"use strict";function _array_like_to_array(arr,len){if(len==null||len>arr.length)len=arr.length;for(var i=0,arr2=new Array(len);i=0)continue;if(!Object.prototype.propertyIsEnumerable.call(source,key))continue;target[key]=source[key]}return target}target=_object_without_properties_loose(source,excluded);if(Object.getOwnPropertySymbols){sourceKeys=Object.getOwnPropertySymbols(source);for(i=0;i=0)continue;if(!Object.prototype.propertyIsEnumerable.call(source,key))continue;target[key]=source[key]}}return target}function _object_without_properties_loose(source,excluded){if(source==null)return{};var target={},sourceKeys=Object.getOwnPropertyNames(source),key,i;for(i=0;i=0)continue;if(!Object.prototype.propertyIsEnumerable.call(source,key))continue;target[key]=source[key]}return target}function _overload_yield(value,kind){this.v=value;this.k=kind}function _possible_constructor_return(self1,call){if(call&&(_type_of(call)==="object"||typeof call==="function")){return call}return _assert_this_initialized(self1)}function _set_prototype_of(o,p){_set_prototype_of=Object.setPrototypeOf||function setPrototypeOf(o,p){o.__proto__=p;return o};return _set_prototype_of(o,p)}function _sliced_to_array(arr,i){return _array_with_holes(arr)||_iterable_to_array_limit(arr,i)||_unsupported_iterable_to_array(arr,i)||_non_iterable_rest()}function _super_prop_base(object,property){while(!Object.prototype.hasOwnProperty.call(object,property)){object=_get_prototype_of(object);if(object===null)break}return object}function _to_array(arr){return _array_with_holes(arr)||_iterable_to_array(arr)||_unsupported_iterable_to_array(arr)||_non_iterable_rest()}function _to_consumable_array(arr){return _array_without_holes(arr)||_iterable_to_array(arr)||_unsupported_iterable_to_array(arr)||_non_iterable_spread()}function _to_primitive(input,hint){if(_type_of(input)!=="object"||input===null)return input;var prim=input[Symbol.toPrimitive];if(prim!==undefined){var res=prim.call(input,hint||"default");if(_type_of(res)!=="object")return res;throw new TypeError("@@toPrimitive must return a primitive value.")}return(hint==="string"?String:Number)(input)}function _to_property_key(arg){var key=_to_primitive(arg,"string");return _type_of(key)==="symbol"?key:String(key)}function _type_of(obj){"@swc/helpers - typeof";return obj&&typeof Symbol!=="undefined"&&obj.constructor===Symbol?"symbol":typeof obj}function _unsupported_iterable_to_array(o,minLen){if(!o)return;if(typeof o==="string")return _array_like_to_array(o,minLen);var n=Object.prototype.toString.call(o).slice(8,-1);if(n==="Object"&&o.constructor)n=o.constructor.name;if(n==="Map"||n==="Set")return Array.from(n);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _array_like_to_array(o,minLen)}function _wrap_async_generator(fn1){return function(){return new _async_generator(fn1.apply(this,arguments))}}function _wrap_native_super(Class){var _cache=typeof Map==="function"?new Map:undefined;_wrap_native_super=function wrapNativeSuper(Class){if(Class===null||!_is_native_function(Class))return Class;if(typeof Class!=="function"){throw new TypeError("Super expression must either be null or a function")}if(typeof _cache!=="undefined"){if(_cache.has(Class))return _cache.get(Class);_cache.set(Class,Wrapper)}function Wrapper(){return _construct(Class,arguments,_get_prototype_of(this).constructor)}Wrapper.prototype=Object.create(Class.prototype,{constructor:{value:Wrapper,enumerable:false,writable:true,configurable:true}});return _set_prototype_of(Wrapper,Class)};return _wrap_native_super(Class)}function _is_native_reflect_construct(){try{var result=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(_){}return(_is_native_reflect_construct=function(){return!!result})()}function _ts_generator(thisArg,body){var f,y,t,_={label:0,sent:function(){if(t[0]&1)throw t[1];return t[1]},trys:[],ops:[]},g=Object.create((typeof Iterator==="function"?Iterator:Object).prototype),d6=Object.defineProperty;return d6(g,"next",{value:verb(0)}),d6(g,"throw",{value:verb(1)}),d6(g,"return",{value:verb(2)}),typeof Symbol==="function"&&d6(g,Symbol.iterator,{value:function(){return this}}),g;function verb(n){return function(v){return step([n,v])}}function step(op1){if(f)throw new TypeError("Generator is already executing.");while(g&&(g=0,op1[0]&&(_=0)),_)try{if(f=1,y&&(t=op1[0]&2?y["return"]:op1[0]?y["throw"]||((t=y["return"])&&t.call(y),0):y.next)&&!(t=t.call(y,op1[1])).done)return t;if(y=0,t)op1=[op1[0]&2,t.value];switch(op1[0]){case 0:case 1:t=op1;break;case 4:_.label++;return{value:op1[1],done:false};case 5:_.label++;y=op1[1];op1=[0];continue;case 7:op1=_.ops.pop();_.trys.pop();continue;default:if(!(t=_.trys,t=t.length>0&&t[t.length-1])&&(op1[0]===6||op1[0]===2)){_=0;continue}if(op1[0]===3&&(!t||op1[1]>t[0]&&op1[1]=o.length)o=void 0;return{value:o&&o[i++],done:!o}}};throw new TypeError(s?"Object is not iterable.":"Symbol.iterator is not defined.")}var sKe=Object.create;var Nx=Object.defineProperty;var uKe=Object.getOwnPropertyDescriptor;var lKe=Object.getOwnPropertyNames;var cKe=Object.getPrototypeOf,pKe=Object.prototype.hasOwnProperty;var dKe=function(e,t,a){return t in e?Nx(e,t,{enumerable:!0,configurable:!0,writable:!0,value:a}):e[t]=a};var T=function(e,t){return function(){return t||e((t={exports:{}}).exports,t),t.exports}},Au=function(e,t){for(var a in t)Nx(e,a,{get:t[a],enumerable:!0})},HJ=function(e,t,a,r){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;if(t&&(typeof t==="undefined"?"undefined":_type_of(t))=="object"||typeof t=="function")try{var _loop=function(){var i=_step.value;!pKe.call(e,i)&&i!==a&&Nx(e,i,{get:function(){return t[i]},enumerable:!(r=uKe(t,i))||r.enumerable})};for(var _iterator=lKe(t)[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true)_loop()}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return e};var va=function(e,t,a){return a=e!=null?sKe(cKe(e)):{},HJ(t||!e||!e.__esModule?Nx(a,"default",{value:e,enumerable:!0}):a,e)},mKe=function(e){return HJ(Nx({},"__esModule",{value:!0}),e)};var S=function(e,t,a){return dKe(e,(typeof t==="undefined"?"undefined":_type_of(t))!="symbol"?t+"":t,a),a},TT=function(e,t,a){if(!t.has(e))throw TypeError("Cannot "+a)};var he=function(e,t,a){return TT(e,t,"read from private field"),a?a.call(e):t.get(e)},fa=function(e,t,a){if(t.has(e))throw TypeError("Cannot add the same private member more than once");_instanceof(t,WeakSet)?t.add(e):t.set(e,a)},ea=function(e,t,a,r){return TT(e,t,"write to private field"),r?r.call(e,a):t.set(e,a),a};var Ba=function(e,t,a){return TT(e,t,"access private method"),a};var VJ=T(function(Ox){var WJ=function WJ(e){for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",a=[],r=0;r>2,p=(i&3)<<4|o>>4,l=(o&15)<<2|u>>6,m=u&63;s||(m=64,n||(l=64)),a.push(t[c],t[p],t[l],t[m])}return a.join("")};(function(e){(function(t){typeof define=="function"&&define.amd?define(["exports"],t):(typeof Ox==="undefined"?"undefined":_type_of(Ox))=="object"&&typeof Ox.nodeName!="string"?t(Ox):t(e)})(function(t){"use strict";var a=e.BlobBuilder||e.WebKitBlobBuilder||e.MSBlobBuilder||e.MozBlobBuilder,r=e.URL||e.webkitURL||function(C,E){return E=document.createElement("a"),E.href=C,E},i=e.Blob,n=r.createObjectURL,o=r.revokeObjectURL,s=e.Symbol&&e.Symbol.toStringTag,u=!1,c=!1,p=a&&a.prototype.append&&a.prototype.getBlob;try{u=new Blob(["\xe4"]).size===2,c=new Blob([new Uint8Array([1,2])]).size===2}catch(C){}function l(C){return C.map(function(E){if(_instanceof(E.buffer,ArrayBuffer)){var P=E.buffer;if(E.byteLength!==P.byteLength){var B=new Uint8Array(E.byteLength);B.set(new Uint8Array(P,E.byteOffset,E.byteLength)),P=B.buffer}return P}return E})}function m(C,E){E=E||{};var P=new a;return l(C).forEach(function(B){P.append(B)}),E.type?P.getBlob(E.type):P.getBlob()}function f(C,E){return new i(l(C),E||{})}e.Blob&&(m.prototype=e.Blob.prototype,f.prototype=e.Blob.prototype);function g(C){for(var E=0,P=C.length,B=e.Uint8Array||Array,M=0,R=Math.max(32,P+(P>>1)+7),N=new B(R>>3<<3);E=55296&&Q<=56319){if(E=55296&&Q<=56319)continue}if(M+4>N.length){R+=8,R*=1+E/C.length*2,R=R>>3<<3;var G=new Uint8Array(R);G.set(N),N=G}if(Q&0xffffff80)if(!(Q&0xfffff800))N[M++]=Q>>6&31|192;else if(!(Q&0xffff0000))N[M++]=Q>>12&15|224,N[M++]=Q>>6&63|128;else if(!(Q&0xffe00000))N[M++]=Q>>18&7|240,N[M++]=Q>>12&63|128,N[M++]=Q>>6&63|128;else continue;else{N[M++]=Q;continue}N[M++]=Q&63|128}return N.slice(0,M)}function h(C){for(var E=C.length,P=[],B=0;B239?4:M>223?3:M>191?2:1;if(B+N<=E){var Q,O,G,$;switch(N){case 1:M<128&&(R=M);break;case 2:Q=C[B+1],(Q&192)===128&&($=(M&31)<<6|Q&63,$>127&&(R=$));break;case 3:Q=C[B+1],O=C[B+2],(Q&192)===128&&(O&192)===128&&($=(M&15)<<12|(Q&63)<<6|O&63,$>2047&&($<55296||$>57343)&&(R=$));break;case 4:Q=C[B+1],O=C[B+2],G=C[B+3],(Q&192)===128&&(O&192)===128&&(G&192)===128&&($=(M&15)<<18|(Q&63)<<12|(O&63)<<6|G&63,$>65535&&$<1114112&&(R=$))}}R===null?(R=65533,N=1):R>65535&&(R-=65536,P.push(R>>>10&1023|55296),R=56320|R&1023),P.push(R),B+=N}for(var K=P.length,U="",j=0;j=P.size&&B.close()})}})}}catch(C){try{new ReadableStream({}),w=function w(P){var B=0;return new ReadableStream({pull:function pull(M){var R=P.slice(B,B+524288);return R.arrayBuffer().then(function(N){B+=N.byteLength;var Q=new Uint8Array(N);M.enqueue(Q),B==P.size&&M.close()})}})}}catch(E){try{new Response("").body.getReader().read(),w=function w(){return new Response(this).body}}catch(P){w=function w(){throw new Error("Include https://github.com/MattiasBuelens/web-streams-polyfill")}}}}function k(C){return new Promise(function(E,P){C.onload=C.onerror=function(B){C.onload=C.onerror=null,B.type==="load"?E(C.result||C):P(new Error("Failed to read the blob/file"))}})}b.arrayBuffer||(b.arrayBuffer=function(){var E=new t.FileReader;return E.readAsArrayBuffer(this),k(E)}),b.text||(b.text=function(){var E=new t.FileReader;return E.readAsText(this),k(E)}),b.stream||(b.stream=w)})})(typeof self!="undefined"&&self||typeof window!="undefined"&&window||typeof global!="undefined"&&global||Ox)});var et=T(function(MT,KJ){"use strict";var Fx=function Fx(e){return e&&e.Math===Math&&e};KJ.exports=Fx((typeof globalThis==="undefined"?"undefined":_type_of(globalThis))=="object"&&globalThis)||Fx((typeof window==="undefined"?"undefined":_type_of(window))=="object"&&window)||Fx((typeof self==="undefined"?"undefined":_type_of(self))=="object"&&self)||Fx((typeof global==="undefined"?"undefined":_type_of(global))=="object"&&global)||Fx((typeof MT==="undefined"?"undefined":_type_of(MT))=="object"&&MT)||function(){return this}()||Function("return this")()});var Qe=T(function(lka,JJ){"use strict";JJ.exports=function(e){try{return!!e()}catch(t){return!0}}});var Ut=T(function(cka,ZJ){"use strict";var fKe=Qe();ZJ.exports=!fKe(function(){return Object.defineProperty({},1,{get:function get(){return 7}})[1]!==7})});var b2=T(function(pka,YJ){"use strict";var gKe=Qe();YJ.exports=!gKe(function(){var e=(function(){}).bind();return typeof e!="function"||e.hasOwnProperty("prototype")})});var Bt=T(function(dka,XJ){"use strict";var hKe=b2(),k4=Function.prototype.call;XJ.exports=hKe?k4.bind(k4):function(){return k4.apply(k4,arguments)}});var qx=T(function(aZ){"use strict";var eZ={}.propertyIsEnumerable,tZ=Object.getOwnPropertyDescriptor,_Ke=tZ&&!eZ.call({1:2},1);aZ.f=_Ke?function(t){var a=tZ(this,t);return!!a&&a.enumerable}:eZ});var Yo=T(function(fka,rZ){"use strict";rZ.exports=function(e,t){return{enumerable:!(e&1),configurable:!(e&2),writable:!(e&4),value:t}}});var Oe=T(function(gka,oZ){"use strict";var iZ=b2(),nZ=Function.prototype,PT=nZ.call,xKe=iZ&&nZ.bind.bind(PT,PT);oZ.exports=iZ?xKe:function(e){return function(){return PT.apply(e,arguments)}}});var On=T(function(hka,uZ){"use strict";var sZ=Oe(),AKe=sZ({}.toString),vKe=sZ("".slice);uZ.exports=function(e){return vKe(AKe(e),8,-1)}});var Gm=T(function(_ka,lZ){"use strict";var yKe=Oe(),wKe=Qe(),bKe=On(),RT=Object,IKe=yKe("".split);lZ.exports=wKe(function(){return!RT("z").propertyIsEnumerable(0)})?function(e){return bKe(e)==="String"?IKe(e,""):RT(e)}:RT});var wc=T(function(xka,cZ){"use strict";cZ.exports=function(e){return e==null}});var Wr=T(function(Aka,pZ){"use strict";var kKe=wc(),CKe=TypeError;pZ.exports=function(e){if(kKe(e))throw new CKe("Can't call method on "+e);return e}});var rn=T(function(vka,dZ){"use strict";var EKe=Gm(),SKe=Wr();dZ.exports=function(e){return EKe(SKe(e))}});var Ua=T(function(yka,mZ){"use strict";var QT=(typeof document==="undefined"?"undefined":_type_of(document))=="object"&&document.all;mZ.exports=typeof QT=="undefined"&&QT!==void 0?function(e){return typeof e=="function"||e===QT}:function(e){return typeof e=="function"}});var ta=T(function(wka,fZ){"use strict";var BKe=Ua();fZ.exports=function(e){return(typeof e==="undefined"?"undefined":_type_of(e))=="object"?e!==null:BKe(e)}});var Ta=T(function(bka,gZ){"use strict";var DT=et(),TKe=Ua(),MKe=function MKe(e){return TKe(e)?e:void 0};gZ.exports=function(e,t){return arguments.length<2?MKe(DT[e]):DT[e]&&DT[e][t]}});var ao=T(function(Ika,hZ){"use strict";var PKe=Oe();hZ.exports=PKe({}.isPrototypeOf)});var _l=T(function(kka,AZ){"use strict";var RKe=et(),_Z=RKe.navigator,xZ=_Z&&_Z.userAgent;AZ.exports=xZ?String(xZ):""});var Al=T(function(Cka,kZ){"use strict";var IZ=et(),NT=_l(),vZ=IZ.process,yZ=IZ.Deno,wZ=vZ&&vZ.versions||yZ&&yZ.version,bZ=wZ&&wZ.v8,xl,C4;bZ&&(xl=bZ.split("."),C4=xl[0]>0&&xl[0]<4?1:+(xl[0]+xl[1]));!C4&&NT&&(xl=NT.match(/Edge\/(\d+)/),(!xl||xl[1]>=74)&&(xl=NT.match(/Chrome\/(\d+)/),xl&&(C4=+xl[1])));kZ.exports=C4});var Ud=T(function(Eka,EZ){"use strict";var CZ=Al(),QKe=Qe(),DKe=et(),NKe=DKe.String;EZ.exports=!!Object.getOwnPropertySymbols&&!QKe(function(){var e=Symbol("symbol detection");return!NKe(e)||!_instanceof(Object(e),Symbol)||!Symbol.sham&&CZ&&CZ<41})});var OT=T(function(Ska,SZ){"use strict";var OKe=Ud();SZ.exports=OKe&&!Symbol.sham&&_type_of(Symbol.iterator)=="symbol"});var Gd=T(function(Bka,BZ){"use strict";var FKe=Ta(),qKe=Ua(),LKe=ao(),$Ke=OT(),UKe=Object;BZ.exports=$Ke?function(e){return(typeof e==="undefined"?"undefined":_type_of(e))=="symbol"}:function(e){var t=FKe("Symbol");return qKe(t)&&LKe(t.prototype,UKe(e))}});var zd=T(function(Tka,TZ){"use strict";var GKe=String;TZ.exports=function(e){try{return GKe(e)}catch(t){return"Object"}}});var Oa=T(function(Mka,MZ){"use strict";var zKe=Ua(),jKe=zd(),HKe=TypeError;MZ.exports=function(e){if(zKe(e))return e;throw new HKe(jKe(e)+" is not a function")}});var fn=T(function(Pka,PZ){"use strict";var WKe=Oa(),VKe=wc();PZ.exports=function(e,t){var a=e[t];return VKe(a)?void 0:WKe(a)}});var $T=T(function(Rka,RZ){"use strict";var FT=Bt(),qT=Ua(),LT=ta(),KKe=TypeError;RZ.exports=function(e,t){var a,r;if(t==="string"&&qT(a=e.toString)&&!LT(r=FT(a,e))||qT(a=e.valueOf)&&!LT(r=FT(a,e))||t!=="string"&&qT(a=e.toString)&&!LT(r=FT(a,e)))return r;throw new KKe("Can't convert object to primitive value")}});var or=T(function(Qka,QZ){"use strict";QZ.exports=!1});var E4=T(function(Dka,NZ){"use strict";var DZ=et(),JKe=Object.defineProperty;NZ.exports=function(e,t){try{JKe(DZ,e,{value:t,configurable:!0,writable:!0})}catch(a){DZ[e]=t}return t}});var Lx=T(function(Nka,qZ){"use strict";var ZKe=or(),YKe=et(),XKe=E4(),OZ="__core-js_shared__",FZ=qZ.exports=YKe[OZ]||XKe(OZ,{});(FZ.versions||(FZ.versions=[])).push({version:"3.47.0",mode:ZKe?"pure":"global",copyright:"\xa9 2014-2025 Denis Pushkarev (zloirock.ru), 2025 CoreJS Company (core-js.io)",license:"https://github.com/zloirock/core-js/blob/v3.47.0/LICENSE",source:"https://github.com/zloirock/core-js"})});var zm=T(function(Oka,$Z){"use strict";var LZ=Lx();$Z.exports=function(e,t){return LZ[e]||(LZ[e]=t||{})}});var tr=T(function(Fka,UZ){"use strict";var eJe=Wr(),tJe=Object;UZ.exports=function(e){return tJe(eJe(e))}});var Ma=T(function(qka,GZ){"use strict";var aJe=Oe(),rJe=tr(),iJe=aJe({}.hasOwnProperty);GZ.exports=Object.hasOwn||function(t,a){return iJe(rJe(t),a)}});var jd=T(function(Lka,zZ){"use strict";var nJe=Oe(),oJe=0,sJe=Math.random(),uJe=nJe(1.1.toString);zZ.exports=function(e){return"Symbol("+(e===void 0?"":e)+")_"+uJe(++oJe+sJe,36)}});var ca=T(function($ka,HZ){"use strict";var lJe=et(),cJe=zm(),jZ=Ma(),pJe=jd(),dJe=Ud(),mJe=OT(),I2=lJe.Symbol,UT=cJe("wks"),fJe=mJe?I2.for||I2:I2&&I2.withoutSetter||pJe;HZ.exports=function(e){return jZ(UT,e)||(UT[e]=dJe&&jZ(I2,e)?I2[e]:fJe("Symbol."+e)),UT[e]}});var $x=T(function(Uka,KZ){"use strict";var gJe=Bt(),WZ=ta(),VZ=Gd(),hJe=fn(),_Je=$T(),xJe=ca(),AJe=TypeError,vJe=xJe("toPrimitive");KZ.exports=function(e,t){if(!WZ(e)||VZ(e))return e;var a=hJe(e,vJe),r;if(a){if(t===void 0&&(t="default"),r=gJe(a,e,t),!WZ(r)||VZ(r))return r;throw new AJe("Can't convert object to primitive value")}return t===void 0&&(t="number"),_Je(e,t)}});var Ap=T(function(Gka,JZ){"use strict";var yJe=$x(),wJe=Gd();JZ.exports=function(e){var t=yJe(e,"string");return wJe(t)?t:t+""}});var Ux=T(function(zka,YZ){"use strict";var bJe=et(),ZZ=ta(),GT=bJe.document,IJe=ZZ(GT)&&ZZ(GT.createElement);YZ.exports=function(e){return IJe?GT.createElement(e):{}}});var zT=T(function(jka,XZ){"use strict";var kJe=Ut(),CJe=Qe(),EJe=Ux();XZ.exports=!kJe&&!CJe(function(){return Object.defineProperty(EJe("div"),"a",{get:function get(){return 7}}).a!==7})});var gn=T(function(tY){"use strict";var SJe=Ut(),BJe=Bt(),TJe=qx(),MJe=Yo(),PJe=rn(),RJe=Ap(),QJe=Ma(),DJe=zT(),eY=Object.getOwnPropertyDescriptor;tY.f=SJe?eY:function(t,a){if(t=PJe(t),a=RJe(a),DJe)try{return eY(t,a)}catch(r){}if(QJe(t,a))return MJe(!BJe(TJe.f,t,a),t[a])}});var jT=T(function(Wka,aY){"use strict";var NJe=Ut(),OJe=Qe();aY.exports=NJe&&OJe(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42})});var Dt=T(function(Vka,rY){"use strict";var FJe=ta(),qJe=String,LJe=TypeError;rY.exports=function(e){if(FJe(e))return e;throw new LJe(qJe(e)+" is not an object")}});var Or=T(function(nY){"use strict";var $Je=Ut(),UJe=zT(),GJe=jT(),S4=Dt(),iY=Ap(),zJe=TypeError,HT=Object.defineProperty,jJe=Object.getOwnPropertyDescriptor,WT="enumerable",VT="configurable",KT="writable";nY.f=$Je?GJe?function(t,a,r){if(S4(t),a=iY(a),S4(r),typeof t=="function"&&a==="prototype"&&"value"in r&&KT in r&&!r[KT]){var i=jJe(t,a);i&&i[KT]&&(t[a]=r.value,r={configurable:VT in r?r[VT]:i[VT],enumerable:WT in r?r[WT]:i[WT],writable:!1})}return HT(t,a,r)}:HT:function(t,a,r){if(S4(t),a=iY(a),S4(r),UJe)try{return HT(t,a,r)}catch(i){}if("get"in r||"set"in r)throw new zJe("Accessors not supported");return"value"in r&&(t[a]=r.value),t}});var hn=T(function(Jka,oY){"use strict";var HJe=Ut(),WJe=Or(),VJe=Yo();oY.exports=HJe?function(e,t,a){return WJe.f(e,t,VJe(1,a))}:function(e,t,a){return e[t]=a,e}});var jm=T(function(Zka,uY){"use strict";var JT=Ut(),KJe=Ma(),sY=Function.prototype,JJe=JT&&Object.getOwnPropertyDescriptor,ZT=KJe(sY,"name"),ZJe=ZT&&(function(){}).name==="something",YJe=ZT&&(!JT||JT&&JJe(sY,"name").configurable);uY.exports={EXISTS:ZT,PROPER:ZJe,CONFIGURABLE:YJe}});var B4=T(function(Yka,lY){"use strict";var XJe=Oe(),eZe=Ua(),YT=Lx(),tZe=XJe(Function.toString);eZe(YT.inspectSource)||(YT.inspectSource=function(e){return tZe(e)});lY.exports=YT.inspectSource});var XT=T(function(Xka,pY){"use strict";var aZe=et(),rZe=Ua(),cY=aZe.WeakMap;pY.exports=rZe(cY)&&/native code/.test(String(cY))});var Gx=T(function(eCa,mY){"use strict";var iZe=zm(),nZe=jd(),dY=iZe("keys");mY.exports=function(e){return dY[e]||(dY[e]=nZe(e))}});var k2=T(function(tCa,fY){"use strict";fY.exports={}});var Fr=T(function(aCa,_Y){"use strict";var oZe=XT(),hY=et(),sZe=ta(),uZe=hn(),eM=Ma(),tM=Lx(),lZe=Gx(),cZe=k2(),gY="Object already initialized",aM=hY.TypeError,pZe=hY.WeakMap,T4,zx,M4,dZe=function dZe(e){return M4(e)?zx(e):T4(e,{})},mZe=function mZe(e){return function(t){var a;if(!sZe(t)||(a=zx(t)).type!==e)throw new aM("Incompatible receiver, "+e+" required");return a}};oZe||tM.state?(vl=tM.state||(tM.state=new pZe),vl.get=vl.get,vl.has=vl.has,vl.set=vl.set,T4=function T4(e,t){if(vl.has(e))throw new aM(gY);return t.facade=e,vl.set(e,t),t},zx=function zx(e){return vl.get(e)||{}},M4=function M4(e){return vl.has(e)}):(Hm=lZe("state"),cZe[Hm]=!0,T4=function T4(e,t){if(eM(e,Hm))throw new aM(gY);return t.facade=e,uZe(e,Hm,t),t},zx=function zx(e){return eM(e,Hm)?e[Hm]:{}},M4=function M4(e){return eM(e,Hm)});var vl,Hm;_Y.exports={set:T4,get:zx,has:M4,enforce:dZe,getterFor:mZe}});var Q4=T(function(rCa,vY){"use strict";var iM=Oe(),fZe=Qe(),gZe=Ua(),P4=Ma(),rM=Ut(),hZe=jm().CONFIGURABLE,_Ze=B4(),AY=Fr(),xZe=AY.enforce,AZe=AY.get,xY=String,R4=Object.defineProperty,vZe=iM("".slice),yZe=iM("".replace),wZe=iM([].join),bZe=rM&&!fZe(function(){return R4(function(){},"length",{value:8}).length!==8}),IZe=String(String).split("String"),kZe=vY.exports=function kZe(e,t,a){vZe(xY(t),0,7)==="Symbol("&&(t="["+yZe(xY(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),a&&a.getter&&(t="get "+t),a&&a.setter&&(t="set "+t),(!P4(e,"name")||hZe&&e.name!==t)&&(rM?R4(e,"name",{value:t,configurable:!0}):e.name=t),bZe&&a&&P4(a,"arity")&&e.length!==a.arity&&R4(e,"length",{value:a.arity});try{a&&P4(a,"constructor")&&a.constructor?rM&&R4(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(i){}var r=xZe(e);return P4(r,"source")||(r.source=wZe(IZe,typeof t=="string"?t:"")),e};Function.prototype.toString=kZe(function(){return gZe(this)&&AZe(this).source||_Ze(this)},"toString")});var mr=T(function(iCa,yY){"use strict";var CZe=Ua(),EZe=Or(),SZe=Q4(),BZe=E4();yY.exports=function(e,t,a,r){r||(r={});var i=r.enumerable,n=r.name!==void 0?r.name:t;if(CZe(a)&&SZe(a,n,r),r.global)i?e[t]=a:BZe(t,a);else{try{r.unsafe?e[t]&&(i=!0):delete e[t]}catch(o){}i?e[t]=a:EZe.f(e,t,{value:a,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return e}});var nM=T(function(nCa,wY){"use strict";var TZe=Math.ceil,MZe=Math.floor;wY.exports=Math.trunc||function(t){var a=+t;return(a>0?MZe:TZe)(a)}});var ci=T(function(oCa,bY){"use strict";var PZe=nM();bY.exports=function(e){var t=+e;return t!==t||t===0?0:PZe(t)}});var bc=T(function(sCa,IY){"use strict";var RZe=ci(),QZe=Math.max,DZe=Math.min;IY.exports=function(e,t){var a=RZe(e);return a<0?QZe(a+t,0):DZe(a,t)}});var Xo=T(function(uCa,kY){"use strict";var NZe=ci(),OZe=Math.min;kY.exports=function(e){var t=NZe(e);return t>0?OZe(t,0x1fffffffffffff):0}});var fr=T(function(lCa,CY){"use strict";var FZe=Xo();CY.exports=function(e){return FZe(e.length)}});var C2=T(function(cCa,SY){"use strict";var qZe=rn(),LZe=bc(),$Ze=fr(),EY=function EY(e){return function(t,a,r){var i=qZe(t),n=$Ze(i);if(n===0)return!e&&-1;var o=LZe(r,n),s;if(e&&a!==a){for(;n>o;)if(s=i[o++],s!==s)return!0}else for(;n>o;o++)if((e||o in i)&&i[o]===a)return e||o||0;return!e&&-1}};SY.exports={includes:EY(!0),indexOf:EY(!1)}});var sM=T(function(pCa,TY){"use strict";var UZe=Oe(),oM=Ma(),GZe=rn(),zZe=C2().indexOf,jZe=k2(),BY=UZe([].push);TY.exports=function(e,t){var a=GZe(e),r=0,i=[],n;for(n in a)!oM(jZe,n)&&oM(a,n)&&BY(i,n);for(;t.length>r;)oM(a,n=t[r++])&&(~zZe(i,n)||BY(i,n));return i}});var D4=T(function(dCa,MY){"use strict";MY.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]});var Hd=T(function(PY){"use strict";var HZe=sM(),WZe=D4(),VZe=WZe.concat("length","prototype");PY.f=Object.getOwnPropertyNames||function(t){return HZe(t,VZe)}});var jx=T(function(RY){"use strict";RY.f=Object.getOwnPropertySymbols});var N4=T(function(gCa,QY){"use strict";var KZe=Ta(),JZe=Oe(),ZZe=Hd(),YZe=jx(),XZe=Dt(),eYe=JZe([].concat);QY.exports=KZe("Reflect","ownKeys")||function(t){var a=ZZe.f(XZe(t)),r=YZe.f;return r?eYe(a,r(t)):a}});var Wm=T(function(hCa,NY){"use strict";var DY=Ma(),tYe=N4(),aYe=gn(),rYe=Or();NY.exports=function(e,t,a){for(var r=tYe(t),i=rYe.f,n=aYe.f,o=0;oo;)PYe.f(t,s=i[o++],r[s]);return t}});var uM=T(function(ICa,jY){"use strict";var NYe=Ta();jY.exports=NYe("document","documentElement")});var _n=T(function(kCa,YY){"use strict";var OYe=Dt(),FYe=L4(),HY=D4(),qYe=k2(),LYe=uM(),$Ye=Ux(),UYe=Gx(),WY=">",VY="<",cM="prototype",pM="script",JY=UYe("IE_PROTO"),lM=function lM(){},ZY=function ZY(e){return VY+pM+WY+e+VY+"/"+pM+WY},KY=function KY(e){e.write(ZY("")),e.close();var t=e.parentWindow.Object;return e=null,t},GYe=function GYe(){var e=$Ye("iframe"),t="java"+pM+":",a;return e.style.display="none",LYe.appendChild(e),e.src=String(t),a=e.contentWindow.document,a.open(),a.write(ZY("document.F=Object")),a.close(),a.F},$4,U4=function U41(){try{$4=new ActiveXObject("htmlfile")}catch(t){}U4=typeof document!="undefined"?document.domain&&$4?KY($4):GYe():KY($4);for(var e=HY.length;e--;)delete U4[cM][HY[e]];return U4()};qYe[JY]=!0;YY.exports=Object.create||function(t,a){var r;return t!==null?(lM[cM]=OYe(t),r=new lM,lM[cM]=null,r[JY]=t):r=U4(),a===void 0?r:FYe.f(r,a)}});var zs=T(function(CCa,XY){"use strict";var zYe=Oe();XY.exports=zYe([].slice)});var G4=T(function(ECa,aX){"use strict";var jYe=On(),HYe=rn(),eX=Hd().f,WYe=zs(),tX=(typeof window==="undefined"?"undefined":_type_of(window))=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],VYe=function VYe(e){try{return eX(e)}catch(t){return WYe(tX)}};aX.exports.f=function(t){return tX&&jYe(t)==="Window"?VYe(t):eX(HYe(t))}});var bi=T(function(SCa,iX){"use strict";var rX=Q4(),KYe=Or();iX.exports=function(e,t,a){return a.get&&rX(a.get,t,{getter:!0}),a.set&&rX(a.set,t,{setter:!0}),KYe.f(e,t,a)}});var dM=T(function(nX){"use strict";var JYe=ca();nX.f=JYe});var Wx=T(function(TCa,oX){"use strict";var ZYe=et();oX.exports=ZYe});var Fn=T(function(MCa,uX){"use strict";var sX=Wx(),YYe=Ma(),XYe=dM(),eXe=Or().f;uX.exports=function(e){var t=sX.Symbol||(sX.Symbol={});YYe(t,e)||eXe(t,e,{value:XYe.f(e)})}});var mM=T(function(PCa,lX){"use strict";var tXe=Bt(),aXe=Ta(),rXe=ca(),iXe=mr();lX.exports=function(){var e=aXe("Symbol"),t=e&&e.prototype,a=t&&t.valueOf,r=rXe("toPrimitive");t&&!t[r]&&iXe(t,r,function(i){return tXe(a,this)},{arity:1})}});var Io=T(function(RCa,pX){"use strict";var nXe=Or().f,oXe=Ma(),sXe=ca(),cX=sXe("toStringTag");pX.exports=function(e,t,a){e&&!a&&(e=e.prototype),e&&!oXe(e,cX)&&nXe(e,cX,{configurable:!0,value:t})}});var Wd=T(function(QCa,dX){"use strict";var uXe=On(),lXe=Oe();dX.exports=function(e){if(uXe(e)==="Function")return lXe(e)}});var ts=T(function(DCa,fX){"use strict";var mX=Wd(),cXe=Oa(),pXe=b2(),dXe=mX(mX.bind);fX.exports=function(e,t){return cXe(e),t===void 0?e:pXe?dXe(e,t):function(){return e.apply(t,arguments)}}});var Ic=T(function(NCa,gX){"use strict";var mXe=On();gX.exports=Array.isArray||function(t){return mXe(t)==="Array"}});var Vd=T(function(OCa,vX){"use strict";var fXe=Oe(),gXe=Qe(),hX=Ua(),hXe=es(),_Xe=Ta(),xXe=B4(),_X=function _X(){},xX=_Xe("Reflect","construct"),fM=/^\s*(?:class|function)\b/,AXe=fXe(fM.exec),vXe=!fM.test(_X),Vx=function Vx(t){if(!hX(t))return!1;try{return xX(_X,[],t),!0}catch(a){return!1}},AX=function AX(t){if(!hX(t))return!1;switch(hXe(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return vXe||!!AXe(fM,xXe(t))}catch(a){return!0}};AX.sham=!0;vX.exports=!xX||gXe(function(){var e;return Vx(Vx.call)||!Vx(Object)||!Vx(function(){e=!0})||e})?AX:Vx});var IX=T(function(FCa,bX){"use strict";var yX=Ic(),yXe=Vd(),wXe=ta(),bXe=ca(),IXe=bXe("species"),wX=Array;bX.exports=function(e){var t;return yX(e)&&(t=e.constructor,yXe(t)&&(t===wX||yX(t.prototype))?t=void 0:wXe(t)&&(t=t[IXe],t===null&&(t=void 0))),t===void 0?wX:t}});var B2=T(function(qCa,kX){"use strict";var kXe=IX();kX.exports=function(e,t){return new(kXe(e))(t===0?0:t)}});var xn=T(function(LCa,EX){"use strict";var CXe=ts(),EXe=Oe(),SXe=Gm(),BXe=tr(),TXe=fr(),MXe=B2(),CX=EXe([].push),Kd=function Kd(e){var t=e===1,a=e===2,r=e===3,i=e===4,n=e===6,o=e===7,s=e===5||n;return function(u,c,p,l){for(var m=BXe(u),f=SXe(m),g=TXe(f),h=CXe(c,p),_=0,A=l||MXe,x=t?A(u,g):a||o?A(u,0):void 0,y,v;g>_;_++)if((s||_ in f)&&(y=f[_],v=h(y,_,m),e))if(t)x[_]=v;else if(v)switch(e){case 3:return!0;case 5:return y;case 6:return _;case 2:CX(x,y)}else switch(e){case 4:return!1;case 7:CX(x,y)}return n?-1:r||i?i:x}};EX.exports={forEach:Kd(0),map:Kd(1),filter:Kd(2),some:Kd(3),every:Kd(4),find:Kd(5),findIndex:Kd(6),filterReject:Kd(7)}});var zX=T(function(){"use strict";var z4=ne(),Zx=et(),bM=Bt(),PXe=Oe(),RXe=or(),T2=Ut(),M2=Ud(),QXe=Qe(),An=Ma(),DXe=ao(),xM=Dt(),j4=rn(),IM=Ap(),NXe=ga(),AM=Yo(),P2=_n(),TX=S2(),OXe=Hd(),MX=G4(),FXe=jx(),PX=gn(),RX=Or(),qXe=L4(),QX=qx(),gM=mr(),LXe=bi(),kM=zm(),$Xe=Gx(),DX=k2(),SX=jd(),UXe=ca(),GXe=dM(),zXe=Fn(),jXe=mM(),HXe=Io(),NX=Fr(),H4=xn().forEach,as=$Xe("hidden"),W4="Symbol",Jx="prototype",WXe=NX.set,BX=NX.getterFor(W4),vu=Object[Jx],Vm=Zx.Symbol,Kx=Vm&&Vm[Jx],VXe=Zx.RangeError,KXe=Zx.TypeError,hM=Zx.QObject,OX=PX.f,Km=RX.f,FX=MX.f,JXe=QX.f,qX=PXe([].push),vp=kM("symbols"),Yx=kM("op-symbols"),ZXe=kM("wks"),vM=!hM||!hM[Jx]||!hM[Jx].findChild,LX=function LX(e,t,a){var r=OX(vu,t);r&&delete vu[t],Km(e,t,a),r&&e!==vu&&Km(vu,t,r)},yM=T2&&QXe(function(){return P2(Km({},"a",{get:function get(){return Km(this,"a",{value:7}).a}})).a!==7})?LX:Km,_M=function _M(e,t){var a=vp[e]=P2(Kx);return WXe(a,{type:W4,tag:e,description:t}),T2||(a.description=t),a},V4=function V41(t,a,r){t===vu&&V4(Yx,a,r),xM(t);var i=IM(a);return xM(r),An(vp,i)?(r.enumerable?(An(t,as)&&t[as][i]&&(t[as][i]=!1),r=P2(r,{enumerable:AM(0,!1)})):(An(t,as)||Km(t,as,AM(1,P2(null))),t[as][i]=!0),yM(t,i,r)):Km(t,i,r)},CM=function CM(t,a){xM(t);var r=j4(a),i=TX(r).concat(GX(r));return H4(i,function(n){(!T2||bM(wM,r,n))&&V4(t,n,r[n])}),t},YXe=function YXe(t,a){return a===void 0?P2(t):CM(P2(t),a)},wM=function wM(t){var a=IM(t),r=bM(JXe,this,a);return this===vu&&An(vp,a)&&!An(Yx,a)?!1:r||!An(this,a)||!An(vp,a)||An(this,as)&&this[as][a]?r:!0},$X=function $X(t,a){var r=j4(t),i=IM(a);if(!(r===vu&&An(vp,i)&&!An(Yx,i))){var n=OX(r,i);return n&&An(vp,i)&&!(An(r,as)&&r[as][i])&&(n.enumerable=!0),n}},UX=function UX(t){var a=FX(j4(t)),r=[];return H4(a,function(i){!An(vp,i)&&!An(DX,i)&&qX(r,i)}),r},GX=function GX(e){var t=e===vu,a=FX(t?Yx:j4(e)),r=[];return H4(a,function(i){An(vp,i)&&(!t||An(vu,i))&&qX(r,vp[i])}),r};M2||(Vm=function Vm(){if(DXe(Kx,this))throw new KXe("Symbol is not a constructor");var t=!arguments.length||arguments[0]===void 0?void 0:NXe(arguments[0]),a=SX(t),r=function r6(i){var n=this===void 0?Zx:this;n===vu&&bM(r,Yx,i),An(n,as)&&An(n[as],a)&&(n[as][a]=!1);var o=AM(1,i);try{yM(n,a,o)}catch(s){if(!_instanceof(s,VXe))throw s;LX(n,a,o)}};return T2&&vM&&yM(vu,a,{configurable:!0,set:r}),_M(a,t)},Kx=Vm[Jx],gM(Kx,"toString",function(){return BX(this).tag}),gM(Vm,"withoutSetter",function(e){return _M(SX(e),e)}),QX.f=wM,RX.f=V4,qXe.f=CM,PX.f=$X,OXe.f=MX.f=UX,FXe.f=GX,GXe.f=function(e){return _M(UXe(e),e)},T2&&(LXe(Kx,"description",{configurable:!0,get:function get(){return BX(this).description}}),RXe||gM(vu,"propertyIsEnumerable",wM,{unsafe:!0})));z4({global:!0,constructor:!0,wrap:!0,forced:!M2,sham:!M2},{Symbol:Vm});H4(TX(ZXe),function(e){zXe(e)});z4({target:W4,stat:!0,forced:!M2},{useSetter:function useSetter(){vM=!0},useSimple:function useSimple(){vM=!1}});z4({target:"Object",stat:!0,forced:!M2,sham:!T2},{create:YXe,defineProperty:V4,defineProperties:CM,getOwnPropertyDescriptor:$X});z4({target:"Object",stat:!0,forced:!M2},{getOwnPropertyNames:UX});jXe();HXe(Vm,W4);DX[as]=!0});var EM=T(function(GCa,jX){"use strict";var XXe=Ud();jX.exports=XXe&&!!Symbol.for&&!!Symbol.keyFor});var WX=T(function(){"use strict";var eet=ne(),tet=Ta(),aet=Ma(),ret=ga(),HX=zm(),iet=EM(),SM=HX("string-to-symbol-registry"),net=HX("symbol-to-string-registry");eet({target:"Symbol",stat:!0,forced:!iet},{for:function _for(e){var t=ret(e);if(aet(SM,t))return SM[t];var a=tet("Symbol")(t);return SM[t]=a,net[a]=t,a}})});var KX=T(function(){"use strict";var oet=ne(),set=Ma(),uet=Gd(),cet=zd(),pet=zm(),det=EM(),VX=pet("symbol-to-string-registry");oet({target:"Symbol",stat:!0,forced:!det},{keyFor:function keyFor(t){if(!uet(t))throw new TypeError(cet(t)+" is not a symbol");if(set(VX,t))return VX[t]}})});var rs=T(function(VCa,XX){"use strict";var met=b2(),YX=Function.prototype,JX=YX.apply,ZX=YX.call;XX.exports=(typeof Reflect==="undefined"?"undefined":_type_of(Reflect))=="object"&&Reflect.apply||(met?ZX.bind(JX):function(){return ZX.apply(JX,arguments)})});var BM=T(function(KCa,eee){"use strict";var fet=ta(),get=Fr().get;eee.exports=function(t){if(!fet(t))return!1;var a=get(t);return!!a&&a.type==="RawJSON"}});var MM=T(function(JCa,iee){"use strict";var TM=Oe(),het=Ma(),K4=SyntaxError,_et=parseInt,xet=String.fromCharCode,Aet=TM("".charAt),tee=TM("".slice),aee=TM(/./.exec),ree={'\\"':'"',"\\\\":"\\","\\/":"/","\\b":"\b","\\f":"\f","\\n":"\n","\\r":"\r","\\t":" "},vet=/^[\da-f]{4}$/i,yet=/^[\u0000-\u001F]$/;iee.exports=function(e,t){for(var a=!0,r="";tn&&Ztt(h,arguments[n]),h});if(l.prototype=c,s!=="Error"?ste?ste(l,p):ute(l,p,{name:!0}):Xtt&&i in u&&(lte(l,u,i),lte(l,u,"prepareStackTrace")),ute(l,u),!cte)try{c.name!==s&&ote(c,"name",s),c.constructor=l}catch(m){}return l}}});var gte=T(function(){"use strict";var mte=ne(),eat=et(),kc=rs(),fte=HM(),WM="WebAssembly",dte=eat[WM],a6=new Error("e",{cause:7}).cause!==7,Xm=function Xm(e,t){var a={};a[e]=fte(e,t,a6),mte({global:!0,constructor:!0,arity:1,forced:a6},a)},VM=function VM(e,t){if(dte&&dte[e]){var a={};a[e]=fte(WM+"."+e,t,a6),mte({target:WM,stat:!0,constructor:!0,arity:1,forced:a6},a)}};Xm("Error",function(e){return function(a){return kc(e,this,arguments)}});Xm("EvalError",function(e){return function(a){return kc(e,this,arguments)}});Xm("RangeError",function(e){return function(a){return kc(e,this,arguments)}});Xm("ReferenceError",function(e){return function(a){return kc(e,this,arguments)}});Xm("SyntaxError",function(e){return function(a){return kc(e,this,arguments)}});Xm("TypeError",function(e){return function(a){return kc(e,this,arguments)}});Xm("URIError",function(e){return function(a){return kc(e,this,arguments)}});VM("CompileError",function(e){return function(a){return kc(e,this,arguments)}});VM("LinkError",function(e){return function(a){return kc(e,this,arguments)}});VM("RuntimeError",function(e){return function(a){return kc(e,this,arguments)}})});var Ate=T(function(){"use strict";var tat=ne(),_te=Ta(),aat=ta(),rat=es(),iat=Qe(),xte="Error",JM="DOMException",nat=Object.setPrototypeOf||({}).__proto__,hte=_te(JM),KM=Error,r6=KM.isError,oat=!r6||!nat||iat(function(){return hte&&!r6(new hte(JM))||!r6(new KM(xte,{cause:function cause(){}}))||r6(_te("Object","create")(KM.prototype))});tat({target:"Error",stat:!0,sham:!0,forced:oat},{isError:function isError(t){if(!aat(t))return!1;var a=rat(t);return a===xte||a===JM}})});var ZM=T(function(Y8a,yte){"use strict";var sat=Ut(),uat=Qe(),lat=Dt(),vte=Ym(),i6=Error.prototype.toString,cat=uat(function(){if(sat){var e=Object.create(Object.defineProperty({},"name",{get:function get(){return this===e}}));if(i6.call(e)!=="true")return!0}return i6.call({message:1,name:2})!=="2: 1"||i6.call({})!=="Error"});yte.exports=cat?function(){var t=lat(this),a=vte(t.name,"Error"),r=vte(t.message);return a?r?a+": "+r:a:r}:i6});var Ite=T(function(){"use strict";var pat=mr(),wte=ZM(),bte=Error.prototype;bte.toString!==wte&&pat(bte,"toString",wte)});var n6=T(function(tEa,kte){"use strict";var dat=Qe();kte.exports=!dat(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype})});var ro=T(function(aEa,Ete){"use strict";var mat=Ma(),fat=Ua(),gat=tr(),hat=Gx(),_at=n6(),Cte=hat("IE_PROTO"),YM=Object,xat=YM.prototype;Ete.exports=_at?YM.getPrototypeOf:function(e){var t=gat(e);if(mat(t,Cte))return t[Cte];var a=t.constructor;return fat(a)&&_instanceof(t,a)?a.prototype:_instanceof(t,YM)?xat:null}});var R2=T(function(rEa,Ste){"use strict";Ste.exports={}});var o6=T(function(iEa,Bte){"use strict";var Aat=ca(),vat=R2(),yat=Aat("iterator"),wat=Array.prototype;Bte.exports=function(e){return e!==void 0&&(vat.Array===e||wat[yat]===e)}});var wp=T(function(nEa,Mte){"use strict";var bat=es(),Tte=fn(),Iat=wc(),kat=R2(),Cat=ca(),Eat=Cat("iterator");Mte.exports=function(e){if(!Iat(e))return Tte(e,Eat)||Tte(e,"@@iterator")||kat[bat(e)]}});var ef=T(function(oEa,Pte){"use strict";var Sat=Bt(),Bat=Oa(),Tat=Dt(),Mat=zd(),Pat=wp(),Rat=TypeError;Pte.exports=function(e,t){var a=arguments.length<2?Pat(e):t;if(Bat(a))return Tat(Sat(a,e));throw new Rat(Mat(e)+" is not iterable")}});var vn=T(function(sEa,Qte){"use strict";var Qat=Bt(),Rte=Dt(),Dat=fn();Qte.exports=function(e,t,a){var r,i;Rte(e);try{if(r=Dat(e,"return"),!r){if(t==="throw")throw a;return a}r=Qat(r,e)}catch(n){i=!0,r=n}if(t==="throw")throw a;if(i)throw r;return Rte(r),a}});var Gi=T(function(uEa,Fte){"use strict";var Nat=ts(),Oat=Bt(),Fat=Dt(),qat=zd(),Lat=o6(),$at=fr(),Dte=ao(),Uat=ef(),Gat=wp(),Nte=vn(),zat=TypeError,s6=function s6(e,t){this.stopped=e,this.result=t},Ote=s6.prototype;Fte.exports=function(e,t,a){var r=a&&a.that,i=!!(a&&a.AS_ENTRIES),n=!!(a&&a.IS_RECORD),o=!!(a&&a.IS_ITERATOR),s=!!(a&&a.INTERRUPTED),u=Nat(t,r),c,p,l,m,f,g,h,_=function _(x){return c&&Nte(c,"normal"),new s6(!0,x)},A=function A(x){return i?(Fat(x),s?u(x[0],x[1],_):u(x[0],x[1])):s?u(x,_):u(x)};if(n)c=e.iterator;else if(o)c=e;else{if(p=Gat(e),!p)throw new zat(qat(e)+" is not iterable");if(Lat(p)){for(l=0,m=$at(e);m>l;l++)if(f=A(e[l]),f&&Dte(Ote,f))return f;return new s6(!1)}c=Uat(e,p)}for(g=n?e.next:c.next;!(h=Oat(g,c)).done;){try{f=A(h.value)}catch(x){Nte(c,"throw",x)}if((typeof f==="undefined"?"undefined":_type_of(f))=="object"&&f&&Dte(Ote,f))return f}return new s6(!1)}});var Lte=T(function(){"use strict";var jat=ne(),Hat=ao(),Wat=ro(),u6=yu(),Vat=Wm(),qte=_n(),XM=hn(),eP=Yo(),Kat=zM(),Jat=t6(),Zat=Gi(),Yat=Ym(),Xat=ca(),ert=Xat("toStringTag"),l6=Error,trt=[].push,Q2=function Q21(t,a){var r=Hat(tP,this),i;u6?i=u6(new l6,r?Wat(this):tP):(i=r?this:qte(tP),XM(i,ert,"Error")),a!==void 0&&XM(i,"message",Yat(a)),Jat(i,Q2,i.stack,1),arguments.length>2&&Kat(i,arguments[2]);var n=[];return Zat(t,trt,{that:n}),XM(i,"errors",n),i};u6?u6(Q2,l6):Vat(Q2,l6,{name:!0});var tP=Q2.prototype=qte(l6.prototype,{constructor:eP(1,Q2),message:eP(1,""),name:eP(1,"AggregateError")});jat({global:!0,constructor:!0,arity:2},{AggregateError:Q2})});var $te=T(function(){"use strict";Lte()});var jte=T(function(){"use strict";var art=ne(),rrt=Ta(),irt=rs(),Ute=Qe(),nrt=HM(),aP="AggregateError",Gte=rrt(aP),zte=!Ute(function(){return Gte([1]).errors[0]!==1})&&Ute(function(){return Gte([1],aP,{cause:7}).cause!==7});art({global:!0,constructor:!0,arity:2,forced:zte},{AggregateError:nrt(aP,function(e){return function(a,r){return irt(e,this,arguments)}},zte,!0)})});var Vte=T(function(){"use strict";var ort=ne(),srt=et(),urt=ao(),Hte=ro(),p6=yu(),lrt=Wm(),Wte=_n(),c6=hn(),rP=Yo(),crt=t6(),prt=Ym(),drt=ca(),mrt=Qe(),frt=or(),D2=srt.SuppressedError,grt=drt("toStringTag"),d6=Error,hrt=!!D2&&D2.length!==3,_rt=!!D2&&mrt(function(){return new D2(1,2,3,{cause:4}).cause===4}),m6=hrt||_rt,tf=function tf1(t,a,r){var i=urt(rA,this),n;return p6?n=m6&&(!i||Hte(this)===rA)?new D2:p6(new d6,i?Hte(this):rA):(n=i?this:Wte(rA),c6(n,grt,"Error")),r!==void 0&&c6(n,"message",prt(r)),crt(n,tf,n.stack,1),c6(n,"error",t),c6(n,"suppressed",a),n};p6?p6(tf,d6):lrt(tf,d6,{name:!0});var rA=tf.prototype=m6?D2.prototype:Wte(d6.prototype,{constructor:rP(1,tf),message:rP(1,""),name:rP(1,"SuppressedError")});m6&&!frt&&(rA.constructor=tf);ort({global:!0,constructor:!0,arity:3,forced:m6},{SuppressedError:tf})});var ko=T(function(_Ea,Kte){"use strict";var xrt=ca(),Art=_n(),vrt=Or().f,iP=xrt("unscopables"),nP=Array.prototype;nP[iP]===void 0&&vrt(nP,iP,{configurable:!0,value:Art(null)});Kte.exports=function(e){nP[iP][e]=!0}});var Jte=T(function(){"use strict";var yrt=ne(),wrt=tr(),brt=fr(),Irt=ci(),krt=ko();yrt({target:"Array",proto:!0},{at:function at1(t){var a=wrt(this),r=brt(a),i=Irt(t),n=i>=0?i:r+i;return n<0||n>=r?void 0:a[n]}});krt("at")});var Yd=T(function(vEa,Zte){"use strict";var Crt=TypeError,Ert=0x1fffffffffffff;Zte.exports=function(e){if(e>Ert)throw Crt("Maximum allowed index exceeded");return e}});var js=T(function(yEa,Yte){"use strict";var Srt=Ut(),Brt=Or(),Trt=Yo();Yte.exports=function(e,t,a){Srt?Brt.f(e,t,Trt(0,a)):e[t]=a}});var N2=T(function(wEa,Xte){"use strict";var Mrt=Qe(),Prt=ca(),Rrt=Al(),Qrt=Prt("species");Xte.exports=function(e){return Rrt>=51||!Mrt(function(){var t=[],a=t.constructor={};return a[Qrt]=function(){return{foo:1}},t[e](Boolean).foo!==1})}});var rae=T(function(){"use strict";var Drt=ne(),Nrt=Qe(),Ort=Ic(),Frt=ta(),qrt=tr(),Lrt=fr(),eae=Yd(),tae=js(),$rt=B2(),Urt=N2(),Grt=ca(),zrt=Al(),aae=Grt("isConcatSpreadable"),jrt=zrt>=51||!Nrt(function(){var e=[];return e[aae]=!1,e.concat()[0]!==e}),Hrt=function Hrt(e){if(!Frt(e))return!1;var t=e[aae];return t!==void 0?!!t:Ort(e)},Wrt=!jrt||!Urt("concat");Drt({target:"Array",proto:!0,arity:1,forced:Wrt},{concat:function concat(t){var a=qrt(this),r=$rt(a,0),i=0,n,o,s,u,c;for(n=-1,s=arguments.length;n2?arguments[2]:void 0,u=Yrt((s===void 0?i:oP(s,i))-o,i-n),c=1;for(o0;)o in r?r[n]=r[o]:Zrt(r,n),n+=c,o+=c;return r}});var sae=T(function(){"use strict";var Xrt=ne(),eit=sP(),tit=ko();Xrt({target:"Array",proto:!0},{copyWithin:eit});tit("copyWithin")});var Cc=T(function(BEa,uae){"use strict";var ait=Qe();uae.exports=function(e,t){var a=[][e];return!!a&&ait(function(){a.call(null,t||function(){return 1},1)})}});var lae=T(function(){"use strict";var rit=ne(),iit=xn().every,nit=Cc(),oit=nit("every");rit({target:"Array",proto:!0,forced:!oit},{every:function every(t){return iit(this,t,arguments.length>1?arguments[1]:void 0)}})});var f6=T(function(PEa,pae){"use strict";var sit=tr(),cae=bc(),uit=fr();pae.exports=function(t){for(var a=sit(this),r=uit(a),i=arguments.length,n=cae(i>1?arguments[1]:void 0,r),o=i>2?arguments[2]:void 0,s=o===void 0?r:cae(o,r);s>n;)a[n++]=t;return a}});var dae=T(function(){"use strict";var lit=ne(),cit=f6(),pit=ko();lit({target:"Array",proto:!0},{fill:cit});pit("fill")});var mae=T(function(){"use strict";var dit=ne(),mit=xn().filter,fit=N2(),git=fit("filter");dit({target:"Array",proto:!0,forced:!git},{filter:function filter(t){return mit(this,t,arguments.length>1?arguments[1]:void 0)}})});var gae=T(function(){"use strict";var hit=ne(),_it=xn().find,xit=ko(),uP="find",fae=!0;uP in[]&&Array(1)[uP](function(){fae=!1});hit({target:"Array",proto:!0,forced:fae},{find:function find(t){return _it(this,t,arguments.length>1?arguments[1]:void 0)}});xit(uP)});var _ae=T(function(){"use strict";var Ait=ne(),vit=xn().findIndex,yit=ko(),lP="findIndex",hae=!0;lP in[]&&Array(1)[lP](function(){hae=!1});Ait({target:"Array",proto:!0,forced:hae},{findIndex:function findIndex(t){return vit(this,t,arguments.length>1?arguments[1]:void 0)}});yit(lP)});var nA=T(function($Ea,Aae){"use strict";var wit=ts(),bit=Gm(),Iit=tr(),kit=fr(),xae=function xae(e){var t=e===1;return function(a,r,i){for(var n=Iit(a),o=bit(n),s=kit(o),u=wit(r,i),c,p;s-- >0;)if(c=o[s],p=u(c,s,n),p)switch(e){case 0:return c;case 1:return s}return t?-1:void 0}};Aae.exports={findLast:xae(0),findLastIndex:xae(1)}});var vae=T(function(){"use strict";var Cit=ne(),Eit=nA().findLast,Sit=ko();Cit({target:"Array",proto:!0},{findLast:function findLast(t){return Eit(this,t,arguments.length>1?arguments[1]:void 0)}});Sit("findLast")});var yae=T(function(){"use strict";var Bit=ne(),Tit=nA().findLastIndex,Mit=ko();Bit({target:"Array",proto:!0},{findLastIndex:function findLastIndex(t){return Tit(this,t,arguments.length>1?arguments[1]:void 0)}});Mit("findLastIndex")});var cP=T(function(HEa,bae){"use strict";var Pit=Ic(),Rit=fr(),Qit=Yd(),Dit=ts(),wae=function wae1(e,t,a,r,i,n,o,s){for(var u=i,c=0,p=o?Dit(o,s):!1,l,m;c0&&Pit(l)?(m=Rit(l),u=wae(e,t,l,m,u,n-1)-1):(Qit(u+1),e[u]=l),u++),c++;return u};bae.exports=wae});var Iae=T(function(){"use strict";var Nit=ne(),Oit=cP(),Fit=tr(),qit=fr(),Lit=ci(),$it=B2();Nit({target:"Array",proto:!0},{flat:function flat(){var t=arguments.length?arguments[0]:void 0,a=Fit(this),r=qit(a),i=$it(a,0);return i.length=Oit(i,a,a,r,0,t===void 0?1:Lit(t)),i}})});var kae=T(function(){"use strict";var Uit=ne(),Git=cP(),zit=Oa(),jit=tr(),Hit=fr(),Wit=B2();Uit({target:"Array",proto:!0},{flatMap:function flatMap(t){var a=jit(this),r=Hit(a),i;return zit(t),i=Wit(a,0),i.length=Git(i,a,a,r,0,1,t,arguments.length>1?arguments[1]:void 0),i}})});var pP=T(function(ZEa,Cae){"use strict";var Vit=xn().forEach,Kit=Cc(),Jit=Kit("forEach");Cae.exports=Jit?[].forEach:function(t){return Vit(this,t,arguments.length>1?arguments[1]:void 0)}});var Sae=T(function(){"use strict";var Zit=ne(),Eae=pP();Zit({target:"Array",proto:!0,forced:[].forEach!==Eae},{forEach:Eae})});var g6=T(function(e7a,Bae){"use strict";var Yit=Dt(),Xit=vn();Bae.exports=function(e,t,a,r){try{return r?t(Yit(a)[0],a[1]):t(a)}catch(i){Xit(e,"throw",i)}}});var dP=T(function(t7a,Pae){"use strict";var ent=ts(),tnt=Bt(),ant=tr(),rnt=g6(),int=o6(),nnt=Vd(),ont=fr(),Tae=js(),snt=ef(),unt=wp(),Mae=Array;Pae.exports=function(t){var a=ant(t),r=nnt(this),i=arguments.length,n=i>1?arguments[1]:void 0,o=n!==void 0;o&&(n=ent(n,i>2?arguments[2]:void 0));var s=unt(a),u=0,c,p,l,m,f,g;if(s&&!(this===Mae&&int(s)))for(p=r?new this:[],m=snt(a,s),f=m.next;!(l=tnt(f,m)).done;u++)g=o?rnt(m,n,[l.value,u],!0):l.value,Tae(p,u,g);else for(c=ont(a),p=r?new this(c):Mae(c);c>u;u++)g=o?n(a[u],u):a[u],Tae(p,u,g);return p.length=u,p}});var oA=T(function(a7a,Nae){"use strict";var lnt=ca(),Qae=lnt("iterator"),Dae=!1;try{Rae=0,mP={next:function next(){return{done:!!Rae++}},return:function _return(){Dae=!0}},mP[Qae]=function(){return this},Array.from(mP,function(){throw 2})}catch(e){}var Rae,mP;Nae.exports=function(e,t){try{if(!t&&!Dae)return!1}catch(i){return!1}var a=!1;try{var r={};r[Qae]=function(){return{next:function next(){return{done:a=!0}}}},e(r)}catch(i){}return a}});var Oae=T(function(){"use strict";var cnt=ne(),pnt=dP(),dnt=oA(),mnt=!dnt(function(e){Array.from(e)});cnt({target:"Array",stat:!0,forced:mnt},{from:pnt})});var Fae=T(function(){"use strict";var fnt=ne(),gnt=C2().includes,hnt=Qe(),_nt=ko(),xnt=hnt(function(){return!Array(1).includes()});fnt({target:"Array",proto:!0,forced:xnt},{includes:function includes(t){return gnt(this,t,arguments.length>1?arguments[1]:void 0)}});_nt("includes")});var Lae=T(function(){"use strict";var Ant=ne(),vnt=Wd(),ynt=C2().indexOf,wnt=Cc(),fP=vnt([].indexOf),qae=!!fP&&1/fP([1],1,-0)<0,bnt=qae||!wnt("indexOf");Ant({target:"Array",proto:!0,forced:bnt},{indexOf:function indexOf(t){var a=arguments.length>1?arguments[1]:void 0;return qae?fP(this,t,a)||0:ynt(this,t,a)}})});var $ae=T(function(){"use strict";var Int=ne(),knt=Ic();Int({target:"Array",stat:!0},{isArray:knt})});var af=T(function(p7a,zae){"use strict";var Cnt=Qe(),Ent=Ua(),Snt=ta(),Bnt=_n(),Uae=ro(),Tnt=mr(),Mnt=ca(),Pnt=or(),_P=Mnt("iterator"),Gae=!1,bp,gP,hP;[].keys&&(hP=[].keys(),"next"in hP?(gP=Uae(Uae(hP)),gP!==Object.prototype&&(bp=gP)):Gae=!0);var Rnt=!Snt(bp)||Cnt(function(){var e={};return bp[_P].call(e)!==e});Rnt?bp={}:Pnt&&(bp=Bnt(bp));Ent(bp[_P])||Tnt(bp,_P,function(){return this});zae.exports={IteratorPrototype:bp,BUGGY_SAFARI_ITERATORS:Gae}});var h6=T(function(d7a,jae){"use strict";var Qnt=af().IteratorPrototype,Dnt=_n(),Nnt=Yo(),Ont=Io(),Fnt=R2(),qnt=function qnt(){return this};jae.exports=function(e,t,a,r){var i=t+" Iterator";return e.prototype=Dnt(Qnt,{next:Nnt(+!r,a)}),Ont(e,i,!1,!0),Fnt[i]=qnt,e}});var A6=T(function(m7a,tre){"use strict";var Lnt=ne(),$nt=Bt(),_6=or(),Xae=jm(),Unt=Ua(),Gnt=h6(),Hae=ro(),Wae=yu(),znt=Io(),jnt=hn(),xP=mr(),Hnt=ca(),Vae=R2(),ere=af(),Wnt=Xae.PROPER,Vnt=Xae.CONFIGURABLE,Kae=ere.IteratorPrototype,x6=ere.BUGGY_SAFARI_ITERATORS,sA=Hnt("iterator"),Jae="keys",uA="values",Zae="entries",Yae=function Yae(){return this};tre.exports=function(e,t,a,r,i,n,o){Gnt(a,t,r);var s=function s(A){if(A===i&&m)return m;if(!x6&&A&&A in p)return p[A];switch(A){case Jae:return function(){return new a(this,A)};case uA:return function(){return new a(this,A)};case Zae:return function(){return new a(this,A)}}return function(){return new a(this)}},u=t+" Iterator",c=!1,p=e.prototype,l=p[sA]||p["@@iterator"]||i&&p[i],m=!x6&&l||s(i),f=t==="Array"&&p.entries||l,g,h,_;if(f&&(g=Hae(f.call(new e)),g!==Object.prototype&&g.next&&(!_6&&Hae(g)!==Kae&&(Wae?Wae(g,Kae):Unt(g[sA])||xP(g,sA,Yae)),znt(g,u,!0,!0),_6&&(Vae[u]=Yae))),Wnt&&i===uA&&l&&l.name!==uA&&(!_6&&Vnt?jnt(p,"name",uA):(c=!0,m=function m(){return $nt(l,this)})),i)if(h={values:s(uA),keys:n?m:s(Jae),entries:s(Zae)},o)for(_ in h)(x6||c||!(_ in p))&&xP(p,_,h[_]);else Lnt({target:t,proto:!0,forced:x6||c},h);return(!_6||o)&&p[sA]!==m&&xP(p,sA,m,{name:i}),Vae[t]=m,h}});var Xd=T(function(f7a,are){"use strict";are.exports=function(e,t){return{value:e,done:t}}});var lA=T(function(g7a,sre){"use strict";var Knt=rn(),AP=ko(),rre=R2(),nre=Fr(),Jnt=Or().f,Znt=A6(),v6=Xd(),Ynt=or(),Xnt=Ut(),ore="Array Iterator",eot=nre.set,tot=nre.getterFor(ore);sre.exports=Znt(Array,"Array",function(e,t){eot(this,{type:ore,target:Knt(e),index:0,kind:t})},function(){var e=tot(this),t=e.target,a=e.index++;if(!t||a>=t.length)return e.target=null,v6(void 0,!0);switch(e.kind){case"keys":return v6(a,!1);case"values":return v6(t[a],!1)}return v6([a,t[a]],!1)},"values");var ire=rre.Arguments=rre.Array;AP("keys");AP("values");AP("entries");if(!Ynt&&Xnt&&ire.name!=="values")try{Jnt(ire,"name",{value:"values"})}catch(e){}});var ure=T(function(){"use strict";var aot=ne(),rot=Oe(),iot=Gm(),not=rn(),oot=Cc(),sot=rot([].join),uot=iot!==Object,lot=uot||!oot("join",",");aot({target:"Array",proto:!0,forced:lot},{join:function join(t){return sot(not(this),t===void 0?",":t)}})});var yP=T(function(x7a,cre){"use strict";var cot=rs(),pot=rn(),dot=ci(),mot=fr(),fot=Cc(),got=Math.min,vP=[].lastIndexOf,lre=!!vP&&1/[1].lastIndexOf(1,-0)<0,hot=fot("lastIndexOf"),_ot=lre||!hot;cre.exports=_ot?function(t){if(lre)return cot(vP,this,arguments)||0;var a=pot(this),r=mot(a);if(r===0)return-1;var i=r-1;for(arguments.length>1&&(i=got(i,dot(arguments[1]))),i<0&&(i=r+i);i>=0;i--)if(i in a&&a[i]===t)return i||0;return-1}:vP});var dre=T(function(){"use strict";var xot=ne(),pre=yP();xot({target:"Array",proto:!0,forced:pre!==[].lastIndexOf},{lastIndexOf:pre})});var mre=T(function(){"use strict";var Aot=ne(),vot=xn().map,yot=N2(),wot=yot("map");Aot({target:"Array",proto:!0,forced:!wot},{map:function map(t){return vot(this,t,arguments.length>1?arguments[1]:void 0)}})});var gre=T(function(){"use strict";var bot=ne(),Iot=Qe(),kot=Vd(),Cot=js(),fre=Array,Eot=Iot(function(){function e(){}return!_instanceof(fre.of.call(e),e)});bot({target:"Array",stat:!0,forced:Eot},{of:function of(){for(var t=0,a=arguments.length,r=new(kot(this)?this:fre)(a);a>t;)Cot(r,t,arguments[t++]);return r.length=a,r}})});var y6=T(function(k7a,hre){"use strict";var Sot=Ut(),Bot=Ic(),Tot=TypeError,Mot=Object.getOwnPropertyDescriptor,Pot=Sot&&!function(){if(this!==void 0)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return _instanceof(e,TypeError)}}();hre.exports=Pot?function(e,t){if(Bot(e)&&!Mot(e,"length").writable)throw new Tot("Cannot set read only .length");return e.length=t}:function(e,t){return e.length=t}});var _re=T(function(){"use strict";var Rot=ne(),Qot=tr(),Dot=fr(),Not=y6(),Oot=Yd(),Fot=Qe(),qot=Fot(function(){return[].push.call({length:0x100000000},1)!==0x100000001}),Lot=function Lot(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(e){return _instanceof(e,TypeError)}},$ot=qot||!Lot();Rot({target:"Array",proto:!0,arity:1,forced:$ot},{push:function push(t){var a=Qot(this),r=Dot(a),i=arguments.length;Oot(r+i);for(var n=0;n=0:s>u;u+=c)u in o&&(i=a(i,o[u],u,n));return i}};yre.exports={left:vre(!1),right:vre(!0)}});var dA=T(function(B7a,wre){"use strict";var pA=et(),Hot=_l(),Wot=On(),w6=function w6(e){return Hot.slice(0,e.length)===e};wre.exports=function(){return w6("Bun/")?"BUN":w6("Cloudflare-Workers")?"CLOUDFLARE":w6("Deno/")?"DENO":w6("Node.js/")?"NODE":pA.Bun&&typeof Bun.version=="string"?"BUN":pA.Deno&&_type_of(Deno.version)=="object"?"DENO":Wot(pA.process)==="process"?"NODE":pA.window&&pA.document?"BROWSER":"REST"}()});var rf=T(function(T7a,bre){"use strict";var Vot=dA();bre.exports=Vot==="NODE"});var kre=T(function(){"use strict";var Kot=ne(),Jot=cA().left,Zot=Cc(),Ire=Al(),Yot=rf(),Xot=!Yot&&Ire>79&&Ire<83,est=Xot||!Zot("reduce");Kot({target:"Array",proto:!0,forced:est},{reduce:function reduce(t){var a=arguments.length;return Jot(this,t,a,a>1?arguments[1]:void 0)}})});var Ere=T(function(){"use strict";var tst=ne(),ast=cA().right,rst=Cc(),Cre=Al(),ist=rf(),nst=!ist&&Cre>79&&Cre<83,ost=nst||!rst("reduceRight");tst({target:"Array",proto:!0,forced:ost},{reduceRight:function reduceRight(t){return ast(this,t,arguments.length,arguments.length>1?arguments[1]:void 0)}})});var Bre=T(function(){"use strict";var sst=ne(),ust=Oe(),lst=Ic(),cst=ust([].reverse),Sre=[1,2];sst({target:"Array",proto:!0,forced:String(Sre)===String(Sre.reverse())},{reverse:function reverse(){return lst(this)&&(this.length=this.length),cst(this)}})});var Pre=T(function(){"use strict";var pst=ne(),Tre=Ic(),dst=Vd(),mst=ta(),Mre=bc(),fst=fr(),gst=rn(),hst=js(),_st=ca(),xst=N2(),Ast=zs(),vst=xst("slice"),yst=_st("species"),wP=Array,wst=Math.max;pst({target:"Array",proto:!0,forced:!vst},{slice:function slice(t,a){var r=gst(this),i=fst(r),n=Mre(t,i),o=Mre(a===void 0?i:a,i),s,u,c;if(Tre(r)&&(s=r.constructor,dst(s)&&(s===wP||Tre(s.prototype))?s=void 0:mst(s)&&(s=s[yst],s===null&&(s=void 0)),s===wP||s===void 0))return Ast(r,n,o);for(u=new(s===void 0?wP:s)(wst(o-n,0)),c=0;n1?arguments[1]:void 0)}})});var b6=T(function($7a,Dre){"use strict";var Qre=zs(),Est=Math.floor,bP=function bP1(e,t){var a=e.length;if(a<8)for(var r=1,i,n;r0;)e[n]=e[--n];n!==r++&&(e[n]=i)}else for(var o=Est(a/2),s=bP(Qre(e,0,o),t),u=bP(Qre(e,o),t),c=s.length,p=u.length,l=0,m=0;l3)){if(Ost)return!0;if(jre)return jre<603;var e="",t,a,r,i;for(t=65;t<76;t++){switch(a=String.fromCharCode(t),t){case 66:case 69:case 70:case 72:r=3;break;case 68:case 71:r=4;break;default:r=2}for(i=0;i<47;i++)e0.push({k:a+i,v:r})}for(e0.sort(function(n,o){return o.v-n.v}),i=0;iUre(a)?1:-1}};Mst({target:"Array",proto:!0,forced:Ust},{sort:function sort(t){t!==void 0&&Pst(t);var a=Rst(this);if(Vre)return t===void 0?Hre(a):Hre(a,t);var r=[],i=$re(a),n,o;for(o=0;oi-u+s;p--)EP(r,p-1)}else if(s>u)for(p=i-u;p>n;p--)l=p+u-1,m=p+s-1,l in r?r[m]=r[l]:EP(r,m);for(p=0;p2?a:fut(t),n=new e(i);i>r;)n[r]=t[r++];return n}});var BP=T(function(aSa,rie){"use strict";var gut=et();rie.exports=function(e,t){var a=gut[e],r=a&&a.prototype;return r&&r[t]}});var iie=T(function(){"use strict";var hut=ne(),_ut=Oe(),xut=Oa(),Aut=rn(),vut=O2(),yut=BP(),wut=ko(),but=Array,Iut=_ut(yut("Array","sort"));hut({target:"Array",proto:!0},{toSorted:function toSorted(t){t!==void 0&&xut(t);var a=Aut(this),r=vut(but,a);return Iut(r,t)}});wut("toSorted")});var nie=T(function(){"use strict";var kut=ne(),Cut=ko(),Eut=Yd(),Sut=fr(),But=bc(),Tut=rn(),Mut=ci(),Put=Array,Rut=Math.max,Qut=Math.min;kut({target:"Array",proto:!0},{toSpliced:function toSpliced(t,a){var r=Tut(this),i=Sut(r),n=But(t,i),o=arguments.length,s=0,u,c,p,l;for(o===0?u=c=0:o===1?(u=0,c=i-n):(u=o-2,c=Qut(Rut(Mut(a),0),i-n)),p=Eut(i+u-c),l=Put(p);s=i||o<0)throw new Vut("Incorrect index");for(var s=new t(i),u=0;ua||u!==u?o*(1/0):o*u}});var RP=T(function(bSa,Aie){"use strict";var plt=PP(),dlt=11920928955078125e-23,mlt=34028234663852886e22,flt=11754943508222875e-54;Aie.exports=Math.fround||function(t){return plt(t,dlt,mlt,flt)}});var yie=T(function(ISa,vie){"use strict";var glt=Array,hlt=Math.abs,Ip=Math.pow,_lt=Math.floor,xlt=Math.log,Alt=Math.LN2,vlt=function vlt(e,t,a){var r=glt(a),i=a*8-t-1,n=(1<>1,s=t===23?Ip(2,-24)-Ip(2,-77):0,u=e<0||e===0&&1/e<0?1:0,c=0,p,l,m;for(e=hlt(e),e!==e||e===1/0?(l=e!==e?1:0,p=n):(p=_lt(xlt(e)/Alt),m=Ip(2,-p),e*m<1&&(p--,m*=2),p+o>=1?e+=s/m:e+=s*Ip(2,1-o),e*m>=2&&(p++,m/=2),p+o>=n?(l=0,p=n):p+o>=1?(l=(e*m-1)*Ip(2,t),p+=o):(l=e*Ip(2,o-1)*Ip(2,t),p=0));t>=8;)r[c++]=l&255,l/=256,t-=8;for(p=p<0;)r[c++]=p&255,p/=256,i-=8;return r[c-1]|=u*128,r},ylt=function ylt(e,t){var a=e.length,r=a*8-t-1,i=(1<>1,o=r-7,s=a-1,u=e[s--],c=u&127,p;for(u>>=7;o>0;)c=c*256+e[s--],o-=8;for(p=c&(1<<-o)-1,c>>=-o,o+=t;o>0;)p=p*256+e[s--],o-=8;if(c===0)c=1-n;else{if(c===i)return p?NaN:u?-1/0:1/0;p+=Ip(2,t),c-=n}return(u?-1:1)*p*Ip(2,c-t)};vie.exports={pack:vlt,unpack:ylt}});var _A=T(function(kSa,Fie){"use strict";var T6=et(),FP=Oe(),QP=Ut(),wlt=mA(),Rie=jm(),blt=hn(),Ilt=bi(),wie=Ec(),DP=Qe(),C6=is(),klt=ci(),Clt=Xo(),S6=fA(),Elt=RP(),Qie=yie(),Slt=ro(),bie=yu(),Blt=f6(),Tlt=zs(),Mlt=Zd(),Plt=Wm(),Die=Io(),qP=Fr(),Rlt=Rie.PROPER,Iie=Rie.CONFIGURABLE,q2="ArrayBuffer",M6="DataView",L2="prototype",Qlt="Wrong length",Nie="Wrong index",kie=qP.getterFor(q2),hA=qP.getterFor(M6),Cie=qP.set,yl=T6[q2],Hs=yl,F2=Hs&&Hs[L2],Sc=T6[M6],of=Sc&&Sc[L2],Eie=Object.prototype,Dlt=T6.Array,B6=T6.RangeError,Nlt=FP(Blt),Olt=FP([].reverse),Oie=Qie.pack,Sie=Qie.unpack,Bie=function Bie(e){return[e&255]},Tie=function Tie(e){return[e&255,e>>8&255]},Mie=function Mie(e){return[e&255,e>>8&255,e>>16&255,e>>24&255]},Pie=function Pie(e){return e[3]<<24|e[2]<<16|e[1]<<8|e[0]},Flt=function Flt(e){return Oie(Elt(e),23,4)},qlt=function qlt(e){return Oie(e,52,8)},E6=function E6(e,t,a){Ilt(e[L2],t,{configurable:!0,get:function get(){return a(this)[t]}})},t0=function t0(e,t,a,r){var i=hA(e),n=S6(a),o=!!r;if(n+t>i.byteLength)throw new B6(Nie);var s=i.bytes,u=n+i.byteOffset,c=Tlt(s,u,u+t);return o?c:Olt(c)},a0=function a0(e,t,a,r,i,n){var o=hA(e),s=S6(a),u=r(+i),c=!!n;if(s+t>o.byteLength)throw new B6(Nie);for(var p=o.bytes,l=s+o.byteOffset,m=0;m>24)},setUint8:function setUint8(t,a){OP(this,t,a<<24>>24)}},{unsafe:!0})):(Hs=function Hs(t){C6(this,F2);var a=S6(t);Cie(this,{type:q2,bytes:Nlt(Dlt(a),0),byteLength:a}),QP||(this.byteLength=a,this.detached=!1)},F2=Hs[L2],Sc=function Sc(t,a,r){C6(this,of),C6(t,F2);var i=kie(t),n=i.byteLength,o=klt(a);if(o<0||o>n)throw new B6("Wrong offset");if(r=r===void 0?n-o:Clt(r),o+r>n)throw new B6(Qlt);Cie(this,{type:M6,buffer:t,byteLength:r,byteOffset:o,bytes:i.bytes}),QP||(this.buffer=t,this.byteLength=r,this.byteOffset=o)},of=Sc[L2],QP&&(E6(Hs,"byteLength",kie),E6(Sc,"buffer",hA),E6(Sc,"byteLength",hA),E6(Sc,"byteOffset",hA)),wie(of,{getInt8:function getInt8(t){return t0(this,1,t)[0]<<24>>24},getUint8:function getUint8(t){return t0(this,1,t)[0]},getInt16:function getInt16(t){var a=t0(this,2,t,arguments.length>1?arguments[1]:!1);return(a[1]<<8|a[0])<<16>>16},getUint16:function getUint16(t){var a=t0(this,2,t,arguments.length>1?arguments[1]:!1);return a[1]<<8|a[0]},getInt32:function getInt32(t){return Pie(t0(this,4,t,arguments.length>1?arguments[1]:!1))},getUint32:function getUint32(t){return Pie(t0(this,4,t,arguments.length>1?arguments[1]:!1))>>>0},getFloat32:function getFloat32(t){return Sie(t0(this,4,t,arguments.length>1?arguments[1]:!1),23)},getFloat64:function getFloat64(t){return Sie(t0(this,8,t,arguments.length>1?arguments[1]:!1),52)},setInt8:function setInt8(t,a){a0(this,1,t,Bie,a)},setUint8:function setUint8(t,a){a0(this,1,t,Bie,a)},setInt16:function setInt16(t,a){a0(this,2,t,Tie,a,arguments.length>2?arguments[2]:!1)},setUint16:function setUint16(t,a){a0(this,2,t,Tie,a,arguments.length>2?arguments[2]:!1)},setInt32:function setInt32(t,a){a0(this,4,t,Mie,a,arguments.length>2?arguments[2]:!1)},setUint32:function setUint32(t,a){a0(this,4,t,Mie,a,arguments.length>2?arguments[2]:!1)},setFloat32:function setFloat32(t,a){a0(this,4,t,Flt,a,arguments.length>2?arguments[2]:!1)},setFloat64:function setFloat64(t,a){a0(this,8,t,qlt,a,arguments.length>2?arguments[2]:!1)}}));var NP,gA,OP;Die(Hs,q2);Die(Sc,M6);Fie.exports={ArrayBuffer:Hs,DataView:Sc}});var Lie=T(function(){"use strict";var Llt=ne(),$lt=et(),Ult=_A(),Glt=nf(),LP="ArrayBuffer",qie=Ult[LP],zlt=$lt[LP];Llt({global:!0,constructor:!0,forced:zlt!==qie},{ArrayBuffer:qie});Glt(LP)});var Ga=T(function(SSa,Jie){"use strict";var jlt=mA(),zP=Ut(),Co=et(),zie=Ua(),Q6=ta(),i0=Ma(),jP=es(),Hlt=zd(),Wlt=hn(),$P=mr(),Vlt=bi(),Klt=ao(),D6=ro(),U2=yu(),Jlt=ca(),Zlt=jd(),jie=Fr(),Hie=jie.enforce,Ylt=jie.get,P6=Co.Int8Array,UP=P6&&P6.prototype,$ie=Co.Uint8ClampedArray,Uie=$ie&&$ie.prototype,Bc=P6&&D6(P6),wl=UP&&D6(UP),Xlt=Object.prototype,HP=Co.TypeError,Gie=Jlt("toStringTag"),GP=Zlt("TYPED_ARRAY_TAG"),R6="TypedArrayConstructor",kp=jlt&&!!U2&&jP(Co.opera)!=="Opera",Wie=!1,ns,r0,$2,Cp={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},WP={BigInt64Array:8,BigUint64Array:8},ect=function ect(t){if(!Q6(t))return!1;var a=jP(t);return a==="DataView"||i0(Cp,a)||i0(WP,a)},Vie=function Vie1(e){var t=D6(e);if(Q6(t)){var a=Ylt(t);return a&&i0(a,R6)?a[R6]:Vie(t)}},Kie=function Kie(e){if(!Q6(e))return!1;var t=jP(e);return i0(Cp,t)||i0(WP,t)},tct=function tct(e){if(Kie(e))return e;throw new HP("Target is not a typed array")},act=function act(e){if(zie(e)&&(!U2||Klt(Bc,e)))return e;throw new HP(Hlt(e)+" is not a typed array constructor")},rct=function rct(e,t,a,r){if(zP){if(a)for(var i in Cp){var n=Co[i];if(n&&i0(n.prototype,e))try{delete n.prototype[e]}catch(o){try{n.prototype[e]=t}catch(s){}}}(!wl[e]||a)&&$P(wl,e,a?t:kp&&UP[e]||t,r)}},ict=function ict(e,t,a){var r,i;if(zP){if(U2){if(a){for(r in Cp)if(i=Co[r],i&&i0(i,e))try{delete i[e]}catch(n){}}if(!Bc[e]||a)try{return $P(Bc,e,a?t:kp&&Bc[e]||t)}catch(n){}else return}for(r in Cp)i=Co[r],i&&(!i[e]||a)&&$P(i,e,t)}};for(ns in Cp)r0=Co[ns],$2=r0&&r0.prototype,$2?Hie($2)[R6]=r0:kp=!1;for(ns in WP)r0=Co[ns],$2=r0&&r0.prototype,$2&&(Hie($2)[R6]=r0);if((!kp||!zie(Bc)||Bc===Function.prototype)&&(Bc=function Bc(){throw new HP("Incorrect invocation")},kp))for(ns in Cp)Co[ns]&&U2(Co[ns],Bc);if((!kp||!wl||wl===Xlt)&&(wl=Bc.prototype,kp))for(ns in Cp)Co[ns]&&U2(Co[ns].prototype,wl);kp&&D6(Uie)!==wl&&U2(Uie,wl);if(zP&&!i0(wl,Gie)){Wie=!0,Vlt(wl,Gie,{configurable:!0,get:function get(){return Q6(this)?this[GP]:void 0}});for(ns in Cp)Co[ns]&&Wlt(Co[ns],GP,ns)}Jie.exports={NATIVE_ARRAY_BUFFER_VIEWS:kp,TYPED_ARRAY_TAG:Wie&&GP,aTypedArray:tct,aTypedArrayConstructor:act,exportTypedArrayMethod:rct,exportTypedArrayStaticMethod:ict,getTypedArrayConstructor:Vie,isView:ect,isTypedArray:Kie,TypedArray:Bc,TypedArrayPrototype:wl}});var Yie=T(function(){"use strict";var nct=ne(),Zie=Ga(),oct=Zie.NATIVE_ARRAY_BUFFER_VIEWS;nct({target:"ArrayBuffer",stat:!0,forced:!oct},{isView:Zie.isView})});var ine=T(function(){"use strict";var sct=ne(),KP=Wd(),uct=Qe(),ane=_A(),Xie=Dt(),ene=bc(),lct=Xo(),JP=ane.ArrayBuffer,VP=ane.DataView,rne=VP.prototype,tne=KP(JP.prototype.slice),cct=KP(rne.getUint8),pct=KP(rne.setUint8),dct=uct(function(){return!new JP(2).slice(1,void 0).byteLength});sct({target:"ArrayBuffer",proto:!0,unsafe:!0,forced:dct},{slice:function slice(t,a){if(tne&&a===void 0)return tne(Xie(this),t);for(var r=Xie(this).byteLength,i=ene(t,r),n=ene(a===void 0?r:a,r),o=new JP(lct(n-i)),s=new VP(this),u=new VP(o),c=0;i>>15,a=e>>>10&sne,r=e&xct;return a===sne?r===0?t===0?1/0:-1/0:NaN:a===0?r*(t===0?une:-une):cne(2,a-15)*(t===0?1+r*lne:-1-r*lne)},vct=_ct(DataView.prototype.getUint16);hct({target:"DataView",proto:!0},{getFloat16:function getFloat16(t){return Act(vct(this,t,arguments.length>1?arguments[1]:!1))}})});var mne=T(function(qSa,dne){"use strict";var yct=es(),wct=TypeError;dne.exports=function(e){if(yct(e)==="DataView")return e;throw new wct("Argument is not a DataView")}});var ZP=T(function(LSa,fne){"use strict";var bct=Math.log,Ict=Math.LN2;fne.exports=Math.log2||function(t){return bct(t)/Ict}});var hne=T(function(){"use strict";var kct=ne(),Cct=Oe(),Ect=mne(),Sct=fA(),Bct=ZP(),gne=MP(),Tct=Math.pow,Mct=65520,Pct=61005353927612305e-21,Rct=0x1000000,YP=1024,Qct=function Qct(e){if(e!==e)return 32256;if(e===0)return(1/e===-1/0)<<15;var t=e<0;if(t&&(e=-e),e>=Mct)return t<<15|31744;if(e2?arguments[2]:!1)}})});var XP=T(function(GSa,Ane){"use strict";var xne=et(),Nct=aA(),Oct=On(),_ne=xne.ArrayBuffer,Fct=xne.TypeError;Ane.exports=_ne&&Nct(_ne.prototype,"byteLength","get")||function(e){if(Oct(e)!=="ArrayBuffer")throw new Fct("ArrayBuffer expected");return e.byteLength}});var eR=T(function(zSa,vne){"use strict";var qct=et(),Lct=mA(),$ct=XP(),Uct=qct.DataView;vne.exports=function(e){if(!Lct||$ct(e)!==0)return!1;try{return new Uct(e),!1}catch(t){return!0}}});var wne=T(function(){"use strict";var Gct=Ut(),zct=bi(),jct=eR(),yne=ArrayBuffer.prototype;Gct&&!("detached"in yne)&&zct(yne,"detached",{configurable:!0,get:function get(){return jct(this)}})});var G2=T(function(WSa,bne){"use strict";var Hct=eR(),Wct=TypeError;bne.exports=function(e){if(Hct(e))throw new Wct("ArrayBuffer is detached");return e}});var tR=T(function(VSa,Ine){"use strict";var Vct=et(),Kct=rf();Ine.exports=function(e){if(Kct){try{return Vct.process.getBuiltinModule(e)}catch(t){}try{return Function('return require("'+e+'")')()}catch(t){}}}});var N6=T(function(KSa,Cne){"use strict";var Jct=et(),Zct=Qe(),aR=Al(),rR=dA(),kne=Jct.structuredClone;Cne.exports=!!kne&&!Zct(function(){if(rR==="DENO"&&aR>92||rR==="NODE"&&aR>94||rR==="BROWSER"&&aR>97)return!1;var e=new ArrayBuffer(8),t=kne(e,{transfer:[e]});return e.byteLength!==0||t.byteLength!==8})});var uR=T(function(JSa,Bne){"use strict";var sR=et(),Yct=tR(),Xct=N6(),ept=sR.structuredClone,Ene=sR.ArrayBuffer,O6=sR.MessageChannel,oR=!1,iR,Sne,F6,nR;if(Xct)oR=function oR(e){ept(e,{transfer:[e]})};else if(Ene)try{O6||(iR=Yct("worker_threads"),iR&&(O6=iR.MessageChannel)),O6&&(Sne=new O6,F6=new Ene(2),nR=function nR(e){Sne.port1.postMessage(null,[e])},F6.byteLength===2&&(nR(F6),F6.byteLength===0&&(oR=nR)))}catch(e){}Bne.exports=oR});var fR=T(function(ZSa,Nne){"use strict";var pR=et(),dR=Oe(),Rne=aA(),tpt=fA(),apt=G2(),rpt=XP(),Tne=uR(),lR=N6(),ipt=pR.structuredClone,Qne=pR.ArrayBuffer,cR=pR.DataView,npt=Math.min,mR=Qne.prototype,Dne=cR.prototype,opt=dR(mR.slice),Mne=Rne(mR,"resizable","get"),Pne=Rne(mR,"maxByteLength","get"),spt=dR(Dne.getInt8),upt=dR(Dne.setInt8);Nne.exports=(lR||Tne)&&function(e,t,a){var r=rpt(e),i=t===void 0?r:tpt(t),n=!Mne||!Mne(e),o;if(apt(e),lR&&(e=ipt(e,{transfer:[e]}),r===i&&(a||n)))return e;if(r>=i&&(!a||n))o=opt(e,0,i);else{var s=a&&!n&&Pne?{maxByteLength:Pne(e)}:void 0;o=new Qne(i,s);for(var u=new cR(e),c=new cR(o),p=npt(i,r),l=0;l=0&&a<=99?a+1900:a;return wpt(this,r)}})});var Wne=T(function(){"use strict";var bpt=ne();bpt({target:"Date",proto:!0},{toGMTString:Date.prototype.toUTCString})});var xA=T(function(c9a,Vne){"use strict";var Ipt=ci(),kpt=ga(),Cpt=Wr(),Ept=RangeError;Vne.exports=function(t){var a=kpt(Cpt(this)),r="",i=Ipt(t);if(i<0||i===1/0)throw new Ept("Wrong number of repetitions");for(;i>0;(i>>>=1)&&(a+=a))i&1&&(r+=a);return r}});var AA=T(function(p9a,Yne){"use strict";var Zne=Oe(),Spt=Xo(),Kne=ga(),Bpt=xA(),Tpt=Wr(),Mpt=Zne(Bpt),Ppt=Zne("".slice),Rpt=Math.ceil,Jne=function Jne(e){return function(t,a,r){var i=Kne(Tpt(t)),n=Spt(a),o=i.length,s=r===void 0?" ":Kne(r),u,c;return n<=o||s===""?i:(u=n-o,c=Mpt(s,Rpt(u/s.length)),c.length>u&&(c=Ppt(c,0,u)),e?i+c:c+i)}};Yne.exports={start:Jne(!1),end:Jne(!0)}});var toe=T(function(d9a,eoe){"use strict";var n0=Oe(),Xne=Qe(),sf=AA().start,Qpt=RangeError,Dpt=isFinite,Npt=Math.abs,Ep=Date.prototype,gR=Ep.toISOString,Opt=n0(Ep.getTime),Fpt=n0(Ep.getUTCDate),qpt=n0(Ep.getUTCFullYear),Lpt=n0(Ep.getUTCHours),$pt=n0(Ep.getUTCMilliseconds),Upt=n0(Ep.getUTCMinutes),Gpt=n0(Ep.getUTCMonth),zpt=n0(Ep.getUTCSeconds);eoe.exports=Xne(function(){return gR.call(new Date(-5e13-1))!=="0385-07-25T07:06:39.999Z"})||!Xne(function(){gR.call(new Date(NaN))})?function(){if(!Dpt(Opt(this)))throw new Qpt("Invalid time value");var t=this,a=qpt(t),r=$pt(t),i=a<0?"-":a>9999?"+":"";return i+sf(Npt(a),i?6:4,0)+"-"+sf(Gpt(t)+1,2,0)+"-"+sf(Fpt(t),2,0)+"T"+sf(Lpt(t),2,0)+":"+sf(Upt(t),2,0)+":"+sf(zpt(t),2,0)+"."+sf(r,3,0)+"Z"}:gR});var roe=T(function(){"use strict";var jpt=ne(),aoe=toe();jpt({target:"Date",proto:!0,forced:Date.prototype.toISOString!==aoe},{toISOString:aoe})});var ioe=T(function(){"use strict";var Hpt=ne(),Wpt=Qe(),Vpt=tr(),Kpt=$x(),Jpt=Wpt(function(){return new Date(NaN).toJSON()!==null||Date.prototype.toJSON.call({toISOString:function toISOString(){return 1}})!==1});Hpt({target:"Date",proto:!0,arity:1,forced:Jpt},{toJSON:function toJSON(t){var a=Vpt(this),r=Kpt(a,"number");return typeof r=="number"&&!isFinite(r)?null:a.toISOString()}})});var ooe=T(function(_9a,noe){"use strict";var Zpt=Dt(),Ypt=$T(),Xpt=TypeError;noe.exports=function(e){if(Zpt(this),e==="string"||e==="default")e="string";else if(e!=="number")throw new Xpt("Incorrect hint");return Ypt(this,e)}});var loe=T(function(){"use strict";var edt=Ma(),tdt=mr(),adt=ooe(),rdt=ca(),soe=rdt("toPrimitive"),uoe=Date.prototype;edt(uoe,soe)||tdt(uoe,soe,adt)});var moe=T(function(){"use strict";var poe=Oe(),idt=mr(),hR=Date.prototype,coe="Invalid Date",doe="toString",ndt=poe(hR[doe]),odt=poe(hR.getTime);String(new Date(NaN))!==coe&&idt(hR,doe,function(){var t=odt(this);return t===t?ndt(this):coe})});var xR=T(function(w9a,xoe){"use strict";var sdt=Ta(),udt=Bt(),ldt=Oe(),cdt=ts(),pdt=Dt(),ddt=Oa(),hoe=wc(),_R=fn(),_oe=ca(),mdt=_oe("asyncDispose"),foe=_oe("dispose"),fdt=ldt([].push),gdt=function gdt(e,t){if(t==="async-dispose"){var a=_R(e,mdt);return a!==void 0||(a=_R(e,foe),a===void 0)?a:function(){var r=this,i=sdt("Promise");return new i(function(n){udt(a,r),n(void 0)})}}return _R(e,foe)},goe=function goe(e,t,a){return arguments.length<3&&!hoe(e)&&(a=ddt(gdt(pdt(e),t))),a===void 0?function(){}:cdt(a,e)};xoe.exports=function(e,t,a,r){var i;if(arguments.length<4){if(hoe(t)&&a==="sync-dispose")return;i=goe(t,a)}else i=goe(void 0,a,r);fdt(e.stack,i)}});var boe=T(function(){"use strict";var hdt=ne(),L6=Ut(),_dt=Ta(),Aoe=Oa(),xdt=is(),voe=mr(),Adt=Ec(),vdt=bi(),yoe=ca(),woe=Fr(),AR=xR(),ydt=_dt("SuppressedError"),wdt=ReferenceError,bdt=yoe("dispose"),Idt=yoe("toStringTag"),U6="DisposableStack",kdt=woe.set,$6=woe.getterFor(U6),vR="sync-dispose",vA="disposed",Cdt="pending",q6=function q6(e){var t=$6(e);if(t.state===vA)throw new wdt(U6+" already disposed");return t},yR=function yR(){kdt(xdt(this,z2),{type:U6,state:Cdt,stack:[]}),L6||(this.disposed=!1)},z2=yR.prototype;Adt(z2,{dispose:function dispose(){var t=$6(this);if(t.state!==vA){t.state=vA,L6||(this.disposed=!0);for(var a=t.stack,r=a.length,i=!1,n;r;){var o=a[--r];a[r]=null;try{o()}catch(s){i?n=new ydt(s,n):(i=!0,n=s)}}if(t.stack=null,i)throw n}},use:function use(t){return AR(q6(this),t,vR),t},adopt:function adopt(t,a){var r=q6(this);return Aoe(a),AR(r,void 0,vR,function(){a(t)}),t},defer:function defer(t){var a=q6(this);Aoe(t),AR(a,void 0,vR,t)},move:function move(){var t=q6(this),a=new yR;return $6(a).stack=t.stack,t.stack=[],t.state=vA,L6||(this.disposed=!0),a}});L6&&vdt(z2,"disposed",{configurable:!0,get:function get(){return $6(this).state===vA}});voe(z2,bdt,z2.dispose,{name:"dispose"});voe(z2,Idt,U6,{nonWritable:!0});hdt({global:!0,constructor:!0},{DisposableStack:yR})});var koe=T(function(){"use strict";var Edt=ne(),yA=Oe(),Sdt=ga(),Bdt=yA("".charAt),Tdt=yA("".charCodeAt),Mdt=yA(/./.exec),Pdt=yA(1.1.toString),Rdt=yA("".toUpperCase),Qdt=/[\w*+\-./@]/,Ioe=function Ioe(e,t){for(var a=Pdt(e,16);a.length=0;r--)if(e[r]!==void 0)try{a=m0t(e[r].iterator,t,a)}catch(i){t="throw",a=i}if(t==="throw")throw a;return a}});var o0=T(function(q9a,ese){"use strict";var f0t=Bt(),g0t=_n(),h0t=hn(),_0t=Ec(),x0t=ca(),Koe=Fr(),A0t=fn(),v0t=af().IteratorPrototype,G6=Xd(),z6=vn(),y0t=Woe(),w0t=x0t("toStringTag"),Joe="IteratorHelper",Zoe="WrapForValidIterator",TR="normal",Voe="throw",b0t=Koe.set,Yoe=function Yoe(e){var t=Koe.getterFor(e?Zoe:Joe);return _0t(g0t(v0t),{next:function next(){var r=t(this);if(e)return r.nextHandler();if(r.done)return G6(void 0,!0);try{var i=r.nextHandler();return r.returnHandlerResult?i:G6(i,r.done)}catch(n){throw r.done=!0,n}},return:function _return(){var a=t(this),r=a.iterator;if(a.done=!0,e){var i=A0t(r,"return");return i?f0t(i,r):G6(void 0,!0)}if(a.inner)try{z6(a.inner.iterator,TR)}catch(n){return z6(r,Voe,n)}if(a.openIters)try{y0t(a.openIters,TR)}catch(n){return z6(r,Voe,n)}return r&&z6(r,TR),G6(void 0,!0)}})},I0t=Yoe(!0),Xoe=Yoe(!1);h0t(Xoe,w0t,"Iterator Helper");ese.exports=function(e,t,a){var r=function r(n,o){o?(o.iterator=n.iterator,o.next=n.next):o=n,o.type=t?Zoe:Joe,o.returnHandlerResult=!!a,o.nextHandler=e,o.counter=0,o.done=!1,b0t(this,o)};return r.prototype=t?I0t:Xoe,r}});var rse=T(function(){"use strict";var k0t=ne(),tse=Bt(),C0t=Oa(),ase=Dt(),E0t=wp(),S0t=o0(),B0t=Array,T0t=S0t(function(){for(;;){var e=this.iterator;if(!e){var t=this.nextIterableIndex++,a=this.iterables;if(t>=a.length){this.done=!0;return}var r=a[t];this.iterables[t]=null,e=this.iterator=tse(r.method,r.iterable),this.next=e.next}var i=ase(tse(this.next,e));if(i.done){this.iterator=null,this.next=null;continue}return i.value}});k0t({target:"Iterator",stat:!0},{concat:function concat(){for(var t=arguments.length,a=B0t(t),r=0;r1?arguments[1]:void 0),f;f=f?f.next:l.first;)for(m(f.value,f.key,this);f&&f.removed;)f=f.previous},has:function has(p){return!!u(this,p)}}),pue(n,a?{get:function get(p){var l=u(this,p);return l&&l.value},set:function set(p,l){return s(this,p===0?0:p,l)}}:{add:function add(p){return s(this,p=p===0?0:p,p)}}),kA&&Kgt(n,"size",{configurable:!0,get:function get(){return o(this).size}}),i},setStrong:function setStrong(e,t,a){var r=t+" Iterator",i=mQ(t),n=mQ(r);e2t(e,t,function(o,s){mue(this,{type:r,target:o,state:i(o),kind:s,last:null})},function(){for(var o=n(this),s=o.kind,u=o.last;u&&u.removed;)u=u.previous;return!o.target||!(o.last=u=u?u.next:o.state.first)?(o.target=null,J6(void 0,!0)):J6(s==="keys"?u.key:s==="values"?u.value:[u.key,u.value],!1)},a?"entries":"values",!a,!0),t2t(t)}}});var hue=T(function(){"use strict";var a2t=IA(),r2t=fQ();a2t("Map",function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}},r2t)});var _ue=T(function(){"use strict";hue()});var gQ=T(function(FBa,xue){"use strict";var Z6=Oe(),CA=Map.prototype;xue.exports={Map:Map,set:Z6(CA.set),get:Z6(CA.get),has:Z6(CA.has),remove:Z6(CA.delete),proto:CA}});var yue=T(function(){"use strict";var i2t=ne(),n2t=Oe(),o2t=Oa(),s2t=Wr(),u2t=Gi(),Y6=gQ(),Aue=or(),l2t=Qe(),vue=Y6.Map,c2t=Y6.has,p2t=Y6.get,d2t=Y6.set,m2t=n2t([].push),f2t=Aue||l2t(function(){return vue.groupBy("ab",function(e){return e}).get("a").length!==1});i2t({target:"Map",stat:!0,forced:Aue||f2t},{groupBy:function groupBy(t,a){s2t(t),o2t(a);var r=new vue,i=0;return u2t(t,function(n){var o=a(n,i++);c2t(r,o)?m2t(p2t(r,o),n):d2t(r,o,[n])}),r}})});var hQ=T(function($Ba,wue){"use strict";var g2t=Math.log;wue.exports=Math.log1p||function(t){var a=+t;return a>-1e-8&&a<1e-8?a-a*a/2:g2t(1+a)}});var Iue=T(function(){"use strict";var h2t=ne(),_2t=hQ(),_Q=Math.acosh,x2t=Math.log,bue=Math.sqrt,A2t=Math.LN2,v2t=!_Q||Math.floor(_Q(Number.MAX_VALUE))!==710||_Q(1/0)!==1/0;h2t({target:"Math",stat:!0,forced:v2t},{acosh:function acosh(t){var a=+t;return a<1?NaN:a>94906265.62425156?x2t(a)+A2t:_2t(a-1+bue(a-1)*bue(a+1))}})});var Eue=T(function(){"use strict";var y2t=ne(),kue=Math.asinh,w2t=Math.log,b2t=Math.sqrt;function Cue(e){var t=+e;return!isFinite(t)||t===0?t:t<0?-Cue(-t):w2t(t+b2t(t*t+1))}var I2t=!(kue&&1/kue(0)>0);y2t({target:"Math",stat:!0,forced:I2t},{asinh:Cue})});var Bue=T(function(){"use strict";var k2t=ne(),Sue=Math.atanh,C2t=Math.log,E2t=!(Sue&&1/Sue(-0)<0);k2t({target:"Math",stat:!0,forced:E2t},{atanh:function atanh(t){var a=+t;return a===0?a:C2t((1+a)/(1-a))/2}})});var Tue=T(function(){"use strict";var S2t=ne(),B2t=k6(),T2t=Math.abs,M2t=Math.pow;S2t({target:"Math",stat:!0},{cbrt:function cbrt(t){var a=+t;return B2t(a)*M2t(T2t(a),1/3)}})});var Mue=T(function(){"use strict";var P2t=ne(),R2t=Math.floor,Q2t=Math.log,D2t=Math.LOG2E;P2t({target:"Math",stat:!0},{clz32:function clz32(t){var a=t>>>0;return a?31-R2t(Q2t(a+.5)*D2t):32}})});var SA=T(function(YBa,Pue){"use strict";var EA=Math.expm1,N2t=Math.exp;Pue.exports=!EA||EA(10)>22025.465794806718||EA(10)<22025.465794806718||EA(-2e-17)!==-2e-17?function(t){var a=+t;return a===0?a:a>-1e-6&&a<1e-6?a+a*a/2:N2t(a)-1}:EA});var Que=T(function(){"use strict";var O2t=ne(),F2t=SA(),Rue=Math.cosh,q2t=Math.abs,xQ=Math.E,L2t=!Rue||Rue(710)===1/0;O2t({target:"Math",stat:!0,forced:L2t},{cosh:function cosh(t){var a=F2t(q2t(t)-1)+1;return(a+1/(a*xQ*xQ))*(xQ/2)}})});var Nue=T(function(){"use strict";var $2t=ne(),Due=SA();$2t({target:"Math",stat:!0,forced:Due!==Math.expm1},{expm1:Due})});var Oue=T(function(){"use strict";var U2t=ne(),G2t=RP();U2t({target:"Math",stat:!0},{fround:G2t})});var Fue=T(function(){"use strict";var z2t=ne(),j2t=PP(),H2t=9765625e-10,W2t=65504,V2t=6103515625e-14;z2t({target:"Math",stat:!0},{f16round:function f16round(t){return j2t(t,H2t,W2t,V2t)}})});var Lue=T(function(){"use strict";var K2t=ne(),que=Math.hypot,J2t=Math.abs,Z2t=Math.sqrt,Y2t=!!que&&que(1/0,NaN)!==1/0;K2t({target:"Math",stat:!0,arity:2,forced:Y2t},{hypot:function hypot(t,a){for(var r=0,i=0,n=arguments.length,o=0,s,u;i0?(u=s/o,r+=u*u):r+=s;return o===1/0?1/0:o*Z2t(r)}})});var Uue=T(function(){"use strict";var X2t=ne(),eht=Qe(),$ue=Math.imul,tht=eht(function(){return $ue(0xffffffff,5)!==-5||$ue.length!==2});X2t({target:"Math",stat:!0,forced:tht},{imul:function imul(t,a){var r=65535,i=+t,n=+a,o=r&i,s=r&n;return 0|o*s+((r&i>>>16)*s+o*(r&n>>>16)<<16>>>0)}})});var AQ=T(function(pTa,Gue){"use strict";var aht=Math.log,rht=Math.LOG10E;Gue.exports=Math.log10||function(t){return aht(t)*rht}});var zue=T(function(){"use strict";var iht=ne(),nht=AQ();iht({target:"Math",stat:!0},{log10:nht})});var jue=T(function(){"use strict";var oht=ne(),sht=hQ();oht({target:"Math",stat:!0},{log1p:sht})});var Hue=T(function(){"use strict";var uht=ne(),lht=ZP();uht({target:"Math",stat:!0},{log2:lht})});var Wue=T(function(){"use strict";var cht=ne(),pht=k6();cht({target:"Math",stat:!0},{sign:pht})});var Jue=T(function(){"use strict";var dht=ne(),mht=Qe(),Vue=SA(),fht=Math.abs,Kue=Math.exp,ght=Math.E,hht=mht(function(){return Math.sinh(-2e-17)!==-2e-17});dht({target:"Math",stat:!0,forced:hht},{sinh:function sinh(t){var a=+t;return fht(a)<1?(Vue(a)-Vue(-a))/2:(Kue(a-1)-Kue(-a-1))*(ght/2)}})});var tle=T(function(){"use strict";var _ht=ne(),xht=Oe(),Aht=Gi(),vht=RangeError,yht=TypeError,wu=1/0,wht=NaN,uf=Math.abs,bQ=Math.pow,Zue=xht([].push),BA=bQ(2,1023),bht=bQ(2,53)-1,Yue=Number.MAX_VALUE,Xue=bQ(2,971),TA={},vQ={},yQ={},wQ={},ele={},X6=function X6(e,t){var a=e+t,r=t-(a-e);return{hi:a,lo:r}};_ht({target:"Math",stat:!0},{sumPrecise:function sumPrecise(t){var a=[],r=0,i=wQ;switch(Aht(t,function(y){if(++r>=bht)throw new vht("Maximum allowed index exceeded");if(typeof y!="number")throw new yht("Value is not a number");i!==TA&&(y!==y?i=TA:y===wu?i=i===vQ?TA:yQ:y===-wu?i=i===yQ?TA:vQ:(y!==0||1/y===wu)&&(i===wQ||i===ele)&&(i=ele,Zue(a,y)))}),i){case TA:return wht;case vQ:return-wu;case yQ:return wu;case wQ:return-0}for(var n=[],o=0,s,u,c,p,l,m,f=0;f=0?n[A]:0;if(A--,uf(o)>1||o>0&&x>0||o<0&&x<0)return o>0?wu:-wu;if(c=X6(o*BA,x/2),p=c.hi,l=c.lo,l*=2,uf(2*p)===wu)return p>0?p===BA&&l===-(Xue/2)&&A>=0&&n[A]<0?Yue:wu:p===-BA&&l===Xue/2&&A>=0&&n[A]>0?-Yue:-wu;l!==0&&(n[++A]=l,l=0),p*=2}for(;A>=0&&(c=X6(p,n[A--]),p=c.hi,l=c.lo,l===0););return A>=0&&(l<0&&n[A]<0||l>0&&n[A]>0)&&(u=l*2,s=p+u,u===s-p&&(p=s)),p}})});var ile=T(function(){"use strict";var Iht=ne(),ale=SA(),rle=Math.exp;Iht({target:"Math",stat:!0},{tanh:function tanh(t){var a=+t,r=ale(a),i=ale(-a);return r===1/0?1:i===1/0?-1:(r-i)/(rle(a)+rle(-a))}})});var nle=T(function(){"use strict";var kht=Io();kht(Math,"Math",!0)});var ole=T(function(){"use strict";var Cht=ne(),Eht=nM();Cht({target:"Math",stat:!0},{trunc:Eht})});var MA=T(function(TTa,sle){"use strict";var Sht=Oe();sle.exports=Sht(1.1.valueOf)});var H2=T(function(MTa,ule){"use strict";ule.exports=" \n\v\f\r \xa0               \u2028\u2029\uFEFF"});var lf=T(function(PTa,cle){"use strict";var Bht=Oe(),Tht=Wr(),Mht=ga(),kQ=H2(),lle=Bht("".replace),Pht=RegExp("^["+kQ+"]+"),Rht=RegExp("(^|[^"+kQ+"])["+kQ+"]+$"),IQ=function IQ(e){return function(t){var a=Mht(Tht(t));return e&1&&(a=lle(a,Pht,"")),e&2&&(a=lle(a,Rht,"$1")),a}};cle.exports={start:IQ(1),end:IQ(2),trim:IQ(3)}});var _le=T(function(){"use strict";var Qht=ne(),CQ=or(),Dht=Ut(),mle=et(),EQ=Wx(),fle=Oe(),Nht=E2(),ple=Ma(),Oht=Zd(),Fht=ao(),qht=Gd(),gle=$x(),Lht=Qe(),$ht=Hd().f,Uht=gn().f,Ght=Or().f,zht=MA(),jht=lf().trim,PA="Number",W2=mle[PA],dle=EQ[PA],SQ=W2.prototype,Hht=mle.TypeError,Wht=fle("".slice),eb=fle("".charCodeAt),Vht=function Vht(e){var t=gle(e,"number");return(typeof t==="undefined"?"undefined":_type_of(t))=="bigint"?t:Kht(t)},Kht=function Kht(e){var t=gle(e,"number"),a,r,i,n,o,s,u,c;if(qht(t))throw new Hht("Cannot convert a Symbol value to a number");if(typeof t=="string"&&t.length>2){if(t=jht(t),a=eb(t,0),a===43||a===45){if(r=eb(t,2),r===88||r===120)return NaN}else if(a===48){switch(eb(t,1)){case 66:case 98:i=2,n=49;break;case 79:case 111:i=8,n=55;break;default:return+t}for(o=Wht(t,2),s=o.length,u=0;un)return NaN;return parseInt(o,i)}}return+t},BQ=Nht(PA,!W2(" 0o1")||!W2("0b1")||W2("+0x1")),Jht=function Jht(e){return Fht(SQ,e)&&Lht(function(){zht(e)})},tb=function tb1(t){var a=arguments.length<1?0:W2(Vht(t));return Jht(this)?Oht(Object(a),this,tb):a};tb.prototype=SQ;BQ&&!CQ&&(SQ.constructor=tb);Qht({global:!0,constructor:!0,wrap:!0,forced:BQ},{Number:tb});var hle=function hle(e,t){for(var a=Dht?$ht(t):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,isFinite,isInteger,isNaN,isSafeInteger,parseFloat,parseInt,fromString,range".split(","),r=0,i;a.length>r;r++)ple(t,i=a[r])&&!ple(e,i)&&Ght(e,i,Uht(t,i))};CQ&&dle&&hle(EQ[PA],dle);(BQ||CQ)&&hle(EQ[PA],W2)});var xle=T(function(){"use strict";var Zht=ne();Zht({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{EPSILON:Math.pow(2,-52)})});var vle=T(function(OTa,Ale){"use strict";var Yht=et(),Xht=Yht.isFinite;Ale.exports=Number.isFinite||function(t){return typeof t=="number"&&Xht(t)}});var yle=T(function(){"use strict";var e1t=ne(),t1t=vle();e1t({target:"Number",stat:!0},{isFinite:t1t})});var ab=T(function(LTa,wle){"use strict";var a1t=ta(),r1t=Math.floor;wle.exports=Number.isInteger||function(t){return!a1t(t)&&isFinite(t)&&r1t(t)===t}});var ble=T(function(){"use strict";var i1t=ne(),n1t=ab();i1t({target:"Number",stat:!0},{isInteger:n1t})});var Ile=T(function(){"use strict";var o1t=ne();o1t({target:"Number",stat:!0},{isNaN:function isNaN1(t){return t!==t}})});var kle=T(function(){"use strict";var s1t=ne(),u1t=ab(),l1t=Math.abs;s1t({target:"Number",stat:!0},{isSafeInteger:function isSafeInteger(t){return u1t(t)&&l1t(t)<=0x1fffffffffffff}})});var Cle=T(function(){"use strict";var c1t=ne();c1t({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{MAX_SAFE_INTEGER:0x1fffffffffffff})});var Ele=T(function(){"use strict";var p1t=ne();p1t({target:"Number",stat:!0,nonConfigurable:!0,nonWritable:!0},{MIN_SAFE_INTEGER:-0x1fffffffffffff})});var TQ=T(function(ZTa,Mle){"use strict";var Tle=et(),d1t=Qe(),m1t=Oe(),f1t=ga(),g1t=lf().trim,h1t=H2(),_1t=m1t("".charAt),rb=Tle.parseFloat,Sle=Tle.Symbol,Ble=Sle&&Sle.iterator,x1t=1/rb(h1t+"-0")!==-1/0||Ble&&!d1t(function(){rb(Object(Ble))});Mle.exports=x1t?function(t){var a=g1t(f1t(t)),r=rb(a);return r===0&&_1t(a,0)==="-"?-0:r}:rb});var Rle=T(function(){"use strict";var A1t=ne(),Ple=TQ();A1t({target:"Number",stat:!0,forced:Number.parseFloat!==Ple},{parseFloat:Ple})});var MQ=T(function(eMa,qle){"use strict";var Ole=et(),v1t=Qe(),y1t=Oe(),w1t=ga(),b1t=lf().trim,Qle=H2(),RA=Ole.parseInt,Dle=Ole.Symbol,Nle=Dle&&Dle.iterator,Fle=/^[+-]?0x/i,I1t=y1t(Fle.exec),k1t=RA(Qle+"08")!==8||RA(Qle+"0x16")!==22||Nle&&!v1t(function(){RA(Object(Nle))});qle.exports=k1t?function(t,a){var r=b1t(w1t(t));return RA(r,a>>>0||(I1t(Fle,r)?16:10))}:RA});var $le=T(function(){"use strict";var C1t=ne(),Lle=MQ();C1t({target:"Number",stat:!0,forced:Number.parseInt!==Lle},{parseInt:Lle})});var Hle=T(function(){"use strict";var E1t=ne(),RQ=Oe(),S1t=ci(),B1t=MA(),T1t=xA(),M1t=AQ(),PQ=Qe(),P1t=RangeError,Ule=String,R1t=isFinite,Q1t=Math.abs,D1t=Math.floor,Gle=Math.pow,N1t=Math.round,Mc=RQ(1.1.toExponential),O1t=RQ(T1t),zle=RQ("".slice),jle=Mc(-69e-12,4)==="-6.9000e-11"&&Mc(1.255,2)==="1.25e+0"&&Mc(12345,3)==="1.235e+4"&&Mc(25,0)==="3e+1",F1t=function F1t(){return PQ(function(){Mc(1,1/0)})&&PQ(function(){Mc(1,-1/0)})},q1t=function q1t(){return!PQ(function(){Mc(1/0,1/0),Mc(NaN,1/0)})},L1t=!jle||!F1t()||!q1t();E1t({target:"Number",proto:!0,forced:L1t},{toExponential:function toExponential(t){var a=B1t(this);if(t===void 0)return Mc(a);var r=S1t(t);if(!R1t(a))return String(a);if(r<0||r>20)throw new P1t("Incorrect fraction digits");if(jle)return Mc(a,r);var i="",n,o,s,u;if(a<0&&(i="-",a=-a),a===0)o=0,n=O1t("0",r+1);else{var c=M1t(a);o=D1t(c);var p=Gle(10,o-r),l=N1t(a/p);2*a>=(2*l+1)*p&&(l+=1),l>=Gle(10,r+1)&&(l/=10,o+=1),n=Ule(l)}return r!==0&&(n=zle(n,0,1)+"."+zle(n,1)),o===0?(s="+",u="0"):(s=o>0?"+":"-",u=Ule(Q1t(o))),n+="e"+s+u,i+n}})});var Yle=T(function(){"use strict";var $1t=ne(),NQ=Oe(),U1t=ci(),G1t=MA(),z1t=xA(),Wle=Qe(),j1t=RangeError,Jle=String,Zle=Math.floor,DQ=NQ(z1t),Vle=NQ("".slice),QA=NQ(1.1.toFixed),K2=function K21(e,t,a){return t===0?a:t%2===1?K2(e,t-1,a*e):K2(e*e,t/2,a)},H1t=function H1t(e){for(var t=0,a=e;a>=4096;)t+=12,a/=4096;for(;a>=2;)t+=1,a/=2;return t},V2=function V2(e,t,a){for(var r=-1,i=a;++r<6;)i+=t*e[r],e[r]=i%1e7,i=Zle(i/1e7)},QQ=function QQ(e,t){for(var a=6,r=0;--a>=0;)r+=e[a],e[a]=Zle(r/t),r=r%t*1e7},Kle=function Kle(e){for(var t=6,a="";--t>=0;)if(a!==""||t===0||e[t]!==0){var r=Jle(e[t]);a=a===""?r:a+DQ("0",7-r.length)+r}return a},W1t=Wle(function(){return QA(8e-5,3)!=="0.000"||QA(.9,0)!=="1"||QA(1.255,2)!=="1.25"||QA(0xde0b6b3a7640080,0)!=="1000000000000000128"})||!Wle(function(){QA({})});$1t({target:"Number",proto:!0,forced:W1t},{toFixed:function toFixed(t){var a=G1t(this),r=U1t(t),i=[0,0,0,0,0,0],n="",o="0",s,u,c,p;if(r<0||r>20)throw new j1t("Incorrect fraction digits");if(a!==a)return"NaN";if(a<=-1e21||a>=1e21)return Jle(a);if(a<0&&(n="-",a=-a),a>1e-21)if(s=H1t(a*K2(2,69,1))-69,u=s<0?a*K2(2,-s,1):a/K2(2,s,1),u*=0x10000000000000,s=52-s,s>0){for(V2(i,0,u),c=r;c>=7;)V2(i,1e7,0),c-=7;for(V2(i,K2(10,c,1),0),c=s-1;c>=23;)QQ(i,1<<23),c-=23;QQ(i,1<0?(p=o.length,o=n+(p<=r?"0."+DQ("0",r-p)+o:Vle(o,0,p-r)+"."+Vle(o,p-r))):o=n+o,o}})});var tce=T(function(){"use strict";var V1t=ne(),K1t=Oe(),Xle=Qe(),ece=MA(),ib=K1t(1.1.toPrecision),J1t=Xle(function(){return ib(1,void 0)!=="1"})||!Xle(function(){ib({})});V1t({target:"Number",proto:!0,forced:J1t},{toPrecision:function toPrecision(t){return t===void 0?ib(ece(this)):ib(ece(this),t)}})});var FQ=T(function(lMa,ice){"use strict";var ace=Ut(),Z1t=Oe(),Y1t=Bt(),X1t=Qe(),OQ=S2(),e_t=jx(),t_t=qx(),a_t=tr(),r_t=Gm(),J2=Object.assign,rce=Object.defineProperty,i_t=Z1t([].concat);ice.exports=!J2||X1t(function(){if(ace&&J2({b:1},J2(rce({},"a",{enumerable:!0,get:function get(){rce(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var e={},t={},a=Symbol("assign detection"),r="abcdefghijklmnopqrst";return e[a]=7,r.split("").forEach(function(i){t[i]=i}),J2({},e)[a]!==7||OQ(J2({},t)).join("")!==r})?function(t,a){for(var r=a_t(t),i=arguments.length,n=1,o=e_t.f,s=t_t.f;i>n;)for(var u=r_t(arguments[n++]),c=o?i_t(OQ(u),o(u)):OQ(u),p=c.length,l=0,m;p>l;)m=c[l++],(!ace||Y1t(s,u,m))&&(r[m]=u[m]);return r}:J2});var oce=T(function(){"use strict";var n_t=ne(),nce=FQ();n_t({target:"Object",stat:!0,arity:2,forced:Object.assign!==nce},{assign:nce})});var sce=T(function(){"use strict";var o_t=ne(),s_t=Ut(),u_t=_n();o_t({target:"Object",stat:!0,sham:!s_t},{create:u_t})});var DA=T(function(fMa,lce){"use strict";var l_t=or(),c_t=et(),p_t=Qe(),uce=I6();lce.exports=l_t||!p_t(function(){if(!(uce&&uce<535)){var e=Math.random();__defineSetter__.call(null,e,function(){}),delete c_t[e]}})});var cce=T(function(){"use strict";var d_t=ne(),m_t=Ut(),f_t=DA(),g_t=Oa(),h_t=tr(),__t=Or();m_t&&d_t({target:"Object",proto:!0,forced:f_t},{__defineGetter__:function __defineGetter__(t,a){__t.f(h_t(this),t,{get:g_t(a),enumerable:!0,configurable:!0})}})});var dce=T(function(){"use strict";var x_t=ne(),A_t=Ut(),pce=L4().f;x_t({target:"Object",stat:!0,forced:Object.defineProperties!==pce,sham:!A_t},{defineProperties:pce})});var fce=T(function(){"use strict";var v_t=ne(),y_t=Ut(),mce=Or().f;v_t({target:"Object",stat:!0,forced:Object.defineProperty!==mce,sham:!y_t},{defineProperty:mce})});var gce=T(function(){"use strict";var w_t=ne(),b_t=Ut(),I_t=DA(),k_t=Oa(),C_t=tr(),E_t=Or();b_t&&w_t({target:"Object",proto:!0,forced:I_t},{__defineSetter__:function __defineSetter__1(t,a){E_t.f(C_t(this),t,{set:k_t(a),enumerable:!0,configurable:!0})}})});var qQ=T(function(bMa,vce){"use strict";var _ce=Ut(),S_t=Qe(),xce=Oe(),B_t=ro(),T_t=S2(),M_t=rn(),P_t=qx().f,Ace=xce(P_t),R_t=xce([].push),Q_t=_ce&&S_t(function(){var e=Object.create(null);return e[2]=2,!Ace(e,2)}),hce=function hce(e){return function(t){for(var a=M_t(t),r=T_t(a),i=Q_t&&B_t(a)===null,n=r.length,o=0,s=[],u;n>o;)u=r[o++],(!_ce||(i?u in a:Ace(a,u)))&&R_t(s,e?[u,a[u]]:a[u]);return s}};vce.exports={entries:hce(!0),values:hce(!1)}});var yce=T(function(){"use strict";var D_t=ne(),N_t=qQ().entries;D_t({target:"Object",stat:!0},{entries:function entries(t){return N_t(t)}})});var wce=T(function(){"use strict";var O_t=ne(),F_t=s0(),q_t=Qe(),L_t=ta(),$_t=u0().onFreeze,LQ=Object.freeze,U_t=q_t(function(){LQ(1)});O_t({target:"Object",stat:!0,forced:U_t,sham:!F_t},{freeze:function freeze(t){return LQ&&L_t(t)?LQ($_t(t)):t}})});var bce=T(function(){"use strict";var G_t=ne(),z_t=Gi(),j_t=js();G_t({target:"Object",stat:!0},{fromEntries:function fromEntries(t){var a={};return z_t(t,function(r,i){j_t(a,r,i)},{AS_ENTRIES:!0}),a}})});var Cce=T(function(){"use strict";var H_t=ne(),W_t=Qe(),V_t=rn(),Ice=gn().f,kce=Ut(),K_t=!kce||W_t(function(){Ice(1)});H_t({target:"Object",stat:!0,forced:K_t,sham:!kce},{getOwnPropertyDescriptor:function getOwnPropertyDescriptor(t,a){return Ice(V_t(t),a)}})});var Ece=T(function(){"use strict";var J_t=ne(),Z_t=Ut(),Y_t=N4(),X_t=rn(),ext=gn(),txt=js();J_t({target:"Object",stat:!0,sham:!Z_t},{getOwnPropertyDescriptors:function getOwnPropertyDescriptors(t){for(var a=X_t(t),r=ext.f,i=Y_t(a),n={},o=0,s,u;i.length>o;)u=r(a,s=i[o++]),u!==void 0&&txt(n,s,u);return n}})});var Sce=T(function(){"use strict";var axt=ne(),rxt=Qe(),ixt=G4().f,nxt=rxt(function(){return!Object.getOwnPropertyNames(1)});axt({target:"Object",stat:!0,forced:nxt},{getOwnPropertyNames:ixt})});var Tce=T(function(){"use strict";var oxt=ne(),sxt=Qe(),uxt=tr(),Bce=ro(),lxt=n6(),cxt=sxt(function(){Bce(1)});oxt({target:"Object",stat:!0,forced:cxt,sham:!lxt},{getPrototypeOf:function getPrototypeOf(t){return Bce(uxt(t))}})});var Pce=T(function(){"use strict";var pxt=ne(),dxt=js(),mxt=Ta(),fxt=Oe(),gxt=Oa(),hxt=Wr(),_xt=Ap(),xxt=Gi(),Axt=Qe(),Mce=Object.groupBy,vxt=mxt("Object","create"),yxt=fxt([].push),wxt=!Mce||Axt(function(){return Mce("ab",function(e){return e}).a.length!==1});pxt({target:"Object",stat:!0,forced:wxt},{groupBy:function groupBy(t,a){hxt(t),gxt(a);var r=vxt(null),i=0;return xxt(t,function(n){var o=_xt(a(n,i++));o in r?yxt(r[o],n):dxt(r,o,[n])}),r}})});var Rce=T(function(){"use strict";var bxt=ne(),Ixt=Ma();bxt({target:"Object",stat:!0},{hasOwn:Ixt})});var $Q=T(function(UMa,Qce){"use strict";Qce.exports=Object.is||function(t,a){return t===a?t!==0||1/t===1/a:t!==t&&a!==a}});var Dce=T(function(){"use strict";var kxt=ne(),Cxt=$Q();kxt({target:"Object",stat:!0},{is:Cxt})});var Oce=T(function(){"use strict";var Ext=ne(),Nce=K6();Ext({target:"Object",stat:!0,forced:Object.isExtensible!==Nce},{isExtensible:Nce})});var qce=T(function(){"use strict";var Sxt=ne(),Bxt=Qe(),Txt=ta(),Mxt=On(),Fce=W6(),UQ=Object.isFrozen,Pxt=Fce||Bxt(function(){UQ(1)});Sxt({target:"Object",stat:!0,forced:Pxt},{isFrozen:function isFrozen(t){return!Txt(t)||Fce&&Mxt(t)==="ArrayBuffer"?!0:UQ?UQ(t):!1}})});var $ce=T(function(){"use strict";var Rxt=ne(),Qxt=Qe(),Dxt=ta(),Nxt=On(),Lce=W6(),GQ=Object.isSealed,Oxt=Lce||Qxt(function(){GQ(1)});Rxt({target:"Object",stat:!0,forced:Oxt},{isSealed:function isSealed(t){return!Dxt(t)||Lce&&Nxt(t)==="ArrayBuffer"?!0:GQ?GQ(t):!1}})});var Gce=T(function(){"use strict";var Fxt=ne(),qxt=tr(),Uce=S2(),Lxt=Qe(),$xt=Lxt(function(){Uce(1)});Fxt({target:"Object",stat:!0,forced:$xt},{keys:function keys(t){return Uce(qxt(t))}})});var zce=T(function(){"use strict";var Uxt=ne(),Gxt=Ut(),zxt=DA(),jxt=tr(),Hxt=Ap(),Wxt=ro(),Vxt=gn().f;Gxt&&Uxt({target:"Object",proto:!0,forced:zxt},{__lookupGetter__:function __lookupGetter__(t){var a=jxt(this),r=Hxt(t),i;do if(i=Vxt(a,r))return i.get;while(a=Wxt(a))}})});var jce=T(function(){"use strict";var Kxt=ne(),Jxt=Ut(),Zxt=DA(),Yxt=tr(),Xxt=Ap(),eAt=ro(),tAt=gn().f;Jxt&&Kxt({target:"Object",proto:!0,forced:Zxt},{__lookupSetter__:function __lookupSetter__(t){var a=Yxt(this),r=Xxt(t),i;do if(i=tAt(a,r))return i.set;while(a=eAt(a))}})});var Hce=T(function(){"use strict";var aAt=ne(),rAt=ta(),iAt=u0().onFreeze,nAt=s0(),oAt=Qe(),zQ=Object.preventExtensions,sAt=oAt(function(){zQ(1)});aAt({target:"Object",stat:!0,forced:sAt,sham:!nAt},{preventExtensions:function preventExtensions(t){return zQ&&rAt(t)?zQ(iAt(t)):t}})});var Zce=T(function(){"use strict";var uAt=Ut(),lAt=bi(),cAt=ta(),pAt=$M(),dAt=tr(),mAt=Wr(),Wce=Object.getPrototypeOf,Vce=Object.setPrototypeOf,Kce=Object.prototype,Jce="__proto__";if(uAt&&Wce&&Vce&&!(Jce in Kce))try{lAt(Kce,Jce,{configurable:!0,get:function get(){return Wce(dAt(this))},set:function set(t){var a=mAt(this);pAt(t)&&cAt(a)&&Vce(a,t)}})}catch(e){}});var Yce=T(function(){"use strict";var fAt=ne(),gAt=ta(),hAt=u0().onFreeze,_At=s0(),xAt=Qe(),jQ=Object.seal,AAt=xAt(function(){jQ(1)});fAt({target:"Object",stat:!0,forced:AAt,sham:!_At},{seal:function seal(t){return jQ&&gAt(t)?jQ(hAt(t)):t}})});var Xce=T(function(){"use strict";var vAt=ne(),yAt=yu();vAt({target:"Object",stat:!0},{setPrototypeOf:yAt})});var tpe=T(function(pPa,epe){"use strict";var wAt=F4(),bAt=es();epe.exports=wAt?({}).toString:function(){return"[object "+bAt(this)+"]"}});var ape=T(function(){"use strict";var IAt=F4(),kAt=mr(),CAt=tpe();IAt||kAt(Object.prototype,"toString",CAt,{unsafe:!0})});var rpe=T(function(){"use strict";var EAt=ne(),SAt=qQ().values;EAt({target:"Object",stat:!0},{values:function values(t){return SAt(t)}})});var npe=T(function(){"use strict";var BAt=ne(),ipe=TQ();BAt({global:!0,forced:parseFloat!==ipe},{parseFloat:ipe})});var spe=T(function(){"use strict";var TAt=ne(),ope=MQ();TAt({global:!0,forced:parseInt!==ope},{parseInt:ope})});var nb=T(function(vPa,upe){"use strict";var MAt=Vd(),PAt=zd(),RAt=TypeError;upe.exports=function(e){if(MAt(e))return e;throw new RAt(PAt(e)+" is not a constructor")}});var NA=T(function(yPa,cpe){"use strict";var lpe=Dt(),QAt=nb(),DAt=wc(),NAt=ca(),OAt=NAt("species");cpe.exports=function(e,t){var a=lpe(e).constructor,r;return a===void 0||DAt(r=lpe(a)[OAt])?t:QAt(r)}});var Ws=T(function(wPa,ppe){"use strict";var FAt=TypeError;ppe.exports=function(e,t){if(e1?Uyt(arguments,1):[],a=Gyt.f(this),r=Mde(function(){return $yt(zyt(e),void 0,t)});return(r.error?a.reject:a.resolve)(r.value),a.promise}})});var Rde=T(function(){"use strict";var Hyt=ne(),Wyt=Pc();Hyt({target:"Promise",stat:!0},{withResolvers:function withResolvers(){var t=Wyt.f(this);return{promise:t.promise,resolve:t.resolve,reject:t.reject}}})});var CD=T(function(sRa,$de){"use strict";var Fde=et(),qde=Lx(),Lde=Ua(),Vyt=_n(),gb=ro(),Kyt=mr(),Jyt=ca(),Zyt=or(),Qde="USE_FUNCTION_CONSTRUCTOR",Dde=Jyt("asyncIterator"),Nde=Fde.AsyncIterator,Ode=qde.AsyncIteratorPrototype,Rc,kD;if(Ode)Rc=Ode;else if(Lde(Nde))Rc=Nde.prototype;else if(qde[Qde]||Fde[Qde])try{kD=gb(gb(gb(Function("return async function*(){}()")()))),gb(kD)===Object.prototype&&(Rc=kD)}catch(e){}Rc?Zyt&&(Rc=Vyt(Rc)):Rc={};Lde(Rc[Dde])||Kyt(Rc,Dde,function(){return this});$de.exports=Rc});var SD=T(function(uRa,Jde){"use strict";var Ude=Bt(),Gde=Dt(),Yyt=_n(),Xyt=fn(),e5t=Ec(),Hde=Fr(),t5t=vn(),a5t=Ta(),r5t=CD(),Wde=Xd(),ED=a5t("Promise"),Vde="AsyncFromSyncIterator",i5t=Hde.set,zde=Hde.getterFor(Vde),jde=function jde(e,t,a,r,i){var n=e.done;ED.resolve(e.value).then(function(o){t(Wde(o,n))},function(o){if(!n&&i)try{t5t(r,"throw",o)}catch(s){o=s}a(o)})},Kde=function Kde(t){t.type=Vde,i5t(this,t)};Kde.prototype=e5t(Yyt(r5t),{next:function next(){var t=zde(this);return new ED(function(a,r){var i=Gde(Ude(t.next,t.iterator));jde(i,a,r,t.iterator,!0)})},return:function _return(){var e=zde(this).iterator;return new ED(function(t,a){var r=Xyt(e,"return");if(r===void 0)return t(Wde(void 0,!0));var i=Gde(Ude(r,e));jde(i,t,a,e)})}});Jde.exports=Kde});var Yde=T(function(lRa,Zde){"use strict";var n5t=Bt(),o5t=SD(),s5t=Dt(),u5t=ef(),l5t=qn(),c5t=fn(),p5t=ca(),d5t=p5t("asyncIterator");Zde.exports=function(e,t){var a=arguments.length<2?c5t(e,d5t):t;return a?s5t(n5t(a,e)):new o5t(l5t(u5t(e)))}});var e0e=T(function(cRa,Xde){"use strict";var m5t=Bt(),f5t=Ta(),g5t=fn();Xde.exports=function(e,t,a,r){try{var i=g5t(e,"return");if(i)return f5t("Promise").resolve(m5t(i,e)).then(function(){t(a)},function(n){r(n)})}catch(n){return r(n)}t(a)}});var a0e=T(function(pRa,t0e){"use strict";var h5t=Bt(),_5t=Oa(),BD=Dt(),x5t=ta(),A5t=Yd(),v5t=Ta(),y5t=qn(),TD=e0e(),zA=function zA(e){var t=e===0,a=e===1,r=e===2,i=e===3;return function(n,o,s){BD(n);var u=o!==void 0;(u||!t)&&_5t(o);var c=y5t(n),p=v5t("Promise"),l=c.iterator,m=c.next,f=0;return new p(function(g,h){var _=function _(x){TD(l,h,x,h)},A=function A1(){try{if(u)try{A5t(f)}catch(x){_(x)}p.resolve(BD(h5t(m,l))).then(function(x){try{if(BD(x).done)t?(s.length=f,g(s)):g(i?!1:r||void 0);else{var y=x.value;try{if(u){var v=o(y,f),I=function I(b){if(a)A();else if(r)b?A():TD(l,g,!1,h);else if(t)try{s[f++]=b,A()}catch(w){_(w)}else b?TD(l,g,i||y,h):A()};x5t(v)?p.resolve(v).then(I,_):I(v)}else s[f++]=y,A()}catch(b){_(b)}}}catch(b){h(b)}},h)}catch(x){h(x)}};A()})}};t0e.exports={toArray:zA(0),forEach:zA(1),every:zA(2),some:zA(3),find:zA(4)}});var s0e=T(function(dRa,o0e){"use strict";var w5t=ts(),r0e=Oe(),b5t=tr(),I5t=Vd(),k5t=Yde(),C5t=ef(),E5t=qn(),S5t=wp(),B5t=fn(),T5t=Ta(),M5t=BP(),P5t=ca(),R5t=SD(),Q5t=a0e().toArray,D5t=P5t("asyncIterator"),i0e=r0e(M5t("Array","values")),N5t=r0e(i0e([]).next),O5t=function O5t(){return new n0e(this)},n0e=function n0e(e){this.iterator=i0e(e)};n0e.prototype.next=function(){return N5t(this.iterator)};o0e.exports=function(t){var a=this,r=arguments.length,i=r>1?arguments[1]:void 0,n=r>2?arguments[2]:void 0;return new(T5t("Promise"))(function(o){var s=b5t(t);i!==void 0&&(i=w5t(i,n));var u=B5t(s,D5t),c=u?void 0:S5t(s)||O5t,p=I5t(a)?new a:[],l=u?k5t(s,u):new R5t(E5t(C5t(s,c)));o(Q5t(l,i,p))})}});var l0e=T(function(){"use strict";var F5t=ne(),q5t=s0e(),L5t=Qe(),u0e=Array.fromAsync,$5t=!u0e||L5t(function(){var e=0;return u0e.call(function(){return e++,[]},{length:0}),e!==1});F5t({target:"Array",stat:!0,forced:$5t},{fromAsync:q5t})});var _0e=T(function(){"use strict";var U5t=ne(),_b=Ut(),m0e=Ta(),c0e=Oa(),G5t=is(),f0e=mr(),z5t=Ec(),j5t=bi(),g0e=ca(),h0e=Fr(),MD=xR(),p0e=Al(),d0e=m0e("Promise"),H5t=m0e("SuppressedError"),W5t=ReferenceError,V5t=g0e("asyncDispose"),K5t=g0e("toStringTag"),Ab="AsyncDisposableStack",J5t=h0e.set,xb=h0e.getterFor(Ab),PD="async-dispose",jA="disposed",Z5t="pending",hb=function hb(e){var t=xb(e);if(t.state===jA)throw new W5t(Ab+" already disposed");return t},RD=function RD(){J5t(G5t(this,ih),{type:Ab,state:Z5t,stack:[]}),_b||(this.disposed=!1)},ih=RD.prototype;z5t(ih,{disposeAsync:function disposeAsync(){var t=this;return new d0e(function(a,r){var i=xb(t);if(i.state===jA)return a(void 0);i.state=jA,_b||(t.disposed=!0);var n=i.stack,o=n.length,s=!1,u,c=function c(l){s?u=new H5t(l,u):(s=!0,u=l),p()},p=function p6(){if(o){var l=n[--o];n[o]=null;try{d0e.resolve(l()).then(p,c)}catch(m){c(m)}}else i.stack=null,s?r(u):a(void 0)};p()})},use:function use(t){return MD(hb(this),t,PD),t},adopt:function adopt(t,a){var r=hb(this);return c0e(a),MD(r,void 0,PD,function(){return a(t)}),t},defer:function defer(t){var a=hb(this);c0e(t),MD(a,void 0,PD,t)},move:function move(){var t=hb(this),a=new RD;return xb(a).stack=t.stack,t.stack=[],t.state=jA,_b||(this.disposed=!0),a}});_b&&j5t(ih,"disposed",{configurable:!0,get:function get(){return xb(this).state===jA}});f0e(ih,V5t,ih.disposeAsync,{name:"disposeAsync"});f0e(ih,K5t,Ab,{nonWritable:!0});var Y5t=p0e&&p0e<136;U5t({global:!0,constructor:!0,forced:Y5t},{AsyncDisposableStack:RD})});var y0e=T(function(){"use strict";var X5t=Bt(),ewt=mr(),twt=Ta(),awt=fn(),rwt=Ma(),iwt=ca(),x0e=CD(),A0e=iwt("asyncDispose"),v0e=twt("Promise");rwt(x0e,A0e)||ewt(x0e,A0e,function(){var e=this;return new v0e(function(t,a){var r=awt(e,"return");r?v0e.resolve(X5t(r,e)).then(function(){t(void 0)},a):t(void 0)})})});var w0e=T(function(){"use strict";var nwt=ne(),owt=rs(),swt=Oa(),uwt=Dt(),lwt=Qe(),cwt=!lwt(function(){Reflect.apply(function(){})});nwt({target:"Reflect",stat:!0,forced:cwt},{apply:function apply(t,a,r){return owt(swt(t),a,uwt(r))}})});var B0e=T(function(){"use strict";var pwt=ne(),dwt=Ta(),QD=rs(),mwt=bR(),b0e=nb(),fwt=Dt(),I0e=ta(),gwt=_n(),C0e=Qe(),DD=dwt("Reflect","construct"),hwt=Object.prototype,_wt=[].push,E0e=C0e(function(){function e(){}return!_instanceof(DD(function(){},[],e),e)}),S0e=!C0e(function(){DD(function(){})}),k0e=E0e||S0e;pwt({target:"Reflect",stat:!0,forced:k0e,sham:k0e},{construct:function construct(t,a){b0e(t),fwt(a);var r=arguments.length<3?t:b0e(arguments[2]);if(S0e&&!E0e)return DD(t,a,r);if(t===r){switch(a.length){case 0:return new t;case 1:return new t(a[0]);case 2:return new t(a[0],a[1]);case 3:return new t(a[0],a[1],a[2]);case 4:return new t(a[0],a[1],a[2],a[3])}var i=[null];return QD(_wt,i,a),new(QD(mwt,t,i))}var n=r.prototype,o=gwt(I0e(n)?n:hwt),s=QD(t,o,a);return I0e(s)?s:o}})});var P0e=T(function(){"use strict";var xwt=ne(),Awt=Ut(),T0e=Dt(),vwt=Ap(),M0e=Or(),ywt=Qe(),wwt=ywt(function(){Reflect.defineProperty(M0e.f({},1,{value:1}),1,{value:2})});xwt({target:"Reflect",stat:!0,forced:wwt,sham:!Awt},{defineProperty:function defineProperty(t,a,r){T0e(t);var i=vwt(a);T0e(r);try{return M0e.f(t,i,r),!0}catch(n){return!1}}})});var R0e=T(function(){"use strict";var bwt=ne(),Iwt=Dt(),kwt=gn().f;bwt({target:"Reflect",stat:!0},{deleteProperty:function deleteProperty(t,a){var r=kwt(Iwt(t),a);return r&&!r.configurable?!1:delete t[a]}})});var ND=T(function(ERa,D0e){"use strict";var Q0e=Ma();D0e.exports=function(e){return e!==void 0&&(Q0e(e,"value")||Q0e(e,"writable"))}});var O0e=T(function(){"use strict";var Cwt=ne(),Ewt=Bt(),Swt=ta(),Bwt=Dt(),Twt=ND(),Mwt=gn(),Pwt=ro();function N0e(e,t){var a=arguments.length<3?e:arguments[2],r,i;if(Bwt(e)===a)return e[t];if(r=Mwt.f(e,t),r)return Twt(r)?r.value:r.get===void 0?void 0:Ewt(r.get,a);if(Swt(i=Pwt(e)))return N0e(i,t,a)}Cwt({target:"Reflect",stat:!0},{get:N0e})});var F0e=T(function(){"use strict";var Rwt=ne(),Qwt=Ut(),Dwt=Dt(),Nwt=gn();Rwt({target:"Reflect",stat:!0,sham:!Qwt},{getOwnPropertyDescriptor:function getOwnPropertyDescriptor(t,a){return Nwt.f(Dwt(t),a)}})});var q0e=T(function(){"use strict";var Owt=ne(),Fwt=Dt(),qwt=ro(),Lwt=n6();Owt({target:"Reflect",stat:!0,sham:!Lwt},{getPrototypeOf:function getPrototypeOf(t){return qwt(Fwt(t))}})});var L0e=T(function(){"use strict";var $wt=ne();$wt({target:"Reflect",stat:!0},{has:function has(t,a){return a in t}})});var $0e=T(function(){"use strict";var Uwt=ne(),Gwt=Dt(),zwt=K6();Uwt({target:"Reflect",stat:!0},{isExtensible:function isExtensible(t){return Gwt(t),zwt(t)}})});var U0e=T(function(){"use strict";var jwt=ne(),Hwt=N4();jwt({target:"Reflect",stat:!0},{ownKeys:Hwt})});var G0e=T(function(){"use strict";var Wwt=ne(),Vwt=Ta(),Kwt=Dt(),Jwt=s0();Wwt({target:"Reflect",stat:!0,sham:!Jwt},{preventExtensions:function preventExtensions(t){Kwt(t);try{var a=Vwt("Object","preventExtensions");return a&&a(t),!0}catch(r){return!1}}})});var V0e=T(function(){"use strict";var Zwt=ne(),Ywt=Bt(),Xwt=Dt(),z0e=ta(),e3t=ND(),t3t=Qe(),OD=Or(),j0e=gn(),a3t=ro(),H0e=Yo();function W0e(e,t,a){var r=arguments.length<4?e:arguments[3],i=j0e.f(Xwt(e),t),n,o,s;if(!i){if(z0e(o=a3t(e)))return W0e(o,t,a,r);i=H0e(0)}if(e3t(i)){if(i.writable===!1||!z0e(r))return!1;if(n=j0e.f(r,t)){if(n.get||n.set||n.writable===!1)return!1;n.value=a,OD.f(r,t,n)}else OD.f(r,t,H0e(0,a))}else{if(s=i.set,s===void 0)return!1;Ywt(s,r,a)}return!0}var r3t=t3t(function(){var e=function e(){},t=OD.f(new e,"a",{configurable:!0});return Reflect.set(e.prototype,"a",1,t)!==!1});Zwt({target:"Reflect",stat:!0,forced:r3t},{set:W0e})});var J0e=T(function(){"use strict";var i3t=ne(),n3t=Dt(),o3t=UM(),K0e=yu();K0e&&i3t({target:"Reflect",stat:!0},{setPrototypeOf:function setPrototypeOf(t,a){n3t(t),o3t(a);try{return K0e(t,a),!0}catch(r){return!1}}})});var Z0e=T(function(){"use strict";var s3t=ne(),u3t=et(),l3t=Io();s3t({global:!0},{Reflect:{}});l3t(u3t.Reflect,"Reflect",!0)});var HA=T(function(VRa,Y0e){"use strict";var c3t=ta(),p3t=On(),d3t=ca(),m3t=d3t("match");Y0e.exports=function(e){var t;return c3t(e)&&((t=e[m3t])!==void 0?!!t:p3t(e)==="RegExp")}});var FD=T(function(KRa,eme){"use strict";var f3t=et(),g3t=Qe(),X0e=f3t.RegExp,h3t=!g3t(function(){var e=!0;try{X0e(".","d")}catch(u){e=!1}var t={},a="",r=e?"dgimsy":"gimsy",i=function i(u,c){Object.defineProperty(t,u,{get:function get(){return a+=c,!0}})},n={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};e&&(n.hasIndices="d");for(var o in n)i(o,n[o]);var s=Object.getOwnPropertyDescriptor(X0e.prototype,"flags").get.call(t);return s!==r||a!==r});eme.exports={correct:h3t}});var vb=T(function(JRa,tme){"use strict";var _3t=Dt();tme.exports=function(){var e=_3t(this),t="";return e.hasIndices&&(t+="d"),e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.unicodeSets&&(t+="v"),e.sticky&&(t+="y"),t}});var c0=T(function(ZRa,rme){"use strict";var x3t=Bt(),A3t=Ma(),v3t=ao(),ame=FD(),y3t=vb(),w3t=RegExp.prototype;rme.exports=ame.correct?function(e){return e.flags}:function(e){return!ame.correct&&v3t(w3t,e)&&!A3t(e,"flags")?x3t(y3t,e):e.flags}});var WA=T(function(YRa,ime){"use strict";var qD=Qe(),b3t=et(),LD=b3t.RegExp,$D=qD(function(){var e=LD("a","y");return e.lastIndex=2,e.exec("abcd")!==null}),I3t=$D||qD(function(){return!LD("a","y").sticky}),k3t=$D||qD(function(){var e=LD("^r","gy");return e.lastIndex=2,e.exec("str")!==null});ime.exports={BROKEN_CARET:k3t,MISSED_STICKY:I3t,UNSUPPORTED_Y:$D}});var yb=T(function(XRa,nme){"use strict";var C3t=Qe(),E3t=et(),S3t=E3t.RegExp;nme.exports=C3t(function(){var e=S3t(".","s");return!(e.dotAll&&e.test("\n")&&e.flags==="s")})});var UD=T(function(eQa,ome){"use strict";var B3t=Qe(),T3t=et(),M3t=T3t.RegExp;ome.exports=B3t(function(){var e=M3t("(?b)","g");return e.exec("b").groups.a!=="b"||"b".replace(e,"$c")!=="bc"})});var hme=T(function(){"use strict";var P3t=Ut(),HD=et(),VA=Oe(),R3t=E2(),Q3t=Zd(),D3t=hn(),N3t=_n(),O3t=Hd().f,sme=ao(),F3t=HA(),ume=ga(),q3t=c0(),dme=WA(),L3t=GM(),$3t=mr(),U3t=Qe(),G3t=Ma(),z3t=Fr().enforce,j3t=nf(),H3t=ca(),mme=yb(),fme=UD(),W3t=H3t("match"),d0=HD.RegExp,nh=d0.prototype,V3t=HD.SyntaxError,K3t=VA(nh.exec),wb=VA("".charAt),lme=VA("".replace),cme=VA("".indexOf),pme=VA("".slice),J3t=/^\?<[^\s\d!#%&*+<=>@^][^\s!#%&*+<=>@^]*>/,ff=/a/g,GD=/a/g,Z3t=new d0(ff)!==ff,gme=dme.MISSED_STICKY,Y3t=dme.UNSUPPORTED_Y,X3t=P3t&&(!Z3t||gme||mme||fme||U3t(function(){return GD[W3t]=!1,d0(ff)!==ff||d0(GD)===GD||String(d0(ff,"i"))!=="/a/i"})),e4t=function e4t(e){for(var t=e.length,a=0,r="",i=!1,n;a<=t;a++){if(n=wb(e,a),n==="\\"){r+=n+wb(e,++a);continue}!i&&n==="."?r+="[\\s\\S]":(n==="["?i=!0:n==="]"&&(i=!1),r+=n)}return r},t4t=function t4t(e){for(var t=e.length,a=0,r="",i=[],n=N3t(null),o=!1,s=!1,u=0,c="",p;a<=t;a++){if(p=wb(e,a),p==="\\")p+=wb(e,++a);else if(p==="]")o=!1;else if(!o)switch(!0){case p==="[":o=!0;break;case p==="(":if(r+=p,pme(e,a+1,a+3)==="?:")continue;K3t(J3t,pme(e,a+1))&&(a+=2,s=!0),u++;continue;case p===">"&&s:if(c===""||G3t(n,c))throw new V3t("Invalid capture group name");n[c]=!0,i[i.length]=[c,u],s=!1,c="";continue}s?c+=p:r+=p}return[r,i]};if(R3t("RegExp",X3t)){for(p0=function(t,a){var r=sme(nh,this),i=F3t(t),n=a===void 0,o=[],s=t,u,c,p,l,m,f;if(!r&&i&&n&&t.constructor===p0)return t;if((i||sme(nh,t))&&(t=t.source,n&&(a=q3t(s))),t=t===void 0?"":ume(t),a=a===void 0?"":ume(a),s=t,mme&&"dotAll"in ff&&(c=!!a&&cme(a,"s")>-1,c&&(a=lme(a,/s/g,""))),u=a,gme&&"sticky"in ff&&(p=!!a&&cme(a,"y")>-1,p&&Y3t&&(a=lme(a,/y/g,""))),fme&&(l=t4t(t),t=l[0],o=l[1]),m=Q3t(d0(t,a),r?this:nh,p0),(c||p||o.length)&&(f=z3t(m),c&&(f.dotAll=!0,f.raw=p0(e4t(t),u)),p&&(f.sticky=!0),o.length&&(f.groups=o)),t!==s)try{D3t(m,"source",s===""?"(?:)":s)}catch(g){}return m},zD=O3t(d0),jD=0;zD.length>jD;)L3t(p0,d0,zD[jD++]);nh.constructor=p0,p0.prototype=nh,$3t(HD,"RegExp",p0,{constructor:!0})}var p0,zD,jD;j3t("RegExp")});var KA=T(function(rQa,_me){"use strict";var a4t=TypeError;_me.exports=function(e){if(typeof e=="string")return e;throw new a4t("Argument is not a string")}});var bme=T(function(){"use strict";var r4t=ne(),JA=Oe(),i4t=KA(),n4t=Ma(),xme=AA().start,o4t=H2(),s4t=Array,Ame=RegExp.escape,vme=JA("".charAt),KD=JA("".charCodeAt),u4t=JA(1.1.toString),l4t=JA([].join),wme=/^[0-9a-z]/i,c4t=/^[$()*+./?[\\\]^{|}]/,p4t=RegExp("^[!\"#%&',\\-:;<=>@`~"+o4t+"]"),WD=JA(wme.exec),yme={" ":"t","\n":"n","\v":"v","\f":"f","\r":"r"},VD=function VD(e){var t=u4t(KD(e,0),16);return t.length<3?"\\x"+xme(t,2,"0"):"\\u"+xme(t,4,"0")},d4t=!Ame||Ame("ab")!=="\\x61b";r4t({target:"RegExp",stat:!0,forced:d4t},{escape:function escape1(t){i4t(t);for(var a=t.length,r=s4t(a),i=0;i=56320||i+1>=a||(KD(t,i+1)&64512)!==56320?r[i]=VD(n):(r[i]=n,r[++i]=vme(t,i))}}return l4t(r,"")}})});var kme=T(function(){"use strict";var m4t=Ut(),f4t=yb(),g4t=On(),h4t=bi(),_4t=Fr().get,Ime=RegExp.prototype,x4t=TypeError;m4t&&f4t&&h4t(Ime,"dotAll",{configurable:!0,get:function get(){if(this!==Ime){if(g4t(this)==="RegExp")return!!_4t(this).dotAll;throw new x4t("Incompatible receiver, RegExp required")}}})});var kb=T(function(uQa,Eme){"use strict";var oh=Bt(),Ib=Oe(),A4t=ga(),v4t=vb(),y4t=WA(),w4t=zm(),b4t=_n(),I4t=Fr().get,k4t=yb(),C4t=UD(),E4t=w4t("native-string-replace",String.prototype.replace),bb=RegExp.prototype.exec,ZD=bb,S4t=Ib("".charAt),B4t=Ib("".indexOf),T4t=Ib("".replace),JD=Ib("".slice),YD=function(){var e=/a/,t=/b*/g;return oh(bb,e,"a"),oh(bb,t,"a"),e.lastIndex!==0||t.lastIndex!==0}(),Cme=y4t.BROKEN_CARET,XD=/()??/.exec("")[1]!==void 0,M4t=YD||XD||Cme||k4t||C4t;M4t&&(ZD=function(t){var a=this,r=I4t(a),i=A4t(t),n=r.raw,o,s,u,c,p,l,m;if(n)return n.lastIndex=a.lastIndex,o=oh(ZD,n,i),a.lastIndex=n.lastIndex,o;var f=r.groups,g=Cme&&a.sticky,h=oh(v4t,a),_=a.source,A=0,x=i;if(g&&(h=T4t(h,"y",""),B4t(h,"g")===-1&&(h+="g"),x=JD(i,a.lastIndex),a.lastIndex>0&&(!a.multiline||a.multiline&&S4t(i,a.lastIndex-1)!=="\n")&&(_="(?: "+_+")",x=" "+x,A++),s=new RegExp("^(?:"+_+")",h)),XD&&(s=new RegExp("^"+_+"$(?!\\s)",h)),YD&&(u=a.lastIndex),c=oh(bb,g?s:a,x),g?c?(c.input=JD(c.input,A),c[0]=JD(c[0],A),c.index=a.lastIndex,a.lastIndex+=c[0].length):a.lastIndex=0:YD&&c&&(a.lastIndex=a.global?c.index+c[0].length:u),XD&&c&&c.length>1&&oh(E4t,c[0],s,function(){for(p=1;p1;return t.has(1)&&t.clear(),{done:r,value:2}}}}},t=new Set([1,2,3,4]);return t.difference(e).size!==3});C6t({target:"Set",proto:!0,real:!0,forced:M6t},{difference:E6t})});var gfe=T(function(QQa,ffe){"use strict";var P6t=m0(),aN=bu(),R6t=sh(),Q6t=g0(),D6t=gf(),N6t=f0(),O6t=aN.Set,mfe=aN.add,F6t=aN.has;ffe.exports=function(t){var a=P6t(this),r=Q6t(t),i=new O6t;return R6t(a)>r.size?N6t(r.getIterator(),function(n){F6t(a,n)&&mfe(i,n)}):D6t(a,function(n){r.includes(n)&&mfe(i,n)}),i}});var hfe=T(function(){"use strict";var q6t=ne(),L6t=Qe(),$6t=gfe(),U6t=h0(),G6t=!U6t("intersection",function(e){return e.size===2&&e.has(1)&&e.has(2)})||L6t(function(){return String(Array.from(new Set([1,2,3]).intersection(new Set([3,2]))))!=="3,2"});q6t({target:"Set",proto:!0,real:!0,forced:G6t},{intersection:$6t})});var xfe=T(function(OQa,_fe){"use strict";var z6t=m0(),j6t=bu().has,H6t=sh(),W6t=g0(),V6t=gf(),K6t=f0(),J6t=vn();_fe.exports=function(t){var a=z6t(this),r=W6t(t);if(H6t(a)<=r.size)return V6t(a,function(n){if(r.includes(n))return!1},!0)!==!1;var i=r.getIterator();return K6t(i,function(n){if(j6t(a,n))return J6t(i,"normal",!1)})!==!1}});var Afe=T(function(){"use strict";var Z6t=ne(),Y6t=xfe(),X6t=h0(),ebt=!X6t("isDisjointFrom",function(e){return!e});Z6t({target:"Set",proto:!0,real:!0,forced:ebt},{isDisjointFrom:Y6t})});var yfe=T(function(LQa,vfe){"use strict";var tbt=m0(),abt=sh(),rbt=gf(),ibt=g0();vfe.exports=function(t){var a=tbt(this),r=ibt(t);return abt(a)>r.size?!1:rbt(a,function(i){if(!r.includes(i))return!1},!0)!==!1}});var wfe=T(function(){"use strict";var nbt=ne(),obt=yfe(),sbt=h0(),ubt=!sbt("isSubsetOf",function(e){return e});nbt({target:"Set",proto:!0,real:!0,forced:ubt},{isSubsetOf:obt})});var Ife=T(function(GQa,bfe){"use strict";var lbt=m0(),cbt=bu().has,pbt=sh(),dbt=g0(),mbt=f0(),fbt=vn();bfe.exports=function(t){var a=lbt(this),r=dbt(t);if(pbt(a)=0?i:r+i;return n<0||n>=r?void 0:Wbt(a,n)}})});var ZA=T(function(tDa,Nfe){"use strict";var nN=Oe(),Kbt=ci(),Jbt=ga(),Zbt=Wr(),Ybt=nN("".charAt),Qfe=nN("".charCodeAt),Xbt=nN("".slice),Dfe=function Dfe(e){return function(t,a){var r=Jbt(Zbt(t)),i=Kbt(a),n=r.length,o,s;return i<0||i>=n?e?"":void 0:(o=Qfe(r,i),o<55296||o>56319||i+1===n||(s=Qfe(r,i+1))<56320||s>57343?e?Ybt(r,i):o:e?Xbt(r,i,i+2):(o-55296<<10)+(s-56320)+65536)}};Nfe.exports={codeAt:Dfe(!1),charAt:Dfe(!0)}});var Ofe=T(function(){"use strict";var eIt=ne(),tIt=ZA().codeAt;eIt({target:"String",proto:!0},{codePointAt:function codePointAt(t){return tIt(this,t)}})});var Bb=T(function(iDa,Ffe){"use strict";var aIt=HA(),rIt=TypeError;Ffe.exports=function(e){if(aIt(e))throw new rIt("The method doesn't accept regular expressions");return e}});var Tb=T(function(nDa,qfe){"use strict";var iIt=ca(),nIt=iIt("match");qfe.exports=function(e){var t=/./;try{"/./"[e](t)}catch(a){try{return t[nIt]=!1,"/./"[e](t)}catch(r){}}return!1}});var Ufe=T(function(){"use strict";var oIt=ne(),sIt=Wd(),uIt=gn().f,lIt=Xo(),Lfe=ga(),cIt=Bb(),pIt=Wr(),dIt=Tb(),mIt=or(),fIt=sIt("".slice),gIt=Math.min,$fe=dIt("endsWith"),hIt=!mIt&&!$fe&&!!function(){var e=uIt(String.prototype,"endsWith");return e&&!e.writable}();oIt({target:"String",proto:!0,forced:!hIt&&!$fe},{endsWith:function endsWith(t){var a=Lfe(pIt(this));cIt(t);var r=arguments.length>1?arguments[1]:void 0,i=a.length,n=r===void 0?i:gIt(lIt(r),i),o=Lfe(t);return fIt(a,n-o.length,n)===o}})});var oN=T(function(){"use strict";var _It=ne(),xIt=Oe(),AIt=bc(),vIt=RangeError,Gfe=String.fromCharCode,zfe=String.fromCodePoint,yIt=xIt([].join),wIt=!!zfe&&zfe.length!==1;_It({target:"String",stat:!0,arity:1,forced:wIt},{fromCodePoint:function fromCodePoint(t){for(var a=[],r=arguments.length,i=0,n;r>i;){if(n=+arguments[i++],AIt(n,1114111)!==n)throw new vIt(n+" is not a valid code point");a[i]=n<65536?Gfe(n):Gfe(((n-=65536)>>10)+55296,n%1024+56320)}return yIt(a,"")}})});var Hfe=T(function(){"use strict";var bIt=ne(),IIt=Oe(),kIt=Bb(),CIt=Wr(),jfe=ga(),EIt=Tb(),SIt=IIt("".indexOf);bIt({target:"String",proto:!0,forced:!EIt("includes")},{includes:function includes(t){return!!~SIt(jfe(CIt(this)),jfe(kIt(t)),arguments.length>1?arguments[1]:void 0)}})});var Vfe=T(function(){"use strict";var BIt=ne(),TIt=Oe(),MIt=Wr(),PIt=ga(),Wfe=TIt("".charCodeAt);BIt({target:"String",proto:!0},{isWellFormed:function isWellFormed(){for(var t=PIt(MIt(this)),a=t.length,r=0;r=56320||++r>=a||(Wfe(t,r)&64512)!==56320))return!1}return!0}})});var sN=T(function(){"use strict";var RIt=ZA().charAt,QIt=ga(),Jfe=Fr(),DIt=A6(),Kfe=Xd(),Zfe="String Iterator",NIt=Jfe.set,OIt=Jfe.getterFor(Zfe);DIt(String,"String",function(e){NIt(this,{type:Zfe,string:QIt(e),index:0})},function(){var t=OIt(this),a=t.string,r=t.index,i;return r>=a.length?Kfe(void 0,!0):(i=RIt(a,r),t.index+=i.length,Kfe(i,!1))})});var YA=T(function(hDa,age){"use strict";Cb();var Yfe=Bt(),Xfe=mr(),FIt=kb(),ege=Qe(),tge=ca(),qIt=hn(),LIt=tge("species"),uN=RegExp.prototype;age.exports=function(e,t,a,r){var i=tge(e),n=!ege(function(){var c={};return c[i]=function(){return 7},""[e](c)!==7}),o=n&&!ege(function(){var c=!1,p=/a/;if(e==="split"){var l={};l[LIt]=function(){return p},p={constructor:l,flags:""},p[i]=/./[i]}return p.exec=function(){return c=!0,null},p[i](""),!c});if(!n||!o||a){var s=/./[i],u=t(i,""[e],function(c,p,l,m,f){var g=p.exec;return g===FIt||g===uN.exec?n&&!f?{done:!0,value:Yfe(s,p,l,m)}:{done:!0,value:Yfe(c,l,p,m)}:{done:!1}});Xfe(String.prototype,e,u[0]),Xfe(uN,i,u[1])}r&&qIt(uN[i],"sham",!0)}});var XA=T(function(_Da,rge){"use strict";var $It=ZA().charAt;rge.exports=function(e,t,a){return t+(a?$It(e,t).length:1)}});var uh=T(function(xDa,nge){"use strict";var ige=Bt(),UIt=Dt(),GIt=Ua(),zIt=On(),jIt=kb(),HIt=TypeError;nge.exports=function(e,t){var a=e.exec;if(GIt(a)){var r=ige(a,e,t);return r!==null&&UIt(r),r}if(zIt(e)==="RegExp")return ige(jIt,e,t);throw new HIt("RegExp#exec called on incompatible receiver")}});var uge=T(function(){"use strict";var WIt=Bt(),VIt=Oe(),KIt=YA(),JIt=Dt(),ZIt=ta(),YIt=Xo(),Mb=ga(),XIt=Wr(),ekt=fn(),tkt=XA(),akt=c0(),oge=uh(),sge=VIt("".indexOf);KIt("match",function(e,t,a){return[function(i){var n=XIt(this),o=ZIt(i)?ekt(i,e):void 0;return o?WIt(o,i,n):new RegExp(i)[e](Mb(n))},function(r){var i=JIt(this),n=Mb(r),o=a(t,i,n);if(o.done)return o.value;var s=Mb(akt(i));if(sge(s,"g")===-1)return oge(i,n);var u=sge(s,"u")!==-1;i.lastIndex=0;for(var c=[],p=0,l;(l=oge(i,n))!==null;){var m=Mb(l[0]);c[p]=m,m===""&&(i.lastIndex=tkt(n,YIt(i.lastIndex),u)),p++}return p===0?null:c}]})});var xge=T(function(){"use strict";var rkt=ne(),lge=Bt(),dge=Wd(),ikt=h6(),Pb=Xd(),cge=Wr(),mge=Xo(),ev=ga(),nkt=Dt(),okt=ta(),skt=On(),ukt=HA(),fge=c0(),lkt=fn(),ckt=mr(),pkt=Qe(),dkt=ca(),mkt=NA(),fkt=XA(),gkt=uh(),gge=Fr(),cN=or(),Rb=dkt("matchAll"),hge="RegExp String",_ge=hge+" Iterator",hkt=gge.set,_kt=gge.getterFor(_ge),pge=RegExp.prototype,xkt=TypeError,pN=dge("".indexOf),Qb=dge("".matchAll),lN=!!Qb&&!pkt(function(){Qb("a",/./)}),Akt=ikt(function(t,a,r,i){hkt(this,{type:_ge,regexp:t,string:a,global:r,unicode:i,done:!1})},hge,function(){var t=_kt(this);if(t.done)return Pb(void 0,!0);var a=t.regexp,r=t.string,i=gkt(a,r);return i===null?(t.done=!0,Pb(void 0,!0)):t.global?(ev(i[0])===""&&(a.lastIndex=fkt(r,mge(a.lastIndex),t.unicode)),Pb(i,!1)):(t.done=!0,Pb(i,!1))}),dN=function dN(e){var t=nkt(this),a=ev(e),r=mkt(t,RegExp),i=ev(fge(t)),n,o,s;return n=new r(r===RegExp?t.source:t,i),o=!!~pN(i,"g"),s=!!~pN(i,"u"),n.lastIndex=mge(t.lastIndex),new Akt(n,a,o,s)};rkt({target:"String",proto:!0,forced:lN},{matchAll:function matchAll(t){var a=cge(this),r,i,n,o;if(okt(t)){if(ukt(t)&&(r=ev(cge(fge(t))),!~pN(r,"g")))throw new xkt("`.matchAll` does not allow non-global regexes");if(lN)return Qb(a,t);if(n=lkt(t,Rb),n===void 0&&cN&&skt(t)==="RegExp"&&(n=dN),n)return lge(n,t,a)}else if(lN)return Qb(a,t);return i=ev(a),o=new RegExp(t,"g"),cN?lge(dN,o,i):o[Rb](i)}});cN||Rb in pge||ckt(pge,Rb,dN)});var mN=T(function(bDa,Age){"use strict";var vkt=_l();Age.exports=/Version\/10(?:\.\d+){1,2}(?: [\w./]+)?(?: Mobile\/\w+)? Safari\//.test(vkt)});var vge=T(function(){"use strict";var ykt=ne(),wkt=AA().end,bkt=mN();ykt({target:"String",proto:!0,forced:bkt},{padEnd:function padEnd(t){return wkt(this,t,arguments.length>1?arguments[1]:void 0)}})});var yge=T(function(){"use strict";var Ikt=ne(),kkt=AA().start,Ckt=mN();Ikt({target:"String",proto:!0,forced:Ckt},{padStart:function padStart(t){return kkt(this,t,arguments.length>1?arguments[1]:void 0)}})});var kge=T(function(){"use strict";var Ekt=ne(),Ige=Oe(),Skt=rn(),Bkt=tr(),wge=ga(),Tkt=fr(),bge=Ige([].push),Mkt=Ige([].join);Ekt({target:"String",stat:!0},{raw:function raw(t){var a=Skt(Bkt(t).raw),r=Tkt(a);if(!r)return"";for(var i=arguments.length,n=[],o=0;;){if(bge(n,wge(a[o++])),o===r)return Mkt(n,"");o]*>)/g,Fkt=/\$([$&'`]|\d{1,2})/g;Ege.exports=function(e,t,a,r,i,n){var o=a+e.length,s=r.length,u=Fkt;return i!==void 0&&(i=Qkt(i),u=Okt),Nkt(n,u,function(c,p){var l;switch(fN(p,0)){case"$":return"$";case"&":return e;case"`":return gN(t,0,a);case"'":return gN(t,o);case"<":l=i[gN(p,1,-1)];break;default:var m=+p;if(m===0)return c;if(m>s){var f=Dkt(m/10);return f===0?c:f<=s?r[f-1]===void 0?fN(p,1):r[f-1]+fN(p,1):c}l=r[m-1]}return l===void 0?"":l})}});var Mge=T(function(){"use strict";var qkt=rs(),Sge=Bt(),Nb=Oe(),Lkt=YA(),$kt=Qe(),Ukt=Dt(),Gkt=Ua(),zkt=ta(),jkt=ci(),Hkt=Xo(),hf=ga(),Wkt=Wr(),Vkt=XA(),Kkt=fn(),Jkt=_N(),Zkt=c0(),Ykt=uh(),Xkt=ca(),AN=Xkt("replace"),eCt=Math.max,tCt=Math.min,aCt=Nb([].concat),xN=Nb([].push),Db=Nb("".indexOf),Bge=Nb("".slice),rCt=function rCt(e){return e===void 0?e:String(e)},iCt=function(){return"a".replace(/./,"$0")==="$0"}(),Tge=function(){return/./[AN]?/./[AN]("a","$0")==="":!1}(),nCt=!$kt(function(){var e=/./;return e.exec=function(){var t=[];return t.groups={a:"7"},t},"".replace(e,"$")!=="7"});Lkt("replace",function(e,t,a){var r=Tge?"$":"$0";return[function(n,o){var s=Wkt(this),u=zkt(n)?Kkt(n,AN):void 0;return u?Sge(u,n,s,o):Sge(t,hf(s),n,o)},function(i,n){var o=Ukt(this),s=hf(i);if(typeof n=="string"&&Db(n,r)===-1&&Db(n,"$<")===-1){var u=a(t,o,s,n);if(u.done)return u.value}var c=Gkt(n);c||(n=hf(n));var p=hf(Zkt(o)),l=Db(p,"g")!==-1,m;l&&(m=Db(p,"u")!==-1,o.lastIndex=0);for(var f=[],g;g=Ykt(o,s),!(g===null||(xN(f,g),!l));){var h=hf(g[0]);h===""&&(o.lastIndex=Vkt(s,Hkt(o.lastIndex),m))}for(var _="",A=0,x=0;x=A&&(_+=Bge(s,A,v)+b,A=v+y.length)}return _+Bge(s,A)}]},!nCt||!iCt||Tge)});var Qge=T(function(){"use strict";var oCt=ne(),sCt=Bt(),yN=Oe(),Pge=Wr(),uCt=Ua(),lCt=ta(),cCt=HA(),lh=ga(),pCt=fn(),dCt=c0(),mCt=_N(),fCt=ca(),gCt=or(),hCt=fCt("replace"),_Ct=TypeError,vN=yN("".indexOf),xCt=yN("".replace),Rge=yN("".slice),ACt=Math.max;oCt({target:"String",proto:!0},{replaceAll:function replaceAll(t,a){var r=Pge(this),i,n,o,s,u,c,p,l,m,f,g=0,h="";if(lCt(t)){if(i=cCt(t),i&&(n=lh(Pge(dCt(t))),!~vN(n,"g")))throw new _Ct("`.replaceAll` does not allow non-global regexes");if(o=pCt(t,hCt),o)return sCt(o,t,r,a);if(gCt&&i)return xCt(lh(r),t,a)}for(s=lh(r),u=lh(t),c=uCt(a),c||(a=lh(a)),p=u.length,l=ACt(1,p),m=vN(s,u);m!==-1;)f=c?lh(a(u,m,s)):mCt(u,s,m,[],void 0,a),h+=Rge(s,g,m)+f,g=m+p,m=m+l>s.length?-1:vN(s,u,m+l);return g1||"".split(/.?/).length;ECt("split",function(e,t,a){var r="0".split(void 0,0).length?function r(i,n){return i===void 0&&n===0?[]:wN(t,this,i,n)}:t;return[function(n,o){var s=TCt(this),u=BCt(n)?QCt(n,e):void 0;return u?wN(u,n,s,o):wN(r,Fge(s),n,o)},function(i,n){var o=SCt(this),s=Fge(i);if(!Lge){var u=a(r,o,s,n,r!==t);if(u.done)return u.value}var c=MCt(o,RegExp),p=o.unicode,l=(o.ignoreCase?"i":"")+(o.multiline?"m":"")+(o.unicode?"u":"")+(ch?"g":"y"),m=new c(ch?"^(?:"+o.source+")":o,l),f=n===void 0?OCt:n>>>0;if(f===0)return[];if(s.length===0)return qge(m,s)===null?[s]:[];for(var g=0,h=0,_=[];h1?arguments[1]:void 0,a.length)),i=Gge(t);return VCt(a,r,r+i.length)===i}})});var Wge=T(function(){"use strict";var ZCt=ne(),YCt=Oe(),XCt=Wr(),Hge=ci(),e8t=ga(),t8t=YCt("".slice),a8t=Math.max,r8t=Math.min,i8t=!"".substr||"ab".substr(-1)!=="b";ZCt({target:"String",proto:!0,forced:i8t},{substr:function substr(t,a){var r=e8t(XCt(this)),i=r.length,n=Hge(t),o,s;return n===1/0&&(n=0),n<0&&(n=a8t(i+n,0)),o=a===void 0?i:Hge(a),o<=0||o===1/0?"":(s=r8t(n+o,i),n>=s?"":t8t(r,n,s))}})});var Zge=T(function(){"use strict";var n8t=ne(),Jge=Bt(),EN=Oe(),o8t=Wr(),s8t=ga(),u8t=Qe(),l8t=Array,kN=EN("".charAt),Vge=EN("".charCodeAt),c8t=EN([].join),CN="".toWellFormed,p8t="�",Kge=CN&&u8t(function(){return Jge(CN,1)!=="1"});n8t({target:"String",proto:!0,forced:Kge},{toWellFormed:function toWellFormed(){var t=s8t(o8t(this));if(Kge)return Jge(CN,t);for(var a=t.length,r=l8t(a),i=0;i=56320||i+1>=a||(Vge(t,i+1)&64512)!==56320?r[i]=p8t:(r[i]=kN(t,i),r[++i]=kN(t,i))}return c8t(r,"")}})});var Ob=T(function(WDa,e2e){"use strict";var d8t=jm().PROPER,m8t=Qe(),Yge=H2(),Xge="​\x85᠎";e2e.exports=function(e){return m8t(function(){return!!Yge[e]()||Xge[e]()!==Xge||d8t&&Yge[e].name!==e})}});var t2e=T(function(){"use strict";var f8t=ne(),g8t=lf().trim,h8t=Ob();f8t({target:"String",proto:!0,forced:h8t("trim")},{trim:function trim(){return g8t(this)}})});var SN=T(function(JDa,a2e){"use strict";var _8t=lf().end,x8t=Ob();a2e.exports=x8t("trimEnd")?function(){return _8t(this)}:"".trimEnd});var i2e=T(function(){"use strict";var A8t=ne(),r2e=SN();A8t({target:"String",proto:!0,name:"trimEnd",forced:"".trimRight!==r2e},{trimRight:r2e})});var o2e=T(function(){"use strict";i2e();var v8t=ne(),n2e=SN();v8t({target:"String",proto:!0,name:"trimEnd",forced:"".trimEnd!==n2e},{trimEnd:n2e})});var BN=T(function(tNa,s2e){"use strict";var y8t=lf().start,w8t=Ob();s2e.exports=w8t("trimStart")?function(){return y8t(this)}:"".trimStart});var l2e=T(function(){"use strict";var b8t=ne(),u2e=BN();b8t({target:"String",proto:!0,name:"trimStart",forced:"".trimLeft!==u2e},{trimLeft:u2e})});var p2e=T(function(){"use strict";l2e();var I8t=ne(),c2e=BN();I8t({target:"String",proto:!0,name:"trimStart",forced:"".trimStart!==c2e},{trimStart:c2e})});var os=T(function(oNa,m2e){"use strict";var k8t=Oe(),C8t=Wr(),d2e=ga(),E8t=/"/g,S8t=k8t("".replace);m2e.exports=function(e,t,a,r){var i=d2e(C8t(e)),n="<"+t;return a!==""&&(n+=" "+a+'="'+S8t(d2e(r),E8t,""")+'"'),n+">"+i+""}});var ss=T(function(sNa,f2e){"use strict";var B8t=Qe();f2e.exports=function(e){return B8t(function(){var t=""[e]('"');return t!==t.toLowerCase()||t.split('"').length>3})}});var g2e=T(function(){"use strict";var T8t=ne(),M8t=os(),P8t=ss();T8t({target:"String",proto:!0,forced:P8t("anchor")},{anchor:function anchor(t){return M8t(this,"a","name",t)}})});var h2e=T(function(){"use strict";var R8t=ne(),Q8t=os(),D8t=ss();R8t({target:"String",proto:!0,forced:D8t("big")},{big:function big(){return Q8t(this,"big","","")}})});var _2e=T(function(){"use strict";var N8t=ne(),O8t=os(),F8t=ss();N8t({target:"String",proto:!0,forced:F8t("blink")},{blink:function blink(){return O8t(this,"blink","","")}})});var x2e=T(function(){"use strict";var q8t=ne(),L8t=os(),$8t=ss();q8t({target:"String",proto:!0,forced:$8t("bold")},{bold:function bold(){return L8t(this,"b","","")}})});var A2e=T(function(){"use strict";var U8t=ne(),G8t=os(),z8t=ss();U8t({target:"String",proto:!0,forced:z8t("fixed")},{fixed:function fixed(){return G8t(this,"tt","","")}})});var v2e=T(function(){"use strict";var j8t=ne(),H8t=os(),W8t=ss();j8t({target:"String",proto:!0,forced:W8t("fontcolor")},{fontcolor:function fontcolor(t){return H8t(this,"font","color",t)}})});var y2e=T(function(){"use strict";var V8t=ne(),K8t=os(),J8t=ss();V8t({target:"String",proto:!0,forced:J8t("fontsize")},{fontsize:function fontsize(t){return K8t(this,"font","size",t)}})});var w2e=T(function(){"use strict";var Z8t=ne(),Y8t=os(),X8t=ss();Z8t({target:"String",proto:!0,forced:X8t("italics")},{italics:function italics(){return Y8t(this,"i","","")}})});var b2e=T(function(){"use strict";var eEt=ne(),tEt=os(),aEt=ss();eEt({target:"String",proto:!0,forced:aEt("link")},{link:function link(t){return tEt(this,"a","href",t)}})});var I2e=T(function(){"use strict";var rEt=ne(),iEt=os(),nEt=ss();rEt({target:"String",proto:!0,forced:nEt("small")},{small:function small(){return iEt(this,"small","","")}})});var k2e=T(function(){"use strict";var oEt=ne(),sEt=os(),uEt=ss();oEt({target:"String",proto:!0,forced:uEt("strike")},{strike:function strike(){return sEt(this,"strike","","")}})});var C2e=T(function(){"use strict";var lEt=ne(),cEt=os(),pEt=ss();lEt({target:"String",proto:!0,forced:pEt("sub")},{sub:function sub(){return cEt(this,"sub","","")}})});var E2e=T(function(){"use strict";var dEt=ne(),mEt=os(),fEt=ss();dEt({target:"String",proto:!0,forced:fEt("sup")},{sup:function sup(){return mEt(this,"sup","","")}})});var Fb=T(function(QNa,B2e){"use strict";var S2e=et(),TN=Qe(),gEt=oA(),hEt=Ga().NATIVE_ARRAY_BUFFER_VIEWS,_Et=S2e.ArrayBuffer,_f=S2e.Int8Array;B2e.exports=!hEt||!TN(function(){_f(1)})||!TN(function(){new _f(-1)})||!gEt(function(e){new _f,new _f(null),new _f(1.5),new _f(e)},!0)||TN(function(){return new _f(new _Et(2),1,void 0).length!==1})});var MN=T(function(DNa,T2e){"use strict";var xEt=j6(),AEt=RangeError;T2e.exports=function(e,t){var a=xEt(e);if(a%t)throw new AEt("Wrong offset");return a}});var P2e=T(function(NNa,M2e){"use strict";var vEt=Math.round;M2e.exports=function(e){var t=vEt(e);return t<0?0:t>255?255:t&255}});var PN=T(function(ONa,R2e){"use strict";var yEt=es();R2e.exports=function(e){var t=yEt(e);return t==="BigInt64Array"||t==="BigUint64Array"}});var qb=T(function(FNa,Q2e){"use strict";var wEt=$x(),bEt=TypeError;Q2e.exports=function(e){var t=wEt(e,"number");if(typeof t=="number")throw new bEt("Can't convert number to bigint");return BigInt(t)}});var RN=T(function(qNa,D2e){"use strict";var IEt=ts(),kEt=Bt(),CEt=nb(),EEt=tr(),SEt=fr(),BEt=ef(),TEt=wp(),MEt=o6(),PEt=PN(),REt=Ga().aTypedArrayConstructor,QEt=qb();D2e.exports=function(t){var a=CEt(this),r=EEt(t),i=arguments.length,n=i>1?arguments[1]:void 0,o=n!==void 0,s=TEt(r),u,c,p,l,m,f,g,h;if(s&&!MEt(s))for(g=BEt(r,s),h=g.next,r=[];!(f=kEt(h,g)).done;)r.push(f.value);for(o&&i>2&&(n=IEt(n,arguments[2])),c=SEt(r),p=new(REt(a))(c),l=PEt(p),u=0;c>u;u++)m=o?n(r[u],u):r[u],p[u]=l?QEt(m):+m;return p}});var Qc=T(function(LNa,LN){"use strict";var N2e=ne(),W2e=et(),O2e=Bt(),DEt=Ut(),NEt=Fb(),iv=Ga(),V2e=_A(),F2e=is(),OEt=Yo(),tv=hn(),FEt=ab(),qEt=Xo(),q2e=fA(),QN=MN(),LEt=P2e(),K2e=Ap(),av=Ma(),$Et=es(),ON=ta(),UEt=Gd(),GEt=_n(),zEt=ao(),Lb=yu(),jEt=Hd().f,L2e=RN(),HEt=xn().forEach,WEt=nf(),VEt=bi(),J2e=Or(),Z2e=gn(),$2e=O2(),$N=Fr(),KEt=Zd(),FN=$N.get,JEt=$N.set,ZEt=$N.enforce,Y2e=J2e.f,YEt=Z2e.f,DN=W2e.RangeError,X2e=V2e.ArrayBuffer,XEt=X2e.prototype,e7t=V2e.DataView,$b=iv.NATIVE_ARRAY_BUFFER_VIEWS,U2e=iv.TYPED_ARRAY_TAG,G2e=iv.TypedArray,rv=iv.TypedArrayPrototype,qN=iv.isTypedArray,Ub="BYTES_PER_ELEMENT",NN="Wrong length",Gb=function Gb(e,t){VEt(e,t,{configurable:!0,get:function get(){return FN(this)[t]}})},z2e=function z2e(e){var t;return zEt(XEt,e)||(t=$Et(e))==="ArrayBuffer"||t==="SharedArrayBuffer"},ehe=function ehe(e,t){return qN(e)&&!UEt(t)&&t in e&&FEt(+t)&&t>=0},j2e=function j2e(t,a){return a=K2e(a),ehe(t,a)?OEt(2,t[a]):YEt(t,a)},H2e=function H2e(t,a,r){return a=K2e(a),ehe(t,a)&&ON(r)&&av(r,"value")&&!av(r,"get")&&!av(r,"set")&&!r.configurable&&(!av(r,"writable")||r.writable)&&(!av(r,"enumerable")||r.enumerable)?(t[a]=r.value,t):Y2e(t,a,r)};DEt?($b||(Z2e.f=j2e,J2e.f=H2e,Gb(rv,"buffer"),Gb(rv,"byteOffset"),Gb(rv,"byteLength"),Gb(rv,"length")),N2e({target:"Object",stat:!0,forced:!$b},{getOwnPropertyDescriptor:j2e,defineProperty:H2e}),LN.exports=function(e,t,a){var r=e.match(/\d+/)[0]/8,i=e+(a?"Clamped":"")+"Array",n="get"+e,o="set"+e,s=W2e[i],u=s,c=u&&u.prototype,p={},l=function l(h,_){var A=FN(h);return A.view[n](_*r+A.byteOffset,!0)},m=function m(h,_,A){var x=FN(h);x.view[o](_*r+x.byteOffset,a?LEt(A):A,!0)},f=function f(h,_){Y2e(h,_,{get:function get(){return l(this,_)},set:function set(A){return m(this,_,A)},enumerable:!0})};$b?NEt&&(u=t(function(h,_,A,x){return F2e(h,c),KEt(function(){return ON(_)?z2e(_)?x!==void 0?new s(_,QN(A,r),x):A!==void 0?new s(_,QN(A,r)):new s(_):qN(_)?$2e(u,_):O2e(L2e,u,_):new s(q2e(_))}(),h,u)}),Lb&&Lb(u,G2e),HEt(jEt(s),function(h){h in u||tv(u,h,s[h])}),u.prototype=c):(u=t(function(h,_,A,x){F2e(h,c);var y=0,v=0,I,b,w;if(!ON(_))w=q2e(_),b=w*r,I=new X2e(b);else if(z2e(_)){I=_,v=QN(A,r);var k=_.byteLength;if(x===void 0){if(k%r)throw new DN(NN);if(b=k-v,b<0)throw new DN(NN)}else if(b=qEt(x)*r,b+v>k)throw new DN(NN);w=b/r}else return qN(_)?$2e(u,_):O2e(L2e,u,_);for(JEt(h,{buffer:I,byteOffset:v,byteLength:b,length:w,view:new e7t(I)});y=0?i:r+i;return n<0||n>=r?void 0:a[n]})});var mhe=T(function(){"use strict";var f7t=Oe(),dhe=Ga(),g7t=sP(),h7t=f7t(g7t),_7t=dhe.aTypedArray,x7t=dhe.exportTypedArrayMethod;x7t("copyWithin",function(t,a){return h7t(_7t(this),t,a,arguments.length>2?arguments[2]:void 0)})});var ghe=T(function(){"use strict";var fhe=Ga(),A7t=xn().every,v7t=fhe.aTypedArray,y7t=fhe.exportTypedArrayMethod;y7t("every",function(t){return A7t(v7t(this),t,arguments.length>1?arguments[1]:void 0)})});var _he=T(function(){"use strict";var hhe=Ga(),w7t=f6(),b7t=qb(),I7t=es(),k7t=Bt(),C7t=Oe(),E7t=Qe(),S7t=hhe.aTypedArray,B7t=hhe.exportTypedArrayMethod,T7t=C7t("".slice),M7t=E7t(function(){var e=0;return new Int8Array(2).fill({valueOf:function valueOf(){return e++}}),e!==1});B7t("fill",function(t){var a=arguments.length;S7t(this);var r=T7t(I7t(this),0,3)==="Big"?b7t(t):+t;return k7t(w7t,this,r,a>1?arguments[1]:void 0,a>2?arguments[2]:void 0)},M7t)});var Ahe=T(function(mOa,xhe){"use strict";var P7t=O2(),R7t=Ga().getTypedArrayConstructor;xhe.exports=function(e,t){return P7t(R7t(e),t)}});var yhe=T(function(){"use strict";var vhe=Ga(),Q7t=xn().filter,D7t=Ahe(),N7t=vhe.aTypedArray,O7t=vhe.exportTypedArrayMethod;O7t("filter",function(t){var a=Q7t(N7t(this),t,arguments.length>1?arguments[1]:void 0);return D7t(this,a)})});var bhe=T(function(){"use strict";var whe=Ga(),F7t=xn().find,q7t=whe.aTypedArray,L7t=whe.exportTypedArrayMethod;L7t("find",function(t){return F7t(q7t(this),t,arguments.length>1?arguments[1]:void 0)})});var khe=T(function(){"use strict";var Ihe=Ga(),$7t=xn().findIndex,U7t=Ihe.aTypedArray,G7t=Ihe.exportTypedArrayMethod;G7t("findIndex",function(t){return $7t(U7t(this),t,arguments.length>1?arguments[1]:void 0)})});var Ehe=T(function(){"use strict";var Che=Ga(),z7t=nA().findLast,j7t=Che.aTypedArray,H7t=Che.exportTypedArrayMethod;H7t("findLast",function(t){return z7t(j7t(this),t,arguments.length>1?arguments[1]:void 0)})});var Bhe=T(function(){"use strict";var She=Ga(),W7t=nA().findLastIndex,V7t=She.aTypedArray,K7t=She.exportTypedArrayMethod;K7t("findLastIndex",function(t){return W7t(V7t(this),t,arguments.length>1?arguments[1]:void 0)})});var Mhe=T(function(){"use strict";var The=Ga(),J7t=xn().forEach,Z7t=The.aTypedArray,Y7t=The.exportTypedArrayMethod;Y7t("forEach",function(t){J7t(Z7t(this),t,arguments.length>1?arguments[1]:void 0)})});var Phe=T(function(){"use strict";var X7t=Fb(),eSt=Ga().exportTypedArrayStaticMethod,tSt=RN();eSt("from",tSt,X7t)});var Qhe=T(function(){"use strict";var Rhe=Ga(),aSt=C2().includes,rSt=Rhe.aTypedArray,iSt=Rhe.exportTypedArrayMethod;iSt("includes",function(t){return aSt(rSt(this),t,arguments.length>1?arguments[1]:void 0)})});var Nhe=T(function(){"use strict";var Dhe=Ga(),nSt=C2().indexOf,oSt=Dhe.aTypedArray,sSt=Dhe.exportTypedArrayMethod;sSt("indexOf",function(t){return nSt(oSt(this),t,arguments.length>1?arguments[1]:void 0)})});var $he=T(function(){"use strict";var uSt=et(),lSt=Qe(),UN=Oe(),Fhe=Ga(),GN=lA(),cSt=ca(),zN=cSt("iterator"),Ohe=uSt.Uint8Array,pSt=UN(GN.values),dSt=UN(GN.keys),mSt=UN(GN.entries),jN=Fhe.aTypedArray,zb=Fhe.exportTypedArrayMethod,ph=Ohe&&Ohe.prototype,jb=!lSt(function(){ph[zN].call([1])}),qhe=!!ph&&ph.values&&ph[zN]===ph.values&&ph.values.name==="values",Lhe=function Lhe(){return pSt(jN(this))};zb("entries",function(){return mSt(jN(this))},jb);zb("keys",function(){return dSt(jN(this))},jb);zb("values",Lhe,jb||!qhe,{name:"values"});zb(zN,Lhe,jb||!qhe,{name:"values"})});var Ghe=T(function(){"use strict";var Uhe=Ga(),fSt=Oe(),gSt=Uhe.aTypedArray,hSt=Uhe.exportTypedArrayMethod,_St=fSt([].join);hSt("join",function(t){return _St(gSt(this),t)})});var jhe=T(function(){"use strict";var zhe=Ga(),xSt=rs(),ASt=yP(),vSt=zhe.aTypedArray,ySt=zhe.exportTypedArrayMethod;ySt("lastIndexOf",function(t){var a=arguments.length;return xSt(ASt,vSt(this),a>1?[t,arguments[1]]:[t])})});var Hhe=T(function(){"use strict";var HN=Ga(),wSt=xn().map,bSt=HN.aTypedArray,ISt=HN.getTypedArrayConstructor,kSt=HN.exportTypedArrayMethod;kSt("map",function(t){return wSt(bSt(this),t,arguments.length>1?arguments[1]:void 0,function(a,r){return new(ISt(a))(r)})})});var Vhe=T(function(){"use strict";var Whe=Ga(),CSt=Fb(),ESt=Whe.aTypedArrayConstructor,SSt=Whe.exportTypedArrayStaticMethod;SSt("of",function(){for(var t=0,a=arguments.length,r=new(ESt(this))(a);a>t;)r[t]=arguments[t++];return r},CSt)});var Jhe=T(function(){"use strict";var Khe=Ga(),BSt=cA().left,TSt=Khe.aTypedArray,MSt=Khe.exportTypedArrayMethod;MSt("reduce",function(t){var a=arguments.length;return BSt(TSt(this),t,a,a>1?arguments[1]:void 0)})});var Yhe=T(function(){"use strict";var Zhe=Ga(),PSt=cA().right,RSt=Zhe.aTypedArray,QSt=Zhe.exportTypedArrayMethod;QSt("reduceRight",function(t){var a=arguments.length;return PSt(RSt(this),t,a,a>1?arguments[1]:void 0)})});var e1e=T(function(){"use strict";var Xhe=Ga(),DSt=Xhe.aTypedArray,NSt=Xhe.exportTypedArrayMethod,OSt=Math.floor;NSt("reverse",function(){for(var t=this,a=DSt(t).length,r=OSt(a/2),i=0,n;i1?arguments[1]:void 0,1),r=LSt(t);if(VN)return r1e(n1e,this,r,a);var i=this.length,n=FSt(r),o=0;if(n+a>i)throw new $St("Wrong length");for(;on;)s[n]=r[n++];return s},JSt)});var l1e=T(function(){"use strict";var u1e=Ga(),ZSt=xn().some,YSt=u1e.aTypedArray,XSt=u1e.exportTypedArrayMethod;XSt("some",function(t){return ZSt(YSt(this),t,arguments.length>1?arguments[1]:void 0)})});var g1e=T(function(){"use strict";var e9t=et(),t9t=Wd(),ZN=Qe(),a9t=Oa(),r9t=b6(),f1e=Ga(),c1e=IP(),i9t=kP(),p1e=Al(),d1e=I6(),n9t=f1e.aTypedArray,o9t=f1e.exportTypedArrayMethod,nv=e9t.Uint16Array,dh=nv&&t9t(nv.prototype.sort),s9t=!!dh&&!(ZN(function(){dh(new nv(2),null)})&&ZN(function(){dh(new nv(2),{})})),m1e=!!dh&&!ZN(function(){if(p1e)return p1e<74;if(c1e)return c1e<67;if(i9t)return!0;if(d1e)return d1e<602;var e=new nv(516),t=Array(516),a,r;for(a=0;a<516;a++)r=a%4,e[a]=515-a,t[a]=a-2*r+3;for(dh(e,function(i,n){return(i/4|0)-(n/4|0)}),a=0;a<516;a++)if(e[a]!==t[a])return!0}),u9t=function u9t(e){return function(t,a){return e!==void 0?+e(t,a)||0:a!==a?-1:t!==t?1:t===0&&a===0?1/t>0&&1/a<0?1:-1:t>a}};o9t("sort",function(t){return t!==void 0&&a9t(t),m1e?dh(this,t):r9t(n9t(this),u9t(t))},!m1e||s9t)});var _1e=T(function(){"use strict";var YN=Ga(),l9t=Xo(),h1e=bc(),c9t=YN.aTypedArray,p9t=YN.getTypedArrayConstructor,d9t=YN.exportTypedArrayMethod;d9t("subarray",function(t,a){var r=c9t(this),i=r.length,n=h1e(t,i),o=p9t(r);return new o(r.buffer,r.byteOffset+n*r.BYTES_PER_ELEMENT,l9t((a===void 0?i:h1e(a,i))-n))})});var w1e=T(function(){"use strict";var m9t=et(),f9t=rs(),v1e=Ga(),XN=Qe(),x1e=zs(),Hb=m9t.Int8Array,A1e=v1e.aTypedArray,g9t=v1e.exportTypedArrayMethod,y1e=[].toLocaleString,h9t=!!Hb&&XN(function(){y1e.call(new Hb(1))}),_9t=XN(function(){return[1,2].toLocaleString()!==new Hb([1,2]).toLocaleString()})||!XN(function(){Hb.prototype.toLocaleString.call([1,2])});g9t("toLocaleString",function(){return f9t(y1e,h9t?x1e(A1e(this)):A1e(this),x1e(arguments))},_9t)});var b1e=T(function(){"use strict";var x9t=SP(),eO=Ga(),A9t=eO.aTypedArray,v9t=eO.exportTypedArrayMethod,y9t=eO.getTypedArrayConstructor;v9t("toReversed",function(){return x9t(A9t(this),y9t(this))})});var I1e=T(function(){"use strict";var Wb=Ga(),w9t=Oe(),b9t=Oa(),I9t=O2(),k9t=Wb.aTypedArray,C9t=Wb.getTypedArrayConstructor,E9t=Wb.exportTypedArrayMethod,S9t=w9t(Wb.TypedArrayPrototype.sort);E9t("toSorted",function(t){t!==void 0&&b9t(t);var a=k9t(this),r=I9t(C9t(a),a);return S9t(r,t)})});var C1e=T(function(){"use strict";var B9t=Ga().exportTypedArrayMethod,T9t=Qe(),M9t=et(),P9t=Oe(),k1e=M9t.Uint8Array,R9t=k1e&&k1e.prototype||{},Vb=[].toString,Q9t=P9t([].join);T9t(function(){Vb.call({})})&&(Vb=function Vb(){return Q9t(this)});var D9t=R9t.toString!==Vb;B9t("toString",Vb,D9t)});var S1e=T(function(){"use strict";var N9t=TP(),tO=Ga(),O9t=PN(),F9t=ci(),q9t=qb(),L9t=tO.aTypedArray,$9t=tO.getTypedArrayConstructor,U9t=tO.exportTypedArrayMethod,E1e=function(){try{new Int8Array(1).with(2,{valueOf:function valueOf(){throw 8}})}catch(e){return e===8}}(),G9t=E1e&&function(){try{new Int8Array(1).with(-.5,1)}catch(e){return!0}}();U9t("with",function(e,t){var a=L9t(this),r=F9t(e),i=O9t(a)?q9t(t):+t;return N9t(a,$9t(a),r,i)},!E1e||G9t)});var aO=T(function(fFa,B1e){"use strict";var z9t=ta(),j9t=String,H9t=TypeError;B1e.exports=function(e){if(e===void 0||z9t(e))return e;throw new H9t(j9t(e)+" is not an object or undefined")}});var ov=T(function(gFa,Q1e){"use strict";var R1e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",T1e=R1e+"+/",M1e=R1e+"-_",P1e=function P1e(e){for(var t={},a=0;a<64;a++)t[e.charAt(a)]=a;return t};Q1e.exports={i2c:T1e,c2i:P1e(T1e),i2cUrl:M1e,c2iUrl:P1e(M1e)}});var rO=T(function(hFa,D1e){"use strict";var W9t=TypeError;D1e.exports=function(e){var t=e&&e.alphabet;if(t===void 0||t==="base64"||t==="base64url")return t||"base64";throw new W9t("Incorrect `alphabet` option")}});var sO=T(function(_Fa,F1e){"use strict";var N1e=et(),V9t=Oe(),K9t=aO(),J9t=KA(),Z9t=Ma(),O1e=ov(),Y9t=rO(),X9t=G2(),eBt=O1e.c2i,tBt=O1e.c2iUrl,_0=N1e.SyntaxError,aBt=N1e.TypeError,xf=V9t("".charAt),iO=function iO(e,t){for(var a=e.length;t>16&255,i>>8&255,i&255];if(r===2){if(a&&n[1]!==0)throw new _0("Extra bits");return[n[0]]}if(r===3){if(a&&n[2]!==0)throw new _0("Extra bits");return[n[0],n[1]]}return n},oO=function oO(e,t,a){for(var r=t.length,i=0;i0){if(n==="stop-before-partial")break;if(n==="loose"){if(p.length===1)throw new _0("Malformed padding: exactly one additional character");u=oO(s,nO(p,i,!1),u)}else throw new _0("Missing padding")}c=o;break}var m=xf(e,l);if(++l,m==="="){if(p.length<2)throw new _0("Padding is too early");if(l=iO(e,l),p.length===2){if(l===o){if(n==="stop-before-partial")break;throw new _0("Malformed padding: only one =")}xf(e,l)==="="&&(++l,l=iO(e,l))}if(l1?arguments[1]:void 0,null,0x1fffffffffffff);return nBt(mh,a.bytes)}})});var lO=T(function(vFa,G1e){"use strict";var uO=et(),$1e=Oe(),uBt=uO.Uint8Array,L1e=uO.SyntaxError,lBt=uO.parseInt,cBt=Math.min,U1e=/[^\da-f]/i,pBt=$1e(U1e.exec),dBt=$1e("".slice);G1e.exports=function(e,t){var a=e.length;if(a%2!==0)throw new L1e("String should be an even number of characters");for(var r=t?cBt(t.length,a/2):a/2,i=t||new uBt(r),n=0,o=0;o1?arguments[1]:void 0,this,this.length);return{read:a.read,written:a.written}}})});var W1e=T(function(){"use strict";var IBt=ne(),kBt=et(),CBt=KA(),EBt=sv(),SBt=G2(),BBt=lO();kBt.Uint8Array&&IBt({target:"Uint8Array",proto:!0},{setFromHex:function setFromHex(t){EBt(this),CBt(t),SBt(this.buffer);var a=BBt(t,this).read;return{read:a,written:a/2}}})});var K1e=T(function(){"use strict";var TBt=ne(),MBt=et(),PBt=Oe(),RBt=aO(),QBt=sv(),DBt=G2(),V1e=ov(),NBt=rO(),OBt=V1e.i2c,FBt=V1e.i2cUrl,qBt=PBt("".charAt),Jb=MBt.Uint8Array,LBt=!Jb||!Jb.prototype.toBase64||!function(){try{var e=new Jb;e.toBase64(null)}catch(t){return!0}}();Jb&&TBt({target:"Uint8Array",proto:!0,forced:LBt},{toBase64:function toBase64(){var t=QBt(this),a=arguments.length?RBt(arguments[0]):void 0,r=NBt(a)==="base64"?OBt:FBt,i=!!a&&!!a.omitPadding;DBt(this.buffer);for(var n="",o=0,s=t.length,u,c=function c(p){return qBt(r,u>>6*p&63)};o+2>(-2*n&6)));return r}})});var T_e=T(function(){"use strict";var QTt=ne(),DTt=et(),S_e=Ta(),B_e=Oe(),NTt=Bt(),_O=Qe(),C_e=ga(),OTt=Ws(),FTt=ov().i2c,hh=S_e("btoa"),E_e=B_e("".charAt),qTt=B_e("".charCodeAt),pv=!!hh&&!_O(function(){return hh("hi")!=="aGk="}),LTt=pv&&!_O(function(){hh()}),$Tt=pv&&_O(function(){return hh(null)!=="bnVsbA=="}),UTt=pv&&hh.length!==1;QTt({global:!0,bind:!0,enumerable:!0,forced:!pv||LTt||$Tt||UTt},{btoa:function btoa1(t){if(OTt(arguments.length,1),pv)return NTt(hh,DTt,C_e(t));for(var a=C_e(t),r="",i=0,n=FTt,o,s;E_e(a,i)||(n="=",i%1);){if(s=qTt(a,i+=3/4),s>255)throw new(S_e("DOMException"))("The string contains characters outside of the Latin1 range","InvalidCharacterError");o=o<<8|s,r+=E_e(n,63&o>>8-i%1*8)}return r}})});var xO=T(function(WFa,M_e){"use strict";M_e.exports={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}});var vO=T(function(VFa,R_e){"use strict";var GTt=Ux(),AO=GTt("span").classList,P_e=AO&&AO.constructor&&AO.constructor.prototype;R_e.exports=P_e===Object.prototype?void 0:P_e});var O_e=T(function(){"use strict";var Q_e=et(),D_e=xO(),zTt=vO(),yO=pP(),jTt=hn(),N_e=function N_e(e){if(e&&e.forEach!==yO)try{jTt(e,"forEach",yO)}catch(t){e.forEach=yO}};for(oI in D_e)D_e[oI]&&N_e(Q_e[oI]&&Q_e[oI].prototype);var oI;N_e(zTt)});var U_e=T(function(){"use strict";var F_e=et(),L_e=xO(),HTt=vO(),dv=lA(),q_e=hn(),WTt=Io(),VTt=ca(),wO=VTt("iterator"),bO=dv.values,$_e=function $_e(e,t){if(e){if(e[wO]!==bO)try{q_e(e,wO,bO)}catch(r){e[wO]=bO}if(WTt(e,t,!0),L_e[t]){for(var a in dv)if(e[a]!==dv[a])try{q_e(e,a,dv[a])}catch(r){e[a]=dv[a]}}}};for(sI in L_e)$_e(F_e[sI]&&F_e[sI].prototype,sI);var sI;$_e(HTt,"DOMTokenList")});var IO=T(function(XFa,G_e){"use strict";G_e.exports={IndexSizeError:{s:"INDEX_SIZE_ERR",c:1,m:1},DOMStringSizeError:{s:"DOMSTRING_SIZE_ERR",c:2,m:0},HierarchyRequestError:{s:"HIERARCHY_REQUEST_ERR",c:3,m:1},WrongDocumentError:{s:"WRONG_DOCUMENT_ERR",c:4,m:1},InvalidCharacterError:{s:"INVALID_CHARACTER_ERR",c:5,m:1},NoDataAllowedError:{s:"NO_DATA_ALLOWED_ERR",c:6,m:0},NoModificationAllowedError:{s:"NO_MODIFICATION_ALLOWED_ERR",c:7,m:1},NotFoundError:{s:"NOT_FOUND_ERR",c:8,m:1},NotSupportedError:{s:"NOT_SUPPORTED_ERR",c:9,m:1},InUseAttributeError:{s:"INUSE_ATTRIBUTE_ERR",c:10,m:1},InvalidStateError:{s:"INVALID_STATE_ERR",c:11,m:1},SyntaxError:{s:"SYNTAX_ERR",c:12,m:1},InvalidModificationError:{s:"INVALID_MODIFICATION_ERR",c:13,m:1},NamespaceError:{s:"NAMESPACE_ERR",c:14,m:1},InvalidAccessError:{s:"INVALID_ACCESS_ERR",c:15,m:1},ValidationError:{s:"VALIDATION_ERR",c:16,m:0},TypeMismatchError:{s:"TYPE_MISMATCH_ERR",c:17,m:1},SecurityError:{s:"SECURITY_ERR",c:18,m:1},NetworkError:{s:"NETWORK_ERR",c:19,m:1},AbortError:{s:"ABORT_ERR",c:20,m:1},URLMismatchError:{s:"URL_MISMATCH_ERR",c:21,m:1},QuotaExceededError:{s:"QUOTA_EXCEEDED_ERR",c:22,m:1},TimeoutError:{s:"TIMEOUT_ERR",c:23,m:1},InvalidNodeTypeError:{s:"INVALID_NODE_TYPE_ERR",c:24,m:1},DataCloneError:{s:"DATA_CLONE_ERR",c:25,m:1}}});var exe=T(function(){"use strict";var KTt=ne(),cI=Ta(),JTt=tR(),TO=Qe(),ZTt=_n(),MO=Yo(),pI=Or().f,YTt=mr(),uI=bi(),lI=Ma(),XTt=is(),eMt=Dt(),H_e=ZM(),z_e=Ym(),_h=IO(),tMt=e6(),W_e=Fr(),PO=Ut(),V_e=or(),xh="DOMException",BO="DATA_CLONE_ERR",mI=cI("Error"),Bp=cI(xh)||function(){try{var e=cI("MessageChannel")||JTt("worker_threads").MessageChannel;new e().port1.postMessage(new WeakMap)}catch(t){if(t.name===BO&&t.code===25)return t.constructor}}(),aMt=Bp&&Bp.prototype,K_e=mI.prototype,rMt=W_e.set,iMt=W_e.getterFor(xh),nMt="stack"in new mI(xh),J_e=function J_e(e){return lI(_h,e)&&_h[e].m?_h[e].c:0},RO=function RO(){XTt(this,fv);var t=arguments.length,a=z_e(t<1?void 0:arguments[0]),r=z_e(t<2?void 0:arguments[1],"Error"),i=J_e(r);if(rMt(this,{type:xh,name:r,message:a,code:i}),PO||(this.name=r,this.message=a,this.code=i),nMt){var n=new mI(a);n.name=xh,pI(this,"stack",MO(1,tMt(n.stack,1)))}},fv=RO.prototype=ZTt(K_e),Z_e=function Z_e(e){return{enumerable:!0,configurable:!0,get:e}},kO=function kO(e){return Z_e(function(){return iMt(this)[e]})};PO&&(uI(fv,"code",kO("code")),uI(fv,"message",kO("message")),uI(fv,"name",kO("name")));pI(fv,"constructor",MO(1,RO));var fI=TO(function(){return!_instanceof(new Bp,mI)}),Y_e=fI||TO(function(){return K_e.toString!==H_e||String(new Bp(1,2))!=="2: 1"}),X_e=fI||TO(function(){return new Bp(1,"DataCloneError").code!==25}),oMt=fI||Bp[BO]!==25||aMt[BO]!==25,j_e=V_e?Y_e||X_e||oMt:fI;KTt({global:!0,constructor:!0,forced:j_e},{DOMException:j_e?RO:Bp});var gv=cI(xh),dI=gv.prototype;Y_e&&(V_e||Bp===gv)&&YTt(dI,"toString",H_e);X_e&&PO&&Bp===gv&&uI(dI,"code",Z_e(function(){return J_e(eMt(this).name)}));for(CO in _h)lI(_h,CO)&&(EO=_h[CO],mv=EO.s,SO=MO(6,EO.c),lI(gv,mv)||pI(gv,mv,SO),lI(dI,mv)||pI(dI,mv,SO));var EO,mv,SO,CO});var sxe=T(function(){"use strict";var sMt=ne(),uMt=et(),$O=Ta(),qO=Yo(),LO=Or().f,txe=Ma(),lMt=is(),cMt=Zd(),axe=Ym(),QO=IO(),pMt=e6(),dMt=Ut(),nxe=or(),_v="DOMException",oxe=$O("Error"),xv=$O(_v),UO=function UO1(){lMt(this,mMt);var t=arguments.length,a=axe(t<1?void 0:arguments[0]),r=axe(t<2?void 0:arguments[1],"Error"),i=new xv(a,r),n=new oxe(a);return n.name=_v,LO(i,"stack",qO(1,pMt(n.stack,1))),cMt(i,this,UO),i},mMt=UO.prototype=xv.prototype,fMt="stack"in new oxe(_v),gMt="stack"in new xv(1,2),DO=xv&&dMt&&Object.getOwnPropertyDescriptor(uMt,_v),hMt=!!DO&&!(DO.writable&&DO.configurable),rxe=fMt&&!hMt&&!gMt;sMt({global:!0,constructor:!0,forced:nxe||rxe},{DOMException:rxe?UO:xv});var hv=$O(_v),ixe=hv.prototype;if(ixe.constructor!==hv){nxe||LO(ixe,"constructor",qO(1,hv));for(NO in QO)txe(QO,NO)&&(OO=QO[NO],FO=OO.s,txe(hv,FO)||LO(hv,FO,qO(6,OO.c)))}var OO,FO,NO});var lxe=T(function(){"use strict";var _Mt=Ta(),xMt=Io(),uxe="DOMException";xMt(_Mt(uxe),uxe)});var pxe=T(function(){"use strict";var AMt=ne(),vMt=et(),cxe=qA().clear;AMt({global:!0,bind:!0,enumerable:!0,forced:vMt.clearImmediate!==cxe},{clearImmediate:cxe})});var gI=T(function(uqa,mxe){"use strict";var dxe=et(),yMt=rs(),wMt=Ua(),bMt=dA(),IMt=_l(),kMt=zs(),CMt=Ws(),EMt=dxe.Function,SMt=/MSIE .\./.test(IMt)||bMt==="BUN"&&function(){var e=dxe.Bun.version.split(".");return e.length<3||e[0]==="0"&&(e[1]<3||e[1]==="3"&&e[2]==="0")}();mxe.exports=function(e,t){var a=t?2:1;return SMt?function(r,i){var n=CMt(arguments.length,1)>a,o=wMt(r)?r:EMt(r),s=n?kMt(arguments,a):[],u=n?function u(){yMt(o,this,s)}:o;return t?e(u,i):e(u)}:e}});var _xe=T(function(){"use strict";var BMt=ne(),hxe=et(),fxe=qA().set,TMt=gI(),gxe=hxe.setImmediate?TMt(fxe,!1):fxe;BMt({global:!0,bind:!0,enumerable:!0,forced:hxe.setImmediate!==gxe},{setImmediate:gxe})});var xxe=T(function(){"use strict";pxe();_xe()});var Axe=T(function(){"use strict";var MMt=ne(),PMt=et(),RMt=uD(),QMt=Oa(),DMt=Ws(),NMt=Qe(),OMt=Ut(),FMt=NMt(function(){return OMt&&Object.getOwnPropertyDescriptor(PMt,"queueMicrotask").value.length!==1});MMt({global:!0,enumerable:!0,dontCallGetSet:!0,forced:FMt},{queueMicrotask:function queueMicrotask1(t){DMt(arguments.length,1),RMt(QMt(t))}})});var yxe=T(function(){"use strict";var qMt=ne(),x0=et(),LMt=bi(),$Mt=Ut(),UMt=TypeError,GMt=Object.defineProperty,vxe=x0.self!==x0;try{$Mt?(hI=Object.getOwnPropertyDescriptor(x0,"self"),(vxe||!hI||!hI.get||!hI.enumerable)&&LMt(x0,"self",{get:function get(){return x0},set:function set(t){if(this!==x0)throw new UMt("Illegal invocation");GMt(x0,"self",{value:t,writable:!0,configurable:!0,enumerable:!0})},configurable:!0,enumerable:!0})):qMt({global:!0,simple:!0,forced:vxe},{self:x0})}catch(e){}var hI});var Pxe=T(function(){"use strict";var zMt=or(),jMt=ne(),Un=et(),vv=Ta(),wv=Oe(),VO=Qe(),HMt=jd(),vh=Ua(),WMt=Vd(),VMt=wc(),yI=ta(),KMt=Gd(),JMt=Gi(),Ixe=Dt(),AI=es(),ZMt=Ma(),YMt=js(),GO=hn(),_I=fr(),XMt=Ws(),ePt=c0(),wI=gQ(),KO=bu(),tPt=gf(),wxe=uR(),aPt=jM(),JO=N6(),Av=Un.Object,rPt=Un.Array,kxe=Un.Date,Cxe=Un.Error,iPt=Un.TypeError,nPt=Un.PerformanceMark,vf=vv("DOMException"),HO=wI.Map,ZO=wI.has,Exe=wI.get,vI=wI.set,Sxe=KO.Set,Bxe=KO.add,oPt=KO.has,sPt=vv("Object","keys"),uPt=wv([].push),lPt=wv((!0).valueOf),cPt=wv(1.1.valueOf),pPt=wv("".valueOf),dPt=wv(kxe.prototype.getTime),WO=HMt("structuredClone"),yv="DataCloneError",xI="Transferring",Txe=function Txe(e){return!VO(function(){var t=new Un.Set([7]),a=e(t),r=e(Av(7));return a===t||!a.has(7)||!yI(r)||+r!=7})&&e},bxe=function bxe(e,t){return!VO(function(){var a=new t,r=e({a:a,b:a});return!(r&&r.a===r.b&&_instanceof(r.a,t)&&r.a.stack===a.stack)})},mPt=function mPt(e){return!VO(function(){var t=e(new Un.AggregateError([1],WO,{cause:3}));return t.name!=="AggregateError"||t.errors[0]!==1||t.message!==WO||t.cause!==3})},Ah=Un.structuredClone,fPt=zMt||!bxe(Ah,Cxe)||!bxe(Ah,vf)||!mPt(Ah),gPt=!Ah&&Txe(function(e){return new nPt(WO,{detail:e}).detail}),Tp=Txe(Ah)||gPt,zO=function zO(e){throw new vf("Uncloneable type: "+e,yv)},us=function us(e,t){throw new vf((t||"Cloning")+" of "+e+" cannot be properly polyfilled in this engine",yv)},jO=function jO(e,t){return Tp||us(t),Tp(e)},hPt=function hPt(){var e;try{e=new Un.DataTransfer}catch(t){try{e=new Un.ClipboardEvent("").clipboardData}catch(a){}}return e&&e.items&&e.files?e:null},Mxe=function Mxe(e,t,a){if(ZO(t,e))return Exe(t,e);var r=a||AI(e),i,n,o,s,u,c;if(r==="SharedArrayBuffer")Tp?i=Tp(e):i=e;else{var p=Un.DataView;!p&&!vh(e.slice)&&us("ArrayBuffer");try{if(vh(e.slice)&&!e.resizable)i=e.slice(0);else for(n=e.byteLength,o=("maxByteLength"in e)?{maxByteLength:e.maxByteLength}:void 0,i=new ArrayBuffer(n,o),s=new p(e),u=new p(i),c=0;c1&&!VMt(arguments[1])?Ixe(arguments[1]):void 0,r=a?a.transfer:void 0,i,n;r!==void 0&&(i=new HO,n=xPt(r,i));var o=$n(t,i);return n&&APt(n),o}})});var Dxe=T(function(){"use strict";var vPt=ne(),Qxe=et(),yPt=gI(),Rxe=yPt(Qxe.setInterval,!0);vPt({global:!0,bind:!0,forced:Qxe.setInterval!==Rxe},{setInterval:Rxe})});var Fxe=T(function(){"use strict";var wPt=ne(),Oxe=et(),bPt=gI(),Nxe=bPt(Oxe.setTimeout,!0);wPt({global:!0,bind:!0,forced:Oxe.setTimeout!==Nxe},{setTimeout:Nxe})});var qxe=T(function(){"use strict";Dxe();Fxe()});var bv=T(function(kqa,$xe){"use strict";var IPt=Qe(),kPt=ca(),CPt=Ut(),Lxe=or(),EPt=kPt("iterator");$xe.exports=!IPt(function(){var e=new URL("b?a=1&b=2&c=3","https://a"),t=e.searchParams,a=new URLSearchParams("a=1&a=2&b=3"),r="";return e.pathname="c%20d",t.forEach(function(i,n){t.delete("b"),r+=n+i}),a.delete("a",2),a.delete("b",void 0),Lxe&&(!e.toJSON||!a.has("a",1)||a.has("a",2)||!a.has("a",void 0)||a.has("b"))||!t.size&&(Lxe||!CPt)||!t.sort||e.href!=="https://a/c%20d?a=1&c=3"||t.get("c")!=="3"||String(new URLSearchParams("?a=1"))!=="a=1"||!t[EPt]||new URL("https://a@b").username!=="a"||new URLSearchParams(new URLSearchParams("a=b")).get("a")!=="b"||new URL("https://тест").host!=="xn--e1aybc"||new URL("https://a#б").hash!=="#%D0%B1"||r!=="a1c3"||new URL("https://x",void 0).host!=="x"})});var Jxe=T(function(Cqa,Kxe){"use strict";var yf=Oe(),YO=0x7fffffff,Iv=36,Hxe=1,tF=26,SPt=38,BPt=700,TPt=72,MPt=128,PPt="-",RPt=/[^\0-\u007E]/,Wxe=/[.\u3002\uFF0E\uFF61]/g,Uxe="Overflow: input needs wider integers to process",XO=Iv-Hxe,Gxe=RangeError,QPt=yf(Wxe.exec),yh=Math.floor,eF=String.fromCharCode,zxe=yf("".charCodeAt),Vxe=yf([].join),A0=yf([].push),DPt=yf("".replace),NPt=yf("".split),OPt=yf("".toLowerCase),FPt=function FPt(e){for(var t=[],a=0,r=e.length;a=55296&&i<=56319&&a>1,e+=yh(e/t);e>XO*tF>>1;)e=yh(e/XO),r+=Iv;return yh(r+(XO+1)*e/(e+SPt))},LPt=function LPt(e){var t=[];e=FPt(e);var a=e.length,r=MPt,i=0,n=TPt,o,s;for(o=0;o=r&&syh((YO-i)/l))throw new Gxe(Uxe);for(i+=(p-r)*l,r=p,o=0;oYO)throw new Gxe(Uxe);if(s===r){for(var m=i,f=Iv;;){var g=f<=n?Hxe:f>=n+tF?tF:f-n;if(m0&&e&a;a>>=1)t++;return t},dRt=function dRt(e){var t=null;switch(e.length){case 1:t=e[0];break;case 2:t=(e[0]&31)<<6|e[1]&63;break;case 3:t=(e[0]&15)<<12|(e[1]&63)<<6|e[2]&63;break;case 4:t=(e[0]&7)<<18|(e[1]&63)<<12|(e[2]&63)<<6|e[3]&63;break}return t>1114111?null:t},nAe=function nAe(e){e=hAe(e,lRt," ");for(var t=e.length,a="",r=0;rt){a+="%",r++;continue}var n=iAe(e,r+1);if(n!==n){a+=i,r++;continue}r+=2;var o=pRt(n);if(o===0)i=iRt(n);else{if(o===1||o>4){a+=iF,r++;continue}for(var s=[n],u=1;ut||CI(e,r)!=="%"));){var c=iAe(e,r+1);if(c!==c){r+=3;break}if(c>191||c<128)break;v0(s,c),r+=2,u++}if(s.length!==o){a+=iF;continue}var p=dRt(s);p===null?a+=iF:i=nRt(p)}}a+=i,r++}return a},mRt=/[!'()~]|%20/g,fRt={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"},gRt=function gRt(e){return fRt[e]},oAe=function oAe(e){return hAe(rRt(e),mRt,gRt)},nF=jPt(function(t,a){gAe(this,{type:fAe,target:Iu(t).entries,index:0,kind:a})},Ih,function(){var t=tRt(this),a=t.target,r=t.index++;if(!a||r>=a.length)return t.target=null,II(void 0,!0);var i=a[r];switch(t.kind){case"keys":return II(i.key,!1);case"values":return II(i.value,!1)}return II([i.key,i.value],!1)},!0),xAe=function xAe(e){this.entries=[],this.url=null,e!==void 0&&(mAe(e)?this.parseObject(e):this.parseQuery(typeof e=="string"?CI(e,0)==="?"?_Ae(e,1):e:Eo(e)))};xAe.prototype={type:Ih,bindURL:function bindURL(e){this.url=e,this.update()},parseObject:function parseObject(e){var t=this.entries,a=ZPt(e),r,i,n,o,s,u,c;if(a)for(r=Yxe(e,a),i=r.next;!(n=bI(i,r)).done;){if(o=Yxe(KPt(n.value)),s=o.next,(u=bI(s,o)).done||(c=bI(s,o)).done||!bI(s,o).done)throw new aRt("Expected sequence with length 2");v0(t,{key:Eo(u.value),value:Eo(c.value)})}else for(var p in e)HPt(e,p)&&v0(t,{key:p,value:Eo(e[p])})},parseQuery:function parseQuery(e){if(e)for(var t=this.entries,a=rAe(e,"&"),r=0,i,n;r0?arguments[0]:void 0,a=gAe(this,new xAe(t));kv||(this.size=a.entries.length)},bh=SI.prototype;GPt(bh,{append:function append(t,a){var r=Iu(this);wh(arguments.length,2),v0(r.entries,{key:Eo(t),value:Eo(a)}),kv||this.size++,r.updateURL()},delete:function _delete(e){for(var t=Iu(this),a=wh(arguments.length,1),r=t.entries,i=Eo(e),n=a<2?void 0:arguments[1],o=n===void 0?n:Eo(n),s=0;sr.key?1:-1}),t.updateURL()},forEach:function forEach(t){for(var a=Iu(this).entries,r=WPt(t,arguments.length>1?arguments[1]:void 0),i=0,n;i1?oF(arguments[1]):{})}}),aF(EI)&&(kI=function kI(t){return dAe(this,rF),new EI(t,arguments.length>1?oF(arguments[1]):{})},rF.constructor=kI,kI.prototype=rF,sF({global:!0,constructor:!0,dontCallGetSet:!0,forced:!0},{Request:kI})));var sAe,uAe,oF,kI;AAe.exports={URLSearchParams:SI,getState:Iu}});var OAe=T(function(){"use strict";sN();var hRt=ne(),EF=Ut(),_Rt=bv(),SF=et(),vAe=ts(),Bu=Oe(),RI=mr(),ku=bi(),xRt=is(),IF=Ma(),BF=FQ(),kh=dP(),kl=zs(),ARt=ZA().codeAt,vRt=Jxe(),Pp=ga(),yRt=Io(),wRt=Ws(),MAe=cF(),PAe=Fr(),bRt=PAe.set,QI=PAe.getterFor("URL"),IRt=MAe.URLSearchParams,kRt=MAe.getState,Ev=SF.URL,kF=SF.TypeError,DI=SF.parseInt,CRt=Math.floor,yAe=Math.pow,Su=Bu("".charAt),Cl=Bu(/./.exec),Bv=Bu([].join),ERt=Bu(1.1.toString),SRt=Bu([].pop),Eh=Bu([].push),pF=Bu("".replace),BRt=Bu([].shift),TRt=Bu("".split),Mv=Bu("".slice),NI=Bu("".toLowerCase),MRt=Bu([].unshift),PRt="Invalid authority",dF="Invalid scheme",wf="Invalid host",wAe="Invalid port",RAe=/[a-z]/i,RRt=/[\d+-.a-z]/i,CF=/\d/,QRt=/^0x/i,DRt=/^[0-7]+$/,NRt=/^\d+$/,QAe=/^[\da-f]+$/i,ORt=/[\0\t\n\r #%/:<>?@[\\\]^|]/,FRt=/[\0\t\n\r #/:<>?@[\\\]^|]/,qRt=/^[\u0000-\u0020]+/,LRt=/(^|[^\u0000-\u0020])[\u0000-\u0020]+$/,$Rt=/[\t\n\r]/g,Cu,URt=function URt(e){var t=TRt(e,"."),a,r,i,n,o,s,u;if(t.length&&t[t.length-1]===""&&t.length--,a=t.length,a>4)return e;for(r=[],i=0;i1&&Su(n,0)==="0"&&(o=Cl(QRt,n)?16:8,n=Mv(n,o===8?1:2)),n==="")s=0;else{if(!Cl(o===10?NRt:o===8?DRt:QAe,n))return e;s=DI(n,o)}Eh(r,s)}for(i=0;i=yAe(256,5-a))return null}else if(s>255)return null;for(u=SRt(r),i=0;i6))return;for(s=0;m();){if(u=null,s>0)if(m()==="."&&s<4)i++;else return;if(!Cl(CF,m()))return;for(;Cl(CF,m());){if(c=DI(m(),10),u===null)u=c;else{if(u===0)return;u=u*10+c}if(u>255)return;i++}t[a]=t[a]*256+u,s++,(s===2||s===4)&&a++}if(s!==4)return;break}else if(m()===":"){if(i++,!m())return}else if(m())return;t[a++]=n}if(r!==null)for(p=a-r,a=7;a!==0&&p>0;)l=t[a],t[a--]=t[r+p-1],t[r+--p]=l;else if(a!==8)return;return t},zRt=function zRt(e){for(var t=null,a=1,r=null,i=0,n=0;n<8;n++)e[n]!==0?(i>a&&(t=r,a=i),r=null,i=0):(r===null&&(r=n),++i);return i>a?r:t},Sv=function Sv(e){var t,a,r,i;if(typeof e=="number"){for(t=[],a=0;a<4;a++)MRt(t,e%256),e=CRt(e/256);return Bv(t,".")}if((typeof e==="undefined"?"undefined":_type_of(e))=="object"){for(t="",r=zRt(e),a=0;a<8;a++)i&&e[a]===0||(i&&(i=!1),r===a?(t+=a?":":"::",i=!0):(t+=ERt(e[a],16),a<7&&(t+=":")));return"["+t+"]"}return e},PI={},DAe=BF({},PI,{" ":1,'"':1,"<":1,">":1,"`":1}),NAe=BF({},DAe,{"#":1,"?":1,"{":1,"}":1}),mF=BF({},NAe,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),y0=function y0(e,t){var a=ARt(e,0);return a>32&&a<127&&!IF(t,e)?e:encodeURIComponent(e)},BI={ftp:21,file:null,http:80,https:443,ws:80,wss:443},Tv=function Tv(e,t){var a;return e.length===2&&Cl(RAe,Su(e,0))&&((a=Su(e,1))===":"||!t&&a==="|")},bAe=function bAe(e){var t;return e.length>1&&Tv(Mv(e,0,2))&&(e.length===2||(t=Su(e,2))==="/"||t==="\\"||t==="?"||t==="#")},jRt=function jRt(e){return e==="."||NI(e)==="%2e"},HRt=function HRt(e){return e=NI(e),e===".."||e==="%2e."||e===".%2e"||e==="%2e%2e"},fF={},IAe={},gF={},kAe={},CAe={},hF={},EAe={},SAe={},TI={},MI={},_F={},xF={},AF={},vF={},BAe={},yF={},Ch={},Dc={},TAe={},bf={},Mp={},TF=function TF1(e,t,a){var r=Pp(e),i,n,o;if(t){if(n=this.parse(r),n)throw new kF(n);this.searchParams=null}else{if(a!==void 0&&(i=new TF(a,!0)),n=this.parse(r,null,i),n)throw new kF(n);o=kRt(new IRt),o.bindURL(this),this.searchParams=o}};TF.prototype={type:"URL",parse:function parse(e,t,a){var r=this,i=t||fF,n=0,o="",s=!1,u=!1,c=!1,p,l,m,f;for(e=Pp(e),t||(r.scheme="",r.username="",r.password="",r.host=null,r.port=null,r.path=[],r.query=null,r.fragment=null,r.cannotBeABaseURL=!1,e=pF(e,qRt,""),e=pF(e,LRt,"$1")),e=pF(e,$Rt,""),p=kh(e);n<=p.length;){switch(l=p[n],i){case fF:if(l&&Cl(RAe,l))o+=NI(l),i=IAe;else{if(t)return dF;i=gF;continue}break;case IAe:if(l&&(Cl(RRt,l)||l==="+"||l==="-"||l==="."))o+=NI(l);else if(l===":"){if(t&&(r.isSpecial()!==IF(BI,o)||o==="file"&&(r.includesCredentials()||r.port!==null)||r.scheme==="file"&&!r.host))return;if(r.scheme=o,t){r.isSpecial()&&BI[r.scheme]===r.port&&(r.port=null);return}o="",r.scheme==="file"?i=vF:r.isSpecial()&&a&&a.scheme===r.scheme?i=kAe:r.isSpecial()?i=SAe:p[n+1]==="/"?(i=CAe,n++):(r.cannotBeABaseURL=!0,Eh(r.path,""),i=TAe)}else{if(t)return dF;o="",i=gF,n=0;continue}break;case gF:if(!a||a.cannotBeABaseURL&&l!=="#")return dF;if(a.cannotBeABaseURL&&l==="#"){r.scheme=a.scheme,r.path=kl(a.path),r.query=a.query,r.fragment="",r.cannotBeABaseURL=!0,i=Mp;break}i=a.scheme==="file"?vF:hF;continue;case kAe:if(l==="/"&&p[n+1]==="/")i=TI,n++;else{i=hF;continue}break;case CAe:if(l==="/"){i=MI;break}else{i=Dc;continue}case hF:if(r.scheme=a.scheme,l===Cu)r.username=a.username,r.password=a.password,r.host=a.host,r.port=a.port,r.path=kl(a.path),r.query=a.query;else if(l==="/"||l==="\\"&&r.isSpecial())i=EAe;else if(l==="?")r.username=a.username,r.password=a.password,r.host=a.host,r.port=a.port,r.path=kl(a.path),r.query="",i=bf;else if(l==="#")r.username=a.username,r.password=a.password,r.host=a.host,r.port=a.port,r.path=kl(a.path),r.query=a.query,r.fragment="",i=Mp;else{r.username=a.username,r.password=a.password,r.host=a.host,r.port=a.port,r.path=kl(a.path),r.path.length--,i=Dc;continue}break;case EAe:if(r.isSpecial()&&(l==="/"||l==="\\"))i=TI;else if(l==="/")i=MI;else{r.username=a.username,r.password=a.password,r.host=a.host,r.port=a.port,i=Dc;continue}break;case SAe:if(i=TI,l!=="/"||Su(o,n+1)!=="/")continue;n++;break;case TI:if(l!=="/"&&l!=="\\"){i=MI;continue}break;case MI:if(l==="@"){s&&(o="%40"+o),s=!0,m=kh(o);for(var g=0;g65535)return wAe;r.port=r.isSpecial()&&A===BI[r.scheme]?null:A,o=""}if(t)return;i=Ch;continue}else return wAe;break;case vF:if(r.scheme="file",l==="/"||l==="\\")i=BAe;else if(a&&a.scheme==="file")switch(l){case Cu:r.host=a.host,r.path=kl(a.path),r.query=a.query;break;case"?":r.host=a.host,r.path=kl(a.path),r.query="",i=bf;break;case"#":r.host=a.host,r.path=kl(a.path),r.query=a.query,r.fragment="",i=Mp;break;default:bAe(Bv(kl(p,n),""))||(r.host=a.host,r.path=kl(a.path),r.shortenPath()),i=Dc;continue}else{i=Dc;continue}break;case BAe:if(l==="/"||l==="\\"){i=yF;break}a&&a.scheme==="file"&&!bAe(Bv(kl(p,n),""))&&(Tv(a.path[0],!0)?Eh(r.path,a.path[0]):r.host=a.host),i=Dc;continue;case yF:if(l===Cu||l==="/"||l==="\\"||l==="?"||l==="#"){if(!t&&Tv(o))i=Dc;else if(o===""){if(r.host="",t)return;i=Ch}else{if(f=r.parseHost(o),f)return f;if(r.host==="localhost"&&(r.host=""),t)return;o="",i=Ch}continue}else o+=l;break;case Ch:if(r.isSpecial()){if(i=Dc,l!=="/"&&l!=="\\")continue}else if(!t&&l==="?")r.query="",i=bf;else if(!t&&l==="#")r.fragment="",i=Mp;else if(l!==Cu&&(i=Dc,l!=="/"))continue;break;case Dc:if(l===Cu||l==="/"||l==="\\"&&r.isSpecial()||!t&&(l==="?"||l==="#")){if(HRt(o)?(r.shortenPath(),l!=="/"&&!(l==="\\"&&r.isSpecial())&&Eh(r.path,"")):jRt(o)?l!=="/"&&!(l==="\\"&&r.isSpecial())&&Eh(r.path,""):(r.scheme==="file"&&!r.path.length&&Tv(o)&&(r.host&&(r.host=""),o=Su(o,0)+":"),Eh(r.path,o)),o="",r.scheme==="file"&&(l===Cu||l==="?"||l==="#"))for(;r.path.length>1&&r.path[0]==="";)BRt(r.path);l==="?"?(r.query="",i=bf):l==="#"&&(r.fragment="",i=Mp)}else o+=y0(l,NAe);break;case TAe:l==="?"?(r.query="",i=bf):l==="#"?(r.fragment="",i=Mp):l!==Cu&&(r.path[0]+=y0(l,PI));break;case bf:!t&&l==="#"?(r.fragment="",i=Mp):l!==Cu&&(l==="'"&&r.isSpecial()?r.query+="%27":l==="#"?r.query+="%23":r.query+=y0(l,PI));break;case Mp:l!==Cu&&(r.fragment+=y0(l,DAe));break}n++}},parseHost:function parseHost(e){var t,a,r;if(Su(e,0)==="["){if(Su(e,e.length-1)!=="]"||(t=GRt(Mv(e,1,-1)),!t))return wf;this.host=t}else if(this.isSpecial()){if(e=vRt(e),Cl(ORt,e)||(t=URt(e),t===null))return wf;this.host=t}else{if(Cl(FRt,e))return wf;for(t="",a=kh(e),r=0;r1?arguments[1]:void 0,i=bRt(a,new TF(t,!1,r));EF||(a.href=i.serialize(),a.origin=i.getOrigin(),a.protocol=i.getProtocol(),a.username=i.getUsername(),a.password=i.getPassword(),a.host=i.getHost(),a.hostname=i.getHostname(),a.port=i.getPort(),a.pathname=i.getPathname(),a.search=i.getSearch(),a.searchParams=i.getSearchParams(),a.hash=i.getHash())},So=Sh.prototype,Eu=function Eu(e,t){return{get:function get(){return QI(this)[e]()},set:t&&function(a){return QI(this)[t](a)},configurable:!0,enumerable:!0}};EF&&(ku(So,"href",Eu("serialize","setHref")),ku(So,"origin",Eu("getOrigin")),ku(So,"protocol",Eu("getProtocol","setProtocol")),ku(So,"username",Eu("getUsername","setUsername")),ku(So,"password",Eu("getPassword","setPassword")),ku(So,"host",Eu("getHost","setHost")),ku(So,"hostname",Eu("getHostname","setHostname")),ku(So,"port",Eu("getPort","setPort")),ku(So,"pathname",Eu("getPathname","setPathname")),ku(So,"search",Eu("getSearch","setSearch")),ku(So,"searchParams",Eu("getSearchParams")),ku(So,"hash",Eu("getHash","setHash")));RI(So,"toJSON",function(){return QI(this).serialize()},{enumerable:!0});RI(So,"toString",function(){return QI(this).serialize()},{enumerable:!0});Ev&&(wF=Ev.createObjectURL,bF=Ev.revokeObjectURL,wF&&RI(Sh,"createObjectURL",vAe(wF,Ev)),bF&&RI(Sh,"revokeObjectURL",vAe(bF,Ev)));var wF,bF;yRt(Sh,"URL");hRt({global:!0,constructor:!0,forced:!_Rt,sham:!EF},{URL:Sh})});var FAe=T(function(){"use strict";OAe()});var $Ae=T(function(){"use strict";var WRt=ne(),VRt=Ta(),LAe=Qe(),KRt=Ws(),qAe=ga(),JRt=bv(),MF=VRt("URL"),ZRt=JRt&&LAe(function(){MF.canParse()}),YRt=LAe(function(){return MF.canParse.length!==1});WRt({target:"URL",stat:!0,forced:!ZRt||YRt},{canParse:function canParse(t){var a=KRt(arguments.length,1),r=qAe(t),i=a<2||arguments[1]===void 0?void 0:qAe(arguments[1]);try{return!!new MF(r,i)}catch(n){return!1}}})});var GAe=T(function(){"use strict";var XRt=ne(),eQt=Ta(),tQt=Ws(),UAe=ga(),aQt=bv(),rQt=eQt("URL");XRt({target:"URL",stat:!0,forced:!aQt},{parse:function parse(t){var a=tQt(arguments.length,1),r=UAe(t),i=a<2||arguments[1]===void 0?void 0:UAe(arguments[1]);try{return new rQt(r,i)}catch(n){return null}}})});var zAe=T(function(){"use strict";var iQt=ne(),nQt=Bt();iQt({target:"URL",proto:!0,enumerable:!0},{toJSON:function toJSON(){return nQt(URL.prototype.toString,this)}})});var jAe=T(function(){"use strict";cF()});var KAe=T(function(){"use strict";var oQt=mr(),OI=Oe(),HAe=ga(),sQt=Ws(),VAe=URLSearchParams,FI=VAe.prototype,uQt=OI(FI.append),WAe=OI(FI.delete),lQt=OI(FI.forEach),cQt=OI([].push),PF=new VAe("a=1&a=2&b=3");PF.delete("a",1);PF.delete("b",void 0);PF+""!="a=2"&&oQt(FI,"delete",function(e){var t=arguments.length,a=t<2?void 0:arguments[1];if(t&&a===void 0)return WAe(this,e);var r=[];lQt(this,function(l,m){cQt(r,{key:m,value:l})}),sQt(t,1);for(var i=HAe(e),n=HAe(a),o=0,s=0,u=!1,c=r.length,p;o2){var u=a.lastIndexOf("/");if(u!==a.length-1){u===-1?(a="",r=0):(a=a.slice(0,u),r=a.length-1-a.lastIndexOf("/")),i=s,n=0;continue}}else if(a.length===2||a.length===1){a="",r=0,i=s,n=0;continue}}t&&(a.length>0?a+="/..":a="..",r=2)}else a.length>0?a+="/"+e.slice(i+1,s):a=e.slice(i+1,s),r=s-i-1;i=s,n=0}else o===46&&n!==-1?++n:n=-1}return a};var XGt=function XGt(e,t){var a=t.dir||t.root,r=t.base||(t.name||"")+(t.ext||"");return a?a===t.root?a+r:a+e+r:r};var m1={resolve:function resolve(){for(var t="",a=!1,r,i=arguments.length-1;i>=-1&&!a;i--){var n;i>=0?n=arguments[i]:(r===void 0&&(r=process.cwd()),n=r),zc(n),n.length!==0&&(t=n+"/"+t,a=n.charCodeAt(0)===47)}return t=Y3e(t,!a),a?t.length>0?"/"+t:"/":t.length>0?t:"."},normalize:function normalize(t){if(zc(t),t.length===0)return".";var a=t.charCodeAt(0)===47,r=t.charCodeAt(t.length-1)===47;return t=Y3e(t,!a),t.length===0&&!a&&(t="."),t.length>0&&r&&(t+="/"),a?"/"+t:t},isAbsolute:function isAbsolute(t){return zc(t),t.length>0&&t.charCodeAt(0)===47},join:function join(){if(arguments.length===0)return".";for(var t,a=0;a0&&(t===void 0?t=r:t+="/"+r)}return t===void 0?".":m1.normalize(t)},relative:function relative(t,a){if(zc(t),zc(a),t===a||(t=m1.resolve(t),a=m1.resolve(a),t===a))return"";for(var r=1;rc){if(a.charCodeAt(o+l)===47)return a.slice(o+l+1);if(l===0)return a.slice(o+l)}else n>c&&(t.charCodeAt(r+l)===47?p=l:l===0&&(p=0));break}var m=t.charCodeAt(r+l),f=a.charCodeAt(o+l);if(m!==f)break;m===47&&(p=l)}var g="";for(l=r+p+1;l<=i;++l)(l===i||t.charCodeAt(l)===47)&&(g.length===0?g+="..":g+="/..");return g.length>0?g+a.slice(o+p):(o+=p,a.charCodeAt(o)===47&&++o,a.slice(o))},_makeLong:function _makeLong(t){return t},dirname:function dirname(t){if(zc(t),t.length===0)return".";for(var a=t.charCodeAt(0),r=a===47,i=-1,n=!0,o=t.length-1;o>=1;--o)if(a=t.charCodeAt(o),a===47){if(!n){i=o;break}}else n=!1;return i===-1?r?"/":".":r&&i===1?"//":t.slice(0,i)},basename:function basename(t,a){if(a!==void 0&&typeof a!="string")throw new TypeError('"ext" argument must be a string');zc(t);var r=0,i=-1,n=!0,o;if(a!==void 0&&a.length>0&&a.length<=t.length){if(a.length===t.length&&a===t)return"";var s=a.length-1,u=-1;for(o=t.length-1;o>=0;--o){var c=t.charCodeAt(o);if(c===47){if(!n){r=o+1;break}}else u===-1&&(n=!1,u=o+1),s>=0&&(c===a.charCodeAt(s)?--s===-1&&(i=o):(s=-1,i=u))}return r===i?i=u:i===-1&&(i=t.length),t.slice(r,i)}else{for(o=t.length-1;o>=0;--o)if(t.charCodeAt(o)===47){if(!n){r=o+1;break}}else i===-1&&(n=!1,i=o+1);return i===-1?"":t.slice(r,i)}},extname:function extname(t){zc(t);for(var a=-1,r=0,i=-1,n=!0,o=0,s=t.length-1;s>=0;--s){var u=t.charCodeAt(s);if(u===47){if(!n){r=s+1;break}continue}i===-1&&(n=!1,i=s+1),u===46?a===-1?a=s:o!==1&&(o=1):a!==-1&&(o=-1)}return a===-1||i===-1||o===0||o===1&&a===i-1&&a===r+1?"":t.slice(a,i)},format:function format(t){if(t===null||(typeof t==="undefined"?"undefined":_type_of(t))!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+(typeof t==="undefined"?"undefined":_type_of(t)));return XGt("/",t)},parse:function parse(t){zc(t);var a={root:"",dir:"",base:"",ext:"",name:""};if(t.length===0)return a;var r=t.charCodeAt(0),i=r===47,n;i?(a.root="/",n=1):n=0;for(var o=-1,s=0,u=-1,c=!0,p=t.length-1,l=0;p>=n;--p){if(r=t.charCodeAt(p),r===47){if(!c){s=p+1;break}continue}u===-1&&(c=!1,u=p+1),r===46?o===-1?o=p:l!==1&&(l=1):o!==-1&&(l=-1)}return o===-1||u===-1||l===0||l===1&&o===u-1&&o===s+1?u!==-1&&(s===0&&i?a.base=a.name=t.slice(1,u):a.base=a.name=t.slice(s,u)):(s===0&&i?(a.name=t.slice(1,o),a.base=t.slice(1,u)):(a.name=t.slice(s,o),a.base=t.slice(s,u)),a.ext=t.slice(o,u)),s>0?a.dir=t.slice(0,s-1):i&&(a.dir="/"),a},sep:"/",delimiter:":",win32:null,posix:null};m1.posix=m1;X3e.exports=m1});var a4e=T(function(t4e,Xq){(function(e){if((typeof t4e==="undefined"?"undefined":_type_of(t4e))=="object"&&typeof Xq!="undefined")Xq.exports=e();else if(typeof define=="function"&&define.amd)define([],e);else{var t;typeof window!="undefined"?t=window:typeof global!="undefined"?t=global:typeof self!="undefined"?t=self:t=this,t.localforage=e()}})(function(){var e,t,a;return(function r(i,n,o){function s(p,l){if(!n[p]){if(!i[p]){var m=typeof require=="function"&&require;if(!l&&m)return m(p,!0);if(u)return u(p,!0);var f=new Error("Cannot find module '"+p+"'");throw f.code="MODULE_NOT_FOUND",f}var g=n[p]={exports:{}};i[p][0].call(g.exports,function(h){var _=i[p][1][h];return s(_||h)},g,g.exports,r,i,n,o)}return n[p].exports}for(var u=typeof require=="function"&&require,c=0;c=43)}}).catch(function(){return!1})}function C(H){return typeof x=="boolean"?m.resolve(x):k(H).then(function(ue){return x=ue,x})}function E(H){var ue=y[H.name],Y={};Y.promise=new m(function(fe,xe){Y.resolve=fe,Y.reject=xe}),ue.deferredOperations.push(Y),ue.dbReady?ue.dbReady=ue.dbReady.then(function(){return Y.promise}):ue.dbReady=Y.promise}function P(H){var ue=y[H.name],Y=ue.deferredOperations.pop();if(Y)return Y.resolve(),Y.promise}function B(H,ue){var Y=y[H.name],fe=Y.deferredOperations.pop();if(fe)return fe.reject(ue),fe.promise}function M(H,ue){return new m(function(Y,fe){if(y[H.name]=y[H.name]||ae(),H.db)if(ue)E(H),H.db.close();else return Y(H.db);var xe=[H.name];ue&&xe.push(H.version);var de=c.open.apply(c,xe);ue&&(de.onupgradeneeded=function(ke){var Re=de.result;try{Re.createObjectStore(H.storeName),ke.oldVersion<=1&&Re.createObjectStore(A)}catch(qe){if(qe.name==="ConstraintError")console.warn('The database "'+H.name+'" has been upgraded from version '+ke.oldVersion+" to version "+ke.newVersion+', but the storage "'+H.storeName+'" already exists.');else throw qe}}),de.onerror=function(ke){ke.preventDefault(),fe(de.error)},de.onsuccess=function(){var ke=de.result;ke.onversionchange=function(Re){Re.target.close()},Y(ke),P(H)}})}function R(H){return M(H,!1)}function N(H){return M(H,!0)}function Q(H,ue){if(!H.db)return!0;var Y=!H.db.objectStoreNames.contains(H.storeName),fe=H.versionH.db.version;if(fe&&(H.version!==ue&&console.warn('The database "'+H.name+"\" can't be downgraded from version "+H.db.version+" to version "+H.version+"."),H.version=H.db.version),xe||Y){if(Y){var de=H.db.version+1;de>H.version&&(H.version=de)}return!0}return!1}function O(H){return new m(function(ue,Y){var fe=new FileReader;fe.onerror=Y,fe.onloadend=function(xe){var de=btoa(xe.target.result||"");ue({__local_forage_encoded_blob:!0,data:de,type:H.type})},fe.readAsBinaryString(H)})}function G(H){var ue=w(atob(H.data));return l([ue],{type:H.type})}function $(H){return H&&H.__local_forage_encoded_blob}function K(H){var ue=this,Y=ue._initReady().then(function(){var fe=y[ue._dbInfo.name];if(fe&&fe.dbReady)return fe.dbReady});return g(Y,H,H),Y}function U(H){E(H);for(var ue=y[H.name],Y=ue.forages,fe=0;fe0&&(!H.db||de.name==="InvalidStateError"||de.name==="NotFoundError"))return m.resolve().then(function(){if(!H.db||de.name==="NotFoundError"&&!H.db.objectStoreNames.contains(H.storeName)&&H.version<=H.db.version)return H.db&&(H.version=H.db.version+1),N(H)}).then(function(){return U(H).then(function(){j(H,ue,Y,fe-1)})}).catch(Y);Y(de)}}function ae(){return{forages:[],db:null,dbReady:null,deferredOperations:[]}}function _e(H){var ue=this,Y={db:null};if(H)for(var fe in H)Y[fe]=H[fe];var xe=y[Y.name];xe||(xe=ae(),y[Y.name]=xe),xe.forages.push(ue),ue._initReady||(ue._initReady=ue.ready,ue.ready=K);var de=[];function ke(){return m.resolve()}for(var Re=0;Re>4,Ye[xe++]=(ke&15)<<4|Re>>2,Ye[xe++]=(Re&3)<<6|qe&63;return Ne}function Z(H){var ue=new Uint8Array(H),Y="",fe;for(fe=0;fe>2],Y+=ye[(ue[fe]&3)<<4|ue[fe+1]>>4],Y+=ye[(ue[fe+1]&15)<<2|ue[fe+2]>>6],Y+=ye[ue[fe+2]&63];return ue.length%3===2?Y=Y.substring(0,Y.length-1)+"=":ue.length%3===1&&(Y=Y.substring(0,Y.length-2)+"=="),Y}function Ee(H,ue){var Y="";if(H&&(Y=yo.call(H)),H&&(Y==="[object ArrayBuffer]"||H.buffer&&yo.call(H.buffer)==="[object ArrayBuffer]")){var fe,xe=ut;_instanceof(H,ArrayBuffer)?(fe=H,xe+=Ke):(fe=H.buffer,Y==="[object Int8Array]"?xe+=zt:Y==="[object Uint8Array]"?xe+=Rt:Y==="[object Uint8ClampedArray]"?xe+=vt:Y==="[object Int16Array]"?xe+=Tt:Y==="[object Uint16Array]"?xe+=tn:Y==="[object Int32Array]"?xe+=He:Y==="[object Uint32Array]"?xe+=pl:Y==="[object Float32Array]"?xe+=Zn:Y==="[object Float64Array]"?xe+=dl:ue(new Error("Failed to get type for BinaryArray"))),ue(xe+Z(fe))}else if(Y==="[object Blob]"){var de=new FileReader;de.onload=function(){var _$ke=At+H.type+"~"+Z(this.result);ue(ut+pt+_$ke)},de.readAsArrayBuffer(H)}else try{ue(JSON.stringify(H))}catch(ke){console.error("Couldn't convert value into a JSON string: ",H),ue(null,ke)}}function Ia(H){if(H.substring(0,lt)!==ut)return JSON.parse(H);var ue=H.substring(vo),Y=H.substring(lt,vo),fe;if(Y===pt&&Zt.test(ue)){var xe=ue.match(Zt);fe=xe[1],ue=ue.substring(xe[0].length)}var de=Yn(ue);switch(Y){case Ke:return de;case pt:return l([de],{type:fe});case zt:return new Int8Array(de);case Rt:return new Uint8Array(de);case vt:return new Uint8ClampedArray(de);case Tt:return new Int16Array(de);case tn:return new Uint16Array(de);case He:return new Int32Array(de);case pl:return new Uint32Array(de);case Zn:return new Float32Array(de);case dl:return new Float64Array(de);default:throw new Error("Unkown type: "+Y)}}var Wt={serialize:Ee,deserialize:Ia,stringToBuffer:Yn,bufferToString:Z};function cr(H,ue,Y,fe){H.executeSql("CREATE TABLE IF NOT EXISTS "+ue.storeName+" (id INTEGER PRIMARY KEY, key unique, value)",[],Y,fe)}function li(H){var ue=this,Y={db:null};if(H)for(var fe in H)Y[fe]=typeof H[fe]!="string"?H[fe].toString():H[fe];var xe=new m(function(de,ke){try{Y.db=openDatabase(Y.name,String(Y.version),Y.description,Y.size)}catch(Re){return ke(Re)}Y.db.transaction(function(Re){cr(Re,Y,function(){ue._dbInfo=Y,de()},function(qe,Ne){ke(Ne)})},ke)});return Y.serializer=Wt,xe}function ir(H,ue,Y,fe,xe,de){H.executeSql(Y,fe,xe,function(ke,Re){Re.code===Re.SYNTAX_ERR?ke.executeSql("SELECT name FROM sqlite_master WHERE type='table' AND name = ?",[ue.storeName],function(qe,Ne){Ne.rows.length?de(qe,Re):cr(qe,ue,function(){qe.executeSql(Y,fe,xe,de)},de)},de):de(ke,Re)},de)}function Fs(H,ue){var Y=this;H=h(H);var fe=new m(function(xe,de){Y.ready().then(function(){var ke=Y._dbInfo;ke.db.transaction(function(Re){ir(Re,ke,"SELECT * FROM "+ke.storeName+" WHERE key = ? LIMIT 1",[H],function(qe,Ne){var Ye=Ne.rows.length?Ne.rows.item(0).value:null;Ye&&(Ye=ke.serializer.deserialize(Ye)),xe(Ye)},function(qe,Ne){de(Ne)})})}).catch(de)});return f(fe,ue),fe}function Jo(H,ue){var Y=this,fe=new m(function(xe,de){Y.ready().then(function(){var ke=Y._dbInfo;ke.db.transaction(function(Re){ir(Re,ke,"SELECT * FROM "+ke.storeName,[],function(qe,Ne){for(var Ye=Ne.rows,kt=Ye.length,Se=0;Se0){ke(_t.apply(xe,[H,qe,Y,fe-1]));return}Re(Se)}})})}).catch(Re)});return f(de,Y),de}function er(H,ue,Y){return _t.apply(this,[H,ue,Y,1])}function hu(H,ue){var Y=this;H=h(H);var fe=new m(function(xe,de){Y.ready().then(function(){var ke=Y._dbInfo;ke.db.transaction(function(Re){ir(Re,ke,"DELETE FROM "+ke.storeName+" WHERE key = ?",[H],function(){xe()},function(qe,Ne){de(Ne)})})}).catch(de)});return f(fe,ue),fe}function Nd(H){var ue=this,Y=new m(function(fe,xe){ue.ready().then(function(){var de=ue._dbInfo;de.db.transaction(function(ke){ir(ke,de,"DELETE FROM "+de.storeName,[],function(){fe()},function(Re,qe){xe(qe)})})}).catch(xe)});return f(Y,H),Y}function qs(H){var ue=this,Y=new m(function(fe,xe){ue.ready().then(function(){var de=ue._dbInfo;de.db.transaction(function(ke){ir(ke,de,"SELECT COUNT(key) as c FROM "+de.storeName,[],function(Re,qe){var Ne=qe.rows.item(0).c;fe(Ne)},function(Re,qe){xe(qe)})})}).catch(xe)});return f(Y,H),Y}function Ls(H,ue){var Y=this,fe=new m(function(xe,de){Y.ready().then(function(){var ke=Y._dbInfo;ke.db.transaction(function(Re){ir(Re,ke,"SELECT key FROM "+ke.storeName+" WHERE id = ? LIMIT 1",[H+1],function(qe,Ne){var Ye=Ne.rows.length?Ne.rows.item(0).key:null;xe(Ye)},function(qe,Ne){de(Ne)})})}).catch(de)});return f(fe,ue),fe}function _u(H){var ue=this,Y=new m(function(fe,xe){ue.ready().then(function(){var de=ue._dbInfo;de.db.transaction(function(ke){ir(ke,de,"SELECT key FROM "+de.storeName,[],function(Re,qe){for(var Ne=[],Ye=0;Ye '__WebKitDatabaseInfoTable__'",[],function(xe,de){for(var ke=[],Re=0;Re0}function x2(H){var ue=this,Y={};if(H)for(var fe in H)Y[fe]=H[fe];return Y.keyPrefix=Xn(H,ue._defaultConfig),Od()?(ue._dbInfo=Y,Y.serializer=Wt,m.resolve()):m.reject()}function A2(H){var ue=this,Y=ue.ready().then(function(){for(var fe=ue._dbInfo.keyPrefix,xe=localStorage.length-1;xe>=0;xe--){var de=localStorage.key(xe);de.indexOf(fe)===0&&localStorage.removeItem(de)}});return f(Y,H),Y}function v2(H,ue){var Y=this;H=h(H);var fe=Y.ready().then(function(){var xe=Y._dbInfo,de=localStorage.getItem(xe.keyPrefix+H);return de&&(de=xe.serializer.deserialize(de)),de});return f(fe,ue),fe}function y2(H,ue){var Y=this,fe=Y.ready().then(function(){for(var xe=Y._dbInfo,de=xe.keyPrefix,ke=de.length,Re=localStorage.length,qe=1,Ne=0;Ne=0;ke--){var Re=localStorage.key(ke);Re.indexOf(de)===0&&localStorage.removeItem(Re)}}):xe=m.reject("Invalid arguments"),f(xe,ue),xe}var ce={_driver:"localStorageWrapper",_initStorage:x2,_support:an(),iterate:y2,getItem:v2,setItem:qd,removeItem:Fd,clear:A2,length:Rx,key:w2,keys:yc,dropInstance:Ld},Te=function Te(ue,Y){return ue===Y||typeof ue=="number"&&typeof Y=="number"&&isNaN(ue)&&isNaN(Y)},st=function st(ue,Y){for(var fe=ue.length,xe=0;xe=r.val||a>=e.length-1)return r}};var s4e=function s4e(e,t){if(typeof e=="number"&&!isNaN(e))return e;if(typeof e!="string")return null;var a=t&&t.mode||"metric";a=rL(a);var r=pzt.exec(e),i,n;if(!r)return null;i=parseFloat(r[1]),n=r[4],n===void 0&&(n="b"),n=n.toLowerCase();var o;return a=="jedec"&&(o=g1["_"+n]),o===void 0&&(o=g1[n]),Math.floor(o.val*i)};u4e.exports=n4e("metric");var ozt=/\B(?=(\d{3})+(?!\d))/g,szt=/(?:\.0*|(\.[^0]+)0+)$/,g1={b:{val:1,longName:"byte",name:"B"},kb:{val:Math.pow(1e3,1),longName:"kilobyte",name:"kB"},mb:{val:Math.pow(1e3,2),longName:"megabyte",name:"MB"},gb:{val:Math.pow(1e3,3),longName:"gigabyte",name:"GB"},tb:{val:Math.pow(1e3,4),longName:"terabyte",name:"TB"},pb:{val:Math.pow(1e3,5),longName:"petabyte",name:"PB"},eb:{val:Math.pow(1e3,6),longName:"exabyte",name:"EB"},zb:{val:Math.pow(1e3,7),longName:"zettabyte",name:"ZB"},yb:{val:Math.pow(1e3,8),longName:"yottabyte",name:"YB"},kib:{val:Math.pow(1024,1),longName:"kibibyte",name:"KiB"},mib:{val:Math.pow(1024,2),longName:"mebibyte",name:"MiB"},gib:{val:Math.pow(1024,3),longName:"gibibyte",name:"GiB"},tib:{val:Math.pow(1024,4),longName:"tebibyte",name:"TiB"},pib:{val:Math.pow(1024,5),longName:"pebibyte",name:"PiB"},eib:{val:Math.pow(1024,6),longName:"exbibyte",name:"EiB"},zib:{val:Math.pow(1024,7),longName:"zebibyte",name:"ZiB"},yib:{val:Math.pow(1024,8),longName:"yobibyte",name:"YiB"},_kb:{val:Math.pow(1024,1),longName:"kilobyte",name:"kB"},_mb:{val:Math.pow(1024,2),longName:"megabyte",name:"MB"},_gb:{val:Math.pow(1024,3),longName:"gigabyte",name:"GB"},_tb:{val:Math.pow(1024,4),longName:"terabyte",name:"TB"}};var uzt=aL(["b","kb","mb","gb","tb","pb","eb","zb","yb"]),lzt=aL(["b","kib","mib","gib","tib","pib","eib","zib","yib"]),czt=aL(["b","_kb","_mb","_gb","_tb"]),pzt=/^((-|\+)?(\d+(?:\.\d+)?)) *((k|m|g|t|p|e|z|y)?i?(b))?$/i;function n4e(e){e=rL(e);function t(r){return r=r!==void 0?r:{},r.mode===void 0&&(r.mode=e),r}function a(r,i){return dzt(r,t(i))}return a.format=function(i,n){return o4e(i,t(n))},a.parse=function(i,n){return s4e(i,t(n))},a.withDefaultMode=n4e,a}});var A4e=T(function(Per,A1){var We=function We(){this.Diff_Timeout=1,this.Diff_EditCost=4,this.Match_Threshold=.5,this.Match_Distance=1e3,this.Patch_DeleteThreshold=.5,this.Patch_Margin=4,this.Match_MaxBits=32},Mr=-1,$r=1,ka=0;We.Diff=function(e,t){return[e,t]};We.prototype.diff_main=function(e,t,a,r){typeof r=="undefined"&&(this.Diff_Timeout<=0?r=Number.MAX_VALUE:r=new Date().getTime()+this.Diff_Timeout*1e3);var i=r;if(e==null||t==null)throw new Error("Null input. (diff_main)");if(e==t)return e?[new We.Diff(ka,e)]:[];typeof a=="undefined"&&(a=!0);var n=a,o=this.diff_commonPrefix(e,t),s=e.substring(0,o);e=e.substring(o),t=t.substring(o),o=this.diff_commonSuffix(e,t);var u=e.substring(e.length-o);e=e.substring(0,e.length-o),t=t.substring(0,t.length-o);var c=this.diff_compute_(e,t,n,i);return s&&c.unshift(new We.Diff(ka,s)),u&&c.push(new We.Diff(ka,u)),this.diff_cleanupMerge(c),c};We.prototype.diff_compute_=function(e,t,a,r){var i;if(!e)return[new We.Diff($r,t)];if(!t)return[new We.Diff(Mr,e)];var n=e.length>t.length?e:t,o=e.length>t.length?t:e,s=n.indexOf(o);if(s!=-1)return i=[new We.Diff($r,n.substring(0,s)),new We.Diff(ka,o),new We.Diff($r,n.substring(s+o.length))],e.length>t.length&&(i[0][0]=i[2][0]=Mr),i;if(o.length==1)return[new We.Diff(Mr,e),new We.Diff($r,t)];var u=this.diff_halfMatch_(e,t);if(u){var c=u[0],p=u[1],l=u[2],m=u[3],f=u[4],g=this.diff_main(c,l,a,r),h=this.diff_main(p,m,a,r);return g.concat([new We.Diff(ka,f)],h)}return a&&e.length>100&&t.length>100?this.diff_lineMode_(e,t,r):this.diff_bisect_(e,t,r)};We.prototype.diff_lineMode_=function(e,t,a){var r=this.diff_linesToChars_(e,t);e=r.chars1,t=r.chars2;var i=r.lineArray,n=this.diff_main(e,t,!1,a);this.diff_charsToLines_(n,i),this.diff_cleanupSemantic(n),n.push(new We.Diff(ka,""));for(var o=0,s=0,u=0,c="",p="";o=1&&u>=1){n.splice(o-s-u,s+u),o=o-s-u;for(var l=this.diff_main(c,p,!1,a),m=l.length-1;m>=0;m--)n.splice(o,0,l[m]);o=o+l.length}u=0,s=0,c="",p="";break}o++}return n.pop(),n};We.prototype.diff_bisect_=function(e,t,a){for(var r=e.length,i=t.length,n=Math.ceil((r+i)/2),o=n,s=2*n,u=new Array(s),c=new Array(s),p=0;pa);A++){for(var x=-A+f;x<=A-g;x+=2){var y=o+x,v;x==-A||x!=A&&u[y-1]r)g+=2;else if(I>i)f+=2;else if(m){var b=o+l-x;if(b>=0&&b=w)return this.diff_bisectSplit_(e,t,v,I,a)}}}for(var k=-A+h;k<=A-_;k+=2){var b=o+k,w;k==-A||k!=A&&c[b-1]r)_+=2;else if(C>i)h+=2;else if(!m){var y=o+l-k;if(y>=0&&y=w)return this.diff_bisectSplit_(e,t,v,I,a)}}}}return[new We.Diff(Mr,e),new We.Diff($r,t)]};We.prototype.diff_bisectSplit_=function(e,t,a,r,i){var n=e.substring(0,a),o=t.substring(0,r),s=e.substring(a),u=t.substring(r),c=this.diff_main(n,o,!1,i),p=this.diff_main(s,u,!1,i);return c.concat(p)};We.prototype.diff_linesToChars_=function(e,t){var a=[],r={};a[0]="";function i(u){for(var c="",p=0,l=-1,m=a.length;lr?e=e.substring(a-r):at.length?e:t,r=e.length>t.length?t:e;if(a.length<4||r.length*2=g.length?[v,I,b,w,y]:null}var o=n(a,r,Math.ceil(a.length/4)),s=n(a,r,Math.ceil(a.length/2)),u;if(!o&&!s)return null;s?o?u=o[4].length>s[4].length?o:s:u=s:u=o;var c,p,l,m;e.length>t.length?(c=u[0],p=u[1],l=u[2],m=u[3]):(l=u[0],m=u[1],c=u[2],p=u[3]);var f=u[4];return[c,p,l,m,f]};We.prototype.diff_cleanupSemantic=function(e){for(var t=!1,a=[],r=0,i=null,n=0,o=0,s=0,u=0,c=0;n0?a[r-1]:-1,o=0,s=0,u=0,c=0,i=null,t=!0)),n++;for(t&&this.diff_cleanupMerge(e),this.diff_cleanupSemanticLossless(e),n=1;n=f?(m>=p.length/2||m>=l.length/2)&&(e.splice(n,0,new We.Diff(ka,l.substring(0,m))),e[n-1][1]=p.substring(0,p.length-m),e[n+1][1]=l.substring(m),n++):(f>=p.length/2||f>=l.length/2)&&(e.splice(n,0,new We.Diff(ka,p.substring(0,f))),e[n-1][0]=$r,e[n-1][1]=l.substring(0,l.length-f),e[n+1][0]=Mr,e[n+1][1]=p.substring(f),n++),n++}n++}};We.prototype.diff_cleanupSemanticLossless=function(e){function t(f,g){if(!f||!g)return 6;var h=f.charAt(f.length-1),_=g.charAt(0),A=h.match(We.nonAlphaNumericRegex_),x=_.match(We.nonAlphaNumericRegex_),y=A&&h.match(We.whitespaceRegex_),v=x&&_.match(We.whitespaceRegex_),I=y&&h.match(We.linebreakRegex_),b=v&&_.match(We.linebreakRegex_),w=I&&f.match(We.blanklineEndRegex_),k=b&&g.match(We.blanklineStartRegex_);return w||k?5:I||b?4:A&&!y&&v?3:y||v?2:A||x?1:0}for(var a=1;a=l&&(l=m,u=r,c=i,p=n)}e[a-1][1]!=u&&(u?e[a-1][1]=u:(e.splice(a-1,1),a--),e[a][1]=c,p?e[a+1][1]=p:(e.splice(a+1,1),a--))}a++}};We.nonAlphaNumericRegex_=/[^a-zA-Z0-9]/;We.whitespaceRegex_=/\s/;We.linebreakRegex_=/[\r\n]/;We.blanklineEndRegex_=/\n\r?\n$/;We.blanklineStartRegex_=/^\r?\n\r?\n/;We.prototype.diff_cleanupEfficiency=function(e){for(var t=!1,a=[],r=0,i=null,n=0,o=!1,s=!1,u=!1,c=!1;n0?a[r-1]:-1,u=c=!1),t=!0)),n++;t&&this.diff_cleanupMerge(e)};We.prototype.diff_cleanupMerge=function(e){e.push(new We.Diff(ka,""));for(var t=0,a=0,r=0,i="",n="",o;t1?(a!==0&&r!==0&&(o=this.diff_commonPrefix(n,i),o!==0&&(t-a-r>0&&e[t-a-r-1][0]==ka?e[t-a-r-1][1]+=n.substring(0,o):(e.splice(0,0,new We.Diff(ka,n.substring(0,o))),t++),n=n.substring(o),i=i.substring(o)),o=this.diff_commonSuffix(n,i),o!==0&&(e[t][1]=n.substring(n.length-o)+e[t][1],n=n.substring(0,n.length-o),i=i.substring(0,i.length-o))),t-=a+r,e.splice(t,a+r),i.length&&(e.splice(t,0,new We.Diff(Mr,i)),t++),n.length&&(e.splice(t,0,new We.Diff($r,n)),t++),t++):t!==0&&e[t-1][0]==ka?(e[t-1][1]+=e[t][1],e.splice(t,1)):t++,r=0,a=0,i="",n="";break}e[e.length-1][1]===""&&e.pop();var s=!1;for(t=1;tt));o++)i=a,n=r;return e.length!=o&&e[o][0]===Mr?n:n+(t-i)};We.prototype.diff_prettyHtml=function(e){for(var t=[],a=/&/g,r=//g,n=/\n/g,o=0;o");switch(s){case $r:t[o]=''+c+"";break;case Mr:t[o]=''+c+"";break;case ka:t[o]=""+c+"";break}}return t.join("")};We.prototype.diff_text1=function(e){for(var t=[],a=0;athis.Match_MaxBits)throw new Error("Pattern too long for this browser.");var r=this.match_alphabet_(t),i=this;function n(v,I){var b=v/t.length,w=Math.abs(a-I);return i.Match_Distance?b+w/i.Match_Distance:w?1:b}var o=this.Match_Threshold,s=e.indexOf(t,a);s!=-1&&(o=Math.min(n(0,s),o),s=e.lastIndexOf(t,a+t.length),s!=-1&&(o=Math.min(n(0,s),o)));var u=1<=g;A--){var x=r[e.charAt(A-1)];if(f===0?_[A]=(_[A+1]<<1|1)&x:_[A]=(_[A+1]<<1|1)&x|((m[A+1]|m[A])<<1|1)|m[A+1],_[A]&u){var y=n(f,A-1);if(y<=o)if(o=y,s=A-1,s>a)g=Math.max(1,2*a-s);else break}}if(n(f+1,a)>o)break;m=_}return s};We.prototype.match_alphabet_=function(e){for(var t={},a=0;a2&&(this.diff_cleanupSemantic(i),this.diff_cleanupEfficiency(i));else if(e&&(typeof e==="undefined"?"undefined":_type_of(e))=="object"&&typeof t=="undefined"&&typeof a=="undefined")i=e,r=this.diff_text1(i);else if(typeof e=="string"&&t&&(typeof t==="undefined"?"undefined":_type_of(t))=="object"&&typeof a=="undefined")r=e,i=t;else if(typeof e=="string"&&typeof t=="string"&&a&&(typeof a==="undefined"?"undefined":_type_of(a))=="object")r=e,i=a;else throw new Error("Unknown call format to patch_make.");if(i.length===0)return[];for(var n=[],o=new We.patch_obj,s=0,u=0,c=0,p=r,l=r,m=0;m=2*this.Patch_Margin&&s&&(this.patch_addContext_(o,p),n.push(o),o=new We.patch_obj,s=0,p=l,u=c);break}f!==$r&&(u+=g.length),f!==Mr&&(c+=g.length)}return s&&(this.patch_addContext_(o,p),n.push(o)),n};We.prototype.patch_deepCopy=function(e){for(var t=[],a=0;athis.Match_MaxBits?(u=this.match_main(t,s.substring(0,this.Match_MaxBits),o),u!=-1&&(c=this.match_main(t,s.substring(s.length-this.Match_MaxBits),o+s.length-this.Match_MaxBits),(c==-1||u>=c)&&(u=-1))):u=this.match_main(t,s,o),u==-1)i[n]=!1,r-=e[n].length2-e[n].length1;else{i[n]=!0,r=u-o;var p;if(c==-1?p=t.substring(u,u+s.length):p=t.substring(u,c+this.Match_MaxBits),s==p)t=t.substring(0,u)+this.diff_text2(e[n].diffs)+t.substring(u+s.length);else{var l=this.diff_main(s,p,!1);if(s.length>this.Match_MaxBits&&this.diff_levenshtein(l)/s.length>this.Patch_DeleteThreshold)i[n]=!1;else{this.diff_cleanupSemanticLossless(l);for(var m=0,f,g=0;gn[0][1].length){var o=t-n[0][1].length;n[0][1]=a.substring(n[0][1].length)+n[0][1],i.start1-=o,i.start2-=o,i.length1+=o,i.length2+=o}if(i=e[e.length-1],n=i.diffs,n.length==0||n[n.length-1][0]!=ka)n.push(new We.Diff(ka,a)),i.length1+=t,i.length2+=t;else if(t>n[n.length-1][1].length){var o=t-n[n.length-1][1].length;n[n.length-1][1]+=a.substring(0,o),i.length1+=o,i.length2+=o}return a};We.prototype.patch_splitMax=function(e){for(var t=this.Match_MaxBits,a=0;a2*t?(s.length1+=p.length,i+=p.length,u=!1,s.diffs.push(new We.Diff(c,p)),r.diffs.shift()):(p=p.substring(0,t-s.length1-this.Patch_Margin),s.length1+=p.length,i+=p.length,c===ka?(s.length2+=p.length,n+=p.length):u=!1,s.diffs.push(new We.Diff(c,p)),p==r.diffs[0][1]?r.diffs.shift():r.diffs[0][1]=r.diffs[0][1].substring(p.length))}o=this.diff_text2(s.diffs),o=o.substring(o.length-this.Patch_Margin);var l=this.diff_text1(r.diffs).substring(0,this.Patch_Margin);l!==""&&(s.length1+=l.length,s.length2+=l.length,s.diffs.length!==0&&s.diffs[s.diffs.length-1][0]===ka?s.diffs[s.diffs.length-1][1]+=l:s.diffs.push(new We.Diff(ka,l))),u||e.splice(++a,0,s)}}};We.prototype.patch_toText=function(e){for(var t=[],a=0;a1&&(l==="/"||l===void 0)&&(f==="/"||f===void 0);g?(r+="((?:[^/]*(?:/|$))*)",c++):r+="([^/]*)"}break;default:r+=u}return(!s||!~s.indexOf("g"))&&(r="^"+r+"$"),new RegExp(r,s)}});var LC=T(function(Xp){"use strict";var Zbe=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",vVt=Zbe+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040",Ybe="["+Zbe+"]["+vVt+"]*",yVt=new RegExp("^"+Ybe+"$"),wVt=function wVt(e,t){var a=[],r=t.exec(e);for(;r;){var i=[];i.startIndex=t.lastIndex-r[0].length;var n=r.length;for(var o=0;o5&&r==="xml")return Ni("InvalidXml","XML declaration allowed only at the start of the document.",Do(e,t));if(e[t]=="?"&&e[t+1]==">"){t++;break}else continue}return t};var tIe=function tIe(e,t){if(e.length>t+5&&e[t+1]==="-"&&e[t+2]==="-"){for(t+=3;t"){t+=2;break}}else if(e.length>t+8&&e[t+1]==="D"&&e[t+2]==="O"&&e[t+3]==="C"&&e[t+4]==="T"&&e[t+5]==="Y"&&e[t+6]==="P"&&e[t+7]==="E"){var a=1;for(t+=8;t"&&(a--,a===0))break}else if(e.length>t+9&&e[t+1]==="["&&e[t+2]==="C"&&e[t+3]==="D"&&e[t+4]==="A"&&e[t+5]==="T"&&e[t+6]==="A"&&e[t+7]==="["){for(t+=8;t"){t+=2;break}}return t};var EVt=function EVt(e,t){var a="",r="",i=!1;for(;t"&&r===""){i=!0;break}a+=e[t]}return r!==""?!1:{value:a,index:t,tagClosed:i}};var aIe=function aIe(e,t){var a=JL.getAllMatches(e,SVt),r={};for(var i=0;i"&&e[n]!==" "&&e[n]!==" "&&e[n]!=="\n"&&e[n]!=="\r";n++)u+=e[n];if(u=u.trim(),u[u.length-1]==="/"&&(u=u.substring(0,u.length-1),n--),!PVt(u)){var l=void 0;return u.trim().length===0?l="Invalid space after '<'.":l="Tag '"+u+"' is an invalid name.",Ni("InvalidTag",l,Do(e,n))}var c=EVt(e,n);if(c===!1)return Ni("InvalidAttr","Attributes for '"+u+"' have open quote.",Do(e,n));var p=c.value;if(n=c.index,p[p.length-1]==="/"){var l6=n-p.length;p=p.substring(0,p.length-1);var m=aIe(p,t);if(m===!0)r=!0;else return Ni(m.err.code,m.err.msg,Do(e,l6+m.err.line))}else if(s)if(c.tagClosed){if(p.trim().length>0)return Ni("InvalidTag","Closing tag '"+u+"' can't have attributes or invalid starting.",Do(e,o));if(a.length===0)return Ni("InvalidTag","Closing tag '"+u+"' has not been opened.",Do(e,o));{var l10=a.pop();if(u!==l10.tagName){var m1=Do(e,l10.tagStartPos);return Ni("InvalidTag","Expected closing tag '"+l10.tagName+"' (opened in line "+m1.line+", col "+m1.col+") instead of closing tag '"+u+"'.",Do(e,o))}a.length==0&&(i=!0)}}else return Ni("InvalidTag","Closing tag '"+u+"' doesn't have proper closing.",Do(e,n));else{var l11=aIe(p,t);if(l11!==!0)return Ni(l11.err.code,l11.err.msg,Do(e,n-p.length+l11.err.line));if(i===!0)return Ni("InvalidXml","Multiple possible root nodes found.",Do(e,n));t.unpairedTags.indexOf(u)!==-1||a.push({tagName:u,tagStartPos:o}),r=!0}for(n++;n0)return Ni("InvalidXml","Invalid '"+JSON.stringify(a.map(function(n){return n.tagName}),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1})}else return Ni("InvalidXml","Start tag expected.",1);return!0};var kVt='"',CVt="'";var SVt=new RegExp("(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['\"])(([\\s\\S])*?)\\5)?","g")});var nIe=T(function(YL){var iIe={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function tagValueProcessor(e,t){return t},attributeValueProcessor:function attributeValueProcessor(e,t){return t},stopNodes:[],alwaysCreateTextNode:!1,isArray:function(){return!1},commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function updateTag(e,t,a){return e}},RVt=function RVt(e){return Object.assign({},iIe,e)};YL.buildOptions=RVt;YL.defaultOptions=iIe});var sIe=T(function(fur,oIe){"use strict";var XL=/*#__PURE__*/function(){function XL(t){_class_call_check(this,XL);this.tagname=t,this.child=[],this[":@"]={}}_create_class(XL,[{key:"add",value:function add(t,a){t==="__proto__"&&(t="#__proto__"),this.child.push(_define_property({},t,a))}},{key:"addChild",value:function addChild(t){var _obj;t.tagname==="__proto__"&&(t.tagname="#__proto__"),t[":@"]&&Object.keys(t[":@"]).length>0?this.child.push((_obj={},_define_property(_obj,t.tagname,t.child),_define_property(_obj,":@",t[":@"]),_obj)):this.child.push(_define_property({},t.tagname,t.child))}}]);return XL}();oIe.exports=XL});var lIe=T(function(gur,uIe){var DVt=function DVt(e,t){var a={};if(e[t+3]==="O"&&e[t+4]==="C"&&e[t+5]==="T"&&e[t+6]==="Y"&&e[t+7]==="P"&&e[t+8]==="E"){t=t+9;var r=1,i=!1,n=!1,o="";for(;t"){if(n?e[t-1]==="-"&&e[t-2]==="-"&&(n=!1,r--):r--,r===0)break}else e[t]==="["?i=!0:o+=e[t];if(r!==0)throw new Error("Unclosed DOCTYPE")}else throw new Error("Invalid Tag instead of DOCTYPE");return{entities:a,i:t}};var NVt=function NVt(e,t){var a="";for(;t1&&arguments[1]!==void 0?arguments[1]:{};if(t=Object.assign({},jVt,t),!e||typeof e!="string")return e;var a=e.trim();if(t.skipLike!==void 0&&t.skipLike.test(a))return e;if(e==="0")return 0;if(t.hex&&GVt.test(a))return VVt(a,16);if(a.search(/[eE]/)!==-1){var r=a.match(/^([-\+])?(0*)([0-9]*(\.[0-9]*)?[eE][-\+]?[0-9]+)$/);if(r){if(t.leadingZeros)a=(r[1]||"")+r[3];else if(!(r[2]==="0"&&r[3][0]==="."))return e;return t.eNotation?Number(a):e}else return e}else{var r6=zVt.exec(a);if(r6){var i=r6[1],n=r6[2],o=WVt(r6[3]);if(!t.leadingZeros&&n.length>0&&i&&a[2]!==".")return e;if(!t.leadingZeros&&n.length>0&&!i&&a[1]!==".")return e;if(t.leadingZeros&&n===e)return 0;{var s=Number(a),u=""+s;return u.search(/[eE]/)!==-1?t.eNotation?s:e:a.indexOf(".")!==-1?u==="0"&&o===""||u===o||i&&u==="-"+o?s:e:n?o===u||i+o===u?s:e:a===u||a===i+u?s:e}}else return e}};var WVt=function WVt(e){return e&&e.indexOf(".")!==-1&&(e=e.replace(/0+$/,""),e==="."?e="0":e[0]==="."?e="0"+e:e[e.length-1]==="."&&(e=e.substr(0,e.length-1))),e};var VVt=function VVt(e,t){if(parseInt)return parseInt(e,t);if(Number.parseInt)return Number.parseInt(e,t);if(window&&window.parseInt)return window.parseInt(e,t);throw new Error("parseInt, Number.parseInt, window.parseInt are not supported")};var GVt=/^[-+]?0x[a-fA-F0-9]+$/,zVt=/^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/,jVt={hex:!0,leadingZeros:!0,decimalPoint:".",eNotation:!0};cIe.exports=HVt});var e$=T(function(_ur,dIe){var KVt=function KVt(e){return typeof e=="function"?e:Array.isArray(e)?function(t){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=e[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var a=_step.value;if(typeof a=="string"&&t===a||_instanceof(a,RegExp)&&a.test(t))return!0}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}}:function(){return!1}};dIe.exports=KVt});var gIe=T(function(xur,fIe){"use strict";var XVt=function XVt(e){var t=Object.keys(e);for(var a=0;a0)){o||(e=this.replaceEntitiesValue(e));var s=this.options.tagValueProcessor(t,e,a,i,n);return s==null?e:(typeof s==="undefined"?"undefined":_type_of(s))!=(typeof e==="undefined"?"undefined":_type_of(e))||s!==e?s:this.options.trimValues?r$(e,this.options.parseTagValue,this.options.numberParseOptions):e.trim()===e?r$(e,this.options.parseTagValue,this.options.numberParseOptions):e}};var tKt=function tKt(e){if(this.options.removeNSPrefix){var t=e.split(":"),a=e.charAt(0)==="/"?"/":"";if(t[0]==="xmlns")return"";t.length===2&&(e=a+t[1])}return e};var rKt=function rKt(e,t,a){if(this.options.ignoreAttributes!==!0&&typeof e=="string"){var r=mIe.getAllMatches(e,aKt),i=r.length,n={};for(var o=0;o2&&arguments[2]!==void 0?arguments[2]:">";var r,i="";for(var n=t;n3&&arguments[3]!==void 0?arguments[3]:">";var i=lKt(e,t+1,r);if(!i)return;var n=i.data,o=i.index,s=n.search(/\s/),u=n,c=!0;s!==-1&&(u=n.substring(0,s),n=n.substring(s+1).trimStart());var p=u;if(a){var l=u.indexOf(":");l!==-1&&(u=u.substr(l+1),c=u!==i.data.substr(l+1))}return{tagName:u,tagExp:n,closeIndex:o,attrExpPresent:c,rawTagName:p}};var cKt=function cKt(e,t,a){var r=a,i=1;for(;a",a,"".concat(t," is not closed"));if(e.substring(a+2,n).trim()===t&&(i--,i===0))return{tagContent:e.substring(r,a),i:n};a=n}else if(e[a+1]==="?")a=jf(e,"?>",a+1,"StopNode is not closed.");else if(e.substr(a+1,3)==="!--")a=jf(e,"-->",a+3,"StopNode is not closed.");else if(e.substr(a+1,2)==="![")a=jf(e,"]]>",a,"StopNode is not closed.")-2;else{var n10=a$(e,a,">");n10&&((n10&&n10.tagName)===t&&n10.tagExp[n10.tagExp.length-1]!=="/"&&i++,a=n10.closeIndex)}};var r$=function r$(e,t,a){if(t&&typeof e=="string"){var r=e.trim();return r==="true"?!0:r==="false"?!1:ZVt(e,a)}else return mIe.isExist(e)?e:""};var mIe=LC(),Oy=sIe(),JVt=lIe(),ZVt=pIe(),YVt=e$(),t$=function t$(t){_class_call_check(this,t$);this.options=t,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"\xa2"},pound:{regex:/&(pound|#163);/g,val:"\xa3"},yen:{regex:/&(yen|#165);/g,val:"\xa5"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"\xa9"},reg:{regex:/&(reg|#174);/g,val:"\xae"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:function(a,r){return String.fromCharCode(Number.parseInt(r,10))}},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:function(a,r){return String.fromCharCode(Number.parseInt(r,16))}}},this.addExternalEntities=XVt,this.parseXml=iKt,this.parseTextData=eKt,this.resolveNameSpace=tKt,this.buildAttributesMap=rKt,this.isItStopNode=uKt,this.replaceEntitiesValue=oKt,this.readStopNodeData=cKt,this.saveTextToParentTag=sKt,this.addChild=nKt,this.ignoreAttributesFn=YVt(this.options.ignoreAttributes)};var aKt=new RegExp("([^\\s=]+)\\s*(=\\s*(['\"])([\\s\\S]*?)\\3)?","gm");var iKt=function iKt(e){e=e.replace(/\r\n?/g,"\n");var t=new Oy("!xml"),a=t,r="",i="";for(var n=0;n",n,"Closing Tag is not closed."),u=e.substring(n+2,s).trim();if(this.options.removeNSPrefix){var l=u.indexOf(":");l!==-1&&(u=u.substr(l+1))}this.options.transformTagName&&(u=this.options.transformTagName(u)),a&&(r=this.saveTextToParentTag(r,a,i));var c=i.substring(i.lastIndexOf(".")+1);if(u&&this.options.unpairedTags.indexOf(u)!==-1)throw new Error("Unpaired tag can not be used as closing tag: "));var p=0;c&&this.options.unpairedTags.indexOf(c)!==-1?(p=i.lastIndexOf(".",i.lastIndexOf(".")-1),this.tagsNodeStack.pop()):p=i.lastIndexOf("."),i=i.substring(0,p),a=this.tagsNodeStack.pop(),r="",n=s}else if(e[n+1]==="?"){var s6=a$(e,n,!1,"?>");if(!s6)throw new Error("Pi Tag is not closed.");if(r=this.saveTextToParentTag(r,a,i),!(this.options.ignoreDeclaration&&s6.tagName==="?xml"||this.options.ignorePiTags)){var u6=new Oy(s6.tagName);u6.add(this.options.textNodeName,""),s6.tagName!==s6.tagExp&&s6.attrExpPresent&&(u6[":@"]=this.buildAttributesMap(s6.tagExp,i,s6.tagName)),this.addChild(a,u6,i)}n=s6.closeIndex+1}else if(e.substr(n+1,3)==="!--"){var s10=jf(e,"-->",n+4,"Comment is not closed.");if(this.options.commentPropName){var u10=e.substring(n+4,s10-2);r=this.saveTextToParentTag(r,a,i),a.add(this.options.commentPropName,[_define_property({},this.options.textNodeName,u10)])}n=s10}else if(e.substr(n+1,2)==="!D"){var s11=JVt(e,n);this.docTypeEntities=s11.entities,n=s11.i}else if(e.substr(n+1,2)==="!["){var s12=jf(e,"]]>",n,"CDATA is not closed.")-2,u11=e.substring(n+9,s12);r=this.saveTextToParentTag(r,a,i);var c6=this.parseTextData(u11,a.tagname,i,!0,!1,!0,!0);c6==null&&(c6=""),this.options.cdataPropName?a.add(this.options.cdataPropName,[_define_property({},this.options.textNodeName,u11)]):a.add(this.options.textNodeName,c6),n=s12+2}else{var s13=a$(e,n,this.options.removeNSPrefix),u12=s13.tagName,c10=s13.rawTagName,p6=s13.tagExp,l6=s13.attrExpPresent,m=s13.closeIndex;this.options.transformTagName&&(u12=this.options.transformTagName(u12)),a&&r&&a.tagname!=="!xml"&&(r=this.saveTextToParentTag(r,a,i,!1));var f=a;if(f&&this.options.unpairedTags.indexOf(f.tagname)!==-1&&(a=this.tagsNodeStack.pop(),i=i.substring(0,i.lastIndexOf("."))),u12!==t.tagname&&(i+=i?"."+u12:u12),this.isItStopNode(this.options.stopNodes,i,u12)){var g="";if(p6.length>0&&p6.lastIndexOf("/")===p6.length-1)u12[u12.length-1]==="/"?(u12=u12.substr(0,u12.length-1),i=i.substr(0,i.length-1),p6=u12):p6=p6.substr(0,p6.length-1),n=s13.closeIndex;else if(this.options.unpairedTags.indexOf(u12)!==-1)n=s13.closeIndex;else{var _=this.readStopNodeData(e,c10,m+1);if(!_)throw new Error("Unexpected end of ".concat(c10));n=_.i,g=_.tagContent}var h=new Oy(u12);u12!==p6&&l6&&(h[":@"]=this.buildAttributesMap(p6,i,u12)),g&&(g=this.parseTextData(g,u12,i,!0,l6,!0,!0)),i=i.substr(0,i.lastIndexOf(".")),h.add(this.options.textNodeName,g),this.addChild(a,h,i)}else{if(p6.length>0&&p6.lastIndexOf("/")===p6.length-1){u12[u12.length-1]==="/"?(u12=u12.substr(0,u12.length-1),i=i.substr(0,i.length-1),p6=u12):p6=p6.substr(0,p6.length-1),this.options.transformTagName&&(u12=this.options.transformTagName(u12));var g1=new Oy(u12);u12!==p6&&l6&&(g1[":@"]=this.buildAttributesMap(p6,i,u12)),this.addChild(a,g1,i),i=i.substr(0,i.lastIndexOf("."))}else{var g10=new Oy(u12);this.tagsNodeStack.push(a),u12!==p6&&l6&&(g10[":@"]=this.buildAttributesMap(p6,i,u12)),this.addChild(a,g10,i),a=g10}r="",n=m}}else r+=e[n];return t.child};var oKt=function oKt(e){if(this.options.processEntities){for(var t in this.docTypeEntities){var a=this.docTypeEntities[t];e=e.replace(a.regx,a.val)}for(var t10 in this.lastEntities){var a6=this.lastEntities[t10];e=e.replace(a6.regex,a6.val)}if(this.options.htmlEntities)for(var t11 in this.htmlEntities){var a10=this.htmlEntities[t11];e=e.replace(a10.regex,a10.val)}e=e.replace(this.ampEntity.regex,this.ampEntity.val)}return e};fIe.exports=t$});var xIe=T(function(_Ie){"use strict";var pKt=function pKt(e,t){return hIe(e,t)};var dKt=function dKt(e){var t=Object.keys(e);for(var a=0;a0&&(i[t.textNodeName]=r):r!==void 0&&(i[t.textNodeName]=r),i}_Ie.prettify=pKt});var vIe=T(function(vur,AIe){var _nIe=nIe(),gKt=_nIe.buildOptions,hKt=gIe(),_xIe=xIe(),_Kt=_xIe.prettify,xKt=ZL(),i$=/*#__PURE__*/function(){function i$(t){_class_call_check(this,i$);this.externalEntities={},this.options=gKt(t)}_create_class(i$,[{key:"parse",value:function parse(t,a){if(typeof t!="string")if(t.toString)t=t.toString();else throw new Error("XML data is accepted in String or Bytes[] form.");if(a){a===!0&&(a={});var n=xKt.validate(t,a);if(n!==!0)throw Error("".concat(n.err.msg,":").concat(n.err.line,":").concat(n.err.col))}var r=new hKt(this.options);r.addExternalEntities(this.externalEntities);var i=r.parseXml(t);return this.options.preserveOrder||i===void 0?i:_Kt(i,this.options)}},{key:"addEntity",value:function addEntity(t,a){if(a.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(t.indexOf("&")!==-1||t.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for ' '");if(a==="&")throw new Error("An entity with value '&' is not permitted");this.externalEntities[t]=a}}]);return i$}();AIe.exports=i$});var kIe=T(function(yur,IIe){var vKt=function vKt(e,t){var a="";return t.format&&t.indentBy.length>0&&(a=AKt),wIe(e,t,"",a)};var yKt=function yKt(e){var t=Object.keys(e);for(var a=0;a0&&t.processEntities)for(var a=0;a"),n=!1;continue}else if(u===t.commentPropName){i+=r+""),n=!0;continue}else if(u[0]==="?"){var g1=yIe(s[":@"],t),h=u==="?xml"?"":r,_=s[u][0][t.textNodeName];_=_.length!==0?" "+_:"",i+=h+"<".concat(u).concat(_).concat(g1,"?>"),n=!0;continue}var p=r;p!==""&&(p+=t.indentBy);var l=yIe(s[":@"],t),m=r+"<".concat(u).concat(l),f=wIe(s[u],t,c,p);t.unpairedTags.indexOf(u)!==-1?t.suppressUnpairedNode?i+=m+">":i+=m+"/>":(!f||f.length===0)&&t.suppressEmptyNode?i+=m+"/>":f&&f.endsWith(">")?i+=m+">".concat(f).concat(r,""):(i+=m+">",f&&r!==""&&(f.includes("/>")||f.includes("")),n=!0}return i}IIe.exports=vKt});var EIe=T(function(wur,CIe){"use strict";var z0=function z0(e){this.options=Object.assign({},kKt,e),this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=IKt(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=SKt),this.processTextOrObjNode=CKt,this.options.format?(this.indentate=EKt,this.tagEndChar=">\n",this.newLine="\n"):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")};var CKt=function CKt(e,t,a,r){var i=this.j2x(e,a+1,r.concat(t));return e[this.options.textNodeName]!==void 0&&Object.keys(e).length===1?this.buildTextValNode(e[this.options.textNodeName],t,i.attrStr,a):this.buildObjectNode(i.val,t,i.attrStr,a)};var EKt=function EKt(e){return this.options.indentBy.repeat(e)};var SKt=function SKt(e){return e.startsWith(this.options.attributeNamePrefix)&&e!==this.options.textNodeName?e.substr(this.attrPrefixLen):!1};var bKt=kIe(),IKt=e$(),kKt={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function tagValueProcessor(e,t){return t},attributeValueProcessor:function attributeValueProcessor(e,t){return t},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1};z0.prototype.build=function(e){return this.options.preserveOrder?bKt(e,this.options):(Array.isArray(e)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(e=_define_property({},this.options.arrayNodeName,e)),this.j2x(e,0,[]).val)};z0.prototype.j2x=function(e,t,a){var r="",i="",n=a.join(".");for(var o in e)if(Object.prototype.hasOwnProperty.call(e,o))if(typeof e[o]=="undefined")this.isAttribute(o)&&(i+="");else if(e[o]===null)this.isAttribute(o)||o===this.options.cdataPropName?i+="":o[0]==="?"?i+=this.indentate(t)+"<"+o+"?"+this.tagEndChar:i+=this.indentate(t)+"<"+o+"/"+this.tagEndChar;else if(_instanceof(e[o],Date))i+=this.buildTextValNode(e[o],o,"",t);else if(_type_of(e[o])!="object"){var s=this.isAttribute(o);if(s&&!this.ignoreAttributesFn(s,n))r+=this.buildAttrPairStr(s,""+e[o]);else if(!s)if(o===this.options.textNodeName){var u=this.options.tagValueProcessor(o,""+e[o]);i+=this.replaceEntitiesValue(u)}else i+=this.buildTextValNode(e[o],o,"",t)}else if(Array.isArray(e[o])){var s6=e[o].length,u6="",c="";for(var p=0;p"+e+i:this.options.commentPropName!==!1&&t===this.options.commentPropName&&n.length===0?this.indentate(r)+"")+this.newLine:this.indentate(r)+"<"+t+a+n+this.tagEndChar+e+this.indentate(r)+i}};z0.prototype.closeTag=function(e){var t="";return this.options.unpairedTags.indexOf(e)!==-1?this.options.suppressUnpairedNode||(t="/"):this.options.suppressEmptyNode?t="/":t=">")+this.newLine;if(this.options.commentPropName!==!1&&t===this.options.commentPropName)return this.indentate(r)+"")+this.newLine;if(t[0]==="?")return this.indentate(r)+"<"+t+a+"?"+this.tagEndChar;{var i=this.options.tagValueProcessor(t,e);return i=this.replaceEntitiesValue(i),i===""?this.indentate(r)+"<"+t+a+this.closeTag(t)+this.tagEndChar:this.indentate(r)+"<"+t+a+">"+i+"0&&this.options.processEntities)for(var t=0;t2&&arguments[2]!==void 0?arguments[2]:{};var r,i,n;for(r in t)n=t[r],a[r]=(i=e[r])!=null?i:n;return a};u$.overwrite=function(e,t){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};var r,i;for(r in e)i=e[r],t[r]!==void 0&&(a[r]=i);return a}});var l$=T(function(Rur,DIe){"use strict";var QIe;QIe=/*#__PURE__*/function(){function QIe(t,a){_class_call_check(this,QIe);this.incr=t,this.decr=a,this._first=null,this._last=null,this.length=0}_create_class(QIe,[{key:"push",value:function push(t){var a;this.length++,typeof this.incr=="function"&&this.incr(),a={value:t,prev:this._last,next:null},this._last!=null?(this._last.next=a,this._last=a):this._first=this._last=a}},{key:"shift",value:function shift(){var t;if(this._first!=null)return this.length--,typeof this.decr=="function"&&this.decr(),t=this._first.value,(this._first=this._first.next)!=null?this._first.prev=null:this._last=null,t}},{key:"first",value:function first(){if(this._first!=null)return this._first.value}},{key:"getArray",value:function getArray(){var t,a,r;for(t=this._first,r=[];t!=null;)r.push((a=t,t=t.next,a.value));return r}},{key:"forEachShift",value:function forEachShift(t){var a;for(a=this.shift();a!=null;)t(a),a=this.shift()}},{key:"debug",value:function debug(){var t,a,r,i,n;for(t=this._first,n=[];t!=null;)n.push((a=t,t=t.next,{value:a.value,prev:(r=a.prev)!=null?r.value:void 0,next:(i=a.next)!=null?i.value:void 0}));return n}}]);return QIe}();DIe.exports=QIe});var Wf=T(function(Dur,qIe){"use strict";var NIe=function NIe(e,t,a,r,i,n,o){try{var s=e[n](o),u=s.value}catch(c){a(c);return}s.done?t(u):Promise.resolve(u).then(r,i)};var OIe=function OIe(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var n=e.apply(t,a);function o(u){NIe(n,r,i,o,s,"next",u)}function s(u){NIe(n,r,i,o,s,"throw",u)}o(void 0)})}};var FIe;FIe=/*#__PURE__*/function(){function FIe(t){var _this=this;var _this1=this;_class_call_check(this,FIe);if(this.instance=t,this._events={},this.instance.on!=null||this.instance.once!=null||this.instance.removeAllListeners!=null)throw new Error("An Emitter already exists for this object");this.instance.on=function(a,r){return _this._addListener(a,"many",r)},this.instance.once=function(a,r){return _this._addListener(a,"once",r)},this.instance.removeAllListeners=function(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:null;return a!=null?delete _this1._events[a]:_this1._events={}}}_create_class(FIe,[{key:"_addListener",value:function _addListener(t,a,r){var i;return(i=this._events)[t]==null&&(i[t]=[]),this._events[t].push({cb:r,status:a}),this.instance}},{key:"listenerCount",value:function listenerCount(t){return this._events[t]!=null?this._events[t].length:0}},{key:"trigger",value:function trigger(t){for(var _len=arguments.length,a=new Array(_len>1?_len-1:0),_key=1;_key<_len;_key++){a[_key-1]=arguments[_key]}var r=this;return OIe(function(){var i,n,_tmp,o;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,4,,5]);t!=="debug"&&r.trigger("debug","Event triggered: ".concat(t),a);if(!(r._events[t]==null))return[3,1];_tmp=void 0;return[3,3];case 1:r._events[t]=r._events[t].filter(function(o){return o.status!=="none"}),n=r._events[t].map(function(){var _$o=OIe(function(s){var u,c,_s1,_tmp,p;return _ts_generator(this,function(_state){switch(_state.label){case 0:if(!(s.status!=="none"))return[3,6];s.status==="once"&&(s.status="none");_state.label=1;case 1:_state.trys.push([1,5,,6]);c=typeof s.cb=="function"?(_s1=s).cb.apply(_s1,_to_consumable_array(a)):void 0;if(!(typeof(c!=null?c.then:void 0)=="function"))return[3,3];return[4,c];case 2:_tmp=_state.sent();return[3,4];case 3:_tmp=c;_state.label=4;case 4:return[2,_tmp];case 5:p=_state.sent();return[2,(u=p,r.trigger("error",u),null)];case 6:return[2]}})});return function(s){return _$o.apply(this,arguments)}}());return[4,Promise.all(n)];case 2:_tmp=_state.sent().find(function(o){return o!=null});_state.label=3;case 3:return[2,_tmp];case 4:o=_state.sent();return[2,(i=o,r.trigger("error",i),null)];case 5:return[2]}})})()}}]);return FIe}();qIe.exports=FIe});var zIe=T(function(Our,GIe){"use strict";var LIe,$Ie,UIe;LIe=l$();$Ie=Wf();UIe=/*#__PURE__*/function(){function UIe(t){_class_call_check(this,UIe);var a;this.Events=new $Ie(this),this._length=0,this._lists=(function(){var _this=this;var r,i,n;for(n=[],a=r=1,i=t;1<=i?r<=i:r>=i;a=1<=i?++r:--r)n.push(new LIe(function(){return _this.incr()},function(){return _this.decr()}));return n}).call(this)}_create_class(UIe,[{key:"incr",value:function incr(){if(this._length++===0)return this.Events.trigger("leftzero")}},{key:"decr",value:function decr(){if(--this._length===0)return this.Events.trigger("zero")}},{key:"push",value:function push(t){return this._lists[t.options.priority].push(t)}},{key:"queued",value:function queued(t){return t!=null?this._lists[t].length:this._length}},{key:"shiftAll",value:function shiftAll(t){return this._lists.forEach(function(a){return a.forEachShift(t)})}},{key:"getFirst",value:function getFirst(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this._lists;var a,r,i;for(a=0,r=t.length;a0)return i;return[]}},{key:"shiftLastFrom",value:function shiftLastFrom(t){return this.getFirst(this._lists.slice(t).reverse()).shift()}}]);return UIe}();GIe.exports=UIe});var Q1=T(function(qur,HIe){"use strict";var jIe;jIe=/*#__PURE__*/function(Error1){_inherits(jIe,Error1);function jIe(){_class_call_check(this,jIe);return _call_super(this,jIe,arguments)}return jIe}(_wrap_native_super(Error));HIe.exports=jIe});var XIe=T(function($ur,YIe){"use strict";var WIe=function WIe(e,t,a,r,i,n,o){try{var s=e[n](o),u=s.value}catch(c){a(c);return}s.done?t(u):Promise.resolve(u).then(r,i)};var VIe=function VIe(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var n=e.apply(t,a);function o(u){WIe(n,r,i,o,s,"next",u)}function s(u){WIe(n,r,i,o,s,"throw",u)}o(void 0)})}};var GC,KIe,JIe,c$,ZIe;c$=10;KIe=5;ZIe=ed();GC=Q1();JIe=/*#__PURE__*/function(){function JIe(t,a,r,i,n,o,s,u){var _this=this;_class_call_check(this,JIe);this.task=t,this.args=a,this.rejectOnDrop=n,this.Events=o,this._states=s,this.Promise=u,this.options=ZIe.load(r,i),this.options.priority=this._sanitizePriority(this.options.priority),this.options.id===i.id&&(this.options.id="".concat(this.options.id,"-").concat(this._randomIndex())),this.promise=new this.Promise(function(c,p){_this._resolve=c,_this._reject=p}),this.retryCount=0}_create_class(JIe,[{key:"_sanitizePriority",value:function _sanitizePriority(t){var a;return a=~~t!==t?KIe:t,a<0?0:a>c$-1?c$-1:a}},{key:"_randomIndex",value:function _randomIndex(){return Math.random().toString(36).slice(2)}},{key:"doDrop",value:function doDrop(){var _ref=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=_ref.error,tmp=_ref.message,a=tmp===void 0?"This job has been dropped by Bottleneck":tmp;return this._states.remove(this.options.id)?(this.rejectOnDrop&&this._reject(t!=null?t:new GC(a)),this.Events.trigger("dropped",{args:this.args,options:this.options,task:this.task,promise:this.promise}),!0):!1}},{key:"_assertStatus",value:function _assertStatus(t){var a;if(a=this._states.jobStatus(this.options.id),!(a===t||t==="DONE"&&a===null))throw new GC("Invalid job status ".concat(a,", expected ").concat(t,". Please open an issue at https://github.com/SGrondin/bottleneck/issues"))}},{key:"doReceive",value:function doReceive(){return this._states.start(this.options.id),this.Events.trigger("received",{args:this.args,options:this.options})}},{key:"doQueue",value:function doQueue(t,a){return this._assertStatus("RECEIVED"),this._states.next(this.options.id),this.Events.trigger("queued",{args:this.args,options:this.options,reachedHWM:t,blocked:a})}},{key:"doRun",value:function doRun(){return this.retryCount===0?(this._assertStatus("QUEUED"),this._states.next(this.options.id)):this._assertStatus("EXECUTING"),this.Events.trigger("scheduled",{args:this.args,options:this.options})}},{key:"doExecute",value:function doExecute(t,a,r,i){var n=this;return VIe(function(){var o,s,u,_t,_n1,c;return _ts_generator(this,function(_state){switch(_state.label){case 0:n.retryCount===0?(n._assertStatus("RUNNING"),n._states.next(n.options.id)):n._assertStatus("EXECUTING"),s={args:n.args,options:n.options,retryCount:n.retryCount},n.Events.trigger("executing",s);_state.label=1;case 1:_state.trys.push([1,5,,6]);return[4,t!=null?(_t=t).schedule.apply(_t,[n.options,n.task].concat(_to_consumable_array(n.args))):(_n1=n).task.apply(_n1,_to_consumable_array(n.args))];case 2:if(!(u=_state.sent(),a()))return[3,4];n.doDone(s);return[4,i(n.options,s)];case 3:return[2,(_state.sent(),n._assertStatus("DONE"),n._resolve(u))];case 4:return[3,6];case 5:c=_state.sent();return[2,(o=c,n._onFailure(o,s,a,r,i))];case 6:return[2]}})})()}},{key:"doExpire",value:function doExpire(t,a,r){var i,n;return this._states.jobStatus(this.options.id==="RUNNING")&&this._states.next(this.options.id),this._assertStatus("EXECUTING"),n={args:this.args,options:this.options,retryCount:this.retryCount},i=new GC("This job timed out after ".concat(this.options.expiration," ms.")),this._onFailure(i,n,t,a,r)}},{key:"_onFailure",value:function _onFailure(t,a,r,i,n){var o=this;return VIe(function(){var s,u,_tmp;return _ts_generator(this,function(_state){switch(_state.label){case 0:if(!r())return[3,5];return[4,o.Events.trigger("failed",t,a)];case 1:s=_state.sent();if(!(s!=null))return[3,2];_tmp=(u=~~s,o.Events.trigger("retry","Retrying ".concat(o.options.id," after ").concat(u," ms"),a),o.retryCount++,i(u));return[3,4];case 2:o.doDone(a);return[4,n(o.options,a)];case 3:_tmp=(_state.sent(),o._assertStatus("DONE"),o._reject(t));_state.label=4;case 4:return[2,_tmp];case 5:return[2]}})})()}},{key:"doDone",value:function doDone(t){return this._assertStatus("EXECUTING"),this._states.next(this.options.id),this.Events.trigger("done",t)}}]);return JIe}();YIe.exports=JIe});var ike=T(function(Gur,rke){"use strict";var eke=function eke(e,t,a,r,i,n,o){try{var s=e[n](o),u=s.value}catch(c){a(c);return}s.done?t(u):Promise.resolve(u).then(r,i)};var eu=function eu(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var n=e.apply(t,a);function o(u){eke(n,r,i,o,s,"next",u)}function s(u){eke(n,r,i,o,s,"throw",u)}o(void 0)})}};var tke,ake,p$;p$=ed();tke=Q1();ake=/*#__PURE__*/function(){function ake(t,a,r){_class_call_check(this,ake);this.instance=t,this.storeOptions=a,this.clientId=this.instance._randomIndex(),p$.load(r,r,this),this._nextRequest=this._lastReservoirRefresh=this._lastReservoirIncrease=Date.now(),this._running=0,this._done=0,this._unblockTime=0,this.ready=this.Promise.resolve(),this.clients={},this._startHeartbeat()}_create_class(ake,[{key:"_startHeartbeat",value:function _startHeartbeat(){var _this=this;var t;return this.heartbeat==null&&(this.storeOptions.reservoirRefreshInterval!=null&&this.storeOptions.reservoirRefreshAmount!=null||this.storeOptions.reservoirIncreaseInterval!=null&&this.storeOptions.reservoirIncreaseAmount!=null)?typeof(t=this.heartbeat=setInterval(function(){var a,r,i,n,o;if(n=Date.now(),_this.storeOptions.reservoirRefreshInterval!=null&&n>=_this._lastReservoirRefresh+_this.storeOptions.reservoirRefreshInterval&&(_this._lastReservoirRefresh=n,_this.storeOptions.reservoir=_this.storeOptions.reservoirRefreshAmount,_this.instance._drainAll(_this.computeCapacity())),_this.storeOptions.reservoirIncreaseInterval!=null&&n>=_this._lastReservoirIncrease+_this.storeOptions.reservoirIncreaseInterval){var s=_this.storeOptions;if(a=s.reservoirIncreaseAmount,i=s.reservoirIncreaseMaximum,o=s.reservoir,_this._lastReservoirIncrease=n,r=i!=null?Math.min(a,i-o):a,r>0)return _this.storeOptions.reservoir+=r,_this.instance._drainAll(_this.computeCapacity())}},this.heartbeatInterval)).unref=="function"?t.unref():void 0:clearInterval(this.heartbeat)}},{key:"__publish__",value:function __publish__(t){var a=this;return eu(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,a.yieldLoop()];case 1:return[2,(_state.sent(),a.instance.Events.trigger("message",t.toString()))]}})})()}},{key:"__disconnect__",value:function __disconnect__(t){var a=this;return eu(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,a.yieldLoop()];case 1:return[2,(_state.sent(),clearInterval(a.heartbeat),a.Promise.resolve())]}})})()}},{key:"yieldLoop",value:function yieldLoop(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;return new this.Promise(function(a,r){return setTimeout(a,t)})}},{key:"computePenalty",value:function computePenalty(){var t;return(t=this.storeOptions.penalty)!=null?t:15*this.storeOptions.minTime||5e3}},{key:"__updateSettings__",value:function __updateSettings__(t){var a=this;return eu(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,a.yieldLoop()];case 1:return[2,(_state.sent(),p$.overwrite(t,t,a.storeOptions),a._startHeartbeat(),a.instance._drainAll(a.computeCapacity()),!0)]}})})()}},{key:"__running__",value:function __running__(){var t=this;return eu(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,t.yieldLoop()];case 1:return[2,(_state.sent(),t._running)]}})})()}},{key:"__queued__",value:function __queued__(){var t=this;return eu(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,t.yieldLoop()];case 1:return[2,(_state.sent(),t.instance.queued())]}})})()}},{key:"__done__",value:function __done__(){var t=this;return eu(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,t.yieldLoop()];case 1:return[2,(_state.sent(),t._done)]}})})()}},{key:"__groupCheck__",value:function __groupCheck__(t){var a=this;return eu(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,a.yieldLoop()];case 1:return[2,(_state.sent(),a._nextRequest+a.timeout=t}},{key:"check",value:function check(t,a){return this.conditionsCheck(t)&&this._nextRequest-a<=0}},{key:"__check__",value:function __check__(t){var a=this;return eu(function(){var r;return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,a.yieldLoop()];case 1:return[2,(_state.sent(),r=Date.now(),a.check(t,r))]}})})()}},{key:"__register__",value:function __register__(t,a,r){var i=this;return eu(function(){var n,o;return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,i.yieldLoop()];case 1:return[2,(_state.sent(),n=Date.now(),i.conditionsCheck(a)?(i._running+=a,i.storeOptions.reservoir!=null&&(i.storeOptions.reservoir-=a),o=Math.max(i._nextRequest-n,0),i._nextRequest=n+o+i.storeOptions.minTime,{success:!0,wait:o,reservoir:i.storeOptions.reservoir}):{success:!1})]}})})()}},{key:"strategyIsBlock",value:function strategyIsBlock(){return this.storeOptions.strategy===3}},{key:"__submit__",value:function __submit__(t,a){var r=this;return eu(function(){var i,n,o;return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,r.yieldLoop()];case 1:if(_state.sent(),r.storeOptions.maxConcurrent!=null&&a>r.storeOptions.maxConcurrent)throw new tke("Impossible to add a job having a weight of ".concat(a," to a limiter having a maxConcurrent setting of ").concat(r.storeOptions.maxConcurrent));return[2,(n=Date.now(),o=r.storeOptions.highWater!=null&&t===r.storeOptions.highWater&&!r.check(a,n),i=r.strategyIsBlock()&&(o||r.isBlocked(n)),i&&(r._unblockTime=n+r.computePenalty(),r._nextRequest=r._unblockTime+r.storeOptions.minTime,r.instance._dropAllQueued()),{reachedHWM:o,blocked:i,strategy:r.storeOptions.strategy})]}})})()}},{key:"__free__",value:function __free__(t,a){var r=this;return eu(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,r.yieldLoop()];case 1:return[2,(_state.sent(),r._running-=a,r._done+=a,r.instance._drainAll(r.computeCapacity()),{running:r._running})]}})})()}}]);return ake}();rke.exports=ake});var nke=T(function(zur,LKt){LKt.exports={"blacklist_client.lua":"local blacklist = ARGV[num_static_argv + 1]\n\nif redis.call('zscore', client_last_seen_key, blacklist) then\n redis.call('zadd', client_last_seen_key, 0, blacklist)\nend\n\n\nreturn {}\n","check.lua":"local weight = tonumber(ARGV[num_static_argv + 1])\n\nlocal capacity = process_tick(now, false)['capacity']\nlocal nextRequest = tonumber(redis.call('hget', settings_key, 'nextRequest'))\n\nreturn conditions_check(capacity, weight) and nextRequest - now <= 0\n","conditions_check.lua":"local conditions_check = function (capacity, weight)\n return capacity == nil or weight <= capacity\nend\n","current_reservoir.lua":"return process_tick(now, false)['reservoir']\n","done.lua":"process_tick(now, false)\n\nreturn tonumber(redis.call('hget', settings_key, 'done'))\n","free.lua":"local index = ARGV[num_static_argv + 1]\n\nredis.call('zadd', job_expirations_key, 0, index)\n\nreturn process_tick(now, false)['running']\n","get_time.lua":"redis.replicate_commands()\n\nlocal get_time = function ()\n local time = redis.call('time')\n\n return tonumber(time[1]..string.sub(time[2], 1, 3))\nend\n","group_check.lua":"return not (redis.call('exists', settings_key) == 1)\n","heartbeat.lua":"process_tick(now, true)\n","increment_reservoir.lua":"local incr = tonumber(ARGV[num_static_argv + 1])\n\nredis.call('hincrby', settings_key, 'reservoir', incr)\n\nlocal reservoir = process_tick(now, true)['reservoir']\n\nlocal groupTimeout = tonumber(redis.call('hget', settings_key, 'groupTimeout'))\nrefresh_expiration(0, 0, groupTimeout)\n\nreturn reservoir\n","init.lua":"local clear = tonumber(ARGV[num_static_argv + 1])\nlocal limiter_version = ARGV[num_static_argv + 2]\nlocal num_local_argv = num_static_argv + 2\n\nif clear == 1 then\n redis.call('del', unpack(KEYS))\nend\n\nif redis.call('exists', settings_key) == 0 then\n -- Create\n local args = {'hmset', settings_key}\n\n for i = num_local_argv + 1, #ARGV do\n table.insert(args, ARGV[i])\n end\n\n redis.call(unpack(args))\n redis.call('hmset', settings_key,\n 'nextRequest', now,\n 'lastReservoirRefresh', now,\n 'lastReservoirIncrease', now,\n 'running', 0,\n 'done', 0,\n 'unblockTime', 0,\n 'capacityPriorityCounter', 0\n )\n\nelse\n -- Apply migrations\n local settings = redis.call('hmget', settings_key,\n 'id',\n 'version'\n )\n local id = settings[1]\n local current_version = settings[2]\n\n if current_version ~= limiter_version then\n local version_digits = {}\n for k, v in string.gmatch(current_version, \"([^.]+)\") do\n table.insert(version_digits, tonumber(k))\n end\n\n -- 2.10.0\n if version_digits[2] < 10 then\n redis.call('hsetnx', settings_key, 'reservoirRefreshInterval', '')\n redis.call('hsetnx', settings_key, 'reservoirRefreshAmount', '')\n redis.call('hsetnx', settings_key, 'lastReservoirRefresh', '')\n redis.call('hsetnx', settings_key, 'done', 0)\n redis.call('hset', settings_key, 'version', '2.10.0')\n end\n\n -- 2.11.1\n if version_digits[2] < 11 or (version_digits[2] == 11 and version_digits[3] < 1) then\n if redis.call('hstrlen', settings_key, 'lastReservoirRefresh') == 0 then\n redis.call('hmset', settings_key,\n 'lastReservoirRefresh', now,\n 'version', '2.11.1'\n )\n end\n end\n\n -- 2.14.0\n if version_digits[2] < 14 then\n local old_running_key = 'b_'..id..'_running'\n local old_executing_key = 'b_'..id..'_executing'\n\n if redis.call('exists', old_running_key) == 1 then\n redis.call('rename', old_running_key, job_weights_key)\n end\n if redis.call('exists', old_executing_key) == 1 then\n redis.call('rename', old_executing_key, job_expirations_key)\n end\n redis.call('hset', settings_key, 'version', '2.14.0')\n end\n\n -- 2.15.2\n if version_digits[2] < 15 or (version_digits[2] == 15 and version_digits[3] < 2) then\n redis.call('hsetnx', settings_key, 'capacityPriorityCounter', 0)\n redis.call('hset', settings_key, 'version', '2.15.2')\n end\n\n -- 2.17.0\n if version_digits[2] < 17 then\n redis.call('hsetnx', settings_key, 'clientTimeout', 10000)\n redis.call('hset', settings_key, 'version', '2.17.0')\n end\n\n -- 2.18.0\n if version_digits[2] < 18 then\n redis.call('hsetnx', settings_key, 'reservoirIncreaseInterval', '')\n redis.call('hsetnx', settings_key, 'reservoirIncreaseAmount', '')\n redis.call('hsetnx', settings_key, 'reservoirIncreaseMaximum', '')\n redis.call('hsetnx', settings_key, 'lastReservoirIncrease', now)\n redis.call('hset', settings_key, 'version', '2.18.0')\n end\n\n end\n\n process_tick(now, false)\nend\n\nlocal groupTimeout = tonumber(redis.call('hget', settings_key, 'groupTimeout'))\nrefresh_expiration(0, 0, groupTimeout)\n\nreturn {}\n","process_tick.lua":"local process_tick = function (now, always_publish)\n\n local compute_capacity = function (maxConcurrent, running, reservoir)\n if maxConcurrent ~= nil and reservoir ~= nil then\n return math.min((maxConcurrent - running), reservoir)\n elseif maxConcurrent ~= nil then\n return maxConcurrent - running\n elseif reservoir ~= nil then\n return reservoir\n else\n return nil\n end\n end\n\n local settings = redis.call('hmget', settings_key,\n 'id',\n 'maxConcurrent',\n 'running',\n 'reservoir',\n 'reservoirRefreshInterval',\n 'reservoirRefreshAmount',\n 'lastReservoirRefresh',\n 'reservoirIncreaseInterval',\n 'reservoirIncreaseAmount',\n 'reservoirIncreaseMaximum',\n 'lastReservoirIncrease',\n 'capacityPriorityCounter',\n 'clientTimeout'\n )\n local id = settings[1]\n local maxConcurrent = tonumber(settings[2])\n local running = tonumber(settings[3])\n local reservoir = tonumber(settings[4])\n local reservoirRefreshInterval = tonumber(settings[5])\n local reservoirRefreshAmount = tonumber(settings[6])\n local lastReservoirRefresh = tonumber(settings[7])\n local reservoirIncreaseInterval = tonumber(settings[8])\n local reservoirIncreaseAmount = tonumber(settings[9])\n local reservoirIncreaseMaximum = tonumber(settings[10])\n local lastReservoirIncrease = tonumber(settings[11])\n local capacityPriorityCounter = tonumber(settings[12])\n local clientTimeout = tonumber(settings[13])\n\n local initial_capacity = compute_capacity(maxConcurrent, running, reservoir)\n\n --\n -- Process 'running' changes\n --\n local expired = redis.call('zrangebyscore', job_expirations_key, '-inf', '('..now)\n\n if #expired > 0 then\n redis.call('zremrangebyscore', job_expirations_key, '-inf', '('..now)\n\n local flush_batch = function (batch, acc)\n local weights = redis.call('hmget', job_weights_key, unpack(batch))\n redis.call('hdel', job_weights_key, unpack(batch))\n local clients = redis.call('hmget', job_clients_key, unpack(batch))\n redis.call('hdel', job_clients_key, unpack(batch))\n\n -- Calculate sum of removed weights\n for i = 1, #weights do\n acc['total'] = acc['total'] + (tonumber(weights[i]) or 0)\n end\n\n -- Calculate sum of removed weights by client\n local client_weights = {}\n for i = 1, #clients do\n local removed = tonumber(weights[i]) or 0\n if removed > 0 then\n acc['client_weights'][clients[i]] = (acc['client_weights'][clients[i]] or 0) + removed\n end\n end\n end\n\n local acc = {\n ['total'] = 0,\n ['client_weights'] = {}\n }\n local batch_size = 1000\n\n -- Compute changes to Zsets and apply changes to Hashes\n for i = 1, #expired, batch_size do\n local batch = {}\n for j = i, math.min(i + batch_size - 1, #expired) do\n table.insert(batch, expired[j])\n end\n\n flush_batch(batch, acc)\n end\n\n -- Apply changes to Zsets\n if acc['total'] > 0 then\n redis.call('hincrby', settings_key, 'done', acc['total'])\n running = tonumber(redis.call('hincrby', settings_key, 'running', -acc['total']))\n end\n\n for client, weight in pairs(acc['client_weights']) do\n redis.call('zincrby', client_running_key, -weight, client)\n end\n end\n\n --\n -- Process 'reservoir' changes\n --\n local reservoirRefreshActive = reservoirRefreshInterval ~= nil and reservoirRefreshAmount ~= nil\n if reservoirRefreshActive and now >= lastReservoirRefresh + reservoirRefreshInterval then\n reservoir = reservoirRefreshAmount\n redis.call('hmset', settings_key,\n 'reservoir', reservoir,\n 'lastReservoirRefresh', now\n )\n end\n\n local reservoirIncreaseActive = reservoirIncreaseInterval ~= nil and reservoirIncreaseAmount ~= nil\n if reservoirIncreaseActive and now >= lastReservoirIncrease + reservoirIncreaseInterval then\n local num_intervals = math.floor((now - lastReservoirIncrease) / reservoirIncreaseInterval)\n local incr = reservoirIncreaseAmount * num_intervals\n if reservoirIncreaseMaximum ~= nil then\n incr = math.min(incr, reservoirIncreaseMaximum - (reservoir or 0))\n end\n if incr > 0 then\n reservoir = (reservoir or 0) + incr\n end\n redis.call('hmset', settings_key,\n 'reservoir', reservoir,\n 'lastReservoirIncrease', lastReservoirIncrease + (num_intervals * reservoirIncreaseInterval)\n )\n end\n\n --\n -- Clear unresponsive clients\n --\n local unresponsive = redis.call('zrangebyscore', client_last_seen_key, '-inf', (now - clientTimeout))\n local unresponsive_lookup = {}\n local terminated_clients = {}\n for i = 1, #unresponsive do\n unresponsive_lookup[unresponsive[i]] = true\n if tonumber(redis.call('zscore', client_running_key, unresponsive[i])) == 0 then\n table.insert(terminated_clients, unresponsive[i])\n end\n end\n if #terminated_clients > 0 then\n redis.call('zrem', client_running_key, unpack(terminated_clients))\n redis.call('hdel', client_num_queued_key, unpack(terminated_clients))\n redis.call('zrem', client_last_registered_key, unpack(terminated_clients))\n redis.call('zrem', client_last_seen_key, unpack(terminated_clients))\n end\n\n --\n -- Broadcast capacity changes\n --\n local final_capacity = compute_capacity(maxConcurrent, running, reservoir)\n\n if always_publish or (initial_capacity ~= nil and final_capacity == nil) then\n -- always_publish or was not unlimited, now unlimited\n redis.call('publish', 'b_'..id, 'capacity:'..(final_capacity or ''))\n\n elseif initial_capacity ~= nil and final_capacity ~= nil and final_capacity > initial_capacity then\n -- capacity was increased\n -- send the capacity message to the limiter having the lowest number of running jobs\n -- the tiebreaker is the limiter having not registered a job in the longest time\n\n local lowest_concurrency_value = nil\n local lowest_concurrency_clients = {}\n local lowest_concurrency_last_registered = {}\n local client_concurrencies = redis.call('zrange', client_running_key, 0, -1, 'withscores')\n\n for i = 1, #client_concurrencies, 2 do\n local client = client_concurrencies[i]\n local concurrency = tonumber(client_concurrencies[i+1])\n\n if (\n lowest_concurrency_value == nil or lowest_concurrency_value == concurrency\n ) and (\n not unresponsive_lookup[client]\n ) and (\n tonumber(redis.call('hget', client_num_queued_key, client)) > 0\n ) then\n lowest_concurrency_value = concurrency\n table.insert(lowest_concurrency_clients, client)\n local last_registered = tonumber(redis.call('zscore', client_last_registered_key, client))\n table.insert(lowest_concurrency_last_registered, last_registered)\n end\n end\n\n if #lowest_concurrency_clients > 0 then\n local position = 1\n local earliest = lowest_concurrency_last_registered[1]\n\n for i,v in ipairs(lowest_concurrency_last_registered) do\n if v < earliest then\n position = i\n earliest = v\n end\n end\n\n local next_client = lowest_concurrency_clients[position]\n redis.call('publish', 'b_'..id,\n 'capacity-priority:'..(final_capacity or '')..\n ':'..next_client..\n ':'..capacityPriorityCounter\n )\n redis.call('hincrby', settings_key, 'capacityPriorityCounter', '1')\n else\n redis.call('publish', 'b_'..id, 'capacity:'..(final_capacity or ''))\n end\n end\n\n return {\n ['capacity'] = final_capacity,\n ['running'] = running,\n ['reservoir'] = reservoir\n }\nend\n","queued.lua":"local clientTimeout = tonumber(redis.call('hget', settings_key, 'clientTimeout'))\nlocal valid_clients = redis.call('zrangebyscore', client_last_seen_key, (now - clientTimeout), 'inf')\nlocal client_queued = redis.call('hmget', client_num_queued_key, unpack(valid_clients))\n\nlocal sum = 0\nfor i = 1, #client_queued do\n sum = sum + tonumber(client_queued[i])\nend\n\nreturn sum\n","refresh_expiration.lua":"local refresh_expiration = function (now, nextRequest, groupTimeout)\n\n if groupTimeout ~= nil then\n local ttl = (nextRequest + groupTimeout) - now\n\n for i = 1, #KEYS do\n redis.call('pexpire', KEYS[i], ttl)\n end\n end\n\nend\n","refs.lua":"local settings_key = KEYS[1]\nlocal job_weights_key = KEYS[2]\nlocal job_expirations_key = KEYS[3]\nlocal job_clients_key = KEYS[4]\nlocal client_running_key = KEYS[5]\nlocal client_num_queued_key = KEYS[6]\nlocal client_last_registered_key = KEYS[7]\nlocal client_last_seen_key = KEYS[8]\n\nlocal now = tonumber(ARGV[1])\nlocal client = ARGV[2]\n\nlocal num_static_argv = 2\n","register.lua":"local index = ARGV[num_static_argv + 1]\nlocal weight = tonumber(ARGV[num_static_argv + 2])\nlocal expiration = tonumber(ARGV[num_static_argv + 3])\n\nlocal state = process_tick(now, false)\nlocal capacity = state['capacity']\nlocal reservoir = state['reservoir']\n\nlocal settings = redis.call('hmget', settings_key,\n 'nextRequest',\n 'minTime',\n 'groupTimeout'\n)\nlocal nextRequest = tonumber(settings[1])\nlocal minTime = tonumber(settings[2])\nlocal groupTimeout = tonumber(settings[3])\n\nif conditions_check(capacity, weight) then\n\n redis.call('hincrby', settings_key, 'running', weight)\n redis.call('hset', job_weights_key, index, weight)\n if expiration ~= nil then\n redis.call('zadd', job_expirations_key, now + expiration, index)\n end\n redis.call('hset', job_clients_key, index, client)\n redis.call('zincrby', client_running_key, weight, client)\n redis.call('hincrby', client_num_queued_key, client, -1)\n redis.call('zadd', client_last_registered_key, now, client)\n\n local wait = math.max(nextRequest - now, 0)\n local newNextRequest = now + wait + minTime\n\n if reservoir == nil then\n redis.call('hset', settings_key,\n 'nextRequest', newNextRequest\n )\n else\n reservoir = reservoir - weight\n redis.call('hmset', settings_key,\n 'reservoir', reservoir,\n 'nextRequest', newNextRequest\n )\n end\n\n refresh_expiration(now, newNextRequest, groupTimeout)\n\n return {true, wait, reservoir}\n\nelse\n return {false}\nend\n","register_client.lua":"local queued = tonumber(ARGV[num_static_argv + 1])\n\n-- Could have been re-registered concurrently\nif not redis.call('zscore', client_last_seen_key, client) then\n redis.call('zadd', client_running_key, 0, client)\n redis.call('hset', client_num_queued_key, client, queued)\n redis.call('zadd', client_last_registered_key, 0, client)\nend\n\nredis.call('zadd', client_last_seen_key, now, client)\n\nreturn {}\n","running.lua":"return process_tick(now, false)['running']\n","submit.lua":"local queueLength = tonumber(ARGV[num_static_argv + 1])\nlocal weight = tonumber(ARGV[num_static_argv + 2])\n\nlocal capacity = process_tick(now, false)['capacity']\n\nlocal settings = redis.call('hmget', settings_key,\n 'id',\n 'maxConcurrent',\n 'highWater',\n 'nextRequest',\n 'strategy',\n 'unblockTime',\n 'penalty',\n 'minTime',\n 'groupTimeout'\n)\nlocal id = settings[1]\nlocal maxConcurrent = tonumber(settings[2])\nlocal highWater = tonumber(settings[3])\nlocal nextRequest = tonumber(settings[4])\nlocal strategy = tonumber(settings[5])\nlocal unblockTime = tonumber(settings[6])\nlocal penalty = tonumber(settings[7])\nlocal minTime = tonumber(settings[8])\nlocal groupTimeout = tonumber(settings[9])\n\nif maxConcurrent ~= nil and weight > maxConcurrent then\n return redis.error_reply('OVERWEIGHT:'..weight..':'..maxConcurrent)\nend\n\nlocal reachedHWM = (highWater ~= nil and queueLength == highWater\n and not (\n conditions_check(capacity, weight)\n and nextRequest - now <= 0\n )\n)\n\nlocal blocked = strategy == 3 and (reachedHWM or unblockTime >= now)\n\nif blocked then\n local computedPenalty = penalty\n if computedPenalty == nil then\n if minTime == 0 then\n computedPenalty = 5000\n else\n computedPenalty = 15 * minTime\n end\n end\n\n local newNextRequest = now + computedPenalty + minTime\n\n redis.call('hmset', settings_key,\n 'unblockTime', now + computedPenalty,\n 'nextRequest', newNextRequest\n )\n\n local clients_queued_reset = redis.call('hkeys', client_num_queued_key)\n local queued_reset = {}\n for i = 1, #clients_queued_reset do\n table.insert(queued_reset, clients_queued_reset[i])\n table.insert(queued_reset, 0)\n end\n redis.call('hmset', client_num_queued_key, unpack(queued_reset))\n\n redis.call('publish', 'b_'..id, 'blocked:')\n\n refresh_expiration(now, newNextRequest, groupTimeout)\nend\n\nif not blocked and not reachedHWM then\n redis.call('hincrby', client_num_queued_key, client, 1)\nend\n\nreturn {reachedHWM, blocked, strategy}\n","update_settings.lua":"local args = {'hmset', settings_key}\n\nfor i = num_static_argv + 1, #ARGV do\n table.insert(args, ARGV[i])\nend\n\nredis.call(unpack(args))\n\nprocess_tick(now, true)\n\nlocal groupTimeout = tonumber(redis.call('hget', settings_key, 'groupTimeout'))\nrefresh_expiration(0, 0, groupTimeout)\n\nreturn {}\n","validate_client.lua":"if not redis.call('zscore', client_last_seen_key, client) then\n return redis.error_reply('UNKNOWN_CLIENT')\nend\n\nredis.call('zadd', client_last_seen_key, now, client)\n","validate_keys.lua":"if not (redis.call('exists', settings_key) == 1) then\n return redis.error_reply('SETTINGS_KEY_NOT_FOUND')\nend\n"}});var HC=T(function(Wi){"use strict";var zC,mi,jC;mi=nke();zC={refs:mi["refs.lua"],validate_keys:mi["validate_keys.lua"],validate_client:mi["validate_client.lua"],refresh_expiration:mi["refresh_expiration.lua"],process_tick:mi["process_tick.lua"],conditions_check:mi["conditions_check.lua"],get_time:mi["get_time.lua"]};Wi.allKeys=function(e){return["b_".concat(e,"_settings"),"b_".concat(e,"_job_weights"),"b_".concat(e,"_job_expirations"),"b_".concat(e,"_job_clients"),"b_".concat(e,"_client_running"),"b_".concat(e,"_client_num_queued"),"b_".concat(e,"_client_last_registered"),"b_".concat(e,"_client_last_seen")]};jC={init:{keys:Wi.allKeys,headers:["process_tick"],refresh_expiration:!0,code:mi["init.lua"]},group_check:{keys:Wi.allKeys,headers:[],refresh_expiration:!1,code:mi["group_check.lua"]},register_client:{keys:Wi.allKeys,headers:["validate_keys"],refresh_expiration:!1,code:mi["register_client.lua"]},blacklist_client:{keys:Wi.allKeys,headers:["validate_keys","validate_client"],refresh_expiration:!1,code:mi["blacklist_client.lua"]},heartbeat:{keys:Wi.allKeys,headers:["validate_keys","validate_client","process_tick"],refresh_expiration:!1,code:mi["heartbeat.lua"]},update_settings:{keys:Wi.allKeys,headers:["validate_keys","validate_client","process_tick"],refresh_expiration:!0,code:mi["update_settings.lua"]},running:{keys:Wi.allKeys,headers:["validate_keys","validate_client","process_tick"],refresh_expiration:!1,code:mi["running.lua"]},queued:{keys:Wi.allKeys,headers:["validate_keys","validate_client"],refresh_expiration:!1,code:mi["queued.lua"]},done:{keys:Wi.allKeys,headers:["validate_keys","validate_client","process_tick"],refresh_expiration:!1,code:mi["done.lua"]},check:{keys:Wi.allKeys,headers:["validate_keys","validate_client","process_tick","conditions_check"],refresh_expiration:!1,code:mi["check.lua"]},submit:{keys:Wi.allKeys,headers:["validate_keys","validate_client","process_tick","conditions_check"],refresh_expiration:!0,code:mi["submit.lua"]},register:{keys:Wi.allKeys,headers:["validate_keys","validate_client","process_tick","conditions_check"],refresh_expiration:!0,code:mi["register.lua"]},free:{keys:Wi.allKeys,headers:["validate_keys","validate_client","process_tick"],refresh_expiration:!0,code:mi["free.lua"]},current_reservoir:{keys:Wi.allKeys,headers:["validate_keys","validate_client","process_tick"],refresh_expiration:!1,code:mi["current_reservoir.lua"]},increment_reservoir:{keys:Wi.allKeys,headers:["validate_keys","validate_client","process_tick"],refresh_expiration:!0,code:mi["increment_reservoir.lua"]}};Wi.names=Object.keys(jC);Wi.keys=function(e,t){return jC[e].keys(t)};Wi.payload=function(e){var t;return t=jC[e],Array.prototype.concat(zC.refs,t.headers.map(function(a){return zC[a]}),t.refresh_expiration?zC.refresh_expiration:"",t.code).join("\n")}});var WC=T(function(exports,module){"use strict";var asyncGeneratorStep=function asyncGeneratorStep(e,t,a,r,i,n,o){try{var s=e[n](o),u=s.value}catch(c){a(c);return}s.done?t(u):Promise.resolve(u).then(r,i)};var _asyncToGenerator=function _asyncToGenerator(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var n=e.apply(t,a);function o(u){asyncGeneratorStep(n,r,i,o,s,"next",u)}function s(u){asyncGeneratorStep(n,r,i,o,s,"throw",u)}o(void 0)})}};var Events,RedisConnection,Scripts,parser;parser=ed();Events=Wf();Scripts=HC();RedisConnection=(function(){var RedisConnection=/*#__PURE__*/function(){function RedisConnection(){var _this=this;var options=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};_class_call_check(this,RedisConnection);parser.load(options,this.defaults,this),this.Redis==null&&(this.Redis=eval("require")("redis")),this.Events==null&&(this.Events=new Events(this)),this.terminated=!1,this.client==null&&(this.client=this.Redis.createClient(this.clientOptions)),this.subscriber=this.client.duplicate(),this.limiters={},this.shas={},this.ready=this.Promise.all([this._setup(this.client,!1),this._setup(this.subscriber,!0)]).then(function(){return _this._loadScripts()}).then(function(){return{client:_this.client,subscriber:_this.subscriber}})}_create_class(RedisConnection,[{key:"_setup",value:function _setup(e,t){var _this=this;return e.setMaxListeners(0),new this.Promise(function(a,r){return e.on("error",function(i){return _this.Events.trigger("error",i)}),t&&e.on("message",function(i,n){var o;return(o=_this.limiters[i])!=null?o._store.onMessage(i,n):void 0}),e.ready?a():e.once("ready",a)})}},{key:"_loadScript",value:function _loadScript(e){var _this=this;return new this.Promise(function(t,a){var r;return r=Scripts.payload(e),_this.client.multi([["script","load",r]]).exec(function(i,n){return i!=null?a(i):(_this.shas[e]=n[0],t(n[0]))})})}},{key:"_loadScripts",value:function _loadScripts(){var _this=this;return this.Promise.all(Scripts.names.map(function(e){return _this._loadScript(e)}))}},{key:"__runCommand__",value:function __runCommand__(e){var t=this;return _asyncToGenerator(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,t.ready];case 1:return[2,(_state.sent(),new t.Promise(function(a,r){return t.client.multi([e]).exec_atomic(function(i,n){return i!=null?r(i):a(n[0])})}))]}})})()}},{key:"__addLimiter__",value:function __addLimiter__(e){var _this=this;return this.Promise.all([e.channel(),e.channel_client()].map(function(t){return new _this.Promise(function(a,r){var i;return i=function(n){if(n===t)return _this.subscriber.removeListener("subscribe",i),_this.limiters[t]=e,a()},_this.subscriber.on("subscribe",i),_this.subscriber.subscribe(t)})}))}},{key:"__removeLimiter__",value:function __removeLimiter__(e){var t=this;return this.Promise.all([e.channel(),e.channel_client()].map(function(){var a=_asyncToGenerator(function(r){var _tmp;return _ts_generator(this,function(_state){switch(_state.label){case 0:_tmp=t.terminated;if(_tmp)return[3,2];return[4,new t.Promise(function(i,n){return t.subscriber.unsubscribe(r,function(o,s){if(o!=null)return n(o);if(s===r)return i()})})];case 1:_tmp=_state.sent();_state.label=2;case 2:return[2,(_tmp,delete t.limiters[r])]}})});return function(r){return a.apply(this,arguments)}}()))}},{key:"__scriptArgs__",value:function __scriptArgs__(e,t,a,r){var i;return i=Scripts.keys(e,t),[this.shas[e],i.length].concat(i,a,r)}},{key:"__scriptFn__",value:function __scriptFn__(e){return this.client.evalsha.bind(this.client)}},{key:"disconnect",value:function disconnect(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;var t,a,r,i;for(i=Object.keys(this.limiters),t=0,r=i.length;t0&&arguments[0]!==void 0?arguments[0]:{};_class_call_check(this,IORedisConnection);parser.load(options,this.defaults,this),this.Redis==null&&(this.Redis=eval("require")("ioredis")),this.Events==null&&(this.Events=new Events(this)),this.terminated=!1,this.clusterNodes!=null?(this.client=new this.Redis.Cluster(this.clusterNodes,this.clientOptions),this.subscriber=new this.Redis.Cluster(this.clusterNodes,this.clientOptions)):this.client!=null&&this.client.duplicate==null?this.subscriber=new this.Redis.Cluster(this.client.startupNodes,this.client.options):(this.client==null&&(this.client=new this.Redis(this.clientOptions)),this.subscriber=this.client.duplicate()),this.limiters={},this.ready=this.Promise.all([this._setup(this.client,!1),this._setup(this.subscriber,!0)]).then(function(){return _this._loadScripts(),{client:_this.client,subscriber:_this.subscriber}})}_create_class(IORedisConnection,[{key:"_setup",value:function _setup(e,t){var _this=this;return e.setMaxListeners(0),new this.Promise(function(a,r){return e.on("error",function(i){return _this.Events.trigger("error",i)}),t&&e.on("message",function(i,n){var o;return(o=_this.limiters[i])!=null?o._store.onMessage(i,n):void 0}),e.status==="ready"?a():e.once("ready",a)})}},{key:"_loadScripts",value:function _loadScripts(){var _this=this;return Scripts.names.forEach(function(e){return _this.client.defineCommand(e,{lua:Scripts.payload(e)})})}},{key:"__runCommand__",value:function __runCommand__(e){var t=this;return _asyncToGenerator(function(){var a,r,i,n,o;return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,t.ready];case 1:_state.sent();return[4,t.client.pipeline([e]).exec()];case 2:i=_state.sent(),n=_slicedToArray(i,1),o=_slicedToArray(n[0],2);return[2,(a=o[0],r=o[1],r)]}})})()}},{key:"__addLimiter__",value:function __addLimiter__(e){var _this=this;return this.Promise.all([e.channel(),e.channel_client()].map(function(t){return new _this.Promise(function(a,r){return _this.subscriber.subscribe(t,function(){return _this.limiters[t]=e,a()})})}))}},{key:"__removeLimiter__",value:function __removeLimiter__(e){var t=this;return[e.channel(),e.channel_client()].forEach(function(){var a=_asyncToGenerator(function(r){var _tmp;return _ts_generator(this,function(_state){switch(_state.label){case 0:_tmp=t.terminated;if(_tmp)return[3,2];return[4,t.subscriber.unsubscribe(r)];case 1:_tmp=_state.sent();_state.label=2;case 2:return[2,(_tmp,delete t.limiters[r])]}})});return function(r){return a.apply(this,arguments)}}())}},{key:"__scriptArgs__",value:function __scriptArgs__(e,t,a,r){var i;return i=Scripts.keys(e,t),[i.length].concat(i,a,r)}},{key:"__scriptFn__",value:function __scriptFn__(e){return this.client[e].bind(this.client)}},{key:"disconnect",value:function disconnect(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;var t,a,r,i;for(i=Object.keys(this.limiters),t=0,r=i.length;t0?~~o:void 0)];case 1:return[2,_state.sent()];case 2:if(!(f==="capacity-priority"))return[3,7];h=o.split(":"),_=KC(h,3);m=_[0],l=_[1],n=_[2],i=m.length>0?~~m:void 0;if(!(l===r.clientId))return[3,5];return[4,r.instance._drainAll(i)];case 3:s=_state.sent(),c=i!=null?i-(s||0):"";return[4,r.clients.client.publish(r.instance.channel(),"capacity-priority:".concat(c,"::").concat(n))];case 4:_tmp=_state.sent();return[3,6];case 5:_tmp=l===""?(clearTimeout(r.capacityPriorityCounters[n]),delete r.capacityPriorityCounters[n],r.instance._drainAll(i)):r.capacityPriorityCounters[n]=setTimeout(Vc(function(){var _$A,x;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,3,,4]);delete r.capacityPriorityCounters[n];return[4,r.runScript("blacklist_client",[l])];case 1:_state.sent();return[4,r.instance._drainAll(i)];case 2:return[2,_state.sent()];case 3:x=_state.sent();return[2,(_$A=x,r.instance.Events.trigger("error",_$A))];case 4:return[2]}})}),1e3);_state.label=6;case 6:return[2,_tmp];case 7:if(f==="message")return[2,r.instance.Events.trigger("message",o)];if(!(f==="blocked"))return[3,9];return[4,r.instance._dropAllQueued()];case 8:return[2,_state.sent()];case 9:return[3,11];case 10:A=_state.sent();return[2,(u=A,r.instance.Events.trigger("error",u))];case 11:return[2]}})})()}},{key:"__disconnect__",value:function __disconnect__(t){return clearInterval(this.heartbeat),this.sharedConnection?this.connection.__removeLimiter__(this.instance):this.connection.disconnect(t)}},{key:"runScript",value:function runScript(t,a){var r=this;return Vc(function(){var _this,_tmp;return _ts_generator(this,function(_state){switch(_state.label){case 0:_this=this;_tmp=t==="init"||t==="register_client";if(_tmp)return[3,2];return[4,r.ready];case 1:_tmp=_state.sent();_state.label=2;case 2:return[2,(_tmp,new r.Promise(function(i,n){var o,s;return o=[Date.now(),r.clientId].concat(a),r.instance.Events.trigger("debug","Calling Redis script: ".concat(t,".lua"),o),s=r.connection.__scriptArgs__(t,r.originalId,o,function(u,c){return u!=null?n(u):i(c)}),r.connection.__scriptFn__(t).apply(_this,_to_consumable_array(s))}).catch(function(i){return i.message==="SETTINGS_KEY_NOT_FOUND"?t==="heartbeat"?r.Promise.resolve():r.runScript("init",r.prepareInitSettings(!1)).then(function(){return r.runScript(t,a)}):i.message==="UNKNOWN_CLIENT"?r.runScript("register_client",[r.instance.queued()]).then(function(){return r.runScript(t,a)}):r.Promise.reject(i)}))]}})})()}},{key:"prepareArray",value:function prepareArray(t){var a,r,i,n;for(i=[],a=0,r=t.length;a0))return[3,2];t._running++;c=t._queue.shift();u=c.task,a=c.args,o=c.resolve,n=c.reject;return[4,xke(function(){var p;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,2,,3]);return[4,u.apply(void 0,_to_consumable_array(a))];case 1:return[2,(s=_state.sent(),function(){return o(s)})];case 2:p=_state.sent();return[2,(i=p,function(){return n(i)})];case 3:return[2]}})})()];case 1:return[2,(r=_state.sent(),t._running--,t._tryToRun(),r())];case 2:return[2]}})})()}},{key:"schedule",value:function schedule(t){for(var _len=arguments.length,a=new Array(_len>1?_len-1:0),_key=1;_key<_len;_key++){a[_key-1]=arguments[_key]}var r,i,n;return n=i=null,r=new this.Promise(function(o,s){return n=o,i=s}),this._queue.push({task:t,args:a,resolve:n,reject:i}),this._tryToRun(),r}}]);return vke}();yke.exports=vke});var bke=T(function(Yur,zKt){zKt.exports={version:"2.19.5"}});var Mke=T(function(Xur,Tke){"use strict";var jKt=function jKt(e,t){return VKt(e)||WKt(e,t)||HKt()};var HKt=function HKt(){throw new TypeError("Invalid attempt to destructure non-iterable instance")};var WKt=function WKt(e,t){var a=[],r=!0,i=!1,n=void 0;try{for(var o=e[Symbol.iterator](),s;!(r=(s=o.next()).done)&&(a.push(s.value),!(t&&a.length===t));r=!0);}catch(u){i=!0,n=u}finally{try{!r&&o.return!=null&&o.return()}finally{if(i)throw n}}return a};var VKt=function VKt(e){if(Array.isArray(e))return e};var Ike=function Ike(e,t,a,r,i,n,o){try{var s=e[n](o),u=s.value}catch(c){a(c);return}s.done?t(u):Promise.resolve(u).then(r,i)};var m$=function m$(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var n=e.apply(t,a);function o(u){Ike(n,r,i,o,s,"next",u)}function s(u){Ike(n,r,i,o,s,"throw",u)}o(void 0)})}};var kke,Cke,Eke,Ske,Bke,JC;JC=ed();kke=Wf();Ske=WC();Eke=VC();Bke=HC();Cke=(function(){var e=/*#__PURE__*/function(){function e(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};_class_call_check(this,e);this.deleteKey=this.deleteKey.bind(this),this.limiterOptions=a,JC.load(this.limiterOptions,this.defaults,this),this.Events=new kke(this),this.instances={},this.Bottleneck=f$(),this._startAutoCleanup(),this.sharedConnection=this.connection!=null,this.connection==null&&(this.limiterOptions.datastore==="redis"?this.connection=new Ske(Object.assign({},this.limiterOptions,{Events:this.Events})):this.limiterOptions.datastore==="ioredis"&&(this.connection=new Eke(Object.assign({},this.limiterOptions,{Events:this.Events}))))}_create_class(e,[{key:"key",value:function key(){var _this=this;var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";var r;return(r=this.instances[a])!=null?r:function(){var i;return i=_this.instances[a]=new _this.Bottleneck(Object.assign(_this.limiterOptions,{id:"".concat(_this.id,"-").concat(a),timeout:_this.timeout,connection:_this.connection})),_this.Events.trigger("created",i,a),i}()}},{key:"deleteKey",value:function deleteKey(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";var r=this;return m$(function(){var i,n,_tmp,_tmp1;return _ts_generator(this,function(_state){switch(_state.label){case 0:n=r.instances[a];_tmp=r.connection;if(!_tmp)return[3,2];return[4,r.connection.__runCommand__(["del"].concat(_to_consumable_array(Bke.allKeys("".concat(r.id,"-").concat(a)))))];case 1:_tmp=i=_state.sent();_state.label=2;case 2:_tmp;_tmp1=n!=null;if(!_tmp1)return[3,4];delete r.instances[a];return[4,n.disconnect()];case 3:_tmp1=_state.sent();_state.label=4;case 4:return[2,(_tmp1,n!=null||i>0)]}})})()}},{key:"limiters",value:function limiters(){var a,r,i,n;r=this.instances,i=[];for(a in r)n=r[a],i.push({key:a,limiter:n});return i}},{key:"keys",value:function keys(){return Object.keys(this.instances)}},{key:"clusterKeys",value:function clusterKeys(){var a=this;return m$(function(){var r,i,n,o,s,u,c,p,l,m,f;return _ts_generator(this,function(_state){switch(_state.label){case 0:if(a.connection==null)return[2,a.Promise.resolve(a.keys())];u=[],r=null,l="b_".concat(a.id,"-").length,i=9;_state.label=1;case 1:if(!(r!==0))return[3,4];return[4,a.connection.__runCommand__(["scan",r!=null?r:0,"match","b_".concat(a.id,"-*_settings"),"count",1e4])];case 2:m=_state.sent(),f=jKt(m,2);for(p=f[0],n=f[1],r=~~p,o=0,c=n.length;o0&&arguments[0]!==void 0?arguments[0]:{};if(JC.overwrite(a,this.defaults,this),JC.overwrite(a,a,this.limiterOptions),a.timeout!=null)return this._startAutoCleanup()}},{key:"disconnect",value:function disconnect(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;var r;if(!this.sharedConnection)return(r=this.connection)!=null?r.disconnect(a):void 0}}]);return e}();return e.prototype.defaults={timeout:1e3*60*5,connection:null,Promise:Promise,id:"group-key"},e}).call(void 0);Tke.exports=Cke});var Nke=T(function(elr,Dke){"use strict";var Pke,Rke,Qke;Qke=ed();Rke=Wf();Pke=(function(){var e=/*#__PURE__*/function(){function e(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};_class_call_check(this,e);this.options=a,Qke.load(this.options,this.defaults,this),this.Events=new Rke(this),this._arr=[],this._resetPromise(),this._lastFlush=Date.now()}_create_class(e,[{key:"_resetPromise",value:function _resetPromise(){var _this=this;return this._promise=new this.Promise(function(a,r){return _this._resolve=a})}},{key:"_flush",value:function _flush(){return clearTimeout(this._timeout),this._lastFlush=Date.now(),this._resolve(),this.Events.trigger("batch",this._arr),this._arr=[],this._resetPromise()}},{key:"add",value:function add(a){var _this=this;var r;return this._arr.push(a),r=this._promise,this._arr.length===this.maxSize?this._flush():this.maxTime!=null&&this._arr.length===1&&(this._timeout=setTimeout(function(){return _this._flush()},this.maxTime)),r}}]);return e}();return e.prototype.defaults={maxTime:null,maxSize:null,Promise:Promise},e}).call(void 0);Dke.exports=Pke});var f$=T(function(tlr,Vke){"use strict";var Oke=function Oke(e,t){return $ke(e)||KKt(e,t)||Lke()};var KKt=function KKt(e,t){var a=[],r=!0,i=!1,n=void 0;try{for(var o=e[Symbol.iterator](),s;!(r=(s=o.next()).done)&&(a.push(s.value),!(t&&a.length===t));r=!0);}catch(u){i=!0,n=u}finally{try{!r&&o.return!=null&&o.return()}finally{if(i)throw n}}return a};var ZC=function ZC(e){return $ke(e)||JKt(e)||Lke()};var Lke=function Lke(){throw new TypeError("Invalid attempt to destructure non-iterable instance")};var JKt=function JKt(e){if(Symbol.iterator in Object(e)||Object.prototype.toString.call(e)==="[object Arguments]")return Array.from(e)};var $ke=function $ke(e){if(Array.isArray(e))return e};var Fke=function Fke(e,t,a,r,i,n,o){try{var s=e[n](o),u=s.value}catch(c){a(c);return}s.done?t(u):Promise.resolve(u).then(r,i)};var g$=function g$(e){return function(){var t=this,a=arguments;return new Promise(function(r,i){var n=e.apply(t,a);function o(u){Fke(n,r,i,o,s,"next",u)}function s(u){Fke(n,r,i,o,s,"throw",u)}o(void 0)})}};var Uke,Gke,h$,_$,zke,x$,jke,Hke,Wke,A$,Kc,qke=[].splice;x$=10;Gke=5;Kc=ed();jke=zIe();_$=XIe();zke=ike();Hke=dke();h$=Wf();Wke=hke();A$=wke();Uke=(function(){var e=/*#__PURE__*/function(){function e(){var _this=this;var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};for(var _len=arguments.length,r=new Array(_len>1?_len-1:0),_key=1;_key<_len;_key++){r[_key-1]=arguments[_key]}_class_call_check(this,e);var i,n;this._addToQueue=this._addToQueue.bind(this),this._validateOptions(a,r),Kc.load(a,this.instanceDefaults,this),this._queues=new jke(x$),this._scheduled={},this._states=new Wke(["RECEIVED","QUEUED","RUNNING","EXECUTING"].concat(this.trackDoneStatus?["DONE"]:[])),this._limiter=null,this.Events=new h$(this),this._submitLock=new A$("submit",this.Promise),this._registerLock=new A$("register",this.Promise),n=Kc.load(a,this.storeDefaults,{}),this._store=(function(){if(this.datastore==="redis"||this.datastore==="ioredis"||this.connection!=null)return i=Kc.load(a,this.redisStoreDefaults,{}),new Hke(this,n,i);if(this.datastore==="local")return i=Kc.load(a,this.localStoreDefaults,{}),new zke(this,n,i);throw new e.prototype.BottleneckError("Invalid datastore type: ".concat(this.datastore))}).call(this),this._queues.on("leftzero",function(){var o;return(o=_this._store.heartbeat)!=null&&typeof o.ref=="function"?o.ref():void 0}),this._queues.on("zero",function(){var o;return(o=_this._store.heartbeat)!=null&&typeof o.unref=="function"?o.unref():void 0})}_create_class(e,[{key:"_validateOptions",value:function _validateOptions(a,r){if(!(a!=null&&(typeof a==="undefined"?"undefined":_type_of(a))=="object"&&r.length===0))throw new e.prototype.BottleneckError("Bottleneck v2 takes a single object argument. Refer to https://github.com/SGrondin/bottleneck#upgrading-to-v2 if you're upgrading from Bottleneck v1.")}},{key:"ready",value:function ready(){return this._store.ready}},{key:"clients",value:function clients(){return this._store.clients}},{key:"channel",value:function channel(){return"b_".concat(this.id)}},{key:"channel_client",value:function channel_client(){return"b_".concat(this.id,"_").concat(this._store.clientId)}},{key:"publish",value:function publish(a){return this._store.__publish__(a)}},{key:"disconnect",value:function disconnect(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return this._store.__disconnect__(a)}},{key:"chain",value:function chain(a){return this._limiter=a,this}},{key:"queued",value:function queued(a){return this._queues.queued(a)}},{key:"clusterQueued",value:function clusterQueued(){return this._store.__queued__()}},{key:"empty",value:function empty(){return this.queued()===0&&this._submitLock.isEmpty()}},{key:"running",value:function running(){return this._store.__running__()}},{key:"done",value:function done(){return this._store.__done__()}},{key:"jobStatus",value:function jobStatus(a){return this._states.jobStatus(a)}},{key:"jobs",value:function jobs(a){return this._states.statusJobs(a)}},{key:"counts",value:function counts(){return this._states.statusCounts()}},{key:"_randomIndex",value:function _randomIndex(){return Math.random().toString(36).slice(2)}},{key:"check",value:function check(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:1;return this._store.__check__(a)}},{key:"_clearGlobalState",value:function _clearGlobalState(a){return this._scheduled[a]!=null?(clearTimeout(this._scheduled[a].expiration),delete this._scheduled[a],!0):!1}},{key:"_free",value:function _free(a,r,i,n){var o=this;return g$(function(){var s,u,c,p;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,2,,3]);return[4,o._store.__free__(a,i.weight)];case 1:c=_state.sent();if(u=c.running,o.Events.trigger("debug","Freed ".concat(i.id),n),u===0&&o.empty())return[2,o.Events.trigger("idle")];return[3,3];case 2:p=_state.sent();return[2,(s=p,o.Events.trigger("error",s))];case 3:return[2]}})})()}},{key:"_run",value:function _run(a,r,i){var _this=this;var n,o,s;return r.doRun(),n=this._clearGlobalState.bind(this,a),s=this._run.bind(this,a,r),o=this._free.bind(this,a,r),this._scheduled[a]={timeout:setTimeout(function(){return r.doExecute(_this._limiter,n,s,o)},i),expiration:r.options.expiration!=null?setTimeout(function(){return r.doExpire(n,s,o)},i+r.options.expiration):void 0,job:r}}},{key:"_drainOne",value:function _drainOne(a){var _this=this;return this._registerLock.schedule(function(){var r,i,n,o,s;if(_this.queued()===0)return _this.Promise.resolve(null);s=_this._queues.getFirst();var u=n=s.first();return o=u.options,r=u.args,a!=null&&o.weight>a?_this.Promise.resolve(null):(_this.Events.trigger("debug","Draining ".concat(o.id),{args:r,options:o}),i=_this._randomIndex(),_this._store.__register__(i,o.weight,o.expiration).then(function(param){var c=param.success,p=param.wait,l=param.reservoir;var m;return _this.Events.trigger("debug","Drained ".concat(o.id),{success:c,args:r,options:o}),c?(s.shift(),m=_this.empty(),m&&_this.Events.trigger("empty"),l===0&&_this.Events.trigger("depleted",m),_this._run(i,n,p),_this.Promise.resolve(o.weight)):_this.Promise.resolve(null)}))})}},{key:"_drainAll",value:function _drainAll(a){var _this=this;var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return this._drainOne(a).then(function(i){var n;return i!=null?(n=a!=null?a-i:a,_this._drainAll(n,r+i)):_this.Promise.resolve(r)}).catch(function(i){return _this.Events.trigger("error",i)})}},{key:"_dropAllQueued",value:function _dropAllQueued(a){return this._queues.shiftAll(function(r){return r.doDrop({message:a})})}},{key:"stop",value:function stop(){var _this=this;var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};var r,i;return a=Kc.load(a,this.stopDefaults),i=function(n){var o;return o=function(){var s;return s=_this._states.counts,s[0]+s[1]+s[2]+s[3]===n},new _this.Promise(function(s,u){return o()?s():_this.on("done",function(){if(o())return _this.removeAllListeners("done"),s()})})},r=a.dropWaitingJobs?(this._run=function r(n,o){return o.doDrop({message:a.dropErrorMessage})},this._drainOne=function(){return _this.Promise.resolve(null)},this._registerLock.schedule(function(){return _this._submitLock.schedule(function(){var n,o,s;o=_this._scheduled;for(n in o)s=o[n],_this.jobStatus(s.job.options.id)==="RUNNING"&&(clearTimeout(s.timeout),clearTimeout(s.expiration),s.job.doDrop({message:a.dropErrorMessage}));return _this._dropAllQueued(a.dropErrorMessage),i(0)})})):this.schedule({priority:x$-1,weight:0},function(){return i(1)}),this._receive=function(n){return n._reject(new e.prototype.BottleneckError(a.enqueueErrorMessage))},this.stop=function(){return _this.Promise.reject(new e.prototype.BottleneckError("stop() has already been called"))},r}},{key:"_addToQueue",value:function _addToQueue(a){var r=this;return g$(function(){var i,n,o,s,u,c,p,l,m,_tmp,_tmp1;return _ts_generator(this,function(_state){switch(_state.label){case 0:i=a.args,s=a.options;_state.label=1;case 1:_state.trys.push([1,3,,4]);return[4,r._store.__submit__(r.queued(),s.weight)];case 2:l=_state.sent();u=l.reachedHWM,n=l.blocked,p=l.strategy;return[3,4];case 3:m=_state.sent();return[2,(o=m,r.Events.trigger("debug","Could not queue ".concat(s.id),{args:i,options:s,error:o}),a.doDrop({error:o}),!1)];case 4:if(!n)return[3,5];_tmp=(a.doDrop(),!0);return[3,9];case 5:if(!(u&&(c=p===e.prototype.strategy.LEAK?r._queues.shiftLastFrom(s.priority):p===e.prototype.strategy.OVERFLOW_PRIORITY?r._queues.shiftLastFrom(s.priority+1):p===e.prototype.strategy.OVERFLOW?a:void 0,c!=null&&c.doDrop(),c==null||p===e.prototype.strategy.OVERFLOW)))return[3,6];_tmp1=(c==null&&a.doDrop(),u);return[3,8];case 6:a.doQueue(u,n),r._queues.push(a);return[4,r._drainAll()];case 7:_tmp1=(_state.sent(),u);_state.label=8;case 8:_tmp=_tmp1;_state.label=9;case 9:return[2,_tmp]}})})()}},{key:"_receive",value:function _receive(a){return this._states.jobStatus(a.options.id)!=null?(a._reject(new e.prototype.BottleneckError("A job with the same id already exists (id=".concat(a.options.id,")"))),!1):(a.doReceive(),this._submitLock.schedule(this._addToQueue,a))}},{key:"submit",value:function submit(){for(var _len=arguments.length,a=new Array(_len),_key=0;_key<_len;_key++){a[_key]=arguments[_key]}var _this=this;var r,i,n,o,s,u,c;if(typeof a[0]=="function"){var p,l,m,f;s=a,p=s,l=ZC(p),i=l[0],a=l.slice(1),m=qke.call(a,-1),f=Oke(m,1),r=f[0],o=Kc.load({},this.jobDefaults)}else{var g,h,_,A;u=a,g=u,h=ZC(g),o=h[0],i=h[1],a=h.slice(2),_=qke.call(a,-1),A=Oke(_,1),r=A[0],o=Kc.load(o,this.jobDefaults)}return c=function(){for(var _len=arguments.length,x=new Array(_len),_key=0;_key<_len;_key++){x[_key]=arguments[_key]}return new _this.Promise(function(y,v){return i.apply(void 0,_to_consumable_array(x).concat([function(){for(var _len=arguments.length,I=new Array(_len),_key=0;_key<_len;_key++){I[_key]=arguments[_key]}return(I[0]!=null?v:y)(I)}]))})},n=new _$(c,a,o,this.jobDefaults,this.rejectOnDrop,this.Events,this._states,this.Promise),n.promise.then(function(x){return typeof r=="function"?r.apply(void 0,_to_consumable_array(x)):void 0}).catch(function(x){return Array.isArray(x)?typeof r=="function"?r.apply(void 0,_to_consumable_array(x)):void 0:typeof r=="function"?r(x):void 0}),this._receive(n)}},{key:"schedule",value:function schedule(){for(var _len=arguments.length,a=new Array(_len),_key=0;_key<_len;_key++){a[_key]=arguments[_key]}var r,i,n;if(typeof a[0]=="function"){var o=a,s=ZC(o);n=s[0],a=s.slice(1),i={}}else{var u=a,c=ZC(u);i=c[0],n=c[1],a=c.slice(2)}return r=new _$(n,a,i,this.jobDefaults,this.rejectOnDrop,this.Events,this._states,this.Promise),this._receive(r),r.promise}},{key:"wrap",value:function wrap(a){var r,i;return r=this.schedule.bind(this),i=function i(){for(var _len=arguments.length,o=new Array(_len),_key=0;_key<_len;_key++){o[_key]=arguments[_key]}return r.apply(void 0,[a.bind(this)].concat(_to_consumable_array(o)))},i.withOptions=function(n){for(var _len=arguments.length,o=new Array(_len>1?_len-1:0),_key=1;_key<_len;_key++){o[_key-1]=arguments[_key]}return r.apply(void 0,[n,a].concat(_to_consumable_array(o)))},i}},{key:"updateSettings",value:function updateSettings(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};var r=this;return g$(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,r._store.__updateSettings__(Kc.overwrite(a,r.storeDefaults))];case 1:return[2,(_state.sent(),Kc.overwrite(a,r.instanceDefaults,r),r)]}})})()}},{key:"currentReservoir",value:function currentReservoir(){return this._store.__currentReservoir__()}},{key:"incrementReservoir",value:function incrementReservoir(){var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0;return this._store.__incrementReservoir__(a)}}]);return e}();return e.default=e,e.Events=h$,e.version=e.prototype.version=bke().version,e.strategy=e.prototype.strategy={LEAK:1,OVERFLOW:2,OVERFLOW_PRIORITY:4,BLOCK:3},e.BottleneckError=e.prototype.BottleneckError=Q1(),e.Group=e.prototype.Group=Mke(),e.RedisConnection=e.prototype.RedisConnection=WC(),e.IORedisConnection=e.prototype.IORedisConnection=VC(),e.Batcher=e.prototype.Batcher=Nke(),e.prototype.jobDefaults={priority:Gke,weight:1,expiration:null,id:""},e.prototype.storeDefaults={maxConcurrent:null,minTime:0,highWater:null,strategy:e.prototype.strategy.LEAK,penalty:null,reservoir:null,reservoirRefreshInterval:null,reservoirRefreshAmount:null,reservoirIncreaseInterval:null,reservoirIncreaseAmount:null,reservoirIncreaseMaximum:null},e.prototype.localStoreDefaults={Promise:Promise,timeout:null,heartbeatInterval:250},e.prototype.redisStoreDefaults={Promise:Promise,timeout:null,heartbeatInterval:5e3,clientTimeout:1e4,Redis:null,clientOptions:{},clusterNodes:null,clearDatastore:!1,connection:null},e.prototype.instanceDefaults={datastore:"local",connection:null,id:"",rejectOnDrop:!0,trackDoneStatus:!1,Promise:Promise},e.prototype.stopDefaults={enqueueErrorMessage:"This limiter has been stopped and cannot accept new jobs.",dropWaitingJobs:!0,dropErrorMessage:"This limiter has been stopped."},e}).call(void 0);Vke.exports=Uke});var Jke=T(function(alr,Kke){"use strict";Kke.exports=f$()});var QBe=T(function($xr,RBe){"use strict";var xaa=function xaa(){var t,a,r;return(r=(a=(t=globalThis[PBe])==null?void 0:t.get)==null?void 0:a.call(t))!=null?r:{}};var Ij=Object.defineProperty,daa=Object.getOwnPropertyDescriptor,maa=Object.getOwnPropertyNames,faa=Object.prototype.hasOwnProperty,gaa=function(e,t){for(var a in t)Ij(e,a,{get:t[a],enumerable:!0})},haa=function(e,t,a,r){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;if(t&&(typeof t==="undefined"?"undefined":_type_of(t))=="object"||typeof t=="function")try{var _loop=function(){var i=_step.value;!faa.call(e,i)&&i!==a&&Ij(e,i,{get:function(){return t[i]},enumerable:!(r=daa(t,i))||r.enumerable})};for(var _iterator=maa(t)[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true)_loop()}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return e},_aa=function(e){return haa(Ij({},"__esModule",{value:!0}),e)},MBe={};gaa(MBe,{SYMBOL_FOR_REQ_CONTEXT:function(){return PBe},getContext:function(){return xaa}});RBe.exports=_aa(MBe);var PBe=Symbol.for("@vercel/request-context")});var OBe=T(function(Uxr,NBe){"use strict";var Ej=Object.defineProperty,Aaa=Object.getOwnPropertyDescriptor,vaa=Object.getOwnPropertyNames,yaa=Object.prototype.hasOwnProperty,waa=function(e,t){for(var a in t)Ej(e,a,{get:t[a],enumerable:!0})},baa=function(e,t,a,r){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;if(t&&(typeof t==="undefined"?"undefined":_type_of(t))=="object"||typeof t=="function")try{var _loop=function(){var i=_step.value;!yaa.call(e,i)&&i!==a&&Ej(e,i,{get:function(){return t[i]},enumerable:!(r=Aaa(t,i))||r.enumerable})};for(var _iterator=vaa(t)[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true)_loop()}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return e},Iaa=function(e){return baa(Ej({},"__esModule",{value:!0}),e)},DBe={};waa(DBe,{AccessTokenMissingError:function(){return kj},RefreshAccessTokenFailedError:function(){return Cj}});NBe.exports=Iaa(DBe);var kj=/*#__PURE__*/function(Error1){_inherits(kj,Error1);function kj(){_class_call_check(this,kj);var _this;_this=_call_super(this,kj,["No authentication found. Please log in with the Vercel CLI (vercel login)."]),_this.name="AccessTokenMissingError";return _this}return kj}(_wrap_native_super(Error)),Cj=/*#__PURE__*/function(Error1){_inherits(Cj,Error1);function Cj(t){_class_call_check(this,Cj);var _this;_this=_call_super(this,Cj,["Failed to refresh authentication token.",{cause:t}]),_this.name="RefreshAccessTokenFailedError";return _this}return Cj}(_wrap_native_super(Error))});var Bj=T(function(Gxr,LBe){"use strict";var Paa=function Paa(){return _async_to_generator(function(){return _ts_generator(this,function(_state){return[2,""]})})()};var Raa=function Raa(){return""};var Qaa=function Qaa(){return _async_to_generator(function(){return _ts_generator(this,function(_state){throw new Error("getVercelToken is not supported in browser environments")})})()};var Sj=Object.defineProperty,kaa=Object.getOwnPropertyDescriptor,Caa=Object.getOwnPropertyNames,Eaa=Object.prototype.hasOwnProperty,Saa=function(e,t){for(var a in t)Sj(e,a,{get:t[a],enumerable:!0})},Baa=function(e,t,a,r){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;if(t&&(typeof t==="undefined"?"undefined":_type_of(t))=="object"||typeof t=="function")try{var _loop=function(){var i=_step.value;!Eaa.call(e,i)&&i!==a&&Sj(e,i,{get:function(){return t[i]},enumerable:!(r=kaa(t,i))||r.enumerable})};for(var _iterator=Caa(t)[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true)_loop()}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return e},Taa=function(e){return Baa(Sj({},"__esModule",{value:!0}),e)},qBe={};Saa(qBe,{AccessTokenMissingError:function(){return FBe.AccessTokenMissingError},RefreshAccessTokenFailedError:function(){return FBe.RefreshAccessTokenFailedError},getContext:function(){return Maa.getContext},getVercelOidcToken:function(){return Paa},getVercelOidcTokenSync:function(){return Raa},getVercelToken:function(){return Qaa}});LBe.exports=Taa(qBe);var Maa=QBe(),FBe=OBe()});var SDe=T(function(k9){(function(){"use strict";var e={not_string:/[^s]/,not_bool:/[^t]/,not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function t(o){return r(n(o),arguments)}function a(o,s){return t.apply(null,[o].concat(s||[]))}function r(o,s){var u=1,c=o.length,p,l="",m,f,g,h,_,A,x,y;for(m=0;m=0),g.type){case"b":p=parseInt(p,10).toString(2);break;case"c":p=String.fromCharCode(parseInt(p,10));break;case"d":case"i":p=parseInt(p,10);break;case"j":p=JSON.stringify(p,null,g.width?parseInt(g.width):0);break;case"e":p=g.precision?parseFloat(p).toExponential(g.precision):parseFloat(p).toExponential();break;case"f":p=g.precision?parseFloat(p).toFixed(g.precision):parseFloat(p);break;case"g":p=g.precision?String(Number(p.toPrecision(g.precision))):parseFloat(p);break;case"o":p=(parseInt(p,10)>>>0).toString(8);break;case"s":p=String(p),p=g.precision?p.substring(0,g.precision):p;break;case"t":p=String(!!p),p=g.precision?p.substring(0,g.precision):p;break;case"T":p=Object.prototype.toString.call(p).slice(8,-1).toLowerCase(),p=g.precision?p.substring(0,g.precision):p;break;case"u":p=parseInt(p,10)>>>0;break;case"v":p=p.valueOf(),p=g.precision?p.substring(0,g.precision):p;break;case"x":p=(parseInt(p,10)>>>0).toString(16);break;case"X":p=(parseInt(p,10)>>>0).toString(16).toUpperCase();break}e.json.test(g.type)?l+=p:(e.number.test(g.type)&&(!x||g.sign)?(y=x?"+":"-",p=p.toString().replace(e.sign,"")):y="",_=g.pad_char?g.pad_char==="0"?"0":g.pad_char.charAt(1):" ",A=g.width-(y+p).length,h=g.width&&A>0?_.repeat(A):"",l+=g.align?y+p+h:_==="0"?y+h+p:h+y+p)}return l}var i=Object.create(null);function n(o){if(i[o])return i[o];for(var s=o,u,c=[],p=0;s;){if((u=e.text.exec(s))!==null)c.push(u[0]);else if((u=e.modulo.exec(s))!==null)c.push("%");else if((u=e.placeholder.exec(s))!==null){if(u[2]){p|=1;var l=[],m=u[2],f=[];if((f=e.key.exec(m))!==null)for(l.push(f[1]);(m=m.substring(f[0].length))!=="";)if((f=e.key_access.exec(m))!==null)l.push(f[1]);else if((f=e.index_access.exec(m))!==null)l.push(f[1]);else throw new SyntaxError("[sprintf] failed to parse named argument key");else throw new SyntaxError("[sprintf] failed to parse named argument key");u[2]=l}else p|=2;if(p===3)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");c.push({placeholder:u[0],param_no:u[1],keys:u[2],sign:u[3],pad_char:u[4],align:u[5],width:u[6],precision:u[7],type:u[8]})}else throw new SyntaxError("[sprintf] unexpected placeholder");s=s.substring(u[0].length)}return i[o]=c}typeof k9!="undefined"&&(k9.sprintf=t,k9.vsprintf=a),typeof window!="undefined"&&(window.sprintf=t,window.vsprintf=a,typeof define=="function"&&define.amd&&define(function(){return{sprintf:t,vsprintf:a}}))})()});var nka={};Au(nka,{default:function(){return kT}});module.exports=mKe(nka);var vBr=va(VJ()),yBr=va(ave());var rve,Bh=(rve=globalThis.process)!=null?rve:{cwd:function cwd(){return"/"},env:{}};typeof Bh.cwd!="function"&&(Bh.cwd=function(){return"/"});(!Bh.env||_type_of(Bh.env)!="object")&&(Bh.env={});globalThis.process=Bh;var uye=va(sve()),lye=require("obsidian");var yQt={2:function(e){var t=function t(i,n,o){_instanceof(i,RegExp)&&(i=a(i,o)),_instanceof(n,RegExp)&&(n=a(n,o));var s=r(i,n,o);return s&&{start:s[0],end:s[1],pre:o.slice(0,s[0]),body:o.slice(s[0]+i.length,s[1]),post:o.slice(s[1]+n.length)}};var a=function a(i,n){var o=n.match(i);return o?o[0]:null};var r=function r(i,n,o){var s,u,c,p,l,m=o.indexOf(i),f=o.indexOf(n,m+1),g=m;if(m>=0&&f>0){for(s=[],c=o.length;g>=0&&!l;)g==m?(s.push(g),m=o.indexOf(i,g+1)):s.length==1?l=[s.pop(),f]:((u=s.pop())=0?m:f;s.length&&(l=[c,p])}return l};e.exports=t,t.range=r},101:function(e,t,a){var r;e=a.nmd(e),function(i){var n=(e&&e.exports,(typeof global==="undefined"?"undefined":_type_of(global))=="object"&&global);n.global!==n&&n.window;var o=function o(l){this.message=l};(o.prototype=new Error).name="InvalidCharacterError";var s=function s(l){throw new o(l)},u="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",c=/[\t\n\f\r ]/g,p={encode:function encode(l){l=String(l),/[^\0-\xFF]/.test(l)&&s("The string to be encoded contains characters outside of the Latin1 range.");for(var m,f,g,h,_=l.length%3,A="",x=-1,y=l.length-_;++x>18&63)+u.charAt(h>>12&63)+u.charAt(h>>6&63)+u.charAt(63&h);return _==2?(m=l.charCodeAt(x)<<8,f=l.charCodeAt(++x),A+=u.charAt((h=m+f)>>10)+u.charAt(h>>4&63)+u.charAt(h<<2&63)+"="):_==1&&(h=l.charCodeAt(x),A+=u.charAt(h>>2)+u.charAt(h<<4&63)+"=="),A},decode:function decode(l){var m=(l=String(l).replace(c,"")).length;m%4==0&&(m=(l=l.replace(/==?$/,"")).length),(m%4==1||/[^+a-zA-Z0-9/]/.test(l))&&s("Invalid character: the string to be decoded is not correctly encoded.");for(var f,g,h=0,_="",A=-1;++A>(-2*h&6)));return _},version:"1.0.0"};(r=(function(){return p}).call(t,a,t,e))===void 0||(e.exports=r)}()},172:function(e,t){t.d=function(a){if(!a)return 0;for(var r=(a=a.toString()).length,i=a.length;i--;){var n=a.charCodeAt(i);56320<=n&&n<=57343&&i--,127>>32-i},rotr:function rotr(r,i){return r<<32-i|r>>>i},endian:function endian(r){if(r.constructor==Number)return 0xff00ff&a.rotl(r,8)|0xff00ff00&a.rotl(r,24);for(var i=0;i0;r--)i.push(Math.floor(256*Math.random()));return i},bytesToWords:function bytesToWords(r){for(var i=[],n=0,o=0;n>>5]|=r[n]<<24-o%32;return i},wordsToBytes:function wordsToBytes(r){for(var i=[],n=0;n<32*r.length;n+=8)i.push(r[n>>>5]>>>24-n%32&255);return i},bytesToHex:function bytesToHex(r){for(var i=[],n=0;n>>4).toString(16)),i.push((15&r[n]).toString(16));return i.join("")},hexToBytes:function hexToBytes(r){for(var i=[],n=0;n>>6*(3-s)&63)):i.push("=");return i.join("")},base64ToBytes:function base64ToBytes(r){r=r.replace(/[^A-Z0-9+\/]/gi,"");for(var i=[],n=0,o=0;n>>6-2*o);return i}},e.exports=a},635:function(e,t,a){var r=a(31),i=a(338),n=a(221);e.exports={XMLParser:i,XMLValidator:r,XMLBuilder:n}},118:function(e){e.exports=function(t){return typeof t=="function"?t:Array.isArray(t)?function(a){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=t[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var r=_step.value;if(typeof r=="string"&&a===r||_instanceof(r,RegExp)&&r.test(a))return!0}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}}:function(){return!1}}},705:function(e,t){var a=":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD",r="["+a+"]["+a+"\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*",i=new RegExp("^"+r+"$");t.isExist=function(n){return n!==void 0},t.isEmptyObject=function(n){return Object.keys(n).length===0},t.merge=function(n,o,s){if(o){var u=Object.keys(o),c=u.length;for(var p=0;p5&&I==="xml")return g("InvalidXml","XML declaration allowed only at the start of the document.",_(x,y));if(x[y]=="?"&&x[y+1]==">"){y++;break}}return y};var s=function s(x,y){if(x.length>y+5&&x[y+1]==="-"&&x[y+2]==="-"){for(y+=3;y"){y+=2;break}}else if(x.length>y+8&&x[y+1]==="D"&&x[y+2]==="O"&&x[y+3]==="C"&&x[y+4]==="T"&&x[y+5]==="Y"&&x[y+6]==="P"&&x[y+7]==="E"){var v=1;for(y+=8;y"&&(v--,v===0))break}else if(x.length>y+9&&x[y+1]==="["&&x[y+2]==="C"&&x[y+3]==="D"&&x[y+4]==="A"&&x[y+5]==="T"&&x[y+6]==="A"&&x[y+7]==="["){for(y+=8;y"){y+=2;break}}return y};var p=function p(x,y){var v="",I="",b=!1;for(;y"&&I===""){b=!0;break}v+=x[y]}return I===""&&{value:v,index:y,tagClosed:b}};var m=function m(x,y){var v=r.getAllMatches(x,l),I={};for(var b=0;b"&&x[k]!==" "&&x[k]!==" "&&x[k]!=="\n"&&x[k]!=="\r";k++)P+=x[k];if(P=P.trim(),P[P.length-1]==="/"&&(P=P.substring(0,P.length-1),k--),w=P,!r.isName(w)){var R=void 0;return R=P.trim().length===0?"Invalid space after '<'.":"Tag '"+P+"' is an invalid name.",g("InvalidTag",R,_(x,k))}var B=p(x,k);if(B===!1)return g("InvalidAttr","Attributes for '"+P+"' have open quote.",_(x,k));var M=B.value;if(k=B.index,M[M.length-1]==="/"){var R4=k-M.length;M=M.substring(0,M.length-1);var N=m(M,y);if(N!==!0)return g(N.err.code,N.err.msg,_(x,R4+N.err.line));I=!0}else if(E){if(!B.tagClosed)return g("InvalidTag","Closing tag '"+P+"' doesn't have proper closing.",_(x,k));if(M.trim().length>0)return g("InvalidTag","Closing tag '"+P+"' can't have attributes or invalid starting.",_(x,C));if(v.length===0)return g("InvalidTag","Closing tag '"+P+"' has not been opened.",_(x,C));{var R6=v.pop();if(P!==R6.tagName){var N10=_(x,R6.tagStartPos);return g("InvalidTag","Expected closing tag '"+R6.tagName+"' (opened in line "+N10.line+", col "+N10.col+") instead of closing tag '"+P+"'.",_(x,C))}v.length==0&&(b=!0)}}else{var R10=m(M,y);if(R10!==!0)return g(R10.err.code,R10.err.msg,_(x,k-M.length+R10.err.line));if(b===!0)return g("InvalidXml","Multiple possible root nodes found.",_(x,k));y.unpairedTags.indexOf(P)!==-1||v.push({tagName:P,tagStartPos:C}),I=!0}for(k++;k0)||g("InvalidXml","Invalid '"+JSON.stringify(v.map(function(k){return k.tagName}),null,4).replace(/\r?\n/g,"")+"' found.",{line:1,col:1}):g("InvalidXml","Start tag expected.",1)};var u='"',c="'";var l=new RegExp("(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['\"])(([\\s\\S])*?)\\5)?","g")},221:function(e,t,a){var o=function o(p){this.options=Object.assign({},n,p),this.options.ignoreAttributes===!0||this.options.attributesGroupName?this.isAttribute=function(){return!1}:(this.ignoreAttributesFn=i(this.options.ignoreAttributes),this.attrPrefixLen=this.options.attributeNamePrefix.length,this.isAttribute=c),this.processTextOrObjNode=s,this.options.format?(this.indentate=u,this.tagEndChar=">\n",this.newLine="\n"):(this.indentate=function(){return""},this.tagEndChar=">",this.newLine="")};var s=function s(p,l,m,f){var g=this.j2x(p,m+1,f.concat(l));return p[this.options.textNodeName]!==void 0&&Object.keys(p).length===1?this.buildTextValNode(p[this.options.textNodeName],l,g.attrStr,m):this.buildObjectNode(g.val,l,g.attrStr,m)};var u=function u(p){return this.options.indentBy.repeat(p)};var c=function c(p){return!(!p.startsWith(this.options.attributeNamePrefix)||p===this.options.textNodeName)&&p.substr(this.attrPrefixLen)};var r=a(87),i=a(118),n={attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,cdataPropName:!1,format:!1,indentBy:" ",suppressEmptyNode:!1,suppressUnpairedNode:!0,suppressBooleanAttributes:!0,tagValueProcessor:function tagValueProcessor(p,l){return l},attributeValueProcessor:function attributeValueProcessor(p,l){return l},preserveOrder:!1,commentPropName:!1,unpairedTags:[],entities:[{regex:new RegExp("&","g"),val:"&"},{regex:new RegExp(">","g"),val:">"},{regex:new RegExp("<","g"),val:"<"},{regex:new RegExp("'","g"),val:"'"},{regex:new RegExp('"',"g"),val:"""}],processEntities:!0,stopNodes:[],oneListGroup:!1};o.prototype.build=function(p){return this.options.preserveOrder?r(p,this.options):(Array.isArray(p)&&this.options.arrayNodeName&&this.options.arrayNodeName.length>1&&(p=_define_property({},this.options.arrayNodeName,p)),this.j2x(p,0,[]).val)},o.prototype.j2x=function(p,l,m){var f="",g="",h=m.join(".");for(var _ in p)if(Object.prototype.hasOwnProperty.call(p,_))if(p[_]===void 0)this.isAttribute(_)&&(g+="");else if(p[_]===null)this.isAttribute(_)?g+="":_[0]==="?"?g+=this.indentate(l)+"<"+_+"?"+this.tagEndChar:g+=this.indentate(l)+"<"+_+"/"+this.tagEndChar;else if(_instanceof(p[_],Date))g+=this.buildTextValNode(p[_],_,"",l);else if(_type_of(p[_])!="object"){var A=this.isAttribute(_);if(A&&!this.ignoreAttributesFn(A,h))f+=this.buildAttrPairStr(A,""+p[_]);else if(!A)if(_===this.options.textNodeName){var x=this.options.tagValueProcessor(_,""+p[_]);g+=this.replaceEntitiesValue(x)}else g+=this.buildTextValNode(p[_],_,"",l)}else if(Array.isArray(p[_])){var A1=p[_].length,x2="",y="";for(var v=0;v")+this.newLine:this.indentate(f)+"<"+l+m+h+this.tagEndChar+p+this.indentate(f)+g:this.indentate(f)+"<"+l+m+h+">"+p+g}},o.prototype.closeTag=function(p){var l="";return this.options.unpairedTags.indexOf(p)!==-1?this.options.suppressUnpairedNode||(l="/"):l=this.options.suppressEmptyNode?"/":">")+this.newLine;if(this.options.commentPropName!==!1&&l===this.options.commentPropName)return this.indentate(f)+"")+this.newLine;if(l[0]==="?")return this.indentate(f)+"<"+l+m+"?"+this.tagEndChar;{var g=this.options.tagValueProcessor(l,p);return g=this.replaceEntitiesValue(g),g===""?this.indentate(f)+"<"+l+m+this.closeTag(l)+this.tagEndChar:this.indentate(f)+"<"+l+m+">"+g+"0&&this.options.processEntities)for(var l=0;l0&&s.processEntities)for(var u=0;u"),l=!1;continue}if(g===s.commentPropName){p+=c+""),l=!0;continue}if(g[0]==="?"){var y2=r(f[":@"],s),v=g==="?xml"?"":c,I=f[g][0][s.textNodeName];I=I.length!==0?" "+I:"",p+=v+"<".concat(g).concat(I).concat(y2,"?>"),l=!0;continue}var _=c;_!==""&&(_+=s.indentBy);var A=c+"<".concat(g).concat(r(f[":@"],s)),x=t(f[g],s,h,_);s.unpairedTags.indexOf(g)!==-1?s.suppressUnpairedNode?p+=A+">":p+=A+"/>":x&&x.length!==0||!s.suppressEmptyNode?x&&x.endsWith(">")?p+=A+">".concat(x).concat(c,""):(p+=A+">",x&&c!==""&&(x.includes("/>")||x.includes("")):p+=A+"/>",l=!0}return p}e.exports=function(o,s){var u="";return s.format&&s.indentBy.length>0&&(u="\n"),t(o,s,"",u)}},193:function(e,t,a){var i=function i(l,m){var f="";for(;m"){if(_?l[m-1]==="-"&&l[m-2]==="-"&&(_=!1,g--):g--,g===0)break}else l[m]==="["?h=!0:A+=l[m];else{if(h&&o(l,m)){var x=void 0,y=void 0;var ref;m+=7,ref=_sliced_to_array(i(l,m+1),3),x=ref[0],y=ref[1],m=ref[2],ref,y.indexOf("&")===-1&&(f[p(x)]={regx:RegExp("&".concat(x,";"),"g"),val:y})}else if(h&&s(l,m))m+=8;else if(h&&u(l,m))m+=8;else if(h&&c(l,m))m+=9;else{if(!n)throw new Error("Invalid DOCTYPE");_=!0}g++,A=""}if(g!==0)throw new Error("Unclosed DOCTYPE")}return{entities:f,i:m}}},63:function(e,t){var a={preserveOrder:!1,attributeNamePrefix:"@_",attributesGroupName:!1,textNodeName:"#text",ignoreAttributes:!0,removeNSPrefix:!1,allowBooleanAttributes:!1,parseTagValue:!0,parseAttributeValue:!1,trimValues:!0,cdataPropName:!1,numberParseOptions:{hex:!0,leadingZeros:!0,eNotation:!0},tagValueProcessor:function tagValueProcessor(r,i){return i},attributeValueProcessor:function attributeValueProcessor(r,i){return i},stopNodes:[],alwaysCreateTextNode:!1,isArray:function(){return!1},commentPropName:!1,unpairedTags:[],processEntities:!0,htmlEntities:!1,ignoreDeclaration:!1,ignorePiTags:!1,transformTagName:!1,transformAttributeName:!1,updateTag:function updateTag(r,i,n){return r}};t.buildOptions=function(r){return Object.assign({},a,r)},t.defaultOptions=a},299:function(e,t,a){var u=function u(b){var w=Object.keys(b);for(var k=0;k0)){B||(b=this.replaceEntitiesValue(b));var M=this.options.tagValueProcessor(w,b,k,E,P);return M==null?b:(typeof M==="undefined"?"undefined":_type_of(M))!=(typeof b==="undefined"?"undefined":_type_of(b))||M!==b?M:this.options.trimValues||b.trim()===b?I(b,this.options.parseTagValue,this.options.numberParseOptions):b}};var p=function p(b){if(this.options.removeNSPrefix){var w=b.split(":"),k=b.charAt(0)==="/"?"/":"";if(w[0]==="xmlns")return"";w.length===2&&(b=k+w[1])}return b};var m=function m(b,w,k){if(this.options.ignoreAttributes!==!0&&typeof b=="string"){var C=r.getAllMatches(b,l),E=C.length,P={};for(var B=0;B2&&arguments[2]!==void 0?arguments[2]:">",K="";for(var U=O;U3&&arguments[3]!==void 0?arguments[3]:">");if(!C)return;var E=C.data,P=C.index,B=E.search(/\s/),M=E,R=!0;B!==-1&&(M=E.substring(0,B),E=E.substring(B+1).trimStart());var N=M;if(k){var Q=M.indexOf(":");Q!==-1&&(M=M.substr(Q+1),R=M!==C.data.substr(Q+1))}return{tagName:M,tagExp:E,closeIndex:P,attrExpPresent:R,rawTagName:N}};var v=function v(b,w,k){var C=k,E=1;for(;k",k,"".concat(w," is not closed"));if(b.substring(k+2,P).trim()===w&&(E--,E===0))return{tagContent:b.substring(C,k),i:P};k=P}else if(b[k+1]==="?")k=x(b,"?>",k+1,"StopNode is not closed.");else if(b.substr(k+1,3)==="!--")k=x(b,"-->",k+3,"StopNode is not closed.");else if(b.substr(k+1,2)==="![")k=x(b,"]]>",k,"StopNode is not closed.")-2;else{var P2=y(b,k,">");P2&&((P2&&P2.tagName)===w&&P2.tagExp[P2.tagExp.length-1]!=="/"&&E++,k=P2.closeIndex)}};var I=function I(b,w,k){if(w&&typeof b=="string"){var C=b.trim();return C==="true"||C!=="false"&&o(b,k)}return r.isExist(b)?b:""};var r=a(705),i=a(365),n=a(193),o=a(494),s=a(118);var l=new RegExp("([^\\s=]+)\\s*(=\\s*(['\"])([\\s\\S]*?)\\3)?","gm");var f=function f(b){b=b.replace(/\r\n?/g,"\n");var w=new i("!xml"),k=w,C="",E="";for(var P=0;P",P,"Closing Tag is not closed."),M=b.substring(P+2,B).trim();if(this.options.removeNSPrefix){var Q=M.indexOf(":");Q!==-1&&(M=M.substr(Q+1))}this.options.transformTagName&&(M=this.options.transformTagName(M)),k&&(C=this.saveTextToParentTag(C,k,E));var R=E.substring(E.lastIndexOf(".")+1);if(M&&this.options.unpairedTags.indexOf(M)!==-1)throw new Error("Unpaired tag can not be used as closing tag: "));var N=0;R&&this.options.unpairedTags.indexOf(R)!==-1?(N=E.lastIndexOf(".",E.lastIndexOf(".")-1),this.tagsNodeStack.pop()):N=E.lastIndexOf("."),E=E.substring(0,N),k=this.tagsNodeStack.pop(),C="",P=B}else if(b[P+1]==="?"){var B6=y(b,P,!1,"?>");if(!B6)throw new Error("Pi Tag is not closed.");if(C=this.saveTextToParentTag(C,k,E),!(this.options.ignoreDeclaration&&B6.tagName==="?xml"||this.options.ignorePiTags)){var M2=new i(B6.tagName);M2.add(this.options.textNodeName,""),B6.tagName!==B6.tagExp&&B6.attrExpPresent&&(M2[":@"]=this.buildAttributesMap(B6.tagExp,E,B6.tagName)),this.addChild(k,M2,E)}P=B6.closeIndex+1}else if(b.substr(P+1,3)==="!--"){var B10=x(b,"-->",P+4,"Comment is not closed.");if(this.options.commentPropName){var M4=b.substring(P+4,B10-2);C=this.saveTextToParentTag(C,k,E),k.add(this.options.commentPropName,[_define_property({},this.options.textNodeName,M4)])}P=B10}else if(b.substr(P+1,2)==="!D"){var B11=n(b,P);this.docTypeEntities=B11.entities,P=B11.i}else if(b.substr(P+1,2)==="!["){var B12=x(b,"]]>",P,"CDATA is not closed.")-2,M6=b.substring(P+9,B12);C=this.saveTextToParentTag(C,k,E);var R4=this.parseTextData(M6,k.tagname,E,!0,!1,!0,!0);R4==null&&(R4=""),this.options.cdataPropName?k.add(this.options.cdataPropName,[_define_property({},this.options.textNodeName,M6)]):k.add(this.options.textNodeName,R4),P=B12+2}else{var B13=y(b,P,this.options.removeNSPrefix),M10=B13.tagName,R6=B13.rawTagName,N10=B13.tagExp,Q2=B13.attrExpPresent,O=B13.closeIndex;this.options.transformTagName&&(M10=this.options.transformTagName(M10)),k&&C&&k.tagname!=="!xml"&&(C=this.saveTextToParentTag(C,k,E,!1));var G=k;if(G&&this.options.unpairedTags.indexOf(G.tagname)!==-1&&(k=this.tagsNodeStack.pop(),E=E.substring(0,E.lastIndexOf("."))),M10!==w.tagname&&(E+=E?"."+M10:M10),this.isItStopNode(this.options.stopNodes,E,M10)){var $="";if(N10.length>0&&N10.lastIndexOf("/")===N10.length-1)M10[M10.length-1]==="/"?(M10=M10.substr(0,M10.length-1),E=E.substr(0,E.length-1),N10=M10):N10=N10.substr(0,N10.length-1),P=B13.closeIndex;else if(this.options.unpairedTags.indexOf(M10)!==-1)P=B13.closeIndex;else{var U=this.readStopNodeData(b,R6,O+1);if(!U)throw new Error("Unexpected end of ".concat(R6));P=U.i,$=U.tagContent}var K=new i(M10);M10!==N10&&Q2&&(K[":@"]=this.buildAttributesMap(N10,E,M10)),$&&($=this.parseTextData($,M10,E,!0,Q2,!0,!0)),E=E.substr(0,E.lastIndexOf(".")),K.add(this.options.textNodeName,$),this.addChild(k,K,E)}else{if(N10.length>0&&N10.lastIndexOf("/")===N10.length-1){M10[M10.length-1]==="/"?(M10=M10.substr(0,M10.length-1),E=E.substr(0,E.length-1),N10=M10):N10=N10.substr(0,N10.length-1),this.options.transformTagName&&(M10=this.options.transformTagName(M10));var $2=new i(M10);M10!==N10&&Q2&&($2[":@"]=this.buildAttributesMap(N10,E,M10)),this.addChild(k,$2,E),E=E.substr(0,E.lastIndexOf("."))}else{var $4=new i(M10);this.tagsNodeStack.push(k),M10!==N10&&Q2&&($4[":@"]=this.buildAttributesMap(N10,E,M10)),this.addChild(k,$4,E),k=$4}C="",P=O}}else C+=b[P];return w.child};var h=function h(b){if(this.options.processEntities){for(var w in this.docTypeEntities){var k=this.docTypeEntities[w];b=b.replace(k.regx,k.val)}for(var w2 in this.lastEntities){var k4=this.lastEntities[w2];b=b.replace(k4.regex,k4.val)}if(this.options.htmlEntities)for(var w6 in this.htmlEntities){var k9=this.htmlEntities[w6];b=b.replace(k9.regex,k9.val)}b=b.replace(this.ampEntity.regex,this.ampEntity.val)}return b};e.exports=function _class(b){_class_call_check(this,_class);this.options=b,this.currentNode=null,this.tagsNodeStack=[],this.docTypeEntities={},this.lastEntities={apos:{regex:/&(apos|#39|#x27);/g,val:"'"},gt:{regex:/&(gt|#62|#x3E);/g,val:">"},lt:{regex:/&(lt|#60|#x3C);/g,val:"<"},quot:{regex:/&(quot|#34|#x22);/g,val:'"'}},this.ampEntity={regex:/&(amp|#38|#x26);/g,val:"&"},this.htmlEntities={space:{regex:/&(nbsp|#160);/g,val:" "},cent:{regex:/&(cent|#162);/g,val:"\xa2"},pound:{regex:/&(pound|#163);/g,val:"\xa3"},yen:{regex:/&(yen|#165);/g,val:"\xa5"},euro:{regex:/&(euro|#8364);/g,val:"€"},copyright:{regex:/&(copy|#169);/g,val:"\xa9"},reg:{regex:/&(reg|#174);/g,val:"\xae"},inr:{regex:/&(inr|#8377);/g,val:"₹"},num_dec:{regex:/&#([0-9]{1,7});/g,val:function(w,k){return String.fromCharCode(Number.parseInt(k,10))}},num_hex:{regex:/&#x([0-9a-fA-F]{1,6});/g,val:function(w,k){return String.fromCharCode(Number.parseInt(k,16))}}},this.addExternalEntities=u,this.parseXml=f,this.parseTextData=c,this.resolveNameSpace=p,this.buildAttributesMap=m,this.isItStopNode=A,this.replaceEntitiesValue=h,this.readStopNodeData=v,this.saveTextToParentTag=_,this.addChild=g,this.ignoreAttributesFn=s(this.options.ignoreAttributes)}},338:function(e,t,a){var _a1=a(63),r=_a1.buildOptions,i=a(299),_a2=a(728),n=_a2.prettify,o=a(31);e.exports=/*#__PURE__*/function(){function _class(s){_class_call_check(this,_class);this.externalEntities={},this.options=r(s)}_create_class(_class,[{key:"parse",value:function parse(s,u){if(typeof s!="string"){if(!s.toString)throw new Error("XML data is accepted in String or Bytes[] form.");s=s.toString()}if(u){u===!0&&(u={});var l=o.validate(s,u);if(l!==!0)throw Error("".concat(l.err.msg,":").concat(l.err.line,":").concat(l.err.col))}var c=new i(this.options);c.addExternalEntities(this.externalEntities);var p=c.parseXml(s);return this.options.preserveOrder||p===void 0?p:n(p,this.options)}},{key:"addEntity",value:function addEntity(s,u){if(u.indexOf("&")!==-1)throw new Error("Entity value can't have '&'");if(s.indexOf("&")!==-1||s.indexOf(";")!==-1)throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for ' '");if(u==="&")throw new Error("An entity with value '&' is not permitted");this.externalEntities[s]=u}}]);return _class}()},728:function(e,t){var r=function r(o){var s=Object.keys(o);for(var u=0;u0&&(p[s.textNodeName]=c):c!==void 0&&(p[s.textNodeName]=c),p}t.prettify=function(o,s){return a(o,s)}},365:function(e){e.exports=/*#__PURE__*/function(){function _class(t){_class_call_check(this,_class);this.tagname=t,this.child=[],this[":@"]={}}_create_class(_class,[{key:"add",value:function add(t,a){t==="__proto__"&&(t="#__proto__"),this.child.push(_define_property({},t,a))}},{key:"addChild",value:function addChild(t){var _obj;t.tagname==="__proto__"&&(t.tagname="#__proto__"),t[":@"]&&Object.keys(t[":@"]).length>0?this.child.push((_obj={},_define_property(_obj,t.tagname,t.child),_define_property(_obj,":@",t[":@"]),_obj)):this.child.push(_define_property({},t.tagname,t.child))}}]);return _class}()},135:function(e){var t=function t(a){return!!a.constructor&&typeof a.constructor.isBuffer=="function"&&a.constructor.isBuffer(a)};e.exports=function(a){return a!=null&&(t(a)||function(r){return typeof r.readFloatLE=="function"&&typeof r.slice=="function"&&t(r.slice(0,0))}(a)||!!a._isBuffer)}},542:function(e,t,a){(function(){var r=a(298),i=a(526).utf8,n=a(135),o=a(526).bin,s=function s6(u,c){u.constructor==String?u=c&&c.encoding==="binary"?o.stringToBytes(u):i.stringToBytes(u):n(u)?u=Array.prototype.slice.call(u,0):Array.isArray(u)||u.constructor===Uint8Array||(u=u.toString());for(var p=r.bytesToWords(u),l=8*u.length,m=0x67452301,f=-0x10325477,g=-0x67452302,h=0x10325476,_=0;_>>24)|0xff00ff00&(p[_]<<24|p[_]>>>8);p[l>>>5]|=128<>>9<<4)]=l;var A=s._ff,x=s._gg,y=s._hh,v=s._ii;for(_=0;_>>0,f=f+b>>>0,g=g+w>>>0,h=h+k>>>0}return r.endian([m,f,g,h])};s._ff=function(u,c,p,l,m,f,g){var h=u+(c&p|~c&l)+(m>>>0)+g;return(h<>>32-f)+c},s._gg=function(u,c,p,l,m,f,g){var h=u+(c&l|p&~l)+(m>>>0)+g;return(h<>>32-f)+c},s._hh=function(u,c,p,l,m,f,g){var h=u+(c^p^l)+(m>>>0)+g;return(h<>>32-f)+c},s._ii=function(u,c,p,l,m,f,g){var h=u+(p^(c|~l))+(m>>>0)+g;return(h<>>32-f)+c},s._blocksize=16,s._digestsize=16,e.exports=function(u,c){if(u==null)throw new Error("Illegal argument "+u);var p=r.wordsToBytes(s(u,c));return c&&c.asBytes?p:c&&c.asString?o.bytesToString(p):r.bytesToHex(p)}})()},285:function(e,t,a){var c=function c(A){return parseInt(A,10)==A?parseInt(A,10):A.charCodeAt(0)};var p=function p(A){return A.split(i).join("\\").split(n).join("{").split(o).join("}").split(s).join(",").split(u).join(".")};var m=function m(A){return"{"+A+"}"};var f=function f(A){return/^-?0\d/.test(A)};var g=function g(A,x){return A<=x};var h=function h(A,x){return A>=x};var r=a(2);e.exports=function(A){return A?(A.substr(0,2)==="{}"&&(A="\\{\\}"+A.substr(2)),_(function(x){return x.split("\\\\").join(i).split("\\{").join(n).split("\\}").join(o).split("\\,").join(s).split("\\.").join(u)}(A),!0).map(p)):[]};var i="\0SLASH"+Math.random()+"\0",n="\0OPEN"+Math.random()+"\0",o="\0CLOSE"+Math.random()+"\0",s="\0COMMA"+Math.random()+"\0",u="\0PERIOD"+Math.random()+"\0";function l(A){if(!A)return[""];var x=[],y=r("{","}",A);if(!y)return A.split(",");var v=y.pre,I=y.body,b=y.post,w=v.split(",");w[w.length-1]+="{"+I+"}";var k=l(b);return b.length&&(w[w.length-1]+=k.shift(),w.push.apply(w,k)),x.push.apply(x,w),x}function _(A,x){var y=[],v=r("{","}",A);if(!v)return[A];var I=v.pre,b=v.post.length?_(v.post,!1):[""];if(/\$$/.test(v.pre))for(var w=0;w=0;if(!M&&!R)return v.post.match(/,.*\}/)?_(A=v.pre+"{"+v.body+o+v.post):[A];if(M)C=v.body.split(/\.\./);else if((C=l(v.body)).length===1&&(C=_(C[0],!1).map(m)).length===1)return b.map(function(J){return v.pre+C[0]+J});if(M){var N=c(C[0]),Q=c(C[1]),O=Math.max(C[0].length,C[1].length),G=C.length==3?Math.abs(c(C[2])):1,$=g;Q0){var _e=new Array(ae+1).join("0");j=U<0?"-"+_e+j.slice(1):_e+j}}E.push(j)}}else{E=[];for(var me=0;me2&&arguments[2]!==void 0?arguments[2]:function l(){},m=p.split("."),f=m.length,g=function g(A){var x=m[A];if(!c)return{v:void 0};if(x==="+"){if(Array.isArray(c))return{v:c.map(function(v,I){var b=m.slice(A+1);return b.length>0?s(v,b.join("."),l):l(c,I,m,A)})};var y=m.slice(0,A).join(".");throw new Error("Object at wildcard (".concat(y,") is not an array"))}c=l(c,x,m,A)},h=0;h2&&arguments[2]!==void 0?arguments[2]:{};if(t(c)!="object"||c===null||p===void 0)return!1;if(typeof p=="number")return p in c;try{var m=!1;return s(c,p,function(f,g,h,_){if(!u(h,_))return f&&f[g];m=l.own?f.hasOwnProperty(g):g in f}),m}catch(f){return!1}},hasOwn:function hasOwn(c,p,l){return this.has(c,p,l||{own:!0})},isIn:function isIn(c,p,l){var m=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};if(t(c)!="object"||c===null||p===void 0)return!1;try{var f=!1,g=!1;return s(c,p,function(h,_,A,x){return f=f||h===l||!!h&&h[_]===l,g=u(A,x)&&t(h)==="object"&&_ in h,h&&h[_]}),m.validPath?f&&g:f}catch(h){return!1}},ObjectPrototypeMutationError:o}},47:function(e,t,a){var n=function n(c,p){for(var l=[],m=0;m=-1&&!p;l--){var m=l>=0?arguments[l]:process.cwd();if(!i(m))throw new TypeError("Arguments to path.resolve must be strings");m&&(c=m+"/"+c,p=m.charAt(0)==="/")}return(p?"/":"")+(c=n(c.split("/"),!p).join("/"))||"."},s.normalize=function(c){var p=s.isAbsolute(c),l=c.substr(-1)==="/";return(c=n(c.split("/"),!p).join("/"))||p||(c="."),c&&l&&(c+="/"),(p?"/":"")+c},s.isAbsolute=function(c){return c.charAt(0)==="/"},s.join=function(){for(var c="",p=0;p=0&&x[v]==="";v--);return y>v?[]:x.slice(y,v+1)}c=s.resolve(c).substr(1),p=s.resolve(p).substr(1);for(var m=l(c.split("/")),f=l(p.split("/")),g=Math.min(m.length,f.length),h=g,_=0;_1&&arguments[1]!==void 0?arguments[1]:{};if(n=Object.assign({},r,n),!i||typeof i!="string")return i;var o=i.trim();if(n.skipLike!==void 0&&n.skipLike.test(o))return i;if(n.hex&&t.test(o))return Number.parseInt(o,16);{var u=a.exec(o);if(u){var c=u[1],p=u[2],l=((s=u[3])&&s.indexOf(".")!==-1&&((s=s.replace(/0+$/,""))==="."?s="0":s[0]==="."?s="0"+s:s[s.length-1]==="."&&(s=s.substr(0,s.length-1))),s),m=u[4]||u[6];if(!n.leadingZeros&&p.length>0&&c&&o[2]!=="."||!n.leadingZeros&&p.length>0&&!c&&o[1]!==".")return i;{var f=Number(o),g=""+f;return g.search(/[eE]/)!==-1||m?n.eNotation?f:i:o.indexOf(".")!==-1?g==="0"&&l===""||g===l||c&&g==="-"+l?f:i:p?l===g||c+l===g?f:i:o===g||o===c+g?f:i}}return i}var s}},737:function(e,t,a){var l=function l(x){return(x||"").toString().replace(n,"")};var g=function g(x){var y,v=(typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{}).location||{},I={},b=_type_of(x=x||v);if(x.protocol==="blob:")I=new A(unescape(x.pathname),{});else if(b==="string")for(y in I=new A(x,{}),f)delete I[y];else if(b==="object"){for(y in x)y in f||(I[y]=x[y]);I.slashes===void 0&&(I.slashes=s.test(x.href))}return I};var h=function h(x){return x==="file:"||x==="ftp:"||x==="http:"||x==="https:"||x==="ws:"||x==="wss:"};var _=function _(x,y){x=(x=l(x)).replace(o,""),y=y||{};var v,I=c.exec(x),b=I[1]?I[1].toLowerCase():"",w=!!I[2],k=!!I[3],C=0;return w?k?(v=I[2]+I[3]+I[4],C=I[2].length+I[3].length):(v=I[2]+I[4],C=I[2].length):k?(v=I[3]+I[4],C=I[3].length):v=I[4],b==="file:"?C>=2&&(v=v.slice(2)):h(b)?v=I[4]:b?w&&(v=v.slice(2)):C>=2&&h(y.protocol)&&(v=I[4]),{protocol:b,slashes:w||h(b),slashesCount:C,rest:v}};var r=a(670),i=a(647),n=/^[\x00-\x20\u00a0\u1680\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff]+/,o=/[\n\r\t]/g,s=/^[A-Za-z][A-Za-z0-9+-.]*:\/\//,u=/:\d+$/,c=/^([a-z][a-z0-9.+-]*:)?(\/\/)?([\\/]+)?([\S\s]*)/i,p=/^[a-zA-Z]:/;var m=[["#","hash"],["?","query"],function(x,y){return h(y.protocol)?x.replace(/\\/g,"/"):x},["/","pathname"],["@","auth",1],[NaN,"host",void 0,1,1],[/:(\d*)$/,"port",void 0,1],[NaN,"hostname",void 0,1,1]],f={hash:1,query:1};function A(x,y,v){if(x=(x=l(x)).replace(o,""),!_instanceof(this,A))return new A(x,y,v);var I,b,w,k,C,E,P=m.slice(),B=typeof y==="undefined"?"undefined":_type_of(y),M=this,R=0;for(B!=="object"&&B!=="string"&&(v=y,y=null),v&&typeof v!="function"&&(v=i.parse),I=!(b=_(x||"",y=g(y))).protocol&&!b.slashes,M.slashes=b.slashes||I&&y.slashes,M.protocol=b.protocol||y.protocol||"",x=b.rest,(b.protocol==="file:"&&(b.slashesCount!==2||p.test(x))||!b.slashes&&(b.protocol||b.slashesCount<2||!h(M.protocol)))&&(P[3]=[/(.*)/,"pathname"]);R1){var n=r.shift();r[0]=n+r[0]}r[0].match(/^file:\/\/\//)?r[0]=r[0].replace(/^([^/:]+):\/*/,"$1:///"):r[0]=r[0].replace(/^([^/:]+):\/*/,"$1://");for(var o=0;o0&&(s=s.replace(/^[\/]+/,"")),s=o0?"?":"")+c.join("&")}(_type_of(arguments[0])=="object"?arguments[0]:[].slice.call(arguments))}(t.reduce(function(r,i,n){return(n===0||i!=="/"||i==="/"&&r[r.length-1]!=="/")&&r.push(i),r},[]))}var CQt=Br(542),Pv=Br.n(CQt),EQt="abcdef0123456789";function dve(e,t){var a=e.url.replace("//",""),r=a.indexOf("/")==-1?"/":a.slice(a.indexOf("/")),i=e.method?e.method.toUpperCase():"GET",n=!!/(^|,)\s*auth\s*($|,)/.test(t.qop)&&"auth",o="00000000".concat(t.nc).slice(-8),s=function(m,f,g,h,_,A,x){var y=x||Pv()("".concat(f,":").concat(g,":").concat(h));return m&&m.toLowerCase()==="md5-sess"?Pv()("".concat(y,":").concat(_,":").concat(A)):y}(t.algorithm,t.username,t.realm,t.password,t.nonce,t.cnonce,t.ha1),u=Pv()("".concat(i,":").concat(r)),c=n?Pv()("".concat(s,":").concat(t.nonce,":").concat(o,":").concat(t.cnonce,":").concat(n,":").concat(u)):Pv()("".concat(s,":").concat(t.nonce,":").concat(u)),p={username:t.username,realm:t.realm,nonce:t.nonce,uri:r,qop:n,response:c,nc:o,cnonce:t.cnonce,algorithm:t.algorithm,opaque:t.opaque},l=[];for(var m in p)p[m]&&(m==="qop"||m==="nc"||m==="algorithm"?l.push("".concat(m,"=").concat(p[m])):l.push("".concat(m,'="').concat(p[m],'"')));return"Digest ".concat(l.join(", "))}function Sve(e){return(e.headers&&e.headers.get("www-authenticate")||"").split(/\s/)[0].toLowerCase()==="digest"}var SQt=Br(101),Bve=Br.n(SQt);function mve(e){return Bve().decode(e)}function fve(e,t){var a;return"Basic ".concat((a="".concat(e,":").concat(t),Bve().encode(a)))}var Ov=typeof WorkerGlobalScope!="undefined"&&_instanceof(self,WorkerGlobalScope)?self:typeof window!="undefined"?window:globalThis,BQt=Ov.fetch.bind(Ov),TQt=(Ov.Headers,Ov.Request),MQt=Ov.Response,Bo=function(e){return e.Auto="auto",e.Digest="digest",e.None="none",e.Password="password",e.Token="token",e}({}),Dp=function(e){return e.DataTypeNoLength="data-type-no-length",e.InvalidAuthType="invalid-auth-type",e.InvalidOutputFormat="invalid-output-format",e.LinkUnsupportedAuthType="link-unsupported-auth",e.InvalidUpdateRange="invalid-update-range",e.NotSupported="not-supported",e}({});function Tve(e,t,a,r,i){switch(e.authType){case Bo.Auto:t&&a&&(e.headers.Authorization=fve(t,a));break;case Bo.Digest:e.digest=function(o,s,u){return{username:o,password:s,ha1:u,nc:0,algorithm:"md5",hasDigestAuth:!1}}(t,a,i);break;case Bo.None:break;case Bo.Password:e.headers.Authorization=fve(t,a);break;case Bo.Token:e.headers.Authorization="".concat((n=r).token_type," ").concat(n.access_token);break;default:throw new Gn({info:{code:Dp.InvalidAuthType}},"Invalid auth type: ".concat(e.authType))}var n}Br(345),Br(800);var gve="@@HOTPATCHER",PQt=function(){};function NF(e){return{original:e,methods:[e],final:!1}}var zF=/*#__PURE__*/function(){function zF1(){_class_call_check(this,zF1);this._configuration={registry:{},getEmptyAction:"null"},this.__type__=gve}_create_class(zF1,[{key:"configuration",get:function get(){return this._configuration}},{key:"getEmptyAction",get:function get(){return this.configuration.getEmptyAction},set:function set(t){this.configuration.getEmptyAction=t}},{key:"control",value:function control(t){var _this=this;var a=arguments.length>1&&arguments[1]!==void 0&&arguments[1];if(!t||t.__type__!==gve)throw new Error("Failed taking control of target HotPatcher instance: Invalid type or object");return Object.keys(t.configuration.registry).forEach(function(r){_this.configuration.registry.hasOwnProperty(r)?a&&(_this.configuration.registry[r]=Object.assign({},t.configuration.registry[r])):_this.configuration.registry[r]=Object.assign({},t.configuration.registry[r])}),t._configuration=this.configuration,this}},{key:"execute",value:function execute(t){var a=this.get(t)||PQt;for(var r=arguments.length,i=new Array(r>1?r-1:0),n=1;n0;)c=[i.shift().apply(p,c)];return c[0]}}).apply(this,_to_consumable_array(a.methods))}},{key:"isPatched",value:function isPatched(t){return!!this.configuration.registry[t]}},{key:"patch",value:function patch(t,a){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},tmp=r.chain,i=tmp===void 0?!1:tmp;if(this.configuration.registry[t]&&this.configuration.registry[t].final)throw new Error("Failed patching '".concat(t,"': Method marked as being final"));if(typeof a!="function")throw new Error("Failed patching '".concat(t,"': Provided method is not a function"));if(i)this.configuration.registry[t]?this.configuration.registry[t].methods.push(a):this.configuration.registry[t]=NF(a);else if(this.isPatched(t)){var _this_configuration_registry_t=this.configuration.registry[t],n=_this_configuration_registry_t.original;this.configuration.registry[t]=Object.assign(NF(a),{original:n})}else this.configuration.registry[t]=NF(a);return this}},{key:"patchInline",value:function patchInline(t,a){this.isPatched(t)||this.patch(t,a);for(var r=arguments.length,i=new Array(r>2?r-2:0),n=2;n1?a-1:0),i=1;i0;){var n=i.shift();r=r?Pve(r,n):UI(n)}return r}function Pve(e,t){var a=UI(e);return Object.keys(t).forEach(function(r){a.hasOwnProperty(r)?Array.isArray(t[r])?a[r]=Array.isArray(a[r])?_to_consumable_array(a[r]).concat(_to_consumable_array(t[r])):_to_consumable_array(t[r]):_type_of(t[r])=="object"&&t[r]?a[r]=_type_of(a[r])=="object"&&a[r]?Pve(a[r],t[r]):UI(t[r]):a[r]=t[r]:a[r]=t[r]}),a}function RQt(e){var t={};var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=e.keys()[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var a=_step.value;t[a]=e.get(a)}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return t}function jF(){for(var e=arguments.length,t=new Array(e),a=0;a65536)throw new TypeError("pattern is too long")},FQt={"[:alnum:]":["\\p{L}\\p{Nl}\\p{Nd}",!0],"[:alpha:]":["\\p{L}\\p{Nl}",!0],"[:ascii:]":["\\x00-\\x7f",!1],"[:blank:]":["\\p{Zs}\\t",!0],"[:cntrl:]":["\\p{Cc}",!0],"[:digit:]":["\\p{Nd}",!0],"[:graph:]":["\\p{Z}\\p{C}",!0,!0],"[:lower:]":["\\p{Ll}",!0],"[:print:]":["\\p{C}",!0],"[:punct:]":["\\p{P}",!0],"[:space:]":["\\p{Z}\\t\\r\\n\\v\\f",!0],"[:upper:]":["\\p{Lu}",!0],"[:word:]":["\\p{L}\\p{Nl}\\p{Nd}\\p{Pc}",!0],"[:xdigit:]":["A-Fa-f0-9",!1]},Rv=function(e){return e.replace(/[[\]\\-]/g,"\\$&")},_ve=function(e){return e.join("")},qQt=function(e,t){var a=t;if(e.charAt(a)!=="[")throw new Error("not in a brace expression");var r=[],i=[],n=a+1,o=!1,s=!1,u=!1,c=!1,p=a,l="";e:for(;nl?r.push(Rv(l)+"-"+Rv(h)):h===l&&r.push(Rv(h)),l="",n++):e.startsWith("-]",n+1)?(r.push(Rv(h+"-")),n+=2):e.startsWith("-",n+1)?(l=h,n+=2):(r.push(Rv(h)),n++)}else u=!0,n++}else c=!0,n++}if(p1&&arguments[1]!==void 0?arguments[1]:{},tmp=_ref.windowsPathsNoEscape,t=tmp===void 0?!1:tmp;return t?e.replace(/\[([^\/\\])\]/g,"$1"):e.replace(/((?!\\).|^)\[([^\/\\])\]/g,"$1$2").replace(/\\([^\/])/g,"$1")},LQt=new Set(["!","?","+","*","@"]),xve=function(e){return LQt.has(e)},FF="(?!\\.)",$Qt=new Set(["[","."]),UQt=new Set(["..","."]),GQt=new Set("().*{}+?[]^$\\!"),ZF="[^/]",Ave=ZF+"*?",vve=ZF+"+?",nn,yn,Qp,ti,zi,b0,If,I0,Nc,kf,Fv,HI,Nve,Qh,LI,qv,WF,WI,Ove,ls=/*#__PURE__*/function(){function ls1(t,a){_class_call_check(this,ls1);fa(this,HI);fa(this,qv);S(this,"type");fa(this,nn,void 0);fa(this,yn,void 0);fa(this,Qp,!1);fa(this,ti,[]);fa(this,zi,void 0);fa(this,b0,void 0);fa(this,If,void 0);fa(this,I0,!1);fa(this,Nc,void 0);fa(this,kf,void 0);fa(this,Fv,!1);var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};this.type=t,t&&ea(this,yn,!0),ea(this,zi,a),ea(this,nn,he(this,zi)?he(he(this,zi),nn):this),ea(this,Nc,he(this,nn)===this?r:he(he(this,nn),Nc)),ea(this,If,he(this,nn)===this?[]:he(he(this,nn),If)),t!=="!"||he(he(this,nn),I0)||he(this,If).push(this),ea(this,b0,he(this,zi)?he(he(this,zi),ti).length:0)}_create_class(ls1,[{key:"hasMagic",get:function get(){if(he(this,yn)!==void 0)return he(this,yn);var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=he(this,ti)[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var t=_step.value;if(typeof t!="string"&&(t.type||t.hasMagic))return ea(this,yn,!0)}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return he(this,yn)}},{key:"toString",value:function toString(){return he(this,kf)!==void 0?he(this,kf):this.type?ea(this,kf,this.type+"("+he(this,ti).map(function(t){return String(t)}).join("|")+")"):ea(this,kf,he(this,ti).map(function(t){return String(t)}).join(""))}},{key:"push",value:function push(){for(var t=arguments.length,a=new Array(t),r=0;r1&&arguments[1]!==void 0?arguments[1]:{},r=new ls(null,void 0,a);return Ba(i=ls,Qh,LI).call(i,t,r,0,a),r}}]);return ls1}(),Mh=ls;nn=new WeakMap,yn=new WeakMap,Qp=new WeakMap,ti=new WeakMap,zi=new WeakMap,b0=new WeakMap,If=new WeakMap,I0=new WeakMap,Nc=new WeakMap,kf=new WeakMap,Fv=new WeakMap,HI=new WeakSet,Nve=function Nve1(){if(this!==he(this,nn))throw new Error("should only call on root");if(he(this,I0))return this;var t;for(this.toString(),ea(this,I0,!0);t=he(this,If).pop();){if(t.type!=="!")continue;var a=t,r=he(a,zi);for(;r;){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;for(var i=he(a,b0)+1;!r.type&&i2&&arguments[2]!==void 0&&arguments[2],i=!1,n="",o=!1;for(var s=0;s2&&arguments[2]!==void 0?arguments[2]:{};return zI(t),!(!a.nocomment&&t.charAt(0)==="#")&&new Dh(t,a).match(e)},zQt=/^\*+([^+@!?\*\[\(]*)$/,jQt=function(e){return function(t){return!t.startsWith(".")&&t.endsWith(e)}},HQt=function(e){return function(t){return t.endsWith(e)}},WQt=function(e){return e=e.toLowerCase(),function(t){return!t.startsWith(".")&&t.toLowerCase().endsWith(e)}},VQt=function(e){return e=e.toLowerCase(),function(t){return t.toLowerCase().endsWith(e)}},KQt=/^\*+\.\*+$/,JQt=function(e){return!e.startsWith(".")&&e.includes(".")},ZQt=function(e){return e!=="."&&e!==".."&&e.includes(".")},YQt=/^\.\*+$/,XQt=function(e){return e!=="."&&e!==".."&&e.startsWith(".")},eDt=/^\*+$/,tDt=function(e){return e.length!==0&&!e.startsWith(".")},aDt=function(e){return e.length!==0&&e!=="."&&e!==".."},rDt=/^\?+([^+@!?\*\[\(]*)?$/,iDt=function(e){var _e=_sliced_to_array(e,2),t=_e[0],tmp=_e[1],a=tmp===void 0?"":tmp,r=Fve([t]);return a?(a=a.toLowerCase(),function(i){return r(i)&&i.toLowerCase().endsWith(a)}):r},nDt=function(e){var _e=_sliced_to_array(e,2),t=_e[0],tmp=_e[1],a=tmp===void 0?"":tmp,r=qve([t]);return a?(a=a.toLowerCase(),function(i){return r(i)&&i.toLowerCase().endsWith(a)}):r},oDt=function(e){var _e=_sliced_to_array(e,2),t=_e[0],tmp=_e[1],a=tmp===void 0?"":tmp,r=qve([t]);return a?function(i){return r(i)&&i.endsWith(a)}:r},sDt=function(e){var _e=_sliced_to_array(e,2),t=_e[0],tmp=_e[1],a=tmp===void 0?"":tmp,r=Fve([t]);return a?function(i){return r(i)&&i.endsWith(a)}:r},Fve=function(e){var _e=_sliced_to_array(e,1),t=_e[0],a=t.length;return function(r){return r.length===a&&!r.startsWith(".")}},qve=function(e){var _e=_sliced_to_array(e,1),t=_e[0],a=t.length;return function(r){return r.length===a&&r!=="."&&r!==".."}},Lve=(typeof process==="undefined"?"undefined":_type_of(process))=="object"&&process?_type_of(process.env)=="object"&&process.env&&process.env.__MINIMATCH_TESTING_PLATFORM__||process.platform:"posix";io.sep=Lve==="win32"?"\\":"/";var Mu=Symbol("globstar **");io.GLOBSTAR=Mu,io.filter=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return function(a){return io(a,e,t)}};var Tu=function Tu1(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return Object.assign({},e,t)};io.defaults=function(e){if(!e||(typeof e==="undefined"?"undefined":_type_of(e))!="object"||!Object.keys(e).length)return io;var t=io;return Object.assign(function(a,r){return t(a,r,Tu(e,arguments.length>2&&arguments[2]!==void 0?arguments[2]:{}))},{Minimatch:/*#__PURE__*/function(_t_Minimatch){_inherits(Minimatch,_t_Minimatch);function Minimatch(a){_class_call_check(this,Minimatch);return _call_super(this,Minimatch,[a,Tu(e,arguments.length>1&&arguments[1]!==void 0?arguments[1]:{})])}_create_class(Minimatch,null,[{key:"defaults",value:function defaults(a){return t.defaults(Tu(e,a)).Minimatch}}]);return Minimatch}(t.Minimatch),AST:/*#__PURE__*/function(_t_AST){_inherits(AST,_t_AST);function AST(a,r){_class_call_check(this,AST);return _call_super(this,AST,[a,r,Tu(e,arguments.length>2&&arguments[2]!==void 0?arguments[2]:{})])}_create_class(AST,null,[{key:"fromGlob",value:function fromGlob(a){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return t.AST.fromGlob(a,Tu(e,r))}}]);return AST}(t.AST),unescape:function unescape1(a){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return t.unescape(a,Tu(e,r))},escape:function escape1(a){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return t.escape(a,Tu(e,r))},filter:function filter(a){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return t.filter(a,Tu(e,r))},defaults:function(a){return t.defaults(Tu(e,a))},makeRe:function makeRe(a){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return t.makeRe(a,Tu(e,r))},braceExpand:function braceExpand(a){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return t.braceExpand(a,Tu(e,r))},match:function match(a,r){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return t.match(a,r,Tu(e,i))},sep:t.sep,GLOBSTAR:Mu})};var $ve=function $ve1(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return zI(e),t.nobrace||!/\{(?:(?!\{).)*\}/.test(e)?[e]:OQt(e)};io.braceExpand=$ve,io.makeRe=function(e){return new Dh(e,arguments.length>1&&arguments[1]!==void 0?arguments[1]:{}).makeRe()},io.match=function(e,t){var a=new Dh(t,arguments.length>2&&arguments[2]!==void 0?arguments[2]:{});return e=e.filter(function(r){return a.match(r)}),a.options.nonull&&!e.length&&e.push(t),e};var yve=/[?*]|[+@!]\(.*?\)|\[|\]/,Dh=/*#__PURE__*/function(){function Dh1(t){_class_call_check(this,Dh1);S(this,"options");S(this,"set");S(this,"pattern");S(this,"windowsPathsNoEscape");S(this,"nonegate");S(this,"negate");S(this,"comment");S(this,"empty");S(this,"preserveMultipleSlashes");S(this,"partial");S(this,"globSet");S(this,"globParts");S(this,"nocase");S(this,"isWindows");S(this,"platform");S(this,"windowsNoMagicRoot");S(this,"regexp");var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};zI(t),a=a||{},this.options=a,this.pattern=t,this.platform=a.platform||Lve,this.isWindows=this.platform==="win32",this.windowsPathsNoEscape=!!a.windowsPathsNoEscape||a.allowWindowsEscape===!1,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.preserveMultipleSlashes=!!a.preserveMultipleSlashes,this.regexp=null,this.negate=!1,this.nonegate=!!a.nonegate,this.comment=!1,this.empty=!1,this.partial=!!a.partial,this.nocase=!!this.options.nocase,this.windowsNoMagicRoot=a.windowsNoMagicRoot!==void 0?a.windowsNoMagicRoot:!(!this.isWindows||!this.nocase),this.globSet=[],this.globParts=[],this.set=[],this.make()}_create_class(Dh1,[{key:"hasMagic",value:function hasMagic(){if(this.options.magicalBraces&&this.set.length>1)return!0;var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined,_iteratorNormalCompletion1=true,_didIteratorError1=false,_iteratorError1=undefined;try{for(var _iterator=this.set[Symbol.iterator](),_step;!(_iteratorNormalCompletion1=(_step=_iterator.next()).done);_iteratorNormalCompletion1=true){var t=_step.value;try{for(var _iterator1=t[Symbol.iterator](),_step1;!(_iteratorNormalCompletion=(_step1=_iterator1.next()).done);_iteratorNormalCompletion=true){var a=_step1.value;if(typeof a!="string")return!0}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator1.return!=null){_iterator1.return()}}finally{if(_didIteratorError){throw _iteratorError}}}}}catch(err){_didIteratorError1=true;_iteratorError1=err}finally{try{if(!_iteratorNormalCompletion1&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError1){throw _iteratorError1}}}return!1}},{key:"debug",value:function debug(){}},{key:"make",value:function make(){var _this=this;var t=this.pattern,a=this.options;if(!a.nocomment&&t.charAt(0)==="#")return void(this.comment=!0);if(!t)return void(this.empty=!0);this.parseNegate(),this.globSet=_to_consumable_array(new Set(this.braceExpand())),a.debug&&(this.debug=function(){var _console;return(_console=console).error.apply(_console,arguments)}),this.debug(this.pattern,this.globSet);var r=this.globSet.map(function(n){return _this.slashSplit(n)});this.globParts=this.preprocess(r),this.debug(this.pattern,this.globParts);var i=this.globParts.map(function(n,o,s){if(_this.isWindows&&_this.windowsNoMagicRoot){var u=!(n[0]!==""||n[1]!==""||n[2]!=="?"&&yve.test(n[2])||yve.test(n[3])),c=/^[a-z]:/i.test(n[0]);if(u)return _to_consumable_array(n.slice(0,4)).concat(_to_consumable_array(n.slice(4).map(function(p){return _this.parse(p)})));if(c)return[n[0]].concat(_to_consumable_array(n.slice(1).map(function(p){return _this.parse(p)})))}return n.map(function(u){return _this.parse(u)})});if(this.debug(this.pattern,i),this.set=i.filter(function(n){return n.indexOf(!1)===-1}),this.isWindows)for(var n=0;n=2?(t=this.firstPhasePreProcess(t),t=this.secondPhasePreProcess(t)):t=a>=1?this.levelOneOptimize(t):this.adjascentGlobstarOptimize(t),t}},{key:"adjascentGlobstarOptimize",value:function adjascentGlobstarOptimize(t){return t.map(function(a){var r=-1;for(;(r=a.indexOf("**",r+1))!==-1;){var i=r;for(;a[i+1]==="**";)i++;i!==r&&a.splice(r,i-r)}return a})}},{key:"levelOneOptimize",value:function levelOneOptimize(t){return t.map(function(a){return(a=a.reduce(function(r,i){var n=r[r.length-1];return i==="**"&&n==="**"?r:i===".."&&n&&n!==".."&&n!=="."&&n!=="**"?(r.pop(),r):(r.push(i),r)},[])).length===0?[""]:a})}},{key:"levelTwoFileOptimize",value:function levelTwoFileOptimize(t){Array.isArray(t)||(t=this.slashSplit(t));var a=!1;do{if(a=!1,!this.preserveMultipleSlashes){for(var i=1;ii&&r.splice(i+1,o-i);var s=r[i+1],u=r[i+2],c=r[i+3];if(s!==".."||!u||u==="."||u===".."||!c||c==="."||c==="..")continue;a=!0,r.splice(i,1);var p=r.slice(0);p[i]="**",t.push(p),i--}if(!this.preserveMultipleSlashes){for(var o10=1;o102&&arguments[2]!==void 0&&arguments[2],i=0,n=0,o=[],s="";for(;i2&&arguments[2]!==void 0&&arguments[2],i=this.options;if(this.isWindows){var h=typeof t[0]=="string"&&/^[a-z]:$/i.test(t[0]),_=!h&&t[0]===""&&t[1]===""&&t[2]==="?"&&/^[a-z]:$/i.test(t[3]),A=typeof a[0]=="string"&&/^[a-z]:$/i.test(a[0]),x=_?3:h?0:void 0,y=!A&&a[0]===""&&a[1]===""&&a[2]==="?"&&typeof a[3]=="string"&&/^[a-z]:$/i.test(a[3])?3:A?0:void 0;if(typeof x=="number"&&typeof y=="number"){var _ref=[t[x],a[y]],v=_ref[0],I=_ref[1];v.toLowerCase()===I.toLowerCase()&&(a[y]=v,y>x?a=a.slice(y):x>y&&(t=t.slice(x)))}}var _this_options=this.options,tmp=_this_options.optimizationLevel,n=tmp===void 0?1:tmp;n>=2&&(t=this.levelTwoFileOptimize(t)),this.debug("matchOne",this,{file:t,pattern:a}),this.debug("matchOne",t.length,a.length);for(var o=0,s=0,u=t.length,c=a.length;o>> no match, partial?",t,m,a,f),m!==u))}var h10=void 0;if(typeof p=="string"?(h10=l===p,this.debug("string match",p,l,h10)):(h10=p.test(l),this.debug("pattern match",p,l,h10)),!h10)return!1}if(o===u&&s===c)return!0;if(o===u)return r;if(s===c)return o===u-1&&t[o]==="";throw new Error("wtf?")}},{key:"braceExpand",value:function braceExpand(){return $ve(this.pattern,this.options)}},{key:"parse",value:function parse(t){zI(t);var a=this.options;if(t==="**")return Mu;if(t==="")return"";var r,i=null;(r=t.match(eDt))?i=a.dot?aDt:tDt:(r=t.match(zQt))?i=(a.nocase?a.dot?VQt:WQt:a.dot?HQt:jQt)(r[1]):(r=t.match(rDt))?i=(a.nocase?a.dot?nDt:iDt:a.dot?oDt:sDt)(r):(r=t.match(KQt))?i=a.dot?ZQt:JQt:(r=t.match(YQt))&&(i=XQt);var n=Mh.fromGlob(t,this.options).toMMPattern();return i&&(typeof n==="undefined"?"undefined":_type_of(n))=="object"&&Reflect.defineProperty(n,"test",{value:i}),n}},{key:"makeRe",value:function makeRe(){if(this.regexp||this.regexp===!1)return this.regexp;var t=this.set;if(!t.length)return this.regexp=!1,this.regexp;var a=this.options,r=a.noglobstar?"[^/]*?":a.dot?"(?:(?!(?:\\/|^)(?:\\.{1,2})($|\\/)).)*?":"(?:(?!(?:\\/|^)\\.).)*?",i=new Set(a.nocase?["i"]:[]),n=t.map(function(u){var c=u.map(function(p){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;if(_instanceof(p,RegExp))try{for(var _iterator=p.flags.split("")[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var l=_step.value;i.add(l)}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return typeof p=="string"?p.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"):p===Mu?Mu:p._src});return c.forEach(function(p,l){var m=c[l+1],f=c[l-1];p===Mu&&f!==Mu&&(f===void 0?m!==void 0&&m!==Mu?c[l+1]="(?:\\/|"+r+"\\/)?"+m:c[l]=r:m===void 0?c[l-1]=f+"(?:\\/|"+r+")?":m!==Mu&&(c[l-1]=f+"(?:\\/|\\/"+r+"\\/)"+m,c[l+1]=Mu))}),c.filter(function(p){return p!==Mu}).join("/")}).join("|"),_ref=_sliced_to_array(t.length>1?["(?:",")"]:["",""],2),o=_ref[0],s=_ref[1];n="^"+o+n+s+"$",this.negate&&(n="^(?!"+n+").+$");try{this.regexp=new RegExp(n,_to_consumable_array(i).join(""))}catch(u){this.regexp=!1}return this.regexp}},{key:"slashSplit",value:function slashSplit(t){return this.preserveMultipleSlashes?t.split("/"):this.isWindows&&/^\/\/[^\/]+/.test(t)?[""].concat(_to_consumable_array(t.split(/\/+/))):t.split(/\/+/)}},{key:"match",value:function match(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.partial;if(this.debug("match",t,this.pattern),this.comment)return!1;if(this.empty)return t==="";if(t==="/"&&a)return!0;var r=this.options;this.isWindows&&(t=t.split("\\").join("/"));var i=this.slashSplit(t);this.debug(this.pattern,"split",i);var n=this.set;this.debug(this.pattern,"set",n);var o=i[i.length-1];if(!o)for(var s=i.length-2;!o&&s>=0;s--)o=i[s];for(var s6=0;s61&&arguments[1]!==void 0?arguments[1]:"","Invalid response: ").concat(e.status," ").concat(e.statusText));return t.status=e.status,t.response=e,t}function un(e,t){var a=t.status;if(a===401&&e.digest)return t;if(a>=400)throw YF(t);return t}function Cf(e,t){return arguments.length>2&&arguments[2]!==void 0&&arguments[2]?{data:t,headers:e.headers?RQt(e.headers):{},status:e.status,statusText:e.statusText}:t}io.AST=Mh,io.Minimatch=Dh,io.escape=function(e){var _ref=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},tmp=_ref.windowsPathsNoEscape,t=tmp===void 0?!1:tmp;return t?e.replace(/[?*()[\]]/g,"[$&]"):e.replace(/[?*()[\]\\]/g,"\\$&")},io.unescape=Qv;var uDt=(wve=function wve1(e,t,a){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},i=sn({url:di(e.remoteURL,pi(t)),method:"COPY",headers:{Destination:di(e.remoteURL,pi(a)),Overwrite:r.overwrite===!1?"F":"T",Depth:r.shallow?"0":"infinity"}},e,r);return o=function o(s){un(e,s)},(n=on(i,e))&&n.then||(n=Promise.resolve(n)),o?n.then(o):n;var n,o},function uDt1(){for(var e=[],t=0;t2&&arguments[2]!==void 0?arguments[2]:Ph.Original,r=Rp().get(e,t);return a==="array"&&Array.isArray(r)===!1?[r]:a==="object"&&Array.isArray(r)?r[0]:r}function Lv(e){return new Promise(function(t){t(function(a){var r=a.multistatus;if(r==="")return{multistatus:{response:[]}};if(!r)throw new Error("Invalid response: No root multistatus found");var i={multistatus:Array.isArray(r)?r[0]:r};return Rp().set(i,"multistatus.response",qI(i,"multistatus.response",Ph.Array)),Rp().set(i,"multistatus.response",Rp().get(i,"multistatus.response").map(function(n){return function(o){var s=Object.assign({},o);return s.status?Rp().set(s,"status",qI(s,"status",Ph.Object)):(Rp().set(s,"propstat",qI(s,"propstat",Ph.Object)),Rp().set(s,"propstat.prop",qI(s,"propstat.prop",Ph.Object))),s}(n)})),i}(new XF.XMLParser({allowBooleanAttributes:!0,attributeNamePrefix:"",textNodeName:"text",ignoreAttributes:!1,removeNSPrefix:!0,numberParseOptions:{hex:!0,leadingZeros:!1},attributeValueProcessor:function(a,r,i){return r==="true"||r==="false"?r==="true":r},tagValueProcessor:function tagValueProcessor(a,r,i){if(!i.endsWith("propstat.prop.displayname"))return r}}).parse(e)))})}function VI(e,t){var a=arguments.length>2&&arguments[2]!==void 0&&arguments[2],tmp=e.getlastmodified,r=tmp===void 0?null:tmp,tmp1=e.getcontentlength,i=tmp1===void 0?"0":tmp1,tmp2=e.resourcetype,n=tmp2===void 0?null:tmp2,tmp3=e.getcontenttype,o=tmp3===void 0?null:tmp3,tmp4=e.getetag,s=tmp4===void 0?null:tmp4,u=n&&(typeof n==="undefined"?"undefined":_type_of(n))=="object"&&n.collection!==void 0?"directory":"file",c={filename:t,basename:$I().basename(t),lastmod:r,size:parseInt(i,10),type:u,etag:typeof s=="string"?s.replace(/"/g,""):null};return u==="file"&&(c.mime=o&&typeof o=="string"?o.split(";")[0]:""),a&&(e.displayname!==void 0&&(e.displayname=String(e.displayname)),c.props=e),c}function Uve(e,t){var a=arguments.length>2&&arguments[2]!==void 0&&arguments[2],r=null;try{e.multistatus.response[0].propstat&&(r=e.multistatus.response[0])}catch(p){}if(!r)throw new Error("Failed getting item stat: bad response");var _r_propstat=r.propstat,i=_r_propstat.prop,n=_r_propstat.status,_n_split=_sliced_to_array(n.split(" ",3),3),o=_n_split[0],s=_n_split[1],u=_n_split[2],c=parseInt(s,10);if(c>=400){var p=new Error("Invalid response: ".concat(c," ").concat(u));throw p.status=c,p}return VI(i,Nv(t),a)}function Gve(e){switch(String(e)){case"-3":return"unlimited";case"-2":case"-1":return"unknown";default:return parseInt(String(e),10)}}function qF(e,t,a){return a?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}var eq=function(e){return function(){for(var t=[],a=0;a2&&arguments[2]!==void 0?arguments[2]:{},tmp=a.details,r=tmp===void 0?!1:tmp,i=sn({url:di(e.remoteURL,pi(t)),method:"PROPFIND",headers:{Accept:"text/plain,application/xml",Depth:"0"}},e,a);return qF(on(i,e),function(n){return un(e,n),qF(n.text(),function(o){return qF(Lv(o),function(s){var u=Uve(s,t,r);return Cf(n,u,r)})})})});function zve(e,t,a){return a?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}var cDt=jve(function(e,t){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=function(n){if(!n||n==="/")return[];var o=n,s=[];do s.push(o),o=$I().dirname(o);while(o&&o!=="/");return s}(Nv(t));r.sort(function(n,o){return n.length>o.length?1:o.length>n.length?-1:0});var i=!1;return function(n,o,s){if(typeof n[Ive]=="function"){var h=function h10(_){try{for(;!(u=l.next()).done;)if((_=o(u.value))&&_.then){if(!kve(_))return void _.then(h,p||(p=To.bind(null,c=new Rh,2)));_=_.v}c?To(c,1,_):c=_}catch(A){To(c||(c=new Rh),2,A)}};var u,c,p,l=n[Ive]();if(h(),l.return){var m=function m(_){try{u.done||l.return()}catch(A){}return _};if(c&&c.then)return c.then(m,function(_){throw m(_)});m()}return c}if(!("length"in n))throw new TypeError("Object is not iterable");for(var f=[],g=0;g2&&arguments[2]!==void 0?arguments[2]:{};if(a.recursive===!0)return cDt(e,t,a);var r=sn({url:di(e.remoteURL,(i=pi(t),i.endsWith("/")?i:i+"/")),method:"MKCOL"},e,a);var i;return zve(on(r,e),function(n){un(e,n)})}),dDt=Br(388),Cve=Br.n(dDt),mDt=function(e){return function(){for(var t=[],a=0;a2&&arguments[2]!==void 0?arguments[2]:{},r={};if(_type_of(a.range)=="object"&&typeof a.range.start=="number"){var s="bytes=".concat(a.range.start,"-");typeof a.range.end=="number"&&(s="".concat(s).concat(a.range.end)),r.Range=s}var i=sn({url:di(e.remoteURL,pi(t)),method:"GET",headers:r},e,a);return o=function o(s){if(un(e,s),r.Range&&s.status!==206){var u=new Error("Invalid response code for partial request: ".concat(s.status));throw u.status=s.status,u}return a.callback&&setTimeout(function(){a.callback(s)},0),s.body},(n=on(i,e))&&n.then||(n=Promise.resolve(n)),o?n.then(o):n;var n,o}),fDt=function(){},gDt=function(e){return function(){for(var t=[],a=0;a2&&arguments[2]!==void 0?arguments[2]:{},r=sn({url:di(e.remoteURL,pi(t)),method:"DELETE"},e,a);return n=function n(o){un(e,o)},(i=on(r,e))&&i.then||(i=Promise.resolve(i)),n?i.then(n):i;var i,n}),_Dt=function(e){return function(){for(var t=[],a=0;a2&&arguments[2]!==void 0?arguments[2]:{};return function(r,i){try{var n=(o=eq(e,t,a),s=function s(){return!0},u?s?s(o):o:(o&&o.then||(o=Promise.resolve(o)),s?o.then(s):o))}catch(c){return i(c)}var o,s,u;return n&&n.then?n.then(void 0,i):n}(0,function(r){if(r.status===404)return!1;throw r})});function LF(e,t,a){return a?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}var xDt=function(e){return function(){for(var t=[],a=0;a2&&arguments[2]!==void 0?arguments[2]:{},r=sn({url:di(e.remoteURL,pi(t),"/"),method:"PROPFIND",headers:{Accept:"text/plain,application/xml",Depth:a.deep?"infinity":"1"}},e,a);return LF(on(r,e),function(i){return un(e,i),LF(i.text(),function(n){if(!n)throw new Error("Failed parsing directory contents: Empty response");return LF(Lv(n),function(o){var s=pve(t),u=function(c,p,l){var m=arguments.length>3&&arguments[3]!==void 0&&arguments[3],f=arguments.length>4&&arguments[4]!==void 0&&arguments[4],g=$I().join(p,"/"),_c_multistatus=c.multistatus,h=_c_multistatus.response,_=h.map(function(A){var x=function(v){try{return v.replace(/^https?:\/\/[^\/]+/,"")}catch(I){throw new Gn(I,"Failed normalising HREF")}}(A.href),_A_propstat=A.propstat,y=_A_propstat.prop;return VI(y,g==="/"?decodeURIComponent(Nv(x)):Nv($I().relative(decodeURIComponent(g),decodeURIComponent(x))),m)});return f?_:_.filter(function(A){return A.basename&&(A.type==="file"||A.filename!==l.replace(/\/$/,""))})}(o,pve(e.remoteBasePath||e.remotePath),s,a.details,a.includeSelf);return a.glob&&(u=function(c,p){return c.filter(function(l){return io(l.filename,p,{matchBase:!0})})}(u,a.glob)),Cf(i,u,a.details)})})})});function tq(e){return function(){for(var t=[],a=0;a2&&arguments[2]!==void 0?arguments[2]:{},r=sn({url:di(e.remoteURL,pi(t)),method:"GET",headers:{Accept:"text/plain"},transformResponse:[wDt]},e,a);return jI(on(r,e),function(i){return un(e,i),jI(i.text(),function(n){return Cf(i,n,a.details)})})});function jI(e,t,a){return a?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}var vDt=tq(function(e,t){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=sn({url:di(e.remoteURL,pi(t)),method:"GET"},e,a);return jI(on(r,e),function(i){var n;return un(e,i),function(o,s){var u=o();return u&&u.then?u.then(s):s()}(function(){return jI(i.arrayBuffer(),function(o){n=o})},function(){return Cf(i,n,a.details)})})}),yDt=tq(function(e,t){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},tmp=a.format,r=tmp===void 0?"binary":tmp;if(r!=="binary"&&r!=="text")throw new Gn({info:{code:Dp.InvalidOutputFormat}},"Invalid output format: ".concat(r));return r==="text"?ADt(e,t,a):vDt(e,t,a)}),wDt=function(e){return e};function bDt(e){return new XF.XMLBuilder({attributeNamePrefix:"@_",format:!0,ignoreAttributes:!1,suppressEmptyNode:!0}).build(Hve({lockinfo:{"@_xmlns:d":"DAV:",lockscope:{exclusive:{}},locktype:{write:{}},owner:{href:e}}},"d"))}function Hve(e,t){var a=_object_spread({},e);for(var r in a)a.hasOwnProperty(r)&&(a[r]&&_type_of(a[r])=="object"&&r.indexOf(":")===-1?(a["".concat(t,":").concat(r)]=Hve(a[r],t),delete a[r]):/^@_/.test(r)===!1&&(a["".concat(t,":").concat(r)]=a[r],delete a[r]));return a}function KF(e,t,a){return a?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}function Wve(e){return function(){for(var t=[],a=0;a3&&arguments[3]!==void 0?arguments[3]:{},i=sn({url:di(e.remoteURL,pi(t)),method:"UNLOCK",headers:{"Lock-Token":a}},e,r);return KF(on(i,e),function(n){if(un(e,n),n.status!==204&&n.status!==200)throw YF(n)})}),kDt=Wve(function(e,t){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=a.refreshToken,tmp=a.timeout,i=tmp===void 0?CDt:tmp,n={Accept:"text/plain,application/xml",Timeout:i};r&&(n.If=r);var o=sn({url:di(e.remoteURL,pi(t)),method:"LOCK",headers:n,data:bDt(e.contactHref)},e,a);return KF(on(o,e),function(s){return un(e,s),KF(s.text(),function(u){var c=(m=u,new XF.XMLParser({removeNSPrefix:!0,parseAttributeValue:!0,parseTagValue:!0}).parse(m)),p=Rp().get(c,"prop.lockdiscovery.activelock.locktoken.href"),l=Rp().get(c,"prop.lockdiscovery.activelock.timeout");var m;if(!p)throw YF(s,"No lock token received: ");return{token:p,serverTimeout:l}})})}),CDt="Infinite, Second-4100000000";function $F(e,t,a){return a?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}var EDt=function(e){return function(){for(var t=[],a=0;a1&&arguments[1]!==void 0?arguments[1]:{},a=t.path||"/",r=sn({url:di(e.remoteURL,a),method:"PROPFIND",headers:{Accept:"text/plain,application/xml",Depth:"0"}},e,t);return $F(on(r,e),function(i){return un(e,i),$F(i.text(),function(n){return $F(Lv(n),function(o){var s=function(u){try{var _u_multistatus_response=_sliced_to_array(u.multistatus.response,1),c=_u_multistatus_response[0],_c_propstat=c.propstat,_c_propstat_prop=_c_propstat.prop,p=_c_propstat_prop["quota-used-bytes"],l=_c_propstat_prop["quota-available-bytes"];return p!==void 0&&l!==void 0?{used:parseInt(String(p),10),available:Gve(l)}:null}catch(c){}return null}(o);return Cf(i,s,t.details)})})})});function UF(e,t,a){return a?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}var SDt=function(e){return function(){for(var t=[],a=0;a2&&arguments[2]!==void 0?arguments[2]:{},tmp=a.details,r=tmp===void 0?!1:tmp,i=sn({url:di(e.remoteURL,pi(t)),method:"SEARCH",headers:{Accept:"text/plain,application/xml","Content-Type":e.headers["Content-Type"]||"application/xml; charset=utf-8"}},e,a);return UF(on(i,e),function(n){return un(e,n),UF(n.text(),function(o){return UF(Lv(o),function(s){var u=function(c,p,l){var m={truncated:!1,results:[]};return m.truncated=c.multistatus.response.some(function(f){var g,h;return((h=(f.status||((g=f.propstat)==null?void 0:g.status)).split(" ",3))==null?void 0:h[1])==="507"&&f.href.replace(/\/$/,"").endsWith(pi(p).replace(/\/$/,""))}),c.multistatus.response.forEach(function(f){if(f.propstat===void 0)return;var g=f.href.split("/").map(decodeURIComponent).join("/");m.results.push(VI(f.propstat.prop,g,l))}),m}(s,t,r);return Cf(n,u,r)})})})}),BDt=function(e){return function(){for(var t=[],a=0;a3&&arguments[3]!==void 0?arguments[3]:{},i=sn({url:di(e.remoteURL,pi(t)),method:"MOVE",headers:{Destination:di(e.remoteURL,pi(a)),Overwrite:r.overwrite===!1?"F":"T"}},e,r);return o=function o(s){un(e,s)},(n=on(i,e))&&n.then||(n=Promise.resolve(n)),o?n.then(o):n;var n,o}),TDt=Br(172),MDt=function(e){return function(){for(var t=[],a=0;a3&&arguments[3]!==void 0?arguments[3]:{},tmp=r.contentLength,i=tmp===void 0?!0:tmp,tmp1=r.overwrite,n=tmp1===void 0?!0:tmp1,o={"Content-Type":"application/octet-stream"};i===!1||(o["Content-Length"]=typeof i=="number"?"".concat(i):"".concat(function(p){if(Rve(p))return p.byteLength;if(Qve(p))return p.length;if(typeof p=="string")return(0,TDt.d)(p);throw new Gn({info:{code:Dp.DataTypeNoLength}},"Cannot calculate data length: Invalid type")}(a))),n||(o["If-None-Match"]="*");var s=sn({url:di(e.remoteURL,pi(t)),method:"PUT",headers:o,data:a},e,r);return c=function c(p){try{un(e,p)}catch(l){var m=l;if(m.status!==412||n)throw m;return!1}return!0},(u=on(s,e))&&u.then||(u=Promise.resolve(u)),c?u.then(c):u;var u,c}),Vve=function(e){return function(){for(var t=[],a=0;a2&&arguments[2]!==void 0?arguments[2]:{},r=sn({url:di(e.remoteURL,pi(t)),method:"OPTIONS"},e,a);return n=function n(o){var s,u;try{un(e,o)}catch(c){throw c}return{compliance:((s=o.headers.get("DAV"))!=null?s:"").split(",").map(function(c){return c.trim()}),server:(u=o.headers.get("Server"))!=null?u:""}},(i=on(r,e))&&i.then||(i=Promise.resolve(i)),n?i.then(n):i;var i,n});function Dv(e,t,a){return a?t?t(e):e:(e&&e.then||(e=Promise.resolve(e)),t?e.then(t):e)}var PDt=aq(function(e,t,a,r,i){var n=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{};if(a>r||a<0)throw new Gn({info:{code:Dp.InvalidUpdateRange}},"Invalid update range ".concat(a," for partial update"));var o={"Content-Type":"application/octet-stream","Content-Length":""+(r-a+1),"Content-Range":"bytes ".concat(a,"-").concat(r,"/*")},s=sn({url:di(e.remoteURL,pi(t)),method:"PUT",headers:o,data:i},e,n);return Dv(on(s,e),function(u){un(e,u)})});function Eve(e,t){var a=e();return a&&a.then?a.then(t):t(a)}var RDt=aq(function(e,t,a,r,i){var n=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{};if(a>r||a<0)throw new Gn({info:{code:Dp.InvalidUpdateRange}},"Invalid update range ".concat(a," for partial update"));var o={"Content-Type":"application/x-sabredav-partialupdate","Content-Length":""+(r-a+1),"X-Update-Range":"bytes=".concat(a,"-").concat(r)},s=sn({url:di(e.remoteURL,pi(t)),method:"PATCH",headers:o,data:i},e,n);return Dv(on(s,e),function(u){un(e,u)})});function aq(e){return function(){for(var t=[],a=0;a5&&arguments[5]!==void 0?arguments[5]:{};return Dv(Vve(e,t,n),function(o){var s=!1;return Eve(function(){if(o.compliance.includes("sabredav-partialupdate"))return Dv(RDt(e,t,a,r,i,n),function(u){return s=!0,u})},function(u){var c=!1;return s?u:Eve(function(){if(o.server.includes("Apache")&&o.compliance.includes(""))return Dv(PDt(e,t,a,r,i,n),function(p){return c=!0,p})},function(p){if(c)return p;throw new Gn({info:{code:Dp.NotSupported}},"Not supported")})})})}),DDt="https://github.com/perry-mitchell/webdav-client/blob/master/LOCK_CONTACT.md";function NDt(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},tmp=t.authType,a=tmp===void 0?null:tmp,r=t.remoteBasePath,tmp1=t.contactHref,i=tmp1===void 0?DDt:tmp1,n=t.ha1,tmp2=t.headers,o=tmp2===void 0?{}:tmp2,s=t.httpAgent,u=t.httpsAgent,c=t.password,p=t.token,l=t.username,m=t.withCredentials,f=a;f||(f=l||c?Bo.Password:Bo.None);var g={authType:f,remoteBasePath:r,contactHref:i,ha1:n,headers:Object.assign({},o),httpAgent:s,httpsAgent:u,password:c,remotePath:kQt(e),remoteURL:e,token:p,username:l,withCredentials:m};return Tve(g,l,c,p,n),{copyFile:function(h,_,A){return uDt(g,h,_,A)},createDirectory:function(h,_){return VF(g,h,_)},createReadStream:function(h,_){return function(A,x){var y=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},v=new(Cve()).PassThrough;return mDt(A,x,y).then(function(I){I.pipe(v)}).catch(function(I){v.emit("error",I)}),v}(g,h,_)},createWriteStream:function(h,_,A){return function(x,y){var v=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},I=arguments.length>3&&arguments[3]!==void 0?arguments[3]:fDt,b=new(Cve()).PassThrough,w={};v.overwrite===!1&&(w["If-None-Match"]="*");var k=sn({url:di(x.remoteURL,pi(y)),method:"PUT",headers:w,data:b,maxRedirects:0},x,v);return on(k,x).then(function(C){return un(x,C)}).then(function(C){setTimeout(function(){I(C)},0)}).catch(function(C){b.emit("error",C)}),b}(g,h,_,A)},customRequest:function(h,_){return gDt(g,h,_)},deleteFile:function(h,_){return hDt(g,h,_)},exists:function(h,_){return _Dt(g,h,_)},getDirectoryContents:function(h,_){return xDt(g,h,_)},getFileContents:function(h,_){return yDt(g,h,_)},getFileDownloadLink:function(h){return function(_,A){var x=di(_.remoteURL,pi(A)),y=/^https:/i.test(x)?"https":"http";switch(_.authType){case Bo.None:break;case Bo.Password:{var v=mve(_.headers.Authorization.replace(/^Basic /i,"").trim());x=x.replace(/^https?:\/\//,"".concat(y,"://").concat(v,"@"));break}default:throw new Gn({info:{code:Dp.LinkUnsupportedAuthType}},"Unsupported auth type for file link: ".concat(_.authType))}return x}(g,h)},getFileUploadLink:function(h){return function(_,A){var x="".concat(di(_.remoteURL,pi(A)),"?Content-Type=application/octet-stream"),y=/^https:/i.test(x)?"https":"http";switch(_.authType){case Bo.None:break;case Bo.Password:{var v=mve(_.headers.Authorization.replace(/^Basic /i,"").trim());x=x.replace(/^https?:\/\//,"".concat(y,"://").concat(v,"@"));break}default:throw new Gn({info:{code:Dp.LinkUnsupportedAuthType}},"Unsupported auth type for file link: ".concat(_.authType))}return x}(g,h)},getHeaders:function(){return Object.assign({},g.headers)},getQuota:function(h){return EDt(g,h)},lock:function(h,_){return kDt(g,h,_)},moveFile:function(h,_,A){return BDt(g,h,_,A)},putFileContents:function(h,_,A){return MDt(g,h,_,A)},partialUpdateFileContents:function(h,_,A,x,y){return QDt(g,h,_,A,x,y)},getDAVCompliance:function(h){return Vve(g,h)},search:function(h,_){return SDt(g,h,_)},setHeaders:function(h){g.headers=Object.assign({},h)},stat:function(h,_){return eq(g,h,_)},unlock:function(h,_,A){return IDt(g,h,_,A)}}}var Kqa=Pu.hT,Jqa=Pu.O4,Zqa=Pu.Kd,Yqa=Pu.YK,rq=Pu.UU,Kve=Pu.Gu,Xqa=Pu.ky,eLa=Pu.h4,tLa=Pu.ch,aLa=Pu.hq,rLa=Pu.i5;var Nh=require("obsidian"),Jve="https://dav.jianguoyun.com/nsdav",Zve="https://dav.jianguoyun.com/dav",Yve="1.3.1",Xve="dc_obsidian_dp0gymrn",Oc="nutstore-llm-gateway";var ODt="0.13.26",FDt="0.14.6";var eye=!Nh.Platform.isAndroidApp&&(0,Nh.requireApiVersion)(ODt)||Nh.Platform.isAndroidApp&&(0,Nh.requireApiVersion)(FDt),Np=!1;var oye=require("obsidian");var no={silent:Number.NEGATIVE_INFINITY,fatal:0,error:0,warn:1,log:2,info:3,success:3,fail:3,ready:3,start:3,box:3,debug:4,trace:5,verbose:Number.POSITIVE_INFINITY},sq={silent:{level:-1},fatal:{level:no.fatal},error:{level:no.error},warn:{level:no.warn},log:{level:no.log},info:{level:no.info},success:{level:no.success},fail:{level:no.fail},ready:{level:no.info},start:{level:no.info},box:{level:no.info},debug:{level:no.debug},trace:{level:no.trace},verbose:{level:no.verbose}};function iq(e){if(e===null||(typeof e==="undefined"?"undefined":_type_of(e))!="object")return!1;var t=Object.getPrototypeOf(e);return t!==null&&t!==Object.prototype&&Object.getPrototypeOf(t)!==null||Symbol.iterator in e?!1:Symbol.toStringTag in e?Object.prototype.toString.call(e)==="[object Module]":!0}function uq(e,t){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".",r=arguments.length>3?arguments[3]:void 0;if(!iq(t))return uq(e,{},a,r);var i=Object.assign({},t);for(var n in e){if(n==="__proto__"||n==="constructor")continue;var o=e[n];o!=null&&(r&&r(i,n,o,a)||(Array.isArray(o)&&Array.isArray(i[n])?i[n]=_to_consumable_array(o).concat(_to_consumable_array(i[n])):iq(o)&&iq(i[n])?i[n]=uq(o,i[n],(a?"".concat(a,"."):"")+n.toString(),r):i[n]=o))}return i}function qDt(e){return function(){for(var _len=arguments.length,t=new Array(_len),_key=0;_key<_len;_key++){t[_key]=arguments[_key]}return t.reduce(function(a,r){return uq(a,r,"",e)},{})}}var LDt=qDt();function $Dt(e){return Object.prototype.toString.call(e)==="[object Object]"}function UDt(e){return!(!$Dt(e)||!e.message&&!e.args||e.stack)}var nq=!1,tye=[],ji=/*#__PURE__*/function(){function ji1(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};_class_call_check(this,ji1);S(this,"options");S(this,"_lastLog");S(this,"_mockFn");var a=t.types||sq;this.options=LDt(_object_spread_props(_object_spread({},t),{defaults:_object_spread({},t.defaults),level:oq(t.level,a),reporters:_to_consumable_array(t.reporters||[])}),{types:sq,throttle:1e3,throttleMin:5,formatOptions:{date:!0,colors:!1,compact:!0}});for(var r in a){var i=_object_spread({type:r},this.options.defaults,a[r]);this[r]=this._wrapLogFn(i),this[r].raw=this._wrapLogFn(i,!0)}this.options.mockFn&&this.mockTypes(),this._lastLog={}}_create_class(ji1,[{key:"level",get:function get(){return this.options.level},set:function set(t){this.options.level=oq(t,this.options.types,this.options.level)}},{key:"prompt",value:function prompt1(t,a){if(!this.options.prompt)throw new Error("prompt is not supported!");return this.options.prompt(t,a)}},{key:"create",value:function create(t){var a=new ji(_object_spread({},this.options,t));return this._mockFn&&a.mockTypes(this._mockFn),a}},{key:"withDefaults",value:function withDefaults(t){return this.create(_object_spread_props(_object_spread({},this.options),{defaults:_object_spread({},this.options.defaults,t)}))}},{key:"withTag",value:function withTag(t){return this.withDefaults({tag:this.options.defaults.tag?this.options.defaults.tag+":"+t:t})}},{key:"addReporter",value:function addReporter(t){return this.options.reporters.push(t),this}},{key:"removeReporter",value:function removeReporter(t){if(t){var a=this.options.reporters.indexOf(t);if(a!==-1)return this.options.reporters.splice(a,1)}else this.options.reporters.splice(0);return this}},{key:"setReporters",value:function setReporters(t){return this.options.reporters=Array.isArray(t)?t:[t],this}},{key:"wrapAll",value:function wrapAll(){this.wrapConsole(),this.wrapStd()}},{key:"restoreAll",value:function restoreAll(){this.restoreConsole(),this.restoreStd()}},{key:"wrapConsole",value:function wrapConsole(){for(var t in this.options.types)console["__"+t]||(console["__"+t]=console[t]),console[t]=this[t].raw}},{key:"restoreConsole",value:function restoreConsole(){for(var t in this.options.types)console["__"+t]&&(console[t]=console["__"+t],delete console["__"+t])}},{key:"wrapStd",value:function wrapStd(){this._wrapStream(this.options.stdout,"log"),this._wrapStream(this.options.stderr,"log")}},{key:"_wrapStream",value:function _wrapStream(t,a){var _this=this;t&&(t.__write||(t.__write=t.write),t.write=function(r){_this[a].raw(String(r).trim())})}},{key:"restoreStd",value:function restoreStd(){this._restoreStream(this.options.stdout),this._restoreStream(this.options.stderr)}},{key:"_restoreStream",value:function _restoreStream(t){t&&t.__write&&(t.write=t.__write,delete t.__write)}},{key:"pauseLogs",value:function pauseLogs(){nq=!0}},{key:"resumeLogs",value:function resumeLogs(){nq=!1;var t=tye.splice(0);var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=t[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var a=_step.value;a[0]._logFn(a[1],a[2])}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}}},{key:"mockTypes",value:function mockTypes(t){var a=t||this.options.mockFn;if(this._mockFn=a,typeof a=="function")for(var r in this.options.types)this[r]=a(r,this.options.types[r])||this[r],this[r].raw=this[r]}},{key:"_wrapLogFn",value:function _wrapLogFn(t,a){var _this=this;return function(){for(var _len=arguments.length,r=new Array(_len),_key=0;_key<_len;_key++){r[_key]=arguments[_key]}if(nq){tye.push([_this,t,r,a]);return}return _this._logFn(t,r,a)}}},{key:"_logFn",value:function _logFn(t,a,r){var _this=this;if((t.level||0)>this.level)return!1;var i=_object_spread_props(_object_spread({date:new Date,args:[]},t),{level:oq(t.level,this.options.types)});!r&&a.length===1&&UDt(a[0])?Object.assign(i,a[0]):i.args=_to_consumable_array(a),i.message&&(i.args.unshift(i.message),delete i.message),i.additional&&(Array.isArray(i.additional)||(i.additional=i.additional.split("\n")),i.args.push("\n"+i.additional.join("\n")),delete i.additional),i.type=typeof i.type=="string"?i.type.toLowerCase():"log",i.tag=typeof i.tag=="string"?i.tag:"";var n=function(){var s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;var u=(_this._lastLog.count||0)-_this.options.throttleMin;if(_this._lastLog.object&&u>0){var c=_to_consumable_array(_this._lastLog.object.args);u>1&&c.push("(repeated ".concat(u," times)")),_this._log(_object_spread_props(_object_spread({},_this._lastLog.object),{args:c})),_this._lastLog.count=1}s&&(_this._lastLog.object=i,_this._log(i))};clearTimeout(this._lastLog.timeout);var o=this._lastLog.time&&i.date?i.date.getTime()-this._lastLog.time.getTime():0;if(this._lastLog.time=i.date,othis.options.throttleMin)){this._lastLog.timeout=setTimeout(n,this.options.throttle);return}}catch(s){}n(!0)}},{key:"_log",value:function _log(t){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=this.options.reporters[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var a=_step.value;a.log(t,{options:this.options})}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}}}]);return ji1}();function oq(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:3;return e===void 0?a:typeof e=="number"?e:t[e]&&t[e].level!==void 0?t[e].level:a}ji.prototype.add=ji.prototype.addReporter;ji.prototype.remove=ji.prototype.removeReporter;ji.prototype.clear=ji.prototype.removeReporter;ji.prototype.withScope=ji.prototype.withTag;ji.prototype.mock=ji.prototype.mockTypes;ji.prototype.pause=ji.prototype.pauseLogs;ji.prototype.resume=ji.prototype.resumeLogs;function aye(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return new ji(e)}var lq=/*#__PURE__*/function(){function lq1(t){_class_call_check(this,lq1);S(this,"options");S(this,"defaultColor");S(this,"levelColorMap");S(this,"typeColorMap");this.options=_object_spread({},t),this.defaultColor="#7f8c8d",this.levelColorMap={0:"#c0392b",1:"#f39c12",3:"#00BCD4"},this.typeColorMap={success:"#2ecc71"}}_create_class(lq1,[{key:"_getLogFn",value:function _getLogFn(t){return t<1?console.__error||console.error:t===1?console.__warn||console.warn:console.__log||console.log}},{key:"log",value:function log(t){var a=this._getLogFn(t.level),r=t.type==="log"?"":t.type,i=t.tag||"",o="\n background: ".concat(this.typeColorMap[t.type]||this.levelColorMap[t.level]||this.defaultColor,";\n border-radius: 0.5em;\n color: white;\n font-weight: bold;\n padding: 2px 0.5em;\n "),s="%c".concat([i,r].filter(Boolean).join(":"));typeof t.args[0]=="string"?a.apply(void 0,["".concat(s,"%c ").concat(t.args[0]),o,""].concat(_to_consumable_array(t.args.slice(1)))):a.apply(void 0,[s,o].concat(_to_consumable_array(t.args)))}}]);return lq1}();function cq(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return aye(_object_spread({reporters:e.reporters||[new lq({})],prompt:function prompt1(a){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return r.type==="confirm"?Promise.resolve(confirm(a)):Promise.resolve(prompt(a))}},e))}var gLa=cq();var GDt=cq({level:no.verbose,formatOptions:{date:!0,colors:!1}}),Pe=GDt;var Fc=require("obsidian");function zDt(){return Fc.Platform.isWin?"Windows":Fc.Platform.isMacOS?"macOS":Fc.Platform.isLinux?"Linux":Fc.Platform.isAndroidApp?"Android":Fc.Platform.isIosApp?"iOS":"Unknown"}function jDt(){return Fc.Platform.isTablet?"Tablet":Fc.Platform.isPhone?"Phone":Fc.Platform.isDesktopApp?"Desktop":Fc.Platform.isMobileApp?"Mobile":"Unknown"}function rye(e){try{return new URL(e).hostname.toLowerCase().includes("jianguoyun")}catch(t){return!1}}var iye="Obsidian (".concat(zDt(),"; ").concat(jDt(),"; ObsidianNutstoreSync/").concat(Yve,")"),nye="Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/148.0.0.0 Safari/537.36";var pq=/*#__PURE__*/function(Error1){_inherits(pq1,Error1);function pq1(a){_class_call_check(this,pq1);var _this;_this=_call_super(this,pq1,["".concat(a.status,": ").concat(a.text)]);_this.res=a;return _this}return pq1}(_wrap_native_super(Error));function Ru(e){return _async_to_generator(function(){var t,a,r,i,n;return _ts_generator(this,function(_state){switch(_state.label){case 0:t=typeof e=="string"?e:e.url,a=typeof e=="string"?{}:e.headers||{},r=rye(t)?_object_spread_props(_object_spread({},a),{"User-Agent":iye}):_object_spread_props(_object_spread({},a),{"User-Agent":nye}),i=typeof e=="string"?{url:t,throw:!1,headers:r}:_object_spread_props(_object_spread({},e),{throw:!1,headers:r});return[4,(0,oye.requestUrl)(i)];case 1:n=_state.sent();if(n.status>=400&&(Pe.error(n),typeof e=="string"||e.throw!==!1))throw new pq(n);return[2,n]}})})()}function sye(e){return Object.fromEntries(Object.entries(e).map(function(param){var _param=_sliced_to_array(param,2),t=_param[0],a=_param[1];return[t.toLowerCase(),a]}))}function HDt(e){return!/[^\u0000-\u00ff]/g.test(e)}eye&&Kve().patch("request",function(e){return _async_to_generator(function(){var p,t,a,r,i,n,o,_tmp,s,l,u,c;return _ts_generator(this,function(_state){switch(_state.label){case 0:t=e,a=sye(_object_spread({},t.headers));delete a.host,delete a["content-length"];r=(p=a.accept)!=null?p:a["content-type"],i=_object_spread({},a);Object.prototype.hasOwnProperty.call(i,"authorization")&&(i.authorization="");n={url:t.url,method:t.method,body:t.data,headers:a,contentType:r,throw:!1};return[4,Ru(n)];case 1:o=_state.sent();_tmp=o.status===401&&lye.Platform.isIosApp&&!t.url.endsWith("/")&&!t.url.endsWith(".md")&&t.method.toUpperCase()==="PROPFIND";if(!_tmp)return[3,3];n.url="".concat(t.url,"/");return[4,Ru(n)];case 2:_tmp=o=_state.sent();_state.label=3;case 3:_tmp;s=sye(_object_spread({},o.headers));for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&(HDt(s[l])||(s[l]=encodeURIComponent(s[l])));c=(0,uye.getReasonPhrase)(o.status);return[2,([101,103,204,205,304].includes(o.status)?u=new Response(null,{status:o.status,statusText:c,headers:s}):u=new Response(o.arrayBuffer,{status:o.status,statusText:c,headers:s}),u)]}})})()});var Uv=typeof Buffer=="function",DLa=typeof TextDecoder=="function"?new TextDecoder:void 0,cye=typeof TextEncoder=="function"?new TextEncoder:void 0,WDt="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",$v=Array.prototype.slice.call(WDt),KI=function(e){var t={};return e.forEach(function(a,r){return t[a]=r}),t}($v),VDt=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,Ks=String.fromCharCode.bind(String),pye=typeof Uint8Array.from=="function"?Uint8Array.from.bind(Uint8Array):function(e){return new Uint8Array(Array.prototype.slice.call(e,0))},mye=function(e){return e.replace(/=/g,"").replace(/[+\/]/g,function(t){return t=="+"?"-":"_"})},fye=function(e){return e.replace(/[^A-Za-z0-9\+\/]/g,"")},KDt=function(e){var t,a,r,i,n="",o=e.length%3;for(var s=0;s255||(r=e.charCodeAt(s++))>255||(i=e.charCodeAt(s++))>255)throw new TypeError("invalid character found");t=a<<16|r<<8|i,n+=$v[t>>18&63]+$v[t>>12&63]+$v[t>>6&63]+$v[t&63]}return o?n.slice(0,o-3)+"===".substring(o):n},gye=typeof btoa=="function"?function(e){return btoa(e)}:Uv?function(e){return Buffer.from(e,"binary").toString("base64")}:KDt,dq=Uv?function(e){return Buffer.from(e).toString("base64")}:function(e){var a=[];for(var r=0,i=e.length;r1&&arguments[1]!==void 0?arguments[1]:!1;return t?mye(dq(e)):dq(e)},JDt=function(e){if(e.length<2){var t=e.charCodeAt(0);return t<128?e:t<2048?Ks(192|t>>>6)+Ks(128|t&63):Ks(224|t>>>12&15)+Ks(128|t>>>6&63)+Ks(128|t&63)}else{var t=65536+(e.charCodeAt(0)-55296)*1024+(e.charCodeAt(1)-56320);return Ks(240|t>>>18&7)+Ks(128|t>>>12&63)+Ks(128|t>>>6&63)+Ks(128|t&63)}},ZDt=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,YDt=function(e){return e.replace(ZDt,JDt)},dye=Uv?function(e){return Buffer.from(e,"utf8").toString("base64")}:cye?function(e){return dq(cye.encode(e))}:function(e){return gye(YDt(e))},hye=function(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return t?mye(dye(e)):dye(e)};var XDt=function(e){if(e=e.replace(/\s+/g,""),!VDt.test(e))throw new TypeError("malformed base64.");e+="==".slice(2-(e.length&3));var t,a,r,i=[];for(var n=0;n>16&255)):r===64?i.push(Ks(t>>16&255,t>>8&255)):i.push(Ks(t>>16&255,t>>8&255,t&255));return i.join("")},eNt=typeof atob=="function"?function(e){return atob(fye(e))}:Uv?function(e){return Buffer.from(e,"base64").toString("binary")}:XDt,tNt=Uv?function(e){return pye(Buffer.from(e,"base64"))}:function(e){return pye(eNt(e).split("").map(function(t){return t.charCodeAt(0)}))},_ye=function(e){return tNt(aNt(e))};var aNt=function(e){return fye(e.replace(/[-_]/g,function(t){return t=="-"?"+":"/"}))};var CT=require("obsidian");var xye=Object.freeze({ignoreUnknown:!1,respectType:!1,respectFunctionNames:!1,respectFunctionProperties:!1,unorderedObjects:!0,unorderedArrays:!1,unorderedSets:!1,excludeKeys:void 0,excludeValues:void 0,replacer:void 0});function Oh(e,t){t?t=_object_spread({},xye,t):t=xye;var a=vye(t);return a.dispatch(e),a.toString()}var rNt=Object.freeze(["prototype","__proto__","constructor"]);function vye(e){var t="",a=new Map,r=function(i){t+=i};return{toString:function toString(){return t},getContext:function getContext(){return a},dispatch:function dispatch(i){return e.replacer&&(i=e.replacer(i)),this[i===null?"null":typeof i==="undefined"?"undefined":_type_of(i)](i)},object:function object(i){var _this=this;if(i&&typeof i.toJSON=="function")return this.object(i.toJSON());var n=Object.prototype.toString.call(i),o="",s=n.length;s<10?o="unknown:["+n+"]":o=n.slice(8,s-1),o=o.toLowerCase();var u=null;if((u=a.get(i))===void 0)a.set(i,a.size);else return this.dispatch("[CIRCULAR:"+u+"]");if(typeof Buffer!="undefined"&&Buffer.isBuffer&&Buffer.isBuffer(i))return r("buffer:"),r(i.toString("utf8"));if(o!=="object"&&o!=="function"&&o!=="asyncfunction")this[o]?this[o](i):e.ignoreUnknown||this.unkown(i,o);else{var c=Object.keys(i);e.unorderedObjects&&(c=c.sort());var p=[];e.respectType!==!1&&!Aye(i)&&(p=rNt),e.excludeKeys&&(c=c.filter(function(m){return!e.excludeKeys(m)}),p=p.filter(function(m){return!e.excludeKeys(m)})),r("object:"+(c.length+p.length)+":");var l=function(m){_this.dispatch(m),r(":"),e.excludeValues||_this.dispatch(i[m]),r(",")};var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=c[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var m=_step.value;l(m)}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}var _iteratorNormalCompletion1=true,_didIteratorError1=false,_iteratorError1=undefined;try{for(var _iterator1=p[Symbol.iterator](),_step1;!(_iteratorNormalCompletion1=(_step1=_iterator1.next()).done);_iteratorNormalCompletion1=true){var m1=_step1.value;l(m1)}}catch(err){_didIteratorError1=true;_iteratorError1=err}finally{try{if(!_iteratorNormalCompletion1&&_iterator1.return!=null){_iterator1.return()}}finally{if(_didIteratorError1){throw _iteratorError1}}}}},array:function array(i,n){if(n=n===void 0?e.unorderedArrays!==!1:n,r("array:"+i.length+":"),!n||i.length<=1){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=i[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var u=_step.value;this.dispatch(u)}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return}var o=new Map,s=i.map(function(u){var c=vye(e);c.dispatch(u);var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=c.getContext()[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var _step_value=_sliced_to_array(_step.value,2),p=_step_value[0],l=_step_value[1];o.set(p,l)}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return c.toString()});return a=o,s.sort(),this.array(s,!1)},date:function date(i){return r("date:"+i.toJSON())},symbol:function symbol(i){return r("symbol:"+i.toString())},unkown:function unkown(i,n){if(r(n),!!i&&(r(":"),i&&typeof i.entries=="function"))return this.array(Array.from(i.entries()),!0)},error:function error(i){return r("error:"+i.toString())},boolean:function boolean(i){return r("bool:"+i)},string:function string(i){r("string:"+i.length+":"),r(i)},function:function _function(i){r("fn:"),Aye(i)?this.dispatch("[native]"):this.dispatch(i.toString()),e.respectFunctionNames!==!1&&this.dispatch("function-name:"+String(i.name)),e.respectFunctionProperties&&this.object(i)},number:function number(i){return r("number:"+i)},xml:function xml(i){return r("xml:"+i.toString())},null:function _null(){return r("Null")},undefined:function undefined1(){return r("Undefined")},regexp:function regexp(i){return r("regex:"+i.toString())},uint8array:function uint8array(i){return r("uint8array:"),this.dispatch(Array.prototype.slice.call(i))},uint8clampedarray:function uint8clampedarray(i){return r("uint8clampedarray:"),this.dispatch(Array.prototype.slice.call(i))},int8array:function int8array(i){return r("int8array:"),this.dispatch(Array.prototype.slice.call(i))},uint16array:function uint16array(i){return r("uint16array:"),this.dispatch(Array.prototype.slice.call(i))},int16array:function int16array(i){return r("int16array:"),this.dispatch(Array.prototype.slice.call(i))},uint32array:function uint32array(i){return r("uint32array:"),this.dispatch(Array.prototype.slice.call(i))},int32array:function int32array(i){return r("int32array:"),this.dispatch(Array.prototype.slice.call(i))},float32array:function float32array(i){return r("float32array:"),this.dispatch(Array.prototype.slice.call(i))},float64array:function float64array(i){return r("float64array:"),this.dispatch(Array.prototype.slice.call(i))},arraybuffer:function arraybuffer(i){return r("arraybuffer:"),this.dispatch(new Uint8Array(i))},url:function url(i){return r("url:"+i.toString())},map:function map(i){r("map:");var n=_to_consumable_array(i);return this.array(n,e.unorderedSets!==!1)},set:function set(i){r("set:");var n=_to_consumable_array(i);return this.array(n,e.unorderedSets!==!1)},file:function file(i){return r("file:"),this.dispatch([i.name,i.size,i.type,i.lastModfied])},blob:function blob(){if(e.ignoreUnknown)return r("[blob]");throw new Error('Hashing Blob objects is currently not supported\nUse "options.replacer" or "options.ignoreUnknown"\n')},domwindow:function domwindow(){return r("domwindow")},bigint:function bigint(i){return r("bigint:"+i.toString())},process:function process1(){return r("process")},timer:function timer(){return r("timer")},pipe:function pipe(){return r("pipe")},tcp:function tcp(){return r("tcp")},udp:function udp(){return r("udp")},tty:function tty(){return r("tty")},statwatcher:function statwatcher(){return r("statwatcher")},securecontext:function securecontext(){return r("securecontext")},connection:function connection(){return r("connection")},zlib:function zlib(){return r("zlib")},context:function context(){return r("context")},nodescript:function nodescript(){return r("nodescript")},httpparser:function httpparser(){return r("httpparser")},dataview:function dataview(){return r("dataview")},signal:function signal(){return r("signal")},fsevent:function fsevent(){return r("fsevent")},tlswrap:function tlswrap(){return r("tlswrap")}}}var yye="[native code] }",iNt=yye.length;function Aye(e){return typeof e!="function"?!1:Function.prototype.toString.call(e).slice(-iNt)===yye}function mq(e,t){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return e===t||Oh(e,a)===Oh(t,a)}var qc=/*#__PURE__*/function(){function qc1(t,a){_class_call_check(this,qc1);S(this,"words");S(this,"sigBytes");t=this.words=t||[],this.sigBytes=a===void 0?t.length*4:a}_create_class(qc1,[{key:"toString",value:function toString(t){return(t||nNt).stringify(this)}},{key:"concat",value:function concat(t){if(this.clamp(),this.sigBytes%4)for(var a=0;a>>2]>>>24-a%4*8&255;this.words[this.sigBytes+a>>>2]|=r<<24-(this.sigBytes+a)%4*8}else for(var a6=0;a6>>2]=t.words[a6>>>2];return this.sigBytes+=t.sigBytes,this}},{key:"clamp",value:function clamp(){this.words[this.sigBytes>>>2]&=0xffffffff<<32-this.sigBytes%4*8,this.words.length=Math.ceil(this.sigBytes/4)}},{key:"clone",value:function clone(){return new qc(_to_consumable_array(this.words))}}]);return qc1}(),nNt={stringify:function stringify(e){var t=[];for(var a=0;a>>2]>>>24-a%4*8&255;t.push((r>>>4).toString(16),(r&15).toString(16))}return t.join("")}},oNt={stringify:function stringify(e){var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",a=[];for(var r=0;r>>2]>>>24-r%4*8&255,n=e.words[r+1>>>2]>>>24-(r+1)%4*8&255,o=e.words[r+2>>>2]>>>24-(r+2)%4*8&255,s=i<<16|n<<8|o;for(var u=0;u<4&&r*8+u*6>>6*(3-u)&63))}return a.join("")}},sNt={parse:function parse(e){var t=e.length,a=[];for(var r=0;r>>2]|=(e.charCodeAt(r)&255)<<24-r%4*8;return new qc(a,t)}},uNt={parse:function parse(e){return sNt.parse(unescape(encodeURIComponent(e)))}},fq=/*#__PURE__*/function(){function fq1(){_class_call_check(this,fq1);S(this,"_data",new qc);S(this,"_nDataBytes",0);S(this,"_minBufferSize",0);S(this,"blockSize",512/32)}_create_class(fq1,[{key:"reset",value:function reset(){this._data=new qc,this._nDataBytes=0}},{key:"_append",value:function _append(t){typeof t=="string"&&(t=uNt.parse(t)),this._data.concat(t),this._nDataBytes+=t.sigBytes}},{key:"_doProcessBlock",value:function _doProcessBlock(t,a){}},{key:"_process",value:function _process(t){var a,r=this._data.sigBytes/(this.blockSize*4);t?r=Math.ceil(r):r=Math.max((r|0)-this._minBufferSize,0);var i=r*this.blockSize,n=Math.min(i*4,this._data.sigBytes);if(i){for(var o=0;o>>7)^(v<<14|v>>>18)^v>>>3,b=Ef[f-2],w=(b<<15|b>>>17)^(b<<13|b>>>19)^b>>>10;Ef[f]=I+Ef[f-7]+w+Ef[f-16]}var g=c&p^~c&l,h=n&o^n&s^o&s,_=(n<<30|n>>>2)^(n<<19|n>>>13)^(n<<10|n>>>22),A=(c<<26|c>>>6)^(c<<21|c>>>11)^(c<<7|c>>>25),x=m+A+g+lNt[f]+Ef[f],y=_+h;m=l,l=p,p=c,c=u+x|0,u=s,s=o,o=n,n=x+y|0}i[0]=i[0]+n|0,i[1]=i[1]+o|0,i[2]=i[2]+s|0,i[3]=i[3]+u|0,i[4]=i[4]+c|0,i[5]=i[5]+p|0,i[6]=i[6]+l|0,i[7]=i[7]+m|0}},{key:"finalize",value:function finalize(a){_get(_get_prototype_of(hq1.prototype),"finalize",this).call(this,a);var r=this._nDataBytes*8,i=this._data.sigBytes*8;return this._data.words[i>>>5]|=128<<24-i%32,this._data.words[(i+64>>>9<<4)+14]=Math.floor(r/0x100000000),this._data.words[(i+64>>>9<<4)+15]=r,this._data.sigBytes=this._data.words.length*4,this._process(),this._hash}}]);return hq1}(gq);function cNt(e){return new hq().finalize(e).toString(oNt)}function cs(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};var a=typeof e=="string"?e:Oh(e,t);return cNt(a).slice(0,10)}function ZI(e,t){return{hash:cs({type:"vault-path",kind:t,path:e}),type:"vault-path",kind:t,path:e}}function YI(e){return _object_spread_props(_object_spread({},e),{range:{from:_object_spread({},e.range.from),to:_object_spread({},e.range.to)},hash:cs(e)})}function XI(e,t){return _async_to_generator(function(){var o,a,r,i,n;return _ts_generator(this,function(_state){switch(_state.label){case 0:a=(t==null?void 0:t.mimeType)||e.type||"image/png",r=(o=t==null?void 0:t.size)!=null?o:e.size,i=e.type===a?e:new Blob([e],{type:a});return[4,dNt(i)];case 1:n=_state.sent();return[2,{hash:cs({type:"image",mimeType:a,size:r,dataUrl:n}),type:"image",blob:e,mimeType:a,name:t==null?void 0:t.name,size:r}]}})})()}function Iye(e,t){var n;var a=t.mimeType||e.type||"application/octet-stream",r=(n=t.size)!=null?n:e.size,i="lastModified"in e&&typeof e.lastModified=="number"?e.lastModified:void 0;return{hash:cs({type:"file",mimeType:a,filename:t.filename,size:r,lastModified:i}),type:"file",blob:e,mimeType:a,filename:t.filename,size:r}}var bye=0;function ek(e,t){bye+=1;var a="pending-context-".concat(Date.now().toString(36),"-").concat(bye);return{type:"pending-context",placeholderType:e,id:a,placeholder:t}}function Lc(e){return e.type==="pending-context"?e.id:e.hash?e.hash:e.type==="vault-path"?cs({type:"vault-path",kind:e.kind,path:e.path}):e.type==="selection"?cs({type:"selection",filePath:e.filePath,range:e.range,selectedText:e.selectedText}):e.type==="file"?cs({type:"file",mimeType:e.mimeType,filename:e.filename,size:e.size}):cs({type:"image",mimeType:e.mimeType,size:e.size})}function pNt(e){if(e.type==="pending-context")return _object_spread({},e);var t=Lc(e);return e.type==="vault-path"?_object_spread_props(_object_spread({},e),{hash:t}):e.type==="image"?_object_spread_props(_object_spread({},e),{hash:t}):e.type==="file"?_object_spread_props(_object_spread({},e),{hash:t}):_object_spread_props(_object_spread({},e),{hash:t,range:{from:_object_spread({},e.range.from),to:_object_spread({},e.range.to)}})}function k0(e){var t=pNt(e);return t.type==="vault-path"?_object_spread({},t):t.type==="image"?_object_spread({},t):t.type==="file"?_object_spread({},t):t.type==="pending-context"?_object_spread({},t):{hash:t.hash,type:"selection",filePath:t.filePath,range:{from:_object_spread({},t.range.from),to:_object_spread({},t.range.to)},selectedText:t.selectedText}}function Gv(e){return e.map(k0)}function dNt(e){return new Promise(function(t,a){var r=new FileReader;r.onerror=function(){a(r.error||new Error("Failed to read image blob."))},r.onload=function(){if(typeof r.result=="string"){t(r.result);return}a(new Error("Unexpected FileReader result while reading image."))},r.readAsDataURL(e)})}function tk(e){var t=e.reduce(function(r,i){return i.type==="vault-path"&&r.push({type:i.kind,path:i.path}),i.type==="selection"&&r.push({type:"selection",filePath:i.filePath,range:{from:i.range.from,to:i.range.to},selectedText:i.selectedText}),r},[]);return"\n".concat(JSON.stringify(t,null,2),"\n")}var LSe=require("obsidian");var _q=function _q1(e,t){return _q=Object.setPrototypeOf||_instanceof({__proto__:[]},Array)&&function(a,r){a.__proto__=r}||function(a,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(a[i]=r[i])},_q(e,t)};function Qu(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");_q(e,t);function a(){this.constructor=e}e.prototype=t===null?Object.create(t):(a.prototype=t.prototype,new a)}function zv(e){var t=typeof Symbol=="function"&&Symbol.iterator,a=t&&e[t],r=0;if(a)return a.call(e);if(e&&typeof e.length=="number")return{next:function next(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Op(e,t){var a=typeof Symbol=="function"&&e[Symbol.iterator];if(!a)return e;var r=a.call(e),i,n=[],o;try{for(;(t===void 0||t-- >0)&&!(i=r.next()).done;)n.push(i.value)}catch(s){o={error:s}}finally{try{i&&!i.done&&(a=r.return)&&a.call(r)}finally{if(o)throw o.error}}return n}function Fp(e,t,a){if(a||arguments.length===2)for(var r=0,i=t.length,n;r0},enumerable:!1,configurable:!0}),t.prototype._trySubscribe=function(a){return this._throwIfClosed(),e.prototype._trySubscribe.call(this,a)},t.prototype._subscribe=function(a){return this._throwIfClosed(),this._checkFinalizedStatuses(a),this._innerSubscribe(a)},t.prototype._innerSubscribe=function(a){var r=this,i=this,n=i.hasError,o=i.isStopped,s=i.observers;return n||o?xq:(this.currentObservers=null,s.push(a),new C0(function(){r.currentObservers=null,Sf(s,a)}))},t.prototype._checkFinalizedStatuses=function(a){var r=this,i=r.hasError,n=r.thrownError,o=r.isStopped;i?a.error(n):o&&a.complete()},t.prototype.asObservable=function(){var a=new jv;return a.source=this,a},t.create=function(a,r){return new Nye(a,r)},t}(jv);var Nye=function(e){Qu(t,e);function t(a,r){var i=e.call(this)||this;return i.destination=a,i.source=r,i}return t.prototype.next=function(a){var r,i;(i=(r=this.destination)===null||r===void 0?void 0:r.next)===null||i===void 0||i.call(r,a)},t.prototype.error=function(a){var r,i;(i=(r=this.destination)===null||r===void 0?void 0:r.error)===null||i===void 0||i.call(r,a)},t.prototype.complete=function(){var a,r;(r=(a=this.destination)===null||a===void 0?void 0:a.complete)===null||r===void 0||r.call(a)},t.prototype._subscribe=function(a){var r,i;return(i=(r=this.source)===null||r===void 0?void 0:r.subscribe(a))!==null&&i!==void 0?i:xq},t}(qr);var Iq={now:function now(){return(Iq.delegate||Date).now()},delegate:void 0};var Oye=function(e){Qu(t,e);function t(a,r){return e.call(this)||this}return t.prototype.schedule=function(a,r){return r===void 0&&(r=0),this},t}(C0);var Hv={setInterval:function setInterval1(e,t){for(var a=[],r=2;r-1?e.replace(yNt,"."):e},o5e=function(e){return!e||ha(e)},Kv=function(e,t,a){var r=ha(t)?t.split("."):t,i=0;for(;i":">",'"':""","'":"'","/":"/"},kNt=function(e){return ha(e)?e.replace(/[&<>"'\/]/g,function(t){return INt[t]}):e},Sq=/*#__PURE__*/function(){function Sq1(t){_class_call_check(this,Sq1);this.capacity=t,this.regExpMap=new Map,this.regExpQueue=[]}_create_class(Sq1,[{key:"getRegExp",value:function getRegExp(t){var a=this.regExpMap.get(t);if(a!==void 0)return a;var r=new RegExp(t);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(t,r),this.regExpQueue.push(t),r}}]);return Sq1}(),CNt=[" ",",","?","!",";"],ENt=new Sq(20),SNt=function(e,t,a){t=t||"",a=a||"";var r=CNt.filter(function(o){return t.indexOf(o)<0&&a.indexOf(o)<0});if(r.length===0)return!0;var i=ENt.getRegExp("(".concat(r.map(function(o){return o==="?"?"\\?":o}).join("|"),")")),n=!i.test(e);if(!n){var o=e.indexOf(a);o>0&&!i.test(e.substring(0,o))&&(n=!0)}return n},Bq=function Bq1(e,t){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:".";if(!e)return;if(e[t])return Object.prototype.hasOwnProperty.call(e,t)?e[t]:void 0;var r=t.split(a),i=e;for(var n=0;n-1&&u1&&arguments[1]!==void 0?arguments[1]:{};this.init(t,a)}_create_class(Uh1,[{key:"init",value:function init(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=a.prefix||"i18next:",this.logger=t||BNt,this.options=a,this.debug=a.debug}},{key:"log",value:function log(){for(var t=arguments.length,a=new Array(t),r=0;r1?a-1:0),i=1;i1&&arguments[1]!==void 0?arguments[1]:{ns:["translation"],defaultNS:"translation"};_this=_call_super(this,hk1),_this.data=t||{},_this.options=a,_this.options.keySeparator===void 0&&(_this.options.keySeparator="."),_this.options.ignoreJSONStructure===void 0&&(_this.options.ignoreJSONStructure=!0);return _this}_create_class(hk1,[{key:"addNamespaces",value:function addNamespaces(t){this.options.ns.indexOf(t)<0&&this.options.ns.push(t)}},{key:"removeNamespaces",value:function removeNamespaces(t){var a=this.options.ns.indexOf(t);a>-1&&this.options.ns.splice(a,1)}},{key:"getResource",value:function getResource(t,a,r){var _s1,_s2;var c,p;var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},n=i.keySeparator!==void 0?i.keySeparator:this.options.keySeparator,o=i.ignoreJSONStructure!==void 0?i.ignoreJSONStructure:this.options.ignoreJSONStructure,s;t.indexOf(".")>-1?s=t.split("."):(s=[t,a],r&&(Array.isArray(r)?(_s1=s).push.apply(_s1,_to_consumable_array(r)):ha(r)&&n?(_s2=s).push.apply(_s2,_to_consumable_array(r.split(n))):s.push(r)));var u=fk(this.data,s);return!u&&!a&&!r&&t.indexOf(".")>-1&&(t=s[0],a=s[1],r=s.slice(2).join(".")),u||!o||!ha(r)?u:Bq((p=(c=this.data)==null?void 0:c[t])==null?void 0:p[a],r,n)}},{key:"addResource",value:function addResource(t,a,r,i){var n=arguments.length>4&&arguments[4]!==void 0?arguments[4]:{silent:!1},o=n.keySeparator!==void 0?n.keySeparator:this.options.keySeparator,s=[t,a];r&&(s=s.concat(o?r.split(o):r)),t.indexOf(".")>-1&&(s=t.split("."),i=a,a=s[1]),this.addNamespaces(a),s5e(this.data,s,i),n.silent||this.emit("added",t,a,r,i)}},{key:"addResources",value:function addResources(t,a,r){var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{silent:!1};for(var n in r)(ha(r[n])||Array.isArray(r[n]))&&this.addResource(t,a,n,r[n],{silent:!0});i.silent||this.emit("added",t,a,r)}},{key:"addResourceBundle",value:function addResourceBundle(t,a,r,i,n){var o=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{silent:!1,skipCopy:!1},s=[t,a];t.indexOf(".")>-1&&(s=t.split("."),i=r,r=a,a=s[1]),this.addNamespaces(a);var u=fk(this.data,s)||{};o.skipCopy||(r=JSON.parse(JSON.stringify(r))),i?g5e(u,r,n):u=_object_spread({},u,r),s5e(this.data,s,u),o.silent||this.emit("added",t,a,r)}},{key:"removeResourceBundle",value:function removeResourceBundle(t,a){this.hasResourceBundle(t,a)&&delete this.data[t][a],this.removeNamespaces(a),this.emit("removed",t,a)}},{key:"hasResourceBundle",value:function hasResourceBundle(t,a){return this.getResource(t,a)!==void 0}},{key:"getResourceBundle",value:function getResourceBundle(t,a){return a||(a=this.options.defaultNS),this.getResource(t,a)}},{key:"getDataByLanguage",value:function getDataByLanguage(t){return this.data[t]}},{key:"hasLanguageSomeTranslations",value:function hasLanguageSomeTranslations(t){var a=this.getDataByLanguage(t);return!!(a&&Object.keys(a)||[]).find(function(i){return a[i]&&Object.keys(a[i]).length>0})}},{key:"toJSON",value:function toJSON(){return this.data}}]);return hk1}(Gh),h5e={processors:{},addPostProcessor:function addPostProcessor(e){this.processors[e.name]=e},handle:function handle(e,t,a,r,i){var _this=this;return e.forEach(function(n){var o,s;t=(s=(o=_this.processors[n])==null?void 0:o.process(t,a,r,i))!=null?s:t}),t}},u5e={},l5e=function(e){return!ha(e)&&typeof e!="boolean"&&typeof e!="number"},zh=/*#__PURE__*/function(Gh1){_inherits(zh1,Gh1);function zh1(t){_class_call_check(this,zh1);var _this;var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};_this=_call_super(this,zh1),vNt(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],t,_this),_this.options=a,_this.options.keySeparator===void 0&&(_this.options.keySeparator="."),_this.logger=Uc.create("translator");return _this}_create_class(zh1,[{key:"changeLanguage",value:function changeLanguage(t){t&&(this.language=t)}},{key:"exists",value:function exists(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};if(t==null)return!1;var r=this.resolve(t,a);return(r==null?void 0:r.res)!==void 0}},{key:"extractFromKey",value:function extractFromKey(t,a){var r=a.nsSeparator!==void 0?a.nsSeparator:this.options.nsSeparator;r===void 0&&(r=":");var i=a.keySeparator!==void 0?a.keySeparator:this.options.keySeparator,n=a.ns||this.options.defaultNS||[],o=r&&t.indexOf(r)>-1,s=!this.options.userDefinedKeySeparator&&!a.keySeparator&&!this.options.userDefinedNsSeparator&&!a.nsSeparator&&!SNt(t,r,i);if(o&&!s){var u=t.match(this.interpolator.nestingRegexp);if(u&&u.length>0)return{key:t,namespaces:ha(n)?[n]:n};var c=t.split(r);(r!==i||r===i&&this.options.ns.indexOf(c[0])>-1)&&(n=c.shift()),t=c.join(i)}return{key:t,namespaces:ha(n)?[n]:n}}},{key:"translate",value:function translate(t,a,r){var _this=this;if((typeof a==="undefined"?"undefined":_type_of(a))!="object"&&this.options.overloadTranslationOptionHandler&&(a=this.options.overloadTranslationOptionHandler(arguments)),(typeof a==="undefined"?"undefined":_type_of(a))=="object"&&(a=_object_spread({},a)),a||(a={}),t==null)return"";Array.isArray(t)||(t=[String(t)]);var i=a.returnDetails!==void 0?a.returnDetails:this.options.returnDetails,n=a.keySeparator!==void 0?a.keySeparator:this.options.keySeparator,_this_extractFromKey=this.extractFromKey(t[t.length-1],a),o=_this_extractFromKey.key,s=_this_extractFromKey.namespaces,u=s[s.length-1],c=a.lng||this.language,p=a.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if((c==null?void 0:c.toLowerCase())==="cimode"){if(p){var P=a.nsSeparator||this.options.nsSeparator;return i?{res:"".concat(u).concat(P).concat(o),usedKey:o,exactUsedKey:o,usedLng:c,usedNS:u,usedParams:this.getUsedParamsDetails(a)}:"".concat(u).concat(P).concat(o)}return i?{res:o,usedKey:o,exactUsedKey:o,usedLng:c,usedNS:u,usedParams:this.getUsedParamsDetails(a)}:o}var l=this.resolve(t,a),m=l==null?void 0:l.res,f=(l==null?void 0:l.usedKey)||o,g=(l==null?void 0:l.exactUsedKey)||o,h=["[object Number]","[object Function]","[object RegExp]"],_=a.joinArrays!==void 0?a.joinArrays:this.options.joinArrays,A=!this.i18nFormat||this.i18nFormat.handleAsObject,x=a.count!==void 0&&!ha(a.count),y=zh.hasDefaultValue(a),v=x?this.pluralResolver.getSuffix(c,a.count,a):"",I=a.ordinal&&x?this.pluralResolver.getSuffix(c,a.count,{ordinal:!1}):"",b=x&&!a.ordinal&&a.count===0,w=b&&a["defaultValue".concat(this.options.pluralSeparator,"zero")]||a["defaultValue".concat(v)]||a["defaultValue".concat(I)]||a.defaultValue,k=m;A&&!m&&y&&(k=w);var C=l5e(k),E=Object.prototype.toString.apply(k);if(A&&k&&C&&h.indexOf(E)<0&&!(ha(_)&&Array.isArray(k))){if(!a.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");var P2=this.options.returnedObjectHandler?this.options.returnedObjectHandler(f,k,_object_spread_props(_object_spread({},a),{ns:s})):"key '".concat(o," (").concat(this.language,")' returned an object instead of string.");return i?(l.res=P2,l.usedParams=this.getUsedParamsDetails(a),l):P2}if(n){var P4=Array.isArray(k),B=P4?[]:{},M=P4?g:f;for(var R in k)if(Object.prototype.hasOwnProperty.call(k,R)){var N="".concat(M).concat(n).concat(R);y&&!m?B[R]=this.translate(N,_object_spread_props(_object_spread({},a),{defaultValue:l5e(w)?w[R]:void 0,joinArrays:!1,ns:s})):B[R]=this.translate(N,_object_spread_props(_object_spread({},a),{joinArrays:!1,ns:s})),B[R]===N&&(B[R]=k[R])}m=B}}else if(A&&ha(_)&&Array.isArray(m))m=m.join(_),m&&(m=this.extendTranslation(m,t,a,r));else{var P6=!1,B6=!1;!this.isValidLookup(m)&&y&&(P6=!0,m=w),this.isValidLookup(m)||(B6=!0,m=o);var R4=(a.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&B6?void 0:m,N10=y&&w!==m&&this.options.updateMissing;if(B6||P6||N10){if(this.logger.log(N10?"updateKey":"missingKey",c,u,o,N10?w:m),n){var $=this.resolve(o,_object_spread_props(_object_spread({},a),{keySeparator:!1}));$&&$.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}var Q=[],O=this.languageUtils.getFallbackCodes(this.options.fallbackLng,a.lng||this.language);if(this.options.saveMissingTo==="fallback"&&O&&O[0])for(var $2=0;$21&&arguments[1]!==void 0?arguments[1]:{},r,i,n,o,s;return ha(t)&&(t=[t]),t.forEach(function(u){if(_this.isValidLookup(r))return;var c=_this.extractFromKey(u,a),p=c.key;i=p;var l=c.namespaces;_this.options.fallbackNS&&(l=l.concat(_this.options.fallbackNS));var m=a.count!==void 0&&!ha(a.count),f=m&&!a.ordinal&&a.count===0,g=a.context!==void 0&&(ha(a.context)||typeof a.context=="number")&&a.context!=="",h=a.lngs?a.lngs:_this.languageUtils.toResolveHierarchy(a.lng||_this.language,a.fallbackLng);l.forEach(function(_){var A,x;_this.isValidLookup(r)||(s=_,!u5e["".concat(h[0],"-").concat(_)]&&(A=_this.utils)!=null&&A.hasLoadedNamespace&&!((x=_this.utils)!=null&&x.hasLoadedNamespace(s))&&(u5e["".concat(h[0],"-").concat(_)]=!0,_this.logger.warn('key "'.concat(i,'" for languages "').concat(h.join(", "),'" won\'t get resolved as namespace "').concat(s,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),h.forEach(function(y){var b;if(_this.isValidLookup(r))return;o=y;var v=[p];if((b=_this.i18nFormat)!=null&&b.addLookupKeys)_this.i18nFormat.addLookupKeys(v,p,y,_,a);else{var w;m&&(w=_this.pluralResolver.getSuffix(y,a.count,a));var k="".concat(_this.options.pluralSeparator,"zero"),C="".concat(_this.options.pluralSeparator,"ordinal").concat(_this.options.pluralSeparator);if(m&&(v.push(p+w),a.ordinal&&w.indexOf(C)===0&&v.push(p+w.replace(C,_this.options.pluralSeparator)),f&&v.push(p+k)),g){var E="".concat(p).concat(_this.options.contextSeparator).concat(a.context);v.push(E),m&&(v.push(E+w),a.ordinal&&w.indexOf(C)===0&&v.push(E+w.replace(C,_this.options.pluralSeparator)),f&&v.push(E+k))}}var I;for(;I=v.pop();)_this.isValidLookup(r)||(n=I,r=_this.getResource(y,_,I,a))}))})}),{res:r,usedKey:i,exactUsedKey:n,usedLng:o,usedNS:s}}},{key:"isValidLookup",value:function isValidLookup(t){return t!==void 0&&!(!this.options.returnNull&&t===null)&&!(!this.options.returnEmptyString&&t==="")}},{key:"getResource",value:function getResource(t,a,r){var n;var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};return(n=this.i18nFormat)!=null&&n.getResource?this.i18nFormat.getResource(t,a,r,i):this.resourceStore.getResource(t,a,r,i)}},{key:"getUsedParamsDetails",value:function getUsedParamsDetails(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},a=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],r=t.replace&&!ha(t.replace),i=r?t.replace:t;if(r&&typeof t.count!="undefined"&&(i.count=t.count),this.options.interpolation.defaultVariables&&(i=_object_spread({},this.options.interpolation.defaultVariables,i)),!r){i=_object_spread({},i);var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=a[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var n=_step.value;delete i[n]}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}}return i}}],[{key:"hasDefaultValue",value:function hasDefaultValue(t){var a="defaultValue";for(var r in t)if(Object.prototype.hasOwnProperty.call(t,r)&&a===r.substring(0,a.length)&&t[r]!==void 0)return!0;return!1}}]);return zh1}(Gh),_k=/*#__PURE__*/function(){function _k1(t){_class_call_check(this,_k1);this.options=t,this.supportedLngs=this.options.supportedLngs||!1,this.logger=Uc.create("languageUtils")}_create_class(_k1,[{key:"getScriptPartFromCode",value:function getScriptPartFromCode(t){if(t=gk(t),!t||t.indexOf("-")<0)return null;var a=t.split("-");return a.length===2||(a.pop(),a[a.length-1].toLowerCase()==="x")?null:this.formatLanguageCode(a.join("-"))}},{key:"getLanguagePartFromCode",value:function getLanguagePartFromCode(t){if(t=gk(t),!t||t.indexOf("-")<0)return t;var a=t.split("-");return this.formatLanguageCode(a[0])}},{key:"formatLanguageCode",value:function formatLanguageCode(t){if(ha(t)&&t.indexOf("-")>-1){var a;try{a=Intl.getCanonicalLocales(t)[0]}catch(r){}return a&&this.options.lowerCaseLng&&(a=a.toLowerCase()),a||(this.options.lowerCaseLng?t.toLowerCase():t)}return this.options.cleanCode||this.options.lowerCaseLng?t.toLowerCase():t}},{key:"isSupportedCode",value:function isSupportedCode(t){return(this.options.load==="languageOnly"||this.options.nonExplicitSupportedLngs)&&(t=this.getLanguagePartFromCode(t)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(t)>-1}},{key:"getBestMatchFromCodes",value:function getBestMatchFromCodes(t){var _this=this;if(!t)return null;var a;return t.forEach(function(r){if(a)return;var i=_this.formatLanguageCode(r);(!_this.options.supportedLngs||_this.isSupportedCode(i))&&(a=i)}),!a&&this.options.supportedLngs&&t.forEach(function(r){if(a)return;var i=_this.getLanguagePartFromCode(r);if(_this.isSupportedCode(i))return a=i;a=_this.options.supportedLngs.find(function(n){if(n===i)return n;if(!(n.indexOf("-")<0&&i.indexOf("-")<0)&&(n.indexOf("-")>0&&i.indexOf("-")<0&&n.substring(0,n.indexOf("-"))===i||n.indexOf(i)===0&&i.length>1))return n})}),a||(a=this.getFallbackCodes(this.options.fallbackLng)[0]),a}},{key:"getFallbackCodes",value:function getFallbackCodes(t,a){if(!t)return[];if(typeof t=="function"&&(t=t(a)),ha(t)&&(t=[t]),Array.isArray(t))return t;if(!a)return t.default||[];var r=t[a];return r||(r=t[this.getScriptPartFromCode(a)]),r||(r=t[this.formatLanguageCode(a)]),r||(r=t[this.getLanguagePartFromCode(a)]),r||(r=t.default),r||[]}},{key:"toResolveHierarchy",value:function toResolveHierarchy(t,a){var _this=this;var r=this.getFallbackCodes(a||this.options.fallbackLng||[],t),i=[],n=function(o){o&&(_this.isSupportedCode(o)?i.push(o):_this.logger.warn("rejecting language code not found in supportedLngs: ".concat(o)))};return ha(t)&&(t.indexOf("-")>-1||t.indexOf("_")>-1)?(this.options.load!=="languageOnly"&&n(this.formatLanguageCode(t)),this.options.load!=="languageOnly"&&this.options.load!=="currentOnly"&&n(this.getScriptPartFromCode(t)),this.options.load!=="currentOnly"&&n(this.getLanguagePartFromCode(t))):ha(t)&&n(this.formatLanguageCode(t)),r.forEach(function(o){i.indexOf(o)<0&&n(_this.formatLanguageCode(o))}),i}}]);return _k1}(),c5e={zero:0,one:1,two:2,few:3,many:4,other:5},p5e={select:function(e){return e===1?"one":"other"},resolvedOptions:function(){return{pluralCategories:["one","other"]}}},Tq=/*#__PURE__*/function(){function Tq1(t){_class_call_check(this,Tq1);var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.languageUtils=t,this.options=a,this.logger=Uc.create("pluralResolver"),this.pluralRulesCache={}}_create_class(Tq1,[{key:"addRule",value:function addRule(t,a){this.rules[t]=a}},{key:"clearCache",value:function clearCache(){this.pluralRulesCache={}}},{key:"getRule",value:function getRule(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=gk(t==="dev"?"en":t),i=a.ordinal?"ordinal":"cardinal",n=JSON.stringify({cleanedCode:r,type:i});if(n in this.pluralRulesCache)return this.pluralRulesCache[n];var o;try{o=new Intl.PluralRules(r,{type:i})}catch(s){if(!Intl)return this.logger.error("No Intl support, please use an Intl polyfill!"),p5e;if(!t.match(/-|_/))return p5e;var u=this.languageUtils.getLanguagePartFromCode(t);o=this.getRule(u,a)}return this.pluralRulesCache[n]=o,o}},{key:"needsPlural",value:function needsPlural(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=this.getRule(t,a);return r||(r=this.getRule("dev",a)),(r==null?void 0:r.resolvedOptions().pluralCategories.length)>1}},{key:"getPluralFormsOfKey",value:function getPluralFormsOfKey(t,a){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.getSuffixes(t,r).map(function(i){return"".concat(a).concat(i)})}},{key:"getSuffixes",value:function getSuffixes(t){var _this=this;var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=this.getRule(t,a);return r||(r=this.getRule("dev",a)),r?r.resolvedOptions().pluralCategories.sort(function(i,n){return c5e[i]-c5e[n]}).map(function(i){return"".concat(_this.options.prepend).concat(a.ordinal?"ordinal".concat(_this.options.prepend):"").concat(i)}):[]}},{key:"getSuffix",value:function getSuffix(t,a){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=this.getRule(t,r);return i?"".concat(this.options.prepend).concat(r.ordinal?"ordinal".concat(this.options.prepend):"").concat(i.select(a)):(this.logger.warn("no plural rule found for: ".concat(t)),this.getSuffix("dev",a,r))}}]);return Tq1}(),d5e=function d5e1(e,t,a){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:".",i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,n=bNt(e,t,a);return!n&&i&&ha(a)&&(n=Bq(e,a,r),n===void 0&&(n=Bq(t,a,r))),n},Eq=function(e){return e.replace(/\$/g,"$$$$")},Mq=/*#__PURE__*/function(){function Mq1(){_class_call_check(this,Mq1);var a;var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=Uc.create("interpolator"),this.options=t,this.format=((a=t==null?void 0:t.interpolation)==null?void 0:a.format)||function(r){return r},this.init(t)}_create_class(Mq1,[{key:"init",value:function init(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};t.interpolation||(t.interpolation={escapeValue:!0});var _t_interpolation=t.interpolation,a=_t_interpolation.escape,r=_t_interpolation.escapeValue,i=_t_interpolation.useRawValueToEscape,n=_t_interpolation.prefix,o=_t_interpolation.prefixEscaped,s=_t_interpolation.suffix,u=_t_interpolation.suffixEscaped,c=_t_interpolation.formatSeparator,p=_t_interpolation.unescapeSuffix,l=_t_interpolation.unescapePrefix,m=_t_interpolation.nestingPrefix,f=_t_interpolation.nestingPrefixEscaped,g=_t_interpolation.nestingSuffix,h=_t_interpolation.nestingSuffixEscaped,_=_t_interpolation.nestingOptionsSeparator,A=_t_interpolation.maxReplaces,x=_t_interpolation.alwaysFormat;this.escape=a!==void 0?a:kNt,this.escapeValue=r!==void 0?r:!0,this.useRawValueToEscape=i!==void 0?i:!1,this.prefix=n?Lh(n):o||"{{",this.suffix=s?Lh(s):u||"}}",this.formatSeparator=c||",",this.unescapePrefix=p?"":l||"-",this.unescapeSuffix=this.unescapePrefix?"":p||"",this.nestingPrefix=m?Lh(m):f||Lh("$t("),this.nestingSuffix=g?Lh(g):h||Lh(")"),this.nestingOptionsSeparator=_||",",this.maxReplaces=A||1e3,this.alwaysFormat=x!==void 0?x:!1,this.resetRegExp()}},{key:"reset",value:function reset(){this.options&&this.init(this.options)}},{key:"resetRegExp",value:function resetRegExp(){var t=function(a,r){return(a==null?void 0:a.source)===r?(a.lastIndex=0,a):new RegExp(r,"g")};this.regexp=t(this.regexp,"".concat(this.prefix,"(.+?)").concat(this.suffix)),this.regexpUnescape=t(this.regexpUnescape,"".concat(this.prefix).concat(this.unescapePrefix,"(.+?)").concat(this.unescapeSuffix).concat(this.suffix)),this.nestingRegexp=t(this.nestingRegexp,"".concat(this.nestingPrefix,"(.+?)").concat(this.nestingSuffix))}},{key:"interpolate",value:function interpolate(t,a,r,i){var _this=this;var f;var n,o,s,u=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},c=function(g){if(g.indexOf(_this.formatSeparator)<0){var x=d5e(a,u,g,_this.options.keySeparator,_this.options.ignoreJSONStructure);return _this.alwaysFormat?_this.format(x,void 0,r,_object_spread_props(_object_spread({},i,a),{interpolationkey:g})):x}var h=g.split(_this.formatSeparator),_=h.shift().trim(),A=h.join(_this.formatSeparator).trim();return _this.format(d5e(a,u,_,_this.options.keySeparator,_this.options.ignoreJSONStructure),A,r,_object_spread_props(_object_spread({},i,a),{interpolationkey:_}))};this.resetRegExp();var p=(i==null?void 0:i.missingInterpolationHandler)||this.options.missingInterpolationHandler,l=((f=i==null?void 0:i.interpolation)==null?void 0:f.skipOnVariables)!==void 0?i.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables;return[{regex:this.regexpUnescape,safeValue:function(g){return Eq(g)}},{regex:this.regexp,safeValue:function(g){return _this.escapeValue?Eq(_this.escape(g)):Eq(g)}}].forEach(function(g){for(s=0;n=g.regex.exec(t);){var h=n[1].trim();if(o=c(h),o===void 0)if(typeof p=="function"){var A=p(t,n,i);o=ha(A)?A:""}else if(i&&Object.prototype.hasOwnProperty.call(i,h))o="";else if(l){o=n[0];continue}else _this.logger.warn("missed to pass in variable ".concat(h," for interpolating ").concat(t)),o="";else!ha(o)&&!_this.useRawValueToEscape&&(o=i5e(o));var _=g.safeValue(o);if(t=t.replace(n[0],_),l?(g.regex.lastIndex+=o.length,g.regex.lastIndex-=n[0].length):g.regex.lastIndex=0,s++,s>=_this.maxReplaces)break}}),t}},{key:"nest",value:function nest(t,a){var _this=this;var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i,n,o,s=function(u,c){var h;var p=_this.nestingOptionsSeparator;if(u.indexOf(p)<0)return u;var l=u.split(new RegExp("".concat(p,"[ ]*{"))),m="{".concat(l[1]);u=l[0],m=_this.interpolate(m,o);var f=m.match(/'/g),g=m.match(/"/g);(((h=f==null?void 0:f.length)!=null?h:0)%2===0&&!g||g.length%2!==0)&&(m=m.replace(/'/g,'"'));try{o=JSON.parse(m),c&&(o=_object_spread({},c,o))}catch(_){return _this.logger.warn("failed parsing options string in nesting for key ".concat(u),_),"".concat(u).concat(p).concat(m)}return o.defaultValue&&o.defaultValue.indexOf(_this.prefix)>-1&&delete o.defaultValue,u};for(;i=this.nestingRegexp.exec(t);){var u=[];o=_object_spread({},r),o=o.replace&&!ha(o.replace)?o.replace:o,o.applyPostProcessor=!1,delete o.defaultValue;var c=!1;if(i[0].indexOf(this.formatSeparator)!==-1&&!/{.*}/.test(i[1])){var p=i[1].split(this.formatSeparator).map(function(l){return l.trim()});i[1]=p.shift(),u=p,c=!0}if(n=a(s.call(this,i[1].trim(),o),o),n&&i[0]===t&&!ha(n))return n;ha(n)||(n=i5e(n)),n||(this.logger.warn("missed to resolve ".concat(i[1]," for nesting ").concat(t)),n=""),c&&(n=u.reduce(function(p,l){return _this.format(p,l,r.lng,_object_spread_props(_object_spread({},r),{interpolationkey:i[1].trim()}))},n.trim())),t=t.replace(i[0],n),this.regexp.lastIndex=0}return t}}]);return Mq1}(),TNt=function(e){var t=e.toLowerCase().trim(),a={};if(e.indexOf("(")>-1){var r=e.split("(");t=r[0].toLowerCase().trim();var i=r[1].substring(0,r[1].length-1);t==="currency"&&i.indexOf(":")<0?a.currency||(a.currency=i.trim()):t==="relativetime"&&i.indexOf(":")<0?a.range||(a.range=i.trim()):i.split(";").forEach(function(o){if(o){var _o_split=_to_array(o.split(":")),s=_o_split[0],u=_o_split.slice(1),c=u.join(":").trim().replace(/^'+|'+$/g,""),p=s.trim();a[p]||(a[p]=c),c==="false"&&(a[p]=!1),c==="true"&&(a[p]=!0),isNaN(c)||(a[p]=parseInt(c,10))}})}return{formatName:t,formatOptions:a}},$h=function(e){var t={};return function(a,r,i){var n=i;i&&i.interpolationkey&&i.formatParams&&i.formatParams[i.interpolationkey]&&i[i.interpolationkey]&&(n=_object_spread_props(_object_spread({},n),_define_property({},i.interpolationkey,void 0)));var o=r+JSON.stringify(n),s=t[o];return s||(s=e(gk(r),i),t[o]=s),s(a)}},Pq=/*#__PURE__*/function(){function Pq1(){_class_call_check(this,Pq1);var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};this.logger=Uc.create("formatter"),this.options=t,this.formats={number:$h(function(a,r){var i=new Intl.NumberFormat(a,_object_spread({},r));return function(n){return i.format(n)}}),currency:$h(function(a,r){var i=new Intl.NumberFormat(a,_object_spread_props(_object_spread({},r),{style:"currency"}));return function(n){return i.format(n)}}),datetime:$h(function(a,r){var i=new Intl.DateTimeFormat(a,_object_spread({},r));return function(n){return i.format(n)}}),relativetime:$h(function(a,r){var i=new Intl.RelativeTimeFormat(a,_object_spread({},r));return function(n){return i.format(n,r.range||"day")}}),list:$h(function(a,r){var i=new Intl.ListFormat(a,_object_spread({},r));return function(n){return i.format(n)}})},this.init(t)}_create_class(Pq1,[{key:"init",value:function init(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{interpolation:{}};this.formatSeparator=a.interpolation.formatSeparator||","}},{key:"add",value:function add(t,a){this.formats[t.toLowerCase().trim()]=a}},{key:"addCached",value:function addCached(t,a){this.formats[t.toLowerCase().trim()]=$h(a)}},{key:"format",value:function format(t,a,r){var _this=this;var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},n=a.split(this.formatSeparator);if(n.length>1&&n[0].indexOf("(")>1&&n[0].indexOf(")")<0&&n.find(function(s){return s.indexOf(")")>-1})){var s=n.findIndex(function(u){return u.indexOf(")")>-1});n[0]=[n[0]].concat(_to_consumable_array(n.splice(1,s))).join(this.formatSeparator)}return n.reduce(function(s,u){var l;var _TNt=TNt(u),c=_TNt.formatName,p=_TNt.formatOptions;if(_this.formats[c]){var m=s;try{var _$f=((l=i==null?void 0:i.formatParams)==null?void 0:l[i.interpolationkey])||{},g=_$f.locale||_$f.lng||i.locale||i.lng||r;m=_this.formats[c](s,g,_object_spread({},p,i,_$f))}catch(f){_this.logger.warn(f)}return m}else _this.logger.warn("there was no format function for ".concat(c));return s},t)}}]);return Pq1}(),MNt=function(e,t){e.pending[t]!==void 0&&(delete e.pending[t],e.pendingCount--)},Rq=/*#__PURE__*/function(Gh1){_inherits(Rq1,Gh1);function Rq1(t,a,r){_class_call_check(this,Rq1);var _this;var n,o;var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{};_this=_call_super(this,Rq1),_this.backend=t,_this.store=a,_this.services=r,_this.languageUtils=r.languageUtils,_this.options=i,_this.logger=Uc.create("backendConnector"),_this.waitingReads=[],_this.maxParallelReads=i.maxParallelReads||10,_this.readingCalls=0,_this.maxRetries=i.maxRetries>=0?i.maxRetries:5,_this.retryTimeout=i.retryTimeout>=1?i.retryTimeout:350,_this.state={},_this.queue=[],(o=(n=_this.backend)==null?void 0:n.init)==null||o.call(n,r,i.backend,i);return _this}_create_class(Rq1,[{key:"queueLoad",value:function queueLoad(t,a,r,i){var _this=this;var n={},o={},s={},u={};return t.forEach(function(c){var p=!0;a.forEach(function(l){var m="".concat(c,"|").concat(l);!r.reload&&_this.store.hasResourceBundle(c,l)?_this.state[m]=2:_this.state[m]<0||(_this.state[m]===1?o[m]===void 0&&(o[m]=!0):(_this.state[m]=1,p=!1,o[m]===void 0&&(o[m]=!0),n[m]===void 0&&(n[m]=!0),u[l]===void 0&&(u[l]=!0)))}),p||(s[c]=!0)}),(Object.keys(n).length||Object.keys(o).length)&&this.queue.push({pending:o,pendingCount:Object.keys(o).length,loaded:{},errors:[],callback:i}),{toLoad:Object.keys(n),pending:Object.keys(o),toLoadLanguages:Object.keys(s),toLoadNamespaces:Object.keys(u)}}},{key:"loaded",value:function loaded(t,a,r){var i=t.split("|"),n=i[0],o=i[1];a&&this.emit("failedLoading",n,o,a),!a&&r&&this.store.addResourceBundle(n,o,r,void 0,void 0,{skipCopy:!0}),this.state[t]=a?-1:2,a&&r&&(this.state[t]=0);var s={};this.queue.forEach(function(u){wNt(u.loaded,[n],o),MNt(u,t),a&&u.errors.push(a),u.pendingCount===0&&!u.done&&(Object.keys(u.loaded).forEach(function(c){s[c]||(s[c]={});var p=u.loaded[c];p.length&&p.forEach(function(l){s[c][l]===void 0&&(s[c][l]=!0)})}),u.done=!0,u.errors.length?u.callback(u.errors):u.callback())}),this.emit("loaded",s),this.queue=this.queue.filter(function(u){return!u.done})}},{key:"read",value:function read(t,a,r){var _this=this;var i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0,n=arguments.length>4&&arguments[4]!==void 0?arguments[4]:this.retryTimeout,o=arguments.length>5?arguments[5]:void 0;if(!t.length)return o(null,{});if(this.readingCalls>=this.maxParallelReads){this.waitingReads.push({lng:t,ns:a,fcName:r,tried:i,wait:n,callback:o});return}this.readingCalls++;var s=function(c,p){if(_this.readingCalls--,_this.waitingReads.length>0){var l=_this.waitingReads.shift();_this.read(l.lng,l.ns,l.fcName,l.tried,l.wait,l.callback)}if(c&&p&&i<_this.maxRetries){setTimeout(function(){_this.read.call(_this,t,a,r,i+1,n*2,o)},n);return}o(c,p)},u=this.backend[r].bind(this.backend);if(u.length===2){try{var _$c=u(t,a);_$c&&typeof _$c.then=="function"?_$c.then(function(p){return s(null,p)}).catch(s):s(null,_$c)}catch(c){s(c)}return}return u(t,a,s)}},{key:"prepareLoading",value:function prepareLoading(t,a){var _this=this;var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),i&&i();ha(t)&&(t=this.languageUtils.toResolveHierarchy(t)),ha(a)&&(a=[a]);var n=this.queueLoad(t,a,r,i);if(!n.toLoad.length)return n.pending.length||i(),null;n.toLoad.forEach(function(o){_this.loadOne(o)})}},{key:"load",value:function load(t,a,r){this.prepareLoading(t,a,{},r)}},{key:"reload",value:function reload(t,a,r){this.prepareLoading(t,a,{reload:!0},r)}},{key:"loadOne",value:function loadOne(t){var _this=this;var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=t.split("|"),i=r[0],n=r[1];this.read(i,n,"read",void 0,void 0,function(o,s){o&&_this.logger.warn("".concat(a,"loading namespace ").concat(n," for language ").concat(i," failed"),o),!o&&s&&_this.logger.log("".concat(a,"loaded namespace ").concat(n," for language ").concat(i),s),_this.loaded(t,o,s)})}},{key:"saveMissing",value:function saveMissing(t,a,r,i,n){var u,c,p,l,m;var o=arguments.length>5&&arguments[5]!==void 0?arguments[5]:{},s=arguments.length>6&&arguments[6]!==void 0?arguments[6]:function(){};if((c=(u=this.services)==null?void 0:u.utils)!=null&&c.hasLoadedNamespace&&!((l=(p=this.services)==null?void 0:p.utils)!=null&&l.hasLoadedNamespace(a))){this.logger.warn('did not save key "'.concat(r,'" as the namespace "').concat(a,'" was not yet loaded'),"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");return}if(!(r==null||r==="")){if((m=this.backend)!=null&&m.create){var f=_object_spread_props(_object_spread({},o),{isUpdate:n}),g=this.backend.create.bind(this.backend);if(g.length<6)try{var _$h;g.length===5?_$h=g(t,a,r,i,f):_$h=g(t,a,r,i),_$h&&typeof _$h.then=="function"?_$h.then(function(_){return s(null,_)}).catch(s):s(null,_$h)}catch(h){s(h)}else g(t,a,r,i,s,f)}!t||!t[0]||this.store.addResource(t[0],a,r,i)}}}]);return Rq1}(Gh),m5e=function(){return{debug:!1,initAsync:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:function(e){var t={};if(_type_of(e[1])=="object"&&(t=e[1]),ha(e[1])&&(t.defaultValue=e[1]),ha(e[2])&&(t.tDescription=e[2]),_type_of(e[2])=="object"||_type_of(e[3])=="object"){var a=e[3]||e[2];Object.keys(a).forEach(function(r){t[r]=a[r]})}return t},interpolation:{escapeValue:!0,format:function(e){return e},prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}},f5e=function(e){var t,a;return ha(e.ns)&&(e.ns=[e.ns]),ha(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),ha(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),((a=(t=e.supportedLngs)==null?void 0:t.indexOf)==null?void 0:a.call(t,"cimode"))<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),typeof e.initImmediate=="boolean"&&(e.initAsync=e.initImmediate),e},mk=function(){},PNt=function(e){Object.getOwnPropertyNames(Object.getPrototypeOf(e)).forEach(function(a){typeof e[a]=="function"&&(e[a]=e[a].bind(e))})},Tf=/*#__PURE__*/function(Gh1){_inherits(Tf1,Gh1);function Tf1(){_class_call_check(this,Tf1);var _this;var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},a=arguments.length>1?arguments[1]:void 0;if(_this=_call_super(this,Tf1),_this.options=f5e(t),_this.services={},_this.logger=Uc,_this.modules={external:[]},PNt(_this),a&&!_this.isInitialized&&!t.isClone){if(!_this.options.initAsync)return _possible_constructor_return(_this,(_this.init(t,a),_this));setTimeout(function(){_this.init(t,a)},0)}return _this}_create_class(Tf1,[{key:"init",value:function init(){var _this=this;var t=this;var a=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;this.isInitializing=!0,typeof a=="function"&&(r=a,a={}),a.defaultNS==null&&a.ns&&(ha(a.ns)?a.defaultNS=a.ns:a.ns.indexOf("translation")<0&&(a.defaultNS=a.ns[0]));var i=m5e();this.options=_object_spread({},i,this.options,f5e(a)),this.options.interpolation=_object_spread({},i.interpolation,this.options.interpolation),a.keySeparator!==void 0&&(this.options.userDefinedKeySeparator=a.keySeparator),a.nsSeparator!==void 0&&(this.options.userDefinedNsSeparator=a.nsSeparator);var n=function(p){return p?typeof p=="function"?new p:p:null};if(!this.options.isClone){this.modules.logger?Uc.init(n(this.modules.logger),this.options):Uc.init(null,this.options);var p;this.modules.formatter?p=this.modules.formatter:p=Pq;var l=new _k(this.options);this.store=new hk(this.options.resources,this.options);var m=this.services;m.logger=Uc,m.resourceStore=this.store,m.languageUtils=l,m.pluralResolver=new Tq(l,{prepend:this.options.pluralSeparator,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),p&&(!this.options.interpolation.format||this.options.interpolation.format===i.interpolation.format)&&(m.formatter=n(p),m.formatter.init(m,this.options),this.options.interpolation.format=m.formatter.format.bind(m.formatter)),m.interpolator=new Mq(this.options),m.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},m.backendConnector=new Rq(n(this.modules.backend),m.resourceStore,m,this.options),m.backendConnector.on("*",function(f){var _t;for(var g=arguments.length,h=new Array(g>1?g-1:0),_=1;_1?g-1:0),_=1;_0&&p6[0]!=="dev"&&(this.options.lng=p6[0])}!this.services.languageDetector&&!this.options.lng&&this.logger.warn("init: no languageDetector is used and no lng is defined"),["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(function(p){_this[p]=function(){var _t_store;return(_t_store=t.store)[p].apply(_t_store,arguments)}}),["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(function(p){_this[p]=function(){var _t_store;return(_t_store=t.store)[p].apply(_t_store,arguments),t}});var u=Vv(),c=function(){var p=function(l,m){_this.isInitializing=!1,_this.isInitialized&&!_this.initializedStoreOnce&&_this.logger.warn("init: i18next is already initialized. You should call init just once!"),_this.isInitialized=!0,_this.options.isClone||_this.logger.log("initialized",_this.options),_this.emit("initialized",_this.options),u.resolve(m),r(l,m)};if(_this.languages&&!_this.isInitialized)return p(null,_this.t.bind(_this));_this.changeLanguage(_this.options.lng,p)};return this.options.resources||!this.options.initAsync?c():setTimeout(c,0),u}},{key:"loadResources",value:function loadResources(t){var _this=this;var n,o;var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:mk,i=ha(t)?t:this.language;if(typeof t=="function"&&(r=t),!this.options.resources||this.options.partialBundledLanguages){if((i==null?void 0:i.toLowerCase())==="cimode"&&(!this.options.preload||this.options.preload.length===0))return r();var s=[],u=function(c){if(!c||c==="cimode")return;_this.services.languageUtils.toResolveHierarchy(c).forEach(function(l){l!=="cimode"&&s.indexOf(l)<0&&s.push(l)})};i?u(i):this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(function(p){return u(p)}),(o=(n=this.options.preload)==null?void 0:n.forEach)==null||o.call(n,function(c){return u(c)}),this.services.backendConnector.load(s,this.options.ns,function(c){!c&&!_this.resolvedLanguage&&_this.language&&_this.setResolvedLanguage(_this.language),r(c)})}else r(null)}},{key:"reloadResources",value:function reloadResources(t,a,r){var i=Vv();return typeof t=="function"&&(r=t,t=void 0),typeof a=="function"&&(r=a,a=void 0),t||(t=this.languages),a||(a=this.options.ns),r||(r=mk),this.services.backendConnector.reload(t,a,function(n){i.resolve(),r(n)}),i}},{key:"use",value:function use(t){if(!t)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!t.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return t.type==="backend"&&(this.modules.backend=t),(t.type==="logger"||t.log&&t.warn&&t.error)&&(this.modules.logger=t),t.type==="languageDetector"&&(this.modules.languageDetector=t),t.type==="i18nFormat"&&(this.modules.i18nFormat=t),t.type==="postProcessor"&&h5e.addPostProcessor(t),t.type==="formatter"&&(this.modules.formatter=t),t.type==="3rdParty"&&this.modules.external.push(t),this}},{key:"setResolvedLanguage",value:function setResolvedLanguage(t){if(!(!t||!this.languages)&&!(["cimode","dev"].indexOf(t)>-1))for(var a=0;a-1)&&this.store.hasLanguageSomeTranslations(r)){this.resolvedLanguage=r;break}}}},{key:"changeLanguage",value:function changeLanguage(t,a){var _this=this;var r=this;this.isLanguageChangingTo=t;var i=Vv();this.emit("languageChanging",t);var n=function(u){_this.language=u,_this.languages=_this.services.languageUtils.toResolveHierarchy(u),_this.resolvedLanguage=void 0,_this.setResolvedLanguage(u)},o=function(u,c){c?(n(c),_this.translator.changeLanguage(c),_this.isLanguageChangingTo=void 0,_this.emit("languageChanged",c),_this.logger.log("languageChanged",c)):_this.isLanguageChangingTo=void 0,i.resolve(function(){var _r1;return(_r1=r).t.apply(_r1,arguments)}),a&&a(u,function(){var _r1;return(_r1=r).t.apply(_r1,arguments)})},s=function(u){var p,l;!t&&!u&&_this.services.languageDetector&&(u=[]);var c=ha(u)?u:_this.services.languageUtils.getBestMatchFromCodes(u);c&&(_this.language||n(c),_this.translator.language||_this.translator.changeLanguage(c),(l=(p=_this.services.languageDetector)==null?void 0:p.cacheUserLanguage)==null||l.call(p,c)),_this.loadResources(c,function(m){o(m,c)})};return!t&&this.services.languageDetector&&!this.services.languageDetector.async?s(this.services.languageDetector.detect()):!t&&this.services.languageDetector&&this.services.languageDetector.async?this.services.languageDetector.detect.length===0?this.services.languageDetector.detect().then(s):this.services.languageDetector.detect(s):s(t),i}},{key:"getFixedT",value:function getFixedT(t,a,r){var i=this;var n=function n10(o,s){var u;if((typeof s==="undefined"?"undefined":_type_of(s))!="object"){for(var c=arguments.length,p=new Array(c>2?c-2:0),l=2;l1&&arguments[1]!==void 0?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;var r=a.lng||this.resolvedLanguage||this.languages[0],i=this.options?this.options.fallbackLng:!1,n=this.languages[this.languages.length-1];if(r.toLowerCase()==="cimode")return!0;var o=function(s,u){var c=_this.services.backendConnector.state["".concat(s,"|").concat(u)];return c===-1||c===0||c===2};if(a.precheck){var s=a.precheck(this,o);if(s!==void 0)return s}return!!(this.hasResourceBundle(r,t)||!this.services.backendConnector.backend||this.options.resources&&!this.options.partialBundledLanguages||o(r,t)&&(!i||o(n,t)))}},{key:"loadNamespaces",value:function loadNamespaces(t,a){var _this=this;var r=Vv();return this.options.ns?(ha(t)&&(t=[t]),t.forEach(function(i){_this.options.ns.indexOf(i)<0&&_this.options.ns.push(i)}),this.loadResources(function(i){r.resolve(),a&&a(i)}),r):(a&&a(),Promise.resolve())}},{key:"loadLanguages",value:function loadLanguages(t,a){var _this=this;var r=Vv();ha(t)&&(t=[t]);var i=this.options.preload||[],n=t.filter(function(o){return i.indexOf(o)<0&&_this.services.languageUtils.isSupportedCode(o)});return n.length?(this.options.preload=i.concat(n),this.loadResources(function(o){r.resolve(),a&&a(o)}),r):(a&&a(),Promise.resolve())}},{key:"dir",value:function dir(t){var i,n;if(t||(t=this.resolvedLanguage||(((i=this.languages)==null?void 0:i.length)>0?this.languages[0]:this.language)),!t)return"rtl";var a=["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"],r=((n=this.services)==null?void 0:n.languageUtils)||new _k(m5e());return a.indexOf(r.getLanguagePartFromCode(t))>-1||t.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}},{key:"cloneInstance",value:function cloneInstance(){var _this=this;var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:mk,r=t.forkResourceStore;r&&delete t.forkResourceStore;var i=_object_spread_props(_object_spread({},this.options,t),{isClone:!0}),n=new Tf(i);if((t.debug!==void 0||t.prefix!==void 0)&&(n.logger=n.logger.clone(t)),["store","services","language"].forEach(function(s){n[s]=_this[s]}),n.services=_object_spread({},this.services),n.services.utils={hasLoadedNamespace:n.hasLoadedNamespace.bind(n)},r){var s=Object.keys(this.store.data).reduce(function(u,c){return u[c]=_object_spread({},_this.store.data[c]),Object.keys(u[c]).reduce(function(p,l){return p[l]=_object_spread({},u[c][l]),p},{})},{});n.store=new hk(s,i),n.services.resourceStore=n.store}return n.translator=new zh(n.services,i),n.translator.on("*",function(s){var _n1;for(var u=arguments.length,c=new Array(u>1?u-1:0),p=1;p0&&arguments[0]!==void 0?arguments[0]:{},a=arguments.length>1?arguments[1]:void 0;return new Tf(t,a)}}]);return Tf1}(Gh),wn=Tf.createInstance();wn.createInstance=Tf.createInstance;var KUa=wn.createInstance,JUa=wn.dir,ZUa=wn.init,YUa=wn.loadResources,XUa=wn.reloadResources,eGa=wn.use,tGa=wn.changeLanguage,aGa=wn.getFixedT,rGa=wn.t,iGa=wn.exists,nGa=wn.setDefaultNamespace,oGa=wn.hasLoadedNamespace,sGa=wn.loadNamespaces,uGa=wn.loadLanguages;var xk={errors:{filenameUnsupportedChars:"File {{path}} contains unsupported characters: {{chars}}"},settings:{language:{name:"Language",desc:"Select interface language",auto:"Auto detect"},account:{name:"Account",desc:"Enter your WebDAV account",placeholder:"Enter your account"},credential:{name:"Credential",desc:"Enter your WebDAV credential",placeholder:"Enter your credential"},checkConnection:{name:"Check connection",desc:"Click to check WebDAV connection",success:"WebDAV connection successful",failure:"WebDAV connection failed",successButton:"Connected ✓",failureButton:"Failed \xd7"},remoteDir:{name:"Remote directory",desc:"Enter the remote directory",placeholder:"Enter the remote directory"},login:{name:"Login",success:"Login successful",failure:"Login failed, please try again"},loginMode:{name:"Login mode",manual:"Manual input",sso:"Single sign-on"},enterpriseBaseUrl:{name:"Nutstore Enterprise",desc:"Optional Base URL for Nutstore Enterprise. Leave empty to use the default endpoint. Example: https://dav.jianguoyun.com",action:"Set",modalTitle:"Set Nutstore Enterprise Base URL",placeholder:"For example https://dav.jianguoyun.com",invalid:"Invalid Base URL",invalidWithReason:"Invalid Base URL: {{reason}}",errors:{invalidFormat:"enter a complete server address, for example: https://dav.jianguoyun.com",unsupportedProtocol:"the address must start with http:// or https://"}},ssoStatus:{loggedIn:"Logged in",notLoggedIn:"Not logged in",logout:"Logout",logoutSuccess:"Logged out successfully"},useGitStyle:{name:"Use git-style conflict markers",desc:"Use <<<<<<< and >>>>>>> markers for conflicts instead of HTML tags"},backupWarning:{name:"Backup warning",desc:"⚠️ Note: Sync process will modify or delete local files. Please backup important files before syncing."},conflictStrategy:{name:"Conflict resolution strategy",desc:"Choose how to resolve file conflicts. \nNote: We recommend backing up important files before using auto-merge to prevent data loss.",diffMatchPatch:"Smart merge (recommended)",latestTimestamp:"Use latest version",skip:"Skip conflicts",diffMatchPatchOrSkip:"Smart merge, skip if unresolvable",localPriority:"Local priority (overwrite server)",serverPriority:"Server priority (overwrite local)"},confirmBeforeSync:{name:"Confirm before sync",desc:"Show pending tasks and execute after confirmation"},confirmBeforeDeleteInAutoSync:{name:"Confirm before deleting files during auto-sync",desc:"Show a confirmation dialog when local files are about to be deleted during auto-sync, allowing you to choose to delete or re-upload them"},realtimeSync:{name:"Real-time sync",desc:"Automatically sync changes as soon as files are modified"},syncMode:{name:"Sync mode",desc:"Choose between strict or loose sync mode. Loose mode is recommended for users with many files for faster syncing. In loose mode, files with the same name and equal size that have no sync record will be ignored.",strict:"Strict",loose:"Loose"},syncPolicy:{name:"Sync policy",desc:"Controls how data is reconciled between your device and the cloud. Override and revert policies delete extra files on the target side.",twoWay:"Two Way",sendOnly:"Send Only",sendOnlyOverrideChanges:"Send Only: Override Changes",receiveOnly:"Receive Only",receiveOnlyRevertLocalChanges:"Receive Only: Revert Local Changes",modal:{title:"Confirm sync policy",twoWayDesc:"Local and cloud sync in both directions — additions and deletions on either side are applied to the other.\nIf the same file is edited on both sides, conflicts are resolved by your configured strategy.",sendOnlyDesc:"Send all local changes (additions, modifications, deletions) to the cloud.\n\n• Local new/modified files → uploaded to the cloud\n• Files deleted locally with no cloud changes → removed from the cloud\n• Cloud-only new or modified files → preserved\n• Deleted locally while the cloud also has changes → skipped (to protect cloud edits)\n\nBest for: local as source of truth, cloud as secondary.",sendOnlyOverrideChangesDesc:"Overwrite the cloud with the full current state of your local vault.\nFiles that exist on the cloud but not locally will be deleted.\nBest when you need to force the cloud to converge to local.",receiveOnlyDesc:"Receive all cloud changes (additions, modifications, deletions) into your local vault.\n\n• Cloud new/modified files → downloaded to local\n• Files deleted on the cloud with no local changes → removed from local\n• Local-only new or modified files → preserved\n• Deleted on the cloud while local also has changes → skipped (to protect local edits)\n\nBest for: read-only devices, or cloud as source of truth.",receiveOnlyRevertLocalChangesDesc:"Revert your local vault to the full current state of the cloud.\nFiles that exist locally but not on the cloud will be deleted.\nBest for read-only devices or when the cloud must be the source of truth.",confirm:"Confirm",cancel:"Cancel"}},startupSyncDelay:{name:"Auto-sync on startup",desc:"Set the number of seconds after startup to automatically perform a sync. Set to 0 to disable auto-sync on startup.",placeholder:"Enter seconds (e.g., 5, 0 to disable)",invalidValue:"Invalid value, reset to 0",exceedsMax:"Value exceeds maximum limit of {{max}} seconds (1 day), automatically adjusted"},autoSyncInterval:{name:"Auto-sync interval",desc:"Set the interval for automatic background synchronization (in minutes). Set to 0 to disable automatic sync.",placeholder:"Enter minutes (e.g., 5, 0 to disable)",invalidValue:"Invalid value, reset to 0",exceedsMax:"Value exceeds maximum limit of {{max}} minutes (1 day), automatically adjusted"},sections:{account:"Account",common:"General",filters:"Filter rules",ai:"AI"},ai:{saved:"AI settings saved",none:"Not set",unnamedProvider:"Unnamed provider",unnamedModel:"Unnamed model",defaultProvider:{name:"Default provider",desc:"Optional provider selected for new chat sessions"},defaultModel:{name:"Default model",desc:"Optional model selected for new chat sessions"},nutstoreLlmGateway:{name:"Nutstore AI (Experimental)",providerName:"Nutstore",desc:"Authorize to use models provided by Nutstore.",pendingDesc:"Finish authorization in your browser. Current code: {{code}}",connectedDesc:"Authorized with {{count}} model(s) available.",authorize:"Authorize",authorizing:"Authorizing...",openAuthorizationPage:"Open authorization page",cancelAuthorization:"Cancel authorization",authorized:"Nutstore AI authorized",disconnect:"Disconnect",disconnected:"Nutstore AI disconnected",refreshModels:"Refresh",modelsRefreshed:"Models refreshed",betaModal:{title:"Feature in Beta",message:"Nutstore AI is currently in beta and not yet available to all users. If you are not on the beta list, you may not be able to use the feature after authorizing. We are gradually opening access — please check back later.",cancel:"Cancel",confirm:"I understand, continue"},errors:{authorizationRequired:"Authorize Nutstore AI first",authorizationExpired:"Nutstore AI authorization expired. Start again.",authorizationFailed:"Nutstore AI authorization failed: {{code}} {{message}}",missingClientId:"Missing LLM_GATEWAY_CLIENT_ID. Nutstore AI authorization cannot start.",modelsFailed:"Failed to fetch Nutstore AI models: {{status}}",emptyModels:"Nutstore AI did not return any available models",refreshFailed:"Failed to refresh Nutstore AI models"}},providers:{name:"Providers",desc:"Manage available AI providers",summary:"{{count}} provider(s) configured",manage:"Manage providers",add:"Add provider",refreshPresetName:"Get latest model list",refreshPresetDesc:"Get the latest model list.",refreshPresetModels:"Get model list",refreshPresetModelsLoading:"Fetching...",refreshPresetModelsSuccess:"Fetched ✓ providers {{providers}} models {{models}}",refreshPresetModelsFailure:"Failed \xd7",presetModelsRefreshed:"Latest model list fetched",presetModelsRefreshFailed:"Update failed. Continuing with local/built-in model list.",presetModelsRefreshFailedWithReason:"Update failed. Continuing with local/built-in model list: {{reason}}",empty:"No provider configured yet.",openaiDefault:"OpenAI default endpoint",presetCustom:"Custom (OpenAI Compatible)",updateModels:"Update models",updateModelsHint:"{{count}} preset model(s) can be added to this provider.",updateModelsSuccess:"{{count}} model(s) added"},provider:{name:"Provider name",desc:"Label shown in the chatbox",baseUrl:{name:"Base URL",desc:"Optional override, for example https://api.openai.com/v1"},apiKey:{name:"API key",desc:"Secret used for requests"},allowBrowserCors:{name:"Allow browser CORS requests",desc:"Prefer native browser fetch for providers that support CORS, enabling streaming output"}},models:{name:"Models",desc:"Models available under this provider",add:"Add model",empty:"No model configured yet."},model:{id:"Model ID",idDesc:"Model identifier sent to the API (e.g. gpt-4o)",inputModalities:"Input modalities"},modals:{confirmDeleteLabel:"Confirm",providers:{title:"Providers",updateModelsTitle:"Sync preset models",updateModelsDesc:"{{count}} model(s) will be added to {{provider}}. Please confirm the new models below:",updateModelsConfirm:"Add models"},provider:{createTitle:"Create provider",editTitle:"Edit provider",edit:"Edit",saved:"Provider saved",deleted:"Provider deleted",corsConfirmTitle:"Enable browser CORS requests",corsConfirmMessage:"Not every provider allows direct browser cross-origin access. When enabled, the plugin will prefer native browser fetch to support streaming output. If this provider stops working afterward, return here and turn this option off.",corsConfirmEnable:"Enable"},model:{createTitle:"Create model",editTitle:"Edit model",edit:"Edit",deleted:"Model deleted"}},yolo:{name:"Full access",desc:"⚠️ When enabled, AI can read and write vault files directly without user confirmation"},errors:{saveFailed:"Failed to save AI settings",saveFailedWithReason:"Failed to save AI settings: {{reason}}",invalidProvidersConfig:"AI provider configuration is invalid. Please fix it in settings. Details: {{reason}}",emptyModelId:"Model ID cannot be empty",duplicateModelId:"A model with this ID already exists",emptyProviderId:"Provider name cannot be empty",duplicateProviderId:"A provider with this name already exists",reservedProviderId:"This provider name is reserved by Nutstore AI. Use another name.",providerNotFoundForProtocolOpen:"Provider not found. It may have been deleted or renamed: {{providerId}}",browserCorsFallbackToBuiltinTransport:"Browser CORS request failed. Temporarily fell back to the built-in request transport.",browserCorsFailedWithDisableLink:"Browser CORS request failed. [Open this provider and disable CORS]({{link}})."}},logout:{confirmTitle:"Confirm logout",confirmMessage:"Are you sure you want to log out? You will need to log in again to continue syncing.",confirm:"Confirm logout",cancel:"Cancel"},help:{name:"How to get WebDAV account and credential?"},filters:{add:"Add rule",remove:"Remove",confirmRemove:"Confirm remove",edit:"Edit rules",save:"Save",cancel:"Cancel",placeholder:"e.g.: .DS_Store, *.pdf",exclude:{name:"Exclusion rules",desc:"Files/folders matching these patterns will NOT be synced."},include:{name:"Inclusion rules",desc:"Files/folders matching these patterns WILL be synced (if defined)."}},configDirSync:{name:"Config directory sync",desc:"Control whether {{configDir}} is included in sync.",none:"Do not sync",bookmarks:"Sync bookmarks only",all:"Sync all (experimental)",bookmarksTitle:"Enable bookmark sync",bookmarksDesc:"Only {{configDir}}/bookmarks.json will be synced. Other config files are not affected.",warnTitle:"Enable full config directory sync?",warnSyncs:"What syncs: plugin settings (data.json), plugin binaries (main.js), themes, snippets, and all other config files.",warnExcludes:"Auto-excluded: {{configDir}}/plugins/**/node_modules, {{configDir}}/plugins/**/.git, and {{configDir}}/plugins/**/.pnpm-store.",warnConflict:"Conflict resolution: when both sides have changes, the more recently modified version wins and the other side is overwritten.",warnRisk:"Risks: running Obsidian on multiple devices simultaneously increases conflict risk; config changes may require restarting Obsidian to take effect.",confirm:"Enable",cancel:"Cancel"},skipLargeFiles:{name:"Skip large files",desc:"Files exceeding this size will be skipped during synchronization. If sync issues occur, try lowering this value.",placeholder:"e.g., 10 MiB or 500 KiB",invalidFormat:'Invalid file size format. Please use formats like "10MB" or "500KB"',exceedsMaxSize:"File size exceeds maximum limit of 500MB"},mobileAppDownloadFileChunkSize:{name:"Mobile download chunk size",desc:"Chunk size used when downloading files on mobile. Smaller values reduce memory usage; larger values reduce request count.",placeholder:"e.g., 16 MiB",invalidFormat:'Invalid chunk size format. Please use formats like "16 MiB" or "512 KiB"',belowMinSize:"Chunk size cannot be below 64 KiB and was adjusted",exceedsMaxSize:"Chunk size cannot exceed 64 MiB and was adjusted"},log:{title:"Debug logs",name:"Console logs",desc:"View console output and debug information",saveToNote:"Save to note",savedToNote:"Logs saved to note: {{fileName}}",saveError:"Failed to save logs",clear:"Clear",cleared:"Console logs cleared",clearName:"Clear logs",clearDesc:"Delete all console output records"},troubleshooting:{title:"Troubleshooting"},cache:{title:"Cache management",clearName:"Clear local cache",clearDesc:"Delete local cache data stored on this device only. This action cannot be undone and will require rebuilding the cache before the next sync. Your Nutstore data remains intact.",clear:"Clear",confirm:"Confirm clear",cleared:"Cache cleared successfully",clearModal:{title:"Clear cache",description:"Select which cache types to clear. This action cannot be undone.",cancel:"Cancel",confirm:"Confirm clear",syncRecordCache:{name:"Sync record cache",desc:"Tracks synchronization status for each file."},blobCache:{name:"File snapshot cache",desc:"Stores file snapshots needed for comparing changes during sync."},traverseWebDAVCache:{name:"File scan cache",desc:"Stores remote folder structure to enable faster sync by fetching only changes. If you encounter file list anomalies or data inconsistencies after a plugin update, try clearing this cache. After clearing, the next sync will need to re-scan all remote files, which may take a while."},nothingSelected:"Please select at least one cache type to clear."},gcBlockedBySync:"Sync is currently running. Wait for sync to finish before running garbage collection.",gcBlockedByGc:"Garbage collection is already running. Please try again later.",generateBlobGarbageName:"GC stress test: generate garbage snapshots",generateBlobGarbageDesc:"Write {{count}} random file snapshots to blob cache (about {{sizeKiB}} KiB each) for GC testing.",generateBlobGarbage:"Generate garbage snapshots",generateBlobGarbageRunning:"Generating garbage snapshots...",generateBlobGarbageDone:"Generated {{count}} garbage snapshot(s)."}},aiPermission:{title:"AI Permission Request",sessionLabel:'Session "{{title}}" is requesting permission',message:"AI is requesting to perform the following file operations:",sessionScopeHint:'"Auto-approve this operation" only applies to this chat session and resets after restarting Obsidian.',allowOnce:"Approve",alwaysAllow:"Auto-approve this operation",deny:"Deny",denied:"Permission denied: {{summary}}",source:"Source",destination:"Destination",operations:{read:"read",write:"write",edit:"edit",delete:"delete",mkdir:"create directory",copy:"copy",move:"move"}},sync:{error:{localPathNotFound:"Local path not found: {{path}}",mergeNotSupported:"This file type is currently not supported for merging",failedToAutoMerge:"Failed to auto merge",failedToUploadMerged:"Failed to upload merged content",requestsTooFrequent:"Requests too frequent, please wait a few minutes and try again",accountNotConfigured:"Nutstore account not configured. Please configure your account in settings first.",ssoTokenInvalid:"Login has expired. Please log in again in settings."},requestsTooFrequent:"Requests too frequent, plugin will resume sync at {{time}}",preparing:"\uD83D\uDCCB Preparing sync",start:"⌛️ Starting sync",complete:"✅ Sync completed",completeWithFailed:"❌ Sync completed with {{failedCount}} failed tasks",failedWithError:"Sync failed with error: {{error}}",progress:"Sync progress: {{percent}}%",blockedBySync:"Sync is already running. Please try again later.",stoppingGcForSync:"Garbage collection is running. Stopping cleanup and starting sync.",startButton:"Start sync",stopButton:"Stop sync",hideButton:"Hide",closeButton:"Close",showProgressButton:"Show sync progress",notSyncing:"No sync currently in progress",percentComplete:"{{percent}}%",currentFile:"{{path}}",filePath:"{{path}}",progressTitle:"Sync progress",progressStats:"Completed: {{completed}} / {{total}} tasks",completedFilesTitle:"Completed tasks",syncingFiles:"Syncing files...",updatingCache:"Updating local cache...",cacheUpdated:"Local cache updated.",failedStatus:"Sync failed",cancelled:"Sync cancelled",suggestUseClientForManyTasks:"Tip: When there are many sync tasks, we recommend using the Nutstore client for better performance and stability. The plugin is more suitable for mobile use!",fileOp:{createLocalDir:"Create local directory",createRemoteDir:"Create remote directory",createRemoteDirs:"Create multi-level directories",download:"Download",filenameError:"Invalid path characters",merge:"Merge",removeLocal:"Remove local",removeRemote:"Remove remote",removeRemoteRecursively:"Remove remote recursively",sync:"Sync",upload:"Upload",noop:"Skip",cleanRecord:"Clean record",skip:"Skip"},skipReason:{"file-too-large":"File too large","folder-contains-ignored-items":"Folder contains ignored items","conflict-in-send-only-mode":"Both local and cloud changed; send-only mode preserved the cloud version","conflict-in-receive-only-mode":"Both local and cloud changed; receive-only mode preserved the local version","deleted-locally-but-changed-remotely":"Deleted locally, but the cloud has changes; skipped to protect cloud edits","deleted-remotely-but-changed-locally":"Deleted on the cloud, but local has changes; skipped to protect local edits"},confirmModal:{title:"Sync confirmation",message:"⚠️ Please note:\n\n1. Sync operation may modify or delete local files\n2. We recommend backing up important files before syncing\n3. In case of file conflicts, manual resolution may be required\n4. Initial sync will process all files and may take longer, please be patient\n\nAre you sure you want to start syncing?",confirm:"Confirm sync",cancel:"Cancel",remoteDir:"Remote directory: {{dir}}",strategy:"Sync strategy: {{strategy}}",policy:"Sync policy: {{policy}}"}},taskList:{title:"Sync task list",instruction:'Please review the tasks below. Click "Continue" to execute the selected tasks, or "Cancel" to skip this sync.',continue:"Continue",cancel:"Cancel"},deleteConfirm:{title:"Confirm local file deletion",instruction:"⚠️ The following local files will be deleted during auto-sync (because they were deleted remotely).\n\nCheck files to delete; unchecked files will be re-uploaded:",warningNotice:"Local files will be deleted, please confirm",select:"Select",filePath:"File path",deleteAndReupload:"Delete selected, re-upload unchecked",skipForNow:"Skip for now"},failedTasks:{title:"Failed sync tasks",instruction:"The following tasks failed during sync:",taskName:"Task",localPath:"Local path",errorMessage:"Error",close:"Close"},textAreaModal:{copy:"Copy",close:"Close",copied:"Text copied to clipboard"},time:{justNow:"just now",minutesAgo:"{{count}}min ago",hoursAgo:"{{count}}h ago",daysAgo:"{{count}}d ago",longAgo:"long ago"},chatbox:{title:"Chatbox",openCommand:"Open chatbox",addToContext:"Add to AI context",newChat:"New chat",sessionDeleted:"Session deleted",exportSaved:"Session exported: {{fileName}}",exportFailed:"Failed to export session",exportDialog:{title:"Export session",description:"Export to a Markdown file in your vault.",includeToolMessages:"Include tool call messages",cancel:"Cancel",confirm:"Export"},exportRole:{user:"User",tool:"Tool"},exportFrontmatter:{title:"title",sessionId:"session_id",exportedAt:"exported_at",createdAt:"created_at",updatedAt:"updated_at",model:"model",includeToolMessages:"include_tool_messages"},exportMeta:{messageTime:"Time",emptyContent:"(no text content)",toolCalls:"Tool calls",toolName:"Tool name",toolCallId:"Tool call ID"},repeatedToolCallsStopped:"The agent repeated the same tool call with the same arguments {{count}} times in a row and was stopped.",task:{cancelledSummary:"Task {{task}} was cancelled.",emptyResult:"Task completed but returned no summary."},ui:{history:{title:"History",sessionActions:"Session actions",sessionRunning:"Running"},actions:{exportAsMarkdown:"Export as Markdown",deleteSession:"Delete",cancel:"Cancel",selectFile:"Select File",send:"Send",stopRun:"Stop",newFragment:"New Fragment",compressContext:"Compress Context",closeTasks:"Close",cancelTask:"Cancel",copy:"Copy",deleteMessage:"Delete message",regenerateMessage:"Regenerate",recallMessage:"Recall",removeContextItem:"Remove"},tooltips:{contextUsage:"Context: {{used}}% used (window {{total}} tokens \xb7 total {{usedTokens}})"},labels:{provider:"Provider",model:"Model",tool:"Tool",toolCall:"Tool call",params:"Params",result:"Result",tasks:"Tasks",currentSession:"Current session",otherSessions:"Other sessions",queuedSubmissions:"Queued Submissions",depth:"Depth",sources:"Sources",contextArea:"Context",todoList:"Todo List"},states:{empty:"Start by sending a message",dragFilePrompt:"Drop to add file",thinking:"Thinking",compressing:"Compressing",processingTools:"Processing Tools",noProvider:"No provider",noModel:"No model",noTasks:"No tasks yet",copied:"Copied!",loadingContextItem:"Loading…",taskQueued:"Queued",taskRunning:"Running",taskCompleted:"Completed",taskFailed:"Failed",taskCancelled:"Cancelled",todoEmpty:"No todos"},placeholders:{input:"Type a message. Enter to send, Shift+Enter for newline"},dialogs:{deleteSession:{title:"Delete Session",message:"Delete this session permanently? This action cannot be undone.",confirm:"Delete"},deleteMessage:{title:"Delete Message",userConfirm:"This will delete this message and all following AI responses and tool results. This action cannot be undone.",assistantConfirm:"This will delete this AI response. This action cannot be undone.",toolConfirm:"This will delete this tool result and remove the corresponding tool call from the AI message. This action cannot be undone.",toolRestoreWarning:"After deletion, these file changes can no longer be restored by recalling the message.",confirm:"Delete"},newFragment:{title:"New Fragment",message:"This starts a fresh stretch of chat in the current conversation. Earlier messages are kept, but the AI will rely less on older parts of the conversation.",confirm:"Create fragment"},compressContext:{title:"Compress Context",message:"This asks the AI to condense the earlier conversation before continuing. It usually helps with long chats, but some details may be simplified.",confirm:"Compress"},regenerate:{title:"Regenerate",message:"This will regenerate this AI response in place. The original response will be replaced, and subsequent messages will be preserved. This action cannot be undone.",confirm:"Regenerate"},recall:{title:"Recall Message",message:"This will put the message content back into the input box and recall this message plus all following messages in the current fragment. This action cannot be undone.",onlySecondTitle:"Confirm Recall Only",onlySecondMessage:"This will recall the message without restoring related file changes. This action cannot be undone. Continue?",restoreSecondTitle:"Confirm Recall and Restore",restoreSecondMessage:"This will recall the message and restore related file changes. This action cannot be undone. Continue?",restoreConfirm:"Recall and restore files",onlyConfirm:"Recall only"}}},requestFailed:"Request failed",errors:{noProvider:"Select a provider before sending",apiKeyRequired:"The selected provider is missing an API key",providerBaseUrlRequired:"The selected OpenAI-compatible provider is missing a base URL",noModel:"Select a model before sending",unsupportedAttachmentType:"Unsupported file type: {{name}}",unknownTool:"Unknown tool: {{name}}",toolFieldRequired:"{{field}} is required",fileNotFound:"File not found: {{path}}",notFile:"Path is not a file: {{path}}",fileNotRead:"Editing failed — read {{path}} at least once before editing it.",editMatchNotFound:"Exact text to replace was not found in the file.",editMatchNotUnique:"Exact text to replace must match exactly once in the file.",sessionNotFound:"The target session no longer exists",taskDepthExceeded:"The task depth limit has been reached",taskSessionUnavailable:"The task session or model configuration is no longer available"}},taskSelectionVirtualList:{pagination:{first:"First",previous:"Prev",next:"Next",last:"Last",pageInfo:"Page {{ current }} / {{ total }}",totalItems:"Total {{ count }} items"},labels:{execute:"Execute",action:"Action",localPath:"Local Path",remotePath:"Remote Path"}},webdavExplorer:{actions:{newFolder:"New Folder",goBack:"Go Back",confirm:"Confirm",cancel:"Cancel"},labels:{currentPath:"Current Path"}}};var Ak={errors:{filenameUnsupportedChars:"文件 {{path}} 包含不支持的字符:{{chars}}"},settings:{language:{name:"语言",desc:"选择界面语言",auto:"自动检测"},account:{name:"账号",desc:"输入你的 WebDAV 账号",placeholder:"输入你的账号"},credential:{name:"凭证",desc:"输入你的 WebDAV 凭证",placeholder:"输入你的凭证"},remoteDir:{name:"远程目录",desc:"输入远程目录",placeholder:"输入远程目录"},checkConnection:{name:"检查连接",desc:"点击检查 WebDAV 连接",success:"WebDAV 连接成功",failure:"WebDAV 连接失败",successButton:"连接成功 ✓",failureButton:"连接失败 \xd7"},login:{name:"登录",success:"登录成功",failure:"登录失败,请重试"},useGitStyle:{name:"使用 Git 样式的冲突标记",desc:"启用后将使用 <<<<<<< 和 >>>>>>> 等标记来显示冲突,而不是 HTML 标记"},backupWarning:{name:"备份提醒",desc:"⚠️ 请注意:同步过程会修改或删除本地文件,建议在同步前备份重要文件。"},conflictStrategy:{name:"冲突解决策略",desc:"选择解决文件冲突的方式。\n注意:建议在使用自动合并功能前,先手动备份重要文件,以防数据丢失。",diffMatchPatch:"智能合并(推荐)",latestTimestamp:"使用最新版本",skip:"跳过冲突",diffMatchPatchOrSkip:"智能合并,无法合并时跳过",localPriority:"本地优先(覆盖服务器)",serverPriority:"服务器优先(覆盖本地)"},loginMode:{name:"登录方式",manual:"手动输入",sso:"单点登录"},ssoStatus:{loggedIn:"已登录",notLoggedIn:"未登录",logout:"退出登录",logoutSuccess:"已退出登录"},logout:{confirmTitle:"确认退出",confirmMessage:"确定要退出登录吗?退出后需要重新登录才能继续同步。",confirm:"确认退出",cancel:"取消"},help:{name:"如何获取 WebDAV 账号和凭证?"},enterpriseBaseUrl:{name:"企业版坚果云",desc:"可选配置企业版坚果云 Base URL,留空则使用默认地址。例如:https://dav.jianguoyun.com",action:"设置",modalTitle:"设置企业版坚果云 Base URL",placeholder:"例如 https://dav.jianguoyun.com",invalid:"Base URL 不合法",invalidWithReason:"Base URL 不合法:{{reason}}",errors:{invalidFormat:"请输入完整的服务器地址,例如:https://dav.jianguoyun.com",unsupportedProtocol:"地址需要以 http:// 或 https:// 开头"}},sections:{account:"账号设置",common:"通用设置",filters:"过滤规则",ai:"AI 设置"},ai:{saved:"AI 设置已保存",none:"未设置",unnamedProvider:"未命名模型提供商",unnamedModel:"未命名模型",defaultProvider:{name:"默认模型提供商",desc:"新建对话时可选的默认模型提供商"},defaultModel:{name:"默认模型",desc:"新建对话时可选的默认模型"},nutstoreLlmGateway:{name:"坚果云 AI(实验性)",providerName:"坚果云",desc:"授权后可使用坚果云提供的模型。",pendingDesc:"请在浏览器中完成授权,当前验证码:{{code}}",connectedDesc:"已授权,当前 {{count}} 个模型可用。",authorize:"授权",authorizing:"授权中...",openAuthorizationPage:"打开授权页",cancelAuthorization:"取消授权",authorized:"坚果云 AI 授权成功",disconnect:"断开",disconnected:"已断开坚果云 AI",refreshModels:"更新",modelsRefreshed:"模型列表已更新",betaModal:{title:"功能内测中",message:"坚果云 AI 目前处于内测阶段,尚未向所有用户开放。如果您不在内测名单中,授权后可能暂时无法使用相关功能,请继续等待,我们正在陆续开放中。",cancel:"取消",confirm:"我知道了,继续授权"},errors:{authorizationRequired:"请先授权坚果云 AI",authorizationExpired:"坚果云 AI 授权已过期,请重新发起授权",authorizationFailed:"坚果云 AI 授权失败:{{code}} {{message}}",missingClientId:"缺少 LLM_GATEWAY_CLIENT_ID,无法启动坚果云 AI 授权",modelsFailed:"获取坚果云 AI 模型失败:{{status}}",emptyModels:"坚果云 AI 没有返回可用模型",refreshFailed:"刷新坚果云 AI 模型失败"}},providers:{name:"模型提供商",desc:"管理可用的 AI 模型提供商",summary:"已配置 {{count}} 个模型提供商",manage:"管理模型提供商",add:"新增模型提供商",refreshPresetName:"获取最新模型列表",refreshPresetDesc:"可以获取最新的模型列表。",refreshPresetModels:"获取模型列表",refreshPresetModelsLoading:"获取中...",refreshPresetModelsSuccess:"提供商 {{providers}},模型 {{models}}",refreshPresetModelsFailure:"获取失败 \xd7",presetModelsRefreshed:"已获取最新模型列表",presetModelsRefreshFailed:"更新失败,继续使用本地/内置模型列表",presetModelsRefreshFailedWithReason:"更新失败,继续使用本地/内置模型列表:{{reason}}",empty:"当前还没有配置模型提供商。",openaiDefault:"使用 OpenAI 默认端点",presetCustom:"自定义(OpenAI Compatible)",updateModels:"更新",updateModelsHint:"预设中还有 {{count}} 个模型可同步到当前提供商。",updateModelsSuccess:"已增加 {{count}} 个模型"},provider:{name:"模型提供商名称",desc:"用于在 Chatbox 中显示的名称",baseUrl:{name:"Base URL",desc:"可选覆盖,例如 https://api.openai.com/v1"},apiKey:{name:"API Key",desc:"发送请求时使用的密钥"},allowBrowserCors:{name:"允许浏览器跨域请求",desc:"开启后将优先使用浏览器原生 fetch,可在支持的提供商上获得流式输出"}},models:{name:"模型",desc:"在当前模型提供商下可用的模型",add:"新增模型",empty:"当前模型提供商下还没有模型。"},model:{id:"模型 ID",idDesc:"请求 API 时使用的模型标识(如 gpt-4o)",inputModalities:"输入模态"},modals:{confirmDeleteLabel:"确认",providers:{title:"模型提供商管理",updateModelsTitle:"同步预设模型",updateModelsDesc:"将为 {{provider}} 增加 {{count}} 个模型,请确认以下新增项:",updateModelsConfirm:"确认增加"},provider:{createTitle:"新建提供商",editTitle:"编辑提供商",edit:"编辑",saved:"提供商已保存",deleted:"提供商已删除",corsConfirmTitle:"确认启用浏览器跨域请求",corsConfirmMessage:"并不是所有模型提供商都允许浏览器直接跨域访问。开启后将优先使用浏览器原生 fetch 以支持流式输出;如果之后发现该提供商无法使用,请回到这里关闭此开关。",corsConfirmEnable:"确认启用"},model:{createTitle:"新建模型",editTitle:"编辑模型",edit:"编辑",deleted:"模型已删除"}},yolo:{name:"完全访问权限",desc:"⚠️ 开启后,AI 可直接读写笔记库中的文件,无需用户确认"},errors:{saveFailed:"AI 设置保存失败",saveFailedWithReason:"AI 设置保存失败:{{reason}}",invalidProvidersConfig:"AI 模型提供商配置无效,请在设置中修正。详情:{{reason}}",emptyModelId:"模型 ID 不能为空",duplicateModelId:"已存在相同 ID 的模型",emptyProviderId:"模型提供商名称不能为空",duplicateProviderId:"已存在相同名称的模型提供商",reservedProviderId:"该模型提供商名称由坚果云 AI 保留,请使用其他名称",providerNotFoundForProtocolOpen:"未找到对应的模型提供商,可能已被删除或重命名:{{providerId}}",browserCorsFallbackToBuiltinTransport:"浏览器跨域请求失败,已临时回退到内置请求方式。",browserCorsFailedWithDisableLink:"浏览器跨域请求失败。[打开此提供商并关闭 CORS]({{link}})。"}},confirmBeforeSync:{name:"同步前确认",desc:"同步前显示待执行的任务列表,确认后再执行"},confirmBeforeDeleteInAutoSync:{name:"自动同步时删除文件前确认",desc:"自动同步过程中检测到本地文件将被删除时,弹出确认对话框让你选择删除或重新上传"},realtimeSync:{name:"实时同步",desc:"文件修改后自动进行同步"},syncMode:{name:"同步模式",desc:"建议在文件较多的情况下选择宽松模式,同步速度更快。宽松模式会忽略同名且大小相等但没有同步记录的文件。",strict:"严格",loose:"宽松"},syncPolicy:{name:"同步策略",desc:"控制本地与云端之间的数据协调方式。带覆盖或还原的策略会删除目标侧多余文件,请谨慎使用。",twoWay:"双向同步",sendOnly:"仅发送",sendOnlyOverrideChanges:"仅发送:覆盖云端变更",receiveOnly:"仅接收",receiveOnlyRevertLocalChanges:"仅接收:还原本地变更",modal:{title:"确认同步策略",twoWayDesc:"本地和云端互相同步,各自的新增和删除都会同步到对方。\n同一文件两端都改动时,按冲突策略处理。",sendOnlyDesc:"把本地的所有变更(新增、修改、删除)发送到云端。\n\n• 本地新增/修改的文件 → 上传到云端\n• 本地删除且云端未改动的文件 → 从云端删除\n• 云端独立新增或修改的文件 → 保留不动\n• 本地删除时云端也有改动 → 跳过该项(避免误删云端改动)\n\n适合:以本地为主、云端为辅的场景。",sendOnlyOverrideChangesDesc:"以本地当前完整状态覆盖云端。\n云端有但本地没有的文件会被删除。\n适合需要强制让云端重新收敛为本地状态时使用。",receiveOnlyDesc:"把云端的所有变更(新增、修改、删除)接收到本地。\n\n• 云端新增/修改的文件 → 下载到本地\n• 云端删除且本地未改动的文件 → 从本地删除\n• 本地独立新增或修改的文件 → 保留不动\n• 云端删除时本地也有改动 → 跳过该项(避免误删本地改动)\n\n适合:只读设备,或以云端为准的场景。",receiveOnlyRevertLocalChangesDesc:"以云端当前完整状态还原本地。\n本地有但云端没有的文件会被删除。\n适合只读设备,或需要强制以云端内容为准时使用。",confirm:"确认",cancel:"取消"}},startupSyncDelay:{name:"启动后自动同步",desc:"设置启动后第几秒自动执行一次同步。设置为 0 则禁用启动时自动同步。",placeholder:"输入秒数 (例如 5, 0 则禁用)",invalidValue:"无效的数值,已重置为 0",exceedsMax:"数值超过最大限制 {{max}} 秒(1天),已自动调整"},autoSyncInterval:{name:"定时自动同步",desc:"设置每隔多长时间在后台自动执行一次同步(分钟)。设置为 0 则禁用定时自动同步。",placeholder:"输入分钟数 (例如 5, 0 则禁用)",invalidValue:"无效的数值,已重置为 0",exceedsMax:"数值超过最大限制 {{max}} 分钟(1天),已自动调整"},filters:{add:"添加规则",remove:"删除",confirmRemove:"确认删除",edit:"编辑规则",save:"保存",cancel:"取消",placeholder:"例如: .DS_Store, *.pdf",exclude:{name:"排除规则",desc:"符合规则的文件/文件夹将不会被同步"},include:{name:"包含规则",desc:"符合规则的文件/文件夹会被同步,如果和排除规则有冲突,会优先选择包含规则。"}},configDirSync:{name:"配置目录同步",desc:"控制 {{configDir}} 目录是否参与同步。",none:"不同步",bookmarks:"仅同步书签",all:"同步全部(实验性)",bookmarksTitle:"启用书签同步",bookmarksDesc:"仅同步 {{configDir}}/bookmarks.json,其他配置文件不受影响。",warnTitle:"启用完整配置目录同步?",warnSyncs:"同步内容:插件设置(data.json)、插件二进制(main.js)、主题、代码片段等所有配置文件。",warnExcludes:"自动排除:{{configDir}}/plugins/**/node_modules、{{configDir}}/plugins/**/.git 和 {{configDir}}/plugins/**/.pnpm-store。",warnConflict:"冲突处理:两端同一文件均有修改时,保留修改时间较新的版本,另一端的修改将被覆盖。",warnRisk:"风险:多台设备同时运行 Obsidian 容易引发冲突;插件设置变更后可能需要重启 Obsidian 才能生效。",confirm:"启用",cancel:"取消"},skipLargeFiles:{name:"跳过大文件",desc:"同步时将跳过超过此大小的文件。如遇同步崩溃,可尝试降低此值。",placeholder:"例如:10 MiB 或 500 KiB",invalidFormat:'无效的文件大小格式,请使用如 "10MB" 或 "500KB" 的格式',exceedsMaxSize:"文件大小超过最大限制 500MB"},mobileAppDownloadFileChunkSize:{name:"移动端下载时分块",desc:"移动端下载文件时使用的分块大小。较小的值可降低内存占用;较大的值可减少请求次数,但是有可能导致软件崩溃。",placeholder:"例如:16 MiB",invalidFormat:'无效的分块大小格式,请使用如 "16 MiB" 或 "512 KiB" 的格式',belowMinSize:"分块大小不能小于 64 KiB,已自动调整",exceedsMaxSize:"分块大小不能超过 64 MiB,已自动调整"},log:{title:"调试日志",name:"控制台日志",desc:"查看控制台输出和调试信息",saveToNote:"保存到笔记",savedToNote:"日志已保存到笔记: {{fileName}}",saveError:"保存日志失败",clear:"清除",cleared:"控制台日志已清除",clearName:"清除日志",clearDesc:"删除所有控制台输出记录"},troubleshooting:{title:"故障排查"},cache:{title:"缓存管理",clearName:"清除本地缓存",clearDesc:"删除当前设备上的本地缓存数据。此操作无法撤销,会导致下次同步前需要重新建立缓存。仅影响当前设备,不会影响您在坚果云中的数据。",clear:"清除",confirm:"确认清除",cleared:"缓存已成功清除",clearModal:{title:"清除缓存",description:"选择需要清除的缓存类型。此操作无法撤销。",cancel:"取消",confirm:"确认清除",syncRecordCache:{name:"同步记录缓存",desc:"跟踪每个文件的同步状态。"},blobCache:{name:"文件快照缓存",desc:"存储用于同步时对比变化的文件快照。"},traverseWebDAVCache:{name:"文件扫描缓存",desc:"存储远程文件夹结构,下次同步时只需获取变化的部分,加快同步速度。如果插件更新后同步出现文件列表异常或数据不一致,可尝试清除此缓存。清除后下次同步需要重新扫描所有远程文件,可能需要较长时间。"},nothingSelected:"请至少选择一种缓存类型进行清除。"},gcBlockedBySync:"当前正在同步,请等待同步结束后再进行垃圾回收。",gcBlockedByGc:"垃圾回收正在进行中,请稍后再试。",generateBlobGarbageName:"GC 压测:生成垃圾快照",generateBlobGarbageDesc:"向 blob 缓存中写入 {{count}} 个随机文件快照(每个约 {{sizeKiB}} KiB),用于测试 GC 清理效果。",generateBlobGarbage:"生成垃圾快照",generateBlobGarbageRunning:"正在生成垃圾快照...",generateBlobGarbageDone:"已生成 {{count}} 个垃圾快照。"}},aiPermission:{title:"AI 权限请求",sessionLabel:"会话「{{title}}」正在请求权限",message:"AI 正在请求执行以下文件操作:",sessionScopeHint:"“自动同意该操作”仅在当前会话生效,重启 Obsidian 后将恢复询问。",allowOnce:"同意",alwaysAllow:"自动同意该操作",deny:"拒绝",denied:"操作已拒绝:{{summary}}",source:"源路径",destination:"目标路径",operations:{read:"读取",write:"写入",edit:"编辑",delete:"删除",mkdir:"创建目录",copy:"复制",move:"移动"}},sync:{error:{localPathNotFound:"本地路径未找到: {{path}}",mergeNotSupported:"该文件类型暂不支持合并",failedToAutoMerge:"自动合并失败",failedToUploadMerged:"上传合并内容失败",requestsTooFrequent:"请求过于频繁,请等待几分钟后再试",accountNotConfigured:"尚未配置坚果云账号,请先在设置中配置账号信息",ssoTokenInvalid:"登录已失效,请在设置中重新登录。"},requestsTooFrequent:"请求过于频繁,插件将在 {{time}} 后自动继续同步任务",preparing:"\uD83D\uDCCB 准备同步",start:"⌛️ 开始同步",complete:"✅ 同步完成",completeWithFailed:"❌ 同步完成,但有 {{failedCount}} 个任务失败",failedWithError:"同步失败,错误信息: {{error}}",progress:"同步进度: {{percent}}%",blockedBySync:"同步正在进行中,请稍后再试。",stoppingGcForSync:"检测到垃圾回收正在进行,正在停止清理并开始同步。",startButton:"开始同步",stopButton:"停止同步",hideButton:"隐藏",closeButton:"关闭",showProgressButton:"显示同步进度",notSyncing:"尚未开始同步",percentComplete:"{{percent}}%",currentFile:"{{path}}",filePath:"{{path}}",progressTitle:"同步进度",progressStats:"已完成: {{completed}} / {{total}} 个任务",completedFilesTitle:"已完成的任务",syncingFiles:"正在同步文件...",updatingCache:"正在更新本地缓存...",cacheUpdated:"本地缓存已更新。",failedStatus:"同步失败",cancelled:"同步已取消",suggestUseClientForManyTasks:"提示:当同步任务较多时,建议使用坚果云客户端同步,可获得更好的性能和稳定性,插件更适合在移动端使用!",fileOp:{createLocalDir:"创建本地目录",createRemoteDir:"创建远程目录",createRemoteDirs:"创建多级目录",download:"下载",filenameError:"路径含无效字符",merge:"合并",removeLocal:"删除本地",removeRemote:"删除远程",removeRemoteRecursively:"递归删除远程",sync:"同步",upload:"上传",noop:"跳过",cleanRecord:"清理记录",skip:"跳过"},skipReason:{"file-too-large":"文件过大","folder-contains-ignored-items":"文件夹包含被忽略的文件","conflict-in-send-only-mode":"本地和云端都已变更;当前为仅发送模式,已保留云端版本","conflict-in-receive-only-mode":"本地和云端都已变更;当前为仅接收模式,已保留本地版本","deleted-locally-but-changed-remotely":"本地已删除,但云端有修改;为避免误删云端改动,已跳过此项","deleted-remotely-but-changed-locally":"云端已删除,但本地有修改;为避免误删本地改动,已跳过此项"},confirmModal:{title:"同步确认",message:"⚠️ 请注意:\n\n1. 同步操作可能会修改或删除本地文件\n2. 建议在同步前手动备份重要文件\n3. 如果出现文件冲突,可能需要手动解决\n4. 首次同步需要处理所有文件,可能会比较慢,请耐心等待\n\n确定要开始同步吗?",confirm:"确认同步",cancel:"取消",remoteDir:"远程目录:{{dir}}",strategy:"同步策略:{{strategy}}",policy:"同步策略:{{policy}}"}},taskList:{title:"同步任务列表",instruction:'请检查以下待执行的任务。点击"继续"将执行选中的任务,点击"取消"则跳过本次同步。',continue:"继续",cancel:"取消"},deleteConfirm:{title:"确认删除本地文件",instruction:"⚠️ 在自动同步过程中检测到以下本地文件将被删除(因远程已删除)。\n\n勾选要删除的文件,未勾选的文件将重新上传到远程:",warningNotice:"检测到本地文件将被删除,请确认",select:"选择",filePath:"文件路径",deleteAndReupload:"删除选中的,重新上传未选中的",skipForNow:"暂时忽略"},failedTasks:{title:"同步失败任务",instruction:"以下任务在同步时失败:",taskName:"任务",localPath:"本地路径",errorMessage:"失败原因",close:"关闭"},textAreaModal:{copy:"复制",close:"关闭",copied:"文本已复制到剪贴板"},time:{justNow:"刚刚",minutesAgo:"{{count}}分钟前",hoursAgo:"{{count}}小时前",daysAgo:"{{count}}天前",longAgo:"很久前"},chatbox:{title:"Chatbox",openCommand:"打开 Chatbox",addToContext:"添加到 AI 上下文",newChat:"新对话",sessionDeleted:"会话已删除",exportSaved:"会话已导出:{{fileName}}",exportFailed:"导出会话失败",exportDialog:{title:"导出会话",description:"导出为 Markdown 文件并保存到笔记库。",includeToolMessages:"包含工具调用消息",cancel:"取消",confirm:"导出"},exportRole:{user:"用户",tool:"工具"},exportFrontmatter:{title:"标题",sessionId:"会话ID",exportedAt:"导出时间",createdAt:"创建时间",updatedAt:"更新时间",model:"模型",includeToolMessages:"包含工具消息"},exportMeta:{messageTime:"时间",emptyContent:"(无文本内容)",toolCalls:"工具调用",toolName:"工具名称",toolCallId:"工具调用 ID"},repeatedToolCallsStopped:"Agent 连续 {{count}} 次调用了完全相同的工具与参数,已停止继续调用。",task:{cancelledSummary:"任务 {{task}} 已取消。",emptyResult:"任务已完成,但没有返回摘要。"},ui:{history:{title:"历史",sessionActions:"会话操作",sessionRunning:"运行中"},actions:{exportAsMarkdown:"导出为 Markdown",deleteSession:"删除",cancel:"取消",selectFile:"选择文件",send:"发送",stopRun:"终止",newFragment:"新建段",compressContext:"压缩上下文",closeTasks:"关闭",cancelTask:"取消",copy:"复制",deleteMessage:"删除消息",regenerateMessage:"重新生成",recallMessage:"撤回",removeContextItem:"移除"},tooltips:{contextUsage:"上下文:已用 {{used}}%(窗口 {{total}} tokens \xb7 总计 {{usedTokens}})"},labels:{provider:"Provider",model:"Model",tool:"工具",toolCall:"工具调用",params:"参数",result:"结果",tasks:"任务",currentSession:"当前会话",otherSessions:"其他会话",queuedSubmissions:"排队内容",depth:"深度",sources:"来源",contextArea:"上下文",todoList:"待办列表"},states:{empty:"开始发送一条消息",dragFilePrompt:"松手以添加文件",thinking:"思考中",compressing:"压缩中",processingTools:"工具处理中",noProvider:"未选择 Provider",noModel:"未选择 Model",noTasks:"还没有任务",copied:"已复制",loadingContextItem:"加载中…",taskQueued:"排队中",taskRunning:"运行中",taskCompleted:"已完成",taskFailed:"失败",taskCancelled:"已取消",todoEmpty:"暂无待办"},placeholders:{input:"输入消息,Enter 发送,Shift+Enter 换行"},dialogs:{deleteSession:{title:"删除会话",message:"确认删除这个会话吗?删除后不可恢复。",confirm:"确认删除"},deleteMessage:{title:"删除消息",userConfirm:"此操作将删除该用户消息,以及其后所有 AI 回复和工具调用结果,无法恢复。",assistantConfirm:"此操作将删除该 AI 回复,无法恢复。",toolConfirm:"此操作将删除该工具调用结果,并从对应的 AI 消息中移除该工具调用记录,无法恢复。",toolRestoreWarning:"删除后将无法通过撤回消息恢复这些文件修改。",confirm:"确认删除"},newFragment:{title:"新建段",message:"这会清除 AI 的记忆,但界面上仍然保留之前的对话记录。",confirm:"新建段"},compressContext:{title:"压缩上下文",message:"这会让 AI 先整理前面的聊天内容,再继续当前对话。这样通常能减少长度带来的影响,但部分细节可能会被简化。",confirm:"开始压缩"},regenerate:{title:"重新生成",message:"此操作将重新生成该 AI 回复,原回复内容将被替换,其后的消息将被保留,无法恢复。",confirm:"重新生成"},recall:{title:"撤回消息",message:"此操作将把消息内容放回输入框,并撤回该消息及当前段中之后的所有消息,无法恢复。",onlySecondTitle:"确认仅撤回",onlySecondMessage:"将仅撤回消息,不还原相关修改。此操作无法恢复,确认继续吗?",restoreSecondTitle:"确认撤回并还原修改",restoreSecondMessage:"将撤回消息,并还原相关修改。此操作无法恢复,确认继续吗?",restoreConfirm:"撤回并还原修改",onlyConfirm:"仅撤回"}}},requestFailed:"请求失败",errors:{noProvider:"发送前请先选择模型提供商",apiKeyRequired:"当前模型提供商缺少 API Key",providerBaseUrlRequired:"当前 OpenAI-compatible 模型提供商缺少 Base URL",noModel:"发送前请先选择模型",unsupportedAttachmentType:"暂不支持该文件类型:{{name}}",unknownTool:"未知工具:{{name}}",toolFieldRequired:"{{field}} 为必填项",fileNotFound:"未找到文件:{{path}}",notFile:"该路径不是文件:{{path}}",fileNotRead:"编辑失败,请至少先读取一次 {{path}} 再编辑。",editMatchNotFound:"文件中未找到要替换的精确文本。",editMatchNotUnique:"要替换的精确文本必须且只能匹配一次。",sessionNotFound:"目标会话已不存在",taskDepthExceeded:"任务拆分深度已达到上限",taskSessionUnavailable:"任务对应的会话或模型配置已不可用"}},taskSelectionVirtualList:{pagination:{first:"首页",previous:"上一页",next:"下一页",last:"末页",pageInfo:"第 {{ current }} / {{ total }} 页",totalItems:"共 {{ count }} 项"},labels:{execute:"执行",action:"操作",localPath:"本地路径",remotePath:"远程路径"}},webdavExplorer:{actions:{newFolder:"新建文件夹",goBack:"返回上一层",confirm:"确定",cancel:"取消"},labels:{currentPath:"当前路径"}}};var DNt="translation",NNt={zh:{translation:Ak},en:{translation:xk}};wn.init({ns:["translation"],defaultNS:DNt,resources:NNt,fallbackLng:"en",interpolation:{escapeValue:!1}});var D=wn;var qa=/*#__PURE__*/function(){function qa1(){_class_call_check(this,qa1)}_create_class(qa1,[{key:"onload",value:function onload(){}},{key:"onunload",value:function onunload(){}}]);return qa1}();var ONt=(typeof global==="undefined"?"undefined":_type_of(global))=="object"&&global&&global.Object===Object&&global,vk=ONt;var FNt=(typeof self==="undefined"?"undefined":_type_of(self))=="object"&&self&&self.Object===Object&&self,qNt=vk||FNt||Function("return this")(),sr=qNt;var LNt=sr.Symbol,Du=LNt;var _5e=Object.prototype,$Nt=_5e.hasOwnProperty,UNt=_5e.toString,Jv=Du?Du.toStringTag:void 0;function GNt(e){var t=$Nt.call(e,Jv),a=e[Jv];try{e[Jv]=void 0;var r=!0}catch(n){}var i=UNt.call(e);return r&&(t?e[Jv]=a:delete e[Jv]),i}var x5e=GNt;var zNt=Object.prototype,jNt=zNt.toString;function HNt(e){return jNt.call(e)}var A5e=HNt;var WNt="[object Null]",VNt="[object Undefined]",v5e=Du?Du.toStringTag:void 0;function KNt(e){return e==null?e===void 0?VNt:WNt:v5e&&v5e in Object(e)?x5e(e):A5e(e)}var Pi=KNt;function JNt(e){return e!=null&&(typeof e==="undefined"?"undefined":_type_of(e))=="object"}var Tr=JNt;var ZNt="[object Symbol]";function YNt(e){return(typeof e==="undefined"?"undefined":_type_of(e))=="symbol"||Tr(e)&&Pi(e)==ZNt}var Zv=YNt;var XNt=Array.isArray,Js=XNt;var eOt=/\s/;function tOt(e){for(var t=e.length;t--&&eOt.test(e.charAt(t)););return t}var y5e=tOt;var aOt=/^\s+/;function rOt(e){return e&&e.slice(0,y5e(e)+1).replace(aOt,"")}var w5e=rOt;function iOt(e){var t=typeof e==="undefined"?"undefined":_type_of(e);return e!=null&&(t=="object"||t=="function")}var Ri=iOt;var b5e=0/0,nOt=/^[-+]0x[0-9a-f]+$/i,oOt=/^0b[01]+$/i,sOt=/^0o[0-7]+$/i,uOt=parseInt;function lOt(e){if(typeof e=="number")return e;if(Zv(e))return b5e;if(Ri(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Ri(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=w5e(e);var a=oOt.test(e);return a||sOt.test(e)?uOt(e.slice(2),a?2:8):nOt.test(e)?b5e:+e}var qp=lOt;var I5e=1/0,cOt=17976931348623157e292;function pOt(e){if(!e)return e===0?e:0;if(e=qp(e),e===I5e||e===-I5e){var t=e<0?-1:1;return t*cOt}return e===e?e:0}var k5e=pOt;function dOt(e){var t=k5e(e),a=t%1;return t===t?a?t-a:t:0}var Yv=dOt;function mOt(e){return e}var jh=mOt;var fOt="[object AsyncFunction]",gOt="[object Function]",hOt="[object GeneratorFunction]",_Ot="[object Proxy]";function xOt(e){if(!Ri(e))return!1;var t=Pi(e);return t==gOt||t==hOt||t==fOt||t==_Ot}var Mf=xOt;var AOt=sr["__core-js_shared__"],yk=AOt;var C5e=function(){var e=/[^.]+$/.exec(yk&&yk.keys&&yk.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function vOt(e){return!!C5e&&C5e in e}var E5e=vOt;var yOt=Function.prototype,wOt=yOt.toString;function bOt(e){if(e!=null){try{return wOt.call(e)}catch(t){}try{return e+""}catch(t){}}return""}var Lp=bOt;var IOt=/[\\^$.*+?()[\]{}|]/g,kOt=/^\[object .+?Constructor\]$/,COt=Function.prototype,EOt=Object.prototype,SOt=COt.toString,BOt=EOt.hasOwnProperty,TOt=RegExp("^"+SOt.call(BOt).replace(IOt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function MOt(e){if(!Ri(e)||E5e(e))return!1;var t=Mf(e)?TOt:kOt;return t.test(Lp(e))}var S5e=MOt;function POt(e,t){return e==null?void 0:e[t]}var B5e=POt;function ROt(e,t){var a=B5e(e,t);return S5e(a)?a:void 0}var ds=ROt;var QOt=ds(sr,"WeakMap"),Pf=QOt;var DOt=Pf&&new Pf,Hh=DOt;var NOt=Hh?function NOt1(e,t){return Hh.set(e,t),e}:jh,wk=NOt;var T5e=Object.create,OOt=function(){function e(){}return function(t){if(!Ri(t))return{};if(T5e)return T5e(t);e.prototype=t;var a=new e;return e.prototype=void 0,a}}(),S0=OOt;function FOt(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var a=S0(e.prototype),r=e.apply(a,t);return Ri(r)?r:a}}var $p=FOt;var qOt=1;function LOt(e,t,a){var r=t&qOt,i=$p(e);function n(){var o=this&&this!==sr&&_instanceof(this,n)?i:e;return o.apply(r?a:this,arguments)}return n}var M5e=LOt;function $Ot(e,t,a){switch(a.length){case 0:return e.call(t);case 1:return e.call(t,a[0]);case 2:return e.call(t,a[0],a[1]);case 3:return e.call(t,a[0],a[1],a[2])}return e.apply(t,a)}var Wh=$Ot;var UOt=Math.max;function GOt(e,t,a,r){for(var i=-1,n=e.length,o=a.length,s=-1,u=t.length,c=UOt(n-o,0),p=Array(u+c),l=!r;++s0){if(++t>=oFt)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var Bk=lFt;var cFt=Bk(wk),Tk=cFt;var pFt=/\{\n\/\* \[wrapped with (.+)\] \*/,dFt=/,? & /;function mFt(e){var t=e.match(pFt);return t?t[1].split(dFt):[]}var F5e=mFt;var fFt=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;function gFt(e,t){var a=t.length;if(!a)return e;var r=a-1;return t[r]=(a>1?"& ":"")+t[r],t=t.join(a>2?", ":" "),e.replace(fFt,"{\n/* [wrapped with "+t+"] */\n")}var q5e=gFt;function hFt(e){return function(){return e}}var L5e=hFt;var _Ft=function(){try{var e=ds(Object,"defineProperty");return e({},"",{}),e}catch(t){}}(),Zh=_Ft;var xFt=Zh?function xFt1(e,t){return Zh(e,"toString",{configurable:!0,enumerable:!1,value:L5e(t),writable:!0})}:jh,$5e=xFt;var AFt=Bk($5e),Mk=AFt;function vFt(e,t){for(var a=-1,r=e==null?0:e.length;++a-1}var H5e=kFt;var CFt=1,EFt=2,SFt=8,BFt=16,TFt=32,MFt=64,PFt=128,RFt=256,QFt=512,DFt=[["ary",PFt],["bind",CFt],["bindKey",EFt],["curry",SFt],["curryRight",BFt],["flip",QFt],["partial",TFt],["partialRight",MFt],["rearg",RFt]];function NFt(e,t){return Pk(DFt,function(a){var r="_."+a[0];t&a[1]&&!H5e(e,r)&&e.push(r)}),e.sort()}var W5e=NFt;function OFt(e,t,a){var r=t+"";return Mk(e,q5e(r,W5e(F5e(r),a)))}var Rk=OFt;var FFt=1,qFt=2,LFt=4,$Ft=8,V5e=32,K5e=64;function UFt(e,t,a,r,i,n,o,s,u,c){var p=t&$Ft,l=p?o:void 0,m=p?void 0:o,f=p?n:void 0,g=p?void 0:n;t|=p?V5e:K5e,t&=~(p?K5e:V5e),t&LFt||(t&=~(FFt|qFt));var h=[e,t,i,f,l,g,m,s,u,c],_=a.apply(void 0,h);return O5e(e)&&Tk(_,h),_.placeholder=r,Rk(_,e,t)}var Qk=UFt;function GFt(e){var t=e;return t.placeholder}var Yh=GFt;var zFt=0x1fffffffffffff,jFt=/^(?:0|[1-9]\d*)$/;function HFt(e,t){var a=typeof e==="undefined"?"undefined":_type_of(e);return t=t==null?zFt:t,!!t&&(a=="number"||a!="symbol"&&jFt.test(e))&&e>-1&&e%1==0&&e1&&x.reverse(),p&&u-1&&e%1==0&&e<=vqt}var Fk=yqt;function wqt(e){return e!=null&&Fk(e.length)&&!Mf(e)}var e1=wqt;function bqt(e,t,a){if(!Ri(a))return!1;var r=typeof t==="undefined"?"undefined":_type_of(t);return(r=="number"?e1(a)&&Xh(t,a.length):r=="string"&&t in a)?B0(a[t],e):!1}var dwe=bqt;var Iqt=Object.prototype;function kqt(e){var t=e&&e.constructor,a=typeof t=="function"&&t.prototype||Iqt;return e===a}var t1=kqt;function Cqt(e,t){for(var a=-1,r=Array(e);++a-1}var Dwe=GLt;function zLt(e,t){var a=this.__data__,r=M0(a,e);return r<0?(++this.size,a.push([e,t])):a[r][1]=t,this}var Nwe=zLt;function n1(e){var t=-1,a=e==null?0:e.length;for(this.clear();++ti?0:i+t),a=a>i?i:a,a<0&&(a+=i),i=t>a?0:a-t>>>0,t>>>=0;for(var n=Array(i);++r=t?e:t)),e}var zwe=n$t;function o$t(e,t,a){return a===void 0&&(a=t,t=void 0),a!==void 0&&(a=qp(a),a=a===a?a:0),t!==void 0&&(t=qp(t),t=t===t?t:0),zwe(qp(e),t,a)}var D0=o$t;function s$t(){this.__data__=new P0,this.size=0}var jwe=s$t;function u$t(e){var t=this.__data__,a=t.delete(e);return this.size=t.size,a}var Hwe=u$t;function l$t(e){return this.__data__.get(e)}var Wwe=l$t;function c$t(e){return this.__data__.has(e)}var Vwe=c$t;var p$t=200;function d$t(e,t){var a=this.__data__;if(_instanceof(a,P0)){var r=a.__data__;if(!R0||r.lengths))return!1;var c=n.get(e),p=n.get(t);if(c&&p)return c==t&&p==e;var l=-1,m=!0,f=a&aGt?new Q3e:void 0;for(n.set(e,t),n.set(t,e);++l=t||w<0||l&&k>=n}function A(){var b=tC();if(_(b))return x(b);s=setTimeout(A,h(b))}function x(b){return s=void 0,m&&r?f(b):(r=i=void 0,o)}function y(){s!==void 0&&clearTimeout(s),c=0,r=u=i=s=void 0}function v(){return s===void 0?o:x(tC())}function I(){var b=tC(),w=_(b);if(r=arguments,i=this,u=b,w){if(s===void 0)return g(u);if(l)return clearTimeout(s),s=setTimeout(A,t),f(u)}return s===void 0&&(s=setTimeout(A,t)),o}return I.cancel=y,I.flush=v,I}var jp=MGt;var PGt="[object String]";function RGt(e){return typeof e=="string"||!Js(e)&&Tr(e)&&Pi(e)==PGt}var Gq=RGt;var QGt="[object Boolean]";function DGt(e){return e===!0||e===!1||Tr(e)&&Pi(e)==QGt}var zq=DGt;var NGt="[object Date]";function OGt(e){return Tr(e)&&Pi(e)==NGt}var V3e=OGt;var K3e=Mo&&Mo.isDate,FGt=K3e?Gc(K3e):V3e,jq=FGt;function qGt(e,t){return W3e(e,t)}var aC=qGt;var LGt=sr.isFinite;function $Gt(e){return typeof e=="number"&&LGt(e)}var d1=$Gt;var UGt="[object Number]";function GGt(e){return typeof e=="number"||Tr(e)&&Pi(e)==UGt}var Hq=GGt;function zGt(e){return e==null}var Sl=zGt;function jGt(e){return e===null}var Wq=jGt;var HGt="[object RegExp]";function WGt(e){return Tr(e)&&Pi(e)==HGt}var J3e=WGt;var Z3e=Mo&&Mo.isRegExp,VGt=Z3e?Gc(Z3e):J3e,Vq=VGt;function KGt(e){return e===void 0}var Kq=KGt;var JGt=32,Jq=pwe(function(e,t){var a=Up(t,Yh(Jq));return uwe(e,JGt,void 0,t,a)});Jq.placeholder={};var Zq=Jq;var ZGt="Expected a function";function YGt(e,t,a){var r=!0,i=!0;if(typeof e!="function")throw new TypeError(ZGt);return Ri(a)&&(r="leading"in a?!!a.leading:r,i="trailing"in a?!!a.trailing:i),jp(e,t,{leading:r,maxWait:t,trailing:i})}var Yq=YGt;var nu=require("obsidian"),Tw=va(ai());var rC=require("obsidian");var iy=/*#__PURE__*/function(_rC_Modal){_inherits(iy1,_rC_Modal);function iy1(a,r){_class_call_check(this,iy1);var _this;_this=_call_super(this,iy1,[a]);_this.tasks=r;S(_this,"confirmed",!1);S(_this,"selectedTasks",[]);_this.selectedTasks=new Array(r.length).fill(!0);return _this}_create_class(iy1,[{key:"onOpen",value:function onOpen(){var _this=this;this.setTitle(D.t("deleteConfirm.title"));var _this1=this,a=_this1.contentEl;a.empty();var r=a.createEl("p",{cls:"delete-confirm-instruction"});r.style.whiteSpace="pre-wrap",r.setText(D.t("deleteConfirm.instruction"));var n=a.createDiv({cls:"max-h-50vh overflow-y-auto"}).createEl("table",{cls:"task-list-table"}),s=n.createEl("thead").createEl("tr"),u=s.createEl("th",{text:D.t("deleteConfirm.select")});u.style.textAlign="center",s.createEl("th",{text:D.t("deleteConfirm.filePath")});var c=n.createEl("tbody");this.tasks.forEach(function(l,m){var f=c.createEl("tr"),g=f.createEl("td");g.style.textAlign="center";var h=g.createEl("input");h.type="checkbox",h.checked=_this.selectedTasks[m],h.addEventListener("change",function(_){_this.selectedTasks[m]=h.checked,_.stopPropagation()}),f.addEventListener("click",function(_){_.target!==h&&(h.checked=!h.checked,_this.selectedTasks[m]=h.checked,_.stopPropagation())}),f.createEl("td",{text:l.localPath})});var p=a.createDiv();p.style.marginTop="1rem",new rC.Setting(p).addButton(function(l){l.setButtonText(D.t("deleteConfirm.deleteAndReupload")).setCta().onClick(function(){_this.confirmed=!0,_this.close()})}).addButton(function(l){l.setButtonText(D.t("deleteConfirm.skipForNow")).onClick(function(){_this.confirmed=!1,_this.close()})})}},{key:"open",value:function open(){var _this=this;var _this1=this,_superprop_get_open=function(){return _get(_get_prototype_of(iy1.prototype),"open",_this)};return _async_to_generator(function(){var _this;return _ts_generator(this,function(_state){_this=this;return[2,(_superprop_get_open().call(_this1),new Promise(function(a){_this.onClose=function(){if(!_this.confirmed){a({tasksToDelete:[],tasksToReupload:[]});return}var r=_this.tasks.filter(function(n,o){return _this.selectedTasks[o]}),i=_this.tasks.filter(function(n,o){return!_this.selectedTasks[o]});a({tasksToDelete:r,tasksToReupload:i})}}))]})}).call(this)}}]);return iy1}(rC.Modal);var iC=require("obsidian");var ny=/*#__PURE__*/function(_iC_Modal){_inherits(ny1,_iC_Modal);function ny1(a,r){_class_call_check(this,ny1);var _this;_this=_call_super(this,ny1,[a]);_this.failedTasks=r;return _this}_create_class(ny1,[{key:"onOpen",value:function onOpen(){var _this=this;this.setTitle(D.t("failedTasks.title"));var _this1=this,a=_this1.contentEl;a.empty(),a.createEl("p",{cls:"failed-tasks-instruction"}).setText(D.t("failedTasks.instruction"));var n=a.createDiv({cls:"max-h-50vh overflow-y-auto"}).createEl("table",{cls:"task-list-table"}),s=n.createEl("thead").createEl("tr");s.createEl("th",{text:D.t("failedTasks.taskName")}),s.createEl("th",{text:D.t("failedTasks.localPath")}),s.createEl("th",{text:D.t("failedTasks.errorMessage")});var u=n.createEl("tbody");this.failedTasks.forEach(function(p){var l=u.createEl("tr");l.createEl("td",{text:p.taskName}),l.createEl("td",{text:p.localPath}),l.createEl("td",{text:p.errorMessage})});var c=a.createDiv();c.style.marginTop="1rem",new iC.Setting(c).addButton(function(p){p.setButtonText(D.t("failedTasks.close")).setCta().onClick(function(){return _this.close()})})}},{key:"onClose",value:function onClose(){var _this=this,a=_this.contentEl;a.empty()}}]);return ny1}(iC.Modal);var TC=require("obsidian");var e4e=require("obsidian"),nC=va(ai()),br=/*#__PURE__*/function(){function br1(t){_class_call_check(this,br1);this.options=t}_create_class(br1,[{key:"vault",get:function get(){return this.options.vault}},{key:"syncRecord",get:function get(){return this.options.syncRecord}},{key:"webdav",get:function get(){return this.options.webdav}},{key:"remoteBaseDir",get:function get(){return this.options.remoteBaseDir}},{key:"remotePath",get:function get(){return(0,nC.isAbsolute)(this.options.remotePath)?this.options.remotePath:(0,nC.join)(this.remoteBaseDir,this.options.remotePath)}},{key:"localPath",get:function get(){return(0,e4e.normalizePath)(this.options.localPath)}},{key:"logger",get:function get(){return this.options.logger}},{key:"toJSON",value:function toJSON(){var _this=this,t=_this.localPath,a=_this.remoteBaseDir,r=_this.remotePath;return{taskName:this.constructor.name,localPath:t,remoteBaseDir:a,remotePath:r}}}]);return br1}(),N0=/*#__PURE__*/function(Error1){_inherits(N01,Error1);function N01(a,r,i){_class_call_check(this,N01);var _this;_this=_call_super(this,N01,[a]);_this.task=r;_this.cause=i;_this.name="TaskError";return _this}return N01}(_wrap_native_super(Error));function Ar(e,t){if(_instanceof(e,N0))return e;var a=_instanceof(e,Error)?e.message:String(e);return new N0(a,t,_instanceof(e,Error)?e:void 0)}var Po=/*#__PURE__*/function(br1){_inherits(Po1,br1);function Po1(){_class_call_check(this,Po1);return _call_super(this,Po1,arguments)}_create_class(Po1,[{key:"exec",value:function exec(){return _async_to_generator(function(){var t;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,2,,3]);return[4,this.syncRecord.deleteFileRecord(this.localPath)];case 1:return[2,(_state.sent(),{success:!0,skipRecord:!0})];case 2:t=_state.sent();return[2,(this.logger.error(this,t),{success:!1,error:Ar(t,this)})];case 3:return[2]}})}).call(this)}}]);return Po1}(br);function ezt(e){return _async_to_generator(function(){return _ts_generator(this,function(_state){return[2,crypto.subtle.digest("SHA-256",e)]})})()}function oy(e){return _async_to_generator(function(){var t;return _ts_generator(this,function(_state){switch(_state.label){case 0:return[4,ezt(e)];case 1:t=_state.sent();return[2,JI(new Uint8Array(t),!1)]}})})()}var r4e=va(a4e());var tzt=[/connection to indexeddb server lost/i,/connection to indexeddatabase server lost/i,/internal error opening backing store/i,/the database connection is closing/i];function azt(e){if(!e)return!1;var t=e,a=typeof t.name=="string"?t.name:"",r=typeof t.message=="string"?t.message:typeof e=="string"?e:"",i="".concat(a," ").concat(r).trim();return i?tzt.some(function(n){return n.test(i)}):!1}function rzt(e){return(typeof e==="undefined"?"undefined":_type_of(e))=="object"&&e!==null&&"getFreshInstance"in e&&typeof e.getFreshInstance=="function"}function eL(e){var f,g;var t=rzt(e)?e:{getFreshInstance:function(){return e},maxRetries:0},a=t.getFreshInstance(),r=(f=t.shouldRecover)!=null?f:azt,i=Math.max(0,(g=t.maxRetries)!=null?g:0);function n(h){return _async_to_generator(function(){var _,A,x;return _ts_generator(this,function(_state){switch(_state.label){case 0:A=0;_state.label=1;case 1:if(!(A<=i))return[3,6];_state.label=2;case 2:_state.trys.push([2,4,,5]);return[4,h(a)];case 3:return[2,_state.sent()];case 4:x=_state.sent();if(A===0&&(_=x),!(A2&&_arguments[2]!==void 0?_arguments[2]:!1;r=(0,Ou.normalizePath)(t);if(!cy(e,r))return[3,5];return[4,e.adapter.stat(r)];case 1:n=_state.sent();if(!n)return[2];if(!(n.type==="folder"))return[3,3];return[4,e.adapter.rmdir(r,a)];case 2:_state.sent();return[2];case 3:return[4,e.adapter.remove(r)];case 4:_state.sent();return[2];case 5:i=e.getAbstractFileByPath(r);_tmp=i;if(!_tmp)return[3,7];return[4,e.trash(i,!1)];case 6:_tmp=_state.sent();_state.label=7;case 7:_tmp;return[2]}})}).apply(this,arguments)}var uC=va(ai());function Tl(e,t){return _async_to_generator(function(){var a,r,_tmp,_tmp1,i,_tmp2,_tmp3,_tmp4;return _ts_generator(this,function(_state){switch(_state.label){case 0:a=[],r=(0,uC.normalize)(t);_tmp=!(r==="/"||r===".");if(!_tmp)return[3,2];return[4,Ro(e,r)];case 1:_tmp=!_state.sent();_state.label=2;case 2:if(!_tmp)return[3,16];_state.label=3;case 3:_tmp1=r!==""&&r!=="/"&&r!==".";if(!_tmp1)return[3,5];return[4,Ro(e,r)];case 4:_tmp1=!_state.sent();_state.label=5;case 5:if(!_tmp1)return[3,7];a.push(r),r=(0,uC.dirname)(r);_state.label=6;case 6:return[3,3];case 7:if(!a.length)return[3,16];i=a.pop();_tmp2=i;if(!_tmp2)return[3,14];return[4,Ro(e,i)];case 8:_tmp3=_state.sent();if(_tmp3)return[3,13];if(!sC(e,i))return[3,10];return[4,e.adapter.mkdir(i)];case 9:_tmp4=_state.sent();return[3,12];case 10:return[4,e.createFolder(i)];case 11:_tmp4=_state.sent();_state.label=12;case 12:_tmp3=_tmp4;_state.label=13;case 13:_tmp2=_tmp3;_state.label=14;case 14:_tmp2;_state.label=15;case 15:return[3,7];case 16:return[2]}})})()}function dy(e){return _async_to_generator(function(){return _ts_generator(this,function(_state){switch(_state.label){case 0:if(!!py.Platform.isMobileApp)return[3,2];return[4,vzt(e)];case 1:_state.sent();return[2];case 2:return[4,yzt(e)];case 3:_state.sent();return[2]}})})()}function xzt(e){return _instanceof(e,ArrayBuffer)?e:bzt(e)}function Azt(e,t){var a=new ArrayBuffer(t),r=new Uint8Array(a),i=0;var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=e[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var n=_step.value;r.set(new Uint8Array(n),i),i+=n.byteLength}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}if(i!==t)throw new Error("Remote Size Not Match!");return a}function vzt(_0){return _async_to_generator(function(param){var e,t,a,r,i,n,o;return _ts_generator(this,function(_state){switch(_state.label){case 0:e=param.vault,t=param.webdav,a=param.remotePath,r=param.localPath,i=param.remoteSize;return[4,t.getFileContents(a,{format:"binary",details:!1})];case 1:n=_state.sent(),o=xzt(n);if(o.byteLength!==i)throw new Error("Remote Size Not Match!");return[4,Tl(e,(0,sL.dirname)(r))];case 2:_state.sent();return[4,Ff(e,r,o)];case 3:_state.sent();return[2]}})}).apply(this,arguments)}function yzt(_0){return _async_to_generator(function(param){var e,t,a,r,i,n,f,o,s,u,c,p,l,m,_$g,h,_,A,_tmp,_tmp1,_tmp2,_tmp3,g,_tmp4;return _ts_generator(this,function(_state){switch(_state.label){case 0:e=param.vault,t=param.webdav,a=param.remotePath,r=param.localPath,i=param.remoteSize,n=param.mobileAppDownloadFileChunkSize;o=(0,py.normalizePath)(r);return[4,Tl(e,(0,sL.dirname)(o))];case 1:if(!(_state.sent(),i===0))return[3,3];return[4,Ff(e,o,new ArrayBuffer(0))];case 2:_state.sent();return[2];case 3:s=(f=e.adapter.appendBinary)==null?void 0:f.bind(e.adapter),u=[],c=p4e(n),p=(0,py.normalizePath)("".concat(o,".nutstore-sync-").concat(Date.now(),"-").concat(Math.random().toString(36).slice(2),".download")),l=0,m=0;Pe.info("[ChunkedDownload] start ".concat(a," (").concat(i," bytes, chunkSize=").concat(c,")"));_state.label=4;case 4:_state.trys.push([4,23,,26]);_state.label=5;case 5:if(!(ll));m++);if(mu.buffer1index;)c.buffer1.push(e[i]);for(;--n>u.buffer2index;)c.buffer2.push(t[n]);(c.buffer1.length||c.buffer2.length)&&(s(),c.buffer1.reverse(),c.buffer2.reverse(),r.push(c)),i>=0&&o.common.push(e[i])}return s(),r.reverse(),r}function m4e(e,t){var a=f4e(e,t),r=[],i=e.length,n=t.length;for(var o=a;o!==null;o=o.chain){var s=i-o.buffer1index-1,u=n-o.buffer2index-1;i=o.buffer1index,n=o.buffer2index,(s||u)&&r.push({buffer1:[i+1,s],buffer1Content:e.slice(i+1,i+1+s),buffer2:[n+1,u],buffer2Content:t.slice(n+1,n+1+u)})}return r.reverse(),r}function Izt(e,t,a){var r=[];function i(u,c){r.push({ab:c,oStart:u.buffer1[0],oLength:u.buffer1[1],abStart:u.buffer2[0],abLength:u.buffer2[1]})}m4e(t,e).forEach(function(u){return i(u,"a")}),m4e(t,a).forEach(function(u){return i(u,"b")}),r.sort(function(u,c){return u.oStart-c.oStart});var n=[],o=0;function s(u){u>o&&(n.push({stable:!0,buffer:"o",bufferStart:o,bufferLength:u-o,bufferContent:t.slice(o,u)}),o=u)}for(;r.length;){var u=r.shift(),c=u.oStart,p=u.oStart+u.oLength,l=[u];for(s(c);r.length;){var m=r[0],f=m.oStart;if(f>p)break;p=Math.max(p,f+m.oLength),l.push(r.shift())}if(l.length===1){if(u.abLength>0){var m1=u.ab==="a"?e:a;n.push({stable:!0,buffer:u.ab,bufferStart:u.abStart,bufferLength:u.abLength,bufferContent:m1.slice(u.abStart,u.abStart+u.abLength)})}}else{var m6={a:[e.length,-1,t.length,-1],b:[a.length,-1,t.length,-1]};for(;l.length;){u=l.shift();var x=u.oStart,y=x+u.oLength,v=u.abStart,I=v+u.abLength,b=m6[u.ab];b[0]=Math.min(v,b[0]),b[1]=Math.max(I,b[1]),b[2]=Math.min(x,b[2]),b[3]=Math.max(y,b[3])}var f10=m6.a[0]+(c-m6.a[2]),g=m6.a[1]+(p-m6.a[3]),h=m6.b[0]+(c-m6.b[2]),_=m6.b[1]+(p-m6.b[3]),A={stable:!1,aStart:f10,aLength:g-f10,aContent:e.slice(f10,g),oStart:c,oLength:p-c,oContent:t.slice(c,p),bStart:h,bLength:_-h,bContent:a.slice(h,_)};n.push(A)}o=p}return s(t.length),n}function lC(e,t,a,r){r=Object.assign({excludeFalseConflicts:!0,stringSeparator:/\s+/},r),typeof e=="string"&&(e=e.split(r.stringSeparator)),typeof t=="string"&&(t=t.split(r.stringSeparator)),typeof a=="string"&&(a=a.split(r.stringSeparator));var n=[],o=Izt(e,t,a),s=[];function u(){s.length&&n.push({ok:s}),s=[]}function c(p,l){if(p.length!==l.length)return!1;for(var m=0;m',o=r.useGitStyle?"=======":'',s=r.useGitStyle?">>>>>>>":"",u=lC(e,t,a,r),c=!1,p=[];return u.forEach(function(l){if(l.ok)p=p.concat(l.ok);else{var m=g4e(l.conflict.a,l.conflict.b);for(var f=0;f_$i?"remote newer → pull":"local newer → push"));return[4,Ro(this.vault,this.localPath)];case 1:if(!_state.sent())return[2,{success:!1,error:Ar(new Error("cannot find file in local fs: "+this.localPath),this)}];if(!(n>_$i))return[3,3];return[4,dy({vault:this.vault,webdav:this.webdav,remotePath:this.remotePath,localPath:this.localPath,remoteSize:o,mobileAppDownloadFileChunkSize:this.options.mobileAppDownloadFileChunkSize})];case 2:_state.sent();return[3,6];case 3:return[4,Bl(this.vault,this.localPath)];case 4:u=_state.sent();return[4,this.webdav.putFileContents(this.remotePath,u,{overwrite:!0})];case 5:_state.sent();_state.label=6;case 6:return[2,{success:!0}];case 7:i=_state.sent();return[2,(this.logger.error("[ConflictResolve/LatestTimestamp] failed: ".concat(this.localPath),i),{success:!1,error:Ar(i,this)})];case 8:return[2]}})}).call(this)}},{key:"execLocalPriority",value:function execLocalPriority(){return _async_to_generator(function(){var r,a;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,4,,5]);return[4,Ro(this.vault,this.localPath)];case 1:if(!_state.sent())return[2,{success:!1,error:Ar(new Error("cannot find file in local fs: "+this.localPath),this)}];return[4,Bl(this.vault,this.localPath)];case 2:r=_state.sent();return[4,this.webdav.putFileContents(this.remotePath,r,{overwrite:!0})];case 3:return[2,(_state.sent(),{success:!0})];case 4:a=_state.sent();return[2,(this.logger.error("[ConflictResolve/LocalPriority] failed: ".concat(this.localPath),a),{success:!1,error:Ar(a,this)})];case 5:return[2]}})}).call(this)}},{key:"execServerPriority",value:function execServerPriority(a){return _async_to_generator(function(){var r;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,2,,3]);if(a.isDir)throw new Error("Remote path is a directory: "+this.remotePath);return[4,dy({vault:this.vault,webdav:this.webdav,remotePath:this.remotePath,localPath:this.localPath,remoteSize:a.size,mobileAppDownloadFileChunkSize:this.options.mobileAppDownloadFileChunkSize})];case 1:return[2,(_state.sent(),{success:!0})];case 2:r=_state.sent();return[2,(this.logger.error("[ConflictResolve/ServerPriority] failed: ".concat(this.localPath),r),{success:!1,error:Ar(r,this)})];case 3:return[2]}})}).call(this)}},{key:"execIntelligentMergeOrSkip",value:function execIntelligentMergeOrSkip(){return _async_to_generator(function(){var a,r,n,o,_this_options,s,u,c,_tmp,p,l,m,f,g,h,_,_tmp1,_tmp2,i;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,16,,17]);return[4,Ro(this.vault,this.localPath)];case 1:if(!_state.sent())throw new Error("cannot find file in local fs: "+this.localPath);return[4,Bl(this.vault,this.localPath)];case 2:n=_state.sent();return[4,this.webdav.getFileContents(this.remotePath,{format:"binary",details:!1})];case 3:o=_state.sent();if(aC(n,o))return[2,{success:!0}];_this_options=this.options,s=_this_options.record,u=null,c=(a=s==null?void 0:s.base)==null?void 0:a.key;_tmp=c;if(!_tmp)return[3,5];return[4,Hp.get(c)];case 4:_tmp=u=_state.sent();_state.label=5;case 5:_tmp;p=Df(this.localPath),l=Df(this.remotePath);if(!(p&&l))throw new Error(D.t("sync.error.mergeNotSupported"));return[4,new Blob([new Uint8Array(n)]).text()];case 6:m=_state.sent();return[4,new Blob([new Uint8Array(o)]).text()];case 7:f=_state.sent();return[4,u==null?void 0:u.text()];case 8:g=(r=_state.sent())!=null?r:m;return[4,uL({localContentText:m,remoteContentText:f,baseContentText:g})];case 9:h=_state.sent();if(this.logger.info("[ConflictResolve/DiffMatchPatchOrSkip] ".concat(this.localPath,": patch_apply ").concat(h.success?"ok":"failed → skip")),!h.success)throw new Error(D.t("sync.error.failedToAutoMerge"));if(h.isIdentical)return[2,{success:!0}];_=h.mergedText;if(!(_===f))return[3,12];_tmp1=_!==m;if(!_tmp1)return[3,11];return[4,F0(this.vault,this.localPath,_)];case 10:_tmp1=_state.sent();_state.label=11;case 11:return[2,(_tmp1,{success:!0})];case 12:return[4,this.webdav.putFileContents(this.remotePath,_,{overwrite:!0})];case 13:if(!_state.sent())throw new Error(D.t("sync.error.failedToUploadMerged"));_tmp2=m!==_;if(!_tmp2)return[3,15];return[4,F0(this.vault,this.localPath,_)];case 14:_tmp2=_state.sent();_state.label=15;case 15:return[2,(_tmp2,{success:!0})];case 16:i=_state.sent();return[2,(this.logger.error("[ConflictResolve/DiffMatchPatchOrSkip] failed: ".concat(this.localPath),i),{success:!1,error:Ar(i,this)})];case 17:return[2]}})}).call(this)}},{key:"execIntelligentMerge",value:function execIntelligentMerge(){return _async_to_generator(function(){var a,r,n,o,_this_options,s,u,c,_tmp,p,l,m,f,g,h,y,_,_tmp1,_tmp2,i;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,20,,21]);return[4,Ro(this.vault,this.localPath)];case 1:if(!_state.sent())throw new Error("cannot find file in local fs: "+this.localPath);return[4,Bl(this.vault,this.localPath)];case 2:n=_state.sent();return[4,this.webdav.getFileContents(this.remotePath,{format:"binary",details:!1})];case 3:o=_state.sent();if(aC(n,o))return[2,{success:!0}];_this_options=this.options,s=_this_options.record,u=null,c=(a=s==null?void 0:s.base)==null?void 0:a.key;_tmp=c;if(!_tmp)return[3,5];return[4,Hp.get(c)];case 4:_tmp=u=_state.sent();_state.label=5;case 5:_tmp;p=Df(this.localPath),l=Df(this.remotePath);if(!(p&&l))throw new Error(D.t("sync.error.mergeNotSupported"));return[4,new Blob([new Uint8Array(n)]).text()];case 6:m=_state.sent();return[4,new Blob([new Uint8Array(o)]).text()];case 7:f=_state.sent();return[4,u==null?void 0:u.text()];case 8:g=(r=_state.sent())!=null?r:m;return[4,uL({localContentText:m,remoteContentText:f,baseContentText:g})];case 9:h=_state.sent();if(!(this.logger.info("[ConflictResolve/DiffMatchPatch] ".concat(this.localPath,": patch_apply ").concat(h.success?"ok":"failed → fallback to mergeDigIn")),!h.success))return[3,13];y=h4e(m,g,f,{stringSeparator:"\n",useGitStyle:this.options.useGitStyle}).result.join("\n");return[4,this.webdav.putFileContents(this.remotePath,y,{overwrite:!0})];case 10:if(!_state.sent())return[3,12];return[4,F0(this.vault,this.localPath,y)];case 11:return[2,(_state.sent(),{success:!0})];case 12:throw new Error(D.t("sync.error.failedToUploadMerged"));case 13:if(h.isIdentical)return[2,{success:!0}];_=h.mergedText;if(!(_===f))return[3,16];_tmp1=_!==m;if(!_tmp1)return[3,15];return[4,F0(this.vault,this.localPath,_)];case 14:_tmp1=_state.sent();_state.label=15;case 15:return[2,(_tmp1,{success:!0})];case 16:return[4,this.webdav.putFileContents(this.remotePath,_,{overwrite:!0})];case 17:if(!_state.sent())throw new Error(D.t("sync.error.failedToUploadMerged"));_tmp2=m!==_;if(!_tmp2)return[3,19];return[4,F0(this.vault,this.localPath,_)];case 18:_tmp2=_state.sent();_state.label=19;case 19:return[2,(_tmp2,{success:!0})];case 20:i=_state.sent();return[2,(this.logger.error("[ConflictResolve/DiffMatchPatch] failed: ".concat(this.localPath),i),{success:!1,error:Ar(i,this)})];case 21:return[2]}})}).call(this)}}]);return Fu1}(br);var Czt=':*?"<>|',y4e=Czt.split("");function qu(e){return y4e.some(function(t){return e.includes(t)})}function w4e(e){return y4e.filter(function(t){return e.includes(t)})}var fy=/*#__PURE__*/function _target(Error1){_inherits(fy1,Error1);function fy1(a,r){_class_call_check(this,fy1);var _this;var i;_this=_call_super(this,fy1);_this.invalidChars=a;_this.filePath=r;_this.name="FilenameError",(i=Object.setPrototypeOf)==null||i.call(Object,_this,(_instanceof(this,fy1)?this.constructor:void 0).prototype),Object.defineProperty(_this,"message",{configurable:!0,get:function(){return fy.format(_this.invalidChars,_this.filePath)}});return _this}_create_class(fy1,null,[{key:"format",value:function format(a,r){var n=Array.from(new Set(a)).map(function(o){return"'".concat(o,"'")}).join(", ");return D.t("errors.filenameUnsupportedChars",{chars:n,path:r})}}]);return fy1}(_wrap_native_super(Error)),Wp=/*#__PURE__*/function(br1){_inherits(Wp1,br1);function Wp1(){_class_call_check(this,Wp1);return _call_super(this,Wp1,arguments)}_create_class(Wp1,[{key:"exec",value:function exec(){var t=w4e(this.localPath);return{success:!1,error:Ar(new fy(t,this.localPath),this)}}}]);return Wp1}(br);var Ml=/*#__PURE__*/function(br1){_inherits(Ml1,br1);function Ml1(){_class_call_check(this,Ml1);return _call_super(this,Ml1,arguments)}_create_class(Ml1,[{key:"exec",value:function exec(){return _async_to_generator(function(){var t;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,2,,3]);this.logger.info("[MkdirLocal] ".concat(this.localPath));return[4,Tl(this.vault,this.localPath)];case 1:return[2,(_state.sent(),{success:!0})];case 2:t=_state.sent();return[2,(this.logger.error("[MkdirLocal] failed: ".concat(this.localPath),t),{success:!1,error:Ar(t,this)})];case 3:return[2]}})}).call(this)}}]);return Ml1}(br);var zn=/*#__PURE__*/function(br1){_inherits(zn1,br1);function zn1(){_class_call_check(this,zn1);return _call_super(this,zn1,arguments)}_create_class(zn1,[{key:"exec",value:function exec(){return _async_to_generator(function(){var t;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,3,,4]);return[4,so(this.vault,this.localPath)];case 1:if(!_state.sent())throw this.logger.debug("[MkdirRemote] local path not found:",this.localPath),new Error(D.t("sync.error.localPathNotFound",{path:this.localPath}));this.logger.info("[MkdirRemote] ".concat(this.remotePath));return[4,this.webdav.createDirectory(this.remotePath,{recursive:!0})];case 2:return[2,(_state.sent(),{success:!0})];case 3:t=_state.sent();return[2,(this.logger.error("[MkdirRemote] failed: ".concat(this.remotePath),t),{success:!1,error:Ar(t,this)})];case 4:return[2]}})}).call(this)}}]);return zn1}(br);var Pl=/*#__PURE__*/function(br1){_inherits(Pl1,br1);function Pl1(a){_class_call_check(this,Pl1);var _this;_this=_call_super(this,Pl1,[a]);S(_this,"additionalPaths");_this.additionalPaths=a.additionalPaths;return _this}_create_class(Pl1,[{key:"exec",value:function exec(){return _async_to_generator(function(){var a;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,3,,4]);return[4,so(this.vault,this.localPath)];case 1:if(!_state.sent())throw this.logger.debug("MkdirsRemoteTask: local path:",this.localPath),this.logger.debug("MkdirsRemoteTask: local stat is null"),new Error(D.t("sync.error.localPathNotFound",{path:this.localPath}));return[4,this.webdav.createDirectory(this.remotePath,{recursive:!0})];case 2:return[2,(_state.sent(),{success:!0})];case 3:a=_state.sent();return[2,(this.logger.error(this,a),{success:!1,error:Ar(a,this)})];case 4:return[2]}})}).call(this)}},{key:"getAllPaths",value:function getAllPaths(){return[{localPath:this.localPath,remotePath:this.remotePath}].concat(_to_consumable_array(this.additionalPaths))}},{key:"toJSON",value:function toJSON(){return _object_spread_props(_object_spread({},_get(_get_prototype_of(Pl1.prototype),"toJSON",this).call(this)),{additionalPaths:this.additionalPaths,totalDirs:this.getAllPaths().length})}}]);return Pl1}(br);var Qo=/*#__PURE__*/function(br1){_inherits(Qo1,br1);function Qo1(){_class_call_check(this,Qo1);return _call_super(this,Qo1,arguments)}_create_class(Qo1,[{key:"exec",value:function exec(){return{success:!0}}}]);return Qo1}(br);var Lu=/*#__PURE__*/function(br1){_inherits(Lu1,br1);function Lu1(a){_class_call_check(this,Lu1);var _this;_this=_call_super(this,Lu1,[a]);_this.options=a;return _this}_create_class(Lu1,[{key:"remoteSize",get:function get(){return this.options.remoteSize}},{key:"exec",value:function exec(){return _async_to_generator(function(){var a;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,2,,3]);this.logger.info("[PullTask] ".concat(this.remotePath," → ").concat(this.localPath," (").concat(this.remoteSize," bytes)"));return[4,dy({vault:this.vault,webdav:this.webdav,remotePath:this.remotePath,localPath:this.localPath,remoteSize:this.remoteSize,mobileAppDownloadFileChunkSize:this.options.mobileAppDownloadFileChunkSize})];case 1:return[2,(_state.sent(),{success:!0})];case 2:a=_state.sent();return[2,(this.logger.error("[PullTask] failed: ".concat(this.localPath),a),{success:!1,error:Ar(a,this)})];case 3:return[2]}})}).call(this)}}]);return Lu1}(br);var $u=/*#__PURE__*/function(br1){_inherits($u1,br1);function $u1(){_class_call_check(this,$u1);return _call_super(this,$u1,arguments)}_create_class($u1,[{key:"exec",value:function exec(){return _async_to_generator(function(){var a,r,t;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,4,,5]);return[4,Ro(this.vault,this.localPath)];case 1:if(!_state.sent())throw new Error("cannot find file in local fs: "+this.localPath);return[4,Bl(this.vault,this.localPath)];case 2:a=_state.sent();this.logger.info("[PushTask] ".concat(this.localPath," → ").concat(this.remotePath," (").concat(a.byteLength," bytes)"));return[4,this.webdav.putFileContents(this.remotePath,a,{overwrite:!0})];case 3:r=_state.sent();if(!r)throw new Error("Upload failed");return[2,{success:r}];case 4:t=_state.sent();return[2,(this.logger.error("[PushTask] failed: ".concat(this.localPath),t),{success:!1,error:Ar(t,this)})];case 5:return[2]}})}).call(this)}}]);return $u1}(br);var ms=/*#__PURE__*/function(br1){_inherits(ms1,br1);function ms1(a){_class_call_check(this,ms1);var _this;_this=_call_super(this,ms1,[a]);_this.options=a;return _this}_create_class(ms1,[{key:"exec",value:function exec(){return _async_to_generator(function(){var _tmp,a;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,5,,6]);return[4,so(this.vault,this.localPath)];case 1:if(!_state.sent())return[3,3];this.logger.info("[RemoveLocal] ".concat(this.localPath));return[4,d4e(this.vault,this.localPath,this.options.recursive)];case 2:_tmp=(_state.sent(),{success:!0});return[3,4];case 3:_tmp={success:!0};_state.label=4;case 4:return[2,_tmp];case 5:a=_state.sent();return[2,(this.logger.error("[RemoveLocal] failed: ".concat(this.localPath),a),{success:!1,error:Ar(a,this)})];case 6:return[2]}})}).call(this)}}]);return ms1}(br);var Rl=/*#__PURE__*/function(br1){_inherits(Rl1,br1);function Rl1(){_class_call_check(this,Rl1);return _call_super(this,Rl1,arguments)}_create_class(Rl1,[{key:"exec",value:function exec(){return _async_to_generator(function(){var t;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,2,,3]);return[4,this.webdav.deleteFile(this.remotePath)];case 1:return[2,(_state.sent(),{success:!0})];case 2:t=_state.sent();return[2,(this.logger.error(t),{success:!1,error:Ar(t,this)})];case 3:return[2]}})}).call(this)}}]);return Rl1}(br);var Zs=/*#__PURE__*/function(br1){_inherits(Zs1,br1);function Zs1(){_class_call_check(this,Zs1);return _call_super(this,Zs1,arguments)}_create_class(Zs1,[{key:"exec",value:function exec(){return _async_to_generator(function(){var t;return _ts_generator(this,function(_state){switch(_state.label){case 0:_state.trys.push([0,2,,3]);this.logger.info("[RemoveRemote] ".concat(this.remotePath));return[4,this.webdav.deleteFile(this.remotePath)];case 1:return[2,(_state.sent(),{success:!0})];case 2:t=_state.sent();return[2,(this.logger.error("[RemoveRemote] failed: ".concat(this.remotePath),t),{success:!1,error:Ar(t,this)})];case 3:return[2]}})}).call(this)}}]);return Zs1}(br);var fs=/*#__PURE__*/function(br1){_inherits(fs1,br1);function fs1(a){_class_call_check(this,fs1);var _this;_this=_call_super(this,fs1,[a]);_this.options=a;return _this}_create_class(fs1,[{key:"exec",value:function exec(){return{success:!0,skipRecord:!0}}}]);return fs1}(br);function Vp(e){if(_instanceof(e,Po))return D.t("sync.fileOp.cleanRecord");if(_instanceof(e,Fu))return D.t("sync.fileOp.merge");if(_instanceof(e,Wp))return D.t("sync.fileOp.filenameError");if(_instanceof(e,Ml))return D.t("sync.fileOp.createLocalDir");if(_instanceof(e,zn))return D.t("sync.fileOp.createRemoteDir");if(_instanceof(e,Pl))return D.t("sync.fileOp.createRemoteDirs");if(_instanceof(e,Qo))return D.t("sync.fileOp.noop");if(_instanceof(e,Lu))return D.t("sync.fileOp.download");if(_instanceof(e,$u))return D.t("sync.fileOp.upload");if(_instanceof(e,ms))return D.t("sync.fileOp.removeLocal");if(_instanceof(e,Zs))return D.t("sync.fileOp.removeRemote");if(_instanceof(e,Rl))return D.t("sync.fileOp.removeRemoteRecursively");if(_instanceof(e,fs)){var t=function(){if(e.options.reason==="file-too-large")return D.t("sync.skipReason.file-too-large");if(e.options.reason==="folder-contains-ignored-items")return D.t("sync.skipReason.folder-contains-ignored-items");if(e.options.reason==="conflict-in-send-only-mode")return D.t("sync.skipReason.conflict-in-send-only-mode");if(e.options.reason==="conflict-in-receive-only-mode")return D.t("sync.skipReason.conflict-in-receive-only-mode");if(e.options.reason==="deleted-locally-but-changed-remotely")return D.t("sync.skipReason.deleted-locally-but-changed-remotely");if(e.options.reason==="deleted-remotely-but-changed-locally")return D.t("sync.skipReason.deleted-remotely-but-changed-locally")}();return"".concat(D.t("sync.fileOp.skip"),": ").concat(t)}return D.t("sync.fileOp.sync")}var Pr={context:void 0,registry:void 0,effects:void 0,done:!1,getContextId:function getContextId(){return b4e(this.context.count)},getNextContextId:function getNextContextId(){return b4e(this.context.count++)}};function b4e(e){var t=String(e),a=t.length-1;return Pr.context.id+(a?String.fromCharCode(96+a):"")+t}function pL(e){Pr.context=e}function Ezt(){return _object_spread_props(_object_spread({},Pr.context),{id:Pr.getNextContextId(),count:0})}var Szt=!1,Bzt=function(e,t){return e===t},Ql=Symbol("solid-proxy"),Tzt=typeof Proxy=="function",mC=Symbol("solid-track"),Vtr=Symbol("solid-dev-component"),pC={equals:Bzt},I4e=null,B4e=N4e,Ys=1,gy=2,T4e={owned:null,cleanups:null,context:null,owner:null};var Ka=null,ct=null,w1=null,v1=null,vr=null,Hi=null,uo=null,fC=0;function y1(e,t){var a=vr,r=Ka,i=e.length===0,n=t===void 0?r:t,o=i?T4e:{owned:null,cleanups:null,context:n?n.context:null,owner:n},s=i?e:function(){return e(function(){return gs(function(){return q0(o)})})};Ka=o,vr=null;try{return Dl(s,!0)}finally{vr=a,Ka=r}}function Pa(e,t){t=t?Object.assign({},pC,t):pC;var a={value:e,observers:null,observerSlots:null,comparator:t.equals||void 0},r=function(i){return typeof i=="function"&&(ct&&ct.running&&ct.sources.has(a)?i=i(a.tValue):i=i(a.value)),D4e(a,i)};return[Q4e.bind(a),r]}function M4e(e,t,a){var r=xC(e,t,!0,Ys);w1&&ct&&ct.running?Hi.push(r):b1(r)}function Vt(e,t,a){var r=xC(e,t,!1,Ys);w1&&ct&&ct.running?Hi.push(r):b1(r)}function Ii(e,t,a){B4e=Nzt;var r=xC(e,t,!1,Ys),i=dL&&Pzt(dL);i&&(r.suspense=i),(!a||!a.render)&&(r.user=!0),uo?uo.push(r):b1(r)}function Rr(e,t,a){a=a?Object.assign({},pC,a):pC;var r=xC(e,t,!0,0);return r.observers=null,r.observerSlots=null,r.comparator=a.equals||void 0,w1&&ct&&ct.running?(r.tState=Ys,Hi.push(r)):b1(r),Q4e.bind(r)}function P4e(e){return Dl(e,!1)}function gs(e){if(!v1&&vr===null)return e();var t=vr;vr=null;try{return v1?v1.untrack(e):e()}finally{vr=t}}function gC(e,t,a){var r=Array.isArray(e),i,n=a&&a.defer;return function(o){var s;if(r){s=Array(e.length);for(var c=0;c1e6)throw Hi=[],new Error},!1)}return t}function b1(e){if(!e.fn)return;q0(e);var t=fC;C4e(e,ct&&ct.running&&ct.sources.has(e)?e.tValue:e.value,t),ct&&!ct.running&&ct.sources.has(e)&&queueMicrotask(function(){Dl(function(){ct&&(ct.running=!0),vr=Ka=e,C4e(e,e.tValue,t),vr=Ka=null},!1)})}function C4e(e,t,a){var r,i=Ka,n=vr;vr=Ka=e;try{r=e.fn(t)}catch(o){return e.pure&&(ct&&ct.running?(e.tState=Ys,e.tOwned&&e.tOwned.forEach(q0),e.tOwned=void 0):(e.state=Ys,e.owned&&e.owned.forEach(q0),e.owned=null)),e.updatedAt=a+1,AC(o)}finally{vr=n,Ka=i}(!e.updatedAt||e.updatedAt<=a)&&(e.updatedAt!=null&&"observers"in e?D4e(e,r,!0):ct&&ct.running&&e.pure?(ct.sources.add(e),e.tValue=r):e.value=r,e.updatedAt=a)}function xC(e,t,a){var r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:Ys,i=arguments.length>4?arguments[4]:void 0;var n={fn:e,state:r,updatedAt:null,owned:null,sources:null,sourceSlots:null,cleanups:null,value:t,owner:Ka,context:Ka?Ka.context:null,pure:a};if(ct&&ct.running&&(n.state=0,n.tState=r),Ka===null||Ka!==T4e&&(ct&&ct.running&&Ka.pure?Ka.tOwned?Ka.tOwned.push(n):Ka.tOwned=[n]:Ka.owned?Ka.owned.push(n):Ka.owned=[n]),v1&&n.fn){var _Pa=_sliced_to_array(Pa(void 0,{equals:!1}),2),o=_Pa[0],s=_Pa[1],u=v1.factory(n.fn,s);ln(function(){return u.dispose()});var c=function(){return Mzt(s).then(function(){return p.dispose()})},p=v1.factory(n.fn,c);n.fn=function(l){return o(),ct&&ct.running?p.track(l):u.track(l)}}return n}function hy(e){var t=ct&&ct.running;if((t?e.tState:e.state)===0)return;if((t?e.tState:e.state)===gy)return dC(e);if(e.suspense&&gs(e.suspense.inFallback))return e.suspense.effects.push(e);var a=[e];for(;(e=e.owner)&&(!e.updatedAt||e.updatedAt=0;r--){if(e=a[r],t){var i=e,n=a[r+1];for(;(i=i.owner)&&i!==n;)if(ct.disposed.has(i))return}if((t?e.tState:e.state)===Ys)b1(e);else if((t?e.tState:e.state)===gy){var i6=Hi;Hi=null,Dl(function(){return dC(e,a[0])},!1),Hi=i6}}}function Dl(e,t){if(Hi)return e();var a=!1;t||(Hi=[]),uo?a=!0:uo=[],fC++;try{var _$r=e();return Qzt(a),_$r}catch(r){a||(uo=null),Hi=null,AC(r)}}function Qzt(e){if(Hi&&(w1&&ct&&ct.running?Dzt(Hi):N4e(Hi),Hi=null),e)return;var t;if(ct){if(!ct.promises.size&&!ct.queue.size){var r=ct.sources,i=ct.disposed;uo.push.apply(uo,ct.effects),t=ct.resolve;var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=uo[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var n=_step.value;"tState"in n&&(n.state=n.tState),delete n.tState}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}ct=null,Dl(function(){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=i[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var n=_step.value;q0(n)}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}var _iteratorNormalCompletion1=true,_didIteratorError1=false,_iteratorError1=undefined;try{for(var _iterator1=r[Symbol.iterator](),_step1;!(_iteratorNormalCompletion1=(_step1=_iterator1.next()).done);_iteratorNormalCompletion1=true){var n10=_step1.value;if(n10.value=n10.tValue,n10.owned)for(var o=0,s=n10.owned.length;o=0;t--)q0(e.tOwned[t]);delete e.tOwned}if(ct&&ct.running&&e.pure)F4e(e,!0);else if(e.owned){for(t=e.owned.length-1;t>=0;t--)q0(e.owned[t]);e.owned=null}if(e.cleanups){for(t=e.cleanups.length-1;t>=0;t--)e.cleanups[t]();e.cleanups=null}ct&&ct.running?e.tState=0:e.state=0}function F4e(e,t){if(t||(e.tState=0,ct.disposed.add(e)),e.owned)for(var a=0;a1&&arguments[1]!==void 0?arguments[1]:Ka;var a=I4e&&t&&t.context&&t.context[I4e],r=Ozt(e);if(!a)throw r;uo?uo.push({fn:function fn1(){E4e(r,a,t)},state:Ys}):E4e(r,a,t)}function mL(e){if(typeof e=="function"&&!e.length)return mL(e());if(Array.isArray(e)){var t=[];for(var a=0;a2&&arguments[2]!==void 0?arguments[2]:{};var r=[],i=[],n=[],o=0,s=t.length>1?[]:null;return ln(function(){return S4e(n)}),function(){var m=function m(f){if(n[l]=f,s){var _Pa=_sliced_to_array(Pa(l),2),g=_Pa[0],h=_Pa[1];return s[l]=h,t(u[l],g)}return t(u[l])};var u=e()||[],c=u.length,p,l;return u[mC],gs(function(){var f,g,h,_,A,x,y,v,I;if(c===0)o!==0&&(S4e(n),n=[],r=[],i=[],o=0,s&&(s=[])),a.fallback&&(r=[Fzt],i[0]=y1(function(b){return n[0]=b,a.fallback()}),o=1);else if(o===0){for(i=new Array(c),l=0;l=x&&v>=x&&r[y]===u[v];y--,v--)h[v]=i[y],_[v]=n[y],s&&(A[v]=s[y]);for(f=new Map,g=new Array(v+1),l=v;l>=x;l--)I=u[l],p=f.get(I),g[l]=p===void 0?-1:p,f.set(I,l);for(p=x;p<=y;p++)I=r[p],l=f.get(I),l!==void 0&&l!==-1?(h[l]=i[p],_[l]=n[p],s&&(A[l]=s[p]),l=g[l],f.set(I,l)):n[p]();for(l=x;l=0;s--){var u=cL(e[s])[o];if(u!==void 0)return u}},has:function has(o){for(var s=e.length-1;s>=0;s--)if(o in cL(e[s]))return!0;return!1},keys:function keys(){var _o1;var o=[];for(var s=0;s=0;o10--){var _loop=function(c){var p=u[c];if(p==="__proto__"||p==="constructor")return"continue";var l=Object.getOwnPropertyDescriptor(s6,p);if(!r[p])r[p]=l.get?{enumerable:!0,configurable:!0,get:Uzt.bind(a[p]=[l.get.bind(s6)])}:l.value!==void 0?l:void 0;else{var m=a[p];m&&(l.get?m.push(l.get.bind(s6)):l.value!==void 0&&m.push(function(){return l.value}))}};var s6=e[o10];if(!s6)continue;var u=Object.getOwnPropertyNames(s6);for(var c=u.length-1;c>=0;c--)_loop(c)}var i={},n=Object.keys(r);for(var o11=n.length-1;o11>=0;o11--){var s10=n[o11],u6=r[s10];u6&&u6.get?Object.defineProperty(i,s10,u6):i[s10]=u6?u6.value:void 0}return i}var q4e=function(e){return"Stale read from <".concat(e,">.")};function Qr(e){var t="fallback"in e&&{fallback:function(){return e.fallback}};return Rr(qzt(function(){return e.each},e.children,t||void 0))}function Ct(e){var t=e.keyed,a=Rr(function(){return e.when},void 0,void 0),r=t?a:Rr(a,void 0,{equals:function(i,n){return!i==!n}});return Rr(function(){var i=r();if(i){var n=e.children;return typeof n=="function"&&n.length>0?gs(function(){return n(t?i:function(){if(!gs(r))throw q4e("Show");return a()})}):n}return e.fallback},void 0,void 0)}function qf(e){var t=Rzt(function(){return e.children}),a=Rr(function(){var _loop=function(o){var s=o,u=i[o],c=n,p=Rr(function(){return c()?void 0:u.when},void 0,void 0),l=u.keyed?p:Rr(p,void 0,{equals:function(m,f){return!m==!f}});n=function(){return c()||(l()?[s,p,u]:void 0)}};var r=t(),i=Array.isArray(r)?r:[r],n=function(){};for(var o=0;o0?gs(function(){return s(o.keyed?n():function(){var c;if(((c=gs(a)())==null?void 0:c[0])!==i)throw q4e("Match");return n()})}):s},void 0,void 0)}function Uu(e){return e}var Gzt=["allowfullscreen","async","alpha","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected","adauctionheaders","browsingtopics","credentialless","defaultchecked","defaultmuted","defaultselected","defer","disablepictureinpicture","disableremoteplayback","preservespitch","shadowrootclonable","shadowrootcustomelementregistry","shadowrootdelegatesfocus","shadowrootserializable","sharedstoragewritable"],iar=new Set(["className","value","readOnly","noValidate","formNoValidate","isMap","noModule","playsInline","adAuctionHeaders","allowFullscreen","browsingTopics","defaultChecked","defaultMuted","defaultSelected","disablePictureInPicture","disableRemotePlayback","preservesPitch","shadowRootClonable","shadowRootCustomElementRegistry","shadowRootDelegatesFocus","shadowRootSerializable","sharedStorageWritable"].concat(_to_consumable_array(Gzt)));var U4e=new Set(["beforeinput","click","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"]);var Qi=function(e){return Rr(function(){return e()})};function zzt(e,t,a){var r=a.length,i=t.length,n=r,o=0,s=0,u=t[i-1].nextSibling,c=null;for(;op10-s){var g=t[o];for(;s3&&arguments[3]!==void 0?arguments[3]:{};var i;return y1(function(n){i=n,t===document?e():Ae(t,e(),t.firstChild?null:void 0,a)},r.owner),function(){i(),t.textContent=""}}function Ue(e,t,a,r){var i,n=function(){var s=r?document.createElementNS("http://www.w3.org/1998/Math/MathML","template"):document.createElement("template");return s.innerHTML=e,a?s.content.firstChild.firstChild:r?s.firstChild:s.content.firstChild},o=t?function(){return gs(function(){return document.importNode(i||(i=n()),!0)})}:function(){return(i||(i=n())).cloneNode(!0)};return o.cloneNode=o,o}function ur(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:window.document;var a=t[L4e]||(t[L4e]=new Set);for(var r=0,i=e.length;r2&&arguments[2]!==void 0?arguments[2]:null;for(var r=0,i=t.length;r=0;o--){var s=t[o];if(i!==s){var u=s.parentNode===e;!n&&!o?u?e.replaceChild(i,s):e.insertBefore(i,a):u&&s.remove()}else n=!0}}else e.insertBefore(i,a);return[i]}var nar=Symbol();var Hzt="http://www.w3.org/2000/svg";function Wzt(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0;return t?document.createElementNS(Hzt,e):document.createElement(e,{is:a})}function yC(e){var t=e.useShadow,a=document.createTextNode(""),r=function(){return e.mount||document.body},i=_C(),n,o=!!Pr.context;return Ii(function(){o&&(_C().user=o=!1),n||(n=R4e(i,function(){return Rr(function(){return e.children})}));var s=r();if(_instanceof(s,HTMLHeadElement)){var _Pa=_sliced_to_array(Pa(!1),2),u=_Pa[0],c=_Pa[1],p=function(){return c(!0)};y1(function(l){return Ae(s,function(){return u()?l():n()},null)}),ln(p)}else{var u6=Wzt(e.isSVG?"g":"div",e.isSVG),c6=t&&u6.attachShadow?u6.attachShadow({mode:"open"}):u6;Object.defineProperty(u6,"_$host",{get:function get(){return a.parentNode},configurable:!0}),Ae(c6,n),s.appendChild(u6),e.ref&&e.ref(u6),ln(function(){return s.removeChild(u6)})}},void 0,{render:!o}),a}var hL=Symbol("store-raw"),E1=Symbol("store-node"),Kp=Symbol("store-has"),H4e=Symbol("store-self");function W4e(e){var t=e[Ql];if(!t&&(Object.defineProperty(e,Ql,{value:t=new Proxy(e,Jzt)}),!Array.isArray(e))){var a=Object.keys(e),r=Object.getOwnPropertyDescriptors(e);for(var i=0,n=a.length;i1&&arguments[1]!==void 0?arguments[1]:new Set;var a,r,i,n;if(a=e!=null&&e[hL])return a;if(!L0(e)||t.has(e))return e;if(Array.isArray(e)){Object.isFrozen(e)?e=e.slice(0):t.add(e);for(var o=0,s=e.length;o3&&arguments[3]!==void 0?arguments[3]:!1;if(!r&&e[t]===a)return;var i=e[t],n=e.length;a===void 0?(delete e[t],e[Kp]&&e[Kp][t]&&i!==void 0&&e[Kp][t].$()):(e[t]=a,e[Kp]&&e[Kp][t]&&i===void 0&&e[Kp][t].$());var o=wC(e,E1),s;if((s=xy(o,t,i))&&s.$(function(){return a}),Array.isArray(e)&&e.length!==n){for(var u=e.length;u2&&arguments[2]!==void 0?arguments[2]:[];var r,i=e;if(t.length>1){r=t.shift();var o=typeof r==="undefined"?"undefined":_type_of(r),s=Array.isArray(e);if(Array.isArray(r)){for(var u=0;u1){_y(e[r],t,[r].concat(a));return}i=e[r],a=[r].concat(a)}var n=t[0];typeof n=="function"&&(n=n(i,a),n===i)||r===void 0&&n==null||(n=S1(n),r===void 0||L0(i)&&L0(n)&&!Array.isArray(n)?K4e(i,n):zu(e,r,n))}function bC(){for(var _len=arguments.length,_tmp=new Array(_len),_key=0;_key<_len;_key++){_tmp[_key]=arguments[_key]}var _tmp1=_sliced_to_array(_tmp,2),e=_tmp1[0],t=_tmp1[1];var a=S1(e||{}),r=Array.isArray(a),i=W4e(a);function n(){for(var _len=arguments.length,o=new Array(_len),_key=0;_key<_len;_key++){o[_key]=arguments[_key]}P4e(function(){r&&o.length===1?Zzt(a,o[0]):_y(a,o)})}return[i,n]}var _L=Symbol("store-root");function C1(e,t,a,r,i){var n=t[a];if(e===n)return;var o=Array.isArray(e);if(a!==_L&&(!L0(e)||!L0(n)||o!==Array.isArray(n)||i&&e[i]!==n[i])){zu(t,a,e);return}if(o){if(e.length&&n.length&&(!r||i&&e[0]&&e[0][i]!=null)){var c,p,l,m,f,g,h,_;for(l=0,m=Math.min(n.length,e.length);l=l&&f>=l&&(n[m]===e[f]||i&&n[m]&&e[f]&&n[m][i]&&n[m][i]===e[f][i]);m--,f--)A[f]=n[m];if(l>f||l>m){for(p=l;p<=f;p++)zu(n,p,e[p]);for(;pe.length&&zu(n,"length",e.length);return}for(h=new Array(f+1),p=f;p>=l;p--)g=e[p],_=i&&g?g[i]:g,c=x.get(_),h[p]=c===void 0?-1:c,x.set(_,p);for(c=l;c<=m;c++)g=n[c],_=i&&g?g[i]:g,p=x.get(_),p!==void 0&&p!==-1&&(A[p]=n[c],p=h[p],x.set(_,p));for(p=l;pe.length&&zu(n,"length",e.length);return}var s=Object.keys(e);for(var c10=0,p10=s.length;c101&&arguments[1]!==void 0?arguments[1]:{};var a=t.merge,tmp=t.key,r=tmp===void 0?"id":tmp,i=S1(e);return function(n){if(!L0(n)||!L0(i))return i;var o=C1(i,_define_property({},_L,n),_L,a,r);return o===void 0?n:o}}function B1(e,t,a,r){var o;r!=null&&r.delegateEvents&&ur(Array.from(U4e),(o=t.ownerDocument)!=null?o:document);var i,n=G4e(function(){var _bC=_sliced_to_array(bC(a),2),s=_bC[0],u=_bC[1];return i=function(c){return u(J4e(c))},Ie(e,s)},t);return{update:function(s){return i(s)},destroy:n}}var Y6e=require("obsidian");function Yzt(e){return e?_object_spread_props(_object_spread({},e),{inputTokenDetails:e.inputTokenDetails?_object_spread({},e.inputTokenDetails):e.inputTokenDetails,outputTokenDetails:e.outputTokenDetails?_object_spread({},e.outputTokenDetails):e.outputTokenDetails}):void 0}function IC(e){var t,a;return e?typeof e.totalTokens=="number"&&e.totalTokens>0?e.totalTokens:Math.max(0,((t=e.inputTokens)!=null?t:0)+((a=e.outputTokens)!=null?a:0)):0}function xL(e){return Array.isArray(e.content)?_object_spread_props(_object_spread({},e),{content:e.content.map(function(t){return t.type==="tool-call"&&t.input&&_type_of(t.input)=="object"?_object_spread_props(_object_spread({},t),{input:_object_spread({},t.input)}):_object_spread({},t)})}):_object_spread({},e)}function Ay(e){switch(e.operation){case"create":return{vaultPath:e.vaultPath,operation:"create",before:{kind:e.before.kind}};case"update":return{vaultPath:e.vaultPath,operation:"update",before:{kind:"file",contentCompressed:e.before.contentCompressed?_object_spread({},e.before.contentCompressed):void 0,contentBase64:e.before.contentBase64}};case"delete":return{vaultPath:e.vaultPath,operation:"delete",before:e.before.kind==="dir"?{kind:"dir"}:{kind:"file",contentCompressed:e.before.contentCompressed?_object_spread({},e.before.contentCompressed):void 0,contentBase64:e.before.contentBase64}}}}function vy(e){var t,a;return _object_spread_props(_object_spread({},e),{reversibleOps:(t=e.reversibleOps)==null?void 0:t.map(Ay),message:xL(e.message),meta:e.meta?_object_spread_props(_object_spread({},e.meta),{usage:Yzt(e.meta.usage)}):void 0,todos:(a=e.todos)==null?void 0:a.map(Z4e)})}function Xzt(e){return _object_spread({},e)}function Z4e(e){return _object_spread({},e)}function Y4e(e){return _object_spread_props(_object_spread({},e),{model:e.model?_object_spread({},e.model):void 0,inferenceParams:e.inferenceParams?_object_spread({},e.inferenceParams):void 0,fragments:e.fragments.map(function(t){return _object_spread_props(_object_spread({},t),{messages:t.messages.map(vy),readVaultPaths:t.readVaultPaths?_to_consumable_array(t.readVaultPaths):void 0})}),tasks:e.tasks.map(Xzt)})}function yy(e){return e.fragments.find(function(t){return t.id===e.activeFragmentId})||e.fragments[e.fragments.length-1]}function X4e(e){var a;var t=yy(e);if(!t)return[];for(var r=t.messages.length-1;r>=0;r-=1){var i=(a=t.messages[r])==null?void 0:a.todos;if(i)return i.map(Z4e)}return[]}function e6e(e){return e.status==="completed"||e.status==="failed"||e.status==="cancelled"}function t6e(e){return _object_spread_props(_object_spread({},e),{status:"queued"})}function a6e(e,t){return _object_spread_props(_object_spread({},e),{status:"running",startedAt:t})}function r6e(e,t){return _object_spread_props(_object_spread({},e),{status:"running",startedAt:t})}function i6e(e,t,a,r){return _object_spread_props(_object_spread({},e),{status:"completed",summary:t,sourceCount:a,finishedAt:r})}function n6e(e,t,a,r,i){return _object_spread(_object_spread_props(_object_spread({},e),{status:"failed",error:t,finishedAt:a,failureStage:r}),e.status==="running"?{startedAt:e.startedAt}:{},typeof i=="number"?{sourceCount:i}:{})}function Lf(e,t,a,r){return _object_spread(_object_spread_props(_object_spread({},e),{status:"cancelled",cancelReason:t,finishedAt:a,summary:r}),e.status==="running"?{startedAt:e.startedAt}:{})}function Wc(e,t){for(var _i1=0,_iter=["status","startedAt","finishedAt","summary","error","failureStage","cancelReason","sourceCount"];_i1<_iter.length;_i1++){var a=_iter[_i1];delete e[a]}return Object.assign(e,t),e}function o6e(e){var r,i,n,o;var t=(r=e==null?void 0:e.ownerDocument)!=null?r:document,a=(n=(i=e==null?void 0:e.getBoundingClientRect().width)!=null?i:e==null?void 0:e.clientWidth)!=null?n:0;return e!=null&&e.isConnected&&a>=486?{mountEl:e,contained:!0}:{mountEl:(o=t.body)!=null?o:document.body,contained:!1}}function kC(e,t){var i;if(!(t!=null&&t.contained))return;var a=e,r=a.containerEl;!r||!t.mountEl.isConnected||(t.mountEl.appendChild(r),r.classList.add("ns-chatbox-contained-modal-container"),(i=a.modalEl)==null||i.classList.add("ns-chatbox-contained-modal"))}var s6e=function(e){return e!=null&&(e=Object.getPrototypeOf(e),e===Array.prototype||e===Object.prototype)};function u6e(e,t,a){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=Object.entries(t)[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var _step_value=_sliced_to_array(_step.value,2),r=_step_value[0],i=_step_value[1];var n="".concat(a,".").concat(r);e[n]=i,s6e(i)&&u6e(e,i,n)}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}}function l6e(e){var t=_object_spread({},e);var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;try{for(var _iterator=Object.entries(e)[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var _step_value=_sliced_to_array(_step.value,2),a=_step_value[0],r=_step_value[1];s6e(r)&&u6e(t,r,a)}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return t}var c6e=function(e,t){var _iteratorNormalCompletion=true,_didIteratorError=false,_iteratorError=undefined;if(t)try{for(var _iterator=Object.entries(t)[Symbol.iterator](),_step;!(_iteratorNormalCompletion=(_step=_iterator.next()).done);_iteratorNormalCompletion=true){var _step_value=_sliced_to_array(_step.value,2),a=_step_value[0],r=_step_value[1];e=e.replace(new RegExp("{{\\s*".concat(a,"\\s*}}"),"g"),r)}}catch(err){_didIteratorError=true;_iteratorError=err}finally{try{if(!_iteratorNormalCompletion&&_iterator.return!=null){_iterator.return()}}finally{if(_didIteratorError){throw _iteratorError}}}return e},ejt=function(e){return e};function p6e(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:ejt;return function(a){for(var _len=arguments.length,r=new Array(_len>1?_len-1:0),_key=1;_key<_len;_key++){r[_key-1]=arguments[_key]}var n;a[0]==="."&&(a=a.slice(1));var i=(n=e())==null?void 0:n[a];switch(typeof i==="undefined"?"undefined":_type_of(i)){case"function":return i.apply(void 0,_to_consumable_array(r));case"string":return t(i,r[0]);default:return i}}}var ajt={en:xk,zh:Ak};function rjt(e){switch(e.split("-")[0].toLowerCase()){case"zh":return"zh";default:return"en"}}var _Pa1=_sliced_to_array(Pa(rjt(navigator.language)),2),ijt=_Pa1[0],yar=_Pa1[1],njt=Rr(function(){return l6e(ajt[ijt()])}),Ce=p6e(njt,c6e);var d6e=Ue("