var t="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},e=function(t){return t&&t.Math===Math&&t},r=e("object"==typeof globalThis&&globalThis)||e("object"==typeof window&&window)||e("object"==typeof self&&self)||e("object"==typeof t&&t)||e("object"==typeof t&&t)||function(){return this}()||Function("return this")(),n={},i=function(t){try{return!!t()}catch(t){return!0}},o=!i((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})),a=!i((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")})),s=a,u=Function.prototype.call,c=s?u.bind(u):function(){return u.apply(u,arguments)},f={},h={}.propertyIsEnumerable,p=Object.getOwnPropertyDescriptor,l=p&&!h.call({1:2},1);f.f=l?function(t){var e=p(this,t);return!!e&&e.enumerable}:h;var d,y,v=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},b=a,g=Function.prototype,m=g.call,w=b&&g.bind.bind(m,m),S=b?w:function(t){return function(){return m.apply(t,arguments)}},O=S,T=O({}.toString),P=O("".slice),j=function(t){return P(T(t),8,-1)},A=i,E=j,I=Object,x=S("".split),R=A((function(){return!I("z").propertyIsEnumerable(0)}))?function(t){return"String"===E(t)?x(t,""):I(t)}:I,U=function(t){return null==t},D=U,B=TypeError,C=function(t){if(D(t))throw new B("Can't call method on "+t);return t},_=R,F=C,L=function(t){return _(F(t))},k="object"==typeof document&&document.all,N=void 0===k&&void 0!==k?function(t){return"function"==typeof t||t===k}:function(t){return"function"==typeof t},M=N,q=function(t){return"object"==typeof t?null!==t:M(t)},H=r,G=N,z=function(t,e){return arguments.length<2?(r=H[t],G(r)?r:void 0):H[t]&&H[t][e];var r},$=S({}.isPrototypeOf),V=r.navigator,W=V&&V.userAgent,X=W?String(W):"",J=r,Y=X,K=J.process,Z=J.Deno,Q=K&&K.versions||Z&&Z.version,tt=Q&&Q.v8;tt&&(y=(d=tt.split("."))[0]>0&&d[0]<4?1:+(d[0]+d[1])),!y&&Y&&(!(d=Y.match(/Edge\/(\d+)/))||d[1]>=74)&&(d=Y.match(/Chrome\/(\d+)/))&&(y=+d[1]);var et=y,rt=et,nt=i,it=r.String,ot=!!Object.getOwnPropertySymbols&&!nt((function(){var t=Symbol("symbol detection");return!it(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&rt&&rt<41})),at=ot&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,st=z,ut=N,ct=$,ft=Object,ht=at?function(t){return"symbol"==typeof t}:function(t){var e=st("Symbol");return ut(e)&&ct(e.prototype,ft(t))},pt=String,lt=function(t){try{return pt(t)}catch(t){return"Object"}},dt=N,yt=lt,vt=TypeError,bt=function(t){if(dt(t))return t;throw new vt(yt(t)+" is not a function")},gt=bt,mt=U,wt=function(t,e){var r=t[e];return mt(r)?void 0:gt(r)},St=c,Ot=N,Tt=q,Pt=TypeError,jt={exports:{}},At=r,Et=Object.defineProperty,It=function(t,e){try{Et(At,t,{value:e,configurable:!0,writable:!0})}catch(r){At[t]=e}return e},xt=r,Rt=It,Ut="__core-js_shared__",Dt=jt.exports=xt[Ut]||Rt(Ut,{});(Dt.versions||(Dt.versions=[])).push({version:"3.38.1",mode:"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"});var Bt=jt.exports,Ct=Bt,_t=function(t,e){return Ct[t]||(Ct[t]=e||{})},Ft=C,Lt=Object,kt=function(t){return Lt(Ft(t))},Nt=kt,Mt=S({}.hasOwnProperty),qt=Object.hasOwn||function(t,e){return Mt(Nt(t),e)},Ht=S,Gt=0,zt=Math.random(),$t=Ht(1..toString),Vt=function(t){return"Symbol("+(void 0===t?"":t)+")_"+$t(++Gt+zt,36)},Wt=_t,Xt=qt,Jt=Vt,Yt=ot,Kt=at,Zt=r.Symbol,Qt=Wt("wks"),te=Kt?Zt.for||Zt:Zt&&Zt.withoutSetter||Jt,ee=function(t){return Xt(Qt,t)||(Qt[t]=Yt&&Xt(Zt,t)?Zt[t]:te("Symbol."+t)),Qt[t]},re=c,ne=q,ie=ht,oe=wt,ae=function(t,e){var r,n;if("string"===e&&Ot(r=t.toString)&&!Tt(n=St(r,t)))return n;if(Ot(r=t.valueOf)&&!Tt(n=St(r,t)))return n;if("string"!==e&&Ot(r=t.toString)&&!Tt(n=St(r,t)))return n;throw new Pt("Can't convert object to primitive value")},se=TypeError,ue=ee("toPrimitive"),ce=function(t,e){if(!ne(t)||ie(t))return t;var r,n=oe(t,ue);if(n){if(void 0===e&&(e="default"),r=re(n,t,e),!ne(r)||ie(r))return r;throw new se("Can't convert object to primitive value")}return void 0===e&&(e="number"),ae(t,e)},fe=ht,he=function(t){var e=ce(t,"string");return fe(e)?e:e+""},pe=q,le=r.document,de=pe(le)&&pe(le.createElement),ye=function(t){return de?le.createElement(t):{}},ve=ye,be=!o&&!i((function(){return 7!==Object.defineProperty(ve("div"),"a",{get:function(){return 7}}).a})),ge=o,me=c,we=f,Se=v,Oe=L,Te=he,Pe=qt,je=be,Ae=Object.getOwnPropertyDescriptor;n.f=ge?Ae:function(t,e){if(t=Oe(t),e=Te(e),je)try{return Ae(t,e)}catch(t){}if(Pe(t,e))return Se(!me(we.f,t,e),t[e])};var Ee={},Ie=o&&i((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype})),xe=q,Re=String,Ue=TypeError,De=function(t){if(xe(t))return t;throw new Ue(Re(t)+" is not an object")},Be=o,Ce=be,_e=Ie,Fe=De,Le=he,ke=TypeError,Ne=Object.defineProperty,Me=Object.getOwnPropertyDescriptor,qe="enumerable",He="configurable",Ge="writable";Ee.f=Be?_e?function(t,e,r){if(Fe(t),e=Le(e),Fe(r),"function"==typeof t&&"prototype"===e&&"value"in r&&Ge in r&&!r[Ge]){var n=Me(t,e);n&&n[Ge]&&(t[e]=r.value,r={configurable:He in r?r[He]:n[He],enumerable:qe in r?r[qe]:n[qe],writable:!1})}return Ne(t,e,r)}:Ne:function(t,e,r){if(Fe(t),e=Le(e),Fe(r),Ce)try{return Ne(t,e,r)}catch(t){}if("get"in r||"set"in r)throw new ke("Accessors not supported");return"value"in r&&(t[e]=r.value),t};var ze=Ee,$e=v,Ve=o?function(t,e,r){return ze.f(t,e,$e(1,r))}:function(t,e,r){return t[e]=r,t},We={exports:{}},Xe=o,Je=qt,Ye=Function.prototype,Ke=Xe&&Object.getOwnPropertyDescriptor,Ze=Je(Ye,"name"),Qe={EXISTS:Ze,PROPER:Ze&&"something"===function(){}.name,CONFIGURABLE:Ze&&(!Xe||Xe&&Ke(Ye,"name").configurable)},tr=N,er=Bt,rr=S(Function.toString);tr(er.inspectSource)||(er.inspectSource=function(t){return rr(t)});var nr,ir,or,ar=er.inspectSource,sr=N,ur=r.WeakMap,cr=sr(ur)&&/native code/.test(String(ur)),fr=Vt,hr=_t("keys"),pr=function(t){return hr[t]||(hr[t]=fr(t))},lr={},dr=cr,yr=r,vr=q,br=Ve,gr=qt,mr=Bt,wr=pr,Sr=lr,Or="Object already initialized",Tr=yr.TypeError,Pr=yr.WeakMap;if(dr||mr.state){var jr=mr.state||(mr.state=new Pr);jr.get=jr.get,jr.has=jr.has,jr.set=jr.set,nr=function(t,e){if(jr.has(t))throw new Tr(Or);return e.facade=t,jr.set(t,e),e},ir=function(t){return jr.get(t)||{}},or=function(t){return jr.has(t)}}else{var Ar=wr("state");Sr[Ar]=!0,nr=function(t,e){if(gr(t,Ar))throw new Tr(Or);return e.facade=t,br(t,Ar,e),e},ir=function(t){return gr(t,Ar)?t[Ar]:{}},or=function(t){return gr(t,Ar)}}var Er={set:nr,get:ir,has:or,enforce:function(t){return or(t)?ir(t):nr(t,{})},getterFor:function(t){return function(e){var r;if(!vr(e)||(r=ir(e)).type!==t)throw new Tr("Incompatible receiver, "+t+" required");return r}}},Ir=S,xr=i,Rr=N,Ur=qt,Dr=o,Br=Qe.CONFIGURABLE,Cr=ar,_r=Er.enforce,Fr=Er.get,Lr=String,kr=Object.defineProperty,Nr=Ir("".slice),Mr=Ir("".replace),qr=Ir([].join),Hr=Dr&&!xr((function(){return 8!==kr((function(){}),"length",{value:8}).length})),Gr=String(String).split("String"),zr=We.exports=function(t,e,r){"Symbol("===Nr(Lr(e),0,7)&&(e="["+Mr(Lr(e),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),r&&r.getter&&(e="get "+e),r&&r.setter&&(e="set "+e),(!Ur(t,"name")||Br&&t.name!==e)&&(Dr?kr(t,"name",{value:e,configurable:!0}):t.name=e),Hr&&r&&Ur(r,"arity")&&t.length!==r.arity&&kr(t,"length",{value:r.arity});try{r&&Ur(r,"constructor")&&r.constructor?Dr&&kr(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(t){}var n=_r(t);return Ur(n,"source")||(n.source=qr(Gr,"string"==typeof e?e:"")),t};Function.prototype.toString=zr((function(){return Rr(this)&&Fr(this).source||Cr(this)}),"toString");var $r=We.exports,Vr=N,Wr=Ee,Xr=$r,Jr=It,Yr=function(t,e,r,n){n||(n={});var o=n.enumerable,i=void 0!==n.name?n.name:e;if(Vr(r)&&Xr(r,i,n),n.global)o?t[e]=r:Jr(e,r);else{try{n.unsafe?t[e]&&(o=!0):delete t[e]}catch(t){}o?t[e]=r:Wr.f(t,e,{value:r,enumerable:!1,configurable:!n.nonConfigurable,writable:!n.nonWritable})}return t},Kr={},Zr=Math.ceil,Qr=Math.floor,tn=Math.trunc||function(t){var e=+t;return(e>0?Qr:Zr)(e)},en=function(t){var e=+t;return e!=e||0===e?0:tn(e)},rn=en,nn=Math.max,on=Math.min,an=en,sn=Math.min,un=function(t){var e=an(t);return e>0?sn(e,9007199254740991):0},cn=function(t){return un(t.length)},fn=L,hn=function(t,e){var r=rn(t);return r<0?nn(r+e,0):on(r,e)},pn=cn,ln=function(t){return function(e,r,n){var o=fn(e),i=pn(o);if(0===i)return!t&&-1;var a,s=hn(n,i);if(t&&r!=r){for(;i>s;)if((a=o[s++])!=a)return!0}else for(;i>s;s++)if((t||s in o)&&o[s]===r)return t||s||0;return!t&&-1}},dn={includes:ln(!0),indexOf:ln(!1)},yn=qt,vn=L,bn=dn.indexOf,gn=lr,mn=S([].push),wn=function(t,e){var r,n=vn(t),o=0,i=[];for(r in n)!yn(gn,r)&&yn(n,r)&&mn(i,r);for(;e.length>o;)yn(n,r=e[o++])&&(~bn(i,r)||mn(i,r));return i},Sn=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],On=wn,Tn=Sn.concat("length","prototype");Kr.f=Object.getOwnPropertyNames||function(t){return On(t,Tn)};var Pn={};Pn.f=Object.getOwnPropertySymbols;var jn=z,An=Kr,En=Pn,In=De,xn=S([].concat),Rn=jn("Reflect","ownKeys")||function(t){var e=An.f(In(t)),r=En.f;return r?xn(e,r(t)):e},Un=qt,Dn=Rn,Bn=n,Cn=Ee,_n=function(t,e,r){for(var n=Dn(e),o=Cn.f,i=Bn.f,a=0;ag;g++)if((s||g in y)&&(l=b(p=y[g],g,d),t))if(e)w[g]=l;else if(l)switch(t){case 3:return!0;case 5:return p;case 6:return g;case 2:qi(w,p)}else switch(t){case 4:return!1;case 7:qi(w,p)}return i?-1:n||o?o:w}},Gi={forEach:Hi(0),map:Hi(1),filter:Hi(2),some:Hi(3),every:Hi(4),find:Hi(5),findIndex:Hi(6),filterReject:Hi(7)},zi={},$i=wn,Vi=Sn,Wi=Object.keys||function(t){return $i(t,Vi)},Xi=o,Ji=Ie,Yi=Ee,Ki=De,Zi=L,Qi=Wi;zi.f=Xi&&!Ji?Object.defineProperties:function(t,e){Ki(t);for(var r,n=Zi(e),o=Qi(e),i=o.length,a=0;i>a;)Yi.f(t,r=o[a++],n[r]);return t};var to,eo=z("document","documentElement"),ro=De,no=zi,io=Sn,oo=lr,ao=eo,so=ye,uo="prototype",co="script",fo=pr("IE_PROTO"),ho=function(){},po=function(t){return"<"+co+">"+t+""},lo=function(t){t.write(po("")),t.close();var e=t.parentWindow.Object;return t=null,e},yo=function(){try{to=new ActiveXObject("htmlfile")}catch(t){}var t,e,r;yo="undefined"!=typeof document?document.domain&&to?lo(to):(e=so("iframe"),r="java"+co+":",e.style.display="none",ao.appendChild(e),e.src=String(r),(t=e.contentWindow.document).open(),t.write(po("document.F=Object")),t.close(),t.F):lo(to);for(var n=io.length;n--;)delete yo[uo][io[n]];return yo()};oo[fo]=!0;var vo=Object.create||function(t,e){var r;return null!==t?(ho[uo]=ro(t),r=new ho,ho[uo]=null,r[fo]=t):r=yo(),void 0===e?r:no.f(r,e)},bo=ee,go=vo,mo=Ee.f,wo=bo("unscopables"),So=Array.prototype;void 0===So[wo]&&mo(So,wo,{configurable:!0,value:go(null)});var Oo=function(t){So[wo][t]=!0},To=Zn,Po=Gi.find,jo=Oo,Ao="find",Eo=!0;Ao in[]&&Array(1)[Ao]((function(){Eo=!1})),To({target:"Array",proto:!0,forced:Eo},{find:function(t){return Po(this,t,arguments.length>1?arguments[1]:void 0)}}),jo(Ao);var Io=r,xo=S;xo(Io.Array.prototype.find);var Ro=!i((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype})),Uo=qt,Do=N,Bo=kt,Co=Ro,_o=pr("IE_PROTO"),Fo=Object,Lo=Fo.prototype,ko=Co?Fo.getPrototypeOf:function(t){var e=Bo(t);if(Uo(e,_o))return e[_o];var r=e.constructor;return Do(r)&&e instanceof r?r.prototype:e instanceof Fo?Lo:null},No=S,Mo=bt,qo=q,Ho=function(t){return qo(t)||null===t},Go=String,zo=TypeError,$o=function(t,e,r){try{return No(Mo(Object.getOwnPropertyDescriptor(t,e)[r]))}catch(t){}},Vo=q,Wo=C,Xo=function(t){if(Ho(t))return t;throw new zo("Can't set "+Go(t)+" as a prototype")},Jo=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,r={};try{(t=$o(Object.prototype,"__proto__","set"))(r,[]),e=r instanceof Array}catch(t){}return function(r,n){return Wo(r),Xo(n),Vo(r)?(e?t(r,n):r.__proto__=n,r):r}}():void 0),Yo=q,Ko=Ve,Zo=Error,Qo=S("".replace),ta=String(new Zo("zxcasd").stack),ea=/\n\s*at [^:]*:[^\n]*/,ra=ea.test(ta),na=v,ia=!i((function(){var t=new Error("a");return!("stack"in t)||(Object.defineProperty(t,"stack",na(1,7)),7!==t.stack)})),oa=Ve,aa=function(t,e){if(ra&&"string"==typeof t&&!Zo.prepareStackTrace)for(;e--;)t=Qo(t,ea,"");return t},sa=ia,ua=Error.captureStackTrace,ca={},fa=ca,ha=ee("iterator"),pa=Array.prototype,la=vi,da=wt,ya=U,va=ca,ba=ee("iterator"),ga=function(t){if(!ya(t))return da(t,ba)||da(t,"@@iterator")||va[la(t)]},ma=c,wa=bt,Sa=De,Oa=lt,Ta=ga,Pa=TypeError,ja=c,Aa=De,Ea=wt,Ia=oi,xa=c,Ra=De,Ua=lt,Da=function(t){return void 0!==t&&(fa.Array===t||pa[ha]===t)},Ba=cn,Ca=$,_a=function(t,e){var r=arguments.length<2?Ta(t):e;if(wa(r))return Sa(ma(r,t));throw new Pa(Oa(t)+" is not iterable")},Fa=ga,La=function(t,e,r){var n,o;Aa(t);try{if(!(n=Ea(t,"return"))){if("throw"===e)throw r;return r}n=ja(n,t)}catch(t){o=!0,n=t}if("throw"===e)throw r;if(o)throw n;return Aa(n),r},ka=TypeError,Na=function(t,e){this.stopped=t,this.result=e},Ma=Na.prototype,qa=function(t,e,r){var n,o,i,a,s,u,c,f=r&&r.that,h=!(!r||!r.AS_ENTRIES),p=!(!r||!r.IS_RECORD),l=!(!r||!r.IS_ITERATOR),d=!(!r||!r.INTERRUPTED),y=Ia(e,f),v=function(t){return n&&La(n,"normal",t),new Na(!0,t)},b=function(t){return h?(Ra(t),d?y(t[0],t[1],v):y(t[0],t[1])):d?y(t,v):y(t)};if(p)n=t.iterator;else if(l)n=t;else{if(!(o=Fa(t)))throw new ka(Ua(t)+" is not iterable");if(Da(o)){for(i=0,a=Ba(t);a>i;i++)if((s=b(t[i]))&&Ca(Ma,s))return s;return new Na(!1)}n=_a(t,o)}for(u=p?t.next:n.next;!(c=xa(u,n)).done;){try{s=b(c.value)}catch(t){La(n,"throw",t)}if("object"==typeof s&&s&&Ca(Ma,s))return s}return new Na(!1)},Ha=vi,Ga=String,za=function(t){if("Symbol"===Ha(t))throw new TypeError("Cannot convert a Symbol value to a string");return Ga(t)},$a=za,Va=Zn,Wa=$,Xa=ko,Ja=Jo,Ya=_n,Ka=vo,Za=Ve,Qa=v,ts=function(t,e){Yo(e)&&"cause"in e&&Ko(t,"cause",e.cause)},es=function(t,e,r,n){sa&&(ua?ua(t,e):oa(t,"stack",aa(r,n)))},rs=qa,ns=function(t,e){return void 0===t?arguments.length<2?"":e:$a(t)},is=ee("toStringTag"),os=Error,as=[].push,ss=function(t,e){var r,n=Wa(us,this);Ja?r=Ja(new os,n?Xa(this):us):(r=n?this:Ka(us),Za(r,is,"Error")),void 0!==e&&Za(r,"message",ns(e)),es(r,ss,r.stack,1),arguments.length>2&&ts(r,arguments[2]);var o=[];return rs(t,as,{that:o}),Za(r,"errors",o),r};Ja?Ja(ss,os):Ya(ss,os,{name:!0});var us=ss.prototype=Ka(os.prototype,{constructor:Qa(1,ss),message:Qa(1,""),name:Qa(1,"AggregateError")});Va({global:!0,constructor:!0,arity:2},{AggregateError:ss});var cs,fs,hs,ps=i,ls=N,ds=q,ys=ko,vs=Yr,bs=ee("iterator"),gs=!1;[].keys&&("next"in(hs=[].keys())?(fs=ys(ys(hs)))!==Object.prototype&&(cs=fs):gs=!0);var ms=!ds(cs)||ps((function(){var t={};return cs[bs].call(t)!==t}));ms&&(cs={}),ls(cs[bs])||vs(cs,bs,(function(){return this}));var ws={IteratorPrototype:cs,BUGGY_SAFARI_ITERATORS:gs},Ss=Ee.f,Os=qt,Ts=ee("toStringTag"),Ps=function(t,e,r){t&&!r&&(t=t.prototype),t&&!Os(t,Ts)&&Ss(t,Ts,{configurable:!0,value:e})},js=ws.IteratorPrototype,As=vo,Es=v,Is=Ps,xs=ca,Rs=function(){return this},Us=Zn,Ds=c,Bs=N,Cs=function(t,e,r,n){var o=e+" Iterator";return t.prototype=As(js,{next:Es(+!n,r)}),Is(t,o,!1),xs[o]=Rs,t},_s=ko,Fs=Jo,Ls=Ps,ks=Ve,Ns=Yr,Ms=ca,qs=Qe.PROPER,Hs=Qe.CONFIGURABLE,Gs=ws.IteratorPrototype,zs=ws.BUGGY_SAFARI_ITERATORS,$s=ee("iterator"),Vs="keys",Ws="values",Xs="entries",Js=function(){return this},Ys=function(t,e,r,n,o,i,a){Cs(r,e,n);var s,u,c,f=function(t){if(t===o&&y)return y;if(!zs&&t&&t in l)return l[t];switch(t){case Vs:case Ws:case Xs:return function(){return new r(this,t)}}return function(){return new r(this)}},h=e+" Iterator",p=!1,l=t.prototype,d=l[$s]||l["@@iterator"]||o&&l[o],y=!zs&&d||f(o),v="Array"===e&&l.entries||d;if(v&&(s=_s(v.call(new t)))!==Object.prototype&&s.next&&(_s(s)!==Gs&&(Fs?Fs(s,Gs):Bs(s[$s])||Ns(s,$s,Js)),Ls(s,h,!0)),qs&&o===Ws&&d&&d.name!==Ws&&(Hs?ks(l,"name",Ws):(p=!0,y=function(){return Ds(d,this)})),o)if(u={values:f(Ws),keys:i?y:f(Vs),entries:f(Xs)},a)for(c in u)(zs||p||!(c in l))&&Ns(l,c,u[c]);else Us({target:e,proto:!0,forced:zs||p},u);return l[$s]!==y&&Ns(l,$s,y,{name:o}),Ms[e]=y,u},Ks=function(t,e){return{value:t,done:e}},Zs=L,Qs=Oo,tu=ca,eu=Er,ru=Ee.f,nu=Ys,iu=Ks,ou=o,au="Array Iterator",su=eu.set,uu=eu.getterFor(au),cu=nu(Array,"Array",(function(t,e){su(this,{type:au,target:Zs(t),index:0,kind:e})}),(function(){var t=uu(this),e=t.target,r=t.index++;if(!e||r>=e.length)return t.target=null,iu(void 0,!0);switch(t.kind){case"keys":return iu(r,!1);case"values":return iu(e[r],!1)}return iu([r,e[r]],!1)}),"values"),fu=tu.Arguments=tu.Array;if(Qs("keys"),Qs("values"),Qs("entries"),ou&&"values"!==fu.name)try{ru(fu,"name",{value:"values"})}catch(t){}var hu=vi,pu=ci?{}.toString:function(){return"[object "+hu(this)+"]"};ci||Yr(Object.prototype,"toString",pu,{unsafe:!0});var lu,du,yu,vu,bu=r,gu=X,mu=j,wu=function(t){return gu.slice(0,t.length)===t},Su=wu("Bun/")?"BUN":wu("Cloudflare-Workers")?"CLOUDFLARE":wu("Deno/")?"DENO":wu("Node.js/")?"NODE":bu.Bun&&"string"==typeof Bun.version?"BUN":bu.Deno&&"object"==typeof Deno.version?"DENO":"process"===mu(bu.process)?"NODE":bu.window&&bu.document?"BROWSER":"REST",Ou="NODE"===Su,Tu=$r,Pu=Ee,ju=z,Au=function(t,e,r){return r.get&&Tu(r.get,e,{getter:!0}),r.set&&Tu(r.set,e,{setter:!0}),Pu.f(t,e,r)},Eu=o,Iu=ee("species"),xu=$,Ru=TypeError,Uu=xi,Du=lt,Bu=TypeError,Cu=De,_u=function(t){if(Uu(t))return t;throw new Bu(Du(t)+" is not a constructor")},Fu=U,Lu=ee("species"),ku=function(t,e){var r,n=Cu(t).constructor;return void 0===n||Fu(r=Cu(n)[Lu])?e:_u(r)},Nu=a,Mu=Function.prototype,qu=Mu.apply,Hu=Mu.call,Gu="object"==typeof Reflect&&Reflect.apply||(Nu?Hu.bind(qu):function(){return Hu.apply(qu,arguments)}),zu=S([].slice),$u=TypeError,Vu=/(?:ipad|iphone|ipod).*applewebkit/i.test(X),Wu=r,Xu=Gu,Ju=oi,Yu=N,Ku=qt,Zu=i,Qu=eo,tc=zu,ec=ye,rc=function(t,e){if(t=s?t?"":void 0:(n=gp(i,a))<55296||n>56319||a+1===s||(o=gp(i,a+1))<56320||o>57343?t?bp(i,a):n:t?mp(i,a,a+2):o-56320+(n-55296<<10)+65536}},Sp=(wp(!1),wp(!0)),Op=za,Tp=Er,Pp=Ys,jp=Ks,Ap="String Iterator",Ep=Tp.set,Ip=Tp.getterFor(Ap);Pp(String,"String",(function(t){Ep(this,{type:Ap,string:Op(t),index:0})}),(function(){var t,e=Ip(this),r=e.string,n=e.index;return n>=r.length?jp(void 0,!0):(t=Sp(r,n),e.index+=t.length,jp(t,!1))})),r.Promise;var xp=ye("span").classList,Rp=xp&&xp.constructor&&xp.constructor.prototype,Up=Rp===Object.prototype?void 0:Rp,Dp=r,Bp={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0},Cp=Up,_p=cu,Fp=Ve,Lp=Ps,kp=ee("iterator"),Np=_p.values,Mp=function(t,e){if(t){if(t[kp]!==Np)try{Fp(t,kp,Np)}catch(e){t[kp]=Np}if(Lp(t,e,!0),Bp[e])for(var r in _p)if(t[r]!==_p[r])try{Fp(t,r,_p[r])}catch(e){t[r]=_p[r]}}};for(var qp in Bp)Mp(Dp[qp]&&Dp[qp].prototype,qp);Mp(Cp,"DOMTokenList");var Hp="undefined"!=typeof globalThis&&globalThis||"undefined"!=typeof self&&self||"undefined"!=typeof global&&global||{},Gp="URLSearchParams"in Hp,zp="Symbol"in Hp&&"iterator"in Symbol,$p="FileReader"in Hp&&"Blob"in Hp&&function(){try{return new Blob,!0}catch(t){return!1}}(),Vp="FormData"in Hp,Wp="ArrayBuffer"in Hp;if(Wp)var Xp=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],Jp=ArrayBuffer.isView||function(t){return t&&Xp.indexOf(Object.prototype.toString.call(t))>-1};function Yp(t){if("string"!=typeof t&&(t=String(t)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(t)||""===t)throw new TypeError('Invalid character in header field name: "'+t+'"');return t.toLowerCase()}function Kp(t){return"string"!=typeof t&&(t=String(t)),t}function Zp(t){var e={next:function(){var e=t.shift();return{done:void 0===e,value:e}}};return zp&&(e[Symbol.iterator]=function(){return e}),e}function Qp(t){this.map={},t instanceof Qp?t.forEach((function(t,e){this.append(e,t)}),this):Array.isArray(t)?t.forEach((function(t){if(2!=t.length)throw new TypeError("Headers constructor: expected name/value pair to be length 2, found"+t.length);this.append(t[0],t[1])}),this):t&&Object.getOwnPropertyNames(t).forEach((function(e){this.append(e,t[e])}),this)}function tl(t){if(!t._noBody)return t.bodyUsed?Promise.reject(new TypeError("Already read")):void(t.bodyUsed=!0)}function el(t){return new Promise((function(e,r){t.onload=function(){e(t.result)},t.onerror=function(){r(t.error)}}))}function rl(t){var e=new FileReader,r=el(e);return e.readAsArrayBuffer(t),r}function nl(t){if(t.slice)return t.slice(0);var e=new Uint8Array(t.byteLength);return e.set(new Uint8Array(t)),e.buffer}function il(){return this.bodyUsed=!1,this._initBody=function(t){var e;this.bodyUsed=this.bodyUsed,this._bodyInit=t,t?"string"==typeof t?this._bodyText=t:$p&&Blob.prototype.isPrototypeOf(t)?this._bodyBlob=t:Vp&&FormData.prototype.isPrototypeOf(t)?this._bodyFormData=t:Gp&&URLSearchParams.prototype.isPrototypeOf(t)?this._bodyText=t.toString():Wp&&$p&&(e=t)&&DataView.prototype.isPrototypeOf(e)?(this._bodyArrayBuffer=nl(t.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):Wp&&(ArrayBuffer.prototype.isPrototypeOf(t)||Jp(t))?this._bodyArrayBuffer=nl(t):this._bodyText=t=Object.prototype.toString.call(t):(this._noBody=!0,this._bodyText=""),this.headers.get("content-type")||("string"==typeof t?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):Gp&&URLSearchParams.prototype.isPrototypeOf(t)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},$p&&(this.blob=function(){var t=tl(this);if(t)return t;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))}),this.arrayBuffer=function(){if(this._bodyArrayBuffer)return tl(this)||(ArrayBuffer.isView(this._bodyArrayBuffer)?Promise.resolve(this._bodyArrayBuffer.buffer.slice(this._bodyArrayBuffer.byteOffset,this._bodyArrayBuffer.byteOffset+this._bodyArrayBuffer.byteLength)):Promise.resolve(this._bodyArrayBuffer));if($p)return this.blob().then(rl);throw new Error("could not read as ArrayBuffer")},this.text=function(){var t=tl(this);if(t)return t;if(this._bodyBlob)return function(t){var e=new FileReader,r=el(e),n=/charset=([A-Za-z0-9_-]+)/.exec(t.type),o=n?n[1]:"utf-8";return e.readAsText(t,o),r}(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(function(t){for(var e=new Uint8Array(t),r=new Array(e.length),n=0;n-1?e:t}(e.method||this.method||"GET"),this.mode=e.mode||this.mode||null,this.signal=e.signal||this.signal||function(){if("AbortController"in Hp)return(new AbortController).signal}(),this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&r)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(r),!("GET"!==this.method&&"HEAD"!==this.method||"no-store"!==e.cache&&"no-cache"!==e.cache)){var n=/([?&])_=[^&]*/;n.test(this.url)?this.url=this.url.replace(n,"$1_="+(new Date).getTime()):this.url+=(/\?/.test(this.url)?"&":"?")+"_="+(new Date).getTime()}}function sl(t){var e=new FormData;return t.trim().split("&").forEach((function(t){if(t){var r=t.split("="),n=r.shift().replace(/\+/g," "),o=r.join("=").replace(/\+/g," ");e.append(decodeURIComponent(n),decodeURIComponent(o))}})),e}function ul(t,e){if(!(this instanceof ul))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');if(e||(e={}),this.type="default",this.status=void 0===e.status?200:e.status,this.status<200||this.status>599)throw new RangeError("Failed to construct 'Response': The status provided (0) is outside the range [200, 599].");this.ok=this.status>=200&&this.status<300,this.statusText=void 0===e.statusText?"":""+e.statusText,this.headers=new Qp(e.headers),this.url=e.url||"",this._initBody(t)}al.prototype.clone=function(){return new al(this,{body:this._bodyInit})},il.call(al.prototype),il.call(ul.prototype),ul.prototype.clone=function(){return new ul(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new Qp(this.headers),url:this.url})},ul.error=function(){var t=new ul(null,{status:200,statusText:""});return t.ok=!1,t.status=0,t.type="error",t};var cl=[301,302,303,307,308];ul.redirect=function(t,e){if(-1===cl.indexOf(e))throw new RangeError("Invalid status code");return new ul(null,{status:e,headers:{location:t}})};var fl=Hp.DOMException;try{new fl}catch(t){(fl=function(t,e){this.message=t,this.name=e;var r=Error(t);this.stack=r.stack}).prototype=Object.create(Error.prototype),fl.prototype.constructor=fl}function hl(t,e){return new Promise((function(r,n){var o=new al(t,e);if(o.signal&&o.signal.aborted)return n(new fl("Aborted","AbortError"));var i=new XMLHttpRequest;function a(){i.abort()}if(i.onload=function(){var t,e,n={statusText:i.statusText,headers:(t=i.getAllResponseHeaders()||"",e=new Qp,t.replace(/\r?\n[\t ]+/g," ").split("\r").map((function(t){return 0===t.indexOf("\n")?t.substr(1,t.length):t})).forEach((function(t){var r=t.split(":"),n=r.shift().trim();if(n){var o=r.join(":").trim();try{e.append(n,o)}catch(t){console.warn("Response "+t.message)}}})),e)};0===o.url.indexOf("file://")&&(i.status<200||i.status>599)?n.status=200:n.status=i.status,n.url="responseURL"in i?i.responseURL:n.headers.get("X-Request-URL");var a="response"in i?i.response:i.responseText;setTimeout((function(){r(new ul(a,n))}),0)},i.onerror=function(){setTimeout((function(){n(new TypeError("Network request failed"))}),0)},i.ontimeout=function(){setTimeout((function(){n(new TypeError("Network request timed out"))}),0)},i.onabort=function(){setTimeout((function(){n(new fl("Aborted","AbortError"))}),0)},i.open(o.method,function(t){try{return""===t&&Hp.location.href?Hp.location.href:t}catch(e){return t}}(o.url),!0),"include"===o.credentials?i.withCredentials=!0:"omit"===o.credentials&&(i.withCredentials=!1),"responseType"in i&&($p?i.responseType="blob":Wp&&(i.responseType="arraybuffer")),e&&"object"==typeof e.headers&&!(e.headers instanceof Qp||Hp.Headers&&e.headers instanceof Hp.Headers)){var s=[];Object.getOwnPropertyNames(e.headers).forEach((function(t){s.push(Yp(t)),i.setRequestHeader(t,Kp(e.headers[t]))})),o.headers.forEach((function(t,e){-1===s.indexOf(e)&&i.setRequestHeader(e,t)}))}else o.headers.forEach((function(t,e){i.setRequestHeader(e,t)}));o.signal&&(o.signal.addEventListener("abort",a),i.onreadystatechange=function(){4===i.readyState&&o.signal.removeEventListener("abort",a)}),i.send(void 0===o._bodyInit?null:o._bodyInit)}))}hl.polyfill=!0,Hp.fetch||(Hp.fetch=hl,Hp.Headers=Qp,Hp.Request=al,Hp.Response=ul);var pl=function(){function t(){this.empty=!0,this.x=0,this.y=0,this.width=0,this.height=0}return t.prototype.reset=function(){this.empty=!0,this.x=0,this.y=0,this.width=0,this.height=0},t.prototype.set=function(t,e,r,n){void 0===r&&(r=0),void 0===n&&(n=0),this.empty=!1,this.x=t,this.y=e,this.width=r,this.height=n},t.prototype.union=function(t,e,r,n){void 0===r&&(r=0),void 0===n&&(n=0),this.empty?(this.empty=!1,this.x=t,this.y=e,this.width=r,this.height=n):(tthis.x+this.width&&(this.width=t+r-this.x),e+n>this.y+this.height&&(this.height=e+n-this.y))},t}(),ll=function(){function t(t){this.dirtyArea=new pl,this.canvas=t,this.context=t.getContext("2d")}return t.prototype.draw=function(t){this.canvas&&this.context&&(this.dirtyArea.empty||(this.context.clearRect(this.dirtyArea.x,this.dirtyArea.y,this.dirtyArea.width,this.dirtyArea.height),this.dirtyArea.reset()),t&&(this.canvas.width==t.width&&this.canvas.height==t.height||(this.canvas.width=t.width,this.canvas.height=t.height),this.drawSubtitleData(t,this.dirtyArea)))},t.prototype.drawSubtitleData=function(t,e){for(var r=0,n=t.compositionData;r0&&o[o.length-1])||6!==s[0]&&2!==s[0])){a=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]=this.length},enumerable:!1,configurable:!0}),t.prototype.readByte=function(){return this.array[this.$position++]},t.prototype.readBytes=function(t){var e=this.array.slice(this.$position,this.$position+t);return this.$position+=t,e},t}(),gl=function(){function t(t){t instanceof Uint8Array?this.baseReader=new bl(t):this.baseReader=t}return Object.defineProperty(t.prototype,"position",{get:function(){return this.baseReader.position},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"length",{get:function(){return this.baseReader.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"eof",{get:function(){return this.baseReader.eof},enumerable:!1,configurable:!0}),t.prototype.readUInt8=function(){return this.baseReader.readByte()},t.prototype.readUInt16=function(){return(this.baseReader.readByte()<<8)+this.baseReader.readByte()},t.prototype.readUInt24=function(){return(this.baseReader.readByte()<<16)+(this.baseReader.readByte()<<8)+this.baseReader.readByte()},t.prototype.readUInt32=function(){return(this.baseReader.readByte()<<24)+(this.baseReader.readByte()<<16)+(this.baseReader.readByte()<<8)+this.baseReader.readByte()},t.prototype.readBytes=function(t){return this.baseReader.readBytes(t)},t}();!function(t){t[t.paletteDefinition=20]="paletteDefinition",t[t.objectDefinition=21]="objectDefinition",t[t.presentationComposition=22]="presentationComposition",t[t.windowDefinition=23]="windowDefinition",t[t.end=128]="end"}(vl||(vl={}));var ml=function(){function t(){this.id=0,this.windowId=0,this.croppedFlag=0,this.horizontalPosition=0,this.verticalPosition=0,this.croppingHorizontalPosition=0,this.croppingVerticalPosition=0,this.croppingWidth=0,this.croppingHeight=0}return Object.defineProperty(t.prototype,"hasCropping",{get:function(){return!!(128&this.croppedFlag)},enumerable:!1,configurable:!0}),t}(),wl=function(){function t(){this.width=0,this.height=0,this.frameRate=0,this.compositionNumber=0,this.compositionState=0,this.paletteUpdateFlag=0,this.paletteId=0,this.compositionObjects=[]}return Object.defineProperty(t.prototype,"segmentType",{get:function(){return vl.presentationComposition},enumerable:!1,configurable:!0}),t.prototype.read=function(t,e){this.width=t.readUInt16(),this.height=t.readUInt16(),this.frameRate=t.readUInt8(),this.compositionNumber=t.readUInt16(),this.compositionState=t.readUInt8(),this.paletteUpdateFlag=t.readUInt8(),this.paletteId=t.readUInt8();var r=t.readUInt8();this.compositionObjects=[];for(var n=0;nr?r:t},t}(),Ol=function(){function t(){this.id=0,this.versionNumber=0,this.lastInSequenceFlag=0,this.width=0,this.height=0,this.dataLength=0}return Object.defineProperty(t.prototype,"isFirstInSequence",{get:function(){return!!(128&this.lastInSequenceFlag)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isLastInSequence",{get:function(){return!!(64&this.lastInSequenceFlag)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"segmentType",{get:function(){return vl.objectDefinition},enumerable:!1,configurable:!0}),t.prototype.read=function(t,e){this.id=t.readUInt16(),this.versionNumber=t.readUInt8(),this.lastInSequenceFlag=t.readUInt8(),this.isFirstInSequence?(this.dataLength=t.readUInt24(),this.width=t.readUInt16(),this.height=t.readUInt16(),this.data=t.readBytes(e-11)):this.data=t.readBytes(e-4)},t}(),Tl=function(){this.id=0,this.horizontalPosition=0,this.verticalPosition=0,this.width=0,this.height=0},Pl=function(){function t(){this.windows=[]}return Object.defineProperty(t.prototype,"segmentType",{get:function(){return vl.windowDefinition},enumerable:!1,configurable:!0}),t.prototype.read=function(t,e){var r=t.readUInt8();this.windows=[];for(var n=0;n=this.length},enumerable:!1,configurable:!0}),t.prototype.readByte=function(){for(;this.subReaders[this.subReaderIndex].position>=this.subReaders[this.subReaderIndex].length;)this.subReaderIndex++;return this.$position++,this.subReaders[this.subReaderIndex].readByte()},t.prototype.readBytes=function(t){for(var e=new Uint8Array(t),r=0;rthis.reader.length&&!this.$eof?[4,this.stream.read()]:[3,2];case 1:return e=o.sent(),r=e.value,n=e.done,r&&this.reader.push(r),n&&(this.$eof=!0),[3,0];case 2:return[2,this.reader.position+t<=this.reader.length]}}))}))},t}(),Il=function(t,e,r){this.width=t,this.height=e,this.compositionData=r},xl=function(t,e,r){this.compositionObject=t,this.window=e,this.pixelData=r},Rl=function(){function t(){}return t.decode=function(t,e,r){t instanceof Uint8Array&&(t=new bl(t));for(var n=0;t.position0&&rr);o++)n++;return n},t}(),Dl=function(){function t(){this.displaySets=[],this.updateTimestamps=[]}return t.prototype.loadFromUrl=function(t,e){return dl(this,void 0,void 0,(function(){var r,n,o,i,a;return yl(this,(function(s){switch(s.label){case 0:return[4,fetch(t)];case 1:if(!(r=s.sent()).ok)throw new Error("HTTP error: ".concat(r.status));return(n=null===(a=r.body)||void 0===a?void 0:a.getReader())?(o=new El(n),[3,4]):[3,2];case 2:return[4,r.arrayBuffer()];case 3:i=s.sent(),o=new bl(new Uint8Array(i)),s.label=4;case 4:return[4,this.loadFromReader(o,e)];case 5:return s.sent(),[2]}}))}))},t.prototype.loadFromBuffer=function(t,e){return dl(this,void 0,void 0,(function(){return yl(this,(function(r){switch(r.label){case 0:return[4,this.loadFromReader(new bl(new Uint8Array(t)),e)];case 1:return r.sent(),[2]}}))}))},t.prototype.loadFromReader=function(t,e){return dl(this,void 0,void 0,(function(){var r,n,o,i;return yl(this,(function(a){switch(a.label){case 0:this.displaySets=[],this.updateTimestamps=[],this.cachedSubtitleData=void 0,r=performance.now(),n=new gl(t),a.label=1;case 1:return t.eof?[3,3]:[4,(o=new jl).read(n,!0)];case 2:return a.sent(),this.displaySets.push(o),this.updateTimestamps.push(o.presentationTimestamp),(null==e?void 0:e.onProgress)&&(i=performance.now())>r+1e3&&(r=i,e.onProgress()),[3,1];case 3:return(null==e?void 0:e.onProgress)&&e.onProgress(),[2]}}))}))},t.prototype.cacheSubtitleAtIndex=function(t){var e=this.getSubtitleAtIndex(t);this.cachedSubtitleData={index:t,data:e}},t.prototype.getSubtitleAtTimestamp=function(t){var e=Ul.getIndexFromTimestamps(t,this.updateTimestamps);return this.getSubtitleAtIndex(e)},t.prototype.getSubtitleAtIndex=function(t){var e;if(this.cachedSubtitleData&&this.cachedSubtitleData.index===t)return this.cachedSubtitleData.data;if(!(t<0||t>=this.displaySets.length)){var r=this.displaySets[t];if(r.presentationComposition){for(var n=[],o=[],i=[],a=t;a>=0;){var s=this.displaySets[a];n.unshift.apply(n,s.objectDefinitions),o.unshift.apply(o,s.paletteDefinitions);for(var u=0,c=s.windowDefinitions;u