rmapi-js 11.0.0 → 11.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/devices.d.ts +22 -0
- package/dist/devices.js +20 -0
- package/dist/index.d.ts +35 -0
- package/dist/index.js +8 -1
- package/dist/raw.d.ts +23 -18
- package/dist/rmapi-js.esm.min.js +6 -6
- package/package.json +1 -1
package/dist/rmapi-js.esm.min.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
var $q=Object.create;var{getPrototypeOf:Qq,defineProperty:N6,getOwnPropertyNames:B7,getOwnPropertyDescriptor:Jq}=Object,U7=Object.prototype.hasOwnProperty;function W7($){return this[$]}var qq,Xq,V7=($,Q,J)=>{var q=$!=null&&typeof $==="object";if(q){var X=Q?qq??=new WeakMap:Xq??=new WeakMap,Y=X.get($);if(Y)return Y}J=$!=null?$q(Qq($)):{};let G=Q||!$||!$.__esModule?N6(J,"default",{value:$,enumerable:!0}):J;for(let B of B7($))if(!U7.call(G,B))N6(G,B,{get:W7.bind($,B),enumerable:!0});if(q)X.set($,G);return G},q2=($)=>{var Q=(G7??=new WeakMap).get($),J;if(Q)return Q;if(Q=N6({},"__esModule",{value:!0}),$&&typeof $==="object"||typeof $==="function"){for(var q of B7($))if(!U7.call(Q,q))N6(Q,q,{get:W7.bind($,q),enumerable:!(J=Jq($,q))||J.enumerable})}return G7.set($,Q),Q},G7,j0=($,Q)=>()=>(Q||$((Q={exports:{}}).exports,Q),Q.exports);var Yq=($)=>$;function Gq($,Q){this[$]=Yq.bind(null,Q)}var B5=($,Q)=>{for(var J in Q)N6($,J,{get:Q[J],enumerable:!0,configurable:!0,set:Gq.bind(Q,J)})};var K7=($,Q)=>()=>($&&(Q=$($=0)),Q);var g2={};B5(g2,{transcode:()=>dq,resolveObjectURL:()=>cq,kStringMaxLength:()=>N7,kMaxLength:()=>A6,isUtf8:()=>pq,isAscii:()=>lq,default:()=>iq,constants:()=>Fq,btoa:()=>Hq,atob:()=>jq,INSPECT_MAX_BYTES:()=>O7,File:()=>Mq,Buffer:()=>b,Blob:()=>wq});function Bq($){var Q=$.length;if(Q%4>0)throw Error("Invalid string. Length must be a multiple of 4");var J=$.indexOf("=");if(J===-1)J=Q;var q=J===Q?0:4-J%4;return[J,q]}function Uq($,Q){return($+Q)*3/4-Q}function Wq($){var Q,J=Bq($),q=J[0],X=J[1],Y=new Uint8Array(Uq(q,X)),G=0,B=X>0?q-4:q,W;for(W=0;W<B;W+=4)Q=X2[$.charCodeAt(W)]<<18|X2[$.charCodeAt(W+1)]<<12|X2[$.charCodeAt(W+2)]<<6|X2[$.charCodeAt(W+3)],Y[G++]=Q>>16&255,Y[G++]=Q>>8&255,Y[G++]=Q&255;if(X===2)Q=X2[$.charCodeAt(W)]<<2|X2[$.charCodeAt(W+1)]>>4,Y[G++]=Q&255;if(X===1)Q=X2[$.charCodeAt(W)]<<10|X2[$.charCodeAt(W+1)]<<4|X2[$.charCodeAt(W+2)]>>2,Y[G++]=Q>>8&255,Y[G++]=Q&255;return Y}function Vq($){return z2[$>>18&63]+z2[$>>12&63]+z2[$>>6&63]+z2[$&63]}function Kq($,Q,J){var q,X=[];for(var Y=Q;Y<J;Y+=3)q=($[Y]<<16&16711680)+($[Y+1]<<8&65280)+($[Y+2]&255),X.push(Vq(q));return X.join("")}function j7($){var Q,J=$.length,q=J%3,X=[],Y=16383;for(var G=0,B=J-q;G<B;G+=Y)X.push(Kq($,G,G+Y>B?B:G+Y));if(q===1)Q=$[J-1],X.push(z2[Q>>2]+z2[Q<<4&63]+"==");else if(q===2)Q=($[J-2]<<8)+$[J-1],X.push(z2[Q>>10]+z2[Q>>4&63]+z2[Q<<2&63]+"=");return X.join("")}function G8($,Q,J,q,X){var Y,G,B=X*8-q-1,W=(1<<B)-1,U=W>>1,V=-7,L=J?X-1:0,w=J?-1:1,M=$[Q+L];L+=w,Y=M&(1<<-V)-1,M>>=-V,V+=B;for(;V>0;Y=Y*256+$[Q+L],L+=w,V-=8);G=Y&(1<<-V)-1,Y>>=-V,V+=q;for(;V>0;G=G*256+$[Q+L],L+=w,V-=8);if(Y===0)Y=1-U;else if(Y===W)return G?NaN:(M?-1:1)*(1/0);else G=G+Math.pow(2,q),Y=Y-U;return(M?-1:1)*G*Math.pow(2,Y-q)}function z7($,Q,J,q,X,Y){var G,B,W,U=Y*8-X-1,V=(1<<U)-1,L=V>>1,w=X===23?Math.pow(2,-24)-Math.pow(2,-77):0,M=q?0:Y-1,y=q?1:-1,x=Q<0||Q===0&&1/Q<0?1:0;if(Q=Math.abs(Q),isNaN(Q)||Q===1/0)B=isNaN(Q)?1:0,G=V;else{if(G=Math.floor(Math.log(Q)/Math.LN2),Q*(W=Math.pow(2,-G))<1)G--,W*=2;if(G+L>=1)Q+=w/W;else Q+=w*Math.pow(2,1-L);if(Q*W>=2)G++,W/=2;if(G+L>=V)B=0,G=V;else if(G+L>=1)B=(Q*W-1)*Math.pow(2,X),G=G+L;else B=Q*Math.pow(2,L-1)*Math.pow(2,X),G=0}for(;X>=8;$[J+M]=B&255,M+=y,B/=256,X-=8);G=G<<X|B,U+=X;for(;U>0;$[J+M]=G&255,M+=y,G/=256,U-=8);$[J+M-y]|=x*128}function Z2($){if($>A6)throw RangeError('The value "'+$+'" is invalid for option "size"');let Q=new Uint8Array($);return Object.setPrototypeOf(Q,b.prototype),Q}function j5($,Q,J){return class extends J{constructor(){super();Object.defineProperty(this,"message",{value:Q.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${$}]`,this.stack,delete this.name}get code(){return $}set code(q){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:q,writable:!0})}toString(){return`${this.name} [${$}]: ${this.message}`}}}function b($,Q,J){if(typeof $==="number"){if(typeof Q==="string")throw TypeError('The "string" argument must be of type string. Received type number');return M5($)}return A7($,Q,J)}function A7($,Q,J){if(typeof $==="string")return Nq($,Q);if(ArrayBuffer.isView($))return Aq($);if($==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof $);if(O2($,ArrayBuffer)||$&&O2($.buffer,ArrayBuffer))return K5($,Q,J);if(typeof SharedArrayBuffer<"u"&&(O2($,SharedArrayBuffer)||$&&O2($.buffer,SharedArrayBuffer)))return K5($,Q,J);if(typeof $==="number")throw TypeError('The "value" argument must not be of type number. Received type number');let q=$.valueOf&&$.valueOf();if(q!=null&&q!==$)return b.from(q,Q,J);let X=Dq($);if(X)return X;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof $[Symbol.toPrimitive]==="function")return b.from($[Symbol.toPrimitive]("string"),Q,J);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof $)}function D7($){if(typeof $!=="number")throw TypeError('"size" argument must be of type number');else if($<0)throw RangeError('The value "'+$+'" is invalid for option "size"')}function Oq($,Q,J){if(D7($),$<=0)return Z2($);if(Q!==void 0)return typeof J==="string"?Z2($).fill(Q,J):Z2($).fill(Q);return Z2($)}function M5($){return D7($),Z2($<0?0:w5($)|0)}function Nq($,Q){if(typeof Q!=="string"||Q==="")Q="utf8";if(!b.isEncoding(Q))throw TypeError("Unknown encoding: "+Q);let J=P7($,Q)|0,q=Z2(J),X=q.write($,Q);if(X!==J)q=q.slice(0,X);return q}function V5($){let Q=$.length<0?0:w5($.length)|0,J=Z2(Q);for(let q=0;q<Q;q+=1)J[q]=$[q]&255;return J}function Aq($){if(O2($,Uint8Array)){let Q=new Uint8Array($);return K5(Q.buffer,Q.byteOffset,Q.byteLength)}return V5($)}function K5($,Q,J){if(Q<0||$.byteLength<Q)throw RangeError('"offset" is outside of buffer bounds');if($.byteLength<Q+(J||0))throw RangeError('"length" is outside of buffer bounds');let q;if(Q===void 0&&J===void 0)q=new Uint8Array($);else if(J===void 0)q=new Uint8Array($,Q);else q=new Uint8Array($,Q,J);return Object.setPrototypeOf(q,b.prototype),q}function Dq($){if(b.isBuffer($)){let Q=w5($.length)|0,J=Z2(Q);if(J.length===0)return J;return $.copy(J,0,0,Q),J}if($.length!==void 0){if(typeof $.length!=="number"||Number.isNaN($.length))return Z2(0);return V5($)}if($.type==="Buffer"&&Array.isArray($.data))return V5($.data)}function w5($){if($>=A6)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+A6.toString(16)+" bytes");return $|0}function P7($,Q){if(b.isBuffer($))return $.length;if(ArrayBuffer.isView($)||O2($,ArrayBuffer))return $.byteLength;if(typeof $!=="string")throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof $);let J=$.length,q=arguments.length>2&&arguments[2]===!0;if(!q&&J===0)return 0;let X=!1;for(;;)switch(Q){case"ascii":case"latin1":case"binary":return J;case"utf8":case"utf-8":return H5($).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return J*2;case"hex":return J>>>1;case"base64":return Z7($).length;default:if(X)return q?-1:H5($).length;Q=(""+Q).toLowerCase(),X=!0}}function Pq($,Q,J){let q=!1;if(Q===void 0||Q<0)Q=0;if(Q>this.length)return"";if(J===void 0||J>this.length)J=this.length;if(J<=0)return"";if(J>>>=0,Q>>>=0,J<=Q)return"";if(!$)$="utf8";while(!0)switch($){case"hex":return gq(this,Q,J);case"utf8":case"utf-8":return R7(this,Q,J);case"ascii":return Tq(this,Q,J);case"latin1":case"binary":return Zq(this,Q,J);case"base64":return vq(this,Q,J);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return xq(this,Q,J);default:if(q)throw TypeError("Unknown encoding: "+$);$=($+"").toLowerCase(),q=!0}}function M1($,Q,J){let q=$[Q];$[Q]=$[J],$[J]=q}function C7($,Q,J,q,X){if($.length===0)return-1;if(typeof J==="string")q=J,J=0;else if(J>2147483647)J=2147483647;else if(J<-2147483648)J=-2147483648;if(J=+J,Number.isNaN(J))J=X?0:$.length-1;if(J<0)J=$.length+J;if(J>=$.length)if(X)return-1;else J=$.length-1;else if(J<0)if(X)J=0;else return-1;if(typeof Q==="string")Q=b.from(Q,q);if(b.isBuffer(Q)){if(Q.length===0)return-1;return w7($,Q,J,q,X)}else if(typeof Q==="number"){if(Q=Q&255,typeof Uint8Array.prototype.indexOf==="function")if(X)return Uint8Array.prototype.indexOf.call($,Q,J);else return Uint8Array.prototype.lastIndexOf.call($,Q,J);return w7($,[Q],J,q,X)}throw TypeError("val must be string, number or Buffer")}function w7($,Q,J,q,X){let Y=1,G=$.length,B=Q.length;if(q!==void 0){if(q=String(q).toLowerCase(),q==="ucs2"||q==="ucs-2"||q==="utf16le"||q==="utf-16le"){if($.length<2||Q.length<2)return-1;Y=2,G/=2,B/=2,J/=2}}function W(V,L){if(Y===1)return V[L];else return V.readUInt16BE(L*Y)}let U;if(X){let V=-1;for(U=J;U<G;U++)if(W($,U)===W(Q,V===-1?0:U-V)){if(V===-1)V=U;if(U-V+1===B)return V*Y}else{if(V!==-1)U-=U-V;V=-1}}else{if(J+B>G)J=G-B;for(U=J;U>=0;U--){let V=!0;for(let L=0;L<B;L++)if(W($,U+L)!==W(Q,L)){V=!1;break}if(V)return U}}return-1}function Cq($,Q,J,q){J=Number(J)||0;let X=$.length-J;if(!q)q=X;else if(q=Number(q),q>X)q=X;let Y=Q.length;if(q>Y/2)q=Y/2;let G;for(G=0;G<q;++G){let B=parseInt(Q.substr(G*2,2),16);if(Number.isNaN(B))return G;$[J+G]=B}return G}function Rq($,Q,J,q){return B8(H5(Q,$.length-J),$,J,q)}function Iq($,Q,J,q){return B8(bq(Q),$,J,q)}function Sq($,Q,J,q){return B8(Z7(Q),$,J,q)}function Eq($,Q,J,q){return B8(hq(Q,$.length-J),$,J,q)}function vq($,Q,J){if(Q===0&&J===$.length)return j7($);else return j7($.slice(Q,J))}function R7($,Q,J){J=Math.min($.length,J);let q=[],X=Q;while(X<J){let Y=$[X],G=null,B=Y>239?4:Y>223?3:Y>191?2:1;if(X+B<=J){let W,U,V,L;switch(B){case 1:if(Y<128)G=Y;break;case 2:if(W=$[X+1],(W&192)===128){if(L=(Y&31)<<6|W&63,L>127)G=L}break;case 3:if(W=$[X+1],U=$[X+2],(W&192)===128&&(U&192)===128){if(L=(Y&15)<<12|(W&63)<<6|U&63,L>2047&&(L<55296||L>57343))G=L}break;case 4:if(W=$[X+1],U=$[X+2],V=$[X+3],(W&192)===128&&(U&192)===128&&(V&192)===128){if(L=(Y&15)<<18|(W&63)<<12|(U&63)<<6|V&63,L>65535&&L<1114112)G=L}}}if(G===null)G=65533,B=1;else if(G>65535)G-=65536,q.push(G>>>10&1023|55296),G=56320|G&1023;q.push(G),X+=B}return kq(q)}function kq($){let Q=$.length;if(Q<=F7)return String.fromCharCode.apply(String,$);let J="",q=0;while(q<Q)J+=String.fromCharCode.apply(String,$.slice(q,q+=F7));return J}function Tq($,Q,J){let q="";J=Math.min($.length,J);for(let X=Q;X<J;++X)q+=String.fromCharCode($[X]&127);return q}function Zq($,Q,J){let q="";J=Math.min($.length,J);for(let X=Q;X<J;++X)q+=String.fromCharCode($[X]);return q}function gq($,Q,J){let q=$.length;if(!Q||Q<0)Q=0;if(!J||J<0||J>q)J=q;let X="";for(let Y=Q;Y<J;++Y)X+=mq[$[Y]];return X}function xq($,Q,J){let q=$.slice(Q,J),X="";for(let Y=0;Y<q.length-1;Y+=2)X+=String.fromCharCode(q[Y]+q[Y+1]*256);return X}function _0($,Q,J){if($%1!==0||$<0)throw RangeError("offset is not uint");if($+Q>J)throw RangeError("Trying to access beyond buffer length")}function o0($,Q,J,q,X,Y){if(!b.isBuffer($))throw TypeError('"buffer" argument must be a Buffer instance');if(Q>X||Q<Y)throw RangeError('"value" argument is out of bounds');if(J+q>$.length)throw RangeError("Index out of range")}function I7($,Q,J,q,X){T7(Q,q,X,$,J,7);let Y=Number(Q&BigInt(4294967295));$[J++]=Y,Y=Y>>8,$[J++]=Y,Y=Y>>8,$[J++]=Y,Y=Y>>8,$[J++]=Y;let G=Number(Q>>BigInt(32)&BigInt(4294967295));return $[J++]=G,G=G>>8,$[J++]=G,G=G>>8,$[J++]=G,G=G>>8,$[J++]=G,J}function S7($,Q,J,q,X){T7(Q,q,X,$,J,7);let Y=Number(Q&BigInt(4294967295));$[J+7]=Y,Y=Y>>8,$[J+6]=Y,Y=Y>>8,$[J+5]=Y,Y=Y>>8,$[J+4]=Y;let G=Number(Q>>BigInt(32)&BigInt(4294967295));return $[J+3]=G,G=G>>8,$[J+2]=G,G=G>>8,$[J+1]=G,G=G>>8,$[J]=G,J+8}function E7($,Q,J,q,X,Y){if(J+q>$.length)throw RangeError("Index out of range");if(J<0)throw RangeError("Index out of range")}function v7($,Q,J,q,X){if(Q=+Q,J=J>>>0,!X)E7($,Q,J,4,340282346638528860000000000000000000000,-340282346638528860000000000000000000000);return z7($,Q,J,q,23,4),J+4}function k7($,Q,J,q,X){if(Q=+Q,J=J>>>0,!X)E7($,Q,J,8,179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,-179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000);return z7($,Q,J,q,52,8),J+8}function L7($){let Q="",J=$.length,q=$[0]==="-"?1:0;for(;J>=q+4;J-=3)Q=`_${$.slice(J-3,J)}${Q}`;return`${$.slice(0,J)}${Q}`}function fq($,Q,J){if(y1(Q,"offset"),$[Q]===void 0||$[Q+J]===void 0)D6(Q,$.length-(J+1))}function T7($,Q,J,q,X,Y){if($>J||$<Q){let G=typeof Q==="bigint"?"n":"",B;if(Y>3)if(Q===0||Q===BigInt(0))B=`>= 0${G} and < 2${G} ** ${(Y+1)*8}${G}`;else B=`>= -(2${G} ** ${(Y+1)*8-1}${G}) and < 2 ** ${(Y+1)*8-1}${G}`;else B=`>= ${Q}${G} and <= ${J}${G}`;throw new W5("value",B,$)}fq(q,X,Y)}function y1($,Q){if(typeof $!=="number")throw new zq(Q,"number",$)}function D6($,Q,J){if(Math.floor($)!==$)throw y1($,J),new W5(J||"offset","an integer",$);if(Q<0)throw new Lq;throw new W5(J||"offset",`>= ${J?1:0} and <= ${Q}`,$)}function _q($){if($=$.split("=")[0],$=$.trim().replace(yq,""),$.length<2)return"";while($.length%4!==0)$=$+"=";return $}function H5($,Q){Q=Q||1/0;let J,q=$.length,X=null,Y=[];for(let G=0;G<q;++G){if(J=$.charCodeAt(G),J>55295&&J<57344){if(!X){if(J>56319){if((Q-=3)>-1)Y.push(239,191,189);continue}else if(G+1===q){if((Q-=3)>-1)Y.push(239,191,189);continue}X=J;continue}if(J<56320){if((Q-=3)>-1)Y.push(239,191,189);X=J;continue}J=(X-55296<<10|J-56320)+65536}else if(X){if((Q-=3)>-1)Y.push(239,191,189)}if(X=null,J<128){if((Q-=1)<0)break;Y.push(J)}else if(J<2048){if((Q-=2)<0)break;Y.push(J>>6|192,J&63|128)}else if(J<65536){if((Q-=3)<0)break;Y.push(J>>12|224,J>>6&63|128,J&63|128)}else if(J<1114112){if((Q-=4)<0)break;Y.push(J>>18|240,J>>12&63|128,J>>6&63|128,J&63|128)}else throw Error("Invalid code point")}return Y}function bq($){let Q=[];for(let J=0;J<$.length;++J)Q.push($.charCodeAt(J)&255);return Q}function hq($,Q){let J,q,X,Y=[];for(let G=0;G<$.length;++G){if((Q-=2)<0)break;J=$.charCodeAt(G),q=J>>8,X=J%256,Y.push(X),Y.push(q)}return Y}function Z7($){return Wq(_q($))}function B8($,Q,J,q){let X;for(X=0;X<q;++X){if(X+J>=Q.length||X>=$.length)break;Q[X+J]=$[X]}return X}function O2($,Q){return $ instanceof Q||$!=null&&$.constructor!=null&&$.constructor.name!=null&&$.constructor.name===Q.name}function d2($){return typeof BigInt>"u"?uq:$}function uq(){throw Error("BigInt not supported")}function F5($){return()=>{throw Error($+" is not implemented for node:buffer browser polyfill")}}var z2,X2,U5="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",j1,H7,M7,O7=50,A6=2147483647,N7=536870888,Hq,jq,Mq,wq,Fq,Lq,zq,W5,F7=4096,yq,mq,cq,pq,lq=($)=>{for(let Q of $)if(Q.charCodeAt(0)>127)return!1;return!0},dq,iq;var x2=K7(()=>{z2=[],X2=[];for(j1=0,H7=U5.length;j1<H7;++j1)z2[j1]=U5[j1],X2[U5.charCodeAt(j1)]=j1;X2[45]=62;X2[95]=63;M7=typeof Symbol==="function"&&typeof Symbol.for==="function"?Symbol.for("nodejs.util.inspect.custom"):null,Hq=globalThis.btoa,jq=globalThis.atob,Mq=globalThis.File,wq=globalThis.Blob,Fq={MAX_LENGTH:A6,MAX_STRING_LENGTH:N7};Lq=j5("ERR_BUFFER_OUT_OF_BOUNDS",function($){if($)return`${$} is outside of buffer bounds`;return"Attempt to access memory outside buffer bounds"},RangeError),zq=j5("ERR_INVALID_ARG_TYPE",function($,Q){return`The "${$}" argument must be of type number. Received type ${typeof Q}`},TypeError),W5=j5("ERR_OUT_OF_RANGE",function($,Q,J){let q=`The value of "${$}" is out of range.`,X=J;if(Number.isInteger(J)&&Math.abs(J)>4294967296)X=L7(String(J));else if(typeof J==="bigint"){if(X=String(J),J>BigInt(2)**BigInt(32)||J<-(BigInt(2)**BigInt(32)))X=L7(X);X+="n"}return q+=` It must be ${Q}. Received ${X}`,q},RangeError);Object.defineProperty(b.prototype,"parent",{enumerable:!0,get:function(){if(!b.isBuffer(this))return;return this.buffer}});Object.defineProperty(b.prototype,"offset",{enumerable:!0,get:function(){if(!b.isBuffer(this))return;return this.byteOffset}});b.poolSize=8192;b.from=function($,Q,J){return A7($,Q,J)};Object.setPrototypeOf(b.prototype,Uint8Array.prototype);Object.setPrototypeOf(b,Uint8Array);b.alloc=function($,Q,J){return Oq($,Q,J)};b.allocUnsafe=function($){return M5($)};b.allocUnsafeSlow=function($){return M5($)};b.isBuffer=function($){return $!=null&&$._isBuffer===!0&&$!==b.prototype};b.compare=function($,Q){if(O2($,Uint8Array))$=b.from($,$.offset,$.byteLength);if(O2(Q,Uint8Array))Q=b.from(Q,Q.offset,Q.byteLength);if(!b.isBuffer($)||!b.isBuffer(Q))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if($===Q)return 0;let J=$.length,q=Q.length;for(let X=0,Y=Math.min(J,q);X<Y;++X)if($[X]!==Q[X]){J=$[X],q=Q[X];break}if(J<q)return-1;if(q<J)return 1;return 0};b.isEncoding=function($){switch(String($).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};b.concat=function($,Q){if(!Array.isArray($))throw TypeError('"list" argument must be an Array of Buffers');if($.length===0)return b.alloc(0);let J;if(Q===void 0){Q=0;for(J=0;J<$.length;++J)Q+=$[J].length}let q=b.allocUnsafe(Q),X=0;for(J=0;J<$.length;++J){let Y=$[J];if(O2(Y,Uint8Array))if(X+Y.length>q.length){if(!b.isBuffer(Y))Y=b.from(Y);Y.copy(q,X)}else Uint8Array.prototype.set.call(q,Y,X);else if(!b.isBuffer(Y))throw TypeError('"list" argument must be an Array of Buffers');else Y.copy(q,X);X+=Y.length}return q};b.byteLength=P7;b.prototype._isBuffer=!0;b.prototype.swap16=function(){let $=this.length;if($%2!==0)throw RangeError("Buffer size must be a multiple of 16-bits");for(let Q=0;Q<$;Q+=2)M1(this,Q,Q+1);return this};b.prototype.swap32=function(){let $=this.length;if($%4!==0)throw RangeError("Buffer size must be a multiple of 32-bits");for(let Q=0;Q<$;Q+=4)M1(this,Q,Q+3),M1(this,Q+1,Q+2);return this};b.prototype.swap64=function(){let $=this.length;if($%8!==0)throw RangeError("Buffer size must be a multiple of 64-bits");for(let Q=0;Q<$;Q+=8)M1(this,Q,Q+7),M1(this,Q+1,Q+6),M1(this,Q+2,Q+5),M1(this,Q+3,Q+4);return this};b.prototype.toString=function(){let $=this.length;if($===0)return"";if(arguments.length===0)return R7(this,0,$);return Pq.apply(this,arguments)};b.prototype.toLocaleString=b.prototype.toString;b.prototype.equals=function($){if(!b.isBuffer($))throw TypeError("Argument must be a Buffer");if(this===$)return!0;return b.compare(this,$)===0};b.prototype.inspect=function(){let $="",Q=O7;if($=this.toString("hex",0,Q).replace(/(.{2})/g,"$1 ").trim(),this.length>Q)$+=" ... ";return"<Buffer "+$+">"};if(M7)b.prototype[M7]=b.prototype.inspect;b.prototype.compare=function($,Q,J,q,X){if(O2($,Uint8Array))$=b.from($,$.offset,$.byteLength);if(!b.isBuffer($))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof $);if(Q===void 0)Q=0;if(J===void 0)J=$?$.length:0;if(q===void 0)q=0;if(X===void 0)X=this.length;if(Q<0||J>$.length||q<0||X>this.length)throw RangeError("out of range index");if(q>=X&&Q>=J)return 0;if(q>=X)return-1;if(Q>=J)return 1;if(Q>>>=0,J>>>=0,q>>>=0,X>>>=0,this===$)return 0;let Y=X-q,G=J-Q,B=Math.min(Y,G),W=this.slice(q,X),U=$.slice(Q,J);for(let V=0;V<B;++V)if(W[V]!==U[V]){Y=W[V],G=U[V];break}if(Y<G)return-1;if(G<Y)return 1;return 0};b.prototype.includes=function($,Q,J){return this.indexOf($,Q,J)!==-1};b.prototype.indexOf=function($,Q,J){return C7(this,$,Q,J,!0)};b.prototype.lastIndexOf=function($,Q,J){return C7(this,$,Q,J,!1)};b.prototype.write=function($,Q,J,q){if(Q===void 0)q="utf8",J=this.length,Q=0;else if(J===void 0&&typeof Q==="string")q=Q,J=this.length,Q=0;else if(isFinite(Q))if(Q=Q>>>0,isFinite(J)){if(J=J>>>0,q===void 0)q="utf8"}else q=J,J=void 0;else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let X=this.length-Q;if(J===void 0||J>X)J=X;if($.length>0&&(J<0||Q<0)||Q>this.length)throw RangeError("Attempt to write outside buffer bounds");if(!q)q="utf8";let Y=!1;for(;;)switch(q){case"hex":return Cq(this,$,Q,J);case"utf8":case"utf-8":return Rq(this,$,Q,J);case"ascii":case"latin1":case"binary":return Iq(this,$,Q,J);case"base64":return Sq(this,$,Q,J);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Eq(this,$,Q,J);default:if(Y)throw TypeError("Unknown encoding: "+q);q=(""+q).toLowerCase(),Y=!0}};b.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};b.prototype.slice=function($,Q){let J=this.length;if($=~~$,Q=Q===void 0?J:~~Q,$<0){if($+=J,$<0)$=0}else if($>J)$=J;if(Q<0){if(Q+=J,Q<0)Q=0}else if(Q>J)Q=J;if(Q<$)Q=$;let q=this.subarray($,Q);return Object.setPrototypeOf(q,b.prototype),q};b.prototype.readUintLE=b.prototype.readUIntLE=function($,Q,J){if($=$>>>0,Q=Q>>>0,!J)_0($,Q,this.length);let q=this[$],X=1,Y=0;while(++Y<Q&&(X*=256))q+=this[$+Y]*X;return q};b.prototype.readUintBE=b.prototype.readUIntBE=function($,Q,J){if($=$>>>0,Q=Q>>>0,!J)_0($,Q,this.length);let q=this[$+--Q],X=1;while(Q>0&&(X*=256))q+=this[$+--Q]*X;return q};b.prototype.readUint8=b.prototype.readUInt8=function($,Q){if($=$>>>0,!Q)_0($,1,this.length);return this[$]};b.prototype.readUint16LE=b.prototype.readUInt16LE=function($,Q){if($=$>>>0,!Q)_0($,2,this.length);return this[$]|this[$+1]<<8};b.prototype.readUint16BE=b.prototype.readUInt16BE=function($,Q){if($=$>>>0,!Q)_0($,2,this.length);return this[$]<<8|this[$+1]};b.prototype.readUint32LE=b.prototype.readUInt32LE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return(this[$]|this[$+1]<<8|this[$+2]<<16)+this[$+3]*16777216};b.prototype.readUint32BE=b.prototype.readUInt32BE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return this[$]*16777216+(this[$+1]<<16|this[$+2]<<8|this[$+3])};b.prototype.readBigUInt64LE=d2(function($){$=$>>>0,y1($,"offset");let Q=this[$],J=this[$+7];if(Q===void 0||J===void 0)D6($,this.length-8);let q=Q+this[++$]*256+this[++$]*65536+this[++$]*16777216,X=this[++$]+this[++$]*256+this[++$]*65536+J*16777216;return BigInt(q)+(BigInt(X)<<BigInt(32))});b.prototype.readBigUInt64BE=d2(function($){$=$>>>0,y1($,"offset");let Q=this[$],J=this[$+7];if(Q===void 0||J===void 0)D6($,this.length-8);let q=Q*16777216+this[++$]*65536+this[++$]*256+this[++$],X=this[++$]*16777216+this[++$]*65536+this[++$]*256+J;return(BigInt(q)<<BigInt(32))+BigInt(X)});b.prototype.readIntLE=function($,Q,J){if($=$>>>0,Q=Q>>>0,!J)_0($,Q,this.length);let q=this[$],X=1,Y=0;while(++Y<Q&&(X*=256))q+=this[$+Y]*X;if(X*=128,q>=X)q-=Math.pow(2,8*Q);return q};b.prototype.readIntBE=function($,Q,J){if($=$>>>0,Q=Q>>>0,!J)_0($,Q,this.length);let q=Q,X=1,Y=this[$+--q];while(q>0&&(X*=256))Y+=this[$+--q]*X;if(X*=128,Y>=X)Y-=Math.pow(2,8*Q);return Y};b.prototype.readInt8=function($,Q){if($=$>>>0,!Q)_0($,1,this.length);if(!(this[$]&128))return this[$];return(255-this[$]+1)*-1};b.prototype.readInt16LE=function($,Q){if($=$>>>0,!Q)_0($,2,this.length);let J=this[$]|this[$+1]<<8;return J&32768?J|4294901760:J};b.prototype.readInt16BE=function($,Q){if($=$>>>0,!Q)_0($,2,this.length);let J=this[$+1]|this[$]<<8;return J&32768?J|4294901760:J};b.prototype.readInt32LE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return this[$]|this[$+1]<<8|this[$+2]<<16|this[$+3]<<24};b.prototype.readInt32BE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return this[$]<<24|this[$+1]<<16|this[$+2]<<8|this[$+3]};b.prototype.readBigInt64LE=d2(function($){$=$>>>0,y1($,"offset");let Q=this[$],J=this[$+7];if(Q===void 0||J===void 0)D6($,this.length-8);let q=this[$+4]+this[$+5]*256+this[$+6]*65536+(J<<24);return(BigInt(q)<<BigInt(32))+BigInt(Q+this[++$]*256+this[++$]*65536+this[++$]*16777216)});b.prototype.readBigInt64BE=d2(function($){$=$>>>0,y1($,"offset");let Q=this[$],J=this[$+7];if(Q===void 0||J===void 0)D6($,this.length-8);let q=(Q<<24)+this[++$]*65536+this[++$]*256+this[++$];return(BigInt(q)<<BigInt(32))+BigInt(this[++$]*16777216+this[++$]*65536+this[++$]*256+J)});b.prototype.readFloatLE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return G8(this,$,!0,23,4)};b.prototype.readFloatBE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return G8(this,$,!1,23,4)};b.prototype.readDoubleLE=function($,Q){if($=$>>>0,!Q)_0($,8,this.length);return G8(this,$,!0,52,8)};b.prototype.readDoubleBE=function($,Q){if($=$>>>0,!Q)_0($,8,this.length);return G8(this,$,!1,52,8)};b.prototype.writeUintLE=b.prototype.writeUIntLE=function($,Q,J,q){if($=+$,Q=Q>>>0,J=J>>>0,!q){let G=Math.pow(2,8*J)-1;o0(this,$,Q,J,G,0)}let X=1,Y=0;this[Q]=$&255;while(++Y<J&&(X*=256))this[Q+Y]=$/X&255;return Q+J};b.prototype.writeUintBE=b.prototype.writeUIntBE=function($,Q,J,q){if($=+$,Q=Q>>>0,J=J>>>0,!q){let G=Math.pow(2,8*J)-1;o0(this,$,Q,J,G,0)}let X=J-1,Y=1;this[Q+X]=$&255;while(--X>=0&&(Y*=256))this[Q+X]=$/Y&255;return Q+J};b.prototype.writeUint8=b.prototype.writeUInt8=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,1,255,0);return this[Q]=$&255,Q+1};b.prototype.writeUint16LE=b.prototype.writeUInt16LE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,2,65535,0);return this[Q]=$&255,this[Q+1]=$>>>8,Q+2};b.prototype.writeUint16BE=b.prototype.writeUInt16BE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,2,65535,0);return this[Q]=$>>>8,this[Q+1]=$&255,Q+2};b.prototype.writeUint32LE=b.prototype.writeUInt32LE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,4,4294967295,0);return this[Q+3]=$>>>24,this[Q+2]=$>>>16,this[Q+1]=$>>>8,this[Q]=$&255,Q+4};b.prototype.writeUint32BE=b.prototype.writeUInt32BE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,4,4294967295,0);return this[Q]=$>>>24,this[Q+1]=$>>>16,this[Q+2]=$>>>8,this[Q+3]=$&255,Q+4};b.prototype.writeBigUInt64LE=d2(function($,Q=0){return I7(this,$,Q,BigInt(0),BigInt("0xffffffffffffffff"))});b.prototype.writeBigUInt64BE=d2(function($,Q=0){return S7(this,$,Q,BigInt(0),BigInt("0xffffffffffffffff"))});b.prototype.writeIntLE=function($,Q,J,q){if($=+$,Q=Q>>>0,!q){let B=Math.pow(2,8*J-1);o0(this,$,Q,J,B-1,-B)}let X=0,Y=1,G=0;this[Q]=$&255;while(++X<J&&(Y*=256)){if($<0&&G===0&&this[Q+X-1]!==0)G=1;this[Q+X]=($/Y>>0)-G&255}return Q+J};b.prototype.writeIntBE=function($,Q,J,q){if($=+$,Q=Q>>>0,!q){let B=Math.pow(2,8*J-1);o0(this,$,Q,J,B-1,-B)}let X=J-1,Y=1,G=0;this[Q+X]=$&255;while(--X>=0&&(Y*=256)){if($<0&&G===0&&this[Q+X+1]!==0)G=1;this[Q+X]=($/Y>>0)-G&255}return Q+J};b.prototype.writeInt8=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,1,127,-128);if($<0)$=255+$+1;return this[Q]=$&255,Q+1};b.prototype.writeInt16LE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,2,32767,-32768);return this[Q]=$&255,this[Q+1]=$>>>8,Q+2};b.prototype.writeInt16BE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,2,32767,-32768);return this[Q]=$>>>8,this[Q+1]=$&255,Q+2};b.prototype.writeInt32LE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,4,2147483647,-2147483648);return this[Q]=$&255,this[Q+1]=$>>>8,this[Q+2]=$>>>16,this[Q+3]=$>>>24,Q+4};b.prototype.writeInt32BE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,4,2147483647,-2147483648);if($<0)$=4294967295+$+1;return this[Q]=$>>>24,this[Q+1]=$>>>16,this[Q+2]=$>>>8,this[Q+3]=$&255,Q+4};b.prototype.writeBigInt64LE=d2(function($,Q=0){return I7(this,$,Q,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});b.prototype.writeBigInt64BE=d2(function($,Q=0){return S7(this,$,Q,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});b.prototype.writeFloatLE=function($,Q,J){return v7(this,$,Q,!0,J)};b.prototype.writeFloatBE=function($,Q,J){return v7(this,$,Q,!1,J)};b.prototype.writeDoubleLE=function($,Q,J){return k7(this,$,Q,!0,J)};b.prototype.writeDoubleBE=function($,Q,J){return k7(this,$,Q,!1,J)};b.prototype.copy=function($,Q,J,q){if(!b.isBuffer($))throw TypeError("argument should be a Buffer");if(!J)J=0;if(!q&&q!==0)q=this.length;if(Q>=$.length)Q=$.length;if(!Q)Q=0;if(q>0&&q<J)q=J;if(q===J)return 0;if($.length===0||this.length===0)return 0;if(Q<0)throw RangeError("targetStart out of bounds");if(J<0||J>=this.length)throw RangeError("Index out of range");if(q<0)throw RangeError("sourceEnd out of bounds");if(q>this.length)q=this.length;if($.length-Q<q-J)q=$.length-Q+J;let X=q-J;if(this===$&&typeof Uint8Array.prototype.copyWithin==="function")this.copyWithin(Q,J,q);else Uint8Array.prototype.set.call($,this.subarray(J,q),Q);return X};b.prototype.fill=function($,Q,J,q){if(typeof $==="string"){if(typeof Q==="string")q=Q,Q=0,J=this.length;else if(typeof J==="string")q=J,J=this.length;if(q!==void 0&&typeof q!=="string")throw TypeError("encoding must be a string");if(typeof q==="string"&&!b.isEncoding(q))throw TypeError("Unknown encoding: "+q);if($.length===1){let Y=$.charCodeAt(0);if(q==="utf8"&&Y<128||q==="latin1")$=Y}}else if(typeof $==="number")$=$&255;else if(typeof $==="boolean")$=Number($);if(Q<0||this.length<Q||this.length<J)throw RangeError("Out of range index");if(J<=Q)return this;if(Q=Q>>>0,J=J===void 0?this.length:J>>>0,!$)$=0;let X;if(typeof $==="number")for(X=Q;X<J;++X)this[X]=$;else{let Y=b.isBuffer($)?$:b.from($,q),G=Y.length;if(G===0)throw TypeError('The value "'+$+'" is invalid for argument "value"');for(X=0;X<J-Q;++X)this[X+Q]=Y[X%G]}return this};yq=/[^+/0-9A-Za-z-_]/g;mq=function(){let $=Array(256);for(let Q=0;Q<16;++Q){let J=Q*16;for(let q=0;q<16;++q)$[J+q]="0123456789abcdef"[Q]+"0123456789abcdef"[q]}return $}();cq=F5("resolveObjectURL"),pq=F5("isUtf8"),dq=F5("transcode"),iq=b});var C6={};B5(C6,{setMaxListeners:()=>p7,once:()=>u7,listenerCount:()=>l7,init:()=>i2,getMaxListeners:()=>i7,getEventListeners:()=>c7,default:()=>QX,captureRejectionSymbol:()=>_7,addAbortListener:()=>n7,EventEmitter:()=>i2});function b7($,Q){var{_events:J}=$;if(Q[0]??=Error("Unhandled error."),!J)throw Q[0];var q=J[y7];if(q)for(var X of x7.call(q))X.apply($,Q);var Y=J.error;if(!Y)throw Q[0];for(var X of x7.call(Y))X.apply($,Q);return!0}function rq($,Q,J,q){Q.then(void 0,function(X){queueMicrotask(()=>aq($,X,J,q))})}function aq($,Q,J,q){if(typeof $[g7]==="function")$[g7](Q,J,...q);else try{$[w1]=!1,$.emit("error",Q)}finally{$[w1]=!0}}function h7($,Q,J){J.warned=!0;let q=Error(`Possible EventEmitter memory leak detected. ${J.length} ${String(Q)} listeners added to [${$.constructor.name}]. Use emitter.setMaxListeners() to increase limit`);q.name="MaxListenersExceededWarning",q.emitter=$,q.type=Q,q.count=J.length,console.warn(q)}function m7($,Q,...J){this.removeListener($,Q),Q.apply(this,J)}function u7($,Q,J){var q=J?.signal;if(d7(q,"options.signal"),q?.aborted)throw new L5(void 0,{cause:q?.reason});let{resolve:X,reject:Y,promise:G}=$newPromiseCapability(Promise),B=(V)=>{if($.removeListener(Q,W),q!=null)U8(q,"abort",U);Y(V)},W=(...V)=>{if(typeof $.removeListener==="function")$.removeListener("error",B);if(q!=null)U8(q,"abort",U);X(V)};if(f7($,Q,W,{once:!0}),Q!=="error"&&typeof $.once==="function")$.once("error",B);function U(){U8($,Q,W),U8($,"error",B),Y(new L5(void 0,{cause:q?.reason}))}if(q!=null)f7(q,"abort",U,{once:!0});return G}function c7($,Q){return $.listeners(Q)}function p7($,...Q){O5($,"setMaxListeners",0);var J;if(Q&&(J=Q.length))for(let q=0;q<J;q++)Q[q].setMaxListeners($);else F1=$}function l7($,Q){return $.listenerCount(Q)}function U8($,Q,J,q){if(typeof $.removeListener==="function")$.removeListener(Q,J);else $.removeEventListener(Q,J,q)}function f7($,Q,J,q){if(typeof $.on==="function")if(q.once)$.once(Q,J);else $.on(Q,J);else $.addEventListener(Q,J,q)}function _1($,Q,J){let q=TypeError(`The "${$}" argument must be of type ${Q}. Received ${J}`);return q.code="ERR_INVALID_ARG_TYPE",q}function eq($,Q,J){let q=RangeError(`The "${$}" argument is out of range. It must be ${Q}. Received ${J}`);return q.code="ERR_OUT_OF_RANGE",q}function d7($,Q){if($!==void 0&&($===null||typeof $!=="object"||!("aborted"in $)))throw _1(Q,"AbortSignal",$)}function O5($,Q,J,q){if(typeof $!=="number")throw _1(Q,"number",$);if(J!=null&&$<J||q!=null&&$>q||(J!=null||q!=null)&&Number.isNaN($))throw eq(Q,`${J!=null?`>= ${J}`:""}${J!=null&&q!=null?" && ":""}${q!=null?`<= ${q}`:""}`,$)}function P6($){if(typeof $!=="function")throw TypeError("The listener must be a function")}function $X($,Q){if(typeof $!=="boolean")throw _1(Q,"boolean",$)}function i7($){return $?._maxListeners??F1}function n7($,Q){if($===void 0)throw _1("signal","AbortSignal",$);if(d7($,"signal"),typeof Q!=="function")throw _1("listener","function",Q);let J;if($.aborted)queueMicrotask(()=>Q());else $.addEventListener("abort",Q,{__proto__:null,once:!0}),J=()=>{$.removeEventListener("abort",Q)};return{__proto__:null,[Symbol.dispose](){J?.()}}}var z5,w1,y7,nq,oq,g7,_7,x7,F1=10,i2=function($){if(this._events===void 0||this._events===this.__proto__._events)this._events={__proto__:null},this._eventsCount=0;if(this._maxListeners??=void 0,this[w1]=$?.captureRejections?Boolean($?.captureRejections):k0[w1])this.emit=tq},k0,sq=function($,...Q){if($==="error")return b7(this,Q);var{_events:J}=this;if(J===void 0)return!1;var q=J[$];if(q===void 0)return!1;let X=q.length>1?q.slice():q;for(let Y=0,{length:G}=X;Y<G;Y++){let B=X[Y];switch(Q.length){case 0:B.call(this);break;case 1:B.call(this,Q[0]);break;case 2:B.call(this,Q[0],Q[1]);break;case 3:B.call(this,Q[0],Q[1],Q[2]);break;default:B.apply(this,Q);break}}return!0},tq=function($,...Q){if($==="error")return b7(this,Q);var{_events:J}=this;if(J===void 0)return!1;var q=J[$];if(q===void 0)return!1;let X=q.length>1?q.slice():q;for(let Y=0,{length:G}=X;Y<G;Y++){let B=X[Y],W;switch(Q.length){case 0:W=B.call(this);break;case 1:W=B.call(this,Q[0]);break;case 2:W=B.call(this,Q[0],Q[1]);break;case 3:W=B.call(this,Q[0],Q[1],Q[2]);break;default:W=B.apply(this,Q);break}if(W!==void 0&&typeof W?.then==="function"&&W.then===Promise.prototype.then)rq(this,W,$,Q)}return!0},L5,QX;var R6=K7(()=>{z5=Symbol.for,w1=Symbol("kCapture"),y7=z5("events.errorMonitor"),nq=Symbol("events.maxEventTargetListeners"),oq=Symbol("events.maxEventTargetListenersWarned"),g7=z5("nodejs.rejection"),_7=z5("nodejs.rejection"),x7=Array.prototype.slice,k0=i2.prototype={};k0._events=void 0;k0._eventsCount=0;k0._maxListeners=void 0;k0.setMaxListeners=function($){return O5($,"setMaxListeners",0),this._maxListeners=$,this};k0.constructor=i2;k0.getMaxListeners=function(){return this?._maxListeners??F1};k0.emit=sq;k0.addListener=function($,Q){P6(Q);var J=this._events;if(!J)J=this._events={__proto__:null},this._eventsCount=0;else if(J.newListener)this.emit("newListener",$,Q.listener??Q);var q=J[$];if(!q)J[$]=[Q],this._eventsCount++;else{q.push(Q);var X=this._maxListeners??F1;if(X>0&&q.length>X&&!q.warned)h7(this,$,q)}return this};k0.on=k0.addListener;k0.prependListener=function($,Q){P6(Q);var J=this._events;if(!J)J=this._events={__proto__:null},this._eventsCount=0;else if(J.newListener)this.emit("newListener",$,Q.listener??Q);var q=J[$];if(!q)J[$]=[Q],this._eventsCount++;else{q.unshift(Q);var X=this._maxListeners??F1;if(X>0&&q.length>X&&!q.warned)h7(this,$,q)}return this};k0.once=function($,Q){P6(Q);let J=m7.bind(this,$,Q);return J.listener=Q,this.addListener($,J),this};k0.prependOnceListener=function($,Q){P6(Q);let J=m7.bind(this,$,Q);return J.listener=Q,this.prependListener($,J),this};k0.removeListener=function($,Q){P6(Q);var{_events:J}=this;if(!J)return this;var q=J[$];if(!q)return this;var X=q.length;let Y=-1;for(let G=X-1;G>=0;G--)if(q[G]===Q||q[G].listener===Q){Y=G;break}if(Y<0)return this;if(Y===0)q.shift();else q.splice(Y,1);if(q.length===0)delete J[$],this._eventsCount--;return this};k0.off=k0.removeListener;k0.removeAllListeners=function($){var{_events:Q}=this;if($&&Q){if(Q[$])delete Q[$],this._eventsCount--}else this._events={__proto__:null};return this};k0.listeners=function($){var{_events:Q}=this;if(!Q)return[];var J=Q[$];if(!J)return[];return J.map((q)=>q.listener??q)};k0.rawListeners=function($){var{_events:Q}=this;if(!Q)return[];var J=Q[$];if(!J)return[];return J.slice()};k0.listenerCount=function($){var{_events:Q}=this;if(!Q)return 0;return Q[$]?.length??0};k0.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]};k0[w1]=!1;L5=class L5 extends Error{constructor($="The operation was aborted",Q=void 0){if(Q!==void 0&&typeof Q!=="object")throw _1("options","Object",Q);super($,Q);this.code="ABORT_ERR",this.name="AbortError"}};Object.defineProperties(i2,{captureRejections:{get(){return k0[w1]},set($){$X($,"EventEmitter.captureRejections"),k0[w1]=$},enumerable:!0},defaultMaxListeners:{enumerable:!0,get:()=>{return F1},set:($)=>{O5($,"defaultMaxListeners",0),F1=$}},kMaxEventTargetListeners:{value:nq,enumerable:!1,configurable:!1,writable:!1},kMaxEventTargetListenersWarned:{value:oq,enumerable:!1,configurable:!1,writable:!1}});Object.assign(i2,{once:u7,getEventListeners:c7,getMaxListeners:i7,setMaxListeners:p7,EventEmitter:i2,usingDomains:!1,captureRejectionSymbol:_7,errorMonitor:y7,addAbortListener:n7,init:i2,listenerCount:l7});QX=i2});var H8=j0((rV,Q$)=>{var S0=($,Q)=>()=>(Q||$((Q={exports:{}}).exports,Q),Q.exports),Z0=S0(($,Q)=>{class J extends Error{constructor(q){if(!Array.isArray(q))throw TypeError(`Expected input to be an Array, got ${typeof q}`);let X="";for(let Y=0;Y<q.length;Y++)X+=` ${q[Y].stack}
|
|
2
|
-
`;super(X);this.name="AggregateError",this.errors=q}}Q.exports={AggregateError:J,ArrayIsArray(q){return Array.isArray(q)},ArrayPrototypeIncludes(q,X){return q.includes(X)},ArrayPrototypeIndexOf(q,X){return q.indexOf(X)},ArrayPrototypeJoin(q,X){return q.join(X)},ArrayPrototypeMap(q,X){return q.map(X)},ArrayPrototypePop(q,X){return q.pop(X)},ArrayPrototypePush(q,X){return q.push(X)},ArrayPrototypeSlice(q,X,Y){return q.slice(X,Y)},Error,FunctionPrototypeCall(q,X,...Y){return q.call(X,...Y)},FunctionPrototypeSymbolHasInstance(q,X){return Function.prototype[Symbol.hasInstance].call(q,X)},MathFloor:Math.floor,Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties(q,X){return Object.defineProperties(q,X)},ObjectDefineProperty(q,X,Y){return Object.defineProperty(q,X,Y)},ObjectGetOwnPropertyDescriptor(q,X){return Object.getOwnPropertyDescriptor(q,X)},ObjectKeys(q){return Object.keys(q)},ObjectSetPrototypeOf(q,X){return Object.setPrototypeOf(q,X)},Promise,PromisePrototypeCatch(q,X){return q.catch(X)},PromisePrototypeThen(q,X,Y){return q.then(X,Y)},PromiseReject(q){return Promise.reject(q)},PromiseResolve(q){return Promise.resolve(q)},ReflectApply:Reflect.apply,RegExpPrototypeTest(q,X){return q.test(X)},SafeSet:Set,String,StringPrototypeSlice(q,X,Y){return q.slice(X,Y)},StringPrototypeToLowerCase(q){return q.toLowerCase()},StringPrototypeToUpperCase(q){return q.toUpperCase()},StringPrototypeTrim(q){return q.trim()},Symbol,SymbolFor:Symbol.for,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,SymbolDispose:Symbol.dispose||Symbol("Symbol.dispose"),SymbolAsyncDispose:Symbol.asyncDispose||Symbol("Symbol.asyncDispose"),TypedArrayPrototypeSet(q,X,Y){return q.set(X,Y)},Boolean,Uint8Array}}),o7=S0(($,Q)=>{Q.exports={format(J,...q){return J.replace(/%([sdifj])/g,function(...[X,Y]){let G=q.shift();if(Y==="f")return G.toFixed(6);else if(Y==="j")return JSON.stringify(G);else if(Y==="s"&&typeof G==="object")return`${G.constructor!==Object?G.constructor.name:""} {}`.trim();else return G.toString()})},inspect(J){switch(typeof J){case"string":if(J.includes("'")){if(!J.includes('"'))return`"${J}"`;else if(!J.includes("`")&&!J.includes("${"))return`\`${J}\``}return`'${J}'`;case"number":if(isNaN(J))return"NaN";else if(Object.is(J,-0))return String(J);return J;case"bigint":return`${String(J)}n`;case"boolean":case"undefined":return String(J);case"object":return"{}"}}}}),d0=S0(($,Q)=>{var{format:J,inspect:q}=o7(),{AggregateError:X}=Z0(),Y=globalThis.AggregateError||X,G=Symbol("kIsNodeError"),B=["string","function","number","object","Function","Object","boolean","bigint","symbol"],W=/^([A-Z][a-z0-9]*)+$/,U={};function V(P,K){if(!P)throw new U.ERR_INTERNAL_ASSERTION(K)}function L(P){let K="",F=P.length,z=P[0]==="-"?1:0;for(;F>=z+4;F-=3)K=`_${P.slice(F-3,F)}${K}`;return`${P.slice(0,F)}${K}`}function w(P,K,F){if(typeof K==="function")return V(K.length<=F.length,`Code: ${P}; The provided arguments length (${F.length}) does not match the required ones (${K.length}).`),K(...F);let z=(K.match(/%[dfijoOs]/g)||[]).length;if(V(z===F.length,`Code: ${P}; The provided arguments length (${F.length}) does not match the required ones (${z}).`),F.length===0)return K;return J(K,...F)}function M(P,K,F){if(!F)F=Error;class z extends F{constructor(...D){super(w(P,K,D))}toString(){return`${this.name} [${P}]: ${this.message}`}}Object.defineProperties(z.prototype,{name:{value:F.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${P}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),z.prototype.code=P,z.prototype[G]=!0,U[P]=z}function y(P){let K="__node_internal_"+P.name;return Object.defineProperty(P,"name",{value:K}),P}function x(P,K){if(P&&K&&P!==K){if(Array.isArray(K.errors))return K.errors.push(P),K;let F=new Y([K,P],K.message);return F.code=K.code,F}return P||K}class A extends Error{constructor(P="The operation was aborted",K=void 0){if(K!==void 0&&typeof K!=="object")throw new U.ERR_INVALID_ARG_TYPE("options","Object",K);super(P,K);this.code="ABORT_ERR",this.name="AbortError"}}M("ERR_ASSERTION","%s",Error),M("ERR_INVALID_ARG_TYPE",(P,K,F)=>{if(V(typeof P==="string","'name' must be a string"),!Array.isArray(K))K=[K];let z="The ";if(P.endsWith(" argument"))z+=`${P} `;else z+=`"${P}" ${P.includes(".")?"property":"argument"} `;z+="must be ";let D=[],_=[],T=[];for(let S of K)if(V(typeof S==="string","All expected entries have to be of type string"),B.includes(S))D.push(S.toLowerCase());else if(W.test(S))_.push(S);else V(S!=="object",'The value "object" should be written as "Object"'),T.push(S);if(_.length>0){let S=D.indexOf("object");if(S!==-1)D.splice(D,S,1),_.push("Object")}if(D.length>0){switch(D.length){case 1:z+=`of type ${D[0]}`;break;case 2:z+=`one of type ${D[0]} or ${D[1]}`;break;default:{let S=D.pop();z+=`one of type ${D.join(", ")}, or ${S}`}}if(_.length>0||T.length>0)z+=" or "}if(_.length>0){switch(_.length){case 1:z+=`an instance of ${_[0]}`;break;case 2:z+=`an instance of ${_[0]} or ${_[1]}`;break;default:{let S=_.pop();z+=`an instance of ${_.join(", ")}, or ${S}`}}if(T.length>0)z+=" or "}switch(T.length){case 0:break;case 1:if(T[0].toLowerCase()!==T[0])z+="an ";z+=`${T[0]}`;break;case 2:z+=`one of ${T[0]} or ${T[1]}`;break;default:{let S=T.pop();z+=`one of ${T.join(", ")}, or ${S}`}}if(F==null)z+=`. Received ${F}`;else if(typeof F==="function"&&F.name)z+=`. Received function ${F.name}`;else if(typeof F==="object"){var l;if((l=F.constructor)!==null&&l!==void 0&&l.name)z+=`. Received an instance of ${F.constructor.name}`;else{let S=q(F,{depth:-1});z+=`. Received ${S}`}}else{let S=q(F,{colors:!1});if(S.length>25)S=`${S.slice(0,25)}...`;z+=`. Received type ${typeof F} (${S})`}return z},TypeError),M("ERR_INVALID_ARG_VALUE",(P,K,F="is invalid")=>{let z=q(K);if(z.length>128)z=z.slice(0,128)+"...";return`The ${P.includes(".")?"property":"argument"} '${P}' ${F}. Received ${z}`},TypeError),M("ERR_INVALID_RETURN_VALUE",(P,K,F)=>{var z;let D=F!==null&&F!==void 0&&(z=F.constructor)!==null&&z!==void 0&&z.name?`instance of ${F.constructor.name}`:`type ${typeof F}`;return`Expected ${P} to be returned from the "${K}" function but got ${D}.`},TypeError),M("ERR_MISSING_ARGS",(...P)=>{V(P.length>0,"At least one arg needs to be specified");let K,F=P.length;switch(P=(Array.isArray(P)?P:[P]).map((z)=>`"${z}"`).join(" or "),F){case 1:K+=`The ${P[0]} argument`;break;case 2:K+=`The ${P[0]} and ${P[1]} arguments`;break;default:{let z=P.pop();K+=`The ${P.join(", ")}, and ${z} arguments`}break}return`${K} must be specified`},TypeError),M("ERR_OUT_OF_RANGE",(P,K,F)=>{V(K,'Missing "range" argument');let z;if(Number.isInteger(F)&&Math.abs(F)>4294967296)z=L(String(F));else if(typeof F==="bigint"){z=String(F);let D=BigInt(2)**BigInt(32);if(F>D||F<-D)z=L(z);z+="n"}else z=q(F);return`The value of "${P}" is out of range. It must be ${K}. Received ${z}`},RangeError),M("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),M("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),M("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),M("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),M("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),M("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),M("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),M("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),M("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),M("ERR_STREAM_WRITE_AFTER_END","write after end",Error),M("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),Q.exports={AbortError:A,aggregateTwoErrors:y(x),hideStackFrames:y,codes:U}}),JX=S0(($,Q)=>{Object.defineProperty($,"__esModule",{value:!0});var J=new WeakMap,q=new WeakMap;function X(E){let C=J.get(E);return console.assert(C!=null,"'this' is expected an Event object, but got",E),C}function Y(E){if(E.passiveListener!=null){if(typeof console<"u"&&typeof console.error==="function")console.error("Unable to preventDefault inside passive event listener invocation.",E.passiveListener);return}if(!E.event.cancelable)return;if(E.canceled=!0,typeof E.event.preventDefault==="function")E.event.preventDefault()}function G(E,C){J.set(this,{eventTarget:E,event:C,eventPhase:2,currentTarget:E,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:C.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});let N=Object.keys(C);for(let Z=0;Z<N.length;++Z){let f=N[Z];if(!(f in this))Object.defineProperty(this,f,B(f))}}if(G.prototype={get type(){return X(this).event.type},get target(){return X(this).eventTarget},get currentTarget(){return X(this).currentTarget},composedPath(){let E=X(this).currentTarget;if(E==null)return[];return[E]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return X(this).eventPhase},stopPropagation(){let E=X(this);if(E.stopped=!0,typeof E.event.stopPropagation==="function")E.event.stopPropagation()},stopImmediatePropagation(){let E=X(this);if(E.stopped=!0,E.immediateStopped=!0,typeof E.event.stopImmediatePropagation==="function")E.event.stopImmediatePropagation()},get bubbles(){return Boolean(X(this).event.bubbles)},get cancelable(){return Boolean(X(this).event.cancelable)},preventDefault(){Y(X(this))},get defaultPrevented(){return X(this).canceled},get composed(){return Boolean(X(this).event.composed)},get timeStamp(){return X(this).timeStamp},get srcElement(){return X(this).eventTarget},get cancelBubble(){return X(this).stopped},set cancelBubble(E){if(!E)return;let C=X(this);if(C.stopped=!0,typeof C.event.cancelBubble==="boolean")C.event.cancelBubble=!0},get returnValue(){return!X(this).canceled},set returnValue(E){if(!E)Y(X(this))},initEvent(){}},Object.defineProperty(G.prototype,"constructor",{value:G,configurable:!0,writable:!0}),typeof window<"u"&&typeof window.Event<"u")Object.setPrototypeOf(G.prototype,window.Event.prototype),q.set(window.Event.prototype,G);function B(E){return{get(){return X(this).event[E]},set(C){X(this).event[E]=C},configurable:!0,enumerable:!0}}function W(E){return{value(){let C=X(this).event;return C[E].apply(C,arguments)},configurable:!0,enumerable:!0}}function U(E,C){let N=Object.keys(C);if(N.length===0)return E;function Z(f,k){E.call(this,f,k)}Z.prototype=Object.create(E.prototype,{constructor:{value:Z,configurable:!0,writable:!0}});for(let f=0;f<N.length;++f){let k=N[f];if(!(k in E.prototype)){let s=typeof Object.getOwnPropertyDescriptor(C,k).value==="function";Object.defineProperty(Z.prototype,k,s?W(k):B(k))}}return Z}function V(E){if(E==null||E===Object.prototype)return G;let C=q.get(E);if(C==null)C=U(V(Object.getPrototypeOf(E)),E),q.set(E,C);return C}function L(E,C){return new(V(Object.getPrototypeOf(C)))(E,C)}function w(E){return X(E).immediateStopped}function M(E,C){X(E).eventPhase=C}function y(E,C){X(E).currentTarget=C}function x(E,C){X(E).passiveListener=C}var A=new WeakMap,P=1,K=2,F=3;function z(E){return E!==null&&typeof E==="object"}function D(E){let C=A.get(E);if(C==null)throw TypeError("'this' is expected an EventTarget object, but got another value.");return C}function _(E){return{get(){let C=D(this).get(E);while(C!=null){if(C.listenerType===F)return C.listener;C=C.next}return null},set(C){if(typeof C!=="function"&&!z(C))C=null;let N=D(this),Z=null,f=N.get(E);while(f!=null){if(f.listenerType===F)if(Z!==null)Z.next=f.next;else if(f.next!==null)N.set(E,f.next);else N.delete(E);else Z=f;f=f.next}if(C!==null){let k={listener:C,listenerType:F,passive:!1,once:!1,next:null};if(Z===null)N.set(E,k);else Z.next=k}},configurable:!0,enumerable:!0}}function T(E,C){Object.defineProperty(E,`on${C}`,_(C))}function l(E){function C(){S.call(this)}C.prototype=Object.create(S.prototype,{constructor:{value:C,configurable:!0,writable:!0}});for(let N=0;N<E.length;++N)T(C.prototype,E[N]);return C}function S(){if(this instanceof S){A.set(this,new Map);return}if(arguments.length===1&&Array.isArray(arguments[0]))return l(arguments[0]);if(arguments.length>0){let E=Array(arguments.length);for(let C=0;C<arguments.length;++C)E[C]=arguments[C];return l(E)}throw TypeError("Cannot call a class as a function")}if(S.prototype={addEventListener(E,C,N){if(C==null)return;if(typeof C!=="function"&&!z(C))throw TypeError("'listener' should be a function or an object.");let Z=D(this),f=z(N),k=(f?Boolean(N.capture):Boolean(N))?P:K,s={listener:C,listenerType:k,passive:f&&Boolean(N.passive),once:f&&Boolean(N.once),next:null},J0=Z.get(E);if(J0===void 0){Z.set(E,s);return}let B0=null;while(J0!=null){if(J0.listener===C&&J0.listenerType===k)return;B0=J0,J0=J0.next}B0.next=s},removeEventListener(E,C,N){if(C==null)return;let Z=D(this),f=(z(N)?Boolean(N.capture):Boolean(N))?P:K,k=null,s=Z.get(E);while(s!=null){if(s.listener===C&&s.listenerType===f){if(k!==null)k.next=s.next;else if(s.next!==null)Z.set(E,s.next);else Z.delete(E);return}k=s,s=s.next}},dispatchEvent(E){if(E==null||typeof E.type!=="string")throw TypeError('"event.type" should be a string.');let C=D(this),N=E.type,Z=C.get(N);if(Z==null)return!0;let f=L(this,E),k=null;while(Z!=null){if(Z.once)if(k!==null)k.next=Z.next;else if(Z.next!==null)C.set(N,Z.next);else C.delete(N);else k=Z;if(x(f,Z.passive?Z.listener:null),typeof Z.listener==="function")try{Z.listener.call(this,f)}catch(s){if(typeof console<"u"&&typeof console.error==="function")console.error(s)}else if(Z.listenerType!==F&&typeof Z.listener.handleEvent==="function")Z.listener.handleEvent(f);if(w(f))break;Z=Z.next}return x(f,null),M(f,0),y(f,null),!f.defaultPrevented}},Object.defineProperty(S.prototype,"constructor",{value:S,configurable:!0,writable:!0}),typeof window<"u"&&typeof window.EventTarget<"u")Object.setPrototypeOf(S.prototype,window.EventTarget.prototype);$.defineEventAttribute=T,$.EventTarget=S,$.default=S,Q.exports=S,Q.exports.EventTarget=Q.exports.default=S,Q.exports.defineEventAttribute=T}),I6=S0(($,Q)=>{Object.defineProperty($,"__esModule",{value:!0});var J=JX();class q extends J.EventTarget{constructor(){super();throw TypeError("AbortSignal cannot be constructed directly")}get aborted(){let V=G.get(this);if(typeof V!=="boolean")throw TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this===null?"null":typeof this}`);return V}}J.defineEventAttribute(q.prototype,"abort");function X(){let V=Object.create(q.prototype);return J.EventTarget.call(V),G.set(V,!1),V}function Y(V){if(G.get(V)!==!1)return;G.set(V,!0),V.dispatchEvent({type:"abort"})}var G=new WeakMap;if(Object.defineProperties(q.prototype,{aborted:{enumerable:!0}}),typeof Symbol==="function"&&typeof Symbol.toStringTag==="symbol")Object.defineProperty(q.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortSignal"});class B{constructor(){W.set(this,X())}get signal(){return U(this)}abort(){Y(U(this))}}var W=new WeakMap;function U(V){let L=W.get(V);if(L==null)throw TypeError(`Expected 'this' to be an 'AbortController' object, but got ${V===null?"null":typeof V}`);return L}if(Object.defineProperties(B.prototype,{signal:{enumerable:!0},abort:{enumerable:!0}}),typeof Symbol==="function"&&typeof Symbol.toStringTag==="symbol")Object.defineProperty(B.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortController"});$.AbortController=B,$.AbortSignal=q,$.default=B,Q.exports=B,Q.exports.AbortController=Q.exports.default=B,Q.exports.AbortSignal=q}),r0=S0(($,Q)=>{var J=(x2(),q2(g2)),{format:q,inspect:X}=o7(),{codes:{ERR_INVALID_ARG_TYPE:Y}}=d0(),{kResistStopPropagation:G,AggregateError:B,SymbolDispose:W}=Z0(),U=globalThis.AbortSignal||I6().AbortSignal,V=globalThis.AbortController||I6().AbortController,L=Object.getPrototypeOf(async function(){}).constructor,w=globalThis.Blob||J.Blob,M=typeof w<"u"?function(A){return A instanceof w}:function(A){return!1},y=(A,P)=>{if(A!==void 0&&(A===null||typeof A!=="object"||!("aborted"in A)))throw new Y(P,"AbortSignal",A)},x=(A,P)=>{if(typeof A!=="function")throw new Y(P,"Function",A)};Q.exports={AggregateError:B,kEmptyObject:Object.freeze({}),once(A){let P=!1;return function(...K){if(P)return;P=!0,A.apply(this,K)}},createDeferredPromise:function(){let A,P;return{promise:new Promise((K,F)=>{A=K,P=F}),resolve:A,reject:P}},promisify(A){return new Promise((P,K)=>{A((F,...z)=>{if(F)return K(F);return P(...z)})})},debuglog(){return function(){}},format:q,inspect:X,types:{isAsyncFunction(A){return A instanceof L},isArrayBufferView(A){return ArrayBuffer.isView(A)}},isBlob:M,deprecate(A,P){return A},addAbortListener:(R6(),q2(C6)).addAbortListener||function(A,P){if(A===void 0)throw new Y("signal","AbortSignal",A);y(A,"signal"),x(P,"listener");let K;if(A.aborted)queueMicrotask(()=>P());else A.addEventListener("abort",P,{__proto__:null,once:!0,[G]:!0}),K=()=>{A.removeEventListener("abort",P)};return{__proto__:null,[W](){var F;(F=K)===null||F===void 0||F()}}},AbortSignalAny:U.any||function(A){if(A.length===1)return A[0];let P=new V,K=()=>P.abort();return A.forEach((F)=>{y(F,"signals"),F.addEventListener("abort",K,{once:!0})}),P.signal.addEventListener("abort",()=>{A.forEach((F)=>F.removeEventListener("abort",K))},{once:!0}),P.signal}},Q.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}),S6=S0(($,Q)=>{var{ArrayIsArray:J,ArrayPrototypeIncludes:q,ArrayPrototypeJoin:X,ArrayPrototypeMap:Y,NumberIsInteger:G,NumberIsNaN:B,NumberMAX_SAFE_INTEGER:W,NumberMIN_SAFE_INTEGER:U,NumberParseInt:V,ObjectPrototypeHasOwnProperty:L,RegExpPrototypeExec:w,String:M,StringPrototypeToUpperCase:y,StringPrototypeTrim:x}=Z0(),{hideStackFrames:A,codes:{ERR_SOCKET_BAD_PORT:P,ERR_INVALID_ARG_TYPE:K,ERR_INVALID_ARG_VALUE:F,ERR_OUT_OF_RANGE:z,ERR_UNKNOWN_SIGNAL:D}}=d0(),{normalizeEncoding:_}=r0(),{isAsyncFunction:T,isArrayBufferView:l}=r0().types,S={};function E(I){return I===(I|0)}function C(I){return I===I>>>0}var N=/^[0-7]+$/,Z="must be a 32-bit unsigned integer or an octal string";function f(I,i,q0){if(typeof I>"u")I=q0;if(typeof I==="string"){if(w(N,I)===null)throw new F(i,I,Z);I=V(I,8)}return J0(I,i),I}var k=A((I,i,q0=U,n=W)=>{if(typeof I!=="number")throw new K(i,"number",I);if(!G(I))throw new z(i,"an integer",I);if(I<q0||I>n)throw new z(i,`>= ${q0} && <= ${n}`,I)}),s=A((I,i,q0=-2147483648,n=2147483647)=>{if(typeof I!=="number")throw new K(i,"number",I);if(!G(I))throw new z(i,"an integer",I);if(I<q0||I>n)throw new z(i,`>= ${q0} && <= ${n}`,I)}),J0=A((I,i,q0=!1)=>{if(typeof I!=="number")throw new K(i,"number",I);if(!G(I))throw new z(i,"an integer",I);let n=q0?1:0,H0=4294967295;if(I<n||I>H0)throw new z(i,`>= ${n} && <= ${H0}`,I)});function B0(I,i){if(typeof I!=="string")throw new K(i,"string",I)}function O0(I,i,q0=void 0,n){if(typeof I!=="number")throw new K(i,"number",I);if(q0!=null&&I<q0||n!=null&&I>n||(q0!=null||n!=null)&&B(I))throw new z(i,`${q0!=null?`>= ${q0}`:""}${q0!=null&&n!=null?" && ":""}${n!=null?`<= ${n}`:""}`,I)}var u=A((I,i,q0)=>{if(!q(q0,I)){let n="must be one of: "+X(Y(q0,(H0)=>typeof H0==="string"?`'${H0}'`:M(H0)),", ");throw new F(i,I,n)}});function K0(I,i){if(typeof I!=="boolean")throw new K(i,"boolean",I)}function O(I,i,q0){return I==null||!L(I,i)?q0:I[i]}var d=A((I,i,q0=null)=>{let n=O(q0,"allowArray",!1),H0=O(q0,"allowFunction",!1);if(!O(q0,"nullable",!1)&&I===null||!n&&J(I)||typeof I!=="object"&&(!H0||typeof I!=="function"))throw new K(i,"Object",I)}),Y0=A((I,i)=>{if(I!=null&&typeof I!=="object"&&typeof I!=="function")throw new K(i,"a dictionary",I)}),m=A((I,i,q0=0)=>{if(!J(I))throw new K(i,"Array",I);if(I.length<q0){let n=`must be longer than ${q0}`;throw new F(i,I,n)}});function W0(I,i){m(I,i);for(let q0=0;q0<I.length;q0++)B0(I[q0],`${i}[${q0}]`)}function M0(I,i){m(I,i);for(let q0=0;q0<I.length;q0++)K0(I[q0],`${i}[${q0}]`)}function C0(I,i){m(I,i);for(let q0=0;q0<I.length;q0++){let n=I[q0],H0=`${i}[${q0}]`;if(n==null)throw new K(H0,"AbortSignal",n);L0(n,H0)}}function N0(I,i="signal"){if(B0(I,i),S[I]===void 0){if(S[y(I)]!==void 0)throw new D(I+" (signals must use all capital letters)");throw new D(I)}}var c=A((I,i="buffer")=>{if(!l(I))throw new K(i,["Buffer","TypedArray","DataView"],I)});function p(I,i){let q0=_(i),n=I.length;if(q0==="hex"&&n%2!==0)throw new F("encoding",i,`is invalid for data of length ${n}`)}function t(I,i="Port",q0=!0){if(typeof I!=="number"&&typeof I!=="string"||typeof I==="string"&&x(I).length===0||+I!==+I>>>0||I>65535||I===0&&!q0)throw new P(i,I,q0);return I|0}var L0=A((I,i)=>{if(I!==void 0&&(I===null||typeof I!=="object"||!("aborted"in I)))throw new K(i,"AbortSignal",I)}),z0=A((I,i)=>{if(typeof I!=="function")throw new K(i,"Function",I)}),R=A((I,i)=>{if(typeof I!=="function"||T(I))throw new K(i,"Function",I)}),v=A((I,i)=>{if(I!==void 0)throw new K(i,"undefined",I)});function h(I,i,q0){if(!q(q0,I))throw new K(i,`('${X(q0,"|")}')`,I)}var a=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function Q0(I,i){if(typeof I>"u"||!w(a,I))throw new F(i,I,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}function e(I){if(typeof I==="string")return Q0(I,"hints"),I;else if(J(I)){let i=I.length,q0="";if(i===0)return q0;for(let n=0;n<i;n++){let H0=I[n];if(Q0(H0,"hints"),q0+=H0,n!==i-1)q0+=", "}return q0}throw new F("hints",I,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}Q.exports={isInt32:E,isUint32:C,parseFileMode:f,validateArray:m,validateStringArray:W0,validateBooleanArray:M0,validateAbortSignalArray:C0,validateBoolean:K0,validateBuffer:c,validateDictionary:Y0,validateEncoding:p,validateFunction:z0,validateInt32:s,validateInteger:k,validateNumber:O0,validateObject:d,validateOneOf:u,validatePlainFunction:R,validatePort:t,validateSignalName:N0,validateString:B0,validateUint32:J0,validateUndefined:v,validateUnion:h,validateAbortSignal:L0,validateLinkHeaderValue:e}}),L1=S0(($,Q)=>{Q.exports=globalThis.process}),y2=S0(($,Q)=>{var{SymbolAsyncIterator:J,SymbolIterator:q,SymbolFor:X}=Z0(),Y=X("nodejs.stream.destroyed"),G=X("nodejs.stream.errored"),B=X("nodejs.stream.readable"),W=X("nodejs.stream.writable"),U=X("nodejs.stream.disturbed"),V=X("nodejs.webstream.isClosedPromise"),L=X("nodejs.webstream.controllerErrorFunction");function w(O,d=!1){var Y0;return!!(O&&typeof O.pipe==="function"&&typeof O.on==="function"&&(!d||typeof O.pause==="function"&&typeof O.resume==="function")&&(!O._writableState||((Y0=O._readableState)===null||Y0===void 0?void 0:Y0.readable)!==!1)&&(!O._writableState||O._readableState))}function M(O){var d;return!!(O&&typeof O.write==="function"&&typeof O.on==="function"&&(!O._readableState||((d=O._writableState)===null||d===void 0?void 0:d.writable)!==!1))}function y(O){return!!(O&&typeof O.pipe==="function"&&O._readableState&&typeof O.on==="function"&&typeof O.write==="function")}function x(O){return O&&(O._readableState||O._writableState||typeof O.write==="function"&&typeof O.on==="function"||typeof O.pipe==="function"&&typeof O.on==="function")}function A(O){return!!(O&&!x(O)&&typeof O.pipeThrough==="function"&&typeof O.getReader==="function"&&typeof O.cancel==="function")}function P(O){return!!(O&&!x(O)&&typeof O.getWriter==="function"&&typeof O.abort==="function")}function K(O){return!!(O&&!x(O)&&typeof O.readable==="object"&&typeof O.writable==="object")}function F(O){return A(O)||P(O)||K(O)}function z(O,d){if(O==null)return!1;if(d===!0)return typeof O[J]==="function";if(d===!1)return typeof O[q]==="function";return typeof O[J]==="function"||typeof O[q]==="function"}function D(O){if(!x(O))return null;let{_writableState:d,_readableState:Y0}=O,m=d||Y0;return!!(O.destroyed||O[Y]||m!==null&&m!==void 0&&m.destroyed)}function _(O){if(!M(O))return null;if(O.writableEnded===!0)return!0;let d=O._writableState;if(d!==null&&d!==void 0&&d.errored)return!1;if(typeof(d===null||d===void 0?void 0:d.ended)!=="boolean")return null;return d.ended}function T(O,d){if(!M(O))return null;if(O.writableFinished===!0)return!0;let Y0=O._writableState;if(Y0!==null&&Y0!==void 0&&Y0.errored)return!1;if(typeof(Y0===null||Y0===void 0?void 0:Y0.finished)!=="boolean")return null;return!!(Y0.finished||d===!1&&Y0.ended===!0&&Y0.length===0)}function l(O){if(!w(O))return null;if(O.readableEnded===!0)return!0;let d=O._readableState;if(!d||d.errored)return!1;if(typeof(d===null||d===void 0?void 0:d.ended)!=="boolean")return null;return d.ended}function S(O,d){if(!w(O))return null;let Y0=O._readableState;if(Y0!==null&&Y0!==void 0&&Y0.errored)return!1;if(typeof(Y0===null||Y0===void 0?void 0:Y0.endEmitted)!=="boolean")return null;return!!(Y0.endEmitted||d===!1&&Y0.ended===!0&&Y0.length===0)}function E(O){if(O&&O[B]!=null)return O[B];if(typeof(O===null||O===void 0?void 0:O.readable)!=="boolean")return null;if(D(O))return!1;return w(O)&&O.readable&&!S(O)}function C(O){if(O&&O[W]!=null)return O[W];if(typeof(O===null||O===void 0?void 0:O.writable)!=="boolean")return null;if(D(O))return!1;return M(O)&&O.writable&&!_(O)}function N(O,d){if(!x(O))return null;if(D(O))return!0;if((d===null||d===void 0?void 0:d.readable)!==!1&&E(O))return!1;if((d===null||d===void 0?void 0:d.writable)!==!1&&C(O))return!1;return!0}function Z(O){var d,Y0;if(!x(O))return null;if(O.writableErrored)return O.writableErrored;return(d=(Y0=O._writableState)===null||Y0===void 0?void 0:Y0.errored)!==null&&d!==void 0?d:null}function f(O){var d,Y0;if(!x(O))return null;if(O.readableErrored)return O.readableErrored;return(d=(Y0=O._readableState)===null||Y0===void 0?void 0:Y0.errored)!==null&&d!==void 0?d:null}function k(O){if(!x(O))return null;if(typeof O.closed==="boolean")return O.closed;let{_writableState:d,_readableState:Y0}=O;if(typeof(d===null||d===void 0?void 0:d.closed)==="boolean"||typeof(Y0===null||Y0===void 0?void 0:Y0.closed)==="boolean")return(d===null||d===void 0?void 0:d.closed)||(Y0===null||Y0===void 0?void 0:Y0.closed);if(typeof O._closed==="boolean"&&s(O))return O._closed;return null}function s(O){return typeof O._closed==="boolean"&&typeof O._defaultKeepAlive==="boolean"&&typeof O._removedConnection==="boolean"&&typeof O._removedContLen==="boolean"}function J0(O){return typeof O._sent100==="boolean"&&s(O)}function B0(O){var d;return typeof O._consuming==="boolean"&&typeof O._dumped==="boolean"&&((d=O.req)===null||d===void 0?void 0:d.upgradeOrConnect)===void 0}function O0(O){if(!x(O))return null;let{_writableState:d,_readableState:Y0}=O,m=d||Y0;return!m&&J0(O)||!!(m&&m.autoDestroy&&m.emitClose&&m.closed===!1)}function u(O){var d;return!!(O&&((d=O[U])!==null&&d!==void 0?d:O.readableDidRead||O.readableAborted))}function K0(O){var d,Y0,m,W0,M0,C0,N0,c,p,t;return!!(O&&((d=(Y0=(m=(W0=(M0=(C0=O[G])!==null&&C0!==void 0?C0:O.readableErrored)!==null&&M0!==void 0?M0:O.writableErrored)!==null&&W0!==void 0?W0:(N0=O._readableState)===null||N0===void 0?void 0:N0.errorEmitted)!==null&&m!==void 0?m:(c=O._writableState)===null||c===void 0?void 0:c.errorEmitted)!==null&&Y0!==void 0?Y0:(p=O._readableState)===null||p===void 0?void 0:p.errored)!==null&&d!==void 0?d:(t=O._writableState)===null||t===void 0?void 0:t.errored))}Q.exports={isDestroyed:D,kIsDestroyed:Y,isDisturbed:u,kIsDisturbed:U,isErrored:K0,kIsErrored:G,isReadable:E,kIsReadable:B,kIsClosedPromise:V,kControllerErrorFunction:L,kIsWritable:W,isClosed:k,isDuplexNodeStream:y,isFinished:N,isIterable:z,isReadableNodeStream:w,isReadableStream:A,isReadableEnded:l,isReadableFinished:S,isReadableErrored:f,isNodeStream:x,isWebStream:F,isWritable:C,isWritableNodeStream:M,isWritableStream:P,isWritableEnded:_,isWritableFinished:T,isWritableErrored:Z,isServerRequest:B0,isServerResponse:J0,willEmitClose:O0,isTransformStream:K}}),n2=S0(($,Q)=>{var J=L1(),{AbortError:q,codes:X}=d0(),{ERR_INVALID_ARG_TYPE:Y,ERR_STREAM_PREMATURE_CLOSE:G}=X,{kEmptyObject:B,once:W}=r0(),{validateAbortSignal:U,validateFunction:V,validateObject:L,validateBoolean:w}=S6(),{Promise:M,PromisePrototypeThen:y,SymbolDispose:x}=Z0(),{isClosed:A,isReadable:P,isReadableNodeStream:K,isReadableStream:F,isReadableFinished:z,isReadableErrored:D,isWritable:_,isWritableNodeStream:T,isWritableStream:l,isWritableFinished:S,isWritableErrored:E,isNodeStream:C,willEmitClose:N,kIsClosedPromise:Z}=y2(),f;function k(u){return u.setHeader&&typeof u.abort==="function"}var s=()=>{};function J0(u,K0,O){var d,Y0;if(arguments.length===2)O=K0,K0=B;else if(K0==null)K0=B;else L(K0,"options");if(V(O,"callback"),U(K0.signal,"options.signal"),O=W(O),F(u)||l(u))return B0(u,K0,O);if(!C(u))throw new Y("stream",["ReadableStream","WritableStream","Stream"],u);let m=(d=K0.readable)!==null&&d!==void 0?d:K(u),W0=(Y0=K0.writable)!==null&&Y0!==void 0?Y0:T(u),M0=u._writableState,C0=u._readableState,N0=()=>{if(!u.writable)t()},c=N(u)&&K(u)===m&&T(u)===W0,p=S(u,!1),t=()=>{if(p=!0,u.destroyed)c=!1;if(c&&(!u.readable||m))return;if(!m||L0)O.call(u)},L0=z(u,!1),z0=()=>{if(L0=!0,u.destroyed)c=!1;if(c&&(!u.writable||W0))return;if(!W0||p)O.call(u)},R=(I)=>{O.call(u,I)},v=A(u),h=()=>{v=!0;let I=E(u)||D(u);if(I&&typeof I!=="boolean")return O.call(u,I);if(m&&!L0&&K(u,!0)){if(!z(u,!1))return O.call(u,new G)}if(W0&&!p){if(!S(u,!1))return O.call(u,new G)}O.call(u)},a=()=>{v=!0;let I=E(u)||D(u);if(I&&typeof I!=="boolean")return O.call(u,I);O.call(u)},Q0=()=>{u.req.on("finish",t)};if(k(u)){if(u.on("complete",t),!c)u.on("abort",h);if(u.req)Q0();else u.on("request",Q0)}else if(W0&&!M0)u.on("end",N0),u.on("close",N0);if(!c&&typeof u.aborted==="boolean")u.on("aborted",h);if(u.on("end",z0),u.on("finish",t),K0.error!==!1)u.on("error",R);if(u.on("close",h),v)J.nextTick(h);else if(M0!==null&&M0!==void 0&&M0.errorEmitted||C0!==null&&C0!==void 0&&C0.errorEmitted){if(!c)J.nextTick(a)}else if(!m&&(!c||P(u))&&(p||_(u)===!1))J.nextTick(a);else if(!W0&&(!c||_(u))&&(L0||P(u)===!1))J.nextTick(a);else if(C0&&u.req&&u.aborted)J.nextTick(a);let e=()=>{if(O=s,u.removeListener("aborted",h),u.removeListener("complete",t),u.removeListener("abort",h),u.removeListener("request",Q0),u.req)u.req.removeListener("finish",t);u.removeListener("end",N0),u.removeListener("close",N0),u.removeListener("finish",t),u.removeListener("end",z0),u.removeListener("error",R),u.removeListener("close",h)};if(K0.signal&&!v){let I=()=>{let i=O;e(),i.call(u,new q(void 0,{cause:K0.signal.reason}))};if(K0.signal.aborted)J.nextTick(I);else{f=f||r0().addAbortListener;let i=f(K0.signal,I),q0=O;O=W((...n)=>{i[x](),q0.apply(u,n)})}}return e}function B0(u,K0,O){let d=!1,Y0=s;if(K0.signal)if(Y0=()=>{d=!0,O.call(u,new q(void 0,{cause:K0.signal.reason}))},K0.signal.aborted)J.nextTick(Y0);else{f=f||r0().addAbortListener;let W0=f(K0.signal,Y0),M0=O;O=W((...C0)=>{W0[x](),M0.apply(u,C0)})}let m=(...W0)=>{if(!d)J.nextTick(()=>O.apply(u,W0))};return y(u[Z].promise,m,m),s}function O0(u,K0){var O;let d=!1;if(K0===null)K0=B;if((O=K0)!==null&&O!==void 0&&O.cleanup)w(K0.cleanup,"cleanup"),d=K0.cleanup;return new M((Y0,m)=>{let W0=J0(u,K0,(M0)=>{if(d)W0();if(M0)m(M0);else Y0()})})}Q.exports=J0,Q.exports.finished=O0}),b1=S0(($,Q)=>{var J=L1(),{aggregateTwoErrors:q,codes:{ERR_MULTIPLE_CALLBACK:X},AbortError:Y}=d0(),{Symbol:G}=Z0(),{kIsDestroyed:B,isDestroyed:W,isFinished:U,isServerRequest:V}=y2(),L=G("kDestroy"),w=G("kConstruct");function M(N,Z,f){if(N){if(N.stack,Z&&!Z.errored)Z.errored=N;if(f&&!f.errored)f.errored=N}}function y(N,Z){let f=this._readableState,k=this._writableState,s=k||f;if(k!==null&&k!==void 0&&k.destroyed||f!==null&&f!==void 0&&f.destroyed){if(typeof Z==="function")Z();return this}if(M(N,k,f),k)k.destroyed=!0;if(f)f.destroyed=!0;if(!s.constructed)this.once(L,function(J0){x(this,q(J0,N),Z)});else x(this,N,Z);return this}function x(N,Z,f){let k=!1;function s(J0){if(k)return;k=!0;let{_readableState:B0,_writableState:O0}=N;if(M(J0,O0,B0),O0)O0.closed=!0;if(B0)B0.closed=!0;if(typeof f==="function")f(J0);if(J0)J.nextTick(A,N,J0);else J.nextTick(P,N)}try{N._destroy(Z||null,s)}catch(J0){s(J0)}}function A(N,Z){K(N,Z),P(N)}function P(N){let{_readableState:Z,_writableState:f}=N;if(f)f.closeEmitted=!0;if(Z)Z.closeEmitted=!0;if(f!==null&&f!==void 0&&f.emitClose||Z!==null&&Z!==void 0&&Z.emitClose)N.emit("close")}function K(N,Z){let{_readableState:f,_writableState:k}=N;if(k!==null&&k!==void 0&&k.errorEmitted||f!==null&&f!==void 0&&f.errorEmitted)return;if(k)k.errorEmitted=!0;if(f)f.errorEmitted=!0;N.emit("error",Z)}function F(){let N=this._readableState,Z=this._writableState;if(N)N.constructed=!0,N.closed=!1,N.closeEmitted=!1,N.destroyed=!1,N.errored=null,N.errorEmitted=!1,N.reading=!1,N.ended=N.readable===!1,N.endEmitted=N.readable===!1;if(Z)Z.constructed=!0,Z.destroyed=!1,Z.closed=!1,Z.closeEmitted=!1,Z.errored=null,Z.errorEmitted=!1,Z.finalCalled=!1,Z.prefinished=!1,Z.ended=Z.writable===!1,Z.ending=Z.writable===!1,Z.finished=Z.writable===!1}function z(N,Z,f){let{_readableState:k,_writableState:s}=N;if(s!==null&&s!==void 0&&s.destroyed||k!==null&&k!==void 0&&k.destroyed)return this;if(k!==null&&k!==void 0&&k.autoDestroy||s!==null&&s!==void 0&&s.autoDestroy)N.destroy(Z);else if(Z){if(Z.stack,s&&!s.errored)s.errored=Z;if(k&&!k.errored)k.errored=Z;if(f)J.nextTick(K,N,Z);else K(N,Z)}}function D(N,Z){if(typeof N._construct!=="function")return;let{_readableState:f,_writableState:k}=N;if(f)f.constructed=!1;if(k)k.constructed=!1;if(N.once(w,Z),N.listenerCount(w)>1)return;J.nextTick(_,N)}function _(N){let Z=!1;function f(k){if(Z){z(N,k!==null&&k!==void 0?k:new X);return}Z=!0;let{_readableState:s,_writableState:J0}=N,B0=J0||s;if(s)s.constructed=!0;if(J0)J0.constructed=!0;if(B0.destroyed)N.emit(L,k);else if(k)z(N,k,!0);else J.nextTick(T,N)}try{N._construct((k)=>{J.nextTick(f,k)})}catch(k){J.nextTick(f,k)}}function T(N){N.emit(w)}function l(N){return(N===null||N===void 0?void 0:N.setHeader)&&typeof N.abort==="function"}function S(N){N.emit("close")}function E(N,Z){N.emit("error",Z),J.nextTick(S,N)}function C(N,Z){if(!N||W(N))return;if(!Z&&!U(N))Z=new Y;if(V(N))N.socket=null,N.destroy(Z);else if(l(N))N.abort();else if(l(N.req))N.req.abort();else if(typeof N.destroy==="function")N.destroy(Z);else if(typeof N.close==="function")N.close();else if(Z)J.nextTick(E,N,Z);else J.nextTick(S,N);if(!N.destroyed)N[B]=!0}Q.exports={construct:D,destroyer:C,destroy:y,undestroy:F,errorOrDestroy:z}}),N5=S0(($,Q)=>{var{ArrayIsArray:J,ObjectSetPrototypeOf:q}=Z0(),{EventEmitter:X}=(R6(),q2(C6));function Y(B){X.call(this,B)}q(Y.prototype,X.prototype),q(Y,X),Y.prototype.pipe=function(B,W){let U=this;function V(P){if(B.writable&&B.write(P)===!1&&U.pause)U.pause()}U.on("data",V);function L(){if(U.readable&&U.resume)U.resume()}if(B.on("drain",L),!B._isStdio&&(!W||W.end!==!1))U.on("end",M),U.on("close",y);let w=!1;function M(){if(w)return;w=!0,B.end()}function y(){if(w)return;if(w=!0,typeof B.destroy==="function")B.destroy()}function x(P){if(A(),X.listenerCount(this,"error")===0)this.emit("error",P)}G(U,"error",x),G(B,"error",x);function A(){U.removeListener("data",V),B.removeListener("drain",L),U.removeListener("end",M),U.removeListener("close",y),U.removeListener("error",x),B.removeListener("error",x),U.removeListener("end",A),U.removeListener("close",A),B.removeListener("close",A)}return U.on("end",A),U.on("close",A),B.on("close",A),B.emit("pipe",U),B};function G(B,W,U){if(typeof B.prependListener==="function")return B.prependListener(W,U);if(!B._events||!B._events[W])B.on(W,U);else if(J(B._events[W]))B._events[W].unshift(U);else B._events[W]=[U,B._events[W]]}Q.exports={Stream:Y,prependListener:G}}),W8=S0(($,Q)=>{var{SymbolDispose:J}=Z0(),{AbortError:q,codes:X}=d0(),{isNodeStream:Y,isWebStream:G,kControllerErrorFunction:B}=y2(),W=n2(),{ERR_INVALID_ARG_TYPE:U}=X,V,L=(w,M)=>{if(typeof w!=="object"||!("aborted"in w))throw new U(M,"AbortSignal",w)};Q.exports.addAbortSignal=function(w,M){if(L(w,"signal"),!Y(M)&&!G(M))throw new U("stream",["ReadableStream","WritableStream","Stream"],M);return Q.exports.addAbortSignalNoValidate(w,M)},Q.exports.addAbortSignalNoValidate=function(w,M){if(typeof w!=="object"||!("aborted"in w))return M;let y=Y(M)?()=>{M.destroy(new q(void 0,{cause:w.reason}))}:()=>{M[B](new q(void 0,{cause:w.reason}))};if(w.aborted)y();else{V=V||r0().addAbortListener;let x=V(w,y);W(M,x[J])}return M}}),qX=S0(($,Q)=>{var{StringPrototypeSlice:J,SymbolIterator:q,TypedArrayPrototypeSet:X,Uint8Array:Y}=Z0(),{Buffer:G}=(x2(),q2(g2)),{inspect:B}=r0();Q.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(W){let U={data:W,next:null};if(this.length>0)this.tail.next=U;else this.head=U;this.tail=U,++this.length}unshift(W){let U={data:W,next:this.head};if(this.length===0)this.tail=U;this.head=U,++this.length}shift(){if(this.length===0)return;let W=this.head.data;if(this.length===1)this.head=this.tail=null;else this.head=this.head.next;return--this.length,W}clear(){this.head=this.tail=null,this.length=0}join(W){if(this.length===0)return"";let U=this.head,V=""+U.data;while((U=U.next)!==null)V+=W+U.data;return V}concat(W){if(this.length===0)return G.alloc(0);let U=G.allocUnsafe(W>>>0),V=this.head,L=0;while(V)X(U,V.data,L),L+=V.data.length,V=V.next;return U}consume(W,U){let V=this.head.data;if(W<V.length){let L=V.slice(0,W);return this.head.data=V.slice(W),L}if(W===V.length)return this.shift();return U?this._getString(W):this._getBuffer(W)}first(){return this.head.data}*[q](){for(let W=this.head;W;W=W.next)yield W.data}_getString(W){let U="",V=this.head,L=0;do{let w=V.data;if(W>w.length)U+=w,W-=w.length;else{if(W===w.length)if(U+=w,++L,V.next)this.head=V.next;else this.head=this.tail=null;else U+=J(w,0,W),this.head=V,V.data=J(w,W);break}++L}while((V=V.next)!==null);return this.length-=L,U}_getBuffer(W){let U=G.allocUnsafe(W),V=W,L=this.head,w=0;do{let M=L.data;if(W>M.length)X(U,M,V-W),W-=M.length;else{if(W===M.length)if(X(U,M,V-W),++w,L.next)this.head=L.next;else this.head=this.tail=null;else X(U,new Y(M.buffer,M.byteOffset,W),V-W),this.head=L,L.data=M.slice(W);break}++w}while((L=L.next)!==null);return this.length-=w,U}[Symbol.for("nodejs.util.inspect.custom")](W,U){return B(this,{...U,depth:0,customInspect:!1})}}}),V8=S0(($,Q)=>{var{MathFloor:J,NumberIsInteger:q}=Z0(),{validateInteger:X}=S6(),{ERR_INVALID_ARG_VALUE:Y}=d0().codes,G=16384,B=16;function W(w,M,y){return w.highWaterMark!=null?w.highWaterMark:M?w[y]:null}function U(w){return w?B:G}function V(w,M){if(X(M,"value",0),w)B=M;else G=M}function L(w,M,y,x){let A=W(M,x,y);if(A!=null){if(!q(A)||A<0){let P=x?`options.${y}`:"options.highWaterMark";throw new Y(P,A)}return J(A)}return U(w.objectMode)}Q.exports={getHighWaterMark:L,getDefaultHighWaterMark:U,setDefaultHighWaterMark:V}}),XX=S0(($,Q)=>{/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */var J=(x2(),q2(g2)),q=J.Buffer;function X(G,B){for(var W in G)B[W]=G[W]}if(q.from&&q.alloc&&q.allocUnsafe&&q.allocUnsafeSlow)Q.exports=J;else X(J,$),$.Buffer=Y;function Y(G,B,W){return q(G,B,W)}Y.prototype=Object.create(q.prototype),X(q,Y),Y.from=function(G,B,W){if(typeof G==="number")throw TypeError("Argument must not be a number");return q(G,B,W)},Y.alloc=function(G,B,W){if(typeof G!=="number")throw TypeError("Argument must be a number");var U=q(G);if(B!==void 0)if(typeof W==="string")U.fill(B,W);else U.fill(B);else U.fill(0);return U},Y.allocUnsafe=function(G){if(typeof G!=="number")throw TypeError("Argument must be a number");return q(G)},Y.allocUnsafeSlow=function(G){if(typeof G!=="number")throw TypeError("Argument must be a number");return J.SlowBuffer(G)}}),YX=S0(($)=>{var Q=XX().Buffer,J=Q.isEncoding||function(K){switch(K=""+K,K&&K.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function q(K){if(!K)return"utf8";var F;while(!0)switch(K){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return K;default:if(F)return;K=(""+K).toLowerCase(),F=!0}}function X(K){var F=q(K);if(typeof F!=="string"&&(Q.isEncoding===J||!J(K)))throw Error("Unknown encoding: "+K);return F||K}$.StringDecoder=Y;function Y(K){this.encoding=X(K);var F;switch(this.encoding){case"utf16le":this.text=w,this.end=M,F=4;break;case"utf8":this.fillLast=U,F=4;break;case"base64":this.text=y,this.end=x,F=3;break;default:this.write=A,this.end=P;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=Q.allocUnsafe(F)}Y.prototype.write=function(K){if(K.length===0)return"";var F,z;if(this.lastNeed){if(F=this.fillLast(K),F===void 0)return"";z=this.lastNeed,this.lastNeed=0}else z=0;if(z<K.length)return F?F+this.text(K,z):this.text(K,z);return F||""},Y.prototype.end=L,Y.prototype.text=V,Y.prototype.fillLast=function(K){if(this.lastNeed<=K.length)return K.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);K.copy(this.lastChar,this.lastTotal-this.lastNeed,0,K.length),this.lastNeed-=K.length};function G(K){if(K<=127)return 0;else if(K>>5===6)return 2;else if(K>>4===14)return 3;else if(K>>3===30)return 4;return K>>6===2?-1:-2}function B(K,F,z){var D=F.length-1;if(D<z)return 0;var _=G(F[D]);if(_>=0){if(_>0)K.lastNeed=_-1;return _}if(--D<z||_===-2)return 0;if(_=G(F[D]),_>=0){if(_>0)K.lastNeed=_-2;return _}if(--D<z||_===-2)return 0;if(_=G(F[D]),_>=0){if(_>0)if(_===2)_=0;else K.lastNeed=_-3;return _}return 0}function W(K,F,z){if((F[0]&192)!==128)return K.lastNeed=0,"�";if(K.lastNeed>1&&F.length>1){if((F[1]&192)!==128)return K.lastNeed=1,"�";if(K.lastNeed>2&&F.length>2){if((F[2]&192)!==128)return K.lastNeed=2,"�"}}}function U(K){var F=this.lastTotal-this.lastNeed,z=W(this,K,F);if(z!==void 0)return z;if(this.lastNeed<=K.length)return K.copy(this.lastChar,F,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);K.copy(this.lastChar,F,0,K.length),this.lastNeed-=K.length}function V(K,F){var z=B(this,K,F);if(!this.lastNeed)return K.toString("utf8",F);this.lastTotal=z;var D=K.length-(z-this.lastNeed);return K.copy(this.lastChar,0,D),K.toString("utf8",F,D)}function L(K){var F=K&&K.length?this.write(K):"";if(this.lastNeed)return F+"�";return F}function w(K,F){if((K.length-F)%2===0){var z=K.toString("utf16le",F);if(z){var D=z.charCodeAt(z.length-1);if(D>=55296&&D<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=K[K.length-2],this.lastChar[1]=K[K.length-1],z.slice(0,-1)}return z}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=K[K.length-1],K.toString("utf16le",F,K.length-1)}function M(K){var F=K&&K.length?this.write(K):"";if(this.lastNeed){var z=this.lastTotal-this.lastNeed;return F+this.lastChar.toString("utf16le",0,z)}return F}function y(K,F){var z=(K.length-F)%3;if(z===0)return K.toString("base64",F);if(this.lastNeed=3-z,this.lastTotal=3,z===1)this.lastChar[0]=K[K.length-1];else this.lastChar[0]=K[K.length-2],this.lastChar[1]=K[K.length-1];return K.toString("base64",F,K.length-z)}function x(K){var F=K&&K.length?this.write(K):"";if(this.lastNeed)return F+this.lastChar.toString("base64",0,3-this.lastNeed);return F}function A(K){return K.toString(this.encoding)}function P(K){return K&&K.length?this.write(K):""}}),r7=S0(($,Q)=>{var J=L1(),{PromisePrototypeThen:q,SymbolAsyncIterator:X,SymbolIterator:Y}=Z0(),{Buffer:G}=(x2(),q2(g2)),{ERR_INVALID_ARG_TYPE:B,ERR_STREAM_NULL_VALUES:W}=d0().codes;function U(V,L,w){let M;if(typeof L==="string"||L instanceof G)return new V({objectMode:!0,...w,read(){this.push(L),this.push(null)}});let y;if(L&&L[X])y=!0,M=L[X]();else if(L&&L[Y])y=!1,M=L[Y]();else throw new B("iterable",["Iterable"],L);let x=new V({objectMode:!0,highWaterMark:1,...w}),A=!1;x._read=function(){if(!A)A=!0,K()},x._destroy=function(F,z){q(P(F),()=>J.nextTick(z,F),(D)=>J.nextTick(z,D||F))};async function P(F){let z=F!==void 0&&F!==null,D=typeof M.throw==="function";if(z&&D){let{value:_,done:T}=await M.throw(F);if(await _,T)return}if(typeof M.return==="function"){let{value:_}=await M.return();await _}}async function K(){for(;;){try{let{value:F,done:z}=y?await M.next():M.next();if(z)x.push(null);else{let D=F&&typeof F.then==="function"?await F:F;if(D===null)throw A=!1,new W;else if(x.push(D))continue;else A=!1}}catch(F){x.destroy(F)}break}}return x}Q.exports=U}),K8=S0(($,Q)=>{var J=L1(),{ArrayPrototypeIndexOf:q,NumberIsInteger:X,NumberIsNaN:Y,NumberParseInt:G,ObjectDefineProperties:B,ObjectKeys:W,ObjectSetPrototypeOf:U,Promise:V,SafeSet:L,SymbolAsyncDispose:w,SymbolAsyncIterator:M,Symbol:y}=Z0();Q.exports=n,n.ReadableState=q0;var{EventEmitter:x}=(R6(),q2(C6)),{Stream:A,prependListener:P}=N5(),{Buffer:K}=(x2(),q2(g2)),{addAbortSignal:F}=W8(),z=n2(),D=r0().debuglog("stream",(H)=>{D=H}),_=qX(),T=b1(),{getHighWaterMark:l,getDefaultHighWaterMark:S}=V8(),{aggregateTwoErrors:E,codes:{ERR_INVALID_ARG_TYPE:C,ERR_METHOD_NOT_IMPLEMENTED:N,ERR_OUT_OF_RANGE:Z,ERR_STREAM_PUSH_AFTER_EOF:f,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:k},AbortError:s}=d0(),{validateObject:J0}=S6(),B0=y("kPaused"),{StringDecoder:O0}=YX(),u=r7();U(n.prototype,A.prototype),U(n,A);var K0=()=>{},{errorOrDestroy:O}=T,d=1,Y0=2,m=4,W0=8,M0=16,C0=32,N0=64,c=128,p=256,t=512,L0=1024,z0=2048,R=4096,v=8192,h=16384,a=32768,Q0=65536,e=131072,I=262144;function i(H){return{enumerable:!1,get(){return(this.state&H)!==0},set(j){if(j)this.state|=H;else this.state&=~H}}}B(q0.prototype,{objectMode:i(d),ended:i(Y0),endEmitted:i(m),reading:i(W0),constructed:i(M0),sync:i(C0),needReadable:i(N0),emittedReadable:i(c),readableListening:i(p),resumeScheduled:i(t),errorEmitted:i(L0),emitClose:i(z0),autoDestroy:i(R),destroyed:i(v),closed:i(h),closeEmitted:i(a),multiAwaitDrain:i(Q0),readingMore:i(e),dataEmitted:i(I)});function q0(H,j,r){if(typeof r!=="boolean")r=j instanceof f2();if(this.state=z0|R|M0|C0,H&&H.objectMode)this.state|=d;if(r&&H&&H.readableObjectMode)this.state|=d;if(this.highWaterMark=H?l(this,H,"readableHighWaterMark",r):S(!1),this.buffer=new _,this.length=0,this.pipes=[],this.flowing=null,this[B0]=null,H&&H.emitClose===!1)this.state&=~z0;if(H&&H.autoDestroy===!1)this.state&=~R;if(this.errored=null,this.defaultEncoding=H&&H.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,H&&H.encoding)this.decoder=new O0(H.encoding),this.encoding=H.encoding}function n(H){if(!(this instanceof n))return new n(H);let j=this instanceof f2();if(this._readableState=new q0(H,this,j),H){if(typeof H.read==="function")this._read=H.read;if(typeof H.destroy==="function")this._destroy=H.destroy;if(typeof H.construct==="function")this._construct=H.construct;if(H.signal&&!j)F(H.signal,this)}A.call(this,H),T.construct(this,()=>{if(this._readableState.needReadable)f1(this,this._readableState)})}n.prototype.destroy=T.destroy,n.prototype._undestroy=T.undestroy,n.prototype._destroy=function(H,j){j(H)},n.prototype[x.captureRejectionSymbol]=function(H){this.destroy(H)},n.prototype[w]=function(){let H;if(!this.destroyed)H=this.readableEnded?null:new s,this.destroy(H);return new V((j,r)=>z(this,(G0)=>G0&&G0!==H?r(G0):j(null)))},n.prototype.push=function(H,j){return H0(this,H,j,!1)},n.prototype.unshift=function(H,j){return H0(this,H,j,!0)};function H0(H,j,r,G0){D("readableAddChunk",j);let U0=H._readableState,c0;if((U0.state&d)===0){if(typeof j==="string"){if(r=r||U0.defaultEncoding,U0.encoding!==r)if(G0&&U0.encoding)j=K.from(j,r).toString(U0.encoding);else j=K.from(j,r),r=""}else if(j instanceof K)r="";else if(A._isUint8Array(j))j=A._uint8ArrayToBuffer(j),r="";else if(j!=null)c0=new C("chunk",["string","Buffer","Uint8Array"],j)}if(c0)O(H,c0);else if(j===null)U0.state&=~W0,u0(H,U0);else if((U0.state&d)!==0||j&&j.length>0)if(G0)if((U0.state&m)!==0)O(H,new k);else if(U0.destroyed||U0.errored)return!1;else E0(H,U0,j,!0);else if(U0.ended)O(H,new f);else if(U0.destroyed||U0.errored)return!1;else if(U0.state&=~W0,U0.decoder&&!r)if(j=U0.decoder.write(j),U0.objectMode||j.length!==0)E0(H,U0,j,!1);else f1(H,U0);else E0(H,U0,j,!1);else if(!G0)U0.state&=~W0,f1(H,U0);return!U0.ended&&(U0.length<U0.highWaterMark||U0.length===0)}function E0(H,j,r,G0){if(j.flowing&&j.length===0&&!j.sync&&H.listenerCount("data")>0){if((j.state&Q0)!==0)j.awaitDrainWriters.clear();else j.awaitDrainWriters=null;j.dataEmitted=!0,H.emit("data",r)}else{if(j.length+=j.objectMode?1:r.length,G0)j.buffer.unshift(r);else j.buffer.push(r);if((j.state&N0)!==0)n0(H)}f1(H,j)}n.prototype.isPaused=function(){let H=this._readableState;return H[B0]===!0||H.flowing===!1},n.prototype.setEncoding=function(H){let j=new O0(H);this._readableState.decoder=j,this._readableState.encoding=this._readableState.decoder.encoding;let r=this._readableState.buffer,G0="";for(let U0 of r)G0+=j.write(U0);if(r.clear(),G0!=="")r.push(G0);return this._readableState.length=G0.length,this};var $2=1073741824;function Q2(H){if(H>$2)throw new Z("size","<= 1GiB",H);else H--,H|=H>>>1,H|=H>>>2,H|=H>>>4,H|=H>>>8,H|=H>>>16,H++;return H}function V1(H,j){if(H<=0||j.length===0&&j.ended)return 0;if((j.state&d)!==0)return 1;if(Y(H)){if(j.flowing&&j.length)return j.buffer.first().length;return j.length}if(H<=j.length)return H;return j.ended?j.length:0}n.prototype.read=function(H){if(D("read",H),H===void 0)H=NaN;else if(!X(H))H=G(H,10);let j=this._readableState,r=H;if(H>j.highWaterMark)j.highWaterMark=Q2(H);if(H!==0)j.state&=~c;if(H===0&&j.needReadable&&((j.highWaterMark!==0?j.length>=j.highWaterMark:j.length>0)||j.ended)){if(D("read: emitReadable",j.length,j.ended),j.length===0&&j.ended)J5(this);else n0(this);return null}if(H=V1(H,j),H===0&&j.ended){if(j.length===0)J5(this);return null}let G0=(j.state&N0)!==0;if(D("need readable",G0),j.length===0||j.length-H<j.highWaterMark)G0=!0,D("length less than watermark",G0);if(j.ended||j.reading||j.destroyed||j.errored||!j.constructed)G0=!1,D("reading, ended or constructing",G0);else if(G0){if(D("do read"),j.state|=W0|C0,j.length===0)j.state|=N0;try{this._read(j.highWaterMark)}catch(c0){O(this,c0)}if(j.state&=~C0,!j.reading)H=V1(r,j)}let U0;if(H>0)U0=Q7(H,j);else U0=null;if(U0===null)j.needReadable=j.length<=j.highWaterMark,H=0;else if(j.length-=H,j.multiAwaitDrain)j.awaitDrainWriters.clear();else j.awaitDrainWriters=null;if(j.length===0){if(!j.ended)j.needReadable=!0;if(r!==H&&j.ended)J5(this)}if(U0!==null&&!j.errorEmitted&&!j.closeEmitted)j.dataEmitted=!0,this.emit("data",U0);return U0};function u0(H,j){if(D("onEofChunk"),j.ended)return;if(j.decoder){let r=j.decoder.end();if(r&&r.length)j.buffer.push(r),j.length+=j.objectMode?1:r.length}if(j.ended=!0,j.sync)n0(H);else j.needReadable=!1,j.emittedReadable=!0,x1(H)}function n0(H){let j=H._readableState;if(D("emitReadable",j.needReadable,j.emittedReadable),j.needReadable=!1,!j.emittedReadable)D("emitReadable",j.flowing),j.emittedReadable=!0,J.nextTick(x1,H)}function x1(H){let j=H._readableState;if(D("emitReadable_",j.destroyed,j.length,j.ended),!j.destroyed&&!j.errored&&(j.length||j.ended))H.emit("readable"),j.emittedReadable=!1;j.needReadable=!j.flowing&&!j.ended&&j.length<=j.highWaterMark,e4(H)}function f1(H,j){if(!j.readingMore&&j.constructed)j.readingMore=!0,J.nextTick(L2,H,j)}function L2(H,j){while(!j.reading&&!j.ended&&(j.length<j.highWaterMark||j.flowing&&j.length===0)){let r=j.length;if(D("maybeReadMore read 0"),H.read(0),r===j.length)break}j.readingMore=!1}n.prototype._read=function(H){throw new N("_read()")},n.prototype.pipe=function(H,j){let r=this,G0=this._readableState;if(G0.pipes.length===1){if(!G0.multiAwaitDrain)G0.multiAwaitDrain=!0,G0.awaitDrainWriters=new L(G0.awaitDrainWriters?[G0.awaitDrainWriters]:[])}G0.pipes.push(H),D("pipe count=%d opts=%j",G0.pipes.length,j);let U0=(!j||j.end!==!1)&&H!==J.stdout&&H!==J.stderr?J2:O6;if(G0.endEmitted)J.nextTick(U0);else r.once("end",U0);H.on("unpipe",c0);function c0(H1,T2){if(D("onunpipe"),H1===r){if(T2&&T2.hasUnpiped===!1)T2.hasUnpiped=!0,eJ()}}function J2(){D("onend"),H.end()}let K1,q7=!1;function eJ(){if(D("cleanup"),H.removeListener("close",Y5),H.removeListener("finish",G5),K1)H.removeListener("drain",K1);if(H.removeListener("error",X5),H.removeListener("unpipe",c0),r.removeListener("end",J2),r.removeListener("end",O6),r.removeListener("data",Y7),q7=!0,K1&&G0.awaitDrainWriters&&(!H._writableState||H._writableState.needDrain))K1()}function X7(){if(!q7){if(G0.pipes.length===1&&G0.pipes[0]===H)D("false write response, pause",0),G0.awaitDrainWriters=H,G0.multiAwaitDrain=!1;else if(G0.pipes.length>1&&G0.pipes.includes(H))D("false write response, pause",G0.awaitDrainWriters.size),G0.awaitDrainWriters.add(H);r.pause()}if(!K1)K1=iJ(r,H),H.on("drain",K1)}r.on("data",Y7);function Y7(H1){D("ondata");let T2=H.write(H1);if(D("dest.write",T2),T2===!1)X7()}function X5(H1){if(D("onerror",H1),O6(),H.removeListener("error",X5),H.listenerCount("error")===0){let T2=H._writableState||H._readableState;if(T2&&!T2.errorEmitted)O(H,H1);else H.emit("error",H1)}}P(H,"error",X5);function Y5(){H.removeListener("finish",G5),O6()}H.once("close",Y5);function G5(){D("onfinish"),H.removeListener("close",Y5),O6()}H.once("finish",G5);function O6(){D("unpipe"),r.unpipe(H)}if(H.emit("pipe",r),H.writableNeedDrain===!0)X7();else if(!G0.flowing)D("pipe resume"),r.resume();return H};function iJ(H,j){return function(){let r=H._readableState;if(r.awaitDrainWriters===j)D("pipeOnDrain",1),r.awaitDrainWriters=null;else if(r.multiAwaitDrain)D("pipeOnDrain",r.awaitDrainWriters.size),r.awaitDrainWriters.delete(j);if((!r.awaitDrainWriters||r.awaitDrainWriters.size===0)&&H.listenerCount("data"))H.resume()}}n.prototype.unpipe=function(H){let j=this._readableState,r={hasUnpiped:!1};if(j.pipes.length===0)return this;if(!H){let U0=j.pipes;j.pipes=[],this.pause();for(let c0=0;c0<U0.length;c0++)U0[c0].emit("unpipe",this,{hasUnpiped:!1});return this}let G0=q(j.pipes,H);if(G0===-1)return this;if(j.pipes.splice(G0,1),j.pipes.length===0)this.pause();return H.emit("unpipe",this,r),this},n.prototype.on=function(H,j){let r=A.prototype.on.call(this,H,j),G0=this._readableState;if(H==="data"){if(G0.readableListening=this.listenerCount("readable")>0,G0.flowing!==!1)this.resume()}else if(H==="readable"){if(!G0.endEmitted&&!G0.readableListening){if(G0.readableListening=G0.needReadable=!0,G0.flowing=!1,G0.emittedReadable=!1,D("on readable",G0.length,G0.reading),G0.length)n0(this);else if(!G0.reading)J.nextTick(nJ,this)}}return r},n.prototype.addListener=n.prototype.on,n.prototype.removeListener=function(H,j){let r=A.prototype.removeListener.call(this,H,j);if(H==="readable")J.nextTick(t4,this);return r},n.prototype.off=n.prototype.removeListener,n.prototype.removeAllListeners=function(H){let j=A.prototype.removeAllListeners.apply(this,arguments);if(H==="readable"||H===void 0)J.nextTick(t4,this);return j};function t4(H){let j=H._readableState;if(j.readableListening=H.listenerCount("readable")>0,j.resumeScheduled&&j[B0]===!1)j.flowing=!0;else if(H.listenerCount("data")>0)H.resume();else if(!j.readableListening)j.flowing=null}function nJ(H){D("readable nexttick read 0"),H.read(0)}n.prototype.resume=function(){let H=this._readableState;if(!H.flowing)D("resume"),H.flowing=!H.readableListening,oJ(this,H);return H[B0]=!1,this};function oJ(H,j){if(!j.resumeScheduled)j.resumeScheduled=!0,J.nextTick(rJ,H,j)}function rJ(H,j){if(D("resume",j.reading),!j.reading)H.read(0);if(j.resumeScheduled=!1,H.emit("resume"),e4(H),j.flowing&&!j.reading)H.read(0)}n.prototype.pause=function(){if(D("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1)D("pause"),this._readableState.flowing=!1,this.emit("pause");return this._readableState[B0]=!0,this};function e4(H){let j=H._readableState;D("flow",j.flowing);while(j.flowing&&H.read()!==null);}n.prototype.wrap=function(H){let j=!1;H.on("data",(G0)=>{if(!this.push(G0)&&H.pause)j=!0,H.pause()}),H.on("end",()=>{this.push(null)}),H.on("error",(G0)=>{O(this,G0)}),H.on("close",()=>{this.destroy()}),H.on("destroy",()=>{this.destroy()}),this._read=()=>{if(j&&H.resume)j=!1,H.resume()};let r=W(H);for(let G0=1;G0<r.length;G0++){let U0=r[G0];if(this[U0]===void 0&&typeof H[U0]==="function")this[U0]=H[U0].bind(H)}return this},n.prototype[M]=function(){return $7(this)},n.prototype.iterator=function(H){if(H!==void 0)J0(H,"options");return $7(this,H)};function $7(H,j){if(typeof H.read!=="function")H=n.wrap(H,{objectMode:!0});let r=aJ(H,j);return r.stream=H,r}async function*aJ(H,j){let r=K0;function G0(J2){if(this===H)r(),r=K0;else r=J2}H.on("readable",G0);let U0,c0=z(H,{writable:!1},(J2)=>{U0=J2?E(U0,J2):null,r(),r=K0});try{while(!0){let J2=H.destroyed?null:H.read();if(J2!==null)yield J2;else if(U0)throw U0;else if(U0===null)return;else await new V(G0)}}catch(J2){throw U0=E(U0,J2),U0}finally{if((U0||(j===null||j===void 0?void 0:j.destroyOnReturn)!==!1)&&(U0===void 0||H._readableState.autoDestroy))T.destroyer(H,null);else H.off("readable",G0),c0()}}B(n.prototype,{readable:{__proto__:null,get(){let H=this._readableState;return!!H&&H.readable!==!1&&!H.destroyed&&!H.errorEmitted&&!H.endEmitted},set(H){if(this._readableState)this._readableState.readable=!!H}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(this._readableState.destroyed||this._readableState.errored)&&!this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(H){if(this._readableState)this._readableState.flowing=H}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return this._readableState?this._readableState.closed:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(H){if(!this._readableState)return;this._readableState.destroyed=H}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}}),B(q0.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[B0]!==!1},set(H){this[B0]=!!H}}}),n._fromList=Q7;function Q7(H,j){if(j.length===0)return null;let r;if(j.objectMode)r=j.buffer.shift();else if(!H||H>=j.length){if(j.decoder)r=j.buffer.join("");else if(j.buffer.length===1)r=j.buffer.first();else r=j.buffer.concat(j.length);j.buffer.clear()}else r=j.buffer.consume(H,j.decoder);return r}function J5(H){let j=H._readableState;if(D("endReadable",j.endEmitted),!j.endEmitted)j.ended=!0,J.nextTick(sJ,j,H)}function sJ(H,j){if(D("endReadableNT",H.endEmitted,H.length),!H.errored&&!H.closeEmitted&&!H.endEmitted&&H.length===0){if(H.endEmitted=!0,j.emit("end"),j.writable&&j.allowHalfOpen===!1)J.nextTick(tJ,j);else if(H.autoDestroy){let r=j._writableState;if(!r||r.autoDestroy&&(r.finished||r.writable===!1))j.destroy()}}}function tJ(H){if(H.writable&&!H.writableEnded&&!H.destroyed)H.end()}n.from=function(H,j){return u(n,H,j)};var q5;function J7(){if(q5===void 0)q5={};return q5}n.fromWeb=function(H,j){return J7().newStreamReadableFromReadableStream(H,j)},n.toWeb=function(H,j){return J7().newReadableStreamFromStreamReadable(H,j)},n.wrap=function(H,j){var r,G0;return new n({objectMode:(r=(G0=H.readableObjectMode)!==null&&G0!==void 0?G0:H.objectMode)!==null&&r!==void 0?r:!0,...j,destroy(U0,c0){T.destroyer(H,U0),c0(U0)}}).wrap(H)}}),A5=S0(($,Q)=>{var J=L1(),{ArrayPrototypeSlice:q,Error:X,FunctionPrototypeSymbolHasInstance:Y,ObjectDefineProperty:G,ObjectDefineProperties:B,ObjectSetPrototypeOf:W,StringPrototypeToLowerCase:U,Symbol:V,SymbolHasInstance:L}=Z0();Q.exports=J0,J0.WritableState=k;var{EventEmitter:w}=(R6(),q2(C6)),M=N5().Stream,{Buffer:y}=(x2(),q2(g2)),x=b1(),{addAbortSignal:A}=W8(),{getHighWaterMark:P,getDefaultHighWaterMark:K}=V8(),{ERR_INVALID_ARG_TYPE:F,ERR_METHOD_NOT_IMPLEMENTED:z,ERR_MULTIPLE_CALLBACK:D,ERR_STREAM_CANNOT_PIPE:_,ERR_STREAM_DESTROYED:T,ERR_STREAM_ALREADY_FINISHED:l,ERR_STREAM_NULL_VALUES:S,ERR_STREAM_WRITE_AFTER_END:E,ERR_UNKNOWN_ENCODING:C}=d0().codes,{errorOrDestroy:N}=x;W(J0.prototype,M.prototype),W(J0,M);function Z(){}var f=V("kOnFinished");function k(R,v,h){if(typeof h!=="boolean")h=v instanceof f2();if(this.objectMode=!!(R&&R.objectMode),h)this.objectMode=this.objectMode||!!(R&&R.writableObjectMode);this.highWaterMark=R?P(this,R,"writableHighWaterMark",h):K(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;let a=!!(R&&R.decodeStrings===!1);this.decodeStrings=!a,this.defaultEncoding=R&&R.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=O.bind(void 0,v),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,s(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!R||R.emitClose!==!1,this.autoDestroy=!R||R.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[f]=[]}function s(R){R.buffered=[],R.bufferedIndex=0,R.allBuffers=!0,R.allNoop=!0}k.prototype.getBuffer=function(){return q(this.buffered,this.bufferedIndex)},G(k.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function J0(R){let v=this instanceof f2();if(!v&&!Y(J0,this))return new J0(R);if(this._writableState=new k(R,this,v),R){if(typeof R.write==="function")this._write=R.write;if(typeof R.writev==="function")this._writev=R.writev;if(typeof R.destroy==="function")this._destroy=R.destroy;if(typeof R.final==="function")this._final=R.final;if(typeof R.construct==="function")this._construct=R.construct;if(R.signal)A(R.signal,this)}M.call(this,R),x.construct(this,()=>{let h=this._writableState;if(!h.writing)W0(this,h);c(this,h)})}G(J0,L,{__proto__:null,value:function(R){if(Y(this,R))return!0;if(this!==J0)return!1;return R&&R._writableState instanceof k}}),J0.prototype.pipe=function(){N(this,new _)};function B0(R,v,h,a){let Q0=R._writableState;if(typeof h==="function")a=h,h=Q0.defaultEncoding;else{if(!h)h=Q0.defaultEncoding;else if(h!=="buffer"&&!y.isEncoding(h))throw new C(h);if(typeof a!=="function")a=Z}if(v===null)throw new S;else if(!Q0.objectMode)if(typeof v==="string"){if(Q0.decodeStrings!==!1)v=y.from(v,h),h="buffer"}else if(v instanceof y)h="buffer";else if(M._isUint8Array(v))v=M._uint8ArrayToBuffer(v),h="buffer";else throw new F("chunk",["string","Buffer","Uint8Array"],v);let e;if(Q0.ending)e=new E;else if(Q0.destroyed)e=new T("write");if(e)return J.nextTick(a,e),N(R,e,!0),e;return Q0.pendingcb++,O0(R,Q0,v,h,a)}J0.prototype.write=function(R,v,h){return B0(this,R,v,h)===!0},J0.prototype.cork=function(){this._writableState.corked++},J0.prototype.uncork=function(){let R=this._writableState;if(R.corked){if(R.corked--,!R.writing)W0(this,R)}},J0.prototype.setDefaultEncoding=function(R){if(typeof R==="string")R=U(R);if(!y.isEncoding(R))throw new C(R);return this._writableState.defaultEncoding=R,this};function O0(R,v,h,a,Q0){let e=v.objectMode?1:h.length;v.length+=e;let I=v.length<v.highWaterMark;if(!I)v.needDrain=!0;if(v.writing||v.corked||v.errored||!v.constructed){if(v.buffered.push({chunk:h,encoding:a,callback:Q0}),v.allBuffers&&a!=="buffer")v.allBuffers=!1;if(v.allNoop&&Q0!==Z)v.allNoop=!1}else v.writelen=e,v.writecb=Q0,v.writing=!0,v.sync=!0,R._write(h,a,v.onwrite),v.sync=!1;return I&&!v.errored&&!v.destroyed}function u(R,v,h,a,Q0,e,I){if(v.writelen=a,v.writecb=I,v.writing=!0,v.sync=!0,v.destroyed)v.onwrite(new T("write"));else if(h)R._writev(Q0,v.onwrite);else R._write(Q0,e,v.onwrite);v.sync=!1}function K0(R,v,h,a){--v.pendingcb,a(h),m(v),N(R,h)}function O(R,v){let h=R._writableState,a=h.sync,Q0=h.writecb;if(typeof Q0!=="function"){N(R,new D);return}if(h.writing=!1,h.writecb=null,h.length-=h.writelen,h.writelen=0,v){if(v.stack,!h.errored)h.errored=v;if(R._readableState&&!R._readableState.errored)R._readableState.errored=v;if(a)J.nextTick(K0,R,h,v,Q0);else K0(R,h,v,Q0)}else{if(h.buffered.length>h.bufferedIndex)W0(R,h);if(a)if(h.afterWriteTickInfo!==null&&h.afterWriteTickInfo.cb===Q0)h.afterWriteTickInfo.count++;else h.afterWriteTickInfo={count:1,cb:Q0,stream:R,state:h},J.nextTick(d,h.afterWriteTickInfo);else Y0(R,h,1,Q0)}}function d({stream:R,state:v,count:h,cb:a}){return v.afterWriteTickInfo=null,Y0(R,v,h,a)}function Y0(R,v,h,a){if(!v.ending&&!R.destroyed&&v.length===0&&v.needDrain)v.needDrain=!1,R.emit("drain");while(h-- >0)v.pendingcb--,a();if(v.destroyed)m(v);c(R,v)}function m(R){if(R.writing)return;for(let Q0=R.bufferedIndex;Q0<R.buffered.length;++Q0){var v;let{chunk:e,callback:I}=R.buffered[Q0],i=R.objectMode?1:e.length;R.length-=i,I((v=R.errored)!==null&&v!==void 0?v:new T("write"))}let h=R[f].splice(0);for(let Q0=0;Q0<h.length;Q0++){var a;h[Q0]((a=R.errored)!==null&&a!==void 0?a:new T("end"))}s(R)}function W0(R,v){if(v.corked||v.bufferProcessing||v.destroyed||!v.constructed)return;let{buffered:h,bufferedIndex:a,objectMode:Q0}=v,e=h.length-a;if(!e)return;let I=a;if(v.bufferProcessing=!0,e>1&&R._writev){v.pendingcb-=e-1;let i=v.allNoop?Z:(n)=>{for(let H0=I;H0<h.length;++H0)h[H0].callback(n)},q0=v.allNoop&&I===0?h:q(h,I);q0.allBuffers=v.allBuffers,u(R,v,!0,v.length,q0,"",i),s(v)}else{do{let{chunk:i,encoding:q0,callback:n}=h[I];h[I++]=null;let H0=Q0?1:i.length;u(R,v,!1,H0,i,q0,n)}while(I<h.length&&!v.writing);if(I===h.length)s(v);else if(I>256)h.splice(0,I),v.bufferedIndex=0;else v.bufferedIndex=I}v.bufferProcessing=!1}J0.prototype._write=function(R,v,h){if(this._writev)this._writev([{chunk:R,encoding:v}],h);else throw new z("_write()")},J0.prototype._writev=null,J0.prototype.end=function(R,v,h){let a=this._writableState;if(typeof R==="function")h=R,R=null,v=null;else if(typeof v==="function")h=v,v=null;let Q0;if(R!==null&&R!==void 0){let e=B0(this,R,v);if(e instanceof X)Q0=e}if(a.corked)a.corked=1,this.uncork();if(Q0);else if(!a.errored&&!a.ending)a.ending=!0,c(this,a,!0),a.ended=!0;else if(a.finished)Q0=new l("end");else if(a.destroyed)Q0=new T("end");if(typeof h==="function")if(Q0||a.finished)J.nextTick(h,Q0);else a[f].push(h);return this};function M0(R){return R.ending&&!R.destroyed&&R.constructed&&R.length===0&&!R.errored&&R.buffered.length===0&&!R.finished&&!R.writing&&!R.errorEmitted&&!R.closeEmitted}function C0(R,v){let h=!1;function a(Q0){if(h){N(R,Q0!==null&&Q0!==void 0?Q0:D());return}if(h=!0,v.pendingcb--,Q0){let e=v[f].splice(0);for(let I=0;I<e.length;I++)e[I](Q0);N(R,Q0,v.sync)}else if(M0(v))v.prefinished=!0,R.emit("prefinish"),v.pendingcb++,J.nextTick(p,R,v)}v.sync=!0,v.pendingcb++;try{R._final(a)}catch(Q0){a(Q0)}v.sync=!1}function N0(R,v){if(!v.prefinished&&!v.finalCalled)if(typeof R._final==="function"&&!v.destroyed)v.finalCalled=!0,C0(R,v);else v.prefinished=!0,R.emit("prefinish")}function c(R,v,h){if(M0(v)){if(N0(R,v),v.pendingcb===0){if(h)v.pendingcb++,J.nextTick((a,Q0)=>{if(M0(Q0))p(a,Q0);else Q0.pendingcb--},R,v);else if(M0(v))v.pendingcb++,p(R,v)}}}function p(R,v){v.pendingcb--,v.finished=!0;let h=v[f].splice(0);for(let a=0;a<h.length;a++)h[a]();if(R.emit("finish"),v.autoDestroy){let a=R._readableState;if(!a||a.autoDestroy&&(a.endEmitted||a.readable===!1))R.destroy()}}B(J0.prototype,{closed:{__proto__:null,get(){return this._writableState?this._writableState.closed:!1}},destroyed:{__proto__:null,get(){return this._writableState?this._writableState.destroyed:!1},set(R){if(this._writableState)this._writableState.destroyed=R}},writable:{__proto__:null,get(){let R=this._writableState;return!!R&&R.writable!==!1&&!R.destroyed&&!R.errored&&!R.ending&&!R.ended},set(R){if(this._writableState)this._writableState.writable=!!R}},writableFinished:{__proto__:null,get(){return this._writableState?this._writableState.finished:!1}},writableObjectMode:{__proto__:null,get(){return this._writableState?this._writableState.objectMode:!1}},writableBuffer:{__proto__:null,get(){return this._writableState&&this._writableState.getBuffer()}},writableEnded:{__proto__:null,get(){return this._writableState?this._writableState.ending:!1}},writableNeedDrain:{__proto__:null,get(){let R=this._writableState;if(!R)return!1;return!R.destroyed&&!R.ending&&R.needDrain}},writableHighWaterMark:{__proto__:null,get(){return this._writableState&&this._writableState.highWaterMark}},writableCorked:{__proto__:null,get(){return this._writableState?this._writableState.corked:0}},writableLength:{__proto__:null,get(){return this._writableState&&this._writableState.length}},errored:{__proto__:null,enumerable:!1,get(){return this._writableState?this._writableState.errored:null}},writableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._writableState.writable!==!1&&(this._writableState.destroyed||this._writableState.errored)&&!this._writableState.finished)}}});var t=x.destroy;J0.prototype.destroy=function(R,v){let h=this._writableState;if(!h.destroyed&&(h.bufferedIndex<h.buffered.length||h[f].length))J.nextTick(m,h);return t.call(this,R,v),this},J0.prototype._undestroy=x.undestroy,J0.prototype._destroy=function(R,v){v(R)},J0.prototype[w.captureRejectionSymbol]=function(R){this.destroy(R)};var L0;function z0(){if(L0===void 0)L0={};return L0}J0.fromWeb=function(R,v){return z0().newStreamWritableFromWritableStream(R,v)},J0.toWeb=function(R){return z0().newWritableStreamFromStreamWritable(R)}}),GX=S0(($,Q)=>{var J=L1(),q=(x2(),q2(g2)),{isReadable:X,isWritable:Y,isIterable:G,isNodeStream:B,isReadableNodeStream:W,isWritableNodeStream:U,isDuplexNodeStream:V,isReadableStream:L,isWritableStream:w}=y2(),M=n2(),{AbortError:y,codes:{ERR_INVALID_ARG_TYPE:x,ERR_INVALID_RETURN_VALUE:A}}=d0(),{destroyer:P}=b1(),K=f2(),F=K8(),z=A5(),{createDeferredPromise:D}=r0(),_=r7(),T=globalThis.Blob||q.Blob,l=typeof T<"u"?function(f){return f instanceof T}:function(f){return!1},S=globalThis.AbortController||I6().AbortController,{FunctionPrototypeCall:E}=Z0();class C extends K{constructor(f){super(f);if((f===null||f===void 0?void 0:f.readable)===!1)this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0;if((f===null||f===void 0?void 0:f.writable)===!1)this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0}}Q.exports=function f(k,s){if(V(k))return k;if(W(k))return Z({readable:k});if(U(k))return Z({writable:k});if(B(k))return Z({writable:!1,readable:!1});if(L(k))return Z({readable:F.fromWeb(k)});if(w(k))return Z({writable:z.fromWeb(k)});if(typeof k==="function"){let{value:B0,write:O0,final:u,destroy:K0}=N(k);if(G(B0))return _(C,B0,{objectMode:!0,write:O0,final:u,destroy:K0});let O=B0===null||B0===void 0?void 0:B0.then;if(typeof O==="function"){let d,Y0=E(O,B0,(m)=>{if(m!=null)throw new A("nully","body",m)},(m)=>{P(d,m)});return d=new C({objectMode:!0,readable:!1,write:O0,final(m){u(async()=>{try{await Y0,J.nextTick(m,null)}catch(W0){J.nextTick(m,W0)}})},destroy:K0})}throw new A("Iterable, AsyncIterable or AsyncFunction",s,B0)}if(l(k))return f(k.arrayBuffer());if(G(k))return _(C,k,{objectMode:!0,writable:!1});if(L(k===null||k===void 0?void 0:k.readable)&&w(k===null||k===void 0?void 0:k.writable))return C.fromWeb(k);if(typeof(k===null||k===void 0?void 0:k.writable)==="object"||typeof(k===null||k===void 0?void 0:k.readable)==="object"){let B0=k!==null&&k!==void 0&&k.readable?W(k===null||k===void 0?void 0:k.readable)?k===null||k===void 0?void 0:k.readable:f(k.readable):void 0,O0=k!==null&&k!==void 0&&k.writable?U(k===null||k===void 0?void 0:k.writable)?k===null||k===void 0?void 0:k.writable:f(k.writable):void 0;return Z({readable:B0,writable:O0})}let J0=k===null||k===void 0?void 0:k.then;if(typeof J0==="function"){let B0;return E(J0,k,(O0)=>{if(O0!=null)B0.push(O0);B0.push(null)},(O0)=>{P(B0,O0)}),B0=new C({objectMode:!0,writable:!1,read(){}})}throw new x(s,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],k)};function N(f){let{promise:k,resolve:s}=D(),J0=new S,B0=J0.signal;return{value:f(async function*(){while(!0){let O0=k;k=null;let{chunk:u,done:K0,cb:O}=await O0;if(J.nextTick(O),K0)return;if(B0.aborted)throw new y(void 0,{cause:B0.reason});({promise:k,resolve:s}=D()),yield u}}(),{signal:B0}),write(O0,u,K0){let O=s;s=null,O({chunk:O0,done:!1,cb:K0})},final(O0){let u=s;s=null,u({done:!0,cb:O0})},destroy(O0,u){J0.abort(),u(O0)}}}function Z(f){let k=f.readable&&typeof f.readable.read!=="function"?F.wrap(f.readable):f.readable,s=f.writable,J0=!!X(k),B0=!!Y(s),O0,u,K0,O,d;function Y0(m){let W0=O;if(O=null,W0)W0(m);else if(m)d.destroy(m)}if(d=new C({readableObjectMode:!!(k!==null&&k!==void 0&&k.readableObjectMode),writableObjectMode:!!(s!==null&&s!==void 0&&s.writableObjectMode),readable:J0,writable:B0}),B0)M(s,(m)=>{if(B0=!1,m)P(k,m);Y0(m)}),d._write=function(m,W0,M0){if(s.write(m,W0))M0();else O0=M0},d._final=function(m){s.end(),u=m},s.on("drain",function(){if(O0){let m=O0;O0=null,m()}}),s.on("finish",function(){if(u){let m=u;u=null,m()}});if(J0)M(k,(m)=>{if(J0=!1,m)P(k,m);Y0(m)}),k.on("readable",function(){if(K0){let m=K0;K0=null,m()}}),k.on("end",function(){d.push(null)}),d._read=function(){while(!0){let m=k.read();if(m===null){K0=d._read;return}if(!d.push(m))return}};return d._destroy=function(m,W0){if(!m&&O!==null)m=new y;if(K0=null,O0=null,u=null,O===null)W0(m);else O=W0,P(s,m),P(k,m)},d}}),f2=S0(($,Q)=>{var{ObjectDefineProperties:J,ObjectGetOwnPropertyDescriptor:q,ObjectKeys:X,ObjectSetPrototypeOf:Y}=Z0();Q.exports=W;var G=K8(),B=A5();Y(W.prototype,G.prototype),Y(W,G);{let w=X(B.prototype);for(let M=0;M<w.length;M++){let y=w[M];if(!W.prototype[y])W.prototype[y]=B.prototype[y]}}function W(w){if(!(this instanceof W))return new W(w);if(G.call(this,w),B.call(this,w),w){if(this.allowHalfOpen=w.allowHalfOpen!==!1,w.readable===!1)this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0;if(w.writable===!1)this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0}else this.allowHalfOpen=!0}J(W.prototype,{writable:{__proto__:null,...q(B.prototype,"writable")},writableHighWaterMark:{__proto__:null,...q(B.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...q(B.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...q(B.prototype,"writableBuffer")},writableLength:{__proto__:null,...q(B.prototype,"writableLength")},writableFinished:{__proto__:null,...q(B.prototype,"writableFinished")},writableCorked:{__proto__:null,...q(B.prototype,"writableCorked")},writableEnded:{__proto__:null,...q(B.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...q(B.prototype,"writableNeedDrain")},destroyed:{__proto__:null,get(){if(this._readableState===void 0||this._writableState===void 0)return!1;return this._readableState.destroyed&&this._writableState.destroyed},set(w){if(this._readableState&&this._writableState)this._readableState.destroyed=w,this._writableState.destroyed=w}}});var U;function V(){if(U===void 0)U={};return U}W.fromWeb=function(w,M){return V().newStreamDuplexFromReadableWritablePair(w,M)},W.toWeb=function(w){return V().newReadableWritablePairFromDuplex(w)};var L;W.from=function(w){if(!L)L=GX();return L(w,"body")}}),a7=S0(($,Q)=>{var{ObjectSetPrototypeOf:J,Symbol:q}=Z0();Q.exports=W;var{ERR_METHOD_NOT_IMPLEMENTED:X}=d0().codes,Y=f2(),{getHighWaterMark:G}=V8();J(W.prototype,Y.prototype),J(W,Y);var B=q("kCallback");function W(L){if(!(this instanceof W))return new W(L);let w=L?G(this,L,"readableHighWaterMark",!0):null;if(w===0)L={...L,highWaterMark:null,readableHighWaterMark:w,writableHighWaterMark:L.writableHighWaterMark||0};if(Y.call(this,L),this._readableState.sync=!1,this[B]=null,L){if(typeof L.transform==="function")this._transform=L.transform;if(typeof L.flush==="function")this._flush=L.flush}this.on("prefinish",V)}function U(L){if(typeof this._flush==="function"&&!this.destroyed)this._flush((w,M)=>{if(w){if(L)L(w);else this.destroy(w);return}if(M!=null)this.push(M);if(this.push(null),L)L()});else if(this.push(null),L)L()}function V(){if(this._final!==U)U.call(this)}W.prototype._final=U,W.prototype._transform=function(L,w,M){throw new X("_transform()")},W.prototype._write=function(L,w,M){let y=this._readableState,x=this._writableState,A=y.length;this._transform(L,w,(P,K)=>{if(P){M(P);return}if(K!=null)this.push(K);if(x.ended||A===y.length||y.length<y.highWaterMark)M();else this[B]=M})},W.prototype._read=function(){if(this[B]){let L=this[B];this[B]=null,L()}}}),s7=S0(($,Q)=>{var{ObjectSetPrototypeOf:J}=Z0();Q.exports=X;var q=a7();J(X.prototype,q.prototype),J(X,q);function X(Y){if(!(this instanceof X))return new X(Y);q.call(this,Y)}X.prototype._transform=function(Y,G,B){B(null,Y)}}),D5=S0(($,Q)=>{var J=L1(),{ArrayIsArray:q,Promise:X,SymbolAsyncIterator:Y,SymbolDispose:G}=Z0(),B=n2(),{once:W}=r0(),U=b1(),V=f2(),{aggregateTwoErrors:L,codes:{ERR_INVALID_ARG_TYPE:w,ERR_INVALID_RETURN_VALUE:M,ERR_MISSING_ARGS:y,ERR_STREAM_DESTROYED:x,ERR_STREAM_PREMATURE_CLOSE:A},AbortError:P}=d0(),{validateFunction:K,validateAbortSignal:F}=S6(),{isIterable:z,isReadable:D,isReadableNodeStream:_,isNodeStream:T,isTransformStream:l,isWebStream:S,isReadableStream:E,isReadableFinished:C}=y2(),N=globalThis.AbortController||I6().AbortController,Z,f,k;function s(m,W0,M0){let C0=!1;m.on("close",()=>{C0=!0});let N0=B(m,{readable:W0,writable:M0},(c)=>{C0=!c});return{destroy:(c)=>{if(C0)return;C0=!0,U.destroyer(m,c||new x("pipe"))},cleanup:N0}}function J0(m){return K(m[m.length-1],"streams[stream.length - 1]"),m.pop()}function B0(m){if(z(m))return m;else if(_(m))return O0(m);throw new w("val",["Readable","Iterable","AsyncIterable"],m)}async function*O0(m){if(!f)f=K8();yield*f.prototype[Y].call(m)}async function u(m,W0,M0,{end:C0}){let N0,c=null,p=(z0)=>{if(z0)N0=z0;if(c){let R=c;c=null,R()}},t=()=>new X((z0,R)=>{if(N0)R(N0);else c=()=>{if(N0)R(N0);else z0()}});W0.on("drain",p);let L0=B(W0,{readable:!1},p);try{if(W0.writableNeedDrain)await t();for await(let z0 of m)if(!W0.write(z0))await t();if(C0)W0.end(),await t();M0()}catch(z0){M0(N0!==z0?L(N0,z0):z0)}finally{L0(),W0.off("drain",p)}}async function K0(m,W0,M0,{end:C0}){if(l(W0))W0=W0.writable;let N0=W0.getWriter();try{for await(let c of m)await N0.ready,N0.write(c).catch(()=>{});if(await N0.ready,C0)await N0.close();M0()}catch(c){try{await N0.abort(c),M0(c)}catch(p){M0(p)}}}function O(...m){return d(m,W(J0(m)))}function d(m,W0,M0){if(m.length===1&&q(m[0]))m=m[0];if(m.length<2)throw new y("streams");let C0=new N,N0=C0.signal,c=M0===null||M0===void 0?void 0:M0.signal,p=[];F(c,"options.signal");function t(){Q0(new P)}k=k||r0().addAbortListener;let L0;if(c)L0=k(c,t);let z0,R,v=[],h=0;function a(n){Q0(n,--h===0)}function Q0(n,H0){var E0;if(n&&(!z0||z0.code==="ERR_STREAM_PREMATURE_CLOSE"))z0=n;if(!z0&&!H0)return;while(v.length)v.shift()(z0);if((E0=L0)===null||E0===void 0||E0[G](),C0.abort(),H0){if(!z0)p.forEach(($2)=>$2());J.nextTick(W0,z0,R)}}let e;for(let n=0;n<m.length;n++){let H0=m[n],E0=n<m.length-1,$2=n>0,Q2=E0||(M0===null||M0===void 0?void 0:M0.end)!==!1,V1=n===m.length-1;if(T(H0)){let u0=function(n0){if(n0&&n0.name!=="AbortError"&&n0.code!=="ERR_STREAM_PREMATURE_CLOSE")a(n0)};var I=u0;if(Q2){let{destroy:n0,cleanup:x1}=s(H0,E0,$2);if(v.push(n0),D(H0)&&V1)p.push(x1)}if(H0.on("error",u0),D(H0)&&V1)p.push(()=>{H0.removeListener("error",u0)})}if(n===0)if(typeof H0==="function"){if(e=H0({signal:N0}),!z(e))throw new M("Iterable, AsyncIterable or Stream","source",e)}else if(z(H0)||_(H0)||l(H0))e=H0;else e=V.from(H0);else if(typeof H0==="function"){if(l(e)){var i;e=B0((i=e)===null||i===void 0?void 0:i.readable)}else e=B0(e);if(e=H0(e,{signal:N0}),E0){if(!z(e,!0))throw new M("AsyncIterable",`transform[${n-1}]`,e)}else{var q0;if(!Z)Z=s7();let u0=new Z({objectMode:!0}),n0=(q0=e)===null||q0===void 0?void 0:q0.then;if(typeof n0==="function")h++,n0.call(e,(L2)=>{if(R=L2,L2!=null)u0.write(L2);if(Q2)u0.end();J.nextTick(a)},(L2)=>{u0.destroy(L2),J.nextTick(a,L2)});else if(z(e,!0))h++,u(e,u0,a,{end:Q2});else if(E(e)||l(e)){let L2=e.readable||e;h++,u(L2,u0,a,{end:Q2})}else throw new M("AsyncIterable or Promise","destination",e);e=u0;let{destroy:x1,cleanup:f1}=s(e,!1,!0);if(v.push(x1),V1)p.push(f1)}}else if(T(H0)){if(_(e)){h+=2;let u0=Y0(e,H0,a,{end:Q2});if(D(H0)&&V1)p.push(u0)}else if(l(e)||E(e)){let u0=e.readable||e;h++,u(u0,H0,a,{end:Q2})}else if(z(e))h++,u(e,H0,a,{end:Q2});else throw new w("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],e);e=H0}else if(S(H0)){if(_(e))h++,K0(B0(e),H0,a,{end:Q2});else if(E(e)||z(e))h++,K0(e,H0,a,{end:Q2});else if(l(e))h++,K0(e.readable,H0,a,{end:Q2});else throw new w("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],e);e=H0}else e=V.from(H0)}if(N0!==null&&N0!==void 0&&N0.aborted||c!==null&&c!==void 0&&c.aborted)J.nextTick(t);return e}function Y0(m,W0,M0,{end:C0}){let N0=!1;if(W0.on("close",()=>{if(!N0)M0(new A)}),m.pipe(W0,{end:!1}),C0){let p=function(){N0=!0,W0.end()};var c=p;if(C(m))J.nextTick(p);else m.once("end",p)}else M0();return B(m,{readable:!0,writable:!1},(p)=>{let t=m._readableState;if(p&&p.code==="ERR_STREAM_PREMATURE_CLOSE"&&t&&t.ended&&!t.errored&&!t.errorEmitted)m.once("end",M0).once("error",M0);else M0(p)}),B(W0,{readable:!1,writable:!0},M0)}Q.exports={pipelineImpl:d,pipeline:O}}),t7=S0(($,Q)=>{var{pipeline:J}=D5(),q=f2(),{destroyer:X}=b1(),{isNodeStream:Y,isReadable:G,isWritable:B,isWebStream:W,isTransformStream:U,isWritableStream:V,isReadableStream:L}=y2(),{AbortError:w,codes:{ERR_INVALID_ARG_VALUE:M,ERR_MISSING_ARGS:y}}=d0(),x=n2();Q.exports=function(...A){if(A.length===0)throw new y("streams");if(A.length===1)return q.from(A[0]);let P=[...A];if(typeof A[0]==="function")A[0]=q.from(A[0]);if(typeof A[A.length-1]==="function"){let N=A.length-1;A[N]=q.from(A[N])}for(let N=0;N<A.length;++N){if(!Y(A[N])&&!W(A[N]))continue;if(N<A.length-1&&!(G(A[N])||L(A[N])||U(A[N])))throw new M(`streams[${N}]`,P[N],"must be readable");if(N>0&&!(B(A[N])||V(A[N])||U(A[N])))throw new M(`streams[${N}]`,P[N],"must be writable")}let K,F,z,D,_;function T(N){let Z=D;if(D=null,Z)Z(N);else if(N)_.destroy(N);else if(!C&&!E)_.destroy()}let l=A[0],S=J(A,T),E=!!(B(l)||V(l)||U(l)),C=!!(G(S)||L(S)||U(S));if(_=new q({writableObjectMode:!!(l!==null&&l!==void 0&&l.writableObjectMode),readableObjectMode:!!(S!==null&&S!==void 0&&S.readableObjectMode),writable:E,readable:C}),E){if(Y(l))_._write=function(Z,f,k){if(l.write(Z,f))k();else K=k},_._final=function(Z){l.end(),F=Z},l.on("drain",function(){if(K){let Z=K;K=null,Z()}});else if(W(l)){let Z=(U(l)?l.writable:l).getWriter();_._write=async function(f,k,s){try{await Z.ready,Z.write(f).catch(()=>{}),s()}catch(J0){s(J0)}},_._final=async function(f){try{await Z.ready,Z.close().catch(()=>{}),F=f}catch(k){f(k)}}}let N=U(S)?S.readable:S;x(N,()=>{if(F){let Z=F;F=null,Z()}})}if(C){if(Y(S))S.on("readable",function(){if(z){let N=z;z=null,N()}}),S.on("end",function(){_.push(null)}),_._read=function(){while(!0){let N=S.read();if(N===null){z=_._read;return}if(!_.push(N))return}};else if(W(S)){let N=(U(S)?S.readable:S).getReader();_._read=async function(){while(!0)try{let{value:Z,done:f}=await N.read();if(!_.push(Z))return;if(f){_.push(null);return}}catch{return}}}}return _._destroy=function(N,Z){if(!N&&D!==null)N=new w;if(z=null,K=null,F=null,D===null)Z(N);else if(D=Z,Y(S))X(S,N)},_}}),BX=S0(($,Q)=>{var J=globalThis.AbortController||I6().AbortController,{codes:{ERR_INVALID_ARG_VALUE:q,ERR_INVALID_ARG_TYPE:X,ERR_MISSING_ARGS:Y,ERR_OUT_OF_RANGE:G},AbortError:B}=d0(),{validateAbortSignal:W,validateInteger:U,validateObject:V}=S6(),L=Z0().Symbol("kWeak"),w=Z0().Symbol("kResistStopPropagation"),{finished:M}=n2(),y=t7(),{addAbortSignalNoValidate:x}=W8(),{isWritable:A,isNodeStream:P}=y2(),{deprecate:K}=r0(),{ArrayPrototypePush:F,Boolean:z,MathFloor:D,Number:_,NumberIsNaN:T,Promise:l,PromiseReject:S,PromiseResolve:E,PromisePrototypeThen:C,Symbol:N}=Z0(),Z=N("kEmpty"),f=N("kEof");function k(c,p){if(p!=null)V(p,"options");if((p===null||p===void 0?void 0:p.signal)!=null)W(p.signal,"options.signal");if(P(c)&&!A(c))throw new q("stream",c,"must be writable");let t=y(this,c);if(p!==null&&p!==void 0&&p.signal)x(p.signal,t);return t}function s(c,p){if(typeof c!=="function")throw new X("fn",["Function","AsyncFunction"],c);if(p!=null)V(p,"options");if((p===null||p===void 0?void 0:p.signal)!=null)W(p.signal,"options.signal");let t=1;if((p===null||p===void 0?void 0:p.concurrency)!=null)t=D(p.concurrency);let L0=t-1;if((p===null||p===void 0?void 0:p.highWaterMark)!=null)L0=D(p.highWaterMark);return U(t,"options.concurrency",1),U(L0,"options.highWaterMark",0),L0+=t,async function*(){let z0=r0().AbortSignalAny([p===null||p===void 0?void 0:p.signal].filter(z)),R=this,v=[],h={signal:z0},a,Q0,e=!1,I=0;function i(){e=!0,q0()}function q0(){I-=1,n()}function n(){if(Q0&&!e&&I<t&&v.length<L0)Q0(),Q0=null}async function H0(){try{for await(let E0 of R){if(e)return;if(z0.aborted)throw new B;try{if(E0=c(E0,h),E0===Z)continue;E0=E(E0)}catch($2){E0=S($2)}if(I+=1,C(E0,q0,i),v.push(E0),a)a(),a=null;if(!e&&(v.length>=L0||I>=t))await new l(($2)=>{Q0=$2})}v.push(f)}catch(E0){let $2=S(E0);C($2,q0,i),v.push($2)}finally{if(e=!0,a)a(),a=null}}H0();try{while(!0){while(v.length>0){let E0=await v[0];if(E0===f)return;if(z0.aborted)throw new B;if(E0!==Z)yield E0;v.shift(),n()}await new l((E0)=>{a=E0})}}finally{if(e=!0,Q0)Q0(),Q0=null}}.call(this)}function J0(c=void 0){if(c!=null)V(c,"options");if((c===null||c===void 0?void 0:c.signal)!=null)W(c.signal,"options.signal");return async function*(){let p=0;for await(let L0 of this){var t;if(c!==null&&c!==void 0&&(t=c.signal)!==null&&t!==void 0&&t.aborted)throw new B({cause:c.signal.reason});yield[p++,L0]}}.call(this)}async function B0(c,p=void 0){for await(let t of O.call(this,c,p))return!0;return!1}async function O0(c,p=void 0){if(typeof c!=="function")throw new X("fn",["Function","AsyncFunction"],c);return!await B0.call(this,async(...t)=>{return!await c(...t)},p)}async function u(c,p){for await(let t of O.call(this,c,p))return t;return}async function K0(c,p){if(typeof c!=="function")throw new X("fn",["Function","AsyncFunction"],c);async function t(L0,z0){return await c(L0,z0),Z}for await(let L0 of s.call(this,t,p));}function O(c,p){if(typeof c!=="function")throw new X("fn",["Function","AsyncFunction"],c);async function t(L0,z0){if(await c(L0,z0))return L0;return Z}return s.call(this,t,p)}class d extends Y{constructor(){super("reduce");this.message="Reduce of an empty stream requires an initial value"}}async function Y0(c,p,t){var L0;if(typeof c!=="function")throw new X("reducer",["Function","AsyncFunction"],c);if(t!=null)V(t,"options");if((t===null||t===void 0?void 0:t.signal)!=null)W(t.signal,"options.signal");let z0=arguments.length>1;if(t!==null&&t!==void 0&&(L0=t.signal)!==null&&L0!==void 0&&L0.aborted){let Q0=new B(void 0,{cause:t.signal.reason});throw this.once("error",()=>{}),await M(this.destroy(Q0)),Q0}let R=new J,v=R.signal;if(t!==null&&t!==void 0&&t.signal){let Q0={once:!0,[L]:this,[w]:!0};t.signal.addEventListener("abort",()=>R.abort(),Q0)}let h=!1;try{for await(let Q0 of this){var a;if(h=!0,t!==null&&t!==void 0&&(a=t.signal)!==null&&a!==void 0&&a.aborted)throw new B;if(!z0)p=Q0,z0=!0;else p=await c(p,Q0,{signal:v})}if(!h&&!z0)throw new d}finally{R.abort()}return p}async function m(c){if(c!=null)V(c,"options");if((c===null||c===void 0?void 0:c.signal)!=null)W(c.signal,"options.signal");let p=[];for await(let L0 of this){var t;if(c!==null&&c!==void 0&&(t=c.signal)!==null&&t!==void 0&&t.aborted)throw new B(void 0,{cause:c.signal.reason});F(p,L0)}return p}function W0(c,p){let t=s.call(this,c,p);return async function*(){for await(let L0 of t)yield*L0}.call(this)}function M0(c){if(c=_(c),T(c))return 0;if(c<0)throw new G("number",">= 0",c);return c}function C0(c,p=void 0){if(p!=null)V(p,"options");if((p===null||p===void 0?void 0:p.signal)!=null)W(p.signal,"options.signal");return c=M0(c),async function*(){var t;if(p!==null&&p!==void 0&&(t=p.signal)!==null&&t!==void 0&&t.aborted)throw new B;for await(let z0 of this){var L0;if(p!==null&&p!==void 0&&(L0=p.signal)!==null&&L0!==void 0&&L0.aborted)throw new B;if(c--<=0)yield z0}}.call(this)}function N0(c,p=void 0){if(p!=null)V(p,"options");if((p===null||p===void 0?void 0:p.signal)!=null)W(p.signal,"options.signal");return c=M0(c),async function*(){var t;if(p!==null&&p!==void 0&&(t=p.signal)!==null&&t!==void 0&&t.aborted)throw new B;for await(let z0 of this){var L0;if(p!==null&&p!==void 0&&(L0=p.signal)!==null&&L0!==void 0&&L0.aborted)throw new B;if(c-- >0)yield z0;if(c<=0)return}}.call(this)}Q.exports.streamReturningOperators={asIndexedPairs:K(J0,"readable.asIndexedPairs will be removed in a future version."),drop:C0,filter:O,flatMap:W0,map:s,take:N0,compose:k},Q.exports.promiseReturningOperators={every:O0,forEach:K0,reduce:Y0,toArray:m,some:B0,find:u}}),e7=S0(($,Q)=>{var{ArrayPrototypePop:J,Promise:q}=Z0(),{isIterable:X,isNodeStream:Y,isWebStream:G}=y2(),{pipelineImpl:B}=D5(),{finished:W}=n2();$$();function U(...V){return new q((L,w)=>{let M,y,x=V[V.length-1];if(x&&typeof x==="object"&&!Y(x)&&!X(x)&&!G(x)){let A=J(V);M=A.signal,y=A.end}B(V,(A,P)=>{if(A)w(A);else L(P)},{signal:M,end:y})})}Q.exports={finished:W,pipeline:U}}),$$=S0(($,Q)=>{var{Buffer:J}=(x2(),q2(g2)),{ObjectDefineProperty:q,ObjectKeys:X,ReflectApply:Y}=Z0(),{promisify:{custom:G}}=r0(),{streamReturningOperators:B,promiseReturningOperators:W}=BX(),{codes:{ERR_ILLEGAL_CONSTRUCTOR:U}}=d0(),V=t7(),{setDefaultHighWaterMark:L,getDefaultHighWaterMark:w}=V8(),{pipeline:M}=D5(),{destroyer:y}=b1(),x=n2(),A=e7(),P=y2(),K=Q.exports=N5().Stream;K.isDestroyed=P.isDestroyed,K.isDisturbed=P.isDisturbed,K.isErrored=P.isErrored,K.isReadable=P.isReadable,K.isWritable=P.isWritable,K.Readable=K8();for(let z of X(B)){let D=function(...T){if(new.target)throw U();return K.Readable.from(Y(_,this,T))},_=B[z];q(D,"name",{__proto__:null,value:_.name}),q(D,"length",{__proto__:null,value:_.length}),q(K.Readable.prototype,z,{__proto__:null,value:D,enumerable:!1,configurable:!0,writable:!0})}for(let z of X(W)){let D=function(...T){if(new.target)throw U();return Y(_,this,T)},_=W[z];q(D,"name",{__proto__:null,value:_.name}),q(D,"length",{__proto__:null,value:_.length}),q(K.Readable.prototype,z,{__proto__:null,value:D,enumerable:!1,configurable:!0,writable:!0})}K.Writable=A5(),K.Duplex=f2(),K.Transform=a7(),K.PassThrough=s7(),K.pipeline=M;var{addAbortSignal:F}=W8();K.addAbortSignal=F,K.finished=x,K.destroy=y,K.compose=V,K.setDefaultHighWaterMark=L,K.getDefaultHighWaterMark=w,q(K,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return A}}),q(M,G,{__proto__:null,enumerable:!0,get(){return A.pipeline}}),q(x,G,{__proto__:null,enumerable:!0,get(){return A.finished}}),K.Stream=K,K._isUint8Array=function(z){return z instanceof Uint8Array},K._uint8ArrayToBuffer=function(z){return J.from(z.buffer,z.byteOffset,z.byteLength)}}),UX=S0(($,Q)=>{var J=H8();{let q=$$(),X=e7(),Y=q.Readable.destroy;Q.exports=q.Readable,Q.exports._uint8ArrayToBuffer=q._uint8ArrayToBuffer,Q.exports._isUint8Array=q._isUint8Array,Q.exports.isDisturbed=q.isDisturbed,Q.exports.isErrored=q.isErrored,Q.exports.isReadable=q.isReadable,Q.exports.Readable=q.Readable,Q.exports.Writable=q.Writable,Q.exports.Duplex=q.Duplex,Q.exports.Transform=q.Transform,Q.exports.PassThrough=q.PassThrough,Q.exports.addAbortSignal=q.addAbortSignal,Q.exports.finished=q.finished,Q.exports.destroy=q.destroy,Q.exports.destroy=Y,Q.exports.pipeline=q.pipeline,Q.exports.compose=q.compose,Object.defineProperty(q,"promises",{configurable:!0,enumerable:!0,get(){return X}}),Q.exports.Stream=q.Stream}Q.exports.default=Q.exports});Q$.exports=UX()});var _2=j0((VX)=>{VX.base64=!0;VX.array=!0;VX.string=!0;VX.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u";VX.nodebuffer=typeof Buffer<"u";VX.uint8array=typeof Uint8Array<"u";if(typeof ArrayBuffer>"u")VX.blob=!1;else{j8=new ArrayBuffer(0);try{VX.blob=new Blob([j8],{type:"application/zip"}).size===0}catch($){try{C5=self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder,M8=new C5,M8.append(j8),VX.blob=M8.getBlob("application/zip").size===0}catch(Q){VX.blob=!1}}}var j8,C5,M8;try{VX.nodestream=!!H8().Readable}catch($){VX.nodestream=!1}});var R5=j0((OX)=>{var LX=g0(),zX=_2(),N2="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";OX.encode=function($){var Q=[],J,q,X,Y,G,B,W,U=0,V=$.length,L=V,w=LX.getTypeOf($)!=="string";while(U<$.length){if(L=V-U,!w)J=$.charCodeAt(U++),q=U<V?$.charCodeAt(U++):0,X=U<V?$.charCodeAt(U++):0;else J=$[U++],q=U<V?$[U++]:0,X=U<V?$[U++]:0;Y=J>>2,G=(J&3)<<4|q>>4,B=L>1?(q&15)<<2|X>>6:64,W=L>2?X&63:64,Q.push(N2.charAt(Y)+N2.charAt(G)+N2.charAt(B)+N2.charAt(W))}return Q.join("")};OX.decode=function($){var Q,J,q,X,Y,G,B,W=0,U=0,V="data:";if($.substr(0,V.length)===V)throw Error("Invalid base64 input, it looks like a data url.");$=$.replace(/[^A-Za-z0-9+/=]/g,"");var L=$.length*3/4;if($.charAt($.length-1)===N2.charAt(64))L--;if($.charAt($.length-2)===N2.charAt(64))L--;if(L%1!==0)throw Error("Invalid base64 input, bad content length.");var w;if(zX.uint8array)w=new Uint8Array(L|0);else w=Array(L|0);while(W<$.length){if(X=N2.indexOf($.charAt(W++)),Y=N2.indexOf($.charAt(W++)),G=N2.indexOf($.charAt(W++)),B=N2.indexOf($.charAt(W++)),Q=X<<2|Y>>4,J=(Y&15)<<4|G>>2,q=(G&3)<<6|B,w[U++]=Q,G!==64)w[U++]=J;if(B!==64)w[U++]=q}return w}});var E6=j0((eV,J$)=>{J$.exports={isNode:typeof Buffer<"u",newBufferFrom:function($,Q){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from($,Q);else{if(typeof $==="number")throw Error('The "data" argument must not be a number');return new Buffer($,Q)}},allocBuffer:function($){if(Buffer.alloc)return Buffer.alloc($);else{var Q=new Buffer($);return Q.fill(0),Q}},isBuffer:function($){return Buffer.isBuffer($)},isStream:function($){return $&&typeof $.on==="function"&&typeof $.pause==="function"&&typeof $.resume==="function"}}});var Y$=j0(($K,X$)=>{var q$=global.MutationObserver||global.WebKitMutationObserver,v6;if(q$)F8=0,I5=new q$(w8),L8=global.document.createTextNode(""),I5.observe(L8,{characterData:!0}),v6=function(){L8.data=F8=++F8%2};else if(!global.setImmediate&&typeof global.MessageChannel<"u")z8=new global.MessageChannel,z8.port1.onmessage=w8,v6=function(){z8.port2.postMessage(0)};else if("document"in global&&"onreadystatechange"in global.document.createElement("script"))v6=function(){var $=global.document.createElement("script");$.onreadystatechange=function(){w8(),$.onreadystatechange=null,$.parentNode.removeChild($),$=null},global.document.documentElement.appendChild($)};else v6=function(){setTimeout(w8,0)};var F8,I5,L8,z8,S5,k6=[];function w8(){S5=!0;var $,Q,J=k6.length;while(J){Q=k6,k6=[],$=-1;while(++$<J)Q[$]();J=k6.length}S5=!1}X$.exports=DX;function DX($){if(k6.push($)===1&&!S5)v6()}});var K$=j0((QK,V$)=>{var PX=Y$();function h1(){}var p0={},G$=["REJECTED"],E5=["FULFILLED"],B$=["PENDING"];V$.exports=o2;function o2($){if(typeof $!=="function")throw TypeError("resolver must be a function");if(this.state=B$,this.queue=[],this.outcome=void 0,$!==h1)U$(this,$)}o2.prototype.finally=function($){if(typeof $!=="function")return this;var Q=this.constructor;return this.then(J,q);function J(X){function Y(){return X}return Q.resolve($()).then(Y)}function q(X){function Y(){throw X}return Q.resolve($()).then(Y)}};o2.prototype.catch=function($){return this.then(null,$)};o2.prototype.then=function($,Q){if(typeof $!=="function"&&this.state===E5||typeof Q!=="function"&&this.state===G$)return this;var J=new this.constructor(h1);if(this.state!==B$){var q=this.state===E5?$:Q;v5(J,q,this.outcome)}else this.queue.push(new T6(J,$,Q));return J};function T6($,Q,J){if(this.promise=$,typeof Q==="function")this.onFulfilled=Q,this.callFulfilled=this.otherCallFulfilled;if(typeof J==="function")this.onRejected=J,this.callRejected=this.otherCallRejected}T6.prototype.callFulfilled=function($){p0.resolve(this.promise,$)};T6.prototype.otherCallFulfilled=function($){v5(this.promise,this.onFulfilled,$)};T6.prototype.callRejected=function($){p0.reject(this.promise,$)};T6.prototype.otherCallRejected=function($){v5(this.promise,this.onRejected,$)};function v5($,Q,J){PX(function(){var q;try{q=Q(J)}catch(X){return p0.reject($,X)}if(q===$)p0.reject($,TypeError("Cannot resolve promise with itself"));else p0.resolve($,q)})}p0.resolve=function($,Q){var J=W$(CX,Q);if(J.status==="error")return p0.reject($,J.value);var q=J.value;if(q)U$($,q);else{$.state=E5,$.outcome=Q;var X=-1,Y=$.queue.length;while(++X<Y)$.queue[X].callFulfilled(Q)}return $};p0.reject=function($,Q){$.state=G$,$.outcome=Q;var J=-1,q=$.queue.length;while(++J<q)$.queue[J].callRejected(Q);return $};function CX($){var Q=$&&$.then;if($&&(typeof $==="object"||typeof $==="function")&&typeof Q==="function")return function(){Q.apply($,arguments)}}function U$($,Q){var J=!1;function q(B){if(J)return;J=!0,p0.reject($,B)}function X(B){if(J)return;J=!0,p0.resolve($,B)}function Y(){Q(X,q)}var G=W$(Y);if(G.status==="error")q(G.value)}function W$($,Q){var J={};try{J.value=$(Q),J.status="success"}catch(q){J.status="error",J.value=q}return J}o2.resolve=RX;function RX($){if($ instanceof this)return $;return p0.resolve(new this(h1),$)}o2.reject=IX;function IX($){var Q=new this(h1);return p0.reject(Q,$)}o2.all=SX;function SX($){var Q=this;if(Object.prototype.toString.call($)!=="[object Array]")return this.reject(TypeError("must be an array"));var J=$.length,q=!1;if(!J)return this.resolve([]);var X=Array(J),Y=0,G=-1,B=new this(h1);while(++G<J)W($[G],G);return B;function W(U,V){Q.resolve(U).then(L,function(w){if(!q)q=!0,p0.reject(B,w)});function L(w){if(X[V]=w,++Y===J&&!q)q=!0,p0.resolve(B,X)}}}o2.race=EX;function EX($){var Q=this;if(Object.prototype.toString.call($)!=="[object Array]")return this.reject(TypeError("must be an array"));var J=$.length,q=!1;if(!J)return this.resolve([]);var X=-1,Y=new this(h1);while(++X<J)G($[X]);return Y;function G(B){Q.resolve(B).then(function(W){if(!q)q=!0,p0.resolve(Y,W)},function(W){if(!q)q=!0,p0.reject(Y,W)})}}});var m1=j0((JK,H$)=>{var k5=null;if(typeof Promise<"u")k5=Promise;else k5=K$();H$.exports={Promise:k5}});var M$=j0((j$)=>{(function($,Q){if($.setImmediate)return;var J=1,q={},X=!1,Y=$.document,G;function B(K){if(typeof K!=="function")K=Function(""+K);var F=Array(arguments.length-1);for(var z=0;z<F.length;z++)F[z]=arguments[z+1];var D={callback:K,args:F};return q[J]=D,G(J),J++}function W(K){delete q[K]}function U(K){var{callback:F,args:z}=K;switch(z.length){case 0:F();break;case 1:F(z[0]);break;case 2:F(z[0],z[1]);break;case 3:F(z[0],z[1],z[2]);break;default:F.apply(Q,z);break}}function V(K){if(X)setTimeout(V,0,K);else{var F=q[K];if(F){X=!0;try{U(F)}finally{W(K),X=!1}}}}function L(){G=function(K){process.nextTick(function(){V(K)})}}function w(){if($.postMessage&&!$.importScripts){var K=!0,F=$.onmessage;return $.onmessage=function(){K=!1},$.postMessage("","*"),$.onmessage=F,K}}function M(){var K="setImmediate$"+Math.random()+"$",F=function(z){if(z.source===$&&typeof z.data==="string"&&z.data.indexOf(K)===0)V(+z.data.slice(K.length))};if($.addEventListener)$.addEventListener("message",F,!1);else $.attachEvent("onmessage",F);G=function(z){$.postMessage(K+z,"*")}}function y(){var K=new MessageChannel;K.port1.onmessage=function(F){var z=F.data;V(z)},G=function(F){K.port2.postMessage(F)}}function x(){var K=Y.documentElement;G=function(F){var z=Y.createElement("script");z.onreadystatechange=function(){V(F),z.onreadystatechange=null,K.removeChild(z),z=null},K.appendChild(z)}}function A(){G=function(K){setTimeout(V,0,K)}}var P=Object.getPrototypeOf&&Object.getPrototypeOf($);if(P=P&&P.setTimeout?P:$,{}.toString.call($.process)==="[object process]")L();else if(w())M();else if($.MessageChannel)y();else if(Y&&"onreadystatechange"in Y.createElement("script"))x();else A();P.setImmediate=B,P.clearImmediate=W})(typeof self>"u"?typeof global>"u"?j$:global:self)});var g0=j0((TX)=>{var r2=_2(),vX=R5(),u1=E6(),T5=m1();M$();function kX($){var Q=null;if(r2.uint8array)Q=new Uint8Array($.length);else Q=Array($.length);return N8($,Q)}TX.newBlob=function($,Q){TX.checkSupport("blob");try{return new Blob([$],{type:Q})}catch(X){try{var J=self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder,q=new J;return q.append($),q.getBlob(Q)}catch(Y){throw Error("Bug : can't construct the Blob.")}}};function Z6($){return $}function N8($,Q){for(var J=0;J<$.length;++J)Q[J]=$.charCodeAt(J)&255;return Q}var O8={stringifyByChunk:function($,Q,J){var q=[],X=0,Y=$.length;if(Y<=J)return String.fromCharCode.apply(null,$);while(X<Y){if(Q==="array"||Q==="nodebuffer")q.push(String.fromCharCode.apply(null,$.slice(X,Math.min(X+J,Y))));else q.push(String.fromCharCode.apply(null,$.subarray(X,Math.min(X+J,Y))));X+=J}return q.join("")},stringifyByChar:function($){var Q="";for(var J=0;J<$.length;J++)Q+=String.fromCharCode($[J]);return Q},applyCanBeUsed:{uint8array:function(){try{return r2.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch($){return!1}}(),nodebuffer:function(){try{return r2.nodebuffer&&String.fromCharCode.apply(null,u1.allocBuffer(1)).length===1}catch($){return!1}}()}};function g6($){var Q=65536,J=TX.getTypeOf($),q=!0;if(J==="uint8array")q=O8.applyCanBeUsed.uint8array;else if(J==="nodebuffer")q=O8.applyCanBeUsed.nodebuffer;if(q)while(Q>1)try{return O8.stringifyByChunk($,J,Q)}catch(X){Q=Math.floor(Q/2)}return O8.stringifyByChar($)}TX.applyFromCharCode=g6;function A8($,Q){for(var J=0;J<$.length;J++)Q[J]=$[J];return Q}var a2={};a2.string={string:Z6,array:function($){return N8($,Array($.length))},arraybuffer:function($){return a2.string.uint8array($).buffer},uint8array:function($){return N8($,new Uint8Array($.length))},nodebuffer:function($){return N8($,u1.allocBuffer($.length))}};a2.array={string:g6,array:Z6,arraybuffer:function($){return new Uint8Array($).buffer},uint8array:function($){return new Uint8Array($)},nodebuffer:function($){return u1.newBufferFrom($)}};a2.arraybuffer={string:function($){return g6(new Uint8Array($))},array:function($){return A8(new Uint8Array($),Array($.byteLength))},arraybuffer:Z6,uint8array:function($){return new Uint8Array($)},nodebuffer:function($){return u1.newBufferFrom(new Uint8Array($))}};a2.uint8array={string:g6,array:function($){return A8($,Array($.length))},arraybuffer:function($){return $.buffer},uint8array:Z6,nodebuffer:function($){return u1.newBufferFrom($)}};a2.nodebuffer={string:g6,array:function($){return A8($,Array($.length))},arraybuffer:function($){return a2.nodebuffer.uint8array($).buffer},uint8array:function($){return A8($,new Uint8Array($.length))},nodebuffer:Z6};TX.transformTo=function($,Q){if(!Q)Q="";if(!$)return Q;TX.checkSupport($);var J=TX.getTypeOf(Q),q=a2[J][$](Q);return q};TX.resolve=function($){var Q=$.split("/"),J=[];for(var q=0;q<Q.length;q++){var X=Q[q];if(X==="."||X===""&&q!==0&&q!==Q.length-1)continue;else if(X==="..")J.pop();else J.push(X)}return J.join("/")};TX.getTypeOf=function($){if(typeof $==="string")return"string";if(Object.prototype.toString.call($)==="[object Array]")return"array";if(r2.nodebuffer&&u1.isBuffer($))return"nodebuffer";if(r2.uint8array&&$ instanceof Uint8Array)return"uint8array";if(r2.arraybuffer&&$ instanceof ArrayBuffer)return"arraybuffer"};TX.checkSupport=function($){var Q=r2[$.toLowerCase()];if(!Q)throw Error($+" is not supported by this platform")};TX.MAX_VALUE_16BITS=65535;TX.MAX_VALUE_32BITS=-1;TX.pretty=function($){var Q="",J,q;for(q=0;q<($||"").length;q++)J=$.charCodeAt(q),Q+="\\x"+(J<16?"0":"")+J.toString(16).toUpperCase();return Q};TX.delay=function($,Q,J){setImmediate(function(){$.apply(J||null,Q||[])})};TX.inherits=function($,Q){var J=function(){};J.prototype=Q.prototype,$.prototype=new J};TX.extend=function(){var $={},Q,J;for(Q=0;Q<arguments.length;Q++)for(J in arguments[Q])if(Object.prototype.hasOwnProperty.call(arguments[Q],J)&&typeof $[J]>"u")$[J]=arguments[Q][J];return $};TX.prepareContent=function($,Q,J,q,X){var Y=T5.Promise.resolve(Q).then(function(G){var B=r2.blob&&(G instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(G))!==-1);if(B&&typeof FileReader<"u")return new T5.Promise(function(W,U){var V=new FileReader;V.onload=function(L){W(L.target.result)},V.onerror=function(L){U(L.target.error)},V.readAsArrayBuffer(G)});else return G});return Y.then(function(G){var B=TX.getTypeOf(G);if(!B)return T5.Promise.reject(Error("Can't read the data of '"+$+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"));if(B==="arraybuffer")G=TX.transformTo("uint8array",G);else if(B==="string"){if(X)G=vX.decode(G);else if(J){if(q!==!0)G=kX(G)}}return G})}});var t0=j0((YK,z$)=>{function L$($){this.name=$||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}L$.prototype={push:function($){this.emit("data",$)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch($){this.emit("error",$)}return!0},error:function($){if(this.isFinished)return!1;if(this.isPaused)this.generatedError=$;else{if(this.isFinished=!0,this.emit("error",$),this.previous)this.previous.error($);this.cleanUp()}return!0},on:function($,Q){return this._listeners[$].push(Q),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function($,Q){if(this._listeners[$])for(var J=0;J<this._listeners[$].length;J++)this._listeners[$][J].call(this,Q)},pipe:function($){return $.registerPrevious(this)},registerPrevious:function($){if(this.isLocked)throw Error("The stream '"+this+"' has already been used.");this.streamInfo=$.streamInfo,this.mergeStreamInfo(),this.previous=$;var Q=this;return $.on("data",function(J){Q.processChunk(J)}),$.on("end",function(){Q.end()}),$.on("error",function(J){Q.error(J)}),this},pause:function(){if(this.isPaused||this.isFinished)return!1;if(this.isPaused=!0,this.previous)this.previous.pause();return!0},resume:function(){if(!this.isPaused||this.isFinished)return!1;this.isPaused=!1;var $=!1;if(this.generatedError)this.error(this.generatedError),$=!0;if(this.previous)this.previous.resume();return!$},flush:function(){},processChunk:function($){this.push($)},withStreamInfo:function($,Q){return this.extraStreamInfo[$]=Q,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var $ in this.extraStreamInfo){if(!Object.prototype.hasOwnProperty.call(this.extraStreamInfo,$))continue;this.streamInfo[$]=this.extraStreamInfo[$]}},lock:function(){if(this.isLocked)throw Error("The stream '"+this+"' has already been used.");if(this.isLocked=!0,this.previous)this.previous.lock()},toString:function(){var $="Worker "+this.name;if(this.previous)return this.previous+" -> "+$;else return $}};z$.exports=L$});var p1=j0((iX)=>{var c1=g0(),z1=_2(),cX=E6(),D8=t0(),x6=Array(256);for(A2=0;A2<256;A2++)x6[A2]=A2>=252?6:A2>=248?5:A2>=240?4:A2>=224?3:A2>=192?2:1;var A2;x6[254]=x6[254]=1;var pX=function($){var Q,J,q,X,Y,G=$.length,B=0;for(X=0;X<G;X++){if(J=$.charCodeAt(X),(J&64512)===55296&&X+1<G){if(q=$.charCodeAt(X+1),(q&64512)===56320)J=65536+(J-55296<<10)+(q-56320),X++}B+=J<128?1:J<2048?2:J<65536?3:4}if(z1.uint8array)Q=new Uint8Array(B);else Q=Array(B);for(Y=0,X=0;Y<B;X++){if(J=$.charCodeAt(X),(J&64512)===55296&&X+1<G){if(q=$.charCodeAt(X+1),(q&64512)===56320)J=65536+(J-55296<<10)+(q-56320),X++}if(J<128)Q[Y++]=J;else if(J<2048)Q[Y++]=192|J>>>6,Q[Y++]=128|J&63;else if(J<65536)Q[Y++]=224|J>>>12,Q[Y++]=128|J>>>6&63,Q[Y++]=128|J&63;else Q[Y++]=240|J>>>18,Q[Y++]=128|J>>>12&63,Q[Y++]=128|J>>>6&63,Q[Y++]=128|J&63}return Q},lX=function($,Q){var J;if(Q=Q||$.length,Q>$.length)Q=$.length;J=Q-1;while(J>=0&&($[J]&192)===128)J--;if(J<0)return Q;if(J===0)return Q;return J+x6[$[J]]>Q?J:Q},dX=function($){var Q,J,q,X,Y=$.length,G=Array(Y*2);for(J=0,Q=0;Q<Y;){if(q=$[Q++],q<128){G[J++]=q;continue}if(X=x6[q],X>4){G[J++]=65533,Q+=X-1;continue}q&=X===2?31:X===3?15:7;while(X>1&&Q<Y)q=q<<6|$[Q++]&63,X--;if(X>1){G[J++]=65533;continue}if(q<65536)G[J++]=q;else q-=65536,G[J++]=55296|q>>10&1023,G[J++]=56320|q&1023}if(G.length!==J)if(G.subarray)G=G.subarray(0,J);else G.length=J;return c1.applyFromCharCode(G)};iX.utf8encode=function(Q){if(z1.nodebuffer)return cX.newBufferFrom(Q,"utf-8");return pX(Q)};iX.utf8decode=function(Q){if(z1.nodebuffer)return c1.transformTo("nodebuffer",Q).toString("utf-8");return Q=c1.transformTo(z1.uint8array?"uint8array":"array",Q),dX(Q)};function P8(){D8.call(this,"utf-8 decode"),this.leftOver=null}c1.inherits(P8,D8);P8.prototype.processChunk=function($){var Q=c1.transformTo(z1.uint8array?"uint8array":"array",$.data);if(this.leftOver&&this.leftOver.length){if(z1.uint8array){var J=Q;Q=new Uint8Array(J.length+this.leftOver.length),Q.set(this.leftOver,0),Q.set(J,this.leftOver.length)}else Q=this.leftOver.concat(Q);this.leftOver=null}var q=lX(Q),X=Q;if(q!==Q.length)if(z1.uint8array)X=Q.subarray(0,q),this.leftOver=Q.subarray(q,Q.length);else X=Q.slice(0,q),this.leftOver=Q.slice(q,Q.length);this.push({data:iX.utf8decode(X),meta:$.meta})};P8.prototype.flush=function(){if(this.leftOver&&this.leftOver.length)this.push({data:iX.utf8decode(this.leftOver),meta:{}}),this.leftOver=null};iX.Utf8DecodeWorker=P8;function g5(){D8.call(this,"utf-8 encode")}c1.inherits(g5,D8);g5.prototype.processChunk=function($){this.push({data:iX.utf8encode($.data),meta:$.meta})};iX.Utf8EncodeWorker=g5});var P$=j0((BK,D$)=>{var N$=t0(),A$=g0();function f5($){N$.call(this,"ConvertWorker to "+$),this.destType=$}A$.inherits(f5,N$);f5.prototype.processChunk=function($){this.push({data:A$.transformTo(this.destType,$.data),meta:$.meta})};D$.exports=f5});var I$=j0((UK,R$)=>{var C$=H8().Readable,rX=g0();rX.inherits(y5,C$);function y5($,Q,J){C$.call(this,Q),this._helper=$;var q=this;$.on("data",function(X,Y){if(!q.push(X))q._helper.pause();if(J)J(Y)}).on("error",function(X){q.emit("error",X)}).on("end",function(){q.push(null)})}y5.prototype._read=function(){this._helper.resume()};R$.exports=y5});var _5=j0((WK,v$)=>{var O1=g0(),aX=P$(),sX=t0(),tX=R5(),eX=_2(),$Y=m1(),S$=null;if(eX.nodestream)try{S$=I$()}catch($){}function QY($,Q,J){switch($){case"blob":return O1.newBlob(O1.transformTo("arraybuffer",Q),J);case"base64":return tX.encode(Q);default:return O1.transformTo($,Q)}}function JY($,Q){var J,q=0,X=null,Y=0;for(J=0;J<Q.length;J++)Y+=Q[J].length;switch($){case"string":return Q.join("");case"array":return Array.prototype.concat.apply([],Q);case"uint8array":X=new Uint8Array(Y);for(J=0;J<Q.length;J++)X.set(Q[J],q),q+=Q[J].length;return X;case"nodebuffer":return Buffer.concat(Q);default:throw Error("concat : unsupported type '"+$+"'")}}function qY($,Q){return new $Y.Promise(function(J,q){var X=[],Y=$._internalType,G=$._outputType,B=$._mimeType;$.on("data",function(W,U){if(X.push(W),Q)Q(U)}).on("error",function(W){X=[],q(W)}).on("end",function(){try{var W=QY(G,JY(Y,X),B);J(W)}catch(U){q(U)}X=[]}).resume()})}function E$($,Q,J){var q=Q;switch(Q){case"blob":case"arraybuffer":q="uint8array";break;case"base64":q="string";break}try{this._internalType=q,this._outputType=Q,this._mimeType=J,O1.checkSupport(q),this._worker=$.pipe(new aX(q)),$.lock()}catch(X){this._worker=new sX("error"),this._worker.error(X)}}E$.prototype={accumulate:function($){return qY(this,$)},on:function($,Q){var J=this;if($==="data")this._worker.on($,function(q){Q.call(J,q.data,q.meta)});else this._worker.on($,function(){O1.delay(Q,arguments,J)});return this},resume:function(){return O1.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function($){if(O1.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw Error(this._outputType+" is not supported by this method");return new S$(this,{objectMode:this._outputType!=="nodebuffer"},$)}};v$.exports=E$});var b5=j0((XY)=>{XY.base64=!1;XY.binary=!1;XY.dir=!1;XY.createFolders=!0;XY.date=null;XY.compression=null;XY.compressionOptions=null;XY.comment=null;XY.unixPermissions=null;XY.dosPermissions=null});var h5=j0((KK,k$)=>{var C8=g0(),R8=t0(),wY=16384;function l1($){R8.call(this,"DataWorker");var Q=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,$.then(function(J){if(Q.dataIsReady=!0,Q.data=J,Q.max=J&&J.length||0,Q.type=C8.getTypeOf(J),!Q.isPaused)Q._tickAndRepeat()},function(J){Q.error(J)})}C8.inherits(l1,R8);l1.prototype.cleanUp=function(){R8.prototype.cleanUp.call(this),this.data=null};l1.prototype.resume=function(){if(!R8.prototype.resume.call(this))return!1;if(!this._tickScheduled&&this.dataIsReady)this._tickScheduled=!0,C8.delay(this._tickAndRepeat,[],this);return!0};l1.prototype._tickAndRepeat=function(){if(this._tickScheduled=!1,this.isPaused||this.isFinished)return;if(this._tick(),!this.isFinished)C8.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0};l1.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var $=wY,Q=null,J=Math.min(this.max,this.index+$);if(this.index>=this.max)return this.end();else{switch(this.type){case"string":Q=this.data.substring(this.index,J);break;case"uint8array":Q=this.data.subarray(this.index,J);break;case"array":case"nodebuffer":Q=this.data.slice(this.index,J);break}return this.index=J,this.push({data:Q,meta:{percent:this.max?this.index/this.max*100:0}})}};k$.exports=l1});var I8=j0((HK,Z$)=>{var FY=g0();function LY(){var $,Q=[];for(var J=0;J<256;J++){$=J;for(var q=0;q<8;q++)$=$&1?3988292384^$>>>1:$>>>1;Q[J]=$}return Q}var T$=LY();function zY($,Q,J,q){var X=T$,Y=q+J;$=$^-1;for(var G=q;G<Y;G++)$=$>>>8^X[($^Q[G])&255];return $^-1}function OY($,Q,J,q){var X=T$,Y=q+J;$=$^-1;for(var G=q;G<Y;G++)$=$>>>8^X[($^Q.charCodeAt(G))&255];return $^-1}Z$.exports=function(Q,J){if(typeof Q>"u"||!Q.length)return 0;var q=FY.getTypeOf(Q)!=="string";if(q)return zY(J|0,Q,Q.length,0);else return OY(J|0,Q,Q.length,0)}});var u5=j0((jK,x$)=>{var g$=t0(),NY=I8(),AY=g0();function m5(){g$.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}AY.inherits(m5,g$);m5.prototype.processChunk=function($){this.streamInfo.crc32=NY($.data,this.streamInfo.crc32||0),this.push($)};x$.exports=m5});var y$=j0((MK,f$)=>{var DY=g0(),c5=t0();function p5($){c5.call(this,"DataLengthProbe for "+$),this.propName=$,this.withStreamInfo($,0)}DY.inherits(p5,c5);p5.prototype.processChunk=function($){if($){var Q=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=Q+$.data.length}c5.prototype.processChunk.call(this,$)};f$.exports=p5});var S8=j0((wK,h$)=>{var _$=m1(),b$=h5(),PY=u5(),l5=y$();function d5($,Q,J,q,X){this.compressedSize=$,this.uncompressedSize=Q,this.crc32=J,this.compression=q,this.compressedContent=X}d5.prototype={getContentWorker:function(){var $=new b$(_$.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new l5("data_length")),Q=this;return $.on("end",function(){if(this.streamInfo.data_length!==Q.uncompressedSize)throw Error("Bug : uncompressed data size mismatch")}),$},getCompressedWorker:function(){return new b$(_$.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}};d5.createWorkerFrom=function($,Q,J){return $.pipe(new PY).pipe(new l5("uncompressedSize")).pipe(Q.compressWorker(J)).pipe(new l5("compressedSize")).withStreamInfo("compression",Q)};h$.exports=d5});var p$=j0((FK,c$)=>{var CY=_5(),RY=h5(),i5=p1(),n5=S8(),m$=t0(),o5=function($,Q,J){this.name=$,this.dir=J.dir,this.date=J.date,this.comment=J.comment,this.unixPermissions=J.unixPermissions,this.dosPermissions=J.dosPermissions,this._data=Q,this._dataBinary=J.binary,this.options={compression:J.compression,compressionOptions:J.compressionOptions}};o5.prototype={internalStream:function($){var Q=null,J="string";try{if(!$)throw Error("No output type specified.");J=$.toLowerCase();var q=J==="string"||J==="text";if(J==="binarystring"||J==="text")J="string";Q=this._decompressWorker();var X=!this._dataBinary;if(X&&!q)Q=Q.pipe(new i5.Utf8EncodeWorker);if(!X&&q)Q=Q.pipe(new i5.Utf8DecodeWorker)}catch(Y){Q=new m$("error"),Q.error(Y)}return new CY(Q,J,"")},async:function($,Q){return this.internalStream($).accumulate(Q)},nodeStream:function($,Q){return this.internalStream($||"nodebuffer").toNodejsStream(Q)},_compressWorker:function($,Q){if(this._data instanceof n5&&this._data.compression.magic===$.magic)return this._data.getCompressedWorker();else{var J=this._decompressWorker();if(!this._dataBinary)J=J.pipe(new i5.Utf8EncodeWorker);return n5.createWorkerFrom(J,$,Q)}},_decompressWorker:function(){if(this._data instanceof n5)return this._data.getContentWorker();else if(this._data instanceof m$)return this._data;else return new RY(this._data)}};var u$=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],IY=function(){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")};for(f6=0;f6<u$.length;f6++)o5.prototype[u$[f6]]=IY;var f6;c$.exports=o5});var b2=j0((r5)=>{var kY=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";function TY($,Q){return Object.prototype.hasOwnProperty.call($,Q)}r5.assign=function($){var Q=Array.prototype.slice.call(arguments,1);while(Q.length){var J=Q.shift();if(!J)continue;if(typeof J!=="object")throw TypeError(J+"must be non-object");for(var q in J)if(TY(J,q))$[q]=J[q]}return $};r5.shrinkBuf=function($,Q){if($.length===Q)return $;if($.subarray)return $.subarray(0,Q);return $.length=Q,$};var ZY={arraySet:function($,Q,J,q,X){if(Q.subarray&&$.subarray){$.set(Q.subarray(J,J+q),X);return}for(var Y=0;Y<q;Y++)$[X+Y]=Q[J+Y]},flattenChunks:function($){var Q,J,q,X,Y,G;q=0;for(Q=0,J=$.length;Q<J;Q++)q+=$[Q].length;G=new Uint8Array(q),X=0;for(Q=0,J=$.length;Q<J;Q++)Y=$[Q],G.set(Y,X),X+=Y.length;return G}},gY={arraySet:function($,Q,J,q,X){for(var Y=0;Y<q;Y++)$[X+Y]=Q[J+Y]},flattenChunks:function($){return[].concat.apply([],$)}};r5.setTyped=function($){if($)r5.Buf8=Uint8Array,r5.Buf16=Uint16Array,r5.Buf32=Int32Array,r5.assign(r5,ZY);else r5.Buf8=Array,r5.Buf16=Array,r5.Buf32=Array,r5.assign(r5,gY)};r5.setTyped(kY)});var j9=j0((JG)=>{var fY=b2(),yY=4,d$=0,i$=1,_Y=2;function i1($){var Q=$.length;while(--Q>=0)$[Q]=0}var bY=0,t$=1,hY=2,mY=3,uY=258,q4=29,u6=256,_6=u6+1+q4,d1=30,X4=19,e$=2*_6+1,N1=15,s5=16,cY=7,Y4=256,$9=16,Q9=17,J9=18,Q4=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],E8=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],pY=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],q9=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],lY=512,h2=Array((_6+2)*2);i1(h2);var y6=Array(d1*2);i1(y6);var b6=Array(lY);i1(b6);var h6=Array(uY-mY+1);i1(h6);var G4=Array(q4);i1(G4);var v8=Array(d1);i1(v8);function t5($,Q,J,q,X){this.static_tree=$,this.extra_bits=Q,this.extra_base=J,this.elems=q,this.max_length=X,this.has_stree=$&&$.length}var X9,Y9,G9;function e5($,Q){this.dyn_tree=$,this.max_code=0,this.stat_desc=Q}function B9($){return $<256?b6[$]:b6[256+($>>>7)]}function m6($,Q){$.pending_buf[$.pending++]=Q&255,$.pending_buf[$.pending++]=Q>>>8&255}function a0($,Q,J){if($.bi_valid>s5-J)$.bi_buf|=Q<<$.bi_valid&65535,m6($,$.bi_buf),$.bi_buf=Q>>s5-$.bi_valid,$.bi_valid+=J-s5;else $.bi_buf|=Q<<$.bi_valid&65535,$.bi_valid+=J}function D2($,Q,J){a0($,J[Q*2],J[Q*2+1])}function U9($,Q){var J=0;do J|=$&1,$>>>=1,J<<=1;while(--Q>0);return J>>>1}function dY($){if($.bi_valid===16)m6($,$.bi_buf),$.bi_buf=0,$.bi_valid=0;else if($.bi_valid>=8)$.pending_buf[$.pending++]=$.bi_buf&255,$.bi_buf>>=8,$.bi_valid-=8}function iY($,Q){var{dyn_tree:J,max_code:q}=Q,X=Q.stat_desc.static_tree,Y=Q.stat_desc.has_stree,G=Q.stat_desc.extra_bits,B=Q.stat_desc.extra_base,W=Q.stat_desc.max_length,U,V,L,w,M,y,x=0;for(w=0;w<=N1;w++)$.bl_count[w]=0;J[$.heap[$.heap_max]*2+1]=0;for(U=$.heap_max+1;U<e$;U++){if(V=$.heap[U],w=J[J[V*2+1]*2+1]+1,w>W)w=W,x++;if(J[V*2+1]=w,V>q)continue;if($.bl_count[w]++,M=0,V>=B)M=G[V-B];if(y=J[V*2],$.opt_len+=y*(w+M),Y)$.static_len+=y*(X[V*2+1]+M)}if(x===0)return;do{w=W-1;while($.bl_count[w]===0)w--;$.bl_count[w]--,$.bl_count[w+1]+=2,$.bl_count[W]--,x-=2}while(x>0);for(w=W;w!==0;w--){V=$.bl_count[w];while(V!==0){if(L=$.heap[--U],L>q)continue;if(J[L*2+1]!==w)$.opt_len+=(w-J[L*2+1])*J[L*2],J[L*2+1]=w;V--}}}function W9($,Q,J){var q=Array(N1+1),X=0,Y,G;for(Y=1;Y<=N1;Y++)q[Y]=X=X+J[Y-1]<<1;for(G=0;G<=Q;G++){var B=$[G*2+1];if(B===0)continue;$[G*2]=U9(q[B]++,B)}}function nY(){var $,Q,J,q,X,Y=Array(N1+1);J=0;for(q=0;q<q4-1;q++){G4[q]=J;for($=0;$<1<<Q4[q];$++)h6[J++]=q}h6[J-1]=q,X=0;for(q=0;q<16;q++){v8[q]=X;for($=0;$<1<<E8[q];$++)b6[X++]=q}X>>=7;for(;q<d1;q++){v8[q]=X<<7;for($=0;$<1<<E8[q]-7;$++)b6[256+X++]=q}for(Q=0;Q<=N1;Q++)Y[Q]=0;$=0;while($<=143)h2[$*2+1]=8,$++,Y[8]++;while($<=255)h2[$*2+1]=9,$++,Y[9]++;while($<=279)h2[$*2+1]=7,$++,Y[7]++;while($<=287)h2[$*2+1]=8,$++,Y[8]++;W9(h2,_6+1,Y);for($=0;$<d1;$++)y6[$*2+1]=5,y6[$*2]=U9($,5);X9=new t5(h2,Q4,u6+1,_6,N1),Y9=new t5(y6,E8,0,d1,N1),G9=new t5([],pY,0,X4,cY)}function V9($){var Q;for(Q=0;Q<_6;Q++)$.dyn_ltree[Q*2]=0;for(Q=0;Q<d1;Q++)$.dyn_dtree[Q*2]=0;for(Q=0;Q<X4;Q++)$.bl_tree[Q*2]=0;$.dyn_ltree[Y4*2]=1,$.opt_len=$.static_len=0,$.last_lit=$.matches=0}function K9($){if($.bi_valid>8)m6($,$.bi_buf);else if($.bi_valid>0)$.pending_buf[$.pending++]=$.bi_buf;$.bi_buf=0,$.bi_valid=0}function oY($,Q,J,q){if(K9($),q)m6($,J),m6($,~J);fY.arraySet($.pending_buf,$.window,Q,J,$.pending),$.pending+=J}function n$($,Q,J,q){var X=Q*2,Y=J*2;return $[X]<$[Y]||$[X]===$[Y]&&q[Q]<=q[J]}function $4($,Q,J){var q=$.heap[J],X=J<<1;while(X<=$.heap_len){if(X<$.heap_len&&n$(Q,$.heap[X+1],$.heap[X],$.depth))X++;if(n$(Q,q,$.heap[X],$.depth))break;$.heap[J]=$.heap[X],J=X,X<<=1}$.heap[J]=q}function o$($,Q,J){var q,X,Y=0,G,B;if($.last_lit!==0)do if(q=$.pending_buf[$.d_buf+Y*2]<<8|$.pending_buf[$.d_buf+Y*2+1],X=$.pending_buf[$.l_buf+Y],Y++,q===0)D2($,X,Q);else{if(G=h6[X],D2($,G+u6+1,Q),B=Q4[G],B!==0)X-=G4[G],a0($,X,B);if(q--,G=B9(q),D2($,G,J),B=E8[G],B!==0)q-=v8[G],a0($,q,B)}while(Y<$.last_lit);D2($,Y4,Q)}function J4($,Q){var J=Q.dyn_tree,q=Q.stat_desc.static_tree,X=Q.stat_desc.has_stree,Y=Q.stat_desc.elems,G,B,W=-1,U;$.heap_len=0,$.heap_max=e$;for(G=0;G<Y;G++)if(J[G*2]!==0)$.heap[++$.heap_len]=W=G,$.depth[G]=0;else J[G*2+1]=0;while($.heap_len<2)if(U=$.heap[++$.heap_len]=W<2?++W:0,J[U*2]=1,$.depth[U]=0,$.opt_len--,X)$.static_len-=q[U*2+1];Q.max_code=W;for(G=$.heap_len>>1;G>=1;G--)$4($,J,G);U=Y;do G=$.heap[1],$.heap[1]=$.heap[$.heap_len--],$4($,J,1),B=$.heap[1],$.heap[--$.heap_max]=G,$.heap[--$.heap_max]=B,J[U*2]=J[G*2]+J[B*2],$.depth[U]=($.depth[G]>=$.depth[B]?$.depth[G]:$.depth[B])+1,J[G*2+1]=J[B*2+1]=U,$.heap[1]=U++,$4($,J,1);while($.heap_len>=2);$.heap[--$.heap_max]=$.heap[1],iY($,Q),W9(J,W,$.bl_count)}function r$($,Q,J){var q,X=-1,Y,G=Q[1],B=0,W=7,U=4;if(G===0)W=138,U=3;Q[(J+1)*2+1]=65535;for(q=0;q<=J;q++){if(Y=G,G=Q[(q+1)*2+1],++B<W&&Y===G)continue;else if(B<U)$.bl_tree[Y*2]+=B;else if(Y!==0){if(Y!==X)$.bl_tree[Y*2]++;$.bl_tree[$9*2]++}else if(B<=10)$.bl_tree[Q9*2]++;else $.bl_tree[J9*2]++;if(B=0,X=Y,G===0)W=138,U=3;else if(Y===G)W=6,U=3;else W=7,U=4}}function a$($,Q,J){var q,X=-1,Y,G=Q[1],B=0,W=7,U=4;if(G===0)W=138,U=3;for(q=0;q<=J;q++){if(Y=G,G=Q[(q+1)*2+1],++B<W&&Y===G)continue;else if(B<U)do D2($,Y,$.bl_tree);while(--B!==0);else if(Y!==0){if(Y!==X)D2($,Y,$.bl_tree),B--;D2($,$9,$.bl_tree),a0($,B-3,2)}else if(B<=10)D2($,Q9,$.bl_tree),a0($,B-3,3);else D2($,J9,$.bl_tree),a0($,B-11,7);if(B=0,X=Y,G===0)W=138,U=3;else if(Y===G)W=6,U=3;else W=7,U=4}}function rY($){var Q;r$($,$.dyn_ltree,$.l_desc.max_code),r$($,$.dyn_dtree,$.d_desc.max_code),J4($,$.bl_desc);for(Q=X4-1;Q>=3;Q--)if($.bl_tree[q9[Q]*2+1]!==0)break;return $.opt_len+=3*(Q+1)+5+5+4,Q}function aY($,Q,J,q){var X;a0($,Q-257,5),a0($,J-1,5),a0($,q-4,4);for(X=0;X<q;X++)a0($,$.bl_tree[q9[X]*2+1],3);a$($,$.dyn_ltree,Q-1),a$($,$.dyn_dtree,J-1)}function sY($){var Q=4093624447,J;for(J=0;J<=31;J++,Q>>>=1)if(Q&1&&$.dyn_ltree[J*2]!==0)return d$;if($.dyn_ltree[18]!==0||$.dyn_ltree[20]!==0||$.dyn_ltree[26]!==0)return i$;for(J=32;J<u6;J++)if($.dyn_ltree[J*2]!==0)return i$;return d$}var s$=!1;function tY($){if(!s$)nY(),s$=!0;$.l_desc=new e5($.dyn_ltree,X9),$.d_desc=new e5($.dyn_dtree,Y9),$.bl_desc=new e5($.bl_tree,G9),$.bi_buf=0,$.bi_valid=0,V9($)}function H9($,Q,J,q){a0($,(bY<<1)+(q?1:0),3),oY($,Q,J,!0)}function eY($){a0($,t$<<1,3),D2($,Y4,h2),dY($)}function $G($,Q,J,q){var X,Y,G=0;if($.level>0){if($.strm.data_type===_Y)$.strm.data_type=sY($);if(J4($,$.l_desc),J4($,$.d_desc),G=rY($),X=$.opt_len+3+7>>>3,Y=$.static_len+3+7>>>3,Y<=X)X=Y}else X=Y=J+5;if(J+4<=X&&Q!==-1)H9($,Q,J,q);else if($.strategy===yY||Y===X)a0($,(t$<<1)+(q?1:0),3),o$($,h2,y6);else a0($,(hY<<1)+(q?1:0),3),aY($,$.l_desc.max_code+1,$.d_desc.max_code+1,G+1),o$($,$.dyn_ltree,$.dyn_dtree);if(V9($),q)K9($)}function QG($,Q,J){if($.pending_buf[$.d_buf+$.last_lit*2]=Q>>>8&255,$.pending_buf[$.d_buf+$.last_lit*2+1]=Q&255,$.pending_buf[$.l_buf+$.last_lit]=J&255,$.last_lit++,Q===0)$.dyn_ltree[J*2]++;else $.matches++,Q--,$.dyn_ltree[(h6[J]+u6+1)*2]++,$.dyn_dtree[B9(Q)*2]++;return $.last_lit===$.lit_bufsize-1}JG._tr_init=tY;JG._tr_stored_block=H9;JG._tr_flush_block=$G;JG._tr_tally=QG;JG._tr_align=eY});var B4=j0((OK,M9)=>{function UG($,Q,J,q){var X=$&65535|0,Y=$>>>16&65535|0,G=0;while(J!==0){G=J>2000?2000:J,J-=G;do X=X+Q[q++]|0,Y=Y+X|0;while(--G);X%=65521,Y%=65521}return X|Y<<16|0}M9.exports=UG});var U4=j0((NK,w9)=>{function WG(){var $,Q=[];for(var J=0;J<256;J++){$=J;for(var q=0;q<8;q++)$=$&1?3988292384^$>>>1:$>>>1;Q[J]=$}return Q}var VG=WG();function KG($,Q,J,q){var X=VG,Y=q+J;$^=-1;for(var G=q;G<Y;G++)$=$>>>8^X[($^Q[G])&255];return $^-1}w9.exports=KG});var k8=j0((AK,F9)=>{F9.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}});var R9=j0((lG)=>{var i0=b2(),Y2=j9(),N9=B4(),s2=U4(),HG=k8(),C1=0,jG=1,MG=3,J1=4,L9=5,C2=0,z9=1,G2=-2,wG=-3,W4=-5,FG=-1,LG=1,T8=2,zG=3,OG=4,NG=0,AG=2,f8=8,DG=9,PG=15,CG=8,RG=29,IG=256,K4=IG+1+RG,SG=30,EG=19,vG=2*K4+1,kG=15,R0=3,$1=258,W2=$1+R0+1,TG=32,y8=42,H4=69,Z8=73,g8=91,x8=103,A1=113,p6=666,y0=1,l6=2,D1=3,r1=4,ZG=3;function Q1($,Q){return $.msg=HG[Q],Q}function O9($){return($<<1)-($>4?9:0)}function e2($){var Q=$.length;while(--Q>=0)$[Q]=0}function t2($){var Q=$.state,J=Q.pending;if(J>$.avail_out)J=$.avail_out;if(J===0)return;if(i0.arraySet($.output,Q.pending_buf,Q.pending_out,J,$.next_out),$.next_out+=J,Q.pending_out+=J,$.total_out+=J,$.avail_out-=J,Q.pending-=J,Q.pending===0)Q.pending_out=0}function b0($,Q){Y2._tr_flush_block($,$.block_start>=0?$.block_start:-1,$.strstart-$.block_start,Q),$.block_start=$.strstart,t2($.strm)}function I0($,Q){$.pending_buf[$.pending++]=Q}function c6($,Q){$.pending_buf[$.pending++]=Q>>>8&255,$.pending_buf[$.pending++]=Q&255}function gG($,Q,J,q){var X=$.avail_in;if(X>q)X=q;if(X===0)return 0;if($.avail_in-=X,i0.arraySet(Q,$.input,$.next_in,X,J),$.state.wrap===1)$.adler=N9($.adler,Q,X,J);else if($.state.wrap===2)$.adler=s2($.adler,Q,X,J);return $.next_in+=X,$.total_in+=X,X}function A9($,Q){var{max_chain_length:J,strstart:q}=$,X,Y,G=$.prev_length,B=$.nice_match,W=$.strstart>$.w_size-W2?$.strstart-($.w_size-W2):0,U=$.window,V=$.w_mask,L=$.prev,w=$.strstart+$1,M=U[q+G-1],y=U[q+G];if($.prev_length>=$.good_match)J>>=2;if(B>$.lookahead)B=$.lookahead;do{if(X=Q,U[X+G]!==y||U[X+G-1]!==M||U[X]!==U[q]||U[++X]!==U[q+1])continue;q+=2,X++;do;while(U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&q<w);if(Y=$1-(w-q),q=w-$1,Y>G){if($.match_start=Q,G=Y,Y>=B)break;M=U[q+G-1],y=U[q+G]}}while((Q=L[Q&V])>W&&--J!==0);if(G<=$.lookahead)return G;return $.lookahead}function P1($){var Q=$.w_size,J,q,X,Y,G;do{if(Y=$.window_size-$.lookahead-$.strstart,$.strstart>=Q+(Q-W2)){i0.arraySet($.window,$.window,Q,Q,0),$.match_start-=Q,$.strstart-=Q,$.block_start-=Q,q=$.hash_size,J=q;do X=$.head[--J],$.head[J]=X>=Q?X-Q:0;while(--q);q=Q,J=q;do X=$.prev[--J],$.prev[J]=X>=Q?X-Q:0;while(--q);Y+=Q}if($.strm.avail_in===0)break;if(q=gG($.strm,$.window,$.strstart+$.lookahead,Y),$.lookahead+=q,$.lookahead+$.insert>=R0){G=$.strstart-$.insert,$.ins_h=$.window[G],$.ins_h=($.ins_h<<$.hash_shift^$.window[G+1])&$.hash_mask;while($.insert)if($.ins_h=($.ins_h<<$.hash_shift^$.window[G+R0-1])&$.hash_mask,$.prev[G&$.w_mask]=$.head[$.ins_h],$.head[$.ins_h]=G,G++,$.insert--,$.lookahead+$.insert<R0)break}}while($.lookahead<W2&&$.strm.avail_in!==0)}function xG($,Q){var J=65535;if(J>$.pending_buf_size-5)J=$.pending_buf_size-5;for(;;){if($.lookahead<=1){if(P1($),$.lookahead===0&&Q===C1)return y0;if($.lookahead===0)break}$.strstart+=$.lookahead,$.lookahead=0;var q=$.block_start+J;if($.strstart===0||$.strstart>=q){if($.lookahead=$.strstart-q,$.strstart=q,b0($,!1),$.strm.avail_out===0)return y0}if($.strstart-$.block_start>=$.w_size-W2){if(b0($,!1),$.strm.avail_out===0)return y0}}if($.insert=0,Q===J1){if(b0($,!0),$.strm.avail_out===0)return D1;return r1}if($.strstart>$.block_start){if(b0($,!1),$.strm.avail_out===0)return y0}return y0}function V4($,Q){var J,q;for(;;){if($.lookahead<W2){if(P1($),$.lookahead<W2&&Q===C1)return y0;if($.lookahead===0)break}if(J=0,$.lookahead>=R0)$.ins_h=($.ins_h<<$.hash_shift^$.window[$.strstart+R0-1])&$.hash_mask,J=$.prev[$.strstart&$.w_mask]=$.head[$.ins_h],$.head[$.ins_h]=$.strstart;if(J!==0&&$.strstart-J<=$.w_size-W2)$.match_length=A9($,J);if($.match_length>=R0)if(q=Y2._tr_tally($,$.strstart-$.match_start,$.match_length-R0),$.lookahead-=$.match_length,$.match_length<=$.max_lazy_match&&$.lookahead>=R0){$.match_length--;do $.strstart++,$.ins_h=($.ins_h<<$.hash_shift^$.window[$.strstart+R0-1])&$.hash_mask,J=$.prev[$.strstart&$.w_mask]=$.head[$.ins_h],$.head[$.ins_h]=$.strstart;while(--$.match_length!==0);$.strstart++}else $.strstart+=$.match_length,$.match_length=0,$.ins_h=$.window[$.strstart],$.ins_h=($.ins_h<<$.hash_shift^$.window[$.strstart+1])&$.hash_mask;else q=Y2._tr_tally($,0,$.window[$.strstart]),$.lookahead--,$.strstart++;if(q){if(b0($,!1),$.strm.avail_out===0)return y0}}if($.insert=$.strstart<R0-1?$.strstart:R0-1,Q===J1){if(b0($,!0),$.strm.avail_out===0)return D1;return r1}if($.last_lit){if(b0($,!1),$.strm.avail_out===0)return y0}return l6}function n1($,Q){var J,q,X;for(;;){if($.lookahead<W2){if(P1($),$.lookahead<W2&&Q===C1)return y0;if($.lookahead===0)break}if(J=0,$.lookahead>=R0)$.ins_h=($.ins_h<<$.hash_shift^$.window[$.strstart+R0-1])&$.hash_mask,J=$.prev[$.strstart&$.w_mask]=$.head[$.ins_h],$.head[$.ins_h]=$.strstart;if($.prev_length=$.match_length,$.prev_match=$.match_start,$.match_length=R0-1,J!==0&&$.prev_length<$.max_lazy_match&&$.strstart-J<=$.w_size-W2){if($.match_length=A9($,J),$.match_length<=5&&($.strategy===LG||$.match_length===R0&&$.strstart-$.match_start>4096))$.match_length=R0-1}if($.prev_length>=R0&&$.match_length<=$.prev_length){X=$.strstart+$.lookahead-R0,q=Y2._tr_tally($,$.strstart-1-$.prev_match,$.prev_length-R0),$.lookahead-=$.prev_length-1,$.prev_length-=2;do if(++$.strstart<=X)$.ins_h=($.ins_h<<$.hash_shift^$.window[$.strstart+R0-1])&$.hash_mask,J=$.prev[$.strstart&$.w_mask]=$.head[$.ins_h],$.head[$.ins_h]=$.strstart;while(--$.prev_length!==0);if($.match_available=0,$.match_length=R0-1,$.strstart++,q){if(b0($,!1),$.strm.avail_out===0)return y0}}else if($.match_available){if(q=Y2._tr_tally($,0,$.window[$.strstart-1]),q)b0($,!1);if($.strstart++,$.lookahead--,$.strm.avail_out===0)return y0}else $.match_available=1,$.strstart++,$.lookahead--}if($.match_available)q=Y2._tr_tally($,0,$.window[$.strstart-1]),$.match_available=0;if($.insert=$.strstart<R0-1?$.strstart:R0-1,Q===J1){if(b0($,!0),$.strm.avail_out===0)return D1;return r1}if($.last_lit){if(b0($,!1),$.strm.avail_out===0)return y0}return l6}function fG($,Q){var J,q,X,Y,G=$.window;for(;;){if($.lookahead<=$1){if(P1($),$.lookahead<=$1&&Q===C1)return y0;if($.lookahead===0)break}if($.match_length=0,$.lookahead>=R0&&$.strstart>0){if(X=$.strstart-1,q=G[X],q===G[++X]&&q===G[++X]&&q===G[++X]){Y=$.strstart+$1;do;while(q===G[++X]&&q===G[++X]&&q===G[++X]&&q===G[++X]&&q===G[++X]&&q===G[++X]&&q===G[++X]&&q===G[++X]&&X<Y);if($.match_length=$1-(Y-X),$.match_length>$.lookahead)$.match_length=$.lookahead}}if($.match_length>=R0)J=Y2._tr_tally($,1,$.match_length-R0),$.lookahead-=$.match_length,$.strstart+=$.match_length,$.match_length=0;else J=Y2._tr_tally($,0,$.window[$.strstart]),$.lookahead--,$.strstart++;if(J){if(b0($,!1),$.strm.avail_out===0)return y0}}if($.insert=0,Q===J1){if(b0($,!0),$.strm.avail_out===0)return D1;return r1}if($.last_lit){if(b0($,!1),$.strm.avail_out===0)return y0}return l6}function yG($,Q){var J;for(;;){if($.lookahead===0){if(P1($),$.lookahead===0){if(Q===C1)return y0;break}}if($.match_length=0,J=Y2._tr_tally($,0,$.window[$.strstart]),$.lookahead--,$.strstart++,J){if(b0($,!1),$.strm.avail_out===0)return y0}}if($.insert=0,Q===J1){if(b0($,!0),$.strm.avail_out===0)return D1;return r1}if($.last_lit){if(b0($,!1),$.strm.avail_out===0)return y0}return l6}function P2($,Q,J,q,X){this.good_length=$,this.max_lazy=Q,this.nice_length=J,this.max_chain=q,this.func=X}var o1;o1=[new P2(0,0,0,0,xG),new P2(4,4,8,4,V4),new P2(4,5,16,8,V4),new P2(4,6,32,32,V4),new P2(4,4,16,16,n1),new P2(8,16,32,32,n1),new P2(8,16,128,128,n1),new P2(8,32,128,256,n1),new P2(32,128,258,1024,n1),new P2(32,258,258,4096,n1)];function _G($){$.window_size=2*$.w_size,e2($.head),$.max_lazy_match=o1[$.level].max_lazy,$.good_match=o1[$.level].good_length,$.nice_match=o1[$.level].nice_length,$.max_chain_length=o1[$.level].max_chain,$.strstart=0,$.block_start=0,$.lookahead=0,$.insert=0,$.match_length=$.prev_length=R0-1,$.match_available=0,$.ins_h=0}function bG(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=f8,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new i0.Buf16(vG*2),this.dyn_dtree=new i0.Buf16((2*SG+1)*2),this.bl_tree=new i0.Buf16((2*EG+1)*2),e2(this.dyn_ltree),e2(this.dyn_dtree),e2(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new i0.Buf16(kG+1),this.heap=new i0.Buf16(2*K4+1),e2(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new i0.Buf16(2*K4+1),e2(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function D9($){var Q;if(!$||!$.state)return Q1($,G2);if($.total_in=$.total_out=0,$.data_type=AG,Q=$.state,Q.pending=0,Q.pending_out=0,Q.wrap<0)Q.wrap=-Q.wrap;return Q.status=Q.wrap?y8:A1,$.adler=Q.wrap===2?0:1,Q.last_flush=C1,Y2._tr_init(Q),C2}function P9($){var Q=D9($);if(Q===C2)_G($.state);return Q}function hG($,Q){if(!$||!$.state)return G2;if($.state.wrap!==2)return G2;return $.state.gzhead=Q,C2}function C9($,Q,J,q,X,Y){if(!$)return G2;var G=1;if(Q===FG)Q=6;if(q<0)G=0,q=-q;else if(q>15)G=2,q-=16;if(X<1||X>DG||J!==f8||q<8||q>15||Q<0||Q>9||Y<0||Y>OG)return Q1($,G2);if(q===8)q=9;var B=new bG;return $.state=B,B.strm=$,B.wrap=G,B.gzhead=null,B.w_bits=q,B.w_size=1<<B.w_bits,B.w_mask=B.w_size-1,B.hash_bits=X+7,B.hash_size=1<<B.hash_bits,B.hash_mask=B.hash_size-1,B.hash_shift=~~((B.hash_bits+R0-1)/R0),B.window=new i0.Buf8(B.w_size*2),B.head=new i0.Buf16(B.hash_size),B.prev=new i0.Buf16(B.w_size),B.lit_bufsize=1<<X+6,B.pending_buf_size=B.lit_bufsize*4,B.pending_buf=new i0.Buf8(B.pending_buf_size),B.d_buf=1*B.lit_bufsize,B.l_buf=3*B.lit_bufsize,B.level=Q,B.strategy=Y,B.method=J,P9($)}function mG($,Q){return C9($,Q,f8,PG,CG,NG)}function uG($,Q){var J,q,X,Y;if(!$||!$.state||Q>L9||Q<0)return $?Q1($,G2):G2;if(q=$.state,!$.output||!$.input&&$.avail_in!==0||q.status===p6&&Q!==J1)return Q1($,$.avail_out===0?W4:G2);if(q.strm=$,J=q.last_flush,q.last_flush=Q,q.status===y8)if(q.wrap===2)if($.adler=0,I0(q,31),I0(q,139),I0(q,8),!q.gzhead)I0(q,0),I0(q,0),I0(q,0),I0(q,0),I0(q,0),I0(q,q.level===9?2:q.strategy>=T8||q.level<2?4:0),I0(q,ZG),q.status=A1;else{if(I0(q,(q.gzhead.text?1:0)+(q.gzhead.hcrc?2:0)+(!q.gzhead.extra?0:4)+(!q.gzhead.name?0:8)+(!q.gzhead.comment?0:16)),I0(q,q.gzhead.time&255),I0(q,q.gzhead.time>>8&255),I0(q,q.gzhead.time>>16&255),I0(q,q.gzhead.time>>24&255),I0(q,q.level===9?2:q.strategy>=T8||q.level<2?4:0),I0(q,q.gzhead.os&255),q.gzhead.extra&&q.gzhead.extra.length)I0(q,q.gzhead.extra.length&255),I0(q,q.gzhead.extra.length>>8&255);if(q.gzhead.hcrc)$.adler=s2($.adler,q.pending_buf,q.pending,0);q.gzindex=0,q.status=H4}else{var G=f8+(q.w_bits-8<<4)<<8,B=-1;if(q.strategy>=T8||q.level<2)B=0;else if(q.level<6)B=1;else if(q.level===6)B=2;else B=3;if(G|=B<<6,q.strstart!==0)G|=TG;if(G+=31-G%31,q.status=A1,c6(q,G),q.strstart!==0)c6(q,$.adler>>>16),c6(q,$.adler&65535);$.adler=1}if(q.status===H4)if(q.gzhead.extra){X=q.pending;while(q.gzindex<(q.gzhead.extra.length&65535)){if(q.pending===q.pending_buf_size){if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(t2($),X=q.pending,q.pending===q.pending_buf_size)break}I0(q,q.gzhead.extra[q.gzindex]&255),q.gzindex++}if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(q.gzindex===q.gzhead.extra.length)q.gzindex=0,q.status=Z8}else q.status=Z8;if(q.status===Z8)if(q.gzhead.name){X=q.pending;do{if(q.pending===q.pending_buf_size){if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(t2($),X=q.pending,q.pending===q.pending_buf_size){Y=1;break}}if(q.gzindex<q.gzhead.name.length)Y=q.gzhead.name.charCodeAt(q.gzindex++)&255;else Y=0;I0(q,Y)}while(Y!==0);if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(Y===0)q.gzindex=0,q.status=g8}else q.status=g8;if(q.status===g8)if(q.gzhead.comment){X=q.pending;do{if(q.pending===q.pending_buf_size){if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(t2($),X=q.pending,q.pending===q.pending_buf_size){Y=1;break}}if(q.gzindex<q.gzhead.comment.length)Y=q.gzhead.comment.charCodeAt(q.gzindex++)&255;else Y=0;I0(q,Y)}while(Y!==0);if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(Y===0)q.status=x8}else q.status=x8;if(q.status===x8)if(q.gzhead.hcrc){if(q.pending+2>q.pending_buf_size)t2($);if(q.pending+2<=q.pending_buf_size)I0(q,$.adler&255),I0(q,$.adler>>8&255),$.adler=0,q.status=A1}else q.status=A1;if(q.pending!==0){if(t2($),$.avail_out===0)return q.last_flush=-1,C2}else if($.avail_in===0&&O9(Q)<=O9(J)&&Q!==J1)return Q1($,W4);if(q.status===p6&&$.avail_in!==0)return Q1($,W4);if($.avail_in!==0||q.lookahead!==0||Q!==C1&&q.status!==p6){var W=q.strategy===T8?yG(q,Q):q.strategy===zG?fG(q,Q):o1[q.level].func(q,Q);if(W===D1||W===r1)q.status=p6;if(W===y0||W===D1){if($.avail_out===0)q.last_flush=-1;return C2}if(W===l6){if(Q===jG)Y2._tr_align(q);else if(Q!==L9){if(Y2._tr_stored_block(q,0,0,!1),Q===MG){if(e2(q.head),q.lookahead===0)q.strstart=0,q.block_start=0,q.insert=0}}if(t2($),$.avail_out===0)return q.last_flush=-1,C2}}if(Q!==J1)return C2;if(q.wrap<=0)return z9;if(q.wrap===2)I0(q,$.adler&255),I0(q,$.adler>>8&255),I0(q,$.adler>>16&255),I0(q,$.adler>>24&255),I0(q,$.total_in&255),I0(q,$.total_in>>8&255),I0(q,$.total_in>>16&255),I0(q,$.total_in>>24&255);else c6(q,$.adler>>>16),c6(q,$.adler&65535);if(t2($),q.wrap>0)q.wrap=-q.wrap;return q.pending!==0?C2:z9}function cG($){var Q;if(!$||!$.state)return G2;if(Q=$.state.status,Q!==y8&&Q!==H4&&Q!==Z8&&Q!==g8&&Q!==x8&&Q!==A1&&Q!==p6)return Q1($,G2);return $.state=null,Q===A1?Q1($,wG):C2}function pG($,Q){var J=Q.length,q,X,Y,G,B,W,U,V;if(!$||!$.state)return G2;if(q=$.state,G=q.wrap,G===2||G===1&&q.status!==y8||q.lookahead)return G2;if(G===1)$.adler=N9($.adler,Q,J,0);if(q.wrap=0,J>=q.w_size){if(G===0)e2(q.head),q.strstart=0,q.block_start=0,q.insert=0;V=new i0.Buf8(q.w_size),i0.arraySet(V,Q,J-q.w_size,q.w_size,0),Q=V,J=q.w_size}B=$.avail_in,W=$.next_in,U=$.input,$.avail_in=J,$.next_in=0,$.input=Q,P1(q);while(q.lookahead>=R0){X=q.strstart,Y=q.lookahead-(R0-1);do q.ins_h=(q.ins_h<<q.hash_shift^q.window[X+R0-1])&q.hash_mask,q.prev[X&q.w_mask]=q.head[q.ins_h],q.head[q.ins_h]=X,X++;while(--Y);q.strstart=X,q.lookahead=R0-1,P1(q)}return q.strstart+=q.lookahead,q.block_start=q.strstart,q.insert=q.lookahead,q.lookahead=0,q.match_length=q.prev_length=R0-1,q.match_available=0,$.next_in=W,$.input=U,$.avail_in=B,q.wrap=G,C2}lG.deflateInit=mG;lG.deflateInit2=C9;lG.deflateReset=P9;lG.deflateResetKeep=D9;lG.deflateSetHeader=hG;lG.deflate=uG;lG.deflateEnd=cG;lG.deflateSetDictionary=pG;lG.deflateInfo="pako deflate (from Nodeca project)"});var j4=j0(($B)=>{var _8=b2(),I9=!0,S9=!0;try{String.fromCharCode.apply(null,[0])}catch($){I9=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch($){S9=!1}var d6=new _8.Buf8(256);for(R2=0;R2<256;R2++)d6[R2]=R2>=252?6:R2>=248?5:R2>=240?4:R2>=224?3:R2>=192?2:1;var R2;d6[254]=d6[254]=1;$B.string2buf=function($){var Q,J,q,X,Y,G=$.length,B=0;for(X=0;X<G;X++){if(J=$.charCodeAt(X),(J&64512)===55296&&X+1<G){if(q=$.charCodeAt(X+1),(q&64512)===56320)J=65536+(J-55296<<10)+(q-56320),X++}B+=J<128?1:J<2048?2:J<65536?3:4}Q=new _8.Buf8(B);for(Y=0,X=0;Y<B;X++){if(J=$.charCodeAt(X),(J&64512)===55296&&X+1<G){if(q=$.charCodeAt(X+1),(q&64512)===56320)J=65536+(J-55296<<10)+(q-56320),X++}if(J<128)Q[Y++]=J;else if(J<2048)Q[Y++]=192|J>>>6,Q[Y++]=128|J&63;else if(J<65536)Q[Y++]=224|J>>>12,Q[Y++]=128|J>>>6&63,Q[Y++]=128|J&63;else Q[Y++]=240|J>>>18,Q[Y++]=128|J>>>12&63,Q[Y++]=128|J>>>6&63,Q[Y++]=128|J&63}return Q};function E9($,Q){if(Q<65534){if($.subarray&&S9||!$.subarray&&I9)return String.fromCharCode.apply(null,_8.shrinkBuf($,Q))}var J="";for(var q=0;q<Q;q++)J+=String.fromCharCode($[q]);return J}$B.buf2binstring=function($){return E9($,$.length)};$B.binstring2buf=function($){var Q=new _8.Buf8($.length);for(var J=0,q=Q.length;J<q;J++)Q[J]=$.charCodeAt(J);return Q};$B.buf2string=function($,Q){var J,q,X,Y,G=Q||$.length,B=Array(G*2);for(q=0,J=0;J<G;){if(X=$[J++],X<128){B[q++]=X;continue}if(Y=d6[X],Y>4){B[q++]=65533,J+=Y-1;continue}X&=Y===2?31:Y===3?15:7;while(Y>1&&J<G)X=X<<6|$[J++]&63,Y--;if(Y>1){B[q++]=65533;continue}if(X<65536)B[q++]=X;else X-=65536,B[q++]=55296|X>>10&1023,B[q++]=56320|X&1023}return E9(B,q)};$B.utf8border=function($,Q){var J;if(Q=Q||$.length,Q>$.length)Q=$.length;J=Q-1;while(J>=0&&($[J]&192)===128)J--;if(J<0)return Q;if(J===0)return Q;return J+d6[$[J]]>Q?J:Q}});var M4=j0((CK,v9)=>{function GB(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}v9.exports=GB});var g9=j0((MB)=>{var i6=R9(),n6=b2(),F4=j4(),L4=k8(),BB=M4(),Z9=Object.prototype.toString,UB=0,w4=4,a1=0,k9=1,T9=2,WB=-1,VB=0,KB=8;function R1($){if(!(this instanceof R1))return new R1($);this.options=n6.assign({level:WB,method:KB,chunkSize:16384,windowBits:15,memLevel:8,strategy:VB,to:""},$||{});var Q=this.options;if(Q.raw&&Q.windowBits>0)Q.windowBits=-Q.windowBits;else if(Q.gzip&&Q.windowBits>0&&Q.windowBits<16)Q.windowBits+=16;this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new BB,this.strm.avail_out=0;var J=i6.deflateInit2(this.strm,Q.level,Q.method,Q.windowBits,Q.memLevel,Q.strategy);if(J!==a1)throw Error(L4[J]);if(Q.header)i6.deflateSetHeader(this.strm,Q.header);if(Q.dictionary){var q;if(typeof Q.dictionary==="string")q=F4.string2buf(Q.dictionary);else if(Z9.call(Q.dictionary)==="[object ArrayBuffer]")q=new Uint8Array(Q.dictionary);else q=Q.dictionary;if(J=i6.deflateSetDictionary(this.strm,q),J!==a1)throw Error(L4[J]);this._dict_set=!0}}R1.prototype.push=function($,Q){var J=this.strm,q=this.options.chunkSize,X,Y;if(this.ended)return!1;if(Y=Q===~~Q?Q:Q===!0?w4:UB,typeof $==="string")J.input=F4.string2buf($);else if(Z9.call($)==="[object ArrayBuffer]")J.input=new Uint8Array($);else J.input=$;J.next_in=0,J.avail_in=J.input.length;do{if(J.avail_out===0)J.output=new n6.Buf8(q),J.next_out=0,J.avail_out=q;if(X=i6.deflate(J,Y),X!==k9&&X!==a1)return this.onEnd(X),this.ended=!0,!1;if(J.avail_out===0||J.avail_in===0&&(Y===w4||Y===T9))if(this.options.to==="string")this.onData(F4.buf2binstring(n6.shrinkBuf(J.output,J.next_out)));else this.onData(n6.shrinkBuf(J.output,J.next_out))}while((J.avail_in>0||J.avail_out===0)&&X!==k9);if(Y===w4)return X=i6.deflateEnd(this.strm),this.onEnd(X),this.ended=!0,X===a1;if(Y===T9)return this.onEnd(a1),J.avail_out=0,!0;return!0};R1.prototype.onData=function($){this.chunks.push($)};R1.prototype.onEnd=function($){if($===a1)if(this.options.to==="string")this.result=this.chunks.join("");else this.result=n6.flattenChunks(this.chunks);this.chunks=[],this.err=$,this.msg=this.strm.msg};function z4($,Q){var J=new R1(Q);if(J.push($,!0),J.err)throw J.msg||L4[J.err];return J.result}function HB($,Q){return Q=Q||{},Q.raw=!0,z4($,Q)}function jB($,Q){return Q=Q||{},Q.gzip=!0,z4($,Q)}MB.Deflate=R1;MB.deflate=z4;MB.deflateRaw=HB;MB.gzip=jB});var f9=j0((IK,x9)=>{var b8=30,OB=12;x9.exports=function(Q,J){var q,X,Y,G,B,W,U,V,L,w,M,y,x,A,P,K,F,z,D,_,T,l,S,E,C;q=Q.state,X=Q.next_in,E=Q.input,Y=X+(Q.avail_in-5),G=Q.next_out,C=Q.output,B=G-(J-Q.avail_out),W=G+(Q.avail_out-257),U=q.dmax,V=q.wsize,L=q.whave,w=q.wnext,M=q.window,y=q.hold,x=q.bits,A=q.lencode,P=q.distcode,K=(1<<q.lenbits)-1,F=(1<<q.distbits)-1;$:do{if(x<15)y+=E[X++]<<x,x+=8,y+=E[X++]<<x,x+=8;z=A[y&K];Q:for(;;){if(D=z>>>24,y>>>=D,x-=D,D=z>>>16&255,D===0)C[G++]=z&65535;else if(D&16){if(_=z&65535,D&=15,D){if(x<D)y+=E[X++]<<x,x+=8;_+=y&(1<<D)-1,y>>>=D,x-=D}if(x<15)y+=E[X++]<<x,x+=8,y+=E[X++]<<x,x+=8;z=P[y&F];J:for(;;){if(D=z>>>24,y>>>=D,x-=D,D=z>>>16&255,D&16){if(T=z&65535,D&=15,x<D){if(y+=E[X++]<<x,x+=8,x<D)y+=E[X++]<<x,x+=8}if(T+=y&(1<<D)-1,T>U){Q.msg="invalid distance too far back",q.mode=b8;break $}if(y>>>=D,x-=D,D=G-B,T>D){if(D=T-D,D>L){if(q.sane){Q.msg="invalid distance too far back",q.mode=b8;break $}}if(l=0,S=M,w===0){if(l+=V-D,D<_){_-=D;do C[G++]=M[l++];while(--D);l=G-T,S=C}}else if(w<D){if(l+=V+w-D,D-=w,D<_){_-=D;do C[G++]=M[l++];while(--D);if(l=0,w<_){D=w,_-=D;do C[G++]=M[l++];while(--D);l=G-T,S=C}}}else if(l+=w-D,D<_){_-=D;do C[G++]=M[l++];while(--D);l=G-T,S=C}while(_>2)C[G++]=S[l++],C[G++]=S[l++],C[G++]=S[l++],_-=3;if(_){if(C[G++]=S[l++],_>1)C[G++]=S[l++]}}else{l=G-T;do C[G++]=C[l++],C[G++]=C[l++],C[G++]=C[l++],_-=3;while(_>2);if(_){if(C[G++]=C[l++],_>1)C[G++]=C[l++]}}}else if((D&64)===0){z=P[(z&65535)+(y&(1<<D)-1)];continue J}else{Q.msg="invalid distance code",q.mode=b8;break $}break}}else if((D&64)===0){z=A[(z&65535)+(y&(1<<D)-1)];continue Q}else if(D&32){q.mode=OB;break $}else{Q.msg="invalid literal/length code",q.mode=b8;break $}break}}while(X<Y&&G<W);_=x>>3,X-=_,x-=_<<3,y&=(1<<x)-1,Q.next_in=X,Q.next_out=G,Q.avail_in=X<Y?5+(Y-X):5-(X-Y),Q.avail_out=G<W?257+(W-G):257-(G-W),q.hold=y,q.bits=x;return}});var c9=j0((SK,u9)=>{var y9=b2(),s1=15,_9=852,b9=592,h9=0,O4=1,m9=2,NB=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],AB=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],DB=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],PB=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];u9.exports=function(Q,J,q,X,Y,G,B,W){var U=W.bits,V=0,L=0,w=0,M=0,y=0,x=0,A=0,P=0,K=0,F=0,z,D,_,T,l,S=null,E=0,C,N=new y9.Buf16(s1+1),Z=new y9.Buf16(s1+1),f=null,k=0,s,J0,B0;for(V=0;V<=s1;V++)N[V]=0;for(L=0;L<X;L++)N[J[q+L]]++;y=U;for(M=s1;M>=1;M--)if(N[M]!==0)break;if(y>M)y=M;if(M===0)return Y[G++]=20971520,Y[G++]=20971520,W.bits=1,0;for(w=1;w<M;w++)if(N[w]!==0)break;if(y<w)y=w;P=1;for(V=1;V<=s1;V++)if(P<<=1,P-=N[V],P<0)return-1;if(P>0&&(Q===h9||M!==1))return-1;Z[1]=0;for(V=1;V<s1;V++)Z[V+1]=Z[V]+N[V];for(L=0;L<X;L++)if(J[q+L]!==0)B[Z[J[q+L]]++]=L;if(Q===h9)S=f=B,C=19;else if(Q===O4)S=NB,E-=257,f=AB,k-=257,C=256;else S=DB,f=PB,C=-1;if(F=0,L=0,V=w,l=G,x=y,A=0,_=-1,K=1<<y,T=K-1,Q===O4&&K>_9||Q===m9&&K>b9)return 1;for(;;){if(s=V-A,B[L]<C)J0=0,B0=B[L];else if(B[L]>C)J0=f[k+B[L]],B0=S[E+B[L]];else J0=96,B0=0;z=1<<V-A,D=1<<x,w=D;do D-=z,Y[l+(F>>A)+D]=s<<24|J0<<16|B0|0;while(D!==0);z=1<<V-1;while(F&z)z>>=1;if(z!==0)F&=z-1,F+=z;else F=0;if(L++,--N[V]===0){if(V===M)break;V=J[q+B[L]]}if(V>y&&(F&T)!==_){if(A===0)A=y;l+=w,x=V-A,P=1<<x;while(x+A<M){if(P-=N[x+A],P<=0)break;x++,P<<=1}if(K+=1<<x,Q===O4&&K>_9||Q===m9&&K>b9)return 1;_=F&T,Y[_]=y<<24|x<<16|l-G|0}}if(F!==0)Y[l+F]=V-A<<24|4194304|0;return W.bits=y,0}});var PQ=j0((cB)=>{var e0=b2(),R4=B4(),I2=U4(),CB=f9(),o6=c9(),RB=0,MQ=1,wQ=2,p9=4,IB=5,h8=6,I1=0,SB=1,EB=2,B2=-2,FQ=-3,I4=-4,vB=-5,l9=8,LQ=1,d9=2,i9=3,n9=4,o9=5,r9=6,a9=7,s9=8,t9=9,e9=10,c8=11,m2=12,N4=13,$Q=14,A4=15,QQ=16,JQ=17,qQ=18,XQ=19,m8=20,u8=21,YQ=22,GQ=23,BQ=24,UQ=25,WQ=26,D4=27,VQ=28,KQ=29,T0=30,S4=31,kB=32,TB=852,ZB=592,gB=15,xB=gB;function HQ($){return($>>>24&255)+($>>>8&65280)+(($&65280)<<8)+(($&255)<<24)}function fB(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new e0.Buf16(320),this.work=new e0.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function zQ($){var Q;if(!$||!$.state)return B2;if(Q=$.state,$.total_in=$.total_out=Q.total=0,$.msg="",Q.wrap)$.adler=Q.wrap&1;return Q.mode=LQ,Q.last=0,Q.havedict=0,Q.dmax=32768,Q.head=null,Q.hold=0,Q.bits=0,Q.lencode=Q.lendyn=new e0.Buf32(TB),Q.distcode=Q.distdyn=new e0.Buf32(ZB),Q.sane=1,Q.back=-1,I1}function OQ($){var Q;if(!$||!$.state)return B2;return Q=$.state,Q.wsize=0,Q.whave=0,Q.wnext=0,zQ($)}function NQ($,Q){var J,q;if(!$||!$.state)return B2;if(q=$.state,Q<0)J=0,Q=-Q;else if(J=(Q>>4)+1,Q<48)Q&=15;if(Q&&(Q<8||Q>15))return B2;if(q.window!==null&&q.wbits!==Q)q.window=null;return q.wrap=J,q.wbits=Q,OQ($)}function AQ($,Q){var J,q;if(!$)return B2;if(q=new fB,$.state=q,q.window=null,J=NQ($,Q),J!==I1)$.state=null;return J}function yB($){return AQ($,xB)}var jQ=!0,P4,C4;function _B($){if(jQ){var Q;P4=new e0.Buf32(512),C4=new e0.Buf32(32),Q=0;while(Q<144)$.lens[Q++]=8;while(Q<256)$.lens[Q++]=9;while(Q<280)$.lens[Q++]=7;while(Q<288)$.lens[Q++]=8;o6(MQ,$.lens,0,288,P4,0,$.work,{bits:9}),Q=0;while(Q<32)$.lens[Q++]=5;o6(wQ,$.lens,0,32,C4,0,$.work,{bits:5}),jQ=!1}$.lencode=P4,$.lenbits=9,$.distcode=C4,$.distbits=5}function DQ($,Q,J,q){var X,Y=$.state;if(Y.window===null)Y.wsize=1<<Y.wbits,Y.wnext=0,Y.whave=0,Y.window=new e0.Buf8(Y.wsize);if(q>=Y.wsize)e0.arraySet(Y.window,Q,J-Y.wsize,Y.wsize,0),Y.wnext=0,Y.whave=Y.wsize;else{if(X=Y.wsize-Y.wnext,X>q)X=q;if(e0.arraySet(Y.window,Q,J-q,X,Y.wnext),q-=X,q)e0.arraySet(Y.window,Q,J-q,q,0),Y.wnext=q,Y.whave=Y.wsize;else{if(Y.wnext+=X,Y.wnext===Y.wsize)Y.wnext=0;if(Y.whave<Y.wsize)Y.whave+=X}}return 0}function bB($,Q){var J,q,X,Y,G,B,W,U,V,L,w,M,y,x,A=0,P,K,F,z,D,_,T,l,S=new e0.Buf8(4),E,C,N=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!$||!$.state||!$.output||!$.input&&$.avail_in!==0)return B2;if(J=$.state,J.mode===m2)J.mode=N4;G=$.next_out,X=$.output,W=$.avail_out,Y=$.next_in,q=$.input,B=$.avail_in,U=J.hold,V=J.bits,L=B,w=W,l=I1;$:for(;;)switch(J.mode){case LQ:if(J.wrap===0){J.mode=N4;break}while(V<16){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.wrap&2&&U===35615){J.check=0,S[0]=U&255,S[1]=U>>>8&255,J.check=I2(J.check,S,2,0),U=0,V=0,J.mode=d9;break}if(J.flags=0,J.head)J.head.done=!1;if(!(J.wrap&1)||(((U&255)<<8)+(U>>8))%31){$.msg="incorrect header check",J.mode=T0;break}if((U&15)!==l9){$.msg="unknown compression method",J.mode=T0;break}if(U>>>=4,V-=4,T=(U&15)+8,J.wbits===0)J.wbits=T;else if(T>J.wbits){$.msg="invalid window size",J.mode=T0;break}J.dmax=1<<T,$.adler=J.check=1,J.mode=U&512?e9:m2,U=0,V=0;break;case d9:while(V<16){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.flags=U,(J.flags&255)!==l9){$.msg="unknown compression method",J.mode=T0;break}if(J.flags&57344){$.msg="unknown header flags set",J.mode=T0;break}if(J.head)J.head.text=U>>8&1;if(J.flags&512)S[0]=U&255,S[1]=U>>>8&255,J.check=I2(J.check,S,2,0);U=0,V=0,J.mode=i9;case i9:while(V<32){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.head)J.head.time=U;if(J.flags&512)S[0]=U&255,S[1]=U>>>8&255,S[2]=U>>>16&255,S[3]=U>>>24&255,J.check=I2(J.check,S,4,0);U=0,V=0,J.mode=n9;case n9:while(V<16){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.head)J.head.xflags=U&255,J.head.os=U>>8;if(J.flags&512)S[0]=U&255,S[1]=U>>>8&255,J.check=I2(J.check,S,2,0);U=0,V=0,J.mode=o9;case o9:if(J.flags&1024){while(V<16){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.length=U,J.head)J.head.extra_len=U;if(J.flags&512)S[0]=U&255,S[1]=U>>>8&255,J.check=I2(J.check,S,2,0);U=0,V=0}else if(J.head)J.head.extra=null;J.mode=r9;case r9:if(J.flags&1024){if(M=J.length,M>B)M=B;if(M){if(J.head){if(T=J.head.extra_len-J.length,!J.head.extra)J.head.extra=Array(J.head.extra_len);e0.arraySet(J.head.extra,q,Y,M,T)}if(J.flags&512)J.check=I2(J.check,q,M,Y);B-=M,Y+=M,J.length-=M}if(J.length)break $}J.length=0,J.mode=a9;case a9:if(J.flags&2048){if(B===0)break $;M=0;do if(T=q[Y+M++],J.head&&T&&J.length<65536)J.head.name+=String.fromCharCode(T);while(T&&M<B);if(J.flags&512)J.check=I2(J.check,q,M,Y);if(B-=M,Y+=M,T)break $}else if(J.head)J.head.name=null;J.length=0,J.mode=s9;case s9:if(J.flags&4096){if(B===0)break $;M=0;do if(T=q[Y+M++],J.head&&T&&J.length<65536)J.head.comment+=String.fromCharCode(T);while(T&&M<B);if(J.flags&512)J.check=I2(J.check,q,M,Y);if(B-=M,Y+=M,T)break $}else if(J.head)J.head.comment=null;J.mode=t9;case t9:if(J.flags&512){while(V<16){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(U!==(J.check&65535)){$.msg="header crc mismatch",J.mode=T0;break}U=0,V=0}if(J.head)J.head.hcrc=J.flags>>9&1,J.head.done=!0;$.adler=J.check=0,J.mode=m2;break;case e9:while(V<32){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}$.adler=J.check=HQ(U),U=0,V=0,J.mode=c8;case c8:if(J.havedict===0)return $.next_out=G,$.avail_out=W,$.next_in=Y,$.avail_in=B,J.hold=U,J.bits=V,EB;$.adler=J.check=1,J.mode=m2;case m2:if(Q===IB||Q===h8)break $;case N4:if(J.last){U>>>=V&7,V-=V&7,J.mode=D4;break}while(V<3){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}switch(J.last=U&1,U>>>=1,V-=1,U&3){case 0:J.mode=$Q;break;case 1:if(_B(J),J.mode=m8,Q===h8){U>>>=2,V-=2;break $}break;case 2:J.mode=JQ;break;case 3:$.msg="invalid block type",J.mode=T0}U>>>=2,V-=2;break;case $Q:U>>>=V&7,V-=V&7;while(V<32){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if((U&65535)!==(U>>>16^65535)){$.msg="invalid stored block lengths",J.mode=T0;break}if(J.length=U&65535,U=0,V=0,J.mode=A4,Q===h8)break $;case A4:J.mode=QQ;case QQ:if(M=J.length,M){if(M>B)M=B;if(M>W)M=W;if(M===0)break $;e0.arraySet(X,q,Y,M,G),B-=M,Y+=M,W-=M,G+=M,J.length-=M;break}J.mode=m2;break;case JQ:while(V<14){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.nlen=(U&31)+257,U>>>=5,V-=5,J.ndist=(U&31)+1,U>>>=5,V-=5,J.ncode=(U&15)+4,U>>>=4,V-=4,J.nlen>286||J.ndist>30){$.msg="too many length or distance symbols",J.mode=T0;break}J.have=0,J.mode=qQ;case qQ:while(J.have<J.ncode){while(V<3){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}J.lens[N[J.have++]]=U&7,U>>>=3,V-=3}while(J.have<19)J.lens[N[J.have++]]=0;if(J.lencode=J.lendyn,J.lenbits=7,E={bits:J.lenbits},l=o6(RB,J.lens,0,19,J.lencode,0,J.work,E),J.lenbits=E.bits,l){$.msg="invalid code lengths set",J.mode=T0;break}J.have=0,J.mode=XQ;case XQ:while(J.have<J.nlen+J.ndist){for(;;){if(A=J.lencode[U&(1<<J.lenbits)-1],P=A>>>24,K=A>>>16&255,F=A&65535,P<=V)break;if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(F<16)U>>>=P,V-=P,J.lens[J.have++]=F;else{if(F===16){C=P+2;while(V<C){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(U>>>=P,V-=P,J.have===0){$.msg="invalid bit length repeat",J.mode=T0;break}T=J.lens[J.have-1],M=3+(U&3),U>>>=2,V-=2}else if(F===17){C=P+3;while(V<C){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}U>>>=P,V-=P,T=0,M=3+(U&7),U>>>=3,V-=3}else{C=P+7;while(V<C){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}U>>>=P,V-=P,T=0,M=11+(U&127),U>>>=7,V-=7}if(J.have+M>J.nlen+J.ndist){$.msg="invalid bit length repeat",J.mode=T0;break}while(M--)J.lens[J.have++]=T}}if(J.mode===T0)break;if(J.lens[256]===0){$.msg="invalid code -- missing end-of-block",J.mode=T0;break}if(J.lenbits=9,E={bits:J.lenbits},l=o6(MQ,J.lens,0,J.nlen,J.lencode,0,J.work,E),J.lenbits=E.bits,l){$.msg="invalid literal/lengths set",J.mode=T0;break}if(J.distbits=6,J.distcode=J.distdyn,E={bits:J.distbits},l=o6(wQ,J.lens,J.nlen,J.ndist,J.distcode,0,J.work,E),J.distbits=E.bits,l){$.msg="invalid distances set",J.mode=T0;break}if(J.mode=m8,Q===h8)break $;case m8:J.mode=u8;case u8:if(B>=6&&W>=258){if($.next_out=G,$.avail_out=W,$.next_in=Y,$.avail_in=B,J.hold=U,J.bits=V,CB($,w),G=$.next_out,X=$.output,W=$.avail_out,Y=$.next_in,q=$.input,B=$.avail_in,U=J.hold,V=J.bits,J.mode===m2)J.back=-1;break}J.back=0;for(;;){if(A=J.lencode[U&(1<<J.lenbits)-1],P=A>>>24,K=A>>>16&255,F=A&65535,P<=V)break;if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(K&&(K&240)===0){z=P,D=K,_=F;for(;;){if(A=J.lencode[_+((U&(1<<z+D)-1)>>z)],P=A>>>24,K=A>>>16&255,F=A&65535,z+P<=V)break;if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}U>>>=z,V-=z,J.back+=z}if(U>>>=P,V-=P,J.back+=P,J.length=F,K===0){J.mode=WQ;break}if(K&32){J.back=-1,J.mode=m2;break}if(K&64){$.msg="invalid literal/length code",J.mode=T0;break}J.extra=K&15,J.mode=YQ;case YQ:if(J.extra){C=J.extra;while(V<C){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}J.length+=U&(1<<J.extra)-1,U>>>=J.extra,V-=J.extra,J.back+=J.extra}J.was=J.length,J.mode=GQ;case GQ:for(;;){if(A=J.distcode[U&(1<<J.distbits)-1],P=A>>>24,K=A>>>16&255,F=A&65535,P<=V)break;if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if((K&240)===0){z=P,D=K,_=F;for(;;){if(A=J.distcode[_+((U&(1<<z+D)-1)>>z)],P=A>>>24,K=A>>>16&255,F=A&65535,z+P<=V)break;if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}U>>>=z,V-=z,J.back+=z}if(U>>>=P,V-=P,J.back+=P,K&64){$.msg="invalid distance code",J.mode=T0;break}J.offset=F,J.extra=K&15,J.mode=BQ;case BQ:if(J.extra){C=J.extra;while(V<C){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}J.offset+=U&(1<<J.extra)-1,U>>>=J.extra,V-=J.extra,J.back+=J.extra}if(J.offset>J.dmax){$.msg="invalid distance too far back",J.mode=T0;break}J.mode=UQ;case UQ:if(W===0)break $;if(M=w-W,J.offset>M){if(M=J.offset-M,M>J.whave){if(J.sane){$.msg="invalid distance too far back",J.mode=T0;break}}if(M>J.wnext)M-=J.wnext,y=J.wsize-M;else y=J.wnext-M;if(M>J.length)M=J.length;x=J.window}else x=X,y=G-J.offset,M=J.length;if(M>W)M=W;W-=M,J.length-=M;do X[G++]=x[y++];while(--M);if(J.length===0)J.mode=u8;break;case WQ:if(W===0)break $;X[G++]=J.length,W--,J.mode=u8;break;case D4:if(J.wrap){while(V<32){if(B===0)break $;B--,U|=q[Y++]<<V,V+=8}if(w-=W,$.total_out+=w,J.total+=w,w)$.adler=J.check=J.flags?I2(J.check,X,w,G-w):R4(J.check,X,w,G-w);if(w=W,(J.flags?U:HQ(U))!==J.check){$.msg="incorrect data check",J.mode=T0;break}U=0,V=0}J.mode=VQ;case VQ:if(J.wrap&&J.flags){while(V<32){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(U!==(J.total&4294967295)){$.msg="incorrect length check",J.mode=T0;break}U=0,V=0}J.mode=KQ;case KQ:l=SB;break $;case T0:l=FQ;break $;case S4:return I4;case kB:default:return B2}if($.next_out=G,$.avail_out=W,$.next_in=Y,$.avail_in=B,J.hold=U,J.bits=V,J.wsize||w!==$.avail_out&&J.mode<T0&&(J.mode<D4||Q!==p9)){if(DQ($,$.output,$.next_out,w-$.avail_out))return J.mode=S4,I4}if(L-=$.avail_in,w-=$.avail_out,$.total_in+=L,$.total_out+=w,J.total+=w,J.wrap&&w)$.adler=J.check=J.flags?I2(J.check,X,w,$.next_out-w):R4(J.check,X,w,$.next_out-w);if($.data_type=J.bits+(J.last?64:0)+(J.mode===m2?128:0)+(J.mode===m8||J.mode===A4?256:0),(L===0&&w===0||Q===p9)&&l===I1)l=vB;return l}function hB($){if(!$||!$.state)return B2;var Q=$.state;if(Q.window)Q.window=null;return $.state=null,I1}function mB($,Q){var J;if(!$||!$.state)return B2;if(J=$.state,(J.wrap&2)===0)return B2;return J.head=Q,Q.done=!1,I1}function uB($,Q){var J=Q.length,q,X,Y;if(!$||!$.state)return B2;if(q=$.state,q.wrap!==0&&q.mode!==c8)return B2;if(q.mode===c8){if(X=1,X=R4(X,Q,J,0),X!==q.check)return FQ}if(Y=DQ($,Q,J,J),Y)return q.mode=S4,I4;return q.havedict=1,I1}cB.inflateReset=OQ;cB.inflateReset2=NQ;cB.inflateResetKeep=zQ;cB.inflateInit=yB;cB.inflateInit2=AQ;cB.inflate=bB;cB.inflateEnd=hB;cB.inflateGetHeader=mB;cB.inflateSetDictionary=uB;cB.inflateInfo="pako inflate (from Nodeca project)"});var E4=j0((vK,CQ)=>{CQ.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}});var IQ=j0((kK,RQ)=>{function eB(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}RQ.exports=eB});var EQ=j0((qU)=>{var t1=PQ(),r6=b2(),p8=j4(),f0=E4(),v4=k8(),$U=M4(),QU=IQ(),SQ=Object.prototype.toString;function S1($){if(!(this instanceof S1))return new S1($);this.options=r6.assign({chunkSize:16384,windowBits:0,to:""},$||{});var Q=this.options;if(Q.raw&&Q.windowBits>=0&&Q.windowBits<16){if(Q.windowBits=-Q.windowBits,Q.windowBits===0)Q.windowBits=-15}if(Q.windowBits>=0&&Q.windowBits<16&&!($&&$.windowBits))Q.windowBits+=32;if(Q.windowBits>15&&Q.windowBits<48){if((Q.windowBits&15)===0)Q.windowBits|=15}this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new $U,this.strm.avail_out=0;var J=t1.inflateInit2(this.strm,Q.windowBits);if(J!==f0.Z_OK)throw Error(v4[J]);if(this.header=new QU,t1.inflateGetHeader(this.strm,this.header),Q.dictionary){if(typeof Q.dictionary==="string")Q.dictionary=p8.string2buf(Q.dictionary);else if(SQ.call(Q.dictionary)==="[object ArrayBuffer]")Q.dictionary=new Uint8Array(Q.dictionary);if(Q.raw){if(J=t1.inflateSetDictionary(this.strm,Q.dictionary),J!==f0.Z_OK)throw Error(v4[J])}}}S1.prototype.push=function($,Q){var J=this.strm,q=this.options.chunkSize,X=this.options.dictionary,Y,G,B,W,U,V=!1;if(this.ended)return!1;if(G=Q===~~Q?Q:Q===!0?f0.Z_FINISH:f0.Z_NO_FLUSH,typeof $==="string")J.input=p8.binstring2buf($);else if(SQ.call($)==="[object ArrayBuffer]")J.input=new Uint8Array($);else J.input=$;J.next_in=0,J.avail_in=J.input.length;do{if(J.avail_out===0)J.output=new r6.Buf8(q),J.next_out=0,J.avail_out=q;if(Y=t1.inflate(J,f0.Z_NO_FLUSH),Y===f0.Z_NEED_DICT&&X)Y=t1.inflateSetDictionary(this.strm,X);if(Y===f0.Z_BUF_ERROR&&V===!0)Y=f0.Z_OK,V=!1;if(Y!==f0.Z_STREAM_END&&Y!==f0.Z_OK)return this.onEnd(Y),this.ended=!0,!1;if(J.next_out){if(J.avail_out===0||Y===f0.Z_STREAM_END||J.avail_in===0&&(G===f0.Z_FINISH||G===f0.Z_SYNC_FLUSH))if(this.options.to==="string"){if(B=p8.utf8border(J.output,J.next_out),W=J.next_out-B,U=p8.buf2string(J.output,B),J.next_out=W,J.avail_out=q-W,W)r6.arraySet(J.output,J.output,B,W,0);this.onData(U)}else this.onData(r6.shrinkBuf(J.output,J.next_out))}if(J.avail_in===0&&J.avail_out===0)V=!0}while((J.avail_in>0||J.avail_out===0)&&Y!==f0.Z_STREAM_END);if(Y===f0.Z_STREAM_END)G=f0.Z_FINISH;if(G===f0.Z_FINISH)return Y=t1.inflateEnd(this.strm),this.onEnd(Y),this.ended=!0,Y===f0.Z_OK;if(G===f0.Z_SYNC_FLUSH)return this.onEnd(f0.Z_OK),J.avail_out=0,!0;return!0};S1.prototype.onData=function($){this.chunks.push($)};S1.prototype.onEnd=function($){if($===f0.Z_OK)if(this.options.to==="string")this.result=this.chunks.join("");else this.result=r6.flattenChunks(this.chunks);this.chunks=[],this.err=$,this.msg=this.strm.msg};function k4($,Q){var J=new S1(Q);if(J.push($,!0),J.err)throw J.msg||v4[J.err];return J.result}function JU($,Q){return Q=Q||{},Q.raw=!0,k4($,Q)}qU.Inflate=S1;qU.inflate=k4;qU.inflateRaw=JU;qU.ungzip=k4});var TQ=j0((ZK,kQ)=>{var UU=b2().assign,WU=g9(),VU=EQ(),KU=E4(),vQ={};UU(vQ,WU,VU,KU);kQ.exports=vQ});var gQ=j0((wU)=>{var HU=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Uint32Array<"u",jU=TQ(),ZQ=g0(),l8=t0(),MU=HU?"uint8array":"array";wU.magic="\b\x00";function E1($,Q){l8.call(this,"FlateWorker/"+$),this._pako=null,this._pakoAction=$,this._pakoOptions=Q,this.meta={}}ZQ.inherits(E1,l8);E1.prototype.processChunk=function($){if(this.meta=$.meta,this._pako===null)this._createPako();this._pako.push(ZQ.transformTo(MU,$.data),!1)};E1.prototype.flush=function(){if(l8.prototype.flush.call(this),this._pako===null)this._createPako();this._pako.push([],!0)};E1.prototype.cleanUp=function(){l8.prototype.cleanUp.call(this),this._pako=null};E1.prototype._createPako=function(){this._pako=new jU[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var $=this;this._pako.onData=function(Q){$.push({data:Q,meta:$.meta})}};wU.compressWorker=function($){return new E1("Deflate",$)};wU.uncompressWorker=function(){return new E1("Inflate",{})}});var T4=j0((OU)=>{var xQ=t0();OU.STORE={magic:"\x00\x00",compressWorker:function(){return new xQ("STORE compression")},uncompressWorker:function(){return new xQ("STORE decompression")}};OU.DEFLATE=gQ()});var Z4=j0((DU)=>{DU.LOCAL_FILE_HEADER="PK\x03\x04";DU.CENTRAL_FILE_HEADER="PK\x01\x02";DU.CENTRAL_DIRECTORY_END="PK\x05\x06";DU.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x06\x07";DU.ZIP64_CENTRAL_DIRECTORY_END="PK\x06\x06";DU.DATA_DESCRIPTOR="PK\x07\b"});var bQ=j0((yK,_Q)=>{var e1=g0(),$6=t0(),g4=p1(),fQ=I8(),d8=Z4(),v0=function($,Q){var J="",q;for(q=0;q<Q;q++)J+=String.fromCharCode($&255),$=$>>>8;return J},vU=function($,Q){var J=$;if(!$)J=Q?16893:33204;return(J&65535)<<16},kU=function($){return($||0)&63},yQ=function($,Q,J,q,X,Y){var{file:G,compression:B}=$,W=Y!==g4.utf8encode,U=e1.transformTo("string",Y(G.name)),V=e1.transformTo("string",g4.utf8encode(G.name)),L=G.comment,w=e1.transformTo("string",Y(L)),M=e1.transformTo("string",g4.utf8encode(L)),y=V.length!==G.name.length,x=M.length!==L.length,A,P,K="",F="",z="",D=G.dir,_=G.date,T={crc32:0,compressedSize:0,uncompressedSize:0};if(!Q||J)T.crc32=$.crc32,T.compressedSize=$.compressedSize,T.uncompressedSize=$.uncompressedSize;var l=0;if(Q)l|=8;if(!W&&(y||x))l|=2048;var S=0,E=0;if(D)S|=16;if(X==="UNIX")E=798,S|=vU(G.unixPermissions,D);else E=20,S|=kU(G.dosPermissions,D);if(A=_.getUTCHours(),A=A<<6,A=A|_.getUTCMinutes(),A=A<<5,A=A|_.getUTCSeconds()/2,P=_.getUTCFullYear()-1980,P=P<<4,P=P|_.getUTCMonth()+1,P=P<<5,P=P|_.getUTCDate(),y)F=v0(1,1)+v0(fQ(U),4)+V,K+="up"+v0(F.length,2)+F;if(x)z=v0(1,1)+v0(fQ(w),4)+M,K+="uc"+v0(z.length,2)+z;var C="";C+=`
|
|
3
|
-
\x00`,C+=v0(l,2),C+=B.magic,C+=v0(A,2),C+=v0(P,2),C+=v0(T.crc32,4),C+=v0(T.compressedSize,4),C+=v0(T.uncompressedSize,4),C+=v0(U.length,2),C+=v0(K.length,2);var N=d8.LOCAL_FILE_HEADER+C+U+K,Z=d8.CENTRAL_FILE_HEADER+v0(E,2)+C+v0(w.length,2)+"\x00\x00\x00\x00"+v0(S,4)+v0(q,4)+U+K+w;return{fileRecord:N,dirRecord:Z}},TU=function($,Q,J,q,X){var Y="",G=e1.transformTo("string",X(q));return Y=d8.CENTRAL_DIRECTORY_END+"\x00\x00\x00\x00"+v0($,2)+v0($,2)+v0(Q,4)+v0(J,4)+v0(G.length,2)+G,Y},ZU=function($){var Q="";return Q=d8.DATA_DESCRIPTOR+v0($.crc32,4)+v0($.compressedSize,4)+v0($.uncompressedSize,4),Q};function V2($,Q,J,q){$6.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=Q,this.zipPlatform=J,this.encodeFileName=q,this.streamFiles=$,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}e1.inherits(V2,$6);V2.prototype.push=function($){var Q=$.meta.percent||0,J=this.entriesCount,q=this._sources.length;if(this.accumulate)this.contentBuffer.push($);else this.bytesWritten+=$.data.length,$6.prototype.push.call(this,{data:$.data,meta:{currentFile:this.currentFile,percent:J?(Q+100*(J-q-1))/J:100}})};V2.prototype.openedSource=function($){this.currentSourceOffset=this.bytesWritten,this.currentFile=$.file.name;var Q=this.streamFiles&&!$.file.dir;if(Q){var J=yQ($,Q,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:J.fileRecord,meta:{percent:0}})}else this.accumulate=!0};V2.prototype.closedSource=function($){this.accumulate=!1;var Q=this.streamFiles&&!$.file.dir,J=yQ($,Q,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(J.dirRecord),Q)this.push({data:ZU($),meta:{percent:100}});else{this.push({data:J.fileRecord,meta:{percent:0}});while(this.contentBuffer.length)this.push(this.contentBuffer.shift())}this.currentFile=null};V2.prototype.flush=function(){var $=this.bytesWritten;for(var Q=0;Q<this.dirRecords.length;Q++)this.push({data:this.dirRecords[Q],meta:{percent:100}});var J=this.bytesWritten-$,q=TU(this.dirRecords.length,J,$,this.zipComment,this.encodeFileName);this.push({data:q,meta:{percent:100}})};V2.prototype.prepareNextSource=function(){if(this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused)this.previous.pause();else this.previous.resume()};V2.prototype.registerPrevious=function($){this._sources.push($);var Q=this;return $.on("data",function(J){Q.processChunk(J)}),$.on("end",function(){if(Q.closedSource(Q.previous.streamInfo),Q._sources.length)Q.prepareNextSource();else Q.end()}),$.on("error",function(J){Q.error(J)}),this};V2.prototype.resume=function(){if(!$6.prototype.resume.call(this))return!1;if(!this.previous&&this._sources.length)return this.prepareNextSource(),!0;if(!this.previous&&!this._sources.length&&!this.generatedError)return this.end(),!0};V2.prototype.error=function($){var Q=this._sources;if(!$6.prototype.error.call(this,$))return!1;for(var J=0;J<Q.length;J++)try{Q[J].error($)}catch(q){}return!0};V2.prototype.lock=function(){$6.prototype.lock.call(this);var $=this._sources;for(var Q=0;Q<$.length;Q++)$[Q].lock()};_Q.exports=V2});var hQ=j0((yU)=>{var gU=T4(),xU=bQ(),fU=function($,Q){var J=$||Q,q=gU[J];if(!q)throw Error(J+" is not a valid compression method !");return q};yU.generateWorker=function($,Q,J){var q=new xU(Q.streamFiles,J,Q.platform,Q.encodeFileName),X=0;try{$.forEach(function(Y,G){X++;var B=fU(G.options.compression,Q.compression),W=G.options.compressionOptions||Q.compressionOptions||{},U=G.dir,V=G.date;G._compressWorker(B,W).withStreamInfo("file",{name:Y,dir:U,date:V,comment:G.comment||"",unixPermissions:G.unixPermissions,dosPermissions:G.dosPermissions}).pipe(q)}),q.entriesCount=X}catch(Y){q.error(Y)}return q}});var uQ=j0((bK,mQ)=>{var bU=g0(),i8=t0();function a6($,Q){i8.call(this,"Nodejs stream input adapter for "+$),this._upstreamEnded=!1,this._bindStream(Q)}bU.inherits(a6,i8);a6.prototype._bindStream=function($){var Q=this;this._stream=$,$.pause(),$.on("data",function(J){Q.push({data:J,meta:{percent:0}})}).on("error",function(J){if(Q.isPaused)this.generatedError=J;else Q.error(J)}).on("end",function(){if(Q.isPaused)Q._upstreamEnded=!0;else Q.end()})};a6.prototype.pause=function(){if(!i8.prototype.pause.call(this))return!1;return this._stream.pause(),!0};a6.prototype.resume=function(){if(!i8.prototype.resume.call(this))return!1;if(this._upstreamEnded)this.end();else this._stream.resume();return!0};mQ.exports=a6});var sQ=j0((hK,aQ)=>{var hU=p1(),s6=g0(),dQ=t0(),mU=_5(),iQ=b5(),cQ=S8(),uU=p$(),cU=hQ(),pQ=E6(),pU=uQ(),nQ=function($,Q,J){var q=s6.getTypeOf(Q),X,Y=s6.extend(J||{},iQ);if(Y.date=Y.date||new Date,Y.compression!==null)Y.compression=Y.compression.toUpperCase();if(typeof Y.unixPermissions==="string")Y.unixPermissions=parseInt(Y.unixPermissions,8);if(Y.unixPermissions&&Y.unixPermissions&16384)Y.dir=!0;if(Y.dosPermissions&&Y.dosPermissions&16)Y.dir=!0;if(Y.dir)$=oQ($);if(Y.createFolders&&(X=lU($)))rQ.call(this,X,!0);var G=q==="string"&&Y.binary===!1&&Y.base64===!1;if(!J||typeof J.binary>"u")Y.binary=!G;var B=Q instanceof cQ&&Q.uncompressedSize===0;if(B||Y.dir||!Q||Q.length===0)Y.base64=!1,Y.binary=!0,Q="",Y.compression="STORE",q="string";var W=null;if(Q instanceof cQ||Q instanceof dQ)W=Q;else if(pQ.isNode&&pQ.isStream(Q))W=new pU($,Q);else W=s6.prepareContent($,Q,Y.binary,Y.optimizedBinaryString,Y.base64);var U=new uU($,W,Y);this.files[$]=U},lU=function($){if($.slice(-1)==="/")$=$.substring(0,$.length-1);var Q=$.lastIndexOf("/");return Q>0?$.substring(0,Q):""},oQ=function($){if($.slice(-1)!=="/")$+="/";return $},rQ=function($,Q){if(Q=typeof Q<"u"?Q:iQ.createFolders,$=oQ($),!this.files[$])nQ.call(this,$,null,{dir:!0,createFolders:Q});return this.files[$]};function lQ($){return Object.prototype.toString.call($)==="[object RegExp]"}var dU={load:function(){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function($){var Q,J,q;for(Q in this.files)if(q=this.files[Q],J=Q.slice(this.root.length,Q.length),J&&Q.slice(0,this.root.length)===this.root)$(J,q)},filter:function($){var Q=[];return this.forEach(function(J,q){if($(J,q))Q.push(q)}),Q},file:function($,Q,J){if(arguments.length===1)if(lQ($)){var q=$;return this.filter(function(Y,G){return!G.dir&&q.test(Y)})}else{var X=this.files[this.root+$];if(X&&!X.dir)return X;else return null}else $=this.root+$,nQ.call(this,$,Q,J);return this},folder:function($){if(!$)return this;if(lQ($))return this.filter(function(X,Y){return Y.dir&&$.test(X)});var Q=this.root+$,J=rQ.call(this,Q),q=this.clone();return q.root=J.name,q},remove:function($){$=this.root+$;var Q=this.files[$];if(!Q){if($.slice(-1)!=="/")$+="/";Q=this.files[$]}if(Q&&!Q.dir)delete this.files[$];else{var J=this.filter(function(X,Y){return Y.name.slice(0,$.length)===$});for(var q=0;q<J.length;q++)delete this.files[J[q].name]}return this},generate:function(){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function($){var Q,J={};try{if(J=s6.extend($||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:hU.utf8encode}),J.type=J.type.toLowerCase(),J.compression=J.compression.toUpperCase(),J.type==="binarystring")J.type="string";if(!J.type)throw Error("No output type specified.");if(s6.checkSupport(J.type),J.platform==="darwin"||J.platform==="freebsd"||J.platform==="linux"||J.platform==="sunos")J.platform="UNIX";if(J.platform==="win32")J.platform="DOS";var q=J.comment||this.comment||"";Q=cU.generateWorker(this,J,q)}catch(X){Q=new dQ("error"),Q.error(X)}return new mU(Q,J.type||"string",J.mimeType)},generateAsync:function($,Q){return this.generateInternalStream($).accumulate(Q)},generateNodeStream:function($,Q){if($=$||{},!$.type)$.type="nodebuffer";return this.generateInternalStream($).toNodejsStream(Q)}};aQ.exports=dU});var x4=j0((mK,eQ)=>{var iU=g0();function tQ($){this.data=$,this.length=$.length,this.index=0,this.zero=0}tQ.prototype={checkOffset:function($){this.checkIndex(this.index+$)},checkIndex:function($){if(this.length<this.zero+$||$<0)throw Error("End of data reached (data length = "+this.length+", asked index = "+$+"). Corrupted zip ?")},setIndex:function($){this.checkIndex($),this.index=$},skip:function($){this.setIndex(this.index+$)},byteAt:function(){},readInt:function($){var Q=0,J;this.checkOffset($);for(J=this.index+$-1;J>=this.index;J--)Q=(Q<<8)+this.byteAt(J);return this.index+=$,Q},readString:function($){return iU.transformTo("string",this.readData($))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var $=this.readInt(4);return new Date(Date.UTC(($>>25&127)+1980,($>>21&15)-1,$>>16&31,$>>11&31,$>>5&63,($&31)<<1))}};eQ.exports=tQ});var f4=j0((uK,QJ)=>{var $J=x4(),nU=g0();function Q6($){$J.call(this,$);for(var Q=0;Q<this.data.length;Q++)$[Q]=$[Q]&255}nU.inherits(Q6,$J);Q6.prototype.byteAt=function($){return this.data[this.zero+$]};Q6.prototype.lastIndexOfSignature=function($){var Q=$.charCodeAt(0),J=$.charCodeAt(1),q=$.charCodeAt(2),X=$.charCodeAt(3);for(var Y=this.length-4;Y>=0;--Y)if(this.data[Y]===Q&&this.data[Y+1]===J&&this.data[Y+2]===q&&this.data[Y+3]===X)return Y-this.zero;return-1};Q6.prototype.readAndCheckSignature=function($){var Q=$.charCodeAt(0),J=$.charCodeAt(1),q=$.charCodeAt(2),X=$.charCodeAt(3),Y=this.readData(4);return Q===Y[0]&&J===Y[1]&&q===Y[2]&&X===Y[3]};Q6.prototype.readData=function($){if(this.checkOffset($),$===0)return[];var Q=this.data.slice(this.zero+this.index,this.zero+this.index+$);return this.index+=$,Q};QJ.exports=Q6});var XJ=j0((cK,qJ)=>{var JJ=x4(),oU=g0();function J6($){JJ.call(this,$)}oU.inherits(J6,JJ);J6.prototype.byteAt=function($){return this.data.charCodeAt(this.zero+$)};J6.prototype.lastIndexOfSignature=function($){return this.data.lastIndexOf($)-this.zero};J6.prototype.readAndCheckSignature=function($){var Q=this.readData(4);return $===Q};J6.prototype.readData=function($){this.checkOffset($);var Q=this.data.slice(this.zero+this.index,this.zero+this.index+$);return this.index+=$,Q};qJ.exports=J6});var _4=j0((pK,GJ)=>{var YJ=f4(),rU=g0();function y4($){YJ.call(this,$)}rU.inherits(y4,YJ);y4.prototype.readData=function($){if(this.checkOffset($),$===0)return new Uint8Array(0);var Q=this.data.subarray(this.zero+this.index,this.zero+this.index+$);return this.index+=$,Q};GJ.exports=y4});var WJ=j0((lK,UJ)=>{var BJ=_4(),aU=g0();function b4($){BJ.call(this,$)}aU.inherits(b4,BJ);b4.prototype.readData=function($){this.checkOffset($);var Q=this.data.slice(this.zero+this.index,this.zero+this.index+$);return this.index+=$,Q};UJ.exports=b4});var h4=j0((dK,KJ)=>{var n8=g0(),VJ=_2(),sU=f4(),tU=XJ(),eU=WJ(),$W=_4();KJ.exports=function($){var Q=n8.getTypeOf($);if(n8.checkSupport(Q),Q==="string"&&!VJ.uint8array)return new tU($);if(Q==="nodebuffer")return new eU($);if(VJ.uint8array)return new $W(n8.transformTo("uint8array",$));return new sU(n8.transformTo("array",$))}});var wJ=j0((iK,MJ)=>{var m4=h4(),q1=g0(),QW=S8(),HJ=I8(),o8=p1(),r8=T4(),JW=_2(),qW=0,XW=3,YW=function($){for(var Q in r8){if(!Object.prototype.hasOwnProperty.call(r8,Q))continue;if(r8[Q].magic===$)return r8[Q]}return null};function jJ($,Q){this.options=$,this.loadOptions=Q}jJ.prototype={isEncrypted:function(){return(this.bitFlag&1)===1},useUTF8:function(){return(this.bitFlag&2048)===2048},readLocalPart:function($){var Q,J;if($.skip(22),this.fileNameLength=$.readInt(2),J=$.readInt(2),this.fileName=$.readData(this.fileNameLength),$.skip(J),this.compressedSize===-1||this.uncompressedSize===-1)throw Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if(Q=YW(this.compressionMethod),Q===null)throw Error("Corrupted zip : compression "+q1.pretty(this.compressionMethod)+" unknown (inner file : "+q1.transformTo("string",this.fileName)+")");this.decompressed=new QW(this.compressedSize,this.uncompressedSize,this.crc32,Q,$.readData(this.compressedSize))},readCentralPart:function($){this.versionMadeBy=$.readInt(2),$.skip(2),this.bitFlag=$.readInt(2),this.compressionMethod=$.readString(2),this.date=$.readDate(),this.crc32=$.readInt(4),this.compressedSize=$.readInt(4),this.uncompressedSize=$.readInt(4);var Q=$.readInt(2);if(this.extraFieldsLength=$.readInt(2),this.fileCommentLength=$.readInt(2),this.diskNumberStart=$.readInt(2),this.internalFileAttributes=$.readInt(2),this.externalFileAttributes=$.readInt(4),this.localHeaderOffset=$.readInt(4),this.isEncrypted())throw Error("Encrypted zip are not supported");$.skip(Q),this.readExtraFields($),this.parseZIP64ExtraField($),this.fileComment=$.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var $=this.versionMadeBy>>8;if(this.dir=this.externalFileAttributes&16?!0:!1,$===qW)this.dosPermissions=this.externalFileAttributes&63;if($===XW)this.unixPermissions=this.externalFileAttributes>>16&65535;if(!this.dir&&this.fileNameStr.slice(-1)==="/")this.dir=!0},parseZIP64ExtraField:function(){if(!this.extraFields[1])return;var $=m4(this.extraFields[1].value);if(this.uncompressedSize===q1.MAX_VALUE_32BITS)this.uncompressedSize=$.readInt(8);if(this.compressedSize===q1.MAX_VALUE_32BITS)this.compressedSize=$.readInt(8);if(this.localHeaderOffset===q1.MAX_VALUE_32BITS)this.localHeaderOffset=$.readInt(8);if(this.diskNumberStart===q1.MAX_VALUE_32BITS)this.diskNumberStart=$.readInt(4)},readExtraFields:function($){var Q=$.index+this.extraFieldsLength,J,q,X;if(!this.extraFields)this.extraFields={};while($.index+4<Q)J=$.readInt(2),q=$.readInt(2),X=$.readData(q),this.extraFields[J]={id:J,length:q,value:X};$.setIndex(Q)},handleUTF8:function(){var $=JW.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=o8.utf8decode(this.fileName),this.fileCommentStr=o8.utf8decode(this.fileComment);else{var Q=this.findExtraFieldUnicodePath();if(Q!==null)this.fileNameStr=Q;else{var J=q1.transformTo($,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(J)}var q=this.findExtraFieldUnicodeComment();if(q!==null)this.fileCommentStr=q;else{var X=q1.transformTo($,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(X)}}},findExtraFieldUnicodePath:function(){var $=this.extraFields[28789];if($){var Q=m4($.value);if(Q.readInt(1)!==1)return null;if(HJ(this.fileName)!==Q.readInt(4))return null;return o8.utf8decode(Q.readData($.length-5))}return null},findExtraFieldUnicodeComment:function(){var $=this.extraFields[25461];if($){var Q=m4($.value);if(Q.readInt(1)!==1)return null;if(HJ(this.fileComment)!==Q.readInt(4))return null;return o8.utf8decode(Q.readData($.length-5))}return null}};MJ.exports=jJ});var zJ=j0((nK,LJ)=>{var GW=h4(),u2=g0(),K2=Z4(),BW=wJ(),UW=_2();function FJ($){this.files=[],this.loadOptions=$}FJ.prototype={checkSignature:function($){if(!this.reader.readAndCheckSignature($)){this.reader.index-=4;var Q=this.reader.readString(4);throw Error("Corrupted zip or bug: unexpected signature ("+u2.pretty(Q)+", expected "+u2.pretty($)+")")}},isSignature:function($,Q){var J=this.reader.index;this.reader.setIndex($);var q=this.reader.readString(4),X=q===Q;return this.reader.setIndex(J),X},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var $=this.reader.readData(this.zipCommentLength),Q=UW.uint8array?"uint8array":"array",J=u2.transformTo(Q,$);this.zipComment=this.loadOptions.decodeFileName(J)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};var $=this.zip64EndOfCentralSize-44,Q=0,J,q,X;while(Q<$)J=this.reader.readInt(2),q=this.reader.readInt(4),X=this.reader.readData(q),this.zip64ExtensibleData[J]={id:J,length:q,value:X}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),this.disksCount>1)throw Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var $,Q;for($=0;$<this.files.length;$++)Q=this.files[$],this.reader.setIndex(Q.localHeaderOffset),this.checkSignature(K2.LOCAL_FILE_HEADER),Q.readLocalPart(this.reader),Q.handleUTF8(),Q.processAttributes()},readCentralDir:function(){var $;this.reader.setIndex(this.centralDirOffset);while(this.reader.readAndCheckSignature(K2.CENTRAL_FILE_HEADER))$=new BW({zip64:this.zip64},this.loadOptions),$.readCentralPart(this.reader),this.files.push($);if(this.centralDirRecords!==this.files.length){if(this.centralDirRecords!==0&&this.files.length===0)throw Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)}},readEndOfCentral:function(){var $=this.reader.lastIndexOfSignature(K2.CENTRAL_DIRECTORY_END);if($<0){var Q=!this.isSignature(0,K2.LOCAL_FILE_HEADER);if(Q)throw Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");else throw Error("Corrupted zip: can't find end of central directory")}this.reader.setIndex($);var J=$;if(this.checkSignature(K2.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===u2.MAX_VALUE_16BITS||this.diskWithCentralDirStart===u2.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===u2.MAX_VALUE_16BITS||this.centralDirRecords===u2.MAX_VALUE_16BITS||this.centralDirSize===u2.MAX_VALUE_32BITS||this.centralDirOffset===u2.MAX_VALUE_32BITS){if(this.zip64=!0,$=this.reader.lastIndexOfSignature(K2.ZIP64_CENTRAL_DIRECTORY_LOCATOR),$<0)throw Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex($),this.checkSignature(K2.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,K2.ZIP64_CENTRAL_DIRECTORY_END)){if(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(K2.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0)throw Error("Corrupted zip: can't find the ZIP64 end of central directory")}this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(K2.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var q=this.centralDirOffset+this.centralDirSize;if(this.zip64)q+=20,q+=12+this.zip64EndOfCentralSize;var X=J-q;if(X>0)if(this.isSignature(J,K2.CENTRAL_FILE_HEADER));else this.reader.zero=X;else if(X<0)throw Error("Corrupted zip: missing "+Math.abs(X)+" bytes.")},prepareReader:function($){this.reader=GW($)},load:function($){this.prepareReader($),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}};LJ.exports=FJ});var AJ=j0((oK,NJ)=>{var u4=g0(),a8=m1(),WW=p1(),VW=zJ(),KW=u5(),OJ=E6();function HW($){return new a8.Promise(function(Q,J){var q=$.decompressed.getContentWorker().pipe(new KW);q.on("error",function(X){J(X)}).on("end",function(){if(q.streamInfo.crc32!==$.decompressed.crc32)J(Error("Corrupted zip : CRC32 mismatch"));else Q()}).resume()})}NJ.exports=function($,Q){var J=this;if(Q=u4.extend(Q||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:WW.utf8decode}),OJ.isNode&&OJ.isStream($))return a8.Promise.reject(Error("JSZip can't accept a stream when loading a zip file."));return u4.prepareContent("the loaded zip file",$,!0,Q.optimizedBinaryString,Q.base64).then(function(q){var X=new VW(Q);return X.load(q),X}).then(function(X){var Y=[a8.Promise.resolve(X)],G=X.files;if(Q.checkCRC32)for(var B=0;B<G.length;B++)Y.push(HW(G[B]));return a8.Promise.all(Y)}).then(function(X){var Y=X.shift(),G=Y.files;for(var B=0;B<G.length;B++){var W=G[B],U=W.fileNameStr,V=u4.resolve(W.fileNameStr);if(J.file(V,W.decompressed,{binary:!0,optimizedBinaryString:!0,date:W.date,dir:W.dir,comment:W.fileCommentStr.length?W.fileCommentStr:null,unixPermissions:W.unixPermissions,dosPermissions:W.dosPermissions,createFolders:Q.createFolders}),!W.dir)J.file(V).unsafeOriginalName=U}if(Y.zipComment.length)J.comment=Y.zipComment;return J})}});var PJ=j0((rK,DJ)=>{function U2(){if(!(this instanceof U2))return new U2;if(arguments.length)throw Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var $=new U2;for(var Q in this)if(typeof this[Q]!=="function")$[Q]=this[Q];return $}}U2.prototype=sQ();U2.prototype.loadAsync=AJ();U2.support=_2();U2.defaults=b5();U2.version="3.10.1";U2.loadAsync=function($,Q){return new U2().loadAsync($,Q)};U2.external=m1();DJ.exports=U2});var _J=j0((n4)=>{/*! crc32.js (C) 2014-present SheetJS -- http://sheetjs.com */var yJ;(function($){if(typeof DO_NOT_EXPORT_CRC>"u")if(typeof n4==="object")$(n4);else if(typeof define==="function"&&define.amd)define(function(){var Q={};return $(Q),Q});else $(yJ={});else $(yJ={})})(function($){$.version="1.2.2";function Q(){var T=0,l=Array(256);for(var S=0;S!=256;++S)T=S,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,l[S]=T;return typeof Int32Array<"u"?new Int32Array(l):l}var J=Q();function q(T){var l=0,S=0,E=0,C=typeof Int32Array<"u"?new Int32Array(4096):Array(4096);for(E=0;E!=256;++E)C[E]=T[E];for(E=0;E!=256;++E){S=T[E];for(l=256+E;l<4096;l+=256)S=C[l]=S>>>8^T[S&255]}var N=[];for(E=1;E!=16;++E)N[E-1]=typeof Int32Array<"u"?C.subarray(E*256,E*256+256):C.slice(E*256,E*256+256);return N}var X=q(J),Y=X[0],G=X[1],B=X[2],W=X[3],U=X[4],V=X[5],L=X[6],w=X[7],M=X[8],y=X[9],x=X[10],A=X[11],P=X[12],K=X[13],F=X[14];function z(T,l){var S=l^-1;for(var E=0,C=T.length;E<C;)S=S>>>8^J[(S^T.charCodeAt(E++))&255];return~S}function D(T,l){var S=l^-1,E=T.length-15,C=0;for(;C<E;)S=F[T[C++]^S&255]^K[T[C++]^S>>8&255]^P[T[C++]^S>>16&255]^A[T[C++]^S>>>24]^x[T[C++]]^y[T[C++]]^M[T[C++]]^w[T[C++]]^L[T[C++]]^V[T[C++]]^U[T[C++]]^W[T[C++]]^B[T[C++]]^G[T[C++]]^Y[T[C++]]^J[T[C++]];E+=15;while(C<E)S=S>>>8^J[(S^T[C++])&255];return~S}function _(T,l){var S=l^-1;for(var E=0,C=T.length,N=0,Z=0;E<C;)if(N=T.charCodeAt(E++),N<128)S=S>>>8^J[(S^N)&255];else if(N<2048)S=S>>>8^J[(S^(192|N>>6&31))&255],S=S>>>8^J[(S^(128|N&63))&255];else if(N>=55296&&N<57344)N=(N&1023)+64,Z=T.charCodeAt(E++)&1023,S=S>>>8^J[(S^(240|N>>8&7))&255],S=S>>>8^J[(S^(128|N>>2&63))&255],S=S>>>8^J[(S^(128|Z>>6&15|(N&3)<<4))&255],S=S>>>8^J[(S^(128|Z&63))&255];else S=S>>>8^J[(S^(224|N>>12&15))&255],S=S>>>8^J[(S^(128|N>>6&63))&255],S=S>>>8^J[(S^(128|N&63))&255];return~S}$.table=J,$.bstr=z,$.buf=D,$.str=_})});var pJ=V7(PJ(),1);var jW=new Uint8Array(16);function c4(){return crypto.getRandomValues(jW)}var h0=[];for(let $=0;$<256;++$)h0.push(($+256).toString(16).slice(1));function CJ($,Q=0){return(h0[$[Q+0]]+h0[$[Q+1]]+h0[$[Q+2]]+h0[$[Q+3]]+"-"+h0[$[Q+4]]+h0[$[Q+5]]+"-"+h0[$[Q+6]]+h0[$[Q+7]]+"-"+h0[$[Q+8]]+h0[$[Q+9]]+"-"+h0[$[Q+10]]+h0[$[Q+11]]+h0[$[Q+12]]+h0[$[Q+13]]+h0[$[Q+14]]+h0[$[Q+15]]).toLowerCase()}function MW($,Q,J){if(!Q&&!$&&crypto.randomUUID)return crypto.randomUUID();return wW($,Q,J)}function wW($,Q,J){$=$||{};let q=$.random??$.rng?.()??c4();if(q.length<16)throw Error("Random bytes length must be >= 16");if(q[6]=q[6]&15|64,q[8]=q[8]&63|128,Q){if(J=J||0,J<0||J+16>Q.length)throw RangeError(`UUID byte range ${J}:${J+15} is out of buffer bounds`);for(let X=0;X<16;++X)Q[J+X]=q[X];return Q}return CJ(q)}var q6=MW;var g={};B5(g,{void:()=>eW,util:()=>P0,unknown:()=>sW,union:()=>qV,undefined:()=>oW,tuple:()=>GV,transformer:()=>FV,symbol:()=>nW,string:()=>gJ,strictObject:()=>JV,setErrorMap:()=>zW,set:()=>WV,record:()=>BV,quotelessJson:()=>FW,promise:()=>wV,preprocess:()=>OV,pipeline:()=>NV,ostring:()=>AV,optional:()=>LV,onumber:()=>DV,oboolean:()=>PV,objectUtil:()=>p4,object:()=>QV,number:()=>xJ,nullable:()=>zV,null:()=>rW,never:()=>tW,nativeEnum:()=>MV,nan:()=>lW,map:()=>UV,makeIssue:()=>t6,literal:()=>HV,lazy:()=>KV,late:()=>cW,isValid:()=>X1,isDirty:()=>t8,isAsync:()=>Y6,isAborted:()=>s8,intersection:()=>YV,instanceof:()=>pW,getParsedType:()=>S2,getErrorMap:()=>X6,function:()=>VV,enum:()=>jV,effect:()=>FV,discriminatedUnion:()=>XV,defaultErrorMap:()=>c2,datetimeRegex:()=>kJ,date:()=>iW,custom:()=>ZJ,coerce:()=>CV,boolean:()=>fJ,bigint:()=>dW,array:()=>$V,any:()=>aW,addIssueToContext:()=>X0,ZodVoid:()=>$8,ZodUnknown:()=>Y1,ZodUnion:()=>K6,ZodUndefined:()=>W6,ZodType:()=>D0,ZodTuple:()=>v2,ZodTransformer:()=>F2,ZodSymbol:()=>e6,ZodString:()=>H2,ZodSet:()=>Z1,ZodSchema:()=>D0,ZodRecord:()=>Q8,ZodReadonly:()=>z6,ZodPromise:()=>g1,ZodPipeline:()=>X8,ZodParsedType:()=>$0,ZodOptional:()=>M2,ZodObject:()=>x0,ZodNumber:()=>G1,ZodNullable:()=>l2,ZodNull:()=>V6,ZodNever:()=>E2,ZodNativeEnum:()=>w6,ZodNaN:()=>q8,ZodMap:()=>J8,ZodLiteral:()=>M6,ZodLazy:()=>j6,ZodIssueCode:()=>o,ZodIntersection:()=>H6,ZodFunction:()=>B6,ZodFirstPartyTypeKind:()=>F0,ZodError:()=>s0,ZodEnum:()=>U1,ZodEffects:()=>F2,ZodDiscriminatedUnion:()=>e8,ZodDefault:()=>F6,ZodDate:()=>k1,ZodCatch:()=>L6,ZodBranded:()=>$5,ZodBoolean:()=>U6,ZodBigInt:()=>B1,ZodArray:()=>j2,ZodAny:()=>T1,Schema:()=>D0,ParseStatus:()=>m0,OK:()=>l0,NEVER:()=>RV,INVALID:()=>w0,EMPTY_PATH:()=>OW,DIRTY:()=>v1,BRAND:()=>uW});var P0;(function($){$.assertEqual=(X)=>{};function Q(X){}$.assertIs=Q;function J(X){throw Error()}$.assertNever=J,$.arrayToEnum=(X)=>{let Y={};for(let G of X)Y[G]=G;return Y},$.getValidEnumValues=(X)=>{let Y=$.objectKeys(X).filter((B)=>typeof X[X[B]]!=="number"),G={};for(let B of Y)G[B]=X[B];return $.objectValues(G)},$.objectValues=(X)=>{return $.objectKeys(X).map(function(Y){return X[Y]})},$.objectKeys=typeof Object.keys==="function"?(X)=>Object.keys(X):(X)=>{let Y=[];for(let G in X)if(Object.prototype.hasOwnProperty.call(X,G))Y.push(G);return Y},$.find=(X,Y)=>{for(let G of X)if(Y(G))return G;return},$.isInteger=typeof Number.isInteger==="function"?(X)=>Number.isInteger(X):(X)=>typeof X==="number"&&Number.isFinite(X)&&Math.floor(X)===X;function q(X,Y=" | "){return X.map((G)=>typeof G==="string"?`'${G}'`:G).join(Y)}$.joinValues=q,$.jsonStringifyReplacer=(X,Y)=>{if(typeof Y==="bigint")return Y.toString();return Y}})(P0||(P0={}));var p4;(function($){$.mergeShapes=(Q,J)=>{return{...Q,...J}}})(p4||(p4={}));var $0=P0.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),S2=($)=>{switch(typeof $){case"undefined":return $0.undefined;case"string":return $0.string;case"number":return Number.isNaN($)?$0.nan:$0.number;case"boolean":return $0.boolean;case"function":return $0.function;case"bigint":return $0.bigint;case"symbol":return $0.symbol;case"object":if(Array.isArray($))return $0.array;if($===null)return $0.null;if($.then&&typeof $.then==="function"&&$.catch&&typeof $.catch==="function")return $0.promise;if(typeof Map<"u"&&$ instanceof Map)return $0.map;if(typeof Set<"u"&&$ instanceof Set)return $0.set;if(typeof Date<"u"&&$ instanceof Date)return $0.date;return $0.object;default:return $0.unknown}};var o=P0.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),FW=($)=>{return JSON.stringify($,null,2).replace(/"([^"]+)":/g,"$1:")};class s0 extends Error{get errors(){return this.issues}constructor($){super();this.issues=[],this.addIssue=(J)=>{this.issues=[...this.issues,J]},this.addIssues=(J=[])=>{this.issues=[...this.issues,...J]};let Q=new.target.prototype;if(Object.setPrototypeOf)Object.setPrototypeOf(this,Q);else this.__proto__=Q;this.name="ZodError",this.issues=$}format($){let Q=$||function(X){return X.message},J={_errors:[]},q=(X)=>{for(let Y of X.issues)if(Y.code==="invalid_union")Y.unionErrors.map(q);else if(Y.code==="invalid_return_type")q(Y.returnTypeError);else if(Y.code==="invalid_arguments")q(Y.argumentsError);else if(Y.path.length===0)J._errors.push(Q(Y));else{let G=J,B=0;while(B<Y.path.length){let W=Y.path[B];if(B!==Y.path.length-1)G[W]=G[W]||{_errors:[]};else G[W]=G[W]||{_errors:[]},G[W]._errors.push(Q(Y));G=G[W],B++}}};return q(this),J}static assert($){if(!($ instanceof s0))throw Error(`Not a ZodError: ${$}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,P0.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten($=(Q)=>Q.message){let Q={},J=[];for(let q of this.issues)if(q.path.length>0){let X=q.path[0];Q[X]=Q[X]||[],Q[X].push($(q))}else J.push($(q));return{formErrors:J,fieldErrors:Q}}get formErrors(){return this.flatten()}}s0.create=($)=>{return new s0($)};var LW=($,Q)=>{let J;switch($.code){case o.invalid_type:if($.received===$0.undefined)J="Required";else J=`Expected ${$.expected}, received ${$.received}`;break;case o.invalid_literal:J=`Invalid literal value, expected ${JSON.stringify($.expected,P0.jsonStringifyReplacer)}`;break;case o.unrecognized_keys:J=`Unrecognized key(s) in object: ${P0.joinValues($.keys,", ")}`;break;case o.invalid_union:J="Invalid input";break;case o.invalid_union_discriminator:J=`Invalid discriminator value. Expected ${P0.joinValues($.options)}`;break;case o.invalid_enum_value:J=`Invalid enum value. Expected ${P0.joinValues($.options)}, received '${$.received}'`;break;case o.invalid_arguments:J="Invalid function arguments";break;case o.invalid_return_type:J="Invalid function return type";break;case o.invalid_date:J="Invalid date";break;case o.invalid_string:if(typeof $.validation==="object")if("includes"in $.validation){if(J=`Invalid input: must include "${$.validation.includes}"`,typeof $.validation.position==="number")J=`${J} at one or more positions greater than or equal to ${$.validation.position}`}else if("startsWith"in $.validation)J=`Invalid input: must start with "${$.validation.startsWith}"`;else if("endsWith"in $.validation)J=`Invalid input: must end with "${$.validation.endsWith}"`;else P0.assertNever($.validation);else if($.validation!=="regex")J=`Invalid ${$.validation}`;else J="Invalid";break;case o.too_small:if($.type==="array")J=`Array must contain ${$.exact?"exactly":$.inclusive?"at least":"more than"} ${$.minimum} element(s)`;else if($.type==="string")J=`String must contain ${$.exact?"exactly":$.inclusive?"at least":"over"} ${$.minimum} character(s)`;else if($.type==="number")J=`Number must be ${$.exact?"exactly equal to ":$.inclusive?"greater than or equal to ":"greater than "}${$.minimum}`;else if($.type==="bigint")J=`Number must be ${$.exact?"exactly equal to ":$.inclusive?"greater than or equal to ":"greater than "}${$.minimum}`;else if($.type==="date")J=`Date must be ${$.exact?"exactly equal to ":$.inclusive?"greater than or equal to ":"greater than "}${new Date(Number($.minimum))}`;else J="Invalid input";break;case o.too_big:if($.type==="array")J=`Array must contain ${$.exact?"exactly":$.inclusive?"at most":"less than"} ${$.maximum} element(s)`;else if($.type==="string")J=`String must contain ${$.exact?"exactly":$.inclusive?"at most":"under"} ${$.maximum} character(s)`;else if($.type==="number")J=`Number must be ${$.exact?"exactly":$.inclusive?"less than or equal to":"less than"} ${$.maximum}`;else if($.type==="bigint")J=`BigInt must be ${$.exact?"exactly":$.inclusive?"less than or equal to":"less than"} ${$.maximum}`;else if($.type==="date")J=`Date must be ${$.exact?"exactly":$.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number($.maximum))}`;else J="Invalid input";break;case o.custom:J="Invalid input";break;case o.invalid_intersection_types:J="Intersection results could not be merged";break;case o.not_multiple_of:J=`Number must be a multiple of ${$.multipleOf}`;break;case o.not_finite:J="Number must be finite";break;default:J=Q.defaultError,P0.assertNever($)}return{message:J}},c2=LW;var RJ=c2;function zW($){RJ=$}function X6(){return RJ}var t6=($)=>{let{data:Q,path:J,errorMaps:q,issueData:X}=$,Y=[...J,...X.path||[]],G={...X,path:Y};if(X.message!==void 0)return{...X,path:Y,message:X.message};let B="",W=q.filter((U)=>!!U).slice().reverse();for(let U of W)B=U(G,{data:Q,defaultError:B}).message;return{...X,path:Y,message:B}},OW=[];function X0($,Q){let J=X6(),q=t6({issueData:Q,data:$.data,path:$.path,errorMaps:[$.common.contextualErrorMap,$.schemaErrorMap,J,J===c2?void 0:c2].filter((X)=>!!X)});$.common.issues.push(q)}class m0{constructor(){this.value="valid"}dirty(){if(this.value==="valid")this.value="dirty"}abort(){if(this.value!=="aborted")this.value="aborted"}static mergeArray($,Q){let J=[];for(let q of Q){if(q.status==="aborted")return w0;if(q.status==="dirty")$.dirty();J.push(q.value)}return{status:$.value,value:J}}static async mergeObjectAsync($,Q){let J=[];for(let q of Q){let X=await q.key,Y=await q.value;J.push({key:X,value:Y})}return m0.mergeObjectSync($,J)}static mergeObjectSync($,Q){let J={};for(let q of Q){let{key:X,value:Y}=q;if(X.status==="aborted")return w0;if(Y.status==="aborted")return w0;if(X.status==="dirty")$.dirty();if(Y.status==="dirty")$.dirty();if(X.value!=="__proto__"&&(typeof Y.value<"u"||q.alwaysSet))J[X.value]=Y.value}return{status:$.value,value:J}}}var w0=Object.freeze({status:"aborted"}),v1=($)=>({status:"dirty",value:$}),l0=($)=>({status:"valid",value:$}),s8=($)=>$.status==="aborted",t8=($)=>$.status==="dirty",X1=($)=>$.status==="valid",Y6=($)=>typeof Promise<"u"&&$ instanceof Promise;var V0;(function($){$.errToObj=(Q)=>typeof Q==="string"?{message:Q}:Q||{},$.toString=(Q)=>typeof Q==="string"?Q:Q?.message})(V0||(V0={}));class w2{constructor($,Q,J,q){this._cachedPath=[],this.parent=$,this.data=Q,this._path=J,this._key=q}get path(){if(!this._cachedPath.length)if(Array.isArray(this._key))this._cachedPath.push(...this._path,...this._key);else this._cachedPath.push(...this._path,this._key);return this._cachedPath}}var IJ=($,Q)=>{if(X1(Q))return{success:!0,data:Q.value};else{if(!$.common.issues.length)throw Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let J=new s0($.common.issues);return this._error=J,this._error}}}};function A0($){if(!$)return{};let{errorMap:Q,invalid_type_error:J,required_error:q,description:X}=$;if(Q&&(J||q))throw Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);if(Q)return{errorMap:Q,description:X};return{errorMap:(G,B)=>{let{message:W}=$;if(G.code==="invalid_enum_value")return{message:W??B.defaultError};if(typeof B.data>"u")return{message:W??q??B.defaultError};if(G.code!=="invalid_type")return{message:B.defaultError};return{message:W??J??B.defaultError}},description:X}}class D0{get description(){return this._def.description}_getType($){return S2($.data)}_getOrReturnCtx($,Q){return Q||{common:$.parent.common,data:$.data,parsedType:S2($.data),schemaErrorMap:this._def.errorMap,path:$.path,parent:$.parent}}_processInputParams($){return{status:new m0,ctx:{common:$.parent.common,data:$.data,parsedType:S2($.data),schemaErrorMap:this._def.errorMap,path:$.path,parent:$.parent}}}_parseSync($){let Q=this._parse($);if(Y6(Q))throw Error("Synchronous parse encountered promise.");return Q}_parseAsync($){let Q=this._parse($);return Promise.resolve(Q)}parse($,Q){let J=this.safeParse($,Q);if(J.success)return J.data;throw J.error}safeParse($,Q){let J={common:{issues:[],async:Q?.async??!1,contextualErrorMap:Q?.errorMap},path:Q?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:$,parsedType:S2($)},q=this._parseSync({data:$,path:J.path,parent:J});return IJ(J,q)}"~validate"($){let Q={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:$,parsedType:S2($)};if(!this["~standard"].async)try{let J=this._parseSync({data:$,path:[],parent:Q});return X1(J)?{value:J.value}:{issues:Q.common.issues}}catch(J){if(J?.message?.toLowerCase()?.includes("encountered"))this["~standard"].async=!0;Q.common={issues:[],async:!0}}return this._parseAsync({data:$,path:[],parent:Q}).then((J)=>X1(J)?{value:J.value}:{issues:Q.common.issues})}async parseAsync($,Q){let J=await this.safeParseAsync($,Q);if(J.success)return J.data;throw J.error}async safeParseAsync($,Q){let J={common:{issues:[],contextualErrorMap:Q?.errorMap,async:!0},path:Q?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:$,parsedType:S2($)},q=this._parse({data:$,path:J.path,parent:J}),X=await(Y6(q)?q:Promise.resolve(q));return IJ(J,X)}refine($,Q){let J=(q)=>{if(typeof Q==="string"||typeof Q>"u")return{message:Q};else if(typeof Q==="function")return Q(q);else return Q};return this._refinement((q,X)=>{let Y=$(q),G=()=>X.addIssue({code:o.custom,...J(q)});if(typeof Promise<"u"&&Y instanceof Promise)return Y.then((B)=>{if(!B)return G(),!1;else return!0});if(!Y)return G(),!1;else return!0})}refinement($,Q){return this._refinement((J,q)=>{if(!$(J))return q.addIssue(typeof Q==="function"?Q(J,q):Q),!1;else return!0})}_refinement($){return new F2({schema:this,typeName:F0.ZodEffects,effect:{type:"refinement",refinement:$}})}superRefine($){return this._refinement($)}constructor($){this.spa=this.safeParseAsync,this._def=$,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:(Q)=>this["~validate"](Q)}}optional(){return M2.create(this,this._def)}nullable(){return l2.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return j2.create(this)}promise(){return g1.create(this,this._def)}or($){return K6.create([this,$],this._def)}and($){return H6.create(this,$,this._def)}transform($){return new F2({...A0(this._def),schema:this,typeName:F0.ZodEffects,effect:{type:"transform",transform:$}})}default($){let Q=typeof $==="function"?$:()=>$;return new F6({...A0(this._def),innerType:this,defaultValue:Q,typeName:F0.ZodDefault})}brand(){return new $5({typeName:F0.ZodBranded,type:this,...A0(this._def)})}catch($){let Q=typeof $==="function"?$:()=>$;return new L6({...A0(this._def),innerType:this,catchValue:Q,typeName:F0.ZodCatch})}describe($){return new this.constructor({...this._def,description:$})}pipe($){return X8.create(this,$)}readonly(){return z6.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}var NW=/^c[^\s-]{8,}$/i,AW=/^[0-9a-z]+$/,DW=/^[0-9A-HJKMNP-TV-Z]{26}$/i,PW=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,CW=/^[a-z0-9_-]{21}$/i,RW=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,IW=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,SW=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,EW="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",l4,vW=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,kW=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,TW=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,ZW=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,gW=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,xW=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,EJ="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",fW=new RegExp(`^${EJ}$`);function vJ($){let Q="[0-5]\\d";if($.precision)Q=`${Q}\\.\\d{${$.precision}}`;else if($.precision==null)Q=`${Q}(\\.\\d+)?`;let J=$.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${Q})${J}`}function yW($){return new RegExp(`^${vJ($)}$`)}function kJ($){let Q=`${EJ}T${vJ($)}`,J=[];if(J.push($.local?"Z?":"Z"),$.offset)J.push("([+-]\\d{2}:?\\d{2})");return Q=`${Q}(${J.join("|")})`,new RegExp(`^${Q}$`)}function _W($,Q){if((Q==="v4"||!Q)&&vW.test($))return!0;if((Q==="v6"||!Q)&&TW.test($))return!0;return!1}function bW($,Q){if(!RW.test($))return!1;try{let[J]=$.split(".");if(!J)return!1;let q=J.replace(/-/g,"+").replace(/_/g,"/").padEnd(J.length+(4-J.length%4)%4,"="),X=JSON.parse(atob(q));if(typeof X!=="object"||X===null)return!1;if("typ"in X&&X?.typ!=="JWT")return!1;if(!X.alg)return!1;if(Q&&X.alg!==Q)return!1;return!0}catch{return!1}}function hW($,Q){if((Q==="v4"||!Q)&&kW.test($))return!0;if((Q==="v6"||!Q)&&ZW.test($))return!0;return!1}class H2 extends D0{_parse($){if(this._def.coerce)$.data=String($.data);if(this._getType($)!==$0.string){let X=this._getOrReturnCtx($);return X0(X,{code:o.invalid_type,expected:$0.string,received:X.parsedType}),w0}let J=new m0,q=void 0;for(let X of this._def.checks)if(X.kind==="min"){if($.data.length<X.value)q=this._getOrReturnCtx($,q),X0(q,{code:o.too_small,minimum:X.value,type:"string",inclusive:!0,exact:!1,message:X.message}),J.dirty()}else if(X.kind==="max"){if($.data.length>X.value)q=this._getOrReturnCtx($,q),X0(q,{code:o.too_big,maximum:X.value,type:"string",inclusive:!0,exact:!1,message:X.message}),J.dirty()}else if(X.kind==="length"){let Y=$.data.length>X.value,G=$.data.length<X.value;if(Y||G){if(q=this._getOrReturnCtx($,q),Y)X0(q,{code:o.too_big,maximum:X.value,type:"string",inclusive:!0,exact:!0,message:X.message});else if(G)X0(q,{code:o.too_small,minimum:X.value,type:"string",inclusive:!0,exact:!0,message:X.message});J.dirty()}}else if(X.kind==="email"){if(!SW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"email",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="emoji"){if(!l4)l4=new RegExp(EW,"u");if(!l4.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"emoji",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="uuid"){if(!PW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"uuid",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="nanoid"){if(!CW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"nanoid",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="cuid"){if(!NW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"cuid",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="cuid2"){if(!AW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"cuid2",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="ulid"){if(!DW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"ulid",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="url")try{new URL($.data)}catch{q=this._getOrReturnCtx($,q),X0(q,{validation:"url",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="regex"){if(X.regex.lastIndex=0,!X.regex.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"regex",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="trim")$.data=$.data.trim();else if(X.kind==="includes"){if(!$.data.includes(X.value,X.position))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:{includes:X.value,position:X.position},message:X.message}),J.dirty()}else if(X.kind==="toLowerCase")$.data=$.data.toLowerCase();else if(X.kind==="toUpperCase")$.data=$.data.toUpperCase();else if(X.kind==="startsWith"){if(!$.data.startsWith(X.value))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:{startsWith:X.value},message:X.message}),J.dirty()}else if(X.kind==="endsWith"){if(!$.data.endsWith(X.value))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:{endsWith:X.value},message:X.message}),J.dirty()}else if(X.kind==="datetime"){if(!kJ(X).test($.data))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:"datetime",message:X.message}),J.dirty()}else if(X.kind==="date"){if(!fW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:"date",message:X.message}),J.dirty()}else if(X.kind==="time"){if(!yW(X).test($.data))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:"time",message:X.message}),J.dirty()}else if(X.kind==="duration"){if(!IW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"duration",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="ip"){if(!_W($.data,X.version))q=this._getOrReturnCtx($,q),X0(q,{validation:"ip",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="jwt"){if(!bW($.data,X.alg))q=this._getOrReturnCtx($,q),X0(q,{validation:"jwt",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="cidr"){if(!hW($.data,X.version))q=this._getOrReturnCtx($,q),X0(q,{validation:"cidr",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="base64"){if(!gW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"base64",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="base64url"){if(!xW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"base64url",code:o.invalid_string,message:X.message}),J.dirty()}else P0.assertNever(X);return{status:J.value,value:$.data}}_regex($,Q,J){return this.refinement((q)=>$.test(q),{validation:Q,code:o.invalid_string,...V0.errToObj(J)})}_addCheck($){return new H2({...this._def,checks:[...this._def.checks,$]})}email($){return this._addCheck({kind:"email",...V0.errToObj($)})}url($){return this._addCheck({kind:"url",...V0.errToObj($)})}emoji($){return this._addCheck({kind:"emoji",...V0.errToObj($)})}uuid($){return this._addCheck({kind:"uuid",...V0.errToObj($)})}nanoid($){return this._addCheck({kind:"nanoid",...V0.errToObj($)})}cuid($){return this._addCheck({kind:"cuid",...V0.errToObj($)})}cuid2($){return this._addCheck({kind:"cuid2",...V0.errToObj($)})}ulid($){return this._addCheck({kind:"ulid",...V0.errToObj($)})}base64($){return this._addCheck({kind:"base64",...V0.errToObj($)})}base64url($){return this._addCheck({kind:"base64url",...V0.errToObj($)})}jwt($){return this._addCheck({kind:"jwt",...V0.errToObj($)})}ip($){return this._addCheck({kind:"ip",...V0.errToObj($)})}cidr($){return this._addCheck({kind:"cidr",...V0.errToObj($)})}datetime($){if(typeof $==="string")return this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:$});return this._addCheck({kind:"datetime",precision:typeof $?.precision>"u"?null:$?.precision,offset:$?.offset??!1,local:$?.local??!1,...V0.errToObj($?.message)})}date($){return this._addCheck({kind:"date",message:$})}time($){if(typeof $==="string")return this._addCheck({kind:"time",precision:null,message:$});return this._addCheck({kind:"time",precision:typeof $?.precision>"u"?null:$?.precision,...V0.errToObj($?.message)})}duration($){return this._addCheck({kind:"duration",...V0.errToObj($)})}regex($,Q){return this._addCheck({kind:"regex",regex:$,...V0.errToObj(Q)})}includes($,Q){return this._addCheck({kind:"includes",value:$,position:Q?.position,...V0.errToObj(Q?.message)})}startsWith($,Q){return this._addCheck({kind:"startsWith",value:$,...V0.errToObj(Q)})}endsWith($,Q){return this._addCheck({kind:"endsWith",value:$,...V0.errToObj(Q)})}min($,Q){return this._addCheck({kind:"min",value:$,...V0.errToObj(Q)})}max($,Q){return this._addCheck({kind:"max",value:$,...V0.errToObj(Q)})}length($,Q){return this._addCheck({kind:"length",value:$,...V0.errToObj(Q)})}nonempty($){return this.min(1,V0.errToObj($))}trim(){return new H2({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new H2({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new H2({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(($)=>$.kind==="datetime")}get isDate(){return!!this._def.checks.find(($)=>$.kind==="date")}get isTime(){return!!this._def.checks.find(($)=>$.kind==="time")}get isDuration(){return!!this._def.checks.find(($)=>$.kind==="duration")}get isEmail(){return!!this._def.checks.find(($)=>$.kind==="email")}get isURL(){return!!this._def.checks.find(($)=>$.kind==="url")}get isEmoji(){return!!this._def.checks.find(($)=>$.kind==="emoji")}get isUUID(){return!!this._def.checks.find(($)=>$.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(($)=>$.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(($)=>$.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(($)=>$.kind==="cuid2")}get isULID(){return!!this._def.checks.find(($)=>$.kind==="ulid")}get isIP(){return!!this._def.checks.find(($)=>$.kind==="ip")}get isCIDR(){return!!this._def.checks.find(($)=>$.kind==="cidr")}get isBase64(){return!!this._def.checks.find(($)=>$.kind==="base64")}get isBase64url(){return!!this._def.checks.find(($)=>$.kind==="base64url")}get minLength(){let $=null;for(let Q of this._def.checks)if(Q.kind==="min"){if($===null||Q.value>$)$=Q.value}return $}get maxLength(){let $=null;for(let Q of this._def.checks)if(Q.kind==="max"){if($===null||Q.value<$)$=Q.value}return $}}H2.create=($)=>{return new H2({checks:[],typeName:F0.ZodString,coerce:$?.coerce??!1,...A0($)})};function mW($,Q){let J=($.toString().split(".")[1]||"").length,q=(Q.toString().split(".")[1]||"").length,X=J>q?J:q,Y=Number.parseInt($.toFixed(X).replace(".","")),G=Number.parseInt(Q.toFixed(X).replace(".",""));return Y%G/10**X}class G1 extends D0{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse($){if(this._def.coerce)$.data=Number($.data);if(this._getType($)!==$0.number){let X=this._getOrReturnCtx($);return X0(X,{code:o.invalid_type,expected:$0.number,received:X.parsedType}),w0}let J=void 0,q=new m0;for(let X of this._def.checks)if(X.kind==="int"){if(!P0.isInteger($.data))J=this._getOrReturnCtx($,J),X0(J,{code:o.invalid_type,expected:"integer",received:"float",message:X.message}),q.dirty()}else if(X.kind==="min"){if(X.inclusive?$.data<X.value:$.data<=X.value)J=this._getOrReturnCtx($,J),X0(J,{code:o.too_small,minimum:X.value,type:"number",inclusive:X.inclusive,exact:!1,message:X.message}),q.dirty()}else if(X.kind==="max"){if(X.inclusive?$.data>X.value:$.data>=X.value)J=this._getOrReturnCtx($,J),X0(J,{code:o.too_big,maximum:X.value,type:"number",inclusive:X.inclusive,exact:!1,message:X.message}),q.dirty()}else if(X.kind==="multipleOf"){if(mW($.data,X.value)!==0)J=this._getOrReturnCtx($,J),X0(J,{code:o.not_multiple_of,multipleOf:X.value,message:X.message}),q.dirty()}else if(X.kind==="finite"){if(!Number.isFinite($.data))J=this._getOrReturnCtx($,J),X0(J,{code:o.not_finite,message:X.message}),q.dirty()}else P0.assertNever(X);return{status:q.value,value:$.data}}gte($,Q){return this.setLimit("min",$,!0,V0.toString(Q))}gt($,Q){return this.setLimit("min",$,!1,V0.toString(Q))}lte($,Q){return this.setLimit("max",$,!0,V0.toString(Q))}lt($,Q){return this.setLimit("max",$,!1,V0.toString(Q))}setLimit($,Q,J,q){return new G1({...this._def,checks:[...this._def.checks,{kind:$,value:Q,inclusive:J,message:V0.toString(q)}]})}_addCheck($){return new G1({...this._def,checks:[...this._def.checks,$]})}int($){return this._addCheck({kind:"int",message:V0.toString($)})}positive($){return this._addCheck({kind:"min",value:0,inclusive:!1,message:V0.toString($)})}negative($){return this._addCheck({kind:"max",value:0,inclusive:!1,message:V0.toString($)})}nonpositive($){return this._addCheck({kind:"max",value:0,inclusive:!0,message:V0.toString($)})}nonnegative($){return this._addCheck({kind:"min",value:0,inclusive:!0,message:V0.toString($)})}multipleOf($,Q){return this._addCheck({kind:"multipleOf",value:$,message:V0.toString(Q)})}finite($){return this._addCheck({kind:"finite",message:V0.toString($)})}safe($){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:V0.toString($)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:V0.toString($)})}get minValue(){let $=null;for(let Q of this._def.checks)if(Q.kind==="min"){if($===null||Q.value>$)$=Q.value}return $}get maxValue(){let $=null;for(let Q of this._def.checks)if(Q.kind==="max"){if($===null||Q.value<$)$=Q.value}return $}get isInt(){return!!this._def.checks.find(($)=>$.kind==="int"||$.kind==="multipleOf"&&P0.isInteger($.value))}get isFinite(){let $=null,Q=null;for(let J of this._def.checks)if(J.kind==="finite"||J.kind==="int"||J.kind==="multipleOf")return!0;else if(J.kind==="min"){if(Q===null||J.value>Q)Q=J.value}else if(J.kind==="max"){if($===null||J.value<$)$=J.value}return Number.isFinite(Q)&&Number.isFinite($)}}G1.create=($)=>{return new G1({checks:[],typeName:F0.ZodNumber,coerce:$?.coerce||!1,...A0($)})};class B1 extends D0{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte}_parse($){if(this._def.coerce)try{$.data=BigInt($.data)}catch{return this._getInvalidInput($)}if(this._getType($)!==$0.bigint)return this._getInvalidInput($);let J=void 0,q=new m0;for(let X of this._def.checks)if(X.kind==="min"){if(X.inclusive?$.data<X.value:$.data<=X.value)J=this._getOrReturnCtx($,J),X0(J,{code:o.too_small,type:"bigint",minimum:X.value,inclusive:X.inclusive,message:X.message}),q.dirty()}else if(X.kind==="max"){if(X.inclusive?$.data>X.value:$.data>=X.value)J=this._getOrReturnCtx($,J),X0(J,{code:o.too_big,type:"bigint",maximum:X.value,inclusive:X.inclusive,message:X.message}),q.dirty()}else if(X.kind==="multipleOf"){if($.data%X.value!==BigInt(0))J=this._getOrReturnCtx($,J),X0(J,{code:o.not_multiple_of,multipleOf:X.value,message:X.message}),q.dirty()}else P0.assertNever(X);return{status:q.value,value:$.data}}_getInvalidInput($){let Q=this._getOrReturnCtx($);return X0(Q,{code:o.invalid_type,expected:$0.bigint,received:Q.parsedType}),w0}gte($,Q){return this.setLimit("min",$,!0,V0.toString(Q))}gt($,Q){return this.setLimit("min",$,!1,V0.toString(Q))}lte($,Q){return this.setLimit("max",$,!0,V0.toString(Q))}lt($,Q){return this.setLimit("max",$,!1,V0.toString(Q))}setLimit($,Q,J,q){return new B1({...this._def,checks:[...this._def.checks,{kind:$,value:Q,inclusive:J,message:V0.toString(q)}]})}_addCheck($){return new B1({...this._def,checks:[...this._def.checks,$]})}positive($){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:V0.toString($)})}negative($){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:V0.toString($)})}nonpositive($){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:V0.toString($)})}nonnegative($){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:V0.toString($)})}multipleOf($,Q){return this._addCheck({kind:"multipleOf",value:$,message:V0.toString(Q)})}get minValue(){let $=null;for(let Q of this._def.checks)if(Q.kind==="min"){if($===null||Q.value>$)$=Q.value}return $}get maxValue(){let $=null;for(let Q of this._def.checks)if(Q.kind==="max"){if($===null||Q.value<$)$=Q.value}return $}}B1.create=($)=>{return new B1({checks:[],typeName:F0.ZodBigInt,coerce:$?.coerce??!1,...A0($)})};class U6 extends D0{_parse($){if(this._def.coerce)$.data=Boolean($.data);if(this._getType($)!==$0.boolean){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.boolean,received:J.parsedType}),w0}return l0($.data)}}U6.create=($)=>{return new U6({typeName:F0.ZodBoolean,coerce:$?.coerce||!1,...A0($)})};class k1 extends D0{_parse($){if(this._def.coerce)$.data=new Date($.data);if(this._getType($)!==$0.date){let X=this._getOrReturnCtx($);return X0(X,{code:o.invalid_type,expected:$0.date,received:X.parsedType}),w0}if(Number.isNaN($.data.getTime())){let X=this._getOrReturnCtx($);return X0(X,{code:o.invalid_date}),w0}let J=new m0,q=void 0;for(let X of this._def.checks)if(X.kind==="min"){if($.data.getTime()<X.value)q=this._getOrReturnCtx($,q),X0(q,{code:o.too_small,message:X.message,inclusive:!0,exact:!1,minimum:X.value,type:"date"}),J.dirty()}else if(X.kind==="max"){if($.data.getTime()>X.value)q=this._getOrReturnCtx($,q),X0(q,{code:o.too_big,message:X.message,inclusive:!0,exact:!1,maximum:X.value,type:"date"}),J.dirty()}else P0.assertNever(X);return{status:J.value,value:new Date($.data.getTime())}}_addCheck($){return new k1({...this._def,checks:[...this._def.checks,$]})}min($,Q){return this._addCheck({kind:"min",value:$.getTime(),message:V0.toString(Q)})}max($,Q){return this._addCheck({kind:"max",value:$.getTime(),message:V0.toString(Q)})}get minDate(){let $=null;for(let Q of this._def.checks)if(Q.kind==="min"){if($===null||Q.value>$)$=Q.value}return $!=null?new Date($):null}get maxDate(){let $=null;for(let Q of this._def.checks)if(Q.kind==="max"){if($===null||Q.value<$)$=Q.value}return $!=null?new Date($):null}}k1.create=($)=>{return new k1({checks:[],coerce:$?.coerce||!1,typeName:F0.ZodDate,...A0($)})};class e6 extends D0{_parse($){if(this._getType($)!==$0.symbol){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.symbol,received:J.parsedType}),w0}return l0($.data)}}e6.create=($)=>{return new e6({typeName:F0.ZodSymbol,...A0($)})};class W6 extends D0{_parse($){if(this._getType($)!==$0.undefined){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.undefined,received:J.parsedType}),w0}return l0($.data)}}W6.create=($)=>{return new W6({typeName:F0.ZodUndefined,...A0($)})};class V6 extends D0{_parse($){if(this._getType($)!==$0.null){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.null,received:J.parsedType}),w0}return l0($.data)}}V6.create=($)=>{return new V6({typeName:F0.ZodNull,...A0($)})};class T1 extends D0{constructor(){super(...arguments);this._any=!0}_parse($){return l0($.data)}}T1.create=($)=>{return new T1({typeName:F0.ZodAny,...A0($)})};class Y1 extends D0{constructor(){super(...arguments);this._unknown=!0}_parse($){return l0($.data)}}Y1.create=($)=>{return new Y1({typeName:F0.ZodUnknown,...A0($)})};class E2 extends D0{_parse($){let Q=this._getOrReturnCtx($);return X0(Q,{code:o.invalid_type,expected:$0.never,received:Q.parsedType}),w0}}E2.create=($)=>{return new E2({typeName:F0.ZodNever,...A0($)})};class $8 extends D0{_parse($){if(this._getType($)!==$0.undefined){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.void,received:J.parsedType}),w0}return l0($.data)}}$8.create=($)=>{return new $8({typeName:F0.ZodVoid,...A0($)})};class j2 extends D0{_parse($){let{ctx:Q,status:J}=this._processInputParams($),q=this._def;if(Q.parsedType!==$0.array)return X0(Q,{code:o.invalid_type,expected:$0.array,received:Q.parsedType}),w0;if(q.exactLength!==null){let Y=Q.data.length>q.exactLength.value,G=Q.data.length<q.exactLength.value;if(Y||G)X0(Q,{code:Y?o.too_big:o.too_small,minimum:G?q.exactLength.value:void 0,maximum:Y?q.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:q.exactLength.message}),J.dirty()}if(q.minLength!==null){if(Q.data.length<q.minLength.value)X0(Q,{code:o.too_small,minimum:q.minLength.value,type:"array",inclusive:!0,exact:!1,message:q.minLength.message}),J.dirty()}if(q.maxLength!==null){if(Q.data.length>q.maxLength.value)X0(Q,{code:o.too_big,maximum:q.maxLength.value,type:"array",inclusive:!0,exact:!1,message:q.maxLength.message}),J.dirty()}if(Q.common.async)return Promise.all([...Q.data].map((Y,G)=>{return q.type._parseAsync(new w2(Q,Y,Q.path,G))})).then((Y)=>{return m0.mergeArray(J,Y)});let X=[...Q.data].map((Y,G)=>{return q.type._parseSync(new w2(Q,Y,Q.path,G))});return m0.mergeArray(J,X)}get element(){return this._def.type}min($,Q){return new j2({...this._def,minLength:{value:$,message:V0.toString(Q)}})}max($,Q){return new j2({...this._def,maxLength:{value:$,message:V0.toString(Q)}})}length($,Q){return new j2({...this._def,exactLength:{value:$,message:V0.toString(Q)}})}nonempty($){return this.min(1,$)}}j2.create=($,Q)=>{return new j2({type:$,minLength:null,maxLength:null,exactLength:null,typeName:F0.ZodArray,...A0(Q)})};function G6($){if($ instanceof x0){let Q={};for(let J in $.shape){let q=$.shape[J];Q[J]=M2.create(G6(q))}return new x0({...$._def,shape:()=>Q})}else if($ instanceof j2)return new j2({...$._def,type:G6($.element)});else if($ instanceof M2)return M2.create(G6($.unwrap()));else if($ instanceof l2)return l2.create(G6($.unwrap()));else if($ instanceof v2)return v2.create($.items.map((Q)=>G6(Q)));else return $}class x0 extends D0{constructor(){super(...arguments);this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let $=this._def.shape(),Q=P0.objectKeys($);return this._cached={shape:$,keys:Q},this._cached}_parse($){if(this._getType($)!==$0.object){let W=this._getOrReturnCtx($);return X0(W,{code:o.invalid_type,expected:$0.object,received:W.parsedType}),w0}let{status:J,ctx:q}=this._processInputParams($),{shape:X,keys:Y}=this._getCached(),G=[];if(!(this._def.catchall instanceof E2&&this._def.unknownKeys==="strip")){for(let W in q.data)if(!Y.includes(W))G.push(W)}let B=[];for(let W of Y){let U=X[W],V=q.data[W];B.push({key:{status:"valid",value:W},value:U._parse(new w2(q,V,q.path,W)),alwaysSet:W in q.data})}if(this._def.catchall instanceof E2){let W=this._def.unknownKeys;if(W==="passthrough")for(let U of G)B.push({key:{status:"valid",value:U},value:{status:"valid",value:q.data[U]}});else if(W==="strict"){if(G.length>0)X0(q,{code:o.unrecognized_keys,keys:G}),J.dirty()}else if(W==="strip");else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let W=this._def.catchall;for(let U of G){let V=q.data[U];B.push({key:{status:"valid",value:U},value:W._parse(new w2(q,V,q.path,U)),alwaysSet:U in q.data})}}if(q.common.async)return Promise.resolve().then(async()=>{let W=[];for(let U of B){let V=await U.key,L=await U.value;W.push({key:V,value:L,alwaysSet:U.alwaysSet})}return W}).then((W)=>{return m0.mergeObjectSync(J,W)});else return m0.mergeObjectSync(J,B)}get shape(){return this._def.shape()}strict($){return V0.errToObj,new x0({...this._def,unknownKeys:"strict",...$!==void 0?{errorMap:(Q,J)=>{let q=this._def.errorMap?.(Q,J).message??J.defaultError;if(Q.code==="unrecognized_keys")return{message:V0.errToObj($).message??q};return{message:q}}}:{}})}strip(){return new x0({...this._def,unknownKeys:"strip"})}passthrough(){return new x0({...this._def,unknownKeys:"passthrough"})}extend($){return new x0({...this._def,shape:()=>({...this._def.shape(),...$})})}merge($){return new x0({unknownKeys:$._def.unknownKeys,catchall:$._def.catchall,shape:()=>({...this._def.shape(),...$._def.shape()}),typeName:F0.ZodObject})}setKey($,Q){return this.augment({[$]:Q})}catchall($){return new x0({...this._def,catchall:$})}pick($){let Q={};for(let J of P0.objectKeys($))if($[J]&&this.shape[J])Q[J]=this.shape[J];return new x0({...this._def,shape:()=>Q})}omit($){let Q={};for(let J of P0.objectKeys(this.shape))if(!$[J])Q[J]=this.shape[J];return new x0({...this._def,shape:()=>Q})}deepPartial(){return G6(this)}partial($){let Q={};for(let J of P0.objectKeys(this.shape)){let q=this.shape[J];if($&&!$[J])Q[J]=q;else Q[J]=q.optional()}return new x0({...this._def,shape:()=>Q})}required($){let Q={};for(let J of P0.objectKeys(this.shape))if($&&!$[J])Q[J]=this.shape[J];else{let X=this.shape[J];while(X instanceof M2)X=X._def.innerType;Q[J]=X}return new x0({...this._def,shape:()=>Q})}keyof(){return TJ(P0.objectKeys(this.shape))}}x0.create=($,Q)=>{return new x0({shape:()=>$,unknownKeys:"strip",catchall:E2.create(),typeName:F0.ZodObject,...A0(Q)})};x0.strictCreate=($,Q)=>{return new x0({shape:()=>$,unknownKeys:"strict",catchall:E2.create(),typeName:F0.ZodObject,...A0(Q)})};x0.lazycreate=($,Q)=>{return new x0({shape:$,unknownKeys:"strip",catchall:E2.create(),typeName:F0.ZodObject,...A0(Q)})};class K6 extends D0{_parse($){let{ctx:Q}=this._processInputParams($),J=this._def.options;function q(X){for(let G of X)if(G.result.status==="valid")return G.result;for(let G of X)if(G.result.status==="dirty")return Q.common.issues.push(...G.ctx.common.issues),G.result;let Y=X.map((G)=>new s0(G.ctx.common.issues));return X0(Q,{code:o.invalid_union,unionErrors:Y}),w0}if(Q.common.async)return Promise.all(J.map(async(X)=>{let Y={...Q,common:{...Q.common,issues:[]},parent:null};return{result:await X._parseAsync({data:Q.data,path:Q.path,parent:Y}),ctx:Y}})).then(q);else{let X=void 0,Y=[];for(let B of J){let W={...Q,common:{...Q.common,issues:[]},parent:null},U=B._parseSync({data:Q.data,path:Q.path,parent:W});if(U.status==="valid")return U;else if(U.status==="dirty"&&!X)X={result:U,ctx:W};if(W.common.issues.length)Y.push(W.common.issues)}if(X)return Q.common.issues.push(...X.ctx.common.issues),X.result;let G=Y.map((B)=>new s0(B));return X0(Q,{code:o.invalid_union,unionErrors:G}),w0}}get options(){return this._def.options}}K6.create=($,Q)=>{return new K6({options:$,typeName:F0.ZodUnion,...A0(Q)})};var p2=($)=>{if($ instanceof j6)return p2($.schema);else if($ instanceof F2)return p2($.innerType());else if($ instanceof M6)return[$.value];else if($ instanceof U1)return $.options;else if($ instanceof w6)return P0.objectValues($.enum);else if($ instanceof F6)return p2($._def.innerType);else if($ instanceof W6)return[void 0];else if($ instanceof V6)return[null];else if($ instanceof M2)return[void 0,...p2($.unwrap())];else if($ instanceof l2)return[null,...p2($.unwrap())];else if($ instanceof $5)return p2($.unwrap());else if($ instanceof z6)return p2($.unwrap());else if($ instanceof L6)return p2($._def.innerType);else return[]};class e8 extends D0{_parse($){let{ctx:Q}=this._processInputParams($);if(Q.parsedType!==$0.object)return X0(Q,{code:o.invalid_type,expected:$0.object,received:Q.parsedType}),w0;let J=this.discriminator,q=Q.data[J],X=this.optionsMap.get(q);if(!X)return X0(Q,{code:o.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[J]}),w0;if(Q.common.async)return X._parseAsync({data:Q.data,path:Q.path,parent:Q});else return X._parseSync({data:Q.data,path:Q.path,parent:Q})}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create($,Q,J){let q=new Map;for(let X of Q){let Y=p2(X.shape[$]);if(!Y.length)throw Error(`A discriminator value for key \`${$}\` could not be extracted from all schema options`);for(let G of Y){if(q.has(G))throw Error(`Discriminator property ${String($)} has duplicate value ${String(G)}`);q.set(G,X)}}return new e8({typeName:F0.ZodDiscriminatedUnion,discriminator:$,options:Q,optionsMap:q,...A0(J)})}}function d4($,Q){let J=S2($),q=S2(Q);if($===Q)return{valid:!0,data:$};else if(J===$0.object&&q===$0.object){let X=P0.objectKeys(Q),Y=P0.objectKeys($).filter((B)=>X.indexOf(B)!==-1),G={...$,...Q};for(let B of Y){let W=d4($[B],Q[B]);if(!W.valid)return{valid:!1};G[B]=W.data}return{valid:!0,data:G}}else if(J===$0.array&&q===$0.array){if($.length!==Q.length)return{valid:!1};let X=[];for(let Y=0;Y<$.length;Y++){let G=$[Y],B=Q[Y],W=d4(G,B);if(!W.valid)return{valid:!1};X.push(W.data)}return{valid:!0,data:X}}else if(J===$0.date&&q===$0.date&&+$===+Q)return{valid:!0,data:$};else return{valid:!1}}class H6 extends D0{_parse($){let{status:Q,ctx:J}=this._processInputParams($),q=(X,Y)=>{if(s8(X)||s8(Y))return w0;let G=d4(X.value,Y.value);if(!G.valid)return X0(J,{code:o.invalid_intersection_types}),w0;if(t8(X)||t8(Y))Q.dirty();return{status:Q.value,value:G.data}};if(J.common.async)return Promise.all([this._def.left._parseAsync({data:J.data,path:J.path,parent:J}),this._def.right._parseAsync({data:J.data,path:J.path,parent:J})]).then(([X,Y])=>q(X,Y));else return q(this._def.left._parseSync({data:J.data,path:J.path,parent:J}),this._def.right._parseSync({data:J.data,path:J.path,parent:J}))}}H6.create=($,Q,J)=>{return new H6({left:$,right:Q,typeName:F0.ZodIntersection,...A0(J)})};class v2 extends D0{_parse($){let{status:Q,ctx:J}=this._processInputParams($);if(J.parsedType!==$0.array)return X0(J,{code:o.invalid_type,expected:$0.array,received:J.parsedType}),w0;if(J.data.length<this._def.items.length)return X0(J,{code:o.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),w0;if(!this._def.rest&&J.data.length>this._def.items.length)X0(J,{code:o.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),Q.dirty();let X=[...J.data].map((Y,G)=>{let B=this._def.items[G]||this._def.rest;if(!B)return null;return B._parse(new w2(J,Y,J.path,G))}).filter((Y)=>!!Y);if(J.common.async)return Promise.all(X).then((Y)=>{return m0.mergeArray(Q,Y)});else return m0.mergeArray(Q,X)}get items(){return this._def.items}rest($){return new v2({...this._def,rest:$})}}v2.create=($,Q)=>{if(!Array.isArray($))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new v2({items:$,typeName:F0.ZodTuple,rest:null,...A0(Q)})};class Q8 extends D0{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse($){let{status:Q,ctx:J}=this._processInputParams($);if(J.parsedType!==$0.object)return X0(J,{code:o.invalid_type,expected:$0.object,received:J.parsedType}),w0;let q=[],X=this._def.keyType,Y=this._def.valueType;for(let G in J.data)q.push({key:X._parse(new w2(J,G,J.path,G)),value:Y._parse(new w2(J,J.data[G],J.path,G)),alwaysSet:G in J.data});if(J.common.async)return m0.mergeObjectAsync(Q,q);else return m0.mergeObjectSync(Q,q)}get element(){return this._def.valueType}static create($,Q,J){if(Q instanceof D0)return new Q8({keyType:$,valueType:Q,typeName:F0.ZodRecord,...A0(J)});return new Q8({keyType:H2.create(),valueType:$,typeName:F0.ZodRecord,...A0(Q)})}}class J8 extends D0{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse($){let{status:Q,ctx:J}=this._processInputParams($);if(J.parsedType!==$0.map)return X0(J,{code:o.invalid_type,expected:$0.map,received:J.parsedType}),w0;let q=this._def.keyType,X=this._def.valueType,Y=[...J.data.entries()].map(([G,B],W)=>{return{key:q._parse(new w2(J,G,J.path,[W,"key"])),value:X._parse(new w2(J,B,J.path,[W,"value"]))}});if(J.common.async){let G=new Map;return Promise.resolve().then(async()=>{for(let B of Y){let W=await B.key,U=await B.value;if(W.status==="aborted"||U.status==="aborted")return w0;if(W.status==="dirty"||U.status==="dirty")Q.dirty();G.set(W.value,U.value)}return{status:Q.value,value:G}})}else{let G=new Map;for(let B of Y){let{key:W,value:U}=B;if(W.status==="aborted"||U.status==="aborted")return w0;if(W.status==="dirty"||U.status==="dirty")Q.dirty();G.set(W.value,U.value)}return{status:Q.value,value:G}}}}J8.create=($,Q,J)=>{return new J8({valueType:Q,keyType:$,typeName:F0.ZodMap,...A0(J)})};class Z1 extends D0{_parse($){let{status:Q,ctx:J}=this._processInputParams($);if(J.parsedType!==$0.set)return X0(J,{code:o.invalid_type,expected:$0.set,received:J.parsedType}),w0;let q=this._def;if(q.minSize!==null){if(J.data.size<q.minSize.value)X0(J,{code:o.too_small,minimum:q.minSize.value,type:"set",inclusive:!0,exact:!1,message:q.minSize.message}),Q.dirty()}if(q.maxSize!==null){if(J.data.size>q.maxSize.value)X0(J,{code:o.too_big,maximum:q.maxSize.value,type:"set",inclusive:!0,exact:!1,message:q.maxSize.message}),Q.dirty()}let X=this._def.valueType;function Y(B){let W=new Set;for(let U of B){if(U.status==="aborted")return w0;if(U.status==="dirty")Q.dirty();W.add(U.value)}return{status:Q.value,value:W}}let G=[...J.data.values()].map((B,W)=>X._parse(new w2(J,B,J.path,W)));if(J.common.async)return Promise.all(G).then((B)=>Y(B));else return Y(G)}min($,Q){return new Z1({...this._def,minSize:{value:$,message:V0.toString(Q)}})}max($,Q){return new Z1({...this._def,maxSize:{value:$,message:V0.toString(Q)}})}size($,Q){return this.min($,Q).max($,Q)}nonempty($){return this.min(1,$)}}Z1.create=($,Q)=>{return new Z1({valueType:$,minSize:null,maxSize:null,typeName:F0.ZodSet,...A0(Q)})};class B6 extends D0{constructor(){super(...arguments);this.validate=this.implement}_parse($){let{ctx:Q}=this._processInputParams($);if(Q.parsedType!==$0.function)return X0(Q,{code:o.invalid_type,expected:$0.function,received:Q.parsedType}),w0;function J(G,B){return t6({data:G,path:Q.path,errorMaps:[Q.common.contextualErrorMap,Q.schemaErrorMap,X6(),c2].filter((W)=>!!W),issueData:{code:o.invalid_arguments,argumentsError:B}})}function q(G,B){return t6({data:G,path:Q.path,errorMaps:[Q.common.contextualErrorMap,Q.schemaErrorMap,X6(),c2].filter((W)=>!!W),issueData:{code:o.invalid_return_type,returnTypeError:B}})}let X={errorMap:Q.common.contextualErrorMap},Y=Q.data;if(this._def.returns instanceof g1){let G=this;return l0(async function(...B){let W=new s0([]),U=await G._def.args.parseAsync(B,X).catch((w)=>{throw W.addIssue(J(B,w)),W}),V=await Reflect.apply(Y,this,U);return await G._def.returns._def.type.parseAsync(V,X).catch((w)=>{throw W.addIssue(q(V,w)),W})})}else{let G=this;return l0(function(...B){let W=G._def.args.safeParse(B,X);if(!W.success)throw new s0([J(B,W.error)]);let U=Reflect.apply(Y,this,W.data),V=G._def.returns.safeParse(U,X);if(!V.success)throw new s0([q(U,V.error)]);return V.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...$){return new B6({...this._def,args:v2.create($).rest(Y1.create())})}returns($){return new B6({...this._def,returns:$})}implement($){return this.parse($)}strictImplement($){return this.parse($)}static create($,Q,J){return new B6({args:$?$:v2.create([]).rest(Y1.create()),returns:Q||Y1.create(),typeName:F0.ZodFunction,...A0(J)})}}class j6 extends D0{get schema(){return this._def.getter()}_parse($){let{ctx:Q}=this._processInputParams($);return this._def.getter()._parse({data:Q.data,path:Q.path,parent:Q})}}j6.create=($,Q)=>{return new j6({getter:$,typeName:F0.ZodLazy,...A0(Q)})};class M6 extends D0{_parse($){if($.data!==this._def.value){let Q=this._getOrReturnCtx($);return X0(Q,{received:Q.data,code:o.invalid_literal,expected:this._def.value}),w0}return{status:"valid",value:$.data}}get value(){return this._def.value}}M6.create=($,Q)=>{return new M6({value:$,typeName:F0.ZodLiteral,...A0(Q)})};function TJ($,Q){return new U1({values:$,typeName:F0.ZodEnum,...A0(Q)})}class U1 extends D0{_parse($){if(typeof $.data!=="string"){let Q=this._getOrReturnCtx($),J=this._def.values;return X0(Q,{expected:P0.joinValues(J),received:Q.parsedType,code:o.invalid_type}),w0}if(!this._cache)this._cache=new Set(this._def.values);if(!this._cache.has($.data)){let Q=this._getOrReturnCtx($),J=this._def.values;return X0(Q,{received:Q.data,code:o.invalid_enum_value,options:J}),w0}return l0($.data)}get options(){return this._def.values}get enum(){let $={};for(let Q of this._def.values)$[Q]=Q;return $}get Values(){let $={};for(let Q of this._def.values)$[Q]=Q;return $}get Enum(){let $={};for(let Q of this._def.values)$[Q]=Q;return $}extract($,Q=this._def){return U1.create($,{...this._def,...Q})}exclude($,Q=this._def){return U1.create(this.options.filter((J)=>!$.includes(J)),{...this._def,...Q})}}U1.create=TJ;class w6 extends D0{_parse($){let Q=P0.getValidEnumValues(this._def.values),J=this._getOrReturnCtx($);if(J.parsedType!==$0.string&&J.parsedType!==$0.number){let q=P0.objectValues(Q);return X0(J,{expected:P0.joinValues(q),received:J.parsedType,code:o.invalid_type}),w0}if(!this._cache)this._cache=new Set(P0.getValidEnumValues(this._def.values));if(!this._cache.has($.data)){let q=P0.objectValues(Q);return X0(J,{received:J.data,code:o.invalid_enum_value,options:q}),w0}return l0($.data)}get enum(){return this._def.values}}w6.create=($,Q)=>{return new w6({values:$,typeName:F0.ZodNativeEnum,...A0(Q)})};class g1 extends D0{unwrap(){return this._def.type}_parse($){let{ctx:Q}=this._processInputParams($);if(Q.parsedType!==$0.promise&&Q.common.async===!1)return X0(Q,{code:o.invalid_type,expected:$0.promise,received:Q.parsedType}),w0;let J=Q.parsedType===$0.promise?Q.data:Promise.resolve(Q.data);return l0(J.then((q)=>{return this._def.type.parseAsync(q,{path:Q.path,errorMap:Q.common.contextualErrorMap})}))}}g1.create=($,Q)=>{return new g1({type:$,typeName:F0.ZodPromise,...A0(Q)})};class F2 extends D0{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===F0.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse($){let{status:Q,ctx:J}=this._processInputParams($),q=this._def.effect||null,X={addIssue:(Y)=>{if(X0(J,Y),Y.fatal)Q.abort();else Q.dirty()},get path(){return J.path}};if(X.addIssue=X.addIssue.bind(X),q.type==="preprocess"){let Y=q.transform(J.data,X);if(J.common.async)return Promise.resolve(Y).then(async(G)=>{if(Q.value==="aborted")return w0;let B=await this._def.schema._parseAsync({data:G,path:J.path,parent:J});if(B.status==="aborted")return w0;if(B.status==="dirty")return v1(B.value);if(Q.value==="dirty")return v1(B.value);return B});else{if(Q.value==="aborted")return w0;let G=this._def.schema._parseSync({data:Y,path:J.path,parent:J});if(G.status==="aborted")return w0;if(G.status==="dirty")return v1(G.value);if(Q.value==="dirty")return v1(G.value);return G}}if(q.type==="refinement"){let Y=(G)=>{let B=q.refinement(G,X);if(J.common.async)return Promise.resolve(B);if(B instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return G};if(J.common.async===!1){let G=this._def.schema._parseSync({data:J.data,path:J.path,parent:J});if(G.status==="aborted")return w0;if(G.status==="dirty")Q.dirty();return Y(G.value),{status:Q.value,value:G.value}}else return this._def.schema._parseAsync({data:J.data,path:J.path,parent:J}).then((G)=>{if(G.status==="aborted")return w0;if(G.status==="dirty")Q.dirty();return Y(G.value).then(()=>{return{status:Q.value,value:G.value}})})}if(q.type==="transform")if(J.common.async===!1){let Y=this._def.schema._parseSync({data:J.data,path:J.path,parent:J});if(!X1(Y))return w0;let G=q.transform(Y.value,X);if(G instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:Q.value,value:G}}else return this._def.schema._parseAsync({data:J.data,path:J.path,parent:J}).then((Y)=>{if(!X1(Y))return w0;return Promise.resolve(q.transform(Y.value,X)).then((G)=>({status:Q.value,value:G}))});P0.assertNever(q)}}F2.create=($,Q,J)=>{return new F2({schema:$,typeName:F0.ZodEffects,effect:Q,...A0(J)})};F2.createWithPreprocess=($,Q,J)=>{return new F2({schema:Q,effect:{type:"preprocess",transform:$},typeName:F0.ZodEffects,...A0(J)})};class M2 extends D0{_parse($){if(this._getType($)===$0.undefined)return l0(void 0);return this._def.innerType._parse($)}unwrap(){return this._def.innerType}}M2.create=($,Q)=>{return new M2({innerType:$,typeName:F0.ZodOptional,...A0(Q)})};class l2 extends D0{_parse($){if(this._getType($)===$0.null)return l0(null);return this._def.innerType._parse($)}unwrap(){return this._def.innerType}}l2.create=($,Q)=>{return new l2({innerType:$,typeName:F0.ZodNullable,...A0(Q)})};class F6 extends D0{_parse($){let{ctx:Q}=this._processInputParams($),J=Q.data;if(Q.parsedType===$0.undefined)J=this._def.defaultValue();return this._def.innerType._parse({data:J,path:Q.path,parent:Q})}removeDefault(){return this._def.innerType}}F6.create=($,Q)=>{return new F6({innerType:$,typeName:F0.ZodDefault,defaultValue:typeof Q.default==="function"?Q.default:()=>Q.default,...A0(Q)})};class L6 extends D0{_parse($){let{ctx:Q}=this._processInputParams($),J={...Q,common:{...Q.common,issues:[]}},q=this._def.innerType._parse({data:J.data,path:J.path,parent:{...J}});if(Y6(q))return q.then((X)=>{return{status:"valid",value:X.status==="valid"?X.value:this._def.catchValue({get error(){return new s0(J.common.issues)},input:J.data})}});else return{status:"valid",value:q.status==="valid"?q.value:this._def.catchValue({get error(){return new s0(J.common.issues)},input:J.data})}}removeCatch(){return this._def.innerType}}L6.create=($,Q)=>{return new L6({innerType:$,typeName:F0.ZodCatch,catchValue:typeof Q.catch==="function"?Q.catch:()=>Q.catch,...A0(Q)})};class q8 extends D0{_parse($){if(this._getType($)!==$0.nan){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.nan,received:J.parsedType}),w0}return{status:"valid",value:$.data}}}q8.create=($)=>{return new q8({typeName:F0.ZodNaN,...A0($)})};var uW=Symbol("zod_brand");class $5 extends D0{_parse($){let{ctx:Q}=this._processInputParams($),J=Q.data;return this._def.type._parse({data:J,path:Q.path,parent:Q})}unwrap(){return this._def.type}}class X8 extends D0{_parse($){let{status:Q,ctx:J}=this._processInputParams($);if(J.common.async)return(async()=>{let X=await this._def.in._parseAsync({data:J.data,path:J.path,parent:J});if(X.status==="aborted")return w0;if(X.status==="dirty")return Q.dirty(),v1(X.value);else return this._def.out._parseAsync({data:X.value,path:J.path,parent:J})})();else{let q=this._def.in._parseSync({data:J.data,path:J.path,parent:J});if(q.status==="aborted")return w0;if(q.status==="dirty")return Q.dirty(),{status:"dirty",value:q.value};else return this._def.out._parseSync({data:q.value,path:J.path,parent:J})}}static create($,Q){return new X8({in:$,out:Q,typeName:F0.ZodPipeline})}}class z6 extends D0{_parse($){let Q=this._def.innerType._parse($),J=(q)=>{if(X1(q))q.value=Object.freeze(q.value);return q};return Y6(Q)?Q.then((q)=>J(q)):J(Q)}unwrap(){return this._def.innerType}}z6.create=($,Q)=>{return new z6({innerType:$,typeName:F0.ZodReadonly,...A0(Q)})};function SJ($,Q){let J=typeof $==="function"?$(Q):typeof $==="string"?{message:$}:$;return typeof J==="string"?{message:J}:J}function ZJ($,Q={},J){if($)return T1.create().superRefine((q,X)=>{let Y=$(q);if(Y instanceof Promise)return Y.then((G)=>{if(!G){let B=SJ(Q,q),W=B.fatal??J??!0;X.addIssue({code:"custom",...B,fatal:W})}});if(!Y){let G=SJ(Q,q),B=G.fatal??J??!0;X.addIssue({code:"custom",...G,fatal:B})}return});return T1.create()}var cW={object:x0.lazycreate},F0;(function($){$.ZodString="ZodString",$.ZodNumber="ZodNumber",$.ZodNaN="ZodNaN",$.ZodBigInt="ZodBigInt",$.ZodBoolean="ZodBoolean",$.ZodDate="ZodDate",$.ZodSymbol="ZodSymbol",$.ZodUndefined="ZodUndefined",$.ZodNull="ZodNull",$.ZodAny="ZodAny",$.ZodUnknown="ZodUnknown",$.ZodNever="ZodNever",$.ZodVoid="ZodVoid",$.ZodArray="ZodArray",$.ZodObject="ZodObject",$.ZodUnion="ZodUnion",$.ZodDiscriminatedUnion="ZodDiscriminatedUnion",$.ZodIntersection="ZodIntersection",$.ZodTuple="ZodTuple",$.ZodRecord="ZodRecord",$.ZodMap="ZodMap",$.ZodSet="ZodSet",$.ZodFunction="ZodFunction",$.ZodLazy="ZodLazy",$.ZodLiteral="ZodLiteral",$.ZodEnum="ZodEnum",$.ZodEffects="ZodEffects",$.ZodNativeEnum="ZodNativeEnum",$.ZodOptional="ZodOptional",$.ZodNullable="ZodNullable",$.ZodDefault="ZodDefault",$.ZodCatch="ZodCatch",$.ZodPromise="ZodPromise",$.ZodBranded="ZodBranded",$.ZodPipeline="ZodPipeline",$.ZodReadonly="ZodReadonly"})(F0||(F0={}));var pW=($,Q={message:`Input not instance of ${$.name}`})=>ZJ((J)=>J instanceof $,Q),gJ=H2.create,xJ=G1.create,lW=q8.create,dW=B1.create,fJ=U6.create,iW=k1.create,nW=e6.create,oW=W6.create,rW=V6.create,aW=T1.create,sW=Y1.create,tW=E2.create,eW=$8.create,$V=j2.create,QV=x0.create,JV=x0.strictCreate,qV=K6.create,XV=e8.create,YV=H6.create,GV=v2.create,BV=Q8.create,UV=J8.create,WV=Z1.create,VV=B6.create,KV=j6.create,HV=M6.create,jV=U1.create,MV=w6.create,wV=g1.create,FV=F2.create,LV=M2.create,zV=l2.create,OV=F2.createWithPreprocess,NV=X8.create,AV=()=>gJ().optional(),DV=()=>xJ().optional(),PV=()=>fJ().optional(),CV={string:($)=>H2.create({...$,coerce:!0}),number:($)=>G1.create({...$,coerce:!0}),boolean:($)=>U6.create({...$,coerce:!0}),bigint:($)=>B1.create({...$,coerce:!0}),date:($)=>k1.create({...$,coerce:!0})};var RV=w0;class k2 extends Error{field;regex;constructor($,Q,J){super(J);this.field=$,this.regex=Q}}class Y8 extends Error{hash;constructor($){super(`'${$}' not found in the root hash`);this.hash=$}}class i4 extends Map{#J;#$=0;constructor($,Q=[]){super();this.#J=$;for(let[J,q]of Q)this.set(J,q)}get($){let Q=super.get($);if(Q!==void 0)super.delete($),super.set($,Q);return Q}set($,Q){let J=super.get($);if(J===void 0)this.#$+=$.length;else if(J!==null)this.#$-=J.length;if(Q!==null)this.#$+=Q.length;super.delete($);let q;while(this.#$>this.#J&&(q=this.entries().next().value)){let[X,Y]=q;if(super.delete(X),this.#$-=X.length,Y!==null)this.#$-=Y.length}return super.set($,Q),this}delete($){let Q=super.get($);if(Q===void 0)return!1;if(super.delete($),Q!==null)this.#$-=Q.length;return this.#$-=$.length,!0}clear(){super.clear(),this.#$=0}}var mJ=V7(_J(),1);function bJ($){let Q=$.reduce((X,Y)=>X+Y.length,0),J=new Uint8Array(Q),q=0;for(let X of $)J.set(X,q),q+=X.length;return J}var Q5=/^[0-9a-f]{64}$/,uJ=g.object({name:g.string(),timestamp:g.number()}).passthrough(),IV=g.object({name:g.string(),pageId:g.string(),timestamp:g.number()}).passthrough(),SV=g.object({authors:g.array(g.string()).optional(),title:g.string().optional(),publicationDate:g.string().optional(),publisher:g.string().optional()}).passthrough(),EV=g.object({id:g.string(),idx:g.object({timestamp:g.string(),value:g.string()}).passthrough(),template:g.object({timestamp:g.string(),value:g.string()}).passthrough().optional(),redir:g.object({timestamp:g.string(),value:g.number().int()}).passthrough().optional(),scrollTime:g.object({timestamp:g.string(),value:g.string().datetime({offset:!0})}).passthrough().optional(),verticalScroll:g.object({timestamp:g.string(),value:g.number()}).passthrough().optional(),deleted:g.object({timestamp:g.string(),value:g.number().int()}).passthrough().optional()}).passthrough(),vV=g.object({lastOpened:g.object({timestamp:g.string(),value:g.string()}).passthrough(),original:g.object({timestamp:g.string(),value:g.number().int()}).passthrough(),pages:g.array(EV),uuids:g.array(g.object({first:g.string(),second:g.number().int().nonnegative()}).passthrough()).nullable()}).passthrough(),kV=g.object({tags:g.array(uJ).optional()}).strict(),TV=g.object({tags:g.array(g.string()).optional()}).strict(),ZV={coverPageNumber:g.number().int(),documentMetadata:SV,extraMetadata:g.record(g.string(),g.string()),fileType:g.enum(["epub","notebook","pdf"]),fontName:g.string(),lineHeight:g.number().int(),orientation:g.enum(["portrait","landscape"]),pageCount:g.number().int().nonnegative(),textAlignment:g.enum(["","justify","left"]),textScale:g.number()},gV={cPages:vV.optional(),customZoomCenterX:g.number().optional(),customZoomCenterY:g.number().optional(),customZoomOrientation:g.enum(["portrait","landscape"]).optional(),customZoomPageHeight:g.number().optional(),customZoomPageWidth:g.number().optional(),customZoomScale:g.number().optional(),dummyDocument:g.boolean().optional(),formatVersion:g.number().int().nonnegative().optional(),keyboardMetadata:g.object({count:g.number().int().nonnegative(),timestamp:g.number()}).passthrough().optional(),lastOpenedPage:g.number().int().optional(),margins:g.number().int().nonnegative().optional(),originalPageCount:g.number().int().optional(),pages:g.array(g.string()).nullable().optional(),pageTags:g.array(IV).optional(),redirectionPageMap:g.array(g.number().int()).optional(),sizeInBytes:g.string().optional(),transform:g.object({m11:g.number().optional(),m12:g.number().optional(),m13:g.number().optional(),m21:g.number().optional(),m22:g.number().optional(),m23:g.number().optional(),m31:g.number().optional(),m32:g.number().optional(),m33:g.number().optional()}).passthrough().optional(),viewBackgroundFilter:g.enum(["off","fullpage"]).optional(),zoomMode:g.enum(["bestFit","customFit","fitToHeight","fitToWidth"]).optional()},cJ=g.object({...ZV,...gV}).passthrough(),xV=cJ.extend({tags:g.array(uJ).optional()}).passthrough(),fV=cJ.extend({tags:g.array(g.string()).optional()}).passthrough(),yV=g.object({name:g.string(),author:g.string(),iconData:g.string(),categories:g.array(g.string()),labels:g.array(g.string()),orientation:g.enum(["portrait","landscape"]),templateVersion:g.string(),supportedScreens:g.array(g.enum(["rm2","rmPP"])),constants:g.array(g.record(g.string(),g.number().int())).optional(),items:g.array(g.unknown()),formatVersion:g.number().int().nonnegative().optional()}).strict(),_V=g.union([kV,TV,yV,xV,fV]),bV=g.object({lastModified:g.string(),parent:g.string(),pinned:g.boolean(),type:g.enum(["DocumentType","CollectionType","TemplateType"]),visibleName:g.string(),lastOpened:g.string().optional(),lastOpenedPage:g.number().int().optional(),createdTime:g.string().optional(),deleted:g.boolean().optional(),metadatamodified:g.boolean().optional(),modified:g.boolean().optional(),synced:g.boolean().optional(),version:g.number().int().nonnegative().optional(),new:g.boolean().optional(),source:g.string().optional()}).passthrough(),hV=g.object({hash:g.string(),generation:g.number()}).passthrough(),mV=g.object({hash:g.string(),generation:g.number(),schemaVersion:g.number().int().nonnegative()}).passthrough(),uV=g.object({docID:g.string(),hash:g.string()}).passthrough();async function o4($){let Q=await crypto.subtle.digest("SHA-256",$);return new Uint8Array(Q).toHex()}function hJ($){let[Q,J,q,X,Y]=$.split(":");if(Q===void 0||J===void 0||q===void 0||X===void 0||Y===void 0)throw Error(`line '${$}' was not formatted correctly`);else if(J==="80000000"||J==="0")return{hash:Q,type:J==="0"?0:80000000,id:q,subfiles:parseInt(X,10),size:parseInt(Y,10)};else throw Error(`line '${$}' was not formatted correctly`)}class r4{#J;#$;#X;#Q;constructor($,Q,J,q){this.#J=$,this.#Q=Q,this.#$=J,this.#X=q}async getRootHash(){let Q=await(await this.#J("GET",`${this.#$}/sync/v4/root`)).text(),J=JSON.parse(Q),{hash:q,generation:X,schemaVersion:Y}=mV.parse(J);if(Y!==3&&Y!==4)throw Error(`schema version ${Y} not supported`);else if(!Number.isSafeInteger(X))throw Error(`generation ${X} was not a safe integer; please file a bug report`);else return[q,X,Y]}async#q($,Q){if(!Q5.test(Q))throw new k2(Q,Q5,"hash was not a valid hash");let q=await(await this.#J("GET",`${this.#$}/sync/v3/files/${Q}`,{headers:{"rm-filename":$}})).arrayBuffer();return new Uint8Array(q)}async getHash($,Q){let J=this.#Q.get(Q);if(J!=null)return new TextEncoder().encode(J);else{let q=await this.#q($,Q);if(this.#Q.get(Q)===void 0)this.#Q.set(Q,null);return q}}async getText($,Q){let J=this.#Q.get(Q);if(J!=null)return J;else{let q=await this.#q($,Q),Y=new TextDecoder().decode(q);return this.#Q.set(Q,Y),Y}}async getEntries($,Q){let J=await this.getText($,Q),[q,...X]=J.slice(0,-1).split(`
|
|
1
|
+
var $q=Object.create;var{getPrototypeOf:Qq,defineProperty:N6,getOwnPropertyNames:B7,getOwnPropertyDescriptor:Jq}=Object,U7=Object.prototype.hasOwnProperty;function W7($){return this[$]}var qq,Xq,V7=($,Q,J)=>{var q=$!=null&&typeof $==="object";if(q){var X=Q?qq??=new WeakMap:Xq??=new WeakMap,Y=X.get($);if(Y)return Y}J=$!=null?$q(Qq($)):{};let G=Q||!$||!$.__esModule?N6(J,"default",{value:$,enumerable:!0}):J;for(let B of B7($))if(!U7.call(G,B))N6(G,B,{get:W7.bind($,B),enumerable:!0});if(q)X.set($,G);return G},q2=($)=>{var Q=(G7??=new WeakMap).get($),J;if(Q)return Q;if(Q=N6({},"__esModule",{value:!0}),$&&typeof $==="object"||typeof $==="function"){for(var q of B7($))if(!U7.call(Q,q))N6(Q,q,{get:W7.bind($,q),enumerable:!(J=Jq($,q))||J.enumerable})}return G7.set($,Q),Q},G7,j0=($,Q)=>()=>(Q||$((Q={exports:{}}).exports,Q),Q.exports);var Yq=($)=>$;function Gq($,Q){this[$]=Yq.bind(null,Q)}var B5=($,Q)=>{for(var J in Q)N6($,J,{get:Q[J],enumerable:!0,configurable:!0,set:Gq.bind(Q,J)})};var K7=($,Q)=>()=>($&&(Q=$($=0)),Q);var g2={};B5(g2,{transcode:()=>dq,resolveObjectURL:()=>cq,kStringMaxLength:()=>N7,kMaxLength:()=>A6,isUtf8:()=>pq,isAscii:()=>lq,default:()=>iq,constants:()=>Fq,btoa:()=>Hq,atob:()=>jq,INSPECT_MAX_BYTES:()=>O7,File:()=>Mq,Buffer:()=>b,Blob:()=>wq});function Bq($){var Q=$.length;if(Q%4>0)throw Error("Invalid string. Length must be a multiple of 4");var J=$.indexOf("=");if(J===-1)J=Q;var q=J===Q?0:4-J%4;return[J,q]}function Uq($,Q){return($+Q)*3/4-Q}function Wq($){var Q,J=Bq($),q=J[0],X=J[1],Y=new Uint8Array(Uq(q,X)),G=0,B=X>0?q-4:q,W;for(W=0;W<B;W+=4)Q=X2[$.charCodeAt(W)]<<18|X2[$.charCodeAt(W+1)]<<12|X2[$.charCodeAt(W+2)]<<6|X2[$.charCodeAt(W+3)],Y[G++]=Q>>16&255,Y[G++]=Q>>8&255,Y[G++]=Q&255;if(X===2)Q=X2[$.charCodeAt(W)]<<2|X2[$.charCodeAt(W+1)]>>4,Y[G++]=Q&255;if(X===1)Q=X2[$.charCodeAt(W)]<<10|X2[$.charCodeAt(W+1)]<<4|X2[$.charCodeAt(W+2)]>>2,Y[G++]=Q>>8&255,Y[G++]=Q&255;return Y}function Vq($){return z2[$>>18&63]+z2[$>>12&63]+z2[$>>6&63]+z2[$&63]}function Kq($,Q,J){var q,X=[];for(var Y=Q;Y<J;Y+=3)q=($[Y]<<16&16711680)+($[Y+1]<<8&65280)+($[Y+2]&255),X.push(Vq(q));return X.join("")}function j7($){var Q,J=$.length,q=J%3,X=[],Y=16383;for(var G=0,B=J-q;G<B;G+=Y)X.push(Kq($,G,G+Y>B?B:G+Y));if(q===1)Q=$[J-1],X.push(z2[Q>>2]+z2[Q<<4&63]+"==");else if(q===2)Q=($[J-2]<<8)+$[J-1],X.push(z2[Q>>10]+z2[Q>>4&63]+z2[Q<<2&63]+"=");return X.join("")}function G8($,Q,J,q,X){var Y,G,B=X*8-q-1,W=(1<<B)-1,U=W>>1,V=-7,L=J?X-1:0,w=J?-1:1,M=$[Q+L];L+=w,Y=M&(1<<-V)-1,M>>=-V,V+=B;for(;V>0;Y=Y*256+$[Q+L],L+=w,V-=8);G=Y&(1<<-V)-1,Y>>=-V,V+=q;for(;V>0;G=G*256+$[Q+L],L+=w,V-=8);if(Y===0)Y=1-U;else if(Y===W)return G?NaN:(M?-1:1)*(1/0);else G=G+Math.pow(2,q),Y=Y-U;return(M?-1:1)*G*Math.pow(2,Y-q)}function z7($,Q,J,q,X,Y){var G,B,W,U=Y*8-X-1,V=(1<<U)-1,L=V>>1,w=X===23?Math.pow(2,-24)-Math.pow(2,-77):0,M=q?0:Y-1,y=q?1:-1,x=Q<0||Q===0&&1/Q<0?1:0;if(Q=Math.abs(Q),isNaN(Q)||Q===1/0)B=isNaN(Q)?1:0,G=V;else{if(G=Math.floor(Math.log(Q)/Math.LN2),Q*(W=Math.pow(2,-G))<1)G--,W*=2;if(G+L>=1)Q+=w/W;else Q+=w*Math.pow(2,1-L);if(Q*W>=2)G++,W/=2;if(G+L>=V)B=0,G=V;else if(G+L>=1)B=(Q*W-1)*Math.pow(2,X),G=G+L;else B=Q*Math.pow(2,L-1)*Math.pow(2,X),G=0}for(;X>=8;$[J+M]=B&255,M+=y,B/=256,X-=8);G=G<<X|B,U+=X;for(;U>0;$[J+M]=G&255,M+=y,G/=256,U-=8);$[J+M-y]|=x*128}function Z2($){if($>A6)throw RangeError('The value "'+$+'" is invalid for option "size"');let Q=new Uint8Array($);return Object.setPrototypeOf(Q,b.prototype),Q}function j5($,Q,J){return class extends J{constructor(){super();Object.defineProperty(this,"message",{value:Q.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${$}]`,this.stack,delete this.name}get code(){return $}set code(q){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:q,writable:!0})}toString(){return`${this.name} [${$}]: ${this.message}`}}}function b($,Q,J){if(typeof $==="number"){if(typeof Q==="string")throw TypeError('The "string" argument must be of type string. Received type number');return M5($)}return A7($,Q,J)}function A7($,Q,J){if(typeof $==="string")return Nq($,Q);if(ArrayBuffer.isView($))return Aq($);if($==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof $);if(O2($,ArrayBuffer)||$&&O2($.buffer,ArrayBuffer))return K5($,Q,J);if(typeof SharedArrayBuffer<"u"&&(O2($,SharedArrayBuffer)||$&&O2($.buffer,SharedArrayBuffer)))return K5($,Q,J);if(typeof $==="number")throw TypeError('The "value" argument must not be of type number. Received type number');let q=$.valueOf&&$.valueOf();if(q!=null&&q!==$)return b.from(q,Q,J);let X=Dq($);if(X)return X;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof $[Symbol.toPrimitive]==="function")return b.from($[Symbol.toPrimitive]("string"),Q,J);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof $)}function D7($){if(typeof $!=="number")throw TypeError('"size" argument must be of type number');else if($<0)throw RangeError('The value "'+$+'" is invalid for option "size"')}function Oq($,Q,J){if(D7($),$<=0)return Z2($);if(Q!==void 0)return typeof J==="string"?Z2($).fill(Q,J):Z2($).fill(Q);return Z2($)}function M5($){return D7($),Z2($<0?0:w5($)|0)}function Nq($,Q){if(typeof Q!=="string"||Q==="")Q="utf8";if(!b.isEncoding(Q))throw TypeError("Unknown encoding: "+Q);let J=P7($,Q)|0,q=Z2(J),X=q.write($,Q);if(X!==J)q=q.slice(0,X);return q}function V5($){let Q=$.length<0?0:w5($.length)|0,J=Z2(Q);for(let q=0;q<Q;q+=1)J[q]=$[q]&255;return J}function Aq($){if(O2($,Uint8Array)){let Q=new Uint8Array($);return K5(Q.buffer,Q.byteOffset,Q.byteLength)}return V5($)}function K5($,Q,J){if(Q<0||$.byteLength<Q)throw RangeError('"offset" is outside of buffer bounds');if($.byteLength<Q+(J||0))throw RangeError('"length" is outside of buffer bounds');let q;if(Q===void 0&&J===void 0)q=new Uint8Array($);else if(J===void 0)q=new Uint8Array($,Q);else q=new Uint8Array($,Q,J);return Object.setPrototypeOf(q,b.prototype),q}function Dq($){if(b.isBuffer($)){let Q=w5($.length)|0,J=Z2(Q);if(J.length===0)return J;return $.copy(J,0,0,Q),J}if($.length!==void 0){if(typeof $.length!=="number"||Number.isNaN($.length))return Z2(0);return V5($)}if($.type==="Buffer"&&Array.isArray($.data))return V5($.data)}function w5($){if($>=A6)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+A6.toString(16)+" bytes");return $|0}function P7($,Q){if(b.isBuffer($))return $.length;if(ArrayBuffer.isView($)||O2($,ArrayBuffer))return $.byteLength;if(typeof $!=="string")throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof $);let J=$.length,q=arguments.length>2&&arguments[2]===!0;if(!q&&J===0)return 0;let X=!1;for(;;)switch(Q){case"ascii":case"latin1":case"binary":return J;case"utf8":case"utf-8":return H5($).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return J*2;case"hex":return J>>>1;case"base64":return Z7($).length;default:if(X)return q?-1:H5($).length;Q=(""+Q).toLowerCase(),X=!0}}function Pq($,Q,J){let q=!1;if(Q===void 0||Q<0)Q=0;if(Q>this.length)return"";if(J===void 0||J>this.length)J=this.length;if(J<=0)return"";if(J>>>=0,Q>>>=0,J<=Q)return"";if(!$)$="utf8";while(!0)switch($){case"hex":return gq(this,Q,J);case"utf8":case"utf-8":return C7(this,Q,J);case"ascii":return Tq(this,Q,J);case"latin1":case"binary":return Zq(this,Q,J);case"base64":return vq(this,Q,J);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return xq(this,Q,J);default:if(q)throw TypeError("Unknown encoding: "+$);$=($+"").toLowerCase(),q=!0}}function M1($,Q,J){let q=$[Q];$[Q]=$[J],$[J]=q}function R7($,Q,J,q,X){if($.length===0)return-1;if(typeof J==="string")q=J,J=0;else if(J>2147483647)J=2147483647;else if(J<-2147483648)J=-2147483648;if(J=+J,Number.isNaN(J))J=X?0:$.length-1;if(J<0)J=$.length+J;if(J>=$.length)if(X)return-1;else J=$.length-1;else if(J<0)if(X)J=0;else return-1;if(typeof Q==="string")Q=b.from(Q,q);if(b.isBuffer(Q)){if(Q.length===0)return-1;return w7($,Q,J,q,X)}else if(typeof Q==="number"){if(Q=Q&255,typeof Uint8Array.prototype.indexOf==="function")if(X)return Uint8Array.prototype.indexOf.call($,Q,J);else return Uint8Array.prototype.lastIndexOf.call($,Q,J);return w7($,[Q],J,q,X)}throw TypeError("val must be string, number or Buffer")}function w7($,Q,J,q,X){let Y=1,G=$.length,B=Q.length;if(q!==void 0){if(q=String(q).toLowerCase(),q==="ucs2"||q==="ucs-2"||q==="utf16le"||q==="utf-16le"){if($.length<2||Q.length<2)return-1;Y=2,G/=2,B/=2,J/=2}}function W(V,L){if(Y===1)return V[L];else return V.readUInt16BE(L*Y)}let U;if(X){let V=-1;for(U=J;U<G;U++)if(W($,U)===W(Q,V===-1?0:U-V)){if(V===-1)V=U;if(U-V+1===B)return V*Y}else{if(V!==-1)U-=U-V;V=-1}}else{if(J+B>G)J=G-B;for(U=J;U>=0;U--){let V=!0;for(let L=0;L<B;L++)if(W($,U+L)!==W(Q,L)){V=!1;break}if(V)return U}}return-1}function Rq($,Q,J,q){J=Number(J)||0;let X=$.length-J;if(!q)q=X;else if(q=Number(q),q>X)q=X;let Y=Q.length;if(q>Y/2)q=Y/2;let G;for(G=0;G<q;++G){let B=parseInt(Q.substr(G*2,2),16);if(Number.isNaN(B))return G;$[J+G]=B}return G}function Cq($,Q,J,q){return B8(H5(Q,$.length-J),$,J,q)}function Iq($,Q,J,q){return B8(bq(Q),$,J,q)}function Sq($,Q,J,q){return B8(Z7(Q),$,J,q)}function Eq($,Q,J,q){return B8(hq(Q,$.length-J),$,J,q)}function vq($,Q,J){if(Q===0&&J===$.length)return j7($);else return j7($.slice(Q,J))}function C7($,Q,J){J=Math.min($.length,J);let q=[],X=Q;while(X<J){let Y=$[X],G=null,B=Y>239?4:Y>223?3:Y>191?2:1;if(X+B<=J){let W,U,V,L;switch(B){case 1:if(Y<128)G=Y;break;case 2:if(W=$[X+1],(W&192)===128){if(L=(Y&31)<<6|W&63,L>127)G=L}break;case 3:if(W=$[X+1],U=$[X+2],(W&192)===128&&(U&192)===128){if(L=(Y&15)<<12|(W&63)<<6|U&63,L>2047&&(L<55296||L>57343))G=L}break;case 4:if(W=$[X+1],U=$[X+2],V=$[X+3],(W&192)===128&&(U&192)===128&&(V&192)===128){if(L=(Y&15)<<18|(W&63)<<12|(U&63)<<6|V&63,L>65535&&L<1114112)G=L}}}if(G===null)G=65533,B=1;else if(G>65535)G-=65536,q.push(G>>>10&1023|55296),G=56320|G&1023;q.push(G),X+=B}return kq(q)}function kq($){let Q=$.length;if(Q<=F7)return String.fromCharCode.apply(String,$);let J="",q=0;while(q<Q)J+=String.fromCharCode.apply(String,$.slice(q,q+=F7));return J}function Tq($,Q,J){let q="";J=Math.min($.length,J);for(let X=Q;X<J;++X)q+=String.fromCharCode($[X]&127);return q}function Zq($,Q,J){let q="";J=Math.min($.length,J);for(let X=Q;X<J;++X)q+=String.fromCharCode($[X]);return q}function gq($,Q,J){let q=$.length;if(!Q||Q<0)Q=0;if(!J||J<0||J>q)J=q;let X="";for(let Y=Q;Y<J;++Y)X+=mq[$[Y]];return X}function xq($,Q,J){let q=$.slice(Q,J),X="";for(let Y=0;Y<q.length-1;Y+=2)X+=String.fromCharCode(q[Y]+q[Y+1]*256);return X}function _0($,Q,J){if($%1!==0||$<0)throw RangeError("offset is not uint");if($+Q>J)throw RangeError("Trying to access beyond buffer length")}function o0($,Q,J,q,X,Y){if(!b.isBuffer($))throw TypeError('"buffer" argument must be a Buffer instance');if(Q>X||Q<Y)throw RangeError('"value" argument is out of bounds');if(J+q>$.length)throw RangeError("Index out of range")}function I7($,Q,J,q,X){T7(Q,q,X,$,J,7);let Y=Number(Q&BigInt(4294967295));$[J++]=Y,Y=Y>>8,$[J++]=Y,Y=Y>>8,$[J++]=Y,Y=Y>>8,$[J++]=Y;let G=Number(Q>>BigInt(32)&BigInt(4294967295));return $[J++]=G,G=G>>8,$[J++]=G,G=G>>8,$[J++]=G,G=G>>8,$[J++]=G,J}function S7($,Q,J,q,X){T7(Q,q,X,$,J,7);let Y=Number(Q&BigInt(4294967295));$[J+7]=Y,Y=Y>>8,$[J+6]=Y,Y=Y>>8,$[J+5]=Y,Y=Y>>8,$[J+4]=Y;let G=Number(Q>>BigInt(32)&BigInt(4294967295));return $[J+3]=G,G=G>>8,$[J+2]=G,G=G>>8,$[J+1]=G,G=G>>8,$[J]=G,J+8}function E7($,Q,J,q,X,Y){if(J+q>$.length)throw RangeError("Index out of range");if(J<0)throw RangeError("Index out of range")}function v7($,Q,J,q,X){if(Q=+Q,J=J>>>0,!X)E7($,Q,J,4,340282346638528860000000000000000000000,-340282346638528860000000000000000000000);return z7($,Q,J,q,23,4),J+4}function k7($,Q,J,q,X){if(Q=+Q,J=J>>>0,!X)E7($,Q,J,8,179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,-179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000);return z7($,Q,J,q,52,8),J+8}function L7($){let Q="",J=$.length,q=$[0]==="-"?1:0;for(;J>=q+4;J-=3)Q=`_${$.slice(J-3,J)}${Q}`;return`${$.slice(0,J)}${Q}`}function fq($,Q,J){if(y1(Q,"offset"),$[Q]===void 0||$[Q+J]===void 0)D6(Q,$.length-(J+1))}function T7($,Q,J,q,X,Y){if($>J||$<Q){let G=typeof Q==="bigint"?"n":"",B;if(Y>3)if(Q===0||Q===BigInt(0))B=`>= 0${G} and < 2${G} ** ${(Y+1)*8}${G}`;else B=`>= -(2${G} ** ${(Y+1)*8-1}${G}) and < 2 ** ${(Y+1)*8-1}${G}`;else B=`>= ${Q}${G} and <= ${J}${G}`;throw new W5("value",B,$)}fq(q,X,Y)}function y1($,Q){if(typeof $!=="number")throw new zq(Q,"number",$)}function D6($,Q,J){if(Math.floor($)!==$)throw y1($,J),new W5(J||"offset","an integer",$);if(Q<0)throw new Lq;throw new W5(J||"offset",`>= ${J?1:0} and <= ${Q}`,$)}function _q($){if($=$.split("=")[0],$=$.trim().replace(yq,""),$.length<2)return"";while($.length%4!==0)$=$+"=";return $}function H5($,Q){Q=Q||1/0;let J,q=$.length,X=null,Y=[];for(let G=0;G<q;++G){if(J=$.charCodeAt(G),J>55295&&J<57344){if(!X){if(J>56319){if((Q-=3)>-1)Y.push(239,191,189);continue}else if(G+1===q){if((Q-=3)>-1)Y.push(239,191,189);continue}X=J;continue}if(J<56320){if((Q-=3)>-1)Y.push(239,191,189);X=J;continue}J=(X-55296<<10|J-56320)+65536}else if(X){if((Q-=3)>-1)Y.push(239,191,189)}if(X=null,J<128){if((Q-=1)<0)break;Y.push(J)}else if(J<2048){if((Q-=2)<0)break;Y.push(J>>6|192,J&63|128)}else if(J<65536){if((Q-=3)<0)break;Y.push(J>>12|224,J>>6&63|128,J&63|128)}else if(J<1114112){if((Q-=4)<0)break;Y.push(J>>18|240,J>>12&63|128,J>>6&63|128,J&63|128)}else throw Error("Invalid code point")}return Y}function bq($){let Q=[];for(let J=0;J<$.length;++J)Q.push($.charCodeAt(J)&255);return Q}function hq($,Q){let J,q,X,Y=[];for(let G=0;G<$.length;++G){if((Q-=2)<0)break;J=$.charCodeAt(G),q=J>>8,X=J%256,Y.push(X),Y.push(q)}return Y}function Z7($){return Wq(_q($))}function B8($,Q,J,q){let X;for(X=0;X<q;++X){if(X+J>=Q.length||X>=$.length)break;Q[X+J]=$[X]}return X}function O2($,Q){return $ instanceof Q||$!=null&&$.constructor!=null&&$.constructor.name!=null&&$.constructor.name===Q.name}function d2($){return typeof BigInt>"u"?uq:$}function uq(){throw Error("BigInt not supported")}function F5($){return()=>{throw Error($+" is not implemented for node:buffer browser polyfill")}}var z2,X2,U5="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",j1,H7,M7,O7=50,A6=2147483647,N7=536870888,Hq,jq,Mq,wq,Fq,Lq,zq,W5,F7=4096,yq,mq,cq,pq,lq=($)=>{for(let Q of $)if(Q.charCodeAt(0)>127)return!1;return!0},dq,iq;var x2=K7(()=>{z2=[],X2=[];for(j1=0,H7=U5.length;j1<H7;++j1)z2[j1]=U5[j1],X2[U5.charCodeAt(j1)]=j1;X2[45]=62;X2[95]=63;M7=typeof Symbol==="function"&&typeof Symbol.for==="function"?Symbol.for("nodejs.util.inspect.custom"):null,Hq=globalThis.btoa,jq=globalThis.atob,Mq=globalThis.File,wq=globalThis.Blob,Fq={MAX_LENGTH:A6,MAX_STRING_LENGTH:N7};Lq=j5("ERR_BUFFER_OUT_OF_BOUNDS",function($){if($)return`${$} is outside of buffer bounds`;return"Attempt to access memory outside buffer bounds"},RangeError),zq=j5("ERR_INVALID_ARG_TYPE",function($,Q){return`The "${$}" argument must be of type number. Received type ${typeof Q}`},TypeError),W5=j5("ERR_OUT_OF_RANGE",function($,Q,J){let q=`The value of "${$}" is out of range.`,X=J;if(Number.isInteger(J)&&Math.abs(J)>4294967296)X=L7(String(J));else if(typeof J==="bigint"){if(X=String(J),J>BigInt(2)**BigInt(32)||J<-(BigInt(2)**BigInt(32)))X=L7(X);X+="n"}return q+=` It must be ${Q}. Received ${X}`,q},RangeError);Object.defineProperty(b.prototype,"parent",{enumerable:!0,get:function(){if(!b.isBuffer(this))return;return this.buffer}});Object.defineProperty(b.prototype,"offset",{enumerable:!0,get:function(){if(!b.isBuffer(this))return;return this.byteOffset}});b.poolSize=8192;b.from=function($,Q,J){return A7($,Q,J)};Object.setPrototypeOf(b.prototype,Uint8Array.prototype);Object.setPrototypeOf(b,Uint8Array);b.alloc=function($,Q,J){return Oq($,Q,J)};b.allocUnsafe=function($){return M5($)};b.allocUnsafeSlow=function($){return M5($)};b.isBuffer=function($){return $!=null&&$._isBuffer===!0&&$!==b.prototype};b.compare=function($,Q){if(O2($,Uint8Array))$=b.from($,$.offset,$.byteLength);if(O2(Q,Uint8Array))Q=b.from(Q,Q.offset,Q.byteLength);if(!b.isBuffer($)||!b.isBuffer(Q))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if($===Q)return 0;let J=$.length,q=Q.length;for(let X=0,Y=Math.min(J,q);X<Y;++X)if($[X]!==Q[X]){J=$[X],q=Q[X];break}if(J<q)return-1;if(q<J)return 1;return 0};b.isEncoding=function($){switch(String($).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};b.concat=function($,Q){if(!Array.isArray($))throw TypeError('"list" argument must be an Array of Buffers');if($.length===0)return b.alloc(0);let J;if(Q===void 0){Q=0;for(J=0;J<$.length;++J)Q+=$[J].length}let q=b.allocUnsafe(Q),X=0;for(J=0;J<$.length;++J){let Y=$[J];if(O2(Y,Uint8Array))if(X+Y.length>q.length){if(!b.isBuffer(Y))Y=b.from(Y);Y.copy(q,X)}else Uint8Array.prototype.set.call(q,Y,X);else if(!b.isBuffer(Y))throw TypeError('"list" argument must be an Array of Buffers');else Y.copy(q,X);X+=Y.length}return q};b.byteLength=P7;b.prototype._isBuffer=!0;b.prototype.swap16=function(){let $=this.length;if($%2!==0)throw RangeError("Buffer size must be a multiple of 16-bits");for(let Q=0;Q<$;Q+=2)M1(this,Q,Q+1);return this};b.prototype.swap32=function(){let $=this.length;if($%4!==0)throw RangeError("Buffer size must be a multiple of 32-bits");for(let Q=0;Q<$;Q+=4)M1(this,Q,Q+3),M1(this,Q+1,Q+2);return this};b.prototype.swap64=function(){let $=this.length;if($%8!==0)throw RangeError("Buffer size must be a multiple of 64-bits");for(let Q=0;Q<$;Q+=8)M1(this,Q,Q+7),M1(this,Q+1,Q+6),M1(this,Q+2,Q+5),M1(this,Q+3,Q+4);return this};b.prototype.toString=function(){let $=this.length;if($===0)return"";if(arguments.length===0)return C7(this,0,$);return Pq.apply(this,arguments)};b.prototype.toLocaleString=b.prototype.toString;b.prototype.equals=function($){if(!b.isBuffer($))throw TypeError("Argument must be a Buffer");if(this===$)return!0;return b.compare(this,$)===0};b.prototype.inspect=function(){let $="",Q=O7;if($=this.toString("hex",0,Q).replace(/(.{2})/g,"$1 ").trim(),this.length>Q)$+=" ... ";return"<Buffer "+$+">"};if(M7)b.prototype[M7]=b.prototype.inspect;b.prototype.compare=function($,Q,J,q,X){if(O2($,Uint8Array))$=b.from($,$.offset,$.byteLength);if(!b.isBuffer($))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof $);if(Q===void 0)Q=0;if(J===void 0)J=$?$.length:0;if(q===void 0)q=0;if(X===void 0)X=this.length;if(Q<0||J>$.length||q<0||X>this.length)throw RangeError("out of range index");if(q>=X&&Q>=J)return 0;if(q>=X)return-1;if(Q>=J)return 1;if(Q>>>=0,J>>>=0,q>>>=0,X>>>=0,this===$)return 0;let Y=X-q,G=J-Q,B=Math.min(Y,G),W=this.slice(q,X),U=$.slice(Q,J);for(let V=0;V<B;++V)if(W[V]!==U[V]){Y=W[V],G=U[V];break}if(Y<G)return-1;if(G<Y)return 1;return 0};b.prototype.includes=function($,Q,J){return this.indexOf($,Q,J)!==-1};b.prototype.indexOf=function($,Q,J){return R7(this,$,Q,J,!0)};b.prototype.lastIndexOf=function($,Q,J){return R7(this,$,Q,J,!1)};b.prototype.write=function($,Q,J,q){if(Q===void 0)q="utf8",J=this.length,Q=0;else if(J===void 0&&typeof Q==="string")q=Q,J=this.length,Q=0;else if(isFinite(Q))if(Q=Q>>>0,isFinite(J)){if(J=J>>>0,q===void 0)q="utf8"}else q=J,J=void 0;else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let X=this.length-Q;if(J===void 0||J>X)J=X;if($.length>0&&(J<0||Q<0)||Q>this.length)throw RangeError("Attempt to write outside buffer bounds");if(!q)q="utf8";let Y=!1;for(;;)switch(q){case"hex":return Rq(this,$,Q,J);case"utf8":case"utf-8":return Cq(this,$,Q,J);case"ascii":case"latin1":case"binary":return Iq(this,$,Q,J);case"base64":return Sq(this,$,Q,J);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Eq(this,$,Q,J);default:if(Y)throw TypeError("Unknown encoding: "+q);q=(""+q).toLowerCase(),Y=!0}};b.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};b.prototype.slice=function($,Q){let J=this.length;if($=~~$,Q=Q===void 0?J:~~Q,$<0){if($+=J,$<0)$=0}else if($>J)$=J;if(Q<0){if(Q+=J,Q<0)Q=0}else if(Q>J)Q=J;if(Q<$)Q=$;let q=this.subarray($,Q);return Object.setPrototypeOf(q,b.prototype),q};b.prototype.readUintLE=b.prototype.readUIntLE=function($,Q,J){if($=$>>>0,Q=Q>>>0,!J)_0($,Q,this.length);let q=this[$],X=1,Y=0;while(++Y<Q&&(X*=256))q+=this[$+Y]*X;return q};b.prototype.readUintBE=b.prototype.readUIntBE=function($,Q,J){if($=$>>>0,Q=Q>>>0,!J)_0($,Q,this.length);let q=this[$+--Q],X=1;while(Q>0&&(X*=256))q+=this[$+--Q]*X;return q};b.prototype.readUint8=b.prototype.readUInt8=function($,Q){if($=$>>>0,!Q)_0($,1,this.length);return this[$]};b.prototype.readUint16LE=b.prototype.readUInt16LE=function($,Q){if($=$>>>0,!Q)_0($,2,this.length);return this[$]|this[$+1]<<8};b.prototype.readUint16BE=b.prototype.readUInt16BE=function($,Q){if($=$>>>0,!Q)_0($,2,this.length);return this[$]<<8|this[$+1]};b.prototype.readUint32LE=b.prototype.readUInt32LE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return(this[$]|this[$+1]<<8|this[$+2]<<16)+this[$+3]*16777216};b.prototype.readUint32BE=b.prototype.readUInt32BE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return this[$]*16777216+(this[$+1]<<16|this[$+2]<<8|this[$+3])};b.prototype.readBigUInt64LE=d2(function($){$=$>>>0,y1($,"offset");let Q=this[$],J=this[$+7];if(Q===void 0||J===void 0)D6($,this.length-8);let q=Q+this[++$]*256+this[++$]*65536+this[++$]*16777216,X=this[++$]+this[++$]*256+this[++$]*65536+J*16777216;return BigInt(q)+(BigInt(X)<<BigInt(32))});b.prototype.readBigUInt64BE=d2(function($){$=$>>>0,y1($,"offset");let Q=this[$],J=this[$+7];if(Q===void 0||J===void 0)D6($,this.length-8);let q=Q*16777216+this[++$]*65536+this[++$]*256+this[++$],X=this[++$]*16777216+this[++$]*65536+this[++$]*256+J;return(BigInt(q)<<BigInt(32))+BigInt(X)});b.prototype.readIntLE=function($,Q,J){if($=$>>>0,Q=Q>>>0,!J)_0($,Q,this.length);let q=this[$],X=1,Y=0;while(++Y<Q&&(X*=256))q+=this[$+Y]*X;if(X*=128,q>=X)q-=Math.pow(2,8*Q);return q};b.prototype.readIntBE=function($,Q,J){if($=$>>>0,Q=Q>>>0,!J)_0($,Q,this.length);let q=Q,X=1,Y=this[$+--q];while(q>0&&(X*=256))Y+=this[$+--q]*X;if(X*=128,Y>=X)Y-=Math.pow(2,8*Q);return Y};b.prototype.readInt8=function($,Q){if($=$>>>0,!Q)_0($,1,this.length);if(!(this[$]&128))return this[$];return(255-this[$]+1)*-1};b.prototype.readInt16LE=function($,Q){if($=$>>>0,!Q)_0($,2,this.length);let J=this[$]|this[$+1]<<8;return J&32768?J|4294901760:J};b.prototype.readInt16BE=function($,Q){if($=$>>>0,!Q)_0($,2,this.length);let J=this[$+1]|this[$]<<8;return J&32768?J|4294901760:J};b.prototype.readInt32LE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return this[$]|this[$+1]<<8|this[$+2]<<16|this[$+3]<<24};b.prototype.readInt32BE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return this[$]<<24|this[$+1]<<16|this[$+2]<<8|this[$+3]};b.prototype.readBigInt64LE=d2(function($){$=$>>>0,y1($,"offset");let Q=this[$],J=this[$+7];if(Q===void 0||J===void 0)D6($,this.length-8);let q=this[$+4]+this[$+5]*256+this[$+6]*65536+(J<<24);return(BigInt(q)<<BigInt(32))+BigInt(Q+this[++$]*256+this[++$]*65536+this[++$]*16777216)});b.prototype.readBigInt64BE=d2(function($){$=$>>>0,y1($,"offset");let Q=this[$],J=this[$+7];if(Q===void 0||J===void 0)D6($,this.length-8);let q=(Q<<24)+this[++$]*65536+this[++$]*256+this[++$];return(BigInt(q)<<BigInt(32))+BigInt(this[++$]*16777216+this[++$]*65536+this[++$]*256+J)});b.prototype.readFloatLE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return G8(this,$,!0,23,4)};b.prototype.readFloatBE=function($,Q){if($=$>>>0,!Q)_0($,4,this.length);return G8(this,$,!1,23,4)};b.prototype.readDoubleLE=function($,Q){if($=$>>>0,!Q)_0($,8,this.length);return G8(this,$,!0,52,8)};b.prototype.readDoubleBE=function($,Q){if($=$>>>0,!Q)_0($,8,this.length);return G8(this,$,!1,52,8)};b.prototype.writeUintLE=b.prototype.writeUIntLE=function($,Q,J,q){if($=+$,Q=Q>>>0,J=J>>>0,!q){let G=Math.pow(2,8*J)-1;o0(this,$,Q,J,G,0)}let X=1,Y=0;this[Q]=$&255;while(++Y<J&&(X*=256))this[Q+Y]=$/X&255;return Q+J};b.prototype.writeUintBE=b.prototype.writeUIntBE=function($,Q,J,q){if($=+$,Q=Q>>>0,J=J>>>0,!q){let G=Math.pow(2,8*J)-1;o0(this,$,Q,J,G,0)}let X=J-1,Y=1;this[Q+X]=$&255;while(--X>=0&&(Y*=256))this[Q+X]=$/Y&255;return Q+J};b.prototype.writeUint8=b.prototype.writeUInt8=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,1,255,0);return this[Q]=$&255,Q+1};b.prototype.writeUint16LE=b.prototype.writeUInt16LE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,2,65535,0);return this[Q]=$&255,this[Q+1]=$>>>8,Q+2};b.prototype.writeUint16BE=b.prototype.writeUInt16BE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,2,65535,0);return this[Q]=$>>>8,this[Q+1]=$&255,Q+2};b.prototype.writeUint32LE=b.prototype.writeUInt32LE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,4,4294967295,0);return this[Q+3]=$>>>24,this[Q+2]=$>>>16,this[Q+1]=$>>>8,this[Q]=$&255,Q+4};b.prototype.writeUint32BE=b.prototype.writeUInt32BE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,4,4294967295,0);return this[Q]=$>>>24,this[Q+1]=$>>>16,this[Q+2]=$>>>8,this[Q+3]=$&255,Q+4};b.prototype.writeBigUInt64LE=d2(function($,Q=0){return I7(this,$,Q,BigInt(0),BigInt("0xffffffffffffffff"))});b.prototype.writeBigUInt64BE=d2(function($,Q=0){return S7(this,$,Q,BigInt(0),BigInt("0xffffffffffffffff"))});b.prototype.writeIntLE=function($,Q,J,q){if($=+$,Q=Q>>>0,!q){let B=Math.pow(2,8*J-1);o0(this,$,Q,J,B-1,-B)}let X=0,Y=1,G=0;this[Q]=$&255;while(++X<J&&(Y*=256)){if($<0&&G===0&&this[Q+X-1]!==0)G=1;this[Q+X]=($/Y>>0)-G&255}return Q+J};b.prototype.writeIntBE=function($,Q,J,q){if($=+$,Q=Q>>>0,!q){let B=Math.pow(2,8*J-1);o0(this,$,Q,J,B-1,-B)}let X=J-1,Y=1,G=0;this[Q+X]=$&255;while(--X>=0&&(Y*=256)){if($<0&&G===0&&this[Q+X+1]!==0)G=1;this[Q+X]=($/Y>>0)-G&255}return Q+J};b.prototype.writeInt8=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,1,127,-128);if($<0)$=255+$+1;return this[Q]=$&255,Q+1};b.prototype.writeInt16LE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,2,32767,-32768);return this[Q]=$&255,this[Q+1]=$>>>8,Q+2};b.prototype.writeInt16BE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,2,32767,-32768);return this[Q]=$>>>8,this[Q+1]=$&255,Q+2};b.prototype.writeInt32LE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,4,2147483647,-2147483648);return this[Q]=$&255,this[Q+1]=$>>>8,this[Q+2]=$>>>16,this[Q+3]=$>>>24,Q+4};b.prototype.writeInt32BE=function($,Q,J){if($=+$,Q=Q>>>0,!J)o0(this,$,Q,4,2147483647,-2147483648);if($<0)$=4294967295+$+1;return this[Q]=$>>>24,this[Q+1]=$>>>16,this[Q+2]=$>>>8,this[Q+3]=$&255,Q+4};b.prototype.writeBigInt64LE=d2(function($,Q=0){return I7(this,$,Q,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});b.prototype.writeBigInt64BE=d2(function($,Q=0){return S7(this,$,Q,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});b.prototype.writeFloatLE=function($,Q,J){return v7(this,$,Q,!0,J)};b.prototype.writeFloatBE=function($,Q,J){return v7(this,$,Q,!1,J)};b.prototype.writeDoubleLE=function($,Q,J){return k7(this,$,Q,!0,J)};b.prototype.writeDoubleBE=function($,Q,J){return k7(this,$,Q,!1,J)};b.prototype.copy=function($,Q,J,q){if(!b.isBuffer($))throw TypeError("argument should be a Buffer");if(!J)J=0;if(!q&&q!==0)q=this.length;if(Q>=$.length)Q=$.length;if(!Q)Q=0;if(q>0&&q<J)q=J;if(q===J)return 0;if($.length===0||this.length===0)return 0;if(Q<0)throw RangeError("targetStart out of bounds");if(J<0||J>=this.length)throw RangeError("Index out of range");if(q<0)throw RangeError("sourceEnd out of bounds");if(q>this.length)q=this.length;if($.length-Q<q-J)q=$.length-Q+J;let X=q-J;if(this===$&&typeof Uint8Array.prototype.copyWithin==="function")this.copyWithin(Q,J,q);else Uint8Array.prototype.set.call($,this.subarray(J,q),Q);return X};b.prototype.fill=function($,Q,J,q){if(typeof $==="string"){if(typeof Q==="string")q=Q,Q=0,J=this.length;else if(typeof J==="string")q=J,J=this.length;if(q!==void 0&&typeof q!=="string")throw TypeError("encoding must be a string");if(typeof q==="string"&&!b.isEncoding(q))throw TypeError("Unknown encoding: "+q);if($.length===1){let Y=$.charCodeAt(0);if(q==="utf8"&&Y<128||q==="latin1")$=Y}}else if(typeof $==="number")$=$&255;else if(typeof $==="boolean")$=Number($);if(Q<0||this.length<Q||this.length<J)throw RangeError("Out of range index");if(J<=Q)return this;if(Q=Q>>>0,J=J===void 0?this.length:J>>>0,!$)$=0;let X;if(typeof $==="number")for(X=Q;X<J;++X)this[X]=$;else{let Y=b.isBuffer($)?$:b.from($,q),G=Y.length;if(G===0)throw TypeError('The value "'+$+'" is invalid for argument "value"');for(X=0;X<J-Q;++X)this[X+Q]=Y[X%G]}return this};yq=/[^+/0-9A-Za-z-_]/g;mq=function(){let $=Array(256);for(let Q=0;Q<16;++Q){let J=Q*16;for(let q=0;q<16;++q)$[J+q]="0123456789abcdef"[Q]+"0123456789abcdef"[q]}return $}();cq=F5("resolveObjectURL"),pq=F5("isUtf8"),dq=F5("transcode"),iq=b});var R6={};B5(R6,{setMaxListeners:()=>p7,once:()=>u7,listenerCount:()=>l7,init:()=>i2,getMaxListeners:()=>i7,getEventListeners:()=>c7,default:()=>QX,captureRejectionSymbol:()=>_7,addAbortListener:()=>n7,EventEmitter:()=>i2});function b7($,Q){var{_events:J}=$;if(Q[0]??=Error("Unhandled error."),!J)throw Q[0];var q=J[y7];if(q)for(var X of x7.call(q))X.apply($,Q);var Y=J.error;if(!Y)throw Q[0];for(var X of x7.call(Y))X.apply($,Q);return!0}function rq($,Q,J,q){Q.then(void 0,function(X){queueMicrotask(()=>aq($,X,J,q))})}function aq($,Q,J,q){if(typeof $[g7]==="function")$[g7](Q,J,...q);else try{$[w1]=!1,$.emit("error",Q)}finally{$[w1]=!0}}function h7($,Q,J){J.warned=!0;let q=Error(`Possible EventEmitter memory leak detected. ${J.length} ${String(Q)} listeners added to [${$.constructor.name}]. Use emitter.setMaxListeners() to increase limit`);q.name="MaxListenersExceededWarning",q.emitter=$,q.type=Q,q.count=J.length,console.warn(q)}function m7($,Q,...J){this.removeListener($,Q),Q.apply(this,J)}function u7($,Q,J){var q=J?.signal;if(d7(q,"options.signal"),q?.aborted)throw new L5(void 0,{cause:q?.reason});let{resolve:X,reject:Y,promise:G}=$newPromiseCapability(Promise),B=(V)=>{if($.removeListener(Q,W),q!=null)U8(q,"abort",U);Y(V)},W=(...V)=>{if(typeof $.removeListener==="function")$.removeListener("error",B);if(q!=null)U8(q,"abort",U);X(V)};if(f7($,Q,W,{once:!0}),Q!=="error"&&typeof $.once==="function")$.once("error",B);function U(){U8($,Q,W),U8($,"error",B),Y(new L5(void 0,{cause:q?.reason}))}if(q!=null)f7(q,"abort",U,{once:!0});return G}function c7($,Q){return $.listeners(Q)}function p7($,...Q){O5($,"setMaxListeners",0);var J;if(Q&&(J=Q.length))for(let q=0;q<J;q++)Q[q].setMaxListeners($);else F1=$}function l7($,Q){return $.listenerCount(Q)}function U8($,Q,J,q){if(typeof $.removeListener==="function")$.removeListener(Q,J);else $.removeEventListener(Q,J,q)}function f7($,Q,J,q){if(typeof $.on==="function")if(q.once)$.once(Q,J);else $.on(Q,J);else $.addEventListener(Q,J,q)}function _1($,Q,J){let q=TypeError(`The "${$}" argument must be of type ${Q}. Received ${J}`);return q.code="ERR_INVALID_ARG_TYPE",q}function eq($,Q,J){let q=RangeError(`The "${$}" argument is out of range. It must be ${Q}. Received ${J}`);return q.code="ERR_OUT_OF_RANGE",q}function d7($,Q){if($!==void 0&&($===null||typeof $!=="object"||!("aborted"in $)))throw _1(Q,"AbortSignal",$)}function O5($,Q,J,q){if(typeof $!=="number")throw _1(Q,"number",$);if(J!=null&&$<J||q!=null&&$>q||(J!=null||q!=null)&&Number.isNaN($))throw eq(Q,`${J!=null?`>= ${J}`:""}${J!=null&&q!=null?" && ":""}${q!=null?`<= ${q}`:""}`,$)}function P6($){if(typeof $!=="function")throw TypeError("The listener must be a function")}function $X($,Q){if(typeof $!=="boolean")throw _1(Q,"boolean",$)}function i7($){return $?._maxListeners??F1}function n7($,Q){if($===void 0)throw _1("signal","AbortSignal",$);if(d7($,"signal"),typeof Q!=="function")throw _1("listener","function",Q);let J;if($.aborted)queueMicrotask(()=>Q());else $.addEventListener("abort",Q,{__proto__:null,once:!0}),J=()=>{$.removeEventListener("abort",Q)};return{__proto__:null,[Symbol.dispose](){J?.()}}}var z5,w1,y7,nq,oq,g7,_7,x7,F1=10,i2=function($){if(this._events===void 0||this._events===this.__proto__._events)this._events={__proto__:null},this._eventsCount=0;if(this._maxListeners??=void 0,this[w1]=$?.captureRejections?Boolean($?.captureRejections):k0[w1])this.emit=tq},k0,sq=function($,...Q){if($==="error")return b7(this,Q);var{_events:J}=this;if(J===void 0)return!1;var q=J[$];if(q===void 0)return!1;let X=q.length>1?q.slice():q;for(let Y=0,{length:G}=X;Y<G;Y++){let B=X[Y];switch(Q.length){case 0:B.call(this);break;case 1:B.call(this,Q[0]);break;case 2:B.call(this,Q[0],Q[1]);break;case 3:B.call(this,Q[0],Q[1],Q[2]);break;default:B.apply(this,Q);break}}return!0},tq=function($,...Q){if($==="error")return b7(this,Q);var{_events:J}=this;if(J===void 0)return!1;var q=J[$];if(q===void 0)return!1;let X=q.length>1?q.slice():q;for(let Y=0,{length:G}=X;Y<G;Y++){let B=X[Y],W;switch(Q.length){case 0:W=B.call(this);break;case 1:W=B.call(this,Q[0]);break;case 2:W=B.call(this,Q[0],Q[1]);break;case 3:W=B.call(this,Q[0],Q[1],Q[2]);break;default:W=B.apply(this,Q);break}if(W!==void 0&&typeof W?.then==="function"&&W.then===Promise.prototype.then)rq(this,W,$,Q)}return!0},L5,QX;var C6=K7(()=>{z5=Symbol.for,w1=Symbol("kCapture"),y7=z5("events.errorMonitor"),nq=Symbol("events.maxEventTargetListeners"),oq=Symbol("events.maxEventTargetListenersWarned"),g7=z5("nodejs.rejection"),_7=z5("nodejs.rejection"),x7=Array.prototype.slice,k0=i2.prototype={};k0._events=void 0;k0._eventsCount=0;k0._maxListeners=void 0;k0.setMaxListeners=function($){return O5($,"setMaxListeners",0),this._maxListeners=$,this};k0.constructor=i2;k0.getMaxListeners=function(){return this?._maxListeners??F1};k0.emit=sq;k0.addListener=function($,Q){P6(Q);var J=this._events;if(!J)J=this._events={__proto__:null},this._eventsCount=0;else if(J.newListener)this.emit("newListener",$,Q.listener??Q);var q=J[$];if(!q)J[$]=[Q],this._eventsCount++;else{q.push(Q);var X=this._maxListeners??F1;if(X>0&&q.length>X&&!q.warned)h7(this,$,q)}return this};k0.on=k0.addListener;k0.prependListener=function($,Q){P6(Q);var J=this._events;if(!J)J=this._events={__proto__:null},this._eventsCount=0;else if(J.newListener)this.emit("newListener",$,Q.listener??Q);var q=J[$];if(!q)J[$]=[Q],this._eventsCount++;else{q.unshift(Q);var X=this._maxListeners??F1;if(X>0&&q.length>X&&!q.warned)h7(this,$,q)}return this};k0.once=function($,Q){P6(Q);let J=m7.bind(this,$,Q);return J.listener=Q,this.addListener($,J),this};k0.prependOnceListener=function($,Q){P6(Q);let J=m7.bind(this,$,Q);return J.listener=Q,this.prependListener($,J),this};k0.removeListener=function($,Q){P6(Q);var{_events:J}=this;if(!J)return this;var q=J[$];if(!q)return this;var X=q.length;let Y=-1;for(let G=X-1;G>=0;G--)if(q[G]===Q||q[G].listener===Q){Y=G;break}if(Y<0)return this;if(Y===0)q.shift();else q.splice(Y,1);if(q.length===0)delete J[$],this._eventsCount--;return this};k0.off=k0.removeListener;k0.removeAllListeners=function($){var{_events:Q}=this;if($&&Q){if(Q[$])delete Q[$],this._eventsCount--}else this._events={__proto__:null};return this};k0.listeners=function($){var{_events:Q}=this;if(!Q)return[];var J=Q[$];if(!J)return[];return J.map((q)=>q.listener??q)};k0.rawListeners=function($){var{_events:Q}=this;if(!Q)return[];var J=Q[$];if(!J)return[];return J.slice()};k0.listenerCount=function($){var{_events:Q}=this;if(!Q)return 0;return Q[$]?.length??0};k0.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]};k0[w1]=!1;L5=class L5 extends Error{constructor($="The operation was aborted",Q=void 0){if(Q!==void 0&&typeof Q!=="object")throw _1("options","Object",Q);super($,Q);this.code="ABORT_ERR",this.name="AbortError"}};Object.defineProperties(i2,{captureRejections:{get(){return k0[w1]},set($){$X($,"EventEmitter.captureRejections"),k0[w1]=$},enumerable:!0},defaultMaxListeners:{enumerable:!0,get:()=>{return F1},set:($)=>{O5($,"defaultMaxListeners",0),F1=$}},kMaxEventTargetListeners:{value:nq,enumerable:!1,configurable:!1,writable:!1},kMaxEventTargetListenersWarned:{value:oq,enumerable:!1,configurable:!1,writable:!1}});Object.assign(i2,{once:u7,getEventListeners:c7,getMaxListeners:i7,setMaxListeners:p7,EventEmitter:i2,usingDomains:!1,captureRejectionSymbol:_7,errorMonitor:y7,addAbortListener:n7,init:i2,listenerCount:l7});QX=i2});var H8=j0((aV,Q$)=>{var S0=($,Q)=>()=>(Q||$((Q={exports:{}}).exports,Q),Q.exports),Z0=S0(($,Q)=>{class J extends Error{constructor(q){if(!Array.isArray(q))throw TypeError(`Expected input to be an Array, got ${typeof q}`);let X="";for(let Y=0;Y<q.length;Y++)X+=` ${q[Y].stack}
|
|
2
|
+
`;super(X);this.name="AggregateError",this.errors=q}}Q.exports={AggregateError:J,ArrayIsArray(q){return Array.isArray(q)},ArrayPrototypeIncludes(q,X){return q.includes(X)},ArrayPrototypeIndexOf(q,X){return q.indexOf(X)},ArrayPrototypeJoin(q,X){return q.join(X)},ArrayPrototypeMap(q,X){return q.map(X)},ArrayPrototypePop(q,X){return q.pop(X)},ArrayPrototypePush(q,X){return q.push(X)},ArrayPrototypeSlice(q,X,Y){return q.slice(X,Y)},Error,FunctionPrototypeCall(q,X,...Y){return q.call(X,...Y)},FunctionPrototypeSymbolHasInstance(q,X){return Function.prototype[Symbol.hasInstance].call(q,X)},MathFloor:Math.floor,Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties(q,X){return Object.defineProperties(q,X)},ObjectDefineProperty(q,X,Y){return Object.defineProperty(q,X,Y)},ObjectGetOwnPropertyDescriptor(q,X){return Object.getOwnPropertyDescriptor(q,X)},ObjectKeys(q){return Object.keys(q)},ObjectSetPrototypeOf(q,X){return Object.setPrototypeOf(q,X)},Promise,PromisePrototypeCatch(q,X){return q.catch(X)},PromisePrototypeThen(q,X,Y){return q.then(X,Y)},PromiseReject(q){return Promise.reject(q)},PromiseResolve(q){return Promise.resolve(q)},ReflectApply:Reflect.apply,RegExpPrototypeTest(q,X){return q.test(X)},SafeSet:Set,String,StringPrototypeSlice(q,X,Y){return q.slice(X,Y)},StringPrototypeToLowerCase(q){return q.toLowerCase()},StringPrototypeToUpperCase(q){return q.toUpperCase()},StringPrototypeTrim(q){return q.trim()},Symbol,SymbolFor:Symbol.for,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,SymbolDispose:Symbol.dispose||Symbol("Symbol.dispose"),SymbolAsyncDispose:Symbol.asyncDispose||Symbol("Symbol.asyncDispose"),TypedArrayPrototypeSet(q,X,Y){return q.set(X,Y)},Boolean,Uint8Array}}),o7=S0(($,Q)=>{Q.exports={format(J,...q){return J.replace(/%([sdifj])/g,function(...[X,Y]){let G=q.shift();if(Y==="f")return G.toFixed(6);else if(Y==="j")return JSON.stringify(G);else if(Y==="s"&&typeof G==="object")return`${G.constructor!==Object?G.constructor.name:""} {}`.trim();else return G.toString()})},inspect(J){switch(typeof J){case"string":if(J.includes("'")){if(!J.includes('"'))return`"${J}"`;else if(!J.includes("`")&&!J.includes("${"))return`\`${J}\``}return`'${J}'`;case"number":if(isNaN(J))return"NaN";else if(Object.is(J,-0))return String(J);return J;case"bigint":return`${String(J)}n`;case"boolean":case"undefined":return String(J);case"object":return"{}"}}}}),d0=S0(($,Q)=>{var{format:J,inspect:q}=o7(),{AggregateError:X}=Z0(),Y=globalThis.AggregateError||X,G=Symbol("kIsNodeError"),B=["string","function","number","object","Function","Object","boolean","bigint","symbol"],W=/^([A-Z][a-z0-9]*)+$/,U={};function V(D,K){if(!D)throw new U.ERR_INTERNAL_ASSERTION(K)}function L(D){let K="",F=D.length,z=D[0]==="-"?1:0;for(;F>=z+4;F-=3)K=`_${D.slice(F-3,F)}${K}`;return`${D.slice(0,F)}${K}`}function w(D,K,F){if(typeof K==="function")return V(K.length<=F.length,`Code: ${D}; The provided arguments length (${F.length}) does not match the required ones (${K.length}).`),K(...F);let z=(K.match(/%[dfijoOs]/g)||[]).length;if(V(z===F.length,`Code: ${D}; The provided arguments length (${F.length}) does not match the required ones (${z}).`),F.length===0)return K;return J(K,...F)}function M(D,K,F){if(!F)F=Error;class z extends F{constructor(...R){super(w(D,K,R))}toString(){return`${this.name} [${D}]: ${this.message}`}}Object.defineProperties(z.prototype,{name:{value:F.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${D}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),z.prototype.code=D,z.prototype[G]=!0,U[D]=z}function y(D){let K="__node_internal_"+D.name;return Object.defineProperty(D,"name",{value:K}),D}function x(D,K){if(D&&K&&D!==K){if(Array.isArray(K.errors))return K.errors.push(D),K;let F=new Y([K,D],K.message);return F.code=K.code,F}return D||K}class A extends Error{constructor(D="The operation was aborted",K=void 0){if(K!==void 0&&typeof K!=="object")throw new U.ERR_INVALID_ARG_TYPE("options","Object",K);super(D,K);this.code="ABORT_ERR",this.name="AbortError"}}M("ERR_ASSERTION","%s",Error),M("ERR_INVALID_ARG_TYPE",(D,K,F)=>{if(V(typeof D==="string","'name' must be a string"),!Array.isArray(K))K=[K];let z="The ";if(D.endsWith(" argument"))z+=`${D} `;else z+=`"${D}" ${D.includes(".")?"property":"argument"} `;z+="must be ";let R=[],_=[],T=[];for(let S of K)if(V(typeof S==="string","All expected entries have to be of type string"),B.includes(S))R.push(S.toLowerCase());else if(W.test(S))_.push(S);else V(S!=="object",'The value "object" should be written as "Object"'),T.push(S);if(_.length>0){let S=R.indexOf("object");if(S!==-1)R.splice(R,S,1),_.push("Object")}if(R.length>0){switch(R.length){case 1:z+=`of type ${R[0]}`;break;case 2:z+=`one of type ${R[0]} or ${R[1]}`;break;default:{let S=R.pop();z+=`one of type ${R.join(", ")}, or ${S}`}}if(_.length>0||T.length>0)z+=" or "}if(_.length>0){switch(_.length){case 1:z+=`an instance of ${_[0]}`;break;case 2:z+=`an instance of ${_[0]} or ${_[1]}`;break;default:{let S=_.pop();z+=`an instance of ${_.join(", ")}, or ${S}`}}if(T.length>0)z+=" or "}switch(T.length){case 0:break;case 1:if(T[0].toLowerCase()!==T[0])z+="an ";z+=`${T[0]}`;break;case 2:z+=`one of ${T[0]} or ${T[1]}`;break;default:{let S=T.pop();z+=`one of ${T.join(", ")}, or ${S}`}}if(F==null)z+=`. Received ${F}`;else if(typeof F==="function"&&F.name)z+=`. Received function ${F.name}`;else if(typeof F==="object"){var l;if((l=F.constructor)!==null&&l!==void 0&&l.name)z+=`. Received an instance of ${F.constructor.name}`;else{let S=q(F,{depth:-1});z+=`. Received ${S}`}}else{let S=q(F,{colors:!1});if(S.length>25)S=`${S.slice(0,25)}...`;z+=`. Received type ${typeof F} (${S})`}return z},TypeError),M("ERR_INVALID_ARG_VALUE",(D,K,F="is invalid")=>{let z=q(K);if(z.length>128)z=z.slice(0,128)+"...";return`The ${D.includes(".")?"property":"argument"} '${D}' ${F}. Received ${z}`},TypeError),M("ERR_INVALID_RETURN_VALUE",(D,K,F)=>{var z;let R=F!==null&&F!==void 0&&(z=F.constructor)!==null&&z!==void 0&&z.name?`instance of ${F.constructor.name}`:`type ${typeof F}`;return`Expected ${D} to be returned from the "${K}" function but got ${R}.`},TypeError),M("ERR_MISSING_ARGS",(...D)=>{V(D.length>0,"At least one arg needs to be specified");let K,F=D.length;switch(D=(Array.isArray(D)?D:[D]).map((z)=>`"${z}"`).join(" or "),F){case 1:K+=`The ${D[0]} argument`;break;case 2:K+=`The ${D[0]} and ${D[1]} arguments`;break;default:{let z=D.pop();K+=`The ${D.join(", ")}, and ${z} arguments`}break}return`${K} must be specified`},TypeError),M("ERR_OUT_OF_RANGE",(D,K,F)=>{V(K,'Missing "range" argument');let z;if(Number.isInteger(F)&&Math.abs(F)>4294967296)z=L(String(F));else if(typeof F==="bigint"){z=String(F);let R=BigInt(2)**BigInt(32);if(F>R||F<-R)z=L(z);z+="n"}else z=q(F);return`The value of "${D}" is out of range. It must be ${K}. Received ${z}`},RangeError),M("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),M("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),M("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),M("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),M("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),M("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),M("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),M("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),M("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),M("ERR_STREAM_WRITE_AFTER_END","write after end",Error),M("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),Q.exports={AbortError:A,aggregateTwoErrors:y(x),hideStackFrames:y,codes:U}}),JX=S0(($,Q)=>{Object.defineProperty($,"__esModule",{value:!0});var J=new WeakMap,q=new WeakMap;function X(E){let P=J.get(E);return console.assert(P!=null,"'this' is expected an Event object, but got",E),P}function Y(E){if(E.passiveListener!=null){if(typeof console<"u"&&typeof console.error==="function")console.error("Unable to preventDefault inside passive event listener invocation.",E.passiveListener);return}if(!E.event.cancelable)return;if(E.canceled=!0,typeof E.event.preventDefault==="function")E.event.preventDefault()}function G(E,P){J.set(this,{eventTarget:E,event:P,eventPhase:2,currentTarget:E,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:P.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});let O=Object.keys(P);for(let Z=0;Z<O.length;++Z){let f=O[Z];if(!(f in this))Object.defineProperty(this,f,B(f))}}if(G.prototype={get type(){return X(this).event.type},get target(){return X(this).eventTarget},get currentTarget(){return X(this).currentTarget},composedPath(){let E=X(this).currentTarget;if(E==null)return[];return[E]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return X(this).eventPhase},stopPropagation(){let E=X(this);if(E.stopped=!0,typeof E.event.stopPropagation==="function")E.event.stopPropagation()},stopImmediatePropagation(){let E=X(this);if(E.stopped=!0,E.immediateStopped=!0,typeof E.event.stopImmediatePropagation==="function")E.event.stopImmediatePropagation()},get bubbles(){return Boolean(X(this).event.bubbles)},get cancelable(){return Boolean(X(this).event.cancelable)},preventDefault(){Y(X(this))},get defaultPrevented(){return X(this).canceled},get composed(){return Boolean(X(this).event.composed)},get timeStamp(){return X(this).timeStamp},get srcElement(){return X(this).eventTarget},get cancelBubble(){return X(this).stopped},set cancelBubble(E){if(!E)return;let P=X(this);if(P.stopped=!0,typeof P.event.cancelBubble==="boolean")P.event.cancelBubble=!0},get returnValue(){return!X(this).canceled},set returnValue(E){if(!E)Y(X(this))},initEvent(){}},Object.defineProperty(G.prototype,"constructor",{value:G,configurable:!0,writable:!0}),typeof window<"u"&&typeof window.Event<"u")Object.setPrototypeOf(G.prototype,window.Event.prototype),q.set(window.Event.prototype,G);function B(E){return{get(){return X(this).event[E]},set(P){X(this).event[E]=P},configurable:!0,enumerable:!0}}function W(E){return{value(){let P=X(this).event;return P[E].apply(P,arguments)},configurable:!0,enumerable:!0}}function U(E,P){let O=Object.keys(P);if(O.length===0)return E;function Z(f,k){E.call(this,f,k)}Z.prototype=Object.create(E.prototype,{constructor:{value:Z,configurable:!0,writable:!0}});for(let f=0;f<O.length;++f){let k=O[f];if(!(k in E.prototype)){let s=typeof Object.getOwnPropertyDescriptor(P,k).value==="function";Object.defineProperty(Z.prototype,k,s?W(k):B(k))}}return Z}function V(E){if(E==null||E===Object.prototype)return G;let P=q.get(E);if(P==null)P=U(V(Object.getPrototypeOf(E)),E),q.set(E,P);return P}function L(E,P){return new(V(Object.getPrototypeOf(P)))(E,P)}function w(E){return X(E).immediateStopped}function M(E,P){X(E).eventPhase=P}function y(E,P){X(E).currentTarget=P}function x(E,P){X(E).passiveListener=P}var A=new WeakMap,D=1,K=2,F=3;function z(E){return E!==null&&typeof E==="object"}function R(E){let P=A.get(E);if(P==null)throw TypeError("'this' is expected an EventTarget object, but got another value.");return P}function _(E){return{get(){let P=R(this).get(E);while(P!=null){if(P.listenerType===F)return P.listener;P=P.next}return null},set(P){if(typeof P!=="function"&&!z(P))P=null;let O=R(this),Z=null,f=O.get(E);while(f!=null){if(f.listenerType===F)if(Z!==null)Z.next=f.next;else if(f.next!==null)O.set(E,f.next);else O.delete(E);else Z=f;f=f.next}if(P!==null){let k={listener:P,listenerType:F,passive:!1,once:!1,next:null};if(Z===null)O.set(E,k);else Z.next=k}},configurable:!0,enumerable:!0}}function T(E,P){Object.defineProperty(E,`on${P}`,_(P))}function l(E){function P(){S.call(this)}P.prototype=Object.create(S.prototype,{constructor:{value:P,configurable:!0,writable:!0}});for(let O=0;O<E.length;++O)T(P.prototype,E[O]);return P}function S(){if(this instanceof S){A.set(this,new Map);return}if(arguments.length===1&&Array.isArray(arguments[0]))return l(arguments[0]);if(arguments.length>0){let E=Array(arguments.length);for(let P=0;P<arguments.length;++P)E[P]=arguments[P];return l(E)}throw TypeError("Cannot call a class as a function")}if(S.prototype={addEventListener(E,P,O){if(P==null)return;if(typeof P!=="function"&&!z(P))throw TypeError("'listener' should be a function or an object.");let Z=R(this),f=z(O),k=(f?Boolean(O.capture):Boolean(O))?D:K,s={listener:P,listenerType:k,passive:f&&Boolean(O.passive),once:f&&Boolean(O.once),next:null},J0=Z.get(E);if(J0===void 0){Z.set(E,s);return}let B0=null;while(J0!=null){if(J0.listener===P&&J0.listenerType===k)return;B0=J0,J0=J0.next}B0.next=s},removeEventListener(E,P,O){if(P==null)return;let Z=R(this),f=(z(O)?Boolean(O.capture):Boolean(O))?D:K,k=null,s=Z.get(E);while(s!=null){if(s.listener===P&&s.listenerType===f){if(k!==null)k.next=s.next;else if(s.next!==null)Z.set(E,s.next);else Z.delete(E);return}k=s,s=s.next}},dispatchEvent(E){if(E==null||typeof E.type!=="string")throw TypeError('"event.type" should be a string.');let P=R(this),O=E.type,Z=P.get(O);if(Z==null)return!0;let f=L(this,E),k=null;while(Z!=null){if(Z.once)if(k!==null)k.next=Z.next;else if(Z.next!==null)P.set(O,Z.next);else P.delete(O);else k=Z;if(x(f,Z.passive?Z.listener:null),typeof Z.listener==="function")try{Z.listener.call(this,f)}catch(s){if(typeof console<"u"&&typeof console.error==="function")console.error(s)}else if(Z.listenerType!==F&&typeof Z.listener.handleEvent==="function")Z.listener.handleEvent(f);if(w(f))break;Z=Z.next}return x(f,null),M(f,0),y(f,null),!f.defaultPrevented}},Object.defineProperty(S.prototype,"constructor",{value:S,configurable:!0,writable:!0}),typeof window<"u"&&typeof window.EventTarget<"u")Object.setPrototypeOf(S.prototype,window.EventTarget.prototype);$.defineEventAttribute=T,$.EventTarget=S,$.default=S,Q.exports=S,Q.exports.EventTarget=Q.exports.default=S,Q.exports.defineEventAttribute=T}),I6=S0(($,Q)=>{Object.defineProperty($,"__esModule",{value:!0});var J=JX();class q extends J.EventTarget{constructor(){super();throw TypeError("AbortSignal cannot be constructed directly")}get aborted(){let V=G.get(this);if(typeof V!=="boolean")throw TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this===null?"null":typeof this}`);return V}}J.defineEventAttribute(q.prototype,"abort");function X(){let V=Object.create(q.prototype);return J.EventTarget.call(V),G.set(V,!1),V}function Y(V){if(G.get(V)!==!1)return;G.set(V,!0),V.dispatchEvent({type:"abort"})}var G=new WeakMap;if(Object.defineProperties(q.prototype,{aborted:{enumerable:!0}}),typeof Symbol==="function"&&typeof Symbol.toStringTag==="symbol")Object.defineProperty(q.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortSignal"});class B{constructor(){W.set(this,X())}get signal(){return U(this)}abort(){Y(U(this))}}var W=new WeakMap;function U(V){let L=W.get(V);if(L==null)throw TypeError(`Expected 'this' to be an 'AbortController' object, but got ${V===null?"null":typeof V}`);return L}if(Object.defineProperties(B.prototype,{signal:{enumerable:!0},abort:{enumerable:!0}}),typeof Symbol==="function"&&typeof Symbol.toStringTag==="symbol")Object.defineProperty(B.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortController"});$.AbortController=B,$.AbortSignal=q,$.default=B,Q.exports=B,Q.exports.AbortController=Q.exports.default=B,Q.exports.AbortSignal=q}),r0=S0(($,Q)=>{var J=(x2(),q2(g2)),{format:q,inspect:X}=o7(),{codes:{ERR_INVALID_ARG_TYPE:Y}}=d0(),{kResistStopPropagation:G,AggregateError:B,SymbolDispose:W}=Z0(),U=globalThis.AbortSignal||I6().AbortSignal,V=globalThis.AbortController||I6().AbortController,L=Object.getPrototypeOf(async function(){}).constructor,w=globalThis.Blob||J.Blob,M=typeof w<"u"?function(A){return A instanceof w}:function(A){return!1},y=(A,D)=>{if(A!==void 0&&(A===null||typeof A!=="object"||!("aborted"in A)))throw new Y(D,"AbortSignal",A)},x=(A,D)=>{if(typeof A!=="function")throw new Y(D,"Function",A)};Q.exports={AggregateError:B,kEmptyObject:Object.freeze({}),once(A){let D=!1;return function(...K){if(D)return;D=!0,A.apply(this,K)}},createDeferredPromise:function(){let A,D;return{promise:new Promise((K,F)=>{A=K,D=F}),resolve:A,reject:D}},promisify(A){return new Promise((D,K)=>{A((F,...z)=>{if(F)return K(F);return D(...z)})})},debuglog(){return function(){}},format:q,inspect:X,types:{isAsyncFunction(A){return A instanceof L},isArrayBufferView(A){return ArrayBuffer.isView(A)}},isBlob:M,deprecate(A,D){return A},addAbortListener:(C6(),q2(R6)).addAbortListener||function(A,D){if(A===void 0)throw new Y("signal","AbortSignal",A);y(A,"signal"),x(D,"listener");let K;if(A.aborted)queueMicrotask(()=>D());else A.addEventListener("abort",D,{__proto__:null,once:!0,[G]:!0}),K=()=>{A.removeEventListener("abort",D)};return{__proto__:null,[W](){var F;(F=K)===null||F===void 0||F()}}},AbortSignalAny:U.any||function(A){if(A.length===1)return A[0];let D=new V,K=()=>D.abort();return A.forEach((F)=>{y(F,"signals"),F.addEventListener("abort",K,{once:!0})}),D.signal.addEventListener("abort",()=>{A.forEach((F)=>F.removeEventListener("abort",K))},{once:!0}),D.signal}},Q.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}),S6=S0(($,Q)=>{var{ArrayIsArray:J,ArrayPrototypeIncludes:q,ArrayPrototypeJoin:X,ArrayPrototypeMap:Y,NumberIsInteger:G,NumberIsNaN:B,NumberMAX_SAFE_INTEGER:W,NumberMIN_SAFE_INTEGER:U,NumberParseInt:V,ObjectPrototypeHasOwnProperty:L,RegExpPrototypeExec:w,String:M,StringPrototypeToUpperCase:y,StringPrototypeTrim:x}=Z0(),{hideStackFrames:A,codes:{ERR_SOCKET_BAD_PORT:D,ERR_INVALID_ARG_TYPE:K,ERR_INVALID_ARG_VALUE:F,ERR_OUT_OF_RANGE:z,ERR_UNKNOWN_SIGNAL:R}}=d0(),{normalizeEncoding:_}=r0(),{isAsyncFunction:T,isArrayBufferView:l}=r0().types,S={};function E(I){return I===(I|0)}function P(I){return I===I>>>0}var O=/^[0-7]+$/,Z="must be a 32-bit unsigned integer or an octal string";function f(I,i,q0){if(typeof I>"u")I=q0;if(typeof I==="string"){if(w(O,I)===null)throw new F(i,I,Z);I=V(I,8)}return J0(I,i),I}var k=A((I,i,q0=U,n=W)=>{if(typeof I!=="number")throw new K(i,"number",I);if(!G(I))throw new z(i,"an integer",I);if(I<q0||I>n)throw new z(i,`>= ${q0} && <= ${n}`,I)}),s=A((I,i,q0=-2147483648,n=2147483647)=>{if(typeof I!=="number")throw new K(i,"number",I);if(!G(I))throw new z(i,"an integer",I);if(I<q0||I>n)throw new z(i,`>= ${q0} && <= ${n}`,I)}),J0=A((I,i,q0=!1)=>{if(typeof I!=="number")throw new K(i,"number",I);if(!G(I))throw new z(i,"an integer",I);let n=q0?1:0,H0=4294967295;if(I<n||I>H0)throw new z(i,`>= ${n} && <= ${H0}`,I)});function B0(I,i){if(typeof I!=="string")throw new K(i,"string",I)}function N0(I,i,q0=void 0,n){if(typeof I!=="number")throw new K(i,"number",I);if(q0!=null&&I<q0||n!=null&&I>n||(q0!=null||n!=null)&&B(I))throw new z(i,`${q0!=null?`>= ${q0}`:""}${q0!=null&&n!=null?" && ":""}${n!=null?`<= ${n}`:""}`,I)}var p=A((I,i,q0)=>{if(!q(q0,I)){let n="must be one of: "+X(Y(q0,(H0)=>typeof H0==="string"?`'${H0}'`:M(H0)),", ");throw new F(i,I,n)}});function K0(I,i){if(typeof I!=="boolean")throw new K(i,"boolean",I)}function N(I,i,q0){return I==null||!L(I,i)?q0:I[i]}var d=A((I,i,q0=null)=>{let n=N(q0,"allowArray",!1),H0=N(q0,"allowFunction",!1);if(!N(q0,"nullable",!1)&&I===null||!n&&J(I)||typeof I!=="object"&&(!H0||typeof I!=="function"))throw new K(i,"Object",I)}),Y0=A((I,i)=>{if(I!=null&&typeof I!=="object"&&typeof I!=="function")throw new K(i,"a dictionary",I)}),m=A((I,i,q0=0)=>{if(!J(I))throw new K(i,"Array",I);if(I.length<q0){let n=`must be longer than ${q0}`;throw new F(i,I,n)}});function U0(I,i){m(I,i);for(let q0=0;q0<I.length;q0++)B0(I[q0],`${i}[${q0}]`)}function M0(I,i){m(I,i);for(let q0=0;q0<I.length;q0++)K0(I[q0],`${i}[${q0}]`)}function P0(I,i){m(I,i);for(let q0=0;q0<I.length;q0++){let n=I[q0],H0=`${i}[${q0}]`;if(n==null)throw new K(H0,"AbortSignal",n);L0(n,H0)}}function z0(I,i="signal"){if(B0(I,i),S[I]===void 0){if(S[y(I)]!==void 0)throw new R(I+" (signals must use all capital letters)");throw new R(I)}}var u=A((I,i="buffer")=>{if(!l(I))throw new K(i,["Buffer","TypedArray","DataView"],I)});function c(I,i){let q0=_(i),n=I.length;if(q0==="hex"&&n%2!==0)throw new F("encoding",i,`is invalid for data of length ${n}`)}function t(I,i="Port",q0=!0){if(typeof I!=="number"&&typeof I!=="string"||typeof I==="string"&&x(I).length===0||+I!==+I>>>0||I>65535||I===0&&!q0)throw new D(i,I,q0);return I|0}var L0=A((I,i)=>{if(I!==void 0&&(I===null||typeof I!=="object"||!("aborted"in I)))throw new K(i,"AbortSignal",I)}),O0=A((I,i)=>{if(typeof I!=="function")throw new K(i,"Function",I)}),C=A((I,i)=>{if(typeof I!=="function"||T(I))throw new K(i,"Function",I)}),v=A((I,i)=>{if(I!==void 0)throw new K(i,"undefined",I)});function h(I,i,q0){if(!q(q0,I))throw new K(i,`('${X(q0,"|")}')`,I)}var a=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function Q0(I,i){if(typeof I>"u"||!w(a,I))throw new F(i,I,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}function e(I){if(typeof I==="string")return Q0(I,"hints"),I;else if(J(I)){let i=I.length,q0="";if(i===0)return q0;for(let n=0;n<i;n++){let H0=I[n];if(Q0(H0,"hints"),q0+=H0,n!==i-1)q0+=", "}return q0}throw new F("hints",I,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}Q.exports={isInt32:E,isUint32:P,parseFileMode:f,validateArray:m,validateStringArray:U0,validateBooleanArray:M0,validateAbortSignalArray:P0,validateBoolean:K0,validateBuffer:u,validateDictionary:Y0,validateEncoding:c,validateFunction:O0,validateInt32:s,validateInteger:k,validateNumber:N0,validateObject:d,validateOneOf:p,validatePlainFunction:C,validatePort:t,validateSignalName:z0,validateString:B0,validateUint32:J0,validateUndefined:v,validateUnion:h,validateAbortSignal:L0,validateLinkHeaderValue:e}}),L1=S0(($,Q)=>{Q.exports=globalThis.process}),y2=S0(($,Q)=>{var{SymbolAsyncIterator:J,SymbolIterator:q,SymbolFor:X}=Z0(),Y=X("nodejs.stream.destroyed"),G=X("nodejs.stream.errored"),B=X("nodejs.stream.readable"),W=X("nodejs.stream.writable"),U=X("nodejs.stream.disturbed"),V=X("nodejs.webstream.isClosedPromise"),L=X("nodejs.webstream.controllerErrorFunction");function w(N,d=!1){var Y0;return!!(N&&typeof N.pipe==="function"&&typeof N.on==="function"&&(!d||typeof N.pause==="function"&&typeof N.resume==="function")&&(!N._writableState||((Y0=N._readableState)===null||Y0===void 0?void 0:Y0.readable)!==!1)&&(!N._writableState||N._readableState))}function M(N){var d;return!!(N&&typeof N.write==="function"&&typeof N.on==="function"&&(!N._readableState||((d=N._writableState)===null||d===void 0?void 0:d.writable)!==!1))}function y(N){return!!(N&&typeof N.pipe==="function"&&N._readableState&&typeof N.on==="function"&&typeof N.write==="function")}function x(N){return N&&(N._readableState||N._writableState||typeof N.write==="function"&&typeof N.on==="function"||typeof N.pipe==="function"&&typeof N.on==="function")}function A(N){return!!(N&&!x(N)&&typeof N.pipeThrough==="function"&&typeof N.getReader==="function"&&typeof N.cancel==="function")}function D(N){return!!(N&&!x(N)&&typeof N.getWriter==="function"&&typeof N.abort==="function")}function K(N){return!!(N&&!x(N)&&typeof N.readable==="object"&&typeof N.writable==="object")}function F(N){return A(N)||D(N)||K(N)}function z(N,d){if(N==null)return!1;if(d===!0)return typeof N[J]==="function";if(d===!1)return typeof N[q]==="function";return typeof N[J]==="function"||typeof N[q]==="function"}function R(N){if(!x(N))return null;let{_writableState:d,_readableState:Y0}=N,m=d||Y0;return!!(N.destroyed||N[Y]||m!==null&&m!==void 0&&m.destroyed)}function _(N){if(!M(N))return null;if(N.writableEnded===!0)return!0;let d=N._writableState;if(d!==null&&d!==void 0&&d.errored)return!1;if(typeof(d===null||d===void 0?void 0:d.ended)!=="boolean")return null;return d.ended}function T(N,d){if(!M(N))return null;if(N.writableFinished===!0)return!0;let Y0=N._writableState;if(Y0!==null&&Y0!==void 0&&Y0.errored)return!1;if(typeof(Y0===null||Y0===void 0?void 0:Y0.finished)!=="boolean")return null;return!!(Y0.finished||d===!1&&Y0.ended===!0&&Y0.length===0)}function l(N){if(!w(N))return null;if(N.readableEnded===!0)return!0;let d=N._readableState;if(!d||d.errored)return!1;if(typeof(d===null||d===void 0?void 0:d.ended)!=="boolean")return null;return d.ended}function S(N,d){if(!w(N))return null;let Y0=N._readableState;if(Y0!==null&&Y0!==void 0&&Y0.errored)return!1;if(typeof(Y0===null||Y0===void 0?void 0:Y0.endEmitted)!=="boolean")return null;return!!(Y0.endEmitted||d===!1&&Y0.ended===!0&&Y0.length===0)}function E(N){if(N&&N[B]!=null)return N[B];if(typeof(N===null||N===void 0?void 0:N.readable)!=="boolean")return null;if(R(N))return!1;return w(N)&&N.readable&&!S(N)}function P(N){if(N&&N[W]!=null)return N[W];if(typeof(N===null||N===void 0?void 0:N.writable)!=="boolean")return null;if(R(N))return!1;return M(N)&&N.writable&&!_(N)}function O(N,d){if(!x(N))return null;if(R(N))return!0;if((d===null||d===void 0?void 0:d.readable)!==!1&&E(N))return!1;if((d===null||d===void 0?void 0:d.writable)!==!1&&P(N))return!1;return!0}function Z(N){var d,Y0;if(!x(N))return null;if(N.writableErrored)return N.writableErrored;return(d=(Y0=N._writableState)===null||Y0===void 0?void 0:Y0.errored)!==null&&d!==void 0?d:null}function f(N){var d,Y0;if(!x(N))return null;if(N.readableErrored)return N.readableErrored;return(d=(Y0=N._readableState)===null||Y0===void 0?void 0:Y0.errored)!==null&&d!==void 0?d:null}function k(N){if(!x(N))return null;if(typeof N.closed==="boolean")return N.closed;let{_writableState:d,_readableState:Y0}=N;if(typeof(d===null||d===void 0?void 0:d.closed)==="boolean"||typeof(Y0===null||Y0===void 0?void 0:Y0.closed)==="boolean")return(d===null||d===void 0?void 0:d.closed)||(Y0===null||Y0===void 0?void 0:Y0.closed);if(typeof N._closed==="boolean"&&s(N))return N._closed;return null}function s(N){return typeof N._closed==="boolean"&&typeof N._defaultKeepAlive==="boolean"&&typeof N._removedConnection==="boolean"&&typeof N._removedContLen==="boolean"}function J0(N){return typeof N._sent100==="boolean"&&s(N)}function B0(N){var d;return typeof N._consuming==="boolean"&&typeof N._dumped==="boolean"&&((d=N.req)===null||d===void 0?void 0:d.upgradeOrConnect)===void 0}function N0(N){if(!x(N))return null;let{_writableState:d,_readableState:Y0}=N,m=d||Y0;return!m&&J0(N)||!!(m&&m.autoDestroy&&m.emitClose&&m.closed===!1)}function p(N){var d;return!!(N&&((d=N[U])!==null&&d!==void 0?d:N.readableDidRead||N.readableAborted))}function K0(N){var d,Y0,m,U0,M0,P0,z0,u,c,t;return!!(N&&((d=(Y0=(m=(U0=(M0=(P0=N[G])!==null&&P0!==void 0?P0:N.readableErrored)!==null&&M0!==void 0?M0:N.writableErrored)!==null&&U0!==void 0?U0:(z0=N._readableState)===null||z0===void 0?void 0:z0.errorEmitted)!==null&&m!==void 0?m:(u=N._writableState)===null||u===void 0?void 0:u.errorEmitted)!==null&&Y0!==void 0?Y0:(c=N._readableState)===null||c===void 0?void 0:c.errored)!==null&&d!==void 0?d:(t=N._writableState)===null||t===void 0?void 0:t.errored))}Q.exports={isDestroyed:R,kIsDestroyed:Y,isDisturbed:p,kIsDisturbed:U,isErrored:K0,kIsErrored:G,isReadable:E,kIsReadable:B,kIsClosedPromise:V,kControllerErrorFunction:L,kIsWritable:W,isClosed:k,isDuplexNodeStream:y,isFinished:O,isIterable:z,isReadableNodeStream:w,isReadableStream:A,isReadableEnded:l,isReadableFinished:S,isReadableErrored:f,isNodeStream:x,isWebStream:F,isWritable:P,isWritableNodeStream:M,isWritableStream:D,isWritableEnded:_,isWritableFinished:T,isWritableErrored:Z,isServerRequest:B0,isServerResponse:J0,willEmitClose:N0,isTransformStream:K}}),n2=S0(($,Q)=>{var J=L1(),{AbortError:q,codes:X}=d0(),{ERR_INVALID_ARG_TYPE:Y,ERR_STREAM_PREMATURE_CLOSE:G}=X,{kEmptyObject:B,once:W}=r0(),{validateAbortSignal:U,validateFunction:V,validateObject:L,validateBoolean:w}=S6(),{Promise:M,PromisePrototypeThen:y,SymbolDispose:x}=Z0(),{isClosed:A,isReadable:D,isReadableNodeStream:K,isReadableStream:F,isReadableFinished:z,isReadableErrored:R,isWritable:_,isWritableNodeStream:T,isWritableStream:l,isWritableFinished:S,isWritableErrored:E,isNodeStream:P,willEmitClose:O,kIsClosedPromise:Z}=y2(),f;function k(p){return p.setHeader&&typeof p.abort==="function"}var s=()=>{};function J0(p,K0,N){var d,Y0;if(arguments.length===2)N=K0,K0=B;else if(K0==null)K0=B;else L(K0,"options");if(V(N,"callback"),U(K0.signal,"options.signal"),N=W(N),F(p)||l(p))return B0(p,K0,N);if(!P(p))throw new Y("stream",["ReadableStream","WritableStream","Stream"],p);let m=(d=K0.readable)!==null&&d!==void 0?d:K(p),U0=(Y0=K0.writable)!==null&&Y0!==void 0?Y0:T(p),M0=p._writableState,P0=p._readableState,z0=()=>{if(!p.writable)t()},u=O(p)&&K(p)===m&&T(p)===U0,c=S(p,!1),t=()=>{if(c=!0,p.destroyed)u=!1;if(u&&(!p.readable||m))return;if(!m||L0)N.call(p)},L0=z(p,!1),O0=()=>{if(L0=!0,p.destroyed)u=!1;if(u&&(!p.writable||U0))return;if(!U0||c)N.call(p)},C=(I)=>{N.call(p,I)},v=A(p),h=()=>{v=!0;let I=E(p)||R(p);if(I&&typeof I!=="boolean")return N.call(p,I);if(m&&!L0&&K(p,!0)){if(!z(p,!1))return N.call(p,new G)}if(U0&&!c){if(!S(p,!1))return N.call(p,new G)}N.call(p)},a=()=>{v=!0;let I=E(p)||R(p);if(I&&typeof I!=="boolean")return N.call(p,I);N.call(p)},Q0=()=>{p.req.on("finish",t)};if(k(p)){if(p.on("complete",t),!u)p.on("abort",h);if(p.req)Q0();else p.on("request",Q0)}else if(U0&&!M0)p.on("end",z0),p.on("close",z0);if(!u&&typeof p.aborted==="boolean")p.on("aborted",h);if(p.on("end",O0),p.on("finish",t),K0.error!==!1)p.on("error",C);if(p.on("close",h),v)J.nextTick(h);else if(M0!==null&&M0!==void 0&&M0.errorEmitted||P0!==null&&P0!==void 0&&P0.errorEmitted){if(!u)J.nextTick(a)}else if(!m&&(!u||D(p))&&(c||_(p)===!1))J.nextTick(a);else if(!U0&&(!u||_(p))&&(L0||D(p)===!1))J.nextTick(a);else if(P0&&p.req&&p.aborted)J.nextTick(a);let e=()=>{if(N=s,p.removeListener("aborted",h),p.removeListener("complete",t),p.removeListener("abort",h),p.removeListener("request",Q0),p.req)p.req.removeListener("finish",t);p.removeListener("end",z0),p.removeListener("close",z0),p.removeListener("finish",t),p.removeListener("end",O0),p.removeListener("error",C),p.removeListener("close",h)};if(K0.signal&&!v){let I=()=>{let i=N;e(),i.call(p,new q(void 0,{cause:K0.signal.reason}))};if(K0.signal.aborted)J.nextTick(I);else{f=f||r0().addAbortListener;let i=f(K0.signal,I),q0=N;N=W((...n)=>{i[x](),q0.apply(p,n)})}}return e}function B0(p,K0,N){let d=!1,Y0=s;if(K0.signal)if(Y0=()=>{d=!0,N.call(p,new q(void 0,{cause:K0.signal.reason}))},K0.signal.aborted)J.nextTick(Y0);else{f=f||r0().addAbortListener;let U0=f(K0.signal,Y0),M0=N;N=W((...P0)=>{U0[x](),M0.apply(p,P0)})}let m=(...U0)=>{if(!d)J.nextTick(()=>N.apply(p,U0))};return y(p[Z].promise,m,m),s}function N0(p,K0){var N;let d=!1;if(K0===null)K0=B;if((N=K0)!==null&&N!==void 0&&N.cleanup)w(K0.cleanup,"cleanup"),d=K0.cleanup;return new M((Y0,m)=>{let U0=J0(p,K0,(M0)=>{if(d)U0();if(M0)m(M0);else Y0()})})}Q.exports=J0,Q.exports.finished=N0}),b1=S0(($,Q)=>{var J=L1(),{aggregateTwoErrors:q,codes:{ERR_MULTIPLE_CALLBACK:X},AbortError:Y}=d0(),{Symbol:G}=Z0(),{kIsDestroyed:B,isDestroyed:W,isFinished:U,isServerRequest:V}=y2(),L=G("kDestroy"),w=G("kConstruct");function M(O,Z,f){if(O){if(O.stack,Z&&!Z.errored)Z.errored=O;if(f&&!f.errored)f.errored=O}}function y(O,Z){let f=this._readableState,k=this._writableState,s=k||f;if(k!==null&&k!==void 0&&k.destroyed||f!==null&&f!==void 0&&f.destroyed){if(typeof Z==="function")Z();return this}if(M(O,k,f),k)k.destroyed=!0;if(f)f.destroyed=!0;if(!s.constructed)this.once(L,function(J0){x(this,q(J0,O),Z)});else x(this,O,Z);return this}function x(O,Z,f){let k=!1;function s(J0){if(k)return;k=!0;let{_readableState:B0,_writableState:N0}=O;if(M(J0,N0,B0),N0)N0.closed=!0;if(B0)B0.closed=!0;if(typeof f==="function")f(J0);if(J0)J.nextTick(A,O,J0);else J.nextTick(D,O)}try{O._destroy(Z||null,s)}catch(J0){s(J0)}}function A(O,Z){K(O,Z),D(O)}function D(O){let{_readableState:Z,_writableState:f}=O;if(f)f.closeEmitted=!0;if(Z)Z.closeEmitted=!0;if(f!==null&&f!==void 0&&f.emitClose||Z!==null&&Z!==void 0&&Z.emitClose)O.emit("close")}function K(O,Z){let{_readableState:f,_writableState:k}=O;if(k!==null&&k!==void 0&&k.errorEmitted||f!==null&&f!==void 0&&f.errorEmitted)return;if(k)k.errorEmitted=!0;if(f)f.errorEmitted=!0;O.emit("error",Z)}function F(){let O=this._readableState,Z=this._writableState;if(O)O.constructed=!0,O.closed=!1,O.closeEmitted=!1,O.destroyed=!1,O.errored=null,O.errorEmitted=!1,O.reading=!1,O.ended=O.readable===!1,O.endEmitted=O.readable===!1;if(Z)Z.constructed=!0,Z.destroyed=!1,Z.closed=!1,Z.closeEmitted=!1,Z.errored=null,Z.errorEmitted=!1,Z.finalCalled=!1,Z.prefinished=!1,Z.ended=Z.writable===!1,Z.ending=Z.writable===!1,Z.finished=Z.writable===!1}function z(O,Z,f){let{_readableState:k,_writableState:s}=O;if(s!==null&&s!==void 0&&s.destroyed||k!==null&&k!==void 0&&k.destroyed)return this;if(k!==null&&k!==void 0&&k.autoDestroy||s!==null&&s!==void 0&&s.autoDestroy)O.destroy(Z);else if(Z){if(Z.stack,s&&!s.errored)s.errored=Z;if(k&&!k.errored)k.errored=Z;if(f)J.nextTick(K,O,Z);else K(O,Z)}}function R(O,Z){if(typeof O._construct!=="function")return;let{_readableState:f,_writableState:k}=O;if(f)f.constructed=!1;if(k)k.constructed=!1;if(O.once(w,Z),O.listenerCount(w)>1)return;J.nextTick(_,O)}function _(O){let Z=!1;function f(k){if(Z){z(O,k!==null&&k!==void 0?k:new X);return}Z=!0;let{_readableState:s,_writableState:J0}=O,B0=J0||s;if(s)s.constructed=!0;if(J0)J0.constructed=!0;if(B0.destroyed)O.emit(L,k);else if(k)z(O,k,!0);else J.nextTick(T,O)}try{O._construct((k)=>{J.nextTick(f,k)})}catch(k){J.nextTick(f,k)}}function T(O){O.emit(w)}function l(O){return(O===null||O===void 0?void 0:O.setHeader)&&typeof O.abort==="function"}function S(O){O.emit("close")}function E(O,Z){O.emit("error",Z),J.nextTick(S,O)}function P(O,Z){if(!O||W(O))return;if(!Z&&!U(O))Z=new Y;if(V(O))O.socket=null,O.destroy(Z);else if(l(O))O.abort();else if(l(O.req))O.req.abort();else if(typeof O.destroy==="function")O.destroy(Z);else if(typeof O.close==="function")O.close();else if(Z)J.nextTick(E,O,Z);else J.nextTick(S,O);if(!O.destroyed)O[B]=!0}Q.exports={construct:R,destroyer:P,destroy:y,undestroy:F,errorOrDestroy:z}}),N5=S0(($,Q)=>{var{ArrayIsArray:J,ObjectSetPrototypeOf:q}=Z0(),{EventEmitter:X}=(C6(),q2(R6));function Y(B){X.call(this,B)}q(Y.prototype,X.prototype),q(Y,X),Y.prototype.pipe=function(B,W){let U=this;function V(D){if(B.writable&&B.write(D)===!1&&U.pause)U.pause()}U.on("data",V);function L(){if(U.readable&&U.resume)U.resume()}if(B.on("drain",L),!B._isStdio&&(!W||W.end!==!1))U.on("end",M),U.on("close",y);let w=!1;function M(){if(w)return;w=!0,B.end()}function y(){if(w)return;if(w=!0,typeof B.destroy==="function")B.destroy()}function x(D){if(A(),X.listenerCount(this,"error")===0)this.emit("error",D)}G(U,"error",x),G(B,"error",x);function A(){U.removeListener("data",V),B.removeListener("drain",L),U.removeListener("end",M),U.removeListener("close",y),U.removeListener("error",x),B.removeListener("error",x),U.removeListener("end",A),U.removeListener("close",A),B.removeListener("close",A)}return U.on("end",A),U.on("close",A),B.on("close",A),B.emit("pipe",U),B};function G(B,W,U){if(typeof B.prependListener==="function")return B.prependListener(W,U);if(!B._events||!B._events[W])B.on(W,U);else if(J(B._events[W]))B._events[W].unshift(U);else B._events[W]=[U,B._events[W]]}Q.exports={Stream:Y,prependListener:G}}),W8=S0(($,Q)=>{var{SymbolDispose:J}=Z0(),{AbortError:q,codes:X}=d0(),{isNodeStream:Y,isWebStream:G,kControllerErrorFunction:B}=y2(),W=n2(),{ERR_INVALID_ARG_TYPE:U}=X,V,L=(w,M)=>{if(typeof w!=="object"||!("aborted"in w))throw new U(M,"AbortSignal",w)};Q.exports.addAbortSignal=function(w,M){if(L(w,"signal"),!Y(M)&&!G(M))throw new U("stream",["ReadableStream","WritableStream","Stream"],M);return Q.exports.addAbortSignalNoValidate(w,M)},Q.exports.addAbortSignalNoValidate=function(w,M){if(typeof w!=="object"||!("aborted"in w))return M;let y=Y(M)?()=>{M.destroy(new q(void 0,{cause:w.reason}))}:()=>{M[B](new q(void 0,{cause:w.reason}))};if(w.aborted)y();else{V=V||r0().addAbortListener;let x=V(w,y);W(M,x[J])}return M}}),qX=S0(($,Q)=>{var{StringPrototypeSlice:J,SymbolIterator:q,TypedArrayPrototypeSet:X,Uint8Array:Y}=Z0(),{Buffer:G}=(x2(),q2(g2)),{inspect:B}=r0();Q.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(W){let U={data:W,next:null};if(this.length>0)this.tail.next=U;else this.head=U;this.tail=U,++this.length}unshift(W){let U={data:W,next:this.head};if(this.length===0)this.tail=U;this.head=U,++this.length}shift(){if(this.length===0)return;let W=this.head.data;if(this.length===1)this.head=this.tail=null;else this.head=this.head.next;return--this.length,W}clear(){this.head=this.tail=null,this.length=0}join(W){if(this.length===0)return"";let U=this.head,V=""+U.data;while((U=U.next)!==null)V+=W+U.data;return V}concat(W){if(this.length===0)return G.alloc(0);let U=G.allocUnsafe(W>>>0),V=this.head,L=0;while(V)X(U,V.data,L),L+=V.data.length,V=V.next;return U}consume(W,U){let V=this.head.data;if(W<V.length){let L=V.slice(0,W);return this.head.data=V.slice(W),L}if(W===V.length)return this.shift();return U?this._getString(W):this._getBuffer(W)}first(){return this.head.data}*[q](){for(let W=this.head;W;W=W.next)yield W.data}_getString(W){let U="",V=this.head,L=0;do{let w=V.data;if(W>w.length)U+=w,W-=w.length;else{if(W===w.length)if(U+=w,++L,V.next)this.head=V.next;else this.head=this.tail=null;else U+=J(w,0,W),this.head=V,V.data=J(w,W);break}++L}while((V=V.next)!==null);return this.length-=L,U}_getBuffer(W){let U=G.allocUnsafe(W),V=W,L=this.head,w=0;do{let M=L.data;if(W>M.length)X(U,M,V-W),W-=M.length;else{if(W===M.length)if(X(U,M,V-W),++w,L.next)this.head=L.next;else this.head=this.tail=null;else X(U,new Y(M.buffer,M.byteOffset,W),V-W),this.head=L,L.data=M.slice(W);break}++w}while((L=L.next)!==null);return this.length-=w,U}[Symbol.for("nodejs.util.inspect.custom")](W,U){return B(this,{...U,depth:0,customInspect:!1})}}}),V8=S0(($,Q)=>{var{MathFloor:J,NumberIsInteger:q}=Z0(),{validateInteger:X}=S6(),{ERR_INVALID_ARG_VALUE:Y}=d0().codes,G=16384,B=16;function W(w,M,y){return w.highWaterMark!=null?w.highWaterMark:M?w[y]:null}function U(w){return w?B:G}function V(w,M){if(X(M,"value",0),w)B=M;else G=M}function L(w,M,y,x){let A=W(M,x,y);if(A!=null){if(!q(A)||A<0){let D=x?`options.${y}`:"options.highWaterMark";throw new Y(D,A)}return J(A)}return U(w.objectMode)}Q.exports={getHighWaterMark:L,getDefaultHighWaterMark:U,setDefaultHighWaterMark:V}}),XX=S0(($,Q)=>{/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */var J=(x2(),q2(g2)),q=J.Buffer;function X(G,B){for(var W in G)B[W]=G[W]}if(q.from&&q.alloc&&q.allocUnsafe&&q.allocUnsafeSlow)Q.exports=J;else X(J,$),$.Buffer=Y;function Y(G,B,W){return q(G,B,W)}Y.prototype=Object.create(q.prototype),X(q,Y),Y.from=function(G,B,W){if(typeof G==="number")throw TypeError("Argument must not be a number");return q(G,B,W)},Y.alloc=function(G,B,W){if(typeof G!=="number")throw TypeError("Argument must be a number");var U=q(G);if(B!==void 0)if(typeof W==="string")U.fill(B,W);else U.fill(B);else U.fill(0);return U},Y.allocUnsafe=function(G){if(typeof G!=="number")throw TypeError("Argument must be a number");return q(G)},Y.allocUnsafeSlow=function(G){if(typeof G!=="number")throw TypeError("Argument must be a number");return J.SlowBuffer(G)}}),YX=S0(($)=>{var Q=XX().Buffer,J=Q.isEncoding||function(K){switch(K=""+K,K&&K.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function q(K){if(!K)return"utf8";var F;while(!0)switch(K){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return K;default:if(F)return;K=(""+K).toLowerCase(),F=!0}}function X(K){var F=q(K);if(typeof F!=="string"&&(Q.isEncoding===J||!J(K)))throw Error("Unknown encoding: "+K);return F||K}$.StringDecoder=Y;function Y(K){this.encoding=X(K);var F;switch(this.encoding){case"utf16le":this.text=w,this.end=M,F=4;break;case"utf8":this.fillLast=U,F=4;break;case"base64":this.text=y,this.end=x,F=3;break;default:this.write=A,this.end=D;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=Q.allocUnsafe(F)}Y.prototype.write=function(K){if(K.length===0)return"";var F,z;if(this.lastNeed){if(F=this.fillLast(K),F===void 0)return"";z=this.lastNeed,this.lastNeed=0}else z=0;if(z<K.length)return F?F+this.text(K,z):this.text(K,z);return F||""},Y.prototype.end=L,Y.prototype.text=V,Y.prototype.fillLast=function(K){if(this.lastNeed<=K.length)return K.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);K.copy(this.lastChar,this.lastTotal-this.lastNeed,0,K.length),this.lastNeed-=K.length};function G(K){if(K<=127)return 0;else if(K>>5===6)return 2;else if(K>>4===14)return 3;else if(K>>3===30)return 4;return K>>6===2?-1:-2}function B(K,F,z){var R=F.length-1;if(R<z)return 0;var _=G(F[R]);if(_>=0){if(_>0)K.lastNeed=_-1;return _}if(--R<z||_===-2)return 0;if(_=G(F[R]),_>=0){if(_>0)K.lastNeed=_-2;return _}if(--R<z||_===-2)return 0;if(_=G(F[R]),_>=0){if(_>0)if(_===2)_=0;else K.lastNeed=_-3;return _}return 0}function W(K,F,z){if((F[0]&192)!==128)return K.lastNeed=0,"�";if(K.lastNeed>1&&F.length>1){if((F[1]&192)!==128)return K.lastNeed=1,"�";if(K.lastNeed>2&&F.length>2){if((F[2]&192)!==128)return K.lastNeed=2,"�"}}}function U(K){var F=this.lastTotal-this.lastNeed,z=W(this,K,F);if(z!==void 0)return z;if(this.lastNeed<=K.length)return K.copy(this.lastChar,F,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);K.copy(this.lastChar,F,0,K.length),this.lastNeed-=K.length}function V(K,F){var z=B(this,K,F);if(!this.lastNeed)return K.toString("utf8",F);this.lastTotal=z;var R=K.length-(z-this.lastNeed);return K.copy(this.lastChar,0,R),K.toString("utf8",F,R)}function L(K){var F=K&&K.length?this.write(K):"";if(this.lastNeed)return F+"�";return F}function w(K,F){if((K.length-F)%2===0){var z=K.toString("utf16le",F);if(z){var R=z.charCodeAt(z.length-1);if(R>=55296&&R<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=K[K.length-2],this.lastChar[1]=K[K.length-1],z.slice(0,-1)}return z}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=K[K.length-1],K.toString("utf16le",F,K.length-1)}function M(K){var F=K&&K.length?this.write(K):"";if(this.lastNeed){var z=this.lastTotal-this.lastNeed;return F+this.lastChar.toString("utf16le",0,z)}return F}function y(K,F){var z=(K.length-F)%3;if(z===0)return K.toString("base64",F);if(this.lastNeed=3-z,this.lastTotal=3,z===1)this.lastChar[0]=K[K.length-1];else this.lastChar[0]=K[K.length-2],this.lastChar[1]=K[K.length-1];return K.toString("base64",F,K.length-z)}function x(K){var F=K&&K.length?this.write(K):"";if(this.lastNeed)return F+this.lastChar.toString("base64",0,3-this.lastNeed);return F}function A(K){return K.toString(this.encoding)}function D(K){return K&&K.length?this.write(K):""}}),r7=S0(($,Q)=>{var J=L1(),{PromisePrototypeThen:q,SymbolAsyncIterator:X,SymbolIterator:Y}=Z0(),{Buffer:G}=(x2(),q2(g2)),{ERR_INVALID_ARG_TYPE:B,ERR_STREAM_NULL_VALUES:W}=d0().codes;function U(V,L,w){let M;if(typeof L==="string"||L instanceof G)return new V({objectMode:!0,...w,read(){this.push(L),this.push(null)}});let y;if(L&&L[X])y=!0,M=L[X]();else if(L&&L[Y])y=!1,M=L[Y]();else throw new B("iterable",["Iterable"],L);let x=new V({objectMode:!0,highWaterMark:1,...w}),A=!1;x._read=function(){if(!A)A=!0,K()},x._destroy=function(F,z){q(D(F),()=>J.nextTick(z,F),(R)=>J.nextTick(z,R||F))};async function D(F){let z=F!==void 0&&F!==null,R=typeof M.throw==="function";if(z&&R){let{value:_,done:T}=await M.throw(F);if(await _,T)return}if(typeof M.return==="function"){let{value:_}=await M.return();await _}}async function K(){for(;;){try{let{value:F,done:z}=y?await M.next():M.next();if(z)x.push(null);else{let R=F&&typeof F.then==="function"?await F:F;if(R===null)throw A=!1,new W;else if(x.push(R))continue;else A=!1}}catch(F){x.destroy(F)}break}}return x}Q.exports=U}),K8=S0(($,Q)=>{var J=L1(),{ArrayPrototypeIndexOf:q,NumberIsInteger:X,NumberIsNaN:Y,NumberParseInt:G,ObjectDefineProperties:B,ObjectKeys:W,ObjectSetPrototypeOf:U,Promise:V,SafeSet:L,SymbolAsyncDispose:w,SymbolAsyncIterator:M,Symbol:y}=Z0();Q.exports=n,n.ReadableState=q0;var{EventEmitter:x}=(C6(),q2(R6)),{Stream:A,prependListener:D}=N5(),{Buffer:K}=(x2(),q2(g2)),{addAbortSignal:F}=W8(),z=n2(),R=r0().debuglog("stream",(H)=>{R=H}),_=qX(),T=b1(),{getHighWaterMark:l,getDefaultHighWaterMark:S}=V8(),{aggregateTwoErrors:E,codes:{ERR_INVALID_ARG_TYPE:P,ERR_METHOD_NOT_IMPLEMENTED:O,ERR_OUT_OF_RANGE:Z,ERR_STREAM_PUSH_AFTER_EOF:f,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:k},AbortError:s}=d0(),{validateObject:J0}=S6(),B0=y("kPaused"),{StringDecoder:N0}=YX(),p=r7();U(n.prototype,A.prototype),U(n,A);var K0=()=>{},{errorOrDestroy:N}=T,d=1,Y0=2,m=4,U0=8,M0=16,P0=32,z0=64,u=128,c=256,t=512,L0=1024,O0=2048,C=4096,v=8192,h=16384,a=32768,Q0=65536,e=131072,I=262144;function i(H){return{enumerable:!1,get(){return(this.state&H)!==0},set(j){if(j)this.state|=H;else this.state&=~H}}}B(q0.prototype,{objectMode:i(d),ended:i(Y0),endEmitted:i(m),reading:i(U0),constructed:i(M0),sync:i(P0),needReadable:i(z0),emittedReadable:i(u),readableListening:i(c),resumeScheduled:i(t),errorEmitted:i(L0),emitClose:i(O0),autoDestroy:i(C),destroyed:i(v),closed:i(h),closeEmitted:i(a),multiAwaitDrain:i(Q0),readingMore:i(e),dataEmitted:i(I)});function q0(H,j,r){if(typeof r!=="boolean")r=j instanceof f2();if(this.state=O0|C|M0|P0,H&&H.objectMode)this.state|=d;if(r&&H&&H.readableObjectMode)this.state|=d;if(this.highWaterMark=H?l(this,H,"readableHighWaterMark",r):S(!1),this.buffer=new _,this.length=0,this.pipes=[],this.flowing=null,this[B0]=null,H&&H.emitClose===!1)this.state&=~O0;if(H&&H.autoDestroy===!1)this.state&=~C;if(this.errored=null,this.defaultEncoding=H&&H.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,H&&H.encoding)this.decoder=new N0(H.encoding),this.encoding=H.encoding}function n(H){if(!(this instanceof n))return new n(H);let j=this instanceof f2();if(this._readableState=new q0(H,this,j),H){if(typeof H.read==="function")this._read=H.read;if(typeof H.destroy==="function")this._destroy=H.destroy;if(typeof H.construct==="function")this._construct=H.construct;if(H.signal&&!j)F(H.signal,this)}A.call(this,H),T.construct(this,()=>{if(this._readableState.needReadable)f1(this,this._readableState)})}n.prototype.destroy=T.destroy,n.prototype._undestroy=T.undestroy,n.prototype._destroy=function(H,j){j(H)},n.prototype[x.captureRejectionSymbol]=function(H){this.destroy(H)},n.prototype[w]=function(){let H;if(!this.destroyed)H=this.readableEnded?null:new s,this.destroy(H);return new V((j,r)=>z(this,(G0)=>G0&&G0!==H?r(G0):j(null)))},n.prototype.push=function(H,j){return H0(this,H,j,!1)},n.prototype.unshift=function(H,j){return H0(this,H,j,!0)};function H0(H,j,r,G0){R("readableAddChunk",j);let W0=H._readableState,c0;if((W0.state&d)===0){if(typeof j==="string"){if(r=r||W0.defaultEncoding,W0.encoding!==r)if(G0&&W0.encoding)j=K.from(j,r).toString(W0.encoding);else j=K.from(j,r),r=""}else if(j instanceof K)r="";else if(A._isUint8Array(j))j=A._uint8ArrayToBuffer(j),r="";else if(j!=null)c0=new P("chunk",["string","Buffer","Uint8Array"],j)}if(c0)N(H,c0);else if(j===null)W0.state&=~U0,u0(H,W0);else if((W0.state&d)!==0||j&&j.length>0)if(G0)if((W0.state&m)!==0)N(H,new k);else if(W0.destroyed||W0.errored)return!1;else E0(H,W0,j,!0);else if(W0.ended)N(H,new f);else if(W0.destroyed||W0.errored)return!1;else if(W0.state&=~U0,W0.decoder&&!r)if(j=W0.decoder.write(j),W0.objectMode||j.length!==0)E0(H,W0,j,!1);else f1(H,W0);else E0(H,W0,j,!1);else if(!G0)W0.state&=~U0,f1(H,W0);return!W0.ended&&(W0.length<W0.highWaterMark||W0.length===0)}function E0(H,j,r,G0){if(j.flowing&&j.length===0&&!j.sync&&H.listenerCount("data")>0){if((j.state&Q0)!==0)j.awaitDrainWriters.clear();else j.awaitDrainWriters=null;j.dataEmitted=!0,H.emit("data",r)}else{if(j.length+=j.objectMode?1:r.length,G0)j.buffer.unshift(r);else j.buffer.push(r);if((j.state&z0)!==0)n0(H)}f1(H,j)}n.prototype.isPaused=function(){let H=this._readableState;return H[B0]===!0||H.flowing===!1},n.prototype.setEncoding=function(H){let j=new N0(H);this._readableState.decoder=j,this._readableState.encoding=this._readableState.decoder.encoding;let r=this._readableState.buffer,G0="";for(let W0 of r)G0+=j.write(W0);if(r.clear(),G0!=="")r.push(G0);return this._readableState.length=G0.length,this};var $2=1073741824;function Q2(H){if(H>$2)throw new Z("size","<= 1GiB",H);else H--,H|=H>>>1,H|=H>>>2,H|=H>>>4,H|=H>>>8,H|=H>>>16,H++;return H}function V1(H,j){if(H<=0||j.length===0&&j.ended)return 0;if((j.state&d)!==0)return 1;if(Y(H)){if(j.flowing&&j.length)return j.buffer.first().length;return j.length}if(H<=j.length)return H;return j.ended?j.length:0}n.prototype.read=function(H){if(R("read",H),H===void 0)H=NaN;else if(!X(H))H=G(H,10);let j=this._readableState,r=H;if(H>j.highWaterMark)j.highWaterMark=Q2(H);if(H!==0)j.state&=~u;if(H===0&&j.needReadable&&((j.highWaterMark!==0?j.length>=j.highWaterMark:j.length>0)||j.ended)){if(R("read: emitReadable",j.length,j.ended),j.length===0&&j.ended)J5(this);else n0(this);return null}if(H=V1(H,j),H===0&&j.ended){if(j.length===0)J5(this);return null}let G0=(j.state&z0)!==0;if(R("need readable",G0),j.length===0||j.length-H<j.highWaterMark)G0=!0,R("length less than watermark",G0);if(j.ended||j.reading||j.destroyed||j.errored||!j.constructed)G0=!1,R("reading, ended or constructing",G0);else if(G0){if(R("do read"),j.state|=U0|P0,j.length===0)j.state|=z0;try{this._read(j.highWaterMark)}catch(c0){N(this,c0)}if(j.state&=~P0,!j.reading)H=V1(r,j)}let W0;if(H>0)W0=Q7(H,j);else W0=null;if(W0===null)j.needReadable=j.length<=j.highWaterMark,H=0;else if(j.length-=H,j.multiAwaitDrain)j.awaitDrainWriters.clear();else j.awaitDrainWriters=null;if(j.length===0){if(!j.ended)j.needReadable=!0;if(r!==H&&j.ended)J5(this)}if(W0!==null&&!j.errorEmitted&&!j.closeEmitted)j.dataEmitted=!0,this.emit("data",W0);return W0};function u0(H,j){if(R("onEofChunk"),j.ended)return;if(j.decoder){let r=j.decoder.end();if(r&&r.length)j.buffer.push(r),j.length+=j.objectMode?1:r.length}if(j.ended=!0,j.sync)n0(H);else j.needReadable=!1,j.emittedReadable=!0,x1(H)}function n0(H){let j=H._readableState;if(R("emitReadable",j.needReadable,j.emittedReadable),j.needReadable=!1,!j.emittedReadable)R("emitReadable",j.flowing),j.emittedReadable=!0,J.nextTick(x1,H)}function x1(H){let j=H._readableState;if(R("emitReadable_",j.destroyed,j.length,j.ended),!j.destroyed&&!j.errored&&(j.length||j.ended))H.emit("readable"),j.emittedReadable=!1;j.needReadable=!j.flowing&&!j.ended&&j.length<=j.highWaterMark,e4(H)}function f1(H,j){if(!j.readingMore&&j.constructed)j.readingMore=!0,J.nextTick(L2,H,j)}function L2(H,j){while(!j.reading&&!j.ended&&(j.length<j.highWaterMark||j.flowing&&j.length===0)){let r=j.length;if(R("maybeReadMore read 0"),H.read(0),r===j.length)break}j.readingMore=!1}n.prototype._read=function(H){throw new O("_read()")},n.prototype.pipe=function(H,j){let r=this,G0=this._readableState;if(G0.pipes.length===1){if(!G0.multiAwaitDrain)G0.multiAwaitDrain=!0,G0.awaitDrainWriters=new L(G0.awaitDrainWriters?[G0.awaitDrainWriters]:[])}G0.pipes.push(H),R("pipe count=%d opts=%j",G0.pipes.length,j);let W0=(!j||j.end!==!1)&&H!==J.stdout&&H!==J.stderr?J2:O6;if(G0.endEmitted)J.nextTick(W0);else r.once("end",W0);H.on("unpipe",c0);function c0(H1,T2){if(R("onunpipe"),H1===r){if(T2&&T2.hasUnpiped===!1)T2.hasUnpiped=!0,eJ()}}function J2(){R("onend"),H.end()}let K1,q7=!1;function eJ(){if(R("cleanup"),H.removeListener("close",Y5),H.removeListener("finish",G5),K1)H.removeListener("drain",K1);if(H.removeListener("error",X5),H.removeListener("unpipe",c0),r.removeListener("end",J2),r.removeListener("end",O6),r.removeListener("data",Y7),q7=!0,K1&&G0.awaitDrainWriters&&(!H._writableState||H._writableState.needDrain))K1()}function X7(){if(!q7){if(G0.pipes.length===1&&G0.pipes[0]===H)R("false write response, pause",0),G0.awaitDrainWriters=H,G0.multiAwaitDrain=!1;else if(G0.pipes.length>1&&G0.pipes.includes(H))R("false write response, pause",G0.awaitDrainWriters.size),G0.awaitDrainWriters.add(H);r.pause()}if(!K1)K1=iJ(r,H),H.on("drain",K1)}r.on("data",Y7);function Y7(H1){R("ondata");let T2=H.write(H1);if(R("dest.write",T2),T2===!1)X7()}function X5(H1){if(R("onerror",H1),O6(),H.removeListener("error",X5),H.listenerCount("error")===0){let T2=H._writableState||H._readableState;if(T2&&!T2.errorEmitted)N(H,H1);else H.emit("error",H1)}}D(H,"error",X5);function Y5(){H.removeListener("finish",G5),O6()}H.once("close",Y5);function G5(){R("onfinish"),H.removeListener("close",Y5),O6()}H.once("finish",G5);function O6(){R("unpipe"),r.unpipe(H)}if(H.emit("pipe",r),H.writableNeedDrain===!0)X7();else if(!G0.flowing)R("pipe resume"),r.resume();return H};function iJ(H,j){return function(){let r=H._readableState;if(r.awaitDrainWriters===j)R("pipeOnDrain",1),r.awaitDrainWriters=null;else if(r.multiAwaitDrain)R("pipeOnDrain",r.awaitDrainWriters.size),r.awaitDrainWriters.delete(j);if((!r.awaitDrainWriters||r.awaitDrainWriters.size===0)&&H.listenerCount("data"))H.resume()}}n.prototype.unpipe=function(H){let j=this._readableState,r={hasUnpiped:!1};if(j.pipes.length===0)return this;if(!H){let W0=j.pipes;j.pipes=[],this.pause();for(let c0=0;c0<W0.length;c0++)W0[c0].emit("unpipe",this,{hasUnpiped:!1});return this}let G0=q(j.pipes,H);if(G0===-1)return this;if(j.pipes.splice(G0,1),j.pipes.length===0)this.pause();return H.emit("unpipe",this,r),this},n.prototype.on=function(H,j){let r=A.prototype.on.call(this,H,j),G0=this._readableState;if(H==="data"){if(G0.readableListening=this.listenerCount("readable")>0,G0.flowing!==!1)this.resume()}else if(H==="readable"){if(!G0.endEmitted&&!G0.readableListening){if(G0.readableListening=G0.needReadable=!0,G0.flowing=!1,G0.emittedReadable=!1,R("on readable",G0.length,G0.reading),G0.length)n0(this);else if(!G0.reading)J.nextTick(nJ,this)}}return r},n.prototype.addListener=n.prototype.on,n.prototype.removeListener=function(H,j){let r=A.prototype.removeListener.call(this,H,j);if(H==="readable")J.nextTick(t4,this);return r},n.prototype.off=n.prototype.removeListener,n.prototype.removeAllListeners=function(H){let j=A.prototype.removeAllListeners.apply(this,arguments);if(H==="readable"||H===void 0)J.nextTick(t4,this);return j};function t4(H){let j=H._readableState;if(j.readableListening=H.listenerCount("readable")>0,j.resumeScheduled&&j[B0]===!1)j.flowing=!0;else if(H.listenerCount("data")>0)H.resume();else if(!j.readableListening)j.flowing=null}function nJ(H){R("readable nexttick read 0"),H.read(0)}n.prototype.resume=function(){let H=this._readableState;if(!H.flowing)R("resume"),H.flowing=!H.readableListening,oJ(this,H);return H[B0]=!1,this};function oJ(H,j){if(!j.resumeScheduled)j.resumeScheduled=!0,J.nextTick(rJ,H,j)}function rJ(H,j){if(R("resume",j.reading),!j.reading)H.read(0);if(j.resumeScheduled=!1,H.emit("resume"),e4(H),j.flowing&&!j.reading)H.read(0)}n.prototype.pause=function(){if(R("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1)R("pause"),this._readableState.flowing=!1,this.emit("pause");return this._readableState[B0]=!0,this};function e4(H){let j=H._readableState;R("flow",j.flowing);while(j.flowing&&H.read()!==null);}n.prototype.wrap=function(H){let j=!1;H.on("data",(G0)=>{if(!this.push(G0)&&H.pause)j=!0,H.pause()}),H.on("end",()=>{this.push(null)}),H.on("error",(G0)=>{N(this,G0)}),H.on("close",()=>{this.destroy()}),H.on("destroy",()=>{this.destroy()}),this._read=()=>{if(j&&H.resume)j=!1,H.resume()};let r=W(H);for(let G0=1;G0<r.length;G0++){let W0=r[G0];if(this[W0]===void 0&&typeof H[W0]==="function")this[W0]=H[W0].bind(H)}return this},n.prototype[M]=function(){return $7(this)},n.prototype.iterator=function(H){if(H!==void 0)J0(H,"options");return $7(this,H)};function $7(H,j){if(typeof H.read!=="function")H=n.wrap(H,{objectMode:!0});let r=aJ(H,j);return r.stream=H,r}async function*aJ(H,j){let r=K0;function G0(J2){if(this===H)r(),r=K0;else r=J2}H.on("readable",G0);let W0,c0=z(H,{writable:!1},(J2)=>{W0=J2?E(W0,J2):null,r(),r=K0});try{while(!0){let J2=H.destroyed?null:H.read();if(J2!==null)yield J2;else if(W0)throw W0;else if(W0===null)return;else await new V(G0)}}catch(J2){throw W0=E(W0,J2),W0}finally{if((W0||(j===null||j===void 0?void 0:j.destroyOnReturn)!==!1)&&(W0===void 0||H._readableState.autoDestroy))T.destroyer(H,null);else H.off("readable",G0),c0()}}B(n.prototype,{readable:{__proto__:null,get(){let H=this._readableState;return!!H&&H.readable!==!1&&!H.destroyed&&!H.errorEmitted&&!H.endEmitted},set(H){if(this._readableState)this._readableState.readable=!!H}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(this._readableState.destroyed||this._readableState.errored)&&!this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(H){if(this._readableState)this._readableState.flowing=H}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return this._readableState?this._readableState.closed:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(H){if(!this._readableState)return;this._readableState.destroyed=H}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}}),B(q0.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[B0]!==!1},set(H){this[B0]=!!H}}}),n._fromList=Q7;function Q7(H,j){if(j.length===0)return null;let r;if(j.objectMode)r=j.buffer.shift();else if(!H||H>=j.length){if(j.decoder)r=j.buffer.join("");else if(j.buffer.length===1)r=j.buffer.first();else r=j.buffer.concat(j.length);j.buffer.clear()}else r=j.buffer.consume(H,j.decoder);return r}function J5(H){let j=H._readableState;if(R("endReadable",j.endEmitted),!j.endEmitted)j.ended=!0,J.nextTick(sJ,j,H)}function sJ(H,j){if(R("endReadableNT",H.endEmitted,H.length),!H.errored&&!H.closeEmitted&&!H.endEmitted&&H.length===0){if(H.endEmitted=!0,j.emit("end"),j.writable&&j.allowHalfOpen===!1)J.nextTick(tJ,j);else if(H.autoDestroy){let r=j._writableState;if(!r||r.autoDestroy&&(r.finished||r.writable===!1))j.destroy()}}}function tJ(H){if(H.writable&&!H.writableEnded&&!H.destroyed)H.end()}n.from=function(H,j){return p(n,H,j)};var q5;function J7(){if(q5===void 0)q5={};return q5}n.fromWeb=function(H,j){return J7().newStreamReadableFromReadableStream(H,j)},n.toWeb=function(H,j){return J7().newReadableStreamFromStreamReadable(H,j)},n.wrap=function(H,j){var r,G0;return new n({objectMode:(r=(G0=H.readableObjectMode)!==null&&G0!==void 0?G0:H.objectMode)!==null&&r!==void 0?r:!0,...j,destroy(W0,c0){T.destroyer(H,W0),c0(W0)}}).wrap(H)}}),A5=S0(($,Q)=>{var J=L1(),{ArrayPrototypeSlice:q,Error:X,FunctionPrototypeSymbolHasInstance:Y,ObjectDefineProperty:G,ObjectDefineProperties:B,ObjectSetPrototypeOf:W,StringPrototypeToLowerCase:U,Symbol:V,SymbolHasInstance:L}=Z0();Q.exports=J0,J0.WritableState=k;var{EventEmitter:w}=(C6(),q2(R6)),M=N5().Stream,{Buffer:y}=(x2(),q2(g2)),x=b1(),{addAbortSignal:A}=W8(),{getHighWaterMark:D,getDefaultHighWaterMark:K}=V8(),{ERR_INVALID_ARG_TYPE:F,ERR_METHOD_NOT_IMPLEMENTED:z,ERR_MULTIPLE_CALLBACK:R,ERR_STREAM_CANNOT_PIPE:_,ERR_STREAM_DESTROYED:T,ERR_STREAM_ALREADY_FINISHED:l,ERR_STREAM_NULL_VALUES:S,ERR_STREAM_WRITE_AFTER_END:E,ERR_UNKNOWN_ENCODING:P}=d0().codes,{errorOrDestroy:O}=x;W(J0.prototype,M.prototype),W(J0,M);function Z(){}var f=V("kOnFinished");function k(C,v,h){if(typeof h!=="boolean")h=v instanceof f2();if(this.objectMode=!!(C&&C.objectMode),h)this.objectMode=this.objectMode||!!(C&&C.writableObjectMode);this.highWaterMark=C?D(this,C,"writableHighWaterMark",h):K(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;let a=!!(C&&C.decodeStrings===!1);this.decodeStrings=!a,this.defaultEncoding=C&&C.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=N.bind(void 0,v),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,s(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!C||C.emitClose!==!1,this.autoDestroy=!C||C.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[f]=[]}function s(C){C.buffered=[],C.bufferedIndex=0,C.allBuffers=!0,C.allNoop=!0}k.prototype.getBuffer=function(){return q(this.buffered,this.bufferedIndex)},G(k.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function J0(C){let v=this instanceof f2();if(!v&&!Y(J0,this))return new J0(C);if(this._writableState=new k(C,this,v),C){if(typeof C.write==="function")this._write=C.write;if(typeof C.writev==="function")this._writev=C.writev;if(typeof C.destroy==="function")this._destroy=C.destroy;if(typeof C.final==="function")this._final=C.final;if(typeof C.construct==="function")this._construct=C.construct;if(C.signal)A(C.signal,this)}M.call(this,C),x.construct(this,()=>{let h=this._writableState;if(!h.writing)U0(this,h);u(this,h)})}G(J0,L,{__proto__:null,value:function(C){if(Y(this,C))return!0;if(this!==J0)return!1;return C&&C._writableState instanceof k}}),J0.prototype.pipe=function(){O(this,new _)};function B0(C,v,h,a){let Q0=C._writableState;if(typeof h==="function")a=h,h=Q0.defaultEncoding;else{if(!h)h=Q0.defaultEncoding;else if(h!=="buffer"&&!y.isEncoding(h))throw new P(h);if(typeof a!=="function")a=Z}if(v===null)throw new S;else if(!Q0.objectMode)if(typeof v==="string"){if(Q0.decodeStrings!==!1)v=y.from(v,h),h="buffer"}else if(v instanceof y)h="buffer";else if(M._isUint8Array(v))v=M._uint8ArrayToBuffer(v),h="buffer";else throw new F("chunk",["string","Buffer","Uint8Array"],v);let e;if(Q0.ending)e=new E;else if(Q0.destroyed)e=new T("write");if(e)return J.nextTick(a,e),O(C,e,!0),e;return Q0.pendingcb++,N0(C,Q0,v,h,a)}J0.prototype.write=function(C,v,h){return B0(this,C,v,h)===!0},J0.prototype.cork=function(){this._writableState.corked++},J0.prototype.uncork=function(){let C=this._writableState;if(C.corked){if(C.corked--,!C.writing)U0(this,C)}},J0.prototype.setDefaultEncoding=function(C){if(typeof C==="string")C=U(C);if(!y.isEncoding(C))throw new P(C);return this._writableState.defaultEncoding=C,this};function N0(C,v,h,a,Q0){let e=v.objectMode?1:h.length;v.length+=e;let I=v.length<v.highWaterMark;if(!I)v.needDrain=!0;if(v.writing||v.corked||v.errored||!v.constructed){if(v.buffered.push({chunk:h,encoding:a,callback:Q0}),v.allBuffers&&a!=="buffer")v.allBuffers=!1;if(v.allNoop&&Q0!==Z)v.allNoop=!1}else v.writelen=e,v.writecb=Q0,v.writing=!0,v.sync=!0,C._write(h,a,v.onwrite),v.sync=!1;return I&&!v.errored&&!v.destroyed}function p(C,v,h,a,Q0,e,I){if(v.writelen=a,v.writecb=I,v.writing=!0,v.sync=!0,v.destroyed)v.onwrite(new T("write"));else if(h)C._writev(Q0,v.onwrite);else C._write(Q0,e,v.onwrite);v.sync=!1}function K0(C,v,h,a){--v.pendingcb,a(h),m(v),O(C,h)}function N(C,v){let h=C._writableState,a=h.sync,Q0=h.writecb;if(typeof Q0!=="function"){O(C,new R);return}if(h.writing=!1,h.writecb=null,h.length-=h.writelen,h.writelen=0,v){if(v.stack,!h.errored)h.errored=v;if(C._readableState&&!C._readableState.errored)C._readableState.errored=v;if(a)J.nextTick(K0,C,h,v,Q0);else K0(C,h,v,Q0)}else{if(h.buffered.length>h.bufferedIndex)U0(C,h);if(a)if(h.afterWriteTickInfo!==null&&h.afterWriteTickInfo.cb===Q0)h.afterWriteTickInfo.count++;else h.afterWriteTickInfo={count:1,cb:Q0,stream:C,state:h},J.nextTick(d,h.afterWriteTickInfo);else Y0(C,h,1,Q0)}}function d({stream:C,state:v,count:h,cb:a}){return v.afterWriteTickInfo=null,Y0(C,v,h,a)}function Y0(C,v,h,a){if(!v.ending&&!C.destroyed&&v.length===0&&v.needDrain)v.needDrain=!1,C.emit("drain");while(h-- >0)v.pendingcb--,a();if(v.destroyed)m(v);u(C,v)}function m(C){if(C.writing)return;for(let Q0=C.bufferedIndex;Q0<C.buffered.length;++Q0){var v;let{chunk:e,callback:I}=C.buffered[Q0],i=C.objectMode?1:e.length;C.length-=i,I((v=C.errored)!==null&&v!==void 0?v:new T("write"))}let h=C[f].splice(0);for(let Q0=0;Q0<h.length;Q0++){var a;h[Q0]((a=C.errored)!==null&&a!==void 0?a:new T("end"))}s(C)}function U0(C,v){if(v.corked||v.bufferProcessing||v.destroyed||!v.constructed)return;let{buffered:h,bufferedIndex:a,objectMode:Q0}=v,e=h.length-a;if(!e)return;let I=a;if(v.bufferProcessing=!0,e>1&&C._writev){v.pendingcb-=e-1;let i=v.allNoop?Z:(n)=>{for(let H0=I;H0<h.length;++H0)h[H0].callback(n)},q0=v.allNoop&&I===0?h:q(h,I);q0.allBuffers=v.allBuffers,p(C,v,!0,v.length,q0,"",i),s(v)}else{do{let{chunk:i,encoding:q0,callback:n}=h[I];h[I++]=null;let H0=Q0?1:i.length;p(C,v,!1,H0,i,q0,n)}while(I<h.length&&!v.writing);if(I===h.length)s(v);else if(I>256)h.splice(0,I),v.bufferedIndex=0;else v.bufferedIndex=I}v.bufferProcessing=!1}J0.prototype._write=function(C,v,h){if(this._writev)this._writev([{chunk:C,encoding:v}],h);else throw new z("_write()")},J0.prototype._writev=null,J0.prototype.end=function(C,v,h){let a=this._writableState;if(typeof C==="function")h=C,C=null,v=null;else if(typeof v==="function")h=v,v=null;let Q0;if(C!==null&&C!==void 0){let e=B0(this,C,v);if(e instanceof X)Q0=e}if(a.corked)a.corked=1,this.uncork();if(Q0);else if(!a.errored&&!a.ending)a.ending=!0,u(this,a,!0),a.ended=!0;else if(a.finished)Q0=new l("end");else if(a.destroyed)Q0=new T("end");if(typeof h==="function")if(Q0||a.finished)J.nextTick(h,Q0);else a[f].push(h);return this};function M0(C){return C.ending&&!C.destroyed&&C.constructed&&C.length===0&&!C.errored&&C.buffered.length===0&&!C.finished&&!C.writing&&!C.errorEmitted&&!C.closeEmitted}function P0(C,v){let h=!1;function a(Q0){if(h){O(C,Q0!==null&&Q0!==void 0?Q0:R());return}if(h=!0,v.pendingcb--,Q0){let e=v[f].splice(0);for(let I=0;I<e.length;I++)e[I](Q0);O(C,Q0,v.sync)}else if(M0(v))v.prefinished=!0,C.emit("prefinish"),v.pendingcb++,J.nextTick(c,C,v)}v.sync=!0,v.pendingcb++;try{C._final(a)}catch(Q0){a(Q0)}v.sync=!1}function z0(C,v){if(!v.prefinished&&!v.finalCalled)if(typeof C._final==="function"&&!v.destroyed)v.finalCalled=!0,P0(C,v);else v.prefinished=!0,C.emit("prefinish")}function u(C,v,h){if(M0(v)){if(z0(C,v),v.pendingcb===0){if(h)v.pendingcb++,J.nextTick((a,Q0)=>{if(M0(Q0))c(a,Q0);else Q0.pendingcb--},C,v);else if(M0(v))v.pendingcb++,c(C,v)}}}function c(C,v){v.pendingcb--,v.finished=!0;let h=v[f].splice(0);for(let a=0;a<h.length;a++)h[a]();if(C.emit("finish"),v.autoDestroy){let a=C._readableState;if(!a||a.autoDestroy&&(a.endEmitted||a.readable===!1))C.destroy()}}B(J0.prototype,{closed:{__proto__:null,get(){return this._writableState?this._writableState.closed:!1}},destroyed:{__proto__:null,get(){return this._writableState?this._writableState.destroyed:!1},set(C){if(this._writableState)this._writableState.destroyed=C}},writable:{__proto__:null,get(){let C=this._writableState;return!!C&&C.writable!==!1&&!C.destroyed&&!C.errored&&!C.ending&&!C.ended},set(C){if(this._writableState)this._writableState.writable=!!C}},writableFinished:{__proto__:null,get(){return this._writableState?this._writableState.finished:!1}},writableObjectMode:{__proto__:null,get(){return this._writableState?this._writableState.objectMode:!1}},writableBuffer:{__proto__:null,get(){return this._writableState&&this._writableState.getBuffer()}},writableEnded:{__proto__:null,get(){return this._writableState?this._writableState.ending:!1}},writableNeedDrain:{__proto__:null,get(){let C=this._writableState;if(!C)return!1;return!C.destroyed&&!C.ending&&C.needDrain}},writableHighWaterMark:{__proto__:null,get(){return this._writableState&&this._writableState.highWaterMark}},writableCorked:{__proto__:null,get(){return this._writableState?this._writableState.corked:0}},writableLength:{__proto__:null,get(){return this._writableState&&this._writableState.length}},errored:{__proto__:null,enumerable:!1,get(){return this._writableState?this._writableState.errored:null}},writableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._writableState.writable!==!1&&(this._writableState.destroyed||this._writableState.errored)&&!this._writableState.finished)}}});var t=x.destroy;J0.prototype.destroy=function(C,v){let h=this._writableState;if(!h.destroyed&&(h.bufferedIndex<h.buffered.length||h[f].length))J.nextTick(m,h);return t.call(this,C,v),this},J0.prototype._undestroy=x.undestroy,J0.prototype._destroy=function(C,v){v(C)},J0.prototype[w.captureRejectionSymbol]=function(C){this.destroy(C)};var L0;function O0(){if(L0===void 0)L0={};return L0}J0.fromWeb=function(C,v){return O0().newStreamWritableFromWritableStream(C,v)},J0.toWeb=function(C){return O0().newWritableStreamFromStreamWritable(C)}}),GX=S0(($,Q)=>{var J=L1(),q=(x2(),q2(g2)),{isReadable:X,isWritable:Y,isIterable:G,isNodeStream:B,isReadableNodeStream:W,isWritableNodeStream:U,isDuplexNodeStream:V,isReadableStream:L,isWritableStream:w}=y2(),M=n2(),{AbortError:y,codes:{ERR_INVALID_ARG_TYPE:x,ERR_INVALID_RETURN_VALUE:A}}=d0(),{destroyer:D}=b1(),K=f2(),F=K8(),z=A5(),{createDeferredPromise:R}=r0(),_=r7(),T=globalThis.Blob||q.Blob,l=typeof T<"u"?function(f){return f instanceof T}:function(f){return!1},S=globalThis.AbortController||I6().AbortController,{FunctionPrototypeCall:E}=Z0();class P extends K{constructor(f){super(f);if((f===null||f===void 0?void 0:f.readable)===!1)this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0;if((f===null||f===void 0?void 0:f.writable)===!1)this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0}}Q.exports=function f(k,s){if(V(k))return k;if(W(k))return Z({readable:k});if(U(k))return Z({writable:k});if(B(k))return Z({writable:!1,readable:!1});if(L(k))return Z({readable:F.fromWeb(k)});if(w(k))return Z({writable:z.fromWeb(k)});if(typeof k==="function"){let{value:B0,write:N0,final:p,destroy:K0}=O(k);if(G(B0))return _(P,B0,{objectMode:!0,write:N0,final:p,destroy:K0});let N=B0===null||B0===void 0?void 0:B0.then;if(typeof N==="function"){let d,Y0=E(N,B0,(m)=>{if(m!=null)throw new A("nully","body",m)},(m)=>{D(d,m)});return d=new P({objectMode:!0,readable:!1,write:N0,final(m){p(async()=>{try{await Y0,J.nextTick(m,null)}catch(U0){J.nextTick(m,U0)}})},destroy:K0})}throw new A("Iterable, AsyncIterable or AsyncFunction",s,B0)}if(l(k))return f(k.arrayBuffer());if(G(k))return _(P,k,{objectMode:!0,writable:!1});if(L(k===null||k===void 0?void 0:k.readable)&&w(k===null||k===void 0?void 0:k.writable))return P.fromWeb(k);if(typeof(k===null||k===void 0?void 0:k.writable)==="object"||typeof(k===null||k===void 0?void 0:k.readable)==="object"){let B0=k!==null&&k!==void 0&&k.readable?W(k===null||k===void 0?void 0:k.readable)?k===null||k===void 0?void 0:k.readable:f(k.readable):void 0,N0=k!==null&&k!==void 0&&k.writable?U(k===null||k===void 0?void 0:k.writable)?k===null||k===void 0?void 0:k.writable:f(k.writable):void 0;return Z({readable:B0,writable:N0})}let J0=k===null||k===void 0?void 0:k.then;if(typeof J0==="function"){let B0;return E(J0,k,(N0)=>{if(N0!=null)B0.push(N0);B0.push(null)},(N0)=>{D(B0,N0)}),B0=new P({objectMode:!0,writable:!1,read(){}})}throw new x(s,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],k)};function O(f){let{promise:k,resolve:s}=R(),J0=new S,B0=J0.signal;return{value:f(async function*(){while(!0){let N0=k;k=null;let{chunk:p,done:K0,cb:N}=await N0;if(J.nextTick(N),K0)return;if(B0.aborted)throw new y(void 0,{cause:B0.reason});({promise:k,resolve:s}=R()),yield p}}(),{signal:B0}),write(N0,p,K0){let N=s;s=null,N({chunk:N0,done:!1,cb:K0})},final(N0){let p=s;s=null,p({done:!0,cb:N0})},destroy(N0,p){J0.abort(),p(N0)}}}function Z(f){let k=f.readable&&typeof f.readable.read!=="function"?F.wrap(f.readable):f.readable,s=f.writable,J0=!!X(k),B0=!!Y(s),N0,p,K0,N,d;function Y0(m){let U0=N;if(N=null,U0)U0(m);else if(m)d.destroy(m)}if(d=new P({readableObjectMode:!!(k!==null&&k!==void 0&&k.readableObjectMode),writableObjectMode:!!(s!==null&&s!==void 0&&s.writableObjectMode),readable:J0,writable:B0}),B0)M(s,(m)=>{if(B0=!1,m)D(k,m);Y0(m)}),d._write=function(m,U0,M0){if(s.write(m,U0))M0();else N0=M0},d._final=function(m){s.end(),p=m},s.on("drain",function(){if(N0){let m=N0;N0=null,m()}}),s.on("finish",function(){if(p){let m=p;p=null,m()}});if(J0)M(k,(m)=>{if(J0=!1,m)D(k,m);Y0(m)}),k.on("readable",function(){if(K0){let m=K0;K0=null,m()}}),k.on("end",function(){d.push(null)}),d._read=function(){while(!0){let m=k.read();if(m===null){K0=d._read;return}if(!d.push(m))return}};return d._destroy=function(m,U0){if(!m&&N!==null)m=new y;if(K0=null,N0=null,p=null,N===null)U0(m);else N=U0,D(s,m),D(k,m)},d}}),f2=S0(($,Q)=>{var{ObjectDefineProperties:J,ObjectGetOwnPropertyDescriptor:q,ObjectKeys:X,ObjectSetPrototypeOf:Y}=Z0();Q.exports=W;var G=K8(),B=A5();Y(W.prototype,G.prototype),Y(W,G);{let w=X(B.prototype);for(let M=0;M<w.length;M++){let y=w[M];if(!W.prototype[y])W.prototype[y]=B.prototype[y]}}function W(w){if(!(this instanceof W))return new W(w);if(G.call(this,w),B.call(this,w),w){if(this.allowHalfOpen=w.allowHalfOpen!==!1,w.readable===!1)this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0;if(w.writable===!1)this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0}else this.allowHalfOpen=!0}J(W.prototype,{writable:{__proto__:null,...q(B.prototype,"writable")},writableHighWaterMark:{__proto__:null,...q(B.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...q(B.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...q(B.prototype,"writableBuffer")},writableLength:{__proto__:null,...q(B.prototype,"writableLength")},writableFinished:{__proto__:null,...q(B.prototype,"writableFinished")},writableCorked:{__proto__:null,...q(B.prototype,"writableCorked")},writableEnded:{__proto__:null,...q(B.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...q(B.prototype,"writableNeedDrain")},destroyed:{__proto__:null,get(){if(this._readableState===void 0||this._writableState===void 0)return!1;return this._readableState.destroyed&&this._writableState.destroyed},set(w){if(this._readableState&&this._writableState)this._readableState.destroyed=w,this._writableState.destroyed=w}}});var U;function V(){if(U===void 0)U={};return U}W.fromWeb=function(w,M){return V().newStreamDuplexFromReadableWritablePair(w,M)},W.toWeb=function(w){return V().newReadableWritablePairFromDuplex(w)};var L;W.from=function(w){if(!L)L=GX();return L(w,"body")}}),a7=S0(($,Q)=>{var{ObjectSetPrototypeOf:J,Symbol:q}=Z0();Q.exports=W;var{ERR_METHOD_NOT_IMPLEMENTED:X}=d0().codes,Y=f2(),{getHighWaterMark:G}=V8();J(W.prototype,Y.prototype),J(W,Y);var B=q("kCallback");function W(L){if(!(this instanceof W))return new W(L);let w=L?G(this,L,"readableHighWaterMark",!0):null;if(w===0)L={...L,highWaterMark:null,readableHighWaterMark:w,writableHighWaterMark:L.writableHighWaterMark||0};if(Y.call(this,L),this._readableState.sync=!1,this[B]=null,L){if(typeof L.transform==="function")this._transform=L.transform;if(typeof L.flush==="function")this._flush=L.flush}this.on("prefinish",V)}function U(L){if(typeof this._flush==="function"&&!this.destroyed)this._flush((w,M)=>{if(w){if(L)L(w);else this.destroy(w);return}if(M!=null)this.push(M);if(this.push(null),L)L()});else if(this.push(null),L)L()}function V(){if(this._final!==U)U.call(this)}W.prototype._final=U,W.prototype._transform=function(L,w,M){throw new X("_transform()")},W.prototype._write=function(L,w,M){let y=this._readableState,x=this._writableState,A=y.length;this._transform(L,w,(D,K)=>{if(D){M(D);return}if(K!=null)this.push(K);if(x.ended||A===y.length||y.length<y.highWaterMark)M();else this[B]=M})},W.prototype._read=function(){if(this[B]){let L=this[B];this[B]=null,L()}}}),s7=S0(($,Q)=>{var{ObjectSetPrototypeOf:J}=Z0();Q.exports=X;var q=a7();J(X.prototype,q.prototype),J(X,q);function X(Y){if(!(this instanceof X))return new X(Y);q.call(this,Y)}X.prototype._transform=function(Y,G,B){B(null,Y)}}),D5=S0(($,Q)=>{var J=L1(),{ArrayIsArray:q,Promise:X,SymbolAsyncIterator:Y,SymbolDispose:G}=Z0(),B=n2(),{once:W}=r0(),U=b1(),V=f2(),{aggregateTwoErrors:L,codes:{ERR_INVALID_ARG_TYPE:w,ERR_INVALID_RETURN_VALUE:M,ERR_MISSING_ARGS:y,ERR_STREAM_DESTROYED:x,ERR_STREAM_PREMATURE_CLOSE:A},AbortError:D}=d0(),{validateFunction:K,validateAbortSignal:F}=S6(),{isIterable:z,isReadable:R,isReadableNodeStream:_,isNodeStream:T,isTransformStream:l,isWebStream:S,isReadableStream:E,isReadableFinished:P}=y2(),O=globalThis.AbortController||I6().AbortController,Z,f,k;function s(m,U0,M0){let P0=!1;m.on("close",()=>{P0=!0});let z0=B(m,{readable:U0,writable:M0},(u)=>{P0=!u});return{destroy:(u)=>{if(P0)return;P0=!0,U.destroyer(m,u||new x("pipe"))},cleanup:z0}}function J0(m){return K(m[m.length-1],"streams[stream.length - 1]"),m.pop()}function B0(m){if(z(m))return m;else if(_(m))return N0(m);throw new w("val",["Readable","Iterable","AsyncIterable"],m)}async function*N0(m){if(!f)f=K8();yield*f.prototype[Y].call(m)}async function p(m,U0,M0,{end:P0}){let z0,u=null,c=(O0)=>{if(O0)z0=O0;if(u){let C=u;u=null,C()}},t=()=>new X((O0,C)=>{if(z0)C(z0);else u=()=>{if(z0)C(z0);else O0()}});U0.on("drain",c);let L0=B(U0,{readable:!1},c);try{if(U0.writableNeedDrain)await t();for await(let O0 of m)if(!U0.write(O0))await t();if(P0)U0.end(),await t();M0()}catch(O0){M0(z0!==O0?L(z0,O0):O0)}finally{L0(),U0.off("drain",c)}}async function K0(m,U0,M0,{end:P0}){if(l(U0))U0=U0.writable;let z0=U0.getWriter();try{for await(let u of m)await z0.ready,z0.write(u).catch(()=>{});if(await z0.ready,P0)await z0.close();M0()}catch(u){try{await z0.abort(u),M0(u)}catch(c){M0(c)}}}function N(...m){return d(m,W(J0(m)))}function d(m,U0,M0){if(m.length===1&&q(m[0]))m=m[0];if(m.length<2)throw new y("streams");let P0=new O,z0=P0.signal,u=M0===null||M0===void 0?void 0:M0.signal,c=[];F(u,"options.signal");function t(){Q0(new D)}k=k||r0().addAbortListener;let L0;if(u)L0=k(u,t);let O0,C,v=[],h=0;function a(n){Q0(n,--h===0)}function Q0(n,H0){var E0;if(n&&(!O0||O0.code==="ERR_STREAM_PREMATURE_CLOSE"))O0=n;if(!O0&&!H0)return;while(v.length)v.shift()(O0);if((E0=L0)===null||E0===void 0||E0[G](),P0.abort(),H0){if(!O0)c.forEach(($2)=>$2());J.nextTick(U0,O0,C)}}let e;for(let n=0;n<m.length;n++){let H0=m[n],E0=n<m.length-1,$2=n>0,Q2=E0||(M0===null||M0===void 0?void 0:M0.end)!==!1,V1=n===m.length-1;if(T(H0)){let u0=function(n0){if(n0&&n0.name!=="AbortError"&&n0.code!=="ERR_STREAM_PREMATURE_CLOSE")a(n0)};var I=u0;if(Q2){let{destroy:n0,cleanup:x1}=s(H0,E0,$2);if(v.push(n0),R(H0)&&V1)c.push(x1)}if(H0.on("error",u0),R(H0)&&V1)c.push(()=>{H0.removeListener("error",u0)})}if(n===0)if(typeof H0==="function"){if(e=H0({signal:z0}),!z(e))throw new M("Iterable, AsyncIterable or Stream","source",e)}else if(z(H0)||_(H0)||l(H0))e=H0;else e=V.from(H0);else if(typeof H0==="function"){if(l(e)){var i;e=B0((i=e)===null||i===void 0?void 0:i.readable)}else e=B0(e);if(e=H0(e,{signal:z0}),E0){if(!z(e,!0))throw new M("AsyncIterable",`transform[${n-1}]`,e)}else{var q0;if(!Z)Z=s7();let u0=new Z({objectMode:!0}),n0=(q0=e)===null||q0===void 0?void 0:q0.then;if(typeof n0==="function")h++,n0.call(e,(L2)=>{if(C=L2,L2!=null)u0.write(L2);if(Q2)u0.end();J.nextTick(a)},(L2)=>{u0.destroy(L2),J.nextTick(a,L2)});else if(z(e,!0))h++,p(e,u0,a,{end:Q2});else if(E(e)||l(e)){let L2=e.readable||e;h++,p(L2,u0,a,{end:Q2})}else throw new M("AsyncIterable or Promise","destination",e);e=u0;let{destroy:x1,cleanup:f1}=s(e,!1,!0);if(v.push(x1),V1)c.push(f1)}}else if(T(H0)){if(_(e)){h+=2;let u0=Y0(e,H0,a,{end:Q2});if(R(H0)&&V1)c.push(u0)}else if(l(e)||E(e)){let u0=e.readable||e;h++,p(u0,H0,a,{end:Q2})}else if(z(e))h++,p(e,H0,a,{end:Q2});else throw new w("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],e);e=H0}else if(S(H0)){if(_(e))h++,K0(B0(e),H0,a,{end:Q2});else if(E(e)||z(e))h++,K0(e,H0,a,{end:Q2});else if(l(e))h++,K0(e.readable,H0,a,{end:Q2});else throw new w("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],e);e=H0}else e=V.from(H0)}if(z0!==null&&z0!==void 0&&z0.aborted||u!==null&&u!==void 0&&u.aborted)J.nextTick(t);return e}function Y0(m,U0,M0,{end:P0}){let z0=!1;if(U0.on("close",()=>{if(!z0)M0(new A)}),m.pipe(U0,{end:!1}),P0){let c=function(){z0=!0,U0.end()};var u=c;if(P(m))J.nextTick(c);else m.once("end",c)}else M0();return B(m,{readable:!0,writable:!1},(c)=>{let t=m._readableState;if(c&&c.code==="ERR_STREAM_PREMATURE_CLOSE"&&t&&t.ended&&!t.errored&&!t.errorEmitted)m.once("end",M0).once("error",M0);else M0(c)}),B(U0,{readable:!1,writable:!0},M0)}Q.exports={pipelineImpl:d,pipeline:N}}),t7=S0(($,Q)=>{var{pipeline:J}=D5(),q=f2(),{destroyer:X}=b1(),{isNodeStream:Y,isReadable:G,isWritable:B,isWebStream:W,isTransformStream:U,isWritableStream:V,isReadableStream:L}=y2(),{AbortError:w,codes:{ERR_INVALID_ARG_VALUE:M,ERR_MISSING_ARGS:y}}=d0(),x=n2();Q.exports=function(...A){if(A.length===0)throw new y("streams");if(A.length===1)return q.from(A[0]);let D=[...A];if(typeof A[0]==="function")A[0]=q.from(A[0]);if(typeof A[A.length-1]==="function"){let O=A.length-1;A[O]=q.from(A[O])}for(let O=0;O<A.length;++O){if(!Y(A[O])&&!W(A[O]))continue;if(O<A.length-1&&!(G(A[O])||L(A[O])||U(A[O])))throw new M(`streams[${O}]`,D[O],"must be readable");if(O>0&&!(B(A[O])||V(A[O])||U(A[O])))throw new M(`streams[${O}]`,D[O],"must be writable")}let K,F,z,R,_;function T(O){let Z=R;if(R=null,Z)Z(O);else if(O)_.destroy(O);else if(!P&&!E)_.destroy()}let l=A[0],S=J(A,T),E=!!(B(l)||V(l)||U(l)),P=!!(G(S)||L(S)||U(S));if(_=new q({writableObjectMode:!!(l!==null&&l!==void 0&&l.writableObjectMode),readableObjectMode:!!(S!==null&&S!==void 0&&S.readableObjectMode),writable:E,readable:P}),E){if(Y(l))_._write=function(Z,f,k){if(l.write(Z,f))k();else K=k},_._final=function(Z){l.end(),F=Z},l.on("drain",function(){if(K){let Z=K;K=null,Z()}});else if(W(l)){let Z=(U(l)?l.writable:l).getWriter();_._write=async function(f,k,s){try{await Z.ready,Z.write(f).catch(()=>{}),s()}catch(J0){s(J0)}},_._final=async function(f){try{await Z.ready,Z.close().catch(()=>{}),F=f}catch(k){f(k)}}}let O=U(S)?S.readable:S;x(O,()=>{if(F){let Z=F;F=null,Z()}})}if(P){if(Y(S))S.on("readable",function(){if(z){let O=z;z=null,O()}}),S.on("end",function(){_.push(null)}),_._read=function(){while(!0){let O=S.read();if(O===null){z=_._read;return}if(!_.push(O))return}};else if(W(S)){let O=(U(S)?S.readable:S).getReader();_._read=async function(){while(!0)try{let{value:Z,done:f}=await O.read();if(!_.push(Z))return;if(f){_.push(null);return}}catch{return}}}}return _._destroy=function(O,Z){if(!O&&R!==null)O=new w;if(z=null,K=null,F=null,R===null)Z(O);else if(R=Z,Y(S))X(S,O)},_}}),BX=S0(($,Q)=>{var J=globalThis.AbortController||I6().AbortController,{codes:{ERR_INVALID_ARG_VALUE:q,ERR_INVALID_ARG_TYPE:X,ERR_MISSING_ARGS:Y,ERR_OUT_OF_RANGE:G},AbortError:B}=d0(),{validateAbortSignal:W,validateInteger:U,validateObject:V}=S6(),L=Z0().Symbol("kWeak"),w=Z0().Symbol("kResistStopPropagation"),{finished:M}=n2(),y=t7(),{addAbortSignalNoValidate:x}=W8(),{isWritable:A,isNodeStream:D}=y2(),{deprecate:K}=r0(),{ArrayPrototypePush:F,Boolean:z,MathFloor:R,Number:_,NumberIsNaN:T,Promise:l,PromiseReject:S,PromiseResolve:E,PromisePrototypeThen:P,Symbol:O}=Z0(),Z=O("kEmpty"),f=O("kEof");function k(u,c){if(c!=null)V(c,"options");if((c===null||c===void 0?void 0:c.signal)!=null)W(c.signal,"options.signal");if(D(u)&&!A(u))throw new q("stream",u,"must be writable");let t=y(this,u);if(c!==null&&c!==void 0&&c.signal)x(c.signal,t);return t}function s(u,c){if(typeof u!=="function")throw new X("fn",["Function","AsyncFunction"],u);if(c!=null)V(c,"options");if((c===null||c===void 0?void 0:c.signal)!=null)W(c.signal,"options.signal");let t=1;if((c===null||c===void 0?void 0:c.concurrency)!=null)t=R(c.concurrency);let L0=t-1;if((c===null||c===void 0?void 0:c.highWaterMark)!=null)L0=R(c.highWaterMark);return U(t,"options.concurrency",1),U(L0,"options.highWaterMark",0),L0+=t,async function*(){let O0=r0().AbortSignalAny([c===null||c===void 0?void 0:c.signal].filter(z)),C=this,v=[],h={signal:O0},a,Q0,e=!1,I=0;function i(){e=!0,q0()}function q0(){I-=1,n()}function n(){if(Q0&&!e&&I<t&&v.length<L0)Q0(),Q0=null}async function H0(){try{for await(let E0 of C){if(e)return;if(O0.aborted)throw new B;try{if(E0=u(E0,h),E0===Z)continue;E0=E(E0)}catch($2){E0=S($2)}if(I+=1,P(E0,q0,i),v.push(E0),a)a(),a=null;if(!e&&(v.length>=L0||I>=t))await new l(($2)=>{Q0=$2})}v.push(f)}catch(E0){let $2=S(E0);P($2,q0,i),v.push($2)}finally{if(e=!0,a)a(),a=null}}H0();try{while(!0){while(v.length>0){let E0=await v[0];if(E0===f)return;if(O0.aborted)throw new B;if(E0!==Z)yield E0;v.shift(),n()}await new l((E0)=>{a=E0})}}finally{if(e=!0,Q0)Q0(),Q0=null}}.call(this)}function J0(u=void 0){if(u!=null)V(u,"options");if((u===null||u===void 0?void 0:u.signal)!=null)W(u.signal,"options.signal");return async function*(){let c=0;for await(let L0 of this){var t;if(u!==null&&u!==void 0&&(t=u.signal)!==null&&t!==void 0&&t.aborted)throw new B({cause:u.signal.reason});yield[c++,L0]}}.call(this)}async function B0(u,c=void 0){for await(let t of N.call(this,u,c))return!0;return!1}async function N0(u,c=void 0){if(typeof u!=="function")throw new X("fn",["Function","AsyncFunction"],u);return!await B0.call(this,async(...t)=>{return!await u(...t)},c)}async function p(u,c){for await(let t of N.call(this,u,c))return t;return}async function K0(u,c){if(typeof u!=="function")throw new X("fn",["Function","AsyncFunction"],u);async function t(L0,O0){return await u(L0,O0),Z}for await(let L0 of s.call(this,t,c));}function N(u,c){if(typeof u!=="function")throw new X("fn",["Function","AsyncFunction"],u);async function t(L0,O0){if(await u(L0,O0))return L0;return Z}return s.call(this,t,c)}class d extends Y{constructor(){super("reduce");this.message="Reduce of an empty stream requires an initial value"}}async function Y0(u,c,t){var L0;if(typeof u!=="function")throw new X("reducer",["Function","AsyncFunction"],u);if(t!=null)V(t,"options");if((t===null||t===void 0?void 0:t.signal)!=null)W(t.signal,"options.signal");let O0=arguments.length>1;if(t!==null&&t!==void 0&&(L0=t.signal)!==null&&L0!==void 0&&L0.aborted){let Q0=new B(void 0,{cause:t.signal.reason});throw this.once("error",()=>{}),await M(this.destroy(Q0)),Q0}let C=new J,v=C.signal;if(t!==null&&t!==void 0&&t.signal){let Q0={once:!0,[L]:this,[w]:!0};t.signal.addEventListener("abort",()=>C.abort(),Q0)}let h=!1;try{for await(let Q0 of this){var a;if(h=!0,t!==null&&t!==void 0&&(a=t.signal)!==null&&a!==void 0&&a.aborted)throw new B;if(!O0)c=Q0,O0=!0;else c=await u(c,Q0,{signal:v})}if(!h&&!O0)throw new d}finally{C.abort()}return c}async function m(u){if(u!=null)V(u,"options");if((u===null||u===void 0?void 0:u.signal)!=null)W(u.signal,"options.signal");let c=[];for await(let L0 of this){var t;if(u!==null&&u!==void 0&&(t=u.signal)!==null&&t!==void 0&&t.aborted)throw new B(void 0,{cause:u.signal.reason});F(c,L0)}return c}function U0(u,c){let t=s.call(this,u,c);return async function*(){for await(let L0 of t)yield*L0}.call(this)}function M0(u){if(u=_(u),T(u))return 0;if(u<0)throw new G("number",">= 0",u);return u}function P0(u,c=void 0){if(c!=null)V(c,"options");if((c===null||c===void 0?void 0:c.signal)!=null)W(c.signal,"options.signal");return u=M0(u),async function*(){var t;if(c!==null&&c!==void 0&&(t=c.signal)!==null&&t!==void 0&&t.aborted)throw new B;for await(let O0 of this){var L0;if(c!==null&&c!==void 0&&(L0=c.signal)!==null&&L0!==void 0&&L0.aborted)throw new B;if(u--<=0)yield O0}}.call(this)}function z0(u,c=void 0){if(c!=null)V(c,"options");if((c===null||c===void 0?void 0:c.signal)!=null)W(c.signal,"options.signal");return u=M0(u),async function*(){var t;if(c!==null&&c!==void 0&&(t=c.signal)!==null&&t!==void 0&&t.aborted)throw new B;for await(let O0 of this){var L0;if(c!==null&&c!==void 0&&(L0=c.signal)!==null&&L0!==void 0&&L0.aborted)throw new B;if(u-- >0)yield O0;if(u<=0)return}}.call(this)}Q.exports.streamReturningOperators={asIndexedPairs:K(J0,"readable.asIndexedPairs will be removed in a future version."),drop:P0,filter:N,flatMap:U0,map:s,take:z0,compose:k},Q.exports.promiseReturningOperators={every:N0,forEach:K0,reduce:Y0,toArray:m,some:B0,find:p}}),e7=S0(($,Q)=>{var{ArrayPrototypePop:J,Promise:q}=Z0(),{isIterable:X,isNodeStream:Y,isWebStream:G}=y2(),{pipelineImpl:B}=D5(),{finished:W}=n2();$$();function U(...V){return new q((L,w)=>{let M,y,x=V[V.length-1];if(x&&typeof x==="object"&&!Y(x)&&!X(x)&&!G(x)){let A=J(V);M=A.signal,y=A.end}B(V,(A,D)=>{if(A)w(A);else L(D)},{signal:M,end:y})})}Q.exports={finished:W,pipeline:U}}),$$=S0(($,Q)=>{var{Buffer:J}=(x2(),q2(g2)),{ObjectDefineProperty:q,ObjectKeys:X,ReflectApply:Y}=Z0(),{promisify:{custom:G}}=r0(),{streamReturningOperators:B,promiseReturningOperators:W}=BX(),{codes:{ERR_ILLEGAL_CONSTRUCTOR:U}}=d0(),V=t7(),{setDefaultHighWaterMark:L,getDefaultHighWaterMark:w}=V8(),{pipeline:M}=D5(),{destroyer:y}=b1(),x=n2(),A=e7(),D=y2(),K=Q.exports=N5().Stream;K.isDestroyed=D.isDestroyed,K.isDisturbed=D.isDisturbed,K.isErrored=D.isErrored,K.isReadable=D.isReadable,K.isWritable=D.isWritable,K.Readable=K8();for(let z of X(B)){let R=function(...T){if(new.target)throw U();return K.Readable.from(Y(_,this,T))},_=B[z];q(R,"name",{__proto__:null,value:_.name}),q(R,"length",{__proto__:null,value:_.length}),q(K.Readable.prototype,z,{__proto__:null,value:R,enumerable:!1,configurable:!0,writable:!0})}for(let z of X(W)){let R=function(...T){if(new.target)throw U();return Y(_,this,T)},_=W[z];q(R,"name",{__proto__:null,value:_.name}),q(R,"length",{__proto__:null,value:_.length}),q(K.Readable.prototype,z,{__proto__:null,value:R,enumerable:!1,configurable:!0,writable:!0})}K.Writable=A5(),K.Duplex=f2(),K.Transform=a7(),K.PassThrough=s7(),K.pipeline=M;var{addAbortSignal:F}=W8();K.addAbortSignal=F,K.finished=x,K.destroy=y,K.compose=V,K.setDefaultHighWaterMark=L,K.getDefaultHighWaterMark=w,q(K,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return A}}),q(M,G,{__proto__:null,enumerable:!0,get(){return A.pipeline}}),q(x,G,{__proto__:null,enumerable:!0,get(){return A.finished}}),K.Stream=K,K._isUint8Array=function(z){return z instanceof Uint8Array},K._uint8ArrayToBuffer=function(z){return J.from(z.buffer,z.byteOffset,z.byteLength)}}),UX=S0(($,Q)=>{var J=H8();{let q=$$(),X=e7(),Y=q.Readable.destroy;Q.exports=q.Readable,Q.exports._uint8ArrayToBuffer=q._uint8ArrayToBuffer,Q.exports._isUint8Array=q._isUint8Array,Q.exports.isDisturbed=q.isDisturbed,Q.exports.isErrored=q.isErrored,Q.exports.isReadable=q.isReadable,Q.exports.Readable=q.Readable,Q.exports.Writable=q.Writable,Q.exports.Duplex=q.Duplex,Q.exports.Transform=q.Transform,Q.exports.PassThrough=q.PassThrough,Q.exports.addAbortSignal=q.addAbortSignal,Q.exports.finished=q.finished,Q.exports.destroy=q.destroy,Q.exports.destroy=Y,Q.exports.pipeline=q.pipeline,Q.exports.compose=q.compose,Object.defineProperty(q,"promises",{configurable:!0,enumerable:!0,get(){return X}}),Q.exports.Stream=q.Stream}Q.exports.default=Q.exports});Q$.exports=UX()});var _2=j0((VX)=>{VX.base64=!0;VX.array=!0;VX.string=!0;VX.arraybuffer=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u";VX.nodebuffer=typeof Buffer<"u";VX.uint8array=typeof Uint8Array<"u";if(typeof ArrayBuffer>"u")VX.blob=!1;else{j8=new ArrayBuffer(0);try{VX.blob=new Blob([j8],{type:"application/zip"}).size===0}catch($){try{R5=self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder,M8=new R5,M8.append(j8),VX.blob=M8.getBlob("application/zip").size===0}catch(Q){VX.blob=!1}}}var j8,R5,M8;try{VX.nodestream=!!H8().Readable}catch($){VX.nodestream=!1}});var C5=j0((OX)=>{var LX=g0(),zX=_2(),N2="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";OX.encode=function($){var Q=[],J,q,X,Y,G,B,W,U=0,V=$.length,L=V,w=LX.getTypeOf($)!=="string";while(U<$.length){if(L=V-U,!w)J=$.charCodeAt(U++),q=U<V?$.charCodeAt(U++):0,X=U<V?$.charCodeAt(U++):0;else J=$[U++],q=U<V?$[U++]:0,X=U<V?$[U++]:0;Y=J>>2,G=(J&3)<<4|q>>4,B=L>1?(q&15)<<2|X>>6:64,W=L>2?X&63:64,Q.push(N2.charAt(Y)+N2.charAt(G)+N2.charAt(B)+N2.charAt(W))}return Q.join("")};OX.decode=function($){var Q,J,q,X,Y,G,B,W=0,U=0,V="data:";if($.substr(0,V.length)===V)throw Error("Invalid base64 input, it looks like a data url.");$=$.replace(/[^A-Za-z0-9+/=]/g,"");var L=$.length*3/4;if($.charAt($.length-1)===N2.charAt(64))L--;if($.charAt($.length-2)===N2.charAt(64))L--;if(L%1!==0)throw Error("Invalid base64 input, bad content length.");var w;if(zX.uint8array)w=new Uint8Array(L|0);else w=Array(L|0);while(W<$.length){if(X=N2.indexOf($.charAt(W++)),Y=N2.indexOf($.charAt(W++)),G=N2.indexOf($.charAt(W++)),B=N2.indexOf($.charAt(W++)),Q=X<<2|Y>>4,J=(Y&15)<<4|G>>2,q=(G&3)<<6|B,w[U++]=Q,G!==64)w[U++]=J;if(B!==64)w[U++]=q}return w}});var E6=j0(($K,J$)=>{J$.exports={isNode:typeof Buffer<"u",newBufferFrom:function($,Q){if(Buffer.from&&Buffer.from!==Uint8Array.from)return Buffer.from($,Q);else{if(typeof $==="number")throw Error('The "data" argument must not be a number');return new Buffer($,Q)}},allocBuffer:function($){if(Buffer.alloc)return Buffer.alloc($);else{var Q=new Buffer($);return Q.fill(0),Q}},isBuffer:function($){return Buffer.isBuffer($)},isStream:function($){return $&&typeof $.on==="function"&&typeof $.pause==="function"&&typeof $.resume==="function"}}});var Y$=j0((QK,X$)=>{var q$=global.MutationObserver||global.WebKitMutationObserver,v6;if(q$)F8=0,I5=new q$(w8),L8=global.document.createTextNode(""),I5.observe(L8,{characterData:!0}),v6=function(){L8.data=F8=++F8%2};else if(!global.setImmediate&&typeof global.MessageChannel<"u")z8=new global.MessageChannel,z8.port1.onmessage=w8,v6=function(){z8.port2.postMessage(0)};else if("document"in global&&"onreadystatechange"in global.document.createElement("script"))v6=function(){var $=global.document.createElement("script");$.onreadystatechange=function(){w8(),$.onreadystatechange=null,$.parentNode.removeChild($),$=null},global.document.documentElement.appendChild($)};else v6=function(){setTimeout(w8,0)};var F8,I5,L8,z8,S5,k6=[];function w8(){S5=!0;var $,Q,J=k6.length;while(J){Q=k6,k6=[],$=-1;while(++$<J)Q[$]();J=k6.length}S5=!1}X$.exports=DX;function DX($){if(k6.push($)===1&&!S5)v6()}});var K$=j0((JK,V$)=>{var PX=Y$();function h1(){}var p0={},G$=["REJECTED"],E5=["FULFILLED"],B$=["PENDING"];V$.exports=o2;function o2($){if(typeof $!=="function")throw TypeError("resolver must be a function");if(this.state=B$,this.queue=[],this.outcome=void 0,$!==h1)U$(this,$)}o2.prototype.finally=function($){if(typeof $!=="function")return this;var Q=this.constructor;return this.then(J,q);function J(X){function Y(){return X}return Q.resolve($()).then(Y)}function q(X){function Y(){throw X}return Q.resolve($()).then(Y)}};o2.prototype.catch=function($){return this.then(null,$)};o2.prototype.then=function($,Q){if(typeof $!=="function"&&this.state===E5||typeof Q!=="function"&&this.state===G$)return this;var J=new this.constructor(h1);if(this.state!==B$){var q=this.state===E5?$:Q;v5(J,q,this.outcome)}else this.queue.push(new T6(J,$,Q));return J};function T6($,Q,J){if(this.promise=$,typeof Q==="function")this.onFulfilled=Q,this.callFulfilled=this.otherCallFulfilled;if(typeof J==="function")this.onRejected=J,this.callRejected=this.otherCallRejected}T6.prototype.callFulfilled=function($){p0.resolve(this.promise,$)};T6.prototype.otherCallFulfilled=function($){v5(this.promise,this.onFulfilled,$)};T6.prototype.callRejected=function($){p0.reject(this.promise,$)};T6.prototype.otherCallRejected=function($){v5(this.promise,this.onRejected,$)};function v5($,Q,J){PX(function(){var q;try{q=Q(J)}catch(X){return p0.reject($,X)}if(q===$)p0.reject($,TypeError("Cannot resolve promise with itself"));else p0.resolve($,q)})}p0.resolve=function($,Q){var J=W$(RX,Q);if(J.status==="error")return p0.reject($,J.value);var q=J.value;if(q)U$($,q);else{$.state=E5,$.outcome=Q;var X=-1,Y=$.queue.length;while(++X<Y)$.queue[X].callFulfilled(Q)}return $};p0.reject=function($,Q){$.state=G$,$.outcome=Q;var J=-1,q=$.queue.length;while(++J<q)$.queue[J].callRejected(Q);return $};function RX($){var Q=$&&$.then;if($&&(typeof $==="object"||typeof $==="function")&&typeof Q==="function")return function(){Q.apply($,arguments)}}function U$($,Q){var J=!1;function q(B){if(J)return;J=!0,p0.reject($,B)}function X(B){if(J)return;J=!0,p0.resolve($,B)}function Y(){Q(X,q)}var G=W$(Y);if(G.status==="error")q(G.value)}function W$($,Q){var J={};try{J.value=$(Q),J.status="success"}catch(q){J.status="error",J.value=q}return J}o2.resolve=CX;function CX($){if($ instanceof this)return $;return p0.resolve(new this(h1),$)}o2.reject=IX;function IX($){var Q=new this(h1);return p0.reject(Q,$)}o2.all=SX;function SX($){var Q=this;if(Object.prototype.toString.call($)!=="[object Array]")return this.reject(TypeError("must be an array"));var J=$.length,q=!1;if(!J)return this.resolve([]);var X=Array(J),Y=0,G=-1,B=new this(h1);while(++G<J)W($[G],G);return B;function W(U,V){Q.resolve(U).then(L,function(w){if(!q)q=!0,p0.reject(B,w)});function L(w){if(X[V]=w,++Y===J&&!q)q=!0,p0.resolve(B,X)}}}o2.race=EX;function EX($){var Q=this;if(Object.prototype.toString.call($)!=="[object Array]")return this.reject(TypeError("must be an array"));var J=$.length,q=!1;if(!J)return this.resolve([]);var X=-1,Y=new this(h1);while(++X<J)G($[X]);return Y;function G(B){Q.resolve(B).then(function(W){if(!q)q=!0,p0.resolve(Y,W)},function(W){if(!q)q=!0,p0.reject(Y,W)})}}});var m1=j0((qK,H$)=>{var k5=null;if(typeof Promise<"u")k5=Promise;else k5=K$();H$.exports={Promise:k5}});var M$=j0((j$)=>{(function($,Q){if($.setImmediate)return;var J=1,q={},X=!1,Y=$.document,G;function B(K){if(typeof K!=="function")K=Function(""+K);var F=Array(arguments.length-1);for(var z=0;z<F.length;z++)F[z]=arguments[z+1];var R={callback:K,args:F};return q[J]=R,G(J),J++}function W(K){delete q[K]}function U(K){var{callback:F,args:z}=K;switch(z.length){case 0:F();break;case 1:F(z[0]);break;case 2:F(z[0],z[1]);break;case 3:F(z[0],z[1],z[2]);break;default:F.apply(Q,z);break}}function V(K){if(X)setTimeout(V,0,K);else{var F=q[K];if(F){X=!0;try{U(F)}finally{W(K),X=!1}}}}function L(){G=function(K){process.nextTick(function(){V(K)})}}function w(){if($.postMessage&&!$.importScripts){var K=!0,F=$.onmessage;return $.onmessage=function(){K=!1},$.postMessage("","*"),$.onmessage=F,K}}function M(){var K="setImmediate$"+Math.random()+"$",F=function(z){if(z.source===$&&typeof z.data==="string"&&z.data.indexOf(K)===0)V(+z.data.slice(K.length))};if($.addEventListener)$.addEventListener("message",F,!1);else $.attachEvent("onmessage",F);G=function(z){$.postMessage(K+z,"*")}}function y(){var K=new MessageChannel;K.port1.onmessage=function(F){var z=F.data;V(z)},G=function(F){K.port2.postMessage(F)}}function x(){var K=Y.documentElement;G=function(F){var z=Y.createElement("script");z.onreadystatechange=function(){V(F),z.onreadystatechange=null,K.removeChild(z),z=null},K.appendChild(z)}}function A(){G=function(K){setTimeout(V,0,K)}}var D=Object.getPrototypeOf&&Object.getPrototypeOf($);if(D=D&&D.setTimeout?D:$,{}.toString.call($.process)==="[object process]")L();else if(w())M();else if($.MessageChannel)y();else if(Y&&"onreadystatechange"in Y.createElement("script"))x();else A();D.setImmediate=B,D.clearImmediate=W})(typeof self>"u"?typeof global>"u"?j$:global:self)});var g0=j0((TX)=>{var r2=_2(),vX=C5(),u1=E6(),T5=m1();M$();function kX($){var Q=null;if(r2.uint8array)Q=new Uint8Array($.length);else Q=Array($.length);return N8($,Q)}TX.newBlob=function($,Q){TX.checkSupport("blob");try{return new Blob([$],{type:Q})}catch(X){try{var J=self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder,q=new J;return q.append($),q.getBlob(Q)}catch(Y){throw Error("Bug : can't construct the Blob.")}}};function Z6($){return $}function N8($,Q){for(var J=0;J<$.length;++J)Q[J]=$.charCodeAt(J)&255;return Q}var O8={stringifyByChunk:function($,Q,J){var q=[],X=0,Y=$.length;if(Y<=J)return String.fromCharCode.apply(null,$);while(X<Y){if(Q==="array"||Q==="nodebuffer")q.push(String.fromCharCode.apply(null,$.slice(X,Math.min(X+J,Y))));else q.push(String.fromCharCode.apply(null,$.subarray(X,Math.min(X+J,Y))));X+=J}return q.join("")},stringifyByChar:function($){var Q="";for(var J=0;J<$.length;J++)Q+=String.fromCharCode($[J]);return Q},applyCanBeUsed:{uint8array:function(){try{return r2.uint8array&&String.fromCharCode.apply(null,new Uint8Array(1)).length===1}catch($){return!1}}(),nodebuffer:function(){try{return r2.nodebuffer&&String.fromCharCode.apply(null,u1.allocBuffer(1)).length===1}catch($){return!1}}()}};function g6($){var Q=65536,J=TX.getTypeOf($),q=!0;if(J==="uint8array")q=O8.applyCanBeUsed.uint8array;else if(J==="nodebuffer")q=O8.applyCanBeUsed.nodebuffer;if(q)while(Q>1)try{return O8.stringifyByChunk($,J,Q)}catch(X){Q=Math.floor(Q/2)}return O8.stringifyByChar($)}TX.applyFromCharCode=g6;function A8($,Q){for(var J=0;J<$.length;J++)Q[J]=$[J];return Q}var a2={};a2.string={string:Z6,array:function($){return N8($,Array($.length))},arraybuffer:function($){return a2.string.uint8array($).buffer},uint8array:function($){return N8($,new Uint8Array($.length))},nodebuffer:function($){return N8($,u1.allocBuffer($.length))}};a2.array={string:g6,array:Z6,arraybuffer:function($){return new Uint8Array($).buffer},uint8array:function($){return new Uint8Array($)},nodebuffer:function($){return u1.newBufferFrom($)}};a2.arraybuffer={string:function($){return g6(new Uint8Array($))},array:function($){return A8(new Uint8Array($),Array($.byteLength))},arraybuffer:Z6,uint8array:function($){return new Uint8Array($)},nodebuffer:function($){return u1.newBufferFrom(new Uint8Array($))}};a2.uint8array={string:g6,array:function($){return A8($,Array($.length))},arraybuffer:function($){return $.buffer},uint8array:Z6,nodebuffer:function($){return u1.newBufferFrom($)}};a2.nodebuffer={string:g6,array:function($){return A8($,Array($.length))},arraybuffer:function($){return a2.nodebuffer.uint8array($).buffer},uint8array:function($){return A8($,new Uint8Array($.length))},nodebuffer:Z6};TX.transformTo=function($,Q){if(!Q)Q="";if(!$)return Q;TX.checkSupport($);var J=TX.getTypeOf(Q),q=a2[J][$](Q);return q};TX.resolve=function($){var Q=$.split("/"),J=[];for(var q=0;q<Q.length;q++){var X=Q[q];if(X==="."||X===""&&q!==0&&q!==Q.length-1)continue;else if(X==="..")J.pop();else J.push(X)}return J.join("/")};TX.getTypeOf=function($){if(typeof $==="string")return"string";if(Object.prototype.toString.call($)==="[object Array]")return"array";if(r2.nodebuffer&&u1.isBuffer($))return"nodebuffer";if(r2.uint8array&&$ instanceof Uint8Array)return"uint8array";if(r2.arraybuffer&&$ instanceof ArrayBuffer)return"arraybuffer"};TX.checkSupport=function($){var Q=r2[$.toLowerCase()];if(!Q)throw Error($+" is not supported by this platform")};TX.MAX_VALUE_16BITS=65535;TX.MAX_VALUE_32BITS=-1;TX.pretty=function($){var Q="",J,q;for(q=0;q<($||"").length;q++)J=$.charCodeAt(q),Q+="\\x"+(J<16?"0":"")+J.toString(16).toUpperCase();return Q};TX.delay=function($,Q,J){setImmediate(function(){$.apply(J||null,Q||[])})};TX.inherits=function($,Q){var J=function(){};J.prototype=Q.prototype,$.prototype=new J};TX.extend=function(){var $={},Q,J;for(Q=0;Q<arguments.length;Q++)for(J in arguments[Q])if(Object.prototype.hasOwnProperty.call(arguments[Q],J)&&typeof $[J]>"u")$[J]=arguments[Q][J];return $};TX.prepareContent=function($,Q,J,q,X){var Y=T5.Promise.resolve(Q).then(function(G){var B=r2.blob&&(G instanceof Blob||["[object File]","[object Blob]"].indexOf(Object.prototype.toString.call(G))!==-1);if(B&&typeof FileReader<"u")return new T5.Promise(function(W,U){var V=new FileReader;V.onload=function(L){W(L.target.result)},V.onerror=function(L){U(L.target.error)},V.readAsArrayBuffer(G)});else return G});return Y.then(function(G){var B=TX.getTypeOf(G);if(!B)return T5.Promise.reject(Error("Can't read the data of '"+$+"'. Is it in a supported JavaScript type (String, Blob, ArrayBuffer, etc) ?"));if(B==="arraybuffer")G=TX.transformTo("uint8array",G);else if(B==="string"){if(X)G=vX.decode(G);else if(J){if(q!==!0)G=kX(G)}}return G})}});var t0=j0((GK,z$)=>{function L$($){this.name=$||"default",this.streamInfo={},this.generatedError=null,this.extraStreamInfo={},this.isPaused=!0,this.isFinished=!1,this.isLocked=!1,this._listeners={data:[],end:[],error:[]},this.previous=null}L$.prototype={push:function($){this.emit("data",$)},end:function(){if(this.isFinished)return!1;this.flush();try{this.emit("end"),this.cleanUp(),this.isFinished=!0}catch($){this.emit("error",$)}return!0},error:function($){if(this.isFinished)return!1;if(this.isPaused)this.generatedError=$;else{if(this.isFinished=!0,this.emit("error",$),this.previous)this.previous.error($);this.cleanUp()}return!0},on:function($,Q){return this._listeners[$].push(Q),this},cleanUp:function(){this.streamInfo=this.generatedError=this.extraStreamInfo=null,this._listeners=[]},emit:function($,Q){if(this._listeners[$])for(var J=0;J<this._listeners[$].length;J++)this._listeners[$][J].call(this,Q)},pipe:function($){return $.registerPrevious(this)},registerPrevious:function($){if(this.isLocked)throw Error("The stream '"+this+"' has already been used.");this.streamInfo=$.streamInfo,this.mergeStreamInfo(),this.previous=$;var Q=this;return $.on("data",function(J){Q.processChunk(J)}),$.on("end",function(){Q.end()}),$.on("error",function(J){Q.error(J)}),this},pause:function(){if(this.isPaused||this.isFinished)return!1;if(this.isPaused=!0,this.previous)this.previous.pause();return!0},resume:function(){if(!this.isPaused||this.isFinished)return!1;this.isPaused=!1;var $=!1;if(this.generatedError)this.error(this.generatedError),$=!0;if(this.previous)this.previous.resume();return!$},flush:function(){},processChunk:function($){this.push($)},withStreamInfo:function($,Q){return this.extraStreamInfo[$]=Q,this.mergeStreamInfo(),this},mergeStreamInfo:function(){for(var $ in this.extraStreamInfo){if(!Object.prototype.hasOwnProperty.call(this.extraStreamInfo,$))continue;this.streamInfo[$]=this.extraStreamInfo[$]}},lock:function(){if(this.isLocked)throw Error("The stream '"+this+"' has already been used.");if(this.isLocked=!0,this.previous)this.previous.lock()},toString:function(){var $="Worker "+this.name;if(this.previous)return this.previous+" -> "+$;else return $}};z$.exports=L$});var p1=j0((iX)=>{var c1=g0(),z1=_2(),cX=E6(),D8=t0(),x6=Array(256);for(A2=0;A2<256;A2++)x6[A2]=A2>=252?6:A2>=248?5:A2>=240?4:A2>=224?3:A2>=192?2:1;var A2;x6[254]=x6[254]=1;var pX=function($){var Q,J,q,X,Y,G=$.length,B=0;for(X=0;X<G;X++){if(J=$.charCodeAt(X),(J&64512)===55296&&X+1<G){if(q=$.charCodeAt(X+1),(q&64512)===56320)J=65536+(J-55296<<10)+(q-56320),X++}B+=J<128?1:J<2048?2:J<65536?3:4}if(z1.uint8array)Q=new Uint8Array(B);else Q=Array(B);for(Y=0,X=0;Y<B;X++){if(J=$.charCodeAt(X),(J&64512)===55296&&X+1<G){if(q=$.charCodeAt(X+1),(q&64512)===56320)J=65536+(J-55296<<10)+(q-56320),X++}if(J<128)Q[Y++]=J;else if(J<2048)Q[Y++]=192|J>>>6,Q[Y++]=128|J&63;else if(J<65536)Q[Y++]=224|J>>>12,Q[Y++]=128|J>>>6&63,Q[Y++]=128|J&63;else Q[Y++]=240|J>>>18,Q[Y++]=128|J>>>12&63,Q[Y++]=128|J>>>6&63,Q[Y++]=128|J&63}return Q},lX=function($,Q){var J;if(Q=Q||$.length,Q>$.length)Q=$.length;J=Q-1;while(J>=0&&($[J]&192)===128)J--;if(J<0)return Q;if(J===0)return Q;return J+x6[$[J]]>Q?J:Q},dX=function($){var Q,J,q,X,Y=$.length,G=Array(Y*2);for(J=0,Q=0;Q<Y;){if(q=$[Q++],q<128){G[J++]=q;continue}if(X=x6[q],X>4){G[J++]=65533,Q+=X-1;continue}q&=X===2?31:X===3?15:7;while(X>1&&Q<Y)q=q<<6|$[Q++]&63,X--;if(X>1){G[J++]=65533;continue}if(q<65536)G[J++]=q;else q-=65536,G[J++]=55296|q>>10&1023,G[J++]=56320|q&1023}if(G.length!==J)if(G.subarray)G=G.subarray(0,J);else G.length=J;return c1.applyFromCharCode(G)};iX.utf8encode=function(Q){if(z1.nodebuffer)return cX.newBufferFrom(Q,"utf-8");return pX(Q)};iX.utf8decode=function(Q){if(z1.nodebuffer)return c1.transformTo("nodebuffer",Q).toString("utf-8");return Q=c1.transformTo(z1.uint8array?"uint8array":"array",Q),dX(Q)};function P8(){D8.call(this,"utf-8 decode"),this.leftOver=null}c1.inherits(P8,D8);P8.prototype.processChunk=function($){var Q=c1.transformTo(z1.uint8array?"uint8array":"array",$.data);if(this.leftOver&&this.leftOver.length){if(z1.uint8array){var J=Q;Q=new Uint8Array(J.length+this.leftOver.length),Q.set(this.leftOver,0),Q.set(J,this.leftOver.length)}else Q=this.leftOver.concat(Q);this.leftOver=null}var q=lX(Q),X=Q;if(q!==Q.length)if(z1.uint8array)X=Q.subarray(0,q),this.leftOver=Q.subarray(q,Q.length);else X=Q.slice(0,q),this.leftOver=Q.slice(q,Q.length);this.push({data:iX.utf8decode(X),meta:$.meta})};P8.prototype.flush=function(){if(this.leftOver&&this.leftOver.length)this.push({data:iX.utf8decode(this.leftOver),meta:{}}),this.leftOver=null};iX.Utf8DecodeWorker=P8;function g5(){D8.call(this,"utf-8 encode")}c1.inherits(g5,D8);g5.prototype.processChunk=function($){this.push({data:iX.utf8encode($.data),meta:$.meta})};iX.Utf8EncodeWorker=g5});var P$=j0((UK,D$)=>{var N$=t0(),A$=g0();function f5($){N$.call(this,"ConvertWorker to "+$),this.destType=$}A$.inherits(f5,N$);f5.prototype.processChunk=function($){this.push({data:A$.transformTo(this.destType,$.data),meta:$.meta})};D$.exports=f5});var I$=j0((WK,C$)=>{var R$=H8().Readable,rX=g0();rX.inherits(y5,R$);function y5($,Q,J){R$.call(this,Q),this._helper=$;var q=this;$.on("data",function(X,Y){if(!q.push(X))q._helper.pause();if(J)J(Y)}).on("error",function(X){q.emit("error",X)}).on("end",function(){q.push(null)})}y5.prototype._read=function(){this._helper.resume()};C$.exports=y5});var _5=j0((VK,v$)=>{var O1=g0(),aX=P$(),sX=t0(),tX=C5(),eX=_2(),$Y=m1(),S$=null;if(eX.nodestream)try{S$=I$()}catch($){}function QY($,Q,J){switch($){case"blob":return O1.newBlob(O1.transformTo("arraybuffer",Q),J);case"base64":return tX.encode(Q);default:return O1.transformTo($,Q)}}function JY($,Q){var J,q=0,X=null,Y=0;for(J=0;J<Q.length;J++)Y+=Q[J].length;switch($){case"string":return Q.join("");case"array":return Array.prototype.concat.apply([],Q);case"uint8array":X=new Uint8Array(Y);for(J=0;J<Q.length;J++)X.set(Q[J],q),q+=Q[J].length;return X;case"nodebuffer":return Buffer.concat(Q);default:throw Error("concat : unsupported type '"+$+"'")}}function qY($,Q){return new $Y.Promise(function(J,q){var X=[],Y=$._internalType,G=$._outputType,B=$._mimeType;$.on("data",function(W,U){if(X.push(W),Q)Q(U)}).on("error",function(W){X=[],q(W)}).on("end",function(){try{var W=QY(G,JY(Y,X),B);J(W)}catch(U){q(U)}X=[]}).resume()})}function E$($,Q,J){var q=Q;switch(Q){case"blob":case"arraybuffer":q="uint8array";break;case"base64":q="string";break}try{this._internalType=q,this._outputType=Q,this._mimeType=J,O1.checkSupport(q),this._worker=$.pipe(new aX(q)),$.lock()}catch(X){this._worker=new sX("error"),this._worker.error(X)}}E$.prototype={accumulate:function($){return qY(this,$)},on:function($,Q){var J=this;if($==="data")this._worker.on($,function(q){Q.call(J,q.data,q.meta)});else this._worker.on($,function(){O1.delay(Q,arguments,J)});return this},resume:function(){return O1.delay(this._worker.resume,[],this._worker),this},pause:function(){return this._worker.pause(),this},toNodejsStream:function($){if(O1.checkSupport("nodestream"),this._outputType!=="nodebuffer")throw Error(this._outputType+" is not supported by this method");return new S$(this,{objectMode:this._outputType!=="nodebuffer"},$)}};v$.exports=E$});var b5=j0((XY)=>{XY.base64=!1;XY.binary=!1;XY.dir=!1;XY.createFolders=!0;XY.date=null;XY.compression=null;XY.compressionOptions=null;XY.comment=null;XY.unixPermissions=null;XY.dosPermissions=null});var h5=j0((HK,k$)=>{var R8=g0(),C8=t0(),wY=16384;function l1($){C8.call(this,"DataWorker");var Q=this;this.dataIsReady=!1,this.index=0,this.max=0,this.data=null,this.type="",this._tickScheduled=!1,$.then(function(J){if(Q.dataIsReady=!0,Q.data=J,Q.max=J&&J.length||0,Q.type=R8.getTypeOf(J),!Q.isPaused)Q._tickAndRepeat()},function(J){Q.error(J)})}R8.inherits(l1,C8);l1.prototype.cleanUp=function(){C8.prototype.cleanUp.call(this),this.data=null};l1.prototype.resume=function(){if(!C8.prototype.resume.call(this))return!1;if(!this._tickScheduled&&this.dataIsReady)this._tickScheduled=!0,R8.delay(this._tickAndRepeat,[],this);return!0};l1.prototype._tickAndRepeat=function(){if(this._tickScheduled=!1,this.isPaused||this.isFinished)return;if(this._tick(),!this.isFinished)R8.delay(this._tickAndRepeat,[],this),this._tickScheduled=!0};l1.prototype._tick=function(){if(this.isPaused||this.isFinished)return!1;var $=wY,Q=null,J=Math.min(this.max,this.index+$);if(this.index>=this.max)return this.end();else{switch(this.type){case"string":Q=this.data.substring(this.index,J);break;case"uint8array":Q=this.data.subarray(this.index,J);break;case"array":case"nodebuffer":Q=this.data.slice(this.index,J);break}return this.index=J,this.push({data:Q,meta:{percent:this.max?this.index/this.max*100:0}})}};k$.exports=l1});var I8=j0((jK,Z$)=>{var FY=g0();function LY(){var $,Q=[];for(var J=0;J<256;J++){$=J;for(var q=0;q<8;q++)$=$&1?3988292384^$>>>1:$>>>1;Q[J]=$}return Q}var T$=LY();function zY($,Q,J,q){var X=T$,Y=q+J;$=$^-1;for(var G=q;G<Y;G++)$=$>>>8^X[($^Q[G])&255];return $^-1}function OY($,Q,J,q){var X=T$,Y=q+J;$=$^-1;for(var G=q;G<Y;G++)$=$>>>8^X[($^Q.charCodeAt(G))&255];return $^-1}Z$.exports=function(Q,J){if(typeof Q>"u"||!Q.length)return 0;var q=FY.getTypeOf(Q)!=="string";if(q)return zY(J|0,Q,Q.length,0);else return OY(J|0,Q,Q.length,0)}});var u5=j0((MK,x$)=>{var g$=t0(),NY=I8(),AY=g0();function m5(){g$.call(this,"Crc32Probe"),this.withStreamInfo("crc32",0)}AY.inherits(m5,g$);m5.prototype.processChunk=function($){this.streamInfo.crc32=NY($.data,this.streamInfo.crc32||0),this.push($)};x$.exports=m5});var y$=j0((wK,f$)=>{var DY=g0(),c5=t0();function p5($){c5.call(this,"DataLengthProbe for "+$),this.propName=$,this.withStreamInfo($,0)}DY.inherits(p5,c5);p5.prototype.processChunk=function($){if($){var Q=this.streamInfo[this.propName]||0;this.streamInfo[this.propName]=Q+$.data.length}c5.prototype.processChunk.call(this,$)};f$.exports=p5});var S8=j0((FK,h$)=>{var _$=m1(),b$=h5(),PY=u5(),l5=y$();function d5($,Q,J,q,X){this.compressedSize=$,this.uncompressedSize=Q,this.crc32=J,this.compression=q,this.compressedContent=X}d5.prototype={getContentWorker:function(){var $=new b$(_$.Promise.resolve(this.compressedContent)).pipe(this.compression.uncompressWorker()).pipe(new l5("data_length")),Q=this;return $.on("end",function(){if(this.streamInfo.data_length!==Q.uncompressedSize)throw Error("Bug : uncompressed data size mismatch")}),$},getCompressedWorker:function(){return new b$(_$.Promise.resolve(this.compressedContent)).withStreamInfo("compressedSize",this.compressedSize).withStreamInfo("uncompressedSize",this.uncompressedSize).withStreamInfo("crc32",this.crc32).withStreamInfo("compression",this.compression)}};d5.createWorkerFrom=function($,Q,J){return $.pipe(new PY).pipe(new l5("uncompressedSize")).pipe(Q.compressWorker(J)).pipe(new l5("compressedSize")).withStreamInfo("compression",Q)};h$.exports=d5});var p$=j0((LK,c$)=>{var RY=_5(),CY=h5(),i5=p1(),n5=S8(),m$=t0(),o5=function($,Q,J){this.name=$,this.dir=J.dir,this.date=J.date,this.comment=J.comment,this.unixPermissions=J.unixPermissions,this.dosPermissions=J.dosPermissions,this._data=Q,this._dataBinary=J.binary,this.options={compression:J.compression,compressionOptions:J.compressionOptions}};o5.prototype={internalStream:function($){var Q=null,J="string";try{if(!$)throw Error("No output type specified.");J=$.toLowerCase();var q=J==="string"||J==="text";if(J==="binarystring"||J==="text")J="string";Q=this._decompressWorker();var X=!this._dataBinary;if(X&&!q)Q=Q.pipe(new i5.Utf8EncodeWorker);if(!X&&q)Q=Q.pipe(new i5.Utf8DecodeWorker)}catch(Y){Q=new m$("error"),Q.error(Y)}return new RY(Q,J,"")},async:function($,Q){return this.internalStream($).accumulate(Q)},nodeStream:function($,Q){return this.internalStream($||"nodebuffer").toNodejsStream(Q)},_compressWorker:function($,Q){if(this._data instanceof n5&&this._data.compression.magic===$.magic)return this._data.getCompressedWorker();else{var J=this._decompressWorker();if(!this._dataBinary)J=J.pipe(new i5.Utf8EncodeWorker);return n5.createWorkerFrom(J,$,Q)}},_decompressWorker:function(){if(this._data instanceof n5)return this._data.getContentWorker();else if(this._data instanceof m$)return this._data;else return new CY(this._data)}};var u$=["asText","asBinary","asNodeBuffer","asUint8Array","asArrayBuffer"],IY=function(){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")};for(f6=0;f6<u$.length;f6++)o5.prototype[u$[f6]]=IY;var f6;c$.exports=o5});var b2=j0((r5)=>{var kY=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";function TY($,Q){return Object.prototype.hasOwnProperty.call($,Q)}r5.assign=function($){var Q=Array.prototype.slice.call(arguments,1);while(Q.length){var J=Q.shift();if(!J)continue;if(typeof J!=="object")throw TypeError(J+"must be non-object");for(var q in J)if(TY(J,q))$[q]=J[q]}return $};r5.shrinkBuf=function($,Q){if($.length===Q)return $;if($.subarray)return $.subarray(0,Q);return $.length=Q,$};var ZY={arraySet:function($,Q,J,q,X){if(Q.subarray&&$.subarray){$.set(Q.subarray(J,J+q),X);return}for(var Y=0;Y<q;Y++)$[X+Y]=Q[J+Y]},flattenChunks:function($){var Q,J,q,X,Y,G;q=0;for(Q=0,J=$.length;Q<J;Q++)q+=$[Q].length;G=new Uint8Array(q),X=0;for(Q=0,J=$.length;Q<J;Q++)Y=$[Q],G.set(Y,X),X+=Y.length;return G}},gY={arraySet:function($,Q,J,q,X){for(var Y=0;Y<q;Y++)$[X+Y]=Q[J+Y]},flattenChunks:function($){return[].concat.apply([],$)}};r5.setTyped=function($){if($)r5.Buf8=Uint8Array,r5.Buf16=Uint16Array,r5.Buf32=Int32Array,r5.assign(r5,ZY);else r5.Buf8=Array,r5.Buf16=Array,r5.Buf32=Array,r5.assign(r5,gY)};r5.setTyped(kY)});var j9=j0((JG)=>{var fY=b2(),yY=4,d$=0,i$=1,_Y=2;function i1($){var Q=$.length;while(--Q>=0)$[Q]=0}var bY=0,t$=1,hY=2,mY=3,uY=258,q4=29,u6=256,_6=u6+1+q4,d1=30,X4=19,e$=2*_6+1,N1=15,s5=16,cY=7,Y4=256,$9=16,Q9=17,J9=18,Q4=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],E8=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],pY=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],q9=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],lY=512,h2=Array((_6+2)*2);i1(h2);var y6=Array(d1*2);i1(y6);var b6=Array(lY);i1(b6);var h6=Array(uY-mY+1);i1(h6);var G4=Array(q4);i1(G4);var v8=Array(d1);i1(v8);function t5($,Q,J,q,X){this.static_tree=$,this.extra_bits=Q,this.extra_base=J,this.elems=q,this.max_length=X,this.has_stree=$&&$.length}var X9,Y9,G9;function e5($,Q){this.dyn_tree=$,this.max_code=0,this.stat_desc=Q}function B9($){return $<256?b6[$]:b6[256+($>>>7)]}function m6($,Q){$.pending_buf[$.pending++]=Q&255,$.pending_buf[$.pending++]=Q>>>8&255}function a0($,Q,J){if($.bi_valid>s5-J)$.bi_buf|=Q<<$.bi_valid&65535,m6($,$.bi_buf),$.bi_buf=Q>>s5-$.bi_valid,$.bi_valid+=J-s5;else $.bi_buf|=Q<<$.bi_valid&65535,$.bi_valid+=J}function D2($,Q,J){a0($,J[Q*2],J[Q*2+1])}function U9($,Q){var J=0;do J|=$&1,$>>>=1,J<<=1;while(--Q>0);return J>>>1}function dY($){if($.bi_valid===16)m6($,$.bi_buf),$.bi_buf=0,$.bi_valid=0;else if($.bi_valid>=8)$.pending_buf[$.pending++]=$.bi_buf&255,$.bi_buf>>=8,$.bi_valid-=8}function iY($,Q){var{dyn_tree:J,max_code:q}=Q,X=Q.stat_desc.static_tree,Y=Q.stat_desc.has_stree,G=Q.stat_desc.extra_bits,B=Q.stat_desc.extra_base,W=Q.stat_desc.max_length,U,V,L,w,M,y,x=0;for(w=0;w<=N1;w++)$.bl_count[w]=0;J[$.heap[$.heap_max]*2+1]=0;for(U=$.heap_max+1;U<e$;U++){if(V=$.heap[U],w=J[J[V*2+1]*2+1]+1,w>W)w=W,x++;if(J[V*2+1]=w,V>q)continue;if($.bl_count[w]++,M=0,V>=B)M=G[V-B];if(y=J[V*2],$.opt_len+=y*(w+M),Y)$.static_len+=y*(X[V*2+1]+M)}if(x===0)return;do{w=W-1;while($.bl_count[w]===0)w--;$.bl_count[w]--,$.bl_count[w+1]+=2,$.bl_count[W]--,x-=2}while(x>0);for(w=W;w!==0;w--){V=$.bl_count[w];while(V!==0){if(L=$.heap[--U],L>q)continue;if(J[L*2+1]!==w)$.opt_len+=(w-J[L*2+1])*J[L*2],J[L*2+1]=w;V--}}}function W9($,Q,J){var q=Array(N1+1),X=0,Y,G;for(Y=1;Y<=N1;Y++)q[Y]=X=X+J[Y-1]<<1;for(G=0;G<=Q;G++){var B=$[G*2+1];if(B===0)continue;$[G*2]=U9(q[B]++,B)}}function nY(){var $,Q,J,q,X,Y=Array(N1+1);J=0;for(q=0;q<q4-1;q++){G4[q]=J;for($=0;$<1<<Q4[q];$++)h6[J++]=q}h6[J-1]=q,X=0;for(q=0;q<16;q++){v8[q]=X;for($=0;$<1<<E8[q];$++)b6[X++]=q}X>>=7;for(;q<d1;q++){v8[q]=X<<7;for($=0;$<1<<E8[q]-7;$++)b6[256+X++]=q}for(Q=0;Q<=N1;Q++)Y[Q]=0;$=0;while($<=143)h2[$*2+1]=8,$++,Y[8]++;while($<=255)h2[$*2+1]=9,$++,Y[9]++;while($<=279)h2[$*2+1]=7,$++,Y[7]++;while($<=287)h2[$*2+1]=8,$++,Y[8]++;W9(h2,_6+1,Y);for($=0;$<d1;$++)y6[$*2+1]=5,y6[$*2]=U9($,5);X9=new t5(h2,Q4,u6+1,_6,N1),Y9=new t5(y6,E8,0,d1,N1),G9=new t5([],pY,0,X4,cY)}function V9($){var Q;for(Q=0;Q<_6;Q++)$.dyn_ltree[Q*2]=0;for(Q=0;Q<d1;Q++)$.dyn_dtree[Q*2]=0;for(Q=0;Q<X4;Q++)$.bl_tree[Q*2]=0;$.dyn_ltree[Y4*2]=1,$.opt_len=$.static_len=0,$.last_lit=$.matches=0}function K9($){if($.bi_valid>8)m6($,$.bi_buf);else if($.bi_valid>0)$.pending_buf[$.pending++]=$.bi_buf;$.bi_buf=0,$.bi_valid=0}function oY($,Q,J,q){if(K9($),q)m6($,J),m6($,~J);fY.arraySet($.pending_buf,$.window,Q,J,$.pending),$.pending+=J}function n$($,Q,J,q){var X=Q*2,Y=J*2;return $[X]<$[Y]||$[X]===$[Y]&&q[Q]<=q[J]}function $4($,Q,J){var q=$.heap[J],X=J<<1;while(X<=$.heap_len){if(X<$.heap_len&&n$(Q,$.heap[X+1],$.heap[X],$.depth))X++;if(n$(Q,q,$.heap[X],$.depth))break;$.heap[J]=$.heap[X],J=X,X<<=1}$.heap[J]=q}function o$($,Q,J){var q,X,Y=0,G,B;if($.last_lit!==0)do if(q=$.pending_buf[$.d_buf+Y*2]<<8|$.pending_buf[$.d_buf+Y*2+1],X=$.pending_buf[$.l_buf+Y],Y++,q===0)D2($,X,Q);else{if(G=h6[X],D2($,G+u6+1,Q),B=Q4[G],B!==0)X-=G4[G],a0($,X,B);if(q--,G=B9(q),D2($,G,J),B=E8[G],B!==0)q-=v8[G],a0($,q,B)}while(Y<$.last_lit);D2($,Y4,Q)}function J4($,Q){var J=Q.dyn_tree,q=Q.stat_desc.static_tree,X=Q.stat_desc.has_stree,Y=Q.stat_desc.elems,G,B,W=-1,U;$.heap_len=0,$.heap_max=e$;for(G=0;G<Y;G++)if(J[G*2]!==0)$.heap[++$.heap_len]=W=G,$.depth[G]=0;else J[G*2+1]=0;while($.heap_len<2)if(U=$.heap[++$.heap_len]=W<2?++W:0,J[U*2]=1,$.depth[U]=0,$.opt_len--,X)$.static_len-=q[U*2+1];Q.max_code=W;for(G=$.heap_len>>1;G>=1;G--)$4($,J,G);U=Y;do G=$.heap[1],$.heap[1]=$.heap[$.heap_len--],$4($,J,1),B=$.heap[1],$.heap[--$.heap_max]=G,$.heap[--$.heap_max]=B,J[U*2]=J[G*2]+J[B*2],$.depth[U]=($.depth[G]>=$.depth[B]?$.depth[G]:$.depth[B])+1,J[G*2+1]=J[B*2+1]=U,$.heap[1]=U++,$4($,J,1);while($.heap_len>=2);$.heap[--$.heap_max]=$.heap[1],iY($,Q),W9(J,W,$.bl_count)}function r$($,Q,J){var q,X=-1,Y,G=Q[1],B=0,W=7,U=4;if(G===0)W=138,U=3;Q[(J+1)*2+1]=65535;for(q=0;q<=J;q++){if(Y=G,G=Q[(q+1)*2+1],++B<W&&Y===G)continue;else if(B<U)$.bl_tree[Y*2]+=B;else if(Y!==0){if(Y!==X)$.bl_tree[Y*2]++;$.bl_tree[$9*2]++}else if(B<=10)$.bl_tree[Q9*2]++;else $.bl_tree[J9*2]++;if(B=0,X=Y,G===0)W=138,U=3;else if(Y===G)W=6,U=3;else W=7,U=4}}function a$($,Q,J){var q,X=-1,Y,G=Q[1],B=0,W=7,U=4;if(G===0)W=138,U=3;for(q=0;q<=J;q++){if(Y=G,G=Q[(q+1)*2+1],++B<W&&Y===G)continue;else if(B<U)do D2($,Y,$.bl_tree);while(--B!==0);else if(Y!==0){if(Y!==X)D2($,Y,$.bl_tree),B--;D2($,$9,$.bl_tree),a0($,B-3,2)}else if(B<=10)D2($,Q9,$.bl_tree),a0($,B-3,3);else D2($,J9,$.bl_tree),a0($,B-11,7);if(B=0,X=Y,G===0)W=138,U=3;else if(Y===G)W=6,U=3;else W=7,U=4}}function rY($){var Q;r$($,$.dyn_ltree,$.l_desc.max_code),r$($,$.dyn_dtree,$.d_desc.max_code),J4($,$.bl_desc);for(Q=X4-1;Q>=3;Q--)if($.bl_tree[q9[Q]*2+1]!==0)break;return $.opt_len+=3*(Q+1)+5+5+4,Q}function aY($,Q,J,q){var X;a0($,Q-257,5),a0($,J-1,5),a0($,q-4,4);for(X=0;X<q;X++)a0($,$.bl_tree[q9[X]*2+1],3);a$($,$.dyn_ltree,Q-1),a$($,$.dyn_dtree,J-1)}function sY($){var Q=4093624447,J;for(J=0;J<=31;J++,Q>>>=1)if(Q&1&&$.dyn_ltree[J*2]!==0)return d$;if($.dyn_ltree[18]!==0||$.dyn_ltree[20]!==0||$.dyn_ltree[26]!==0)return i$;for(J=32;J<u6;J++)if($.dyn_ltree[J*2]!==0)return i$;return d$}var s$=!1;function tY($){if(!s$)nY(),s$=!0;$.l_desc=new e5($.dyn_ltree,X9),$.d_desc=new e5($.dyn_dtree,Y9),$.bl_desc=new e5($.bl_tree,G9),$.bi_buf=0,$.bi_valid=0,V9($)}function H9($,Q,J,q){a0($,(bY<<1)+(q?1:0),3),oY($,Q,J,!0)}function eY($){a0($,t$<<1,3),D2($,Y4,h2),dY($)}function $G($,Q,J,q){var X,Y,G=0;if($.level>0){if($.strm.data_type===_Y)$.strm.data_type=sY($);if(J4($,$.l_desc),J4($,$.d_desc),G=rY($),X=$.opt_len+3+7>>>3,Y=$.static_len+3+7>>>3,Y<=X)X=Y}else X=Y=J+5;if(J+4<=X&&Q!==-1)H9($,Q,J,q);else if($.strategy===yY||Y===X)a0($,(t$<<1)+(q?1:0),3),o$($,h2,y6);else a0($,(hY<<1)+(q?1:0),3),aY($,$.l_desc.max_code+1,$.d_desc.max_code+1,G+1),o$($,$.dyn_ltree,$.dyn_dtree);if(V9($),q)K9($)}function QG($,Q,J){if($.pending_buf[$.d_buf+$.last_lit*2]=Q>>>8&255,$.pending_buf[$.d_buf+$.last_lit*2+1]=Q&255,$.pending_buf[$.l_buf+$.last_lit]=J&255,$.last_lit++,Q===0)$.dyn_ltree[J*2]++;else $.matches++,Q--,$.dyn_ltree[(h6[J]+u6+1)*2]++,$.dyn_dtree[B9(Q)*2]++;return $.last_lit===$.lit_bufsize-1}JG._tr_init=tY;JG._tr_stored_block=H9;JG._tr_flush_block=$G;JG._tr_tally=QG;JG._tr_align=eY});var B4=j0((NK,M9)=>{function UG($,Q,J,q){var X=$&65535|0,Y=$>>>16&65535|0,G=0;while(J!==0){G=J>2000?2000:J,J-=G;do X=X+Q[q++]|0,Y=Y+X|0;while(--G);X%=65521,Y%=65521}return X|Y<<16|0}M9.exports=UG});var U4=j0((AK,w9)=>{function WG(){var $,Q=[];for(var J=0;J<256;J++){$=J;for(var q=0;q<8;q++)$=$&1?3988292384^$>>>1:$>>>1;Q[J]=$}return Q}var VG=WG();function KG($,Q,J,q){var X=VG,Y=q+J;$^=-1;for(var G=q;G<Y;G++)$=$>>>8^X[($^Q[G])&255];return $^-1}w9.exports=KG});var k8=j0((DK,F9)=>{F9.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}});var C9=j0((lG)=>{var i0=b2(),Y2=j9(),N9=B4(),s2=U4(),HG=k8(),R1=0,jG=1,MG=3,J1=4,L9=5,R2=0,z9=1,G2=-2,wG=-3,W4=-5,FG=-1,LG=1,T8=2,zG=3,OG=4,NG=0,AG=2,f8=8,DG=9,PG=15,RG=8,CG=29,IG=256,K4=IG+1+CG,SG=30,EG=19,vG=2*K4+1,kG=15,C0=3,$1=258,W2=$1+C0+1,TG=32,y8=42,H4=69,Z8=73,g8=91,x8=103,A1=113,p6=666,y0=1,l6=2,D1=3,r1=4,ZG=3;function Q1($,Q){return $.msg=HG[Q],Q}function O9($){return($<<1)-($>4?9:0)}function e2($){var Q=$.length;while(--Q>=0)$[Q]=0}function t2($){var Q=$.state,J=Q.pending;if(J>$.avail_out)J=$.avail_out;if(J===0)return;if(i0.arraySet($.output,Q.pending_buf,Q.pending_out,J,$.next_out),$.next_out+=J,Q.pending_out+=J,$.total_out+=J,$.avail_out-=J,Q.pending-=J,Q.pending===0)Q.pending_out=0}function b0($,Q){Y2._tr_flush_block($,$.block_start>=0?$.block_start:-1,$.strstart-$.block_start,Q),$.block_start=$.strstart,t2($.strm)}function I0($,Q){$.pending_buf[$.pending++]=Q}function c6($,Q){$.pending_buf[$.pending++]=Q>>>8&255,$.pending_buf[$.pending++]=Q&255}function gG($,Q,J,q){var X=$.avail_in;if(X>q)X=q;if(X===0)return 0;if($.avail_in-=X,i0.arraySet(Q,$.input,$.next_in,X,J),$.state.wrap===1)$.adler=N9($.adler,Q,X,J);else if($.state.wrap===2)$.adler=s2($.adler,Q,X,J);return $.next_in+=X,$.total_in+=X,X}function A9($,Q){var{max_chain_length:J,strstart:q}=$,X,Y,G=$.prev_length,B=$.nice_match,W=$.strstart>$.w_size-W2?$.strstart-($.w_size-W2):0,U=$.window,V=$.w_mask,L=$.prev,w=$.strstart+$1,M=U[q+G-1],y=U[q+G];if($.prev_length>=$.good_match)J>>=2;if(B>$.lookahead)B=$.lookahead;do{if(X=Q,U[X+G]!==y||U[X+G-1]!==M||U[X]!==U[q]||U[++X]!==U[q+1])continue;q+=2,X++;do;while(U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&U[++q]===U[++X]&&q<w);if(Y=$1-(w-q),q=w-$1,Y>G){if($.match_start=Q,G=Y,Y>=B)break;M=U[q+G-1],y=U[q+G]}}while((Q=L[Q&V])>W&&--J!==0);if(G<=$.lookahead)return G;return $.lookahead}function P1($){var Q=$.w_size,J,q,X,Y,G;do{if(Y=$.window_size-$.lookahead-$.strstart,$.strstart>=Q+(Q-W2)){i0.arraySet($.window,$.window,Q,Q,0),$.match_start-=Q,$.strstart-=Q,$.block_start-=Q,q=$.hash_size,J=q;do X=$.head[--J],$.head[J]=X>=Q?X-Q:0;while(--q);q=Q,J=q;do X=$.prev[--J],$.prev[J]=X>=Q?X-Q:0;while(--q);Y+=Q}if($.strm.avail_in===0)break;if(q=gG($.strm,$.window,$.strstart+$.lookahead,Y),$.lookahead+=q,$.lookahead+$.insert>=C0){G=$.strstart-$.insert,$.ins_h=$.window[G],$.ins_h=($.ins_h<<$.hash_shift^$.window[G+1])&$.hash_mask;while($.insert)if($.ins_h=($.ins_h<<$.hash_shift^$.window[G+C0-1])&$.hash_mask,$.prev[G&$.w_mask]=$.head[$.ins_h],$.head[$.ins_h]=G,G++,$.insert--,$.lookahead+$.insert<C0)break}}while($.lookahead<W2&&$.strm.avail_in!==0)}function xG($,Q){var J=65535;if(J>$.pending_buf_size-5)J=$.pending_buf_size-5;for(;;){if($.lookahead<=1){if(P1($),$.lookahead===0&&Q===R1)return y0;if($.lookahead===0)break}$.strstart+=$.lookahead,$.lookahead=0;var q=$.block_start+J;if($.strstart===0||$.strstart>=q){if($.lookahead=$.strstart-q,$.strstart=q,b0($,!1),$.strm.avail_out===0)return y0}if($.strstart-$.block_start>=$.w_size-W2){if(b0($,!1),$.strm.avail_out===0)return y0}}if($.insert=0,Q===J1){if(b0($,!0),$.strm.avail_out===0)return D1;return r1}if($.strstart>$.block_start){if(b0($,!1),$.strm.avail_out===0)return y0}return y0}function V4($,Q){var J,q;for(;;){if($.lookahead<W2){if(P1($),$.lookahead<W2&&Q===R1)return y0;if($.lookahead===0)break}if(J=0,$.lookahead>=C0)$.ins_h=($.ins_h<<$.hash_shift^$.window[$.strstart+C0-1])&$.hash_mask,J=$.prev[$.strstart&$.w_mask]=$.head[$.ins_h],$.head[$.ins_h]=$.strstart;if(J!==0&&$.strstart-J<=$.w_size-W2)$.match_length=A9($,J);if($.match_length>=C0)if(q=Y2._tr_tally($,$.strstart-$.match_start,$.match_length-C0),$.lookahead-=$.match_length,$.match_length<=$.max_lazy_match&&$.lookahead>=C0){$.match_length--;do $.strstart++,$.ins_h=($.ins_h<<$.hash_shift^$.window[$.strstart+C0-1])&$.hash_mask,J=$.prev[$.strstart&$.w_mask]=$.head[$.ins_h],$.head[$.ins_h]=$.strstart;while(--$.match_length!==0);$.strstart++}else $.strstart+=$.match_length,$.match_length=0,$.ins_h=$.window[$.strstart],$.ins_h=($.ins_h<<$.hash_shift^$.window[$.strstart+1])&$.hash_mask;else q=Y2._tr_tally($,0,$.window[$.strstart]),$.lookahead--,$.strstart++;if(q){if(b0($,!1),$.strm.avail_out===0)return y0}}if($.insert=$.strstart<C0-1?$.strstart:C0-1,Q===J1){if(b0($,!0),$.strm.avail_out===0)return D1;return r1}if($.last_lit){if(b0($,!1),$.strm.avail_out===0)return y0}return l6}function n1($,Q){var J,q,X;for(;;){if($.lookahead<W2){if(P1($),$.lookahead<W2&&Q===R1)return y0;if($.lookahead===0)break}if(J=0,$.lookahead>=C0)$.ins_h=($.ins_h<<$.hash_shift^$.window[$.strstart+C0-1])&$.hash_mask,J=$.prev[$.strstart&$.w_mask]=$.head[$.ins_h],$.head[$.ins_h]=$.strstart;if($.prev_length=$.match_length,$.prev_match=$.match_start,$.match_length=C0-1,J!==0&&$.prev_length<$.max_lazy_match&&$.strstart-J<=$.w_size-W2){if($.match_length=A9($,J),$.match_length<=5&&($.strategy===LG||$.match_length===C0&&$.strstart-$.match_start>4096))$.match_length=C0-1}if($.prev_length>=C0&&$.match_length<=$.prev_length){X=$.strstart+$.lookahead-C0,q=Y2._tr_tally($,$.strstart-1-$.prev_match,$.prev_length-C0),$.lookahead-=$.prev_length-1,$.prev_length-=2;do if(++$.strstart<=X)$.ins_h=($.ins_h<<$.hash_shift^$.window[$.strstart+C0-1])&$.hash_mask,J=$.prev[$.strstart&$.w_mask]=$.head[$.ins_h],$.head[$.ins_h]=$.strstart;while(--$.prev_length!==0);if($.match_available=0,$.match_length=C0-1,$.strstart++,q){if(b0($,!1),$.strm.avail_out===0)return y0}}else if($.match_available){if(q=Y2._tr_tally($,0,$.window[$.strstart-1]),q)b0($,!1);if($.strstart++,$.lookahead--,$.strm.avail_out===0)return y0}else $.match_available=1,$.strstart++,$.lookahead--}if($.match_available)q=Y2._tr_tally($,0,$.window[$.strstart-1]),$.match_available=0;if($.insert=$.strstart<C0-1?$.strstart:C0-1,Q===J1){if(b0($,!0),$.strm.avail_out===0)return D1;return r1}if($.last_lit){if(b0($,!1),$.strm.avail_out===0)return y0}return l6}function fG($,Q){var J,q,X,Y,G=$.window;for(;;){if($.lookahead<=$1){if(P1($),$.lookahead<=$1&&Q===R1)return y0;if($.lookahead===0)break}if($.match_length=0,$.lookahead>=C0&&$.strstart>0){if(X=$.strstart-1,q=G[X],q===G[++X]&&q===G[++X]&&q===G[++X]){Y=$.strstart+$1;do;while(q===G[++X]&&q===G[++X]&&q===G[++X]&&q===G[++X]&&q===G[++X]&&q===G[++X]&&q===G[++X]&&q===G[++X]&&X<Y);if($.match_length=$1-(Y-X),$.match_length>$.lookahead)$.match_length=$.lookahead}}if($.match_length>=C0)J=Y2._tr_tally($,1,$.match_length-C0),$.lookahead-=$.match_length,$.strstart+=$.match_length,$.match_length=0;else J=Y2._tr_tally($,0,$.window[$.strstart]),$.lookahead--,$.strstart++;if(J){if(b0($,!1),$.strm.avail_out===0)return y0}}if($.insert=0,Q===J1){if(b0($,!0),$.strm.avail_out===0)return D1;return r1}if($.last_lit){if(b0($,!1),$.strm.avail_out===0)return y0}return l6}function yG($,Q){var J;for(;;){if($.lookahead===0){if(P1($),$.lookahead===0){if(Q===R1)return y0;break}}if($.match_length=0,J=Y2._tr_tally($,0,$.window[$.strstart]),$.lookahead--,$.strstart++,J){if(b0($,!1),$.strm.avail_out===0)return y0}}if($.insert=0,Q===J1){if(b0($,!0),$.strm.avail_out===0)return D1;return r1}if($.last_lit){if(b0($,!1),$.strm.avail_out===0)return y0}return l6}function P2($,Q,J,q,X){this.good_length=$,this.max_lazy=Q,this.nice_length=J,this.max_chain=q,this.func=X}var o1;o1=[new P2(0,0,0,0,xG),new P2(4,4,8,4,V4),new P2(4,5,16,8,V4),new P2(4,6,32,32,V4),new P2(4,4,16,16,n1),new P2(8,16,32,32,n1),new P2(8,16,128,128,n1),new P2(8,32,128,256,n1),new P2(32,128,258,1024,n1),new P2(32,258,258,4096,n1)];function _G($){$.window_size=2*$.w_size,e2($.head),$.max_lazy_match=o1[$.level].max_lazy,$.good_match=o1[$.level].good_length,$.nice_match=o1[$.level].nice_length,$.max_chain_length=o1[$.level].max_chain,$.strstart=0,$.block_start=0,$.lookahead=0,$.insert=0,$.match_length=$.prev_length=C0-1,$.match_available=0,$.ins_h=0}function bG(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=f8,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new i0.Buf16(vG*2),this.dyn_dtree=new i0.Buf16((2*SG+1)*2),this.bl_tree=new i0.Buf16((2*EG+1)*2),e2(this.dyn_ltree),e2(this.dyn_dtree),e2(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new i0.Buf16(kG+1),this.heap=new i0.Buf16(2*K4+1),e2(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new i0.Buf16(2*K4+1),e2(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function D9($){var Q;if(!$||!$.state)return Q1($,G2);if($.total_in=$.total_out=0,$.data_type=AG,Q=$.state,Q.pending=0,Q.pending_out=0,Q.wrap<0)Q.wrap=-Q.wrap;return Q.status=Q.wrap?y8:A1,$.adler=Q.wrap===2?0:1,Q.last_flush=R1,Y2._tr_init(Q),R2}function P9($){var Q=D9($);if(Q===R2)_G($.state);return Q}function hG($,Q){if(!$||!$.state)return G2;if($.state.wrap!==2)return G2;return $.state.gzhead=Q,R2}function R9($,Q,J,q,X,Y){if(!$)return G2;var G=1;if(Q===FG)Q=6;if(q<0)G=0,q=-q;else if(q>15)G=2,q-=16;if(X<1||X>DG||J!==f8||q<8||q>15||Q<0||Q>9||Y<0||Y>OG)return Q1($,G2);if(q===8)q=9;var B=new bG;return $.state=B,B.strm=$,B.wrap=G,B.gzhead=null,B.w_bits=q,B.w_size=1<<B.w_bits,B.w_mask=B.w_size-1,B.hash_bits=X+7,B.hash_size=1<<B.hash_bits,B.hash_mask=B.hash_size-1,B.hash_shift=~~((B.hash_bits+C0-1)/C0),B.window=new i0.Buf8(B.w_size*2),B.head=new i0.Buf16(B.hash_size),B.prev=new i0.Buf16(B.w_size),B.lit_bufsize=1<<X+6,B.pending_buf_size=B.lit_bufsize*4,B.pending_buf=new i0.Buf8(B.pending_buf_size),B.d_buf=1*B.lit_bufsize,B.l_buf=3*B.lit_bufsize,B.level=Q,B.strategy=Y,B.method=J,P9($)}function mG($,Q){return R9($,Q,f8,PG,RG,NG)}function uG($,Q){var J,q,X,Y;if(!$||!$.state||Q>L9||Q<0)return $?Q1($,G2):G2;if(q=$.state,!$.output||!$.input&&$.avail_in!==0||q.status===p6&&Q!==J1)return Q1($,$.avail_out===0?W4:G2);if(q.strm=$,J=q.last_flush,q.last_flush=Q,q.status===y8)if(q.wrap===2)if($.adler=0,I0(q,31),I0(q,139),I0(q,8),!q.gzhead)I0(q,0),I0(q,0),I0(q,0),I0(q,0),I0(q,0),I0(q,q.level===9?2:q.strategy>=T8||q.level<2?4:0),I0(q,ZG),q.status=A1;else{if(I0(q,(q.gzhead.text?1:0)+(q.gzhead.hcrc?2:0)+(!q.gzhead.extra?0:4)+(!q.gzhead.name?0:8)+(!q.gzhead.comment?0:16)),I0(q,q.gzhead.time&255),I0(q,q.gzhead.time>>8&255),I0(q,q.gzhead.time>>16&255),I0(q,q.gzhead.time>>24&255),I0(q,q.level===9?2:q.strategy>=T8||q.level<2?4:0),I0(q,q.gzhead.os&255),q.gzhead.extra&&q.gzhead.extra.length)I0(q,q.gzhead.extra.length&255),I0(q,q.gzhead.extra.length>>8&255);if(q.gzhead.hcrc)$.adler=s2($.adler,q.pending_buf,q.pending,0);q.gzindex=0,q.status=H4}else{var G=f8+(q.w_bits-8<<4)<<8,B=-1;if(q.strategy>=T8||q.level<2)B=0;else if(q.level<6)B=1;else if(q.level===6)B=2;else B=3;if(G|=B<<6,q.strstart!==0)G|=TG;if(G+=31-G%31,q.status=A1,c6(q,G),q.strstart!==0)c6(q,$.adler>>>16),c6(q,$.adler&65535);$.adler=1}if(q.status===H4)if(q.gzhead.extra){X=q.pending;while(q.gzindex<(q.gzhead.extra.length&65535)){if(q.pending===q.pending_buf_size){if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(t2($),X=q.pending,q.pending===q.pending_buf_size)break}I0(q,q.gzhead.extra[q.gzindex]&255),q.gzindex++}if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(q.gzindex===q.gzhead.extra.length)q.gzindex=0,q.status=Z8}else q.status=Z8;if(q.status===Z8)if(q.gzhead.name){X=q.pending;do{if(q.pending===q.pending_buf_size){if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(t2($),X=q.pending,q.pending===q.pending_buf_size){Y=1;break}}if(q.gzindex<q.gzhead.name.length)Y=q.gzhead.name.charCodeAt(q.gzindex++)&255;else Y=0;I0(q,Y)}while(Y!==0);if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(Y===0)q.gzindex=0,q.status=g8}else q.status=g8;if(q.status===g8)if(q.gzhead.comment){X=q.pending;do{if(q.pending===q.pending_buf_size){if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(t2($),X=q.pending,q.pending===q.pending_buf_size){Y=1;break}}if(q.gzindex<q.gzhead.comment.length)Y=q.gzhead.comment.charCodeAt(q.gzindex++)&255;else Y=0;I0(q,Y)}while(Y!==0);if(q.gzhead.hcrc&&q.pending>X)$.adler=s2($.adler,q.pending_buf,q.pending-X,X);if(Y===0)q.status=x8}else q.status=x8;if(q.status===x8)if(q.gzhead.hcrc){if(q.pending+2>q.pending_buf_size)t2($);if(q.pending+2<=q.pending_buf_size)I0(q,$.adler&255),I0(q,$.adler>>8&255),$.adler=0,q.status=A1}else q.status=A1;if(q.pending!==0){if(t2($),$.avail_out===0)return q.last_flush=-1,R2}else if($.avail_in===0&&O9(Q)<=O9(J)&&Q!==J1)return Q1($,W4);if(q.status===p6&&$.avail_in!==0)return Q1($,W4);if($.avail_in!==0||q.lookahead!==0||Q!==R1&&q.status!==p6){var W=q.strategy===T8?yG(q,Q):q.strategy===zG?fG(q,Q):o1[q.level].func(q,Q);if(W===D1||W===r1)q.status=p6;if(W===y0||W===D1){if($.avail_out===0)q.last_flush=-1;return R2}if(W===l6){if(Q===jG)Y2._tr_align(q);else if(Q!==L9){if(Y2._tr_stored_block(q,0,0,!1),Q===MG){if(e2(q.head),q.lookahead===0)q.strstart=0,q.block_start=0,q.insert=0}}if(t2($),$.avail_out===0)return q.last_flush=-1,R2}}if(Q!==J1)return R2;if(q.wrap<=0)return z9;if(q.wrap===2)I0(q,$.adler&255),I0(q,$.adler>>8&255),I0(q,$.adler>>16&255),I0(q,$.adler>>24&255),I0(q,$.total_in&255),I0(q,$.total_in>>8&255),I0(q,$.total_in>>16&255),I0(q,$.total_in>>24&255);else c6(q,$.adler>>>16),c6(q,$.adler&65535);if(t2($),q.wrap>0)q.wrap=-q.wrap;return q.pending!==0?R2:z9}function cG($){var Q;if(!$||!$.state)return G2;if(Q=$.state.status,Q!==y8&&Q!==H4&&Q!==Z8&&Q!==g8&&Q!==x8&&Q!==A1&&Q!==p6)return Q1($,G2);return $.state=null,Q===A1?Q1($,wG):R2}function pG($,Q){var J=Q.length,q,X,Y,G,B,W,U,V;if(!$||!$.state)return G2;if(q=$.state,G=q.wrap,G===2||G===1&&q.status!==y8||q.lookahead)return G2;if(G===1)$.adler=N9($.adler,Q,J,0);if(q.wrap=0,J>=q.w_size){if(G===0)e2(q.head),q.strstart=0,q.block_start=0,q.insert=0;V=new i0.Buf8(q.w_size),i0.arraySet(V,Q,J-q.w_size,q.w_size,0),Q=V,J=q.w_size}B=$.avail_in,W=$.next_in,U=$.input,$.avail_in=J,$.next_in=0,$.input=Q,P1(q);while(q.lookahead>=C0){X=q.strstart,Y=q.lookahead-(C0-1);do q.ins_h=(q.ins_h<<q.hash_shift^q.window[X+C0-1])&q.hash_mask,q.prev[X&q.w_mask]=q.head[q.ins_h],q.head[q.ins_h]=X,X++;while(--Y);q.strstart=X,q.lookahead=C0-1,P1(q)}return q.strstart+=q.lookahead,q.block_start=q.strstart,q.insert=q.lookahead,q.lookahead=0,q.match_length=q.prev_length=C0-1,q.match_available=0,$.next_in=W,$.input=U,$.avail_in=B,q.wrap=G,R2}lG.deflateInit=mG;lG.deflateInit2=R9;lG.deflateReset=P9;lG.deflateResetKeep=D9;lG.deflateSetHeader=hG;lG.deflate=uG;lG.deflateEnd=cG;lG.deflateSetDictionary=pG;lG.deflateInfo="pako deflate (from Nodeca project)"});var j4=j0(($B)=>{var _8=b2(),I9=!0,S9=!0;try{String.fromCharCode.apply(null,[0])}catch($){I9=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch($){S9=!1}var d6=new _8.Buf8(256);for(C2=0;C2<256;C2++)d6[C2]=C2>=252?6:C2>=248?5:C2>=240?4:C2>=224?3:C2>=192?2:1;var C2;d6[254]=d6[254]=1;$B.string2buf=function($){var Q,J,q,X,Y,G=$.length,B=0;for(X=0;X<G;X++){if(J=$.charCodeAt(X),(J&64512)===55296&&X+1<G){if(q=$.charCodeAt(X+1),(q&64512)===56320)J=65536+(J-55296<<10)+(q-56320),X++}B+=J<128?1:J<2048?2:J<65536?3:4}Q=new _8.Buf8(B);for(Y=0,X=0;Y<B;X++){if(J=$.charCodeAt(X),(J&64512)===55296&&X+1<G){if(q=$.charCodeAt(X+1),(q&64512)===56320)J=65536+(J-55296<<10)+(q-56320),X++}if(J<128)Q[Y++]=J;else if(J<2048)Q[Y++]=192|J>>>6,Q[Y++]=128|J&63;else if(J<65536)Q[Y++]=224|J>>>12,Q[Y++]=128|J>>>6&63,Q[Y++]=128|J&63;else Q[Y++]=240|J>>>18,Q[Y++]=128|J>>>12&63,Q[Y++]=128|J>>>6&63,Q[Y++]=128|J&63}return Q};function E9($,Q){if(Q<65534){if($.subarray&&S9||!$.subarray&&I9)return String.fromCharCode.apply(null,_8.shrinkBuf($,Q))}var J="";for(var q=0;q<Q;q++)J+=String.fromCharCode($[q]);return J}$B.buf2binstring=function($){return E9($,$.length)};$B.binstring2buf=function($){var Q=new _8.Buf8($.length);for(var J=0,q=Q.length;J<q;J++)Q[J]=$.charCodeAt(J);return Q};$B.buf2string=function($,Q){var J,q,X,Y,G=Q||$.length,B=Array(G*2);for(q=0,J=0;J<G;){if(X=$[J++],X<128){B[q++]=X;continue}if(Y=d6[X],Y>4){B[q++]=65533,J+=Y-1;continue}X&=Y===2?31:Y===3?15:7;while(Y>1&&J<G)X=X<<6|$[J++]&63,Y--;if(Y>1){B[q++]=65533;continue}if(X<65536)B[q++]=X;else X-=65536,B[q++]=55296|X>>10&1023,B[q++]=56320|X&1023}return E9(B,q)};$B.utf8border=function($,Q){var J;if(Q=Q||$.length,Q>$.length)Q=$.length;J=Q-1;while(J>=0&&($[J]&192)===128)J--;if(J<0)return Q;if(J===0)return Q;return J+d6[$[J]]>Q?J:Q}});var M4=j0((CK,v9)=>{function GB(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}v9.exports=GB});var g9=j0((MB)=>{var i6=C9(),n6=b2(),F4=j4(),L4=k8(),BB=M4(),Z9=Object.prototype.toString,UB=0,w4=4,a1=0,k9=1,T9=2,WB=-1,VB=0,KB=8;function C1($){if(!(this instanceof C1))return new C1($);this.options=n6.assign({level:WB,method:KB,chunkSize:16384,windowBits:15,memLevel:8,strategy:VB,to:""},$||{});var Q=this.options;if(Q.raw&&Q.windowBits>0)Q.windowBits=-Q.windowBits;else if(Q.gzip&&Q.windowBits>0&&Q.windowBits<16)Q.windowBits+=16;this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new BB,this.strm.avail_out=0;var J=i6.deflateInit2(this.strm,Q.level,Q.method,Q.windowBits,Q.memLevel,Q.strategy);if(J!==a1)throw Error(L4[J]);if(Q.header)i6.deflateSetHeader(this.strm,Q.header);if(Q.dictionary){var q;if(typeof Q.dictionary==="string")q=F4.string2buf(Q.dictionary);else if(Z9.call(Q.dictionary)==="[object ArrayBuffer]")q=new Uint8Array(Q.dictionary);else q=Q.dictionary;if(J=i6.deflateSetDictionary(this.strm,q),J!==a1)throw Error(L4[J]);this._dict_set=!0}}C1.prototype.push=function($,Q){var J=this.strm,q=this.options.chunkSize,X,Y;if(this.ended)return!1;if(Y=Q===~~Q?Q:Q===!0?w4:UB,typeof $==="string")J.input=F4.string2buf($);else if(Z9.call($)==="[object ArrayBuffer]")J.input=new Uint8Array($);else J.input=$;J.next_in=0,J.avail_in=J.input.length;do{if(J.avail_out===0)J.output=new n6.Buf8(q),J.next_out=0,J.avail_out=q;if(X=i6.deflate(J,Y),X!==k9&&X!==a1)return this.onEnd(X),this.ended=!0,!1;if(J.avail_out===0||J.avail_in===0&&(Y===w4||Y===T9))if(this.options.to==="string")this.onData(F4.buf2binstring(n6.shrinkBuf(J.output,J.next_out)));else this.onData(n6.shrinkBuf(J.output,J.next_out))}while((J.avail_in>0||J.avail_out===0)&&X!==k9);if(Y===w4)return X=i6.deflateEnd(this.strm),this.onEnd(X),this.ended=!0,X===a1;if(Y===T9)return this.onEnd(a1),J.avail_out=0,!0;return!0};C1.prototype.onData=function($){this.chunks.push($)};C1.prototype.onEnd=function($){if($===a1)if(this.options.to==="string")this.result=this.chunks.join("");else this.result=n6.flattenChunks(this.chunks);this.chunks=[],this.err=$,this.msg=this.strm.msg};function z4($,Q){var J=new C1(Q);if(J.push($,!0),J.err)throw J.msg||L4[J.err];return J.result}function HB($,Q){return Q=Q||{},Q.raw=!0,z4($,Q)}function jB($,Q){return Q=Q||{},Q.gzip=!0,z4($,Q)}MB.Deflate=C1;MB.deflate=z4;MB.deflateRaw=HB;MB.gzip=jB});var f9=j0((SK,x9)=>{var b8=30,OB=12;x9.exports=function(Q,J){var q,X,Y,G,B,W,U,V,L,w,M,y,x,A,D,K,F,z,R,_,T,l,S,E,P;q=Q.state,X=Q.next_in,E=Q.input,Y=X+(Q.avail_in-5),G=Q.next_out,P=Q.output,B=G-(J-Q.avail_out),W=G+(Q.avail_out-257),U=q.dmax,V=q.wsize,L=q.whave,w=q.wnext,M=q.window,y=q.hold,x=q.bits,A=q.lencode,D=q.distcode,K=(1<<q.lenbits)-1,F=(1<<q.distbits)-1;$:do{if(x<15)y+=E[X++]<<x,x+=8,y+=E[X++]<<x,x+=8;z=A[y&K];Q:for(;;){if(R=z>>>24,y>>>=R,x-=R,R=z>>>16&255,R===0)P[G++]=z&65535;else if(R&16){if(_=z&65535,R&=15,R){if(x<R)y+=E[X++]<<x,x+=8;_+=y&(1<<R)-1,y>>>=R,x-=R}if(x<15)y+=E[X++]<<x,x+=8,y+=E[X++]<<x,x+=8;z=D[y&F];J:for(;;){if(R=z>>>24,y>>>=R,x-=R,R=z>>>16&255,R&16){if(T=z&65535,R&=15,x<R){if(y+=E[X++]<<x,x+=8,x<R)y+=E[X++]<<x,x+=8}if(T+=y&(1<<R)-1,T>U){Q.msg="invalid distance too far back",q.mode=b8;break $}if(y>>>=R,x-=R,R=G-B,T>R){if(R=T-R,R>L){if(q.sane){Q.msg="invalid distance too far back",q.mode=b8;break $}}if(l=0,S=M,w===0){if(l+=V-R,R<_){_-=R;do P[G++]=M[l++];while(--R);l=G-T,S=P}}else if(w<R){if(l+=V+w-R,R-=w,R<_){_-=R;do P[G++]=M[l++];while(--R);if(l=0,w<_){R=w,_-=R;do P[G++]=M[l++];while(--R);l=G-T,S=P}}}else if(l+=w-R,R<_){_-=R;do P[G++]=M[l++];while(--R);l=G-T,S=P}while(_>2)P[G++]=S[l++],P[G++]=S[l++],P[G++]=S[l++],_-=3;if(_){if(P[G++]=S[l++],_>1)P[G++]=S[l++]}}else{l=G-T;do P[G++]=P[l++],P[G++]=P[l++],P[G++]=P[l++],_-=3;while(_>2);if(_){if(P[G++]=P[l++],_>1)P[G++]=P[l++]}}}else if((R&64)===0){z=D[(z&65535)+(y&(1<<R)-1)];continue J}else{Q.msg="invalid distance code",q.mode=b8;break $}break}}else if((R&64)===0){z=A[(z&65535)+(y&(1<<R)-1)];continue Q}else if(R&32){q.mode=OB;break $}else{Q.msg="invalid literal/length code",q.mode=b8;break $}break}}while(X<Y&&G<W);_=x>>3,X-=_,x-=_<<3,y&=(1<<x)-1,Q.next_in=X,Q.next_out=G,Q.avail_in=X<Y?5+(Y-X):5-(X-Y),Q.avail_out=G<W?257+(W-G):257-(G-W),q.hold=y,q.bits=x;return}});var c9=j0((EK,u9)=>{var y9=b2(),s1=15,_9=852,b9=592,h9=0,O4=1,m9=2,NB=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],AB=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],DB=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],PB=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];u9.exports=function(Q,J,q,X,Y,G,B,W){var U=W.bits,V=0,L=0,w=0,M=0,y=0,x=0,A=0,D=0,K=0,F=0,z,R,_,T,l,S=null,E=0,P,O=new y9.Buf16(s1+1),Z=new y9.Buf16(s1+1),f=null,k=0,s,J0,B0;for(V=0;V<=s1;V++)O[V]=0;for(L=0;L<X;L++)O[J[q+L]]++;y=U;for(M=s1;M>=1;M--)if(O[M]!==0)break;if(y>M)y=M;if(M===0)return Y[G++]=20971520,Y[G++]=20971520,W.bits=1,0;for(w=1;w<M;w++)if(O[w]!==0)break;if(y<w)y=w;D=1;for(V=1;V<=s1;V++)if(D<<=1,D-=O[V],D<0)return-1;if(D>0&&(Q===h9||M!==1))return-1;Z[1]=0;for(V=1;V<s1;V++)Z[V+1]=Z[V]+O[V];for(L=0;L<X;L++)if(J[q+L]!==0)B[Z[J[q+L]]++]=L;if(Q===h9)S=f=B,P=19;else if(Q===O4)S=NB,E-=257,f=AB,k-=257,P=256;else S=DB,f=PB,P=-1;if(F=0,L=0,V=w,l=G,x=y,A=0,_=-1,K=1<<y,T=K-1,Q===O4&&K>_9||Q===m9&&K>b9)return 1;for(;;){if(s=V-A,B[L]<P)J0=0,B0=B[L];else if(B[L]>P)J0=f[k+B[L]],B0=S[E+B[L]];else J0=96,B0=0;z=1<<V-A,R=1<<x,w=R;do R-=z,Y[l+(F>>A)+R]=s<<24|J0<<16|B0|0;while(R!==0);z=1<<V-1;while(F&z)z>>=1;if(z!==0)F&=z-1,F+=z;else F=0;if(L++,--O[V]===0){if(V===M)break;V=J[q+B[L]]}if(V>y&&(F&T)!==_){if(A===0)A=y;l+=w,x=V-A,D=1<<x;while(x+A<M){if(D-=O[x+A],D<=0)break;x++,D<<=1}if(K+=1<<x,Q===O4&&K>_9||Q===m9&&K>b9)return 1;_=F&T,Y[_]=y<<24|x<<16|l-G|0}}if(F!==0)Y[l+F]=V-A<<24|4194304|0;return W.bits=y,0}});var PQ=j0((cB)=>{var e0=b2(),C4=B4(),I2=U4(),RB=f9(),o6=c9(),CB=0,MQ=1,wQ=2,p9=4,IB=5,h8=6,I1=0,SB=1,EB=2,B2=-2,FQ=-3,I4=-4,vB=-5,l9=8,LQ=1,d9=2,i9=3,n9=4,o9=5,r9=6,a9=7,s9=8,t9=9,e9=10,c8=11,m2=12,N4=13,$Q=14,A4=15,QQ=16,JQ=17,qQ=18,XQ=19,m8=20,u8=21,YQ=22,GQ=23,BQ=24,UQ=25,WQ=26,D4=27,VQ=28,KQ=29,T0=30,S4=31,kB=32,TB=852,ZB=592,gB=15,xB=gB;function HQ($){return($>>>24&255)+($>>>8&65280)+(($&65280)<<8)+(($&255)<<24)}function fB(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new e0.Buf16(320),this.work=new e0.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function zQ($){var Q;if(!$||!$.state)return B2;if(Q=$.state,$.total_in=$.total_out=Q.total=0,$.msg="",Q.wrap)$.adler=Q.wrap&1;return Q.mode=LQ,Q.last=0,Q.havedict=0,Q.dmax=32768,Q.head=null,Q.hold=0,Q.bits=0,Q.lencode=Q.lendyn=new e0.Buf32(TB),Q.distcode=Q.distdyn=new e0.Buf32(ZB),Q.sane=1,Q.back=-1,I1}function OQ($){var Q;if(!$||!$.state)return B2;return Q=$.state,Q.wsize=0,Q.whave=0,Q.wnext=0,zQ($)}function NQ($,Q){var J,q;if(!$||!$.state)return B2;if(q=$.state,Q<0)J=0,Q=-Q;else if(J=(Q>>4)+1,Q<48)Q&=15;if(Q&&(Q<8||Q>15))return B2;if(q.window!==null&&q.wbits!==Q)q.window=null;return q.wrap=J,q.wbits=Q,OQ($)}function AQ($,Q){var J,q;if(!$)return B2;if(q=new fB,$.state=q,q.window=null,J=NQ($,Q),J!==I1)$.state=null;return J}function yB($){return AQ($,xB)}var jQ=!0,P4,R4;function _B($){if(jQ){var Q;P4=new e0.Buf32(512),R4=new e0.Buf32(32),Q=0;while(Q<144)$.lens[Q++]=8;while(Q<256)$.lens[Q++]=9;while(Q<280)$.lens[Q++]=7;while(Q<288)$.lens[Q++]=8;o6(MQ,$.lens,0,288,P4,0,$.work,{bits:9}),Q=0;while(Q<32)$.lens[Q++]=5;o6(wQ,$.lens,0,32,R4,0,$.work,{bits:5}),jQ=!1}$.lencode=P4,$.lenbits=9,$.distcode=R4,$.distbits=5}function DQ($,Q,J,q){var X,Y=$.state;if(Y.window===null)Y.wsize=1<<Y.wbits,Y.wnext=0,Y.whave=0,Y.window=new e0.Buf8(Y.wsize);if(q>=Y.wsize)e0.arraySet(Y.window,Q,J-Y.wsize,Y.wsize,0),Y.wnext=0,Y.whave=Y.wsize;else{if(X=Y.wsize-Y.wnext,X>q)X=q;if(e0.arraySet(Y.window,Q,J-q,X,Y.wnext),q-=X,q)e0.arraySet(Y.window,Q,J-q,q,0),Y.wnext=q,Y.whave=Y.wsize;else{if(Y.wnext+=X,Y.wnext===Y.wsize)Y.wnext=0;if(Y.whave<Y.wsize)Y.whave+=X}}return 0}function bB($,Q){var J,q,X,Y,G,B,W,U,V,L,w,M,y,x,A=0,D,K,F,z,R,_,T,l,S=new e0.Buf8(4),E,P,O=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!$||!$.state||!$.output||!$.input&&$.avail_in!==0)return B2;if(J=$.state,J.mode===m2)J.mode=N4;G=$.next_out,X=$.output,W=$.avail_out,Y=$.next_in,q=$.input,B=$.avail_in,U=J.hold,V=J.bits,L=B,w=W,l=I1;$:for(;;)switch(J.mode){case LQ:if(J.wrap===0){J.mode=N4;break}while(V<16){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.wrap&2&&U===35615){J.check=0,S[0]=U&255,S[1]=U>>>8&255,J.check=I2(J.check,S,2,0),U=0,V=0,J.mode=d9;break}if(J.flags=0,J.head)J.head.done=!1;if(!(J.wrap&1)||(((U&255)<<8)+(U>>8))%31){$.msg="incorrect header check",J.mode=T0;break}if((U&15)!==l9){$.msg="unknown compression method",J.mode=T0;break}if(U>>>=4,V-=4,T=(U&15)+8,J.wbits===0)J.wbits=T;else if(T>J.wbits){$.msg="invalid window size",J.mode=T0;break}J.dmax=1<<T,$.adler=J.check=1,J.mode=U&512?e9:m2,U=0,V=0;break;case d9:while(V<16){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.flags=U,(J.flags&255)!==l9){$.msg="unknown compression method",J.mode=T0;break}if(J.flags&57344){$.msg="unknown header flags set",J.mode=T0;break}if(J.head)J.head.text=U>>8&1;if(J.flags&512)S[0]=U&255,S[1]=U>>>8&255,J.check=I2(J.check,S,2,0);U=0,V=0,J.mode=i9;case i9:while(V<32){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.head)J.head.time=U;if(J.flags&512)S[0]=U&255,S[1]=U>>>8&255,S[2]=U>>>16&255,S[3]=U>>>24&255,J.check=I2(J.check,S,4,0);U=0,V=0,J.mode=n9;case n9:while(V<16){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.head)J.head.xflags=U&255,J.head.os=U>>8;if(J.flags&512)S[0]=U&255,S[1]=U>>>8&255,J.check=I2(J.check,S,2,0);U=0,V=0,J.mode=o9;case o9:if(J.flags&1024){while(V<16){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.length=U,J.head)J.head.extra_len=U;if(J.flags&512)S[0]=U&255,S[1]=U>>>8&255,J.check=I2(J.check,S,2,0);U=0,V=0}else if(J.head)J.head.extra=null;J.mode=r9;case r9:if(J.flags&1024){if(M=J.length,M>B)M=B;if(M){if(J.head){if(T=J.head.extra_len-J.length,!J.head.extra)J.head.extra=Array(J.head.extra_len);e0.arraySet(J.head.extra,q,Y,M,T)}if(J.flags&512)J.check=I2(J.check,q,M,Y);B-=M,Y+=M,J.length-=M}if(J.length)break $}J.length=0,J.mode=a9;case a9:if(J.flags&2048){if(B===0)break $;M=0;do if(T=q[Y+M++],J.head&&T&&J.length<65536)J.head.name+=String.fromCharCode(T);while(T&&M<B);if(J.flags&512)J.check=I2(J.check,q,M,Y);if(B-=M,Y+=M,T)break $}else if(J.head)J.head.name=null;J.length=0,J.mode=s9;case s9:if(J.flags&4096){if(B===0)break $;M=0;do if(T=q[Y+M++],J.head&&T&&J.length<65536)J.head.comment+=String.fromCharCode(T);while(T&&M<B);if(J.flags&512)J.check=I2(J.check,q,M,Y);if(B-=M,Y+=M,T)break $}else if(J.head)J.head.comment=null;J.mode=t9;case t9:if(J.flags&512){while(V<16){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(U!==(J.check&65535)){$.msg="header crc mismatch",J.mode=T0;break}U=0,V=0}if(J.head)J.head.hcrc=J.flags>>9&1,J.head.done=!0;$.adler=J.check=0,J.mode=m2;break;case e9:while(V<32){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}$.adler=J.check=HQ(U),U=0,V=0,J.mode=c8;case c8:if(J.havedict===0)return $.next_out=G,$.avail_out=W,$.next_in=Y,$.avail_in=B,J.hold=U,J.bits=V,EB;$.adler=J.check=1,J.mode=m2;case m2:if(Q===IB||Q===h8)break $;case N4:if(J.last){U>>>=V&7,V-=V&7,J.mode=D4;break}while(V<3){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}switch(J.last=U&1,U>>>=1,V-=1,U&3){case 0:J.mode=$Q;break;case 1:if(_B(J),J.mode=m8,Q===h8){U>>>=2,V-=2;break $}break;case 2:J.mode=JQ;break;case 3:$.msg="invalid block type",J.mode=T0}U>>>=2,V-=2;break;case $Q:U>>>=V&7,V-=V&7;while(V<32){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if((U&65535)!==(U>>>16^65535)){$.msg="invalid stored block lengths",J.mode=T0;break}if(J.length=U&65535,U=0,V=0,J.mode=A4,Q===h8)break $;case A4:J.mode=QQ;case QQ:if(M=J.length,M){if(M>B)M=B;if(M>W)M=W;if(M===0)break $;e0.arraySet(X,q,Y,M,G),B-=M,Y+=M,W-=M,G+=M,J.length-=M;break}J.mode=m2;break;case JQ:while(V<14){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(J.nlen=(U&31)+257,U>>>=5,V-=5,J.ndist=(U&31)+1,U>>>=5,V-=5,J.ncode=(U&15)+4,U>>>=4,V-=4,J.nlen>286||J.ndist>30){$.msg="too many length or distance symbols",J.mode=T0;break}J.have=0,J.mode=qQ;case qQ:while(J.have<J.ncode){while(V<3){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}J.lens[O[J.have++]]=U&7,U>>>=3,V-=3}while(J.have<19)J.lens[O[J.have++]]=0;if(J.lencode=J.lendyn,J.lenbits=7,E={bits:J.lenbits},l=o6(CB,J.lens,0,19,J.lencode,0,J.work,E),J.lenbits=E.bits,l){$.msg="invalid code lengths set",J.mode=T0;break}J.have=0,J.mode=XQ;case XQ:while(J.have<J.nlen+J.ndist){for(;;){if(A=J.lencode[U&(1<<J.lenbits)-1],D=A>>>24,K=A>>>16&255,F=A&65535,D<=V)break;if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(F<16)U>>>=D,V-=D,J.lens[J.have++]=F;else{if(F===16){P=D+2;while(V<P){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(U>>>=D,V-=D,J.have===0){$.msg="invalid bit length repeat",J.mode=T0;break}T=J.lens[J.have-1],M=3+(U&3),U>>>=2,V-=2}else if(F===17){P=D+3;while(V<P){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}U>>>=D,V-=D,T=0,M=3+(U&7),U>>>=3,V-=3}else{P=D+7;while(V<P){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}U>>>=D,V-=D,T=0,M=11+(U&127),U>>>=7,V-=7}if(J.have+M>J.nlen+J.ndist){$.msg="invalid bit length repeat",J.mode=T0;break}while(M--)J.lens[J.have++]=T}}if(J.mode===T0)break;if(J.lens[256]===0){$.msg="invalid code -- missing end-of-block",J.mode=T0;break}if(J.lenbits=9,E={bits:J.lenbits},l=o6(MQ,J.lens,0,J.nlen,J.lencode,0,J.work,E),J.lenbits=E.bits,l){$.msg="invalid literal/lengths set",J.mode=T0;break}if(J.distbits=6,J.distcode=J.distdyn,E={bits:J.distbits},l=o6(wQ,J.lens,J.nlen,J.ndist,J.distcode,0,J.work,E),J.distbits=E.bits,l){$.msg="invalid distances set",J.mode=T0;break}if(J.mode=m8,Q===h8)break $;case m8:J.mode=u8;case u8:if(B>=6&&W>=258){if($.next_out=G,$.avail_out=W,$.next_in=Y,$.avail_in=B,J.hold=U,J.bits=V,RB($,w),G=$.next_out,X=$.output,W=$.avail_out,Y=$.next_in,q=$.input,B=$.avail_in,U=J.hold,V=J.bits,J.mode===m2)J.back=-1;break}J.back=0;for(;;){if(A=J.lencode[U&(1<<J.lenbits)-1],D=A>>>24,K=A>>>16&255,F=A&65535,D<=V)break;if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(K&&(K&240)===0){z=D,R=K,_=F;for(;;){if(A=J.lencode[_+((U&(1<<z+R)-1)>>z)],D=A>>>24,K=A>>>16&255,F=A&65535,z+D<=V)break;if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}U>>>=z,V-=z,J.back+=z}if(U>>>=D,V-=D,J.back+=D,J.length=F,K===0){J.mode=WQ;break}if(K&32){J.back=-1,J.mode=m2;break}if(K&64){$.msg="invalid literal/length code",J.mode=T0;break}J.extra=K&15,J.mode=YQ;case YQ:if(J.extra){P=J.extra;while(V<P){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}J.length+=U&(1<<J.extra)-1,U>>>=J.extra,V-=J.extra,J.back+=J.extra}J.was=J.length,J.mode=GQ;case GQ:for(;;){if(A=J.distcode[U&(1<<J.distbits)-1],D=A>>>24,K=A>>>16&255,F=A&65535,D<=V)break;if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if((K&240)===0){z=D,R=K,_=F;for(;;){if(A=J.distcode[_+((U&(1<<z+R)-1)>>z)],D=A>>>24,K=A>>>16&255,F=A&65535,z+D<=V)break;if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}U>>>=z,V-=z,J.back+=z}if(U>>>=D,V-=D,J.back+=D,K&64){$.msg="invalid distance code",J.mode=T0;break}J.offset=F,J.extra=K&15,J.mode=BQ;case BQ:if(J.extra){P=J.extra;while(V<P){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}J.offset+=U&(1<<J.extra)-1,U>>>=J.extra,V-=J.extra,J.back+=J.extra}if(J.offset>J.dmax){$.msg="invalid distance too far back",J.mode=T0;break}J.mode=UQ;case UQ:if(W===0)break $;if(M=w-W,J.offset>M){if(M=J.offset-M,M>J.whave){if(J.sane){$.msg="invalid distance too far back",J.mode=T0;break}}if(M>J.wnext)M-=J.wnext,y=J.wsize-M;else y=J.wnext-M;if(M>J.length)M=J.length;x=J.window}else x=X,y=G-J.offset,M=J.length;if(M>W)M=W;W-=M,J.length-=M;do X[G++]=x[y++];while(--M);if(J.length===0)J.mode=u8;break;case WQ:if(W===0)break $;X[G++]=J.length,W--,J.mode=u8;break;case D4:if(J.wrap){while(V<32){if(B===0)break $;B--,U|=q[Y++]<<V,V+=8}if(w-=W,$.total_out+=w,J.total+=w,w)$.adler=J.check=J.flags?I2(J.check,X,w,G-w):C4(J.check,X,w,G-w);if(w=W,(J.flags?U:HQ(U))!==J.check){$.msg="incorrect data check",J.mode=T0;break}U=0,V=0}J.mode=VQ;case VQ:if(J.wrap&&J.flags){while(V<32){if(B===0)break $;B--,U+=q[Y++]<<V,V+=8}if(U!==(J.total&4294967295)){$.msg="incorrect length check",J.mode=T0;break}U=0,V=0}J.mode=KQ;case KQ:l=SB;break $;case T0:l=FQ;break $;case S4:return I4;case kB:default:return B2}if($.next_out=G,$.avail_out=W,$.next_in=Y,$.avail_in=B,J.hold=U,J.bits=V,J.wsize||w!==$.avail_out&&J.mode<T0&&(J.mode<D4||Q!==p9)){if(DQ($,$.output,$.next_out,w-$.avail_out))return J.mode=S4,I4}if(L-=$.avail_in,w-=$.avail_out,$.total_in+=L,$.total_out+=w,J.total+=w,J.wrap&&w)$.adler=J.check=J.flags?I2(J.check,X,w,$.next_out-w):C4(J.check,X,w,$.next_out-w);if($.data_type=J.bits+(J.last?64:0)+(J.mode===m2?128:0)+(J.mode===m8||J.mode===A4?256:0),(L===0&&w===0||Q===p9)&&l===I1)l=vB;return l}function hB($){if(!$||!$.state)return B2;var Q=$.state;if(Q.window)Q.window=null;return $.state=null,I1}function mB($,Q){var J;if(!$||!$.state)return B2;if(J=$.state,(J.wrap&2)===0)return B2;return J.head=Q,Q.done=!1,I1}function uB($,Q){var J=Q.length,q,X,Y;if(!$||!$.state)return B2;if(q=$.state,q.wrap!==0&&q.mode!==c8)return B2;if(q.mode===c8){if(X=1,X=C4(X,Q,J,0),X!==q.check)return FQ}if(Y=DQ($,Q,J,J),Y)return q.mode=S4,I4;return q.havedict=1,I1}cB.inflateReset=OQ;cB.inflateReset2=NQ;cB.inflateResetKeep=zQ;cB.inflateInit=yB;cB.inflateInit2=AQ;cB.inflate=bB;cB.inflateEnd=hB;cB.inflateGetHeader=mB;cB.inflateSetDictionary=uB;cB.inflateInfo="pako inflate (from Nodeca project)"});var E4=j0((kK,RQ)=>{RQ.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}});var IQ=j0((TK,CQ)=>{function eB(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}CQ.exports=eB});var EQ=j0((qU)=>{var t1=PQ(),r6=b2(),p8=j4(),f0=E4(),v4=k8(),$U=M4(),QU=IQ(),SQ=Object.prototype.toString;function S1($){if(!(this instanceof S1))return new S1($);this.options=r6.assign({chunkSize:16384,windowBits:0,to:""},$||{});var Q=this.options;if(Q.raw&&Q.windowBits>=0&&Q.windowBits<16){if(Q.windowBits=-Q.windowBits,Q.windowBits===0)Q.windowBits=-15}if(Q.windowBits>=0&&Q.windowBits<16&&!($&&$.windowBits))Q.windowBits+=32;if(Q.windowBits>15&&Q.windowBits<48){if((Q.windowBits&15)===0)Q.windowBits|=15}this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new $U,this.strm.avail_out=0;var J=t1.inflateInit2(this.strm,Q.windowBits);if(J!==f0.Z_OK)throw Error(v4[J]);if(this.header=new QU,t1.inflateGetHeader(this.strm,this.header),Q.dictionary){if(typeof Q.dictionary==="string")Q.dictionary=p8.string2buf(Q.dictionary);else if(SQ.call(Q.dictionary)==="[object ArrayBuffer]")Q.dictionary=new Uint8Array(Q.dictionary);if(Q.raw){if(J=t1.inflateSetDictionary(this.strm,Q.dictionary),J!==f0.Z_OK)throw Error(v4[J])}}}S1.prototype.push=function($,Q){var J=this.strm,q=this.options.chunkSize,X=this.options.dictionary,Y,G,B,W,U,V=!1;if(this.ended)return!1;if(G=Q===~~Q?Q:Q===!0?f0.Z_FINISH:f0.Z_NO_FLUSH,typeof $==="string")J.input=p8.binstring2buf($);else if(SQ.call($)==="[object ArrayBuffer]")J.input=new Uint8Array($);else J.input=$;J.next_in=0,J.avail_in=J.input.length;do{if(J.avail_out===0)J.output=new r6.Buf8(q),J.next_out=0,J.avail_out=q;if(Y=t1.inflate(J,f0.Z_NO_FLUSH),Y===f0.Z_NEED_DICT&&X)Y=t1.inflateSetDictionary(this.strm,X);if(Y===f0.Z_BUF_ERROR&&V===!0)Y=f0.Z_OK,V=!1;if(Y!==f0.Z_STREAM_END&&Y!==f0.Z_OK)return this.onEnd(Y),this.ended=!0,!1;if(J.next_out){if(J.avail_out===0||Y===f0.Z_STREAM_END||J.avail_in===0&&(G===f0.Z_FINISH||G===f0.Z_SYNC_FLUSH))if(this.options.to==="string"){if(B=p8.utf8border(J.output,J.next_out),W=J.next_out-B,U=p8.buf2string(J.output,B),J.next_out=W,J.avail_out=q-W,W)r6.arraySet(J.output,J.output,B,W,0);this.onData(U)}else this.onData(r6.shrinkBuf(J.output,J.next_out))}if(J.avail_in===0&&J.avail_out===0)V=!0}while((J.avail_in>0||J.avail_out===0)&&Y!==f0.Z_STREAM_END);if(Y===f0.Z_STREAM_END)G=f0.Z_FINISH;if(G===f0.Z_FINISH)return Y=t1.inflateEnd(this.strm),this.onEnd(Y),this.ended=!0,Y===f0.Z_OK;if(G===f0.Z_SYNC_FLUSH)return this.onEnd(f0.Z_OK),J.avail_out=0,!0;return!0};S1.prototype.onData=function($){this.chunks.push($)};S1.prototype.onEnd=function($){if($===f0.Z_OK)if(this.options.to==="string")this.result=this.chunks.join("");else this.result=r6.flattenChunks(this.chunks);this.chunks=[],this.err=$,this.msg=this.strm.msg};function k4($,Q){var J=new S1(Q);if(J.push($,!0),J.err)throw J.msg||v4[J.err];return J.result}function JU($,Q){return Q=Q||{},Q.raw=!0,k4($,Q)}qU.Inflate=S1;qU.inflate=k4;qU.inflateRaw=JU;qU.ungzip=k4});var TQ=j0((gK,kQ)=>{var UU=b2().assign,WU=g9(),VU=EQ(),KU=E4(),vQ={};UU(vQ,WU,VU,KU);kQ.exports=vQ});var gQ=j0((wU)=>{var HU=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Uint32Array<"u",jU=TQ(),ZQ=g0(),l8=t0(),MU=HU?"uint8array":"array";wU.magic="\b\x00";function E1($,Q){l8.call(this,"FlateWorker/"+$),this._pako=null,this._pakoAction=$,this._pakoOptions=Q,this.meta={}}ZQ.inherits(E1,l8);E1.prototype.processChunk=function($){if(this.meta=$.meta,this._pako===null)this._createPako();this._pako.push(ZQ.transformTo(MU,$.data),!1)};E1.prototype.flush=function(){if(l8.prototype.flush.call(this),this._pako===null)this._createPako();this._pako.push([],!0)};E1.prototype.cleanUp=function(){l8.prototype.cleanUp.call(this),this._pako=null};E1.prototype._createPako=function(){this._pako=new jU[this._pakoAction]({raw:!0,level:this._pakoOptions.level||-1});var $=this;this._pako.onData=function(Q){$.push({data:Q,meta:$.meta})}};wU.compressWorker=function($){return new E1("Deflate",$)};wU.uncompressWorker=function(){return new E1("Inflate",{})}});var T4=j0((OU)=>{var xQ=t0();OU.STORE={magic:"\x00\x00",compressWorker:function(){return new xQ("STORE compression")},uncompressWorker:function(){return new xQ("STORE decompression")}};OU.DEFLATE=gQ()});var Z4=j0((DU)=>{DU.LOCAL_FILE_HEADER="PK\x03\x04";DU.CENTRAL_FILE_HEADER="PK\x01\x02";DU.CENTRAL_DIRECTORY_END="PK\x05\x06";DU.ZIP64_CENTRAL_DIRECTORY_LOCATOR="PK\x06\x07";DU.ZIP64_CENTRAL_DIRECTORY_END="PK\x06\x06";DU.DATA_DESCRIPTOR="PK\x07\b"});var bQ=j0((_K,_Q)=>{var e1=g0(),$6=t0(),g4=p1(),fQ=I8(),d8=Z4(),v0=function($,Q){var J="",q;for(q=0;q<Q;q++)J+=String.fromCharCode($&255),$=$>>>8;return J},vU=function($,Q){var J=$;if(!$)J=Q?16893:33204;return(J&65535)<<16},kU=function($){return($||0)&63},yQ=function($,Q,J,q,X,Y){var{file:G,compression:B}=$,W=Y!==g4.utf8encode,U=e1.transformTo("string",Y(G.name)),V=e1.transformTo("string",g4.utf8encode(G.name)),L=G.comment,w=e1.transformTo("string",Y(L)),M=e1.transformTo("string",g4.utf8encode(L)),y=V.length!==G.name.length,x=M.length!==L.length,A,D,K="",F="",z="",R=G.dir,_=G.date,T={crc32:0,compressedSize:0,uncompressedSize:0};if(!Q||J)T.crc32=$.crc32,T.compressedSize=$.compressedSize,T.uncompressedSize=$.uncompressedSize;var l=0;if(Q)l|=8;if(!W&&(y||x))l|=2048;var S=0,E=0;if(R)S|=16;if(X==="UNIX")E=798,S|=vU(G.unixPermissions,R);else E=20,S|=kU(G.dosPermissions,R);if(A=_.getUTCHours(),A=A<<6,A=A|_.getUTCMinutes(),A=A<<5,A=A|_.getUTCSeconds()/2,D=_.getUTCFullYear()-1980,D=D<<4,D=D|_.getUTCMonth()+1,D=D<<5,D=D|_.getUTCDate(),y)F=v0(1,1)+v0(fQ(U),4)+V,K+="up"+v0(F.length,2)+F;if(x)z=v0(1,1)+v0(fQ(w),4)+M,K+="uc"+v0(z.length,2)+z;var P="";P+=`
|
|
3
|
+
\x00`,P+=v0(l,2),P+=B.magic,P+=v0(A,2),P+=v0(D,2),P+=v0(T.crc32,4),P+=v0(T.compressedSize,4),P+=v0(T.uncompressedSize,4),P+=v0(U.length,2),P+=v0(K.length,2);var O=d8.LOCAL_FILE_HEADER+P+U+K,Z=d8.CENTRAL_FILE_HEADER+v0(E,2)+P+v0(w.length,2)+"\x00\x00\x00\x00"+v0(S,4)+v0(q,4)+U+K+w;return{fileRecord:O,dirRecord:Z}},TU=function($,Q,J,q,X){var Y="",G=e1.transformTo("string",X(q));return Y=d8.CENTRAL_DIRECTORY_END+"\x00\x00\x00\x00"+v0($,2)+v0($,2)+v0(Q,4)+v0(J,4)+v0(G.length,2)+G,Y},ZU=function($){var Q="";return Q=d8.DATA_DESCRIPTOR+v0($.crc32,4)+v0($.compressedSize,4)+v0($.uncompressedSize,4),Q};function V2($,Q,J,q){$6.call(this,"ZipFileWorker"),this.bytesWritten=0,this.zipComment=Q,this.zipPlatform=J,this.encodeFileName=q,this.streamFiles=$,this.accumulate=!1,this.contentBuffer=[],this.dirRecords=[],this.currentSourceOffset=0,this.entriesCount=0,this.currentFile=null,this._sources=[]}e1.inherits(V2,$6);V2.prototype.push=function($){var Q=$.meta.percent||0,J=this.entriesCount,q=this._sources.length;if(this.accumulate)this.contentBuffer.push($);else this.bytesWritten+=$.data.length,$6.prototype.push.call(this,{data:$.data,meta:{currentFile:this.currentFile,percent:J?(Q+100*(J-q-1))/J:100}})};V2.prototype.openedSource=function($){this.currentSourceOffset=this.bytesWritten,this.currentFile=$.file.name;var Q=this.streamFiles&&!$.file.dir;if(Q){var J=yQ($,Q,!1,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);this.push({data:J.fileRecord,meta:{percent:0}})}else this.accumulate=!0};V2.prototype.closedSource=function($){this.accumulate=!1;var Q=this.streamFiles&&!$.file.dir,J=yQ($,Q,!0,this.currentSourceOffset,this.zipPlatform,this.encodeFileName);if(this.dirRecords.push(J.dirRecord),Q)this.push({data:ZU($),meta:{percent:100}});else{this.push({data:J.fileRecord,meta:{percent:0}});while(this.contentBuffer.length)this.push(this.contentBuffer.shift())}this.currentFile=null};V2.prototype.flush=function(){var $=this.bytesWritten;for(var Q=0;Q<this.dirRecords.length;Q++)this.push({data:this.dirRecords[Q],meta:{percent:100}});var J=this.bytesWritten-$,q=TU(this.dirRecords.length,J,$,this.zipComment,this.encodeFileName);this.push({data:q,meta:{percent:100}})};V2.prototype.prepareNextSource=function(){if(this.previous=this._sources.shift(),this.openedSource(this.previous.streamInfo),this.isPaused)this.previous.pause();else this.previous.resume()};V2.prototype.registerPrevious=function($){this._sources.push($);var Q=this;return $.on("data",function(J){Q.processChunk(J)}),$.on("end",function(){if(Q.closedSource(Q.previous.streamInfo),Q._sources.length)Q.prepareNextSource();else Q.end()}),$.on("error",function(J){Q.error(J)}),this};V2.prototype.resume=function(){if(!$6.prototype.resume.call(this))return!1;if(!this.previous&&this._sources.length)return this.prepareNextSource(),!0;if(!this.previous&&!this._sources.length&&!this.generatedError)return this.end(),!0};V2.prototype.error=function($){var Q=this._sources;if(!$6.prototype.error.call(this,$))return!1;for(var J=0;J<Q.length;J++)try{Q[J].error($)}catch(q){}return!0};V2.prototype.lock=function(){$6.prototype.lock.call(this);var $=this._sources;for(var Q=0;Q<$.length;Q++)$[Q].lock()};_Q.exports=V2});var hQ=j0((yU)=>{var gU=T4(),xU=bQ(),fU=function($,Q){var J=$||Q,q=gU[J];if(!q)throw Error(J+" is not a valid compression method !");return q};yU.generateWorker=function($,Q,J){var q=new xU(Q.streamFiles,J,Q.platform,Q.encodeFileName),X=0;try{$.forEach(function(Y,G){X++;var B=fU(G.options.compression,Q.compression),W=G.options.compressionOptions||Q.compressionOptions||{},U=G.dir,V=G.date;G._compressWorker(B,W).withStreamInfo("file",{name:Y,dir:U,date:V,comment:G.comment||"",unixPermissions:G.unixPermissions,dosPermissions:G.dosPermissions}).pipe(q)}),q.entriesCount=X}catch(Y){q.error(Y)}return q}});var uQ=j0((hK,mQ)=>{var bU=g0(),i8=t0();function a6($,Q){i8.call(this,"Nodejs stream input adapter for "+$),this._upstreamEnded=!1,this._bindStream(Q)}bU.inherits(a6,i8);a6.prototype._bindStream=function($){var Q=this;this._stream=$,$.pause(),$.on("data",function(J){Q.push({data:J,meta:{percent:0}})}).on("error",function(J){if(Q.isPaused)this.generatedError=J;else Q.error(J)}).on("end",function(){if(Q.isPaused)Q._upstreamEnded=!0;else Q.end()})};a6.prototype.pause=function(){if(!i8.prototype.pause.call(this))return!1;return this._stream.pause(),!0};a6.prototype.resume=function(){if(!i8.prototype.resume.call(this))return!1;if(this._upstreamEnded)this.end();else this._stream.resume();return!0};mQ.exports=a6});var sQ=j0((mK,aQ)=>{var hU=p1(),s6=g0(),dQ=t0(),mU=_5(),iQ=b5(),cQ=S8(),uU=p$(),cU=hQ(),pQ=E6(),pU=uQ(),nQ=function($,Q,J){var q=s6.getTypeOf(Q),X,Y=s6.extend(J||{},iQ);if(Y.date=Y.date||new Date,Y.compression!==null)Y.compression=Y.compression.toUpperCase();if(typeof Y.unixPermissions==="string")Y.unixPermissions=parseInt(Y.unixPermissions,8);if(Y.unixPermissions&&Y.unixPermissions&16384)Y.dir=!0;if(Y.dosPermissions&&Y.dosPermissions&16)Y.dir=!0;if(Y.dir)$=oQ($);if(Y.createFolders&&(X=lU($)))rQ.call(this,X,!0);var G=q==="string"&&Y.binary===!1&&Y.base64===!1;if(!J||typeof J.binary>"u")Y.binary=!G;var B=Q instanceof cQ&&Q.uncompressedSize===0;if(B||Y.dir||!Q||Q.length===0)Y.base64=!1,Y.binary=!0,Q="",Y.compression="STORE",q="string";var W=null;if(Q instanceof cQ||Q instanceof dQ)W=Q;else if(pQ.isNode&&pQ.isStream(Q))W=new pU($,Q);else W=s6.prepareContent($,Q,Y.binary,Y.optimizedBinaryString,Y.base64);var U=new uU($,W,Y);this.files[$]=U},lU=function($){if($.slice(-1)==="/")$=$.substring(0,$.length-1);var Q=$.lastIndexOf("/");return Q>0?$.substring(0,Q):""},oQ=function($){if($.slice(-1)!=="/")$+="/";return $},rQ=function($,Q){if(Q=typeof Q<"u"?Q:iQ.createFolders,$=oQ($),!this.files[$])nQ.call(this,$,null,{dir:!0,createFolders:Q});return this.files[$]};function lQ($){return Object.prototype.toString.call($)==="[object RegExp]"}var dU={load:function(){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},forEach:function($){var Q,J,q;for(Q in this.files)if(q=this.files[Q],J=Q.slice(this.root.length,Q.length),J&&Q.slice(0,this.root.length)===this.root)$(J,q)},filter:function($){var Q=[];return this.forEach(function(J,q){if($(J,q))Q.push(q)}),Q},file:function($,Q,J){if(arguments.length===1)if(lQ($)){var q=$;return this.filter(function(Y,G){return!G.dir&&q.test(Y)})}else{var X=this.files[this.root+$];if(X&&!X.dir)return X;else return null}else $=this.root+$,nQ.call(this,$,Q,J);return this},folder:function($){if(!$)return this;if(lQ($))return this.filter(function(X,Y){return Y.dir&&$.test(X)});var Q=this.root+$,J=rQ.call(this,Q),q=this.clone();return q.root=J.name,q},remove:function($){$=this.root+$;var Q=this.files[$];if(!Q){if($.slice(-1)!=="/")$+="/";Q=this.files[$]}if(Q&&!Q.dir)delete this.files[$];else{var J=this.filter(function(X,Y){return Y.name.slice(0,$.length)===$});for(var q=0;q<J.length;q++)delete this.files[J[q].name]}return this},generate:function(){throw Error("This method has been removed in JSZip 3.0, please check the upgrade guide.")},generateInternalStream:function($){var Q,J={};try{if(J=s6.extend($||{},{streamFiles:!1,compression:"STORE",compressionOptions:null,type:"",platform:"DOS",comment:null,mimeType:"application/zip",encodeFileName:hU.utf8encode}),J.type=J.type.toLowerCase(),J.compression=J.compression.toUpperCase(),J.type==="binarystring")J.type="string";if(!J.type)throw Error("No output type specified.");if(s6.checkSupport(J.type),J.platform==="darwin"||J.platform==="freebsd"||J.platform==="linux"||J.platform==="sunos")J.platform="UNIX";if(J.platform==="win32")J.platform="DOS";var q=J.comment||this.comment||"";Q=cU.generateWorker(this,J,q)}catch(X){Q=new dQ("error"),Q.error(X)}return new mU(Q,J.type||"string",J.mimeType)},generateAsync:function($,Q){return this.generateInternalStream($).accumulate(Q)},generateNodeStream:function($,Q){if($=$||{},!$.type)$.type="nodebuffer";return this.generateInternalStream($).toNodejsStream(Q)}};aQ.exports=dU});var x4=j0((uK,eQ)=>{var iU=g0();function tQ($){this.data=$,this.length=$.length,this.index=0,this.zero=0}tQ.prototype={checkOffset:function($){this.checkIndex(this.index+$)},checkIndex:function($){if(this.length<this.zero+$||$<0)throw Error("End of data reached (data length = "+this.length+", asked index = "+$+"). Corrupted zip ?")},setIndex:function($){this.checkIndex($),this.index=$},skip:function($){this.setIndex(this.index+$)},byteAt:function(){},readInt:function($){var Q=0,J;this.checkOffset($);for(J=this.index+$-1;J>=this.index;J--)Q=(Q<<8)+this.byteAt(J);return this.index+=$,Q},readString:function($){return iU.transformTo("string",this.readData($))},readData:function(){},lastIndexOfSignature:function(){},readAndCheckSignature:function(){},readDate:function(){var $=this.readInt(4);return new Date(Date.UTC(($>>25&127)+1980,($>>21&15)-1,$>>16&31,$>>11&31,$>>5&63,($&31)<<1))}};eQ.exports=tQ});var f4=j0((cK,QJ)=>{var $J=x4(),nU=g0();function Q6($){$J.call(this,$);for(var Q=0;Q<this.data.length;Q++)$[Q]=$[Q]&255}nU.inherits(Q6,$J);Q6.prototype.byteAt=function($){return this.data[this.zero+$]};Q6.prototype.lastIndexOfSignature=function($){var Q=$.charCodeAt(0),J=$.charCodeAt(1),q=$.charCodeAt(2),X=$.charCodeAt(3);for(var Y=this.length-4;Y>=0;--Y)if(this.data[Y]===Q&&this.data[Y+1]===J&&this.data[Y+2]===q&&this.data[Y+3]===X)return Y-this.zero;return-1};Q6.prototype.readAndCheckSignature=function($){var Q=$.charCodeAt(0),J=$.charCodeAt(1),q=$.charCodeAt(2),X=$.charCodeAt(3),Y=this.readData(4);return Q===Y[0]&&J===Y[1]&&q===Y[2]&&X===Y[3]};Q6.prototype.readData=function($){if(this.checkOffset($),$===0)return[];var Q=this.data.slice(this.zero+this.index,this.zero+this.index+$);return this.index+=$,Q};QJ.exports=Q6});var XJ=j0((pK,qJ)=>{var JJ=x4(),oU=g0();function J6($){JJ.call(this,$)}oU.inherits(J6,JJ);J6.prototype.byteAt=function($){return this.data.charCodeAt(this.zero+$)};J6.prototype.lastIndexOfSignature=function($){return this.data.lastIndexOf($)-this.zero};J6.prototype.readAndCheckSignature=function($){var Q=this.readData(4);return $===Q};J6.prototype.readData=function($){this.checkOffset($);var Q=this.data.slice(this.zero+this.index,this.zero+this.index+$);return this.index+=$,Q};qJ.exports=J6});var _4=j0((lK,GJ)=>{var YJ=f4(),rU=g0();function y4($){YJ.call(this,$)}rU.inherits(y4,YJ);y4.prototype.readData=function($){if(this.checkOffset($),$===0)return new Uint8Array(0);var Q=this.data.subarray(this.zero+this.index,this.zero+this.index+$);return this.index+=$,Q};GJ.exports=y4});var WJ=j0((dK,UJ)=>{var BJ=_4(),aU=g0();function b4($){BJ.call(this,$)}aU.inherits(b4,BJ);b4.prototype.readData=function($){this.checkOffset($);var Q=this.data.slice(this.zero+this.index,this.zero+this.index+$);return this.index+=$,Q};UJ.exports=b4});var h4=j0((iK,KJ)=>{var n8=g0(),VJ=_2(),sU=f4(),tU=XJ(),eU=WJ(),$W=_4();KJ.exports=function($){var Q=n8.getTypeOf($);if(n8.checkSupport(Q),Q==="string"&&!VJ.uint8array)return new tU($);if(Q==="nodebuffer")return new eU($);if(VJ.uint8array)return new $W(n8.transformTo("uint8array",$));return new sU(n8.transformTo("array",$))}});var wJ=j0((nK,MJ)=>{var m4=h4(),q1=g0(),QW=S8(),HJ=I8(),o8=p1(),r8=T4(),JW=_2(),qW=0,XW=3,YW=function($){for(var Q in r8){if(!Object.prototype.hasOwnProperty.call(r8,Q))continue;if(r8[Q].magic===$)return r8[Q]}return null};function jJ($,Q){this.options=$,this.loadOptions=Q}jJ.prototype={isEncrypted:function(){return(this.bitFlag&1)===1},useUTF8:function(){return(this.bitFlag&2048)===2048},readLocalPart:function($){var Q,J;if($.skip(22),this.fileNameLength=$.readInt(2),J=$.readInt(2),this.fileName=$.readData(this.fileNameLength),$.skip(J),this.compressedSize===-1||this.uncompressedSize===-1)throw Error("Bug or corrupted zip : didn't get enough information from the central directory (compressedSize === -1 || uncompressedSize === -1)");if(Q=YW(this.compressionMethod),Q===null)throw Error("Corrupted zip : compression "+q1.pretty(this.compressionMethod)+" unknown (inner file : "+q1.transformTo("string",this.fileName)+")");this.decompressed=new QW(this.compressedSize,this.uncompressedSize,this.crc32,Q,$.readData(this.compressedSize))},readCentralPart:function($){this.versionMadeBy=$.readInt(2),$.skip(2),this.bitFlag=$.readInt(2),this.compressionMethod=$.readString(2),this.date=$.readDate(),this.crc32=$.readInt(4),this.compressedSize=$.readInt(4),this.uncompressedSize=$.readInt(4);var Q=$.readInt(2);if(this.extraFieldsLength=$.readInt(2),this.fileCommentLength=$.readInt(2),this.diskNumberStart=$.readInt(2),this.internalFileAttributes=$.readInt(2),this.externalFileAttributes=$.readInt(4),this.localHeaderOffset=$.readInt(4),this.isEncrypted())throw Error("Encrypted zip are not supported");$.skip(Q),this.readExtraFields($),this.parseZIP64ExtraField($),this.fileComment=$.readData(this.fileCommentLength)},processAttributes:function(){this.unixPermissions=null,this.dosPermissions=null;var $=this.versionMadeBy>>8;if(this.dir=this.externalFileAttributes&16?!0:!1,$===qW)this.dosPermissions=this.externalFileAttributes&63;if($===XW)this.unixPermissions=this.externalFileAttributes>>16&65535;if(!this.dir&&this.fileNameStr.slice(-1)==="/")this.dir=!0},parseZIP64ExtraField:function(){if(!this.extraFields[1])return;var $=m4(this.extraFields[1].value);if(this.uncompressedSize===q1.MAX_VALUE_32BITS)this.uncompressedSize=$.readInt(8);if(this.compressedSize===q1.MAX_VALUE_32BITS)this.compressedSize=$.readInt(8);if(this.localHeaderOffset===q1.MAX_VALUE_32BITS)this.localHeaderOffset=$.readInt(8);if(this.diskNumberStart===q1.MAX_VALUE_32BITS)this.diskNumberStart=$.readInt(4)},readExtraFields:function($){var Q=$.index+this.extraFieldsLength,J,q,X;if(!this.extraFields)this.extraFields={};while($.index+4<Q)J=$.readInt(2),q=$.readInt(2),X=$.readData(q),this.extraFields[J]={id:J,length:q,value:X};$.setIndex(Q)},handleUTF8:function(){var $=JW.uint8array?"uint8array":"array";if(this.useUTF8())this.fileNameStr=o8.utf8decode(this.fileName),this.fileCommentStr=o8.utf8decode(this.fileComment);else{var Q=this.findExtraFieldUnicodePath();if(Q!==null)this.fileNameStr=Q;else{var J=q1.transformTo($,this.fileName);this.fileNameStr=this.loadOptions.decodeFileName(J)}var q=this.findExtraFieldUnicodeComment();if(q!==null)this.fileCommentStr=q;else{var X=q1.transformTo($,this.fileComment);this.fileCommentStr=this.loadOptions.decodeFileName(X)}}},findExtraFieldUnicodePath:function(){var $=this.extraFields[28789];if($){var Q=m4($.value);if(Q.readInt(1)!==1)return null;if(HJ(this.fileName)!==Q.readInt(4))return null;return o8.utf8decode(Q.readData($.length-5))}return null},findExtraFieldUnicodeComment:function(){var $=this.extraFields[25461];if($){var Q=m4($.value);if(Q.readInt(1)!==1)return null;if(HJ(this.fileComment)!==Q.readInt(4))return null;return o8.utf8decode(Q.readData($.length-5))}return null}};MJ.exports=jJ});var zJ=j0((oK,LJ)=>{var GW=h4(),u2=g0(),K2=Z4(),BW=wJ(),UW=_2();function FJ($){this.files=[],this.loadOptions=$}FJ.prototype={checkSignature:function($){if(!this.reader.readAndCheckSignature($)){this.reader.index-=4;var Q=this.reader.readString(4);throw Error("Corrupted zip or bug: unexpected signature ("+u2.pretty(Q)+", expected "+u2.pretty($)+")")}},isSignature:function($,Q){var J=this.reader.index;this.reader.setIndex($);var q=this.reader.readString(4),X=q===Q;return this.reader.setIndex(J),X},readBlockEndOfCentral:function(){this.diskNumber=this.reader.readInt(2),this.diskWithCentralDirStart=this.reader.readInt(2),this.centralDirRecordsOnThisDisk=this.reader.readInt(2),this.centralDirRecords=this.reader.readInt(2),this.centralDirSize=this.reader.readInt(4),this.centralDirOffset=this.reader.readInt(4),this.zipCommentLength=this.reader.readInt(2);var $=this.reader.readData(this.zipCommentLength),Q=UW.uint8array?"uint8array":"array",J=u2.transformTo(Q,$);this.zipComment=this.loadOptions.decodeFileName(J)},readBlockZip64EndOfCentral:function(){this.zip64EndOfCentralSize=this.reader.readInt(8),this.reader.skip(4),this.diskNumber=this.reader.readInt(4),this.diskWithCentralDirStart=this.reader.readInt(4),this.centralDirRecordsOnThisDisk=this.reader.readInt(8),this.centralDirRecords=this.reader.readInt(8),this.centralDirSize=this.reader.readInt(8),this.centralDirOffset=this.reader.readInt(8),this.zip64ExtensibleData={};var $=this.zip64EndOfCentralSize-44,Q=0,J,q,X;while(Q<$)J=this.reader.readInt(2),q=this.reader.readInt(4),X=this.reader.readData(q),this.zip64ExtensibleData[J]={id:J,length:q,value:X}},readBlockZip64EndOfCentralLocator:function(){if(this.diskWithZip64CentralDirStart=this.reader.readInt(4),this.relativeOffsetEndOfZip64CentralDir=this.reader.readInt(8),this.disksCount=this.reader.readInt(4),this.disksCount>1)throw Error("Multi-volumes zip are not supported")},readLocalFiles:function(){var $,Q;for($=0;$<this.files.length;$++)Q=this.files[$],this.reader.setIndex(Q.localHeaderOffset),this.checkSignature(K2.LOCAL_FILE_HEADER),Q.readLocalPart(this.reader),Q.handleUTF8(),Q.processAttributes()},readCentralDir:function(){var $;this.reader.setIndex(this.centralDirOffset);while(this.reader.readAndCheckSignature(K2.CENTRAL_FILE_HEADER))$=new BW({zip64:this.zip64},this.loadOptions),$.readCentralPart(this.reader),this.files.push($);if(this.centralDirRecords!==this.files.length){if(this.centralDirRecords!==0&&this.files.length===0)throw Error("Corrupted zip or bug: expected "+this.centralDirRecords+" records in central dir, got "+this.files.length)}},readEndOfCentral:function(){var $=this.reader.lastIndexOfSignature(K2.CENTRAL_DIRECTORY_END);if($<0){var Q=!this.isSignature(0,K2.LOCAL_FILE_HEADER);if(Q)throw Error("Can't find end of central directory : is this a zip file ? If it is, see https://stuk.github.io/jszip/documentation/howto/read_zip.html");else throw Error("Corrupted zip: can't find end of central directory")}this.reader.setIndex($);var J=$;if(this.checkSignature(K2.CENTRAL_DIRECTORY_END),this.readBlockEndOfCentral(),this.diskNumber===u2.MAX_VALUE_16BITS||this.diskWithCentralDirStart===u2.MAX_VALUE_16BITS||this.centralDirRecordsOnThisDisk===u2.MAX_VALUE_16BITS||this.centralDirRecords===u2.MAX_VALUE_16BITS||this.centralDirSize===u2.MAX_VALUE_32BITS||this.centralDirOffset===u2.MAX_VALUE_32BITS){if(this.zip64=!0,$=this.reader.lastIndexOfSignature(K2.ZIP64_CENTRAL_DIRECTORY_LOCATOR),$<0)throw Error("Corrupted zip: can't find the ZIP64 end of central directory locator");if(this.reader.setIndex($),this.checkSignature(K2.ZIP64_CENTRAL_DIRECTORY_LOCATOR),this.readBlockZip64EndOfCentralLocator(),!this.isSignature(this.relativeOffsetEndOfZip64CentralDir,K2.ZIP64_CENTRAL_DIRECTORY_END)){if(this.relativeOffsetEndOfZip64CentralDir=this.reader.lastIndexOfSignature(K2.ZIP64_CENTRAL_DIRECTORY_END),this.relativeOffsetEndOfZip64CentralDir<0)throw Error("Corrupted zip: can't find the ZIP64 end of central directory")}this.reader.setIndex(this.relativeOffsetEndOfZip64CentralDir),this.checkSignature(K2.ZIP64_CENTRAL_DIRECTORY_END),this.readBlockZip64EndOfCentral()}var q=this.centralDirOffset+this.centralDirSize;if(this.zip64)q+=20,q+=12+this.zip64EndOfCentralSize;var X=J-q;if(X>0)if(this.isSignature(J,K2.CENTRAL_FILE_HEADER));else this.reader.zero=X;else if(X<0)throw Error("Corrupted zip: missing "+Math.abs(X)+" bytes.")},prepareReader:function($){this.reader=GW($)},load:function($){this.prepareReader($),this.readEndOfCentral(),this.readCentralDir(),this.readLocalFiles()}};LJ.exports=FJ});var AJ=j0((rK,NJ)=>{var u4=g0(),a8=m1(),WW=p1(),VW=zJ(),KW=u5(),OJ=E6();function HW($){return new a8.Promise(function(Q,J){var q=$.decompressed.getContentWorker().pipe(new KW);q.on("error",function(X){J(X)}).on("end",function(){if(q.streamInfo.crc32!==$.decompressed.crc32)J(Error("Corrupted zip : CRC32 mismatch"));else Q()}).resume()})}NJ.exports=function($,Q){var J=this;if(Q=u4.extend(Q||{},{base64:!1,checkCRC32:!1,optimizedBinaryString:!1,createFolders:!1,decodeFileName:WW.utf8decode}),OJ.isNode&&OJ.isStream($))return a8.Promise.reject(Error("JSZip can't accept a stream when loading a zip file."));return u4.prepareContent("the loaded zip file",$,!0,Q.optimizedBinaryString,Q.base64).then(function(q){var X=new VW(Q);return X.load(q),X}).then(function(X){var Y=[a8.Promise.resolve(X)],G=X.files;if(Q.checkCRC32)for(var B=0;B<G.length;B++)Y.push(HW(G[B]));return a8.Promise.all(Y)}).then(function(X){var Y=X.shift(),G=Y.files;for(var B=0;B<G.length;B++){var W=G[B],U=W.fileNameStr,V=u4.resolve(W.fileNameStr);if(J.file(V,W.decompressed,{binary:!0,optimizedBinaryString:!0,date:W.date,dir:W.dir,comment:W.fileCommentStr.length?W.fileCommentStr:null,unixPermissions:W.unixPermissions,dosPermissions:W.dosPermissions,createFolders:Q.createFolders}),!W.dir)J.file(V).unsafeOriginalName=U}if(Y.zipComment.length)J.comment=Y.zipComment;return J})}});var PJ=j0((aK,DJ)=>{function U2(){if(!(this instanceof U2))return new U2;if(arguments.length)throw Error("The constructor with parameters has been removed in JSZip 3.0, please check the upgrade guide.");this.files=Object.create(null),this.comment=null,this.root="",this.clone=function(){var $=new U2;for(var Q in this)if(typeof this[Q]!=="function")$[Q]=this[Q];return $}}U2.prototype=sQ();U2.prototype.loadAsync=AJ();U2.support=_2();U2.defaults=b5();U2.version="3.10.1";U2.loadAsync=function($,Q){return new U2().loadAsync($,Q)};U2.external=m1();DJ.exports=U2});var _J=j0((n4)=>{/*! crc32.js (C) 2014-present SheetJS -- http://sheetjs.com */var yJ;(function($){if(typeof DO_NOT_EXPORT_CRC>"u")if(typeof n4==="object")$(n4);else if(typeof define==="function"&&define.amd)define(function(){var Q={};return $(Q),Q});else $(yJ={});else $(yJ={})})(function($){$.version="1.2.2";function Q(){var T=0,l=Array(256);for(var S=0;S!=256;++S)T=S,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,T=T&1?-2097792136^T>>>1:T>>>1,l[S]=T;return typeof Int32Array<"u"?new Int32Array(l):l}var J=Q();function q(T){var l=0,S=0,E=0,P=typeof Int32Array<"u"?new Int32Array(4096):Array(4096);for(E=0;E!=256;++E)P[E]=T[E];for(E=0;E!=256;++E){S=T[E];for(l=256+E;l<4096;l+=256)S=P[l]=S>>>8^T[S&255]}var O=[];for(E=1;E!=16;++E)O[E-1]=typeof Int32Array<"u"?P.subarray(E*256,E*256+256):P.slice(E*256,E*256+256);return O}var X=q(J),Y=X[0],G=X[1],B=X[2],W=X[3],U=X[4],V=X[5],L=X[6],w=X[7],M=X[8],y=X[9],x=X[10],A=X[11],D=X[12],K=X[13],F=X[14];function z(T,l){var S=l^-1;for(var E=0,P=T.length;E<P;)S=S>>>8^J[(S^T.charCodeAt(E++))&255];return~S}function R(T,l){var S=l^-1,E=T.length-15,P=0;for(;P<E;)S=F[T[P++]^S&255]^K[T[P++]^S>>8&255]^D[T[P++]^S>>16&255]^A[T[P++]^S>>>24]^x[T[P++]]^y[T[P++]]^M[T[P++]]^w[T[P++]]^L[T[P++]]^V[T[P++]]^U[T[P++]]^W[T[P++]]^B[T[P++]]^G[T[P++]]^Y[T[P++]]^J[T[P++]];E+=15;while(P<E)S=S>>>8^J[(S^T[P++])&255];return~S}function _(T,l){var S=l^-1;for(var E=0,P=T.length,O=0,Z=0;E<P;)if(O=T.charCodeAt(E++),O<128)S=S>>>8^J[(S^O)&255];else if(O<2048)S=S>>>8^J[(S^(192|O>>6&31))&255],S=S>>>8^J[(S^(128|O&63))&255];else if(O>=55296&&O<57344)O=(O&1023)+64,Z=T.charCodeAt(E++)&1023,S=S>>>8^J[(S^(240|O>>8&7))&255],S=S>>>8^J[(S^(128|O>>2&63))&255],S=S>>>8^J[(S^(128|Z>>6&15|(O&3)<<4))&255],S=S>>>8^J[(S^(128|Z&63))&255];else S=S>>>8^J[(S^(224|O>>12&15))&255],S=S>>>8^J[(S^(128|O>>6&63))&255],S=S>>>8^J[(S^(128|O&63))&255];return~S}$.table=J,$.bstr=z,$.buf=R,$.str=_})});var pJ=V7(PJ(),1);var jW=new Uint8Array(16);function c4(){return crypto.getRandomValues(jW)}var h0=[];for(let $=0;$<256;++$)h0.push(($+256).toString(16).slice(1));function RJ($,Q=0){return(h0[$[Q+0]]+h0[$[Q+1]]+h0[$[Q+2]]+h0[$[Q+3]]+"-"+h0[$[Q+4]]+h0[$[Q+5]]+"-"+h0[$[Q+6]]+h0[$[Q+7]]+"-"+h0[$[Q+8]]+h0[$[Q+9]]+"-"+h0[$[Q+10]]+h0[$[Q+11]]+h0[$[Q+12]]+h0[$[Q+13]]+h0[$[Q+14]]+h0[$[Q+15]]).toLowerCase()}function MW($,Q,J){if(!Q&&!$&&crypto.randomUUID)return crypto.randomUUID();return wW($,Q,J)}function wW($,Q,J){$=$||{};let q=$.random??$.rng?.()??c4();if(q.length<16)throw Error("Random bytes length must be >= 16");if(q[6]=q[6]&15|64,q[8]=q[8]&63|128,Q){if(J=J||0,J<0||J+16>Q.length)throw RangeError(`UUID byte range ${J}:${J+15} is out of buffer bounds`);for(let X=0;X<16;++X)Q[J+X]=q[X];return Q}return RJ(q)}var q6=MW;var g={};B5(g,{void:()=>eW,util:()=>R0,unknown:()=>sW,union:()=>qV,undefined:()=>oW,tuple:()=>GV,transformer:()=>FV,symbol:()=>nW,string:()=>gJ,strictObject:()=>JV,setErrorMap:()=>zW,set:()=>WV,record:()=>BV,quotelessJson:()=>FW,promise:()=>wV,preprocess:()=>OV,pipeline:()=>NV,ostring:()=>AV,optional:()=>LV,onumber:()=>DV,oboolean:()=>PV,objectUtil:()=>p4,object:()=>QV,number:()=>xJ,nullable:()=>zV,null:()=>rW,never:()=>tW,nativeEnum:()=>MV,nan:()=>lW,map:()=>UV,makeIssue:()=>t6,literal:()=>HV,lazy:()=>KV,late:()=>cW,isValid:()=>X1,isDirty:()=>t8,isAsync:()=>Y6,isAborted:()=>s8,intersection:()=>YV,instanceof:()=>pW,getParsedType:()=>S2,getErrorMap:()=>X6,function:()=>VV,enum:()=>jV,effect:()=>FV,discriminatedUnion:()=>XV,defaultErrorMap:()=>c2,datetimeRegex:()=>kJ,date:()=>iW,custom:()=>ZJ,coerce:()=>RV,boolean:()=>fJ,bigint:()=>dW,array:()=>$V,any:()=>aW,addIssueToContext:()=>X0,ZodVoid:()=>$8,ZodUnknown:()=>Y1,ZodUnion:()=>K6,ZodUndefined:()=>W6,ZodType:()=>D0,ZodTuple:()=>v2,ZodTransformer:()=>F2,ZodSymbol:()=>e6,ZodString:()=>H2,ZodSet:()=>Z1,ZodSchema:()=>D0,ZodRecord:()=>Q8,ZodReadonly:()=>z6,ZodPromise:()=>g1,ZodPipeline:()=>X8,ZodParsedType:()=>$0,ZodOptional:()=>M2,ZodObject:()=>x0,ZodNumber:()=>G1,ZodNullable:()=>l2,ZodNull:()=>V6,ZodNever:()=>E2,ZodNativeEnum:()=>w6,ZodNaN:()=>q8,ZodMap:()=>J8,ZodLiteral:()=>M6,ZodLazy:()=>j6,ZodIssueCode:()=>o,ZodIntersection:()=>H6,ZodFunction:()=>B6,ZodFirstPartyTypeKind:()=>F0,ZodError:()=>s0,ZodEnum:()=>U1,ZodEffects:()=>F2,ZodDiscriminatedUnion:()=>e8,ZodDefault:()=>F6,ZodDate:()=>k1,ZodCatch:()=>L6,ZodBranded:()=>$5,ZodBoolean:()=>U6,ZodBigInt:()=>B1,ZodArray:()=>j2,ZodAny:()=>T1,Schema:()=>D0,ParseStatus:()=>m0,OK:()=>l0,NEVER:()=>CV,INVALID:()=>w0,EMPTY_PATH:()=>OW,DIRTY:()=>v1,BRAND:()=>uW});var R0;(function($){$.assertEqual=(X)=>{};function Q(X){}$.assertIs=Q;function J(X){throw Error()}$.assertNever=J,$.arrayToEnum=(X)=>{let Y={};for(let G of X)Y[G]=G;return Y},$.getValidEnumValues=(X)=>{let Y=$.objectKeys(X).filter((B)=>typeof X[X[B]]!=="number"),G={};for(let B of Y)G[B]=X[B];return $.objectValues(G)},$.objectValues=(X)=>{return $.objectKeys(X).map(function(Y){return X[Y]})},$.objectKeys=typeof Object.keys==="function"?(X)=>Object.keys(X):(X)=>{let Y=[];for(let G in X)if(Object.prototype.hasOwnProperty.call(X,G))Y.push(G);return Y},$.find=(X,Y)=>{for(let G of X)if(Y(G))return G;return},$.isInteger=typeof Number.isInteger==="function"?(X)=>Number.isInteger(X):(X)=>typeof X==="number"&&Number.isFinite(X)&&Math.floor(X)===X;function q(X,Y=" | "){return X.map((G)=>typeof G==="string"?`'${G}'`:G).join(Y)}$.joinValues=q,$.jsonStringifyReplacer=(X,Y)=>{if(typeof Y==="bigint")return Y.toString();return Y}})(R0||(R0={}));var p4;(function($){$.mergeShapes=(Q,J)=>{return{...Q,...J}}})(p4||(p4={}));var $0=R0.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),S2=($)=>{switch(typeof $){case"undefined":return $0.undefined;case"string":return $0.string;case"number":return Number.isNaN($)?$0.nan:$0.number;case"boolean":return $0.boolean;case"function":return $0.function;case"bigint":return $0.bigint;case"symbol":return $0.symbol;case"object":if(Array.isArray($))return $0.array;if($===null)return $0.null;if($.then&&typeof $.then==="function"&&$.catch&&typeof $.catch==="function")return $0.promise;if(typeof Map<"u"&&$ instanceof Map)return $0.map;if(typeof Set<"u"&&$ instanceof Set)return $0.set;if(typeof Date<"u"&&$ instanceof Date)return $0.date;return $0.object;default:return $0.unknown}};var o=R0.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]),FW=($)=>{return JSON.stringify($,null,2).replace(/"([^"]+)":/g,"$1:")};class s0 extends Error{get errors(){return this.issues}constructor($){super();this.issues=[],this.addIssue=(J)=>{this.issues=[...this.issues,J]},this.addIssues=(J=[])=>{this.issues=[...this.issues,...J]};let Q=new.target.prototype;if(Object.setPrototypeOf)Object.setPrototypeOf(this,Q);else this.__proto__=Q;this.name="ZodError",this.issues=$}format($){let Q=$||function(X){return X.message},J={_errors:[]},q=(X)=>{for(let Y of X.issues)if(Y.code==="invalid_union")Y.unionErrors.map(q);else if(Y.code==="invalid_return_type")q(Y.returnTypeError);else if(Y.code==="invalid_arguments")q(Y.argumentsError);else if(Y.path.length===0)J._errors.push(Q(Y));else{let G=J,B=0;while(B<Y.path.length){let W=Y.path[B];if(B!==Y.path.length-1)G[W]=G[W]||{_errors:[]};else G[W]=G[W]||{_errors:[]},G[W]._errors.push(Q(Y));G=G[W],B++}}};return q(this),J}static assert($){if(!($ instanceof s0))throw Error(`Not a ZodError: ${$}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,R0.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten($=(Q)=>Q.message){let Q={},J=[];for(let q of this.issues)if(q.path.length>0){let X=q.path[0];Q[X]=Q[X]||[],Q[X].push($(q))}else J.push($(q));return{formErrors:J,fieldErrors:Q}}get formErrors(){return this.flatten()}}s0.create=($)=>{return new s0($)};var LW=($,Q)=>{let J;switch($.code){case o.invalid_type:if($.received===$0.undefined)J="Required";else J=`Expected ${$.expected}, received ${$.received}`;break;case o.invalid_literal:J=`Invalid literal value, expected ${JSON.stringify($.expected,R0.jsonStringifyReplacer)}`;break;case o.unrecognized_keys:J=`Unrecognized key(s) in object: ${R0.joinValues($.keys,", ")}`;break;case o.invalid_union:J="Invalid input";break;case o.invalid_union_discriminator:J=`Invalid discriminator value. Expected ${R0.joinValues($.options)}`;break;case o.invalid_enum_value:J=`Invalid enum value. Expected ${R0.joinValues($.options)}, received '${$.received}'`;break;case o.invalid_arguments:J="Invalid function arguments";break;case o.invalid_return_type:J="Invalid function return type";break;case o.invalid_date:J="Invalid date";break;case o.invalid_string:if(typeof $.validation==="object")if("includes"in $.validation){if(J=`Invalid input: must include "${$.validation.includes}"`,typeof $.validation.position==="number")J=`${J} at one or more positions greater than or equal to ${$.validation.position}`}else if("startsWith"in $.validation)J=`Invalid input: must start with "${$.validation.startsWith}"`;else if("endsWith"in $.validation)J=`Invalid input: must end with "${$.validation.endsWith}"`;else R0.assertNever($.validation);else if($.validation!=="regex")J=`Invalid ${$.validation}`;else J="Invalid";break;case o.too_small:if($.type==="array")J=`Array must contain ${$.exact?"exactly":$.inclusive?"at least":"more than"} ${$.minimum} element(s)`;else if($.type==="string")J=`String must contain ${$.exact?"exactly":$.inclusive?"at least":"over"} ${$.minimum} character(s)`;else if($.type==="number")J=`Number must be ${$.exact?"exactly equal to ":$.inclusive?"greater than or equal to ":"greater than "}${$.minimum}`;else if($.type==="bigint")J=`Number must be ${$.exact?"exactly equal to ":$.inclusive?"greater than or equal to ":"greater than "}${$.minimum}`;else if($.type==="date")J=`Date must be ${$.exact?"exactly equal to ":$.inclusive?"greater than or equal to ":"greater than "}${new Date(Number($.minimum))}`;else J="Invalid input";break;case o.too_big:if($.type==="array")J=`Array must contain ${$.exact?"exactly":$.inclusive?"at most":"less than"} ${$.maximum} element(s)`;else if($.type==="string")J=`String must contain ${$.exact?"exactly":$.inclusive?"at most":"under"} ${$.maximum} character(s)`;else if($.type==="number")J=`Number must be ${$.exact?"exactly":$.inclusive?"less than or equal to":"less than"} ${$.maximum}`;else if($.type==="bigint")J=`BigInt must be ${$.exact?"exactly":$.inclusive?"less than or equal to":"less than"} ${$.maximum}`;else if($.type==="date")J=`Date must be ${$.exact?"exactly":$.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number($.maximum))}`;else J="Invalid input";break;case o.custom:J="Invalid input";break;case o.invalid_intersection_types:J="Intersection results could not be merged";break;case o.not_multiple_of:J=`Number must be a multiple of ${$.multipleOf}`;break;case o.not_finite:J="Number must be finite";break;default:J=Q.defaultError,R0.assertNever($)}return{message:J}},c2=LW;var CJ=c2;function zW($){CJ=$}function X6(){return CJ}var t6=($)=>{let{data:Q,path:J,errorMaps:q,issueData:X}=$,Y=[...J,...X.path||[]],G={...X,path:Y};if(X.message!==void 0)return{...X,path:Y,message:X.message};let B="",W=q.filter((U)=>!!U).slice().reverse();for(let U of W)B=U(G,{data:Q,defaultError:B}).message;return{...X,path:Y,message:B}},OW=[];function X0($,Q){let J=X6(),q=t6({issueData:Q,data:$.data,path:$.path,errorMaps:[$.common.contextualErrorMap,$.schemaErrorMap,J,J===c2?void 0:c2].filter((X)=>!!X)});$.common.issues.push(q)}class m0{constructor(){this.value="valid"}dirty(){if(this.value==="valid")this.value="dirty"}abort(){if(this.value!=="aborted")this.value="aborted"}static mergeArray($,Q){let J=[];for(let q of Q){if(q.status==="aborted")return w0;if(q.status==="dirty")$.dirty();J.push(q.value)}return{status:$.value,value:J}}static async mergeObjectAsync($,Q){let J=[];for(let q of Q){let X=await q.key,Y=await q.value;J.push({key:X,value:Y})}return m0.mergeObjectSync($,J)}static mergeObjectSync($,Q){let J={};for(let q of Q){let{key:X,value:Y}=q;if(X.status==="aborted")return w0;if(Y.status==="aborted")return w0;if(X.status==="dirty")$.dirty();if(Y.status==="dirty")$.dirty();if(X.value!=="__proto__"&&(typeof Y.value<"u"||q.alwaysSet))J[X.value]=Y.value}return{status:$.value,value:J}}}var w0=Object.freeze({status:"aborted"}),v1=($)=>({status:"dirty",value:$}),l0=($)=>({status:"valid",value:$}),s8=($)=>$.status==="aborted",t8=($)=>$.status==="dirty",X1=($)=>$.status==="valid",Y6=($)=>typeof Promise<"u"&&$ instanceof Promise;var V0;(function($){$.errToObj=(Q)=>typeof Q==="string"?{message:Q}:Q||{},$.toString=(Q)=>typeof Q==="string"?Q:Q?.message})(V0||(V0={}));class w2{constructor($,Q,J,q){this._cachedPath=[],this.parent=$,this.data=Q,this._path=J,this._key=q}get path(){if(!this._cachedPath.length)if(Array.isArray(this._key))this._cachedPath.push(...this._path,...this._key);else this._cachedPath.push(...this._path,this._key);return this._cachedPath}}var IJ=($,Q)=>{if(X1(Q))return{success:!0,data:Q.value};else{if(!$.common.issues.length)throw Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let J=new s0($.common.issues);return this._error=J,this._error}}}};function A0($){if(!$)return{};let{errorMap:Q,invalid_type_error:J,required_error:q,description:X}=$;if(Q&&(J||q))throw Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);if(Q)return{errorMap:Q,description:X};return{errorMap:(G,B)=>{let{message:W}=$;if(G.code==="invalid_enum_value")return{message:W??B.defaultError};if(typeof B.data>"u")return{message:W??q??B.defaultError};if(G.code!=="invalid_type")return{message:B.defaultError};return{message:W??J??B.defaultError}},description:X}}class D0{get description(){return this._def.description}_getType($){return S2($.data)}_getOrReturnCtx($,Q){return Q||{common:$.parent.common,data:$.data,parsedType:S2($.data),schemaErrorMap:this._def.errorMap,path:$.path,parent:$.parent}}_processInputParams($){return{status:new m0,ctx:{common:$.parent.common,data:$.data,parsedType:S2($.data),schemaErrorMap:this._def.errorMap,path:$.path,parent:$.parent}}}_parseSync($){let Q=this._parse($);if(Y6(Q))throw Error("Synchronous parse encountered promise.");return Q}_parseAsync($){let Q=this._parse($);return Promise.resolve(Q)}parse($,Q){let J=this.safeParse($,Q);if(J.success)return J.data;throw J.error}safeParse($,Q){let J={common:{issues:[],async:Q?.async??!1,contextualErrorMap:Q?.errorMap},path:Q?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:$,parsedType:S2($)},q=this._parseSync({data:$,path:J.path,parent:J});return IJ(J,q)}"~validate"($){let Q={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:$,parsedType:S2($)};if(!this["~standard"].async)try{let J=this._parseSync({data:$,path:[],parent:Q});return X1(J)?{value:J.value}:{issues:Q.common.issues}}catch(J){if(J?.message?.toLowerCase()?.includes("encountered"))this["~standard"].async=!0;Q.common={issues:[],async:!0}}return this._parseAsync({data:$,path:[],parent:Q}).then((J)=>X1(J)?{value:J.value}:{issues:Q.common.issues})}async parseAsync($,Q){let J=await this.safeParseAsync($,Q);if(J.success)return J.data;throw J.error}async safeParseAsync($,Q){let J={common:{issues:[],contextualErrorMap:Q?.errorMap,async:!0},path:Q?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:$,parsedType:S2($)},q=this._parse({data:$,path:J.path,parent:J}),X=await(Y6(q)?q:Promise.resolve(q));return IJ(J,X)}refine($,Q){let J=(q)=>{if(typeof Q==="string"||typeof Q>"u")return{message:Q};else if(typeof Q==="function")return Q(q);else return Q};return this._refinement((q,X)=>{let Y=$(q),G=()=>X.addIssue({code:o.custom,...J(q)});if(typeof Promise<"u"&&Y instanceof Promise)return Y.then((B)=>{if(!B)return G(),!1;else return!0});if(!Y)return G(),!1;else return!0})}refinement($,Q){return this._refinement((J,q)=>{if(!$(J))return q.addIssue(typeof Q==="function"?Q(J,q):Q),!1;else return!0})}_refinement($){return new F2({schema:this,typeName:F0.ZodEffects,effect:{type:"refinement",refinement:$}})}superRefine($){return this._refinement($)}constructor($){this.spa=this.safeParseAsync,this._def=$,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:(Q)=>this["~validate"](Q)}}optional(){return M2.create(this,this._def)}nullable(){return l2.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return j2.create(this)}promise(){return g1.create(this,this._def)}or($){return K6.create([this,$],this._def)}and($){return H6.create(this,$,this._def)}transform($){return new F2({...A0(this._def),schema:this,typeName:F0.ZodEffects,effect:{type:"transform",transform:$}})}default($){let Q=typeof $==="function"?$:()=>$;return new F6({...A0(this._def),innerType:this,defaultValue:Q,typeName:F0.ZodDefault})}brand(){return new $5({typeName:F0.ZodBranded,type:this,...A0(this._def)})}catch($){let Q=typeof $==="function"?$:()=>$;return new L6({...A0(this._def),innerType:this,catchValue:Q,typeName:F0.ZodCatch})}describe($){return new this.constructor({...this._def,description:$})}pipe($){return X8.create(this,$)}readonly(){return z6.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}var NW=/^c[^\s-]{8,}$/i,AW=/^[0-9a-z]+$/,DW=/^[0-9A-HJKMNP-TV-Z]{26}$/i,PW=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,RW=/^[a-z0-9_-]{21}$/i,CW=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,IW=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,SW=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,EW="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$",l4,vW=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,kW=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,TW=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,ZW=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,gW=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,xW=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,EJ="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",fW=new RegExp(`^${EJ}$`);function vJ($){let Q="[0-5]\\d";if($.precision)Q=`${Q}\\.\\d{${$.precision}}`;else if($.precision==null)Q=`${Q}(\\.\\d+)?`;let J=$.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${Q})${J}`}function yW($){return new RegExp(`^${vJ($)}$`)}function kJ($){let Q=`${EJ}T${vJ($)}`,J=[];if(J.push($.local?"Z?":"Z"),$.offset)J.push("([+-]\\d{2}:?\\d{2})");return Q=`${Q}(${J.join("|")})`,new RegExp(`^${Q}$`)}function _W($,Q){if((Q==="v4"||!Q)&&vW.test($))return!0;if((Q==="v6"||!Q)&&TW.test($))return!0;return!1}function bW($,Q){if(!CW.test($))return!1;try{let[J]=$.split(".");if(!J)return!1;let q=J.replace(/-/g,"+").replace(/_/g,"/").padEnd(J.length+(4-J.length%4)%4,"="),X=JSON.parse(atob(q));if(typeof X!=="object"||X===null)return!1;if("typ"in X&&X?.typ!=="JWT")return!1;if(!X.alg)return!1;if(Q&&X.alg!==Q)return!1;return!0}catch{return!1}}function hW($,Q){if((Q==="v4"||!Q)&&kW.test($))return!0;if((Q==="v6"||!Q)&&ZW.test($))return!0;return!1}class H2 extends D0{_parse($){if(this._def.coerce)$.data=String($.data);if(this._getType($)!==$0.string){let X=this._getOrReturnCtx($);return X0(X,{code:o.invalid_type,expected:$0.string,received:X.parsedType}),w0}let J=new m0,q=void 0;for(let X of this._def.checks)if(X.kind==="min"){if($.data.length<X.value)q=this._getOrReturnCtx($,q),X0(q,{code:o.too_small,minimum:X.value,type:"string",inclusive:!0,exact:!1,message:X.message}),J.dirty()}else if(X.kind==="max"){if($.data.length>X.value)q=this._getOrReturnCtx($,q),X0(q,{code:o.too_big,maximum:X.value,type:"string",inclusive:!0,exact:!1,message:X.message}),J.dirty()}else if(X.kind==="length"){let Y=$.data.length>X.value,G=$.data.length<X.value;if(Y||G){if(q=this._getOrReturnCtx($,q),Y)X0(q,{code:o.too_big,maximum:X.value,type:"string",inclusive:!0,exact:!0,message:X.message});else if(G)X0(q,{code:o.too_small,minimum:X.value,type:"string",inclusive:!0,exact:!0,message:X.message});J.dirty()}}else if(X.kind==="email"){if(!SW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"email",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="emoji"){if(!l4)l4=new RegExp(EW,"u");if(!l4.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"emoji",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="uuid"){if(!PW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"uuid",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="nanoid"){if(!RW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"nanoid",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="cuid"){if(!NW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"cuid",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="cuid2"){if(!AW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"cuid2",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="ulid"){if(!DW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"ulid",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="url")try{new URL($.data)}catch{q=this._getOrReturnCtx($,q),X0(q,{validation:"url",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="regex"){if(X.regex.lastIndex=0,!X.regex.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"regex",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="trim")$.data=$.data.trim();else if(X.kind==="includes"){if(!$.data.includes(X.value,X.position))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:{includes:X.value,position:X.position},message:X.message}),J.dirty()}else if(X.kind==="toLowerCase")$.data=$.data.toLowerCase();else if(X.kind==="toUpperCase")$.data=$.data.toUpperCase();else if(X.kind==="startsWith"){if(!$.data.startsWith(X.value))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:{startsWith:X.value},message:X.message}),J.dirty()}else if(X.kind==="endsWith"){if(!$.data.endsWith(X.value))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:{endsWith:X.value},message:X.message}),J.dirty()}else if(X.kind==="datetime"){if(!kJ(X).test($.data))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:"datetime",message:X.message}),J.dirty()}else if(X.kind==="date"){if(!fW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:"date",message:X.message}),J.dirty()}else if(X.kind==="time"){if(!yW(X).test($.data))q=this._getOrReturnCtx($,q),X0(q,{code:o.invalid_string,validation:"time",message:X.message}),J.dirty()}else if(X.kind==="duration"){if(!IW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"duration",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="ip"){if(!_W($.data,X.version))q=this._getOrReturnCtx($,q),X0(q,{validation:"ip",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="jwt"){if(!bW($.data,X.alg))q=this._getOrReturnCtx($,q),X0(q,{validation:"jwt",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="cidr"){if(!hW($.data,X.version))q=this._getOrReturnCtx($,q),X0(q,{validation:"cidr",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="base64"){if(!gW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"base64",code:o.invalid_string,message:X.message}),J.dirty()}else if(X.kind==="base64url"){if(!xW.test($.data))q=this._getOrReturnCtx($,q),X0(q,{validation:"base64url",code:o.invalid_string,message:X.message}),J.dirty()}else R0.assertNever(X);return{status:J.value,value:$.data}}_regex($,Q,J){return this.refinement((q)=>$.test(q),{validation:Q,code:o.invalid_string,...V0.errToObj(J)})}_addCheck($){return new H2({...this._def,checks:[...this._def.checks,$]})}email($){return this._addCheck({kind:"email",...V0.errToObj($)})}url($){return this._addCheck({kind:"url",...V0.errToObj($)})}emoji($){return this._addCheck({kind:"emoji",...V0.errToObj($)})}uuid($){return this._addCheck({kind:"uuid",...V0.errToObj($)})}nanoid($){return this._addCheck({kind:"nanoid",...V0.errToObj($)})}cuid($){return this._addCheck({kind:"cuid",...V0.errToObj($)})}cuid2($){return this._addCheck({kind:"cuid2",...V0.errToObj($)})}ulid($){return this._addCheck({kind:"ulid",...V0.errToObj($)})}base64($){return this._addCheck({kind:"base64",...V0.errToObj($)})}base64url($){return this._addCheck({kind:"base64url",...V0.errToObj($)})}jwt($){return this._addCheck({kind:"jwt",...V0.errToObj($)})}ip($){return this._addCheck({kind:"ip",...V0.errToObj($)})}cidr($){return this._addCheck({kind:"cidr",...V0.errToObj($)})}datetime($){if(typeof $==="string")return this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:$});return this._addCheck({kind:"datetime",precision:typeof $?.precision>"u"?null:$?.precision,offset:$?.offset??!1,local:$?.local??!1,...V0.errToObj($?.message)})}date($){return this._addCheck({kind:"date",message:$})}time($){if(typeof $==="string")return this._addCheck({kind:"time",precision:null,message:$});return this._addCheck({kind:"time",precision:typeof $?.precision>"u"?null:$?.precision,...V0.errToObj($?.message)})}duration($){return this._addCheck({kind:"duration",...V0.errToObj($)})}regex($,Q){return this._addCheck({kind:"regex",regex:$,...V0.errToObj(Q)})}includes($,Q){return this._addCheck({kind:"includes",value:$,position:Q?.position,...V0.errToObj(Q?.message)})}startsWith($,Q){return this._addCheck({kind:"startsWith",value:$,...V0.errToObj(Q)})}endsWith($,Q){return this._addCheck({kind:"endsWith",value:$,...V0.errToObj(Q)})}min($,Q){return this._addCheck({kind:"min",value:$,...V0.errToObj(Q)})}max($,Q){return this._addCheck({kind:"max",value:$,...V0.errToObj(Q)})}length($,Q){return this._addCheck({kind:"length",value:$,...V0.errToObj(Q)})}nonempty($){return this.min(1,V0.errToObj($))}trim(){return new H2({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new H2({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new H2({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(($)=>$.kind==="datetime")}get isDate(){return!!this._def.checks.find(($)=>$.kind==="date")}get isTime(){return!!this._def.checks.find(($)=>$.kind==="time")}get isDuration(){return!!this._def.checks.find(($)=>$.kind==="duration")}get isEmail(){return!!this._def.checks.find(($)=>$.kind==="email")}get isURL(){return!!this._def.checks.find(($)=>$.kind==="url")}get isEmoji(){return!!this._def.checks.find(($)=>$.kind==="emoji")}get isUUID(){return!!this._def.checks.find(($)=>$.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(($)=>$.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(($)=>$.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(($)=>$.kind==="cuid2")}get isULID(){return!!this._def.checks.find(($)=>$.kind==="ulid")}get isIP(){return!!this._def.checks.find(($)=>$.kind==="ip")}get isCIDR(){return!!this._def.checks.find(($)=>$.kind==="cidr")}get isBase64(){return!!this._def.checks.find(($)=>$.kind==="base64")}get isBase64url(){return!!this._def.checks.find(($)=>$.kind==="base64url")}get minLength(){let $=null;for(let Q of this._def.checks)if(Q.kind==="min"){if($===null||Q.value>$)$=Q.value}return $}get maxLength(){let $=null;for(let Q of this._def.checks)if(Q.kind==="max"){if($===null||Q.value<$)$=Q.value}return $}}H2.create=($)=>{return new H2({checks:[],typeName:F0.ZodString,coerce:$?.coerce??!1,...A0($)})};function mW($,Q){let J=($.toString().split(".")[1]||"").length,q=(Q.toString().split(".")[1]||"").length,X=J>q?J:q,Y=Number.parseInt($.toFixed(X).replace(".","")),G=Number.parseInt(Q.toFixed(X).replace(".",""));return Y%G/10**X}class G1 extends D0{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse($){if(this._def.coerce)$.data=Number($.data);if(this._getType($)!==$0.number){let X=this._getOrReturnCtx($);return X0(X,{code:o.invalid_type,expected:$0.number,received:X.parsedType}),w0}let J=void 0,q=new m0;for(let X of this._def.checks)if(X.kind==="int"){if(!R0.isInteger($.data))J=this._getOrReturnCtx($,J),X0(J,{code:o.invalid_type,expected:"integer",received:"float",message:X.message}),q.dirty()}else if(X.kind==="min"){if(X.inclusive?$.data<X.value:$.data<=X.value)J=this._getOrReturnCtx($,J),X0(J,{code:o.too_small,minimum:X.value,type:"number",inclusive:X.inclusive,exact:!1,message:X.message}),q.dirty()}else if(X.kind==="max"){if(X.inclusive?$.data>X.value:$.data>=X.value)J=this._getOrReturnCtx($,J),X0(J,{code:o.too_big,maximum:X.value,type:"number",inclusive:X.inclusive,exact:!1,message:X.message}),q.dirty()}else if(X.kind==="multipleOf"){if(mW($.data,X.value)!==0)J=this._getOrReturnCtx($,J),X0(J,{code:o.not_multiple_of,multipleOf:X.value,message:X.message}),q.dirty()}else if(X.kind==="finite"){if(!Number.isFinite($.data))J=this._getOrReturnCtx($,J),X0(J,{code:o.not_finite,message:X.message}),q.dirty()}else R0.assertNever(X);return{status:q.value,value:$.data}}gte($,Q){return this.setLimit("min",$,!0,V0.toString(Q))}gt($,Q){return this.setLimit("min",$,!1,V0.toString(Q))}lte($,Q){return this.setLimit("max",$,!0,V0.toString(Q))}lt($,Q){return this.setLimit("max",$,!1,V0.toString(Q))}setLimit($,Q,J,q){return new G1({...this._def,checks:[...this._def.checks,{kind:$,value:Q,inclusive:J,message:V0.toString(q)}]})}_addCheck($){return new G1({...this._def,checks:[...this._def.checks,$]})}int($){return this._addCheck({kind:"int",message:V0.toString($)})}positive($){return this._addCheck({kind:"min",value:0,inclusive:!1,message:V0.toString($)})}negative($){return this._addCheck({kind:"max",value:0,inclusive:!1,message:V0.toString($)})}nonpositive($){return this._addCheck({kind:"max",value:0,inclusive:!0,message:V0.toString($)})}nonnegative($){return this._addCheck({kind:"min",value:0,inclusive:!0,message:V0.toString($)})}multipleOf($,Q){return this._addCheck({kind:"multipleOf",value:$,message:V0.toString(Q)})}finite($){return this._addCheck({kind:"finite",message:V0.toString($)})}safe($){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:V0.toString($)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:V0.toString($)})}get minValue(){let $=null;for(let Q of this._def.checks)if(Q.kind==="min"){if($===null||Q.value>$)$=Q.value}return $}get maxValue(){let $=null;for(let Q of this._def.checks)if(Q.kind==="max"){if($===null||Q.value<$)$=Q.value}return $}get isInt(){return!!this._def.checks.find(($)=>$.kind==="int"||$.kind==="multipleOf"&&R0.isInteger($.value))}get isFinite(){let $=null,Q=null;for(let J of this._def.checks)if(J.kind==="finite"||J.kind==="int"||J.kind==="multipleOf")return!0;else if(J.kind==="min"){if(Q===null||J.value>Q)Q=J.value}else if(J.kind==="max"){if($===null||J.value<$)$=J.value}return Number.isFinite(Q)&&Number.isFinite($)}}G1.create=($)=>{return new G1({checks:[],typeName:F0.ZodNumber,coerce:$?.coerce||!1,...A0($)})};class B1 extends D0{constructor(){super(...arguments);this.min=this.gte,this.max=this.lte}_parse($){if(this._def.coerce)try{$.data=BigInt($.data)}catch{return this._getInvalidInput($)}if(this._getType($)!==$0.bigint)return this._getInvalidInput($);let J=void 0,q=new m0;for(let X of this._def.checks)if(X.kind==="min"){if(X.inclusive?$.data<X.value:$.data<=X.value)J=this._getOrReturnCtx($,J),X0(J,{code:o.too_small,type:"bigint",minimum:X.value,inclusive:X.inclusive,message:X.message}),q.dirty()}else if(X.kind==="max"){if(X.inclusive?$.data>X.value:$.data>=X.value)J=this._getOrReturnCtx($,J),X0(J,{code:o.too_big,type:"bigint",maximum:X.value,inclusive:X.inclusive,message:X.message}),q.dirty()}else if(X.kind==="multipleOf"){if($.data%X.value!==BigInt(0))J=this._getOrReturnCtx($,J),X0(J,{code:o.not_multiple_of,multipleOf:X.value,message:X.message}),q.dirty()}else R0.assertNever(X);return{status:q.value,value:$.data}}_getInvalidInput($){let Q=this._getOrReturnCtx($);return X0(Q,{code:o.invalid_type,expected:$0.bigint,received:Q.parsedType}),w0}gte($,Q){return this.setLimit("min",$,!0,V0.toString(Q))}gt($,Q){return this.setLimit("min",$,!1,V0.toString(Q))}lte($,Q){return this.setLimit("max",$,!0,V0.toString(Q))}lt($,Q){return this.setLimit("max",$,!1,V0.toString(Q))}setLimit($,Q,J,q){return new B1({...this._def,checks:[...this._def.checks,{kind:$,value:Q,inclusive:J,message:V0.toString(q)}]})}_addCheck($){return new B1({...this._def,checks:[...this._def.checks,$]})}positive($){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:V0.toString($)})}negative($){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:V0.toString($)})}nonpositive($){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:V0.toString($)})}nonnegative($){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:V0.toString($)})}multipleOf($,Q){return this._addCheck({kind:"multipleOf",value:$,message:V0.toString(Q)})}get minValue(){let $=null;for(let Q of this._def.checks)if(Q.kind==="min"){if($===null||Q.value>$)$=Q.value}return $}get maxValue(){let $=null;for(let Q of this._def.checks)if(Q.kind==="max"){if($===null||Q.value<$)$=Q.value}return $}}B1.create=($)=>{return new B1({checks:[],typeName:F0.ZodBigInt,coerce:$?.coerce??!1,...A0($)})};class U6 extends D0{_parse($){if(this._def.coerce)$.data=Boolean($.data);if(this._getType($)!==$0.boolean){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.boolean,received:J.parsedType}),w0}return l0($.data)}}U6.create=($)=>{return new U6({typeName:F0.ZodBoolean,coerce:$?.coerce||!1,...A0($)})};class k1 extends D0{_parse($){if(this._def.coerce)$.data=new Date($.data);if(this._getType($)!==$0.date){let X=this._getOrReturnCtx($);return X0(X,{code:o.invalid_type,expected:$0.date,received:X.parsedType}),w0}if(Number.isNaN($.data.getTime())){let X=this._getOrReturnCtx($);return X0(X,{code:o.invalid_date}),w0}let J=new m0,q=void 0;for(let X of this._def.checks)if(X.kind==="min"){if($.data.getTime()<X.value)q=this._getOrReturnCtx($,q),X0(q,{code:o.too_small,message:X.message,inclusive:!0,exact:!1,minimum:X.value,type:"date"}),J.dirty()}else if(X.kind==="max"){if($.data.getTime()>X.value)q=this._getOrReturnCtx($,q),X0(q,{code:o.too_big,message:X.message,inclusive:!0,exact:!1,maximum:X.value,type:"date"}),J.dirty()}else R0.assertNever(X);return{status:J.value,value:new Date($.data.getTime())}}_addCheck($){return new k1({...this._def,checks:[...this._def.checks,$]})}min($,Q){return this._addCheck({kind:"min",value:$.getTime(),message:V0.toString(Q)})}max($,Q){return this._addCheck({kind:"max",value:$.getTime(),message:V0.toString(Q)})}get minDate(){let $=null;for(let Q of this._def.checks)if(Q.kind==="min"){if($===null||Q.value>$)$=Q.value}return $!=null?new Date($):null}get maxDate(){let $=null;for(let Q of this._def.checks)if(Q.kind==="max"){if($===null||Q.value<$)$=Q.value}return $!=null?new Date($):null}}k1.create=($)=>{return new k1({checks:[],coerce:$?.coerce||!1,typeName:F0.ZodDate,...A0($)})};class e6 extends D0{_parse($){if(this._getType($)!==$0.symbol){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.symbol,received:J.parsedType}),w0}return l0($.data)}}e6.create=($)=>{return new e6({typeName:F0.ZodSymbol,...A0($)})};class W6 extends D0{_parse($){if(this._getType($)!==$0.undefined){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.undefined,received:J.parsedType}),w0}return l0($.data)}}W6.create=($)=>{return new W6({typeName:F0.ZodUndefined,...A0($)})};class V6 extends D0{_parse($){if(this._getType($)!==$0.null){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.null,received:J.parsedType}),w0}return l0($.data)}}V6.create=($)=>{return new V6({typeName:F0.ZodNull,...A0($)})};class T1 extends D0{constructor(){super(...arguments);this._any=!0}_parse($){return l0($.data)}}T1.create=($)=>{return new T1({typeName:F0.ZodAny,...A0($)})};class Y1 extends D0{constructor(){super(...arguments);this._unknown=!0}_parse($){return l0($.data)}}Y1.create=($)=>{return new Y1({typeName:F0.ZodUnknown,...A0($)})};class E2 extends D0{_parse($){let Q=this._getOrReturnCtx($);return X0(Q,{code:o.invalid_type,expected:$0.never,received:Q.parsedType}),w0}}E2.create=($)=>{return new E2({typeName:F0.ZodNever,...A0($)})};class $8 extends D0{_parse($){if(this._getType($)!==$0.undefined){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.void,received:J.parsedType}),w0}return l0($.data)}}$8.create=($)=>{return new $8({typeName:F0.ZodVoid,...A0($)})};class j2 extends D0{_parse($){let{ctx:Q,status:J}=this._processInputParams($),q=this._def;if(Q.parsedType!==$0.array)return X0(Q,{code:o.invalid_type,expected:$0.array,received:Q.parsedType}),w0;if(q.exactLength!==null){let Y=Q.data.length>q.exactLength.value,G=Q.data.length<q.exactLength.value;if(Y||G)X0(Q,{code:Y?o.too_big:o.too_small,minimum:G?q.exactLength.value:void 0,maximum:Y?q.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:q.exactLength.message}),J.dirty()}if(q.minLength!==null){if(Q.data.length<q.minLength.value)X0(Q,{code:o.too_small,minimum:q.minLength.value,type:"array",inclusive:!0,exact:!1,message:q.minLength.message}),J.dirty()}if(q.maxLength!==null){if(Q.data.length>q.maxLength.value)X0(Q,{code:o.too_big,maximum:q.maxLength.value,type:"array",inclusive:!0,exact:!1,message:q.maxLength.message}),J.dirty()}if(Q.common.async)return Promise.all([...Q.data].map((Y,G)=>{return q.type._parseAsync(new w2(Q,Y,Q.path,G))})).then((Y)=>{return m0.mergeArray(J,Y)});let X=[...Q.data].map((Y,G)=>{return q.type._parseSync(new w2(Q,Y,Q.path,G))});return m0.mergeArray(J,X)}get element(){return this._def.type}min($,Q){return new j2({...this._def,minLength:{value:$,message:V0.toString(Q)}})}max($,Q){return new j2({...this._def,maxLength:{value:$,message:V0.toString(Q)}})}length($,Q){return new j2({...this._def,exactLength:{value:$,message:V0.toString(Q)}})}nonempty($){return this.min(1,$)}}j2.create=($,Q)=>{return new j2({type:$,minLength:null,maxLength:null,exactLength:null,typeName:F0.ZodArray,...A0(Q)})};function G6($){if($ instanceof x0){let Q={};for(let J in $.shape){let q=$.shape[J];Q[J]=M2.create(G6(q))}return new x0({...$._def,shape:()=>Q})}else if($ instanceof j2)return new j2({...$._def,type:G6($.element)});else if($ instanceof M2)return M2.create(G6($.unwrap()));else if($ instanceof l2)return l2.create(G6($.unwrap()));else if($ instanceof v2)return v2.create($.items.map((Q)=>G6(Q)));else return $}class x0 extends D0{constructor(){super(...arguments);this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;let $=this._def.shape(),Q=R0.objectKeys($);return this._cached={shape:$,keys:Q},this._cached}_parse($){if(this._getType($)!==$0.object){let W=this._getOrReturnCtx($);return X0(W,{code:o.invalid_type,expected:$0.object,received:W.parsedType}),w0}let{status:J,ctx:q}=this._processInputParams($),{shape:X,keys:Y}=this._getCached(),G=[];if(!(this._def.catchall instanceof E2&&this._def.unknownKeys==="strip")){for(let W in q.data)if(!Y.includes(W))G.push(W)}let B=[];for(let W of Y){let U=X[W],V=q.data[W];B.push({key:{status:"valid",value:W},value:U._parse(new w2(q,V,q.path,W)),alwaysSet:W in q.data})}if(this._def.catchall instanceof E2){let W=this._def.unknownKeys;if(W==="passthrough")for(let U of G)B.push({key:{status:"valid",value:U},value:{status:"valid",value:q.data[U]}});else if(W==="strict"){if(G.length>0)X0(q,{code:o.unrecognized_keys,keys:G}),J.dirty()}else if(W==="strip");else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let W=this._def.catchall;for(let U of G){let V=q.data[U];B.push({key:{status:"valid",value:U},value:W._parse(new w2(q,V,q.path,U)),alwaysSet:U in q.data})}}if(q.common.async)return Promise.resolve().then(async()=>{let W=[];for(let U of B){let V=await U.key,L=await U.value;W.push({key:V,value:L,alwaysSet:U.alwaysSet})}return W}).then((W)=>{return m0.mergeObjectSync(J,W)});else return m0.mergeObjectSync(J,B)}get shape(){return this._def.shape()}strict($){return V0.errToObj,new x0({...this._def,unknownKeys:"strict",...$!==void 0?{errorMap:(Q,J)=>{let q=this._def.errorMap?.(Q,J).message??J.defaultError;if(Q.code==="unrecognized_keys")return{message:V0.errToObj($).message??q};return{message:q}}}:{}})}strip(){return new x0({...this._def,unknownKeys:"strip"})}passthrough(){return new x0({...this._def,unknownKeys:"passthrough"})}extend($){return new x0({...this._def,shape:()=>({...this._def.shape(),...$})})}merge($){return new x0({unknownKeys:$._def.unknownKeys,catchall:$._def.catchall,shape:()=>({...this._def.shape(),...$._def.shape()}),typeName:F0.ZodObject})}setKey($,Q){return this.augment({[$]:Q})}catchall($){return new x0({...this._def,catchall:$})}pick($){let Q={};for(let J of R0.objectKeys($))if($[J]&&this.shape[J])Q[J]=this.shape[J];return new x0({...this._def,shape:()=>Q})}omit($){let Q={};for(let J of R0.objectKeys(this.shape))if(!$[J])Q[J]=this.shape[J];return new x0({...this._def,shape:()=>Q})}deepPartial(){return G6(this)}partial($){let Q={};for(let J of R0.objectKeys(this.shape)){let q=this.shape[J];if($&&!$[J])Q[J]=q;else Q[J]=q.optional()}return new x0({...this._def,shape:()=>Q})}required($){let Q={};for(let J of R0.objectKeys(this.shape))if($&&!$[J])Q[J]=this.shape[J];else{let X=this.shape[J];while(X instanceof M2)X=X._def.innerType;Q[J]=X}return new x0({...this._def,shape:()=>Q})}keyof(){return TJ(R0.objectKeys(this.shape))}}x0.create=($,Q)=>{return new x0({shape:()=>$,unknownKeys:"strip",catchall:E2.create(),typeName:F0.ZodObject,...A0(Q)})};x0.strictCreate=($,Q)=>{return new x0({shape:()=>$,unknownKeys:"strict",catchall:E2.create(),typeName:F0.ZodObject,...A0(Q)})};x0.lazycreate=($,Q)=>{return new x0({shape:$,unknownKeys:"strip",catchall:E2.create(),typeName:F0.ZodObject,...A0(Q)})};class K6 extends D0{_parse($){let{ctx:Q}=this._processInputParams($),J=this._def.options;function q(X){for(let G of X)if(G.result.status==="valid")return G.result;for(let G of X)if(G.result.status==="dirty")return Q.common.issues.push(...G.ctx.common.issues),G.result;let Y=X.map((G)=>new s0(G.ctx.common.issues));return X0(Q,{code:o.invalid_union,unionErrors:Y}),w0}if(Q.common.async)return Promise.all(J.map(async(X)=>{let Y={...Q,common:{...Q.common,issues:[]},parent:null};return{result:await X._parseAsync({data:Q.data,path:Q.path,parent:Y}),ctx:Y}})).then(q);else{let X=void 0,Y=[];for(let B of J){let W={...Q,common:{...Q.common,issues:[]},parent:null},U=B._parseSync({data:Q.data,path:Q.path,parent:W});if(U.status==="valid")return U;else if(U.status==="dirty"&&!X)X={result:U,ctx:W};if(W.common.issues.length)Y.push(W.common.issues)}if(X)return Q.common.issues.push(...X.ctx.common.issues),X.result;let G=Y.map((B)=>new s0(B));return X0(Q,{code:o.invalid_union,unionErrors:G}),w0}}get options(){return this._def.options}}K6.create=($,Q)=>{return new K6({options:$,typeName:F0.ZodUnion,...A0(Q)})};var p2=($)=>{if($ instanceof j6)return p2($.schema);else if($ instanceof F2)return p2($.innerType());else if($ instanceof M6)return[$.value];else if($ instanceof U1)return $.options;else if($ instanceof w6)return R0.objectValues($.enum);else if($ instanceof F6)return p2($._def.innerType);else if($ instanceof W6)return[void 0];else if($ instanceof V6)return[null];else if($ instanceof M2)return[void 0,...p2($.unwrap())];else if($ instanceof l2)return[null,...p2($.unwrap())];else if($ instanceof $5)return p2($.unwrap());else if($ instanceof z6)return p2($.unwrap());else if($ instanceof L6)return p2($._def.innerType);else return[]};class e8 extends D0{_parse($){let{ctx:Q}=this._processInputParams($);if(Q.parsedType!==$0.object)return X0(Q,{code:o.invalid_type,expected:$0.object,received:Q.parsedType}),w0;let J=this.discriminator,q=Q.data[J],X=this.optionsMap.get(q);if(!X)return X0(Q,{code:o.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[J]}),w0;if(Q.common.async)return X._parseAsync({data:Q.data,path:Q.path,parent:Q});else return X._parseSync({data:Q.data,path:Q.path,parent:Q})}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create($,Q,J){let q=new Map;for(let X of Q){let Y=p2(X.shape[$]);if(!Y.length)throw Error(`A discriminator value for key \`${$}\` could not be extracted from all schema options`);for(let G of Y){if(q.has(G))throw Error(`Discriminator property ${String($)} has duplicate value ${String(G)}`);q.set(G,X)}}return new e8({typeName:F0.ZodDiscriminatedUnion,discriminator:$,options:Q,optionsMap:q,...A0(J)})}}function d4($,Q){let J=S2($),q=S2(Q);if($===Q)return{valid:!0,data:$};else if(J===$0.object&&q===$0.object){let X=R0.objectKeys(Q),Y=R0.objectKeys($).filter((B)=>X.indexOf(B)!==-1),G={...$,...Q};for(let B of Y){let W=d4($[B],Q[B]);if(!W.valid)return{valid:!1};G[B]=W.data}return{valid:!0,data:G}}else if(J===$0.array&&q===$0.array){if($.length!==Q.length)return{valid:!1};let X=[];for(let Y=0;Y<$.length;Y++){let G=$[Y],B=Q[Y],W=d4(G,B);if(!W.valid)return{valid:!1};X.push(W.data)}return{valid:!0,data:X}}else if(J===$0.date&&q===$0.date&&+$===+Q)return{valid:!0,data:$};else return{valid:!1}}class H6 extends D0{_parse($){let{status:Q,ctx:J}=this._processInputParams($),q=(X,Y)=>{if(s8(X)||s8(Y))return w0;let G=d4(X.value,Y.value);if(!G.valid)return X0(J,{code:o.invalid_intersection_types}),w0;if(t8(X)||t8(Y))Q.dirty();return{status:Q.value,value:G.data}};if(J.common.async)return Promise.all([this._def.left._parseAsync({data:J.data,path:J.path,parent:J}),this._def.right._parseAsync({data:J.data,path:J.path,parent:J})]).then(([X,Y])=>q(X,Y));else return q(this._def.left._parseSync({data:J.data,path:J.path,parent:J}),this._def.right._parseSync({data:J.data,path:J.path,parent:J}))}}H6.create=($,Q,J)=>{return new H6({left:$,right:Q,typeName:F0.ZodIntersection,...A0(J)})};class v2 extends D0{_parse($){let{status:Q,ctx:J}=this._processInputParams($);if(J.parsedType!==$0.array)return X0(J,{code:o.invalid_type,expected:$0.array,received:J.parsedType}),w0;if(J.data.length<this._def.items.length)return X0(J,{code:o.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),w0;if(!this._def.rest&&J.data.length>this._def.items.length)X0(J,{code:o.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),Q.dirty();let X=[...J.data].map((Y,G)=>{let B=this._def.items[G]||this._def.rest;if(!B)return null;return B._parse(new w2(J,Y,J.path,G))}).filter((Y)=>!!Y);if(J.common.async)return Promise.all(X).then((Y)=>{return m0.mergeArray(Q,Y)});else return m0.mergeArray(Q,X)}get items(){return this._def.items}rest($){return new v2({...this._def,rest:$})}}v2.create=($,Q)=>{if(!Array.isArray($))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new v2({items:$,typeName:F0.ZodTuple,rest:null,...A0(Q)})};class Q8 extends D0{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse($){let{status:Q,ctx:J}=this._processInputParams($);if(J.parsedType!==$0.object)return X0(J,{code:o.invalid_type,expected:$0.object,received:J.parsedType}),w0;let q=[],X=this._def.keyType,Y=this._def.valueType;for(let G in J.data)q.push({key:X._parse(new w2(J,G,J.path,G)),value:Y._parse(new w2(J,J.data[G],J.path,G)),alwaysSet:G in J.data});if(J.common.async)return m0.mergeObjectAsync(Q,q);else return m0.mergeObjectSync(Q,q)}get element(){return this._def.valueType}static create($,Q,J){if(Q instanceof D0)return new Q8({keyType:$,valueType:Q,typeName:F0.ZodRecord,...A0(J)});return new Q8({keyType:H2.create(),valueType:$,typeName:F0.ZodRecord,...A0(Q)})}}class J8 extends D0{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse($){let{status:Q,ctx:J}=this._processInputParams($);if(J.parsedType!==$0.map)return X0(J,{code:o.invalid_type,expected:$0.map,received:J.parsedType}),w0;let q=this._def.keyType,X=this._def.valueType,Y=[...J.data.entries()].map(([G,B],W)=>{return{key:q._parse(new w2(J,G,J.path,[W,"key"])),value:X._parse(new w2(J,B,J.path,[W,"value"]))}});if(J.common.async){let G=new Map;return Promise.resolve().then(async()=>{for(let B of Y){let W=await B.key,U=await B.value;if(W.status==="aborted"||U.status==="aborted")return w0;if(W.status==="dirty"||U.status==="dirty")Q.dirty();G.set(W.value,U.value)}return{status:Q.value,value:G}})}else{let G=new Map;for(let B of Y){let{key:W,value:U}=B;if(W.status==="aborted"||U.status==="aborted")return w0;if(W.status==="dirty"||U.status==="dirty")Q.dirty();G.set(W.value,U.value)}return{status:Q.value,value:G}}}}J8.create=($,Q,J)=>{return new J8({valueType:Q,keyType:$,typeName:F0.ZodMap,...A0(J)})};class Z1 extends D0{_parse($){let{status:Q,ctx:J}=this._processInputParams($);if(J.parsedType!==$0.set)return X0(J,{code:o.invalid_type,expected:$0.set,received:J.parsedType}),w0;let q=this._def;if(q.minSize!==null){if(J.data.size<q.minSize.value)X0(J,{code:o.too_small,minimum:q.minSize.value,type:"set",inclusive:!0,exact:!1,message:q.minSize.message}),Q.dirty()}if(q.maxSize!==null){if(J.data.size>q.maxSize.value)X0(J,{code:o.too_big,maximum:q.maxSize.value,type:"set",inclusive:!0,exact:!1,message:q.maxSize.message}),Q.dirty()}let X=this._def.valueType;function Y(B){let W=new Set;for(let U of B){if(U.status==="aborted")return w0;if(U.status==="dirty")Q.dirty();W.add(U.value)}return{status:Q.value,value:W}}let G=[...J.data.values()].map((B,W)=>X._parse(new w2(J,B,J.path,W)));if(J.common.async)return Promise.all(G).then((B)=>Y(B));else return Y(G)}min($,Q){return new Z1({...this._def,minSize:{value:$,message:V0.toString(Q)}})}max($,Q){return new Z1({...this._def,maxSize:{value:$,message:V0.toString(Q)}})}size($,Q){return this.min($,Q).max($,Q)}nonempty($){return this.min(1,$)}}Z1.create=($,Q)=>{return new Z1({valueType:$,minSize:null,maxSize:null,typeName:F0.ZodSet,...A0(Q)})};class B6 extends D0{constructor(){super(...arguments);this.validate=this.implement}_parse($){let{ctx:Q}=this._processInputParams($);if(Q.parsedType!==$0.function)return X0(Q,{code:o.invalid_type,expected:$0.function,received:Q.parsedType}),w0;function J(G,B){return t6({data:G,path:Q.path,errorMaps:[Q.common.contextualErrorMap,Q.schemaErrorMap,X6(),c2].filter((W)=>!!W),issueData:{code:o.invalid_arguments,argumentsError:B}})}function q(G,B){return t6({data:G,path:Q.path,errorMaps:[Q.common.contextualErrorMap,Q.schemaErrorMap,X6(),c2].filter((W)=>!!W),issueData:{code:o.invalid_return_type,returnTypeError:B}})}let X={errorMap:Q.common.contextualErrorMap},Y=Q.data;if(this._def.returns instanceof g1){let G=this;return l0(async function(...B){let W=new s0([]),U=await G._def.args.parseAsync(B,X).catch((w)=>{throw W.addIssue(J(B,w)),W}),V=await Reflect.apply(Y,this,U);return await G._def.returns._def.type.parseAsync(V,X).catch((w)=>{throw W.addIssue(q(V,w)),W})})}else{let G=this;return l0(function(...B){let W=G._def.args.safeParse(B,X);if(!W.success)throw new s0([J(B,W.error)]);let U=Reflect.apply(Y,this,W.data),V=G._def.returns.safeParse(U,X);if(!V.success)throw new s0([q(U,V.error)]);return V.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...$){return new B6({...this._def,args:v2.create($).rest(Y1.create())})}returns($){return new B6({...this._def,returns:$})}implement($){return this.parse($)}strictImplement($){return this.parse($)}static create($,Q,J){return new B6({args:$?$:v2.create([]).rest(Y1.create()),returns:Q||Y1.create(),typeName:F0.ZodFunction,...A0(J)})}}class j6 extends D0{get schema(){return this._def.getter()}_parse($){let{ctx:Q}=this._processInputParams($);return this._def.getter()._parse({data:Q.data,path:Q.path,parent:Q})}}j6.create=($,Q)=>{return new j6({getter:$,typeName:F0.ZodLazy,...A0(Q)})};class M6 extends D0{_parse($){if($.data!==this._def.value){let Q=this._getOrReturnCtx($);return X0(Q,{received:Q.data,code:o.invalid_literal,expected:this._def.value}),w0}return{status:"valid",value:$.data}}get value(){return this._def.value}}M6.create=($,Q)=>{return new M6({value:$,typeName:F0.ZodLiteral,...A0(Q)})};function TJ($,Q){return new U1({values:$,typeName:F0.ZodEnum,...A0(Q)})}class U1 extends D0{_parse($){if(typeof $.data!=="string"){let Q=this._getOrReturnCtx($),J=this._def.values;return X0(Q,{expected:R0.joinValues(J),received:Q.parsedType,code:o.invalid_type}),w0}if(!this._cache)this._cache=new Set(this._def.values);if(!this._cache.has($.data)){let Q=this._getOrReturnCtx($),J=this._def.values;return X0(Q,{received:Q.data,code:o.invalid_enum_value,options:J}),w0}return l0($.data)}get options(){return this._def.values}get enum(){let $={};for(let Q of this._def.values)$[Q]=Q;return $}get Values(){let $={};for(let Q of this._def.values)$[Q]=Q;return $}get Enum(){let $={};for(let Q of this._def.values)$[Q]=Q;return $}extract($,Q=this._def){return U1.create($,{...this._def,...Q})}exclude($,Q=this._def){return U1.create(this.options.filter((J)=>!$.includes(J)),{...this._def,...Q})}}U1.create=TJ;class w6 extends D0{_parse($){let Q=R0.getValidEnumValues(this._def.values),J=this._getOrReturnCtx($);if(J.parsedType!==$0.string&&J.parsedType!==$0.number){let q=R0.objectValues(Q);return X0(J,{expected:R0.joinValues(q),received:J.parsedType,code:o.invalid_type}),w0}if(!this._cache)this._cache=new Set(R0.getValidEnumValues(this._def.values));if(!this._cache.has($.data)){let q=R0.objectValues(Q);return X0(J,{received:J.data,code:o.invalid_enum_value,options:q}),w0}return l0($.data)}get enum(){return this._def.values}}w6.create=($,Q)=>{return new w6({values:$,typeName:F0.ZodNativeEnum,...A0(Q)})};class g1 extends D0{unwrap(){return this._def.type}_parse($){let{ctx:Q}=this._processInputParams($);if(Q.parsedType!==$0.promise&&Q.common.async===!1)return X0(Q,{code:o.invalid_type,expected:$0.promise,received:Q.parsedType}),w0;let J=Q.parsedType===$0.promise?Q.data:Promise.resolve(Q.data);return l0(J.then((q)=>{return this._def.type.parseAsync(q,{path:Q.path,errorMap:Q.common.contextualErrorMap})}))}}g1.create=($,Q)=>{return new g1({type:$,typeName:F0.ZodPromise,...A0(Q)})};class F2 extends D0{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===F0.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse($){let{status:Q,ctx:J}=this._processInputParams($),q=this._def.effect||null,X={addIssue:(Y)=>{if(X0(J,Y),Y.fatal)Q.abort();else Q.dirty()},get path(){return J.path}};if(X.addIssue=X.addIssue.bind(X),q.type==="preprocess"){let Y=q.transform(J.data,X);if(J.common.async)return Promise.resolve(Y).then(async(G)=>{if(Q.value==="aborted")return w0;let B=await this._def.schema._parseAsync({data:G,path:J.path,parent:J});if(B.status==="aborted")return w0;if(B.status==="dirty")return v1(B.value);if(Q.value==="dirty")return v1(B.value);return B});else{if(Q.value==="aborted")return w0;let G=this._def.schema._parseSync({data:Y,path:J.path,parent:J});if(G.status==="aborted")return w0;if(G.status==="dirty")return v1(G.value);if(Q.value==="dirty")return v1(G.value);return G}}if(q.type==="refinement"){let Y=(G)=>{let B=q.refinement(G,X);if(J.common.async)return Promise.resolve(B);if(B instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return G};if(J.common.async===!1){let G=this._def.schema._parseSync({data:J.data,path:J.path,parent:J});if(G.status==="aborted")return w0;if(G.status==="dirty")Q.dirty();return Y(G.value),{status:Q.value,value:G.value}}else return this._def.schema._parseAsync({data:J.data,path:J.path,parent:J}).then((G)=>{if(G.status==="aborted")return w0;if(G.status==="dirty")Q.dirty();return Y(G.value).then(()=>{return{status:Q.value,value:G.value}})})}if(q.type==="transform")if(J.common.async===!1){let Y=this._def.schema._parseSync({data:J.data,path:J.path,parent:J});if(!X1(Y))return w0;let G=q.transform(Y.value,X);if(G instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:Q.value,value:G}}else return this._def.schema._parseAsync({data:J.data,path:J.path,parent:J}).then((Y)=>{if(!X1(Y))return w0;return Promise.resolve(q.transform(Y.value,X)).then((G)=>({status:Q.value,value:G}))});R0.assertNever(q)}}F2.create=($,Q,J)=>{return new F2({schema:$,typeName:F0.ZodEffects,effect:Q,...A0(J)})};F2.createWithPreprocess=($,Q,J)=>{return new F2({schema:Q,effect:{type:"preprocess",transform:$},typeName:F0.ZodEffects,...A0(J)})};class M2 extends D0{_parse($){if(this._getType($)===$0.undefined)return l0(void 0);return this._def.innerType._parse($)}unwrap(){return this._def.innerType}}M2.create=($,Q)=>{return new M2({innerType:$,typeName:F0.ZodOptional,...A0(Q)})};class l2 extends D0{_parse($){if(this._getType($)===$0.null)return l0(null);return this._def.innerType._parse($)}unwrap(){return this._def.innerType}}l2.create=($,Q)=>{return new l2({innerType:$,typeName:F0.ZodNullable,...A0(Q)})};class F6 extends D0{_parse($){let{ctx:Q}=this._processInputParams($),J=Q.data;if(Q.parsedType===$0.undefined)J=this._def.defaultValue();return this._def.innerType._parse({data:J,path:Q.path,parent:Q})}removeDefault(){return this._def.innerType}}F6.create=($,Q)=>{return new F6({innerType:$,typeName:F0.ZodDefault,defaultValue:typeof Q.default==="function"?Q.default:()=>Q.default,...A0(Q)})};class L6 extends D0{_parse($){let{ctx:Q}=this._processInputParams($),J={...Q,common:{...Q.common,issues:[]}},q=this._def.innerType._parse({data:J.data,path:J.path,parent:{...J}});if(Y6(q))return q.then((X)=>{return{status:"valid",value:X.status==="valid"?X.value:this._def.catchValue({get error(){return new s0(J.common.issues)},input:J.data})}});else return{status:"valid",value:q.status==="valid"?q.value:this._def.catchValue({get error(){return new s0(J.common.issues)},input:J.data})}}removeCatch(){return this._def.innerType}}L6.create=($,Q)=>{return new L6({innerType:$,typeName:F0.ZodCatch,catchValue:typeof Q.catch==="function"?Q.catch:()=>Q.catch,...A0(Q)})};class q8 extends D0{_parse($){if(this._getType($)!==$0.nan){let J=this._getOrReturnCtx($);return X0(J,{code:o.invalid_type,expected:$0.nan,received:J.parsedType}),w0}return{status:"valid",value:$.data}}}q8.create=($)=>{return new q8({typeName:F0.ZodNaN,...A0($)})};var uW=Symbol("zod_brand");class $5 extends D0{_parse($){let{ctx:Q}=this._processInputParams($),J=Q.data;return this._def.type._parse({data:J,path:Q.path,parent:Q})}unwrap(){return this._def.type}}class X8 extends D0{_parse($){let{status:Q,ctx:J}=this._processInputParams($);if(J.common.async)return(async()=>{let X=await this._def.in._parseAsync({data:J.data,path:J.path,parent:J});if(X.status==="aborted")return w0;if(X.status==="dirty")return Q.dirty(),v1(X.value);else return this._def.out._parseAsync({data:X.value,path:J.path,parent:J})})();else{let q=this._def.in._parseSync({data:J.data,path:J.path,parent:J});if(q.status==="aborted")return w0;if(q.status==="dirty")return Q.dirty(),{status:"dirty",value:q.value};else return this._def.out._parseSync({data:q.value,path:J.path,parent:J})}}static create($,Q){return new X8({in:$,out:Q,typeName:F0.ZodPipeline})}}class z6 extends D0{_parse($){let Q=this._def.innerType._parse($),J=(q)=>{if(X1(q))q.value=Object.freeze(q.value);return q};return Y6(Q)?Q.then((q)=>J(q)):J(Q)}unwrap(){return this._def.innerType}}z6.create=($,Q)=>{return new z6({innerType:$,typeName:F0.ZodReadonly,...A0(Q)})};function SJ($,Q){let J=typeof $==="function"?$(Q):typeof $==="string"?{message:$}:$;return typeof J==="string"?{message:J}:J}function ZJ($,Q={},J){if($)return T1.create().superRefine((q,X)=>{let Y=$(q);if(Y instanceof Promise)return Y.then((G)=>{if(!G){let B=SJ(Q,q),W=B.fatal??J??!0;X.addIssue({code:"custom",...B,fatal:W})}});if(!Y){let G=SJ(Q,q),B=G.fatal??J??!0;X.addIssue({code:"custom",...G,fatal:B})}return});return T1.create()}var cW={object:x0.lazycreate},F0;(function($){$.ZodString="ZodString",$.ZodNumber="ZodNumber",$.ZodNaN="ZodNaN",$.ZodBigInt="ZodBigInt",$.ZodBoolean="ZodBoolean",$.ZodDate="ZodDate",$.ZodSymbol="ZodSymbol",$.ZodUndefined="ZodUndefined",$.ZodNull="ZodNull",$.ZodAny="ZodAny",$.ZodUnknown="ZodUnknown",$.ZodNever="ZodNever",$.ZodVoid="ZodVoid",$.ZodArray="ZodArray",$.ZodObject="ZodObject",$.ZodUnion="ZodUnion",$.ZodDiscriminatedUnion="ZodDiscriminatedUnion",$.ZodIntersection="ZodIntersection",$.ZodTuple="ZodTuple",$.ZodRecord="ZodRecord",$.ZodMap="ZodMap",$.ZodSet="ZodSet",$.ZodFunction="ZodFunction",$.ZodLazy="ZodLazy",$.ZodLiteral="ZodLiteral",$.ZodEnum="ZodEnum",$.ZodEffects="ZodEffects",$.ZodNativeEnum="ZodNativeEnum",$.ZodOptional="ZodOptional",$.ZodNullable="ZodNullable",$.ZodDefault="ZodDefault",$.ZodCatch="ZodCatch",$.ZodPromise="ZodPromise",$.ZodBranded="ZodBranded",$.ZodPipeline="ZodPipeline",$.ZodReadonly="ZodReadonly"})(F0||(F0={}));var pW=($,Q={message:`Input not instance of ${$.name}`})=>ZJ((J)=>J instanceof $,Q),gJ=H2.create,xJ=G1.create,lW=q8.create,dW=B1.create,fJ=U6.create,iW=k1.create,nW=e6.create,oW=W6.create,rW=V6.create,aW=T1.create,sW=Y1.create,tW=E2.create,eW=$8.create,$V=j2.create,QV=x0.create,JV=x0.strictCreate,qV=K6.create,XV=e8.create,YV=H6.create,GV=v2.create,BV=Q8.create,UV=J8.create,WV=Z1.create,VV=B6.create,KV=j6.create,HV=M6.create,jV=U1.create,MV=w6.create,wV=g1.create,FV=F2.create,LV=M2.create,zV=l2.create,OV=F2.createWithPreprocess,NV=X8.create,AV=()=>gJ().optional(),DV=()=>xJ().optional(),PV=()=>fJ().optional(),RV={string:($)=>H2.create({...$,coerce:!0}),number:($)=>G1.create({...$,coerce:!0}),boolean:($)=>U6.create({...$,coerce:!0}),bigint:($)=>B1.create({...$,coerce:!0}),date:($)=>k1.create({...$,coerce:!0})};var CV=w0;class k2 extends Error{field;regex;constructor($,Q,J){super(J);this.field=$,this.regex=Q}}class Y8 extends Error{hash;constructor($){super(`'${$}' not found in the root hash`);this.hash=$}}class i4 extends Map{#J;#$=0;constructor($,Q=[]){super();this.#J=$;for(let[J,q]of Q)this.set(J,q)}get($){let Q=super.get($);if(Q!==void 0)super.delete($),super.set($,Q);return Q}set($,Q){let J=super.get($);if(J===void 0)this.#$+=$.length;else if(J!==null)this.#$-=J.length;if(Q!==null)this.#$+=Q.length;super.delete($);let q;while(this.#$>this.#J&&(q=this.entries().next().value)){let[X,Y]=q;if(super.delete(X),this.#$-=X.length,Y!==null)this.#$-=Y.length}return super.set($,Q),this}delete($){let Q=super.get($);if(Q===void 0)return!1;if(super.delete($),Q!==null)this.#$-=Q.length;return this.#$-=$.length,!0}clear(){super.clear(),this.#$=0}}var mJ=V7(_J(),1);function bJ($){let Q=$.reduce((X,Y)=>X+Y.length,0),J=new Uint8Array(Q),q=0;for(let X of $)J.set(X,q),q+=X.length;return J}var Q5=/^[0-9a-f]{64}$/,uJ=g.object({name:g.string(),timestamp:g.number()}).passthrough(),IV=g.object({name:g.string(),pageId:g.string(),timestamp:g.number()}).passthrough(),SV=g.object({authors:g.array(g.string()).optional(),title:g.string().optional(),publicationDate:g.string().optional(),publisher:g.string().optional()}).passthrough(),EV=g.object({id:g.string(),idx:g.object({timestamp:g.string(),value:g.string()}).passthrough(),template:g.object({timestamp:g.string(),value:g.string()}).passthrough().optional(),redir:g.object({timestamp:g.string(),value:g.number().int()}).passthrough().optional(),scrollTime:g.object({timestamp:g.string(),value:g.string().datetime({offset:!0})}).passthrough().optional(),verticalScroll:g.object({timestamp:g.string(),value:g.number()}).passthrough().optional(),deleted:g.object({timestamp:g.string(),value:g.number().int()}).passthrough().optional()}).passthrough(),vV=g.object({lastOpened:g.object({timestamp:g.string(),value:g.string()}).passthrough(),original:g.object({timestamp:g.string(),value:g.number().int()}).passthrough(),pages:g.array(EV),uuids:g.array(g.object({first:g.string(),second:g.number().int().nonnegative()}).passthrough()).nullable()}).passthrough(),kV=g.object({tags:g.array(uJ).optional()}).strict(),TV=g.object({tags:g.array(g.string()).optional()}).strict(),ZV={coverPageNumber:g.number().int(),documentMetadata:SV,extraMetadata:g.record(g.string(),g.string()),fileType:g.enum(["epub","notebook","pdf"]),fontName:g.string(),lineHeight:g.number().int(),orientation:g.enum(["portrait","landscape"]),pageCount:g.number().int().nonnegative(),textAlignment:g.enum(["","justify","left"]),textScale:g.number()},gV={cPages:vV.optional(),customZoomCenterX:g.number().optional(),customZoomCenterY:g.number().optional(),customZoomOrientation:g.enum(["portrait","landscape"]).optional(),customZoomPageHeight:g.number().optional(),customZoomPageWidth:g.number().optional(),customZoomScale:g.number().optional(),dummyDocument:g.boolean().optional(),formatVersion:g.number().int().nonnegative().optional(),keyboardMetadata:g.object({count:g.number().int().nonnegative(),timestamp:g.number()}).passthrough().optional(),lastOpenedPage:g.number().int().optional(),margins:g.number().int().nonnegative().optional(),originalPageCount:g.number().int().optional(),pages:g.array(g.string()).nullable().optional(),pageTags:g.array(IV).optional(),redirectionPageMap:g.array(g.number().int()).optional(),sizeInBytes:g.string().optional(),transform:g.object({m11:g.number().optional(),m12:g.number().optional(),m13:g.number().optional(),m21:g.number().optional(),m22:g.number().optional(),m23:g.number().optional(),m31:g.number().optional(),m32:g.number().optional(),m33:g.number().optional()}).passthrough().optional(),viewBackgroundFilter:g.enum(["off","fullpage"]).optional(),zoomMode:g.enum(["bestFit","customFit","fitToHeight","fitToWidth"]).optional()},cJ=g.object({...ZV,...gV}).passthrough(),xV=cJ.extend({tags:g.array(uJ).optional()}).passthrough(),fV=cJ.extend({tags:g.array(g.string()).optional()}).passthrough(),yV=g.object({name:g.string(),author:g.string(),iconData:g.string(),categories:g.array(g.string()),labels:g.array(g.string()),orientation:g.enum(["portrait","landscape"]),templateVersion:g.string(),supportedScreens:g.array(g.enum(["rm2","rmPP"])),constants:g.array(g.record(g.string(),g.number().int())).optional(),items:g.array(g.unknown()),formatVersion:g.number().int().nonnegative().optional()}).strict(),_V=g.union([kV,TV,yV,xV,fV]),bV=g.object({lastModified:g.string(),parent:g.string(),pinned:g.boolean(),type:g.enum(["DocumentType","CollectionType","TemplateType"]),visibleName:g.string(),lastOpened:g.string().optional(),lastOpenedPage:g.number().int().optional(),createdTime:g.string().optional(),deleted:g.boolean().optional(),metadatamodified:g.boolean().optional(),modified:g.boolean().optional(),synced:g.boolean().optional(),version:g.number().int().nonnegative().optional(),new:g.boolean().optional(),source:g.string().optional()}).passthrough(),hV=g.object({hash:g.string(),generation:g.number()}).passthrough(),mV=g.object({hash:g.string(),generation:g.number(),schemaVersion:g.number().int().nonnegative()}).passthrough(),uV=g.object({docID:g.string(),hash:g.string()}).passthrough();async function o4($){let Q=await crypto.subtle.digest("SHA-256",$);return new Uint8Array(Q).toHex()}function hJ($){let[Q,J,q,X,Y]=$.split(":");if(Q===void 0||J===void 0||q===void 0||X===void 0||Y===void 0)throw Error(`line '${$}' was not formatted correctly`);else if(J==="80000000"||J==="0")return{hash:Q,type:J==="0"?0:80000000,id:q,subfiles:parseInt(X,10),size:parseInt(Y,10)};else throw Error(`line '${$}' was not formatted correctly`)}class r4{#J;#$;#X;#Q;constructor($,Q,J,q){this.#J=$,this.#Q=Q,this.#$=J,this.#X=q}async getRootHash(){let Q=await(await this.#J("GET",`${this.#$}/sync/v4/root`)).text(),J=JSON.parse(Q),{hash:q,generation:X,schemaVersion:Y}=mV.parse(J);if(Y!==3&&Y!==4)throw Error(`schema version ${Y} not supported`);else if(!Number.isSafeInteger(X))throw Error(`generation ${X} was not a safe integer; please file a bug report`);else return[q,X,Y]}async#q($,Q){if(!Q5.test(Q))throw new k2(Q,Q5,"hash was not a valid hash");let q=await(await this.#J("GET",`${this.#$}/sync/v3/files/${Q}`,{headers:{"rm-filename":$}})).arrayBuffer();return new Uint8Array(q)}async getHash($,Q){let J=this.#Q.get(Q);if(J!=null)return new TextEncoder().encode(J);else{let q=await this.#q($,Q);if(this.#Q.get(Q)===void 0)this.#Q.set(Q,null);return q}}async getText($,Q){let J=this.#Q.get(Q);if(J!=null)return J;else{let q=await this.#q($,Q),Y=new TextDecoder().decode(q);return this.#Q.set(Q,Y),Y}}async getEntries($,Q){let J=await this.getText($,Q),[q,...X]=J.slice(0,-1).split(`
|
|
4
4
|
`);if(q==="3")return{entries:X.map(hJ)};else if(q==="4"){let[Y,...G]=X;if(!Y)throw Error("missing info line for schema version 4");let[B,W,U,V]=Y.split(":");if(B!=="0"||W===void 0||U===void 0||V===void 0)throw Error(`schema 4 info line '${Y}' was not formatted correctly`);let L=G.map(hJ);if(parseInt(U,10)!==L.length)throw Error(`schema 4 expected ${U} entries, but found ${L.length}`);else return{entries:L,id:W,size:parseInt(V,10)}}else throw Error(`schema version ${q} not supported`)}async getContent($,Q){let J=await this.getText($,Q),q=JSON.parse(J);return _V.parse(q)}async getMetadata($,Q){let J=await this.getText($,Q),q=JSON.parse(J);return bV.parse(q)}async putRootHash($,Q,J=!0){if(!Number.isSafeInteger(Q))throw Error(`generation ${Q} was not a safe integer`);else if(!Q5.test($))throw new k2($,Q5,"rootHash was not a valid hash");let q=JSON.stringify({hash:$,generation:Q,broadcast:J}),Y=await(await this.#J("PUT",`${this.#$}/sync/v3/root`,{body:q})).text(),G=JSON.parse(Y),{hash:B,generation:W}=hV.parse(G);if(Number.isSafeInteger(W))return[B,W];else throw Error(`new generation ${W} was not a safe integer; please file a bug report`)}async#Y($,Q,J){if(!this.#Q.has(Q)){let q=mJ.default.buf(J,0),X=new ArrayBuffer(4);new DataView(X).setInt32(0,q,!1);let Y=new Uint8Array(X).toBase64();if(await this.#J("PUT",`${this.#$}/sync/v3/files/${Q}`,{body:J,headers:{"rm-filename":$,"x-goog-hash":`crc32c=${Y}`}}),this.#Q.get(Q)===void 0)this.#Q.set(Q,null)}}async putFile($,Q){let J=await o4(Q);return[{id:$,hash:J,type:0,subfiles:0,size:Q.length},this.#Y($,J,Q)]}async putText($,Q){let q=new TextEncoder().encode(Q),[X,Y]=await this.putFile($,q);return[X,Y.then(()=>{this.#Q.set(X.hash,Q)})]}async putContent($,Q){if(!$.endsWith(".content"))throw Error(`id ${$} did not end with '.content'`);else return await this.putText($,JSON.stringify(Q))}async putMetadata($,Q){if(!$.endsWith(".metadata"))throw Error(`id ${$} did not end with '.metadata'`);else return await this.putText($,JSON.stringify(Q))}async putEntries($,Q,J){if($==="root"&&J===3)console.warn('writing a schema 3 root index, which reMarkable rejects with a 400 "Software must be updated" error; write the root index with schema version 4 instead');let q=[...Q].sort((V,L)=>V.id.localeCompare(L.id)),X=q.reduce((V,L)=>V+L.size,0),Y=[`${J}
|
|
5
5
|
`];if(J===4){let V=$==="root"?".":$;Y.push(`0:${V}:${q.length}:${X}
|
|
6
6
|
`)}for(let{hash:V,type:L,id:w,subfiles:M,size:y}of q){let x=J===4?0:L;Y.push(`${V}:${x}:${w}:${M}:${y}
|
|
7
|
-
`)}let B=new TextEncoder().encode(Y.join("")),W;if(J===3){let V=[];for(let{hash:L}of q)V.push(Uint8Array.fromHex(L));W=await o4(bJ(V))}else if(J===4)W=await o4(B);else throw Error(`unsupported schema version ${J}`);return[{id:$,hash:W,type:J>3?0:80000000,subfiles:q.length,size:X},this.#Y(`${$}.docSchema`,W,B)]}async uploadFile($,Q,J){let X=new TextEncoder().encode(JSON.stringify({file_name:$})).toBase64(),G=await(await this.#J("POST",`${this.#X}/doc/v2/files`,{body:Q,headers:{"Content-Type":J,"rm-meta":X,"rm-source":"RoR-Browser"}})).json(),{docID:B,hash:W}=uV.parse(G);return{id:B,hash:W}}dumpCache(){return JSON.stringify(Object.fromEntries(this.#Q))}clearCache(){this.#Q.clear()}}var lJ="https://webapp-prod.cloud.remarkable.engineering",
|
|
8
|
-
`)throw new a4;else throw new s4(X.status,X.statusText,`failed reMarkable request: ${Y}`)}else return X}async#K({hash:$,id:Q}){let{entries:J}=await this.raw.getEntries(`${Q}.docSchema`,$),q=J.find((y)=>y.id.endsWith(".metadata")),X=J.find((y)=>y.id.endsWith(".content"));if(q===void 0)throw Error(`couldn't find metadata for hash ${$}`);let[{visibleName:Y,lastModified:G,pinned:B,parent:W,lastOpened:U,createdTime:V,new:L,source:w},M]=await Promise.all([this.raw.getMetadata(q.id,q.hash),X===void 0?Promise.resolve({fileType:void 0,tags:void 0}):this.raw.getContent(X.id,X.hash)]);if("templateVersion"in M)return{id:Q,hash:$,visibleName:Y,lastModified:G,new:L,pinned:B,source:w,parent:W,createdTime:V,type:"TemplateType"};else if(M.fileType===void 0)return{id:Q,hash:$,visibleName:Y,lastModified:G,pinned:B,parent:W,tags:M.tags,type:"CollectionType"};else return{id:Q,hash:$,visibleName:Y,lastModified:G,pinned:B,parent:W,tags:M.tags,lastOpened:U??"",fileType:M.fileType,type:"DocumentType"}}async listItems($=!1){let Q=await this.listIds($);return await Promise.all(Q.map((J)=>this.#K(J)))}async listIds($=!1){let[Q]=await this.#q($),{entries:J}=await this.raw.getEntries("root.docSchema",Q);return J.map(({id:q,hash:X})=>({id:q,hash:X}))}async getContent($,Q){let{entries:J}=await this.raw.getEntries(`${$}.docSchema`,Q),[q]=J.filter((X)=>X.id.endsWith(".content"));if(q===void 0)throw Error(`couldn't find contents for hash ${Q}`);else return await this.raw.getContent(q.id,q.hash)}async getMetadata($,Q){let{entries:J}=await this.raw.getEntries(`${$}.docSchema`,Q),[q]=J.filter((X)=>X.id.endsWith(".metadata"));if(q===void 0)throw Error(`couldn't find metadata for hash ${Q}`);else return await this.raw.getMetadata(q.id,q.hash)}async getPdf($,Q){let{entries:J}=await this.raw.getEntries(`${$}.docSchema`,Q),[q]=J.filter((X)=>X.id.endsWith(".pdf"));if(q===void 0)throw Error(`couldn't find pdf for hash ${Q}`);else return await this.raw.getHash(q.id,q.hash)}async getEpub($,Q){let{entries:J}=await this.raw.getEntries(`${$}.docSchema`,Q),[q]=J.filter((X)=>X.id.endsWith(".epub"));if(q===void 0)throw Error(`couldn't find epub for hash ${Q}`);else return await this.raw.getHash(q.id,q.hash)}async getDocument($,Q){let{entries:J}=await this.raw.getEntries(`${$}.docSchema`,Q),q=new pJ.default;for(let X of J)q.file(X.id,this.raw.getHash(X.id,X.hash));return q.generateAsync({type:"uint8array"})}async#U($,Q,J,{refresh:q,parent:X="",pinned:Y=!1,zoomMode:G="bestFit",viewBackgroundFilter:B,textScale:W=1,textAlignment:U="justify",fontName:V="",coverPageNumber:L=-1,authors:w,title:M,publicationDate:y,publisher:x,extraMetadata:A={},lineHeight:
|
|
9
|
-
`),this.raw.putFile(`${
|
|
7
|
+
`)}let B=new TextEncoder().encode(Y.join("")),W;if(J===3){let V=[];for(let{hash:L}of q)V.push(Uint8Array.fromHex(L));W=await o4(bJ(V))}else if(J===4)W=await o4(B);else throw Error(`unsupported schema version ${J}`);return[{id:$,hash:W,type:J>3?0:80000000,subfiles:q.length,size:X},this.#Y(`${$}.docSchema`,W,B)]}async uploadFile($,Q,J){let X=new TextEncoder().encode(JSON.stringify({file_name:$})).toBase64(),G=await(await this.#J("POST",`${this.#X}/doc/v2/files`,{body:Q,headers:{"Content-Type":J,"rm-meta":X,"rm-source":"RoR-Browser"}})).json(),{docID:B,hash:W}=uV.parse(G);return{id:B,hash:W}}dumpCache(){return JSON.stringify(Object.fromEntries(this.#Q))}clearCache(){this.#Q.clear()}}var cV={RM100:{name:"reMarkable 1",width:1404,height:1872,dpi:226},RM110:{name:"reMarkable 2",width:1404,height:1872,dpi:226},RM02A:{name:"reMarkable Paper Pro",width:1620,height:2160,dpi:229},RM03A:{name:"reMarkable Paper Pro Move",width:954,height:1696,dpi:264},RM102:{name:"reMarkable Paper Pure",width:1404,height:1872,dpi:226}};var lJ="https://webapp-prod.cloud.remarkable.engineering",pV="https://eu.tectonic.remarkable.com",lV="https://internal.cloud.remarkable.com",W1=/^([0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}||trash)$/;class a4 extends Error{constructor(){super("root generation was stale; try put again")}}class s4 extends Error{status;statusText;constructor($,Q,J){super(J);this.status=$,this.statusText=Q}}async function Fj($,{deviceDesc:Q="browser-chrome",uuid:J=q6(),authHost:q=lJ}={}){if($.length!==8)throw Error(`code should be length 8, but was ${$.length}`);let X=await fetch(`${q}/token/json/2/device/new`,{method:"POST",headers:{Authorization:"Bearer"},body:JSON.stringify({code:$,deviceDesc:Q,deviceID:J})});if(!X.ok)throw new s4(X.status,X.statusText,"couldn't register api");else return await X.text()}class dJ{#J;#$;raw;#X;#Q;constructor($,Q,J,q){this.#J=$,this.#$=q,this.raw=new r4((X,Y,{body:G,headers:B}={})=>this.#V(Y,{method:X,body:G,headers:B}),q,Q,J)}async#q($=!1){if($||this.#X===void 0){let[Q,J,q]=await this.raw.getRootHash();this.#X=[Q,J],this.#Q=q}return[...this.#X,this.#Q]}async#Y($,Q){try{let[J,q]=await this.raw.putRootHash($,Q);this.#X=[J,q]}catch(J){if(J instanceof a4)this.#X=void 0;throw J}}async#V($,{body:Q,method:J="POST",headers:q={}}){let X=await fetch($,{method:J,headers:{Authorization:`Bearer ${this.#J}`,...q},body:Q});if(!X.ok){let Y=await X.text();if(Y===`{"message":"precondition failed"}
|
|
8
|
+
`)throw new a4;else throw new s4(X.status,X.statusText,`failed reMarkable request: ${Y}`)}else return X}async#K({hash:$,id:Q}){let{entries:J}=await this.raw.getEntries(`${Q}.docSchema`,$),q=J.find((y)=>y.id.endsWith(".metadata")),X=J.find((y)=>y.id.endsWith(".content"));if(q===void 0)throw Error(`couldn't find metadata for hash ${$}`);let[{visibleName:Y,lastModified:G,pinned:B,parent:W,lastOpened:U,createdTime:V,new:L,source:w},M]=await Promise.all([this.raw.getMetadata(q.id,q.hash),X===void 0?Promise.resolve({fileType:void 0,tags:void 0}):this.raw.getContent(X.id,X.hash)]);if("templateVersion"in M)return{id:Q,hash:$,visibleName:Y,lastModified:G,new:L,pinned:B,source:w,parent:W,createdTime:V,type:"TemplateType"};else if(M.fileType===void 0)return{id:Q,hash:$,visibleName:Y,lastModified:G,pinned:B,parent:W,tags:M.tags,type:"CollectionType"};else return{id:Q,hash:$,visibleName:Y,lastModified:G,pinned:B,parent:W,tags:M.tags,lastOpened:U??"",fileType:M.fileType,type:"DocumentType"}}async listItems($=!1){let Q=await this.listIds($);return await Promise.all(Q.map((J)=>this.#K(J)))}async listIds($=!1){let[Q]=await this.#q($),{entries:J}=await this.raw.getEntries("root.docSchema",Q);return J.map(({id:q,hash:X})=>({id:q,hash:X}))}async getContent($,Q){let{entries:J}=await this.raw.getEntries(`${$}.docSchema`,Q),[q]=J.filter((X)=>X.id.endsWith(".content"));if(q===void 0)throw Error(`couldn't find contents for hash ${Q}`);else return await this.raw.getContent(q.id,q.hash)}async getMetadata($,Q){let{entries:J}=await this.raw.getEntries(`${$}.docSchema`,Q),[q]=J.filter((X)=>X.id.endsWith(".metadata"));if(q===void 0)throw Error(`couldn't find metadata for hash ${Q}`);else return await this.raw.getMetadata(q.id,q.hash)}async getPdf($,Q){let{entries:J}=await this.raw.getEntries(`${$}.docSchema`,Q),[q]=J.filter((X)=>X.id.endsWith(".pdf"));if(q===void 0)throw Error(`couldn't find pdf for hash ${Q}`);else return await this.raw.getHash(q.id,q.hash)}async getEpub($,Q){let{entries:J}=await this.raw.getEntries(`${$}.docSchema`,Q),[q]=J.filter((X)=>X.id.endsWith(".epub"));if(q===void 0)throw Error(`couldn't find epub for hash ${Q}`);else return await this.raw.getHash(q.id,q.hash)}async getDocument($,Q){let{entries:J}=await this.raw.getEntries(`${$}.docSchema`,Q),q=new pJ.default;for(let X of J)q.file(X.id,this.raw.getHash(X.id,X.hash));return q.generateAsync({type:"uint8array"})}async#U($,Q,J,{refresh:q,parent:X="",pinned:Y=!1,zoomMode:G="bestFit",viewBackgroundFilter:B,textScale:W=1,textAlignment:U="justify",fontName:V="",coverPageNumber:L=-1,authors:w,title:M,publicationDate:y,publisher:x,extraMetadata:A={},lineHeight:D=-1,margins:K=125,orientation:F="portrait",tags:z,customZoomScale:R,customZoomCenterX:_,customZoomCenterY:T,customZoomPageWidth:l,customZoomPageHeight:S,customZoomOrientation:E}){if(X&&!W1.test(X))throw new k2(X,W1,"parent must be a valid document id");let P=q6(),O=new Date,Z={parent:X,pinned:Y,lastModified:(+O).toFixed(),createdTime:(+O).toFixed(),type:"DocumentType",visibleName:$,lastOpened:"0",lastOpenedPage:0},f={coverPageNumber:L,documentMetadata:{authors:w,title:M,publicationDate:y,publisher:x},extraMetadata:A,lineHeight:D,margins:K,orientation:F,fileType:Q,formatVersion:1,tags:z?.map((c)=>({name:c,timestamp:+O}))??[],fontName:V,textAlignment:U,textScale:W,zoomMode:G,customZoomScale:R,customZoomCenterX:_,customZoomCenterY:T,customZoomPageWidth:l,customZoomPageHeight:S,customZoomOrientation:E,viewBackgroundFilter:B,originalPageCount:1,pageCount:1,pageTags:[],pages:[q6()],redirectionPageMap:[0],sizeInBytes:J.length.toFixed()},[[k,s],[J0,B0],[N0,p],[K0,N],[d,Y0,m]]=await Promise.all([this.raw.putContent(`${P}.content`,f),this.raw.putMetadata(`${P}.metadata`,Z),this.raw.putText(`${P}.pagedata`,`
|
|
9
|
+
`),this.raw.putFile(`${P}.${Q}`,J),this.#q(q)]),[[U0,M0],{entries:P0}]=await Promise.all([this.raw.putEntries(P,[k,J0,N0,K0],m),this.raw.getEntries("root.docSchema",d)]);P0.push(U0);let[z0,u]=await this.raw.putEntries("root",P0,4);return await Promise.all([s,B0,p,N,M0,u]),await this.#Y(z0.hash,Y0),{id:P,hash:U0.hash}}async putPdf($,Q,J={}){return await this.#U($,"pdf",Q,J)}async putEpub($,Q,J={}){return await this.#U($,"epub",Q,J)}async putFolder($,{parent:Q=""}={},J=!1){if(Q&&!W1.test(Q))throw new k2(Q,W1,"parent must be a valid document id");let q=q6(),X=new Date,Y={tags:[]},G={lastModified:(+X).toFixed(),createdTime:(+X).toFixed(),parent:Q,pinned:!1,type:"CollectionType",visibleName:$},[[B,W],[U,V],[L,w,M]]=await Promise.all([this.raw.putContent(`${q}.content`,Y),this.raw.putMetadata(`${q}.metadata`,G),this.#q(J)]),[[y,x],{entries:A}]=await Promise.all([this.raw.putEntries(q,[B,U],M),this.raw.getEntries("root.docSchema",L)]);A.push(y);let[D,K]=await this.raw.putEntries("root",A,4);return await Promise.all([W,V,x,K]),await this.#Y(D.hash,w),{id:q,hash:y.hash}}async uploadEpub($,Q){return await this.raw.uploadFile($,Q,"application/epub+zip")}async uploadPdf($,Q){return await this.raw.uploadFile($,Q,"application/pdf")}async uploadFolder($){return await this.raw.uploadFile($,new Uint8Array(0),"folder")}async#H($,Q,J,q){let{entries:X}=await this.raw.getEntries(`${$}.docSchema`,Q),Y=X.findIndex((M)=>M.id.endsWith(".content")),G=X[Y];if(G===void 0)throw Error("internal error: couldn't find content in entry hash");let B=await this.raw.getContent(G.id,G.hash);Object.assign(B,J);let[W,U]=await this.raw.putContent(G.id,B);X[Y]=W;let[V,L]=await this.raw.putEntries($,X,q),w=Promise.all([U,L]);return[V,w]}async#G($,Q,J,q){let[X,Y,G]=await this.#q(q),{entries:B}=await this.raw.getEntries("root.docSchema",X),W=B.findIndex((x)=>x.hash===$),U=B[W];if(U===void 0)throw new Y8($);let[[V,L],w]=await Promise.all([this.#H(U.id,$,Q,G),this.getMetadata(U.id,$)]);if(w.type!==J)throw Error(`expected type ${J} but got ${w.type} for hash ${$}`);B[W]=V;let[M,y]=await this.raw.putEntries("root",B,4);return await Promise.all([L,y]),await this.#Y(M.hash,Y),{hash:V.hash}}async updateDocument($,Q,J=!1){return await this.#G($,Q,"DocumentType",J)}async updateCollection($,Q,J=!1){return await this.#G($,Q,"CollectionType",J)}async updateTemplate($,Q,J=!1){return await this.#G($,Q,"TemplateType",J)}async#W($,Q,J,q){let{entries:X}=await this.raw.getEntries(`${$}.docSchema`,Q),Y=X.findIndex((M)=>M.id.endsWith(".metadata")),G=X[Y];if(G===void 0)throw Error("internal error: couldn't find metadata in entry hash");let B=await this.raw.getMetadata(G.id,G.hash);Object.assign(B,J);let[W,U]=await this.raw.putMetadata(G.id,B);X[Y]=W;let[V,L]=await this.raw.putEntries($,X,q),w=Promise.all([U,L]);return[V,w]}async#B($,Q,J=!1){let[q,X,Y]=await this.#q(J),{entries:G}=await this.raw.getEntries("root.docSchema",q),B=G.findIndex((M)=>M.hash===$),W=G[B];if(W===void 0)throw new Y8($);let[U,V]=await this.#W(W.id,$,Q,Y);G[B]=U;let[L,w]=await this.raw.putEntries("root",G,4);return await Promise.all([V,w]),await this.#Y(L.hash,X),{hash:U.hash}}async move($,Q,J=!1){if(!W1.test(Q))throw new k2(Q,W1,"parent must be a valid document id");return await this.#B($,{parent:Q},J)}async delete($,Q=!1){return await this.move($,"trash",Q)}async rename($,Q,J=!1){return await this.#B($,{visibleName:Q},J)}async stared($,Q,J=!1){return await this.#B($,{pinned:Q},J)}async bulkMove($,Q,J=!1){if(!W1.test(Q))throw new k2(Q,W1,"parent must be a valid document id");let[q,X,Y]=await this.#q(J),{entries:G}=await this.raw.getEntries("root.docSchema",q),B=new Set($),W=[],U=[];for(let x of G)(B.has(x.hash)?W:U).push(x);let V=await Promise.all(W.map(({id:x,hash:A})=>this.#W(x,A,{parent:Q},Y))),L=[],w={};for(let[x,[A,D]]of V.entries())U.push(A),L.push(D),w[W[x].hash]=A.hash;let[M,y]=await this.raw.putEntries("root",U,4);return await Promise.all([Promise.all(L),y]),await this.#Y(M.hash,X),{hashes:w}}async bulkDelete($,Q=!1){return await this.bulkMove($,"trash",Q)}dumpCache(){return this.raw.dumpCache()}async pruneCache($){let[Q]=await this.#q($),J=new Set(this.#$.keys());J.delete(Q);let X=[(await this.raw.getEntries("root.docSchema",Q)).entries],Y=[];while(X.length){for(let B of X)for(let{hash:W,subfiles:U,id:V}of B)if(J.delete(W),U>0)Y.push(this.raw.getEntries(`${V}.docSchema`,W));X=(await Promise.all(Y)).map((B)=>B.entries),Y=[]}for(let G of J)this.#$.delete(G)}clearCache(){this.raw.clearCache()}}var dV=g.record(g.string(),g.string().nullable());async function iV($,{authHost:Q=lJ}={}){let J=await fetch(`${Q}/token/json/2/user/new`,{method:"POST",headers:{Authorization:`Bearer ${$}`}});if(!J.ok)throw Error(`couldn't fetch auth token: ${J.statusText}`);return await J.text()}function nV($,{rawHost:Q=pV,uploadHost:J=lV,cache:q,maxCacheSize:X=1/0}={}){let Y=JSON.parse(q??"{}"),G=dV.safeParse(Y);if(G.success){let B=Object.entries(G.data),W=X===1/0?new Map(B):new i4(X,B);return new dJ($,Q,J,W)}throw Error("cache was not a valid cache (json string mapping); your cache must be corrupted somehow. Either initialize remarkable without a cache, or fix its format.")}async function Lj($,Q={}){let{authHost:J,rawHost:q,uploadHost:X,cache:Y,maxCacheSize:G}=Q??{},B=await iV($,{authHost:J});return nV(B,{rawHost:q,uploadHost:X,cache:Y,maxCacheSize:G})}export{nV as session,Lj as remarkable,Fj as register,cV as deviceScreens,iV as auth,k2 as ValidationError,s4 as ResponseError,Y8 as HashNotFoundError,a4 as GenerationError};
|