You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
nextcloud-server/dist/string_decoder-BO00msnV.chu...

2 lines
58 KiB

var Kt={},Pt={};Pt.byteLength=oe,Pt.toByteArray=se,Pt.fromByteArray=he;for(var ht=[],rt=[],ne=typeof Uint8Array<"u"?Uint8Array:Array,Gt="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",vt=0,re=Gt.length;vt<re;++vt)ht[vt]=Gt[vt],rt[Gt.charCodeAt(vt)]=vt;rt[45]=62,rt[95]=63;function Zt(E){var m=E.length;if(m%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var O=E.indexOf("=");O===-1&&(O=m);var A=O===m?0:4-O%4;return[O,A]}function oe(E){var m=Zt(E),O=m[0],A=m[1];return(O+A)*3/4-A}function ie(E,m,O){return(m+O)*3/4-O}function se(E){var m,O=Zt(E),A=O[0],U=O[1],B=new ne(ie(E,A,U)),v=0,S=U>0?A-4:A,_;for(_=0;_<S;_+=4)m=rt[E.charCodeAt(_)]<<18|rt[E.charCodeAt(_+1)]<<12|rt[E.charCodeAt(_+2)]<<6|rt[E.charCodeAt(_+3)],B[v++]=m>>16&255,B[v++]=m>>8&255,B[v++]=m&255;return U===2&&(m=rt[E.charCodeAt(_)]<<2|rt[E.charCodeAt(_+1)]>>4,B[v++]=m&255),U===1&&(m=rt[E.charCodeAt(_)]<<10|rt[E.charCodeAt(_+1)]<<4|rt[E.charCodeAt(_+2)]>>2,B[v++]=m>>8&255,B[v++]=m&255),B}function fe(E){return ht[E>>18&63]+ht[E>>12&63]+ht[E>>6&63]+ht[E&63]}function ue(E,m,O){for(var A,U=[],B=m;B<O;B+=3)A=(E[B]<<16&16711680)+(E[B+1]<<8&65280)+(E[B+2]&255),U.push(fe(A));return U.join("")}function he(E){for(var m,O=E.length,A=O%3,U=[],B=16383,v=0,S=O-A;v<S;v+=B)U.push(ue(E,v,v+B>S?S:v+B));return A===1?(m=E[O-1],U.push(ht[m>>2]+ht[m<<4&63]+"==")):A===2&&(m=(E[O-2]<<8)+E[O-1],U.push(ht[m>>10]+ht[m>>4&63]+ht[m<<2&63]+"=")),U.join("")}var Wt={};Wt.read=function(E,m,O,A,U){var B,v,S=U*8-A-1,_=(1<<S)-1,C=_>>1,a=-7,q=O?U-1:0,et=O?-1:1,K=E[m+q];for(q+=et,B=K&(1<<-a)-1,K>>=-a,a+=S;a>0;B=B*256+E[m+q],q+=et,a-=8);for(v=B&(1<<-a)-1,B>>=-a,a+=A;a>0;v=v*256+E[m+q],q+=et,a-=8);if(B===0)B=1-C;else{if(B===_)return v?NaN:(K?-1:1)*(1/0);v=v+Math.pow(2,A),B=B-C}return(K?-1:1)*v*Math.pow(2,B-A)},Wt.write=function(E,m,O,A,U,B){var v,S,_,C=B*8-U-1,a=(1<<C)-1,q=a>>1,et=U===23?Math.pow(2,-24)-Math.pow(2,-77):0,K=A?0:B-1,ot=A?1:-1,wt=m<0||m===0&&1/m<0?1:0;for(m=Math.abs(m),isNaN(m)||m===1/0?(S=isNaN(m)?1:0,v=a):(v=Math.floor(Math.log(m)/Math.LN2),m*(_=Math.pow(2,-v))<1&&(v--,_*=2),v+q>=1?m+=et/_:m+=et*Math.pow(2,1-q),m*_>=2&&(v++,_/=2),v+q>=a?(S=0,v=a):v+q>=1?(S=(m*_-1)*Math.pow(2,U),v=v+q):(S=m*Math.pow(2,q-1)*Math.pow(2,U),v=0));U>=8;E[O+K]=S&255,K+=ot,S/=256,U-=8);for(v=v<<U|S,C+=U;C>0;E[O+K]=v&255,K+=ot,v/=256,C-=8);E[O+K-ot]|=wt*128};(function(E){const m=Pt,O=Wt,A=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;E.Buffer=a,E.SlowBuffer=L,E.INSPECT_MAX_BYTES=50;const U=2147483647;E.kMaxLength=U;const{Uint8Array:B,ArrayBuffer:v,SharedArrayBuffer:S}=globalThis;a.TYPED_ARRAY_SUPPORT=_(),!a.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function _(){try{const t=new B(1),n={foo:function(){return 42}};return Object.setPrototypeOf(n,B.prototype),Object.setPrototypeOf(t,n),t.foo()===42}catch{return!1}}Object.defineProperty(a.prototype,"parent",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.buffer}}),Object.defineProperty(a.prototype,"offset",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.byteOffset}});function C(t){if(t>U)throw new RangeError('The value "'+t+'" is invalid for option "size"');const n=new B(t);return Object.setPrototypeOf(n,a.prototype),n}function a(t,n,o){if(typeof t=="number"){if(typeof n=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return ot(t)}return q(t,n,o)}a.poolSize=8192;function q(t,n,o){if(typeof t=="string")return wt(t,n);if(v.isView(t))return g(t);if(t==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);if(nt(t,v)||t&&nt(t.buffer,v)||typeof S<"u"&&(nt(t,S)||t&&nt(t.buffer,S)))return y(t,n,o);if(typeof t=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const s=t.valueOf&&t.valueOf();if(s!=null&&s!==t)return a.from(s,n,o);const u=d(t);if(u)return u;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof t[Symbol.toPrimitive]=="function")return a.from(t[Symbol.toPrimitive]("string"),n,o);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t)}a.from=function(t,n,o){return q(t,n,o)},Object.setPrototypeOf(a.prototype,B.prototype),Object.setPrototypeOf(a,B);function et(t){if(typeof t!="number")throw new TypeError('"size" argument must be of type number');if(t<0)throw new RangeError('The value "'+t+'" is invalid for option "size"')}function K(t,n,o){return et(t),t<=0?C(t):n!==void 0?typeof o=="string"?C(t).fill(n,o):C(t).fill(n):C(t)}a.alloc=function(t,n,o){return K(t,n,o)};function ot(t){return et(t),C(t<0?0:T(t)|0)}a.allocUnsafe=function(t){return ot(t)},a.allocUnsafeSlow=function(t){return ot(t)};function wt(t,n){if((typeof n!="string"||n==="")&&(n="utf8"),!a.isEncoding(n))throw new TypeError("Unknown encoding: "+n);const o=N(t,n)|0;let s=C(o);const u=s.write(t,n);return u!==o&&(s=s.slice(0,u)),s}function at(t){const n=t.length<0?0:T(t.length)|0,o=C(n);for(let s=0;s<n;s+=1)o[s]=t[s]&255;return o}function g(t){if(nt(t,B)){const n=new B(t);return y(n.buffer,n.byteOffset,n.byteLength)}return at(t)}function y(t,n,o){if(n<0||t.byteLength<n)throw new RangeError('"offset" is outside of buffer bounds');if(t.byteLength<n+(o||0))throw new RangeError('"length" is outside of buffer bounds');let s;return n===void 0&&o===void 0?s=new B(t):o===void 0?s=new B(t,n):s=new B(t,n,o),Object.setPrototypeOf(s,a.prototype),s}function d(t){if(a.isBuffer(t)){const n=T(t.length)|0,o=C(n);return o.length===0||t.copy(o,0,0,n),o}if(t.length!==void 0)return typeof t.length!="number"||Bt(t.length)?C(0):at(t);if(t.type==="Buffer"&&Array.isArray(t.data))return at(t.data)}function T(t){if(t>=U)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+U.toString(16)+" bytes");return t|0}function L(t){return+t!=t&&(t=0),a.alloc(+t)}a.isBuffer=function(t){return t!=null&&t._isBuffer===!0&&t!==a.prototype},a.compare=function(t,n){if(nt(t,B)&&(t=a.from(t,t.offset,t.byteLength)),nt(n,B)&&(n=a.from(n,n.offset,n.byteLength)),!a.isBuffer(t)||!a.isBuffer(n))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(t===n)return 0;let o=t.length,s=n.length;for(let u=0,c=Math.min(o,s);u<c;++u)if(t[u]!==n[u]){o=t[u],s=n[u];break}return o<s?-1:s<o?1:0},a.isEncoding=function(t){switch(String(t).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}},a.concat=function(t,n){if(!Array.isArray(t))throw new TypeError('"list" argument must be an Array of Buffers');if(t.length===0)return a.alloc(0);let o;if(n===void 0)for(n=0,o=0;o<t.length;++o)n+=t[o].length;const s=a.allocUnsafe(n);let u=0;for(o=0;o<t.length;++o){let c=t[o];if(nt(c,B))u+c.length>s.length?(a.isBuffer(c)||(c=a.from(c)),c.copy(s,u)):B.prototype.set.call(s,c,u);else if(a.isBuffer(c))c.copy(s,u);else throw new TypeError('"list" argument must be an Array of Buffers');u+=c.length}return s};function N(t,n){if(a.isBuffer(t))return t.length;if(v.isView(t)||nt(t,v))return t.byteLength;if(typeof t!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof t);const o=t.length,s=arguments.length>2&&arguments[2]===!0;if(!s&&o===0)return 0;let u=!1;for(;;)switch(n){case"ascii":case"latin1":case"binary":return o;case"utf8":case"utf-8":return Ot(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return o*2;case"hex":return o>>>1;case"base64":return Q(t).length;default:if(u)return s?-1:Ot(t).length;n=(""+n).toLowerCase(),u=!0}}a.byteLength=N;function I(t,n,o){let s=!1;if((n===void 0||n<0)&&(n=0),n>this.length||((o===void 0||o>this.length)&&(o=this.length),o<=0)||(o>>>=0,n>>>=0,o<=n))return"";for(t||(t="utf8");;)switch(t){case"hex":return It(this,n,o);case"utf8":case"utf-8":return mt(this,n,o);case"ascii":return Lt(this,n,o);case"latin1":case"binary":return Ft(this,n,o);case"base64":return lt(this,n,o);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return jt(this,n,o);default:if(s)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),s=!0}}a.prototype._isBuffer=!0;function R(t,n,o){const s=t[n];t[n]=t[o],t[o]=s}a.prototype.swap16=function(){const t=this.length;if(t%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let n=0;n<t;n+=2)R(this,n,n+1);return this},a.prototype.swap32=function(){const t=this.length;if(t%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let n=0;n<t;n+=4)R(this,n,n+3),R(this,n+1,n+2);return this},a.prototype.swap64=function(){const t=this.length;if(t%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let n=0;n<t;n+=8)R(this,n,n+7),R(this,n+1,n+6),R(this,n+2,n+5),R(this,n+3,n+4);return this},a.prototype.toString=function(){const t=this.length;return t===0?"":arguments.length===0?mt(this,0,t):I.apply(this,arguments)},a.prototype.toLocaleString=a.prototype.toString,a.prototype.equals=function(t){if(!a.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t?!0:a.compare(this,t)===0},a.prototype.inspect=function(){let t="";const n=E.INSPECT_MAX_BYTES;return t=this.toString("hex",0,n).replace(/(.{2})/g,"$1 ").trim(),this.length>n&&(t+=" ... "),"<Buffer "+t+">"},A&&(a.prototype[A]=a.prototype.inspect),a.prototype.compare=function(t,n,o,s,u){if(nt(t,B)&&(t=a.from(t,t.offset,t.byteLength)),!a.isBuffer(t))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof t);if(n===void 0&&(n=0),o===void 0&&(o=t?t.length:0),s===void 0&&(s=0),u===void 0&&(u=this.length),n<0||o>t.length||s<0||u>this.length)throw new RangeError("out of range index");if(s>=u&&n>=o)return 0;if(s>=u)return-1;if(n>=o)return 1;if(n>>>=0,o>>>=0,s>>>=0,u>>>=0,this===t)return 0;let c=u-s,w=o-n;const $=Math.min(c,w),G=this.slice(s,u),F=t.slice(n,o);for(let M=0;M<$;++M)if(G[M]!==F[M]){c=G[M],w=F[M];break}return c<w?-1:w<c?1:0};function Y(t,n,o,s,u){if(t.length===0)return-1;if(typeof o=="string"?(s=o,o=0):o>2147483647?o=2147483647:o<-2147483648&&(o=-2147483648),o=+o,Bt(o)&&(o=u?0:t.length-1),o<0&&(o=t.length+o),o>=t.length){if(u)return-1;o=t.length-1}else if(o<0)if(u)o=0;else return-1;if(typeof n=="string"&&(n=a.from(n,s)),a.isBuffer(n))return n.length===0?-1:P(t,n,o,s,u);if(typeof n=="number")return n=n&255,typeof B.prototype.indexOf=="function"?u?B.prototype.indexOf.call(t,n,o):B.prototype.lastIndexOf.call(t,n,o):P(t,[n],o,s,u);throw new TypeError("val must be string, number or Buffer")}function P(t,n,o,s,u){let c=1,w=t.length,$=n.length;if(s!==void 0&&(s=String(s).toLowerCase(),s==="ucs2"||s==="ucs-2"||s==="utf16le"||s==="utf-16le")){if(t.length<2||n.length<2)return-1;c=2,w/=2,$/=2,o/=2}function G(M,z){return c===1?M[z]:M.readUInt16BE(z*c)}let F;if(u){let M=-1;for(F=o;F<w;F++)if(G(t,F)===G(n,M===-1?0:F-M)){if(M===-1&&(M=F),F-M+1===$)return M*c}else M!==-1&&(F-=F-M),M=-1}else for(o+$>w&&(o=w-$),F=o;F>=0;F--){let M=!0;for(let z=0;z<$;z++)if(G(t,F+z)!==G(n,z)){M=!1;break}if(M)return F}return-1}a.prototype.includes=function(t,n,o){return this.indexOf(t,n,o)!==-1},a.prototype.indexOf=function(t,n,o){return Y(this,t,n,o,!0)},a.prototype.lastIndexOf=function(t,n,o){return Y(this,t,n,o,!1)};function X(t,n,o,s){o=Number(o)||0;const u=t.length-o;s?(s=Number(s),s>u&&(s=u)):s=u;const c=n.length;s>c/2&&(s=c/2);let w;for(w=0;w<s;++w){const $=parseInt(n.substr(w*2,2),16);if(Bt($))return w;t[o+w]=$}return w}function l(t,n,o,s){return bt(Ot(n,t.length-o),t,o,s)}function H(t,n,o,s){return bt(zt(n),t,o,s)}function it(t,n,o,s){return bt(Q(n),t,o,s)}function tt(t,n,o,s){return bt(V(n,t.length-o),t,o,s)}a.prototype.write=function(t,n,o,s){if(n===void 0)s="utf8",o=this.length,n=0;else if(o===void 0&&typeof n=="string")s=n,o=this.length,n=0;else if(isFinite(n))n=n>>>0,isFinite(o)?(o=o>>>0,s===void 0&&(s="utf8")):(s=o,o=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const u=this.length-n;if((o===void 0||o>u)&&(o=u),t.length>0&&(o<0||n<0)||n>this.length)throw new RangeError("Attempt to write outside buffer bounds");s||(s="utf8");let c=!1;for(;;)switch(s){case"hex":return X(this,t,n,o);case"utf8":case"utf-8":return l(this,t,n,o);case"ascii":case"latin1":case"binary":return H(this,t,n,o);case"base64":return it(this,t,n,o);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return tt(this,t,n,o);default:if(c)throw new TypeError("Unknown encoding: "+s);s=(""+s).toLowerCase(),c=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function lt(t,n,o){return n===0&&o===t.length?m.fromByteArray(t):m.fromByteArray(t.slice(n,o))}function mt(t,n,o){o=Math.min(t.length,o);const s=[];let u=n;for(;u<o;){const c=t[u];let w=null,$=c>239?4:c>223?3:c>191?2:1;if(u+$<=o){let G,F,M,z;switch($){case 1:c<128&&(w=c);break;case 2:G=t[u+1],(G&192)===128&&(z=(c&31)<<6|G&63,z>127&&(w=z));break;case 3:G=t[u+1],F=t[u+2],(G&192)===128&&(F&192)===128&&(z=(c&15)<<12|(G&63)<<6|F&63,z>2047&&(z<55296||z>57343)&&(w=z));break;case 4:G=t[u+1],F=t[u+2],M=t[u+3],(G&192)===128&&(F&192)===128&&(M&192)===128&&(z=(c&15)<<18|(G&63)<<12|(F&63)<<6|M&63,z>65535&&z<1114112&&(w=z))}}w===null?(w=65533,$=1):w>65535&&(w-=65536,s.push(w>>>10&1023|55296),w=56320|w&1023),s.push(w),u+=$}return $t(s)}const Et=4096;function $t(t){const n=t.length;if(n<=Et)return String.fromCharCode.apply(String,t);let o="",s=0;for(;s<n;)o+=String.fromCharCode.apply(String,t.slice(s,s+=Et));return o}function Lt(t,n,o){let s="";o=Math.min(t.length,o);for(let u=n;u<o;++u)s+=String.fromCharCode(t[u]&127);return s}function Ft(t,n,o){let s="";o=Math.min(t.length,o);for(let u=n;u<o;++u)s+=String.fromCharCode(t[u]);return s}function It(t,n,o){const s=t.length;(!n||n<0)&&(n=0),(!o||o<0||o>s)&&(o=s);let u="";for(let c=n;c<o;++c)u+=Mt[t[c]];return u}function jt(t,n,o){const s=t.slice(n,o);let u="";for(let c=0;c<s.length-1;c+=2)u+=String.fromCharCode(s[c]+s[c+1]*256);return u}a.prototype.slice=function(t,n){const o=this.length;t=~~t,n=n===void 0?o:~~n,t<0?(t+=o,t<0&&(t=0)):t>o&&(t=o),n<0?(n+=o,n<0&&(n=0)):n>o&&(n=o),n<t&&(n=t);const s=this.subarray(t,n);return Object.setPrototypeOf(s,a.prototype),s};function x(t,n,o){if(t%1!==0||t<0)throw new RangeError("offset is not uint");if(t+n>o)throw new RangeError("Trying to access beyond buffer length")}a.prototype.readUintLE=a.prototype.readUIntLE=function(t,n,o){t=t>>>0,n=n>>>0,o||x(t,n,this.length);let s=this[t],u=1,c=0;for(;++c<n&&(u*=256);)s+=this[t+c]*u;return s},a.prototype.readUintBE=a.prototype.readUIntBE=function(t,n,o){t=t>>>0,n=n>>>0,o||x(t,n,this.length);let s=this[t+--n],u=1;for(;n>0&&(u*=256);)s+=this[t+--n]*u;return s},a.prototype.readUint8=a.prototype.readUInt8=function(t,n){return t=t>>>0,n||x(t,1,this.length),this[t]},a.prototype.readUint16LE=a.prototype.readUInt16LE=function(t,n){return t=t>>>0,n||x(t,2,this.length),this[t]|this[t+1]<<8},a.prototype.readUint16BE=a.prototype.readUInt16BE=function(t,n){return t=t>>>0,n||x(t,2,this.length),this[t]<<8|this[t+1]},a.prototype.readUint32LE=a.prototype.readUInt32LE=function(t,n){return t=t>>>0,n||x(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+this[t+3]*16777216},a.prototype.readUint32BE=a.prototype.readUInt32BE=function(t,n){return t=t>>>0,n||x(t,4,this.length),this[t]*16777216+(this[t+1]<<16|this[t+2]<<8|this[t+3])},a.prototype.readBigUInt64LE=st(function(t){t=t>>>0,ct(t,"offset");const n=this[t],o=this[t+7];(n===void 0||o===void 0)&&dt(t,this.length-8);const s=n+this[++t]*2**8+this[++t]*2**16+this[++t]*2**24,u=this[++t]+this[++t]*2**8+this[++t]*2**16+o*2**24;return BigInt(s)+(BigInt(u)<<BigInt(32))}),a.prototype.readBigUInt64BE=st(function(t){t=t>>>0,ct(t,"offset");const n=this[t],o=this[t+7];(n===void 0||o===void 0)&&dt(t,this.length-8);const s=n*2**24+this[++t]*2**16+this[++t]*2**8+this[++t],u=this[++t]*2**24+this[++t]*2**16+this[++t]*2**8+o;return(BigInt(s)<<BigInt(32))+BigInt(u)}),a.prototype.readIntLE=function(t,n,o){t=t>>>0,n=n>>>0,o||x(t,n,this.length);let s=this[t],u=1,c=0;for(;++c<n&&(u*=256);)s+=this[t+c]*u;return u*=128,s>=u&&(s-=Math.pow(2,8*n)),s},a.prototype.readIntBE=function(t,n,o){t=t>>>0,n=n>>>0,o||x(t,n,this.length);let s=n,u=1,c=this[t+--s];for(;s>0&&(u*=256);)c+=this[t+--s]*u;return u*=128,c>=u&&(c-=Math.pow(2,8*n)),c},a.prototype.readInt8=function(t,n){return t=t>>>0,n||x(t,1,this.length),this[t]&128?(255-this[t]+1)*-1:this[t]},a.prototype.readInt16LE=function(t,n){t=t>>>0,n||x(t,2,this.length);const o=this[t]|this[t+1]<<8;return o&32768?o|4294901760:o},a.prototype.readInt16BE=function(t,n){t=t>>>0,n||x(t,2,this.length);const o=this[t+1]|this[t]<<8;return o&32768?o|4294901760:o},a.prototype.readInt32LE=function(t,n){return t=t>>>0,n||x(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},a.prototype.readInt32BE=function(t,n){return t=t>>>0,n||x(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},a.prototype.readBigInt64LE=st(function(t){t=t>>>0,ct(t,"offset");const n=this[t],o=this[t+7];(n===void 0||o===void 0)&&dt(t,this.length-8);const s=this[t+4]+this[t+5]*2**8+this[t+6]*2**16+(o<<24);return(BigInt(s)<<BigInt(32))+BigInt(n+this[++t]*2**8+this[++t]*2**16+this[++t]*2**24)}),a.prototype.readBigInt64BE=st(function(t){t=t>>>0,ct(t,"offset");const n=this[t],o=this[t+7];(n===void 0||o===void 0)&&dt(t,this.length-8);const s=(n<<24)+this[++t]*2**16+this[++t]*2**8+this[++t];return(BigInt(s)<<BigInt(32))+BigInt(this[++t]*2**24+this[++t]*2**16+this[++t]*2**8+o)}),a.prototype.readFloatLE=function(t,n){return t=t>>>0,n||x(t,4,this.length),O.read(this,t,!0,23,4)},a.prototype.readFloatBE=function(t,n){return t=t>>>0,n||x(t,4,this.length),O.read(this,t,!1,23,4)},a.prototype.readDoubleLE=function(t,n){return t=t>>>0,n||x(t,8,this.length),O.read(this,t,!0,52,8)},a.prototype.readDoubleBE=function(t,n){return t=t>>>0,n||x(t,8,this.length),O.read(this,t,!1,52,8)};function Z(t,n,o,s,u,c){if(!a.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(n>u||n<c)throw new RangeError('"value" argument is out of bounds');if(o+s>t.length)throw new RangeError("Index out of range")}a.prototype.writeUintLE=a.prototype.writeUIntLE=function(t,n,o,s){if(t=+t,n=n>>>0,o=o>>>0,!s){const w=Math.pow(2,8*o)-1;Z(this,t,n,o,w,0)}let u=1,c=0;for(this[n]=t&255;++c<o&&(u*=256);)this[n+c]=t/u&255;return n+o},a.prototype.writeUintBE=a.prototype.writeUIntBE=function(t,n,o,s){if(t=+t,n=n>>>0,o=o>>>0,!s){const w=Math.pow(2,8*o)-1;Z(this,t,n,o,w,0)}let u=o-1,c=1;for(this[n+u]=t&255;--u>=0&&(c*=256);)this[n+u]=t/c&255;return n+o},a.prototype.writeUint8=a.prototype.writeUInt8=function(t,n,o){return t=+t,n=n>>>0,o||Z(this,t,n,1,255,0),this[n]=t&255,n+1},a.prototype.writeUint16LE=a.prototype.writeUInt16LE=function(t,n,o){return t=+t,n=n>>>0,o||Z(this,t,n,2,65535,0),this[n]=t&255,this[n+1]=t>>>8,n+2},a.prototype.writeUint16BE=a.prototype.writeUInt16BE=function(t,n,o){return t=+t,n=n>>>0,o||Z(this,t,n,2,65535,0),this[n]=t>>>8,this[n+1]=t&255,n+2},a.prototype.writeUint32LE=a.prototype.writeUInt32LE=function(t,n,o){return t=+t,n=n>>>0,o||Z(this,t,n,4,4294967295,0),this[n+3]=t>>>24,this[n+2]=t>>>16,this[n+1]=t>>>8,this[n]=t&255,n+4},a.prototype.writeUint32BE=a.prototype.writeUInt32BE=function(t,n,o){return t=+t,n=n>>>0,o||Z(this,t,n,4,4294967295,0),this[n]=t>>>24,this[n+1]=t>>>16,this[n+2]=t>>>8,this[n+3]=t&255,n+4};function ft(t,n,o,s,u){At(n,s,u,t,o,7);let c=Number(n&BigInt(4294967295));t[o++]=c,c=c>>8,t[o++]=c,c=c>>8,t[o++]=c,c=c>>8,t[o++]=c;let w=Number(n>>BigInt(32)&BigInt(4294967295));return t[o++]=w,w=w>>8,t[o++]=w,w=w>>8,t[o++]=w,w=w>>8,t[o++]=w,o}function Tt(t,n,o,s,u){At(n,s,u,t,o,7);let c=Number(n&BigInt(4294967295));t[o+7]=c,c=c>>8,t[o+6]=c,c=c>>8,t[o+5]=c,c=c>>8,t[o+4]=c;let w=Number(n>>BigInt(32)&BigInt(4294967295));return t[o+3]=w,w=w>>8,t[o+2]=w,w=w>>8,t[o+1]=w,w=w>>8,t[o]=w,o+8}a.prototype.writeBigUInt64LE=st(function(t,n=0){return ft(this,t,n,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeBigUInt64BE=st(function(t,n=0){return Tt(this,t,n,BigInt(0),BigInt("0xffffffffffffffff"))}),a.prototype.writeIntLE=function(t,n,o,s){if(t=+t,n=n>>>0,!s){const $=Math.pow(2,8*o-1);Z(this,t,n,o,$-1,-$)}let u=0,c=1,w=0;for(this[n]=t&255;++u<o&&(c*=256);)t<0&&w===0&&this[n+u-1]!==0&&(w=1),this[n+u]=(t/c>>0)-w&255;return n+o},a.prototype.writeIntBE=function(t,n,o,s){if(t=+t,n=n>>>0,!s){const $=Math.pow(2,8*o-1);Z(this,t,n,o,$-1,-$)}let u=o-1,c=1,w=0;for(this[n+u]=t&255;--u>=0&&(c*=256);)t<0&&w===0&&this[n+u+1]!==0&&(w=1),this[n+u]=(t/c>>0)-w&255;return n+o},a.prototype.writeInt8=function(t,n,o){return t=+t,n=n>>>0,o||Z(this,t,n,1,127,-128),t<0&&(t=255+t+1),this[n]=t&255,n+1},a.prototype.writeInt16LE=function(t,n,o){return t=+t,n=n>>>0,o||Z(this,t,n,2,32767,-32768),this[n]=t&255,this[n+1]=t>>>8,n+2},a.prototype.writeInt16BE=function(t,n,o){return t=+t,n=n>>>0,o||Z(this,t,n,2,32767,-32768),this[n]=t>>>8,this[n+1]=t&255,n+2},a.prototype.writeInt32LE=function(t,n,o){return t=+t,n=n>>>0,o||Z(this,t,n,4,2147483647,-2147483648),this[n]=t&255,this[n+1]=t>>>8,this[n+2]=t>>>16,this[n+3]=t>>>24,n+4},a.prototype.writeInt32BE=function(t,n,o){return t=+t,n=n>>>0,o||Z(this,t,n,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),this[n]=t>>>24,this[n+1]=t>>>16,this[n+2]=t>>>8,this[n+3]=t&255,n+4},a.prototype.writeBigInt64LE=st(function(t,n=0){return ft(this,t,n,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),a.prototype.writeBigInt64BE=st(function(t,n=0){return Tt(this,t,n,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function Ut(t,n,o,s,u,c){if(o+s>t.length)throw new RangeError("Index out of range");if(o<0)throw new RangeError("Index out of range")}function St(t,n,o,s,u){return n=+n,o=o>>>0,u||Ut(t,n,o,4),O.write(t,n,o,s,23,4),o+4}a.prototype.writeFloatLE=function(t,n,o){return St(this,t,n,!0,o)},a.prototype.writeFloatBE=function(t,n,o){return St(this,t,n,!1,o)};function _t(t,n,o,s,u){return n=+n,o=o>>>0,u||Ut(t,n,o,8),O.write(t,n,o,s,52,8),o+8}a.prototype.writeDoubleLE=function(t,n,o){return _t(this,t,n,!0,o)},a.prototype.writeDoubleBE=function(t,n,o){return _t(this,t,n,!1,o)},a.prototype.copy=function(t,n,o,s){if(!a.isBuffer(t))throw new TypeError("argument should be a Buffer");if(o||(o=0),!s&&s!==0&&(s=this.length),n>=t.length&&(n=t.length),n||(n=0),s>0&&s<o&&(s=o),s===o||t.length===0||this.length===0)return 0;if(n<0)throw new RangeError("targetStart out of bounds");if(o<0||o>=this.length)throw new RangeError("Index out of range");if(s<0)throw new RangeError("sourceEnd out of bounds");s>this.length&&(s=this.length),t.length-n<s-o&&(s=t.length-n+o);const u=s-o;return this===t&&typeof B.prototype.copyWithin=="function"?this.copyWithin(n,o,s):B.prototype.set.call(t,this.subarray(o,s),n),u},a.prototype.fill=function(t,n,o,s){if(typeof t=="string"){if(typeof n=="string"?(s=n,n=0,o=this.length):typeof o=="string"&&(s=o,o=this.length),s!==void 0&&typeof s!="string")throw new TypeError("encoding must be a string");if(typeof s=="string"&&!a.isEncoding(s))throw new TypeError("Unknown encoding: "+s);if(t.length===1){const c=t.charCodeAt(0);(s==="utf8"&&c<128||s==="latin1")&&(t=c)}}else typeof t=="number"?t=t&255:typeof t=="boolean"&&(t=Number(t));if(n<0||this.length<n||this.length<o)throw new RangeError("Out of range index");if(o<=n)return this;n=n>>>0,o=o===void 0?this.length:o>>>0,t||(t=0);let u;if(typeof t=="number")for(u=n;u<o;++u)this[u]=t;else{const c=a.isBuffer(t)?t:a.from(t,s),w=c.length;if(w===0)throw new TypeError('The value "'+t+'" is invalid for argument "value"');for(u=0;u<o-n;++u)this[u+n]=c[u%w]}return this};const pt={};function Rt(t,n,o){pt[t]=class extends o{constructor(){super(),Object.defineProperty(this,"message",{value:n.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${t}]`,this.stack,delete this.name}get code(){return t}set code(s){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:s,writable:!0})}toString(){return`${this.name} [${t}]: ${this.message}`}}}Rt("ERR_BUFFER_OUT_OF_BOUNDS",function(t){return t?`${t} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),Rt("ERR_INVALID_ARG_TYPE",function(t,n){return`The "${t}" argument must be of type number. Received type ${typeof n}`},TypeError),Rt("ERR_OUT_OF_RANGE",function(t,n,o){let s=`The value of "${t}" is out of range.`,u=o;return Number.isInteger(o)&&Math.abs(o)>2**32?u=Nt(String(o)):typeof o=="bigint"&&(u=String(o),(o>BigInt(2)**BigInt(32)||o<-(BigInt(2)**BigInt(32)))&&(u=Nt(u)),u+="n"),s+=` It must be ${n}. Received ${u}`,s},RangeError);function Nt(t){let n="",o=t.length;const s=t[0]==="-"?1:0;for(;o>=s+4;o-=3)n=`_${t.slice(o-3,o)}${n}`;return`${t.slice(0,o)}${n}`}function kt(t,n,o){ct(n,"offset"),(t[n]===void 0||t[n+o]===void 0)&&dt(n,t.length-(o+1))}function At(t,n,o,s,u,c){if(t>o||t<n){const w=typeof n=="bigint"?"n":"";let $;throw n===0||n===BigInt(0)?$=`>= 0${w} and < 2${w} ** ${(c+1)*8}${w}`:$=`>= -(2${w} ** ${(c+1)*8-1}${w}) and < 2 ** ${(c+1)*8-1}${w}`,new pt.ERR_OUT_OF_RANGE("value",$,t)}kt(s,u,c)}function ct(t,n){if(typeof t!="number")throw new pt.ERR_INVALID_ARG_TYPE(n,"number",t)}function dt(t,n,o){throw Math.floor(t)!==t?(ct(t,o),new pt.ERR_OUT_OF_RANGE("offset","an integer",t)):n<0?new pt.ERR_BUFFER_OUT_OF_BOUNDS:new pt.ERR_OUT_OF_RANGE("offset",`>= 0 and <= ${n}`,t)}const Dt=/[^+/0-9A-Za-z-_]/g;function Yt(t){if(t=t.split("=")[0],t=t.trim().replace(Dt,""),t.length<2)return"";for(;t.length%4!==0;)t=t+"=";return t}function Ot(t,n){n=n||1/0;let o;const s=t.length;let u=null;const c=[];for(let w=0;w<s;++w){if(o=t.charCodeAt(w),o>55295&&o<57344){if(!u){if(o>56319){(n-=3)>-1&&c.push(239,191,189);continue}else if(w+1===s){(n-=3)>-1&&c.push(239,191,189);continue}u=o;continue}if(o<56320){(n-=3)>-1&&c.push(239,191,189),u=o;continue}o=(u-55296<<10|o-56320)+65536}else u&&(n-=3)>-1&&c.push(239,191,189);if(u=null,o<128){if((n-=1)<0)break;c.push(o)}else if(o<2048){if((n-=2)<0)break;c.push(o>>6|192,o&63|128)}else if(o<65536){if((n-=3)<0)break;c.push(o>>12|224,o>>6&63|128,o&63|128)}else if(o<1114112){if((n-=4)<0)break;c.push(o>>18|240,o>>12&63|128,o>>6&63|128,o&63|128)}else throw new Error("Invalid code point")}return c}function zt(t){const n=[];for(let o=0;o<t.length;++o)n.push(t.charCodeAt(o)&255);return n}function V(t,n){let o,s,u;const c=[];for(let w=0;w<t.length&&!((n-=2)<0);++w)o=t.charCodeAt(w),s=o>>8,u=o%256,c.push(u),c.push(s);return c}function Q(t){return m.toByteArray(Yt(t))}function bt(t,n,o,s){let u;for(u=0;u<s&&!(u+o>=n.length||u>=t.length);++u)n[u+o]=t[u];return u}function nt(t,n){return t instanceof n||t!=null&&t.constructor!=null&&t.constructor.name!=null&&t.constructor.name===n.name}function Bt(t){return t!==t}const Mt=(function(){const t="0123456789abcdef",n=new Array(256);for(let o=0;o<16;++o){const s=o*16;for(let u=0;u<16;++u)n[s+u]=t[o]+t[u]}return n})();function st(t){return typeof BigInt>"u"?gt:t}function gt(){throw new Error("BigInt not supported")}})(Kt);const ce=Kt.Buffer;var Xt={},Ht;function ae(){return Ht||(Ht=1,(function(E){Object.defineProperties(E,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});var m={},O={};O.byteLength=a,O.toByteArray=et,O.fromByteArray=wt;for(var A=[],U=[],B=typeof Uint8Array<"u"?Uint8Array:Array,v="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",S=0,_=v.length;S<_;++S)A[S]=v[S],U[v.charCodeAt(S)]=S;U[45]=62,U[95]=63;function C(y){var d=y.length;if(d%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var T=y.indexOf("=");T===-1&&(T=d);var L=T===d?0:4-T%4;return[T,L]}function a(y){var d=C(y),T=d[0],L=d[1];return(T+L)*3/4-L}function q(y,d,T){return(d+T)*3/4-T}function et(y){var d,T=C(y),L=T[0],N=T[1],I=new B(q(y,L,N)),R=0,Y=N>0?L-4:L,P;for(P=0;P<Y;P+=4)d=U[y.charCodeAt(P)]<<18|U[y.charCodeAt(P+1)]<<12|U[y.charCodeAt(P+2)]<<6|U[y.charCodeAt(P+3)],I[R++]=d>>16&255,I[R++]=d>>8&255,I[R++]=d&255;return N===2&&(d=U[y.charCodeAt(P)]<<2|U[y.charCodeAt(P+1)]>>4,I[R++]=d&255),N===1&&(d=U[y.charCodeAt(P)]<<10|U[y.charCodeAt(P+1)]<<4|U[y.charCodeAt(P+2)]>>2,I[R++]=d>>8&255,I[R++]=d&255),I}function K(y){return A[y>>18&63]+A[y>>12&63]+A[y>>6&63]+A[y&63]}function ot(y,d,T){for(var L,N=[],I=d;I<T;I+=3)L=(y[I]<<16&16711680)+(y[I+1]<<8&65280)+(y[I+2]&255),N.push(K(L));return N.join("")}function wt(y){for(var d,T=y.length,L=T%3,N=[],I=16383,R=0,Y=T-L;R<Y;R+=I)N.push(ot(y,R,R+I>Y?Y:R+I));return L===1?(d=y[T-1],N.push(A[d>>2]+A[d<<4&63]+"==")):L===2&&(d=(y[T-2]<<8)+y[T-1],N.push(A[d>>10]+A[d>>4&63]+A[d<<2&63]+"=")),N.join("")}var at={};at.read=function(y,d,T,L,N){var I,R,Y=N*8-L-1,P=(1<<Y)-1,X=P>>1,l=-7,H=T?N-1:0,it=T?-1:1,tt=y[d+H];for(H+=it,I=tt&(1<<-l)-1,tt>>=-l,l+=Y;l>0;I=I*256+y[d+H],H+=it,l-=8);for(R=I&(1<<-l)-1,I>>=-l,l+=L;l>0;R=R*256+y[d+H],H+=it,l-=8);if(I===0)I=1-X;else{if(I===P)return R?NaN:(tt?-1:1)*(1/0);R=R+Math.pow(2,L),I=I-X}return(tt?-1:1)*R*Math.pow(2,I-L)},at.write=function(y,d,T,L,N,I){var R,Y,P,X=I*8-N-1,l=(1<<X)-1,H=l>>1,it=N===23?Math.pow(2,-24)-Math.pow(2,-77):0,tt=L?0:I-1,lt=L?1:-1,mt=d<0||d===0&&1/d<0?1:0;for(d=Math.abs(d),isNaN(d)||d===1/0?(Y=isNaN(d)?1:0,R=l):(R=Math.floor(Math.log(d)/Math.LN2),d*(P=Math.pow(2,-R))<1&&(R--,P*=2),R+H>=1?d+=it/P:d+=it*Math.pow(2,1-H),d*P>=2&&(R++,P/=2),R+H>=l?(Y=0,R=l):R+H>=1?(Y=(d*P-1)*Math.pow(2,N),R=R+H):(Y=d*Math.pow(2,H-1)*Math.pow(2,N),R=0));N>=8;y[T+tt]=Y&255,tt+=lt,Y/=256,N-=8);for(R=R<<N|Y,X+=N;X>0;y[T+tt]=R&255,tt+=lt,R/=256,X-=8);y[T+tt-lt]|=mt*128},(function(y){const d=O,T=at,L=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;y.Buffer=l,y.SlowBuffer=jt,y.INSPECT_MAX_BYTES=50;const N=2147483647;y.kMaxLength=N;const{Uint8Array:I,ArrayBuffer:R,SharedArrayBuffer:Y}=globalThis;l.TYPED_ARRAY_SUPPORT=P(),!l.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function P(){try{const e=new I(1),r={foo:function(){return 42}};return Object.setPrototypeOf(r,I.prototype),Object.setPrototypeOf(e,r),e.foo()===42}catch{return!1}}Object.defineProperty(l.prototype,"parent",{enumerable:!0,get:function(){if(l.isBuffer(this))return this.buffer}}),Object.defineProperty(l.prototype,"offset",{enumerable:!0,get:function(){if(l.isBuffer(this))return this.byteOffset}});function X(e){if(e>N)throw new RangeError('The value "'+e+'" is invalid for option "size"');const r=new I(e);return Object.setPrototypeOf(r,l.prototype),r}function l(e,r,i){if(typeof e=="number"){if(typeof r=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return lt(e)}return H(e,r,i)}l.poolSize=8192;function H(e,r,i){if(typeof e=="string")return mt(e,r);if(R.isView(e))return $t(e);if(e==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(ut(e,R)||e&&ut(e.buffer,R)||typeof Y<"u"&&(ut(e,Y)||e&&ut(e.buffer,Y)))return Lt(e,r,i);if(typeof e=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const f=e.valueOf&&e.valueOf();if(f!=null&&f!==e)return l.from(f,r,i);const h=Ft(e);if(h)return h;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof e[Symbol.toPrimitive]=="function")return l.from(e[Symbol.toPrimitive]("string"),r,i);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}l.from=function(e,r,i){return H(e,r,i)},Object.setPrototypeOf(l.prototype,I.prototype),Object.setPrototypeOf(l,I);function it(e){if(typeof e!="number")throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function tt(e,r,i){return it(e),e<=0?X(e):r!==void 0?typeof i=="string"?X(e).fill(r,i):X(e).fill(r):X(e)}l.alloc=function(e,r,i){return tt(e,r,i)};function lt(e){return it(e),X(e<0?0:It(e)|0)}l.allocUnsafe=function(e){return lt(e)},l.allocUnsafeSlow=function(e){return lt(e)};function mt(e,r){if((typeof r!="string"||r==="")&&(r="utf8"),!l.isEncoding(r))throw new TypeError("Unknown encoding: "+r);const i=x(e,r)|0;let f=X(i);const h=f.write(e,r);return h!==i&&(f=f.slice(0,h)),f}function Et(e){const r=e.length<0?0:It(e.length)|0,i=X(r);for(let f=0;f<r;f+=1)i[f]=e[f]&255;return i}function $t(e){if(ut(e,I)){const r=new I(e);return Lt(r.buffer,r.byteOffset,r.byteLength)}return Et(e)}function Lt(e,r,i){if(r<0||e.byteLength<r)throw new RangeError('"offset" is outside of buffer bounds');if(e.byteLength<r+(i||0))throw new RangeError('"length" is outside of buffer bounds');let f;return r===void 0&&i===void 0?f=new I(e):i===void 0?f=new I(e,r):f=new I(e,r,i),Object.setPrototypeOf(f,l.prototype),f}function Ft(e){if(l.isBuffer(e)){const r=It(e.length)|0,i=X(r);return i.length===0||e.copy(i,0,0,r),i}if(e.length!==void 0)return typeof e.length!="number"||xt(e.length)?X(0):Et(e);if(e.type==="Buffer"&&Array.isArray(e.data))return Et(e.data)}function It(e){if(e>=N)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+N.toString(16)+" bytes");return e|0}function jt(e){return+e!=e&&(e=0),l.alloc(+e)}l.isBuffer=function(e){return e!=null&&e._isBuffer===!0&&e!==l.prototype},l.compare=function(e,r){if(ut(e,I)&&(e=l.from(e,e.offset,e.byteLength)),ut(r,I)&&(r=l.from(r,r.offset,r.byteLength)),!l.isBuffer(e)||!l.isBuffer(r))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===r)return 0;let i=e.length,f=r.length;for(let h=0,p=Math.min(i,f);h<p;++h)if(e[h]!==r[h]){i=e[h],f=r[h];break}return i<f?-1:f<i?1:0},l.isEncoding=function(e){switch(String(e).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}},l.concat=function(e,r){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(e.length===0)return l.alloc(0);let i;if(r===void 0)for(r=0,i=0;i<e.length;++i)r+=e[i].length;const f=l.allocUnsafe(r);let h=0;for(i=0;i<e.length;++i){let p=e[i];if(ut(p,I))h+p.length>f.length?(l.isBuffer(p)||(p=l.from(p)),p.copy(f,h)):I.prototype.set.call(f,p,h);else if(l.isBuffer(p))p.copy(f,h);else throw new TypeError('"list" argument must be an Array of Buffers');h+=p.length}return f};function x(e,r){if(l.isBuffer(e))return e.length;if(R.isView(e)||ut(e,R))return e.byteLength;if(typeof e!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);const i=e.length,f=arguments.length>2&&arguments[2]===!0;if(!f&&i===0)return 0;let h=!1;for(;;)switch(r){case"ascii":case"latin1":case"binary":return i;case"utf8":case"utf-8":return G(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return i*2;case"hex":return i>>>1;case"base64":return z(e).length;default:if(h)return f?-1:G(e).length;r=(""+r).toLowerCase(),h=!0}}l.byteLength=x;function Z(e,r,i){let f=!1;if((r===void 0||r<0)&&(r=0),r>this.length||((i===void 0||i>this.length)&&(i=this.length),i<=0)||(i>>>=0,r>>>=0,i<=r))return"";for(e||(e="utf8");;)switch(e){case"hex":return Ot(this,r,i);case"utf8":case"utf-8":return At(this,r,i);case"ascii":return Dt(this,r,i);case"latin1":case"binary":return Yt(this,r,i);case"base64":return kt(this,r,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return zt(this,r,i);default:if(f)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),f=!0}}l.prototype._isBuffer=!0;function ft(e,r,i){const f=e[r];e[r]=e[i],e[i]=f}l.prototype.swap16=function(){const e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let r=0;r<e;r+=2)ft(this,r,r+1);return this},l.prototype.swap32=function(){const e=this.length;if(e%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let r=0;r<e;r+=4)ft(this,r,r+3),ft(this,r+1,r+2);return this},l.prototype.swap64=function(){const e=this.length;if(e%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let r=0;r<e;r+=8)ft(this,r,r+7),ft(this,r+1,r+6),ft(this,r+2,r+5),ft(this,r+3,r+4);return this},l.prototype.toString=function(){const e=this.length;return e===0?"":arguments.length===0?At(this,0,e):Z.apply(this,arguments)},l.prototype.toLocaleString=l.prototype.toString,l.prototype.equals=function(e){if(!l.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e?!0:l.compare(this,e)===0},l.prototype.inspect=function(){let e="";const r=y.INSPECT_MAX_BYTES;return e=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(e+=" ... "),"<Buffer "+e+">"},L&&(l.prototype[L]=l.prototype.inspect),l.prototype.compare=function(e,r,i,f,h){if(ut(e,I)&&(e=l.from(e,e.offset,e.byteLength)),!l.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(r===void 0&&(r=0),i===void 0&&(i=e?e.length:0),f===void 0&&(f=0),h===void 0&&(h=this.length),r<0||i>e.length||f<0||h>this.length)throw new RangeError("out of range index");if(f>=h&&r>=i)return 0;if(f>=h)return-1;if(r>=i)return 1;if(r>>>=0,i>>>=0,f>>>=0,h>>>=0,this===e)return 0;let p=h-f,b=i-r;const k=Math.min(p,b),J=this.slice(f,h),D=e.slice(r,i);for(let j=0;j<k;++j)if(J[j]!==D[j]){p=J[j],b=D[j];break}return p<b?-1:b<p?1:0};function Tt(e,r,i,f,h){if(e.length===0)return-1;if(typeof i=="string"?(f=i,i=0):i>2147483647?i=2147483647:i<-2147483648&&(i=-2147483648),i=+i,xt(i)&&(i=h?0:e.length-1),i<0&&(i=e.length+i),i>=e.length){if(h)return-1;i=e.length-1}else if(i<0)if(h)i=0;else return-1;if(typeof r=="string"&&(r=l.from(r,f)),l.isBuffer(r))return r.length===0?-1:Ut(e,r,i,f,h);if(typeof r=="number")return r=r&255,typeof I.prototype.indexOf=="function"?h?I.prototype.indexOf.call(e,r,i):I.prototype.lastIndexOf.call(e,r,i):Ut(e,[r],i,f,h);throw new TypeError("val must be string, number or Buffer")}function Ut(e,r,i,f,h){let p=1,b=e.length,k=r.length;if(f!==void 0&&(f=String(f).toLowerCase(),f==="ucs2"||f==="ucs-2"||f==="utf16le"||f==="utf-16le")){if(e.length<2||r.length<2)return-1;p=2,b/=2,k/=2,i/=2}function J(j,W){return p===1?j[W]:j.readUInt16BE(W*p)}let D;if(h){let j=-1;for(D=i;D<b;D++)if(J(e,D)===J(r,j===-1?0:D-j)){if(j===-1&&(j=D),D-j+1===k)return j*p}else j!==-1&&(D-=D-j),j=-1}else for(i+k>b&&(i=b-k),D=i;D>=0;D--){let j=!0;for(let W=0;W<k;W++)if(J(e,D+W)!==J(r,W)){j=!1;break}if(j)return D}return-1}l.prototype.includes=function(e,r,i){return this.indexOf(e,r,i)!==-1},l.prototype.indexOf=function(e,r,i){return Tt(this,e,r,i,!0)},l.prototype.lastIndexOf=function(e,r,i){return Tt(this,e,r,i,!1)};function St(e,r,i,f){i=Number(i)||0;const h=e.length-i;f?(f=Number(f),f>h&&(f=h)):f=h;const p=r.length;f>p/2&&(f=p/2);let b;for(b=0;b<f;++b){const k=parseInt(r.substr(b*2,2),16);if(xt(k))return b;e[i+b]=k}return b}function _t(e,r,i,f){return Ct(G(r,e.length-i),e,i,f)}function pt(e,r,i,f){return Ct(F(r),e,i,f)}function Rt(e,r,i,f){return Ct(z(r),e,i,f)}function Nt(e,r,i,f){return Ct(M(r,e.length-i),e,i,f)}l.prototype.write=function(e,r,i,f){if(r===void 0)f="utf8",i=this.length,r=0;else if(i===void 0&&typeof r=="string")f=r,i=this.length,r=0;else if(isFinite(r))r=r>>>0,isFinite(i)?(i=i>>>0,f===void 0&&(f="utf8")):(f=i,i=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const h=this.length-r;if((i===void 0||i>h)&&(i=h),e.length>0&&(i<0||r<0)||r>this.length)throw new RangeError("Attempt to write outside buffer bounds");f||(f="utf8");let p=!1;for(;;)switch(f){case"hex":return St(this,e,r,i);case"utf8":case"utf-8":return _t(this,e,r,i);case"ascii":case"latin1":case"binary":return pt(this,e,r,i);case"base64":return Rt(this,e,r,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Nt(this,e,r,i);default:if(p)throw new TypeError("Unknown encoding: "+f);f=(""+f).toLowerCase(),p=!0}},l.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function kt(e,r,i){return r===0&&i===e.length?d.fromByteArray(e):d.fromByteArray(e.slice(r,i))}function At(e,r,i){i=Math.min(e.length,i);const f=[];let h=r;for(;h<i;){const p=e[h];let b=null,k=p>239?4:p>223?3:p>191?2:1;if(h+k<=i){let J,D,j,W;switch(k){case 1:p<128&&(b=p);break;case 2:J=e[h+1],(J&192)===128&&(W=(p&31)<<6|J&63,W>127&&(b=W));break;case 3:J=e[h+1],D=e[h+2],(J&192)===128&&(D&192)===128&&(W=(p&15)<<12|(J&63)<<6|D&63,W>2047&&(W<55296||W>57343)&&(b=W));break;case 4:J=e[h+1],D=e[h+2],j=e[h+3],(J&192)===128&&(D&192)===128&&(j&192)===128&&(W=(p&15)<<18|(J&63)<<12|(D&63)<<6|j&63,W>65535&&W<1114112&&(b=W))}}b===null?(b=65533,k=1):b>65535&&(b-=65536,f.push(b>>>10&1023|55296),b=56320|b&1023),f.push(b),h+=k}return dt(f)}const ct=4096;function dt(e){const r=e.length;if(r<=ct)return String.fromCharCode.apply(String,e);let i="",f=0;for(;f<r;)i+=String.fromCharCode.apply(String,e.slice(f,f+=ct));return i}function Dt(e,r,i){let f="";i=Math.min(e.length,i);for(let h=r;h<i;++h)f+=String.fromCharCode(e[h]&127);return f}function Yt(e,r,i){let f="";i=Math.min(e.length,i);for(let h=r;h<i;++h)f+=String.fromCharCode(e[h]);return f}function Ot(e,r,i){const f=e.length;(!r||r<0)&&(r=0),(!i||i<0||i>f)&&(i=f);let h="";for(let p=r;p<i;++p)h+=te[e[p]];return h}function zt(e,r,i){const f=e.slice(r,i);let h="";for(let p=0;p<f.length-1;p+=2)h+=String.fromCharCode(f[p]+f[p+1]*256);return h}l.prototype.slice=function(e,r){const i=this.length;e=~~e,r=r===void 0?i:~~r,e<0?(e+=i,e<0&&(e=0)):e>i&&(e=i),r<0?(r+=i,r<0&&(r=0)):r>i&&(r=i),r<e&&(r=e);const f=this.subarray(e,r);return Object.setPrototypeOf(f,l.prototype),f};function V(e,r,i){if(e%1!==0||e<0)throw new RangeError("offset is not uint");if(e+r>i)throw new RangeError("Trying to access beyond buffer length")}l.prototype.readUintLE=l.prototype.readUIntLE=function(e,r,i){e=e>>>0,r=r>>>0,i||V(e,r,this.length);let f=this[e],h=1,p=0;for(;++p<r&&(h*=256);)f+=this[e+p]*h;return f},l.prototype.readUintBE=l.prototype.readUIntBE=function(e,r,i){e=e>>>0,r=r>>>0,i||V(e,r,this.length);let f=this[e+--r],h=1;for(;r>0&&(h*=256);)f+=this[e+--r]*h;return f},l.prototype.readUint8=l.prototype.readUInt8=function(e,r){return e=e>>>0,r||V(e,1,this.length),this[e]},l.prototype.readUint16LE=l.prototype.readUInt16LE=function(e,r){return e=e>>>0,r||V(e,2,this.length),this[e]|this[e+1]<<8},l.prototype.readUint16BE=l.prototype.readUInt16BE=function(e,r){return e=e>>>0,r||V(e,2,this.length),this[e]<<8|this[e+1]},l.prototype.readUint32LE=l.prototype.readUInt32LE=function(e,r){return e=e>>>0,r||V(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216},l.prototype.readUint32BE=l.prototype.readUInt32BE=function(e,r){return e=e>>>0,r||V(e,4,this.length),this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])},l.prototype.readBigUInt64LE=yt(function(e){e=e>>>0,u(e,"offset");const r=this[e],i=this[e+7];(r===void 0||i===void 0)&&c(e,this.length-8);const f=r+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24,h=this[++e]+this[++e]*2**8+this[++e]*2**16+i*2**24;return BigInt(f)+(BigInt(h)<<BigInt(32))}),l.prototype.readBigUInt64BE=yt(function(e){e=e>>>0,u(e,"offset");const r=this[e],i=this[e+7];(r===void 0||i===void 0)&&c(e,this.length-8);const f=r*2**24+this[++e]*2**16+this[++e]*2**8+this[++e],h=this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+i;return(BigInt(f)<<BigInt(32))+BigInt(h)}),l.prototype.readIntLE=function(e,r,i){e=e>>>0,r=r>>>0,i||V(e,r,this.length);let f=this[e],h=1,p=0;for(;++p<r&&(h*=256);)f+=this[e+p]*h;return h*=128,f>=h&&(f-=Math.pow(2,8*r)),f},l.prototype.readIntBE=function(e,r,i){e=e>>>0,r=r>>>0,i||V(e,r,this.length);let f=r,h=1,p=this[e+--f];for(;f>0&&(h*=256);)p+=this[e+--f]*h;return h*=128,p>=h&&(p-=Math.pow(2,8*r)),p},l.prototype.readInt8=function(e,r){return e=e>>>0,r||V(e,1,this.length),this[e]&128?(255-this[e]+1)*-1:this[e]},l.prototype.readInt16LE=function(e,r){e=e>>>0,r||V(e,2,this.length);const i=this[e]|this[e+1]<<8;return i&32768?i|4294901760:i},l.prototype.readInt16BE=function(e,r){e=e>>>0,r||V(e,2,this.length);const i=this[e+1]|this[e]<<8;return i&32768?i|4294901760:i},l.prototype.readInt32LE=function(e,r){return e=e>>>0,r||V(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},l.prototype.readInt32BE=function(e,r){return e=e>>>0,r||V(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},l.prototype.readBigInt64LE=yt(function(e){e=e>>>0,u(e,"offset");const r=this[e],i=this[e+7];(r===void 0||i===void 0)&&c(e,this.length-8);const f=this[e+4]+this[e+5]*2**8+this[e+6]*2**16+(i<<24);return(BigInt(f)<<BigInt(32))+BigInt(r+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24)}),l.prototype.readBigInt64BE=yt(function(e){e=e>>>0,u(e,"offset");const r=this[e],i=this[e+7];(r===void 0||i===void 0)&&c(e,this.length-8);const f=(r<<24)+this[++e]*2**16+this[++e]*2**8+this[++e];return(BigInt(f)<<BigInt(32))+BigInt(this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+i)}),l.prototype.readFloatLE=function(e,r){return e=e>>>0,r||V(e,4,this.length),T.read(this,e,!0,23,4)},l.prototype.readFloatBE=function(e,r){return e=e>>>0,r||V(e,4,this.length),T.read(this,e,!1,23,4)},l.prototype.readDoubleLE=function(e,r){return e=e>>>0,r||V(e,8,this.length),T.read(this,e,!0,52,8)},l.prototype.readDoubleBE=function(e,r){return e=e>>>0,r||V(e,8,this.length),T.read(this,e,!1,52,8)};function Q(e,r,i,f,h,p){if(!l.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(r>h||r<p)throw new RangeError('"value" argument is out of bounds');if(i+f>e.length)throw new RangeError("Index out of range")}l.prototype.writeUintLE=l.prototype.writeUIntLE=function(e,r,i,f){if(e=+e,r=r>>>0,i=i>>>0,!f){const b=Math.pow(2,8*i)-1;Q(this,e,r,i,b,0)}let h=1,p=0;for(this[r]=e&255;++p<i&&(h*=256);)this[r+p]=e/h&255;return r+i},l.prototype.writeUintBE=l.prototype.writeUIntBE=function(e,r,i,f){if(e=+e,r=r>>>0,i=i>>>0,!f){const b=Math.pow(2,8*i)-1;Q(this,e,r,i,b,0)}let h=i-1,p=1;for(this[r+h]=e&255;--h>=0&&(p*=256);)this[r+h]=e/p&255;return r+i},l.prototype.writeUint8=l.prototype.writeUInt8=function(e,r,i){return e=+e,r=r>>>0,i||Q(this,e,r,1,255,0),this[r]=e&255,r+1},l.prototype.writeUint16LE=l.prototype.writeUInt16LE=function(e,r,i){return e=+e,r=r>>>0,i||Q(this,e,r,2,65535,0),this[r]=e&255,this[r+1]=e>>>8,r+2},l.prototype.writeUint16BE=l.prototype.writeUInt16BE=function(e,r,i){return e=+e,r=r>>>0,i||Q(this,e,r,2,65535,0),this[r]=e>>>8,this[r+1]=e&255,r+2},l.prototype.writeUint32LE=l.prototype.writeUInt32LE=function(e,r,i){return e=+e,r=r>>>0,i||Q(this,e,r,4,4294967295,0),this[r+3]=e>>>24,this[r+2]=e>>>16,this[r+1]=e>>>8,this[r]=e&255,r+4},l.prototype.writeUint32BE=l.prototype.writeUInt32BE=function(e,r,i){return e=+e,r=r>>>0,i||Q(this,e,r,4,4294967295,0),this[r]=e>>>24,this[r+1]=e>>>16,this[r+2]=e>>>8,this[r+3]=e&255,r+4};function bt(e,r,i,f,h){s(r,f,h,e,i,7);let p=Number(r&BigInt(4294967295));e[i++]=p,p=p>>8,e[i++]=p,p=p>>8,e[i++]=p,p=p>>8,e[i++]=p;let b=Number(r>>BigInt(32)&BigInt(4294967295));return e[i++]=b,b=b>>8,e[i++]=b,b=b>>8,e[i++]=b,b=b>>8,e[i++]=b,i}function nt(e,r,i,f,h){s(r,f,h,e,i,7);let p=Number(r&BigInt(4294967295));e[i+7]=p,p=p>>8,e[i+6]=p,p=p>>8,e[i+5]=p,p=p>>8,e[i+4]=p;let b=Number(r>>BigInt(32)&BigInt(4294967295));return e[i+3]=b,b=b>>8,e[i+2]=b,b=b>>8,e[i+1]=b,b=b>>8,e[i]=b,i+8}l.prototype.writeBigUInt64LE=yt(function(e,r=0){return bt(this,e,r,BigInt(0),BigInt("0xffffffffffffffff"))}),l.prototype.writeBigUInt64BE=yt(function(e,r=0){return nt(this,e,r,BigInt(0),BigInt("0xffffffffffffffff"))}),l.prototype.writeIntLE=function(e,r,i,f){if(e=+e,r=r>>>0,!f){const k=Math.pow(2,8*i-1);Q(this,e,r,i,k-1,-k)}let h=0,p=1,b=0;for(this[r]=e&255;++h<i&&(p*=256);)e<0&&b===0&&this[r+h-1]!==0&&(b=1),this[r+h]=(e/p>>0)-b&255;return r+i},l.prototype.writeIntBE=function(e,r,i,f){if(e=+e,r=r>>>0,!f){const k=Math.pow(2,8*i-1);Q(this,e,r,i,k-1,-k)}let h=i-1,p=1,b=0;for(this[r+h]=e&255;--h>=0&&(p*=256);)e<0&&b===0&&this[r+h+1]!==0&&(b=1),this[r+h]=(e/p>>0)-b&255;return r+i},l.prototype.writeInt8=function(e,r,i){return e=+e,r=r>>>0,i||Q(this,e,r,1,127,-128),e<0&&(e=255+e+1),this[r]=e&255,r+1},l.prototype.writeInt16LE=function(e,r,i){return e=+e,r=r>>>0,i||Q(this,e,r,2,32767,-32768),this[r]=e&255,this[r+1]=e>>>8,r+2},l.prototype.writeInt16BE=function(e,r,i){return e=+e,r=r>>>0,i||Q(this,e,r,2,32767,-32768),this[r]=e>>>8,this[r+1]=e&255,r+2},l.prototype.writeInt32LE=function(e,r,i){return e=+e,r=r>>>0,i||Q(this,e,r,4,2147483647,-2147483648),this[r]=e&255,this[r+1]=e>>>8,this[r+2]=e>>>16,this[r+3]=e>>>24,r+4},l.prototype.writeInt32BE=function(e,r,i){return e=+e,r=r>>>0,i||Q(this,e,r,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[r]=e>>>24,this[r+1]=e>>>16,this[r+2]=e>>>8,this[r+3]=e&255,r+4},l.prototype.writeBigInt64LE=yt(function(e,r=0){return bt(this,e,r,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),l.prototype.writeBigInt64BE=yt(function(e,r=0){return nt(this,e,r,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function Bt(e,r,i,f,h,p){if(i+f>e.length)throw new RangeError("Index out of range");if(i<0)throw new RangeError("Index out of range")}function Mt(e,r,i,f,h){return r=+r,i=i>>>0,h||Bt(e,r,i,4),T.write(e,r,i,f,23,4),i+4}l.prototype.writeFloatLE=function(e,r,i){return Mt(this,e,r,!0,i)},l.prototype.writeFloatBE=function(e,r,i){return Mt(this,e,r,!1,i)};function st(e,r,i,f,h){return r=+r,i=i>>>0,h||Bt(e,r,i,8),T.write(e,r,i,f,52,8),i+8}l.prototype.writeDoubleLE=function(e,r,i){return st(this,e,r,!0,i)},l.prototype.writeDoubleBE=function(e,r,i){return st(this,e,r,!1,i)},l.prototype.copy=function(e,r,i,f){if(!l.isBuffer(e))throw new TypeError("argument should be a Buffer");if(i||(i=0),!f&&f!==0&&(f=this.length),r>=e.length&&(r=e.length),r||(r=0),f>0&&f<i&&(f=i),f===i||e.length===0||this.length===0)return 0;if(r<0)throw new RangeError("targetStart out of bounds");if(i<0||i>=this.length)throw new RangeError("Index out of range");if(f<0)throw new RangeError("sourceEnd out of bounds");f>this.length&&(f=this.length),e.length-r<f-i&&(f=e.length-r+i);const h=f-i;return this===e&&typeof I.prototype.copyWithin=="function"?this.copyWithin(r,i,f):I.prototype.set.call(e,this.subarray(i,f),r),h},l.prototype.fill=function(e,r,i,f){if(typeof e=="string"){if(typeof r=="string"?(f=r,r=0,i=this.length):typeof i=="string"&&(f=i,i=this.length),f!==void 0&&typeof f!="string")throw new TypeError("encoding must be a string");if(typeof f=="string"&&!l.isEncoding(f))throw new TypeError("Unknown encoding: "+f);if(e.length===1){const p=e.charCodeAt(0);(f==="utf8"&&p<128||f==="latin1")&&(e=p)}}else typeof e=="number"?e=e&255:typeof e=="boolean"&&(e=Number(e));if(r<0||this.length<r||this.length<i)throw new RangeError("Out of range index");if(i<=r)return this;r=r>>>0,i=i===void 0?this.length:i>>>0,e||(e=0);let h;if(typeof e=="number")for(h=r;h<i;++h)this[h]=e;else{const p=l.isBuffer(e)?e:l.from(e,f),b=p.length;if(b===0)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(h=0;h<i-r;++h)this[h+r]=p[h%b]}return this};const gt={};function t(e,r,i){gt[e]=class extends i{constructor(){super(),Object.defineProperty(this,"message",{value:r.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${e}]`,this.stack,delete this.name}get code(){return e}set code(f){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:f,writable:!0})}toString(){return`${this.name} [${e}]: ${this.message}`}}}t("ERR_BUFFER_OUT_OF_BOUNDS",function(e){return e?`${e} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),t("ERR_INVALID_ARG_TYPE",function(e,r){return`The "${e}" argument must be of type number. Received type ${typeof r}`},TypeError),t("ERR_OUT_OF_RANGE",function(e,r,i){let f=`The value of "${e}" is out of range.`,h=i;return Number.isInteger(i)&&Math.abs(i)>2**32?h=n(String(i)):typeof i=="bigint"&&(h=String(i),(i>BigInt(2)**BigInt(32)||i<-(BigInt(2)**BigInt(32)))&&(h=n(h)),h+="n"),f+=` It must be ${r}. Received ${h}`,f},RangeError);function n(e){let r="",i=e.length;const f=e[0]==="-"?1:0;for(;i>=f+4;i-=3)r=`_${e.slice(i-3,i)}${r}`;return`${e.slice(0,i)}${r}`}function o(e,r,i){u(r,"offset"),(e[r]===void 0||e[r+i]===void 0)&&c(r,e.length-(i+1))}function s(e,r,i,f,h,p){if(e>i||e<r){const b=typeof r=="bigint"?"n":"";let k;throw r===0||r===BigInt(0)?k=`>= 0${b} and < 2${b} ** ${(p+1)*8}${b}`:k=`>= -(2${b} ** ${(p+1)*8-1}${b}) and < 2 ** ${(p+1)*8-1}${b}`,new gt.ERR_OUT_OF_RANGE("value",k,e)}o(f,h,p)}function u(e,r){if(typeof e!="number")throw new gt.ERR_INVALID_ARG_TYPE(r,"number",e)}function c(e,r,i){throw Math.floor(e)!==e?(u(e,i),new gt.ERR_OUT_OF_RANGE("offset","an integer",e)):r<0?new gt.ERR_BUFFER_OUT_OF_BOUNDS:new gt.ERR_OUT_OF_RANGE("offset",`>= 0 and <= ${r}`,e)}const w=/[^+/0-9A-Za-z-_]/g;function $(e){if(e=e.split("=")[0],e=e.trim().replace(w,""),e.length<2)return"";for(;e.length%4!==0;)e=e+"=";return e}function G(e,r){r=r||1/0;let i;const f=e.length;let h=null;const p=[];for(let b=0;b<f;++b){if(i=e.charCodeAt(b),i>55295&&i<57344){if(!h){if(i>56319){(r-=3)>-1&&p.push(239,191,189);continue}else if(b+1===f){(r-=3)>-1&&p.push(239,191,189);continue}h=i;continue}if(i<56320){(r-=3)>-1&&p.push(239,191,189),h=i;continue}i=(h-55296<<10|i-56320)+65536}else h&&(r-=3)>-1&&p.push(239,191,189);if(h=null,i<128){if((r-=1)<0)break;p.push(i)}else if(i<2048){if((r-=2)<0)break;p.push(i>>6|192,i&63|128)}else if(i<65536){if((r-=3)<0)break;p.push(i>>12|224,i>>6&63|128,i&63|128)}else if(i<1114112){if((r-=4)<0)break;p.push(i>>18|240,i>>12&63|128,i>>6&63|128,i&63|128)}else throw new Error("Invalid code point")}return p}function F(e){const r=[];for(let i=0;i<e.length;++i)r.push(e.charCodeAt(i)&255);return r}function M(e,r){let i,f,h;const p=[];for(let b=0;b<e.length&&!((r-=2)<0);++b)i=e.charCodeAt(b),f=i>>8,h=i%256,p.push(h),p.push(f);return p}function z(e){return d.toByteArray($(e))}function Ct(e,r,i,f){let h;for(h=0;h<f&&!(h+i>=r.length||h>=e.length);++h)r[h+i]=e[h];return h}function ut(e,r){return e instanceof r||e!=null&&e.constructor!=null&&e.constructor.name!=null&&e.constructor.name===r.name}function xt(e){return e!==e}const te=(function(){const e="0123456789abcdef",r=new Array(256);for(let i=0;i<16;++i){const f=i*16;for(let h=0;h<16;++h)r[f+h]=e[i]+e[h]}return r})();function yt(e){return typeof BigInt>"u"?ee:e}function ee(){throw new Error("BigInt not supported")}})(m);const g=m.Buffer;E.Blob=m.Blob,E.BlobOptions=m.BlobOptions,E.Buffer=m.Buffer,E.File=m.File,E.FileOptions=m.FileOptions,E.INSPECT_MAX_BYTES=m.INSPECT_MAX_BYTES,E.SlowBuffer=m.SlowBuffer,E.TranscodeEncoding=m.TranscodeEncoding,E.atob=m.atob,E.btoa=m.btoa,E.constants=m.constants,E.default=g,E.isAscii=m.isAscii,E.isUtf8=m.isUtf8,E.kMaxLength=m.kMaxLength,E.kStringMaxLength=m.kStringMaxLength,E.resolveObjectURL=m.resolveObjectURL,E.transcode=m.transcode})(Xt)),Xt}var qt={},Vt={exports:{}},Qt;function le(){return Qt||(Qt=1,(function(E,m){var O=ae(),A=O.Buffer;function U(v,S){for(var _ in v)S[_]=v[_]}A.from&&A.alloc&&A.allocUnsafe&&A.allocUnsafeSlow?E.exports=O:(U(O,m),m.Buffer=B);function B(v,S,_){return A(v,S,_)}U(A,B),B.from=function(v,S,_){if(typeof v=="number")throw new TypeError("Argument must not be a number");return A(v,S,_)},B.alloc=function(v,S,_){if(typeof v!="number")throw new TypeError("Argument must be a number");var C=A(v);return S!==void 0?typeof _=="string"?C.fill(S,_):C.fill(S):C.fill(0),C},B.allocUnsafe=function(v){if(typeof v!="number")throw new TypeError("Argument must be a number");return A(v)},B.allocUnsafeSlow=function(v){if(typeof v!="number")throw new TypeError("Argument must be a number");return O.SlowBuffer(v)}})(Vt,Vt.exports)),Vt.exports}var Jt;function pe(){if(Jt)return qt;Jt=1;var E=le().Buffer,m=E.isEncoding||function(g){switch(g=""+g,g&&g.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 O(g){if(!g)return"utf8";for(var y;;)switch(g){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 g;default:if(y)return;g=(""+g).toLowerCase(),y=!0}}function A(g){var y=O(g);if(typeof y!="string"&&(E.isEncoding===m||!m(g)))throw new Error("Unknown encoding: "+g);return y||g}qt.StringDecoder=U;function U(g){this.encoding=A(g);var y;switch(this.encoding){case"utf16le":this.text=q,this.end=et,y=4;break;case"utf8":this.fillLast=_,y=4;break;case"base64":this.text=K,this.end=ot,y=3;break;default:this.write=wt,this.end=at;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=E.allocUnsafe(y)}U.prototype.write=function(g){if(g.length===0)return"";var y,d;if(this.lastNeed){if(y=this.fillLast(g),y===void 0)return"";d=this.lastNeed,this.lastNeed=0}else d=0;return d<g.length?y?y+this.text(g,d):this.text(g,d):y||""},U.prototype.end=a,U.prototype.text=C,U.prototype.fillLast=function(g){if(this.lastNeed<=g.length)return g.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);g.copy(this.lastChar,this.lastTotal-this.lastNeed,0,g.length),this.lastNeed-=g.length};function B(g){return g<=127?0:g>>5===6?2:g>>4===14?3:g>>3===30?4:g>>6===2?-1:-2}function v(g,y,d){var T=y.length-1;if(T<d)return 0;var L=B(y[T]);return L>=0?(L>0&&(g.lastNeed=L-1),L):--T<d||L===-2?0:(L=B(y[T]),L>=0?(L>0&&(g.lastNeed=L-2),L):--T<d||L===-2?0:(L=B(y[T]),L>=0?(L>0&&(L===2?L=0:g.lastNeed=L-3),L):0))}function S(g,y,d){if((y[0]&192)!==128)return g.lastNeed=0,"<EFBFBD>";if(g.lastNeed>1&&y.length>1){if((y[1]&192)!==128)return g.lastNeed=1,"<EFBFBD>";if(g.lastNeed>2&&y.length>2&&(y[2]&192)!==128)return g.lastNeed=2,"<EFBFBD>"}}function _(g){var y=this.lastTotal-this.lastNeed,d=S(this,g);if(d!==void 0)return d;if(this.lastNeed<=g.length)return g.copy(this.lastChar,y,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);g.copy(this.lastChar,y,0,g.length),this.lastNeed-=g.length}function C(g,y){var d=v(this,g,y);if(!this.lastNeed)return g.toString("utf8",y);this.lastTotal=d;var T=g.length-(d-this.lastNeed);return g.copy(this.lastChar,0,T),g.toString("utf8",y,T)}function a(g){var y=g&&g.length?this.write(g):"";return this.lastNeed?y+"<EFBFBD>":y}function q(g,y){if((g.length-y)%2===0){var d=g.toString("utf16le",y);if(d){var T=d.charCodeAt(d.length-1);if(T>=55296&&T<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1],d.slice(0,-1)}return d}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=g[g.length-1],g.toString("utf16le",y,g.length-1)}function et(g){var y=g&&g.length?this.write(g):"";if(this.lastNeed){var d=this.lastTotal-this.lastNeed;return y+this.lastChar.toString("utf16le",0,d)}return y}function K(g,y){var d=(g.length-y)%3;return d===0?g.toString("base64",y):(this.lastNeed=3-d,this.lastTotal=3,d===1?this.lastChar[0]=g[g.length-1]:(this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1]),g.toString("base64",y,g.length-d))}function ot(g){var y=g&&g.length?this.write(g):"";return this.lastNeed?y+this.lastChar.toString("base64",0,3-this.lastNeed):y}function wt(g){return g.toString(this.encoding)}function at(g){return g&&g.length?this.write(g):""}return qt}export{ce as B,ae as a,pe as r};
//# sourceMappingURL=string_decoder-BO00msnV.chunk.mjs.map