Linux websever 5.15.0-153-generic #163-Ubuntu SMP Thu Aug 7 16:37:18 UTC 2025 x86_64
Apache/2.4.52 (Ubuntu)
: 192.168.3.70 | : 192.168.1.99
Cant Read [ /etc/named.conf ]
8.1.2-1ubuntu2.23
urlab
www.github.com/MadExploits
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
UNLOCK SHELL
HASH IDENTIFIER
CPANEL RESET
CREATE WP USER
README
+ Create Folder
+ Create File
/
var /
www /
html /
coursewise /
assets /
[ HOME SHELL ]
Name
Size
Permission
Action
AcademicTools-tj30wEj0.js
7.55
KB
-rwxr-xr-x
AcademicTools-tj30wEj0.js.map
14.63
KB
-rwxr-xr-x
AddCourse-BTNu-pnI.js
10.08
KB
-rwxr-xr-x
AddCourse-BTNu-pnI.js.map
35.84
KB
-rwxr-xr-x
AdminFeedbackManagement-DsTd1C...
13.52
KB
-rwxr-xr-x
AdminFeedbackManagement-DsTd1C...
45.25
KB
-rwxr-xr-x
CourseReviews-CLlzbLuT.js
27.45
KB
-rwxr-xr-x
CourseReviews-CLlzbLuT.js.map
112.09
KB
-rwxr-xr-x
Dewan-B5d13VSK.png
819.07
KB
-rwxr-xr-x
Dewan-Bniqtmij.js
102
B
-rwxr-xr-x
Dewan-Bniqtmij.js.map
197
B
-rwxr-xr-x
EditCourse-DeWQqcol.js
9.65
KB
-rwxr-xr-x
EditCourse-DeWQqcol.js.map
34.87
KB
-rwxr-xr-x
MyCourses-BA9wctPB.js
8.48
KB
-rwxr-xr-x
MyCourses-BA9wctPB.js.map
31.95
KB
-rwxr-xr-x
Rajput-BnxWGXCy.js
104
B
-rwxr-xr-x
Rajput-BnxWGXCy.js.map
200
B
-rwxr-xr-x
Rajput-CE3gMniE.png
908.11
KB
-rwxr-xr-x
Settings-BGf6-NRc.js
2.09
KB
-rwxr-xr-x
Settings-BGf6-NRc.js.map
5.35
KB
-rwxr-xr-x
TimetableClashChecker-gskbNvYE...
32.74
KB
-rwxr-xr-x
TimetableClashChecker-gskbNvYE...
137.78
KB
-rwxr-xr-x
UserManagement-pl4YxOXe.js
2.17
KB
-rwxr-xr-x
UserManagement-pl4YxOXe.js.map
5.49
KB
-rwxr-xr-x
academic-components-DF0R8Z3x.j...
670.84
KB
-rwxr-xr-x
academic-components-DF0R8Z3x.j...
1.87
MB
-rwxr-xr-x
admin-components-DUStTukf.js
1.36
MB
-rwxr-xr-x
admin-components-DUStTukf.js.m...
5.5
MB
-rwxr-xr-x
apple-touch-icon-CvbJoadU.png
20.94
KB
-rwxr-xr-x
browser-DyVnc2OH.js
392
B
-rwxr-xr-x
browser-DyVnc2OH.js.map
404
B
-rwxr-xr-x
favicon-16x16-CXk8OJVQ.png
734
B
-rwxr-xr-x
favicon-32x32-BMg2Kocu.png
1.78
KB
-rwxr-xr-x
favicon-hhFM0i7Z.ico
15.04
KB
-rwxr-xr-x
geminiService-khxcBfs7.js
2.36
KB
-rwxr-xr-x
geminiService-khxcBfs7.js.map
6.73
KB
-rwxr-xr-x
index-BbxTXAhJ.css
45.32
KB
-rwxr-xr-x
index-DN1SJQ1D.js
73.27
KB
-rwxr-xr-x
index-DN1SJQ1D.js.map
215.58
KB
-rwxr-xr-x
index.es-B3idowhG.js
155.35
KB
-rwxr-xr-x
index.es-B3idowhG.js.map
624.87
KB
-rwxr-xr-x
kunal-UYflGF6w.jpg
9.22
MB
-rwxr-xr-x
kunal-ozIpZZVI.js
102
B
-rwxr-xr-x
kunal-ozIpZZVI.js.map
197
B
-rwxr-xr-x
pdf-vendor-Bz5wMm03.js
317.87
KB
-rwxr-xr-x
pdf-vendor-Bz5wMm03.js.map
976.2
KB
-rwxr-xr-x
purify.es-CQJ0hv7W.js
21.35
KB
-rwxr-xr-x
purify.es-CQJ0hv7W.js.map
88.01
KB
-rwxr-xr-x
react-vendor-BFYHlx6n.js
160.29
KB
-rwxr-xr-x
react-vendor-BFYHlx6n.js.map
687.16
KB
-rwxr-xr-x
sarthak-CfXTejkX.png
764.15
KB
-rwxr-xr-x
sarthak-Cq6ZcrGb.js
106
B
-rwxr-xr-x
sarthak-Cq6ZcrGb.js.map
203
B
-rwxr-xr-x
site-BwHFeIBa.webmanifest
263
B
-rwxr-xr-x
supabase-vendor-DtZyL83W.js
105.45
KB
-rwxr-xr-x
supabase-vendor-DtZyL83W.js.ma...
449.41
KB
-rwxr-xr-x
ui-vendor-DSJ4jbeb.js
44.26
KB
-rwxr-xr-x
ui-vendor-DSJ4jbeb.js.map
190.96
KB
-rwxr-xr-x
useToast-Bg1woyD1.js
414
B
-rwxr-xr-x
useToast-Bg1woyD1.js.map
1.83
KB
-rwxr-xr-x
xlsx-vendor-D_ykzFJ-.js
276.48
KB
-rwxr-xr-x
xlsx-vendor-D_ykzFJ-.js.map
1.37
MB
-rwxr-xr-x
Delete
Unzip
Zip
${this.title}
Close
Code Editor : admin-components-DUStTukf.js
import{b as xv,R as hf,r as G,c as jm,a as ku,d as cr,u as Cu}from"./react-vendor-BFYHlx6n.js";import{c as _v}from"./supabase-vendor-DtZyL83W.js";import{c as Go}from"./pdf-vendor-Bz5wMm03.js";import{u as As,w as Sv}from"./xlsx-vendor-D_ykzFJ-.js";import{A as kv}from"./ui-vendor-DSJ4jbeb.js";var Tl={exports:{}},Ms={};/** * @license React * react-jsx-runtime.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var pf;function Cv(){if(pf)return Ms;pf=1;var t=xv(),r=Symbol.for("react.element"),e=Symbol.for("react.fragment"),a=Object.prototype.hasOwnProperty,f=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,c={key:!0,ref:!0,__self:!0,__source:!0};function s(l,i,n){var o,h={},u=null,d=null;n!==void 0&&(u=""+n),i.key!==void 0&&(u=""+i.key),i.ref!==void 0&&(d=i.ref);for(o in i)a.call(i,o)&&!c.hasOwnProperty(o)&&(h[o]=i[o]);if(l&&l.defaultProps)for(o in i=l.defaultProps,i)h[o]===void 0&&(h[o]=i[o]);return{$$typeof:r,type:l,key:u,ref:d,props:h,_owner:f.current}}return Ms.Fragment=e,Ms.jsx=s,Ms.jsxs=s,Ms}var mf;function Tv(){return mf||(mf=1,Tl.exports=Cv()),Tl.exports}var W=Tv();function Ev(t){if(t.sheet)return t.sheet;for(var r=0;r<document.styleSheets.length;r++)if(document.styleSheets[r].ownerNode===t)return document.styleSheets[r]}function Av(t){var r=document.createElement("style");return r.setAttribute("data-emotion",t.key),t.nonce!==void 0&&r.setAttribute("nonce",t.nonce),r.appendChild(document.createTextNode("")),r.setAttribute("data-s",""),r}var Mv=function(){function t(e){var a=this;this._insertTag=function(f){var c;a.tags.length===0?a.insertionPoint?c=a.insertionPoint.nextSibling:a.prepend?c=a.container.firstChild:c=a.before:c=a.tags[a.tags.length-1].nextSibling,a.container.insertBefore(f,c),a.tags.push(f)},this.isSpeedy=e.speedy===void 0?!0:e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var r=t.prototype;return r.hydrate=function(a){a.forEach(this._insertTag)},r.insert=function(a){this.ctr%(this.isSpeedy?65e3:1)===0&&this._insertTag(Av(this));var f=this.tags[this.tags.length-1];if(this.isSpeedy){var c=Ev(f);try{c.insertRule(a,c.cssRules.length)}catch{}}else f.appendChild(document.createTextNode(a));this.ctr++},r.flush=function(){this.tags.forEach(function(a){var f;return(f=a.parentNode)==null?void 0:f.removeChild(a)}),this.tags=[],this.ctr=0},t}(),br="-ms-",Ba="-moz-",Mt="-webkit-",Pm="comm",Tu="rule",Eu="decl",jv="@import",Rm="@keyframes",Pv="@layer",Rv=Math.abs,el=String.fromCharCode,Iv=Object.assign;function Ov(t,r){return hr(t,0)^45?(((r<<2^hr(t,0))<<2^hr(t,1))<<2^hr(t,2))<<2^hr(t,3):0}function Im(t){return t.trim()}function Nv(t,r){return(t=r.exec(t))?t[0]:t}function jt(t,r,e){return t.replace(r,e)}function Sc(t,r){return t.indexOf(r)}function hr(t,r){return t.charCodeAt(r)|0}function co(t,r,e){return t.slice(r,e)}function hn(t){return t.length}function Au(t){return t.length}function Yo(t,r){return r.push(t),t}function Dv(t,r){return t.map(r).join("")}var tl=1,us=1,Om=0,Or=0,nr=0,ws="";function rl(t,r,e,a,f,c,s){return{value:t,root:r,parent:e,type:a,props:f,children:c,line:tl,column:us,length:s,return:""}}function js(t,r){return Iv(rl("",null,null,"",null,null,0),t,{length:-t.length},r)}function Fv(){return nr}function Bv(){return nr=Or>0?hr(ws,--Or):0,us--,nr===10&&(us=1,tl--),nr}function Fr(){return nr=Or<Om?hr(ws,Or++):0,us++,nr===10&&(us=1,tl++),nr}function vn(){return hr(ws,Or)}function ba(){return Or}function Po(t,r){return co(ws,t,r)}function uo(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 Nm(t){return tl=us=1,Om=hn(ws=t),Or=0,[]}function Dm(t){return ws="",t}function ga(t){return Im(Po(Or-1,kc(t===91?t+2:t===40?t+1:t)))}function Lv(t){for(;(nr=vn())&&nr<33;)Fr();return uo(t)>2||uo(nr)>3?"":" "}function $v(t,r){for(;--r&&Fr()&&!(nr<48||nr>102||nr>57&&nr<65||nr>70&&nr<97););return Po(t,ba()+(r<6&&vn()==32&&Fr()==32))}function kc(t){for(;Fr();)switch(nr){case t:return Or;case 34:case 39:t!==34&&t!==39&&kc(nr);break;case 40:t===41&&kc(t);break;case 92:Fr();break}return Or}function zv(t,r){for(;Fr()&&t+nr!==57;)if(t+nr===84&&vn()===47)break;return"/*"+Po(r,Or-1)+"*"+el(t===47?t:Fr())}function Vv(t){for(;!uo(vn());)Fr();return Po(t,Or)}function Uv(t){return Dm(va("",null,null,null,[""],t=Nm(t),0,[0],t))}function va(t,r,e,a,f,c,s,l,i){for(var n=0,o=0,h=s,u=0,d=0,m=0,b=1,p=1,v=1,g=0,x="",C=f,T=c,R=a,B=x;p;)switch(m=g,g=Fr()){case 40:if(m!=108&&hr(B,h-1)==58){Sc(B+=jt(ga(g),"&","&\f"),"&\f")!=-1&&(v=-1);break}case 34:case 39:case 91:B+=ga(g);break;case 9:case 10:case 13:case 32:B+=Lv(m);break;case 92:B+=$v(ba()-1,7);continue;case 47:switch(vn()){case 42:case 47:Yo(Wv(zv(Fr(),ba()),r,e),i);break;default:B+="/"}break;case 123*b:l[n++]=hn(B)*v;case 125*b:case 59:case 0:switch(g){case 0:case 125:p=0;case 59+o:v==-1&&(B=jt(B,/\f/g,"")),d>0&&hn(B)-h&&Yo(d>32?gf(B+";",a,e,h-1):gf(jt(B," ","")+";",a,e,h-2),i);break;case 59:B+=";";default:if(Yo(R=bf(B,r,e,n,o,f,l,x,C=[],T=[],h),c),g===123)if(o===0)va(B,r,R,R,C,c,h,l,T);else switch(u===99&&hr(B,3)===110?100:u){case 100:case 108:case 109:case 115:va(t,R,R,a&&Yo(bf(t,R,R,0,0,f,l,x,f,C=[],h),T),f,T,h,l,a?C:T);break;default:va(B,R,R,R,[""],T,0,l,T)}}n=o=d=0,b=v=1,x=B="",h=s;break;case 58:h=1+hn(B),d=m;default:if(b<1){if(g==123)--b;else if(g==125&&b++==0&&Bv()==125)continue}switch(B+=el(g),g*b){case 38:v=o>0?1:(B+="\f",-1);break;case 44:l[n++]=(hn(B)-1)*v,v=1;break;case 64:vn()===45&&(B+=ga(Fr())),u=vn(),o=h=hn(x=B+=Vv(ba())),g++;break;case 45:m===45&&hn(B)==2&&(b=0)}}return c}function bf(t,r,e,a,f,c,s,l,i,n,o){for(var h=f-1,u=f===0?c:[""],d=Au(u),m=0,b=0,p=0;m<a;++m)for(var v=0,g=co(t,h+1,h=Rv(b=s[m])),x=t;v<d;++v)(x=Im(b>0?u[v]+" "+g:jt(g,/&\f/g,u[v])))&&(i[p++]=x);return rl(t,r,e,f===0?Tu:l,i,n,o)}function Wv(t,r,e){return rl(t,r,e,Pm,el(Fv()),co(t,2,-2),0)}function gf(t,r,e,a){return rl(t,r,e,Eu,co(t,0,a),co(t,a+1,-1),a)}function ts(t,r){for(var e="",a=Au(t),f=0;f<a;f++)e+=r(t[f],f,t,r)||"";return e}function Hv(t,r,e,a){switch(t.type){case Pv:if(t.children.length)break;case jv:case Eu:return t.return=t.return||t.value;case Pm:return"";case Rm:return t.return=t.value+"{"+ts(t.children,a)+"}";case Tu:t.value=t.props.join(",")}return hn(e=ts(t.children,a))?t.return=t.value+"{"+e+"}":""}function qv(t){var r=Au(t);return function(e,a,f,c){for(var s="",l=0;l<r;l++)s+=t[l](e,a,f,c)||"";return s}}function Xv(t){return function(r){r.root||(r=r.return)&&t(r)}}function Fm(t){var r=Object.create(null);return function(e){return r[e]===void 0&&(r[e]=t(e)),r[e]}}var Kv=function(r,e,a){for(var f=0,c=0;f=c,c=vn(),f===38&&c===12&&(e[a]=1),!uo(c);)Fr();return Po(r,Or)},Gv=function(r,e){var a=-1,f=44;do switch(uo(f)){case 0:f===38&&vn()===12&&(e[a]=1),r[a]+=Kv(Or-1,e,a);break;case 2:r[a]+=ga(f);break;case 4:if(f===44){r[++a]=vn()===58?"&\f":"",e[a]=r[a].length;break}default:r[a]+=el(f)}while(f=Fr());return r},Yv=function(r,e){return Dm(Gv(Nm(r),e))},vf=new WeakMap,Zv=function(r){if(!(r.type!=="rule"||!r.parent||r.length<1)){for(var e=r.value,a=r.parent,f=r.column===a.column&&r.line===a.line;a.type!=="rule";)if(a=a.parent,!a)return;if(!(r.props.length===1&&e.charCodeAt(0)!==58&&!vf.get(a))&&!f){vf.set(r,!0);for(var c=[],s=Yv(e,c),l=a.props,i=0,n=0;i<s.length;i++)for(var o=0;o<l.length;o++,n++)r.props[n]=c[i]?s[i].replace(/&\f/g,l[o]):l[o]+" "+s[i]}}},Jv=function(r){if(r.type==="decl"){var e=r.value;e.charCodeAt(0)===108&&e.charCodeAt(2)===98&&(r.return="",r.value="")}};function Bm(t,r){switch(Ov(t,r)){case 5103:return Mt+"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 Mt+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return Mt+t+Ba+t+br+t+t;case 6828:case 4268:return Mt+t+br+t+t;case 6165:return Mt+t+br+"flex-"+t+t;case 5187:return Mt+t+jt(t,/(\w+).+(:[^]+)/,Mt+"box-$1$2"+br+"flex-$1$2")+t;case 5443:return Mt+t+br+"flex-item-"+jt(t,/flex-|-self/,"")+t;case 4675:return Mt+t+br+"flex-line-pack"+jt(t,/align-content|flex-|-self/,"")+t;case 5548:return Mt+t+br+jt(t,"shrink","negative")+t;case 5292:return Mt+t+br+jt(t,"basis","preferred-size")+t;case 6060:return Mt+"box-"+jt(t,"-grow","")+Mt+t+br+jt(t,"grow","positive")+t;case 4554:return Mt+jt(t,/([^-])(transform)/g,"$1"+Mt+"$2")+t;case 6187:return jt(jt(jt(t,/(zoom-|grab)/,Mt+"$1"),/(image-set)/,Mt+"$1"),t,"")+t;case 5495:case 3959:return jt(t,/(image-set\([^]*)/,Mt+"$1$`$1");case 4968:return jt(jt(t,/(.+:)(flex-)?(.*)/,Mt+"box-pack:$3"+br+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+Mt+t+t;case 4095:case 3583:case 4068:case 2532:return jt(t,/(.+)-inline(.+)/,Mt+"$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(hn(t)-1-r>6)switch(hr(t,r+1)){case 109:if(hr(t,r+4)!==45)break;case 102:return jt(t,/(.+:)(.+)-([^]+)/,"$1"+Mt+"$2-$3$1"+Ba+(hr(t,r+3)==108?"$3":"$2-$3"))+t;case 115:return~Sc(t,"stretch")?Bm(jt(t,"stretch","fill-available"),r)+t:t}break;case 4949:if(hr(t,r+1)!==115)break;case 6444:switch(hr(t,hn(t)-3-(~Sc(t,"!important")&&10))){case 107:return jt(t,":",":"+Mt)+t;case 101:return jt(t,/(.+:)([^;!]+)(;|!.+)?/,"$1"+Mt+(hr(t,14)===45?"inline-":"")+"box$3$1"+Mt+"$2$3$1"+br+"$2box$3")+t}break;case 5936:switch(hr(t,r+11)){case 114:return Mt+t+br+jt(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return Mt+t+br+jt(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return Mt+t+br+jt(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return Mt+t+br+t+t}return t}var Qv=function(r,e,a,f){if(r.length>-1&&!r.return)switch(r.type){case Eu:r.return=Bm(r.value,r.length);break;case Rm:return ts([js(r,{value:jt(r.value,"@","@"+Mt)})],f);case Tu:if(r.length)return Dv(r.props,function(c){switch(Nv(c,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return ts([js(r,{props:[jt(c,/:(read-\w+)/,":"+Ba+"$1")]})],f);case"::placeholder":return ts([js(r,{props:[jt(c,/:(plac\w+)/,":"+Mt+"input-$1")]}),js(r,{props:[jt(c,/:(plac\w+)/,":"+Ba+"$1")]}),js(r,{props:[jt(c,/:(plac\w+)/,br+"input-$1")]})],f)}return""})}},ey=[Qv],ty=function(r){var e=r.key;if(e==="css"){var a=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(a,function(b){var p=b.getAttribute("data-emotion");p.indexOf(" ")!==-1&&(document.head.appendChild(b),b.setAttribute("data-s",""))})}var f=r.stylisPlugins||ey,c={},s,l=[];s=r.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+e+' "]'),function(b){for(var p=b.getAttribute("data-emotion").split(" "),v=1;v<p.length;v++)c[p[v]]=!0;l.push(b)});var i,n=[Zv,Jv];{var o,h=[Hv,Xv(function(b){o.insert(b)})],u=qv(n.concat(f,h)),d=function(p){return ts(Uv(p),u)};i=function(p,v,g,x){o=g,d(p?p+"{"+v.styles+"}":v.styles),x&&(m.inserted[v.name]=!0)}}var m={key:e,sheet:new Mv({key:e,container:s,nonce:r.nonce,speedy:r.speedy,prepend:r.prepend,insertionPoint:r.insertionPoint}),nonce:r.nonce,inserted:c,registered:{},insert:i};return m.sheet.hydrate(l),m};function Ti(){return Ti=Object.assign?Object.assign.bind():function(t){for(var r=1;r<arguments.length;r++){var e=arguments[r];for(var a in e)({}).hasOwnProperty.call(e,a)&&(t[a]=e[a])}return t},Ti.apply(null,arguments)}var yf=function(r){var e=new WeakMap;return function(a){if(e.has(a))return e.get(a);var f=r(a);return e.set(a,f),f}},El={exports:{}},Nt={};/** @license React v16.13.1 * react-is.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */var wf;function ry(){if(wf)return Nt;wf=1;var t=typeof Symbol=="function"&&Symbol.for,r=t?Symbol.for("react.element"):60103,e=t?Symbol.for("react.portal"):60106,a=t?Symbol.for("react.fragment"):60107,f=t?Symbol.for("react.strict_mode"):60108,c=t?Symbol.for("react.profiler"):60114,s=t?Symbol.for("react.provider"):60109,l=t?Symbol.for("react.context"):60110,i=t?Symbol.for("react.async_mode"):60111,n=t?Symbol.for("react.concurrent_mode"):60111,o=t?Symbol.for("react.forward_ref"):60112,h=t?Symbol.for("react.suspense"):60113,u=t?Symbol.for("react.suspense_list"):60120,d=t?Symbol.for("react.memo"):60115,m=t?Symbol.for("react.lazy"):60116,b=t?Symbol.for("react.block"):60121,p=t?Symbol.for("react.fundamental"):60117,v=t?Symbol.for("react.responder"):60118,g=t?Symbol.for("react.scope"):60119;function x(T){if(typeof T=="object"&&T!==null){var R=T.$$typeof;switch(R){case r:switch(T=T.type,T){case i:case n:case a:case c:case f:case h:return T;default:switch(T=T&&T.$$typeof,T){case l:case o:case m:case d:case s:return T;default:return R}}case e:return R}}}function C(T){return x(T)===n}return Nt.AsyncMode=i,Nt.ConcurrentMode=n,Nt.ContextConsumer=l,Nt.ContextProvider=s,Nt.Element=r,Nt.ForwardRef=o,Nt.Fragment=a,Nt.Lazy=m,Nt.Memo=d,Nt.Portal=e,Nt.Profiler=c,Nt.StrictMode=f,Nt.Suspense=h,Nt.isAsyncMode=function(T){return C(T)||x(T)===i},Nt.isConcurrentMode=C,Nt.isContextConsumer=function(T){return x(T)===l},Nt.isContextProvider=function(T){return x(T)===s},Nt.isElement=function(T){return typeof T=="object"&&T!==null&&T.$$typeof===r},Nt.isForwardRef=function(T){return x(T)===o},Nt.isFragment=function(T){return x(T)===a},Nt.isLazy=function(T){return x(T)===m},Nt.isMemo=function(T){return x(T)===d},Nt.isPortal=function(T){return x(T)===e},Nt.isProfiler=function(T){return x(T)===c},Nt.isStrictMode=function(T){return x(T)===f},Nt.isSuspense=function(T){return x(T)===h},Nt.isValidElementType=function(T){return typeof T=="string"||typeof T=="function"||T===a||T===n||T===c||T===f||T===h||T===u||typeof T=="object"&&T!==null&&(T.$$typeof===m||T.$$typeof===d||T.$$typeof===s||T.$$typeof===l||T.$$typeof===o||T.$$typeof===p||T.$$typeof===v||T.$$typeof===g||T.$$typeof===b)},Nt.typeOf=x,Nt}var xf;function ny(){return xf||(xf=1,El.exports=ry()),El.exports}var Al,_f;function iy(){if(_f)return Al;_f=1;var t=ny(),r={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},e={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},f={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},c={};c[t.ForwardRef]=a,c[t.Memo]=f;function s(m){return t.isMemo(m)?f:c[m.$$typeof]||r}var l=Object.defineProperty,i=Object.getOwnPropertyNames,n=Object.getOwnPropertySymbols,o=Object.getOwnPropertyDescriptor,h=Object.getPrototypeOf,u=Object.prototype;function d(m,b,p){if(typeof b!="string"){if(u){var v=h(b);v&&v!==u&&d(m,v,p)}var g=i(b);n&&(g=g.concat(n(b)));for(var x=s(m),C=s(b),T=0;T<g.length;++T){var R=g[T];if(!e[R]&&!(p&&p[R])&&!(C&&C[R])&&!(x&&x[R])){var B=o(b,R);try{l(m,R,B)}catch{}}}}return m}return Al=d,Al}iy();var sy=!0;function oy(t,r,e){var a="";return e.split(" ").forEach(function(f){t[f]!==void 0?r.push(t[f]+";"):f&&(a+=f+" ")}),a}var Lm=function(r,e,a){var f=r.key+"-"+e.name;(a===!1||sy===!1)&&r.registered[f]===void 0&&(r.registered[f]=e.styles)},$m=function(r,e,a){Lm(r,e,a);var f=r.key+"-"+e.name;if(r.inserted[e.name]===void 0){var c=e;do r.insert(e===c?"."+f:"",c,r.sheet,!0),c=c.next;while(c!==void 0)}};function ay(t){for(var r=0,e,a=0,f=t.length;f>=4;++a,f-=4)e=t.charCodeAt(a)&255|(t.charCodeAt(++a)&255)<<8|(t.charCodeAt(++a)&255)<<16|(t.charCodeAt(++a)&255)<<24,e=(e&65535)*1540483477+((e>>>16)*59797<<16),e^=e>>>24,r=(e&65535)*1540483477+((e>>>16)*59797<<16)^(r&65535)*1540483477+((r>>>16)*59797<<16);switch(f){case 3:r^=(t.charCodeAt(a+2)&255)<<16;case 2:r^=(t.charCodeAt(a+1)&255)<<8;case 1:r^=t.charCodeAt(a)&255,r=(r&65535)*1540483477+((r>>>16)*59797<<16)}return r^=r>>>13,r=(r&65535)*1540483477+((r>>>16)*59797<<16),((r^r>>>15)>>>0).toString(36)}var ly={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},cy=/[A-Z]|^ms/g,uy=/_EMO_([^_]+?)_([^]*?)_EMO_/g,zm=function(r){return r.charCodeAt(1)===45},Sf=function(r){return r!=null&&typeof r!="boolean"},Ml=Fm(function(t){return zm(t)?t:t.replace(cy,"-$&").toLowerCase()}),kf=function(r,e){switch(r){case"animation":case"animationName":if(typeof e=="string")return e.replace(uy,function(a,f,c){return pn={name:f,styles:c,next:pn},f})}return ly[r]!==1&&!zm(r)&&typeof e=="number"&&e!==0?e+"px":e};function fo(t,r,e){if(e==null)return"";var a=e;if(a.__emotion_styles!==void 0)return a;switch(typeof e){case"boolean":return"";case"object":{var f=e;if(f.anim===1)return pn={name:f.name,styles:f.styles,next:pn},f.name;var c=e;if(c.styles!==void 0){var s=c.next;if(s!==void 0)for(;s!==void 0;)pn={name:s.name,styles:s.styles,next:pn},s=s.next;var l=c.styles+";";return l}return dy(t,r,e)}case"function":{if(t!==void 0){var i=pn,n=e(t);return pn=i,fo(t,r,n)}break}}var o=e;if(r==null)return o;var h=r[o];return h!==void 0?h:o}function dy(t,r,e){var a="";if(Array.isArray(e))for(var f=0;f<e.length;f++)a+=fo(t,r,e[f])+";";else for(var c in e){var s=e[c];if(typeof s!="object"){var l=s;r!=null&&r[l]!==void 0?a+=c+"{"+r[l]+"}":Sf(l)&&(a+=Ml(c)+":"+kf(c,l)+";")}else if(Array.isArray(s)&&typeof s[0]=="string"&&(r==null||r[s[0]]===void 0))for(var i=0;i<s.length;i++)Sf(s[i])&&(a+=Ml(c)+":"+kf(c,s[i])+";");else{var n=fo(t,r,s);switch(c){case"animation":case"animationName":{a+=Ml(c)+":"+n+";";break}default:a+=c+"{"+n+"}"}}}return a}var Cf=/label:\s*([^\s;{]+)\s*(;|$)/g,pn;function Mu(t,r,e){if(t.length===1&&typeof t[0]=="object"&&t[0]!==null&&t[0].styles!==void 0)return t[0];var a=!0,f="";pn=void 0;var c=t[0];if(c==null||c.raw===void 0)a=!1,f+=fo(e,r,c);else{var s=c;f+=s[0]}for(var l=1;l<t.length;l++)if(f+=fo(e,r,t[l]),a){var i=c;f+=i[l]}Cf.lastIndex=0;for(var n="",o;(o=Cf.exec(f))!==null;)n+="-"+o[1];var h=ay(f)+n;return{name:h,styles:f,next:pn}}var fy=function(r){return r()},Vm=hf.useInsertionEffect?hf.useInsertionEffect:!1,hy=Vm||fy,Tf=Vm||G.useLayoutEffect,Um=G.createContext(typeof HTMLElement<"u"?ty({key:"css"}):null);Um.Provider;var Wm=function(r){return G.forwardRef(function(e,a){var f=G.useContext(Um);return r(e,f,a)})},ho=G.createContext({}),py=function(r,e){if(typeof e=="function"){var a=e(r);return a}return Ti({},r,e)},my=yf(function(t){return yf(function(r){return py(t,r)})}),by=function(r){var e=G.useContext(ho);return r.theme!==e&&(e=my(e)(r.theme)),G.createElement(ho.Provider,{value:e},r.children)},nl=Wm(function(t,r){var e=t.styles,a=Mu([e],void 0,G.useContext(ho)),f=G.useRef();return Tf(function(){var c=r.key+"-global",s=new r.sheet.constructor({key:c,nonce:r.sheet.nonce,container:r.sheet.container,speedy:r.sheet.isSpeedy}),l=!1,i=document.querySelector('style[data-emotion="'+c+" "+a.name+'"]');return r.sheet.tags.length&&(s.before=r.sheet.tags[0]),i!==null&&(l=!0,i.setAttribute("data-emotion",c),s.hydrate([i])),f.current=[s,l],function(){s.flush()}},[r]),Tf(function(){var c=f.current,s=c[0],l=c[1];if(l){c[1]=!1;return}if(a.next!==void 0&&$m(r,a.next,!0),s.tags.length){var i=s.tags[s.tags.length-1].nextElementSibling;s.before=i,s.flush()}r.insert("",a,s,!1)},[r,a.name]),null});function gy(){for(var t=arguments.length,r=new Array(t),e=0;e<t;e++)r[e]=arguments[e];return Mu(r)}var Ri=function(){var r=gy.apply(void 0,arguments),e="animation-"+r.name;return{name:e,styles:"@keyframes "+e+"{"+r.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}},Hm=String.raw,qm=Hm` :root, :host { --chakra-vh: 100vh; } @supports (height: -webkit-fill-available) { :root, :host { --chakra-vh: -webkit-fill-available; } } @supports (height: -moz-fill-available) { :root, :host { --chakra-vh: -moz-fill-available; } } @supports (height: 100dvh) { :root, :host { --chakra-vh: 100dvh; } } `,vy=()=>W.jsx(nl,{styles:qm}),yy=({scope:t=""})=>W.jsx(nl,{styles:Hm` html { line-height: 1.5; -webkit-text-size-adjust: 100%; font-family: system-ui, sans-serif; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; -moz-osx-font-smoothing: grayscale; touch-action: manipulation; } body { position: relative; min-height: 100%; margin: 0; font-feature-settings: "kern"; } ${t} :where(*, *::before, *::after) { border-width: 0; border-style: solid; box-sizing: border-box; word-wrap: break-word; } main { display: block; } ${t} hr { border-top-width: 1px; box-sizing: content-box; height: 0; overflow: visible; } ${t} :where(pre, code, kbd,samp) { font-family: SFMono-Regular, Menlo, Monaco, Consolas, monospace; font-size: 1em; } ${t} a { background-color: transparent; color: inherit; text-decoration: inherit; } ${t} abbr[title] { border-bottom: none; text-decoration: underline; -webkit-text-decoration: underline dotted; text-decoration: underline dotted; } ${t} :where(b, strong) { font-weight: bold; } ${t} small { font-size: 80%; } ${t} :where(sub,sup) { font-size: 75%; line-height: 0; position: relative; vertical-align: baseline; } ${t} sub { bottom: -0.25em; } ${t} sup { top: -0.5em; } ${t} img { border-style: none; } ${t} :where(button, input, optgroup, select, textarea) { font-family: inherit; font-size: 100%; line-height: 1.15; margin: 0; } ${t} :where(button, input) { overflow: visible; } ${t} :where(button, select) { text-transform: none; } ${t} :where( button::-moz-focus-inner, [type="button"]::-moz-focus-inner, [type="reset"]::-moz-focus-inner, [type="submit"]::-moz-focus-inner ) { border-style: none; padding: 0; } ${t} fieldset { padding: 0.35em 0.75em 0.625em; } ${t} legend { box-sizing: border-box; color: inherit; display: table; max-width: 100%; padding: 0; white-space: normal; } ${t} progress { vertical-align: baseline; } ${t} textarea { overflow: auto; } ${t} :where([type="checkbox"], [type="radio"]) { box-sizing: border-box; padding: 0; } ${t} input[type="number"]::-webkit-inner-spin-button, ${t} input[type="number"]::-webkit-outer-spin-button { -webkit-appearance: none !important; } ${t} input[type="number"] { -moz-appearance: textfield; } ${t} input[type="search"] { -webkit-appearance: textfield; outline-offset: -2px; } ${t} input[type="search"]::-webkit-search-decoration { -webkit-appearance: none !important; } ${t} ::-webkit-file-upload-button { -webkit-appearance: button; font: inherit; } ${t} details { display: block; } ${t} summary { display: list-item; } template { display: none; } [hidden] { display: none !important; } ${t} :where( blockquote, dl, dd, h1, h2, h3, h4, h5, h6, hr, figure, p, pre ) { margin: 0; } ${t} button { background: transparent; padding: 0; } ${t} fieldset { margin: 0; padding: 0; } ${t} :where(ol, ul) { margin: 0; padding: 0; } ${t} textarea { resize: vertical; } ${t} :where(button, [role="button"]) { cursor: pointer; } ${t} button::-moz-focus-inner { border: 0 !important; } ${t} table { border-collapse: collapse; } ${t} :where(h1, h2, h3, h4, h5, h6) { font-size: inherit; font-weight: inherit; } ${t} :where(button, input, optgroup, select, textarea) { padding: 0; line-height: inherit; color: inherit; } ${t} :where(img, svg, video, canvas, audio, iframe, embed, object) { display: block; } ${t} :where(img, video) { max-width: 100%; height: auto; } [data-js-focus-visible] :focus:not([data-focus-visible-added]):not( [data-focus-visible-disabled] ) { outline: none; box-shadow: none; } ${t} select::-ms-expand { display: none; } ${qm} `});function wy(t,r){return`${t} returned \`undefined\`. Seems you forgot to wrap component within ${r}`}function It(t={}){const{name:r,strict:e=!0,hookName:a="useContext",providerName:f="Provider",errorMessage:c,defaultValue:s}=t,l=G.createContext(s);l.displayName=r;function i(){var n;const o=G.useContext(l);if(!o&&e){const h=new Error(c??wy(a,f));throw h.name="ContextError",(n=Error.captureStackTrace)==null||n.call(Error,h,i),h}return o}return[l.Provider,i,l]}var[xy,_y]=It({strict:!1,name:"PortalManagerContext"});function Xm(t){const{children:r,zIndex:e}=t;return W.jsx(xy,{value:{zIndex:e},children:r})}Xm.displayName="PortalManager";var Qn=globalThis?.document?G.useLayoutEffect:G.useEffect,[Km,Sy]=It({strict:!1,name:"PortalContext"}),ju="chakra-portal",ky=".chakra-portal",Cy=t=>W.jsx("div",{className:"chakra-portal-zIndex",style:{position:"absolute",zIndex:t.zIndex,top:0,left:0,right:0},children:t.children}),Ty=t=>{const{appendToParentPortal:r,children:e}=t,[a,f]=G.useState(null),c=G.useRef(null),[,s]=G.useState({});G.useEffect(()=>s({}),[]);const l=Sy(),i=_y();Qn(()=>{if(!a)return;const o=a.ownerDocument,h=r?l??o.body:o.body;if(!h)return;c.current=o.createElement("div"),c.current.className=ju,h.appendChild(c.current),s({});const u=c.current;return()=>{h.contains(u)&&h.removeChild(u)}},[a]);const n=i?.zIndex?W.jsx(Cy,{zIndex:i?.zIndex,children:e}):e;return c.current?jm.createPortal(W.jsx(Km,{value:c.current,children:n}),c.current):W.jsx("span",{ref:o=>{o&&f(o)}})},Ey=t=>{const{children:r,containerRef:e,appendToParentPortal:a}=t,f=e.current,c=f??(typeof window<"u"?document.body:void 0),s=G.useMemo(()=>{const i=f?.ownerDocument.createElement("div");return i&&(i.className=ju),i},[f]),[,l]=G.useState({});return Qn(()=>l({}),[]),Qn(()=>{if(!(!s||!c))return c.appendChild(s),()=>{c.removeChild(s)}},[s,c]),c&&s?jm.createPortal(W.jsx(Km,{value:a?s:null,children:r}),s):null};function xs(t){const r={appendToParentPortal:!0,...t},{containerRef:e,...a}=r;return e?W.jsx(Ey,{containerRef:e,...a}):W.jsx(Ty,{...a})}xs.className=ju;xs.selector=ky;xs.displayName="Portal";function ri(){const t=G.useContext(ho);if(!t)throw Error("useTheme: `theme` is undefined. Seems you forgot to wrap your app in `<ChakraProvider />` or `<ThemeProvider />`");return t}var Pu=G.createContext({});Pu.displayName="ColorModeContext";function il(){const t=G.useContext(Pu);if(t===void 0)throw new Error("useColorMode must be used within a ColorModeProvider");return t}function rs(t,r){const{colorMode:e}=il();return e==="dark"?r:t}var Zo={light:"chakra-ui-light",dark:"chakra-ui-dark"};function Ay(t={}){const{preventTransition:r=!0}=t,e={setDataset:a=>{const f=r?e.preventTransition():void 0;document.documentElement.dataset.theme=a,document.documentElement.style.colorScheme=a,f?.()},setClassName(a){document.body.classList.add(a?Zo.dark:Zo.light),document.body.classList.remove(a?Zo.light:Zo.dark)},query(){return window.matchMedia("(prefers-color-scheme: dark)")},getSystemTheme(a){var f;return((f=e.query().matches)!=null?f:a==="dark")?"dark":"light"},addListener(a){const f=e.query(),c=s=>{a(s.matches?"dark":"light")};return typeof f.addListener=="function"?f.addListener(c):f.addEventListener("change",c),()=>{typeof f.removeListener=="function"?f.removeListener(c):f.removeEventListener("change",c)}},preventTransition(){const a=document.createElement("style");return a.appendChild(document.createTextNode("*{-webkit-transition:none!important;-moz-transition:none!important;-o-transition:none!important;-ms-transition:none!important;transition:none!important}")),document.head.appendChild(a),()=>{window.getComputedStyle(document.body),requestAnimationFrame(()=>{requestAnimationFrame(()=>{document.head.removeChild(a)})})}}};return e}var My="chakra-ui-color-mode";function jy(t){return{ssr:!1,type:"localStorage",get(r){if(!globalThis?.document)return r;let e;try{e=localStorage.getItem(t)||r}catch{}return e||r},set(r){try{localStorage.setItem(t,r)}catch{}}}}var Py=jy(My),Ef=()=>{};function Af(t,r){return t.type==="cookie"&&t.ssr?t.get(r):r}function Gm(t){const{value:r,children:e,options:{useSystemColorMode:a,initialColorMode:f,disableTransitionOnChange:c}={},colorModeManager:s=Py}=t,l=f==="dark"?"dark":"light",[i,n]=G.useState(()=>Af(s,l)),[o,h]=G.useState(()=>Af(s)),{getSystemTheme:u,setClassName:d,setDataset:m,addListener:b}=G.useMemo(()=>Ay({preventTransition:c}),[c]),p=f==="system"&&!i?o:i,v=G.useCallback(C=>{const T=C==="system"?u():C;n(T),d(T==="dark"),m(T),s.set(T)},[s,u,d,m]);Qn(()=>{f==="system"&&h(u())},[]),G.useEffect(()=>{const C=s.get();if(C){v(C);return}if(f==="system"){v("system");return}v(l)},[s,l,f,v]);const g=G.useCallback(()=>{v(p==="dark"?"light":"dark")},[p,v]);G.useEffect(()=>{if(a)return b(v)},[a,b,v]);const x=G.useMemo(()=>({colorMode:r??p,toggleColorMode:r?Ef:g,setColorMode:r?Ef:v,forced:r!==void 0}),[p,g,v,r]);return W.jsx(Pu.Provider,{value:x,children:e})}Gm.displayName="ColorModeProvider";function Ym(){const t=il(),r=ri();return{...t,theme:r}}function Ry(t,r,e){var a,f;if(r==null)return r;const c=s=>{var l,i;return(i=(l=t.__breakpoints)==null?void 0:l.asArray)==null?void 0:i[s]};return(f=(a=c(r))!=null?a:c(e))!=null?f:e}function Iy(t,r,e){var a,f;if(r==null)return r;const c=s=>{var l,i;return(i=(l=t.__cssMap)==null?void 0:l[s])==null?void 0:i.value};return(f=(a=c(r))!=null?a:c(e))!=null?f:e}function Oy(t,r,e){const a=ri();return Zm(t,r,e)(a)}function Zm(t,r,e){const a=Array.isArray(r)?r:[r],f=Array.isArray(e)?e:[e];return c=>{const s=f.filter(Boolean),l=a.map((i,n)=>{var o,h;if(t==="breakpoints")return Ry(c,i,(o=s[n])!=null?o:i);const u=`${t}.${i}`;return Iy(c,u,(h=s[n])!=null?h:i)});return Array.isArray(r)?l:l[0]}}var Fe=(...t)=>t.filter(Boolean).join(" ");function kr(t){const r=typeof t;return t!=null&&(r==="object"||r==="function")&&!Array.isArray(t)}var Ro=t=>{const{condition:r,message:e}=t};function Xr(t,...r){return Ny(t)?t(...r):t}var Ny=t=>typeof t=="function",Bt=t=>t?"":void 0,On=t=>t?!0:void 0;function Qe(...t){return function(e){t.some(a=>(a?.(e),e?.defaultPrevented))}}function Ru(...t){return function(e){t.forEach(a=>{a?.(e)})}}var Fs={exports:{}};Fs.exports;var Mf;function Dy(){return Mf||(Mf=1,function(t,r){var e=200,a="__lodash_hash_undefined__",f=800,c=16,s=9007199254740991,l="[object Arguments]",i="[object Array]",n="[object AsyncFunction]",o="[object Boolean]",h="[object Date]",u="[object Error]",d="[object Function]",m="[object GeneratorFunction]",b="[object Map]",p="[object Number]",v="[object Null]",g="[object Object]",x="[object Proxy]",C="[object RegExp]",T="[object Set]",R="[object String]",B="[object Undefined]",I="[object WeakMap]",F="[object ArrayBuffer]",L="[object DataView]",V="[object Float32Array]",z="[object Float64Array]",E="[object Int8Array]",P="[object Int16Array]",k="[object Int32Array]",y="[object Uint8Array]",w="[object Uint8ClampedArray]",_="[object Uint16Array]",S="[object Uint32Array]",A=/[\\^$.*+?()[\]{}|]/g,O=/^\[object .+?Constructor\]$/,N=/^(?:0|[1-9]\d*)$/,U={};U[V]=U[z]=U[E]=U[P]=U[k]=U[y]=U[w]=U[_]=U[S]=!0,U[l]=U[i]=U[F]=U[o]=U[L]=U[h]=U[u]=U[d]=U[b]=U[p]=U[g]=U[C]=U[T]=U[R]=U[I]=!1;var H=typeof globalThis=="object"&&globalThis&&globalThis.Object===Object&&globalThis,Z=typeof self=="object"&&self&&self.Object===Object&&self,D=H||Z||Function("return this")(),q=r&&!r.nodeType&&r,M=q&&!0&&t&&!t.nodeType&&t,j=M&&M.exports===q,$=j&&H.process,K=function(){try{var ie=M&&M.require&&M.require("util").types;return ie||$&&$.binding&&$.binding("util")}catch{}}(),J=K&&K.isTypedArray;function X(ie,de,ge){switch(ge.length){case 0:return ie.call(de);case 1:return ie.call(de,ge[0]);case 2:return ie.call(de,ge[0],ge[1]);case 3:return ie.call(de,ge[0],ge[1],ge[2])}return ie.apply(de,ge)}function Q(ie,de){for(var ge=-1,Ve=Array(ie);++ge<ie;)Ve[ge]=de(ge);return Ve}function ee(ie){return function(de){return ie(de)}}function se(ie,de){return ie?.[de]}function Y(ie,de){return function(ge){return ie(de(ge))}}var te=Array.prototype,ne=Function.prototype,oe=Object.prototype,ae=D["__core-js_shared__"],ce=ne.toString,me=oe.hasOwnProperty,be=function(){var ie=/[^.]+$/.exec(ae&&ae.keys&&ae.keys.IE_PROTO||"");return ie?"Symbol(src)_1."+ie:""}(),ye=oe.toString,Me=ce.call(Object),Te=RegExp("^"+ce.call(me).replace(A,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),fe=j?D.Buffer:void 0,ke=D.Symbol,Ee=D.Uint8Array;fe&&fe.allocUnsafe;var Ne=Y(Object.getPrototypeOf,Object),De=Object.create,je=oe.propertyIsEnumerable,Ce=te.splice,Oe=ke?ke.toStringTag:void 0,Le=function(){try{var ie=an(Object,"defineProperty");return ie({},"",{}),ie}catch{}}(),Be=fe?fe.isBuffer:void 0,ct=Math.max,wt=Date.now,We=an(D,"Map"),dt=an(Object,"create"),ut=function(){function ie(){}return function(de){if(!li(de))return{};if(De)return De(de);ie.prototype=de;var ge=new ie;return ie.prototype=void 0,ge}}();function qe(ie){var de=-1,ge=ie==null?0:ie.length;for(this.clear();++de<ge;){var Ve=ie[de];this.set(Ve[0],Ve[1])}}function Ot(){this.__data__=dt?dt(null):{},this.size=0}function bt(ie){var de=this.has(ie)&&delete this.__data__[ie];return this.size-=de?1:0,de}function Ye(ie){var de=this.__data__;if(dt){var ge=de[ie];return ge===a?void 0:ge}return me.call(de,ie)?de[ie]:void 0}function pt(ie){var de=this.__data__;return dt?de[ie]!==void 0:me.call(de,ie)}function kt(ie,de){var ge=this.__data__;return this.size+=this.has(ie)?0:1,ge[ie]=dt&&de===void 0?a:de,this}qe.prototype.clear=Ot,qe.prototype.delete=bt,qe.prototype.get=Ye,qe.prototype.has=pt,qe.prototype.set=kt;function Ue(ie){var de=-1,ge=ie==null?0:ie.length;for(this.clear();++de<ge;){var Ve=ie[de];this.set(Ve[0],Ve[1])}}function vt(){this.__data__=[],this.size=0}function Ct(ie){var de=this.__data__,ge=re(de,ie);if(ge<0)return!1;var Ve=de.length-1;return ge==Ve?de.pop():Ce.call(de,ge,1),--this.size,!0}function it(ie){var de=this.__data__,ge=re(de,ie);return ge<0?void 0:de[ge][1]}function le(ie){return re(this.__data__,ie)>-1}function he(ie,de){var ge=this.__data__,Ve=re(ge,ie);return Ve<0?(++this.size,ge.push([ie,de])):ge[Ve][1]=de,this}Ue.prototype.clear=vt,Ue.prototype.delete=Ct,Ue.prototype.get=it,Ue.prototype.has=le,Ue.prototype.set=he;function ve(ie){var de=-1,ge=ie==null?0:ie.length;for(this.clear();++de<ge;){var Ve=ie[de];this.set(Ve[0],Ve[1])}}function Pe(){this.size=0,this.__data__={hash:new qe,map:new(We||Ue),string:new qe}}function Xe(ie){var de=Jr(this,ie).delete(ie);return this.size-=de?1:0,de}function Ie(ie){return Jr(this,ie).get(ie)}function et(ie){return Jr(this,ie).has(ie)}function Ke(ie,de){var ge=Jr(this,ie),Ve=ge.size;return ge.set(ie,de),this.size+=ge.size==Ve?0:1,this}ve.prototype.clear=Pe,ve.prototype.delete=Xe,ve.prototype.get=Ie,ve.prototype.has=et,ve.prototype.set=Ke;function $e(ie){var de=this.__data__=new Ue(ie);this.size=de.size}function rt(){this.__data__=new Ue,this.size=0}function tt(ie){var de=this.__data__,ge=de.delete(ie);return this.size=de.size,ge}function ot(ie){return this.__data__.get(ie)}function Wt(ie){return this.__data__.has(ie)}function Ft(ie,de){var ge=this.__data__;if(ge instanceof Ue){var Ve=ge.__data__;if(!We||Ve.length<e-1)return Ve.push([ie,de]),this.size=++ge.size,this;ge=this.__data__=new ve(Ve)}return ge.set(ie,de),this.size=ge.size,this}$e.prototype.clear=rt,$e.prototype.delete=tt,$e.prototype.get=ot,$e.prototype.has=Wt,$e.prototype.set=Ft;function Qt(ie,de){var ge=Wn(ie),Ve=!ge&&oi(ie),yt=!ge&&!Ve&&ai(ie),Lt=!ge&&!Ve&&!yt&&cf(ie),Ht=ge||Ve||yt||Lt,Et=Ht?Q(ie.length,String):[],qt=Et.length;for(var en in ie)Ht&&(en=="length"||yt&&(en=="offset"||en=="parent")||Lt&&(en=="buffer"||en=="byteLength"||en=="byteOffset")||mt(en,qt))||Et.push(en);return Et}function Kt(ie,de,ge){(ge!==void 0&&!Mn(ie[de],ge)||ge===void 0&&!(de in ie))&&pe(ie,de,ge)}function pr(ie,de,ge){var Ve=ie[de];(!(me.call(ie,de)&&Mn(Ve,ge))||ge===void 0&&!(de in ie))&&pe(ie,de,ge)}function re(ie,de){for(var ge=ie.length;ge--;)if(Mn(ie[ge][0],de))return ge;return-1}function pe(ie,de,ge){de=="__proto__"&&Le?Le(ie,de,{configurable:!0,enumerable:!0,value:ge,writable:!0}):ie[de]=ge}var we=En();function _e(ie){return ie==null?ie===void 0?B:v:Oe&&Oe in Object(ie)?zn(ie):cn(ie)}function ze(ie){return Ts(ie)&&_e(ie)==l}function Ae(ie){if(!li(ie)||Ni(ie))return!1;var de=qn(ie)?Te:O;return de.test(Xo(ie))}function Re(ie){return Ts(ie)&&lf(ie.length)&&!!U[_e(ie)]}function ht(ie){if(!li(ie))return Qr(ie);var de=mr(ie),ge=[];for(var Ve in ie)Ve=="constructor"&&(de||!me.call(ie,Ve))||ge.push(Ve);return ge}function st(ie,de,ge,Ve,yt){ie!==de&&we(de,function(Lt,Ht){if(yt||(yt=new $e),li(Lt))at(ie,de,Ht,ge,st,Ve,yt);else{var Et=Ve?Ve(Vn(ie,Ht),Lt,Ht+"",ie,de,yt):void 0;Et===void 0&&(Et=Lt),Kt(ie,Ht,Et)}},uf)}function at(ie,de,ge,Ve,yt,Lt,Ht){var Et=Vn(ie,ge),qt=Vn(de,ge),en=Ht.get(qt);if(en){Kt(ie,ge,en);return}var Dr=Lt?Lt(Et,qt,ge+"",ie,de,Ht):void 0,Es=Dr===void 0;if(Es){var kl=Wn(qt),Cl=!kl&&ai(qt),ff=!kl&&!Cl&&cf(qt);Dr=qt,kl||Cl||ff?Wn(Et)?Dr=Et:Ko(Et)?Dr=rr(Et):Cl?(Es=!1,Dr=_t(qt)):ff?(Es=!1,Dr=zt(qt)):Dr=[]:bv(qt)||oi(qt)?(Dr=Et,oi(Et)?Dr=gv(Et):(!li(Et)||qn(Et))&&(Dr=St(qt))):Es=!1}Es&&(Ht.set(qt,Dr),yt(Dr,qt,Ve,Lt,Ht),Ht.delete(qt)),Kt(ie,ge,Dr)}function Ge(ie,de){return Un(si(ie,de,df),ie+"")}var xt=Le?function(ie,de){return Le(ie,"toString",{configurable:!0,enumerable:!1,value:yv(de),writable:!0})}:df;function _t(ie,de){return ie.slice()}function Tt(ie){var de=new ie.constructor(ie.byteLength);return new Ee(de).set(new Ee(ie)),de}function zt(ie,de){var ge=Tt(ie.buffer);return new ie.constructor(ge,ie.byteOffset,ie.length)}function rr(ie,de){var ge=-1,Ve=ie.length;for(de||(de=Array(Ve));++ge<Ve;)de[ge]=ie[ge];return de}function ur(ie,de,ge,Ve){var yt=!ge;ge||(ge={});for(var Lt=-1,Ht=de.length;++Lt<Ht;){var Et=de[Lt],qt=void 0;qt===void 0&&(qt=ie[Et]),yt?pe(ge,Et,qt):pr(ge,Et,qt)}return ge}function Nr(ie){return Ge(function(de,ge){var Ve=-1,yt=ge.length,Lt=yt>1?ge[yt-1]:void 0,Ht=yt>2?ge[2]:void 0;for(Lt=ie.length>3&&typeof Lt=="function"?(yt--,Lt):void 0,Ht&&ln(ge[0],ge[1],Ht)&&(Lt=yt<3?void 0:Lt,yt=1),de=Object(de);++Ve<yt;){var Et=ge[Ve];Et&&ie(de,Et,Ve,Lt)}return de})}function En(ie){return function(de,ge,Ve){for(var yt=-1,Lt=Object(de),Ht=Ve(de),Et=Ht.length;Et--;){var qt=Ht[++yt];if(ge(Lt[qt],qt,Lt)===!1)break}return de}}function Jr(ie,de){var ge=ie.__data__;return An(de)?ge[typeof de=="string"?"string":"hash"]:ge.map}function an(ie,de){var ge=se(ie,de);return Ae(ge)?ge:void 0}function zn(ie){var de=me.call(ie,Oe),ge=ie[Oe];try{ie[Oe]=void 0;var Ve=!0}catch{}var yt=ye.call(ie);return Ve&&(de?ie[Oe]=ge:delete ie[Oe]),yt}function St(ie){return typeof ie.constructor=="function"&&!mr(ie)?ut(Ne(ie)):{}}function mt(ie,de){var ge=typeof ie;return de=de??s,!!de&&(ge=="number"||ge!="symbol"&&N.test(ie))&&ie>-1&&ie%1==0&&ie<de}function ln(ie,de,ge){if(!li(ge))return!1;var Ve=typeof de;return(Ve=="number"?Hn(ge)&&mt(de,ge.length):Ve=="string"&&de in ge)?Mn(ge[de],ie):!1}function An(ie){var de=typeof ie;return de=="string"||de=="number"||de=="symbol"||de=="boolean"?ie!=="__proto__":ie===null}function Ni(ie){return!!be&&be in ie}function mr(ie){var de=ie&&ie.constructor,ge=typeof de=="function"&&de.prototype||oe;return ie===ge}function Qr(ie){var de=[];if(ie!=null)for(var ge in Object(ie))de.push(ge);return de}function cn(ie){return ye.call(ie)}function si(ie,de,ge){return de=ct(de===void 0?ie.length-1:de,0),function(){for(var Ve=arguments,yt=-1,Lt=ct(Ve.length-de,0),Ht=Array(Lt);++yt<Lt;)Ht[yt]=Ve[de+yt];yt=-1;for(var Et=Array(de+1);++yt<de;)Et[yt]=Ve[yt];return Et[de]=ge(Ht),X(ie,this,Et)}}function Vn(ie,de){if(!(de==="constructor"&&typeof ie[de]=="function")&&de!="__proto__")return ie[de]}var Un=un(xt);function un(ie){var de=0,ge=0;return function(){var Ve=wt(),yt=c-(Ve-ge);if(ge=Ve,yt>0){if(++de>=f)return arguments[0]}else de=0;return ie.apply(void 0,arguments)}}function Xo(ie){if(ie!=null){try{return ce.call(ie)}catch{}try{return ie+""}catch{}}return""}function Mn(ie,de){return ie===de||ie!==ie&&de!==de}var oi=ze(function(){return arguments}())?ze:function(ie){return Ts(ie)&&me.call(ie,"callee")&&!je.call(ie,"callee")},Wn=Array.isArray;function Hn(ie){return ie!=null&&lf(ie.length)&&!qn(ie)}function Ko(ie){return Ts(ie)&&Hn(ie)}var ai=Be||wv;function qn(ie){if(!li(ie))return!1;var de=_e(ie);return de==d||de==m||de==n||de==x}function lf(ie){return typeof ie=="number"&&ie>-1&&ie%1==0&&ie<=s}function li(ie){var de=typeof ie;return ie!=null&&(de=="object"||de=="function")}function Ts(ie){return ie!=null&&typeof ie=="object"}function bv(ie){if(!Ts(ie)||_e(ie)!=g)return!1;var de=Ne(ie);if(de===null)return!0;var ge=me.call(de,"constructor")&&de.constructor;return typeof ge=="function"&&ge instanceof ge&&ce.call(ge)==Me}var cf=J?ee(J):Re;function gv(ie){return ur(ie,uf(ie))}function uf(ie){return Hn(ie)?Qt(ie):ht(ie)}var vv=Nr(function(ie,de,ge,Ve){st(ie,de,ge,Ve)});function yv(ie){return function(){return ie}}function df(ie){return ie}function wv(){return!1}t.exports=vv}(Fs,Fs.exports)),Fs.exports}var Fy=Dy();const gn=ku(Fy);var By=t=>/!(important)?$/.test(t),jf=t=>typeof t=="string"?t.replace(/!(important)?$/,"").trim():t,Ly=(t,r)=>e=>{const a=String(r),f=By(a),c=jf(a),s=t?`${t}.${c}`:c;let l=kr(e.__cssMap)&&s in e.__cssMap?e.__cssMap[s].varRef:r;return l=jf(l),f?`${l} !important`:l};function Iu(t){const{scale:r,transform:e,compose:a}=t;return(c,s)=>{var l;const i=Ly(r,c)(s);let n=(l=e?.(i,s))!=null?l:i;return a&&(n=a(n,s)),n}}var Jo=(...t)=>r=>t.reduce((e,a)=>a(e),r);function zr(t,r){return e=>{const a={property:e,scale:t};return a.transform=Iu({scale:t,transform:r}),a}}var $y=({rtl:t,ltr:r})=>e=>e.direction==="rtl"?t:r;function zy(t){const{property:r,scale:e,transform:a}=t;return{scale:e,property:$y(r),transform:e?Iu({scale:e,compose:a}):a}}var Jm=["rotate(var(--chakra-rotate, 0))","scaleX(var(--chakra-scale-x, 1))","scaleY(var(--chakra-scale-y, 1))","skewX(var(--chakra-skew-x, 0))","skewY(var(--chakra-skew-y, 0))"];function Vy(){return["translateX(var(--chakra-translate-x, 0))","translateY(var(--chakra-translate-y, 0))",...Jm].join(" ")}function Uy(){return["translate3d(var(--chakra-translate-x, 0), var(--chakra-translate-y, 0), 0)",...Jm].join(" ")}var Wy={"--chakra-blur":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-brightness":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-contrast":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-grayscale":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-hue-rotate":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-invert":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-saturate":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-sepia":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-drop-shadow":"var(--chakra-empty,/*!*/ /*!*/)",filter:["var(--chakra-blur)","var(--chakra-brightness)","var(--chakra-contrast)","var(--chakra-grayscale)","var(--chakra-hue-rotate)","var(--chakra-invert)","var(--chakra-saturate)","var(--chakra-sepia)","var(--chakra-drop-shadow)"].join(" ")},Hy={backdropFilter:["var(--chakra-backdrop-blur)","var(--chakra-backdrop-brightness)","var(--chakra-backdrop-contrast)","var(--chakra-backdrop-grayscale)","var(--chakra-backdrop-hue-rotate)","var(--chakra-backdrop-invert)","var(--chakra-backdrop-opacity)","var(--chakra-backdrop-saturate)","var(--chakra-backdrop-sepia)"].join(" "),"--chakra-backdrop-blur":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-brightness":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-contrast":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-grayscale":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-hue-rotate":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-invert":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-opacity":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-saturate":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-backdrop-sepia":"var(--chakra-empty,/*!*/ /*!*/)"};function qy(t){return{"--chakra-ring-offset-shadow":"var(--chakra-ring-inset) 0 0 0 var(--chakra-ring-offset-width) var(--chakra-ring-offset-color)","--chakra-ring-shadow":"var(--chakra-ring-inset) 0 0 0 calc(var(--chakra-ring-width) + var(--chakra-ring-offset-width)) var(--chakra-ring-color)","--chakra-ring-width":t,boxShadow:["var(--chakra-ring-offset-shadow)","var(--chakra-ring-shadow)","var(--chakra-shadow, 0 0 #0000)"].join(", ")}}var Xy={"row-reverse":{space:"--chakra-space-x-reverse",divide:"--chakra-divide-x-reverse"},"column-reverse":{space:"--chakra-space-y-reverse",divide:"--chakra-divide-y-reverse"}},Cc={"to-t":"to top","to-tr":"to top right","to-r":"to right","to-br":"to bottom right","to-b":"to bottom","to-bl":"to bottom left","to-l":"to left","to-tl":"to top left"},Ky=new Set(Object.values(Cc)),Tc=new Set(["none","-moz-initial","inherit","initial","revert","unset"]),Gy=t=>t.trim();function Yy(t,r){if(t==null||Tc.has(t))return t;if(!(Ec(t)||Tc.has(t)))return`url('${t}')`;const f=/(^[a-z-A-Z]+)\((.*)\)/g.exec(t),c=f?.[1],s=f?.[2];if(!c||!s)return t;const l=c.includes("-gradient")?c:`${c}-gradient`,[i,...n]=s.split(",").map(Gy).filter(Boolean);if(n?.length===0)return t;const o=i in Cc?Cc[i]:i;n.unshift(o);const h=n.map(u=>{if(Ky.has(u))return u;const d=u.indexOf(" "),[m,b]=d!==-1?[u.substr(0,d),u.substr(d+1)]:[u],p=Ec(b)?b:b&&b.split(" "),v=`colors.${m}`,g=v in r.__cssMap?r.__cssMap[v].varRef:m;return p?[g,...Array.isArray(p)?p:[p]].join(" "):g});return`${l}(${h.join(", ")})`}var Ec=t=>typeof t=="string"&&t.includes("(")&&t.includes(")"),Zy=(t,r)=>Yy(t,r??{});function Jy(t){return/^var\(--.+\)$/.test(t)}var Qy=t=>{const r=parseFloat(t.toString()),e=t.toString().replace(String(r),"");return{unitless:!e,value:r,unit:e}},dn=t=>r=>`${t}(${r})`,gt={filter(t){return t!=="auto"?t:Wy},backdropFilter(t){return t!=="auto"?t:Hy},ring(t){return qy(gt.px(t))},bgClip(t){return t==="text"?{color:"transparent",backgroundClip:"text"}:{backgroundClip:t}},transform(t){return t==="auto"?Vy():t==="auto-gpu"?Uy():t},vh(t){return t==="$100vh"?"var(--chakra-vh)":t},px(t){if(t==null)return t;const{unitless:r}=Qy(t);return r||typeof t=="number"?`${t}px`:t},fraction(t){return typeof t!="number"||t>1?t:`${t*100}%`},float(t,r){const e={left:"right",right:"left"};return r.direction==="rtl"?e[t]:t},degree(t){if(Jy(t)||t==null)return t;const r=typeof t=="string"&&!t.endsWith("deg");return typeof t=="number"||r?`${t}deg`:t},gradient:Zy,blur:dn("blur"),opacity:dn("opacity"),brightness:dn("brightness"),contrast:dn("contrast"),dropShadow:dn("drop-shadow"),grayscale:dn("grayscale"),hueRotate:t=>dn("hue-rotate")(gt.degree(t)),invert:dn("invert"),saturate:dn("saturate"),sepia:dn("sepia"),bgImage(t){return t==null||Ec(t)||Tc.has(t)?t:`url(${t})`},outline(t){const r=String(t)==="0"||String(t)==="none";return t!==null&&r?{outline:"2px solid transparent",outlineOffset:"2px"}:{outline:t}},flexDirection(t){var r;const{space:e,divide:a}=(r=Xy[t])!=null?r:{},f={flexDirection:t};return e&&(f[e]=1),a&&(f[a]=1),f}},ue={borderWidths:zr("borderWidths"),borderStyles:zr("borderStyles"),colors:zr("colors"),borders:zr("borders"),gradients:zr("gradients",gt.gradient),radii:zr("radii",gt.px),space:zr("space",Jo(gt.vh,gt.px)),spaceT:zr("space",Jo(gt.vh,gt.px)),degreeT(t){return{property:t,transform:gt.degree}},prop(t,r,e){return{property:t,scale:r,...r&&{transform:Iu({scale:r,transform:e})}}},propT(t,r){return{property:t,transform:r}},sizes:zr("sizes",Jo(gt.vh,gt.px)),sizesT:zr("sizes",Jo(gt.vh,gt.fraction)),shadows:zr("shadows"),logical:zy,blur:zr("blur",gt.blur)},ya={background:ue.colors("background"),backgroundColor:ue.colors("backgroundColor"),backgroundImage:ue.gradients("backgroundImage"),backgroundSize:!0,backgroundPosition:!0,backgroundRepeat:!0,backgroundAttachment:!0,backgroundClip:{transform:gt.bgClip},bgSize:ue.prop("backgroundSize"),bgPosition:ue.prop("backgroundPosition"),bg:ue.colors("background"),bgColor:ue.colors("backgroundColor"),bgPos:ue.prop("backgroundPosition"),bgRepeat:ue.prop("backgroundRepeat"),bgAttachment:ue.prop("backgroundAttachment"),bgGradient:ue.gradients("backgroundImage"),bgClip:{transform:gt.bgClip}};Object.assign(ya,{bgImage:ya.backgroundImage,bgImg:ya.backgroundImage});var At={border:ue.borders("border"),borderWidth:ue.borderWidths("borderWidth"),borderStyle:ue.borderStyles("borderStyle"),borderColor:ue.colors("borderColor"),borderRadius:ue.radii("borderRadius"),borderTop:ue.borders("borderTop"),borderBlockStart:ue.borders("borderBlockStart"),borderTopLeftRadius:ue.radii("borderTopLeftRadius"),borderStartStartRadius:ue.logical({scale:"radii",property:{ltr:"borderTopLeftRadius",rtl:"borderTopRightRadius"}}),borderEndStartRadius:ue.logical({scale:"radii",property:{ltr:"borderBottomLeftRadius",rtl:"borderBottomRightRadius"}}),borderTopRightRadius:ue.radii("borderTopRightRadius"),borderStartEndRadius:ue.logical({scale:"radii",property:{ltr:"borderTopRightRadius",rtl:"borderTopLeftRadius"}}),borderEndEndRadius:ue.logical({scale:"radii",property:{ltr:"borderBottomRightRadius",rtl:"borderBottomLeftRadius"}}),borderRight:ue.borders("borderRight"),borderInlineEnd:ue.borders("borderInlineEnd"),borderBottom:ue.borders("borderBottom"),borderBlockEnd:ue.borders("borderBlockEnd"),borderBottomLeftRadius:ue.radii("borderBottomLeftRadius"),borderBottomRightRadius:ue.radii("borderBottomRightRadius"),borderLeft:ue.borders("borderLeft"),borderInlineStart:{property:"borderInlineStart",scale:"borders"},borderInlineStartRadius:ue.logical({scale:"radii",property:{ltr:["borderTopLeftRadius","borderBottomLeftRadius"],rtl:["borderTopRightRadius","borderBottomRightRadius"]}}),borderInlineEndRadius:ue.logical({scale:"radii",property:{ltr:["borderTopRightRadius","borderBottomRightRadius"],rtl:["borderTopLeftRadius","borderBottomLeftRadius"]}}),borderX:ue.borders(["borderLeft","borderRight"]),borderInline:ue.borders("borderInline"),borderY:ue.borders(["borderTop","borderBottom"]),borderBlock:ue.borders("borderBlock"),borderTopWidth:ue.borderWidths("borderTopWidth"),borderBlockStartWidth:ue.borderWidths("borderBlockStartWidth"),borderTopColor:ue.colors("borderTopColor"),borderBlockStartColor:ue.colors("borderBlockStartColor"),borderTopStyle:ue.borderStyles("borderTopStyle"),borderBlockStartStyle:ue.borderStyles("borderBlockStartStyle"),borderBottomWidth:ue.borderWidths("borderBottomWidth"),borderBlockEndWidth:ue.borderWidths("borderBlockEndWidth"),borderBottomColor:ue.colors("borderBottomColor"),borderBlockEndColor:ue.colors("borderBlockEndColor"),borderBottomStyle:ue.borderStyles("borderBottomStyle"),borderBlockEndStyle:ue.borderStyles("borderBlockEndStyle"),borderLeftWidth:ue.borderWidths("borderLeftWidth"),borderInlineStartWidth:ue.borderWidths("borderInlineStartWidth"),borderLeftColor:ue.colors("borderLeftColor"),borderInlineStartColor:ue.colors("borderInlineStartColor"),borderLeftStyle:ue.borderStyles("borderLeftStyle"),borderInlineStartStyle:ue.borderStyles("borderInlineStartStyle"),borderRightWidth:ue.borderWidths("borderRightWidth"),borderInlineEndWidth:ue.borderWidths("borderInlineEndWidth"),borderRightColor:ue.colors("borderRightColor"),borderInlineEndColor:ue.colors("borderInlineEndColor"),borderRightStyle:ue.borderStyles("borderRightStyle"),borderInlineEndStyle:ue.borderStyles("borderInlineEndStyle"),borderTopRadius:ue.radii(["borderTopLeftRadius","borderTopRightRadius"]),borderBottomRadius:ue.radii(["borderBottomLeftRadius","borderBottomRightRadius"]),borderLeftRadius:ue.radii(["borderTopLeftRadius","borderBottomLeftRadius"]),borderRightRadius:ue.radii(["borderTopRightRadius","borderBottomRightRadius"])};Object.assign(At,{rounded:At.borderRadius,roundedTop:At.borderTopRadius,roundedTopLeft:At.borderTopLeftRadius,roundedTopRight:At.borderTopRightRadius,roundedTopStart:At.borderStartStartRadius,roundedTopEnd:At.borderStartEndRadius,roundedBottom:At.borderBottomRadius,roundedBottomLeft:At.borderBottomLeftRadius,roundedBottomRight:At.borderBottomRightRadius,roundedBottomStart:At.borderEndStartRadius,roundedBottomEnd:At.borderEndEndRadius,roundedLeft:At.borderLeftRadius,roundedRight:At.borderRightRadius,roundedStart:At.borderInlineStartRadius,roundedEnd:At.borderInlineEndRadius,borderStart:At.borderInlineStart,borderEnd:At.borderInlineEnd,borderTopStartRadius:At.borderStartStartRadius,borderTopEndRadius:At.borderStartEndRadius,borderBottomStartRadius:At.borderEndStartRadius,borderBottomEndRadius:At.borderEndEndRadius,borderStartRadius:At.borderInlineStartRadius,borderEndRadius:At.borderInlineEndRadius,borderStartWidth:At.borderInlineStartWidth,borderEndWidth:At.borderInlineEndWidth,borderStartColor:At.borderInlineStartColor,borderEndColor:At.borderInlineEndColor,borderStartStyle:At.borderInlineStartStyle,borderEndStyle:At.borderInlineEndStyle});var ew={color:ue.colors("color"),textColor:ue.colors("color"),fill:ue.colors("fill"),stroke:ue.colors("stroke")},Ac={boxShadow:ue.shadows("boxShadow"),mixBlendMode:!0,blendMode:ue.prop("mixBlendMode"),backgroundBlendMode:!0,bgBlendMode:ue.prop("backgroundBlendMode"),opacity:!0};Object.assign(Ac,{shadow:Ac.boxShadow});var tw={filter:{transform:gt.filter},blur:ue.blur("--chakra-blur"),brightness:ue.propT("--chakra-brightness",gt.brightness),contrast:ue.propT("--chakra-contrast",gt.contrast),hueRotate:ue.propT("--chakra-hue-rotate",gt.hueRotate),invert:ue.propT("--chakra-invert",gt.invert),saturate:ue.propT("--chakra-saturate",gt.saturate),dropShadow:ue.propT("--chakra-drop-shadow",gt.dropShadow),backdropFilter:{transform:gt.backdropFilter},backdropBlur:ue.blur("--chakra-backdrop-blur"),backdropBrightness:ue.propT("--chakra-backdrop-brightness",gt.brightness),backdropContrast:ue.propT("--chakra-backdrop-contrast",gt.contrast),backdropHueRotate:ue.propT("--chakra-backdrop-hue-rotate",gt.hueRotate),backdropInvert:ue.propT("--chakra-backdrop-invert",gt.invert),backdropSaturate:ue.propT("--chakra-backdrop-saturate",gt.saturate)},La={alignItems:!0,alignContent:!0,justifyItems:!0,justifyContent:!0,flexWrap:!0,flexDirection:{transform:gt.flexDirection},flex:!0,flexFlow:!0,flexGrow:!0,flexShrink:!0,flexBasis:ue.sizes("flexBasis"),justifySelf:!0,alignSelf:!0,order:!0,placeItems:!0,placeContent:!0,placeSelf:!0,gap:ue.space("gap"),rowGap:ue.space("rowGap"),columnGap:ue.space("columnGap")};Object.assign(La,{flexDir:La.flexDirection});var Qm={gridGap:ue.space("gridGap"),gridColumnGap:ue.space("gridColumnGap"),gridRowGap:ue.space("gridRowGap"),gridColumn:!0,gridRow:!0,gridAutoFlow:!0,gridAutoColumns:!0,gridColumnStart:!0,gridColumnEnd:!0,gridRowStart:!0,gridRowEnd:!0,gridAutoRows:!0,gridTemplate:!0,gridTemplateColumns:!0,gridTemplateRows:!0,gridTemplateAreas:!0,gridArea:!0},rw={appearance:!0,cursor:!0,resize:!0,userSelect:!0,pointerEvents:!0,outline:{transform:gt.outline},outlineOffset:!0,outlineColor:ue.colors("outlineColor")},Wr={width:ue.sizesT("width"),inlineSize:ue.sizesT("inlineSize"),height:ue.sizes("height"),blockSize:ue.sizes("blockSize"),boxSize:ue.sizes(["width","height"]),minWidth:ue.sizes("minWidth"),minInlineSize:ue.sizes("minInlineSize"),minHeight:ue.sizes("minHeight"),minBlockSize:ue.sizes("minBlockSize"),maxWidth:ue.sizes("maxWidth"),maxInlineSize:ue.sizes("maxInlineSize"),maxHeight:ue.sizes("maxHeight"),maxBlockSize:ue.sizes("maxBlockSize"),overflow:!0,overflowX:!0,overflowY:!0,overscrollBehavior:!0,overscrollBehaviorX:!0,overscrollBehaviorY:!0,display:!0,aspectRatio:!0,hideFrom:{scale:"breakpoints",transform:(t,r)=>{var e,a,f;return{[`@media screen and (min-width: ${(f=(a=(e=r.__breakpoints)==null?void 0:e.get(t))==null?void 0:a.minW)!=null?f:t})`]:{display:"none"}}}},hideBelow:{scale:"breakpoints",transform:(t,r)=>{var e,a,f;return{[`@media screen and (max-width: ${(f=(a=(e=r.__breakpoints)==null?void 0:e.get(t))==null?void 0:a._minW)!=null?f:t})`]:{display:"none"}}}},verticalAlign:!0,boxSizing:!0,boxDecorationBreak:!0,float:ue.propT("float",gt.float),objectFit:!0,objectPosition:!0,visibility:!0,isolation:!0};Object.assign(Wr,{w:Wr.width,h:Wr.height,minW:Wr.minWidth,maxW:Wr.maxWidth,minH:Wr.minHeight,maxH:Wr.maxHeight,overscroll:Wr.overscrollBehavior,overscrollX:Wr.overscrollBehaviorX,overscrollY:Wr.overscrollBehaviorY});var nw={listStyleType:!0,listStylePosition:!0,listStylePos:ue.prop("listStylePosition"),listStyleImage:!0,listStyleImg:ue.prop("listStyleImage")};function iw(t,r,e,a){const f=typeof r=="string"?r.split("."):[r];for(a=0;a<f.length&&t;a+=1)t=t[f[a]];return t===void 0?e:t}var sw=t=>{const r=new WeakMap;return(a,f,c,s)=>{if(typeof a>"u")return t(a,f,c);r.has(a)||r.set(a,new Map);const l=r.get(a);if(l.has(f))return l.get(f);const i=t(a,f,c,s);return l.set(f,i),i}},ow=sw(iw),aw={border:"0px",clip:"rect(0, 0, 0, 0)",width:"1px",height:"1px",margin:"-1px",padding:"0px",overflow:"hidden",whiteSpace:"nowrap",position:"absolute"},lw={position:"static",width:"auto",height:"auto",clip:"auto",padding:"0",margin:"0",overflow:"visible",whiteSpace:"normal"},jl=(t,r,e)=>{const a={},f=ow(t,r,{});for(const c in f)c in e&&e[c]!=null||(a[c]=f[c]);return a},cw={srOnly:{transform(t){return t===!0?aw:t==="focusable"?lw:{}}},layerStyle:{processResult:!0,transform:(t,r,e)=>jl(r,`layerStyles.${t}`,e)},textStyle:{processResult:!0,transform:(t,r,e)=>jl(r,`textStyles.${t}`,e)},apply:{processResult:!0,transform:(t,r,e)=>jl(r,t,e)}},Ys={position:!0,pos:ue.prop("position"),zIndex:ue.prop("zIndex","zIndices"),inset:ue.spaceT("inset"),insetX:ue.spaceT(["left","right"]),insetInline:ue.spaceT("insetInline"),insetY:ue.spaceT(["top","bottom"]),insetBlock:ue.spaceT("insetBlock"),top:ue.spaceT("top"),insetBlockStart:ue.spaceT("insetBlockStart"),bottom:ue.spaceT("bottom"),insetBlockEnd:ue.spaceT("insetBlockEnd"),left:ue.spaceT("left"),insetInlineStart:ue.logical({scale:"space",property:{ltr:"left",rtl:"right"}}),right:ue.spaceT("right"),insetInlineEnd:ue.logical({scale:"space",property:{ltr:"right",rtl:"left"}})};Object.assign(Ys,{insetStart:Ys.insetInlineStart,insetEnd:Ys.insetInlineEnd});var uw={ring:{transform:gt.ring},ringColor:ue.colors("--chakra-ring-color"),ringOffset:ue.prop("--chakra-ring-offset-width"),ringOffsetColor:ue.colors("--chakra-ring-offset-color"),ringInset:ue.prop("--chakra-ring-inset")},Ut={margin:ue.spaceT("margin"),marginTop:ue.spaceT("marginTop"),marginBlockStart:ue.spaceT("marginBlockStart"),marginRight:ue.spaceT("marginRight"),marginInlineEnd:ue.spaceT("marginInlineEnd"),marginBottom:ue.spaceT("marginBottom"),marginBlockEnd:ue.spaceT("marginBlockEnd"),marginLeft:ue.spaceT("marginLeft"),marginInlineStart:ue.spaceT("marginInlineStart"),marginX:ue.spaceT(["marginInlineStart","marginInlineEnd"]),marginInline:ue.spaceT("marginInline"),marginY:ue.spaceT(["marginTop","marginBottom"]),marginBlock:ue.spaceT("marginBlock"),padding:ue.space("padding"),paddingTop:ue.space("paddingTop"),paddingBlockStart:ue.space("paddingBlockStart"),paddingRight:ue.space("paddingRight"),paddingBottom:ue.space("paddingBottom"),paddingBlockEnd:ue.space("paddingBlockEnd"),paddingLeft:ue.space("paddingLeft"),paddingInlineStart:ue.space("paddingInlineStart"),paddingInlineEnd:ue.space("paddingInlineEnd"),paddingX:ue.space(["paddingInlineStart","paddingInlineEnd"]),paddingInline:ue.space("paddingInline"),paddingY:ue.space(["paddingTop","paddingBottom"]),paddingBlock:ue.space("paddingBlock")};Object.assign(Ut,{m:Ut.margin,mt:Ut.marginTop,mr:Ut.marginRight,me:Ut.marginInlineEnd,marginEnd:Ut.marginInlineEnd,mb:Ut.marginBottom,ml:Ut.marginLeft,ms:Ut.marginInlineStart,marginStart:Ut.marginInlineStart,mx:Ut.marginX,my:Ut.marginY,p:Ut.padding,pt:Ut.paddingTop,py:Ut.paddingY,px:Ut.paddingX,pb:Ut.paddingBottom,pl:Ut.paddingLeft,ps:Ut.paddingInlineStart,paddingStart:Ut.paddingInlineStart,pr:Ut.paddingRight,pe:Ut.paddingInlineEnd,paddingEnd:Ut.paddingInlineEnd});var dw={textDecorationColor:ue.colors("textDecorationColor"),textDecoration:!0,textDecor:{property:"textDecoration"},textDecorationLine:!0,textDecorationStyle:!0,textDecorationThickness:!0,textUnderlineOffset:!0,textShadow:ue.shadows("textShadow")},fw={clipPath:!0,transform:ue.propT("transform",gt.transform),transformOrigin:!0,translateX:ue.spaceT("--chakra-translate-x"),translateY:ue.spaceT("--chakra-translate-y"),skewX:ue.degreeT("--chakra-skew-x"),skewY:ue.degreeT("--chakra-skew-y"),scaleX:ue.prop("--chakra-scale-x"),scaleY:ue.prop("--chakra-scale-y"),scale:ue.prop(["--chakra-scale-x","--chakra-scale-y"]),rotate:ue.degreeT("--chakra-rotate")},hw={transition:!0,transitionDelay:!0,animation:!0,willChange:!0,transitionDuration:ue.prop("transitionDuration","transition.duration"),transitionProperty:ue.prop("transitionProperty","transition.property"),transitionTimingFunction:ue.prop("transitionTimingFunction","transition.easing")},pw={fontFamily:ue.prop("fontFamily","fonts"),fontSize:ue.prop("fontSize","fontSizes",gt.px),fontWeight:ue.prop("fontWeight","fontWeights"),lineHeight:ue.prop("lineHeight","lineHeights"),letterSpacing:ue.prop("letterSpacing","letterSpacings"),textAlign:!0,fontStyle:!0,textIndent:!0,wordBreak:!0,overflowWrap:!0,textOverflow:!0,textTransform:!0,whiteSpace:!0,isTruncated:{transform(t){if(t===!0)return{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}}},noOfLines:{static:{overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:"var(--chakra-line-clamp)"},property:"--chakra-line-clamp"}},mw={scrollBehavior:!0,scrollSnapAlign:!0,scrollSnapStop:!0,scrollSnapType:!0,scrollMargin:ue.spaceT("scrollMargin"),scrollMarginTop:ue.spaceT("scrollMarginTop"),scrollMarginBottom:ue.spaceT("scrollMarginBottom"),scrollMarginLeft:ue.spaceT("scrollMarginLeft"),scrollMarginRight:ue.spaceT("scrollMarginRight"),scrollMarginX:ue.spaceT(["scrollMarginLeft","scrollMarginRight"]),scrollMarginY:ue.spaceT(["scrollMarginTop","scrollMarginBottom"]),scrollPadding:ue.spaceT("scrollPadding"),scrollPaddingTop:ue.spaceT("scrollPaddingTop"),scrollPaddingBottom:ue.spaceT("scrollPaddingBottom"),scrollPaddingLeft:ue.spaceT("scrollPaddingLeft"),scrollPaddingRight:ue.spaceT("scrollPaddingRight"),scrollPaddingX:ue.spaceT(["scrollPaddingLeft","scrollPaddingRight"]),scrollPaddingY:ue.spaceT(["scrollPaddingTop","scrollPaddingBottom"])};function e0(t){return kr(t)&&t.reference?t.reference:String(t)}var sl=(t,...r)=>r.map(e0).join(` ${t} `).replace(/calc/g,""),Pf=(...t)=>`calc(${sl("+",...t)})`,Rf=(...t)=>`calc(${sl("-",...t)})`,Mc=(...t)=>`calc(${sl("*",...t)})`,If=(...t)=>`calc(${sl("/",...t)})`,Of=t=>{const r=e0(t);return r!=null&&!Number.isNaN(parseFloat(r))?String(r).startsWith("-")?String(r).slice(1):`-${r}`:Mc(r,-1)},di=Object.assign(t=>({add:(...r)=>di(Pf(t,...r)),subtract:(...r)=>di(Rf(t,...r)),multiply:(...r)=>di(Mc(t,...r)),divide:(...r)=>di(If(t,...r)),negate:()=>di(Of(t)),toString:()=>t.toString()}),{add:Pf,subtract:Rf,multiply:Mc,divide:If,negate:Of});function bw(t,r="-"){return t.replace(/\s+/g,r)}function gw(t){const r=bw(t.toString());return yw(vw(r))}function vw(t){return t.includes("\\.")?t:!Number.isInteger(parseFloat(t.toString()))?t.replace(".","\\."):t}function yw(t){return t.replace(/[!-,/:-@[-^`{-~]/g,"\\$&")}function ww(t,r=""){return[r,t].filter(Boolean).join("-")}function xw(t,r){return`var(${t}${r?`, ${r}`:""})`}function _w(t,r=""){return gw(`--${ww(t,r)}`)}function Ze(t,r,e){const a=_w(t,e);return{variable:a,reference:xw(a,r)}}function Sw(t,r){const e={};for(const a of r){if(Array.isArray(a)){const[f,c]=a;e[f]=Ze(`${t}-${f}`,c);continue}e[a]=Ze(`${t}-${a}`)}return e}function kw(t){const r=t==null?0:t.length;return r?t[r-1]:void 0}function Cw(t){const r=parseFloat(t.toString()),e=t.toString().replace(String(r),"");return{unitless:!e,value:r,unit:e}}function jc(t){if(t==null)return t;const{unitless:r}=Cw(t);return r||typeof t=="number"?`${t}px`:t}var t0=(t,r)=>parseInt(t[1],10)>parseInt(r[1],10)?1:-1,Ou=t=>Object.fromEntries(Object.entries(t).sort(t0));function Nf(t){const r=Ou(t);return Object.assign(Object.values(r),r)}function Tw(t){const r=Object.keys(Ou(t));return new Set(r)}function Df(t){var r;if(!t)return t;t=(r=jc(t))!=null?r:t;const e=-.02;return typeof t=="number"?`${t+e}`:t.replace(/(\d+\.?\d*)/u,a=>`${parseFloat(a)+e}`)}function Bs(t,r){const e=["@media screen"];return t&&e.push("and",`(min-width: ${jc(t)})`),r&&e.push("and",`(max-width: ${jc(r)})`),e.join(" ")}function Ew(t){var r;if(!t)return null;t.base=(r=t.base)!=null?r:"0px";const e=Nf(t),a=Object.entries(t).sort(t0).map(([s,l],i,n)=>{var o;let[,h]=(o=n[i+1])!=null?o:[];return h=parseFloat(h)>0?Df(h):void 0,{_minW:Df(l),breakpoint:s,minW:l,maxW:h,maxWQuery:Bs(null,h),minWQuery:Bs(l),minMaxQuery:Bs(l,h)}}),f=Tw(t),c=Array.from(f.values());return{keys:f,normalized:e,isResponsive(s){const l=Object.keys(s);return l.length>0&&l.every(i=>f.has(i))},asObject:Ou(t),asArray:Nf(t),details:a,get(s){return a.find(l=>l.breakpoint===s)},media:[null,...e.map(s=>Bs(s)).slice(1)],toArrayValue(s){if(!kr(s))throw new Error("toArrayValue: value must be an object");const l=c.map(i=>{var n;return(n=s[i])!=null?n:null});for(;kw(l)===null;)l.pop();return l},toObjectValue(s){if(!Array.isArray(s))throw new Error("toObjectValue: value must be an array");return s.reduce((l,i,n)=>{const o=c[n];return o!=null&&i!=null&&(l[o]=i),l},{})}}}var dr={hover:(t,r)=>`${t}:hover ${r}, ${t}[data-hover] ${r}`,focus:(t,r)=>`${t}:focus ${r}, ${t}[data-focus] ${r}`,focusVisible:(t,r)=>`${t}:focus-visible ${r}`,focusWithin:(t,r)=>`${t}:focus-within ${r}`,active:(t,r)=>`${t}:active ${r}, ${t}[data-active] ${r}`,disabled:(t,r)=>`${t}:disabled ${r}, ${t}[data-disabled] ${r}`,invalid:(t,r)=>`${t}:invalid ${r}, ${t}[data-invalid] ${r}`,checked:(t,r)=>`${t}:checked ${r}, ${t}[data-checked] ${r}`,placeholderShown:(t,r)=>`${t}:placeholder-shown ${r}`},Xn=t=>r0(r=>t(r,"&"),"[role=group]","[data-group]",".group"),jn=t=>r0(r=>t(r,"~ &"),"[data-peer]",".peer"),r0=(t,...r)=>r.map(t).join(", "),ol={_hover:"&:hover, &[data-hover]",_active:"&:active, &[data-active]",_focus:"&:focus, &[data-focus]",_highlighted:"&[data-highlighted]",_focusWithin:"&:focus-within",_focusVisible:"&:focus-visible, &[data-focus-visible]",_disabled:"&:disabled, &[disabled], &[aria-disabled=true], &[data-disabled]",_readOnly:"&[aria-readonly=true], &[readonly], &[data-readonly]",_before:"&::before",_after:"&::after",_empty:"&:empty",_expanded:"&[aria-expanded=true], &[data-expanded]",_checked:"&[aria-checked=true], &[data-checked]",_grabbed:"&[aria-grabbed=true], &[data-grabbed]",_pressed:"&[aria-pressed=true], &[data-pressed]",_invalid:"&[aria-invalid=true], &[data-invalid]",_valid:"&[data-valid], &[data-state=valid]",_loading:"&[data-loading], &[aria-busy=true]",_selected:"&[aria-selected=true], &[data-selected]",_hidden:"&[hidden], &[data-hidden]",_autofill:"&:-webkit-autofill",_even:"&:nth-of-type(even)",_odd:"&:nth-of-type(odd)",_first:"&:first-of-type",_firstLetter:"&::first-letter",_last:"&:last-of-type",_notFirst:"&:not(:first-of-type)",_notLast:"&:not(:last-of-type)",_visited:"&:visited",_activeLink:"&[aria-current=page]",_activeStep:"&[aria-current=step]",_indeterminate:"&:indeterminate, &[aria-checked=mixed], &[data-indeterminate]",_groupHover:Xn(dr.hover),_peerHover:jn(dr.hover),_groupFocus:Xn(dr.focus),_peerFocus:jn(dr.focus),_groupFocusVisible:Xn(dr.focusVisible),_peerFocusVisible:jn(dr.focusVisible),_groupActive:Xn(dr.active),_peerActive:jn(dr.active),_groupDisabled:Xn(dr.disabled),_peerDisabled:jn(dr.disabled),_groupInvalid:Xn(dr.invalid),_peerInvalid:jn(dr.invalid),_groupChecked:Xn(dr.checked),_peerChecked:jn(dr.checked),_groupFocusWithin:Xn(dr.focusWithin),_peerFocusWithin:jn(dr.focusWithin),_peerPlaceholderShown:jn(dr.placeholderShown),_placeholder:"&::placeholder",_placeholderShown:"&:placeholder-shown",_fullScreen:"&:fullscreen",_selection:"&::selection",_rtl:"[dir=rtl] &, &[dir=rtl]",_ltr:"[dir=ltr] &, &[dir=ltr]",_mediaDark:"@media (prefers-color-scheme: dark)",_mediaReduceMotion:"@media (prefers-reduced-motion: reduce)",_dark:".chakra-ui-dark &:not([data-theme]),[data-theme=dark] &:not([data-theme]),&[data-theme=dark]",_light:".chakra-ui-light &:not([data-theme]),[data-theme=light] &:not([data-theme]),&[data-theme=light]",_horizontal:"&[data-orientation=horizontal]",_vertical:"&[data-orientation=vertical]"},n0=Object.keys(ol);function Ff(t,r){return Ze(String(t).replace(/\./g,"-"),void 0,r)}function Aw(t,r){let e={};const a={};for(const[f,c]of Object.entries(t)){const{isSemantic:s,value:l}=c,{variable:i,reference:n}=Ff(f,r?.cssVarPrefix);if(!s){if(f.startsWith("space")){const u=f.split("."),[d,...m]=u,b=`${d}.-${m.join(".")}`,p=di.negate(l),v=di.negate(n);a[b]={value:p,var:i,varRef:v}}e[i]=l,a[f]={value:l,var:i,varRef:n};continue}const o=u=>{const m=[String(f).split(".")[0],u].join(".");if(!t[m])return u;const{reference:p}=Ff(m,r?.cssVarPrefix);return p},h=kr(l)?l:{default:l};e=gn(e,Object.entries(h).reduce((u,[d,m])=>{var b,p;if(!m)return u;const v=o(`${m}`);if(d==="default")return u[i]=v,u;const g=(p=(b=ol)==null?void 0:b[d])!=null?p:d;return u[g]={[i]:v},u},{})),a[f]={value:n,var:i,varRef:n}}return{cssVars:e,cssMap:a}}function Mw(t,r=[]){const e=Object.assign({},t);for(const a of r)a in e&&delete e[a];return e}function jw(t,r){const e={};for(const a of r)a in t&&(e[a]=t[a]);return e}function Pw(t){return typeof t=="object"&&t!=null&&!Array.isArray(t)}function Bf(t,r,e={}){const{stop:a,getKey:f}=e;function c(s,l=[]){var i;if(Pw(s)||Array.isArray(s)){const n={};for(const[o,h]of Object.entries(s)){const u=(i=f?.(o))!=null?i:o,d=[...l,u];if(a?.(s,d))return r(s,l);n[u]=c(h,d)}return n}return r(s,l)}return c(t)}var Rw=["colors","borders","borderWidths","borderStyles","fonts","fontSizes","fontWeights","gradients","letterSpacings","lineHeights","radii","space","shadows","sizes","zIndices","transition","blur","breakpoints"];function Iw(t){return jw(t,Rw)}function Ow(t){return t.semanticTokens}function Nw(t){const{__cssMap:r,__cssVars:e,__breakpoints:a,...f}=t;return f}var Dw=t=>n0.includes(t)||t==="default";function Fw({tokens:t,semanticTokens:r}){const e={};return Bf(t,(a,f)=>{a!=null&&(e[f.join(".")]={isSemantic:!1,value:a})}),Bf(r,(a,f)=>{a!=null&&(e[f.join(".")]={isSemantic:!0,value:a})},{stop:a=>Object.keys(a).every(Dw)}),e}function Bw(t){var r;const e=Nw(t),a=Iw(e),f=Ow(e),c=Fw({tokens:a,semanticTokens:f}),s=(r=e.config)==null?void 0:r.cssVarPrefix,{cssMap:l,cssVars:i}=Aw(c,{cssVarPrefix:s});return Object.assign(e,{__cssVars:{...{"--chakra-ring-inset":"var(--chakra-empty,/*!*/ /*!*/)","--chakra-ring-offset-width":"0px","--chakra-ring-offset-color":"#fff","--chakra-ring-color":"rgba(66, 153, 225, 0.6)","--chakra-ring-offset-shadow":"0 0 #0000","--chakra-ring-shadow":"0 0 #0000","--chakra-space-x-reverse":"0","--chakra-space-y-reverse":"0"},...i},__cssMap:l,__breakpoints:Ew(e.breakpoints)}),e}var Nu=gn({},ya,At,ew,La,Wr,tw,uw,rw,Qm,cw,Ys,Ac,Ut,mw,pw,dw,fw,nw,hw),Lw=Object.assign({},Ut,Wr,La,Qm,Ys),i0=Object.keys(Lw),$w=[...Object.keys(Nu),...n0],zw={...Nu,...ol},Vw=t=>t in zw,Uw=t=>r=>{if(!r.__breakpoints)return t;const{isResponsive:e,toArrayValue:a,media:f}=r.__breakpoints,c={};for(const s in t){let l=Xr(t[s],r);if(l==null)continue;if(l=kr(l)&&e(l)?a(l):l,!Array.isArray(l)){c[s]=l;continue}const i=l.slice(0,f.length).length;for(let n=0;n<i;n+=1){const o=f?.[n];if(!o){c[s]=l[n];continue}c[o]=c[o]||{},l[n]!=null&&(c[o][s]=l[n])}}return c};function Ww(t){const r=[];let e="",a=!1;for(let f=0;f<t.length;f++){const c=t[f];c==="("?(a=!0,e+=c):c===")"?(a=!1,e+=c):c===","&&!a?(r.push(e),e=""):e+=c}return e=e.trim(),e&&r.push(e),r}function Hw(t){return/^var\(--.+\)$/.test(t)}var qw=(t,r)=>t.startsWith("--")&&typeof r=="string"&&!Hw(r),Xw=(t,r)=>{var e,a;if(r==null)return r;const f=i=>{var n,o;return(o=(n=t.__cssMap)==null?void 0:n[i])==null?void 0:o.varRef},c=i=>{var n;return(n=f(i))!=null?n:i},[s,l]=Ww(r);return r=(a=(e=f(s))!=null?e:c(l))!=null?a:c(r),r};function Kw(t){const{configs:r={},pseudos:e={},theme:a}=t,f=(c,s=!1)=>{var l,i,n;const o=Xr(c,a),h=Uw(o)(a);let u={};for(let d in h){const m=h[d];let b=Xr(m,a);d in e&&(d=e[d]),qw(d,b)&&(b=Xw(a,b));let p=r[d];if(p===!0&&(p={property:d}),kr(b)){u[d]=(l=u[d])!=null?l:{},u[d]=gn({},u[d],f(b,!0));continue}let v=(n=(i=p?.transform)==null?void 0:i.call(p,b,a,o))!=null?n:b;v=p?.processResult?f(v,!0):v;const g=Xr(p?.property,a);if(!s&&p?.static){const x=Xr(p.static,a);u=gn({},u,x)}if(g&&Array.isArray(g)){for(const x of g)u[x]=v;continue}if(g){g==="&"&&kr(v)?u=gn({},u,v):u[g]=v;continue}if(kr(v)){u=gn({},u,v);continue}u[d]=v}return u};return f}var s0=t=>r=>Kw({theme:r,pseudos:ol,configs:Nu})(t);function $t(t){return{definePartsStyle(r){return r},defineMultiStyleConfig(r){return{parts:t,...r}}}}function Gw(t,r){if(Array.isArray(t))return t;if(kr(t))return r(t);if(t!=null)return[t]}function Yw(t,r){for(let e=r+1;e<t.length;e++)if(t[e]!=null)return e;return-1}function Zw(t){const r=t.__breakpoints;return function(a,f,c,s){var l,i;if(!r)return;const n={},o=Gw(c,r.toArrayValue);if(!o)return n;const h=o.length,u=h===1,d=!!a.parts;for(let m=0;m<h;m++){const b=r.details[m],p=r.details[Yw(o,m)],v=Bs(b.minW,p?._minW),g=Xr((l=a[f])==null?void 0:l[o[m]],s);if(g){if(d){(i=a.parts)==null||i.forEach(x=>{gn(n,{[x]:u?g[x]:{[v]:g[x]}})});continue}if(!d){u?gn(n,g):n[v]=g;continue}n[v]=g}}return n}}function Jw(t){return r=>{var e;const{variant:a,size:f,theme:c}=r,s=Zw(c);return gn({},Xr((e=t.baseStyle)!=null?e:{},r),s(t,"sizes",f,r),s(t,"variants",a,r))}}function Qw(t,r,e){var a,f,c;return(c=(f=(a=t.__cssMap)==null?void 0:a[`${r}.${e}`])==null?void 0:f.varRef)!=null?c:e}function Dt(t){return Mw(t,["styleConfig","size","variant","colorScheme"])}var ex={common:"background-color, border-color, color, fill, stroke, opacity, box-shadow, transform",colors:"background-color, border-color, color, fill, stroke",dimensions:"width, height",position:"left, right, top, bottom",background:"background-color, background-image, background-position"},tx={"ease-in":"cubic-bezier(0.4, 0, 1, 1)","ease-out":"cubic-bezier(0, 0, 0.2, 1)","ease-in-out":"cubic-bezier(0.4, 0, 0.2, 1)"},rx={"ultra-fast":"50ms",faster:"100ms",fast:"150ms",normal:"200ms",slow:"300ms",slower:"400ms","ultra-slow":"500ms"},nx={property:ex,easing:tx,duration:rx},ix=nx,sx={hide:-1,auto:"auto",base:0,docked:10,dropdown:1e3,sticky:1100,banner:1200,overlay:1300,modal:1400,popover:1500,skipLink:1600,toast:1700,tooltip:1800},ox=sx,ax={none:0,"1px":"1px solid","2px":"2px solid","4px":"4px solid","8px":"8px solid"},lx=ax,cx={base:"0em",sm:"30em",md:"48em",lg:"62em",xl:"80em","2xl":"96em"},ux=cx,dx={transparent:"transparent",current:"currentColor",black:"#000000",white:"#FFFFFF",whiteAlpha:{50:"rgba(255, 255, 255, 0.04)",100:"rgba(255, 255, 255, 0.06)",200:"rgba(255, 255, 255, 0.08)",300:"rgba(255, 255, 255, 0.16)",400:"rgba(255, 255, 255, 0.24)",500:"rgba(255, 255, 255, 0.36)",600:"rgba(255, 255, 255, 0.48)",700:"rgba(255, 255, 255, 0.64)",800:"rgba(255, 255, 255, 0.80)",900:"rgba(255, 255, 255, 0.92)"},blackAlpha:{50:"rgba(0, 0, 0, 0.04)",100:"rgba(0, 0, 0, 0.06)",200:"rgba(0, 0, 0, 0.08)",300:"rgba(0, 0, 0, 0.16)",400:"rgba(0, 0, 0, 0.24)",500:"rgba(0, 0, 0, 0.36)",600:"rgba(0, 0, 0, 0.48)",700:"rgba(0, 0, 0, 0.64)",800:"rgba(0, 0, 0, 0.80)",900:"rgba(0, 0, 0, 0.92)"},gray:{50:"#F7FAFC",100:"#EDF2F7",200:"#E2E8F0",300:"#CBD5E0",400:"#A0AEC0",500:"#718096",600:"#4A5568",700:"#2D3748",800:"#1A202C",900:"#171923"},red:{50:"#FFF5F5",100:"#FED7D7",200:"#FEB2B2",300:"#FC8181",400:"#F56565",500:"#E53E3E",600:"#C53030",700:"#9B2C2C",800:"#822727",900:"#63171B"},orange:{50:"#FFFAF0",100:"#FEEBC8",200:"#FBD38D",300:"#F6AD55",400:"#ED8936",500:"#DD6B20",600:"#C05621",700:"#9C4221",800:"#7B341E",900:"#652B19"},yellow:{50:"#FFFFF0",100:"#FEFCBF",200:"#FAF089",300:"#F6E05E",400:"#ECC94B",500:"#D69E2E",600:"#B7791F",700:"#975A16",800:"#744210",900:"#5F370E"},green:{50:"#F0FFF4",100:"#C6F6D5",200:"#9AE6B4",300:"#68D391",400:"#48BB78",500:"#38A169",600:"#2F855A",700:"#276749",800:"#22543D",900:"#1C4532"},teal:{50:"#E6FFFA",100:"#B2F5EA",200:"#81E6D9",300:"#4FD1C5",400:"#38B2AC",500:"#319795",600:"#2C7A7B",700:"#285E61",800:"#234E52",900:"#1D4044"},blue:{50:"#ebf8ff",100:"#bee3f8",200:"#90cdf4",300:"#63b3ed",400:"#4299e1",500:"#3182ce",600:"#2b6cb0",700:"#2c5282",800:"#2a4365",900:"#1A365D"},cyan:{50:"#EDFDFD",100:"#C4F1F9",200:"#9DECF9",300:"#76E4F7",400:"#0BC5EA",500:"#00B5D8",600:"#00A3C4",700:"#0987A0",800:"#086F83",900:"#065666"},purple:{50:"#FAF5FF",100:"#E9D8FD",200:"#D6BCFA",300:"#B794F4",400:"#9F7AEA",500:"#805AD5",600:"#6B46C1",700:"#553C9A",800:"#44337A",900:"#322659"},pink:{50:"#FFF5F7",100:"#FED7E2",200:"#FBB6CE",300:"#F687B3",400:"#ED64A6",500:"#D53F8C",600:"#B83280",700:"#97266D",800:"#702459",900:"#521B41"},linkedin:{50:"#E8F4F9",100:"#CFEDFB",200:"#9BDAF3",300:"#68C7EC",400:"#34B3E4",500:"#00A0DC",600:"#008CC9",700:"#0077B5",800:"#005E93",900:"#004471"},facebook:{50:"#E8F4F9",100:"#D9DEE9",200:"#B7C2DA",300:"#6482C0",400:"#4267B2",500:"#385898",600:"#314E89",700:"#29487D",800:"#223B67",900:"#1E355B"},messenger:{50:"#D0E6FF",100:"#B9DAFF",200:"#A2CDFF",300:"#7AB8FF",400:"#2E90FF",500:"#0078FF",600:"#0063D1",700:"#0052AC",800:"#003C7E",900:"#002C5C"},whatsapp:{50:"#dffeec",100:"#b9f5d0",200:"#90edb3",300:"#65e495",400:"#3cdd78",500:"#22c35e",600:"#179848",700:"#0c6c33",800:"#01421c",900:"#001803"},twitter:{50:"#E5F4FD",100:"#C8E9FB",200:"#A8DCFA",300:"#83CDF7",400:"#57BBF5",500:"#1DA1F2",600:"#1A94DA",700:"#1681BF",800:"#136B9E",900:"#0D4D71"},telegram:{50:"#E3F2F9",100:"#C5E4F3",200:"#A2D4EC",300:"#7AC1E4",400:"#47A9DA",500:"#0088CC",600:"#007AB8",700:"#006BA1",800:"#005885",900:"#003F5E"}},fx=dx,hx={none:"0",sm:"0.125rem",base:"0.25rem",md:"0.375rem",lg:"0.5rem",xl:"0.75rem","2xl":"1rem","3xl":"1.5rem",full:"9999px"},px=hx,mx={xs:"0 0 0 1px rgba(0, 0, 0, 0.05)",sm:"0 1px 2px 0 rgba(0, 0, 0, 0.05)",base:"0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06)",md:"0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06)",lg:"0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05)",xl:"0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04)","2xl":"0 25px 50px -12px rgba(0, 0, 0, 0.25)",outline:"0 0 0 3px rgba(66, 153, 225, 0.6)",inner:"inset 0 2px 4px 0 rgba(0,0,0,0.06)",none:"none","dark-lg":"rgba(0, 0, 0, 0.1) 0px 0px 0px 1px, rgba(0, 0, 0, 0.2) 0px 5px 10px, rgba(0, 0, 0, 0.4) 0px 15px 40px"},bx=mx,gx={none:0,sm:"4px",base:"8px",md:"12px",lg:"16px",xl:"24px","2xl":"40px","3xl":"64px"},vx=gx,yx={letterSpacings:{tighter:"-0.05em",tight:"-0.025em",normal:"0",wide:"0.025em",wider:"0.05em",widest:"0.1em"},lineHeights:{normal:"normal",none:1,shorter:1.25,short:1.375,base:1.5,tall:1.625,taller:"2",3:".75rem",4:"1rem",5:"1.25rem",6:"1.5rem",7:"1.75rem",8:"2rem",9:"2.25rem",10:"2.5rem"},fontWeights:{hairline:100,thin:200,light:300,normal:400,medium:500,semibold:600,bold:700,extrabold:800,black:900},fonts:{heading:'-apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',body:'-apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"',mono:'SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace'},fontSizes:{"3xs":"0.45rem","2xs":"0.625rem",xs:"0.75rem",sm:"0.875rem",md:"1rem",lg:"1.125rem",xl:"1.25rem","2xl":"1.5rem","3xl":"1.875rem","4xl":"2.25rem","5xl":"3rem","6xl":"3.75rem","7xl":"4.5rem","8xl":"6rem","9xl":"8rem"}},o0=yx,a0={px:"1px",.5:"0.125rem",1:"0.25rem",1.5:"0.375rem",2:"0.5rem",2.5:"0.625rem",3:"0.75rem",3.5:"0.875rem",4:"1rem",5:"1.25rem",6:"1.5rem",7:"1.75rem",8:"2rem",9:"2.25rem",10:"2.5rem",12:"3rem",14:"3.5rem",16:"4rem",20:"5rem",24:"6rem",28:"7rem",32:"8rem",36:"9rem",40:"10rem",44:"11rem",48:"12rem",52:"13rem",56:"14rem",60:"15rem",64:"16rem",72:"18rem",80:"20rem",96:"24rem"},wx={max:"max-content",min:"min-content",full:"100%","3xs":"14rem","2xs":"16rem",xs:"20rem",sm:"24rem",md:"28rem",lg:"32rem",xl:"36rem","2xl":"42rem","3xl":"48rem","4xl":"56rem","5xl":"64rem","6xl":"72rem","7xl":"80rem","8xl":"90rem",prose:"60ch"},xx={sm:"640px",md:"768px",lg:"1024px",xl:"1280px"},_x={...a0,...wx,container:xx},l0=_x,Sx={breakpoints:ux,zIndices:ox,radii:px,blur:vx,colors:fx,...o0,sizes:l0,shadows:bx,space:a0,borders:lx,transition:ix},{defineMultiStyleConfig:kx,definePartsStyle:Ls}=$t(["stepper","step","title","description","indicator","separator","icon","number"]),Pn=Ze("stepper-indicator-size"),Ui=Ze("stepper-icon-size"),Wi=Ze("stepper-title-font-size"),$s=Ze("stepper-description-font-size"),Ps=Ze("stepper-accent-color"),Cx=Ls(({colorScheme:t})=>({stepper:{display:"flex",justifyContent:"space-between",gap:"4","&[data-orientation=vertical]":{flexDirection:"column",alignItems:"flex-start"},"&[data-orientation=horizontal]":{flexDirection:"row",alignItems:"center"},[Ps.variable]:`colors.${t}.500`,_dark:{[Ps.variable]:`colors.${t}.200`}},title:{fontSize:Wi.reference,fontWeight:"medium"},description:{fontSize:$s.reference,color:"chakra-subtle-text"},number:{fontSize:Wi.reference},step:{flexShrink:0,position:"relative",display:"flex",gap:"2","&[data-orientation=horizontal]":{alignItems:"center"},flex:"1","&:last-of-type:not([data-stretch])":{flex:"initial"}},icon:{flexShrink:0,width:Ui.reference,height:Ui.reference},indicator:{flexShrink:0,borderRadius:"full",width:Pn.reference,height:Pn.reference,display:"flex",justifyContent:"center",alignItems:"center","&[data-status=active]":{borderWidth:"2px",borderColor:Ps.reference},"&[data-status=complete]":{bg:Ps.reference,color:"chakra-inverse-text"},"&[data-status=incomplete]":{borderWidth:"2px"}},separator:{bg:"chakra-border-color",flex:"1","&[data-status=complete]":{bg:Ps.reference},"&[data-orientation=horizontal]":{width:"100%",height:"2px",marginStart:"2"},"&[data-orientation=vertical]":{width:"2px",position:"absolute",height:"100%",maxHeight:`calc(100% - ${Pn.reference} - 8px)`,top:`calc(${Pn.reference} + 4px)`,insetStart:`calc(${Pn.reference} / 2 - 1px)`}}})),Tx=kx({baseStyle:Cx,sizes:{xs:Ls({stepper:{[Pn.variable]:"sizes.4",[Ui.variable]:"sizes.3",[Wi.variable]:"fontSizes.xs",[$s.variable]:"fontSizes.xs"}}),sm:Ls({stepper:{[Pn.variable]:"sizes.6",[Ui.variable]:"sizes.4",[Wi.variable]:"fontSizes.sm",[$s.variable]:"fontSizes.xs"}}),md:Ls({stepper:{[Pn.variable]:"sizes.8",[Ui.variable]:"sizes.5",[Wi.variable]:"fontSizes.md",[$s.variable]:"fontSizes.sm"}}),lg:Ls({stepper:{[Pn.variable]:"sizes.10",[Ui.variable]:"sizes.6",[Wi.variable]:"fontSizes.lg",[$s.variable]:"fontSizes.md"}})},defaultProps:{size:"md",colorScheme:"blue"}});function Rt(t,r={}){let e=!1;function a(){if(!e){e=!0;return}throw new Error("[anatomy] .part(...) should only be called once. Did you mean to use .extend(...) ?")}function f(...o){a();for(const h of o)r[h]=i(h);return Rt(t,r)}function c(...o){for(const h of o)h in r||(r[h]=i(h));return Rt(t,r)}function s(){return Object.fromEntries(Object.entries(r).map(([h,u])=>[h,u.selector]))}function l(){return Object.fromEntries(Object.entries(r).map(([h,u])=>[h,u.className]))}function i(o){const d=`chakra-${(["container","root"].includes(o??"")?[t]:[t,o]).filter(Boolean).join("__")}`;return{className:d,selector:`.${d}`,toString:()=>o}}return{parts:f,toPart:i,extend:c,selectors:s,classnames:l,get keys(){return Object.keys(r)},__type:{}}}var Ex=Rt("accordion").parts("root","container","button","panel").extend("icon"),Ax=Rt("alert").parts("title","description","container").extend("icon","spinner"),Mx=Rt("avatar").parts("label","badge","container").extend("excessLabel","group"),jx=Rt("breadcrumb").parts("link","item","container").extend("separator");Rt("button").parts();var Px=Rt("checkbox").parts("control","icon","container").extend("label");Rt("progress").parts("track","filledTrack").extend("label");var Rx=Rt("drawer").parts("overlay","dialogContainer","dialog").extend("header","closeButton","body","footer"),Ix=Rt("editable").parts("preview","input","textarea"),Ox=Rt("form").parts("container","requiredIndicator","helperText"),Nx=Rt("formError").parts("text","icon"),Dx=Rt("input").parts("addon","field","element","group"),Fx=Rt("list").parts("container","item","icon"),Bx=Rt("menu").parts("button","list","item").extend("groupTitle","icon","command","divider"),Lx=Rt("modal").parts("overlay","dialogContainer","dialog").extend("header","closeButton","body","footer"),$x=Rt("numberinput").parts("root","field","stepperGroup","stepper");Rt("pininput").parts("field");var zx=Rt("popover").parts("content","header","body","footer").extend("popper","arrow","closeButton"),Vx=Rt("progress").parts("label","filledTrack","track"),Ux=Rt("radio").parts("container","control","label"),Wx=Rt("select").parts("field","icon"),Hx=Rt("slider").parts("container","track","thumb","filledTrack","mark"),qx=Rt("stat").parts("container","label","helpText","number","icon"),Xx=Rt("switch").parts("container","track","thumb","label"),Kx=Rt("table").parts("table","thead","tbody","tr","th","td","tfoot","caption"),Gx=Rt("tabs").parts("root","tab","tablist","tabpanel","tabpanels","indicator"),Yx=Rt("tag").parts("container","label","closeButton"),Zx=Rt("card").parts("container","header","body","footer");Rt("stepper").parts("stepper","step","title","description","indicator","separator","icon","number");function pi(t,r,e){return Math.min(Math.max(t,e),r)}class Jx extends Error{constructor(r){super(`Failed to parse color: "${r}"`)}}var zs=Jx;function Du(t){if(typeof t!="string")throw new zs(t);if(t.trim().toLowerCase()==="transparent")return[0,0,0,0];let r=t.trim();r=o5.test(t)?t5(t):t;const e=r5.exec(r);if(e){const s=Array.from(e).slice(1);return[...s.slice(0,3).map(l=>parseInt(po(l,2),16)),parseInt(po(s[3]||"f",2),16)/255]}const a=n5.exec(r);if(a){const s=Array.from(a).slice(1);return[...s.slice(0,3).map(l=>parseInt(l,16)),parseInt(s[3]||"ff",16)/255]}const f=i5.exec(r);if(f){const s=Array.from(f).slice(1);return[...s.slice(0,3).map(l=>parseInt(l,10)),parseFloat(s[3]||"1")]}const c=s5.exec(r);if(c){const[s,l,i,n]=Array.from(c).slice(1).map(parseFloat);if(pi(0,100,l)!==l)throw new zs(t);if(pi(0,100,i)!==i)throw new zs(t);return[...a5(s,l,i),Number.isNaN(n)?1:n]}throw new zs(t)}function Qx(t){let r=5381,e=t.length;for(;e;)r=r*33^t.charCodeAt(--e);return(r>>>0)%2341}const Lf=t=>parseInt(t.replace(/_/g,""),36),e5="1q29ehhb 1n09sgk7 1kl1ekf_ _yl4zsno 16z9eiv3 1p29lhp8 _bd9zg04 17u0____ _iw9zhe5 _to73___ _r45e31e _7l6g016 _jh8ouiv _zn3qba8 1jy4zshs 11u87k0u 1ro9yvyo 1aj3xael 1gz9zjz0 _3w8l4xo 1bf1ekf_ _ke3v___ _4rrkb__ 13j776yz _646mbhl _nrjr4__ _le6mbhl 1n37ehkb _m75f91n _qj3bzfz 1939yygw 11i5z6x8 _1k5f8xs 1509441m 15t5lwgf _ae2th1n _tg1ugcv 1lp1ugcv 16e14up_ _h55rw7n _ny9yavn _7a11xb_ 1ih442g9 _pv442g9 1mv16xof 14e6y7tu 1oo9zkds 17d1cisi _4v9y70f _y98m8kc 1019pq0v 12o9zda8 _348j4f4 1et50i2o _8epa8__ _ts6senj 1o350i2o 1mi9eiuo 1259yrp0 1ln80gnw _632xcoy 1cn9zldc _f29edu4 1n490c8q _9f9ziet 1b94vk74 _m49zkct 1kz6s73a 1eu9dtog _q58s1rz 1dy9sjiq __u89jo3 _aj5nkwg _ld89jo3 13h9z6wx _qa9z2ii _l119xgq _bs5arju 1hj4nwk9 1qt4nwk9 1ge6wau6 14j9zlcw 11p1edc_ _ms1zcxe _439shk6 _jt9y70f _754zsow 1la40eju _oq5p___ _x279qkz 1fa5r3rv _yd2d9ip _424tcku _8y1di2_ _zi2uabw _yy7rn9h 12yz980_ __39ljp6 1b59zg0x _n39zfzp 1fy9zest _b33k___ _hp9wq92 1il50hz4 _io472ub _lj9z3eo 19z9ykg0 _8t8iu3a 12b9bl4a 1ak5yw0o _896v4ku _tb8k8lv _s59zi6t _c09ze0p 1lg80oqn 1id9z8wb _238nba5 1kq6wgdi _154zssg _tn3zk49 _da9y6tc 1sg7cv4f _r12jvtt 1gq5fmkz 1cs9rvci _lp9jn1c _xw1tdnb 13f9zje6 16f6973h _vo7ir40 _bt5arjf _rc45e4t _hr4e100 10v4e100 _hc9zke2 _w91egv_ _sj2r1kk 13c87yx8 _vqpds__ _ni8ggk8 _tj9yqfb 1ia2j4r4 _7x9b10u 1fc9ld4j 1eq9zldr _5j9lhpx _ez9zl6o _md61fzm".split(" ").reduce((t,r)=>{const e=Lf(r.substring(0,3)),a=Lf(r.substring(3)).toString(16);let f="";for(let c=0;c<6-a.length;c++)f+="0";return t[e]=`${f}${a}`,t},{});function t5(t){const r=t.toLowerCase().trim(),e=e5[Qx(r)];if(!e)throw new zs(t);return`#${e}`}const po=(t,r)=>Array.from(Array(r)).map(()=>t).join(""),r5=new RegExp(`^#${po("([a-f0-9])",3)}([a-f0-9])?$`,"i"),n5=new RegExp(`^#${po("([a-f0-9]{2})",3)}([a-f0-9]{2})?$`,"i"),i5=new RegExp(`^rgba?\\(\\s*(\\d+)\\s*${po(",\\s*(\\d+)\\s*",2)}(?:,\\s*([\\d.]+))?\\s*\\)$`,"i"),s5=/^hsla?\(\s*([\d.]+)\s*,\s*([\d.]+)%\s*,\s*([\d.]+)%(?:\s*,\s*([\d.]+))?\s*\)$/i,o5=/^[a-z]+$/i,$f=t=>Math.round(t*255),a5=(t,r,e)=>{let a=e/100;if(r===0)return[a,a,a].map($f);const f=(t%360+360)%360/60,c=(1-Math.abs(2*a-1))*(r/100),s=c*(1-Math.abs(f%2-1));let l=0,i=0,n=0;f>=0&&f<1?(l=c,i=s):f>=1&&f<2?(l=s,i=c):f>=2&&f<3?(i=c,n=s):f>=3&&f<4?(i=s,n=c):f>=4&&f<5?(l=s,n=c):f>=5&&f<6&&(l=c,n=s);const o=a-c/2,h=l+o,u=i+o,d=n+o;return[h,u,d].map($f)};function l5(t,r,e,a){return`rgba(${pi(0,255,t).toFixed()}, ${pi(0,255,r).toFixed()}, ${pi(0,255,e).toFixed()}, ${parseFloat(pi(0,1,a).toFixed(3))})`}function c5(t,r){const[e,a,f,c]=Du(t);return l5(e,a,f,c-r)}function u5(t){const[r,e,a,f]=Du(t);let c=s=>{const l=pi(0,255,s).toString(16);return l.length===1?`0${l}`:l};return`#${c(r)}${c(e)}${c(a)}${f<1?c(Math.round(f*255)):""}`}function d5(t,r,e,a,f){for(r=r.split?r.split("."):r,a=0;a<r.length;a++)t=t?t[r[a]]:f;return t===f?e:t}var f5=t=>Object.keys(t).length===0,_r=(t,r,e)=>{const a=d5(t,`colors.${r}`,r);try{return u5(a),a}catch{return e??"#000000"}},h5=t=>{const[r,e,a]=Du(t);return(r*299+e*587+a*114)/1e3},p5=t=>r=>{const e=_r(r,t);return h5(e)<128?"dark":"light"},m5=t=>r=>p5(t)(r)==="dark",ds=(t,r)=>e=>{const a=_r(e,t);return c5(a,1-r)};function zf(t="1rem",r="rgba(255, 255, 255, 0.15)"){return{backgroundImage:`linear-gradient( 45deg, ${r} 25%, transparent 25%, transparent 50%, ${r} 50%, ${r} 75%, transparent 75%, transparent )`,backgroundSize:`${t} ${t}`}}var b5=()=>`#${Math.floor(Math.random()*16777215).toString(16).padEnd(6,"0")}`;function g5(t){const r=b5();return!t||f5(t)?r:t.string&&t.colors?y5(t.string,t.colors):t.string&&!t.colors?v5(t.string):t.colors&&!t.string?w5(t.colors):r}function v5(t){let r=0;if(t.length===0)return r.toString();for(let a=0;a<t.length;a+=1)r=t.charCodeAt(a)+((r<<5)-r),r=r&r;let e="#";for(let a=0;a<3;a+=1){const f=r>>a*8&255;e+=`00${f.toString(16)}`.substr(-2)}return e}function y5(t,r){let e=0;if(t.length===0)return r[0];for(let a=0;a<t.length;a+=1)e=t.charCodeAt(a)+((e<<5)-e),e=e&e;return e=(e%r.length+r.length)%r.length,r[e]}function w5(t){return t[Math.floor(Math.random()*t.length)]}function Je(t,r){return e=>e.colorMode==="dark"?r:t}function Fu(t){const{orientation:r,vertical:e,horizontal:a}=t;return r?r==="vertical"?e:a:{}}function c0(t){return kr(t)&&t.reference?t.reference:String(t)}var al=(t,...r)=>r.map(c0).join(` ${t} `).replace(/calc/g,""),Vf=(...t)=>`calc(${al("+",...t)})`,Uf=(...t)=>`calc(${al("-",...t)})`,Pc=(...t)=>`calc(${al("*",...t)})`,Wf=(...t)=>`calc(${al("/",...t)})`,Hf=t=>{const r=c0(t);return r!=null&&!Number.isNaN(parseFloat(r))?String(r).startsWith("-")?String(r).slice(1):`-${r}`:Pc(r,-1)},Rn=Object.assign(t=>({add:(...r)=>Rn(Vf(t,...r)),subtract:(...r)=>Rn(Uf(t,...r)),multiply:(...r)=>Rn(Pc(t,...r)),divide:(...r)=>Rn(Wf(t,...r)),negate:()=>Rn(Hf(t)),toString:()=>t.toString()}),{add:Vf,subtract:Uf,multiply:Pc,divide:Wf,negate:Hf});function x5(t){return!Number.isInteger(parseFloat(t.toString()))}function _5(t,r="-"){return t.replace(/\s+/g,r)}function u0(t){const r=_5(t.toString());return r.includes("\\.")?t:x5(t)?r.replace(".","\\."):t}function S5(t,r=""){return[r,u0(t)].filter(Boolean).join("-")}function k5(t,r){return`var(${u0(t)}${r?`, ${r}`:""})`}function C5(t,r=""){return`--${S5(t,r)}`}function sr(t,r){const e=C5(t,void 0);return{variable:e,reference:k5(e,T5(void 0))}}function T5(t){return t?.reference}var{defineMultiStyleConfig:E5,definePartsStyle:wa}=$t(Xx.keys),Zs=sr("switch-track-width"),gi=sr("switch-track-height"),Pl=sr("switch-track-diff"),A5=Rn.subtract(Zs,gi),Rc=sr("switch-thumb-x"),Rs=sr("switch-bg"),M5=t=>{const{colorScheme:r}=t;return{borderRadius:"full",p:"0.5",width:[Zs.reference],height:[gi.reference],transitionProperty:"common",transitionDuration:"fast",[Rs.variable]:"colors.gray.300",_dark:{[Rs.variable]:"colors.whiteAlpha.400"},_focusVisible:{boxShadow:"outline"},_disabled:{opacity:.4,cursor:"not-allowed"},_checked:{[Rs.variable]:`colors.${r}.500`,_dark:{[Rs.variable]:`colors.${r}.200`}},bg:Rs.reference}},j5={bg:"white",transitionProperty:"transform",transitionDuration:"normal",borderRadius:"inherit",width:[gi.reference],height:[gi.reference],_checked:{transform:`translateX(${Rc.reference})`}},P5=wa(t=>({container:{[Pl.variable]:A5,[Rc.variable]:Pl.reference,_rtl:{[Rc.variable]:Rn(Pl).negate().toString()}},track:M5(t),thumb:j5})),R5={sm:wa({container:{[Zs.variable]:"1.375rem",[gi.variable]:"sizes.3"}}),md:wa({container:{[Zs.variable]:"1.875rem",[gi.variable]:"sizes.4"}}),lg:wa({container:{[Zs.variable]:"2.875rem",[gi.variable]:"sizes.6"}})},I5=E5({baseStyle:P5,sizes:R5,defaultProps:{size:"md",colorScheme:"blue"}}),{defineMultiStyleConfig:O5,definePartsStyle:ns}=$t(Kx.keys),N5=ns({table:{fontVariantNumeric:"lining-nums tabular-nums",borderCollapse:"collapse",width:"full"},th:{fontFamily:"heading",fontWeight:"bold",textTransform:"uppercase",letterSpacing:"wider",textAlign:"start"},td:{textAlign:"start"},caption:{mt:4,fontFamily:"heading",textAlign:"center",fontWeight:"medium"}}),$a={"&[data-is-numeric=true]":{textAlign:"end"}},D5=ns(t=>{const{colorScheme:r}=t;return{th:{color:Je("gray.600","gray.400")(t),borderBottom:"1px",borderColor:Je(`${r}.100`,`${r}.700`)(t),...$a},td:{borderBottom:"1px",borderColor:Je(`${r}.100`,`${r}.700`)(t),...$a},caption:{color:Je("gray.600","gray.100")(t)},tfoot:{tr:{"&:last-of-type":{th:{borderBottomWidth:0}}}}}}),F5=ns(t=>{const{colorScheme:r}=t;return{th:{color:Je("gray.600","gray.400")(t),borderBottom:"1px",borderColor:Je(`${r}.100`,`${r}.700`)(t),...$a},td:{borderBottom:"1px",borderColor:Je(`${r}.100`,`${r}.700`)(t),...$a},caption:{color:Je("gray.600","gray.100")(t)},tbody:{tr:{"&:nth-of-type(odd)":{"th, td":{borderBottomWidth:"1px",borderColor:Je(`${r}.100`,`${r}.700`)(t)},td:{background:Je(`${r}.100`,`${r}.700`)(t)}}}},tfoot:{tr:{"&:last-of-type":{th:{borderBottomWidth:0}}}}}}),B5={simple:D5,striped:F5,unstyled:{}},L5={sm:ns({th:{px:"4",py:"1",lineHeight:"4",fontSize:"xs"},td:{px:"4",py:"2",fontSize:"sm",lineHeight:"4"},caption:{px:"4",py:"2",fontSize:"xs"}}),md:ns({th:{px:"6",py:"3",lineHeight:"4",fontSize:"xs"},td:{px:"6",py:"4",lineHeight:"5"},caption:{px:"6",py:"2",fontSize:"sm"}}),lg:ns({th:{px:"8",py:"4",lineHeight:"5",fontSize:"sm"},td:{px:"8",py:"5",lineHeight:"6"},caption:{px:"6",py:"2",fontSize:"md"}})},$5=O5({baseStyle:N5,variants:B5,sizes:L5,defaultProps:{variant:"simple",size:"md",colorScheme:"gray"}}),jr=Ze("tabs-color"),sn=Ze("tabs-bg"),Qo=Ze("tabs-border-color"),{defineMultiStyleConfig:z5,definePartsStyle:yn}=$t(Gx.keys),V5=t=>{const{orientation:r}=t;return{display:r==="vertical"?"flex":"block"}},U5=t=>{const{isFitted:r}=t;return{flex:r?1:void 0,transitionProperty:"common",transitionDuration:"normal",_focusVisible:{zIndex:1,boxShadow:"outline"},_disabled:{cursor:"not-allowed",opacity:.4}}},W5=t=>{const{align:r="start",orientation:e}=t;return{justifyContent:{end:"flex-end",center:"center",start:"flex-start"}[r],flexDirection:e==="vertical"?"column":"row"}},H5={p:4},q5=yn(t=>({root:V5(t),tab:U5(t),tablist:W5(t),tabpanel:H5})),X5={sm:yn({tab:{py:1,px:4,fontSize:"sm"}}),md:yn({tab:{fontSize:"md",py:2,px:4}}),lg:yn({tab:{fontSize:"lg",py:3,px:4}})},K5=yn(t=>{const{colorScheme:r,orientation:e}=t,a=e==="vertical",f=a?"borderStart":"borderBottom",c=a?"marginStart":"marginBottom";return{tablist:{[f]:"2px solid",borderColor:"inherit"},tab:{[f]:"2px solid",borderColor:"transparent",[c]:"-2px",_selected:{[jr.variable]:`colors.${r}.600`,_dark:{[jr.variable]:`colors.${r}.300`},borderColor:"currentColor"},_active:{[sn.variable]:"colors.gray.200",_dark:{[sn.variable]:"colors.whiteAlpha.300"}},_disabled:{_active:{bg:"none"}},color:jr.reference,bg:sn.reference}}}),G5=yn(t=>{const{colorScheme:r}=t;return{tab:{borderTopRadius:"md",border:"1px solid",borderColor:"transparent",mb:"-1px",[Qo.variable]:"transparent",_selected:{[jr.variable]:`colors.${r}.600`,[Qo.variable]:"colors.white",_dark:{[jr.variable]:`colors.${r}.300`,[Qo.variable]:"colors.gray.800"},borderColor:"inherit",borderBottomColor:Qo.reference},color:jr.reference},tablist:{mb:"-1px",borderBottom:"1px solid",borderColor:"inherit"}}}),Y5=yn(t=>{const{colorScheme:r}=t;return{tab:{border:"1px solid",borderColor:"inherit",[sn.variable]:"colors.gray.50",_dark:{[sn.variable]:"colors.whiteAlpha.50"},mb:"-1px",_notLast:{marginEnd:"-1px"},_selected:{[sn.variable]:"colors.white",[jr.variable]:`colors.${r}.600`,_dark:{[sn.variable]:"colors.gray.800",[jr.variable]:`colors.${r}.300`},borderColor:"inherit",borderTopColor:"currentColor",borderBottomColor:"transparent"},color:jr.reference,bg:sn.reference},tablist:{mb:"-1px",borderBottom:"1px solid",borderColor:"inherit"}}}),Z5=yn(t=>{const{colorScheme:r,theme:e}=t;return{tab:{borderRadius:"full",fontWeight:"semibold",color:"gray.600",_selected:{color:_r(e,`${r}.700`),bg:_r(e,`${r}.100`)}}}}),J5=yn(t=>{const{colorScheme:r}=t;return{tab:{borderRadius:"full",fontWeight:"semibold",[jr.variable]:"colors.gray.600",_dark:{[jr.variable]:"inherit"},_selected:{[jr.variable]:"colors.white",[sn.variable]:`colors.${r}.600`,_dark:{[jr.variable]:"colors.gray.800",[sn.variable]:`colors.${r}.300`}},color:jr.reference,bg:sn.reference}}}),Q5=yn({}),e6={line:K5,enclosed:G5,"enclosed-colored":Y5,"soft-rounded":Z5,"solid-rounded":J5,unstyled:Q5},t6=z5({baseStyle:q5,sizes:X5,variants:e6,defaultProps:{size:"md",variant:"line",colorScheme:"blue"}}),tr=Sw("badge",["bg","color","shadow"]),r6={px:1,textTransform:"uppercase",fontSize:"xs",borderRadius:"sm",fontWeight:"bold",bg:tr.bg.reference,color:tr.color.reference,boxShadow:tr.shadow.reference},n6=t=>{const{colorScheme:r,theme:e}=t,a=ds(`${r}.500`,.6)(e);return{[tr.bg.variable]:`colors.${r}.500`,[tr.color.variable]:"colors.white",_dark:{[tr.bg.variable]:a,[tr.color.variable]:"colors.whiteAlpha.800"}}},i6=t=>{const{colorScheme:r,theme:e}=t,a=ds(`${r}.200`,.16)(e);return{[tr.bg.variable]:`colors.${r}.100`,[tr.color.variable]:`colors.${r}.800`,_dark:{[tr.bg.variable]:a,[tr.color.variable]:`colors.${r}.200`}}},s6=t=>{const{colorScheme:r,theme:e}=t,a=ds(`${r}.200`,.8)(e);return{[tr.color.variable]:`colors.${r}.500`,_dark:{[tr.color.variable]:a},[tr.shadow.variable]:`inset 0 0 0px 1px ${tr.color.reference}`}},o6={solid:n6,subtle:i6,outline:s6},Js={baseStyle:r6,variants:o6,defaultProps:{variant:"subtle",colorScheme:"gray"}},{defineMultiStyleConfig:a6,definePartsStyle:vi}=$t(Yx.keys),qf=Ze("tag-bg"),Xf=Ze("tag-color"),Rl=Ze("tag-shadow"),xa=Ze("tag-min-height"),_a=Ze("tag-min-width"),Sa=Ze("tag-font-size"),ka=Ze("tag-padding-inline"),l6={fontWeight:"medium",lineHeight:1.2,outline:0,[Xf.variable]:tr.color.reference,[qf.variable]:tr.bg.reference,[Rl.variable]:tr.shadow.reference,color:Xf.reference,bg:qf.reference,boxShadow:Rl.reference,borderRadius:"md",minH:xa.reference,minW:_a.reference,fontSize:Sa.reference,px:ka.reference,_focusVisible:{[Rl.variable]:"shadows.outline"}},c6={lineHeight:1.2,overflow:"visible"},u6={fontSize:"lg",w:"5",h:"5",transitionProperty:"common",transitionDuration:"normal",borderRadius:"full",marginStart:"1.5",marginEnd:"-1",opacity:.5,_disabled:{opacity:.4},_focusVisible:{boxShadow:"outline",bg:"rgba(0, 0, 0, 0.14)"},_hover:{opacity:.8},_active:{opacity:1}},d6=vi({container:l6,label:c6,closeButton:u6}),f6={sm:vi({container:{[xa.variable]:"sizes.5",[_a.variable]:"sizes.5",[Sa.variable]:"fontSizes.xs",[ka.variable]:"space.2"},closeButton:{marginEnd:"-2px",marginStart:"0.35rem"}}),md:vi({container:{[xa.variable]:"sizes.6",[_a.variable]:"sizes.6",[Sa.variable]:"fontSizes.sm",[ka.variable]:"space.2"}}),lg:vi({container:{[xa.variable]:"sizes.8",[_a.variable]:"sizes.8",[Sa.variable]:"fontSizes.md",[ka.variable]:"space.3"}})},h6={subtle:vi(t=>{var r;return{container:(r=Js.variants)==null?void 0:r.subtle(t)}}),solid:vi(t=>{var r;return{container:(r=Js.variants)==null?void 0:r.solid(t)}}),outline:vi(t=>{var r;return{container:(r=Js.variants)==null?void 0:r.outline(t)}})},p6=a6({variants:h6,baseStyle:d6,sizes:f6,defaultProps:{size:"md",variant:"subtle",colorScheme:"gray"}}),{definePartsStyle:In,defineMultiStyleConfig:m6}=$t(Dx.keys),Hi=Ze("input-height"),qi=Ze("input-font-size"),Xi=Ze("input-padding"),Ki=Ze("input-border-radius"),b6=In({addon:{height:Hi.reference,fontSize:qi.reference,px:Xi.reference,borderRadius:Ki.reference},field:{width:"100%",height:Hi.reference,fontSize:qi.reference,px:Xi.reference,borderRadius:Ki.reference,minWidth:0,outline:0,position:"relative",appearance:"none",transitionProperty:"common",transitionDuration:"normal",_disabled:{opacity:.4,cursor:"not-allowed"}}}),Kn={lg:{[qi.variable]:"fontSizes.lg",[Xi.variable]:"space.4",[Ki.variable]:"radii.md",[Hi.variable]:"sizes.12"},md:{[qi.variable]:"fontSizes.md",[Xi.variable]:"space.4",[Ki.variable]:"radii.md",[Hi.variable]:"sizes.10"},sm:{[qi.variable]:"fontSizes.sm",[Xi.variable]:"space.3",[Ki.variable]:"radii.sm",[Hi.variable]:"sizes.8"},xs:{[qi.variable]:"fontSizes.xs",[Xi.variable]:"space.2",[Ki.variable]:"radii.sm",[Hi.variable]:"sizes.6"}},g6={lg:In({field:Kn.lg,group:Kn.lg}),md:In({field:Kn.md,group:Kn.md}),sm:In({field:Kn.sm,group:Kn.sm}),xs:In({field:Kn.xs,group:Kn.xs})};function Bu(t){const{focusBorderColor:r,errorBorderColor:e}=t;return{focusBorderColor:r||Je("blue.500","blue.300")(t),errorBorderColor:e||Je("red.500","red.300")(t)}}var v6=In(t=>{const{theme:r}=t,{focusBorderColor:e,errorBorderColor:a}=Bu(t);return{field:{border:"1px solid",borderColor:"inherit",bg:"inherit",_hover:{borderColor:Je("gray.300","whiteAlpha.400")(t)},_readOnly:{boxShadow:"none !important",userSelect:"all"},_invalid:{borderColor:_r(r,a),boxShadow:`0 0 0 1px ${_r(r,a)}`},_focusVisible:{zIndex:1,borderColor:_r(r,e),boxShadow:`0 0 0 1px ${_r(r,e)}`}},addon:{border:"1px solid",borderColor:Je("inherit","whiteAlpha.50")(t),bg:Je("gray.100","whiteAlpha.300")(t)}}}),y6=In(t=>{const{theme:r}=t,{focusBorderColor:e,errorBorderColor:a}=Bu(t);return{field:{border:"2px solid",borderColor:"transparent",bg:Je("gray.100","whiteAlpha.50")(t),_hover:{bg:Je("gray.200","whiteAlpha.100")(t)},_readOnly:{boxShadow:"none !important",userSelect:"all"},_invalid:{borderColor:_r(r,a)},_focusVisible:{bg:"transparent",borderColor:_r(r,e)}},addon:{border:"2px solid",borderColor:"transparent",bg:Je("gray.100","whiteAlpha.50")(t)}}}),w6=In(t=>{const{theme:r}=t,{focusBorderColor:e,errorBorderColor:a}=Bu(t);return{field:{borderBottom:"1px solid",borderColor:"inherit",borderRadius:"0",px:"0",bg:"transparent",_readOnly:{boxShadow:"none !important",userSelect:"all"},_invalid:{borderColor:_r(r,a),boxShadow:`0px 1px 0px 0px ${_r(r,a)}`},_focusVisible:{borderColor:_r(r,e),boxShadow:`0px 1px 0px 0px ${_r(r,e)}`}},addon:{borderBottom:"2px solid",borderColor:"inherit",borderRadius:"0",px:"0",bg:"transparent"}}}),x6=In({field:{bg:"transparent",px:"0",height:"auto"},addon:{bg:"transparent",px:"0",height:"auto"}}),_6={outline:v6,filled:y6,flushed:w6,unstyled:x6},Pt=m6({baseStyle:b6,sizes:g6,variants:_6,defaultProps:{size:"md",variant:"outline"}}),Kf,S6={...(Kf=Pt.baseStyle)==null?void 0:Kf.field,paddingY:"2",minHeight:"20",lineHeight:"short",verticalAlign:"top"},Gf,Yf,k6={outline:t=>{var r,e;return(e=(r=Pt.variants)==null?void 0:r.outline(t).field)!=null?e:{}},flushed:t=>{var r,e;return(e=(r=Pt.variants)==null?void 0:r.flushed(t).field)!=null?e:{}},filled:t=>{var r,e;return(e=(r=Pt.variants)==null?void 0:r.filled(t).field)!=null?e:{}},unstyled:(Yf=(Gf=Pt.variants)==null?void 0:Gf.unstyled.field)!=null?Yf:{}},Zf,Jf,Qf,eh,th,rh,nh,ih,C6={xs:(Jf=(Zf=Pt.sizes)==null?void 0:Zf.xs.field)!=null?Jf:{},sm:(eh=(Qf=Pt.sizes)==null?void 0:Qf.sm.field)!=null?eh:{},md:(rh=(th=Pt.sizes)==null?void 0:th.md.field)!=null?rh:{},lg:(ih=(nh=Pt.sizes)==null?void 0:nh.lg.field)!=null?ih:{}},T6={baseStyle:S6,sizes:C6,variants:k6,defaultProps:{size:"md",variant:"outline"}},ea=sr("tooltip-bg"),Il=sr("tooltip-fg"),E6=sr("popper-arrow-bg"),A6={bg:ea.reference,color:Il.reference,[ea.variable]:"colors.gray.700",[Il.variable]:"colors.whiteAlpha.900",_dark:{[ea.variable]:"colors.gray.300",[Il.variable]:"colors.gray.900"},[E6.variable]:ea.reference,px:"2",py:"0.5",borderRadius:"sm",fontWeight:"medium",fontSize:"sm",boxShadow:"md",maxW:"xs",zIndex:"tooltip"},M6={baseStyle:A6},{defineMultiStyleConfig:j6,definePartsStyle:Vs}=$t(Vx.keys),P6=t=>{const{colorScheme:r,theme:e,isIndeterminate:a,hasStripe:f}=t,c=Je(zf(),zf("1rem","rgba(0,0,0,0.1)"))(t),s=Je(`${r}.500`,`${r}.200`)(t),l=`linear-gradient( to right, transparent 0%, ${_r(e,s)} 50%, transparent 100% )`;return{...!a&&f&&c,...a?{bgImage:l}:{bgColor:s}}},R6={lineHeight:"1",fontSize:"0.25em",fontWeight:"bold",color:"white"},I6=t=>({bg:Je("gray.100","whiteAlpha.300")(t)}),O6=t=>({transitionProperty:"common",transitionDuration:"slow",...P6(t)}),N6=Vs(t=>({label:R6,filledTrack:O6(t),track:I6(t)})),D6={xs:Vs({track:{h:"1"}}),sm:Vs({track:{h:"2"}}),md:Vs({track:{h:"3"}}),lg:Vs({track:{h:"4"}})},F6=j6({sizes:D6,baseStyle:N6,defaultProps:{size:"md",colorScheme:"blue"}}),B6=t=>typeof t=="function";function Cr(t,...r){return B6(t)?t(...r):t}var{definePartsStyle:Ca,defineMultiStyleConfig:L6}=$t(Px.keys),Qs=Ze("checkbox-size"),$6=t=>{const{colorScheme:r}=t;return{w:Qs.reference,h:Qs.reference,transitionProperty:"box-shadow",transitionDuration:"normal",border:"2px solid",borderRadius:"sm",borderColor:"inherit",color:"white",_checked:{bg:Je(`${r}.500`,`${r}.200`)(t),borderColor:Je(`${r}.500`,`${r}.200`)(t),color:Je("white","gray.900")(t),_hover:{bg:Je(`${r}.600`,`${r}.300`)(t),borderColor:Je(`${r}.600`,`${r}.300`)(t)},_disabled:{borderColor:Je("gray.200","transparent")(t),bg:Je("gray.200","whiteAlpha.300")(t),color:Je("gray.500","whiteAlpha.500")(t)}},_indeterminate:{bg:Je(`${r}.500`,`${r}.200`)(t),borderColor:Je(`${r}.500`,`${r}.200`)(t),color:Je("white","gray.900")(t)},_disabled:{bg:Je("gray.100","whiteAlpha.100")(t),borderColor:Je("gray.100","transparent")(t)},_focusVisible:{boxShadow:"outline"},_invalid:{borderColor:Je("red.500","red.300")(t)}}},z6={_disabled:{cursor:"not-allowed"}},V6={userSelect:"none",_disabled:{opacity:.4}},U6={transitionProperty:"transform",transitionDuration:"normal"},W6=Ca(t=>({icon:U6,container:z6,control:Cr($6,t),label:V6})),H6={sm:Ca({control:{[Qs.variable]:"sizes.3"},label:{fontSize:"sm"},icon:{fontSize:"3xs"}}),md:Ca({control:{[Qs.variable]:"sizes.4"},label:{fontSize:"md"},icon:{fontSize:"2xs"}}),lg:Ca({control:{[Qs.variable]:"sizes.5"},label:{fontSize:"lg"},icon:{fontSize:"2xs"}})},za=L6({baseStyle:W6,sizes:H6,defaultProps:{size:"md",colorScheme:"blue"}}),{defineMultiStyleConfig:q6,definePartsStyle:Ta}=$t(Ux.keys),X6=t=>{var r;const e=(r=Cr(za.baseStyle,t))==null?void 0:r.control;return{...e,borderRadius:"full",_checked:{...e?._checked,_before:{content:'""',display:"inline-block",pos:"relative",w:"50%",h:"50%",borderRadius:"50%",bg:"currentColor"}}}},K6=Ta(t=>{var r,e,a,f;return{label:(e=(r=za).baseStyle)==null?void 0:e.call(r,t).label,container:(f=(a=za).baseStyle)==null?void 0:f.call(a,t).container,control:X6(t)}}),G6={md:Ta({control:{w:"4",h:"4"},label:{fontSize:"md"}}),lg:Ta({control:{w:"5",h:"5"},label:{fontSize:"lg"}}),sm:Ta({control:{width:"3",height:"3"},label:{fontSize:"sm"}})},Y6=q6({baseStyle:K6,sizes:G6,defaultProps:{size:"md",colorScheme:"blue"}}),{defineMultiStyleConfig:Z6,definePartsStyle:J6}=$t(Wx.keys),ta=Ze("select-bg"),sh,Q6={...(sh=Pt.baseStyle)==null?void 0:sh.field,appearance:"none",paddingBottom:"1px",lineHeight:"normal",bg:ta.reference,[ta.variable]:"colors.white",_dark:{[ta.variable]:"colors.gray.700"},"> option, > optgroup":{bg:ta.reference}},e4={width:"6",height:"100%",insetEnd:"2",position:"relative",color:"currentColor",fontSize:"xl",_disabled:{opacity:.5}},t4=J6({field:Q6,icon:e4}),ra={paddingInlineEnd:"8"},oh,ah,lh,ch,uh,dh,fh,hh,r4={lg:{...(oh=Pt.sizes)==null?void 0:oh.lg,field:{...(ah=Pt.sizes)==null?void 0:ah.lg.field,...ra}},md:{...(lh=Pt.sizes)==null?void 0:lh.md,field:{...(ch=Pt.sizes)==null?void 0:ch.md.field,...ra}},sm:{...(uh=Pt.sizes)==null?void 0:uh.sm,field:{...(dh=Pt.sizes)==null?void 0:dh.sm.field,...ra}},xs:{...(fh=Pt.sizes)==null?void 0:fh.xs,field:{...(hh=Pt.sizes)==null?void 0:hh.xs.field,...ra},icon:{insetEnd:"1"}}},n4=Z6({baseStyle:t4,sizes:r4,variants:Pt.variants,defaultProps:Pt.defaultProps}),Ol=Ze("skeleton-start-color"),Nl=Ze("skeleton-end-color"),i4={[Ol.variable]:"colors.gray.100",[Nl.variable]:"colors.gray.400",_dark:{[Ol.variable]:"colors.gray.800",[Nl.variable]:"colors.gray.600"},background:Ol.reference,borderColor:Nl.reference,opacity:.7,borderRadius:"sm"},s4={baseStyle:i4},Dl=Ze("skip-link-bg"),o4={borderRadius:"md",fontWeight:"semibold",_focusVisible:{boxShadow:"outline",padding:"4",position:"fixed",top:"6",insetStart:"6",[Dl.variable]:"colors.white",_dark:{[Dl.variable]:"colors.gray.700"},bg:Dl.reference}},a4={baseStyle:o4},{defineMultiStyleConfig:l4,definePartsStyle:ll}=$t(Hx.keys),mo=Ze("slider-thumb-size"),bo=Ze("slider-track-size"),Jn=Ze("slider-bg"),c4=t=>{const{orientation:r}=t;return{display:"inline-block",position:"relative",cursor:"pointer",_disabled:{opacity:.6,cursor:"default",pointerEvents:"none"},...Fu({orientation:r,vertical:{h:"100%"},horizontal:{w:"100%"}})}},u4=t=>({...Fu({orientation:t.orientation,horizontal:{h:bo.reference},vertical:{w:bo.reference}}),overflow:"hidden",borderRadius:"sm",[Jn.variable]:"colors.gray.200",_dark:{[Jn.variable]:"colors.whiteAlpha.200"},_disabled:{[Jn.variable]:"colors.gray.300",_dark:{[Jn.variable]:"colors.whiteAlpha.300"}},bg:Jn.reference}),d4=t=>{const{orientation:r}=t;return{...Fu({orientation:r,vertical:{left:"50%",transform:"translateX(-50%)",_active:{transform:"translateX(-50%) scale(1.15)"}},horizontal:{top:"50%",transform:"translateY(-50%)",_active:{transform:"translateY(-50%) scale(1.15)"}}}),w:mo.reference,h:mo.reference,display:"flex",alignItems:"center",justifyContent:"center",position:"absolute",outline:0,zIndex:1,borderRadius:"full",bg:"white",boxShadow:"base",border:"1px solid",borderColor:"transparent",transitionProperty:"transform",transitionDuration:"normal",_focusVisible:{boxShadow:"outline"},_disabled:{bg:"gray.300"}}},f4=t=>{const{colorScheme:r}=t;return{width:"inherit",height:"inherit",[Jn.variable]:`colors.${r}.500`,_dark:{[Jn.variable]:`colors.${r}.200`},bg:Jn.reference}},h4=ll(t=>({container:c4(t),track:u4(t),thumb:d4(t),filledTrack:f4(t)})),p4=ll({container:{[mo.variable]:"sizes.4",[bo.variable]:"sizes.1"}}),m4=ll({container:{[mo.variable]:"sizes.3.5",[bo.variable]:"sizes.1"}}),b4=ll({container:{[mo.variable]:"sizes.2.5",[bo.variable]:"sizes.0.5"}}),g4={lg:p4,md:m4,sm:b4},v4=l4({baseStyle:h4,sizes:g4,defaultProps:{size:"md",colorScheme:"blue"}}),fi=sr("spinner-size"),y4={width:[fi.reference],height:[fi.reference]},w4={xs:{[fi.variable]:"sizes.3"},sm:{[fi.variable]:"sizes.4"},md:{[fi.variable]:"sizes.6"},lg:{[fi.variable]:"sizes.8"},xl:{[fi.variable]:"sizes.12"}},x4={baseStyle:y4,sizes:w4,defaultProps:{size:"md"}},{defineMultiStyleConfig:_4,definePartsStyle:d0}=$t(qx.keys),S4={fontWeight:"medium"},k4={opacity:.8,marginBottom:"2"},C4={verticalAlign:"baseline",fontWeight:"semibold"},T4={marginEnd:1,w:"3.5",h:"3.5",verticalAlign:"middle"},E4=d0({container:{},label:S4,helpText:k4,number:C4,icon:T4}),A4={md:d0({label:{fontSize:"sm"},helpText:{fontSize:"sm"},number:{fontSize:"2xl"}})},M4=_4({baseStyle:E4,sizes:A4,defaultProps:{size:"md"}}),Fl=Ze("kbd-bg"),j4={[Fl.variable]:"colors.gray.100",_dark:{[Fl.variable]:"colors.whiteAlpha.100"},bg:Fl.reference,borderRadius:"md",borderWidth:"1px",borderBottomWidth:"3px",fontSize:"0.8em",fontWeight:"bold",lineHeight:"normal",px:"0.4em",whiteSpace:"nowrap"},P4={baseStyle:j4},R4={transitionProperty:"common",transitionDuration:"fast",transitionTimingFunction:"ease-out",cursor:"pointer",textDecoration:"none",outline:"none",color:"inherit",_hover:{textDecoration:"underline"},_focusVisible:{boxShadow:"outline"}},I4={baseStyle:R4},{defineMultiStyleConfig:O4,definePartsStyle:N4}=$t(Fx.keys),D4={marginEnd:"2",display:"inline",verticalAlign:"text-bottom"},F4=N4({icon:D4}),B4=O4({baseStyle:F4}),{defineMultiStyleConfig:L4,definePartsStyle:$4}=$t(Bx.keys),fn=Ze("menu-bg"),Bl=Ze("menu-shadow"),z4={[fn.variable]:"#fff",[Bl.variable]:"shadows.sm",_dark:{[fn.variable]:"colors.gray.700",[Bl.variable]:"shadows.dark-lg"},color:"inherit",minW:"3xs",py:"2",zIndex:1,borderRadius:"md",borderWidth:"1px",bg:fn.reference,boxShadow:Bl.reference},V4={py:"1.5",px:"3",transitionProperty:"background",transitionDuration:"ultra-fast",transitionTimingFunction:"ease-in",_focus:{[fn.variable]:"colors.gray.100",_dark:{[fn.variable]:"colors.whiteAlpha.100"}},_active:{[fn.variable]:"colors.gray.200",_dark:{[fn.variable]:"colors.whiteAlpha.200"}},_expanded:{[fn.variable]:"colors.gray.100",_dark:{[fn.variable]:"colors.whiteAlpha.100"}},_disabled:{opacity:.4,cursor:"not-allowed"},bg:fn.reference},U4={mx:4,my:2,fontWeight:"semibold",fontSize:"sm"},W4={display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0},H4={opacity:.6},q4={border:0,borderBottom:"1px solid",borderColor:"inherit",my:"2",opacity:.6},X4={transitionProperty:"common",transitionDuration:"normal"},K4=$4({button:X4,list:z4,item:V4,groupTitle:U4,icon:W4,command:H4,divider:q4}),G4=L4({baseStyle:K4}),{defineMultiStyleConfig:Y4,definePartsStyle:Ic}=$t(Lx.keys),Ll=Ze("modal-bg"),$l=Ze("modal-shadow"),Z4={bg:"blackAlpha.600",zIndex:"modal"},J4=t=>{const{isCentered:r,scrollBehavior:e}=t;return{display:"flex",zIndex:"modal",justifyContent:"center",alignItems:r?"center":"flex-start",overflow:e==="inside"?"hidden":"auto",overscrollBehaviorY:"none"}},Q4=t=>{const{isCentered:r,scrollBehavior:e}=t;return{borderRadius:"md",color:"inherit",my:r?"auto":"16",mx:r?"auto":void 0,zIndex:"modal",maxH:e==="inside"?"calc(100% - 7.5rem)":void 0,[Ll.variable]:"colors.white",[$l.variable]:"shadows.lg",_dark:{[Ll.variable]:"colors.gray.700",[$l.variable]:"shadows.dark-lg"},bg:Ll.reference,boxShadow:$l.reference}},e8={px:"6",py:"4",fontSize:"xl",fontWeight:"semibold"},t8={position:"absolute",top:"2",insetEnd:"3"},r8=t=>{const{scrollBehavior:r}=t;return{px:"6",py:"2",flex:"1",overflow:r==="inside"?"auto":void 0}},n8={px:"6",py:"4"},i8=Ic(t=>({overlay:Z4,dialogContainer:Cr(J4,t),dialog:Cr(Q4,t),header:e8,closeButton:t8,body:Cr(r8,t),footer:n8}));function tn(t){return Ic(t==="full"?{dialog:{maxW:"100vw",minH:"$100vh",my:"0",borderRadius:"0"}}:{dialog:{maxW:t}})}var s8={xs:tn("xs"),sm:tn("sm"),md:tn("md"),lg:tn("lg"),xl:tn("xl"),"2xl":tn("2xl"),"3xl":tn("3xl"),"4xl":tn("4xl"),"5xl":tn("5xl"),"6xl":tn("6xl"),full:tn("full")},o8=Y4({baseStyle:i8,sizes:s8,defaultProps:{size:"md"}}),{defineMultiStyleConfig:a8,definePartsStyle:f0}=$t($x.keys),Lu=sr("number-input-stepper-width"),h0=sr("number-input-input-padding"),l8=Rn(Lu).add("0.5rem").toString(),zl=sr("number-input-bg"),Vl=sr("number-input-color"),Ul=sr("number-input-border-color"),c8={[Lu.variable]:"sizes.6",[h0.variable]:l8},u8=t=>{var r,e;return(e=(r=Cr(Pt.baseStyle,t))==null?void 0:r.field)!=null?e:{}},d8={width:Lu.reference},f8={borderStart:"1px solid",borderStartColor:Ul.reference,color:Vl.reference,bg:zl.reference,[Vl.variable]:"colors.chakra-body-text",[Ul.variable]:"colors.chakra-border-color",_dark:{[Vl.variable]:"colors.whiteAlpha.800",[Ul.variable]:"colors.whiteAlpha.300"},_active:{[zl.variable]:"colors.gray.200",_dark:{[zl.variable]:"colors.whiteAlpha.300"}},_disabled:{opacity:.4,cursor:"not-allowed"}},h8=f0(t=>{var r;return{root:c8,field:(r=Cr(u8,t))!=null?r:{},stepperGroup:d8,stepper:f8}});function na(t){var r,e,a;const f=(r=Pt.sizes)==null?void 0:r[t],c={lg:"md",md:"md",sm:"sm",xs:"sm"},s=(a=(e=f.field)==null?void 0:e.fontSize)!=null?a:"md",l=o0.fontSizes[s];return f0({field:{...f.field,paddingInlineEnd:h0.reference,verticalAlign:"top"},stepper:{fontSize:Rn(l).multiply(.75).toString(),_first:{borderTopEndRadius:c[t]},_last:{borderBottomEndRadius:c[t],mt:"-1px",borderTopWidth:1}}})}var p8={xs:na("xs"),sm:na("sm"),md:na("md"),lg:na("lg")},m8=a8({baseStyle:h8,sizes:p8,variants:Pt.variants,defaultProps:Pt.defaultProps}),ph,b8={...(ph=Pt.baseStyle)==null?void 0:ph.field,textAlign:"center"},g8={lg:{fontSize:"lg",w:12,h:12,borderRadius:"md"},md:{fontSize:"md",w:10,h:10,borderRadius:"md"},sm:{fontSize:"sm",w:8,h:8,borderRadius:"sm"},xs:{fontSize:"xs",w:6,h:6,borderRadius:"sm"}},mh,bh,v8={outline:t=>{var r,e,a;return(a=(e=Cr((r=Pt.variants)==null?void 0:r.outline,t))==null?void 0:e.field)!=null?a:{}},flushed:t=>{var r,e,a;return(a=(e=Cr((r=Pt.variants)==null?void 0:r.flushed,t))==null?void 0:e.field)!=null?a:{}},filled:t=>{var r,e,a;return(a=(e=Cr((r=Pt.variants)==null?void 0:r.filled,t))==null?void 0:e.field)!=null?a:{}},unstyled:(bh=(mh=Pt.variants)==null?void 0:mh.unstyled.field)!=null?bh:{}},y8={baseStyle:b8,sizes:g8,variants:v8,defaultProps:Pt.defaultProps},{defineMultiStyleConfig:w8,definePartsStyle:x8}=$t(zx.keys),ia=sr("popper-bg"),_8=sr("popper-arrow-bg"),gh=sr("popper-arrow-shadow-color"),S8={zIndex:10},k8={[ia.variable]:"colors.white",bg:ia.reference,[_8.variable]:ia.reference,[gh.variable]:"colors.gray.200",_dark:{[ia.variable]:"colors.gray.700",[gh.variable]:"colors.whiteAlpha.300"},width:"xs",border:"1px solid",borderColor:"inherit",borderRadius:"md",boxShadow:"sm",zIndex:"inherit",_focusVisible:{outline:0,boxShadow:"outline"}},C8={px:3,py:2,borderBottomWidth:"1px"},T8={px:3,py:2},E8={px:3,py:2,borderTopWidth:"1px"},A8={position:"absolute",borderRadius:"md",top:1,insetEnd:2,padding:2},M8=x8({popper:S8,content:k8,header:C8,body:T8,footer:E8,closeButton:A8}),j8=w8({baseStyle:M8}),{definePartsStyle:Oc,defineMultiStyleConfig:P8}=$t(Rx.keys),Wl=Ze("drawer-bg"),Hl=Ze("drawer-box-shadow");function Di(t){return Oc(t==="full"?{dialog:{maxW:"100vw",h:"100vh"}}:{dialog:{maxW:t}})}var R8={bg:"blackAlpha.600",zIndex:"modal"},I8={display:"flex",zIndex:"modal",justifyContent:"center"},O8=t=>{const{isFullHeight:r}=t;return{...r&&{height:"100vh"},zIndex:"modal",maxH:"100vh",color:"inherit",[Wl.variable]:"colors.white",[Hl.variable]:"shadows.lg",_dark:{[Wl.variable]:"colors.gray.700",[Hl.variable]:"shadows.dark-lg"},bg:Wl.reference,boxShadow:Hl.reference}},N8={px:"6",py:"4",fontSize:"xl",fontWeight:"semibold"},D8={position:"absolute",top:"2",insetEnd:"3"},F8={px:"6",py:"2",flex:"1",overflow:"auto"},B8={px:"6",py:"4"},L8=Oc(t=>({overlay:R8,dialogContainer:I8,dialog:Cr(O8,t),header:N8,closeButton:D8,body:F8,footer:B8})),$8={xs:Di("xs"),sm:Di("md"),md:Di("lg"),lg:Di("2xl"),xl:Di("4xl"),full:Di("full")},z8=P8({baseStyle:L8,sizes:$8,defaultProps:{size:"xs"}}),{definePartsStyle:V8,defineMultiStyleConfig:U8}=$t(Ix.keys),W8={borderRadius:"md",py:"1",transitionProperty:"common",transitionDuration:"normal"},H8={borderRadius:"md",py:"1",transitionProperty:"common",transitionDuration:"normal",width:"full",_focusVisible:{boxShadow:"outline"},_placeholder:{opacity:.6}},q8={borderRadius:"md",py:"1",transitionProperty:"common",transitionDuration:"normal",width:"full",_focusVisible:{boxShadow:"outline"},_placeholder:{opacity:.6}},X8=V8({preview:W8,input:H8,textarea:q8}),K8=U8({baseStyle:X8}),{definePartsStyle:G8,defineMultiStyleConfig:Y8}=$t(Ox.keys),is=Ze("form-control-color"),Z8={marginStart:"1",[is.variable]:"colors.red.500",_dark:{[is.variable]:"colors.red.300"},color:is.reference},J8={mt:"2",[is.variable]:"colors.gray.600",_dark:{[is.variable]:"colors.whiteAlpha.600"},color:is.reference,lineHeight:"normal",fontSize:"sm"},Q8=G8({container:{width:"100%",position:"relative"},requiredIndicator:Z8,helperText:J8}),e_=Y8({baseStyle:Q8}),{definePartsStyle:t_,defineMultiStyleConfig:r_}=$t(Nx.keys),ss=Ze("form-error-color"),n_={[ss.variable]:"colors.red.500",_dark:{[ss.variable]:"colors.red.300"},color:ss.reference,mt:"2",fontSize:"sm",lineHeight:"normal"},i_={marginEnd:"0.5em",[ss.variable]:"colors.red.500",_dark:{[ss.variable]:"colors.red.300"},color:ss.reference},s_=t_({text:n_,icon:i_}),o_=r_({baseStyle:s_}),a_={fontSize:"md",marginEnd:"3",mb:"2",fontWeight:"medium",transitionProperty:"common",transitionDuration:"normal",opacity:1,_disabled:{opacity:.4}},l_={baseStyle:a_},c_={fontFamily:"heading",fontWeight:"bold"},u_={"4xl":{fontSize:["6xl",null,"7xl"],lineHeight:1},"3xl":{fontSize:["5xl",null,"6xl"],lineHeight:1},"2xl":{fontSize:["4xl",null,"5xl"],lineHeight:[1.2,null,1]},xl:{fontSize:["3xl",null,"4xl"],lineHeight:[1.33,null,1.2]},lg:{fontSize:["2xl",null,"3xl"],lineHeight:[1.33,null,1.2]},md:{fontSize:"xl",lineHeight:1.2},sm:{fontSize:"md",lineHeight:1.2},xs:{fontSize:"sm",lineHeight:1.2}},d_={baseStyle:c_,sizes:u_,defaultProps:{size:"xl"}},{defineMultiStyleConfig:f_,definePartsStyle:h_}=$t(jx.keys),ql=Ze("breadcrumb-link-decor"),p_={transitionProperty:"common",transitionDuration:"fast",transitionTimingFunction:"ease-out",outline:"none",color:"inherit",textDecoration:ql.reference,[ql.variable]:"none","&:not([aria-current=page])":{cursor:"pointer",_hover:{[ql.variable]:"underline"},_focusVisible:{boxShadow:"outline"}}},m_=h_({link:p_}),b_=f_({baseStyle:m_}),g_={lineHeight:"1.2",borderRadius:"md",fontWeight:"semibold",transitionProperty:"common",transitionDuration:"normal",_focusVisible:{boxShadow:"outline"},_disabled:{opacity:.4,cursor:"not-allowed",boxShadow:"none"},_hover:{_disabled:{bg:"initial"}}},p0=t=>{const{colorScheme:r,theme:e}=t;if(r==="gray")return{color:Je("gray.800","whiteAlpha.900")(t),_hover:{bg:Je("gray.100","whiteAlpha.200")(t)},_active:{bg:Je("gray.200","whiteAlpha.300")(t)}};const a=ds(`${r}.200`,.12)(e),f=ds(`${r}.200`,.24)(e);return{color:Je(`${r}.600`,`${r}.200`)(t),bg:"transparent",_hover:{bg:Je(`${r}.50`,a)(t)},_active:{bg:Je(`${r}.100`,f)(t)}}},v_=t=>{const{colorScheme:r}=t,e=Je("gray.200","whiteAlpha.300")(t);return{border:"1px solid",borderColor:r==="gray"?e:"currentColor",".chakra-button__group[data-attached][data-orientation=horizontal] > &:not(:last-of-type)":{marginEnd:"-1px"},".chakra-button__group[data-attached][data-orientation=vertical] > &:not(:last-of-type)":{marginBottom:"-1px"},...Cr(p0,t)}},y_={yellow:{bg:"yellow.400",color:"black",hoverBg:"yellow.500",activeBg:"yellow.600"},cyan:{bg:"cyan.400",color:"black",hoverBg:"cyan.500",activeBg:"cyan.600"}},w_=t=>{var r;const{colorScheme:e}=t;if(e==="gray"){const i=Je("gray.100","whiteAlpha.200")(t);return{bg:i,color:Je("gray.800","whiteAlpha.900")(t),_hover:{bg:Je("gray.200","whiteAlpha.300")(t),_disabled:{bg:i}},_active:{bg:Je("gray.300","whiteAlpha.400")(t)}}}const{bg:a=`${e}.500`,color:f="white",hoverBg:c=`${e}.600`,activeBg:s=`${e}.700`}=(r=y_[e])!=null?r:{},l=Je(a,`${e}.200`)(t);return{bg:l,color:Je(f,"gray.800")(t),_hover:{bg:Je(c,`${e}.300`)(t),_disabled:{bg:l}},_active:{bg:Je(s,`${e}.400`)(t)}}},x_=t=>{const{colorScheme:r}=t;return{padding:0,height:"auto",lineHeight:"normal",verticalAlign:"baseline",color:Je(`${r}.500`,`${r}.200`)(t),_hover:{textDecoration:"underline",_disabled:{textDecoration:"none"}},_active:{color:Je(`${r}.700`,`${r}.500`)(t)}}},__={bg:"none",color:"inherit",display:"inline",lineHeight:"inherit",m:"0",p:"0"},S_={ghost:p0,outline:v_,solid:w_,link:x_,unstyled:__},k_={lg:{h:"12",minW:"12",fontSize:"lg",px:"6"},md:{h:"10",minW:"10",fontSize:"md",px:"4"},sm:{h:"8",minW:"8",fontSize:"sm",px:"3"},xs:{h:"6",minW:"6",fontSize:"xs",px:"2"}},C_={baseStyle:g_,variants:S_,sizes:k_,defaultProps:{variant:"solid",size:"md",colorScheme:"gray"}},{definePartsStyle:yi,defineMultiStyleConfig:T_}=$t(Zx.keys),Va=Ze("card-bg"),Nn=Ze("card-padding"),m0=Ze("card-shadow"),Ea=Ze("card-radius"),b0=Ze("card-border-width","0"),g0=Ze("card-border-color"),E_=yi({container:{[Va.variable]:"colors.chakra-body-bg",backgroundColor:Va.reference,boxShadow:m0.reference,borderRadius:Ea.reference,color:"chakra-body-text",borderWidth:b0.reference,borderColor:g0.reference},body:{padding:Nn.reference,flex:"1 1 0%"},header:{padding:Nn.reference},footer:{padding:Nn.reference}}),A_={sm:yi({container:{[Ea.variable]:"radii.base",[Nn.variable]:"space.3"}}),md:yi({container:{[Ea.variable]:"radii.md",[Nn.variable]:"space.5"}}),lg:yi({container:{[Ea.variable]:"radii.xl",[Nn.variable]:"space.7"}})},M_={elevated:yi({container:{[m0.variable]:"shadows.base",_dark:{[Va.variable]:"colors.gray.700"}}}),outline:yi({container:{[b0.variable]:"1px",[g0.variable]:"colors.chakra-border-color"}}),filled:yi({container:{[Va.variable]:"colors.chakra-subtle-bg"}}),unstyled:{body:{[Nn.variable]:0},header:{[Nn.variable]:0},footer:{[Nn.variable]:0}}},j_=T_({baseStyle:E_,variants:M_,sizes:A_,defaultProps:{variant:"elevated",size:"md"}}),eo=sr("close-button-size"),Is=sr("close-button-bg"),P_={w:[eo.reference],h:[eo.reference],borderRadius:"md",transitionProperty:"common",transitionDuration:"normal",_disabled:{opacity:.4,cursor:"not-allowed",boxShadow:"none"},_hover:{[Is.variable]:"colors.blackAlpha.100",_dark:{[Is.variable]:"colors.whiteAlpha.100"}},_active:{[Is.variable]:"colors.blackAlpha.200",_dark:{[Is.variable]:"colors.whiteAlpha.200"}},_focusVisible:{boxShadow:"outline"},bg:Is.reference},R_={lg:{[eo.variable]:"sizes.10",fontSize:"md"},md:{[eo.variable]:"sizes.8",fontSize:"xs"},sm:{[eo.variable]:"sizes.6",fontSize:"2xs"}},I_={baseStyle:P_,sizes:R_,defaultProps:{size:"md"}},{variants:O_,defaultProps:N_}=Js,D_={fontFamily:"mono",fontSize:"sm",px:"0.2em",borderRadius:"sm",bg:tr.bg.reference,color:tr.color.reference,boxShadow:tr.shadow.reference},F_={baseStyle:D_,variants:O_,defaultProps:N_},B_={w:"100%",mx:"auto",maxW:"prose",px:"4"},L_={baseStyle:B_},$_={opacity:.6,borderColor:"inherit"},z_={borderStyle:"solid"},V_={borderStyle:"dashed"},U_={solid:z_,dashed:V_},W_={baseStyle:$_,variants:U_,defaultProps:{variant:"solid"}},{definePartsStyle:H_,defineMultiStyleConfig:q_}=$t(Ex.keys),X_={borderTopWidth:"1px",borderColor:"inherit",_last:{borderBottomWidth:"1px"}},K_={transitionProperty:"common",transitionDuration:"normal",fontSize:"md",_focusVisible:{boxShadow:"outline"},_hover:{bg:"blackAlpha.50"},_disabled:{opacity:.4,cursor:"not-allowed"},px:"4",py:"2"},G_={pt:"2",px:"4",pb:"5"},Y_={fontSize:"1.25em"},Z_=H_({container:X_,button:K_,panel:G_,icon:Y_}),J_=q_({baseStyle:Z_}),{definePartsStyle:Io,defineMultiStyleConfig:Q_}=$t(Ax.keys),Br=Ze("alert-fg"),Fn=Ze("alert-bg"),e9=Io({container:{bg:Fn.reference,px:"4",py:"3"},title:{fontWeight:"bold",lineHeight:"6",marginEnd:"2"},description:{lineHeight:"6"},icon:{color:Br.reference,flexShrink:0,marginEnd:"3",w:"5",h:"6"},spinner:{color:Br.reference,flexShrink:0,marginEnd:"3",w:"5",h:"5"}});function $u(t){const{theme:r,colorScheme:e}=t,a=ds(`${e}.200`,.16)(r);return{light:`colors.${e}.100`,dark:a}}var t9=Io(t=>{const{colorScheme:r}=t,e=$u(t);return{container:{[Br.variable]:`colors.${r}.600`,[Fn.variable]:e.light,_dark:{[Br.variable]:`colors.${r}.200`,[Fn.variable]:e.dark}}}}),r9=Io(t=>{const{colorScheme:r}=t,e=$u(t);return{container:{[Br.variable]:`colors.${r}.600`,[Fn.variable]:e.light,_dark:{[Br.variable]:`colors.${r}.200`,[Fn.variable]:e.dark},paddingStart:"3",borderStartWidth:"4px",borderStartColor:Br.reference}}}),n9=Io(t=>{const{colorScheme:r}=t,e=$u(t);return{container:{[Br.variable]:`colors.${r}.600`,[Fn.variable]:e.light,_dark:{[Br.variable]:`colors.${r}.200`,[Fn.variable]:e.dark},pt:"2",borderTopWidth:"4px",borderTopColor:Br.reference}}}),i9=Io(t=>{const{colorScheme:r}=t;return{container:{[Br.variable]:"colors.white",[Fn.variable]:`colors.${r}.600`,_dark:{[Br.variable]:"colors.gray.900",[Fn.variable]:`colors.${r}.200`},color:Br.reference}}}),s9={subtle:t9,"left-accent":r9,"top-accent":n9,solid:i9},o9=Q_({baseStyle:e9,variants:s9,defaultProps:{variant:"subtle",colorScheme:"blue"}}),{definePartsStyle:v0,defineMultiStyleConfig:a9}=$t(Mx.keys),os=Ze("avatar-border-color"),to=Ze("avatar-bg"),go=Ze("avatar-font-size"),fs=Ze("avatar-size"),l9={borderRadius:"full",border:"0.2em solid",borderColor:os.reference,[os.variable]:"white",_dark:{[os.variable]:"colors.gray.800"}},c9={bg:to.reference,fontSize:go.reference,width:fs.reference,height:fs.reference,lineHeight:"1",[to.variable]:"colors.gray.200",_dark:{[to.variable]:"colors.whiteAlpha.400"}},u9=t=>{const{name:r,theme:e}=t,a=r?g5({string:r}):"colors.gray.400",f=m5(a)(e);let c="white";return f||(c="gray.800"),{bg:to.reference,fontSize:go.reference,color:c,borderColor:os.reference,verticalAlign:"top",width:fs.reference,height:fs.reference,"&:not([data-loaded])":{[to.variable]:a},[os.variable]:"colors.white",_dark:{[os.variable]:"colors.gray.800"}}},d9={fontSize:go.reference,lineHeight:"1"},f9=v0(t=>({badge:Cr(l9,t),excessLabel:Cr(c9,t),container:Cr(u9,t),label:d9}));function Gn(t){const r=t!=="100%"?l0[t]:void 0;return v0({container:{[fs.variable]:r??t,[go.variable]:`calc(${r??t} / 2.5)`},excessLabel:{[fs.variable]:r??t,[go.variable]:`calc(${r??t} / 2.5)`}})}var h9={"2xs":Gn(4),xs:Gn(6),sm:Gn(8),md:Gn(12),lg:Gn(16),xl:Gn(24),"2xl":Gn(32),full:Gn("100%")},p9=a9({baseStyle:f9,sizes:h9,defaultProps:{size:"md"}}),m9={Accordion:J_,Alert:o9,Avatar:p9,Badge:Js,Breadcrumb:b_,Button:C_,Checkbox:za,CloseButton:I_,Code:F_,Container:L_,Divider:W_,Drawer:z8,Editable:K8,Form:e_,FormError:o_,FormLabel:l_,Heading:d_,Input:Pt,Kbd:P4,Link:I4,List:B4,Menu:G4,Modal:o8,NumberInput:m8,PinInput:y8,Popover:j8,Progress:F6,Radio:Y6,Select:n4,Skeleton:s4,SkipLink:a4,Slider:v4,Spinner:x4,Stat:M4,Switch:I5,Table:$5,Tabs:t6,Tag:p6,Textarea:T6,Tooltip:M6,Card:j_,Stepper:Tx},b9={colors:{"chakra-body-text":{_light:"gray.800",_dark:"whiteAlpha.900"},"chakra-body-bg":{_light:"white",_dark:"gray.800"},"chakra-border-color":{_light:"gray.200",_dark:"whiteAlpha.300"},"chakra-inverse-text":{_light:"white",_dark:"gray.800"},"chakra-subtle-bg":{_light:"gray.100",_dark:"gray.700"},"chakra-subtle-text":{_light:"gray.600",_dark:"gray.400"},"chakra-placeholder-color":{_light:"gray.500",_dark:"whiteAlpha.400"}}},g9={global:{body:{fontFamily:"body",color:"chakra-body-text",bg:"chakra-body-bg",transitionProperty:"background-color",transitionDuration:"normal",lineHeight:"base"},"*::placeholder":{color:"chakra-placeholder-color"},"*, *::before, &::after":{borderColor:"chakra-border-color"}}},v9="ltr",y9={useSystemColorMode:!1,initialColorMode:"light",cssVarPrefix:"chakra"},w9={semanticTokens:b9,direction:v9,...Sx,components:m9,styles:g9,config:y9};function x9(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}var _9=x9();function S9(t,r){const e={};return Object.keys(t).forEach(a=>{r.includes(a)||(e[a]=t[a])}),e}function k9(t,r,e,a){const f=typeof r=="string"?r.split("."):[r];for(a=0;a<f.length&&t;a+=1)t=t[f[a]];return t===void 0?e:t}var C9=t=>{const r=new WeakMap;return(a,f,c,s)=>{if(typeof a>"u")return t(a,f,c);r.has(a)||r.set(a,new Map);const l=r.get(a);if(l.has(f))return l.get(f);const i=t(a,f,c,s);return l.set(f,i),i}},y0=C9(k9);function w0(t,r){const e={};return Object.keys(t).forEach(a=>{const f=t[a];r(f,a,t)&&(e[a]=f)}),e}var x0=t=>w0(t,r=>r!=null);function T9(t){return typeof t=="function"}function _0(t,...r){return T9(t)?t(...r):t}function E9(...t){return function(e){t.some(a=>(a?.(e),e?.defaultPrevented))}}var Xl,vh;function A9(){if(vh)return Xl;vh=1;var t=typeof Element<"u",r=typeof Map=="function",e=typeof Set=="function",a=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function f(c,s){if(c===s)return!0;if(c&&s&&typeof c=="object"&&typeof s=="object"){if(c.constructor!==s.constructor)return!1;var l,i,n;if(Array.isArray(c)){if(l=c.length,l!=s.length)return!1;for(i=l;i--!==0;)if(!f(c[i],s[i]))return!1;return!0}var o;if(r&&c instanceof Map&&s instanceof Map){if(c.size!==s.size)return!1;for(o=c.entries();!(i=o.next()).done;)if(!s.has(i.value[0]))return!1;for(o=c.entries();!(i=o.next()).done;)if(!f(i.value[1],s.get(i.value[0])))return!1;return!0}if(e&&c instanceof Set&&s instanceof Set){if(c.size!==s.size)return!1;for(o=c.entries();!(i=o.next()).done;)if(!s.has(i.value[0]))return!1;return!0}if(a&&ArrayBuffer.isView(c)&&ArrayBuffer.isView(s)){if(l=c.length,l!=s.length)return!1;for(i=l;i--!==0;)if(c[i]!==s[i])return!1;return!0}if(c.constructor===RegExp)return c.source===s.source&&c.flags===s.flags;if(c.valueOf!==Object.prototype.valueOf&&typeof c.valueOf=="function"&&typeof s.valueOf=="function")return c.valueOf()===s.valueOf();if(c.toString!==Object.prototype.toString&&typeof c.toString=="function"&&typeof s.toString=="function")return c.toString()===s.toString();if(n=Object.keys(c),l=n.length,l!==Object.keys(s).length)return!1;for(i=l;i--!==0;)if(!Object.prototype.hasOwnProperty.call(s,n[i]))return!1;if(t&&c instanceof Element)return!1;for(i=l;i--!==0;)if(!((n[i]==="_owner"||n[i]==="__v"||n[i]==="__o")&&c.$$typeof)&&!f(c[n[i]],s[n[i]]))return!1;return!0}return c!==c&&s!==s}return Xl=function(s,l){try{return f(s,l)}catch(i){if((i.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw i}},Xl}var M9=A9();const j9=ku(M9);function S0(t,r={}){var e;const{styleConfig:a,...f}=r,{theme:c,colorMode:s}=Ym(),l=t?y0(c,`components.${t}`):void 0,i=a||l,n=gn({theme:c,colorMode:s},(e=i?.defaultProps)!=null?e:{},x0(S9(f,["children"]))),o=G.useRef({});if(i){const u=Jw(i)(n);j9(o.current,u)||(o.current=u)}return o.current}function $r(t,r={}){return S0(t,r)}function or(t,r={}){return S0(t,r)}var P9=new Set([...$w,"textStyle","layerStyle","apply","noOfLines","focusBorderColor","errorBorderColor","as","__css","css","sx"]),R9=new Set(["htmlWidth","htmlHeight","htmlSize","htmlTranslate"]);function I9(t){return R9.has(t)||!P9.has(t)}function O9(t,...r){if(t==null)throw new TypeError("Cannot convert undefined or null to object");const e={...t};for(const a of r)if(a!=null)for(const f in a)Object.prototype.hasOwnProperty.call(a,f)&&(f in e&&delete e[f],e[f]=a[f]);return e}function zu(t){const r=Object.assign({},t);for(let e in r)r[e]===void 0&&delete r[e];return r}var N9=/^((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|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)-.*))$/,D9=Fm(function(t){return N9.test(t)||t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)<91}),F9=D9,B9=function(r){return r!=="theme"},yh=function(r){return typeof r=="string"&&r.charCodeAt(0)>96?F9:B9},wh=function(r,e,a){var f;if(e){var c=e.shouldForwardProp;f=r.__emotion_forwardProp&&c?function(s){return r.__emotion_forwardProp(s)&&c(s)}:c}return typeof f!="function"&&a&&(f=r.__emotion_forwardProp),f},L9=function(r){var e=r.cache,a=r.serialized,f=r.isStringTag;return Lm(e,a,f),hy(function(){return $m(e,a,f)}),null},$9=function t(r,e){var a=r.__emotion_real===r,f=a&&r.__emotion_base||r,c,s;e!==void 0&&(c=e.label,s=e.target);var l=wh(r,e,a),i=l||yh(f),n=!i("as");return function(){var o=arguments,h=a&&r.__emotion_styles!==void 0?r.__emotion_styles.slice(0):[];if(c!==void 0&&h.push("label:"+c+";"),o[0]==null||o[0].raw===void 0)h.push.apply(h,o);else{h.push(o[0][0]);for(var u=o.length,d=1;d<u;d++)h.push(o[d],o[0][d])}var m=Wm(function(b,p,v){var g=n&&b.as||f,x="",C=[],T=b;if(b.theme==null){T={};for(var R in b)T[R]=b[R];T.theme=G.useContext(ho)}typeof b.className=="string"?x=oy(p.registered,C,b.className):b.className!=null&&(x=b.className+" ");var B=Mu(h.concat(C),p.registered,T);x+=p.key+"-"+B.name,s!==void 0&&(x+=" "+s);var I=n&&l===void 0?yh(g):i,F={};for(var L in b)n&&L==="as"||I(L)&&(F[L]=b[L]);return F.className=x,F.ref=v,G.createElement(G.Fragment,null,G.createElement(L9,{cache:p,serialized:B,isStringTag:typeof g=="string"}),G.createElement(g,F))});return m.displayName=c!==void 0?c:"Styled("+(typeof f=="string"?f:f.displayName||f.name||"Component")+")",m.defaultProps=r.defaultProps,m.__emotion_real=m,m.__emotion_base=f,m.__emotion_styles=h,m.__emotion_forwardProp=l,Object.defineProperty(m,"toString",{value:function(){return"."+s}}),m.withComponent=function(b,p){return t(b,Ti({},e,p,{shouldForwardProp:wh(m,p,!0)})).apply(void 0,h)},m}},z9=["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"],Ua=$9.bind();z9.forEach(function(t){Ua[t]=Ua(t)});var xh,V9=(xh=Ua.default)!=null?xh:Ua,U9=({baseStyle:t})=>r=>{const{theme:e,css:a,__css:f,sx:c,...s}=r,l=w0(s,(h,u)=>Vw(u)),i=_0(t,r),n=O9({},f,i,x0(l),c),o=s0(n)(r.theme);return a?[o,a]:o};function Kl(t,r){const{baseStyle:e,...a}=r??{};a.shouldForwardProp||(a.shouldForwardProp=I9);const f=U9({baseStyle:e}),c=V9(t,a)(f);return cr.forwardRef(function(i,n){const{colorMode:o,forced:h}=il();return cr.createElement(c,{ref:n,"data-theme":h?o:void 0,...i})})}function W9(){const t=new Map;return new Proxy(Kl,{apply(r,e,a){return Kl(...a)},get(r,e){return t.has(e)||t.set(e,Kl(e)),t.get(e)}})}var xe=W9();function Se(t){return G.forwardRef(t)}function k0(t={}){const{strict:r=!0,errorMessage:e="useContext: `context` is undefined. Seems you forgot to wrap component within the Provider",name:a}=t,f=G.createContext(void 0);f.displayName=a;function c(){var s;const l=G.useContext(f);if(!l&&r){const i=new Error(e);throw i.name="ContextError",(s=Error.captureStackTrace)==null||s.call(Error,i,c),i}return l}return[f.Provider,c,f]}function H9(t){const{cssVarsRoot:r,theme:e,children:a}=t,f=G.useMemo(()=>Bw(e),[e]);return W.jsxs(by,{theme:f,children:[W.jsx(q9,{root:r}),a]})}function q9({root:t=":host, :root"}){const r=[t,"[data-theme]"].join(",");return W.jsx(nl,{styles:e=>({[r]:e.__cssVars})})}k0({name:"StylesContext",errorMessage:"useStyles: `styles` is undefined. Seems you forgot to wrap the components in `<StylesProvider />` "});function X9(t){return k0({name:`${t}StylesContext`,errorMessage:`useStyles: "styles" is undefined. Seems you forgot to wrap the components in "<${t} />" `})}function K9(){const{colorMode:t}=il();return W.jsx(nl,{styles:r=>{const e=y0(r,"styles.global"),a=_0(e,{theme:r,colorMode:t});return a?s0(a)(r):void 0}})}var Vu=G.createContext({getDocument(){return document},getWindow(){return window}});Vu.displayName="EnvironmentContext";function G9({defer:t}={}){const[,r]=G.useReducer(e=>e+1,0);return Qn(()=>{t&&r()},[t]),G.useContext(Vu)}function C0(t){const{children:r,environment:e,disabled:a}=t,f=G.useRef(null),c=G.useMemo(()=>e||{getDocument:()=>{var l,i;return(i=(l=f.current)==null?void 0:l.ownerDocument)!=null?i:document},getWindow:()=>{var l,i;return(i=(l=f.current)==null?void 0:l.ownerDocument.defaultView)!=null?i:window}},[e]),s=!a||!e;return W.jsxs(Vu.Provider,{value:c,children:[r,s&&W.jsx("span",{id:"__chakra_env",hidden:!0,ref:f})]})}C0.displayName="EnvironmentProvider";var Y9=t=>{const{children:r,colorModeManager:e,portalZIndex:a,resetScope:f,resetCSS:c=!0,theme:s={},environment:l,cssVarsRoot:i,disableEnvironment:n,disableGlobalStyle:o}=t,h=W.jsx(C0,{environment:l,disabled:n,children:r});return W.jsx(H9,{theme:s,cssVarsRoot:i,children:W.jsxs(Gm,{colorModeManager:e,options:s.config,children:[c?W.jsx(yy,{scope:f}):W.jsx(vy,{}),!o&&W.jsx(K9,{}),a?W.jsx(Xm,{zIndex:a,children:h}):h]})})},Z9=(t,r)=>t.find(e=>e.id===r);function _h(t,r){const e=T0(t,r),a=e?t[e].findIndex(f=>f.id===r):-1;return{position:e,index:a}}function T0(t,r){for(const[e,a]of Object.entries(t))if(Z9(a,r))return e}function J9(t){const r=t.includes("right"),e=t.includes("left");let a="center";return r&&(a="flex-end"),e&&(a="flex-start"),{display:"flex",flexDirection:"column",alignItems:a}}function Q9(t){const e=t==="top"||t==="bottom"?"0 auto":void 0,a=t.includes("top")?"env(safe-area-inset-top, 0px)":void 0,f=t.includes("bottom")?"env(safe-area-inset-bottom, 0px)":void 0,c=t.includes("left")?void 0:"env(safe-area-inset-right, 0px)",s=t.includes("right")?void 0:"env(safe-area-inset-left, 0px)";return{position:"fixed",zIndex:"var(--toast-z-index, 5500)",pointerEvents:"none",display:"flex",flexDirection:"column",margin:e,top:a,bottom:f,right:c,left:s}}function xr(t,r=[]){const e=G.useRef(t);return G.useEffect(()=>{e.current=t}),G.useCallback((...a)=>{var f;return(f=e.current)==null?void 0:f.call(e,...a)},r)}function eS(t,r){const e=xr(t);G.useEffect(()=>{if(r==null)return;let a=null;return a=window.setTimeout(()=>{e()},r),()=>{a&&window.clearTimeout(a)}},[r,e])}function Ei(t,r){const e=G.useRef(!1),a=G.useRef(!1);G.useEffect(()=>{if(e.current&&a.current)return t();a.current=!0},r),G.useEffect(()=>(e.current=!0,()=>{e.current=!1}),[])}const Uu=G.createContext({});function cl(t){const r=G.useRef(null);return r.current===null&&(r.current=t()),r.current}const Wu=typeof window<"u",Hu=Wu?G.useLayoutEffect:G.useEffect,Oo=G.createContext(null),qu=G.createContext({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"});class tS extends G.Component{getSnapshotBeforeUpdate(r){const e=this.props.childRef.current;if(e&&r.isPresent&&!this.props.isPresent){const a=e.offsetParent,f=a instanceof HTMLElement&&a.offsetWidth||0,c=this.props.sizeRef.current;c.height=e.offsetHeight||0,c.width=e.offsetWidth||0,c.top=e.offsetTop,c.left=e.offsetLeft,c.right=f-c.width-c.left}return null}componentDidUpdate(){}render(){return this.props.children}}function rS({children:t,isPresent:r,anchorX:e}){const a=G.useId(),f=G.useRef(null),c=G.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:s}=G.useContext(qu);return G.useInsertionEffect(()=>{const{width:l,height:i,top:n,left:o,right:h}=c.current;if(r||!f.current||!l||!i)return;const u=e==="left"?`left: ${o}`:`right: ${h}`;f.current.dataset.motionPopId=a;const d=document.createElement("style");return s&&(d.nonce=s),document.head.appendChild(d),d.sheet&&d.sheet.insertRule(` [data-motion-pop-id="${a}"] { position: absolute !important; width: ${l}px !important; height: ${i}px !important; ${u}px !important; top: ${n}px !important; } `),()=>{document.head.contains(d)&&document.head.removeChild(d)}},[r]),W.jsx(tS,{isPresent:r,childRef:f,sizeRef:c,children:G.cloneElement(t,{ref:f})})}const nS=({children:t,initial:r,isPresent:e,onExitComplete:a,custom:f,presenceAffectsLayout:c,mode:s,anchorX:l})=>{const i=cl(iS),n=G.useId();let o=!0,h=G.useMemo(()=>(o=!1,{id:n,initial:r,isPresent:e,custom:f,onExitComplete:u=>{i.set(u,!0);for(const d of i.values())if(!d)return;a&&a()},register:u=>(i.set(u,!1),()=>i.delete(u))}),[e,i,a]);return c&&o&&(h={...h}),G.useMemo(()=>{i.forEach((u,d)=>i.set(d,!1))},[e]),G.useEffect(()=>{!e&&!i.size&&a&&a()},[e]),s==="popLayout"&&(t=W.jsx(rS,{isPresent:e,anchorX:l,children:t})),W.jsx(Oo.Provider,{value:h,children:t})};function iS(){return new Map}function Xu(t=!0){const r=G.useContext(Oo);if(r===null)return[!0,null];const{isPresent:e,onExitComplete:a,register:f}=r,c=G.useId();G.useEffect(()=>{if(t)return f(c)},[t]);const s=G.useCallback(()=>t&&a&&a(c),[c,a,t]);return!e&&a?[!1,s]:[!0]}function sS(){return oS(G.useContext(Oo))}function oS(t){return t===null?!0:t.isPresent}const sa=t=>t.key||"";function Sh(t){const r=[];return G.Children.forEach(t,e=>{G.isValidElement(e)&&r.push(e)}),r}const Ii=({children:t,custom:r,initial:e=!0,onExitComplete:a,presenceAffectsLayout:f=!0,mode:c="sync",propagate:s=!1,anchorX:l="left"})=>{const[i,n]=Xu(s),o=G.useMemo(()=>Sh(t),[t]),h=s&&!i?[]:o.map(sa),u=G.useRef(!0),d=G.useRef(o),m=cl(()=>new Map),[b,p]=G.useState(o),[v,g]=G.useState(o);Hu(()=>{u.current=!1,d.current=o;for(let T=0;T<v.length;T++){const R=sa(v[T]);h.includes(R)?m.delete(R):m.get(R)!==!0&&m.set(R,!1)}},[v,h.length,h.join("-")]);const x=[];if(o!==b){let T=[...o];for(let R=0;R<v.length;R++){const B=v[R],I=sa(B);h.includes(I)||(T.splice(R,0,B),x.push(B))}return c==="wait"&&x.length&&(T=x),g(Sh(T)),p(o),null}const{forceRender:C}=G.useContext(Uu);return W.jsx(W.Fragment,{children:v.map(T=>{const R=sa(T),B=s&&!i?!1:o===v||h.includes(R),I=()=>{if(m.has(R))m.set(R,!0);else return;let F=!0;m.forEach(L=>{L||(F=!1)}),F&&(C?.(),g(d.current),s&&n?.(),a&&a())};return W.jsx(nS,{isPresent:B,initial:!u.current||e?void 0:!1,custom:r,presenceAffectsLayout:f,mode:c,onExitComplete:B?void 0:I,anchorX:l,children:T},R)})})};function Ku(t,r){t.indexOf(r)===-1&&t.push(r)}function Gu(t,r){const e=t.indexOf(r);e>-1&&t.splice(e,1)}const Bn=(t,r,e)=>e>r?r:e<t?t:e;let Yu=()=>{};const Ln={},E0=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),A0=t=>/^0[^.\s]+$/u.test(t);function Zu(t){let r;return()=>(r===void 0&&(r=t()),r)}const Kr=t=>t,aS=(t,r)=>e=>r(t(e)),No=(...t)=>t.reduce(aS),vo=(t,r,e)=>{const a=r-t;return a===0?1:(e-t)/a};class Ju{constructor(){this.subscriptions=[]}add(r){return Ku(this.subscriptions,r),()=>Gu(this.subscriptions,r)}notify(r,e,a){const f=this.subscriptions.length;if(f)if(f===1)this.subscriptions[0](r,e,a);else for(let c=0;c<f;c++){const s=this.subscriptions[c];s&&s(r,e,a)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const wn=t=>t*1e3,xn=t=>t/1e3;function M0(t,r){return r?t*(1e3/r):0}const j0=(t,r,e)=>(((1-3*e+3*r)*t+(3*e-6*r))*t+3*r)*t,lS=1e-7,cS=12;function uS(t,r,e,a,f){let c,s,l=0;do s=r+(e-r)/2,c=j0(s,a,f)-t,c>0?e=s:r=s;while(Math.abs(c)>lS&&++l<cS);return s}function Do(t,r,e,a){if(t===r&&e===a)return Kr;const f=c=>uS(c,0,1,t,e);return c=>c===0||c===1?c:j0(f(c),r,a)}const P0=t=>r=>r<=.5?t(2*r)/2:(2-t(2*(1-r)))/2,R0=t=>r=>1-t(1-r),I0=Do(.33,1.53,.69,.99),Qu=R0(I0),O0=P0(Qu),N0=t=>(t*=2)<1?.5*Qu(t):.5*(2-Math.pow(2,-10*(t-1))),ed=t=>1-Math.sin(Math.acos(t)),D0=R0(ed),F0=P0(ed),dS=Do(.42,0,1,1),fS=Do(0,0,.58,1),B0=Do(.42,0,.58,1),hS=t=>Array.isArray(t)&&typeof t[0]!="number",L0=t=>Array.isArray(t)&&typeof t[0]=="number",pS={linear:Kr,easeIn:dS,easeInOut:B0,easeOut:fS,circIn:ed,circInOut:F0,circOut:D0,backIn:Qu,backInOut:O0,backOut:I0,anticipate:N0},mS=t=>typeof t=="string",kh=t=>{if(L0(t)){Yu(t.length===4);const[r,e,a,f]=t;return Do(r,e,a,f)}else if(mS(t))return pS[t];return t},oa=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function bS(t,r){let e=new Set,a=new Set,f=!1,c=!1;const s=new WeakSet;let l={delta:0,timestamp:0,isProcessing:!1};function i(o){s.has(o)&&(n.schedule(o),t()),o(l)}const n={schedule:(o,h=!1,u=!1)=>{const m=u&&f?e:a;return h&&s.add(o),m.has(o)||m.add(o),o},cancel:o=>{a.delete(o),s.delete(o)},process:o=>{if(l=o,f){c=!0;return}f=!0,[e,a]=[a,e],e.forEach(i),e.clear(),f=!1,c&&(c=!1,n.process(o))}};return n}const gS=40;function $0(t,r){let e=!1,a=!0;const f={delta:0,timestamp:0,isProcessing:!1},c=()=>e=!0,s=oa.reduce((x,C)=>(x[C]=bS(c),x),{}),{setup:l,read:i,resolveKeyframes:n,preUpdate:o,update:h,preRender:u,render:d,postRender:m}=s,b=()=>{const x=Ln.useManualTiming?f.timestamp:performance.now();e=!1,Ln.useManualTiming||(f.delta=a?1e3/60:Math.max(Math.min(x-f.timestamp,gS),1)),f.timestamp=x,f.isProcessing=!0,l.process(f),i.process(f),n.process(f),o.process(f),h.process(f),u.process(f),d.process(f),m.process(f),f.isProcessing=!1,e&&r&&(a=!1,t(b))},p=()=>{e=!0,a=!0,f.isProcessing||t(b)};return{schedule:oa.reduce((x,C)=>{const T=s[C];return x[C]=(R,B=!1,I=!1)=>(e||p(),T.schedule(R,B,I)),x},{}),cancel:x=>{for(let C=0;C<oa.length;C++)s[oa[C]].cancel(x)},state:f,steps:s}}const{schedule:Yt,cancel:ei,state:fr,steps:Gl}=$0(typeof requestAnimationFrame<"u"?requestAnimationFrame:Kr,!0);let Aa;function vS(){Aa=void 0}const Pr={now:()=>(Aa===void 0&&Pr.set(fr.isProcessing||Ln.useManualTiming?fr.timestamp:performance.now()),Aa),set:t=>{Aa=t,queueMicrotask(vS)}},z0=t=>r=>typeof r=="string"&&r.startsWith(t),td=z0("--"),yS=z0("var(--"),rd=t=>yS(t)?wS.test(t.split("/*")[0].trim()):!1,wS=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,_s={test:t=>typeof t=="number",parse:parseFloat,transform:t=>t},yo={..._s,transform:t=>Bn(0,1,t)},aa={..._s,default:1},ro=t=>Math.round(t*1e5)/1e5,nd=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function xS(t){return t==null}const _S=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,id=(t,r)=>e=>!!(typeof e=="string"&&_S.test(e)&&e.startsWith(t)||r&&!xS(e)&&Object.prototype.hasOwnProperty.call(e,r)),V0=(t,r,e)=>a=>{if(typeof a!="string")return a;const[f,c,s,l]=a.match(nd);return{[t]:parseFloat(f),[r]:parseFloat(c),[e]:parseFloat(s),alpha:l!==void 0?parseFloat(l):1}},SS=t=>Bn(0,255,t),Yl={..._s,transform:t=>Math.round(SS(t))},mi={test:id("rgb","red"),parse:V0("red","green","blue"),transform:({red:t,green:r,blue:e,alpha:a=1})=>"rgba("+Yl.transform(t)+", "+Yl.transform(r)+", "+Yl.transform(e)+", "+ro(yo.transform(a))+")"};function kS(t){let r="",e="",a="",f="";return t.length>5?(r=t.substring(1,3),e=t.substring(3,5),a=t.substring(5,7),f=t.substring(7,9)):(r=t.substring(1,2),e=t.substring(2,3),a=t.substring(3,4),f=t.substring(4,5),r+=r,e+=e,a+=a,f+=f),{red:parseInt(r,16),green:parseInt(e,16),blue:parseInt(a,16),alpha:f?parseInt(f,16)/255:1}}const Nc={test:id("#"),parse:kS,transform:mi.transform},Fo=t=>({test:r=>typeof r=="string"&&r.endsWith(t)&&r.split(" ").length===1,parse:parseFloat,transform:r=>`${r}${t}`}),Yn=Fo("deg"),_n=Fo("%"),nt=Fo("px"),CS=Fo("vh"),TS=Fo("vw"),Ch={..._n,parse:t=>_n.parse(t)/100,transform:t=>_n.transform(t*100)},Gi={test:id("hsl","hue"),parse:V0("hue","saturation","lightness"),transform:({hue:t,saturation:r,lightness:e,alpha:a=1})=>"hsla("+Math.round(t)+", "+_n.transform(ro(r))+", "+_n.transform(ro(e))+", "+ro(yo.transform(a))+")"},gr={test:t=>mi.test(t)||Nc.test(t)||Gi.test(t),parse:t=>mi.test(t)?mi.parse(t):Gi.test(t)?Gi.parse(t):Nc.parse(t),transform:t=>typeof t=="string"?t:t.hasOwnProperty("red")?mi.transform(t):Gi.transform(t)},ES=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function AS(t){return isNaN(t)&&typeof t=="string"&&(t.match(nd)?.length||0)+(t.match(ES)?.length||0)>0}const U0="number",W0="color",MS="var",jS="var(",Th="${}",PS=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function wo(t){const r=t.toString(),e=[],a={color:[],number:[],var:[]},f=[];let c=0;const l=r.replace(PS,i=>(gr.test(i)?(a.color.push(c),f.push(W0),e.push(gr.parse(i))):i.startsWith(jS)?(a.var.push(c),f.push(MS),e.push(i)):(a.number.push(c),f.push(U0),e.push(parseFloat(i))),++c,Th)).split(Th);return{values:e,split:l,indexes:a,types:f}}function H0(t){return wo(t).values}function q0(t){const{split:r,types:e}=wo(t),a=r.length;return f=>{let c="";for(let s=0;s<a;s++)if(c+=r[s],f[s]!==void 0){const l=e[s];l===U0?c+=ro(f[s]):l===W0?c+=gr.transform(f[s]):c+=f[s]}return c}}const RS=t=>typeof t=="number"?0:t;function IS(t){const r=H0(t);return q0(t)(r.map(RS))}const ti={test:AS,parse:H0,createTransformer:q0,getAnimatableNone:IS};function Zl(t,r,e){return e<0&&(e+=1),e>1&&(e-=1),e<1/6?t+(r-t)*6*e:e<1/2?r:e<2/3?t+(r-t)*(2/3-e)*6:t}function OS({hue:t,saturation:r,lightness:e,alpha:a}){t/=360,r/=100,e/=100;let f=0,c=0,s=0;if(!r)f=c=s=e;else{const l=e<.5?e*(1+r):e+r-e*r,i=2*e-l;f=Zl(i,l,t+1/3),c=Zl(i,l,t),s=Zl(i,l,t-1/3)}return{red:Math.round(f*255),green:Math.round(c*255),blue:Math.round(s*255),alpha:a}}function Wa(t,r){return e=>e>0?r:t}const Gt=(t,r,e)=>t+(r-t)*e,Jl=(t,r,e)=>{const a=t*t,f=e*(r*r-a)+a;return f<0?0:Math.sqrt(f)},NS=[Nc,mi,Gi],DS=t=>NS.find(r=>r.test(t));function Eh(t){const r=DS(t);if(!r)return!1;let e=r.parse(t);return r===Gi&&(e=OS(e)),e}const Ah=(t,r)=>{const e=Eh(t),a=Eh(r);if(!e||!a)return Wa(t,r);const f={...e};return c=>(f.red=Jl(e.red,a.red,c),f.green=Jl(e.green,a.green,c),f.blue=Jl(e.blue,a.blue,c),f.alpha=Gt(e.alpha,a.alpha,c),mi.transform(f))},Dc=new Set(["none","hidden"]);function FS(t,r){return Dc.has(t)?e=>e<=0?t:r:e=>e>=1?r:t}function BS(t,r){return e=>Gt(t,r,e)}function sd(t){return typeof t=="number"?BS:typeof t=="string"?rd(t)?Wa:gr.test(t)?Ah:zS:Array.isArray(t)?X0:typeof t=="object"?gr.test(t)?Ah:LS:Wa}function X0(t,r){const e=[...t],a=e.length,f=t.map((c,s)=>sd(c)(c,r[s]));return c=>{for(let s=0;s<a;s++)e[s]=f[s](c);return e}}function LS(t,r){const e={...t,...r},a={};for(const f in e)t[f]!==void 0&&r[f]!==void 0&&(a[f]=sd(t[f])(t[f],r[f]));return f=>{for(const c in a)e[c]=a[c](f);return e}}function $S(t,r){const e=[],a={color:0,var:0,number:0};for(let f=0;f<r.values.length;f++){const c=r.types[f],s=t.indexes[c][a[c]],l=t.values[s]??0;e[f]=l,a[c]++}return e}const zS=(t,r)=>{const e=ti.createTransformer(r),a=wo(t),f=wo(r);return a.indexes.var.length===f.indexes.var.length&&a.indexes.color.length===f.indexes.color.length&&a.indexes.number.length>=f.indexes.number.length?Dc.has(t)&&!f.values.length||Dc.has(r)&&!a.values.length?FS(t,r):No(X0($S(a,f),f.values),e):Wa(t,r)};function K0(t,r,e){return typeof t=="number"&&typeof r=="number"&&typeof e=="number"?Gt(t,r,e):sd(t)(t,r)}const VS=t=>{const r=({timestamp:e})=>t(e);return{start:(e=!0)=>Yt.update(r,e),stop:()=>ei(r),now:()=>fr.isProcessing?fr.timestamp:Pr.now()}},G0=(t,r,e=10)=>{let a="";const f=Math.max(Math.round(r/e),2);for(let c=0;c<f;c++)a+=t(c/(f-1))+", ";return`linear(${a.substring(0,a.length-2)})`},Ha=2e4;function od(t){let r=0;const e=50;let a=t.next(r);for(;!a.done&&r<Ha;)r+=e,a=t.next(r);return r>=Ha?1/0:r}function US(t,r=100,e){const a=e({...t,keyframes:[0,r]}),f=Math.min(od(a),Ha);return{type:"keyframes",ease:c=>a.next(f*c).value/r,duration:xn(f)}}const WS=5;function Y0(t,r,e){const a=Math.max(r-WS,0);return M0(e-t(a),r-a)}const Jt={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},Mh=.001;function HS({duration:t=Jt.duration,bounce:r=Jt.bounce,velocity:e=Jt.velocity,mass:a=Jt.mass}){let f,c,s=1-r;s=Bn(Jt.minDamping,Jt.maxDamping,s),t=Bn(Jt.minDuration,Jt.maxDuration,xn(t)),s<1?(f=n=>{const o=n*s,h=o*t,u=o-e,d=Fc(n,s),m=Math.exp(-h);return Mh-u/d*m},c=n=>{const h=n*s*t,u=h*e+e,d=Math.pow(s,2)*Math.pow(n,2)*t,m=Math.exp(-h),b=Fc(Math.pow(n,2),s);return(-f(n)+Mh>0?-1:1)*((u-d)*m)/b}):(f=n=>{const o=Math.exp(-n*t),h=(n-e)*t+1;return-.001+o*h},c=n=>{const o=Math.exp(-n*t),h=(e-n)*(t*t);return o*h});const l=5/t,i=XS(f,c,l);if(t=wn(t),isNaN(i))return{stiffness:Jt.stiffness,damping:Jt.damping,duration:t};{const n=Math.pow(i,2)*a;return{stiffness:n,damping:s*2*Math.sqrt(a*n),duration:t}}}const qS=12;function XS(t,r,e){let a=e;for(let f=1;f<qS;f++)a=a-t(a)/r(a);return a}function Fc(t,r){return t*Math.sqrt(1-r*r)}const KS=["duration","bounce"],GS=["stiffness","damping","mass"];function jh(t,r){return r.some(e=>t[e]!==void 0)}function YS(t){let r={velocity:Jt.velocity,stiffness:Jt.stiffness,damping:Jt.damping,mass:Jt.mass,isResolvedFromDuration:!1,...t};if(!jh(t,GS)&&jh(t,KS))if(t.visualDuration){const e=t.visualDuration,a=2*Math.PI/(e*1.2),f=a*a,c=2*Bn(.05,1,1-(t.bounce||0))*Math.sqrt(f);r={...r,mass:Jt.mass,stiffness:f,damping:c}}else{const e=HS(t);r={...r,...e,mass:Jt.mass},r.isResolvedFromDuration=!0}return r}function qa(t=Jt.visualDuration,r=Jt.bounce){const e=typeof t!="object"?{visualDuration:t,keyframes:[0,1],bounce:r}:t;let{restSpeed:a,restDelta:f}=e;const c=e.keyframes[0],s=e.keyframes[e.keyframes.length-1],l={done:!1,value:c},{stiffness:i,damping:n,mass:o,duration:h,velocity:u,isResolvedFromDuration:d}=YS({...e,velocity:-xn(e.velocity||0)}),m=u||0,b=n/(2*Math.sqrt(i*o)),p=s-c,v=xn(Math.sqrt(i/o)),g=Math.abs(p)<5;a||(a=g?Jt.restSpeed.granular:Jt.restSpeed.default),f||(f=g?Jt.restDelta.granular:Jt.restDelta.default);let x;if(b<1){const T=Fc(v,b);x=R=>{const B=Math.exp(-b*v*R);return s-B*((m+b*v*p)/T*Math.sin(T*R)+p*Math.cos(T*R))}}else if(b===1)x=T=>s-Math.exp(-v*T)*(p+(m+v*p)*T);else{const T=v*Math.sqrt(b*b-1);x=R=>{const B=Math.exp(-b*v*R),I=Math.min(T*R,300);return s-B*((m+b*v*p)*Math.sinh(I)+T*p*Math.cosh(I))/T}}const C={calculatedDuration:d&&h||null,next:T=>{const R=x(T);if(d)l.done=T>=h;else{let B=T===0?m:0;b<1&&(B=T===0?wn(m):Y0(x,T,R));const I=Math.abs(B)<=a,F=Math.abs(s-R)<=f;l.done=I&&F}return l.value=l.done?s:R,l},toString:()=>{const T=Math.min(od(C),Ha),R=G0(B=>C.next(T*B).value,T,30);return T+"ms "+R},toTransition:()=>{}};return C}qa.applyToOptions=t=>{const r=US(t,100,qa);return t.ease=r.ease,t.duration=wn(r.duration),t.type="keyframes",t};function Bc({keyframes:t,velocity:r=0,power:e=.8,timeConstant:a=325,bounceDamping:f=10,bounceStiffness:c=500,modifyTarget:s,min:l,max:i,restDelta:n=.5,restSpeed:o}){const h=t[0],u={done:!1,value:h},d=I=>l!==void 0&&I<l||i!==void 0&&I>i,m=I=>l===void 0?i:i===void 0||Math.abs(l-I)<Math.abs(i-I)?l:i;let b=e*r;const p=h+b,v=s===void 0?p:s(p);v!==p&&(b=v-h);const g=I=>-b*Math.exp(-I/a),x=I=>v+g(I),C=I=>{const F=g(I),L=x(I);u.done=Math.abs(F)<=n,u.value=u.done?v:L};let T,R;const B=I=>{d(u.value)&&(T=I,R=qa({keyframes:[u.value,m(u.value)],velocity:Y0(x,I,u.value),damping:f,stiffness:c,restDelta:n,restSpeed:o}))};return B(0),{calculatedDuration:null,next:I=>{let F=!1;return!R&&T===void 0&&(F=!0,C(I),B(I)),T!==void 0&&I>=T?R.next(I-T):(!F&&C(I),u)}}}function ZS(t,r,e){const a=[],f=e||Ln.mix||K0,c=t.length-1;for(let s=0;s<c;s++){let l=f(t[s],t[s+1]);if(r){const i=Array.isArray(r)?r[s]||Kr:r;l=No(i,l)}a.push(l)}return a}function JS(t,r,{clamp:e=!0,ease:a,mixer:f}={}){const c=t.length;if(Yu(c===r.length),c===1)return()=>r[0];if(c===2&&r[0]===r[1])return()=>r[1];const s=t[0]===t[1];t[0]>t[c-1]&&(t=[...t].reverse(),r=[...r].reverse());const l=ZS(r,a,f),i=l.length,n=o=>{if(s&&o<t[0])return r[0];let h=0;if(i>1)for(;h<t.length-2&&!(o<t[h+1]);h++);const u=vo(t[h],t[h+1],o);return l[h](u)};return e?o=>n(Bn(t[0],t[c-1],o)):n}function QS(t,r){const e=t[t.length-1];for(let a=1;a<=r;a++){const f=vo(0,r,a);t.push(Gt(e,1,f))}}function e7(t){const r=[0];return QS(r,t.length-1),r}function t7(t,r){return t.map(e=>e*r)}function r7(t,r){return t.map(()=>r||B0).splice(0,t.length-1)}function no({duration:t=300,keyframes:r,times:e,ease:a="easeInOut"}){const f=hS(a)?a.map(kh):kh(a),c={done:!1,value:r[0]},s=t7(e&&e.length===r.length?e:e7(r),t),l=JS(s,r,{ease:Array.isArray(f)?f:r7(r,f)});return{calculatedDuration:t,next:i=>(c.value=l(i),c.done=i>=t,c)}}const n7=t=>t!==null;function ad(t,{repeat:r,repeatType:e="loop"},a,f=1){const c=t.filter(n7),l=f<0||r&&e!=="loop"&&r%2===1?0:c.length-1;return!l||a===void 0?c[l]:a}const i7={decay:Bc,inertia:Bc,tween:no,keyframes:no,spring:qa};function Z0(t){typeof t.type=="string"&&(t.type=i7[t.type])}class ld{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(r=>{this.resolve=r})}notifyFinished(){this.resolve()}then(r,e){return this.finished.then(r,e)}}const s7=t=>t/100;class cd extends ld{constructor(r){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=(e=!0)=>{if(e){const{motionValue:a}=this.options;a&&a.updatedAt!==Pr.now()&&this.tick(Pr.now())}this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=r,this.initAnimation(),this.play(),r.autoplay===!1&&this.pause()}initAnimation(){const{options:r}=this;Z0(r);const{type:e=no,repeat:a=0,repeatDelay:f=0,repeatType:c,velocity:s=0}=r;let{keyframes:l}=r;const i=e||no;i!==no&&typeof l[0]!="number"&&(this.mixKeyframes=No(s7,K0(l[0],l[1])),l=[0,100]);const n=i({...r,keyframes:l});c==="mirror"&&(this.mirroredGenerator=i({...r,keyframes:[...l].reverse(),velocity:-s})),n.calculatedDuration===null&&(n.calculatedDuration=od(n));const{calculatedDuration:o}=n;this.calculatedDuration=o,this.resolvedDuration=o+f,this.totalDuration=this.resolvedDuration*(a+1)-f,this.generator=n}updateTime(r){const e=Math.round(r-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=e}tick(r,e=!1){const{generator:a,totalDuration:f,mixKeyframes:c,mirroredGenerator:s,resolvedDuration:l,calculatedDuration:i}=this;if(this.startTime===null)return a.next(0);const{delay:n=0,keyframes:o,repeat:h,repeatType:u,repeatDelay:d,type:m,onUpdate:b,finalKeyframe:p}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,r):this.speed<0&&(this.startTime=Math.min(r-f/this.speed,this.startTime)),e?this.currentTime=r:this.updateTime(r);const v=this.currentTime-n*(this.playbackSpeed>=0?1:-1),g=this.playbackSpeed>=0?v<0:v>f;this.currentTime=Math.max(v,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=f);let x=this.currentTime,C=a;if(h){const I=Math.min(this.currentTime,f)/l;let F=Math.floor(I),L=I%1;!L&&I>=1&&(L=1),L===1&&F--,F=Math.min(F,h+1),!!(F%2)&&(u==="reverse"?(L=1-L,d&&(L-=d/l)):u==="mirror"&&(C=s)),x=Bn(0,1,L)*l}const T=g?{done:!1,value:o[0]}:C.next(x);c&&(T.value=c(T.value));let{done:R}=T;!g&&i!==null&&(R=this.playbackSpeed>=0?this.currentTime>=f:this.currentTime<=0);const B=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&R);return B&&m!==Bc&&(T.value=ad(o,this.options,p,this.speed)),b&&b(T.value),B&&this.finish(),T}then(r,e){return this.finished.then(r,e)}get duration(){return xn(this.calculatedDuration)}get time(){return xn(this.currentTime)}set time(r){r=wn(r),this.currentTime=r,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=r:this.driver&&(this.startTime=this.driver.now()-r/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(r){this.updateTime(Pr.now());const e=this.playbackSpeed!==r;this.playbackSpeed=r,e&&(this.time=xn(this.currentTime))}play(){if(this.isStopped)return;const{driver:r=VS,startTime:e}=this.options;this.driver||(this.driver=r(f=>this.tick(f))),this.options.onPlay?.();const a=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=a):this.holdTime!==null?this.startTime=a-this.holdTime:this.startTime||(this.startTime=e??a),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(Pr.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(r){return this.startTime=0,this.tick(r,!0)}attachTimeline(r){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),r.observe(this)}}function o7(t){for(let r=1;r<t.length;r++)t[r]??(t[r]=t[r-1])}const bi=t=>t*180/Math.PI,Lc=t=>{const r=bi(Math.atan2(t[1],t[0]));return $c(r)},a7={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:t=>(Math.abs(t[0])+Math.abs(t[3]))/2,rotate:Lc,rotateZ:Lc,skewX:t=>bi(Math.atan(t[1])),skewY:t=>bi(Math.atan(t[2])),skew:t=>(Math.abs(t[1])+Math.abs(t[2]))/2},$c=t=>(t=t%360,t<0&&(t+=360),t),Ph=Lc,Rh=t=>Math.sqrt(t[0]*t[0]+t[1]*t[1]),Ih=t=>Math.sqrt(t[4]*t[4]+t[5]*t[5]),l7={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Rh,scaleY:Ih,scale:t=>(Rh(t)+Ih(t))/2,rotateX:t=>$c(bi(Math.atan2(t[6],t[5]))),rotateY:t=>$c(bi(Math.atan2(-t[2],t[0]))),rotateZ:Ph,rotate:Ph,skewX:t=>bi(Math.atan(t[4])),skewY:t=>bi(Math.atan(t[1])),skew:t=>(Math.abs(t[1])+Math.abs(t[4]))/2};function Oh(t){return t.includes("scale")?1:0}function zc(t,r){if(!t||t==="none")return Oh(r);const e=t.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let a,f;if(e)a=l7,f=e;else{const l=t.match(/^matrix\(([-\d.e\s,]+)\)$/u);a=a7,f=l}if(!f)return Oh(r);const c=a[r],s=f[1].split(",").map(u7);return typeof c=="function"?c(s):s[c]}const c7=(t,r)=>{const{transform:e="none"}=getComputedStyle(t);return zc(e,r)};function u7(t){return parseFloat(t.trim())}const Ss=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],ks=new Set(Ss),Nh=t=>t===_s||t===nt,d7=new Set(["x","y","z"]),f7=Ss.filter(t=>!d7.has(t));function h7(t){const r=[];return f7.forEach(e=>{const a=t.getValue(e);a!==void 0&&(r.push([e,a.get()]),a.set(e.startsWith("scale")?1:0))}),r}const wi={width:({x:t},{paddingLeft:r="0",paddingRight:e="0"})=>t.max-t.min-parseFloat(r)-parseFloat(e),height:({y:t},{paddingTop:r="0",paddingBottom:e="0"})=>t.max-t.min-parseFloat(r)-parseFloat(e),top:(t,{top:r})=>parseFloat(r),left:(t,{left:r})=>parseFloat(r),bottom:({y:t},{top:r})=>parseFloat(r)+(t.max-t.min),right:({x:t},{left:r})=>parseFloat(r)+(t.max-t.min),x:(t,{transform:r})=>zc(r,"x"),y:(t,{transform:r})=>zc(r,"y")};wi.translateX=wi.x;wi.translateY=wi.y;const xi=new Set;let Vc=!1,Uc=!1,Wc=!1;function J0(){if(Uc){const t=Array.from(xi).filter(a=>a.needsMeasurement),r=new Set(t.map(a=>a.element)),e=new Map;r.forEach(a=>{const f=h7(a);f.length&&(e.set(a,f),a.render())}),t.forEach(a=>a.measureInitialState()),r.forEach(a=>{a.render();const f=e.get(a);f&&f.forEach(([c,s])=>{a.getValue(c)?.set(s)})}),t.forEach(a=>a.measureEndState()),t.forEach(a=>{a.suspendedScrollY!==void 0&&window.scrollTo(0,a.suspendedScrollY)})}Uc=!1,Vc=!1,xi.forEach(t=>t.complete(Wc)),xi.clear()}function Q0(){xi.forEach(t=>{t.readKeyframes(),t.needsMeasurement&&(Uc=!0)})}function p7(){Wc=!0,Q0(),J0(),Wc=!1}class ud{constructor(r,e,a,f,c,s=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...r],this.onComplete=e,this.name=a,this.motionValue=f,this.element=c,this.isAsync=s}scheduleResolve(){this.state="scheduled",this.isAsync?(xi.add(this),Vc||(Vc=!0,Yt.read(Q0),Yt.resolveKeyframes(J0))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:r,name:e,element:a,motionValue:f}=this;if(r[0]===null){const c=f?.get(),s=r[r.length-1];if(c!==void 0)r[0]=c;else if(a&&e){const l=a.readValue(e,s);l!=null&&(r[0]=l)}r[0]===void 0&&(r[0]=s),f&&c===void 0&&f.set(r[0])}o7(r)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(r=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,r),xi.delete(this)}cancel(){this.state==="scheduled"&&(xi.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const m7=t=>t.startsWith("--");function b7(t,r,e){m7(r)?t.style.setProperty(r,e):t.style[r]=e}const g7=Zu(()=>window.ScrollTimeline!==void 0),v7={};function y7(t,r){const e=Zu(t);return()=>v7[r]??e()}const e1=y7(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Us=([t,r,e,a])=>`cubic-bezier(${t}, ${r}, ${e}, ${a})`,Dh={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Us([0,.65,.55,1]),circOut:Us([.55,0,1,.45]),backIn:Us([.31,.01,.66,-.59]),backOut:Us([.33,1.53,.69,.99])};function t1(t,r){if(t)return typeof t=="function"?e1()?G0(t,r):"ease-out":L0(t)?Us(t):Array.isArray(t)?t.map(e=>t1(e,r)||Dh.easeOut):Dh[t]}function w7(t,r,e,{delay:a=0,duration:f=300,repeat:c=0,repeatType:s="loop",ease:l="easeOut",times:i}={},n=void 0){const o={[r]:e};i&&(o.offset=i);const h=t1(l,f);Array.isArray(h)&&(o.easing=h);const u={delay:a,duration:f,easing:Array.isArray(h)?"linear":h,fill:"both",iterations:c+1,direction:s==="reverse"?"alternate":"normal"};return n&&(u.pseudoElement=n),t.animate(o,u)}function r1(t){return typeof t=="function"&&"applyToOptions"in t}function x7({type:t,...r}){return r1(t)&&e1()?t.applyToOptions(r):(r.duration??(r.duration=300),r.ease??(r.ease="easeOut"),r)}class _7 extends ld{constructor(r){if(super(),this.finishedTime=null,this.isStopped=!1,!r)return;const{element:e,name:a,keyframes:f,pseudoElement:c,allowFlatten:s=!1,finalKeyframe:l,onComplete:i}=r;this.isPseudoElement=!!c,this.allowFlatten=s,this.options=r,Yu(typeof r.type!="string");const n=x7(r);this.animation=w7(e,a,f,n,c),n.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!c){const o=ad(f,this.options,l,this.speed);this.updateMotionValue?this.updateMotionValue(o):b7(e,a,o),this.animation.cancel()}i?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:r}=this;r==="idle"||r==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const r=this.animation.effect?.getComputedTiming?.().duration||0;return xn(Number(r))}get time(){return xn(Number(this.animation.currentTime)||0)}set time(r){this.finishedTime=null,this.animation.currentTime=wn(r)}get speed(){return this.animation.playbackRate}set speed(r){r<0&&(this.finishedTime=null),this.animation.playbackRate=r}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(r){this.animation.startTime=r}attachTimeline({timeline:r,observe:e}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,r&&g7()?(this.animation.timeline=r,Kr):e(this)}}const n1={anticipate:N0,backInOut:O0,circInOut:F0};function S7(t){return t in n1}function k7(t){typeof t.ease=="string"&&S7(t.ease)&&(t.ease=n1[t.ease])}const Fh=10;class C7 extends _7{constructor(r){k7(r),Z0(r),super(r),r.startTime&&(this.startTime=r.startTime),this.options=r}updateMotionValue(r){const{motionValue:e,onUpdate:a,onComplete:f,element:c,...s}=this.options;if(!e)return;if(r!==void 0){e.set(r);return}const l=new cd({...s,autoplay:!1}),i=wn(this.finishedTime??this.time);e.setWithVelocity(l.sample(i-Fh).value,l.sample(i).value,Fh),l.stop()}}const Bh=(t,r)=>r==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(ti.test(t)||t==="0")&&!t.startsWith("url("));function T7(t){const r=t[0];if(t.length===1)return!0;for(let e=0;e<t.length;e++)if(t[e]!==r)return!0}function E7(t,r,e,a){const f=t[0];if(f===null)return!1;if(r==="display"||r==="visibility")return!0;const c=t[t.length-1],s=Bh(f,r),l=Bh(c,r);return!s||!l?!1:T7(t)||(e==="spring"||r1(e))&&a}const A7=new Set(["opacity","clipPath","filter","transform"]),M7=Zu(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function j7(t){const{motionValue:r,name:e,repeatDelay:a,repeatType:f,damping:c,type:s}=t;if(!r||!r.owner||!(r.owner.current instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:i}=r.owner.getProps();return M7()&&e&&A7.has(e)&&(e!=="transform"||!i)&&!l&&!a&&f!=="mirror"&&c!==0&&s!=="inertia"}const P7=40;class R7 extends ld{constructor({autoplay:r=!0,delay:e=0,type:a="keyframes",repeat:f=0,repeatDelay:c=0,repeatType:s="loop",keyframes:l,name:i,motionValue:n,element:o,...h}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=Pr.now();const u={autoplay:r,delay:e,type:a,repeat:f,repeatDelay:c,repeatType:s,name:i,motionValue:n,element:o,...h},d=o?.KeyframeResolver||ud;this.keyframeResolver=new d(l,(m,b,p)=>this.onKeyframesResolved(m,b,u,!p),i,n,o),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(r,e,a,f){this.keyframeResolver=void 0;const{name:c,type:s,velocity:l,delay:i,isHandoff:n,onUpdate:o}=a;this.resolvedAt=Pr.now(),E7(r,c,s,l)||((Ln.instantAnimations||!i)&&o?.(ad(r,a,e)),r[0]=r[r.length-1],a.duration=0,a.repeat=0);const u={startTime:f?this.resolvedAt?this.resolvedAt-this.createdAt>P7?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:e,...a,keyframes:r},d=!n&&j7(u)?new C7({...u,element:u.motionValue.owner.current}):new cd(u);d.finished.then(()=>this.notifyFinished()).catch(Kr),this.pendingTimeline&&(this.stopTimeline=d.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=d}get finished(){return this._animation?this.animation.finished:this._finished}then(r,e){return this.finished.finally(r).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),p7()),this._animation}get duration(){return this.animation.duration}get time(){return this.animation.time}set time(r){this.animation.time=r}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(r){this.animation.speed=r}get startTime(){return this.animation.startTime}attachTimeline(r){return this._animation?this.stopTimeline=this.animation.attachTimeline(r):this.pendingTimeline=r,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}const I7=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function O7(t){const r=I7.exec(t);if(!r)return[,];const[,e,a,f]=r;return[`--${e??a}`,f]}function i1(t,r,e=1){const[a,f]=O7(t);if(!a)return;const c=window.getComputedStyle(r).getPropertyValue(a);if(c){const s=c.trim();return E0(s)?parseFloat(s):s}return rd(f)?i1(f,r,e+1):f}function dd(t,r){return t?.[r]??t?.default??t}const s1=new Set(["width","height","top","left","right","bottom",...Ss]),N7={test:t=>t==="auto",parse:t=>t},o1=t=>r=>r.test(t),a1=[_s,nt,_n,Yn,TS,CS,N7],Lh=t=>a1.find(o1(t));function D7(t){return typeof t=="number"?t===0:t!==null?t==="none"||t==="0"||A0(t):!0}const F7=new Set(["brightness","contrast","saturate","opacity"]);function B7(t){const[r,e]=t.slice(0,-1).split("(");if(r==="drop-shadow")return t;const[a]=e.match(nd)||[];if(!a)return t;const f=e.replace(a,"");let c=F7.has(r)?1:0;return a!==e&&(c*=100),r+"("+c+f+")"}const L7=/\b([a-z-]*)\(.*?\)/gu,Hc={...ti,getAnimatableNone:t=>{const r=t.match(L7);return r?r.map(B7).join(" "):t}},$h={..._s,transform:Math.round},$7={rotate:Yn,rotateX:Yn,rotateY:Yn,rotateZ:Yn,scale:aa,scaleX:aa,scaleY:aa,scaleZ:aa,skew:Yn,skewX:Yn,skewY:Yn,distance:nt,translateX:nt,translateY:nt,translateZ:nt,x:nt,y:nt,z:nt,perspective:nt,transformPerspective:nt,opacity:yo,originX:Ch,originY:Ch,originZ:nt},fd={borderWidth:nt,borderTopWidth:nt,borderRightWidth:nt,borderBottomWidth:nt,borderLeftWidth:nt,borderRadius:nt,radius:nt,borderTopLeftRadius:nt,borderTopRightRadius:nt,borderBottomRightRadius:nt,borderBottomLeftRadius:nt,width:nt,maxWidth:nt,height:nt,maxHeight:nt,top:nt,right:nt,bottom:nt,left:nt,padding:nt,paddingTop:nt,paddingRight:nt,paddingBottom:nt,paddingLeft:nt,margin:nt,marginTop:nt,marginRight:nt,marginBottom:nt,marginLeft:nt,backgroundPositionX:nt,backgroundPositionY:nt,...$7,zIndex:$h,fillOpacity:yo,strokeOpacity:yo,numOctaves:$h},z7={...fd,color:gr,backgroundColor:gr,outlineColor:gr,fill:gr,stroke:gr,borderColor:gr,borderTopColor:gr,borderRightColor:gr,borderBottomColor:gr,borderLeftColor:gr,filter:Hc,WebkitFilter:Hc},l1=t=>z7[t];function c1(t,r){let e=l1(t);return e!==Hc&&(e=ti),e.getAnimatableNone?e.getAnimatableNone(r):void 0}const V7=new Set(["auto","none","0"]);function U7(t,r,e){let a=0,f;for(;a<t.length&&!f;){const c=t[a];typeof c=="string"&&!V7.has(c)&&wo(c).values.length&&(f=t[a]),a++}if(f&&e)for(const c of r)t[c]=c1(e,f)}class W7 extends ud{constructor(r,e,a,f,c){super(r,e,a,f,c,!0)}readKeyframes(){const{unresolvedKeyframes:r,element:e,name:a}=this;if(!e||!e.current)return;super.readKeyframes();for(let i=0;i<r.length;i++){let n=r[i];if(typeof n=="string"&&(n=n.trim(),rd(n))){const o=i1(n,e.current);o!==void 0&&(r[i]=o),i===r.length-1&&(this.finalKeyframe=n)}}if(this.resolveNoneKeyframes(),!s1.has(a)||r.length!==2)return;const[f,c]=r,s=Lh(f),l=Lh(c);if(s!==l)if(Nh(s)&&Nh(l))for(let i=0;i<r.length;i++){const n=r[i];typeof n=="string"&&(r[i]=parseFloat(n))}else wi[a]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:r,name:e}=this,a=[];for(let f=0;f<r.length;f++)(r[f]===null||D7(r[f]))&&a.push(f);a.length&&U7(r,a,e)}measureInitialState(){const{element:r,unresolvedKeyframes:e,name:a}=this;if(!r||!r.current)return;a==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=wi[a](r.measureViewportBox(),window.getComputedStyle(r.current)),e[0]=this.measuredOrigin;const f=e[e.length-1];f!==void 0&&r.getValue(a,f).jump(f,!1)}measureEndState(){const{element:r,name:e,unresolvedKeyframes:a}=this;if(!r||!r.current)return;const f=r.getValue(e);f&&f.jump(this.measuredOrigin,!1);const c=a.length-1,s=a[c];a[c]=wi[e](r.measureViewportBox(),window.getComputedStyle(r.current)),s!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=s),this.removedTransforms?.length&&this.removedTransforms.forEach(([l,i])=>{r.getValue(l).set(i)}),this.resolveNoneKeyframes()}}function H7(t,r,e){if(t instanceof EventTarget)return[t];if(typeof t=="string"){let a=document;const f=e?.[t]??a.querySelectorAll(t);return f?Array.from(f):[]}return Array.from(t)}const zh=30,q7=t=>!isNaN(parseFloat(t));class X7{constructor(r,e={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=(a,f=!0)=>{const c=Pr.now();if(this.updatedAt!==c&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(a),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const s of this.dependents)s.dirty();f&&this.events.renderRequest?.notify(this.current)},this.hasAnimated=!1,this.setCurrent(r),this.owner=e.owner}setCurrent(r){this.current=r,this.updatedAt=Pr.now(),this.canTrackVelocity===null&&r!==void 0&&(this.canTrackVelocity=q7(this.current))}setPrevFrameValue(r=this.current){this.prevFrameValue=r,this.prevUpdatedAt=this.updatedAt}onChange(r){return this.on("change",r)}on(r,e){this.events[r]||(this.events[r]=new Ju);const a=this.events[r].add(e);return r==="change"?()=>{a(),Yt.read(()=>{this.events.change.getSize()||this.stop()})}:a}clearListeners(){for(const r in this.events)this.events[r].clear()}attach(r,e){this.passiveEffect=r,this.stopPassiveEffect=e}set(r,e=!0){!e||!this.passiveEffect?this.updateAndNotify(r,e):this.passiveEffect(r,this.updateAndNotify)}setWithVelocity(r,e,a){this.set(e),this.prev=void 0,this.prevFrameValue=r,this.prevUpdatedAt=this.updatedAt-a}jump(r,e=!0){this.updateAndNotify(r),this.prev=r,this.prevUpdatedAt=this.prevFrameValue=void 0,e&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(r){this.dependents||(this.dependents=new Set),this.dependents.add(r)}removeDependent(r){this.dependents&&this.dependents.delete(r)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const r=Pr.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||r-this.updatedAt>zh)return 0;const e=Math.min(this.updatedAt-this.prevUpdatedAt,zh);return M0(parseFloat(this.current)-parseFloat(this.prevFrameValue),e)}start(r){return this.stop(),new Promise(e=>{this.hasAnimated=!0,this.animation=r(e),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function hs(t,r){return new X7(t,r)}const u1=(t,r)=>r&&typeof t=="number"?r.transform(t):t,{schedule:hd}=$0(queueMicrotask,!1),nn={x:!1,y:!1};function d1(){return nn.x||nn.y}function K7(t){return t==="x"||t==="y"?nn[t]?null:(nn[t]=!0,()=>{nn[t]=!1}):nn.x||nn.y?null:(nn.x=nn.y=!0,()=>{nn.x=nn.y=!1})}function f1(t,r){const e=H7(t),a=new AbortController,f={passive:!0,...r,signal:a.signal};return[e,f,()=>a.abort()]}function Vh(t){return!(t.pointerType==="touch"||d1())}function G7(t,r,e={}){const[a,f,c]=f1(t,e),s=l=>{if(!Vh(l))return;const{target:i}=l,n=r(i,l);if(typeof n!="function"||!i)return;const o=h=>{Vh(h)&&(n(h),i.removeEventListener("pointerleave",o))};i.addEventListener("pointerleave",o,f)};return a.forEach(l=>{l.addEventListener("pointerenter",s,f)}),c}const h1=(t,r)=>r?t===r?!0:h1(t,r.parentElement):!1,pd=t=>t.pointerType==="mouse"?typeof t.button!="number"||t.button<=0:t.isPrimary!==!1,Y7=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function Z7(t){return Y7.has(t.tagName)||t.tabIndex!==-1}const Ma=new WeakSet;function Uh(t){return r=>{r.key==="Enter"&&t(r)}}function Ql(t,r){t.dispatchEvent(new PointerEvent("pointer"+r,{isPrimary:!0,bubbles:!0}))}const J7=(t,r)=>{const e=t.currentTarget;if(!e)return;const a=Uh(()=>{if(Ma.has(e))return;Ql(e,"down");const f=Uh(()=>{Ql(e,"up")}),c=()=>Ql(e,"cancel");e.addEventListener("keyup",f,r),e.addEventListener("blur",c,r)});e.addEventListener("keydown",a,r),e.addEventListener("blur",()=>e.removeEventListener("keydown",a),r)};function Wh(t){return pd(t)&&!d1()}function Q7(t,r,e={}){const[a,f,c]=f1(t,e),s=l=>{const i=l.currentTarget;if(!Wh(l))return;Ma.add(i);const n=r(i,l),o=(d,m)=>{window.removeEventListener("pointerup",h),window.removeEventListener("pointercancel",u),Ma.has(i)&&Ma.delete(i),Wh(d)&&typeof n=="function"&&n(d,{success:m})},h=d=>{o(d,i===window||i===document||e.useGlobalTarget||h1(i,d.target))},u=d=>{o(d,!1)};window.addEventListener("pointerup",h,f),window.addEventListener("pointercancel",u,f)};return a.forEach(l=>{(e.useGlobalTarget?window:l).addEventListener("pointerdown",s,f),l instanceof HTMLElement&&(l.addEventListener("focus",n=>J7(n,f)),!Z7(l)&&!l.hasAttribute("tabindex")&&(l.tabIndex=0))}),c}const e3=[...a1,gr,ti],t3=t=>e3.find(o1(t)),p1=G.createContext({strict:!1}),Hh={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},ps={};for(const t in Hh)ps[t]={isEnabled:r=>Hh[t].some(e=>!!r[e])};function r3(t){for(const r in t)ps[r]={...ps[r],...t[r]}}const n3=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Xa(t){return t.startsWith("while")||t.startsWith("drag")&&t!=="draggable"||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||n3.has(t)}let m1=t=>!Xa(t);function i3(t){t&&(m1=r=>r.startsWith("on")?!Xa(r):t(r))}try{i3(require("@emotion/is-prop-valid").default)}catch{}function s3(t,r,e){const a={};for(const f in t)f==="values"&&typeof t.values=="object"||(m1(f)||e===!0&&Xa(f)||!r&&!Xa(f)||t.draggable&&f.startsWith("onDrag"))&&(a[f]=t[f]);return a}function o3(t){if(typeof Proxy>"u")return t;const r=new Map,e=(...a)=>t(...a);return new Proxy(e,{get:(a,f)=>f==="create"?t:(r.has(f)||r.set(f,t(f)),r.get(f))})}const ul=G.createContext({});function dl(t){return t!==null&&typeof t=="object"&&typeof t.start=="function"}function xo(t){return typeof t=="string"||Array.isArray(t)}const md=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],bd=["initial",...md];function fl(t){return dl(t.animate)||bd.some(r=>xo(t[r]))}function b1(t){return!!(fl(t)||t.variants)}function a3(t,r){if(fl(t)){const{initial:e,animate:a}=t;return{initial:e===!1||xo(e)?e:void 0,animate:xo(a)?a:void 0}}return t.inherit!==!1?r:{}}function l3(t){const{initial:r,animate:e}=a3(t,G.useContext(ul));return G.useMemo(()=>({initial:r,animate:e}),[qh(r),qh(e)])}function qh(t){return Array.isArray(t)?t.join(" "):t}const c3=Symbol.for("motionComponentSymbol");function Yi(t){return t&&typeof t=="object"&&Object.prototype.hasOwnProperty.call(t,"current")}function u3(t,r,e){return G.useCallback(a=>{a&&t.onMount&&t.onMount(a),r&&(a?r.mount(a):r.unmount()),e&&(typeof e=="function"?e(a):Yi(e)&&(e.current=a))},[r])}const gd=t=>t.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),d3="framerAppearId",g1="data-"+gd(d3),v1=G.createContext({});function f3(t,r,e,a,f){const{visualElement:c}=G.useContext(ul),s=G.useContext(p1),l=G.useContext(Oo),i=G.useContext(qu).reducedMotion,n=G.useRef(null);a=a||s.renderer,!n.current&&a&&(n.current=a(t,{visualState:r,parent:c,props:e,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:i}));const o=n.current,h=G.useContext(v1);o&&!o.projection&&f&&(o.type==="html"||o.type==="svg")&&h3(n.current,e,f,h);const u=G.useRef(!1);G.useInsertionEffect(()=>{o&&u.current&&o.update(e,l)});const d=e[g1],m=G.useRef(!!d&&!window.MotionHandoffIsComplete?.(d)&&window.MotionHasOptimisedAnimation?.(d));return Hu(()=>{o&&(u.current=!0,window.MotionIsMounted=!0,o.updateFeatures(),hd.render(o.render),m.current&&o.animationState&&o.animationState.animateChanges())}),G.useEffect(()=>{o&&(!m.current&&o.animationState&&o.animationState.animateChanges(),m.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(d)}),m.current=!1))}),o}function h3(t,r,e,a){const{layoutId:f,layout:c,drag:s,dragConstraints:l,layoutScroll:i,layoutRoot:n,layoutCrossfade:o}=r;t.projection=new e(t.latestValues,r["data-framer-portal-id"]?void 0:y1(t.parent)),t.projection.setOptions({layoutId:f,layout:c,alwaysMeasureLayout:!!s||l&&Yi(l),visualElement:t,animationType:typeof c=="string"?c:"both",initialPromotionConfig:a,crossfade:o,layoutScroll:i,layoutRoot:n})}function y1(t){if(t)return t.options.allowProjection!==!1?t.projection:y1(t.parent)}function p3({preloadedFeatures:t,createVisualElement:r,useRender:e,useVisualState:a,Component:f}){t&&r3(t);function c(l,i){let n;const o={...G.useContext(qu),...l,layoutId:m3(l)},{isStatic:h}=o,u=l3(l),d=a(l,h);if(!h&&Wu){b3();const m=g3(o);n=m.MeasureLayout,u.visualElement=f3(f,d,o,r,m.ProjectionNode)}return W.jsxs(ul.Provider,{value:u,children:[n&&u.visualElement?W.jsx(n,{visualElement:u.visualElement,...o}):null,e(f,l,u3(d,u.visualElement,i),d,h,u.visualElement)]})}c.displayName=`motion.${typeof f=="string"?f:`create(${f.displayName??f.name??""})`}`;const s=G.forwardRef(c);return s[c3]=f,s}function m3({layoutId:t}){const r=G.useContext(Uu).id;return r&&t!==void 0?r+"-"+t:t}function b3(t,r){G.useContext(p1).strict}function g3(t){const{drag:r,layout:e}=ps;if(!r&&!e)return{};const a={...r,...e};return{MeasureLayout:r?.isEnabled(t)||e?.isEnabled(t)?a.MeasureLayout:void 0,ProjectionNode:a.ProjectionNode}}const _o={};function v3(t){for(const r in t)_o[r]=t[r],td(r)&&(_o[r].isCSSVariable=!0)}function w1(t,{layout:r,layoutId:e}){return ks.has(t)||t.startsWith("origin")||(r||e!==void 0)&&(!!_o[t]||t==="opacity")}const vr=t=>!!(t&&t.getVelocity),y3={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},w3=Ss.length;function x3(t,r,e){let a="",f=!0;for(let c=0;c<w3;c++){const s=Ss[c],l=t[s];if(l===void 0)continue;let i=!0;if(typeof l=="number"?i=l===(s.startsWith("scale")?1:0):i=parseFloat(l)===0,!i||e){const n=u1(l,fd[s]);if(!i){f=!1;const o=y3[s]||s;a+=`${o}(${n}) `}e&&(r[s]=n)}}return a=a.trim(),e?a=e(r,f?"":a):f&&(a="none"),a}function vd(t,r,e){const{style:a,vars:f,transformOrigin:c}=t;let s=!1,l=!1;for(const i in r){const n=r[i];if(ks.has(i)){s=!0;continue}else if(td(i)){f[i]=n;continue}else{const o=u1(n,fd[i]);i.startsWith("origin")?(l=!0,c[i]=o):a[i]=o}}if(r.transform||(s||e?a.transform=x3(r,t.transform,e):a.transform&&(a.transform="none")),l){const{originX:i="50%",originY:n="50%",originZ:o=0}=c;a.transformOrigin=`${i} ${n} ${o}`}}const yd=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function x1(t,r,e){for(const a in r)!vr(r[a])&&!w1(a,e)&&(t[a]=r[a])}function _3({transformTemplate:t},r){return G.useMemo(()=>{const e=yd();return vd(e,r,t),Object.assign({},e.vars,e.style)},[r])}function S3(t,r){const e=t.style||{},a={};return x1(a,e,t),Object.assign(a,_3(t,r)),a}function k3(t,r){const e={},a=S3(t,r);return t.drag&&t.dragListener!==!1&&(e.draggable=!1,a.userSelect=a.WebkitUserSelect=a.WebkitTouchCallout="none",a.touchAction=t.drag===!0?"none":`pan-${t.drag==="x"?"y":"x"}`),t.tabIndex===void 0&&(t.onTap||t.onTapStart||t.whileTap)&&(e.tabIndex=0),e.style=a,e}const C3=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function wd(t){return typeof t!="string"||t.includes("-")?!1:!!(C3.indexOf(t)>-1||/[A-Z]/u.test(t))}const T3={offset:"stroke-dashoffset",array:"stroke-dasharray"},E3={offset:"strokeDashoffset",array:"strokeDasharray"};function A3(t,r,e=1,a=0,f=!0){t.pathLength=1;const c=f?T3:E3;t[c.offset]=nt.transform(-a);const s=nt.transform(r),l=nt.transform(e);t[c.array]=`${s} ${l}`}function _1(t,{attrX:r,attrY:e,attrScale:a,pathLength:f,pathSpacing:c=1,pathOffset:s=0,...l},i,n,o){if(vd(t,l,n),i){t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox);return}t.attrs=t.style,t.style={};const{attrs:h,style:u}=t;h.transform&&(u.transform=h.transform,delete h.transform),(u.transform||h.transformOrigin)&&(u.transformOrigin=h.transformOrigin??"50% 50%",delete h.transformOrigin),u.transform&&(u.transformBox=o?.transformBox??"fill-box",delete h.transformBox),r!==void 0&&(h.x=r),e!==void 0&&(h.y=e),a!==void 0&&(h.scale=a),f!==void 0&&A3(h,f,c,s,!1)}const S1=()=>({...yd(),attrs:{}}),k1=t=>typeof t=="string"&&t.toLowerCase()==="svg";function M3(t,r,e,a){const f=G.useMemo(()=>{const c=S1();return _1(c,r,k1(a),t.transformTemplate,t.style),{...c.attrs,style:{...c.style}}},[r]);if(t.style){const c={};x1(c,t.style,t),f.style={...c,...f.style}}return f}function j3(t=!1){return(e,a,f,{latestValues:c},s)=>{const i=(wd(e)?M3:k3)(a,c,s,e),n=s3(a,typeof e=="string",t),o=e!==G.Fragment?{...n,...i,ref:f}:{},{children:h}=a,u=G.useMemo(()=>vr(h)?h.get():h,[h]);return G.createElement(e,{...o,children:u})}}function Xh(t){const r=[{},{}];return t?.values.forEach((e,a)=>{r[0][a]=e.get(),r[1][a]=e.getVelocity()}),r}function xd(t,r,e,a){if(typeof r=="function"){const[f,c]=Xh(a);r=r(e!==void 0?e:t.custom,f,c)}if(typeof r=="string"&&(r=t.variants&&t.variants[r]),typeof r=="function"){const[f,c]=Xh(a);r=r(e!==void 0?e:t.custom,f,c)}return r}function ja(t){return vr(t)?t.get():t}function P3({scrapeMotionValuesFromProps:t,createRenderState:r},e,a,f){return{latestValues:R3(e,a,f,t),renderState:r()}}const C1=t=>(r,e)=>{const a=G.useContext(ul),f=G.useContext(Oo),c=()=>P3(t,r,a,f);return e?c():cl(c)};function R3(t,r,e,a){const f={},c=a(t,{});for(const u in c)f[u]=ja(c[u]);let{initial:s,animate:l}=t;const i=fl(t),n=b1(t);r&&n&&!i&&t.inherit!==!1&&(s===void 0&&(s=r.initial),l===void 0&&(l=r.animate));let o=e?e.initial===!1:!1;o=o||s===!1;const h=o?l:s;if(h&&typeof h!="boolean"&&!dl(h)){const u=Array.isArray(h)?h:[h];for(let d=0;d<u.length;d++){const m=xd(t,u[d]);if(m){const{transitionEnd:b,transition:p,...v}=m;for(const g in v){let x=v[g];if(Array.isArray(x)){const C=o?x.length-1:0;x=x[C]}x!==null&&(f[g]=x)}for(const g in b)f[g]=b[g]}}}return f}function _d(t,r,e){const{style:a}=t,f={};for(const c in a)(vr(a[c])||r.style&&vr(r.style[c])||w1(c,t)||e?.getValue(c)?.liveStyle!==void 0)&&(f[c]=a[c]);return f}const I3={useVisualState:C1({scrapeMotionValuesFromProps:_d,createRenderState:yd})};function T1(t,r,e){const a=_d(t,r,e);for(const f in t)if(vr(t[f])||vr(r[f])){const c=Ss.indexOf(f)!==-1?"attr"+f.charAt(0).toUpperCase()+f.substring(1):f;a[c]=t[f]}return a}const O3={useVisualState:C1({scrapeMotionValuesFromProps:T1,createRenderState:S1})};function N3(t,r){return function(a,{forwardMotionProps:f}={forwardMotionProps:!1}){const s={...wd(a)?O3:I3,preloadedFeatures:t,useRender:j3(f),createVisualElement:r,Component:a};return p3(s)}}function So(t,r,e){const a=t.getProps();return xd(a,r,e!==void 0?e:a.custom,t)}const qc=t=>Array.isArray(t);function D3(t,r,e){t.hasValue(r)?t.getValue(r).set(e):t.addValue(r,hs(e))}function F3(t){return qc(t)?t[t.length-1]||0:t}function Sd(t,r){const e=So(t,r);let{transitionEnd:a={},transition:f={},...c}=e||{};c={...c,...a};for(const s in c){const l=F3(c[s]);D3(t,s,l)}}function B3(t){return!!(vr(t)&&t.add)}function Xc(t,r){const e=t.getValue("willChange");if(B3(e))return e.add(r);if(!e&&Ln.WillChange){const a=new Ln.WillChange("auto");t.addValue("willChange",a),a.add(r)}}function E1(t){return t.props[g1]}const L3=t=>t!==null;function $3(t,{repeat:r,repeatType:e="loop"},a){const f=t.filter(L3),c=r&&e!=="loop"&&r%2===1?0:f.length-1;return f[c]}const z3={type:"spring",stiffness:500,damping:25,restSpeed:10},V3=t=>({type:"spring",stiffness:550,damping:t===0?2*Math.sqrt(550):30,restSpeed:10}),U3={type:"keyframes",duration:.8},W3={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},H3=(t,{keyframes:r})=>r.length>2?U3:ks.has(t)?t.startsWith("scale")?V3(r[1]):z3:W3;function q3({when:t,delay:r,delayChildren:e,staggerChildren:a,staggerDirection:f,repeat:c,repeatType:s,repeatDelay:l,from:i,elapsed:n,...o}){return!!Object.keys(o).length}const kd=(t,r,e,a={},f,c)=>s=>{const l=dd(a,t)||{},i=l.delay||a.delay||0;let{elapsed:n=0}=a;n=n-wn(i);const o={keyframes:Array.isArray(e)?e:[null,e],ease:"easeOut",velocity:r.getVelocity(),...l,delay:-n,onUpdate:u=>{r.set(u),l.onUpdate&&l.onUpdate(u)},onComplete:()=>{s(),l.onComplete&&l.onComplete()},name:t,motionValue:r,element:c?void 0:f};q3(l)||Object.assign(o,H3(t,o)),o.duration&&(o.duration=wn(o.duration)),o.repeatDelay&&(o.repeatDelay=wn(o.repeatDelay)),o.from!==void 0&&(o.keyframes[0]=o.from);let h=!1;if((o.type===!1||o.duration===0&&!o.repeatDelay)&&(o.duration=0,o.delay===0&&(h=!0)),(Ln.instantAnimations||Ln.skipAnimations)&&(h=!0,o.duration=0,o.delay=0),o.allowFlatten=!l.type&&!l.ease,h&&!c&&r.get()!==void 0){const u=$3(o.keyframes,l);if(u!==void 0){Yt.update(()=>{o.onUpdate(u),o.onComplete()});return}}return l.isSync?new cd(o):new R7(o)};function X3({protectedKeys:t,needsAnimating:r},e){const a=t.hasOwnProperty(e)&&r[e]!==!0;return r[e]=!1,a}function A1(t,r,{delay:e=0,transitionOverride:a,type:f}={}){let{transition:c=t.getDefaultTransition(),transitionEnd:s,...l}=r;a&&(c=a);const i=[],n=f&&t.animationState&&t.animationState.getState()[f];for(const o in l){const h=t.getValue(o,t.latestValues[o]??null),u=l[o];if(u===void 0||n&&X3(n,o))continue;const d={delay:e,...dd(c||{},o)},m=h.get();if(m!==void 0&&!h.isAnimating&&!Array.isArray(u)&&u===m&&!d.velocity)continue;let b=!1;if(window.MotionHandoffAnimation){const v=E1(t);if(v){const g=window.MotionHandoffAnimation(v,o,Yt);g!==null&&(d.startTime=g,b=!0)}}Xc(t,o),h.start(kd(o,h,u,t.shouldReduceMotion&&s1.has(o)?{type:!1}:d,t,b));const p=h.animation;p&&i.push(p)}return s&&Promise.all(i).then(()=>{Yt.update(()=>{s&&Sd(t,s)})}),i}function Kc(t,r,e={}){const a=So(t,r,e.type==="exit"?t.presenceContext?.custom:void 0);let{transition:f=t.getDefaultTransition()||{}}=a||{};e.transitionOverride&&(f=e.transitionOverride);const c=a?()=>Promise.all(A1(t,a,e)):()=>Promise.resolve(),s=t.variantChildren&&t.variantChildren.size?(i=0)=>{const{delayChildren:n=0,staggerChildren:o,staggerDirection:h}=f;return K3(t,r,n+i,o,h,e)}:()=>Promise.resolve(),{when:l}=f;if(l){const[i,n]=l==="beforeChildren"?[c,s]:[s,c];return i().then(()=>n())}else return Promise.all([c(),s(e.delay)])}function K3(t,r,e=0,a=0,f=1,c){const s=[],l=(t.variantChildren.size-1)*a,i=f===1?(n=0)=>n*a:(n=0)=>l-n*a;return Array.from(t.variantChildren).sort(G3).forEach((n,o)=>{n.notify("AnimationStart",r),s.push(Kc(n,r,{...c,delay:e+i(o)}).then(()=>n.notify("AnimationComplete",r)))}),Promise.all(s)}function G3(t,r){return t.sortNodePosition(r)}function M1(t,r,e={}){t.notify("AnimationStart",r);let a;if(Array.isArray(r)){const f=r.map(c=>Kc(t,c,e));a=Promise.all(f)}else if(typeof r=="string")a=Kc(t,r,e);else{const f=typeof r=="function"?So(t,r,e.custom):r;a=Promise.all(A1(t,f,e))}return a.then(()=>{t.notify("AnimationComplete",r)})}function j1(t,r){if(!Array.isArray(r))return!1;const e=r.length;if(e!==t.length)return!1;for(let a=0;a<e;a++)if(r[a]!==t[a])return!1;return!0}const Y3=bd.length;function P1(t){if(!t)return;if(!t.isControllingVariants){const e=t.parent?P1(t.parent)||{}:{};return t.props.initial!==void 0&&(e.initial=t.props.initial),e}const r={};for(let e=0;e<Y3;e++){const a=bd[e],f=t.props[a];(xo(f)||f===!1)&&(r[a]=f)}return r}const Z3=[...md].reverse(),J3=md.length;function Q3(t){return r=>Promise.all(r.map(({animation:e,options:a})=>M1(t,e,a)))}function ek(t){let r=Q3(t),e=Kh(),a=!0;const f=i=>(n,o)=>{const h=So(t,o,i==="exit"?t.presenceContext?.custom:void 0);if(h){const{transition:u,transitionEnd:d,...m}=h;n={...n,...m,...d}}return n};function c(i){r=i(t)}function s(i){const{props:n}=t,o=P1(t.parent)||{},h=[],u=new Set;let d={},m=1/0;for(let p=0;p<J3;p++){const v=Z3[p],g=e[v],x=n[v]!==void 0?n[v]:o[v],C=xo(x),T=v===i?g.isActive:null;T===!1&&(m=p);let R=x===o[v]&&x!==n[v]&&C;if(R&&a&&t.manuallyAnimateOnMount&&(R=!1),g.protectedKeys={...d},!g.isActive&&T===null||!x&&!g.prevProp||dl(x)||typeof x=="boolean")continue;const B=tk(g.prevProp,x);let I=B||v===i&&g.isActive&&!R&&C||p>m&&C,F=!1;const L=Array.isArray(x)?x:[x];let V=L.reduce(f(v),{});T===!1&&(V={});const{prevResolvedValues:z={}}=g,E={...z,...V},P=w=>{I=!0,u.has(w)&&(F=!0,u.delete(w)),g.needsAnimating[w]=!0;const _=t.getValue(w);_&&(_.liveStyle=!1)};for(const w in E){const _=V[w],S=z[w];if(d.hasOwnProperty(w))continue;let A=!1;qc(_)&&qc(S)?A=!j1(_,S):A=_!==S,A?_!=null?P(w):u.add(w):_!==void 0&&u.has(w)?P(w):g.protectedKeys[w]=!0}g.prevProp=x,g.prevResolvedValues=V,g.isActive&&(d={...d,...V}),a&&t.blockInitialAnimation&&(I=!1),I&&(!(R&&B)||F)&&h.push(...L.map(w=>({animation:w,options:{type:v}})))}if(u.size){const p={};if(typeof n.initial!="boolean"){const v=So(t,Array.isArray(n.initial)?n.initial[0]:n.initial);v&&v.transition&&(p.transition=v.transition)}u.forEach(v=>{const g=t.getBaseTarget(v),x=t.getValue(v);x&&(x.liveStyle=!0),p[v]=g??null}),h.push({animation:p})}let b=!!h.length;return a&&(n.initial===!1||n.initial===n.animate)&&!t.manuallyAnimateOnMount&&(b=!1),a=!1,b?r(h):Promise.resolve()}function l(i,n){if(e[i].isActive===n)return Promise.resolve();t.variantChildren?.forEach(h=>h.animationState?.setActive(i,n)),e[i].isActive=n;const o=s(i);for(const h in e)e[h].protectedKeys={};return o}return{animateChanges:s,setActive:l,setAnimateFunction:c,getState:()=>e,reset:()=>{e=Kh(),a=!0}}}function tk(t,r){return typeof r=="string"?r!==t:Array.isArray(r)?!j1(r,t):!1}function ci(t=!1){return{isActive:t,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Kh(){return{animate:ci(!0),whileInView:ci(),whileHover:ci(),whileTap:ci(),whileDrag:ci(),whileFocus:ci(),exit:ci()}}class ni{constructor(r){this.isMounted=!1,this.node=r}update(){}}class rk extends ni{constructor(r){super(r),r.animationState||(r.animationState=ek(r))}updateAnimationControlsSubscription(){const{animate:r}=this.node.getProps();dl(r)&&(this.unmountControls=r.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:r}=this.node.getProps(),{animate:e}=this.node.prevProps||{};r!==e&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let nk=0;class ik extends ni{constructor(){super(...arguments),this.id=nk++}update(){if(!this.node.presenceContext)return;const{isPresent:r,onExitComplete:e}=this.node.presenceContext,{isPresent:a}=this.node.prevPresenceContext||{};if(!this.node.animationState||r===a)return;const f=this.node.animationState.setActive("exit",!r);e&&!r&&f.then(()=>{e(this.id)})}mount(){const{register:r,onExitComplete:e}=this.node.presenceContext||{};e&&e(this.id),r&&(this.unmount=r(this.id))}unmount(){}}const sk={animation:{Feature:rk},exit:{Feature:ik}};function ko(t,r,e,a={passive:!0}){return t.addEventListener(r,e,a),()=>t.removeEventListener(r,e)}function Bo(t){return{point:{x:t.pageX,y:t.pageY}}}const ok=t=>r=>pd(r)&&t(r,Bo(r));function io(t,r,e,a){return ko(t,r,ok(e),a)}function R1({top:t,left:r,right:e,bottom:a}){return{x:{min:r,max:e},y:{min:t,max:a}}}function ak({x:t,y:r}){return{top:r.min,right:t.max,bottom:r.max,left:t.min}}function lk(t,r){if(!r)return t;const e=r({x:t.left,y:t.top}),a=r({x:t.right,y:t.bottom});return{top:e.y,left:e.x,bottom:a.y,right:a.x}}const I1=1e-4,ck=1-I1,uk=1+I1,O1=.01,dk=0-O1,fk=0+O1;function Sr(t){return t.max-t.min}function hk(t,r,e){return Math.abs(t-r)<=e}function Gh(t,r,e,a=.5){t.origin=a,t.originPoint=Gt(r.min,r.max,t.origin),t.scale=Sr(e)/Sr(r),t.translate=Gt(e.min,e.max,t.origin)-t.originPoint,(t.scale>=ck&&t.scale<=uk||isNaN(t.scale))&&(t.scale=1),(t.translate>=dk&&t.translate<=fk||isNaN(t.translate))&&(t.translate=0)}function so(t,r,e,a){Gh(t.x,r.x,e.x,a?a.originX:void 0),Gh(t.y,r.y,e.y,a?a.originY:void 0)}function Yh(t,r,e){t.min=e.min+r.min,t.max=t.min+Sr(r)}function pk(t,r,e){Yh(t.x,r.x,e.x),Yh(t.y,r.y,e.y)}function Zh(t,r,e){t.min=r.min-e.min,t.max=t.min+Sr(r)}function oo(t,r,e){Zh(t.x,r.x,e.x),Zh(t.y,r.y,e.y)}const Jh=()=>({translate:0,scale:1,origin:0,originPoint:0}),Zi=()=>({x:Jh(),y:Jh()}),Qh=()=>({min:0,max:0}),er=()=>({x:Qh(),y:Qh()});function Hr(t){return[t("x"),t("y")]}function ec(t){return t===void 0||t===1}function Gc({scale:t,scaleX:r,scaleY:e}){return!ec(t)||!ec(r)||!ec(e)}function ui(t){return Gc(t)||N1(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}function N1(t){return ep(t.x)||ep(t.y)}function ep(t){return t&&t!=="0%"}function Ka(t,r,e){const a=t-e,f=r*a;return e+f}function tp(t,r,e,a,f){return f!==void 0&&(t=Ka(t,f,a)),Ka(t,e,a)+r}function Yc(t,r=0,e=1,a,f){t.min=tp(t.min,r,e,a,f),t.max=tp(t.max,r,e,a,f)}function D1(t,{x:r,y:e}){Yc(t.x,r.translate,r.scale,r.originPoint),Yc(t.y,e.translate,e.scale,e.originPoint)}const rp=.999999999999,np=1.0000000000001;function mk(t,r,e,a=!1){const f=e.length;if(!f)return;r.x=r.y=1;let c,s;for(let l=0;l<f;l++){c=e[l],s=c.projectionDelta;const{visualElement:i}=c.options;i&&i.props.style&&i.props.style.display==="contents"||(a&&c.options.layoutScroll&&c.scroll&&c!==c.root&&Qi(t,{x:-c.scroll.offset.x,y:-c.scroll.offset.y}),s&&(r.x*=s.x.scale,r.y*=s.y.scale,D1(t,s)),a&&ui(c.latestValues)&&Qi(t,c.latestValues))}r.x<np&&r.x>rp&&(r.x=1),r.y<np&&r.y>rp&&(r.y=1)}function Ji(t,r){t.min=t.min+r,t.max=t.max+r}function ip(t,r,e,a,f=.5){const c=Gt(t.min,t.max,f);Yc(t,r,e,c,a)}function Qi(t,r){ip(t.x,r.x,r.scaleX,r.scale,r.originX),ip(t.y,r.y,r.scaleY,r.scale,r.originY)}function F1(t,r){return R1(lk(t.getBoundingClientRect(),r))}function bk(t,r,e){const a=F1(t,e),{scroll:f}=r;return f&&(Ji(a.x,f.offset.x),Ji(a.y,f.offset.y)),a}const B1=({current:t})=>t?t.ownerDocument.defaultView:null,sp=(t,r)=>Math.abs(t-r);function gk(t,r){const e=sp(t.x,r.x),a=sp(t.y,r.y);return Math.sqrt(e**2+a**2)}class L1{constructor(r,e,{transformPagePoint:a,contextWindow:f,dragSnapToOrigin:c=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const h=rc(this.lastMoveEventInfo,this.history),u=this.startEvent!==null,d=gk(h.offset,{x:0,y:0})>=3;if(!u&&!d)return;const{point:m}=h,{timestamp:b}=fr;this.history.push({...m,timestamp:b});const{onStart:p,onMove:v}=this.handlers;u||(p&&p(this.lastMoveEvent,h),this.startEvent=this.lastMoveEvent),v&&v(this.lastMoveEvent,h)},this.handlePointerMove=(h,u)=>{this.lastMoveEvent=h,this.lastMoveEventInfo=tc(u,this.transformPagePoint),Yt.update(this.updatePoint,!0)},this.handlePointerUp=(h,u)=>{this.end();const{onEnd:d,onSessionEnd:m,resumeAnimation:b}=this.handlers;if(this.dragSnapToOrigin&&b&&b(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const p=rc(h.type==="pointercancel"?this.lastMoveEventInfo:tc(u,this.transformPagePoint),this.history);this.startEvent&&d&&d(h,p),m&&m(h,p)},!pd(r))return;this.dragSnapToOrigin=c,this.handlers=e,this.transformPagePoint=a,this.contextWindow=f||window;const s=Bo(r),l=tc(s,this.transformPagePoint),{point:i}=l,{timestamp:n}=fr;this.history=[{...i,timestamp:n}];const{onSessionStart:o}=e;o&&o(r,rc(l,this.history)),this.removeListeners=No(io(this.contextWindow,"pointermove",this.handlePointerMove),io(this.contextWindow,"pointerup",this.handlePointerUp),io(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(r){this.handlers=r}end(){this.removeListeners&&this.removeListeners(),ei(this.updatePoint)}}function tc(t,r){return r?{point:r(t.point)}:t}function op(t,r){return{x:t.x-r.x,y:t.y-r.y}}function rc({point:t},r){return{point:t,delta:op(t,$1(r)),offset:op(t,vk(r)),velocity:yk(r,.1)}}function vk(t){return t[0]}function $1(t){return t[t.length-1]}function yk(t,r){if(t.length<2)return{x:0,y:0};let e=t.length-1,a=null;const f=$1(t);for(;e>=0&&(a=t[e],!(f.timestamp-a.timestamp>wn(r)));)e--;if(!a)return{x:0,y:0};const c=xn(f.timestamp-a.timestamp);if(c===0)return{x:0,y:0};const s={x:(f.x-a.x)/c,y:(f.y-a.y)/c};return s.x===1/0&&(s.x=0),s.y===1/0&&(s.y=0),s}function wk(t,{min:r,max:e},a){return r!==void 0&&t<r?t=a?Gt(r,t,a.min):Math.max(t,r):e!==void 0&&t>e&&(t=a?Gt(e,t,a.max):Math.min(t,e)),t}function ap(t,r,e){return{min:r!==void 0?t.min+r:void 0,max:e!==void 0?t.max+e-(t.max-t.min):void 0}}function xk(t,{top:r,left:e,bottom:a,right:f}){return{x:ap(t.x,e,f),y:ap(t.y,r,a)}}function lp(t,r){let e=r.min-t.min,a=r.max-t.max;return r.max-r.min<t.max-t.min&&([e,a]=[a,e]),{min:e,max:a}}function _k(t,r){return{x:lp(t.x,r.x),y:lp(t.y,r.y)}}function Sk(t,r){let e=.5;const a=Sr(t),f=Sr(r);return f>a?e=vo(r.min,r.max-a,t.min):a>f&&(e=vo(t.min,t.max-f,r.min)),Bn(0,1,e)}function kk(t,r){const e={};return r.min!==void 0&&(e.min=r.min-t.min),r.max!==void 0&&(e.max=r.max-t.min),e}const Zc=.35;function Ck(t=Zc){return t===!1?t=0:t===!0&&(t=Zc),{x:cp(t,"left","right"),y:cp(t,"top","bottom")}}function cp(t,r,e){return{min:up(t,r),max:up(t,e)}}function up(t,r){return typeof t=="number"?t:t[r]||0}const Tk=new WeakMap;class Ek{constructor(r){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=er(),this.visualElement=r}start(r,{snapToCursor:e=!1}={}){const{presenceContext:a}=this.visualElement;if(a&&a.isPresent===!1)return;const f=o=>{const{dragSnapToOrigin:h}=this.getProps();h?this.pauseAnimation():this.stopAnimation(),e&&this.snapToCursor(Bo(o).point)},c=(o,h)=>{const{drag:u,dragPropagation:d,onDragStart:m}=this.getProps();if(u&&!d&&(this.openDragLock&&this.openDragLock(),this.openDragLock=K7(u),!this.openDragLock))return;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Hr(p=>{let v=this.getAxisMotionValue(p).get()||0;if(_n.test(v)){const{projection:g}=this.visualElement;if(g&&g.layout){const x=g.layout.layoutBox[p];x&&(v=Sr(x)*(parseFloat(v)/100))}}this.originPoint[p]=v}),m&&Yt.postRender(()=>m(o,h)),Xc(this.visualElement,"transform");const{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},s=(o,h)=>{const{dragPropagation:u,dragDirectionLock:d,onDirectionLock:m,onDrag:b}=this.getProps();if(!u&&!this.openDragLock)return;const{offset:p}=h;if(d&&this.currentDirection===null){this.currentDirection=Ak(p),this.currentDirection!==null&&m&&m(this.currentDirection);return}this.updateAxis("x",h.point,p),this.updateAxis("y",h.point,p),this.visualElement.render(),b&&b(o,h)},l=(o,h)=>this.stop(o,h),i=()=>Hr(o=>this.getAnimationState(o)==="paused"&&this.getAxisMotionValue(o).animation?.play()),{dragSnapToOrigin:n}=this.getProps();this.panSession=new L1(r,{onSessionStart:f,onStart:c,onMove:s,onSessionEnd:l,resumeAnimation:i},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:n,contextWindow:B1(this.visualElement)})}stop(r,e){const a=this.isDragging;if(this.cancel(),!a)return;const{velocity:f}=e;this.startAnimation(f);const{onDragEnd:c}=this.getProps();c&&Yt.postRender(()=>c(r,e))}cancel(){this.isDragging=!1;const{projection:r,animationState:e}=this.visualElement;r&&(r.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:a}=this.getProps();!a&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),e&&e.setActive("whileDrag",!1)}updateAxis(r,e,a){const{drag:f}=this.getProps();if(!a||!la(r,f,this.currentDirection))return;const c=this.getAxisMotionValue(r);let s=this.originPoint[r]+a[r];this.constraints&&this.constraints[r]&&(s=wk(s,this.constraints[r],this.elastic[r])),c.set(s)}resolveConstraints(){const{dragConstraints:r,dragElastic:e}=this.getProps(),a=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,f=this.constraints;r&&Yi(r)?this.constraints||(this.constraints=this.resolveRefConstraints()):r&&a?this.constraints=xk(a.layoutBox,r):this.constraints=!1,this.elastic=Ck(e),f!==this.constraints&&a&&this.constraints&&!this.hasMutatedConstraints&&Hr(c=>{this.constraints!==!1&&this.getAxisMotionValue(c)&&(this.constraints[c]=kk(a.layoutBox[c],this.constraints[c]))})}resolveRefConstraints(){const{dragConstraints:r,onMeasureDragConstraints:e}=this.getProps();if(!r||!Yi(r))return!1;const a=r.current,{projection:f}=this.visualElement;if(!f||!f.layout)return!1;const c=bk(a,f.root,this.visualElement.getTransformPagePoint());let s=_k(f.layout.layoutBox,c);if(e){const l=e(ak(s));this.hasMutatedConstraints=!!l,l&&(s=R1(l))}return s}startAnimation(r){const{drag:e,dragMomentum:a,dragElastic:f,dragTransition:c,dragSnapToOrigin:s,onDragTransitionEnd:l}=this.getProps(),i=this.constraints||{},n=Hr(o=>{if(!la(o,e,this.currentDirection))return;let h=i&&i[o]||{};s&&(h={min:0,max:0});const u=f?200:1e6,d=f?40:1e7,m={type:"inertia",velocity:a?r[o]:0,bounceStiffness:u,bounceDamping:d,timeConstant:750,restDelta:1,restSpeed:10,...c,...h};return this.startAxisValueAnimation(o,m)});return Promise.all(n).then(l)}startAxisValueAnimation(r,e){const a=this.getAxisMotionValue(r);return Xc(this.visualElement,r),a.start(kd(r,a,0,e,this.visualElement,!1))}stopAnimation(){Hr(r=>this.getAxisMotionValue(r).stop())}pauseAnimation(){Hr(r=>this.getAxisMotionValue(r).animation?.pause())}getAnimationState(r){return this.getAxisMotionValue(r).animation?.state}getAxisMotionValue(r){const e=`_drag${r.toUpperCase()}`,a=this.visualElement.getProps(),f=a[e];return f||this.visualElement.getValue(r,(a.initial?a.initial[r]:void 0)||0)}snapToCursor(r){Hr(e=>{const{drag:a}=this.getProps();if(!la(e,a,this.currentDirection))return;const{projection:f}=this.visualElement,c=this.getAxisMotionValue(e);if(f&&f.layout){const{min:s,max:l}=f.layout.layoutBox[e];c.set(r[e]-Gt(s,l,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:r,dragConstraints:e}=this.getProps(),{projection:a}=this.visualElement;if(!Yi(e)||!a||!this.constraints)return;this.stopAnimation();const f={x:0,y:0};Hr(s=>{const l=this.getAxisMotionValue(s);if(l&&this.constraints!==!1){const i=l.get();f[s]=Sk({min:i,max:i},this.constraints[s])}});const{transformTemplate:c}=this.visualElement.getProps();this.visualElement.current.style.transform=c?c({},""):"none",a.root&&a.root.updateScroll(),a.updateLayout(),this.resolveConstraints(),Hr(s=>{if(!la(s,r,null))return;const l=this.getAxisMotionValue(s),{min:i,max:n}=this.constraints[s];l.set(Gt(i,n,f[s]))})}addListeners(){if(!this.visualElement.current)return;Tk.set(this.visualElement,this);const r=this.visualElement.current,e=io(r,"pointerdown",i=>{const{drag:n,dragListener:o=!0}=this.getProps();n&&o&&this.start(i)}),a=()=>{const{dragConstraints:i}=this.getProps();Yi(i)&&i.current&&(this.constraints=this.resolveRefConstraints())},{projection:f}=this.visualElement,c=f.addEventListener("measure",a);f&&!f.layout&&(f.root&&f.root.updateScroll(),f.updateLayout()),Yt.read(a);const s=ko(window,"resize",()=>this.scalePositionWithinConstraints()),l=f.addEventListener("didUpdate",({delta:i,hasLayoutChanged:n})=>{this.isDragging&&n&&(Hr(o=>{const h=this.getAxisMotionValue(o);h&&(this.originPoint[o]+=i[o].translate,h.set(h.get()+i[o].translate))}),this.visualElement.render())});return()=>{s(),e(),c(),l&&l()}}getProps(){const r=this.visualElement.getProps(),{drag:e=!1,dragDirectionLock:a=!1,dragPropagation:f=!1,dragConstraints:c=!1,dragElastic:s=Zc,dragMomentum:l=!0}=r;return{...r,drag:e,dragDirectionLock:a,dragPropagation:f,dragConstraints:c,dragElastic:s,dragMomentum:l}}}function la(t,r,e){return(r===!0||r===t)&&(e===null||e===t)}function Ak(t,r=10){let e=null;return Math.abs(t.y)>r?e="y":Math.abs(t.x)>r&&(e="x"),e}class Mk extends ni{constructor(r){super(r),this.removeGroupControls=Kr,this.removeListeners=Kr,this.controls=new Ek(r)}mount(){const{dragControls:r}=this.node.getProps();r&&(this.removeGroupControls=r.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Kr}unmount(){this.removeGroupControls(),this.removeListeners()}}const dp=t=>(r,e)=>{t&&Yt.postRender(()=>t(r,e))};class jk extends ni{constructor(){super(...arguments),this.removePointerDownListener=Kr}onPointerDown(r){this.session=new L1(r,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:B1(this.node)})}createPanHandlers(){const{onPanSessionStart:r,onPanStart:e,onPan:a,onPanEnd:f}=this.node.getProps();return{onSessionStart:dp(r),onStart:dp(e),onMove:a,onEnd:(c,s)=>{delete this.session,f&&Yt.postRender(()=>f(c,s))}}}mount(){this.removePointerDownListener=io(this.node.current,"pointerdown",r=>this.onPointerDown(r))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const Pa={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function fp(t,r){return r.max===r.min?0:t/(r.max-r.min)*100}const Os={correct:(t,r)=>{if(!r.target)return t;if(typeof t=="string")if(nt.test(t))t=parseFloat(t);else return t;const e=fp(t,r.target.x),a=fp(t,r.target.y);return`${e}% ${a}%`}},Pk={correct:(t,{treeScale:r,projectionDelta:e})=>{const a=t,f=ti.parse(t);if(f.length>5)return a;const c=ti.createTransformer(t),s=typeof f[0]!="number"?1:0,l=e.x.scale*r.x,i=e.y.scale*r.y;f[0+s]/=l,f[1+s]/=i;const n=Gt(l,i,.5);return typeof f[2+s]=="number"&&(f[2+s]/=n),typeof f[3+s]=="number"&&(f[3+s]/=n),c(f)}};class Rk extends G.Component{componentDidMount(){const{visualElement:r,layoutGroup:e,switchLayoutGroup:a,layoutId:f}=this.props,{projection:c}=r;v3(Ik),c&&(e.group&&e.group.add(c),a&&a.register&&f&&a.register(c),c.root.didUpdate(),c.addEventListener("animationComplete",()=>{this.safeToRemove()}),c.setOptions({...c.options,onExitComplete:()=>this.safeToRemove()})),Pa.hasEverUpdated=!0}getSnapshotBeforeUpdate(r){const{layoutDependency:e,visualElement:a,drag:f,isPresent:c}=this.props,{projection:s}=a;return s&&(s.isPresent=c,f||r.layoutDependency!==e||e===void 0||r.isPresent!==c?s.willUpdate():this.safeToRemove(),r.isPresent!==c&&(c?s.promote():s.relegate()||Yt.postRender(()=>{const l=s.getStack();(!l||!l.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:r}=this.props.visualElement;r&&(r.root.didUpdate(),hd.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:r,layoutGroup:e,switchLayoutGroup:a}=this.props,{projection:f}=r;f&&(f.scheduleCheckAfterUnmount(),e&&e.group&&e.group.remove(f),a&&a.deregister&&a.deregister(f))}safeToRemove(){const{safeToRemove:r}=this.props;r&&r()}render(){return null}}function z1(t){const[r,e]=Xu(),a=G.useContext(Uu);return W.jsx(Rk,{...t,layoutGroup:a,switchLayoutGroup:G.useContext(v1),isPresent:r,safeToRemove:e})}const Ik={borderRadius:{...Os,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Os,borderTopRightRadius:Os,borderBottomLeftRadius:Os,borderBottomRightRadius:Os,boxShadow:Pk};function Ok(t,r,e){const a=vr(t)?t:hs(t);return a.start(kd("",a,r,e)),a.animation}function Nk(t){return t instanceof SVGElement&&t.tagName!=="svg"}const Dk=(t,r)=>t.depth-r.depth;class Fk{constructor(){this.children=[],this.isDirty=!1}add(r){Ku(this.children,r),this.isDirty=!0}remove(r){Gu(this.children,r),this.isDirty=!0}forEach(r){this.isDirty&&this.children.sort(Dk),this.isDirty=!1,this.children.forEach(r)}}function Bk(t,r){const e=Pr.now(),a=({timestamp:f})=>{const c=f-e;c>=r&&(ei(a),t(c-r))};return Yt.setup(a,!0),()=>ei(a)}const V1=["TopLeft","TopRight","BottomLeft","BottomRight"],Lk=V1.length,hp=t=>typeof t=="string"?parseFloat(t):t,pp=t=>typeof t=="number"||nt.test(t);function $k(t,r,e,a,f,c){f?(t.opacity=Gt(0,e.opacity??1,zk(a)),t.opacityExit=Gt(r.opacity??1,0,Vk(a))):c&&(t.opacity=Gt(r.opacity??1,e.opacity??1,a));for(let s=0;s<Lk;s++){const l=`border${V1[s]}Radius`;let i=mp(r,l),n=mp(e,l);if(i===void 0&&n===void 0)continue;i||(i=0),n||(n=0),i===0||n===0||pp(i)===pp(n)?(t[l]=Math.max(Gt(hp(i),hp(n),a),0),(_n.test(n)||_n.test(i))&&(t[l]+="%")):t[l]=n}(r.rotate||e.rotate)&&(t.rotate=Gt(r.rotate||0,e.rotate||0,a))}function mp(t,r){return t[r]!==void 0?t[r]:t.borderRadius}const zk=U1(0,.5,D0),Vk=U1(.5,.95,Kr);function U1(t,r,e){return a=>a<t?0:a>r?1:e(vo(t,r,a))}function bp(t,r){t.min=r.min,t.max=r.max}function Vr(t,r){bp(t.x,r.x),bp(t.y,r.y)}function gp(t,r){t.translate=r.translate,t.scale=r.scale,t.originPoint=r.originPoint,t.origin=r.origin}function vp(t,r,e,a,f){return t-=r,t=Ka(t,1/e,a),f!==void 0&&(t=Ka(t,1/f,a)),t}function Uk(t,r=0,e=1,a=.5,f,c=t,s=t){if(_n.test(r)&&(r=parseFloat(r),r=Gt(s.min,s.max,r/100)-s.min),typeof r!="number")return;let l=Gt(c.min,c.max,a);t===c&&(l-=r),t.min=vp(t.min,r,e,l,f),t.max=vp(t.max,r,e,l,f)}function yp(t,r,[e,a,f],c,s){Uk(t,r[e],r[a],r[f],r.scale,c,s)}const Wk=["x","scaleX","originX"],Hk=["y","scaleY","originY"];function wp(t,r,e,a){yp(t.x,r,Wk,e?e.x:void 0,a?a.x:void 0),yp(t.y,r,Hk,e?e.y:void 0,a?a.y:void 0)}function xp(t){return t.translate===0&&t.scale===1}function W1(t){return xp(t.x)&&xp(t.y)}function _p(t,r){return t.min===r.min&&t.max===r.max}function qk(t,r){return _p(t.x,r.x)&&_p(t.y,r.y)}function Sp(t,r){return Math.round(t.min)===Math.round(r.min)&&Math.round(t.max)===Math.round(r.max)}function H1(t,r){return Sp(t.x,r.x)&&Sp(t.y,r.y)}function kp(t){return Sr(t.x)/Sr(t.y)}function Cp(t,r){return t.translate===r.translate&&t.scale===r.scale&&t.originPoint===r.originPoint}class Xk{constructor(){this.members=[]}add(r){Ku(this.members,r),r.scheduleRender()}remove(r){if(Gu(this.members,r),r===this.prevLead&&(this.prevLead=void 0),r===this.lead){const e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(r){const e=this.members.findIndex(f=>r===f);if(e===0)return!1;let a;for(let f=e;f>=0;f--){const c=this.members[f];if(c.isPresent!==!1){a=c;break}}return a?(this.promote(a),!0):!1}promote(r,e){const a=this.lead;if(r!==a&&(this.prevLead=a,this.lead=r,r.show(),a)){a.instance&&a.scheduleRender(),r.scheduleRender(),r.resumeFrom=a,e&&(r.resumeFrom.preserveOpacity=!0),a.snapshot&&(r.snapshot=a.snapshot,r.snapshot.latestValues=a.animationValues||a.latestValues),r.root&&r.root.isUpdating&&(r.isLayoutDirty=!0);const{crossfade:f}=r.options;f===!1&&a.hide()}}exitAnimationComplete(){this.members.forEach(r=>{const{options:e,resumingFrom:a}=r;e.onExitComplete&&e.onExitComplete(),a&&a.options.onExitComplete&&a.options.onExitComplete()})}scheduleRender(){this.members.forEach(r=>{r.instance&&r.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function Kk(t,r,e){let a="";const f=t.x.translate/r.x,c=t.y.translate/r.y,s=e?.z||0;if((f||c||s)&&(a=`translate3d(${f}px, ${c}px, ${s}px) `),(r.x!==1||r.y!==1)&&(a+=`scale(${1/r.x}, ${1/r.y}) `),e){const{transformPerspective:n,rotate:o,rotateX:h,rotateY:u,skewX:d,skewY:m}=e;n&&(a=`perspective(${n}px) ${a}`),o&&(a+=`rotate(${o}deg) `),h&&(a+=`rotateX(${h}deg) `),u&&(a+=`rotateY(${u}deg) `),d&&(a+=`skewX(${d}deg) `),m&&(a+=`skewY(${m}deg) `)}const l=t.x.scale*r.x,i=t.y.scale*r.y;return(l!==1||i!==1)&&(a+=`scale(${l}, ${i})`),a||"none"}const nc=["","X","Y","Z"],Gk={visibility:"hidden"},Yk=1e3;let Zk=0;function ic(t,r,e,a){const{latestValues:f}=r;f[t]&&(e[t]=f[t],r.setStaticValue(t,0),a&&(a[t]=0))}function q1(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;const{visualElement:r}=t.options;if(!r)return;const e=E1(r);if(window.MotionHasOptimisedAnimation(e,"transform")){const{layout:f,layoutId:c}=t.options;window.MotionCancelOptimisedAnimation(e,"transform",Yt,!(f||c))}const{parent:a}=t;a&&!a.hasCheckedOptimisedAppear&&q1(a)}function X1({attachResizeListener:t,defaultParent:r,measureScroll:e,checkIsScrollRoot:a,resetTransform:f}){return class{constructor(s={},l=r?.()){this.id=Zk++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(eC),this.nodes.forEach(sC),this.nodes.forEach(oC),this.nodes.forEach(tC)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=s,this.root=l?l.root||l:this,this.path=l?[...l.path,l]:[],this.parent=l,this.depth=l?l.depth+1:0;for(let i=0;i<this.path.length;i++)this.path[i].shouldResetTransform=!0;this.root===this&&(this.nodes=new Fk)}addEventListener(s,l){return this.eventHandlers.has(s)||this.eventHandlers.set(s,new Ju),this.eventHandlers.get(s).add(l)}notifyListeners(s,...l){const i=this.eventHandlers.get(s);i&&i.notify(...l)}hasListeners(s){return this.eventHandlers.has(s)}mount(s){if(this.instance)return;this.isSVG=Nk(s),this.instance=s;const{layoutId:l,layout:i,visualElement:n}=this.options;if(n&&!n.current&&n.mount(s),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(i||l)&&(this.isLayoutDirty=!0),t){let o;const h=()=>this.root.updateBlockedByResize=!1;t(s,()=>{this.root.updateBlockedByResize=!0,o&&o(),o=Bk(h,250),Pa.hasAnimatedSinceResize&&(Pa.hasAnimatedSinceResize=!1,this.nodes.forEach(Ep))})}l&&this.root.registerSharedNode(l,this),this.options.animate!==!1&&n&&(l||i)&&this.addEventListener("didUpdate",({delta:o,hasLayoutChanged:h,hasRelativeLayoutChanged:u,layout:d})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const m=this.options.transition||n.getDefaultTransition()||dC,{onLayoutAnimationStart:b,onLayoutAnimationComplete:p}=n.getProps(),v=!this.targetLayout||!H1(this.targetLayout,d),g=!h&&u;if(this.options.layoutRoot||this.resumeFrom||g||h&&(v||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(o,g);const x={...dd(m,"layout"),onPlay:b,onComplete:p};(n.shouldReduceMotion||this.options.layoutRoot)&&(x.delay=0,x.type=!1),this.startAnimation(x)}else h||Ep(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=d})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const s=this.getStack();s&&s.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),ei(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(aC),this.animationId++)}getTransformTemplate(){const{visualElement:s}=this.options;return s&&s.getProps().transformTemplate}willUpdate(s=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&q1(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let o=0;o<this.path.length;o++){const h=this.path[o];h.shouldResetTransform=!0,h.updateScroll("snapshot"),h.options.layoutRoot&&h.willUpdate(!1)}const{layoutId:l,layout:i}=this.options;if(l===void 0&&!i)return;const n=this.getTransformTemplate();this.prevTransformTemplateValue=n?n(this.latestValues,""):void 0,this.updateSnapshot(),s&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(Tp);return}this.isUpdating||this.nodes.forEach(nC),this.isUpdating=!1,this.nodes.forEach(iC),this.nodes.forEach(Jk),this.nodes.forEach(Qk),this.clearAllSnapshots();const l=Pr.now();fr.delta=Bn(0,1e3/60,l-fr.timestamp),fr.timestamp=l,fr.isProcessing=!0,Gl.update.process(fr),Gl.preRender.process(fr),Gl.render.process(fr),fr.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,hd.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(rC),this.sharedNodes.forEach(lC)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,Yt.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){Yt.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Sr(this.snapshot.measuredBox.x)&&!Sr(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let i=0;i<this.path.length;i++)this.path[i].updateScroll();const s=this.layout;this.layout=this.measure(!1),this.layoutCorrected=er(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:l}=this.options;l&&l.notify("LayoutMeasure",this.layout.layoutBox,s?s.layoutBox:void 0)}updateScroll(s="measure"){let l=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===s&&(l=!1),l&&this.instance){const i=a(this.instance);this.scroll={animationId:this.root.animationId,phase:s,isRoot:i,offset:e(this.instance),wasRoot:this.scroll?this.scroll.isRoot:i}}}resetTransform(){if(!f)return;const s=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,l=this.projectionDelta&&!W1(this.projectionDelta),i=this.getTransformTemplate(),n=i?i(this.latestValues,""):void 0,o=n!==this.prevTransformTemplateValue;s&&this.instance&&(l||ui(this.latestValues)||o)&&(f(this.instance,n),this.shouldResetTransform=!1,this.scheduleRender())}measure(s=!0){const l=this.measurePageBox();let i=this.removeElementScroll(l);return s&&(i=this.removeTransform(i)),fC(i),{animationId:this.root.animationId,measuredBox:l,layoutBox:i,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:s}=this.options;if(!s)return er();const l=s.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(hC))){const{scroll:n}=this.root;n&&(Ji(l.x,n.offset.x),Ji(l.y,n.offset.y))}return l}removeElementScroll(s){const l=er();if(Vr(l,s),this.scroll?.wasRoot)return l;for(let i=0;i<this.path.length;i++){const n=this.path[i],{scroll:o,options:h}=n;n!==this.root&&o&&h.layoutScroll&&(o.wasRoot&&Vr(l,s),Ji(l.x,o.offset.x),Ji(l.y,o.offset.y))}return l}applyTransform(s,l=!1){const i=er();Vr(i,s);for(let n=0;n<this.path.length;n++){const o=this.path[n];!l&&o.options.layoutScroll&&o.scroll&&o!==o.root&&Qi(i,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),ui(o.latestValues)&&Qi(i,o.latestValues)}return ui(this.latestValues)&&Qi(i,this.latestValues),i}removeTransform(s){const l=er();Vr(l,s);for(let i=0;i<this.path.length;i++){const n=this.path[i];if(!n.instance||!ui(n.latestValues))continue;Gc(n.latestValues)&&n.updateSnapshot();const o=er(),h=n.measurePageBox();Vr(o,h),wp(l,n.latestValues,n.snapshot?n.snapshot.layoutBox:void 0,o)}return ui(this.latestValues)&&wp(l,this.latestValues),l}setTargetDelta(s){this.targetDelta=s,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(s){this.options={...this.options,...s,crossfade:s.crossfade!==void 0?s.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==fr.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(s=!1){const l=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=l.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=l.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=l.isSharedProjectionDirty);const i=!!this.resumingFrom||this!==l;if(!(s||i&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:o,layoutId:h}=this.options;if(!(!this.layout||!(o||h))){if(this.resolvedRelativeTargetAt=fr.timestamp,!this.targetDelta&&!this.relativeTarget){const u=this.getClosestProjectingParent();u&&u.layout&&this.animationProgress!==1?(this.relativeParent=u,this.forceRelativeParentToResolveTarget(),this.relativeTarget=er(),this.relativeTargetOrigin=er(),oo(this.relativeTargetOrigin,this.layout.layoutBox,u.layout.layoutBox),Vr(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}if(!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=er(),this.targetWithTransforms=er()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),pk(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):Vr(this.target,this.layout.layoutBox),D1(this.target,this.targetDelta)):Vr(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget)){this.attemptToResolveRelativeTarget=!1;const u=this.getClosestProjectingParent();u&&!!u.resumingFrom==!!this.resumingFrom&&!u.options.layoutScroll&&u.target&&this.animationProgress!==1?(this.relativeParent=u,this.forceRelativeParentToResolveTarget(),this.relativeTarget=er(),this.relativeTargetOrigin=er(),oo(this.relativeTargetOrigin,this.target,u.target),Vr(this.relativeTarget,this.relativeTargetOrigin)):this.relativeParent=this.relativeTarget=void 0}}}getClosestProjectingParent(){if(!(!this.parent||Gc(this.parent.latestValues)||N1(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}calcProjection(){const s=this.getLead(),l=!!this.resumingFrom||this!==s;let i=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(i=!1),l&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(i=!1),this.resolvedRelativeTargetAt===fr.timestamp&&(i=!1),i)return;const{layout:n,layoutId:o}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(n||o))return;Vr(this.layoutCorrected,this.layout.layoutBox);const h=this.treeScale.x,u=this.treeScale.y;mk(this.layoutCorrected,this.treeScale,this.path,l),s.layout&&!s.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(s.target=s.layout.layoutBox,s.targetWithTransforms=er());const{target:d}=s;if(!d){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(gp(this.prevProjectionDelta.x,this.projectionDelta.x),gp(this.prevProjectionDelta.y,this.projectionDelta.y)),so(this.projectionDelta,this.layoutCorrected,d,this.latestValues),(this.treeScale.x!==h||this.treeScale.y!==u||!Cp(this.projectionDelta.x,this.prevProjectionDelta.x)||!Cp(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",d))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(s=!0){if(this.options.visualElement?.scheduleRender(),s){const l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Zi(),this.projectionDelta=Zi(),this.projectionDeltaWithTransform=Zi()}setAnimationOrigin(s,l=!1){const i=this.snapshot,n=i?i.latestValues:{},o={...this.latestValues},h=Zi();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!l;const u=er(),d=i?i.source:void 0,m=this.layout?this.layout.source:void 0,b=d!==m,p=this.getStack(),v=!p||p.members.length<=1,g=!!(b&&!v&&this.options.crossfade===!0&&!this.path.some(uC));this.animationProgress=0;let x;this.mixTargetDelta=C=>{const T=C/1e3;Ap(h.x,s.x,T),Ap(h.y,s.y,T),this.setTargetDelta(h),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(oo(u,this.layout.layoutBox,this.relativeParent.layout.layoutBox),cC(this.relativeTarget,this.relativeTargetOrigin,u,T),x&&qk(this.relativeTarget,x)&&(this.isProjectionDirty=!1),x||(x=er()),Vr(x,this.relativeTarget)),b&&(this.animationValues=o,$k(o,n,this.latestValues,T,g,v)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=T},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(s){this.notifyListeners("animationStart"),this.currentAnimation?.stop(!1),this.resumingFrom?.currentAnimation?.stop(!1),this.pendingAnimation&&(ei(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Yt.update(()=>{Pa.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=hs(0)),this.currentAnimation=Ok(this.motionValue,[0,1e3],{...s,isSync:!0,onUpdate:l=>{this.mixTargetDelta(l),s.onUpdate&&s.onUpdate(l)},onStop:()=>{},onComplete:()=>{s.onComplete&&s.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const s=this.getStack();s&&s.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(Yk),this.currentAnimation.stop(!1)),this.completeAnimation()}applyTransformsToTarget(){const s=this.getLead();let{targetWithTransforms:l,target:i,layout:n,latestValues:o}=s;if(!(!l||!i||!n)){if(this!==s&&this.layout&&n&&K1(this.options.animationType,this.layout.layoutBox,n.layoutBox)){i=this.target||er();const h=Sr(this.layout.layoutBox.x);i.x.min=s.target.x.min,i.x.max=i.x.min+h;const u=Sr(this.layout.layoutBox.y);i.y.min=s.target.y.min,i.y.max=i.y.min+u}Vr(l,i),Qi(l,o),so(this.projectionDeltaWithTransform,this.layoutCorrected,l,o)}}registerSharedNode(s,l){this.sharedNodes.has(s)||this.sharedNodes.set(s,new Xk),this.sharedNodes.get(s).add(l);const n=l.options.initialPromotionConfig;l.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(l):void 0})}isLead(){const s=this.getStack();return s?s.lead===this:!0}getLead(){const{layoutId:s}=this.options;return s?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:s}=this.options;return s?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:s}=this.options;if(s)return this.root.sharedNodes.get(s)}promote({needsReset:s,transition:l,preserveFollowOpacity:i}={}){const n=this.getStack();n&&n.promote(this,i),s&&(this.projectionDelta=void 0,this.needsReset=!0),l&&this.setOptions({transition:l})}relegate(){const s=this.getStack();return s?s.relegate(this):!1}resetSkewAndRotation(){const{visualElement:s}=this.options;if(!s)return;let l=!1;const{latestValues:i}=s;if((i.z||i.rotate||i.rotateX||i.rotateY||i.rotateZ||i.skewX||i.skewY)&&(l=!0),!l)return;const n={};i.z&&ic("z",s,n,this.animationValues);for(let o=0;o<nc.length;o++)ic(`rotate${nc[o]}`,s,n,this.animationValues),ic(`skew${nc[o]}`,s,n,this.animationValues);s.render();for(const o in n)s.setStaticValue(o,n[o]),this.animationValues&&(this.animationValues[o]=n[o]);s.scheduleRender()}getProjectionStyles(s){if(!this.instance||this.isSVG)return;if(!this.isVisible)return Gk;const l={visibility:""},i=this.getTransformTemplate();if(this.needsReset)return this.needsReset=!1,l.opacity="",l.pointerEvents=ja(s?.pointerEvents)||"",l.transform=i?i(this.latestValues,""):"none",l;const n=this.getLead();if(!this.projectionDelta||!this.layout||!n.target){const d={};return this.options.layoutId&&(d.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,d.pointerEvents=ja(s?.pointerEvents)||""),this.hasProjected&&!ui(this.latestValues)&&(d.transform=i?i({},""):"none",this.hasProjected=!1),d}const o=n.animationValues||n.latestValues;this.applyTransformsToTarget(),l.transform=Kk(this.projectionDeltaWithTransform,this.treeScale,o),i&&(l.transform=i(o,l.transform));const{x:h,y:u}=this.projectionDelta;l.transformOrigin=`${h.origin*100}% ${u.origin*100}% 0`,n.animationValues?l.opacity=n===this?o.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:o.opacityExit:l.opacity=n===this?o.opacity!==void 0?o.opacity:"":o.opacityExit!==void 0?o.opacityExit:0;for(const d in _o){if(o[d]===void 0)continue;const{correct:m,applyTo:b,isCSSVariable:p}=_o[d],v=l.transform==="none"?o[d]:m(o[d],n);if(b){const g=b.length;for(let x=0;x<g;x++)l[b[x]]=v}else p?this.options.visualElement.renderState.vars[d]=v:l[d]=v}return this.options.layoutId&&(l.pointerEvents=n===this?ja(s?.pointerEvents)||"":"none"),l}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(s=>s.currentAnimation?.stop(!1)),this.root.nodes.forEach(Tp),this.root.sharedNodes.clear()}}}function Jk(t){t.updateLayout()}function Qk(t){const r=t.resumeFrom?.snapshot||t.snapshot;if(t.isLead()&&t.layout&&r&&t.hasListeners("didUpdate")){const{layoutBox:e,measuredBox:a}=t.layout,{animationType:f}=t.options,c=r.source!==t.layout.source;f==="size"?Hr(o=>{const h=c?r.measuredBox[o]:r.layoutBox[o],u=Sr(h);h.min=e[o].min,h.max=h.min+u}):K1(f,r.layoutBox,e)&&Hr(o=>{const h=c?r.measuredBox[o]:r.layoutBox[o],u=Sr(e[o]);h.max=h.min+u,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[o].max=t.relativeTarget[o].min+u)});const s=Zi();so(s,e,r.layoutBox);const l=Zi();c?so(l,t.applyTransform(a,!0),r.measuredBox):so(l,e,r.layoutBox);const i=!W1(s);let n=!1;if(!t.resumeFrom){const o=t.getClosestProjectingParent();if(o&&!o.resumeFrom){const{snapshot:h,layout:u}=o;if(h&&u){const d=er();oo(d,r.layoutBox,h.layoutBox);const m=er();oo(m,e,u.layoutBox),H1(d,m)||(n=!0),o.options.layoutRoot&&(t.relativeTarget=m,t.relativeTargetOrigin=d,t.relativeParent=o)}}}t.notifyListeners("didUpdate",{layout:e,snapshot:r,delta:l,layoutDelta:s,hasLayoutChanged:i,hasRelativeLayoutChanged:n})}else if(t.isLead()){const{onExitComplete:e}=t.options;e&&e()}t.options.transition=void 0}function eC(t){t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=!!(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}function tC(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}function rC(t){t.clearSnapshot()}function Tp(t){t.clearMeasurements()}function nC(t){t.isLayoutDirty=!1}function iC(t){const{visualElement:r}=t.options;r&&r.getProps().onBeforeLayoutMeasure&&r.notify("BeforeLayoutMeasure"),t.resetTransform()}function Ep(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}function sC(t){t.resolveTargetDelta()}function oC(t){t.calcProjection()}function aC(t){t.resetSkewAndRotation()}function lC(t){t.removeLeadSnapshot()}function Ap(t,r,e){t.translate=Gt(r.translate,0,e),t.scale=Gt(r.scale,1,e),t.origin=r.origin,t.originPoint=r.originPoint}function Mp(t,r,e,a){t.min=Gt(r.min,e.min,a),t.max=Gt(r.max,e.max,a)}function cC(t,r,e,a){Mp(t.x,r.x,e.x,a),Mp(t.y,r.y,e.y,a)}function uC(t){return t.animationValues&&t.animationValues.opacityExit!==void 0}const dC={duration:.45,ease:[.4,0,.1,1]},jp=t=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),Pp=jp("applewebkit/")&&!jp("chrome/")?Math.round:Kr;function Rp(t){t.min=Pp(t.min),t.max=Pp(t.max)}function fC(t){Rp(t.x),Rp(t.y)}function K1(t,r,e){return t==="position"||t==="preserve-aspect"&&!hk(kp(r),kp(e),.2)}function hC(t){return t!==t.root&&t.scroll?.wasRoot}const pC=X1({attachResizeListener:(t,r)=>ko(t,"resize",r),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),sc={current:void 0},G1=X1({measureScroll:t=>({x:t.scrollLeft,y:t.scrollTop}),defaultParent:()=>{if(!sc.current){const t=new pC({});t.mount(window),t.setOptions({layoutScroll:!0}),sc.current=t}return sc.current},resetTransform:(t,r)=>{t.style.transform=r!==void 0?r:"none"},checkIsScrollRoot:t=>window.getComputedStyle(t).position==="fixed"}),mC={pan:{Feature:jk},drag:{Feature:Mk,ProjectionNode:G1,MeasureLayout:z1}};function Ip(t,r,e){const{props:a}=t;t.animationState&&a.whileHover&&t.animationState.setActive("whileHover",e==="Start");const f="onHover"+e,c=a[f];c&&Yt.postRender(()=>c(r,Bo(r)))}class bC extends ni{mount(){const{current:r}=this.node;r&&(this.unmount=G7(r,(e,a)=>(Ip(this.node,a,"Start"),f=>Ip(this.node,f,"End"))))}unmount(){}}class gC extends ni{constructor(){super(...arguments),this.isActive=!1}onFocus(){let r=!1;try{r=this.node.current.matches(":focus-visible")}catch{r=!0}!r||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=No(ko(this.node.current,"focus",()=>this.onFocus()),ko(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Op(t,r,e){const{props:a}=t;if(t.current instanceof HTMLButtonElement&&t.current.disabled)return;t.animationState&&a.whileTap&&t.animationState.setActive("whileTap",e==="Start");const f="onTap"+(e==="End"?"":e),c=a[f];c&&Yt.postRender(()=>c(r,Bo(r)))}class vC extends ni{mount(){const{current:r}=this.node;r&&(this.unmount=Q7(r,(e,a)=>(Op(this.node,a,"Start"),(f,{success:c})=>Op(this.node,f,c?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Jc=new WeakMap,oc=new WeakMap,yC=t=>{const r=Jc.get(t.target);r&&r(t)},wC=t=>{t.forEach(yC)};function xC({root:t,...r}){const e=t||document;oc.has(e)||oc.set(e,{});const a=oc.get(e),f=JSON.stringify(r);return a[f]||(a[f]=new IntersectionObserver(wC,{root:t,...r})),a[f]}function _C(t,r,e){const a=xC(r);return Jc.set(t,e),a.observe(t),()=>{Jc.delete(t),a.unobserve(t)}}const SC={some:0,all:1};class kC extends ni{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:r={}}=this.node.getProps(),{root:e,margin:a,amount:f="some",once:c}=r,s={root:e?e.current:void 0,rootMargin:a,threshold:typeof f=="number"?f:SC[f]},l=i=>{const{isIntersecting:n}=i;if(this.isInView===n||(this.isInView=n,c&&!n&&this.hasEnteredView))return;n&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",n);const{onViewportEnter:o,onViewportLeave:h}=this.node.getProps(),u=n?o:h;u&&u(i)};return _C(this.node.current,s,l)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:r,prevProps:e}=this.node;["amount","margin","root"].some(CC(r,e))&&this.startObserver()}unmount(){}}function CC({viewport:t={}},{viewport:r={}}={}){return e=>t[e]!==r[e]}const TC={inView:{Feature:kC},tap:{Feature:vC},focus:{Feature:gC},hover:{Feature:bC}},EC={layout:{ProjectionNode:G1,MeasureLayout:z1}},Qc={current:null},Y1={current:!1};function AC(){if(Y1.current=!0,!!Wu)if(window.matchMedia){const t=window.matchMedia("(prefers-reduced-motion)"),r=()=>Qc.current=t.matches;t.addListener(r),r()}else Qc.current=!1}const MC=new WeakMap;function jC(t,r,e){for(const a in r){const f=r[a],c=e[a];if(vr(f))t.addValue(a,f);else if(vr(c))t.addValue(a,hs(f,{owner:t}));else if(c!==f)if(t.hasValue(a)){const s=t.getValue(a);s.liveStyle===!0?s.jump(f):s.hasAnimated||s.set(f)}else{const s=t.getStaticValue(a);t.addValue(a,hs(s!==void 0?s:f,{owner:t}))}}for(const a in e)r[a]===void 0&&t.removeValue(a);return r}const Np=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class PC{scrapeMotionValuesFromProps(r,e,a){return{}}constructor({parent:r,props:e,presenceContext:a,reducedMotionConfig:f,blockInitialAnimation:c,visualState:s},l={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=ud,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const u=Pr.now();this.renderScheduledAt<u&&(this.renderScheduledAt=u,Yt.render(this.render,!1,!0))};const{latestValues:i,renderState:n}=s;this.latestValues=i,this.baseTarget={...i},this.initialValues=e.initial?{...i}:{},this.renderState=n,this.parent=r,this.props=e,this.presenceContext=a,this.depth=r?r.depth+1:0,this.reducedMotionConfig=f,this.options=l,this.blockInitialAnimation=!!c,this.isControllingVariants=fl(e),this.isVariantNode=b1(e),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(r&&r.current);const{willChange:o,...h}=this.scrapeMotionValuesFromProps(e,{},this);for(const u in h){const d=h[u];i[u]!==void 0&&vr(d)&&d.set(i[u],!1)}}mount(r){this.current=r,MC.set(r,this),this.projection&&!this.projection.instance&&this.projection.mount(r),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((e,a)=>this.bindToMotionValue(a,e)),Y1.current||AC(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Qc.current,this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),ei(this.notifyUpdate),ei(this.render),this.valueSubscriptions.forEach(r=>r()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const r in this.events)this.events[r].clear();for(const r in this.features){const e=this.features[r];e&&(e.unmount(),e.isMounted=!1)}this.current=null}bindToMotionValue(r,e){this.valueSubscriptions.has(r)&&this.valueSubscriptions.get(r)();const a=ks.has(r);a&&this.onBindTransform&&this.onBindTransform();const f=e.on("change",l=>{this.latestValues[r]=l,this.props.onUpdate&&Yt.preRender(this.notifyUpdate),a&&this.projection&&(this.projection.isTransformDirty=!0)}),c=e.on("renderRequest",this.scheduleRender);let s;window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,r,e)),this.valueSubscriptions.set(r,()=>{f(),c(),s&&s(),e.owner&&e.stop()})}sortNodePosition(r){return!this.current||!this.sortInstanceNodePosition||this.type!==r.type?0:this.sortInstanceNodePosition(this.current,r.current)}updateFeatures(){let r="animation";for(r in ps){const e=ps[r];if(!e)continue;const{isEnabled:a,Feature:f}=e;if(!this.features[r]&&f&&a(this.props)&&(this.features[r]=new f(this)),this.features[r]){const c=this.features[r];c.isMounted?c.update():(c.mount(),c.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):er()}getStaticValue(r){return this.latestValues[r]}setStaticValue(r,e){this.latestValues[r]=e}update(r,e){(r.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=r,this.prevPresenceContext=this.presenceContext,this.presenceContext=e;for(let a=0;a<Np.length;a++){const f=Np[a];this.propEventSubscriptions[f]&&(this.propEventSubscriptions[f](),delete this.propEventSubscriptions[f]);const c="on"+f,s=r[c];s&&(this.propEventSubscriptions[f]=this.on(f,s))}this.prevMotionValues=jC(this,this.scrapeMotionValuesFromProps(r,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(r){return this.props.variants?this.props.variants[r]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(r){const e=this.getClosestVariantNode();if(e)return e.variantChildren&&e.variantChildren.add(r),()=>e.variantChildren.delete(r)}addValue(r,e){const a=this.values.get(r);e!==a&&(a&&this.removeValue(r),this.bindToMotionValue(r,e),this.values.set(r,e),this.latestValues[r]=e.get())}removeValue(r){this.values.delete(r);const e=this.valueSubscriptions.get(r);e&&(e(),this.valueSubscriptions.delete(r)),delete this.latestValues[r],this.removeValueFromRenderState(r,this.renderState)}hasValue(r){return this.values.has(r)}getValue(r,e){if(this.props.values&&this.props.values[r])return this.props.values[r];let a=this.values.get(r);return a===void 0&&e!==void 0&&(a=hs(e===null?void 0:e,{owner:this}),this.addValue(r,a)),a}readValue(r,e){let a=this.latestValues[r]!==void 0||!this.current?this.latestValues[r]:this.getBaseTargetFromProps(this.props,r)??this.readValueFromInstance(this.current,r,this.options);return a!=null&&(typeof a=="string"&&(E0(a)||A0(a))?a=parseFloat(a):!t3(a)&&ti.test(e)&&(a=c1(r,e)),this.setBaseTarget(r,vr(a)?a.get():a)),vr(a)?a.get():a}setBaseTarget(r,e){this.baseTarget[r]=e}getBaseTarget(r){const{initial:e}=this.props;let a;if(typeof e=="string"||typeof e=="object"){const c=xd(this.props,e,this.presenceContext?.custom);c&&(a=c[r])}if(e&&a!==void 0)return a;const f=this.getBaseTargetFromProps(this.props,r);return f!==void 0&&!vr(f)?f:this.initialValues[r]!==void 0&&a===void 0?void 0:this.baseTarget[r]}on(r,e){return this.events[r]||(this.events[r]=new Ju),this.events[r].add(e)}notify(r,...e){this.events[r]&&this.events[r].notify(...e)}}class Z1 extends PC{constructor(){super(...arguments),this.KeyframeResolver=W7}sortInstanceNodePosition(r,e){return r.compareDocumentPosition(e)&2?1:-1}getBaseTargetFromProps(r,e){return r.style?r.style[e]:void 0}removeValueFromRenderState(r,{vars:e,style:a}){delete e[r],delete a[r]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:r}=this.props;vr(r)&&(this.childSubscription=r.on("change",e=>{this.current&&(this.current.textContent=`${e}`)}))}}function J1(t,{style:r,vars:e},a,f){Object.assign(t.style,r,f&&f.getProjectionStyles(a));for(const c in e)t.style.setProperty(c,e[c])}function RC(t){return window.getComputedStyle(t)}class IC extends Z1{constructor(){super(...arguments),this.type="html",this.renderInstance=J1}readValueFromInstance(r,e){if(ks.has(e))return c7(r,e);{const a=RC(r),f=(td(e)?a.getPropertyValue(e):a[e])||0;return typeof f=="string"?f.trim():f}}measureInstanceViewportBox(r,{transformPagePoint:e}){return F1(r,e)}build(r,e,a){vd(r,e,a.transformTemplate)}scrapeMotionValuesFromProps(r,e,a){return _d(r,e,a)}}const Q1=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function OC(t,r,e,a){J1(t,r,void 0,a);for(const f in r.attrs)t.setAttribute(Q1.has(f)?f:gd(f),r.attrs[f])}class NC extends Z1{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=er}getBaseTargetFromProps(r,e){return r[e]}readValueFromInstance(r,e){if(ks.has(e)){const a=l1(e);return a&&a.default||0}return e=Q1.has(e)?e:gd(e),r.getAttribute(e)}scrapeMotionValuesFromProps(r,e,a){return T1(r,e,a)}build(r,e,a){_1(r,e,this.isSVGTag,a.transformTemplate,a.style)}renderInstance(r,e,a,f){OC(r,e,a,f)}mount(r){this.isSVGTag=k1(r.tagName),super.mount(r)}}const DC=(t,r)=>wd(t)?new NC(r):new IC(r,{allowProjection:t!==G.Fragment}),FC=N3({...sk,...TC,...mC,...EC},DC),on=o3(FC);function BC(t){t.values.forEach(r=>r.stop())}function eu(t,r){[...r].reverse().forEach(a=>{const f=t.getVariant(a);f&&Sd(t,f),t.variantChildren&&t.variantChildren.forEach(c=>{eu(c,r)})})}function LC(t,r){if(Array.isArray(r))return eu(t,r);if(typeof r=="string")return eu(t,[r]);Sd(t,r)}function $C(){const t=new Set,r={subscribe(e){return t.add(e),()=>void t.delete(e)},start(e,a){const f=[];return t.forEach(c=>{f.push(M1(c,e,{transitionOverride:a}))}),Promise.all(f)},set(e){return t.forEach(a=>{LC(a,e)})},stop(){t.forEach(e=>{BC(e)})},mount(){return()=>{r.stop()}}};return r}function zC(){const t=cl($C);return Hu(t.mount,[]),t}const pO=zC;var VC={initial:t=>{const{position:r}=t,e=["top","bottom"].includes(r)?"y":"x";let a=["top-right","bottom-right"].includes(r)?1:-1;return r==="bottom"&&(a=1),{opacity:0,[e]:a*24}},animate:{opacity:1,y:0,x:0,scale:1,transition:{duration:.4,ease:[.4,0,.2,1]}},exit:{opacity:0,scale:.85,transition:{duration:.2,ease:[.4,0,1,1]}}},eb=G.memo(t=>{const{id:r,message:e,onCloseComplete:a,onRequestRemove:f,requestClose:c=!1,position:s="bottom",duration:l=5e3,containerStyle:i,motionVariants:n=VC,toastSpacing:o="0.5rem"}=t,[h,u]=G.useState(l),d=sS();Ei(()=>{d||a?.()},[d]),Ei(()=>{u(l)},[l]);const m=()=>u(null),b=()=>u(l),p=()=>{d&&f()};G.useEffect(()=>{d&&c&&f()},[d,c,f]),eS(p,h);const v=G.useMemo(()=>({pointerEvents:"auto",maxWidth:560,minWidth:300,margin:o,...i}),[i,o]),g=G.useMemo(()=>J9(s),[s]);return W.jsx(on.div,{layout:!0,className:"chakra-toast",variants:n,initial:"initial",animate:"animate",exit:"exit",onHoverStart:m,onHoverEnd:b,custom:{position:s},style:g,children:W.jsx(xe.div,{role:"status","aria-atomic":"true",className:"chakra-toast__inner",__css:v,children:Xr(e,{id:r,onClose:p})})})});eb.displayName="ToastComponent";function UC(t,r){var e;const a=t??"bottom",c={"top-start":{ltr:"top-left",rtl:"top-right"},"top-end":{ltr:"top-right",rtl:"top-left"},"bottom-start":{ltr:"bottom-left",rtl:"bottom-right"},"bottom-end":{ltr:"bottom-right",rtl:"bottom-left"}}[a];return(e=c?.[r])!=null?e:a}var Dp={path:W.jsxs("g",{stroke:"currentColor",strokeWidth:"1.5",children:[W.jsx("path",{strokeLinecap:"round",fill:"none",d:"M9,9a3,3,0,1,1,4,2.829,1.5,1.5,0,0,0-1,1.415V14.25"}),W.jsx("path",{fill:"currentColor",strokeLinecap:"round",d:"M12,17.25a.375.375,0,1,0,.375.375A.375.375,0,0,0,12,17.25h0"}),W.jsx("circle",{fill:"none",strokeMiterlimit:"10",cx:"12",cy:"12",r:"11.25"})]}),viewBox:"0 0 24 24"},Tr=Se((t,r)=>{const{as:e,viewBox:a,color:f="currentColor",focusable:c=!1,children:s,className:l,__css:i,...n}=t,o=Fe("chakra-icon",l),h=$r("Icon",t),u={w:"1em",h:"1em",display:"inline-block",lineHeight:"1em",flexShrink:0,color:f,...i,...h},d={ref:r,focusable:c,className:o,__css:u},m=a??Dp.viewBox;if(e&&typeof e!="string")return W.jsx(xe.svg,{as:e,...d,...n});const b=s??Dp.path;return W.jsx(xe.svg,{verticalAlign:"middle",viewBox:m,...d,...n,children:b})});Tr.displayName="Icon";function ar(t){const{viewBox:r="0 0 24 24",d:e,displayName:a,defaultProps:f={}}=t,c=G.Children.toArray(t.path),s=Se((l,i)=>W.jsx(Tr,{ref:i,viewBox:r,...f,...l,children:c.length?c:W.jsx("path",{fill:"currentColor",d:e})}));return s.displayName=a,s}function WC(t){return W.jsx(Tr,{viewBox:"0 0 24 24",...t,children:W.jsx("path",{fill:"currentColor",d:"M12,0A12,12,0,1,0,24,12,12.014,12.014,0,0,0,12,0Zm6.927,8.2-6.845,9.289a1.011,1.011,0,0,1-1.43.188L5.764,13.769a1,1,0,1,1,1.25-1.562l4.076,3.261,6.227-8.451A1,1,0,1,1,18.927,8.2Z"})})}function HC(t){return W.jsx(Tr,{viewBox:"0 0 24 24",...t,children:W.jsx("path",{fill:"currentColor",d:"M12,0A12,12,0,1,0,24,12,12.013,12.013,0,0,0,12,0Zm.25,5a1.5,1.5,0,1,1-1.5,1.5A1.5,1.5,0,0,1,12.25,5ZM14.5,18.5h-4a1,1,0,0,1,0-2h.75a.25.25,0,0,0,.25-.25v-4.5a.25.25,0,0,0-.25-.25H10.5a1,1,0,0,1,0-2h1a2,2,0,0,1,2,2v4.75a.25.25,0,0,0,.25.25h.75a1,1,0,1,1,0,2Z"})})}function Fp(t){return W.jsx(Tr,{viewBox:"0 0 24 24",...t,children:W.jsx("path",{fill:"currentColor",d:"M11.983,0a12.206,12.206,0,0,0-8.51,3.653A11.8,11.8,0,0,0,0,12.207,11.779,11.779,0,0,0,11.8,24h.214A12.111,12.111,0,0,0,24,11.791h0A11.766,11.766,0,0,0,11.983,0ZM10.5,16.542a1.476,1.476,0,0,1,1.449-1.53h.027a1.527,1.527,0,0,1,1.523,1.47,1.475,1.475,0,0,1-1.449,1.53h-.027A1.529,1.529,0,0,1,10.5,16.542ZM11,12.5v-6a1,1,0,0,1,2,0v6a1,1,0,1,1-2,0Z"})})}var qC=Ri({"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(360deg)"}}),hl=Se((t,r)=>{const e=$r("Spinner",t),{label:a="Loading...",thickness:f="2px",speed:c="0.45s",emptyColor:s="transparent",className:l,...i}=Dt(t),n=Fe("chakra-spinner",l),o={display:"inline-block",borderColor:"currentColor",borderStyle:"solid",borderRadius:"99999px",borderWidth:f,borderBottomColor:s,borderLeftColor:s,animation:`${qC} ${c} linear infinite`,...e};return W.jsx(xe.div,{ref:r,__css:o,className:n,...i,children:a&&W.jsx(xe.span,{srOnly:!0,children:a})})});hl.displayName="Spinner";var[XC,Cd]=It({name:"AlertContext",hookName:"useAlertContext",providerName:"<Alert />"}),[KC,Td]=It({name:"AlertStylesContext",hookName:"useAlertStyles",providerName:"<Alert />"}),tb={info:{icon:HC,colorScheme:"blue"},warning:{icon:Fp,colorScheme:"orange"},success:{icon:WC,colorScheme:"green"},error:{icon:Fp,colorScheme:"red"},loading:{icon:hl,colorScheme:"blue"}};function GC(t){return tb[t].colorScheme}function YC(t){return tb[t].icon}var rb=Se(function(r,e){const a=Td(),{status:f}=Cd(),c={display:"inline",...a.description};return W.jsx(xe.div,{ref:e,"data-status":f,...r,className:Fe("chakra-alert__desc",r.className),__css:c})});rb.displayName="AlertDescription";function nb(t){const{status:r}=Cd(),e=YC(r),a=Td(),f=r==="loading"?a.spinner:a.icon;return W.jsx(xe.span,{display:"inherit","data-status":r,...t,className:Fe("chakra-alert__icon",t.className),__css:f,children:t.children||W.jsx(e,{h:"100%",w:"100%"})})}nb.displayName="AlertIcon";var ib=Se(function(r,e){const a=Td(),{status:f}=Cd();return W.jsx(xe.div,{ref:e,"data-status":f,...r,className:Fe("chakra-alert__title",r.className),__css:a.title})});ib.displayName="AlertTitle";var sb=Se(function(r,e){var a;const{status:f="info",addRole:c=!0,...s}=Dt(r),l=(a=r.colorScheme)!=null?a:GC(f),i=or("Alert",{...r,colorScheme:l}),n={width:"100%",display:"flex",alignItems:"center",position:"relative",overflow:"hidden",...i.container};return W.jsx(XC,{value:{status:f},children:W.jsx(KC,{value:i,children:W.jsx(xe.div,{"data-status":f,role:c?"alert":void 0,ref:e,...s,className:Fe("chakra-alert",r.className),__css:n})})})});sb.displayName="Alert";function ZC(t){return W.jsx(Tr,{focusable:"false","aria-hidden":!0,...t,children:W.jsx("path",{fill:"currentColor",d:"M.439,21.44a1.5,1.5,0,0,0,2.122,2.121L11.823,14.3a.25.25,0,0,1,.354,0l9.262,9.263a1.5,1.5,0,1,0,2.122-2.121L14.3,12.177a.25.25,0,0,1,0-.354l9.263-9.262A1.5,1.5,0,0,0,21.439.44L12.177,9.7a.25.25,0,0,1-.354,0L2.561.44A1.5,1.5,0,0,0,.439,2.561L9.7,11.823a.25.25,0,0,1,0,.354Z"})})}var pl=Se(function(r,e){const a=$r("CloseButton",r),{children:f,isDisabled:c,__css:s,...l}=Dt(r),i={outline:0,display:"flex",alignItems:"center",justifyContent:"center",flexShrink:0};return W.jsx(xe.button,{type:"button","aria-label":"Close",ref:e,disabled:c,__css:{...i,...a,...s},...l,children:f||W.jsx(ZC,{width:"1em",height:"1em"})})});pl.displayName="CloseButton";var JC={top:[],"top-left":[],"top-right":[],"bottom-left":[],bottom:[],"bottom-right":[]},mn=QC(JC);function QC(t){let r=t;const e=new Set,a=f=>{r=f(r),e.forEach(c=>c())};return{getState:()=>r,subscribe:f=>(e.add(f),()=>{a(()=>t),e.delete(f)}),removeToast:(f,c)=>{a(s=>({...s,[c]:s[c].filter(l=>l.id!=f)}))},notify:(f,c)=>{const s=eT(f,c),{position:l,id:i}=s;return a(n=>{var o,h;const d=l.includes("top")?[s,...(o=n[l])!=null?o:[]]:[...(h=n[l])!=null?h:[],s];return{...n,[l]:d}}),i},update:(f,c)=>{f&&a(s=>{const l={...s},{position:i,index:n}=_h(l,f);return i&&n!==-1&&(l[i][n]={...l[i][n],...c,message:ob(c)}),l})},closeAll:({positions:f}={})=>{a(c=>(f??["bottom","bottom-right","bottom-left","top","top-left","top-right"]).reduce((i,n)=>(i[n]=c[n].map(o=>({...o,requestClose:!0})),i),{...c}))},close:f=>{a(c=>{const s=T0(c,f);return s?{...c,[s]:c[s].map(l=>l.id==f?{...l,requestClose:!0}:l)}:c})},isActive:f=>!!_h(mn.getState(),f).position}}var Bp=0;function eT(t,r={}){var e,a;Bp+=1;const f=(e=r.id)!=null?e:Bp,c=(a=r.position)!=null?a:"bottom";return{id:f,message:t,position:c,duration:r.duration,onCloseComplete:r.onCloseComplete,onRequestRemove:()=>mn.removeToast(String(f),c),status:r.status,requestClose:!1,containerStyle:r.containerStyle}}var tT=t=>{const{status:r,variant:e="solid",id:a,title:f,isClosable:c,onClose:s,description:l,colorScheme:i,icon:n}=t,o=a?{root:`toast-${a}`,title:`toast-${a}-title`,description:`toast-${a}-description`}:void 0;return W.jsxs(sb,{addRole:!1,status:r,variant:e,id:o?.root,alignItems:"start",borderRadius:"md",boxShadow:"lg",paddingEnd:8,textAlign:"start",width:"auto",colorScheme:i,children:[W.jsx(nb,{children:n}),W.jsxs(xe.div,{flex:"1",maxWidth:"100%",children:[f&&W.jsx(ib,{id:o?.title,children:f}),l&&W.jsx(rb,{id:o?.description,display:"block",children:l})]}),c&&W.jsx(pl,{size:"sm",onClick:s,position:"absolute",insetEnd:1,top:1})]})};function ob(t={}){const{render:r,toastComponent:e=tT}=t;return f=>typeof r=="function"?r({...f,...t}):W.jsx(e,{...f,...t})}function rT(t,r){const e=f=>{var c;return{...r,...f,position:UC((c=f?.position)!=null?c:r?.position,t)}},a=f=>{const c=e(f),s=ob(c);return mn.notify(s,c)};return a.update=(f,c)=>{mn.update(f,e(c))},a.promise=(f,c)=>{const s=a({...c.loading,status:"loading",duration:null});f.then(l=>a.update(s,{status:"success",duration:5e3,...Xr(c.success,l)})).catch(l=>a.update(s,{status:"error",duration:5e3,...Xr(c.error,l)}))},a.closeAll=mn.closeAll,a.close=mn.close,a.isActive=mn.isActive,a}var[nT,iT]=It({name:"ToastOptionsContext",strict:!1}),sT=t=>{const r=G.useSyncExternalStore(mn.subscribe,mn.getState,mn.getState),{motionVariants:e,component:a=eb,portalProps:f}=t,s=Object.keys(r).map(l=>{const i=r[l];return W.jsx("div",{role:"region","aria-live":"polite","aria-label":`Notifications-${l}`,id:`chakra-toast-manager-${l}`,style:Q9(l),children:W.jsx(Ii,{initial:!1,children:i.map(n=>W.jsx(a,{motionVariants:e,...n},n.id))})},l)});return W.jsx(xs,{...f,children:s})};function ab(t){const{theme:r}=Ym(),e=iT();return G.useMemo(()=>rT(r.direction,{...e,...t}),[t,r.direction,e])}var oT=t=>function({children:e,theme:a=t,toastOptions:f,...c}){return W.jsxs(Y9,{theme:a,...c,children:[W.jsx(nT,{value:f?.defaultOptions,children:e}),W.jsx(sT,{...f})]})},mO=oT(w9),aT=Object.defineProperty,lT=(t,r,e)=>r in t?aT(t,r,{enumerable:!0,configurable:!0,writable:!0,value:e}):t[r]=e,Zt=(t,r,e)=>(lT(t,typeof r!="symbol"?r+"":r,e),e);function Lp(t){return t.sort((r,e)=>{const a=r.compareDocumentPosition(e);if(a&Node.DOCUMENT_POSITION_FOLLOWING||a&Node.DOCUMENT_POSITION_CONTAINED_BY)return-1;if(a&Node.DOCUMENT_POSITION_PRECEDING||a&Node.DOCUMENT_POSITION_CONTAINS)return 1;if(a&Node.DOCUMENT_POSITION_DISCONNECTED||a&Node.DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC)throw Error("Cannot sort the given nodes.");return 0})}var cT=t=>typeof t=="object"&&"nodeType"in t&&t.nodeType===Node.ELEMENT_NODE;function $p(t,r,e){let a=t+1;return e&&a>=r&&(a=0),a}function zp(t,r,e){let a=t-1;return e&&a<0&&(a=r),a}var tu=typeof window<"u"?G.useLayoutEffect:G.useEffect,Ga=t=>t,uT=class{constructor(){Zt(this,"descendants",new Map),Zt(this,"register",t=>{if(t!=null)return cT(t)?this.registerNode(t):r=>{this.registerNode(r,t)}}),Zt(this,"unregister",t=>{this.descendants.delete(t);const r=Lp(Array.from(this.descendants.keys()));this.assignIndex(r)}),Zt(this,"destroy",()=>{this.descendants.clear()}),Zt(this,"assignIndex",t=>{this.descendants.forEach(r=>{const e=t.indexOf(r.node);r.index=e,r.node.dataset.index=r.index.toString()})}),Zt(this,"count",()=>this.descendants.size),Zt(this,"enabledCount",()=>this.enabledValues().length),Zt(this,"values",()=>Array.from(this.descendants.values()).sort((r,e)=>r.index-e.index)),Zt(this,"enabledValues",()=>this.values().filter(t=>!t.disabled)),Zt(this,"item",t=>{if(this.count()!==0)return this.values()[t]}),Zt(this,"enabledItem",t=>{if(this.enabledCount()!==0)return this.enabledValues()[t]}),Zt(this,"first",()=>this.item(0)),Zt(this,"firstEnabled",()=>this.enabledItem(0)),Zt(this,"last",()=>this.item(this.descendants.size-1)),Zt(this,"lastEnabled",()=>{const t=this.enabledValues().length-1;return this.enabledItem(t)}),Zt(this,"indexOf",t=>{var r,e;return t&&(e=(r=this.descendants.get(t))==null?void 0:r.index)!=null?e:-1}),Zt(this,"enabledIndexOf",t=>t==null?-1:this.enabledValues().findIndex(r=>r.node.isSameNode(t))),Zt(this,"next",(t,r=!0)=>{const e=$p(t,this.count(),r);return this.item(e)}),Zt(this,"nextEnabled",(t,r=!0)=>{const e=this.item(t);if(!e)return;const a=this.enabledIndexOf(e.node),f=$p(a,this.enabledCount(),r);return this.enabledItem(f)}),Zt(this,"prev",(t,r=!0)=>{const e=zp(t,this.count()-1,r);return this.item(e)}),Zt(this,"prevEnabled",(t,r=!0)=>{const e=this.item(t);if(!e)return;const a=this.enabledIndexOf(e.node),f=zp(a,this.enabledCount()-1,r);return this.enabledItem(f)}),Zt(this,"registerNode",(t,r)=>{if(!t||this.descendants.has(t))return;const e=Array.from(this.descendants.keys()).concat(t),a=Lp(e);r?.disabled&&(r.disabled=!!r.disabled);const f={node:t,index:-1,...r};this.descendants.set(t,f),this.assignIndex(a)})}};function dT(t,r){if(t!=null){if(typeof t=="function"){t(r);return}try{t.current=r}catch{throw new Error(`Cannot assign value '${r}' to ref '${t}'`)}}}function Xt(...t){return r=>{t.forEach(e=>{dT(e,r)})}}function fT(...t){return G.useMemo(()=>Xt(...t),t)}function hT(){const t=G.useRef(new uT);return tu(()=>()=>t.current.destroy()),t.current}var[pT,lb]=It({name:"DescendantsProvider",errorMessage:"useDescendantsContext must be used within DescendantsProvider"});function mT(t){const r=lb(),[e,a]=G.useState(-1),f=G.useRef(null);tu(()=>()=>{f.current&&r.unregister(f.current)},[]),tu(()=>{if(!f.current)return;const s=Number(f.current.dataset.index);e!=s&&!Number.isNaN(s)&&a(s)});const c=Ga(t?r.register(t):r.register);return{descendants:r,index:e,enabledIndex:r.enabledIndexOf(f.current),register:Xt(c,f)}}function Ed(){return[Ga(pT),()=>Ga(lb()),()=>hT(),f=>mT(f)]}var[bT,ml]=It({name:"AccordionStylesContext",hookName:"useAccordionStyles",providerName:"<Accordion />"}),[gT,Ad]=It({name:"AccordionItemContext",hookName:"useAccordionItemContext",providerName:"<AccordionItem />"}),[vT,bO,yT,wT]=Ed(),Ws=Se(function(r,e){const{getButtonProps:a}=Ad(),f=a(r,e),s={display:"flex",alignItems:"center",width:"100%",outline:0,...ml().button};return W.jsx(xe.button,{...f,className:Fe("chakra-accordion__button",r.className),__css:s})});Ws.displayName="AccordionButton";function cb(t){const{value:r,defaultValue:e,onChange:a,shouldUpdate:f=(u,d)=>u!==d}=t,c=xr(a),s=xr(f),[l,i]=G.useState(e),n=r!==void 0,o=n?r:l,h=xr(u=>{const m=typeof u=="function"?u(o):u;s(o,m)&&(n||i(m),c(m))},[n,c,o,s]);return[o,h]}function xT(t){const{onChange:r,defaultIndex:e,index:a,allowMultiple:f,allowToggle:c,...s}=t;kT(t),CT(t);const l=yT(),[i,n]=G.useState(-1);G.useEffect(()=>()=>{n(-1)},[]);const[o,h]=cb({value:a,defaultValue(){return f?e??[]:e??-1},onChange:r});return{index:o,setIndex:h,htmlProps:s,getAccordionItemProps:d=>{let m=!1;return d!==null&&(m=Array.isArray(o)?o.includes(d):o===d),{isOpen:m,onChange:p=>{if(d!==null)if(f&&Array.isArray(o)){const v=p?o.concat(d):o.filter(g=>g!==d);h(v)}else p?h(d):c&&h(-1)}}},focusedIndex:i,setFocusedIndex:n,descendants:l}}var[_T,Md]=It({name:"AccordionContext",hookName:"useAccordionContext",providerName:"Accordion"});function ST(t){const{isDisabled:r,isFocusable:e,id:a,...f}=t,{getAccordionItemProps:c,setFocusedIndex:s}=Md(),l=G.useRef(null),i=G.useId(),n=a??i,o=`accordion-button-${n}`,h=`accordion-panel-${n}`;TT(t);const{register:u,index:d,descendants:m}=wT({disabled:r&&!e}),{isOpen:b,onChange:p}=c(d===-1?null:d);ET({isOpen:b,isDisabled:r});const v=()=>{p?.(!0)},g=()=>{p?.(!1)},x=G.useCallback(()=>{p?.(!b),s(d)},[d,s,b,p]),C=G.useCallback(I=>{const L={ArrowDown:()=>{const V=m.nextEnabled(d);V?.node.focus()},ArrowUp:()=>{const V=m.prevEnabled(d);V?.node.focus()},Home:()=>{const V=m.firstEnabled();V?.node.focus()},End:()=>{const V=m.lastEnabled();V?.node.focus()}}[I.key];L&&(I.preventDefault(),L(I))},[m,d]),T=G.useCallback(()=>{s(d)},[s,d]),R=G.useCallback(function(F={},L=null){return{...F,type:"button",ref:Xt(u,l,L),id:o,disabled:!!r,"aria-expanded":!!b,"aria-controls":h,onClick:Qe(F.onClick,x),onFocus:Qe(F.onFocus,T),onKeyDown:Qe(F.onKeyDown,C)}},[o,r,b,x,T,C,h,u]),B=G.useCallback(function(F={},L=null){return{...F,ref:L,role:"region",id:h,"aria-labelledby":o,hidden:!b}},[o,b,h]);return{isOpen:b,isDisabled:r,isFocusable:e,onOpen:v,onClose:g,getButtonProps:R,getPanelProps:B,htmlProps:f}}function kT(t){const r=t.index||t.defaultIndex,e=r!=null&&!Array.isArray(r)&&t.allowMultiple;Ro({condition:!!e,message:`If 'allowMultiple' is passed, then 'index' or 'defaultIndex' must be an array. You passed: ${typeof r},`})}function CT(t){Ro({condition:!!(t.allowMultiple&&t.allowToggle),message:"If 'allowMultiple' is passed, 'allowToggle' will be ignored. Either remove 'allowToggle' or 'allowMultiple' depending on whether you want multiple accordions visible or not"})}function TT(t){Ro({condition:!!(t.isFocusable&&!t.isDisabled),message:`Using only 'isFocusable', this prop is reserved for situations where you pass 'isDisabled' but you still want the element to receive focus (A11y). Either remove it or pass 'isDisabled' as well. `})}function ET(t){Ro({condition:t.isOpen&&!!t.isDisabled,message:"Cannot open a disabled accordion item"})}function Hs(t){const{isOpen:r,isDisabled:e}=Ad(),{reduceMotion:a}=Md(),f=Fe("chakra-accordion__icon",t.className),c=ml(),s={opacity:e?.4:1,transform:r?"rotate(-180deg)":void 0,transition:a?void 0:"transform 0.2s",transformOrigin:"center",...c.icon};return W.jsx(Tr,{viewBox:"0 0 24 24","aria-hidden":!0,className:f,__css:s,...t,children:W.jsx("path",{fill:"currentColor",d:"M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"})})}Hs.displayName="AccordionIcon";var qs=Se(function(r,e){const{children:a,className:f}=r,{htmlProps:c,...s}=ST(r),i={...ml().container,overflowAnchor:"none"},n=G.useMemo(()=>s,[s]);return W.jsx(gT,{value:n,children:W.jsx(xe.div,{ref:e,...c,className:Fe("chakra-accordion__item",f),__css:i,children:typeof a=="function"?a({isExpanded:!!s.isOpen,isDisabled:!!s.isDisabled}):a})})});qs.displayName="AccordionItem";var es={ease:[.25,.1,.25,1],easeIn:[.4,0,1,1],easeOut:[0,0,.2,1]},_i={enter:{duration:.2,ease:es.easeOut},exit:{duration:.1,ease:es.easeIn}},Dn={enter:(t,r)=>({...t,delay:typeof r=="number"?r:r?.enter}),exit:(t,r)=>({...t,delay:typeof r=="number"?r:r?.exit})},AT=t=>t!=null&&parseInt(t.toString(),10)>0,Vp={exit:{height:{duration:.2,ease:es.ease},opacity:{duration:.3,ease:es.ease}},enter:{height:{duration:.3,ease:es.ease},opacity:{duration:.4,ease:es.ease}}},MT={exit:({animateOpacity:t,startingHeight:r,transition:e,transitionEnd:a,delay:f})=>{var c;return{...t&&{opacity:AT(r)?1:0},height:r,transitionEnd:a?.exit,transition:(c=e?.exit)!=null?c:Dn.exit(Vp.exit,f)}},enter:({animateOpacity:t,endingHeight:r,transition:e,transitionEnd:a,delay:f})=>{var c;return{...t&&{opacity:1},height:r,transitionEnd:a?.enter,transition:(c=e?.enter)!=null?c:Dn.enter(Vp.enter,f)}}},ub=G.forwardRef((t,r)=>{const{in:e,unmountOnExit:a,animateOpacity:f=!0,startingHeight:c=0,endingHeight:s="auto",style:l,className:i,transition:n,transitionEnd:o,...h}=t,[u,d]=G.useState(!1);G.useEffect(()=>{const g=setTimeout(()=>{d(!0)});return()=>clearTimeout(g)},[]),Ro({condition:Number(c)>0&&!!a,message:"startingHeight and unmountOnExit are mutually exclusive. You can't use them together"});const m=parseFloat(c.toString())>0,b={startingHeight:c,endingHeight:s,animateOpacity:f,transition:u?n:{enter:{duration:0}},transitionEnd:{enter:o?.enter,exit:a?o?.exit:{...o?.exit,display:m?"block":"none"}}},p=a?e:!0,v=e||a?"enter":"exit";return W.jsx(Ii,{initial:!1,custom:b,children:p&&W.jsx(on.div,{ref:r,...h,className:Fe("chakra-collapse",i),style:{overflow:"hidden",display:"block",...l},custom:b,variants:MT,initial:a?"exit":!1,animate:v,exit:"exit"})})});ub.displayName="Collapse";var jT={enter:({transition:t,transitionEnd:r,delay:e}={})=>{var a;return{opacity:1,transition:(a=t?.enter)!=null?a:Dn.enter(_i.enter,e),transitionEnd:r?.enter}},exit:({transition:t,transitionEnd:r,delay:e}={})=>{var a;return{opacity:0,transition:(a=t?.exit)!=null?a:Dn.exit(_i.exit,e),transitionEnd:r?.exit}}},db={initial:"exit",animate:"enter",exit:"exit",variants:jT},PT=G.forwardRef(function(r,e){const{unmountOnExit:a,in:f,className:c,transition:s,transitionEnd:l,delay:i,...n}=r,o=f||a?"enter":"exit",h=a?f&&a:!0,u={transition:s,transitionEnd:l,delay:i};return W.jsx(Ii,{custom:u,children:h&&W.jsx(on.div,{ref:e,className:Fe("chakra-fade",c),custom:u,...db,animate:o,...n})})});PT.displayName="Fade";var RT={exit:({reverse:t,initialScale:r,transition:e,transitionEnd:a,delay:f})=>{var c;return{opacity:0,...t?{scale:r,transitionEnd:a?.exit}:{transitionEnd:{scale:r,...a?.exit}},transition:(c=e?.exit)!=null?c:Dn.exit(_i.exit,f)}},enter:({transitionEnd:t,transition:r,delay:e})=>{var a;return{opacity:1,scale:1,transition:(a=r?.enter)!=null?a:Dn.enter(_i.enter,e),transitionEnd:t?.enter}}},fb={initial:"exit",animate:"enter",exit:"exit",variants:RT},IT=G.forwardRef(function(r,e){const{unmountOnExit:a,in:f,reverse:c=!0,initialScale:s=.95,className:l,transition:i,transitionEnd:n,delay:o,...h}=r,u=a?f&&a:!0,d=f||a?"enter":"exit",m={initialScale:s,reverse:c,transition:i,transitionEnd:n,delay:o};return W.jsx(Ii,{custom:m,children:u&&W.jsx(on.div,{ref:e,className:Fe("chakra-offset-slide",l),...fb,animate:d,custom:m,...h})})});IT.displayName="ScaleFade";var OT={initial:({offsetX:t,offsetY:r,transition:e,transitionEnd:a,delay:f})=>{var c;return{opacity:0,x:t,y:r,transition:(c=e?.exit)!=null?c:Dn.exit(_i.exit,f),transitionEnd:a?.exit}},enter:({transition:t,transitionEnd:r,delay:e})=>{var a;return{opacity:1,x:0,y:0,transition:(a=t?.enter)!=null?a:Dn.enter(_i.enter,e),transitionEnd:r?.enter}},exit:({offsetY:t,offsetX:r,transition:e,transitionEnd:a,reverse:f,delay:c})=>{var s;const l={x:r,y:t};return{opacity:0,transition:(s=e?.exit)!=null?s:Dn.exit(_i.exit,c),...f?{...l,transitionEnd:a?.exit}:{transitionEnd:{...l,...a?.exit}}}}},Xs={initial:"initial",animate:"enter",exit:"exit",variants:OT},NT=G.forwardRef(function(r,e){const{unmountOnExit:a,in:f,reverse:c=!0,className:s,offsetX:l=0,offsetY:i=8,transition:n,transitionEnd:o,delay:h,...u}=r,d=a?f&&a:!0,m=f||a?"enter":"exit",b={offsetX:l,offsetY:i,reverse:c,transition:n,transitionEnd:o,delay:h};return W.jsx(Ii,{custom:b,children:d&&W.jsx(on.div,{ref:e,className:Fe("chakra-offset-slide",s),custom:b,...Xs,animate:m,...u})})});NT.displayName="SlideFade";var Ks=Se(function(r,e){const{className:a,motionProps:f,...c}=r,{reduceMotion:s}=Md(),{getPanelProps:l,isOpen:i}=Ad(),n=l(c,e),o=Fe("chakra-accordion__panel",a),h=ml();s||delete n.hidden;const u=W.jsx(xe.div,{...n,__css:h.panel,className:o});return s?u:W.jsx(ub,{in:i,...f,children:u})});Ks.displayName="AccordionPanel";var Gs=Se(function({children:r,reduceMotion:e,...a},f){const c=or("Accordion",a),s=Dt(a),{htmlProps:l,descendants:i,...n}=xT(s),o=G.useMemo(()=>({...n,reduceMotion:!!e}),[n,e]);return W.jsx(vT,{value:i,children:W.jsx(_T,{value:o,children:W.jsx(bT,{value:c,children:W.jsx(xe.div,{ref:f,...l,className:Fe("chakra-accordion",a.className),__css:c.root,children:r})})})})});Gs.displayName="Accordion";var[DT,hb]=It({name:"AvatarStylesContext",hookName:"useAvatarStyles",providerName:"<Avatar/>"}),FT={"top-start":{top:"0",insetStart:"0",transform:"translate(-25%, -25%)"},"top-end":{top:"0",insetEnd:"0",transform:"translate(25%, -25%)"},"bottom-start":{bottom:"0",insetStart:"0",transform:"translate(-25%, 25%)"},"bottom-end":{bottom:"0",insetEnd:"0",transform:"translate(25%, 25%)"}},BT=Se(function(r,e){const{placement:a="bottom-end",className:f,...c}=r,s=hb(),i={position:"absolute",display:"flex",alignItems:"center",justifyContent:"center",...FT[a],...s.badge};return W.jsx(xe.div,{ref:e,...c,className:Fe("chakra-avatar__badge",f),__css:i})});BT.displayName="AvatarBadge";function LT(t){var r;const e=t.split(" "),a=(r=e[0])!=null?r:"",f=e.length>1?e[e.length-1]:"";return a&&f?`${a.charAt(0)}${f.charAt(0)}`:a.charAt(0)}function pb(t){const{name:r,getInitials:e,...a}=t,f=hb();return W.jsx(xe.div,{role:"img","aria-label":r,...a,__css:f.label,children:r?e?.(r):null})}pb.displayName="AvatarName";var mb=t=>W.jsxs(xe.svg,{viewBox:"0 0 128 128",color:"#fff",width:"100%",height:"100%",className:"chakra-avatar__svg",...t,children:[W.jsx("path",{fill:"currentColor",d:"M103,102.1388 C93.094,111.92 79.3504,118 64.1638,118 C48.8056,118 34.9294,111.768 25,101.7892 L25,95.2 C25,86.8096 31.981,80 40.6,80 L87.4,80 C96.019,80 103,86.8096 103,95.2 L103,102.1388 Z"}),W.jsx("path",{fill:"currentColor",d:"M63.9961647,24 C51.2938136,24 41,34.2938136 41,46.9961647 C41,59.7061864 51.2938136,70 63.9961647,70 C76.6985159,70 87,59.7061864 87,46.9961647 C87,34.2938136 76.6985159,24 63.9961647,24"})]}),ru=Se(function(r,e){const{htmlWidth:a,htmlHeight:f,alt:c,...s}=r;return W.jsx("img",{width:a,height:f,ref:e,alt:c,...s})});ru.displayName="NativeImage";function bb(t){const{loading:r,src:e,srcSet:a,onLoad:f,onError:c,crossOrigin:s,sizes:l,ignoreFallback:i}=t,[n,o]=G.useState("pending");G.useEffect(()=>{o(e?"loading":"pending")},[e]);const h=G.useRef(),u=G.useCallback(()=>{if(!e)return;d();const m=new Image;m.src=e,s&&(m.crossOrigin=s),a&&(m.srcset=a),l&&(m.sizes=l),r&&(m.loading=r),m.onload=b=>{d(),o("loaded"),f?.(b)},m.onerror=b=>{d(),o("failed"),c?.(b)},h.current=m},[e,s,a,l,f,c,r]),d=()=>{h.current&&(h.current.onload=null,h.current.onerror=null,h.current=null)};return Qn(()=>{if(!i)return n==="loading"&&u(),()=>{d()}},[n,u,i]),i?"loaded":n}var $T=(t,r)=>t!=="loaded"&&r==="beforeLoadOrError"||t==="failed"&&r==="onError";function zT(t,r=[]){const e=Object.assign({},t);for(const a of r)a in e&&delete e[a];return e}var VT=Se(function(r,e){const{fallbackSrc:a,fallback:f,src:c,srcSet:s,align:l,fit:i,loading:n,ignoreFallback:o,crossOrigin:h,fallbackStrategy:u="beforeLoadOrError",referrerPolicy:d,...m}=r,b=a!==void 0||f!==void 0,p=n!=null||o||!b,v=bb({...r,crossOrigin:h,ignoreFallback:p}),g=$T(v,u),x={ref:e,objectFit:i,objectPosition:l,...p?m:zT(m,["onError","onLoad"])};return g?f||W.jsx(xe.img,{as:ru,className:"chakra-image__placeholder",src:a,...x}):W.jsx(xe.img,{as:ru,src:c,srcSet:s,crossOrigin:h,loading:n,referrerPolicy:d,className:"chakra-image",...x})});VT.displayName="Image";function gb(t){const{src:r,srcSet:e,onError:a,onLoad:f,getInitials:c,name:s,borderRadius:l,loading:i,iconLabel:n,icon:o=W.jsx(mb,{}),ignoreFallback:h,referrerPolicy:u,crossOrigin:d}=t,b=bb({src:r,onError:a,crossOrigin:d,ignoreFallback:h})==="loaded";return!r||!b?s?W.jsx(pb,{className:"chakra-avatar__initials",getInitials:c,name:s}):G.cloneElement(o,{role:"img","aria-label":n}):W.jsx(xe.img,{src:r,srcSet:e,alt:s,onLoad:f,referrerPolicy:u,crossOrigin:d??void 0,className:"chakra-avatar__img",loading:i,__css:{width:"100%",height:"100%",objectFit:"cover",borderRadius:l}})}gb.displayName="AvatarImage";var UT={display:"inline-flex",alignItems:"center",justifyContent:"center",textAlign:"center",textTransform:"uppercase",fontWeight:"medium",position:"relative",flexShrink:0},WT=Se((t,r)=>{const e=or("Avatar",t),[a,f]=G.useState(!1),{src:c,srcSet:s,name:l,showBorder:i,borderRadius:n="full",onError:o,onLoad:h,getInitials:u=LT,icon:d=W.jsx(mb,{}),iconLabel:m=" avatar",loading:b,children:p,borderColor:v,ignoreFallback:g,crossOrigin:x,referrerPolicy:C,...T}=Dt(t),R={borderRadius:n,borderWidth:i?"2px":void 0,...UT,...e.container};return v&&(R.borderColor=v),W.jsx(xe.span,{ref:r,...T,className:Fe("chakra-avatar",t.className),"data-loaded":Bt(a),__css:R,children:W.jsxs(DT,{value:e,children:[W.jsx(gb,{src:c,srcSet:s,loading:b,onLoad:Qe(h,()=>{f(!0)}),onError:o,getInitials:u,name:l,borderRadius:n,icon:d,iconLabel:m,ignoreFallback:g,crossOrigin:x,referrerPolicy:C}),p]})})});WT.displayName="Avatar";function bl(t){return G.Children.toArray(t).filter(r=>G.isValidElement(r))}var[gO,HT]=It({strict:!1,name:"ButtonGroupContext"});function qT(t){const[r,e]=G.useState(!t);return{ref:G.useCallback(c=>{c&&e(c.tagName==="BUTTON")},[]),type:r?"button":void 0}}function nu(t){const{children:r,className:e,...a}=t,f=G.isValidElement(r)?G.cloneElement(r,{"aria-hidden":!0,focusable:!1}):r,c=Fe("chakra-button__icon",e);return W.jsx(xe.span,{display:"inline-flex",alignSelf:"center",flexShrink:0,...a,className:c,children:f})}nu.displayName="ButtonIcon";function iu(t){const{label:r,placement:e,spacing:a="0.5rem",children:f=W.jsx(hl,{color:"currentColor",width:"1em",height:"1em"}),className:c,__css:s,...l}=t,i=Fe("chakra-button__spinner",c),n=e==="start"?"marginEnd":"marginStart",o=G.useMemo(()=>({display:"flex",alignItems:"center",position:r?"relative":"absolute",[n]:r?a:0,fontSize:"1em",lineHeight:"normal",...s}),[s,r,n,a]);return W.jsx(xe.div,{className:i,...l,__css:o,children:f})}iu.displayName="ButtonSpinner";var wr=Se((t,r)=>{const e=HT(),a=$r("Button",{...e,...t}),{isDisabled:f=e?.isDisabled,isLoading:c,isActive:s,children:l,leftIcon:i,rightIcon:n,loadingText:o,iconSpacing:h="0.5rem",type:u,spinner:d,spinnerPlacement:m="start",className:b,as:p,...v}=Dt(t),g=G.useMemo(()=>{const R={...a?._focus,zIndex:1};return{display:"inline-flex",appearance:"none",alignItems:"center",justifyContent:"center",userSelect:"none",position:"relative",whiteSpace:"nowrap",verticalAlign:"middle",outline:"none",...a,...!!e&&{_focus:R}}},[a,e]),{ref:x,type:C}=qT(p),T={rightIcon:n,leftIcon:i,iconSpacing:h,children:l};return W.jsxs(xe.button,{ref:fT(r,x),as:p,type:u??C,"data-active":Bt(s),"data-loading":Bt(c),__css:g,className:Fe("chakra-button",b),...v,disabled:f||c,children:[c&&m==="start"&&W.jsx(iu,{className:"chakra-button__spinner--start",label:o,placement:"start",spacing:h,children:d}),c?o||W.jsx(xe.span,{opacity:0,children:W.jsx(Up,{...T})}):W.jsx(Up,{...T}),c&&m==="end"&&W.jsx(iu,{className:"chakra-button__spinner--end",label:o,placement:"end",spacing:h,children:d})]})});wr.displayName="Button";function Up(t){const{leftIcon:r,rightIcon:e,children:a,iconSpacing:f}=t;return W.jsxs(W.Fragment,{children:[r&&W.jsx(nu,{marginEnd:f,children:r}),a,e&&W.jsx(nu,{marginStart:f,children:e})]})}var XT=Se((t,r)=>{const{icon:e,children:a,isRound:f,"aria-label":c,...s}=t,l=e||a,i=G.isValidElement(l)?G.cloneElement(l,{"aria-hidden":!0,focusable:!1}):null;return W.jsx(wr,{padding:"0",borderRadius:f?"full":void 0,ref:r,"aria-label":c,...s,children:i})});XT.displayName="IconButton";var[KT,vb]=X9("Card"),vO=Se(function(r,e){const{className:a,...f}=r,c=vb();return W.jsx(xe.div,{ref:e,className:Fe("chakra-card__body",a),__css:c.body,...f})}),yO=Se(function(r,e){const{className:a,...f}=r,c=vb();return W.jsx(xe.div,{ref:e,className:Fe("chakra-card__header",a),__css:c.header,...f})}),wO=Se(function(r,e){const{className:a,children:f,direction:c="column",justify:s,align:l,...i}=Dt(r),n=or("Card",r);return W.jsx(xe.div,{ref:e,className:Fe("chakra-card",a),__css:{display:"flex",flexDirection:c,justifyContent:s,alignItems:l,position:"relative",minWidth:0,wordWrap:"break-word",...n.container},...i,children:W.jsx(KT,{value:n,children:f})})}),[GT,yb]=It({name:"FormControlStylesContext",errorMessage:`useFormControlStyles returned is 'undefined'. Seems you forgot to wrap the components in "<FormControl />" `}),[YT,Lo]=It({strict:!1,name:"FormControlContext"});function ZT(t){const{id:r,isRequired:e,isInvalid:a,isDisabled:f,isReadOnly:c,...s}=t,l=G.useId(),i=r||`field-${l}`,n=`${i}-label`,o=`${i}-feedback`,h=`${i}-helptext`,[u,d]=G.useState(!1),[m,b]=G.useState(!1),[p,v]=G.useState(!1),g=G.useCallback((B={},I=null)=>({id:h,...B,ref:Xt(I,F=>{F&&b(!0)})}),[h]),x=G.useCallback((B={},I=null)=>({...B,ref:I,"data-focus":Bt(p),"data-disabled":Bt(f),"data-invalid":Bt(a),"data-readonly":Bt(c),id:B.id!==void 0?B.id:n,htmlFor:B.htmlFor!==void 0?B.htmlFor:i}),[i,f,p,a,c,n]),C=G.useCallback((B={},I=null)=>({id:o,...B,ref:Xt(I,F=>{F&&d(!0)}),"aria-live":"polite"}),[o]),T=G.useCallback((B={},I=null)=>({...B,...s,ref:I,role:"group","data-focus":Bt(p),"data-disabled":Bt(f),"data-invalid":Bt(a),"data-readonly":Bt(c)}),[s,f,p,a,c]),R=G.useCallback((B={},I=null)=>({...B,ref:I,role:"presentation","aria-hidden":!0,children:B.children||"*"}),[]);return{isRequired:!!e,isInvalid:!!a,isReadOnly:!!c,isDisabled:!!f,isFocused:!!p,onFocus:()=>v(!0),onBlur:()=>v(!1),hasFeedbackText:u,setHasFeedbackText:d,hasHelpText:m,setHasHelpText:b,id:i,labelId:n,feedbackId:o,helpTextId:h,htmlProps:s,getHelpTextProps:g,getErrorMessageProps:C,getRootProps:T,getLabelProps:x,getRequiredIndicatorProps:R}}var JT=Se(function(r,e){const a=or("Form",r),f=Dt(r),{getRootProps:c,htmlProps:s,...l}=ZT(f),i=Fe("chakra-form-control",r.className);return W.jsx(YT,{value:l,children:W.jsx(GT,{value:a,children:W.jsx(xe.div,{...c({},e),className:i,__css:a.container})})})});JT.displayName="FormControl";var QT=Se(function(r,e){const a=Lo(),f=yb(),c=Fe("chakra-form__helper-text",r.className);return W.jsx(xe.div,{...a?.getHelpTextProps(r,e),__css:f.helperText,className:c})});QT.displayName="FormHelperText";var eE=Se(function(r,e){var a;const f=$r("FormLabel",r),c=Dt(r),{className:s,children:l,requiredIndicator:i=W.jsx(wb,{}),optionalIndicator:n=null,...o}=c,h=Lo(),u=(a=h?.getLabelProps(o,e))!=null?a:{ref:e,...o};return W.jsxs(xe.label,{...u,className:Fe("chakra-form__label",c.className),__css:{display:"block",textAlign:"start",...f},children:[l,h?.isRequired?i:n]})});eE.displayName="FormLabel";var wb=Se(function(r,e){const a=Lo(),f=yb();if(!a?.isRequired)return null;const c=Fe("chakra-form__required-indicator",r.className);return W.jsx(xe.span,{...a?.getRequiredIndicatorProps(r,e),__css:f.requiredIndicator,className:c})});wb.displayName="RequiredIndicator";function jd(t){const{isDisabled:r,isInvalid:e,isReadOnly:a,isRequired:f,...c}=xb(t);return{...c,disabled:r,readOnly:a,required:f,"aria-invalid":On(e),"aria-required":On(f),"aria-readonly":On(a)}}function xb(t){var r,e,a;const f=Lo(),{id:c,disabled:s,readOnly:l,required:i,isRequired:n,isInvalid:o,isReadOnly:h,isDisabled:u,onFocus:d,onBlur:m,...b}=t,p=t["aria-describedby"]?[t["aria-describedby"]]:[];return f?.hasFeedbackText&&f?.isInvalid&&p.push(f.feedbackId),f?.hasHelpText&&p.push(f.helpTextId),{...b,"aria-describedby":p.join(" ")||void 0,id:c??f?.id,isDisabled:(r=s??u)!=null?r:f?.isDisabled,isReadOnly:(e=l??h)!=null?e:f?.isReadOnly,isRequired:(a=i??n)!=null?a:f?.isRequired,isInvalid:o??f?.isInvalid,onFocus:Qe(f?.onFocus,d),onBlur:Qe(f?.onBlur,m)}}var tE=()=>typeof document<"u",Wp=!1,$o=null,Ai=!1,su=!1,ou=new Set;function Pd(t,r){ou.forEach(e=>e(t,r))}var rE=typeof window<"u"&&window.navigator!=null?/^Mac/.test(window.navigator.platform):!1;function nE(t){return!(t.metaKey||!rE&&t.altKey||t.ctrlKey||t.key==="Control"||t.key==="Shift"||t.key==="Meta")}function Hp(t){Ai=!0,nE(t)&&($o="keyboard",Pd("keyboard",t))}function Fi(t){if($o="pointer",t.type==="mousedown"||t.type==="pointerdown"){Ai=!0;const r=t.composedPath?t.composedPath()[0]:t.target;let e=!1;try{e=r.matches(":focus-visible")}catch{}if(e)return;Pd("pointer",t)}}function iE(t){return t.mozInputSource===0&&t.isTrusted?!0:t.detail===0&&!t.pointerType}function sE(t){iE(t)&&(Ai=!0,$o="virtual")}function oE(t){t.target===window||t.target===document||(!Ai&&!su&&($o="virtual",Pd("virtual",t)),Ai=!1,su=!1)}function aE(){Ai=!1,su=!0}function qp(){return $o!=="pointer"}function lE(){if(!tE()||Wp)return;const{focus:t}=HTMLElement.prototype;HTMLElement.prototype.focus=function(...e){Ai=!0,t.apply(this,e)},document.addEventListener("keydown",Hp,!0),document.addEventListener("keyup",Hp,!0),document.addEventListener("click",sE,!0),window.addEventListener("focus",oE,!0),window.addEventListener("blur",aE,!1),typeof PointerEvent<"u"?(document.addEventListener("pointerdown",Fi,!0),document.addEventListener("pointermove",Fi,!0),document.addEventListener("pointerup",Fi,!0)):(document.addEventListener("mousedown",Fi,!0),document.addEventListener("mousemove",Fi,!0),document.addEventListener("mouseup",Fi,!0)),Wp=!0}function cE(t){lE(),t(qp());const r=()=>t(qp());return ou.add(r),()=>{ou.delete(r)}}function uE(t){const r=parseFloat(t);return typeof r!="number"||Number.isNaN(r)?0:r}function _b(t,r){let e=uE(t);const a=10**(r??10);return e=Math.round(e*a)/a,r?e.toFixed(r):e.toString()}function Xp(t){if(!Number.isFinite(t))return 0;let r=1,e=0;for(;Math.round(t*r)/r!==t;)r*=10,e+=1;return e}function dE(t,r,e){return t==null?t:(e<r&&console.warn("clamp: max cannot be less than min"),Math.min(Math.max(t,r),e))}function fE(t={}){const{onChange:r,precision:e,defaultValue:a,value:f,step:c=1,min:s=Number.MIN_SAFE_INTEGER,max:l=Number.MAX_SAFE_INTEGER,keepWithinRange:i=!0}=t,n=xr(r),[o,h]=G.useState(()=>{var L;return a==null?"":(L=ac(a,c,e))!=null?L:""}),u=typeof f<"u",d=u?f:o,m=Sb(Zn(d),c),b=e??m,p=G.useCallback(L=>{L!==d&&(u||h(L.toString()),n?.(L.toString(),Zn(L)))},[n,u,d]),v=G.useCallback(L=>{let V=L;return i&&(V=dE(V,s,l)),_b(V,b)},[b,i,l,s]),g=G.useCallback((L=c)=>{let V;d===""?V=Zn(L):V=Zn(d)+L,V=v(V),p(V)},[v,c,p,d]),x=G.useCallback((L=c)=>{let V;d===""?V=Zn(-L):V=Zn(d)-L,V=v(V),p(V)},[v,c,p,d]),C=G.useCallback(()=>{var L;let V;a==null?V="":V=(L=ac(a,c,e))!=null?L:s,p(V)},[a,e,c,p,s]),T=G.useCallback(L=>{var V;const z=(V=ac(L,c,b))!=null?V:s;p(z)},[b,c,p,s]),R=Zn(d);return{isOutOfRange:R>l||R<s,isAtMax:R===l,isAtMin:R===s,precision:b,value:d,valueAsNumber:R,update:p,reset:C,increment:g,decrement:x,clamp:v,cast:T,setValue:h}}function Zn(t){return parseFloat(t.toString().replace(/[^\w.-]+/g,""))}function Sb(t,r){return Math.max(Xp(r),Xp(t))}function ac(t,r,e){const a=Zn(t);if(Number.isNaN(a))return;const f=Sb(a,r);return _b(a,e??f)}function Si(t,r,e,a){const f=xr(e);return G.useEffect(()=>{const c=typeof t=="function"?t():t??document;if(!(!e||!c))return c.addEventListener(r,f,a),()=>{c.removeEventListener(r,f,a)}},[r,t,a,f,e]),()=>{const c=typeof t=="function"?t():t??document;c?.removeEventListener(r,f,a)}}function hE(t){return"current"in t}var kb=()=>typeof window<"u";function pE(){var t;const r=navigator.userAgentData;return(t=r?.platform)!=null?t:navigator.platform}var mE=t=>kb()&&t.test(navigator.vendor),bE=t=>kb()&&t.test(pE()),gE=()=>bE(/mac|iphone|ipad|ipod/i),vE=()=>gE()&&mE(/apple/i);function yE(t){const{ref:r,elements:e,enabled:a}=t,f=()=>{var c,s;return(s=(c=r.current)==null?void 0:c.ownerDocument)!=null?s:document};Si(f,"pointerdown",c=>{if(!vE()||!a)return;const s=c.target,i=(e??[r]).some(n=>{const o=hE(n)?n.current:n;return o?.contains(s)||o===s});f().activeElement!==s&&i&&(c.preventDefault(),s.focus())})}function wE(t,r){if(t==null)return{};var e={};for(var a in t)if({}.hasOwnProperty.call(t,a)){if(r.indexOf(a)!==-1)continue;e[a]=t[a]}return e}var au="data-focus-lock",Cb="data-focus-lock-disabled",xE="data-no-focus-lock",_E="data-autofocus-inside",SE="data-no-autofocus";function lc(t,r){return typeof t=="function"?t(r):t&&(t.current=r),t}function kE(t,r){var e=G.useState(function(){return{value:t,callback:r,facade:{get current(){return e.value},set current(a){var f=e.value;f!==a&&(e.value=a,e.callback(a,f))}}}})[0];return e.callback=r,e.facade}var CE=typeof window<"u"?G.useLayoutEffect:G.useEffect,Kp=new WeakMap;function Tb(t,r){var e=kE(null,function(a){return t.forEach(function(f){return lc(f,a)})});return CE(function(){var a=Kp.get(e);if(a){var f=new Set(a),c=new Set(t),s=e.current;f.forEach(function(l){c.has(l)||lc(l,null)}),c.forEach(function(l){f.has(l)||lc(l,s)})}Kp.set(e,t)},[t]),e}var cc={width:"1px",height:"0px",padding:0,overflow:"hidden",position:"fixed",top:"1px",left:"1px"},bn=function(){return bn=Object.assign||function(r){for(var e,a=1,f=arguments.length;a<f;a++){e=arguments[a];for(var c in e)Object.prototype.hasOwnProperty.call(e,c)&&(r[c]=e[c])}return r},bn.apply(this,arguments)};function Eb(t,r){var e={};for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&r.indexOf(a)<0&&(e[a]=t[a]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var f=0,a=Object.getOwnPropertySymbols(t);f<a.length;f++)r.indexOf(a[f])<0&&Object.prototype.propertyIsEnumerable.call(t,a[f])&&(e[a[f]]=t[a[f]]);return e}function TE(t,r,e){if(e||arguments.length===2)for(var a=0,f=r.length,c;a<f;a++)(c||!(a in r))&&(c||(c=Array.prototype.slice.call(r,0,a)),c[a]=r[a]);return t.concat(c||Array.prototype.slice.call(r))}function Ab(t){return t}function Mb(t,r){r===void 0&&(r=Ab);var e=[],a=!1,f={read:function(){if(a)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return e.length?e[e.length-1]:t},useMedium:function(c){var s=r(c,a);return e.push(s),function(){e=e.filter(function(l){return l!==s})}},assignSyncMedium:function(c){for(a=!0;e.length;){var s=e;e=[],s.forEach(c)}e={push:function(l){return c(l)},filter:function(){return e}}},assignMedium:function(c){a=!0;var s=[];if(e.length){var l=e;e=[],l.forEach(c),s=e}var i=function(){var o=s;s=[],o.forEach(c)},n=function(){return Promise.resolve().then(i)};n(),e={push:function(o){s.push(o),n()},filter:function(o){return s=s.filter(o),e}}}};return f}function Rd(t,r){return r===void 0&&(r=Ab),Mb(t,r)}function jb(t){t===void 0&&(t={});var r=Mb(null);return r.options=bn({async:!0,ssr:!1},t),r}var Pb=function(t){var r=t.sideCar,e=Eb(t,["sideCar"]);if(!r)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var a=r.read();if(!a)throw new Error("Sidecar medium not found");return G.createElement(a,bn({},e))};Pb.isSideCarExport=!0;function EE(t,r){return t.useMedium(r),Pb}var Rb=Rd({},function(t){var r=t.target,e=t.currentTarget;return{target:r,currentTarget:e}}),Ib=Rd(),AE=Rd(),ME=jb({async:!0,ssr:typeof document<"u"}),jE=G.createContext(void 0),PE=[],Id=G.forwardRef(function(r,e){var a,f=G.useState(),c=f[0],s=f[1],l=G.useRef(),i=G.useRef(!1),n=G.useRef(null),o=G.useState({}),h=o[1],u=r.children,d=r.disabled,m=d===void 0?!1:d,b=r.noFocusGuards,p=b===void 0?!1:b,v=r.persistentFocus,g=v===void 0?!1:v,x=r.crossFrame,C=x===void 0?!0:x,T=r.autoFocus,R=T===void 0?!0:T;r.allowTextSelection;var B=r.group,I=r.className,F=r.whiteList,L=r.hasPositiveIndices,V=r.shards,z=V===void 0?PE:V,E=r.as,P=E===void 0?"div":E,k=r.lockProps,y=k===void 0?{}:k,w=r.sideCar,_=r.returnFocus,S=_===void 0?!1:_,A=r.focusOptions,O=r.onActivation,N=r.onDeactivation,U=G.useState({}),H=U[0],Z=G.useCallback(function(se){var Y=se.captureFocusRestore;if(!n.current){var te,ne=(te=document)==null?void 0:te.activeElement;n.current=ne,ne!==document.body&&(n.current=Y(ne))}l.current&&O&&O(l.current),i.current=!0,h()},[O]),D=G.useCallback(function(){i.current=!1,N&&N(l.current),h()},[N]),q=G.useCallback(function(se){var Y=n.current;if(Y){var te=(typeof Y=="function"?Y():Y)||document.body,ne=typeof S=="function"?S(te):S;if(ne){var oe=typeof ne=="object"?ne:void 0;n.current=null,se?Promise.resolve().then(function(){return te.focus(oe)}):te.focus(oe)}}},[S]),M=G.useCallback(function(se){i.current&&Rb.useMedium(se)},[]),j=Ib.useMedium,$=G.useCallback(function(se){l.current!==se&&(l.current=se,s(se))},[]),K=Ti((a={},a[Cb]=m&&"disabled",a[au]=B,a),y),J=p!==!0,X=J&&p!=="tail",Q=Tb([e,$]),ee=G.useMemo(function(){return{observed:l,shards:z,enabled:!m,active:i.current}},[m,i.current,z,c]);return cr.createElement(G.Fragment,null,J&&[cr.createElement("div",{key:"guard-first","data-focus-guard":!0,tabIndex:m?-1:0,style:cc}),L?cr.createElement("div",{key:"guard-nearest","data-focus-guard":!0,tabIndex:m?-1:1,style:cc}):null],!m&&cr.createElement(w,{id:H,sideCar:ME,observed:c,disabled:m,persistentFocus:g,crossFrame:C,autoFocus:R,whiteList:F,shards:z,onActivation:Z,onDeactivation:D,returnFocus:q,focusOptions:A,noFocusGuards:p}),cr.createElement(P,Ti({ref:Q},K,{className:I,onBlur:j,onFocus:M}),cr.createElement(jE.Provider,{value:ee},u)),X&&cr.createElement("div",{"data-focus-guard":!0,tabIndex:m?-1:0,style:cc}))});Id.propTypes={};function lu(t,r){return lu=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,a){return e.__proto__=a,e},lu(t,r)}function RE(t,r){t.prototype=Object.create(r.prototype),t.prototype.constructor=t,lu(t,r)}function Co(t){"@babel/helpers - typeof";return Co=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(r){return typeof r}:function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},Co(t)}function IE(t,r){if(Co(t)!="object"||!t)return t;var e=t[Symbol.toPrimitive];if(e!==void 0){var a=e.call(t,r);if(Co(a)!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(t)}function OE(t){var r=IE(t,"string");return Co(r)=="symbol"?r:r+""}function NE(t,r,e){return(r=OE(r))in t?Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[r]=e,t}function DE(t,r){function e(a){return a.displayName||a.name||"Component"}return function(f){var c=[],s;function l(){s=t(c.map(function(n){return n.props})),r(s)}var i=function(n){RE(o,n);function o(){return n.apply(this,arguments)||this}o.peek=function(){return s};var h=o.prototype;return h.componentDidMount=function(){c.push(this),l()},h.componentDidUpdate=function(){l()},h.componentWillUnmount=function(){var d=c.indexOf(this);c.splice(d,1),l()},h.render=function(){return cr.createElement(f,this.props)},o}(G.PureComponent);return NE(i,"displayName","SideEffect("+e(f)+")"),i}}var Cn=function(t){for(var r=Array(t.length),e=0;e<t.length;++e)r[e]=t[e];return r},Mi=function(t){return Array.isArray(t)?t:[t]},Ob=function(t){return Array.isArray(t)?t[0]:t},FE=function(t){if(t.nodeType!==Node.ELEMENT_NODE)return!1;var r=window.getComputedStyle(t,null);return!r||!r.getPropertyValue?!1:r.getPropertyValue("display")==="none"||r.getPropertyValue("visibility")==="hidden"},Nb=function(t){return t.parentNode&&t.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE?t.parentNode.host:t.parentNode},Db=function(t){return t===document||t&&t.nodeType===Node.DOCUMENT_NODE},BE=function(t){return t.hasAttribute("inert")},LE=function(t,r){return!t||Db(t)||!FE(t)&&!BE(t)&&r(Nb(t))},Fb=function(t,r){var e=t.get(r);if(e!==void 0)return e;var a=LE(r,Fb.bind(void 0,t));return t.set(r,a),a},$E=function(t,r){return t&&!Db(t)?UE(t)?r(Nb(t)):!1:!0},Bb=function(t,r){var e=t.get(r);if(e!==void 0)return e;var a=$E(r,Bb.bind(void 0,t));return t.set(r,a),a},Lb=function(t){return t.dataset},zE=function(t){return t.tagName==="BUTTON"},$b=function(t){return t.tagName==="INPUT"},zb=function(t){return $b(t)&&t.type==="radio"},VE=function(t){return!(($b(t)||zE(t))&&(t.type==="hidden"||t.disabled))},UE=function(t){var r=t.getAttribute(SE);return![!0,"true",""].includes(r)},Od=function(t){var r;return!!(t&&(!((r=Lb(t))===null||r===void 0)&&r.focusGuard))},cu=function(t){return!Od(t)},WE=function(t){return!!t},HE=function(t,r){var e=Math.max(0,t.tabIndex),a=Math.max(0,r.tabIndex),f=e-a,c=t.index-r.index;if(f){if(!e)return 1;if(!a)return-1}return f||c},qE=function(t){return t.tabIndex<0&&!t.hasAttribute("tabindex")?0:t.tabIndex},Nd=function(t,r,e){return Cn(t).map(function(a,f){var c=qE(a);return{node:a,index:f,tabIndex:e&&c===-1?(a.dataset||{}).focusGuard?0:-1:c}}).filter(function(a){return!r||a.tabIndex>=0}).sort(HE)},XE=["button:enabled","select:enabled","textarea:enabled","input:enabled","a[href]","area[href]","summary","iframe","object","embed","audio[controls]","video[controls]","[tabindex]","[contenteditable]","[autofocus]"],Dd=XE.join(","),KE="".concat(Dd,", [data-focus-guard]"),Vb=function(t,r){return Cn((t.shadowRoot||t).children).reduce(function(e,a){return e.concat(a.matches(r?KE:Dd)?[a]:[],Vb(a))},[])},GE=function(t,r){var e;return t instanceof HTMLIFrameElement&&(!((e=t.contentDocument)===null||e===void 0)&&e.body)?ms([t.contentDocument.body],r):[t]},ms=function(t,r){return t.reduce(function(e,a){var f,c=Vb(a,r),s=(f=[]).concat.apply(f,c.map(function(l){return GE(l,r)}));return e.concat(s,a.parentNode?Cn(a.parentNode.querySelectorAll(Dd)).filter(function(l){return l===a}):[])},[])},YE=function(t){var r=t.querySelectorAll("[".concat(_E,"]"));return Cn(r).map(function(e){return ms([e])}).reduce(function(e,a){return e.concat(a)},[])},Fd=function(t,r){return Cn(t).filter(function(e){return Fb(r,e)}).filter(function(e){return VE(e)})},Gp=function(t,r){return r===void 0&&(r=new Map),Cn(t).filter(function(e){return Bb(r,e)})},Bd=function(t,r,e){return Nd(Fd(ms(t,e),r),!0,e)},To=function(t,r){return Nd(Fd(ms(t),r),!1)},ZE=function(t,r){return Fd(YE(t),r)},ki=function(t,r){return t.shadowRoot?ki(t.shadowRoot,r):Object.getPrototypeOf(t).contains!==void 0&&Object.getPrototypeOf(t).contains.call(t,r)?!0:Cn(t.children).some(function(e){var a;if(e instanceof HTMLIFrameElement){var f=(a=e.contentDocument)===null||a===void 0?void 0:a.body;return f?ki(f,r):!1}return ki(e,r)})},JE=function(t){for(var r=new Set,e=t.length,a=0;a<e;a+=1)for(var f=a+1;f<e;f+=1){var c=t[a].compareDocumentPosition(t[f]);(c&Node.DOCUMENT_POSITION_CONTAINED_BY)>0&&r.add(f),(c&Node.DOCUMENT_POSITION_CONTAINS)>0&&r.add(a)}return t.filter(function(s,l){return!r.has(l)})},Ub=function(t){return t.parentNode?Ub(t.parentNode):t},Ld=function(t){var r=Mi(t);return r.filter(Boolean).reduce(function(e,a){var f=a.getAttribute(au);return e.push.apply(e,f?JE(Cn(Ub(a).querySelectorAll("[".concat(au,'="').concat(f,'"]:not([').concat(Cb,'="disabled"])')))):[a]),e},[])},QE=function(t){try{return t()}catch{return}},Eo=function(t){if(t===void 0&&(t=document),!(!t||!t.activeElement)){var r=t.activeElement;return r.shadowRoot?Eo(r.shadowRoot):r instanceof HTMLIFrameElement&&QE(function(){return r.contentWindow.document})?Eo(r.contentWindow.document):r}},eA=function(t,r){return t===r},tA=function(t,r){return!!Cn(t.querySelectorAll("iframe")).some(function(e){return eA(e,r)})},Wb=function(t,r){return r===void 0&&(r=Eo(Ob(t).ownerDocument)),!r||r.dataset&&r.dataset.focusGuard?!1:Ld(t).some(function(e){return ki(e,r)||tA(e,r)})},rA=function(t){t===void 0&&(t=document);var r=Eo(t);return r?Cn(t.querySelectorAll("[".concat(xE,"]"))).some(function(e){return ki(e,r)}):!1},nA=function(t,r){return r.filter(zb).filter(function(e){return e.name===t.name}).filter(function(e){return e.checked})[0]||t},$d=function(t,r){return zb(t)&&t.name?nA(t,r):t},iA=function(t){var r=new Set;return t.forEach(function(e){return r.add($d(e,t))}),t.filter(function(e){return r.has(e)})},Yp=function(t){return t[0]&&t.length>1?$d(t[0],t):t[0]},Zp=function(t,r){return t.indexOf($d(r,t))},uu="NEW_FOCUS",sA=function(t,r,e,a,f){var c=t.length,s=t[0],l=t[c-1],i=Od(a);if(!(a&&t.indexOf(a)>=0)){var n=a!==void 0?e.indexOf(a):-1,o=f?e.indexOf(f):n,h=f?t.indexOf(f):-1;if(n===-1)return h!==-1?h:uu;if(h===-1)return uu;var u=n-o,d=e.indexOf(s),m=e.indexOf(l),b=iA(e),p=a!==void 0?b.indexOf(a):-1,v=f?b.indexOf(f):p,g=b.filter(function(I){return I.tabIndex>=0}),x=a!==void 0?g.indexOf(a):-1,C=f?g.indexOf(f):x,T=x>=0&&C>=0?C-x:v-p;if(!u&&h>=0||r.length===0)return h;var R=Zp(t,r[0]),B=Zp(t,r[r.length-1]);if(n<=d&&i&&Math.abs(u)>1)return B;if(n>=m&&i&&Math.abs(u)>1)return R;if(u&&Math.abs(T)>1)return h;if(n<=d)return B;if(n>m)return R;if(u)return Math.abs(u)>1?h:(c+h+u)%c}},oA=function(t){return function(r){var e,a=(e=Lb(r))===null||e===void 0?void 0:e.autofocus;return r.autofocus||a!==void 0&&a!=="false"||t.indexOf(r)>=0}},Jp=function(t,r,e){var a=t.map(function(c){var s=c.node;return s}),f=Gp(a.filter(oA(e)));return f&&f.length?Yp(f):Yp(Gp(r))},du=function(t,r){return r===void 0&&(r=[]),r.push(t),t.parentNode&&du(t.parentNode.host||t.parentNode,r),r},uc=function(t,r){for(var e=du(t),a=du(r),f=0;f<e.length;f+=1){var c=e[f];if(a.indexOf(c)>=0)return c}return!1},Hb=function(t,r,e){var a=Mi(t),f=Mi(r),c=a[0],s=!1;return f.filter(Boolean).forEach(function(l){s=uc(s||l,l)||s,e.filter(Boolean).forEach(function(i){var n=uc(c,i);n&&(!s||ki(n,s)?s=n:s=uc(n,s))})}),s},Qp=function(t,r){return t.reduce(function(e,a){return e.concat(ZE(a,r))},[])},aA=function(t,r){var e=new Map;return r.forEach(function(a){return e.set(a.node,a)}),t.map(function(a){return e.get(a)}).filter(WE)},lA=function(t,r){var e=Eo(Mi(t).length>0?document:Ob(t).ownerDocument),a=Ld(t).filter(cu),f=Hb(e||t,t,a),c=new Map,s=To(a,c),l=s.filter(function(m){var b=m.node;return cu(b)});if(l[0]){var i=To([f],c).map(function(m){var b=m.node;return b}),n=aA(i,l),o=n.map(function(m){var b=m.node;return b}),h=n.filter(function(m){var b=m.tabIndex;return b>=0}).map(function(m){var b=m.node;return b}),u=sA(o,h,i,e,r);if(u===uu){var d=Jp(s,h,Qp(a,c))||Jp(s,o,Qp(a,c));if(d)return{node:d};console.warn("focus-lock: cannot find any node to move focus into");return}return u===void 0?u:n[u]}},cA=function(t){var r=Ld(t).filter(cu),e=Hb(t,t,r),a=Nd(ms([e],!0),!0,!0),f=ms(r,!1);return a.map(function(c){var s=c.node,l=c.index;return{node:s,index:l,lockItem:f.indexOf(s)>=0,guard:Od(s)}})},zd=function(t,r){t&&("focus"in t&&t.focus(r),"contentWindow"in t&&t.contentWindow&&t.contentWindow.focus())},dc=0,fc=!1,qb=function(t,r,e){e===void 0&&(e={});var a=lA(t,r);if(!fc&&a){if(dc>2){console.error("FocusLock: focus-fighting detected. Only one focus management system could be active. See https://github.com/theKashey/focus-lock/#focus-fighting"),fc=!0,setTimeout(function(){fc=!1},1);return}dc++,zd(a.node,e.focusOptions),dc--}};function Ns(t){if(!t)return null;if(typeof WeakRef>"u")return function(){return t||null};var r=t?new WeakRef(t):null;return function(){return r?.deref()||null}}var uA=function(t){if(!t)return null;for(var r=[],e=t;e&&e!==document.body;)r.push({current:Ns(e),parent:Ns(e.parentElement),left:Ns(e.previousElementSibling),right:Ns(e.nextElementSibling)}),e=e.parentElement;return{element:Ns(t),stack:r,ownerDocument:t.ownerDocument}},dA=function(t){var r,e,a,f,c;if(t)for(var s=t.stack,l=t.ownerDocument,i=new Map,n=0,o=s;n<o.length;n++){var h=o[n],u=(r=h.parent)===null||r===void 0?void 0:r.call(h);if(u&&l.contains(u)){for(var d=(e=h.left)===null||e===void 0?void 0:e.call(h),m=h.current(),b=u.contains(m)?m:void 0,p=(a=h.right)===null||a===void 0?void 0:a.call(h),v=Bd([u],i),g=(c=(f=b??d?.nextElementSibling)!==null&&f!==void 0?f:p)!==null&&c!==void 0?c:d;g;){for(var x=0,C=v;x<C.length;x++){var T=C[x];if(g?.contains(T.node))return T.node}g=g.nextElementSibling}if(v.length)return v[0].node}}},Xb=function(t){var r=uA(t);return function(){return dA(r)}},fA=function(t,r,e){if(!t||!r)return console.error("no element or scope given"),{};var a=Mi(r);if(a.every(function(s){return!ki(s,t)}))return console.error("Active element is not contained in the scope"),{};var f=e?Bd(a,new Map):To(a,new Map),c=f.findIndex(function(s){var l=s.node;return l===t});if(c!==-1)return{prev:f[c-1],next:f[c+1],first:f[0],last:f[f.length-1]}},hA=function(t,r){var e=r?Bd(Mi(t),new Map):To(Mi(t),new Map);return{first:e[0],last:e[e.length-1]}},pA=function(t){return Object.assign({scope:document.body,cycle:!0,onlyTabbable:!0},t)},Kb=function(t,r,e){r===void 0&&(r={});var a=pA(r),f=fA(t,a.scope,a.onlyTabbable);if(f){var c=e(f,a.cycle);c&&zd(c.node,a.focusOptions)}},mA=function(t,r){r===void 0&&(r={}),Kb(t,r,function(e,a){var f=e.next,c=e.first;return f||a&&c})},bA=function(t,r){r===void 0&&(r={}),Kb(t,r,function(e,a){var f=e.prev,c=e.last;return f||a&&c})},Gb=function(t,r,e){var a,f=hA(t,(a=r.onlyTabbable)!==null&&a!==void 0?a:!0),c=f[e];c&&zd(c.node,r.focusOptions)},gA=function(t,r){r===void 0&&(r={}),Gb(t,r,"first")},vA=function(t,r){r===void 0&&(r={}),Gb(t,r,"last")};function Vd(t){setTimeout(t,1)}var yA=function(r){return r&&"current"in r?r.current:r},Yb=function(){return document&&document.activeElement===document.body},wA=function(){return Yb()||rA()},as=null,Mr=null,em=function(){return null},ls=null,Ao=!1,Ud=!1,xA=function(){return!0},_A=function(r){return(as.whiteList||xA)(r)},SA=function(r,e){ls={observerNode:r,portaledElement:e}},kA=function(r){return ls&&ls.portaledElement===r};function tm(t,r,e,a){var f=null,c=t;do{var s=a[c];if(s.guard)s.node.dataset.focusAutoGuard&&(f=s);else if(s.lockItem){if(c!==t)return;f=null}else break}while((c+=e)!==r);f&&(f.node.tabIndex=0)}var CA=function(r){return r?!!Ao:Ao==="meanwhile"},TA=function t(r,e,a){return e&&(e.host===r&&(!e.activeElement||a.contains(e.activeElement))||e.parentNode&&t(r,e.parentNode,a))},EA=function(r,e){return e.some(function(a){return TA(r,a,a)})},Zb=function(r){return To(r,new Map)},AA=function(r){return!Zb([r.parentNode]).some(function(e){return e.node===r})},Ya=function(){var r=!1;if(as){var e=as,a=e.observed,f=e.persistentFocus,c=e.autoFocus,s=e.shards,l=e.crossFrame,i=e.focusOptions,n=e.noFocusGuards,o=a||ls&&ls.portaledElement;if(Yb()&&Mr&&Mr!==document.body&&(!document.body.contains(Mr)||AA(Mr))){var h=em();h&&h.focus()}var u=document&&document.activeElement;if(o){var d=[o].concat(s.map(yA).filter(Boolean)),m=function(){if(!CA(l)||!n||!Mr||Ud)return!1;var x=Zb(d),C=x.findIndex(function(T){var R=T.node;return R===Mr});return C===0||C===x.length-1};if((!u||_A(u))&&(f||m()||!wA()||!Mr&&c)&&(o&&!(Wb(d)||u&&EA(u,d)||kA(u))&&(document&&!Mr&&u&&!c?(u.blur&&u.blur(),document.body.focus()):(r=qb(d,Mr,{focusOptions:i}),ls={})),Mr=document&&document.activeElement,Mr!==document.body&&(em=Xb(Mr)),Ao=!1),document&&u!==document.activeElement&&document.querySelector("[data-focus-auto-guard]")){var b=document&&document.activeElement,p=cA(d),v=p.map(function(g){var x=g.node;return x}).indexOf(b);v>-1&&(p.filter(function(g){var x=g.guard,C=g.node;return x&&C.dataset.focusAutoGuard}).forEach(function(g){var x=g.node;return x.removeAttribute("tabIndex")}),tm(v,p.length,1,p),tm(v,-1,-1,p))}}}return r},Jb=function(r){Ya()&&r&&(r.stopPropagation(),r.preventDefault())},Wd=function(){return Vd(Ya)},MA=function(r){var e=r.target,a=r.currentTarget;a.contains(e)||SA(a,e)},jA=function(){return null},Qb=function(){Ud=!0},eg=function(){Ud=!1,Ao="just",Vd(function(){Ao="meanwhile"})},PA=function(){document.addEventListener("focusin",Jb),document.addEventListener("focusout",Wd),window.addEventListener("focus",Qb),window.addEventListener("blur",eg)},RA=function(){document.removeEventListener("focusin",Jb),document.removeEventListener("focusout",Wd),window.removeEventListener("focus",Qb),window.removeEventListener("blur",eg)};function IA(t){return t.filter(function(r){var e=r.disabled;return!e})}var tg={moveFocusInside:qb,focusInside:Wb,focusNextElement:mA,focusPrevElement:bA,focusFirstElement:gA,focusLastElement:vA,captureFocusRestore:Xb};function OA(t){var r=t.slice(-1)[0];r&&!as&&PA();var e=as,a=e&&r&&r.id===e.id;as=r,e&&!a&&(e.onDeactivation(),t.filter(function(f){var c=f.id;return c===e.id}).length||e.returnFocus(!r)),r?(Mr=null,(!a||e.observed!==r.observed)&&r.onActivation(tg),Ya(),Vd(Ya)):(RA(),Mr=null)}Rb.assignSyncMedium(MA);Ib.assignMedium(Wd);AE.assignMedium(function(t){return t(tg)});const NA=DE(IA,OA)(jA);var fu=G.forwardRef(function(r,e){return cr.createElement(Id,Ti({sideCar:NA,ref:e},r))}),rg=Id.propTypes||{};rg.sideCar;wE(rg,["sideCar"]);fu.propTypes={};function ng(t){return t!=null&&typeof t=="object"&&"nodeType"in t&&t.nodeType===Node.ELEMENT_NODE}function Hd(t){var r;if(!ng(t))return!1;const e=(r=t.ownerDocument.defaultView)!=null?r:window;return t instanceof e.HTMLElement}function DA(t){var r,e;return(e=(r=ig(t))==null?void 0:r.defaultView)!=null?e:window}function ig(t){return ng(t)?t.ownerDocument:document}function FA(t){return ig(t).activeElement}function BA(t){const r=t.ownerDocument.defaultView||window,{overflow:e,overflowX:a,overflowY:f}=r.getComputedStyle(t);return/auto|scroll|overlay|hidden/.test(e+f+a)}function LA(t){return t.localName==="html"?t:t.assignedSlot||t.parentElement||t.ownerDocument.documentElement}function sg(t){return["html","body","#document"].includes(t.localName)?t.ownerDocument.body:Hd(t)&&BA(t)?t:sg(LA(t))}var og=t=>t.hasAttribute("tabindex"),$A=t=>og(t)&&t.tabIndex===-1;function zA(t){return!!t.getAttribute("disabled")||!!t.getAttribute("aria-disabled")}function ag(t){return t.parentElement&&ag(t.parentElement)?!0:t.hidden}function VA(t){const r=t.getAttribute("contenteditable");return r!=="false"&&r!=null}function lg(t){if(!Hd(t)||ag(t)||zA(t))return!1;const{localName:r}=t;if(["input","select","textarea","button"].indexOf(r)>=0)return!0;const a={a:()=>t.hasAttribute("href"),audio:()=>t.hasAttribute("controls"),video:()=>t.hasAttribute("controls")};return r in a?a[r]():VA(t)?!0:og(t)}function UA(t){return t?Hd(t)&&lg(t)&&!$A(t):!1}var WA=["input:not(:disabled):not([disabled])","select:not(:disabled):not([disabled])","textarea:not(:disabled):not([disabled])","embed","iframe","object","a[href]","area[href]","button:not(:disabled):not([disabled])","[tabindex]","audio[controls]","video[controls]","*[tabindex]:not([aria-disabled])","*[contenteditable]"],HA=WA.join(),qA=t=>t.offsetWidth>0&&t.offsetHeight>0;function cg(t){const r=Array.from(t.querySelectorAll(HA));return r.unshift(t),r.filter(e=>lg(e)&&qA(e))}var rm,XA=(rm=fu.default)!=null?rm:fu,ug=t=>{const{initialFocusRef:r,finalFocusRef:e,contentRef:a,restoreFocus:f,children:c,isDisabled:s,autoFocus:l,persistentFocus:i,lockFocusAcrossFrames:n}=t,o=G.useCallback(()=>{r?.current?r.current.focus():a?.current&&cg(a.current).length===0&&requestAnimationFrame(()=>{var m;(m=a.current)==null||m.focus()})},[r,a]),h=G.useCallback(()=>{var d;(d=e?.current)==null||d.focus()},[e]),u=f&&!e;return W.jsx(XA,{crossFrame:n,persistentFocus:i,autoFocus:l,disabled:s,onActivation:o,onDeactivation:h,returnFocus:u,children:c})};ug.displayName="FocusLock";var KA=_9?G.useLayoutEffect:G.useEffect;function nm(t,r=[]){const e=G.useRef(t);return KA(()=>{e.current=t}),G.useCallback((...a)=>{var f;return(f=e.current)==null?void 0:f.call(e,...a)},r)}function GA(t,r){const e=G.useId();return G.useMemo(()=>t||[r,e].filter(Boolean).join("-"),[t,r,e])}function YA(t,r){const e=t!==void 0;return[e,e&&typeof t<"u"?t:r]}function xO(t={}){const{onClose:r,onOpen:e,isOpen:a,id:f}=t,c=nm(e),s=nm(r),[l,i]=G.useState(t.defaultIsOpen||!1),[n,o]=YA(a,l),h=GA(f,"disclosure"),u=G.useCallback(()=>{n||i(!1),s?.()},[n,s]),d=G.useCallback(()=>{n||i(!0),c?.()},[n,c]),m=G.useCallback(()=>{(o?u:d)()},[o,d,u]);return{isOpen:!!o,onOpen:d,onClose:u,onToggle:m,isControlled:n,getButtonProps:(b={})=>({...b,"aria-expanded":o,"aria-controls":h,onClick:E9(b.onClick,m)}),getDisclosureProps:(b={})=>({...b,hidden:!o,id:h})}}var[ZA,JA]=It({name:"InputGroupStylesContext",errorMessage:`useInputGroupStyles returned is 'undefined'. Seems you forgot to wrap the components in "<InputGroup />" `}),QA=Se(function(r,e){const a=or("Input",r),{children:f,className:c,...s}=Dt(r),l=Fe("chakra-input__group",c),i={},n=bl(f),o=a.field;n.forEach(u=>{var d,m;a&&(o&&u.type.id==="InputLeftElement"&&(i.paddingStart=(d=o.height)!=null?d:o.h),o&&u.type.id==="InputRightElement"&&(i.paddingEnd=(m=o.height)!=null?m:o.h),u.type.id==="InputRightAddon"&&(i.borderEndRadius=0),u.type.id==="InputLeftAddon"&&(i.borderStartRadius=0))});const h=n.map(u=>{var d,m;const b=zu({size:((d=u.props)==null?void 0:d.size)||r.size,variant:((m=u.props)==null?void 0:m.variant)||r.variant});return u.type.id!=="Input"?G.cloneElement(u,b):G.cloneElement(u,Object.assign(b,i,u.props))});return W.jsx(xe.div,{className:l,ref:e,__css:{width:"100%",display:"flex",position:"relative",isolation:"isolate",...a.group},"data-group":!0,...s,children:W.jsx(ZA,{value:a,children:h})})});QA.displayName="InputGroup";var eM=xe("div",{baseStyle:{display:"flex",alignItems:"center",justifyContent:"center",position:"absolute",top:"0",zIndex:2}}),gl=Se(function(r,e){var a,f;const{placement:c="left",...s}=r,l=JA(),i=l.field,o={[c==="left"?"insetStart":"insetEnd"]:"0",width:(a=i?.height)!=null?a:i?.h,height:(f=i?.height)!=null?f:i?.h,fontSize:i?.fontSize,...l.element};return W.jsx(eM,{ref:e,__css:o,...s})});gl.id="InputElement";gl.displayName="InputElement";var dg=Se(function(r,e){const{className:a,...f}=r,c=Fe("chakra-input__left-element",a);return W.jsx(gl,{ref:e,placement:"left",className:c,...f})});dg.id="InputLeftElement";dg.displayName="InputLeftElement";var fg=Se(function(r,e){const{className:a,...f}=r,c=Fe("chakra-input__right-element",a);return W.jsx(gl,{ref:e,placement:"right",className:c,...f})});fg.id="InputRightElement";fg.displayName="InputRightElement";var qd=Se(function(r,e){const{htmlSize:a,...f}=r,c=or("Input",f),s=Dt(f),l=jd(s),i=Fe("chakra-input",r.className);return W.jsx(xe.input,{size:a,...l,__css:c.field,ref:e,className:i})});qd.displayName="Input";qd.id="Input";var[tM,hg]=It({name:"ListStylesContext",errorMessage:`useListStyles returned is 'undefined'. Seems you forgot to wrap the components in "<List />" `}),qr=Se(function(r,e){const a=or("List",r),{children:f,styleType:c="none",stylePosition:s,spacing:l,...i}=Dt(r),n=bl(f),h=l?{["& > *:not(style) ~ *:not(style)"]:{mt:l}}:{};return W.jsx(tM,{value:a,children:W.jsx(xe.ul,{ref:e,listStyleType:c,listStylePosition:s,role:"list",__css:{...a.container,...h},...i,children:n})})});qr.displayName="List";var rM=Se((t,r)=>{const{as:e,...a}=t;return W.jsx(qr,{ref:r,as:"ol",styleType:"decimal",marginStart:"1em",...a})});rM.displayName="OrderedList";var nM=Se(function(r,e){const{as:a,...f}=r;return W.jsx(qr,{ref:e,as:"ul",styleType:"initial",marginStart:"1em",...f})});nM.displayName="UnorderedList";var Vt=Se(function(r,e){const a=hg();return W.jsx(xe.li,{ref:e,...r,__css:a.item})});Vt.displayName="ListItem";var hu=Se(function(r,e){const a=hg();return W.jsx(Tr,{ref:e,role:"presentation",...r,__css:a.icon})});hu.displayName="ListIcon";var pg=Se(function(r,e){const{templateAreas:a,gap:f,rowGap:c,columnGap:s,column:l,row:i,autoFlow:n,autoRows:o,templateRows:h,autoColumns:u,templateColumns:d,...m}=r,b={display:"grid",gridTemplateAreas:a,gridGap:f,gridRowGap:c,gridColumnGap:s,gridAutoColumns:u,gridColumn:l,gridRow:i,gridAutoFlow:n,gridAutoRows:o,gridTemplateRows:h,gridTemplateColumns:d};return W.jsx(xe.div,{ref:e,__css:b,...m})});pg.displayName="Grid";var mg=Object.freeze(["base","sm","md","lg","xl","2xl"]);function vl(t,r){return Array.isArray(t)?t.map(e=>e===null?null:r(e)):kr(t)?Object.keys(t).reduce((e,a)=>(e[a]=r(t[a]),e),{}):t!=null?r(t):null}function iM(t,r=mg){const e={};return t.forEach((a,f)=>{const c=r[f];a!=null&&(e[c]=a)}),e}var bg=Se(function(r,e){const{columns:a,spacingX:f,spacingY:c,spacing:s,minChildWidth:l,...i}=r,n=ri(),o=l?oM(l,n):aM(a);return W.jsx(pg,{ref:e,gap:s,columnGap:f,rowGap:c,templateColumns:o,...i})});bg.displayName="SimpleGrid";function sM(t){return typeof t=="number"?`${t}px`:t}function oM(t,r){return vl(t,e=>{const a=Zm("sizes",e,sM(e))(r);return e===null?null:`repeat(auto-fit, minmax(${a}, 1fr))`})}function aM(t){return vl(t,r=>r===null?null:`repeat(${r}, minmax(0, 1fr))`)}var He=Se(function(r,e){const a=$r("Text",r),{className:f,align:c,decoration:s,casing:l,...i}=Dt(r),n=zu({textAlign:r.align,textDecoration:r.decoration,textTransform:r.casing});return W.jsx(xe.p,{ref:e,className:Fe("chakra-text",r.className),...n,...i,__css:a})});He.displayName="Text";var lM=Se(function(r,e){const{spacing:a="0.5rem",spacingX:f,spacingY:c,children:s,justify:l,direction:i,align:n,className:o,shouldWrapChildren:h,...u}=r,d=G.useMemo(()=>h?G.Children.map(s,(m,b)=>W.jsx(gg,{children:m},b)):s,[s,h]);return W.jsx(xe.div,{ref:e,className:Fe("chakra-wrap",o),...u,children:W.jsx(xe.ul,{className:"chakra-wrap__list",__css:{display:"flex",flexWrap:"wrap",justifyContent:l,alignItems:n,flexDirection:i,listStyleType:"none",gap:a,columnGap:f,rowGap:c,padding:"0"},children:d})})});lM.displayName="Wrap";var gg=Se(function(r,e){const{className:a,...f}=r;return W.jsx(xe.li,{ref:e,__css:{display:"flex",alignItems:"flex-start"},className:Fe("chakra-wrap__listitem",a),...f})});gg.displayName="WrapItem";var vg=t=>W.jsx(xe.div,{className:"chakra-stack__item",...t,__css:{display:"inline-block",flex:"0 0 auto",minWidth:0,...t.__css}});vg.displayName="StackItem";function cM(t){const{spacing:r,direction:e}=t,a={column:{my:r,mx:0,borderLeftWidth:0,borderBottomWidth:"1px"},"column-reverse":{my:r,mx:0,borderLeftWidth:0,borderBottomWidth:"1px"},row:{mx:r,my:0,borderLeftWidth:"1px",borderBottomWidth:0},"row-reverse":{mx:r,my:0,borderLeftWidth:"1px",borderBottomWidth:0}};return{"&":vl(e,f=>a[f])}}var Xd=Se((t,r)=>{const{isInline:e,direction:a,align:f,justify:c,spacing:s="0.5rem",wrap:l,children:i,divider:n,className:o,shouldWrapChildren:h,...u}=t,d=e?"row":a??"column",m=G.useMemo(()=>cM({spacing:s,direction:d}),[s,d]),b=!!n,p=!h&&!b,v=G.useMemo(()=>{const x=bl(i);return p?x:x.map((C,T)=>{const R=typeof C.key<"u"?C.key:T,B=T+1===x.length,F=h?W.jsx(vg,{children:C},R):C;if(!b)return F;const L=G.cloneElement(n,{__css:m}),V=B?null:L;return W.jsxs(G.Fragment,{children:[F,V]},R)})},[n,m,b,p,h,i]),g=Fe("chakra-stack",o);return W.jsx(xe.div,{ref:r,display:"flex",alignItems:f,justifyContent:c,flexDirection:d,flexWrap:l,gap:b?void 0:s,className:g,...u,children:v})});Xd.displayName="Stack";var yr=Se((t,r)=>W.jsx(Xd,{align:"center",...t,direction:"column",ref:r}));yr.displayName="VStack";var lr=Se((t,r)=>W.jsx(Xd,{align:"center",...t,direction:"row",ref:r}));lr.displayName="HStack";function im(t){return vl(t,r=>r==="auto"?"auto":`span ${r}/span ${r}`)}var uM=Se(function(r,e){const{area:a,colSpan:f,colStart:c,colEnd:s,rowEnd:l,rowSpan:i,rowStart:n,...o}=r,h=zu({gridArea:a,gridColumn:im(f),gridRow:im(i),gridColumnStart:c,gridColumnEnd:s,gridRowStart:n,gridRowEnd:l});return W.jsx(xe.div,{ref:e,__css:h,...o})});uM.displayName="GridItem";var hi=Se(function(r,e){const a=$r("Heading",r),{className:f,...c}=Dt(r);return W.jsx(xe.h2,{ref:e,className:Fe("chakra-heading",r.className),...c,__css:a})});hi.displayName="Heading";var ft=xe("div");ft.displayName="Box";var yg=Se(function(r,e){const{size:a,centerContent:f=!0,...c}=r,s=f?{display:"flex",alignItems:"center",justifyContent:"center"}:{};return W.jsx(ft,{ref:e,boxSize:a,__css:{...s,flexShrink:0,flexGrow:0},...c})});yg.displayName="Square";var dM=Se(function(r,e){const{size:a,...f}=r;return W.jsx(yg,{size:a,ref:e,borderRadius:"9999px",...f})});dM.displayName="Circle";var Ar=Se(function(r,e){const a=$r("Badge",r),{className:f,...c}=Dt(r);return W.jsx(xe.span,{ref:e,className:Fe("chakra-badge",r.className),...c,__css:{display:"inline-block",whiteSpace:"nowrap",verticalAlign:"middle",...a}})});Ar.displayName="Badge";var fM=xe("div",{baseStyle:{display:"flex",alignItems:"center",justifyContent:"center"}});fM.displayName="Center";var hM={horizontal:{insetStart:"50%",transform:"translateX(-50%)"},vertical:{top:"50%",transform:"translateY(-50%)"},both:{insetStart:"50%",top:"50%",transform:"translate(-50%, -50%)"}};Se(function(r,e){const{axis:a="both",...f}=r;return W.jsx(xe.div,{ref:e,__css:hM[a],...f,position:"absolute"})});var pM=Se(function(r,e){const{className:a,centerContent:f,...c}=Dt(r),s=$r("Container",r);return W.jsx(xe.div,{ref:e,className:Fe("chakra-container",a),...c,__css:{...s,...f&&{display:"flex",flexDirection:"column",alignItems:"center"}}})});pM.displayName="Container";var wg=Se(function(r,e){const{borderLeftWidth:a,borderBottomWidth:f,borderTopWidth:c,borderRightWidth:s,borderWidth:l,borderStyle:i,borderColor:n,...o}=$r("Divider",r),{className:h,orientation:u="horizontal",__css:d,...m}=Dt(r),b={vertical:{borderLeftWidth:a||s||l||"1px",height:"100%"},horizontal:{borderBottomWidth:f||c||l||"1px",width:"100%"}};return W.jsx(xe.hr,{ref:e,"aria-orientation":u,...m,__css:{...o,border:"0",borderColor:n,borderStyle:i,...b[u],...d},className:Fe("chakra-divider",h)})});wg.displayName="Divider";var pu=Se(function(r,e){const{direction:a,align:f,justify:c,wrap:s,basis:l,grow:i,shrink:n,...o}=r,h={display:"flex",flexDirection:a,alignItems:f,justifyContent:c,flexWrap:s,flexBasis:l,flexGrow:i,flexShrink:n};return W.jsx(xe.div,{ref:e,__css:h,...o})});pu.displayName="Flex";function mM(t,r={}){const{ssr:e=!0,fallback:a}=r,{getWindow:f}=G9(),c=Array.isArray(t)?t:[t];let s=Array.isArray(a)?a:[a];s=s.filter(n=>n!=null);const[l,i]=G.useState(()=>c.map((n,o)=>({media:n,matches:e?!!s[o]:f().matchMedia(n).matches})));return G.useEffect(()=>{const n=f();i(c.map(u=>({media:u,matches:n.matchMedia(u).matches})));const o=c.map(u=>n.matchMedia(u)),h=u=>{i(d=>d.slice().map(m=>m.media===u.media?{...m,matches:u.matches}:m))};return o.forEach(u=>{typeof u.addListener=="function"?u.addListener(h):u.addEventListener("change",h)}),()=>{o.forEach(u=>{typeof u.removeListener=="function"?u.removeListener(h):u.removeEventListener("change",h)})}},[f]),l.map(n=>n.matches)}function bM(t,r,e=mg){let a=Object.keys(t).indexOf(r);if(a!==-1)return t[r];let f=e.indexOf(r);for(;f>=0;){const c=e[f];if(t.hasOwnProperty(c)){a=f;break}f-=1}if(a!==-1){const c=e[a];return t[c]}}function gM(t){var r,e;const a=kr(t)?t:{fallback:t??"base"},c=ri().__breakpoints.details.map(({minMaxQuery:n,breakpoint:o})=>({breakpoint:o,query:n.replace("@media screen and ","")})),s=c.map(n=>n.breakpoint===a.fallback),i=mM(c.map(n=>n.query),{fallback:s,ssr:a.ssr}).findIndex(n=>n==!0);return(e=(r=c[i])==null?void 0:r.breakpoint)!=null?e:a.fallback}function _O(t,r){var e;const a=kr(r)?r:{fallback:"base"},f=gM(a),c=ri();if(!f)return;const s=Array.from(((e=c.__breakpoints)==null?void 0:e.keys)||[]),l=Array.isArray(t)?Object.fromEntries(Object.entries(iM(t,s)).map(([i,n])=>[i,n])):t;return bM(l,f,s)}function vM(t){const{key:r}=t;return r.length===1||r.length>1&&/[^a-zA-Z0-9]/.test(r)}function yM(t={}){const{timeout:r=300,preventDefault:e=()=>!0}=t,[a,f]=G.useState([]),c=G.useRef(),s=()=>{c.current&&(clearTimeout(c.current),c.current=null)},l=()=>{s(),c.current=setTimeout(()=>{f([]),c.current=null},r)};G.useEffect(()=>s,[]);function i(n){return o=>{if(o.key==="Backspace"){const h=[...a];h.pop(),f(h);return}if(vM(o)){const h=a.concat(o.key);e(o)&&(o.preventDefault(),o.stopPropagation()),f(h),n(h.join("")),l()}}}return i}function wM(t,r,e,a){if(r==null)return a;if(!a)return t.find(s=>e(s).toLowerCase().startsWith(r.toLowerCase()));const f=t.filter(c=>e(c).toLowerCase().startsWith(r.toLowerCase()));if(f.length>0){let c;return f.includes(a)?(c=f.indexOf(a)+1,c===f.length&&(c=0),f[c]):(c=t.indexOf(f[0]),t[c])}return a}function xM(){const t=G.useRef(new Map),r=t.current,e=G.useCallback((f,c,s,l)=>{t.current.set(s,{type:c,el:f,options:l}),f.addEventListener(c,s,l)},[]),a=G.useCallback((f,c,s,l)=>{f.removeEventListener(c,s,l),t.current.delete(s)},[]);return G.useEffect(()=>()=>{r.forEach((f,c)=>{a(f.el,f.type,c,f.options)})},[a,r]),{add:e,remove:a}}function hc(t){const r=t.target,{tagName:e,isContentEditable:a}=r;return e!=="INPUT"&&e!=="TEXTAREA"&&a!==!0}function xg(t={}){const{ref:r,isDisabled:e,isFocusable:a,clickOnEnter:f=!0,clickOnSpace:c=!0,onMouseDown:s,onMouseUp:l,onClick:i,onKeyDown:n,onKeyUp:o,tabIndex:h,onMouseOver:u,onMouseLeave:d,...m}=t,[b,p]=G.useState(!0),[v,g]=G.useState(!1),x=xM(),C=w=>{w&&w.tagName!=="BUTTON"&&p(!1)},T=b?h:h||0,R=e&&!a,B=G.useCallback(w=>{if(e){w.stopPropagation(),w.preventDefault();return}w.currentTarget.focus(),i?.(w)},[e,i]),I=G.useCallback(w=>{v&&hc(w)&&(w.preventDefault(),w.stopPropagation(),g(!1),x.remove(document,"keyup",I,!1))},[v,x]),F=G.useCallback(w=>{if(n?.(w),e||w.defaultPrevented||w.metaKey||!hc(w.nativeEvent)||b)return;const _=f&&w.key==="Enter";c&&w.key===" "&&(w.preventDefault(),g(!0)),_&&(w.preventDefault(),w.currentTarget.click()),x.add(document,"keyup",I,!1)},[e,b,n,f,c,x,I]),L=G.useCallback(w=>{if(o?.(w),e||w.defaultPrevented||w.metaKey||!hc(w.nativeEvent)||b)return;c&&w.key===" "&&(w.preventDefault(),g(!1),w.currentTarget.click())},[c,b,e,o]),V=G.useCallback(w=>{w.button===0&&(g(!1),x.remove(document,"mouseup",V,!1))},[x]),z=G.useCallback(w=>{if(w.button!==0)return;if(e){w.stopPropagation(),w.preventDefault();return}b||g(!0),w.currentTarget.focus({preventScroll:!0}),x.add(document,"mouseup",V,!1),s?.(w)},[e,b,s,x,V]),E=G.useCallback(w=>{w.button===0&&(b||g(!1),l?.(w))},[l,b]),P=G.useCallback(w=>{if(e){w.preventDefault();return}u?.(w)},[e,u]),k=G.useCallback(w=>{v&&(w.preventDefault(),g(!1)),d?.(w)},[v,d]),y=Xt(r,C);return b?{...m,ref:y,type:"button","aria-disabled":R?void 0:e,disabled:R,onClick:B,onMouseDown:s,onMouseUp:l,onKeyUp:o,onKeyDown:n,onMouseOver:u,onMouseLeave:d}:{...m,ref:y,role:"button","data-active":Bt(v),"aria-disabled":e?"true":void 0,tabIndex:R?void 0:T,onClick:B,onMouseDown:z,onMouseUp:E,onKeyUp:L,onKeyDown:F,onMouseOver:P,onMouseLeave:k}}function _M(t){const r=t.current;if(!r)return!1;const e=FA(r);return!e||r.contains(e)?!1:!!UA(e)}function _g(t,r){const{shouldFocus:e,visible:a,focusRef:f}=r,c=e&&!a;Ei(()=>{if(!c||_M(t))return;const s=f?.current||t.current;let l;if(s)return l=requestAnimationFrame(()=>{s.focus({preventScroll:!0})}),()=>{cancelAnimationFrame(l)}},[c,t,f])}var SM={preventScroll:!0,shouldFocus:!1};function kM(t,r=SM){const{focusRef:e,preventScroll:a,shouldFocus:f,visible:c}=r,s=CM(t)?t.current:t,l=f&&c,i=G.useRef(l),n=G.useRef(c);Qn(()=>{!n.current&&c&&(i.current=l),n.current=c},[c,l]);const o=G.useCallback(()=>{if(!(!c||!s||!i.current)&&(i.current=!1,!s.contains(document.activeElement)))if(e?.current)requestAnimationFrame(()=>{var h;(h=e.current)==null||h.focus({preventScroll:a})});else{const h=cg(s);h.length>0&&requestAnimationFrame(()=>{h[0].focus({preventScroll:a})})}},[c,a,s,e]);Ei(()=>{o()},[o]),Si(s,"transitionend",o)}function CM(t){return"current"in t}var Bi=(t,r)=>({var:t,varRef:r?`var(${t}, ${r})`:`var(${t})`}),ir={arrowShadowColor:Bi("--popper-arrow-shadow-color"),arrowSize:Bi("--popper-arrow-size","8px"),arrowSizeHalf:Bi("--popper-arrow-size-half"),arrowBg:Bi("--popper-arrow-bg"),transformOrigin:Bi("--popper-transform-origin"),arrowOffset:Bi("--popper-arrow-offset")};function TM(t){if(t.includes("top"))return"1px 1px 0px 0 var(--popper-arrow-shadow-color)";if(t.includes("bottom"))return"-1px -1px 0px 0 var(--popper-arrow-shadow-color)";if(t.includes("right"))return"-1px 1px 0px 0 var(--popper-arrow-shadow-color)";if(t.includes("left"))return"1px -1px 0px 0 var(--popper-arrow-shadow-color)"}var EM={top:"bottom center","top-start":"bottom left","top-end":"bottom right",bottom:"top center","bottom-start":"top left","bottom-end":"top right",left:"right center","left-start":"right top","left-end":"right bottom",right:"left center","right-start":"left top","right-end":"left bottom"},AM=t=>EM[t],sm={scroll:!0,resize:!0};function MM(t){let r;return typeof t=="object"?r={enabled:!0,options:{...sm,...t}}:r={enabled:t,options:sm},r}var jM={name:"matchWidth",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:({state:t})=>{t.styles.popper.width=`${t.rects.reference.width}px`},effect:({state:t})=>()=>{const r=t.elements.reference;t.elements.popper.style.width=`${r.offsetWidth}px`}},PM={name:"transformOrigin",enabled:!0,phase:"write",fn:({state:t})=>{om(t)},effect:({state:t})=>()=>{om(t)}},om=t=>{t.elements.popper.style.setProperty(ir.transformOrigin.var,AM(t.placement))},RM={name:"positionArrow",enabled:!0,phase:"afterWrite",fn:({state:t})=>{IM(t)}},IM=t=>{var r;if(!t.placement)return;const e=OM(t.placement);if((r=t.elements)!=null&&r.arrow&&e){Object.assign(t.elements.arrow.style,{[e.property]:e.value,width:ir.arrowSize.varRef,height:ir.arrowSize.varRef,zIndex:-1});const a={[ir.arrowSizeHalf.var]:`calc(${ir.arrowSize.varRef} / 2 - 1px)`,[ir.arrowOffset.var]:`calc(${ir.arrowSizeHalf.varRef} * -1)`};for(const f in a)t.elements.arrow.style.setProperty(f,a[f])}},OM=t=>{if(t.startsWith("top"))return{property:"bottom",value:ir.arrowOffset.varRef};if(t.startsWith("bottom"))return{property:"top",value:ir.arrowOffset.varRef};if(t.startsWith("left"))return{property:"right",value:ir.arrowOffset.varRef};if(t.startsWith("right"))return{property:"left",value:ir.arrowOffset.varRef}},NM={name:"innerArrow",enabled:!0,phase:"main",requires:["arrow"],fn:({state:t})=>{am(t)},effect:({state:t})=>()=>{am(t)}},am=t=>{if(!t.elements.arrow)return;const r=t.elements.arrow.querySelector("[data-popper-arrow-inner]");if(!r)return;const e=TM(t.placement);e&&r.style.setProperty("--popper-arrow-default-shadow",e),Object.assign(r.style,{transform:"rotate(45deg)",background:ir.arrowBg.varRef,top:0,left:0,width:"100%",height:"100%",position:"absolute",zIndex:"inherit",boxShadow:"var(--popper-arrow-shadow, var(--popper-arrow-default-shadow))"})},DM={"start-start":{ltr:"left-start",rtl:"right-start"},"start-end":{ltr:"left-end",rtl:"right-end"},"end-start":{ltr:"right-start",rtl:"left-start"},"end-end":{ltr:"right-end",rtl:"left-end"},start:{ltr:"left",rtl:"right"},end:{ltr:"right",rtl:"left"}},FM={"auto-start":"auto-end","auto-end":"auto-start","top-start":"top-end","top-end":"top-start","bottom-start":"bottom-end","bottom-end":"bottom-start"};function BM(t,r="ltr"){var e,a;const f=((e=DM[t])==null?void 0:e[r])||t;return r==="ltr"?f:(a=FM[t])!=null?a:f}var Rr="top",Yr="bottom",Zr="right",Ir="left",Kd="auto",zo=[Rr,Yr,Zr,Ir],bs="start",Mo="end",LM="clippingParents",Sg="viewport",Ds="popper",$M="reference",lm=zo.reduce(function(t,r){return t.concat([r+"-"+bs,r+"-"+Mo])},[]),kg=[].concat(zo,[Kd]).reduce(function(t,r){return t.concat([r,r+"-"+bs,r+"-"+Mo])},[]),zM="beforeRead",VM="read",UM="afterRead",WM="beforeMain",HM="main",qM="afterMain",XM="beforeWrite",KM="write",GM="afterWrite",YM=[zM,VM,UM,WM,HM,qM,XM,KM,GM];function kn(t){return t?(t.nodeName||"").toLowerCase():null}function Lr(t){if(t==null)return window;if(t.toString()!=="[object Window]"){var r=t.ownerDocument;return r&&r.defaultView||window}return t}function ji(t){var r=Lr(t).Element;return t instanceof r||t instanceof Element}function Gr(t){var r=Lr(t).HTMLElement;return t instanceof r||t instanceof HTMLElement}function Gd(t){if(typeof ShadowRoot>"u")return!1;var r=Lr(t).ShadowRoot;return t instanceof r||t instanceof ShadowRoot}function ZM(t){var r=t.state;Object.keys(r.elements).forEach(function(e){var a=r.styles[e]||{},f=r.attributes[e]||{},c=r.elements[e];!Gr(c)||!kn(c)||(Object.assign(c.style,a),Object.keys(f).forEach(function(s){var l=f[s];l===!1?c.removeAttribute(s):c.setAttribute(s,l===!0?"":l)}))})}function JM(t){var r=t.state,e={popper:{position:r.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(r.elements.popper.style,e.popper),r.styles=e,r.elements.arrow&&Object.assign(r.elements.arrow.style,e.arrow),function(){Object.keys(r.elements).forEach(function(a){var f=r.elements[a],c=r.attributes[a]||{},s=Object.keys(r.styles.hasOwnProperty(a)?r.styles[a]:e[a]),l=s.reduce(function(i,n){return i[n]="",i},{});!Gr(f)||!kn(f)||(Object.assign(f.style,l),Object.keys(c).forEach(function(i){f.removeAttribute(i)}))})}}const QM={name:"applyStyles",enabled:!0,phase:"write",fn:ZM,effect:JM,requires:["computeStyles"]};function Sn(t){return t.split("-")[0]}var Ci=Math.max,Za=Math.min,gs=Math.round;function mu(){var t=navigator.userAgentData;return t!=null&&t.brands&&Array.isArray(t.brands)?t.brands.map(function(r){return r.brand+"/"+r.version}).join(" "):navigator.userAgent}function Cg(){return!/^((?!chrome|android).)*safari/i.test(mu())}function vs(t,r,e){r===void 0&&(r=!1),e===void 0&&(e=!1);var a=t.getBoundingClientRect(),f=1,c=1;r&&Gr(t)&&(f=t.offsetWidth>0&&gs(a.width)/t.offsetWidth||1,c=t.offsetHeight>0&&gs(a.height)/t.offsetHeight||1);var s=ji(t)?Lr(t):window,l=s.visualViewport,i=!Cg()&&e,n=(a.left+(i&&l?l.offsetLeft:0))/f,o=(a.top+(i&&l?l.offsetTop:0))/c,h=a.width/f,u=a.height/c;return{width:h,height:u,top:o,right:n+h,bottom:o+u,left:n,x:n,y:o}}function Yd(t){var r=vs(t),e=t.offsetWidth,a=t.offsetHeight;return Math.abs(r.width-e)<=1&&(e=r.width),Math.abs(r.height-a)<=1&&(a=r.height),{x:t.offsetLeft,y:t.offsetTop,width:e,height:a}}function Tg(t,r){var e=r.getRootNode&&r.getRootNode();if(t.contains(r))return!0;if(e&&Gd(e)){var a=r;do{if(a&&t.isSameNode(a))return!0;a=a.parentNode||a.host}while(a)}return!1}function $n(t){return Lr(t).getComputedStyle(t)}function ej(t){return["table","td","th"].indexOf(kn(t))>=0}function ii(t){return((ji(t)?t.ownerDocument:t.document)||window.document).documentElement}function yl(t){return kn(t)==="html"?t:t.assignedSlot||t.parentNode||(Gd(t)?t.host:null)||ii(t)}function cm(t){return!Gr(t)||$n(t).position==="fixed"?null:t.offsetParent}function tj(t){var r=/firefox/i.test(mu()),e=/Trident/i.test(mu());if(e&&Gr(t)){var a=$n(t);if(a.position==="fixed")return null}var f=yl(t);for(Gd(f)&&(f=f.host);Gr(f)&&["html","body"].indexOf(kn(f))<0;){var c=$n(f);if(c.transform!=="none"||c.perspective!=="none"||c.contain==="paint"||["transform","perspective"].indexOf(c.willChange)!==-1||r&&c.willChange==="filter"||r&&c.filter&&c.filter!=="none")return f;f=f.parentNode}return null}function Vo(t){for(var r=Lr(t),e=cm(t);e&&ej(e)&&$n(e).position==="static";)e=cm(e);return e&&(kn(e)==="html"||kn(e)==="body"&&$n(e).position==="static")?r:e||tj(t)||r}function Zd(t){return["top","bottom"].indexOf(t)>=0?"x":"y"}function ao(t,r,e){return Ci(t,Za(r,e))}function rj(t,r,e){var a=ao(t,r,e);return a>e?e:a}function Eg(){return{top:0,right:0,bottom:0,left:0}}function Ag(t){return Object.assign({},Eg(),t)}function Mg(t,r){return r.reduce(function(e,a){return e[a]=t,e},{})}var nj=function(r,e){return r=typeof r=="function"?r(Object.assign({},e.rects,{placement:e.placement})):r,Ag(typeof r!="number"?r:Mg(r,zo))};function ij(t){var r,e=t.state,a=t.name,f=t.options,c=e.elements.arrow,s=e.modifiersData.popperOffsets,l=Sn(e.placement),i=Zd(l),n=[Ir,Zr].indexOf(l)>=0,o=n?"height":"width";if(!(!c||!s)){var h=nj(f.padding,e),u=Yd(c),d=i==="y"?Rr:Ir,m=i==="y"?Yr:Zr,b=e.rects.reference[o]+e.rects.reference[i]-s[i]-e.rects.popper[o],p=s[i]-e.rects.reference[i],v=Vo(c),g=v?i==="y"?v.clientHeight||0:v.clientWidth||0:0,x=b/2-p/2,C=h[d],T=g-u[o]-h[m],R=g/2-u[o]/2+x,B=ao(C,R,T),I=i;e.modifiersData[a]=(r={},r[I]=B,r.centerOffset=B-R,r)}}function sj(t){var r=t.state,e=t.options,a=e.element,f=a===void 0?"[data-popper-arrow]":a;f!=null&&(typeof f=="string"&&(f=r.elements.popper.querySelector(f),!f)||Tg(r.elements.popper,f)&&(r.elements.arrow=f))}const oj={name:"arrow",enabled:!0,phase:"main",fn:ij,effect:sj,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function ys(t){return t.split("-")[1]}var aj={top:"auto",right:"auto",bottom:"auto",left:"auto"};function lj(t,r){var e=t.x,a=t.y,f=r.devicePixelRatio||1;return{x:gs(e*f)/f||0,y:gs(a*f)/f||0}}function um(t){var r,e=t.popper,a=t.popperRect,f=t.placement,c=t.variation,s=t.offsets,l=t.position,i=t.gpuAcceleration,n=t.adaptive,o=t.roundOffsets,h=t.isFixed,u=s.x,d=u===void 0?0:u,m=s.y,b=m===void 0?0:m,p=typeof o=="function"?o({x:d,y:b}):{x:d,y:b};d=p.x,b=p.y;var v=s.hasOwnProperty("x"),g=s.hasOwnProperty("y"),x=Ir,C=Rr,T=window;if(n){var R=Vo(e),B="clientHeight",I="clientWidth";if(R===Lr(e)&&(R=ii(e),$n(R).position!=="static"&&l==="absolute"&&(B="scrollHeight",I="scrollWidth")),R=R,f===Rr||(f===Ir||f===Zr)&&c===Mo){C=Yr;var F=h&&R===T&&T.visualViewport?T.visualViewport.height:R[B];b-=F-a.height,b*=i?1:-1}if(f===Ir||(f===Rr||f===Yr)&&c===Mo){x=Zr;var L=h&&R===T&&T.visualViewport?T.visualViewport.width:R[I];d-=L-a.width,d*=i?1:-1}}var V=Object.assign({position:l},n&&aj),z=o===!0?lj({x:d,y:b},Lr(e)):{x:d,y:b};if(d=z.x,b=z.y,i){var E;return Object.assign({},V,(E={},E[C]=g?"0":"",E[x]=v?"0":"",E.transform=(T.devicePixelRatio||1)<=1?"translate("+d+"px, "+b+"px)":"translate3d("+d+"px, "+b+"px, 0)",E))}return Object.assign({},V,(r={},r[C]=g?b+"px":"",r[x]=v?d+"px":"",r.transform="",r))}function cj(t){var r=t.state,e=t.options,a=e.gpuAcceleration,f=a===void 0?!0:a,c=e.adaptive,s=c===void 0?!0:c,l=e.roundOffsets,i=l===void 0?!0:l,n={placement:Sn(r.placement),variation:ys(r.placement),popper:r.elements.popper,popperRect:r.rects.popper,gpuAcceleration:f,isFixed:r.options.strategy==="fixed"};r.modifiersData.popperOffsets!=null&&(r.styles.popper=Object.assign({},r.styles.popper,um(Object.assign({},n,{offsets:r.modifiersData.popperOffsets,position:r.options.strategy,adaptive:s,roundOffsets:i})))),r.modifiersData.arrow!=null&&(r.styles.arrow=Object.assign({},r.styles.arrow,um(Object.assign({},n,{offsets:r.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:i})))),r.attributes.popper=Object.assign({},r.attributes.popper,{"data-popper-placement":r.placement})}const uj={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:cj,data:{}};var ca={passive:!0};function dj(t){var r=t.state,e=t.instance,a=t.options,f=a.scroll,c=f===void 0?!0:f,s=a.resize,l=s===void 0?!0:s,i=Lr(r.elements.popper),n=[].concat(r.scrollParents.reference,r.scrollParents.popper);return c&&n.forEach(function(o){o.addEventListener("scroll",e.update,ca)}),l&&i.addEventListener("resize",e.update,ca),function(){c&&n.forEach(function(o){o.removeEventListener("scroll",e.update,ca)}),l&&i.removeEventListener("resize",e.update,ca)}}const fj={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:dj,data:{}};var hj={left:"right",right:"left",bottom:"top",top:"bottom"};function Ra(t){return t.replace(/left|right|bottom|top/g,function(r){return hj[r]})}var pj={start:"end",end:"start"};function dm(t){return t.replace(/start|end/g,function(r){return pj[r]})}function Jd(t){var r=Lr(t),e=r.pageXOffset,a=r.pageYOffset;return{scrollLeft:e,scrollTop:a}}function Qd(t){return vs(ii(t)).left+Jd(t).scrollLeft}function mj(t,r){var e=Lr(t),a=ii(t),f=e.visualViewport,c=a.clientWidth,s=a.clientHeight,l=0,i=0;if(f){c=f.width,s=f.height;var n=Cg();(n||!n&&r==="fixed")&&(l=f.offsetLeft,i=f.offsetTop)}return{width:c,height:s,x:l+Qd(t),y:i}}function bj(t){var r,e=ii(t),a=Jd(t),f=(r=t.ownerDocument)==null?void 0:r.body,c=Ci(e.scrollWidth,e.clientWidth,f?f.scrollWidth:0,f?f.clientWidth:0),s=Ci(e.scrollHeight,e.clientHeight,f?f.scrollHeight:0,f?f.clientHeight:0),l=-a.scrollLeft+Qd(t),i=-a.scrollTop;return $n(f||e).direction==="rtl"&&(l+=Ci(e.clientWidth,f?f.clientWidth:0)-c),{width:c,height:s,x:l,y:i}}function ef(t){var r=$n(t),e=r.overflow,a=r.overflowX,f=r.overflowY;return/auto|scroll|overlay|hidden/.test(e+f+a)}function jg(t){return["html","body","#document"].indexOf(kn(t))>=0?t.ownerDocument.body:Gr(t)&&ef(t)?t:jg(yl(t))}function lo(t,r){var e;r===void 0&&(r=[]);var a=jg(t),f=a===((e=t.ownerDocument)==null?void 0:e.body),c=Lr(a),s=f?[c].concat(c.visualViewport||[],ef(a)?a:[]):a,l=r.concat(s);return f?l:l.concat(lo(yl(s)))}function bu(t){return Object.assign({},t,{left:t.x,top:t.y,right:t.x+t.width,bottom:t.y+t.height})}function gj(t,r){var e=vs(t,!1,r==="fixed");return e.top=e.top+t.clientTop,e.left=e.left+t.clientLeft,e.bottom=e.top+t.clientHeight,e.right=e.left+t.clientWidth,e.width=t.clientWidth,e.height=t.clientHeight,e.x=e.left,e.y=e.top,e}function fm(t,r,e){return r===Sg?bu(mj(t,e)):ji(r)?gj(r,e):bu(bj(ii(t)))}function vj(t){var r=lo(yl(t)),e=["absolute","fixed"].indexOf($n(t).position)>=0,a=e&&Gr(t)?Vo(t):t;return ji(a)?r.filter(function(f){return ji(f)&&Tg(f,a)&&kn(f)!=="body"}):[]}function yj(t,r,e,a){var f=r==="clippingParents"?vj(t):[].concat(r),c=[].concat(f,[e]),s=c[0],l=c.reduce(function(i,n){var o=fm(t,n,a);return i.top=Ci(o.top,i.top),i.right=Za(o.right,i.right),i.bottom=Za(o.bottom,i.bottom),i.left=Ci(o.left,i.left),i},fm(t,s,a));return l.width=l.right-l.left,l.height=l.bottom-l.top,l.x=l.left,l.y=l.top,l}function Pg(t){var r=t.reference,e=t.element,a=t.placement,f=a?Sn(a):null,c=a?ys(a):null,s=r.x+r.width/2-e.width/2,l=r.y+r.height/2-e.height/2,i;switch(f){case Rr:i={x:s,y:r.y-e.height};break;case Yr:i={x:s,y:r.y+r.height};break;case Zr:i={x:r.x+r.width,y:l};break;case Ir:i={x:r.x-e.width,y:l};break;default:i={x:r.x,y:r.y}}var n=f?Zd(f):null;if(n!=null){var o=n==="y"?"height":"width";switch(c){case bs:i[n]=i[n]-(r[o]/2-e[o]/2);break;case Mo:i[n]=i[n]+(r[o]/2-e[o]/2);break}}return i}function jo(t,r){r===void 0&&(r={});var e=r,a=e.placement,f=a===void 0?t.placement:a,c=e.strategy,s=c===void 0?t.strategy:c,l=e.boundary,i=l===void 0?LM:l,n=e.rootBoundary,o=n===void 0?Sg:n,h=e.elementContext,u=h===void 0?Ds:h,d=e.altBoundary,m=d===void 0?!1:d,b=e.padding,p=b===void 0?0:b,v=Ag(typeof p!="number"?p:Mg(p,zo)),g=u===Ds?$M:Ds,x=t.rects.popper,C=t.elements[m?g:u],T=yj(ji(C)?C:C.contextElement||ii(t.elements.popper),i,o,s),R=vs(t.elements.reference),B=Pg({reference:R,element:x,placement:f}),I=bu(Object.assign({},x,B)),F=u===Ds?I:R,L={top:T.top-F.top+v.top,bottom:F.bottom-T.bottom+v.bottom,left:T.left-F.left+v.left,right:F.right-T.right+v.right},V=t.modifiersData.offset;if(u===Ds&&V){var z=V[f];Object.keys(L).forEach(function(E){var P=[Zr,Yr].indexOf(E)>=0?1:-1,k=[Rr,Yr].indexOf(E)>=0?"y":"x";L[E]+=z[k]*P})}return L}function wj(t,r){r===void 0&&(r={});var e=r,a=e.placement,f=e.boundary,c=e.rootBoundary,s=e.padding,l=e.flipVariations,i=e.allowedAutoPlacements,n=i===void 0?kg:i,o=ys(a),h=o?l?lm:lm.filter(function(m){return ys(m)===o}):zo,u=h.filter(function(m){return n.indexOf(m)>=0});u.length===0&&(u=h);var d=u.reduce(function(m,b){return m[b]=jo(t,{placement:b,boundary:f,rootBoundary:c,padding:s})[Sn(b)],m},{});return Object.keys(d).sort(function(m,b){return d[m]-d[b]})}function xj(t){if(Sn(t)===Kd)return[];var r=Ra(t);return[dm(t),r,dm(r)]}function _j(t){var r=t.state,e=t.options,a=t.name;if(!r.modifiersData[a]._skip){for(var f=e.mainAxis,c=f===void 0?!0:f,s=e.altAxis,l=s===void 0?!0:s,i=e.fallbackPlacements,n=e.padding,o=e.boundary,h=e.rootBoundary,u=e.altBoundary,d=e.flipVariations,m=d===void 0?!0:d,b=e.allowedAutoPlacements,p=r.options.placement,v=Sn(p),g=v===p,x=i||(g||!m?[Ra(p)]:xj(p)),C=[p].concat(x).reduce(function(H,Z){return H.concat(Sn(Z)===Kd?wj(r,{placement:Z,boundary:o,rootBoundary:h,padding:n,flipVariations:m,allowedAutoPlacements:b}):Z)},[]),T=r.rects.reference,R=r.rects.popper,B=new Map,I=!0,F=C[0],L=0;L<C.length;L++){var V=C[L],z=Sn(V),E=ys(V)===bs,P=[Rr,Yr].indexOf(z)>=0,k=P?"width":"height",y=jo(r,{placement:V,boundary:o,rootBoundary:h,altBoundary:u,padding:n}),w=P?E?Zr:Ir:E?Yr:Rr;T[k]>R[k]&&(w=Ra(w));var _=Ra(w),S=[];if(c&&S.push(y[z]<=0),l&&S.push(y[w]<=0,y[_]<=0),S.every(function(H){return H})){F=V,I=!1;break}B.set(V,S)}if(I)for(var A=m?3:1,O=function(Z){var D=C.find(function(q){var M=B.get(q);if(M)return M.slice(0,Z).every(function(j){return j})});if(D)return F=D,"break"},N=A;N>0;N--){var U=O(N);if(U==="break")break}r.placement!==F&&(r.modifiersData[a]._skip=!0,r.placement=F,r.reset=!0)}}const Sj={name:"flip",enabled:!0,phase:"main",fn:_j,requiresIfExists:["offset"],data:{_skip:!1}};function hm(t,r,e){return e===void 0&&(e={x:0,y:0}),{top:t.top-r.height-e.y,right:t.right-r.width+e.x,bottom:t.bottom-r.height+e.y,left:t.left-r.width-e.x}}function pm(t){return[Rr,Zr,Yr,Ir].some(function(r){return t[r]>=0})}function kj(t){var r=t.state,e=t.name,a=r.rects.reference,f=r.rects.popper,c=r.modifiersData.preventOverflow,s=jo(r,{elementContext:"reference"}),l=jo(r,{altBoundary:!0}),i=hm(s,a),n=hm(l,f,c),o=pm(i),h=pm(n);r.modifiersData[e]={referenceClippingOffsets:i,popperEscapeOffsets:n,isReferenceHidden:o,hasPopperEscaped:h},r.attributes.popper=Object.assign({},r.attributes.popper,{"data-popper-reference-hidden":o,"data-popper-escaped":h})}const Cj={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:kj};function Tj(t,r,e){var a=Sn(t),f=[Ir,Rr].indexOf(a)>=0?-1:1,c=typeof e=="function"?e(Object.assign({},r,{placement:t})):e,s=c[0],l=c[1];return s=s||0,l=(l||0)*f,[Ir,Zr].indexOf(a)>=0?{x:l,y:s}:{x:s,y:l}}function Ej(t){var r=t.state,e=t.options,a=t.name,f=e.offset,c=f===void 0?[0,0]:f,s=kg.reduce(function(o,h){return o[h]=Tj(h,r.rects,c),o},{}),l=s[r.placement],i=l.x,n=l.y;r.modifiersData.popperOffsets!=null&&(r.modifiersData.popperOffsets.x+=i,r.modifiersData.popperOffsets.y+=n),r.modifiersData[a]=s}const Aj={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:Ej};function Mj(t){var r=t.state,e=t.name;r.modifiersData[e]=Pg({reference:r.rects.reference,element:r.rects.popper,placement:r.placement})}const jj={name:"popperOffsets",enabled:!0,phase:"read",fn:Mj,data:{}};function Pj(t){return t==="x"?"y":"x"}function Rj(t){var r=t.state,e=t.options,a=t.name,f=e.mainAxis,c=f===void 0?!0:f,s=e.altAxis,l=s===void 0?!1:s,i=e.boundary,n=e.rootBoundary,o=e.altBoundary,h=e.padding,u=e.tether,d=u===void 0?!0:u,m=e.tetherOffset,b=m===void 0?0:m,p=jo(r,{boundary:i,rootBoundary:n,padding:h,altBoundary:o}),v=Sn(r.placement),g=ys(r.placement),x=!g,C=Zd(v),T=Pj(C),R=r.modifiersData.popperOffsets,B=r.rects.reference,I=r.rects.popper,F=typeof b=="function"?b(Object.assign({},r.rects,{placement:r.placement})):b,L=typeof F=="number"?{mainAxis:F,altAxis:F}:Object.assign({mainAxis:0,altAxis:0},F),V=r.modifiersData.offset?r.modifiersData.offset[r.placement]:null,z={x:0,y:0};if(R){if(c){var E,P=C==="y"?Rr:Ir,k=C==="y"?Yr:Zr,y=C==="y"?"height":"width",w=R[C],_=w+p[P],S=w-p[k],A=d?-I[y]/2:0,O=g===bs?B[y]:I[y],N=g===bs?-I[y]:-B[y],U=r.elements.arrow,H=d&&U?Yd(U):{width:0,height:0},Z=r.modifiersData["arrow#persistent"]?r.modifiersData["arrow#persistent"].padding:Eg(),D=Z[P],q=Z[k],M=ao(0,B[y],H[y]),j=x?B[y]/2-A-M-D-L.mainAxis:O-M-D-L.mainAxis,$=x?-B[y]/2+A+M+q+L.mainAxis:N+M+q+L.mainAxis,K=r.elements.arrow&&Vo(r.elements.arrow),J=K?C==="y"?K.clientTop||0:K.clientLeft||0:0,X=(E=V?.[C])!=null?E:0,Q=w+j-X-J,ee=w+$-X,se=ao(d?Za(_,Q):_,w,d?Ci(S,ee):S);R[C]=se,z[C]=se-w}if(l){var Y,te=C==="x"?Rr:Ir,ne=C==="x"?Yr:Zr,oe=R[T],ae=T==="y"?"height":"width",ce=oe+p[te],me=oe-p[ne],be=[Rr,Ir].indexOf(v)!==-1,ye=(Y=V?.[T])!=null?Y:0,Me=be?ce:oe-B[ae]-I[ae]-ye+L.altAxis,Te=be?oe+B[ae]+I[ae]-ye-L.altAxis:me,fe=d&&be?rj(Me,oe,Te):ao(d?Me:ce,oe,d?Te:me);R[T]=fe,z[T]=fe-oe}r.modifiersData[a]=z}}const Ij={name:"preventOverflow",enabled:!0,phase:"main",fn:Rj,requiresIfExists:["offset"]};function Oj(t){return{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}function Nj(t){return t===Lr(t)||!Gr(t)?Jd(t):Oj(t)}function Dj(t){var r=t.getBoundingClientRect(),e=gs(r.width)/t.offsetWidth||1,a=gs(r.height)/t.offsetHeight||1;return e!==1||a!==1}function Fj(t,r,e){e===void 0&&(e=!1);var a=Gr(r),f=Gr(r)&&Dj(r),c=ii(r),s=vs(t,f,e),l={scrollLeft:0,scrollTop:0},i={x:0,y:0};return(a||!a&&!e)&&((kn(r)!=="body"||ef(c))&&(l=Nj(r)),Gr(r)?(i=vs(r,!0),i.x+=r.clientLeft,i.y+=r.clientTop):c&&(i.x=Qd(c))),{x:s.left+l.scrollLeft-i.x,y:s.top+l.scrollTop-i.y,width:s.width,height:s.height}}function Bj(t){var r=new Map,e=new Set,a=[];t.forEach(function(c){r.set(c.name,c)});function f(c){e.add(c.name);var s=[].concat(c.requires||[],c.requiresIfExists||[]);s.forEach(function(l){if(!e.has(l)){var i=r.get(l);i&&f(i)}}),a.push(c)}return t.forEach(function(c){e.has(c.name)||f(c)}),a}function Lj(t){var r=Bj(t);return YM.reduce(function(e,a){return e.concat(r.filter(function(f){return f.phase===a}))},[])}function $j(t){var r;return function(){return r||(r=new Promise(function(e){Promise.resolve().then(function(){r=void 0,e(t())})})),r}}function zj(t){var r=t.reduce(function(e,a){var f=e[a.name];return e[a.name]=f?Object.assign({},f,a,{options:Object.assign({},f.options,a.options),data:Object.assign({},f.data,a.data)}):a,e},{});return Object.keys(r).map(function(e){return r[e]})}var mm={placement:"bottom",modifiers:[],strategy:"absolute"};function bm(){for(var t=arguments.length,r=new Array(t),e=0;e<t;e++)r[e]=arguments[e];return!r.some(function(a){return!(a&&typeof a.getBoundingClientRect=="function")})}function Vj(t){t===void 0&&(t={});var r=t,e=r.defaultModifiers,a=e===void 0?[]:e,f=r.defaultOptions,c=f===void 0?mm:f;return function(l,i,n){n===void 0&&(n=c);var o={placement:"bottom",orderedModifiers:[],options:Object.assign({},mm,c),modifiersData:{},elements:{reference:l,popper:i},attributes:{},styles:{}},h=[],u=!1,d={state:o,setOptions:function(v){var g=typeof v=="function"?v(o.options):v;b(),o.options=Object.assign({},c,o.options,g),o.scrollParents={reference:ji(l)?lo(l):l.contextElement?lo(l.contextElement):[],popper:lo(i)};var x=Lj(zj([].concat(a,o.options.modifiers)));return o.orderedModifiers=x.filter(function(C){return C.enabled}),m(),d.update()},forceUpdate:function(){if(!u){var v=o.elements,g=v.reference,x=v.popper;if(bm(g,x)){o.rects={reference:Fj(g,Vo(x),o.options.strategy==="fixed"),popper:Yd(x)},o.reset=!1,o.placement=o.options.placement,o.orderedModifiers.forEach(function(L){return o.modifiersData[L.name]=Object.assign({},L.data)});for(var C=0;C<o.orderedModifiers.length;C++){if(o.reset===!0){o.reset=!1,C=-1;continue}var T=o.orderedModifiers[C],R=T.fn,B=T.options,I=B===void 0?{}:B,F=T.name;typeof R=="function"&&(o=R({state:o,options:I,name:F,instance:d})||o)}}}},update:$j(function(){return new Promise(function(p){d.forceUpdate(),p(o)})}),destroy:function(){b(),u=!0}};if(!bm(l,i))return d;d.setOptions(n).then(function(p){!u&&n.onFirstUpdate&&n.onFirstUpdate(p)});function m(){o.orderedModifiers.forEach(function(p){var v=p.name,g=p.options,x=g===void 0?{}:g,C=p.effect;if(typeof C=="function"){var T=C({state:o,name:v,instance:d,options:x}),R=function(){};h.push(T||R)}})}function b(){h.forEach(function(p){return p()}),h=[]}return d}}var Uj=[fj,jj,uj,QM,Aj,Sj,Ij,oj,Cj],Wj=Vj({defaultModifiers:Uj});function tf(t={}){const{enabled:r=!0,modifiers:e,placement:a="bottom",strategy:f="absolute",arrowPadding:c=8,eventListeners:s=!0,offset:l,gutter:i=8,flip:n=!0,boundary:o="clippingParents",preventOverflow:h=!0,matchWidth:u,direction:d="ltr"}=t,m=G.useRef(null),b=G.useRef(null),p=G.useRef(null),v=BM(a,d),g=G.useRef(()=>{}),x=G.useCallback(()=>{var L;!r||!m.current||!b.current||((L=g.current)==null||L.call(g),p.current=Wj(m.current,b.current,{placement:v,modifiers:[NM,RM,PM,{...jM,enabled:!!u},{name:"eventListeners",...MM(s)},{name:"arrow",options:{padding:c}},{name:"offset",options:{offset:l??[0,i]}},{name:"flip",enabled:!!n,options:{padding:8}},{name:"preventOverflow",enabled:!!h,options:{boundary:o}},...e??[]],strategy:f}),p.current.forceUpdate(),g.current=p.current.destroy)},[v,r,e,u,s,c,l,i,n,h,o,f]);G.useEffect(()=>()=>{var L;!m.current&&!b.current&&((L=p.current)==null||L.destroy(),p.current=null)},[]);const C=G.useCallback(L=>{m.current=L,x()},[x]),T=G.useCallback((L={},V=null)=>({...L,ref:Xt(C,V)}),[C]),R=G.useCallback(L=>{b.current=L,x()},[x]),B=G.useCallback((L={},V=null)=>({...L,ref:Xt(R,V),style:{...L.style,position:f,minWidth:u?void 0:"max-content",inset:"0 auto auto 0"}}),[f,R,u]),I=G.useCallback((L={},V=null)=>{const{size:z,shadowColor:E,bg:P,style:k,...y}=L;return{...y,ref:V,"data-popper-arrow":"",style:Hj(L)}},[]),F=G.useCallback((L={},V=null)=>({...L,ref:V,"data-popper-arrow-inner":""}),[]);return{update(){var L;(L=p.current)==null||L.update()},forceUpdate(){var L;(L=p.current)==null||L.forceUpdate()},transformOrigin:ir.transformOrigin.varRef,referenceRef:C,popperRef:R,getPopperProps:B,getArrowProps:I,getArrowInnerProps:F,getReferenceProps:T}}function Hj(t){const{size:r,shadowColor:e,bg:a,style:f}=t,c={...f,position:"absolute"};return r&&(c["--popper-arrow-size"]=r),e&&(c["--popper-arrow-shadow-color"]=e),a&&(c["--popper-arrow-bg"]=a),c}function rf(t={}){const{onClose:r,onOpen:e,isOpen:a,id:f}=t,c=xr(e),s=xr(r),[l,i]=G.useState(t.defaultIsOpen||!1),n=a!==void 0?a:l,o=a!==void 0,h=G.useId(),u=f??`disclosure-${h}`,d=G.useCallback(()=>{o||i(!1),s?.()},[o,s]),m=G.useCallback(()=>{o||i(!0),c?.()},[o,c]),b=G.useCallback(()=>{n?d():m()},[n,m,d]);function p(g={}){return{...g,"aria-expanded":n,"aria-controls":u,onClick(x){var C;(C=g.onClick)==null||C.call(g,x),b()}}}function v(g={}){return{...g,hidden:!n,id:u}}return{isOpen:n,onOpen:m,onClose:d,onToggle:b,isControlled:o,getButtonProps:p,getDisclosureProps:v}}function qj(t){const{ref:r,handler:e,enabled:a=!0}=t,f=xr(e),s=G.useRef({isPointerDown:!1,ignoreEmulatedMouseEvents:!1}).current;G.useEffect(()=>{if(!a)return;const l=h=>{pc(h,r)&&(s.isPointerDown=!0)},i=h=>{if(s.ignoreEmulatedMouseEvents){s.ignoreEmulatedMouseEvents=!1;return}s.isPointerDown&&e&&pc(h,r)&&(s.isPointerDown=!1,f(h))},n=h=>{s.ignoreEmulatedMouseEvents=!0,e&&s.isPointerDown&&pc(h,r)&&(s.isPointerDown=!1,f(h))},o=Rg(r.current);return o.addEventListener("mousedown",l,!0),o.addEventListener("mouseup",i,!0),o.addEventListener("touchstart",l,!0),o.addEventListener("touchend",n,!0),()=>{o.removeEventListener("mousedown",l,!0),o.removeEventListener("mouseup",i,!0),o.removeEventListener("touchstart",l,!0),o.removeEventListener("touchend",n,!0)}},[e,r,f,s,a])}function pc(t,r){var e;const a=t.target;return a&&!Rg(a).contains(a)?!1:!((e=r.current)!=null&&e.contains(a))}function Rg(t){var r;return(r=t?.ownerDocument)!=null?r:document}function Ig(t){const{isOpen:r,ref:e}=t,[a,f]=G.useState(r),[c,s]=G.useState(!1);return G.useEffect(()=>{c||(f(r),s(!0))},[r,c,a]),Si(()=>e.current,"animationend",()=>{f(r)}),{present:!(r?!1:!a),onComplete(){var i;const n=DA(e.current),o=new n.CustomEvent("animationend",{bubbles:!0});(i=e.current)==null||i.dispatchEvent(o)}}}function nf(t){const{wasSelected:r,enabled:e,isSelected:a,mode:f="unmount"}=t;return!!(!e||a||f==="keepMounted"&&r)}var[Xj,Kj,Gj,Yj]=Ed(),[Zj,Uo]=It({strict:!1,name:"MenuContext"});function Jj(t,...r){const e=G.useId(),a=t||e;return G.useMemo(()=>r.map(f=>`${f}-${a}`),[a,r])}function Og(t){var r;return(r=t?.ownerDocument)!=null?r:document}function gm(t){return Og(t).activeElement===t}function Qj(t={}){const{id:r,closeOnSelect:e=!0,closeOnBlur:a=!0,initialFocusRef:f,autoSelect:c=!0,isLazy:s,isOpen:l,defaultIsOpen:i,onClose:n,onOpen:o,placement:h="bottom-start",lazyBehavior:u="unmount",direction:d,computePositionOnMount:m=!1,...b}=t,p=G.useRef(null),v=G.useRef(null),g=Gj(),x=G.useCallback(()=>{requestAnimationFrame(()=>{var U;(U=p.current)==null||U.focus({preventScroll:!1})})},[]),C=G.useCallback(()=>{const U=setTimeout(()=>{var H;if(f)(H=f.current)==null||H.focus();else{const Z=g.firstEnabled();Z&&E(Z.index)}});_.current.add(U)},[g,f]),T=G.useCallback(()=>{const U=setTimeout(()=>{const H=g.lastEnabled();H&&E(H.index)});_.current.add(U)},[g]),R=G.useCallback(()=>{o?.(),c?C():x()},[c,C,x,o]),{isOpen:B,onOpen:I,onClose:F,onToggle:L}=rf({isOpen:l,defaultIsOpen:i,onClose:n,onOpen:R});qj({enabled:B&&a,ref:p,handler:U=>{var H;(H=v.current)!=null&&H.contains(U.target)||F()}});const V=tf({...b,enabled:B||m,placement:h,direction:d}),[z,E]=G.useState(-1);Ei(()=>{B||E(-1)},[B]),_g(p,{focusRef:v,visible:B,shouldFocus:!0});const P=Ig({isOpen:B,ref:p}),[k,y]=Jj(r,"menu-button","menu-list"),w=G.useCallback(()=>{I(),x()},[I,x]),_=G.useRef(new Set([]));G.useEffect(()=>{const U=_.current;return()=>{U.forEach(H=>clearTimeout(H)),U.clear()}},[]);const S=G.useCallback(()=>{I(),C()},[C,I]),A=G.useCallback(()=>{I(),T()},[I,T]),O=G.useCallback(()=>{var U,H;const Z=Og(p.current),D=(U=p.current)==null?void 0:U.contains(Z.activeElement);if(!(B&&!D))return;const M=(H=g.item(z))==null?void 0:H.node;M?.focus({preventScroll:!0})},[B,z,g]),N=G.useRef(null);return{openAndFocusMenu:w,openAndFocusFirstItem:S,openAndFocusLastItem:A,onTransitionEnd:O,unstable__animationState:P,descendants:g,popper:V,buttonId:k,menuId:y,forceUpdate:V.forceUpdate,orientation:"vertical",isOpen:B,onToggle:L,onOpen:I,onClose:F,menuRef:p,buttonRef:v,focusedIndex:z,closeOnSelect:e,closeOnBlur:a,autoSelect:c,setFocusedIndex:E,isLazy:s,lazyBehavior:u,initialFocusRef:f,rafId:N}}function eP(t={},r=null){const e=Uo(),{onToggle:a,popper:f,openAndFocusFirstItem:c,openAndFocusLastItem:s}=e,l=G.useCallback(i=>{const n=i.key,h={Enter:c,ArrowDown:c,ArrowUp:s}[n];h&&(i.preventDefault(),i.stopPropagation(),h(i))},[c,s]);return{...t,ref:Xt(e.buttonRef,r,f.referenceRef),id:e.buttonId,"data-active":Bt(e.isOpen),"aria-expanded":e.isOpen,"aria-haspopup":"menu","aria-controls":e.menuId,onClick:Qe(t.onClick,a),onKeyDown:Qe(t.onKeyDown,l)}}function gu(t){var r;return iP(t)&&!!((r=t?.getAttribute("role"))!=null&&r.startsWith("menuitem"))}function tP(t={},r=null){const e=Uo();if(!e)throw new Error("useMenuContext: context is undefined. Seems you forgot to wrap component within <Menu>");const{focusedIndex:a,setFocusedIndex:f,menuRef:c,isOpen:s,onClose:l,menuId:i,isLazy:n,lazyBehavior:o,unstable__animationState:h}=e,u=Kj(),d=yM({preventDefault:v=>v.key!==" "&&gu(v.target)}),m=G.useCallback(v=>{if(!v.currentTarget.contains(v.target))return;const g=v.key,C={Tab:R=>R.preventDefault(),Escape:l,ArrowDown:()=>{const R=u.nextEnabled(a);R&&f(R.index)},ArrowUp:()=>{const R=u.prevEnabled(a);R&&f(R.index)}}[g];if(C){v.preventDefault(),C(v);return}const T=d(R=>{const B=wM(u.values(),R,I=>{var F,L;return(L=(F=I?.node)==null?void 0:F.textContent)!=null?L:""},u.item(a));if(B){const I=u.indexOf(B.node);f(I)}});gu(v.target)&&T(v)},[u,a,d,l,f]),b=G.useRef(!1);s&&(b.current=!0);const p=nf({wasSelected:b.current,enabled:n,mode:o,isSelected:h.present});return{...t,ref:Xt(c,r),children:p?t.children:null,tabIndex:-1,role:"menu",id:i,style:{...t.style,transformOrigin:"var(--popper-transform-origin)"},"aria-orientation":"vertical",onKeyDown:Qe(t.onKeyDown,m)}}function rP(t={}){const{popper:r,isOpen:e}=Uo();return r.getPopperProps({...t,style:{visibility:e?"visible":"hidden",...t.style}})}function nP(t={},r=null){const{onMouseEnter:e,onMouseMove:a,onMouseLeave:f,onClick:c,onFocus:s,isDisabled:l,isFocusable:i,closeOnSelect:n,type:o,...h}=t,u=Uo(),{setFocusedIndex:d,focusedIndex:m,closeOnSelect:b,onClose:p,menuRef:v,isOpen:g,menuId:x,rafId:C}=u,T=G.useRef(null),R=`${x}-menuitem-${G.useId()}`,{index:B,register:I}=Yj({disabled:l&&!i}),F=G.useCallback(w=>{e?.(w),!l&&d(B)},[d,B,l,e]),L=G.useCallback(w=>{a?.(w),T.current&&!gm(T.current)&&F(w)},[F,a]),V=G.useCallback(w=>{f?.(w),!l&&d(-1)},[d,l,f]),z=G.useCallback(w=>{c?.(w),gu(w.currentTarget)&&(n??b)&&p()},[p,c,b,n]),E=G.useCallback(w=>{s?.(w),d(B)},[d,s,B]),P=B===m,k=l&&!i;Ei(()=>{if(g)return P&&!k&&T.current?(C.current&&cancelAnimationFrame(C.current),C.current=requestAnimationFrame(()=>{var w;(w=T.current)==null||w.focus({preventScroll:!0}),C.current=null})):v.current&&!gm(v.current)&&v.current.focus({preventScroll:!0}),()=>{C.current&&cancelAnimationFrame(C.current)}},[P,k,v,g]);const y=xg({onClick:z,onFocus:E,onMouseEnter:F,onMouseMove:L,onMouseLeave:V,ref:Xt(I,T,r),isDisabled:l,isFocusable:i});return{...h,...y,type:o??y.type,id:R,role:"menuitem",tabIndex:P?0:-1}}function iP(t){var r;if(!sP(t))return!1;const e=(r=t.ownerDocument.defaultView)!=null?r:window;return t instanceof e.HTMLElement}function sP(t){return t!=null&&typeof t=="object"&&"nodeType"in t&&t.nodeType===Node.ELEMENT_NODE}var[oP,Wo]=It({name:"MenuStylesContext",errorMessage:`useMenuStyles returned is 'undefined'. Seems you forgot to wrap the components in "<Menu />" `}),aP=t=>{const{children:r}=t,e=or("Menu",t),a=Dt(t),{direction:f}=ri(),{descendants:c,...s}=Qj({...a,direction:f}),l=G.useMemo(()=>s,[s]),{isOpen:i,onClose:n,forceUpdate:o}=l;return W.jsx(Xj,{value:c,children:W.jsx(Zj,{value:l,children:W.jsx(oP,{value:e,children:Xr(r,{isOpen:i,onClose:n,forceUpdate:o})})})})};aP.displayName="Menu";var Ng=Se((t,r)=>{const e=Wo();return W.jsx(xe.span,{ref:r,...t,__css:e.command,className:"chakra-menu__command"})});Ng.displayName="MenuCommand";var lP=Se((t,r)=>{const{type:e,...a}=t,f=Wo(),c=a.as||e?e??void 0:"button",s=G.useMemo(()=>({textDecoration:"none",color:"inherit",userSelect:"none",display:"flex",width:"100%",alignItems:"center",textAlign:"start",flex:"0 0 auto",outline:0,...f.item}),[f.item]);return W.jsx(xe.button,{ref:r,type:c,...a,__css:s})}),Dg=t=>{const{className:r,children:e,...a}=t,f=Wo(),c=G.Children.only(e),s=G.isValidElement(c)?G.cloneElement(c,{focusable:"false","aria-hidden":!0,className:Fe("chakra-menu__icon",c.props.className)}):null,l=Fe("chakra-menu__icon-wrapper",r);return W.jsx(xe.span,{className:l,...a,__css:f.icon,children:s})};Dg.displayName="MenuIcon";var cP=Se((t,r)=>{const{icon:e,iconSpacing:a="0.75rem",command:f,commandSpacing:c="0.75rem",children:s,...l}=t,i=nP(l,r),o=e||f?W.jsx("span",{style:{pointerEvents:"none",flex:1},children:s}):s;return W.jsxs(lP,{...i,className:Fe("chakra-menu__menuitem",i.className),children:[e&&W.jsx(Dg,{fontSize:"0.8em",marginEnd:a,children:e}),o,f&&W.jsx(Ng,{marginStart:c,children:f})]})});cP.displayName="MenuItem";var uP={enter:{visibility:"visible",opacity:1,scale:1,transition:{duration:.2,ease:[.4,0,.2,1]}},exit:{transitionEnd:{visibility:"hidden"},opacity:0,scale:.8,transition:{duration:.1,easings:"easeOut"}}},dP=xe(on.div),fP=Se(function(r,e){var a,f;const{rootProps:c,motionProps:s,...l}=r,{isOpen:i,onTransitionEnd:n,unstable__animationState:o}=Uo(),h=tP(l,e),u=rP(c),d=Wo();return W.jsx(xe.div,{...u,__css:{zIndex:(f=r.zIndex)!=null?f:(a=d.list)==null?void 0:a.zIndex},children:W.jsx(dP,{variants:uP,initial:!1,animate:i?"enter":"exit",__css:{outline:0,...d.list},...s,className:Fe("chakra-menu__menu-list",h.className),...h,onUpdate:n,onAnimationComplete:Ru(o.onComplete,h.onAnimationComplete)})})});fP.displayName="MenuList";var hP=Se((t,r)=>{const e=Wo();return W.jsx(xe.button,{ref:r,...t,__css:{display:"inline-flex",appearance:"none",alignItems:"center",outline:0,...e.button}})}),pP=Se((t,r)=>{const{children:e,as:a,...f}=t,c=eP(f,r),s=a||hP;return W.jsx(s,{...c,className:Fe("chakra-menu__menu-button",t.className),children:W.jsx(xe.span,{__css:{pointerEvents:"none",flex:"1 1 auto",minW:0},children:t.children})})});pP.displayName="MenuButton";var mP={slideInBottom:{...Xs,custom:{offsetY:16,reverse:!0}},slideInRight:{...Xs,custom:{offsetX:16,reverse:!0}},slideInTop:{...Xs,custom:{offsetY:-16,reverse:!0}},slideInLeft:{...Xs,custom:{offsetX:-16,reverse:!0}},scale:{...fb,custom:{initialScale:.95,reverse:!0}},none:{}},bP=xe(on.section),gP=t=>mP[t||"none"],Fg=G.forwardRef((t,r)=>{const{preset:e,motionProps:a=gP(e),...f}=t;return W.jsx(bP,{ref:r,...a,...f})});Fg.displayName="ModalTransition";var vP=Object.defineProperty,yP=(t,r,e)=>r in t?vP(t,r,{enumerable:!0,configurable:!0,writable:!0,value:e}):t[r]=e,wP=(t,r,e)=>(yP(t,r+"",e),e),xP=class{constructor(){wP(this,"modals"),this.modals=new Map}add(t){return this.modals.set(t,this.modals.size+1),this.modals.size}remove(t){this.modals.delete(t)}isTopModal(t){return t?this.modals.get(t)===this.modals.size:!1}},vu=new xP;function Bg(t,r){const[e,a]=G.useState(0);return G.useEffect(()=>{const f=t.current;if(f){if(r){const c=vu.add(f);a(c)}return()=>{vu.remove(f),a(0)}}},[r,t]),e}var _P=function(t){if(typeof document>"u")return null;var r=Array.isArray(t)?t[0]:t;return r.ownerDocument.body},Li=new WeakMap,ua=new WeakMap,da={},mc=0,Lg=function(t){return t&&(t.host||Lg(t.parentNode))},SP=function(t,r){return r.map(function(e){if(t.contains(e))return e;var a=Lg(e);return a&&t.contains(a)?a:(console.error("aria-hidden",e,"in not contained inside",t,". Doing nothing"),null)}).filter(function(e){return!!e})},kP=function(t,r,e,a){var f=SP(r,Array.isArray(t)?t:[t]);da[e]||(da[e]=new WeakMap);var c=da[e],s=[],l=new Set,i=new Set(f),n=function(h){!h||l.has(h)||(l.add(h),n(h.parentNode))};f.forEach(n);var o=function(h){!h||i.has(h)||Array.prototype.forEach.call(h.children,function(u){if(l.has(u))o(u);else try{var d=u.getAttribute(a),m=d!==null&&d!=="false",b=(Li.get(u)||0)+1,p=(c.get(u)||0)+1;Li.set(u,b),c.set(u,p),s.push(u),b===1&&m&&ua.set(u,!0),p===1&&u.setAttribute(e,"true"),m||u.setAttribute(a,"true")}catch(v){console.error("aria-hidden: cannot operate on ",u,v)}})};return o(r),l.clear(),mc++,function(){s.forEach(function(h){var u=Li.get(h)-1,d=c.get(h)-1;Li.set(h,u),c.set(h,d),u||(ua.has(h)||h.removeAttribute(a),ua.delete(h)),d||h.removeAttribute(e)}),mc--,mc||(Li=new WeakMap,Li=new WeakMap,ua=new WeakMap,da={})}},CP=function(t,r,e){e===void 0&&(e="data-aria-hidden");var a=Array.from(Array.isArray(t)?t:[t]),f=_P(t);return f?(a.push.apply(a,Array.from(f.querySelectorAll("[aria-live]"))),kP(a,f,e,"aria-hidden")):function(){return null}};function TP(t){const{isOpen:r,onClose:e,id:a,closeOnOverlayClick:f=!0,closeOnEsc:c=!0,useInert:s=!0,onOverlayClick:l,onEsc:i}=t,n=G.useRef(null),o=G.useRef(null),[h,u,d]=AP(a,"chakra-modal","chakra-modal--header","chakra-modal--body");EP(n,r&&s);const m=Bg(n,r),b=G.useRef(null),p=G.useCallback(F=>{b.current=F.target},[]),v=G.useCallback(F=>{F.key==="Escape"&&(F.stopPropagation(),c&&e?.(),i?.())},[c,e,i]),[g,x]=G.useState(!1),[C,T]=G.useState(!1),R=G.useCallback((F={},L=null)=>({role:"dialog",...F,ref:Xt(L,n),id:h,tabIndex:-1,"aria-modal":!0,"aria-labelledby":g?u:void 0,"aria-describedby":C?d:void 0,onClick:Qe(F.onClick,V=>V.stopPropagation())}),[d,C,h,u,g]),B=G.useCallback(F=>{F.stopPropagation(),b.current===F.target&&vu.isTopModal(n.current)&&(f&&e?.(),l?.())},[e,f,l]),I=G.useCallback((F={},L=null)=>({...F,ref:Xt(L,o),onClick:Qe(F.onClick,B),onKeyDown:Qe(F.onKeyDown,v),onMouseDown:Qe(F.onMouseDown,p)}),[v,p,B]);return{isOpen:r,onClose:e,headerId:u,bodyId:d,setBodyMounted:T,setHeaderMounted:x,dialogRef:n,overlayRef:o,getDialogProps:R,getDialogContainerProps:I,index:m}}function EP(t,r){const e=t.current;G.useEffect(()=>{if(!(!t.current||!r))return CP(t.current)},[r,t,e])}function AP(t,...r){const e=G.useId(),a=t||e;return G.useMemo(()=>r.map(f=>`${f}-${a}`),[a,r])}var[MP,Cs]=It({name:"ModalStylesContext",errorMessage:`useModalStyles returned is 'undefined'. Seems you forgot to wrap the components in "<Modal />" `}),[jP,Pi]=It({strict:!0,name:"ModalContext",errorMessage:"useModalContext: `context` is undefined. Seems you forgot to wrap modal components in `<Modal />`"}),sf=t=>{const r={scrollBehavior:"outside",autoFocus:!0,trapFocus:!0,returnFocusOnClose:!0,blockScrollOnMount:!0,allowPinchZoom:!1,motionPreset:"scale",lockFocusAcrossFrames:!0,...t},{portalProps:e,children:a,autoFocus:f,trapFocus:c,initialFocusRef:s,finalFocusRef:l,returnFocusOnClose:i,blockScrollOnMount:n,allowPinchZoom:o,preserveScrollBarGap:h,motionPreset:u,lockFocusAcrossFrames:d,onCloseComplete:m}=r,b=or("Modal",r),v={...TP(r),autoFocus:f,trapFocus:c,initialFocusRef:s,finalFocusRef:l,returnFocusOnClose:i,blockScrollOnMount:n,allowPinchZoom:o,preserveScrollBarGap:h,motionPreset:u,lockFocusAcrossFrames:d};return W.jsx(jP,{value:v,children:W.jsx(MP,{value:b,children:W.jsx(Ii,{onExitComplete:m,children:v.isOpen&&W.jsx(xs,{...e,children:a})})})})};sf.displayName="Modal";var Ia="right-scroll-bar-position",Oa="width-before-scroll-bar",PP="with-scroll-bars-hidden",RP="--removed-body-scroll-bar-size",$g=jb(),bc=function(){},wl=G.forwardRef(function(t,r){var e=G.useRef(null),a=G.useState({onScrollCapture:bc,onWheelCapture:bc,onTouchMoveCapture:bc}),f=a[0],c=a[1],s=t.forwardProps,l=t.children,i=t.className,n=t.removeScrollBar,o=t.enabled,h=t.shards,u=t.sideCar,d=t.noIsolation,m=t.inert,b=t.allowPinchZoom,p=t.as,v=p===void 0?"div":p,g=t.gapMode,x=Eb(t,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noIsolation","inert","allowPinchZoom","as","gapMode"]),C=u,T=Tb([e,r]),R=bn(bn({},x),f);return G.createElement(G.Fragment,null,o&&G.createElement(C,{sideCar:$g,removeScrollBar:n,shards:h,noIsolation:d,inert:m,setCallbacks:c,allowPinchZoom:!!b,lockRef:e,gapMode:g}),s?G.cloneElement(G.Children.only(l),bn(bn({},R),{ref:T})):G.createElement(v,bn({},R,{className:i,ref:T}),l))});wl.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};wl.classNames={fullWidth:Oa,zeroRight:Ia};var IP=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function OP(){if(!document)return null;var t=document.createElement("style");t.type="text/css";var r=IP();return r&&t.setAttribute("nonce",r),t}function NP(t,r){t.styleSheet?t.styleSheet.cssText=r:t.appendChild(document.createTextNode(r))}function DP(t){var r=document.head||document.getElementsByTagName("head")[0];r.appendChild(t)}var FP=function(){var t=0,r=null;return{add:function(e){t==0&&(r=OP())&&(NP(r,e),DP(r)),t++},remove:function(){t--,!t&&r&&(r.parentNode&&r.parentNode.removeChild(r),r=null)}}},BP=function(){var t=FP();return function(r,e){G.useEffect(function(){return t.add(r),function(){t.remove()}},[r&&e])}},zg=function(){var t=BP(),r=function(e){var a=e.styles,f=e.dynamic;return t(a,f),null};return r},LP={left:0,top:0,right:0,gap:0},gc=function(t){return parseInt(t||"",10)||0},$P=function(t){var r=window.getComputedStyle(document.body),e=r[t==="padding"?"paddingLeft":"marginLeft"],a=r[t==="padding"?"paddingTop":"marginTop"],f=r[t==="padding"?"paddingRight":"marginRight"];return[gc(e),gc(a),gc(f)]},zP=function(t){if(t===void 0&&(t="margin"),typeof window>"u")return LP;var r=$P(t),e=document.documentElement.clientWidth,a=window.innerWidth;return{left:r[0],top:r[1],right:r[2],gap:Math.max(0,a-e+r[2]-r[0])}},VP=zg(),cs="data-scroll-locked",UP=function(t,r,e,a){var f=t.left,c=t.top,s=t.right,l=t.gap;return e===void 0&&(e="margin"),` .`.concat(PP,` { overflow: hidden `).concat(a,`; padding-right: `).concat(l,"px ").concat(a,`; } body[`).concat(cs,`] { overflow: hidden `).concat(a,`; overscroll-behavior: contain; `).concat([r&&"position: relative ".concat(a,";"),e==="margin"&&` padding-left: `.concat(f,`px; padding-top: `).concat(c,`px; padding-right: `).concat(s,`px; margin-left:0; margin-top:0; margin-right: `).concat(l,"px ").concat(a,`; `),e==="padding"&&"padding-right: ".concat(l,"px ").concat(a,";")].filter(Boolean).join(""),` } .`).concat(Ia,` { right: `).concat(l,"px ").concat(a,`; } .`).concat(Oa,` { margin-right: `).concat(l,"px ").concat(a,`; } .`).concat(Ia," .").concat(Ia,` { right: 0 `).concat(a,`; } .`).concat(Oa," .").concat(Oa,` { margin-right: 0 `).concat(a,`; } body[`).concat(cs,`] { `).concat(RP,": ").concat(l,`px; } `)},vm=function(){var t=parseInt(document.body.getAttribute(cs)||"0",10);return isFinite(t)?t:0},WP=function(){G.useEffect(function(){return document.body.setAttribute(cs,(vm()+1).toString()),function(){var t=vm()-1;t<=0?document.body.removeAttribute(cs):document.body.setAttribute(cs,t.toString())}},[])},HP=function(t){var r=t.noRelative,e=t.noImportant,a=t.gapMode,f=a===void 0?"margin":a;WP();var c=G.useMemo(function(){return zP(f)},[f]);return G.createElement(VP,{styles:UP(c,!r,f,e?"":"!important")})},yu=!1;if(typeof window<"u")try{var fa=Object.defineProperty({},"passive",{get:function(){return yu=!0,!0}});window.addEventListener("test",fa,fa),window.removeEventListener("test",fa,fa)}catch{yu=!1}var $i=yu?{passive:!1}:!1,qP=function(t){return t.tagName==="TEXTAREA"},Vg=function(t,r){if(!(t instanceof Element))return!1;var e=window.getComputedStyle(t);return e[r]!=="hidden"&&!(e.overflowY===e.overflowX&&!qP(t)&&e[r]==="visible")},XP=function(t){return Vg(t,"overflowY")},KP=function(t){return Vg(t,"overflowX")},ym=function(t,r){var e=r.ownerDocument,a=r;do{typeof ShadowRoot<"u"&&a instanceof ShadowRoot&&(a=a.host);var f=Ug(t,a);if(f){var c=Wg(t,a),s=c[1],l=c[2];if(s>l)return!0}a=a.parentNode}while(a&&a!==e.body);return!1},GP=function(t){var r=t.scrollTop,e=t.scrollHeight,a=t.clientHeight;return[r,e,a]},YP=function(t){var r=t.scrollLeft,e=t.scrollWidth,a=t.clientWidth;return[r,e,a]},Ug=function(t,r){return t==="v"?XP(r):KP(r)},Wg=function(t,r){return t==="v"?GP(r):YP(r)},ZP=function(t,r){return t==="h"&&r==="rtl"?-1:1},JP=function(t,r,e,a,f){var c=ZP(t,window.getComputedStyle(r).direction),s=c*a,l=e.target,i=r.contains(l),n=!1,o=s>0,h=0,u=0;do{var d=Wg(t,l),m=d[0],b=d[1],p=d[2],v=b-p-c*m;(m||v)&&Ug(t,l)&&(h+=v,u+=m),l instanceof ShadowRoot?l=l.host:l=l.parentNode}while(!i&&l!==document.body||i&&(r.contains(l)||r===l));return(o&&Math.abs(h)<1||!o&&Math.abs(u)<1)&&(n=!0),n},ha=function(t){return"changedTouches"in t?[t.changedTouches[0].clientX,t.changedTouches[0].clientY]:[0,0]},wm=function(t){return[t.deltaX,t.deltaY]},xm=function(t){return t&&"current"in t?t.current:t},QP=function(t,r){return t[0]===r[0]&&t[1]===r[1]},eR=function(t){return` .block-interactivity-`.concat(t,` {pointer-events: none;} .allow-interactivity-`).concat(t,` {pointer-events: all;} `)},tR=0,zi=[];function rR(t){var r=G.useRef([]),e=G.useRef([0,0]),a=G.useRef(),f=G.useState(tR++)[0],c=G.useState(zg)[0],s=G.useRef(t);G.useEffect(function(){s.current=t},[t]),G.useEffect(function(){if(t.inert){document.body.classList.add("block-interactivity-".concat(f));var b=TE([t.lockRef.current],(t.shards||[]).map(xm),!0).filter(Boolean);return b.forEach(function(p){return p.classList.add("allow-interactivity-".concat(f))}),function(){document.body.classList.remove("block-interactivity-".concat(f)),b.forEach(function(p){return p.classList.remove("allow-interactivity-".concat(f))})}}},[t.inert,t.lockRef.current,t.shards]);var l=G.useCallback(function(b,p){if("touches"in b&&b.touches.length===2||b.type==="wheel"&&b.ctrlKey)return!s.current.allowPinchZoom;var v=ha(b),g=e.current,x="deltaX"in b?b.deltaX:g[0]-v[0],C="deltaY"in b?b.deltaY:g[1]-v[1],T,R=b.target,B=Math.abs(x)>Math.abs(C)?"h":"v";if("touches"in b&&B==="h"&&R.type==="range")return!1;var I=ym(B,R);if(!I)return!0;if(I?T=B:(T=B==="v"?"h":"v",I=ym(B,R)),!I)return!1;if(!a.current&&"changedTouches"in b&&(x||C)&&(a.current=T),!T)return!0;var F=a.current||T;return JP(F,p,b,F==="h"?x:C)},[]),i=G.useCallback(function(b){var p=b;if(!(!zi.length||zi[zi.length-1]!==c)){var v="deltaY"in p?wm(p):ha(p),g=r.current.filter(function(T){return T.name===p.type&&(T.target===p.target||p.target===T.shadowParent)&&QP(T.delta,v)})[0];if(g&&g.should){p.cancelable&&p.preventDefault();return}if(!g){var x=(s.current.shards||[]).map(xm).filter(Boolean).filter(function(T){return T.contains(p.target)}),C=x.length>0?l(p,x[0]):!s.current.noIsolation;C&&p.cancelable&&p.preventDefault()}}},[]),n=G.useCallback(function(b,p,v,g){var x={name:b,delta:p,target:v,should:g,shadowParent:nR(v)};r.current.push(x),setTimeout(function(){r.current=r.current.filter(function(C){return C!==x})},1)},[]),o=G.useCallback(function(b){e.current=ha(b),a.current=void 0},[]),h=G.useCallback(function(b){n(b.type,wm(b),b.target,l(b,t.lockRef.current))},[]),u=G.useCallback(function(b){n(b.type,ha(b),b.target,l(b,t.lockRef.current))},[]);G.useEffect(function(){return zi.push(c),t.setCallbacks({onScrollCapture:h,onWheelCapture:h,onTouchMoveCapture:u}),document.addEventListener("wheel",i,$i),document.addEventListener("touchmove",i,$i),document.addEventListener("touchstart",o,$i),function(){zi=zi.filter(function(b){return b!==c}),document.removeEventListener("wheel",i,$i),document.removeEventListener("touchmove",i,$i),document.removeEventListener("touchstart",o,$i)}},[]);var d=t.removeScrollBar,m=t.inert;return G.createElement(G.Fragment,null,m?G.createElement(c,{styles:eR(f)}):null,d?G.createElement(HP,{gapMode:t.gapMode}):null)}function nR(t){for(var r=null;t!==null;)t instanceof ShadowRoot&&(r=t.host,t=t.host),t=t.parentNode;return r}const iR=EE($g,rR);var Hg=G.forwardRef(function(t,r){return G.createElement(wl,bn({},t,{ref:r,sideCar:iR}))});Hg.classNames=wl.classNames;function sR(t){const{autoFocus:r,trapFocus:e,dialogRef:a,initialFocusRef:f,blockScrollOnMount:c,allowPinchZoom:s,finalFocusRef:l,returnFocusOnClose:i,preserveScrollBarGap:n,lockFocusAcrossFrames:o,isOpen:h}=Pi(),[u,d]=Xu();G.useEffect(()=>{!u&&d&&setTimeout(d)},[u,d]);const m=Bg(a,h);return W.jsx(ug,{autoFocus:r,isDisabled:!e,initialFocusRef:f,finalFocusRef:l,restoreFocus:i,contentRef:a,lockFocusAcrossFrames:o,children:W.jsx(Hg,{removeScrollBar:!n,allowPinchZoom:s,enabled:m===1&&c,forwardProps:!0,children:t.children})})}var of=Se((t,r)=>{const{className:e,children:a,containerProps:f,motionProps:c,...s}=t,{getDialogProps:l,getDialogContainerProps:i}=Pi(),n=l(s,r),o=i(f),h=Fe("chakra-modal__content",e),u=Cs(),d={display:"flex",flexDirection:"column",position:"relative",width:"100%",outline:0,...u.dialog},m={display:"flex",width:"100vw",height:"$100vh",position:"fixed",left:0,top:0,...u.dialogContainer},{motionPreset:b}=Pi();return W.jsx(sR,{children:W.jsx(xe.div,{...o,className:"chakra-modal__content-container",tabIndex:-1,__css:m,children:W.jsx(Fg,{preset:b,motionProps:c,className:h,...n,__css:d,children:a})})})});of.displayName="ModalContent";function SO(t){const{leastDestructiveRef:r,...e}=t;return W.jsx(sf,{...e,initialFocusRef:r})}var kO=Se((t,r)=>W.jsx(of,{ref:r,role:"alertdialog",...t})),qg=Se((t,r)=>{const{className:e,...a}=t,f=Fe("chakra-modal__footer",e),s={display:"flex",alignItems:"center",justifyContent:"flex-end",...Cs().footer};return W.jsx(xe.footer,{ref:r,...a,__css:s,className:f})});qg.displayName="ModalFooter";var Xg=Se((t,r)=>{const{className:e,...a}=t,{headerId:f,setHeaderMounted:c}=Pi();G.useEffect(()=>(c(!0),()=>c(!1)),[c]);const s=Fe("chakra-modal__header",e),i={flex:0,...Cs().header};return W.jsx(xe.header,{ref:r,className:s,id:f,...a,__css:i})});Xg.displayName="ModalHeader";var oR=xe(on.div),Kg=Se((t,r)=>{const{className:e,transition:a,motionProps:f,...c}=t,s=Fe("chakra-modal__overlay",e),i={pos:"fixed",left:"0",top:"0",w:"100vw",h:"100vh",...Cs().overlay},{motionPreset:n}=Pi(),h=f||(n==="none"?{}:db);return W.jsx(oR,{...h,__css:i,ref:r,className:s,...c})});Kg.displayName="ModalOverlay";var Gg=Se((t,r)=>{const{className:e,...a}=t,{bodyId:f,setBodyMounted:c}=Pi();G.useEffect(()=>(c(!0),()=>c(!1)),[c]);const s=Fe("chakra-modal__body",e),l=Cs();return W.jsx(xe.div,{ref:r,className:s,id:f,...a,__css:l.body})});Gg.displayName="ModalBody";var Yg=Se((t,r)=>{const{onClick:e,className:a,...f}=t,{onClose:c}=Pi(),s=Fe("chakra-modal__close-btn",a),l=Cs();return W.jsx(pl,{ref:r,__css:l.closeButton,className:s,onClick:Qe(e,i=>{i.stopPropagation(),c()}),...f})});Yg.displayName="ModalCloseButton";var aR=t=>W.jsx(Tr,{viewBox:"0 0 24 24",...t,children:W.jsx("path",{fill:"currentColor",d:"M21,5H3C2.621,5,2.275,5.214,2.105,5.553C1.937,5.892,1.973,6.297,2.2,6.6l9,12 c0.188,0.252,0.485,0.4,0.8,0.4s0.611-0.148,0.8-0.4l9-12c0.228-0.303,0.264-0.708,0.095-1.047C21.725,5.214,21.379,5,21,5z"})}),lR=t=>W.jsx(Tr,{viewBox:"0 0 24 24",...t,children:W.jsx("path",{fill:"currentColor",d:"M12.8,5.4c-0.377-0.504-1.223-0.504-1.6,0l-9,12c-0.228,0.303-0.264,0.708-0.095,1.047 C2.275,18.786,2.621,19,3,19h18c0.379,0,0.725-0.214,0.895-0.553c0.169-0.339,0.133-0.744-0.095-1.047L12.8,5.4z"})});function _m(t,r,e,a){G.useEffect(()=>{var f;if(!t.current||!a)return;const c=(f=t.current.ownerDocument.defaultView)!=null?f:window,s=Array.isArray(r)?r:[r],l=new c.MutationObserver(i=>{for(const n of i)n.type==="attributes"&&n.attributeName&&s.includes(n.attributeName)&&e(n)});return l.observe(t.current,{attributes:!0,attributeFilter:s}),()=>l.disconnect()})}function cR(t,r){const e=xr(t);G.useEffect(()=>{let a=null;const f=()=>e();return r!==null&&(a=window.setInterval(f,r)),()=>{a&&window.clearInterval(a)}},[r,e])}var uR=50,Sm=300;function dR(t,r){const[e,a]=G.useState(!1),[f,c]=G.useState(null),[s,l]=G.useState(!0),i=G.useRef(null),n=()=>clearTimeout(i.current);cR(()=>{f==="increment"&&t(),f==="decrement"&&r()},e?uR:null);const o=G.useCallback(()=>{s&&t(),i.current=setTimeout(()=>{l(!1),a(!0),c("increment")},Sm)},[t,s]),h=G.useCallback(()=>{s&&r(),i.current=setTimeout(()=>{l(!1),a(!0),c("decrement")},Sm)},[r,s]),u=G.useCallback(()=>{l(!0),a(!1),n()},[]);return G.useEffect(()=>()=>n(),[]),{up:o,down:h,stop:u,isSpinning:e}}var fR=/^[Ee0-9+\-.]$/;function hR(t){return fR.test(t)}function pR(t,r){if(t.key==null)return!0;const e=t.ctrlKey||t.altKey||t.metaKey;return!(t.key.length===1)||e?!0:r(t.key)}function mR(t={}){const{focusInputOnChange:r=!0,clampValueOnBlur:e=!0,keepWithinRange:a=!0,min:f=Number.MIN_SAFE_INTEGER,max:c=Number.MAX_SAFE_INTEGER,step:s=1,isReadOnly:l,isDisabled:i,isRequired:n,isInvalid:o,pattern:h="[0-9]*(.[0-9]+)?",inputMode:u="decimal",allowMouseWheel:d,id:m,onChange:b,precision:p,name:v,"aria-describedby":g,"aria-label":x,"aria-labelledby":C,onFocus:T,onBlur:R,onInvalid:B,getAriaValueText:I,isValidCharacter:F,format:L,parse:V,...z}=t,E=xr(T),P=xr(R),k=xr(B),y=xr(F??hR),w=xr(I),_=fE(t),{update:S,increment:A,decrement:O}=_,[N,U]=G.useState(!1),H=!(l||i),Z=G.useRef(null),D=G.useRef(null),q=G.useRef(null),M=G.useRef(null),j=G.useCallback(fe=>fe.split("").filter(y).join(""),[y]),$=G.useCallback(fe=>{var ke;return(ke=V?.(fe))!=null?ke:fe},[V]),K=G.useCallback(fe=>{var ke;return((ke=L?.(fe))!=null?ke:fe).toString()},[L]);Ei(()=>{(_.valueAsNumber>c||_.valueAsNumber<f)&&k?.("rangeOverflow",K(_.value),_.valueAsNumber)},[_.valueAsNumber,_.value,K,k]),Qn(()=>{if(!Z.current)return;if(Z.current.value!=_.value){const ke=$(Z.current.value);_.setValue(j(ke))}},[$,j]);const J=G.useCallback((fe=s)=>{H&&A(fe)},[A,H,s]),X=G.useCallback((fe=s)=>{H&&O(fe)},[O,H,s]),Q=dR(J,X);_m(q,"disabled",Q.stop,Q.isSpinning),_m(M,"disabled",Q.stop,Q.isSpinning);const ee=G.useCallback(fe=>{if(fe.nativeEvent.isComposing)return;const Ee=$(fe.currentTarget.value);S(j(Ee)),D.current={start:fe.currentTarget.selectionStart,end:fe.currentTarget.selectionEnd}},[S,j,$]),se=G.useCallback(fe=>{var ke,Ee,Ne;E?.(fe),D.current&&(fe.target.selectionStart=(Ee=D.current.start)!=null?Ee:(ke=fe.currentTarget.value)==null?void 0:ke.length,fe.currentTarget.selectionEnd=(Ne=D.current.end)!=null?Ne:fe.currentTarget.selectionStart)},[E]),Y=G.useCallback(fe=>{if(fe.nativeEvent.isComposing)return;pR(fe,y)||fe.preventDefault();const ke=te(fe)*s,Ee=fe.key,De={ArrowUp:()=>J(ke),ArrowDown:()=>X(ke),Home:()=>S(f),End:()=>S(c)}[Ee];De&&(fe.preventDefault(),De(fe))},[y,s,J,X,S,f,c]),te=fe=>{let ke=1;return(fe.metaKey||fe.ctrlKey)&&(ke=.1),fe.shiftKey&&(ke=10),ke},ne=G.useMemo(()=>{const fe=w?.(_.value);if(fe!=null)return fe;const ke=_.value.toString();return ke||void 0},[_.value,w]),oe=G.useCallback(()=>{let fe=_.value;if(_.value==="")return;/^[eE]/.test(_.value.toString())?_.setValue(""):(_.valueAsNumber<f&&(fe=f),_.valueAsNumber>c&&(fe=c),_.cast(fe))},[_,c,f]),ae=G.useCallback(()=>{U(!1),e&&oe()},[e,U,oe]),ce=G.useCallback(()=>{r&&requestAnimationFrame(()=>{var fe;(fe=Z.current)==null||fe.focus()})},[r]),me=G.useCallback(fe=>{fe.preventDefault(),Q.up(),ce()},[ce,Q]),be=G.useCallback(fe=>{fe.preventDefault(),Q.down(),ce()},[ce,Q]);Si(()=>Z.current,"wheel",fe=>{var ke,Ee;const De=((Ee=(ke=Z.current)==null?void 0:ke.ownerDocument)!=null?Ee:document).activeElement===Z.current;if(!d||!De)return;fe.preventDefault();const je=te(fe)*s,Ce=Math.sign(fe.deltaY);Ce===-1?J(je):Ce===1&&X(je)},{passive:!1});const ye=G.useCallback((fe={},ke=null)=>{const Ee=i||a&&_.isAtMax;return{...fe,ref:Xt(ke,q),role:"button",tabIndex:-1,onPointerDown:Qe(fe.onPointerDown,Ne=>{Ne.button!==0||Ee||me(Ne)}),onPointerLeave:Qe(fe.onPointerLeave,Q.stop),onPointerUp:Qe(fe.onPointerUp,Q.stop),disabled:Ee,"aria-disabled":On(Ee)}},[_.isAtMax,a,me,Q.stop,i]),Me=G.useCallback((fe={},ke=null)=>{const Ee=i||a&&_.isAtMin;return{...fe,ref:Xt(ke,M),role:"button",tabIndex:-1,onPointerDown:Qe(fe.onPointerDown,Ne=>{Ne.button!==0||Ee||be(Ne)}),onPointerLeave:Qe(fe.onPointerLeave,Q.stop),onPointerUp:Qe(fe.onPointerUp,Q.stop),disabled:Ee,"aria-disabled":On(Ee)}},[_.isAtMin,a,be,Q.stop,i]),Te=G.useCallback((fe={},ke=null)=>{var Ee,Ne,De,je;return{name:v,inputMode:u,type:"text",pattern:h,"aria-labelledby":C,"aria-label":x,"aria-describedby":g,id:m,disabled:i,...fe,readOnly:(Ee=fe.readOnly)!=null?Ee:l,"aria-readonly":(Ne=fe.readOnly)!=null?Ne:l,"aria-required":(De=fe.required)!=null?De:n,required:(je=fe.required)!=null?je:n,ref:Xt(Z,ke),value:K(_.value),role:"spinbutton","aria-valuemin":f,"aria-valuemax":c,"aria-valuenow":Number.isNaN(_.valueAsNumber)?void 0:_.valueAsNumber,"aria-invalid":On(o??_.isOutOfRange),"aria-valuetext":ne,autoComplete:"off",autoCorrect:"off",onChange:Qe(fe.onChange,ee),onKeyDown:Qe(fe.onKeyDown,Y),onFocus:Qe(fe.onFocus,se,()=>U(!0)),onBlur:Qe(fe.onBlur,P,ae)}},[v,u,h,C,x,K,g,m,i,n,l,o,_.value,_.valueAsNumber,_.isOutOfRange,f,c,ne,ee,Y,se,P,ae]);return{value:K(_.value),valueAsNumber:_.valueAsNumber,isFocused:N,isDisabled:i,isReadOnly:l,getIncrementButtonProps:ye,getDecrementButtonProps:Me,getInputProps:Te,htmlProps:z}}var[bR,xl]=It({name:"NumberInputStylesContext",errorMessage:`useNumberInputStyles returned is 'undefined'. Seems you forgot to wrap the components in "<NumberInput />" `}),[gR,af]=It({name:"NumberInputContext",errorMessage:"useNumberInputContext: `context` is undefined. Seems you forgot to wrap number-input's components within <NumberInput />"}),vR=Se(function(r,e){const a=or("NumberInput",r),f=Dt(r),c=xb(f),{htmlProps:s,...l}=mR(c),i=G.useMemo(()=>l,[l]);return W.jsx(gR,{value:i,children:W.jsx(bR,{value:a,children:W.jsx(xe.div,{...s,ref:e,className:Fe("chakra-numberinput",r.className),__css:{position:"relative",zIndex:0,...a.root}})})})});vR.displayName="NumberInput";var yR=Se(function(r,e){const a=xl();return W.jsx(xe.div,{"aria-hidden":!0,ref:e,...r,__css:{display:"flex",flexDirection:"column",position:"absolute",top:"0",insetEnd:"0px",margin:"1px",height:"calc(100% - 2px)",zIndex:1,...a.stepperGroup}})});yR.displayName="NumberInputStepper";var wR=Se(function(r,e){const{getInputProps:a}=af(),f=a(r,e),c=xl();return W.jsx(xe.input,{...f,className:Fe("chakra-numberinput__field",r.className),__css:{width:"100%",...c.field}})});wR.displayName="NumberInputField";var Zg=xe("div",{baseStyle:{display:"flex",justifyContent:"center",alignItems:"center",flex:1,transitionProperty:"common",transitionDuration:"normal",userSelect:"none",cursor:"pointer",lineHeight:"normal"}}),xR=Se(function(r,e){var a;const f=xl(),{getDecrementButtonProps:c}=af(),s=c(r,e);return W.jsx(Zg,{...s,__css:f.stepper,children:(a=r.children)!=null?a:W.jsx(aR,{})})});xR.displayName="NumberDecrementStepper";var _R=Se(function(r,e){var a;const{getIncrementButtonProps:f}=af(),c=f(r,e),s=xl();return W.jsx(Zg,{...c,__css:s.stepper,children:(a=r.children)!=null?a:W.jsx(lR,{})})});_R.displayName="NumberIncrementStepper";var[SR,Oi]=It({name:"PopoverContext",errorMessage:"usePopoverContext: `context` is undefined. Seems you forgot to wrap all popover components within `<Popover />`"}),[kR,Ho]=It({name:"PopoverStylesContext",errorMessage:`usePopoverStyles returned is 'undefined'. Seems you forgot to wrap the components in "<Popover />" `}),CR=Se(function(r,e){const{getHeaderProps:a}=Oi(),f=Ho();return W.jsx(xe.header,{...a(r,e),className:Fe("chakra-popover__header",r.className),__css:f.header})});CR.displayName="PopoverHeader";function TR(t){const r=G.Children.only(t.children),{getTriggerProps:e}=Oi();return G.cloneElement(r,e(r.props,r.ref))}TR.displayName="PopoverTrigger";var Vi={click:"click",hover:"hover"};function ER(t={}){const{closeOnBlur:r=!0,closeOnEsc:e=!0,initialFocusRef:a,id:f,returnFocusOnClose:c=!0,autoFocus:s=!0,arrowSize:l,arrowShadowColor:i,trigger:n=Vi.click,openDelay:o=200,closeDelay:h=200,isLazy:u,lazyBehavior:d="unmount",computePositionOnMount:m,...b}=t,{isOpen:p,onClose:v,onOpen:g,onToggle:x}=rf(t),C=G.useRef(null),T=G.useRef(null),R=G.useRef(null),B=G.useRef(!1),I=G.useRef(!1);p&&(I.current=!0);const[F,L]=G.useState(!1),[V,z]=G.useState(!1),E=G.useId(),P=f??E,[k,y,w,_]=["popover-trigger","popover-content","popover-header","popover-body"].map(ee=>`${ee}-${P}`),{referenceRef:S,getArrowProps:A,getPopperProps:O,getArrowInnerProps:N,forceUpdate:U}=tf({...b,enabled:p||!!m}),H=Ig({isOpen:p,ref:R});yE({enabled:p,ref:T}),_g(R,{focusRef:T,visible:p,shouldFocus:c&&n===Vi.click}),kM(R,{focusRef:a,visible:p,shouldFocus:s&&n===Vi.click});const Z=nf({wasSelected:I.current,enabled:u,mode:d,isSelected:H.present}),D=G.useCallback((ee={},se=null)=>{const Y={...ee,style:{...ee.style,transformOrigin:ir.transformOrigin.varRef,[ir.arrowSize.var]:l?`${l}px`:void 0,[ir.arrowShadowColor.var]:i},ref:Xt(R,se),children:Z?ee.children:null,id:y,tabIndex:-1,role:"dialog",onKeyDown:Qe(ee.onKeyDown,te=>{e&&te.key==="Escape"&&v()}),onBlur:Qe(ee.onBlur,te=>{const ne=km(te),oe=vc(R.current,ne),ae=vc(T.current,ne);p&&r&&(!oe&&!ae)&&v()}),"aria-labelledby":F?w:void 0,"aria-describedby":V?_:void 0};return n===Vi.hover&&(Y.role="tooltip",Y.onMouseEnter=Qe(ee.onMouseEnter,()=>{B.current=!0}),Y.onMouseLeave=Qe(ee.onMouseLeave,te=>{te.nativeEvent.relatedTarget!==null&&(B.current=!1,setTimeout(()=>v(),h))})),Y},[Z,y,F,w,V,_,n,e,v,p,r,h,i,l]),q=G.useCallback((ee={},se=null)=>O({...ee,style:{visibility:p?"visible":"hidden",...ee.style}},se),[p,O]),M=G.useCallback((ee,se=null)=>({...ee,ref:Xt(se,C,S)}),[C,S]),j=G.useRef(),$=G.useRef(),K=G.useCallback(ee=>{C.current==null&&S(ee)},[S]),J=G.useCallback((ee={},se=null)=>{const Y={...ee,ref:Xt(T,se,K),id:k,"aria-haspopup":"dialog","aria-expanded":p,"aria-controls":y};return n===Vi.click&&(Y.onClick=Qe(ee.onClick,x)),n===Vi.hover&&(Y.onFocus=Qe(ee.onFocus,()=>{j.current===void 0&&g()}),Y.onBlur=Qe(ee.onBlur,te=>{const ne=km(te),oe=!vc(R.current,ne);p&&r&&oe&&v()}),Y.onKeyDown=Qe(ee.onKeyDown,te=>{te.key==="Escape"&&v()}),Y.onMouseEnter=Qe(ee.onMouseEnter,()=>{B.current=!0,j.current=window.setTimeout(()=>g(),o)}),Y.onMouseLeave=Qe(ee.onMouseLeave,()=>{B.current=!1,j.current&&(clearTimeout(j.current),j.current=void 0),$.current=window.setTimeout(()=>{B.current===!1&&v()},h)})),Y},[k,p,y,n,K,x,g,r,v,o,h]);G.useEffect(()=>()=>{j.current&&clearTimeout(j.current),$.current&&clearTimeout($.current)},[]);const X=G.useCallback((ee={},se=null)=>({...ee,id:w,ref:Xt(se,Y=>{L(!!Y)})}),[w]),Q=G.useCallback((ee={},se=null)=>({...ee,id:_,ref:Xt(se,Y=>{z(!!Y)})}),[_]);return{forceUpdate:U,isOpen:p,onAnimationComplete:H.onComplete,onClose:v,getAnchorProps:M,getArrowProps:A,getArrowInnerProps:N,getPopoverPositionerProps:q,getPopoverProps:D,getTriggerProps:J,getHeaderProps:X,getBodyProps:Q}}function vc(t,r){return t===r||t?.contains(r)}function km(t){var r;const e=t.currentTarget.ownerDocument.activeElement;return(r=t.relatedTarget)!=null?r:e}function AR(t){const r=or("Popover",t),{children:e,...a}=Dt(t),f=ri(),c=ER({...a,direction:f.direction});return W.jsx(SR,{value:c,children:W.jsx(kR,{value:r,children:Xr(e,{isOpen:c.isOpen,onClose:c.onClose,forceUpdate:c.forceUpdate})})})}AR.displayName="Popover";var yc=(t,r)=>r?`${t}.${r}, ${r}`:void 0;function MR(t){var r;const{bg:e,bgColor:a,backgroundColor:f,shadow:c,boxShadow:s,shadowColor:l}=t,{getArrowProps:i,getArrowInnerProps:n}=Oi(),o=Ho(),h=(r=e??a)!=null?r:f,u=c??s;return W.jsx(xe.div,{...i(),className:"chakra-popover__arrow-positioner",children:W.jsx(xe.div,{className:Fe("chakra-popover__arrow",t.className),...n(t),__css:{"--popper-arrow-shadow-color":yc("colors",l),"--popper-arrow-bg":yc("colors",h),"--popper-arrow-shadow":yc("shadows",u),...o.arrow}})})}MR.displayName="PopoverArrow";var jR=Se(function(r,e){const{getBodyProps:a}=Oi(),f=Ho();return W.jsx(xe.div,{...a(r,e),className:Fe("chakra-popover__body",r.className),__css:f.body})});jR.displayName="PopoverBody";var PR=Se(function(r,e){const{onClose:a}=Oi(),f=Ho();return W.jsx(pl,{size:"sm",onClick:a,className:Fe("chakra-popover__close-btn",r.className),__css:f.closeButton,ref:e,...r})});PR.displayName="PopoverCloseButton";function RR(t){if(t)return{enter:{...t.enter,visibility:"visible"},exit:{...t.exit,transitionEnd:{visibility:"hidden"}}}}var IR={exit:{opacity:0,scale:.95,transition:{duration:.1,ease:[.4,0,1,1]}},enter:{scale:1,opacity:1,transition:{duration:.15,ease:[0,0,.2,1]}}},OR=xe(on.section),Jg=Se(function(r,e){const{variants:a=IR,...f}=r,{isOpen:c}=Oi();return W.jsx(OR,{ref:e,variants:RR(a),initial:!1,animate:c?"enter":"exit",...f})});Jg.displayName="PopoverTransition";var NR=Se(function(r,e){const{rootProps:a,motionProps:f,...c}=r,{getPopoverProps:s,getPopoverPositionerProps:l,onAnimationComplete:i}=Oi(),n=Ho(),o={position:"relative",display:"flex",flexDirection:"column",...n.content};return W.jsx(xe.div,{...l(a),__css:n.popper,className:"chakra-popover__popper",children:W.jsx(Jg,{...f,...s(c,e),onAnimationComplete:Ru(i,c.onAnimationComplete),className:Fe("chakra-popover__content",r.className),__css:o})})});NR.displayName="PopoverContent";function DR(t,r,e){return(t-r)*100/(e-r)}Ri({"0%":{strokeDasharray:"1, 400",strokeDashoffset:"0"},"50%":{strokeDasharray:"400, 400",strokeDashoffset:"-100"},"100%":{strokeDasharray:"400, 400",strokeDashoffset:"-260"}});Ri({"0%":{transform:"rotate(0deg)"},"100%":{transform:"rotate(360deg)"}});var FR=Ri({"0%":{left:"-40%"},"100%":{left:"100%"}}),BR=Ri({from:{backgroundPosition:"1rem 0"},to:{backgroundPosition:"0 0"}});function LR(t){const{value:r=0,min:e,max:a,valueText:f,getValueText:c,isIndeterminate:s,role:l="progressbar"}=t,i=DR(r,e,a);return{bind:{"data-indeterminate":s?"":void 0,"aria-valuemax":a,"aria-valuemin":e,"aria-valuenow":s?void 0:r,"aria-valuetext":(()=>{if(r!=null)return typeof c=="function"?c(r,i):f})(),role:l},percent:i,value:r}}var[$R,zR]=It({name:"ProgressStylesContext",errorMessage:`useProgressStyles returned is 'undefined'. Seems you forgot to wrap the components in "<Progress />" `}),VR=Se((t,r)=>{const{min:e,max:a,value:f,isIndeterminate:c,role:s,...l}=t,i=LR({value:f,min:e,max:a,isIndeterminate:c,role:s}),o={height:"100%",...zR().filledTrack};return W.jsx(xe.div,{ref:r,style:{width:`${i.percent}%`,...l.style},...i.bind,...l,__css:o})}),Qg=Se((t,r)=>{var e;const{value:a,min:f=0,max:c=100,hasStripe:s,isAnimated:l,children:i,borderRadius:n,isIndeterminate:o,"aria-label":h,"aria-labelledby":u,"aria-valuetext":d,title:m,role:b,...p}=Dt(t),v=or("Progress",t),g=n??((e=v.track)==null?void 0:e.borderRadius),x={animation:`${BR} 1s linear infinite`},R={...!o&&s&&l&&x,...o&&{position:"absolute",willChange:"left",minWidth:"50%",animation:`${FR} 1s ease infinite normal none running`}},B={overflow:"hidden",position:"relative",...v.track};return W.jsx(xe.div,{ref:r,borderRadius:g,__css:B,...p,children:W.jsxs($R,{value:v,children:[W.jsx(VR,{"aria-label":h,"aria-labelledby":u,"aria-valuetext":d,min:f,max:c,value:a,isIndeterminate:o,css:R,borderRadius:g,title:m,role:b}),i]})})});Qg.displayName="Progress";function UR(t){return t&&kr(t)&&kr(t.target)}function WR(t={}){const{onChange:r,value:e,defaultValue:a,name:f,isDisabled:c,isFocusable:s,isNative:l,...i}=t,[n,o]=G.useState(a||""),h=typeof e<"u",u=h?e:n,d=G.useRef(null),m=G.useCallback(()=>{const T=d.current;if(!T)return;let R="input:not(:disabled):checked";const B=T.querySelector(R);if(B){B.focus();return}R="input:not(:disabled)";const I=T.querySelector(R);I?.focus()},[]),p=`radio-${G.useId()}`,v=f||p,g=G.useCallback(T=>{const R=UR(T)?T.target.value:T;h||o(R),r?.(String(R))},[r,h]),x=G.useCallback((T={},R=null)=>({...T,ref:Xt(R,d),role:"radiogroup"}),[]),C=G.useCallback((T={},R=null)=>({...T,ref:R,name:v,[l?"checked":"isChecked"]:u!=null?T.value===u:void 0,onChange(I){g(I)},"data-radiogroup":!0}),[l,v,g,u]);return{getRootProps:x,getRadioProps:C,name:v,ref:d,focus:m,setValue:o,value:u,onChange:g,isDisabled:c,isFocusable:s,htmlProps:i}}var[HR,ev]=It({name:"RadioGroupContext",strict:!1}),qR=Se((t,r)=>{const{colorScheme:e,size:a,variant:f,children:c,className:s,isDisabled:l,isFocusable:i,...n}=t,{value:o,onChange:h,getRootProps:u,name:d,htmlProps:m}=WR(n),b=G.useMemo(()=>({name:d,size:a,onChange:h,colorScheme:e,value:o,variant:f,isDisabled:l,isFocusable:i}),[d,a,h,e,o,f,l,i]);return W.jsx(HR,{value:b,children:W.jsx(xe.div,{...u(m,r),className:Fe("chakra-radio-group",s),children:c})})});qR.displayName="RadioGroup";var XR={border:"0",clip:"rect(0, 0, 0, 0)",height:"1px",width:"1px",margin:"-1px",padding:"0",overflow:"hidden",whiteSpace:"nowrap",position:"absolute"};function KR(t={}){const{defaultChecked:r,isChecked:e,isFocusable:a,isDisabled:f,isReadOnly:c,isRequired:s,onChange:l,isInvalid:i,name:n,value:o,id:h,"data-radiogroup":u,"aria-describedby":d,...m}=t,b=`radio-${G.useId()}`,p=Lo(),g=!!ev()||!!u;let C=!!p&&!g?p.id:b;C=h??C;const T=f??p?.isDisabled,R=c??p?.isReadOnly,B=s??p?.isRequired,I=i??p?.isInvalid,[F,L]=G.useState(!1),[V,z]=G.useState(!1),[E,P]=G.useState(!1),[k,y]=G.useState(!1),[w,_]=G.useState(!!r),S=typeof e<"u",A=S?e:w;G.useEffect(()=>cE(L),[]);const O=G.useCallback(K=>{if(R||T){K.preventDefault();return}S||_(K.target.checked),l?.(K)},[S,T,R,l]),N=G.useCallback(K=>{K.key===" "&&y(!0)},[y]),U=G.useCallback(K=>{K.key===" "&&y(!1)},[y]),H=G.useCallback((K={},J=null)=>({...K,ref:J,"data-active":Bt(k),"data-hover":Bt(E),"data-disabled":Bt(T),"data-invalid":Bt(I),"data-checked":Bt(A),"data-focus":Bt(V),"data-focus-visible":Bt(V&&F),"data-readonly":Bt(R),"aria-hidden":!0,onMouseDown:Qe(K.onMouseDown,()=>y(!0)),onMouseUp:Qe(K.onMouseUp,()=>y(!1)),onMouseEnter:Qe(K.onMouseEnter,()=>P(!0)),onMouseLeave:Qe(K.onMouseLeave,()=>P(!1))}),[k,E,T,I,A,V,R,F]),{onFocus:Z,onBlur:D}=p??{},q=G.useCallback((K={},J=null)=>{const X=T&&!a;return{...K,id:C,ref:J,type:"radio",name:n,value:o,onChange:Qe(K.onChange,O),onBlur:Qe(D,K.onBlur,()=>z(!1)),onFocus:Qe(Z,K.onFocus,()=>z(!0)),onKeyDown:Qe(K.onKeyDown,N),onKeyUp:Qe(K.onKeyUp,U),checked:A,disabled:X,readOnly:R,required:B,"aria-invalid":On(I),"aria-disabled":On(X),"aria-required":On(B),"data-readonly":Bt(R),"aria-describedby":d,style:XR}},[T,a,C,n,o,O,D,Z,N,U,A,R,B,I,d]);return{state:{isInvalid:I,isFocused:V,isChecked:A,isActive:k,isHovered:E,isDisabled:T,isReadOnly:R,isRequired:B},getCheckboxProps:H,getRadioProps:H,getInputProps:q,getLabelProps:(K={},J=null)=>({...K,ref:J,onMouseDown:Qe(K.onMouseDown,GR),"data-disabled":Bt(T),"data-checked":Bt(A),"data-invalid":Bt(I)}),getRootProps:(K,J=null)=>({...K,ref:J,"data-disabled":Bt(T),"data-checked":Bt(A),"data-invalid":Bt(I)}),htmlProps:m}}function GR(t){t.preventDefault(),t.stopPropagation()}function YR(t,r){const e={},a={};for(const[f,c]of Object.entries(t))r.includes(f)?e[f]=c:a[f]=c;return[e,a]}var ZR=Se((t,r)=>{var e;const a=ev(),{onChange:f,value:c}=t,s=or("Radio",{...a,...t}),l=Dt(t),{spacing:i="0.5rem",children:n,isDisabled:o=a?.isDisabled,isFocusable:h=a?.isFocusable,inputProps:u,...d}=l;let m=t.isChecked;a?.value!=null&&c!=null&&(m=a.value===c);let b=f;a?.onChange&&c!=null&&(b=Ru(a.onChange,f));const p=(e=t?.name)!=null?e:a?.name,{getInputProps:v,getCheckboxProps:g,getLabelProps:x,getRootProps:C,htmlProps:T}=KR({...d,isChecked:m,isFocusable:h,isDisabled:o,onChange:b,name:p}),[R,B]=YR(T,i0),I=g(B),F=v(u,r),L=x(),V=Object.assign({},R,C()),z={display:"inline-flex",alignItems:"center",verticalAlign:"top",cursor:"pointer",position:"relative",...s.container},E={display:"inline-flex",alignItems:"center",justifyContent:"center",flexShrink:0,...s.control},P={userSelect:"none",marginStart:i,...s.label};return W.jsxs(xe.label,{className:"chakra-radio",...V,__css:z,children:[W.jsx("input",{className:"chakra-radio__input",...F}),W.jsx(xe.span,{className:"chakra-radio__control",...I,__css:E}),n&&W.jsx(xe.span,{className:"chakra-radio__label",...L,__css:P,children:n})]})});ZR.displayName="Radio";var tv=Se(function(r,e){const{children:a,placeholder:f,className:c,...s}=r;return W.jsxs(xe.select,{...s,ref:e,className:Fe("chakra-select",c),children:[f&&W.jsx("option",{value:"",children:f}),a]})});tv.displayName="SelectField";function JR(t,r){const e={},a={};for(const[f,c]of Object.entries(t))r.includes(f)?e[f]=c:a[f]=c;return[e,a]}var QR=Se((t,r)=>{var e;const a=or("Select",t),{rootProps:f,placeholder:c,icon:s,color:l,height:i,h:n,minH:o,minHeight:h,iconColor:u,iconSize:d,...m}=Dt(t),[b,p]=JR(m,i0),v=jd(p),g={width:"100%",height:"fit-content",position:"relative",color:l},x={paddingEnd:"2rem",...a.field,_focus:{zIndex:"unset",...(e=a.field)==null?void 0:e._focus}};return W.jsxs(xe.div,{className:"chakra-select__wrapper",__css:g,...b,...f,children:[W.jsx(tv,{ref:r,height:n??i,minH:o??h,placeholder:c,...v,__css:x,children:t.children}),W.jsx(rv,{"data-disabled":Bt(v.disabled),...(u||l)&&{color:u||l},__css:a.icon,...d&&{fontSize:d},children:s})]})});QR.displayName="Select";var eI=t=>W.jsx("svg",{viewBox:"0 0 24 24",...t,children:W.jsx("path",{fill:"currentColor",d:"M16.59 8.59L12 13.17 7.41 8.59 6 10l6 6 6-6z"})}),tI=xe("div",{baseStyle:{position:"absolute",display:"inline-flex",alignItems:"center",justifyContent:"center",pointerEvents:"none",top:"50%",transform:"translateY(-50%)"}}),rv=t=>{const{children:r=W.jsx(eI,{}),...e}=t,a=G.cloneElement(r,{role:"presentation",className:"chakra-select__icon",focusable:!1,"aria-hidden":!0,style:{width:"1em",height:"1em",color:"currentColor"}});return W.jsx(tI,{...e,className:"chakra-select__icon-wrapper",children:G.isValidElement(r)?a:null})};rv.displayName="SelectIcon";function rI(){const t=G.useRef(!0);return G.useEffect(()=>{t.current=!1},[]),t.current}function nI(t){const r=G.useRef();return G.useEffect(()=>{r.current=t},[t]),r.current}var iI=xe("div",{baseStyle:{boxShadow:"none",backgroundClip:"padding-box",cursor:"default",color:"transparent",pointerEvents:"none",userSelect:"none","&::before, &::after, *":{visibility:"hidden"}}}),wu=Ze("skeleton-start-color"),xu=Ze("skeleton-end-color"),sI=Ri({from:{opacity:0},to:{opacity:1}}),oI=Ri({from:{borderColor:wu.reference,background:wu.reference},to:{borderColor:xu.reference,background:xu.reference}}),aI=Se((t,r)=>{const e={...t,fadeDuration:typeof t.fadeDuration=="number"?t.fadeDuration:.4,speed:typeof t.speed=="number"?t.speed:.8},a=$r("Skeleton",e),f=rI(),{startColor:c="",endColor:s="",isLoaded:l,fadeDuration:i,speed:n,className:o,fitContent:h,...u}=Dt(e),[d,m]=Oy("colors",[c,s]),b=nI(l),p=Fe("chakra-skeleton",o),v={...d&&{[wu.variable]:d},...m&&{[xu.variable]:m}};if(l){const g=f||b?"none":`${sI} ${i}s`;return W.jsx(xe.div,{ref:r,className:p,__css:{animation:g},...u})}return W.jsx(iI,{ref:r,className:p,...u,__css:{width:h?"fit-content":void 0,...a,...v,_dark:{...a._dark,...v},animation:`${n}s linear infinite alternate ${oI}`}})});aI.displayName="Skeleton";var[lI,nv]=It({name:"StatStylesContext",errorMessage:`useStatStyles returned is 'undefined'. Seems you forgot to wrap the components in "<Stat />" `}),cI=Se(function(r,e){const a=or("Stat",r),f={position:"relative",flex:"1 1 0%",...a.container},{className:c,children:s,...l}=Dt(r);return W.jsx(lI,{value:a,children:W.jsx(xe.div,{ref:e,...l,className:Fe("chakra-stat",c),__css:f,children:W.jsx("dl",{children:s})})})});cI.displayName="Stat";var uI=Se(function(r,e){const a=nv();return W.jsx(xe.dt,{ref:e,...r,className:Fe("chakra-stat__label",r.className),__css:a.label})});uI.displayName="StatLabel";var dI=Se(function(r,e){const a=nv();return W.jsx(xe.dd,{ref:e,...r,className:Fe("chakra-stat__number",r.className),__css:{...a.number,fontFeatureSettings:"pnum",fontVariantNumeric:"proportional-nums"}})});dI.displayName="StatNumber";var[fI,qo]=It({name:"TableStylesContext",errorMessage:`useTableStyles returned is 'undefined'. Seems you forgot to wrap the components in "<Table />" `}),_u=Se((t,r)=>{const e=or("Table",t),{className:a,layout:f,...c}=Dt(t);return W.jsx(fI,{value:e,children:W.jsx(xe.table,{ref:r,__css:{tableLayout:f,...e.table},className:Fe("chakra-table",a),...c})})});_u.displayName="Table";var Cm=Se((t,r)=>{const e=qo();return W.jsx(xe.thead,{...t,ref:r,__css:e.thead})}),Er=Se((t,r)=>{const e=qo();return W.jsx(xe.tr,{...t,ref:r,__css:e.tr})}),Tm=Se((t,r)=>{const e=qo();return W.jsx(xe.tbody,{...t,ref:r,__css:e.tbody})}),lt=Se(({isNumeric:t,...r},e)=>{const a=qo();return W.jsx(xe.td,{...r,ref:e,__css:a.td,"data-is-numeric":t})}),Ur=Se(({isNumeric:t,...r},e)=>{const a=qo();return W.jsx(xe.th,{...r,ref:e,__css:a.th,"data-is-numeric":t})}),[hI,pI,mI,bI]=Ed();function gI(t){var r;const{defaultIndex:e,onChange:a,index:f,isManual:c,isLazy:s,lazyBehavior:l="unmount",orientation:i="horizontal",direction:n="ltr",...o}=t,[h,u]=G.useState(e??0),[d,m]=cb({defaultValue:e??0,value:f,onChange:a});G.useEffect(()=>{f!=null&&u(f)},[f]);const b=mI(),p=G.useId();return{id:`tabs-${(r=t.id)!=null?r:p}`,selectedIndex:d,focusedIndex:h,setSelectedIndex:m,setFocusedIndex:u,isManual:c,isLazy:s,lazyBehavior:l,orientation:i,descendants:b,direction:n,htmlProps:o}}var[vI,_l]=It({name:"TabsContext",errorMessage:"useTabsContext: `context` is undefined. Seems you forgot to wrap all tabs components within <Tabs />"});function yI(t){const{focusedIndex:r,orientation:e,direction:a}=_l(),f=pI(),c=G.useCallback(s=>{const l=()=>{var g;const x=f.nextEnabled(r);x&&((g=x.node)==null||g.focus())},i=()=>{var g;const x=f.prevEnabled(r);x&&((g=x.node)==null||g.focus())},n=()=>{var g;const x=f.firstEnabled();x&&((g=x.node)==null||g.focus())},o=()=>{var g;const x=f.lastEnabled();x&&((g=x.node)==null||g.focus())},h=e==="horizontal",u=e==="vertical",d=s.key,m=a==="ltr"?"ArrowLeft":"ArrowRight",b=a==="ltr"?"ArrowRight":"ArrowLeft",v={[m]:()=>h&&i(),[b]:()=>h&&l(),ArrowDown:()=>u&&l(),ArrowUp:()=>u&&i(),Home:n,End:o}[d];v&&(s.preventDefault(),v(s))},[f,r,e,a]);return{...t,role:"tablist","aria-orientation":e,onKeyDown:Qe(t.onKeyDown,c)}}function wI(t){const{isDisabled:r=!1,isFocusable:e=!1,...a}=t,{setSelectedIndex:f,isManual:c,id:s,setFocusedIndex:l,selectedIndex:i}=_l(),{index:n,register:o}=bI({disabled:r&&!e}),h=n===i,u=()=>{f(n)},d=()=>{l(n),!c&&!(r&&e)&&f(n)};return{...xg({...a,ref:Xt(o,t.ref),isDisabled:r,isFocusable:e,onClick:Qe(t.onClick,u)}),id:iv(s,n),role:"tab",tabIndex:h?0:-1,type:"button","aria-selected":h,"aria-controls":sv(s,n),onFocus:r?void 0:Qe(t.onFocus,d)}}var[xI,_I]=It({});function SI(t){const r=_l(),{id:e,selectedIndex:a}=r,c=bl(t.children).map((s,l)=>G.createElement(xI,{key:l,value:{isSelected:l===a,id:sv(e,l),tabId:iv(e,l),selectedIndex:a}},s));return{...t,children:c}}function kI(t){const{children:r,...e}=t,{isLazy:a,lazyBehavior:f}=_l(),{isSelected:c,id:s,tabId:l}=_I(),i=G.useRef(!1);c&&(i.current=!0);const n=nf({wasSelected:i.current,isSelected:c,enabled:a,mode:f});return{tabIndex:0,...e,children:n?r:null,role:"tabpanel","aria-labelledby":l,hidden:!c,id:s}}function iv(t,r){return`${t}--tab-${r}`}function sv(t,r){return`${t}--tabpanel-${r}`}var[CI,Sl]=It({name:"TabsStylesContext",errorMessage:`useTabsStyles returned is 'undefined'. Seems you forgot to wrap the components in "<Tabs />" `}),ov=Se(function(r,e){const a=or("Tabs",r),{children:f,className:c,...s}=Dt(r),{htmlProps:l,descendants:i,...n}=gI(s),o=G.useMemo(()=>n,[n]),{isFitted:h,...u}=l,d={position:"relative",...a.root};return W.jsx(hI,{value:i,children:W.jsx(vI,{value:o,children:W.jsx(CI,{value:a,children:W.jsx(xe.div,{className:Fe("chakra-tabs",c),ref:e,...u,__css:d,children:f})})})})});ov.displayName="Tabs";var av=Se(function(r,e){const a=yI({...r,ref:e}),c={display:"flex",...Sl().tablist};return W.jsx(xe.div,{...a,className:Fe("chakra-tabs__tablist",r.className),__css:c})});av.displayName="TabList";var Na=Se(function(r,e){const a=kI({...r,ref:e}),f=Sl();return W.jsx(xe.div,{outline:"0",...a,className:Fe("chakra-tabs__tab-panel",r.className),__css:f.tabpanel})});Na.displayName="TabPanel";var lv=Se(function(r,e){const a=SI(r),f=Sl();return W.jsx(xe.div,{...a,width:"100%",ref:e,className:Fe("chakra-tabs__tab-panels",r.className),__css:f.tabpanels})});lv.displayName="TabPanels";var Da=Se(function(r,e){const a=Sl(),f=wI({...r,ref:e}),c={outline:"0",display:"flex",alignItems:"center",justifyContent:"center",...a.tab};return W.jsx(xe.button,{...f,className:Fe("chakra-tabs__tab",r.className),__css:c})});Da.displayName="Tab";var[TI,cv]=It({name:"TagStylesContext",errorMessage:`useTagStyles returned is 'undefined'. Seems you forgot to wrap the components in "<Tag />" `}),EI=Se((t,r)=>{const e=or("Tag",t),a=Dt(t),f={display:"inline-flex",verticalAlign:"top",alignItems:"center",maxWidth:"100%",...e.container};return W.jsx(TI,{value:e,children:W.jsx(xe.span,{ref:r,...a,__css:f})})});EI.displayName="Tag";var AI=Se((t,r)=>{const e=cv();return W.jsx(xe.span,{ref:r,noOfLines:1,...t,__css:e.label})});AI.displayName="TagLabel";var MI=Se((t,r)=>W.jsx(Tr,{ref:r,verticalAlign:"top",marginEnd:"0.5rem",...t}));MI.displayName="TagLeftIcon";var jI=Se((t,r)=>W.jsx(Tr,{ref:r,verticalAlign:"top",marginStart:"0.5rem",...t}));jI.displayName="TagRightIcon";var uv=t=>W.jsx(Tr,{verticalAlign:"inherit",viewBox:"0 0 512 512",...t,children:W.jsx("path",{fill:"currentColor",d:"M289.94 256l95-95A24 24 0 00351 127l-95 95-95-95a24 24 0 00-34 34l95 95-95 95a24 24 0 1034 34l95-95 95 95a24 24 0 0034-34z"})});uv.displayName="TagCloseIcon";var PI=Se((t,r)=>{const{isDisabled:e,children:a,...f}=t,s={display:"flex",alignItems:"center",justifyContent:"center",outline:"0",...cv().closeButton};return W.jsx(xe.button,{ref:r,"aria-label":"close",...f,type:"button",disabled:e,__css:s,children:a||W.jsx(uv,{})})});PI.displayName="TagCloseButton";function RI(t,r=[]){const e=Object.assign({},t);for(const a of r)a in e&&delete e[a];return e}var II=["h","minH","height","minHeight"],OI=Se((t,r)=>{const e=$r("Textarea",t),{className:a,rows:f,...c}=Dt(t),s=jd(c),l=f?RI(e,II):e;return W.jsx(xe.textarea,{ref:r,rows:f,...s,className:Fe("chakra-textarea",a),__css:l})});OI.displayName="Textarea";var NI={exit:{scale:.85,opacity:0,transition:{opacity:{duration:.15,easings:"easeInOut"},scale:{duration:.2,easings:"easeInOut"}}},enter:{scale:1,opacity:1,transition:{opacity:{easings:"easeOut",duration:.2},scale:{duration:.2,ease:[.175,.885,.4,1.1]}}}},Su=t=>{var r;return((r=t.current)==null?void 0:r.ownerDocument)||document},Fa=t=>{var r,e;return((e=(r=t.current)==null?void 0:r.ownerDocument)==null?void 0:e.defaultView)||window};function DI(t={}){const{openDelay:r=0,closeDelay:e=0,closeOnClick:a=!0,closeOnMouseDown:f,closeOnScroll:c,closeOnPointerDown:s=f,closeOnEsc:l=!0,onOpen:i,onClose:n,placement:o,id:h,isOpen:u,defaultIsOpen:d,arrowSize:m=10,arrowShadowColor:b,arrowPadding:p,modifiers:v,isDisabled:g,gutter:x,offset:C,direction:T,...R}=t,{isOpen:B,onOpen:I,onClose:F}=rf({isOpen:u,defaultIsOpen:d,onOpen:i,onClose:n}),{referenceRef:L,getPopperProps:V,getArrowInnerProps:z,getArrowProps:E}=tf({enabled:B,placement:o,arrowPadding:p,modifiers:v,gutter:x,offset:C,direction:T}),P=G.useId(),y=`tooltip-${h??P}`,w=G.useRef(null),_=G.useRef(),S=G.useCallback(()=>{_.current&&(clearTimeout(_.current),_.current=void 0)},[]),A=G.useRef(),O=G.useCallback(()=>{A.current&&(clearTimeout(A.current),A.current=void 0)},[]),N=G.useCallback(()=>{O(),F()},[F,O]),U=FI(w,N),H=G.useCallback(()=>{if(!g&&!_.current){B&&U();const J=Fa(w);_.current=J.setTimeout(I,r)}},[U,g,B,I,r]),Z=G.useCallback(()=>{S();const J=Fa(w);A.current=J.setTimeout(N,e)},[e,N,S]),D=G.useCallback(()=>{B&&a&&Z()},[a,Z,B]),q=G.useCallback(()=>{B&&s&&Z()},[s,Z,B]),M=G.useCallback(J=>{B&&J.key==="Escape"&&Z()},[B,Z]);Si(()=>Su(w),"keydown",l?M:void 0),Si(()=>{if(!c)return null;const J=w.current;if(!J)return null;const X=sg(J);return X.localName==="body"?Fa(w):X},"scroll",()=>{B&&c&&N()},{passive:!0,capture:!0}),G.useEffect(()=>{g&&(S(),B&&F())},[g,B,F,S]),G.useEffect(()=>()=>{S(),O()},[S,O]),Si(()=>w.current,"pointerleave",Z);const j=G.useCallback((J={},X=null)=>({...J,ref:Xt(w,X,L),onPointerEnter:Qe(J.onPointerEnter,ee=>{ee.pointerType!=="touch"&&H()}),onClick:Qe(J.onClick,D),onPointerDown:Qe(J.onPointerDown,q),onFocus:Qe(J.onFocus,H),onBlur:Qe(J.onBlur,Z),"aria-describedby":B?y:void 0}),[H,Z,q,B,y,D,L]),$=G.useCallback((J={},X=null)=>V({...J,style:{...J.style,[ir.arrowSize.var]:m?`${m}px`:void 0,[ir.arrowShadowColor.var]:b}},X),[V,m,b]),K=G.useCallback((J={},X=null)=>{const Q={...J.style,position:"relative",transformOrigin:ir.transformOrigin.varRef};return{ref:X,...R,...J,id:y,role:"tooltip",style:Q}},[R,y]);return{isOpen:B,show:H,hide:Z,getTriggerProps:j,getTooltipProps:K,getTooltipPositionerProps:$,getArrowProps:E,getArrowInnerProps:z}}var wc="chakra-ui:close-tooltip";function FI(t,r){return G.useEffect(()=>{const e=Su(t);return e.addEventListener(wc,r),()=>e.removeEventListener(wc,r)},[r,t]),()=>{const e=Su(t),a=Fa(t);e.dispatchEvent(new a.CustomEvent(wc))}}function BI(t,r=[]){const e=Object.assign({},t);for(const a of r)a in e&&delete e[a];return e}function LI(t,r){const e={};for(const a of r)a in t&&(e[a]=t[a]);return e}var $I=xe(on.div),zI=Se((t,r)=>{var e,a;const f=$r("Tooltip",t),c=Dt(t),s=ri(),{children:l,label:i,shouldWrapChildren:n,"aria-label":o,hasArrow:h,bg:u,portalProps:d,background:m,backgroundColor:b,bgColor:p,motionProps:v,...g}=c,x=(a=(e=m??b)!=null?e:u)!=null?a:p;if(x){f.bg=x;const V=Qw(s,"colors",x);f[ir.arrowBg.var]=V}const C=DI({...g,direction:s.direction}),T=typeof l=="string"||n;let R;if(T)R=W.jsx(xe.span,{display:"inline-block",tabIndex:0,...C.getTriggerProps(),children:l});else{const V=G.Children.only(l);R=G.cloneElement(V,C.getTriggerProps(V.props,V.ref))}const B=!!o,I=C.getTooltipProps({},r),F=B?BI(I,["role","id"]):I,L=LI(I,["role","id"]);return i?W.jsxs(W.Fragment,{children:[R,W.jsx(Ii,{children:C.isOpen&&W.jsx(xs,{...d,children:W.jsx(xe.div,{...C.getTooltipPositionerProps(),__css:{zIndex:f.zIndex,pointerEvents:"none"},children:W.jsxs($I,{variants:NI,initial:"exit",animate:"enter",exit:"exit",...v,...F,__css:f,children:[i,B&&W.jsx(xe.span,{srOnly:!0,...L,children:o}),h&&W.jsx(xe.div,{"data-popper-arrow":!0,className:"chakra-tooltip__arrow-wrapper",children:W.jsx(xe.div,{"data-popper-arrow-inner":!0,className:"chakra-tooltip__arrow",__css:{bg:f.bg}})})]})})})})]}):W.jsx(W.Fragment,{children:l})});zI.displayName="Tooltip";const dv="https://xsztxkukcbfiqsvxkjpf.supabase.co".startsWith("http")?"https://xsztxkukcbfiqsvxkjpf.supabase.co":"https://https://xsztxkukcbfiqsvxkjpf.supabase.co",VI="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InhzenR4a3VrY2JmaXFzdnhranBmIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NDMyNDc1MjEsImV4cCI6MjA1ODgyMzUyMX0.T1gabS-2qvkwoBpT6bOwBxL1GHvqW2R8vD0QKqSgigQ";if(!dv)throw console.error("Missing Supabase environment variables"),new Error("Missing Supabase environment variables. Please check your .env file.");const rn=_v(dv,VI,{auth:{autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0}});var CO=ar({displayName:"ViewOffIcon",path:W.jsxs("g",{fill:"currentColor",children:[W.jsx("path",{d:"M23.2,10.549a20.954,20.954,0,0,0-4.3-3.6l4-3.995a1,1,0,1,0-1.414-1.414l-.018.018a.737.737,0,0,1-.173.291l-19.5,19.5c-.008.007-.018.009-.026.017a1,1,0,0,0,1.631,1.088l4.146-4.146a11.26,11.26,0,0,0,4.31.939h.3c4.256,0,8.489-2.984,11.051-5.8A2.171,2.171,0,0,0,23.2,10.549ZM16.313,13.27a4.581,4.581,0,0,1-3,3.028,4.3,4.3,0,0,1-3.1-.19.253.253,0,0,1-.068-.407l5.56-5.559a.252.252,0,0,1,.407.067A4.3,4.3,0,0,1,16.313,13.27Z"}),W.jsx("path",{d:"M7.615,13.4a.244.244,0,0,0,.061-.24A4.315,4.315,0,0,1,7.5,12,4.5,4.5,0,0,1,12,7.5a4.276,4.276,0,0,1,1.16.173.244.244,0,0,0,.24-.062l1.941-1.942a.254.254,0,0,0-.1-.421A10.413,10.413,0,0,0,12,4.75C7.7,4.692,3.4,7.7.813,10.549a2.15,2.15,0,0,0-.007,2.9,21.209,21.209,0,0,0,3.438,3.03.256.256,0,0,0,.326-.029Z"})]})}),pa=ar({d:"M11.983,0a12.206,12.206,0,0,0-8.51,3.653A11.8,11.8,0,0,0,0,12.207,11.779,11.779,0,0,0,11.8,24h.214A12.111,12.111,0,0,0,24,11.791h0A11.766,11.766,0,0,0,11.983,0ZM10.5,16.542a1.476,1.476,0,0,1,1.449-1.53h.027a1.527,1.527,0,0,1,1.523,1.47,1.475,1.475,0,0,1-1.449,1.53h-.027A1.529,1.529,0,0,1,10.5,16.542ZM11,12.5v-6a1,1,0,0,1,2,0v6a1,1,0,1,1-2,0Z",displayName:"WarningIcon"}),TO=ar({d:"M23.555,8.729a1.505,1.505,0,0,0-1.406-.98H16.062a.5.5,0,0,1-.472-.334L13.405,1.222a1.5,1.5,0,0,0-2.81,0l-.005.016L8.41,7.415a.5.5,0,0,1-.471.334H1.85A1.5,1.5,0,0,0,.887,10.4l5.184,4.3a.5.5,0,0,1,.155.543L4.048,21.774a1.5,1.5,0,0,0,2.31,1.684l5.346-3.92a.5.5,0,0,1,.591,0l5.344,3.919a1.5,1.5,0,0,0,2.312-1.683l-2.178-6.535a.5.5,0,0,1,.155-.543l5.194-4.306A1.5,1.5,0,0,0,23.555,8.729Z",displayName:"StarIcon"}),EO=ar({displayName:"TimeIcon",path:W.jsxs("g",{fill:"currentColor",children:[W.jsx("path",{d:"M12,0A12,12,0,1,0,24,12,12.014,12.014,0,0,0,12,0Zm0,22A10,10,0,1,1,22,12,10.011,10.011,0,0,1,12,22Z"}),W.jsx("path",{d:"M17.134,15.81,12.5,11.561V6.5a1,1,0,0,0-2,0V12a1,1,0,0,0,.324.738l4.959,4.545a1.01,1.01,0,0,0,1.413-.061A1,1,0,0,0,17.134,15.81Z"})]})}),UI=ar({displayName:"ViewIcon",path:W.jsxs("g",{fill:"currentColor",children:[W.jsx("path",{d:"M23.432,10.524C20.787,7.614,16.4,4.538,12,4.6,7.6,4.537,3.213,7.615.568,10.524a2.211,2.211,0,0,0,0,2.948C3.182,16.351,7.507,19.4,11.839,19.4h.308c4.347,0,8.671-3.049,11.288-5.929A2.21,2.21,0,0,0,23.432,10.524ZM7.4,12A4.6,4.6,0,1,1,12,16.6,4.6,4.6,0,0,1,7.4,12Z"}),W.jsx("circle",{cx:"12",cy:"12",r:"2"})]})}),fv=ar({displayName:"RepeatIcon",path:W.jsxs("g",{fill:"currentColor",children:[W.jsx("path",{d:"M10.319,4.936a7.239,7.239,0,0,1,7.1,2.252,1.25,1.25,0,1,0,1.872-1.657A9.737,9.737,0,0,0,9.743,2.5,10.269,10.269,0,0,0,2.378,9.61a.249.249,0,0,1-.271.178l-1.033-.13A.491.491,0,0,0,.6,9.877a.5.5,0,0,0-.019.526l2.476,4.342a.5.5,0,0,0,.373.248.43.43,0,0,0,.062,0,.5.5,0,0,0,.359-.152l3.477-3.593a.5.5,0,0,0-.3-.844L5.15,10.172a.25.25,0,0,1-.2-.333A7.7,7.7,0,0,1,10.319,4.936Z"}),W.jsx("path",{d:"M23.406,14.1a.5.5,0,0,0,.015-.526l-2.5-4.329A.5.5,0,0,0,20.546,9a.489.489,0,0,0-.421.151l-3.456,3.614a.5.5,0,0,0,.3.842l1.848.221a.249.249,0,0,1,.183.117.253.253,0,0,1,.023.216,7.688,7.688,0,0,1-5.369,4.9,7.243,7.243,0,0,1-7.1-2.253,1.25,1.25,0,1,0-1.872,1.656,9.74,9.74,0,0,0,9.549,3.03,10.261,10.261,0,0,0,7.369-7.12.251.251,0,0,1,.27-.179l1.058.127a.422.422,0,0,0,.06,0A.5.5,0,0,0,23.406,14.1Z"})]})}),AO=ar({d:"M23.384,21.619,16.855,15.09a9.284,9.284,0,1,0-1.768,1.768l6.529,6.529a1.266,1.266,0,0,0,1.768,0A1.251,1.251,0,0,0,23.384,21.619ZM2.75,9.5a6.75,6.75,0,1,1,6.75,6.75A6.758,6.758,0,0,1,2.75,9.5Z",displayName:"SearchIcon"}),WI=ar({viewBox:"0 0 14 14",d:"M14,7.77 L14,6.17 L12.06,5.53 L11.61,4.44 L12.49,2.6 L11.36,1.47 L9.55,2.38 L8.46,1.93 L7.77,0.01 L6.17,0.01 L5.54,1.95 L4.43,2.4 L2.59,1.52 L1.46,2.65 L2.37,4.46 L1.92,5.55 L0,6.23 L0,7.82 L1.94,8.46 L2.39,9.55 L1.51,11.39 L2.64,12.52 L4.45,11.61 L5.54,12.06 L6.23,13.98 L7.82,13.98 L8.45,12.04 L9.56,11.59 L11.4,12.47 L12.53,11.34 L11.61,9.53 L12.08,8.44 L14,7.75 L14,7.77 Z M7,10 C5.34,10 4,8.66 4,7 C4,5.34 5.34,4 7,4 C8.66,4 10,5.34 10,7 C10,8.66 8.66,10 7,10 Z",displayName:"SettingsIcon"}),MO=ar({displayName:"EditIcon",path:W.jsxs("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeWidth:"2",children:[W.jsx("path",{d:"M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7"}),W.jsx("path",{d:"M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z"})]})}),jO=ar({d:"M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z",displayName:"ChevronRightIcon"}),PO=ar({displayName:"CloseIcon",d:"M.439,21.44a1.5,1.5,0,0,0,2.122,2.121L11.823,14.3a.25.25,0,0,1,.354,0l9.262,9.263a1.5,1.5,0,1,0,2.122-2.121L14.3,12.177a.25.25,0,0,1,0-.354l9.263-9.262A1.5,1.5,0,0,0,21.439.44L12.177,9.7a.25.25,0,0,1-.354,0L2.561.44A1.5,1.5,0,0,0,.439,2.561L9.7,11.823a.25.25,0,0,1,0,.354Z"}),RO=ar({displayName:"DeleteIcon",path:W.jsx("g",{fill:"currentColor",children:W.jsx("path",{d:"M19.452 7.5H4.547a.5.5 0 00-.5.545l1.287 14.136A2 2 0 007.326 24h9.347a2 2 0 001.992-1.819L19.95 8.045a.5.5 0 00-.129-.382.5.5 0 00-.369-.163zm-9.2 13a.75.75 0 01-1.5 0v-9a.75.75 0 011.5 0zm5 0a.75.75 0 01-1.5 0v-9a.75.75 0 011.5 0zM22 4h-4.75a.25.25 0 01-.25-.25V2.5A2.5 2.5 0 0014.5 0h-5A2.5 2.5 0 007 2.5v1.25a.25.25 0 01-.25.25H2a1 1 0 000 2h20a1 1 0 000-2zM9 3.75V2.5a.5.5 0 01.5-.5h5a.5.5 0 01.5.5v1.25a.25.25 0 01-.25.25h-5.5A.25.25 0 019 3.75z"})})}),HI=ar({d:"M11.2857,6.05714 L10.08571,4.85714 L7.85714,7.14786 L7.85714,1 L6.14286,1 L6.14286,7.14786 L3.91429,4.85714 L2.71429,6.05714 L7,10.42857 L11.2857,6.05714 Z M1,11.2857 L1,13 L13,13 L13,11.2857 L1,11.2857 Z",displayName:"DownloadIcon",viewBox:"0 0 14 14"}),IO=ar({displayName:"CalendarIcon",viewBox:"0 0 14 14",d:"M10.8889,5.5 L3.11111,5.5 L3.11111,7.05556 L10.8889,7.05556 L10.8889,5.5 Z M12.4444,1.05556 L11.6667,1.05556 L11.6667,0 L10.1111,0 L10.1111,1.05556 L3.88889,1.05556 L3.88889,0 L2.33333,0 L2.33333,1.05556 L1.55556,1.05556 C0.692222,1.05556 0.00777777,1.75556 0.00777777,2.61111 L0,12.5 C0,13.3556 0.692222,14 1.55556,14 L12.4444,14 C13.3,14 14,13.3556 14,12.5 L14,2.61111 C14,1.75556 13.3,1.05556 12.4444,1.05556 Z M12.4444,12.5 L1.55556,12.5 L1.55556,3.94444 L12.4444,3.94444 L12.4444,12.5 Z M8.55556,8.61111 L3.11111,8.61111 L3.11111,10.1667 L8.55556,10.1667 L8.55556,8.61111 Z"}),qI=ar({d:"M0.913134,0.920639 C1.49851,0.331726 2.29348,0 3.12342,0 L10.8766,0 C11.7065,0 12.5015,0.331725 13.0869,0.920639 C13.6721,1.50939 14,2.30689 14,3.13746 L14,8.12943 C13.9962,8.51443 13.9059,8.97125 13.7629,9.32852 C13.6128,9.683 13.3552,10.0709 13.0869,10.3462 C12.813,10.6163 12.4265,10.8761 12.0734,11.0274 C11.7172,11.1716 11.2607,11.263 10.8766,11.2669 L10.1234,11.2669 L10.1234,12.5676 L10.1209,12.5676 C10.1204,12.793 10.0633,13.0791 9.97807,13.262 C9.8627,13.466 9.61158,13.7198 9.40818,13.8382 L9.40824,13.8383 C9.4077,13.8386 9.40716,13.8388 9.40661,13.8391 C9.40621,13.8393 9.4058,13.8396 9.40539,13.8398 L9.40535,13.8397 C9.22958,13.9254 8.94505,13.9951 8.75059,14 L8.74789,14 C8.35724,13.9963 7.98473,13.8383 7.71035,13.5617 L5.39553,11.2669 L3.12342,11.2669 C2.29348,11.2669 1.49851,10.9352 0.913134,10.3462 C0.644826,10.0709 0.387187,9.683 0.23711,9.32852 C0.0941235,8.97125 0.00379528,8.51443 0,8.12943 L0,3.13746 C0,2.30689 0.327915,1.50939 0.913134,0.920639 Z M3.12342,1.59494 C2.71959,1.59494 2.33133,1.75628 2.04431,2.04503 C1.75713,2.33395 1.59494,2.72681 1.59494,3.13746 L1.59494,8.12943 C1.59114,8.35901 1.62114,8.51076 1.71193,8.72129 C1.79563,8.9346 1.88065,9.06264 2.04431,9.22185 C2.33133,9.5106 2.71959,9.67195 3.12342,9.67195 L5.72383,9.67195 C5.93413,9.67195 6.13592,9.75502 6.28527,9.90308 L8.52848,12.1269 L8.52848,10.4694 C8.52848,10.029 8.88552,9.67195 9.32595,9.67195 L10.8766,9.67195 C11.1034,9.67583 11.2517,9.64614 11.4599,9.55518 C11.6712,9.47132 11.7976,9.38635 11.9557,9.22185 C12.1193,9.06264 12.2044,8.9346 12.2881,8.72129 C12.3789,8.51076 12.4089,8.35901 12.4051,8.12943 L12.4051,3.13746 C12.4051,2.72681 12.2429,2.33394 11.9557,2.04503 C11.6687,1.75628 11.2804,1.59494 10.8766,1.59494 L3.12342,1.59494 Z",displayName:"ChatIcon",viewBox:"0 0 14 14"}),OO=ar({viewBox:"0 0 14 14",path:W.jsx("g",{fill:"currentColor",children:W.jsx("polygon",{points:"5.5 11.9993304 14 3.49933039 12.5 2 5.5 8.99933039 1.5 4.9968652 0 6.49933039"})})}),ma=ar({displayName:"CheckCircleIcon",d:"M12,0A12,12,0,1,0,24,12,12.014,12.014,0,0,0,12,0Zm6.927,8.2-6.845,9.289a1.011,1.011,0,0,1-1.43.188L5.764,13.769a1,1,0,1,1,1.25-1.562l4.076,3.261,6.227-8.451A1,1,0,1,1,18.927,8.2Z"}),hv=ar({d:"M0,12a1.5,1.5,0,0,0,1.5,1.5h8.75a.25.25,0,0,1,.25.25V22.5a1.5,1.5,0,0,0,3,0V13.75a.25.25,0,0,1,.25-.25H22.5a1.5,1.5,0,0,0,0-3H13.75a.25.25,0,0,1-.25-.25V1.5a1.5,1.5,0,0,0-3,0v8.75a.25.25,0,0,1-.25.25H1.5A1.5,1.5,0,0,0,0,12Z",displayName:"AddIcon"}),NO=ar({d:"M20 11H7.83l5.59-5.59L12 4l-8 8 8 8 1.41-1.41L7.83 13H20v-2z",displayName:"ArrowBackIcon"}),pv={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},Em=cr.createContext&&cr.createContext(pv),XI=["attr","size","title"];function KI(t,r){if(t==null)return{};var e=GI(t,r),a,f;if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(t);for(f=0;f<c.length;f++)a=c[f],!(r.indexOf(a)>=0)&&Object.prototype.propertyIsEnumerable.call(t,a)&&(e[a]=t[a])}return e}function GI(t,r){if(t==null)return{};var e={};for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a)){if(r.indexOf(a)>=0)continue;e[a]=t[a]}return e}function Ja(){return Ja=Object.assign?Object.assign.bind():function(t){for(var r=1;r<arguments.length;r++){var e=arguments[r];for(var a in e)Object.prototype.hasOwnProperty.call(e,a)&&(t[a]=e[a])}return t},Ja.apply(this,arguments)}function Am(t,r){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);r&&(a=a.filter(function(f){return Object.getOwnPropertyDescriptor(t,f).enumerable})),e.push.apply(e,a)}return e}function Qa(t){for(var r=1;r<arguments.length;r++){var e=arguments[r]!=null?arguments[r]:{};r%2?Am(Object(e),!0).forEach(function(a){YI(t,a,e[a])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):Am(Object(e)).forEach(function(a){Object.defineProperty(t,a,Object.getOwnPropertyDescriptor(e,a))})}return t}function YI(t,r,e){return r=ZI(r),r in t?Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[r]=e,t}function ZI(t){var r=JI(t,"string");return typeof r=="symbol"?r:r+""}function JI(t,r){if(typeof t!="object"||!t)return t;var e=t[Symbol.toPrimitive];if(e!==void 0){var a=e.call(t,r);if(typeof a!="object")return a;throw new TypeError("@@toPrimitive must return a primitive value.")}return(r==="string"?String:Number)(t)}function mv(t){return t&&t.map((r,e)=>cr.createElement(r.tag,Qa({key:e},r.attr),mv(r.child)))}function Tn(t){return r=>cr.createElement(QI,Ja({attr:Qa({},t.attr)},r),mv(t.child))}function QI(t){var r=e=>{var{attr:a,size:f,title:c}=t,s=KI(t,XI),l=f||e.size||"1em",i;return e.className&&(i=e.className),t.className&&(i=(i?i+" ":"")+t.className),cr.createElement("svg",Ja({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},e.attr,a,s,{className:i,style:Qa(Qa({color:t.color||e.color},e.style),t.style),height:l,width:l,xmlns:"http://www.w3.org/2000/svg"}),c&&cr.createElement("title",null,c),t.children)};return Em!==void 0?cr.createElement(Em.Consumer,null,e=>r(e)):r(pv)}function DO(t){return Tn({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M224 512c35.32 0 63.97-28.65 63.97-64H160.03c0 35.35 28.65 64 63.97 64zm215.39-149.71c-19.32-20.76-55.47-51.99-55.47-154.29 0-77.7-54.48-139.9-127.94-155.16V32c0-17.67-14.32-32-31.98-32s-31.98 14.33-31.98 32v20.84C118.56 68.1 64.08 130.3 64.08 208c0 102.3-36.15 133.53-55.47 154.29-6 6.45-8.66 14.16-8.61 21.71.11 16.4 12.98 32 32.1 32h383.8c19.12 0 32-15.6 32.1-32 .05-7.55-2.61-15.27-8.61-21.71z"},child:[]}]})(t)}function FO(t){return Tn({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M448 360V24c0-13.3-10.7-24-24-24H96C43 0 0 43 0 96v320c0 53 43 96 96 96h328c13.3 0 24-10.7 24-24v-16c0-7.5-3.5-14.3-8.9-18.7-4.2-15.4-4.2-59.3 0-74.7 5.4-4.3 8.9-11.1 8.9-18.6zM128 134c0-3.3 2.7-6 6-6h212c3.3 0 6 2.7 6 6v20c0 3.3-2.7 6-6 6H134c-3.3 0-6-2.7-6-6v-20zm0 64c0-3.3 2.7-6 6-6h212c3.3 0 6 2.7 6 6v20c0 3.3-2.7 6-6 6H134c-3.3 0-6-2.7-6-6v-20zm253.4 250H96c-17.7 0-32-14.3-32-32 0-17.6 14.4-32 32-32h285.4c-1.9 17.1-1.9 46.9 0 64z"},child:[]}]})(t)}function BO(t){return Tn({attr:{viewBox:"0 0 640 512"},child:[{tag:"path",attr:{d:"M208 352c-2.39 0-4.78.35-7.06 1.09C187.98 357.3 174.35 360 160 360c-14.35 0-27.98-2.7-40.95-6.91-2.28-.74-4.66-1.09-7.05-1.09C49.94 352-.33 402.48 0 464.62.14 490.88 21.73 512 48 512h224c26.27 0 47.86-21.12 48-47.38.33-62.14-49.94-112.62-112-112.62zm-48-32c53.02 0 96-42.98 96-96s-42.98-96-96-96-96 42.98-96 96 42.98 96 96 96zM592 0H208c-26.47 0-48 22.25-48 49.59V96c23.42 0 45.1 6.78 64 17.8V64h352v288h-64v-64H384v64h-76.24c19.1 16.69 33.12 38.73 39.69 64H592c26.47 0 48-22.25 48-49.59V49.59C640 22.25 618.47 0 592 0z"},child:[]}]})(t)}function LO(t){return Tn({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M332.8 320h38.4c6.4 0 12.8-6.4 12.8-12.8V172.8c0-6.4-6.4-12.8-12.8-12.8h-38.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h38.4c6.4 0 12.8-6.4 12.8-12.8V76.8c0-6.4-6.4-12.8-12.8-12.8h-38.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-288 0h38.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-38.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h38.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-38.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zM496 384H64V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16z"},child:[]}]})(t)}function $O(t){return Tn({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M487.4 315.7l-42.6-24.6c4.3-23.2 4.3-47 0-70.2l42.6-24.6c4.9-2.8 7.1-8.6 5.5-14-11.1-35.6-30-67.8-54.7-94.6-3.8-4.1-10-5.1-14.8-2.3L380.8 110c-17.9-15.4-38.5-27.3-60.8-35.1V25.8c0-5.6-3.9-10.5-9.4-11.7-36.7-8.2-74.3-7.8-109.2 0-5.5 1.2-9.4 6.1-9.4 11.7V75c-22.2 7.9-42.8 19.8-60.8 35.1L88.7 85.5c-4.9-2.8-11-1.9-14.8 2.3-24.7 26.7-43.6 58.9-54.7 94.6-1.7 5.4.6 11.2 5.5 14L67.3 221c-4.3 23.2-4.3 47 0 70.2l-42.6 24.6c-4.9 2.8-7.1 8.6-5.5 14 11.1 35.6 30 67.8 54.7 94.6 3.8 4.1 10 5.1 14.8 2.3l42.6-24.6c17.9 15.4 38.5 27.3 60.8 35.1v49.2c0 5.6 3.9 10.5 9.4 11.7 36.7 8.2 74.3 7.8 109.2 0 5.5-1.2 9.4-6.1 9.4-11.7v-49.2c22.2-7.9 42.8-19.8 60.8-35.1l42.6 24.6c4.9 2.8 11 1.9 14.8-2.3 24.7-26.7 43.6-58.9 54.7-94.6 1.5-5.5-.7-11.3-5.6-14.1zM256 336c-44.1 0-80-35.9-80-80s35.9-80 80-80 80 35.9 80 80-35.9 80-80 80z"},child:[]}]})(t)}function zO(t){return Tn({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M448 73.143v45.714C448 159.143 347.667 192 224 192S0 159.143 0 118.857V73.143C0 32.857 100.333 0 224 0s224 32.857 224 73.143zM448 176v102.857C448 319.143 347.667 352 224 352S0 319.143 0 278.857V176c48.125 33.143 136.208 48.572 224 48.572S399.874 209.143 448 176zm0 160v102.857C448 479.143 347.667 512 224 512S0 479.143 0 438.857V336c48.125 33.143 136.208 48.572 224 48.572S399.874 369.143 448 336z"},child:[]}]})(t)}function VO(t){return Tn({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M400 224h-24v-72C376 68.2 307.8 0 224 0S72 68.2 72 152v72H48c-26.5 0-48 21.5-48 48v192c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V272c0-26.5-21.5-48-48-48zm-104 0H152v-72c0-39.7 32.3-72 72-72s72 32.3 72 72v72z"},child:[]}]})(t)}function UO(t){return Tn({attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M496 128v16a8 8 0 0 1-8 8h-24v12c0 6.627-5.373 12-12 12H60c-6.627 0-12-5.373-12-12v-12H24a8 8 0 0 1-8-8v-16a8 8 0 0 1 4.941-7.392l232-88a7.996 7.996 0 0 1 6.118 0l232 88A8 8 0 0 1 496 128zm-24 304H40c-13.255 0-24 10.745-24 24v16a8 8 0 0 0 8 8h464a8 8 0 0 0 8-8v-16c0-13.255-10.745-24-24-24zM96 192v192H60c-6.627 0-12 5.373-12 12v20h416v-20c0-6.627-5.373-12-12-12h-36V192h-64v192h-64V192h-64v192h-64V192H96z"},child:[]}]})(t)}function WO(t){return Tn({attr:{viewBox:"0 0 448 512"},child:[{tag:"path",attr:{d:"M319.4 320.6L224 416l-95.4-95.4C57.1 323.7 0 382.2 0 454.4v9.6c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-9.6c0-72.2-57.1-130.7-128.6-133.8zM13.6 79.8l6.4 1.5v58.4c-7 4.2-12 11.5-12 20.3 0 8.4 4.6 15.4 11.1 19.7L3.5 242c-1.7 6.9 2.1 14 7.6 14h41.8c5.5 0 9.3-7.1 7.6-14l-15.6-62.3C51.4 175.4 56 168.4 56 160c0-8.8-5-16.1-12-20.3V87.1l66 15.9c-8.6 17.2-14 36.4-14 57 0 70.7 57.3 128 128 128s128-57.3 128-128c0-20.6-5.3-39.8-14-57l96.3-23.2c18.2-4.4 18.2-27.1 0-31.5l-190.4-46c-13-3.1-26.7-3.1-39.7 0L13.6 48.2c-18.1 4.4-18.1 27.2 0 31.6z"},child:[]}]})(t)}function eO(t){return Tn({attr:{viewBox:"0 0 640 512"},child:[{tag:"path",attr:{d:"M96 224c35.3 0 64-28.7 64-64s-28.7-64-64-64-64 28.7-64 64 28.7 64 64 64zm448 0c35.3 0 64-28.7 64-64s-28.7-64-64-64-64 28.7-64 64 28.7 64 64 64zm32 32h-64c-17.6 0-33.5 7.1-45.1 18.6 40.3 22.1 68.9 62 75.1 109.4h66c17.7 0 32-14.3 32-32v-32c0-35.3-28.7-64-64-64zm-256 0c61.9 0 112-50.1 112-112S381.9 32 320 32 208 82.1 208 144s50.1 112 112 112zm76.8 32h-8.3c-20.8 10-43.9 16-68.5 16s-47.6-6-68.5-16h-8.3C179.6 288 128 339.6 128 403.2V432c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48v-28.8c0-63.6-51.6-115.2-115.2-115.2zm-223.7-13.4C161.5 263.1 145.6 256 128 256H64c-35.3 0-64 28.7-64 64v32c0 17.7 14.3 32 32 32h65.9c6.3-47.4 34.9-87.3 75.2-109.4z"},child:[]}]})(t)}const tO=({title:t,description:r,icon:e,onClick:a})=>{const f=rs("white","gray.800"),c=rs("purple.200","gray.600"),s=rs("purple.50","gray.700");return W.jsxs(wr,{onClick:a,height:"200px",p:6,bg:f,border:"1px",borderColor:c,borderRadius:"xl",boxShadow:"lg",_hover:{bg:s,transform:"translateY(-5px)",boxShadow:"xl",borderColor:"purple.300"},transition:"all 0.3s",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",textAlign:"center",w:"100%",children:[W.jsx(Tr,{as:e,w:10,h:10,color:"purple.500",mb:4}),W.jsx(He,{fontSize:"xl",fontWeight:"bold",mb:2,color:"purple.600",children:t}),W.jsx(He,{color:"gray.500",fontSize:"sm",children:r})]})},HO=()=>{const t=Cu(),r=ab(),e=rs("linear(to-br, purple.50, blue.50)","linear(to-br, gray.900, purple.900)"),a=async()=>{try{const{error:c}=await rn.auth.signOut();if(c)throw c;r({title:"Signed out successfully",status:"success",duration:3e3,isClosable:!0}),t("/")}catch{r({title:"Error signing out",status:"error",duration:3e3,isClosable:!0})}},f=[{title:"Add Course",description:"Add a new course to the system",icon:hv,route:"/admin/courses/add"},{title:"Bulk Upload",description:"Upload multiple courses using Excel file",icon:fv,route:"/admin/courses/bulk-upload"},{title:"Department & Courses",description:"View and manage courses that have been added",icon:UI,route:"/admin/courses/my-courses"},{title:"Feedback",description:"View and manage user feedback submissions",icon:qI,route:"/admin/feedback"},{title:"User Management",description:"View and manage user accounts",icon:eO,route:"/admin/user-management"},{title:"Settings",description:"Configure system settings",icon:WI,route:"/admin/settings"}];return W.jsxs(ft,{p:8,minH:"100vh",bgGradient:e,children:[W.jsx(ft,{display:"flex",justifyContent:"flex-end",mb:4,children:W.jsx(wr,{onClick:a,colorScheme:"red",size:"sm",children:"Sign Out"})}),W.jsxs(yr,{spacing:8,maxW:"1200px",mx:"auto",children:[W.jsx(hi,{size:"xl",mb:6,bgGradient:"linear(to-r, blue.400, purple.500)",bgClip:"text",children:"Admin Dashboard"}),W.jsx(bg,{columns:{base:1,md:2,lg:3},spacing:8,w:"100%",justifyItems:"center",children:f.map((c,s)=>W.jsx(tO,{title:c.title,description:c.description,icon:c.icon,onClick:()=>t(c.route)},s))})]})]})},xc=on(ft),rO=({text:t="Back to Dashboard",onClick:r})=>{const e=Cu(),a=rs("white","gray.800"),f=()=>{r?r():e("/admin")};return W.jsxs(W.Fragment,{children:[W.jsx("style",{children:` @keyframes gradient { 0% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } 100% { background-position: 0% 50%; } } `}),W.jsx(xc,{initial:{opacity:0,x:20},animate:{opacity:1,x:0,y:[0,-2,0]},transition:{opacity:{duration:.5},x:{duration:.5},y:{repeat:1/0,duration:3,ease:"easeInOut"}},whileHover:{scale:1.08,y:-5,boxShadow:"0 20px 40px -10px rgba(139, 92, 246, 0.4)"},whileTap:{scale:.95},children:W.jsx(ft,{position:"relative",borderRadius:"xl",overflow:"hidden",_before:{content:'""',position:"absolute",top:0,left:0,right:0,bottom:0,background:"linear-gradient(45deg, #667eea, #764ba2, #f093fb, #f5576c)",backgroundSize:"300% 300%",animation:"gradient 4s ease infinite",borderRadius:"xl",padding:"2px"},_after:{content:'""',position:"absolute",top:"2px",left:"2px",right:"2px",bottom:"2px",background:a,borderRadius:"10px",zIndex:1},children:W.jsx(wr,{leftIcon:W.jsx(xc,{animate:{x:[-3,3,-3],rotate:[0,-10,10,0]},transition:{repeat:1/0,duration:2.5,ease:"easeInOut"},children:W.jsx(Tr,{as:kv})}),onClick:f,colorScheme:"purple",variant:"solid",size:"md",bg:"linear-gradient(135deg, #667eea 0%, #764ba2 100%)",_hover:{bg:"linear-gradient(135deg, #764ba2 0%, #f093fb 100%)"},borderRadius:"10px",px:6,py:2,fontWeight:"bold",color:"white",position:"relative",zIndex:2,transition:"all 0.3s ease-in-out",textShadow:"0 1px 2px rgba(0,0,0,0.1)",children:W.jsx(xc,{initial:{opacity:0},animate:{opacity:1},transition:{delay:.2},children:t})})})})]})};var _c={exports:{}};/*! ExcelJS 19-10-2023 */var Mm;function nO(){return Mm||(Mm=1,function(t,r){(function(e){t.exports=e()})(function(){return function e(a,f,c){function s(n,o){if(!f[n]){if(!a[n]){var h=typeof Go=="function"&&Go;if(!o&&h)return h(n,!0);if(l)return l(n,!0);var u=new Error("Cannot find module '"+n+"'");throw u.code="MODULE_NOT_FOUND",u}var d=f[n]={exports:{}};a[n][0].call(d.exports,function(m){return s(a[n][1][m]||m)},d,d.exports,e,a,f,c)}return f[n].exports}for(var l=typeof Go=="function"&&Go,i=0;i<c.length;i++)s(c[i]);return s}({1:[function(e,a,f){const c=e("fs"),s=e("fast-csv"),l=e("dayjs/plugin/customParseFormat"),i=e("dayjs/plugin/utc"),n=e("dayjs").extend(l).extend(i),o=e("../utils/stream-buf"),{fs:{exists:h}}=e("../utils/utils"),u={true:!0,false:!1,"#N/A":{error:"#N/A"},"#REF!":{error:"#REF!"},"#NAME?":{error:"#NAME?"},"#DIV/0!":{error:"#DIV/0!"},"#NULL!":{error:"#NULL!"},"#VALUE!":{error:"#VALUE!"},"#NUM!":{error:"#NUM!"}};a.exports=class{constructor(d){this.workbook=d,this.worksheet=null}async readFile(d,m){if(m=m||{},!await h(d))throw new Error("File not found: "+d);const b=c.createReadStream(d),p=await this.read(b,m);return b.close(),p}read(d,m){return m=m||{},new Promise((b,p)=>{const v=this.workbook.addWorksheet(m.sheetName),g=m.dateFormats||["YYYY-MM-DD[T]HH:mm:ssZ","YYYY-MM-DD[T]HH:mm:ss","MM-DD-YYYY","YYYY-MM-DD"],x=m.map||function(T){if(T==="")return null;const R=Number(T);if(!Number.isNaN(R)&&R!==1/0)return R;const B=g.reduce((F,L)=>{if(F)return F;const V=n(T,L,!0);return V.isValid()?V:null},null);if(B)return new Date(B.valueOf());const I=u[T];return I!==void 0?I:T},C=s.parse(m.parserOptions).on("data",T=>{v.addRow(T.map(x))}).on("end",()=>{C.emit("worksheet",v)});C.on("worksheet",b).on("error",p),d.pipe(C)})}createInputStream(){throw new Error("`CSV#createInputStream` is deprecated. You should use `CSV#read` instead. This method will be removed in version 5.0. Please follow upgrade instruction: https://github.com/exceljs/exceljs/blob/master/UPGRADE-4.0.md")}write(d,m){return new Promise((b,p)=>{m=m||{};const v=this.workbook.getWorksheet(m.sheetName||m.sheetId),g=s.format(m.formatterOptions);d.on("finish",()=>{b()}),g.on("error",p),g.pipe(d);const{dateFormat:x,dateUTC:C}=m,T=m.map||(I=>{if(I){if(I.text||I.hyperlink)return I.hyperlink||I.text||"";if(I.formula||I.result)return I.result||"";if(I instanceof Date)return x?C?n.utc(I).format(x):n(I).format(x):C?n.utc(I).format():n(I).format();if(I.error)return I.error;if(typeof I=="object")return JSON.stringify(I)}return I}),R=m.includeEmptyRows===void 0||m.includeEmptyRows;let B=1;v&&v.eachRow((I,F)=>{if(R)for(;B++<F-1;)g.write([]);const{values:L}=I;L.shift(),g.write(L.map(T)),B=F}),g.end()})}writeFile(d,m){const b={encoding:(m=m||{}).encoding||"utf8"},p=c.createWriteStream(d,b);return this.write(p,m)}async writeBuffer(d){const m=new o;return await this.write(m,d),m.read()}}},{"../utils/stream-buf":24,"../utils/utils":27,dayjs:391,"dayjs/plugin/customParseFormat":392,"dayjs/plugin/utc":393,"fast-csv":424,fs:216}],2:[function(e,a,f){const c=e("../utils/col-cache");class s{constructor(i,n){let o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;if(this.worksheet=i,n)if(typeof n=="string"){const h=c.decodeAddress(n);this.nativeCol=h.col+o,this.nativeColOff=0,this.nativeRow=h.row+o,this.nativeRowOff=0}else n.nativeCol!==void 0?(this.nativeCol=n.nativeCol||0,this.nativeColOff=n.nativeColOff||0,this.nativeRow=n.nativeRow||0,this.nativeRowOff=n.nativeRowOff||0):n.col!==void 0?(this.col=n.col+o,this.row=n.row+o):(this.nativeCol=0,this.nativeColOff=0,this.nativeRow=0,this.nativeRowOff=0);else this.nativeCol=0,this.nativeColOff=0,this.nativeRow=0,this.nativeRowOff=0}static asInstance(i){return i instanceof s||i==null?i:new s(i)}get col(){return this.nativeCol+Math.min(this.colWidth-1,this.nativeColOff)/this.colWidth}set col(i){this.nativeCol=Math.floor(i),this.nativeColOff=Math.floor((i-this.nativeCol)*this.colWidth)}get row(){return this.nativeRow+Math.min(this.rowHeight-1,this.nativeRowOff)/this.rowHeight}set row(i){this.nativeRow=Math.floor(i),this.nativeRowOff=Math.floor((i-this.nativeRow)*this.rowHeight)}get colWidth(){return this.worksheet&&this.worksheet.getColumn(this.nativeCol+1)&&this.worksheet.getColumn(this.nativeCol+1).isCustomWidth?Math.floor(1e4*this.worksheet.getColumn(this.nativeCol+1).width):64e4}get rowHeight(){return this.worksheet&&this.worksheet.getRow(this.nativeRow+1)&&this.worksheet.getRow(this.nativeRow+1).height?Math.floor(1e4*this.worksheet.getRow(this.nativeRow+1).height):18e4}get model(){return{nativeCol:this.nativeCol,nativeColOff:this.nativeColOff,nativeRow:this.nativeRow,nativeRowOff:this.nativeRowOff}}set model(i){this.nativeCol=i.nativeCol,this.nativeColOff=i.nativeColOff,this.nativeRow=i.nativeRow,this.nativeRowOff=i.nativeRowOff}}a.exports=s},{"../utils/col-cache":19}],3:[function(e,a,f){const c=e("../utils/col-cache"),s=e("../utils/under-dash"),l=e("./enums"),{slideFormula:i}=e("../utils/shared-formula"),n=e("./note");class o{constructor(d,m,b){if(!d||!m)throw new Error("A Cell needs a Row");this._row=d,this._column=m,c.validateAddress(b),this._address=b,this._value=h.create(o.Types.Null,this),this.style=this._mergeStyle(d.style,m.style,{}),this._mergeCount=0}get worksheet(){return this._row.worksheet}get workbook(){return this._row.worksheet.workbook}destroy(){delete this.style,delete this._value,delete this._row,delete this._column,delete this._address}get numFmt(){return this.style.numFmt}set numFmt(d){this.style.numFmt=d}get font(){return this.style.font}set font(d){this.style.font=d}get alignment(){return this.style.alignment}set alignment(d){this.style.alignment=d}get border(){return this.style.border}set border(d){this.style.border=d}get fill(){return this.style.fill}set fill(d){this.style.fill=d}get protection(){return this.style.protection}set protection(d){this.style.protection=d}_mergeStyle(d,m,b){const p=d&&d.numFmt||m&&m.numFmt;p&&(b.numFmt=p);const v=d&&d.font||m&&m.font;v&&(b.font=v);const g=d&&d.alignment||m&&m.alignment;g&&(b.alignment=g);const x=d&&d.border||m&&m.border;x&&(b.border=x);const C=d&&d.fill||m&&m.fill;C&&(b.fill=C);const T=d&&d.protection||m&&m.protection;return T&&(b.protection=T),b}get address(){return this._address}get row(){return this._row.number}get col(){return this._column.number}get $col$row(){return`$${this._column.letter}$${this.row}`}get type(){return this._value.type}get effectiveType(){return this._value.effectiveType}toCsvString(){return this._value.toCsvString()}addMergeRef(){this._mergeCount++}releaseMergeRef(){this._mergeCount--}get isMerged(){return this._mergeCount>0||this.type===o.Types.Merge}merge(d,m){this._value.release(),this._value=h.create(o.Types.Merge,this,d),m||(this.style=d.style)}unmerge(){this.type===o.Types.Merge&&(this._value.release(),this._value=h.create(o.Types.Null,this),this.style=this._mergeStyle(this._row.style,this._column.style,{}))}isMergedTo(d){return this._value.type===o.Types.Merge&&this._value.isMergedTo(d)}get master(){return this.type===o.Types.Merge?this._value.master:this}get isHyperlink(){return this._value.type===o.Types.Hyperlink}get hyperlink(){return this._value.hyperlink}get value(){return this._value.value}set value(d){this.type!==o.Types.Merge?(this._value.release(),this._value=h.create(h.getType(d),this,d)):this._value.master.value=d}get note(){return this._comment&&this._comment.note}set note(d){this._comment=new n(d)}get text(){return this._value.toString()}get html(){return s.escapeHtml(this.text)}toString(){return this.text}_upgradeToHyperlink(d){this.type===o.Types.String&&(this._value=h.create(o.Types.Hyperlink,this,{text:this._value.value,hyperlink:d}))}get formula(){return this._value.formula}get result(){return this._value.result}get formulaType(){return this._value.formulaType}get fullAddress(){const{worksheet:d}=this._row;return{sheetName:d.name,address:this.address,row:this.row,col:this.col}}get name(){return this.names[0]}set name(d){this.names=[d]}get names(){return this.workbook.definedNames.getNamesEx(this.fullAddress)}set names(d){const{definedNames:m}=this.workbook;m.removeAllNames(this.fullAddress),d.forEach(b=>{m.addEx(this.fullAddress,b)})}addName(d){this.workbook.definedNames.addEx(this.fullAddress,d)}removeName(d){this.workbook.definedNames.removeEx(this.fullAddress,d)}removeAllNames(){this.workbook.definedNames.removeAllNames(this.fullAddress)}get _dataValidations(){return this.worksheet.dataValidations}get dataValidation(){return this._dataValidations.find(this.address)}set dataValidation(d){this._dataValidations.add(this.address,d)}get model(){const{model:d}=this._value;return d.style=this.style,this._comment&&(d.comment=this._comment.model),d}set model(d){if(this._value.release(),this._value=h.create(d.type,this),this._value.model=d,d.comment)switch(d.comment.type){case"note":this._comment=n.fromModel(d.comment)}d.style?this.style=d.style:this.style={}}}o.Types=l.ValueType;const h={getType:u=>u==null?o.Types.Null:u instanceof String||typeof u=="string"?o.Types.String:typeof u=="number"?o.Types.Number:typeof u=="boolean"?o.Types.Boolean:u instanceof Date?o.Types.Date:u.text&&u.hyperlink?o.Types.Hyperlink:u.formula||u.sharedFormula?o.Types.Formula:u.richText?o.Types.RichText:u.sharedString?o.Types.SharedString:u.error?o.Types.Error:o.Types.JSON,types:[{t:o.Types.Null,f:class{constructor(u){this.model={address:u.address,type:o.Types.Null}}get value(){return null}set value(u){}get type(){return o.Types.Null}get effectiveType(){return o.Types.Null}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return""}release(){}toString(){return""}}},{t:o.Types.Number,f:class{constructor(u,d){this.model={address:u.address,type:o.Types.Number,value:d}}get value(){return this.model.value}set value(u){this.model.value=u}get type(){return o.Types.Number}get effectiveType(){return o.Types.Number}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return this.model.value.toString()}release(){}toString(){return this.model.value.toString()}}},{t:o.Types.String,f:class{constructor(u,d){this.model={address:u.address,type:o.Types.String,value:d}}get value(){return this.model.value}set value(u){this.model.value=u}get type(){return o.Types.String}get effectiveType(){return o.Types.String}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return`"${this.model.value.replace(/"/g,'""')}"`}release(){}toString(){return this.model.value}}},{t:o.Types.Date,f:class{constructor(u,d){this.model={address:u.address,type:o.Types.Date,value:d}}get value(){return this.model.value}set value(u){this.model.value=u}get type(){return o.Types.Date}get effectiveType(){return o.Types.Date}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return this.model.value.toISOString()}release(){}toString(){return this.model.value.toString()}}},{t:o.Types.Hyperlink,f:class{constructor(u,d){this.model={address:u.address,type:o.Types.Hyperlink,text:d?d.text:void 0,hyperlink:d?d.hyperlink:void 0},d&&d.tooltip&&(this.model.tooltip=d.tooltip)}get value(){const u={text:this.model.text,hyperlink:this.model.hyperlink};return this.model.tooltip&&(u.tooltip=this.model.tooltip),u}set value(u){this.model={text:u.text,hyperlink:u.hyperlink},u.tooltip&&(this.model.tooltip=u.tooltip)}get text(){return this.model.text}set text(u){this.model.text=u}get hyperlink(){return this.model.hyperlink}set hyperlink(u){this.model.hyperlink=u}get type(){return o.Types.Hyperlink}get effectiveType(){return o.Types.Hyperlink}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return this.model.hyperlink}release(){}toString(){return this.model.text}}},{t:o.Types.Formula,f:class{constructor(u,d){this.cell=u,this.model={address:u.address,type:o.Types.Formula,shareType:d?d.shareType:void 0,ref:d?d.ref:void 0,formula:d?d.formula:void 0,sharedFormula:d?d.sharedFormula:void 0,result:d?d.result:void 0}}_copyModel(u){const d={},m=b=>{const p=u[b];p&&(d[b]=p)};return m("formula"),m("result"),m("ref"),m("shareType"),m("sharedFormula"),d}get value(){return this._copyModel(this.model)}set value(u){this.model=this._copyModel(u)}validate(u){switch(h.getType(u)){case o.Types.Null:case o.Types.String:case o.Types.Number:case o.Types.Date:break;case o.Types.Hyperlink:case o.Types.Formula:default:throw new Error("Cannot process that type of result value")}}get dependencies(){return{ranges:this.formula.match(/([a-zA-Z0-9]+!)?[A-Z]{1,3}\d{1,4}:[A-Z]{1,3}\d{1,4}/g),cells:this.formula.replace(/([a-zA-Z0-9]+!)?[A-Z]{1,3}\d{1,4}:[A-Z]{1,3}\d{1,4}/g,"").match(/([a-zA-Z0-9]+!)?[A-Z]{1,3}\d{1,4}/g)}}get formula(){return this.model.formula||this._getTranslatedFormula()}set formula(u){this.model.formula=u}get formulaType(){return this.model.formula?l.FormulaType.Master:this.model.sharedFormula?l.FormulaType.Shared:l.FormulaType.None}get result(){return this.model.result}set result(u){this.model.result=u}get type(){return o.Types.Formula}get effectiveType(){const u=this.model.result;return u==null?l.ValueType.Null:u instanceof String||typeof u=="string"?l.ValueType.String:typeof u=="number"?l.ValueType.Number:u instanceof Date?l.ValueType.Date:u.text&&u.hyperlink?l.ValueType.Hyperlink:u.formula?l.ValueType.Formula:l.ValueType.Null}get address(){return this.model.address}set address(u){this.model.address=u}_getTranslatedFormula(){if(!this._translatedFormula&&this.model.sharedFormula){const{worksheet:u}=this.cell,d=u.findCell(this.model.sharedFormula);this._translatedFormula=d&&i(d.formula,d.address,this.model.address)}return this._translatedFormula}toCsvString(){return""+(this.model.result||"")}release(){}toString(){return this.model.result?this.model.result.toString():""}}},{t:o.Types.Merge,f:class{constructor(u,d){this.model={address:u.address,type:o.Types.Merge,master:d?d.address:void 0},this._master=d,d&&d.addMergeRef()}get value(){return this._master.value}set value(u){u instanceof o?(this._master&&this._master.releaseMergeRef(),u.addMergeRef(),this._master=u):this._master.value=u}isMergedTo(u){return u===this._master}get master(){return this._master}get type(){return o.Types.Merge}get effectiveType(){return this._master.effectiveType}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return""}release(){this._master.releaseMergeRef()}toString(){return this.value.toString()}}},{t:o.Types.JSON,f:class{constructor(u,d){this.model={address:u.address,type:o.Types.String,value:JSON.stringify(d),rawValue:d}}get value(){return this.model.rawValue}set value(u){this.model.rawValue=u,this.model.value=JSON.stringify(u)}get type(){return o.Types.String}get effectiveType(){return o.Types.String}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return this.model.value}release(){}toString(){return this.model.value}}},{t:o.Types.SharedString,f:class{constructor(u,d){this.model={address:u.address,type:o.Types.SharedString,value:d}}get value(){return this.model.value}set value(u){this.model.value=u}get type(){return o.Types.SharedString}get effectiveType(){return o.Types.SharedString}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return this.model.value.toString()}release(){}toString(){return this.model.value.toString()}}},{t:o.Types.RichText,f:class{constructor(u,d){this.model={address:u.address,type:o.Types.String,value:d}}get value(){return this.model.value}set value(u){this.model.value=u}toString(){return this.model.value.richText.map(u=>u.text).join("")}get type(){return o.Types.RichText}get effectiveType(){return o.Types.RichText}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return`"${this.text.replace(/"/g,'""')}"`}release(){}}},{t:o.Types.Boolean,f:class{constructor(u,d){this.model={address:u.address,type:o.Types.Boolean,value:d}}get value(){return this.model.value}set value(u){this.model.value=u}get type(){return o.Types.Boolean}get effectiveType(){return o.Types.Boolean}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return this.model.value?1:0}release(){}toString(){return this.model.value.toString()}}},{t:o.Types.Error,f:class{constructor(u,d){this.model={address:u.address,type:o.Types.Error,value:d}}get value(){return this.model.value}set value(u){this.model.value=u}get type(){return o.Types.Error}get effectiveType(){return o.Types.Error}get address(){return this.model.address}set address(u){this.model.address=u}toCsvString(){return this.toString()}release(){}toString(){return this.model.value.error.toString()}}}].reduce((u,d)=>(u[d.t]=d.f,u),[]),create(u,d,m){const b=this.types[u];if(!b)throw new Error("Could not create Value of type "+u);return new b(d,m)}};a.exports=o},{"../utils/col-cache":19,"../utils/shared-formula":23,"../utils/under-dash":26,"./enums":7,"./note":9}],4:[function(e,a,f){const c=e("../utils/under-dash"),s=e("./enums"),l=e("../utils/col-cache");class i{constructor(o,h,u){this._worksheet=o,this._number=h,u!==!1&&(this.defn=u)}get number(){return this._number}get worksheet(){return this._worksheet}get letter(){return l.n2l(this._number)}get isCustomWidth(){return this.width!==void 0&&this.width!==9}get defn(){return{header:this._header,key:this.key,width:this.width,style:this.style,hidden:this.hidden,outlineLevel:this.outlineLevel}}set defn(o){o?(this.key=o.key,this.width=o.width!==void 0?o.width:9,this.outlineLevel=o.outlineLevel,o.style?this.style=o.style:this.style={},this.header=o.header,this._hidden=!!o.hidden):(delete this._header,delete this._key,delete this.width,this.style={},this.outlineLevel=0)}get headers(){return this._header&&this._header instanceof Array?this._header:[this._header]}get header(){return this._header}set header(o){o!==void 0?(this._header=o,this.headers.forEach((h,u)=>{this._worksheet.getCell(u+1,this.number).value=h})):this._header=void 0}get key(){return this._key}set key(o){(this._key&&this._worksheet.getColumnKey(this._key))===this&&this._worksheet.deleteColumnKey(this._key),this._key=o,o&&this._worksheet.setColumnKey(this._key,this)}get hidden(){return!!this._hidden}set hidden(o){this._hidden=o}get outlineLevel(){return this._outlineLevel||0}set outlineLevel(o){this._outlineLevel=o}get collapsed(){return!!(this._outlineLevel&&this._outlineLevel>=this._worksheet.properties.outlineLevelCol)}toString(){return JSON.stringify({key:this.key,width:this.width,headers:this.headers.length?this.headers:void 0})}equivalentTo(o){return this.width===o.width&&this.hidden===o.hidden&&this.outlineLevel===o.outlineLevel&&c.isEqual(this.style,o.style)}get isDefault(){if(this.isCustomWidth||this.hidden||this.outlineLevel)return!1;const o=this.style;return!o||!(o.font||o.numFmt||o.alignment||o.border||o.fill||o.protection)}get headerCount(){return this.headers.length}eachCell(o,h){const u=this.number;h||(h=o,o=null),this._worksheet.eachRow(o,(d,m)=>{h(d.getCell(u),m)})}get values(){const o=[];return this.eachCell((h,u)=>{h&&h.type!==s.ValueType.Null&&(o[u]=h.value)}),o}set values(o){if(!o)return;const h=this.number;let u=0;o.hasOwnProperty("0")&&(u=1),o.forEach((d,m)=>{this._worksheet.getCell(m+u,h).value=d})}_applyStyle(o,h){return this.style[o]=h,this.eachCell(u=>{u[o]=h}),h}get numFmt(){return this.style.numFmt}set numFmt(o){this._applyStyle("numFmt",o)}get font(){return this.style.font}set font(o){this._applyStyle("font",o)}get alignment(){return this.style.alignment}set alignment(o){this._applyStyle("alignment",o)}get protection(){return this.style.protection}set protection(o){this._applyStyle("protection",o)}get border(){return this.style.border}set border(o){this._applyStyle("border",o)}get fill(){return this.style.fill}set fill(o){this._applyStyle("fill",o)}static toModel(o){const h=[];let u=null;return o&&o.forEach((d,m)=>{d.isDefault?u&&(u=null):u&&d.equivalentTo(u)?u.max=m+1:(u={min:m+1,max:m+1,width:d.width!==void 0?d.width:9,style:d.style,isCustomWidth:d.isCustomWidth,hidden:d.hidden,outlineLevel:d.outlineLevel,collapsed:d.collapsed},h.push(u))}),h.length?h:void 0}static fromModel(o,h){const u=[];let d=1,m=0;for(h=(h=h||[]).sort(function(b,p){return b.min-p.min});m<h.length;){const b=h[m++];for(;d<b.min;)u.push(new i(o,d++));for(;d<=b.max;)u.push(new i(o,d++,b))}return u.length?u:null}}a.exports=i},{"../utils/col-cache":19,"../utils/under-dash":26,"./enums":7}],5:[function(e,a,f){a.exports=class{constructor(c){this.model=c||{}}add(c,s){return this.model[c]=s}find(c){return this.model[c]}remove(c){this.model[c]=void 0}}},{}],6:[function(e,a,f){const c=e("../utils/under-dash"),s=e("../utils/col-cache"),l=e("../utils/cell-matrix"),i=e("./range"),n=/[$](\w+)[$](\d+)(:[$](\w+)[$](\d+))?/;a.exports=class{constructor(){this.matrixMap={}}getMatrix(o){return this.matrixMap[o]||(this.matrixMap[o]=new l)}add(o,h){const u=s.decodeEx(o);this.addEx(u,h)}addEx(o,h){const u=this.getMatrix(h);if(o.top)for(let d=o.left;d<=o.right;d++)for(let m=o.top;m<=o.bottom;m++){const b={sheetName:o.sheetName,address:s.n2l(d)+m,row:m,col:d};u.addCellEx(b)}else u.addCellEx(o)}remove(o,h){const u=s.decodeEx(o);this.removeEx(u,h)}removeEx(o,h){this.getMatrix(h).removeCellEx(o)}removeAllNames(o){c.each(this.matrixMap,h=>{h.removeCellEx(o)})}forEach(o){c.each(this.matrixMap,(h,u)=>{h.forEach(d=>{o(u,d)})})}getNames(o){return this.getNamesEx(s.decodeEx(o))}getNamesEx(o){return c.map(this.matrixMap,(h,u)=>h.findCellEx(o)&&u).filter(Boolean)}_explore(o,h){h.mark=!1;const{sheetName:u}=h,d=new i(h.row,h.col,h.row,h.col,u);let m,b;function p(g,x){const C=o.findCellAt(u,g,h.col);return!(!C||!C.mark)&&(d[x]=g,C.mark=!1,!0)}for(b=h.row-1;p(b,"top");b--);for(b=h.row+1;p(b,"bottom");b++);function v(g,x){const C=[];for(b=d.top;b<=d.bottom;b++){const T=o.findCellAt(u,b,g);if(!T||!T.mark)return!1;C.push(T)}d[x]=g;for(let T=0;T<C.length;T++)C[T].mark=!1;return!0}for(m=h.col-1;v(m,"left");m--);for(m=h.col+1;v(m,"right");m++);return d}getRanges(o,h){return(h=h||this.matrixMap[o])?(h.forEach(u=>{u.mark=!0}),{name:o,ranges:h.map(u=>u.mark&&this._explore(h,u)).filter(Boolean).map(u=>u.$shortRange)}):{name:o,ranges:[]}}normaliseMatrix(o,h){o.forEachInSheet(h,(u,d,m)=>{u&&(u.row===d&&u.col===m||(u.row=d,u.col=m,u.address=s.n2l(m)+d))})}spliceRows(o,h,u,d){c.each(this.matrixMap,m=>{m.spliceRows(o,h,u,d),this.normaliseMatrix(m,o)})}spliceColumns(o,h,u,d){c.each(this.matrixMap,m=>{m.spliceColumns(o,h,u,d),this.normaliseMatrix(m,o)})}get model(){return c.map(this.matrixMap,(o,h)=>this.getRanges(h,o)).filter(o=>o.ranges.length)}set model(o){const h=this.matrixMap={};o.forEach(u=>{const d=h[u.name]=new l;u.ranges.forEach(m=>{n.test(m.split("!").pop()||"")&&d.addCell(m)})})}}},{"../utils/cell-matrix":18,"../utils/col-cache":19,"../utils/under-dash":26,"./range":10}],7:[function(e,a,f){a.exports={ValueType:{Null:0,Merge:1,Number:2,String:3,Date:4,Hyperlink:5,Formula:6,SharedString:7,RichText:8,Boolean:9,Error:10},FormulaType:{None:0,Master:1,Shared:2},RelationshipType:{None:0,OfficeDocument:1,Worksheet:2,CalcChain:3,SharedStrings:4,Styles:5,Theme:6,Hyperlink:7},DocumentType:{Xlsx:1},ReadingOrder:{LeftToRight:1,RightToLeft:2},ErrorValue:{NotApplicable:"#N/A",Ref:"#REF!",Name:"#NAME?",DivZero:"#DIV/0!",Null:"#NULL!",Value:"#VALUE!",Num:"#NUM!"}}},{}],8:[function(e,a,f){const c=e("../utils/col-cache"),s=e("./anchor");a.exports=class{constructor(l,i){this.worksheet=l,this.model=i}get model(){switch(this.type){case"background":return{type:this.type,imageId:this.imageId};case"image":return{type:this.type,imageId:this.imageId,hyperlinks:this.range.hyperlinks,range:{tl:this.range.tl.model,br:this.range.br&&this.range.br.model,ext:this.range.ext,editAs:this.range.editAs}};default:throw new Error("Invalid Image Type")}}set model(l){let{type:i,imageId:n,range:o,hyperlinks:h}=l;if(this.type=i,this.imageId=n,i==="image")if(typeof o=="string"){const u=c.decode(o);this.range={tl:new s(this.worksheet,{col:u.left,row:u.top},-1),br:new s(this.worksheet,{col:u.right,row:u.bottom},0),editAs:"oneCell"}}else this.range={tl:new s(this.worksheet,o.tl,0),br:o.br&&new s(this.worksheet,o.br,0),ext:o.ext,editAs:o.editAs,hyperlinks:h||o.hyperlinks}}}},{"../utils/col-cache":19,"./anchor":2}],9:[function(e,a,f){const c=e("../utils/under-dash");class s{constructor(i){this.note=i}get model(){let i=null;switch(typeof this.note){case"string":i={type:"note",note:{texts:[{text:this.note}]}};break;default:i={type:"note",note:this.note}}return c.deepMerge({},s.DEFAULT_CONFIGS,i)}set model(i){const{note:n}=i,{texts:o}=n;o.length===1&&Object.keys(o[0]).length===1?this.note=o[0].text:this.note=n}static fromModel(i){const n=new s;return n.model=i,n}}s.DEFAULT_CONFIGS={note:{margins:{insetmode:"auto",inset:[.13,.13,.25,.25]},protection:{locked:"True",lockText:"True"},editAs:"absolute"}},a.exports=s},{"../utils/under-dash":26}],10:[function(e,a,f){const c=e("../utils/col-cache");class s{constructor(){this.decode(arguments)}setTLBR(i,n,o,h,u){if(arguments.length<4){const d=c.decodeAddress(i),m=c.decodeAddress(n);this.model={top:Math.min(d.row,m.row),left:Math.min(d.col,m.col),bottom:Math.max(d.row,m.row),right:Math.max(d.col,m.col),sheetName:o},this.setTLBR(d.row,d.col,m.row,m.col,u)}else this.model={top:Math.min(i,o),left:Math.min(n,h),bottom:Math.max(i,o),right:Math.max(n,h),sheetName:u}}decode(i){switch(i.length){case 5:this.setTLBR(i[0],i[1],i[2],i[3],i[4]);break;case 4:this.setTLBR(i[0],i[1],i[2],i[3]);break;case 3:this.setTLBR(i[0],i[1],i[2]);break;case 2:this.setTLBR(i[0],i[1]);break;case 1:{const n=i[0];if(n instanceof s)this.model={top:n.model.top,left:n.model.left,bottom:n.model.bottom,right:n.model.right,sheetName:n.sheetName};else if(n instanceof Array)this.decode(n);else if(n.top&&n.left&&n.bottom&&n.right)this.model={top:n.top,left:n.left,bottom:n.bottom,right:n.right,sheetName:n.sheetName};else{const o=c.decodeEx(n);o.top?this.model={top:o.top,left:o.left,bottom:o.bottom,right:o.right,sheetName:o.sheetName}:this.model={top:o.row,left:o.col,bottom:o.row,right:o.col,sheetName:o.sheetName}}break}case 0:this.model={top:0,left:0,bottom:0,right:0};break;default:throw new Error("Invalid number of arguments to _getDimensions() - "+i.length)}}get top(){return this.model.top||1}set top(i){this.model.top=i}get left(){return this.model.left||1}set left(i){this.model.left=i}get bottom(){return this.model.bottom||1}set bottom(i){this.model.bottom=i}get right(){return this.model.right||1}set right(i){this.model.right=i}get sheetName(){return this.model.sheetName}set sheetName(i){this.model.sheetName=i}get _serialisedSheetName(){const{sheetName:i}=this.model;return i?/^[a-zA-Z0-9]*$/.test(i)?i+"!":`'${i}'!`:""}expand(i,n,o,h){(!this.model.top||i<this.top)&&(this.top=i),(!this.model.left||n<this.left)&&(this.left=n),(!this.model.bottom||o>this.bottom)&&(this.bottom=o),(!this.model.right||h>this.right)&&(this.right=h)}expandRow(i){if(i){const{dimensions:n,number:o}=i;n&&this.expand(o,n.min,o,n.max)}}expandToAddress(i){const n=c.decodeEx(i);this.expand(n.row,n.col,n.row,n.col)}get tl(){return c.n2l(this.left)+this.top}get $t$l(){return`$${c.n2l(this.left)}$${this.top}`}get br(){return c.n2l(this.right)+this.bottom}get $b$r(){return`$${c.n2l(this.right)}$${this.bottom}`}get range(){return`${this._serialisedSheetName+this.tl}:${this.br}`}get $range(){return`${this._serialisedSheetName+this.$t$l}:${this.$b$r}`}get shortRange(){return this.count>1?this.range:this._serialisedSheetName+this.tl}get $shortRange(){return this.count>1?this.$range:this._serialisedSheetName+this.$t$l}get count(){return(1+this.bottom-this.top)*(1+this.right-this.left)}toString(){return this.range}intersects(i){return(!i.sheetName||!this.sheetName||i.sheetName===this.sheetName)&&!(i.bottom<this.top)&&!(i.top>this.bottom)&&!(i.right<this.left)&&!(i.left>this.right)}contains(i){const n=c.decodeEx(i);return this.containsEx(n)}containsEx(i){return(!i.sheetName||!this.sheetName||i.sheetName===this.sheetName)&&i.row>=this.top&&i.row<=this.bottom&&i.col>=this.left&&i.col<=this.right}forEachAddress(i){for(let n=this.left;n<=this.right;n++)for(let o=this.top;o<=this.bottom;o++)i(c.encodeAddress(o,n),o,n)}}a.exports=s},{"../utils/col-cache":19}],11:[function(e,a,f){const c=e("../utils/under-dash"),s=e("./enums"),l=e("../utils/col-cache"),i=e("./cell");a.exports=class{constructor(n,o){this._worksheet=n,this._number=o,this._cells=[],this.style={},this.outlineLevel=0}get number(){return this._number}get worksheet(){return this._worksheet}commit(){this._worksheet._commitRow(this)}destroy(){delete this._worksheet,delete this._cells,delete this.style}findCell(n){return this._cells[n-1]}getCellEx(n){let o=this._cells[n.col-1];if(!o){const h=this._worksheet.getColumn(n.col);o=new i(this,h,n.address),this._cells[n.col-1]=o}return o}getCell(n){if(typeof n=="string"){const o=this._worksheet.getColumnKey(n);n=o?o.number:l.l2n(n)}return this._cells[n-1]||this.getCellEx({address:l.encodeAddress(this._number,n),row:this._number,col:n})}splice(n,o){const h=n+o;for(var u=arguments.length,d=new Array(u>2?u-2:0),m=2;m<u;m++)d[m-2]=arguments[m];const b=d.length-o,p=this._cells.length;let v,g,x;if(b<0)for(v=n+d.length;v<=p;v++)x=this._cells[v-1],g=this._cells[v-b-1],g?(x=this.getCell(v),x.value=g.value,x.style=g.style,x._comment=g._comment):x&&(x.value=null,x.style={},x._comment=void 0);else if(b>0)for(v=p;v>=h;v--)g=this._cells[v-1],g?(x=this.getCell(v+b),x.value=g.value,x.style=g.style,x._comment=g._comment):this._cells[v+b-1]=void 0;for(v=0;v<d.length;v++)x=this.getCell(n+v),x.value=d[v],x.style={},x._comment=void 0}eachCell(n,o){if(o||(o=n,n=null),n&&n.includeEmpty){const h=this._cells.length;for(let u=1;u<=h;u++)o(this.getCell(u),u)}else this._cells.forEach((h,u)=>{h&&h.type!==s.ValueType.Null&&o(h,u+1)})}addPageBreak(n,o){const h=this._worksheet,u=Math.max(0,n-1)||0,d=Math.max(0,o-1)||16838,m={id:this._number,max:d,man:1};u&&(m.min=u),h.rowBreaks.push(m)}get values(){const n=[];return this._cells.forEach(o=>{o&&o.type!==s.ValueType.Null&&(n[o.col]=o.value)}),n}set values(n){if(this._cells=[],n)if(n instanceof Array){let o=0;n.hasOwnProperty("0")&&(o=1),n.forEach((h,u)=>{h!==void 0&&(this.getCellEx({address:l.encodeAddress(this._number,u+o),row:this._number,col:u+o}).value=h)})}else this._worksheet.eachColumnKey((o,h)=>{n[h]!==void 0&&(this.getCellEx({address:l.encodeAddress(this._number,o.number),row:this._number,col:o.number}).value=n[h])})}get hasValues(){return c.some(this._cells,n=>n&&n.type!==s.ValueType.Null)}get cellCount(){return this._cells.length}get actualCellCount(){let n=0;return this.eachCell(()=>{n++}),n}get dimensions(){let n=0,o=0;return this._cells.forEach(h=>{h&&h.type!==s.ValueType.Null&&((!n||n>h.col)&&(n=h.col),o<h.col&&(o=h.col))}),n>0?{min:n,max:o}:null}_applyStyle(n,o){return this.style[n]=o,this._cells.forEach(h=>{h&&(h[n]=o)}),o}get numFmt(){return this.style.numFmt}set numFmt(n){this._applyStyle("numFmt",n)}get font(){return this.style.font}set font(n){this._applyStyle("font",n)}get alignment(){return this.style.alignment}set alignment(n){this._applyStyle("alignment",n)}get protection(){return this.style.protection}set protection(n){this._applyStyle("protection",n)}get border(){return this.style.border}set border(n){this._applyStyle("border",n)}get fill(){return this.style.fill}set fill(n){this._applyStyle("fill",n)}get hidden(){return!!this._hidden}set hidden(n){this._hidden=n}get outlineLevel(){return this._outlineLevel||0}set outlineLevel(n){this._outlineLevel=n}get collapsed(){return!!(this._outlineLevel&&this._outlineLevel>=this._worksheet.properties.outlineLevelRow)}get model(){const n=[];let o=0,h=0;return this._cells.forEach(u=>{if(u){const d=u.model;d&&((!o||o>u.col)&&(o=u.col),h<u.col&&(h=u.col),n.push(d))}}),this.height||n.length?{cells:n,number:this.number,min:o,max:h,height:this.height,style:this.style,hidden:this.hidden,outlineLevel:this.outlineLevel,collapsed:this.collapsed}:null}set model(n){if(n.number!==this._number)throw new Error("Invalid row number in model");let o;this._cells=[],n.cells.forEach(h=>{switch(h.type){case i.Types.Merge:break;default:{let u;if(h.address)u=l.decodeAddress(h.address);else if(o){const{row:d}=o,m=o.col+1;u={row:d,col:m,address:l.encodeAddress(d,m),$col$row:`$${l.n2l(m)}$${d}`}}o=u,this.getCellEx(u).model=h;break}}}),n.height?this.height=n.height:delete this.height,this.hidden=n.hidden,this.outlineLevel=n.outlineLevel||0,this.style=n.style&&JSON.parse(JSON.stringify(n.style))||{}}}},{"../utils/col-cache":19,"../utils/under-dash":26,"./cell":3,"./enums":7}],12:[function(e,a,f){const c=e("../utils/col-cache");class s{constructor(i,n,o){this.table=i,this.column=n,this.index=o}_set(i,n){this.table.cacheState(),this.column[i]=n}get name(){return this.column.name}set name(i){this._set("name",i)}get filterButton(){return this.column.filterButton}set filterButton(i){this.column.filterButton=i}get style(){return this.column.style}set style(i){this.column.style=i}get totalsRowLabel(){return this.column.totalsRowLabel}set totalsRowLabel(i){this._set("totalsRowLabel",i)}get totalsRowFunction(){return this.column.totalsRowFunction}set totalsRowFunction(i){this._set("totalsRowFunction",i)}get totalsRowResult(){return this.column.totalsRowResult}set totalsRowResult(i){this._set("totalsRowResult",i)}get totalsRowFormula(){return this.column.totalsRowFormula}set totalsRowFormula(i){this._set("totalsRowFormula",i)}}a.exports=class{constructor(l,i){this.worksheet=l,i&&(this.table=i,this.validate(),this.store())}getFormula(l){switch(l.totalsRowFunction){case"none":return null;case"average":return`SUBTOTAL(101,${this.table.name}[${l.name}])`;case"countNums":return`SUBTOTAL(102,${this.table.name}[${l.name}])`;case"count":return`SUBTOTAL(103,${this.table.name}[${l.name}])`;case"max":return`SUBTOTAL(104,${this.table.name}[${l.name}])`;case"min":return`SUBTOTAL(105,${this.table.name}[${l.name}])`;case"stdDev":return`SUBTOTAL(106,${this.table.name}[${l.name}])`;case"var":return`SUBTOTAL(107,${this.table.name}[${l.name}])`;case"sum":return`SUBTOTAL(109,${this.table.name}[${l.name}])`;case"custom":return l.totalsRowFormula;default:throw new Error("Invalid Totals Row Function: "+l.totalsRowFunction)}}get width(){return this.table.columns.length}get height(){return this.table.rows.length}get filterHeight(){return this.height+(this.table.headerRow?1:0)}get tableHeight(){return this.filterHeight+(this.table.totalsRow?1:0)}validate(){const{table:l}=this,i=(b,p,v)=>{b[p]===void 0&&(b[p]=v)};i(l,"headerRow",!0),i(l,"totalsRow",!1),i(l,"style",{}),i(l.style,"theme","TableStyleMedium2"),i(l.style,"showFirstColumn",!1),i(l.style,"showLastColumn",!1),i(l.style,"showRowStripes",!1),i(l.style,"showColumnStripes",!1);const n=(b,p)=>{if(!b)throw new Error(p)};n(l.ref,"Table must have ref"),n(l.columns,"Table must have column definitions"),n(l.rows,"Table must have row definitions"),l.tl=c.decodeAddress(l.ref);const{row:o,col:h}=l.tl;n(o>0,"Table must be on valid row"),n(h>0,"Table must be on valid col");const{width:u,filterHeight:d,tableHeight:m}=this;l.autoFilterRef=c.encode(o,h,o+d-1,h+u-1),l.tableRef=c.encode(o,h,o+m-1,h+u-1),l.columns.forEach((b,p)=>{n(b.name,`Column ${p} must have a name`),p===0?i(b,"totalsRowLabel","Total"):(i(b,"totalsRowFunction","none"),b.totalsRowFormula=this.getFormula(b))})}store(){const l=(d,m)=>{m&&Object.keys(m).forEach(b=>{d[b]=m[b]})},{worksheet:i,table:n}=this,{row:o,col:h}=n.tl;let u=0;if(n.headerRow){const d=i.getRow(o+u++);n.columns.forEach((m,b)=>{const{style:p,name:v}=m,g=d.getCell(h+b);g.value=v,l(g,p)})}if(n.rows.forEach(d=>{const m=i.getRow(o+u++);d.forEach((b,p)=>{const v=m.getCell(h+p);v.value=b,l(v,n.columns[p].style)})}),n.totalsRow){const d=i.getRow(o+u++);n.columns.forEach((m,b)=>{const p=d.getCell(h+b);if(b===0)p.value=m.totalsRowLabel;else{const v=this.getFormula(m);p.value=v?{formula:m.totalsRowFormula,result:m.totalsRowResult}:null}l(p,m.style)})}}load(l){const{table:i}=this,{row:n,col:o}=i.tl;let h=0;if(i.headerRow){const u=l.getRow(n+h++);i.columns.forEach((d,m)=>{u.getCell(o+m).value=d.name})}if(i.rows.forEach(u=>{const d=l.getRow(n+h++);u.forEach((m,b)=>{d.getCell(o+b).value=m})}),i.totalsRow){const u=l.getRow(n+h++);i.columns.forEach((d,m)=>{const b=u.getCell(o+m);m===0?b.value=d.totalsRowLabel:this.getFormula(d)&&(b.value={formula:d.totalsRowFormula,result:d.totalsRowResult})})}}get model(){return this.table}set model(l){this.table=l}cacheState(){this._cache||(this._cache={ref:this.ref,width:this.width,tableHeight:this.tableHeight})}commit(){if(!this._cache)return;this.validate();const l=c.decodeAddress(this._cache.ref);if(this.ref!==this._cache.ref)for(let i=0;i<this._cache.tableHeight;i++){const n=this.worksheet.getRow(l.row+i);for(let o=0;o<this._cache.width;o++)n.getCell(l.col+o).value=null}else{for(let i=this.tableHeight;i<this._cache.tableHeight;i++){const n=this.worksheet.getRow(l.row+i);for(let o=0;o<this._cache.width;o++)n.getCell(l.col+o).value=null}for(let i=0;i<this.tableHeight;i++){const n=this.worksheet.getRow(l.row+i);for(let o=this.width;o<this._cache.width;o++)n.getCell(l.col+o).value=null}}this.store()}addRow(l,i){this.cacheState(),i===void 0?this.table.rows.push(l):this.table.rows.splice(i,0,l)}removeRows(l){let i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;this.cacheState(),this.table.rows.splice(l,i)}getColumn(l){const i=this.table.columns[l];return new s(this,i,l)}addColumn(l,i,n){this.cacheState(),n===void 0?(this.table.columns.push(l),this.table.rows.forEach((o,h)=>{o.push(i[h])})):(this.table.columns.splice(n,0,l),this.table.rows.forEach((o,h)=>{o.splice(n,0,i[h])}))}removeColumns(l){let i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;this.cacheState(),this.table.columns.splice(l,i),this.table.rows.forEach(n=>{n.splice(l,i)})}_assign(l,i,n){this.cacheState(),l[i]=n}get ref(){return this.table.ref}set ref(l){this._assign(this.table,"ref",l)}get name(){return this.table.name}set name(l){this.table.name=l}get displayName(){return this.table.displyName||this.table.name}set displayNamename(l){this.table.displayName=l}get headerRow(){return this.table.headerRow}set headerRow(l){this._assign(this.table,"headerRow",l)}get totalsRow(){return this.table.totalsRow}set totalsRow(l){this._assign(this.table,"totalsRow",l)}get theme(){return this.table.style.name}set theme(l){this.table.style.name=l}get showFirstColumn(){return this.table.style.showFirstColumn}set showFirstColumn(l){this.table.style.showFirstColumn=l}get showLastColumn(){return this.table.style.showLastColumn}set showLastColumn(l){this.table.style.showLastColumn=l}get showRowStripes(){return this.table.style.showRowStripes}set showRowStripes(l){this.table.style.showRowStripes=l}get showColumnStripes(){return this.table.style.showColumnStripes}set showColumnStripes(l){this.table.style.showColumnStripes=l}}},{"../utils/col-cache":19}],13:[function(e,a,f){const c=e("./worksheet"),s=e("./defined-names"),l=e("../xlsx/xlsx"),i=e("../csv/csv");a.exports=class{constructor(){this.category="",this.company="",this.created=new Date,this.description="",this.keywords="",this.manager="",this.modified=this.created,this.properties={},this.calcProperties={},this._worksheets=[],this.subject="",this.title="",this.views=[],this.media=[],this._definedNames=new s}get xlsx(){return this._xlsx||(this._xlsx=new l(this)),this._xlsx}get csv(){return this._csv||(this._csv=new i(this)),this._csv}get nextId(){for(let n=1;n<this._worksheets.length;n++)if(!this._worksheets[n])return n;return this._worksheets.length||1}addWorksheet(n,o){const h=this.nextId;o&&(typeof o=="string"?(console.trace('tabColor argument is now deprecated. Please use workbook.addWorksheet(name, {properties: { tabColor: { argb: "rbg value" } }'),o={properties:{tabColor:{argb:o}}}):(o.argb||o.theme||o.indexed)&&(console.trace("tabColor argument is now deprecated. Please use workbook.addWorksheet(name, {properties: { tabColor: { ... } }"),o={properties:{tabColor:o}}));const u=this._worksheets.reduce((b,p)=>(p&&p.orderNo)>b?p.orderNo:b,0),d=Object.assign({},o,{id:h,name:n,orderNo:u+1,workbook:this}),m=new c(d);return this._worksheets[h]=m,m}removeWorksheetEx(n){delete this._worksheets[n.id]}removeWorksheet(n){const o=this.getWorksheet(n);o&&o.destroy()}getWorksheet(n){return n===void 0?this._worksheets.find(Boolean):typeof n=="number"?this._worksheets[n]:typeof n=="string"?this._worksheets.find(o=>o&&o.name===n):void 0}get worksheets(){return this._worksheets.slice(1).sort((n,o)=>n.orderNo-o.orderNo).filter(Boolean)}eachSheet(n){this.worksheets.forEach(o=>{n(o,o.id)})}get definedNames(){return this._definedNames}clearThemes(){this._themes=void 0}addImage(n){const o=this.media.length;return this.media.push(Object.assign({},n,{type:"image"})),o}getImage(n){return this.media[n]}get model(){return{creator:this.creator||"Unknown",lastModifiedBy:this.lastModifiedBy||"Unknown",lastPrinted:this.lastPrinted,created:this.created,modified:this.modified,properties:this.properties,worksheets:this.worksheets.map(n=>n.model),sheets:this.worksheets.map(n=>n.model).filter(Boolean),definedNames:this._definedNames.model,views:this.views,company:this.company,manager:this.manager,title:this.title,subject:this.subject,keywords:this.keywords,category:this.category,description:this.description,language:this.language,revision:this.revision,contentStatus:this.contentStatus,themes:this._themes,media:this.media,calcProperties:this.calcProperties}}set model(n){this.creator=n.creator,this.lastModifiedBy=n.lastModifiedBy,this.lastPrinted=n.lastPrinted,this.created=n.created,this.modified=n.modified,this.company=n.company,this.manager=n.manager,this.title=n.title,this.subject=n.subject,this.keywords=n.keywords,this.category=n.category,this.description=n.description,this.language=n.language,this.revision=n.revision,this.contentStatus=n.contentStatus,this.properties=n.properties,this.calcProperties=n.calcProperties,this._worksheets=[],n.worksheets.forEach(o=>{const{id:h,name:u,state:d}=o,m=n.sheets&&n.sheets.findIndex(b=>b.id===h);(this._worksheets[h]=new c({id:h,name:u,orderNo:m,state:d,workbook:this})).model=o}),this._definedNames.model=n.definedNames,this.views=n.views,this._themes=n.themes,this.media=n.media||[]}}},{"../csv/csv":1,"../xlsx/xlsx":144,"./defined-names":6,"./worksheet":14}],14:[function(e,a,f){const c=e("../utils/under-dash"),s=e("../utils/col-cache"),l=e("./range"),i=e("./row"),n=e("./column"),o=e("./enums"),h=e("./image"),u=e("./table"),d=e("./data-validations"),m=e("../utils/encryptor"),{copyStyle:b}=e("../utils/copy-style");a.exports=class{constructor(p){p=p||{},this._workbook=p.workbook,this.id=p.id,this.orderNo=p.orderNo,this.name=p.name,this.state=p.state||"visible",this._rows=[],this._columns=null,this._keys={},this._merges={},this.rowBreaks=[],this.properties=Object.assign({},{defaultRowHeight:15,dyDescent:55,outlineLevelCol:0,outlineLevelRow:0},p.properties),this.pageSetup=Object.assign({},{margins:{left:.7,right:.7,top:.75,bottom:.75,header:.3,footer:.3},orientation:"portrait",horizontalDpi:4294967295,verticalDpi:4294967295,fitToPage:!(!p.pageSetup||!p.pageSetup.fitToWidth&&!p.pageSetup.fitToHeight||p.pageSetup.scale),pageOrder:"downThenOver",blackAndWhite:!1,draft:!1,cellComments:"None",errors:"displayed",scale:100,fitToWidth:1,fitToHeight:1,paperSize:void 0,showRowColHeaders:!1,showGridLines:!1,firstPageNumber:void 0,horizontalCentered:!1,verticalCentered:!1,rowBreaks:null,colBreaks:null},p.pageSetup),this.headerFooter=Object.assign({},{differentFirst:!1,differentOddEven:!1,oddHeader:null,oddFooter:null,evenHeader:null,evenFooter:null,firstHeader:null,firstFooter:null},p.headerFooter),this.dataValidations=new d,this.views=p.views||[],this.autoFilter=p.autoFilter||null,this._media=[],this.sheetProtection=null,this.tables={},this.conditionalFormattings=[]}get name(){return this._name}set name(p){if(p===void 0&&(p="sheet"+this.id),this._name!==p){if(typeof p!="string")throw new Error("The name has to be a string.");if(p==="")throw new Error("The name can't be empty.");if(p==="History")throw new Error('The name "History" is protected. Please use a different name.');if(/[*?:/\\[\]]/.test(p))throw new Error(`Worksheet name ${p} cannot include any of the following characters: * ? : \\ / [ ]`);if(/(^')|('$)/.test(p))throw new Error("The first or last character of worksheet name cannot be a single quotation mark: "+p);if(p&&p.length>31&&(console.warn(`Worksheet name ${p} exceeds 31 chars. This will be truncated`),p=p.substring(0,31)),this._workbook._worksheets.find(v=>v&&v.name.toLowerCase()===p.toLowerCase()))throw new Error("Worksheet name already exists: "+p);this._name=p}}get workbook(){return this._workbook}destroy(){this._workbook.removeWorksheetEx(this)}get dimensions(){const p=new l;return this._rows.forEach(v=>{if(v){const g=v.dimensions;g&&p.expand(v.number,g.min,v.number,g.max)}}),p}get columns(){return this._columns}set columns(p){this._headerRowCount=p.reduce((x,C)=>{const T=(C.header?1:C.headers&&C.headers.length)||0;return Math.max(x,T)},0);let v=1;const g=this._columns=[];p.forEach(x=>{const C=new n(this,v++,!1);g.push(C),C.defn=x})}getColumnKey(p){return this._keys[p]}setColumnKey(p,v){this._keys[p]=v}deleteColumnKey(p){delete this._keys[p]}eachColumnKey(p){c.each(this._keys,p)}getColumn(p){if(typeof p=="string"){const v=this._keys[p];if(v)return v;p=s.l2n(p)}if(this._columns||(this._columns=[]),p>this._columns.length){let v=this._columns.length+1;for(;v<=p;)this._columns.push(new n(this,v++))}return this._columns[p-1]}spliceColumns(p,v){const g=this._rows.length;for(var x=arguments.length,C=new Array(x>2?x-2:0),T=2;T<x;T++)C[T-2]=arguments[T];if(C.length>0)for(let F=0;F<g;F++){const L=[p,v];C.forEach(z=>{L.push(z[F]||null)});const V=this.getRow(F+1);V.splice.apply(V,L)}else this._rows.forEach(F=>{F&&F.splice(p,v)});const R=C.length-v,B=p+v,I=this._columns.length;if(R<0)for(let F=p+C.length;F<=I;F++)this.getColumn(F).defn=this.getColumn(F-R).defn;else if(R>0)for(let F=I;F>=B;F--)this.getColumn(F+R).defn=this.getColumn(F).defn;for(let F=p;F<p+C.length;F++)this.getColumn(F).defn=null;this.workbook.definedNames.spliceColumns(this.name,p,v,C.length)}get lastColumn(){return this.getColumn(this.columnCount)}get columnCount(){let p=0;return this.eachRow(v=>{p=Math.max(p,v.cellCount)}),p}get actualColumnCount(){const p=[];let v=0;return this.eachRow(g=>{g.eachCell(x=>{let{col:C}=x;p[C]||(p[C]=!0,v++)})}),v}_commitRow(){}get _lastRowNumber(){const p=this._rows;let v=p.length;for(;v>0&&p[v-1]===void 0;)v--;return v}get _nextRow(){return this._lastRowNumber+1}get lastRow(){if(this._rows.length)return this._rows[this._rows.length-1]}findRow(p){return this._rows[p-1]}findRows(p,v){return this._rows.slice(p-1,p-1+v)}get rowCount(){return this._lastRowNumber}get actualRowCount(){let p=0;return this.eachRow(()=>{p++}),p}getRow(p){let v=this._rows[p-1];return v||(v=this._rows[p-1]=new i(this,p)),v}getRows(p,v){if(v<1)return;const g=[];for(let x=p;x<p+v;x++)g.push(this.getRow(x));return g}addRow(p){let v=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";const g=this._nextRow,x=this.getRow(g);return x.values=p,this._setStyleOption(g,v[0]==="i"?v:"n"),x}addRows(p){let v=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";const g=[];return p.forEach(x=>{g.push(this.addRow(x,v))}),g}insertRow(p,v){let g=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"n";return this.spliceRows(p,0,v),this._setStyleOption(p,g),this.getRow(p)}insertRows(p,v){let g=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"n";if(this.spliceRows(p,0,...v),g!=="n")for(let x=0;x<v.length;x++)g[0]==="o"&&this.findRow(v.length+p+x)!==void 0?this._copyStyle(v.length+p+x,p+x,g[1]==="+"):g[0]==="i"&&this.findRow(p-1)!==void 0&&this._copyStyle(p-1,p+x,g[1]==="+");return this.getRows(p,v.length)}_setStyleOption(p){let v=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";v[0]==="o"&&this.findRow(p+1)!==void 0?this._copyStyle(p+1,p,v[1]==="+"):v[0]==="i"&&this.findRow(p-1)!==void 0&&this._copyStyle(p-1,p,v[1]==="+")}_copyStyle(p,v){let g=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const x=this.getRow(p),C=this.getRow(v);C.style=b(x.style),x.eachCell({includeEmpty:g},(T,R)=>{C.getCell(R).style=b(T.style)}),C.height=x.height}duplicateRow(p,v){let g=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const x=this._rows[p-1],C=new Array(v).fill(x.values);this.spliceRows(p+1,g?0:v,...C);for(let T=0;T<v;T++){const R=this._rows[p+T];R.style=x.style,R.height=x.height,x.eachCell({includeEmpty:!0},(B,I)=>{R.getCell(I).style=B.style})}}spliceRows(p,v){const g=p+v;for(var x=arguments.length,C=new Array(x>2?x-2:0),T=2;T<x;T++)C[T-2]=arguments[T];const R=C.length,B=R-v,I=this._rows.length;let F,L;if(B<0)for(p===I&&(this._rows[I-1]=void 0),F=g;F<=I;F++)if(L=this._rows[F-1],L){const V=this.getRow(F+B);V.values=L.values,V.style=L.style,V.height=L.height,L.eachCell({includeEmpty:!0},(z,E)=>{V.getCell(E).style=z.style}),this._rows[F-1]=void 0}else this._rows[F+B-1]=void 0;else if(B>0)for(F=I;F>=g;F--)if(L=this._rows[F-1],L){const V=this.getRow(F+B);V.values=L.values,V.style=L.style,V.height=L.height,L.eachCell({includeEmpty:!0},(z,E)=>{if(V.getCell(E).style=z.style,z._value.constructor.name==="MergeValue"){const P=this.getRow(z._row._number+R).getCell(E),k=z._value._master,y=this.getRow(k._row._number+R).getCell(k._column._number);P.merge(y)}})}else this._rows[F+B-1]=void 0;for(F=0;F<R;F++){const V=this.getRow(p+F);V.style={},V.values=C[F]}this.workbook.definedNames.spliceRows(this.name,p,v,R)}eachRow(p,v){if(v||(v=p,p=void 0),p&&p.includeEmpty){const g=this._rows.length;for(let x=1;x<=g;x++)v(this.getRow(x),x)}else this._rows.forEach(g=>{g&&g.hasValues&&v(g,g.number)})}getSheetValues(){const p=[];return this._rows.forEach(v=>{v&&(p[v.number]=v.values)}),p}findCell(p,v){const g=s.getAddress(p,v),x=this._rows[g.row-1];return x?x.findCell(g.col):void 0}getCell(p,v){const g=s.getAddress(p,v);return this.getRow(g.row).getCellEx(g)}mergeCells(){for(var p=arguments.length,v=new Array(p),g=0;g<p;g++)v[g]=arguments[g];const x=new l(v);this._mergeCellsInternal(x)}mergeCellsWithoutStyle(){for(var p=arguments.length,v=new Array(p),g=0;g<p;g++)v[g]=arguments[g];const x=new l(v);this._mergeCellsInternal(x,!0)}_mergeCellsInternal(p,v){c.each(this._merges,x=>{if(x.intersects(p))throw new Error("Cannot merge already merged cells")});const g=this.getCell(p.top,p.left);for(let x=p.top;x<=p.bottom;x++)for(let C=p.left;C<=p.right;C++)(x>p.top||C>p.left)&&this.getCell(x,C).merge(g,v);this._merges[g.address]=p}_unMergeMaster(p){const v=this._merges[p.address];if(v){for(let g=v.top;g<=v.bottom;g++)for(let x=v.left;x<=v.right;x++)this.getCell(g,x).unmerge();delete this._merges[p.address]}}get hasMerges(){return c.some(this._merges,Boolean)}unMergeCells(){for(var p=arguments.length,v=new Array(p),g=0;g<p;g++)v[g]=arguments[g];const x=new l(v);for(let C=x.top;C<=x.bottom;C++)for(let T=x.left;T<=x.right;T++){const R=this.findCell(C,T);R&&(R.type===o.ValueType.Merge?this._unMergeMaster(R.master):this._merges[R.address]&&this._unMergeMaster(R))}}fillFormula(p,v,g){let x=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"shared";const C=s.decode(p),{top:T,left:R,bottom:B,right:I}=C,F=I-R+1,L=s.encodeAddress(T,R),V=x==="shared";let z;z=typeof g=="function"?g:Array.isArray(g)?Array.isArray(g[0])?(P,k)=>g[P-T][k-R]:(P,k)=>g[(P-T)*F+(k-R)]:()=>{};let E=!0;for(let P=T;P<=B;P++)for(let k=R;k<=I;k++)E?(this.getCell(P,k).value={shareType:x,formula:v,ref:p,result:z(P,k)},E=!1):this.getCell(P,k).value=V?{sharedFormula:L,result:z(P,k)}:z(P,k)}addImage(p,v){const g={type:"image",imageId:p,range:v};this._media.push(new h(this,g))}getImages(){return this._media.filter(p=>p.type==="image")}addBackgroundImage(p){const v={type:"background",imageId:p};this._media.push(new h(this,v))}getBackgroundImageId(){const p=this._media.find(v=>v.type==="background");return p&&p.imageId}protect(p,v){return new Promise(g=>{this.sheetProtection={sheet:!0},v&&"spinCount"in v&&(v.spinCount=Number.isFinite(v.spinCount)?Math.round(Math.max(0,v.spinCount)):1e5),p&&(this.sheetProtection.algorithmName="SHA-512",this.sheetProtection.saltValue=m.randomBytes(16).toString("base64"),this.sheetProtection.spinCount=v&&"spinCount"in v?v.spinCount:1e5,this.sheetProtection.hashValue=m.convertPasswordToHash(p,"SHA512",this.sheetProtection.saltValue,this.sheetProtection.spinCount)),v&&(this.sheetProtection=Object.assign(this.sheetProtection,v),!p&&"spinCount"in v&&delete this.sheetProtection.spinCount),g()})}unprotect(){this.sheetProtection=null}addTable(p){const v=new u(this,p);return this.tables[p.name]=v,v}getTable(p){return this.tables[p]}removeTable(p){delete this.tables[p]}getTables(){return Object.values(this.tables)}addConditionalFormatting(p){this.conditionalFormattings.push(p)}removeConditionalFormatting(p){typeof p=="number"?this.conditionalFormattings.splice(p,1):this.conditionalFormattings=p instanceof Function?this.conditionalFormattings.filter(p):[]}get tabColor(){return console.trace("worksheet.tabColor property is now deprecated. Please use worksheet.properties.tabColor"),this.properties.tabColor}set tabColor(p){console.trace("worksheet.tabColor property is now deprecated. Please use worksheet.properties.tabColor"),this.properties.tabColor=p}get model(){const p={id:this.id,name:this.name,dataValidations:this.dataValidations.model,properties:this.properties,state:this.state,pageSetup:this.pageSetup,headerFooter:this.headerFooter,rowBreaks:this.rowBreaks,views:this.views,autoFilter:this.autoFilter,media:this._media.map(x=>x.model),sheetProtection:this.sheetProtection,tables:Object.values(this.tables).map(x=>x.model),conditionalFormattings:this.conditionalFormattings};p.cols=n.toModel(this.columns);const v=p.rows=[],g=p.dimensions=new l;return this._rows.forEach(x=>{const C=x&&x.model;C&&(g.expand(C.number,C.min,C.number,C.max),v.push(C))}),p.merges=[],c.each(this._merges,x=>{p.merges.push(x.range)}),p}_parseRows(p){this._rows=[],p.rows.forEach(v=>{const g=new i(this,v.number);this._rows[g.number-1]=g,g.model=v})}_parseMergeCells(p){c.each(p.mergeCells,v=>{this.mergeCellsWithoutStyle(v)})}set model(p){this.name=p.name,this._columns=n.fromModel(this,p.cols),this._parseRows(p),this._parseMergeCells(p),this.dataValidations=new d(p.dataValidations),this.properties=p.properties,this.pageSetup=p.pageSetup,this.headerFooter=p.headerFooter,this.views=p.views,this.autoFilter=p.autoFilter,this._media=p.media.map(v=>new h(this,v)),this.sheetProtection=p.sheetProtection,this.tables=p.tables.reduce((v,g)=>{const x=new u;return x.model=g,v[g.name]=x,v},{}),this.conditionalFormattings=p.conditionalFormattings}}},{"../utils/col-cache":19,"../utils/copy-style":20,"../utils/encryptor":21,"../utils/under-dash":26,"./column":4,"./data-validations":5,"./enums":7,"./image":8,"./range":10,"./row":11,"./table":12}],15:[function(e,a,f){e("core-js/modules/es.promise"),e("core-js/modules/es.promise.finally"),e("core-js/modules/es.object.assign"),e("core-js/modules/es.object.keys"),e("core-js/modules/es.object.values"),e("core-js/modules/es.symbol"),e("core-js/modules/es.symbol.async-iterator"),e("core-js/modules/es.array.iterator"),e("core-js/modules/es.array.includes"),e("core-js/modules/es.array.find-index"),e("core-js/modules/es.array.find"),e("core-js/modules/es.string.from-code-point"),e("core-js/modules/es.string.includes"),e("core-js/modules/es.number.is-nan"),e("regenerator-runtime/runtime");const c={Workbook:e("./doc/workbook")},s=e("./doc/enums");Object.keys(s).forEach(l=>{c[l]=s[l]}),a.exports=c},{"./doc/enums":7,"./doc/workbook":13,"core-js/modules/es.array.find":359,"core-js/modules/es.array.find-index":358,"core-js/modules/es.array.includes":360,"core-js/modules/es.array.iterator":361,"core-js/modules/es.number.is-nan":363,"core-js/modules/es.object.assign":364,"core-js/modules/es.object.keys":366,"core-js/modules/es.object.values":367,"core-js/modules/es.promise":372,"core-js/modules/es.promise.finally":371,"core-js/modules/es.string.from-code-point":376,"core-js/modules/es.string.includes":377,"core-js/modules/es.symbol":381,"core-js/modules/es.symbol.async-iterator":378,"regenerator-runtime/runtime":492}],16:[function(e,a,f){const c=typeof TextDecoder>"u"?null:new TextDecoder("utf-8");f.bufferToString=function(s){return typeof s=="string"?s:c?c.decode(s):s.toString()}},{}],17:[function(e,a,f){const c=typeof TextEncoder>"u"?null:new TextEncoder("utf-8"),{Buffer:s}=e("buffer");f.stringToBuffer=function(l){return typeof l!="string"?l:c?s.from(c.encode(l).buffer):s.from(l)}},{buffer:220}],18:[function(e,a,f){const c=e("./under-dash"),s=e("./col-cache");a.exports=class{constructor(l){this.template=l,this.sheets={}}addCell(l){this.addCellEx(s.decodeEx(l))}getCell(l){return this.findCellEx(s.decodeEx(l),!0)}findCell(l){return this.findCellEx(s.decodeEx(l),!1)}findCellAt(l,i,n){const o=this.sheets[l],h=o&&o[i];return h&&h[n]}addCellEx(l){if(l.top)for(let i=l.top;i<=l.bottom;i++)for(let n=l.left;n<=l.right;n++)this.getCellAt(l.sheetName,i,n);else this.findCellEx(l,!0)}getCellEx(l){return this.findCellEx(l,!0)}findCellEx(l,i){const n=this.findSheet(l,i),o=this.findSheetRow(n,l,i);return this.findRowCell(o,l,i)}getCellAt(l,i,n){const o=this.sheets[l]||(this.sheets[l]=[]),h=o[i]||(o[i]=[]);return h[n]||(h[n]={sheetName:l,address:s.n2l(n)+i,row:i,col:n})}removeCellEx(l){const i=this.findSheet(l);if(!i)return;const n=this.findSheetRow(i,l);n&&delete n[l.col]}forEachInSheet(l,i){const n=this.sheets[l];n&&n.forEach((o,h)=>{o&&o.forEach((u,d)=>{u&&i(u,h,d)})})}forEach(l){c.each(this.sheets,(i,n)=>{this.forEachInSheet(n,l)})}map(l){const i=[];return this.forEach(n=>{i.push(l(n))}),i}findSheet(l,i){const n=l.sheetName;return this.sheets[n]?this.sheets[n]:i?this.sheets[n]=[]:void 0}findSheetRow(l,i,n){const{row:o}=i;return l&&l[o]?l[o]:n?l[o]=[]:void 0}findRowCell(l,i,n){const{col:o}=i;return l&&l[o]?l[o]:n?l[o]=this.template?Object.assign(i,JSON.parse(JSON.stringify(this.template))):i:void 0}spliceRows(l,i,n,o){const h=this.sheets[l];if(h){const u=[];for(let d=0;d<o;d++)u.push([]);h.splice(i,n,...u)}}spliceColumns(l,i,n,o){const h=this.sheets[l];if(h){const u=[];for(let d=0;d<o;d++)u.push(null);c.each(h,d=>{d.splice(i,n,...u)})}}}},{"./col-cache":19,"./under-dash":26}],19:[function(e,a,f){const c=/^[A-Z]+\d+$/,s={_dictionary:["A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"],_l2nFill:0,_l2n:{},_n2l:[],_level:l=>l<=26?1:l<=676?2:3,_fill(l){let i,n,o,h,u,d=1;if(l>=4)throw new Error("Out of bounds. Excel supports columns from 1 to 16384");if(this._l2nFill<1&&l>=1){for(;d<=26;)i=this._dictionary[d-1],this._n2l[d]=i,this._l2n[i]=d,d++;this._l2nFill=1}if(this._l2nFill<2&&l>=2){for(d=27;d<=702;)n=d-27,o=n%26,h=Math.floor(n/26),i=this._dictionary[h]+this._dictionary[o],this._n2l[d]=i,this._l2n[i]=d,d++;this._l2nFill=2}if(this._l2nFill<3&&l>=3){for(d=703;d<=16384;)n=d-703,o=n%26,h=Math.floor(n/26)%26,u=Math.floor(n/676),i=this._dictionary[u]+this._dictionary[h]+this._dictionary[o],this._n2l[d]=i,this._l2n[i]=d,d++;this._l2nFill=3}},l2n(l){if(this._l2n[l]||this._fill(l.length),!this._l2n[l])throw new Error("Out of bounds. Invalid column letter: "+l);return this._l2n[l]},n2l(l){if(l<1||l>16384)throw new Error(l+" is out of bounds. Excel supports columns from 1 to 16384");return this._n2l[l]||this._fill(this._level(l)),this._n2l[l]},_hash:{},validateAddress(l){if(!c.test(l))throw new Error("Invalid Address: "+l);return!0},decodeAddress(l){const i=l.length<5&&this._hash[l];if(i)return i;let n=!1,o="",h=0,u=!1,d="",m=0;for(let p,v=0;v<l.length;v++)if(p=l.charCodeAt(v),!u&&p>=65&&p<=90)n=!0,o+=l[v],h=26*h+p-64;else if(p>=48&&p<=57)u=!0,d+=l[v],m=10*m+p-48;else if(u&&n&&p!==36)break;if(n){if(h>16384)throw new Error("Out of bounds. Invalid column letter: "+o)}else h=void 0;u||(m=void 0);const b={address:l=o+d,col:h,row:m,$col$row:`$${o}$${d}`};return h<=100&&m<=100&&(this._hash[l]=b,this._hash[b.$col$row]=b),b},getAddress(l,i){if(i){const n=this.n2l(i)+l;return this.decodeAddress(n)}return this.decodeAddress(l)},decode(l){const i=l.split(":");if(i.length===2){const n=this.decodeAddress(i[0]),o=this.decodeAddress(i[1]),h={top:Math.min(n.row,o.row),left:Math.min(n.col,o.col),bottom:Math.max(n.row,o.row),right:Math.max(n.col,o.col)};return h.tl=this.n2l(h.left)+h.top,h.br=this.n2l(h.right)+h.bottom,h.dimensions=`${h.tl}:${h.br}`,h}return this.decodeAddress(l)},decodeEx(l){const i=l.match(/(?:(?:(?:'((?:[^']|'')*)')|([^'^ !]*))!)?(.*)/),n=i[1]||i[2],o=i[3],h=o.split(":");if(h.length>1){let d=this.decodeAddress(h[0]),m=this.decodeAddress(h[1]);const b=Math.min(d.row,m.row),p=Math.min(d.col,m.col),v=Math.max(d.row,m.row),g=Math.max(d.col,m.col);return d=this.n2l(p)+b,m=this.n2l(g)+v,{top:b,left:p,bottom:v,right:g,sheetName:n,tl:{address:d,col:p,row:b,$col$row:`$${this.n2l(p)}$${b}`,sheetName:n},br:{address:m,col:g,row:v,$col$row:`$${this.n2l(g)}$${v}`,sheetName:n},dimensions:`${d}:${m}`}}if(o.startsWith("#"))return n?{sheetName:n,error:o}:{error:o};const u=this.decodeAddress(o);return n?{sheetName:n,...u}:u},encodeAddress:(l,i)=>s.n2l(i)+l,encode(){switch(arguments.length){case 2:return s.encodeAddress(arguments[0],arguments[1]);case 4:return`${s.encodeAddress(arguments[0],arguments[1])}:${s.encodeAddress(arguments[2],arguments[3])}`;default:throw new Error("Can only encode with 2 or 4 arguments")}},inRange(l,i){const[n,o,,h,u]=l,[d,m]=i;return d>=n&&d<=h&&m>=o&&m<=u}};a.exports=s},{}],20:[function(e,a,f){const c=(l,i)=>({...l,...i.reduce((n,o)=>(l[o]&&(n[o]={...l[o]}),n),{})}),s=function(l,i,n){let o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[];l[n]&&(i[n]=c(l[n],o))};f.copyStyle=l=>{if(!l)return l;if(i=l,Object.keys(i).length===0)return{};var i;const n={...l};return s(l,n,"font",["color"]),s(l,n,"alignment"),s(l,n,"protection"),l.border&&(s(l,n,"border"),s(l.border,n.border,"top",["color"]),s(l.border,n.border,"left",["color"]),s(l.border,n.border,"bottom",["color"]),s(l.border,n.border,"right",["color"]),s(l.border,n.border,"diagonal",["color"])),l.fill&&(s(l,n,"fill",["fgColor","bgColor","center"]),l.fill.stops&&(n.fill.stops=l.fill.stops.map(o=>c(o,["color"])))),n}},{}],21:[function(e,a,f){(function(c){(function(){const s=e("crypto"),l={hash(i){const n=s.createHash(i);for(var o=arguments.length,h=new Array(o>1?o-1:0),u=1;u<o;u++)h[u-1]=arguments[u];return n.update(c.concat(h)),n.digest()},convertPasswordToHash(i,n,o,h){if(n=n.toLowerCase(),s.getHashes().indexOf(n)<0)throw new Error(`Hash algorithm '${n}' not supported!`);const u=c.from(i,"utf16le");let d=this.hash(n,c.from(o,"base64"),u);for(let m=0;m<h;m++){const b=c.alloc(4);b.writeUInt32LE(m,0),d=this.hash(n,d,b)}return d.toString("base64")},randomBytes:i=>s.randomBytes(i)};a.exports=l}).call(this)}).call(this,e("buffer").Buffer)},{buffer:220,crypto:390}],22:[function(e,a,f){const{SaxesParser:c}=e("saxes"),{PassThrough:s}=e("readable-stream"),{bufferToString:l}=e("./browser-buffer-decode");a.exports=async function*(i){i.pipe&&!i[Symbol.asyncIterator]&&(i=i.pipe(new s));const n=new c;let o;n.on("error",u=>{o=u});let h=[];n.on("opentag",u=>h.push({eventType:"opentag",value:u})),n.on("text",u=>h.push({eventType:"text",value:u})),n.on("closetag",u=>h.push({eventType:"closetag",value:u}));for await(const u of i){if(n.write(l(u)),o)throw o;yield h,h=[]}}},{"./browser-buffer-decode":16,"readable-stream":491,saxes:496}],23:[function(e,a,f){const c=e("./col-cache"),s=/(([a-z_\-0-9]*)!)?([a-z0-9_$]{2,})([(])?/gi,l=/^([$])?([a-z]+)([$])?([1-9][0-9]*)$/i;a.exports={slideFormula:function(i,n,o){const h=c.decode(n),u=c.decode(o);return i.replace(s,(d,m,b,p,v)=>{if(v)return d;const g=l.exec(p);if(g){const x=g[1],C=g[2].toUpperCase(),T=g[3],R=g[4];if(C.length>3||C.length===3&&C>"XFD")return d;let B=c.l2n(C),I=parseInt(R,10);return x||(B+=u.col-h.col),T||(I+=u.row-h.row),(m||"")+(x||"")+c.n2l(B)+(T||"")+I}return d})}}},{"./col-cache":19}],24:[function(e,a,f){(function(c,s){(function(){const l=e("readable-stream"),i=e("./utils"),n=e("./string-buf");class o{constructor(p,v){this._data=p,this._encoding=v}get length(){return this.toBuffer().length}copy(p,v,g,x){return this.toBuffer().copy(p,v,g,x)}toBuffer(){return this._buffer||(this._buffer=s.from(this._data,this._encoding)),this._buffer}}class h{constructor(p){this._data=p}get length(){return this._data.length}copy(p,v,g,x){return this._data._buf.copy(p,v,g,x)}toBuffer(){return this._data.toBuffer()}}class u{constructor(p){this._data=p}get length(){return this._data.length}copy(p,v,g,x){this._data.copy(p,v,g,x)}toBuffer(){return this._data}}class d{constructor(p){this.size=p,this.buffer=s.alloc(p),this.iRead=0,this.iWrite=0}toBuffer(){if(this.iRead===0&&this.iWrite===this.size)return this.buffer;const p=s.alloc(this.iWrite-this.iRead);return this.buffer.copy(p,0,this.iRead,this.iWrite),p}get length(){return this.iWrite-this.iRead}get eod(){return this.iRead===this.iWrite}get full(){return this.iWrite===this.size}read(p){let v;return p===0?null:p===void 0||p>=this.length?(v=this.toBuffer(),this.iRead=this.iWrite,v):(v=s.alloc(p),this.buffer.copy(v,0,this.iRead,p),this.iRead+=p,v)}write(p,v,g){const x=Math.min(g,this.size-this.iWrite);return p.copy(this.buffer,this.iWrite,v,v+x),this.iWrite+=x,x}}const m=function(b){b=b||{},this.bufSize=b.bufSize||1048576,this.buffers=[],this.batch=b.batch||!1,this.corked=!1,this.inPos=0,this.outPos=0,this.pipes=[],this.paused=!1,this.encoding=null};i.inherits(m,l.Duplex,{toBuffer(){switch(this.buffers.length){case 0:return null;case 1:return this.buffers[0].toBuffer();default:return s.concat(this.buffers.map(b=>b.toBuffer()))}},_getWritableBuffer(){if(this.buffers.length){const p=this.buffers[this.buffers.length-1];if(!p.full)return p}const b=new d(this.bufSize);return this.buffers.push(b),b},async _pipe(b){await Promise.all(this.pipes.map(function(p){return new Promise(v=>{p.write(b.toBuffer(),()=>{v()})})}))},_writeToBuffers(b){let p=0;const v=b.length;for(;p<v;)p+=this._getWritableBuffer().write(b,p,v-p)},async write(b,p,v){let g;if(p instanceof Function&&(v=p,p="utf8"),v=v||i.nop,b instanceof n)g=new h(b);else if(b instanceof s)g=new u(b);else{if(!(typeof b=="string"||b instanceof String||b instanceof ArrayBuffer))throw new Error("Chunk must be one of type String, Buffer or StringBuf.");g=new o(b,p)}if(this.pipes.length)if(this.batch)for(this._writeToBuffers(g);!this.corked&&this.buffers.length>1;)this._pipe(this.buffers.shift());else this.corked?(this._writeToBuffers(g),c.nextTick(v)):(await this._pipe(g),v());else this.paused||this.emit("data",g.toBuffer()),this._writeToBuffers(g),this.emit("readable");return!0},cork(){this.corked=!0},_flush(){if(this.pipes.length)for(;this.buffers.length;)this._pipe(this.buffers.shift())},uncork(){this.corked=!1,this._flush()},end(b,p,v){const g=x=>{x?v(x):(this._flush(),this.pipes.forEach(C=>{C.end()}),this.emit("finish"))};b?this.write(b,p,g):g()},read(b){let p;if(b){for(p=[];b&&this.buffers.length&&!this.buffers[0].eod;){const v=this.buffers[0],g=v.read(b);b-=g.length,p.push(g),v.eod&&v.full&&this.buffers.shift()}return s.concat(p)}return p=this.buffers.map(v=>v.toBuffer()).filter(Boolean),this.buffers=[],s.concat(p)},setEncoding(b){this.encoding=b},pause(){this.paused=!0},resume(){this.paused=!1},isPaused(){return!!this.paused},pipe(b){this.pipes.push(b),!this.paused&&this.buffers.length&&this.end()},unpipe(b){this.pipes=this.pipes.filter(p=>p!==b)},unshift(){throw new Error("Not Implemented")},wrap(){throw new Error("Not Implemented")}}),a.exports=m}).call(this)}).call(this,e("_process"),e("buffer").Buffer)},{"./string-buf":25,"./utils":27,_process:467,buffer:220,"readable-stream":491}],25:[function(e,a,f){(function(c){(function(){a.exports=class{constructor(s){this._buf=c.alloc(s&&s.size||16384),this._encoding=s&&s.encoding||"utf8",this._inPos=0,this._buffer=void 0}get length(){return this._inPos}get capacity(){return this._buf.length}get buffer(){return this._buf}toBuffer(){return this._buffer||(this._buffer=c.alloc(this.length),this._buf.copy(this._buffer,0,0,this.length)),this._buffer}reset(s){s=s||0,this._buffer=void 0,this._inPos=s}_grow(s){let l=2*this._buf.length;for(;l<s;)l*=2;const i=c.alloc(l);this._buf.copy(i,0),this._buf=i}addText(s){this._buffer=void 0;let l=this._inPos+this._buf.write(s,this._inPos,this._encoding);for(;l>=this._buf.length-4;)this._grow(this._inPos+s.length),l=this._inPos+this._buf.write(s,this._inPos,this._encoding);this._inPos=l}addStringBuf(s){s.length&&(this._buffer=void 0,this.length+s.length>this.capacity&&this._grow(this.length+s.length),s._buf.copy(this._buf,this._inPos,0,s.length),this._inPos+=s.length)}}}).call(this)}).call(this,e("buffer").Buffer)},{buffer:220}],26:[function(e,a,f){const{toString:c}=Object.prototype,s=/["&<>]/,l={each:function(i,n){i&&(Array.isArray(i)?i.forEach(n):Object.keys(i).forEach(o=>{n(i[o],o)}))},some:function(i,n){return!!i&&(Array.isArray(i)?i.some(n):Object.keys(i).some(o=>n(i[o],o)))},every:function(i,n){return!i||(Array.isArray(i)?i.every(n):Object.keys(i).every(o=>n(i[o],o)))},map:function(i,n){return i?Array.isArray(i)?i.map(n):Object.keys(i).map(o=>n(i[o],o)):[]},keyBy:(i,n)=>i.reduce((o,h)=>(o[h[n]]=h,o),{}),isEqual:function(i,n){const o=typeof i,h=typeof n,u=Array.isArray(i),d=Array.isArray(n);let m;if(o!==h)return!1;switch(typeof i){case"object":if(u||d)return!(!u||!d)&&i.length===n.length&&i.every((b,p)=>{const v=n[p];return l.isEqual(b,v)});if(i===null||n===null)return i===n;if(m=Object.keys(i),Object.keys(n).length!==m.length)return!1;for(const b of m)if(!n.hasOwnProperty(b))return!1;return l.every(i,(b,p)=>{const v=n[p];return l.isEqual(b,v)});default:return i===n}},escapeHtml(i){const n=s.exec(i);if(!n)return i;let o="",h="",u=0,d=n.index;for(;d<i.length;d++){switch(i.charAt(d)){case'"':h=""";break;case"&":h="&";break;case"'":h="'";break;case"<":h="<";break;case">":h=">";break;default:continue}u!==d&&(o+=i.substring(u,d)),u=d+1,o+=h}return u!==d?o+i.substring(u,d):o},strcmp:(i,n)=>i<n?-1:i>n?1:0,isUndefined:i=>c.call(i)==="[object Undefined]",isObject:i=>c.call(i)==="[object Object]",deepMerge(){const i=arguments[0]||{},{length:n}=arguments;let o,h,u;function d(m,b){o=i[b],u=Array.isArray(m),l.isObject(m)||u?(u?(u=!1,h=o&&Array.isArray(o)?o:[]):h=o&&l.isObject(o)?o:{},i[b]=l.deepMerge(h,m)):l.isUndefined(m)||(i[b]=m)}for(let m=0;m<n;m++)l.each(arguments[m],d);return i}};a.exports=l},{}],27:[function(e,a,f){(function(c,s){(function(){const l=e("fs"),i=/[<>&'"\x7F\x00-\x08\x0B-\x0C\x0E-\x1F]/,n={nop(){},promiseImmediate:o=>new Promise(h=>{c.setImmediate?s(()=>{h(o)}):setTimeout(()=>{h(o)},1)}),inherits:function(o,h,u,d){o.super_=h,d||(d=u,u=null),u&&Object.keys(u).forEach(b=>{Object.defineProperty(o,b,Object.getOwnPropertyDescriptor(u,b))});const m={constructor:{value:o,enumerable:!1,writable:!1,configurable:!0}};d&&Object.keys(d).forEach(b=>{m[b]=Object.getOwnPropertyDescriptor(d,b)}),o.prototype=Object.create(h.prototype,m)},dateToExcel:(o,h)=>25569+o.getTime()/864e5-(h?1462:0),excelToDate(o,h){const u=Math.round(24*(o-25569+(h?1462:0))*3600*1e3);return new Date(u)},parsePath(o){const h=o.lastIndexOf("/");return{path:o.substring(0,h),name:o.substring(h+1)}},getRelsPath(o){const h=n.parsePath(o);return`${h.path}/_rels/${h.name}.rels`},xmlEncode(o){const h=i.exec(o);if(!h)return o;let u="",d="",m=0,b=h.index;for(;b<o.length;b++){const p=o.charCodeAt(b);switch(p){case 34:d=""";break;case 38:d="&";break;case 39:d="'";break;case 60:d="<";break;case 62:d=">";break;case 127:d="";break;default:if(p<=31&&(p<=8||p>=11&&p!==13)){d="";break}continue}m!==b&&(u+=o.substring(m,b)),m=b+1,d&&(u+=d)}return m!==b?u+o.substring(m,b):u},xmlDecode:o=>o.replace(/&([a-z]*);/g,h=>{switch(h){case"<":return"<";case">":return">";case"&":return"&";case"'":return"'";case""":return'"';default:return h}}),validInt(o){const h=parseInt(o,10);return Number.isNaN(h)?0:h},isDateFmt(o){return o?(o=(o=o.replace(/\[[^\]]*]/g,"")).replace(/"[^"]*"/g,"")).match(/[ymdhMsb]+/)!==null:!1},fs:{exists:o=>new Promise(h=>{l.access(o,l.constants.F_OK,u=>{h(!u)})})},toIsoDateString:o=>o.toIsoString().subsstr(0,10),parseBoolean:o=>o===!0||o==="true"||o===1||o==="1"};a.exports=n}).call(this)}).call(this,typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{},e("timers").setImmediate)},{fs:216,timers:523}],28:[function(e,a,f){const c=e("./under-dash"),s=e("./utils");function l(o,h,u){o.push(` ${h}="${s.xmlEncode(u.toString())}"`)}function i(o,h){if(h){const u=[];c.each(h,(d,m)=>{d!==void 0&&l(u,m,d)}),o.push(u.join(""))}}class n{constructor(){this._xml=[],this._stack=[],this._rollbacks=[]}get tos(){return this._stack.length?this._stack[this._stack.length-1]:void 0}get cursor(){return this._xml.length}openXml(h){const u=this._xml;u.push("<?xml"),i(u,h),u.push(`?> `)}openNode(h,u){const d=this.tos,m=this._xml;d&&this.open&&m.push(">"),this._stack.push(h),m.push("<"),m.push(h),i(m,u),this.leaf=!0,this.open=!0}addAttribute(h,u){if(!this.open)throw new Error("Cannot write attributes to node if it is not open");u!==void 0&&l(this._xml,h,u)}addAttributes(h){if(!this.open)throw new Error("Cannot write attributes to node if it is not open");i(this._xml,h)}writeText(h){const u=this._xml;this.open&&(u.push(">"),this.open=!1),this.leaf=!1,u.push(s.xmlEncode(h.toString()))}writeXml(h){this.open&&(this._xml.push(">"),this.open=!1),this.leaf=!1,this._xml.push(h)}closeNode(){const h=this._stack.pop(),u=this._xml;this.leaf?u.push("/>"):(u.push("</"),u.push(h),u.push(">")),this.open=!1,this.leaf=!1}leafNode(h,u,d){this.openNode(h,u),d!==void 0&&this.writeText(d),this.closeNode()}closeAll(){for(;this._stack.length;)this.closeNode()}addRollback(){return this._rollbacks.push({xml:this._xml.length,stack:this._stack.length,leaf:this.leaf,open:this.open}),this.cursor}commit(){this._rollbacks.pop()}rollback(){const h=this._rollbacks.pop();this._xml.length>h.xml&&this._xml.splice(h.xml,this._xml.length-h.xml),this._stack.length>h.stack&&this._stack.splice(h.stack,this._stack.length-h.stack),this.leaf=h.leaf,this.open=h.open}get xml(){return this.closeAll(),this._xml.join("")}}n.StdDocAttributes={version:"1.0",encoding:"UTF-8",standalone:"yes"},a.exports=n},{"./under-dash":26,"./utils":27}],29:[function(e,a,f){(function(c){(function(){const s=e("events"),l=e("jszip"),i=e("./stream-buf"),{stringToBuffer:n}=e("./browser-buffer-encode");class o extends s.EventEmitter{constructor(u){super(),this.options=Object.assign({type:"nodebuffer",compression:"DEFLATE"},u),this.zip=new l,this.stream=new i}append(u,d){d.hasOwnProperty("base64")&&d.base64?this.zip.file(d.name,u,{base64:!0}):(c.browser&&typeof u=="string"&&(u=n(u)),this.zip.file(d.name,u))}async finalize(){const u=await this.zip.generateAsync(this.options);this.stream.end(u),this.emit("finish")}read(u){return this.stream.read(u)}setEncoding(u){return this.stream.setEncoding(u)}pause(){return this.stream.pause()}resume(){return this.stream.resume()}isPaused(){return this.stream.isPaused()}pipe(u,d){return this.stream.pipe(u,d)}unpipe(u){return this.stream.unpipe(u)}unshift(u){return this.stream.unshift(u)}wrap(u){return this.stream.wrap(u)}}a.exports={ZipWriter:o}}).call(this)}).call(this,e("_process"))},{"./browser-buffer-encode":17,"./stream-buf":24,_process:467,events:422,jszip:441}],30:[function(e,a,f){a.exports={0:{f:"General"},1:{f:"0"},2:{f:"0.00"},3:{f:"#,##0"},4:{f:"#,##0.00"},9:{f:"0%"},10:{f:"0.00%"},11:{f:"0.00E+00"},12:{f:"# ?/?"},13:{f:"# ??/??"},14:{f:"mm-dd-yy"},15:{f:"d-mmm-yy"},16:{f:"d-mmm"},17:{f:"mmm-yy"},18:{f:"h:mm AM/PM"},19:{f:"h:mm:ss AM/PM"},20:{f:"h:mm"},21:{f:"h:mm:ss"},22:{f:'m/d/yy "h":mm'},27:{"zh-tw":"[$-404]e/m/d","zh-cn":'yyyy"年"m"月"',"ja-jp":"[$-411]ge.m.d","ko-kr":'yyyy"年" mm"月" dd"日"'},28:{"zh-tw":'[$-404]e"年"m"月"d"日"',"zh-cn":'m"月"d"日"',"ja-jp":'[$-411]ggge"年"m"月"d"日"',"ko-kr":"mm-dd"},29:{"zh-tw":'[$-404]e"年"m"月"d"日"',"zh-cn":'m"月"d"日"',"ja-jp":'[$-411]ggge"年"m"月"d"日"',"ko-kr":"mm-dd"},30:{"zh-tw":"m/d/yy ","zh-cn":"m-d-yy","ja-jp":"m/d/yy","ko-kr":"mm-dd-yy"},31:{"zh-tw":'yyyy"年"m"月"d"日"',"zh-cn":'yyyy"年"m"月"d"日"',"ja-jp":'yyyy"年"m"月"d"日"',"ko-kr":'yyyy"년" mm"월" dd"일"'},32:{"zh-tw":'hh"時"mm"分"',"zh-cn":'h"时"mm"分"',"ja-jp":'h"時"mm"分"',"ko-kr":'h"시" mm"분"'},33:{"zh-tw":'hh"時"mm"分"ss"秒"',"zh-cn":'h"时"mm"分"ss"秒"',"ja-jp":'h"時"mm"分"ss"秒"',"ko-kr":'h"시" mm"분" ss"초"'},34:{"zh-tw":'上午/下午 hh"時"mm"分"',"zh-cn":'上午/下午 h"时"mm"分"',"ja-jp":'yyyy"年"m"月"',"ko-kr":"yyyy-mm-dd"},35:{"zh-tw":'上午/下午 hh"時"mm"分"ss"秒"',"zh-cn":'上午/下午 h"时"mm"分"ss"秒"',"ja-jp":'m"月"d"日"',"ko-kr":"yyyy-mm-dd"},36:{"zh-tw":"[$-404]e/m/d","zh-cn":'yyyy"年"m"月"',"ja-jp":"[$-411]ge.m.d","ko-kr":'yyyy"年" mm"月" dd"日"'},37:{f:"#,##0 ;(#,##0)"},38:{f:"#,##0 ;[Red](#,##0)"},39:{f:"#,##0.00 ;(#,##0.00)"},40:{f:"#,##0.00 ;[Red](#,##0.00)"},45:{f:"mm:ss"},46:{f:"[h]:mm:ss"},47:{f:"mmss.0"},48:{f:"##0.0E+0"},49:{f:"@"},50:{"zh-tw":"[$-404]e/m/d","zh-cn":'yyyy"年"m"月"',"ja-jp":"[$-411]ge.m.d","ko-kr":'yyyy"年" mm"月" dd"日"'},51:{"zh-tw":'[$-404]e"年"m"月"d"日"',"zh-cn":'m"月"d"日"',"ja-jp":'[$-411]ggge"年"m"月"d"日"',"ko-kr":"mm-dd"},52:{"zh-tw":'上午/下午 hh"時"mm"分"',"zh-cn":'yyyy"年"m"月"',"ja-jp":'yyyy"年"m"月"',"ko-kr":"yyyy-mm-dd"},53:{"zh-tw":'上午/下午 hh"時"mm"分"ss"秒"',"zh-cn":'m"月"d"日"',"ja-jp":'m"月"d"日"',"ko-kr":"yyyy-mm-dd"},54:{"zh-tw":'[$-404]e"年"m"月"d"日"',"zh-cn":'m"月"d"日"',"ja-jp":'[$-411]ggge"年"m"月"d"日"',"ko-kr":"mm-dd"},55:{"zh-tw":'上午/下午 hh"時"mm"分"',"zh-cn":'上午/下午 h"时"mm"分"',"ja-jp":'yyyy"年"m"月"',"ko-kr":"yyyy-mm-dd"},56:{"zh-tw":'上午/下午 hh"時"mm"分"ss"秒"',"zh-cn":'上午/下午 h"时"mm"分"ss"秒"',"ja-jp":'m"月"d"日"',"ko-kr":"yyyy-mm-dd"},57:{"zh-tw":"[$-404]e/m/d","zh-cn":'yyyy"年"m"月"',"ja-jp":"[$-411]ge.m.d","ko-kr":'yyyy"年" mm"月" dd"日"'},58:{"zh-tw":'[$-404]e"年"m"月"d"日"',"zh-cn":'m"月"d"日"',"ja-jp":'[$-411]ggge"年"m"月"d"日"',"ko-kr":"mm-dd"},59:{"th-th":"t0"},60:{"th-th":"t0.00"},61:{"th-th":"t#,##0"},62:{"th-th":"t#,##0.00"},67:{"th-th":"t0%"},68:{"th-th":"t0.00%"},69:{"th-th":"t# ?/?"},70:{"th-th":"t# ??/??"},81:{"th-th":"d/m/bb"}}},{}],31:[function(e,a,f){a.exports={OfficeDocument:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",Worksheet:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet",CalcChain:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/calcChain",SharedStrings:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings",Styles:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",Theme:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",Hyperlink:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",Image:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",CoreProperties:"http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties",ExtenderProperties:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties",Comments:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments",VmlDrawing:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/vmlDrawing",Table:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/table"}},{}],32:[function(e,a,f){const c=e("../../utils/parse-sax"),s=e("../../utils/xml-stream");class l{prepare(){}render(){}parseOpen(n){}parseText(n){}parseClose(n){}reconcile(n,o){}reset(){this.model=null,this.map&&Object.values(this.map).forEach(n=>{n instanceof l?n.reset():n.xform&&n.xform.reset()})}mergeModel(n){this.model=Object.assign(this.model||{},n)}async parse(n){for await(const o of n)for(const{eventType:h,value:u}of o)if(h==="opentag")this.parseOpen(u);else if(h==="text")this.parseText(u);else if(h==="closetag"&&!this.parseClose(u.name))return this.model;return this.model}async parseStream(n){return this.parse(c(n))}get xml(){return this.toXml(this.model)}toXml(n){const o=new s;return this.render(o,n),o.xml}static toAttribute(n,o){let h=arguments.length>2&&arguments[2]!==void 0&&arguments[2];if(n===void 0){if(h)return o}else if(h||n!==o)return n.toString()}static toStringAttribute(n,o){let h=arguments.length>2&&arguments[2]!==void 0&&arguments[2];return l.toAttribute(n,o,h)}static toStringValue(n,o){return n===void 0?o:n}static toBoolAttribute(n,o){let h=arguments.length>2&&arguments[2]!==void 0&&arguments[2];if(n===void 0){if(h)return o}else if(h||n!==o)return n?"1":"0"}static toBoolValue(n,o){return n===void 0?o:n==="1"}static toIntAttribute(n,o){let h=arguments.length>2&&arguments[2]!==void 0&&arguments[2];return l.toAttribute(n,o,h)}static toIntValue(n,o){return n===void 0?o:parseInt(n,10)}static toFloatAttribute(n,o){let h=arguments.length>2&&arguments[2]!==void 0&&arguments[2];return l.toAttribute(n,o,h)}static toFloatValue(n,o){return n===void 0?o:parseFloat(n)}}a.exports=l},{"../../utils/parse-sax":22,"../../utils/xml-stream":28}],33:[function(e,a,f){const c=e("../base-xform"),s=e("../../../utils/col-cache");function l(n){try{return s.decodeEx(n),!0}catch{return!1}}function i(n){const o=[];let h=!1,u="";return n.split(",").forEach(d=>{if(!d)return;const m=(d.match(/'/g)||[]).length;if(!m)return void(h?u+=d+",":l(d)&&o.push(d));const b=m%2==0;!h&&b&&l(d)?o.push(d):h&&!b?(h=!1,l(u+d)&&o.push(u+d),u=""):(h=!0,u+=d+",")}),o}a.exports=class extends c{render(n,o){n.openNode("definedName",{name:o.name,localSheetId:o.localSheetId}),n.writeText(o.ranges.join(",")),n.closeNode()}parseOpen(n){switch(n.name){case"definedName":return this._parsedName=n.attributes.name,this._parsedLocalSheetId=n.attributes.localSheetId,this._parsedText=[],!0;default:return!1}}parseText(n){this._parsedText.push(n)}parseClose(){return this.model={name:this._parsedName,ranges:i(this._parsedText.join(""))},this._parsedLocalSheetId!==void 0&&(this.model.localSheetId=parseInt(this._parsedLocalSheetId,10)),!1}}},{"../../../utils/col-cache":19,"../base-xform":32}],34:[function(e,a,f){const c=e("../../../utils/utils"),s=e("../base-xform");a.exports=class extends s{render(l,i){l.leafNode("sheet",{sheetId:i.id,name:i.name,state:i.state,"r:id":i.rId})}parseOpen(l){return l.name==="sheet"&&(this.model={name:c.xmlDecode(l.attributes.name),id:parseInt(l.attributes.sheetId,10),state:l.attributes.state,rId:l.attributes["r:id"]},!0)}parseText(){}parseClose(){return!1}}},{"../../../utils/utils":27,"../base-xform":32}],35:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{render(s,l){s.leafNode("calcPr",{calcId:171027,fullCalcOnLoad:l.fullCalcOnLoad?1:void 0})}parseOpen(s){return s.name==="calcPr"&&(this.model={},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],36:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{render(s,l){s.leafNode("workbookPr",{date1904:l.date1904?1:void 0,defaultThemeVersion:164011,filterPrivacy:1})}parseOpen(s){return s.name==="workbookPr"&&(this.model={date1904:s.attributes.date1904==="1"},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],37:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{render(s,l){const i={xWindow:l.x||0,yWindow:l.y||0,windowWidth:l.width||12e3,windowHeight:l.height||24e3,firstSheet:l.firstSheet,activeTab:l.activeTab};l.visibility&&l.visibility!=="visible"&&(i.visibility=l.visibility),s.leafNode("workbookView",i)}parseOpen(s){if(s.name==="workbookView"){const l=this.model={},i=function(o,h,u){const d=h!==void 0?l[o]=h:u;d!==void 0&&(l[o]=d)},n=function(o,h,u){const d=h!==void 0?l[o]=parseInt(h,10):u;d!==void 0&&(l[o]=d)};return n("x",s.attributes.xWindow,0),n("y",s.attributes.yWindow,0),n("width",s.attributes.windowWidth,25e3),n("height",s.attributes.windowHeight,1e4),i("visibility",s.attributes.visibility,"visible"),n("activeTab",s.attributes.activeTab,void 0),n("firstSheet",s.attributes.firstSheet,void 0),!0}return!1}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],38:[function(e,a,f){const c=e("../../../utils/under-dash"),s=e("../../../utils/col-cache"),l=e("../../../utils/xml-stream"),i=e("../base-xform"),n=e("../static-xform"),o=e("../list-xform"),h=e("./defined-name-xform"),u=e("./sheet-xform"),d=e("./workbook-view-xform"),m=e("./workbook-properties-xform"),b=e("./workbook-calc-properties-xform");class p extends i{constructor(){super(),this.map={fileVersion:p.STATIC_XFORMS.fileVersion,workbookPr:new m,bookViews:new o({tag:"bookViews",count:!1,childXform:new d}),sheets:new o({tag:"sheets",count:!1,childXform:new u}),definedNames:new o({tag:"definedNames",count:!1,childXform:new h}),calcPr:new b}}prepare(g){g.sheets=g.worksheets;const x=[];let C=0;g.sheets.forEach(T=>{if(T.pageSetup&&T.pageSetup.printArea&&T.pageSetup.printArea.split("&&").forEach(R=>{const B=R.split(":"),I={name:"_xlnm.Print_Area",ranges:[`'${T.name}'!$${B[0]}:$${B[1]}`],localSheetId:C};x.push(I)}),T.pageSetup&&(T.pageSetup.printTitlesRow||T.pageSetup.printTitlesColumn)){const R=[];if(T.pageSetup.printTitlesColumn){const I=T.pageSetup.printTitlesColumn.split(":");R.push(`'${T.name}'!$${I[0]}:$${I[1]}`)}if(T.pageSetup.printTitlesRow){const I=T.pageSetup.printTitlesRow.split(":");R.push(`'${T.name}'!$${I[0]}:$${I[1]}`)}const B={name:"_xlnm.Print_Titles",ranges:R,localSheetId:C};x.push(B)}C++}),x.length&&(g.definedNames=g.definedNames.concat(x)),(g.media||[]).forEach((T,R)=>{T.name=T.type+(R+1)})}render(g,x){g.openXml(l.StdDocAttributes),g.openNode("workbook",p.WORKBOOK_ATTRIBUTES),this.map.fileVersion.render(g),this.map.workbookPr.render(g,x.properties),this.map.bookViews.render(g,x.views),this.map.sheets.render(g,x.sheets),this.map.definedNames.render(g,x.definedNames),this.map.calcPr.render(g,x.calcProperties),g.closeNode()}parseOpen(g){if(this.parser)return this.parser.parseOpen(g),!0;switch(g.name){case"workbook":return!0;default:return this.parser=this.map[g.name],this.parser&&this.parser.parseOpen(g),!0}}parseText(g){this.parser&&this.parser.parseText(g)}parseClose(g){if(this.parser)return this.parser.parseClose(g)||(this.parser=void 0),!0;switch(g){case"workbook":return this.model={sheets:this.map.sheets.model,properties:this.map.workbookPr.model||{},views:this.map.bookViews.model,calcProperties:{}},this.map.definedNames.model&&(this.model.definedNames=this.map.definedNames.model),!1;default:return!0}}reconcile(g){const x=(g.workbookRels||[]).reduce((I,F)=>(I[F.Id]=F,I),{}),C=[];let T,R=0;(g.sheets||[]).forEach(I=>{const F=x[I.rId];F&&(T=g.worksheetHash["xl/"+F.Target.replace(/^(\s|\/xl\/)+/,"")],T&&(T.name=I.name,T.id=I.id,T.state=I.state,C[R++]=T))});const B=[];c.each(g.definedNames,I=>{if(I.name==="_xlnm.Print_Area"){if(T=C[I.localSheetId],T){T.pageSetup||(T.pageSetup={});const F=s.decodeEx(I.ranges[0]);T.pageSetup.printArea=T.pageSetup.printArea?`${T.pageSetup.printArea}&&${F.dimensions}`:F.dimensions}}else if(I.name==="_xlnm.Print_Titles"){if(T=C[I.localSheetId],T){T.pageSetup||(T.pageSetup={});const F=I.ranges.join(","),L=/\$/g,V=/\$\d+:\$\d+/,z=F.match(V);if(z&&z.length){const k=z[0];T.pageSetup.printTitlesRow=k.replace(L,"")}const E=/\$[A-Z]+:\$[A-Z]+/,P=F.match(E);if(P&&P.length){const k=P[0];T.pageSetup.printTitlesColumn=k.replace(L,"")}}}else B.push(I)}),g.definedNames=B,g.media.forEach((I,F)=>{I.index=F})}}p.WORKBOOK_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","mc:Ignorable":"x15","xmlns:x15":"http://schemas.microsoft.com/office/spreadsheetml/2010/11/main"},p.STATIC_XFORMS={fileVersion:new n({tag:"fileVersion",$:{appName:"xl",lastEdited:5,lowestEdited:5,rupBuild:9303}})},a.exports=p},{"../../../utils/col-cache":19,"../../../utils/under-dash":26,"../../../utils/xml-stream":28,"../base-xform":32,"../list-xform":71,"../static-xform":120,"./defined-name-xform":33,"./sheet-xform":34,"./workbook-calc-properties-xform":35,"./workbook-properties-xform":36,"./workbook-view-xform":37}],39:[function(e,a,f){const c=e("../strings/rich-text-xform"),s=e("../../../utils/utils"),l=e("../base-xform"),i=a.exports=function(n){this.model=n};s.inherits(i,l,{get tag(){return"r"},get richTextXform(){return this._richTextXform||(this._richTextXform=new c),this._richTextXform},render(n,o){o=o||this.model,n.openNode("comment",{ref:o.ref,authorId:0}),n.openNode("text"),o&&o.note&&o.note.texts&&o.note.texts.forEach(h=>{this.richTextXform.render(n,h)}),n.closeNode(),n.closeNode()},parseOpen(n){if(this.parser)return this.parser.parseOpen(n),!0;switch(n.name){case"comment":return this.model={type:"note",note:{texts:[]},...n.attributes},!0;case"r":return this.parser=this.richTextXform,this.parser.parseOpen(n),!0;default:return!1}},parseText(n){this.parser&&this.parser.parseText(n)},parseClose(n){switch(n){case"comment":return!1;case"r":return this.model.note.texts.push(this.parser.model),this.parser=void 0,!0;default:return this.parser&&this.parser.parseClose(n),!0}}})},{"../../../utils/utils":27,"../base-xform":32,"../strings/rich-text-xform":122}],40:[function(e,a,f){const c=e("../../../utils/xml-stream"),s=e("../../../utils/utils"),l=e("../base-xform"),i=e("./comment-xform"),n=a.exports=function(){this.map={comment:new i}};s.inherits(n,l,{COMMENTS_ATTRIBUTES:{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main"}},{render(o,h){h=h||this.model,o.openXml(c.StdDocAttributes),o.openNode("comments",n.COMMENTS_ATTRIBUTES),o.openNode("authors"),o.leafNode("author",null,"Author"),o.closeNode(),o.openNode("commentList"),h.comments.forEach(u=>{this.map.comment.render(o,u)}),o.closeNode(),o.closeNode()},parseOpen(o){if(this.parser)return this.parser.parseOpen(o),!0;switch(o.name){case"commentList":return this.model={comments:[]},!0;case"comment":return this.parser=this.map.comment,this.parser.parseOpen(o),!0;default:return!1}},parseText(o){this.parser&&this.parser.parseText(o)},parseClose(o){switch(o){case"commentList":return!1;case"comment":return this.model.comments.push(this.parser.model),this.parser=void 0,!0;default:return this.parser&&this.parser.parseClose(o),!0}}})},{"../../../utils/utils":27,"../../../utils/xml-stream":28,"../base-xform":32,"./comment-xform":39}],41:[function(e,a,f){const c=e("../../base-xform");a.exports=class extends c{constructor(s){super(),this._model=s}get tag(){return this._model&&this._model.tag}render(s,l,i){(l===i[2]||this.tag==="x:SizeWithCells"&&l===i[1])&&s.leafNode(this.tag)}parseOpen(s){switch(s.name){case this.tag:return this.model={},this.model[this.tag]=!0,!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../../base-xform":32}],42:[function(e,a,f){const c=e("../../base-xform");a.exports=class extends c{constructor(s){super(),this._model=s}get tag(){return this._model&&this._model.tag}render(s,l){s.leafNode(this.tag,null,l)}parseOpen(s){switch(s.name){case this.tag:return this.text="",!0;default:return!1}}parseText(s){this.text=s}parseClose(){return!1}}},{"../../base-xform":32}],43:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"x:Anchor"}getAnchorRect(s){const l=Math.floor(s.left),i=Math.floor(68*(s.left-l)),n=Math.floor(s.top),o=Math.floor(18*(s.top-n)),h=Math.floor(s.right),u=Math.floor(68*(s.right-h)),d=Math.floor(s.bottom);return[l,i,n,o,h,u,d,Math.floor(18*(s.bottom-d))]}getDefaultRect(s){const l=s.col,i=Math.max(s.row-2,0);return[l,6,i,14,l+2,2,i+4,16]}render(s,l){const i=l.anchor?this.getAnchorRect(l.anchor):this.getDefaultRect(l.refAddress);s.leafNode("x:Anchor",null,i.join(", "))}parseOpen(s){switch(s.name){case this.tag:return this.text="",!0;default:return!1}}parseText(s){this.text=s}parseClose(){return!1}}},{"../base-xform":32}],44:[function(e,a,f){const c=e("../base-xform"),s=e("./vml-anchor-xform"),l=e("./style/vml-protection-xform"),i=e("./style/vml-position-xform"),n=["twoCells","oneCells","absolute"];a.exports=class extends c{constructor(){super(),this.map={"x:Anchor":new s,"x:Locked":new l({tag:"x:Locked"}),"x:LockText":new l({tag:"x:LockText"}),"x:SizeWithCells":new i({tag:"x:SizeWithCells"}),"x:MoveWithCells":new i({tag:"x:MoveWithCells"})}}get tag(){return"x:ClientData"}render(o,h){const{protection:u,editAs:d}=h.note;o.openNode(this.tag,{ObjectType:"Note"}),this.map["x:MoveWithCells"].render(o,d,n),this.map["x:SizeWithCells"].render(o,d,n),this.map["x:Anchor"].render(o,h),this.map["x:Locked"].render(o,u.locked),o.leafNode("x:AutoFill",null,"False"),this.map["x:LockText"].render(o,u.lockText),o.leafNode("x:Row",null,h.refAddress.row-1),o.leafNode("x:Column",null,h.refAddress.col-1),o.closeNode()}parseOpen(o){switch(o.name){case this.tag:this.reset(),this.model={anchor:[],protection:{},editAs:""};break;default:this.parser=this.map[o.name],this.parser&&this.parser.parseOpen(o)}return!0}parseText(o){this.parser&&this.parser.parseText(o)}parseClose(o){if(this.parser)return this.parser.parseClose(o)||(this.parser=void 0),!0;switch(o){case this.tag:return this.normalizeModel(),!1;default:return!0}}normalizeModel(){const o=Object.assign({},this.map["x:MoveWithCells"].model,this.map["x:SizeWithCells"].model),h=Object.keys(o).length;this.model.editAs=n[h],this.model.anchor=this.map["x:Anchor"].text,this.model.protection.locked=this.map["x:Locked"].text,this.model.protection.lockText=this.map["x:LockText"].text}}},{"../base-xform":32,"./style/vml-position-xform":41,"./style/vml-protection-xform":42,"./vml-anchor-xform":43}],45:[function(e,a,f){const c=e("../../../utils/xml-stream"),s=e("../base-xform"),l=e("./vml-shape-xform");class i extends s{constructor(){super(),this.map={"v:shape":new l}}get tag(){return"xml"}render(o,h){o.openXml(c.StdDocAttributes),o.openNode(this.tag,i.DRAWING_ATTRIBUTES),o.openNode("o:shapelayout",{"v:ext":"edit"}),o.leafNode("o:idmap",{"v:ext":"edit",data:1}),o.closeNode(),o.openNode("v:shapetype",{id:"_x0000_t202",coordsize:"21600,21600","o:spt":202,path:"m,l,21600r21600,l21600,xe"}),o.leafNode("v:stroke",{joinstyle:"miter"}),o.leafNode("v:path",{gradientshapeok:"t","o:connecttype":"rect"}),o.closeNode(),h.comments.forEach((u,d)=>{this.map["v:shape"].render(o,u,d)}),o.closeNode()}parseOpen(o){if(this.parser)return this.parser.parseOpen(o),!0;switch(o.name){case this.tag:this.reset(),this.model={comments:[]};break;default:this.parser=this.map[o.name],this.parser&&this.parser.parseOpen(o)}return!0}parseText(o){this.parser&&this.parser.parseText(o)}parseClose(o){if(this.parser)return this.parser.parseClose(o)||(this.model.comments.push(this.parser.model),this.parser=void 0),!0;switch(o){case this.tag:return!1;default:return!0}}reconcile(o,h){o.anchors.forEach(u=>{u.br?this.map["xdr:twoCellAnchor"].reconcile(u,h):this.map["xdr:oneCellAnchor"].reconcile(u,h)})}}i.DRAWING_ATTRIBUTES={"xmlns:v":"urn:schemas-microsoft-com:vml","xmlns:o":"urn:schemas-microsoft-com:office:office","xmlns:x":"urn:schemas-microsoft-com:office:excel"},a.exports=i},{"../../../utils/xml-stream":28,"../base-xform":32,"./vml-shape-xform":46}],46:[function(e,a,f){const c=e("../base-xform"),s=e("./vml-textbox-xform"),l=e("./vml-client-data-xform");class i extends c{constructor(){super(),this.map={"v:textbox":new s,"x:ClientData":new l}}get tag(){return"v:shape"}render(o,h,u){o.openNode("v:shape",i.V_SHAPE_ATTRIBUTES(h,u)),o.leafNode("v:fill",{color2:"infoBackground [80]"}),o.leafNode("v:shadow",{color:"none [81]",obscured:"t"}),o.leafNode("v:path",{"o:connecttype":"none"}),this.map["v:textbox"].render(o,h),this.map["x:ClientData"].render(o,h),o.closeNode()}parseOpen(o){if(this.parser)return this.parser.parseOpen(o),!0;switch(o.name){case this.tag:this.reset(),this.model={margins:{insetmode:o.attributes["o:insetmode"]},anchor:"",editAs:"",protection:{}};break;default:this.parser=this.map[o.name],this.parser&&this.parser.parseOpen(o)}return!0}parseText(o){this.parser&&this.parser.parseText(o)}parseClose(o){if(this.parser)return this.parser.parseClose(o)||(this.parser=void 0),!0;switch(o){case this.tag:return this.model.margins.inset=this.map["v:textbox"].model&&this.map["v:textbox"].model.inset,this.model.protection=this.map["x:ClientData"].model&&this.map["x:ClientData"].model.protection,this.model.anchor=this.map["x:ClientData"].model&&this.map["x:ClientData"].model.anchor,this.model.editAs=this.map["x:ClientData"].model&&this.map["x:ClientData"].model.editAs,!1;default:return!0}}}i.V_SHAPE_ATTRIBUTES=(n,o)=>({id:"_x0000_s"+(1025+o),type:"#_x0000_t202",style:"position:absolute; margin-left:105.3pt;margin-top:10.5pt;width:97.8pt;height:59.1pt;z-index:1;visibility:hidden",fillcolor:"infoBackground [80]",strokecolor:"none [81]","o:insetmode":n.note.margins&&n.note.margins.insetmode}),a.exports=i},{"../base-xform":32,"./vml-client-data-xform":44,"./vml-textbox-xform":47}],47:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"v:textbox"}conversionUnit(s,l,i){return`${parseFloat(s)*l.toFixed(2)}${i}`}reverseConversionUnit(s){return(s||"").split(",").map(l=>Number(parseFloat(this.conversionUnit(parseFloat(l),.1,"")).toFixed(2)))}render(s,l){const i={style:"mso-direction-alt:auto"};if(l&&l.note){let{inset:n}=l.note&&l.note.margins;Array.isArray(n)&&(n=n.map(o=>this.conversionUnit(o,10,"mm")).join(",")),n&&(i.inset=n)}s.openNode("v:textbox",i),s.leafNode("div",{style:"text-align:left"}),s.closeNode()}parseOpen(s){switch(s.name){case this.tag:return this.model={inset:this.reverseConversionUnit(s.attributes.inset)},!0;default:return!0}}parseText(){}parseClose(s){switch(s){case this.tag:return!1;default:return!0}}}},{"../base-xform":32}],48:[function(e,a,f){const c=e("./base-xform");a.exports=class extends c{createNewModel(s){return{}}parseOpen(s){return this.parser=this.parser||this.map[s.name],this.parser?(this.parser.parseOpen(s),!0):s.name===this.tag&&(this.model=this.createNewModel(s),!0)}parseText(s){this.parser&&this.parser.parseText(s)}onParserClose(s,l){this.model[s]=l.model}parseClose(s){return this.parser?(this.parser.parseClose(s)||(this.onParserClose(s,this.parser),this.parser=void 0),!0):s!==this.tag}}},{"./base-xform":32}],49:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{render(s,l){s.openNode("HeadingPairs"),s.openNode("vt:vector",{size:2,baseType:"variant"}),s.openNode("vt:variant"),s.leafNode("vt:lpstr",void 0,"Worksheets"),s.closeNode(),s.openNode("vt:variant"),s.leafNode("vt:i4",void 0,l.length),s.closeNode(),s.closeNode(),s.closeNode()}parseOpen(s){return s.name==="HeadingPairs"}parseText(){}parseClose(s){return s!=="HeadingPairs"}}},{"../base-xform":32}],50:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{render(s,l){s.openNode("TitlesOfParts"),s.openNode("vt:vector",{size:l.length,baseType:"lpstr"}),l.forEach(i=>{s.leafNode("vt:lpstr",void 0,i.name)}),s.closeNode(),s.closeNode()}parseOpen(s){return s.name==="TitlesOfParts"}parseText(){}parseClose(s){return s!=="TitlesOfParts"}}},{"../base-xform":32}],51:[function(e,a,f){const c=e("../../../utils/xml-stream"),s=e("../base-xform"),l=e("../simple/string-xform"),i=e("./app-heading-pairs-xform"),n=e("./app-titles-of-parts-xform");class o extends s{constructor(){super(),this.map={Company:new l({tag:"Company"}),Manager:new l({tag:"Manager"}),HeadingPairs:new i,TitleOfParts:new n}}render(u,d){u.openXml(c.StdDocAttributes),u.openNode("Properties",o.PROPERTY_ATTRIBUTES),u.leafNode("Application",void 0,"Microsoft Excel"),u.leafNode("DocSecurity",void 0,"0"),u.leafNode("ScaleCrop",void 0,"false"),this.map.HeadingPairs.render(u,d.worksheets),this.map.TitleOfParts.render(u,d.worksheets),this.map.Company.render(u,d.company||""),this.map.Manager.render(u,d.manager),u.leafNode("LinksUpToDate",void 0,"false"),u.leafNode("SharedDoc",void 0,"false"),u.leafNode("HyperlinksChanged",void 0,"false"),u.leafNode("AppVersion",void 0,"16.0300"),u.closeNode()}parseOpen(u){if(this.parser)return this.parser.parseOpen(u),!0;switch(u.name){case"Properties":return!0;default:return this.parser=this.map[u.name],!!this.parser&&(this.parser.parseOpen(u),!0)}}parseText(u){this.parser&&this.parser.parseText(u)}parseClose(u){if(this.parser)return this.parser.parseClose(u)||(this.parser=void 0),!0;switch(u){case"Properties":return this.model={worksheets:this.map.TitleOfParts.model,company:this.map.Company.model,manager:this.map.Manager.model},!1;default:return!0}}}o.DateFormat=function(h){return h.toISOString().replace(/[.]\d{3,6}/,"")},o.DateAttrs={"xsi:type":"dcterms:W3CDTF"},o.PROPERTY_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/officeDocument/2006/extended-properties","xmlns:vt":"http://schemas.openxmlformats.org/officeDocument/2006/docPropsVTypes"},a.exports=o},{"../../../utils/xml-stream":28,"../base-xform":32,"../simple/string-xform":119,"./app-heading-pairs-xform":49,"./app-titles-of-parts-xform":50}],52:[function(e,a,f){const c=e("../../../utils/xml-stream"),s=e("../base-xform");class l extends s{render(n,o){n.openXml(c.StdDocAttributes),n.openNode("Types",l.PROPERTY_ATTRIBUTES);const h={};(o.media||[]).forEach(u=>{if(u.type==="image"){const d=u.extension;h[d]||(h[d]=!0,n.leafNode("Default",{Extension:d,ContentType:"image/"+d}))}}),n.leafNode("Default",{Extension:"rels",ContentType:"application/vnd.openxmlformats-package.relationships+xml"}),n.leafNode("Default",{Extension:"xml",ContentType:"application/xml"}),n.leafNode("Override",{PartName:"/xl/workbook.xml",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml"}),o.worksheets.forEach(u=>{const d=`/xl/worksheets/sheet${u.id}.xml`;n.leafNode("Override",{PartName:d,ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml"})}),n.leafNode("Override",{PartName:"/xl/theme/theme1.xml",ContentType:"application/vnd.openxmlformats-officedocument.theme+xml"}),n.leafNode("Override",{PartName:"/xl/styles.xml",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml"}),o.sharedStrings&&o.sharedStrings.count&&n.leafNode("Override",{PartName:"/xl/sharedStrings.xml",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml"}),o.tables&&o.tables.forEach(u=>{n.leafNode("Override",{PartName:"/xl/tables/"+u.target,ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml"})}),o.drawings&&o.drawings.forEach(u=>{n.leafNode("Override",{PartName:`/xl/drawings/${u.name}.xml`,ContentType:"application/vnd.openxmlformats-officedocument.drawing+xml"})}),o.commentRefs&&(n.leafNode("Default",{Extension:"vml",ContentType:"application/vnd.openxmlformats-officedocument.vmlDrawing"}),o.commentRefs.forEach(u=>{let{commentName:d}=u;n.leafNode("Override",{PartName:`/xl/${d}.xml`,ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml"})})),n.leafNode("Override",{PartName:"/docProps/core.xml",ContentType:"application/vnd.openxmlformats-package.core-properties+xml"}),n.leafNode("Override",{PartName:"/docProps/app.xml",ContentType:"application/vnd.openxmlformats-officedocument.extended-properties+xml"}),n.closeNode()}parseOpen(){return!1}parseText(){}parseClose(){return!1}}l.PROPERTY_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/package/2006/content-types"},a.exports=l},{"../../../utils/xml-stream":28,"../base-xform":32}],53:[function(e,a,f){const c=e("../../../utils/xml-stream"),s=e("../base-xform"),l=e("../simple/date-xform"),i=e("../simple/string-xform"),n=e("../simple/integer-xform");class o extends s{constructor(){super(),this.map={"dc:creator":new i({tag:"dc:creator"}),"dc:title":new i({tag:"dc:title"}),"dc:subject":new i({tag:"dc:subject"}),"dc:description":new i({tag:"dc:description"}),"dc:identifier":new i({tag:"dc:identifier"}),"dc:language":new i({tag:"dc:language"}),"cp:keywords":new i({tag:"cp:keywords"}),"cp:category":new i({tag:"cp:category"}),"cp:lastModifiedBy":new i({tag:"cp:lastModifiedBy"}),"cp:lastPrinted":new l({tag:"cp:lastPrinted",format:o.DateFormat}),"cp:revision":new n({tag:"cp:revision"}),"cp:version":new i({tag:"cp:version"}),"cp:contentStatus":new i({tag:"cp:contentStatus"}),"cp:contentType":new i({tag:"cp:contentType"}),"dcterms:created":new l({tag:"dcterms:created",attrs:o.DateAttrs,format:o.DateFormat}),"dcterms:modified":new l({tag:"dcterms:modified",attrs:o.DateAttrs,format:o.DateFormat})}}render(u,d){u.openXml(c.StdDocAttributes),u.openNode("cp:coreProperties",o.CORE_PROPERTY_ATTRIBUTES),this.map["dc:creator"].render(u,d.creator),this.map["dc:title"].render(u,d.title),this.map["dc:subject"].render(u,d.subject),this.map["dc:description"].render(u,d.description),this.map["dc:identifier"].render(u,d.identifier),this.map["dc:language"].render(u,d.language),this.map["cp:keywords"].render(u,d.keywords),this.map["cp:category"].render(u,d.category),this.map["cp:lastModifiedBy"].render(u,d.lastModifiedBy),this.map["cp:lastPrinted"].render(u,d.lastPrinted),this.map["cp:revision"].render(u,d.revision),this.map["cp:version"].render(u,d.version),this.map["cp:contentStatus"].render(u,d.contentStatus),this.map["cp:contentType"].render(u,d.contentType),this.map["dcterms:created"].render(u,d.created),this.map["dcterms:modified"].render(u,d.modified),u.closeNode()}parseOpen(u){if(this.parser)return this.parser.parseOpen(u),!0;switch(u.name){case"cp:coreProperties":case"coreProperties":return!0;default:if(this.parser=this.map[u.name],this.parser)return this.parser.parseOpen(u),!0;throw new Error("Unexpected xml node in parseOpen: "+JSON.stringify(u))}}parseText(u){this.parser&&this.parser.parseText(u)}parseClose(u){if(this.parser)return this.parser.parseClose(u)||(this.parser=void 0),!0;switch(u){case"cp:coreProperties":case"coreProperties":return this.model={creator:this.map["dc:creator"].model,title:this.map["dc:title"].model,subject:this.map["dc:subject"].model,description:this.map["dc:description"].model,identifier:this.map["dc:identifier"].model,language:this.map["dc:language"].model,keywords:this.map["cp:keywords"].model,category:this.map["cp:category"].model,lastModifiedBy:this.map["cp:lastModifiedBy"].model,lastPrinted:this.map["cp:lastPrinted"].model,revision:this.map["cp:revision"].model,contentStatus:this.map["cp:contentStatus"].model,contentType:this.map["cp:contentType"].model,created:this.map["dcterms:created"].model,modified:this.map["dcterms:modified"].model},!1;default:throw new Error("Unexpected xml node in parseClose: "+u)}}}o.DateFormat=function(h){return h.toISOString().replace(/[.]\d{3}/,"")},o.DateAttrs={"xsi:type":"dcterms:W3CDTF"},o.CORE_PROPERTY_ATTRIBUTES={"xmlns:cp":"http://schemas.openxmlformats.org/package/2006/metadata/core-properties","xmlns:dc":"http://purl.org/dc/elements/1.1/","xmlns:dcterms":"http://purl.org/dc/terms/","xmlns:dcmitype":"http://purl.org/dc/dcmitype/","xmlns:xsi":"http://www.w3.org/2001/XMLSchema-instance"},a.exports=o},{"../../../utils/xml-stream":28,"../base-xform":32,"../simple/date-xform":117,"../simple/integer-xform":118,"../simple/string-xform":119}],54:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{render(s,l){s.leafNode("Relationship",l)}parseOpen(s){switch(s.name){case"Relationship":return this.model=s.attributes,!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],55:[function(e,a,f){const c=e("../../../utils/xml-stream"),s=e("../base-xform"),l=e("./relationship-xform");class i extends s{constructor(){super(),this.map={Relationship:new l}}render(o,h){h=h||this._values,o.openXml(c.StdDocAttributes),o.openNode("Relationships",i.RELATIONSHIPS_ATTRIBUTES),h.forEach(u=>{this.map.Relationship.render(o,u)}),o.closeNode()}parseOpen(o){if(this.parser)return this.parser.parseOpen(o),!0;switch(o.name){case"Relationships":return this.model=[],!0;default:if(this.parser=this.map[o.name],this.parser)return this.parser.parseOpen(o),!0;throw new Error("Unexpected xml node in parseOpen: "+JSON.stringify(o))}}parseText(o){this.parser&&this.parser.parseText(o)}parseClose(o){if(this.parser)return this.parser.parseClose(o)||(this.model.push(this.parser.model),this.parser=void 0),!0;switch(o){case"Relationships":return!1;default:throw new Error("Unexpected xml node in parseClose: "+o)}}}i.RELATIONSHIPS_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/package/2006/relationships"},a.exports=i},{"../../../utils/xml-stream":28,"../base-xform":32,"./relationship-xform":54}],56:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{parseOpen(s){if(this.parser)return this.parser.parseOpen(s),!0;switch(s.name){case this.tag:this.reset(),this.model={range:{editAs:s.attributes.editAs||"oneCell"}};break;default:this.parser=this.map[s.name],this.parser&&this.parser.parseOpen(s)}return!0}parseText(s){this.parser&&this.parser.parseText(s)}reconcilePicture(s,l){if(s&&s.rId){const i=l.rels[s.rId].Target.match(/.*\/media\/(.+[.][a-zA-Z]{3,4})/);if(i){const n=i[1],o=l.mediaIndex[n];return l.media[o]}}}}},{"../base-xform":32}],57:[function(e,a,f){const c=e("../base-xform"),s=e("./blip-xform");a.exports=class extends c{constructor(){super(),this.map={"a:blip":new s}}get tag(){return"xdr:blipFill"}render(l,i){l.openNode(this.tag),this.map["a:blip"].render(l,i),l.openNode("a:stretch"),l.leafNode("a:fillRect"),l.closeNode(),l.closeNode()}parseOpen(l){if(this.parser)return this.parser.parseOpen(l),!0;switch(l.name){case this.tag:this.reset();break;default:this.parser=this.map[l.name],this.parser&&this.parser.parseOpen(l)}return!0}parseText(){}parseClose(l){if(this.parser)return this.parser.parseClose(l)||(this.parser=void 0),!0;switch(l){case this.tag:return this.model=this.map["a:blip"].model,!1;default:return!0}}}},{"../base-xform":32,"./blip-xform":58}],58:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"a:blip"}render(s,l){s.leafNode(this.tag,{"xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships","r:embed":l.rId,cstate:"print"})}parseOpen(s){switch(s.name){case this.tag:return this.model={rId:s.attributes["r:embed"]},!0;default:return!0}}parseText(){}parseClose(s){switch(s){case this.tag:return!1;default:return!0}}}},{"../base-xform":32}],59:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"xdr:cNvPicPr"}render(s){s.openNode(this.tag),s.leafNode("a:picLocks",{noChangeAspect:"1"}),s.closeNode()}parseOpen(s){switch(s.name){case this.tag:default:return!0}}parseText(){}parseClose(s){switch(s){case this.tag:return!1;default:return!0}}}},{"../base-xform":32}],60:[function(e,a,f){const c=e("../base-xform"),s=e("./hlink-click-xform"),l=e("./ext-lst-xform");a.exports=class extends c{constructor(){super(),this.map={"a:hlinkClick":new s,"a:extLst":new l}}get tag(){return"xdr:cNvPr"}render(i,n){i.openNode(this.tag,{id:n.index,name:"Picture "+n.index}),this.map["a:hlinkClick"].render(i,n),this.map["a:extLst"].render(i,n),i.closeNode()}parseOpen(i){if(this.parser)return this.parser.parseOpen(i),!0;switch(i.name){case this.tag:this.reset();break;default:this.parser=this.map[i.name],this.parser&&this.parser.parseOpen(i)}return!0}parseText(){}parseClose(i){if(this.parser)return this.parser.parseClose(i)||(this.parser=void 0),!0;switch(i){case this.tag:return this.model=this.map["a:hlinkClick"].model,!1;default:return!0}}}},{"../base-xform":32,"./ext-lst-xform":63,"./hlink-click-xform":65}],61:[function(e,a,f){const c=e("../base-xform"),s=e("../simple/integer-xform");a.exports=class extends c{constructor(l){super(),this.tag=l.tag,this.map={"xdr:col":new s({tag:"xdr:col",zero:!0}),"xdr:colOff":new s({tag:"xdr:colOff",zero:!0}),"xdr:row":new s({tag:"xdr:row",zero:!0}),"xdr:rowOff":new s({tag:"xdr:rowOff",zero:!0})}}render(l,i){l.openNode(this.tag),this.map["xdr:col"].render(l,i.nativeCol),this.map["xdr:colOff"].render(l,i.nativeColOff),this.map["xdr:row"].render(l,i.nativeRow),this.map["xdr:rowOff"].render(l,i.nativeRowOff),l.closeNode()}parseOpen(l){if(this.parser)return this.parser.parseOpen(l),!0;switch(l.name){case this.tag:this.reset();break;default:this.parser=this.map[l.name],this.parser&&this.parser.parseOpen(l)}return!0}parseText(l){this.parser&&this.parser.parseText(l)}parseClose(l){if(this.parser)return this.parser.parseClose(l)||(this.parser=void 0),!0;switch(l){case this.tag:return this.model={nativeCol:this.map["xdr:col"].model,nativeColOff:this.map["xdr:colOff"].model,nativeRow:this.map["xdr:row"].model,nativeRowOff:this.map["xdr:rowOff"].model},!1;default:return!0}}}},{"../base-xform":32,"../simple/integer-xform":118}],62:[function(e,a,f){const c=e("../../../utils/col-cache"),s=e("../../../utils/xml-stream"),l=e("../base-xform"),i=e("./two-cell-anchor-xform"),n=e("./one-cell-anchor-xform");class o extends l{constructor(){super(),this.map={"xdr:twoCellAnchor":new i,"xdr:oneCellAnchor":new n}}prepare(u){u.anchors.forEach((d,m)=>{d.anchorType=function(b){return(typeof b.range=="string"?c.decode(b.range):b.range).br?"xdr:twoCellAnchor":"xdr:oneCellAnchor"}(d),this.map[d.anchorType].prepare(d,{index:m})})}get tag(){return"xdr:wsDr"}render(u,d){u.openXml(s.StdDocAttributes),u.openNode(this.tag,o.DRAWING_ATTRIBUTES),d.anchors.forEach(m=>{this.map[m.anchorType].render(u,m)}),u.closeNode()}parseOpen(u){if(this.parser)return this.parser.parseOpen(u),!0;switch(u.name){case this.tag:this.reset(),this.model={anchors:[]};break;default:this.parser=this.map[u.name],this.parser&&this.parser.parseOpen(u)}return!0}parseText(u){this.parser&&this.parser.parseText(u)}parseClose(u){if(this.parser)return this.parser.parseClose(u)||(this.model.anchors.push(this.parser.model),this.parser=void 0),!0;switch(u){case this.tag:return!1;default:return!0}}reconcile(u,d){u.anchors.forEach(m=>{m.br?this.map["xdr:twoCellAnchor"].reconcile(m,d):this.map["xdr:oneCellAnchor"].reconcile(m,d)})}}o.DRAWING_ATTRIBUTES={"xmlns:xdr":"http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing","xmlns:a":"http://schemas.openxmlformats.org/drawingml/2006/main"},a.exports=o},{"../../../utils/col-cache":19,"../../../utils/xml-stream":28,"../base-xform":32,"./one-cell-anchor-xform":67,"./two-cell-anchor-xform":70}],63:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"a:extLst"}render(s){s.openNode(this.tag),s.openNode("a:ext",{uri:"{FF2B5EF4-FFF2-40B4-BE49-F238E27FC236}"}),s.leafNode("a16:creationId",{"xmlns:a16":"http://schemas.microsoft.com/office/drawing/2014/main",id:"{00000000-0008-0000-0000-000002000000}"}),s.closeNode(),s.closeNode()}parseOpen(s){switch(s.name){case this.tag:default:return!0}}parseText(){}parseClose(s){switch(s){case this.tag:return!1;default:return!0}}}},{"../base-xform":32}],64:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{constructor(s){super(),this.tag=s.tag,this.map={}}render(s,l){s.openNode(this.tag);const i=Math.floor(9525*l.width),n=Math.floor(9525*l.height);s.addAttribute("cx",i),s.addAttribute("cy",n),s.closeNode()}parseOpen(s){return s.name===this.tag&&(this.model={width:parseInt(s.attributes.cx||"0",10)/9525,height:parseInt(s.attributes.cy||"0",10)/9525},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],65:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"a:hlinkClick"}render(s,l){l.hyperlinks&&l.hyperlinks.rId&&s.leafNode(this.tag,{"xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships","r:id":l.hyperlinks.rId,tooltip:l.hyperlinks.tooltip})}parseOpen(s){switch(s.name){case this.tag:return this.model={hyperlinks:{rId:s.attributes["r:id"],tooltip:s.attributes.tooltip}},!0;default:return!0}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],66:[function(e,a,f){const c=e("../base-xform"),s=e("./c-nv-pr-xform"),l=e("./c-nv-pic-pr-xform");a.exports=class extends c{constructor(){super(),this.map={"xdr:cNvPr":new s,"xdr:cNvPicPr":new l}}get tag(){return"xdr:nvPicPr"}render(i,n){i.openNode(this.tag),this.map["xdr:cNvPr"].render(i,n),this.map["xdr:cNvPicPr"].render(i,n),i.closeNode()}parseOpen(i){if(this.parser)return this.parser.parseOpen(i),!0;switch(i.name){case this.tag:this.reset();break;default:this.parser=this.map[i.name],this.parser&&this.parser.parseOpen(i)}return!0}parseText(){}parseClose(i){if(this.parser)return this.parser.parseClose(i)||(this.parser=void 0),!0;switch(i){case this.tag:return this.model=this.map["xdr:cNvPr"].model,!1;default:return!0}}}},{"../base-xform":32,"./c-nv-pic-pr-xform":59,"./c-nv-pr-xform":60}],67:[function(e,a,f){const c=e("./base-cell-anchor-xform"),s=e("../static-xform"),l=e("./cell-position-xform"),i=e("./ext-xform"),n=e("./pic-xform");a.exports=class extends c{constructor(){super(),this.map={"xdr:from":new l({tag:"xdr:from"}),"xdr:ext":new i({tag:"xdr:ext"}),"xdr:pic":new n,"xdr:clientData":new s({tag:"xdr:clientData"})}}get tag(){return"xdr:oneCellAnchor"}prepare(o,h){this.map["xdr:pic"].prepare(o.picture,h)}render(o,h){o.openNode(this.tag,{editAs:h.range.editAs||"oneCell"}),this.map["xdr:from"].render(o,h.range.tl),this.map["xdr:ext"].render(o,h.range.ext),this.map["xdr:pic"].render(o,h.picture),this.map["xdr:clientData"].render(o,{}),o.closeNode()}parseClose(o){if(this.parser)return this.parser.parseClose(o)||(this.parser=void 0),!0;switch(o){case this.tag:return this.model.range.tl=this.map["xdr:from"].model,this.model.range.ext=this.map["xdr:ext"].model,this.model.picture=this.map["xdr:pic"].model,!1;default:return!0}}reconcile(o,h){o.medium=this.reconcilePicture(o.picture,h)}}},{"../static-xform":120,"./base-cell-anchor-xform":56,"./cell-position-xform":61,"./ext-xform":64,"./pic-xform":68}],68:[function(e,a,f){const c=e("../base-xform"),s=e("../static-xform"),l=e("./blip-fill-xform"),i=e("./nv-pic-pr-xform"),n=e("./sp-pr");a.exports=class extends c{constructor(){super(),this.map={"xdr:nvPicPr":new i,"xdr:blipFill":new l,"xdr:spPr":new s(n)}}get tag(){return"xdr:pic"}prepare(o,h){o.index=h.index+1}render(o,h){o.openNode(this.tag),this.map["xdr:nvPicPr"].render(o,h),this.map["xdr:blipFill"].render(o,h),this.map["xdr:spPr"].render(o,h),o.closeNode()}parseOpen(o){if(this.parser)return this.parser.parseOpen(o),!0;switch(o.name){case this.tag:this.reset();break;default:this.parser=this.map[o.name],this.parser&&this.parser.parseOpen(o)}return!0}parseText(){}parseClose(o){if(this.parser)return this.parser.parseClose(o)||(this.mergeModel(this.parser.model),this.parser=void 0),!0;switch(o){case this.tag:return!1;default:return!0}}}},{"../base-xform":32,"../static-xform":120,"./blip-fill-xform":57,"./nv-pic-pr-xform":66,"./sp-pr":69}],69:[function(e,a,f){a.exports={tag:"xdr:spPr",c:[{tag:"a:xfrm",c:[{tag:"a:off",$:{x:"0",y:"0"}},{tag:"a:ext",$:{cx:"0",cy:"0"}}]},{tag:"a:prstGeom",$:{prst:"rect"},c:[{tag:"a:avLst"}]}]}},{}],70:[function(e,a,f){const c=e("./base-cell-anchor-xform"),s=e("../static-xform"),l=e("./cell-position-xform"),i=e("./pic-xform");a.exports=class extends c{constructor(){super(),this.map={"xdr:from":new l({tag:"xdr:from"}),"xdr:to":new l({tag:"xdr:to"}),"xdr:pic":new i,"xdr:clientData":new s({tag:"xdr:clientData"})}}get tag(){return"xdr:twoCellAnchor"}prepare(n,o){this.map["xdr:pic"].prepare(n.picture,o)}render(n,o){n.openNode(this.tag,{editAs:o.range.editAs||"oneCell"}),this.map["xdr:from"].render(n,o.range.tl),this.map["xdr:to"].render(n,o.range.br),this.map["xdr:pic"].render(n,o.picture),this.map["xdr:clientData"].render(n,{}),n.closeNode()}parseClose(n){if(this.parser)return this.parser.parseClose(n)||(this.parser=void 0),!0;switch(n){case this.tag:return this.model.range.tl=this.map["xdr:from"].model,this.model.range.br=this.map["xdr:to"].model,this.model.picture=this.map["xdr:pic"].model,!1;default:return!0}}reconcile(n,o){n.medium=this.reconcilePicture(n.picture,o)}}},{"../static-xform":120,"./base-cell-anchor-xform":56,"./cell-position-xform":61,"./pic-xform":68}],71:[function(e,a,f){const c=e("./base-xform");a.exports=class extends c{constructor(s){super(),this.tag=s.tag,this.always=!!s.always,this.count=s.count,this.empty=s.empty,this.$count=s.$count||"count",this.$=s.$,this.childXform=s.childXform,this.maxItems=s.maxItems}prepare(s,l){const{childXform:i}=this;s&&s.forEach((n,o)=>{l.index=o,i.prepare(n,l)})}render(s,l){if(this.always||l&&l.length){s.openNode(this.tag,this.$),this.count&&s.addAttribute(this.$count,l&&l.length||0);const{childXform:i}=this;(l||[]).forEach((n,o)=>{i.render(s,n,o)}),s.closeNode()}else this.empty&&s.leafNode(this.tag)}parseOpen(s){if(this.parser)return this.parser.parseOpen(s),!0;switch(s.name){case this.tag:return this.model=[],!0;default:return!!this.childXform.parseOpen(s)&&(this.parser=this.childXform,!0)}}parseText(s){this.parser&&this.parser.parseText(s)}parseClose(s){if(this.parser){if(!this.parser.parseClose(s)&&(this.model.push(this.parser.model),this.parser=void 0,this.maxItems&&this.model.length>this.maxItems))throw new Error(`Max ${this.childXform.tag} count (${this.maxItems}) exceeded`);return!0}return!1}reconcile(s,l){if(s){const{childXform:i}=this;s.forEach(n=>{i.reconcile(n,l)})}}}},{"./base-xform":32}],72:[function(e,a,f){const c=e("../../../utils/col-cache"),s=e("../base-xform");a.exports=class extends s{get tag(){return"autoFilter"}render(l,i){if(i)if(typeof i=="string")l.leafNode("autoFilter",{ref:i});else{const n=function(u){return typeof u=="string"?u:c.getAddress(u.row,u.column).address},o=n(i.from),h=n(i.to);o&&h&&l.leafNode("autoFilter",{ref:`${o}:${h}`})}}parseOpen(l){l.name==="autoFilter"&&(this.model=l.attributes.ref)}}},{"../../../utils/col-cache":19,"../base-xform":32}],73:[function(e,a,f){const c=e("../../../utils/utils"),s=e("../base-xform"),l=e("../../../doc/range"),i=e("../../../doc/enums"),n=e("../strings/rich-text-xform");function o(h){if(h==null)return i.ValueType.Null;if(h instanceof String||typeof h=="string")return i.ValueType.String;if(typeof h=="number")return i.ValueType.Number;if(typeof h=="boolean")return i.ValueType.Boolean;if(h instanceof Date)return i.ValueType.Date;if(h.text&&h.hyperlink)return i.ValueType.Hyperlink;if(h.formula)return i.ValueType.Formula;if(h.error)return i.ValueType.Error;throw new Error("I could not understand type of value")}a.exports=class extends s{constructor(){super(),this.richTextXForm=new n}get tag(){return"c"}prepare(h,u){const d=u.styles.addStyleModel(h.style||{},function(m){switch(m.type){case i.ValueType.Formula:return o(m.result);default:return m.type}}(h));switch(d&&(h.styleId=d),h.comment&&u.comments.push({...h.comment,ref:h.address}),h.type){case i.ValueType.String:case i.ValueType.RichText:u.sharedStrings&&(h.ssId=u.sharedStrings.add(h.value));break;case i.ValueType.Date:u.date1904&&(h.date1904=!0);break;case i.ValueType.Hyperlink:u.sharedStrings&&h.text!==void 0&&h.text!==null&&(h.ssId=u.sharedStrings.add(h.text)),u.hyperlinks.push({address:h.address,target:h.hyperlink,tooltip:h.tooltip});break;case i.ValueType.Merge:u.merges.add(h);break;case i.ValueType.Formula:if(u.date1904&&(h.date1904=!0),h.shareType==="shared"&&(h.si=u.siFormulae++),h.formula)u.formulae[h.address]=h;else if(h.sharedFormula){const m=u.formulae[h.sharedFormula];if(!m)throw new Error("Shared Formula master must exist above and or left of clone for cell "+h.address);m.si===void 0?(m.shareType="shared",m.si=u.siFormulae++,m.range=new l(m.address,h.address)):m.range&&m.range.expandToAddress(h.address),h.si=m.si}}}renderFormula(h,u){let d=null;switch(u.shareType){case"shared":d={t:"shared",ref:u.ref||u.range.range,si:u.si};break;case"array":d={t:"array",ref:u.ref};break;default:u.si!==void 0&&(d={t:"shared",si:u.si})}switch(o(u.result)){case i.ValueType.Null:h.leafNode("f",d,u.formula);break;case i.ValueType.String:h.addAttribute("t","str"),h.leafNode("f",d,u.formula),h.leafNode("v",null,u.result);break;case i.ValueType.Number:h.leafNode("f",d,u.formula),h.leafNode("v",null,u.result);break;case i.ValueType.Boolean:h.addAttribute("t","b"),h.leafNode("f",d,u.formula),h.leafNode("v",null,u.result?1:0);break;case i.ValueType.Error:h.addAttribute("t","e"),h.leafNode("f",d,u.formula),h.leafNode("v",null,u.result.error);break;case i.ValueType.Date:h.leafNode("f",d,u.formula),h.leafNode("v",null,c.dateToExcel(u.result,u.date1904));break;default:throw new Error("I could not understand type of value")}}render(h,u){if(u.type!==i.ValueType.Null||u.styleId){switch(h.openNode("c"),h.addAttribute("r",u.address),u.styleId&&h.addAttribute("s",u.styleId),u.type){case i.ValueType.Null:break;case i.ValueType.Number:h.leafNode("v",null,u.value);break;case i.ValueType.Boolean:h.addAttribute("t","b"),h.leafNode("v",null,u.value?"1":"0");break;case i.ValueType.Error:h.addAttribute("t","e"),h.leafNode("v",null,u.value.error);break;case i.ValueType.String:case i.ValueType.RichText:u.ssId!==void 0?(h.addAttribute("t","s"),h.leafNode("v",null,u.ssId)):u.value&&u.value.richText?(h.addAttribute("t","inlineStr"),h.openNode("is"),u.value.richText.forEach(d=>{this.richTextXForm.render(h,d)}),h.closeNode("is")):(h.addAttribute("t","str"),h.leafNode("v",null,u.value));break;case i.ValueType.Date:h.leafNode("v",null,c.dateToExcel(u.value,u.date1904));break;case i.ValueType.Hyperlink:u.ssId!==void 0?(h.addAttribute("t","s"),h.leafNode("v",null,u.ssId)):(h.addAttribute("t","str"),h.leafNode("v",null,u.text));break;case i.ValueType.Formula:this.renderFormula(h,u);break;case i.ValueType.Merge:}h.closeNode()}}parseOpen(h){if(this.parser)return this.parser.parseOpen(h),!0;switch(h.name){case"c":return this.model={address:h.attributes.r},this.t=h.attributes.t,h.attributes.s&&(this.model.styleId=parseInt(h.attributes.s,10)),!0;case"f":return this.currentNode="f",this.model.si=h.attributes.si,this.model.shareType=h.attributes.t,this.model.ref=h.attributes.ref,!0;case"v":return this.currentNode="v",!0;case"t":return this.currentNode="t",!0;case"r":return this.parser=this.richTextXForm,this.parser.parseOpen(h),!0;default:return!1}}parseText(h){if(this.parser)this.parser.parseText(h);else switch(this.currentNode){case"f":this.model.formula=this.model.formula?this.model.formula+h:h;break;case"v":case"t":this.model.value&&this.model.value.richText?this.model.value.richText.text=this.model.value.richText.text?this.model.value.richText.text+h:h:this.model.value=this.model.value?this.model.value+h:h}}parseClose(h){switch(h){case"c":{const{model:u}=this;if(u.formula||u.shareType)u.type=i.ValueType.Formula,u.value&&(this.t==="str"?u.result=c.xmlDecode(u.value):this.t==="b"?u.result=parseInt(u.value,10)!==0:this.t==="e"?u.result={error:u.value}:u.result=parseFloat(u.value),u.value=void 0);else if(u.value!==void 0)switch(this.t){case"s":u.type=i.ValueType.String,u.value=parseInt(u.value,10);break;case"str":u.type=i.ValueType.String,u.value=c.xmlDecode(u.value);break;case"inlineStr":u.type=i.ValueType.String;break;case"b":u.type=i.ValueType.Boolean,u.value=parseInt(u.value,10)!==0;break;case"e":u.type=i.ValueType.Error,u.value={error:u.value};break;default:u.type=i.ValueType.Number,u.value=parseFloat(u.value)}else u.styleId?u.type=i.ValueType.Null:u.type=i.ValueType.Merge;return!1}case"f":case"v":case"is":return this.currentNode=void 0,!0;case"t":return this.parser?(this.parser.parseClose(h),!0):(this.currentNode=void 0,!0);case"r":return this.model.value=this.model.value||{},this.model.value.richText=this.model.value.richText||[],this.model.value.richText.push(this.parser.model),this.parser=void 0,this.currentNode=void 0,!0;default:return!!this.parser&&(this.parser.parseClose(h),!0)}}reconcile(h,u){const d=h.styleId&&u.styles&&u.styles.getStyleModel(h.styleId);switch(d&&(h.style=d),h.styleId!==void 0&&(h.styleId=void 0),h.type){case i.ValueType.String:typeof h.value=="number"&&u.sharedStrings&&(h.value=u.sharedStrings.getString(h.value)),h.value.richText&&(h.type=i.ValueType.RichText);break;case i.ValueType.Number:d&&c.isDateFmt(d.numFmt)&&(h.type=i.ValueType.Date,h.value=c.excelToDate(h.value,u.date1904));break;case i.ValueType.Formula:h.result!==void 0&&d&&c.isDateFmt(d.numFmt)&&(h.result=c.excelToDate(h.result,u.date1904)),h.shareType==="shared"&&(h.ref?u.formulae[h.si]=h.address:(h.sharedFormula=u.formulae[h.si],delete h.shareType),delete h.si)}const m=u.hyperlinkMap[h.address];m&&(h.type===i.ValueType.Formula?(h.text=h.result,h.result=void 0):(h.text=h.value,h.value=void 0),h.type=i.ValueType.Hyperlink,h.hyperlink=m);const b=u.commentsMap&&u.commentsMap[h.address];b&&(h.comment=b)}}},{"../../../doc/enums":7,"../../../doc/range":10,"../../../utils/utils":27,"../base-xform":32,"../strings/rich-text-xform":122}],74:[function(e,a,f){const c=e("../../base-xform");a.exports=class extends c{get tag(){return"x14:cfIcon"}render(s,l){s.leafNode(this.tag,{iconSet:l.iconSet,iconId:l.iconId})}parseOpen(s){let{attributes:l}=s;this.model={iconSet:l.iconSet,iconId:c.toIntValue(l.iconId)}}parseClose(s){return s!==this.tag}}},{"../../base-xform":32}],75:[function(e,a,f){const{v4:c}=e("uuid"),s=e("../../base-xform"),l=e("../../composite-xform"),i=e("./databar-ext-xform"),n=e("./icon-set-ext-xform"),o={"3Triangles":!0,"3Stars":!0,"5Boxes":!0};class h extends l{constructor(){super(),this.map={"x14:dataBar":this.databarXform=new i,"x14:iconSet":this.iconSetXform=new n}}get tag(){return"x14:cfRule"}static isExt(d){return d.type==="dataBar"?i.isExt(d):!(d.type!=="iconSet"||!d.custom&&!o[d.iconSet])}prepare(d){h.isExt(d)&&(d.x14Id=`{${c()}}`.toUpperCase())}render(d,m){if(h.isExt(m))switch(m.type){case"dataBar":this.renderDataBar(d,m);break;case"iconSet":this.renderIconSet(d,m)}}renderDataBar(d,m){d.openNode(this.tag,{type:"dataBar",id:m.x14Id}),this.databarXform.render(d,m),d.closeNode()}renderIconSet(d,m){d.openNode(this.tag,{type:"iconSet",priority:m.priority,id:m.x14Id||`{${c()}}`}),this.iconSetXform.render(d,m),d.closeNode()}createNewModel(d){let{attributes:m}=d;return{type:m.type,x14Id:m.id,priority:s.toIntValue(m.priority)}}onParserClose(d,m){Object.assign(this.model,m.model)}}a.exports=h},{"../../base-xform":32,"../../composite-xform":48,"./databar-ext-xform":79,"./icon-set-ext-xform":81,uuid:528}],76:[function(e,a,f){const c=e("../../composite-xform"),s=e("./f-ext-xform");a.exports=class extends c{constructor(){super(),this.map={"xm:f":this.fExtXform=new s}}get tag(){return"x14:cfvo"}render(l,i){l.openNode(this.tag,{type:i.type}),i.value!==void 0&&this.fExtXform.render(l,i.value),l.closeNode()}createNewModel(l){return{type:l.attributes.type}}onParserClose(l,i){switch(l){case"xm:f":this.model.value=i.model?parseFloat(i.model):0}}}},{"../../composite-xform":48,"./f-ext-xform":80}],77:[function(e,a,f){const c=e("../../composite-xform"),s=e("./sqref-ext-xform"),l=e("./cf-rule-ext-xform");a.exports=class extends c{constructor(){super(),this.map={"xm:sqref":this.sqRef=new s,"x14:cfRule":this.cfRule=new l}}get tag(){return"x14:conditionalFormatting"}prepare(i,n){i.rules.forEach(o=>{this.cfRule.prepare(o,n)})}render(i,n){n.rules.some(l.isExt)&&(i.openNode(this.tag,{"xmlns:xm":"http://schemas.microsoft.com/office/excel/2006/main"}),n.rules.filter(l.isExt).forEach(o=>this.cfRule.render(i,o)),this.sqRef.render(i,n.ref),i.closeNode())}createNewModel(){return{rules:[]}}onParserClose(i,n){switch(i){case"xm:sqref":this.model.ref=n.model;break;case"x14:cfRule":this.model.rules.push(n.model)}}}},{"../../composite-xform":48,"./cf-rule-ext-xform":75,"./sqref-ext-xform":82}],78:[function(e,a,f){const c=e("../../composite-xform"),s=e("./cf-rule-ext-xform"),l=e("./conditional-formatting-ext-xform");a.exports=class extends c{constructor(){super(),this.map={"x14:conditionalFormatting":this.cfXform=new l}}get tag(){return"x14:conditionalFormattings"}hasContent(i){return i.hasExtContent===void 0&&(i.hasExtContent=i.some(n=>n.rules.some(s.isExt))),i.hasExtContent}prepare(i,n){i.forEach(o=>{this.cfXform.prepare(o,n)})}render(i,n){this.hasContent(n)&&(i.openNode(this.tag),n.forEach(o=>this.cfXform.render(i,o)),i.closeNode())}createNewModel(){return[]}onParserClose(i,n){this.model.push(n.model)}}},{"../../composite-xform":48,"./cf-rule-ext-xform":75,"./conditional-formatting-ext-xform":77}],79:[function(e,a,f){const c=e("../../base-xform"),s=e("../../composite-xform"),l=e("../../style/color-xform"),i=e("./cfvo-ext-xform");a.exports=class extends s{constructor(){super(),this.map={"x14:cfvo":this.cfvoXform=new i,"x14:borderColor":this.borderColorXform=new l("x14:borderColor"),"x14:negativeBorderColor":this.negativeBorderColorXform=new l("x14:negativeBorderColor"),"x14:negativeFillColor":this.negativeFillColorXform=new l("x14:negativeFillColor"),"x14:axisColor":this.axisColorXform=new l("x14:axisColor")}}static isExt(n){return!n.gradient}get tag(){return"x14:dataBar"}render(n,o){n.openNode(this.tag,{minLength:c.toIntAttribute(o.minLength,0,!0),maxLength:c.toIntAttribute(o.maxLength,100,!0),border:c.toBoolAttribute(o.border,!1),gradient:c.toBoolAttribute(o.gradient,!0),negativeBarColorSameAsPositive:c.toBoolAttribute(o.negativeBarColorSameAsPositive,!0),negativeBarBorderColorSameAsPositive:c.toBoolAttribute(o.negativeBarBorderColorSameAsPositive,!0),axisPosition:c.toAttribute(o.axisPosition,"auto"),direction:c.toAttribute(o.direction,"leftToRight")}),o.cfvo.forEach(h=>{this.cfvoXform.render(n,h)}),this.borderColorXform.render(n,o.borderColor),this.negativeBorderColorXform.render(n,o.negativeBorderColor),this.negativeFillColorXform.render(n,o.negativeFillColor),this.axisColorXform.render(n,o.axisColor),n.closeNode()}createNewModel(n){let{attributes:o}=n;return{cfvo:[],minLength:c.toIntValue(o.minLength,0),maxLength:c.toIntValue(o.maxLength,100),border:c.toBoolValue(o.border,!1),gradient:c.toBoolValue(o.gradient,!0),negativeBarColorSameAsPositive:c.toBoolValue(o.negativeBarColorSameAsPositive,!0),negativeBarBorderColorSameAsPositive:c.toBoolValue(o.negativeBarBorderColorSameAsPositive,!0),axisPosition:c.toStringValue(o.axisPosition,"auto"),direction:c.toStringValue(o.direction,"leftToRight")}}onParserClose(n,o){const[,h]=n.split(":");switch(h){case"cfvo":this.model.cfvo.push(o.model);break;default:this.model[h]=o.model}}}},{"../../base-xform":32,"../../composite-xform":48,"../../style/color-xform":128,"./cfvo-ext-xform":76}],80:[function(e,a,f){const c=e("../../base-xform");a.exports=class extends c{get tag(){return"xm:f"}render(s,l){s.leafNode(this.tag,null,l)}parseOpen(){this.model=""}parseText(s){this.model+=s}parseClose(s){return s!==this.tag}}},{"../../base-xform":32}],81:[function(e,a,f){const c=e("../../base-xform"),s=e("../../composite-xform"),l=e("./cfvo-ext-xform"),i=e("./cf-icon-ext-xform");a.exports=class extends s{constructor(){super(),this.map={"x14:cfvo":this.cfvoXform=new l,"x14:cfIcon":this.cfIconXform=new i}}get tag(){return"x14:iconSet"}render(n,o){n.openNode(this.tag,{iconSet:c.toStringAttribute(o.iconSet),reverse:c.toBoolAttribute(o.reverse,!1),showValue:c.toBoolAttribute(o.showValue,!0),custom:c.toBoolAttribute(o.icons,!1)}),o.cfvo.forEach(h=>{this.cfvoXform.render(n,h)}),o.icons&&o.icons.forEach((h,u)=>{h.iconId=u,this.cfIconXform.render(n,h)}),n.closeNode()}createNewModel(n){let{attributes:o}=n;return{cfvo:[],iconSet:c.toStringValue(o.iconSet,"3TrafficLights"),reverse:c.toBoolValue(o.reverse,!1),showValue:c.toBoolValue(o.showValue,!0)}}onParserClose(n,o){const[,h]=n.split(":");switch(h){case"cfvo":this.model.cfvo.push(o.model);break;case"cfIcon":this.model.icons||(this.model.icons=[]),this.model.icons.push(o.model);break;default:this.model[h]=o.model}}}},{"../../base-xform":32,"../../composite-xform":48,"./cf-icon-ext-xform":74,"./cfvo-ext-xform":76}],82:[function(e,a,f){const c=e("../../base-xform");a.exports=class extends c{get tag(){return"xm:sqref"}render(s,l){s.leafNode(this.tag,null,l)}parseOpen(){this.model=""}parseText(s){this.model+=s}parseClose(s){return s!==this.tag}}},{"../../base-xform":32}],83:[function(e,a,f){const c=e("../../base-xform"),s=e("../../composite-xform"),l=e("../../../../doc/range"),i=e("./databar-xform"),n=e("./ext-lst-ref-xform"),o=e("./formula-xform"),h=e("./color-scale-xform"),u=e("./icon-set-xform"),d={"3Triangles":!0,"3Stars":!0,"5Boxes":!0},m=p=>{const{type:v,operator:g}=p;switch(v){case"containsText":case"containsBlanks":case"notContainsBlanks":case"containsErrors":case"notContainsErrors":return{type:"containsText",operator:v};default:return{type:v,operator:g}}};class b extends s{constructor(){super(),this.map={dataBar:this.databarXform=new i,extLst:this.extLstRefXform=new n,formula:this.formulaXform=new o,colorScale:this.colorScaleXform=new h,iconSet:this.iconSetXform=new u}}get tag(){return"cfRule"}static isPrimitive(v){return v.type!=="iconSet"||!v.custom&&!d[v.iconSet]}render(v,g){switch(g.type){case"expression":this.renderExpression(v,g);break;case"cellIs":this.renderCellIs(v,g);break;case"top10":this.renderTop10(v,g);break;case"aboveAverage":this.renderAboveAverage(v,g);break;case"dataBar":this.renderDataBar(v,g);break;case"colorScale":this.renderColorScale(v,g);break;case"iconSet":this.renderIconSet(v,g);break;case"containsText":this.renderText(v,g);break;case"timePeriod":this.renderTimePeriod(v,g)}}renderExpression(v,g){v.openNode(this.tag,{type:"expression",dxfId:g.dxfId,priority:g.priority}),this.formulaXform.render(v,g.formulae[0]),v.closeNode()}renderCellIs(v,g){v.openNode(this.tag,{type:"cellIs",dxfId:g.dxfId,priority:g.priority,operator:g.operator}),g.formulae.forEach(x=>{this.formulaXform.render(v,x)}),v.closeNode()}renderTop10(v,g){v.leafNode(this.tag,{type:"top10",dxfId:g.dxfId,priority:g.priority,percent:c.toBoolAttribute(g.percent,!1),bottom:c.toBoolAttribute(g.bottom,!1),rank:c.toIntValue(g.rank,10,!0)})}renderAboveAverage(v,g){v.leafNode(this.tag,{type:"aboveAverage",dxfId:g.dxfId,priority:g.priority,aboveAverage:c.toBoolAttribute(g.aboveAverage,!0)})}renderDataBar(v,g){v.openNode(this.tag,{type:"dataBar",priority:g.priority}),this.databarXform.render(v,g),this.extLstRefXform.render(v,g),v.closeNode()}renderColorScale(v,g){v.openNode(this.tag,{type:"colorScale",priority:g.priority}),this.colorScaleXform.render(v,g),v.closeNode()}renderIconSet(v,g){b.isPrimitive(g)&&(v.openNode(this.tag,{type:"iconSet",priority:g.priority}),this.iconSetXform.render(v,g),v.closeNode())}renderText(v,g){v.openNode(this.tag,{type:g.operator,dxfId:g.dxfId,priority:g.priority,operator:c.toStringAttribute(g.operator,"containsText")});const x=(C=>{if(C.formulae&&C.formulae[0])return C.formulae[0];const T=new l(C.ref),{tl:R}=T;switch(C.operator){case"containsText":return`NOT(ISERROR(SEARCH("${C.text}",${R})))`;case"containsBlanks":return`LEN(TRIM(${R}))=0`;case"notContainsBlanks":return`LEN(TRIM(${R}))>0`;case"containsErrors":return`ISERROR(${R})`;case"notContainsErrors":return`NOT(ISERROR(${R}))`;default:return}})(g);x&&this.formulaXform.render(v,x),v.closeNode()}renderTimePeriod(v,g){v.openNode(this.tag,{type:"timePeriod",dxfId:g.dxfId,priority:g.priority,timePeriod:g.timePeriod});const x=(C=>{if(C.formulae&&C.formulae[0])return C.formulae[0];const T=new l(C.ref),{tl:R}=T;switch(C.timePeriod){case"thisWeek":return`AND(TODAY()-ROUNDDOWN(${R},0)<=WEEKDAY(TODAY())-1,ROUNDDOWN(${R},0)-TODAY()<=7-WEEKDAY(TODAY()))`;case"lastWeek":return`AND(TODAY()-ROUNDDOWN(${R},0)>=(WEEKDAY(TODAY())),TODAY()-ROUNDDOWN(${R},0)<(WEEKDAY(TODAY())+7))`;case"nextWeek":return`AND(ROUNDDOWN(${R},0)-TODAY()>(7-WEEKDAY(TODAY())),ROUNDDOWN(${R},0)-TODAY()<(15-WEEKDAY(TODAY())))`;case"yesterday":return`FLOOR(${R},1)=TODAY()-1`;case"today":return`FLOOR(${R},1)=TODAY()`;case"tomorrow":return`FLOOR(${R},1)=TODAY()+1`;case"last7Days":return`AND(TODAY()-FLOOR(${R},1)<=6,FLOOR(${R},1)<=TODAY())`;case"lastMonth":return`AND(MONTH(${R})=MONTH(EDATE(TODAY(),0-1)),YEAR(${R})=YEAR(EDATE(TODAY(),0-1)))`;case"thisMonth":return`AND(MONTH(${R})=MONTH(TODAY()),YEAR(${R})=YEAR(TODAY()))`;case"nextMonth":return`AND(MONTH(${R})=MONTH(EDATE(TODAY(),0+1)),YEAR(${R})=YEAR(EDATE(TODAY(),0+1)))`;default:return}})(g);x&&this.formulaXform.render(v,x),v.closeNode()}createNewModel(v){let{attributes:g}=v;return{...m(g),dxfId:c.toIntValue(g.dxfId),priority:c.toIntValue(g.priority),timePeriod:g.timePeriod,percent:c.toBoolValue(g.percent),bottom:c.toBoolValue(g.bottom),rank:c.toIntValue(g.rank),aboveAverage:c.toBoolValue(g.aboveAverage)}}onParserClose(v,g){switch(v){case"dataBar":case"extLst":case"colorScale":case"iconSet":Object.assign(this.model,g.model);break;case"formula":this.model.formulae=this.model.formulae||[],this.model.formulae.push(g.model)}}}a.exports=b},{"../../../../doc/range":10,"../../base-xform":32,"../../composite-xform":48,"./color-scale-xform":85,"./databar-xform":88,"./ext-lst-ref-xform":89,"./formula-xform":90,"./icon-set-xform":91}],84:[function(e,a,f){const c=e("../../base-xform");a.exports=class extends c{get tag(){return"cfvo"}render(s,l){s.leafNode(this.tag,{type:l.type,val:l.value})}parseOpen(s){this.model={type:s.attributes.type,value:c.toFloatValue(s.attributes.val)}}parseClose(s){return s!==this.tag}}},{"../../base-xform":32}],85:[function(e,a,f){const c=e("../../composite-xform"),s=e("../../style/color-xform"),l=e("./cfvo-xform");a.exports=class extends c{constructor(){super(),this.map={cfvo:this.cfvoXform=new l,color:this.colorXform=new s}}get tag(){return"colorScale"}render(i,n){i.openNode(this.tag),n.cfvo.forEach(o=>{this.cfvoXform.render(i,o)}),n.color.forEach(o=>{this.colorXform.render(i,o)}),i.closeNode()}createNewModel(i){return{cfvo:[],color:[]}}onParserClose(i,n){this.model[i].push(n.model)}}},{"../../composite-xform":48,"../../style/color-xform":128,"./cfvo-xform":84}],86:[function(e,a,f){const c=e("../../composite-xform"),s=e("./cf-rule-xform");a.exports=class extends c{constructor(){super(),this.map={cfRule:new s}}get tag(){return"conditionalFormatting"}render(l,i){i.rules.some(s.isPrimitive)&&(l.openNode(this.tag,{sqref:i.ref}),i.rules.forEach(n=>{s.isPrimitive(n)&&(n.ref=i.ref,this.map.cfRule.render(l,n))}),l.closeNode())}createNewModel(l){let{attributes:i}=l;return{ref:i.sqref,rules:[]}}onParserClose(l,i){this.model.rules.push(i.model)}}},{"../../composite-xform":48,"./cf-rule-xform":83}],87:[function(e,a,f){const c=e("../../base-xform"),s=e("./conditional-formatting-xform");a.exports=class extends c{constructor(){super(),this.cfXform=new s}get tag(){return"conditionalFormatting"}reset(){this.model=[]}prepare(l,i){let n=l.reduce((o,h)=>Math.max(o,...h.rules.map(u=>u.priority||0)),1);l.forEach(o=>{o.rules.forEach(h=>{h.priority||(h.priority=n++),h.style&&(h.dxfId=i.styles.addDxfStyle(h.style))})})}render(l,i){i.forEach(n=>{this.cfXform.render(l,n)})}parseOpen(l){if(this.parser)return this.parser.parseOpen(l),!0;switch(l.name){case"conditionalFormatting":return this.parser=this.cfXform,this.parser.parseOpen(l),!0;default:return!1}}parseText(l){this.parser&&this.parser.parseText(l)}parseClose(l){return!!this.parser&&(!!this.parser.parseClose(l)||(this.model.push(this.parser.model),this.parser=void 0,!1))}reconcile(l,i){l.forEach(n=>{n.rules.forEach(o=>{o.dxfId!==void 0&&(o.style=i.styles.getDxfStyle(o.dxfId),delete o.dxfId)})})}}},{"../../base-xform":32,"./conditional-formatting-xform":86}],88:[function(e,a,f){const c=e("../../composite-xform"),s=e("../../style/color-xform"),l=e("./cfvo-xform");a.exports=class extends c{constructor(){super(),this.map={cfvo:this.cfvoXform=new l,color:this.colorXform=new s}}get tag(){return"dataBar"}render(i,n){i.openNode(this.tag),n.cfvo.forEach(o=>{this.cfvoXform.render(i,o)}),this.colorXform.render(i,n.color),i.closeNode()}createNewModel(){return{cfvo:[]}}onParserClose(i,n){switch(i){case"cfvo":this.model.cfvo.push(n.model);break;case"color":this.model.color=n.model}}}},{"../../composite-xform":48,"../../style/color-xform":128,"./cfvo-xform":84}],89:[function(e,a,f){const c=e("../../base-xform"),s=e("../../composite-xform");class l extends c{get tag(){return"x14:id"}render(o,h){o.leafNode(this.tag,null,h)}parseOpen(){this.model=""}parseText(o){this.model+=o}parseClose(o){return o!==this.tag}}class i extends s{constructor(){super(),this.map={"x14:id":this.idXform=new l}}get tag(){return"ext"}render(o,h){o.openNode(this.tag,{uri:"{B025F937-C7B1-47D3-B67F-A62EFF666E3E}","xmlns:x14":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/main"}),this.idXform.render(o,h.x14Id),o.closeNode()}createNewModel(){return{}}onParserClose(o,h){this.model.x14Id=h.model}}a.exports=class extends s{constructor(){super(),this.map={ext:new i}}get tag(){return"extLst"}render(n,o){n.openNode(this.tag),this.map.ext.render(n,o),n.closeNode()}createNewModel(){return{}}onParserClose(n,o){Object.assign(this.model,o.model)}}},{"../../base-xform":32,"../../composite-xform":48}],90:[function(e,a,f){const c=e("../../base-xform");a.exports=class extends c{get tag(){return"formula"}render(s,l){s.leafNode(this.tag,null,l)}parseOpen(){this.model=""}parseText(s){this.model+=s}parseClose(s){return s!==this.tag}}},{"../../base-xform":32}],91:[function(e,a,f){const c=e("../../base-xform"),s=e("../../composite-xform"),l=e("./cfvo-xform");a.exports=class extends s{constructor(){super(),this.map={cfvo:this.cfvoXform=new l}}get tag(){return"iconSet"}render(i,n){i.openNode(this.tag,{iconSet:c.toStringAttribute(n.iconSet,"3TrafficLights"),reverse:c.toBoolAttribute(n.reverse,!1),showValue:c.toBoolAttribute(n.showValue,!0)}),n.cfvo.forEach(o=>{this.cfvoXform.render(i,o)}),i.closeNode()}createNewModel(i){let{attributes:n}=i;return{iconSet:c.toStringValue(n.iconSet,"3TrafficLights"),reverse:c.toBoolValue(n.reverse),showValue:c.toBoolValue(n.showValue),cfvo:[]}}onParserClose(i,n){this.model[i].push(n.model)}}},{"../../base-xform":32,"../../composite-xform":48,"./cfvo-xform":84}],92:[function(e,a,f){const c=e("../../../utils/utils"),s=e("../base-xform");a.exports=class extends s{get tag(){return"col"}prepare(l,i){const n=i.styles.addStyleModel(l.style||{});n&&(l.styleId=n)}render(l,i){l.openNode("col"),l.addAttribute("min",i.min),l.addAttribute("max",i.max),i.width&&l.addAttribute("width",i.width),i.styleId&&l.addAttribute("style",i.styleId),i.hidden&&l.addAttribute("hidden","1"),i.bestFit&&l.addAttribute("bestFit","1"),i.outlineLevel&&l.addAttribute("outlineLevel",i.outlineLevel),i.collapsed&&l.addAttribute("collapsed","1"),l.addAttribute("customWidth","1"),l.closeNode()}parseOpen(l){if(l.name==="col"){const i=this.model={min:parseInt(l.attributes.min||"0",10),max:parseInt(l.attributes.max||"0",10),width:l.attributes.width===void 0?void 0:parseFloat(l.attributes.width||"0")};return l.attributes.style&&(i.styleId=parseInt(l.attributes.style,10)),c.parseBoolean(l.attributes.hidden)&&(i.hidden=!0),c.parseBoolean(l.attributes.bestFit)&&(i.bestFit=!0),l.attributes.outlineLevel&&(i.outlineLevel=parseInt(l.attributes.outlineLevel,10)),c.parseBoolean(l.attributes.collapsed)&&(i.collapsed=!0),!0}return!1}parseText(){}parseClose(){return!1}reconcile(l,i){l.styleId&&(l.style=i.styles.getStyleModel(l.styleId))}}},{"../../../utils/utils":27,"../base-xform":32}],93:[function(e,a,f){const c=e("../../../utils/under-dash"),s=e("../../../utils/utils"),l=e("../../../utils/col-cache"),i=e("../base-xform"),n=e("../../../doc/range");function o(u,d,m,b){const p=d[m];p!==void 0?u[m]=p:b!==void 0&&(u[m]=b)}function h(u,d,m,b){const p=d[m];p!==void 0&&(u[m]=s.parseBoolean(p))}a.exports=class extends i{get tag(){return"dataValidations"}render(u,d){const m=function(b){const p=c.map(b,(x,C)=>({address:C,dataValidation:x,marked:!1})).sort((x,C)=>c.strcmp(x.address,C.address)),v=c.keyBy(p,"address"),g=(x,C,T)=>{for(let R=0;R<C;R++){const B=l.encodeAddress(x.row+R,T);if(!b[B]||!c.isEqual(b[x.address],b[B]))return!1}return!0};return p.map(x=>{if(!x.marked){const C=l.decodeEx(x.address);if(C.dimensions)return v[C.dimensions].marked=!0,{...x.dataValidation,sqref:x.address};let T=1,R=l.encodeAddress(C.row+T,C.col);for(;b[R]&&c.isEqual(x.dataValidation,b[R]);)T++,R=l.encodeAddress(C.row+T,C.col);let B=1;for(;g(C,T,C.col+B);)B++;for(let I=0;I<T;I++)for(let F=0;F<B;F++)R=l.encodeAddress(C.row+I,C.col+F),v[R].marked=!0;if(T>1||B>1){const I=C.row+(T-1),F=C.col+(B-1);return{...x.dataValidation,sqref:`${x.address}:${l.encodeAddress(I,F)}`}}return{...x.dataValidation,sqref:x.address}}return null}).filter(Boolean)}(d);m.length&&(u.openNode("dataValidations",{count:m.length}),m.forEach(b=>{u.openNode("dataValidation"),b.type!=="any"&&(u.addAttribute("type",b.type),b.operator&&b.type!=="list"&&b.operator!=="between"&&u.addAttribute("operator",b.operator),b.allowBlank&&u.addAttribute("allowBlank","1")),b.showInputMessage&&u.addAttribute("showInputMessage","1"),b.promptTitle&&u.addAttribute("promptTitle",b.promptTitle),b.prompt&&u.addAttribute("prompt",b.prompt),b.showErrorMessage&&u.addAttribute("showErrorMessage","1"),b.errorStyle&&u.addAttribute("errorStyle",b.errorStyle),b.errorTitle&&u.addAttribute("errorTitle",b.errorTitle),b.error&&u.addAttribute("error",b.error),u.addAttribute("sqref",b.sqref),(b.formulae||[]).forEach((p,v)=>{u.openNode("formula"+(v+1)),b.type==="date"?u.writeText(s.dateToExcel(new Date(p))):u.writeText(p),u.closeNode()}),u.closeNode()}),u.closeNode())}parseOpen(u){switch(u.name){case"dataValidations":return this.model={},!0;case"dataValidation":{this._address=u.attributes.sqref;const d={type:u.attributes.type||"any",formulae:[]};switch(u.attributes.type&&h(d,u.attributes,"allowBlank"),h(d,u.attributes,"showInputMessage"),h(d,u.attributes,"showErrorMessage"),d.type){case"any":case"list":case"custom":break;default:o(d,u.attributes,"operator","between")}return o(d,u.attributes,"promptTitle"),o(d,u.attributes,"prompt"),o(d,u.attributes,"errorStyle"),o(d,u.attributes,"errorTitle"),o(d,u.attributes,"error"),this._dataValidation=d,!0}case"formula1":case"formula2":return this._formula=[],!0;default:return!1}}parseText(u){this._formula&&this._formula.push(u)}parseClose(u){switch(u){case"dataValidations":return!1;case"dataValidation":return this._dataValidation.formulae&&this._dataValidation.formulae.length||(delete this._dataValidation.formulae,delete this._dataValidation.operator),(this._address.split(/\s+/g)||[]).forEach(d=>{d.includes(":")?new n(d).forEachAddress(m=>{this.model[m]=this._dataValidation}):this.model[d]=this._dataValidation}),!0;case"formula1":case"formula2":{let d=this._formula.join("");switch(this._dataValidation.type){case"whole":case"textLength":d=parseInt(d,10);break;case"decimal":d=parseFloat(d);break;case"date":d=s.excelToDate(parseFloat(d))}return this._dataValidation.formulae.push(d),this._formula=void 0,!0}default:return!0}}}},{"../../../doc/range":10,"../../../utils/col-cache":19,"../../../utils/under-dash":26,"../../../utils/utils":27,"../base-xform":32}],94:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"dimension"}render(s,l){l&&s.leafNode("dimension",{ref:l})}parseOpen(s){return s.name==="dimension"&&(this.model=s.attributes.ref,!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],95:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"drawing"}render(s,l){l&&s.leafNode(this.tag,{"r:id":l.rId})}parseOpen(s){switch(s.name){case this.tag:return this.model={rId:s.attributes["r:id"]},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],96:[function(e,a,f){const c=e("../composite-xform"),s=e("./cf-ext/conditional-formattings-ext-xform");class l extends c{constructor(){super(),this.map={"x14:conditionalFormattings":this.conditionalFormattings=new s}}get tag(){return"ext"}hasContent(n){return this.conditionalFormattings.hasContent(n.conditionalFormattings)}prepare(n,o){this.conditionalFormattings.prepare(n.conditionalFormattings,o)}render(n,o){n.openNode("ext",{uri:"{78C0D931-6437-407d-A8EE-F0AAD7539E65}","xmlns:x14":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/main"}),this.conditionalFormattings.render(n,o.conditionalFormattings),n.closeNode()}createNewModel(){return{}}onParserClose(n,o){this.model[n]=o.model}}a.exports=class extends c{constructor(){super(),this.map={ext:this.ext=new l}}get tag(){return"extLst"}prepare(i,n){this.ext.prepare(i,n)}hasContent(i){return this.ext.hasContent(i)}render(i,n){this.hasContent(n)&&(i.openNode("extLst"),this.ext.render(i,n),i.closeNode())}createNewModel(){return{}}onParserClose(i,n){Object.assign(this.model,n.model)}}},{"../composite-xform":48,"./cf-ext/conditional-formattings-ext-xform":78}],97:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"headerFooter"}render(s,l){if(l){s.addRollback();let i=!1;s.openNode("headerFooter"),l.differentFirst&&(s.addAttribute("differentFirst","1"),i=!0),l.differentOddEven&&(s.addAttribute("differentOddEven","1"),i=!0),l.oddHeader&&typeof l.oddHeader=="string"&&(s.leafNode("oddHeader",null,l.oddHeader),i=!0),l.oddFooter&&typeof l.oddFooter=="string"&&(s.leafNode("oddFooter",null,l.oddFooter),i=!0),l.evenHeader&&typeof l.evenHeader=="string"&&(s.leafNode("evenHeader",null,l.evenHeader),i=!0),l.evenFooter&&typeof l.evenFooter=="string"&&(s.leafNode("evenFooter",null,l.evenFooter),i=!0),l.firstHeader&&typeof l.firstHeader=="string"&&(s.leafNode("firstHeader",null,l.firstHeader),i=!0),l.firstFooter&&typeof l.firstFooter=="string"&&(s.leafNode("firstFooter",null,l.firstFooter),i=!0),i?(s.closeNode(),s.commit()):s.rollback()}}parseOpen(s){switch(s.name){case"headerFooter":return this.model={},s.attributes.differentFirst&&(this.model.differentFirst=parseInt(s.attributes.differentFirst,0)===1),s.attributes.differentOddEven&&(this.model.differentOddEven=parseInt(s.attributes.differentOddEven,0)===1),!0;case"oddHeader":return this.currentNode="oddHeader",!0;case"oddFooter":return this.currentNode="oddFooter",!0;case"evenHeader":return this.currentNode="evenHeader",!0;case"evenFooter":return this.currentNode="evenFooter",!0;case"firstHeader":return this.currentNode="firstHeader",!0;case"firstFooter":return this.currentNode="firstFooter",!0;default:return!1}}parseText(s){switch(this.currentNode){case"oddHeader":this.model.oddHeader=s;break;case"oddFooter":this.model.oddFooter=s;break;case"evenHeader":this.model.evenHeader=s;break;case"evenFooter":this.model.evenFooter=s;break;case"firstHeader":this.model.firstHeader=s;break;case"firstFooter":this.model.firstFooter=s}}parseClose(){switch(this.currentNode){case"oddHeader":case"oddFooter":case"evenHeader":case"evenFooter":case"firstHeader":case"firstFooter":return this.currentNode=void 0,!0;default:return!1}}}},{"../base-xform":32}],98:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"hyperlink"}render(s,l){this.isInternalLink(l)?s.leafNode("hyperlink",{ref:l.address,"r:id":l.rId,tooltip:l.tooltip,location:l.target}):s.leafNode("hyperlink",{ref:l.address,"r:id":l.rId,tooltip:l.tooltip})}parseOpen(s){return s.name==="hyperlink"&&(this.model={address:s.attributes.ref,rId:s.attributes["r:id"],tooltip:s.attributes.tooltip},s.attributes.location&&(this.model.target=s.attributes.location),!0)}parseText(){}parseClose(){return!1}isInternalLink(s){return s.target&&/^[^!]+![a-zA-Z]+[\d]+$/.test(s.target)}}},{"../base-xform":32}],99:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"mergeCell"}render(s,l){s.leafNode("mergeCell",{ref:l})}parseOpen(s){return s.name==="mergeCell"&&(this.model=s.attributes.ref,!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],100:[function(e,a,f){const c=e("../../../utils/under-dash"),s=e("../../../doc/range"),l=e("../../../utils/col-cache"),i=e("../../../doc/enums");a.exports=class{constructor(){this.merges={}}add(n){if(this.merges[n.master])this.merges[n.master].expandToAddress(n.address);else{const o=`${n.master}:${n.address}`;this.merges[n.master]=new s(o)}}get mergeCells(){return c.map(this.merges,n=>n.range)}reconcile(n,o){c.each(n,h=>{const u=l.decode(h);for(let d=u.top;d<=u.bottom;d++){const m=o[d-1];for(let b=u.left;b<=u.right;b++){const p=m.cells[b-1];p?p.type===i.ValueType.Merge&&(p.master=u.tl):m.cells[b]={type:i.ValueType.Null,address:l.encodeAddress(d,b)}}}})}getMasterAddress(n){const o=this.hash[n];return o&&o.tl}}},{"../../../doc/enums":7,"../../../doc/range":10,"../../../utils/col-cache":19,"../../../utils/under-dash":26}],101:[function(e,a,f){const c=e("../base-xform"),s=l=>l!==void 0;a.exports=class extends c{get tag(){return"outlinePr"}render(l,i){return!(!i||!s(i.summaryBelow)&&!s(i.summaryRight))&&(l.leafNode(this.tag,{summaryBelow:s(i.summaryBelow)?Number(i.summaryBelow):void 0,summaryRight:s(i.summaryRight)?Number(i.summaryRight):void 0}),!0)}parseOpen(l){return l.name===this.tag&&(this.model={summaryBelow:s(l.attributes.summaryBelow)?!!Number(l.attributes.summaryBelow):void 0,summaryRight:s(l.attributes.summaryRight)?!!Number(l.attributes.summaryRight):void 0},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],102:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"brk"}render(s,l){s.leafNode("brk",l)}parseOpen(s){return s.name==="brk"&&(this.model=s.attributes.ref,!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],103:[function(e,a,f){const c=e("../../../utils/under-dash"),s=e("../base-xform");a.exports=class extends s{get tag(){return"pageMargins"}render(l,i){if(i){const n={left:i.left,right:i.right,top:i.top,bottom:i.bottom,header:i.header,footer:i.footer};c.some(n,o=>o!==void 0)&&l.leafNode(this.tag,n)}}parseOpen(l){switch(l.name){case this.tag:return this.model={left:parseFloat(l.attributes.left||.7),right:parseFloat(l.attributes.right||.7),top:parseFloat(l.attributes.top||.75),bottom:parseFloat(l.attributes.bottom||.75),header:parseFloat(l.attributes.header||.3),footer:parseFloat(l.attributes.footer||.3)},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../../../utils/under-dash":26,"../base-xform":32}],104:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"pageSetUpPr"}render(s,l){return!(!l||!l.fitToPage)&&(s.leafNode(this.tag,{fitToPage:l.fitToPage?"1":void 0}),!0)}parseOpen(s){return s.name===this.tag&&(this.model={fitToPage:s.attributes.fitToPage==="1"},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],105:[function(e,a,f){const c=e("../../../utils/under-dash"),s=e("../base-xform");function l(h){return h?"1":void 0}function i(h){switch(h){case"overThenDown":return h;default:return}}function n(h){switch(h){case"atEnd":case"asDisplyed":return h;default:return}}function o(h){switch(h){case"dash":case"blank":case"NA":return h;default:return}}a.exports=class extends s{get tag(){return"pageSetup"}render(h,u){if(u){const d={paperSize:u.paperSize,orientation:u.orientation,horizontalDpi:u.horizontalDpi,verticalDpi:u.verticalDpi,pageOrder:i(u.pageOrder),blackAndWhite:l(u.blackAndWhite),draft:l(u.draft),cellComments:n(u.cellComments),errors:o(u.errors),scale:u.scale,fitToWidth:u.fitToWidth,fitToHeight:u.fitToHeight,firstPageNumber:u.firstPageNumber,useFirstPageNumber:l(u.firstPageNumber),usePrinterDefaults:l(u.usePrinterDefaults),copies:u.copies};c.some(d,m=>m!==void 0)&&h.leafNode(this.tag,d)}}parseOpen(h){switch(h.name){case this.tag:return this.model={paperSize:(u=h.attributes.paperSize,u!==void 0?parseInt(u,10):void 0),orientation:h.attributes.orientation||"portrait",horizontalDpi:parseInt(h.attributes.horizontalDpi||"4294967295",10),verticalDpi:parseInt(h.attributes.verticalDpi||"4294967295",10),pageOrder:h.attributes.pageOrder||"downThenOver",blackAndWhite:h.attributes.blackAndWhite==="1",draft:h.attributes.draft==="1",cellComments:h.attributes.cellComments||"None",errors:h.attributes.errors||"displayed",scale:parseInt(h.attributes.scale||"100",10),fitToWidth:parseInt(h.attributes.fitToWidth||"1",10),fitToHeight:parseInt(h.attributes.fitToHeight||"1",10),firstPageNumber:parseInt(h.attributes.firstPageNumber||"1",10),useFirstPageNumber:h.attributes.useFirstPageNumber==="1",usePrinterDefaults:h.attributes.usePrinterDefaults==="1",copies:parseInt(h.attributes.copies||"1",10)},!0;default:return!1}var u}parseText(){}parseClose(){return!1}}},{"../../../utils/under-dash":26,"../base-xform":32}],106:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"picture"}render(s,l){l&&s.leafNode(this.tag,{"r:id":l.rId})}parseOpen(s){switch(s.name){case this.tag:return this.model={rId:s.attributes["r:id"]},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],107:[function(e,a,f){const c=e("../../../utils/under-dash"),s=e("../base-xform");function l(i){return i?"1":void 0}a.exports=class extends s{get tag(){return"printOptions"}render(i,n){if(n){const o={headings:l(n.showRowColHeaders),gridLines:l(n.showGridLines),horizontalCentered:l(n.horizontalCentered),verticalCentered:l(n.verticalCentered)};c.some(o,h=>h!==void 0)&&i.leafNode(this.tag,o)}}parseOpen(i){switch(i.name){case this.tag:return this.model={showRowColHeaders:i.attributes.headings==="1",showGridLines:i.attributes.gridLines==="1",horizontalCentered:i.attributes.horizontalCentered==="1",verticalCentered:i.attributes.verticalCentered==="1"},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../../../utils/under-dash":26,"../base-xform":32}],108:[function(e,a,f){const c=e("./page-breaks-xform"),s=e("../list-xform");a.exports=class extends s{constructor(){super({tag:"rowBreaks",count:!0,childXform:new c})}render(l,i){if(i&&i.length){l.openNode(this.tag,this.$),this.count&&(l.addAttribute(this.$count,i.length),l.addAttribute("manualBreakCount",i.length));const{childXform:n}=this;i.forEach(o=>{n.render(l,o)}),l.closeNode()}else this.empty&&l.leafNode(this.tag)}}},{"../list-xform":71,"./page-breaks-xform":102}],109:[function(e,a,f){const c=e("../base-xform"),s=e("../../../utils/utils"),l=e("./cell-xform");a.exports=class extends c{constructor(i){super(),this.maxItems=i&&i.maxItems,this.map={c:new l}}get tag(){return"row"}prepare(i,n){const o=n.styles.addStyleModel(i.style);o&&(i.styleId=o);const h=this.map.c;i.cells.forEach(u=>{h.prepare(u,n)})}render(i,n,o){i.openNode("row"),i.addAttribute("r",n.number),n.height&&(i.addAttribute("ht",n.height),i.addAttribute("customHeight","1")),n.hidden&&i.addAttribute("hidden","1"),n.min>0&&n.max>0&&n.min<=n.max&&i.addAttribute("spans",`${n.min}:${n.max}`),n.styleId&&(i.addAttribute("s",n.styleId),i.addAttribute("customFormat","1")),i.addAttribute("x14ac:dyDescent","0.25"),n.outlineLevel&&i.addAttribute("outlineLevel",n.outlineLevel),n.collapsed&&i.addAttribute("collapsed","1");const h=this.map.c;n.cells.forEach(u=>{h.render(i,u,o)}),i.closeNode()}parseOpen(i){if(this.parser)return this.parser.parseOpen(i),!0;if(i.name==="row"){this.numRowsSeen+=1;const n=i.attributes.spans?i.attributes.spans.split(":").map(h=>parseInt(h,10)):[void 0,void 0],o=this.model={number:parseInt(i.attributes.r,10),min:n[0],max:n[1],cells:[]};return i.attributes.s&&(o.styleId=parseInt(i.attributes.s,10)),s.parseBoolean(i.attributes.hidden)&&(o.hidden=!0),s.parseBoolean(i.attributes.bestFit)&&(o.bestFit=!0),i.attributes.ht&&(o.height=parseFloat(i.attributes.ht)),i.attributes.outlineLevel&&(o.outlineLevel=parseInt(i.attributes.outlineLevel,10)),s.parseBoolean(i.attributes.collapsed)&&(o.collapsed=!0),!0}return this.parser=this.map[i.name],!!this.parser&&(this.parser.parseOpen(i),!0)}parseText(i){this.parser&&this.parser.parseText(i)}parseClose(i){if(this.parser){if(!this.parser.parseClose(i)){if(this.model.cells.push(this.parser.model),this.maxItems&&this.model.cells.length>this.maxItems)throw new Error(`Max column count (${this.maxItems}) exceeded`);this.parser=void 0}return!0}return!1}reconcile(i,n){i.style=i.styleId?n.styles.getStyleModel(i.styleId):{},i.styleId!==void 0&&(i.styleId=void 0);const o=this.map.c;i.cells.forEach(h=>{o.reconcile(h,n)})}}},{"../../../utils/utils":27,"../base-xform":32,"./cell-xform":73}],110:[function(e,a,f){const c=e("../../../utils/under-dash"),s=e("../base-xform");a.exports=class extends s{get tag(){return"sheetFormatPr"}render(l,i){if(i){const n={defaultRowHeight:i.defaultRowHeight,outlineLevelRow:i.outlineLevelRow,outlineLevelCol:i.outlineLevelCol,"x14ac:dyDescent":i.dyDescent};i.defaultColWidth&&(n.defaultColWidth=i.defaultColWidth),i.defaultRowHeight&&i.defaultRowHeight===15||(n.customHeight="1"),c.some(n,o=>o!==void 0)&&l.leafNode("sheetFormatPr",n)}}parseOpen(l){return l.name==="sheetFormatPr"&&(this.model={defaultRowHeight:parseFloat(l.attributes.defaultRowHeight||"0"),dyDescent:parseFloat(l.attributes["x14ac:dyDescent"]||"0"),outlineLevelRow:parseInt(l.attributes.outlineLevelRow||"0",10),outlineLevelCol:parseInt(l.attributes.outlineLevelCol||"0",10)},l.attributes.defaultColWidth&&(this.model.defaultColWidth=parseFloat(l.attributes.defaultColWidth)),!0)}parseText(){}parseClose(){return!1}}},{"../../../utils/under-dash":26,"../base-xform":32}],111:[function(e,a,f){const c=e("../base-xform"),s=e("../style/color-xform"),l=e("./page-setup-properties-xform"),i=e("./outline-properties-xform");a.exports=class extends c{constructor(){super(),this.map={tabColor:new s("tabColor"),pageSetUpPr:new l,outlinePr:new i}}get tag(){return"sheetPr"}render(n,o){if(o){n.addRollback(),n.openNode("sheetPr");let h=!1;h=this.map.tabColor.render(n,o.tabColor)||h,h=this.map.pageSetUpPr.render(n,o.pageSetup)||h,h=this.map.outlinePr.render(n,o.outlineProperties)||h,h?(n.closeNode(),n.commit()):n.rollback()}}parseOpen(n){return this.parser?(this.parser.parseOpen(n),!0):n.name===this.tag?(this.reset(),!0):!!this.map[n.name]&&(this.parser=this.map[n.name],this.parser.parseOpen(n),!0)}parseText(n){return!!this.parser&&(this.parser.parseText(n),!0)}parseClose(n){return this.parser?(this.parser.parseClose(n)||(this.parser=void 0),!0):(this.map.tabColor.model||this.map.pageSetUpPr.model||this.map.outlinePr.model?(this.model={},this.map.tabColor.model&&(this.model.tabColor=this.map.tabColor.model),this.map.pageSetUpPr.model&&(this.model.pageSetup=this.map.pageSetUpPr.model),this.map.outlinePr.model&&(this.model.outlineProperties=this.map.outlinePr.model)):this.model=null,!1)}}},{"../base-xform":32,"../style/color-xform":128,"./outline-properties-xform":101,"./page-setup-properties-xform":104}],112:[function(e,a,f){const c=e("../../../utils/under-dash"),s=e("../base-xform");function l(n,o){return n?o:void 0}function i(n,o){return n===o||void 0}a.exports=class extends s{get tag(){return"sheetProtection"}render(n,o){if(o){const h={sheet:l(o.sheet,"1"),selectLockedCells:o.selectLockedCells===!1?"1":void 0,selectUnlockedCells:o.selectUnlockedCells===!1?"1":void 0,formatCells:l(o.formatCells,"0"),formatColumns:l(o.formatColumns,"0"),formatRows:l(o.formatRows,"0"),insertColumns:l(o.insertColumns,"0"),insertRows:l(o.insertRows,"0"),insertHyperlinks:l(o.insertHyperlinks,"0"),deleteColumns:l(o.deleteColumns,"0"),deleteRows:l(o.deleteRows,"0"),sort:l(o.sort,"0"),autoFilter:l(o.autoFilter,"0"),pivotTables:l(o.pivotTables,"0")};o.sheet&&(h.algorithmName=o.algorithmName,h.hashValue=o.hashValue,h.saltValue=o.saltValue,h.spinCount=o.spinCount,h.objects=l(o.objects===!1,"1"),h.scenarios=l(o.scenarios===!1,"1")),c.some(h,u=>u!==void 0)&&n.leafNode(this.tag,h)}}parseOpen(n){switch(n.name){case this.tag:return this.model={sheet:i(n.attributes.sheet,"1"),objects:n.attributes.objects!=="1"&&void 0,scenarios:n.attributes.scenarios!=="1"&&void 0,selectLockedCells:n.attributes.selectLockedCells!=="1"&&void 0,selectUnlockedCells:n.attributes.selectUnlockedCells!=="1"&&void 0,formatCells:i(n.attributes.formatCells,"0"),formatColumns:i(n.attributes.formatColumns,"0"),formatRows:i(n.attributes.formatRows,"0"),insertColumns:i(n.attributes.insertColumns,"0"),insertRows:i(n.attributes.insertRows,"0"),insertHyperlinks:i(n.attributes.insertHyperlinks,"0"),deleteColumns:i(n.attributes.deleteColumns,"0"),deleteRows:i(n.attributes.deleteRows,"0"),sort:i(n.attributes.sort,"0"),autoFilter:i(n.attributes.autoFilter,"0"),pivotTables:i(n.attributes.pivotTables,"0")},n.attributes.algorithmName&&(this.model.algorithmName=n.attributes.algorithmName,this.model.hashValue=n.attributes.hashValue,this.model.saltValue=n.attributes.saltValue,this.model.spinCount=parseInt(n.attributes.spinCount,10)),!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../../../utils/under-dash":26,"../base-xform":32}],113:[function(e,a,f){const c=e("../../../utils/col-cache"),s=e("../base-xform"),l={frozen:"frozen",frozenSplit:"frozen",split:"split"};a.exports=class extends s{get tag(){return"sheetView"}prepare(i){switch(i.state){case"frozen":case"split":break;default:i.state="normal"}}render(i,n){i.openNode("sheetView",{workbookViewId:n.workbookViewId||0});const o=function(b,p,v){v&&i.addAttribute(b,p)};let h,u,d,m;switch(o("rightToLeft","1",n.rightToLeft===!0),o("tabSelected","1",n.tabSelected),o("showRuler","0",n.showRuler===!1),o("showRowColHeaders","0",n.showRowColHeaders===!1),o("showGridLines","0",n.showGridLines===!1),o("zoomScale",n.zoomScale,n.zoomScale),o("zoomScaleNormal",n.zoomScaleNormal,n.zoomScaleNormal),o("view",n.style,n.style),n.state){case"frozen":u=n.xSplit||0,d=n.ySplit||0,h=n.topLeftCell||c.getAddress(d+1,u+1).address,m=(n.xSplit&&n.ySplit?"bottomRight":n.xSplit&&"topRight")||"bottomLeft",i.leafNode("pane",{xSplit:n.xSplit||void 0,ySplit:n.ySplit||void 0,topLeftCell:h,activePane:m,state:"frozen"}),i.leafNode("selection",{pane:m,activeCell:n.activeCell,sqref:n.activeCell});break;case"split":n.activePane==="topLeft"&&(n.activePane=void 0),i.leafNode("pane",{xSplit:n.xSplit||void 0,ySplit:n.ySplit||void 0,topLeftCell:n.topLeftCell,activePane:n.activePane}),i.leafNode("selection",{pane:n.activePane,activeCell:n.activeCell,sqref:n.activeCell});break;case"normal":n.activeCell&&i.leafNode("selection",{activeCell:n.activeCell,sqref:n.activeCell})}i.closeNode()}parseOpen(i){switch(i.name){case"sheetView":return this.sheetView={workbookViewId:parseInt(i.attributes.workbookViewId,10),rightToLeft:i.attributes.rightToLeft==="1",tabSelected:i.attributes.tabSelected==="1",showRuler:i.attributes.showRuler!=="0",showRowColHeaders:i.attributes.showRowColHeaders!=="0",showGridLines:i.attributes.showGridLines!=="0",zoomScale:parseInt(i.attributes.zoomScale||"100",10),zoomScaleNormal:parseInt(i.attributes.zoomScaleNormal||"100",10),style:i.attributes.view},this.pane=void 0,this.selections={},!0;case"pane":return this.pane={xSplit:parseInt(i.attributes.xSplit||"0",10),ySplit:parseInt(i.attributes.ySplit||"0",10),topLeftCell:i.attributes.topLeftCell,activePane:i.attributes.activePane||"topLeft",state:i.attributes.state},!0;case"selection":{const n=i.attributes.pane||"topLeft";return this.selections[n]={pane:n,activeCell:i.attributes.activeCell},!0}default:return!1}}parseText(){}parseClose(i){let n,o;switch(i){case"sheetView":return this.sheetView&&this.pane?(n=this.model={workbookViewId:this.sheetView.workbookViewId,rightToLeft:this.sheetView.rightToLeft,state:l[this.pane.state]||"split",xSplit:this.pane.xSplit,ySplit:this.pane.ySplit,topLeftCell:this.pane.topLeftCell,showRuler:this.sheetView.showRuler,showRowColHeaders:this.sheetView.showRowColHeaders,showGridLines:this.sheetView.showGridLines,zoomScale:this.sheetView.zoomScale,zoomScaleNormal:this.sheetView.zoomScaleNormal},this.model.state==="split"&&(n.activePane=this.pane.activePane),o=this.selections[this.pane.activePane],o&&o.activeCell&&(n.activeCell=o.activeCell),this.sheetView.style&&(n.style=this.sheetView.style)):(n=this.model={workbookViewId:this.sheetView.workbookViewId,rightToLeft:this.sheetView.rightToLeft,state:"normal",showRuler:this.sheetView.showRuler,showRowColHeaders:this.sheetView.showRowColHeaders,showGridLines:this.sheetView.showGridLines,zoomScale:this.sheetView.zoomScale,zoomScaleNormal:this.sheetView.zoomScaleNormal},o=this.selections.topLeft,o&&o.activeCell&&(n.activeCell=o.activeCell),this.sheetView.style&&(n.style=this.sheetView.style)),!1;default:return!0}}reconcile(){}}},{"../../../utils/col-cache":19,"../base-xform":32}],114:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"tablePart"}render(s,l){l&&s.leafNode(this.tag,{"r:id":l.rId})}parseOpen(s){switch(s.name){case this.tag:return this.model={rId:s.attributes["r:id"]},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],115:[function(e,a,f){const c=e("../../../utils/under-dash"),s=e("../../../utils/col-cache"),l=e("../../../utils/xml-stream"),i=e("../../rel-type"),n=e("./merges"),o=e("../base-xform"),h=e("../list-xform"),u=e("./row-xform"),d=e("./col-xform"),m=e("./dimension-xform"),b=e("./hyperlink-xform"),p=e("./merge-cell-xform"),v=e("./data-validations-xform"),g=e("./sheet-properties-xform"),x=e("./sheet-format-properties-xform"),C=e("./sheet-view-xform"),T=e("./sheet-protection-xform"),R=e("./page-margins-xform"),B=e("./page-setup-xform"),I=e("./print-options-xform"),F=e("./auto-filter-xform"),L=e("./picture-xform"),V=e("./drawing-xform"),z=e("./table-part-xform"),E=e("./row-breaks-xform"),P=e("./header-footer-xform"),k=e("./cf/conditional-formattings-xform"),y=e("./ext-lst-xform"),w=(S,A)=>{if(!A||!A.length)return S;if(!S||!S.length)return A;const O={},N={};return S.forEach(U=>{O[U.ref]=U,U.rules.forEach(H=>{const{x14Id:Z}=H;Z&&(N[Z]=H)})}),A.forEach(U=>{U.rules.forEach(H=>{const Z=N[H.x14Id];Z?((D,q)=>{Object.keys(q).forEach(M=>{const j=D[M],$=q[M];j===void 0&&$!==void 0&&(D[M]=$)})})(Z,H):O[U.ref]?O[U.ref].rules.push(H):S.push({ref:U.ref,rules:[H]})})}),S};class _ extends o{constructor(A){super();const{maxRows:O,maxCols:N,ignoreNodes:U}=A||{};this.ignoreNodes=U||[],this.map={sheetPr:new g,dimension:new m,sheetViews:new h({tag:"sheetViews",count:!1,childXform:new C}),sheetFormatPr:new x,cols:new h({tag:"cols",count:!1,childXform:new d}),sheetData:new h({tag:"sheetData",count:!1,empty:!0,childXform:new u({maxItems:N}),maxItems:O}),autoFilter:new F,mergeCells:new h({tag:"mergeCells",count:!0,childXform:new p}),rowBreaks:new E,hyperlinks:new h({tag:"hyperlinks",count:!1,childXform:new b}),pageMargins:new R,dataValidations:new v,pageSetup:new B,headerFooter:new P,printOptions:new I,picture:new L,drawing:new V,sheetProtection:new T,tableParts:new h({tag:"tableParts",count:!0,childXform:new z}),conditionalFormatting:new k,extLst:new y}}prepare(A,O){O.merges=new n,A.hyperlinks=O.hyperlinks=[],A.comments=O.comments=[],O.formulae={},O.siFormulae=0,this.map.cols.prepare(A.cols,O),this.map.sheetData.prepare(A.rows,O),this.map.conditionalFormatting.prepare(A.conditionalFormattings,O),A.mergeCells=O.merges.mergeCells;const N=A.rels=[];function U(D){return"rId"+(D.length+1)}if(A.hyperlinks.forEach(D=>{const q=U(N);D.rId=q,N.push({Id:q,Type:i.Hyperlink,Target:D.target,TargetMode:"External"})}),A.comments.length>0){const D={Id:U(N),Type:i.Comments,Target:`../comments${A.id}.xml`};N.push(D);const q={Id:U(N),Type:i.VmlDrawing,Target:`../drawings/vmlDrawing${A.id}.vml`};N.push(q),A.comments.forEach(M=>{M.refAddress=s.decodeAddress(M.ref)}),O.commentRefs.push({commentName:"comments"+A.id,vmlDrawing:"vmlDrawing"+A.id})}const H=[];let Z;A.media.forEach(D=>{if(D.type==="background"){const q=U(N);Z=O.media[D.imageId],N.push({Id:q,Type:i.Image,Target:`../media/${Z.name}.${Z.extension}`}),A.background={rId:q},A.image=O.media[D.imageId]}else if(D.type==="image"){let{drawing:q}=A;Z=O.media[D.imageId],q||(q=A.drawing={rId:U(N),name:"drawing"+ ++O.drawingsCount,anchors:[],rels:[]},O.drawings.push(q),N.push({Id:q.rId,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing",Target:`../drawings/${q.name}.xml`}));let M=this.preImageId===D.imageId?H[D.imageId]:H[q.rels.length];M||(M=U(q.rels),H[q.rels.length]=M,q.rels.push({Id:M,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",Target:`../media/${Z.name}.${Z.extension}`}));const j={picture:{rId:M},range:D.range};if(D.hyperlinks&&D.hyperlinks.hyperlink){const $=U(q.rels);H[q.rels.length]=$,j.picture.hyperlinks={tooltip:D.hyperlinks.tooltip,rId:$},q.rels.push({Id:$,Type:i.Hyperlink,Target:D.hyperlinks.hyperlink,TargetMode:"External"})}this.preImageId=D.imageId,q.anchors.push(j)}}),A.tables.forEach(D=>{const q=U(N);D.rId=q,N.push({Id:q,Type:i.Table,Target:"../tables/"+D.target}),D.columns.forEach(M=>{const{style:j}=M;j&&(M.dxfId=O.styles.addDxfStyle(j))})}),this.map.extLst.prepare(A,O)}render(A,O){A.openXml(l.StdDocAttributes),A.openNode("worksheet",_.WORKSHEET_ATTRIBUTES);const N=O.properties?{defaultRowHeight:O.properties.defaultRowHeight,dyDescent:O.properties.dyDescent,outlineLevelCol:O.properties.outlineLevelCol,outlineLevelRow:O.properties.outlineLevelRow}:void 0;O.properties&&O.properties.defaultColWidth&&(N.defaultColWidth=O.properties.defaultColWidth);const U={outlineProperties:O.properties&&O.properties.outlineProperties,tabColor:O.properties&&O.properties.tabColor,pageSetup:O.pageSetup&&O.pageSetup.fitToPage?{fitToPage:O.pageSetup.fitToPage}:void 0},H=O.pageSetup&&O.pageSetup.margins,Z={showRowColHeaders:O.pageSetup&&O.pageSetup.showRowColHeaders,showGridLines:O.pageSetup&&O.pageSetup.showGridLines,horizontalCentered:O.pageSetup&&O.pageSetup.horizontalCentered,verticalCentered:O.pageSetup&&O.pageSetup.verticalCentered},D=O.sheetProtection;this.map.sheetPr.render(A,U),this.map.dimension.render(A,O.dimensions),this.map.sheetViews.render(A,O.views),this.map.sheetFormatPr.render(A,N),this.map.cols.render(A,O.cols),this.map.sheetData.render(A,O.rows),this.map.sheetProtection.render(A,D),this.map.autoFilter.render(A,O.autoFilter),this.map.mergeCells.render(A,O.mergeCells),this.map.conditionalFormatting.render(A,O.conditionalFormattings),this.map.dataValidations.render(A,O.dataValidations),this.map.hyperlinks.render(A,O.hyperlinks),this.map.printOptions.render(A,Z),this.map.pageMargins.render(A,H),this.map.pageSetup.render(A,O.pageSetup),this.map.headerFooter.render(A,O.headerFooter),this.map.rowBreaks.render(A,O.rowBreaks),this.map.drawing.render(A,O.drawing),this.map.picture.render(A,O.background),this.map.tableParts.render(A,O.tables),this.map.extLst.render(A,O),O.rels&&O.rels.forEach(q=>{q.Type===i.VmlDrawing&&A.leafNode("legacyDrawing",{"r:id":q.Id})}),A.closeNode()}parseOpen(A){return this.parser?(this.parser.parseOpen(A),!0):A.name==="worksheet"?(c.each(this.map,O=>{O.reset()}),!0):(this.map[A.name]&&!this.ignoreNodes.includes(A.name)&&(this.parser=this.map[A.name],this.parser.parseOpen(A)),!0)}parseText(A){this.parser&&this.parser.parseText(A)}parseClose(A){if(this.parser)return this.parser.parseClose(A)||(this.parser=void 0),!0;switch(A){case"worksheet":{const O=this.map.sheetFormatPr.model||{};this.map.sheetPr.model&&this.map.sheetPr.model.tabColor&&(O.tabColor=this.map.sheetPr.model.tabColor),this.map.sheetPr.model&&this.map.sheetPr.model.outlineProperties&&(O.outlineProperties=this.map.sheetPr.model.outlineProperties);const N={fitToPage:this.map.sheetPr.model&&this.map.sheetPr.model.pageSetup&&this.map.sheetPr.model.pageSetup.fitToPage||!1,margins:this.map.pageMargins.model},U=Object.assign(N,this.map.pageSetup.model,this.map.printOptions.model),H=w(this.map.conditionalFormatting.model,this.map.extLst.model&&this.map.extLst.model["x14:conditionalFormattings"]);return this.model={dimensions:this.map.dimension.model,cols:this.map.cols.model,rows:this.map.sheetData.model,mergeCells:this.map.mergeCells.model,hyperlinks:this.map.hyperlinks.model,dataValidations:this.map.dataValidations.model,properties:O,views:this.map.sheetViews.model,pageSetup:U,headerFooter:this.map.headerFooter.model,background:this.map.picture.model,drawing:this.map.drawing.model,tables:this.map.tableParts.model,conditionalFormattings:H},this.map.autoFilter.model&&(this.model.autoFilter=this.map.autoFilter.model),this.map.sheetProtection.model&&(this.model.sheetProtection=this.map.sheetProtection.model),!1}default:return!0}}reconcile(A,O){const N=(A.relationships||[]).reduce((H,Z)=>{if(H[Z.Id]=Z,Z.Type===i.Comments&&(A.comments=O.comments[Z.Target].comments),Z.Type===i.VmlDrawing&&A.comments&&A.comments.length){const D=O.vmlDrawings[Z.Target].comments;A.comments.forEach((q,M)=>{q.note=Object.assign({},q.note,D[M])})}return H},{});if(O.commentsMap=(A.comments||[]).reduce((H,Z)=>(Z.ref&&(H[Z.ref]=Z),H),{}),O.hyperlinkMap=(A.hyperlinks||[]).reduce((H,Z)=>(Z.rId&&(H[Z.address]=N[Z.rId].Target),H),{}),O.formulae={},A.rows=A.rows&&A.rows.filter(Boolean)||[],A.rows.forEach(H=>{H.cells=H.cells&&H.cells.filter(Boolean)||[]}),this.map.cols.reconcile(A.cols,O),this.map.sheetData.reconcile(A.rows,O),this.map.conditionalFormatting.reconcile(A.conditionalFormattings,O),A.media=[],A.drawing){const H=N[A.drawing.rId].Target.match(/\/drawings\/([a-zA-Z0-9]+)[.][a-zA-Z]{3,4}$/);if(H){const Z=H[1];O.drawings[Z].anchors.forEach(D=>{if(D.medium){const q={type:"image",imageId:D.medium.index,range:D.range,hyperlinks:D.picture.hyperlinks};A.media.push(q)}})}}const U=A.background&&N[A.background.rId];if(U){const H=U.Target.split("/media/")[1],Z=O.mediaIndex&&O.mediaIndex[H];Z!==void 0&&A.media.push({type:"background",imageId:Z})}A.tables=(A.tables||[]).map(H=>{const Z=N[H.rId];return O.tables[Z.Target]}),delete A.relationships,delete A.hyperlinks,delete A.comments}}_.WORKSHEET_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","mc:Ignorable":"x14ac","xmlns:x14ac":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac"},a.exports=_},{"../../../utils/col-cache":19,"../../../utils/under-dash":26,"../../../utils/xml-stream":28,"../../rel-type":31,"../base-xform":32,"../list-xform":71,"./auto-filter-xform":72,"./cf/conditional-formattings-xform":87,"./col-xform":92,"./data-validations-xform":93,"./dimension-xform":94,"./drawing-xform":95,"./ext-lst-xform":96,"./header-footer-xform":97,"./hyperlink-xform":98,"./merge-cell-xform":99,"./merges":100,"./page-margins-xform":103,"./page-setup-xform":105,"./picture-xform":106,"./print-options-xform":107,"./row-breaks-xform":108,"./row-xform":109,"./sheet-format-properties-xform":110,"./sheet-properties-xform":111,"./sheet-protection-xform":112,"./sheet-view-xform":113,"./table-part-xform":114}],116:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{constructor(s){super(),this.tag=s.tag,this.attr=s.attr}render(s,l){l&&(s.openNode(this.tag),s.closeNode())}parseOpen(s){s.name===this.tag&&(this.model=!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],117:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{constructor(s){super(),this.tag=s.tag,this.attr=s.attr,this.attrs=s.attrs,this._format=s.format||function(l){try{return Number.isNaN(l.getTime())?"":l.toISOString()}catch{return""}},this._parse=s.parse||function(l){return new Date(l)}}render(s,l){l&&(s.openNode(this.tag),this.attrs&&s.addAttributes(this.attrs),this.attr?s.addAttribute(this.attr,this._format(l)):s.writeText(this._format(l)),s.closeNode())}parseOpen(s){s.name===this.tag&&(this.attr?this.model=this._parse(s.attributes[this.attr]):this.text=[])}parseText(s){this.attr||this.text.push(s)}parseClose(){return this.attr||(this.model=this._parse(this.text.join(""))),!1}}},{"../base-xform":32}],118:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{constructor(s){super(),this.tag=s.tag,this.attr=s.attr,this.attrs=s.attrs,this.zero=s.zero}render(s,l){(l||this.zero)&&(s.openNode(this.tag),this.attrs&&s.addAttributes(this.attrs),this.attr?s.addAttribute(this.attr,l):s.writeText(l),s.closeNode())}parseOpen(s){return s.name===this.tag&&(this.attr?this.model=parseInt(s.attributes[this.attr],10):this.text=[],!0)}parseText(s){this.attr||this.text.push(s)}parseClose(){return this.attr||(this.model=parseInt(this.text.join("")||0,10)),!1}}},{"../base-xform":32}],119:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{constructor(s){super(),this.tag=s.tag,this.attr=s.attr,this.attrs=s.attrs}render(s,l){l!==void 0&&(s.openNode(this.tag),this.attrs&&s.addAttributes(this.attrs),this.attr?s.addAttribute(this.attr,l):s.writeText(l),s.closeNode())}parseOpen(s){s.name===this.tag&&(this.attr?this.model=s.attributes[this.attr]:this.text=[])}parseText(s){this.attr||this.text.push(s)}parseClose(){return this.attr||(this.model=this.text.join("")),!1}}},{"../base-xform":32}],120:[function(e,a,f){const c=e("./base-xform"),s=e("../../utils/xml-stream");a.exports=class extends c{constructor(l){super(),this._model=l}render(l){if(!this._xml){const i=new s;(function n(o,h){o.openNode(h.tag,h.$),h.c&&h.c.forEach(u=>{n(o,u)}),h.t&&o.writeText(h.t),o.closeNode()})(i,this._model),this._xml=i.xml}l.writeXml(this._xml)}parseOpen(){return!0}parseText(){}parseClose(l){switch(l){case this._model.tag:return!1;default:return!0}}}},{"../../utils/xml-stream":28,"./base-xform":32}],121:[function(e,a,f){const c=e("./text-xform"),s=e("./rich-text-xform"),l=e("../base-xform");a.exports=class extends l{constructor(){super(),this.map={r:new s,t:new c}}get tag(){return"rPh"}render(i,n){if(i.openNode(this.tag,{sb:n.sb||0,eb:n.eb||0}),n&&n.hasOwnProperty("richText")&&n.richText){const{r:o}=this.map;n.richText.forEach(h=>{o.render(i,h)})}else n&&this.map.t.render(i,n.text);i.closeNode()}parseOpen(i){const{name:n}=i;return this.parser?(this.parser.parseOpen(i),!0):n===this.tag?(this.model={sb:parseInt(i.attributes.sb,10),eb:parseInt(i.attributes.eb,10)},!0):(this.parser=this.map[n],!!this.parser&&(this.parser.parseOpen(i),!0))}parseText(i){this.parser&&this.parser.parseText(i)}parseClose(i){if(this.parser){if(!this.parser.parseClose(i)){switch(i){case"r":{let n=this.model.richText;n||(n=this.model.richText=[]),n.push(this.parser.model);break}case"t":this.model.text=this.parser.model}this.parser=void 0}return!0}switch(i){case this.tag:return!1;default:return!0}}}},{"../base-xform":32,"./rich-text-xform":122,"./text-xform":125}],122:[function(e,a,f){const c=e("./text-xform"),s=e("../style/font-xform"),l=e("../base-xform");class i extends l{constructor(o){super(),this.model=o}get tag(){return"r"}get textXform(){return this._textXform||(this._textXform=new c)}get fontXform(){return this._fontXform||(this._fontXform=new s(i.FONT_OPTIONS))}render(o,h){h=h||this.model,o.openNode("r"),h.font&&this.fontXform.render(o,h.font),this.textXform.render(o,h.text),o.closeNode()}parseOpen(o){if(this.parser)return this.parser.parseOpen(o),!0;switch(o.name){case"r":return this.model={},!0;case"t":return this.parser=this.textXform,this.parser.parseOpen(o),!0;case"rPr":return this.parser=this.fontXform,this.parser.parseOpen(o),!0;default:return!1}}parseText(o){this.parser&&this.parser.parseText(o)}parseClose(o){switch(o){case"r":return!1;case"t":return this.model.text=this.parser.model,this.parser=void 0,!0;case"rPr":return this.model.font=this.parser.model,this.parser=void 0,!0;default:return this.parser&&this.parser.parseClose(o),!0}}}i.FONT_OPTIONS={tagName:"rPr",fontNameTag:"rFont"},a.exports=i},{"../base-xform":32,"../style/font-xform":131,"./text-xform":125}],123:[function(e,a,f){const c=e("./text-xform"),s=e("./rich-text-xform"),l=e("./phonetic-text-xform"),i=e("../base-xform");a.exports=class extends i{constructor(n){super(),this.model=n,this.map={r:new s,t:new c,rPh:new l}}get tag(){return"si"}render(n,o){n.openNode(this.tag),o&&o.hasOwnProperty("richText")&&o.richText?o.richText.length?o.richText.forEach(h=>{this.map.r.render(n,h)}):this.map.t.render(n,""):o!=null&&this.map.t.render(n,o),n.closeNode()}parseOpen(n){const{name:o}=n;return this.parser?(this.parser.parseOpen(n),!0):o===this.tag?(this.model={},!0):(this.parser=this.map[o],!!this.parser&&(this.parser.parseOpen(n),!0))}parseText(n){this.parser&&this.parser.parseText(n)}parseClose(n){if(this.parser){if(!this.parser.parseClose(n)){switch(n){case"r":{let o=this.model.richText;o||(o=this.model.richText=[]),o.push(this.parser.model);break}case"t":this.model=this.parser.model}this.parser=void 0}return!0}switch(n){case this.tag:return!1;default:return!0}}}},{"../base-xform":32,"./phonetic-text-xform":121,"./rich-text-xform":122,"./text-xform":125}],124:[function(e,a,f){const c=e("../../../utils/xml-stream"),s=e("../base-xform"),l=e("./shared-string-xform");a.exports=class extends s{constructor(i){super(),this.model=i||{values:[],count:0},this.hash=Object.create(null),this.rich=Object.create(null)}get sharedStringXform(){return this._sharedStringXform||(this._sharedStringXform=new l)}get values(){return this.model.values}get uniqueCount(){return this.model.values.length}get count(){return this.model.count}getString(i){return this.model.values[i]}add(i){return i.richText?this.addRichText(i):this.addText(i)}addText(i){let n=this.hash[i];return n===void 0&&(n=this.hash[i]=this.model.values.length,this.model.values.push(i)),this.model.count++,n}addRichText(i){const n=this.sharedStringXform.toXml(i);let o=this.rich[n];return o===void 0&&(o=this.rich[n]=this.model.values.length,this.model.values.push(i)),this.model.count++,o}render(i,n){n=n||this._values,i.openXml(c.StdDocAttributes),i.openNode("sst",{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main",count:n.count,uniqueCount:n.values.length});const o=this.sharedStringXform;n.values.forEach(h=>{o.render(i,h)}),i.closeNode()}parseOpen(i){if(this.parser)return this.parser.parseOpen(i),!0;switch(i.name){case"sst":return!0;case"si":return this.parser=this.sharedStringXform,this.parser.parseOpen(i),!0;default:throw new Error("Unexpected xml node in parseOpen: "+JSON.stringify(i))}}parseText(i){this.parser&&this.parser.parseText(i)}parseClose(i){if(this.parser)return this.parser.parseClose(i)||(this.model.values.push(this.parser.model),this.model.count++,this.parser=void 0),!0;switch(i){case"sst":return!1;default:throw new Error("Unexpected xml node in parseClose: "+i)}}}},{"../../../utils/xml-stream":28,"../base-xform":32,"./shared-string-xform":123}],125:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"t"}render(s,l){s.openNode("t"),/^\s|\n|\s$/.test(l)&&s.addAttribute("xml:space","preserve"),s.writeText(l),s.closeNode()}get model(){return this._text.join("").replace(/_x([0-9A-F]{4})_/g,(s,l)=>String.fromCharCode(parseInt(l,16)))}parseOpen(s){switch(s.name){case"t":return this._text=[],!0;default:return!1}}parseText(s){this._text.push(s)}parseClose(){return!1}}},{"../base-xform":32}],126:[function(e,a,f){const c=e("../../../doc/enums"),s=e("../../../utils/utils"),l=e("../base-xform"),i={horizontalValues:["left","center","right","fill","centerContinuous","distributed","justify"].reduce((o,h)=>(o[h]=!0,o),{}),horizontal(o){return this.horizontalValues[o]?o:void 0},verticalValues:["top","middle","bottom","distributed","justify"].reduce((o,h)=>(o[h]=!0,o),{}),vertical(o){return o==="middle"?"center":this.verticalValues[o]?o:void 0},wrapText:o=>!!o||void 0,shrinkToFit:o=>!!o||void 0,textRotation(o){switch(o){case"vertical":return o;default:return(o=s.validInt(o))>=-90&&o<=90?o:void 0}},indent:o=>(o=s.validInt(o),Math.max(0,o)),readingOrder(o){switch(o){case"ltr":return c.ReadingOrder.LeftToRight;case"rtl":return c.ReadingOrder.RightToLeft;default:return}}},n={toXml(o){if(o=i.textRotation(o)){if(o==="vertical")return 255;const h=Math.round(o);if(h>=0&&h<=90)return h;if(h<0&&h>=-90)return 90-h}},toModel(o){const h=s.validInt(o);if(h!==void 0){if(h===255)return"vertical";if(h>=0&&h<=90)return h;if(h>90&&h<=180)return 90-h}}};a.exports=class extends l{get tag(){return"alignment"}render(o,h){o.addRollback(),o.openNode("alignment");let u=!1;function d(m,b){b&&(o.addAttribute(m,b),u=!0)}d("horizontal",i.horizontal(h.horizontal)),d("vertical",i.vertical(h.vertical)),d("wrapText",!!i.wrapText(h.wrapText)&&"1"),d("shrinkToFit",!!i.shrinkToFit(h.shrinkToFit)&&"1"),d("indent",i.indent(h.indent)),d("textRotation",n.toXml(h.textRotation)),d("readingOrder",i.readingOrder(h.readingOrder)),o.closeNode(),u?o.commit():o.rollback()}parseOpen(o){const h={};let u=!1;function d(m,b,p){m&&(h[b]=p,u=!0)}d(o.attributes.horizontal,"horizontal",o.attributes.horizontal),d(o.attributes.vertical,"vertical",o.attributes.vertical==="center"?"middle":o.attributes.vertical),d(o.attributes.wrapText,"wrapText",s.parseBoolean(o.attributes.wrapText)),d(o.attributes.shrinkToFit,"shrinkToFit",s.parseBoolean(o.attributes.shrinkToFit)),d(o.attributes.indent,"indent",parseInt(o.attributes.indent,10)),d(o.attributes.textRotation,"textRotation",n.toModel(o.attributes.textRotation)),d(o.attributes.readingOrder,"readingOrder",o.attributes.readingOrder==="2"?"rtl":"ltr"),this.model=u?h:null}parseText(){}parseClose(){return!1}}},{"../../../doc/enums":7,"../../../utils/utils":27,"../base-xform":32}],127:[function(e,a,f){const c=e("../base-xform"),s=e("../../../utils/utils"),l=e("./color-xform");class i extends c{constructor(o){super(),this.name=o,this.map={color:new l}}get tag(){return this.name}render(o,h,u){const d=h&&h.color||u||this.defaultColor;o.openNode(this.name),h&&h.style&&(o.addAttribute("style",h.style),d&&this.map.color.render(o,d)),o.closeNode()}parseOpen(o){if(this.parser)return this.parser.parseOpen(o),!0;switch(o.name){case this.name:{const{style:h}=o.attributes;return this.model=h?{style:h}:void 0,!0}case"color":return this.parser=this.map.color,this.parser.parseOpen(o),!0;default:return!1}}parseText(o){this.parser&&this.parser.parseText(o)}parseClose(o){return this.parser?(this.parser.parseClose(o)||(this.parser=void 0),!0):(o===this.name&&this.map.color.model&&(this.model||(this.model={}),this.model.color=this.map.color.model),!1)}validStyle(o){return i.validStyleValues[o]}}i.validStyleValues=["thin","dashed","dotted","dashDot","hair","dashDotDot","slantDashDot","mediumDashed","mediumDashDotDot","mediumDashDot","medium","double","thick"].reduce((n,o)=>(n[o]=!0,n),{}),a.exports=class extends c{constructor(){super(),this.map={top:new i("top"),left:new i("left"),bottom:new i("bottom"),right:new i("right"),diagonal:new i("diagonal")}}render(n,o){const{color:h}=o;function u(d,m){d&&!d.color&&o.color&&(d={...d,color:o.color}),m.render(n,d,h)}n.openNode("border"),o.diagonal&&o.diagonal.style&&(o.diagonal.up&&n.addAttribute("diagonalUp","1"),o.diagonal.down&&n.addAttribute("diagonalDown","1")),u(o.left,this.map.left),u(o.right,this.map.right),u(o.top,this.map.top),u(o.bottom,this.map.bottom),u(o.diagonal,this.map.diagonal),n.closeNode()}parseOpen(n){if(this.parser)return this.parser.parseOpen(n),!0;switch(n.name){case"border":return this.reset(),this.diagonalUp=s.parseBoolean(n.attributes.diagonalUp),this.diagonalDown=s.parseBoolean(n.attributes.diagonalDown),!0;default:return this.parser=this.map[n.name],!!this.parser&&(this.parser.parseOpen(n),!0)}}parseText(n){this.parser&&this.parser.parseText(n)}parseClose(n){if(this.parser)return this.parser.parseClose(n)||(this.parser=void 0),!0;if(n==="border"){const o=this.model={},h=function(u,d,m){d&&(m&&Object.assign(d,m),o[u]=d)};h("left",this.map.left.model),h("right",this.map.right.model),h("top",this.map.top.model),h("bottom",this.map.bottom.model),h("diagonal",this.map.diagonal.model,{up:this.diagonalUp,down:this.diagonalDown})}return!1}}},{"../../../utils/utils":27,"../base-xform":32,"./color-xform":128}],128:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{constructor(s){super(),this.name=s||"color"}get tag(){return this.name}render(s,l){return!!l&&(s.openNode(this.name),l.argb?s.addAttribute("rgb",l.argb):l.theme!==void 0?(s.addAttribute("theme",l.theme),l.tint!==void 0&&s.addAttribute("tint",l.tint)):l.indexed!==void 0?s.addAttribute("indexed",l.indexed):s.addAttribute("auto","1"),s.closeNode(),!0)}parseOpen(s){return s.name===this.name&&(s.attributes.rgb?this.model={argb:s.attributes.rgb}:s.attributes.theme?(this.model={theme:parseInt(s.attributes.theme,10)},s.attributes.tint&&(this.model.tint=parseFloat(s.attributes.tint))):s.attributes.indexed?this.model={indexed:parseInt(s.attributes.indexed,10)}:this.model=void 0,!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],129:[function(e,a,f){const c=e("../base-xform"),s=e("./alignment-xform"),l=e("./border-xform"),i=e("./fill-xform"),n=e("./font-xform"),o=e("./numfmt-xform"),h=e("./protection-xform");a.exports=class extends c{constructor(){super(),this.map={alignment:new s,border:new l,fill:new i,font:new n,numFmt:new o,protection:new h}}get tag(){return"dxf"}render(u,d){if(u.openNode(this.tag),d.font&&this.map.font.render(u,d.font),d.numFmt&&d.numFmtId){const m={id:d.numFmtId,formatCode:d.numFmt};this.map.numFmt.render(u,m)}d.fill&&this.map.fill.render(u,d.fill),d.alignment&&this.map.alignment.render(u,d.alignment),d.border&&this.map.border.render(u,d.border),d.protection&&this.map.protection.render(u,d.protection),u.closeNode()}parseOpen(u){if(this.parser)return this.parser.parseOpen(u),!0;switch(u.name){case this.tag:return this.reset(),!0;default:return this.parser=this.map[u.name],this.parser&&this.parser.parseOpen(u),!0}}parseText(u){this.parser&&this.parser.parseText(u)}parseClose(u){return this.parser?(this.parser.parseClose(u)||(this.parser=void 0),!0):u!==this.tag||(this.model={alignment:this.map.alignment.model,border:this.map.border.model,fill:this.map.fill.model,font:this.map.font.model,numFmt:this.map.numFmt.model,protection:this.map.protection.model},!1)}}},{"../base-xform":32,"./alignment-xform":126,"./border-xform":127,"./fill-xform":130,"./font-xform":131,"./numfmt-xform":132,"./protection-xform":133}],130:[function(e,a,f){const c=e("../base-xform"),s=e("./color-xform");class l extends c{constructor(){super(),this.map={color:new s}}get tag(){return"stop"}render(u,d){u.openNode("stop"),u.addAttribute("position",d.position),this.map.color.render(u,d.color),u.closeNode()}parseOpen(u){if(this.parser)return this.parser.parseOpen(u),!0;switch(u.name){case"stop":return this.model={position:parseFloat(u.attributes.position)},!0;case"color":return this.parser=this.map.color,this.parser.parseOpen(u),!0;default:return!1}}parseText(){}parseClose(u){return!!this.parser&&(this.parser.parseClose(u)||(this.model.color=this.parser.model,this.parser=void 0),!0)}}class i extends c{constructor(){super(),this.map={fgColor:new s("fgColor"),bgColor:new s("bgColor")}}get name(){return"pattern"}get tag(){return"patternFill"}render(u,d){u.openNode("patternFill"),u.addAttribute("patternType",d.pattern),d.fgColor&&this.map.fgColor.render(u,d.fgColor),d.bgColor&&this.map.bgColor.render(u,d.bgColor),u.closeNode()}parseOpen(u){if(this.parser)return this.parser.parseOpen(u),!0;switch(u.name){case"patternFill":return this.model={type:"pattern",pattern:u.attributes.patternType},!0;default:return this.parser=this.map[u.name],!!this.parser&&(this.parser.parseOpen(u),!0)}}parseText(u){this.parser&&this.parser.parseText(u)}parseClose(u){return!!this.parser&&(this.parser.parseClose(u)||(this.parser.model&&(this.model[u]=this.parser.model),this.parser=void 0),!0)}}class n extends c{constructor(){super(),this.map={stop:new l}}get name(){return"gradient"}get tag(){return"gradientFill"}render(u,d){switch(u.openNode("gradientFill"),d.gradient){case"angle":u.addAttribute("degree",d.degree);break;case"path":u.addAttribute("type","path"),d.center.left&&(u.addAttribute("left",d.center.left),d.center.right===void 0&&u.addAttribute("right",d.center.left)),d.center.right&&u.addAttribute("right",d.center.right),d.center.top&&(u.addAttribute("top",d.center.top),d.center.bottom===void 0&&u.addAttribute("bottom",d.center.top)),d.center.bottom&&u.addAttribute("bottom",d.center.bottom)}const m=this.map.stop;d.stops.forEach(b=>{m.render(u,b)}),u.closeNode()}parseOpen(u){if(this.parser)return this.parser.parseOpen(u),!0;switch(u.name){case"gradientFill":{const d=this.model={stops:[]};return u.attributes.degree?(d.gradient="angle",d.degree=parseInt(u.attributes.degree,10)):u.attributes.type==="path"&&(d.gradient="path",d.center={left:u.attributes.left?parseFloat(u.attributes.left):0,top:u.attributes.top?parseFloat(u.attributes.top):0},u.attributes.right!==u.attributes.left&&(d.center.right=u.attributes.right?parseFloat(u.attributes.right):0),u.attributes.bottom!==u.attributes.top&&(d.center.bottom=u.attributes.bottom?parseFloat(u.attributes.bottom):0)),!0}case"stop":return this.parser=this.map.stop,this.parser.parseOpen(u),!0;default:return!1}}parseText(u){this.parser&&this.parser.parseText(u)}parseClose(u){return!!this.parser&&(this.parser.parseClose(u)||(this.model.stops.push(this.parser.model),this.parser=void 0),!0)}}class o extends c{constructor(){super(),this.map={patternFill:new i,gradientFill:new n}}get tag(){return"fill"}render(u,d){switch(u.addRollback(),u.openNode("fill"),d.type){case"pattern":this.map.patternFill.render(u,d);break;case"gradient":this.map.gradientFill.render(u,d);break;default:return void u.rollback()}u.closeNode(),u.commit()}parseOpen(u){if(this.parser)return this.parser.parseOpen(u),!0;switch(u.name){case"fill":return this.model={},!0;default:return this.parser=this.map[u.name],!!this.parser&&(this.parser.parseOpen(u),!0)}}parseText(u){this.parser&&this.parser.parseText(u)}parseClose(u){return!!this.parser&&(this.parser.parseClose(u)||(this.model=this.parser.model,this.model.type=this.parser.name,this.parser=void 0),!0)}validStyle(u){return o.validPatternValues[u]}}o.validPatternValues=["none","solid","darkVertical","darkGray","mediumGray","lightGray","gray125","gray0625","darkHorizontal","darkVertical","darkDown","darkUp","darkGrid","darkTrellis","lightHorizontal","lightVertical","lightDown","lightUp","lightGrid","lightTrellis","lightGrid"].reduce((h,u)=>(h[u]=!0,h),{}),o.StopXform=l,o.PatternFillXform=i,o.GradientFillXform=n,a.exports=o},{"../base-xform":32,"./color-xform":128}],131:[function(e,a,f){const c=e("./color-xform"),s=e("../simple/boolean-xform"),l=e("../simple/integer-xform"),i=e("../simple/string-xform"),n=e("./underline-xform"),o=e("../../../utils/under-dash"),h=e("../base-xform");class u extends h{constructor(m){super(),this.options=m||u.OPTIONS,this.map={b:{prop:"bold",xform:new s({tag:"b",attr:"val"})},i:{prop:"italic",xform:new s({tag:"i",attr:"val"})},u:{prop:"underline",xform:new n},charset:{prop:"charset",xform:new l({tag:"charset",attr:"val"})},color:{prop:"color",xform:new c},condense:{prop:"condense",xform:new s({tag:"condense",attr:"val"})},extend:{prop:"extend",xform:new s({tag:"extend",attr:"val"})},family:{prop:"family",xform:new l({tag:"family",attr:"val"})},outline:{prop:"outline",xform:new s({tag:"outline",attr:"val"})},vertAlign:{prop:"vertAlign",xform:new i({tag:"vertAlign",attr:"val"})},scheme:{prop:"scheme",xform:new i({tag:"scheme",attr:"val"})},shadow:{prop:"shadow",xform:new s({tag:"shadow",attr:"val"})},strike:{prop:"strike",xform:new s({tag:"strike",attr:"val"})},sz:{prop:"size",xform:new l({tag:"sz",attr:"val"})}},this.map[this.options.fontNameTag]={prop:"name",xform:new i({tag:this.options.fontNameTag,attr:"val"})}}get tag(){return this.options.tagName}render(m,b){const{map:p}=this;m.openNode(this.options.tagName),o.each(this.map,(v,g)=>{p[g].xform.render(m,b[v.prop])}),m.closeNode()}parseOpen(m){if(this.parser)return this.parser.parseOpen(m),!0;if(this.map[m.name])return this.parser=this.map[m.name].xform,this.parser.parseOpen(m);switch(m.name){case this.options.tagName:return this.model={},!0;default:return!1}}parseText(m){this.parser&&this.parser.parseText(m)}parseClose(m){if(this.parser&&!this.parser.parseClose(m)){const b=this.map[m];return this.parser.model&&(this.model[b.prop]=this.parser.model),this.parser=void 0,!0}switch(m){case this.options.tagName:return!1;default:return!0}}}u.OPTIONS={tagName:"font",fontNameTag:"name"},a.exports=u},{"../../../utils/under-dash":26,"../base-xform":32,"../simple/boolean-xform":116,"../simple/integer-xform":118,"../simple/string-xform":119,"./color-xform":128,"./underline-xform":136}],132:[function(e,a,f){const c=e("../../../utils/under-dash"),s=e("../../defaultnumformats"),l=e("../base-xform"),i=function(){const o={};return c.each(s,(h,u)=>{h.f&&(o[h.f]=parseInt(u,10))}),o}();class n extends l{constructor(h,u){super(),this.id=h,this.formatCode=u}get tag(){return"numFmt"}render(h,u){h.leafNode("numFmt",{numFmtId:u.id,formatCode:u.formatCode})}parseOpen(h){switch(h.name){case"numFmt":return this.model={id:parseInt(h.attributes.numFmtId,10),formatCode:h.attributes.formatCode.replace(/[\\](.)/g,"$1")},!0;default:return!1}}parseText(){}parseClose(){return!1}}n.getDefaultFmtId=function(o){return i[o]},n.getDefaultFmtCode=function(o){return s[o]&&s[o].f},a.exports=n},{"../../../utils/under-dash":26,"../../defaultnumformats":30,"../base-xform":32}],133:[function(e,a,f){const c=e("../base-xform"),s={boolean:(l,i)=>l===void 0?i:l};a.exports=class extends c{get tag(){return"protection"}render(l,i){l.addRollback(),l.openNode("protection");let n=!1;function o(h,u){u!==void 0&&(l.addAttribute(h,u),n=!0)}o("locked",s.boolean(i.locked,!0)?void 0:"0"),o("hidden",s.boolean(i.hidden,!1)?"1":void 0),l.closeNode(),n?l.commit():l.rollback()}parseOpen(l){const i={locked:l.attributes.locked!=="0",hidden:l.attributes.hidden==="1"},n=!i.locked||i.hidden;this.model=n?i:null}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],134:[function(e,a,f){const c=e("../base-xform"),s=e("./alignment-xform"),l=e("./protection-xform");a.exports=class extends c{constructor(i){super(),this.xfId=!(!i||!i.xfId),this.map={alignment:new s,protection:new l}}get tag(){return"xf"}render(i,n){i.openNode("xf",{numFmtId:n.numFmtId||0,fontId:n.fontId||0,fillId:n.fillId||0,borderId:n.borderId||0}),this.xfId&&i.addAttribute("xfId",n.xfId||0),n.numFmtId&&i.addAttribute("applyNumberFormat","1"),n.fontId&&i.addAttribute("applyFont","1"),n.fillId&&i.addAttribute("applyFill","1"),n.borderId&&i.addAttribute("applyBorder","1"),n.alignment&&i.addAttribute("applyAlignment","1"),n.protection&&i.addAttribute("applyProtection","1"),n.alignment&&this.map.alignment.render(i,n.alignment),n.protection&&this.map.protection.render(i,n.protection),i.closeNode()}parseOpen(i){if(this.parser)return this.parser.parseOpen(i),!0;switch(i.name){case"xf":return this.model={numFmtId:parseInt(i.attributes.numFmtId,10),fontId:parseInt(i.attributes.fontId,10),fillId:parseInt(i.attributes.fillId,10),borderId:parseInt(i.attributes.borderId,10)},this.xfId&&(this.model.xfId=parseInt(i.attributes.xfId,10)),!0;case"alignment":return this.parser=this.map.alignment,this.parser.parseOpen(i),!0;case"protection":return this.parser=this.map.protection,this.parser.parseOpen(i),!0;default:return!1}}parseText(i){this.parser&&this.parser.parseText(i)}parseClose(i){return this.parser?(this.parser.parseClose(i)||(this.map.protection===this.parser?this.model.protection=this.parser.model:this.model.alignment=this.parser.model,this.parser=void 0),!0):i!=="xf"}}},{"../base-xform":32,"./alignment-xform":126,"./protection-xform":133}],135:[function(e,a,f){const c=e("../../../doc/enums"),s=e("../../../utils/xml-stream"),l=e("../base-xform"),i=e("../static-xform"),n=e("../list-xform"),o=e("./font-xform"),h=e("./fill-xform"),u=e("./border-xform"),d=e("./numfmt-xform"),m=e("./style-xform"),b=e("./dxf-xform");class p extends l{constructor(g){super(),this.map={numFmts:new n({tag:"numFmts",count:!0,childXform:new d}),fonts:new n({tag:"fonts",count:!0,childXform:new o,$:{"x14ac:knownFonts":1}}),fills:new n({tag:"fills",count:!0,childXform:new h}),borders:new n({tag:"borders",count:!0,childXform:new u}),cellStyleXfs:new n({tag:"cellStyleXfs",count:!0,childXform:new m}),cellXfs:new n({tag:"cellXfs",count:!0,childXform:new m({xfId:!0})}),dxfs:new n({tag:"dxfs",always:!0,count:!0,childXform:new b}),numFmt:new d,font:new o,fill:new h,border:new u,style:new m({xfId:!0}),cellStyles:p.STATIC_XFORMS.cellStyles,tableStyles:p.STATIC_XFORMS.tableStyles,extLst:p.STATIC_XFORMS.extLst},g&&this.init()}initIndex(){this.index={style:{},numFmt:{},numFmtNextId:164,font:{},border:{},fill:{}}}init(){this.model={styles:[],numFmts:[],fonts:[],borders:[],fills:[],dxfs:[]},this.initIndex(),this._addBorder({}),this._addStyle({numFmtId:0,fontId:0,fillId:0,borderId:0,xfId:0}),this._addFill({type:"pattern",pattern:"none"}),this._addFill({type:"pattern",pattern:"gray125"}),this.weakMap=new WeakMap}render(g,x){x=x||this.model,g.openXml(s.StdDocAttributes),g.openNode("styleSheet",p.STYLESHEET_ATTRIBUTES),this.index?(x.numFmts&&x.numFmts.length&&(g.openNode("numFmts",{count:x.numFmts.length}),x.numFmts.forEach(C=>{g.writeXml(C)}),g.closeNode()),x.fonts.length||this._addFont({size:11,color:{theme:1},name:"Calibri",family:2,scheme:"minor"}),g.openNode("fonts",{count:x.fonts.length,"x14ac:knownFonts":1}),x.fonts.forEach(C=>{g.writeXml(C)}),g.closeNode(),g.openNode("fills",{count:x.fills.length}),x.fills.forEach(C=>{g.writeXml(C)}),g.closeNode(),g.openNode("borders",{count:x.borders.length}),x.borders.forEach(C=>{g.writeXml(C)}),g.closeNode(),this.map.cellStyleXfs.render(g,[{numFmtId:0,fontId:0,fillId:0,borderId:0,xfId:0}]),g.openNode("cellXfs",{count:x.styles.length}),x.styles.forEach(C=>{g.writeXml(C)}),g.closeNode()):(this.map.numFmts.render(g,x.numFmts),this.map.fonts.render(g,x.fonts),this.map.fills.render(g,x.fills),this.map.borders.render(g,x.borders),this.map.cellStyleXfs.render(g,[{numFmtId:0,fontId:0,fillId:0,borderId:0,xfId:0}]),this.map.cellXfs.render(g,x.styles)),p.STATIC_XFORMS.cellStyles.render(g),this.map.dxfs.render(g,x.dxfs),p.STATIC_XFORMS.tableStyles.render(g),p.STATIC_XFORMS.extLst.render(g),g.closeNode()}parseOpen(g){if(this.parser)return this.parser.parseOpen(g),!0;switch(g.name){case"styleSheet":return this.initIndex(),!0;default:return this.parser=this.map[g.name],this.parser&&this.parser.parseOpen(g),!0}}parseText(g){this.parser&&this.parser.parseText(g)}parseClose(g){if(this.parser)return this.parser.parseClose(g)||(this.parser=void 0),!0;switch(g){case"styleSheet":{this.model={};const x=(C,T)=>{T.model&&T.model.length&&(this.model[C]=T.model)};if(x("numFmts",this.map.numFmts),x("fonts",this.map.fonts),x("fills",this.map.fills),x("borders",this.map.borders),x("styles",this.map.cellXfs),x("dxfs",this.map.dxfs),this.index={model:[],numFmt:[]},this.model.numFmts){const C=this.index.numFmt;this.model.numFmts.forEach(T=>{C[T.id]=T.formatCode})}return!1}default:return!0}}addStyleModel(g,x){if(!g)return 0;if(this.model.fonts.length||this._addFont({size:11,color:{theme:1},name:"Calibri",family:2,scheme:"minor"}),this.weakMap&&this.weakMap.has(g))return this.weakMap.get(g);const C={};if(x=x||c.ValueType.Number,g.numFmt)C.numFmtId=this._addNumFmtStr(g.numFmt);else switch(x){case c.ValueType.Number:C.numFmtId=this._addNumFmtStr("General");break;case c.ValueType.Date:C.numFmtId=this._addNumFmtStr("mm-dd-yy")}g.font&&(C.fontId=this._addFont(g.font)),g.border&&(C.borderId=this._addBorder(g.border)),g.fill&&(C.fillId=this._addFill(g.fill)),g.alignment&&(C.alignment=g.alignment),g.protection&&(C.protection=g.protection);const T=this._addStyle(C);return this.weakMap&&this.weakMap.set(g,T),T}getStyleModel(g){const x=this.model.styles[g];if(!x)return null;let C=this.index.model[g];if(C)return C;if(C=this.index.model[g]={},x.numFmtId){const R=this.index.numFmt[x.numFmtId]||d.getDefaultFmtCode(x.numFmtId);R&&(C.numFmt=R)}function T(R,B,I){if(I||I===0){const F=B[I];F&&(C[R]=F)}}return T("font",this.model.fonts,x.fontId),T("border",this.model.borders,x.borderId),T("fill",this.model.fills,x.fillId),x.alignment&&(C.alignment=x.alignment),x.protection&&(C.protection=x.protection),C}addDxfStyle(g){return g.numFmt&&(g.numFmtId=this._addNumFmtStr(g.numFmt)),this.model.dxfs.push(g),this.model.dxfs.length-1}getDxfStyle(g){return this.model.dxfs[g]}_addStyle(g){const x=this.map.style.toXml(g);let C=this.index.style[x];return C===void 0&&(C=this.index.style[x]=this.model.styles.length,this.model.styles.push(x)),C}_addNumFmtStr(g){let x=d.getDefaultFmtId(g);if(x!==void 0||(x=this.index.numFmt[g],x!==void 0))return x;x=this.index.numFmt[g]=164+this.model.numFmts.length;const C=this.map.numFmt.toXml({id:x,formatCode:g});return this.model.numFmts.push(C),x}_addFont(g){const x=this.map.font.toXml(g);let C=this.index.font[x];return C===void 0&&(C=this.index.font[x]=this.model.fonts.length,this.model.fonts.push(x)),C}_addBorder(g){const x=this.map.border.toXml(g);let C=this.index.border[x];return C===void 0&&(C=this.index.border[x]=this.model.borders.length,this.model.borders.push(x)),C}_addFill(g){const x=this.map.fill.toXml(g);let C=this.index.fill[x];return C===void 0&&(C=this.index.fill[x]=this.model.fills.length,this.model.fills.push(x)),C}}p.STYLESHEET_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","mc:Ignorable":"x14ac x16r2","xmlns:x14ac":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac","xmlns:x16r2":"http://schemas.microsoft.com/office/spreadsheetml/2015/02/main"},p.STATIC_XFORMS={cellStyles:new i({tag:"cellStyles",$:{count:1},c:[{tag:"cellStyle",$:{name:"Normal",xfId:0,builtinId:0}}]}),dxfs:new i({tag:"dxfs",$:{count:0}}),tableStyles:new i({tag:"tableStyles",$:{count:0,defaultTableStyle:"TableStyleMedium2",defaultPivotStyle:"PivotStyleLight16"}}),extLst:new i({tag:"extLst",c:[{tag:"ext",$:{uri:"{EB79DEF2-80B8-43e5-95BD-54CBDDF9020C}","xmlns:x14":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/main"},c:[{tag:"x14:slicerStyles",$:{defaultSlicerStyle:"SlicerStyleLight1"}}]},{tag:"ext",$:{uri:"{9260A510-F301-46a8-8635-F512D64BE5F5}","xmlns:x15":"http://schemas.microsoft.com/office/spreadsheetml/2010/11/main"},c:[{tag:"x15:timelineStyles",$:{defaultTimelineStyle:"TimeSlicerStyleLight1"}}]}]})},p.Mock=class extends p{constructor(){super(),this.model={styles:[{numFmtId:0,fontId:0,fillId:0,borderId:0,xfId:0}],numFmts:[],fonts:[{size:11,color:{theme:1},name:"Calibri",family:2,scheme:"minor"}],borders:[{}],fills:[{type:"pattern",pattern:"none"},{type:"pattern",pattern:"gray125"}]}}parseStream(v){return v.autodrain(),Promise.resolve()}addStyleModel(v,g){switch(g){case c.ValueType.Date:return this.dateStyleId;default:return 0}}get dateStyleId(){if(!this._dateStyleId){const v={numFmtId:d.getDefaultFmtId("mm-dd-yy")};this._dateStyleId=this.model.styles.length,this.model.styles.push(v)}return this._dateStyleId}getStyleModel(){return{}}},a.exports=p},{"../../../doc/enums":7,"../../../utils/xml-stream":28,"../base-xform":32,"../list-xform":71,"../static-xform":120,"./border-xform":127,"./dxf-xform":129,"./fill-xform":130,"./font-xform":131,"./numfmt-xform":132,"./style-xform":134}],136:[function(e,a,f){const c=e("../base-xform");class s extends c{constructor(i){super(),this.model=i}get tag(){return"u"}render(i,n){if((n=n||this.model)===!0)i.leafNode("u");else{const o=s.Attributes[n];o&&i.leafNode("u",o)}}parseOpen(i){i.name==="u"&&(this.model=i.attributes.val||!0)}parseText(){}parseClose(){return!1}}s.Attributes={single:{},double:{val:"double"},singleAccounting:{val:"singleAccounting"},doubleAccounting:{val:"doubleAccounting"}},a.exports=s},{"../base-xform":32}],137:[function(e,a,f){const c=e("../base-xform"),s=e("./filter-column-xform");a.exports=class extends c{constructor(){super(),this.map={filterColumn:new s}}get tag(){return"autoFilter"}prepare(l){l.columns.forEach((i,n)=>{this.map.filterColumn.prepare(i,{index:n})})}render(l,i){return l.openNode(this.tag,{ref:i.autoFilterRef}),i.columns.forEach(n=>{this.map.filterColumn.render(l,n)}),l.closeNode(),!0}parseOpen(l){if(this.parser)return this.parser.parseOpen(l),!0;switch(l.name){case this.tag:return this.model={autoFilterRef:l.attributes.ref,columns:[]},!0;default:if(this.parser=this.map[l.name],this.parser)return this.parseOpen(l),!0;throw new Error("Unexpected xml node in parseOpen: "+JSON.stringify(l))}}parseText(l){this.parser&&this.parser.parseText(l)}parseClose(l){if(this.parser)return this.parser.parseClose(l)||(this.model.columns.push(this.parser.model),this.parser=void 0),!0;switch(l){case this.tag:return!1;default:throw new Error("Unexpected xml node in parseClose: "+l)}}}},{"../base-xform":32,"./filter-column-xform":139}],138:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"customFilter"}render(s,l){s.leafNode(this.tag,{val:l.val,operator:l.operator})}parseOpen(s){return s.name===this.tag&&(this.model={val:s.attributes.val,operator:s.attributes.operator},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],139:[function(e,a,f){const c=e("../base-xform"),s=e("../list-xform"),l=e("./custom-filter-xform"),i=e("./filter-xform");a.exports=class extends c{constructor(){super(),this.map={customFilters:new s({tag:"customFilters",count:!1,empty:!0,childXform:new l}),filters:new s({tag:"filters",count:!1,empty:!0,childXform:new i})}}get tag(){return"filterColumn"}prepare(n,o){n.colId=o.index.toString()}render(n,o){return o.customFilters?(n.openNode(this.tag,{colId:o.colId,hiddenButton:o.filterButton?"0":"1"}),this.map.customFilters.render(n,o.customFilters),n.closeNode(),!0):(n.leafNode(this.tag,{colId:o.colId,hiddenButton:o.filterButton?"0":"1"}),!0)}parseOpen(n){if(this.parser)return this.parser.parseOpen(n),!0;const{attributes:o}=n;switch(n.name){case this.tag:return this.model={filterButton:o.hiddenButton==="0"},!0;default:if(this.parser=this.map[n.name],this.parser)return this.parseOpen(n),!0;throw new Error("Unexpected xml node in parseOpen: "+JSON.stringify(n))}}parseText(){}parseClose(n){if(this.parser)return this.parser.parseClose(n)||(this.parser=void 0),!0;switch(n){case this.tag:return this.model.customFilters=this.map.customFilters.model,!1;default:return!0}}}},{"../base-xform":32,"../list-xform":71,"./custom-filter-xform":138,"./filter-xform":140}],140:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"filter"}render(s,l){s.leafNode(this.tag,{val:l.val})}parseOpen(s){return s.name===this.tag&&(this.model={val:s.attributes.val},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],141:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"tableColumn"}prepare(s,l){s.id=l.index+1}render(s,l){return s.leafNode(this.tag,{id:l.id.toString(),name:l.name,totalsRowLabel:l.totalsRowLabel,totalsRowFunction:l.totalsRowFunction,dxfId:l.dxfId}),!0}parseOpen(s){if(s.name===this.tag){const{attributes:l}=s;return this.model={name:l.name,totalsRowLabel:l.totalsRowLabel,totalsRowFunction:l.totalsRowFunction,dxfId:l.dxfId},!0}return!1}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],142:[function(e,a,f){const c=e("../base-xform");a.exports=class extends c{get tag(){return"tableStyleInfo"}render(s,l){return s.leafNode(this.tag,{name:l.theme?l.theme:void 0,showFirstColumn:l.showFirstColumn?"1":"0",showLastColumn:l.showLastColumn?"1":"0",showRowStripes:l.showRowStripes?"1":"0",showColumnStripes:l.showColumnStripes?"1":"0"}),!0}parseOpen(s){if(s.name===this.tag){const{attributes:l}=s;return this.model={theme:l.name?l.name:null,showFirstColumn:l.showFirstColumn==="1",showLastColumn:l.showLastColumn==="1",showRowStripes:l.showRowStripes==="1",showColumnStripes:l.showColumnStripes==="1"},!0}return!1}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],143:[function(e,a,f){const c=e("../../../utils/xml-stream"),s=e("../base-xform"),l=e("../list-xform"),i=e("./auto-filter-xform"),n=e("./table-column-xform"),o=e("./table-style-info-xform");class h extends s{constructor(){super(),this.map={autoFilter:new i,tableColumns:new l({tag:"tableColumns",count:!0,empty:!0,childXform:new n}),tableStyleInfo:new o}}prepare(d,m){this.map.autoFilter.prepare(d),this.map.tableColumns.prepare(d.columns,m)}get tag(){return"table"}render(d,m){d.openXml(c.StdDocAttributes),d.openNode(this.tag,{...h.TABLE_ATTRIBUTES,id:m.id,name:m.name,displayName:m.displayName||m.name,ref:m.tableRef,totalsRowCount:m.totalsRow?"1":void 0,totalsRowShown:m.totalsRow?void 0:"1",headerRowCount:m.headerRow?"1":"0"}),this.map.autoFilter.render(d,m),this.map.tableColumns.render(d,m.columns),this.map.tableStyleInfo.render(d,m.style),d.closeNode()}parseOpen(d){if(this.parser)return this.parser.parseOpen(d),!0;const{name:m,attributes:b}=d;switch(m){case this.tag:this.reset(),this.model={name:b.name,displayName:b.displayName||b.name,tableRef:b.ref,totalsRow:b.totalsRowCount==="1",headerRow:b.headerRowCount==="1"};break;default:this.parser=this.map[d.name],this.parser&&this.parser.parseOpen(d)}return!0}parseText(d){this.parser&&this.parser.parseText(d)}parseClose(d){if(this.parser)return this.parser.parseClose(d)||(this.parser=void 0),!0;switch(d){case this.tag:return this.model.columns=this.map.tableColumns.model,this.map.autoFilter.model&&(this.model.autoFilterRef=this.map.autoFilter.model.autoFilterRef,this.map.autoFilter.model.columns.forEach((m,b)=>{this.model.columns[b].filterButton=m.filterButton})),this.model.style=this.map.tableStyleInfo.model,!1;default:return!0}}reconcile(d,m){d.columns.forEach(b=>{b.dxfId!==void 0&&(b.style=m.styles.getDxfStyle(b.dxfId))})}}h.TABLE_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","mc:Ignorable":"xr xr3","xmlns:xr":"http://schemas.microsoft.com/office/spreadsheetml/2014/revision","xmlns:xr3":"http://schemas.microsoft.com/office/spreadsheetml/2016/revision3"},a.exports=h},{"../../../utils/xml-stream":28,"../base-xform":32,"../list-xform":71,"./auto-filter-xform":137,"./table-column-xform":141,"./table-style-info-xform":142}],144:[function(e,a,f){(function(c,s){(function(){const l=e("fs"),i=e("jszip"),{PassThrough:n}=e("readable-stream"),o=e("../utils/zip-stream"),h=e("../utils/stream-buf"),u=e("../utils/utils"),d=e("../utils/xml-stream"),{bufferToString:m}=e("../utils/browser-buffer-decode"),b=e("./xform/style/styles-xform"),p=e("./xform/core/core-xform"),v=e("./xform/strings/shared-strings-xform"),g=e("./xform/core/relationships-xform"),x=e("./xform/core/content-types-xform"),C=e("./xform/core/app-xform"),T=e("./xform/book/workbook-xform"),R=e("./xform/sheet/worksheet-xform"),B=e("./xform/drawing/drawing-xform"),I=e("./xform/table/table-xform"),F=e("./xform/comment/comments-xform"),L=e("./xform/comment/vml-notes-xform"),V=e("./xml/theme1");class z{constructor(P){this.workbook=P}async readFile(P,k){if(!await u.fs.exists(P))throw new Error("File not found: "+P);const y=l.createReadStream(P);try{const w=await this.read(y,k);return y.close(),w}catch(w){throw y.close(),w}}parseRels(P){return new g().parseStream(P)}parseWorkbook(P){return new T().parseStream(P)}parseSharedStrings(P){return new v().parseStream(P)}reconcile(P,k){const y=new T,w=new R(k),_=new B,S=new I;y.reconcile(P);const A={media:P.media,mediaIndex:P.mediaIndex};Object.keys(P.drawings).forEach(U=>{const H=P.drawings[U],Z=P.drawingRels[U];Z&&(A.rels=Z.reduce((D,q)=>(D[q.Id]=q,D),{}),(H.anchors||[]).forEach(D=>{const q=D.picture&&D.picture.hyperlinks;q&&A.rels[q.rId]&&(q.hyperlink=A.rels[q.rId].Target,delete q.rId)}),_.reconcile(H,A))});const O={styles:P.styles};Object.values(P.tables).forEach(U=>{S.reconcile(U,O)});const N={styles:P.styles,sharedStrings:P.sharedStrings,media:P.media,mediaIndex:P.mediaIndex,date1904:P.properties&&P.properties.date1904,drawings:P.drawings,comments:P.comments,tables:P.tables,vmlDrawings:P.vmlDrawings};P.worksheets.forEach(U=>{U.relationships=P.worksheetRels[U.sheetNo],w.reconcile(U,N)}),delete P.worksheetHash,delete P.worksheetRels,delete P.globalRels,delete P.sharedStrings,delete P.workbookRels,delete P.sheetDefs,delete P.styles,delete P.mediaIndex,delete P.drawings,delete P.drawingRels,delete P.vmlDrawings}async _processWorksheetEntry(P,k,y,w,_){const S=new R(w),A=await S.parseStream(P);A.sheetNo=y,k.worksheetHash[_]=A,k.worksheets.push(A)}async _processCommentEntry(P,k,y){const w=new F,_=await w.parseStream(P);k.comments[`../${y}.xml`]=_}async _processTableEntry(P,k,y){const w=new I,_=await w.parseStream(P);k.tables[`../tables/${y}.xml`]=_}async _processWorksheetRelsEntry(P,k,y){const w=new g,_=await w.parseStream(P);k.worksheetRels[y]=_}async _processMediaEntry(P,k,y){const w=y.lastIndexOf(".");if(w>=1){const _=y.substr(w+1),S=y.substr(0,w);await new Promise((A,O)=>{const N=new h;N.on("finish",()=>{k.mediaIndex[y]=k.media.length,k.mediaIndex[S]=k.media.length;const U={type:"image",name:S,extension:_,buffer:N.toBuffer()};k.media.push(U),A()}),P.on("error",U=>{O(U)}),P.pipe(N)})}}async _processDrawingEntry(P,k,y){const w=new B,_=await w.parseStream(P);k.drawings[y]=_}async _processDrawingRelsEntry(P,k,y){const w=new g,_=await w.parseStream(P);k.drawingRels[y]=_}async _processVmlDrawingEntry(P,k,y){const w=new L,_=await w.parseStream(P);k.vmlDrawings[`../drawings/${y}.vml`]=_}async _processThemeEntry(P,k,y){await new Promise((w,_)=>{const S=new h;P.on("error",_),S.on("error",_),S.on("finish",()=>{k.themes[y]=S.read().toString(),w()}),P.pipe(S)})}createInputStream(){throw new Error("`XLSX#createInputStream` is deprecated. You should use `XLSX#read` instead. This method will be removed in version 5.0. Please follow upgrade instruction: https://github.com/exceljs/exceljs/blob/master/UPGRADE-4.0.md")}async read(P,k){!P[Symbol.asyncIterator]&&P.pipe&&(P=P.pipe(new n));const y=[];for await(const w of P)y.push(w);return this.load(s.concat(y),k)}async load(P,k){let y;y=k&&k.base64?s.from(P.toString(),"base64"):P;const w={worksheets:[],worksheetHash:{},worksheetRels:[],themes:{},media:[],mediaIndex:{},drawings:{},drawingRels:{},comments:{},tables:{},vmlDrawings:{}},_=await i.loadAsync(y);for(const S of Object.values(_.files))if(!S.dir){let A,O=S.name;if(O[0]==="/"&&(O=O.substr(1)),O.match(/xl\/media\//)||O.match(/xl\/theme\/([a-zA-Z0-9]+)[.]xml/))A=new n,A.write(await S.async("nodebuffer"));else{let N;A=new n({writableObjectMode:!0,readableObjectMode:!0}),N=c.browser?m(await S.async("nodebuffer")):await S.async("string");const U=16384;for(let H=0;H<N.length;H+=U)A.write(N.substring(H,H+U))}switch(A.end(),O){case"_rels/.rels":w.globalRels=await this.parseRels(A);break;case"xl/workbook.xml":{const N=await this.parseWorkbook(A);w.sheets=N.sheets,w.definedNames=N.definedNames,w.views=N.views,w.properties=N.properties,w.calcProperties=N.calcProperties;break}case"xl/_rels/workbook.xml.rels":w.workbookRels=await this.parseRels(A);break;case"xl/sharedStrings.xml":w.sharedStrings=new v,await w.sharedStrings.parseStream(A);break;case"xl/styles.xml":w.styles=new b,await w.styles.parseStream(A);break;case"docProps/app.xml":{const N=new C,U=await N.parseStream(A);w.company=U.company,w.manager=U.manager;break}case"docProps/core.xml":{const N=new p,U=await N.parseStream(A);Object.assign(w,U);break}default:{let N=O.match(/xl\/worksheets\/sheet(\d+)[.]xml/);if(N){await this._processWorksheetEntry(A,w,N[1],k,O);break}if(N=O.match(/xl\/worksheets\/_rels\/sheet(\d+)[.]xml.rels/),N){await this._processWorksheetRelsEntry(A,w,N[1]);break}if(N=O.match(/xl\/theme\/([a-zA-Z0-9]+)[.]xml/),N){await this._processThemeEntry(A,w,N[1]);break}if(N=O.match(/xl\/media\/([a-zA-Z0-9]+[.][a-zA-Z0-9]{3,4})$/),N){await this._processMediaEntry(A,w,N[1]);break}if(N=O.match(/xl\/drawings\/([a-zA-Z0-9]+)[.]xml/),N){await this._processDrawingEntry(A,w,N[1]);break}if(N=O.match(/xl\/(comments\d+)[.]xml/),N){await this._processCommentEntry(A,w,N[1]);break}if(N=O.match(/xl\/tables\/(table\d+)[.]xml/),N){await this._processTableEntry(A,w,N[1]);break}if(N=O.match(/xl\/drawings\/_rels\/([a-zA-Z0-9]+)[.]xml[.]rels/),N){await this._processDrawingRelsEntry(A,w,N[1]);break}if(N=O.match(/xl\/drawings\/(vmlDrawing\d+)[.]vml/),N){await this._processVmlDrawingEntry(A,w,N[1]);break}}}}return this.reconcile(w,k),this.workbook.model=w,this.workbook}async addMedia(P,k){await Promise.all(k.media.map(async y=>{if(y.type==="image"){const w=`xl/media/${y.name}.${y.extension}`;if(y.filename){const _=await function(S,A){return new Promise((O,N)=>{l.readFile(S,A,(U,H)=>{U?N(U):O(H)})})}(y.filename);return P.append(_,{name:w})}if(y.buffer)return P.append(y.buffer,{name:w});if(y.base64){const _=y.base64,S=_.substring(_.indexOf(",")+1);return P.append(S,{name:w,base64:!0})}}throw new Error("Unsupported media")}))}addDrawings(P,k){const y=new B,w=new g;k.worksheets.forEach(_=>{const{drawing:S}=_;if(S){y.prepare(S,{});let A=y.toXml(S);P.append(A,{name:`xl/drawings/${S.name}.xml`}),A=w.toXml(S.rels),P.append(A,{name:`xl/drawings/_rels/${S.name}.xml.rels`})}})}addTables(P,k){const y=new I;k.worksheets.forEach(w=>{const{tables:_}=w;_.forEach(S=>{y.prepare(S,{});const A=y.toXml(S);P.append(A,{name:"xl/tables/"+S.target})})})}async addContentTypes(P,k){const y=new x().toXml(k);P.append(y,{name:"[Content_Types].xml"})}async addApp(P,k){const y=new C().toXml(k);P.append(y,{name:"docProps/app.xml"})}async addCore(P,k){const y=new p;P.append(y.toXml(k),{name:"docProps/core.xml"})}async addThemes(P,k){const y=k.themes||{theme1:V};Object.keys(y).forEach(w=>{const _=y[w],S=`xl/theme/${w}.xml`;P.append(_,{name:S})})}async addOfficeRels(P){const k=new g().toXml([{Id:"rId1",Type:z.RelType.OfficeDocument,Target:"xl/workbook.xml"},{Id:"rId2",Type:z.RelType.CoreProperties,Target:"docProps/core.xml"},{Id:"rId3",Type:z.RelType.ExtenderProperties,Target:"docProps/app.xml"}]);P.append(k,{name:"_rels/.rels"})}async addWorkbookRels(P,k){let y=1;const w=[{Id:"rId"+y++,Type:z.RelType.Styles,Target:"styles.xml"},{Id:"rId"+y++,Type:z.RelType.Theme,Target:"theme/theme1.xml"}];k.sharedStrings.count&&w.push({Id:"rId"+y++,Type:z.RelType.SharedStrings,Target:"sharedStrings.xml"}),k.worksheets.forEach(S=>{S.rId="rId"+y++,w.push({Id:S.rId,Type:z.RelType.Worksheet,Target:`worksheets/sheet${S.id}.xml`})});const _=new g().toXml(w);P.append(_,{name:"xl/_rels/workbook.xml.rels"})}async addSharedStrings(P,k){k.sharedStrings&&k.sharedStrings.count&&P.append(k.sharedStrings.xml,{name:"xl/sharedStrings.xml"})}async addStyles(P,k){const{xml:y}=k.styles;y&&P.append(y,{name:"xl/styles.xml"})}async addWorkbook(P,k){const y=new T;P.append(y.toXml(k),{name:"xl/workbook.xml"})}async addWorksheets(P,k){const y=new R,w=new g,_=new F,S=new L;k.worksheets.forEach(A=>{let O=new d;y.render(O,A),P.append(O.xml,{name:`xl/worksheets/sheet${A.id}.xml`}),A.rels&&A.rels.length&&(O=new d,w.render(O,A.rels),P.append(O.xml,{name:`xl/worksheets/_rels/sheet${A.id}.xml.rels`})),A.comments.length>0&&(O=new d,_.render(O,A),P.append(O.xml,{name:`xl/comments${A.id}.xml`}),O=new d,S.render(O,A),P.append(O.xml,{name:`xl/drawings/vmlDrawing${A.id}.vml`}))})}_finalize(P){return new Promise((k,y)=>{P.on("finish",()=>{k(this)}),P.on("error",y),P.finalize()})}prepareModel(P,k){P.creator=P.creator||"ExcelJS",P.lastModifiedBy=P.lastModifiedBy||"ExcelJS",P.created=P.created||new Date,P.modified=P.modified||new Date,P.useSharedStrings=k.useSharedStrings===void 0||k.useSharedStrings,P.useStyles=k.useStyles===void 0||k.useStyles,P.sharedStrings=new v,P.styles=P.useStyles?new b(!0):new b.Mock;const y=new T,w=new R;y.prepare(P);const _={sharedStrings:P.sharedStrings,styles:P.styles,date1904:P.properties.date1904,drawingsCount:0,media:P.media};_.drawings=P.drawings=[],_.commentRefs=P.commentRefs=[];let S=0;P.tables=[],P.worksheets.forEach(A=>{A.tables.forEach(O=>{S++,O.target=`table${S}.xml`,O.id=S,P.tables.push(O)}),w.prepare(A,_)})}async write(P,k){k=k||{};const{model:y}=this.workbook,w=new o.ZipWriter(k.zip);return w.pipe(P),this.prepareModel(y,k),await this.addContentTypes(w,y),await this.addOfficeRels(w,y),await this.addWorkbookRels(w,y),await this.addWorksheets(w,y),await this.addSharedStrings(w,y),await this.addDrawings(w,y),await this.addTables(w,y),await Promise.all([this.addThemes(w,y),this.addStyles(w,y)]),await this.addMedia(w,y),await Promise.all([this.addApp(w,y),this.addCore(w,y)]),await this.addWorkbook(w,y),this._finalize(w)}writeFile(P,k){const y=l.createWriteStream(P);return new Promise((w,_)=>{y.on("finish",()=>{w()}),y.on("error",S=>{_(S)}),this.write(y,k).then(()=>{y.end()}).catch(S=>{_(S)})})}async writeBuffer(P){const k=new h;return await this.write(k,P),k.read()}}z.RelType=e("./rel-type"),a.exports=z}).call(this)}).call(this,e("_process"),e("buffer").Buffer)},{"../utils/browser-buffer-decode":16,"../utils/stream-buf":24,"../utils/utils":27,"../utils/xml-stream":28,"../utils/zip-stream":29,"./rel-type":31,"./xform/book/workbook-xform":38,"./xform/comment/comments-xform":40,"./xform/comment/vml-notes-xform":45,"./xform/core/app-xform":51,"./xform/core/content-types-xform":52,"./xform/core/core-xform":53,"./xform/core/relationships-xform":55,"./xform/drawing/drawing-xform":62,"./xform/sheet/worksheet-xform":115,"./xform/strings/shared-strings-xform":124,"./xform/style/styles-xform":135,"./xform/table/table-xform":143,"./xml/theme1":145,_process:467,buffer:220,fs:216,jszip:441,"readable-stream":491}],145:[function(e,a,f){a.exports=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <a:theme xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main" name="Office Theme"> <a:themeElements> <a:clrScheme name="Office"> <a:dk1> <a:sysClr val="windowText" lastClr="000000"/> </a:dk1> <a:lt1> <a:sysClr val="window" lastClr="FFFFFF"/> </a:lt1> <a:dk2> <a:srgbClr val="1F497D"/> </a:dk2> <a:lt2> <a:srgbClr val="EEECE1"/> </a:lt2> <a:accent1> <a:srgbClr val="4F81BD"/> </a:accent1> <a:accent2> <a:srgbClr val="C0504D"/> </a:accent2> <a:accent3> <a:srgbClr val="9BBB59"/> </a:accent3> <a:accent4> <a:srgbClr val="8064A2"/> </a:accent4> <a:accent5> <a:srgbClr val="4BACC6"/> </a:accent5> <a:accent6> <a:srgbClr val="F79646"/> </a:accent6> <a:hlink> <a:srgbClr val="0000FF"/> </a:hlink> <a:folHlink> <a:srgbClr val="800080"/> </a:folHlink> </a:clrScheme> <a:fontScheme name="Office"> <a:majorFont> <a:latin typeface="Cambria"/> <a:ea typeface=""/> <a:cs typeface=""/> <a:font script="Jpan" typeface="MS Pゴシック"/> <a:font script="Hang" typeface="맑은 고딕"/> <a:font script="Hans" typeface="宋体"/> <a:font script="Hant" typeface="新細明體"/> <a:font script="Arab" typeface="Times New Roman"/> <a:font script="Hebr" typeface="Times New Roman"/> <a:font script="Thai" typeface="Tahoma"/> <a:font script="Ethi" typeface="Nyala"/> <a:font script="Beng" typeface="Vrinda"/> <a:font script="Gujr" typeface="Shruti"/> <a:font script="Khmr" typeface="MoolBoran"/> <a:font script="Knda" typeface="Tunga"/> <a:font script="Guru" typeface="Raavi"/> <a:font script="Cans" typeface="Euphemia"/> <a:font script="Cher" typeface="Plantagenet Cherokee"/> <a:font script="Yiii" typeface="Microsoft Yi Baiti"/> <a:font script="Tibt" typeface="Microsoft Himalaya"/> <a:font script="Thaa" typeface="MV Boli"/> <a:font script="Deva" typeface="Mangal"/> <a:font script="Telu" typeface="Gautami"/> <a:font script="Taml" typeface="Latha"/> <a:font script="Syrc" typeface="Estrangelo Edessa"/> <a:font script="Orya" typeface="Kalinga"/> <a:font script="Mlym" typeface="Kartika"/> <a:font script="Laoo" typeface="DokChampa"/> <a:font script="Sinh" typeface="Iskoola Pota"/> <a:font script="Mong" typeface="Mongolian Baiti"/> <a:font script="Viet" typeface="Times New Roman"/> <a:font script="Uigh" typeface="Microsoft Uighur"/> <a:font script="Geor" typeface="Sylfaen"/> </a:majorFont> <a:minorFont> <a:latin typeface="Calibri"/> <a:ea typeface=""/> <a:cs typeface=""/> <a:font script="Jpan" typeface="MS Pゴシック"/> <a:font script="Hang" typeface="맑은 고딕"/> <a:font script="Hans" typeface="宋体"/> <a:font script="Hant" typeface="新細明體"/> <a:font script="Arab" typeface="Arial"/> <a:font script="Hebr" typeface="Arial"/> <a:font script="Thai" typeface="Tahoma"/> <a:font script="Ethi" typeface="Nyala"/> <a:font script="Beng" typeface="Vrinda"/> <a:font script="Gujr" typeface="Shruti"/> <a:font script="Khmr" typeface="DaunPenh"/> <a:font script="Knda" typeface="Tunga"/> <a:font script="Guru" typeface="Raavi"/> <a:font script="Cans" typeface="Euphemia"/> <a:font script="Cher" typeface="Plantagenet Cherokee"/> <a:font script="Yiii" typeface="Microsoft Yi Baiti"/> <a:font script="Tibt" typeface="Microsoft Himalaya"/> <a:font script="Thaa" typeface="MV Boli"/> <a:font script="Deva" typeface="Mangal"/> <a:font script="Telu" typeface="Gautami"/> <a:font script="Taml" typeface="Latha"/> <a:font script="Syrc" typeface="Estrangelo Edessa"/> <a:font script="Orya" typeface="Kalinga"/> <a:font script="Mlym" typeface="Kartika"/> <a:font script="Laoo" typeface="DokChampa"/> <a:font script="Sinh" typeface="Iskoola Pota"/> <a:font script="Mong" typeface="Mongolian Baiti"/> <a:font script="Viet" typeface="Arial"/> <a:font script="Uigh" typeface="Microsoft Uighur"/> <a:font script="Geor" typeface="Sylfaen"/> </a:minorFont> </a:fontScheme> <a:fmtScheme name="Office"> <a:fillStyleLst> <a:solidFill> <a:schemeClr val="phClr"/> </a:solidFill> <a:gradFill rotWithShape="1"> <a:gsLst> <a:gs pos="0"> <a:schemeClr val="phClr"> <a:tint val="50000"/> <a:satMod val="300000"/> </a:schemeClr> </a:gs> <a:gs pos="35000"> <a:schemeClr val="phClr"> <a:tint val="37000"/> <a:satMod val="300000"/> </a:schemeClr> </a:gs> <a:gs pos="100000"> <a:schemeClr val="phClr"> <a:tint val="15000"/> <a:satMod val="350000"/> </a:schemeClr> </a:gs> </a:gsLst> <a:lin ang="16200000" scaled="1"/> </a:gradFill> <a:gradFill rotWithShape="1"> <a:gsLst> <a:gs pos="0"> <a:schemeClr val="phClr"> <a:tint val="100000"/> <a:shade val="100000"/> <a:satMod val="130000"/> </a:schemeClr> </a:gs> <a:gs pos="100000"> <a:schemeClr val="phClr"> <a:tint val="50000"/> <a:shade val="100000"/> <a:satMod val="350000"/> </a:schemeClr> </a:gs> </a:gsLst> <a:lin ang="16200000" scaled="0"/> </a:gradFill> </a:fillStyleLst> <a:lnStyleLst> <a:ln w="9525" cap="flat" cmpd="sng" algn="ctr"> <a:solidFill> <a:schemeClr val="phClr"> <a:shade val="95000"/> <a:satMod val="105000"/> </a:schemeClr> </a:solidFill> <a:prstDash val="solid"/> </a:ln> <a:ln w="25400" cap="flat" cmpd="sng" algn="ctr"> <a:solidFill> <a:schemeClr val="phClr"/> </a:solidFill> <a:prstDash val="solid"/> </a:ln> <a:ln w="38100" cap="flat" cmpd="sng" algn="ctr"> <a:solidFill> <a:schemeClr val="phClr"/> </a:solidFill> <a:prstDash val="solid"/> </a:ln> </a:lnStyleLst> <a:effectStyleLst> <a:effectStyle> <a:effectLst> <a:outerShdw blurRad="40000" dist="20000" dir="5400000" rotWithShape="0"> <a:srgbClr val="000000"> <a:alpha val="38000"/> </a:srgbClr> </a:outerShdw> </a:effectLst> </a:effectStyle> <a:effectStyle> <a:effectLst> <a:outerShdw blurRad="40000" dist="23000" dir="5400000" rotWithShape="0"> <a:srgbClr val="000000"> <a:alpha val="35000"/> </a:srgbClr> </a:outerShdw> </a:effectLst> </a:effectStyle> <a:effectStyle> <a:effectLst> <a:outerShdw blurRad="40000" dist="23000" dir="5400000" rotWithShape="0"> <a:srgbClr val="000000"> <a:alpha val="35000"/> </a:srgbClr> </a:outerShdw> </a:effectLst> <a:scene3d> <a:camera prst="orthographicFront"> <a:rot lat="0" lon="0" rev="0"/> </a:camera> <a:lightRig rig="threePt" dir="t"> <a:rot lat="0" lon="0" rev="1200000"/> </a:lightRig> </a:scene3d> <a:sp3d> <a:bevelT w="63500" h="25400"/> </a:sp3d> </a:effectStyle> </a:effectStyleLst> <a:bgFillStyleLst> <a:solidFill> <a:schemeClr val="phClr"/> </a:solidFill> <a:gradFill rotWithShape="1"> <a:gsLst> <a:gs pos="0"> <a:schemeClr val="phClr"> <a:tint val="40000"/> <a:satMod val="350000"/> </a:schemeClr> </a:gs> <a:gs pos="40000"> <a:schemeClr val="phClr"> <a:tint val="45000"/> <a:shade val="99000"/> <a:satMod val="350000"/> </a:schemeClr> </a:gs> <a:gs pos="100000"> <a:schemeClr val="phClr"> <a:shade val="20000"/> <a:satMod val="255000"/> </a:schemeClr> </a:gs> </a:gsLst> <a:path path="circle"> <a:fillToRect l="50000" t="-80000" r="50000" b="180000"/> </a:path> </a:gradFill> <a:gradFill rotWithShape="1"> <a:gsLst> <a:gs pos="0"> <a:schemeClr val="phClr"> <a:tint val="80000"/> <a:satMod val="300000"/> </a:schemeClr> </a:gs> <a:gs pos="100000"> <a:schemeClr val="phClr"> <a:shade val="30000"/> <a:satMod val="200000"/> </a:schemeClr> </a:gs> </a:gsLst> <a:path path="circle"> <a:fillToRect l="50000" t="50000" r="50000" b="50000"/> </a:path> </a:gradFill> </a:bgFillStyleLst> </a:fmtScheme> </a:themeElements> <a:objectDefaults> <a:spDef> <a:spPr/> <a:bodyPr/> <a:lstStyle/> <a:style> <a:lnRef idx="1"> <a:schemeClr val="accent1"/> </a:lnRef> <a:fillRef idx="3"> <a:schemeClr val="accent1"/> </a:fillRef> <a:effectRef idx="2"> <a:schemeClr val="accent1"/> </a:effectRef> <a:fontRef idx="minor"> <a:schemeClr val="lt1"/> </a:fontRef> </a:style> </a:spDef> <a:lnDef> <a:spPr/> <a:bodyPr/> <a:lstStyle/> <a:style> <a:lnRef idx="2"> <a:schemeClr val="accent1"/> </a:lnRef> <a:fillRef idx="0"> <a:schemeClr val="accent1"/> </a:fillRef> <a:effectRef idx="1"> <a:schemeClr val="accent1"/> </a:effectRef> <a:fontRef idx="minor"> <a:schemeClr val="tx1"/> </a:fontRef> </a:style> </a:lnDef> </a:objectDefaults> <a:extraClrSchemeLst/> </a:theme>`},{}],146:[function(e,a,f){(function(c){(function(){Object.defineProperty(f,"__esModule",{value:!0}),f.CsvFormatterStream=void 0;const s=e("stream"),l=e("./formatter");class i extends s.Transform{constructor(o){super({writableObjectMode:o.objectMode}),this.hasWrittenBOM=!1,this.formatterOptions=o,this.rowFormatter=new l.RowFormatter(o),this.hasWrittenBOM=!o.writeBOM}transform(o){return this.rowFormatter.rowTransform=o,this}_transform(o,h,u){let d=!1;try{this.hasWrittenBOM||(this.push(this.formatterOptions.BOM),this.hasWrittenBOM=!0),this.rowFormatter.format(o,(m,b)=>m?(d=!0,u(m)):(b&&b.forEach(p=>{this.push(c.from(p,"utf8"))}),d=!0,u()))}catch(m){if(d)throw m;u(m)}}_flush(o){this.rowFormatter.finish((h,u)=>h?o(h):(u&&u.forEach(d=>{this.push(c.from(d,"utf8"))}),o()))}}f.CsvFormatterStream=i}).call(this)}).call(this,e("buffer").Buffer)},{"./formatter":150,buffer:220,stream:505}],147:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.FormatterOptions=void 0,f.FormatterOptions=class{constructor(){let c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};var s;this.objectMode=!0,this.delimiter=",",this.rowDelimiter=` `,this.quote='"',this.escape=this.quote,this.quoteColumns=!1,this.quoteHeaders=this.quoteColumns,this.headers=null,this.includeEndRowDelimiter=!1,this.writeBOM=!1,this.BOM="\uFEFF",this.alwaysWriteHeaders=!1,Object.assign(this,c||{}),c?.quoteHeaders===void 0&&(this.quoteHeaders=this.quoteColumns),c?.quote===!0?this.quote='"':c?.quote===!1&&(this.quote=""),typeof c?.escape!="string"&&(this.escape=this.quote),this.shouldWriteHeaders=!!this.headers&&((s=c.writeHeaders)===null||s===void 0||s),this.headers=Array.isArray(this.headers)?this.headers:null,this.escapedQuote=`${this.escape}${this.quote}`}}},{}],148:[function(e,a,f){var c=function(n){return n&&n.__esModule?n:{default:n}};Object.defineProperty(f,"__esModule",{value:!0}),f.FieldFormatter=void 0;const s=c(e("lodash.isboolean")),l=c(e("lodash.isnil")),i=c(e("lodash.escaperegexp"));f.FieldFormatter=class{constructor(n){this._headers=null,this.formatterOptions=n,n.headers!==null&&(this.headers=n.headers),this.REPLACE_REGEXP=new RegExp(n.quote,"g");const o=`[${n.delimiter}${i.default(n.rowDelimiter)}|\r| ]`;this.ESCAPE_REGEXP=new RegExp(o)}set headers(n){this._headers=n}shouldQuote(n,o){const h=o?this.formatterOptions.quoteHeaders:this.formatterOptions.quoteColumns;return s.default(h)?h:Array.isArray(h)?h[n]:this._headers!==null&&h[this._headers[n]]}format(n,o,h){const u=(""+(l.default(n)?"":n)).replace(/\0/g,""),{formatterOptions:d}=this;return d.quote!==""&&u.indexOf(d.quote)!==-1?this.quoteField(u.replace(this.REPLACE_REGEXP,d.escapedQuote)):u.search(this.ESCAPE_REGEXP)!==-1||this.shouldQuote(o,h)?this.quoteField(u):u}quoteField(n){const{quote:o}=this.formatterOptions;return`${o}${n}${o}`}}},{"lodash.escaperegexp":442,"lodash.isboolean":444,"lodash.isnil":447}],149:[function(e,a,f){var c=function(h){return h&&h.__esModule?h:{default:h}};Object.defineProperty(f,"__esModule",{value:!0}),f.RowFormatter=void 0;const s=c(e("lodash.isfunction")),l=c(e("lodash.isequal")),i=e("./FieldFormatter"),n=e("../types");class o{constructor(u){this.rowCount=0,this.formatterOptions=u,this.fieldFormatter=new i.FieldFormatter(u),this.headers=u.headers,this.shouldWriteHeaders=u.shouldWriteHeaders,this.hasWrittenHeaders=!1,this.headers!==null&&(this.fieldFormatter.headers=this.headers),u.transform&&(this.rowTransform=u.transform)}static isRowHashArray(u){return!!Array.isArray(u)&&Array.isArray(u[0])&&u[0].length===2}static isRowArray(u){return Array.isArray(u)&&!this.isRowHashArray(u)}static gatherHeaders(u){return o.isRowHashArray(u)?u.map(d=>d[0]):Array.isArray(u)?u:Object.keys(u)}static createTransform(u){return n.isSyncTransform(u)?(d,m)=>{let b=null;try{b=u(d)}catch(p){return m(p)}return m(null,b)}:(d,m)=>{u(d,m)}}set rowTransform(u){if(!s.default(u))throw new TypeError("The transform should be a function");this._rowTransform=o.createTransform(u)}format(u,d){this.callTransformer(u,(m,b)=>{if(m)return d(m);if(!u)return d(null);const p=[];if(b){const{shouldFormatColumns:v,headers:g}=this.checkHeaders(b);if(this.shouldWriteHeaders&&g&&!this.hasWrittenHeaders&&(p.push(this.formatColumns(g,!0)),this.hasWrittenHeaders=!0),v){const x=this.gatherColumns(b);p.push(this.formatColumns(x,!1))}}return d(null,p)})}finish(u){const d=[];if(this.formatterOptions.alwaysWriteHeaders&&this.rowCount===0){if(!this.headers)return u(new Error("`alwaysWriteHeaders` option is set to true but `headers` option not provided."));d.push(this.formatColumns(this.headers,!0))}return this.formatterOptions.includeEndRowDelimiter&&d.push(this.formatterOptions.rowDelimiter),u(null,d)}checkHeaders(u){if(this.headers)return{shouldFormatColumns:!0,headers:this.headers};const d=o.gatherHeaders(u);return this.headers=d,this.fieldFormatter.headers=d,this.shouldWriteHeaders?{shouldFormatColumns:!l.default(d,u),headers:d}:{shouldFormatColumns:!0,headers:null}}gatherColumns(u){if(this.headers===null)throw new Error("Headers is currently null");return Array.isArray(u)?o.isRowHashArray(u)?this.headers.map((d,m)=>{const b=u[m];return b?b[1]:""}):o.isRowArray(u)&&!this.shouldWriteHeaders?u:this.headers.map((d,m)=>u[m]):this.headers.map(d=>u[d])}callTransformer(u,d){return this._rowTransform?this._rowTransform(u,d):d(null,u)}formatColumns(u,d){const m=u.map((p,v)=>this.fieldFormatter.format(p,v,d)).join(this.formatterOptions.delimiter),{rowCount:b}=this;return this.rowCount+=1,b?[this.formatterOptions.rowDelimiter,m].join(""):m}}f.RowFormatter=o},{"../types":152,"./FieldFormatter":148,"lodash.isequal":445,"lodash.isfunction":446}],150:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.FieldFormatter=f.RowFormatter=void 0;var c=e("./RowFormatter");Object.defineProperty(f,"RowFormatter",{enumerable:!0,get:function(){return c.RowFormatter}});var s=e("./FieldFormatter");Object.defineProperty(f,"FieldFormatter",{enumerable:!0,get:function(){return s.FieldFormatter}})},{"./FieldFormatter":148,"./RowFormatter":149}],151:[function(e,a,f){(function(c){(function(){var s=Object.create?function(v,g,x,C){C===void 0&&(C=x),Object.defineProperty(v,C,{enumerable:!0,get:function(){return g[x]}})}:function(v,g,x,C){C===void 0&&(C=x),v[C]=g[x]},l=Object.create?function(v,g){Object.defineProperty(v,"default",{enumerable:!0,value:g})}:function(v,g){v.default=g},i=function(v){if(v&&v.__esModule)return v;var g={};if(v!=null)for(var x in v)x!=="default"&&Object.prototype.hasOwnProperty.call(v,x)&&s(g,v,x);return l(g,v),g},n=function(v,g){for(var x in v)x==="default"||Object.prototype.hasOwnProperty.call(g,x)||s(g,v,x)};Object.defineProperty(f,"__esModule",{value:!0}),f.writeToPath=f.writeToString=f.writeToBuffer=f.writeToStream=f.write=f.format=f.FormatterOptions=f.CsvFormatterStream=void 0;const o=e("util"),h=e("stream"),u=i(e("fs")),d=e("./FormatterOptions"),m=e("./CsvFormatterStream");n(e("./types"),f);var b=e("./CsvFormatterStream");Object.defineProperty(f,"CsvFormatterStream",{enumerable:!0,get:function(){return b.CsvFormatterStream}});var p=e("./FormatterOptions");Object.defineProperty(f,"FormatterOptions",{enumerable:!0,get:function(){return p.FormatterOptions}}),f.format=v=>new m.CsvFormatterStream(new d.FormatterOptions(v)),f.write=(v,g)=>{const x=f.format(g),C=o.promisify((T,R)=>{x.write(T,void 0,R)});return v.reduce((T,R)=>T.then(()=>C(R)),Promise.resolve()).then(()=>x.end()).catch(T=>{x.emit("error",T)}),x},f.writeToStream=(v,g,x)=>f.write(g,x).pipe(v),f.writeToBuffer=function(v){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const x=[],C=new h.Writable({write(T,R,B){x.push(T),B()}});return new Promise((T,R)=>{C.on("error",R).on("finish",()=>T(c.concat(x))),f.write(v,g).pipe(C)})},f.writeToString=(v,g)=>f.writeToBuffer(v,g).then(x=>x.toString()),f.writeToPath=(v,g,x)=>{const C=u.createWriteStream(v,{encoding:"utf8"});return f.write(g,x).pipe(C)}}).call(this)}).call(this,e("buffer").Buffer)},{"./CsvFormatterStream":146,"./FormatterOptions":147,"./types":152,buffer:220,fs:216,stream:505,util:527}],152:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.isSyncTransform=void 0,f.isSyncTransform=c=>c.length===1},{}],153:[function(e,a,f){(function(c){(function(){Object.defineProperty(f,"__esModule",{value:!0}),f.CsvParserStream=void 0;const s=e("string_decoder"),l=e("stream"),i=e("./transforms"),n=e("./parser");class o extends l.Transform{constructor(u){super({objectMode:u.objectMode}),this.lines="",this.rowCount=0,this.parsedRowCount=0,this.parsedLineCount=0,this.endEmitted=!1,this.headersEmitted=!1,this.parserOptions=u,this.parser=new n.Parser(u),this.headerTransformer=new i.HeaderTransformer(u),this.decoder=new s.StringDecoder(u.encoding),this.rowTransformerValidator=new i.RowTransformerValidator}get hasHitRowLimit(){return this.parserOptions.limitRows&&this.rowCount>=this.parserOptions.maxRows}get shouldEmitRows(){return this.parsedRowCount>this.parserOptions.skipRows}get shouldSkipLine(){return this.parsedLineCount<=this.parserOptions.skipLines}transform(u){return this.rowTransformerValidator.rowTransform=u,this}validate(u){return this.rowTransformerValidator.rowValidator=u,this}emit(u){if(u==="end")return this.endEmitted||(this.endEmitted=!0,super.emit("end",this.rowCount)),!1;for(var d=arguments.length,m=new Array(d>1?d-1:0),b=1;b<d;b++)m[b-1]=arguments[b];return super.emit(u,...m)}_transform(u,d,m){if(this.hasHitRowLimit)return m();const b=o.wrapDoneCallback(m);try{const{lines:p}=this,v=p+this.decoder.write(u),g=this.parse(v,!0);return this.processRows(g,b)}catch(p){return b(p)}}_flush(u){const d=o.wrapDoneCallback(u);if(this.hasHitRowLimit)return d();try{const m=this.lines+this.decoder.end(),b=this.parse(m,!1);return this.processRows(b,d)}catch(m){return d(m)}}parse(u,d){if(!u)return[];const{line:m,rows:b}=this.parser.parse(u,d);return this.lines=m,b}processRows(u,d){const m=u.length,b=p=>{const v=C=>C?d(C):p%100!=0?b(p+1):void c(()=>b(p+1));if(this.checkAndEmitHeaders(),p>=m||this.hasHitRowLimit)return d();if(this.parsedLineCount+=1,this.shouldSkipLine)return v();const g=u[p];this.rowCount+=1,this.parsedRowCount+=1;const x=this.rowCount;return this.transformRow(g,(C,T)=>{if(C)return this.rowCount-=1,v(C);if(!T)return v(new Error("expected transform result"));if(T.isValid){if(T.row)return this.pushRow(T.row,v)}else this.emit("data-invalid",T.row,x,T.reason);return v()})};b(0)}transformRow(u,d){try{this.headerTransformer.transform(u,(m,b)=>m?d(m):b?b.isValid?b.row?this.shouldEmitRows?this.rowTransformerValidator.transformAndValidate(b.row,d):this.skipRow(d):(this.rowCount-=1,this.parsedRowCount-=1,d(null,{row:null,isValid:!0})):this.shouldEmitRows?d(null,{isValid:!1,row:u}):this.skipRow(d):d(new Error("Expected result from header transform")))}catch(m){d(m)}}checkAndEmitHeaders(){!this.headersEmitted&&this.headerTransformer.headers&&(this.headersEmitted=!0,this.emit("headers",this.headerTransformer.headers))}skipRow(u){return this.rowCount-=1,u(null,{row:null,isValid:!0})}pushRow(u,d){try{this.parserOptions.objectMode?this.push(u):this.push(JSON.stringify(u)),d()}catch(m){d(m)}}static wrapDoneCallback(u){let d=!1;return function(m){if(m){if(d)throw m;return d=!0,void u(m)}for(var b=arguments.length,p=new Array(b>1?b-1:0),v=1;v<b;v++)p[v-1]=arguments[v];u(...p)}}}f.CsvParserStream=o}).call(this)}).call(this,e("timers").setImmediate)},{"./parser":165,"./transforms":168,stream:505,string_decoder:218,timers:523}],154:[function(e,a,f){var c=function(i){return i&&i.__esModule?i:{default:i}};Object.defineProperty(f,"__esModule",{value:!0}),f.ParserOptions=void 0;const s=c(e("lodash.escaperegexp")),l=c(e("lodash.isnil"));f.ParserOptions=class{constructor(i){var n;if(this.objectMode=!0,this.delimiter=",",this.ignoreEmpty=!1,this.quote='"',this.escape=null,this.escapeChar=this.quote,this.comment=null,this.supportsComments=!1,this.ltrim=!1,this.rtrim=!1,this.trim=!1,this.headers=null,this.renameHeaders=!1,this.strictColumnHandling=!1,this.discardUnmappedColumns=!1,this.carriageReturn="\r",this.encoding="utf8",this.limitRows=!1,this.maxRows=0,this.skipLines=0,this.skipRows=0,Object.assign(this,i||{}),this.delimiter.length>1)throw new Error("delimiter option must be one character long");this.escapedDelimiter=s.default(this.delimiter),this.escapeChar=(n=this.escape)!==null&&n!==void 0?n:this.quote,this.supportsComments=!l.default(this.comment),this.NEXT_TOKEN_REGEXP=new RegExp(`([^\\s]|\\r\\n|\\n|\\r|${this.escapedDelimiter})`),this.maxRows>0&&(this.limitRows=!0)}}},{"lodash.escaperegexp":442,"lodash.isnil":447}],155:[function(e,a,f){var c=Object.create?function(b,p,v,g){g===void 0&&(g=v),Object.defineProperty(b,g,{enumerable:!0,get:function(){return p[v]}})}:function(b,p,v,g){g===void 0&&(g=v),b[g]=p[v]},s=Object.create?function(b,p){Object.defineProperty(b,"default",{enumerable:!0,value:p})}:function(b,p){b.default=p},l=function(b){if(b&&b.__esModule)return b;var p={};if(b!=null)for(var v in b)v!=="default"&&Object.prototype.hasOwnProperty.call(b,v)&&c(p,b,v);return s(p,b),p},i=function(b,p){for(var v in b)v==="default"||Object.prototype.hasOwnProperty.call(p,v)||c(p,b,v)};Object.defineProperty(f,"__esModule",{value:!0}),f.parseString=f.parseFile=f.parseStream=f.parse=f.ParserOptions=f.CsvParserStream=void 0;const n=l(e("fs")),o=e("stream"),h=e("./ParserOptions"),u=e("./CsvParserStream");i(e("./types"),f);var d=e("./CsvParserStream");Object.defineProperty(f,"CsvParserStream",{enumerable:!0,get:function(){return d.CsvParserStream}});var m=e("./ParserOptions");Object.defineProperty(f,"ParserOptions",{enumerable:!0,get:function(){return m.ParserOptions}}),f.parse=b=>new u.CsvParserStream(new h.ParserOptions(b)),f.parseStream=(b,p)=>b.pipe(new u.CsvParserStream(new h.ParserOptions(p))),f.parseFile=function(b){let p=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return n.createReadStream(b).pipe(new u.CsvParserStream(new h.ParserOptions(p)))},f.parseString=(b,p)=>{const v=new o.Readable;return v.push(b),v.push(null),v.pipe(new u.CsvParserStream(new h.ParserOptions(p)))}},{"./CsvParserStream":153,"./ParserOptions":154,"./types":169,fs:216,stream:505}],156:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.Parser=void 0;const c=e("./Scanner"),s=e("./RowParser"),l=e("./Token");class i{constructor(o){this.parserOptions=o,this.rowParser=new s.RowParser(this.parserOptions)}static removeBOM(o){return o&&o.charCodeAt(0)===65279?o.slice(1):o}parse(o,h){const u=new c.Scanner({line:i.removeBOM(o),parserOptions:this.parserOptions,hasMoreData:h});return this.parserOptions.supportsComments?this.parseWithComments(u):this.parseWithoutComments(u)}parseWithoutComments(o){const h=[];let u=!0;for(;u;)u=this.parseRow(o,h);return{line:o.line,rows:h}}parseWithComments(o){const{parserOptions:h}=this,u=[];for(let d=o.nextCharacterToken;d!==null;d=o.nextCharacterToken)if(l.Token.isTokenComment(d,h)){if(o.advancePastLine()===null)return{line:o.lineFromCursor,rows:u};if(!o.hasMoreCharacters)return{line:o.lineFromCursor,rows:u};o.truncateToCursor()}else if(!this.parseRow(o,u))break;return{line:o.line,rows:u}}parseRow(o,h){if(!o.nextNonSpaceToken)return!1;const u=this.rowParser.parse(o);return u!==null&&(this.parserOptions.ignoreEmpty&&s.RowParser.isEmptyRow(u)||h.push(u),!0)}}f.Parser=i},{"./RowParser":157,"./Scanner":158,"./Token":159}],157:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.RowParser=void 0;const c=e("./column"),s=e("./Token");f.RowParser=class{constructor(l){this.parserOptions=l,this.columnParser=new c.ColumnParser(l)}static isEmptyRow(l){return l.join("").replace(/\s+/g,"")===""}parse(l){const{parserOptions:i}=this,{hasMoreData:n}=l,o=l,h=[];let u=this.getStartToken(o,h);for(;u;){if(s.Token.isTokenRowDelimiter(u))return o.advancePastToken(u),!o.hasMoreCharacters&&s.Token.isTokenCarriageReturn(u,i)&&n?null:(o.truncateToCursor(),h);if(!this.shouldSkipColumnParse(o,u,h)){const d=this.columnParser.parse(o);if(d===null)return null;h.push(d)}u=o.nextNonSpaceToken}return n?null:(o.truncateToCursor(),h)}getStartToken(l,i){const n=l.nextNonSpaceToken;return n!==null&&s.Token.isTokenDelimiter(n,this.parserOptions)?(i.push(""),l.nextNonSpaceToken):n}shouldSkipColumnParse(l,i,n){const{parserOptions:o}=this;if(s.Token.isTokenDelimiter(i,o)){l.advancePastToken(i);const h=l.nextCharacterToken;if(!l.hasMoreCharacters||h!==null&&s.Token.isTokenRowDelimiter(h)||h!==null&&s.Token.isTokenDelimiter(h,o))return n.push(""),!0}return!1}}},{"./Token":159,"./column":164}],158:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.Scanner=void 0;const c=e("./Token"),s=/((?:\r\n)|\n|\r)/;f.Scanner=class{constructor(l){this.cursor=0,this.line=l.line,this.lineLength=this.line.length,this.parserOptions=l.parserOptions,this.hasMoreData=l.hasMoreData,this.cursor=l.cursor||0}get hasMoreCharacters(){return this.lineLength>this.cursor}get nextNonSpaceToken(){const{lineFromCursor:l}=this,i=this.parserOptions.NEXT_TOKEN_REGEXP;if(l.search(i)===-1)return null;const n=i.exec(l);if(n==null)return null;const o=n[1],h=this.cursor+(n.index||0);return new c.Token({token:o,startCursor:h,endCursor:h+o.length-1})}get nextCharacterToken(){const{cursor:l,lineLength:i}=this;return i<=l?null:new c.Token({token:this.line[l],startCursor:l,endCursor:l})}get lineFromCursor(){return this.line.substr(this.cursor)}advancePastLine(){const l=s.exec(this.lineFromCursor);return l?(this.cursor+=(l.index||0)+l[0].length,this):this.hasMoreData?null:(this.cursor=this.lineLength,this)}advanceTo(l){return this.cursor=l,this}advanceToToken(l){return this.cursor=l.startCursor,this}advancePastToken(l){return this.cursor=l.endCursor+1,this}truncateToCursor(){return this.line=this.lineFromCursor,this.lineLength=this.line.length,this.cursor=0,this}}},{"./Token":159}],159:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.Token=void 0,f.Token=class{constructor(c){this.token=c.token,this.startCursor=c.startCursor,this.endCursor=c.endCursor}static isTokenRowDelimiter(c){const s=c.token;return s==="\r"||s===` `||s===`\r `}static isTokenCarriageReturn(c,s){return c.token===s.carriageReturn}static isTokenComment(c,s){return s.supportsComments&&!!c&&c.token===s.comment}static isTokenEscapeCharacter(c,s){return c.token===s.escapeChar}static isTokenQuote(c,s){return c.token===s.quote}static isTokenDelimiter(c,s){return c.token===s.delimiter}}},{}],160:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.ColumnFormatter=void 0,f.ColumnFormatter=class{constructor(c){c.trim?this.format=s=>s.trim():c.ltrim?this.format=s=>s.trimLeft():c.rtrim?this.format=s=>s.trimRight():this.format=s=>s}}},{}],161:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.ColumnParser=void 0;const c=e("./NonQuotedColumnParser"),s=e("./QuotedColumnParser"),l=e("../Token");f.ColumnParser=class{constructor(i){this.parserOptions=i,this.quotedColumnParser=new s.QuotedColumnParser(i),this.nonQuotedColumnParser=new c.NonQuotedColumnParser(i)}parse(i){const{nextNonSpaceToken:n}=i;return n!==null&&l.Token.isTokenQuote(n,this.parserOptions)?(i.advanceToToken(n),this.quotedColumnParser.parse(i)):this.nonQuotedColumnParser.parse(i)}}},{"../Token":159,"./NonQuotedColumnParser":162,"./QuotedColumnParser":163}],162:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.NonQuotedColumnParser=void 0;const c=e("./ColumnFormatter"),s=e("../Token");f.NonQuotedColumnParser=class{constructor(l){this.parserOptions=l,this.columnFormatter=new c.ColumnFormatter(l)}parse(l){if(!l.hasMoreCharacters)return null;const{parserOptions:i}=this,n=[];let o=l.nextCharacterToken;for(;o&&!s.Token.isTokenDelimiter(o,i)&&!s.Token.isTokenRowDelimiter(o);o=l.nextCharacterToken)n.push(o.token),l.advancePastToken(o);return this.columnFormatter.format(n.join(""))}}},{"../Token":159,"./ColumnFormatter":160}],163:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.QuotedColumnParser=void 0;const c=e("./ColumnFormatter"),s=e("../Token");f.QuotedColumnParser=class{constructor(l){this.parserOptions=l,this.columnFormatter=new c.ColumnFormatter(l)}parse(l){if(!l.hasMoreCharacters)return null;const i=l.cursor,{foundClosingQuote:n,col:o}=this.gatherDataBetweenQuotes(l);if(!n){if(l.advanceTo(i),!l.hasMoreData)throw new Error(`Parse Error: missing closing: '${this.parserOptions.quote||""}' in line: at '${l.lineFromCursor.replace(/[\r\n]/g,"\\n'")}'`);return null}return this.checkForMalformedColumn(l),o}gatherDataBetweenQuotes(l){const{parserOptions:i}=this;let n=!1,o=!1;const h=[];let u=l.nextCharacterToken;for(;!o&&u!==null;u=l.nextCharacterToken){const d=s.Token.isTokenQuote(u,i);if(!n&&d)n=!0;else if(n)if(s.Token.isTokenEscapeCharacter(u,i)){l.advancePastToken(u);const m=l.nextCharacterToken;m!==null&&(s.Token.isTokenQuote(m,i)||s.Token.isTokenEscapeCharacter(m,i))?(h.push(m.token),u=m):d?o=!0:h.push(u.token)}else d?o=!0:h.push(u.token);l.advancePastToken(u)}return{col:this.columnFormatter.format(h.join("")),foundClosingQuote:o}}checkForMalformedColumn(l){const{parserOptions:i}=this,{nextNonSpaceToken:n}=l;if(n){const o=s.Token.isTokenDelimiter(n,i),h=s.Token.isTokenRowDelimiter(n);if(!o&&!h){const u=l.lineFromCursor.substr(0,10).replace(/[\r\n]/g,"\\n'");throw new Error(`Parse Error: expected: '${i.escapedDelimiter}' OR new line got: '${n.token}'. at '${u}`)}l.advanceToToken(n)}else l.hasMoreData||l.advancePastLine()}}},{"../Token":159,"./ColumnFormatter":160}],164:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.ColumnFormatter=f.QuotedColumnParser=f.NonQuotedColumnParser=f.ColumnParser=void 0;var c=e("./ColumnParser");Object.defineProperty(f,"ColumnParser",{enumerable:!0,get:function(){return c.ColumnParser}});var s=e("./NonQuotedColumnParser");Object.defineProperty(f,"NonQuotedColumnParser",{enumerable:!0,get:function(){return s.NonQuotedColumnParser}});var l=e("./QuotedColumnParser");Object.defineProperty(f,"QuotedColumnParser",{enumerable:!0,get:function(){return l.QuotedColumnParser}});var i=e("./ColumnFormatter");Object.defineProperty(f,"ColumnFormatter",{enumerable:!0,get:function(){return i.ColumnFormatter}})},{"./ColumnFormatter":160,"./ColumnParser":161,"./NonQuotedColumnParser":162,"./QuotedColumnParser":163}],165:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.QuotedColumnParser=f.NonQuotedColumnParser=f.ColumnParser=f.Token=f.Scanner=f.RowParser=f.Parser=void 0;var c=e("./Parser");Object.defineProperty(f,"Parser",{enumerable:!0,get:function(){return c.Parser}});var s=e("./RowParser");Object.defineProperty(f,"RowParser",{enumerable:!0,get:function(){return s.RowParser}});var l=e("./Scanner");Object.defineProperty(f,"Scanner",{enumerable:!0,get:function(){return l.Scanner}});var i=e("./Token");Object.defineProperty(f,"Token",{enumerable:!0,get:function(){return i.Token}});var n=e("./column");Object.defineProperty(f,"ColumnParser",{enumerable:!0,get:function(){return n.ColumnParser}}),Object.defineProperty(f,"NonQuotedColumnParser",{enumerable:!0,get:function(){return n.NonQuotedColumnParser}}),Object.defineProperty(f,"QuotedColumnParser",{enumerable:!0,get:function(){return n.QuotedColumnParser}})},{"./Parser":156,"./RowParser":157,"./Scanner":158,"./Token":159,"./column":164}],166:[function(e,a,f){var c=function(o){return o&&o.__esModule?o:{default:o}};Object.defineProperty(f,"__esModule",{value:!0}),f.HeaderTransformer=void 0;const s=c(e("lodash.isundefined")),l=c(e("lodash.isfunction")),i=c(e("lodash.uniq")),n=c(e("lodash.groupby"));f.HeaderTransformer=class{constructor(o){this.headers=null,this.receivedHeaders=!1,this.shouldUseFirstRow=!1,this.processedFirstRow=!1,this.headersLength=0,this.parserOptions=o,o.headers===!0?this.shouldUseFirstRow=!0:Array.isArray(o.headers)?this.setHeaders(o.headers):l.default(o.headers)&&(this.headersTransform=o.headers)}transform(o,h){return this.shouldMapRow(o)?h(null,this.processRow(o)):h(null,{row:null,isValid:!0})}shouldMapRow(o){const{parserOptions:h}=this;if(!this.headersTransform&&h.renameHeaders&&!this.processedFirstRow){if(!this.receivedHeaders)throw new Error("Error renaming headers: new headers must be provided in an array");return this.processedFirstRow=!0,!1}if(!this.receivedHeaders&&Array.isArray(o)){if(this.headersTransform)this.setHeaders(this.headersTransform(o));else{if(!this.shouldUseFirstRow)return!0;this.setHeaders(o)}return!1}return!0}processRow(o){if(!this.headers)return{row:o,isValid:!0};const{parserOptions:h}=this;if(!h.discardUnmappedColumns&&o.length>this.headersLength){if(!h.strictColumnHandling)throw new Error(`Unexpected Error: column header mismatch expected: ${this.headersLength} columns got: ${o.length}`);return{row:o,isValid:!1,reason:`Column header mismatch expected: ${this.headersLength} columns got: ${o.length}`}}return h.strictColumnHandling&&o.length<this.headersLength?{row:o,isValid:!1,reason:`Column header mismatch expected: ${this.headersLength} columns got: ${o.length}`}:{row:this.mapHeaders(o),isValid:!0}}mapHeaders(o){const h={},{headers:u,headersLength:d}=this;for(let m=0;m<d;m+=1){const b=u[m];if(!s.default(b)){const p=o[m];s.default(p)?h[b]="":h[b]=p}}return h}setHeaders(o){var h;const u=o.filter(d=>!!d);if(i.default(u).length!==u.length){const d=n.default(u),m=Object.keys(d).filter(b=>d[b].length>1);throw new Error("Duplicate headers found "+JSON.stringify(m))}this.headers=o,this.receivedHeaders=!0,this.headersLength=((h=this.headers)===null||h===void 0?void 0:h.length)||0}}},{"lodash.groupby":443,"lodash.isfunction":446,"lodash.isundefined":448,"lodash.uniq":449}],167:[function(e,a,f){var c=function(n){return n&&n.__esModule?n:{default:n}};Object.defineProperty(f,"__esModule",{value:!0}),f.RowTransformerValidator=void 0;const s=c(e("lodash.isfunction")),l=e("../types");class i{constructor(){this._rowTransform=null,this._rowValidator=null}static createTransform(o){return l.isSyncTransform(o)?(h,u)=>{let d=null;try{d=o(h)}catch(m){return u(m)}return u(null,d)}:o}static createValidator(o){return l.isSyncValidate(o)?(h,u)=>{u(null,{row:h,isValid:o(h)})}:(h,u)=>{o(h,(d,m,b)=>d?u(d):u(null,m?{row:h,isValid:m,reason:b}:{row:h,isValid:!1,reason:b}))}}set rowTransform(o){if(!s.default(o))throw new TypeError("The transform should be a function");this._rowTransform=i.createTransform(o)}set rowValidator(o){if(!s.default(o))throw new TypeError("The validate should be a function");this._rowValidator=i.createValidator(o)}transformAndValidate(o,h){return this.callTransformer(o,(u,d)=>u?h(u):d?this.callValidator(d,(m,b)=>m?h(m):b&&!b.isValid?h(null,{row:d,isValid:!1,reason:b.reason}):h(null,{row:d,isValid:!0})):h(null,{row:null,isValid:!0}))}callTransformer(o,h){return this._rowTransform?this._rowTransform(o,h):h(null,o)}callValidator(o,h){return this._rowValidator?this._rowValidator(o,h):h(null,{row:o,isValid:!0})}}f.RowTransformerValidator=i},{"../types":169,"lodash.isfunction":446}],168:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.HeaderTransformer=f.RowTransformerValidator=void 0;var c=e("./RowTransformerValidator");Object.defineProperty(f,"RowTransformerValidator",{enumerable:!0,get:function(){return c.RowTransformerValidator}});var s=e("./HeaderTransformer");Object.defineProperty(f,"HeaderTransformer",{enumerable:!0,get:function(){return s.HeaderTransformer}})},{"./HeaderTransformer":166,"./RowTransformerValidator":167}],169:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.isSyncValidate=f.isSyncTransform=void 0,f.isSyncTransform=c=>c.length===1,f.isSyncValidate=c=>c.length===1},{}],170:[function(e,a,f){const c=f;c.bignum=e("bn.js"),c.define=e("./asn1/api").define,c.base=e("./asn1/base"),c.constants=e("./asn1/constants"),c.decoders=e("./asn1/decoders"),c.encoders=e("./asn1/encoders")},{"./asn1/api":171,"./asn1/base":173,"./asn1/constants":177,"./asn1/decoders":179,"./asn1/encoders":182,"bn.js":184}],171:[function(e,a,f){const c=e("./encoders"),s=e("./decoders"),l=e("inherits");function i(n,o){this.name=n,this.body=o,this.decoders={},this.encoders={}}f.define=function(n,o){return new i(n,o)},i.prototype._createNamed=function(n){const o=this.name;function h(u){this._initNamed(u,o)}return l(h,n),h.prototype._initNamed=function(u,d){n.call(this,u,d)},new h(this)},i.prototype._getDecoder=function(n){return n=n||"der",this.decoders.hasOwnProperty(n)||(this.decoders[n]=this._createNamed(s[n])),this.decoders[n]},i.prototype.decode=function(n,o,h){return this._getDecoder(o).decode(n,h)},i.prototype._getEncoder=function(n){return n=n||"der",this.encoders.hasOwnProperty(n)||(this.encoders[n]=this._createNamed(c[n])),this.encoders[n]},i.prototype.encode=function(n,o,h){return this._getEncoder(o).encode(n,h)}},{"./decoders":179,"./encoders":182,inherits:440}],172:[function(e,a,f){const c=e("inherits"),s=e("../base/reporter").Reporter,l=e("safer-buffer").Buffer;function i(o,h){s.call(this,h),l.isBuffer(o)?(this.base=o,this.offset=0,this.length=o.length):this.error("Input not Buffer")}function n(o,h){if(Array.isArray(o))this.length=0,this.value=o.map(function(u){return n.isEncoderBuffer(u)||(u=new n(u,h)),this.length+=u.length,u},this);else if(typeof o=="number"){if(!(0<=o&&o<=255))return h.error("non-byte EncoderBuffer value");this.value=o,this.length=1}else if(typeof o=="string")this.value=o,this.length=l.byteLength(o);else{if(!l.isBuffer(o))return h.error("Unsupported type: "+typeof o);this.value=o,this.length=o.length}}c(i,s),f.DecoderBuffer=i,i.isDecoderBuffer=function(o){return o instanceof i?!0:typeof o=="object"&&l.isBuffer(o.base)&&o.constructor.name==="DecoderBuffer"&&typeof o.offset=="number"&&typeof o.length=="number"&&typeof o.save=="function"&&typeof o.restore=="function"&&typeof o.isEmpty=="function"&&typeof o.readUInt8=="function"&&typeof o.skip=="function"&&typeof o.raw=="function"},i.prototype.save=function(){return{offset:this.offset,reporter:s.prototype.save.call(this)}},i.prototype.restore=function(o){const h=new i(this.base);return h.offset=o.offset,h.length=this.offset,this.offset=o.offset,s.prototype.restore.call(this,o.reporter),h},i.prototype.isEmpty=function(){return this.offset===this.length},i.prototype.readUInt8=function(o){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(o||"DecoderBuffer overrun")},i.prototype.skip=function(o,h){if(!(this.offset+o<=this.length))return this.error(h||"DecoderBuffer overrun");const u=new i(this.base);return u._reporterState=this._reporterState,u.offset=this.offset,u.length=this.offset+o,this.offset+=o,u},i.prototype.raw=function(o){return this.base.slice(o?o.offset:this.offset,this.length)},f.EncoderBuffer=n,n.isEncoderBuffer=function(o){return o instanceof n?!0:typeof o=="object"&&o.constructor.name==="EncoderBuffer"&&typeof o.length=="number"&&typeof o.join=="function"},n.prototype.join=function(o,h){return o||(o=l.alloc(this.length)),h||(h=0),this.length===0||(Array.isArray(this.value)?this.value.forEach(function(u){u.join(o,h),h+=u.length}):(typeof this.value=="number"?o[h]=this.value:typeof this.value=="string"?o.write(this.value,h):l.isBuffer(this.value)&&this.value.copy(o,h),h+=this.length)),o}},{"../base/reporter":175,inherits:440,"safer-buffer":495}],173:[function(e,a,f){const c=f;c.Reporter=e("./reporter").Reporter,c.DecoderBuffer=e("./buffer").DecoderBuffer,c.EncoderBuffer=e("./buffer").EncoderBuffer,c.Node=e("./node")},{"./buffer":172,"./node":174,"./reporter":175}],174:[function(e,a,f){const c=e("../base/reporter").Reporter,s=e("../base/buffer").EncoderBuffer,l=e("../base/buffer").DecoderBuffer,i=e("minimalistic-assert"),n=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],o=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(n);function h(d,m,b){const p={};this._baseState=p,p.name=b,p.enc=d,p.parent=m||null,p.children=null,p.tag=null,p.args=null,p.reverseArgs=null,p.choice=null,p.optional=!1,p.any=!1,p.obj=!1,p.use=null,p.useDecoder=null,p.key=null,p.default=null,p.explicit=null,p.implicit=null,p.contains=null,p.parent||(p.children=[],this._wrap())}a.exports=h;const u=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];h.prototype.clone=function(){const d=this._baseState,m={};u.forEach(function(p){m[p]=d[p]});const b=new this.constructor(m.parent);return b._baseState=m,b},h.prototype._wrap=function(){const d=this._baseState;o.forEach(function(m){this[m]=function(){const b=new this.constructor(this);return d.children.push(b),b[m].apply(b,arguments)}},this)},h.prototype._init=function(d){const m=this._baseState;i(m.parent===null),d.call(this),m.children=m.children.filter(function(b){return b._baseState.parent===this},this),i.equal(m.children.length,1,"Root node can have only one child")},h.prototype._useArgs=function(d){const m=this._baseState,b=d.filter(function(p){return p instanceof this.constructor},this);d=d.filter(function(p){return!(p instanceof this.constructor)},this),b.length!==0&&(i(m.children===null),m.children=b,b.forEach(function(p){p._baseState.parent=this},this)),d.length!==0&&(i(m.args===null),m.args=d,m.reverseArgs=d.map(function(p){if(typeof p!="object"||p.constructor!==Object)return p;const v={};return Object.keys(p).forEach(function(g){g==(0|g)&&(g|=0);const x=p[g];v[x]=g}),v}))},["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"].forEach(function(d){h.prototype[d]=function(){const m=this._baseState;throw new Error(d+" not implemented for encoding: "+m.enc)}}),n.forEach(function(d){h.prototype[d]=function(){const m=this._baseState,b=Array.prototype.slice.call(arguments);return i(m.tag===null),m.tag=d,this._useArgs(b),this}}),h.prototype.use=function(d){i(d);const m=this._baseState;return i(m.use===null),m.use=d,this},h.prototype.optional=function(){return this._baseState.optional=!0,this},h.prototype.def=function(d){const m=this._baseState;return i(m.default===null),m.default=d,m.optional=!0,this},h.prototype.explicit=function(d){const m=this._baseState;return i(m.explicit===null&&m.implicit===null),m.explicit=d,this},h.prototype.implicit=function(d){const m=this._baseState;return i(m.explicit===null&&m.implicit===null),m.implicit=d,this},h.prototype.obj=function(){const d=this._baseState,m=Array.prototype.slice.call(arguments);return d.obj=!0,m.length!==0&&this._useArgs(m),this},h.prototype.key=function(d){const m=this._baseState;return i(m.key===null),m.key=d,this},h.prototype.any=function(){return this._baseState.any=!0,this},h.prototype.choice=function(d){const m=this._baseState;return i(m.choice===null),m.choice=d,this._useArgs(Object.keys(d).map(function(b){return d[b]})),this},h.prototype.contains=function(d){const m=this._baseState;return i(m.use===null),m.contains=d,this},h.prototype._decode=function(d,m){const b=this._baseState;if(b.parent===null)return d.wrapResult(b.children[0]._decode(d,m));let p,v=b.default,g=!0,x=null;if(b.key!==null&&(x=d.enterKey(b.key)),b.optional){let C=null;if(b.explicit!==null?C=b.explicit:b.implicit!==null?C=b.implicit:b.tag!==null&&(C=b.tag),C!==null||b.any){if(g=this._peekTag(d,C,b.any),d.isError(g))return g}else{const T=d.save();try{b.choice===null?this._decodeGeneric(b.tag,d,m):this._decodeChoice(d,m),g=!0}catch{g=!1}d.restore(T)}}if(b.obj&&g&&(p=d.enterObject()),g){if(b.explicit!==null){const T=this._decodeTag(d,b.explicit);if(d.isError(T))return T;d=T}const C=d.offset;if(b.use===null&&b.choice===null){let T;b.any&&(T=d.save());const R=this._decodeTag(d,b.implicit!==null?b.implicit:b.tag,b.any);if(d.isError(R))return R;b.any?v=d.raw(T):d=R}if(m&&m.track&&b.tag!==null&&m.track(d.path(),C,d.length,"tagged"),m&&m.track&&b.tag!==null&&m.track(d.path(),d.offset,d.length,"content"),b.any||(v=b.choice===null?this._decodeGeneric(b.tag,d,m):this._decodeChoice(d,m)),d.isError(v))return v;if(b.any||b.choice!==null||b.children===null||b.children.forEach(function(T){T._decode(d,m)}),b.contains&&(b.tag==="octstr"||b.tag==="bitstr")){const T=new l(v);v=this._getUse(b.contains,d._reporterState.obj)._decode(T,m)}}return b.obj&&g&&(v=d.leaveObject(p)),b.key===null||v===null&&g!==!0?x!==null&&d.exitKey(x):d.leaveKey(x,b.key,v),v},h.prototype._decodeGeneric=function(d,m,b){const p=this._baseState;return d==="seq"||d==="set"?null:d==="seqof"||d==="setof"?this._decodeList(m,d,p.args[0],b):/str$/.test(d)?this._decodeStr(m,d,b):d==="objid"&&p.args?this._decodeObjid(m,p.args[0],p.args[1],b):d==="objid"?this._decodeObjid(m,null,null,b):d==="gentime"||d==="utctime"?this._decodeTime(m,d,b):d==="null_"?this._decodeNull(m,b):d==="bool"?this._decodeBool(m,b):d==="objDesc"?this._decodeStr(m,d,b):d==="int"||d==="enum"?this._decodeInt(m,p.args&&p.args[0],b):p.use!==null?this._getUse(p.use,m._reporterState.obj)._decode(m,b):m.error("unknown tag: "+d)},h.prototype._getUse=function(d,m){const b=this._baseState;return b.useDecoder=this._use(d,m),i(b.useDecoder._baseState.parent===null),b.useDecoder=b.useDecoder._baseState.children[0],b.implicit!==b.useDecoder._baseState.implicit&&(b.useDecoder=b.useDecoder.clone(),b.useDecoder._baseState.implicit=b.implicit),b.useDecoder},h.prototype._decodeChoice=function(d,m){const b=this._baseState;let p=null,v=!1;return Object.keys(b.choice).some(function(g){const x=d.save(),C=b.choice[g];try{const T=C._decode(d,m);if(d.isError(T))return!1;p={type:g,value:T},v=!0}catch{return d.restore(x),!1}return!0},this),v?p:d.error("Choice not matched")},h.prototype._createEncoderBuffer=function(d){return new s(d,this.reporter)},h.prototype._encode=function(d,m,b){const p=this._baseState;if(p.default!==null&&p.default===d)return;const v=this._encodeValue(d,m,b);return v===void 0||this._skipDefault(v,m,b)?void 0:v},h.prototype._encodeValue=function(d,m,b){const p=this._baseState;if(p.parent===null)return p.children[0]._encode(d,m||new c);let v=null;if(this.reporter=m,p.optional&&d===void 0){if(p.default===null)return;d=p.default}let g=null,x=!1;if(p.any)v=this._createEncoderBuffer(d);else if(p.choice)v=this._encodeChoice(d,m);else if(p.contains)g=this._getUse(p.contains,b)._encode(d,m),x=!0;else if(p.children)g=p.children.map(function(C){if(C._baseState.tag==="null_")return C._encode(null,m,d);if(C._baseState.key===null)return m.error("Child should have a key");const T=m.enterKey(C._baseState.key);if(typeof d!="object")return m.error("Child expected, but input is not object");const R=C._encode(d[C._baseState.key],m,d);return m.leaveKey(T),R},this).filter(function(C){return C}),g=this._createEncoderBuffer(g);else if(p.tag==="seqof"||p.tag==="setof"){if(!p.args||p.args.length!==1)return m.error("Too many args for : "+p.tag);if(!Array.isArray(d))return m.error("seqof/setof, but data is not Array");const C=this.clone();C._baseState.implicit=null,g=this._createEncoderBuffer(d.map(function(T){const R=this._baseState;return this._getUse(R.args[0],d)._encode(T,m)},C))}else p.use!==null?v=this._getUse(p.use,b)._encode(d,m):(g=this._encodePrimitive(p.tag,d),x=!0);if(!p.any&&p.choice===null){const C=p.implicit!==null?p.implicit:p.tag,T=p.implicit===null?"universal":"context";C===null?p.use===null&&m.error("Tag could be omitted only for .use()"):p.use===null&&(v=this._encodeComposite(C,x,T,g))}return p.explicit!==null&&(v=this._encodeComposite(p.explicit,!1,"context",v)),v},h.prototype._encodeChoice=function(d,m){const b=this._baseState,p=b.choice[d.type];return p||i(!1,d.type+" not found in "+JSON.stringify(Object.keys(b.choice))),p._encode(d.value,m)},h.prototype._encodePrimitive=function(d,m){const b=this._baseState;if(/str$/.test(d))return this._encodeStr(m,d);if(d==="objid"&&b.args)return this._encodeObjid(m,b.reverseArgs[0],b.args[1]);if(d==="objid")return this._encodeObjid(m,null,null);if(d==="gentime"||d==="utctime")return this._encodeTime(m,d);if(d==="null_")return this._encodeNull();if(d==="int"||d==="enum")return this._encodeInt(m,b.args&&b.reverseArgs[0]);if(d==="bool")return this._encodeBool(m);if(d==="objDesc")return this._encodeStr(m,d);throw new Error("Unsupported tag: "+d)},h.prototype._isNumstr=function(d){return/^[0-9 ]*$/.test(d)},h.prototype._isPrintstr=function(d){return/^[A-Za-z0-9 '()+,-./:=?]*$/.test(d)}},{"../base/buffer":172,"../base/reporter":175,"minimalistic-assert":453}],175:[function(e,a,f){const c=e("inherits");function s(i){this._reporterState={obj:null,path:[],options:i||{},errors:[]}}function l(i,n){this.path=i,this.rethrow(n)}f.Reporter=s,s.prototype.isError=function(i){return i instanceof l},s.prototype.save=function(){const i=this._reporterState;return{obj:i.obj,pathLen:i.path.length}},s.prototype.restore=function(i){const n=this._reporterState;n.obj=i.obj,n.path=n.path.slice(0,i.pathLen)},s.prototype.enterKey=function(i){return this._reporterState.path.push(i)},s.prototype.exitKey=function(i){const n=this._reporterState;n.path=n.path.slice(0,i-1)},s.prototype.leaveKey=function(i,n,o){const h=this._reporterState;this.exitKey(i),h.obj!==null&&(h.obj[n]=o)},s.prototype.path=function(){return this._reporterState.path.join("/")},s.prototype.enterObject=function(){const i=this._reporterState,n=i.obj;return i.obj={},n},s.prototype.leaveObject=function(i){const n=this._reporterState,o=n.obj;return n.obj=i,o},s.prototype.error=function(i){let n;const o=this._reporterState,h=i instanceof l;if(n=h?i:new l(o.path.map(function(u){return"["+JSON.stringify(u)+"]"}).join(""),i.message||i,i.stack),!o.options.partial)throw n;return h||o.errors.push(n),n},s.prototype.wrapResult=function(i){const n=this._reporterState;return n.options.partial?{result:this.isError(i)?null:i,errors:n.errors}:i},c(l,Error),l.prototype.rethrow=function(i){if(this.message=i+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,l),!this.stack)try{throw new Error(this.message)}catch(n){this.stack=n.stack}return this}},{inherits:440}],176:[function(e,a,f){function c(s){const l={};return Object.keys(s).forEach(function(i){(0|i)==i&&(i|=0);const n=s[i];l[n]=i}),l}f.tagClass={0:"universal",1:"application",2:"context",3:"private"},f.tagClassByName=c(f.tagClass),f.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},f.tagByName=c(f.tag)},{}],177:[function(e,a,f){const c=f;c._reverse=function(s){const l={};return Object.keys(s).forEach(function(i){(0|i)==i&&(i|=0);const n=s[i];l[n]=i}),l},c.der=e("./der")},{"./der":176}],178:[function(e,a,f){const c=e("inherits"),s=e("bn.js"),l=e("../base/buffer").DecoderBuffer,i=e("../base/node"),n=e("../constants/der");function o(m){this.enc="der",this.name=m.name,this.entity=m,this.tree=new h,this.tree._init(m.body)}function h(m){i.call(this,"der",m)}function u(m,b){let p=m.readUInt8(b);if(m.isError(p))return p;const v=n.tagClass[p>>6],g=(32&p)==0;if((31&p)==31){let x=p;for(p=0;(128&x)==128;){if(x=m.readUInt8(b),m.isError(x))return x;p<<=7,p|=127&x}}else p&=31;return{cls:v,primitive:g,tag:p,tagStr:n.tag[p]}}function d(m,b,p){let v=m.readUInt8(p);if(m.isError(v))return v;if(!b&&v===128)return null;if((128&v)==0)return v;const g=127&v;if(g>4)return m.error("length octect is too long");v=0;for(let x=0;x<g;x++){v<<=8;const C=m.readUInt8(p);if(m.isError(C))return C;v|=C}return v}a.exports=o,o.prototype.decode=function(m,b){return l.isDecoderBuffer(m)||(m=new l(m,b)),this.tree._decode(m,b)},c(h,i),h.prototype._peekTag=function(m,b,p){if(m.isEmpty())return!1;const v=m.save(),g=u(m,'Failed to peek tag: "'+b+'"');return m.isError(g)?g:(m.restore(v),g.tag===b||g.tagStr===b||g.tagStr+"of"===b||p)},h.prototype._decodeTag=function(m,b,p){const v=u(m,'Failed to decode tag of "'+b+'"');if(m.isError(v))return v;let g=d(m,v.primitive,'Failed to get length of "'+b+'"');if(m.isError(g))return g;if(!p&&v.tag!==b&&v.tagStr!==b&&v.tagStr+"of"!==b)return m.error('Failed to match tag: "'+b+'"');if(v.primitive||g!==null)return m.skip(g,'Failed to match body of: "'+b+'"');const x=m.save(),C=this._skipUntilEnd(m,'Failed to skip indefinite length body: "'+this.tag+'"');return m.isError(C)?C:(g=m.offset-x.offset,m.restore(x),m.skip(g,'Failed to match body of: "'+b+'"'))},h.prototype._skipUntilEnd=function(m,b){for(;;){const p=u(m,b);if(m.isError(p))return p;const v=d(m,p.primitive,b);if(m.isError(v))return v;let g;if(g=p.primitive||v!==null?m.skip(v):this._skipUntilEnd(m,b),m.isError(g))return g;if(p.tagStr==="end")break}},h.prototype._decodeList=function(m,b,p,v){const g=[];for(;!m.isEmpty();){const x=this._peekTag(m,"end");if(m.isError(x))return x;const C=p.decode(m,"der",v);if(m.isError(C)&&x)break;g.push(C)}return g},h.prototype._decodeStr=function(m,b){if(b==="bitstr"){const p=m.readUInt8();return m.isError(p)?p:{unused:p,data:m.raw()}}if(b==="bmpstr"){const p=m.raw();if(p.length%2==1)return m.error("Decoding of string type: bmpstr length mismatch");let v="";for(let g=0;g<p.length/2;g++)v+=String.fromCharCode(p.readUInt16BE(2*g));return v}if(b==="numstr"){const p=m.raw().toString("ascii");return this._isNumstr(p)?p:m.error("Decoding of string type: numstr unsupported characters")}if(b==="octstr"||b==="objDesc")return m.raw();if(b==="printstr"){const p=m.raw().toString("ascii");return this._isPrintstr(p)?p:m.error("Decoding of string type: printstr unsupported characters")}return/str$/.test(b)?m.raw().toString():m.error("Decoding of string type: "+b+" unsupported")},h.prototype._decodeObjid=function(m,b,p){let v;const g=[];let x=0,C=0;for(;!m.isEmpty();)C=m.readUInt8(),x<<=7,x|=127&C,(128&C)==0&&(g.push(x),x=0);128&C&&g.push(x);const T=g[0]/40|0,R=g[0]%40;if(v=p?g:[T,R].concat(g.slice(1)),b){let B=b[v.join(" ")];B===void 0&&(B=b[v.join(".")]),B!==void 0&&(v=B)}return v},h.prototype._decodeTime=function(m,b){const p=m.raw().toString();let v,g,x,C,T,R;if(b==="gentime")v=0|p.slice(0,4),g=0|p.slice(4,6),x=0|p.slice(6,8),C=0|p.slice(8,10),T=0|p.slice(10,12),R=0|p.slice(12,14);else{if(b!=="utctime")return m.error("Decoding "+b+" time is not supported yet");v=0|p.slice(0,2),g=0|p.slice(2,4),x=0|p.slice(4,6),C=0|p.slice(6,8),T=0|p.slice(8,10),R=0|p.slice(10,12),v=v<70?2e3+v:1900+v}return Date.UTC(v,g-1,x,C,T,R,0)},h.prototype._decodeNull=function(){return null},h.prototype._decodeBool=function(m){const b=m.readUInt8();return m.isError(b)?b:b!==0},h.prototype._decodeInt=function(m,b){const p=m.raw();let v=new s(p);return b&&(v=b[v.toString(10)]||v),v},h.prototype._use=function(m,b){return typeof m=="function"&&(m=m(b)),m._getDecoder("der").tree}},{"../base/buffer":172,"../base/node":174,"../constants/der":176,"bn.js":184,inherits:440}],179:[function(e,a,f){const c=f;c.der=e("./der"),c.pem=e("./pem")},{"./der":178,"./pem":180}],180:[function(e,a,f){const c=e("inherits"),s=e("safer-buffer").Buffer,l=e("./der");function i(n){l.call(this,n),this.enc="pem"}c(i,l),a.exports=i,i.prototype.decode=function(n,o){const h=n.toString().split(/[\r\n]+/g),u=o.label.toUpperCase(),d=/^-----(BEGIN|END) ([^-]+)-----$/;let m=-1,b=-1;for(let g=0;g<h.length;g++){const x=h[g].match(d);if(x!==null&&x[2]===u){if(m!==-1){if(x[1]!=="END")break;b=g;break}if(x[1]!=="BEGIN")break;m=g}}if(m===-1||b===-1)throw new Error("PEM section not found for: "+u);const p=h.slice(m+1,b).join("");p.replace(/[^a-z0-9+/=]+/gi,"");const v=s.from(p,"base64");return l.prototype.decode.call(this,v,o)}},{"./der":178,inherits:440,"safer-buffer":495}],181:[function(e,a,f){const c=e("inherits"),s=e("safer-buffer").Buffer,l=e("../base/node"),i=e("../constants/der");function n(u){this.enc="der",this.name=u.name,this.entity=u,this.tree=new o,this.tree._init(u.body)}function o(u){l.call(this,"der",u)}function h(u){return u<10?"0"+u:u}a.exports=n,n.prototype.encode=function(u,d){return this.tree._encode(u,d).join()},c(o,l),o.prototype._encodeComposite=function(u,d,m,b){const p=function(x,C,T,R){let B;if(x==="seqof"?x="seq":x==="setof"&&(x="set"),i.tagByName.hasOwnProperty(x))B=i.tagByName[x];else{if(typeof x!="number"||(0|x)!==x)return R.error("Unknown tag: "+x);B=x}return B>=31?R.error("Multi-octet tag encoding unsupported"):(C||(B|=32),B|=i.tagClassByName[T||"universal"]<<6,B)}(u,d,m,this.reporter);if(b.length<128){const x=s.alloc(2);return x[0]=p,x[1]=b.length,this._createEncoderBuffer([x,b])}let v=1;for(let x=b.length;x>=256;x>>=8)v++;const g=s.alloc(2+v);g[0]=p,g[1]=128|v;for(let x=1+v,C=b.length;C>0;x--,C>>=8)g[x]=255&C;return this._createEncoderBuffer([g,b])},o.prototype._encodeStr=function(u,d){if(d==="bitstr")return this._createEncoderBuffer([0|u.unused,u.data]);if(d==="bmpstr"){const m=s.alloc(2*u.length);for(let b=0;b<u.length;b++)m.writeUInt16BE(u.charCodeAt(b),2*b);return this._createEncoderBuffer(m)}return d==="numstr"?this._isNumstr(u)?this._createEncoderBuffer(u):this.reporter.error("Encoding of string type: numstr supports only digits and space"):d==="printstr"?this._isPrintstr(u)?this._createEncoderBuffer(u):this.reporter.error("Encoding of string type: printstr supports only latin upper and lower case letters, digits, space, apostrophe, left and rigth parenthesis, plus sign, comma, hyphen, dot, slash, colon, equal sign, question mark"):/str$/.test(d)||d==="objDesc"?this._createEncoderBuffer(u):this.reporter.error("Encoding of string type: "+d+" unsupported")},o.prototype._encodeObjid=function(u,d,m){if(typeof u=="string"){if(!d)return this.reporter.error("string objid given, but no values map found");if(!d.hasOwnProperty(u))return this.reporter.error("objid not found in values map");u=d[u].split(/[\s.]+/g);for(let g=0;g<u.length;g++)u[g]|=0}else if(Array.isArray(u)){u=u.slice();for(let g=0;g<u.length;g++)u[g]|=0}if(!Array.isArray(u))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(u));if(!m){if(u[1]>=40)return this.reporter.error("Second objid identifier OOB");u.splice(0,2,40*u[0]+u[1])}let b=0;for(let g=0;g<u.length;g++){let x=u[g];for(b++;x>=128;x>>=7)b++}const p=s.alloc(b);let v=p.length-1;for(let g=u.length-1;g>=0;g--){let x=u[g];for(p[v--]=127&x;(x>>=7)>0;)p[v--]=128|127&x}return this._createEncoderBuffer(p)},o.prototype._encodeTime=function(u,d){let m;const b=new Date(u);return d==="gentime"?m=[h(b.getUTCFullYear()),h(b.getUTCMonth()+1),h(b.getUTCDate()),h(b.getUTCHours()),h(b.getUTCMinutes()),h(b.getUTCSeconds()),"Z"].join(""):d==="utctime"?m=[h(b.getUTCFullYear()%100),h(b.getUTCMonth()+1),h(b.getUTCDate()),h(b.getUTCHours()),h(b.getUTCMinutes()),h(b.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+d+" time is not supported yet"),this._encodeStr(m,"octstr")},o.prototype._encodeNull=function(){return this._createEncoderBuffer("")},o.prototype._encodeInt=function(u,d){if(typeof u=="string"){if(!d)return this.reporter.error("String int or enum given, but no values map");if(!d.hasOwnProperty(u))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(u));u=d[u]}if(typeof u!="number"&&!s.isBuffer(u)){const p=u.toArray();!u.sign&&128&p[0]&&p.unshift(0),u=s.from(p)}if(s.isBuffer(u)){let p=u.length;u.length===0&&p++;const v=s.alloc(p);return u.copy(v),u.length===0&&(v[0]=0),this._createEncoderBuffer(v)}if(u<128)return this._createEncoderBuffer(u);if(u<256)return this._createEncoderBuffer([0,u]);let m=1;for(let p=u;p>=256;p>>=8)m++;const b=new Array(m);for(let p=b.length-1;p>=0;p--)b[p]=255&u,u>>=8;return 128&b[0]&&b.unshift(0),this._createEncoderBuffer(s.from(b))},o.prototype._encodeBool=function(u){return this._createEncoderBuffer(u?255:0)},o.prototype._use=function(u,d){return typeof u=="function"&&(u=u(d)),u._getEncoder("der").tree},o.prototype._skipDefault=function(u,d,m){const b=this._baseState;let p;if(b.default===null)return!1;const v=u.join();if(b.defaultBuffer===void 0&&(b.defaultBuffer=this._encodeValue(b.default,d,m).join()),v.length!==b.defaultBuffer.length)return!1;for(p=0;p<v.length;p++)if(v[p]!==b.defaultBuffer[p])return!1;return!0}},{"../base/node":174,"../constants/der":176,inherits:440,"safer-buffer":495}],182:[function(e,a,f){const c=f;c.der=e("./der"),c.pem=e("./pem")},{"./der":181,"./pem":183}],183:[function(e,a,f){const c=e("inherits"),s=e("./der");function l(i){s.call(this,i),this.enc="pem"}c(l,s),a.exports=l,l.prototype.encode=function(i,n){const o=s.prototype.encode.call(this,i).toString("base64"),h=["-----BEGIN "+n.label+"-----"];for(let u=0;u<o.length;u+=64)h.push(o.slice(u,u+64));return h.push("-----END "+n.label+"-----"),h.join(` `)}},{"./der":181,inherits:440}],184:[function(e,a,f){(function(c,s){function l(E,P){if(!E)throw new Error(P||"Assertion failed")}function i(E,P){E.super_=P;var k=function(){};k.prototype=P.prototype,E.prototype=new k,E.prototype.constructor=E}function n(E,P,k){if(n.isBN(E))return E;this.negative=0,this.words=null,this.length=0,this.red=null,E!==null&&(P!=="le"&&P!=="be"||(k=P,P=10),this._init(E||0,P||10,k||"be"))}var o;typeof c=="object"?c.exports=n:(void 0).BN=n,n.BN=n,n.wordSize=26;try{o=typeof window<"u"&&window.Buffer!==void 0?window.Buffer:e("buffer").Buffer}catch{}function h(E,P){var k=E.charCodeAt(P);return k>=65&&k<=70?k-55:k>=97&&k<=102?k-87:k-48&15}function u(E,P,k){var y=h(E,k);return k-1>=P&&(y|=h(E,k-1)<<4),y}function d(E,P,k,y){for(var w=0,_=Math.min(E.length,k),S=P;S<_;S++){var A=E.charCodeAt(S)-48;w*=y,w+=A>=49?A-49+10:A>=17?A-17+10:A}return w}n.isBN=function(E){return E instanceof n||E!==null&&typeof E=="object"&&E.constructor.wordSize===n.wordSize&&Array.isArray(E.words)},n.max=function(E,P){return E.cmp(P)>0?E:P},n.min=function(E,P){return E.cmp(P)<0?E:P},n.prototype._init=function(E,P,k){if(typeof E=="number")return this._initNumber(E,P,k);if(typeof E=="object")return this._initArray(E,P,k);P==="hex"&&(P=16),l(P===(0|P)&&P>=2&&P<=36);var y=0;(E=E.toString().replace(/\s+/g,""))[0]==="-"&&(y++,this.negative=1),y<E.length&&(P===16?this._parseHex(E,y,k):(this._parseBase(E,P,y),k==="le"&&this._initArray(this.toArray(),P,k)))},n.prototype._initNumber=function(E,P,k){E<0&&(this.negative=1,E=-E),E<67108864?(this.words=[67108863&E],this.length=1):E<4503599627370496?(this.words=[67108863&E,E/67108864&67108863],this.length=2):(l(E<9007199254740992),this.words=[67108863&E,E/67108864&67108863,1],this.length=3),k==="le"&&this._initArray(this.toArray(),P,k)},n.prototype._initArray=function(E,P,k){if(l(typeof E.length=="number"),E.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(E.length/3),this.words=new Array(this.length);for(var y=0;y<this.length;y++)this.words[y]=0;var w,_,S=0;if(k==="be")for(y=E.length-1,w=0;y>=0;y-=3)_=E[y]|E[y-1]<<8|E[y-2]<<16,this.words[w]|=_<<S&67108863,this.words[w+1]=_>>>26-S&67108863,(S+=24)>=26&&(S-=26,w++);else if(k==="le")for(y=0,w=0;y<E.length;y+=3)_=E[y]|E[y+1]<<8|E[y+2]<<16,this.words[w]|=_<<S&67108863,this.words[w+1]=_>>>26-S&67108863,(S+=24)>=26&&(S-=26,w++);return this.strip()},n.prototype._parseHex=function(E,P,k){this.length=Math.ceil((E.length-P)/6),this.words=new Array(this.length);for(var y=0;y<this.length;y++)this.words[y]=0;var w,_=0,S=0;if(k==="be")for(y=E.length-1;y>=P;y-=2)w=u(E,P,y)<<_,this.words[S]|=67108863&w,_>=18?(_-=18,S+=1,this.words[S]|=w>>>26):_+=8;else for(y=(E.length-P)%2==0?P+1:P;y<E.length;y+=2)w=u(E,P,y)<<_,this.words[S]|=67108863&w,_>=18?(_-=18,S+=1,this.words[S]|=w>>>26):_+=8;this.strip()},n.prototype._parseBase=function(E,P,k){this.words=[0],this.length=1;for(var y=0,w=1;w<=67108863;w*=P)y++;y--,w=w/P|0;for(var _=E.length-k,S=_%y,A=Math.min(_,_-S)+k,O=0,N=k;N<A;N+=y)O=d(E,N,N+y,P),this.imuln(w),this.words[0]+O<67108864?this.words[0]+=O:this._iaddn(O);if(S!==0){var U=1;for(O=d(E,N,E.length,P),N=0;N<S;N++)U*=P;this.imuln(U),this.words[0]+O<67108864?this.words[0]+=O:this._iaddn(O)}this.strip()},n.prototype.copy=function(E){E.words=new Array(this.length);for(var P=0;P<this.length;P++)E.words[P]=this.words[P];E.length=this.length,E.negative=this.negative,E.red=this.red},n.prototype.clone=function(){var E=new n(null);return this.copy(E),E},n.prototype._expand=function(E){for(;this.length<E;)this.words[this.length++]=0;return this},n.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},n.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},n.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var m=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],b=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],p=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function v(E,P,k){k.negative=P.negative^E.negative;var y=E.length+P.length|0;k.length=y,y=y-1|0;var w=0|E.words[0],_=0|P.words[0],S=w*_,A=67108863&S,O=S/67108864|0;k.words[0]=A;for(var N=1;N<y;N++){for(var U=O>>>26,H=67108863&O,Z=Math.min(N,P.length-1),D=Math.max(0,N-E.length+1);D<=Z;D++){var q=N-D|0;U+=(S=(w=0|E.words[q])*(_=0|P.words[D])+H)/67108864|0,H=67108863&S}k.words[N]=0|H,O=0|U}return O!==0?k.words[N]=0|O:k.length--,k.strip()}n.prototype.toString=function(E,P){var k;if(P=0|P||1,(E=E||10)===16||E==="hex"){k="";for(var y=0,w=0,_=0;_<this.length;_++){var S=this.words[_],A=(16777215&(S<<y|w)).toString(16);k=(w=S>>>24-y&16777215)!==0||_!==this.length-1?m[6-A.length]+A+k:A+k,(y+=2)>=26&&(y-=26,_--)}for(w!==0&&(k=w.toString(16)+k);k.length%P!=0;)k="0"+k;return this.negative!==0&&(k="-"+k),k}if(E===(0|E)&&E>=2&&E<=36){var O=b[E],N=p[E];k="";var U=this.clone();for(U.negative=0;!U.isZero();){var H=U.modn(N).toString(E);k=(U=U.idivn(N)).isZero()?H+k:m[O-H.length]+H+k}for(this.isZero()&&(k="0"+k);k.length%P!=0;)k="0"+k;return this.negative!==0&&(k="-"+k),k}l(!1,"Base should be between 2 and 36")},n.prototype.toNumber=function(){var E=this.words[0];return this.length===2?E+=67108864*this.words[1]:this.length===3&&this.words[2]===1?E+=4503599627370496+67108864*this.words[1]:this.length>2&&l(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-E:E},n.prototype.toJSON=function(){return this.toString(16)},n.prototype.toBuffer=function(E,P){return l(o!==void 0),this.toArrayLike(o,E,P)},n.prototype.toArray=function(E,P){return this.toArrayLike(Array,E,P)},n.prototype.toArrayLike=function(E,P,k){var y=this.byteLength(),w=k||Math.max(1,y);l(y<=w,"byte array longer than desired length"),l(w>0,"Requested array length <= 0"),this.strip();var _,S,A=P==="le",O=new E(w),N=this.clone();if(A){for(S=0;!N.isZero();S++)_=N.andln(255),N.iushrn(8),O[S]=_;for(;S<w;S++)O[S]=0}else{for(S=0;S<w-y;S++)O[S]=0;for(S=0;!N.isZero();S++)_=N.andln(255),N.iushrn(8),O[w-S-1]=_}return O},Math.clz32?n.prototype._countBits=function(E){return 32-Math.clz32(E)}:n.prototype._countBits=function(E){var P=E,k=0;return P>=4096&&(k+=13,P>>>=13),P>=64&&(k+=7,P>>>=7),P>=8&&(k+=4,P>>>=4),P>=2&&(k+=2,P>>>=2),k+P},n.prototype._zeroBits=function(E){if(E===0)return 26;var P=E,k=0;return(8191&P)==0&&(k+=13,P>>>=13),(127&P)==0&&(k+=7,P>>>=7),(15&P)==0&&(k+=4,P>>>=4),(3&P)==0&&(k+=2,P>>>=2),(1&P)==0&&k++,k},n.prototype.bitLength=function(){var E=this.words[this.length-1],P=this._countBits(E);return 26*(this.length-1)+P},n.prototype.zeroBits=function(){if(this.isZero())return 0;for(var E=0,P=0;P<this.length;P++){var k=this._zeroBits(this.words[P]);if(E+=k,k!==26)break}return E},n.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},n.prototype.toTwos=function(E){return this.negative!==0?this.abs().inotn(E).iaddn(1):this.clone()},n.prototype.fromTwos=function(E){return this.testn(E-1)?this.notn(E).iaddn(1).ineg():this.clone()},n.prototype.isNeg=function(){return this.negative!==0},n.prototype.neg=function(){return this.clone().ineg()},n.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},n.prototype.iuor=function(E){for(;this.length<E.length;)this.words[this.length++]=0;for(var P=0;P<E.length;P++)this.words[P]=this.words[P]|E.words[P];return this.strip()},n.prototype.ior=function(E){return l((this.negative|E.negative)==0),this.iuor(E)},n.prototype.or=function(E){return this.length>E.length?this.clone().ior(E):E.clone().ior(this)},n.prototype.uor=function(E){return this.length>E.length?this.clone().iuor(E):E.clone().iuor(this)},n.prototype.iuand=function(E){var P;P=this.length>E.length?E:this;for(var k=0;k<P.length;k++)this.words[k]=this.words[k]&E.words[k];return this.length=P.length,this.strip()},n.prototype.iand=function(E){return l((this.negative|E.negative)==0),this.iuand(E)},n.prototype.and=function(E){return this.length>E.length?this.clone().iand(E):E.clone().iand(this)},n.prototype.uand=function(E){return this.length>E.length?this.clone().iuand(E):E.clone().iuand(this)},n.prototype.iuxor=function(E){var P,k;this.length>E.length?(P=this,k=E):(P=E,k=this);for(var y=0;y<k.length;y++)this.words[y]=P.words[y]^k.words[y];if(this!==P)for(;y<P.length;y++)this.words[y]=P.words[y];return this.length=P.length,this.strip()},n.prototype.ixor=function(E){return l((this.negative|E.negative)==0),this.iuxor(E)},n.prototype.xor=function(E){return this.length>E.length?this.clone().ixor(E):E.clone().ixor(this)},n.prototype.uxor=function(E){return this.length>E.length?this.clone().iuxor(E):E.clone().iuxor(this)},n.prototype.inotn=function(E){l(typeof E=="number"&&E>=0);var P=0|Math.ceil(E/26),k=E%26;this._expand(P),k>0&&P--;for(var y=0;y<P;y++)this.words[y]=67108863&~this.words[y];return k>0&&(this.words[y]=~this.words[y]&67108863>>26-k),this.strip()},n.prototype.notn=function(E){return this.clone().inotn(E)},n.prototype.setn=function(E,P){l(typeof E=="number"&&E>=0);var k=E/26|0,y=E%26;return this._expand(k+1),this.words[k]=P?this.words[k]|1<<y:this.words[k]&~(1<<y),this.strip()},n.prototype.iadd=function(E){var P,k,y;if(this.negative!==0&&E.negative===0)return this.negative=0,P=this.isub(E),this.negative^=1,this._normSign();if(this.negative===0&&E.negative!==0)return E.negative=0,P=this.isub(E),E.negative=1,P._normSign();this.length>E.length?(k=this,y=E):(k=E,y=this);for(var w=0,_=0;_<y.length;_++)P=(0|k.words[_])+(0|y.words[_])+w,this.words[_]=67108863&P,w=P>>>26;for(;w!==0&&_<k.length;_++)P=(0|k.words[_])+w,this.words[_]=67108863&P,w=P>>>26;if(this.length=k.length,w!==0)this.words[this.length]=w,this.length++;else if(k!==this)for(;_<k.length;_++)this.words[_]=k.words[_];return this},n.prototype.add=function(E){var P;return E.negative!==0&&this.negative===0?(E.negative=0,P=this.sub(E),E.negative^=1,P):E.negative===0&&this.negative!==0?(this.negative=0,P=E.sub(this),this.negative=1,P):this.length>E.length?this.clone().iadd(E):E.clone().iadd(this)},n.prototype.isub=function(E){if(E.negative!==0){E.negative=0;var P=this.iadd(E);return E.negative=1,P._normSign()}if(this.negative!==0)return this.negative=0,this.iadd(E),this.negative=1,this._normSign();var k,y,w=this.cmp(E);if(w===0)return this.negative=0,this.length=1,this.words[0]=0,this;w>0?(k=this,y=E):(k=E,y=this);for(var _=0,S=0;S<y.length;S++)_=(P=(0|k.words[S])-(0|y.words[S])+_)>>26,this.words[S]=67108863&P;for(;_!==0&&S<k.length;S++)_=(P=(0|k.words[S])+_)>>26,this.words[S]=67108863&P;if(_===0&&S<k.length&&k!==this)for(;S<k.length;S++)this.words[S]=k.words[S];return this.length=Math.max(this.length,S),k!==this&&(this.negative=1),this.strip()},n.prototype.sub=function(E){return this.clone().isub(E)};var g=function(E,P,k){var y,w,_,S=E.words,A=P.words,O=k.words,N=0,U=0|S[0],H=8191&U,Z=U>>>13,D=0|S[1],q=8191&D,M=D>>>13,j=0|S[2],$=8191&j,K=j>>>13,J=0|S[3],X=8191&J,Q=J>>>13,ee=0|S[4],se=8191&ee,Y=ee>>>13,te=0|S[5],ne=8191&te,oe=te>>>13,ae=0|S[6],ce=8191&ae,me=ae>>>13,be=0|S[7],ye=8191&be,Me=be>>>13,Te=0|S[8],fe=8191&Te,ke=Te>>>13,Ee=0|S[9],Ne=8191&Ee,De=Ee>>>13,je=0|A[0],Ce=8191&je,Oe=je>>>13,Le=0|A[1],Be=8191&Le,ct=Le>>>13,wt=0|A[2],We=8191&wt,dt=wt>>>13,ut=0|A[3],qe=8191&ut,Ot=ut>>>13,bt=0|A[4],Ye=8191&bt,pt=bt>>>13,kt=0|A[5],Ue=8191&kt,vt=kt>>>13,Ct=0|A[6],it=8191&Ct,le=Ct>>>13,he=0|A[7],ve=8191&he,Pe=he>>>13,Xe=0|A[8],Ie=8191&Xe,et=Xe>>>13,Ke=0|A[9],$e=8191&Ke,rt=Ke>>>13;k.negative=E.negative^P.negative,k.length=19;var tt=(N+(y=Math.imul(H,Ce))|0)+((8191&(w=(w=Math.imul(H,Oe))+Math.imul(Z,Ce)|0))<<13)|0;N=((_=Math.imul(Z,Oe))+(w>>>13)|0)+(tt>>>26)|0,tt&=67108863,y=Math.imul(q,Ce),w=(w=Math.imul(q,Oe))+Math.imul(M,Ce)|0,_=Math.imul(M,Oe);var ot=(N+(y=y+Math.imul(H,Be)|0)|0)+((8191&(w=(w=w+Math.imul(H,ct)|0)+Math.imul(Z,Be)|0))<<13)|0;N=((_=_+Math.imul(Z,ct)|0)+(w>>>13)|0)+(ot>>>26)|0,ot&=67108863,y=Math.imul($,Ce),w=(w=Math.imul($,Oe))+Math.imul(K,Ce)|0,_=Math.imul(K,Oe),y=y+Math.imul(q,Be)|0,w=(w=w+Math.imul(q,ct)|0)+Math.imul(M,Be)|0,_=_+Math.imul(M,ct)|0;var Wt=(N+(y=y+Math.imul(H,We)|0)|0)+((8191&(w=(w=w+Math.imul(H,dt)|0)+Math.imul(Z,We)|0))<<13)|0;N=((_=_+Math.imul(Z,dt)|0)+(w>>>13)|0)+(Wt>>>26)|0,Wt&=67108863,y=Math.imul(X,Ce),w=(w=Math.imul(X,Oe))+Math.imul(Q,Ce)|0,_=Math.imul(Q,Oe),y=y+Math.imul($,Be)|0,w=(w=w+Math.imul($,ct)|0)+Math.imul(K,Be)|0,_=_+Math.imul(K,ct)|0,y=y+Math.imul(q,We)|0,w=(w=w+Math.imul(q,dt)|0)+Math.imul(M,We)|0,_=_+Math.imul(M,dt)|0;var Ft=(N+(y=y+Math.imul(H,qe)|0)|0)+((8191&(w=(w=w+Math.imul(H,Ot)|0)+Math.imul(Z,qe)|0))<<13)|0;N=((_=_+Math.imul(Z,Ot)|0)+(w>>>13)|0)+(Ft>>>26)|0,Ft&=67108863,y=Math.imul(se,Ce),w=(w=Math.imul(se,Oe))+Math.imul(Y,Ce)|0,_=Math.imul(Y,Oe),y=y+Math.imul(X,Be)|0,w=(w=w+Math.imul(X,ct)|0)+Math.imul(Q,Be)|0,_=_+Math.imul(Q,ct)|0,y=y+Math.imul($,We)|0,w=(w=w+Math.imul($,dt)|0)+Math.imul(K,We)|0,_=_+Math.imul(K,dt)|0,y=y+Math.imul(q,qe)|0,w=(w=w+Math.imul(q,Ot)|0)+Math.imul(M,qe)|0,_=_+Math.imul(M,Ot)|0;var Qt=(N+(y=y+Math.imul(H,Ye)|0)|0)+((8191&(w=(w=w+Math.imul(H,pt)|0)+Math.imul(Z,Ye)|0))<<13)|0;N=((_=_+Math.imul(Z,pt)|0)+(w>>>13)|0)+(Qt>>>26)|0,Qt&=67108863,y=Math.imul(ne,Ce),w=(w=Math.imul(ne,Oe))+Math.imul(oe,Ce)|0,_=Math.imul(oe,Oe),y=y+Math.imul(se,Be)|0,w=(w=w+Math.imul(se,ct)|0)+Math.imul(Y,Be)|0,_=_+Math.imul(Y,ct)|0,y=y+Math.imul(X,We)|0,w=(w=w+Math.imul(X,dt)|0)+Math.imul(Q,We)|0,_=_+Math.imul(Q,dt)|0,y=y+Math.imul($,qe)|0,w=(w=w+Math.imul($,Ot)|0)+Math.imul(K,qe)|0,_=_+Math.imul(K,Ot)|0,y=y+Math.imul(q,Ye)|0,w=(w=w+Math.imul(q,pt)|0)+Math.imul(M,Ye)|0,_=_+Math.imul(M,pt)|0;var Kt=(N+(y=y+Math.imul(H,Ue)|0)|0)+((8191&(w=(w=w+Math.imul(H,vt)|0)+Math.imul(Z,Ue)|0))<<13)|0;N=((_=_+Math.imul(Z,vt)|0)+(w>>>13)|0)+(Kt>>>26)|0,Kt&=67108863,y=Math.imul(ce,Ce),w=(w=Math.imul(ce,Oe))+Math.imul(me,Ce)|0,_=Math.imul(me,Oe),y=y+Math.imul(ne,Be)|0,w=(w=w+Math.imul(ne,ct)|0)+Math.imul(oe,Be)|0,_=_+Math.imul(oe,ct)|0,y=y+Math.imul(se,We)|0,w=(w=w+Math.imul(se,dt)|0)+Math.imul(Y,We)|0,_=_+Math.imul(Y,dt)|0,y=y+Math.imul(X,qe)|0,w=(w=w+Math.imul(X,Ot)|0)+Math.imul(Q,qe)|0,_=_+Math.imul(Q,Ot)|0,y=y+Math.imul($,Ye)|0,w=(w=w+Math.imul($,pt)|0)+Math.imul(K,Ye)|0,_=_+Math.imul(K,pt)|0,y=y+Math.imul(q,Ue)|0,w=(w=w+Math.imul(q,vt)|0)+Math.imul(M,Ue)|0,_=_+Math.imul(M,vt)|0;var pr=(N+(y=y+Math.imul(H,it)|0)|0)+((8191&(w=(w=w+Math.imul(H,le)|0)+Math.imul(Z,it)|0))<<13)|0;N=((_=_+Math.imul(Z,le)|0)+(w>>>13)|0)+(pr>>>26)|0,pr&=67108863,y=Math.imul(ye,Ce),w=(w=Math.imul(ye,Oe))+Math.imul(Me,Ce)|0,_=Math.imul(Me,Oe),y=y+Math.imul(ce,Be)|0,w=(w=w+Math.imul(ce,ct)|0)+Math.imul(me,Be)|0,_=_+Math.imul(me,ct)|0,y=y+Math.imul(ne,We)|0,w=(w=w+Math.imul(ne,dt)|0)+Math.imul(oe,We)|0,_=_+Math.imul(oe,dt)|0,y=y+Math.imul(se,qe)|0,w=(w=w+Math.imul(se,Ot)|0)+Math.imul(Y,qe)|0,_=_+Math.imul(Y,Ot)|0,y=y+Math.imul(X,Ye)|0,w=(w=w+Math.imul(X,pt)|0)+Math.imul(Q,Ye)|0,_=_+Math.imul(Q,pt)|0,y=y+Math.imul($,Ue)|0,w=(w=w+Math.imul($,vt)|0)+Math.imul(K,Ue)|0,_=_+Math.imul(K,vt)|0,y=y+Math.imul(q,it)|0,w=(w=w+Math.imul(q,le)|0)+Math.imul(M,it)|0,_=_+Math.imul(M,le)|0;var re=(N+(y=y+Math.imul(H,ve)|0)|0)+((8191&(w=(w=w+Math.imul(H,Pe)|0)+Math.imul(Z,ve)|0))<<13)|0;N=((_=_+Math.imul(Z,Pe)|0)+(w>>>13)|0)+(re>>>26)|0,re&=67108863,y=Math.imul(fe,Ce),w=(w=Math.imul(fe,Oe))+Math.imul(ke,Ce)|0,_=Math.imul(ke,Oe),y=y+Math.imul(ye,Be)|0,w=(w=w+Math.imul(ye,ct)|0)+Math.imul(Me,Be)|0,_=_+Math.imul(Me,ct)|0,y=y+Math.imul(ce,We)|0,w=(w=w+Math.imul(ce,dt)|0)+Math.imul(me,We)|0,_=_+Math.imul(me,dt)|0,y=y+Math.imul(ne,qe)|0,w=(w=w+Math.imul(ne,Ot)|0)+Math.imul(oe,qe)|0,_=_+Math.imul(oe,Ot)|0,y=y+Math.imul(se,Ye)|0,w=(w=w+Math.imul(se,pt)|0)+Math.imul(Y,Ye)|0,_=_+Math.imul(Y,pt)|0,y=y+Math.imul(X,Ue)|0,w=(w=w+Math.imul(X,vt)|0)+Math.imul(Q,Ue)|0,_=_+Math.imul(Q,vt)|0,y=y+Math.imul($,it)|0,w=(w=w+Math.imul($,le)|0)+Math.imul(K,it)|0,_=_+Math.imul(K,le)|0,y=y+Math.imul(q,ve)|0,w=(w=w+Math.imul(q,Pe)|0)+Math.imul(M,ve)|0,_=_+Math.imul(M,Pe)|0;var pe=(N+(y=y+Math.imul(H,Ie)|0)|0)+((8191&(w=(w=w+Math.imul(H,et)|0)+Math.imul(Z,Ie)|0))<<13)|0;N=((_=_+Math.imul(Z,et)|0)+(w>>>13)|0)+(pe>>>26)|0,pe&=67108863,y=Math.imul(Ne,Ce),w=(w=Math.imul(Ne,Oe))+Math.imul(De,Ce)|0,_=Math.imul(De,Oe),y=y+Math.imul(fe,Be)|0,w=(w=w+Math.imul(fe,ct)|0)+Math.imul(ke,Be)|0,_=_+Math.imul(ke,ct)|0,y=y+Math.imul(ye,We)|0,w=(w=w+Math.imul(ye,dt)|0)+Math.imul(Me,We)|0,_=_+Math.imul(Me,dt)|0,y=y+Math.imul(ce,qe)|0,w=(w=w+Math.imul(ce,Ot)|0)+Math.imul(me,qe)|0,_=_+Math.imul(me,Ot)|0,y=y+Math.imul(ne,Ye)|0,w=(w=w+Math.imul(ne,pt)|0)+Math.imul(oe,Ye)|0,_=_+Math.imul(oe,pt)|0,y=y+Math.imul(se,Ue)|0,w=(w=w+Math.imul(se,vt)|0)+Math.imul(Y,Ue)|0,_=_+Math.imul(Y,vt)|0,y=y+Math.imul(X,it)|0,w=(w=w+Math.imul(X,le)|0)+Math.imul(Q,it)|0,_=_+Math.imul(Q,le)|0,y=y+Math.imul($,ve)|0,w=(w=w+Math.imul($,Pe)|0)+Math.imul(K,ve)|0,_=_+Math.imul(K,Pe)|0,y=y+Math.imul(q,Ie)|0,w=(w=w+Math.imul(q,et)|0)+Math.imul(M,Ie)|0,_=_+Math.imul(M,et)|0;var we=(N+(y=y+Math.imul(H,$e)|0)|0)+((8191&(w=(w=w+Math.imul(H,rt)|0)+Math.imul(Z,$e)|0))<<13)|0;N=((_=_+Math.imul(Z,rt)|0)+(w>>>13)|0)+(we>>>26)|0,we&=67108863,y=Math.imul(Ne,Be),w=(w=Math.imul(Ne,ct))+Math.imul(De,Be)|0,_=Math.imul(De,ct),y=y+Math.imul(fe,We)|0,w=(w=w+Math.imul(fe,dt)|0)+Math.imul(ke,We)|0,_=_+Math.imul(ke,dt)|0,y=y+Math.imul(ye,qe)|0,w=(w=w+Math.imul(ye,Ot)|0)+Math.imul(Me,qe)|0,_=_+Math.imul(Me,Ot)|0,y=y+Math.imul(ce,Ye)|0,w=(w=w+Math.imul(ce,pt)|0)+Math.imul(me,Ye)|0,_=_+Math.imul(me,pt)|0,y=y+Math.imul(ne,Ue)|0,w=(w=w+Math.imul(ne,vt)|0)+Math.imul(oe,Ue)|0,_=_+Math.imul(oe,vt)|0,y=y+Math.imul(se,it)|0,w=(w=w+Math.imul(se,le)|0)+Math.imul(Y,it)|0,_=_+Math.imul(Y,le)|0,y=y+Math.imul(X,ve)|0,w=(w=w+Math.imul(X,Pe)|0)+Math.imul(Q,ve)|0,_=_+Math.imul(Q,Pe)|0,y=y+Math.imul($,Ie)|0,w=(w=w+Math.imul($,et)|0)+Math.imul(K,Ie)|0,_=_+Math.imul(K,et)|0;var _e=(N+(y=y+Math.imul(q,$e)|0)|0)+((8191&(w=(w=w+Math.imul(q,rt)|0)+Math.imul(M,$e)|0))<<13)|0;N=((_=_+Math.imul(M,rt)|0)+(w>>>13)|0)+(_e>>>26)|0,_e&=67108863,y=Math.imul(Ne,We),w=(w=Math.imul(Ne,dt))+Math.imul(De,We)|0,_=Math.imul(De,dt),y=y+Math.imul(fe,qe)|0,w=(w=w+Math.imul(fe,Ot)|0)+Math.imul(ke,qe)|0,_=_+Math.imul(ke,Ot)|0,y=y+Math.imul(ye,Ye)|0,w=(w=w+Math.imul(ye,pt)|0)+Math.imul(Me,Ye)|0,_=_+Math.imul(Me,pt)|0,y=y+Math.imul(ce,Ue)|0,w=(w=w+Math.imul(ce,vt)|0)+Math.imul(me,Ue)|0,_=_+Math.imul(me,vt)|0,y=y+Math.imul(ne,it)|0,w=(w=w+Math.imul(ne,le)|0)+Math.imul(oe,it)|0,_=_+Math.imul(oe,le)|0,y=y+Math.imul(se,ve)|0,w=(w=w+Math.imul(se,Pe)|0)+Math.imul(Y,ve)|0,_=_+Math.imul(Y,Pe)|0,y=y+Math.imul(X,Ie)|0,w=(w=w+Math.imul(X,et)|0)+Math.imul(Q,Ie)|0,_=_+Math.imul(Q,et)|0;var ze=(N+(y=y+Math.imul($,$e)|0)|0)+((8191&(w=(w=w+Math.imul($,rt)|0)+Math.imul(K,$e)|0))<<13)|0;N=((_=_+Math.imul(K,rt)|0)+(w>>>13)|0)+(ze>>>26)|0,ze&=67108863,y=Math.imul(Ne,qe),w=(w=Math.imul(Ne,Ot))+Math.imul(De,qe)|0,_=Math.imul(De,Ot),y=y+Math.imul(fe,Ye)|0,w=(w=w+Math.imul(fe,pt)|0)+Math.imul(ke,Ye)|0,_=_+Math.imul(ke,pt)|0,y=y+Math.imul(ye,Ue)|0,w=(w=w+Math.imul(ye,vt)|0)+Math.imul(Me,Ue)|0,_=_+Math.imul(Me,vt)|0,y=y+Math.imul(ce,it)|0,w=(w=w+Math.imul(ce,le)|0)+Math.imul(me,it)|0,_=_+Math.imul(me,le)|0,y=y+Math.imul(ne,ve)|0,w=(w=w+Math.imul(ne,Pe)|0)+Math.imul(oe,ve)|0,_=_+Math.imul(oe,Pe)|0,y=y+Math.imul(se,Ie)|0,w=(w=w+Math.imul(se,et)|0)+Math.imul(Y,Ie)|0,_=_+Math.imul(Y,et)|0;var Ae=(N+(y=y+Math.imul(X,$e)|0)|0)+((8191&(w=(w=w+Math.imul(X,rt)|0)+Math.imul(Q,$e)|0))<<13)|0;N=((_=_+Math.imul(Q,rt)|0)+(w>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,y=Math.imul(Ne,Ye),w=(w=Math.imul(Ne,pt))+Math.imul(De,Ye)|0,_=Math.imul(De,pt),y=y+Math.imul(fe,Ue)|0,w=(w=w+Math.imul(fe,vt)|0)+Math.imul(ke,Ue)|0,_=_+Math.imul(ke,vt)|0,y=y+Math.imul(ye,it)|0,w=(w=w+Math.imul(ye,le)|0)+Math.imul(Me,it)|0,_=_+Math.imul(Me,le)|0,y=y+Math.imul(ce,ve)|0,w=(w=w+Math.imul(ce,Pe)|0)+Math.imul(me,ve)|0,_=_+Math.imul(me,Pe)|0,y=y+Math.imul(ne,Ie)|0,w=(w=w+Math.imul(ne,et)|0)+Math.imul(oe,Ie)|0,_=_+Math.imul(oe,et)|0;var Re=(N+(y=y+Math.imul(se,$e)|0)|0)+((8191&(w=(w=w+Math.imul(se,rt)|0)+Math.imul(Y,$e)|0))<<13)|0;N=((_=_+Math.imul(Y,rt)|0)+(w>>>13)|0)+(Re>>>26)|0,Re&=67108863,y=Math.imul(Ne,Ue),w=(w=Math.imul(Ne,vt))+Math.imul(De,Ue)|0,_=Math.imul(De,vt),y=y+Math.imul(fe,it)|0,w=(w=w+Math.imul(fe,le)|0)+Math.imul(ke,it)|0,_=_+Math.imul(ke,le)|0,y=y+Math.imul(ye,ve)|0,w=(w=w+Math.imul(ye,Pe)|0)+Math.imul(Me,ve)|0,_=_+Math.imul(Me,Pe)|0,y=y+Math.imul(ce,Ie)|0,w=(w=w+Math.imul(ce,et)|0)+Math.imul(me,Ie)|0,_=_+Math.imul(me,et)|0;var ht=(N+(y=y+Math.imul(ne,$e)|0)|0)+((8191&(w=(w=w+Math.imul(ne,rt)|0)+Math.imul(oe,$e)|0))<<13)|0;N=((_=_+Math.imul(oe,rt)|0)+(w>>>13)|0)+(ht>>>26)|0,ht&=67108863,y=Math.imul(Ne,it),w=(w=Math.imul(Ne,le))+Math.imul(De,it)|0,_=Math.imul(De,le),y=y+Math.imul(fe,ve)|0,w=(w=w+Math.imul(fe,Pe)|0)+Math.imul(ke,ve)|0,_=_+Math.imul(ke,Pe)|0,y=y+Math.imul(ye,Ie)|0,w=(w=w+Math.imul(ye,et)|0)+Math.imul(Me,Ie)|0,_=_+Math.imul(Me,et)|0;var st=(N+(y=y+Math.imul(ce,$e)|0)|0)+((8191&(w=(w=w+Math.imul(ce,rt)|0)+Math.imul(me,$e)|0))<<13)|0;N=((_=_+Math.imul(me,rt)|0)+(w>>>13)|0)+(st>>>26)|0,st&=67108863,y=Math.imul(Ne,ve),w=(w=Math.imul(Ne,Pe))+Math.imul(De,ve)|0,_=Math.imul(De,Pe),y=y+Math.imul(fe,Ie)|0,w=(w=w+Math.imul(fe,et)|0)+Math.imul(ke,Ie)|0,_=_+Math.imul(ke,et)|0;var at=(N+(y=y+Math.imul(ye,$e)|0)|0)+((8191&(w=(w=w+Math.imul(ye,rt)|0)+Math.imul(Me,$e)|0))<<13)|0;N=((_=_+Math.imul(Me,rt)|0)+(w>>>13)|0)+(at>>>26)|0,at&=67108863,y=Math.imul(Ne,Ie),w=(w=Math.imul(Ne,et))+Math.imul(De,Ie)|0,_=Math.imul(De,et);var Ge=(N+(y=y+Math.imul(fe,$e)|0)|0)+((8191&(w=(w=w+Math.imul(fe,rt)|0)+Math.imul(ke,$e)|0))<<13)|0;N=((_=_+Math.imul(ke,rt)|0)+(w>>>13)|0)+(Ge>>>26)|0,Ge&=67108863;var xt=(N+(y=Math.imul(Ne,$e))|0)+((8191&(w=(w=Math.imul(Ne,rt))+Math.imul(De,$e)|0))<<13)|0;return N=((_=Math.imul(De,rt))+(w>>>13)|0)+(xt>>>26)|0,xt&=67108863,O[0]=tt,O[1]=ot,O[2]=Wt,O[3]=Ft,O[4]=Qt,O[5]=Kt,O[6]=pr,O[7]=re,O[8]=pe,O[9]=we,O[10]=_e,O[11]=ze,O[12]=Ae,O[13]=Re,O[14]=ht,O[15]=st,O[16]=at,O[17]=Ge,O[18]=xt,N!==0&&(O[19]=N,k.length++),k};function x(E,P,k){return new C().mulp(E,P,k)}function C(E,P){this.x=E,this.y=P}Math.imul||(g=v),n.prototype.mulTo=function(E,P){var k=this.length+E.length;return this.length===10&&E.length===10?g(this,E,P):k<63?v(this,E,P):k<1024?function(y,w,_){_.negative=w.negative^y.negative,_.length=y.length+w.length;for(var S=0,A=0,O=0;O<_.length-1;O++){var N=A;A=0;for(var U=67108863&S,H=Math.min(O,w.length-1),Z=Math.max(0,O-y.length+1);Z<=H;Z++){var D=O-Z,q=(0|y.words[D])*(0|w.words[Z]),M=67108863&q;U=67108863&(M=M+U|0),A+=(N=(N=N+(q/67108864|0)|0)+(M>>>26)|0)>>>26,N&=67108863}_.words[O]=U,S=N,N=A}return S!==0?_.words[O]=S:_.length--,_.strip()}(this,E,P):x(this,E,P)},C.prototype.makeRBT=function(E){for(var P=new Array(E),k=n.prototype._countBits(E)-1,y=0;y<E;y++)P[y]=this.revBin(y,k,E);return P},C.prototype.revBin=function(E,P,k){if(E===0||E===k-1)return E;for(var y=0,w=0;w<P;w++)y|=(1&E)<<P-w-1,E>>=1;return y},C.prototype.permute=function(E,P,k,y,w,_){for(var S=0;S<_;S++)y[S]=P[E[S]],w[S]=k[E[S]]},C.prototype.transform=function(E,P,k,y,w,_){this.permute(_,E,P,k,y,w);for(var S=1;S<w;S<<=1)for(var A=S<<1,O=Math.cos(2*Math.PI/A),N=Math.sin(2*Math.PI/A),U=0;U<w;U+=A)for(var H=O,Z=N,D=0;D<S;D++){var q=k[U+D],M=y[U+D],j=k[U+D+S],$=y[U+D+S],K=H*j-Z*$;$=H*$+Z*j,j=K,k[U+D]=q+j,y[U+D]=M+$,k[U+D+S]=q-j,y[U+D+S]=M-$,D!==A&&(K=O*H-N*Z,Z=O*Z+N*H,H=K)}},C.prototype.guessLen13b=function(E,P){var k=1|Math.max(P,E),y=1&k,w=0;for(k=k/2|0;k;k>>>=1)w++;return 1<<w+1+y},C.prototype.conjugate=function(E,P,k){if(!(k<=1))for(var y=0;y<k/2;y++){var w=E[y];E[y]=E[k-y-1],E[k-y-1]=w,w=P[y],P[y]=-P[k-y-1],P[k-y-1]=-w}},C.prototype.normalize13b=function(E,P){for(var k=0,y=0;y<P/2;y++){var w=8192*Math.round(E[2*y+1]/P)+Math.round(E[2*y]/P)+k;E[y]=67108863&w,k=w<67108864?0:w/67108864|0}return E},C.prototype.convert13b=function(E,P,k,y){for(var w=0,_=0;_<P;_++)w+=0|E[_],k[2*_]=8191&w,w>>>=13,k[2*_+1]=8191&w,w>>>=13;for(_=2*P;_<y;++_)k[_]=0;l(w===0),l((-8192&w)==0)},C.prototype.stub=function(E){for(var P=new Array(E),k=0;k<E;k++)P[k]=0;return P},C.prototype.mulp=function(E,P,k){var y=2*this.guessLen13b(E.length,P.length),w=this.makeRBT(y),_=this.stub(y),S=new Array(y),A=new Array(y),O=new Array(y),N=new Array(y),U=new Array(y),H=new Array(y),Z=k.words;Z.length=y,this.convert13b(E.words,E.length,S,y),this.convert13b(P.words,P.length,N,y),this.transform(S,_,A,O,y,w),this.transform(N,_,U,H,y,w);for(var D=0;D<y;D++){var q=A[D]*U[D]-O[D]*H[D];O[D]=A[D]*H[D]+O[D]*U[D],A[D]=q}return this.conjugate(A,O,y),this.transform(A,O,Z,_,y,w),this.conjugate(Z,_,y),this.normalize13b(Z,y),k.negative=E.negative^P.negative,k.length=E.length+P.length,k.strip()},n.prototype.mul=function(E){var P=new n(null);return P.words=new Array(this.length+E.length),this.mulTo(E,P)},n.prototype.mulf=function(E){var P=new n(null);return P.words=new Array(this.length+E.length),x(this,E,P)},n.prototype.imul=function(E){return this.clone().mulTo(E,this)},n.prototype.imuln=function(E){l(typeof E=="number"),l(E<67108864);for(var P=0,k=0;k<this.length;k++){var y=(0|this.words[k])*E,w=(67108863&y)+(67108863&P);P>>=26,P+=y/67108864|0,P+=w>>>26,this.words[k]=67108863&w}return P!==0&&(this.words[k]=P,this.length++),this},n.prototype.muln=function(E){return this.clone().imuln(E)},n.prototype.sqr=function(){return this.mul(this)},n.prototype.isqr=function(){return this.imul(this.clone())},n.prototype.pow=function(E){var P=function(_){for(var S=new Array(_.bitLength()),A=0;A<S.length;A++){var O=A/26|0,N=A%26;S[A]=(_.words[O]&1<<N)>>>N}return S}(E);if(P.length===0)return new n(1);for(var k=this,y=0;y<P.length&&P[y]===0;y++,k=k.sqr());if(++y<P.length)for(var w=k.sqr();y<P.length;y++,w=w.sqr())P[y]!==0&&(k=k.mul(w));return k},n.prototype.iushln=function(E){l(typeof E=="number"&&E>=0);var P,k=E%26,y=(E-k)/26,w=67108863>>>26-k<<26-k;if(k!==0){var _=0;for(P=0;P<this.length;P++){var S=this.words[P]&w,A=(0|this.words[P])-S<<k;this.words[P]=A|_,_=S>>>26-k}_&&(this.words[P]=_,this.length++)}if(y!==0){for(P=this.length-1;P>=0;P--)this.words[P+y]=this.words[P];for(P=0;P<y;P++)this.words[P]=0;this.length+=y}return this.strip()},n.prototype.ishln=function(E){return l(this.negative===0),this.iushln(E)},n.prototype.iushrn=function(E,P,k){var y;l(typeof E=="number"&&E>=0),y=P?(P-P%26)/26:0;var w=E%26,_=Math.min((E-w)/26,this.length),S=67108863^67108863>>>w<<w,A=k;if(y-=_,y=Math.max(0,y),A){for(var O=0;O<_;O++)A.words[O]=this.words[O];A.length=_}if(_!==0)if(this.length>_)for(this.length-=_,O=0;O<this.length;O++)this.words[O]=this.words[O+_];else this.words[0]=0,this.length=1;var N=0;for(O=this.length-1;O>=0&&(N!==0||O>=y);O--){var U=0|this.words[O];this.words[O]=N<<26-w|U>>>w,N=U&S}return A&&N!==0&&(A.words[A.length++]=N),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},n.prototype.ishrn=function(E,P,k){return l(this.negative===0),this.iushrn(E,P,k)},n.prototype.shln=function(E){return this.clone().ishln(E)},n.prototype.ushln=function(E){return this.clone().iushln(E)},n.prototype.shrn=function(E){return this.clone().ishrn(E)},n.prototype.ushrn=function(E){return this.clone().iushrn(E)},n.prototype.testn=function(E){l(typeof E=="number"&&E>=0);var P=E%26,k=(E-P)/26,y=1<<P;return!(this.length<=k)&&!!(this.words[k]&y)},n.prototype.imaskn=function(E){l(typeof E=="number"&&E>=0);var P=E%26,k=(E-P)/26;if(l(this.negative===0,"imaskn works only with positive numbers"),this.length<=k)return this;if(P!==0&&k++,this.length=Math.min(k,this.length),P!==0){var y=67108863^67108863>>>P<<P;this.words[this.length-1]&=y}return this.strip()},n.prototype.maskn=function(E){return this.clone().imaskn(E)},n.prototype.iaddn=function(E){return l(typeof E=="number"),l(E<67108864),E<0?this.isubn(-E):this.negative!==0?this.length===1&&(0|this.words[0])<E?(this.words[0]=E-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(E),this.negative=1,this):this._iaddn(E)},n.prototype._iaddn=function(E){this.words[0]+=E;for(var P=0;P<this.length&&this.words[P]>=67108864;P++)this.words[P]-=67108864,P===this.length-1?this.words[P+1]=1:this.words[P+1]++;return this.length=Math.max(this.length,P+1),this},n.prototype.isubn=function(E){if(l(typeof E=="number"),l(E<67108864),E<0)return this.iaddn(-E);if(this.negative!==0)return this.negative=0,this.iaddn(E),this.negative=1,this;if(this.words[0]-=E,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var P=0;P<this.length&&this.words[P]<0;P++)this.words[P]+=67108864,this.words[P+1]-=1;return this.strip()},n.prototype.addn=function(E){return this.clone().iaddn(E)},n.prototype.subn=function(E){return this.clone().isubn(E)},n.prototype.iabs=function(){return this.negative=0,this},n.prototype.abs=function(){return this.clone().iabs()},n.prototype._ishlnsubmul=function(E,P,k){var y,w,_=E.length+k;this._expand(_);var S=0;for(y=0;y<E.length;y++){w=(0|this.words[y+k])+S;var A=(0|E.words[y])*P;S=((w-=67108863&A)>>26)-(A/67108864|0),this.words[y+k]=67108863&w}for(;y<this.length-k;y++)S=(w=(0|this.words[y+k])+S)>>26,this.words[y+k]=67108863&w;if(S===0)return this.strip();for(l(S===-1),S=0,y=0;y<this.length;y++)S=(w=-(0|this.words[y])+S)>>26,this.words[y]=67108863&w;return this.negative=1,this.strip()},n.prototype._wordDiv=function(E,P){var k=(this.length,E.length),y=this.clone(),w=E,_=0|w.words[w.length-1];(k=26-this._countBits(_))!==0&&(w=w.ushln(k),y.iushln(k),_=0|w.words[w.length-1]);var S,A=y.length-w.length;if(P!=="mod"){(S=new n(null)).length=A+1,S.words=new Array(S.length);for(var O=0;O<S.length;O++)S.words[O]=0}var N=y.clone()._ishlnsubmul(w,1,A);N.negative===0&&(y=N,S&&(S.words[A]=1));for(var U=A-1;U>=0;U--){var H=67108864*(0|y.words[w.length+U])+(0|y.words[w.length+U-1]);for(H=Math.min(H/_|0,67108863),y._ishlnsubmul(w,H,U);y.negative!==0;)H--,y.negative=0,y._ishlnsubmul(w,1,U),y.isZero()||(y.negative^=1);S&&(S.words[U]=H)}return S&&S.strip(),y.strip(),P!=="div"&&k!==0&&y.iushrn(k),{div:S||null,mod:y}},n.prototype.divmod=function(E,P,k){return l(!E.isZero()),this.isZero()?{div:new n(0),mod:new n(0)}:this.negative!==0&&E.negative===0?(_=this.neg().divmod(E,P),P!=="mod"&&(y=_.div.neg()),P!=="div"&&(w=_.mod.neg(),k&&w.negative!==0&&w.iadd(E)),{div:y,mod:w}):this.negative===0&&E.negative!==0?(_=this.divmod(E.neg(),P),P!=="mod"&&(y=_.div.neg()),{div:y,mod:_.mod}):(this.negative&E.negative)!=0?(_=this.neg().divmod(E.neg(),P),P!=="div"&&(w=_.mod.neg(),k&&w.negative!==0&&w.isub(E)),{div:_.div,mod:w}):E.length>this.length||this.cmp(E)<0?{div:new n(0),mod:this}:E.length===1?P==="div"?{div:this.divn(E.words[0]),mod:null}:P==="mod"?{div:null,mod:new n(this.modn(E.words[0]))}:{div:this.divn(E.words[0]),mod:new n(this.modn(E.words[0]))}:this._wordDiv(E,P);var y,w,_},n.prototype.div=function(E){return this.divmod(E,"div",!1).div},n.prototype.mod=function(E){return this.divmod(E,"mod",!1).mod},n.prototype.umod=function(E){return this.divmod(E,"mod",!0).mod},n.prototype.divRound=function(E){var P=this.divmod(E);if(P.mod.isZero())return P.div;var k=P.div.negative!==0?P.mod.isub(E):P.mod,y=E.ushrn(1),w=E.andln(1),_=k.cmp(y);return _<0||w===1&&_===0?P.div:P.div.negative!==0?P.div.isubn(1):P.div.iaddn(1)},n.prototype.modn=function(E){l(E<=67108863);for(var P=(1<<26)%E,k=0,y=this.length-1;y>=0;y--)k=(P*k+(0|this.words[y]))%E;return k},n.prototype.idivn=function(E){l(E<=67108863);for(var P=0,k=this.length-1;k>=0;k--){var y=(0|this.words[k])+67108864*P;this.words[k]=y/E|0,P=y%E}return this.strip()},n.prototype.divn=function(E){return this.clone().idivn(E)},n.prototype.egcd=function(E){l(E.negative===0),l(!E.isZero());var P=this,k=E.clone();P=P.negative!==0?P.umod(E):P.clone();for(var y=new n(1),w=new n(0),_=new n(0),S=new n(1),A=0;P.isEven()&&k.isEven();)P.iushrn(1),k.iushrn(1),++A;for(var O=k.clone(),N=P.clone();!P.isZero();){for(var U=0,H=1;(P.words[0]&H)==0&&U<26;++U,H<<=1);if(U>0)for(P.iushrn(U);U-- >0;)(y.isOdd()||w.isOdd())&&(y.iadd(O),w.isub(N)),y.iushrn(1),w.iushrn(1);for(var Z=0,D=1;(k.words[0]&D)==0&&Z<26;++Z,D<<=1);if(Z>0)for(k.iushrn(Z);Z-- >0;)(_.isOdd()||S.isOdd())&&(_.iadd(O),S.isub(N)),_.iushrn(1),S.iushrn(1);P.cmp(k)>=0?(P.isub(k),y.isub(_),w.isub(S)):(k.isub(P),_.isub(y),S.isub(w))}return{a:_,b:S,gcd:k.iushln(A)}},n.prototype._invmp=function(E){l(E.negative===0),l(!E.isZero());var P=this,k=E.clone();P=P.negative!==0?P.umod(E):P.clone();for(var y,w=new n(1),_=new n(0),S=k.clone();P.cmpn(1)>0&&k.cmpn(1)>0;){for(var A=0,O=1;(P.words[0]&O)==0&&A<26;++A,O<<=1);if(A>0)for(P.iushrn(A);A-- >0;)w.isOdd()&&w.iadd(S),w.iushrn(1);for(var N=0,U=1;(k.words[0]&U)==0&&N<26;++N,U<<=1);if(N>0)for(k.iushrn(N);N-- >0;)_.isOdd()&&_.iadd(S),_.iushrn(1);P.cmp(k)>=0?(P.isub(k),w.isub(_)):(k.isub(P),_.isub(w))}return(y=P.cmpn(1)===0?w:_).cmpn(0)<0&&y.iadd(E),y},n.prototype.gcd=function(E){if(this.isZero())return E.abs();if(E.isZero())return this.abs();var P=this.clone(),k=E.clone();P.negative=0,k.negative=0;for(var y=0;P.isEven()&&k.isEven();y++)P.iushrn(1),k.iushrn(1);for(;;){for(;P.isEven();)P.iushrn(1);for(;k.isEven();)k.iushrn(1);var w=P.cmp(k);if(w<0){var _=P;P=k,k=_}else if(w===0||k.cmpn(1)===0)break;P.isub(k)}return k.iushln(y)},n.prototype.invm=function(E){return this.egcd(E).a.umod(E)},n.prototype.isEven=function(){return(1&this.words[0])==0},n.prototype.isOdd=function(){return(1&this.words[0])==1},n.prototype.andln=function(E){return this.words[0]&E},n.prototype.bincn=function(E){l(typeof E=="number");var P=E%26,k=(E-P)/26,y=1<<P;if(this.length<=k)return this._expand(k+1),this.words[k]|=y,this;for(var w=y,_=k;w!==0&&_<this.length;_++){var S=0|this.words[_];w=(S+=w)>>>26,S&=67108863,this.words[_]=S}return w!==0&&(this.words[_]=w,this.length++),this},n.prototype.isZero=function(){return this.length===1&&this.words[0]===0},n.prototype.cmpn=function(E){var P,k=E<0;if(this.negative!==0&&!k)return-1;if(this.negative===0&&k)return 1;if(this.strip(),this.length>1)P=1;else{k&&(E=-E),l(E<=67108863,"Number is too big");var y=0|this.words[0];P=y===E?0:y<E?-1:1}return this.negative!==0?0|-P:P},n.prototype.cmp=function(E){if(this.negative!==0&&E.negative===0)return-1;if(this.negative===0&&E.negative!==0)return 1;var P=this.ucmp(E);return this.negative!==0?0|-P:P},n.prototype.ucmp=function(E){if(this.length>E.length)return 1;if(this.length<E.length)return-1;for(var P=0,k=this.length-1;k>=0;k--){var y=0|this.words[k],w=0|E.words[k];if(y!==w){y<w?P=-1:y>w&&(P=1);break}}return P},n.prototype.gtn=function(E){return this.cmpn(E)===1},n.prototype.gt=function(E){return this.cmp(E)===1},n.prototype.gten=function(E){return this.cmpn(E)>=0},n.prototype.gte=function(E){return this.cmp(E)>=0},n.prototype.ltn=function(E){return this.cmpn(E)===-1},n.prototype.lt=function(E){return this.cmp(E)===-1},n.prototype.lten=function(E){return this.cmpn(E)<=0},n.prototype.lte=function(E){return this.cmp(E)<=0},n.prototype.eqn=function(E){return this.cmpn(E)===0},n.prototype.eq=function(E){return this.cmp(E)===0},n.red=function(E){return new V(E)},n.prototype.toRed=function(E){return l(!this.red,"Already a number in reduction context"),l(this.negative===0,"red works only with positives"),E.convertTo(this)._forceRed(E)},n.prototype.fromRed=function(){return l(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},n.prototype._forceRed=function(E){return this.red=E,this},n.prototype.forceRed=function(E){return l(!this.red,"Already a number in reduction context"),this._forceRed(E)},n.prototype.redAdd=function(E){return l(this.red,"redAdd works only with red numbers"),this.red.add(this,E)},n.prototype.redIAdd=function(E){return l(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,E)},n.prototype.redSub=function(E){return l(this.red,"redSub works only with red numbers"),this.red.sub(this,E)},n.prototype.redISub=function(E){return l(this.red,"redISub works only with red numbers"),this.red.isub(this,E)},n.prototype.redShl=function(E){return l(this.red,"redShl works only with red numbers"),this.red.shl(this,E)},n.prototype.redMul=function(E){return l(this.red,"redMul works only with red numbers"),this.red._verify2(this,E),this.red.mul(this,E)},n.prototype.redIMul=function(E){return l(this.red,"redMul works only with red numbers"),this.red._verify2(this,E),this.red.imul(this,E)},n.prototype.redSqr=function(){return l(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},n.prototype.redISqr=function(){return l(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},n.prototype.redSqrt=function(){return l(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},n.prototype.redInvm=function(){return l(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},n.prototype.redNeg=function(){return l(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},n.prototype.redPow=function(E){return l(this.red&&!E.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,E)};var T={k256:null,p224:null,p192:null,p25519:null};function R(E,P){this.name=E,this.p=new n(P,16),this.n=this.p.bitLength(),this.k=new n(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function B(){R.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function I(){R.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function F(){R.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function L(){R.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function V(E){if(typeof E=="string"){var P=n._prime(E);this.m=P.p,this.prime=P}else l(E.gtn(1),"modulus must be greater than 1"),this.m=E,this.prime=null}function z(E){V.call(this,E),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new n(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}R.prototype._tmp=function(){var E=new n(null);return E.words=new Array(Math.ceil(this.n/13)),E},R.prototype.ireduce=function(E){var P,k=E;do this.split(k,this.tmp),P=(k=(k=this.imulK(k)).iadd(this.tmp)).bitLength();while(P>this.n);var y=P<this.n?-1:k.ucmp(this.p);return y===0?(k.words[0]=0,k.length=1):y>0?k.isub(this.p):k.strip!==void 0?k.strip():k._strip(),k},R.prototype.split=function(E,P){E.iushrn(this.n,0,P)},R.prototype.imulK=function(E){return E.imul(this.k)},i(B,R),B.prototype.split=function(E,P){for(var k=Math.min(E.length,9),y=0;y<k;y++)P.words[y]=E.words[y];if(P.length=k,E.length<=9)return E.words[0]=0,void(E.length=1);var w=E.words[9];for(P.words[P.length++]=4194303&w,y=10;y<E.length;y++){var _=0|E.words[y];E.words[y-10]=(4194303&_)<<4|w>>>22,w=_}w>>>=22,E.words[y-10]=w,w===0&&E.length>10?E.length-=10:E.length-=9},B.prototype.imulK=function(E){E.words[E.length]=0,E.words[E.length+1]=0,E.length+=2;for(var P=0,k=0;k<E.length;k++){var y=0|E.words[k];P+=977*y,E.words[k]=67108863&P,P=64*y+(P/67108864|0)}return E.words[E.length-1]===0&&(E.length--,E.words[E.length-1]===0&&E.length--),E},i(I,R),i(F,R),i(L,R),L.prototype.imulK=function(E){for(var P=0,k=0;k<E.length;k++){var y=19*(0|E.words[k])+P,w=67108863&y;y>>>=26,E.words[k]=w,P=y}return P!==0&&(E.words[E.length++]=P),E},n._prime=function(E){if(T[E])return T[E];var P;if(E==="k256")P=new B;else if(E==="p224")P=new I;else if(E==="p192")P=new F;else{if(E!=="p25519")throw new Error("Unknown prime "+E);P=new L}return T[E]=P,P},V.prototype._verify1=function(E){l(E.negative===0,"red works only with positives"),l(E.red,"red works only with red numbers")},V.prototype._verify2=function(E,P){l((E.negative|P.negative)==0,"red works only with positives"),l(E.red&&E.red===P.red,"red works only with red numbers")},V.prototype.imod=function(E){return this.prime?this.prime.ireduce(E)._forceRed(this):E.umod(this.m)._forceRed(this)},V.prototype.neg=function(E){return E.isZero()?E.clone():this.m.sub(E)._forceRed(this)},V.prototype.add=function(E,P){this._verify2(E,P);var k=E.add(P);return k.cmp(this.m)>=0&&k.isub(this.m),k._forceRed(this)},V.prototype.iadd=function(E,P){this._verify2(E,P);var k=E.iadd(P);return k.cmp(this.m)>=0&&k.isub(this.m),k},V.prototype.sub=function(E,P){this._verify2(E,P);var k=E.sub(P);return k.cmpn(0)<0&&k.iadd(this.m),k._forceRed(this)},V.prototype.isub=function(E,P){this._verify2(E,P);var k=E.isub(P);return k.cmpn(0)<0&&k.iadd(this.m),k},V.prototype.shl=function(E,P){return this._verify1(E),this.imod(E.ushln(P))},V.prototype.imul=function(E,P){return this._verify2(E,P),this.imod(E.imul(P))},V.prototype.mul=function(E,P){return this._verify2(E,P),this.imod(E.mul(P))},V.prototype.isqr=function(E){return this.imul(E,E.clone())},V.prototype.sqr=function(E){return this.mul(E,E)},V.prototype.sqrt=function(E){if(E.isZero())return E.clone();var P=this.m.andln(3);if(l(P%2==1),P===3){var k=this.m.add(new n(1)).iushrn(2);return this.pow(E,k)}for(var y=this.m.subn(1),w=0;!y.isZero()&&y.andln(1)===0;)w++,y.iushrn(1);l(!y.isZero());var _=new n(1).toRed(this),S=_.redNeg(),A=this.m.subn(1).iushrn(1),O=this.m.bitLength();for(O=new n(2*O*O).toRed(this);this.pow(O,A).cmp(S)!==0;)O.redIAdd(S);for(var N=this.pow(O,y),U=this.pow(E,y.addn(1).iushrn(1)),H=this.pow(E,y),Z=w;H.cmp(_)!==0;){for(var D=H,q=0;D.cmp(_)!==0;q++)D=D.redSqr();l(q<Z);var M=this.pow(N,new n(1).iushln(Z-q-1));U=U.redMul(M),N=M.redSqr(),H=H.redMul(N),Z=q}return U},V.prototype.invm=function(E){var P=E._invmp(this.m);return P.negative!==0?(P.negative=0,this.imod(P).redNeg()):this.imod(P)},V.prototype.pow=function(E,P){if(P.isZero())return new n(1).toRed(this);if(P.cmpn(1)===0)return E.clone();var k=new Array(16);k[0]=new n(1).toRed(this),k[1]=E;for(var y=2;y<k.length;y++)k[y]=this.mul(k[y-1],E);var w=k[0],_=0,S=0,A=P.bitLength()%26;for(A===0&&(A=26),y=P.length-1;y>=0;y--){for(var O=P.words[y],N=A-1;N>=0;N--){var U=O>>N&1;w!==k[0]&&(w=this.sqr(w)),U!==0||_!==0?(_<<=1,_|=U,(++S===4||y===0&&N===0)&&(w=this.mul(w,k[_]),S=0,_=0)):S=0}A=26}return w},V.prototype.convertTo=function(E){var P=E.umod(this.m);return P===E?P.clone():P},V.prototype.convertFrom=function(E){var P=E.clone();return P.red=null,P},n.mont=function(E){return new z(E)},i(z,V),z.prototype.convertTo=function(E){return this.imod(E.ushln(this.shift))},z.prototype.convertFrom=function(E){var P=this.imod(E.mul(this.rinv));return P.red=null,P},z.prototype.imul=function(E,P){if(E.isZero()||P.isZero())return E.words[0]=0,E.length=1,E;var k=E.imul(P),y=k.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),w=k.isub(y).iushrn(this.shift),_=w;return w.cmp(this.m)>=0?_=w.isub(this.m):w.cmpn(0)<0&&(_=w.iadd(this.m)),_._forceRed(this)},z.prototype.mul=function(E,P){if(E.isZero()||P.isZero())return new n(0)._forceRed(this);var k=E.mul(P),y=k.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),w=k.isub(y).iushrn(this.shift),_=w;return w.cmp(this.m)>=0?_=w.isub(this.m):w.cmpn(0)<0&&(_=w.iadd(this.m)),_._forceRed(this)},z.prototype.invm=function(E){return this.imod(E._invmp(this.m).mul(this.r2))._forceRed(this)}})(a===void 0||a)},{buffer:188}],185:[function(e,a,f){f.byteLength=function(d){var m=h(d),b=m[0],p=m[1];return 3*(b+p)/4-p},f.toByteArray=function(d){var m,b,p=h(d),v=p[0],g=p[1],x=new l(function(R,B,I){return 3*(B+I)/4-I}(0,v,g)),C=0,T=g>0?v-4:v;for(b=0;b<T;b+=4)m=s[d.charCodeAt(b)]<<18|s[d.charCodeAt(b+1)]<<12|s[d.charCodeAt(b+2)]<<6|s[d.charCodeAt(b+3)],x[C++]=m>>16&255,x[C++]=m>>8&255,x[C++]=255&m;return g===2&&(m=s[d.charCodeAt(b)]<<2|s[d.charCodeAt(b+1)]>>4,x[C++]=255&m),g===1&&(m=s[d.charCodeAt(b)]<<10|s[d.charCodeAt(b+1)]<<4|s[d.charCodeAt(b+2)]>>2,x[C++]=m>>8&255,x[C++]=255&m),x},f.fromByteArray=function(d){for(var m,b=d.length,p=b%3,v=[],g=0,x=b-p;g<x;g+=16383)v.push(u(d,g,g+16383>x?x:g+16383));return p===1?(m=d[b-1],v.push(c[m>>2]+c[m<<4&63]+"==")):p===2&&(m=(d[b-2]<<8)+d[b-1],v.push(c[m>>10]+c[m>>4&63]+c[m<<2&63]+"=")),v.join("")};for(var c=[],s=[],l=typeof Uint8Array<"u"?Uint8Array:Array,i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n=0,o=i.length;n<o;++n)c[n]=i[n],s[i.charCodeAt(n)]=n;function h(d){var m=d.length;if(m%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var b=d.indexOf("=");return b===-1&&(b=m),[b,b===m?0:4-b%4]}function u(d,m,b){for(var p,v,g=[],x=m;x<b;x+=3)p=(d[x]<<16&16711680)+(d[x+1]<<8&65280)+(255&d[x+2]),g.push(c[(v=p)>>18&63]+c[v>>12&63]+c[v>>6&63]+c[63&v]);return g.join("")}s[45]=62,s[95]=63},{}],186:[function(e,a,f){(function(c,s){function l(k,y){if(!k)throw new Error(y||"Assertion failed")}function i(k,y){k.super_=y;var w=function(){};w.prototype=y.prototype,k.prototype=new w,k.prototype.constructor=k}function n(k,y,w){if(n.isBN(k))return k;this.negative=0,this.words=null,this.length=0,this.red=null,k!==null&&(y!=="le"&&y!=="be"||(w=y,y=10),this._init(k||0,y||10,w||"be"))}var o;typeof c=="object"?c.exports=n:(void 0).BN=n,n.BN=n,n.wordSize=26;try{o=typeof window<"u"&&window.Buffer!==void 0?window.Buffer:e("buffer").Buffer}catch{}function h(k,y){var w=k.charCodeAt(y);return w>=48&&w<=57?w-48:w>=65&&w<=70?w-55:w>=97&&w<=102?w-87:void l(!1,"Invalid character in "+k)}function u(k,y,w){var _=h(k,w);return w-1>=y&&(_|=h(k,w-1)<<4),_}function d(k,y,w,_){for(var S=0,A=0,O=Math.min(k.length,w),N=y;N<O;N++){var U=k.charCodeAt(N)-48;S*=_,A=U>=49?U-49+10:U>=17?U-17+10:U,l(U>=0&&A<_,"Invalid character"),S+=A}return S}function m(k,y){k.words=y.words,k.length=y.length,k.negative=y.negative,k.red=y.red}if(n.isBN=function(k){return k instanceof n||k!==null&&typeof k=="object"&&k.constructor.wordSize===n.wordSize&&Array.isArray(k.words)},n.max=function(k,y){return k.cmp(y)>0?k:y},n.min=function(k,y){return k.cmp(y)<0?k:y},n.prototype._init=function(k,y,w){if(typeof k=="number")return this._initNumber(k,y,w);if(typeof k=="object")return this._initArray(k,y,w);y==="hex"&&(y=16),l(y===(0|y)&&y>=2&&y<=36);var _=0;(k=k.toString().replace(/\s+/g,""))[0]==="-"&&(_++,this.negative=1),_<k.length&&(y===16?this._parseHex(k,_,w):(this._parseBase(k,y,_),w==="le"&&this._initArray(this.toArray(),y,w)))},n.prototype._initNumber=function(k,y,w){k<0&&(this.negative=1,k=-k),k<67108864?(this.words=[67108863&k],this.length=1):k<4503599627370496?(this.words=[67108863&k,k/67108864&67108863],this.length=2):(l(k<9007199254740992),this.words=[67108863&k,k/67108864&67108863,1],this.length=3),w==="le"&&this._initArray(this.toArray(),y,w)},n.prototype._initArray=function(k,y,w){if(l(typeof k.length=="number"),k.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(k.length/3),this.words=new Array(this.length);for(var _=0;_<this.length;_++)this.words[_]=0;var S,A,O=0;if(w==="be")for(_=k.length-1,S=0;_>=0;_-=3)A=k[_]|k[_-1]<<8|k[_-2]<<16,this.words[S]|=A<<O&67108863,this.words[S+1]=A>>>26-O&67108863,(O+=24)>=26&&(O-=26,S++);else if(w==="le")for(_=0,S=0;_<k.length;_+=3)A=k[_]|k[_+1]<<8|k[_+2]<<16,this.words[S]|=A<<O&67108863,this.words[S+1]=A>>>26-O&67108863,(O+=24)>=26&&(O-=26,S++);return this._strip()},n.prototype._parseHex=function(k,y,w){this.length=Math.ceil((k.length-y)/6),this.words=new Array(this.length);for(var _=0;_<this.length;_++)this.words[_]=0;var S,A=0,O=0;if(w==="be")for(_=k.length-1;_>=y;_-=2)S=u(k,y,_)<<A,this.words[O]|=67108863&S,A>=18?(A-=18,O+=1,this.words[O]|=S>>>26):A+=8;else for(_=(k.length-y)%2==0?y+1:y;_<k.length;_+=2)S=u(k,y,_)<<A,this.words[O]|=67108863&S,A>=18?(A-=18,O+=1,this.words[O]|=S>>>26):A+=8;this._strip()},n.prototype._parseBase=function(k,y,w){this.words=[0],this.length=1;for(var _=0,S=1;S<=67108863;S*=y)_++;_--,S=S/y|0;for(var A=k.length-w,O=A%_,N=Math.min(A,A-O)+w,U=0,H=w;H<N;H+=_)U=d(k,H,H+_,y),this.imuln(S),this.words[0]+U<67108864?this.words[0]+=U:this._iaddn(U);if(O!==0){var Z=1;for(U=d(k,H,k.length,y),H=0;H<O;H++)Z*=y;this.imuln(Z),this.words[0]+U<67108864?this.words[0]+=U:this._iaddn(U)}this._strip()},n.prototype.copy=function(k){k.words=new Array(this.length);for(var y=0;y<this.length;y++)k.words[y]=this.words[y];k.length=this.length,k.negative=this.negative,k.red=this.red},n.prototype._move=function(k){m(k,this)},n.prototype.clone=function(){var k=new n(null);return this.copy(k),k},n.prototype._expand=function(k){for(;this.length<k;)this.words[this.length++]=0;return this},n.prototype._strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},n.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol<"u"&&typeof Symbol.for=="function")try{n.prototype[Symbol.for("nodejs.util.inspect.custom")]=b}catch{n.prototype.inspect=b}else n.prototype.inspect=b;function b(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var p=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],v=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],g=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];n.prototype.toString=function(k,y){var w;if(y=0|y||1,(k=k||10)===16||k==="hex"){w="";for(var _=0,S=0,A=0;A<this.length;A++){var O=this.words[A],N=(16777215&(O<<_|S)).toString(16);S=O>>>24-_&16777215,(_+=2)>=26&&(_-=26,A--),w=S!==0||A!==this.length-1?p[6-N.length]+N+w:N+w}for(S!==0&&(w=S.toString(16)+w);w.length%y!=0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}if(k===(0|k)&&k>=2&&k<=36){var U=v[k],H=g[k];w="";var Z=this.clone();for(Z.negative=0;!Z.isZero();){var D=Z.modrn(H).toString(k);w=(Z=Z.idivn(H)).isZero()?D+w:p[U-D.length]+D+w}for(this.isZero()&&(w="0"+w);w.length%y!=0;)w="0"+w;return this.negative!==0&&(w="-"+w),w}l(!1,"Base should be between 2 and 36")},n.prototype.toNumber=function(){var k=this.words[0];return this.length===2?k+=67108864*this.words[1]:this.length===3&&this.words[2]===1?k+=4503599627370496+67108864*this.words[1]:this.length>2&&l(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-k:k},n.prototype.toJSON=function(){return this.toString(16,2)},o&&(n.prototype.toBuffer=function(k,y){return this.toArrayLike(o,k,y)}),n.prototype.toArray=function(k,y){return this.toArrayLike(Array,k,y)};function x(k,y,w){w.negative=y.negative^k.negative;var _=k.length+y.length|0;w.length=_,_=_-1|0;var S=0|k.words[0],A=0|y.words[0],O=S*A,N=67108863&O,U=O/67108864|0;w.words[0]=N;for(var H=1;H<_;H++){for(var Z=U>>>26,D=67108863&U,q=Math.min(H,y.length-1),M=Math.max(0,H-k.length+1);M<=q;M++){var j=H-M|0;Z+=(O=(S=0|k.words[j])*(A=0|y.words[M])+D)/67108864|0,D=67108863&O}w.words[H]=0|D,U=0|Z}return U!==0?w.words[H]=0|U:w.length--,w._strip()}n.prototype.toArrayLike=function(k,y,w){this._strip();var _=this.byteLength(),S=w||Math.max(1,_);l(_<=S,"byte array longer than desired length"),l(S>0,"Requested array length <= 0");var A=function(O,N){return O.allocUnsafe?O.allocUnsafe(N):new O(N)}(k,S);return this["_toArrayLike"+(y==="le"?"LE":"BE")](A,_),A},n.prototype._toArrayLikeLE=function(k,y){for(var w=0,_=0,S=0,A=0;S<this.length;S++){var O=this.words[S]<<A|_;k[w++]=255&O,w<k.length&&(k[w++]=O>>8&255),w<k.length&&(k[w++]=O>>16&255),A===6?(w<k.length&&(k[w++]=O>>24&255),_=0,A=0):(_=O>>>24,A+=2)}if(w<k.length)for(k[w++]=_;w<k.length;)k[w++]=0},n.prototype._toArrayLikeBE=function(k,y){for(var w=k.length-1,_=0,S=0,A=0;S<this.length;S++){var O=this.words[S]<<A|_;k[w--]=255&O,w>=0&&(k[w--]=O>>8&255),w>=0&&(k[w--]=O>>16&255),A===6?(w>=0&&(k[w--]=O>>24&255),_=0,A=0):(_=O>>>24,A+=2)}if(w>=0)for(k[w--]=_;w>=0;)k[w--]=0},Math.clz32?n.prototype._countBits=function(k){return 32-Math.clz32(k)}:n.prototype._countBits=function(k){var y=k,w=0;return y>=4096&&(w+=13,y>>>=13),y>=64&&(w+=7,y>>>=7),y>=8&&(w+=4,y>>>=4),y>=2&&(w+=2,y>>>=2),w+y},n.prototype._zeroBits=function(k){if(k===0)return 26;var y=k,w=0;return(8191&y)==0&&(w+=13,y>>>=13),(127&y)==0&&(w+=7,y>>>=7),(15&y)==0&&(w+=4,y>>>=4),(3&y)==0&&(w+=2,y>>>=2),(1&y)==0&&w++,w},n.prototype.bitLength=function(){var k=this.words[this.length-1],y=this._countBits(k);return 26*(this.length-1)+y},n.prototype.zeroBits=function(){if(this.isZero())return 0;for(var k=0,y=0;y<this.length;y++){var w=this._zeroBits(this.words[y]);if(k+=w,w!==26)break}return k},n.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},n.prototype.toTwos=function(k){return this.negative!==0?this.abs().inotn(k).iaddn(1):this.clone()},n.prototype.fromTwos=function(k){return this.testn(k-1)?this.notn(k).iaddn(1).ineg():this.clone()},n.prototype.isNeg=function(){return this.negative!==0},n.prototype.neg=function(){return this.clone().ineg()},n.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},n.prototype.iuor=function(k){for(;this.length<k.length;)this.words[this.length++]=0;for(var y=0;y<k.length;y++)this.words[y]=this.words[y]|k.words[y];return this._strip()},n.prototype.ior=function(k){return l((this.negative|k.negative)==0),this.iuor(k)},n.prototype.or=function(k){return this.length>k.length?this.clone().ior(k):k.clone().ior(this)},n.prototype.uor=function(k){return this.length>k.length?this.clone().iuor(k):k.clone().iuor(this)},n.prototype.iuand=function(k){var y;y=this.length>k.length?k:this;for(var w=0;w<y.length;w++)this.words[w]=this.words[w]&k.words[w];return this.length=y.length,this._strip()},n.prototype.iand=function(k){return l((this.negative|k.negative)==0),this.iuand(k)},n.prototype.and=function(k){return this.length>k.length?this.clone().iand(k):k.clone().iand(this)},n.prototype.uand=function(k){return this.length>k.length?this.clone().iuand(k):k.clone().iuand(this)},n.prototype.iuxor=function(k){var y,w;this.length>k.length?(y=this,w=k):(y=k,w=this);for(var _=0;_<w.length;_++)this.words[_]=y.words[_]^w.words[_];if(this!==y)for(;_<y.length;_++)this.words[_]=y.words[_];return this.length=y.length,this._strip()},n.prototype.ixor=function(k){return l((this.negative|k.negative)==0),this.iuxor(k)},n.prototype.xor=function(k){return this.length>k.length?this.clone().ixor(k):k.clone().ixor(this)},n.prototype.uxor=function(k){return this.length>k.length?this.clone().iuxor(k):k.clone().iuxor(this)},n.prototype.inotn=function(k){l(typeof k=="number"&&k>=0);var y=0|Math.ceil(k/26),w=k%26;this._expand(y),w>0&&y--;for(var _=0;_<y;_++)this.words[_]=67108863&~this.words[_];return w>0&&(this.words[_]=~this.words[_]&67108863>>26-w),this._strip()},n.prototype.notn=function(k){return this.clone().inotn(k)},n.prototype.setn=function(k,y){l(typeof k=="number"&&k>=0);var w=k/26|0,_=k%26;return this._expand(w+1),this.words[w]=y?this.words[w]|1<<_:this.words[w]&~(1<<_),this._strip()},n.prototype.iadd=function(k){var y,w,_;if(this.negative!==0&&k.negative===0)return this.negative=0,y=this.isub(k),this.negative^=1,this._normSign();if(this.negative===0&&k.negative!==0)return k.negative=0,y=this.isub(k),k.negative=1,y._normSign();this.length>k.length?(w=this,_=k):(w=k,_=this);for(var S=0,A=0;A<_.length;A++)y=(0|w.words[A])+(0|_.words[A])+S,this.words[A]=67108863&y,S=y>>>26;for(;S!==0&&A<w.length;A++)y=(0|w.words[A])+S,this.words[A]=67108863&y,S=y>>>26;if(this.length=w.length,S!==0)this.words[this.length]=S,this.length++;else if(w!==this)for(;A<w.length;A++)this.words[A]=w.words[A];return this},n.prototype.add=function(k){var y;return k.negative!==0&&this.negative===0?(k.negative=0,y=this.sub(k),k.negative^=1,y):k.negative===0&&this.negative!==0?(this.negative=0,y=k.sub(this),this.negative=1,y):this.length>k.length?this.clone().iadd(k):k.clone().iadd(this)},n.prototype.isub=function(k){if(k.negative!==0){k.negative=0;var y=this.iadd(k);return k.negative=1,y._normSign()}if(this.negative!==0)return this.negative=0,this.iadd(k),this.negative=1,this._normSign();var w,_,S=this.cmp(k);if(S===0)return this.negative=0,this.length=1,this.words[0]=0,this;S>0?(w=this,_=k):(w=k,_=this);for(var A=0,O=0;O<_.length;O++)A=(y=(0|w.words[O])-(0|_.words[O])+A)>>26,this.words[O]=67108863&y;for(;A!==0&&O<w.length;O++)A=(y=(0|w.words[O])+A)>>26,this.words[O]=67108863&y;if(A===0&&O<w.length&&w!==this)for(;O<w.length;O++)this.words[O]=w.words[O];return this.length=Math.max(this.length,O),w!==this&&(this.negative=1),this._strip()},n.prototype.sub=function(k){return this.clone().isub(k)};var C=function(k,y,w){var _,S,A,O=k.words,N=y.words,U=w.words,H=0,Z=0|O[0],D=8191&Z,q=Z>>>13,M=0|O[1],j=8191&M,$=M>>>13,K=0|O[2],J=8191&K,X=K>>>13,Q=0|O[3],ee=8191&Q,se=Q>>>13,Y=0|O[4],te=8191&Y,ne=Y>>>13,oe=0|O[5],ae=8191&oe,ce=oe>>>13,me=0|O[6],be=8191&me,ye=me>>>13,Me=0|O[7],Te=8191&Me,fe=Me>>>13,ke=0|O[8],Ee=8191&ke,Ne=ke>>>13,De=0|O[9],je=8191&De,Ce=De>>>13,Oe=0|N[0],Le=8191&Oe,Be=Oe>>>13,ct=0|N[1],wt=8191&ct,We=ct>>>13,dt=0|N[2],ut=8191&dt,qe=dt>>>13,Ot=0|N[3],bt=8191&Ot,Ye=Ot>>>13,pt=0|N[4],kt=8191&pt,Ue=pt>>>13,vt=0|N[5],Ct=8191&vt,it=vt>>>13,le=0|N[6],he=8191&le,ve=le>>>13,Pe=0|N[7],Xe=8191&Pe,Ie=Pe>>>13,et=0|N[8],Ke=8191&et,$e=et>>>13,rt=0|N[9],tt=8191&rt,ot=rt>>>13;w.negative=k.negative^y.negative,w.length=19;var Wt=(H+(_=Math.imul(D,Le))|0)+((8191&(S=(S=Math.imul(D,Be))+Math.imul(q,Le)|0))<<13)|0;H=((A=Math.imul(q,Be))+(S>>>13)|0)+(Wt>>>26)|0,Wt&=67108863,_=Math.imul(j,Le),S=(S=Math.imul(j,Be))+Math.imul($,Le)|0,A=Math.imul($,Be);var Ft=(H+(_=_+Math.imul(D,wt)|0)|0)+((8191&(S=(S=S+Math.imul(D,We)|0)+Math.imul(q,wt)|0))<<13)|0;H=((A=A+Math.imul(q,We)|0)+(S>>>13)|0)+(Ft>>>26)|0,Ft&=67108863,_=Math.imul(J,Le),S=(S=Math.imul(J,Be))+Math.imul(X,Le)|0,A=Math.imul(X,Be),_=_+Math.imul(j,wt)|0,S=(S=S+Math.imul(j,We)|0)+Math.imul($,wt)|0,A=A+Math.imul($,We)|0;var Qt=(H+(_=_+Math.imul(D,ut)|0)|0)+((8191&(S=(S=S+Math.imul(D,qe)|0)+Math.imul(q,ut)|0))<<13)|0;H=((A=A+Math.imul(q,qe)|0)+(S>>>13)|0)+(Qt>>>26)|0,Qt&=67108863,_=Math.imul(ee,Le),S=(S=Math.imul(ee,Be))+Math.imul(se,Le)|0,A=Math.imul(se,Be),_=_+Math.imul(J,wt)|0,S=(S=S+Math.imul(J,We)|0)+Math.imul(X,wt)|0,A=A+Math.imul(X,We)|0,_=_+Math.imul(j,ut)|0,S=(S=S+Math.imul(j,qe)|0)+Math.imul($,ut)|0,A=A+Math.imul($,qe)|0;var Kt=(H+(_=_+Math.imul(D,bt)|0)|0)+((8191&(S=(S=S+Math.imul(D,Ye)|0)+Math.imul(q,bt)|0))<<13)|0;H=((A=A+Math.imul(q,Ye)|0)+(S>>>13)|0)+(Kt>>>26)|0,Kt&=67108863,_=Math.imul(te,Le),S=(S=Math.imul(te,Be))+Math.imul(ne,Le)|0,A=Math.imul(ne,Be),_=_+Math.imul(ee,wt)|0,S=(S=S+Math.imul(ee,We)|0)+Math.imul(se,wt)|0,A=A+Math.imul(se,We)|0,_=_+Math.imul(J,ut)|0,S=(S=S+Math.imul(J,qe)|0)+Math.imul(X,ut)|0,A=A+Math.imul(X,qe)|0,_=_+Math.imul(j,bt)|0,S=(S=S+Math.imul(j,Ye)|0)+Math.imul($,bt)|0,A=A+Math.imul($,Ye)|0;var pr=(H+(_=_+Math.imul(D,kt)|0)|0)+((8191&(S=(S=S+Math.imul(D,Ue)|0)+Math.imul(q,kt)|0))<<13)|0;H=((A=A+Math.imul(q,Ue)|0)+(S>>>13)|0)+(pr>>>26)|0,pr&=67108863,_=Math.imul(ae,Le),S=(S=Math.imul(ae,Be))+Math.imul(ce,Le)|0,A=Math.imul(ce,Be),_=_+Math.imul(te,wt)|0,S=(S=S+Math.imul(te,We)|0)+Math.imul(ne,wt)|0,A=A+Math.imul(ne,We)|0,_=_+Math.imul(ee,ut)|0,S=(S=S+Math.imul(ee,qe)|0)+Math.imul(se,ut)|0,A=A+Math.imul(se,qe)|0,_=_+Math.imul(J,bt)|0,S=(S=S+Math.imul(J,Ye)|0)+Math.imul(X,bt)|0,A=A+Math.imul(X,Ye)|0,_=_+Math.imul(j,kt)|0,S=(S=S+Math.imul(j,Ue)|0)+Math.imul($,kt)|0,A=A+Math.imul($,Ue)|0;var re=(H+(_=_+Math.imul(D,Ct)|0)|0)+((8191&(S=(S=S+Math.imul(D,it)|0)+Math.imul(q,Ct)|0))<<13)|0;H=((A=A+Math.imul(q,it)|0)+(S>>>13)|0)+(re>>>26)|0,re&=67108863,_=Math.imul(be,Le),S=(S=Math.imul(be,Be))+Math.imul(ye,Le)|0,A=Math.imul(ye,Be),_=_+Math.imul(ae,wt)|0,S=(S=S+Math.imul(ae,We)|0)+Math.imul(ce,wt)|0,A=A+Math.imul(ce,We)|0,_=_+Math.imul(te,ut)|0,S=(S=S+Math.imul(te,qe)|0)+Math.imul(ne,ut)|0,A=A+Math.imul(ne,qe)|0,_=_+Math.imul(ee,bt)|0,S=(S=S+Math.imul(ee,Ye)|0)+Math.imul(se,bt)|0,A=A+Math.imul(se,Ye)|0,_=_+Math.imul(J,kt)|0,S=(S=S+Math.imul(J,Ue)|0)+Math.imul(X,kt)|0,A=A+Math.imul(X,Ue)|0,_=_+Math.imul(j,Ct)|0,S=(S=S+Math.imul(j,it)|0)+Math.imul($,Ct)|0,A=A+Math.imul($,it)|0;var pe=(H+(_=_+Math.imul(D,he)|0)|0)+((8191&(S=(S=S+Math.imul(D,ve)|0)+Math.imul(q,he)|0))<<13)|0;H=((A=A+Math.imul(q,ve)|0)+(S>>>13)|0)+(pe>>>26)|0,pe&=67108863,_=Math.imul(Te,Le),S=(S=Math.imul(Te,Be))+Math.imul(fe,Le)|0,A=Math.imul(fe,Be),_=_+Math.imul(be,wt)|0,S=(S=S+Math.imul(be,We)|0)+Math.imul(ye,wt)|0,A=A+Math.imul(ye,We)|0,_=_+Math.imul(ae,ut)|0,S=(S=S+Math.imul(ae,qe)|0)+Math.imul(ce,ut)|0,A=A+Math.imul(ce,qe)|0,_=_+Math.imul(te,bt)|0,S=(S=S+Math.imul(te,Ye)|0)+Math.imul(ne,bt)|0,A=A+Math.imul(ne,Ye)|0,_=_+Math.imul(ee,kt)|0,S=(S=S+Math.imul(ee,Ue)|0)+Math.imul(se,kt)|0,A=A+Math.imul(se,Ue)|0,_=_+Math.imul(J,Ct)|0,S=(S=S+Math.imul(J,it)|0)+Math.imul(X,Ct)|0,A=A+Math.imul(X,it)|0,_=_+Math.imul(j,he)|0,S=(S=S+Math.imul(j,ve)|0)+Math.imul($,he)|0,A=A+Math.imul($,ve)|0;var we=(H+(_=_+Math.imul(D,Xe)|0)|0)+((8191&(S=(S=S+Math.imul(D,Ie)|0)+Math.imul(q,Xe)|0))<<13)|0;H=((A=A+Math.imul(q,Ie)|0)+(S>>>13)|0)+(we>>>26)|0,we&=67108863,_=Math.imul(Ee,Le),S=(S=Math.imul(Ee,Be))+Math.imul(Ne,Le)|0,A=Math.imul(Ne,Be),_=_+Math.imul(Te,wt)|0,S=(S=S+Math.imul(Te,We)|0)+Math.imul(fe,wt)|0,A=A+Math.imul(fe,We)|0,_=_+Math.imul(be,ut)|0,S=(S=S+Math.imul(be,qe)|0)+Math.imul(ye,ut)|0,A=A+Math.imul(ye,qe)|0,_=_+Math.imul(ae,bt)|0,S=(S=S+Math.imul(ae,Ye)|0)+Math.imul(ce,bt)|0,A=A+Math.imul(ce,Ye)|0,_=_+Math.imul(te,kt)|0,S=(S=S+Math.imul(te,Ue)|0)+Math.imul(ne,kt)|0,A=A+Math.imul(ne,Ue)|0,_=_+Math.imul(ee,Ct)|0,S=(S=S+Math.imul(ee,it)|0)+Math.imul(se,Ct)|0,A=A+Math.imul(se,it)|0,_=_+Math.imul(J,he)|0,S=(S=S+Math.imul(J,ve)|0)+Math.imul(X,he)|0,A=A+Math.imul(X,ve)|0,_=_+Math.imul(j,Xe)|0,S=(S=S+Math.imul(j,Ie)|0)+Math.imul($,Xe)|0,A=A+Math.imul($,Ie)|0;var _e=(H+(_=_+Math.imul(D,Ke)|0)|0)+((8191&(S=(S=S+Math.imul(D,$e)|0)+Math.imul(q,Ke)|0))<<13)|0;H=((A=A+Math.imul(q,$e)|0)+(S>>>13)|0)+(_e>>>26)|0,_e&=67108863,_=Math.imul(je,Le),S=(S=Math.imul(je,Be))+Math.imul(Ce,Le)|0,A=Math.imul(Ce,Be),_=_+Math.imul(Ee,wt)|0,S=(S=S+Math.imul(Ee,We)|0)+Math.imul(Ne,wt)|0,A=A+Math.imul(Ne,We)|0,_=_+Math.imul(Te,ut)|0,S=(S=S+Math.imul(Te,qe)|0)+Math.imul(fe,ut)|0,A=A+Math.imul(fe,qe)|0,_=_+Math.imul(be,bt)|0,S=(S=S+Math.imul(be,Ye)|0)+Math.imul(ye,bt)|0,A=A+Math.imul(ye,Ye)|0,_=_+Math.imul(ae,kt)|0,S=(S=S+Math.imul(ae,Ue)|0)+Math.imul(ce,kt)|0,A=A+Math.imul(ce,Ue)|0,_=_+Math.imul(te,Ct)|0,S=(S=S+Math.imul(te,it)|0)+Math.imul(ne,Ct)|0,A=A+Math.imul(ne,it)|0,_=_+Math.imul(ee,he)|0,S=(S=S+Math.imul(ee,ve)|0)+Math.imul(se,he)|0,A=A+Math.imul(se,ve)|0,_=_+Math.imul(J,Xe)|0,S=(S=S+Math.imul(J,Ie)|0)+Math.imul(X,Xe)|0,A=A+Math.imul(X,Ie)|0,_=_+Math.imul(j,Ke)|0,S=(S=S+Math.imul(j,$e)|0)+Math.imul($,Ke)|0,A=A+Math.imul($,$e)|0;var ze=(H+(_=_+Math.imul(D,tt)|0)|0)+((8191&(S=(S=S+Math.imul(D,ot)|0)+Math.imul(q,tt)|0))<<13)|0;H=((A=A+Math.imul(q,ot)|0)+(S>>>13)|0)+(ze>>>26)|0,ze&=67108863,_=Math.imul(je,wt),S=(S=Math.imul(je,We))+Math.imul(Ce,wt)|0,A=Math.imul(Ce,We),_=_+Math.imul(Ee,ut)|0,S=(S=S+Math.imul(Ee,qe)|0)+Math.imul(Ne,ut)|0,A=A+Math.imul(Ne,qe)|0,_=_+Math.imul(Te,bt)|0,S=(S=S+Math.imul(Te,Ye)|0)+Math.imul(fe,bt)|0,A=A+Math.imul(fe,Ye)|0,_=_+Math.imul(be,kt)|0,S=(S=S+Math.imul(be,Ue)|0)+Math.imul(ye,kt)|0,A=A+Math.imul(ye,Ue)|0,_=_+Math.imul(ae,Ct)|0,S=(S=S+Math.imul(ae,it)|0)+Math.imul(ce,Ct)|0,A=A+Math.imul(ce,it)|0,_=_+Math.imul(te,he)|0,S=(S=S+Math.imul(te,ve)|0)+Math.imul(ne,he)|0,A=A+Math.imul(ne,ve)|0,_=_+Math.imul(ee,Xe)|0,S=(S=S+Math.imul(ee,Ie)|0)+Math.imul(se,Xe)|0,A=A+Math.imul(se,Ie)|0,_=_+Math.imul(J,Ke)|0,S=(S=S+Math.imul(J,$e)|0)+Math.imul(X,Ke)|0,A=A+Math.imul(X,$e)|0;var Ae=(H+(_=_+Math.imul(j,tt)|0)|0)+((8191&(S=(S=S+Math.imul(j,ot)|0)+Math.imul($,tt)|0))<<13)|0;H=((A=A+Math.imul($,ot)|0)+(S>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,_=Math.imul(je,ut),S=(S=Math.imul(je,qe))+Math.imul(Ce,ut)|0,A=Math.imul(Ce,qe),_=_+Math.imul(Ee,bt)|0,S=(S=S+Math.imul(Ee,Ye)|0)+Math.imul(Ne,bt)|0,A=A+Math.imul(Ne,Ye)|0,_=_+Math.imul(Te,kt)|0,S=(S=S+Math.imul(Te,Ue)|0)+Math.imul(fe,kt)|0,A=A+Math.imul(fe,Ue)|0,_=_+Math.imul(be,Ct)|0,S=(S=S+Math.imul(be,it)|0)+Math.imul(ye,Ct)|0,A=A+Math.imul(ye,it)|0,_=_+Math.imul(ae,he)|0,S=(S=S+Math.imul(ae,ve)|0)+Math.imul(ce,he)|0,A=A+Math.imul(ce,ve)|0,_=_+Math.imul(te,Xe)|0,S=(S=S+Math.imul(te,Ie)|0)+Math.imul(ne,Xe)|0,A=A+Math.imul(ne,Ie)|0,_=_+Math.imul(ee,Ke)|0,S=(S=S+Math.imul(ee,$e)|0)+Math.imul(se,Ke)|0,A=A+Math.imul(se,$e)|0;var Re=(H+(_=_+Math.imul(J,tt)|0)|0)+((8191&(S=(S=S+Math.imul(J,ot)|0)+Math.imul(X,tt)|0))<<13)|0;H=((A=A+Math.imul(X,ot)|0)+(S>>>13)|0)+(Re>>>26)|0,Re&=67108863,_=Math.imul(je,bt),S=(S=Math.imul(je,Ye))+Math.imul(Ce,bt)|0,A=Math.imul(Ce,Ye),_=_+Math.imul(Ee,kt)|0,S=(S=S+Math.imul(Ee,Ue)|0)+Math.imul(Ne,kt)|0,A=A+Math.imul(Ne,Ue)|0,_=_+Math.imul(Te,Ct)|0,S=(S=S+Math.imul(Te,it)|0)+Math.imul(fe,Ct)|0,A=A+Math.imul(fe,it)|0,_=_+Math.imul(be,he)|0,S=(S=S+Math.imul(be,ve)|0)+Math.imul(ye,he)|0,A=A+Math.imul(ye,ve)|0,_=_+Math.imul(ae,Xe)|0,S=(S=S+Math.imul(ae,Ie)|0)+Math.imul(ce,Xe)|0,A=A+Math.imul(ce,Ie)|0,_=_+Math.imul(te,Ke)|0,S=(S=S+Math.imul(te,$e)|0)+Math.imul(ne,Ke)|0,A=A+Math.imul(ne,$e)|0;var ht=(H+(_=_+Math.imul(ee,tt)|0)|0)+((8191&(S=(S=S+Math.imul(ee,ot)|0)+Math.imul(se,tt)|0))<<13)|0;H=((A=A+Math.imul(se,ot)|0)+(S>>>13)|0)+(ht>>>26)|0,ht&=67108863,_=Math.imul(je,kt),S=(S=Math.imul(je,Ue))+Math.imul(Ce,kt)|0,A=Math.imul(Ce,Ue),_=_+Math.imul(Ee,Ct)|0,S=(S=S+Math.imul(Ee,it)|0)+Math.imul(Ne,Ct)|0,A=A+Math.imul(Ne,it)|0,_=_+Math.imul(Te,he)|0,S=(S=S+Math.imul(Te,ve)|0)+Math.imul(fe,he)|0,A=A+Math.imul(fe,ve)|0,_=_+Math.imul(be,Xe)|0,S=(S=S+Math.imul(be,Ie)|0)+Math.imul(ye,Xe)|0,A=A+Math.imul(ye,Ie)|0,_=_+Math.imul(ae,Ke)|0,S=(S=S+Math.imul(ae,$e)|0)+Math.imul(ce,Ke)|0,A=A+Math.imul(ce,$e)|0;var st=(H+(_=_+Math.imul(te,tt)|0)|0)+((8191&(S=(S=S+Math.imul(te,ot)|0)+Math.imul(ne,tt)|0))<<13)|0;H=((A=A+Math.imul(ne,ot)|0)+(S>>>13)|0)+(st>>>26)|0,st&=67108863,_=Math.imul(je,Ct),S=(S=Math.imul(je,it))+Math.imul(Ce,Ct)|0,A=Math.imul(Ce,it),_=_+Math.imul(Ee,he)|0,S=(S=S+Math.imul(Ee,ve)|0)+Math.imul(Ne,he)|0,A=A+Math.imul(Ne,ve)|0,_=_+Math.imul(Te,Xe)|0,S=(S=S+Math.imul(Te,Ie)|0)+Math.imul(fe,Xe)|0,A=A+Math.imul(fe,Ie)|0,_=_+Math.imul(be,Ke)|0,S=(S=S+Math.imul(be,$e)|0)+Math.imul(ye,Ke)|0,A=A+Math.imul(ye,$e)|0;var at=(H+(_=_+Math.imul(ae,tt)|0)|0)+((8191&(S=(S=S+Math.imul(ae,ot)|0)+Math.imul(ce,tt)|0))<<13)|0;H=((A=A+Math.imul(ce,ot)|0)+(S>>>13)|0)+(at>>>26)|0,at&=67108863,_=Math.imul(je,he),S=(S=Math.imul(je,ve))+Math.imul(Ce,he)|0,A=Math.imul(Ce,ve),_=_+Math.imul(Ee,Xe)|0,S=(S=S+Math.imul(Ee,Ie)|0)+Math.imul(Ne,Xe)|0,A=A+Math.imul(Ne,Ie)|0,_=_+Math.imul(Te,Ke)|0,S=(S=S+Math.imul(Te,$e)|0)+Math.imul(fe,Ke)|0,A=A+Math.imul(fe,$e)|0;var Ge=(H+(_=_+Math.imul(be,tt)|0)|0)+((8191&(S=(S=S+Math.imul(be,ot)|0)+Math.imul(ye,tt)|0))<<13)|0;H=((A=A+Math.imul(ye,ot)|0)+(S>>>13)|0)+(Ge>>>26)|0,Ge&=67108863,_=Math.imul(je,Xe),S=(S=Math.imul(je,Ie))+Math.imul(Ce,Xe)|0,A=Math.imul(Ce,Ie),_=_+Math.imul(Ee,Ke)|0,S=(S=S+Math.imul(Ee,$e)|0)+Math.imul(Ne,Ke)|0,A=A+Math.imul(Ne,$e)|0;var xt=(H+(_=_+Math.imul(Te,tt)|0)|0)+((8191&(S=(S=S+Math.imul(Te,ot)|0)+Math.imul(fe,tt)|0))<<13)|0;H=((A=A+Math.imul(fe,ot)|0)+(S>>>13)|0)+(xt>>>26)|0,xt&=67108863,_=Math.imul(je,Ke),S=(S=Math.imul(je,$e))+Math.imul(Ce,Ke)|0,A=Math.imul(Ce,$e);var _t=(H+(_=_+Math.imul(Ee,tt)|0)|0)+((8191&(S=(S=S+Math.imul(Ee,ot)|0)+Math.imul(Ne,tt)|0))<<13)|0;H=((A=A+Math.imul(Ne,ot)|0)+(S>>>13)|0)+(_t>>>26)|0,_t&=67108863;var Tt=(H+(_=Math.imul(je,tt))|0)+((8191&(S=(S=Math.imul(je,ot))+Math.imul(Ce,tt)|0))<<13)|0;return H=((A=Math.imul(Ce,ot))+(S>>>13)|0)+(Tt>>>26)|0,Tt&=67108863,U[0]=Wt,U[1]=Ft,U[2]=Qt,U[3]=Kt,U[4]=pr,U[5]=re,U[6]=pe,U[7]=we,U[8]=_e,U[9]=ze,U[10]=Ae,U[11]=Re,U[12]=ht,U[13]=st,U[14]=at,U[15]=Ge,U[16]=xt,U[17]=_t,U[18]=Tt,H!==0&&(U[19]=H,w.length++),w};function T(k,y,w){w.negative=y.negative^k.negative,w.length=k.length+y.length;for(var _=0,S=0,A=0;A<w.length-1;A++){var O=S;S=0;for(var N=67108863&_,U=Math.min(A,y.length-1),H=Math.max(0,A-k.length+1);H<=U;H++){var Z=A-H,D=(0|k.words[Z])*(0|y.words[H]),q=67108863&D;N=67108863&(q=q+N|0),S+=(O=(O=O+(D/67108864|0)|0)+(q>>>26)|0)>>>26,O&=67108863}w.words[A]=N,_=O,O=S}return _!==0?w.words[A]=_:w.length--,w._strip()}function R(k,y,w){return T(k,y,w)}Math.imul||(C=x),n.prototype.mulTo=function(k,y){var w=this.length+k.length;return this.length===10&&k.length===10?C(this,k,y):w<63?x(this,k,y):w<1024?T(this,k,y):R(this,k,y)},n.prototype.mul=function(k){var y=new n(null);return y.words=new Array(this.length+k.length),this.mulTo(k,y)},n.prototype.mulf=function(k){var y=new n(null);return y.words=new Array(this.length+k.length),R(this,k,y)},n.prototype.imul=function(k){return this.clone().mulTo(k,this)},n.prototype.imuln=function(k){var y=k<0;y&&(k=-k),l(typeof k=="number"),l(k<67108864);for(var w=0,_=0;_<this.length;_++){var S=(0|this.words[_])*k,A=(67108863&S)+(67108863&w);w>>=26,w+=S/67108864|0,w+=A>>>26,this.words[_]=67108863&A}return w!==0&&(this.words[_]=w,this.length++),y?this.ineg():this},n.prototype.muln=function(k){return this.clone().imuln(k)},n.prototype.sqr=function(){return this.mul(this)},n.prototype.isqr=function(){return this.imul(this.clone())},n.prototype.pow=function(k){var y=function(A){for(var O=new Array(A.bitLength()),N=0;N<O.length;N++){var U=N/26|0,H=N%26;O[N]=A.words[U]>>>H&1}return O}(k);if(y.length===0)return new n(1);for(var w=this,_=0;_<y.length&&y[_]===0;_++,w=w.sqr());if(++_<y.length)for(var S=w.sqr();_<y.length;_++,S=S.sqr())y[_]!==0&&(w=w.mul(S));return w},n.prototype.iushln=function(k){l(typeof k=="number"&&k>=0);var y,w=k%26,_=(k-w)/26,S=67108863>>>26-w<<26-w;if(w!==0){var A=0;for(y=0;y<this.length;y++){var O=this.words[y]&S,N=(0|this.words[y])-O<<w;this.words[y]=N|A,A=O>>>26-w}A&&(this.words[y]=A,this.length++)}if(_!==0){for(y=this.length-1;y>=0;y--)this.words[y+_]=this.words[y];for(y=0;y<_;y++)this.words[y]=0;this.length+=_}return this._strip()},n.prototype.ishln=function(k){return l(this.negative===0),this.iushln(k)},n.prototype.iushrn=function(k,y,w){var _;l(typeof k=="number"&&k>=0),_=y?(y-y%26)/26:0;var S=k%26,A=Math.min((k-S)/26,this.length),O=67108863^67108863>>>S<<S,N=w;if(_-=A,_=Math.max(0,_),N){for(var U=0;U<A;U++)N.words[U]=this.words[U];N.length=A}if(A!==0)if(this.length>A)for(this.length-=A,U=0;U<this.length;U++)this.words[U]=this.words[U+A];else this.words[0]=0,this.length=1;var H=0;for(U=this.length-1;U>=0&&(H!==0||U>=_);U--){var Z=0|this.words[U];this.words[U]=H<<26-S|Z>>>S,H=Z&O}return N&&H!==0&&(N.words[N.length++]=H),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},n.prototype.ishrn=function(k,y,w){return l(this.negative===0),this.iushrn(k,y,w)},n.prototype.shln=function(k){return this.clone().ishln(k)},n.prototype.ushln=function(k){return this.clone().iushln(k)},n.prototype.shrn=function(k){return this.clone().ishrn(k)},n.prototype.ushrn=function(k){return this.clone().iushrn(k)},n.prototype.testn=function(k){l(typeof k=="number"&&k>=0);var y=k%26,w=(k-y)/26,_=1<<y;return!(this.length<=w)&&!!(this.words[w]&_)},n.prototype.imaskn=function(k){l(typeof k=="number"&&k>=0);var y=k%26,w=(k-y)/26;if(l(this.negative===0,"imaskn works only with positive numbers"),this.length<=w)return this;if(y!==0&&w++,this.length=Math.min(w,this.length),y!==0){var _=67108863^67108863>>>y<<y;this.words[this.length-1]&=_}return this._strip()},n.prototype.maskn=function(k){return this.clone().imaskn(k)},n.prototype.iaddn=function(k){return l(typeof k=="number"),l(k<67108864),k<0?this.isubn(-k):this.negative!==0?this.length===1&&(0|this.words[0])<=k?(this.words[0]=k-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(k),this.negative=1,this):this._iaddn(k)},n.prototype._iaddn=function(k){this.words[0]+=k;for(var y=0;y<this.length&&this.words[y]>=67108864;y++)this.words[y]-=67108864,y===this.length-1?this.words[y+1]=1:this.words[y+1]++;return this.length=Math.max(this.length,y+1),this},n.prototype.isubn=function(k){if(l(typeof k=="number"),l(k<67108864),k<0)return this.iaddn(-k);if(this.negative!==0)return this.negative=0,this.iaddn(k),this.negative=1,this;if(this.words[0]-=k,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var y=0;y<this.length&&this.words[y]<0;y++)this.words[y]+=67108864,this.words[y+1]-=1;return this._strip()},n.prototype.addn=function(k){return this.clone().iaddn(k)},n.prototype.subn=function(k){return this.clone().isubn(k)},n.prototype.iabs=function(){return this.negative=0,this},n.prototype.abs=function(){return this.clone().iabs()},n.prototype._ishlnsubmul=function(k,y,w){var _,S,A=k.length+w;this._expand(A);var O=0;for(_=0;_<k.length;_++){S=(0|this.words[_+w])+O;var N=(0|k.words[_])*y;O=((S-=67108863&N)>>26)-(N/67108864|0),this.words[_+w]=67108863&S}for(;_<this.length-w;_++)O=(S=(0|this.words[_+w])+O)>>26,this.words[_+w]=67108863&S;if(O===0)return this._strip();for(l(O===-1),O=0,_=0;_<this.length;_++)O=(S=-(0|this.words[_])+O)>>26,this.words[_]=67108863&S;return this.negative=1,this._strip()},n.prototype._wordDiv=function(k,y){var w=(this.length,k.length),_=this.clone(),S=k,A=0|S.words[S.length-1];(w=26-this._countBits(A))!==0&&(S=S.ushln(w),_.iushln(w),A=0|S.words[S.length-1]);var O,N=_.length-S.length;if(y!=="mod"){(O=new n(null)).length=N+1,O.words=new Array(O.length);for(var U=0;U<O.length;U++)O.words[U]=0}var H=_.clone()._ishlnsubmul(S,1,N);H.negative===0&&(_=H,O&&(O.words[N]=1));for(var Z=N-1;Z>=0;Z--){var D=67108864*(0|_.words[S.length+Z])+(0|_.words[S.length+Z-1]);for(D=Math.min(D/A|0,67108863),_._ishlnsubmul(S,D,Z);_.negative!==0;)D--,_.negative=0,_._ishlnsubmul(S,1,Z),_.isZero()||(_.negative^=1);O&&(O.words[Z]=D)}return O&&O._strip(),_._strip(),y!=="div"&&w!==0&&_.iushrn(w),{div:O||null,mod:_}},n.prototype.divmod=function(k,y,w){return l(!k.isZero()),this.isZero()?{div:new n(0),mod:new n(0)}:this.negative!==0&&k.negative===0?(A=this.neg().divmod(k,y),y!=="mod"&&(_=A.div.neg()),y!=="div"&&(S=A.mod.neg(),w&&S.negative!==0&&S.iadd(k)),{div:_,mod:S}):this.negative===0&&k.negative!==0?(A=this.divmod(k.neg(),y),y!=="mod"&&(_=A.div.neg()),{div:_,mod:A.mod}):(this.negative&k.negative)!=0?(A=this.neg().divmod(k.neg(),y),y!=="div"&&(S=A.mod.neg(),w&&S.negative!==0&&S.isub(k)),{div:A.div,mod:S}):k.length>this.length||this.cmp(k)<0?{div:new n(0),mod:this}:k.length===1?y==="div"?{div:this.divn(k.words[0]),mod:null}:y==="mod"?{div:null,mod:new n(this.modrn(k.words[0]))}:{div:this.divn(k.words[0]),mod:new n(this.modrn(k.words[0]))}:this._wordDiv(k,y);var _,S,A},n.prototype.div=function(k){return this.divmod(k,"div",!1).div},n.prototype.mod=function(k){return this.divmod(k,"mod",!1).mod},n.prototype.umod=function(k){return this.divmod(k,"mod",!0).mod},n.prototype.divRound=function(k){var y=this.divmod(k);if(y.mod.isZero())return y.div;var w=y.div.negative!==0?y.mod.isub(k):y.mod,_=k.ushrn(1),S=k.andln(1),A=w.cmp(_);return A<0||S===1&&A===0?y.div:y.div.negative!==0?y.div.isubn(1):y.div.iaddn(1)},n.prototype.modrn=function(k){var y=k<0;y&&(k=-k),l(k<=67108863);for(var w=(1<<26)%k,_=0,S=this.length-1;S>=0;S--)_=(w*_+(0|this.words[S]))%k;return y?-_:_},n.prototype.modn=function(k){return this.modrn(k)},n.prototype.idivn=function(k){var y=k<0;y&&(k=-k),l(k<=67108863);for(var w=0,_=this.length-1;_>=0;_--){var S=(0|this.words[_])+67108864*w;this.words[_]=S/k|0,w=S%k}return this._strip(),y?this.ineg():this},n.prototype.divn=function(k){return this.clone().idivn(k)},n.prototype.egcd=function(k){l(k.negative===0),l(!k.isZero());var y=this,w=k.clone();y=y.negative!==0?y.umod(k):y.clone();for(var _=new n(1),S=new n(0),A=new n(0),O=new n(1),N=0;y.isEven()&&w.isEven();)y.iushrn(1),w.iushrn(1),++N;for(var U=w.clone(),H=y.clone();!y.isZero();){for(var Z=0,D=1;(y.words[0]&D)==0&&Z<26;++Z,D<<=1);if(Z>0)for(y.iushrn(Z);Z-- >0;)(_.isOdd()||S.isOdd())&&(_.iadd(U),S.isub(H)),_.iushrn(1),S.iushrn(1);for(var q=0,M=1;(w.words[0]&M)==0&&q<26;++q,M<<=1);if(q>0)for(w.iushrn(q);q-- >0;)(A.isOdd()||O.isOdd())&&(A.iadd(U),O.isub(H)),A.iushrn(1),O.iushrn(1);y.cmp(w)>=0?(y.isub(w),_.isub(A),S.isub(O)):(w.isub(y),A.isub(_),O.isub(S))}return{a:A,b:O,gcd:w.iushln(N)}},n.prototype._invmp=function(k){l(k.negative===0),l(!k.isZero());var y=this,w=k.clone();y=y.negative!==0?y.umod(k):y.clone();for(var _,S=new n(1),A=new n(0),O=w.clone();y.cmpn(1)>0&&w.cmpn(1)>0;){for(var N=0,U=1;(y.words[0]&U)==0&&N<26;++N,U<<=1);if(N>0)for(y.iushrn(N);N-- >0;)S.isOdd()&&S.iadd(O),S.iushrn(1);for(var H=0,Z=1;(w.words[0]&Z)==0&&H<26;++H,Z<<=1);if(H>0)for(w.iushrn(H);H-- >0;)A.isOdd()&&A.iadd(O),A.iushrn(1);y.cmp(w)>=0?(y.isub(w),S.isub(A)):(w.isub(y),A.isub(S))}return(_=y.cmpn(1)===0?S:A).cmpn(0)<0&&_.iadd(k),_},n.prototype.gcd=function(k){if(this.isZero())return k.abs();if(k.isZero())return this.abs();var y=this.clone(),w=k.clone();y.negative=0,w.negative=0;for(var _=0;y.isEven()&&w.isEven();_++)y.iushrn(1),w.iushrn(1);for(;;){for(;y.isEven();)y.iushrn(1);for(;w.isEven();)w.iushrn(1);var S=y.cmp(w);if(S<0){var A=y;y=w,w=A}else if(S===0||w.cmpn(1)===0)break;y.isub(w)}return w.iushln(_)},n.prototype.invm=function(k){return this.egcd(k).a.umod(k)},n.prototype.isEven=function(){return(1&this.words[0])==0},n.prototype.isOdd=function(){return(1&this.words[0])==1},n.prototype.andln=function(k){return this.words[0]&k},n.prototype.bincn=function(k){l(typeof k=="number");var y=k%26,w=(k-y)/26,_=1<<y;if(this.length<=w)return this._expand(w+1),this.words[w]|=_,this;for(var S=_,A=w;S!==0&&A<this.length;A++){var O=0|this.words[A];S=(O+=S)>>>26,O&=67108863,this.words[A]=O}return S!==0&&(this.words[A]=S,this.length++),this},n.prototype.isZero=function(){return this.length===1&&this.words[0]===0},n.prototype.cmpn=function(k){var y,w=k<0;if(this.negative!==0&&!w)return-1;if(this.negative===0&&w)return 1;if(this._strip(),this.length>1)y=1;else{w&&(k=-k),l(k<=67108863,"Number is too big");var _=0|this.words[0];y=_===k?0:_<k?-1:1}return this.negative!==0?0|-y:y},n.prototype.cmp=function(k){if(this.negative!==0&&k.negative===0)return-1;if(this.negative===0&&k.negative!==0)return 1;var y=this.ucmp(k);return this.negative!==0?0|-y:y},n.prototype.ucmp=function(k){if(this.length>k.length)return 1;if(this.length<k.length)return-1;for(var y=0,w=this.length-1;w>=0;w--){var _=0|this.words[w],S=0|k.words[w];if(_!==S){_<S?y=-1:_>S&&(y=1);break}}return y},n.prototype.gtn=function(k){return this.cmpn(k)===1},n.prototype.gt=function(k){return this.cmp(k)===1},n.prototype.gten=function(k){return this.cmpn(k)>=0},n.prototype.gte=function(k){return this.cmp(k)>=0},n.prototype.ltn=function(k){return this.cmpn(k)===-1},n.prototype.lt=function(k){return this.cmp(k)===-1},n.prototype.lten=function(k){return this.cmpn(k)<=0},n.prototype.lte=function(k){return this.cmp(k)<=0},n.prototype.eqn=function(k){return this.cmpn(k)===0},n.prototype.eq=function(k){return this.cmp(k)===0},n.red=function(k){return new E(k)},n.prototype.toRed=function(k){return l(!this.red,"Already a number in reduction context"),l(this.negative===0,"red works only with positives"),k.convertTo(this)._forceRed(k)},n.prototype.fromRed=function(){return l(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},n.prototype._forceRed=function(k){return this.red=k,this},n.prototype.forceRed=function(k){return l(!this.red,"Already a number in reduction context"),this._forceRed(k)},n.prototype.redAdd=function(k){return l(this.red,"redAdd works only with red numbers"),this.red.add(this,k)},n.prototype.redIAdd=function(k){return l(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,k)},n.prototype.redSub=function(k){return l(this.red,"redSub works only with red numbers"),this.red.sub(this,k)},n.prototype.redISub=function(k){return l(this.red,"redISub works only with red numbers"),this.red.isub(this,k)},n.prototype.redShl=function(k){return l(this.red,"redShl works only with red numbers"),this.red.shl(this,k)},n.prototype.redMul=function(k){return l(this.red,"redMul works only with red numbers"),this.red._verify2(this,k),this.red.mul(this,k)},n.prototype.redIMul=function(k){return l(this.red,"redMul works only with red numbers"),this.red._verify2(this,k),this.red.imul(this,k)},n.prototype.redSqr=function(){return l(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},n.prototype.redISqr=function(){return l(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},n.prototype.redSqrt=function(){return l(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},n.prototype.redInvm=function(){return l(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},n.prototype.redNeg=function(){return l(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},n.prototype.redPow=function(k){return l(this.red&&!k.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,k)};var B={k256:null,p224:null,p192:null,p25519:null};function I(k,y){this.name=k,this.p=new n(y,16),this.n=this.p.bitLength(),this.k=new n(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function F(){I.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function L(){I.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function V(){I.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function z(){I.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function E(k){if(typeof k=="string"){var y=n._prime(k);this.m=y.p,this.prime=y}else l(k.gtn(1),"modulus must be greater than 1"),this.m=k,this.prime=null}function P(k){E.call(this,k),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new n(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}I.prototype._tmp=function(){var k=new n(null);return k.words=new Array(Math.ceil(this.n/13)),k},I.prototype.ireduce=function(k){var y,w=k;do this.split(w,this.tmp),y=(w=(w=this.imulK(w)).iadd(this.tmp)).bitLength();while(y>this.n);var _=y<this.n?-1:w.ucmp(this.p);return _===0?(w.words[0]=0,w.length=1):_>0?w.isub(this.p):w.strip!==void 0?w.strip():w._strip(),w},I.prototype.split=function(k,y){k.iushrn(this.n,0,y)},I.prototype.imulK=function(k){return k.imul(this.k)},i(F,I),F.prototype.split=function(k,y){for(var w=Math.min(k.length,9),_=0;_<w;_++)y.words[_]=k.words[_];if(y.length=w,k.length<=9)return k.words[0]=0,void(k.length=1);var S=k.words[9];for(y.words[y.length++]=4194303&S,_=10;_<k.length;_++){var A=0|k.words[_];k.words[_-10]=(4194303&A)<<4|S>>>22,S=A}S>>>=22,k.words[_-10]=S,S===0&&k.length>10?k.length-=10:k.length-=9},F.prototype.imulK=function(k){k.words[k.length]=0,k.words[k.length+1]=0,k.length+=2;for(var y=0,w=0;w<k.length;w++){var _=0|k.words[w];y+=977*_,k.words[w]=67108863&y,y=64*_+(y/67108864|0)}return k.words[k.length-1]===0&&(k.length--,k.words[k.length-1]===0&&k.length--),k},i(L,I),i(V,I),i(z,I),z.prototype.imulK=function(k){for(var y=0,w=0;w<k.length;w++){var _=19*(0|k.words[w])+y,S=67108863&_;_>>>=26,k.words[w]=S,y=_}return y!==0&&(k.words[k.length++]=y),k},n._prime=function(k){if(B[k])return B[k];var y;if(k==="k256")y=new F;else if(k==="p224")y=new L;else if(k==="p192")y=new V;else{if(k!=="p25519")throw new Error("Unknown prime "+k);y=new z}return B[k]=y,y},E.prototype._verify1=function(k){l(k.negative===0,"red works only with positives"),l(k.red,"red works only with red numbers")},E.prototype._verify2=function(k,y){l((k.negative|y.negative)==0,"red works only with positives"),l(k.red&&k.red===y.red,"red works only with red numbers")},E.prototype.imod=function(k){return this.prime?this.prime.ireduce(k)._forceRed(this):(m(k,k.umod(this.m)._forceRed(this)),k)},E.prototype.neg=function(k){return k.isZero()?k.clone():this.m.sub(k)._forceRed(this)},E.prototype.add=function(k,y){this._verify2(k,y);var w=k.add(y);return w.cmp(this.m)>=0&&w.isub(this.m),w._forceRed(this)},E.prototype.iadd=function(k,y){this._verify2(k,y);var w=k.iadd(y);return w.cmp(this.m)>=0&&w.isub(this.m),w},E.prototype.sub=function(k,y){this._verify2(k,y);var w=k.sub(y);return w.cmpn(0)<0&&w.iadd(this.m),w._forceRed(this)},E.prototype.isub=function(k,y){this._verify2(k,y);var w=k.isub(y);return w.cmpn(0)<0&&w.iadd(this.m),w},E.prototype.shl=function(k,y){return this._verify1(k),this.imod(k.ushln(y))},E.prototype.imul=function(k,y){return this._verify2(k,y),this.imod(k.imul(y))},E.prototype.mul=function(k,y){return this._verify2(k,y),this.imod(k.mul(y))},E.prototype.isqr=function(k){return this.imul(k,k.clone())},E.prototype.sqr=function(k){return this.mul(k,k)},E.prototype.sqrt=function(k){if(k.isZero())return k.clone();var y=this.m.andln(3);if(l(y%2==1),y===3){var w=this.m.add(new n(1)).iushrn(2);return this.pow(k,w)}for(var _=this.m.subn(1),S=0;!_.isZero()&&_.andln(1)===0;)S++,_.iushrn(1);l(!_.isZero());var A=new n(1).toRed(this),O=A.redNeg(),N=this.m.subn(1).iushrn(1),U=this.m.bitLength();for(U=new n(2*U*U).toRed(this);this.pow(U,N).cmp(O)!==0;)U.redIAdd(O);for(var H=this.pow(U,_),Z=this.pow(k,_.addn(1).iushrn(1)),D=this.pow(k,_),q=S;D.cmp(A)!==0;){for(var M=D,j=0;M.cmp(A)!==0;j++)M=M.redSqr();l(j<q);var $=this.pow(H,new n(1).iushln(q-j-1));Z=Z.redMul($),H=$.redSqr(),D=D.redMul(H),q=j}return Z},E.prototype.invm=function(k){var y=k._invmp(this.m);return y.negative!==0?(y.negative=0,this.imod(y).redNeg()):this.imod(y)},E.prototype.pow=function(k,y){if(y.isZero())return new n(1).toRed(this);if(y.cmpn(1)===0)return k.clone();var w=new Array(16);w[0]=new n(1).toRed(this),w[1]=k;for(var _=2;_<w.length;_++)w[_]=this.mul(w[_-1],k);var S=w[0],A=0,O=0,N=y.bitLength()%26;for(N===0&&(N=26),_=y.length-1;_>=0;_--){for(var U=y.words[_],H=N-1;H>=0;H--){var Z=U>>H&1;S!==w[0]&&(S=this.sqr(S)),Z!==0||A!==0?(A<<=1,A|=Z,(++O===4||_===0&&H===0)&&(S=this.mul(S,w[A]),O=0,A=0)):O=0}N=26}return S},E.prototype.convertTo=function(k){var y=k.umod(this.m);return y===k?y.clone():y},E.prototype.convertFrom=function(k){var y=k.clone();return y.red=null,y},n.mont=function(k){return new P(k)},i(P,E),P.prototype.convertTo=function(k){return this.imod(k.ushln(this.shift))},P.prototype.convertFrom=function(k){var y=this.imod(k.mul(this.rinv));return y.red=null,y},P.prototype.imul=function(k,y){if(k.isZero()||y.isZero())return k.words[0]=0,k.length=1,k;var w=k.imul(y),_=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),S=w.isub(_).iushrn(this.shift),A=S;return S.cmp(this.m)>=0?A=S.isub(this.m):S.cmpn(0)<0&&(A=S.iadd(this.m)),A._forceRed(this)},P.prototype.mul=function(k,y){if(k.isZero()||y.isZero())return new n(0)._forceRed(this);var w=k.mul(y),_=w.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),S=w.isub(_).iushrn(this.shift),A=S;return S.cmp(this.m)>=0?A=S.isub(this.m):S.cmpn(0)<0&&(A=S.iadd(this.m)),A._forceRed(this)},P.prototype.invm=function(k){return this.imod(k._invmp(this.m).mul(this.r2))._forceRed(this)}})(a===void 0||a)},{buffer:188}],187:[function(e,a,f){var c;function s(i){this.rand=i}if(a.exports=function(i){return c||(c=new s(null)),c.generate(i)},a.exports.Rand=s,s.prototype.generate=function(i){return this._rand(i)},s.prototype._rand=function(i){if(this.rand.getBytes)return this.rand.getBytes(i);for(var n=new Uint8Array(i),o=0;o<n.length;o++)n[o]=this.rand.getByte();return n},typeof self=="object")self.crypto&&self.crypto.getRandomValues?s.prototype._rand=function(i){var n=new Uint8Array(i);return self.crypto.getRandomValues(n),n}:self.msCrypto&&self.msCrypto.getRandomValues?s.prototype._rand=function(i){var n=new Uint8Array(i);return self.msCrypto.getRandomValues(n),n}:typeof window=="object"&&(s.prototype._rand=function(){throw new Error("Not implemented yet")});else try{var l=e("crypto");if(typeof l.randomBytes!="function")throw new Error("Not supported");s.prototype._rand=function(i){return l.randomBytes(i)}}catch{}},{crypto:188}],188:[function(e,a,f){},{}],189:[function(e,a,f){var c=e("safe-buffer").Buffer;function s(u){c.isBuffer(u)||(u=c.from(u));for(var d=u.length/4|0,m=new Array(d),b=0;b<d;b++)m[b]=u.readUInt32BE(4*b);return m}function l(u){for(;0<u.length;u++)u[0]=0}function i(u,d,m,b,p){for(var v,g,x,C,T=m[0],R=m[1],B=m[2],I=m[3],F=u[0]^d[0],L=u[1]^d[1],V=u[2]^d[2],z=u[3]^d[3],E=4,P=1;P<p;P++)v=T[F>>>24]^R[L>>>16&255]^B[V>>>8&255]^I[255&z]^d[E++],g=T[L>>>24]^R[V>>>16&255]^B[z>>>8&255]^I[255&F]^d[E++],x=T[V>>>24]^R[z>>>16&255]^B[F>>>8&255]^I[255&L]^d[E++],C=T[z>>>24]^R[F>>>16&255]^B[L>>>8&255]^I[255&V]^d[E++],F=v,L=g,V=x,z=C;return v=(b[F>>>24]<<24|b[L>>>16&255]<<16|b[V>>>8&255]<<8|b[255&z])^d[E++],g=(b[L>>>24]<<24|b[V>>>16&255]<<16|b[z>>>8&255]<<8|b[255&F])^d[E++],x=(b[V>>>24]<<24|b[z>>>16&255]<<16|b[F>>>8&255]<<8|b[255&L])^d[E++],C=(b[z>>>24]<<24|b[F>>>16&255]<<16|b[L>>>8&255]<<8|b[255&V])^d[E++],[v>>>=0,g>>>=0,x>>>=0,C>>>=0]}var n=[0,1,2,4,8,16,32,64,128,27,54],o=function(){for(var u=new Array(256),d=0;d<256;d++)u[d]=d<128?d<<1:d<<1^283;for(var m=[],b=[],p=[[],[],[],[]],v=[[],[],[],[]],g=0,x=0,C=0;C<256;++C){var T=x^x<<1^x<<2^x<<3^x<<4;T=T>>>8^255&T^99,m[g]=T,b[T]=g;var R=u[g],B=u[R],I=u[B],F=257*u[T]^16843008*T;p[0][g]=F<<24|F>>>8,p[1][g]=F<<16|F>>>16,p[2][g]=F<<8|F>>>24,p[3][g]=F,F=16843009*I^65537*B^257*R^16843008*g,v[0][T]=F<<24|F>>>8,v[1][T]=F<<16|F>>>16,v[2][T]=F<<8|F>>>24,v[3][T]=F,g===0?g=x=1:(g=R^u[u[u[I^R]]],x^=u[u[x]])}return{SBOX:m,INV_SBOX:b,SUB_MIX:p,INV_SUB_MIX:v}}();function h(u){this._key=s(u),this._reset()}h.blockSize=16,h.keySize=32,h.prototype.blockSize=h.blockSize,h.prototype.keySize=h.keySize,h.prototype._reset=function(){for(var u=this._key,d=u.length,m=d+6,b=4*(m+1),p=[],v=0;v<d;v++)p[v]=u[v];for(v=d;v<b;v++){var g=p[v-1];v%d==0?(g=g<<8|g>>>24,g=o.SBOX[g>>>24]<<24|o.SBOX[g>>>16&255]<<16|o.SBOX[g>>>8&255]<<8|o.SBOX[255&g],g^=n[v/d|0]<<24):d>6&&v%d==4&&(g=o.SBOX[g>>>24]<<24|o.SBOX[g>>>16&255]<<16|o.SBOX[g>>>8&255]<<8|o.SBOX[255&g]),p[v]=p[v-d]^g}for(var x=[],C=0;C<b;C++){var T=b-C,R=p[T-(C%4?0:4)];x[C]=C<4||T<=4?R:o.INV_SUB_MIX[0][o.SBOX[R>>>24]]^o.INV_SUB_MIX[1][o.SBOX[R>>>16&255]]^o.INV_SUB_MIX[2][o.SBOX[R>>>8&255]]^o.INV_SUB_MIX[3][o.SBOX[255&R]]}this._nRounds=m,this._keySchedule=p,this._invKeySchedule=x},h.prototype.encryptBlockRaw=function(u){return i(u=s(u),this._keySchedule,o.SUB_MIX,o.SBOX,this._nRounds)},h.prototype.encryptBlock=function(u){var d=this.encryptBlockRaw(u),m=c.allocUnsafe(16);return m.writeUInt32BE(d[0],0),m.writeUInt32BE(d[1],4),m.writeUInt32BE(d[2],8),m.writeUInt32BE(d[3],12),m},h.prototype.decryptBlock=function(u){var d=(u=s(u))[1];u[1]=u[3],u[3]=d;var m=i(u,this._invKeySchedule,o.INV_SUB_MIX,o.INV_SBOX,this._nRounds),b=c.allocUnsafe(16);return b.writeUInt32BE(m[0],0),b.writeUInt32BE(m[3],4),b.writeUInt32BE(m[2],8),b.writeUInt32BE(m[1],12),b},h.prototype.scrub=function(){l(this._keySchedule),l(this._invKeySchedule),l(this._key)},a.exports.AES=h},{"safe-buffer":494}],190:[function(e,a,f){var c=e("./aes"),s=e("safe-buffer").Buffer,l=e("cipher-base"),i=e("inherits"),n=e("./ghash"),o=e("buffer-xor"),h=e("./incr32");function u(d,m,b,p){l.call(this);var v=s.alloc(4,0);this._cipher=new c.AES(m);var g=this._cipher.encryptBlock(v);this._ghash=new n(g),b=function(x,C,T){if(C.length===12)return x._finID=s.concat([C,s.from([0,0,0,1])]),s.concat([C,s.from([0,0,0,2])]);var R=new n(T),B=C.length,I=B%16;R.update(C),I&&(I=16-I,R.update(s.alloc(I,0))),R.update(s.alloc(8,0));var F=8*B,L=s.alloc(8);L.writeUIntBE(F,0,8),R.update(L),x._finID=R.state;var V=s.from(x._finID);return h(V),V}(this,b,g),this._prev=s.from(b),this._cache=s.allocUnsafe(0),this._secCache=s.allocUnsafe(0),this._decrypt=p,this._alen=0,this._len=0,this._mode=d,this._authTag=null,this._called=!1}i(u,l),u.prototype._update=function(d){if(!this._called&&this._alen){var m=16-this._alen%16;m<16&&(m=s.alloc(m,0),this._ghash.update(m))}this._called=!0;var b=this._mode.encrypt(this,d);return this._decrypt?this._ghash.update(d):this._ghash.update(b),this._len+=d.length,b},u.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var d=o(this._ghash.final(8*this._alen,8*this._len),this._cipher.encryptBlock(this._finID));if(this._decrypt&&function(m,b){var p=0;m.length!==b.length&&p++;for(var v=Math.min(m.length,b.length),g=0;g<v;++g)p+=m[g]^b[g];return p}(d,this._authTag))throw new Error("Unsupported state or unable to authenticate data");this._authTag=d,this._cipher.scrub()},u.prototype.getAuthTag=function(){if(this._decrypt||!s.isBuffer(this._authTag))throw new Error("Attempting to get auth tag in unsupported state");return this._authTag},u.prototype.setAuthTag=function(d){if(!this._decrypt)throw new Error("Attempting to set auth tag in unsupported state");this._authTag=d},u.prototype.setAAD=function(d){if(this._called)throw new Error("Attempting to set AAD in unsupported state");this._ghash.update(d),this._alen+=d.length},a.exports=u},{"./aes":189,"./ghash":194,"./incr32":195,"buffer-xor":219,"cipher-base":221,inherits:440,"safe-buffer":494}],191:[function(e,a,f){var c=e("./encrypter"),s=e("./decrypter"),l=e("./modes/list.json");f.createCipher=f.Cipher=c.createCipher,f.createCipheriv=f.Cipheriv=c.createCipheriv,f.createDecipher=f.Decipher=s.createDecipher,f.createDecipheriv=f.Decipheriv=s.createDecipheriv,f.listCiphers=f.getCiphers=function(){return Object.keys(l)}},{"./decrypter":192,"./encrypter":193,"./modes/list.json":203}],192:[function(e,a,f){var c=e("./authCipher"),s=e("safe-buffer").Buffer,l=e("./modes"),i=e("./streamCipher"),n=e("cipher-base"),o=e("./aes"),h=e("evp_bytestokey");function u(b,p,v){n.call(this),this._cache=new d,this._last=void 0,this._cipher=new o.AES(p),this._prev=s.from(v),this._mode=b,this._autopadding=!0}function d(){this.cache=s.allocUnsafe(0)}function m(b,p,v){var g=l[b.toLowerCase()];if(!g)throw new TypeError("invalid suite type");if(typeof v=="string"&&(v=s.from(v)),g.mode!=="GCM"&&v.length!==g.iv)throw new TypeError("invalid iv length "+v.length);if(typeof p=="string"&&(p=s.from(p)),p.length!==g.key/8)throw new TypeError("invalid key length "+p.length);return g.type==="stream"?new i(g.module,p,v,!0):g.type==="auth"?new c(g.module,p,v,!0):new u(g.module,p,v)}e("inherits")(u,n),u.prototype._update=function(b){var p,v;this._cache.add(b);for(var g=[];p=this._cache.get(this._autopadding);)v=this._mode.decrypt(this,p),g.push(v);return s.concat(g)},u.prototype._final=function(){var b=this._cache.flush();if(this._autopadding)return function(p){var v=p[15];if(v<1||v>16)throw new Error("unable to decrypt data");for(var g=-1;++g<v;)if(p[g+(16-v)]!==v)throw new Error("unable to decrypt data");if(v!==16)return p.slice(0,16-v)}(this._mode.decrypt(this,b));if(b)throw new Error("data not multiple of block length")},u.prototype.setAutoPadding=function(b){return this._autopadding=!!b,this},d.prototype.add=function(b){this.cache=s.concat([this.cache,b])},d.prototype.get=function(b){var p;if(b){if(this.cache.length>16)return p=this.cache.slice(0,16),this.cache=this.cache.slice(16),p}else if(this.cache.length>=16)return p=this.cache.slice(0,16),this.cache=this.cache.slice(16),p;return null},d.prototype.flush=function(){if(this.cache.length)return this.cache},f.createDecipher=function(b,p){var v=l[b.toLowerCase()];if(!v)throw new TypeError("invalid suite type");var g=h(p,!1,v.key,v.iv);return m(b,g.key,g.iv)},f.createDecipheriv=m},{"./aes":189,"./authCipher":190,"./modes":202,"./streamCipher":205,"cipher-base":221,evp_bytestokey:423,inherits:440,"safe-buffer":494}],193:[function(e,a,f){var c=e("./modes"),s=e("./authCipher"),l=e("safe-buffer").Buffer,i=e("./streamCipher"),n=e("cipher-base"),o=e("./aes"),h=e("evp_bytestokey");function u(p,v,g){n.call(this),this._cache=new m,this._cipher=new o.AES(v),this._prev=l.from(g),this._mode=p,this._autopadding=!0}e("inherits")(u,n),u.prototype._update=function(p){var v,g;this._cache.add(p);for(var x=[];v=this._cache.get();)g=this._mode.encrypt(this,v),x.push(g);return l.concat(x)};var d=l.alloc(16,16);function m(){this.cache=l.allocUnsafe(0)}function b(p,v,g){var x=c[p.toLowerCase()];if(!x)throw new TypeError("invalid suite type");if(typeof v=="string"&&(v=l.from(v)),v.length!==x.key/8)throw new TypeError("invalid key length "+v.length);if(typeof g=="string"&&(g=l.from(g)),x.mode!=="GCM"&&g.length!==x.iv)throw new TypeError("invalid iv length "+g.length);return x.type==="stream"?new i(x.module,v,g):x.type==="auth"?new s(x.module,v,g):new u(x.module,v,g)}u.prototype._final=function(){var p=this._cache.flush();if(this._autopadding)return p=this._mode.encrypt(this,p),this._cipher.scrub(),p;if(!p.equals(d))throw this._cipher.scrub(),new Error("data not multiple of block length")},u.prototype.setAutoPadding=function(p){return this._autopadding=!!p,this},m.prototype.add=function(p){this.cache=l.concat([this.cache,p])},m.prototype.get=function(){if(this.cache.length>15){var p=this.cache.slice(0,16);return this.cache=this.cache.slice(16),p}return null},m.prototype.flush=function(){for(var p=16-this.cache.length,v=l.allocUnsafe(p),g=-1;++g<p;)v.writeUInt8(p,g);return l.concat([this.cache,v])},f.createCipheriv=b,f.createCipher=function(p,v){var g=c[p.toLowerCase()];if(!g)throw new TypeError("invalid suite type");var x=h(v,!1,g.key,g.iv);return b(p,x.key,x.iv)}},{"./aes":189,"./authCipher":190,"./modes":202,"./streamCipher":205,"cipher-base":221,evp_bytestokey:423,inherits:440,"safe-buffer":494}],194:[function(e,a,f){var c=e("safe-buffer").Buffer,s=c.alloc(16,0);function l(n){var o=c.allocUnsafe(16);return o.writeUInt32BE(n[0]>>>0,0),o.writeUInt32BE(n[1]>>>0,4),o.writeUInt32BE(n[2]>>>0,8),o.writeUInt32BE(n[3]>>>0,12),o}function i(n){this.h=n,this.state=c.alloc(16,0),this.cache=c.allocUnsafe(0)}i.prototype.ghash=function(n){for(var o=-1;++o<n.length;)this.state[o]^=n[o];this._multiply()},i.prototype._multiply=function(){for(var n,o,h,u=[(n=this.h).readUInt32BE(0),n.readUInt32BE(4),n.readUInt32BE(8),n.readUInt32BE(12)],d=[0,0,0,0],m=-1;++m<128;){for((this.state[~~(m/8)]&1<<7-m%8)!=0&&(d[0]^=u[0],d[1]^=u[1],d[2]^=u[2],d[3]^=u[3]),h=(1&u[3])!=0,o=3;o>0;o--)u[o]=u[o]>>>1|(1&u[o-1])<<31;u[0]=u[0]>>>1,h&&(u[0]=u[0]^225<<24)}this.state=l(d)},i.prototype.update=function(n){var o;for(this.cache=c.concat([this.cache,n]);this.cache.length>=16;)o=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(o)},i.prototype.final=function(n,o){return this.cache.length&&this.ghash(c.concat([this.cache,s],16)),this.ghash(l([0,n,0,o])),this.state},a.exports=i},{"safe-buffer":494}],195:[function(e,a,f){a.exports=function(c){for(var s,l=c.length;l--;){if((s=c.readUInt8(l))!==255){s++,c.writeUInt8(s,l);break}c.writeUInt8(0,l)}}},{}],196:[function(e,a,f){var c=e("buffer-xor");f.encrypt=function(s,l){var i=c(l,s._prev);return s._prev=s._cipher.encryptBlock(i),s._prev},f.decrypt=function(s,l){var i=s._prev;s._prev=l;var n=s._cipher.decryptBlock(l);return c(n,i)}},{"buffer-xor":219}],197:[function(e,a,f){var c=e("safe-buffer").Buffer,s=e("buffer-xor");function l(i,n,o){var h=n.length,u=s(n,i._cache);return i._cache=i._cache.slice(h),i._prev=c.concat([i._prev,o?n:u]),u}f.encrypt=function(i,n,o){for(var h,u=c.allocUnsafe(0);n.length;){if(i._cache.length===0&&(i._cache=i._cipher.encryptBlock(i._prev),i._prev=c.allocUnsafe(0)),!(i._cache.length<=n.length)){u=c.concat([u,l(i,n,o)]);break}h=i._cache.length,u=c.concat([u,l(i,n.slice(0,h),o)]),n=n.slice(h)}return u}},{"buffer-xor":219,"safe-buffer":494}],198:[function(e,a,f){var c=e("safe-buffer").Buffer;function s(i,n,o){for(var h,u,d=-1,m=0;++d<8;)h=n&1<<7-d?128:0,m+=(128&(u=i._cipher.encryptBlock(i._prev)[0]^h))>>d%8,i._prev=l(i._prev,o?h:u);return m}function l(i,n){var o=i.length,h=-1,u=c.allocUnsafe(i.length);for(i=c.concat([i,c.from([n])]);++h<o;)u[h]=i[h]<<1|i[h+1]>>7;return u}f.encrypt=function(i,n,o){for(var h=n.length,u=c.allocUnsafe(h),d=-1;++d<h;)u[d]=s(i,n[d],o);return u}},{"safe-buffer":494}],199:[function(e,a,f){var c=e("safe-buffer").Buffer;function s(l,i,n){var o=l._cipher.encryptBlock(l._prev)[0]^i;return l._prev=c.concat([l._prev.slice(1),c.from([n?i:o])]),o}f.encrypt=function(l,i,n){for(var o=i.length,h=c.allocUnsafe(o),u=-1;++u<o;)h[u]=s(l,i[u],n);return h}},{"safe-buffer":494}],200:[function(e,a,f){var c=e("buffer-xor"),s=e("safe-buffer").Buffer,l=e("../incr32");function i(n){var o=n._cipher.encryptBlockRaw(n._prev);return l(n._prev),o}f.encrypt=function(n,o){var h=Math.ceil(o.length/16),u=n._cache.length;n._cache=s.concat([n._cache,s.allocUnsafe(16*h)]);for(var d=0;d<h;d++){var m=i(n),b=u+16*d;n._cache.writeUInt32BE(m[0],b+0),n._cache.writeUInt32BE(m[1],b+4),n._cache.writeUInt32BE(m[2],b+8),n._cache.writeUInt32BE(m[3],b+12)}var p=n._cache.slice(0,o.length);return n._cache=n._cache.slice(o.length),c(o,p)}},{"../incr32":195,"buffer-xor":219,"safe-buffer":494}],201:[function(e,a,f){f.encrypt=function(c,s){return c._cipher.encryptBlock(s)},f.decrypt=function(c,s){return c._cipher.decryptBlock(s)}},{}],202:[function(e,a,f){var c={ECB:e("./ecb"),CBC:e("./cbc"),CFB:e("./cfb"),CFB8:e("./cfb8"),CFB1:e("./cfb1"),OFB:e("./ofb"),CTR:e("./ctr"),GCM:e("./ctr")},s=e("./list.json");for(var l in s)s[l].module=c[s[l].mode];a.exports=s},{"./cbc":196,"./cfb":197,"./cfb1":198,"./cfb8":199,"./ctr":200,"./ecb":201,"./list.json":203,"./ofb":204}],203:[function(e,a,f){a.exports={"aes-128-ecb":{cipher:"AES",key:128,iv:0,mode:"ECB",type:"block"},"aes-192-ecb":{cipher:"AES",key:192,iv:0,mode:"ECB",type:"block"},"aes-256-ecb":{cipher:"AES",key:256,iv:0,mode:"ECB",type:"block"},"aes-128-cbc":{cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},"aes-192-cbc":{cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},"aes-256-cbc":{cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},aes128:{cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},aes192:{cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},aes256:{cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},"aes-128-cfb":{cipher:"AES",key:128,iv:16,mode:"CFB",type:"stream"},"aes-192-cfb":{cipher:"AES",key:192,iv:16,mode:"CFB",type:"stream"},"aes-256-cfb":{cipher:"AES",key:256,iv:16,mode:"CFB",type:"stream"},"aes-128-cfb8":{cipher:"AES",key:128,iv:16,mode:"CFB8",type:"stream"},"aes-192-cfb8":{cipher:"AES",key:192,iv:16,mode:"CFB8",type:"stream"},"aes-256-cfb8":{cipher:"AES",key:256,iv:16,mode:"CFB8",type:"stream"},"aes-128-cfb1":{cipher:"AES",key:128,iv:16,mode:"CFB1",type:"stream"},"aes-192-cfb1":{cipher:"AES",key:192,iv:16,mode:"CFB1",type:"stream"},"aes-256-cfb1":{cipher:"AES",key:256,iv:16,mode:"CFB1",type:"stream"},"aes-128-ofb":{cipher:"AES",key:128,iv:16,mode:"OFB",type:"stream"},"aes-192-ofb":{cipher:"AES",key:192,iv:16,mode:"OFB",type:"stream"},"aes-256-ofb":{cipher:"AES",key:256,iv:16,mode:"OFB",type:"stream"},"aes-128-ctr":{cipher:"AES",key:128,iv:16,mode:"CTR",type:"stream"},"aes-192-ctr":{cipher:"AES",key:192,iv:16,mode:"CTR",type:"stream"},"aes-256-ctr":{cipher:"AES",key:256,iv:16,mode:"CTR",type:"stream"},"aes-128-gcm":{cipher:"AES",key:128,iv:12,mode:"GCM",type:"auth"},"aes-192-gcm":{cipher:"AES",key:192,iv:12,mode:"GCM",type:"auth"},"aes-256-gcm":{cipher:"AES",key:256,iv:12,mode:"GCM",type:"auth"}}},{}],204:[function(e,a,f){(function(c){(function(){var s=e("buffer-xor");function l(i){return i._prev=i._cipher.encryptBlock(i._prev),i._prev}f.encrypt=function(i,n){for(;i._cache.length<n.length;)i._cache=c.concat([i._cache,l(i)]);var o=i._cache.slice(0,n.length);return i._cache=i._cache.slice(n.length),s(n,o)}}).call(this)}).call(this,e("buffer").Buffer)},{buffer:220,"buffer-xor":219}],205:[function(e,a,f){var c=e("./aes"),s=e("safe-buffer").Buffer,l=e("cipher-base");function i(n,o,h,u){l.call(this),this._cipher=new c.AES(o),this._prev=s.from(h),this._cache=s.allocUnsafe(0),this._secCache=s.allocUnsafe(0),this._decrypt=u,this._mode=n}e("inherits")(i,l),i.prototype._update=function(n){return this._mode.encrypt(this,n,this._decrypt)},i.prototype._final=function(){this._cipher.scrub()},a.exports=i},{"./aes":189,"cipher-base":221,inherits:440,"safe-buffer":494}],206:[function(e,a,f){var c=e("browserify-des"),s=e("browserify-aes/browser"),l=e("browserify-aes/modes"),i=e("browserify-des/modes"),n=e("evp_bytestokey");function o(u,d,m){if(u=u.toLowerCase(),l[u])return s.createCipheriv(u,d,m);if(i[u])return new c({key:d,iv:m,mode:u});throw new TypeError("invalid suite type")}function h(u,d,m){if(u=u.toLowerCase(),l[u])return s.createDecipheriv(u,d,m);if(i[u])return new c({key:d,iv:m,mode:u,decrypt:!0});throw new TypeError("invalid suite type")}f.createCipher=f.Cipher=function(u,d){var m,b;if(u=u.toLowerCase(),l[u])m=l[u].key,b=l[u].iv;else{if(!i[u])throw new TypeError("invalid suite type");m=8*i[u].key,b=i[u].iv}var p=n(d,!1,m,b);return o(u,p.key,p.iv)},f.createCipheriv=f.Cipheriv=o,f.createDecipher=f.Decipher=function(u,d){var m,b;if(u=u.toLowerCase(),l[u])m=l[u].key,b=l[u].iv;else{if(!i[u])throw new TypeError("invalid suite type");m=8*i[u].key,b=i[u].iv}var p=n(d,!1,m,b);return h(u,p.key,p.iv)},f.createDecipheriv=f.Decipheriv=h,f.listCiphers=f.getCiphers=function(){return Object.keys(i).concat(s.getCiphers())}},{"browserify-aes/browser":191,"browserify-aes/modes":202,"browserify-des":207,"browserify-des/modes":208,evp_bytestokey:423}],207:[function(e,a,f){var c=e("cipher-base"),s=e("des.js"),l=e("inherits"),i=e("safe-buffer").Buffer,n={"des-ede3-cbc":s.CBC.instantiate(s.EDE),"des-ede3":s.EDE,"des-ede-cbc":s.CBC.instantiate(s.EDE),"des-ede":s.EDE,"des-cbc":s.CBC.instantiate(s.DES),"des-ecb":s.DES};function o(h){c.call(this);var u,d=h.mode.toLowerCase(),m=n[d];u=h.decrypt?"decrypt":"encrypt";var b=h.key;i.isBuffer(b)||(b=i.from(b)),d!=="des-ede"&&d!=="des-ede-cbc"||(b=i.concat([b,b.slice(0,8)]));var p=h.iv;i.isBuffer(p)||(p=i.from(p)),this._des=m.create({key:b,iv:p,type:u})}n.des=n["des-cbc"],n.des3=n["des-ede3-cbc"],a.exports=o,l(o,c),o.prototype._update=function(h){return i.from(this._des.update(h))},o.prototype._final=function(){return i.from(this._des.final())}},{"cipher-base":221,"des.js":394,inherits:440,"safe-buffer":494}],208:[function(e,a,f){f["des-ecb"]={key:8,iv:0},f["des-cbc"]=f.des={key:8,iv:8},f["des-ede3-cbc"]=f.des3={key:24,iv:8},f["des-ede3"]={key:24,iv:0},f["des-ede-cbc"]={key:16,iv:8},f["des-ede"]={key:16,iv:0}},{}],209:[function(e,a,f){(function(c){(function(){var s=e("bn.js"),l=e("randombytes");function i(o){var h,u=o.modulus.byteLength();do h=new s(l(u));while(h.cmp(o.modulus)>=0||!h.umod(o.prime1)||!h.umod(o.prime2));return h}function n(o,h){var u=function(B){var I=i(B);return{blinder:I.toRed(s.mont(B.modulus)).redPow(new s(B.publicExponent)).fromRed(),unblinder:I.invm(B.modulus)}}(h),d=h.modulus.byteLength(),m=new s(o).mul(u.blinder).umod(h.modulus),b=m.toRed(s.mont(h.prime1)),p=m.toRed(s.mont(h.prime2)),v=h.coefficient,g=h.prime1,x=h.prime2,C=b.redPow(h.exponent1).fromRed(),T=p.redPow(h.exponent2).fromRed(),R=C.isub(T).imul(v).umod(g).imul(x);return T.iadd(R).imul(u.unblinder).umod(h.modulus).toArrayLike(c,"be",d)}n.getr=i,a.exports=n}).call(this)}).call(this,e("buffer").Buffer)},{"bn.js":186,buffer:220,randombytes:475}],210:[function(e,a,f){a.exports=e("./browser/algorithms.json")},{"./browser/algorithms.json":211}],211:[function(e,a,f){a.exports={sha224WithRSAEncryption:{sign:"rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},"RSA-SHA224":{sign:"ecdsa/rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},sha256WithRSAEncryption:{sign:"rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},"RSA-SHA256":{sign:"ecdsa/rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},sha384WithRSAEncryption:{sign:"rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},"RSA-SHA384":{sign:"ecdsa/rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},sha512WithRSAEncryption:{sign:"rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA512":{sign:"ecdsa/rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA1":{sign:"rsa",hash:"sha1",id:"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{sign:"ecdsa",hash:"sha1",id:""},sha256:{sign:"ecdsa",hash:"sha256",id:""},sha224:{sign:"ecdsa",hash:"sha224",id:""},sha384:{sign:"ecdsa",hash:"sha384",id:""},sha512:{sign:"ecdsa",hash:"sha512",id:""},"DSA-SHA":{sign:"dsa",hash:"sha1",id:""},"DSA-SHA1":{sign:"dsa",hash:"sha1",id:""},DSA:{sign:"dsa",hash:"sha1",id:""},"DSA-WITH-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-WITH-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-WITH-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-WITH-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-RIPEMD160":{sign:"dsa",hash:"rmd160",id:""},ripemd160WithRSA:{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},"RSA-RIPEMD160":{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},md5WithRSAEncryption:{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"},"RSA-MD5":{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"}}},{}],212:[function(e,a,f){a.exports={"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"}},{}],213:[function(e,a,f){var c=e("safe-buffer").Buffer,s=e("create-hash"),l=e("readable-stream"),i=e("inherits"),n=e("./sign"),o=e("./verify"),h=e("./algorithms.json");function u(p){l.Writable.call(this);var v=h[p];if(!v)throw new Error("Unknown message digest");this._hashType=v.hash,this._hash=s(v.hash),this._tag=v.id,this._signType=v.sign}function d(p){l.Writable.call(this);var v=h[p];if(!v)throw new Error("Unknown message digest");this._hash=s(v.hash),this._tag=v.id,this._signType=v.sign}function m(p){return new u(p)}function b(p){return new d(p)}Object.keys(h).forEach(function(p){h[p].id=c.from(h[p].id,"hex"),h[p.toLowerCase()]=h[p]}),i(u,l.Writable),u.prototype._write=function(p,v,g){this._hash.update(p),g()},u.prototype.update=function(p,v){return typeof p=="string"&&(p=c.from(p,v)),this._hash.update(p),this},u.prototype.sign=function(p,v){this.end();var g=this._hash.digest(),x=n(g,p,this._hashType,this._signType,this._tag);return v?x.toString(v):x},i(d,l.Writable),d.prototype._write=function(p,v,g){this._hash.update(p),g()},d.prototype.update=function(p,v){return typeof p=="string"&&(p=c.from(p,v)),this._hash.update(p),this},d.prototype.verify=function(p,v,g){typeof v=="string"&&(v=c.from(v,g)),this.end();var x=this._hash.digest();return o(v,x,p,this._signType,this._tag)},a.exports={Sign:m,Verify:b,createSign:m,createVerify:b}},{"./algorithms.json":211,"./sign":214,"./verify":215,"create-hash":386,inherits:440,"readable-stream":491,"safe-buffer":494}],214:[function(e,a,f){var c=e("safe-buffer").Buffer,s=e("create-hmac"),l=e("browserify-rsa"),i=e("elliptic").ec,n=e("bn.js"),o=e("parse-asn1"),h=e("./curves.json");function u(p,v,g,x){if((p=c.from(p.toArray())).length<v.byteLength()){var C=c.alloc(v.byteLength()-p.length);p=c.concat([C,p])}var T=g.length,R=function(F,L){F=(F=d(F,L)).mod(L);var V=c.from(F.toArray());if(V.length<L.byteLength()){var z=c.alloc(L.byteLength()-V.length);V=c.concat([z,V])}return V}(g,v),B=c.alloc(T);B.fill(1);var I=c.alloc(T);return I=s(x,I).update(B).update(c.from([0])).update(p).update(R).digest(),B=s(x,I).update(B).digest(),{k:I=s(x,I).update(B).update(c.from([1])).update(p).update(R).digest(),v:B=s(x,I).update(B).digest()}}function d(p,v){var g=new n(p),x=(p.length<<3)-v.bitLength();return x>0&&g.ishrn(x),g}function m(p,v,g){var x,C;do{for(x=c.alloc(0);8*x.length<p.bitLength();)v.v=s(g,v.k).update(v.v).digest(),x=c.concat([x,v.v]);C=d(x,p),v.k=s(g,v.k).update(v.v).update(c.from([0])).digest(),v.v=s(g,v.k).update(v.v).digest()}while(C.cmp(p)!==-1);return C}function b(p,v,g,x){return p.toRed(n.mont(g)).redPow(v).fromRed().mod(x)}a.exports=function(p,v,g,x,C){var T=o(v);if(T.curve){if(x!=="ecdsa"&&x!=="ecdsa/rsa")throw new Error("wrong private key type");return function(F,L){var V=h[L.curve.join(".")];if(!V)throw new Error("unknown curve "+L.curve.join("."));var z=new i(V).keyFromPrivate(L.privateKey).sign(F);return c.from(z.toDER())}(p,T)}if(T.type==="dsa"){if(x!=="dsa")throw new Error("wrong private key type");return function(F,L,V){for(var z,E=L.params.priv_key,P=L.params.p,k=L.params.q,y=L.params.g,w=new n(0),_=d(F,k).mod(k),S=!1,A=u(E,k,F,V);S===!1;)z=m(k,A,V),w=b(y,z,P,k),(S=z.invm(k).imul(_.add(E.mul(w))).mod(k)).cmpn(0)===0&&(S=!1,w=new n(0));return function(O,N){O=O.toArray(),N=N.toArray(),128&O[0]&&(O=[0].concat(O)),128&N[0]&&(N=[0].concat(N));var U=[48,O.length+N.length+4,2,O.length];return U=U.concat(O,[2,N.length],N),c.from(U)}(w,S)}(p,T,g)}if(x!=="rsa"&&x!=="ecdsa/rsa")throw new Error("wrong private key type");p=c.concat([C,p]);for(var R=T.modulus.byteLength(),B=[0,1];p.length+B.length+1<R;)B.push(255);B.push(0);for(var I=-1;++I<p.length;)B.push(p[I]);return l(B,T)},a.exports.getKey=u,a.exports.makeKey=m},{"./curves.json":212,"bn.js":186,"browserify-rsa":209,"create-hmac":388,elliptic:405,"parse-asn1":459,"safe-buffer":494}],215:[function(e,a,f){var c=e("safe-buffer").Buffer,s=e("bn.js"),l=e("elliptic").ec,i=e("parse-asn1"),n=e("./curves.json");function o(h,u){if(h.cmpn(0)<=0)throw new Error("invalid sig");if(h.cmp(u)>=u)throw new Error("invalid sig")}a.exports=function(h,u,d,m,b){var p=i(d);if(p.type==="ec"){if(m!=="ecdsa"&&m!=="ecdsa/rsa")throw new Error("wrong public key type");return function(B,I,F){var L=n[F.data.algorithm.curve.join(".")];if(!L)throw new Error("unknown curve "+F.data.algorithm.curve.join("."));var V=new l(L),z=F.data.subjectPrivateKey.data;return V.verify(I,B,z)}(h,u,p)}if(p.type==="dsa"){if(m!=="dsa")throw new Error("wrong public key type");return function(B,I,F){var L=F.data.p,V=F.data.q,z=F.data.g,E=F.data.pub_key,P=i.signature.decode(B,"der"),k=P.s,y=P.r;o(k,V),o(y,V);var w=s.mont(L),_=k.invm(V);return z.toRed(w).redPow(new s(I).mul(_).mod(V)).fromRed().mul(E.toRed(w).redPow(y.mul(_).mod(V)).fromRed()).mod(L).mod(V).cmp(y)===0}(h,u,p)}if(m!=="rsa"&&m!=="ecdsa/rsa")throw new Error("wrong public key type");u=c.concat([b,u]);for(var v=p.modulus.byteLength(),g=[1],x=0;u.length+g.length+2<v;)g.push(255),x++;g.push(0);for(var C=-1;++C<u.length;)g.push(u[C]);g=c.from(g);var T=s.mont(p.modulus);h=(h=new s(h).toRed(T)).redPow(new s(p.publicExponent)),h=c.from(h.fromRed().toArray());var R=x<8?1:0;for(v=Math.min(h.length,g.length),h.length!==g.length&&(R=1),C=-1;++C<v;)R|=h[C]^g[C];return R===0}},{"./curves.json":212,"bn.js":186,elliptic:405,"parse-asn1":459,"safe-buffer":494}],216:[function(e,a,f){},{}],217:[function(e,a,f){var c=e("buffer"),s=c.Buffer;function l(n,o){for(var h in n)o[h]=n[h]}function i(n,o,h){return s(n,o,h)}s.from&&s.alloc&&s.allocUnsafe&&s.allocUnsafeSlow?a.exports=c:(l(c,f),f.Buffer=i),l(s,i),i.from=function(n,o,h){if(typeof n=="number")throw new TypeError("Argument must not be a number");return s(n,o,h)},i.alloc=function(n,o,h){if(typeof n!="number")throw new TypeError("Argument must be a number");var u=s(n);return o!==void 0?typeof h=="string"?u.fill(o,h):u.fill(o):u.fill(0),u},i.allocUnsafe=function(n){if(typeof n!="number")throw new TypeError("Argument must be a number");return s(n)},i.allocUnsafeSlow=function(n){if(typeof n!="number")throw new TypeError("Argument must be a number");return c.SlowBuffer(n)}},{buffer:220}],218:[function(e,a,f){var c=e("safe-buffer").Buffer,s=c.isEncoding||function(p){switch((p=""+p)&&p.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function l(p){var v;switch(this.encoding=function(g){var x=function(C){if(!C)return"utf8";for(var T;;)switch(C){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return C;default:if(T)return;C=(""+C).toLowerCase(),T=!0}}(g);if(typeof x!="string"&&(c.isEncoding===s||!s(g)))throw new Error("Unknown encoding: "+g);return x||g}(p),this.encoding){case"utf16le":this.text=o,this.end=h,v=4;break;case"utf8":this.fillLast=n,v=4;break;case"base64":this.text=u,this.end=d,v=3;break;default:return this.write=m,void(this.end=b)}this.lastNeed=0,this.lastTotal=0,this.lastChar=c.allocUnsafe(v)}function i(p){return p<=127?0:p>>5==6?2:p>>4==14?3:p>>3==30?4:p>>6==2?-1:-2}function n(p){var v=this.lastTotal-this.lastNeed,g=function(x,C,T){if((192&C[0])!=128)return x.lastNeed=0,"�";if(x.lastNeed>1&&C.length>1){if((192&C[1])!=128)return x.lastNeed=1,"�";if(x.lastNeed>2&&C.length>2&&(192&C[2])!=128)return x.lastNeed=2,"�"}}(this,p);return g!==void 0?g:this.lastNeed<=p.length?(p.copy(this.lastChar,v,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):(p.copy(this.lastChar,v,0,p.length),void(this.lastNeed-=p.length))}function o(p,v){if((p.length-v)%2==0){var g=p.toString("utf16le",v);if(g){var x=g.charCodeAt(g.length-1);if(x>=55296&&x<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=p[p.length-2],this.lastChar[1]=p[p.length-1],g.slice(0,-1)}return g}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=p[p.length-1],p.toString("utf16le",v,p.length-1)}function h(p){var v=p&&p.length?this.write(p):"";if(this.lastNeed){var g=this.lastTotal-this.lastNeed;return v+this.lastChar.toString("utf16le",0,g)}return v}function u(p,v){var g=(p.length-v)%3;return g===0?p.toString("base64",v):(this.lastNeed=3-g,this.lastTotal=3,g===1?this.lastChar[0]=p[p.length-1]:(this.lastChar[0]=p[p.length-2],this.lastChar[1]=p[p.length-1]),p.toString("base64",v,p.length-g))}function d(p){var v=p&&p.length?this.write(p):"";return this.lastNeed?v+this.lastChar.toString("base64",0,3-this.lastNeed):v}function m(p){return p.toString(this.encoding)}function b(p){return p&&p.length?this.write(p):""}f.StringDecoder=l,l.prototype.write=function(p){if(p.length===0)return"";var v,g;if(this.lastNeed){if((v=this.fillLast(p))===void 0)return"";g=this.lastNeed,this.lastNeed=0}else g=0;return g<p.length?v?v+this.text(p,g):this.text(p,g):v||""},l.prototype.end=function(p){var v=p&&p.length?this.write(p):"";return this.lastNeed?v+"�":v},l.prototype.text=function(p,v){var g=function(C,T,R){var B=T.length-1;if(B<R)return 0;var I=i(T[B]);return I>=0?(I>0&&(C.lastNeed=I-1),I):--B<R||I===-2?0:(I=i(T[B]))>=0?(I>0&&(C.lastNeed=I-2),I):--B<R||I===-2?0:(I=i(T[B]))>=0?(I>0&&(I===2?I=0:C.lastNeed=I-3),I):0}(this,p,v);if(!this.lastNeed)return p.toString("utf8",v);this.lastTotal=g;var x=p.length-(g-this.lastNeed);return p.copy(this.lastChar,0,x),p.toString("utf8",v,x)},l.prototype.fillLast=function(p){if(this.lastNeed<=p.length)return p.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);p.copy(this.lastChar,this.lastTotal-this.lastNeed,0,p.length),this.lastNeed-=p.length}},{"safe-buffer":217}],219:[function(e,a,f){(function(c){(function(){a.exports=function(s,l){for(var i=Math.min(s.length,l.length),n=new c(i),o=0;o<i;++o)n[o]=s[o]^l[o];return n}}).call(this)}).call(this,e("buffer").Buffer)},{buffer:220}],220:[function(e,a,f){(function(c){(function(){var s=e("base64-js"),l=e("ieee754");f.Buffer=n,f.SlowBuffer=function(M){return+M!=M&&(M=0),n.alloc(+M)},f.INSPECT_MAX_BYTES=50;function i(M){if(M>2147483647)throw new RangeError('The value "'+M+'" is invalid for option "size"');var j=new Uint8Array(M);return j.__proto__=n.prototype,j}function n(M,j,$){if(typeof M=="number"){if(typeof j=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return u(M)}return o(M,j,$)}function o(M,j,$){if(typeof M=="string")return function(X,Q){if(typeof Q=="string"&&Q!==""||(Q="utf8"),!n.isEncoding(Q))throw new TypeError("Unknown encoding: "+Q);var ee=0|b(X,Q),se=i(ee),Y=se.write(X,Q);return Y!==ee&&(se=se.slice(0,Y)),se}(M,j);if(ArrayBuffer.isView(M))return d(M);if(M==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof M);if(D(M,ArrayBuffer)||M&&D(M.buffer,ArrayBuffer))return function(X,Q,ee){if(Q<0||X.byteLength<Q)throw new RangeError('"offset" is outside of buffer bounds');if(X.byteLength<Q+(ee||0))throw new RangeError('"length" is outside of buffer bounds');var se;return se=Q===void 0&&ee===void 0?new Uint8Array(X):ee===void 0?new Uint8Array(X,Q):new Uint8Array(X,Q,ee),se.__proto__=n.prototype,se}(M,j,$);if(typeof M=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');var K=M.valueOf&&M.valueOf();if(K!=null&&K!==M)return n.from(K,j,$);var J=function(X){if(n.isBuffer(X)){var Q=0|m(X.length),ee=i(Q);return ee.length===0||X.copy(ee,0,0,Q),ee}if(X.length!==void 0)return typeof X.length!="number"||q(X.length)?i(0):d(X);if(X.type==="Buffer"&&Array.isArray(X.data))return d(X.data)}(M);if(J)return J;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof M[Symbol.toPrimitive]=="function")return n.from(M[Symbol.toPrimitive]("string"),j,$);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof M)}function h(M){if(typeof M!="number")throw new TypeError('"size" argument must be of type number');if(M<0)throw new RangeError('The value "'+M+'" is invalid for option "size"')}function u(M){return h(M),i(M<0?0:0|m(M))}function d(M){for(var j=M.length<0?0:0|m(M.length),$=i(j),K=0;K<j;K+=1)$[K]=255&M[K];return $}function m(M){if(M>=2147483647)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x7fffffff bytes");return 0|M}function b(M,j){if(n.isBuffer(M))return M.length;if(ArrayBuffer.isView(M)||D(M,ArrayBuffer))return M.byteLength;if(typeof M!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof M);var $=M.length,K=arguments.length>2&&arguments[2]===!0;if(!K&&$===0)return 0;for(var J=!1;;)switch(j){case"ascii":case"latin1":case"binary":return $;case"utf8":case"utf-8":return U(M).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*$;case"hex":return $>>>1;case"base64":return H(M).length;default:if(J)return K?-1:U(M).length;j=(""+j).toLowerCase(),J=!0}}function p(M,j,$){var K=!1;if((j===void 0||j<0)&&(j=0),j>this.length||(($===void 0||$>this.length)&&($=this.length),$<=0)||($>>>=0)<=(j>>>=0))return"";for(M||(M="utf8");;)switch(M){case"hex":return P(this,j,$);case"utf8":case"utf-8":return V(this,j,$);case"ascii":return z(this,j,$);case"latin1":case"binary":return E(this,j,$);case"base64":return L(this,j,$);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return k(this,j,$);default:if(K)throw new TypeError("Unknown encoding: "+M);M=(M+"").toLowerCase(),K=!0}}function v(M,j,$){var K=M[j];M[j]=M[$],M[$]=K}function g(M,j,$,K,J){if(M.length===0)return-1;if(typeof $=="string"?(K=$,$=0):$>2147483647?$=2147483647:$<-2147483648&&($=-2147483648),q($=+$)&&($=J?0:M.length-1),$<0&&($=M.length+$),$>=M.length){if(J)return-1;$=M.length-1}else if($<0){if(!J)return-1;$=0}if(typeof j=="string"&&(j=n.from(j,K)),n.isBuffer(j))return j.length===0?-1:x(M,j,$,K,J);if(typeof j=="number")return j&=255,typeof Uint8Array.prototype.indexOf=="function"?J?Uint8Array.prototype.indexOf.call(M,j,$):Uint8Array.prototype.lastIndexOf.call(M,j,$):x(M,[j],$,K,J);throw new TypeError("val must be string, number or Buffer")}function x(M,j,$,K,J){var X,Q=1,ee=M.length,se=j.length;if(K!==void 0&&((K=String(K).toLowerCase())==="ucs2"||K==="ucs-2"||K==="utf16le"||K==="utf-16le")){if(M.length<2||j.length<2)return-1;Q=2,ee/=2,se/=2,$/=2}function Y(ae,ce){return Q===1?ae[ce]:ae.readUInt16BE(ce*Q)}if(J){var te=-1;for(X=$;X<ee;X++)if(Y(M,X)===Y(j,te===-1?0:X-te)){if(te===-1&&(te=X),X-te+1===se)return te*Q}else te!==-1&&(X-=X-te),te=-1}else for($+se>ee&&($=ee-se),X=$;X>=0;X--){for(var ne=!0,oe=0;oe<se;oe++)if(Y(M,X+oe)!==Y(j,oe)){ne=!1;break}if(ne)return X}return-1}function C(M,j,$,K){$=Number($)||0;var J=M.length-$;K?(K=Number(K))>J&&(K=J):K=J;var X=j.length;K>X/2&&(K=X/2);for(var Q=0;Q<K;++Q){var ee=parseInt(j.substr(2*Q,2),16);if(q(ee))return Q;M[$+Q]=ee}return Q}function T(M,j,$,K){return Z(U(j,M.length-$),M,$,K)}function R(M,j,$,K){return Z(function(J){for(var X=[],Q=0;Q<J.length;++Q)X.push(255&J.charCodeAt(Q));return X}(j),M,$,K)}function B(M,j,$,K){return R(M,j,$,K)}function I(M,j,$,K){return Z(H(j),M,$,K)}function F(M,j,$,K){return Z(function(J,X){for(var Q,ee,se,Y=[],te=0;te<J.length&&!((X-=2)<0);++te)Q=J.charCodeAt(te),ee=Q>>8,se=Q%256,Y.push(se),Y.push(ee);return Y}(j,M.length-$),M,$,K)}function L(M,j,$){return j===0&&$===M.length?s.fromByteArray(M):s.fromByteArray(M.slice(j,$))}function V(M,j,$){$=Math.min(M.length,$);for(var K=[],J=j;J<$;){var X,Q,ee,se,Y=M[J],te=null,ne=Y>239?4:Y>223?3:Y>191?2:1;if(J+ne<=$)switch(ne){case 1:Y<128&&(te=Y);break;case 2:(192&(X=M[J+1]))==128&&(se=(31&Y)<<6|63&X)>127&&(te=se);break;case 3:X=M[J+1],Q=M[J+2],(192&X)==128&&(192&Q)==128&&(se=(15&Y)<<12|(63&X)<<6|63&Q)>2047&&(se<55296||se>57343)&&(te=se);break;case 4:X=M[J+1],Q=M[J+2],ee=M[J+3],(192&X)==128&&(192&Q)==128&&(192&ee)==128&&(se=(15&Y)<<18|(63&X)<<12|(63&Q)<<6|63&ee)>65535&&se<1114112&&(te=se)}te===null?(te=65533,ne=1):te>65535&&(te-=65536,K.push(te>>>10&1023|55296),te=56320|1023&te),K.push(te),J+=ne}return function(oe){var ae=oe.length;if(ae<=4096)return String.fromCharCode.apply(String,oe);for(var ce="",me=0;me<ae;)ce+=String.fromCharCode.apply(String,oe.slice(me,me+=4096));return ce}(K)}f.kMaxLength=2147483647,n.TYPED_ARRAY_SUPPORT=function(){try{var M=new Uint8Array(1);return M.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},M.foo()===42}catch{return!1}}(),n.TYPED_ARRAY_SUPPORT||typeof console>"u"||typeof console.error!="function"||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(n.prototype,"parent",{enumerable:!0,get:function(){if(n.isBuffer(this))return this.buffer}}),Object.defineProperty(n.prototype,"offset",{enumerable:!0,get:function(){if(n.isBuffer(this))return this.byteOffset}}),typeof Symbol<"u"&&Symbol.species!=null&&n[Symbol.species]===n&&Object.defineProperty(n,Symbol.species,{value:null,configurable:!0,enumerable:!1,writable:!1}),n.poolSize=8192,n.from=function(M,j,$){return o(M,j,$)},n.prototype.__proto__=Uint8Array.prototype,n.__proto__=Uint8Array,n.alloc=function(M,j,$){return function(K,J,X){return h(K),K<=0?i(K):J!==void 0?typeof X=="string"?i(K).fill(J,X):i(K).fill(J):i(K)}(M,j,$)},n.allocUnsafe=function(M){return u(M)},n.allocUnsafeSlow=function(M){return u(M)},n.isBuffer=function(M){return M!=null&&M._isBuffer===!0&&M!==n.prototype},n.compare=function(M,j){if(D(M,Uint8Array)&&(M=n.from(M,M.offset,M.byteLength)),D(j,Uint8Array)&&(j=n.from(j,j.offset,j.byteLength)),!n.isBuffer(M)||!n.isBuffer(j))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(M===j)return 0;for(var $=M.length,K=j.length,J=0,X=Math.min($,K);J<X;++J)if(M[J]!==j[J]){$=M[J],K=j[J];break}return $<K?-1:K<$?1:0},n.isEncoding=function(M){switch(String(M).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},n.concat=function(M,j){if(!Array.isArray(M))throw new TypeError('"list" argument must be an Array of Buffers');if(M.length===0)return n.alloc(0);var $;if(j===void 0)for(j=0,$=0;$<M.length;++$)j+=M[$].length;var K=n.allocUnsafe(j),J=0;for($=0;$<M.length;++$){var X=M[$];if(D(X,Uint8Array)&&(X=n.from(X)),!n.isBuffer(X))throw new TypeError('"list" argument must be an Array of Buffers');X.copy(K,J),J+=X.length}return K},n.byteLength=b,n.prototype._isBuffer=!0,n.prototype.swap16=function(){var M=this.length;if(M%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var j=0;j<M;j+=2)v(this,j,j+1);return this},n.prototype.swap32=function(){var M=this.length;if(M%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var j=0;j<M;j+=4)v(this,j,j+3),v(this,j+1,j+2);return this},n.prototype.swap64=function(){var M=this.length;if(M%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var j=0;j<M;j+=8)v(this,j,j+7),v(this,j+1,j+6),v(this,j+2,j+5),v(this,j+3,j+4);return this},n.prototype.toString=function(){var M=this.length;return M===0?"":arguments.length===0?V(this,0,M):p.apply(this,arguments)},n.prototype.toLocaleString=n.prototype.toString,n.prototype.equals=function(M){if(!n.isBuffer(M))throw new TypeError("Argument must be a Buffer");return this===M||n.compare(this,M)===0},n.prototype.inspect=function(){var M="",j=f.INSPECT_MAX_BYTES;return M=this.toString("hex",0,j).replace(/(.{2})/g,"$1 ").trim(),this.length>j&&(M+=" ... "),"<Buffer "+M+">"},n.prototype.compare=function(M,j,$,K,J){if(D(M,Uint8Array)&&(M=n.from(M,M.offset,M.byteLength)),!n.isBuffer(M))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof M);if(j===void 0&&(j=0),$===void 0&&($=M?M.length:0),K===void 0&&(K=0),J===void 0&&(J=this.length),j<0||$>M.length||K<0||J>this.length)throw new RangeError("out of range index");if(K>=J&&j>=$)return 0;if(K>=J)return-1;if(j>=$)return 1;if(this===M)return 0;for(var X=(J>>>=0)-(K>>>=0),Q=($>>>=0)-(j>>>=0),ee=Math.min(X,Q),se=this.slice(K,J),Y=M.slice(j,$),te=0;te<ee;++te)if(se[te]!==Y[te]){X=se[te],Q=Y[te];break}return X<Q?-1:Q<X?1:0},n.prototype.includes=function(M,j,$){return this.indexOf(M,j,$)!==-1},n.prototype.indexOf=function(M,j,$){return g(this,M,j,$,!0)},n.prototype.lastIndexOf=function(M,j,$){return g(this,M,j,$,!1)},n.prototype.write=function(M,j,$,K){if(j===void 0)K="utf8",$=this.length,j=0;else if($===void 0&&typeof j=="string")K=j,$=this.length,j=0;else{if(!isFinite(j))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");j>>>=0,isFinite($)?($>>>=0,K===void 0&&(K="utf8")):(K=$,$=void 0)}var J=this.length-j;if(($===void 0||$>J)&&($=J),M.length>0&&($<0||j<0)||j>this.length)throw new RangeError("Attempt to write outside buffer bounds");K||(K="utf8");for(var X=!1;;)switch(K){case"hex":return C(this,M,j,$);case"utf8":case"utf-8":return T(this,M,j,$);case"ascii":return R(this,M,j,$);case"latin1":case"binary":return B(this,M,j,$);case"base64":return I(this,M,j,$);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return F(this,M,j,$);default:if(X)throw new TypeError("Unknown encoding: "+K);K=(""+K).toLowerCase(),X=!0}},n.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function z(M,j,$){var K="";$=Math.min(M.length,$);for(var J=j;J<$;++J)K+=String.fromCharCode(127&M[J]);return K}function E(M,j,$){var K="";$=Math.min(M.length,$);for(var J=j;J<$;++J)K+=String.fromCharCode(M[J]);return K}function P(M,j,$){var K=M.length;(!j||j<0)&&(j=0),(!$||$<0||$>K)&&($=K);for(var J="",X=j;X<$;++X)J+=N(M[X]);return J}function k(M,j,$){for(var K=M.slice(j,$),J="",X=0;X<K.length;X+=2)J+=String.fromCharCode(K[X]+256*K[X+1]);return J}function y(M,j,$){if(M%1!=0||M<0)throw new RangeError("offset is not uint");if(M+j>$)throw new RangeError("Trying to access beyond buffer length")}function w(M,j,$,K,J,X){if(!n.isBuffer(M))throw new TypeError('"buffer" argument must be a Buffer instance');if(j>J||j<X)throw new RangeError('"value" argument is out of bounds');if($+K>M.length)throw new RangeError("Index out of range")}function _(M,j,$,K,J,X){if($+K>M.length)throw new RangeError("Index out of range");if($<0)throw new RangeError("Index out of range")}function S(M,j,$,K,J){return j=+j,$>>>=0,J||_(M,0,$,4),l.write(M,j,$,K,23,4),$+4}function A(M,j,$,K,J){return j=+j,$>>>=0,J||_(M,0,$,8),l.write(M,j,$,K,52,8),$+8}n.prototype.slice=function(M,j){var $=this.length;(M=~~M)<0?(M+=$)<0&&(M=0):M>$&&(M=$),(j=j===void 0?$:~~j)<0?(j+=$)<0&&(j=0):j>$&&(j=$),j<M&&(j=M);var K=this.subarray(M,j);return K.__proto__=n.prototype,K},n.prototype.readUIntLE=function(M,j,$){M>>>=0,j>>>=0,$||y(M,j,this.length);for(var K=this[M],J=1,X=0;++X<j&&(J*=256);)K+=this[M+X]*J;return K},n.prototype.readUIntBE=function(M,j,$){M>>>=0,j>>>=0,$||y(M,j,this.length);for(var K=this[M+--j],J=1;j>0&&(J*=256);)K+=this[M+--j]*J;return K},n.prototype.readUInt8=function(M,j){return M>>>=0,j||y(M,1,this.length),this[M]},n.prototype.readUInt16LE=function(M,j){return M>>>=0,j||y(M,2,this.length),this[M]|this[M+1]<<8},n.prototype.readUInt16BE=function(M,j){return M>>>=0,j||y(M,2,this.length),this[M]<<8|this[M+1]},n.prototype.readUInt32LE=function(M,j){return M>>>=0,j||y(M,4,this.length),(this[M]|this[M+1]<<8|this[M+2]<<16)+16777216*this[M+3]},n.prototype.readUInt32BE=function(M,j){return M>>>=0,j||y(M,4,this.length),16777216*this[M]+(this[M+1]<<16|this[M+2]<<8|this[M+3])},n.prototype.readIntLE=function(M,j,$){M>>>=0,j>>>=0,$||y(M,j,this.length);for(var K=this[M],J=1,X=0;++X<j&&(J*=256);)K+=this[M+X]*J;return K>=(J*=128)&&(K-=Math.pow(2,8*j)),K},n.prototype.readIntBE=function(M,j,$){M>>>=0,j>>>=0,$||y(M,j,this.length);for(var K=j,J=1,X=this[M+--K];K>0&&(J*=256);)X+=this[M+--K]*J;return X>=(J*=128)&&(X-=Math.pow(2,8*j)),X},n.prototype.readInt8=function(M,j){return M>>>=0,j||y(M,1,this.length),128&this[M]?-1*(255-this[M]+1):this[M]},n.prototype.readInt16LE=function(M,j){M>>>=0,j||y(M,2,this.length);var $=this[M]|this[M+1]<<8;return 32768&$?4294901760|$:$},n.prototype.readInt16BE=function(M,j){M>>>=0,j||y(M,2,this.length);var $=this[M+1]|this[M]<<8;return 32768&$?4294901760|$:$},n.prototype.readInt32LE=function(M,j){return M>>>=0,j||y(M,4,this.length),this[M]|this[M+1]<<8|this[M+2]<<16|this[M+3]<<24},n.prototype.readInt32BE=function(M,j){return M>>>=0,j||y(M,4,this.length),this[M]<<24|this[M+1]<<16|this[M+2]<<8|this[M+3]},n.prototype.readFloatLE=function(M,j){return M>>>=0,j||y(M,4,this.length),l.read(this,M,!0,23,4)},n.prototype.readFloatBE=function(M,j){return M>>>=0,j||y(M,4,this.length),l.read(this,M,!1,23,4)},n.prototype.readDoubleLE=function(M,j){return M>>>=0,j||y(M,8,this.length),l.read(this,M,!0,52,8)},n.prototype.readDoubleBE=function(M,j){return M>>>=0,j||y(M,8,this.length),l.read(this,M,!1,52,8)},n.prototype.writeUIntLE=function(M,j,$,K){M=+M,j>>>=0,$>>>=0,K||w(this,M,j,$,Math.pow(2,8*$)-1,0);var J=1,X=0;for(this[j]=255&M;++X<$&&(J*=256);)this[j+X]=M/J&255;return j+$},n.prototype.writeUIntBE=function(M,j,$,K){M=+M,j>>>=0,$>>>=0,K||w(this,M,j,$,Math.pow(2,8*$)-1,0);var J=$-1,X=1;for(this[j+J]=255&M;--J>=0&&(X*=256);)this[j+J]=M/X&255;return j+$},n.prototype.writeUInt8=function(M,j,$){return M=+M,j>>>=0,$||w(this,M,j,1,255,0),this[j]=255&M,j+1},n.prototype.writeUInt16LE=function(M,j,$){return M=+M,j>>>=0,$||w(this,M,j,2,65535,0),this[j]=255&M,this[j+1]=M>>>8,j+2},n.prototype.writeUInt16BE=function(M,j,$){return M=+M,j>>>=0,$||w(this,M,j,2,65535,0),this[j]=M>>>8,this[j+1]=255&M,j+2},n.prototype.writeUInt32LE=function(M,j,$){return M=+M,j>>>=0,$||w(this,M,j,4,4294967295,0),this[j+3]=M>>>24,this[j+2]=M>>>16,this[j+1]=M>>>8,this[j]=255&M,j+4},n.prototype.writeUInt32BE=function(M,j,$){return M=+M,j>>>=0,$||w(this,M,j,4,4294967295,0),this[j]=M>>>24,this[j+1]=M>>>16,this[j+2]=M>>>8,this[j+3]=255&M,j+4},n.prototype.writeIntLE=function(M,j,$,K){if(M=+M,j>>>=0,!K){var J=Math.pow(2,8*$-1);w(this,M,j,$,J-1,-J)}var X=0,Q=1,ee=0;for(this[j]=255&M;++X<$&&(Q*=256);)M<0&&ee===0&&this[j+X-1]!==0&&(ee=1),this[j+X]=(M/Q>>0)-ee&255;return j+$},n.prototype.writeIntBE=function(M,j,$,K){if(M=+M,j>>>=0,!K){var J=Math.pow(2,8*$-1);w(this,M,j,$,J-1,-J)}var X=$-1,Q=1,ee=0;for(this[j+X]=255&M;--X>=0&&(Q*=256);)M<0&&ee===0&&this[j+X+1]!==0&&(ee=1),this[j+X]=(M/Q>>0)-ee&255;return j+$},n.prototype.writeInt8=function(M,j,$){return M=+M,j>>>=0,$||w(this,M,j,1,127,-128),M<0&&(M=255+M+1),this[j]=255&M,j+1},n.prototype.writeInt16LE=function(M,j,$){return M=+M,j>>>=0,$||w(this,M,j,2,32767,-32768),this[j]=255&M,this[j+1]=M>>>8,j+2},n.prototype.writeInt16BE=function(M,j,$){return M=+M,j>>>=0,$||w(this,M,j,2,32767,-32768),this[j]=M>>>8,this[j+1]=255&M,j+2},n.prototype.writeInt32LE=function(M,j,$){return M=+M,j>>>=0,$||w(this,M,j,4,2147483647,-2147483648),this[j]=255&M,this[j+1]=M>>>8,this[j+2]=M>>>16,this[j+3]=M>>>24,j+4},n.prototype.writeInt32BE=function(M,j,$){return M=+M,j>>>=0,$||w(this,M,j,4,2147483647,-2147483648),M<0&&(M=4294967295+M+1),this[j]=M>>>24,this[j+1]=M>>>16,this[j+2]=M>>>8,this[j+3]=255&M,j+4},n.prototype.writeFloatLE=function(M,j,$){return S(this,M,j,!0,$)},n.prototype.writeFloatBE=function(M,j,$){return S(this,M,j,!1,$)},n.prototype.writeDoubleLE=function(M,j,$){return A(this,M,j,!0,$)},n.prototype.writeDoubleBE=function(M,j,$){return A(this,M,j,!1,$)},n.prototype.copy=function(M,j,$,K){if(!n.isBuffer(M))throw new TypeError("argument should be a Buffer");if($||($=0),K||K===0||(K=this.length),j>=M.length&&(j=M.length),j||(j=0),K>0&&K<$&&(K=$),K===$||M.length===0||this.length===0)return 0;if(j<0)throw new RangeError("targetStart out of bounds");if($<0||$>=this.length)throw new RangeError("Index out of range");if(K<0)throw new RangeError("sourceEnd out of bounds");K>this.length&&(K=this.length),M.length-j<K-$&&(K=M.length-j+$);var J=K-$;if(this===M&&typeof Uint8Array.prototype.copyWithin=="function")this.copyWithin(j,$,K);else if(this===M&&$<j&&j<K)for(var X=J-1;X>=0;--X)M[X+j]=this[X+$];else Uint8Array.prototype.set.call(M,this.subarray($,K),j);return J},n.prototype.fill=function(M,j,$,K){if(typeof M=="string"){if(typeof j=="string"?(K=j,j=0,$=this.length):typeof $=="string"&&(K=$,$=this.length),K!==void 0&&typeof K!="string")throw new TypeError("encoding must be a string");if(typeof K=="string"&&!n.isEncoding(K))throw new TypeError("Unknown encoding: "+K);if(M.length===1){var J=M.charCodeAt(0);(K==="utf8"&&J<128||K==="latin1")&&(M=J)}}else typeof M=="number"&&(M&=255);if(j<0||this.length<j||this.length<$)throw new RangeError("Out of range index");if($<=j)return this;var X;if(j>>>=0,$=$===void 0?this.length:$>>>0,M||(M=0),typeof M=="number")for(X=j;X<$;++X)this[X]=M;else{var Q=n.isBuffer(M)?M:n.from(M,K),ee=Q.length;if(ee===0)throw new TypeError('The value "'+M+'" is invalid for argument "value"');for(X=0;X<$-j;++X)this[X+j]=Q[X%ee]}return this};var O=/[^+/0-9A-Za-z-_]/g;function N(M){return M<16?"0"+M.toString(16):M.toString(16)}function U(M,j){var $;j=j||1/0;for(var K=M.length,J=null,X=[],Q=0;Q<K;++Q){if(($=M.charCodeAt(Q))>55295&&$<57344){if(!J){if($>56319){(j-=3)>-1&&X.push(239,191,189);continue}if(Q+1===K){(j-=3)>-1&&X.push(239,191,189);continue}J=$;continue}if($<56320){(j-=3)>-1&&X.push(239,191,189),J=$;continue}$=65536+(J-55296<<10|$-56320)}else J&&(j-=3)>-1&&X.push(239,191,189);if(J=null,$<128){if((j-=1)<0)break;X.push($)}else if($<2048){if((j-=2)<0)break;X.push($>>6|192,63&$|128)}else if($<65536){if((j-=3)<0)break;X.push($>>12|224,$>>6&63|128,63&$|128)}else{if(!($<1114112))throw new Error("Invalid code point");if((j-=4)<0)break;X.push($>>18|240,$>>12&63|128,$>>6&63|128,63&$|128)}}return X}function H(M){return s.toByteArray(function(j){if((j=(j=j.split("=")[0]).trim().replace(O,"")).length<2)return"";for(;j.length%4!=0;)j+="=";return j}(M))}function Z(M,j,$,K){for(var J=0;J<K&&!(J+$>=j.length||J>=M.length);++J)j[J+$]=M[J];return J}function D(M,j){return M instanceof j||M!=null&&M.constructor!=null&&M.constructor.name!=null&&M.constructor.name===j.name}function q(M){return M!=M}}).call(this)}).call(this,e("buffer").Buffer)},{"base64-js":185,buffer:220,ieee754:439}],221:[function(e,a,f){var c=e("safe-buffer").Buffer,s=e("stream").Transform,l=e("string_decoder").StringDecoder;function i(n){s.call(this),this.hashMode=typeof n=="string",this.hashMode?this[n]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}e("inherits")(i,s),i.prototype.update=function(n,o,h){typeof n=="string"&&(n=c.from(n,o));var u=this._update(n);return this.hashMode?this:(h&&(u=this._toString(u,h)),u)},i.prototype.setAutoPadding=function(){},i.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},i.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},i.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},i.prototype._transform=function(n,o,h){var u;try{this.hashMode?this._update(n):this.push(this._update(n))}catch(d){u=d}finally{h(u)}},i.prototype._flush=function(n){var o;try{this.push(this.__final())}catch(h){o=h}n(o)},i.prototype._finalOrDigest=function(n){var o=this.__final()||c.alloc(0);return n&&(o=this._toString(o,n,!0)),o},i.prototype._toString=function(n,o,h){if(this._decoder||(this._decoder=new l(o),this._encoding=o),this._encoding!==o)throw new Error("can't switch encodings");var u=this._decoder.write(n);return h&&(u+=this._decoder.end()),u},a.exports=i},{inherits:440,"safe-buffer":494,stream:505,string_decoder:218}],222:[function(e,a,f){var c=e("../internals/is-callable"),s=e("../internals/try-to-string"),l=TypeError;a.exports=function(i){if(c(i))return i;throw new l(s(i)+" is not a function")}},{"../internals/is-callable":285,"../internals/try-to-string":349}],223:[function(e,a,f){var c=e("../internals/is-constructor"),s=e("../internals/try-to-string"),l=TypeError;a.exports=function(i){if(c(i))return i;throw new l(s(i)+" is not a constructor")}},{"../internals/is-constructor":286,"../internals/try-to-string":349}],224:[function(e,a,f){var c=e("../internals/is-callable"),s=String,l=TypeError;a.exports=function(i){if(typeof i=="object"||c(i))return i;throw new l("Can't set "+s(i)+" as a prototype")}},{"../internals/is-callable":285}],225:[function(e,a,f){var c=e("../internals/well-known-symbol"),s=e("../internals/object-create"),l=e("../internals/object-define-property").f,i=c("unscopables"),n=Array.prototype;n[i]===void 0&&l(n,i,{configurable:!0,value:s(null)}),a.exports=function(o){n[i][o]=!0}},{"../internals/object-create":306,"../internals/object-define-property":308,"../internals/well-known-symbol":357}],226:[function(e,a,f){var c=e("../internals/object-is-prototype-of"),s=TypeError;a.exports=function(l,i){if(c(i,l))return l;throw new s("Incorrect invocation")}},{"../internals/object-is-prototype-of":314}],227:[function(e,a,f){var c=e("../internals/is-object"),s=String,l=TypeError;a.exports=function(i){if(c(i))return i;throw new l(s(i)+" is not an object")}},{"../internals/is-object":289}],228:[function(e,a,f){var c=e("../internals/to-indexed-object"),s=e("../internals/to-absolute-index"),l=e("../internals/length-of-array-like"),i=function(n){return function(o,h,u){var d,m=c(o),b=l(m),p=s(u,b);if(n&&h!=h){for(;b>p;)if((d=m[p++])!=d)return!0}else for(;b>p;p++)if((n||p in m)&&m[p]===h)return n||p||0;return!n&&-1}};a.exports={includes:i(!0),indexOf:i(!1)}},{"../internals/length-of-array-like":299,"../internals/to-absolute-index":340,"../internals/to-indexed-object":341}],229:[function(e,a,f){var c=e("../internals/function-bind-context"),s=e("../internals/function-uncurry-this"),l=e("../internals/indexed-object"),i=e("../internals/to-object"),n=e("../internals/length-of-array-like"),o=e("../internals/array-species-create"),h=s([].push),u=function(d){var m=d===1,b=d===2,p=d===3,v=d===4,g=d===6,x=d===7,C=d===5||g;return function(T,R,B,I){for(var F,L,V=i(T),z=l(V),E=c(R,B),P=n(z),k=0,y=I||o,w=m?y(T,P):b||x?y(T,0):void 0;P>k;k++)if((C||k in z)&&(L=E(F=z[k],k,V),d))if(m)w[k]=L;else if(L)switch(d){case 3:return!0;case 5:return F;case 6:return k;case 2:h(w,F)}else switch(d){case 4:return!1;case 7:h(w,F)}return g?-1:p||v?v:w}};a.exports={forEach:u(0),map:u(1),filter:u(2),some:u(3),every:u(4),find:u(5),findIndex:u(6),filterReject:u(7)}},{"../internals/array-species-create":233,"../internals/function-bind-context":262,"../internals/function-uncurry-this":268,"../internals/indexed-object":280,"../internals/length-of-array-like":299,"../internals/to-object":344}],230:[function(e,a,f){var c=e("../internals/to-absolute-index"),s=e("../internals/length-of-array-like"),l=e("../internals/create-property"),i=Array,n=Math.max;a.exports=function(o,h,u){for(var d=s(o),m=c(h,d),b=c(u===void 0?d:u,d),p=i(n(b-m,0)),v=0;m<b;m++,v++)l(p,v,o[m]);return p.length=v,p}},{"../internals/create-property":243,"../internals/length-of-array-like":299,"../internals/to-absolute-index":340}],231:[function(e,a,f){var c=e("../internals/function-uncurry-this");a.exports=c([].slice)},{"../internals/function-uncurry-this":268}],232:[function(e,a,f){var c=e("../internals/is-array"),s=e("../internals/is-constructor"),l=e("../internals/is-object"),i=e("../internals/well-known-symbol")("species"),n=Array;a.exports=function(o){var h;return c(o)&&(h=o.constructor,(s(h)&&(h===n||c(h.prototype))||l(h)&&(h=h[i])===null)&&(h=void 0)),h===void 0?n:h}},{"../internals/is-array":284,"../internals/is-constructor":286,"../internals/is-object":289,"../internals/well-known-symbol":357}],233:[function(e,a,f){var c=e("../internals/array-species-constructor");a.exports=function(s,l){return new(c(s))(l===0?0:l)}},{"../internals/array-species-constructor":232}],234:[function(e,a,f){var c=e("../internals/well-known-symbol")("iterator"),s=!1;try{var l=0,i={next:function(){return{done:!!l++}},return:function(){s=!0}};i[c]=function(){return this},Array.from(i,function(){throw 2})}catch{}a.exports=function(n,o){try{if(!o&&!s)return!1}catch{return!1}var h=!1;try{var u={};u[c]=function(){return{next:function(){return{done:h=!0}}}},n(u)}catch{}return h}},{"../internals/well-known-symbol":357}],235:[function(e,a,f){var c=e("../internals/function-uncurry-this"),s=c({}.toString),l=c("".slice);a.exports=function(i){return l(s(i),8,-1)}},{"../internals/function-uncurry-this":268}],236:[function(e,a,f){var c=e("../internals/to-string-tag-support"),s=e("../internals/is-callable"),l=e("../internals/classof-raw"),i=e("../internals/well-known-symbol")("toStringTag"),n=Object,o=l(function(){return arguments}())==="Arguments";a.exports=c?l:function(h){var u,d,m;return h===void 0?"Undefined":h===null?"Null":typeof(d=function(b,p){try{return b[p]}catch{}}(u=n(h),i))=="string"?d:o?l(u):(m=l(u))==="Object"&&s(u.callee)?"Arguments":m}},{"../internals/classof-raw":235,"../internals/is-callable":285,"../internals/to-string-tag-support":347,"../internals/well-known-symbol":357}],237:[function(e,a,f){var c=e("../internals/has-own-property"),s=e("../internals/own-keys"),l=e("../internals/object-get-own-property-descriptor"),i=e("../internals/object-define-property");a.exports=function(n,o,h){for(var u=s(o),d=i.f,m=l.f,b=0;b<u.length;b++){var p=u[b];c(n,p)||h&&c(h,p)||d(n,p,m(o,p))}}},{"../internals/has-own-property":275,"../internals/object-define-property":308,"../internals/object-get-own-property-descriptor":309,"../internals/own-keys":321}],238:[function(e,a,f){var c=e("../internals/well-known-symbol")("match");a.exports=function(s){var l=/./;try{"/./"[s](l)}catch{try{return l[c]=!1,"/./"[s](l)}catch{}}return!1}},{"../internals/well-known-symbol":357}],239:[function(e,a,f){var c=e("../internals/fails");a.exports=!c(function(){function s(){}return s.prototype.constructor=null,Object.getPrototypeOf(new s)!==s.prototype})},{"../internals/fails":260}],240:[function(e,a,f){a.exports=function(c,s){return{value:c,done:s}}},{}],241:[function(e,a,f){var c=e("../internals/descriptors"),s=e("../internals/object-define-property"),l=e("../internals/create-property-descriptor");a.exports=c?function(i,n,o){return s.f(i,n,l(1,o))}:function(i,n,o){return i[n]=o,i}},{"../internals/create-property-descriptor":242,"../internals/descriptors":247,"../internals/object-define-property":308}],242:[function(e,a,f){a.exports=function(c,s){return{enumerable:!(1&c),configurable:!(2&c),writable:!(4&c),value:s}}},{}],243:[function(e,a,f){var c=e("../internals/to-property-key"),s=e("../internals/object-define-property"),l=e("../internals/create-property-descriptor");a.exports=function(i,n,o){var h=c(n);h in i?s.f(i,h,l(0,o)):i[h]=o}},{"../internals/create-property-descriptor":242,"../internals/object-define-property":308,"../internals/to-property-key":346}],244:[function(e,a,f){var c=e("../internals/make-built-in"),s=e("../internals/object-define-property");a.exports=function(l,i,n){return n.get&&c(n.get,i,{getter:!0}),n.set&&c(n.set,i,{setter:!0}),s.f(l,i,n)}},{"../internals/make-built-in":300,"../internals/object-define-property":308}],245:[function(e,a,f){var c=e("../internals/is-callable"),s=e("../internals/object-define-property"),l=e("../internals/make-built-in"),i=e("../internals/define-global-property");a.exports=function(n,o,h,u){u||(u={});var d=u.enumerable,m=u.name!==void 0?u.name:o;if(c(h)&&l(h,m,u),u.global)d?n[o]=h:i(o,h);else{try{u.unsafe?n[o]&&(d=!0):delete n[o]}catch{}d?n[o]=h:s.f(n,o,{value:h,enumerable:!1,configurable:!u.nonConfigurable,writable:!u.nonWritable})}return n}},{"../internals/define-global-property":246,"../internals/is-callable":285,"../internals/make-built-in":300,"../internals/object-define-property":308}],246:[function(e,a,f){var c=e("../internals/global"),s=Object.defineProperty;a.exports=function(l,i){try{s(c,l,{value:i,configurable:!0,writable:!0})}catch{c[l]=i}return i}},{"../internals/global":274}],247:[function(e,a,f){var c=e("../internals/fails");a.exports=!c(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7})},{"../internals/fails":260}],248:[function(e,a,f){var c=typeof document=="object"&&document.all,s=c===void 0&&c!==void 0;a.exports={all:c,IS_HTMLDDA:s}},{}],249:[function(e,a,f){var c=e("../internals/global"),s=e("../internals/is-object"),l=c.document,i=s(l)&&s(l.createElement);a.exports=function(n){return i?l.createElement(n):{}}},{"../internals/global":274,"../internals/is-object":289}],250:[function(e,a,f){var c=e("../internals/engine-is-deno"),s=e("../internals/engine-is-node");a.exports=!c&&!s&&typeof window=="object"&&typeof document=="object"},{"../internals/engine-is-deno":251,"../internals/engine-is-node":254}],251:[function(e,a,f){a.exports=typeof Deno=="object"&&Deno&&typeof Deno.version=="object"},{}],252:[function(e,a,f){var c=e("../internals/engine-user-agent");a.exports=/ipad|iphone|ipod/i.test(c)&&typeof Pebble<"u"},{"../internals/engine-user-agent":256}],253:[function(e,a,f){var c=e("../internals/engine-user-agent");a.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(c)},{"../internals/engine-user-agent":256}],254:[function(e,a,f){var c=e("../internals/global"),s=e("../internals/classof-raw");a.exports=s(c.process)==="process"},{"../internals/classof-raw":235,"../internals/global":274}],255:[function(e,a,f){var c=e("../internals/engine-user-agent");a.exports=/web0s(?!.*chrome)/i.test(c)},{"../internals/engine-user-agent":256}],256:[function(e,a,f){a.exports=typeof navigator<"u"&&String(navigator.userAgent)||""},{}],257:[function(e,a,f){var c,s,l=e("../internals/global"),i=e("../internals/engine-user-agent"),n=l.process,o=l.Deno,h=n&&n.versions||o&&o.version,u=h&&h.v8;u&&(s=(c=u.split("."))[0]>0&&c[0]<4?1:+(c[0]+c[1])),!s&&i&&(!(c=i.match(/Edge\/(\d+)/))||c[1]>=74)&&(c=i.match(/Chrome\/(\d+)/))&&(s=+c[1]),a.exports=s},{"../internals/engine-user-agent":256,"../internals/global":274}],258:[function(e,a,f){a.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},{}],259:[function(e,a,f){var c=e("../internals/global"),s=e("../internals/object-get-own-property-descriptor").f,l=e("../internals/create-non-enumerable-property"),i=e("../internals/define-built-in"),n=e("../internals/define-global-property"),o=e("../internals/copy-constructor-properties"),h=e("../internals/is-forced");a.exports=function(u,d){var m,b,p,v,g,x=u.target,C=u.global,T=u.stat;if(m=C?c:T?c[x]||n(x,{}):(c[x]||{}).prototype)for(b in d){if(v=d[b],p=u.dontCallGetSet?(g=s(m,b))&&g.value:m[b],!h(C?b:x+(T?".":"#")+b,u.forced)&&p!==void 0){if(typeof v==typeof p)continue;o(v,p)}(u.sham||p&&p.sham)&&l(v,"sham",!0),i(m,b,v,u)}}},{"../internals/copy-constructor-properties":237,"../internals/create-non-enumerable-property":241,"../internals/define-built-in":245,"../internals/define-global-property":246,"../internals/global":274,"../internals/is-forced":287,"../internals/object-get-own-property-descriptor":309}],260:[function(e,a,f){a.exports=function(c){try{return!!c()}catch{return!0}}},{}],261:[function(e,a,f){var c=e("../internals/function-bind-native"),s=Function.prototype,l=s.apply,i=s.call;a.exports=typeof Reflect=="object"&&Reflect.apply||(c?i.bind(l):function(){return i.apply(l,arguments)})},{"../internals/function-bind-native":263}],262:[function(e,a,f){var c=e("../internals/function-uncurry-this-clause"),s=e("../internals/a-callable"),l=e("../internals/function-bind-native"),i=c(c.bind);a.exports=function(n,o){return s(n),o===void 0?n:l?i(n,o):function(){return n.apply(o,arguments)}}},{"../internals/a-callable":222,"../internals/function-bind-native":263,"../internals/function-uncurry-this-clause":267}],263:[function(e,a,f){var c=e("../internals/fails");a.exports=!c(function(){var s=function(){}.bind();return typeof s!="function"||s.hasOwnProperty("prototype")})},{"../internals/fails":260}],264:[function(e,a,f){var c=e("../internals/function-bind-native"),s=Function.prototype.call;a.exports=c?s.bind(s):function(){return s.apply(s,arguments)}},{"../internals/function-bind-native":263}],265:[function(e,a,f){var c=e("../internals/descriptors"),s=e("../internals/has-own-property"),l=Function.prototype,i=c&&Object.getOwnPropertyDescriptor,n=s(l,"name"),o=n&&function(){}.name==="something",h=n&&(!c||c&&i(l,"name").configurable);a.exports={EXISTS:n,PROPER:o,CONFIGURABLE:h}},{"../internals/descriptors":247,"../internals/has-own-property":275}],266:[function(e,a,f){var c=e("../internals/function-uncurry-this"),s=e("../internals/a-callable");a.exports=function(l,i,n){try{return c(s(Object.getOwnPropertyDescriptor(l,i)[n]))}catch{}}},{"../internals/a-callable":222,"../internals/function-uncurry-this":268}],267:[function(e,a,f){var c=e("../internals/classof-raw"),s=e("../internals/function-uncurry-this");a.exports=function(l){if(c(l)==="Function")return s(l)}},{"../internals/classof-raw":235,"../internals/function-uncurry-this":268}],268:[function(e,a,f){var c=e("../internals/function-bind-native"),s=Function.prototype,l=s.call,i=c&&s.bind.bind(l,l);a.exports=c?i:function(n){return function(){return l.apply(n,arguments)}}},{"../internals/function-bind-native":263}],269:[function(e,a,f){var c=e("../internals/global"),s=e("../internals/is-callable"),l=function(i){return s(i)?i:void 0};a.exports=function(i,n){return arguments.length<2?l(c[i]):c[i]&&c[i][n]}},{"../internals/global":274,"../internals/is-callable":285}],270:[function(e,a,f){var c=e("../internals/classof"),s=e("../internals/get-method"),l=e("../internals/is-null-or-undefined"),i=e("../internals/iterators"),n=e("../internals/well-known-symbol")("iterator");a.exports=function(o){if(!l(o))return s(o,n)||s(o,"@@iterator")||i[c(o)]}},{"../internals/classof":236,"../internals/get-method":273,"../internals/is-null-or-undefined":288,"../internals/iterators":298,"../internals/well-known-symbol":357}],271:[function(e,a,f){var c=e("../internals/function-call"),s=e("../internals/a-callable"),l=e("../internals/an-object"),i=e("../internals/try-to-string"),n=e("../internals/get-iterator-method"),o=TypeError;a.exports=function(h,u){var d=arguments.length<2?n(h):u;if(s(d))return l(c(d,h));throw new o(i(h)+" is not iterable")}},{"../internals/a-callable":222,"../internals/an-object":227,"../internals/function-call":264,"../internals/get-iterator-method":270,"../internals/try-to-string":349}],272:[function(e,a,f){var c=e("../internals/function-uncurry-this"),s=e("../internals/is-array"),l=e("../internals/is-callable"),i=e("../internals/classof-raw"),n=e("../internals/to-string"),o=c([].push);a.exports=function(h){if(l(h))return h;if(s(h)){for(var u=h.length,d=[],m=0;m<u;m++){var b=h[m];typeof b=="string"?o(d,b):typeof b!="number"&&i(b)!=="Number"&&i(b)!=="String"||o(d,n(b))}var p=d.length,v=!0;return function(g,x){if(v)return v=!1,x;if(s(this))return x;for(var C=0;C<p;C++)if(d[C]===g)return x}}}},{"../internals/classof-raw":235,"../internals/function-uncurry-this":268,"../internals/is-array":284,"../internals/is-callable":285,"../internals/to-string":348}],273:[function(e,a,f){var c=e("../internals/a-callable"),s=e("../internals/is-null-or-undefined");a.exports=function(l,i){var n=l[i];return s(n)?void 0:c(n)}},{"../internals/a-callable":222,"../internals/is-null-or-undefined":288}],274:[function(e,a,f){(function(c){(function(){var s=function(l){return l&&l.Math===Math&&l};a.exports=s(typeof globalThis=="object"&&globalThis)||s(typeof window=="object"&&window)||s(typeof self=="object"&&self)||s(typeof c=="object"&&c)||function(){return this}()||this||Function("return this")()}).call(this)}).call(this,typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{}],275:[function(e,a,f){var c=e("../internals/function-uncurry-this"),s=e("../internals/to-object"),l=c({}.hasOwnProperty);a.exports=Object.hasOwn||function(i,n){return l(s(i),n)}},{"../internals/function-uncurry-this":268,"../internals/to-object":344}],276:[function(e,a,f){a.exports={}},{}],277:[function(e,a,f){a.exports=function(c,s){try{arguments.length===1?console.error(c):console.error(c,s)}catch{}}},{}],278:[function(e,a,f){var c=e("../internals/get-built-in");a.exports=c("document","documentElement")},{"../internals/get-built-in":269}],279:[function(e,a,f){var c=e("../internals/descriptors"),s=e("../internals/fails"),l=e("../internals/document-create-element");a.exports=!c&&!s(function(){return Object.defineProperty(l("div"),"a",{get:function(){return 7}}).a!==7})},{"../internals/descriptors":247,"../internals/document-create-element":249,"../internals/fails":260}],280:[function(e,a,f){var c=e("../internals/function-uncurry-this"),s=e("../internals/fails"),l=e("../internals/classof-raw"),i=Object,n=c("".split);a.exports=s(function(){return!i("z").propertyIsEnumerable(0)})?function(o){return l(o)==="String"?n(o,""):i(o)}:i},{"../internals/classof-raw":235,"../internals/fails":260,"../internals/function-uncurry-this":268}],281:[function(e,a,f){var c=e("../internals/function-uncurry-this"),s=e("../internals/is-callable"),l=e("../internals/shared-store"),i=c(Function.toString);s(l.inspectSource)||(l.inspectSource=function(n){return i(n)}),a.exports=l.inspectSource},{"../internals/function-uncurry-this":268,"../internals/is-callable":285,"../internals/shared-store":333}],282:[function(e,a,f){var c,s,l,i=e("../internals/weak-map-basic-detection"),n=e("../internals/global"),o=e("../internals/is-object"),h=e("../internals/create-non-enumerable-property"),u=e("../internals/has-own-property"),d=e("../internals/shared-store"),m=e("../internals/shared-key"),b=e("../internals/hidden-keys"),p=n.TypeError,v=n.WeakMap;if(i||d.state){var g=d.state||(d.state=new v);g.get=g.get,g.has=g.has,g.set=g.set,c=function(C,T){if(g.has(C))throw new p("Object already initialized");return T.facade=C,g.set(C,T),T},s=function(C){return g.get(C)||{}},l=function(C){return g.has(C)}}else{var x=m("state");b[x]=!0,c=function(C,T){if(u(C,x))throw new p("Object already initialized");return T.facade=C,h(C,x,T),T},s=function(C){return u(C,x)?C[x]:{}},l=function(C){return u(C,x)}}a.exports={set:c,get:s,has:l,enforce:function(C){return l(C)?s(C):c(C,{})},getterFor:function(C){return function(T){var R;if(!o(T)||(R=s(T)).type!==C)throw new p("Incompatible receiver, "+C+" required");return R}}}},{"../internals/create-non-enumerable-property":241,"../internals/global":274,"../internals/has-own-property":275,"../internals/hidden-keys":276,"../internals/is-object":289,"../internals/shared-key":332,"../internals/shared-store":333,"../internals/weak-map-basic-detection":354}],283:[function(e,a,f){var c=e("../internals/well-known-symbol"),s=e("../internals/iterators"),l=c("iterator"),i=Array.prototype;a.exports=function(n){return n!==void 0&&(s.Array===n||i[l]===n)}},{"../internals/iterators":298,"../internals/well-known-symbol":357}],284:[function(e,a,f){var c=e("../internals/classof-raw");a.exports=Array.isArray||function(s){return c(s)==="Array"}},{"../internals/classof-raw":235}],285:[function(e,a,f){var c=e("../internals/document-all"),s=c.all;a.exports=c.IS_HTMLDDA?function(l){return typeof l=="function"||l===s}:function(l){return typeof l=="function"}},{"../internals/document-all":248}],286:[function(e,a,f){var c=e("../internals/function-uncurry-this"),s=e("../internals/fails"),l=e("../internals/is-callable"),i=e("../internals/classof"),n=e("../internals/get-built-in"),o=e("../internals/inspect-source"),h=function(){},u=[],d=n("Reflect","construct"),m=/^\s*(?:class|function)\b/,b=c(m.exec),p=!m.test(h),v=function(x){if(!l(x))return!1;try{return d(h,u,x),!0}catch{return!1}},g=function(x){if(!l(x))return!1;switch(i(x)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return p||!!b(m,o(x))}catch{return!0}};g.sham=!0,a.exports=!d||s(function(){var x;return v(v.call)||!v(Object)||!v(function(){x=!0})||x})?g:v},{"../internals/classof":236,"../internals/fails":260,"../internals/function-uncurry-this":268,"../internals/get-built-in":269,"../internals/inspect-source":281,"../internals/is-callable":285}],287:[function(e,a,f){var c=e("../internals/fails"),s=e("../internals/is-callable"),l=/#|\.prototype\./,i=function(d,m){var b=o[n(d)];return b===u||b!==h&&(s(m)?c(m):!!m)},n=i.normalize=function(d){return String(d).replace(l,".").toLowerCase()},o=i.data={},h=i.NATIVE="N",u=i.POLYFILL="P";a.exports=i},{"../internals/fails":260,"../internals/is-callable":285}],288:[function(e,a,f){a.exports=function(c){return c==null}},{}],289:[function(e,a,f){var c=e("../internals/is-callable"),s=e("../internals/document-all"),l=s.all;a.exports=s.IS_HTMLDDA?function(i){return typeof i=="object"?i!==null:c(i)||i===l}:function(i){return typeof i=="object"?i!==null:c(i)}},{"../internals/document-all":248,"../internals/is-callable":285}],290:[function(e,a,f){a.exports=!1},{}],291:[function(e,a,f){var c=e("../internals/is-object"),s=e("../internals/classof-raw"),l=e("../internals/well-known-symbol")("match");a.exports=function(i){var n;return c(i)&&((n=i[l])!==void 0?!!n:s(i)==="RegExp")}},{"../internals/classof-raw":235,"../internals/is-object":289,"../internals/well-known-symbol":357}],292:[function(e,a,f){var c=e("../internals/get-built-in"),s=e("../internals/is-callable"),l=e("../internals/object-is-prototype-of"),i=e("../internals/use-symbol-as-uid"),n=Object;a.exports=i?function(o){return typeof o=="symbol"}:function(o){var h=c("Symbol");return s(h)&&l(h.prototype,n(o))}},{"../internals/get-built-in":269,"../internals/is-callable":285,"../internals/object-is-prototype-of":314,"../internals/use-symbol-as-uid":351}],293:[function(e,a,f){var c=e("../internals/function-bind-context"),s=e("../internals/function-call"),l=e("../internals/an-object"),i=e("../internals/try-to-string"),n=e("../internals/is-array-iterator-method"),o=e("../internals/length-of-array-like"),h=e("../internals/object-is-prototype-of"),u=e("../internals/get-iterator"),d=e("../internals/get-iterator-method"),m=e("../internals/iterator-close"),b=TypeError,p=function(g,x){this.stopped=g,this.result=x},v=p.prototype;a.exports=function(g,x,C){var T,R,B,I,F,L,V,z=C&&C.that,E=!(!C||!C.AS_ENTRIES),P=!(!C||!C.IS_RECORD),k=!(!C||!C.IS_ITERATOR),y=!(!C||!C.INTERRUPTED),w=c(x,z),_=function(A){return T&&m(T,"normal",A),new p(!0,A)},S=function(A){return E?(l(A),y?w(A[0],A[1],_):w(A[0],A[1])):y?w(A,_):w(A)};if(P)T=g.iterator;else if(k)T=g;else{if(!(R=d(g)))throw new b(i(g)+" is not iterable");if(n(R)){for(B=0,I=o(g);I>B;B++)if((F=S(g[B]))&&h(v,F))return F;return new p(!1)}T=u(g,R)}for(L=P?g.next:T.next;!(V=s(L,T)).done;){try{F=S(V.value)}catch(A){m(T,"throw",A)}if(typeof F=="object"&&F&&h(v,F))return F}return new p(!1)}},{"../internals/an-object":227,"../internals/function-bind-context":262,"../internals/function-call":264,"../internals/get-iterator":271,"../internals/get-iterator-method":270,"../internals/is-array-iterator-method":283,"../internals/iterator-close":294,"../internals/length-of-array-like":299,"../internals/object-is-prototype-of":314,"../internals/try-to-string":349}],294:[function(e,a,f){var c=e("../internals/function-call"),s=e("../internals/an-object"),l=e("../internals/get-method");a.exports=function(i,n,o){var h,u;s(i);try{if(!(h=l(i,"return"))){if(n==="throw")throw o;return o}h=c(h,i)}catch(d){u=!0,h=d}if(n==="throw")throw o;if(u)throw h;return s(h),o}},{"../internals/an-object":227,"../internals/function-call":264,"../internals/get-method":273}],295:[function(e,a,f){var c=e("../internals/iterators-core").IteratorPrototype,s=e("../internals/object-create"),l=e("../internals/create-property-descriptor"),i=e("../internals/set-to-string-tag"),n=e("../internals/iterators"),o=function(){return this};a.exports=function(h,u,d,m){var b=u+" Iterator";return h.prototype=s(c,{next:l(+!m,d)}),i(h,b,!1,!0),n[b]=o,h}},{"../internals/create-property-descriptor":242,"../internals/iterators":298,"../internals/iterators-core":297,"../internals/object-create":306,"../internals/set-to-string-tag":331}],296:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/function-call"),l=e("../internals/is-pure"),i=e("../internals/function-name"),n=e("../internals/is-callable"),o=e("../internals/iterator-create-constructor"),h=e("../internals/object-get-prototype-of"),u=e("../internals/object-set-prototype-of"),d=e("../internals/set-to-string-tag"),m=e("../internals/create-non-enumerable-property"),b=e("../internals/define-built-in"),p=e("../internals/well-known-symbol"),v=e("../internals/iterators"),g=e("../internals/iterators-core"),x=i.PROPER,C=i.CONFIGURABLE,T=g.IteratorPrototype,R=g.BUGGY_SAFARI_ITERATORS,B=p("iterator"),I=function(){return this};a.exports=function(F,L,V,z,E,P,k){o(V,L,z);var y,w,_,S=function(D){if(D===E&&H)return H;if(!R&&D&&D in N)return N[D];switch(D){case"keys":case"values":case"entries":return function(){return new V(this,D)}}return function(){return new V(this)}},A=L+" Iterator",O=!1,N=F.prototype,U=N[B]||N["@@iterator"]||E&&N[E],H=!R&&U||S(E),Z=L==="Array"&&N.entries||U;if(Z&&(y=h(Z.call(new F)))!==Object.prototype&&y.next&&(l||h(y)===T||(u?u(y,T):n(y[B])||b(y,B,I)),d(y,A,!0,!0),l&&(v[A]=I)),x&&E==="values"&&U&&U.name!=="values"&&(!l&&C?m(N,"name","values"):(O=!0,H=function(){return s(U,this)})),E)if(w={values:S("values"),keys:P?H:S("keys"),entries:S("entries")},k)for(_ in w)(R||O||!(_ in N))&&b(N,_,w[_]);else c({target:L,proto:!0,forced:R||O},w);return l&&!k||N[B]===H||b(N,B,H,{name:E}),v[L]=H,w}},{"../internals/create-non-enumerable-property":241,"../internals/define-built-in":245,"../internals/export":259,"../internals/function-call":264,"../internals/function-name":265,"../internals/is-callable":285,"../internals/is-pure":290,"../internals/iterator-create-constructor":295,"../internals/iterators":298,"../internals/iterators-core":297,"../internals/object-get-prototype-of":313,"../internals/object-set-prototype-of":318,"../internals/set-to-string-tag":331,"../internals/well-known-symbol":357}],297:[function(e,a,f){var c,s,l,i=e("../internals/fails"),n=e("../internals/is-callable"),o=e("../internals/is-object"),h=e("../internals/object-create"),u=e("../internals/object-get-prototype-of"),d=e("../internals/define-built-in"),m=e("../internals/well-known-symbol"),b=e("../internals/is-pure"),p=m("iterator"),v=!1;[].keys&&("next"in(l=[].keys())?(s=u(u(l)))!==Object.prototype&&(c=s):v=!0),!o(c)||i(function(){var g={};return c[p].call(g)!==g})?c={}:b&&(c=h(c)),n(c[p])||d(c,p,function(){return this}),a.exports={IteratorPrototype:c,BUGGY_SAFARI_ITERATORS:v}},{"../internals/define-built-in":245,"../internals/fails":260,"../internals/is-callable":285,"../internals/is-object":289,"../internals/is-pure":290,"../internals/object-create":306,"../internals/object-get-prototype-of":313,"../internals/well-known-symbol":357}],298:[function(e,a,f){arguments[4][276][0].apply(f,arguments)},{dup:276}],299:[function(e,a,f){var c=e("../internals/to-length");a.exports=function(s){return c(s.length)}},{"../internals/to-length":343}],300:[function(e,a,f){var c=e("../internals/function-uncurry-this"),s=e("../internals/fails"),l=e("../internals/is-callable"),i=e("../internals/has-own-property"),n=e("../internals/descriptors"),o=e("../internals/function-name").CONFIGURABLE,h=e("../internals/inspect-source"),u=e("../internals/internal-state"),d=u.enforce,m=u.get,b=String,p=Object.defineProperty,v=c("".slice),g=c("".replace),x=c([].join),C=n&&!s(function(){return p(function(){},"length",{value:8}).length!==8}),T=String(String).split("String"),R=a.exports=function(B,I,F){v(b(I),0,7)==="Symbol("&&(I="["+g(b(I),/^Symbol\(([^)]*)\)/,"$1")+"]"),F&&F.getter&&(I="get "+I),F&&F.setter&&(I="set "+I),(!i(B,"name")||o&&B.name!==I)&&(n?p(B,"name",{value:I,configurable:!0}):B.name=I),C&&F&&i(F,"arity")&&B.length!==F.arity&&p(B,"length",{value:F.arity});try{F&&i(F,"constructor")&&F.constructor?n&&p(B,"prototype",{writable:!1}):B.prototype&&(B.prototype=void 0)}catch{}var L=d(B);return i(L,"source")||(L.source=x(T,typeof I=="string"?I:"")),B};Function.prototype.toString=R(function(){return l(this)&&m(this).source||h(this)},"toString")},{"../internals/descriptors":247,"../internals/fails":260,"../internals/function-name":265,"../internals/function-uncurry-this":268,"../internals/has-own-property":275,"../internals/inspect-source":281,"../internals/internal-state":282,"../internals/is-callable":285}],301:[function(e,a,f){var c=Math.ceil,s=Math.floor;a.exports=Math.trunc||function(l){var i=+l;return(i>0?s:c)(i)}},{}],302:[function(e,a,f){var c,s,l,i,n,o=e("../internals/global"),h=e("../internals/function-bind-context"),u=e("../internals/object-get-own-property-descriptor").f,d=e("../internals/task").set,m=e("../internals/queue"),b=e("../internals/engine-is-ios"),p=e("../internals/engine-is-ios-pebble"),v=e("../internals/engine-is-webos-webkit"),g=e("../internals/engine-is-node"),x=o.MutationObserver||o.WebKitMutationObserver,C=o.document,T=o.process,R=o.Promise,B=u(o,"queueMicrotask"),I=B&&B.value;if(!I){var F=new m,L=function(){var V,z;for(g&&(V=T.domain)&&V.exit();z=F.get();)try{z()}catch(E){throw F.head&&c(),E}V&&V.enter()};b||g||v||!x||!C?!p&&R&&R.resolve?((i=R.resolve(void 0)).constructor=R,n=h(i.then,i),c=function(){n(L)}):g?c=function(){T.nextTick(L)}:(d=h(d,o),c=function(){d(L)}):(s=!0,l=C.createTextNode(""),new x(L).observe(l,{characterData:!0}),c=function(){l.data=s=!s}),I=function(V){F.head||c(),F.add(V)}}a.exports=I},{"../internals/engine-is-ios":253,"../internals/engine-is-ios-pebble":252,"../internals/engine-is-node":254,"../internals/engine-is-webos-webkit":255,"../internals/function-bind-context":262,"../internals/global":274,"../internals/object-get-own-property-descriptor":309,"../internals/queue":328,"../internals/task":339}],303:[function(e,a,f){var c=e("../internals/a-callable"),s=TypeError,l=function(i){var n,o;this.promise=new i(function(h,u){if(n!==void 0||o!==void 0)throw new s("Bad Promise constructor");n=h,o=u}),this.resolve=c(n),this.reject=c(o)};a.exports.f=function(i){return new l(i)}},{"../internals/a-callable":222}],304:[function(e,a,f){var c=e("../internals/is-regexp"),s=TypeError;a.exports=function(l){if(c(l))throw new s("The method doesn't accept regular expressions");return l}},{"../internals/is-regexp":291}],305:[function(e,a,f){var c=e("../internals/descriptors"),s=e("../internals/function-uncurry-this"),l=e("../internals/function-call"),i=e("../internals/fails"),n=e("../internals/object-keys"),o=e("../internals/object-get-own-property-symbols"),h=e("../internals/object-property-is-enumerable"),u=e("../internals/to-object"),d=e("../internals/indexed-object"),m=Object.assign,b=Object.defineProperty,p=s([].concat);a.exports=!m||i(function(){if(c&&m({b:1},m(b({},"a",{enumerable:!0,get:function(){b(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var v={},g={},x=Symbol("assign detection");return v[x]=7,"abcdefghijklmnopqrst".split("").forEach(function(C){g[C]=C}),m({},v)[x]!==7||n(m({},g)).join("")!=="abcdefghijklmnopqrst"})?function(v,g){for(var x=u(v),C=arguments.length,T=1,R=o.f,B=h.f;C>T;)for(var I,F=d(arguments[T++]),L=R?p(n(F),R(F)):n(F),V=L.length,z=0;V>z;)I=L[z++],c&&!l(B,F,I)||(x[I]=F[I]);return x}:m},{"../internals/descriptors":247,"../internals/fails":260,"../internals/function-call":264,"../internals/function-uncurry-this":268,"../internals/indexed-object":280,"../internals/object-get-own-property-symbols":312,"../internals/object-keys":316,"../internals/object-property-is-enumerable":317,"../internals/to-object":344}],306:[function(e,a,f){var c,s=e("../internals/an-object"),l=e("../internals/object-define-properties"),i=e("../internals/enum-bug-keys"),n=e("../internals/hidden-keys"),o=e("../internals/html"),h=e("../internals/document-create-element"),u=e("../internals/shared-key"),d=u("IE_PROTO"),m=function(){},b=function(g){return"<script>"+g+"<\/script>"},p=function(g){g.write(b("")),g.close();var x=g.parentWindow.Object;return g=null,x},v=function(){try{c=new ActiveXObject("htmlfile")}catch{}var g,x;v=typeof document<"u"?document.domain&&c?p(c):((x=h("iframe")).style.display="none",o.appendChild(x),x.src="javascript:",(g=x.contentWindow.document).open(),g.write(b("document.F=Object")),g.close(),g.F):p(c);for(var C=i.length;C--;)delete v.prototype[i[C]];return v()};n[d]=!0,a.exports=Object.create||function(g,x){var C;return g!==null?(m.prototype=s(g),C=new m,m.prototype=null,C[d]=g):C=v(),x===void 0?C:l.f(C,x)}},{"../internals/an-object":227,"../internals/document-create-element":249,"../internals/enum-bug-keys":258,"../internals/hidden-keys":276,"../internals/html":278,"../internals/object-define-properties":307,"../internals/shared-key":332}],307:[function(e,a,f){var c=e("../internals/descriptors"),s=e("../internals/v8-prototype-define-bug"),l=e("../internals/object-define-property"),i=e("../internals/an-object"),n=e("../internals/to-indexed-object"),o=e("../internals/object-keys");f.f=c&&!s?Object.defineProperties:function(h,u){i(h);for(var d,m=n(u),b=o(u),p=b.length,v=0;p>v;)l.f(h,d=b[v++],m[d]);return h}},{"../internals/an-object":227,"../internals/descriptors":247,"../internals/object-define-property":308,"../internals/object-keys":316,"../internals/to-indexed-object":341,"../internals/v8-prototype-define-bug":352}],308:[function(e,a,f){var c=e("../internals/descriptors"),s=e("../internals/ie8-dom-define"),l=e("../internals/v8-prototype-define-bug"),i=e("../internals/an-object"),n=e("../internals/to-property-key"),o=TypeError,h=Object.defineProperty,u=Object.getOwnPropertyDescriptor;f.f=c?l?function(d,m,b){if(i(d),m=n(m),i(b),typeof d=="function"&&m==="prototype"&&"value"in b&&"writable"in b&&!b.writable){var p=u(d,m);p&&p.writable&&(d[m]=b.value,b={configurable:"configurable"in b?b.configurable:p.configurable,enumerable:"enumerable"in b?b.enumerable:p.enumerable,writable:!1})}return h(d,m,b)}:h:function(d,m,b){if(i(d),m=n(m),i(b),s)try{return h(d,m,b)}catch{}if("get"in b||"set"in b)throw new o("Accessors not supported");return"value"in b&&(d[m]=b.value),d}},{"../internals/an-object":227,"../internals/descriptors":247,"../internals/ie8-dom-define":279,"../internals/to-property-key":346,"../internals/v8-prototype-define-bug":352}],309:[function(e,a,f){var c=e("../internals/descriptors"),s=e("../internals/function-call"),l=e("../internals/object-property-is-enumerable"),i=e("../internals/create-property-descriptor"),n=e("../internals/to-indexed-object"),o=e("../internals/to-property-key"),h=e("../internals/has-own-property"),u=e("../internals/ie8-dom-define"),d=Object.getOwnPropertyDescriptor;f.f=c?d:function(m,b){if(m=n(m),b=o(b),u)try{return d(m,b)}catch{}if(h(m,b))return i(!s(l.f,m,b),m[b])}},{"../internals/create-property-descriptor":242,"../internals/descriptors":247,"../internals/function-call":264,"../internals/has-own-property":275,"../internals/ie8-dom-define":279,"../internals/object-property-is-enumerable":317,"../internals/to-indexed-object":341,"../internals/to-property-key":346}],310:[function(e,a,f){var c=e("../internals/classof-raw"),s=e("../internals/to-indexed-object"),l=e("../internals/object-get-own-property-names").f,i=e("../internals/array-slice-simple"),n=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];a.exports.f=function(o){return n&&c(o)==="Window"?function(h){try{return l(h)}catch{return i(n)}}(o):l(s(o))}},{"../internals/array-slice-simple":230,"../internals/classof-raw":235,"../internals/object-get-own-property-names":311,"../internals/to-indexed-object":341}],311:[function(e,a,f){var c=e("../internals/object-keys-internal"),s=e("../internals/enum-bug-keys").concat("length","prototype");f.f=Object.getOwnPropertyNames||function(l){return c(l,s)}},{"../internals/enum-bug-keys":258,"../internals/object-keys-internal":315}],312:[function(e,a,f){f.f=Object.getOwnPropertySymbols},{}],313:[function(e,a,f){var c=e("../internals/has-own-property"),s=e("../internals/is-callable"),l=e("../internals/to-object"),i=e("../internals/shared-key"),n=e("../internals/correct-prototype-getter"),o=i("IE_PROTO"),h=Object,u=h.prototype;a.exports=n?h.getPrototypeOf:function(d){var m=l(d);if(c(m,o))return m[o];var b=m.constructor;return s(b)&&m instanceof b?b.prototype:m instanceof h?u:null}},{"../internals/correct-prototype-getter":239,"../internals/has-own-property":275,"../internals/is-callable":285,"../internals/shared-key":332,"../internals/to-object":344}],314:[function(e,a,f){var c=e("../internals/function-uncurry-this");a.exports=c({}.isPrototypeOf)},{"../internals/function-uncurry-this":268}],315:[function(e,a,f){var c=e("../internals/function-uncurry-this"),s=e("../internals/has-own-property"),l=e("../internals/to-indexed-object"),i=e("../internals/array-includes").indexOf,n=e("../internals/hidden-keys"),o=c([].push);a.exports=function(h,u){var d,m=l(h),b=0,p=[];for(d in m)!s(n,d)&&s(m,d)&&o(p,d);for(;u.length>b;)s(m,d=u[b++])&&(~i(p,d)||o(p,d));return p}},{"../internals/array-includes":228,"../internals/function-uncurry-this":268,"../internals/has-own-property":275,"../internals/hidden-keys":276,"../internals/to-indexed-object":341}],316:[function(e,a,f){var c=e("../internals/object-keys-internal"),s=e("../internals/enum-bug-keys");a.exports=Object.keys||function(l){return c(l,s)}},{"../internals/enum-bug-keys":258,"../internals/object-keys-internal":315}],317:[function(e,a,f){var c={}.propertyIsEnumerable,s=Object.getOwnPropertyDescriptor,l=s&&!c.call({1:2},1);f.f=l?function(i){var n=s(this,i);return!!n&&n.enumerable}:c},{}],318:[function(e,a,f){var c=e("../internals/function-uncurry-this-accessor"),s=e("../internals/an-object"),l=e("../internals/a-possible-prototype");a.exports=Object.setPrototypeOf||("__proto__"in{}?function(){var i,n=!1,o={};try{(i=c(Object.prototype,"__proto__","set"))(o,[]),n=o instanceof Array}catch{}return function(h,u){return s(h),l(u),n?i(h,u):h.__proto__=u,h}}():void 0)},{"../internals/a-possible-prototype":224,"../internals/an-object":227,"../internals/function-uncurry-this-accessor":266}],319:[function(e,a,f){var c=e("../internals/descriptors"),s=e("../internals/fails"),l=e("../internals/function-uncurry-this"),i=e("../internals/object-get-prototype-of"),n=e("../internals/object-keys"),o=e("../internals/to-indexed-object"),h=l(e("../internals/object-property-is-enumerable").f),u=l([].push),d=c&&s(function(){var b=Object.create(null);return b[2]=2,!h(b,2)}),m=function(b){return function(p){for(var v,g=o(p),x=n(g),C=d&&i(g)===null,T=x.length,R=0,B=[];T>R;)v=x[R++],c&&!(C?v in g:h(g,v))||u(B,b?[v,g[v]]:g[v]);return B}};a.exports={entries:m(!0),values:m(!1)}},{"../internals/descriptors":247,"../internals/fails":260,"../internals/function-uncurry-this":268,"../internals/object-get-prototype-of":313,"../internals/object-keys":316,"../internals/object-property-is-enumerable":317,"../internals/to-indexed-object":341}],320:[function(e,a,f){var c=e("../internals/function-call"),s=e("../internals/is-callable"),l=e("../internals/is-object"),i=TypeError;a.exports=function(n,o){var h,u;if(o==="string"&&s(h=n.toString)&&!l(u=c(h,n))||s(h=n.valueOf)&&!l(u=c(h,n))||o!=="string"&&s(h=n.toString)&&!l(u=c(h,n)))return u;throw new i("Can't convert object to primitive value")}},{"../internals/function-call":264,"../internals/is-callable":285,"../internals/is-object":289}],321:[function(e,a,f){var c=e("../internals/get-built-in"),s=e("../internals/function-uncurry-this"),l=e("../internals/object-get-own-property-names"),i=e("../internals/object-get-own-property-symbols"),n=e("../internals/an-object"),o=s([].concat);a.exports=c("Reflect","ownKeys")||function(h){var u=l.f(n(h)),d=i.f;return d?o(u,d(h)):u}},{"../internals/an-object":227,"../internals/function-uncurry-this":268,"../internals/get-built-in":269,"../internals/object-get-own-property-names":311,"../internals/object-get-own-property-symbols":312}],322:[function(e,a,f){var c=e("../internals/global");a.exports=c},{"../internals/global":274}],323:[function(e,a,f){a.exports=function(c){try{return{error:!1,value:c()}}catch(s){return{error:!0,value:s}}}},{}],324:[function(e,a,f){var c=e("../internals/global"),s=e("../internals/promise-native-constructor"),l=e("../internals/is-callable"),i=e("../internals/is-forced"),n=e("../internals/inspect-source"),o=e("../internals/well-known-symbol"),h=e("../internals/engine-is-browser"),u=e("../internals/engine-is-deno"),d=e("../internals/is-pure"),m=e("../internals/engine-v8-version"),b=s&&s.prototype,p=o("species"),v=!1,g=l(c.PromiseRejectionEvent),x=i("Promise",function(){var C=n(s),T=C!==String(s);if(!T&&m===66||d&&(!b.catch||!b.finally))return!0;if(!m||m<51||!/native code/.test(C)){var R=new s(function(I){I(1)}),B=function(I){I(function(){},function(){})};if((R.constructor={})[p]=B,!(v=R.then(function(){})instanceof B))return!0}return!T&&(h||u)&&!g});a.exports={CONSTRUCTOR:x,REJECTION_EVENT:g,SUBCLASSING:v}},{"../internals/engine-is-browser":250,"../internals/engine-is-deno":251,"../internals/engine-v8-version":257,"../internals/global":274,"../internals/inspect-source":281,"../internals/is-callable":285,"../internals/is-forced":287,"../internals/is-pure":290,"../internals/promise-native-constructor":325,"../internals/well-known-symbol":357}],325:[function(e,a,f){var c=e("../internals/global");a.exports=c.Promise},{"../internals/global":274}],326:[function(e,a,f){var c=e("../internals/an-object"),s=e("../internals/is-object"),l=e("../internals/new-promise-capability");a.exports=function(i,n){if(c(i),s(n)&&n.constructor===i)return n;var o=l.f(i);return(0,o.resolve)(n),o.promise}},{"../internals/an-object":227,"../internals/is-object":289,"../internals/new-promise-capability":303}],327:[function(e,a,f){var c=e("../internals/promise-native-constructor"),s=e("../internals/check-correctness-of-iteration"),l=e("../internals/promise-constructor-detection").CONSTRUCTOR;a.exports=l||!s(function(i){c.all(i).then(void 0,function(){})})},{"../internals/check-correctness-of-iteration":234,"../internals/promise-constructor-detection":324,"../internals/promise-native-constructor":325}],328:[function(e,a,f){var c=function(){this.head=null,this.tail=null};c.prototype={add:function(s){var l={item:s,next:null},i=this.tail;i?i.next=l:this.head=l,this.tail=l},get:function(){var s=this.head;if(s)return(this.head=s.next)===null&&(this.tail=null),s.item}},a.exports=c},{}],329:[function(e,a,f){var c=e("../internals/is-null-or-undefined"),s=TypeError;a.exports=function(l){if(c(l))throw new s("Can't call method on "+l);return l}},{"../internals/is-null-or-undefined":288}],330:[function(e,a,f){var c=e("../internals/get-built-in"),s=e("../internals/define-built-in-accessor"),l=e("../internals/well-known-symbol"),i=e("../internals/descriptors"),n=l("species");a.exports=function(o){var h=c(o);i&&h&&!h[n]&&s(h,n,{configurable:!0,get:function(){return this}})}},{"../internals/define-built-in-accessor":244,"../internals/descriptors":247,"../internals/get-built-in":269,"../internals/well-known-symbol":357}],331:[function(e,a,f){var c=e("../internals/object-define-property").f,s=e("../internals/has-own-property"),l=e("../internals/well-known-symbol")("toStringTag");a.exports=function(i,n,o){i&&!o&&(i=i.prototype),i&&!s(i,l)&&c(i,l,{configurable:!0,value:n})}},{"../internals/has-own-property":275,"../internals/object-define-property":308,"../internals/well-known-symbol":357}],332:[function(e,a,f){var c=e("../internals/shared"),s=e("../internals/uid"),l=c("keys");a.exports=function(i){return l[i]||(l[i]=s(i))}},{"../internals/shared":334,"../internals/uid":350}],333:[function(e,a,f){var c=e("../internals/global"),s=e("../internals/define-global-property"),l=c["__core-js_shared__"]||s("__core-js_shared__",{});a.exports=l},{"../internals/define-global-property":246,"../internals/global":274}],334:[function(e,a,f){var c=e("../internals/is-pure"),s=e("../internals/shared-store");(a.exports=function(l,i){return s[l]||(s[l]=i!==void 0?i:{})})("versions",[]).push({version:"3.33.0",mode:c?"pure":"global",copyright:"© 2014-2023 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.33.0/LICENSE",source:"https://github.com/zloirock/core-js"})},{"../internals/is-pure":290,"../internals/shared-store":333}],335:[function(e,a,f){var c=e("../internals/an-object"),s=e("../internals/a-constructor"),l=e("../internals/is-null-or-undefined"),i=e("../internals/well-known-symbol")("species");a.exports=function(n,o){var h,u=c(n).constructor;return u===void 0||l(h=c(u)[i])?o:s(h)}},{"../internals/a-constructor":223,"../internals/an-object":227,"../internals/is-null-or-undefined":288,"../internals/well-known-symbol":357}],336:[function(e,a,f){var c=e("../internals/engine-v8-version"),s=e("../internals/fails"),l=e("../internals/global").String;a.exports=!!Object.getOwnPropertySymbols&&!s(function(){var i=Symbol("symbol detection");return!l(i)||!(Object(i)instanceof Symbol)||!Symbol.sham&&c&&c<41})},{"../internals/engine-v8-version":257,"../internals/fails":260,"../internals/global":274}],337:[function(e,a,f){var c=e("../internals/function-call"),s=e("../internals/get-built-in"),l=e("../internals/well-known-symbol"),i=e("../internals/define-built-in");a.exports=function(){var n=s("Symbol"),o=n&&n.prototype,h=o&&o.valueOf,u=l("toPrimitive");o&&!o[u]&&i(o,u,function(d){return c(h,this)},{arity:1})}},{"../internals/define-built-in":245,"../internals/function-call":264,"../internals/get-built-in":269,"../internals/well-known-symbol":357}],338:[function(e,a,f){var c=e("../internals/symbol-constructor-detection");a.exports=c&&!!Symbol.for&&!!Symbol.keyFor},{"../internals/symbol-constructor-detection":336}],339:[function(e,a,f){var c,s,l,i,n=e("../internals/global"),o=e("../internals/function-apply"),h=e("../internals/function-bind-context"),u=e("../internals/is-callable"),d=e("../internals/has-own-property"),m=e("../internals/fails"),b=e("../internals/html"),p=e("../internals/array-slice"),v=e("../internals/document-create-element"),g=e("../internals/validate-arguments-length"),x=e("../internals/engine-is-ios"),C=e("../internals/engine-is-node"),T=n.setImmediate,R=n.clearImmediate,B=n.process,I=n.Dispatch,F=n.Function,L=n.MessageChannel,V=n.String,z=0,E={};m(function(){c=n.location});var P=function(_){if(d(E,_)){var S=E[_];delete E[_],S()}},k=function(_){return function(){P(_)}},y=function(_){P(_.data)},w=function(_){n.postMessage(V(_),c.protocol+"//"+c.host)};T&&R||(T=function(_){g(arguments.length,1);var S=u(_)?_:F(_),A=p(arguments,1);return E[++z]=function(){o(S,void 0,A)},s(z),z},R=function(_){delete E[_]},C?s=function(_){B.nextTick(k(_))}:I&&I.now?s=function(_){I.now(k(_))}:L&&!x?(i=(l=new L).port2,l.port1.onmessage=y,s=h(i.postMessage,i)):n.addEventListener&&u(n.postMessage)&&!n.importScripts&&c&&c.protocol!=="file:"&&!m(w)?(s=w,n.addEventListener("message",y,!1)):s="onreadystatechange"in v("script")?function(_){b.appendChild(v("script")).onreadystatechange=function(){b.removeChild(this),P(_)}}:function(_){setTimeout(k(_),0)}),a.exports={set:T,clear:R}},{"../internals/array-slice":231,"../internals/document-create-element":249,"../internals/engine-is-ios":253,"../internals/engine-is-node":254,"../internals/fails":260,"../internals/function-apply":261,"../internals/function-bind-context":262,"../internals/global":274,"../internals/has-own-property":275,"../internals/html":278,"../internals/is-callable":285,"../internals/validate-arguments-length":353}],340:[function(e,a,f){var c=e("../internals/to-integer-or-infinity"),s=Math.max,l=Math.min;a.exports=function(i,n){var o=c(i);return o<0?s(o+n,0):l(o,n)}},{"../internals/to-integer-or-infinity":342}],341:[function(e,a,f){var c=e("../internals/indexed-object"),s=e("../internals/require-object-coercible");a.exports=function(l){return c(s(l))}},{"../internals/indexed-object":280,"../internals/require-object-coercible":329}],342:[function(e,a,f){var c=e("../internals/math-trunc");a.exports=function(s){var l=+s;return l!=l||l===0?0:c(l)}},{"../internals/math-trunc":301}],343:[function(e,a,f){var c=e("../internals/to-integer-or-infinity"),s=Math.min;a.exports=function(l){return l>0?s(c(l),9007199254740991):0}},{"../internals/to-integer-or-infinity":342}],344:[function(e,a,f){var c=e("../internals/require-object-coercible"),s=Object;a.exports=function(l){return s(c(l))}},{"../internals/require-object-coercible":329}],345:[function(e,a,f){var c=e("../internals/function-call"),s=e("../internals/is-object"),l=e("../internals/is-symbol"),i=e("../internals/get-method"),n=e("../internals/ordinary-to-primitive"),o=e("../internals/well-known-symbol"),h=TypeError,u=o("toPrimitive");a.exports=function(d,m){if(!s(d)||l(d))return d;var b,p=i(d,u);if(p){if(m===void 0&&(m="default"),b=c(p,d,m),!s(b)||l(b))return b;throw new h("Can't convert object to primitive value")}return m===void 0&&(m="number"),n(d,m)}},{"../internals/function-call":264,"../internals/get-method":273,"../internals/is-object":289,"../internals/is-symbol":292,"../internals/ordinary-to-primitive":320,"../internals/well-known-symbol":357}],346:[function(e,a,f){var c=e("../internals/to-primitive"),s=e("../internals/is-symbol");a.exports=function(l){var i=c(l,"string");return s(i)?i:i+""}},{"../internals/is-symbol":292,"../internals/to-primitive":345}],347:[function(e,a,f){var c={};c[e("../internals/well-known-symbol")("toStringTag")]="z",a.exports=String(c)==="[object z]"},{"../internals/well-known-symbol":357}],348:[function(e,a,f){var c=e("../internals/classof"),s=String;a.exports=function(l){if(c(l)==="Symbol")throw new TypeError("Cannot convert a Symbol value to a string");return s(l)}},{"../internals/classof":236}],349:[function(e,a,f){var c=String;a.exports=function(s){try{return c(s)}catch{return"Object"}}},{}],350:[function(e,a,f){var c=e("../internals/function-uncurry-this"),s=0,l=Math.random(),i=c(1 .toString);a.exports=function(n){return"Symbol("+(n===void 0?"":n)+")_"+i(++s+l,36)}},{"../internals/function-uncurry-this":268}],351:[function(e,a,f){var c=e("../internals/symbol-constructor-detection");a.exports=c&&!Symbol.sham&&typeof Symbol.iterator=="symbol"},{"../internals/symbol-constructor-detection":336}],352:[function(e,a,f){var c=e("../internals/descriptors"),s=e("../internals/fails");a.exports=c&&s(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})},{"../internals/descriptors":247,"../internals/fails":260}],353:[function(e,a,f){var c=TypeError;a.exports=function(s,l){if(s<l)throw new c("Not enough arguments");return s}},{}],354:[function(e,a,f){var c=e("../internals/global"),s=e("../internals/is-callable"),l=c.WeakMap;a.exports=s(l)&&/native code/.test(String(l))},{"../internals/global":274,"../internals/is-callable":285}],355:[function(e,a,f){var c=e("../internals/path"),s=e("../internals/has-own-property"),l=e("../internals/well-known-symbol-wrapped"),i=e("../internals/object-define-property").f;a.exports=function(n){var o=c.Symbol||(c.Symbol={});s(o,n)||i(o,n,{value:l.f(n)})}},{"../internals/has-own-property":275,"../internals/object-define-property":308,"../internals/path":322,"../internals/well-known-symbol-wrapped":356}],356:[function(e,a,f){var c=e("../internals/well-known-symbol");f.f=c},{"../internals/well-known-symbol":357}],357:[function(e,a,f){var c=e("../internals/global"),s=e("../internals/shared"),l=e("../internals/has-own-property"),i=e("../internals/uid"),n=e("../internals/symbol-constructor-detection"),o=e("../internals/use-symbol-as-uid"),h=c.Symbol,u=s("wks"),d=o?h.for||h:h&&h.withoutSetter||i;a.exports=function(m){return l(u,m)||(u[m]=n&&l(h,m)?h[m]:d("Symbol."+m)),u[m]}},{"../internals/global":274,"../internals/has-own-property":275,"../internals/shared":334,"../internals/symbol-constructor-detection":336,"../internals/uid":350,"../internals/use-symbol-as-uid":351}],358:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/array-iteration").findIndex,l=e("../internals/add-to-unscopables"),i=!0;"findIndex"in[]&&Array(1).findIndex(function(){i=!1}),c({target:"Array",proto:!0,forced:i},{findIndex:function(n){return s(this,n,arguments.length>1?arguments[1]:void 0)}}),l("findIndex")},{"../internals/add-to-unscopables":225,"../internals/array-iteration":229,"../internals/export":259}],359:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/array-iteration").find,l=e("../internals/add-to-unscopables"),i=!0;"find"in[]&&Array(1).find(function(){i=!1}),c({target:"Array",proto:!0,forced:i},{find:function(n){return s(this,n,arguments.length>1?arguments[1]:void 0)}}),l("find")},{"../internals/add-to-unscopables":225,"../internals/array-iteration":229,"../internals/export":259}],360:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/array-includes").includes,l=e("../internals/fails"),i=e("../internals/add-to-unscopables");c({target:"Array",proto:!0,forced:l(function(){return!Array(1).includes()})},{includes:function(n){return s(this,n,arguments.length>1?arguments[1]:void 0)}}),i("includes")},{"../internals/add-to-unscopables":225,"../internals/array-includes":228,"../internals/export":259,"../internals/fails":260}],361:[function(e,a,f){var c=e("../internals/to-indexed-object"),s=e("../internals/add-to-unscopables"),l=e("../internals/iterators"),i=e("../internals/internal-state"),n=e("../internals/object-define-property").f,o=e("../internals/iterator-define"),h=e("../internals/create-iter-result-object"),u=e("../internals/is-pure"),d=e("../internals/descriptors"),m=i.set,b=i.getterFor("Array Iterator");a.exports=o(Array,"Array",function(v,g){m(this,{type:"Array Iterator",target:c(v),index:0,kind:g})},function(){var v=b(this),g=v.target,x=v.kind,C=v.index++;if(!g||C>=g.length)return v.target=void 0,h(void 0,!0);switch(x){case"keys":return h(C,!1);case"values":return h(g[C],!1)}return h([C,g[C]],!1)},"values");var p=l.Arguments=l.Array;if(s("keys"),s("values"),s("entries"),!u&&d&&p.name!=="values")try{n(p,"name",{value:"values"})}catch{}},{"../internals/add-to-unscopables":225,"../internals/create-iter-result-object":240,"../internals/descriptors":247,"../internals/internal-state":282,"../internals/is-pure":290,"../internals/iterator-define":296,"../internals/iterators":298,"../internals/object-define-property":308,"../internals/to-indexed-object":341}],362:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/get-built-in"),l=e("../internals/function-apply"),i=e("../internals/function-call"),n=e("../internals/function-uncurry-this"),o=e("../internals/fails"),h=e("../internals/is-callable"),u=e("../internals/is-symbol"),d=e("../internals/array-slice"),m=e("../internals/get-json-replacer-function"),b=e("../internals/symbol-constructor-detection"),p=String,v=s("JSON","stringify"),g=n(/./.exec),x=n("".charAt),C=n("".charCodeAt),T=n("".replace),R=n(1 .toString),B=/[\uD800-\uDFFF]/g,I=/^[\uD800-\uDBFF]$/,F=/^[\uDC00-\uDFFF]$/,L=!b||o(function(){var P=s("Symbol")("stringify detection");return v([P])!=="[null]"||v({a:P})!=="{}"||v(Object(P))!=="{}"}),V=o(function(){return v("\uDF06\uD834")!=='"\\udf06\\ud834"'||v("\uDEAD")!=='"\\udead"'}),z=function(P,k){var y=d(arguments),w=m(k);if(h(w)||P!==void 0&&!u(P))return y[1]=function(_,S){if(h(w)&&(S=i(w,this,p(_),S)),!u(S))return S},l(v,null,y)},E=function(P,k,y){var w=x(y,k-1),_=x(y,k+1);return g(I,P)&&!g(F,_)||g(F,P)&&!g(I,w)?"\\u"+R(C(P,0),16):P};v&&c({target:"JSON",stat:!0,arity:3,forced:L||V},{stringify:function(P,k,y){var w=d(arguments),_=l(L?z:v,null,w);return V&&typeof _=="string"?T(_,B,E):_}})},{"../internals/array-slice":231,"../internals/export":259,"../internals/fails":260,"../internals/function-apply":261,"../internals/function-call":264,"../internals/function-uncurry-this":268,"../internals/get-built-in":269,"../internals/get-json-replacer-function":272,"../internals/is-callable":285,"../internals/is-symbol":292,"../internals/symbol-constructor-detection":336}],363:[function(e,a,f){e("../internals/export")({target:"Number",stat:!0},{isNaN:function(c){return c!=c}})},{"../internals/export":259}],364:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/object-assign");c({target:"Object",stat:!0,arity:2,forced:Object.assign!==s},{assign:s})},{"../internals/export":259,"../internals/object-assign":305}],365:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/symbol-constructor-detection"),l=e("../internals/fails"),i=e("../internals/object-get-own-property-symbols"),n=e("../internals/to-object");c({target:"Object",stat:!0,forced:!s||l(function(){i.f(1)})},{getOwnPropertySymbols:function(o){var h=i.f;return h?h(n(o)):[]}})},{"../internals/export":259,"../internals/fails":260,"../internals/object-get-own-property-symbols":312,"../internals/symbol-constructor-detection":336,"../internals/to-object":344}],366:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/to-object"),l=e("../internals/object-keys");c({target:"Object",stat:!0,forced:e("../internals/fails")(function(){l(1)})},{keys:function(i){return l(s(i))}})},{"../internals/export":259,"../internals/fails":260,"../internals/object-keys":316,"../internals/to-object":344}],367:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/object-to-array").values;c({target:"Object",stat:!0},{values:function(l){return s(l)}})},{"../internals/export":259,"../internals/object-to-array":319}],368:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/function-call"),l=e("../internals/a-callable"),i=e("../internals/new-promise-capability"),n=e("../internals/perform"),o=e("../internals/iterate");c({target:"Promise",stat:!0,forced:e("../internals/promise-statics-incorrect-iteration")},{all:function(h){var u=this,d=i.f(u),m=d.resolve,b=d.reject,p=n(function(){var v=l(u.resolve),g=[],x=0,C=1;o(h,function(T){var R=x++,B=!1;C++,s(v,u,T).then(function(I){B||(B=!0,g[R]=I,--C||m(g))},b)}),--C||m(g)});return p.error&&b(p.value),d.promise}})},{"../internals/a-callable":222,"../internals/export":259,"../internals/function-call":264,"../internals/iterate":293,"../internals/new-promise-capability":303,"../internals/perform":323,"../internals/promise-statics-incorrect-iteration":327}],369:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/is-pure"),l=e("../internals/promise-constructor-detection").CONSTRUCTOR,i=e("../internals/promise-native-constructor"),n=e("../internals/get-built-in"),o=e("../internals/is-callable"),h=e("../internals/define-built-in"),u=i&&i.prototype;if(c({target:"Promise",proto:!0,forced:l,real:!0},{catch:function(m){return this.then(void 0,m)}}),!s&&o(i)){var d=n("Promise").prototype.catch;u.catch!==d&&h(u,"catch",d,{unsafe:!0})}},{"../internals/define-built-in":245,"../internals/export":259,"../internals/get-built-in":269,"../internals/is-callable":285,"../internals/is-pure":290,"../internals/promise-constructor-detection":324,"../internals/promise-native-constructor":325}],370:[function(e,a,f){var c,s,l,i=e("../internals/export"),n=e("../internals/is-pure"),o=e("../internals/engine-is-node"),h=e("../internals/global"),u=e("../internals/function-call"),d=e("../internals/define-built-in"),m=e("../internals/object-set-prototype-of"),b=e("../internals/set-to-string-tag"),p=e("../internals/set-species"),v=e("../internals/a-callable"),g=e("../internals/is-callable"),x=e("../internals/is-object"),C=e("../internals/an-instance"),T=e("../internals/species-constructor"),R=e("../internals/task").set,B=e("../internals/microtask"),I=e("../internals/host-report-errors"),F=e("../internals/perform"),L=e("../internals/queue"),V=e("../internals/internal-state"),z=e("../internals/promise-native-constructor"),E=e("../internals/promise-constructor-detection"),P=e("../internals/new-promise-capability"),k=E.CONSTRUCTOR,y=E.REJECTION_EVENT,w=E.SUBCLASSING,_=V.getterFor("Promise"),S=V.set,A=z&&z.prototype,O=z,N=A,U=h.TypeError,H=h.document,Z=h.process,D=P.f,q=D,M=!!(H&&H.createEvent&&h.dispatchEvent),j=function(ne){var oe;return!(!x(ne)||!g(oe=ne.then))&&oe},$=function(ne,oe){var ae,ce,me,be=oe.value,ye=oe.state===1,Me=ye?ne.ok:ne.fail,Te=ne.resolve,fe=ne.reject,ke=ne.domain;try{Me?(ye||(oe.rejection===2&&ee(oe),oe.rejection=1),Me===!0?ae=be:(ke&&ke.enter(),ae=Me(be),ke&&(ke.exit(),me=!0)),ae===ne.promise?fe(new U("Promise-chain cycle")):(ce=j(ae))?u(ce,ae,Te,fe):Te(ae)):fe(be)}catch(Ee){ke&&!me&&ke.exit(),fe(Ee)}},K=function(ne,oe){ne.notified||(ne.notified=!0,B(function(){for(var ae,ce=ne.reactions;ae=ce.get();)$(ae,ne);ne.notified=!1,oe&&!ne.rejection&&X(ne)}))},J=function(ne,oe,ae){var ce,me;M?((ce=H.createEvent("Event")).promise=oe,ce.reason=ae,ce.initEvent(ne,!1,!0),h.dispatchEvent(ce)):ce={promise:oe,reason:ae},!y&&(me=h["on"+ne])?me(ce):ne==="unhandledrejection"&&I("Unhandled promise rejection",ae)},X=function(ne){u(R,h,function(){var oe,ae=ne.facade,ce=ne.value;if(Q(ne)&&(oe=F(function(){o?Z.emit("unhandledRejection",ce,ae):J("unhandledrejection",ae,ce)}),ne.rejection=o||Q(ne)?2:1,oe.error))throw oe.value})},Q=function(ne){return ne.rejection!==1&&!ne.parent},ee=function(ne){u(R,h,function(){var oe=ne.facade;o?Z.emit("rejectionHandled",oe):J("rejectionhandled",oe,ne.value)})},se=function(ne,oe,ae){return function(ce){ne(oe,ce,ae)}},Y=function(ne,oe,ae){ne.done||(ne.done=!0,ae&&(ne=ae),ne.value=oe,ne.state=2,K(ne,!0))},te=function(ne,oe,ae){if(!ne.done){ne.done=!0,ae&&(ne=ae);try{if(ne.facade===oe)throw new U("Promise can't be resolved itself");var ce=j(oe);ce?B(function(){var me={done:!1};try{u(ce,oe,se(te,me,ne),se(Y,me,ne))}catch(be){Y(me,be,ne)}}):(ne.value=oe,ne.state=1,K(ne,!1))}catch(me){Y({done:!1},me,ne)}}};if(k&&(N=(O=function(ne){C(this,N),v(ne),u(c,this);var oe=_(this);try{ne(se(te,oe),se(Y,oe))}catch(ae){Y(oe,ae)}}).prototype,(c=function(ne){S(this,{type:"Promise",done:!1,notified:!1,parent:!1,reactions:new L,rejection:!1,state:0,value:void 0})}).prototype=d(N,"then",function(ne,oe){var ae=_(this),ce=D(T(this,O));return ae.parent=!0,ce.ok=!g(ne)||ne,ce.fail=g(oe)&&oe,ce.domain=o?Z.domain:void 0,ae.state===0?ae.reactions.add(ce):B(function(){$(ce,ae)}),ce.promise}),s=function(){var ne=new c,oe=_(ne);this.promise=ne,this.resolve=se(te,oe),this.reject=se(Y,oe)},P.f=D=function(ne){return ne===O||ne===void 0?new s(ne):q(ne)},!n&&g(z)&&A!==Object.prototype)){l=A.then,w||d(A,"then",function(ne,oe){var ae=this;return new O(function(ce,me){u(l,ae,ce,me)}).then(ne,oe)},{unsafe:!0});try{delete A.constructor}catch{}m&&m(A,N)}i({global:!0,constructor:!0,wrap:!0,forced:k},{Promise:O}),b(O,"Promise",!1,!0),p("Promise")},{"../internals/a-callable":222,"../internals/an-instance":226,"../internals/define-built-in":245,"../internals/engine-is-node":254,"../internals/export":259,"../internals/function-call":264,"../internals/global":274,"../internals/host-report-errors":277,"../internals/internal-state":282,"../internals/is-callable":285,"../internals/is-object":289,"../internals/is-pure":290,"../internals/microtask":302,"../internals/new-promise-capability":303,"../internals/object-set-prototype-of":318,"../internals/perform":323,"../internals/promise-constructor-detection":324,"../internals/promise-native-constructor":325,"../internals/queue":328,"../internals/set-species":330,"../internals/set-to-string-tag":331,"../internals/species-constructor":335,"../internals/task":339}],371:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/is-pure"),l=e("../internals/promise-native-constructor"),i=e("../internals/fails"),n=e("../internals/get-built-in"),o=e("../internals/is-callable"),h=e("../internals/species-constructor"),u=e("../internals/promise-resolve"),d=e("../internals/define-built-in"),m=l&&l.prototype;if(c({target:"Promise",proto:!0,real:!0,forced:!!l&&i(function(){m.finally.call({then:function(){}},function(){})})},{finally:function(p){var v=h(this,n("Promise")),g=o(p);return this.then(g?function(x){return u(v,p()).then(function(){return x})}:p,g?function(x){return u(v,p()).then(function(){throw x})}:p)}}),!s&&o(l)){var b=n("Promise").prototype.finally;m.finally!==b&&d(m,"finally",b,{unsafe:!0})}},{"../internals/define-built-in":245,"../internals/export":259,"../internals/fails":260,"../internals/get-built-in":269,"../internals/is-callable":285,"../internals/is-pure":290,"../internals/promise-native-constructor":325,"../internals/promise-resolve":326,"../internals/species-constructor":335}],372:[function(e,a,f){e("../modules/es.promise.constructor"),e("../modules/es.promise.all"),e("../modules/es.promise.catch"),e("../modules/es.promise.race"),e("../modules/es.promise.reject"),e("../modules/es.promise.resolve")},{"../modules/es.promise.all":368,"../modules/es.promise.catch":369,"../modules/es.promise.constructor":370,"../modules/es.promise.race":373,"../modules/es.promise.reject":374,"../modules/es.promise.resolve":375}],373:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/function-call"),l=e("../internals/a-callable"),i=e("../internals/new-promise-capability"),n=e("../internals/perform"),o=e("../internals/iterate");c({target:"Promise",stat:!0,forced:e("../internals/promise-statics-incorrect-iteration")},{race:function(h){var u=this,d=i.f(u),m=d.reject,b=n(function(){var p=l(u.resolve);o(h,function(v){s(p,u,v).then(d.resolve,m)})});return b.error&&m(b.value),d.promise}})},{"../internals/a-callable":222,"../internals/export":259,"../internals/function-call":264,"../internals/iterate":293,"../internals/new-promise-capability":303,"../internals/perform":323,"../internals/promise-statics-incorrect-iteration":327}],374:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/function-call"),l=e("../internals/new-promise-capability");c({target:"Promise",stat:!0,forced:e("../internals/promise-constructor-detection").CONSTRUCTOR},{reject:function(i){var n=l.f(this);return s(n.reject,void 0,i),n.promise}})},{"../internals/export":259,"../internals/function-call":264,"../internals/new-promise-capability":303,"../internals/promise-constructor-detection":324}],375:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/get-built-in"),l=e("../internals/is-pure"),i=e("../internals/promise-native-constructor"),n=e("../internals/promise-constructor-detection").CONSTRUCTOR,o=e("../internals/promise-resolve"),h=s("Promise"),u=l&&!n;c({target:"Promise",stat:!0,forced:l||n},{resolve:function(d){return o(u&&this===h?i:this,d)}})},{"../internals/export":259,"../internals/get-built-in":269,"../internals/is-pure":290,"../internals/promise-constructor-detection":324,"../internals/promise-native-constructor":325,"../internals/promise-resolve":326}],376:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/function-uncurry-this"),l=e("../internals/to-absolute-index"),i=RangeError,n=String.fromCharCode,o=String.fromCodePoint,h=s([].join);c({target:"String",stat:!0,arity:1,forced:!!o&&o.length!==1},{fromCodePoint:function(u){for(var d,m=[],b=arguments.length,p=0;b>p;){if(d=+arguments[p++],l(d,1114111)!==d)throw new i(d+" is not a valid code point");m[p]=d<65536?n(d):n(55296+((d-=65536)>>10),d%1024+56320)}return h(m,"")}})},{"../internals/export":259,"../internals/function-uncurry-this":268,"../internals/to-absolute-index":340}],377:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/function-uncurry-this"),l=e("../internals/not-a-regexp"),i=e("../internals/require-object-coercible"),n=e("../internals/to-string"),o=e("../internals/correct-is-regexp-logic"),h=s("".indexOf);c({target:"String",proto:!0,forced:!o("includes")},{includes:function(u){return!!~h(n(i(this)),n(l(u)),arguments.length>1?arguments[1]:void 0)}})},{"../internals/correct-is-regexp-logic":238,"../internals/export":259,"../internals/function-uncurry-this":268,"../internals/not-a-regexp":304,"../internals/require-object-coercible":329,"../internals/to-string":348}],378:[function(e,a,f){e("../internals/well-known-symbol-define")("asyncIterator")},{"../internals/well-known-symbol-define":355}],379:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/global"),l=e("../internals/function-call"),i=e("../internals/function-uncurry-this"),n=e("../internals/is-pure"),o=e("../internals/descriptors"),h=e("../internals/symbol-constructor-detection"),u=e("../internals/fails"),d=e("../internals/has-own-property"),m=e("../internals/object-is-prototype-of"),b=e("../internals/an-object"),p=e("../internals/to-indexed-object"),v=e("../internals/to-property-key"),g=e("../internals/to-string"),x=e("../internals/create-property-descriptor"),C=e("../internals/object-create"),T=e("../internals/object-keys"),R=e("../internals/object-get-own-property-names"),B=e("../internals/object-get-own-property-names-external"),I=e("../internals/object-get-own-property-symbols"),F=e("../internals/object-get-own-property-descriptor"),L=e("../internals/object-define-property"),V=e("../internals/object-define-properties"),z=e("../internals/object-property-is-enumerable"),E=e("../internals/define-built-in"),P=e("../internals/define-built-in-accessor"),k=e("../internals/shared"),y=e("../internals/shared-key"),w=e("../internals/hidden-keys"),_=e("../internals/uid"),S=e("../internals/well-known-symbol"),A=e("../internals/well-known-symbol-wrapped"),O=e("../internals/well-known-symbol-define"),N=e("../internals/symbol-define-to-primitive"),U=e("../internals/set-to-string-tag"),H=e("../internals/internal-state"),Z=e("../internals/array-iteration").forEach,D=y("hidden"),q=H.set,M=H.getterFor("Symbol"),j=Object.prototype,$=s.Symbol,K=$&&$.prototype,J=s.RangeError,X=s.TypeError,Q=s.QObject,ee=F.f,se=L.f,Y=B.f,te=z.f,ne=i([].push),oe=k("symbols"),ae=k("op-symbols"),ce=k("wks"),me=!Q||!Q.prototype||!Q.prototype.findChild,be=function(je,Ce,Oe){var Le=ee(j,Ce);Le&&delete j[Ce],se(je,Ce,Oe),Le&&je!==j&&se(j,Ce,Le)},ye=o&&u(function(){return C(se({},"a",{get:function(){return se(this,"a",{value:7}).a}})).a!==7})?be:se,Me=function(je,Ce){var Oe=oe[je]=C(K);return q(Oe,{type:"Symbol",tag:je,description:Ce}),o||(Oe.description=Ce),Oe},Te=function(je,Ce,Oe){je===j&&Te(ae,Ce,Oe),b(je);var Le=v(Ce);return b(Oe),d(oe,Le)?(Oe.enumerable?(d(je,D)&&je[D][Le]&&(je[D][Le]=!1),Oe=C(Oe,{enumerable:x(0,!1)})):(d(je,D)||se(je,D,x(1,{})),je[D][Le]=!0),ye(je,Le,Oe)):se(je,Le,Oe)},fe=function(je,Ce){b(je);var Oe=p(Ce),Le=T(Oe).concat(De(Oe));return Z(Le,function(Be){o&&!l(ke,Oe,Be)||Te(je,Be,Oe[Be])}),je},ke=function(je){var Ce=v(je),Oe=l(te,this,Ce);return!(this===j&&d(oe,Ce)&&!d(ae,Ce))&&(!(Oe||!d(this,Ce)||!d(oe,Ce)||d(this,D)&&this[D][Ce])||Oe)},Ee=function(je,Ce){var Oe=p(je),Le=v(Ce);if(Oe!==j||!d(oe,Le)||d(ae,Le)){var Be=ee(Oe,Le);return!Be||!d(oe,Le)||d(Oe,D)&&Oe[D][Le]||(Be.enumerable=!0),Be}},Ne=function(je){var Ce=Y(p(je)),Oe=[];return Z(Ce,function(Le){d(oe,Le)||d(w,Le)||ne(Oe,Le)}),Oe},De=function(je){var Ce=je===j,Oe=Y(Ce?ae:p(je)),Le=[];return Z(Oe,function(Be){!d(oe,Be)||Ce&&!d(j,Be)||ne(Le,oe[Be])}),Le};h||(E(K=($=function(){if(m(K,this))throw new X("Symbol is not a constructor");var je=arguments.length&&arguments[0]!==void 0?g(arguments[0]):void 0,Ce=_(je),Oe=function(Le){this===j&&l(Oe,ae,Le),d(this,D)&&d(this[D],Ce)&&(this[D][Ce]=!1);var Be=x(1,Le);try{ye(this,Ce,Be)}catch(ct){if(!(ct instanceof J))throw ct;be(this,Ce,Be)}};return o&&me&&ye(j,Ce,{configurable:!0,set:Oe}),Me(Ce,je)}).prototype,"toString",function(){return M(this).tag}),E($,"withoutSetter",function(je){return Me(_(je),je)}),z.f=ke,L.f=Te,V.f=fe,F.f=Ee,R.f=B.f=Ne,I.f=De,A.f=function(je){return Me(S(je),je)},o&&(P(K,"description",{configurable:!0,get:function(){return M(this).description}}),n||E(j,"propertyIsEnumerable",ke,{unsafe:!0}))),c({global:!0,constructor:!0,wrap:!0,forced:!h,sham:!h},{Symbol:$}),Z(T(ce),function(je){O(je)}),c({target:"Symbol",stat:!0,forced:!h},{useSetter:function(){me=!0},useSimple:function(){me=!1}}),c({target:"Object",stat:!0,forced:!h,sham:!o},{create:function(je,Ce){return Ce===void 0?C(je):fe(C(je),Ce)},defineProperty:Te,defineProperties:fe,getOwnPropertyDescriptor:Ee}),c({target:"Object",stat:!0,forced:!h},{getOwnPropertyNames:Ne}),N(),U($,"Symbol"),w[D]=!0},{"../internals/an-object":227,"../internals/array-iteration":229,"../internals/create-property-descriptor":242,"../internals/define-built-in":245,"../internals/define-built-in-accessor":244,"../internals/descriptors":247,"../internals/export":259,"../internals/fails":260,"../internals/function-call":264,"../internals/function-uncurry-this":268,"../internals/global":274,"../internals/has-own-property":275,"../internals/hidden-keys":276,"../internals/internal-state":282,"../internals/is-pure":290,"../internals/object-create":306,"../internals/object-define-properties":307,"../internals/object-define-property":308,"../internals/object-get-own-property-descriptor":309,"../internals/object-get-own-property-names":311,"../internals/object-get-own-property-names-external":310,"../internals/object-get-own-property-symbols":312,"../internals/object-is-prototype-of":314,"../internals/object-keys":316,"../internals/object-property-is-enumerable":317,"../internals/set-to-string-tag":331,"../internals/shared":334,"../internals/shared-key":332,"../internals/symbol-constructor-detection":336,"../internals/symbol-define-to-primitive":337,"../internals/to-indexed-object":341,"../internals/to-property-key":346,"../internals/to-string":348,"../internals/uid":350,"../internals/well-known-symbol":357,"../internals/well-known-symbol-define":355,"../internals/well-known-symbol-wrapped":356}],380:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/get-built-in"),l=e("../internals/has-own-property"),i=e("../internals/to-string"),n=e("../internals/shared"),o=e("../internals/symbol-registry-detection"),h=n("string-to-symbol-registry"),u=n("symbol-to-string-registry");c({target:"Symbol",stat:!0,forced:!o},{for:function(d){var m=i(d);if(l(h,m))return h[m];var b=s("Symbol")(m);return h[m]=b,u[b]=m,b}})},{"../internals/export":259,"../internals/get-built-in":269,"../internals/has-own-property":275,"../internals/shared":334,"../internals/symbol-registry-detection":338,"../internals/to-string":348}],381:[function(e,a,f){e("../modules/es.symbol.constructor"),e("../modules/es.symbol.for"),e("../modules/es.symbol.key-for"),e("../modules/es.json.stringify"),e("../modules/es.object.get-own-property-symbols")},{"../modules/es.json.stringify":362,"../modules/es.object.get-own-property-symbols":365,"../modules/es.symbol.constructor":379,"../modules/es.symbol.for":380,"../modules/es.symbol.key-for":382}],382:[function(e,a,f){var c=e("../internals/export"),s=e("../internals/has-own-property"),l=e("../internals/is-symbol"),i=e("../internals/try-to-string"),n=e("../internals/shared"),o=e("../internals/symbol-registry-detection"),h=n("symbol-to-string-registry");c({target:"Symbol",stat:!0,forced:!o},{keyFor:function(u){if(!l(u))throw new TypeError(i(u)+" is not a symbol");if(s(h,u))return h[u]}})},{"../internals/export":259,"../internals/has-own-property":275,"../internals/is-symbol":292,"../internals/shared":334,"../internals/symbol-registry-detection":338,"../internals/try-to-string":349}],383:[function(e,a,f){function c(s){return Object.prototype.toString.call(s)}f.isArray=function(s){return Array.isArray?Array.isArray(s):c(s)==="[object Array]"},f.isBoolean=function(s){return typeof s=="boolean"},f.isNull=function(s){return s===null},f.isNullOrUndefined=function(s){return s==null},f.isNumber=function(s){return typeof s=="number"},f.isString=function(s){return typeof s=="string"},f.isSymbol=function(s){return typeof s=="symbol"},f.isUndefined=function(s){return s===void 0},f.isRegExp=function(s){return c(s)==="[object RegExp]"},f.isObject=function(s){return typeof s=="object"&&s!==null},f.isDate=function(s){return c(s)==="[object Date]"},f.isError=function(s){return c(s)==="[object Error]"||s instanceof Error},f.isFunction=function(s){return typeof s=="function"},f.isPrimitive=function(s){return s===null||typeof s=="boolean"||typeof s=="number"||typeof s=="string"||typeof s=="symbol"||s===void 0},f.isBuffer=e("buffer").Buffer.isBuffer},{buffer:220}],384:[function(e,a,f){(function(c){(function(){var s=e("elliptic"),l=e("bn.js");a.exports=function(h){return new n(h)};var i={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};function n(h){this.curveType=i[h],this.curveType||(this.curveType={name:h}),this.curve=new s.ec(this.curveType.name),this.keys=void 0}function o(h,u,d){Array.isArray(h)||(h=h.toArray());var m=new c(h);if(d&&m.length<d){var b=new c(d-m.length);b.fill(0),m=c.concat([b,m])}return u?m.toString(u):m}i.p224=i.secp224r1,i.p256=i.secp256r1=i.prime256v1,i.p192=i.secp192r1=i.prime192v1,i.p384=i.secp384r1,i.p521=i.secp521r1,n.prototype.generateKeys=function(h,u){return this.keys=this.curve.genKeyPair(),this.getPublicKey(h,u)},n.prototype.computeSecret=function(h,u,d){return u=u||"utf8",c.isBuffer(h)||(h=new c(h,u)),o(this.curve.keyFromPublic(h).getPublic().mul(this.keys.getPrivate()).getX(),d,this.curveType.byteLength)},n.prototype.getPublicKey=function(h,u){var d=this.keys.getPublic(u==="compressed",!0);return u==="hybrid"&&(d[d.length-1]%2?d[0]=7:d[0]=6),o(d,h)},n.prototype.getPrivateKey=function(h){return o(this.keys.getPrivate(),h)},n.prototype.setPublicKey=function(h,u){return u=u||"utf8",c.isBuffer(h)||(h=new c(h,u)),this.keys._importPublic(h),this},n.prototype.setPrivateKey=function(h,u){u=u||"utf8",c.isBuffer(h)||(h=new c(h,u));var d=new l(h);return d=d.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(d),this}}).call(this)}).call(this,e("buffer").Buffer)},{"bn.js":385,buffer:220,elliptic:405}],385:[function(e,a,f){arguments[4][184][0].apply(f,arguments)},{buffer:188,dup:184}],386:[function(e,a,f){var c=e("inherits"),s=e("md5.js"),l=e("ripemd160"),i=e("sha.js"),n=e("cipher-base");function o(h){n.call(this,"digest"),this._hash=h}c(o,n),o.prototype._update=function(h){this._hash.update(h)},o.prototype._final=function(){return this._hash.digest()},a.exports=function(h){return(h=h.toLowerCase())==="md5"?new s:h==="rmd160"||h==="ripemd160"?new l:new o(i(h))}},{"cipher-base":221,inherits:440,"md5.js":450,ripemd160:493,"sha.js":498}],387:[function(e,a,f){var c=e("md5.js");a.exports=function(s){return new c().update(s).digest()}},{"md5.js":450}],388:[function(e,a,f){var c=e("inherits"),s=e("./legacy"),l=e("cipher-base"),i=e("safe-buffer").Buffer,n=e("create-hash/md5"),o=e("ripemd160"),h=e("sha.js"),u=i.alloc(128);function d(m,b){l.call(this,"digest"),typeof b=="string"&&(b=i.from(b));var p=m==="sha512"||m==="sha384"?128:64;this._alg=m,this._key=b,b.length>p?b=(m==="rmd160"?new o:h(m)).update(b).digest():b.length<p&&(b=i.concat([b,u],p));for(var v=this._ipad=i.allocUnsafe(p),g=this._opad=i.allocUnsafe(p),x=0;x<p;x++)v[x]=54^b[x],g[x]=92^b[x];this._hash=m==="rmd160"?new o:h(m),this._hash.update(v)}c(d,l),d.prototype._update=function(m){this._hash.update(m)},d.prototype._final=function(){var m=this._hash.digest();return(this._alg==="rmd160"?new o:h(this._alg)).update(this._opad).update(m).digest()},a.exports=function(m,b){return(m=m.toLowerCase())==="rmd160"||m==="ripemd160"?new d("rmd160",b):m==="md5"?new s(n,b):new d(m,b)}},{"./legacy":389,"cipher-base":221,"create-hash/md5":387,inherits:440,ripemd160:493,"safe-buffer":494,"sha.js":498}],389:[function(e,a,f){var c=e("inherits"),s=e("safe-buffer").Buffer,l=e("cipher-base"),i=s.alloc(128);function n(o,h){l.call(this,"digest"),typeof h=="string"&&(h=s.from(h)),this._alg=o,this._key=h,h.length>64?h=o(h):h.length<64&&(h=s.concat([h,i],64));for(var u=this._ipad=s.allocUnsafe(64),d=this._opad=s.allocUnsafe(64),m=0;m<64;m++)u[m]=54^h[m],d[m]=92^h[m];this._hash=[u]}c(n,l),n.prototype._update=function(o){this._hash.push(o)},n.prototype._final=function(){var o=this._alg(s.concat(this._hash));return this._alg(s.concat([this._opad,o]))},a.exports=n},{"cipher-base":221,inherits:440,"safe-buffer":494}],390:[function(e,a,f){f.randomBytes=f.rng=f.pseudoRandomBytes=f.prng=e("randombytes"),f.createHash=f.Hash=e("create-hash"),f.createHmac=f.Hmac=e("create-hmac");var c=e("browserify-sign/algos"),s=Object.keys(c),l=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(s);f.getHashes=function(){return l};var i=e("pbkdf2");f.pbkdf2=i.pbkdf2,f.pbkdf2Sync=i.pbkdf2Sync;var n=e("browserify-cipher");f.Cipher=n.Cipher,f.createCipher=n.createCipher,f.Cipheriv=n.Cipheriv,f.createCipheriv=n.createCipheriv,f.Decipher=n.Decipher,f.createDecipher=n.createDecipher,f.Decipheriv=n.Decipheriv,f.createDecipheriv=n.createDecipheriv,f.getCiphers=n.getCiphers,f.listCiphers=n.listCiphers;var o=e("diffie-hellman");f.DiffieHellmanGroup=o.DiffieHellmanGroup,f.createDiffieHellmanGroup=o.createDiffieHellmanGroup,f.getDiffieHellman=o.getDiffieHellman,f.createDiffieHellman=o.createDiffieHellman,f.DiffieHellman=o.DiffieHellman;var h=e("browserify-sign");f.createSign=h.createSign,f.Sign=h.Sign,f.createVerify=h.createVerify,f.Verify=h.Verify,f.createECDH=e("create-ecdh");var u=e("public-encrypt");f.publicEncrypt=u.publicEncrypt,f.privateEncrypt=u.privateEncrypt,f.publicDecrypt=u.publicDecrypt,f.privateDecrypt=u.privateDecrypt;var d=e("randomfill");f.randomFill=d.randomFill,f.randomFillSync=d.randomFillSync,f.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join(` `))},f.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}},{"browserify-cipher":206,"browserify-sign":213,"browserify-sign/algos":210,"create-ecdh":384,"create-hash":386,"create-hmac":388,"diffie-hellman":400,pbkdf2:460,"public-encrypt":468,randombytes:475,randomfill:476}],391:[function(e,a,f){(function(c,s){typeof f=="object"&&a!==void 0?a.exports=s():(c=typeof globalThis<"u"?globalThis:c||self).dayjs=s()})(void 0,function(){var c=6e4,s=36e5,l="millisecond",i="second",n="minute",o="hour",h="day",u="week",d="month",m="quarter",b="year",p="date",v="Invalid Date",g=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,x=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,C={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(y){var w=["th","st","nd","rd"],_=y%100;return"["+y+(w[(_-20)%10]||w[_]||w[0])+"]"}},T=function(y,w,_){var S=String(y);return!S||S.length>=w?y:""+Array(w+1-S.length).join(_)+y},R={s:T,z:function(y){var w=-y.utcOffset(),_=Math.abs(w),S=Math.floor(_/60),A=_%60;return(w<=0?"+":"-")+T(S,2,"0")+":"+T(A,2,"0")},m:function y(w,_){if(w.date()<_.date())return-y(_,w);var S=12*(_.year()-w.year())+(_.month()-w.month()),A=w.clone().add(S,d),O=_-A<0,N=w.clone().add(S+(O?-1:1),d);return+(-(S+(_-A)/(O?A-N:N-A))||0)},a:function(y){return y<0?Math.ceil(y)||0:Math.floor(y)},p:function(y){return{M:d,y:b,w:u,d:h,D:p,h:o,m:n,s:i,ms:l,Q:m}[y]||String(y||"").toLowerCase().replace(/s$/,"")},u:function(y){return y===void 0}},B="en",I={};I[B]=C;var F="$isDayjsObject",L=function(y){return y instanceof P||!(!y||!y[F])},V=function y(w,_,S){var A;if(!w)return B;if(typeof w=="string"){var O=w.toLowerCase();I[O]&&(A=O),_&&(I[O]=_,A=O);var N=w.split("-");if(!A&&N.length>1)return y(N[0])}else{var U=w.name;I[U]=w,A=U}return!S&&A&&(B=A),A||!S&&B},z=function(y,w){if(L(y))return y.clone();var _=typeof w=="object"?w:{};return _.date=y,_.args=arguments,new P(_)},E=R;E.l=V,E.i=L,E.w=function(y,w){return z(y,{locale:w.$L,utc:w.$u,x:w.$x,$offset:w.$offset})};var P=function(){function y(_){this.$L=V(_.locale,null,!0),this.parse(_),this.$x=this.$x||_.x||{},this[F]=!0}var w=y.prototype;return w.parse=function(_){this.$d=function(S){var A=S.date,O=S.utc;if(A===null)return new Date(NaN);if(E.u(A))return new Date;if(A instanceof Date)return new Date(A);if(typeof A=="string"&&!/Z$/i.test(A)){var N=A.match(g);if(N){var U=N[2]-1||0,H=(N[7]||"0").substring(0,3);return O?new Date(Date.UTC(N[1],U,N[3]||1,N[4]||0,N[5]||0,N[6]||0,H)):new Date(N[1],U,N[3]||1,N[4]||0,N[5]||0,N[6]||0,H)}}return new Date(A)}(_),this.init()},w.init=function(){var _=this.$d;this.$y=_.getFullYear(),this.$M=_.getMonth(),this.$D=_.getDate(),this.$W=_.getDay(),this.$H=_.getHours(),this.$m=_.getMinutes(),this.$s=_.getSeconds(),this.$ms=_.getMilliseconds()},w.$utils=function(){return E},w.isValid=function(){return this.$d.toString()!==v},w.isSame=function(_,S){var A=z(_);return this.startOf(S)<=A&&A<=this.endOf(S)},w.isAfter=function(_,S){return z(_)<this.startOf(S)},w.isBefore=function(_,S){return this.endOf(S)<z(_)},w.$g=function(_,S,A){return E.u(_)?this[S]:this.set(A,_)},w.unix=function(){return Math.floor(this.valueOf()/1e3)},w.valueOf=function(){return this.$d.getTime()},w.startOf=function(_,S){var A=this,O=!!E.u(S)||S,N=E.p(_),U=function(K,J){var X=E.w(A.$u?Date.UTC(A.$y,J,K):new Date(A.$y,J,K),A);return O?X:X.endOf(h)},H=function(K,J){return E.w(A.toDate()[K].apply(A.toDate("s"),(O?[0,0,0,0]:[23,59,59,999]).slice(J)),A)},Z=this.$W,D=this.$M,q=this.$D,M="set"+(this.$u?"UTC":"");switch(N){case b:return O?U(1,0):U(31,11);case d:return O?U(1,D):U(0,D+1);case u:var j=this.$locale().weekStart||0,$=(Z<j?Z+7:Z)-j;return U(O?q-$:q+(6-$),D);case h:case p:return H(M+"Hours",0);case o:return H(M+"Minutes",1);case n:return H(M+"Seconds",2);case i:return H(M+"Milliseconds",3);default:return this.clone()}},w.endOf=function(_){return this.startOf(_,!1)},w.$set=function(_,S){var A,O=E.p(_),N="set"+(this.$u?"UTC":""),U=(A={},A[h]=N+"Date",A[p]=N+"Date",A[d]=N+"Month",A[b]=N+"FullYear",A[o]=N+"Hours",A[n]=N+"Minutes",A[i]=N+"Seconds",A[l]=N+"Milliseconds",A)[O],H=O===h?this.$D+(S-this.$W):S;if(O===d||O===b){var Z=this.clone().set(p,1);Z.$d[U](H),Z.init(),this.$d=Z.set(p,Math.min(this.$D,Z.daysInMonth())).$d}else U&&this.$d[U](H);return this.init(),this},w.set=function(_,S){return this.clone().$set(_,S)},w.get=function(_){return this[E.p(_)]()},w.add=function(_,S){var A,O=this;_=Number(_);var N=E.p(S),U=function(D){var q=z(O);return E.w(q.date(q.date()+Math.round(D*_)),O)};if(N===d)return this.set(d,this.$M+_);if(N===b)return this.set(b,this.$y+_);if(N===h)return U(1);if(N===u)return U(7);var H=(A={},A[n]=c,A[o]=s,A[i]=1e3,A)[N]||1,Z=this.$d.getTime()+_*H;return E.w(Z,this)},w.subtract=function(_,S){return this.add(-1*_,S)},w.format=function(_){var S=this,A=this.$locale();if(!this.isValid())return A.invalidDate||v;var O=_||"YYYY-MM-DDTHH:mm:ssZ",N=E.z(this),U=this.$H,H=this.$m,Z=this.$M,D=A.weekdays,q=A.months,M=A.meridiem,j=function(J,X,Q,ee){return J&&(J[X]||J(S,O))||Q[X].slice(0,ee)},$=function(J){return E.s(U%12||12,J,"0")},K=M||function(J,X,Q){var ee=J<12?"AM":"PM";return Q?ee.toLowerCase():ee};return O.replace(x,function(J,X){return X||function(Q){switch(Q){case"YY":return String(S.$y).slice(-2);case"YYYY":return E.s(S.$y,4,"0");case"M":return Z+1;case"MM":return E.s(Z+1,2,"0");case"MMM":return j(A.monthsShort,Z,q,3);case"MMMM":return j(q,Z);case"D":return S.$D;case"DD":return E.s(S.$D,2,"0");case"d":return String(S.$W);case"dd":return j(A.weekdaysMin,S.$W,D,2);case"ddd":return j(A.weekdaysShort,S.$W,D,3);case"dddd":return D[S.$W];case"H":return String(U);case"HH":return E.s(U,2,"0");case"h":return $(1);case"hh":return $(2);case"a":return K(U,H,!0);case"A":return K(U,H,!1);case"m":return String(H);case"mm":return E.s(H,2,"0");case"s":return String(S.$s);case"ss":return E.s(S.$s,2,"0");case"SSS":return E.s(S.$ms,3,"0");case"Z":return N}return null}(J)||N.replace(":","")})},w.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},w.diff=function(_,S,A){var O,N=this,U=E.p(S),H=z(_),Z=(H.utcOffset()-this.utcOffset())*c,D=this-H,q=function(){return E.m(N,H)};switch(U){case b:O=q()/12;break;case d:O=q();break;case m:O=q()/3;break;case u:O=(D-Z)/6048e5;break;case h:O=(D-Z)/864e5;break;case o:O=D/s;break;case n:O=D/c;break;case i:O=D/1e3;break;default:O=D}return A?O:E.a(O)},w.daysInMonth=function(){return this.endOf(d).$D},w.$locale=function(){return I[this.$L]},w.locale=function(_,S){if(!_)return this.$L;var A=this.clone(),O=V(_,S,!0);return O&&(A.$L=O),A},w.clone=function(){return E.w(this.$d,this)},w.toDate=function(){return new Date(this.valueOf())},w.toJSON=function(){return this.isValid()?this.toISOString():null},w.toISOString=function(){return this.$d.toISOString()},w.toString=function(){return this.$d.toUTCString()},y}(),k=P.prototype;return z.prototype=k,[["$ms",l],["$s",i],["$m",n],["$H",o],["$W",h],["$M",d],["$y",b],["$D",p]].forEach(function(y){k[y[1]]=function(w){return this.$g(w,y[0],y[1])}}),z.extend=function(y,w){return y.$i||(y(w,P,z),y.$i=!0),z},z.locale=V,z.isDayjs=L,z.unix=function(y){return z(1e3*y)},z.en=I[B],z.Ls=I,z.p={},z})},{}],392:[function(e,a,f){(function(c,s){typeof f=="object"&&a!==void 0?a.exports=s():(c=typeof globalThis<"u"?globalThis:c||self).dayjs_plugin_customParseFormat=s()})(void 0,function(){var c={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},s=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,l=/\d\d/,i=/\d\d?/,n=/\d*[^-_:/,()\s\d]+/,o={},h=function(g){return(g=+g)+(g>68?1900:2e3)},u=function(g){return function(x){this[g]=+x}},d=[/[+-]\d\d:?(\d\d)?|Z/,function(g){(this.zone||(this.zone={})).offset=function(x){if(!x||x==="Z")return 0;var C=x.match(/([+-]|\d\d)/g),T=60*C[1]+(+C[2]||0);return T===0?0:C[0]==="+"?-T:T}(g)}],m=function(g){var x=o[g];return x&&(x.indexOf?x:x.s.concat(x.f))},b=function(g,x){var C,T=o.meridiem;if(T){for(var R=1;R<=24;R+=1)if(g.indexOf(T(R,0,x))>-1){C=R>12;break}}else C=g===(x?"pm":"PM");return C},p={A:[n,function(g){this.afternoon=b(g,!1)}],a:[n,function(g){this.afternoon=b(g,!0)}],S:[/\d/,function(g){this.milliseconds=100*+g}],SS:[l,function(g){this.milliseconds=10*+g}],SSS:[/\d{3}/,function(g){this.milliseconds=+g}],s:[i,u("seconds")],ss:[i,u("seconds")],m:[i,u("minutes")],mm:[i,u("minutes")],H:[i,u("hours")],h:[i,u("hours")],HH:[i,u("hours")],hh:[i,u("hours")],D:[i,u("day")],DD:[l,u("day")],Do:[n,function(g){var x=o.ordinal,C=g.match(/\d+/);if(this.day=C[0],x)for(var T=1;T<=31;T+=1)x(T).replace(/\[|\]/g,"")===g&&(this.day=T)}],M:[i,u("month")],MM:[l,u("month")],MMM:[n,function(g){var x=m("months"),C=(m("monthsShort")||x.map(function(T){return T.slice(0,3)})).indexOf(g)+1;if(C<1)throw new Error;this.month=C%12||C}],MMMM:[n,function(g){var x=m("months").indexOf(g)+1;if(x<1)throw new Error;this.month=x%12||x}],Y:[/[+-]?\d+/,u("year")],YY:[l,function(g){this.year=h(g)}],YYYY:[/\d{4}/,u("year")],Z:d,ZZ:d};function v(g){var x,C;x=g,C=o&&o.formats;for(var T=(g=x.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(z,E,P){var k=P&&P.toUpperCase();return E||C[P]||c[P]||C[k].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(y,w,_){return w||_.slice(1)})})).match(s),R=T.length,B=0;B<R;B+=1){var I=T[B],F=p[I],L=F&&F[0],V=F&&F[1];T[B]=V?{regex:L,parser:V}:I.replace(/^\[|\]$/g,"")}return function(z){for(var E={},P=0,k=0;P<R;P+=1){var y=T[P];if(typeof y=="string")k+=y.length;else{var w=y.regex,_=y.parser,S=z.slice(k),A=w.exec(S)[0];_.call(E,A),z=z.replace(A,"")}}return function(O){var N=O.afternoon;if(N!==void 0){var U=O.hours;N?U<12&&(O.hours+=12):U===12&&(O.hours=0),delete O.afternoon}}(E),E}}return function(g,x,C){C.p.customParseFormat=!0,g&&g.parseTwoDigitYear&&(h=g.parseTwoDigitYear);var T=x.prototype,R=T.parse;T.parse=function(B){var I=B.date,F=B.utc,L=B.args;this.$u=F;var V=L[1];if(typeof V=="string"){var z=L[2]===!0,E=L[3]===!0,P=z||E,k=L[2];E&&(k=L[2]),o=this.$locale(),!z&&k&&(o=C.Ls[k]),this.$d=function(S,A,O){try{if(["x","X"].indexOf(A)>-1)return new Date((A==="X"?1e3:1)*S);var N=v(A)(S),U=N.year,H=N.month,Z=N.day,D=N.hours,q=N.minutes,M=N.seconds,j=N.milliseconds,$=N.zone,K=new Date,J=Z||(U||H?1:K.getDate()),X=U||K.getFullYear(),Q=0;U&&!H||(Q=H>0?H-1:K.getMonth());var ee=D||0,se=q||0,Y=M||0,te=j||0;return $?new Date(Date.UTC(X,Q,J,ee,se,Y,te+60*$.offset*1e3)):O?new Date(Date.UTC(X,Q,J,ee,se,Y,te)):new Date(X,Q,J,ee,se,Y,te)}catch{return new Date("")}}(I,V,F),this.init(),k&&k!==!0&&(this.$L=this.locale(k).$L),P&&I!=this.format(V)&&(this.$d=new Date("")),o={}}else if(V instanceof Array)for(var y=V.length,w=1;w<=y;w+=1){L[1]=V[w-1];var _=C.apply(this,L);if(_.isValid()){this.$d=_.$d,this.$L=_.$L,this.init();break}w===y&&(this.$d=new Date(""))}else R.call(this,B)}}})},{}],393:[function(e,a,f){(function(c,s){typeof f=="object"&&a!==void 0?a.exports=s():(c=typeof globalThis<"u"?globalThis:c||self).dayjs_plugin_utc=s()})(void 0,function(){var c="minute",s=/[+-]\d\d(?::?\d\d)?/g,l=/([+-]|\d\d)/g;return function(i,n,o){var h=n.prototype;o.utc=function(g){var x={date:g,utc:!0,args:arguments};return new n(x)},h.utc=function(g){var x=o(this.toDate(),{locale:this.$L,utc:!0});return g?x.add(this.utcOffset(),c):x},h.local=function(){return o(this.toDate(),{locale:this.$L,utc:!1})};var u=h.parse;h.parse=function(g){g.utc&&(this.$u=!0),this.$utils().u(g.$offset)||(this.$offset=g.$offset),u.call(this,g)};var d=h.init;h.init=function(){if(this.$u){var g=this.$d;this.$y=g.getUTCFullYear(),this.$M=g.getUTCMonth(),this.$D=g.getUTCDate(),this.$W=g.getUTCDay(),this.$H=g.getUTCHours(),this.$m=g.getUTCMinutes(),this.$s=g.getUTCSeconds(),this.$ms=g.getUTCMilliseconds()}else d.call(this)};var m=h.utcOffset;h.utcOffset=function(g,x){var C=this.$utils().u;if(C(g))return this.$u?0:C(this.$offset)?m.call(this):this.$offset;if(typeof g=="string"&&(g=function(I){I===void 0&&(I="");var F=I.match(s);if(!F)return null;var L=(""+F[0]).match(l)||["-",0,0],V=L[0],z=60*+L[1]+ +L[2];return z===0?0:V==="+"?z:-z}(g))===null)return this;var T=Math.abs(g)<=16?60*g:g,R=this;if(x)return R.$offset=T,R.$u=g===0,R;if(g!==0){var B=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(R=this.local().add(T+B,c)).$offset=T,R.$x.$localOffset=B}else R=this.utc();return R};var b=h.format;h.format=function(g){var x=g||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return b.call(this,x)},h.valueOf=function(){var g=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*g},h.isUTC=function(){return!!this.$u},h.toISOString=function(){return this.toDate().toISOString()},h.toString=function(){return this.toDate().toUTCString()};var p=h.toDate;h.toDate=function(g){return g==="s"&&this.$offset?o(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():p.call(this)};var v=h.diff;h.diff=function(g,x,C){if(g&&this.$u===g.$u)return v.call(this,g,x,C);var T=this.local(),R=o(g).local();return v.call(T,R,x,C)}}})},{}],394:[function(e,a,f){f.utils=e("./des/utils"),f.Cipher=e("./des/cipher"),f.DES=e("./des/des"),f.CBC=e("./des/cbc"),f.EDE=e("./des/ede")},{"./des/cbc":395,"./des/cipher":396,"./des/des":397,"./des/ede":398,"./des/utils":399}],395:[function(e,a,f){var c=e("minimalistic-assert"),s=e("inherits"),l={};function i(n){c.equal(n.length,8,"Invalid IV length"),this.iv=new Array(8);for(var o=0;o<this.iv.length;o++)this.iv[o]=n[o]}f.instantiate=function(n){function o(m){n.call(this,m),this._cbcInit()}s(o,n);for(var h=Object.keys(l),u=0;u<h.length;u++){var d=h[u];o.prototype[d]=l[d]}return o.create=function(m){return new o(m)},o},l._cbcInit=function(){var n=new i(this.options.iv);this._cbcState=n},l._update=function(n,o,h,u){var d=this._cbcState,m=this.constructor.super_.prototype,b=d.iv;if(this.type==="encrypt"){for(var p=0;p<this.blockSize;p++)b[p]^=n[o+p];for(m._update.call(this,b,0,h,u),p=0;p<this.blockSize;p++)b[p]=h[u+p]}else{for(m._update.call(this,n,o,h,u),p=0;p<this.blockSize;p++)h[u+p]^=b[p];for(p=0;p<this.blockSize;p++)b[p]=n[o+p]}}},{inherits:440,"minimalistic-assert":453}],396:[function(e,a,f){var c=e("minimalistic-assert");function s(l){this.options=l,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0,this.padding=l.padding!==!1}a.exports=s,s.prototype._init=function(){},s.prototype.update=function(l){return l.length===0?[]:this.type==="decrypt"?this._updateDecrypt(l):this._updateEncrypt(l)},s.prototype._buffer=function(l,i){for(var n=Math.min(this.buffer.length-this.bufferOff,l.length-i),o=0;o<n;o++)this.buffer[this.bufferOff+o]=l[i+o];return this.bufferOff+=n,n},s.prototype._flushBuffer=function(l,i){return this._update(this.buffer,0,l,i),this.bufferOff=0,this.blockSize},s.prototype._updateEncrypt=function(l){var i=0,n=0,o=(this.bufferOff+l.length)/this.blockSize|0,h=new Array(o*this.blockSize);this.bufferOff!==0&&(i+=this._buffer(l,i),this.bufferOff===this.buffer.length&&(n+=this._flushBuffer(h,n)));for(var u=l.length-(l.length-i)%this.blockSize;i<u;i+=this.blockSize)this._update(l,i,h,n),n+=this.blockSize;for(;i<l.length;i++,this.bufferOff++)this.buffer[this.bufferOff]=l[i];return h},s.prototype._updateDecrypt=function(l){for(var i=0,n=0,o=Math.ceil((this.bufferOff+l.length)/this.blockSize)-1,h=new Array(o*this.blockSize);o>0;o--)i+=this._buffer(l,i),n+=this._flushBuffer(h,n);return i+=this._buffer(l,i),h},s.prototype.final=function(l){var i,n;return l&&(i=this.update(l)),n=this.type==="encrypt"?this._finalEncrypt():this._finalDecrypt(),i?i.concat(n):n},s.prototype._pad=function(l,i){if(i===0)return!1;for(;i<l.length;)l[i++]=0;return!0},s.prototype._finalEncrypt=function(){if(!this._pad(this.buffer,this.bufferOff))return[];var l=new Array(this.blockSize);return this._update(this.buffer,0,l,0),l},s.prototype._unpad=function(l){return l},s.prototype._finalDecrypt=function(){c.equal(this.bufferOff,this.blockSize,"Not enough data to decrypt");var l=new Array(this.blockSize);return this._flushBuffer(l,0),this._unpad(l)}},{"minimalistic-assert":453}],397:[function(e,a,f){var c=e("minimalistic-assert"),s=e("inherits"),l=e("./utils"),i=e("./cipher");function n(){this.tmp=new Array(2),this.keys=null}function o(u){i.call(this,u);var d=new n;this._desState=d,this.deriveKeys(d,u.key)}s(o,i),a.exports=o,o.create=function(u){return new o(u)};var h=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];o.prototype.deriveKeys=function(u,d){u.keys=new Array(32),c.equal(d.length,this.blockSize,"Invalid key length");var m=l.readUInt32BE(d,0),b=l.readUInt32BE(d,4);l.pc1(m,b,u.tmp,0),m=u.tmp[0],b=u.tmp[1];for(var p=0;p<u.keys.length;p+=2){var v=h[p>>>1];m=l.r28shl(m,v),b=l.r28shl(b,v),l.pc2(m,b,u.keys,p)}},o.prototype._update=function(u,d,m,b){var p=this._desState,v=l.readUInt32BE(u,d),g=l.readUInt32BE(u,d+4);l.ip(v,g,p.tmp,0),v=p.tmp[0],g=p.tmp[1],this.type==="encrypt"?this._encrypt(p,v,g,p.tmp,0):this._decrypt(p,v,g,p.tmp,0),v=p.tmp[0],g=p.tmp[1],l.writeUInt32BE(m,v,b),l.writeUInt32BE(m,g,b+4)},o.prototype._pad=function(u,d){if(this.padding===!1)return!1;for(var m=u.length-d,b=d;b<u.length;b++)u[b]=m;return!0},o.prototype._unpad=function(u){if(this.padding===!1)return u;for(var d=u[u.length-1],m=u.length-d;m<u.length;m++)c.equal(u[m],d);return u.slice(0,u.length-d)},o.prototype._encrypt=function(u,d,m,b,p){for(var v=d,g=m,x=0;x<u.keys.length;x+=2){var C=u.keys[x],T=u.keys[x+1];l.expand(g,u.tmp,0),C^=u.tmp[0],T^=u.tmp[1];var R=l.substitute(C,T),B=g;g=(v^l.permute(R))>>>0,v=B}l.rip(g,v,b,p)},o.prototype._decrypt=function(u,d,m,b,p){for(var v=m,g=d,x=u.keys.length-2;x>=0;x-=2){var C=u.keys[x],T=u.keys[x+1];l.expand(v,u.tmp,0),C^=u.tmp[0],T^=u.tmp[1];var R=l.substitute(C,T),B=v;v=(g^l.permute(R))>>>0,g=B}l.rip(v,g,b,p)}},{"./cipher":396,"./utils":399,inherits:440,"minimalistic-assert":453}],398:[function(e,a,f){var c=e("minimalistic-assert"),s=e("inherits"),l=e("./cipher"),i=e("./des");function n(h,u){c.equal(u.length,24,"Invalid key length");var d=u.slice(0,8),m=u.slice(8,16),b=u.slice(16,24);this.ciphers=h==="encrypt"?[i.create({type:"encrypt",key:d}),i.create({type:"decrypt",key:m}),i.create({type:"encrypt",key:b})]:[i.create({type:"decrypt",key:b}),i.create({type:"encrypt",key:m}),i.create({type:"decrypt",key:d})]}function o(h){l.call(this,h);var u=new n(this.type,this.options.key);this._edeState=u}s(o,l),a.exports=o,o.create=function(h){return new o(h)},o.prototype._update=function(h,u,d,m){var b=this._edeState;b.ciphers[0]._update(h,u,d,m),b.ciphers[1]._update(d,m,d,m),b.ciphers[2]._update(d,m,d,m)},o.prototype._pad=i.prototype._pad,o.prototype._unpad=i.prototype._unpad},{"./cipher":396,"./des":397,inherits:440,"minimalistic-assert":453}],399:[function(e,a,f){f.readUInt32BE=function(i,n){return(i[0+n]<<24|i[1+n]<<16|i[2+n]<<8|i[3+n])>>>0},f.writeUInt32BE=function(i,n,o){i[0+o]=n>>>24,i[1+o]=n>>>16&255,i[2+o]=n>>>8&255,i[3+o]=255&n},f.ip=function(i,n,o,h){for(var u=0,d=0,m=6;m>=0;m-=2){for(var b=0;b<=24;b+=8)u<<=1,u|=n>>>b+m&1;for(b=0;b<=24;b+=8)u<<=1,u|=i>>>b+m&1}for(m=6;m>=0;m-=2){for(b=1;b<=25;b+=8)d<<=1,d|=n>>>b+m&1;for(b=1;b<=25;b+=8)d<<=1,d|=i>>>b+m&1}o[h+0]=u>>>0,o[h+1]=d>>>0},f.rip=function(i,n,o,h){for(var u=0,d=0,m=0;m<4;m++)for(var b=24;b>=0;b-=8)u<<=1,u|=n>>>b+m&1,u<<=1,u|=i>>>b+m&1;for(m=4;m<8;m++)for(b=24;b>=0;b-=8)d<<=1,d|=n>>>b+m&1,d<<=1,d|=i>>>b+m&1;o[h+0]=u>>>0,o[h+1]=d>>>0},f.pc1=function(i,n,o,h){for(var u=0,d=0,m=7;m>=5;m--){for(var b=0;b<=24;b+=8)u<<=1,u|=n>>b+m&1;for(b=0;b<=24;b+=8)u<<=1,u|=i>>b+m&1}for(b=0;b<=24;b+=8)u<<=1,u|=n>>b+m&1;for(m=1;m<=3;m++){for(b=0;b<=24;b+=8)d<<=1,d|=n>>b+m&1;for(b=0;b<=24;b+=8)d<<=1,d|=i>>b+m&1}for(b=0;b<=24;b+=8)d<<=1,d|=i>>b+m&1;o[h+0]=u>>>0,o[h+1]=d>>>0},f.r28shl=function(i,n){return i<<n&268435455|i>>>28-n};var c=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];f.pc2=function(i,n,o,h){for(var u=0,d=0,m=c.length>>>1,b=0;b<m;b++)u<<=1,u|=i>>>c[b]&1;for(b=m;b<c.length;b++)d<<=1,d|=n>>>c[b]&1;o[h+0]=u>>>0,o[h+1]=d>>>0},f.expand=function(i,n,o){var h=0,u=0;h=(1&i)<<5|i>>>27;for(var d=23;d>=15;d-=4)h<<=6,h|=i>>>d&63;for(d=11;d>=3;d-=4)u|=i>>>d&63,u<<=6;u|=(31&i)<<1|i>>>31,n[o+0]=h>>>0,n[o+1]=u>>>0};var s=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];f.substitute=function(i,n){for(var o=0,h=0;h<4;h++)o<<=4,o|=s[64*h+(i>>>18-6*h&63)];for(h=0;h<4;h++)o<<=4,o|=s[256+64*h+(n>>>18-6*h&63)];return o>>>0};var l=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];f.permute=function(i){for(var n=0,o=0;o<l.length;o++)n<<=1,n|=i>>>l[o]&1;return n>>>0},f.padSplit=function(i,n,o){for(var h=i.toString(2);h.length<n;)h="0"+h;for(var u=[],d=0;d<n;d+=o)u.push(h.slice(d,d+o));return u.join(" ")}},{}],400:[function(e,a,f){(function(c){(function(){var s=e("./lib/generatePrime"),l=e("./lib/primes.json"),i=e("./lib/dh"),n={binary:!0,hex:!0,base64:!0};f.DiffieHellmanGroup=f.createDiffieHellmanGroup=f.getDiffieHellman=function(o){var h=new c(l[o].prime,"hex"),u=new c(l[o].gen,"hex");return new i(h,u)},f.createDiffieHellman=f.DiffieHellman=function o(h,u,d,m){return c.isBuffer(u)||n[u]===void 0?o(h,"binary",u,d):(u=u||"binary",m=m||"binary",d=d||new c([2]),c.isBuffer(d)||(d=new c(d,m)),typeof h=="number"?new i(s(h,d),d,!0):(c.isBuffer(h)||(h=new c(h,u)),new i(h,d,!0)))}}).call(this)}).call(this,e("buffer").Buffer)},{"./lib/dh":401,"./lib/generatePrime":402,"./lib/primes.json":403,buffer:220}],401:[function(e,a,f){(function(c){(function(){var s=e("bn.js"),l=new(e("miller-rabin")),i=new s(24),n=new s(11),o=new s(10),h=new s(3),u=new s(7),d=e("./generatePrime"),m=e("randombytes");function b(C,T){return T=T||"utf8",c.isBuffer(C)||(C=new c(C,T)),this._pub=new s(C),this}function p(C,T){return T=T||"utf8",c.isBuffer(C)||(C=new c(C,T)),this._priv=new s(C),this}a.exports=g;var v={};function g(C,T,R){this.setGenerator(T),this.__prime=new s(C),this._prime=s.mont(this.__prime),this._primeLen=C.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,R?(this.setPublicKey=b,this.setPrivateKey=p):this._primeCode=8}function x(C,T){var R=new c(C.toArray());return T?R.toString(T):R}Object.defineProperty(g.prototype,"verifyError",{enumerable:!0,get:function(){return typeof this._primeCode!="number"&&(this._primeCode=function(C,T){var R=T.toString("hex"),B=[R,C.toString(16)].join("_");if(B in v)return v[B];var I,F=0;if(C.isEven()||!d.simpleSieve||!d.fermatTest(C)||!l.test(C))return F+=1,F+=R==="02"||R==="05"?8:4,v[B]=F,F;switch(l.test(C.shrn(1))||(F+=2),R){case"02":C.mod(i).cmp(n)&&(F+=8);break;case"05":(I=C.mod(o)).cmp(h)&&I.cmp(u)&&(F+=8);break;default:F+=4}return v[B]=F,F}(this.__prime,this.__gen)),this._primeCode}}),g.prototype.generateKeys=function(){return this._priv||(this._priv=new s(m(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},g.prototype.computeSecret=function(C){var T=(C=(C=new s(C)).toRed(this._prime)).redPow(this._priv).fromRed(),R=new c(T.toArray()),B=this.getPrime();if(R.length<B.length){var I=new c(B.length-R.length);I.fill(0),R=c.concat([I,R])}return R},g.prototype.getPublicKey=function(C){return x(this._pub,C)},g.prototype.getPrivateKey=function(C){return x(this._priv,C)},g.prototype.getPrime=function(C){return x(this.__prime,C)},g.prototype.getGenerator=function(C){return x(this._gen,C)},g.prototype.setGenerator=function(C,T){return T=T||"utf8",c.isBuffer(C)||(C=new c(C,T)),this.__gen=C,this._gen=new s(C),this}}).call(this)}).call(this,e("buffer").Buffer)},{"./generatePrime":402,"bn.js":404,buffer:220,"miller-rabin":451,randombytes:475}],402:[function(e,a,f){var c=e("randombytes");a.exports=C,C.simpleSieve=g,C.fermatTest=x;var s=e("bn.js"),l=new s(24),i=new(e("miller-rabin")),n=new s(1),o=new s(2),h=new s(5),u=(new s(16),new s(8),new s(10)),d=new s(3),m=(new s(7),new s(11)),b=new s(4),p=(new s(12),null);function v(){if(p!==null)return p;var T=[];T[0]=2;for(var R=1,B=3;B<1048576;B+=2){for(var I=Math.ceil(Math.sqrt(B)),F=0;F<R&&T[F]<=I&&B%T[F]!=0;F++);R!==F&&T[F]<=I||(T[R++]=B)}return p=T,T}function g(T){for(var R=v(),B=0;B<R.length;B++)if(T.modn(R[B])===0)return T.cmpn(R[B])===0;return!0}function x(T){var R=s.mont(T);return o.toRed(R).redPow(T.subn(1)).fromRed().cmpn(1)===0}function C(T,R){if(T<16)return new s(R===2||R===5?[140,123]:[140,39]);var B,I;for(R=new s(R);;){for(B=new s(c(Math.ceil(T/8)));B.bitLength()>T;)B.ishrn(1);if(B.isEven()&&B.iadd(n),B.testn(1)||B.iadd(o),R.cmp(o)){if(!R.cmp(h))for(;B.mod(u).cmp(d);)B.iadd(b)}else for(;B.mod(l).cmp(m);)B.iadd(b);if(g(I=B.shrn(1))&&g(B)&&x(I)&&x(B)&&i.test(I)&&i.test(B))return B}}},{"bn.js":404,"miller-rabin":451,randombytes:475}],403:[function(e,a,f){a.exports={modp1:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},modp2:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},modp5:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},modp14:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},modp15:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},modp16:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},modp17:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},modp18:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"}}},{}],404:[function(e,a,f){arguments[4][184][0].apply(f,arguments)},{buffer:188,dup:184}],405:[function(e,a,f){var c=f;c.version=e("../package.json").version,c.utils=e("./elliptic/utils"),c.rand=e("brorand"),c.curve=e("./elliptic/curve"),c.curves=e("./elliptic/curves"),c.ec=e("./elliptic/ec"),c.eddsa=e("./elliptic/eddsa")},{"../package.json":421,"./elliptic/curve":408,"./elliptic/curves":411,"./elliptic/ec":412,"./elliptic/eddsa":415,"./elliptic/utils":419,brorand:187}],406:[function(e,a,f){var c=e("bn.js"),s=e("../utils"),l=s.getNAF,i=s.getJSF,n=s.assert;function o(u,d){this.type=u,this.p=new c(d.p,16),this.red=d.prime?c.red(d.prime):c.mont(this.p),this.zero=new c(0).toRed(this.red),this.one=new c(1).toRed(this.red),this.two=new c(2).toRed(this.red),this.n=d.n&&new c(d.n,16),this.g=d.g&&this.pointFromJSON(d.g,d.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var m=this.n&&this.p.div(this.n);!m||m.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function h(u,d){this.curve=u,this.type=d,this.precomputed=null}a.exports=o,o.prototype.point=function(){throw new Error("Not implemented")},o.prototype.validate=function(){throw new Error("Not implemented")},o.prototype._fixedNafMul=function(u,d){n(u.precomputed);var m=u._getDoubles(),b=l(d,1,this._bitLength),p=(1<<m.step+1)-(m.step%2==0?2:1);p/=3;var v,g,x=[];for(v=0;v<b.length;v+=m.step){g=0;for(var C=v+m.step-1;C>=v;C--)g=(g<<1)+b[C];x.push(g)}for(var T=this.jpoint(null,null,null),R=this.jpoint(null,null,null),B=p;B>0;B--){for(v=0;v<x.length;v++)(g=x[v])===B?R=R.mixedAdd(m.points[v]):g===-B&&(R=R.mixedAdd(m.points[v].neg()));T=T.add(R)}return T.toP()},o.prototype._wnafMul=function(u,d){var m=4,b=u._getNAFPoints(m);m=b.wnd;for(var p=b.points,v=l(d,m,this._bitLength),g=this.jpoint(null,null,null),x=v.length-1;x>=0;x--){for(var C=0;x>=0&&v[x]===0;x--)C++;if(x>=0&&C++,g=g.dblp(C),x<0)break;var T=v[x];n(T!==0),g=u.type==="affine"?T>0?g.mixedAdd(p[T-1>>1]):g.mixedAdd(p[-T-1>>1].neg()):T>0?g.add(p[T-1>>1]):g.add(p[-T-1>>1].neg())}return u.type==="affine"?g.toP():g},o.prototype._wnafMulAdd=function(u,d,m,b,p){var v,g,x,C=this._wnafT1,T=this._wnafT2,R=this._wnafT3,B=0;for(v=0;v<b;v++){var I=(x=d[v])._getNAFPoints(u);C[v]=I.wnd,T[v]=I.points}for(v=b-1;v>=1;v-=2){var F=v-1,L=v;if(C[F]===1&&C[L]===1){var V=[d[F],null,null,d[L]];d[F].y.cmp(d[L].y)===0?(V[1]=d[F].add(d[L]),V[2]=d[F].toJ().mixedAdd(d[L].neg())):d[F].y.cmp(d[L].y.redNeg())===0?(V[1]=d[F].toJ().mixedAdd(d[L]),V[2]=d[F].add(d[L].neg())):(V[1]=d[F].toJ().mixedAdd(d[L]),V[2]=d[F].toJ().mixedAdd(d[L].neg()));var z=[-3,-1,-5,-7,0,7,5,1,3],E=i(m[F],m[L]);for(B=Math.max(E[0].length,B),R[F]=new Array(B),R[L]=new Array(B),g=0;g<B;g++){var P=0|E[0][g],k=0|E[1][g];R[F][g]=z[3*(P+1)+(k+1)],R[L][g]=0,T[F]=V}}else R[F]=l(m[F],C[F],this._bitLength),R[L]=l(m[L],C[L],this._bitLength),B=Math.max(R[F].length,B),B=Math.max(R[L].length,B)}var y=this.jpoint(null,null,null),w=this._wnafT4;for(v=B;v>=0;v--){for(var _=0;v>=0;){var S=!0;for(g=0;g<b;g++)w[g]=0|R[g][v],w[g]!==0&&(S=!1);if(!S)break;_++,v--}if(v>=0&&_++,y=y.dblp(_),v<0)break;for(g=0;g<b;g++){var A=w[g];A!==0&&(A>0?x=T[g][A-1>>1]:A<0&&(x=T[g][-A-1>>1].neg()),y=x.type==="affine"?y.mixedAdd(x):y.add(x))}}for(v=0;v<b;v++)T[v]=null;return p?y:y.toP()},o.BasePoint=h,h.prototype.eq=function(){throw new Error("Not implemented")},h.prototype.validate=function(){return this.curve.validate(this)},o.prototype.decodePoint=function(u,d){u=s.toArray(u,d);var m=this.p.byteLength();if((u[0]===4||u[0]===6||u[0]===7)&&u.length-1==2*m)return u[0]===6?n(u[u.length-1]%2==0):u[0]===7&&n(u[u.length-1]%2==1),this.point(u.slice(1,1+m),u.slice(1+m,1+2*m));if((u[0]===2||u[0]===3)&&u.length-1===m)return this.pointFromX(u.slice(1,1+m),u[0]===3);throw new Error("Unknown point format")},h.prototype.encodeCompressed=function(u){return this.encode(u,!0)},h.prototype._encode=function(u){var d=this.curve.p.byteLength(),m=this.getX().toArray("be",d);return u?[this.getY().isEven()?2:3].concat(m):[4].concat(m,this.getY().toArray("be",d))},h.prototype.encode=function(u,d){return s.encode(this._encode(d),u)},h.prototype.precompute=function(u){if(this.precomputed)return this;var d={doubles:null,naf:null,beta:null};return d.naf=this._getNAFPoints(8),d.doubles=this._getDoubles(4,u),d.beta=this._getBeta(),this.precomputed=d,this},h.prototype._hasDoubles=function(u){if(!this.precomputed)return!1;var d=this.precomputed.doubles;return!!d&&d.points.length>=Math.ceil((u.bitLength()+1)/d.step)},h.prototype._getDoubles=function(u,d){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var m=[this],b=this,p=0;p<d;p+=u){for(var v=0;v<u;v++)b=b.dbl();m.push(b)}return{step:u,points:m}},h.prototype._getNAFPoints=function(u){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var d=[this],m=(1<<u)-1,b=m===1?null:this.dbl(),p=1;p<m;p++)d[p]=d[p-1].add(b);return{wnd:u,points:d}},h.prototype._getBeta=function(){return null},h.prototype.dblp=function(u){for(var d=this,m=0;m<u;m++)d=d.dbl();return d}},{"../utils":419,"bn.js":420}],407:[function(e,a,f){var c=e("../utils"),s=e("bn.js"),l=e("inherits"),i=e("./base"),n=c.assert;function o(u){this.twisted=(0|u.a)!=1,this.mOneA=this.twisted&&(0|u.a)==-1,this.extended=this.mOneA,i.call(this,"edwards",u),this.a=new s(u.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new s(u.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new s(u.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),n(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(0|u.c)==1}function h(u,d,m,b,p){i.BasePoint.call(this,u,"projective"),d===null&&m===null&&b===null?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new s(d,16),this.y=new s(m,16),this.z=b?new s(b,16):this.curve.one,this.t=p&&new s(p,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}l(o,i),a.exports=o,o.prototype._mulA=function(u){return this.mOneA?u.redNeg():this.a.redMul(u)},o.prototype._mulC=function(u){return this.oneC?u:this.c.redMul(u)},o.prototype.jpoint=function(u,d,m,b){return this.point(u,d,m,b)},o.prototype.pointFromX=function(u,d){(u=new s(u,16)).red||(u=u.toRed(this.red));var m=u.redSqr(),b=this.c2.redSub(this.a.redMul(m)),p=this.one.redSub(this.c2.redMul(this.d).redMul(m)),v=b.redMul(p.redInvm()),g=v.redSqrt();if(g.redSqr().redSub(v).cmp(this.zero)!==0)throw new Error("invalid point");var x=g.fromRed().isOdd();return(d&&!x||!d&&x)&&(g=g.redNeg()),this.point(u,g)},o.prototype.pointFromY=function(u,d){(u=new s(u,16)).red||(u=u.toRed(this.red));var m=u.redSqr(),b=m.redSub(this.c2),p=m.redMul(this.d).redMul(this.c2).redSub(this.a),v=b.redMul(p.redInvm());if(v.cmp(this.zero)===0){if(d)throw new Error("invalid point");return this.point(this.zero,u)}var g=v.redSqrt();if(g.redSqr().redSub(v).cmp(this.zero)!==0)throw new Error("invalid point");return g.fromRed().isOdd()!==d&&(g=g.redNeg()),this.point(g,u)},o.prototype.validate=function(u){if(u.isInfinity())return!0;u.normalize();var d=u.x.redSqr(),m=u.y.redSqr(),b=d.redMul(this.a).redAdd(m),p=this.c2.redMul(this.one.redAdd(this.d.redMul(d).redMul(m)));return b.cmp(p)===0},l(h,i.BasePoint),o.prototype.pointFromJSON=function(u){return h.fromJSON(this,u)},o.prototype.point=function(u,d,m,b){return new h(this,u,d,m,b)},h.fromJSON=function(u,d){return new h(u,d[0],d[1],d[2])},h.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},h.prototype.isInfinity=function(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)},h.prototype._extDbl=function(){var u=this.x.redSqr(),d=this.y.redSqr(),m=this.z.redSqr();m=m.redIAdd(m);var b=this.curve._mulA(u),p=this.x.redAdd(this.y).redSqr().redISub(u).redISub(d),v=b.redAdd(d),g=v.redSub(m),x=b.redSub(d),C=p.redMul(g),T=v.redMul(x),R=p.redMul(x),B=g.redMul(v);return this.curve.point(C,T,B,R)},h.prototype._projDbl=function(){var u,d,m,b,p,v,g=this.x.redAdd(this.y).redSqr(),x=this.x.redSqr(),C=this.y.redSqr();if(this.curve.twisted){var T=(b=this.curve._mulA(x)).redAdd(C);this.zOne?(u=g.redSub(x).redSub(C).redMul(T.redSub(this.curve.two)),d=T.redMul(b.redSub(C)),m=T.redSqr().redSub(T).redSub(T)):(p=this.z.redSqr(),v=T.redSub(p).redISub(p),u=g.redSub(x).redISub(C).redMul(v),d=T.redMul(b.redSub(C)),m=T.redMul(v))}else b=x.redAdd(C),p=this.curve._mulC(this.z).redSqr(),v=b.redSub(p).redSub(p),u=this.curve._mulC(g.redISub(b)).redMul(v),d=this.curve._mulC(b).redMul(x.redISub(C)),m=b.redMul(v);return this.curve.point(u,d,m)},h.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},h.prototype._extAdd=function(u){var d=this.y.redSub(this.x).redMul(u.y.redSub(u.x)),m=this.y.redAdd(this.x).redMul(u.y.redAdd(u.x)),b=this.t.redMul(this.curve.dd).redMul(u.t),p=this.z.redMul(u.z.redAdd(u.z)),v=m.redSub(d),g=p.redSub(b),x=p.redAdd(b),C=m.redAdd(d),T=v.redMul(g),R=x.redMul(C),B=v.redMul(C),I=g.redMul(x);return this.curve.point(T,R,I,B)},h.prototype._projAdd=function(u){var d,m,b=this.z.redMul(u.z),p=b.redSqr(),v=this.x.redMul(u.x),g=this.y.redMul(u.y),x=this.curve.d.redMul(v).redMul(g),C=p.redSub(x),T=p.redAdd(x),R=this.x.redAdd(this.y).redMul(u.x.redAdd(u.y)).redISub(v).redISub(g),B=b.redMul(C).redMul(R);return this.curve.twisted?(d=b.redMul(T).redMul(g.redSub(this.curve._mulA(v))),m=C.redMul(T)):(d=b.redMul(T).redMul(g.redSub(v)),m=this.curve._mulC(C).redMul(T)),this.curve.point(B,d,m)},h.prototype.add=function(u){return this.isInfinity()?u:u.isInfinity()?this:this.curve.extended?this._extAdd(u):this._projAdd(u)},h.prototype.mul=function(u){return this._hasDoubles(u)?this.curve._fixedNafMul(this,u):this.curve._wnafMul(this,u)},h.prototype.mulAdd=function(u,d,m){return this.curve._wnafMulAdd(1,[this,d],[u,m],2,!1)},h.prototype.jmulAdd=function(u,d,m){return this.curve._wnafMulAdd(1,[this,d],[u,m],2,!0)},h.prototype.normalize=function(){if(this.zOne)return this;var u=this.z.redInvm();return this.x=this.x.redMul(u),this.y=this.y.redMul(u),this.t&&(this.t=this.t.redMul(u)),this.z=this.curve.one,this.zOne=!0,this},h.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},h.prototype.getX=function(){return this.normalize(),this.x.fromRed()},h.prototype.getY=function(){return this.normalize(),this.y.fromRed()},h.prototype.eq=function(u){return this===u||this.getX().cmp(u.getX())===0&&this.getY().cmp(u.getY())===0},h.prototype.eqXToP=function(u){var d=u.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(d)===0)return!0;for(var m=u.clone(),b=this.curve.redN.redMul(this.z);;){if(m.iadd(this.curve.n),m.cmp(this.curve.p)>=0)return!1;if(d.redIAdd(b),this.x.cmp(d)===0)return!0}},h.prototype.toP=h.prototype.normalize,h.prototype.mixedAdd=h.prototype.add},{"../utils":419,"./base":406,"bn.js":420,inherits:440}],408:[function(e,a,f){var c=f;c.base=e("./base"),c.short=e("./short"),c.mont=e("./mont"),c.edwards=e("./edwards")},{"./base":406,"./edwards":407,"./mont":409,"./short":410}],409:[function(e,a,f){var c=e("bn.js"),s=e("inherits"),l=e("./base"),i=e("../utils");function n(h){l.call(this,"mont",h),this.a=new c(h.a,16).toRed(this.red),this.b=new c(h.b,16).toRed(this.red),this.i4=new c(4).toRed(this.red).redInvm(),this.two=new c(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function o(h,u,d){l.BasePoint.call(this,h,"projective"),u===null&&d===null?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new c(u,16),this.z=new c(d,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}s(n,l),a.exports=n,n.prototype.validate=function(h){var u=h.normalize().x,d=u.redSqr(),m=d.redMul(u).redAdd(d.redMul(this.a)).redAdd(u);return m.redSqrt().redSqr().cmp(m)===0},s(o,l.BasePoint),n.prototype.decodePoint=function(h,u){return this.point(i.toArray(h,u),1)},n.prototype.point=function(h,u){return new o(this,h,u)},n.prototype.pointFromJSON=function(h){return o.fromJSON(this,h)},o.prototype.precompute=function(){},o.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},o.fromJSON=function(h,u){return new o(h,u[0],u[1]||h.one)},o.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},o.prototype.isInfinity=function(){return this.z.cmpn(0)===0},o.prototype.dbl=function(){var h=this.x.redAdd(this.z).redSqr(),u=this.x.redSub(this.z).redSqr(),d=h.redSub(u),m=h.redMul(u),b=d.redMul(u.redAdd(this.curve.a24.redMul(d)));return this.curve.point(m,b)},o.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},o.prototype.diffAdd=function(h,u){var d=this.x.redAdd(this.z),m=this.x.redSub(this.z),b=h.x.redAdd(h.z),p=h.x.redSub(h.z).redMul(d),v=b.redMul(m),g=u.z.redMul(p.redAdd(v).redSqr()),x=u.x.redMul(p.redISub(v).redSqr());return this.curve.point(g,x)},o.prototype.mul=function(h){for(var u=h.clone(),d=this,m=this.curve.point(null,null),b=[];u.cmpn(0)!==0;u.iushrn(1))b.push(u.andln(1));for(var p=b.length-1;p>=0;p--)b[p]===0?(d=d.diffAdd(m,this),m=m.dbl()):(m=d.diffAdd(m,this),d=d.dbl());return m},o.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},o.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},o.prototype.eq=function(h){return this.getX().cmp(h.getX())===0},o.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},o.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},{"../utils":419,"./base":406,"bn.js":420,inherits:440}],410:[function(e,a,f){var c=e("../utils"),s=e("bn.js"),l=e("inherits"),i=e("./base"),n=c.assert;function o(d){i.call(this,"short",d),this.a=new s(d.a,16).toRed(this.red),this.b=new s(d.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=this.a.fromRed().cmpn(0)===0,this.threeA=this.a.fromRed().sub(this.p).cmpn(-3)===0,this.endo=this._getEndomorphism(d),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}function h(d,m,b,p){i.BasePoint.call(this,d,"affine"),m===null&&b===null?(this.x=null,this.y=null,this.inf=!0):(this.x=new s(m,16),this.y=new s(b,16),p&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function u(d,m,b,p){i.BasePoint.call(this,d,"jacobian"),m===null&&b===null&&p===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new s(0)):(this.x=new s(m,16),this.y=new s(b,16),this.z=new s(p,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}l(o,i),a.exports=o,o.prototype._getEndomorphism=function(d){if(this.zeroA&&this.g&&this.n&&this.p.modn(3)===1){var m,b;if(d.beta)m=new s(d.beta,16).toRed(this.red);else{var p=this._getEndoRoots(this.p);m=(m=p[0].cmp(p[1])<0?p[0]:p[1]).toRed(this.red)}if(d.lambda)b=new s(d.lambda,16);else{var v=this._getEndoRoots(this.n);this.g.mul(v[0]).x.cmp(this.g.x.redMul(m))===0?b=v[0]:(b=v[1],n(this.g.mul(b).x.cmp(this.g.x.redMul(m))===0))}return{beta:m,lambda:b,basis:d.basis?d.basis.map(function(g){return{a:new s(g.a,16),b:new s(g.b,16)}}):this._getEndoBasis(b)}}},o.prototype._getEndoRoots=function(d){var m=d===this.p?this.red:s.mont(d),b=new s(2).toRed(m).redInvm(),p=b.redNeg(),v=new s(3).toRed(m).redNeg().redSqrt().redMul(b);return[p.redAdd(v).fromRed(),p.redSub(v).fromRed()]},o.prototype._getEndoBasis=function(d){for(var m,b,p,v,g,x,C,T,R,B=this.n.ushrn(Math.floor(this.n.bitLength()/2)),I=d,F=this.n.clone(),L=new s(1),V=new s(0),z=new s(0),E=new s(1),P=0;I.cmpn(0)!==0;){var k=F.div(I);T=F.sub(k.mul(I)),R=z.sub(k.mul(L));var y=E.sub(k.mul(V));if(!p&&T.cmp(B)<0)m=C.neg(),b=L,p=T.neg(),v=R;else if(p&&++P==2)break;C=T,F=I,I=T,z=L,L=R,E=V,V=y}g=T.neg(),x=R;var w=p.sqr().add(v.sqr());return g.sqr().add(x.sqr()).cmp(w)>=0&&(g=m,x=b),p.negative&&(p=p.neg(),v=v.neg()),g.negative&&(g=g.neg(),x=x.neg()),[{a:p,b:v},{a:g,b:x}]},o.prototype._endoSplit=function(d){var m=this.endo.basis,b=m[0],p=m[1],v=p.b.mul(d).divRound(this.n),g=b.b.neg().mul(d).divRound(this.n),x=v.mul(b.a),C=g.mul(p.a),T=v.mul(b.b),R=g.mul(p.b);return{k1:d.sub(x).sub(C),k2:T.add(R).neg()}},o.prototype.pointFromX=function(d,m){(d=new s(d,16)).red||(d=d.toRed(this.red));var b=d.redSqr().redMul(d).redIAdd(d.redMul(this.a)).redIAdd(this.b),p=b.redSqrt();if(p.redSqr().redSub(b).cmp(this.zero)!==0)throw new Error("invalid point");var v=p.fromRed().isOdd();return(m&&!v||!m&&v)&&(p=p.redNeg()),this.point(d,p)},o.prototype.validate=function(d){if(d.inf)return!0;var m=d.x,b=d.y,p=this.a.redMul(m),v=m.redSqr().redMul(m).redIAdd(p).redIAdd(this.b);return b.redSqr().redISub(v).cmpn(0)===0},o.prototype._endoWnafMulAdd=function(d,m,b){for(var p=this._endoWnafT1,v=this._endoWnafT2,g=0;g<d.length;g++){var x=this._endoSplit(m[g]),C=d[g],T=C._getBeta();x.k1.negative&&(x.k1.ineg(),C=C.neg(!0)),x.k2.negative&&(x.k2.ineg(),T=T.neg(!0)),p[2*g]=C,p[2*g+1]=T,v[2*g]=x.k1,v[2*g+1]=x.k2}for(var R=this._wnafMulAdd(1,p,v,2*g,b),B=0;B<2*g;B++)p[B]=null,v[B]=null;return R},l(h,i.BasePoint),o.prototype.point=function(d,m,b){return new h(this,d,m,b)},o.prototype.pointFromJSON=function(d,m){return h.fromJSON(this,d,m)},h.prototype._getBeta=function(){if(this.curve.endo){var d=this.precomputed;if(d&&d.beta)return d.beta;var m=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(d){var b=this.curve,p=function(v){return b.point(v.x.redMul(b.endo.beta),v.y)};d.beta=m,m.precomputed={beta:null,naf:d.naf&&{wnd:d.naf.wnd,points:d.naf.points.map(p)},doubles:d.doubles&&{step:d.doubles.step,points:d.doubles.points.map(p)}}}return m}},h.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},h.fromJSON=function(d,m,b){typeof m=="string"&&(m=JSON.parse(m));var p=d.point(m[0],m[1],b);if(!m[2])return p;function v(x){return d.point(x[0],x[1],b)}var g=m[2];return p.precomputed={beta:null,doubles:g.doubles&&{step:g.doubles.step,points:[p].concat(g.doubles.points.map(v))},naf:g.naf&&{wnd:g.naf.wnd,points:[p].concat(g.naf.points.map(v))}},p},h.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},h.prototype.isInfinity=function(){return this.inf},h.prototype.add=function(d){if(this.inf)return d;if(d.inf)return this;if(this.eq(d))return this.dbl();if(this.neg().eq(d))return this.curve.point(null,null);if(this.x.cmp(d.x)===0)return this.curve.point(null,null);var m=this.y.redSub(d.y);m.cmpn(0)!==0&&(m=m.redMul(this.x.redSub(d.x).redInvm()));var b=m.redSqr().redISub(this.x).redISub(d.x),p=m.redMul(this.x.redSub(b)).redISub(this.y);return this.curve.point(b,p)},h.prototype.dbl=function(){if(this.inf)return this;var d=this.y.redAdd(this.y);if(d.cmpn(0)===0)return this.curve.point(null,null);var m=this.curve.a,b=this.x.redSqr(),p=d.redInvm(),v=b.redAdd(b).redIAdd(b).redIAdd(m).redMul(p),g=v.redSqr().redISub(this.x.redAdd(this.x)),x=v.redMul(this.x.redSub(g)).redISub(this.y);return this.curve.point(g,x)},h.prototype.getX=function(){return this.x.fromRed()},h.prototype.getY=function(){return this.y.fromRed()},h.prototype.mul=function(d){return d=new s(d,16),this.isInfinity()?this:this._hasDoubles(d)?this.curve._fixedNafMul(this,d):this.curve.endo?this.curve._endoWnafMulAdd([this],[d]):this.curve._wnafMul(this,d)},h.prototype.mulAdd=function(d,m,b){var p=[this,m],v=[d,b];return this.curve.endo?this.curve._endoWnafMulAdd(p,v):this.curve._wnafMulAdd(1,p,v,2)},h.prototype.jmulAdd=function(d,m,b){var p=[this,m],v=[d,b];return this.curve.endo?this.curve._endoWnafMulAdd(p,v,!0):this.curve._wnafMulAdd(1,p,v,2,!0)},h.prototype.eq=function(d){return this===d||this.inf===d.inf&&(this.inf||this.x.cmp(d.x)===0&&this.y.cmp(d.y)===0)},h.prototype.neg=function(d){if(this.inf)return this;var m=this.curve.point(this.x,this.y.redNeg());if(d&&this.precomputed){var b=this.precomputed,p=function(v){return v.neg()};m.precomputed={naf:b.naf&&{wnd:b.naf.wnd,points:b.naf.points.map(p)},doubles:b.doubles&&{step:b.doubles.step,points:b.doubles.points.map(p)}}}return m},h.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},l(u,i.BasePoint),o.prototype.jpoint=function(d,m,b){return new u(this,d,m,b)},u.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var d=this.z.redInvm(),m=d.redSqr(),b=this.x.redMul(m),p=this.y.redMul(m).redMul(d);return this.curve.point(b,p)},u.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},u.prototype.add=function(d){if(this.isInfinity())return d;if(d.isInfinity())return this;var m=d.z.redSqr(),b=this.z.redSqr(),p=this.x.redMul(m),v=d.x.redMul(b),g=this.y.redMul(m.redMul(d.z)),x=d.y.redMul(b.redMul(this.z)),C=p.redSub(v),T=g.redSub(x);if(C.cmpn(0)===0)return T.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var R=C.redSqr(),B=R.redMul(C),I=p.redMul(R),F=T.redSqr().redIAdd(B).redISub(I).redISub(I),L=T.redMul(I.redISub(F)).redISub(g.redMul(B)),V=this.z.redMul(d.z).redMul(C);return this.curve.jpoint(F,L,V)},u.prototype.mixedAdd=function(d){if(this.isInfinity())return d.toJ();if(d.isInfinity())return this;var m=this.z.redSqr(),b=this.x,p=d.x.redMul(m),v=this.y,g=d.y.redMul(m).redMul(this.z),x=b.redSub(p),C=v.redSub(g);if(x.cmpn(0)===0)return C.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var T=x.redSqr(),R=T.redMul(x),B=b.redMul(T),I=C.redSqr().redIAdd(R).redISub(B).redISub(B),F=C.redMul(B.redISub(I)).redISub(v.redMul(R)),L=this.z.redMul(x);return this.curve.jpoint(I,F,L)},u.prototype.dblp=function(d){if(d===0)return this;if(this.isInfinity())return this;if(!d)return this.dbl();var m;if(this.curve.zeroA||this.curve.threeA){var b=this;for(m=0;m<d;m++)b=b.dbl();return b}var p=this.curve.a,v=this.curve.tinv,g=this.x,x=this.y,C=this.z,T=C.redSqr().redSqr(),R=x.redAdd(x);for(m=0;m<d;m++){var B=g.redSqr(),I=R.redSqr(),F=I.redSqr(),L=B.redAdd(B).redIAdd(B).redIAdd(p.redMul(T)),V=g.redMul(I),z=L.redSqr().redISub(V.redAdd(V)),E=V.redISub(z),P=L.redMul(E);P=P.redIAdd(P).redISub(F);var k=R.redMul(C);m+1<d&&(T=T.redMul(F)),g=z,C=k,R=P}return this.curve.jpoint(g,R.redMul(v),C)},u.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},u.prototype._zeroDbl=function(){var d,m,b;if(this.zOne){var p=this.x.redSqr(),v=this.y.redSqr(),g=v.redSqr(),x=this.x.redAdd(v).redSqr().redISub(p).redISub(g);x=x.redIAdd(x);var C=p.redAdd(p).redIAdd(p),T=C.redSqr().redISub(x).redISub(x),R=g.redIAdd(g);R=(R=R.redIAdd(R)).redIAdd(R),d=T,m=C.redMul(x.redISub(T)).redISub(R),b=this.y.redAdd(this.y)}else{var B=this.x.redSqr(),I=this.y.redSqr(),F=I.redSqr(),L=this.x.redAdd(I).redSqr().redISub(B).redISub(F);L=L.redIAdd(L);var V=B.redAdd(B).redIAdd(B),z=V.redSqr(),E=F.redIAdd(F);E=(E=E.redIAdd(E)).redIAdd(E),d=z.redISub(L).redISub(L),m=V.redMul(L.redISub(d)).redISub(E),b=(b=this.y.redMul(this.z)).redIAdd(b)}return this.curve.jpoint(d,m,b)},u.prototype._threeDbl=function(){var d,m,b;if(this.zOne){var p=this.x.redSqr(),v=this.y.redSqr(),g=v.redSqr(),x=this.x.redAdd(v).redSqr().redISub(p).redISub(g);x=x.redIAdd(x);var C=p.redAdd(p).redIAdd(p).redIAdd(this.curve.a),T=C.redSqr().redISub(x).redISub(x);d=T;var R=g.redIAdd(g);R=(R=R.redIAdd(R)).redIAdd(R),m=C.redMul(x.redISub(T)).redISub(R),b=this.y.redAdd(this.y)}else{var B=this.z.redSqr(),I=this.y.redSqr(),F=this.x.redMul(I),L=this.x.redSub(B).redMul(this.x.redAdd(B));L=L.redAdd(L).redIAdd(L);var V=F.redIAdd(F),z=(V=V.redIAdd(V)).redAdd(V);d=L.redSqr().redISub(z),b=this.y.redAdd(this.z).redSqr().redISub(I).redISub(B);var E=I.redSqr();E=(E=(E=E.redIAdd(E)).redIAdd(E)).redIAdd(E),m=L.redMul(V.redISub(d)).redISub(E)}return this.curve.jpoint(d,m,b)},u.prototype._dbl=function(){var d=this.curve.a,m=this.x,b=this.y,p=this.z,v=p.redSqr().redSqr(),g=m.redSqr(),x=b.redSqr(),C=g.redAdd(g).redIAdd(g).redIAdd(d.redMul(v)),T=m.redAdd(m),R=(T=T.redIAdd(T)).redMul(x),B=C.redSqr().redISub(R.redAdd(R)),I=R.redISub(B),F=x.redSqr();F=(F=(F=F.redIAdd(F)).redIAdd(F)).redIAdd(F);var L=C.redMul(I).redISub(F),V=b.redAdd(b).redMul(p);return this.curve.jpoint(B,L,V)},u.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var d=this.x.redSqr(),m=this.y.redSqr(),b=this.z.redSqr(),p=m.redSqr(),v=d.redAdd(d).redIAdd(d),g=v.redSqr(),x=this.x.redAdd(m).redSqr().redISub(d).redISub(p),C=(x=(x=(x=x.redIAdd(x)).redAdd(x).redIAdd(x)).redISub(g)).redSqr(),T=p.redIAdd(p);T=(T=(T=T.redIAdd(T)).redIAdd(T)).redIAdd(T);var R=v.redIAdd(x).redSqr().redISub(g).redISub(C).redISub(T),B=m.redMul(R);B=(B=B.redIAdd(B)).redIAdd(B);var I=this.x.redMul(C).redISub(B);I=(I=I.redIAdd(I)).redIAdd(I);var F=this.y.redMul(R.redMul(T.redISub(R)).redISub(x.redMul(C)));F=(F=(F=F.redIAdd(F)).redIAdd(F)).redIAdd(F);var L=this.z.redAdd(x).redSqr().redISub(b).redISub(C);return this.curve.jpoint(I,F,L)},u.prototype.mul=function(d,m){return d=new s(d,m),this.curve._wnafMul(this,d)},u.prototype.eq=function(d){if(d.type==="affine")return this.eq(d.toJ());if(this===d)return!0;var m=this.z.redSqr(),b=d.z.redSqr();if(this.x.redMul(b).redISub(d.x.redMul(m)).cmpn(0)!==0)return!1;var p=m.redMul(this.z),v=b.redMul(d.z);return this.y.redMul(v).redISub(d.y.redMul(p)).cmpn(0)===0},u.prototype.eqXToP=function(d){var m=this.z.redSqr(),b=d.toRed(this.curve.red).redMul(m);if(this.x.cmp(b)===0)return!0;for(var p=d.clone(),v=this.curve.redN.redMul(m);;){if(p.iadd(this.curve.n),p.cmp(this.curve.p)>=0)return!1;if(b.redIAdd(v),this.x.cmp(b)===0)return!0}},u.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},u.prototype.isInfinity=function(){return this.z.cmpn(0)===0}},{"../utils":419,"./base":406,"bn.js":420,inherits:440}],411:[function(e,a,f){var c,s=f,l=e("hash.js"),i=e("./curve"),n=e("./utils").assert;function o(u){u.type==="short"?this.curve=new i.short(u):u.type==="edwards"?this.curve=new i.edwards(u):this.curve=new i.mont(u),this.g=this.curve.g,this.n=this.curve.n,this.hash=u.hash,n(this.g.validate(),"Invalid curve"),n(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function h(u,d){Object.defineProperty(s,u,{configurable:!0,enumerable:!0,get:function(){var m=new o(d);return Object.defineProperty(s,u,{configurable:!0,enumerable:!0,value:m}),m}})}s.PresetCurve=o,h("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:l.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),h("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:l.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),h("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:l.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),h("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:l.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),h("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:l.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),h("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:l.sha256,gRed:!1,g:["9"]}),h("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:l.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{c=e("./precomputed/secp256k1")}catch{c=void 0}h("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:l.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",c]})},{"./curve":408,"./precomputed/secp256k1":418,"./utils":419,"hash.js":426}],412:[function(e,a,f){var c=e("bn.js"),s=e("hmac-drbg"),l=e("../utils"),i=e("../curves"),n=e("brorand"),o=l.assert,h=e("./key"),u=e("./signature");function d(m){if(!(this instanceof d))return new d(m);typeof m=="string"&&(o(Object.prototype.hasOwnProperty.call(i,m),"Unknown curve "+m),m=i[m]),m instanceof i.PresetCurve&&(m={curve:m}),this.curve=m.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=m.curve.g,this.g.precompute(m.curve.n.bitLength()+1),this.hash=m.hash||m.curve.hash}a.exports=d,d.prototype.keyPair=function(m){return new h(this,m)},d.prototype.keyFromPrivate=function(m,b){return h.fromPrivate(this,m,b)},d.prototype.keyFromPublic=function(m,b){return h.fromPublic(this,m,b)},d.prototype.genKeyPair=function(m){m||(m={});for(var b=new s({hash:this.hash,pers:m.pers,persEnc:m.persEnc||"utf8",entropy:m.entropy||n(this.hash.hmacStrength),entropyEnc:m.entropy&&m.entropyEnc||"utf8",nonce:this.n.toArray()}),p=this.n.byteLength(),v=this.n.sub(new c(2));;){var g=new c(b.generate(p));if(!(g.cmp(v)>0))return g.iaddn(1),this.keyFromPrivate(g)}},d.prototype._truncateToN=function(m,b){var p=8*m.byteLength()-this.n.bitLength();return p>0&&(m=m.ushrn(p)),!b&&m.cmp(this.n)>=0?m.sub(this.n):m},d.prototype.sign=function(m,b,p,v){typeof p=="object"&&(v=p,p=null),v||(v={}),b=this.keyFromPrivate(b,p),m=this._truncateToN(new c(m,16));for(var g=this.n.byteLength(),x=b.getPrivate().toArray("be",g),C=m.toArray("be",g),T=new s({hash:this.hash,entropy:x,nonce:C,pers:v.pers,persEnc:v.persEnc||"utf8"}),R=this.n.sub(new c(1)),B=0;;B++){var I=v.k?v.k(B):new c(T.generate(this.n.byteLength()));if(!((I=this._truncateToN(I,!0)).cmpn(1)<=0||I.cmp(R)>=0)){var F=this.g.mul(I);if(!F.isInfinity()){var L=F.getX(),V=L.umod(this.n);if(V.cmpn(0)!==0){var z=I.invm(this.n).mul(V.mul(b.getPrivate()).iadd(m));if((z=z.umod(this.n)).cmpn(0)!==0){var E=(F.getY().isOdd()?1:0)|(L.cmp(V)!==0?2:0);return v.canonical&&z.cmp(this.nh)>0&&(z=this.n.sub(z),E^=1),new u({r:V,s:z,recoveryParam:E})}}}}}},d.prototype.verify=function(m,b,p,v){m=this._truncateToN(new c(m,16)),p=this.keyFromPublic(p,v);var g=(b=new u(b,"hex")).r,x=b.s;if(g.cmpn(1)<0||g.cmp(this.n)>=0||x.cmpn(1)<0||x.cmp(this.n)>=0)return!1;var C,T=x.invm(this.n),R=T.mul(m).umod(this.n),B=T.mul(g).umod(this.n);return this.curve._maxwellTrick?!(C=this.g.jmulAdd(R,p.getPublic(),B)).isInfinity()&&C.eqXToP(g):!(C=this.g.mulAdd(R,p.getPublic(),B)).isInfinity()&&C.getX().umod(this.n).cmp(g)===0},d.prototype.recoverPubKey=function(m,b,p,v){o((3&p)===p,"The recovery param is more than two bits"),b=new u(b,v);var g=this.n,x=new c(m),C=b.r,T=b.s,R=1&p,B=p>>1;if(C.cmp(this.curve.p.umod(this.curve.n))>=0&&B)throw new Error("Unable to find sencond key candinate");C=B?this.curve.pointFromX(C.add(this.curve.n),R):this.curve.pointFromX(C,R);var I=b.r.invm(g),F=g.sub(x).mul(I).umod(g),L=T.mul(I).umod(g);return this.g.mulAdd(F,C,L)},d.prototype.getKeyRecoveryParam=function(m,b,p,v){if((b=new u(b,v)).recoveryParam!==null)return b.recoveryParam;for(var g=0;g<4;g++){var x;try{x=this.recoverPubKey(m,b,g)}catch{continue}if(x.eq(p))return g}throw new Error("Unable to find valid recovery factor")}},{"../curves":411,"../utils":419,"./key":413,"./signature":414,"bn.js":420,brorand:187,"hmac-drbg":438}],413:[function(e,a,f){var c=e("bn.js"),s=e("../utils").assert;function l(i,n){this.ec=i,this.priv=null,this.pub=null,n.priv&&this._importPrivate(n.priv,n.privEnc),n.pub&&this._importPublic(n.pub,n.pubEnc)}a.exports=l,l.fromPublic=function(i,n,o){return n instanceof l?n:new l(i,{pub:n,pubEnc:o})},l.fromPrivate=function(i,n,o){return n instanceof l?n:new l(i,{priv:n,privEnc:o})},l.prototype.validate=function(){var i=this.getPublic();return i.isInfinity()?{result:!1,reason:"Invalid public key"}:i.validate()?i.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},l.prototype.getPublic=function(i,n){return typeof i=="string"&&(n=i,i=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),n?this.pub.encode(n,i):this.pub},l.prototype.getPrivate=function(i){return i==="hex"?this.priv.toString(16,2):this.priv},l.prototype._importPrivate=function(i,n){this.priv=new c(i,n||16),this.priv=this.priv.umod(this.ec.curve.n)},l.prototype._importPublic=function(i,n){if(i.x||i.y)return this.ec.curve.type==="mont"?s(i.x,"Need x coordinate"):this.ec.curve.type!=="short"&&this.ec.curve.type!=="edwards"||s(i.x&&i.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(i.x,i.y));this.pub=this.ec.curve.decodePoint(i,n)},l.prototype.derive=function(i){return i.validate()||s(i.validate(),"public point not validated"),i.mul(this.priv).getX()},l.prototype.sign=function(i,n,o){return this.ec.sign(i,this,n,o)},l.prototype.verify=function(i,n){return this.ec.verify(i,n,this)},l.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"}},{"../utils":419,"bn.js":420}],414:[function(e,a,f){var c=e("bn.js"),s=e("../utils"),l=s.assert;function i(d,m){if(d instanceof i)return d;this._importDER(d,m)||(l(d.r&&d.s,"Signature without r or s"),this.r=new c(d.r,16),this.s=new c(d.s,16),d.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=d.recoveryParam)}function n(){this.place=0}function o(d,m){var b=d[m.place++];if(!(128&b))return b;var p=15&b;if(p===0||p>4)return!1;for(var v=0,g=0,x=m.place;g<p;g++,x++)v<<=8,v|=d[x],v>>>=0;return!(v<=127)&&(m.place=x,v)}function h(d){for(var m=0,b=d.length-1;!d[m]&&!(128&d[m+1])&&m<b;)m++;return m===0?d:d.slice(m)}function u(d,m){if(m<128)d.push(m);else{var b=1+(Math.log(m)/Math.LN2>>>3);for(d.push(128|b);--b;)d.push(m>>>(b<<3)&255);d.push(m)}}a.exports=i,i.prototype._importDER=function(d,m){d=s.toArray(d,m);var b=new n;if(d[b.place++]!==48)return!1;var p=o(d,b);if(p===!1||p+b.place!==d.length||d[b.place++]!==2)return!1;var v=o(d,b);if(v===!1)return!1;var g=d.slice(b.place,v+b.place);if(b.place+=v,d[b.place++]!==2)return!1;var x=o(d,b);if(x===!1||d.length!==x+b.place)return!1;var C=d.slice(b.place,x+b.place);if(g[0]===0){if(!(128&g[1]))return!1;g=g.slice(1)}if(C[0]===0){if(!(128&C[1]))return!1;C=C.slice(1)}return this.r=new c(g),this.s=new c(C),this.recoveryParam=null,!0},i.prototype.toDER=function(d){var m=this.r.toArray(),b=this.s.toArray();for(128&m[0]&&(m=[0].concat(m)),128&b[0]&&(b=[0].concat(b)),m=h(m),b=h(b);!(b[0]||128&b[1]);)b=b.slice(1);var p=[2];u(p,m.length),(p=p.concat(m)).push(2),u(p,b.length);var v=p.concat(b),g=[48];return u(g,v.length),g=g.concat(v),s.encode(g,d)}},{"../utils":419,"bn.js":420}],415:[function(e,a,f){var c=e("hash.js"),s=e("../curves"),l=e("../utils"),i=l.assert,n=l.parseBytes,o=e("./key"),h=e("./signature");function u(d){if(i(d==="ed25519","only tested with ed25519 so far"),!(this instanceof u))return new u(d);d=s[d].curve,this.curve=d,this.g=d.g,this.g.precompute(d.n.bitLength()+1),this.pointClass=d.point().constructor,this.encodingLength=Math.ceil(d.n.bitLength()/8),this.hash=c.sha512}a.exports=u,u.prototype.sign=function(d,m){d=n(d);var b=this.keyFromSecret(m),p=this.hashInt(b.messagePrefix(),d),v=this.g.mul(p),g=this.encodePoint(v),x=this.hashInt(g,b.pubBytes(),d).mul(b.priv()),C=p.add(x).umod(this.curve.n);return this.makeSignature({R:v,S:C,Rencoded:g})},u.prototype.verify=function(d,m,b){d=n(d),m=this.makeSignature(m);var p=this.keyFromPublic(b),v=this.hashInt(m.Rencoded(),p.pubBytes(),d),g=this.g.mul(m.S());return m.R().add(p.pub().mul(v)).eq(g)},u.prototype.hashInt=function(){for(var d=this.hash(),m=0;m<arguments.length;m++)d.update(arguments[m]);return l.intFromLE(d.digest()).umod(this.curve.n)},u.prototype.keyFromPublic=function(d){return o.fromPublic(this,d)},u.prototype.keyFromSecret=function(d){return o.fromSecret(this,d)},u.prototype.makeSignature=function(d){return d instanceof h?d:new h(this,d)},u.prototype.encodePoint=function(d){var m=d.getY().toArray("le",this.encodingLength);return m[this.encodingLength-1]|=d.getX().isOdd()?128:0,m},u.prototype.decodePoint=function(d){var m=(d=l.parseBytes(d)).length-1,b=d.slice(0,m).concat(-129&d[m]),p=(128&d[m])!=0,v=l.intFromLE(b);return this.curve.pointFromY(v,p)},u.prototype.encodeInt=function(d){return d.toArray("le",this.encodingLength)},u.prototype.decodeInt=function(d){return l.intFromLE(d)},u.prototype.isPoint=function(d){return d instanceof this.pointClass}},{"../curves":411,"../utils":419,"./key":416,"./signature":417,"hash.js":426}],416:[function(e,a,f){var c=e("../utils"),s=c.assert,l=c.parseBytes,i=c.cachedProperty;function n(o,h){this.eddsa=o,this._secret=l(h.secret),o.isPoint(h.pub)?this._pub=h.pub:this._pubBytes=l(h.pub)}n.fromPublic=function(o,h){return h instanceof n?h:new n(o,{pub:h})},n.fromSecret=function(o,h){return h instanceof n?h:new n(o,{secret:h})},n.prototype.secret=function(){return this._secret},i(n,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())}),i(n,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())}),i(n,"privBytes",function(){var o=this.eddsa,h=this.hash(),u=o.encodingLength-1,d=h.slice(0,o.encodingLength);return d[0]&=248,d[u]&=127,d[u]|=64,d}),i(n,"priv",function(){return this.eddsa.decodeInt(this.privBytes())}),i(n,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()}),i(n,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)}),n.prototype.sign=function(o){return s(this._secret,"KeyPair can only verify"),this.eddsa.sign(o,this)},n.prototype.verify=function(o,h){return this.eddsa.verify(o,h,this)},n.prototype.getSecret=function(o){return s(this._secret,"KeyPair is public only"),c.encode(this.secret(),o)},n.prototype.getPublic=function(o){return c.encode(this.pubBytes(),o)},a.exports=n},{"../utils":419}],417:[function(e,a,f){var c=e("bn.js"),s=e("../utils"),l=s.assert,i=s.cachedProperty,n=s.parseBytes;function o(h,u){this.eddsa=h,typeof u!="object"&&(u=n(u)),Array.isArray(u)&&(u={R:u.slice(0,h.encodingLength),S:u.slice(h.encodingLength)}),l(u.R&&u.S,"Signature without R or S"),h.isPoint(u.R)&&(this._R=u.R),u.S instanceof c&&(this._S=u.S),this._Rencoded=Array.isArray(u.R)?u.R:u.Rencoded,this._Sencoded=Array.isArray(u.S)?u.S:u.Sencoded}i(o,"S",function(){return this.eddsa.decodeInt(this.Sencoded())}),i(o,"R",function(){return this.eddsa.decodePoint(this.Rencoded())}),i(o,"Rencoded",function(){return this.eddsa.encodePoint(this.R())}),i(o,"Sencoded",function(){return this.eddsa.encodeInt(this.S())}),o.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},o.prototype.toHex=function(){return s.encode(this.toBytes(),"hex").toUpperCase()},a.exports=o},{"../utils":419,"bn.js":420}],418:[function(e,a,f){a.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}},{}],419:[function(e,a,f){var c=f,s=e("bn.js"),l=e("minimalistic-assert"),i=e("minimalistic-crypto-utils");c.assert=l,c.toArray=i.toArray,c.zero2=i.zero2,c.toHex=i.toHex,c.encode=i.encode,c.getNAF=function(n,o,h){var u=new Array(Math.max(n.bitLength(),h)+1);u.fill(0);for(var d=1<<o+1,m=n.clone(),b=0;b<u.length;b++){var p,v=m.andln(d-1);m.isOdd()?(p=v>(d>>1)-1?(d>>1)-v:v,m.isubn(p)):p=0,u[b]=p,m.iushrn(1)}return u},c.getJSF=function(n,o){var h=[[],[]];n=n.clone(),o=o.clone();for(var u,d=0,m=0;n.cmpn(-d)>0||o.cmpn(-m)>0;){var b,p,v=n.andln(3)+d&3,g=o.andln(3)+m&3;v===3&&(v=-1),g===3&&(g=-1),b=(1&v)==0?0:(u=n.andln(7)+d&7)!==3&&u!==5||g!==2?v:-v,h[0].push(b),p=(1&g)==0?0:(u=o.andln(7)+m&7)!==3&&u!==5||v!==2?g:-g,h[1].push(p),2*d===b+1&&(d=1-d),2*m===p+1&&(m=1-m),n.iushrn(1),o.iushrn(1)}return h},c.cachedProperty=function(n,o,h){var u="_"+o;n.prototype[o]=function(){return this[u]!==void 0?this[u]:this[u]=h.call(this)}},c.parseBytes=function(n){return typeof n=="string"?c.toArray(n,"hex"):n},c.intFromLE=function(n){return new s(n,"hex","le")}},{"bn.js":420,"minimalistic-assert":453,"minimalistic-crypto-utils":454}],420:[function(e,a,f){arguments[4][184][0].apply(f,arguments)},{buffer:188,dup:184}],421:[function(e,a,f){a.exports={name:"elliptic",version:"6.5.4",description:"EC cryptography",main:"lib/elliptic.js",files:["lib"],scripts:{lint:"eslint lib test","lint:fix":"npm run lint -- --fix",unit:"istanbul test _mocha --reporter=spec test/index.js",test:"npm run lint && npm run unit",version:"grunt dist && git add dist/"},repository:{type:"git",url:"git@github.com:indutny/elliptic"},keywords:["EC","Elliptic","curve","Cryptography"],author:"Fedor Indutny <fedor@indutny.com>",license:"MIT",bugs:{url:"https://github.com/indutny/elliptic/issues"},homepage:"https://github.com/indutny/elliptic",devDependencies:{brfs:"^2.0.2",coveralls:"^3.1.0",eslint:"^7.6.0",grunt:"^1.2.1","grunt-browserify":"^5.3.0","grunt-cli":"^1.3.2","grunt-contrib-connect":"^3.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^5.0.0","grunt-mocha-istanbul":"^5.0.2","grunt-saucelabs":"^9.0.1",istanbul:"^0.4.5",mocha:"^8.0.1"},dependencies:{"bn.js":"^4.11.9",brorand:"^1.1.0","hash.js":"^1.0.0","hmac-drbg":"^1.0.1",inherits:"^2.0.4","minimalistic-assert":"^1.0.1","minimalistic-crypto-utils":"^1.0.1"}}},{}],422:[function(e,a,f){var c=Object.create||function(I){var F=function(){};return F.prototype=I,new F},s=Object.keys||function(I){var F=[];for(var L in I)Object.prototype.hasOwnProperty.call(I,L)&&F.push(L);return L},l=Function.prototype.bind||function(I){var F=this;return function(){return F.apply(I,arguments)}};function i(){this._events&&Object.prototype.hasOwnProperty.call(this,"_events")||(this._events=c(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0}a.exports=i,i.EventEmitter=i,i.prototype._events=void 0,i.prototype._maxListeners=void 0;var n,o=10;try{var h={};Object.defineProperty&&Object.defineProperty(h,"x",{value:0}),n=h.x===0}catch{n=!1}function u(I){return I._maxListeners===void 0?i.defaultMaxListeners:I._maxListeners}function d(I,F,L){if(F)I.call(L);else for(var V=I.length,z=B(I,V),E=0;E<V;++E)z[E].call(L)}function m(I,F,L,V){if(F)I.call(L,V);else for(var z=I.length,E=B(I,z),P=0;P<z;++P)E[P].call(L,V)}function b(I,F,L,V,z){if(F)I.call(L,V,z);else for(var E=I.length,P=B(I,E),k=0;k<E;++k)P[k].call(L,V,z)}function p(I,F,L,V,z,E){if(F)I.call(L,V,z,E);else for(var P=I.length,k=B(I,P),y=0;y<P;++y)k[y].call(L,V,z,E)}function v(I,F,L,V){if(F)I.apply(L,V);else for(var z=I.length,E=B(I,z),P=0;P<z;++P)E[P].apply(L,V)}function g(I,F,L,V){var z,E,P;if(typeof L!="function")throw new TypeError('"listener" argument must be a function');if((E=I._events)?(E.newListener&&(I.emit("newListener",F,L.listener?L.listener:L),E=I._events),P=E[F]):(E=I._events=c(null),I._eventsCount=0),P){if(typeof P=="function"?P=E[F]=V?[L,P]:[P,L]:V?P.unshift(L):P.push(L),!P.warned&&(z=u(I))&&z>0&&P.length>z){P.warned=!0;var k=new Error("Possible EventEmitter memory leak detected. "+P.length+' "'+String(F)+'" listeners added. Use emitter.setMaxListeners() to increase limit.');k.name="MaxListenersExceededWarning",k.emitter=I,k.type=F,k.count=P.length,typeof console=="object"&&console.warn&&console.warn("%s: %s",k.name,k.message)}}else P=E[F]=L,++I._eventsCount;return I}function x(){if(!this.fired)switch(this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length){case 0:return this.listener.call(this.target);case 1:return this.listener.call(this.target,arguments[0]);case 2:return this.listener.call(this.target,arguments[0],arguments[1]);case 3:return this.listener.call(this.target,arguments[0],arguments[1],arguments[2]);default:for(var I=new Array(arguments.length),F=0;F<I.length;++F)I[F]=arguments[F];this.listener.apply(this.target,I)}}function C(I,F,L){var V={fired:!1,wrapFn:void 0,target:I,type:F,listener:L},z=l.call(x,V);return z.listener=L,V.wrapFn=z,z}function T(I,F,L){var V=I._events;if(!V)return[];var z=V[F];return z?typeof z=="function"?L?[z.listener||z]:[z]:L?function(E){for(var P=new Array(E.length),k=0;k<P.length;++k)P[k]=E[k].listener||E[k];return P}(z):B(z,z.length):[]}function R(I){var F=this._events;if(F){var L=F[I];if(typeof L=="function")return 1;if(L)return L.length}return 0}function B(I,F){for(var L=new Array(F),V=0;V<F;++V)L[V]=I[V];return L}n?Object.defineProperty(i,"defaultMaxListeners",{enumerable:!0,get:function(){return o},set:function(I){if(typeof I!="number"||I<0||I!=I)throw new TypeError('"defaultMaxListeners" must be a positive number');o=I}}):i.defaultMaxListeners=o,i.prototype.setMaxListeners=function(I){if(typeof I!="number"||I<0||isNaN(I))throw new TypeError('"n" argument must be a positive number');return this._maxListeners=I,this},i.prototype.getMaxListeners=function(){return u(this)},i.prototype.emit=function(I){var F,L,V,z,E,P,k=I==="error";if(P=this._events)k=k&&P.error==null;else if(!k)return!1;if(k){if(arguments.length>1&&(F=arguments[1]),F instanceof Error)throw F;var y=new Error('Unhandled "error" event. ('+F+")");throw y.context=F,y}if(!(L=P[I]))return!1;var w=typeof L=="function";switch(V=arguments.length){case 1:d(L,w,this);break;case 2:m(L,w,this,arguments[1]);break;case 3:b(L,w,this,arguments[1],arguments[2]);break;case 4:p(L,w,this,arguments[1],arguments[2],arguments[3]);break;default:for(z=new Array(V-1),E=1;E<V;E++)z[E-1]=arguments[E];v(L,w,this,z)}return!0},i.prototype.addListener=function(I,F){return g(this,I,F,!1)},i.prototype.on=i.prototype.addListener,i.prototype.prependListener=function(I,F){return g(this,I,F,!0)},i.prototype.once=function(I,F){if(typeof F!="function")throw new TypeError('"listener" argument must be a function');return this.on(I,C(this,I,F)),this},i.prototype.prependOnceListener=function(I,F){if(typeof F!="function")throw new TypeError('"listener" argument must be a function');return this.prependListener(I,C(this,I,F)),this},i.prototype.removeListener=function(I,F){var L,V,z,E,P;if(typeof F!="function")throw new TypeError('"listener" argument must be a function');if(!(V=this._events))return this;if(!(L=V[I]))return this;if(L===F||L.listener===F)--this._eventsCount==0?this._events=c(null):(delete V[I],V.removeListener&&this.emit("removeListener",I,L.listener||F));else if(typeof L!="function"){for(z=-1,E=L.length-1;E>=0;E--)if(L[E]===F||L[E].listener===F){P=L[E].listener,z=E;break}if(z<0)return this;z===0?L.shift():function(k,y){for(var w=y,_=w+1,S=k.length;_<S;w+=1,_+=1)k[w]=k[_];k.pop()}(L,z),L.length===1&&(V[I]=L[0]),V.removeListener&&this.emit("removeListener",I,P||F)}return this},i.prototype.removeAllListeners=function(I){var F,L,V;if(!(L=this._events))return this;if(!L.removeListener)return arguments.length===0?(this._events=c(null),this._eventsCount=0):L[I]&&(--this._eventsCount==0?this._events=c(null):delete L[I]),this;if(arguments.length===0){var z,E=s(L);for(V=0;V<E.length;++V)(z=E[V])!=="removeListener"&&this.removeAllListeners(z);return this.removeAllListeners("removeListener"),this._events=c(null),this._eventsCount=0,this}if(typeof(F=L[I])=="function")this.removeListener(I,F);else if(F)for(V=F.length-1;V>=0;V--)this.removeListener(I,F[V]);return this},i.prototype.listeners=function(I){return T(this,I,!0)},i.prototype.rawListeners=function(I){return T(this,I,!1)},i.listenerCount=function(I,F){return typeof I.listenerCount=="function"?I.listenerCount(F):R.call(I,F)},i.prototype.listenerCount=R,i.prototype.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]}},{}],423:[function(e,a,f){var c=e("safe-buffer").Buffer,s=e("md5.js");a.exports=function(l,i,n,o){if(c.isBuffer(l)||(l=c.from(l,"binary")),i&&(c.isBuffer(i)||(i=c.from(i,"binary")),i.length!==8))throw new RangeError("salt should be Buffer with 8 byte length");for(var h=n/8,u=c.alloc(h),d=c.alloc(o||0),m=c.alloc(0);h>0||o>0;){var b=new s;b.update(m),b.update(l),i&&b.update(i),m=b.digest();var p=0;if(h>0){var v=u.length-h;p=Math.min(h,m.length),m.copy(u,v,0,p),h-=p}if(p<m.length&&o>0){var g=d.length-o,x=Math.min(o,m.length-p);m.copy(d,g,p,p+x),o-=x}}return m.fill(0),{key:u,iv:d}}},{"md5.js":450,"safe-buffer":494}],424:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.CsvParserStream=f.ParserOptions=f.parseFile=f.parseStream=f.parseString=f.parse=f.FormatterOptions=f.CsvFormatterStream=f.writeToPath=f.writeToString=f.writeToBuffer=f.writeToStream=f.write=f.format=void 0;var c=e("@fast-csv/format");Object.defineProperty(f,"format",{enumerable:!0,get:function(){return c.format}}),Object.defineProperty(f,"write",{enumerable:!0,get:function(){return c.write}}),Object.defineProperty(f,"writeToStream",{enumerable:!0,get:function(){return c.writeToStream}}),Object.defineProperty(f,"writeToBuffer",{enumerable:!0,get:function(){return c.writeToBuffer}}),Object.defineProperty(f,"writeToString",{enumerable:!0,get:function(){return c.writeToString}}),Object.defineProperty(f,"writeToPath",{enumerable:!0,get:function(){return c.writeToPath}}),Object.defineProperty(f,"CsvFormatterStream",{enumerable:!0,get:function(){return c.CsvFormatterStream}}),Object.defineProperty(f,"FormatterOptions",{enumerable:!0,get:function(){return c.FormatterOptions}});var s=e("@fast-csv/parse");Object.defineProperty(f,"parse",{enumerable:!0,get:function(){return s.parse}}),Object.defineProperty(f,"parseString",{enumerable:!0,get:function(){return s.parseString}}),Object.defineProperty(f,"parseStream",{enumerable:!0,get:function(){return s.parseStream}}),Object.defineProperty(f,"parseFile",{enumerable:!0,get:function(){return s.parseFile}}),Object.defineProperty(f,"ParserOptions",{enumerable:!0,get:function(){return s.ParserOptions}}),Object.defineProperty(f,"CsvParserStream",{enumerable:!0,get:function(){return s.CsvParserStream}})},{"@fast-csv/format":151,"@fast-csv/parse":155}],425:[function(e,a,f){var c=e("safe-buffer").Buffer,s=e("readable-stream").Transform;function l(i){s.call(this),this._block=c.allocUnsafe(i),this._blockSize=i,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}e("inherits")(l,s),l.prototype._transform=function(i,n,o){var h=null;try{this.update(i,n)}catch(u){h=u}o(h)},l.prototype._flush=function(i){var n=null;try{this.push(this.digest())}catch(o){n=o}i(n)},l.prototype.update=function(i,n){if(function(b,p){if(!c.isBuffer(b)&&typeof b!="string")throw new TypeError(p+" must be a string or a buffer")}(i,"Data"),this._finalized)throw new Error("Digest already called");c.isBuffer(i)||(i=c.from(i,n));for(var o=this._block,h=0;this._blockOffset+i.length-h>=this._blockSize;){for(var u=this._blockOffset;u<this._blockSize;)o[u++]=i[h++];this._update(),this._blockOffset=0}for(;h<i.length;)o[this._blockOffset++]=i[h++];for(var d=0,m=8*i.length;m>0;++d)this._length[d]+=m,(m=this._length[d]/4294967296|0)>0&&(this._length[d]-=4294967296*m);return this},l.prototype._update=function(){throw new Error("_update is not implemented")},l.prototype.digest=function(i){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var n=this._digest();i!==void 0&&(n=n.toString(i)),this._block.fill(0),this._blockOffset=0;for(var o=0;o<4;++o)this._length[o]=0;return n},l.prototype._digest=function(){throw new Error("_digest is not implemented")},a.exports=l},{inherits:440,"readable-stream":491,"safe-buffer":494}],426:[function(e,a,f){var c=f;c.utils=e("./hash/utils"),c.common=e("./hash/common"),c.sha=e("./hash/sha"),c.ripemd=e("./hash/ripemd"),c.hmac=e("./hash/hmac"),c.sha1=c.sha.sha1,c.sha256=c.sha.sha256,c.sha224=c.sha.sha224,c.sha384=c.sha.sha384,c.sha512=c.sha.sha512,c.ripemd160=c.ripemd.ripemd160},{"./hash/common":427,"./hash/hmac":428,"./hash/ripemd":429,"./hash/sha":430,"./hash/utils":437}],427:[function(e,a,f){var c=e("./utils"),s=e("minimalistic-assert");function l(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}f.BlockHash=l,l.prototype.update=function(i,n){if(i=c.toArray(i,n),this.pending?this.pending=this.pending.concat(i):this.pending=i,this.pendingTotal+=i.length,this.pending.length>=this._delta8){var o=(i=this.pending).length%this._delta8;this.pending=i.slice(i.length-o,i.length),this.pending.length===0&&(this.pending=null),i=c.join32(i,0,i.length-o,this.endian);for(var h=0;h<i.length;h+=this._delta32)this._update(i,h,h+this._delta32)}return this},l.prototype.digest=function(i){return this.update(this._pad()),s(this.pending===null),this._digest(i)},l.prototype._pad=function(){var i=this.pendingTotal,n=this._delta8,o=n-(i+this.padLength)%n,h=new Array(o+this.padLength);h[0]=128;for(var u=1;u<o;u++)h[u]=0;if(i<<=3,this.endian==="big"){for(var d=8;d<this.padLength;d++)h[u++]=0;h[u++]=0,h[u++]=0,h[u++]=0,h[u++]=0,h[u++]=i>>>24&255,h[u++]=i>>>16&255,h[u++]=i>>>8&255,h[u++]=255&i}else for(h[u++]=255&i,h[u++]=i>>>8&255,h[u++]=i>>>16&255,h[u++]=i>>>24&255,h[u++]=0,h[u++]=0,h[u++]=0,h[u++]=0,d=8;d<this.padLength;d++)h[u++]=0;return h}},{"./utils":437,"minimalistic-assert":453}],428:[function(e,a,f){var c=e("./utils"),s=e("minimalistic-assert");function l(i,n,o){if(!(this instanceof l))return new l(i,n,o);this.Hash=i,this.blockSize=i.blockSize/8,this.outSize=i.outSize/8,this.inner=null,this.outer=null,this._init(c.toArray(n,o))}a.exports=l,l.prototype._init=function(i){i.length>this.blockSize&&(i=new this.Hash().update(i).digest()),s(i.length<=this.blockSize);for(var n=i.length;n<this.blockSize;n++)i.push(0);for(n=0;n<i.length;n++)i[n]^=54;for(this.inner=new this.Hash().update(i),n=0;n<i.length;n++)i[n]^=106;this.outer=new this.Hash().update(i)},l.prototype.update=function(i,n){return this.inner.update(i,n),this},l.prototype.digest=function(i){return this.outer.update(this.inner.digest()),this.outer.digest(i)}},{"./utils":437,"minimalistic-assert":453}],429:[function(e,a,f){var c=e("./utils"),s=e("./common"),l=c.rotl32,i=c.sum32,n=c.sum32_3,o=c.sum32_4,h=s.BlockHash;function u(){if(!(this instanceof u))return new u;h.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function d(C,T,R,B){return C<=15?T^R^B:C<=31?T&R|~T&B:C<=47?(T|~R)^B:C<=63?T&B|R&~B:T^(R|~B)}function m(C){return C<=15?0:C<=31?1518500249:C<=47?1859775393:C<=63?2400959708:2840853838}function b(C){return C<=15?1352829926:C<=31?1548603684:C<=47?1836072691:C<=63?2053994217:0}c.inherits(u,h),f.ripemd160=u,u.blockSize=512,u.outSize=160,u.hmacStrength=192,u.padLength=64,u.prototype._update=function(C,T){for(var R=this.h[0],B=this.h[1],I=this.h[2],F=this.h[3],L=this.h[4],V=R,z=B,E=I,P=F,k=L,y=0;y<80;y++){var w=i(l(o(R,d(y,B,I,F),C[p[y]+T],m(y)),g[y]),L);R=L,L=F,F=l(I,10),I=B,B=w,w=i(l(o(V,d(79-y,z,E,P),C[v[y]+T],b(y)),x[y]),k),V=k,k=P,P=l(E,10),E=z,z=w}w=n(this.h[1],I,P),this.h[1]=n(this.h[2],F,k),this.h[2]=n(this.h[3],L,V),this.h[3]=n(this.h[4],R,z),this.h[4]=n(this.h[0],B,E),this.h[0]=w},u.prototype._digest=function(C){return C==="hex"?c.toHex32(this.h,"little"):c.split32(this.h,"little")};var p=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],v=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],g=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],x=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]},{"./common":427,"./utils":437}],430:[function(e,a,f){f.sha1=e("./sha/1"),f.sha224=e("./sha/224"),f.sha256=e("./sha/256"),f.sha384=e("./sha/384"),f.sha512=e("./sha/512")},{"./sha/1":431,"./sha/224":432,"./sha/256":433,"./sha/384":434,"./sha/512":435}],431:[function(e,a,f){var c=e("../utils"),s=e("../common"),l=e("./common"),i=c.rotl32,n=c.sum32,o=c.sum32_5,h=l.ft_1,u=s.BlockHash,d=[1518500249,1859775393,2400959708,3395469782];function m(){if(!(this instanceof m))return new m;u.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}c.inherits(m,u),a.exports=m,m.blockSize=512,m.outSize=160,m.hmacStrength=80,m.padLength=64,m.prototype._update=function(b,p){for(var v=this.W,g=0;g<16;g++)v[g]=b[p+g];for(;g<v.length;g++)v[g]=i(v[g-3]^v[g-8]^v[g-14]^v[g-16],1);var x=this.h[0],C=this.h[1],T=this.h[2],R=this.h[3],B=this.h[4];for(g=0;g<v.length;g++){var I=~~(g/20),F=o(i(x,5),h(I,C,T,R),B,v[g],d[I]);B=R,R=T,T=i(C,30),C=x,x=F}this.h[0]=n(this.h[0],x),this.h[1]=n(this.h[1],C),this.h[2]=n(this.h[2],T),this.h[3]=n(this.h[3],R),this.h[4]=n(this.h[4],B)},m.prototype._digest=function(b){return b==="hex"?c.toHex32(this.h,"big"):c.split32(this.h,"big")}},{"../common":427,"../utils":437,"./common":436}],432:[function(e,a,f){var c=e("../utils"),s=e("./256");function l(){if(!(this instanceof l))return new l;s.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}c.inherits(l,s),a.exports=l,l.blockSize=512,l.outSize=224,l.hmacStrength=192,l.padLength=64,l.prototype._digest=function(i){return i==="hex"?c.toHex32(this.h.slice(0,7),"big"):c.split32(this.h.slice(0,7),"big")}},{"../utils":437,"./256":433}],433:[function(e,a,f){var c=e("../utils"),s=e("../common"),l=e("./common"),i=e("minimalistic-assert"),n=c.sum32,o=c.sum32_4,h=c.sum32_5,u=l.ch32,d=l.maj32,m=l.s0_256,b=l.s1_256,p=l.g0_256,v=l.g1_256,g=s.BlockHash,x=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function C(){if(!(this instanceof C))return new C;g.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=x,this.W=new Array(64)}c.inherits(C,g),a.exports=C,C.blockSize=512,C.outSize=256,C.hmacStrength=192,C.padLength=64,C.prototype._update=function(T,R){for(var B=this.W,I=0;I<16;I++)B[I]=T[R+I];for(;I<B.length;I++)B[I]=o(v(B[I-2]),B[I-7],p(B[I-15]),B[I-16]);var F=this.h[0],L=this.h[1],V=this.h[2],z=this.h[3],E=this.h[4],P=this.h[5],k=this.h[6],y=this.h[7];for(i(this.k.length===B.length),I=0;I<B.length;I++){var w=h(y,b(E),u(E,P,k),this.k[I],B[I]),_=n(m(F),d(F,L,V));y=k,k=P,P=E,E=n(z,w),z=V,V=L,L=F,F=n(w,_)}this.h[0]=n(this.h[0],F),this.h[1]=n(this.h[1],L),this.h[2]=n(this.h[2],V),this.h[3]=n(this.h[3],z),this.h[4]=n(this.h[4],E),this.h[5]=n(this.h[5],P),this.h[6]=n(this.h[6],k),this.h[7]=n(this.h[7],y)},C.prototype._digest=function(T){return T==="hex"?c.toHex32(this.h,"big"):c.split32(this.h,"big")}},{"../common":427,"../utils":437,"./common":436,"minimalistic-assert":453}],434:[function(e,a,f){var c=e("../utils"),s=e("./512");function l(){if(!(this instanceof l))return new l;s.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}c.inherits(l,s),a.exports=l,l.blockSize=1024,l.outSize=384,l.hmacStrength=192,l.padLength=128,l.prototype._digest=function(i){return i==="hex"?c.toHex32(this.h.slice(0,12),"big"):c.split32(this.h.slice(0,12),"big")}},{"../utils":437,"./512":435}],435:[function(e,a,f){var c=e("../utils"),s=e("../common"),l=e("minimalistic-assert"),i=c.rotr64_hi,n=c.rotr64_lo,o=c.shr64_hi,h=c.shr64_lo,u=c.sum64,d=c.sum64_hi,m=c.sum64_lo,b=c.sum64_4_hi,p=c.sum64_4_lo,v=c.sum64_5_hi,g=c.sum64_5_lo,x=s.BlockHash,C=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function T(){if(!(this instanceof T))return new T;x.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=C,this.W=new Array(160)}function R(_,S,A,O,N){var U=_&A^~_&N;return U<0&&(U+=4294967296),U}function B(_,S,A,O,N,U){var H=S&O^~S&U;return H<0&&(H+=4294967296),H}function I(_,S,A,O,N){var U=_&A^_&N^A&N;return U<0&&(U+=4294967296),U}function F(_,S,A,O,N,U){var H=S&O^S&U^O&U;return H<0&&(H+=4294967296),H}function L(_,S){var A=i(_,S,28)^i(S,_,2)^i(S,_,7);return A<0&&(A+=4294967296),A}function V(_,S){var A=n(_,S,28)^n(S,_,2)^n(S,_,7);return A<0&&(A+=4294967296),A}function z(_,S){var A=i(_,S,14)^i(_,S,18)^i(S,_,9);return A<0&&(A+=4294967296),A}function E(_,S){var A=n(_,S,14)^n(_,S,18)^n(S,_,9);return A<0&&(A+=4294967296),A}function P(_,S){var A=i(_,S,1)^i(_,S,8)^o(_,S,7);return A<0&&(A+=4294967296),A}function k(_,S){var A=n(_,S,1)^n(_,S,8)^h(_,S,7);return A<0&&(A+=4294967296),A}function y(_,S){var A=i(_,S,19)^i(S,_,29)^o(_,S,6);return A<0&&(A+=4294967296),A}function w(_,S){var A=n(_,S,19)^n(S,_,29)^h(_,S,6);return A<0&&(A+=4294967296),A}c.inherits(T,x),a.exports=T,T.blockSize=1024,T.outSize=512,T.hmacStrength=192,T.padLength=128,T.prototype._prepareBlock=function(_,S){for(var A=this.W,O=0;O<32;O++)A[O]=_[S+O];for(;O<A.length;O+=2){var N=y(A[O-4],A[O-3]),U=w(A[O-4],A[O-3]),H=A[O-14],Z=A[O-13],D=P(A[O-30],A[O-29]),q=k(A[O-30],A[O-29]),M=A[O-32],j=A[O-31];A[O]=b(N,U,H,Z,D,q,M,j),A[O+1]=p(N,U,H,Z,D,q,M,j)}},T.prototype._update=function(_,S){this._prepareBlock(_,S);var A=this.W,O=this.h[0],N=this.h[1],U=this.h[2],H=this.h[3],Z=this.h[4],D=this.h[5],q=this.h[6],M=this.h[7],j=this.h[8],$=this.h[9],K=this.h[10],J=this.h[11],X=this.h[12],Q=this.h[13],ee=this.h[14],se=this.h[15];l(this.k.length===A.length);for(var Y=0;Y<A.length;Y+=2){var te=ee,ne=se,oe=z(j,$),ae=E(j,$),ce=R(j,$,K,J,X),me=B(j,$,K,J,X,Q),be=this.k[Y],ye=this.k[Y+1],Me=A[Y],Te=A[Y+1],fe=v(te,ne,oe,ae,ce,me,be,ye,Me,Te),ke=g(te,ne,oe,ae,ce,me,be,ye,Me,Te);te=L(O,N),ne=V(O,N),oe=I(O,N,U,H,Z),ae=F(O,N,U,H,Z,D);var Ee=d(te,ne,oe,ae),Ne=m(te,ne,oe,ae);ee=X,se=Q,X=K,Q=J,K=j,J=$,j=d(q,M,fe,ke),$=m(M,M,fe,ke),q=Z,M=D,Z=U,D=H,U=O,H=N,O=d(fe,ke,Ee,Ne),N=m(fe,ke,Ee,Ne)}u(this.h,0,O,N),u(this.h,2,U,H),u(this.h,4,Z,D),u(this.h,6,q,M),u(this.h,8,j,$),u(this.h,10,K,J),u(this.h,12,X,Q),u(this.h,14,ee,se)},T.prototype._digest=function(_){return _==="hex"?c.toHex32(this.h,"big"):c.split32(this.h,"big")}},{"../common":427,"../utils":437,"minimalistic-assert":453}],436:[function(e,a,f){var c=e("../utils").rotr32;function s(n,o,h){return n&o^~n&h}function l(n,o,h){return n&o^n&h^o&h}function i(n,o,h){return n^o^h}f.ft_1=function(n,o,h,u){return n===0?s(o,h,u):n===1||n===3?i(o,h,u):n===2?l(o,h,u):void 0},f.ch32=s,f.maj32=l,f.p32=i,f.s0_256=function(n){return c(n,2)^c(n,13)^c(n,22)},f.s1_256=function(n){return c(n,6)^c(n,11)^c(n,25)},f.g0_256=function(n){return c(n,7)^c(n,18)^n>>>3},f.g1_256=function(n){return c(n,17)^c(n,19)^n>>>10}},{"../utils":437}],437:[function(e,a,f){var c=e("minimalistic-assert"),s=e("inherits");function l(h,u){return(64512&h.charCodeAt(u))==55296&&!(u<0||u+1>=h.length)&&(64512&h.charCodeAt(u+1))==56320}function i(h){return(h>>>24|h>>>8&65280|h<<8&16711680|(255&h)<<24)>>>0}function n(h){return h.length===1?"0"+h:h}function o(h){return h.length===7?"0"+h:h.length===6?"00"+h:h.length===5?"000"+h:h.length===4?"0000"+h:h.length===3?"00000"+h:h.length===2?"000000"+h:h.length===1?"0000000"+h:h}f.inherits=s,f.toArray=function(h,u){if(Array.isArray(h))return h.slice();if(!h)return[];var d=[];if(typeof h=="string")if(u){if(u==="hex")for((h=h.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(h="0"+h),b=0;b<h.length;b+=2)d.push(parseInt(h[b]+h[b+1],16))}else for(var m=0,b=0;b<h.length;b++){var p=h.charCodeAt(b);p<128?d[m++]=p:p<2048?(d[m++]=p>>6|192,d[m++]=63&p|128):l(h,b)?(p=65536+((1023&p)<<10)+(1023&h.charCodeAt(++b)),d[m++]=p>>18|240,d[m++]=p>>12&63|128,d[m++]=p>>6&63|128,d[m++]=63&p|128):(d[m++]=p>>12|224,d[m++]=p>>6&63|128,d[m++]=63&p|128)}else for(b=0;b<h.length;b++)d[b]=0|h[b];return d},f.toHex=function(h){for(var u="",d=0;d<h.length;d++)u+=n(h[d].toString(16));return u},f.htonl=i,f.toHex32=function(h,u){for(var d="",m=0;m<h.length;m++){var b=h[m];u==="little"&&(b=i(b)),d+=o(b.toString(16))}return d},f.zero2=n,f.zero8=o,f.join32=function(h,u,d,m){var b=d-u;c(b%4==0);for(var p=new Array(b/4),v=0,g=u;v<p.length;v++,g+=4){var x;x=m==="big"?h[g]<<24|h[g+1]<<16|h[g+2]<<8|h[g+3]:h[g+3]<<24|h[g+2]<<16|h[g+1]<<8|h[g],p[v]=x>>>0}return p},f.split32=function(h,u){for(var d=new Array(4*h.length),m=0,b=0;m<h.length;m++,b+=4){var p=h[m];u==="big"?(d[b]=p>>>24,d[b+1]=p>>>16&255,d[b+2]=p>>>8&255,d[b+3]=255&p):(d[b+3]=p>>>24,d[b+2]=p>>>16&255,d[b+1]=p>>>8&255,d[b]=255&p)}return d},f.rotr32=function(h,u){return h>>>u|h<<32-u},f.rotl32=function(h,u){return h<<u|h>>>32-u},f.sum32=function(h,u){return h+u>>>0},f.sum32_3=function(h,u,d){return h+u+d>>>0},f.sum32_4=function(h,u,d,m){return h+u+d+m>>>0},f.sum32_5=function(h,u,d,m,b){return h+u+d+m+b>>>0},f.sum64=function(h,u,d,m){var b=h[u],p=m+h[u+1]>>>0,v=(p<m?1:0)+d+b;h[u]=v>>>0,h[u+1]=p},f.sum64_hi=function(h,u,d,m){return(u+m>>>0<u?1:0)+h+d>>>0},f.sum64_lo=function(h,u,d,m){return u+m>>>0},f.sum64_4_hi=function(h,u,d,m,b,p,v,g){var x=0,C=u;return x+=(C=C+m>>>0)<u?1:0,x+=(C=C+p>>>0)<p?1:0,h+d+b+v+(x+=(C=C+g>>>0)<g?1:0)>>>0},f.sum64_4_lo=function(h,u,d,m,b,p,v,g){return u+m+p+g>>>0},f.sum64_5_hi=function(h,u,d,m,b,p,v,g,x,C){var T=0,R=u;return T+=(R=R+m>>>0)<u?1:0,T+=(R=R+p>>>0)<p?1:0,T+=(R=R+g>>>0)<g?1:0,h+d+b+v+x+(T+=(R=R+C>>>0)<C?1:0)>>>0},f.sum64_5_lo=function(h,u,d,m,b,p,v,g,x,C){return u+m+p+g+C>>>0},f.rotr64_hi=function(h,u,d){return(u<<32-d|h>>>d)>>>0},f.rotr64_lo=function(h,u,d){return(h<<32-d|u>>>d)>>>0},f.shr64_hi=function(h,u,d){return h>>>d},f.shr64_lo=function(h,u,d){return(h<<32-d|u>>>d)>>>0}},{inherits:440,"minimalistic-assert":453}],438:[function(e,a,f){var c=e("hash.js"),s=e("minimalistic-crypto-utils"),l=e("minimalistic-assert");function i(n){if(!(this instanceof i))return new i(n);this.hash=n.hash,this.predResist=!!n.predResist,this.outLen=this.hash.outSize,this.minEntropy=n.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var o=s.toArray(n.entropy,n.entropyEnc||"hex"),h=s.toArray(n.nonce,n.nonceEnc||"hex"),u=s.toArray(n.pers,n.persEnc||"hex");l(o.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(o,h,u)}a.exports=i,i.prototype._init=function(n,o,h){var u=n.concat(o).concat(h);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var d=0;d<this.V.length;d++)this.K[d]=0,this.V[d]=1;this._update(u),this._reseed=1,this.reseedInterval=281474976710656},i.prototype._hmac=function(){return new c.hmac(this.hash,this.K)},i.prototype._update=function(n){var o=this._hmac().update(this.V).update([0]);n&&(o=o.update(n)),this.K=o.digest(),this.V=this._hmac().update(this.V).digest(),n&&(this.K=this._hmac().update(this.V).update([1]).update(n).digest(),this.V=this._hmac().update(this.V).digest())},i.prototype.reseed=function(n,o,h,u){typeof o!="string"&&(u=h,h=o,o=null),n=s.toArray(n,o),h=s.toArray(h,u),l(n.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(n.concat(h||[])),this._reseed=1},i.prototype.generate=function(n,o,h,u){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof o!="string"&&(u=h,h=o,o=null),h&&(h=s.toArray(h,u||"hex"),this._update(h));for(var d=[];d.length<n;)this.V=this._hmac().update(this.V).digest(),d=d.concat(this.V);var m=d.slice(0,n);return this._update(h),this._reseed++,s.encode(m,o)}},{"hash.js":426,"minimalistic-assert":453,"minimalistic-crypto-utils":454}],439:[function(e,a,f){/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */f.read=function(c,s,l,i,n){var o,h,u=8*n-i-1,d=(1<<u)-1,m=d>>1,b=-7,p=l?n-1:0,v=l?-1:1,g=c[s+p];for(p+=v,o=g&(1<<-b)-1,g>>=-b,b+=u;b>0;o=256*o+c[s+p],p+=v,b-=8);for(h=o&(1<<-b)-1,o>>=-b,b+=i;b>0;h=256*h+c[s+p],p+=v,b-=8);if(o===0)o=1-m;else{if(o===d)return h?NaN:1/0*(g?-1:1);h+=Math.pow(2,i),o-=m}return(g?-1:1)*h*Math.pow(2,o-i)},f.write=function(c,s,l,i,n,o){var h,u,d,m=8*o-n-1,b=(1<<m)-1,p=b>>1,v=n===23?Math.pow(2,-24)-Math.pow(2,-77):0,g=i?0:o-1,x=i?1:-1,C=s<0||s===0&&1/s<0?1:0;for(s=Math.abs(s),isNaN(s)||s===1/0?(u=isNaN(s)?1:0,h=b):(h=Math.floor(Math.log(s)/Math.LN2),s*(d=Math.pow(2,-h))<1&&(h--,d*=2),(s+=h+p>=1?v/d:v*Math.pow(2,1-p))*d>=2&&(h++,d/=2),h+p>=b?(u=0,h=b):h+p>=1?(u=(s*d-1)*Math.pow(2,n),h+=p):(u=s*Math.pow(2,p-1)*Math.pow(2,n),h=0));n>=8;c[l+g]=255&u,g+=x,u/=256,n-=8);for(h=h<<n|u,m+=n;m>0;c[l+g]=255&h,g+=x,h/=256,m-=8);c[l+g-x]|=128*C}},{}],440:[function(e,a,f){typeof Object.create=="function"?a.exports=function(c,s){s&&(c.super_=s,c.prototype=Object.create(s.prototype,{constructor:{value:c,enumerable:!1,writable:!0,configurable:!0}}))}:a.exports=function(c,s){if(s){c.super_=s;var l=function(){};l.prototype=s.prototype,c.prototype=new l,c.prototype.constructor=c}}},{}],441:[function(e,a,f){(function(c,s,l,i,n,o,h,u){(function(){/*! JSZip v3.10.1 - A JavaScript class for generating and reading zip files <http://stuartk.com/jszip> (c) 2009-2016 Stuart Knightley <stuart [at] stuartk.com> Dual licenced under the MIT license or GPLv3. See https://raw.github.com/Stuk/jszip/main/LICENSE.markdown. JSZip uses the library pako released under the MIT license : https://github.com/nodeca/pako/blob/main/LICENSE */(function(d){typeof f=="object"&&a!==void 0?a.exports=d():(typeof window<"u"?window:s!==void 0?s:typeof self<"u"?self:this).JSZip=d()})(function(){return function d(m,b,p){function v(C,T){if(!b[C]){if(!m[C]){var R=typeof e=="function"&&e;if(!T&&R)return R(C,!0);if(g)return g(C,!0);var B=new Error("Cannot find module '"+C+"'");throw B.code="MODULE_NOT_FOUND",B}var I=b[C]={exports:{}};m[C][0].call(I.exports,function(F){return v(m[C][1][F]||F)},I,I.exports,d,m,b,p)}return b[C].exports}for(var g=typeof e=="function"&&e,x=0;x<p.length;x++)v(p[x]);return v}({1:[function(d,m,b){var p=d("./utils"),v=d("./support"),g="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";b.encode=function(x){for(var C,T,R,B,I,F,L,V=[],z=0,E=x.length,P=E,k=p.getTypeOf(x)!=="string";z<x.length;)P=E-z,R=k?(C=x[z++],T=z<E?x[z++]:0,z<E?x[z++]:0):(C=x.charCodeAt(z++),T=z<E?x.charCodeAt(z++):0,z<E?x.charCodeAt(z++):0),B=C>>2,I=(3&C)<<4|T>>4,F=1<P?(15&T)<<2|R>>6:64,L=2<P?63&R:64,V.push(g.charAt(B)+g.charAt(I)+g.charAt(F)+g.charAt(L));return V.join("")},b.decode=function(x){var C,T,R,B,I,F,L=0,V=0,z="data:";if(x.substr(0,z.length)===z)throw new Error("Invalid base64 input, it looks like a data url.");var E,P=3*(x=x.replace(/[^A-Za-z0-9+/=]/g,"")).length/4;if(x.charAt(x.length-1)===g.charAt(64)&&P--,x.charAt(x.length-2)===g.charAt(64)&&P--,P%1!=0)throw new Error("Invalid base64 input, bad content length.");for(E=v.uint8array?new Uint8Array(0|P):new Array(0|P);L<x.length;)C=g.indexOf(x.charAt(L++))<<2|(B=g.indexOf(x.charAt(L++)))>>4,T=(15&B)<<4|(I=g.indexOf(x.charAt(L++)))>>2,R=(3&I)<<6|(F=g.indexOf(x.charAt(L++))),E[V++]=C,I!==64&&(E[V++]=T),F!==64&&(E[V++]=R);return E}},{"./support":30,"./utils":32}],2:[function(d,m,b){var p=d("./external"),v=d("./stream/DataWorker"),g=d("./stream/Crc32Probe"),x=d("./stream/DataLengthProbe");function C(T,R,B,I,F){this.compressedSize=T,this.uncompressedSize=R,this.crc32=B,this.compression=I,this.compressedContent=F}C.prototype={getContentWorker:function(){var T=new v(p.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new x("data_length")),R=this;return T.on("end",function(){if(this.streamInfo.data_length!==R.uncompressedSize)throw new Error("Bug : uncompressed data size mismatch")}),T},getCompressedWorker:function(){return new v(p.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}},C.createWorkerFrom=function(T,R,B){return T.pipe(new g).pipe(new x("uncompressedSize")).pipe(R.compressWorker(B)).pipe(new x("compressedSize")).withStreamInfo("compression",R)},m.exports=C},{"./external":6,"./stream/Crc32Probe":25,"./stream/DataLengthProbe":26,"./stream/DataWorker":27}],3:[function(d,m,b){var p=d("./stream/GenericWorker");b.STORE={magic:"\0\0",compressWorker:function(){return new p("STORE compression")},uncompressWorker:function(){return new p("STORE decompression")}},b.DEFLATE=d("./flate")},{"./flate":7,"./stream/GenericWorker":28}],4:[function(d,m,b){var p=d("./utils"),v=function(){for(var g,x=[],C=0;C<256;C++){g=C;for(var T=0;T<8;T++)g=1&g?3988292384^g>>>1:g>>>1;x[C]=g}return x}();m.exports=function(g,x){return g!==void 0&&g.length?p.getTypeOf(g)!=="string"?function(C,T,R,B){var I=v,F=0+R;C^=-1;for(var L=0;L<F;L++)C=C>>>8^I[255&(C^T[L])];return-1^C}(0|x,g,g.length):function(C,T,R,B){var I=v,F=0+R;C^=-1;for(var L=0;L<F;L++)C=C>>>8^I[255&(C^T.charCodeAt(L))];return-1^C}(0|x,g,g.length):0}},{"./utils":32}],5:[function(d,m,b){b.base64=!1,b.binary=!1,b.dir=!1,b.createFolders=!0,b.date=null,b.compression=null,b.compressionOptions=null,b.comment=null,b.unixPermissions=null,b.dosPermissions=null},{}],6:[function(d,m,b){var p;p=typeof Promise<"u"?Promise:d("lie"),m.exports={Promise:p}},{lie:37}],7:[function(d,m,b){var p=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Uint32Array<"u",v=d("pako"),g=d("./utils"),x=d("./stream/GenericWorker"),C=p?"uint8array":"array";function T(R,B){x.call(this,"FlateWorker/"+R),this._pako=null,this._pakoAction=R,this._pakoOptions=B,this.meta={}}b.magic="\b\0",g.inherits(T,x),T.prototype.processChunk=function(R){this.meta=R.meta,this._pako===null&&this._createPako(),this._pako.push(g.transformTo(C,R.data),!1)},T.prototype.flush=function(){x.prototype.flush.call(this),this._pako===null&&this._createPako(),this._pako.push([],!0)},T.prototype.cleanUp=function(){x.prototype.cleanUp.call(this),this._pako=null},T.prototype._createPako=function(){this._pako=new v[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var R=this;this._pako.onData=function(B){R.push({data:B,meta:R.meta})}},b.compressWorker=function(R){return new T("Deflate",R)},b.uncompressWorker=function(){return new T("Inflate",{})}},{"./stream/GenericWorker":28,"./utils":32,pako:38}],8:[function(d,m,b){function p(I,F){var L,V="";for(L=0;L<F;L++)V+=String.fromCharCode(255&I),I>>>=8;return V}function v(I,F,L,V,z,E){var P,k,y=I.file,w=I.compression,_=E!==C.utf8encode,S=g.transformTo("string",E(y.name)),A=g.transformTo("string",C.utf8encode(y.name)),O=y.comment,N=g.transformTo("string",E(O)),U=g.transformTo("string",C.utf8encode(O)),H=A.length!==y.name.length,Z=U.length!==O.length,D="",q="",M="",j=y.dir,$=y.date,K={crc32:0,compressedSize:0,uncompressedSize:0};F&&!L||(K.crc32=I.crc32,K.compressedSize=I.compressedSize,K.uncompressedSize=I.uncompressedSize);var J=0;F&&(J|=8),_||!H&&!Z||(J|=2048);var X=0,Q=0;j&&(X|=16),z==="UNIX"?(Q=798,X|=function(se,Y){var te=se;return se||(te=Y?16893:33204),(65535&te)<<16}(y.unixPermissions,j)):(Q=20,X|=function(se){return 63&(se||0)}(y.dosPermissions)),P=$.getUTCHours(),P<<=6,P|=$.getUTCMinutes(),P<<=5,P|=$.getUTCSeconds()/2,k=$.getUTCFullYear()-1980,k<<=4,k|=$.getUTCMonth()+1,k<<=5,k|=$.getUTCDate(),H&&(q=p(1,1)+p(T(S),4)+A,D+="up"+p(q.length,2)+q),Z&&(M=p(1,1)+p(T(N),4)+U,D+="uc"+p(M.length,2)+M);var ee="";return ee+=` \0`,ee+=p(J,2),ee+=w.magic,ee+=p(P,2),ee+=p(k,2),ee+=p(K.crc32,4),ee+=p(K.compressedSize,4),ee+=p(K.uncompressedSize,4),ee+=p(S.length,2),ee+=p(D.length,2),{fileRecord:R.LOCAL_FILE_HEADER+ee+S+D,dirRecord:R.CENTRAL_FILE_HEADER+p(Q,2)+ee+p(N.length,2)+"\0\0\0\0"+p(X,4)+p(V,4)+S+D+N}}var g=d("../utils"),x=d("../stream/GenericWorker"),C=d("../utf8"),T=d("../crc32"),R=d("../signature");function B(I,F,L,V){x.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=F,this.zipPlatform=L,this.encodeFileName=V,this.streamFiles=I,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}g.inherits(B,x),B.prototype.push=function(I){var F=I.meta.percent||0,L=this.entriesCount,V=this._sources.length;this.accumulate?this.contentBuffer.push(I):(this.bytesWritten+=I.data.length,x.prototype.push.call(this,{data:I.data,meta:{currentFile:this.currentFile,percent:L?(F+100*(L-V-1))/L:100}}))},B.prototype.openedSource=function(I){this.currentSourceOffset=this.bytesWritten,this.currentFile=I.file.name;var F=this.streamFiles&&!I.file.dir;if(F){var L=v(I,F,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:L.fileRecord,meta:{percent:0}})}else this.accumulate=!0},B.prototype.closedSource=function(I){this.accumulate=!1;var F=this.streamFiles&&!I.file.dir,L=v(I,F,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(L.dirRecord),F)this.push({data:function(V){return R.DATA_DESCRIPTOR+p(V.crc32,4)+p(V.compressedSize,4)+p(V.uncompressedSize,4)}(I),meta:{percent:100}});else for(this.push({data:L.fileRecord,meta:{percent:0}});this.contentBuffer.length;)this.push(this.contentBuffer.shift());this.currentFile=null},B.prototype.flush=function(){for(var I=this.bytesWritten,F=0;F<this.dirRecords.length;F++)this.push({data:this.dirRecords[F],meta:{percent:100}});var L=this.bytesWritten-I,V=function(z,E,P,k,y){var w=g.transformTo("string",y(k));return R.CENTRAL_DIRECTORY_END+"\0\0\0\0"+p(z,2)+p(z,2)+p(E,4)+p(P,4)+p(w.length,2)+w}(this.dirRecords.length,L,I,this.zipComment,this.encodeFileName);this.push({data:V,meta:{percent:100}})},B.prototype.prepareNextSource=function(){this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused?this.previous.pause():this.previous.resume()},B.prototype.registerPrevious=function(I){this._sources.push(I);var F=this;return I.on("data",function(L){F.processChunk(L)}),I.on("end",function(){F.closedSource(F.previous.streamInfo),F._sources.length?F.prepareNextSource():F.end()}),I.on("error",function(L){F.error(L)}),this},B.prototype.resume=function(){return!!x.prototype.resume.call(this)&&(!this.previous&&this._sources.length?(this.prepareNextSource(),!0):this.previous||this._sources.length||this.generatedError?void 0:(this.end(),!0))},B.prototype.error=function(I){var F=this._sources;if(!x.prototype.error.call(this,I))return!1;for(var L=0;L<F.length;L++)try{F[L].error(I)}catch{}return!0},B.prototype.lock=function(){x.prototype.lock.call(this);for(var I=this._sources,F=0;F<I.length;F++)I[F].lock()},m.exports=B},{"../crc32":4,"../signature":23,"../stream/GenericWorker":28,"../utf8":31,"../utils":32}],9:[function(d,m,b){var p=d("../compressions"),v=d("./ZipFileWorker");b.generateWorker=function(g,x,C){var T=new v(x.streamFiles,C,x.platform,x.encodeFileName),R=0;try{g.forEach(function(B,I){R++;var F=function(E,P){var k=E||P,y=p[k];if(!y)throw new Error(k+" is not a valid compression method !");return y}(I.options.compression,x.compression),L=I.options.compressionOptions||x.compressionOptions||{},V=I.dir,z=I.date;I._compressWorker(F,L).withStreamInfo("file",{name:B,dir:V,date:z,comment:I.comment||"",unixPermissions:I.unixPermissions,dosPermissions:I.dosPermissions}).pipe(T)}),T.entriesCount=R}catch(B){T.error(B)}return T}},{"../compressions":3,"./ZipFileWorker":8}],10:[function(d,m,b){function p(){if(!(this instanceof p))return new p;if(arguments.length)throw new Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var v=new p;for(var g in this)typeof this[g]!="function"&&(v[g]=this[g]);return v}}(p.prototype=d("./object")).loadAsync=d("./load"),p.support=d("./support"),p.defaults=d("./defaults"),p.version="3.10.1",p.loadAsync=function(v,g){return new p().loadAsync(v,g)},p.external=d("./external"),m.exports=p},{"./defaults":5,"./external":6,"./load":11,"./object":15,"./support":30}],11:[function(d,m,b){var p=d("./utils"),v=d("./external"),g=d("./utf8"),x=d("./zipEntries"),C=d("./stream/Crc32Probe"),T=d("./nodejsUtils");function R(B){return new v.Promise(function(I,F){var L=B.decompressed.getContentWorker().pipe(new C);L.on("error",function(V){F(V)}).on("end",function(){L.streamInfo.crc32!==B.decompressed.crc32?F(new Error("Corrupted zip : CRC32 mismatch")):I()}).resume()})}m.exports=function(B,I){var F=this;return I=p.extend(I||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:g.utf8decode}),T.isNode&&T.isStream(B)?v.Promise.reject(new Error("JSZip can't accept a stream when loading a zip file.")):p.prepareContent("the loaded zip file",B,!0,I.optimizedBinaryString,I.base64).then(function(L){var V=new x(I);return V.load(L),V}).then(function(L){var V=[v.Promise.resolve(L)],z=L.files;if(I.checkCRC32)for(var E=0;E<z.length;E++)V.push(R(z[E]));return v.Promise.all(V)}).then(function(L){for(var V=L.shift(),z=V.files,E=0;E<z.length;E++){var P=z[E],k=P.fileNameStr,y=p.resolve(P.fileNameStr);F.file(y,P.decompressed,{binary:!0,optimizedBinaryString:!0,date:P.date,dir:P.dir,comment:P.fileCommentStr.length?P.fileCommentStr:null,unixPermissions:P.unixPermissions,dosPermissions:P.dosPermissions,createFolders:I.createFolders}),P.dir||(F.file(y).unsafeOriginalName=k)}return V.zipComment.length&&(F.comment=V.zipComment),F})}},{"./external":6,"./nodejsUtils":14,"./stream/Crc32Probe":25,"./utf8":31,"./utils":32,"./zipEntries":33}],12:[function(d,m,b){var p=d("../utils"),v=d("../stream/GenericWorker");function g(x,C){v.call(this,"Nodejs stream input adapter for "+x),this._upstreamEnded=!1,this._bindStream(C)}p.inherits(g,v),g.prototype._bindStream=function(x){var C=this;(this._stream=x).pause(),x.on("data",function(T){C.push({data:T,meta:{percent:0}})}).on("error",function(T){C.isPaused?this.generatedError=T:C.error(T)}).on("end",function(){C.isPaused?C._upstreamEnded=!0:C.end()})},g.prototype.pause=function(){return!!v.prototype.pause.call(this)&&(this._stream.pause(),!0)},g.prototype.resume=function(){return!!v.prototype.resume.call(this)&&(this._upstreamEnded?this.end():this._stream.resume(),!0)},m.exports=g},{"../stream/GenericWorker":28,"../utils":32}],13:[function(d,m,b){var p=d("readable-stream").Readable;function v(g,x,C){p.call(this,x),this._helper=g;var T=this;g.on("data",function(R,B){T.push(R)||T._helper.pause(),C&&C(B)}).on("error",function(R){T.emit("error",R)}).on("end",function(){T.push(null)})}d("../utils").inherits(v,p),v.prototype._read=function(){this._helper.resume()},m.exports=v},{"../utils":32,"readable-stream":16}],14:[function(d,m,b){m.exports={isNode:l!==void 0,newBufferFrom:function(p,v){if(l.from&&l.from!==Uint8Array.from)return l.from(p,v);if(typeof p=="number")throw new Error('The "data" argument must not be a number');return new l(p,v)},allocBuffer:function(p){if(l.alloc)return l.alloc(p);var v=new l(p);return v.fill(0),v},isBuffer:function(p){return l.isBuffer(p)},isStream:function(p){return p&&typeof p.on=="function"&&typeof p.pause=="function"&&typeof p.resume=="function"}}},{}],15:[function(d,m,b){function p(y,w,_){var S,A=g.getTypeOf(w),O=g.extend(_||{},T);O.date=O.date||new Date,O.compression!==null&&(O.compression=O.compression.toUpperCase()),typeof O.unixPermissions=="string"&&(O.unixPermissions=parseInt(O.unixPermissions,8)),O.unixPermissions&&16384&O.unixPermissions&&(O.dir=!0),O.dosPermissions&&16&O.dosPermissions&&(O.dir=!0),O.dir&&(y=z(y)),O.createFolders&&(S=V(y))&&E.call(this,S,!0);var N=A==="string"&&O.binary===!1&&O.base64===!1;_&&_.binary!==void 0||(O.binary=!N),(w instanceof R&&w.uncompressedSize===0||O.dir||!w||w.length===0)&&(O.base64=!1,O.binary=!0,w="",O.compression="STORE",A="string");var U;U=w instanceof R||w instanceof x?w:F.isNode&&F.isStream(w)?new L(y,w):g.prepareContent(y,w,O.binary,O.optimizedBinaryString,O.base64);var H=new B(y,U,O);this.files[y]=H}var v=d("./utf8"),g=d("./utils"),x=d("./stream/GenericWorker"),C=d("./stream/StreamHelper"),T=d("./defaults"),R=d("./compressedObject"),B=d("./zipObject"),I=d("./generate"),F=d("./nodejsUtils"),L=d("./nodejs/NodejsStreamInputAdapter"),V=function(y){y.slice(-1)==="/"&&(y=y.substring(0,y.length-1));var w=y.lastIndexOf("/");return 0<w?y.substring(0,w):""},z=function(y){return y.slice(-1)!=="/"&&(y+="/"),y},E=function(y,w){return w=w!==void 0?w:T.createFolders,y=z(y),this.files[y]||p.call(this,y,null,{dir:!0,createFolders:w}),this.files[y]};function P(y){return Object.prototype.toString.call(y)==="[object RegExp]"}var k={load:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function(y){var w,_,S;for(w in this.files)S=this.files[w],(_=w.slice(this.root.length,w.length))&&w.slice(0,this.root.length)===this.root&&y(_,S)},filter:function(y){var w=[];return this.forEach(function(_,S){y(_,S)&&w.push(S)}),w},file:function(y,w,_){if(arguments.length!==1)return y=this.root+y,p.call(this,y,w,_),this;if(P(y)){var S=y;return this.filter(function(O,N){return!N.dir&&S.test(O)})}var A=this.files[this.root+y];return A&&!A.dir?A:null},folder:function(y){if(!y)return this;if(P(y))return this.filter(function(A,O){return O.dir&&y.test(A)});var w=this.root+y,_=E.call(this,w),S=this.clone();return S.root=_.name,S},remove:function(y){y=this.root+y;var w=this.files[y];if(w||(y.slice(-1)!=="/"&&(y+="/"),w=this.files[y]),w&&!w.dir)delete this.files[y];else for(var _=this.filter(function(A,O){return O.name.slice(0,y.length)===y}),S=0;S<_.length;S++)delete this.files[_[S].name];return this},generate:function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function(y){var w,_={};try{if((_=g.extend(y||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:v.utf8encode})).type=_.type.toLowerCase(),_.compression=_.compression.toUpperCase(),_.type==="binarystring"&&(_.type="string"),!_.type)throw new Error("No output type specified.");g.checkSupport(_.type),_.platform!=="darwin"&&_.platform!=="freebsd"&&_.platform!=="linux"&&_.platform!=="sunos"||(_.platform="UNIX"),_.platform==="win32"&&(_.platform="DOS");var S=_.comment||this.comment||"";w=I.generateWorker(this,_,S)}catch(A){(w=new x("error")).error(A)}return new C(w,_.type||"string",_.mimeType)},generateAsync:function(y,w){return this.generateInternalStream(y).accumulate(w)},generateNodeStream:function(y,w){return(y=y||{}).type||(y.type="nodebuffer"),this.generateInternalStream(y).toNodejsStream(w)}};m.exports=k},{"./compressedObject":2,"./defaults":5,"./generate":9,"./nodejs/NodejsStreamInputAdapter":12,"./nodejsUtils":14,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31,"./utils":32,"./zipObject":35}],16:[function(d,m,b){m.exports=d("stream")},{stream:void 0}],17:[function(d,m,b){var p=d("./DataReader");function v(g){p.call(this,g);for(var x=0;x<this.data.length;x++)g[x]=255&g[x]}d("../utils").inherits(v,p),v.prototype.byteAt=function(g){return this.data[this.zero+g]},v.prototype.lastIndexOfSignature=function(g){for(var x=g.charCodeAt(0),C=g.charCodeAt(1),T=g.charCodeAt(2),R=g.charCodeAt(3),B=this.length-4;0<=B;--B)if(this.data[B]===x&&this.data[B+1]===C&&this.data[B+2]===T&&this.data[B+3]===R)return B-this.zero;return-1},v.prototype.readAndCheckSignature=function(g){var x=g.charCodeAt(0),C=g.charCodeAt(1),T=g.charCodeAt(2),R=g.charCodeAt(3),B=this.readData(4);return x===B[0]&&C===B[1]&&T===B[2]&&R===B[3]},v.prototype.readData=function(g){if(this.checkOffset(g),g===0)return[];var x=this.data.slice(this.zero+this.index,this.zero+this.index+g);return this.index+=g,x},m.exports=v},{"../utils":32,"./DataReader":18}],18:[function(d,m,b){var p=d("../utils");function v(g){this.data=g,this.length=g.length,this.index=0,this.zero=0}v.prototype={checkOffset:function(g){this.checkIndex(this.index+g)},checkIndex:function(g){if(this.length<this.zero+g||g<0)throw new Error("End of data reached (data length = "+this.length+", asked index = "+g+"). Corrupted zip ?")},setIndex:function(g){this.checkIndex(g),this.index=g},skip:function(g){this.setIndex(this.index+g)},byteAt:function(){},readInt:function(g){var x,C=0;for(this.checkOffset(g),x=this.index+g-1;x>=this.index;x--)C=(C<<8)+this.byteAt(x);return this.index+=g,C},readString:function(g){return p.transformTo("string",this.readData(g))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var g=this.readInt(4);return new Date(Date.UTC(1980+(g>>25&127),(g>>21&15)-1,g>>16&31,g>>11&31,g>>5&63,(31&g)<<1))}},m.exports=v},{"../utils":32}],19:[function(d,m,b){var p=d("./Uint8ArrayReader");function v(g){p.call(this,g)}d("../utils").inherits(v,p),v.prototype.readData=function(g){this.checkOffset(g);var x=this.data.slice(this.zero+this.index,this.zero+this.index+g);return this.index+=g,x},m.exports=v},{"../utils":32,"./Uint8ArrayReader":21}],20:[function(d,m,b){var p=d("./DataReader");function v(g){p.call(this,g)}d("../utils").inherits(v,p),v.prototype.byteAt=function(g){return this.data.charCodeAt(this.zero+g)},v.prototype.lastIndexOfSignature=function(g){return this.data.lastIndexOf(g)-this.zero},v.prototype.readAndCheckSignature=function(g){return g===this.readData(4)},v.prototype.readData=function(g){this.checkOffset(g);var x=this.data.slice(this.zero+this.index,this.zero+this.index+g);return this.index+=g,x},m.exports=v},{"../utils":32,"./DataReader":18}],21:[function(d,m,b){var p=d("./ArrayReader");function v(g){p.call(this,g)}d("../utils").inherits(v,p),v.prototype.readData=function(g){if(this.checkOffset(g),g===0)return new Uint8Array(0);var x=this.data.subarray(this.zero+this.index,this.zero+this.index+g);return this.index+=g,x},m.exports=v},{"../utils":32,"./ArrayReader":17}],22:[function(d,m,b){var p=d("../utils"),v=d("../support"),g=d("./ArrayReader"),x=d("./StringReader"),C=d("./NodeBufferReader"),T=d("./Uint8ArrayReader");m.exports=function(R){var B=p.getTypeOf(R);return p.checkSupport(B),B!=="string"||v.uint8array?B==="nodebuffer"?new C(R):v.uint8array?new T(p.transformTo("uint8array",R)):new g(p.transformTo("array",R)):new x(R)}},{"../support":30,"../utils":32,"./ArrayReader":17,"./NodeBufferReader":19,"./StringReader":20,"./Uint8ArrayReader":21}],23:[function(d,m,b){b.LOCAL_FILE_HEADER="PK",b.CENTRAL_FILE_HEADER="PK",b.CENTRAL_DIRECTORY_END="PK",b.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x07",b.ZIP64_CENTRAL_DIRECTORY_END="PK",b.DATA_DESCRIPTOR="PK\x07\b"},{}],24:[function(d,m,b){var p=d("./GenericWorker"),v=d("../utils");function g(x){p.call(this,"ConvertWorker to "+x),this.destType=x}v.inherits(g,p),g.prototype.processChunk=function(x){this.push({data:v.transformTo(this.destType,x.data),meta:x.meta})},m.exports=g},{"../utils":32,"./GenericWorker":28}],25:[function(d,m,b){var p=d("./GenericWorker"),v=d("../crc32");function g(){p.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}d("../utils").inherits(g,p),g.prototype.processChunk=function(x){this.streamInfo.crc32=v(x.data,this.streamInfo.crc32||0),this.push(x)},m.exports=g},{"../crc32":4,"../utils":32,"./GenericWorker":28}],26:[function(d,m,b){var p=d("../utils"),v=d("./GenericWorker");function g(x){v.call(this,"DataLengthProbe for "+x),this.propName=x,this.withStreamInfo(x,0)}p.inherits(g,v),g.prototype.processChunk=function(x){if(x){var C=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=C+x.data.length}v.prototype.processChunk.call(this,x)},m.exports=g},{"../utils":32,"./GenericWorker":28}],27:[function(d,m,b){var p=d("../utils"),v=d("./GenericWorker");function g(x){v.call(this,"DataWorker");var C=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,x.then(function(T){C.dataIsReady=!0,C.data=T,C.max=T&&T.length||0,C.type=p.getTypeOf(T),C.isPaused||C._tickAndRepeat()},function(T){C.error(T)})}p.inherits(g,v),g.prototype.cleanUp=function(){v.prototype.cleanUp.call(this),this.data=null},g.prototype.resume=function(){return!!v.prototype.resume.call(this)&&(!this._tickScheduled&&this.dataIsReady&&(this._tickScheduled=!0,p.delay(this._tickAndRepeat,[],this)),!0)},g.prototype._tickAndRepeat=function(){this._tickScheduled=!1,this.isPaused||this.isFinished||(this._tick(),this.isFinished||(p.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0))},g.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var x=null,C=Math.min(this.max,this.index+16384);if(this.index>=this.max)return this.end();switch(this.type){case"string":x=this.data.substring(this.index,C);break;case"uint8array":x=this.data.subarray(this.index,C);break;case"array":case"nodebuffer":x=this.data.slice(this.index,C)}return this.index=C,this.push({data:x,meta:{percent:this.max?this.index/this.max*100:0}})},m.exports=g},{"../utils":32,"./GenericWorker":28}],28:[function(d,m,b){function p(v){this.name=v||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}p.prototype={push:function(v){this.emit("data",v)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch(v){this.emit("error",v)}return!0},error:function(v){return!this.isFinished&&(this.isPaused?this.generatedError=v:(this.isFinished=!0,this.emit("error",v),this.previous&&this.previous.error(v),this.cleanUp()),!0)},on:function(v,g){return this._listeners[v].push(g),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function(v,g){if(this._listeners[v])for(var x=0;x<this._listeners[v].length;x++)this._listeners[v][x].call(this,g)},pipe:function(v){return v.registerPrevious(this)},registerPrevious:function(v){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.streamInfo=v.streamInfo,this.mergeStreamInfo(),this.previous=v;var g=this;return v.on("data",function(x){g.processChunk(x)}),v.on("end",function(){g.end()}),v.on("error",function(x){g.error(x)}),this},pause:function(){return!this.isPaused&&!this.isFinished&&(this.isPaused=!0,this.previous&&this.previous.pause(),!0)},resume:function(){if(!this.isPaused||this.isFinished)return!1;var v=this.isPaused=!1;return this.generatedError&&(this.error(this.generatedError),v=!0),this.previous&&this.previous.resume(),!v},flush:function(){},processChunk:function(v){this.push(v)},withStreamInfo:function(v,g){return this.extraStreamInfo[v]=g,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var v in this.extraStreamInfo)Object.prototype.hasOwnProperty.call(this.extraStreamInfo,v)&&(this.streamInfo[v]=this.extraStreamInfo[v])},lock:function(){if(this.isLocked)throw new Error("The stream '"+this+"' has already been used.");this.isLocked=!0,this.previous&&this.previous.lock()},toString:function(){var v="Worker "+this.name;return this.previous?this.previous+" -> "+v:v}},m.exports=p},{}],29:[function(d,m,b){var p=d("../utils"),v=d("./ConvertWorker"),g=d("./GenericWorker"),x=d("../base64"),C=d("../support"),T=d("../external"),R=null;if(C.nodestream)try{R=d("../nodejs/NodejsStreamOutputAdapter")}catch{}function B(I,F,L){var V=F;switch(F){case"blob":case"arraybuffer":V="uint8array";break;case"base64":V="string"}try{this._internalType=V,this._outputType=F,this._mimeType=L,p.checkSupport(V),this._worker=I.pipe(new v(V)),I.lock()}catch(z){this._worker=new g("error"),this._worker.error(z)}}B.prototype={accumulate:function(I){return function(F,L){return new T.Promise(function(V,z){var E=[],P=F._internalType,k=F._outputType,y=F._mimeType;F.on("data",function(w,_){E.push(w),L&&L(_)}).on("error",function(w){E=[],z(w)}).on("end",function(){try{var w=function(_,S,A){switch(_){case"blob":return p.newBlob(p.transformTo("arraybuffer",S),A);case"base64":return x.encode(S);default:return p.transformTo(_,S)}}(k,function(_,S){var A,O=0,N=null,U=0;for(A=0;A<S.length;A++)U+=S[A].length;switch(_){case"string":return S.join("");case"array":return Array.prototype.concat.apply([],S);case"uint8array":for(N=new Uint8Array(U),A=0;A<S.length;A++)N.set(S[A],O),O+=S[A].length;return N;case"nodebuffer":return l.concat(S);default:throw new Error("concat : unsupported type '"+_+"'")}}(P,E),y);V(w)}catch(_){z(_)}E=[]}).resume()})}(this,I)},on:function(I,F){var L=this;return I==="data"?this._worker.on(I,function(V){F.call(L,V.data,V.meta)}):this._worker.on(I,function(){p.delay(F,arguments,L)}),this},resume:function(){return p.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function(I){if(p.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw new Error(this._outputType+" is not supported by this method");return new R(this,{objectMode:this._outputType!=="nodebuffer"},I)}},m.exports=B},{"../base64":1,"../external":6,"../nodejs/NodejsStreamOutputAdapter":13,"../support":30,"../utils":32,"./ConvertWorker":24,"./GenericWorker":28}],30:[function(d,m,b){if(b.base64=!0,b.array=!0,b.string=!0,b.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",b.nodebuffer=l!==void 0,b.uint8array=typeof Uint8Array<"u",typeof ArrayBuffer>"u")b.blob=!1;else{var p=new ArrayBuffer(0);try{b.blob=new Blob([p],{type:"application/zip"}).size===0}catch{try{var v=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);v.append(p),b.blob=v.getBlob("application/zip").size===0}catch{b.blob=!1}}}try{b.nodestream=!!d("readable-stream").Readable}catch{b.nodestream=!1}},{"readable-stream":16}],31:[function(d,m,b){for(var p=d("./utils"),v=d("./support"),g=d("./nodejsUtils"),x=d("./stream/GenericWorker"),C=new Array(256),T=0;T<256;T++)C[T]=252<=T?6:248<=T?5:240<=T?4:224<=T?3:192<=T?2:1;function R(){x.call(this,"utf-8 decode"),this.leftOver=null}function B(){x.call(this,"utf-8 encode")}C[254]=C[254]=1,b.utf8encode=function(I){return v.nodebuffer?g.newBufferFrom(I,"utf-8"):function(F){var L,V,z,E,P,k=F.length,y=0;for(E=0;E<k;E++)(64512&(V=F.charCodeAt(E)))==55296&&E+1<k&&(64512&(z=F.charCodeAt(E+1)))==56320&&(V=65536+(V-55296<<10)+(z-56320),E++),y+=V<128?1:V<2048?2:V<65536?3:4;for(L=v.uint8array?new Uint8Array(y):new Array(y),E=P=0;P<y;E++)(64512&(V=F.charCodeAt(E)))==55296&&E+1<k&&(64512&(z=F.charCodeAt(E+1)))==56320&&(V=65536+(V-55296<<10)+(z-56320),E++),V<128?L[P++]=V:(V<2048?L[P++]=192|V>>>6:(V<65536?L[P++]=224|V>>>12:(L[P++]=240|V>>>18,L[P++]=128|V>>>12&63),L[P++]=128|V>>>6&63),L[P++]=128|63&V);return L}(I)},b.utf8decode=function(I){return v.nodebuffer?p.transformTo("nodebuffer",I).toString("utf-8"):function(F){var L,V,z,E,P=F.length,k=new Array(2*P);for(L=V=0;L<P;)if((z=F[L++])<128)k[V++]=z;else if(4<(E=C[z]))k[V++]=65533,L+=E-1;else{for(z&=E===2?31:E===3?15:7;1<E&&L<P;)z=z<<6|63&F[L++],E--;1<E?k[V++]=65533:z<65536?k[V++]=z:(z-=65536,k[V++]=55296|z>>10&1023,k[V++]=56320|1023&z)}return k.length!==V&&(k.subarray?k=k.subarray(0,V):k.length=V),p.applyFromCharCode(k)}(I=p.transformTo(v.uint8array?"uint8array":"array",I))},p.inherits(R,x),R.prototype.processChunk=function(I){var F=p.transformTo(v.uint8array?"uint8array":"array",I.data);if(this.leftOver&&this.leftOver.length){if(v.uint8array){var L=F;(F=new Uint8Array(L.length+this.leftOver.length)).set(this.leftOver,0),F.set(L,this.leftOver.length)}else F=this.leftOver.concat(F);this.leftOver=null}var V=function(E,P){var k;for((P=P||E.length)>E.length&&(P=E.length),k=P-1;0<=k&&(192&E[k])==128;)k--;return k<0||k===0?P:k+C[E[k]]>P?k:P}(F),z=F;V!==F.length&&(v.uint8array?(z=F.subarray(0,V),this.leftOver=F.subarray(V,F.length)):(z=F.slice(0,V),this.leftOver=F.slice(V,F.length))),this.push({data:b.utf8decode(z),meta:I.meta})},R.prototype.flush=function(){this.leftOver&&this.leftOver.length&&(this.push({data:b.utf8decode(this.leftOver),meta:{}}),this.leftOver=null)},b.Utf8DecodeWorker=R,p.inherits(B,x),B.prototype.processChunk=function(I){this.push({data:b.utf8encode(I.data),meta:I.meta})},b.Utf8EncodeWorker=B},{"./nodejsUtils":14,"./stream/GenericWorker":28,"./support":30,"./utils":32}],32:[function(d,m,b){var p=d("./support"),v=d("./base64"),g=d("./nodejsUtils"),x=d("./external");function C(L){return L}function T(L,V){for(var z=0;z<L.length;++z)V[z]=255&L.charCodeAt(z);return V}d("setimmediate"),b.newBlob=function(L,V){b.checkSupport("blob");try{return new Blob([L],{type:V})}catch{try{var z=new(self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder);return z.append(L),z.getBlob(V)}catch{throw new Error("Bug : can't construct the Blob.")}}};var R={stringifyByChunk:function(L,V,z){var E=[],P=0,k=L.length;if(k<=z)return String.fromCharCode.apply(null,L);for(;P<k;)V==="array"||V==="nodebuffer"?E.push(String.fromCharCode.apply(null,L.slice(P,Math.min(P+z,k)))):E.push(String.fromCharCode.apply(null,L.subarray(P,Math.min(P+z,k)))),P+=z;return E.join("")},stringifyByChar:function(L){for(var V="",z=0;z<L.length;z++)V+=String.fromCharCode(L[z]);return V},applyCanBeUsed:{uint8array:function(){try{return p.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch{return!1}}(),nodebuffer:function(){try{return p.nodebuffer&&String.fromCharCode.apply(null,g.allocBuffer(1)).length===1}catch{return!1}}()}};function B(L){var V=65536,z=b.getTypeOf(L),E=!0;if(z==="uint8array"?E=R.applyCanBeUsed.uint8array:z==="nodebuffer"&&(E=R.applyCanBeUsed.nodebuffer),E)for(;1<V;)try{return R.stringifyByChunk(L,z,V)}catch{V=Math.floor(V/2)}return R.stringifyByChar(L)}function I(L,V){for(var z=0;z<L.length;z++)V[z]=L[z];return V}b.applyFromCharCode=B;var F={};F.string={string:C,array:function(L){return T(L,new Array(L.length))},arraybuffer:function(L){return F.string.uint8array(L).buffer},uint8array:function(L){return T(L,new Uint8Array(L.length))},nodebuffer:function(L){return T(L,g.allocBuffer(L.length))}},F.array={string:B,array:C,arraybuffer:function(L){return new Uint8Array(L).buffer},uint8array:function(L){return new Uint8Array(L)},nodebuffer:function(L){return g.newBufferFrom(L)}},F.arraybuffer={string:function(L){return B(new Uint8Array(L))},array:function(L){return I(new Uint8Array(L),new Array(L.byteLength))},arraybuffer:C,uint8array:function(L){return new Uint8Array(L)},nodebuffer:function(L){return g.newBufferFrom(new Uint8Array(L))}},F.uint8array={string:B,array:function(L){return I(L,new Array(L.length))},arraybuffer:function(L){return L.buffer},uint8array:C,nodebuffer:function(L){return g.newBufferFrom(L)}},F.nodebuffer={string:B,array:function(L){return I(L,new Array(L.length))},arraybuffer:function(L){return F.nodebuffer.uint8array(L).buffer},uint8array:function(L){return I(L,new Uint8Array(L.length))},nodebuffer:C},b.transformTo=function(L,V){if(V=V||"",!L)return V;b.checkSupport(L);var z=b.getTypeOf(V);return F[z][L](V)},b.resolve=function(L){for(var V=L.split("/"),z=[],E=0;E<V.length;E++){var P=V[E];P==="."||P===""&&E!==0&&E!==V.length-1||(P===".."?z.pop():z.push(P))}return z.join("/")},b.getTypeOf=function(L){return typeof L=="string"?"string":Object.prototype.toString.call(L)==="[object Array]"?"array":p.nodebuffer&&g.isBuffer(L)?"nodebuffer":p.uint8array&&L instanceof Uint8Array?"uint8array":p.arraybuffer&&L instanceof ArrayBuffer?"arraybuffer":void 0},b.checkSupport=function(L){if(!p[L.toLowerCase()])throw new Error(L+" is not supported by this platform")},b.MAX_VALUE_16BITS=65535,b.MAX_VALUE_32BITS=-1,b.pretty=function(L){var V,z,E="";for(z=0;z<(L||"").length;z++)E+="\\x"+((V=L.charCodeAt(z))<16?"0":"")+V.toString(16).toUpperCase();return E},b.delay=function(L,V,z){u(function(){L.apply(z||null,V||[])})},b.inherits=function(L,V){function z(){}z.prototype=V.prototype,L.prototype=new z},b.extend=function(){var L,V,z={};for(L=0;L<arguments.length;L++)for(V in arguments[L])Object.prototype.hasOwnProperty.call(arguments[L],V)&&z[V]===void 0&&(z[V]=arguments[L][V]);return z},b.prepareContent=function(L,V,z,E,P){return x.Promise.resolve(V).then(function(k){return p.blob&&(k instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(k))!==-1)&&typeof FileReader<"u"?new x.Promise(function(y,w){var _=new FileReader;_.onload=function(S){y(S.target.result)},_.onerror=function(S){w(S.target.error)},_.readAsArrayBuffer(k)}):k}).then(function(k){var y=b.getTypeOf(k);return y?(y==="arraybuffer"?k=b.transformTo("uint8array",k):y==="string"&&(P?k=v.decode(k):z&&E!==!0&&(k=function(w){return T(w,p.uint8array?new Uint8Array(w.length):new Array(w.length))}(k))),k):x.Promise.reject(new Error("Can't read the data of '"+L+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"))})}},{"./base64":1,"./external":6,"./nodejsUtils":14,"./support":30,setimmediate:54}],33:[function(d,m,b){var p=d("./reader/readerFor"),v=d("./utils"),g=d("./signature"),x=d("./zipEntry"),C=d("./support");function T(R){this.files=[],this.loadOptions=R}T.prototype={checkSignature:function(R){if(!this.reader.readAndCheckSignature(R)){this.reader.index-=4;var B=this.reader.readString(4);throw new Error("Corrupted zip or bug: unexpected signature ("+v.pretty(B)+", expected "+v.pretty(R)+")")}},isSignature:function(R,B){var I=this.reader.index;this.reader.setIndex(R);var F=this.reader.readString(4)===B;return this.reader.setIndex(I),F},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var R=this.reader.readData(this.zipCommentLength),B=C.uint8array?"uint8array":"array",I=v.transformTo(B,R);this.zipComment=this.loadOptions.decodeFileName(I)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};for(var R,B,I,F=this.zip64EndOfCentralSize-44;0<F;)R=this.reader.readInt(2),B=this.reader.readInt(4),I=this.reader.readData(B),this.zip64ExtensibleData[R]={id:R,length:B,value:I}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),1<this.disksCount)throw new Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var R,B;for(R=0;R<this.files.length;R++)B=this.files[R],this.reader.setIndex(B.localHeaderOffset),this.checkSignature(g.LOCAL_FILE_HEADER),B.readLocalPart(this.reader),B.handleUTF8(),B.processAttributes()},readCentralDir:function(){var R;for(this.reader.setIndex(this.centralDirOffset);this.reader.readAndCheckSignature(g.CENTRAL_FILE_HEADER);)(R=new x({zip64:this.zip64},this.loadOptions)).readCentralPart(this.reader),this.files.push(R);if(this.centralDirRecords!==this.files.length&&this.centralDirRecords!==0&&this.files.length===0)throw new Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)},readEndOfCentral:function(){var R=this.reader.lastIndexOfSignature(g.CENTRAL_DIRECTORY_END);if(R<0)throw this.isSignature(0,g.LOCAL_FILE_HEADER)?new Error("Corrupted zip: can't find end of central directory"):new Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");this.reader.setIndex(R);var B=R;if(this.checkSignature(g.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===v.MAX_VALUE_16BITS||this.diskWithCentralDirStart===v.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===v.MAX_VALUE_16BITS||this.centralDirRecords===v.MAX_VALUE_16BITS||this.centralDirSize===v.MAX_VALUE_32BITS||this.centralDirOffset===v.MAX_VALUE_32BITS){if(this.zip64=!0,(R=this.reader.lastIndexOfSignature(g.ZIP64_CENTRAL_DIRECTORY_LOCATOR))<0)throw new Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex(R),this.checkSignature(g.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,g.ZIP64_CENTRAL_DIRECTORY_END)&&(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(g.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0))throw new Error("Corrupted zip: can't find the ZIP64 end of central directory");this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(g.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var I=this.centralDirOffset+this.centralDirSize;this.zip64&&(I+=20,I+=12+this.zip64EndOfCentralSize);var F=B-I;if(0<F)this.isSignature(B,g.CENTRAL_FILE_HEADER)||(this.reader.zero=F);else if(F<0)throw new Error("Corrupted zip: missing "+Math.abs(F)+" bytes.")},prepareReader:function(R){this.reader=p(R)},load:function(R){this.prepareReader(R),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}},m.exports=T},{"./reader/readerFor":22,"./signature":23,"./support":30,"./utils":32,"./zipEntry":34}],34:[function(d,m,b){var p=d("./reader/readerFor"),v=d("./utils"),g=d("./compressedObject"),x=d("./crc32"),C=d("./utf8"),T=d("./compressions"),R=d("./support");function B(I,F){this.options=I,this.loadOptions=F}B.prototype={isEncrypted:function(){return(1&this.bitFlag)==1},useUTF8:function(){return(2048&this.bitFlag)==2048},readLocalPart:function(I){var F,L;if(I.skip(22),this.fileNameLength=I.readInt(2),L=I.readInt(2),this.fileName=I.readData(this.fileNameLength),I.skip(L),this.compressedSize===-1||this.uncompressedSize===-1)throw new Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if((F=function(V){for(var z in T)if(Object.prototype.hasOwnProperty.call(T,z)&&T[z].magic===V)return T[z];return null}(this.compressionMethod))===null)throw new Error("Corrupted zip : compression "+v.pretty(this.compressionMethod)+" unknown (inner file : "+v.transformTo("string",this.fileName)+")");this.decompressed=new g(this.compressedSize,this.uncompressedSize,this.crc32,F,I.readData(this.compressedSize))},readCentralPart:function(I){this.versionMadeBy=I.readInt(2),I.skip(2),this.bitFlag=I.readInt(2),this.compressionMethod=I.readString(2),this.date=I.readDate(),this.crc32=I.readInt(4),this.compressedSize=I.readInt(4),this.uncompressedSize=I.readInt(4);var F=I.readInt(2);if(this.extraFieldsLength=I.readInt(2),this.fileCommentLength=I.readInt(2),this.diskNumberStart=I.readInt(2),this.internalFileAttributes=I.readInt(2),this.externalFileAttributes=I.readInt(4),this.localHeaderOffset=I.readInt(4),this.isEncrypted())throw new Error("Encrypted zip are not supported");I.skip(F),this.readExtraFields(I),this.parseZIP64ExtraField(I),this.fileComment=I.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var I=this.versionMadeBy>>8;this.dir=!!(16&this.externalFileAttributes),I==0&&(this.dosPermissions=63&this.externalFileAttributes),I==3&&(this.unixPermissions=this.externalFileAttributes>>16&65535),this.dir||this.fileNameStr.slice(-1)!=="/"||(this.dir=!0)},parseZIP64ExtraField:function(){if(this.extraFields[1]){var I=p(this.extraFields[1].value);this.uncompressedSize===v.MAX_VALUE_32BITS&&(this.uncompressedSize=I.readInt(8)),this.compressedSize===v.MAX_VALUE_32BITS&&(this.compressedSize=I.readInt(8)),this.localHeaderOffset===v.MAX_VALUE_32BITS&&(this.localHeaderOffset=I.readInt(8)),this.diskNumberStart===v.MAX_VALUE_32BITS&&(this.diskNumberStart=I.readInt(4))}},readExtraFields:function(I){var F,L,V,z=I.index+this.extraFieldsLength;for(this.extraFields||(this.extraFields={});I.index+4<z;)F=I.readInt(2),L=I.readInt(2),V=I.readData(L),this.extraFields[F]={id:F,length:L,value:V};I.setIndex(z)},handleUTF8:function(){var I=R.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=C.utf8decode(this.fileName),this.fileCommentStr=C.utf8decode(this.fileComment);else{var F=this.findExtraFieldUnicodePath();if(F!==null)this.fileNameStr=F;else{var L=v.transformTo(I,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(L)}var V=this.findExtraFieldUnicodeComment();if(V!==null)this.fileCommentStr=V;else{var z=v.transformTo(I,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(z)}}},findExtraFieldUnicodePath:function(){var I=this.extraFields[28789];if(I){var F=p(I.value);return F.readInt(1)!==1||x(this.fileName)!==F.readInt(4)?null:C.utf8decode(F.readData(I.length-5))}return null},findExtraFieldUnicodeComment:function(){var I=this.extraFields[25461];if(I){var F=p(I.value);return F.readInt(1)!==1||x(this.fileComment)!==F.readInt(4)?null:C.utf8decode(F.readData(I.length-5))}return null}},m.exports=B},{"./compressedObject":2,"./compressions":3,"./crc32":4,"./reader/readerFor":22,"./support":30,"./utf8":31,"./utils":32}],35:[function(d,m,b){function p(F,L,V){this.name=F,this.dir=V.dir,this.date=V.date,this.comment=V.comment,this.unixPermissions=V.unixPermissions,this.dosPermissions=V.dosPermissions,this._data=L,this._dataBinary=V.binary,this.options={compression:V.compression,compressionOptions:V.compressionOptions}}var v=d("./stream/StreamHelper"),g=d("./stream/DataWorker"),x=d("./utf8"),C=d("./compressedObject"),T=d("./stream/GenericWorker");p.prototype={internalStream:function(F){var L=null,V="string";try{if(!F)throw new Error("No output type specified.");var z=(V=F.toLowerCase())==="string"||V==="text";V!=="binarystring"&&V!=="text"||(V="string"),L=this._decompressWorker();var E=!this._dataBinary;E&&!z&&(L=L.pipe(new x.Utf8EncodeWorker)),!E&&z&&(L=L.pipe(new x.Utf8DecodeWorker))}catch(P){(L=new T("error")).error(P)}return new v(L,V,"")},async:function(F,L){return this.internalStream(F).accumulate(L)},nodeStream:function(F,L){return this.internalStream(F||"nodebuffer").toNodejsStream(L)},_compressWorker:function(F,L){if(this._data instanceof C&&this._data.compression.magic===F.magic)return this._data.getCompressedWorker();var V=this._decompressWorker();return this._dataBinary||(V=V.pipe(new x.Utf8EncodeWorker)),C.createWorkerFrom(V,F,L)},_decompressWorker:function(){return this._data instanceof C?this._data.getContentWorker():this._data instanceof T?this._data:new g(this._data)}};for(var R=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],B=function(){throw new Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},I=0;I<R.length;I++)p.prototype[R[I]]=B;m.exports=p},{"./compressedObject":2,"./stream/DataWorker":27,"./stream/GenericWorker":28,"./stream/StreamHelper":29,"./utf8":31}],36:[function(d,m,b){(function(p){var v,g,x=p.MutationObserver||p.WebKitMutationObserver;if(x){var C=0,T=new x(F),R=p.document.createTextNode("");T.observe(R,{characterData:!0}),v=function(){R.data=C=++C%2}}else if(p.setImmediate||p.MessageChannel===void 0)v="document"in p&&"onreadystatechange"in p.document.createElement("script")?function(){var L=p.document.createElement("script");L.onreadystatechange=function(){F(),L.onreadystatechange=null,L.parentNode.removeChild(L),L=null},p.document.documentElement.appendChild(L)}:function(){setTimeout(F,0)};else{var B=new p.MessageChannel;B.port1.onmessage=F,v=function(){B.port2.postMessage(0)}}var I=[];function F(){var L,V;g=!0;for(var z=I.length;z;){for(V=I,I=[],L=-1;++L<z;)V[L]();z=I.length}g=!1}m.exports=function(L){I.push(L)!==1||g||v()}}).call(this,s!==void 0?s:typeof self<"u"?self:typeof window<"u"?window:{})},{}],37:[function(d,m,b){var p=d("immediate");function v(){}var g={},x=["REJECTED"],C=["FULFILLED"],T=["PENDING"];function R(z){if(typeof z!="function")throw new TypeError("resolver must be a function");this.state=T,this.queue=[],this.outcome=void 0,z!==v&&L(this,z)}function B(z,E,P){this.promise=z,typeof E=="function"&&(this.onFulfilled=E,this.callFulfilled=this.otherCallFulfilled),typeof P=="function"&&(this.onRejected=P,this.callRejected=this.otherCallRejected)}function I(z,E,P){p(function(){var k;try{k=E(P)}catch(y){return g.reject(z,y)}k===z?g.reject(z,new TypeError("Cannot resolve promise with itself")):g.resolve(z,k)})}function F(z){var E=z&&z.then;if(z&&(typeof z=="object"||typeof z=="function")&&typeof E=="function")return function(){E.apply(z,arguments)}}function L(z,E){var P=!1;function k(_){P||(P=!0,g.reject(z,_))}function y(_){P||(P=!0,g.resolve(z,_))}var w=V(function(){E(y,k)});w.status==="error"&&k(w.value)}function V(z,E){var P={};try{P.value=z(E),P.status="success"}catch(k){P.status="error",P.value=k}return P}(m.exports=R).prototype.finally=function(z){if(typeof z!="function")return this;var E=this.constructor;return this.then(function(P){return E.resolve(z()).then(function(){return P})},function(P){return E.resolve(z()).then(function(){throw P})})},R.prototype.catch=function(z){return this.then(null,z)},R.prototype.then=function(z,E){if(typeof z!="function"&&this.state===C||typeof E!="function"&&this.state===x)return this;var P=new this.constructor(v);return this.state!==T?I(P,this.state===C?z:E,this.outcome):this.queue.push(new B(P,z,E)),P},B.prototype.callFulfilled=function(z){g.resolve(this.promise,z)},B.prototype.otherCallFulfilled=function(z){I(this.promise,this.onFulfilled,z)},B.prototype.callRejected=function(z){g.reject(this.promise,z)},B.prototype.otherCallRejected=function(z){I(this.promise,this.onRejected,z)},g.resolve=function(z,E){var P=V(F,E);if(P.status==="error")return g.reject(z,P.value);var k=P.value;if(k)L(z,k);else{z.state=C,z.outcome=E;for(var y=-1,w=z.queue.length;++y<w;)z.queue[y].callFulfilled(E)}return z},g.reject=function(z,E){z.state=x,z.outcome=E;for(var P=-1,k=z.queue.length;++P<k;)z.queue[P].callRejected(E);return z},R.resolve=function(z){return z instanceof this?z:g.resolve(new this(v),z)},R.reject=function(z){var E=new this(v);return g.reject(E,z)},R.all=function(z){var E=this;if(Object.prototype.toString.call(z)!=="[object Array]")return this.reject(new TypeError("must be an array"));var P=z.length,k=!1;if(!P)return this.resolve([]);for(var y=new Array(P),w=0,_=-1,S=new this(v);++_<P;)A(z[_],_);return S;function A(O,N){E.resolve(O).then(function(U){y[N]=U,++w!==P||k||(k=!0,g.resolve(S,y))},function(U){k||(k=!0,g.reject(S,U))})}},R.race=function(z){if(Object.prototype.toString.call(z)!=="[object Array]")return this.reject(new TypeError("must be an array"));var E=z.length,P=!1;if(!E)return this.resolve([]);for(var k,y=-1,w=new this(v);++y<E;)k=z[y],this.resolve(k).then(function(_){P||(P=!0,g.resolve(w,_))},function(_){P||(P=!0,g.reject(w,_))});return w}},{immediate:36}],38:[function(d,m,b){var p={};(0,d("./lib/utils/common").assign)(p,d("./lib/deflate"),d("./lib/inflate"),d("./lib/zlib/constants")),m.exports=p},{"./lib/deflate":39,"./lib/inflate":40,"./lib/utils/common":41,"./lib/zlib/constants":44}],39:[function(d,m,b){var p=d("./zlib/deflate"),v=d("./utils/common"),g=d("./utils/strings"),x=d("./zlib/messages"),C=d("./zlib/zstream"),T=Object.prototype.toString;function R(I){if(!(this instanceof R))return new R(I);this.options=v.assign({level:-1,method:8,chunkSize:16384,windowBits:15,memLevel:8,strategy:0,to:""},I||{});var F=this.options;F.raw&&0<F.windowBits?F.windowBits=-F.windowBits:F.gzip&&0<F.windowBits&&F.windowBits<16&&(F.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new C,this.strm.avail_out=0;var L=p.deflateInit2(this.strm,F.level,F.method,F.windowBits,F.memLevel,F.strategy);if(L!==0)throw new Error(x[L]);if(F.header&&p.deflateSetHeader(this.strm,F.header),F.dictionary){var V;if(V=typeof F.dictionary=="string"?g.string2buf(F.dictionary):T.call(F.dictionary)==="[object ArrayBuffer]"?new Uint8Array(F.dictionary):F.dictionary,(L=p.deflateSetDictionary(this.strm,V))!==0)throw new Error(x[L]);this._dict_set=!0}}function B(I,F){var L=new R(F);if(L.push(I,!0),L.err)throw L.msg||x[L.err];return L.result}R.prototype.push=function(I,F){var L,V,z=this.strm,E=this.options.chunkSize;if(this.ended)return!1;V=F===~~F?F:F===!0?4:0,typeof I=="string"?z.input=g.string2buf(I):T.call(I)==="[object ArrayBuffer]"?z.input=new Uint8Array(I):z.input=I,z.next_in=0,z.avail_in=z.input.length;do{if(z.avail_out===0&&(z.output=new v.Buf8(E),z.next_out=0,z.avail_out=E),(L=p.deflate(z,V))!==1&&L!==0)return this.onEnd(L),!(this.ended=!0);z.avail_out!==0&&(z.avail_in!==0||V!==4&&V!==2)||(this.options.to==="string"?this.onData(g.buf2binstring(v.shrinkBuf(z.output,z.next_out))):this.onData(v.shrinkBuf(z.output,z.next_out)))}while((0<z.avail_in||z.avail_out===0)&&L!==1);return V===4?(L=p.deflateEnd(this.strm),this.onEnd(L),this.ended=!0,L===0):V!==2||(this.onEnd(0),!(z.avail_out=0))},R.prototype.onData=function(I){this.chunks.push(I)},R.prototype.onEnd=function(I){I===0&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=v.flattenChunks(this.chunks)),this.chunks=[],this.err=I,this.msg=this.strm.msg},b.Deflate=R,b.deflate=B,b.deflateRaw=function(I,F){return(F=F||{}).raw=!0,B(I,F)},b.gzip=function(I,F){return(F=F||{}).gzip=!0,B(I,F)}},{"./utils/common":41,"./utils/strings":42,"./zlib/deflate":46,"./zlib/messages":51,"./zlib/zstream":53}],40:[function(d,m,b){var p=d("./zlib/inflate"),v=d("./utils/common"),g=d("./utils/strings"),x=d("./zlib/constants"),C=d("./zlib/messages"),T=d("./zlib/zstream"),R=d("./zlib/gzheader"),B=Object.prototype.toString;function I(L){if(!(this instanceof I))return new I(L);this.options=v.assign({chunkSize:16384,windowBits:0,to:""},L||{});var V=this.options;V.raw&&0<=V.windowBits&&V.windowBits<16&&(V.windowBits=-V.windowBits,V.windowBits===0&&(V.windowBits=-15)),!(0<=V.windowBits&&V.windowBits<16)||L&&L.windowBits||(V.windowBits+=32),15<V.windowBits&&V.windowBits<48&&(15&V.windowBits)==0&&(V.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new T,this.strm.avail_out=0;var z=p.inflateInit2(this.strm,V.windowBits);if(z!==x.Z_OK)throw new Error(C[z]);this.header=new R,p.inflateGetHeader(this.strm,this.header)}function F(L,V){var z=new I(V);if(z.push(L,!0),z.err)throw z.msg||C[z.err];return z.result}I.prototype.push=function(L,V){var z,E,P,k,y,w,_=this.strm,S=this.options.chunkSize,A=this.options.dictionary,O=!1;if(this.ended)return!1;E=V===~~V?V:V===!0?x.Z_FINISH:x.Z_NO_FLUSH,typeof L=="string"?_.input=g.binstring2buf(L):B.call(L)==="[object ArrayBuffer]"?_.input=new Uint8Array(L):_.input=L,_.next_in=0,_.avail_in=_.input.length;do{if(_.avail_out===0&&(_.output=new v.Buf8(S),_.next_out=0,_.avail_out=S),(z=p.inflate(_,x.Z_NO_FLUSH))===x.Z_NEED_DICT&&A&&(w=typeof A=="string"?g.string2buf(A):B.call(A)==="[object ArrayBuffer]"?new Uint8Array(A):A,z=p.inflateSetDictionary(this.strm,w)),z===x.Z_BUF_ERROR&&O===!0&&(z=x.Z_OK,O=!1),z!==x.Z_STREAM_END&&z!==x.Z_OK)return this.onEnd(z),!(this.ended=!0);_.next_out&&(_.avail_out!==0&&z!==x.Z_STREAM_END&&(_.avail_in!==0||E!==x.Z_FINISH&&E!==x.Z_SYNC_FLUSH)||(this.options.to==="string"?(P=g.utf8border(_.output,_.next_out),k=_.next_out-P,y=g.buf2string(_.output,P),_.next_out=k,_.avail_out=S-k,k&&v.arraySet(_.output,_.output,P,k,0),this.onData(y)):this.onData(v.shrinkBuf(_.output,_.next_out)))),_.avail_in===0&&_.avail_out===0&&(O=!0)}while((0<_.avail_in||_.avail_out===0)&&z!==x.Z_STREAM_END);return z===x.Z_STREAM_END&&(E=x.Z_FINISH),E===x.Z_FINISH?(z=p.inflateEnd(this.strm),this.onEnd(z),this.ended=!0,z===x.Z_OK):E!==x.Z_SYNC_FLUSH||(this.onEnd(x.Z_OK),!(_.avail_out=0))},I.prototype.onData=function(L){this.chunks.push(L)},I.prototype.onEnd=function(L){L===x.Z_OK&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=v.flattenChunks(this.chunks)),this.chunks=[],this.err=L,this.msg=this.strm.msg},b.Inflate=I,b.inflate=F,b.inflateRaw=function(L,V){return(V=V||{}).raw=!0,F(L,V)},b.ungzip=F},{"./utils/common":41,"./utils/strings":42,"./zlib/constants":44,"./zlib/gzheader":47,"./zlib/inflate":49,"./zlib/messages":51,"./zlib/zstream":53}],41:[function(d,m,b){var p=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";b.assign=function(x){for(var C=Array.prototype.slice.call(arguments,1);C.length;){var T=C.shift();if(T){if(typeof T!="object")throw new TypeError(T+"must be non-object");for(var R in T)T.hasOwnProperty(R)&&(x[R]=T[R])}}return x},b.shrinkBuf=function(x,C){return x.length===C?x:x.subarray?x.subarray(0,C):(x.length=C,x)};var v={arraySet:function(x,C,T,R,B){if(C.subarray&&x.subarray)x.set(C.subarray(T,T+R),B);else for(var I=0;I<R;I++)x[B+I]=C[T+I]},flattenChunks:function(x){var C,T,R,B,I,F;for(C=R=0,T=x.length;C<T;C++)R+=x[C].length;for(F=new Uint8Array(R),C=B=0,T=x.length;C<T;C++)I=x[C],F.set(I,B),B+=I.length;return F}},g={arraySet:function(x,C,T,R,B){for(var I=0;I<R;I++)x[B+I]=C[T+I]},flattenChunks:function(x){return[].concat.apply([],x)}};b.setTyped=function(x){x?(b.Buf8=Uint8Array,b.Buf16=Uint16Array,b.Buf32=Int32Array,b.assign(b,v)):(b.Buf8=Array,b.Buf16=Array,b.Buf32=Array,b.assign(b,g))},b.setTyped(p)},{}],42:[function(d,m,b){var p=d("./common"),v=!0,g=!0;try{String.fromCharCode.apply(null,[0])}catch{v=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{g=!1}for(var x=new p.Buf8(256),C=0;C<256;C++)x[C]=252<=C?6:248<=C?5:240<=C?4:224<=C?3:192<=C?2:1;function T(R,B){if(B<65537&&(R.subarray&&g||!R.subarray&&v))return String.fromCharCode.apply(null,p.shrinkBuf(R,B));for(var I="",F=0;F<B;F++)I+=String.fromCharCode(R[F]);return I}x[254]=x[254]=1,b.string2buf=function(R){var B,I,F,L,V,z=R.length,E=0;for(L=0;L<z;L++)(64512&(I=R.charCodeAt(L)))==55296&&L+1<z&&(64512&(F=R.charCodeAt(L+1)))==56320&&(I=65536+(I-55296<<10)+(F-56320),L++),E+=I<128?1:I<2048?2:I<65536?3:4;for(B=new p.Buf8(E),L=V=0;V<E;L++)(64512&(I=R.charCodeAt(L)))==55296&&L+1<z&&(64512&(F=R.charCodeAt(L+1)))==56320&&(I=65536+(I-55296<<10)+(F-56320),L++),I<128?B[V++]=I:(I<2048?B[V++]=192|I>>>6:(I<65536?B[V++]=224|I>>>12:(B[V++]=240|I>>>18,B[V++]=128|I>>>12&63),B[V++]=128|I>>>6&63),B[V++]=128|63&I);return B},b.buf2binstring=function(R){return T(R,R.length)},b.binstring2buf=function(R){for(var B=new p.Buf8(R.length),I=0,F=B.length;I<F;I++)B[I]=R.charCodeAt(I);return B},b.buf2string=function(R,B){var I,F,L,V,z=B||R.length,E=new Array(2*z);for(I=F=0;I<z;)if((L=R[I++])<128)E[F++]=L;else if(4<(V=x[L]))E[F++]=65533,I+=V-1;else{for(L&=V===2?31:V===3?15:7;1<V&&I<z;)L=L<<6|63&R[I++],V--;1<V?E[F++]=65533:L<65536?E[F++]=L:(L-=65536,E[F++]=55296|L>>10&1023,E[F++]=56320|1023&L)}return T(E,F)},b.utf8border=function(R,B){var I;for((B=B||R.length)>R.length&&(B=R.length),I=B-1;0<=I&&(192&R[I])==128;)I--;return I<0||I===0?B:I+x[R[I]]>B?I:B}},{"./common":41}],43:[function(d,m,b){m.exports=function(p,v,g,x){for(var C=65535&p|0,T=p>>>16&65535|0,R=0;g!==0;){for(g-=R=2e3<g?2e3:g;T=T+(C=C+v[x++]|0)|0,--R;);C%=65521,T%=65521}return C|T<<16|0}},{}],44:[function(d,m,b){m.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],45:[function(d,m,b){var p=function(){for(var v,g=[],x=0;x<256;x++){v=x;for(var C=0;C<8;C++)v=1&v?3988292384^v>>>1:v>>>1;g[x]=v}return g}();m.exports=function(v,g,x,C){var T=p,R=C+x;v^=-1;for(var B=C;B<R;B++)v=v>>>8^T[255&(v^g[B])];return-1^v}},{}],46:[function(d,m,b){var p,v=d("../utils/common"),g=d("./trees"),x=d("./adler32"),C=d("./crc32"),T=d("./messages"),R=-2,B=258,I=262,F=113;function L(D,q){return D.msg=T[q],q}function V(D){return(D<<1)-(4<D?9:0)}function z(D){for(var q=D.length;0<=--q;)D[q]=0}function E(D){var q=D.state,M=q.pending;M>D.avail_out&&(M=D.avail_out),M!==0&&(v.arraySet(D.output,q.pending_buf,q.pending_out,M,D.next_out),D.next_out+=M,q.pending_out+=M,D.total_out+=M,D.avail_out-=M,q.pending-=M,q.pending===0&&(q.pending_out=0))}function P(D,q){g._tr_flush_block(D,0<=D.block_start?D.block_start:-1,D.strstart-D.block_start,q),D.block_start=D.strstart,E(D.strm)}function k(D,q){D.pending_buf[D.pending++]=q}function y(D,q){D.pending_buf[D.pending++]=q>>>8&255,D.pending_buf[D.pending++]=255&q}function w(D,q){var M,j,$=D.max_chain_length,K=D.strstart,J=D.prev_length,X=D.nice_match,Q=D.strstart>D.w_size-I?D.strstart-(D.w_size-I):0,ee=D.window,se=D.w_mask,Y=D.prev,te=D.strstart+B,ne=ee[K+J-1],oe=ee[K+J];D.prev_length>=D.good_match&&($>>=2),X>D.lookahead&&(X=D.lookahead);do if(ee[(M=q)+J]===oe&&ee[M+J-1]===ne&&ee[M]===ee[K]&&ee[++M]===ee[K+1]){K+=2,M++;do;while(ee[++K]===ee[++M]&&ee[++K]===ee[++M]&&ee[++K]===ee[++M]&&ee[++K]===ee[++M]&&ee[++K]===ee[++M]&&ee[++K]===ee[++M]&&ee[++K]===ee[++M]&&ee[++K]===ee[++M]&&K<te);if(j=B-(te-K),K=te-B,J<j){if(D.match_start=q,X<=(J=j))break;ne=ee[K+J-1],oe=ee[K+J]}}while((q=Y[q&se])>Q&&--$!=0);return J<=D.lookahead?J:D.lookahead}function _(D){var q,M,j,$,K,J,X,Q,ee,se,Y=D.w_size;do{if($=D.window_size-D.lookahead-D.strstart,D.strstart>=Y+(Y-I)){for(v.arraySet(D.window,D.window,Y,Y,0),D.match_start-=Y,D.strstart-=Y,D.block_start-=Y,q=M=D.hash_size;j=D.head[--q],D.head[q]=Y<=j?j-Y:0,--M;);for(q=M=Y;j=D.prev[--q],D.prev[q]=Y<=j?j-Y:0,--M;);$+=Y}if(D.strm.avail_in===0)break;if(J=D.strm,X=D.window,Q=D.strstart+D.lookahead,se=void 0,(ee=$)<(se=J.avail_in)&&(se=ee),M=se===0?0:(J.avail_in-=se,v.arraySet(X,J.input,J.next_in,se,Q),J.state.wrap===1?J.adler=x(J.adler,X,se,Q):J.state.wrap===2&&(J.adler=C(J.adler,X,se,Q)),J.next_in+=se,J.total_in+=se,se),D.lookahead+=M,D.lookahead+D.insert>=3)for(K=D.strstart-D.insert,D.ins_h=D.window[K],D.ins_h=(D.ins_h<<D.hash_shift^D.window[K+1])&D.hash_mask;D.insert&&(D.ins_h=(D.ins_h<<D.hash_shift^D.window[K+3-1])&D.hash_mask,D.prev[K&D.w_mask]=D.head[D.ins_h],D.head[D.ins_h]=K,K++,D.insert--,!(D.lookahead+D.insert<3)););}while(D.lookahead<I&&D.strm.avail_in!==0)}function S(D,q){for(var M,j;;){if(D.lookahead<I){if(_(D),D.lookahead<I&&q===0)return 1;if(D.lookahead===0)break}if(M=0,D.lookahead>=3&&(D.ins_h=(D.ins_h<<D.hash_shift^D.window[D.strstart+3-1])&D.hash_mask,M=D.prev[D.strstart&D.w_mask]=D.head[D.ins_h],D.head[D.ins_h]=D.strstart),M!==0&&D.strstart-M<=D.w_size-I&&(D.match_length=w(D,M)),D.match_length>=3)if(j=g._tr_tally(D,D.strstart-D.match_start,D.match_length-3),D.lookahead-=D.match_length,D.match_length<=D.max_lazy_match&&D.lookahead>=3){for(D.match_length--;D.strstart++,D.ins_h=(D.ins_h<<D.hash_shift^D.window[D.strstart+3-1])&D.hash_mask,M=D.prev[D.strstart&D.w_mask]=D.head[D.ins_h],D.head[D.ins_h]=D.strstart,--D.match_length!=0;);D.strstart++}else D.strstart+=D.match_length,D.match_length=0,D.ins_h=D.window[D.strstart],D.ins_h=(D.ins_h<<D.hash_shift^D.window[D.strstart+1])&D.hash_mask;else j=g._tr_tally(D,0,D.window[D.strstart]),D.lookahead--,D.strstart++;if(j&&(P(D,!1),D.strm.avail_out===0))return 1}return D.insert=D.strstart<2?D.strstart:2,q===4?(P(D,!0),D.strm.avail_out===0?3:4):D.last_lit&&(P(D,!1),D.strm.avail_out===0)?1:2}function A(D,q){for(var M,j,$;;){if(D.lookahead<I){if(_(D),D.lookahead<I&&q===0)return 1;if(D.lookahead===0)break}if(M=0,D.lookahead>=3&&(D.ins_h=(D.ins_h<<D.hash_shift^D.window[D.strstart+3-1])&D.hash_mask,M=D.prev[D.strstart&D.w_mask]=D.head[D.ins_h],D.head[D.ins_h]=D.strstart),D.prev_length=D.match_length,D.prev_match=D.match_start,D.match_length=2,M!==0&&D.prev_length<D.max_lazy_match&&D.strstart-M<=D.w_size-I&&(D.match_length=w(D,M),D.match_length<=5&&(D.strategy===1||D.match_length===3&&4096<D.strstart-D.match_start)&&(D.match_length=2)),D.prev_length>=3&&D.match_length<=D.prev_length){for($=D.strstart+D.lookahead-3,j=g._tr_tally(D,D.strstart-1-D.prev_match,D.prev_length-3),D.lookahead-=D.prev_length-1,D.prev_length-=2;++D.strstart<=$&&(D.ins_h=(D.ins_h<<D.hash_shift^D.window[D.strstart+3-1])&D.hash_mask,M=D.prev[D.strstart&D.w_mask]=D.head[D.ins_h],D.head[D.ins_h]=D.strstart),--D.prev_length!=0;);if(D.match_available=0,D.match_length=2,D.strstart++,j&&(P(D,!1),D.strm.avail_out===0))return 1}else if(D.match_available){if((j=g._tr_tally(D,0,D.window[D.strstart-1]))&&P(D,!1),D.strstart++,D.lookahead--,D.strm.avail_out===0)return 1}else D.match_available=1,D.strstart++,D.lookahead--}return D.match_available&&(j=g._tr_tally(D,0,D.window[D.strstart-1]),D.match_available=0),D.insert=D.strstart<2?D.strstart:2,q===4?(P(D,!0),D.strm.avail_out===0?3:4):D.last_lit&&(P(D,!1),D.strm.avail_out===0)?1:2}function O(D,q,M,j,$){this.good_length=D,this.max_lazy=q,this.nice_length=M,this.max_chain=j,this.func=$}function N(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=8,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new v.Buf16(1146),this.dyn_dtree=new v.Buf16(122),this.bl_tree=new v.Buf16(78),z(this.dyn_ltree),z(this.dyn_dtree),z(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new v.Buf16(16),this.heap=new v.Buf16(573),z(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new v.Buf16(573),z(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function U(D){var q;return D&&D.state?(D.total_in=D.total_out=0,D.data_type=2,(q=D.state).pending=0,q.pending_out=0,q.wrap<0&&(q.wrap=-q.wrap),q.status=q.wrap?42:F,D.adler=q.wrap===2?0:1,q.last_flush=0,g._tr_init(q),0):L(D,R)}function H(D){var q=U(D);return q===0&&function(M){M.window_size=2*M.w_size,z(M.head),M.max_lazy_match=p[M.level].max_lazy,M.good_match=p[M.level].good_length,M.nice_match=p[M.level].nice_length,M.max_chain_length=p[M.level].max_chain,M.strstart=0,M.block_start=0,M.lookahead=0,M.insert=0,M.match_length=M.prev_length=2,M.match_available=0,M.ins_h=0}(D.state),q}function Z(D,q,M,j,$,K){if(!D)return R;var J=1;if(q===-1&&(q=6),j<0?(J=0,j=-j):15<j&&(J=2,j-=16),$<1||9<$||M!==8||j<8||15<j||q<0||9<q||K<0||4<K)return L(D,R);j===8&&(j=9);var X=new N;return(D.state=X).strm=D,X.wrap=J,X.gzhead=null,X.w_bits=j,X.w_size=1<<X.w_bits,X.w_mask=X.w_size-1,X.hash_bits=$+7,X.hash_size=1<<X.hash_bits,X.hash_mask=X.hash_size-1,X.hash_shift=~~((X.hash_bits+3-1)/3),X.window=new v.Buf8(2*X.w_size),X.head=new v.Buf16(X.hash_size),X.prev=new v.Buf16(X.w_size),X.lit_bufsize=1<<$+6,X.pending_buf_size=4*X.lit_bufsize,X.pending_buf=new v.Buf8(X.pending_buf_size),X.d_buf=1*X.lit_bufsize,X.l_buf=3*X.lit_bufsize,X.level=q,X.strategy=K,X.method=M,H(D)}p=[new O(0,0,0,0,function(D,q){var M=65535;for(M>D.pending_buf_size-5&&(M=D.pending_buf_size-5);;){if(D.lookahead<=1){if(_(D),D.lookahead===0&&q===0)return 1;if(D.lookahead===0)break}D.strstart+=D.lookahead,D.lookahead=0;var j=D.block_start+M;if((D.strstart===0||D.strstart>=j)&&(D.lookahead=D.strstart-j,D.strstart=j,P(D,!1),D.strm.avail_out===0)||D.strstart-D.block_start>=D.w_size-I&&(P(D,!1),D.strm.avail_out===0))return 1}return D.insert=0,q===4?(P(D,!0),D.strm.avail_out===0?3:4):(D.strstart>D.block_start&&(P(D,!1),D.strm.avail_out),1)}),new O(4,4,8,4,S),new O(4,5,16,8,S),new O(4,6,32,32,S),new O(4,4,16,16,A),new O(8,16,32,32,A),new O(8,16,128,128,A),new O(8,32,128,256,A),new O(32,128,258,1024,A),new O(32,258,258,4096,A)],b.deflateInit=function(D,q){return Z(D,q,8,15,8,0)},b.deflateInit2=Z,b.deflateReset=H,b.deflateResetKeep=U,b.deflateSetHeader=function(D,q){return D&&D.state?D.state.wrap!==2?R:(D.state.gzhead=q,0):R},b.deflate=function(D,q){var M,j,$,K;if(!D||!D.state||5<q||q<0)return D?L(D,R):R;if(j=D.state,!D.output||!D.input&&D.avail_in!==0||j.status===666&&q!==4)return L(D,D.avail_out===0?-5:R);if(j.strm=D,M=j.last_flush,j.last_flush=q,j.status===42)if(j.wrap===2)D.adler=0,k(j,31),k(j,139),k(j,8),j.gzhead?(k(j,(j.gzhead.text?1:0)+(j.gzhead.hcrc?2:0)+(j.gzhead.extra?4:0)+(j.gzhead.name?8:0)+(j.gzhead.comment?16:0)),k(j,255&j.gzhead.time),k(j,j.gzhead.time>>8&255),k(j,j.gzhead.time>>16&255),k(j,j.gzhead.time>>24&255),k(j,j.level===9?2:2<=j.strategy||j.level<2?4:0),k(j,255&j.gzhead.os),j.gzhead.extra&&j.gzhead.extra.length&&(k(j,255&j.gzhead.extra.length),k(j,j.gzhead.extra.length>>8&255)),j.gzhead.hcrc&&(D.adler=C(D.adler,j.pending_buf,j.pending,0)),j.gzindex=0,j.status=69):(k(j,0),k(j,0),k(j,0),k(j,0),k(j,0),k(j,j.level===9?2:2<=j.strategy||j.level<2?4:0),k(j,3),j.status=F);else{var J=8+(j.w_bits-8<<4)<<8;J|=(2<=j.strategy||j.level<2?0:j.level<6?1:j.level===6?2:3)<<6,j.strstart!==0&&(J|=32),J+=31-J%31,j.status=F,y(j,J),j.strstart!==0&&(y(j,D.adler>>>16),y(j,65535&D.adler)),D.adler=1}if(j.status===69)if(j.gzhead.extra){for($=j.pending;j.gzindex<(65535&j.gzhead.extra.length)&&(j.pending!==j.pending_buf_size||(j.gzhead.hcrc&&j.pending>$&&(D.adler=C(D.adler,j.pending_buf,j.pending-$,$)),E(D),$=j.pending,j.pending!==j.pending_buf_size));)k(j,255&j.gzhead.extra[j.gzindex]),j.gzindex++;j.gzhead.hcrc&&j.pending>$&&(D.adler=C(D.adler,j.pending_buf,j.pending-$,$)),j.gzindex===j.gzhead.extra.length&&(j.gzindex=0,j.status=73)}else j.status=73;if(j.status===73)if(j.gzhead.name){$=j.pending;do{if(j.pending===j.pending_buf_size&&(j.gzhead.hcrc&&j.pending>$&&(D.adler=C(D.adler,j.pending_buf,j.pending-$,$)),E(D),$=j.pending,j.pending===j.pending_buf_size)){K=1;break}K=j.gzindex<j.gzhead.name.length?255&j.gzhead.name.charCodeAt(j.gzindex++):0,k(j,K)}while(K!==0);j.gzhead.hcrc&&j.pending>$&&(D.adler=C(D.adler,j.pending_buf,j.pending-$,$)),K===0&&(j.gzindex=0,j.status=91)}else j.status=91;if(j.status===91)if(j.gzhead.comment){$=j.pending;do{if(j.pending===j.pending_buf_size&&(j.gzhead.hcrc&&j.pending>$&&(D.adler=C(D.adler,j.pending_buf,j.pending-$,$)),E(D),$=j.pending,j.pending===j.pending_buf_size)){K=1;break}K=j.gzindex<j.gzhead.comment.length?255&j.gzhead.comment.charCodeAt(j.gzindex++):0,k(j,K)}while(K!==0);j.gzhead.hcrc&&j.pending>$&&(D.adler=C(D.adler,j.pending_buf,j.pending-$,$)),K===0&&(j.status=103)}else j.status=103;if(j.status===103&&(j.gzhead.hcrc?(j.pending+2>j.pending_buf_size&&E(D),j.pending+2<=j.pending_buf_size&&(k(j,255&D.adler),k(j,D.adler>>8&255),D.adler=0,j.status=F)):j.status=F),j.pending!==0){if(E(D),D.avail_out===0)return j.last_flush=-1,0}else if(D.avail_in===0&&V(q)<=V(M)&&q!==4)return L(D,-5);if(j.status===666&&D.avail_in!==0)return L(D,-5);if(D.avail_in!==0||j.lookahead!==0||q!==0&&j.status!==666){var X=j.strategy===2?function(Q,ee){for(var se;;){if(Q.lookahead===0&&(_(Q),Q.lookahead===0)){if(ee===0)return 1;break}if(Q.match_length=0,se=g._tr_tally(Q,0,Q.window[Q.strstart]),Q.lookahead--,Q.strstart++,se&&(P(Q,!1),Q.strm.avail_out===0))return 1}return Q.insert=0,ee===4?(P(Q,!0),Q.strm.avail_out===0?3:4):Q.last_lit&&(P(Q,!1),Q.strm.avail_out===0)?1:2}(j,q):j.strategy===3?function(Q,ee){for(var se,Y,te,ne,oe=Q.window;;){if(Q.lookahead<=B){if(_(Q),Q.lookahead<=B&&ee===0)return 1;if(Q.lookahead===0)break}if(Q.match_length=0,Q.lookahead>=3&&0<Q.strstart&&(Y=oe[te=Q.strstart-1])===oe[++te]&&Y===oe[++te]&&Y===oe[++te]){ne=Q.strstart+B;do;while(Y===oe[++te]&&Y===oe[++te]&&Y===oe[++te]&&Y===oe[++te]&&Y===oe[++te]&&Y===oe[++te]&&Y===oe[++te]&&Y===oe[++te]&&te<ne);Q.match_length=B-(ne-te),Q.match_length>Q.lookahead&&(Q.match_length=Q.lookahead)}if(Q.match_length>=3?(se=g._tr_tally(Q,1,Q.match_length-3),Q.lookahead-=Q.match_length,Q.strstart+=Q.match_length,Q.match_length=0):(se=g._tr_tally(Q,0,Q.window[Q.strstart]),Q.lookahead--,Q.strstart++),se&&(P(Q,!1),Q.strm.avail_out===0))return 1}return Q.insert=0,ee===4?(P(Q,!0),Q.strm.avail_out===0?3:4):Q.last_lit&&(P(Q,!1),Q.strm.avail_out===0)?1:2}(j,q):p[j.level].func(j,q);if(X!==3&&X!==4||(j.status=666),X===1||X===3)return D.avail_out===0&&(j.last_flush=-1),0;if(X===2&&(q===1?g._tr_align(j):q!==5&&(g._tr_stored_block(j,0,0,!1),q===3&&(z(j.head),j.lookahead===0&&(j.strstart=0,j.block_start=0,j.insert=0))),E(D),D.avail_out===0))return j.last_flush=-1,0}return q!==4?0:j.wrap<=0?1:(j.wrap===2?(k(j,255&D.adler),k(j,D.adler>>8&255),k(j,D.adler>>16&255),k(j,D.adler>>24&255),k(j,255&D.total_in),k(j,D.total_in>>8&255),k(j,D.total_in>>16&255),k(j,D.total_in>>24&255)):(y(j,D.adler>>>16),y(j,65535&D.adler)),E(D),0<j.wrap&&(j.wrap=-j.wrap),j.pending!==0?0:1)},b.deflateEnd=function(D){var q;return D&&D.state?(q=D.state.status)!==42&&q!==69&&q!==73&&q!==91&&q!==103&&q!==F&&q!==666?L(D,R):(D.state=null,q===F?L(D,-3):0):R},b.deflateSetDictionary=function(D,q){var M,j,$,K,J,X,Q,ee,se=q.length;if(!D||!D.state||(K=(M=D.state).wrap)===2||K===1&&M.status!==42||M.lookahead)return R;for(K===1&&(D.adler=x(D.adler,q,se,0)),M.wrap=0,se>=M.w_size&&(K===0&&(z(M.head),M.strstart=0,M.block_start=0,M.insert=0),ee=new v.Buf8(M.w_size),v.arraySet(ee,q,se-M.w_size,M.w_size,0),q=ee,se=M.w_size),J=D.avail_in,X=D.next_in,Q=D.input,D.avail_in=se,D.next_in=0,D.input=q,_(M);M.lookahead>=3;){for(j=M.strstart,$=M.lookahead-2;M.ins_h=(M.ins_h<<M.hash_shift^M.window[j+3-1])&M.hash_mask,M.prev[j&M.w_mask]=M.head[M.ins_h],M.head[M.ins_h]=j,j++,--$;);M.strstart=j,M.lookahead=2,_(M)}return M.strstart+=M.lookahead,M.block_start=M.strstart,M.insert=M.lookahead,M.lookahead=0,M.match_length=M.prev_length=2,M.match_available=0,D.next_in=X,D.input=Q,D.avail_in=J,M.wrap=K,0},b.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./messages":51,"./trees":52}],47:[function(d,m,b){m.exports=function(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}},{}],48:[function(d,m,b){m.exports=function(p,v){var g,x,C,T,R,B,I,F,L,V,z,E,P,k,y,w,_,S,A,O,N,U,H,Z,D;g=p.state,x=p.next_in,Z=p.input,C=x+(p.avail_in-5),T=p.next_out,D=p.output,R=T-(v-p.avail_out),B=T+(p.avail_out-257),I=g.dmax,F=g.wsize,L=g.whave,V=g.wnext,z=g.window,E=g.hold,P=g.bits,k=g.lencode,y=g.distcode,w=(1<<g.lenbits)-1,_=(1<<g.distbits)-1;e:do{P<15&&(E+=Z[x++]<<P,P+=8,E+=Z[x++]<<P,P+=8),S=k[E&w];t:for(;;){if(E>>>=A=S>>>24,P-=A,(A=S>>>16&255)==0)D[T++]=65535&S;else{if(!(16&A)){if((64&A)==0){S=k[(65535&S)+(E&(1<<A)-1)];continue t}if(32&A){g.mode=12;break e}p.msg="invalid literal/length code",g.mode=30;break e}O=65535&S,(A&=15)&&(P<A&&(E+=Z[x++]<<P,P+=8),O+=E&(1<<A)-1,E>>>=A,P-=A),P<15&&(E+=Z[x++]<<P,P+=8,E+=Z[x++]<<P,P+=8),S=y[E&_];r:for(;;){if(E>>>=A=S>>>24,P-=A,!(16&(A=S>>>16&255))){if((64&A)==0){S=y[(65535&S)+(E&(1<<A)-1)];continue r}p.msg="invalid distance code",g.mode=30;break e}if(N=65535&S,P<(A&=15)&&(E+=Z[x++]<<P,(P+=8)<A&&(E+=Z[x++]<<P,P+=8)),I<(N+=E&(1<<A)-1)){p.msg="invalid distance too far back",g.mode=30;break e}if(E>>>=A,P-=A,(A=T-R)<N){if(L<(A=N-A)&&g.sane){p.msg="invalid distance too far back",g.mode=30;break e}if(H=z,(U=0)===V){if(U+=F-A,A<O){for(O-=A;D[T++]=z[U++],--A;);U=T-N,H=D}}else if(V<A){if(U+=F+V-A,(A-=V)<O){for(O-=A;D[T++]=z[U++],--A;);if(U=0,V<O){for(O-=A=V;D[T++]=z[U++],--A;);U=T-N,H=D}}}else if(U+=V-A,A<O){for(O-=A;D[T++]=z[U++],--A;);U=T-N,H=D}for(;2<O;)D[T++]=H[U++],D[T++]=H[U++],D[T++]=H[U++],O-=3;O&&(D[T++]=H[U++],1<O&&(D[T++]=H[U++]))}else{for(U=T-N;D[T++]=D[U++],D[T++]=D[U++],D[T++]=D[U++],2<(O-=3););O&&(D[T++]=D[U++],1<O&&(D[T++]=D[U++]))}break}}break}}while(x<C&&T<B);x-=O=P>>3,E&=(1<<(P-=O<<3))-1,p.next_in=x,p.next_out=T,p.avail_in=x<C?C-x+5:5-(x-C),p.avail_out=T<B?B-T+257:257-(T-B),g.hold=E,g.bits=P}},{}],49:[function(d,m,b){var p=d("../utils/common"),v=d("./adler32"),g=d("./crc32"),x=d("./inffast"),C=d("./inftrees"),T=-2;function R(w){return(w>>>24&255)+(w>>>8&65280)+((65280&w)<<8)+((255&w)<<24)}function B(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new p.Buf16(320),this.work=new p.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function I(w){var _;return w&&w.state?(_=w.state,w.total_in=w.total_out=_.total=0,w.msg="",_.wrap&&(w.adler=1&_.wrap),_.mode=1,_.last=0,_.havedict=0,_.dmax=32768,_.head=null,_.hold=0,_.bits=0,_.lencode=_.lendyn=new p.Buf32(852),_.distcode=_.distdyn=new p.Buf32(592),_.sane=1,_.back=-1,0):T}function F(w){var _;return w&&w.state?((_=w.state).wsize=0,_.whave=0,_.wnext=0,I(w)):T}function L(w,_){var S,A;return w&&w.state?(A=w.state,_<0?(S=0,_=-_):(S=1+(_>>4),_<48&&(_&=15)),_&&(_<8||15<_)?T:(A.window!==null&&A.wbits!==_&&(A.window=null),A.wrap=S,A.wbits=_,F(w))):T}function V(w,_){var S,A;return w?(A=new B,(w.state=A).window=null,(S=L(w,_))!==0&&(w.state=null),S):T}var z,E,P=!0;function k(w){if(P){var _;for(z=new p.Buf32(512),E=new p.Buf32(32),_=0;_<144;)w.lens[_++]=8;for(;_<256;)w.lens[_++]=9;for(;_<280;)w.lens[_++]=7;for(;_<288;)w.lens[_++]=8;for(C(1,w.lens,0,288,z,0,w.work,{bits:9}),_=0;_<32;)w.lens[_++]=5;C(2,w.lens,0,32,E,0,w.work,{bits:5}),P=!1}w.lencode=z,w.lenbits=9,w.distcode=E,w.distbits=5}function y(w,_,S,A){var O,N=w.state;return N.window===null&&(N.wsize=1<<N.wbits,N.wnext=0,N.whave=0,N.window=new p.Buf8(N.wsize)),A>=N.wsize?(p.arraySet(N.window,_,S-N.wsize,N.wsize,0),N.wnext=0,N.whave=N.wsize):(A<(O=N.wsize-N.wnext)&&(O=A),p.arraySet(N.window,_,S-A,O,N.wnext),(A-=O)?(p.arraySet(N.window,_,S-A,A,0),N.wnext=A,N.whave=N.wsize):(N.wnext+=O,N.wnext===N.wsize&&(N.wnext=0),N.whave<N.wsize&&(N.whave+=O))),0}b.inflateReset=F,b.inflateReset2=L,b.inflateResetKeep=I,b.inflateInit=function(w){return V(w,15)},b.inflateInit2=V,b.inflate=function(w,_){var S,A,O,N,U,H,Z,D,q,M,j,$,K,J,X,Q,ee,se,Y,te,ne,oe,ae,ce,me=0,be=new p.Buf8(4),ye=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!w||!w.state||!w.output||!w.input&&w.avail_in!==0)return T;(S=w.state).mode===12&&(S.mode=13),U=w.next_out,O=w.output,Z=w.avail_out,N=w.next_in,A=w.input,H=w.avail_in,D=S.hold,q=S.bits,M=H,j=Z,oe=0;e:for(;;)switch(S.mode){case 1:if(S.wrap===0){S.mode=13;break}for(;q<16;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}if(2&S.wrap&&D===35615){be[S.check=0]=255&D,be[1]=D>>>8&255,S.check=g(S.check,be,2,0),q=D=0,S.mode=2;break}if(S.flags=0,S.head&&(S.head.done=!1),!(1&S.wrap)||(((255&D)<<8)+(D>>8))%31){w.msg="incorrect header check",S.mode=30;break}if((15&D)!=8){w.msg="unknown compression method",S.mode=30;break}if(q-=4,ne=8+(15&(D>>>=4)),S.wbits===0)S.wbits=ne;else if(ne>S.wbits){w.msg="invalid window size",S.mode=30;break}S.dmax=1<<ne,w.adler=S.check=1,S.mode=512&D?10:12,q=D=0;break;case 2:for(;q<16;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}if(S.flags=D,(255&S.flags)!=8){w.msg="unknown compression method",S.mode=30;break}if(57344&S.flags){w.msg="unknown header flags set",S.mode=30;break}S.head&&(S.head.text=D>>8&1),512&S.flags&&(be[0]=255&D,be[1]=D>>>8&255,S.check=g(S.check,be,2,0)),q=D=0,S.mode=3;case 3:for(;q<32;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}S.head&&(S.head.time=D),512&S.flags&&(be[0]=255&D,be[1]=D>>>8&255,be[2]=D>>>16&255,be[3]=D>>>24&255,S.check=g(S.check,be,4,0)),q=D=0,S.mode=4;case 4:for(;q<16;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}S.head&&(S.head.xflags=255&D,S.head.os=D>>8),512&S.flags&&(be[0]=255&D,be[1]=D>>>8&255,S.check=g(S.check,be,2,0)),q=D=0,S.mode=5;case 5:if(1024&S.flags){for(;q<16;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}S.length=D,S.head&&(S.head.extra_len=D),512&S.flags&&(be[0]=255&D,be[1]=D>>>8&255,S.check=g(S.check,be,2,0)),q=D=0}else S.head&&(S.head.extra=null);S.mode=6;case 6:if(1024&S.flags&&(H<($=S.length)&&($=H),$&&(S.head&&(ne=S.head.extra_len-S.length,S.head.extra||(S.head.extra=new Array(S.head.extra_len)),p.arraySet(S.head.extra,A,N,$,ne)),512&S.flags&&(S.check=g(S.check,A,$,N)),H-=$,N+=$,S.length-=$),S.length))break e;S.length=0,S.mode=7;case 7:if(2048&S.flags){if(H===0)break e;for($=0;ne=A[N+$++],S.head&&ne&&S.length<65536&&(S.head.name+=String.fromCharCode(ne)),ne&&$<H;);if(512&S.flags&&(S.check=g(S.check,A,$,N)),H-=$,N+=$,ne)break e}else S.head&&(S.head.name=null);S.length=0,S.mode=8;case 8:if(4096&S.flags){if(H===0)break e;for($=0;ne=A[N+$++],S.head&&ne&&S.length<65536&&(S.head.comment+=String.fromCharCode(ne)),ne&&$<H;);if(512&S.flags&&(S.check=g(S.check,A,$,N)),H-=$,N+=$,ne)break e}else S.head&&(S.head.comment=null);S.mode=9;case 9:if(512&S.flags){for(;q<16;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}if(D!==(65535&S.check)){w.msg="header crc mismatch",S.mode=30;break}q=D=0}S.head&&(S.head.hcrc=S.flags>>9&1,S.head.done=!0),w.adler=S.check=0,S.mode=12;break;case 10:for(;q<32;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}w.adler=S.check=R(D),q=D=0,S.mode=11;case 11:if(S.havedict===0)return w.next_out=U,w.avail_out=Z,w.next_in=N,w.avail_in=H,S.hold=D,S.bits=q,2;w.adler=S.check=1,S.mode=12;case 12:if(_===5||_===6)break e;case 13:if(S.last){D>>>=7&q,q-=7&q,S.mode=27;break}for(;q<3;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}switch(S.last=1&D,q-=1,3&(D>>>=1)){case 0:S.mode=14;break;case 1:if(k(S),S.mode=20,_!==6)break;D>>>=2,q-=2;break e;case 2:S.mode=17;break;case 3:w.msg="invalid block type",S.mode=30}D>>>=2,q-=2;break;case 14:for(D>>>=7&q,q-=7&q;q<32;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}if((65535&D)!=(D>>>16^65535)){w.msg="invalid stored block lengths",S.mode=30;break}if(S.length=65535&D,q=D=0,S.mode=15,_===6)break e;case 15:S.mode=16;case 16:if($=S.length){if(H<$&&($=H),Z<$&&($=Z),$===0)break e;p.arraySet(O,A,N,$,U),H-=$,N+=$,Z-=$,U+=$,S.length-=$;break}S.mode=12;break;case 17:for(;q<14;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}if(S.nlen=257+(31&D),D>>>=5,q-=5,S.ndist=1+(31&D),D>>>=5,q-=5,S.ncode=4+(15&D),D>>>=4,q-=4,286<S.nlen||30<S.ndist){w.msg="too many length or distance symbols",S.mode=30;break}S.have=0,S.mode=18;case 18:for(;S.have<S.ncode;){for(;q<3;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}S.lens[ye[S.have++]]=7&D,D>>>=3,q-=3}for(;S.have<19;)S.lens[ye[S.have++]]=0;if(S.lencode=S.lendyn,S.lenbits=7,ae={bits:S.lenbits},oe=C(0,S.lens,0,19,S.lencode,0,S.work,ae),S.lenbits=ae.bits,oe){w.msg="invalid code lengths set",S.mode=30;break}S.have=0,S.mode=19;case 19:for(;S.have<S.nlen+S.ndist;){for(;Q=(me=S.lencode[D&(1<<S.lenbits)-1])>>>16&255,ee=65535&me,!((X=me>>>24)<=q);){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}if(ee<16)D>>>=X,q-=X,S.lens[S.have++]=ee;else{if(ee===16){for(ce=X+2;q<ce;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}if(D>>>=X,q-=X,S.have===0){w.msg="invalid bit length repeat",S.mode=30;break}ne=S.lens[S.have-1],$=3+(3&D),D>>>=2,q-=2}else if(ee===17){for(ce=X+3;q<ce;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}q-=X,ne=0,$=3+(7&(D>>>=X)),D>>>=3,q-=3}else{for(ce=X+7;q<ce;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}q-=X,ne=0,$=11+(127&(D>>>=X)),D>>>=7,q-=7}if(S.have+$>S.nlen+S.ndist){w.msg="invalid bit length repeat",S.mode=30;break}for(;$--;)S.lens[S.have++]=ne}}if(S.mode===30)break;if(S.lens[256]===0){w.msg="invalid code -- missing end-of-block",S.mode=30;break}if(S.lenbits=9,ae={bits:S.lenbits},oe=C(1,S.lens,0,S.nlen,S.lencode,0,S.work,ae),S.lenbits=ae.bits,oe){w.msg="invalid literal/lengths set",S.mode=30;break}if(S.distbits=6,S.distcode=S.distdyn,ae={bits:S.distbits},oe=C(2,S.lens,S.nlen,S.ndist,S.distcode,0,S.work,ae),S.distbits=ae.bits,oe){w.msg="invalid distances set",S.mode=30;break}if(S.mode=20,_===6)break e;case 20:S.mode=21;case 21:if(6<=H&&258<=Z){w.next_out=U,w.avail_out=Z,w.next_in=N,w.avail_in=H,S.hold=D,S.bits=q,x(w,j),U=w.next_out,O=w.output,Z=w.avail_out,N=w.next_in,A=w.input,H=w.avail_in,D=S.hold,q=S.bits,S.mode===12&&(S.back=-1);break}for(S.back=0;Q=(me=S.lencode[D&(1<<S.lenbits)-1])>>>16&255,ee=65535&me,!((X=me>>>24)<=q);){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}if(Q&&(240&Q)==0){for(se=X,Y=Q,te=ee;Q=(me=S.lencode[te+((D&(1<<se+Y)-1)>>se)])>>>16&255,ee=65535&me,!(se+(X=me>>>24)<=q);){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}D>>>=se,q-=se,S.back+=se}if(D>>>=X,q-=X,S.back+=X,S.length=ee,Q===0){S.mode=26;break}if(32&Q){S.back=-1,S.mode=12;break}if(64&Q){w.msg="invalid literal/length code",S.mode=30;break}S.extra=15&Q,S.mode=22;case 22:if(S.extra){for(ce=S.extra;q<ce;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}S.length+=D&(1<<S.extra)-1,D>>>=S.extra,q-=S.extra,S.back+=S.extra}S.was=S.length,S.mode=23;case 23:for(;Q=(me=S.distcode[D&(1<<S.distbits)-1])>>>16&255,ee=65535&me,!((X=me>>>24)<=q);){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}if((240&Q)==0){for(se=X,Y=Q,te=ee;Q=(me=S.distcode[te+((D&(1<<se+Y)-1)>>se)])>>>16&255,ee=65535&me,!(se+(X=me>>>24)<=q);){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}D>>>=se,q-=se,S.back+=se}if(D>>>=X,q-=X,S.back+=X,64&Q){w.msg="invalid distance code",S.mode=30;break}S.offset=ee,S.extra=15&Q,S.mode=24;case 24:if(S.extra){for(ce=S.extra;q<ce;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}S.offset+=D&(1<<S.extra)-1,D>>>=S.extra,q-=S.extra,S.back+=S.extra}if(S.offset>S.dmax){w.msg="invalid distance too far back",S.mode=30;break}S.mode=25;case 25:if(Z===0)break e;if($=j-Z,S.offset>$){if(($=S.offset-$)>S.whave&&S.sane){w.msg="invalid distance too far back",S.mode=30;break}K=$>S.wnext?($-=S.wnext,S.wsize-$):S.wnext-$,$>S.length&&($=S.length),J=S.window}else J=O,K=U-S.offset,$=S.length;for(Z<$&&($=Z),Z-=$,S.length-=$;O[U++]=J[K++],--$;);S.length===0&&(S.mode=21);break;case 26:if(Z===0)break e;O[U++]=S.length,Z--,S.mode=21;break;case 27:if(S.wrap){for(;q<32;){if(H===0)break e;H--,D|=A[N++]<<q,q+=8}if(j-=Z,w.total_out+=j,S.total+=j,j&&(w.adler=S.check=S.flags?g(S.check,O,j,U-j):v(S.check,O,j,U-j)),j=Z,(S.flags?D:R(D))!==S.check){w.msg="incorrect data check",S.mode=30;break}q=D=0}S.mode=28;case 28:if(S.wrap&&S.flags){for(;q<32;){if(H===0)break e;H--,D+=A[N++]<<q,q+=8}if(D!==(4294967295&S.total)){w.msg="incorrect length check",S.mode=30;break}q=D=0}S.mode=29;case 29:oe=1;break e;case 30:oe=-3;break e;case 31:return-4;case 32:default:return T}return w.next_out=U,w.avail_out=Z,w.next_in=N,w.avail_in=H,S.hold=D,S.bits=q,(S.wsize||j!==w.avail_out&&S.mode<30&&(S.mode<27||_!==4))&&y(w,w.output,w.next_out,j-w.avail_out)?(S.mode=31,-4):(M-=w.avail_in,j-=w.avail_out,w.total_in+=M,w.total_out+=j,S.total+=j,S.wrap&&j&&(w.adler=S.check=S.flags?g(S.check,O,j,w.next_out-j):v(S.check,O,j,w.next_out-j)),w.data_type=S.bits+(S.last?64:0)+(S.mode===12?128:0)+(S.mode===20||S.mode===15?256:0),(M==0&&j===0||_===4)&&oe===0&&(oe=-5),oe)},b.inflateEnd=function(w){if(!w||!w.state)return T;var _=w.state;return _.window&&(_.window=null),w.state=null,0},b.inflateGetHeader=function(w,_){var S;return w&&w.state?(2&(S=w.state).wrap)==0?T:((S.head=_).done=!1,0):T},b.inflateSetDictionary=function(w,_){var S,A=_.length;return w&&w.state?(S=w.state).wrap!==0&&S.mode!==11?T:S.mode===11&&v(1,_,A,0)!==S.check?-3:y(w,_,A,A)?(S.mode=31,-4):(S.havedict=1,0):T},b.inflateInfo="pako inflate (from Nodeca project)"},{"../utils/common":41,"./adler32":43,"./crc32":45,"./inffast":48,"./inftrees":50}],50:[function(d,m,b){var p=d("../utils/common"),v=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],g=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],x=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],C=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];m.exports=function(T,R,B,I,F,L,V,z){var E,P,k,y,w,_,S,A,O,N=z.bits,U=0,H=0,Z=0,D=0,q=0,M=0,j=0,$=0,K=0,J=0,X=null,Q=0,ee=new p.Buf16(16),se=new p.Buf16(16),Y=null,te=0;for(U=0;U<=15;U++)ee[U]=0;for(H=0;H<I;H++)ee[R[B+H]]++;for(q=N,D=15;1<=D&&ee[D]===0;D--);if(D<q&&(q=D),D===0)return F[L++]=20971520,F[L++]=20971520,z.bits=1,0;for(Z=1;Z<D&&ee[Z]===0;Z++);for(q<Z&&(q=Z),U=$=1;U<=15;U++)if($<<=1,($-=ee[U])<0)return-1;if(0<$&&(T===0||D!==1))return-1;for(se[1]=0,U=1;U<15;U++)se[U+1]=se[U]+ee[U];for(H=0;H<I;H++)R[B+H]!==0&&(V[se[R[B+H]]++]=H);if(_=T===0?(X=Y=V,19):T===1?(X=v,Q-=257,Y=g,te-=257,256):(X=x,Y=C,-1),U=Z,w=L,j=H=J=0,k=-1,y=(K=1<<(M=q))-1,T===1&&852<K||T===2&&592<K)return 1;for(;;){for(S=U-j,O=V[H]<_?(A=0,V[H]):V[H]>_?(A=Y[te+V[H]],X[Q+V[H]]):(A=96,0),E=1<<U-j,Z=P=1<<M;F[w+(J>>j)+(P-=E)]=S<<24|A<<16|O|0,P!==0;);for(E=1<<U-1;J&E;)E>>=1;if(E!==0?(J&=E-1,J+=E):J=0,H++,--ee[U]==0){if(U===D)break;U=R[B+V[H]]}if(q<U&&(J&y)!==k){for(j===0&&(j=q),w+=Z,$=1<<(M=U-j);M+j<D&&!(($-=ee[M+j])<=0);)M++,$<<=1;if(K+=1<<M,T===1&&852<K||T===2&&592<K)return 1;F[k=J&y]=q<<24|M<<16|w-L|0}}return J!==0&&(F[w+J]=U-j<<24|64<<16|0),z.bits=q,0}},{"../utils/common":41}],51:[function(d,m,b){m.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],52:[function(d,m,b){var p=d("../utils/common");function v(Y){for(var te=Y.length;0<=--te;)Y[te]=0}var g=256,x=286,C=30,T=15,R=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],B=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],I=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],F=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],L=new Array(576);v(L);var V=new Array(60);v(V);var z=new Array(512);v(z);var E=new Array(256);v(E);var P=new Array(29);v(P);var k,y,w,_=new Array(C);function S(Y,te,ne,oe,ae){this.static_tree=Y,this.extra_bits=te,this.extra_base=ne,this.elems=oe,this.max_length=ae,this.has_stree=Y&&Y.length}function A(Y,te){this.dyn_tree=Y,this.max_code=0,this.stat_desc=te}function O(Y){return Y<256?z[Y]:z[256+(Y>>>7)]}function N(Y,te){Y.pending_buf[Y.pending++]=255&te,Y.pending_buf[Y.pending++]=te>>>8&255}function U(Y,te,ne){Y.bi_valid>16-ne?(Y.bi_buf|=te<<Y.bi_valid&65535,N(Y,Y.bi_buf),Y.bi_buf=te>>16-Y.bi_valid,Y.bi_valid+=ne-16):(Y.bi_buf|=te<<Y.bi_valid&65535,Y.bi_valid+=ne)}function H(Y,te,ne){U(Y,ne[2*te],ne[2*te+1])}function Z(Y,te){for(var ne=0;ne|=1&Y,Y>>>=1,ne<<=1,0<--te;);return ne>>>1}function D(Y,te,ne){var oe,ae,ce=new Array(16),me=0;for(oe=1;oe<=T;oe++)ce[oe]=me=me+ne[oe-1]<<1;for(ae=0;ae<=te;ae++){var be=Y[2*ae+1];be!==0&&(Y[2*ae]=Z(ce[be]++,be))}}function q(Y){var te;for(te=0;te<x;te++)Y.dyn_ltree[2*te]=0;for(te=0;te<C;te++)Y.dyn_dtree[2*te]=0;for(te=0;te<19;te++)Y.bl_tree[2*te]=0;Y.dyn_ltree[512]=1,Y.opt_len=Y.static_len=0,Y.last_lit=Y.matches=0}function M(Y){8<Y.bi_valid?N(Y,Y.bi_buf):0<Y.bi_valid&&(Y.pending_buf[Y.pending++]=Y.bi_buf),Y.bi_buf=0,Y.bi_valid=0}function j(Y,te,ne,oe){var ae=2*te,ce=2*ne;return Y[ae]<Y[ce]||Y[ae]===Y[ce]&&oe[te]<=oe[ne]}function $(Y,te,ne){for(var oe=Y.heap[ne],ae=ne<<1;ae<=Y.heap_len&&(ae<Y.heap_len&&j(te,Y.heap[ae+1],Y.heap[ae],Y.depth)&&ae++,!j(te,oe,Y.heap[ae],Y.depth));)Y.heap[ne]=Y.heap[ae],ne=ae,ae<<=1;Y.heap[ne]=oe}function K(Y,te,ne){var oe,ae,ce,me,be=0;if(Y.last_lit!==0)for(;oe=Y.pending_buf[Y.d_buf+2*be]<<8|Y.pending_buf[Y.d_buf+2*be+1],ae=Y.pending_buf[Y.l_buf+be],be++,oe===0?H(Y,ae,te):(H(Y,(ce=E[ae])+g+1,te),(me=R[ce])!==0&&U(Y,ae-=P[ce],me),H(Y,ce=O(--oe),ne),(me=B[ce])!==0&&U(Y,oe-=_[ce],me)),be<Y.last_lit;);H(Y,256,te)}function J(Y,te){var ne,oe,ae,ce=te.dyn_tree,me=te.stat_desc.static_tree,be=te.stat_desc.has_stree,ye=te.stat_desc.elems,Me=-1;for(Y.heap_len=0,Y.heap_max=573,ne=0;ne<ye;ne++)ce[2*ne]!==0?(Y.heap[++Y.heap_len]=Me=ne,Y.depth[ne]=0):ce[2*ne+1]=0;for(;Y.heap_len<2;)ce[2*(ae=Y.heap[++Y.heap_len]=Me<2?++Me:0)]=1,Y.depth[ae]=0,Y.opt_len--,be&&(Y.static_len-=me[2*ae+1]);for(te.max_code=Me,ne=Y.heap_len>>1;1<=ne;ne--)$(Y,ce,ne);for(ae=ye;ne=Y.heap[1],Y.heap[1]=Y.heap[Y.heap_len--],$(Y,ce,1),oe=Y.heap[1],Y.heap[--Y.heap_max]=ne,Y.heap[--Y.heap_max]=oe,ce[2*ae]=ce[2*ne]+ce[2*oe],Y.depth[ae]=(Y.depth[ne]>=Y.depth[oe]?Y.depth[ne]:Y.depth[oe])+1,ce[2*ne+1]=ce[2*oe+1]=ae,Y.heap[1]=ae++,$(Y,ce,1),2<=Y.heap_len;);Y.heap[--Y.heap_max]=Y.heap[1],function(Te,fe){var ke,Ee,Ne,De,je,Ce,Oe=fe.dyn_tree,Le=fe.max_code,Be=fe.stat_desc.static_tree,ct=fe.stat_desc.has_stree,wt=fe.stat_desc.extra_bits,We=fe.stat_desc.extra_base,dt=fe.stat_desc.max_length,ut=0;for(De=0;De<=T;De++)Te.bl_count[De]=0;for(Oe[2*Te.heap[Te.heap_max]+1]=0,ke=Te.heap_max+1;ke<573;ke++)dt<(De=Oe[2*Oe[2*(Ee=Te.heap[ke])+1]+1]+1)&&(De=dt,ut++),Oe[2*Ee+1]=De,Le<Ee||(Te.bl_count[De]++,je=0,We<=Ee&&(je=wt[Ee-We]),Ce=Oe[2*Ee],Te.opt_len+=Ce*(De+je),ct&&(Te.static_len+=Ce*(Be[2*Ee+1]+je)));if(ut!==0){do{for(De=dt-1;Te.bl_count[De]===0;)De--;Te.bl_count[De]--,Te.bl_count[De+1]+=2,Te.bl_count[dt]--,ut-=2}while(0<ut);for(De=dt;De!==0;De--)for(Ee=Te.bl_count[De];Ee!==0;)Le<(Ne=Te.heap[--ke])||(Oe[2*Ne+1]!==De&&(Te.opt_len+=(De-Oe[2*Ne+1])*Oe[2*Ne],Oe[2*Ne+1]=De),Ee--)}}(Y,te),D(ce,Me,Y.bl_count)}function X(Y,te,ne){var oe,ae,ce=-1,me=te[1],be=0,ye=7,Me=4;for(me===0&&(ye=138,Me=3),te[2*(ne+1)+1]=65535,oe=0;oe<=ne;oe++)ae=me,me=te[2*(oe+1)+1],++be<ye&&ae===me||(be<Me?Y.bl_tree[2*ae]+=be:ae!==0?(ae!==ce&&Y.bl_tree[2*ae]++,Y.bl_tree[32]++):be<=10?Y.bl_tree[34]++:Y.bl_tree[36]++,ce=ae,Me=(be=0)===me?(ye=138,3):ae===me?(ye=6,3):(ye=7,4))}function Q(Y,te,ne){var oe,ae,ce=-1,me=te[1],be=0,ye=7,Me=4;for(me===0&&(ye=138,Me=3),oe=0;oe<=ne;oe++)if(ae=me,me=te[2*(oe+1)+1],!(++be<ye&&ae===me)){if(be<Me)for(;H(Y,ae,Y.bl_tree),--be!=0;);else ae!==0?(ae!==ce&&(H(Y,ae,Y.bl_tree),be--),H(Y,16,Y.bl_tree),U(Y,be-3,2)):be<=10?(H(Y,17,Y.bl_tree),U(Y,be-3,3)):(H(Y,18,Y.bl_tree),U(Y,be-11,7));ce=ae,Me=(be=0)===me?(ye=138,3):ae===me?(ye=6,3):(ye=7,4)}}v(_);var ee=!1;function se(Y,te,ne,oe){U(Y,0+(oe?1:0),3),function(ae,ce,me,be){M(ae),N(ae,me),N(ae,~me),p.arraySet(ae.pending_buf,ae.window,ce,me,ae.pending),ae.pending+=me}(Y,te,ne)}b._tr_init=function(Y){ee||(function(){var te,ne,oe,ae,ce,me=new Array(16);for(ae=oe=0;ae<28;ae++)for(P[ae]=oe,te=0;te<1<<R[ae];te++)E[oe++]=ae;for(E[oe-1]=ae,ae=ce=0;ae<16;ae++)for(_[ae]=ce,te=0;te<1<<B[ae];te++)z[ce++]=ae;for(ce>>=7;ae<C;ae++)for(_[ae]=ce<<7,te=0;te<1<<B[ae]-7;te++)z[256+ce++]=ae;for(ne=0;ne<=T;ne++)me[ne]=0;for(te=0;te<=143;)L[2*te+1]=8,te++,me[8]++;for(;te<=255;)L[2*te+1]=9,te++,me[9]++;for(;te<=279;)L[2*te+1]=7,te++,me[7]++;for(;te<=287;)L[2*te+1]=8,te++,me[8]++;for(D(L,287,me),te=0;te<C;te++)V[2*te+1]=5,V[2*te]=Z(te,5);k=new S(L,R,257,x,T),y=new S(V,B,0,C,T),w=new S(new Array(0),I,0,19,7)}(),ee=!0),Y.l_desc=new A(Y.dyn_ltree,k),Y.d_desc=new A(Y.dyn_dtree,y),Y.bl_desc=new A(Y.bl_tree,w),Y.bi_buf=0,Y.bi_valid=0,q(Y)},b._tr_stored_block=se,b._tr_flush_block=function(Y,te,ne,oe){var ae,ce,me=0;0<Y.level?(Y.strm.data_type===2&&(Y.strm.data_type=function(be){var ye,Me=4093624447;for(ye=0;ye<=31;ye++,Me>>>=1)if(1&Me&&be.dyn_ltree[2*ye]!==0)return 0;if(be.dyn_ltree[18]!==0||be.dyn_ltree[20]!==0||be.dyn_ltree[26]!==0)return 1;for(ye=32;ye<g;ye++)if(be.dyn_ltree[2*ye]!==0)return 1;return 0}(Y)),J(Y,Y.l_desc),J(Y,Y.d_desc),me=function(be){var ye;for(X(be,be.dyn_ltree,be.l_desc.max_code),X(be,be.dyn_dtree,be.d_desc.max_code),J(be,be.bl_desc),ye=18;3<=ye&&be.bl_tree[2*F[ye]+1]===0;ye--);return be.opt_len+=3*(ye+1)+5+5+4,ye}(Y),ae=Y.opt_len+3+7>>>3,(ce=Y.static_len+3+7>>>3)<=ae&&(ae=ce)):ae=ce=ne+5,ne+4<=ae&&te!==-1?se(Y,te,ne,oe):Y.strategy===4||ce===ae?(U(Y,2+(oe?1:0),3),K(Y,L,V)):(U(Y,4+(oe?1:0),3),function(be,ye,Me,Te){var fe;for(U(be,ye-257,5),U(be,Me-1,5),U(be,Te-4,4),fe=0;fe<Te;fe++)U(be,be.bl_tree[2*F[fe]+1],3);Q(be,be.dyn_ltree,ye-1),Q(be,be.dyn_dtree,Me-1)}(Y,Y.l_desc.max_code+1,Y.d_desc.max_code+1,me+1),K(Y,Y.dyn_ltree,Y.dyn_dtree)),q(Y),oe&&M(Y)},b._tr_tally=function(Y,te,ne){return Y.pending_buf[Y.d_buf+2*Y.last_lit]=te>>>8&255,Y.pending_buf[Y.d_buf+2*Y.last_lit+1]=255&te,Y.pending_buf[Y.l_buf+Y.last_lit]=255&ne,Y.last_lit++,te===0?Y.dyn_ltree[2*ne]++:(Y.matches++,te--,Y.dyn_ltree[2*(E[ne]+g+1)]++,Y.dyn_dtree[2*O(te)]++),Y.last_lit===Y.lit_bufsize-1},b._tr_align=function(Y){U(Y,2,3),H(Y,256,L),function(te){te.bi_valid===16?(N(te,te.bi_buf),te.bi_buf=0,te.bi_valid=0):8<=te.bi_valid&&(te.pending_buf[te.pending++]=255&te.bi_buf,te.bi_buf>>=8,te.bi_valid-=8)}(Y)}},{"../utils/common":41}],53:[function(d,m,b){m.exports=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}},{}],54:[function(d,m,b){(function(p){(function(v,g){if(!v.setImmediate){var x,C,T,R,B=1,I={},F=!1,L=v.document,V=Object.getPrototypeOf&&Object.getPrototypeOf(v);V=V&&V.setTimeout?V:v,x={}.toString.call(v.process)==="[object process]"?function(k){c.nextTick(function(){E(k)})}:function(){if(v.postMessage&&!v.importScripts){var k=!0,y=v.onmessage;return v.onmessage=function(){k=!1},v.postMessage("","*"),v.onmessage=y,k}}()?(R="setImmediate$"+Math.random()+"$",v.addEventListener?v.addEventListener("message",P,!1):v.attachEvent("onmessage",P),function(k){v.postMessage(R+k,"*")}):v.MessageChannel?((T=new MessageChannel).port1.onmessage=function(k){E(k.data)},function(k){T.port2.postMessage(k)}):L&&"onreadystatechange"in L.createElement("script")?(C=L.documentElement,function(k){var y=L.createElement("script");y.onreadystatechange=function(){E(k),y.onreadystatechange=null,C.removeChild(y),y=null},C.appendChild(y)}):function(k){setTimeout(E,0,k)},V.setImmediate=function(k){typeof k!="function"&&(k=new Function(""+k));for(var y=new Array(arguments.length-1),w=0;w<y.length;w++)y[w]=arguments[w+1];var _={callback:k,args:y};return I[B]=_,x(B),B++},V.clearImmediate=z}function z(k){delete I[k]}function E(k){if(F)setTimeout(E,0,k);else{var y=I[k];if(y){F=!0;try{(function(w){var _=w.callback,S=w.args;switch(S.length){case 0:_();break;case 1:_(S[0]);break;case 2:_(S[0],S[1]);break;case 3:_(S[0],S[1],S[2]);break;default:_.apply(void 0,S)}})(y)}finally{z(k),F=!1}}}}function P(k){k.source===v&&typeof k.data=="string"&&k.data.indexOf(R)===0&&E(+k.data.slice(R.length))}})(typeof self>"u"?p===void 0?this:p:self)}).call(this,s!==void 0?s:typeof self<"u"?self:typeof window<"u"?window:{})},{}]},{},[10])(10)})}).call(this)}).call(this,e("_process"),typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],e("timers").setImmediate)},{_process:467,buffer:220,timers:523}],442:[function(e,a,f){(function(c){(function(){var s=/[\\^$.*+?()[\]{}|]/g,l=RegExp(s.source),i=typeof c=="object"&&c&&c.Object===Object&&c,n=typeof self=="object"&&self&&self.Object===Object&&self,o=i||n||Function("return this")(),h=Object.prototype.toString,u=o.Symbol,d=u?u.prototype:void 0,m=d?d.toString:void 0;function b(p){if(typeof p=="string")return p;if(function(g){return typeof g=="symbol"||function(x){return!!x&&typeof x=="object"}(g)&&h.call(g)=="[object Symbol]"}(p))return m?m.call(p):"";var v=p+"";return v=="0"&&1/p==-1/0?"-0":v}a.exports=function(p){var v;return(p=(v=p)==null?"":b(v))&&l.test(p)?p.replace(s,"\\$&"):p}}).call(this)}).call(this,typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{}],443:[function(e,a,f){(function(c){(function(){var s="[object Arguments]",l="[object Map]",i="[object Object]",n="[object Set]",o=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,h=/^\w*$/,u=/^\./,d=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,m=/\\(\\)?/g,b=/^\[object .+?Constructor\]$/,p=/^(?:0|[1-9]\d*)$/,v={};v["[object Float32Array]"]=v["[object Float64Array]"]=v["[object Int8Array]"]=v["[object Int16Array]"]=v["[object Int32Array]"]=v["[object Uint8Array]"]=v["[object Uint8ClampedArray]"]=v["[object Uint16Array]"]=v["[object Uint32Array]"]=!0,v[s]=v["[object Array]"]=v["[object ArrayBuffer]"]=v["[object Boolean]"]=v["[object DataView]"]=v["[object Date]"]=v["[object Error]"]=v["[object Function]"]=v[l]=v["[object Number]"]=v[i]=v["[object RegExp]"]=v[n]=v["[object String]"]=v["[object WeakMap]"]=!1;var g=typeof c=="object"&&c&&c.Object===Object&&c,x=typeof self=="object"&&self&&self.Object===Object&&self,C=g||x||Function("return this")(),T=typeof f=="object"&&f&&!f.nodeType&&f,R=T&&typeof a=="object"&&a&&!a.nodeType&&a,B=R&&R.exports===T&&g.process,I=function(){try{return B&&B.binding("util")}catch{}}(),F=I&&I.isTypedArray;function L(re,pe,we,_e){for(var ze=-1,Ae=re?re.length:0;++ze<Ae;){var Re=re[ze];pe(_e,Re,we(Re),re)}return _e}function V(re,pe){for(var we=-1,_e=re?re.length:0;++we<_e;)if(pe(re[we],we,re))return!0;return!1}function z(re){var pe=!1;if(re!=null&&typeof re.toString!="function")try{pe=!!(re+"")}catch{}return pe}function E(re){var pe=-1,we=Array(re.size);return re.forEach(function(_e,ze){we[++pe]=[ze,_e]}),we}function P(re){var pe=-1,we=Array(re.size);return re.forEach(function(_e){we[++pe]=_e}),we}var k,y,w,_=Array.prototype,S=Function.prototype,A=Object.prototype,O=C["__core-js_shared__"],N=(k=/[^.]+$/.exec(O&&O.keys&&O.keys.IE_PROTO||""))?"Symbol(src)_1."+k:"",U=S.toString,H=A.hasOwnProperty,Z=A.toString,D=RegExp("^"+U.call(H).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),q=C.Symbol,M=C.Uint8Array,j=A.propertyIsEnumerable,$=_.splice,K=(y=Object.keys,w=Object,function(re){return y(w(re))}),J=Ye(C,"DataView"),X=Ye(C,"Map"),Q=Ye(C,"Promise"),ee=Ye(C,"Set"),se=Ye(C,"WeakMap"),Y=Ye(Object,"create"),te=he(J),ne=he(X),oe=he(Q),ae=he(ee),ce=he(se),me=q?q.prototype:void 0,be=me?me.valueOf:void 0,ye=me?me.toString:void 0;function Me(re){var pe=-1,we=re?re.length:0;for(this.clear();++pe<we;){var _e=re[pe];this.set(_e[0],_e[1])}}function Te(re){var pe=-1,we=re?re.length:0;for(this.clear();++pe<we;){var _e=re[pe];this.set(_e[0],_e[1])}}function fe(re){var pe=-1,we=re?re.length:0;for(this.clear();++pe<we;){var _e=re[pe];this.set(_e[0],_e[1])}}function ke(re){var pe=-1,we=re?re.length:0;for(this.__data__=new fe;++pe<we;)this.add(re[pe])}function Ee(re){this.__data__=new Te(re)}function Ne(re,pe){var we=Ke(re)||et(re)?function(Re,ht){for(var st=-1,at=Array(Re);++st<Re;)at[st]=ht(st);return at}(re.length,String):[],_e=we.length,ze=!!_e;for(var Ae in re)!H.call(re,Ae)||ze&&(Ae=="length"||kt(Ae,_e))||we.push(Ae);return we}function De(re,pe){for(var we=re.length;we--;)if(Ie(re[we][0],pe))return we;return-1}function je(re,pe,we,_e){return Oe(re,function(ze,Ae,Re){pe(_e,ze,we(ze),Re)}),_e}Me.prototype.clear=function(){this.__data__=Y?Y(null):{}},Me.prototype.delete=function(re){return this.has(re)&&delete this.__data__[re]},Me.prototype.get=function(re){var pe=this.__data__;if(Y){var we=pe[re];return we==="__lodash_hash_undefined__"?void 0:we}return H.call(pe,re)?pe[re]:void 0},Me.prototype.has=function(re){var pe=this.__data__;return Y?pe[re]!==void 0:H.call(pe,re)},Me.prototype.set=function(re,pe){return this.__data__[re]=Y&&pe===void 0?"__lodash_hash_undefined__":pe,this},Te.prototype.clear=function(){this.__data__=[]},Te.prototype.delete=function(re){var pe=this.__data__,we=De(pe,re);return!(we<0)&&(we==pe.length-1?pe.pop():$.call(pe,we,1),!0)},Te.prototype.get=function(re){var pe=this.__data__,we=De(pe,re);return we<0?void 0:pe[we][1]},Te.prototype.has=function(re){return De(this.__data__,re)>-1},Te.prototype.set=function(re,pe){var we=this.__data__,_e=De(we,re);return _e<0?we.push([re,pe]):we[_e][1]=pe,this},fe.prototype.clear=function(){this.__data__={hash:new Me,map:new(X||Te),string:new Me}},fe.prototype.delete=function(re){return bt(this,re).delete(re)},fe.prototype.get=function(re){return bt(this,re).get(re)},fe.prototype.has=function(re){return bt(this,re).has(re)},fe.prototype.set=function(re,pe){return bt(this,re).set(re,pe),this},ke.prototype.add=ke.prototype.push=function(re){return this.__data__.set(re,"__lodash_hash_undefined__"),this},ke.prototype.has=function(re){return this.__data__.has(re)},Ee.prototype.clear=function(){this.__data__=new Te},Ee.prototype.delete=function(re){return this.__data__.delete(re)},Ee.prototype.get=function(re){return this.__data__.get(re)},Ee.prototype.has=function(re){return this.__data__.has(re)},Ee.prototype.set=function(re,pe){var we=this.__data__;if(we instanceof Te){var _e=we.__data__;if(!X||_e.length<199)return _e.push([re,pe]),this;we=this.__data__=new fe(_e)}return we.set(re,pe),this};var Ce,Oe=(Ce=function(re,pe){return re&&Le(re,pe,Kt)},function(re,pe){if(re==null)return re;if(!$e(re))return Ce(re,pe);for(var we=re.length,_e=-1,ze=Object(re);++_e<we&&pe(ze[_e],_e,ze)!==!1;);return re}),Le=function(re){return function(pe,we,_e){for(var ze=-1,Ae=Object(pe),Re=_e(pe),ht=Re.length;ht--;){var st=Re[++ze];if(we(Ae[st],st,Ae)===!1)break}return pe}}();function Be(re,pe){for(var we=0,_e=(pe=Ue(pe,re)?[pe]:qe(pe)).length;re!=null&&we<_e;)re=re[le(pe[we++])];return we&&we==_e?re:void 0}function ct(re,pe){return re!=null&&pe in Object(re)}function wt(re,pe,we,_e,ze){return re===pe||(re==null||pe==null||!ot(re)&&!Wt(pe)?re!=re&&pe!=pe:function(Ae,Re,ht,st,at,Ge){var xt=Ke(Ae),_t=Ke(Re),Tt="[object Array]",zt="[object Array]";xt||(Tt=(Tt=pt(Ae))==s?i:Tt),_t||(zt=(zt=pt(Re))==s?i:zt);var rr=Tt==i&&!z(Ae),ur=zt==i&&!z(Re),Nr=Tt==zt;if(Nr&&!rr)return Ge||(Ge=new Ee),xt||Qt(Ae)?Ot(Ae,Re,ht,st,at,Ge):function(St,mt,ln,An,Ni,mr,Qr){switch(ln){case"[object DataView]":if(St.byteLength!=mt.byteLength||St.byteOffset!=mt.byteOffset)return!1;St=St.buffer,mt=mt.buffer;case"[object ArrayBuffer]":return!(St.byteLength!=mt.byteLength||!An(new M(St),new M(mt)));case"[object Boolean]":case"[object Date]":case"[object Number]":return Ie(+St,+mt);case"[object Error]":return St.name==mt.name&&St.message==mt.message;case"[object RegExp]":case"[object String]":return St==mt+"";case l:var cn=E;case n:var si=2&mr;if(cn||(cn=P),St.size!=mt.size&&!si)return!1;var Vn=Qr.get(St);if(Vn)return Vn==mt;mr|=1,Qr.set(St,mt);var Un=Ot(cn(St),cn(mt),An,Ni,mr,Qr);return Qr.delete(St),Un;case"[object Symbol]":if(be)return be.call(St)==be.call(mt)}return!1}(Ae,Re,Tt,ht,st,at,Ge);if(!(2&at)){var En=rr&&H.call(Ae,"__wrapped__"),Jr=ur&&H.call(Re,"__wrapped__");if(En||Jr){var an=En?Ae.value():Ae,zn=Jr?Re.value():Re;return Ge||(Ge=new Ee),ht(an,zn,st,at,Ge)}}return Nr?(Ge||(Ge=new Ee),function(St,mt,ln,An,Ni,mr){var Qr=2&Ni,cn=Kt(St),si=cn.length,Vn=Kt(mt).length;if(si!=Vn&&!Qr)return!1;for(var Un=si;Un--;){var un=cn[Un];if(!(Qr?un in mt:H.call(mt,un)))return!1}var Xo=mr.get(St);if(Xo&&mr.get(mt))return Xo==mt;var Mn=!0;mr.set(St,mt),mr.set(mt,St);for(var oi=Qr;++Un<si;){un=cn[Un];var Wn=St[un],Hn=mt[un];if(An)var Ko=Qr?An(Hn,Wn,un,mt,St,mr):An(Wn,Hn,un,St,mt,mr);if(!(Ko===void 0?Wn===Hn||ln(Wn,Hn,An,Ni,mr):Ko)){Mn=!1;break}oi||(oi=un=="constructor")}if(Mn&&!oi){var ai=St.constructor,qn=mt.constructor;ai==qn||!("constructor"in St)||!("constructor"in mt)||typeof ai=="function"&&ai instanceof ai&&typeof qn=="function"&&qn instanceof qn||(Mn=!1)}return mr.delete(St),mr.delete(mt),Mn}(Ae,Re,ht,st,at,Ge)):!1}(re,pe,wt,we,_e,ze))}function We(re){return!(!ot(re)||function(pe){return!!N&&N in pe}(re))&&(rt(re)||z(re)?D:b).test(he(re))}function dt(re){return typeof re=="function"?re:re==null?pr:typeof re=="object"?Ke(re)?function(_e,ze){return Ue(_e)&&vt(ze)?Ct(le(_e),ze):function(Ae){var Re=function(ht,st,at){var Ge=ht==null?void 0:Be(ht,st);return Ge===void 0?at:Ge}(Ae,_e);return Re===void 0&&Re===ze?function(ht,st){return ht!=null&&function(at,Ge,xt){Ge=Ue(Ge,at)?[Ge]:qe(Ge);for(var _t,Tt=-1,zt=Ge.length;++Tt<zt;){var rr=le(Ge[Tt]);if(!(_t=at!=null&&xt(at,rr)))break;at=at[rr]}return _t||!!(zt=at?at.length:0)&&tt(zt)&&kt(rr,zt)&&(Ke(at)||et(at))}(ht,st,ct)}(Ae,_e):wt(ze,Re,void 0,3)}}(re[0],re[1]):function(_e){var ze=function(Ae){for(var Re=Kt(Ae),ht=Re.length;ht--;){var st=Re[ht],at=Ae[st];Re[ht]=[st,at,vt(at)]}return Re}(_e);return ze.length==1&&ze[0][2]?Ct(ze[0][0],ze[0][1]):function(Ae){return Ae===_e||function(Re,ht,st,at){var Ge=st.length,xt=Ge;if(Re==null)return!xt;for(Re=Object(Re);Ge--;){var _t=st[Ge];if(_t[2]?_t[1]!==Re[_t[0]]:!(_t[0]in Re))return!1}for(;++Ge<xt;){var Tt=(_t=st[Ge])[0],zt=Re[Tt],rr=_t[1];if(_t[2]){if(zt===void 0&&!(Tt in Re))return!1}else{var ur=new Ee,Nr;if(!(Nr===void 0?wt(rr,zt,at,3,ur):Nr))return!1}}return!0}(Ae,_e,ze)}}(re):Ue(pe=re)?(we=le(pe),function(_e){return _e?.[we]}):function(_e){return function(ze){return Be(ze,_e)}}(pe);var pe,we}function ut(re){if(we=(pe=re)&&pe.constructor,_e=typeof we=="function"&&we.prototype||A,pe!==_e)return K(re);var pe,we,_e,ze=[];for(var Ae in Object(re))H.call(re,Ae)&&Ae!="constructor"&&ze.push(Ae);return ze}function qe(re){return Ke(re)?re:it(re)}function Ot(re,pe,we,_e,ze,Ae){var Re=2&ze,ht=re.length,st=pe.length;if(ht!=st&&!(Re&&st>ht))return!1;var at=Ae.get(re);if(at&&Ae.get(pe))return at==pe;var Ge=-1,xt=!0,_t=1&ze?new ke:void 0;for(Ae.set(re,pe),Ae.set(pe,re);++Ge<ht;){var Tt=re[Ge],zt=pe[Ge];if(_e)var rr=Re?_e(zt,Tt,Ge,pe,re,Ae):_e(Tt,zt,Ge,re,pe,Ae);if(rr!==void 0){if(rr)continue;xt=!1;break}if(_t){if(!V(pe,function(ur,Nr){if(!_t.has(Nr)&&(Tt===ur||we(Tt,ur,_e,ze,Ae)))return _t.add(Nr)})){xt=!1;break}}else if(Tt!==zt&&!we(Tt,zt,_e,ze,Ae)){xt=!1;break}}return Ae.delete(re),Ae.delete(pe),xt}function bt(re,pe){var we,_e,ze=re.__data__;return((_e=typeof(we=pe))=="string"||_e=="number"||_e=="symbol"||_e=="boolean"?we!=="__proto__":we===null)?ze[typeof pe=="string"?"string":"hash"]:ze.map}function Ye(re,pe){var we=function(_e,ze){return _e?.[ze]}(re,pe);return We(we)?we:void 0}var pt=function(re){return Z.call(re)};function kt(re,pe){return!!(pe=pe??9007199254740991)&&(typeof re=="number"||p.test(re))&&re>-1&&re%1==0&&re<pe}function Ue(re,pe){if(Ke(re))return!1;var we=typeof re;return!(we!="number"&&we!="symbol"&&we!="boolean"&&re!=null&&!Ft(re))||h.test(re)||!o.test(re)||pe!=null&&re in Object(pe)}function vt(re){return re==re&&!ot(re)}function Ct(re,pe){return function(we){return we!=null&&we[re]===pe&&(pe!==void 0||re in Object(we))}}(J&&pt(new J(new ArrayBuffer(1)))!="[object DataView]"||X&&pt(new X)!=l||Q&&pt(Q.resolve())!="[object Promise]"||ee&&pt(new ee)!=n||se&&pt(new se)!="[object WeakMap]")&&(pt=function(re){var pe=Z.call(re),we=pe==i?re.constructor:void 0,_e=we?he(we):void 0;if(_e)switch(_e){case te:return"[object DataView]";case ne:return l;case oe:return"[object Promise]";case ae:return n;case ce:return"[object WeakMap]"}return pe});var it=Xe(function(re){var pe;re=(pe=re)==null?"":function(_e){if(typeof _e=="string")return _e;if(Ft(_e))return ye?ye.call(_e):"";var ze=_e+"";return ze=="0"&&1/_e==-1/0?"-0":ze}(pe);var we=[];return u.test(re)&&we.push(""),re.replace(d,function(_e,ze,Ae,Re){we.push(Ae?Re.replace(m,"$1"):ze||_e)}),we});function le(re){if(typeof re=="string"||Ft(re))return re;var pe=re+"";return pe=="0"&&1/re==-1/0?"-0":pe}function he(re){if(re!=null){try{return U.call(re)}catch{}try{return re+""}catch{}}return""}var ve,Pe=(ve=function(re,pe,we){H.call(re,we)?re[we].push(pe):re[we]=[pe]},function(re,pe){var we=Ke(re)?L:je,_e={};return we(re,ve,dt(pe),_e)});function Xe(re,pe){if(typeof re!="function"||pe&&typeof pe!="function")throw new TypeError("Expected a function");var we=function(){var _e=arguments,ze=pe?pe.apply(this,_e):_e[0],Ae=we.cache;if(Ae.has(ze))return Ae.get(ze);var Re=re.apply(this,_e);return we.cache=Ae.set(ze,Re),Re};return we.cache=new(Xe.Cache||fe),we}function Ie(re,pe){return re===pe||re!=re&&pe!=pe}function et(re){return function(pe){return Wt(pe)&&$e(pe)}(re)&&H.call(re,"callee")&&(!j.call(re,"callee")||Z.call(re)==s)}Xe.Cache=fe;var Ke=Array.isArray;function $e(re){return re!=null&&tt(re.length)&&!rt(re)}function rt(re){var pe=ot(re)?Z.call(re):"";return pe=="[object Function]"||pe=="[object GeneratorFunction]"}function tt(re){return typeof re=="number"&&re>-1&&re%1==0&&re<=9007199254740991}function ot(re){var pe=typeof re;return!!re&&(pe=="object"||pe=="function")}function Wt(re){return!!re&&typeof re=="object"}function Ft(re){return typeof re=="symbol"||Wt(re)&&Z.call(re)=="[object Symbol]"}var Qt=F?function(re){return function(pe){return re(pe)}}(F):function(re){return Wt(re)&&tt(re.length)&&!!v[Z.call(re)]};function Kt(re){return $e(re)?Ne(re):ut(re)}function pr(re){return re}a.exports=Pe}).call(this)}).call(this,typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{}],444:[function(e,a,f){var c=Object.prototype.toString;a.exports=function(s){return s===!0||s===!1||function(l){return!!l&&typeof l=="object"}(s)&&c.call(s)=="[object Boolean]"}},{}],445:[function(e,a,f){(function(c){(function(){var s="[object Arguments]",l="[object Map]",i="[object Object]",n="[object Set]",o=/^\[object .+?Constructor\]$/,h=/^(?:0|[1-9]\d*)$/,u={};u["[object Float32Array]"]=u["[object Float64Array]"]=u["[object Int8Array]"]=u["[object Int16Array]"]=u["[object Int32Array]"]=u["[object Uint8Array]"]=u["[object Uint8ClampedArray]"]=u["[object Uint16Array]"]=u["[object Uint32Array]"]=!0,u[s]=u["[object Array]"]=u["[object ArrayBuffer]"]=u["[object Boolean]"]=u["[object DataView]"]=u["[object Date]"]=u["[object Error]"]=u["[object Function]"]=u[l]=u["[object Number]"]=u[i]=u["[object RegExp]"]=u[n]=u["[object String]"]=u["[object WeakMap]"]=!1;var d=typeof c=="object"&&c&&c.Object===Object&&c,m=typeof self=="object"&&self&&self.Object===Object&&self,b=d||m||Function("return this")(),p=typeof f=="object"&&f&&!f.nodeType&&f,v=p&&typeof a=="object"&&a&&!a.nodeType&&a,g=v&&v.exports===p,x=g&&d.process,C=function(){try{return x&&x.binding&&x.binding("util")}catch{}}(),T=C&&C.isTypedArray;function R(le,he){for(var ve=-1,Pe=le==null?0:le.length;++ve<Pe;)if(he(le[ve],ve,le))return!0;return!1}function B(le){var he=-1,ve=Array(le.size);return le.forEach(function(Pe,Xe){ve[++he]=[Xe,Pe]}),ve}function I(le){var he=-1,ve=Array(le.size);return le.forEach(function(Pe){ve[++he]=Pe}),ve}var F,L,V,z=Array.prototype,E=Function.prototype,P=Object.prototype,k=b["__core-js_shared__"],y=E.toString,w=P.hasOwnProperty,_=(F=/[^.]+$/.exec(k&&k.keys&&k.keys.IE_PROTO||""))?"Symbol(src)_1."+F:"",S=P.toString,A=RegExp("^"+y.call(w).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),O=g?b.Buffer:void 0,N=b.Symbol,U=b.Uint8Array,H=P.propertyIsEnumerable,Z=z.splice,D=N?N.toStringTag:void 0,q=Object.getOwnPropertySymbols,M=O?O.isBuffer:void 0,j=(L=Object.keys,V=Object,function(le){return L(V(le))}),$=ct(b,"DataView"),K=ct(b,"Map"),J=ct(b,"Promise"),X=ct(b,"Set"),Q=ct(b,"WeakMap"),ee=ct(Object,"create"),se=ut($),Y=ut(K),te=ut(J),ne=ut(X),oe=ut(Q),ae=N?N.prototype:void 0,ce=ae?ae.valueOf:void 0;function me(le){var he=-1,ve=le==null?0:le.length;for(this.clear();++he<ve;){var Pe=le[he];this.set(Pe[0],Pe[1])}}function be(le){var he=-1,ve=le==null?0:le.length;for(this.clear();++he<ve;){var Pe=le[he];this.set(Pe[0],Pe[1])}}function ye(le){var he=-1,ve=le==null?0:le.length;for(this.clear();++he<ve;){var Pe=le[he];this.set(Pe[0],Pe[1])}}function Me(le){var he=-1,ve=le==null?0:le.length;for(this.__data__=new ye;++he<ve;)this.add(le[he])}function Te(le){var he=this.__data__=new be(le);this.size=he.size}function fe(le,he){var ve=bt(le),Pe=!ve&&Ot(le),Xe=!ve&&!Pe&&Ye(le),Ie=!ve&&!Pe&&!Xe&&Ct(le),et=ve||Pe||Xe||Ie,Ke=et?function(tt,ot){for(var Wt=-1,Ft=Array(tt);++Wt<tt;)Ft[Wt]=ot(Wt);return Ft}(le.length,String):[],$e=Ke.length;for(var rt in le)!w.call(le,rt)||et&&(rt=="length"||Xe&&(rt=="offset"||rt=="parent")||Ie&&(rt=="buffer"||rt=="byteLength"||rt=="byteOffset")||dt(rt,$e))||Ke.push(rt);return Ke}function ke(le,he){for(var ve=le.length;ve--;)if(qe(le[ve][0],he))return ve;return-1}function Ee(le){return le==null?le===void 0?"[object Undefined]":"[object Null]":D&&D in Object(le)?function(he){var ve=w.call(he,D),Pe=he[D];try{he[D]=void 0;var Xe=!0}catch{}var Ie=S.call(he);return Xe&&(ve?he[D]=Pe:delete he[D]),Ie}(le):function(he){return S.call(he)}(le)}function Ne(le){return vt(le)&&Ee(le)==s}function De(le,he,ve,Pe,Xe){return le===he||(le==null||he==null||!vt(le)&&!vt(he)?le!=le&&he!=he:function(Ie,et,Ke,$e,rt,tt){var ot=bt(Ie),Wt=bt(et),Ft=ot?"[object Array]":We(Ie),Qt=Wt?"[object Array]":We(et),Kt=(Ft=Ft==s?i:Ft)==i,pr=(Qt=Qt==s?i:Qt)==i,re=Ft==Qt;if(re&&Ye(Ie)){if(!Ye(et))return!1;ot=!0,Kt=!1}if(re&&!Kt)return tt||(tt=new Te),ot||Ct(Ie)?Oe(Ie,et,Ke,$e,rt,tt):function(Ae,Re,ht,st,at,Ge,xt){switch(ht){case"[object DataView]":if(Ae.byteLength!=Re.byteLength||Ae.byteOffset!=Re.byteOffset)return!1;Ae=Ae.buffer,Re=Re.buffer;case"[object ArrayBuffer]":return!(Ae.byteLength!=Re.byteLength||!Ge(new U(Ae),new U(Re)));case"[object Boolean]":case"[object Date]":case"[object Number]":return qe(+Ae,+Re);case"[object Error]":return Ae.name==Re.name&&Ae.message==Re.message;case"[object RegExp]":case"[object String]":return Ae==Re+"";case l:var _t=B;case n:var Tt=1&st;if(_t||(_t=I),Ae.size!=Re.size&&!Tt)return!1;var zt=xt.get(Ae);if(zt)return zt==Re;st|=2,xt.set(Ae,Re);var rr=Oe(_t(Ae),_t(Re),st,at,Ge,xt);return xt.delete(Ae),rr;case"[object Symbol]":if(ce)return ce.call(Ae)==ce.call(Re)}return!1}(Ie,et,Ft,Ke,$e,rt,tt);if(!(1&Ke)){var pe=Kt&&w.call(Ie,"__wrapped__"),we=pr&&w.call(et,"__wrapped__");if(pe||we){var _e=pe?Ie.value():Ie,ze=we?et.value():et;return tt||(tt=new Te),rt(_e,ze,Ke,$e,tt)}}return re?(tt||(tt=new Te),function(Ae,Re,ht,st,at,Ge){var xt=1&ht,_t=Le(Ae),Tt=_t.length,zt=Le(Re).length;if(Tt!=zt&&!xt)return!1;for(var rr=Tt;rr--;){var ur=_t[rr];if(!(xt?ur in Re:w.call(Re,ur)))return!1}var Nr=Ge.get(Ae);if(Nr&&Ge.get(Re))return Nr==Re;var En=!0;Ge.set(Ae,Re),Ge.set(Re,Ae);for(var Jr=xt;++rr<Tt;){ur=_t[rr];var an=Ae[ur],zn=Re[ur];if(st)var St=xt?st(zn,an,ur,Re,Ae,Ge):st(an,zn,ur,Ae,Re,Ge);if(!(St===void 0?an===zn||at(an,zn,ht,st,Ge):St)){En=!1;break}Jr||(Jr=ur=="constructor")}if(En&&!Jr){var mt=Ae.constructor,ln=Re.constructor;mt==ln||!("constructor"in Ae)||!("constructor"in Re)||typeof mt=="function"&&mt instanceof mt&&typeof ln=="function"&&ln instanceof ln||(En=!1)}return Ge.delete(Ae),Ge.delete(Re),En}(Ie,et,Ke,$e,rt,tt)):!1}(le,he,ve,Pe,De,Xe))}function je(le){return!(!Ue(le)||function(he){return!!_&&_ in he}(le))&&(pt(le)?A:o).test(ut(le))}function Ce(le){if(ve=(he=le)&&he.constructor,Pe=typeof ve=="function"&&ve.prototype||P,he!==Pe)return j(le);var he,ve,Pe,Xe=[];for(var Ie in Object(le))w.call(le,Ie)&&Ie!="constructor"&&Xe.push(Ie);return Xe}function Oe(le,he,ve,Pe,Xe,Ie){var et=1&ve,Ke=le.length,$e=he.length;if(Ke!=$e&&!(et&&$e>Ke))return!1;var rt=Ie.get(le);if(rt&&Ie.get(he))return rt==he;var tt=-1,ot=!0,Wt=2&ve?new Me:void 0;for(Ie.set(le,he),Ie.set(he,le);++tt<Ke;){var Ft=le[tt],Qt=he[tt];if(Pe)var Kt=et?Pe(Qt,Ft,tt,he,le,Ie):Pe(Ft,Qt,tt,le,he,Ie);if(Kt!==void 0){if(Kt)continue;ot=!1;break}if(Wt){if(!R(he,function(pr,re){if(pe=re,!Wt.has(pe)&&(Ft===pr||Xe(Ft,pr,ve,Pe,Ie)))return Wt.push(re);var pe})){ot=!1;break}}else if(Ft!==Qt&&!Xe(Ft,Qt,ve,Pe,Ie)){ot=!1;break}}return Ie.delete(le),Ie.delete(he),ot}function Le(le){return function(he,ve,Pe){var Xe=ve(he);return bt(he)?Xe:function(Ie,et){for(var Ke=-1,$e=et.length,rt=Ie.length;++Ke<$e;)Ie[rt+Ke]=et[Ke];return Ie}(Xe,Pe(he))}(le,it,wt)}function Be(le,he){var ve,Pe,Xe=le.__data__;return((Pe=typeof(ve=he))=="string"||Pe=="number"||Pe=="symbol"||Pe=="boolean"?ve!=="__proto__":ve===null)?Xe[typeof he=="string"?"string":"hash"]:Xe.map}function ct(le,he){var ve=function(Pe,Xe){return Pe?.[Xe]}(le,he);return je(ve)?ve:void 0}me.prototype.clear=function(){this.__data__=ee?ee(null):{},this.size=0},me.prototype.delete=function(le){var he=this.has(le)&&delete this.__data__[le];return this.size-=he?1:0,he},me.prototype.get=function(le){var he=this.__data__;if(ee){var ve=he[le];return ve==="__lodash_hash_undefined__"?void 0:ve}return w.call(he,le)?he[le]:void 0},me.prototype.has=function(le){var he=this.__data__;return ee?he[le]!==void 0:w.call(he,le)},me.prototype.set=function(le,he){var ve=this.__data__;return this.size+=this.has(le)?0:1,ve[le]=ee&&he===void 0?"__lodash_hash_undefined__":he,this},be.prototype.clear=function(){this.__data__=[],this.size=0},be.prototype.delete=function(le){var he=this.__data__,ve=ke(he,le);return!(ve<0)&&(ve==he.length-1?he.pop():Z.call(he,ve,1),--this.size,!0)},be.prototype.get=function(le){var he=this.__data__,ve=ke(he,le);return ve<0?void 0:he[ve][1]},be.prototype.has=function(le){return ke(this.__data__,le)>-1},be.prototype.set=function(le,he){var ve=this.__data__,Pe=ke(ve,le);return Pe<0?(++this.size,ve.push([le,he])):ve[Pe][1]=he,this},ye.prototype.clear=function(){this.size=0,this.__data__={hash:new me,map:new(K||be),string:new me}},ye.prototype.delete=function(le){var he=Be(this,le).delete(le);return this.size-=he?1:0,he},ye.prototype.get=function(le){return Be(this,le).get(le)},ye.prototype.has=function(le){return Be(this,le).has(le)},ye.prototype.set=function(le,he){var ve=Be(this,le),Pe=ve.size;return ve.set(le,he),this.size+=ve.size==Pe?0:1,this},Me.prototype.add=Me.prototype.push=function(le){return this.__data__.set(le,"__lodash_hash_undefined__"),this},Me.prototype.has=function(le){return this.__data__.has(le)},Te.prototype.clear=function(){this.__data__=new be,this.size=0},Te.prototype.delete=function(le){var he=this.__data__,ve=he.delete(le);return this.size=he.size,ve},Te.prototype.get=function(le){return this.__data__.get(le)},Te.prototype.has=function(le){return this.__data__.has(le)},Te.prototype.set=function(le,he){var ve=this.__data__;if(ve instanceof be){var Pe=ve.__data__;if(!K||Pe.length<199)return Pe.push([le,he]),this.size=++ve.size,this;ve=this.__data__=new ye(Pe)}return ve.set(le,he),this.size=ve.size,this};var wt=q?function(le){return le==null?[]:(le=Object(le),function(he,ve){for(var Pe=-1,Xe=he==null?0:he.length,Ie=0,et=[];++Pe<Xe;){var Ke=he[Pe];ve(Ke,Pe,he)&&(et[Ie++]=Ke)}return et}(q(le),function(he){return H.call(le,he)}))}:function(){return[]},We=Ee;function dt(le,he){return!!(he=he??9007199254740991)&&(typeof le=="number"||h.test(le))&&le>-1&&le%1==0&&le<he}function ut(le){if(le!=null){try{return y.call(le)}catch{}try{return le+""}catch{}}return""}function qe(le,he){return le===he||le!=le&&he!=he}($&&We(new $(new ArrayBuffer(1)))!="[object DataView]"||K&&We(new K)!=l||J&&We(J.resolve())!="[object Promise]"||X&&We(new X)!=n||Q&&We(new Q)!="[object WeakMap]")&&(We=function(le){var he=Ee(le),ve=he==i?le.constructor:void 0,Pe=ve?ut(ve):"";if(Pe)switch(Pe){case se:return"[object DataView]";case Y:return l;case te:return"[object Promise]";case ne:return n;case oe:return"[object WeakMap]"}return he});var Ot=Ne(function(){return arguments}())?Ne:function(le){return vt(le)&&w.call(le,"callee")&&!H.call(le,"callee")},bt=Array.isArray,Ye=M||function(){return!1};function pt(le){if(!Ue(le))return!1;var he=Ee(le);return he=="[object Function]"||he=="[object GeneratorFunction]"||he=="[object AsyncFunction]"||he=="[object Proxy]"}function kt(le){return typeof le=="number"&&le>-1&&le%1==0&&le<=9007199254740991}function Ue(le){var he=typeof le;return le!=null&&(he=="object"||he=="function")}function vt(le){return le!=null&&typeof le=="object"}var Ct=T?function(le){return function(he){return le(he)}}(T):function(le){return vt(le)&&kt(le.length)&&!!u[Ee(le)]};function it(le){return(he=le)!=null&&kt(he.length)&&!pt(he)?fe(le):Ce(le);var he}a.exports=function(le,he){return De(le,he)}}).call(this)}).call(this,typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{}],446:[function(e,a,f){(function(c){(function(){var s=typeof c=="object"&&c&&c.Object===Object&&c,l=typeof self=="object"&&self&&self.Object===Object&&self,i=s||l||Function("return this")(),n=Object.prototype,o=n.hasOwnProperty,h=n.toString,u=i.Symbol,d=u?u.toStringTag:void 0;function m(b){return b==null?b===void 0?"[object Undefined]":"[object Null]":d&&d in Object(b)?function(p){var v=o.call(p,d),g=p[d];try{p[d]=void 0;var x=!0}catch{}var C=h.call(p);return x&&(v?p[d]=g:delete p[d]),C}(b):function(p){return h.call(p)}(b)}a.exports=function(b){if(!function(v){var g=typeof v;return v!=null&&(g=="object"||g=="function")}(b))return!1;var p=m(b);return p=="[object Function]"||p=="[object GeneratorFunction]"||p=="[object AsyncFunction]"||p=="[object Proxy]"}}).call(this)}).call(this,typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{}],447:[function(e,a,f){a.exports=function(c){return c==null}},{}],448:[function(e,a,f){a.exports=function(c){return c===void 0}},{}],449:[function(e,a,f){(function(c){(function(){var s=/^\[object .+?Constructor\]$/,l=typeof c=="object"&&c&&c.Object===Object&&c,i=typeof self=="object"&&self&&self.Object===Object&&self,n=l||i||Function("return this")();function o(N,U){return!!(N&&N.length)&&function(H,Z,D){if(Z!=Z)return function(j,$,K,J){for(var X=j.length,Q=K+-1;++Q<X;)if($(j[Q],Q,j))return Q;return-1}(H,h,D);for(var q=D-1,M=H.length;++q<M;)if(H[q]===Z)return q;return-1}(N,U,0)>-1}function h(N){return N!=N}function u(N,U){return N.has(U)}function d(N){var U=-1,H=Array(N.size);return N.forEach(function(Z){H[++U]=Z}),H}var m,b=Array.prototype,p=Function.prototype,v=Object.prototype,g=n["__core-js_shared__"],x=(m=/[^.]+$/.exec(g&&g.keys&&g.keys.IE_PROTO||""))?"Symbol(src)_1."+m:"",C=p.toString,T=v.hasOwnProperty,R=v.toString,B=RegExp("^"+C.call(T).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),I=b.splice,F=A(n,"Map"),L=A(n,"Set"),V=A(Object,"create");function z(N){var U=-1,H=N?N.length:0;for(this.clear();++U<H;){var Z=N[U];this.set(Z[0],Z[1])}}function E(N){var U=-1,H=N?N.length:0;for(this.clear();++U<H;){var Z=N[U];this.set(Z[0],Z[1])}}function P(N){var U=-1,H=N?N.length:0;for(this.clear();++U<H;){var Z=N[U];this.set(Z[0],Z[1])}}function k(N){var U=-1,H=N?N.length:0;for(this.__data__=new P;++U<H;)this.add(N[U])}function y(N,U){for(var H,Z,D=N.length;D--;)if((H=N[D][0])===(Z=U)||H!=H&&Z!=Z)return D;return-1}function w(N){return!(!O(N)||(U=N,x&&x in U))&&(function(H){var Z=O(H)?R.call(H):"";return Z=="[object Function]"||Z=="[object GeneratorFunction]"}(N)||function(H){var Z=!1;if(H!=null&&typeof H.toString!="function")try{Z=!!(H+"")}catch{}return Z}(N)?B:s).test(function(H){if(H!=null){try{return C.call(H)}catch{}try{return H+""}catch{}}return""}(N));var U}z.prototype.clear=function(){this.__data__=V?V(null):{}},z.prototype.delete=function(N){return this.has(N)&&delete this.__data__[N]},z.prototype.get=function(N){var U=this.__data__;if(V){var H=U[N];return H==="__lodash_hash_undefined__"?void 0:H}return T.call(U,N)?U[N]:void 0},z.prototype.has=function(N){var U=this.__data__;return V?U[N]!==void 0:T.call(U,N)},z.prototype.set=function(N,U){return this.__data__[N]=V&&U===void 0?"__lodash_hash_undefined__":U,this},E.prototype.clear=function(){this.__data__=[]},E.prototype.delete=function(N){var U=this.__data__,H=y(U,N);return!(H<0)&&(H==U.length-1?U.pop():I.call(U,H,1),!0)},E.prototype.get=function(N){var U=this.__data__,H=y(U,N);return H<0?void 0:U[H][1]},E.prototype.has=function(N){return y(this.__data__,N)>-1},E.prototype.set=function(N,U){var H=this.__data__,Z=y(H,N);return Z<0?H.push([N,U]):H[Z][1]=U,this},P.prototype.clear=function(){this.__data__={hash:new z,map:new(F||E),string:new z}},P.prototype.delete=function(N){return S(this,N).delete(N)},P.prototype.get=function(N){return S(this,N).get(N)},P.prototype.has=function(N){return S(this,N).has(N)},P.prototype.set=function(N,U){return S(this,N).set(N,U),this},k.prototype.add=k.prototype.push=function(N){return this.__data__.set(N,"__lodash_hash_undefined__"),this},k.prototype.has=function(N){return this.__data__.has(N)};var _=L&&1/d(new L([,-0]))[1]==1/0?function(N){return new L(N)}:function(){};function S(N,U){var H,Z,D=N.__data__;return((Z=typeof(H=U))=="string"||Z=="number"||Z=="symbol"||Z=="boolean"?H!=="__proto__":H===null)?D[typeof U=="string"?"string":"hash"]:D.map}function A(N,U){var H=function(Z,D){return Z?.[D]}(N,U);return w(H)?H:void 0}function O(N){var U=typeof N;return!!N&&(U=="object"||U=="function")}a.exports=function(N){return N&&N.length?function(U,H,Z){var D=-1,q=o,M=U.length,j=!0,$=[],K=$;if(M>=200){var J=_(U);if(J)return d(J);j=!1,q=u,K=new k}else K=$;e:for(;++D<M;){var X=U[D],Q=X;if(X=X!==0?X:0,j&&Q==Q){for(var ee=K.length;ee--;)if(K[ee]===Q)continue e;$.push(X)}else q(K,Q,Z)||(K!==$&&K.push(Q),$.push(X))}return $}(N):[]}}).call(this)}).call(this,typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{}],450:[function(e,a,f){var c=e("inherits"),s=e("hash-base"),l=e("safe-buffer").Buffer,i=new Array(16);function n(){s.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function o(b,p){return b<<p|b>>>32-p}function h(b,p,v,g,x,C,T){return o(b+(p&v|~p&g)+x+C|0,T)+p|0}function u(b,p,v,g,x,C,T){return o(b+(p&g|v&~g)+x+C|0,T)+p|0}function d(b,p,v,g,x,C,T){return o(b+(p^v^g)+x+C|0,T)+p|0}function m(b,p,v,g,x,C,T){return o(b+(v^(p|~g))+x+C|0,T)+p|0}c(n,s),n.prototype._update=function(){for(var b=i,p=0;p<16;++p)b[p]=this._block.readInt32LE(4*p);var v=this._a,g=this._b,x=this._c,C=this._d;v=h(v,g,x,C,b[0],3614090360,7),C=h(C,v,g,x,b[1],3905402710,12),x=h(x,C,v,g,b[2],606105819,17),g=h(g,x,C,v,b[3],3250441966,22),v=h(v,g,x,C,b[4],4118548399,7),C=h(C,v,g,x,b[5],1200080426,12),x=h(x,C,v,g,b[6],2821735955,17),g=h(g,x,C,v,b[7],4249261313,22),v=h(v,g,x,C,b[8],1770035416,7),C=h(C,v,g,x,b[9],2336552879,12),x=h(x,C,v,g,b[10],4294925233,17),g=h(g,x,C,v,b[11],2304563134,22),v=h(v,g,x,C,b[12],1804603682,7),C=h(C,v,g,x,b[13],4254626195,12),x=h(x,C,v,g,b[14],2792965006,17),v=u(v,g=h(g,x,C,v,b[15],1236535329,22),x,C,b[1],4129170786,5),C=u(C,v,g,x,b[6],3225465664,9),x=u(x,C,v,g,b[11],643717713,14),g=u(g,x,C,v,b[0],3921069994,20),v=u(v,g,x,C,b[5],3593408605,5),C=u(C,v,g,x,b[10],38016083,9),x=u(x,C,v,g,b[15],3634488961,14),g=u(g,x,C,v,b[4],3889429448,20),v=u(v,g,x,C,b[9],568446438,5),C=u(C,v,g,x,b[14],3275163606,9),x=u(x,C,v,g,b[3],4107603335,14),g=u(g,x,C,v,b[8],1163531501,20),v=u(v,g,x,C,b[13],2850285829,5),C=u(C,v,g,x,b[2],4243563512,9),x=u(x,C,v,g,b[7],1735328473,14),v=d(v,g=u(g,x,C,v,b[12],2368359562,20),x,C,b[5],4294588738,4),C=d(C,v,g,x,b[8],2272392833,11),x=d(x,C,v,g,b[11],1839030562,16),g=d(g,x,C,v,b[14],4259657740,23),v=d(v,g,x,C,b[1],2763975236,4),C=d(C,v,g,x,b[4],1272893353,11),x=d(x,C,v,g,b[7],4139469664,16),g=d(g,x,C,v,b[10],3200236656,23),v=d(v,g,x,C,b[13],681279174,4),C=d(C,v,g,x,b[0],3936430074,11),x=d(x,C,v,g,b[3],3572445317,16),g=d(g,x,C,v,b[6],76029189,23),v=d(v,g,x,C,b[9],3654602809,4),C=d(C,v,g,x,b[12],3873151461,11),x=d(x,C,v,g,b[15],530742520,16),v=m(v,g=d(g,x,C,v,b[2],3299628645,23),x,C,b[0],4096336452,6),C=m(C,v,g,x,b[7],1126891415,10),x=m(x,C,v,g,b[14],2878612391,15),g=m(g,x,C,v,b[5],4237533241,21),v=m(v,g,x,C,b[12],1700485571,6),C=m(C,v,g,x,b[3],2399980690,10),x=m(x,C,v,g,b[10],4293915773,15),g=m(g,x,C,v,b[1],2240044497,21),v=m(v,g,x,C,b[8],1873313359,6),C=m(C,v,g,x,b[15],4264355552,10),x=m(x,C,v,g,b[6],2734768916,15),g=m(g,x,C,v,b[13],1309151649,21),v=m(v,g,x,C,b[4],4149444226,6),C=m(C,v,g,x,b[11],3174756917,10),x=m(x,C,v,g,b[2],718787259,15),g=m(g,x,C,v,b[9],3951481745,21),this._a=this._a+v|0,this._b=this._b+g|0,this._c=this._c+x|0,this._d=this._d+C|0},n.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var b=l.allocUnsafe(16);return b.writeInt32LE(this._a,0),b.writeInt32LE(this._b,4),b.writeInt32LE(this._c,8),b.writeInt32LE(this._d,12),b},a.exports=n},{"hash-base":425,inherits:440,"safe-buffer":494}],451:[function(e,a,f){var c=e("bn.js"),s=e("brorand");function l(i){this.rand=i||new s.Rand}a.exports=l,l.create=function(i){return new l(i)},l.prototype._randbelow=function(i){var n=i.bitLength(),o=Math.ceil(n/8);do var h=new c(this.rand.generate(o));while(h.cmp(i)>=0);return h},l.prototype._randrange=function(i,n){var o=n.sub(i);return i.add(this._randbelow(o))},l.prototype.test=function(i,n,o){var h=i.bitLength(),u=c.mont(i),d=new c(1).toRed(u);n||(n=Math.max(1,h/48|0));for(var m=i.subn(1),b=0;!m.testn(b);b++);for(var p=i.shrn(b),v=m.toRed(u);n>0;n--){var g=this._randrange(new c(2),m);o&&o(g);var x=g.toRed(u).redPow(p);if(x.cmp(d)!==0&&x.cmp(v)!==0){for(var C=1;C<b;C++){if((x=x.redSqr()).cmp(d)===0)return!1;if(x.cmp(v)===0)break}if(C===b)return!1}}return!0},l.prototype.getDivisor=function(i,n){var o=i.bitLength(),h=c.mont(i),u=new c(1).toRed(h);n||(n=Math.max(1,o/48|0));for(var d=i.subn(1),m=0;!d.testn(m);m++);for(var b=i.shrn(m),p=d.toRed(h);n>0;n--){var v=this._randrange(new c(2),d),g=i.gcd(v);if(g.cmpn(1)!==0)return g;var x=v.toRed(h).redPow(b);if(x.cmp(u)!==0&&x.cmp(p)!==0){for(var C=1;C<m;C++){if((x=x.redSqr()).cmp(u)===0)return x.fromRed().subn(1).gcd(i);if(x.cmp(p)===0)break}if(C===m)return(x=x.redSqr()).fromRed().subn(1).gcd(i)}}return!1}},{"bn.js":452,brorand:187}],452:[function(e,a,f){arguments[4][184][0].apply(f,arguments)},{buffer:188,dup:184}],453:[function(e,a,f){function c(s,l){if(!s)throw new Error(l||"Assertion failed")}a.exports=c,c.equal=function(s,l,i){if(s!=l)throw new Error(i||"Assertion failed: "+s+" != "+l)}},{}],454:[function(e,a,f){var c=f;function s(i){return i.length===1?"0"+i:i}function l(i){for(var n="",o=0;o<i.length;o++)n+=s(i[o].toString(16));return n}c.toArray=function(i,n){if(Array.isArray(i))return i.slice();if(!i)return[];var o=[];if(typeof i!="string"){for(var h=0;h<i.length;h++)o[h]=0|i[h];return o}if(n==="hex")for((i=i.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(i="0"+i),h=0;h<i.length;h+=2)o.push(parseInt(i[h]+i[h+1],16));else for(h=0;h<i.length;h++){var u=i.charCodeAt(h),d=u>>8,m=255&u;d?o.push(d,m):o.push(m)}return o},c.zero2=s,c.toHex=l,c.encode=function(i,n){return n==="hex"?l(i):i}},{}],455:[function(e,a,f){a.exports={"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"}},{}],456:[function(e,a,f){var c=e("asn1.js");f.certificate=e("./certificate");var s=c.define("RSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())});f.RSAPrivateKey=s;var l=c.define("RSAPublicKey",function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())});f.RSAPublicKey=l;var i=c.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(n),this.key("subjectPublicKey").bitstr())});f.PublicKey=i;var n=c.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())}),o=c.define("PrivateKeyInfo",function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(n),this.key("subjectPrivateKey").octstr())});f.PrivateKey=o;var h=c.define("EncryptedPrivateKeyInfo",function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())});f.EncryptedPrivateKey=h;var u=c.define("DSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())});f.DSAPrivateKey=u,f.DSAparam=c.define("DSAparam",function(){this.int()});var d=c.define("ECPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(m),this.key("publicKey").optional().explicit(1).bitstr())});f.ECPrivateKey=d;var m=c.define("ECParameters",function(){this.choice({namedCurve:this.objid()})});f.signature=c.define("signature",function(){this.seq().obj(this.key("r").int(),this.key("s").int())})},{"./certificate":457,"asn1.js":170}],457:[function(e,a,f){var c=e("asn1.js"),s=c.define("Time",function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})}),l=c.define("AttributeTypeValue",function(){this.seq().obj(this.key("type").objid(),this.key("value").any())}),i=c.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())}),n=c.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(i),this.key("subjectPublicKey").bitstr())}),o=c.define("RelativeDistinguishedName",function(){this.setof(l)}),h=c.define("RDNSequence",function(){this.seqof(o)}),u=c.define("Name",function(){this.choice({rdnSequence:this.use(h)})}),d=c.define("Validity",function(){this.seq().obj(this.key("notBefore").use(s),this.key("notAfter").use(s))}),m=c.define("Extension",function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())}),b=c.define("TBSCertificate",function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(i),this.key("issuer").use(u),this.key("validity").use(d),this.key("subject").use(u),this.key("subjectPublicKeyInfo").use(n),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(m).optional())}),p=c.define("X509Certificate",function(){this.seq().obj(this.key("tbsCertificate").use(b),this.key("signatureAlgorithm").use(i),this.key("signatureValue").bitstr())});a.exports=p},{"asn1.js":170}],458:[function(e,a,f){var c=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,s=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,l=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,i=e("evp_bytestokey"),n=e("browserify-aes"),o=e("safe-buffer").Buffer;a.exports=function(h,u){var d,m=h.toString(),b=m.match(c);if(b){var p="aes"+b[1],v=o.from(b[2],"hex"),g=o.from(b[3].replace(/[\r\n]/g,""),"base64"),x=i(u,v.slice(0,8),parseInt(b[1],10)).key,C=[],T=n.createDecipheriv(p,x,v);C.push(T.update(g)),C.push(T.final()),d=o.concat(C)}else{var R=m.match(l);d=o.from(R[2].replace(/[\r\n]/g,""),"base64")}return{tag:m.match(s)[1],data:d}}},{"browserify-aes":191,evp_bytestokey:423,"safe-buffer":494}],459:[function(e,a,f){var c=e("./asn1"),s=e("./aesid.json"),l=e("./fixProc"),i=e("browserify-aes"),n=e("pbkdf2"),o=e("safe-buffer").Buffer;function h(u){var d;typeof u!="object"||o.isBuffer(u)||(d=u.passphrase,u=u.key),typeof u=="string"&&(u=o.from(u));var m,b,p=l(u,d),v=p.tag,g=p.data;switch(v){case"CERTIFICATE":b=c.certificate.decode(g,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(b||(b=c.PublicKey.decode(g,"der")),m=b.algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return c.RSAPublicKey.decode(b.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return b.subjectPrivateKey=b.subjectPublicKey,{type:"ec",data:b};case"1.2.840.10040.4.1":return b.algorithm.params.pub_key=c.DSAparam.decode(b.subjectPublicKey.data,"der"),{type:"dsa",data:b.algorithm.params};default:throw new Error("unknown key id "+m)}case"ENCRYPTED PRIVATE KEY":g=function(x,C){var T=x.algorithm.decrypt.kde.kdeparams.salt,R=parseInt(x.algorithm.decrypt.kde.kdeparams.iters.toString(),10),B=s[x.algorithm.decrypt.cipher.algo.join(".")],I=x.algorithm.decrypt.cipher.iv,F=x.subjectPrivateKey,L=parseInt(B.split("-")[1],10)/8,V=n.pbkdf2Sync(C,T,R,L,"sha1"),z=i.createDecipheriv(B,V,I),E=[];return E.push(z.update(F)),E.push(z.final()),o.concat(E)}(g=c.EncryptedPrivateKey.decode(g,"der"),d);case"PRIVATE KEY":switch(m=(b=c.PrivateKey.decode(g,"der")).algorithm.algorithm.join(".")){case"1.2.840.113549.1.1.1":return c.RSAPrivateKey.decode(b.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:b.algorithm.curve,privateKey:c.ECPrivateKey.decode(b.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return b.algorithm.params.priv_key=c.DSAparam.decode(b.subjectPrivateKey,"der"),{type:"dsa",params:b.algorithm.params};default:throw new Error("unknown key id "+m)}case"RSA PUBLIC KEY":return c.RSAPublicKey.decode(g,"der");case"RSA PRIVATE KEY":return c.RSAPrivateKey.decode(g,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:c.DSAPrivateKey.decode(g,"der")};case"EC PRIVATE KEY":return{curve:(g=c.ECPrivateKey.decode(g,"der")).parameters.value,privateKey:g.privateKey};default:throw new Error("unknown key type "+v)}}a.exports=h,h.signature=c.signature},{"./aesid.json":455,"./asn1":456,"./fixProc":458,"browserify-aes":191,pbkdf2:460,"safe-buffer":494}],460:[function(e,a,f){f.pbkdf2=e("./lib/async"),f.pbkdf2Sync=e("./lib/sync")},{"./lib/async":461,"./lib/sync":464}],461:[function(e,a,f){(function(c){(function(){var s,l,i=e("safe-buffer").Buffer,n=e("./precondition"),o=e("./default-encoding"),h=e("./sync"),u=e("./to-buffer"),d=c.crypto&&c.crypto.subtle,m={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},b=[];function p(){return l||(l=c.process&&c.process.nextTick?c.process.nextTick:c.queueMicrotask?c.queueMicrotask:c.setImmediate?c.setImmediate:c.setTimeout)}function v(g,x,C,T,R){return d.importKey("raw",g,{name:"PBKDF2"},!1,["deriveBits"]).then(function(B){return d.deriveBits({name:"PBKDF2",salt:x,iterations:C,hash:{name:R}},B,T<<3)}).then(function(B){return i.from(B)})}a.exports=function(g,x,C,T,R,B){typeof R=="function"&&(B=R,R=void 0);var I=m[(R=R||"sha1").toLowerCase()];if(I&&typeof c.Promise=="function"){if(n(C,T),g=u(g,o,"Password"),x=u(x,o,"Salt"),typeof B!="function")throw new Error("No callback provided to pbkdf2");(function(F,L){F.then(function(V){p()(function(){L(null,V)})},function(V){p()(function(){L(V)})})})(function(F){if(c.process&&!c.process.browser||!d||!d.importKey||!d.deriveBits)return Promise.resolve(!1);if(b[F]!==void 0)return b[F];var L=v(s=s||i.alloc(8),s,10,128,F).then(function(){return!0}).catch(function(){return!1});return b[F]=L,L}(I).then(function(F){return F?v(g,x,C,T,I):h(g,x,C,T,R)}),B)}else p()(function(){var F;try{F=h(g,x,C,T,R)}catch(L){return B(L)}B(null,F)})}}).call(this)}).call(this,typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{"./default-encoding":462,"./precondition":463,"./sync":464,"./to-buffer":465,"safe-buffer":494}],462:[function(e,a,f){(function(c,s){(function(){var l;s.process&&s.process.browser?l="utf-8":s.process&&s.process.version?l=parseInt(c.version.split(".")[0].slice(1),10)>=6?"utf-8":"binary":l="utf-8",a.exports=l}).call(this)}).call(this,e("_process"),typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{_process:467}],463:[function(e,a,f){var c=Math.pow(2,30)-1;a.exports=function(s,l){if(typeof s!="number")throw new TypeError("Iterations not a number");if(s<0)throw new TypeError("Bad iterations");if(typeof l!="number")throw new TypeError("Key length not a number");if(l<0||l>c||l!=l)throw new TypeError("Bad key length")}},{}],464:[function(e,a,f){var c=e("create-hash/md5"),s=e("ripemd160"),l=e("sha.js"),i=e("safe-buffer").Buffer,n=e("./precondition"),o=e("./default-encoding"),h=e("./to-buffer"),u=i.alloc(128),d={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function m(b,p,v){var g=function(I){function F(L){return l(I).update(L).digest()}return I==="rmd160"||I==="ripemd160"?function(L){return new s().update(L).digest()}:I==="md5"?c:F}(b),x=b==="sha512"||b==="sha384"?128:64;p.length>x?p=g(p):p.length<x&&(p=i.concat([p,u],x));for(var C=i.allocUnsafe(x+d[b]),T=i.allocUnsafe(x+d[b]),R=0;R<x;R++)C[R]=54^p[R],T[R]=92^p[R];var B=i.allocUnsafe(x+v+4);C.copy(B,0,0,x),this.ipad1=B,this.ipad2=C,this.opad=T,this.alg=b,this.blocksize=x,this.hash=g,this.size=d[b]}m.prototype.run=function(b,p){return b.copy(p,this.blocksize),this.hash(p).copy(this.opad,this.blocksize),this.hash(this.opad)},a.exports=function(b,p,v,g,x){n(v,g);var C=new m(x=x||"sha1",b=h(b,o,"Password"),(p=h(p,o,"Salt")).length),T=i.allocUnsafe(g),R=i.allocUnsafe(p.length+4);p.copy(R,0,0,p.length);for(var B=0,I=d[x],F=Math.ceil(g/I),L=1;L<=F;L++){R.writeUInt32BE(L,p.length);for(var V=C.run(R,C.ipad1),z=V,E=1;E<v;E++){z=C.run(z,C.ipad2);for(var P=0;P<I;P++)V[P]^=z[P]}V.copy(T,B),B+=I}return T}},{"./default-encoding":462,"./precondition":463,"./to-buffer":465,"create-hash/md5":387,ripemd160:493,"safe-buffer":494,"sha.js":498}],465:[function(e,a,f){var c=e("safe-buffer").Buffer;a.exports=function(s,l,i){if(c.isBuffer(s))return s;if(typeof s=="string")return c.from(s,l);if(ArrayBuffer.isView(s))return c.from(s.buffer);throw new TypeError(i+" must be a string, a Buffer, a typed array or a DataView")}},{"safe-buffer":494}],466:[function(e,a,f){(function(c){(function(){c===void 0||!c.version||c.version.indexOf("v0.")===0||c.version.indexOf("v1.")===0&&c.version.indexOf("v1.8.")!==0?a.exports={nextTick:function(s,l,i,n){if(typeof s!="function")throw new TypeError('"callback" argument must be a function');var o,h,u=arguments.length;switch(u){case 0:case 1:return c.nextTick(s);case 2:return c.nextTick(function(){s.call(null,l)});case 3:return c.nextTick(function(){s.call(null,l,i)});case 4:return c.nextTick(function(){s.call(null,l,i,n)});default:for(o=new Array(u-1),h=0;h<o.length;)o[h++]=arguments[h];return c.nextTick(function(){s.apply(null,o)})}}}:a.exports=c}).call(this)}).call(this,e("_process"))},{_process:467}],467:[function(e,a,f){var c,s,l=a.exports={};function i(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(x){if(c===setTimeout)return setTimeout(x,0);if((c===i||!c)&&setTimeout)return c=setTimeout,setTimeout(x,0);try{return c(x,0)}catch{try{return c.call(null,x,0)}catch{return c.call(this,x,0)}}}(function(){try{c=typeof setTimeout=="function"?setTimeout:i}catch{c=i}try{s=typeof clearTimeout=="function"?clearTimeout:n}catch{s=n}})();var h,u=[],d=!1,m=-1;function b(){d&&h&&(d=!1,h.length?u=h.concat(u):m=-1,u.length&&p())}function p(){if(!d){var x=o(b);d=!0;for(var C=u.length;C;){for(h=u,u=[];++m<C;)h&&h[m].run();m=-1,C=u.length}h=null,d=!1,function(T){if(s===clearTimeout)return clearTimeout(T);if((s===n||!s)&&clearTimeout)return s=clearTimeout,clearTimeout(T);try{s(T)}catch{try{return s.call(null,T)}catch{return s.call(this,T)}}}(x)}}function v(x,C){this.fun=x,this.array=C}function g(){}l.nextTick=function(x){var C=new Array(arguments.length-1);if(arguments.length>1)for(var T=1;T<arguments.length;T++)C[T-1]=arguments[T];u.push(new v(x,C)),u.length!==1||d||o(p)},v.prototype.run=function(){this.fun.apply(null,this.array)},l.title="browser",l.browser=!0,l.env={},l.argv=[],l.version="",l.versions={},l.on=g,l.addListener=g,l.once=g,l.off=g,l.removeListener=g,l.removeAllListeners=g,l.emit=g,l.prependListener=g,l.prependOnceListener=g,l.listeners=function(x){return[]},l.binding=function(x){throw new Error("process.binding is not supported")},l.cwd=function(){return"/"},l.chdir=function(x){throw new Error("process.chdir is not supported")},l.umask=function(){return 0}},{}],468:[function(e,a,f){f.publicEncrypt=e("./publicEncrypt"),f.privateDecrypt=e("./privateDecrypt"),f.privateEncrypt=function(c,s){return f.publicEncrypt(c,s,!0)},f.publicDecrypt=function(c,s){return f.privateDecrypt(c,s,!0)}},{"./privateDecrypt":471,"./publicEncrypt":472}],469:[function(e,a,f){var c=e("create-hash"),s=e("safe-buffer").Buffer;function l(i){var n=s.allocUnsafe(4);return n.writeUInt32BE(i,0),n}a.exports=function(i,n){for(var o,h=s.alloc(0),u=0;h.length<n;)o=l(u++),h=s.concat([h,c("sha1").update(i).update(o).digest()]);return h.slice(0,n)}},{"create-hash":386,"safe-buffer":494}],470:[function(e,a,f){arguments[4][184][0].apply(f,arguments)},{buffer:188,dup:184}],471:[function(e,a,f){var c=e("parse-asn1"),s=e("./mgf"),l=e("./xor"),i=e("bn.js"),n=e("browserify-rsa"),o=e("create-hash"),h=e("./withPublic"),u=e("safe-buffer").Buffer;a.exports=function(d,m,b){var p;p=d.padding?d.padding:b?1:4;var v,g=c(d),x=g.modulus.byteLength();if(m.length>x||new i(m).cmp(g.modulus)>=0)throw new Error("decryption error");v=b?h(new i(m),g):n(m,g);var C=u.alloc(x-v.length);if(v=u.concat([C,v],x),p===4)return function(T,R){var B=T.modulus.byteLength(),I=o("sha1").update(u.alloc(0)).digest(),F=I.length;if(R[0]!==0)throw new Error("decryption error");var L=R.slice(1,F+1),V=R.slice(F+1),z=l(L,s(V,F)),E=l(V,s(z,B-F-1));if(function(k,y){k=u.from(k),y=u.from(y);var w=0,_=k.length;k.length!==y.length&&(w++,_=Math.min(k.length,y.length));for(var S=-1;++S<_;)w+=k[S]^y[S];return w}(I,E.slice(0,F)))throw new Error("decryption error");for(var P=F;E[P]===0;)P++;if(E[P++]!==1)throw new Error("decryption error");return E.slice(P)}(g,v);if(p===1)return function(T,R,B){for(var I=R.slice(0,2),F=2,L=0;R[F++]!==0;)if(F>=R.length){L++;break}var V=R.slice(2,F-1);if((I.toString("hex")!=="0002"&&!B||I.toString("hex")!=="0001"&&B)&&L++,V.length<8&&L++,L)throw new Error("decryption error");return R.slice(F)}(0,v,b);if(p===3)return v;throw new Error("unknown padding")}},{"./mgf":469,"./withPublic":473,"./xor":474,"bn.js":470,"browserify-rsa":209,"create-hash":386,"parse-asn1":459,"safe-buffer":494}],472:[function(e,a,f){var c=e("parse-asn1"),s=e("randombytes"),l=e("create-hash"),i=e("./mgf"),n=e("./xor"),o=e("bn.js"),h=e("./withPublic"),u=e("browserify-rsa"),d=e("safe-buffer").Buffer;a.exports=function(m,b,p){var v;v=m.padding?m.padding:p?1:4;var g,x=c(m);if(v===4)g=function(C,T){var R=C.modulus.byteLength(),B=T.length,I=l("sha1").update(d.alloc(0)).digest(),F=I.length,L=2*F;if(B>R-L-2)throw new Error("message too long");var V=d.alloc(R-B-L-2),z=R-F-1,E=s(F),P=n(d.concat([I,V,d.alloc(1,1),T],z),i(E,z)),k=n(E,i(P,F));return new o(d.concat([d.alloc(1),k,P],R))}(x,b);else if(v===1)g=function(C,T,R){var B,I=T.length,F=C.modulus.byteLength();if(I>F-11)throw new Error("message too long");return B=R?d.alloc(F-I-3,255):function(L){for(var V,z=d.allocUnsafe(L),E=0,P=s(2*L),k=0;E<L;)k===P.length&&(P=s(2*L),k=0),(V=P[k++])&&(z[E++]=V);return z}(F-I-3),new o(d.concat([d.from([0,R?1:2]),B,d.alloc(1),T],F))}(x,b,p);else{if(v!==3)throw new Error("unknown padding");if((g=new o(b)).cmp(x.modulus)>=0)throw new Error("data too long for modulus")}return p?u(g,x):h(g,x)}},{"./mgf":469,"./withPublic":473,"./xor":474,"bn.js":470,"browserify-rsa":209,"create-hash":386,"parse-asn1":459,randombytes:475,"safe-buffer":494}],473:[function(e,a,f){var c=e("bn.js"),s=e("safe-buffer").Buffer;a.exports=function(l,i){return s.from(l.toRed(c.mont(i.modulus)).redPow(new c(i.publicExponent)).fromRed().toArray())}},{"bn.js":470,"safe-buffer":494}],474:[function(e,a,f){a.exports=function(c,s){for(var l=c.length,i=-1;++i<l;)c[i]^=s[i];return c}},{}],475:[function(e,a,f){(function(c,s){(function(){var l=e("safe-buffer").Buffer,i=s.crypto||s.msCrypto;i&&i.getRandomValues?a.exports=function(n,o){if(n>4294967295)throw new RangeError("requested too many random bytes");var h=l.allocUnsafe(n);if(n>0)if(n>65536)for(var u=0;u<n;u+=65536)i.getRandomValues(h.slice(u,u+65536));else i.getRandomValues(h);return typeof o=="function"?c.nextTick(function(){o(null,h)}):h}:a.exports=function(){throw new Error(`Secure random number generation is not supported by this browser. Use Chrome, Firefox or Internet Explorer 11`)}}).call(this)}).call(this,e("_process"),typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{_process:467,"safe-buffer":494}],476:[function(e,a,f){(function(c,s){(function(){function l(){throw new Error(`secure random number generation not supported by this browser use chrome, FireFox or Internet Explorer 11`)}var i=e("safe-buffer"),n=e("randombytes"),o=i.Buffer,h=i.kMaxLength,u=s.crypto||s.msCrypto,d=Math.pow(2,32)-1;function m(v,g){if(typeof v!="number"||v!=v)throw new TypeError("offset must be a number");if(v>d||v<0)throw new TypeError("offset must be a uint32");if(v>h||v>g)throw new RangeError("offset out of range")}function b(v,g,x){if(typeof v!="number"||v!=v)throw new TypeError("size must be a number");if(v>d||v<0)throw new TypeError("size must be a uint32");if(v+g>x||v>h)throw new RangeError("buffer too small")}function p(v,g,x,C){if(c.browser){var T=v.buffer,R=new Uint8Array(T,g,x);return u.getRandomValues(R),C?void c.nextTick(function(){C(null,v)}):v}if(!C)return n(x).copy(v,g),v;n(x,function(B,I){if(B)return C(B);I.copy(v,g),C(null,v)})}u&&u.getRandomValues||!c.browser?(f.randomFill=function(v,g,x,C){if(!(o.isBuffer(v)||v instanceof s.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if(typeof g=="function")C=g,g=0,x=v.length;else if(typeof x=="function")C=x,x=v.length-g;else if(typeof C!="function")throw new TypeError('"cb" argument must be a function');return m(g,v.length),b(x,g,v.length),p(v,g,x,C)},f.randomFillSync=function(v,g,x){if(g===void 0&&(g=0),!(o.isBuffer(v)||v instanceof s.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');return m(g,v.length),x===void 0&&(x=v.length-g),b(x,g,v.length),p(v,g,x)}):(f.randomFill=l,f.randomFillSync=l)}).call(this)}).call(this,e("_process"),typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{_process:467,randombytes:475,"safe-buffer":494}],477:[function(e,a,f){var c={};function s(i,n,o){o||(o=Error);var h=function(u){var d,m;function b(p,v,g){return u.call(this,function(x,C,T){return typeof n=="string"?n:n(x,C,T)}(p,v,g))||this}return m=u,(d=b).prototype=Object.create(m.prototype),d.prototype.constructor=d,d.__proto__=m,b}(o);h.prototype.name=o.name,h.prototype.code=i,c[i]=h}function l(i,n){if(Array.isArray(i)){var o=i.length;return i=i.map(function(h){return String(h)}),o>2?"one of ".concat(n," ").concat(i.slice(0,o-1).join(", "),", or ")+i[o-1]:o===2?"one of ".concat(n," ").concat(i[0]," or ").concat(i[1]):"of ".concat(n," ").concat(i[0])}return"of ".concat(n," ").concat(String(i))}s("ERR_INVALID_OPT_VALUE",function(i,n){return'The value "'+n+'" is invalid for option "'+i+'"'},TypeError),s("ERR_INVALID_ARG_TYPE",function(i,n,o){var h,u,d;if(typeof n=="string"&&(u="not ",n.substr(0,u.length)===u)?(h="must not be",n=n.replace(/^not /,"")):h="must be",function(b,p,v){return(v===void 0||v>b.length)&&(v=b.length),b.substring(v-p.length,v)===p}(i," argument"))d="The ".concat(i," ").concat(h," ").concat(l(n,"type"));else{var m=function(b,p,v){return typeof v!="number"&&(v=0),!(v+p.length>b.length)&&b.indexOf(p,v)!==-1}(i,".")?"property":"argument";d='The "'.concat(i,'" ').concat(m," ").concat(h," ").concat(l(n,"type"))}return d+=". Received type ".concat(typeof o)},TypeError),s("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),s("ERR_METHOD_NOT_IMPLEMENTED",function(i){return"The "+i+" method is not implemented"}),s("ERR_STREAM_PREMATURE_CLOSE","Premature close"),s("ERR_STREAM_DESTROYED",function(i){return"Cannot call "+i+" after a stream was destroyed"}),s("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),s("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),s("ERR_STREAM_WRITE_AFTER_END","write after end"),s("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),s("ERR_UNKNOWN_ENCODING",function(i){return"Unknown encoding: "+i},TypeError),s("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),a.exports.codes=c},{}],478:[function(e,a,f){(function(c){(function(){var s=Object.keys||function(b){var p=[];for(var v in b)p.push(v);return p};a.exports=u;var l=e("./_stream_readable"),i=e("./_stream_writable");e("inherits")(u,l);for(var n=s(i.prototype),o=0;o<n.length;o++){var h=n[o];u.prototype[h]||(u.prototype[h]=i.prototype[h])}function u(b){if(!(this instanceof u))return new u(b);l.call(this,b),i.call(this,b),this.allowHalfOpen=!0,b&&(b.readable===!1&&(this.readable=!1),b.writable===!1&&(this.writable=!1),b.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",d)))}function d(){this._writableState.ended||c.nextTick(m,this)}function m(b){b.end()}Object.defineProperty(u.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(u.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(u.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(u.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState!==void 0&&this._writableState!==void 0&&this._readableState.destroyed&&this._writableState.destroyed},set:function(b){this._readableState!==void 0&&this._writableState!==void 0&&(this._readableState.destroyed=b,this._writableState.destroyed=b)}})}).call(this)}).call(this,e("_process"))},{"./_stream_readable":480,"./_stream_writable":482,_process:467,inherits:440}],479:[function(e,a,f){a.exports=s;var c=e("./_stream_transform");function s(l){if(!(this instanceof s))return new s(l);c.call(this,l)}e("inherits")(s,c),s.prototype._transform=function(l,i,n){n(null,l)}},{"./_stream_transform":481,inherits:440}],480:[function(e,a,f){(function(c,s){(function(){var l;a.exports=z,z.ReadableState=V,e("events").EventEmitter;var i=function(M,j){return M.listeners(j).length},n=e("./internal/streams/stream"),o=e("buffer").Buffer,h=(s!==void 0?s:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){},u,d=e("util");u=d&&d.debuglog?d.debuglog("stream"):function(){};var m,b,p,v=e("./internal/streams/buffer_list"),g=e("./internal/streams/destroy"),x=e("./internal/streams/state").getHighWaterMark,C=e("../errors").codes,T=C.ERR_INVALID_ARG_TYPE,R=C.ERR_STREAM_PUSH_AFTER_EOF,B=C.ERR_METHOD_NOT_IMPLEMENTED,I=C.ERR_STREAM_UNSHIFT_AFTER_END_EVENT;e("inherits")(z,n);var F=g.errorOrDestroy,L=["error","close","destroy","pause","resume"];function V(M,j,$){l=l||e("./_stream_duplex"),M=M||{},typeof $!="boolean"&&($=j instanceof l),this.objectMode=!!M.objectMode,$&&(this.objectMode=this.objectMode||!!M.readableObjectMode),this.highWaterMark=x(this,M,"readableHighWaterMark",$),this.buffer=new v,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=M.emitClose!==!1,this.autoDestroy=!!M.autoDestroy,this.destroyed=!1,this.defaultEncoding=M.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,M.encoding&&(m||(m=e("string_decoder/").StringDecoder),this.decoder=new m(M.encoding),this.encoding=M.encoding)}function z(M){if(l=l||e("./_stream_duplex"),!(this instanceof z))return new z(M);var j=this instanceof l;this._readableState=new V(M,this,j),this.readable=!0,M&&(typeof M.read=="function"&&(this._read=M.read),typeof M.destroy=="function"&&(this._destroy=M.destroy)),n.call(this)}function E(M,j,$,K,J){u("readableAddChunk",j);var X,Q=M._readableState;if(j===null)Q.reading=!1,function(ee,se){if(u("onEofChunk"),!se.ended){if(se.decoder){var Y=se.decoder.end();Y&&Y.length&&(se.buffer.push(Y),se.length+=se.objectMode?1:Y.length)}se.ended=!0,se.sync?y(ee):(se.needReadable=!1,se.emittedReadable||(se.emittedReadable=!0,w(ee)))}}(M,Q);else if(J||(X=function(ee,se){var Y;te=se,o.isBuffer(te)||te instanceof h||typeof se=="string"||se===void 0||ee.objectMode||(Y=new T("chunk",["string","Buffer","Uint8Array"],se));var te;return Y}(Q,j)),X)F(M,X);else if(Q.objectMode||j&&j.length>0)if(typeof j=="string"||Q.objectMode||Object.getPrototypeOf(j)===o.prototype||(j=function(ee){return o.from(ee)}(j)),K)Q.endEmitted?F(M,new I):P(M,Q,j,!0);else if(Q.ended)F(M,new R);else{if(Q.destroyed)return!1;Q.reading=!1,Q.decoder&&!$?(j=Q.decoder.write(j),Q.objectMode||j.length!==0?P(M,Q,j,!1):_(M,Q)):P(M,Q,j,!1)}else K||(Q.reading=!1,_(M,Q));return!Q.ended&&(Q.length<Q.highWaterMark||Q.length===0)}function P(M,j,$,K){j.flowing&&j.length===0&&!j.sync?(j.awaitDrain=0,M.emit("data",$)):(j.length+=j.objectMode?1:$.length,K?j.buffer.unshift($):j.buffer.push($),j.needReadable&&y(M)),_(M,j)}Object.defineProperty(z.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState!==void 0&&this._readableState.destroyed},set:function(M){this._readableState&&(this._readableState.destroyed=M)}}),z.prototype.destroy=g.destroy,z.prototype._undestroy=g.undestroy,z.prototype._destroy=function(M,j){j(M)},z.prototype.push=function(M,j){var $,K=this._readableState;return K.objectMode?$=!0:typeof M=="string"&&((j=j||K.defaultEncoding)!==K.encoding&&(M=o.from(M,j),j=""),$=!0),E(this,M,j,!1,$)},z.prototype.unshift=function(M){return E(this,M,null,!0,!1)},z.prototype.isPaused=function(){return this._readableState.flowing===!1},z.prototype.setEncoding=function(M){m||(m=e("string_decoder/").StringDecoder);var j=new m(M);this._readableState.decoder=j,this._readableState.encoding=this._readableState.decoder.encoding;for(var $=this._readableState.buffer.head,K="";$!==null;)K+=j.write($.data),$=$.next;return this._readableState.buffer.clear(),K!==""&&this._readableState.buffer.push(K),this._readableState.length=K.length,this};function k(M,j){return M<=0||j.length===0&&j.ended?0:j.objectMode?1:M!=M?j.flowing&&j.length?j.buffer.head.data.length:j.length:(M>j.highWaterMark&&(j.highWaterMark=function($){return $>=1073741824?$=1073741824:($--,$|=$>>>1,$|=$>>>2,$|=$>>>4,$|=$>>>8,$|=$>>>16,$++),$}(M)),M<=j.length?M:j.ended?j.length:(j.needReadable=!0,0))}function y(M){var j=M._readableState;u("emitReadable",j.needReadable,j.emittedReadable),j.needReadable=!1,j.emittedReadable||(u("emitReadable",j.flowing),j.emittedReadable=!0,c.nextTick(w,M))}function w(M){var j=M._readableState;u("emitReadable_",j.destroyed,j.length,j.ended),j.destroyed||!j.length&&!j.ended||(M.emit("readable"),j.emittedReadable=!1),j.needReadable=!j.flowing&&!j.ended&&j.length<=j.highWaterMark,U(M)}function _(M,j){j.readingMore||(j.readingMore=!0,c.nextTick(S,M,j))}function S(M,j){for(;!j.reading&&!j.ended&&(j.length<j.highWaterMark||j.flowing&&j.length===0);){var $=j.length;if(u("maybeReadMore read 0"),M.read(0),$===j.length)break}j.readingMore=!1}function A(M){var j=M._readableState;j.readableListening=M.listenerCount("readable")>0,j.resumeScheduled&&!j.paused?j.flowing=!0:M.listenerCount("data")>0&&M.resume()}function O(M){u("readable nexttick read 0"),M.read(0)}function N(M,j){u("resume",j.reading),j.reading||M.read(0),j.resumeScheduled=!1,M.emit("resume"),U(M),j.flowing&&!j.reading&&M.read(0)}function U(M){var j=M._readableState;for(u("flow",j.flowing);j.flowing&&M.read()!==null;);}function H(M,j){return j.length===0?null:(j.objectMode?$=j.buffer.shift():!M||M>=j.length?($=j.decoder?j.buffer.join(""):j.buffer.length===1?j.buffer.first():j.buffer.concat(j.length),j.buffer.clear()):$=j.buffer.consume(M,j.decoder),$);var $}function Z(M){var j=M._readableState;u("endReadable",j.endEmitted),j.endEmitted||(j.ended=!0,c.nextTick(D,j,M))}function D(M,j){if(u("endReadableNT",M.endEmitted,M.length),!M.endEmitted&&M.length===0&&(M.endEmitted=!0,j.readable=!1,j.emit("end"),M.autoDestroy)){var $=j._writableState;(!$||$.autoDestroy&&$.finished)&&j.destroy()}}function q(M,j){for(var $=0,K=M.length;$<K;$++)if(M[$]===j)return $;return-1}z.prototype.read=function(M){u("read",M),M=parseInt(M,10);var j=this._readableState,$=M;if(M!==0&&(j.emittedReadable=!1),M===0&&j.needReadable&&((j.highWaterMark!==0?j.length>=j.highWaterMark:j.length>0)||j.ended))return u("read: emitReadable",j.length,j.ended),j.length===0&&j.ended?Z(this):y(this),null;if((M=k(M,j))===0&&j.ended)return j.length===0&&Z(this),null;var K,J=j.needReadable;return u("need readable",J),(j.length===0||j.length-M<j.highWaterMark)&&u("length less than watermark",J=!0),j.ended||j.reading?u("reading or ended",J=!1):J&&(u("do read"),j.reading=!0,j.sync=!0,j.length===0&&(j.needReadable=!0),this._read(j.highWaterMark),j.sync=!1,j.reading||(M=k($,j))),(K=M>0?H(M,j):null)===null?(j.needReadable=j.length<=j.highWaterMark,M=0):(j.length-=M,j.awaitDrain=0),j.length===0&&(j.ended||(j.needReadable=!0),$!==M&&j.ended&&Z(this)),K!==null&&this.emit("data",K),K},z.prototype._read=function(M){F(this,new B("_read()"))},z.prototype.pipe=function(M,j){var $=this,K=this._readableState;switch(K.pipesCount){case 0:K.pipes=M;break;case 1:K.pipes=[K.pipes,M];break;default:K.pipes.push(M)}K.pipesCount+=1,u("pipe count=%d opts=%j",K.pipesCount,j);var J=(!j||j.end!==!1)&&M!==c.stdout&&M!==c.stderr?Q:ae;function X(ce,me){u("onunpipe"),ce===$&&me&&me.hasUnpiped===!1&&(me.hasUnpiped=!0,u("cleanup"),M.removeListener("close",ne),M.removeListener("finish",oe),M.removeListener("drain",ee),M.removeListener("error",te),M.removeListener("unpipe",X),$.removeListener("end",Q),$.removeListener("end",ae),$.removeListener("data",Y),se=!0,!K.awaitDrain||M._writableState&&!M._writableState.needDrain||ee())}function Q(){u("onend"),M.end()}K.endEmitted?c.nextTick(J):$.once("end",J),M.on("unpipe",X);var ee=function(ce){return function(){var me=ce._readableState;u("pipeOnDrain",me.awaitDrain),me.awaitDrain&&me.awaitDrain--,me.awaitDrain===0&&i(ce,"data")&&(me.flowing=!0,U(ce))}}($);M.on("drain",ee);var se=!1;function Y(ce){u("ondata");var me=M.write(ce);u("dest.write",me),me===!1&&((K.pipesCount===1&&K.pipes===M||K.pipesCount>1&&q(K.pipes,M)!==-1)&&!se&&(u("false write response, pause",K.awaitDrain),K.awaitDrain++),$.pause())}function te(ce){u("onerror",ce),ae(),M.removeListener("error",te),i(M,"error")===0&&F(M,ce)}function ne(){M.removeListener("finish",oe),ae()}function oe(){u("onfinish"),M.removeListener("close",ne),ae()}function ae(){u("unpipe"),$.unpipe(M)}return $.on("data",Y),function(ce,me,be){if(typeof ce.prependListener=="function")return ce.prependListener(me,be);ce._events&&ce._events[me]?Array.isArray(ce._events[me])?ce._events[me].unshift(be):ce._events[me]=[be,ce._events[me]]:ce.on(me,be)}(M,"error",te),M.once("close",ne),M.once("finish",oe),M.emit("pipe",$),K.flowing||(u("pipe resume"),$.resume()),M},z.prototype.unpipe=function(M){var j=this._readableState,$={hasUnpiped:!1};if(j.pipesCount===0)return this;if(j.pipesCount===1)return M&&M!==j.pipes||(M||(M=j.pipes),j.pipes=null,j.pipesCount=0,j.flowing=!1,M&&M.emit("unpipe",this,$)),this;if(!M){var K=j.pipes,J=j.pipesCount;j.pipes=null,j.pipesCount=0,j.flowing=!1;for(var X=0;X<J;X++)K[X].emit("unpipe",this,{hasUnpiped:!1});return this}var Q=q(j.pipes,M);return Q===-1||(j.pipes.splice(Q,1),j.pipesCount-=1,j.pipesCount===1&&(j.pipes=j.pipes[0]),M.emit("unpipe",this,$)),this},z.prototype.on=function(M,j){var $=n.prototype.on.call(this,M,j),K=this._readableState;return M==="data"?(K.readableListening=this.listenerCount("readable")>0,K.flowing!==!1&&this.resume()):M==="readable"&&(K.endEmitted||K.readableListening||(K.readableListening=K.needReadable=!0,K.flowing=!1,K.emittedReadable=!1,u("on readable",K.length,K.reading),K.length?y(this):K.reading||c.nextTick(O,this))),$},z.prototype.addListener=z.prototype.on,z.prototype.removeListener=function(M,j){var $=n.prototype.removeListener.call(this,M,j);return M==="readable"&&c.nextTick(A,this),$},z.prototype.removeAllListeners=function(M){var j=n.prototype.removeAllListeners.apply(this,arguments);return M!=="readable"&&M!==void 0||c.nextTick(A,this),j},z.prototype.resume=function(){var M=this._readableState;return M.flowing||(u("resume"),M.flowing=!M.readableListening,function(j,$){$.resumeScheduled||($.resumeScheduled=!0,c.nextTick(N,j,$))}(this,M)),M.paused=!1,this},z.prototype.pause=function(){return u("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(u("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},z.prototype.wrap=function(M){var j=this,$=this._readableState,K=!1;for(var J in M.on("end",function(){if(u("wrapped end"),$.decoder&&!$.ended){var Q=$.decoder.end();Q&&Q.length&&j.push(Q)}j.push(null)}),M.on("data",function(Q){u("wrapped data"),$.decoder&&(Q=$.decoder.write(Q)),$.objectMode&&Q==null||($.objectMode||Q&&Q.length)&&(j.push(Q)||(K=!0,M.pause()))}),M)this[J]===void 0&&typeof M[J]=="function"&&(this[J]=function(Q){return function(){return M[Q].apply(M,arguments)}}(J));for(var X=0;X<L.length;X++)M.on(L[X],this.emit.bind(this,L[X]));return this._read=function(Q){u("wrapped _read",Q),K&&(K=!1,M.resume())},this},typeof Symbol=="function"&&(z.prototype[Symbol.asyncIterator]=function(){return b===void 0&&(b=e("./internal/streams/async_iterator")),b(this)}),Object.defineProperty(z.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(z.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(z.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(M){this._readableState&&(this._readableState.flowing=M)}}),z._fromList=H,Object.defineProperty(z.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}}),typeof Symbol=="function"&&(z.from=function(M,j){return p===void 0&&(p=e("./internal/streams/from")),p(z,M,j)})}).call(this)}).call(this,e("_process"),typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{"../errors":477,"./_stream_duplex":478,"./internal/streams/async_iterator":483,"./internal/streams/buffer_list":484,"./internal/streams/destroy":485,"./internal/streams/from":487,"./internal/streams/state":489,"./internal/streams/stream":490,_process:467,buffer:220,events:422,inherits:440,"string_decoder/":522,util:188}],481:[function(e,a,f){a.exports=u;var c=e("../errors").codes,s=c.ERR_METHOD_NOT_IMPLEMENTED,l=c.ERR_MULTIPLE_CALLBACK,i=c.ERR_TRANSFORM_ALREADY_TRANSFORMING,n=c.ERR_TRANSFORM_WITH_LENGTH_0,o=e("./_stream_duplex");function h(b,p){var v=this._transformState;v.transforming=!1;var g=v.writecb;if(g===null)return this.emit("error",new l);v.writechunk=null,v.writecb=null,p!=null&&this.push(p),g(b);var x=this._readableState;x.reading=!1,(x.needReadable||x.length<x.highWaterMark)&&this._read(x.highWaterMark)}function u(b){if(!(this instanceof u))return new u(b);o.call(this,b),this._transformState={afterTransform:h.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,b&&(typeof b.transform=="function"&&(this._transform=b.transform),typeof b.flush=="function"&&(this._flush=b.flush)),this.on("prefinish",d)}function d(){var b=this;typeof this._flush!="function"||this._readableState.destroyed?m(this,null,null):this._flush(function(p,v){m(b,p,v)})}function m(b,p,v){if(p)return b.emit("error",p);if(v!=null&&b.push(v),b._writableState.length)throw new n;if(b._transformState.transforming)throw new i;return b.push(null)}e("inherits")(u,o),u.prototype.push=function(b,p){return this._transformState.needTransform=!1,o.prototype.push.call(this,b,p)},u.prototype._transform=function(b,p,v){v(new s("_transform()"))},u.prototype._write=function(b,p,v){var g=this._transformState;if(g.writecb=v,g.writechunk=b,g.writeencoding=p,!g.transforming){var x=this._readableState;(g.needTransform||x.needReadable||x.length<x.highWaterMark)&&this._read(x.highWaterMark)}},u.prototype._read=function(b){var p=this._transformState;p.writechunk===null||p.transforming?p.needTransform=!0:(p.transforming=!0,this._transform(p.writechunk,p.writeencoding,p.afterTransform))},u.prototype._destroy=function(b,p){o.prototype._destroy.call(this,b,function(v){p(v)})}},{"../errors":477,"./_stream_duplex":478,inherits:440}],482:[function(e,a,f){(function(c,s){(function(){function l(S){var A=this;this.next=null,this.entry=null,this.finish=function(){(function(O,N,U){var H=O.entry;for(O.entry=null;H;){var Z=H.callback;N.pendingcb--,Z(U),H=H.next}N.corkedRequestsFree.next=O})(A,S)}}var i;a.exports=z,z.WritableState=V;var n={deprecate:e("util-deprecate")},o=e("./internal/streams/stream"),h=e("buffer").Buffer,u=(s!==void 0?s:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){},d,m=e("./internal/streams/destroy"),b=e("./internal/streams/state").getHighWaterMark,p=e("../errors").codes,v=p.ERR_INVALID_ARG_TYPE,g=p.ERR_METHOD_NOT_IMPLEMENTED,x=p.ERR_MULTIPLE_CALLBACK,C=p.ERR_STREAM_CANNOT_PIPE,T=p.ERR_STREAM_DESTROYED,R=p.ERR_STREAM_NULL_VALUES,B=p.ERR_STREAM_WRITE_AFTER_END,I=p.ERR_UNKNOWN_ENCODING,F=m.errorOrDestroy;function L(){}function V(S,A,O){i=i||e("./_stream_duplex"),S=S||{},typeof O!="boolean"&&(O=A instanceof i),this.objectMode=!!S.objectMode,O&&(this.objectMode=this.objectMode||!!S.writableObjectMode),this.highWaterMark=b(this,S,"writableHighWaterMark",O),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var N=S.decodeStrings===!1;this.decodeStrings=!N,this.defaultEncoding=S.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(U){(function(H,Z){var D=H._writableState,q=D.sync,M=D.writecb;if(typeof M!="function")throw new x;if(function($){$.writing=!1,$.writecb=null,$.length-=$.writelen,$.writelen=0}(D),Z)(function($,K,J,X,Q){--K.pendingcb,J?(c.nextTick(Q,X),c.nextTick(_,$,K),$._writableState.errorEmitted=!0,F($,X)):(Q(X),$._writableState.errorEmitted=!0,F($,X),_($,K))})(H,D,q,Z,M);else{var j=y(D)||H.destroyed;j||D.corked||D.bufferProcessing||!D.bufferedRequest||k(H,D),q?c.nextTick(P,H,D,j,M):P(H,D,j,M)}})(A,U)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=S.emitClose!==!1,this.autoDestroy=!!S.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new l(this)}function z(S){var A=this instanceof(i=i||e("./_stream_duplex"));if(!A&&!d.call(z,this))return new z(S);this._writableState=new V(S,this,A),this.writable=!0,S&&(typeof S.write=="function"&&(this._write=S.write),typeof S.writev=="function"&&(this._writev=S.writev),typeof S.destroy=="function"&&(this._destroy=S.destroy),typeof S.final=="function"&&(this._final=S.final)),o.call(this)}function E(S,A,O,N,U,H,Z){A.writelen=N,A.writecb=Z,A.writing=!0,A.sync=!0,A.destroyed?A.onwrite(new T("write")):O?S._writev(U,A.onwrite):S._write(U,H,A.onwrite),A.sync=!1}function P(S,A,O,N){O||function(U,H){H.length===0&&H.needDrain&&(H.needDrain=!1,U.emit("drain"))}(S,A),A.pendingcb--,N(),_(S,A)}function k(S,A){A.bufferProcessing=!0;var O=A.bufferedRequest;if(S._writev&&O&&O.next){var N=A.bufferedRequestCount,U=new Array(N),H=A.corkedRequestsFree;H.entry=O;for(var Z=0,D=!0;O;)U[Z]=O,O.isBuf||(D=!1),O=O.next,Z+=1;U.allBuffers=D,E(S,A,!0,A.length,U,"",H.finish),A.pendingcb++,A.lastBufferedRequest=null,H.next?(A.corkedRequestsFree=H.next,H.next=null):A.corkedRequestsFree=new l(A),A.bufferedRequestCount=0}else{for(;O;){var q=O.chunk,M=O.encoding,j=O.callback;if(E(S,A,!1,A.objectMode?1:q.length,q,M,j),O=O.next,A.bufferedRequestCount--,A.writing)break}O===null&&(A.lastBufferedRequest=null)}A.bufferedRequest=O,A.bufferProcessing=!1}function y(S){return S.ending&&S.length===0&&S.bufferedRequest===null&&!S.finished&&!S.writing}function w(S,A){S._final(function(O){A.pendingcb--,O&&F(S,O),A.prefinished=!0,S.emit("prefinish"),_(S,A)})}function _(S,A){var O=y(A);if(O&&(function(U,H){H.prefinished||H.finalCalled||(typeof U._final!="function"||H.destroyed?(H.prefinished=!0,U.emit("prefinish")):(H.pendingcb++,H.finalCalled=!0,c.nextTick(w,U,H)))}(S,A),A.pendingcb===0&&(A.finished=!0,S.emit("finish"),A.autoDestroy))){var N=S._readableState;(!N||N.autoDestroy&&N.endEmitted)&&S.destroy()}return O}e("inherits")(z,o),V.prototype.getBuffer=function(){for(var S=this.bufferedRequest,A=[];S;)A.push(S),S=S.next;return A},function(){try{Object.defineProperty(V.prototype,"buffer",{get:n.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}(),typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(d=Function.prototype[Symbol.hasInstance],Object.defineProperty(z,Symbol.hasInstance,{value:function(S){return!!d.call(this,S)||this===z&&S&&S._writableState instanceof V}})):d=function(S){return S instanceof this},z.prototype.pipe=function(){F(this,new C)},z.prototype.write=function(S,A,O){var N,U=this._writableState,H=!1,Z=!U.objectMode&&(N=S,h.isBuffer(N)||N instanceof u);return Z&&!h.isBuffer(S)&&(S=function(D){return h.from(D)}(S)),typeof A=="function"&&(O=A,A=null),Z?A="buffer":A||(A=U.defaultEncoding),typeof O!="function"&&(O=L),U.ending?function(D,q){var M=new B;F(D,M),c.nextTick(q,M)}(this,O):(Z||function(D,q,M,j){var $;return M===null?$=new R:typeof M=="string"||q.objectMode||($=new v("chunk",["string","Buffer"],M)),!$||(F(D,$),c.nextTick(j,$),!1)}(this,U,S,O))&&(U.pendingcb++,H=function(D,q,M,j,$,K){if(!M){var J=function(se,Y,te){return se.objectMode||se.decodeStrings===!1||typeof Y!="string"||(Y=h.from(Y,te)),Y}(q,j,$);j!==J&&(M=!0,$="buffer",j=J)}var X=q.objectMode?1:j.length;q.length+=X;var Q=q.length<q.highWaterMark;if(Q||(q.needDrain=!0),q.writing||q.corked){var ee=q.lastBufferedRequest;q.lastBufferedRequest={chunk:j,encoding:$,isBuf:M,callback:K,next:null},ee?ee.next=q.lastBufferedRequest:q.bufferedRequest=q.lastBufferedRequest,q.bufferedRequestCount+=1}else E(D,q,!1,X,j,$,K);return Q}(this,U,Z,S,A,O)),H},z.prototype.cork=function(){this._writableState.corked++},z.prototype.uncork=function(){var S=this._writableState;S.corked&&(S.corked--,S.writing||S.corked||S.bufferProcessing||!S.bufferedRequest||k(this,S))},z.prototype.setDefaultEncoding=function(S){if(typeof S=="string"&&(S=S.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((S+"").toLowerCase())>-1))throw new I(S);return this._writableState.defaultEncoding=S,this},Object.defineProperty(z.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(z.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),z.prototype._write=function(S,A,O){O(new g("_write()"))},z.prototype._writev=null,z.prototype.end=function(S,A,O){var N=this._writableState;return typeof S=="function"?(O=S,S=null,A=null):typeof A=="function"&&(O=A,A=null),S!=null&&this.write(S,A),N.corked&&(N.corked=1,this.uncork()),N.ending||function(U,H,Z){H.ending=!0,_(U,H),Z&&(H.finished?c.nextTick(Z):U.once("finish",Z)),H.ended=!0,U.writable=!1}(this,N,O),this},Object.defineProperty(z.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(z.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState!==void 0&&this._writableState.destroyed},set:function(S){this._writableState&&(this._writableState.destroyed=S)}}),z.prototype.destroy=m.destroy,z.prototype._undestroy=m.undestroy,z.prototype._destroy=function(S,A){A(S)}}).call(this)}).call(this,e("_process"),typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{"../errors":477,"./_stream_duplex":478,"./internal/streams/destroy":485,"./internal/streams/state":489,"./internal/streams/stream":490,_process:467,buffer:220,inherits:440,"util-deprecate":524}],483:[function(e,a,f){(function(c){(function(){var s;function l(T,R,B){return(R=function(I){var F=function(L,V){if(typeof L!="object"||L===null)return L;var z=L[Symbol.toPrimitive];if(z!==void 0){var E=z.call(L,V);if(typeof E!="object")return E;throw new TypeError("@@toPrimitive must return a primitive value.")}return(V==="string"?String:Number)(L)}(I,"string");return typeof F=="symbol"?F:String(F)}(R))in T?Object.defineProperty(T,R,{value:B,enumerable:!0,configurable:!0,writable:!0}):T[R]=B,T}var i=e("./end-of-stream"),n=Symbol("lastResolve"),o=Symbol("lastReject"),h=Symbol("error"),u=Symbol("ended"),d=Symbol("lastPromise"),m=Symbol("handlePromise"),b=Symbol("stream");function p(T,R){return{value:T,done:R}}function v(T){var R=T[n];if(R!==null){var B=T[b].read();B!==null&&(T[d]=null,T[n]=null,T[o]=null,R(p(B,!1)))}}function g(T){c.nextTick(v,T)}var x=Object.getPrototypeOf(function(){}),C=Object.setPrototypeOf((l(s={get stream(){return this[b]},next:function(){var T=this,R=this[h];if(R!==null)return Promise.reject(R);if(this[u])return Promise.resolve(p(void 0,!0));if(this[b].destroyed)return new Promise(function(L,V){c.nextTick(function(){T[h]?V(T[h]):L(p(void 0,!0))})});var B,I=this[d];if(I)B=new Promise(function(L,V){return function(z,E){L.then(function(){V[u]?z(p(void 0,!0)):V[m](z,E)},E)}}(I,this));else{var F=this[b].read();if(F!==null)return Promise.resolve(p(F,!1));B=new Promise(this[m])}return this[d]=B,B}},Symbol.asyncIterator,function(){return this}),l(s,"return",function(){var T=this;return new Promise(function(R,B){T[b].destroy(null,function(I){I?B(I):R(p(void 0,!0))})})}),s),x);a.exports=function(T){var R,B=Object.create(C,(l(R={},b,{value:T,writable:!0}),l(R,n,{value:null,writable:!0}),l(R,o,{value:null,writable:!0}),l(R,h,{value:null,writable:!0}),l(R,u,{value:T._readableState.endEmitted,writable:!0}),l(R,m,{value:function(I,F){var L=B[b].read();L?(B[d]=null,B[n]=null,B[o]=null,I(p(L,!1))):(B[n]=I,B[o]=F)},writable:!0}),R));return B[d]=null,i(T,function(I){if(I&&I.code!=="ERR_STREAM_PREMATURE_CLOSE"){var F=B[o];return F!==null&&(B[d]=null,B[n]=null,B[o]=null,F(I)),void(B[h]=I)}var L=B[n];L!==null&&(B[d]=null,B[n]=null,B[o]=null,L(p(void 0,!0))),B[u]=!0}),T.on("readable",g.bind(null,B)),B}}).call(this)}).call(this,e("_process"))},{"./end-of-stream":486,_process:467}],484:[function(e,a,f){function c(d,m){var b=Object.keys(d);if(Object.getOwnPropertySymbols){var p=Object.getOwnPropertySymbols(d);m&&(p=p.filter(function(v){return Object.getOwnPropertyDescriptor(d,v).enumerable})),b.push.apply(b,p)}return b}function s(d){for(var m=1;m<arguments.length;m++){var b=arguments[m]!=null?arguments[m]:{};m%2?c(Object(b),!0).forEach(function(p){l(d,p,b[p])}):Object.getOwnPropertyDescriptors?Object.defineProperties(d,Object.getOwnPropertyDescriptors(b)):c(Object(b)).forEach(function(p){Object.defineProperty(d,p,Object.getOwnPropertyDescriptor(b,p))})}return d}function l(d,m,b){return(m=n(m))in d?Object.defineProperty(d,m,{value:b,enumerable:!0,configurable:!0,writable:!0}):d[m]=b,d}function i(d,m){for(var b=0;b<m.length;b++){var p=m[b];p.enumerable=p.enumerable||!1,p.configurable=!0,"value"in p&&(p.writable=!0),Object.defineProperty(d,n(p.key),p)}}function n(d){var m=function(b,p){if(typeof b!="object"||b===null)return b;var v=b[Symbol.toPrimitive];if(v!==void 0){var g=v.call(b,p);if(typeof g!="object")return g;throw new TypeError("@@toPrimitive must return a primitive value.")}return(p==="string"?String:Number)(b)}(d,"string");return typeof m=="symbol"?m:String(m)}var o=e("buffer").Buffer,h=e("util").inspect,u=h&&h.custom||"inspect";a.exports=function(){function d(){(function(p,v){if(!(p instanceof v))throw new TypeError("Cannot call a class as a function")})(this,d),this.head=null,this.tail=null,this.length=0}var m,b;return m=d,(b=[{key:"push",value:function(p){var v={data:p,next:null};this.length>0?this.tail.next=v:this.head=v,this.tail=v,++this.length}},{key:"unshift",value:function(p){var v={data:p,next:this.head};this.length===0&&(this.tail=v),this.head=v,++this.length}},{key:"shift",value:function(){if(this.length!==0){var p=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,p}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(p){if(this.length===0)return"";for(var v=this.head,g=""+v.data;v=v.next;)g+=p+v.data;return g}},{key:"concat",value:function(p){if(this.length===0)return o.alloc(0);for(var v,g,x,C=o.allocUnsafe(p>>>0),T=this.head,R=0;T;)v=T.data,g=C,x=R,o.prototype.copy.call(v,g,x),R+=T.data.length,T=T.next;return C}},{key:"consume",value:function(p,v){var g;return p<this.head.data.length?(g=this.head.data.slice(0,p),this.head.data=this.head.data.slice(p)):g=p===this.head.data.length?this.shift():v?this._getString(p):this._getBuffer(p),g}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(p){var v=this.head,g=1,x=v.data;for(p-=x.length;v=v.next;){var C=v.data,T=p>C.length?C.length:p;if(T===C.length?x+=C:x+=C.slice(0,p),(p-=T)==0){T===C.length?(++g,v.next?this.head=v.next:this.head=this.tail=null):(this.head=v,v.data=C.slice(T));break}++g}return this.length-=g,x}},{key:"_getBuffer",value:function(p){var v=o.allocUnsafe(p),g=this.head,x=1;for(g.data.copy(v),p-=g.data.length;g=g.next;){var C=g.data,T=p>C.length?C.length:p;if(C.copy(v,v.length-p,0,T),(p-=T)==0){T===C.length?(++x,g.next?this.head=g.next:this.head=this.tail=null):(this.head=g,g.data=C.slice(T));break}++x}return this.length-=x,v}},{key:u,value:function(p,v){return h(this,s(s({},v),{},{depth:0,customInspect:!1}))}}])&&i(m.prototype,b),Object.defineProperty(m,"prototype",{writable:!1}),d}()},{buffer:220,util:188}],485:[function(e,a,f){(function(c){(function(){function s(n,o){i(n,o),l(n)}function l(n){n._writableState&&!n._writableState.emitClose||n._readableState&&!n._readableState.emitClose||n.emit("close")}function i(n,o){n.emit("error",o)}a.exports={destroy:function(n,o){var h=this,u=this._readableState&&this._readableState.destroyed,d=this._writableState&&this._writableState.destroyed;return u||d?(o?o(n):n&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,c.nextTick(i,this,n)):c.nextTick(i,this,n)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(n||null,function(m){!o&&m?h._writableState?h._writableState.errorEmitted?c.nextTick(l,h):(h._writableState.errorEmitted=!0,c.nextTick(s,h,m)):c.nextTick(s,h,m):o?(c.nextTick(l,h),o(m)):c.nextTick(l,h)}),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)},errorOrDestroy:function(n,o){var h=n._readableState,u=n._writableState;h&&h.autoDestroy||u&&u.autoDestroy?n.destroy(o):n.emit("error",o)}}}).call(this)}).call(this,e("_process"))},{_process:467}],486:[function(e,a,f){var c=e("../../../errors").codes.ERR_STREAM_PREMATURE_CLOSE;function s(){}a.exports=function l(i,n,o){if(typeof n=="function")return l(i,null,n);n||(n={}),o=function(T){var R=!1;return function(){if(!R){R=!0;for(var B=arguments.length,I=new Array(B),F=0;F<B;F++)I[F]=arguments[F];T.apply(this,I)}}}(o||s);var h=n.readable||n.readable!==!1&&i.readable,u=n.writable||n.writable!==!1&&i.writable,d=function(){i.writable||b()},m=i._writableState&&i._writableState.finished,b=function(){u=!1,m=!0,h||o.call(i)},p=i._readableState&&i._readableState.endEmitted,v=function(){h=!1,p=!0,u||o.call(i)},g=function(T){o.call(i,T)},x=function(){var T;return h&&!p?(i._readableState&&i._readableState.ended||(T=new c),o.call(i,T)):u&&!m?(i._writableState&&i._writableState.ended||(T=new c),o.call(i,T)):void 0},C=function(){i.req.on("finish",b)};return function(T){return T.setHeader&&typeof T.abort=="function"}(i)?(i.on("complete",b),i.on("abort",x),i.req?C():i.on("request",C)):u&&!i._writableState&&(i.on("end",d),i.on("close",d)),i.on("end",v),i.on("finish",b),n.error!==!1&&i.on("error",g),i.on("close",x),function(){i.removeListener("complete",b),i.removeListener("abort",x),i.removeListener("request",C),i.req&&i.req.removeListener("finish",b),i.removeListener("end",d),i.removeListener("close",d),i.removeListener("finish",b),i.removeListener("end",v),i.removeListener("error",g),i.removeListener("close",x)}}},{"../../../errors":477}],487:[function(e,a,f){a.exports=function(){throw new Error("Readable.from is not available in the browser")}},{}],488:[function(e,a,f){var c,s=e("../../../errors").codes,l=s.ERR_MISSING_ARGS,i=s.ERR_STREAM_DESTROYED;function n(m){if(m)throw m}function o(m,b,p,v){v=function(C){var T=!1;return function(){T||(T=!0,C.apply(void 0,arguments))}}(v);var g=!1;m.on("close",function(){g=!0}),c===void 0&&(c=e("./end-of-stream")),c(m,{readable:b,writable:p},function(C){if(C)return v(C);g=!0,v()});var x=!1;return function(C){if(!g&&!x)return x=!0,function(T){return T.setHeader&&typeof T.abort=="function"}(m)?m.abort():typeof m.destroy=="function"?m.destroy():void v(C||new i("pipe"))}}function h(m){m()}function u(m,b){return m.pipe(b)}function d(m){return m.length?typeof m[m.length-1]!="function"?n:m.pop():n}a.exports=function(){for(var m=arguments.length,b=new Array(m),p=0;p<m;p++)b[p]=arguments[p];var v,g=d(b);if(Array.isArray(b[0])&&(b=b[0]),b.length<2)throw new l("streams");var x=b.map(function(C,T){var R=T<b.length-1;return o(C,R,T>0,function(B){v||(v=B),B&&x.forEach(h),R||(x.forEach(h),g(v))})});return b.reduce(u)}},{"../../../errors":477,"./end-of-stream":486}],489:[function(e,a,f){var c=e("../../../errors").codes.ERR_INVALID_OPT_VALUE;a.exports={getHighWaterMark:function(s,l,i,n){var o=function(h,u,d){return h.highWaterMark!=null?h.highWaterMark:u?h[d]:null}(l,n,i);if(o!=null){if(!isFinite(o)||Math.floor(o)!==o||o<0)throw new c(n?i:"highWaterMark",o);return Math.floor(o)}return s.objectMode?16:16384}}},{"../../../errors":477}],490:[function(e,a,f){a.exports=e("events").EventEmitter},{events:422}],491:[function(e,a,f){(f=a.exports=e("./lib/_stream_readable.js")).Stream=f,f.Readable=f,f.Writable=e("./lib/_stream_writable.js"),f.Duplex=e("./lib/_stream_duplex.js"),f.Transform=e("./lib/_stream_transform.js"),f.PassThrough=e("./lib/_stream_passthrough.js"),f.finished=e("./lib/internal/streams/end-of-stream.js"),f.pipeline=e("./lib/internal/streams/pipeline.js")},{"./lib/_stream_duplex.js":478,"./lib/_stream_passthrough.js":479,"./lib/_stream_readable.js":480,"./lib/_stream_transform.js":481,"./lib/_stream_writable.js":482,"./lib/internal/streams/end-of-stream.js":486,"./lib/internal/streams/pipeline.js":488}],492:[function(e,a,f){var c=function(s){var l=Object.prototype,i=l.hasOwnProperty,n=Object.defineProperty||function(_,S,A){_[S]=A.value},o=typeof Symbol=="function"?Symbol:{},h=o.iterator||"@@iterator",u=o.asyncIterator||"@@asyncIterator",d=o.toStringTag||"@@toStringTag";function m(_,S,A){return Object.defineProperty(_,S,{value:A,enumerable:!0,configurable:!0,writable:!0}),_[S]}try{m({},"")}catch{m=function(S,A,O){return S[A]=O}}function b(_,S,A,O){var N=S&&S.prototype instanceof g?S:g,U=Object.create(N.prototype),H=new k(O||[]);return n(U,"_invoke",{value:V(_,A,H)}),U}function p(_,S,A){try{return{type:"normal",arg:_.call(S,A)}}catch(O){return{type:"throw",arg:O}}}s.wrap=b;var v={};function g(){}function x(){}function C(){}var T={};m(T,h,function(){return this});var R=Object.getPrototypeOf,B=R&&R(R(y([])));B&&B!==l&&i.call(B,h)&&(T=B);var I=C.prototype=g.prototype=Object.create(T);function F(_){["next","throw","return"].forEach(function(S){m(_,S,function(A){return this._invoke(S,A)})})}function L(_,S){var A;n(this,"_invoke",{value:function(O,N){function U(){return new S(function(H,Z){(function D(q,M,j,$){var K=p(_[q],_,M);if(K.type!=="throw"){var J=K.arg,X=J.value;return X&&typeof X=="object"&&i.call(X,"__await")?S.resolve(X.__await).then(function(Q){D("next",Q,j,$)},function(Q){D("throw",Q,j,$)}):S.resolve(X).then(function(Q){J.value=Q,j(J)},function(Q){return D("throw",Q,j,$)})}$(K.arg)})(O,N,H,Z)})}return A=A?A.then(U,U):U()}})}function V(_,S,A){var O="suspendedStart";return function(N,U){if(O==="executing")throw new Error("Generator is already running");if(O==="completed"){if(N==="throw")throw U;return w()}for(A.method=N,A.arg=U;;){var H=A.delegate;if(H){var Z=z(H,A);if(Z){if(Z===v)continue;return Z}}if(A.method==="next")A.sent=A._sent=A.arg;else if(A.method==="throw"){if(O==="suspendedStart")throw O="completed",A.arg;A.dispatchException(A.arg)}else A.method==="return"&&A.abrupt("return",A.arg);O="executing";var D=p(_,S,A);if(D.type==="normal"){if(O=A.done?"completed":"suspendedYield",D.arg===v)continue;return{value:D.arg,done:A.done}}D.type==="throw"&&(O="completed",A.method="throw",A.arg=D.arg)}}}function z(_,S){var A=S.method,O=_.iterator[A];if(O===void 0)return S.delegate=null,A==="throw"&&_.iterator.return&&(S.method="return",S.arg=void 0,z(_,S),S.method==="throw")||A!=="return"&&(S.method="throw",S.arg=new TypeError("The iterator does not provide a '"+A+"' method")),v;var N=p(O,_.iterator,S.arg);if(N.type==="throw")return S.method="throw",S.arg=N.arg,S.delegate=null,v;var U=N.arg;return U?U.done?(S[_.resultName]=U.value,S.next=_.nextLoc,S.method!=="return"&&(S.method="next",S.arg=void 0),S.delegate=null,v):U:(S.method="throw",S.arg=new TypeError("iterator result is not an object"),S.delegate=null,v)}function E(_){var S={tryLoc:_[0]};1 in _&&(S.catchLoc=_[1]),2 in _&&(S.finallyLoc=_[2],S.afterLoc=_[3]),this.tryEntries.push(S)}function P(_){var S=_.completion||{};S.type="normal",delete S.arg,_.completion=S}function k(_){this.tryEntries=[{tryLoc:"root"}],_.forEach(E,this),this.reset(!0)}function y(_){if(_){var S=_[h];if(S)return S.call(_);if(typeof _.next=="function")return _;if(!isNaN(_.length)){var A=-1,O=function N(){for(;++A<_.length;)if(i.call(_,A))return N.value=_[A],N.done=!1,N;return N.value=void 0,N.done=!0,N};return O.next=O}}return{next:w}}function w(){return{value:void 0,done:!0}}return x.prototype=C,n(I,"constructor",{value:C,configurable:!0}),n(C,"constructor",{value:x,configurable:!0}),x.displayName=m(C,d,"GeneratorFunction"),s.isGeneratorFunction=function(_){var S=typeof _=="function"&&_.constructor;return!!S&&(S===x||(S.displayName||S.name)==="GeneratorFunction")},s.mark=function(_){return Object.setPrototypeOf?Object.setPrototypeOf(_,C):(_.__proto__=C,m(_,d,"GeneratorFunction")),_.prototype=Object.create(I),_},s.awrap=function(_){return{__await:_}},F(L.prototype),m(L.prototype,u,function(){return this}),s.AsyncIterator=L,s.async=function(_,S,A,O,N){N===void 0&&(N=Promise);var U=new L(b(_,S,A,O),N);return s.isGeneratorFunction(S)?U:U.next().then(function(H){return H.done?H.value:U.next()})},F(I),m(I,d,"Generator"),m(I,h,function(){return this}),m(I,"toString",function(){return"[object Generator]"}),s.keys=function(_){var S=Object(_),A=[];for(var O in S)A.push(O);return A.reverse(),function N(){for(;A.length;){var U=A.pop();if(U in S)return N.value=U,N.done=!1,N}return N.done=!0,N}},s.values=y,k.prototype={constructor:k,reset:function(_){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(P),!_)for(var S in this)S.charAt(0)==="t"&&i.call(this,S)&&!isNaN(+S.slice(1))&&(this[S]=void 0)},stop:function(){this.done=!0;var _=this.tryEntries[0].completion;if(_.type==="throw")throw _.arg;return this.rval},dispatchException:function(_){if(this.done)throw _;var S=this;function A(D,q){return U.type="throw",U.arg=_,S.next=D,q&&(S.method="next",S.arg=void 0),!!q}for(var O=this.tryEntries.length-1;O>=0;--O){var N=this.tryEntries[O],U=N.completion;if(N.tryLoc==="root")return A("end");if(N.tryLoc<=this.prev){var H=i.call(N,"catchLoc"),Z=i.call(N,"finallyLoc");if(H&&Z){if(this.prev<N.catchLoc)return A(N.catchLoc,!0);if(this.prev<N.finallyLoc)return A(N.finallyLoc)}else if(H){if(this.prev<N.catchLoc)return A(N.catchLoc,!0)}else{if(!Z)throw new Error("try statement without catch or finally");if(this.prev<N.finallyLoc)return A(N.finallyLoc)}}}},abrupt:function(_,S){for(var A=this.tryEntries.length-1;A>=0;--A){var O=this.tryEntries[A];if(O.tryLoc<=this.prev&&i.call(O,"finallyLoc")&&this.prev<O.finallyLoc){var N=O;break}}N&&(_==="break"||_==="continue")&&N.tryLoc<=S&&S<=N.finallyLoc&&(N=null);var U=N?N.completion:{};return U.type=_,U.arg=S,N?(this.method="next",this.next=N.finallyLoc,v):this.complete(U)},complete:function(_,S){if(_.type==="throw")throw _.arg;return _.type==="break"||_.type==="continue"?this.next=_.arg:_.type==="return"?(this.rval=this.arg=_.arg,this.method="return",this.next="end"):_.type==="normal"&&S&&(this.next=S),v},finish:function(_){for(var S=this.tryEntries.length-1;S>=0;--S){var A=this.tryEntries[S];if(A.finallyLoc===_)return this.complete(A.completion,A.afterLoc),P(A),v}},catch:function(_){for(var S=this.tryEntries.length-1;S>=0;--S){var A=this.tryEntries[S];if(A.tryLoc===_){var O=A.completion;if(O.type==="throw"){var N=O.arg;P(A)}return N}}throw new Error("illegal catch attempt")},delegateYield:function(_,S,A){return this.delegate={iterator:y(_),resultName:S,nextLoc:A},this.method==="next"&&(this.arg=void 0),v}},s}(typeof a=="object"?a.exports:{});try{regeneratorRuntime=c}catch{typeof globalThis=="object"?globalThis.regeneratorRuntime=c:Function("r","regeneratorRuntime = r")(c)}},{}],493:[function(e,a,f){var c=e("buffer").Buffer,s=e("inherits"),l=e("hash-base"),i=new Array(16),n=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],o=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],h=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],u=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11],d=[0,1518500249,1859775393,2400959708,2840853838],m=[1352829926,1548603684,1836072691,2053994217,0];function b(){l.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function p(R,B){return R<<B|R>>>32-B}function v(R,B,I,F,L,V,z,E){return p(R+(B^I^F)+V+z|0,E)+L|0}function g(R,B,I,F,L,V,z,E){return p(R+(B&I|~B&F)+V+z|0,E)+L|0}function x(R,B,I,F,L,V,z,E){return p(R+((B|~I)^F)+V+z|0,E)+L|0}function C(R,B,I,F,L,V,z,E){return p(R+(B&F|I&~F)+V+z|0,E)+L|0}function T(R,B,I,F,L,V,z,E){return p(R+(B^(I|~F))+V+z|0,E)+L|0}s(b,l),b.prototype._update=function(){for(var R=i,B=0;B<16;++B)R[B]=this._block.readInt32LE(4*B);for(var I=0|this._a,F=0|this._b,L=0|this._c,V=0|this._d,z=0|this._e,E=0|this._a,P=0|this._b,k=0|this._c,y=0|this._d,w=0|this._e,_=0;_<80;_+=1){var S,A;_<16?(S=v(I,F,L,V,z,R[n[_]],d[0],h[_]),A=T(E,P,k,y,w,R[o[_]],m[0],u[_])):_<32?(S=g(I,F,L,V,z,R[n[_]],d[1],h[_]),A=C(E,P,k,y,w,R[o[_]],m[1],u[_])):_<48?(S=x(I,F,L,V,z,R[n[_]],d[2],h[_]),A=x(E,P,k,y,w,R[o[_]],m[2],u[_])):_<64?(S=C(I,F,L,V,z,R[n[_]],d[3],h[_]),A=g(E,P,k,y,w,R[o[_]],m[3],u[_])):(S=T(I,F,L,V,z,R[n[_]],d[4],h[_]),A=v(E,P,k,y,w,R[o[_]],m[4],u[_])),I=z,z=V,V=p(L,10),L=F,F=S,E=w,w=y,y=p(k,10),k=P,P=A}var O=this._b+L+y|0;this._b=this._c+V+w|0,this._c=this._d+z+E|0,this._d=this._e+I+P|0,this._e=this._a+F+k|0,this._a=O},b.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var R=c.alloc?c.alloc(20):new c(20);return R.writeInt32LE(this._a,0),R.writeInt32LE(this._b,4),R.writeInt32LE(this._c,8),R.writeInt32LE(this._d,12),R.writeInt32LE(this._e,16),R},a.exports=b},{buffer:220,"hash-base":425,inherits:440}],494:[function(e,a,f){/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */var c=e("buffer"),s=c.Buffer;function l(n,o){for(var h in n)o[h]=n[h]}function i(n,o,h){return s(n,o,h)}s.from&&s.alloc&&s.allocUnsafe&&s.allocUnsafeSlow?a.exports=c:(l(c,f),f.Buffer=i),i.prototype=Object.create(s.prototype),l(s,i),i.from=function(n,o,h){if(typeof n=="number")throw new TypeError("Argument must not be a number");return s(n,o,h)},i.alloc=function(n,o,h){if(typeof n!="number")throw new TypeError("Argument must be a number");var u=s(n);return o!==void 0?typeof h=="string"?u.fill(o,h):u.fill(o):u.fill(0),u},i.allocUnsafe=function(n){if(typeof n!="number")throw new TypeError("Argument must be a number");return s(n)},i.allocUnsafeSlow=function(n){if(typeof n!="number")throw new TypeError("Argument must be a number");return c.SlowBuffer(n)}},{buffer:220}],495:[function(e,a,f){(function(c){(function(){var s,l=e("buffer"),i=l.Buffer,n={};for(s in l)l.hasOwnProperty(s)&&s!=="SlowBuffer"&&s!=="Buffer"&&(n[s]=l[s]);var o=n.Buffer={};for(s in i)i.hasOwnProperty(s)&&s!=="allocUnsafe"&&s!=="allocUnsafeSlow"&&(o[s]=i[s]);if(n.Buffer.prototype=i.prototype,o.from&&o.from!==Uint8Array.from||(o.from=function(h,u,d){if(typeof h=="number")throw new TypeError('The "value" argument must not be of type number. Received type '+typeof h);if(h&&h.length===void 0)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof h);return i(h,u,d)}),o.alloc||(o.alloc=function(h,u,d){if(typeof h!="number")throw new TypeError('The "size" argument must be of type number. Received type '+typeof h);if(h<0||h>=2*(1<<30))throw new RangeError('The value "'+h+'" is invalid for option "size"');var m=i(h);return u&&u.length!==0?typeof d=="string"?m.fill(u,d):m.fill(u):m.fill(0),m}),!n.kStringMaxLength)try{n.kStringMaxLength=c.binding("buffer").kStringMaxLength}catch{}n.constants||(n.constants={MAX_LENGTH:n.kMaxLength},n.kStringMaxLength&&(n.constants.MAX_STRING_LENGTH=n.kStringMaxLength)),a.exports=n}).call(this)}).call(this,e("_process"))},{_process:467,buffer:220}],496:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0});const c=e("xmlchars/xml/1.0/ed5"),s=e("xmlchars/xml/1.1/ed2"),l=e("xmlchars/xmlns/1.0/ed3");var i=c.isS,n=c.isChar,o=c.isNameStartChar,h=c.isNameChar,u=c.S_LIST,d=c.NAME_RE,m=s.isChar,b=l.isNCNameStartChar,p=l.isNCNameChar,v=l.NC_NAME_RE;const g="http://www.w3.org/XML/1998/namespace",x="http://www.w3.org/2000/xmlns/",C={__proto__:null,xml:g,xmlns:x},T={__proto__:null,amp:"&",gt:">",lt:"<",quot:'"',apos:"'"},R=y=>y===34||y===39,B=[34,39],I=[...B,91,62],F=[...B,60,93],L=[61,63,...u],V=[...u,62,38,60];function z(y,w,_){switch(w){case"xml":_!==g&&y.fail(`xml prefix must be bound to ${g}.`);break;case"xmlns":_!==x&&y.fail(`xmlns prefix must be bound to ${x}.`)}switch(_){case x:y.fail(w===""?`the default namespace may not be set to ${_}.`:`may not assign a prefix (even "xmlns") to the URI ${x}.`);break;case g:switch(w){case"xml":break;case"":y.fail(`the default namespace may not be set to ${_}.`);break;default:y.fail("may not assign the xml namespace to another prefix.")}}}const E=y=>v.test(y),P=y=>d.test(y);f.EVENTS=["xmldecl","text","processinginstruction","doctype","comment","opentagstart","attribute","opentag","closetag","cdata","error","end","ready"];const k={xmldecl:"xmldeclHandler",text:"textHandler",processinginstruction:"piHandler",doctype:"doctypeHandler",comment:"commentHandler",opentagstart:"openTagStartHandler",attribute:"attributeHandler",opentag:"openTagHandler",closetag:"closeTagHandler",cdata:"cdataHandler",error:"errorHandler",end:"endHandler",ready:"readyHandler"};f.SaxesParser=class{constructor(y){this.opt=y??{},this.fragmentOpt=!!this.opt.fragment;const w=this.xmlnsOpt=!!this.opt.xmlns;if(this.trackPosition=this.opt.position!==!1,this.fileName=this.opt.fileName,w){this.nameStartCheck=b,this.nameCheck=p,this.isName=E,this.processAttribs=this.processAttribsNS,this.pushAttrib=this.pushAttribNS,this.ns=Object.assign({__proto__:null},C);const _=this.opt.additionalNamespaces;_!=null&&(function(S,A){for(const O of Object.keys(A))z(S,O,A[O])}(this,_),Object.assign(this.ns,_))}else this.nameStartCheck=o,this.nameCheck=h,this.isName=P,this.processAttribs=this.processAttribsPlain,this.pushAttrib=this.pushAttribPlain;this.stateTable=[this.sBegin,this.sBeginWhitespace,this.sDoctype,this.sDoctypeQuote,this.sDTD,this.sDTDQuoted,this.sDTDOpenWaka,this.sDTDOpenWakaBang,this.sDTDComment,this.sDTDCommentEnding,this.sDTDCommentEnded,this.sDTDPI,this.sDTDPIEnding,this.sText,this.sEntity,this.sOpenWaka,this.sOpenWakaBang,this.sComment,this.sCommentEnding,this.sCommentEnded,this.sCData,this.sCDataEnding,this.sCDataEnding2,this.sPIFirstChar,this.sPIRest,this.sPIBody,this.sPIEnding,this.sXMLDeclNameStart,this.sXMLDeclName,this.sXMLDeclEq,this.sXMLDeclValueStart,this.sXMLDeclValue,this.sXMLDeclSeparator,this.sXMLDeclEnding,this.sOpenTag,this.sOpenTagSlash,this.sAttrib,this.sAttribName,this.sAttribNameSawWhite,this.sAttribValue,this.sAttribValueQuoted,this.sAttribValueClosed,this.sAttribValueUnquoted,this.sCloseTag,this.sCloseTagSawWhite],this._init()}get closed(){return this._closed}_init(){var y;this.openWakaBang="",this.text="",this.name="",this.piTarget="",this.entity="",this.q=null,this.tags=[],this.tag=null,this.topNS=null,this.chunk="",this.chunkPosition=0,this.i=0,this.prevI=0,this.carriedFromPrevious=void 0,this.forbiddenState=0,this.attribList=[];const{fragmentOpt:w}=this;this.state=w?13:0,this.reportedTextBeforeRoot=this.reportedTextAfterRoot=this.closedRoot=this.sawRoot=w,this.xmlDeclPossible=!w,this.xmlDeclExpects=["version"],this.entityReturnState=void 0;let{defaultXMLVersion:_}=this.opt;if(_===void 0){if(this.opt.forceXMLVersion===!0)throw new Error("forceXMLVersion set but defaultXMLVersion is not set");_="1.0"}this.setXMLVersion(_),this.positionAtNewLine=0,this.doctype=!1,this._closed=!1,this.xmlDecl={version:void 0,encoding:void 0,standalone:void 0},this.line=1,this.column=0,this.ENTITIES=Object.create(T),(y=this.readyHandler)===null||y===void 0||y.call(this)}get position(){return this.chunkPosition+this.i}get columnIndex(){return this.position-this.positionAtNewLine}on(y,w){this[k[y]]=w}off(y){this[k[y]]=void 0}makeError(y){var w;let _=(w=this.fileName)!==null&&w!==void 0?w:"";return this.trackPosition&&(_.length>0&&(_+=":"),_+=`${this.line}:${this.column}`),_.length>0&&(_+=": "),new Error(_+y)}fail(y){const w=this.makeError(y),_=this.errorHandler;if(_===void 0)throw w;return _(w),this}write(y){if(this.closed)return this.fail("cannot write after close; assign an onready handler.");let w=!1;y===null?(w=!0,y=""):typeof y=="object"&&(y=y.toString()),this.carriedFromPrevious!==void 0&&(y=`${this.carriedFromPrevious}${y}`,this.carriedFromPrevious=void 0);let _=y.length;const S=y.charCodeAt(_-1);!w&&(S===13||S>=55296&&S<=56319)&&(this.carriedFromPrevious=y[_-1],_--,y=y.slice(0,_));const{stateTable:A}=this;for(this.chunk=y,this.i=0;this.i<_;)A[this.state].call(this);return this.chunkPosition+=_,w?this.end():this}close(){return this.write(null)}getCode10(){const{chunk:y,i:w}=this;if(this.prevI=w,this.i=w+1,w>=y.length)return-1;const _=y.charCodeAt(w);if(this.column++,_<55296){if(_>=32||_===9)return _;switch(_){case 10:return this.line++,this.column=0,this.positionAtNewLine=this.position,10;case 13:return y.charCodeAt(w+1)===10&&(this.i=w+2),this.line++,this.column=0,this.positionAtNewLine=this.position,-2;default:return this.fail("disallowed character."),_}}if(_>56319)return _>=57344&&_<=65533||this.fail("disallowed character."),_;const S=65536+1024*(_-55296)+(y.charCodeAt(w+1)-56320);return this.i=w+2,S>1114111&&this.fail("disallowed character."),S}getCode11(){const{chunk:y,i:w}=this;if(this.prevI=w,this.i=w+1,w>=y.length)return-1;const _=y.charCodeAt(w);if(this.column++,_<55296){if(_>31&&_<127||_>159&&_!==8232||_===9)return _;switch(_){case 10:return this.line++,this.column=0,this.positionAtNewLine=this.position,10;case 13:{const A=y.charCodeAt(w+1);A!==10&&A!==133||(this.i=w+2)}case 133:case 8232:return this.line++,this.column=0,this.positionAtNewLine=this.position,-2;default:return this.fail("disallowed character."),_}}if(_>56319)return _>=57344&&_<=65533||this.fail("disallowed character."),_;const S=65536+1024*(_-55296)+(y.charCodeAt(w+1)-56320);return this.i=w+2,S>1114111&&this.fail("disallowed character."),S}getCodeNorm(){const y=this.getCode();return y===-2?10:y}unget(){this.i=this.prevI,this.column--}captureTo(y){let{i:w}=this;const{chunk:_}=this;for(;;){const S=this.getCode(),A=S===-2,O=A?10:S;if(O===-1||y.includes(O))return this.text+=_.slice(w,this.prevI),O;A&&(this.text+=_.slice(w,this.prevI)+` `,w=this.i)}}captureToChar(y){let{i:w}=this;const{chunk:_}=this;for(;;){let S=this.getCode();switch(S){case-2:this.text+=_.slice(w,this.prevI)+` `,w=this.i,S=10;break;case-1:return this.text+=_.slice(w),!1}if(S===y)return this.text+=_.slice(w,this.prevI),!0}}captureNameChars(){const{chunk:y,i:w}=this;for(;;){const _=this.getCode();if(_===-1)return this.name+=y.slice(w),-1;if(!h(_))return this.name+=y.slice(w,this.prevI),_===-2?10:_}}skipSpaces(){for(;;){const y=this.getCodeNorm();if(y===-1||!i(y))return y}}setXMLVersion(y){this.currentXMLVersion=y,y==="1.0"?(this.isChar=n,this.getCode=this.getCode10):(this.isChar=m,this.getCode=this.getCode11)}sBegin(){this.chunk.charCodeAt(0)===65279&&(this.i++,this.column++),this.state=1}sBeginWhitespace(){const y=this.i,w=this.skipSpaces();switch(this.prevI!==y&&(this.xmlDeclPossible=!1),w){case 60:if(this.state=15,this.text.length!==0)throw new Error("no-empty text at start");break;case-1:break;default:this.unget(),this.state=13,this.xmlDeclPossible=!1}}sDoctype(){var y;const w=this.captureTo(I);switch(w){case 62:(y=this.doctypeHandler)===null||y===void 0||y.call(this,this.text),this.text="",this.state=13,this.doctype=!0;break;case-1:break;default:this.text+=String.fromCodePoint(w),w===91?this.state=4:R(w)&&(this.state=3,this.q=w)}}sDoctypeQuote(){const y=this.q;this.captureToChar(y)&&(this.text+=String.fromCodePoint(y),this.q=null,this.state=2)}sDTD(){const y=this.captureTo(F);y!==-1&&(this.text+=String.fromCodePoint(y),y===93?this.state=2:y===60?this.state=6:R(y)&&(this.state=5,this.q=y))}sDTDQuoted(){const y=this.q;this.captureToChar(y)&&(this.text+=String.fromCodePoint(y),this.state=4,this.q=null)}sDTDOpenWaka(){const y=this.getCodeNorm();switch(this.text+=String.fromCodePoint(y),y){case 33:this.state=7,this.openWakaBang="";break;case 63:this.state=11;break;default:this.state=4}}sDTDOpenWakaBang(){const y=String.fromCodePoint(this.getCodeNorm()),w=this.openWakaBang+=y;this.text+=y,w!=="-"&&(this.state=w==="--"?8:4,this.openWakaBang="")}sDTDComment(){this.captureToChar(45)&&(this.text+="-",this.state=9)}sDTDCommentEnding(){const y=this.getCodeNorm();this.text+=String.fromCodePoint(y),this.state=y===45?10:8}sDTDCommentEnded(){const y=this.getCodeNorm();this.text+=String.fromCodePoint(y),y===62?this.state=4:(this.fail("malformed comment."),this.state=8)}sDTDPI(){this.captureToChar(63)&&(this.text+="?",this.state=12)}sDTDPIEnding(){const y=this.getCodeNorm();this.text+=String.fromCodePoint(y),y===62&&(this.state=4)}sText(){this.tags.length!==0?this.handleTextInRoot():this.handleTextOutsideRoot()}sEntity(){let{i:y}=this;const{chunk:w}=this;e:for(;;)switch(this.getCode()){case-2:this.entity+=w.slice(y,this.prevI)+` `,y=this.i;break;case 59:{const{entityReturnState:_}=this,S=this.entity+w.slice(y,this.prevI);let A;this.state=_,S===""?(this.fail("empty entity name."),A="&;"):(A=this.parseEntity(S),this.entity=""),_===13&&this.textHandler===void 0||(this.text+=A);break e}case-1:this.entity+=w.slice(y);break e}}sOpenWaka(){const y=this.getCode();if(o(y))this.state=34,this.unget(),this.xmlDeclPossible=!1;else switch(y){case 47:this.state=43,this.xmlDeclPossible=!1;break;case 33:this.state=16,this.openWakaBang="",this.xmlDeclPossible=!1;break;case 63:this.state=23;break;default:this.fail("disallowed character in tag name"),this.state=13,this.xmlDeclPossible=!1}}sOpenWakaBang(){switch(this.openWakaBang+=String.fromCodePoint(this.getCodeNorm()),this.openWakaBang){case"[CDATA[":this.sawRoot||this.reportedTextBeforeRoot||(this.fail("text data outside of root node."),this.reportedTextBeforeRoot=!0),this.closedRoot&&!this.reportedTextAfterRoot&&(this.fail("text data outside of root node."),this.reportedTextAfterRoot=!0),this.state=20,this.openWakaBang="";break;case"--":this.state=17,this.openWakaBang="";break;case"DOCTYPE":this.state=2,(this.doctype||this.sawRoot)&&this.fail("inappropriately located doctype declaration."),this.openWakaBang="";break;default:this.openWakaBang.length>=7&&this.fail("incorrect syntax.")}}sComment(){this.captureToChar(45)&&(this.state=18)}sCommentEnding(){var y;const w=this.getCodeNorm();w===45?(this.state=19,(y=this.commentHandler)===null||y===void 0||y.call(this,this.text),this.text=""):(this.text+="-"+String.fromCodePoint(w),this.state=17)}sCommentEnded(){const y=this.getCodeNorm();y!==62?(this.fail("malformed comment."),this.text+="--"+String.fromCodePoint(y),this.state=17):this.state=13}sCData(){this.captureToChar(93)&&(this.state=21)}sCDataEnding(){const y=this.getCodeNorm();y===93?this.state=22:(this.text+="]"+String.fromCodePoint(y),this.state=20)}sCDataEnding2(){var y;const w=this.getCodeNorm();switch(w){case 62:(y=this.cdataHandler)===null||y===void 0||y.call(this,this.text),this.text="",this.state=13;break;case 93:this.text+="]";break;default:this.text+="]]"+String.fromCodePoint(w),this.state=20}}sPIFirstChar(){const y=this.getCodeNorm();this.nameStartCheck(y)?(this.piTarget+=String.fromCodePoint(y),this.state=24):y===63||i(y)?(this.fail("processing instruction without a target."),this.state=y===63?26:25):(this.fail("disallowed character in processing instruction name."),this.piTarget+=String.fromCodePoint(y),this.state=24)}sPIRest(){const{chunk:y,i:w}=this;for(;;){const _=this.getCodeNorm();if(_===-1)return void(this.piTarget+=y.slice(w));if(!this.nameCheck(_)){this.piTarget+=y.slice(w,this.prevI);const S=_===63;S||i(_)?this.piTarget==="xml"?(this.xmlDeclPossible||this.fail("an XML declaration must be at the start of the document."),this.state=S?33:27):this.state=S?26:25:(this.fail("disallowed character in processing instruction name."),this.piTarget+=String.fromCodePoint(_));break}}}sPIBody(){if(this.text.length===0){const y=this.getCodeNorm();y===63?this.state=26:i(y)||(this.text=String.fromCodePoint(y))}else this.captureToChar(63)&&(this.state=26)}sPIEnding(){var y;const w=this.getCodeNorm();if(w===62){const{piTarget:_}=this;_.toLowerCase()==="xml"&&this.fail("the XML declaration must appear at the start of the document."),(y=this.piHandler)===null||y===void 0||y.call(this,{target:_,body:this.text}),this.piTarget=this.text="",this.state=13}else w===63?this.text+="?":(this.text+="?"+String.fromCodePoint(w),this.state=25);this.xmlDeclPossible=!1}sXMLDeclNameStart(){const y=this.skipSpaces();y!==63?y!==-1&&(this.state=28,this.name=String.fromCodePoint(y)):this.state=33}sXMLDeclName(){const y=this.captureTo(L);if(y===63)return this.state=33,this.name+=this.text,this.text="",void this.fail("XML declaration is incomplete.");if(i(y)||y===61){if(this.name+=this.text,this.text="",!this.xmlDeclExpects.includes(this.name))switch(this.name.length){case 0:this.fail("did not expect any more name/value pairs.");break;case 1:this.fail(`expected the name ${this.xmlDeclExpects[0]}.`);break;default:this.fail("expected one of "+this.xmlDeclExpects.join(", "))}this.state=y===61?30:29}}sXMLDeclEq(){const y=this.getCodeNorm();if(y===63)return this.state=33,void this.fail("XML declaration is incomplete.");i(y)||(y!==61&&this.fail("value required."),this.state=30)}sXMLDeclValueStart(){const y=this.getCodeNorm();if(y===63)return this.state=33,void this.fail("XML declaration is incomplete.");i(y)||(R(y)?this.q=y:(this.fail("value must be quoted."),this.q=32),this.state=31)}sXMLDeclValue(){const y=this.captureTo([this.q,63]);if(y===63)return this.state=33,this.text="",void this.fail("XML declaration is incomplete.");if(y===-1)return;const w=this.text;switch(this.text="",this.name){case"version":{this.xmlDeclExpects=["encoding","standalone"];const _=w;this.xmlDecl.version=_,/^1\.[0-9]+$/.test(_)?this.opt.forceXMLVersion||this.setXMLVersion(_):this.fail("version number must match /^1\\.[0-9]+$/.");break}case"encoding":/^[A-Za-z][A-Za-z0-9._-]*$/.test(w)||this.fail("encoding value must match /^[A-Za-z0-9][A-Za-z0-9._-]*$/."),this.xmlDeclExpects=["standalone"],this.xmlDecl.encoding=w;break;case"standalone":w!=="yes"&&w!=="no"&&this.fail('standalone value must match "yes" or "no".'),this.xmlDeclExpects=[],this.xmlDecl.standalone=w}this.name="",this.state=32}sXMLDeclSeparator(){const y=this.getCodeNorm();y!==63?(i(y)||(this.fail("whitespace required."),this.unget()),this.state=27):this.state=33}sXMLDeclEnding(){var y;this.getCodeNorm()===62?(this.piTarget!=="xml"?this.fail("processing instructions are not allowed before root."):this.name!=="version"&&this.xmlDeclExpects.includes("version")&&this.fail("XML declaration must contain a version."),(y=this.xmldeclHandler)===null||y===void 0||y.call(this,this.xmlDecl),this.name="",this.piTarget=this.text="",this.state=13):this.fail("The character ? is disallowed anywhere in XML declarations."),this.xmlDeclPossible=!1}sOpenTag(){var y;const w=this.captureNameChars();if(w===-1)return;const _=this.tag={name:this.name,attributes:Object.create(null)};switch(this.name="",this.xmlnsOpt&&(this.topNS=_.ns=Object.create(null)),(y=this.openTagStartHandler)===null||y===void 0||y.call(this,_),this.sawRoot=!0,!this.fragmentOpt&&this.closedRoot&&this.fail("documents may contain only one root."),w){case 62:this.openTag();break;case 47:this.state=35;break;default:i(w)||this.fail("disallowed character in tag name."),this.state=36}}sOpenTagSlash(){this.getCode()===62?this.openSelfClosingTag():(this.fail("forward-slash in opening tag not followed by >."),this.state=36)}sAttrib(){const y=this.skipSpaces();y!==-1&&(o(y)?(this.unget(),this.state=37):y===62?this.openTag():y===47?this.state=35:this.fail("disallowed character in attribute name."))}sAttribName(){const y=this.captureNameChars();y===61?this.state=39:i(y)?this.state=38:y===62?(this.fail("attribute without value."),this.pushAttrib(this.name,this.name),this.name=this.text="",this.openTag()):y!==-1&&this.fail("disallowed character in attribute name.")}sAttribNameSawWhite(){const y=this.skipSpaces();switch(y){case-1:return;case 61:this.state=39;break;default:this.fail("attribute without value."),this.text="",this.name="",y===62?this.openTag():o(y)?(this.unget(),this.state=37):(this.fail("disallowed character in attribute name."),this.state=36)}}sAttribValue(){const y=this.getCodeNorm();R(y)?(this.q=y,this.state=40):i(y)||(this.fail("unquoted attribute value."),this.state=42,this.unget())}sAttribValueQuoted(){const{q:y,chunk:w}=this;let{i:_}=this;for(;;)switch(this.getCode()){case y:return this.pushAttrib(this.name,this.text+w.slice(_,this.prevI)),this.name=this.text="",this.q=null,void(this.state=41);case 38:return this.text+=w.slice(_,this.prevI),this.state=14,void(this.entityReturnState=40);case 10:case-2:case 9:this.text+=w.slice(_,this.prevI)+" ",_=this.i;break;case 60:return this.text+=w.slice(_,this.prevI),void this.fail("disallowed character.");case-1:return void(this.text+=w.slice(_))}}sAttribValueClosed(){const y=this.getCodeNorm();i(y)?this.state=36:y===62?this.openTag():y===47?this.state=35:o(y)?(this.fail("no whitespace between attributes."),this.unget(),this.state=37):this.fail("disallowed character in attribute name.")}sAttribValueUnquoted(){const y=this.captureTo(V);switch(y){case 38:this.state=14,this.entityReturnState=42;break;case 60:this.fail("disallowed character.");break;case-1:break;default:this.text.includes("]]>")&&this.fail('the string "]]>" is disallowed in char data.'),this.pushAttrib(this.name,this.text),this.name=this.text="",y===62?this.openTag():this.state=36}}sCloseTag(){const y=this.captureNameChars();y===62?this.closeTag():i(y)?this.state=44:y!==-1&&this.fail("disallowed character in closing tag.")}sCloseTagSawWhite(){switch(this.skipSpaces()){case 62:this.closeTag();break;case-1:break;default:this.fail("disallowed character in closing tag.")}}handleTextInRoot(){let{i:y,forbiddenState:w}=this;const{chunk:_,textHandler:S}=this;e:for(;;)switch(this.getCode()){case 60:if(this.state=15,S!==void 0){const{text:A}=this,O=_.slice(y,this.prevI);A.length!==0?(S(A+O),this.text=""):O.length!==0&&S(O)}w=0;break e;case 38:this.state=14,this.entityReturnState=13,S!==void 0&&(this.text+=_.slice(y,this.prevI)),w=0;break e;case 93:switch(w){case 0:w=1;break;case 1:w=2;break;case 2:break;default:throw new Error("impossible state")}break;case 62:w===2&&this.fail('the string "]]>" is disallowed in char data.'),w=0;break;case-2:S!==void 0&&(this.text+=_.slice(y,this.prevI)+` `),y=this.i,w=0;break;case-1:S!==void 0&&(this.text+=_.slice(y));break e;default:w=0}this.forbiddenState=w}handleTextOutsideRoot(){let{i:y}=this;const{chunk:w,textHandler:_}=this;let S=!1;e:for(;;){const A=this.getCode();switch(A){case 60:if(this.state=15,_!==void 0){const{text:O}=this,N=w.slice(y,this.prevI);O.length!==0?(_(O+N),this.text=""):N.length!==0&&_(N)}break e;case 38:this.state=14,this.entityReturnState=13,_!==void 0&&(this.text+=w.slice(y,this.prevI)),S=!0;break e;case-2:_!==void 0&&(this.text+=w.slice(y,this.prevI)+` `),y=this.i;break;case-1:_!==void 0&&(this.text+=w.slice(y));break e;default:i(A)||(S=!0)}}S&&(this.sawRoot||this.reportedTextBeforeRoot||(this.fail("text data outside of root node."),this.reportedTextBeforeRoot=!0),this.closedRoot&&!this.reportedTextAfterRoot&&(this.fail("text data outside of root node."),this.reportedTextAfterRoot=!0))}pushAttribNS(y,w){var _;const{prefix:S,local:A}=this.qname(y),O={name:y,prefix:S,local:A,value:w};if(this.attribList.push(O),(_=this.attributeHandler)===null||_===void 0||_.call(this,O),S==="xmlns"){const N=w.trim();this.currentXMLVersion==="1.0"&&N===""&&this.fail("invalid attempt to undefine prefix in XML 1.0"),this.topNS[A]=N,z(this,A,N)}else if(y==="xmlns"){const N=w.trim();this.topNS[""]=N,z(this,"",N)}}pushAttribPlain(y,w){var _;const S={name:y,value:w};this.attribList.push(S),(_=this.attributeHandler)===null||_===void 0||_.call(this,S)}end(){var y,w;this.sawRoot||this.fail("document must contain a root element.");const{tags:_}=this;for(;_.length>0;){const A=_.pop();this.fail("unclosed tag: "+A.name)}this.state!==0&&this.state!==13&&this.fail("unexpected end.");const{text:S}=this;return S.length!==0&&((y=this.textHandler)===null||y===void 0||y.call(this,S),this.text=""),this._closed=!0,(w=this.endHandler)===null||w===void 0||w.call(this),this._init(),this}resolve(y){var w,_;let S=this.topNS[y];if(S!==void 0)return S;const{tags:A}=this;for(let O=A.length-1;O>=0;O--)if(S=A[O].ns[y],S!==void 0)return S;return S=this.ns[y],S!==void 0?S:(_=(w=this.opt).resolvePrefix)===null||_===void 0?void 0:_.call(w,y)}qname(y){const w=y.indexOf(":");if(w===-1)return{prefix:"",local:y};const _=y.slice(w+1),S=y.slice(0,w);return(S===""||_===""||_.includes(":"))&&this.fail(`malformed name: ${y}.`),{prefix:S,local:_}}processAttribsNS(){var y;const{attribList:w}=this,_=this.tag;{const{prefix:O,local:N}=this.qname(_.name);_.prefix=O,_.local=N;const U=_.uri=(y=this.resolve(O))!==null&&y!==void 0?y:"";O!==""&&(O==="xmlns"&&this.fail('tags may not have "xmlns" as prefix.'),U===""&&(this.fail(`unbound namespace prefix: ${JSON.stringify(O)}.`),_.uri=O))}if(w.length===0)return;const{attributes:S}=_,A=new Set;for(const O of w){const{name:N,prefix:U,local:H}=O;let Z,D;U===""?(Z=N==="xmlns"?x:"",D=N):(Z=this.resolve(U),Z===void 0&&(this.fail(`unbound namespace prefix: ${JSON.stringify(U)}.`),Z=U),D=`{${Z}}${H}`),A.has(D)&&this.fail(`duplicate attribute: ${D}.`),A.add(D),O.uri=Z,S[N]=O}this.attribList=[]}processAttribsPlain(){const{attribList:y}=this,w=this.tag.attributes;for(const{name:_,value:S}of y)w[_]!==void 0&&this.fail(`duplicate attribute: ${_}.`),w[_]=S;this.attribList=[]}openTag(){var y;this.processAttribs();const{tags:w}=this,_=this.tag;_.isSelfClosing=!1,(y=this.openTagHandler)===null||y===void 0||y.call(this,_),w.push(_),this.state=13,this.name=""}openSelfClosingTag(){var y,w,_;this.processAttribs();const{tags:S}=this,A=this.tag;A.isSelfClosing=!0,(y=this.openTagHandler)===null||y===void 0||y.call(this,A),(w=this.closeTagHandler)===null||w===void 0||w.call(this,A),(this.tag=(_=S[S.length-1])!==null&&_!==void 0?_:null)===null&&(this.closedRoot=!0),this.state=13,this.name=""}closeTag(){const{tags:y,name:w}=this;if(this.state=13,this.name="",w==="")return this.fail("weird empty close tag."),void(this.text+="</>");const _=this.closeTagHandler;let S=y.length;for(;S-- >0;){const A=this.tag=y.pop();if(this.topNS=A.ns,_?.(A),A.name===w)break;this.fail("unexpected close tag.")}S===0?this.closedRoot=!0:S<0&&(this.fail(`unmatched closing tag: ${w}.`),this.text+=`</${w}>`)}parseEntity(y){if(y[0]!=="#"){const _=this.ENTITIES[y];return _!==void 0?_:(this.fail(this.isName(y)?"undefined entity.":"disallowed character in entity name."),`&${y};`)}let w=NaN;return y[1]==="x"&&/^#x[0-9a-f]+$/i.test(y)?w=parseInt(y.slice(2),16):/^#[0-9]+$/.test(y)&&(w=parseInt(y.slice(1),10)),this.isChar(w)?String.fromCodePoint(w):(this.fail("malformed character entity."),`&${y};`)}}},{"xmlchars/xml/1.0/ed5":543,"xmlchars/xml/1.1/ed2":544,"xmlchars/xmlns/1.0/ed3":545}],497:[function(e,a,f){var c=e("safe-buffer").Buffer;function s(l,i){this._block=c.alloc(l),this._finalSize=i,this._blockSize=l,this._len=0}s.prototype.update=function(l,i){typeof l=="string"&&(i=i||"utf8",l=c.from(l,i));for(var n=this._block,o=this._blockSize,h=l.length,u=this._len,d=0;d<h;){for(var m=u%o,b=Math.min(h-d,o-m),p=0;p<b;p++)n[m+p]=l[d+p];d+=b,(u+=b)%o==0&&this._update(n)}return this._len+=h,this},s.prototype.digest=function(l){var i=this._len%this._blockSize;this._block[i]=128,this._block.fill(0,i+1),i>=this._finalSize&&(this._update(this._block),this._block.fill(0));var n=8*this._len;if(n<=4294967295)this._block.writeUInt32BE(n,this._blockSize-4);else{var o=(4294967295&n)>>>0,h=(n-o)/4294967296;this._block.writeUInt32BE(h,this._blockSize-8),this._block.writeUInt32BE(o,this._blockSize-4)}this._update(this._block);var u=this._hash();return l?u.toString(l):u},s.prototype._update=function(){throw new Error("_update must be implemented by subclass")},a.exports=s},{"safe-buffer":494}],498:[function(e,a,f){var c=a.exports=function(s){s=s.toLowerCase();var l=c[s];if(!l)throw new Error(s+" is not supported (we accept pull requests)");return new l};c.sha=e("./sha"),c.sha1=e("./sha1"),c.sha224=e("./sha224"),c.sha256=e("./sha256"),c.sha384=e("./sha384"),c.sha512=e("./sha512")},{"./sha":499,"./sha1":500,"./sha224":501,"./sha256":502,"./sha384":503,"./sha512":504}],499:[function(e,a,f){var c=e("inherits"),s=e("./hash"),l=e("safe-buffer").Buffer,i=[1518500249,1859775393,-1894007588,-899497514],n=new Array(80);function o(){this.init(),this._w=n,s.call(this,64,56)}function h(d){return d<<30|d>>>2}function u(d,m,b,p){return d===0?m&b|~m&p:d===2?m&b|m&p|b&p:m^b^p}c(o,s),o.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},o.prototype._update=function(d){for(var m,b=this._w,p=0|this._a,v=0|this._b,g=0|this._c,x=0|this._d,C=0|this._e,T=0;T<16;++T)b[T]=d.readInt32BE(4*T);for(;T<80;++T)b[T]=b[T-3]^b[T-8]^b[T-14]^b[T-16];for(var R=0;R<80;++R){var B=~~(R/20),I=0|((m=p)<<5|m>>>27)+u(B,v,g,x)+C+b[R]+i[B];C=x,x=g,g=h(v),v=p,p=I}this._a=p+this._a|0,this._b=v+this._b|0,this._c=g+this._c|0,this._d=x+this._d|0,this._e=C+this._e|0},o.prototype._hash=function(){var d=l.allocUnsafe(20);return d.writeInt32BE(0|this._a,0),d.writeInt32BE(0|this._b,4),d.writeInt32BE(0|this._c,8),d.writeInt32BE(0|this._d,12),d.writeInt32BE(0|this._e,16),d},a.exports=o},{"./hash":497,inherits:440,"safe-buffer":494}],500:[function(e,a,f){var c=e("inherits"),s=e("./hash"),l=e("safe-buffer").Buffer,i=[1518500249,1859775393,-1894007588,-899497514],n=new Array(80);function o(){this.init(),this._w=n,s.call(this,64,56)}function h(m){return m<<5|m>>>27}function u(m){return m<<30|m>>>2}function d(m,b,p,v){return m===0?b&p|~b&v:m===2?b&p|b&v|p&v:b^p^v}c(o,s),o.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},o.prototype._update=function(m){for(var b,p=this._w,v=0|this._a,g=0|this._b,x=0|this._c,C=0|this._d,T=0|this._e,R=0;R<16;++R)p[R]=m.readInt32BE(4*R);for(;R<80;++R)p[R]=(b=p[R-3]^p[R-8]^p[R-14]^p[R-16])<<1|b>>>31;for(var B=0;B<80;++B){var I=~~(B/20),F=h(v)+d(I,g,x,C)+T+p[B]+i[I]|0;T=C,C=x,x=u(g),g=v,v=F}this._a=v+this._a|0,this._b=g+this._b|0,this._c=x+this._c|0,this._d=C+this._d|0,this._e=T+this._e|0},o.prototype._hash=function(){var m=l.allocUnsafe(20);return m.writeInt32BE(0|this._a,0),m.writeInt32BE(0|this._b,4),m.writeInt32BE(0|this._c,8),m.writeInt32BE(0|this._d,12),m.writeInt32BE(0|this._e,16),m},a.exports=o},{"./hash":497,inherits:440,"safe-buffer":494}],501:[function(e,a,f){var c=e("inherits"),s=e("./sha256"),l=e("./hash"),i=e("safe-buffer").Buffer,n=new Array(64);function o(){this.init(),this._w=n,l.call(this,64,56)}c(o,s),o.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},o.prototype._hash=function(){var h=i.allocUnsafe(28);return h.writeInt32BE(this._a,0),h.writeInt32BE(this._b,4),h.writeInt32BE(this._c,8),h.writeInt32BE(this._d,12),h.writeInt32BE(this._e,16),h.writeInt32BE(this._f,20),h.writeInt32BE(this._g,24),h},a.exports=o},{"./hash":497,"./sha256":502,inherits:440,"safe-buffer":494}],502:[function(e,a,f){var c=e("inherits"),s=e("./hash"),l=e("safe-buffer").Buffer,i=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],n=new Array(64);function o(){this.init(),this._w=n,s.call(this,64,56)}function h(p,v,g){return g^p&(v^g)}function u(p,v,g){return p&v|g&(p|v)}function d(p){return(p>>>2|p<<30)^(p>>>13|p<<19)^(p>>>22|p<<10)}function m(p){return(p>>>6|p<<26)^(p>>>11|p<<21)^(p>>>25|p<<7)}function b(p){return(p>>>7|p<<25)^(p>>>18|p<<14)^p>>>3}c(o,s),o.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},o.prototype._update=function(p){for(var v,g=this._w,x=0|this._a,C=0|this._b,T=0|this._c,R=0|this._d,B=0|this._e,I=0|this._f,F=0|this._g,L=0|this._h,V=0;V<16;++V)g[V]=p.readInt32BE(4*V);for(;V<64;++V)g[V]=0|(((v=g[V-2])>>>17|v<<15)^(v>>>19|v<<13)^v>>>10)+g[V-7]+b(g[V-15])+g[V-16];for(var z=0;z<64;++z){var E=L+m(B)+h(B,I,F)+i[z]+g[z]|0,P=d(x)+u(x,C,T)|0;L=F,F=I,I=B,B=R+E|0,R=T,T=C,C=x,x=E+P|0}this._a=x+this._a|0,this._b=C+this._b|0,this._c=T+this._c|0,this._d=R+this._d|0,this._e=B+this._e|0,this._f=I+this._f|0,this._g=F+this._g|0,this._h=L+this._h|0},o.prototype._hash=function(){var p=l.allocUnsafe(32);return p.writeInt32BE(this._a,0),p.writeInt32BE(this._b,4),p.writeInt32BE(this._c,8),p.writeInt32BE(this._d,12),p.writeInt32BE(this._e,16),p.writeInt32BE(this._f,20),p.writeInt32BE(this._g,24),p.writeInt32BE(this._h,28),p},a.exports=o},{"./hash":497,inherits:440,"safe-buffer":494}],503:[function(e,a,f){var c=e("inherits"),s=e("./sha512"),l=e("./hash"),i=e("safe-buffer").Buffer,n=new Array(160);function o(){this.init(),this._w=n,l.call(this,128,112)}c(o,s),o.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},o.prototype._hash=function(){var h=i.allocUnsafe(48);function u(d,m,b){h.writeInt32BE(d,b),h.writeInt32BE(m,b+4)}return u(this._ah,this._al,0),u(this._bh,this._bl,8),u(this._ch,this._cl,16),u(this._dh,this._dl,24),u(this._eh,this._el,32),u(this._fh,this._fl,40),h},a.exports=o},{"./hash":497,"./sha512":504,inherits:440,"safe-buffer":494}],504:[function(e,a,f){var c=e("inherits"),s=e("./hash"),l=e("safe-buffer").Buffer,i=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],n=new Array(160);function o(){this.init(),this._w=n,s.call(this,128,112)}function h(C,T,R){return R^C&(T^R)}function u(C,T,R){return C&T|R&(C|T)}function d(C,T){return(C>>>28|T<<4)^(T>>>2|C<<30)^(T>>>7|C<<25)}function m(C,T){return(C>>>14|T<<18)^(C>>>18|T<<14)^(T>>>9|C<<23)}function b(C,T){return(C>>>1|T<<31)^(C>>>8|T<<24)^C>>>7}function p(C,T){return(C>>>1|T<<31)^(C>>>8|T<<24)^(C>>>7|T<<25)}function v(C,T){return(C>>>19|T<<13)^(T>>>29|C<<3)^C>>>6}function g(C,T){return(C>>>19|T<<13)^(T>>>29|C<<3)^(C>>>6|T<<26)}function x(C,T){return C>>>0<T>>>0?1:0}c(o,s),o.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},o.prototype._update=function(C){for(var T=this._w,R=0|this._ah,B=0|this._bh,I=0|this._ch,F=0|this._dh,L=0|this._eh,V=0|this._fh,z=0|this._gh,E=0|this._hh,P=0|this._al,k=0|this._bl,y=0|this._cl,w=0|this._dl,_=0|this._el,S=0|this._fl,A=0|this._gl,O=0|this._hl,N=0;N<32;N+=2)T[N]=C.readInt32BE(4*N),T[N+1]=C.readInt32BE(4*N+4);for(;N<160;N+=2){var U=T[N-30],H=T[N-30+1],Z=b(U,H),D=p(H,U),q=v(U=T[N-4],H=T[N-4+1]),M=g(H,U),j=T[N-14],$=T[N-14+1],K=T[N-32],J=T[N-32+1],X=D+$|0,Q=Z+j+x(X,D)|0;Q=(Q=Q+q+x(X=X+M|0,M)|0)+K+x(X=X+J|0,J)|0,T[N]=Q,T[N+1]=X}for(var ee=0;ee<160;ee+=2){Q=T[ee],X=T[ee+1];var se=u(R,B,I),Y=u(P,k,y),te=d(R,P),ne=d(P,R),oe=m(L,_),ae=m(_,L),ce=i[ee],me=i[ee+1],be=h(L,V,z),ye=h(_,S,A),Me=O+ae|0,Te=E+oe+x(Me,O)|0;Te=(Te=(Te=Te+be+x(Me=Me+ye|0,ye)|0)+ce+x(Me=Me+me|0,me)|0)+Q+x(Me=Me+X|0,X)|0;var fe=ne+Y|0,ke=te+se+x(fe,ne)|0;E=z,O=A,z=V,A=S,V=L,S=_,L=F+Te+x(_=w+Me|0,w)|0,F=I,w=y,I=B,y=k,B=R,k=P,R=Te+ke+x(P=Me+fe|0,Me)|0}this._al=this._al+P|0,this._bl=this._bl+k|0,this._cl=this._cl+y|0,this._dl=this._dl+w|0,this._el=this._el+_|0,this._fl=this._fl+S|0,this._gl=this._gl+A|0,this._hl=this._hl+O|0,this._ah=this._ah+R+x(this._al,P)|0,this._bh=this._bh+B+x(this._bl,k)|0,this._ch=this._ch+I+x(this._cl,y)|0,this._dh=this._dh+F+x(this._dl,w)|0,this._eh=this._eh+L+x(this._el,_)|0,this._fh=this._fh+V+x(this._fl,S)|0,this._gh=this._gh+z+x(this._gl,A)|0,this._hh=this._hh+E+x(this._hl,O)|0},o.prototype._hash=function(){var C=l.allocUnsafe(64);function T(R,B,I){C.writeInt32BE(R,I),C.writeInt32BE(B,I+4)}return T(this._ah,this._al,0),T(this._bh,this._bl,8),T(this._ch,this._cl,16),T(this._dh,this._dl,24),T(this._eh,this._el,32),T(this._fh,this._fl,40),T(this._gh,this._gl,48),T(this._hh,this._hl,56),C},a.exports=o},{"./hash":497,inherits:440,"safe-buffer":494}],505:[function(e,a,f){a.exports=s;var c=e("events").EventEmitter;function s(){c.call(this)}e("inherits")(s,c),s.Readable=e("readable-stream/readable.js"),s.Writable=e("readable-stream/writable.js"),s.Duplex=e("readable-stream/duplex.js"),s.Transform=e("readable-stream/transform.js"),s.PassThrough=e("readable-stream/passthrough.js"),s.Stream=s,s.prototype.pipe=function(l,i){var n=this;function o(v){l.writable&&l.write(v)===!1&&n.pause&&n.pause()}function h(){n.readable&&n.resume&&n.resume()}n.on("data",o),l.on("drain",h),l._isStdio||i&&i.end===!1||(n.on("end",d),n.on("close",m));var u=!1;function d(){u||(u=!0,l.end())}function m(){u||(u=!0,typeof l.destroy=="function"&&l.destroy())}function b(v){if(p(),c.listenerCount(this,"error")===0)throw v}function p(){n.removeListener("data",o),l.removeListener("drain",h),n.removeListener("end",d),n.removeListener("close",m),n.removeListener("error",b),l.removeListener("error",b),n.removeListener("end",p),n.removeListener("close",p),l.removeListener("close",p)}return n.on("error",b),l.on("error",b),n.on("end",p),n.on("close",p),l.on("close",p),l.emit("pipe",n),l}},{events:422,inherits:440,"readable-stream/duplex.js":507,"readable-stream/passthrough.js":516,"readable-stream/readable.js":517,"readable-stream/transform.js":518,"readable-stream/writable.js":519}],506:[function(e,a,f){var c={}.toString;a.exports=Array.isArray||function(s){return c.call(s)=="[object Array]"}},{}],507:[function(e,a,f){a.exports=e("./lib/_stream_duplex.js")},{"./lib/_stream_duplex.js":508}],508:[function(e,a,f){var c=e("process-nextick-args"),s=Object.keys||function(p){var v=[];for(var g in p)v.push(g);return v};a.exports=d;var l=Object.create(e("core-util-is"));l.inherits=e("inherits");var i=e("./_stream_readable"),n=e("./_stream_writable");l.inherits(d,i);for(var o=s(n.prototype),h=0;h<o.length;h++){var u=o[h];d.prototype[u]||(d.prototype[u]=n.prototype[u])}function d(p){if(!(this instanceof d))return new d(p);i.call(this,p),n.call(this,p),p&&p.readable===!1&&(this.readable=!1),p&&p.writable===!1&&(this.writable=!1),this.allowHalfOpen=!0,p&&p.allowHalfOpen===!1&&(this.allowHalfOpen=!1),this.once("end",m)}function m(){this.allowHalfOpen||this._writableState.ended||c.nextTick(b,this)}function b(p){p.end()}Object.defineProperty(d.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(d.prototype,"destroyed",{get:function(){return this._readableState!==void 0&&this._writableState!==void 0&&this._readableState.destroyed&&this._writableState.destroyed},set:function(p){this._readableState!==void 0&&this._writableState!==void 0&&(this._readableState.destroyed=p,this._writableState.destroyed=p)}}),d.prototype._destroy=function(p,v){this.push(null),this.end(),c.nextTick(v,p)}},{"./_stream_readable":510,"./_stream_writable":512,"core-util-is":383,inherits:440,"process-nextick-args":466}],509:[function(e,a,f){a.exports=l;var c=e("./_stream_transform"),s=Object.create(e("core-util-is"));function l(i){if(!(this instanceof l))return new l(i);c.call(this,i)}s.inherits=e("inherits"),s.inherits(l,c),l.prototype._transform=function(i,n,o){o(null,i)}},{"./_stream_transform":511,"core-util-is":383,inherits:440}],510:[function(e,a,f){(function(c,s){(function(){var l=e("process-nextick-args");a.exports=R;var i,n=e("isarray");R.ReadableState=T,e("events").EventEmitter;var o=function(O,N){return O.listeners(N).length},h=e("./internal/streams/stream"),u=e("safe-buffer").Buffer,d=(s!==void 0?s:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){},m=Object.create(e("core-util-is"));m.inherits=e("inherits");var b=e("util"),p=void 0;p=b&&b.debuglog?b.debuglog("stream"):function(){};var v,g=e("./internal/streams/BufferList"),x=e("./internal/streams/destroy");m.inherits(R,h);var C=["error","close","destroy","pause","resume"];function T(O,N){O=O||{};var U=N instanceof(i=i||e("./_stream_duplex"));this.objectMode=!!O.objectMode,U&&(this.objectMode=this.objectMode||!!O.readableObjectMode);var H=O.highWaterMark,Z=O.readableHighWaterMark,D=this.objectMode?16:16384;this.highWaterMark=H||H===0?H:U&&(Z||Z===0)?Z:D,this.highWaterMark=Math.floor(this.highWaterMark),this.buffer=new g,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.destroyed=!1,this.defaultEncoding=O.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,O.encoding&&(v||(v=e("string_decoder/").StringDecoder),this.decoder=new v(O.encoding),this.encoding=O.encoding)}function R(O){if(i=i||e("./_stream_duplex"),!(this instanceof R))return new R(O);this._readableState=new T(O,this),this.readable=!0,O&&(typeof O.read=="function"&&(this._read=O.read),typeof O.destroy=="function"&&(this._destroy=O.destroy)),h.call(this)}function B(O,N,U,H,Z){var D,q=O._readableState;return N===null?(q.reading=!1,function(M,j){if(!j.ended){if(j.decoder){var $=j.decoder.end();$&&$.length&&(j.buffer.push($),j.length+=j.objectMode?1:$.length)}j.ended=!0,L(M)}}(O,q)):(Z||(D=function(M,j){var $;K=j,u.isBuffer(K)||K instanceof d||typeof j=="string"||j===void 0||M.objectMode||($=new TypeError("Invalid non-string/buffer chunk"));var K;return $}(q,N)),D?O.emit("error",D):q.objectMode||N&&N.length>0?(typeof N=="string"||q.objectMode||Object.getPrototypeOf(N)===u.prototype||(N=function(M){return u.from(M)}(N)),H?q.endEmitted?O.emit("error",new Error("stream.unshift() after end event")):I(O,q,N,!0):q.ended?O.emit("error",new Error("stream.push() after EOF")):(q.reading=!1,q.decoder&&!U?(N=q.decoder.write(N),q.objectMode||N.length!==0?I(O,q,N,!1):z(O,q)):I(O,q,N,!1))):H||(q.reading=!1)),function(M){return!M.ended&&(M.needReadable||M.length<M.highWaterMark||M.length===0)}(q)}function I(O,N,U,H){N.flowing&&N.length===0&&!N.sync?(O.emit("data",U),O.read(0)):(N.length+=N.objectMode?1:U.length,H?N.buffer.unshift(U):N.buffer.push(U),N.needReadable&&L(O)),z(O,N)}Object.defineProperty(R.prototype,"destroyed",{get:function(){return this._readableState!==void 0&&this._readableState.destroyed},set:function(O){this._readableState&&(this._readableState.destroyed=O)}}),R.prototype.destroy=x.destroy,R.prototype._undestroy=x.undestroy,R.prototype._destroy=function(O,N){this.push(null),N(O)},R.prototype.push=function(O,N){var U,H=this._readableState;return H.objectMode?U=!0:typeof O=="string"&&((N=N||H.defaultEncoding)!==H.encoding&&(O=u.from(O,N),N=""),U=!0),B(this,O,N,!1,U)},R.prototype.unshift=function(O){return B(this,O,null,!0,!1)},R.prototype.isPaused=function(){return this._readableState.flowing===!1},R.prototype.setEncoding=function(O){return v||(v=e("string_decoder/").StringDecoder),this._readableState.decoder=new v(O),this._readableState.encoding=O,this};function F(O,N){return O<=0||N.length===0&&N.ended?0:N.objectMode?1:O!=O?N.flowing&&N.length?N.buffer.head.data.length:N.length:(O>N.highWaterMark&&(N.highWaterMark=function(U){return U>=8388608?U=8388608:(U--,U|=U>>>1,U|=U>>>2,U|=U>>>4,U|=U>>>8,U|=U>>>16,U++),U}(O)),O<=N.length?O:N.ended?N.length:(N.needReadable=!0,0))}function L(O){var N=O._readableState;N.needReadable=!1,N.emittedReadable||(p("emitReadable",N.flowing),N.emittedReadable=!0,N.sync?l.nextTick(V,O):V(O))}function V(O){p("emit readable"),O.emit("readable"),y(O)}function z(O,N){N.readingMore||(N.readingMore=!0,l.nextTick(E,O,N))}function E(O,N){for(var U=N.length;!N.reading&&!N.flowing&&!N.ended&&N.length<N.highWaterMark&&(p("maybeReadMore read 0"),O.read(0),U!==N.length);)U=N.length;N.readingMore=!1}function P(O){p("readable nexttick read 0"),O.read(0)}function k(O,N){N.reading||(p("resume read 0"),O.read(0)),N.resumeScheduled=!1,N.awaitDrain=0,O.emit("resume"),y(O),N.flowing&&!N.reading&&O.read(0)}function y(O){var N=O._readableState;for(p("flow",N.flowing);N.flowing&&O.read()!==null;);}function w(O,N){return N.length===0?null:(N.objectMode?U=N.buffer.shift():!O||O>=N.length?(U=N.decoder?N.buffer.join(""):N.buffer.length===1?N.buffer.head.data:N.buffer.concat(N.length),N.buffer.clear()):U=function(H,Z,D){var q;return H<Z.head.data.length?(q=Z.head.data.slice(0,H),Z.head.data=Z.head.data.slice(H)):q=H===Z.head.data.length?Z.shift():D?function(M,j){var $=j.head,K=1,J=$.data;for(M-=J.length;$=$.next;){var X=$.data,Q=M>X.length?X.length:M;if(Q===X.length?J+=X:J+=X.slice(0,M),(M-=Q)===0){Q===X.length?(++K,$.next?j.head=$.next:j.head=j.tail=null):(j.head=$,$.data=X.slice(Q));break}++K}return j.length-=K,J}(H,Z):function(M,j){var $=u.allocUnsafe(M),K=j.head,J=1;for(K.data.copy($),M-=K.data.length;K=K.next;){var X=K.data,Q=M>X.length?X.length:M;if(X.copy($,$.length-M,0,Q),(M-=Q)===0){Q===X.length?(++J,K.next?j.head=K.next:j.head=j.tail=null):(j.head=K,K.data=X.slice(Q));break}++J}return j.length-=J,$}(H,Z),q}(O,N.buffer,N.decoder),U);var U}function _(O){var N=O._readableState;if(N.length>0)throw new Error('"endReadable()" called on non-empty stream');N.endEmitted||(N.ended=!0,l.nextTick(S,N,O))}function S(O,N){O.endEmitted||O.length!==0||(O.endEmitted=!0,N.readable=!1,N.emit("end"))}function A(O,N){for(var U=0,H=O.length;U<H;U++)if(O[U]===N)return U;return-1}R.prototype.read=function(O){p("read",O),O=parseInt(O,10);var N=this._readableState,U=O;if(O!==0&&(N.emittedReadable=!1),O===0&&N.needReadable&&(N.length>=N.highWaterMark||N.ended))return p("read: emitReadable",N.length,N.ended),N.length===0&&N.ended?_(this):L(this),null;if((O=F(O,N))===0&&N.ended)return N.length===0&&_(this),null;var H,Z=N.needReadable;return p("need readable",Z),(N.length===0||N.length-O<N.highWaterMark)&&p("length less than watermark",Z=!0),N.ended||N.reading?p("reading or ended",Z=!1):Z&&(p("do read"),N.reading=!0,N.sync=!0,N.length===0&&(N.needReadable=!0),this._read(N.highWaterMark),N.sync=!1,N.reading||(O=F(U,N))),(H=O>0?w(O,N):null)===null?(N.needReadable=!0,O=0):N.length-=O,N.length===0&&(N.ended||(N.needReadable=!0),U!==O&&N.ended&&_(this)),H!==null&&this.emit("data",H),H},R.prototype._read=function(O){this.emit("error",new Error("_read() is not implemented"))},R.prototype.pipe=function(O,N){var U=this,H=this._readableState;switch(H.pipesCount){case 0:H.pipes=O;break;case 1:H.pipes=[H.pipes,O];break;default:H.pipes.push(O)}H.pipesCount+=1,p("pipe count=%d opts=%j",H.pipesCount,N);var Z=(!N||N.end!==!1)&&O!==c.stdout&&O!==c.stderr?q:ee;function D(se,Y){p("onunpipe"),se===U&&Y&&Y.hasUnpiped===!1&&(Y.hasUnpiped=!0,p("cleanup"),O.removeListener("close",X),O.removeListener("finish",Q),O.removeListener("drain",M),O.removeListener("error",J),O.removeListener("unpipe",D),U.removeListener("end",q),U.removeListener("end",ee),U.removeListener("data",K),j=!0,!H.awaitDrain||O._writableState&&!O._writableState.needDrain||M())}function q(){p("onend"),O.end()}H.endEmitted?l.nextTick(Z):U.once("end",Z),O.on("unpipe",D);var M=function(se){return function(){var Y=se._readableState;p("pipeOnDrain",Y.awaitDrain),Y.awaitDrain&&Y.awaitDrain--,Y.awaitDrain===0&&o(se,"data")&&(Y.flowing=!0,y(se))}}(U);O.on("drain",M);var j=!1,$=!1;function K(se){p("ondata"),$=!1,O.write(se)!==!1||$||((H.pipesCount===1&&H.pipes===O||H.pipesCount>1&&A(H.pipes,O)!==-1)&&!j&&(p("false write response, pause",H.awaitDrain),H.awaitDrain++,$=!0),U.pause())}function J(se){p("onerror",se),ee(),O.removeListener("error",J),o(O,"error")===0&&O.emit("error",se)}function X(){O.removeListener("finish",Q),ee()}function Q(){p("onfinish"),O.removeListener("close",X),ee()}function ee(){p("unpipe"),U.unpipe(O)}return U.on("data",K),function(se,Y,te){if(typeof se.prependListener=="function")return se.prependListener(Y,te);se._events&&se._events[Y]?n(se._events[Y])?se._events[Y].unshift(te):se._events[Y]=[te,se._events[Y]]:se.on(Y,te)}(O,"error",J),O.once("close",X),O.once("finish",Q),O.emit("pipe",U),H.flowing||(p("pipe resume"),U.resume()),O},R.prototype.unpipe=function(O){var N=this._readableState,U={hasUnpiped:!1};if(N.pipesCount===0)return this;if(N.pipesCount===1)return O&&O!==N.pipes||(O||(O=N.pipes),N.pipes=null,N.pipesCount=0,N.flowing=!1,O&&O.emit("unpipe",this,U)),this;if(!O){var H=N.pipes,Z=N.pipesCount;N.pipes=null,N.pipesCount=0,N.flowing=!1;for(var D=0;D<Z;D++)H[D].emit("unpipe",this,{hasUnpiped:!1});return this}var q=A(N.pipes,O);return q===-1||(N.pipes.splice(q,1),N.pipesCount-=1,N.pipesCount===1&&(N.pipes=N.pipes[0]),O.emit("unpipe",this,U)),this},R.prototype.on=function(O,N){var U=h.prototype.on.call(this,O,N);if(O==="data")this._readableState.flowing!==!1&&this.resume();else if(O==="readable"){var H=this._readableState;H.endEmitted||H.readableListening||(H.readableListening=H.needReadable=!0,H.emittedReadable=!1,H.reading?H.length&&L(this):l.nextTick(P,this))}return U},R.prototype.addListener=R.prototype.on,R.prototype.resume=function(){var O=this._readableState;return O.flowing||(p("resume"),O.flowing=!0,function(N,U){U.resumeScheduled||(U.resumeScheduled=!0,l.nextTick(k,N,U))}(this,O)),this},R.prototype.pause=function(){return p("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(p("pause"),this._readableState.flowing=!1,this.emit("pause")),this},R.prototype.wrap=function(O){var N=this,U=this._readableState,H=!1;for(var Z in O.on("end",function(){if(p("wrapped end"),U.decoder&&!U.ended){var q=U.decoder.end();q&&q.length&&N.push(q)}N.push(null)}),O.on("data",function(q){p("wrapped data"),U.decoder&&(q=U.decoder.write(q)),U.objectMode&&q==null||(U.objectMode||q&&q.length)&&(N.push(q)||(H=!0,O.pause()))}),O)this[Z]===void 0&&typeof O[Z]=="function"&&(this[Z]=function(q){return function(){return O[q].apply(O,arguments)}}(Z));for(var D=0;D<C.length;D++)O.on(C[D],this.emit.bind(this,C[D]));return this._read=function(q){p("wrapped _read",q),H&&(H=!1,O.resume())},this},Object.defineProperty(R.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),R._fromList=w}).call(this)}).call(this,e("_process"),typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{"./_stream_duplex":508,"./internal/streams/BufferList":513,"./internal/streams/destroy":514,"./internal/streams/stream":515,_process:467,"core-util-is":383,events:422,inherits:440,isarray:506,"process-nextick-args":466,"safe-buffer":520,"string_decoder/":521,util:188}],511:[function(e,a,f){a.exports=i;var c=e("./_stream_duplex"),s=Object.create(e("core-util-is"));function l(h,u){var d=this._transformState;d.transforming=!1;var m=d.writecb;if(!m)return this.emit("error",new Error("write callback called multiple times"));d.writechunk=null,d.writecb=null,u!=null&&this.push(u),m(h);var b=this._readableState;b.reading=!1,(b.needReadable||b.length<b.highWaterMark)&&this._read(b.highWaterMark)}function i(h){if(!(this instanceof i))return new i(h);c.call(this,h),this._transformState={afterTransform:l.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,h&&(typeof h.transform=="function"&&(this._transform=h.transform),typeof h.flush=="function"&&(this._flush=h.flush)),this.on("prefinish",n)}function n(){var h=this;typeof this._flush=="function"?this._flush(function(u,d){o(h,u,d)}):o(this,null,null)}function o(h,u,d){if(u)return h.emit("error",u);if(d!=null&&h.push(d),h._writableState.length)throw new Error("Calling transform done when ws.length != 0");if(h._transformState.transforming)throw new Error("Calling transform done when still transforming");return h.push(null)}s.inherits=e("inherits"),s.inherits(i,c),i.prototype.push=function(h,u){return this._transformState.needTransform=!1,c.prototype.push.call(this,h,u)},i.prototype._transform=function(h,u,d){throw new Error("_transform() is not implemented")},i.prototype._write=function(h,u,d){var m=this._transformState;if(m.writecb=d,m.writechunk=h,m.writeencoding=u,!m.transforming){var b=this._readableState;(m.needTransform||b.needReadable||b.length<b.highWaterMark)&&this._read(b.highWaterMark)}},i.prototype._read=function(h){var u=this._transformState;u.writechunk!==null&&u.writecb&&!u.transforming?(u.transforming=!0,this._transform(u.writechunk,u.writeencoding,u.afterTransform)):u.needTransform=!0},i.prototype._destroy=function(h,u){var d=this;c.prototype._destroy.call(this,h,function(m){u(m),d.emit("close")})}},{"./_stream_duplex":508,"core-util-is":383,inherits:440}],512:[function(e,a,f){(function(c,s,l){(function(){var i=e("process-nextick-args");function n(z){var E=this;this.next=null,this.entry=null,this.finish=function(){(function(P,k,y){var w=P.entry;for(P.entry=null;w;){var _=w.callback;k.pendingcb--,_(y),w=w.next}k.corkedRequestsFree.next=P})(E,z)}}a.exports=T;var o,h=!c.browser&&["v0.10","v0.9."].indexOf(c.version.slice(0,5))>-1?l:i.nextTick;T.WritableState=C;var u=Object.create(e("core-util-is"));u.inherits=e("inherits");var d={deprecate:e("util-deprecate")},m=e("./internal/streams/stream"),b=e("safe-buffer").Buffer,p=(s!==void 0?s:typeof window<"u"?window:typeof self<"u"?self:{}).Uint8Array||function(){},v,g=e("./internal/streams/destroy");function x(){}function C(z,E){o=o||e("./_stream_duplex"),z=z||{};var P=E instanceof o;this.objectMode=!!z.objectMode,P&&(this.objectMode=this.objectMode||!!z.writableObjectMode);var k=z.highWaterMark,y=z.writableHighWaterMark,w=this.objectMode?16:16384;this.highWaterMark=k||k===0?k:P&&(y||y===0)?y:w,this.highWaterMark=Math.floor(this.highWaterMark),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var _=z.decodeStrings===!1;this.decodeStrings=!_,this.defaultEncoding=z.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(S){(function(A,O){var N=A._writableState,U=N.sync,H=N.writecb;if(function(D){D.writing=!1,D.writecb=null,D.length-=D.writelen,D.writelen=0}(N),O)(function(D,q,M,j,$){--q.pendingcb,M?(i.nextTick($,j),i.nextTick(V,D,q),D._writableState.errorEmitted=!0,D.emit("error",j)):($(j),D._writableState.errorEmitted=!0,D.emit("error",j),V(D,q))})(A,N,U,O,H);else{var Z=F(N);Z||N.corked||N.bufferProcessing||!N.bufferedRequest||I(A,N),U?h(B,A,N,Z,H):B(A,N,Z,H)}})(E,S)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new n(this)}function T(z){if(o=o||e("./_stream_duplex"),!(v.call(T,this)||this instanceof o))return new T(z);this._writableState=new C(z,this),this.writable=!0,z&&(typeof z.write=="function"&&(this._write=z.write),typeof z.writev=="function"&&(this._writev=z.writev),typeof z.destroy=="function"&&(this._destroy=z.destroy),typeof z.final=="function"&&(this._final=z.final)),m.call(this)}function R(z,E,P,k,y,w,_){E.writelen=k,E.writecb=_,E.writing=!0,E.sync=!0,P?z._writev(y,E.onwrite):z._write(y,w,E.onwrite),E.sync=!1}function B(z,E,P,k){P||function(y,w){w.length===0&&w.needDrain&&(w.needDrain=!1,y.emit("drain"))}(z,E),E.pendingcb--,k(),V(z,E)}function I(z,E){E.bufferProcessing=!0;var P=E.bufferedRequest;if(z._writev&&P&&P.next){var k=E.bufferedRequestCount,y=new Array(k),w=E.corkedRequestsFree;w.entry=P;for(var _=0,S=!0;P;)y[_]=P,P.isBuf||(S=!1),P=P.next,_+=1;y.allBuffers=S,R(z,E,!0,E.length,y,"",w.finish),E.pendingcb++,E.lastBufferedRequest=null,w.next?(E.corkedRequestsFree=w.next,w.next=null):E.corkedRequestsFree=new n(E),E.bufferedRequestCount=0}else{for(;P;){var A=P.chunk,O=P.encoding,N=P.callback;if(R(z,E,!1,E.objectMode?1:A.length,A,O,N),P=P.next,E.bufferedRequestCount--,E.writing)break}P===null&&(E.lastBufferedRequest=null)}E.bufferedRequest=P,E.bufferProcessing=!1}function F(z){return z.ending&&z.length===0&&z.bufferedRequest===null&&!z.finished&&!z.writing}function L(z,E){z._final(function(P){E.pendingcb--,P&&z.emit("error",P),E.prefinished=!0,z.emit("prefinish"),V(z,E)})}function V(z,E){var P=F(E);return P&&(function(k,y){y.prefinished||y.finalCalled||(typeof k._final=="function"?(y.pendingcb++,y.finalCalled=!0,i.nextTick(L,k,y)):(y.prefinished=!0,k.emit("prefinish")))}(z,E),E.pendingcb===0&&(E.finished=!0,z.emit("finish"))),P}u.inherits(T,m),C.prototype.getBuffer=function(){for(var z=this.bufferedRequest,E=[];z;)E.push(z),z=z.next;return E},function(){try{Object.defineProperty(C.prototype,"buffer",{get:d.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}(),typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(v=Function.prototype[Symbol.hasInstance],Object.defineProperty(T,Symbol.hasInstance,{value:function(z){return!!v.call(this,z)||this===T&&z&&z._writableState instanceof C}})):v=function(z){return z instanceof this},T.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},T.prototype.write=function(z,E,P){var k,y=this._writableState,w=!1,_=!y.objectMode&&(k=z,b.isBuffer(k)||k instanceof p);return _&&!b.isBuffer(z)&&(z=function(S){return b.from(S)}(z)),typeof E=="function"&&(P=E,E=null),_?E="buffer":E||(E=y.defaultEncoding),typeof P!="function"&&(P=x),y.ended?function(S,A){var O=new Error("write after end");S.emit("error",O),i.nextTick(A,O)}(this,P):(_||function(S,A,O,N){var U=!0,H=!1;return O===null?H=new TypeError("May not write null values to stream"):typeof O=="string"||O===void 0||A.objectMode||(H=new TypeError("Invalid non-string/buffer chunk")),H&&(S.emit("error",H),i.nextTick(N,H),U=!1),U}(this,y,z,P))&&(y.pendingcb++,w=function(S,A,O,N,U,H){if(!O){var Z=function(j,$,K){return j.objectMode||j.decodeStrings===!1||typeof $!="string"||($=b.from($,K)),$}(A,N,U);N!==Z&&(O=!0,U="buffer",N=Z)}var D=A.objectMode?1:N.length;A.length+=D;var q=A.length<A.highWaterMark;if(q||(A.needDrain=!0),A.writing||A.corked){var M=A.lastBufferedRequest;A.lastBufferedRequest={chunk:N,encoding:U,isBuf:O,callback:H,next:null},M?M.next=A.lastBufferedRequest:A.bufferedRequest=A.lastBufferedRequest,A.bufferedRequestCount+=1}else R(S,A,!1,D,N,U,H);return q}(this,y,_,z,E,P)),w},T.prototype.cork=function(){this._writableState.corked++},T.prototype.uncork=function(){var z=this._writableState;z.corked&&(z.corked--,z.writing||z.corked||z.bufferProcessing||!z.bufferedRequest||I(this,z))},T.prototype.setDefaultEncoding=function(z){if(typeof z=="string"&&(z=z.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((z+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+z);return this._writableState.defaultEncoding=z,this},Object.defineProperty(T.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),T.prototype._write=function(z,E,P){P(new Error("_write() is not implemented"))},T.prototype._writev=null,T.prototype.end=function(z,E,P){var k=this._writableState;typeof z=="function"?(P=z,z=null,E=null):typeof E=="function"&&(P=E,E=null),z!=null&&this.write(z,E),k.corked&&(k.corked=1,this.uncork()),k.ending||function(y,w,_){w.ending=!0,V(y,w),_&&(w.finished?i.nextTick(_):y.once("finish",_)),w.ended=!0,y.writable=!1}(this,k,P)},Object.defineProperty(T.prototype,"destroyed",{get:function(){return this._writableState!==void 0&&this._writableState.destroyed},set:function(z){this._writableState&&(this._writableState.destroyed=z)}}),T.prototype.destroy=g.destroy,T.prototype._undestroy=g.undestroy,T.prototype._destroy=function(z,E){this.end(),E(z)}}).call(this)}).call(this,e("_process"),typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{},e("timers").setImmediate)},{"./_stream_duplex":508,"./internal/streams/destroy":514,"./internal/streams/stream":515,_process:467,"core-util-is":383,inherits:440,"process-nextick-args":466,"safe-buffer":520,timers:523,"util-deprecate":524}],513:[function(e,a,f){var c=e("safe-buffer").Buffer,s=e("util");a.exports=function(){function l(){(function(i,n){if(!(i instanceof n))throw new TypeError("Cannot call a class as a function")})(this,l),this.head=null,this.tail=null,this.length=0}return l.prototype.push=function(i){var n={data:i,next:null};this.length>0?this.tail.next=n:this.head=n,this.tail=n,++this.length},l.prototype.unshift=function(i){var n={data:i,next:this.head};this.length===0&&(this.tail=n),this.head=n,++this.length},l.prototype.shift=function(){if(this.length!==0){var i=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,i}},l.prototype.clear=function(){this.head=this.tail=null,this.length=0},l.prototype.join=function(i){if(this.length===0)return"";for(var n=this.head,o=""+n.data;n=n.next;)o+=i+n.data;return o},l.prototype.concat=function(i){if(this.length===0)return c.alloc(0);for(var n,o,h,u=c.allocUnsafe(i>>>0),d=this.head,m=0;d;)n=d.data,o=u,h=m,n.copy(o,h),m+=d.data.length,d=d.next;return u},l}(),s&&s.inspect&&s.inspect.custom&&(a.exports.prototype[s.inspect.custom]=function(){var l=s.inspect({length:this.length});return this.constructor.name+" "+l})},{"safe-buffer":520,util:188}],514:[function(e,a,f){var c=e("process-nextick-args");function s(l,i){l.emit("error",i)}a.exports={destroy:function(l,i){var n=this,o=this._readableState&&this._readableState.destroyed,h=this._writableState&&this._writableState.destroyed;return o||h?(i?i(l):l&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,c.nextTick(s,this,l)):c.nextTick(s,this,l)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(l||null,function(u){!i&&u?n._writableState?n._writableState.errorEmitted||(n._writableState.errorEmitted=!0,c.nextTick(s,n,u)):c.nextTick(s,n,u):i&&i(u)}),this)},undestroy:function(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}}},{"process-nextick-args":466}],515:[function(e,a,f){arguments[4][490][0].apply(f,arguments)},{dup:490,events:422}],516:[function(e,a,f){a.exports=e("./readable").PassThrough},{"./readable":517}],517:[function(e,a,f){(f=a.exports=e("./lib/_stream_readable.js")).Stream=f,f.Readable=f,f.Writable=e("./lib/_stream_writable.js"),f.Duplex=e("./lib/_stream_duplex.js"),f.Transform=e("./lib/_stream_transform.js"),f.PassThrough=e("./lib/_stream_passthrough.js")},{"./lib/_stream_duplex.js":508,"./lib/_stream_passthrough.js":509,"./lib/_stream_readable.js":510,"./lib/_stream_transform.js":511,"./lib/_stream_writable.js":512}],518:[function(e,a,f){a.exports=e("./readable").Transform},{"./readable":517}],519:[function(e,a,f){a.exports=e("./lib/_stream_writable.js")},{"./lib/_stream_writable.js":512}],520:[function(e,a,f){arguments[4][217][0].apply(f,arguments)},{buffer:220,dup:217}],521:[function(e,a,f){arguments[4][218][0].apply(f,arguments)},{dup:218,"safe-buffer":520}],522:[function(e,a,f){arguments[4][218][0].apply(f,arguments)},{dup:218,"safe-buffer":494}],523:[function(e,a,f){(function(c,s){(function(){var l=e("process/browser.js").nextTick,i=Function.prototype.apply,n=Array.prototype.slice,o={},h=0;function u(d,m){this._id=d,this._clearFn=m}f.setTimeout=function(){return new u(i.call(setTimeout,window,arguments),clearTimeout)},f.setInterval=function(){return new u(i.call(setInterval,window,arguments),clearInterval)},f.clearTimeout=f.clearInterval=function(d){d.close()},u.prototype.unref=u.prototype.ref=function(){},u.prototype.close=function(){this._clearFn.call(window,this._id)},f.enroll=function(d,m){clearTimeout(d._idleTimeoutId),d._idleTimeout=m},f.unenroll=function(d){clearTimeout(d._idleTimeoutId),d._idleTimeout=-1},f._unrefActive=f.active=function(d){clearTimeout(d._idleTimeoutId);var m=d._idleTimeout;m>=0&&(d._idleTimeoutId=setTimeout(function(){d._onTimeout&&d._onTimeout()},m))},f.setImmediate=typeof c=="function"?c:function(d){var m=h++,b=!(arguments.length<2)&&n.call(arguments,1);return o[m]=!0,l(function(){o[m]&&(b?d.apply(null,b):d.call(null),f.clearImmediate(m))}),m},f.clearImmediate=typeof s=="function"?s:function(d){delete o[d]}}).call(this)}).call(this,e("timers").setImmediate,e("timers").clearImmediate)},{"process/browser.js":467,timers:523}],524:[function(e,a,f){(function(c){(function(){function s(l){try{if(!c.localStorage)return!1}catch{return!1}var i=c.localStorage[l];return i!=null&&String(i).toLowerCase()==="true"}a.exports=function(l,i){if(s("noDeprecation"))return l;var n=!1;return function(){if(!n){if(s("throwDeprecation"))throw new Error(i);s("traceDeprecation")?console.trace(i):console.warn(i),n=!0}return l.apply(this,arguments)}}}).call(this)}).call(this,typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{}],525:[function(e,a,f){typeof Object.create=="function"?a.exports=function(c,s){c.super_=s,c.prototype=Object.create(s.prototype,{constructor:{value:c,enumerable:!1,writable:!0,configurable:!0}})}:a.exports=function(c,s){c.super_=s;var l=function(){};l.prototype=s.prototype,c.prototype=new l,c.prototype.constructor=c}},{}],526:[function(e,a,f){a.exports=function(c){return c&&typeof c=="object"&&typeof c.copy=="function"&&typeof c.fill=="function"&&typeof c.readUInt8=="function"}},{}],527:[function(e,a,f){(function(c,s){(function(){var l=/%[sdj%]/g;f.format=function(y){if(!C(y)){for(var w=[],_=0;_<arguments.length;_++)w.push(o(arguments[_]));return w.join(" ")}_=1;for(var S=arguments,A=S.length,O=String(y).replace(l,function(U){if(U==="%%")return"%";if(_>=A)return U;switch(U){case"%s":return String(S[_++]);case"%d":return Number(S[_++]);case"%j":try{return JSON.stringify(S[_++])}catch{return"[Circular]"}default:return U}}),N=S[_];_<A;N=S[++_])g(N)||!B(N)?O+=" "+N:O+=" "+o(N);return O},f.deprecate=function(y,w){if(T(s.process))return function(){return f.deprecate(y,w).apply(this,arguments)};if(c.noDeprecation===!0)return y;var _=!1;return function(){if(!_){if(c.throwDeprecation)throw new Error(w);c.traceDeprecation?console.trace(w):console.error(w),_=!0}return y.apply(this,arguments)}};var i,n={};function o(y,w){var _={seen:[],stylize:u};return arguments.length>=3&&(_.depth=arguments[2]),arguments.length>=4&&(_.colors=arguments[3]),v(w)?_.showHidden=w:w&&f._extend(_,w),T(_.showHidden)&&(_.showHidden=!1),T(_.depth)&&(_.depth=2),T(_.colors)&&(_.colors=!1),T(_.customInspect)&&(_.customInspect=!0),_.colors&&(_.stylize=h),d(_,y,_.depth)}function h(y,w){var _=o.styles[w];return _?"\x1B["+o.colors[_][0]+"m"+y+"\x1B["+o.colors[_][1]+"m":y}function u(y,w){return y}function d(y,w,_){if(y.customInspect&&w&&L(w.inspect)&&w.inspect!==f.inspect&&(!w.constructor||w.constructor.prototype!==w)){var S=w.inspect(_,y);return C(S)||(S=d(y,S,_)),S}var A=function(M,j){if(T(j))return M.stylize("undefined","undefined");if(C(j)){var $="'"+JSON.stringify(j).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return M.stylize($,"string")}if(x(j))return M.stylize(""+j,"number");if(v(j))return M.stylize(""+j,"boolean");if(g(j))return M.stylize("null","null")}(y,w);if(A)return A;var O=Object.keys(w),N=function(M){var j={};return M.forEach(function($,K){j[$]=!0}),j}(O);if(y.showHidden&&(O=Object.getOwnPropertyNames(w)),F(w)&&(O.indexOf("message")>=0||O.indexOf("description")>=0))return m(w);if(O.length===0){if(L(w)){var U=w.name?": "+w.name:"";return y.stylize("[Function"+U+"]","special")}if(R(w))return y.stylize(RegExp.prototype.toString.call(w),"regexp");if(I(w))return y.stylize(Date.prototype.toString.call(w),"date");if(F(w))return m(w)}var H,Z="",D=!1,q=["{","}"];return p(w)&&(D=!0,q=["[","]"]),L(w)&&(Z=" [Function"+(w.name?": "+w.name:"")+"]"),R(w)&&(Z=" "+RegExp.prototype.toString.call(w)),I(w)&&(Z=" "+Date.prototype.toUTCString.call(w)),F(w)&&(Z=" "+m(w)),O.length!==0||D&&w.length!=0?_<0?R(w)?y.stylize(RegExp.prototype.toString.call(w),"regexp"):y.stylize("[Object]","special"):(y.seen.push(w),H=D?function(M,j,$,K,J){for(var X=[],Q=0,ee=j.length;Q<ee;++Q)k(j,String(Q))?X.push(b(M,j,$,K,String(Q),!0)):X.push("");return J.forEach(function(se){se.match(/^\d+$/)||X.push(b(M,j,$,K,se,!0))}),X}(y,w,_,N,O):O.map(function(M){return b(y,w,_,N,M,D)}),y.seen.pop(),function(M,j,$){return M.reduce(function(K,J){return J.indexOf(` `)>=0,K+J.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?$[0]+(j===""?"":j+` `)+" "+M.join(`, `)+" "+$[1]:$[0]+j+" "+M.join(", ")+" "+$[1]}(H,Z,q)):q[0]+Z+q[1]}function m(y){return"["+Error.prototype.toString.call(y)+"]"}function b(y,w,_,S,A,O){var N,U,H;if((H=Object.getOwnPropertyDescriptor(w,A)||{value:w[A]}).get?U=H.set?y.stylize("[Getter/Setter]","special"):y.stylize("[Getter]","special"):H.set&&(U=y.stylize("[Setter]","special")),k(S,A)||(N="["+A+"]"),U||(y.seen.indexOf(H.value)<0?(U=g(_)?d(y,H.value,null):d(y,H.value,_-1)).indexOf(` `)>-1&&(U=O?U.split(` `).map(function(Z){return" "+Z}).join(` `).substr(2):` `+U.split(` `).map(function(Z){return" "+Z}).join(` `)):U=y.stylize("[Circular]","special")),T(N)){if(O&&A.match(/^\d+$/))return U;(N=JSON.stringify(""+A)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(N=N.substr(1,N.length-2),N=y.stylize(N,"name")):(N=N.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),N=y.stylize(N,"string"))}return N+": "+U}function p(y){return Array.isArray(y)}function v(y){return typeof y=="boolean"}function g(y){return y===null}function x(y){return typeof y=="number"}function C(y){return typeof y=="string"}function T(y){return y===void 0}function R(y){return B(y)&&V(y)==="[object RegExp]"}function B(y){return typeof y=="object"&&y!==null}function I(y){return B(y)&&V(y)==="[object Date]"}function F(y){return B(y)&&(V(y)==="[object Error]"||y instanceof Error)}function L(y){return typeof y=="function"}function V(y){return Object.prototype.toString.call(y)}function z(y){return y<10?"0"+y.toString(10):y.toString(10)}f.debuglog=function(y){if(T(i)&&(i=c.env.NODE_DEBUG||""),y=y.toUpperCase(),!n[y])if(new RegExp("\\b"+y+"\\b","i").test(i)){var w=c.pid;n[y]=function(){var _=f.format.apply(f,arguments);console.error("%s %d: %s",y,w,_)}}else n[y]=function(){};return n[y]},f.inspect=o,o.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},o.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},f.isArray=p,f.isBoolean=v,f.isNull=g,f.isNullOrUndefined=function(y){return y==null},f.isNumber=x,f.isString=C,f.isSymbol=function(y){return typeof y=="symbol"},f.isUndefined=T,f.isRegExp=R,f.isObject=B,f.isDate=I,f.isError=F,f.isFunction=L,f.isPrimitive=function(y){return y===null||typeof y=="boolean"||typeof y=="number"||typeof y=="string"||typeof y=="symbol"||y===void 0},f.isBuffer=e("./support/isBuffer");var E=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function P(){var y=new Date,w=[z(y.getHours()),z(y.getMinutes()),z(y.getSeconds())].join(":");return[y.getDate(),E[y.getMonth()],w].join(" ")}function k(y,w){return Object.prototype.hasOwnProperty.call(y,w)}f.log=function(){console.log("%s - %s",P(),f.format.apply(f,arguments))},f.inherits=e("inherits"),f._extend=function(y,w){if(!w||!B(w))return y;for(var _=Object.keys(w),S=_.length;S--;)y[_[S]]=w[_[S]];return y}}).call(this)}).call(this,e("_process"),typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:{})},{"./support/isBuffer":526,_process:467,inherits:525}],528:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),Object.defineProperty(f,"v1",{enumerable:!0,get:function(){return c.default}}),Object.defineProperty(f,"v3",{enumerable:!0,get:function(){return s.default}}),Object.defineProperty(f,"v4",{enumerable:!0,get:function(){return l.default}}),Object.defineProperty(f,"v5",{enumerable:!0,get:function(){return i.default}}),Object.defineProperty(f,"NIL",{enumerable:!0,get:function(){return n.default}}),Object.defineProperty(f,"version",{enumerable:!0,get:function(){return o.default}}),Object.defineProperty(f,"validate",{enumerable:!0,get:function(){return h.default}}),Object.defineProperty(f,"stringify",{enumerable:!0,get:function(){return u.default}}),Object.defineProperty(f,"parse",{enumerable:!0,get:function(){return d.default}});var c=m(e("./v1.js")),s=m(e("./v3.js")),l=m(e("./v4.js")),i=m(e("./v5.js")),n=m(e("./nil.js")),o=m(e("./version.js")),h=m(e("./validate.js")),u=m(e("./stringify.js")),d=m(e("./parse.js"));function m(b){return b&&b.__esModule?b:{default:b}}},{"./nil.js":530,"./parse.js":531,"./stringify.js":535,"./v1.js":536,"./v3.js":537,"./v4.js":539,"./v5.js":540,"./validate.js":541,"./version.js":542}],529:[function(e,a,f){function c(d){return 14+(d+64>>>9<<4)+1}function s(d,m){const b=(65535&d)+(65535&m);return(d>>16)+(m>>16)+(b>>16)<<16|65535&b}function l(d,m,b,p,v,g){return s((x=s(s(m,d),s(p,g)))<<(C=v)|x>>>32-C,b);var x,C}function i(d,m,b,p,v,g,x){return l(m&b|~m&p,d,m,v,g,x)}function n(d,m,b,p,v,g,x){return l(m&p|b&~p,d,m,v,g,x)}function o(d,m,b,p,v,g,x){return l(m^b^p,d,m,v,g,x)}function h(d,m,b,p,v,g,x){return l(b^(m|~p),d,m,v,g,x)}Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0;var u=function(d){if(typeof d=="string"){const m=unescape(encodeURIComponent(d));d=new Uint8Array(m.length);for(let b=0;b<m.length;++b)d[b]=m.charCodeAt(b)}return function(m){const b=[],p=32*m.length;for(let v=0;v<p;v+=8){const g=m[v>>5]>>>v%32&255,x=parseInt("0123456789abcdef".charAt(g>>>4&15)+"0123456789abcdef".charAt(15&g),16);b.push(x)}return b}(function(m,b){m[b>>5]|=128<<b%32,m[c(b)-1]=b;let p=1732584193,v=-271733879,g=-1732584194,x=271733878;for(let C=0;C<m.length;C+=16){const T=p,R=v,B=g,I=x;p=i(p,v,g,x,m[C],7,-680876936),x=i(x,p,v,g,m[C+1],12,-389564586),g=i(g,x,p,v,m[C+2],17,606105819),v=i(v,g,x,p,m[C+3],22,-1044525330),p=i(p,v,g,x,m[C+4],7,-176418897),x=i(x,p,v,g,m[C+5],12,1200080426),g=i(g,x,p,v,m[C+6],17,-1473231341),v=i(v,g,x,p,m[C+7],22,-45705983),p=i(p,v,g,x,m[C+8],7,1770035416),x=i(x,p,v,g,m[C+9],12,-1958414417),g=i(g,x,p,v,m[C+10],17,-42063),v=i(v,g,x,p,m[C+11],22,-1990404162),p=i(p,v,g,x,m[C+12],7,1804603682),x=i(x,p,v,g,m[C+13],12,-40341101),g=i(g,x,p,v,m[C+14],17,-1502002290),v=i(v,g,x,p,m[C+15],22,1236535329),p=n(p,v,g,x,m[C+1],5,-165796510),x=n(x,p,v,g,m[C+6],9,-1069501632),g=n(g,x,p,v,m[C+11],14,643717713),v=n(v,g,x,p,m[C],20,-373897302),p=n(p,v,g,x,m[C+5],5,-701558691),x=n(x,p,v,g,m[C+10],9,38016083),g=n(g,x,p,v,m[C+15],14,-660478335),v=n(v,g,x,p,m[C+4],20,-405537848),p=n(p,v,g,x,m[C+9],5,568446438),x=n(x,p,v,g,m[C+14],9,-1019803690),g=n(g,x,p,v,m[C+3],14,-187363961),v=n(v,g,x,p,m[C+8],20,1163531501),p=n(p,v,g,x,m[C+13],5,-1444681467),x=n(x,p,v,g,m[C+2],9,-51403784),g=n(g,x,p,v,m[C+7],14,1735328473),v=n(v,g,x,p,m[C+12],20,-1926607734),p=o(p,v,g,x,m[C+5],4,-378558),x=o(x,p,v,g,m[C+8],11,-2022574463),g=o(g,x,p,v,m[C+11],16,1839030562),v=o(v,g,x,p,m[C+14],23,-35309556),p=o(p,v,g,x,m[C+1],4,-1530992060),x=o(x,p,v,g,m[C+4],11,1272893353),g=o(g,x,p,v,m[C+7],16,-155497632),v=o(v,g,x,p,m[C+10],23,-1094730640),p=o(p,v,g,x,m[C+13],4,681279174),x=o(x,p,v,g,m[C],11,-358537222),g=o(g,x,p,v,m[C+3],16,-722521979),v=o(v,g,x,p,m[C+6],23,76029189),p=o(p,v,g,x,m[C+9],4,-640364487),x=o(x,p,v,g,m[C+12],11,-421815835),g=o(g,x,p,v,m[C+15],16,530742520),v=o(v,g,x,p,m[C+2],23,-995338651),p=h(p,v,g,x,m[C],6,-198630844),x=h(x,p,v,g,m[C+7],10,1126891415),g=h(g,x,p,v,m[C+14],15,-1416354905),v=h(v,g,x,p,m[C+5],21,-57434055),p=h(p,v,g,x,m[C+12],6,1700485571),x=h(x,p,v,g,m[C+3],10,-1894986606),g=h(g,x,p,v,m[C+10],15,-1051523),v=h(v,g,x,p,m[C+1],21,-2054922799),p=h(p,v,g,x,m[C+8],6,1873313359),x=h(x,p,v,g,m[C+15],10,-30611744),g=h(g,x,p,v,m[C+6],15,-1560198380),v=h(v,g,x,p,m[C+13],21,1309151649),p=h(p,v,g,x,m[C+4],6,-145523070),x=h(x,p,v,g,m[C+11],10,-1120210379),g=h(g,x,p,v,m[C+2],15,718787259),v=h(v,g,x,p,m[C+9],21,-343485551),p=s(p,T),v=s(v,R),g=s(g,B),x=s(x,I)}return[p,v,g,x]}(function(m){if(m.length===0)return[];const b=8*m.length,p=new Uint32Array(c(b));for(let v=0;v<b;v+=8)p[v>>5]|=(255&m[v/8])<<v%32;return p}(d),8*d.length))};f.default=u},{}],530:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0,f.default="00000000-0000-0000-0000-000000000000"},{}],531:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0;var c,s=(c=e("./validate.js"))&&c.__esModule?c:{default:c},l=function(i){if(!(0,s.default)(i))throw TypeError("Invalid UUID");let n;const o=new Uint8Array(16);return o[0]=(n=parseInt(i.slice(0,8),16))>>>24,o[1]=n>>>16&255,o[2]=n>>>8&255,o[3]=255&n,o[4]=(n=parseInt(i.slice(9,13),16))>>>8,o[5]=255&n,o[6]=(n=parseInt(i.slice(14,18),16))>>>8,o[7]=255&n,o[8]=(n=parseInt(i.slice(19,23),16))>>>8,o[9]=255&n,o[10]=(n=parseInt(i.slice(24,36),16))/1099511627776&255,o[11]=n/4294967296&255,o[12]=n>>>24&255,o[13]=n>>>16&255,o[14]=n>>>8&255,o[15]=255&n,o};f.default=l},{"./validate.js":541}],532:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0,f.default=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i},{}],533:[function(e,a,f){let c;Object.defineProperty(f,"__esModule",{value:!0}),f.default=function(){if(!c&&(c=typeof crypto<"u"&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||typeof msCrypto<"u"&&typeof msCrypto.getRandomValues=="function"&&msCrypto.getRandomValues.bind(msCrypto),!c))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return c(s)};const s=new Uint8Array(16)},{}],534:[function(e,a,f){function c(i,n,o,h){switch(i){case 0:return n&o^~n&h;case 1:return n^o^h;case 2:return n&o^n&h^o&h;case 3:return n^o^h}}function s(i,n){return i<<n|i>>>32-n}Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0;var l=function(i){const n=[1518500249,1859775393,2400959708,3395469782],o=[1732584193,4023233417,2562383102,271733878,3285377520];if(typeof i=="string"){const m=unescape(encodeURIComponent(i));i=[];for(let b=0;b<m.length;++b)i.push(m.charCodeAt(b))}else Array.isArray(i)||(i=Array.prototype.slice.call(i));i.push(128);const h=i.length/4+2,u=Math.ceil(h/16),d=new Array(u);for(let m=0;m<u;++m){const b=new Uint32Array(16);for(let p=0;p<16;++p)b[p]=i[64*m+4*p]<<24|i[64*m+4*p+1]<<16|i[64*m+4*p+2]<<8|i[64*m+4*p+3];d[m]=b}d[u-1][14]=8*(i.length-1)/Math.pow(2,32),d[u-1][14]=Math.floor(d[u-1][14]),d[u-1][15]=8*(i.length-1)&4294967295;for(let m=0;m<u;++m){const b=new Uint32Array(80);for(let T=0;T<16;++T)b[T]=d[m][T];for(let T=16;T<80;++T)b[T]=s(b[T-3]^b[T-8]^b[T-14]^b[T-16],1);let p=o[0],v=o[1],g=o[2],x=o[3],C=o[4];for(let T=0;T<80;++T){const R=Math.floor(T/20),B=s(p,5)+c(R,v,g,x)+C+n[R]+b[T]>>>0;C=x,x=g,g=s(v,30)>>>0,v=p,p=B}o[0]=o[0]+p>>>0,o[1]=o[1]+v>>>0,o[2]=o[2]+g>>>0,o[3]=o[3]+x>>>0,o[4]=o[4]+C>>>0}return[o[0]>>24&255,o[0]>>16&255,o[0]>>8&255,255&o[0],o[1]>>24&255,o[1]>>16&255,o[1]>>8&255,255&o[1],o[2]>>24&255,o[2]>>16&255,o[2]>>8&255,255&o[2],o[3]>>24&255,o[3]>>16&255,o[3]>>8&255,255&o[3],o[4]>>24&255,o[4]>>16&255,o[4]>>8&255,255&o[4]]};f.default=l},{}],535:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0;var c,s=(c=e("./validate.js"))&&c.__esModule?c:{default:c};const l=[];for(let n=0;n<256;++n)l.push((n+256).toString(16).substr(1));var i=function(n){let o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;const h=(l[n[o+0]]+l[n[o+1]]+l[n[o+2]]+l[n[o+3]]+"-"+l[n[o+4]]+l[n[o+5]]+"-"+l[n[o+6]]+l[n[o+7]]+"-"+l[n[o+8]]+l[n[o+9]]+"-"+l[n[o+10]]+l[n[o+11]]+l[n[o+12]]+l[n[o+13]]+l[n[o+14]]+l[n[o+15]]).toLowerCase();if(!(0,s.default)(h))throw TypeError("Stringified UUID is invalid");return h};f.default=i},{"./validate.js":541}],536:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0;var c=l(e("./rng.js")),s=l(e("./stringify.js"));function l(d){return d&&d.__esModule?d:{default:d}}let i,n,o=0,h=0;var u=function(d,m,b){let p=m&&b||0;const v=m||new Array(16);let g=(d=d||{}).node||i,x=d.clockseq!==void 0?d.clockseq:n;if(g==null||x==null){const F=d.random||(d.rng||c.default)();g==null&&(g=i=[1|F[0],F[1],F[2],F[3],F[4],F[5]]),x==null&&(x=n=16383&(F[6]<<8|F[7]))}let C=d.msecs!==void 0?d.msecs:Date.now(),T=d.nsecs!==void 0?d.nsecs:h+1;const R=C-o+(T-h)/1e4;if(R<0&&d.clockseq===void 0&&(x=x+1&16383),(R<0||C>o)&&d.nsecs===void 0&&(T=0),T>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");o=C,h=T,n=x,C+=122192928e5;const B=(1e4*(268435455&C)+T)%4294967296;v[p++]=B>>>24&255,v[p++]=B>>>16&255,v[p++]=B>>>8&255,v[p++]=255&B;const I=C/4294967296*1e4&268435455;v[p++]=I>>>8&255,v[p++]=255&I,v[p++]=I>>>24&15|16,v[p++]=I>>>16&255,v[p++]=x>>>8|128,v[p++]=255&x;for(let F=0;F<6;++F)v[p+F]=g[F];return m||(0,s.default)(v)};f.default=u},{"./rng.js":533,"./stringify.js":535}],537:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0;var c=l(e("./v35.js")),s=l(e("./md5.js"));function l(n){return n&&n.__esModule?n:{default:n}}var i=(0,c.default)("v3",48,s.default);f.default=i},{"./md5.js":529,"./v35.js":538}],538:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=function(o,h,u){function d(m,b,p,v){if(typeof m=="string"&&(m=function(x){x=unescape(encodeURIComponent(x));const C=[];for(let T=0;T<x.length;++T)C.push(x.charCodeAt(T));return C}(m)),typeof b=="string"&&(b=(0,s.default)(b)),b.length!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let g=new Uint8Array(16+m.length);if(g.set(b),g.set(m,b.length),g=u(g),g[6]=15&g[6]|h,g[8]=63&g[8]|128,p){v=v||0;for(let x=0;x<16;++x)p[v+x]=g[x];return p}return(0,c.default)(g)}try{d.name=o}catch{}return d.DNS=i,d.URL=n,d},f.URL=f.DNS=void 0;var c=l(e("./stringify.js")),s=l(e("./parse.js"));function l(o){return o&&o.__esModule?o:{default:o}}const i="6ba7b810-9dad-11d1-80b4-00c04fd430c8";f.DNS=i;const n="6ba7b811-9dad-11d1-80b4-00c04fd430c8";f.URL=n},{"./parse.js":531,"./stringify.js":535}],539:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0;var c=l(e("./rng.js")),s=l(e("./stringify.js"));function l(n){return n&&n.__esModule?n:{default:n}}var i=function(n,o,h){const u=(n=n||{}).random||(n.rng||c.default)();if(u[6]=15&u[6]|64,u[8]=63&u[8]|128,o){h=h||0;for(let d=0;d<16;++d)o[h+d]=u[d];return o}return(0,s.default)(u)};f.default=i},{"./rng.js":533,"./stringify.js":535}],540:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0;var c=l(e("./v35.js")),s=l(e("./sha1.js"));function l(n){return n&&n.__esModule?n:{default:n}}var i=(0,c.default)("v5",80,s.default);f.default=i},{"./sha1.js":534,"./v35.js":538}],541:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0;var c,s=(c=e("./regex.js"))&&c.__esModule?c:{default:c},l=function(i){return typeof i=="string"&&s.default.test(i)};f.default=l},{"./regex.js":532}],542:[function(e,a,f){Object.defineProperty(f,"__esModule",{value:!0}),f.default=void 0;var c,s=(c=e("./validate.js"))&&c.__esModule?c:{default:c},l=function(i){if(!(0,s.default)(i))throw TypeError("Invalid UUID");return parseInt(i.substr(14,1),16)};f.default=l},{"./validate.js":541}],543:[function(e,a,f){/** * Character classes and associated utilities for the 5th edition of XML 1.0. * * @author Louis-Dominique Dubeau * @license MIT * @copyright Louis-Dominique Dubeau */Object.defineProperty(f,"__esModule",{value:!0}),f.CHAR=` \r --�𐀀-`,f.S=` \r `,f.NAME_START_CHAR=":A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-⁰-Ⰰ-、-豈-﷏ﷰ-�𐀀-",f.NAME_CHAR="-"+f.NAME_START_CHAR+".0-9·̀-ͯ‿-⁀",f.CHAR_RE=new RegExp("^["+f.CHAR+"]$","u"),f.S_RE=new RegExp("^["+f.S+"]+$","u"),f.NAME_START_CHAR_RE=new RegExp("^["+f.NAME_START_CHAR+"]$","u"),f.NAME_CHAR_RE=new RegExp("^["+f.NAME_CHAR+"]$","u"),f.NAME_RE=new RegExp("^["+f.NAME_START_CHAR+"]["+f.NAME_CHAR+"]*$","u"),f.NMTOKEN_RE=new RegExp("^["+f.NAME_CHAR+"]+$","u");function c(s){return s>=65&&s<=90||s>=97&&s<=122||s===58||s===95||s===8204||s===8205||s>=192&&s<=214||s>=216&&s<=246||s>=248&&s<=767||s>=880&&s<=893||s>=895&&s<=8191||s>=8304&&s<=8591||s>=11264&&s<=12271||s>=12289&&s<=55295||s>=63744&&s<=64975||s>=65008&&s<=65533||s>=65536&&s<=983039}f.S_LIST=[32,10,13,9],f.isChar=function(s){return s>=32&&s<=55295||s===10||s===13||s===9||s>=57344&&s<=65533||s>=65536&&s<=1114111},f.isS=function(s){return s===32||s===10||s===13||s===9},f.isNameStartChar=c,f.isNameChar=function(s){return c(s)||s>=48&&s<=57||s===45||s===46||s===183||s>=768&&s<=879||s>=8255&&s<=8256}},{}],544:[function(e,a,f){/** * Character classes and associated utilities for the 2nd edition of XML 1.1. * * @author Louis-Dominique Dubeau * @license MIT * @copyright Louis-Dominique Dubeau */Object.defineProperty(f,"__esModule",{value:!0}),f.CHAR="--�𐀀-",f.RESTRICTED_CHAR="-\b\v\f---",f.S=` \r `,f.NAME_START_CHAR=":A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ-⁰-Ⰰ-、-豈-﷏ﷰ-�𐀀-",f.NAME_CHAR="-"+f.NAME_START_CHAR+".0-9·̀-ͯ‿-⁀",f.CHAR_RE=new RegExp("^["+f.CHAR+"]$","u"),f.RESTRICTED_CHAR_RE=new RegExp("^["+f.RESTRICTED_CHAR+"]$","u"),f.S_RE=new RegExp("^["+f.S+"]+$","u"),f.NAME_START_CHAR_RE=new RegExp("^["+f.NAME_START_CHAR+"]$","u"),f.NAME_CHAR_RE=new RegExp("^["+f.NAME_CHAR+"]$","u"),f.NAME_RE=new RegExp("^["+f.NAME_START_CHAR+"]["+f.NAME_CHAR+"]*$","u"),f.NMTOKEN_RE=new RegExp("^["+f.NAME_CHAR+"]+$","u");function c(s){return s>=65&&s<=90||s>=97&&s<=122||s===58||s===95||s===8204||s===8205||s>=192&&s<=214||s>=216&&s<=246||s>=248&&s<=767||s>=880&&s<=893||s>=895&&s<=8191||s>=8304&&s<=8591||s>=11264&&s<=12271||s>=12289&&s<=55295||s>=63744&&s<=64975||s>=65008&&s<=65533||s>=65536&&s<=983039}f.S_LIST=[32,10,13,9],f.isChar=function(s){return s>=1&&s<=55295||s>=57344&&s<=65533||s>=65536&&s<=1114111},f.isRestrictedChar=function(s){return s>=1&&s<=8||s===11||s===12||s>=14&&s<=31||s>=127&&s<=132||s>=134&&s<=159},f.isCharAndNotRestricted=function(s){return s===9||s===10||s===13||s>31&&s<127||s===133||s>159&&s<=55295||s>=57344&&s<=65533||s>=65536&&s<=1114111},f.isS=function(s){return s===32||s===10||s===13||s===9},f.isNameStartChar=c,f.isNameChar=function(s){return c(s)||s>=48&&s<=57||s===45||s===46||s===183||s>=768&&s<=879||s>=8255&&s<=8256}},{}],545:[function(e,a,f){/** * Character class utilities for XML NS 1.0 edition 3. * * @author Louis-Dominique Dubeau * @license MIT * @copyright Louis-Dominique Dubeau */function c(s){return s>=65&&s<=90||s===95||s>=97&&s<=122||s>=192&&s<=214||s>=216&&s<=246||s>=248&&s<=767||s>=880&&s<=893||s>=895&&s<=8191||s>=8204&&s<=8205||s>=8304&&s<=8591||s>=11264&&s<=12271||s>=12289&&s<=55295||s>=63744&&s<=64975||s>=65008&&s<=65533||s>=65536&&s<=983039}Object.defineProperty(f,"__esModule",{value:!0}),f.NC_NAME_START_CHAR="A-Z_a-zÀ-ÖØ-öø-˿Ͱ-ͽͿ--⁰-Ⰰ-、-豈-﷏ﷰ-�𐀀-",f.NC_NAME_CHAR="-"+f.NC_NAME_START_CHAR+".0-9·̀-ͯ‿-⁀",f.NC_NAME_START_CHAR_RE=new RegExp("^["+f.NC_NAME_START_CHAR+"]$","u"),f.NC_NAME_CHAR_RE=new RegExp("^["+f.NC_NAME_CHAR+"]$","u"),f.NC_NAME_RE=new RegExp("^["+f.NC_NAME_START_CHAR+"]["+f.NC_NAME_CHAR+"]*$","u"),f.isNCNameStartChar=c,f.isNCNameChar=function(s){return c(s)||s===45||s===46||s>=48&&s<=57||s===183||s>=768&&s<=879||s>=8255&&s<=8256}},{}]},{},[15])(15)})}(_c)),_c.exports}var iO=nO();const sO=ku(iO);JSON.stringify([{day:"Monday",start_time:"09:00",end_time:"10:30"},{day:"Wednesday",start_time:"09:00",end_time:"10:30"}],null,2);const oO=()=>{const t=[{course_code:"CSE101",course_name:"Introduction to Programming",course_acronym:"IP",credits:4,dept_acronym:"CSE",semester:1,semester_type:"Monsoon",description:"Basic programming concepts using Python",professor_allocated:"Dr. Smith",prerequisites:"",antirequisites:"",schedule:JSON.stringify([{day:"Monday",start_time:"09:00",end_time:"10:30"},{day:"Wednesday",start_time:"09:00",end_time:"10:30"}]),related_course_codes:"CSE102,CSE201"},{course_code:"MTH270",course_name:"Linear Algebra",course_acronym:"LA",credits:3,dept_acronym:"MTH",semester:3,semester_type:"Winter",description:"Mathematical foundations of linear algebra with theoretical focus",professor_allocated:"Dr. Johnson",prerequisites:"MTH101,MTH102",antirequisites:"CSE270,ECE270",schedule:JSON.stringify([{day:"Tuesday",start_time:"11:00",end_time:"12:30"},{day:"Thursday",start_time:"11:00",end_time:"12:30"}]),related_course_codes:""}],r=As.json_to_sheet(t),e=As.book_new(),a=[["COURSE UPLOAD TEMPLATE INSTRUCTIONS"],[""],["REQUIRED FIELDS:"],["• course_code: Unique identifier for the course (e.g., CSE101)"],["• course_name: Full name of the course"],["• course_acronym: Short name or acronym for the course"],["• credits: Number of credits (1-16)"],["• dept_acronym: Department acronym (e.g., CSE, ECE, MTH)"],["• professor_allocated: Name of the instructor"],[""],["OPTIONAL FIELDS:"],["• semester: Recommended semester number (1-8)"],["• semester_type: One of: Monsoon, Winter, Summer"],["• description: Course description"],["• prerequisites: Comma-separated list of prerequisite course codes"],["• antirequisites: Comma-separated list of antirequisite course codes"],["• schedule: JSON array of class schedule (see examples)"],["• related_course_codes: Comma-separated list of related course codes"],[""],["SCHEDULE FORMAT:"],["The schedule should be a JSON array with objects containing:"],["• day: One of Monday, Tuesday, Wednesday, Thursday, Friday, Saturday"],["• start_time: Class start time in HH:MM format (24-hour)"],["• end_time: Class end time in HH:MM format (24-hour)"],[""],['Example: [{"day":"Monday","start_time":"09:00","end_time":"10:30"}]']],f=As.aoa_to_sheet(a);As.book_append_sheet(e,f,"Instructions"),As.book_append_sheet(e,r,"Course Data"),Sv(e,"course_upload_template_with_examples.xlsx")},aO=()=>{const[t,r]=G.useState(!1),[e,a]=G.useState(0),[f,c]=G.useState({success:[],errors:[]}),[s,l]=G.useState([]),[i,n]=G.useState(!1),[o,h]=G.useState(!1),[u,d]=G.useState([]),[m,b]=G.useState([]),[p,v]=G.useState([]),[g,x]=G.useState("update_all"),[C,T]=G.useState({}),[R,B]=G.useState([]),[I,F]=G.useState([]),L=ab();Cu();const V=rs("purple.200","gray.600");G.useEffect(()=>{(async()=>{try{const{data:j,error:$}=await rn.from("departments_iiitd").select("uuid, dept_name, dept_acronym").order("dept_name");if($)throw $;const K=j?.map(J=>({id:J.uuid,name:J.dept_name,acronym:J.dept_acronym}))||[];l(K)}catch(j){console.error("Error fetching streams:",j),L({title:"Error",description:"Failed to fetch streams",status:"error",duration:5e3,isClosable:!0})}})()},[L]);const z=async M=>M.map(j=>{let $=null;if(j.schedule)try{$=typeof j.schedule=="string"?j.schedule:JSON.stringify(j.schedule)}catch(K){console.error("Error processing schedule data:",K)}return{course_code:j.course_code,course_name:j.course_name,course_acronym:j.course_acronym||j.course_code.substring(0,4),credits:Number(j.credits),dept_acronym:j.dept_acronym,semester:j.semester?Number(j.semester):null,semester_type:j.semester_type||null,description:j.description||null,professor_allocated:j.professor_allocated||null,prerequisites:j.prerequisites||null,antirequisites:j.antirequisites||null,schedule:$,related_course_codes:j.related_course_codes||null,created_at:new Date().toISOString(),updated_at:new Date().toISOString()}}),E=async M=>{try{const{data:j,error:$}=await rn.from("courses_iiitd").select("course_code").in("course_code",M);if($)throw $;return j.map(K=>K.course_code)}catch(j){return console.error("Error checking existing courses:",j),[]}},P=M=>{const j=[],$={},K={};return M.forEach((J,X)=>{$[J.course_code]||($[J.course_code]=[]),$[J.course_code].push({...J,rowIndex:X});const Q=J.course_name.trim().toLowerCase();K[Q]||(K[Q]=[]),K[Q].push({...J,rowIndex:X})}),Object.entries($).forEach(([J,X])=>{if(X.length>1){const Q=X.map(ee=>ee.rowIndex+2);j.push({type:"excel_duplicate",courseCode:J,courseName:X[0].course_name,rowNumbers:Q,message:`Duplicate course code "${J}" found in Excel rows: ${Q.join(", ")}`})}}),Object.entries(K).forEach(([J,X])=>{if(X.length>1){const Q=[...new Set(X.map(ee=>ee.course_code))];if(Q.length>1){const ee=X.map(se=>se.rowIndex+2);j.push({type:"excel_duplicate",courseCode:Q.join(", "),courseName:X[0].course_name,rowNumbers:ee,message:`Duplicate course name "${X[0].course_name}" with different codes (${Q.join(", ")}) found in Excel rows: ${ee.join(", ")}`})}}}),j},k=M=>{const j=M.match(/([A-Z]+)(\d)(\d{2})/i);if(j){const[,$,K,J]=j;return{prefix:$.toUpperCase(),level:parseInt(K),number:parseInt(J),isUndergraduate:parseInt(K)<=4,isGraduate:parseInt(K)>=5,levelCategory:parseInt(K)<=2?"Introductory":parseInt(K)<=4?"Intermediate/Advanced":"Graduate"}}return null},y=async M=>{try{const j=M.map(ee=>ee.course_code),$=M.map(ee=>ee.course_name),{data:K,error:J}=await rn.from("courses_iiitd").select("uuid, course_code, course_name, dept_acronym, credits, semester").or(`course_code.in.(${j.join(",")}),course_name.in.(${$.map(ee=>`"${ee}"`).join(",")})`);if(J)throw console.error("Error checking for duplicates:",J),new Error(`Database error: ${J.message}`);const X=[],Q={};return K?.forEach(ee=>{const se=ee.course_name.trim().toLowerCase();Q[se]||(Q[se]=[]),Q[se].push(ee)}),M.forEach(ee=>{const se=ee.course_name.trim().toLowerCase(),Y=Q[se]||[];if(Y.length>0){const te=Y.find(ne=>ne.course_code===ee.course_code);if(te)X.push({type:"database_duplicate",courseCode:ee.course_code,courseName:ee.course_name,existingId:te.uuid,message:`⚠️ EXACT DUPLICATE: Course "${ee.course_code}" already exists in the database (ID: ${te.uuid}). This will be updated with your new data.`});else{const ne=Y.map(be=>be.course_code).join(", "),oe=[...new Set(Y.map(be=>be.dept_acronym))].join(", "),ae=k(ee.course_code),ce=Y.map(be=>({code:be.course_code,level:k(be.course_code),department:be.dept_acronym}));if(ae&&ce.some(be=>be.level&&be.level.prefix===ae.prefix&&be.level.level!==ae.level)){const be=ce.filter(ye=>ye.level&&ye.level.prefix===ae.prefix).map(ye=>`${ye.code} (${ye.level?.levelCategory})`).join(", ");X.push({type:"database_duplicate",courseCode:`${ee.course_code} (multi-level with ${ne})`,courseName:ee.course_name,existingId:Y[0].uuid,message:`🎓 MULTI-LEVEL COURSE: "${ee.course_name}" is already offered as ${be}. ✅ RECOMMENDED ACTION: Add "${ee.course_code}" (${ae.levelCategory}) as a separate course entry if: • This is a different academic level (undergraduate vs graduate) • It has more advanced prerequisites and content • Different target audience (${ae.isGraduate?"graduate":"undergraduate"} students) • Higher credit hours or more rigorous requirements 📚 EXAMPLES: • SSH322 (Intermediate) vs SSH522 (Graduate) - Same topic, different depth • MTH201 (Undergraduate) vs MTH501 (Graduate) - Advanced version • CSE301 (Intermediate) vs CSE601 (Graduate) - Research-focused version ⚠️ AVOID DUPLICATE if: • Same level courses with just different numbering • No significant difference in content depth or prerequisites • Same target student population 💡 TIP: Multi-level courses are common where graduate students need more advanced treatment of the same subject matter.`})}else[...new Set(Y.map(ye=>ye.dept_acronym))].length>1||!Y.some(ye=>ye.dept_acronym===ee.dept_acronym)?X.push({type:"database_duplicate",courseCode:`${ee.course_code} (cross-dept with ${ne})`,courseName:ee.course_name,existingId:Y[0].uuid,message:`📚 CROSS-DEPARTMENTAL COURSE: "${ee.course_name}" is already offered as ${ne} by ${oe}. ✅ RECOMMENDED ACTION: Add "${ee.course_code}" as a separate course entry if: • This course is taught by a different department • It has different prerequisites, schedule, or instructor • Students need to enroll specifically in this department's version ⚠️ AVOID DUPLICATE if: • This is the exact same course with just a different code • Students can enroll in either version interchangeably • The content, instructor, and requirements are identical 💡 TIP: Cross-departmental courses are common (e.g., MTH270 & CSE270 both teaching Linear Algebra). Each department can have their own entry with department-specific details.`}):X.push({type:"database_duplicate",courseCode:`${ee.course_code} (potential duplicate of ${ne})`,courseName:ee.course_name,existingId:Y[0].uuid,message:`🚫 POTENTIAL DUPLICATE: "${ee.course_name}" already exists as ${ne} in the same department. ⚠️ REVIEW NEEDED: Multiple course codes for the same content within one department is unusual. ✅ PROCEED ONLY if: • This represents a genuine course restructuring • Different course codes serve different degree requirements • There are meaningful differences in content or level 🚫 AVOID if: • This is just an administrative code change • No real difference in course content or requirements • Would confuse students with multiple identical options`})}}}),X}catch(j){return console.error("Error detecting database duplicates:",j),[]}},w=async M=>{try{const j=M.map(Q=>Q.course_name),{data:$,error:K}=await rn.from("courses_iiitd").select("uuid, course_code, course_name").in("course_name",j);if(K)throw K;const J={},X=[];return M.forEach(Q=>{const ee=$?.find(se=>se.course_name.trim().toLowerCase()===Q.course_name.trim().toLowerCase());ee&&(ee.course_code!==Q.course_code?(J[Q.course_code]=ee.course_code,console.log(`Detected update: ${ee.course_code} → ${Q.course_code} (${Q.course_name})`)):X.push(Q.course_code))}),{updateMappings:J,duplicateDetection:X}}catch(j){return console.error("Error finding course updates:",j),{updateMappings:{},duplicateDetection:[]}}},_=(M,j,$,K,J,X,Q,ee)=>{const se={type:M,courseCode:j,courseName:$,action:K,details:J,timestamp:new Date().toLocaleString(),oldValues:X||void 0,newValues:Q||void 0,errorMessage:ee};F(Y=>[...Y,se]),console.log(`[CHANGE LOG] ${M.toUpperCase()}: ${j} - ${K}`,se)},S=async M=>{try{const{data:j,error:$}=await rn.from("courses_iiitd").select("*").eq("course_code",M).single();return $?null:j}catch{return null}},A=(M,j,$)=>{const K=[];if(JSON.stringify(M)!==JSON.stringify(j))if(Array.isArray(M)||Array.isArray(j)){const J=Array.isArray(M)?M:[],X=Array.isArray(j)?j:[];K.push(`${$}: [${J.join(", ")}] → [${X.join(", ")}]`)}else K.push(`${$}: "${M||"null"}" → "${j||"null"}"`);return K},O=(M,j)=>{const $=[];return $.push(...A(M.course_code,j.course_code,"Course Code")),$.push(...A(M.course_name,j.course_name,"Course Name")),$.push(...A(M.credits,j.credits,"Credits")),$.push(...A(M.semester,j.semester,"Semester")),$.push(...A(M.description,j.description,"Description")),$.push(...A(M.professor_allocated,j.professor_allocated,"Instructor")),$.push(...A(M.dept_acronym,j.dept_acronym,"Department")),$.push(...A(M.prerequisites,j.prerequisites,"Prerequisites")),$.push(...A(M.antirequisites,j.antirequisites,"Anti-requisites")),$.push(...A(M.schedule,j.schedule,"Schedule")),$.push(...A(M.related_course_codes,j.related_course_codes,"Related Courses Codes")),$.filter(Boolean)},N=async M=>{const j=M.target.files?.[0];if(j){n(!0),a(0),c({success:[],errors:[]}),B([]),F([]);try{const{data:{session:$},error:K}=await rn.auth.getSession();if(K||!$){L({title:"Authentication Error",description:"Please login as admin first",status:"error",duration:5e3,isClosable:!0}),n(!1);return}console.log("=== STARTING EXCEL FILE PROCESSING ===");const J=new sO.Workbook,X=await j.arrayBuffer();await J.xlsx.load(X);const Q=J.worksheets[0];if(!Q){L({title:"Invalid File",description:"Could not find any worksheets in the Excel file",status:"error",duration:5e3,isClosable:!0}),n(!1);return}const ee=[];Q.getRow(1).eachCell(fe=>{ee.push(fe.text)});const se=[];if(Q.eachRow((fe,ke)=>{if(ke>1){const Ee={};fe.eachCell((Ne,De)=>{if(De<=ee.length){const je=ee[De-1];Ee[je]=Ne.text}}),se.push(Ee)}}),se.length===0){L({title:"Empty File",description:"The Excel file contains no data rows",status:"warning",duration:5e3,isClosable:!0}),n(!1);return}const Y=await z(se),te=P(Y),ne=await y(Y),oe=[...te,...ne];if(B(oe),oe.length>0){const fe=oe.some(Ee=>Ee.type==="excel_duplicate"),ke=oe.some(Ee=>Ee.type==="database_duplicate");fe?L({title:"Excel File Issues Detected",description:`Found ${oe.length} issues in your Excel file. Scroll down to see the detailed error list below.`,status:"error",duration:15e3,isClosable:!0}):ke&&L({title:"Potential Course Conflicts",description:`Found ${oe.length} potential naming conflicts. Scroll down to see the detailed error list below.`,status:"warning",duration:15e3,isClosable:!0}),n(!1);return}const ae=Y.map(fe=>fe.course_code),ce=await E(ae),{updateMappings:me,duplicateDetection:be}=await w(Y),ye=[...new Set([...ce,...Object.keys(me)])],Me=ae.filter(fe=>!ye.includes(fe));d(Y.map(fe=>({...fe,isUpdate:!!me[fe.course_code],originalCode:me[fe.course_code]||fe.course_code}))),b(ye),v(Me),console.log("Update mappings detected:",me),console.log("New courses:",Me),console.log("Existing/Update courses:",ye);const Te={};ce.forEach(fe=>{Te[fe]=!0}),T(Te),Y.length>0?h(!0):L({title:"No valid courses found",description:"The Excel file does not contain any valid courses to upload.",status:"warning",duration:5e3,isClosable:!0})}catch($){console.error("Error reading Excel file:",$),L({title:"Error",description:$ instanceof Error?$.message:"Failed to read the Excel file",status:"error",duration:5e3,isClosable:!0})}finally{n(!1)}}},U=async()=>{h(!1),r(!0),F([]);try{let M=[];g==="update_all"?M=u:g==="add_new_only"?M=u.filter(J=>!m.includes(J.course_code)):g==="custom"&&(M=u.filter(J=>!m.includes(J.course_code)||m.includes(J.course_code)&&C[J.course_code])),console.log(`=== STARTING DATABASE UPLOAD OF ${M.length} COURSES ===`);const j=[];let $=0,K=0;for(let J=0;J<M.length;J++){const X=M[J];console.log(`Processing course ${J+1}/${M.length}: ${X.course_code}`),J>0&&J%5===0&&await new Promise(Q=>setTimeout(Q,1e3));try{let Q,ee,se=!m.includes(X.course_code),Y=null;if(!se||X.isUpdate){const te=X.originalCode||X.course_code;Y=await S(te)}if(X.isUpdate&&X.originalCode){console.log(`Updating course: ${X.originalCode} → ${X.course_code}`);const te={course_code:X.course_code,course_acronym:X.course_code,course_name:X.course_name,credits:X.credits,dept_acronym:X.dept_acronym,semester:X.semester,semester_type:X.semester_type,description:X.description,professor_allocated:X.professor_allocated,prerequisites:X.prerequisites,antirequisites:X.antirequisites,schedule:X.schedule,related_course_codes:X.related_course_codes,updated_at:new Date().toISOString()},{error:ne}=await rn.from("courses_iiitd").delete().eq("course_code",X.originalCode);if(ne)throw new Error(`Failed to delete old course ${X.originalCode}: ${ne.message}`);const oe=await rn.from("courses_iiitd").insert(te);if(Q=oe.data,ee=oe.error,!ee){const ae=Y?O(Y,X):[],ce=ae.length>0?ae.join("; "):"Course code updated";_("updated",X.course_code,X.course_name,`Course code changed from ${X.originalCode} to ${X.course_code}`,ce,Y,te)}}else{const te={course_code:X.course_code,course_acronym:X.course_code,course_name:X.course_name,credits:X.credits,dept_acronym:X.dept_acronym,semester:X.semester,semester_type:X.semester_type,description:X.description,professor_allocated:X.professor_allocated,prerequisites:X.prerequisites,antirequisites:X.antirequisites,schedule:X.schedule,related_course_codes:X.related_course_codes,created_at:new Date().toISOString(),updated_at:new Date().toISOString()},ne=await rn.from("courses_iiitd").upsert(te,{onConflict:"course_code",ignoreDuplicates:!1});if(Q=ne.data,ee=ne.error,!ee)if(se)_("added",X.course_code,X.course_name,"New course added",`Credits: ${X.credits}, Semester: ${X.semester}, Department: ${X.dept_acronym}`,void 0,te);else{const oe=Y?O(Y,X):[],ae=oe.length>0?oe.join("; "):"No changes detected";oe.length>0?_("updated",X.course_code,X.course_name,"Course updated",ae,Y,te):_("skipped",X.course_code,X.course_name,"No changes needed","Course data is identical to existing record",Y,te)}}if(ee)console.error(`Error upserting course ${X.course_code}:`,ee),K++,_("error",X.course_code,X.course_name,"Failed to process course",`Database error: ${ee.message}`,Y,X,ee.message),c(te=>({...te,errors:[...te.errors,`Failed to add/update ${X.course_code}: ${ee.message||"Server error"}`]}));else{console.log(`Successfully upserted course ${X.course_code}`),$++,j.push(X.course_code);const te=X.isUpdate?`updated (${X.originalCode} → ${X.course_code})`:m.includes(X.course_code)?"updated":"added";c(ne=>({...ne,success:[...ne.success,`Successfully ${te} ${X.course_code}`]}))}a((J+1)/M.length*100)}catch(Q){console.error(`Error processing course ${X.course_code}:`,Q),K++,_("error",X.course_code,X.course_name,"Processing failed","Unexpected error during processing",void 0,X,Q instanceof Error?Q.message:"Unknown error"),c(ee=>({...ee,errors:[...ee.errors,`Failed to add/update ${X.course_code}: ${Q instanceof Error?Q.message:"Unknown error"}`]}))}}if(j.length>0){const J=JSON.parse(sessionStorage.getItem("uploadedCourses")||"[]");sessionStorage.setItem("uploadedCourses",JSON.stringify([...J,...j]))}console.log(`=== UPLOAD COMPLETE: ${$} successful, ${K} failed ===`),L({title:"Upload Complete",description:`Successfully processed ${$} courses with ${K} errors. Check the change log for details.`,status:"success",duration:8e3,isClosable:!0})}catch(M){console.error("Error uploading courses:",M),L({title:"Upload Error",description:M instanceof Error?M.message:"An unexpected error occurred during upload",status:"error",duration:5e3,isClosable:!0})}finally{r(!1)}},H=M=>{const j={};m.forEach($=>{j[$]=M}),T(j)},Z=()=>{h(!1),d([]),b([]),v([]),B([]),F([])},D=()=>{B([]),d([]),b([]),v([]),F([]),c({success:[],errors:[]});const M=document.getElementById("file-upload");M&&(M.value=""),L({title:"Cleared",description:"Error list cleared. You can now upload a corrected Excel file.",status:"info",duration:3e3,isClosable:!0})},q=async()=>{try{r(!0);const M=JSON.parse(sessionStorage.getItem("uploadedCourses")||"[]");if(M.length===0){L({title:"No courses to delete",description:"No courses have been uploaded in this session",status:"info",duration:5e3,isClosable:!0}),r(!1);return}if(!window.confirm(`Are you sure you want to delete ${M.length} uploaded courses? This action cannot be undone.`)){r(!1);return}const j=20;let $=0,K=0;for(let J=0;J<M.length;J+=j){const X=M.slice(J,J+j);try{const{error:Q}=await rn.from("courses_iiitd").delete().in("course_code",X);Q?(console.error("Error deleting courses:",Q),K+=X.length):$+=X.length,a((J+X.length)/M.length*100)}catch(Q){console.error("Error in batch delete:",Q),K+=X.length}}sessionStorage.removeItem("uploadedCourses"),L({title:"Deletion Complete",description:`Successfully deleted ${$} courses with ${K} errors`,status:"success",duration:5e3,isClosable:!0}),c({success:[],errors:[]})}catch(M){console.error("Error deleting courses:",M),L({title:"Error",description:"Failed to delete courses",status:"error",duration:5e3,isClosable:!0})}finally{r(!1)}};return W.jsx(ft,{p:8,maxWidth:"1200px",mx:"auto",bgGradient:"linear(to-br, purple.50, blue.50)",children:W.jsxs(yr,{spacing:8,align:"stretch",bg:"white",p:8,borderRadius:"xl",boxShadow:"lg",border:"1px",borderColor:V,children:[W.jsxs(pu,{justify:"space-between",align:"center",w:"100%",flexWrap:"wrap",gap:4,children:[W.jsx(ft,{children:W.jsx(hi,{size:"lg",bgGradient:"linear(to-r, blue.400, purple.500)",bgClip:"text",children:"Add New Course"})}),W.jsx(rO,{})]}),W.jsx(Gs,{allowToggle:!0,children:W.jsxs(qs,{children:[W.jsx("h2",{children:W.jsxs(Ws,{children:[W.jsx(ft,{flex:"1",textAlign:"left",children:W.jsx(He,{fontWeight:"bold",children:"Upload Format Instructions"})}),W.jsx(Hs,{})]})}),W.jsx(Ks,{pb:4,children:W.jsxs(yr,{align:"stretch",spacing:4,children:[W.jsx(He,{children:"Download the template below and fill in your course data following these guidelines:"}),W.jsxs(_u,{variant:"simple",size:"sm",children:[W.jsx(Cm,{children:W.jsxs(Er,{children:[W.jsx(Ur,{children:"Field"}),W.jsx(Ur,{children:"Format"}),W.jsx(Ur,{children:"Example"})]})}),W.jsxs(Tm,{children:[W.jsxs(Er,{children:[W.jsx(lt,{children:"course_code"}),W.jsx(lt,{children:"String"}),W.jsx(lt,{children:"CSE101"})]}),W.jsxs(Er,{children:[W.jsx(lt,{children:"course_name"}),W.jsx(lt,{children:"String"}),W.jsx(lt,{children:"Introduction to Programming"})]}),W.jsxs(Er,{children:[W.jsx(lt,{children:"course_acronym"}),W.jsx(lt,{children:"String"}),W.jsx(lt,{children:"IP"})]}),W.jsxs(Er,{children:[W.jsx(lt,{children:"credits"}),W.jsx(lt,{children:"Number"}),W.jsx(lt,{children:"4"})]}),W.jsxs(Er,{children:[W.jsx(lt,{children:"dept_acronym"}),W.jsx(lt,{children:"String"}),W.jsx(lt,{children:"CSE"})]}),W.jsxs(Er,{children:[W.jsx(lt,{children:"semester"}),W.jsx(lt,{children:"Number"}),W.jsx(lt,{children:"1"})]}),W.jsxs(Er,{children:[W.jsx(lt,{children:"semester_type"}),W.jsx(lt,{children:"String"}),W.jsx(lt,{children:"Monsoon"})]}),W.jsxs(Er,{children:[W.jsx(lt,{children:"prerequisites"}),W.jsx(lt,{children:"Comma-separated"}),W.jsx(lt,{children:"MATH101,PHY101"})]}),W.jsxs(Er,{children:[W.jsx(lt,{children:"antirequisites"}),W.jsx(lt,{children:"Comma-separated"}),W.jsx(lt,{children:"CSE102,CSE103"})]}),W.jsxs(Er,{children:[W.jsx(lt,{children:"schedule"}),W.jsx(lt,{children:"JSON string"}),W.jsx(lt,{children:'[{"day":"Monday","start_time":"09:00","end_time":"10:30"}]'})]}),W.jsxs(Er,{children:[W.jsx(lt,{children:"related_course_codes"}),W.jsx(lt,{children:"Comma-separated"}),W.jsx(lt,{children:"CSE102,CSE201"})]})]})]}),W.jsx(wr,{leftIcon:W.jsx(HI,{}),colorScheme:"blue",onClick:oO,size:"sm",children:"Download Template"})]})})]})}),W.jsx(He,{children:"Upload an Excel file containing multiple courses. Make sure to follow the template format."}),W.jsxs(ft,{p:4,bg:"blue.50",border:"1px",borderColor:"blue.200",borderRadius:"md",children:[W.jsxs(lr,{mb:2,children:[W.jsx(ma,{color:"blue.500"}),W.jsx(He,{fontWeight:"bold",color:"blue.700",children:"ℹ️ Normal Behavior When Uploading All Courses"})]}),W.jsxs(yr,{align:"start",spacing:2,children:[W.jsxs(He,{fontSize:"sm",color:"blue.600",children:[W.jsx("strong",{children:"✅ Expected:"})," If your Excel file contains courses that already exist in the database, this is normal! The system will:"]}),W.jsxs(qr,{spacing:1,ml:4,children:[W.jsxs(Vt,{fontSize:"sm",color:"blue.600",children:["• ",W.jsx("strong",{children:"Update existing courses"})," with any changes from your Excel file"]}),W.jsxs(Vt,{fontSize:"sm",color:"blue.600",children:["• ",W.jsx("strong",{children:"Add new courses"})," that don't exist in the database"]}),W.jsxs(Vt,{fontSize:"sm",color:"blue.600",children:["• ",W.jsx("strong",{children:"Show you a preview"})," of what will be updated vs added before proceeding"]})]}),W.jsxs(He,{fontSize:"sm",color:"blue.600",children:[W.jsx("strong",{children:"⚠️ Only fix conflicts if:"})," You see warnings about course name conflicts or duplicate rows in your Excel file."]})]})]}),W.jsxs(ft,{p:4,bg:"green.50",border:"1px",borderColor:"green.200",borderRadius:"md",children:[W.jsxs(lr,{mb:2,children:[W.jsx(He,{fontSize:"lg",children:"📚"}),W.jsx(He,{fontWeight:"bold",color:"green.700",children:"Course Offering Guidelines"})]}),W.jsxs(yr,{align:"start",spacing:4,children:[W.jsxs(ft,{children:[W.jsx(He,{fontSize:"sm",color:"green.600",fontWeight:"bold",mb:2,children:"🏛️ CROSS-DEPARTMENTAL COURSES (Same content, different departments)"}),W.jsxs(ft,{ml:4,children:[W.jsx(He,{fontSize:"sm",color:"green.600",fontWeight:"bold",mb:1,children:"✅ CREATE SEPARATE ENTRIES when:"}),W.jsxs(qr,{spacing:1,ml:4,children:[W.jsx(Vt,{fontSize:"sm",color:"green.600",children:"• Different departments teach with different focus/approach"}),W.jsx(Vt,{fontSize:"sm",color:"green.600",children:"• Prerequisites or requirements vary by department"}),W.jsx(Vt,{fontSize:"sm",color:"green.600",children:"• Different instructors or schedules"}),W.jsx(Vt,{fontSize:"sm",color:"green.600",children:"• Students must enroll in specific department version"})]})]})]}),W.jsxs(ft,{children:[W.jsx(He,{fontSize:"sm",color:"purple.600",fontWeight:"bold",mb:2,children:"🎓 MULTI-LEVEL COURSES (Same content, different academic levels)"}),W.jsxs(ft,{ml:4,children:[W.jsx(He,{fontSize:"sm",color:"purple.600",fontWeight:"bold",mb:1,children:"✅ CREATE SEPARATE ENTRIES when:"}),W.jsxs(qr,{spacing:1,ml:4,children:[W.jsx(Vt,{fontSize:"sm",color:"purple.600",children:"• Different academic levels (3xx undergraduate vs 5xx graduate)"}),W.jsx(Vt,{fontSize:"sm",color:"purple.600",children:"• More advanced prerequisites for higher level"}),W.jsx(Vt,{fontSize:"sm",color:"purple.600",children:"• Different content depth and rigor"}),W.jsx(Vt,{fontSize:"sm",color:"purple.600",children:"• Different target audiences (undergrad vs grad students)"})]})]})]}),W.jsxs(ft,{ml:4,children:[W.jsx(He,{fontSize:"sm",color:"orange.600",fontWeight:"bold",mb:1,children:"⚠️ AVOID DUPLICATES when:"}),W.jsxs(qr,{spacing:1,ml:4,children:[W.jsx(Vt,{fontSize:"sm",color:"orange.600",children:"• Exact same content, instructor, and requirements"}),W.jsx(Vt,{fontSize:"sm",color:"orange.600",children:"• Students can enroll in any version interchangeably"}),W.jsx(Vt,{fontSize:"sm",color:"orange.600",children:"• Only the course code differs (administrative reasons)"})]})]}),W.jsxs(ft,{p:3,bg:"green.100",borderRadius:"md",border:"1px",borderColor:"green.300",children:[W.jsx(He,{fontSize:"sm",fontWeight:"bold",color:"green.700",mb:2,children:"💡 Examples:"}),W.jsx(He,{fontSize:"sm",fontWeight:"bold",color:"green.700",mb:1,children:'Cross-Departmental: "Linear Algebra"'}),W.jsxs(qr,{spacing:1,ml:4,mb:3,children:[W.jsxs(Vt,{fontSize:"sm",color:"green.700",children:[W.jsx("strong",{children:"MTH270"})," (Math Dept) - Theoretical focus, proof-based"]}),W.jsxs(Vt,{fontSize:"sm",color:"green.700",children:[W.jsx("strong",{children:"CSE270"})," (CS Dept) - Application focus, programming-based"]}),W.jsxs(Vt,{fontSize:"sm",color:"green.700",children:[W.jsx("strong",{children:"EEE270"})," (EE Dept) - Signal processing applications"]})]}),W.jsx(He,{fontSize:"sm",fontWeight:"bold",color:"purple.700",mb:1,children:'Multi-Level: "Research Methodology"'}),W.jsxs(qr,{spacing:1,ml:4,children:[W.jsxs(Vt,{fontSize:"sm",color:"purple.700",children:[W.jsx("strong",{children:"SSH322"})," (Undergraduate) - Basic research methods"]}),W.jsxs(Vt,{fontSize:"sm",color:"purple.700",children:[W.jsx("strong",{children:"SSH522"})," (Graduate) - Advanced methods, statistical analysis"]})]}),W.jsx(He,{fontSize:"xs",color:"green.600",mt:2,children:"Each should be separate entries with level/department-specific details."})]})]})]}),W.jsxs(lr,{spacing:4,children:[W.jsxs(wr,{as:"label",htmlFor:"file-upload",colorScheme:"purple",size:"lg",cursor:"pointer",isLoading:i||t,children:["Choose Excel File",W.jsx(qd,{id:"file-upload",type:"file",accept:".xlsx,.xls",onChange:N,display:"none",title:"Upload Excel File","aria-label":"Upload Excel File"})]}),W.jsx(wr,{colorScheme:"red",size:"lg",onClick:q,isLoading:t,isDisabled:i,children:"Delete Uploaded Courses"})]}),i&&W.jsxs(lr,{spacing:2,justify:"center",children:[W.jsx(hl,{size:"sm"}),W.jsx(He,{children:"Verifying courses..."})]}),R.length>0&&W.jsx(ft,{textAlign:"center",my:4,children:W.jsxs(wr,{colorScheme:"red",size:"lg",onClick:()=>{const M=document.getElementById("error-details-section");M&&M.scrollIntoView({behavior:"smooth",block:"start"})},leftIcon:W.jsx(pa,{}),children:["📍 View ",R.length," Course Issues Below"]})}),t&&W.jsx(Qg,{value:e,size:"sm",colorScheme:"purple",hasStripe:!0,isAnimated:!0}),(f.success.length>0||f.errors.length>0)&&W.jsxs(yr,{align:"stretch",spacing:4,children:[f.success.length>0&&W.jsxs(ft,{children:[W.jsxs(hi,{size:"sm",mb:2,children:["Successfully Processed (",f.success.length,"):"]}),W.jsx(qr,{spacing:2,maxH:"300px",overflowY:"auto",p:2,border:"1px",borderColor:"gray.200",borderRadius:"md",children:f.success.map((M,j)=>W.jsxs(Vt,{children:[W.jsx(hu,{as:ma,color:"green.500"}),M]},j))})]}),f.errors.length>0&&W.jsxs(ft,{children:[W.jsxs(hi,{size:"sm",mb:2,color:"red.500",children:["Errors (",f.errors.length,"):"]}),W.jsx(qr,{spacing:2,maxH:"300px",overflowY:"auto",p:2,border:"1px",borderColor:"red.200",borderRadius:"md",children:f.errors.map((M,j)=>W.jsxs(Vt,{color:"red.500",children:[W.jsx(hu,{as:pa,color:"red.500"}),M]},j))})]})]}),R.length>0&&W.jsxs(ft,{id:"error-details-section",border:"2px",borderColor:"red.300",borderRadius:"lg",bg:"red.50",p:6,boxShadow:"xl",position:"relative",children:[W.jsx(ft,{position:"absolute",top:"-10px",left:"50%",transform:"translateX(-50%)",bg:"red.500",color:"white",px:4,py:1,borderRadius:"full",fontSize:"sm",fontWeight:"bold",children:"🚨 ISSUES FOUND - FIX REQUIRED"}),W.jsxs(yr,{align:"stretch",spacing:4,children:[W.jsxs(lr,{children:[W.jsx(pa,{color:"red.500",boxSize:6}),W.jsxs(yr,{align:"start",spacing:1,children:[W.jsxs(hi,{size:"md",color:"red.600",children:["⚠️ ",R.length," Course Issues Found"]}),W.jsx(He,{fontSize:"sm",color:"red.600",children:"Please review and fix these specific issues in your Excel file before proceeding."})]})]}),W.jsx(yr,{align:"stretch",spacing:3,children:R.slice(0,5).map((M,j)=>W.jsxs(ft,{p:4,border:"1px",borderColor:"red.200",borderRadius:"md",bg:"white",boxShadow:"sm",children:[W.jsxs(lr,{justify:"space-between",mb:2,children:[W.jsx(Ar,{colorScheme:M.type==="excel_duplicate"?"orange":"red",variant:"solid",fontSize:"xs",children:M.type==="excel_duplicate"?"EXCEL DUPLICATE":"NAMING CONFLICT"}),M.existingId&&W.jsxs(Ar,{colorScheme:"gray",variant:"outline",fontSize:"xs",children:["DB ID: ",M.existingId]})]}),W.jsxs(He,{fontWeight:"bold",mb:1,color:"red.700",children:["📚 Course: ",M.courseCode]}),W.jsxs(He,{fontSize:"sm",mb:2,color:"gray.700",children:["📖 Name: ",M.courseName]}),M.rowNumbers&&W.jsxs(He,{fontSize:"sm",color:"orange.600",mb:2,fontWeight:"bold",children:["📍 Excel Rows: ",M.rowNumbers.join(", ")]}),W.jsx(He,{fontSize:"sm",color:"gray.600",mb:3,children:M.message}),W.jsxs(ft,{p:3,bg:"blue.50",borderRadius:"md",border:"1px",borderColor:"blue.200",children:[W.jsx(He,{fontSize:"sm",color:"blue.700",fontWeight:"bold",mb:1,children:"🔧 Action Required:"}),W.jsx(He,{fontSize:"sm",color:"blue.600",children:M.type==="excel_duplicate"?`Go to Excel rows ${M.rowNumbers?.join(", ")} and remove the duplicate entries for course "${M.courseCode}". Keep only one row.`:`Review course "${M.courseCode}" - this name already exists with a different code. Verify if this is intentional or fix the naming conflict.`})]})]},j))}),R.length>5&&W.jsx(Gs,{allowToggle:!0,children:W.jsxs(qs,{children:[W.jsx("h2",{children:W.jsxs(Ws,{bg:"white",_hover:{bg:"gray.50"},children:[W.jsx(ft,{flex:"1",textAlign:"left",children:W.jsxs(He,{fontWeight:"bold",color:"red.600",children:["📋 View Remaining ",R.length-5," Issues"]})}),W.jsx(Hs,{})]})}),W.jsx(Ks,{pb:4,bg:"white",children:W.jsx(yr,{align:"stretch",spacing:3,children:R.slice(5).map((M,j)=>W.jsxs(ft,{p:4,border:"1px",borderColor:"red.200",borderRadius:"md",bg:"gray.50",children:[W.jsxs(lr,{justify:"space-between",mb:2,children:[W.jsx(Ar,{colorScheme:M.type==="excel_duplicate"?"orange":"red",variant:"solid",fontSize:"xs",children:M.type==="excel_duplicate"?"EXCEL DUPLICATE":"NAMING CONFLICT"}),M.existingId&&W.jsxs(Ar,{colorScheme:"gray",variant:"outline",fontSize:"xs",children:["DB ID: ",M.existingId]})]}),W.jsxs(He,{fontWeight:"bold",mb:1,color:"red.700",children:["📚 Course: ",M.courseCode]}),W.jsxs(He,{fontSize:"sm",mb:2,color:"gray.700",children:["📖 Name: ",M.courseName]}),M.rowNumbers&&W.jsxs(He,{fontSize:"sm",color:"orange.600",mb:2,fontWeight:"bold",children:["📍 Excel Rows: ",M.rowNumbers.join(", ")]}),W.jsx(He,{fontSize:"sm",color:"gray.600",mb:3,children:M.message}),W.jsxs(ft,{p:3,bg:"blue.50",borderRadius:"md",border:"1px",borderColor:"blue.200",children:[W.jsx(He,{fontSize:"sm",color:"blue.700",fontWeight:"bold",mb:1,children:"🔧 Action Required:"}),W.jsx(He,{fontSize:"sm",color:"blue.600",children:M.type==="excel_duplicate"?`Go to Excel rows ${M.rowNumbers?.join(", ")} and remove the duplicate entries for course "${M.courseCode}". Keep only one row.`:`Review course "${M.courseCode}" - this name already exists with a different code. Verify if this is intentional or fix the naming conflict.`})]})]},j+5))})})]})}),W.jsxs(ft,{p:4,bg:"yellow.50",border:"1px",borderColor:"yellow.200",borderRadius:"md",children:[W.jsx(He,{fontWeight:"bold",color:"yellow.800",mb:2,children:"📝 Next Steps:"}),W.jsxs(qr,{spacing:1,children:[W.jsx(Vt,{fontSize:"sm",color:"yellow.700",children:"1. Open your Excel file and fix the issues listed above"}),W.jsx(Vt,{fontSize:"sm",color:"yellow.700",children:"2. Save the Excel file after making corrections"}),W.jsx(Vt,{fontSize:"sm",color:"yellow.700",children:"3. Upload the corrected file again"})]}),W.jsx(lr,{justify:"center",mt:4,children:W.jsx(wr,{colorScheme:"blue",onClick:D,size:"sm",children:"🗑️ Clear Errors & Try Again"})})]})]})]}),I.length>0&&W.jsx(yr,{align:"stretch",spacing:4,children:W.jsxs(ft,{children:[W.jsxs(hi,{size:"sm",mb:2,color:"blue.500",children:["Change Log (",I.length," operations):"]}),W.jsx(He,{fontSize:"sm",color:"gray.600",mb:3,children:"Detailed record of all changes made during the upload process."}),W.jsx(Gs,{allowToggle:!0,children:W.jsxs(qs,{children:[W.jsx("h2",{children:W.jsxs(Ws,{children:[W.jsx(ft,{flex:"1",textAlign:"left",children:W.jsxs(lr,{children:[W.jsx(ma,{color:"blue.500"}),W.jsx(He,{fontWeight:"bold",children:"View Change Details"}),W.jsxs(Ar,{colorScheme:"green",ml:2,children:[I.filter(M=>M.type==="added").length," Added"]}),W.jsxs(Ar,{colorScheme:"blue",ml:1,children:[I.filter(M=>M.type==="updated").length," Updated"]}),W.jsxs(Ar,{colorScheme:"gray",ml:1,children:[I.filter(M=>M.type==="skipped").length," Skipped"]}),W.jsxs(Ar,{colorScheme:"red",ml:1,children:[I.filter(M=>M.type==="error").length," Errors"]})]})}),W.jsx(Hs,{})]})}),W.jsx(Ks,{pb:4,children:W.jsx(yr,{align:"stretch",spacing:3,maxH:"500px",overflowY:"auto",children:I.map((M,j)=>W.jsxs(ft,{p:4,border:"1px",borderColor:M.type==="added"?"green.200":M.type==="updated"?"blue.200":M.type==="error"?"red.200":"gray.200",borderRadius:"md",bg:M.type==="added"?"green.50":M.type==="updated"?"blue.50":M.type==="error"?"red.50":"gray.50",children:[W.jsx(lr,{justify:"space-between",mb:2,children:W.jsxs(lr,{children:[W.jsx(Ar,{colorScheme:M.type==="added"?"green":M.type==="updated"?"blue":M.type==="error"?"red":"gray",variant:"solid",children:M.type.toUpperCase()}),W.jsx(He,{fontSize:"xs",color:"gray.500",children:M.timestamp})]})}),W.jsxs(He,{fontWeight:"bold",mb:1,children:[M.courseCode," - ",M.courseName]}),W.jsxs(He,{fontSize:"sm",mb:2,color:"gray.700",children:[W.jsx("strong",{children:"Action:"})," ",M.action]}),W.jsxs(He,{fontSize:"sm",mb:3,color:"gray.600",children:[W.jsx("strong",{children:"Details:"})," ",M.details]}),M.errorMessage&&W.jsxs(He,{fontSize:"sm",color:"red.600",mb:2,children:[W.jsx("strong",{children:"Error:"})," ",M.errorMessage]}),(M.oldValues||M.newValues)&&W.jsx(Gs,{allowToggle:!0,size:"sm",children:W.jsxs(qs,{border:"none",children:[W.jsx("h2",{children:W.jsxs(Ws,{px:0,py:1,children:[W.jsx(ft,{flex:"1",textAlign:"left",children:W.jsx(He,{fontSize:"xs",color:"blue.600",fontWeight:"bold",children:"View Data Changes"})}),W.jsx(Hs,{})]})}),W.jsx(Ks,{px:0,py:2,children:W.jsxs(lr,{align:"start",spacing:4,children:[M.oldValues&&W.jsxs(ft,{flex:1,children:[W.jsx(He,{fontSize:"xs",fontWeight:"bold",color:"red.600",mb:1,children:"Old Values:"}),W.jsx(ft,{fontSize:"xs",bg:"red.50",p:2,borderRadius:"md",border:"1px",borderColor:"red.200",children:W.jsx("pre",{style:{whiteSpace:"pre-wrap",fontSize:"10px"},children:JSON.stringify(M.oldValues,null,2)})})]}),M.newValues&&W.jsxs(ft,{flex:1,children:[W.jsx(He,{fontSize:"xs",fontWeight:"bold",color:"green.600",mb:1,children:"New Values:"}),W.jsx(ft,{fontSize:"xs",bg:"green.50",p:2,borderRadius:"md",border:"1px",borderColor:"green.200",children:W.jsx("pre",{style:{whiteSpace:"pre-wrap",fontSize:"10px"},children:JSON.stringify(M.newValues,null,2)})})]})]})})]})})]},j))})})]})})]})}),W.jsxs(sf,{isOpen:o,onClose:Z,size:"xl",scrollBehavior:"inside",children:[W.jsx(Kg,{}),W.jsxs(of,{children:[W.jsx(Xg,{children:"Verify Courses"}),W.jsx(Yg,{}),W.jsx(Gg,{children:W.jsxs(yr,{spacing:4,align:"stretch",children:[W.jsxs(He,{children:["Your file contains ",W.jsx(Ar,{colorScheme:"blue",children:u.length})," courses:"]}),W.jsxs(pu,{justify:"space-between",children:[W.jsxs(Ar,{colorScheme:"green",p:2,borderRadius:"md",children:[W.jsx(hv,{mr:1})," ",p.length," new courses to add"]}),W.jsxs(Ar,{colorScheme:"orange",p:2,borderRadius:"md",children:[W.jsx(fv,{mr:1})," ",m.length," existing courses to update"]})]}),R.length===0?W.jsxs(ft,{p:3,bg:"green.50",border:"1px",borderColor:"green.200",borderRadius:"md",children:[W.jsxs(lr,{children:[W.jsx(ma,{color:"green.500"}),W.jsx(He,{color:"green.700",fontWeight:"bold",children:"✅ Ready to proceed! No conflicts detected."})]}),W.jsx(He,{fontSize:"sm",color:"green.600",mt:1,children:"Your Excel file looks good. Choose how you'd like to handle existing courses below."})]}):W.jsxs(ft,{p:3,bg:"orange.50",border:"1px",borderColor:"orange.200",borderRadius:"md",children:[W.jsxs(lr,{children:[W.jsx(pa,{color:"orange.500"}),W.jsx(He,{color:"orange.700",fontWeight:"bold",children:"⚠️ Please resolve conflicts before proceeding."})]}),W.jsx(He,{fontSize:"sm",color:"orange.600",mt:1,children:"Check the conflict details above and fix your Excel file."})]}),W.jsx(wg,{}),W.jsx(He,{fontWeight:"bold",children:"How would you like to proceed?"}),W.jsxs(ov,{isFitted:!0,variant:"enclosed",onChange:M=>{x(M===0?"update_all":M===1?"add_new_only":"custom")},children:[W.jsxs(av,{children:[W.jsx(Da,{children:"Update All"}),W.jsx(Da,{children:"Add New Only"}),W.jsx(Da,{children:"Custom Selection"})]}),W.jsxs(lv,{children:[W.jsx(Na,{children:W.jsxs(He,{children:["This will add ",p.length," new courses and update ",m.length," existing courses."]})}),W.jsx(Na,{children:W.jsxs(He,{children:["This will only add ",p.length," new courses. No existing courses will be updated."]})}),W.jsx(Na,{children:W.jsxs(yr,{align:"stretch",spacing:3,children:[W.jsxs(lr,{justify:"space-between",children:[W.jsx(He,{fontWeight:"bold",children:"Select courses to update:"}),W.jsxs(lr,{spacing:2,children:[W.jsx(wr,{size:"xs",onClick:()=>H(!0),children:"Select All"}),W.jsx(wr,{size:"xs",onClick:()=>H(!1),children:"Deselect All"})]})]}),m.length>0?W.jsx(ft,{maxH:"300px",overflowY:"auto",border:"1px",borderColor:"gray.200",borderRadius:"md",p:2,children:W.jsxs(_u,{size:"sm",variant:"simple",children:[W.jsx(Cm,{children:W.jsxs(Er,{children:[W.jsx(Ur,{children:"Code"}),W.jsx(Ur,{children:"Name"}),W.jsx(Ur,{children:"Credits"}),W.jsx(Ur,{children:"Department"}),W.jsx(Ur,{children:"Semester"}),W.jsx(Ur,{children:"Prerequisites"}),W.jsx(Ur,{children:"Related Courses"}),W.jsx(Ur,{children:"Status"}),W.jsx(Ur,{children:"Actions"})]})}),W.jsx(Tm,{children:I.map((M,j)=>W.jsxs(Er,{children:[W.jsx(lt,{children:M.courseCode}),W.jsx(lt,{children:M.courseName}),W.jsx(lt,{children:M.newValues?.credits||M.oldValues?.credits||"-"}),W.jsx(lt,{children:M.newValues?.dept_acronym||M.oldValues?.dept_acronym||"-"}),W.jsx(lt,{children:M.newValues?.semester||M.oldValues?.semester||"-"}),W.jsx(lt,{children:M.newValues?.prerequisites||M.oldValues?.prerequisites||"-"}),W.jsx(lt,{children:M.newValues?.related_course_codes||M.oldValues?.related_course_codes||"-"}),W.jsx(lt,{children:W.jsx(Ar,{colorScheme:M.type==="added"?"green":M.type==="updated"?"blue":M.type==="error"?"red":"yellow",children:M.type})}),W.jsx(lt,{children:W.jsx(wr,{size:"xs",onClick:()=>{L({title:"Log Details",description:`${M.courseCode}: ${M.details}`,status:M.type==="error"?"error":"info",duration:5e3,isClosable:!0})},children:"Details"})})]},j))})]})}):W.jsx(He,{children:"No existing courses found to update."}),W.jsxs(He,{children:["This will add ",p.length," new courses and update ",Object.entries(C).filter(([M,j])=>j).length," of ",m.length," existing courses."]})]})})]})]})]})}),W.jsx(qg,{children:W.jsxs(lr,{spacing:3,children:[W.jsx(wr,{onClick:Z,variant:"outline",children:"Cancel"}),W.jsx(wr,{colorScheme:"green",onClick:U,isDisabled:R.length>0||g==="custom"&&m.length>0&&Object.entries(C).filter(([M,j])=>j).length===0&&p.length===0,children:R.length>0?"Fix Duplicates First":"Proceed with Upload"})]})})]})]})]})})},qO=Object.freeze(Object.defineProperty({__proto__:null,default:aO},Symbol.toStringTag,{value:"Module"}));export{Gg as $,WT as A,ft as B,wO as C,Ar as D,xO as E,pu as F,pg as G,hi as H,qd as I,aI as J,yO as K,lr as L,aP as M,EI as N,MI as O,AI as P,ib as Q,rb as R,QR as S,He as T,sf as U,yr as V,Kg as W,of as X,Xg as Y,Yg as Z,Co as _,wr as a,Ii as a$,wg as a0,qg as a1,ov as a2,av as a3,Da as a4,lv as a5,Na as a6,_O as a7,zI as a8,dM as a9,HO as aA,rO as aB,vR as aC,wR as aD,hv as aE,PO as aF,jO as aG,AO as aH,MO as aI,RO as aJ,UO as aK,FO as aL,BO as aM,NO as aN,yR as aO,_R as aP,xR as aQ,eO as aR,LO as aS,WO as aT,IO as aU,EO as aV,$O as aW,WI as aX,VO as aY,zO as aZ,DO as a_,fM as aa,QT as ab,qR as ac,Xd as ad,ZR as ae,Qg as af,Ri as ag,on as ah,Tr as ai,qr as aj,Vt as ak,hu as al,il as am,BT as an,QA as ao,fg as ap,nM as aq,pM as ar,CO as as,UI as at,pO as au,OI as av,VT as aw,SO as ax,kO as ay,mO as az,uM as b,AR as b0,TR as b1,TO as b2,NR as b3,MR as b4,PR as b5,CR as b6,jR as b7,lM as b8,gg as b9,OO as ba,PI as bb,NE as bc,qO as bd,JT as c,eE as d,rs as e,hl as f,sb as g,nb as h,pP as i,W as j,XT as k,fP as l,cP as m,vO as n,bg as o,cI as p,uI as q,dI as r,rn as s,_u as t,ab as u,Cm as v,Er as w,Ur as x,Tm as y,lt as z}; //# sourceMappingURL=admin-components-DUStTukf.js.map
Close