UNPKG

@gamechanger-finance/gc

Version:

Official GameChanger Wallet library and CLI for integrating with Cardano dapps and solve other tasks (https://gamechanger.finance/)

1 lines 350 kB
this.gc=function(){function t(t,e){return e.forEach((function(e){e&&"string"!=typeof e&&!Array.isArray(e)&&Object.keys(e).forEach((function(n){if("default"!==n&&!(n in t)){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}}))})),Object.freeze(t)}var e="undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},n=[],r=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,o=!1;function a(){o=!0;for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",e=0;e<64;++e)n[e]=t[e],r[t.charCodeAt(e)]=e;r["-".charCodeAt(0)]=62,r["_".charCodeAt(0)]=63}function s(t,e,r){for(var i,o,a=[],s=e;s<r;s+=3)i=(t[s]<<16)+(t[s+1]<<8)+t[s+2],a.push(n[(o=i)>>18&63]+n[o>>12&63]+n[o>>6&63]+n[63&o]);return a.join("")}function A(t){var e;o||a();for(var r=t.length,i=r%3,A="",c=[],u=16383,l=0,f=r-i;l<f;l+=u)c.push(s(t,l,l+u>f?f:l+u));return 1===i?(e=t[r-1],A+=n[e>>2],A+=n[e<<4&63],A+="=="):2===i&&(e=(t[r-2]<<8)+t[r-1],A+=n[e>>10],A+=n[e>>4&63],A+=n[e<<2&63],A+="="),c.push(A),c.join("")}function c(t,e,n,r,i){var o,a,s=8*i-r-1,A=(1<<s)-1,c=A>>1,u=-7,l=n?i-1:0,f=n?-1:1,h=t[e+l];for(l+=f,o=h&(1<<-u)-1,h>>=-u,u+=s;u>0;o=256*o+t[e+l],l+=f,u-=8);for(a=o&(1<<-u)-1,o>>=-u,u+=r;u>0;a=256*a+t[e+l],l+=f,u-=8);if(0===o)o=1-c;else{if(o===A)return a?NaN:1/0*(h?-1:1);a+=Math.pow(2,r),o-=c}return(h?-1:1)*a*Math.pow(2,o-r)}function u(t,e,n,r,i,o){var a,s,A,c=8*o-i-1,u=(1<<c)-1,l=u>>1,f=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,h=r?0:o-1,d=r?1:-1,p=e<0||0===e&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(s=isNaN(e)?1:0,a=u):(a=Math.floor(Math.log(e)/Math.LN2),e*(A=Math.pow(2,-a))<1&&(a--,A*=2),(e+=a+l>=1?f/A:f*Math.pow(2,1-l))*A>=2&&(a++,A/=2),a+l>=u?(s=0,a=u):a+l>=1?(s=(e*A-1)*Math.pow(2,i),a+=l):(s=e*Math.pow(2,l-1)*Math.pow(2,i),a=0));i>=8;t[n+h]=255&s,h+=d,s/=256,i-=8);for(a=a<<i|s,c+=i;c>0;t[n+h]=255&a,h+=d,a/=256,c-=8);t[n+h-d]|=128*p}var l={}.toString,f=Array.isArray||function(t){return"[object Array]"==l.call(t)};function h(){return p.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function d(t,e){if(h()<e)throw new RangeError("Invalid typed array length");return p.TYPED_ARRAY_SUPPORT?(t=new Uint8Array(e)).__proto__=p.prototype:(null===t&&(t=new p(e)),t.length=e),t}function p(t,e,n){if(!(p.TYPED_ARRAY_SUPPORT||this instanceof p))return new p(t,e,n);if("number"==typeof t){if("string"==typeof e)throw new Error("If encoding is specified then the first argument must be a string");return _(this,t)}return g(this,t,e,n)}function g(t,e,n,r){if("number"==typeof e)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&e instanceof ArrayBuffer?function(t,e,n,r){if(e.byteLength,n<0||e.byteLength<n)throw new RangeError("'offset' is out of bounds");if(e.byteLength<n+(r||0))throw new RangeError("'length' is out of bounds");e=void 0===n&&void 0===r?new Uint8Array(e):void 0===r?new Uint8Array(e,n):new Uint8Array(e,n,r);p.TYPED_ARRAY_SUPPORT?(t=e).__proto__=p.prototype:t=b(t,e);return t}(t,e,n,r):"string"==typeof e?function(t,e,n){"string"==typeof n&&""!==n||(n="utf8");if(!p.isEncoding(n))throw new TypeError('"encoding" must be a valid string encoding');var r=0|y(e,n);t=d(t,r);var i=t.write(e,n);i!==r&&(t=t.slice(0,i));return t}(t,e,n):function(t,e){if(v(e)){var n=0|w(e.length);return 0===(t=d(t,n)).length||e.copy(t,0,0,n),t}if(e){if("undefined"!=typeof ArrayBuffer&&e.buffer instanceof ArrayBuffer||"length"in e)return"number"!=typeof e.length||(r=e.length)!=r?d(t,0):b(t,e);if("Buffer"===e.type&&f(e.data))return b(t,e.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(t,e)}function m(t){if("number"!=typeof t)throw new TypeError('"size" argument must be a number');if(t<0)throw new RangeError('"size" argument must not be negative')}function _(t,e){if(m(e),t=d(t,e<0?0:0|w(e)),!p.TYPED_ARRAY_SUPPORT)for(var n=0;n<e;++n)t[n]=0;return t}function b(t,e){var n=e.length<0?0:0|w(e.length);t=d(t,n);for(var r=0;r<n;r+=1)t[r]=255&e[r];return t}function w(t){if(t>=h())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+h().toString(16)+" bytes");return 0|t}function v(t){return!(null==t||!t._isBuffer)}function y(t,e){if(v(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!=typeof t&&(t=""+t);var n=t.length;if(0===n)return 0;for(var r=!1;;)switch(e){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":case void 0:return J(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return V(t).length;default:if(r)return J(t).length;e=(""+e).toLowerCase(),r=!0}}function E(t,e,n){var r=!1;if((void 0===e||e<0)&&(e=0),e>this.length)return"";if((void 0===n||n>this.length)&&(n=this.length),n<=0)return"";if((n>>>=0)<=(e>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return z(this,e,n);case"utf8":case"utf-8":return M(this,e,n);case"ascii":return U(this,e,n);case"latin1":case"binary":return D(this,e,n);case"base64":return T(this,e,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Q(this,e,n);default:if(r)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),r=!0}}function x(t,e,n){var r=t[e];t[e]=t[n],t[n]=r}function C(t,e,n,r,i){if(0===t.length)return-1;if("string"==typeof n?(r=n,n=0):n>2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),n=+n,isNaN(n)&&(n=i?0:t.length-1),n<0&&(n=t.length+n),n>=t.length){if(i)return-1;n=t.length-1}else if(n<0){if(!i)return-1;n=0}if("string"==typeof e&&(e=p.from(e,r)),v(e))return 0===e.length?-1:B(t,e,n,r,i);if("number"==typeof e)return e&=255,p.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(t,e,n):Uint8Array.prototype.lastIndexOf.call(t,e,n):B(t,[e],n,r,i);throw new TypeError("val must be string, number or Buffer")}function B(t,e,n,r,i){var o,a=1,s=t.length,A=e.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(t.length<2||e.length<2)return-1;a=2,s/=2,A/=2,n/=2}function c(t,e){return 1===a?t[e]:t.readUInt16BE(e*a)}if(i){var u=-1;for(o=n;o<s;o++)if(c(t,o)===c(e,-1===u?0:o-u)){if(-1===u&&(u=o),o-u+1===A)return u*a}else-1!==u&&(o-=o-u),u=-1}else for(n+A>s&&(n=s-A),o=n;o>=0;o--){for(var l=!0,f=0;f<A;f++)if(c(t,o+f)!==c(e,f)){l=!1;break}if(l)return o}return-1}function k(t,e,n,r){n=Number(n)||0;var i=t.length-n;r?(r=Number(r))>i&&(r=i):r=i;var o=e.length;if(o%2!=0)throw new TypeError("Invalid hex string");r>o/2&&(r=o/2);for(var a=0;a<r;++a){var s=parseInt(e.substr(2*a,2),16);if(isNaN(s))return a;t[n+a]=s}return a}function S(t,e,n,r){return X(J(e,t.length-n),t,n,r)}function I(t,e,n,r){return X(function(t){for(var e=[],n=0;n<t.length;++n)e.push(255&t.charCodeAt(n));return e}(e),t,n,r)}function R(t,e,n,r){return I(t,e,n,r)}function O(t,e,n,r){return X(V(e),t,n,r)}function P(t,e,n,r){return X(function(t,e){for(var n,r,i,o=[],a=0;a<t.length&&!((e-=2)<0);++a)r=(n=t.charCodeAt(a))>>8,i=n%256,o.push(i),o.push(r);return o}(e,t.length-n),t,n,r)}function T(t,e,n){return 0===e&&n===t.length?A(t):A(t.slice(e,n))}function M(t,e,n){n=Math.min(t.length,n);for(var r=[],i=e;i<n;){var o,a,s,A,c=t[i],u=null,l=c>239?4:c>223?3:c>191?2:1;if(i+l<=n)switch(l){case 1:c<128&&(u=c);break;case 2:128==(192&(o=t[i+1]))&&(A=(31&c)<<6|63&o)>127&&(u=A);break;case 3:o=t[i+1],a=t[i+2],128==(192&o)&&128==(192&a)&&(A=(15&c)<<12|(63&o)<<6|63&a)>2047&&(A<55296||A>57343)&&(u=A);break;case 4:o=t[i+1],a=t[i+2],s=t[i+3],128==(192&o)&&128==(192&a)&&128==(192&s)&&(A=(15&c)<<18|(63&o)<<12|(63&a)<<6|63&s)>65535&&A<1114112&&(u=A)}null===u?(u=65533,l=1):u>65535&&(u-=65536,r.push(u>>>10&1023|55296),u=56320|1023&u),r.push(u),i+=l}return function(t){var e=t.length;if(e<=L)return String.fromCharCode.apply(String,t);var n="",r=0;for(;r<e;)n+=String.fromCharCode.apply(String,t.slice(r,r+=L));return n}(r)}p.TYPED_ARRAY_SUPPORT=void 0===e.TYPED_ARRAY_SUPPORT||e.TYPED_ARRAY_SUPPORT,h(),p.poolSize=8192,p._augment=function(t){return t.__proto__=p.prototype,t},p.from=function(t,e,n){return g(null,t,e,n)},p.TYPED_ARRAY_SUPPORT&&(p.prototype.__proto__=Uint8Array.prototype,p.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&p[Symbol.species]),p.alloc=function(t,e,n){return function(t,e,n,r){return m(e),e<=0?d(t,e):void 0!==n?"string"==typeof r?d(t,e).fill(n,r):d(t,e).fill(n):d(t,e)}(null,t,e,n)},p.allocUnsafe=function(t){return _(null,t)},p.allocUnsafeSlow=function(t){return _(null,t)},p.isBuffer=function(t){return null!=t&&(!!t._isBuffer||K(t)||function(t){return"function"==typeof t.readFloatLE&&"function"==typeof t.slice&&K(t.slice(0,0))}(t))},p.compare=function(t,e){if(!v(t)||!v(e))throw new TypeError("Arguments must be Buffers");if(t===e)return 0;for(var n=t.length,r=e.length,i=0,o=Math.min(n,r);i<o;++i)if(t[i]!==e[i]){n=t[i],r=e[i];break}return n<r?-1:r<n?1:0},p.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}},p.concat=function(t,e){if(!f(t))throw new TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return p.alloc(0);var n;if(void 0===e)for(e=0,n=0;n<t.length;++n)e+=t[n].length;var r=p.allocUnsafe(e),i=0;for(n=0;n<t.length;++n){var o=t[n];if(!v(o))throw new TypeError('"list" argument must be an Array of Buffers');o.copy(r,i),i+=o.length}return r},p.byteLength=y,p.prototype._isBuffer=!0,p.prototype.swap16=function(){var t=this.length;if(t%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var e=0;e<t;e+=2)x(this,e,e+1);return this},p.prototype.swap32=function(){var t=this.length;if(t%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var e=0;e<t;e+=4)x(this,e,e+3),x(this,e+1,e+2);return this},p.prototype.swap64=function(){var t=this.length;if(t%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var e=0;e<t;e+=8)x(this,e,e+7),x(this,e+1,e+6),x(this,e+2,e+5),x(this,e+3,e+4);return this},p.prototype.toString=function(){var t=0|this.length;return 0===t?"":0===arguments.length?M(this,0,t):E.apply(this,arguments)},p.prototype.equals=function(t){if(!v(t))throw new TypeError("Argument must be a Buffer");return this===t||0===p.compare(this,t)},p.prototype.inspect=function(){var t="";return this.length>0&&(t=this.toString("hex",0,50).match(/.{2}/g).join(" "),this.length>50&&(t+=" ... ")),"<Buffer "+t+">"},p.prototype.compare=function(t,e,n,r,i){if(!v(t))throw new TypeError("Argument must be a Buffer");if(void 0===e&&(e=0),void 0===n&&(n=t?t.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),e<0||n>t.length||r<0||i>this.length)throw new RangeError("out of range index");if(r>=i&&e>=n)return 0;if(r>=i)return-1;if(e>=n)return 1;if(this===t)return 0;for(var o=(i>>>=0)-(r>>>=0),a=(n>>>=0)-(e>>>=0),s=Math.min(o,a),A=this.slice(r,i),c=t.slice(e,n),u=0;u<s;++u)if(A[u]!==c[u]){o=A[u],a=c[u];break}return o<a?-1:a<o?1:0},p.prototype.includes=function(t,e,n){return-1!==this.indexOf(t,e,n)},p.prototype.indexOf=function(t,e,n){return C(this,t,e,n,!0)},p.prototype.lastIndexOf=function(t,e,n){return C(this,t,e,n,!1)},p.prototype.write=function(t,e,n,r){if(void 0===e)r="utf8",n=this.length,e=0;else if(void 0===n&&"string"==typeof e)r=e,n=this.length,e=0;else{if(!isFinite(e))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");e|=0,isFinite(n)?(n|=0,void 0===r&&(r="utf8")):(r=n,n=void 0)}var i=this.length-e;if((void 0===n||n>i)&&(n=i),t.length>0&&(n<0||e<0)||e>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var o=!1;;)switch(r){case"hex":return k(this,t,e,n);case"utf8":case"utf-8":return S(this,t,e,n);case"ascii":return I(this,t,e,n);case"latin1":case"binary":return R(this,t,e,n);case"base64":return O(this,t,e,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P(this,t,e,n);default:if(o)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),o=!0}},p.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var L=4096;function U(t,e,n){var r="";n=Math.min(t.length,n);for(var i=e;i<n;++i)r+=String.fromCharCode(127&t[i]);return r}function D(t,e,n){var r="";n=Math.min(t.length,n);for(var i=e;i<n;++i)r+=String.fromCharCode(t[i]);return r}function z(t,e,n){var r=t.length;(!e||e<0)&&(e=0),(!n||n<0||n>r)&&(n=r);for(var i="",o=e;o<n;++o)i+=W(t[o]);return i}function Q(t,e,n){for(var r=t.slice(e,n),i="",o=0;o<r.length;o+=2)i+=String.fromCharCode(r[o]+256*r[o+1]);return i}function j(t,e,n){if(t%1!=0||t<0)throw new RangeError("offset is not uint");if(t+e>n)throw new RangeError("Trying to access beyond buffer length")}function N(t,e,n,r,i,o){if(!v(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>i||e<o)throw new RangeError('"value" argument is out of bounds');if(n+r>t.length)throw new RangeError("Index out of range")}function F(t,e,n,r){e<0&&(e=65535+e+1);for(var i=0,o=Math.min(t.length-n,2);i<o;++i)t[n+i]=(e&255<<8*(r?i:1-i))>>>8*(r?i:1-i)}function q(t,e,n,r){e<0&&(e=4294967295+e+1);for(var i=0,o=Math.min(t.length-n,4);i<o;++i)t[n+i]=e>>>8*(r?i:3-i)&255}function G(t,e,n,r,i,o){if(n+r>t.length)throw new RangeError("Index out of range");if(n<0)throw new RangeError("Index out of range")}function Z(t,e,n,r,i){return i||G(t,0,n,4),u(t,e,n,r,23,4),n+4}function H(t,e,n,r,i){return i||G(t,0,n,8),u(t,e,n,r,52,8),n+8}p.prototype.slice=function(t,e){var n,r=this.length;if((t=~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),(e=void 0===e?r:~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),e<t&&(e=t),p.TYPED_ARRAY_SUPPORT)(n=this.subarray(t,e)).__proto__=p.prototype;else{var i=e-t;n=new p(i,void 0);for(var o=0;o<i;++o)n[o]=this[o+t]}return n},p.prototype.readUIntLE=function(t,e,n){t|=0,e|=0,n||j(t,e,this.length);for(var r=this[t],i=1,o=0;++o<e&&(i*=256);)r+=this[t+o]*i;return r},p.prototype.readUIntBE=function(t,e,n){t|=0,e|=0,n||j(t,e,this.length);for(var r=this[t+--e],i=1;e>0&&(i*=256);)r+=this[t+--e]*i;return r},p.prototype.readUInt8=function(t,e){return e||j(t,1,this.length),this[t]},p.prototype.readUInt16LE=function(t,e){return e||j(t,2,this.length),this[t]|this[t+1]<<8},p.prototype.readUInt16BE=function(t,e){return e||j(t,2,this.length),this[t]<<8|this[t+1]},p.prototype.readUInt32LE=function(t,e){return e||j(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},p.prototype.readUInt32BE=function(t,e){return e||j(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},p.prototype.readIntLE=function(t,e,n){t|=0,e|=0,n||j(t,e,this.length);for(var r=this[t],i=1,o=0;++o<e&&(i*=256);)r+=this[t+o]*i;return r>=(i*=128)&&(r-=Math.pow(2,8*e)),r},p.prototype.readIntBE=function(t,e,n){t|=0,e|=0,n||j(t,e,this.length);for(var r=e,i=1,o=this[t+--r];r>0&&(i*=256);)o+=this[t+--r]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*e)),o},p.prototype.readInt8=function(t,e){return e||j(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},p.prototype.readInt16LE=function(t,e){e||j(t,2,this.length);var n=this[t]|this[t+1]<<8;return 32768&n?4294901760|n:n},p.prototype.readInt16BE=function(t,e){e||j(t,2,this.length);var n=this[t+1]|this[t]<<8;return 32768&n?4294901760|n:n},p.prototype.readInt32LE=function(t,e){return e||j(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},p.prototype.readInt32BE=function(t,e){return e||j(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},p.prototype.readFloatLE=function(t,e){return e||j(t,4,this.length),c(this,t,!0,23,4)},p.prototype.readFloatBE=function(t,e){return e||j(t,4,this.length),c(this,t,!1,23,4)},p.prototype.readDoubleLE=function(t,e){return e||j(t,8,this.length),c(this,t,!0,52,8)},p.prototype.readDoubleBE=function(t,e){return e||j(t,8,this.length),c(this,t,!1,52,8)},p.prototype.writeUIntLE=function(t,e,n,r){(t=+t,e|=0,n|=0,r)||N(this,t,e,n,Math.pow(2,8*n)-1,0);var i=1,o=0;for(this[e]=255&t;++o<n&&(i*=256);)this[e+o]=t/i&255;return e+n},p.prototype.writeUIntBE=function(t,e,n,r){(t=+t,e|=0,n|=0,r)||N(this,t,e,n,Math.pow(2,8*n)-1,0);var i=n-1,o=1;for(this[e+i]=255&t;--i>=0&&(o*=256);)this[e+i]=t/o&255;return e+n},p.prototype.writeUInt8=function(t,e,n){return t=+t,e|=0,n||N(this,t,e,1,255,0),p.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[e]=255&t,e+1},p.prototype.writeUInt16LE=function(t,e,n){return t=+t,e|=0,n||N(this,t,e,2,65535,0),p.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):F(this,t,e,!0),e+2},p.prototype.writeUInt16BE=function(t,e,n){return t=+t,e|=0,n||N(this,t,e,2,65535,0),p.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):F(this,t,e,!1),e+2},p.prototype.writeUInt32LE=function(t,e,n){return t=+t,e|=0,n||N(this,t,e,4,4294967295,0),p.TYPED_ARRAY_SUPPORT?(this[e+3]=t>>>24,this[e+2]=t>>>16,this[e+1]=t>>>8,this[e]=255&t):q(this,t,e,!0),e+4},p.prototype.writeUInt32BE=function(t,e,n){return t=+t,e|=0,n||N(this,t,e,4,4294967295,0),p.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):q(this,t,e,!1),e+4},p.prototype.writeIntLE=function(t,e,n,r){if(t=+t,e|=0,!r){var i=Math.pow(2,8*n-1);N(this,t,e,n,i-1,-i)}var o=0,a=1,s=0;for(this[e]=255&t;++o<n&&(a*=256);)t<0&&0===s&&0!==this[e+o-1]&&(s=1),this[e+o]=(t/a>>0)-s&255;return e+n},p.prototype.writeIntBE=function(t,e,n,r){if(t=+t,e|=0,!r){var i=Math.pow(2,8*n-1);N(this,t,e,n,i-1,-i)}var o=n-1,a=1,s=0;for(this[e+o]=255&t;--o>=0&&(a*=256);)t<0&&0===s&&0!==this[e+o+1]&&(s=1),this[e+o]=(t/a>>0)-s&255;return e+n},p.prototype.writeInt8=function(t,e,n){return t=+t,e|=0,n||N(this,t,e,1,127,-128),p.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[e]=255&t,e+1},p.prototype.writeInt16LE=function(t,e,n){return t=+t,e|=0,n||N(this,t,e,2,32767,-32768),p.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8):F(this,t,e,!0),e+2},p.prototype.writeInt16BE=function(t,e,n){return t=+t,e|=0,n||N(this,t,e,2,32767,-32768),p.TYPED_ARRAY_SUPPORT?(this[e]=t>>>8,this[e+1]=255&t):F(this,t,e,!1),e+2},p.prototype.writeInt32LE=function(t,e,n){return t=+t,e|=0,n||N(this,t,e,4,2147483647,-2147483648),p.TYPED_ARRAY_SUPPORT?(this[e]=255&t,this[e+1]=t>>>8,this[e+2]=t>>>16,this[e+3]=t>>>24):q(this,t,e,!0),e+4},p.prototype.writeInt32BE=function(t,e,n){return t=+t,e|=0,n||N(this,t,e,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),p.TYPED_ARRAY_SUPPORT?(this[e]=t>>>24,this[e+1]=t>>>16,this[e+2]=t>>>8,this[e+3]=255&t):q(this,t,e,!1),e+4},p.prototype.writeFloatLE=function(t,e,n){return Z(this,t,e,!0,n)},p.prototype.writeFloatBE=function(t,e,n){return Z(this,t,e,!1,n)},p.prototype.writeDoubleLE=function(t,e,n){return H(this,t,e,!0,n)},p.prototype.writeDoubleBE=function(t,e,n){return H(this,t,e,!1,n)},p.prototype.copy=function(t,e,n,r){if(n||(n=0),r||0===r||(r=this.length),e>=t.length&&(e=t.length),e||(e=0),r>0&&r<n&&(r=n),r===n)return 0;if(0===t.length||0===this.length)return 0;if(e<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),t.length-e<r-n&&(r=t.length-e+n);var i,o=r-n;if(this===t&&n<e&&e<r)for(i=o-1;i>=0;--i)t[i+e]=this[i+n];else if(o<1e3||!p.TYPED_ARRAY_SUPPORT)for(i=0;i<o;++i)t[i+e]=this[i+n];else Uint8Array.prototype.set.call(t,this.subarray(n,n+o),e);return o},p.prototype.fill=function(t,e,n,r){if("string"==typeof t){if("string"==typeof e?(r=e,e=0,n=this.length):"string"==typeof n&&(r=n,n=this.length),1===t.length){var i=t.charCodeAt(0);i<256&&(t=i)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!p.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof t&&(t&=255);if(e<0||this.length<e||this.length<n)throw new RangeError("Out of range index");if(n<=e)return this;var o;if(e>>>=0,n=void 0===n?this.length:n>>>0,t||(t=0),"number"==typeof t)for(o=e;o<n;++o)this[o]=t;else{var a=v(t)?t:J(new p(t,r).toString()),s=a.length;for(o=0;o<n-e;++o)this[o+e]=a[o%s]}return this};var Y=/[^+\/0-9A-Za-z-_]/g;function W(t){return t<16?"0"+t.toString(16):t.toString(16)}function J(t,e){var n;e=e||1/0;for(var r=t.length,i=null,o=[],a=0;a<r;++a){if((n=t.charCodeAt(a))>55295&&n<57344){if(!i){if(n>56319){(e-=3)>-1&&o.push(239,191,189);continue}if(a+1===r){(e-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(e-=3)>-1&&o.push(239,191,189),i=n;continue}n=65536+(i-55296<<10|n-56320)}else i&&(e-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((e-=1)<0)break;o.push(n)}else if(n<2048){if((e-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((e-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else{if(!(n<1114112))throw new Error("Invalid code point");if((e-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}}return o}function V(t){return function(t){var e,n,s,A,c,u;o||a();var l=t.length;if(l%4>0)throw new Error("Invalid string. Length must be a multiple of 4");c="="===t[l-2]?2:"="===t[l-1]?1:0,u=new i(3*l/4-c),s=c>0?l-4:l;var f=0;for(e=0,n=0;e<s;e+=4,n+=3)A=r[t.charCodeAt(e)]<<18|r[t.charCodeAt(e+1)]<<12|r[t.charCodeAt(e+2)]<<6|r[t.charCodeAt(e+3)],u[f++]=A>>16&255,u[f++]=A>>8&255,u[f++]=255&A;return 2===c?(A=r[t.charCodeAt(e)]<<2|r[t.charCodeAt(e+1)]>>4,u[f++]=255&A):1===c&&(A=r[t.charCodeAt(e)]<<10|r[t.charCodeAt(e+1)]<<4|r[t.charCodeAt(e+2)]>>2,u[f++]=A>>8&255,u[f++]=255&A),u}(function(t){if((t=function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}(t).replace(Y,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function X(t,e,n,r){for(var i=0;i<r&&!(i+n>=e.length||i>=t.length);++i)e[i+n]=t[i];return i}function K(t){return!!t.constructor&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)}var $="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function tt(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var et={exports:{}};!function(t,e){function n(t,e){var n=[],r=[];return null==e&&(e=function(t,e){return n[0]===e?"[Circular ~]":"[Circular ~."+r.slice(0,n.indexOf(e)).join(".")+"]"}),function(i,o){if(n.length>0){var a=n.indexOf(this);~a?n.splice(a+1):n.push(this),~a?r.splice(a,1/0,i):r.push(i),~n.indexOf(o)&&(o=e.call(this,i,o))}else n.push(o);return null==t?o:t.call(this,i,o)}}(t.exports=function(t,e,r,i){return JSON.stringify(t,n(e,i),r)}).getSerialize=n}(et);var nt=tt(et.exports);function rt(t){return t.toString("base64").replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}function it(t){return new p(t=(t+=Array(5-t.length%4).join("=")).replace(/\-/g,"+").replace(/\_/g,"/"),"base64")}var ot=Object.freeze({__proto__:null,decode:it,encode:rt,validate:function(t){return/^[A-Za-z0-9\-_]+$/.test(t)},version:"1.0.0"});function at(t){let e=t.length;for(;--e>=0;)t[e]=0}const st=256,At=286,ct=30,ut=15,lt=new Uint8Array([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]),ft=new Uint8Array([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]),ht=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),dt=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),pt=new Array(576);at(pt);const gt=new Array(60);at(gt);const mt=new Array(512);at(mt);const _t=new Array(256);at(_t);const bt=new Array(29);at(bt);const wt=new Array(ct);function vt(t,e,n,r,i){this.static_tree=t,this.extra_bits=e,this.extra_base=n,this.elems=r,this.max_length=i,this.has_stree=t&&t.length}let yt,Et,xt;function Ct(t,e){this.dyn_tree=t,this.max_code=0,this.stat_desc=e}at(wt);const Bt=t=>t<256?mt[t]:mt[256+(t>>>7)],kt=(t,e)=>{t.pending_buf[t.pending++]=255&e,t.pending_buf[t.pending++]=e>>>8&255},St=(t,e,n)=>{t.bi_valid>16-n?(t.bi_buf|=e<<t.bi_valid&65535,kt(t,t.bi_buf),t.bi_buf=e>>16-t.bi_valid,t.bi_valid+=n-16):(t.bi_buf|=e<<t.bi_valid&65535,t.bi_valid+=n)},It=(t,e,n)=>{St(t,n[2*e],n[2*e+1])},Rt=(t,e)=>{let n=0;do{n|=1&t,t>>>=1,n<<=1}while(--e>0);return n>>>1},Ot=(t,e,n)=>{const r=new Array(16);let i,o,a=0;for(i=1;i<=ut;i++)a=a+n[i-1]<<1,r[i]=a;for(o=0;o<=e;o++){let e=t[2*o+1];0!==e&&(t[2*o]=Rt(r[e]++,e))}},Pt=t=>{let e;for(e=0;e<At;e++)t.dyn_ltree[2*e]=0;for(e=0;e<ct;e++)t.dyn_dtree[2*e]=0;for(e=0;e<19;e++)t.bl_tree[2*e]=0;t.dyn_ltree[512]=1,t.opt_len=t.static_len=0,t.sym_next=t.matches=0},Tt=t=>{t.bi_valid>8?kt(t,t.bi_buf):t.bi_valid>0&&(t.pending_buf[t.pending++]=t.bi_buf),t.bi_buf=0,t.bi_valid=0},Mt=(t,e,n,r)=>{const i=2*e,o=2*n;return t[i]<t[o]||t[i]===t[o]&&r[e]<=r[n]},Lt=(t,e,n)=>{const r=t.heap[n];let i=n<<1;for(;i<=t.heap_len&&(i<t.heap_len&&Mt(e,t.heap[i+1],t.heap[i],t.depth)&&i++,!Mt(e,r,t.heap[i],t.depth));)t.heap[n]=t.heap[i],n=i,i<<=1;t.heap[n]=r},Ut=(t,e,n)=>{let r,i,o,a,s=0;if(0!==t.sym_next)do{r=255&t.pending_buf[t.sym_buf+s++],r+=(255&t.pending_buf[t.sym_buf+s++])<<8,i=t.pending_buf[t.sym_buf+s++],0===r?It(t,i,e):(o=_t[i],It(t,o+st+1,e),a=lt[o],0!==a&&(i-=bt[o],St(t,i,a)),r--,o=Bt(r),It(t,o,n),a=ft[o],0!==a&&(r-=wt[o],St(t,r,a)))}while(s<t.sym_next);It(t,256,e)},Dt=(t,e)=>{const n=e.dyn_tree,r=e.stat_desc.static_tree,i=e.stat_desc.has_stree,o=e.stat_desc.elems;let a,s,A,c=-1;for(t.heap_len=0,t.heap_max=573,a=0;a<o;a++)0!==n[2*a]?(t.heap[++t.heap_len]=c=a,t.depth[a]=0):n[2*a+1]=0;for(;t.heap_len<2;)A=t.heap[++t.heap_len]=c<2?++c:0,n[2*A]=1,t.depth[A]=0,t.opt_len--,i&&(t.static_len-=r[2*A+1]);for(e.max_code=c,a=t.heap_len>>1;a>=1;a--)Lt(t,n,a);A=o;do{a=t.heap[1],t.heap[1]=t.heap[t.heap_len--],Lt(t,n,1),s=t.heap[1],t.heap[--t.heap_max]=a,t.heap[--t.heap_max]=s,n[2*A]=n[2*a]+n[2*s],t.depth[A]=(t.depth[a]>=t.depth[s]?t.depth[a]:t.depth[s])+1,n[2*a+1]=n[2*s+1]=A,t.heap[1]=A++,Lt(t,n,1)}while(t.heap_len>=2);t.heap[--t.heap_max]=t.heap[1],((t,e)=>{const n=e.dyn_tree,r=e.max_code,i=e.stat_desc.static_tree,o=e.stat_desc.has_stree,a=e.stat_desc.extra_bits,s=e.stat_desc.extra_base,A=e.stat_desc.max_length;let c,u,l,f,h,d,p=0;for(f=0;f<=ut;f++)t.bl_count[f]=0;for(n[2*t.heap[t.heap_max]+1]=0,c=t.heap_max+1;c<573;c++)u=t.heap[c],f=n[2*n[2*u+1]+1]+1,f>A&&(f=A,p++),n[2*u+1]=f,u>r||(t.bl_count[f]++,h=0,u>=s&&(h=a[u-s]),d=n[2*u],t.opt_len+=d*(f+h),o&&(t.static_len+=d*(i[2*u+1]+h)));if(0!==p){do{for(f=A-1;0===t.bl_count[f];)f--;t.bl_count[f]--,t.bl_count[f+1]+=2,t.bl_count[A]--,p-=2}while(p>0);for(f=A;0!==f;f--)for(u=t.bl_count[f];0!==u;)l=t.heap[--c],l>r||(n[2*l+1]!==f&&(t.opt_len+=(f-n[2*l+1])*n[2*l],n[2*l+1]=f),u--)}})(t,e),Ot(n,c,t.bl_count)},zt=(t,e,n)=>{let r,i,o=-1,a=e[1],s=0,A=7,c=4;for(0===a&&(A=138,c=3),e[2*(n+1)+1]=65535,r=0;r<=n;r++)i=a,a=e[2*(r+1)+1],++s<A&&i===a||(s<c?t.bl_tree[2*i]+=s:0!==i?(i!==o&&t.bl_tree[2*i]++,t.bl_tree[32]++):s<=10?t.bl_tree[34]++:t.bl_tree[36]++,s=0,o=i,0===a?(A=138,c=3):i===a?(A=6,c=3):(A=7,c=4))},Qt=(t,e,n)=>{let r,i,o=-1,a=e[1],s=0,A=7,c=4;for(0===a&&(A=138,c=3),r=0;r<=n;r++)if(i=a,a=e[2*(r+1)+1],!(++s<A&&i===a)){if(s<c)do{It(t,i,t.bl_tree)}while(0!=--s);else 0!==i?(i!==o&&(It(t,i,t.bl_tree),s--),It(t,16,t.bl_tree),St(t,s-3,2)):s<=10?(It(t,17,t.bl_tree),St(t,s-3,3)):(It(t,18,t.bl_tree),St(t,s-11,7));s=0,o=i,0===a?(A=138,c=3):i===a?(A=6,c=3):(A=7,c=4)}};let jt=!1;const Nt=(t,e,n,r)=>{St(t,0+(r?1:0),3),Tt(t),kt(t,n),kt(t,~n),n&&t.pending_buf.set(t.window.subarray(e,e+n),t.pending),t.pending+=n};var Ft=(t,e,n,r)=>{let i,o,a=0;t.level>0?(2===t.strm.data_type&&(t.strm.data_type=(t=>{let e,n=4093624447;for(e=0;e<=31;e++,n>>>=1)if(1&n&&0!==t.dyn_ltree[2*e])return 0;if(0!==t.dyn_ltree[18]||0!==t.dyn_ltree[20]||0!==t.dyn_ltree[26])return 1;for(e=32;e<st;e++)if(0!==t.dyn_ltree[2*e])return 1;return 0})(t)),Dt(t,t.l_desc),Dt(t,t.d_desc),a=(t=>{let e;for(zt(t,t.dyn_ltree,t.l_desc.max_code),zt(t,t.dyn_dtree,t.d_desc.max_code),Dt(t,t.bl_desc),e=18;e>=3&&0===t.bl_tree[2*dt[e]+1];e--);return t.opt_len+=3*(e+1)+5+5+4,e})(t),i=t.opt_len+3+7>>>3,o=t.static_len+3+7>>>3,o<=i&&(i=o)):i=o=n+5,n+4<=i&&-1!==e?Nt(t,e,n,r):4===t.strategy||o===i?(St(t,2+(r?1:0),3),Ut(t,pt,gt)):(St(t,4+(r?1:0),3),((t,e,n,r)=>{let i;for(St(t,e-257,5),St(t,n-1,5),St(t,r-4,4),i=0;i<r;i++)St(t,t.bl_tree[2*dt[i]+1],3);Qt(t,t.dyn_ltree,e-1),Qt(t,t.dyn_dtree,n-1)})(t,t.l_desc.max_code+1,t.d_desc.max_code+1,a+1),Ut(t,t.dyn_ltree,t.dyn_dtree)),Pt(t),r&&Tt(t)},qt={_tr_init:t=>{jt||((()=>{let t,e,n,r,i;const o=new Array(16);for(n=0,r=0;r<28;r++)for(bt[r]=n,t=0;t<1<<lt[r];t++)_t[n++]=r;for(_t[n-1]=r,i=0,r=0;r<16;r++)for(wt[r]=i,t=0;t<1<<ft[r];t++)mt[i++]=r;for(i>>=7;r<ct;r++)for(wt[r]=i<<7,t=0;t<1<<ft[r]-7;t++)mt[256+i++]=r;for(e=0;e<=ut;e++)o[e]=0;for(t=0;t<=143;)pt[2*t+1]=8,t++,o[8]++;for(;t<=255;)pt[2*t+1]=9,t++,o[9]++;for(;t<=279;)pt[2*t+1]=7,t++,o[7]++;for(;t<=287;)pt[2*t+1]=8,t++,o[8]++;for(Ot(pt,287,o),t=0;t<ct;t++)gt[2*t+1]=5,gt[2*t]=Rt(t,5);yt=new vt(pt,lt,257,At,ut),Et=new vt(gt,ft,0,ct,ut),xt=new vt(new Array(0),ht,0,19,7)})(),jt=!0),t.l_desc=new Ct(t.dyn_ltree,yt),t.d_desc=new Ct(t.dyn_dtree,Et),t.bl_desc=new Ct(t.bl_tree,xt),t.bi_buf=0,t.bi_valid=0,Pt(t)},_tr_stored_block:Nt,_tr_flush_block:Ft,_tr_tally:(t,e,n)=>(t.pending_buf[t.sym_buf+t.sym_next++]=e,t.pending_buf[t.sym_buf+t.sym_next++]=e>>8,t.pending_buf[t.sym_buf+t.sym_next++]=n,0===e?t.dyn_ltree[2*n]++:(t.matches++,e--,t.dyn_ltree[2*(_t[n]+st+1)]++,t.dyn_dtree[2*Bt(e)]++),t.sym_next===t.sym_end),_tr_align:t=>{St(t,2,3),It(t,256,pt),(t=>{16===t.bi_valid?(kt(t,t.bi_buf),t.bi_buf=0,t.bi_valid=0):t.bi_valid>=8&&(t.pending_buf[t.pending++]=255&t.bi_buf,t.bi_buf>>=8,t.bi_valid-=8)})(t)}};var Gt=(t,e,n,r)=>{let i=65535&t|0,o=t>>>16&65535|0,a=0;for(;0!==n;){a=n>2e3?2e3:n,n-=a;do{i=i+e[r++]|0,o=o+i|0}while(--a);i%=65521,o%=65521}return i|o<<16|0};const Zt=new Uint32Array((()=>{let t,e=[];for(var n=0;n<256;n++){t=n;for(var r=0;r<8;r++)t=1&t?3988292384^t>>>1:t>>>1;e[n]=t}return e})());var Ht=(t,e,n,r)=>{const i=Zt,o=r+n;t^=-1;for(let n=r;n<o;n++)t=t>>>8^i[255&(t^e[n])];return-1^t},Yt={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"},Wt={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_MEM_ERROR:-4,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};const{_tr_init:Jt,_tr_stored_block:Vt,_tr_flush_block:Xt,_tr_tally:Kt,_tr_align:$t}=qt,{Z_NO_FLUSH:te,Z_PARTIAL_FLUSH:ee,Z_FULL_FLUSH:ne,Z_FINISH:re,Z_BLOCK:ie,Z_OK:oe,Z_STREAM_END:ae,Z_STREAM_ERROR:se,Z_DATA_ERROR:Ae,Z_BUF_ERROR:ce,Z_DEFAULT_COMPRESSION:ue,Z_FILTERED:le,Z_HUFFMAN_ONLY:fe,Z_RLE:he,Z_FIXED:de,Z_DEFAULT_STRATEGY:pe,Z_UNKNOWN:ge,Z_DEFLATED:me}=Wt,_e=258,be=262,we=42,ve=113,ye=666,Ee=(t,e)=>(t.msg=Yt[e],e),xe=t=>2*t-(t>4?9:0),Ce=t=>{let e=t.length;for(;--e>=0;)t[e]=0},Be=t=>{let e,n,r,i=t.w_size;e=t.hash_size,r=e;do{n=t.head[--r],t.head[r]=n>=i?n-i:0}while(--e);e=i,r=e;do{n=t.prev[--r],t.prev[r]=n>=i?n-i:0}while(--e)};let ke=(t,e,n)=>(e<<t.hash_shift^n)&t.hash_mask;const Se=t=>{const e=t.state;let n=e.pending;n>t.avail_out&&(n=t.avail_out),0!==n&&(t.output.set(e.pending_buf.subarray(e.pending_out,e.pending_out+n),t.next_out),t.next_out+=n,e.pending_out+=n,t.total_out+=n,t.avail_out-=n,e.pending-=n,0===e.pending&&(e.pending_out=0))},Ie=(t,e)=>{Xt(t,t.block_start>=0?t.block_start:-1,t.strstart-t.block_start,e),t.block_start=t.strstart,Se(t.strm)},Re=(t,e)=>{t.pending_buf[t.pending++]=e},Oe=(t,e)=>{t.pending_buf[t.pending++]=e>>>8&255,t.pending_buf[t.pending++]=255&e},Pe=(t,e,n,r)=>{let i=t.avail_in;return i>r&&(i=r),0===i?0:(t.avail_in-=i,e.set(t.input.subarray(t.next_in,t.next_in+i),n),1===t.state.wrap?t.adler=Gt(t.adler,e,i,n):2===t.state.wrap&&(t.adler=Ht(t.adler,e,i,n)),t.next_in+=i,t.total_in+=i,i)},Te=(t,e)=>{let n,r,i=t.max_chain_length,o=t.strstart,a=t.prev_length,s=t.nice_match;const A=t.strstart>t.w_size-be?t.strstart-(t.w_size-be):0,c=t.window,u=t.w_mask,l=t.prev,f=t.strstart+_e;let h=c[o+a-1],d=c[o+a];t.prev_length>=t.good_match&&(i>>=2),s>t.lookahead&&(s=t.lookahead);do{if(n=e,c[n+a]===d&&c[n+a-1]===h&&c[n]===c[o]&&c[++n]===c[o+1]){o+=2,n++;do{}while(c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&c[++o]===c[++n]&&o<f);if(r=_e-(f-o),o=f-_e,r>a){if(t.match_start=e,a=r,r>=s)break;h=c[o+a-1],d=c[o+a]}}}while((e=l[e&u])>A&&0!=--i);return a<=t.lookahead?a:t.lookahead},Me=t=>{const e=t.w_size;let n,r,i;do{if(r=t.window_size-t.lookahead-t.strstart,t.strstart>=e+(e-be)&&(t.window.set(t.window.subarray(e,e+e-r),0),t.match_start-=e,t.strstart-=e,t.block_start-=e,t.insert>t.strstart&&(t.insert=t.strstart),Be(t),r+=e),0===t.strm.avail_in)break;if(n=Pe(t.strm,t.window,t.strstart+t.lookahead,r),t.lookahead+=n,t.lookahead+t.insert>=3)for(i=t.strstart-t.insert,t.ins_h=t.window[i],t.ins_h=ke(t,t.ins_h,t.window[i+1]);t.insert&&(t.ins_h=ke(t,t.ins_h,t.window[i+3-1]),t.prev[i&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=i,i++,t.insert--,!(t.lookahead+t.insert<3)););}while(t.lookahead<be&&0!==t.strm.avail_in)},Le=(t,e)=>{let n,r,i,o=t.pending_buf_size-5>t.w_size?t.w_size:t.pending_buf_size-5,a=0,s=t.strm.avail_in;do{if(n=65535,i=t.bi_valid+42>>3,t.strm.avail_out<i)break;if(i=t.strm.avail_out-i,r=t.strstart-t.block_start,n>r+t.strm.avail_in&&(n=r+t.strm.avail_in),n>i&&(n=i),n<o&&(0===n&&e!==re||e===te||n!==r+t.strm.avail_in))break;a=e===re&&n===r+t.strm.avail_in?1:0,Vt(t,0,0,a),t.pending_buf[t.pending-4]=n,t.pending_buf[t.pending-3]=n>>8,t.pending_buf[t.pending-2]=~n,t.pending_buf[t.pending-1]=~n>>8,Se(t.strm),r&&(r>n&&(r=n),t.strm.output.set(t.window.subarray(t.block_start,t.block_start+r),t.strm.next_out),t.strm.next_out+=r,t.strm.avail_out-=r,t.strm.total_out+=r,t.block_start+=r,n-=r),n&&(Pe(t.strm,t.strm.output,t.strm.next_out,n),t.strm.next_out+=n,t.strm.avail_out-=n,t.strm.total_out+=n)}while(0===a);return s-=t.strm.avail_in,s&&(s>=t.w_size?(t.matches=2,t.window.set(t.strm.input.subarray(t.strm.next_in-t.w_size,t.strm.next_in),0),t.strstart=t.w_size,t.insert=t.strstart):(t.window_size-t.strstart<=s&&(t.strstart-=t.w_size,t.window.set(t.window.subarray(t.w_size,t.w_size+t.strstart),0),t.matches<2&&t.matches++,t.insert>t.strstart&&(t.insert=t.strstart)),t.window.set(t.strm.input.subarray(t.strm.next_in-s,t.strm.next_in),t.strstart),t.strstart+=s,t.insert+=s>t.w_size-t.insert?t.w_size-t.insert:s),t.block_start=t.strstart),t.high_water<t.strstart&&(t.high_water=t.strstart),a?4:e!==te&&e!==re&&0===t.strm.avail_in&&t.strstart===t.block_start?2:(i=t.window_size-t.strstart,t.strm.avail_in>i&&t.block_start>=t.w_size&&(t.block_start-=t.w_size,t.strstart-=t.w_size,t.window.set(t.window.subarray(t.w_size,t.w_size+t.strstart),0),t.matches<2&&t.matches++,i+=t.w_size,t.insert>t.strstart&&(t.insert=t.strstart)),i>t.strm.avail_in&&(i=t.strm.avail_in),i&&(Pe(t.strm,t.window,t.strstart,i),t.strstart+=i,t.insert+=i>t.w_size-t.insert?t.w_size-t.insert:i),t.high_water<t.strstart&&(t.high_water=t.strstart),i=t.bi_valid+42>>3,i=t.pending_buf_size-i>65535?65535:t.pending_buf_size-i,o=i>t.w_size?t.w_size:i,r=t.strstart-t.block_start,(r>=o||(r||e===re)&&e!==te&&0===t.strm.avail_in&&r<=i)&&(n=r>i?i:r,a=e===re&&0===t.strm.avail_in&&n===r?1:0,Vt(t,t.block_start,n,a),t.block_start+=n,Se(t.strm)),a?3:1)},Ue=(t,e)=>{let n,r;for(;;){if(t.lookahead<be){if(Me(t),t.lookahead<be&&e===te)return 1;if(0===t.lookahead)break}if(n=0,t.lookahead>=3&&(t.ins_h=ke(t,t.ins_h,t.window[t.strstart+3-1]),n=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart),0!==n&&t.strstart-n<=t.w_size-be&&(t.match_length=Te(t,n)),t.match_length>=3)if(r=Kt(t,t.strstart-t.match_start,t.match_length-3),t.lookahead-=t.match_length,t.match_length<=t.max_lazy_match&&t.lookahead>=3){t.match_length--;do{t.strstart++,t.ins_h=ke(t,t.ins_h,t.window[t.strstart+3-1]),n=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart}while(0!=--t.match_length);t.strstart++}else t.strstart+=t.match_length,t.match_length=0,t.ins_h=t.window[t.strstart],t.ins_h=ke(t,t.ins_h,t.window[t.strstart+1]);else r=Kt(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++;if(r&&(Ie(t,!1),0===t.strm.avail_out))return 1}return t.insert=t.strstart<2?t.strstart:2,e===re?(Ie(t,!0),0===t.strm.avail_out?3:4):t.sym_next&&(Ie(t,!1),0===t.strm.avail_out)?1:2},De=(t,e)=>{let n,r,i;for(;;){if(t.lookahead<be){if(Me(t),t.lookahead<be&&e===te)return 1;if(0===t.lookahead)break}if(n=0,t.lookahead>=3&&(t.ins_h=ke(t,t.ins_h,t.window[t.strstart+3-1]),n=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart),t.prev_length=t.match_length,t.prev_match=t.match_start,t.match_length=2,0!==n&&t.prev_length<t.max_lazy_match&&t.strstart-n<=t.w_size-be&&(t.match_length=Te(t,n),t.match_length<=5&&(t.strategy===le||3===t.match_length&&t.strstart-t.match_start>4096)&&(t.match_length=2)),t.prev_length>=3&&t.match_length<=t.prev_length){i=t.strstart+t.lookahead-3,r=Kt(t,t.strstart-1-t.prev_match,t.prev_length-3),t.lookahead-=t.prev_length-1,t.prev_length-=2;do{++t.strstart<=i&&(t.ins_h=ke(t,t.ins_h,t.window[t.strstart+3-1]),n=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart)}while(0!=--t.prev_length);if(t.match_available=0,t.match_length=2,t.strstart++,r&&(Ie(t,!1),0===t.strm.avail_out))return 1}else if(t.match_available){if(r=Kt(t,0,t.window[t.strstart-1]),r&&Ie(t,!1),t.strstart++,t.lookahead--,0===t.strm.avail_out)return 1}else t.match_available=1,t.strstart++,t.lookahead--}return t.match_available&&(r=Kt(t,0,t.window[t.strstart-1]),t.match_available=0),t.insert=t.strstart<2?t.strstart:2,e===re?(Ie(t,!0),0===t.strm.avail_out?3:4):t.sym_next&&(Ie(t,!1),0===t.strm.avail_out)?1:2};function ze(t,e,n,r,i){this.good_length=t,this.max_lazy=e,this.nice_length=n,this.max_chain=r,this.func=i}const Qe=[new ze(0,0,0,0,Le),new ze(4,4,8,4,Ue),new ze(4,5,16,8,Ue),new ze(4,6,32,32,Ue),new ze(4,4,16,16,De),new ze(8,16,32,32,De),new ze(8,16,128,128,De),new ze(8,32,128,256,De),new ze(32,128,258,1024,De),new ze(32,258,258,4096,De)];function je(){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=me,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 Uint16Array(1146),this.dyn_dtree=new Uint16Array(122),this.bl_tree=new Uint16Array(78),Ce(this.dyn_ltree),Ce(this.dyn_dtree),Ce(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(16),this.heap=new Uint16Array(573),Ce(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(573),Ce(this.depth),this.sym_buf=0,this.lit_bufsize=0,this.sym_next=0,this.sym_end=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}const Ne=t=>{if(!t)return 1;const e=t.state;return!e||e.strm!==t||e.status!==we&&57!==e.status&&69!==e.status&&73!==e.status&&91!==e.status&&103!==e.status&&e.status!==ve&&e.status!==ye?1:0},Fe=t=>{if(Ne(t))return Ee(t,se);t.total_in=t.total_out=0,t.data_type=ge;const e=t.state;return e.pending=0,e.pending_out=0,e.wrap<0&&(e.wrap=-e.wrap),e.status=2===e.wrap?57:e.wrap?we:ve,t.adler=2===e.wrap?0:1,e.last_flush=-2,Jt(e),oe},qe=t=>{const e=Fe(t);var n;return e===oe&&((n=t.state).window_size=2*n.w_size,Ce(n.head),n.max_lazy_match=Qe[n.level].max_lazy,n.good_match=Qe[n.level].good_length,n.nice_match=Qe[n.level].nice_length,n.max_chain_length=Qe[n.level].max_chain,n.strstart=0,n.block_start=0,n.lookahead=0,n.insert=0,n.match_length=n.prev_length=2,n.match_available=0,n.ins_h=0),e},Ge=(t,e,n,r,i,o)=>{if(!t)return se;let a=1;if(e===ue&&(e=6),r<0?(a=0,r=-r):r>15&&(a=2,r-=16),i<1||i>9||n!==me||r<8||r>15||e<0||e>9||o<0||o>de||8===r&&1!==a)return Ee(t,se);8===r&&(r=9);const s=new je;return t.state=s,s.strm=t,s.status=we,s.wrap=a,s.gzhead=null,s.w_bits=r,s.w_size=1<<s.w_bits,s.w_mask=s.w_size-1,s.hash_bits=i+7,s.hash_size=1<<s.hash_bits,s.hash_mask=s.hash_size-1,s.hash_shift=~~((s.hash_bits+3-1)/3),s.window=new Uint8Array(2*s.w_size),s.head=new Uint16Array(s.hash_size),s.prev=new Uint16Array(s.w_size),s.lit_bufsize=1<<i+6,s.pending_buf_size=4*s.lit_bufsize,s.pending_buf=new Uint8Array(s.pending_buf_size),s.sym_buf=s.lit_bufsize,s.sym_end=3*(s.lit_bufsize-1),s.level=e,s.strategy=o,s.method=n,qe(t)};var Ze={deflateInit:(t,e)=>Ge(t,e,me,15,8,pe),deflateInit2:Ge,deflateReset:qe,deflateResetKeep:Fe,deflateSetHeader:(t,e)=>Ne(t)||2!==t.state.wrap?se:(t.state.gzhead=e,oe),deflate:(t,e)=>{if(Ne(t)||e>ie||e<0)return t?Ee(t,se):se;const n=t.state;if(!t.output||0!==t.avail_in&&!t.input||n.status===ye&&e!==re)return Ee(t,0===t.avail_out?ce:se);const r=n.last_flush;if(n.last_flush=e,0!==n.pending){if(Se(t),0===t.avail_out)return n.last_flush=-1,oe}else if(0===t.avail_in&&xe(e)<=xe(r)&&e!==re)return Ee(t,ce);if(n.status===ye&&0!==t.avail_in)return Ee(t,ce);if(n.status===we&&0===n.wrap&&(n.status=ve),n.status===we){let e=me+(n.w_bits-8<<4)<<8,r=-1;if(r=n.strategy>=fe||n.level<2?0:n.level<6?1:6===n.level?2:3,e|=r<<6,0!==n.strstart&&(e|=32),e+=31-e%31,Oe(n,e),0!==n.strstart&&(Oe(n,t.adler>>>16),Oe(n,65535&t.adler)),t.adler=1,n.status=ve,Se(t),0!==n.pending)return n.last_flush=-1,oe}if(57===n.status)if(t.adler=0,Re(n,31),Re(n,139),Re(n,8),n.gzhead)Re(n,(n.gzhead.text?1:0)+(n.gzhead.hcrc?2:0)+(n.gzhead.extra?4:0)+(n.gzhead.name?8:0)+(n.gzhead.comment?16:0)),Re(n,255&n.gzhead.time),Re(n,n.gzhead.time>>8&255),Re(n,n.gzhead.time>>16&255),Re(n,n.gzhead.time>>24&255),Re(n,9===n.level?2:n.strategy>=fe||n.level<2?4:0),Re(n,255&n.gzhead.os),n.gzhead.extra&&n.gzhead.extra.length&&(Re(n,255&n.gzhead.extra.length),Re(n,n.gzhead.extra.length>>8&255)),n.gzhead.hcrc&&(t.adler=Ht(t.adler,n.pending_buf,n.pending,0)),n.gzindex=0,n.status=69;else if(Re(n,0),Re(n,0),Re(n,0),Re(n,0),Re(n,0),Re(n,9===n.level?2:n.strategy>=fe||n.level<2?4:0),Re(n,3),n.status=ve,Se(t),0!==n.pending)return n.last_flush=-1,oe;if(69===n.status){if(n.gzhead.extra){let e=n.pending,r=(65535&n.gzhead.extra.length)-n.gzindex;for(;n.pending+r>n.pending_buf_size;){let i=n.pending_buf_size-n.pending;if(n.pending_buf.set(n.gzhead.extra.subarray(n.gzindex,n.gzindex+i),n.pending),n.pending=n.pending_buf_size,n.gzhead.hcrc&&n.pending>e&&(t.adler=Ht(t.adler,n.pending_buf,n.pending-e,e)),n.gzindex+=i,Se(t),0!==n.pending)return n.last_flush=-1,oe;e=0,r-=i}let i=new Uint8Array(n.gzhead.extra);n.pending_buf.set(i.subarray(n.gzindex,n.gzindex+r),n.pending),n.pending+=r,n.gzhead.hcrc&&n.pending>e&&(t.adler=Ht(t.adler,n.pending_buf,n.pending-e,e)),n.gzindex=0}n.status=73}if(73===n.status){if(n.gzhead.name){let e,r=n.pending;do{if(n.pending===n.pending_buf_size){if(n.gzhead.hcrc&&n.pending>r&&(t.adler=Ht(t.adler,n.pending_buf,n.pending-r,r)),Se(t),0!==n.pending)return n.last_flush=-1,oe;r=0}e=n.gzindex<n.gzhead.name.length?255&n.gzhead.name.charCodeAt(n.gzindex++):0,Re(n,e)}while(0!==e);n.gzhead.hcrc&&n.pending>r&&(t.adler=Ht(t.adler,n.pending_buf,n.pending-r,r)),n.gzindex=0}n.status=91}if(91===n.status){if(n.gzhead.comment){let e,r=n.pending;do{if(n.pending===n.pending_buf_size){if(n.gzhead.hcrc&&n.pending>r&&(t.adler=Ht(t.adler,n.pending_buf,n.pending-r,r)),Se(t),0!==n.pending)return n.last_flush=-1,oe;r=0}e=n.gzindex<n.gzhead.comment.length?255&n.gzhead.comment.charCodeAt(n.gzindex++):0,Re(n,e)}while(0!==e);n.gzhead.hcrc&&n.pending>r&&(t.adler=Ht(t.adler,n.pending_buf,n.pending-r,r))}n.status=103}if(103===n.status){if(n.gzhead.hcrc){if(n.pending+2>n.pending_buf_size&&(Se(t),0!==n.pending))return n.last_flush=-1,oe;Re(n,255&t.adler),Re(n,t.adler>>8&255),t.adler=0}if(n.status=ve,Se(t),0!==n.pending)return n.last_flush=-1,oe}if(0!==t.avail_in||0!==n.lookahead||e!==te&&n.status!==ye){let r=0===n.level?Le(n,e):n.strategy===fe?((t,e)=>{let n;for(;;){if(0===t.lookahead&&(Me(t),0===t.lookahead)){if(e===te)return 1;break}if(t.match_length=0,n=Kt(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++,n&&(Ie(t,!1),0===t.strm.avail_out))return 1}return t.insert=0,e===re?(Ie(t,!0),0===t.strm.avail_out?3:4):t.sym_next&&(Ie(t,!1),0===t.strm.avail_out)?1:2})(n,e):n.strategy===he?((t,e)=>{let n,r,i,o;const a=t.window;for(;;){if(t.lookahead<=_e){if(Me(t),t.lookahead<=_e&&e===te)return 1;if(0===t.lookahead)break}if(t.match_length=0,t.lookahead>=3&&t.strstart>0&&(i=t.strstart-1,r=a[i],r===a[++i]&&r===a[++i]&&r===a[++i])){o=t.strstart+_e;do{}while(r===a[++i]&&r===a[++i]&&r===a[++i]&&r===a[++i]&&r===a[++i]&&r===a[++i]&&r===a[++i]&&r===a[++i]&&i<o);t.match_length=_e-(o-i),t.match_length>t.lookahead&&(t.match_length=t.lookahead)}if(t.match_length>=3?(n=Kt(t,1,t.match_length-3),t.lookahead-=t.match_length,t.strstart+=t.match_length,t.match_length=0):(n=Kt(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++),n&&(Ie(t,!1),0===t.strm.avail_out))return 1}return t.insert=0,e===re?(Ie(t,!0),0===t.strm.avail_out?3:4):t.sym_next&&(Ie(t,!1),0===t.strm.avail_out)?1:2})(n,e):Qe[n.level].func(n,e);if(3!==r&&4!==r||(n.status=ye),1===r||3===r)return 0===t.avail_out&&(n.last_flush=-1),oe;if(2===r&&(e===ee?$t(n):e!==ie&&(Vt(n,0,0,!1),e===ne&&(Ce(n.head),0===n.lookahead&&(n.strstart=0,n.block_start=0,n.insert=0))),Se(t),0===t.avail_out))return n.last_flush=-1,oe}return e!==re?oe:n.wrap<=0?ae:(2===n.wrap?(Re(n,255&t.adler),Re(n,t.adler>>8&255),Re(n,t.adler>>16&255),Re(n,t.adler>>24&255),Re(n,255&t.total_in),Re(n,t.total_in>>8&255),Re(n,t.total_in>>16&255),Re(n,t.total_in>>24&255)):(Oe(n,t.adler>>>16),Oe(n,65535&t.adler)),Se(t),n.wrap>0&&(n.wrap=-n.wrap),0!==n.pending?oe:ae)},deflateEnd:t=>{if(Ne(t))return se;const e=t.state.status;return t.state=null,e===ve?Ee(t,Ae):oe},deflateSetDictionary:(t,e)=>{let n=e.length;if(Ne(t))return se;const r=t.state,i=r.wrap;if(2===i||1===i&&r.status!==we||r.lookahead)return se;if(1===i&&(t.adler=Gt(t.adler,e,n,0)),r.wrap=0,n>=r.w_size){0===i&&(Ce(r.head),r.strstart=0,r.block_start=0,r.insert=0);let t=new Uint8Array(r.w_size);t.set(e.subarray(n-r.w_size,n),0),e=t,n=r.w_size}const o=t.avail_in,a=t.next_in,s=t.input;for(t.avail_in=n,t.next_in=0,t.input=e,Me(r);r.lookahead>=3;){let t=r.strstart,e=r.lookahead-2;do{r.ins_h=ke(r,r.ins_h,r.window[t+3-1]),r.prev[t&r.w_mask]=r.head[r.ins_h],r.head[r.ins_h]=t,t++}while(--e);r.strstart=t,r.lookahead=2,Me(r)}return r.strstart+=r.lookahead,r.block_start=r.strstart,r.insert=r.lookahead,r.lookahead=0,r.match_length=r.prev_length=2,r.match_available=0,t.next_in=a,t.input=s,t.avail_in=o,r.wrap=i,oe},deflateInfo:"pako deflate (from Nodeca project)"};const He=(t,e)=>Object.prototype.hasOwnProperty.call(t,e);var Ye={assign:function(t){const e=Array.prototype.slice.call(arguments,1);for(;e.length;){const n=e.shift();if(n){if("object"!=typeof n)throw new TypeError(n+"must be non-object");for(const e in n)He(n,e)&&(t[e]=n[e])}}return t},flattenChunks:t=>{let e=0;for(let n=0,r=t.length;n<r;n++)e+=t[n].length;const n=new Uint8Array(e);for(let e=0,r=0,i=t.length;e<i;e++){let i=t[e];n.set(i,r),r+=i.length}return n}};let We=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch(t){We=!1}const Je=new Uint8Array(256);for(let t=0;t<256;t++)Je[t]=t>=252?6:t>=248?5:t>=240?4:t>=224?3:t>=192?2:1;Je[254]=Je[254]=1;var Ve={string2buf:t=>{if("function"==typeof TextEncoder&&TextEncoder.prototype.encode)return(new TextEncoder).encode(t);let e,n,r,i,o,a=t.length,s=0;for(i=0;i<a;i++)n=t.charCodeAt(i),55296==(64512&n)&&i+1<a&&(r=t.charCodeAt(i+1),56320==(64512&r)&&(n=65536+(n-55296<<10)+(r-56320),i++)),s+=n<128?1:n<2048?2:n<65536?3:4;for(e=new Uint8Array(s),o=0,i=0;o<s;i++)n=t.charCodeAt(i),55296==(64512&n)&&i+1<a&&(r=t.charCodeAt(i+1),56320==(64512&r)&&(n=65536+(n-55296<<10)+(r-56320),i++)),n<128?e[o++]=n:n<2048?(e[o++]=192|n>>>6,e[o++]=128|63&n):n<65536?(e[o++]=224|n>>>12,e[o++]=128|n>>>6&63,e[o++]=128|63&n):(e[o++]=240|n>>>18,e[o++]=128|n>>>12&63,e[o++]=128|n>>>6&63,e[o++]=128|63&n);return e},buf2string:(t,e)=>{const n=e||t.length;if("function"==typeof TextDecoder&&TextDecoder.prototype.decode)return(new TextDecoder).decode(t.subarray(0,e));let r,i;const o=new Array(2*n);for(i=0,r=0;r<n;){let e=t[r++];if(e<128){o[i++]=e;continue}let a=Je[e];if(a>4)o[i++]=65533,r+=a-1;else{for(e&=2===a?31:3===a?15:7;a>1&&r<n;)e=e<<6|63&t[r++],a--;a>1?o[i++]=65533:e<65536?o[i++]=e:(e-=65536,o[i++]=55296|e>>10&1023,o[i++]=56320|1023&e)}}return((t,e)=>{if(e<65534&&t.subarray&&We)return String.fromCharCode.apply(null,t.length===e?t:t.subarray(0,e));let n="";for(let r=0;r<e;r++)n+=String.fromCharCode(t[r]);return n})(o,i)},utf8border:(t,e)=>{(e=e||t.length)>t.length&&(e=t.length);let n=e-1;for(;n>=0&&128==(192&t[n]);)n--;return n<0||0===n?e:n+Je[t[n]]>e?n:e}};var Xe=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0};const Ke=Object.prototype.toString,{Z_NO_FLUSH:$e,Z_SYNC_FLUSH:tn,Z_FULL_FLUSH:en,Z_FINISH:nn,Z_OK:rn,Z_STREAM_END:on,Z_DEFAULT_COMPRESSION:an,Z_DEFAULT_STRATEGY:sn,Z_DEFLATED:An}=Wt;function cn(t){this.options=Ye.assign({level:an,method:An,chunkSize:16384,windowBits:15,memLevel:8,strategy:sn},t||{});let e=this.options;e.raw&&e.windowBits>0?e.windowBits=-e.windowBits:e.gzip&&e.windowBits>0&&e.windowBits<16&&(e.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Xe,this.strm.avail_out=0;let n=Ze.deflateInit2(this.strm,e.level,e.method,e.windowBits,e.memLevel,e.strategy);if(n!==rn)throw new Error(Yt[n]);if(e.header&&Ze.deflateSetHeader(this.strm,e.header),e.dictionary){let t;if(t="string"==