text: !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).zip={})}(this,(function(t){"use strict";const e={chunkSize:524288,maxWorkers:"undefined"!=typeof navigator&&navigator.hardwareConcurrency||2,terminateWorkerTimeout:5e3,useWebWorkers:!0,workerScripts:void 0},n=Object.assign({},e);function i(){return n}function r(t){if(void 0!==t.chunkSize&&(n.chunkSize=t.chunkSize),void 0!==t.maxWorkers&&(n.maxWorkers=t.maxWorkers),void 0!==t.terminateWorkerTimeout&&(n.terminateWorkerTimeout=t.terminateWorkerTimeout),void 0!==t.useWebWorkers&&(n.useWebWorkers=t.useWebWorkers),void 0!==t.Deflate&&(n.Deflate=t.Deflate),void 0!==t.Inflate&&(n.Inflate=t.Inflate),void 0!==t.workerScripts){if(t.workerScripts.deflate){if(!Array.isArray(t.workerScripts.deflate))throw new Error("workerScripts.deflate must be an array");n.workerScripts||(n.workerScripts={}),n.workerScripts.deflate=t.workerScripts.deflate}if(t.workerScripts.inflate){if(!Array.isArray(t.workerScripts.inflate))throw new Error("workerScripts.inflate must be an array");n.workerScripts||(n.workerScripts={}),n.workerScripts.inflate=t.workerScripts.inflate}}}function a(t,e,n){return class{constructor(i){const r=this;r.codec=new t(Object.assign({},e,i)),n(r.codec,(t=>{if(r.pendingData){const e=r.pendingData;r.pendingData=new Uint8Array(e.length+t.length),r.pendingData.set(e,0),r.pendingData.set(t,e.length)}else r.pendingData=new Uint8Array(t)}))}async append(t){return this.codec.push(t),i(this)}async flush(){return this.codec.push(new Uint8Array(0),!0),i(this)}};function i(t){if(t.pendingData){const e=t.pendingData;return t.pendingData=null,e}return new Uint8Array(0)}}const s=[];for(let t=0;t<256;t++){let e=t;for(let t=0;t<8;t++)1&e?e=e>>>1^3988292384:e>>>=1;s[t]=e}class o{constructor(t){this.crc=t||-1}append(t){let e=0|this.crc;for(let n=0,i=0|t.length;n<i;n++)e=e>>>8^s[255&(e^t[n])];this.crc=e}get(){return~this.crc}}const c={concat(t,e){if(0===t.length||0===e.length)return t.concat(e);const n=t[t.length-1],i=c.getPartial(n);return 32===i?t.concat(e):c._shiftRight(e,i,0|n,t.slice(0,t.length-1))},bitLength(t){const e=t.length;if(0===e)return 0;const n=t[e-1];return 32*(e-1)+c.getPartial(n)},clamp(t,e){if(32*t.length<e)return t;const n=(t=t.slice(0,Math.ceil(e/32))).length;return e&=31,n>0&&e&&(t[n-1]=c.partial(e,t[n-1]&2147483648>>e-1,1)),t},partial:(t,e,n)=>32===t?e:(n?0|e:e<<32-t)+1099511627776*t,getPartial:t=>Math.round(t/1099511627776)||32,_shiftRight(t,e,n,i){for(void 0===i&&(i=[]);e>=32;e-=32)i.push(n),n=0;if(0===e)return i.concat(t);for(let r=0;r<t.length;r++)i.push(n|t[r]>>>e),n=t[r]<<32-e;const r=t.length?t[t.length-1]:0,a=c.getPartial(r);return i.push(c.partial(e+a&31,e+a>32?n:i.pop(),1)),i}},l={bytes:{fromBits(t){const e=c.bitLength(t)/8,n=new Uint8Array(e);let i;for(let r=0;r<e;r++)0==(3&r)&&(i=t[r/4]),n[r]=i>>>24,i<<=8;return n},toBits(t){const e=[];let n,i=0;for(n=0;n<t.length;n++)i=i<<8|t[n],3==(3&n)&&(e.push(i),i=0);return 3&n&&e.push(c.partial(8*(3&n),i)),e}}},d={sha1:function(t){t?(this._h=t._h.slice(0),this._buffer=t._buffer.slice(0),this._length=t._length):this.reset()}};d.sha1.prototype={blockSize:512,reset:function(){const t=this;return t._h=this._init.slice(0),t._buffer=[],t._length=0,t},update:function(t){const e=this;"string"==typeof t&&(t=l.utf8String.toBits(t));const n=e._buffer=c.concat(e._buffer,t),i=e._length,r=e._length=i+c.bitLength(t);if(r>9007199254740991)throw new Error("Cannot hash more than 2^53 - 1 bits");const a=new Uint32Array(n);let s=0;for(let t=e.blockSize+i-(e.blockSize+i&e.blockSize-1);t<=r;t+=e.blockSize)e._block(a.subarray(16*s,16*(s+1))),s+=1;return n.splice(0,16*s),e},finalize:function(){const t=this;let e=t._buffer;const n=t._h;e=c.concat(e,[c.partial(1,1)]);for(let t=e.length+2;15&t;t++)e.push(0);for(e.push(Math.floor(t._length/4294967296)),e.push(0|t._length);e.length;)t._block(e.splice(0,16));return t.reset(),n},_init:[1732584193,4023233417,2562383102,271733878,3285377520],_key:[1518500249,1859775393,2400959708,3395469782],_f:function(t,e,n,i){return t<=19?e&n|~e&i:t<=39?e^n^i:t<=59?e&n|e&i|n&i:t<=79?e^n^i:void 0},_S:function(t,e){return e<<t|e>>>32-t},_block:function(t){const e=this,n=e._h,i=Array(80);for(let e=0;e<16;e++)i[e]=t[e];let r=n[0],a=n[1],s=n[2],o=n[3],c=n[4];for(let t=0;t<=79;t++){t>=16&&(i[t]=e._S(1,i[t-3]^i[t-8]^i[t-14]^i[t-16]));const n=e._S(5,r)+e._f(t,a,s,o)+c+i[t]+e._key[Math.floor(t/20)]|0;c=o,o=s,s=e._S(30,a),a=r,r=n}n[0]=n[0]+r|0,n[1]=n[1]+a|0,n[2]=n[2]+s|0,n[3]=n[3]+o|0,n[4]=n[4]+c|0}};const u={aes:class{constructor(t){const e=this;e._tables=[[[],[],[],[],[]],[[],[],[],[],[]]],e._tables[0][0][0]||e._precompute();const n=e._tables[0][4],i=e._tables[1],r=t.length;let a,s,o,c=1;if(4!==r&&6!==r&&8!==r)throw new Error("invalid aes key size");for(e._key=[s=t.slice(0),o=[]],a=r;a<4*r+28;a++){let t=s[a-1];(a%r==0||8===r&&a%r==4)&&(t=n[t>>>24]<<24^n[t>>16&255]<<16^n[t>>8&255]<<8^n[255&t],a%r==0&&(t=t<<8^t>>>24^c<<24,c=c<<1^283*(c>>7))),s[a]=s[a-r]^t}for(let t=0;a;t++,a--){const e=s[3&t?a:a-4];o[t]=a<=4||t<4?e:i[0][n[e>>>24]]^i[1][n[e>>16&255]]^i[2][n[e>>8&255]]^i[3][n[255&e]]}}encrypt(t){return this._crypt(t,0)}decrypt(t){return this._crypt(t,1)}_precompute(){const t=this._tables[0],e=this._tables[1],n=t[4],i=e[4],r=[],a=[];let s,o,c,l;for(let t=0;t<256;t++)a[(r[t]=t<<1^283*(t>>7))^t]=t;for(let d=s=0;!n[d];d^=o||1,s=a[s]||1){let a=s^s<<1^s<<2^s<<3^s<<4;a=a>>8^255&a^99,n[d]=a,i[a]=d,l=r[c=r[o=r[d]]];let u=16843009*l^65537*c^257*o^16843008*d,f=257*r[a]^16843008*a;for(let n=0;n<4;n++)t[n][d]=f=f<<24^f>>>8,e[n][a]=u=u<<24^u>>>8}for(let n=0;n<5;n++)t[n]=t[n].slice(0),e[n]=e[n].slice(0)}_crypt(t,e){if(4!==t.length)throw new Error("invalid aes block size");const n=this._key[e],i=n.length/4-2,r=[0,0,0,0],a=this._tables[e],s=a[0],o=a[1],c=a[2],l=a[3],d=a[4];let u,f,h,p=t[0]^n[0],_=t[e?3:1]^n[1],w=t[2]^n[2],g=t[e?1:3]^n[3],y=4;for(let t=0;t<i;t++)u=s[p>>>24]^o[_>>16&255]^c[w>>8&255]^l[255&g]^n[y],f=s[_>>>24]^o[w>>16&255]^c[g>>8&255]^l[255&p]^n[y+1],h=s[w>>>24]^o[g>>16&255]^c[p>>8&255]^l[255&_]^n[y+2],g=s[g>>>24]^o[p>>16&255]^c[_>>8&255]^l[255&w]^n[y+3],y+=4,p=u,_=f,w=h;for(let t=0;t<4;t++)r[e?3&-t:t]=d[p>>>24]<<24^d[_>>16&255]<<16^d[w>>8&255]<<8^d[255&g]^n[y++],u=p,p=_,_=w,w=g,g=u;return r}}},f={ctrGladman:class{constructor(t,e){this._prf=t,this._initIv=e,this._iv=e}reset(){this._iv=this._initIv}update(t){return this.calculate(this._prf,t,this._iv)}incWord(t){if(255==(t>>24&255)){let e=t>>16&255,n=t>>8&255,i=255&t;255===e?(e=0,255===n?(n=0,255===i?i=0:++i):++n):++e,t=0,t+=e<<16,t+=n<<8,t+=i}else t+=1<<24;return t}incCounter(t){0===(t[0]=this.incWord(t[0]))&&(t[1]=this.incWord(t[1]))}calculate(t,e,n){let i;if(!(i=e.length))return[];const r=c.bitLength(e);for(let r=0;r<i;r+=4){this.incCounter(n);const i=t.encrypt(n);e[r]^=i[0],e[r+1]^=i[1],e[r+2]^=i[2],e[r+3]^=i[3]}return c.clamp(e,r)}}},h={hmacSha1:class{constructor(t){const e=this,n=e._hash=d.sha1,i=[[],[]],r=n.prototype.blockSize/32;e._baseHash=[new n,new n],t.length>r&&(t=n.hash(t));for(let e=0;e<r;e++)i[0][e]=909522486^t[e],i[1][e]=1549556828^t[e];e._baseHash[0].update(i[0]),e._baseHash[1].update(i[1]),e._resultHash=new n(e._baseHash[0])}reset(){const t=this;t._resultHash=new t._hash(t._baseHash[0]),t._updated=!1}update(t){this._updated=!0,this._resultHash.update(t)}digest(){const t=this,e=t._resultHash.finalize(),n=new t._hash(t._baseHash[1]).update(e).finalize();return t.reset(),n}}},p="Invalid pasword",_=16,w={name:"PBKDF2"},g=Object.assign({hash:{name:"HMAC"}},w),y=Object.assign({iterations:1e3,hash:{name:"SHA-1"}},w),b=["deriveBits"],m=[8,12,16],x=[16,24,32],k=10,v=[0,0,0,0],A=crypto.subtle,E=l.bytes,U=u.aes,R=f.ctrGladman,D=h.hmacSha1;class z{constructor(t,e,n){Object.assign(this,{password:t,signed:e,strength:n-1,pendingInput:new Uint8Array(0)})}async append(t){const e=this;if(e.password){const n=I(t,0,m[e.strength]+2);await async function(t,e,n){await T(t,n,I(e,0,m[t.strength]));const i=I(e,m[t.strength]),r=t.keys.passwordVerification;if(r[0]!=i[0]||r[1]!=i[1])throw new Error(p)}(e,n,e.password),e.password=null,e.aesCtrGladman=new R(new U(e.keys.key),Array.from(v)),e.hmac=new D(e.keys.authentication),t=I(t,m[e.strength]+2)}return F(e,t,new Uint8Array(t.length-k-(t.length-k)%_),0,k,!0)}async flush(){const t=this,e=t.pendingInput,n=I(e,0,e.length-k),i=I(e,e.length-k);let r=new Uint8Array(0);if(n.length){const e=E.toBits(n);t.hmac.update(e);const i=t.aesCtrGladman.update(e);r=E.fromBits(i)}let a=!0;if(t.signed){const e=I(E.fromBits(t.hmac.digest()),0,k);for(let t=0;t<k;t++)e[t]!=i[t]&&(a=!1)}return{valid:a,data:r}}}class S{constructor(t,e){Object.assign(this,{password:t,strength:e-1,pendingInput:new Uint8Array(0)})}async append(t){const e=this;let n=new Uint8Array(0);e.password&&(n=await async function(t,e){const n=crypto.getRandomValues(new Uint8Array(m[t.strength]));return await T(t,e,n),C(n,t.keys.passwordVerification)}(e,e.password),e.password=null,e.aesCtrGladman=new R(new U(e.keys.key),Array.from(v)),e.hmac=new D(e.keys.authentication));const i=new Uint8Array(n.length+t.length-t.length%_);return i.set(n,0),F(e,t,i,n.length,0)}async flush(){const t=this;let e=new Uint8Array(0);if(t.pendingInput.length){const n=t.aesCtrGladman.update(E.toBits(t.pendingInput));t.hmac.update(n),e=E.fromBits(n)}const n=I(E.fromBits(t.hmac.digest()),0,k);return{data:C(e,n),signature:n}}}function F(t,e,n,i,r,a){const s=e.length-r;let o;for(t.pendingInput.length&&(e=C(t.pendingInput,e),n=function(t,e){if(e&&e>t.length){const n=t;(t=new Uint8Array(e)).set(n,0)}return t}(n,s-s%_)),o=0;o<=s-_;o+=_){const r=E.toBits(I(e,o,o+_));a&&t.hmac.update(r);const s=t.aesCtrGladman.update(r);a||t.hmac.update(s),n.set(E.fromBits(s),o+i)}return t.pendingInput=I(e,o),n}async function T(t,e,n){const i=(new TextEncoder).encode(e),r=await A.importKey("raw",i,g,!1,b),a=await A.deriveBits(Object.assign({salt:n},y),r,8*(2*x[t.strength]+2)),s=new Uint8Array(a);t.keys={key:E.toBits(I(s,0,x[t.strength])),authentication:E.toBits(I(s,x[t.strength],2*x[t.strength])),passwordVerification:I(s,2*x[t.strength])}}function C(t,e){let n=t;return t.length+e.length&&(n=new Uint8Array(t.length+e.length),n.set(t,0),n.set(e,t.length)),n}function I(t,e,n){return t.subarray(e,n)}const B=12;class M{constructor(t,e){Object.assign(this,{password:t,passwordVerification:e}),N(this,t)}async append(t){const e=this;if(e.password){const n=W(e,t.subarray(0,B));if(e.password=null,n[11]!=e.passwordVerification)throw new Error(p);t=t.subarray(B)}return W(e,t)}async flush(){return{valid:!0,data:new Uint8Array(0)}}}class O{constructor(t,e){Object.assign(this,{password:t,passwordVerification:e}),N(this,t)}async append(t){const e=this;let n,i;if(e.password){e.password=null;const r=crypto.getRandomValues(new Uint8Array(B));r[11]=e.passwordVerification,n=new Uint8Array(t.length+r.length),n.set(H(e,r),0),i=B}else n=new Uint8Array(t.length),i=0;return n.set(H(e,t),i),n}async flush(){return{data:new Uint8Array(0)}}}function W(t,e){const n=new Uint8Array(e.length);for(let i=0;i<e.length;i++)n[i]=j(t)^e[i],L(t,n[i]);return n}function H(t,e){const n=new Uint8Array(e.length);for(let i=0;i<e.length;i++)n[i]=j(t)^e[i],L(t,e[i]);return n}function N(t,e){t.keys=[305419896,591751049,878082192],t.crcKey0=new o(t.keys[0]),t.crcKey2=new o(t.keys[2]);for(let n=0;n<e.length;n++)L(t,e.charCodeAt(n))}function L(t,e){t.crcKey0.append([e]),t.keys[0]=~t.crcKey0.get(),t.keys[1]=V(t.keys[1]+P(t.keys[0])),t.keys[1]=V(Math.imul(t.keys[1],134775813)+1),t.crcKey2.append([t.keys[1]>>>24]),t.keys[2]=~t.crcKey2.get()}function j(t){const e=2|t.keys[2];return P(Math.imul(e,1^e)>>>8)}function P(t){return 255&t}function V(t){return 4294967295&t}const Z="deflate",q="inflate",K="Invalid signature";class G{constructor(t,{signature:e,password:n,signed:i,compressed:r,zipCrypto:a,passwordVerification:s,encryptionStrength:c},{chunkSize:l}){const d=Boolean(n);Object.assign(this,{signature:e,encrypted:d,signed:i,compressed:r,inflate:r&&new t({chunkSize:l}),crc32:i&&new o,zipCrypto:a,decrypt:d&&a?new M(n,s):new z(n,i,c)})}async append(t){const e=this;return e.encrypted&&t.length&&(t=await e.decrypt.append(t)),e.compressed&&t.length&&(t=await e.inflate.append(t)),(!e.encrypted||e.zipCrypto)&&e.signed&&t.length&&e.crc32.append(t),t}async flush(){const t=this;let e,n=new Uint8Array(0);if(t.encrypted){const e=await t.decrypt.flush();if(!e.valid)throw new Error(K);n=e.data}if((!t.encrypted||t.zipCrypto)&&t.signed){const n=new DataView(new Uint8Array(4).buffer);if(e=t.crc32.get(),n.setUint32(0,e),t.signature!=n.getUint32(0,!1))throw new Error(K)}return t.compressed&&(n=await t.inflate.append(n)||new Uint8Array(0),await t.inflate.flush()),{data:n,signature:e}}}class Y{constructor(t,{encrypted:e,signed:n,compressed:i,level:r,zipCrypto:a,password:s,passwordVerification:c,encryptionStrength:l},{chunkSize:d}){Object.assign(this,{encrypted:e,signed:n,compressed:i,deflate:i&&new t({level:r||5,chunkSize:d}),crc32:n&&new o,zipCrypto:a,encrypt:e&&a?new O(s,c):new S(s,l)})}async append(t){const e=this;let n=t;return e.compressed&&t.length&&(n=await e.deflate.append(t)),e.encrypted&&n.length&&(n=await e.encrypt.append(n)),(!e.encrypted||e.zipCrypto)&&e.signed&&t.length&&e.crc32.append(t),n}async flush(){const t=this;let e,n=new Uint8Array(0);if(t.compressed&&(n=await t.deflate.flush()||new Uint8Array(0)),t.encrypted){n=await t.encrypt.append(n);const i=await t.encrypt.flush();e=i.signature;const r=new Uint8Array(n.length+i.data.length);r.set(n,0),r.set(i.data,n.length),n=r}return t.encrypted&&!t.zipCrypto||!t.signed||(e=t.crc32.get()),{data:n,signature:e}}}const X="init",J="append",Q="flush",$="message";var tt=(t,e,n,i,r,a,s)=>(Object.assign(t,{busy:!0,codecConstructor:e,options:Object.assign({},n),scripts:s,terminate(){t.worker&&!t.busy&&(t.worker.terminate(),t.interface=null)},onTaskFinished(){t.busy=!1,r(t)}}),a?function(t,e){let n;t.interface||(t.worker=new Worker(new URL(t.scripts[0],"undefined"==typeof document?new(require("url").URL)("file:"+__filename).href:document.currentScript&&document.currentScript.src||new URL("zip-fs.min.js",document.baseURI).href)),t.worker.addEventListener($,a,!1),t.interface={append:t=>i({type:J,data:t}),flush:()=>i({type:Q})});return t.interface;async function i(i){if(!n){const n=t.options,i=t.scripts.slice(1);await r({scripts:i,type:X,options:n,config:{chunkSize:e.chunkSize}})}return r(i)}function r(e){const i=t.worker,r=new Promise(((t,e)=>n={resolve:t,reject:e}));try{if(e.data)try{e.data=e.data.buffer,i.postMessage(e,[e.data])}catch(t){i.postMessage(e)}else i.postMessage(e)}catch(e){n.reject(e),n=null,t.onTaskFinished()}return r}function a(e){const i=e.data;if(n){const e=i.error,r=i.type;if(e){const i=new Error(e.message);i.stack=e.stack,n.reject(i),n=null,t.onTaskFinished()}else if(r==X||r==Q||r==J){const e=i.data;r==Q?(n.resolve({data:new Uint8Array(e),signature:i.signature}),n=null,t.onTaskFinished()):n.resolve(e&&new Uint8Array(e))}}}}(t,i):function(t,e){const n=function(t,e,n){return e.codecType.startsWith(Z)?new Y(t,e,n):e.codecType.startsWith(q)?new G(t,e,n):void 0}(t.codecConstructor,t.options,e);return{async append(e){try{return await n.append(e)}catch(e){throw t.onTaskFinished(),e}},async flush(){try{return await n.flush()}finally{t.onTaskFinished()}}}}(t,i));let et=[],nt=[];function it(t,e,n){const i=!(!e.compressed&&!e.signed&&!e.encrypted)&&(e.useWebWorkers||void 0===e.useWebWorkers&&n.useWebWorkers),r=i&&n.workerScripts?n.workerScripts[e.codecType]:[];if(et.length<n.maxWorkers){const s={};return et.push(s),tt(s,t,e,n,a,i,r)}{const s=et.find((t=>!t.busy));return s?(rt(s),tt(s,t,e,n,a,i,r)):new Promise((n=>nt.push({resolve:n,codecConstructor:t,options:e,webWorker:i,scripts:r})))}function a(t){if(nt.length){const[{resolve:e,codecConstructor:i,options:r,webWorker:s,scripts:o}]=nt.splice(0,1);e(tt(t,i,r,n,a,s,o))}else t.worker?(rt(t),Number.isFinite(n.terminateWorkerTimeout)&&n.terminateWorkerTimeout>=0&&(t.terminateTimeout=setTimeout((()=>{et=et.filter((e=>e!=t)),t.terminate()}),n.terminateWorkerTimeout))):et=et.filter((e=>e!=t))}}function rt(t){t.terminateTimeout&&(clearTimeout(t.terminateTimeout),t.terminateTimeout=null)}const at="HTTP error ",st="HTTP Range not supported",ot="text/plain",ct="Content-Length",lt="Accept-Ranges",dt="HEAD",ut="GET",ft="bytes";class ht{constructor(){this.size=0}init(){this.initialized=!0}}class pt extends ht{}class _t extends ht{writeUint8Array(t){this.size+=t.length}}class wt extends pt{constructor(t){super(),this.blobReader=new mt(new Blob([t],{type:ot}))}async init(){super.init(),this.blobReader.init(),this.size=this.blobReader.size}async readUint8Array(t,e){return this.blobReader.readUint8Array(t,e)}}class gt extends _t{constructor(t){super(),this.encoding=t,this.blob=new Blob([],{type:ot})}async writeUint8Array(t){super.writeUint8Array(t),this.blob=new Blob([this.blob,t.buffer],{type:ot})}getData(){const t=new FileReader;return new Promise(((e,n)=>{t.onload=t=>e(t.target.result),t.onerror=()=>n(t.error),t.readAsText(this.blob,this.encoding)}))}}class yt extends pt{constructor(t){super(),this.dataURI=t;let e=t.length;for(;"="==t.charAt(e-1);)e--;this.dataStart=t.indexOf(",")+1,this.size=Math.floor(.75*(e-this.dataStart))}async readUint8Array(t,e){const n=new Uint8Array(e),i=4*Math.floor(t/3),r=atob(this.dataURI.substring(i+this.dataStart,4*Math.ceil((t+e)/3)+this.dataStart)),a=t-3*Math.floor(i/4);for(let t=a;t<a+e;t++)n[t-a]=r.charCodeAt(t);return n}}class bt extends _t{constructor(t){super(),this.data="data:"+(t||"")+";base64,",this.pending=[]}async writeUint8Array(t){super.writeUint8Array(t);let e=0,n=this.pending;const i=this.pending.length;for(this.pending="",e=0;e<3*Math.floor((i+t.length)/3)-i;e++)n+=String.fromCharCode(t[e]);for(;e<t.length;e++)this.pending+=String.fromCharCode(t[e]);n.length>2?this.data+=btoa(n):this.pending=n}getData(){return this.data+btoa(this.pending)}}class mt extends pt{constructor(t){super(),this.blob=t,this.size=t.size}async readUint8Array(t,e){const n=new FileReader;return new Promise(((i,r)=>{n.onload=t=>i(new Uint8Array(t.target.result)),n.onerror=()=>r(n.error),n.readAsArrayBuffer(this.blob.slice(t,t+e))}))}}class xt extends _t{constructor(t){super(),this.offset=0,this.contentType=t,this.blob=new Blob([],{type:t})}async writeUint8Array(t){super.writeUint8Array(t),this.blob=new Blob([this.blob,t.buffer],{type:this.contentType}),this.offset=this.blob.size}getData(){return this.blob}}class kt extends pt{constructor(t,e){super(),this.url=t,this.preventHeadRequest=e.preventHeadRequest,this.useRangeHeader=e.useRangeHeader,this.forceRangeRequests=e.forceRangeRequests,this.options=Object.assign({},e),delete this.options.preventHeadRequest,delete this.options.useRangeHeader,delete this.options.forceRangeRequests,delete this.options.useXHR}async init(){if(super.init(),Ft(this.url)&&!this.preventHeadRequest){const t=await At(dt,this.url,this.options);if(this.size=Number(t.headers.get(ct)),!this.forceRangeRequests&&this.useRangeHeader&&t.headers.get(lt)!=ft)throw new Error(st);void 0===this.size&&await vt(this,this.options)}else await vt(this,this.options)}async readUint8Array(t,e){if(this.useRangeHeader){const n=await At(ut,this.url,this.options,Object.assign({},this.options.headers,{HEADER_RANGE:"bytes="+t+"-"+(t+e-1)}));if(206!=n.status)throw new Error(st);return new Uint8Array(await n.arrayBuffer())}return this.data||await vt(this,this.options),new Uint8Array(this.data.subarray(t,t+e))}}async function vt(t,e){const n=await At(ut,t.url,e);t.data=new Uint8Array(await n.arrayBuffer()),t.size||(t.size=t.data.length)}async function At(t,e,n,i){i=Object.assign({},n.headers,i);const r=await fetch(e,Object.assign({},n,{method:t,headers:i}));if(r.status<400)return r;throw new Error(at+(r.statusText||r.status))}class Et extends pt{constructor(t,e){super(),this.url=t,this.preventHeadRequest=e.preventHeadRequest,this.useRangeHeader=e.useRangeHeader,this.forceRangeRequests=e.forceRangeRequests}async init(){if(super.init(),Ft(this.url)&&!this.preventHeadRequest)return new Promise(((t,e)=>Rt(dt,this.url,(n=>{this.size=Number(n.getResponseHeader(ct)),this.useRangeHeader?this.forceRangeRequests||n.getResponseHeader(lt)==ft?t():e(new Error(st)):void 0===this.size?Ut(this,this.url).then((()=>t())).catch(e):t()}),e)));await Ut(this,this.url)}async readUint8Array(t,e){if(!this.useRangeHeader)return this.data||await Ut(this,this.url),new Uint8Array(this.data.subarray(t,t+e));if(206!=(await new Promise(((n,i)=>Rt(ut,this.url,(t=>n(new Uint8Array(t.response))),i,[["Range","bytes="+t+"-"+(t+e-1)]])))).status)throw new Error(st)}}function Ut(t,e){return new Promise(((n,i)=>Rt(ut,e,(e=>{t.data=new Uint8Array(e.response),t.size||(t.size=t.data.length),n()}),i)))}function Rt(t,e,n,i,r=[]){const a=new XMLHttpRequest;return a.addEventListener("load",(()=>{a.status<400?n(a):i(at+(a.statusText||a.status))}),!1),a.addEventListener("error",i,!1),a.open(t,e),r.forEach((t=>a.setRequestHeader(t[0],t[1]))),a.responseType="arraybuffer",a.send(),a}class Dt extends pt{constructor(t,e={}){super(),this.url=t,e.useXHR?this.reader=new Et(t,e):this.reader=new kt(t,e)}set size(t){}get size(){return this.reader.size}async init(){super.init(),await this.reader.init()}async readUint8Array(t,e){return this.reader.readUint8Array(t,e)}}class zt extends pt{constructor(t){super(),this.array=t,this.size=t.length}async readUint8Array(t,e){return this.array.slice(t,t+e)}}class St extends _t{constructor(){super(),this.array=new Uint8Array(0)}async writeUint8Array(t){super.writeUint8Array(t);const e=this.array;this.array=new Uint8Array(e.length+t.length),this.array.set(e),this.array.set(t,e.length)}getData(){return this.array}}function Ft(t){if("undefined"!=typeof document){const e=document.createElement("a");return e.href=t,"http:"==e.protocol||"https:"==e.protocol}return/^https?:\/\//i.test(t)}const Tt=4294967295,Ct=65535,It=67324752,Bt=134695760,Mt=33639248,Ot=101010256,Wt=101075792,Ht=117853008,Nt=39169,Lt=21589,jt=2048,Pt="/",Vt=new Date(2107,11,31),Zt=new Date(1980,0,1),qt="\0☺☻♥♦♣♠•◘○◙♂♀♪♫☼►◄↕‼¶§▬↨↑↓→←∟↔▲▼ !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~⌂ÇüéâäàåçêëèïîìÄÅÉæÆôöòûùÿÖÜ¢£¥₧ƒáíóúñÑªº¿⌐¬½¼¡«»░▒▓│┤╡╢╖╕╣║╗╝╜╛┐└┴┬├─┼╞╟╚╔╩╦╠═╬╧╨╤╥╙╘╒╓╫╪┘┌█▄▌▐▀αßΓπΣσµτΦΘΩδ∞φε∩≡±≥≤⌠⌡÷≈°∙·√ⁿ²■ ".split("");const Kt="Abort error";async function Gt(t,e,n,i,r,a,s){const o=Math.max(a.chunkSize,64);return async function a(c=0,l=0){const d=s.signal;if(c<r){Yt(d,t);const u=await e.readUint8Array(c+i,Math.min(o,r-c)),f=u.length;Yt(d,t);const h=await t.append(u);if(Yt(d,t),l+=await Xt(n,h),s.onprogress)try{s.onprogress(c+f,r)}catch(t){}return a(c+o,l)}{const e=await t.flush();return l+=await Xt(n,e.data),{signature:e.signature,length:l}}}()}function Yt(t,e){if(t&&t.aborted)throw e.flush(),new Error(Kt)}async function Xt(t,e){return e.length&&await t.writeUint8Array(e),e.length}const Jt=["filename","rawFilename","directory","encrypted","compressedSize","uncompressedSize","lastModDate","rawLastModDate","comment","rawComment","signature","extraField","rawExtraField","bitFlag","extraFieldZip64","extraFieldUnicodePath","extraFieldUnicodeComment","extraFieldAES","filenameUTF8","commentUTF8","offset","zip64","compressionMethod","extraFieldNTFS","lastAccessDate","creationDate","extraFieldExtendedTimestamp","version","versionMadeBy","msDosCompatible","internalFileAttribute","externalFileAttribute"];class Qt{constructor(t){Jt.forEach((e=>this[e]=t[e]))}}const $t="File format is not recognized",te="End of central directory not found",ee="End of Zip64 central directory not found",ne="End of Zip64 central directory locator not found",ie="Central directory header not found",re="Local file header not found",ae="Zip64 extra field not found",se="File contains encrypted entry",oe="Encryption method not supported",ce="Compression method not supported",le="utf-8",de=["uncompressedSize","compressedSize","offset"];class ue{constructor(t,e={}){Object.assign(this,{reader:t,options:e,config:i()})}async getEntries(t={}){const e=this,n=e.reader;if(n.initialized||await n.init(),n.size<22)throw new Error($t);const i=await async function(t,e,n,i,r){const a=new Uint8Array(4);!function(t,e,n){t.setUint32(e,n,!0)}(Ae(a),0,e);const s=i+r;return await o(i)||await o(Math.min(s,n));async function o(e){const r=n-e,s=await Ee(t,r,e);for(let t=s.length-i;t>=0;t--)if(s[t]==a[0]&&s[t+1]==a[1]&&s[t+2]==a[2]&&s[t+3]==a[3])return{offset:r+t,buffer:s.slice(t,t+i).buffer}}}(n,Ot,n.size,22,1048560);if(!i)throw new Error(te);const r=Ae(i);let a=ke(r,12),s=ke(r,16),o=xe(r,8),c=0;if(s==Tt||o==Ct){const t=Ae(await Ee(n,i.offset-20,20));if(ke(t,0)!=Ht)throw new Error(ee);s=ve(t,8);let e=await Ee(n,s,56),r=Ae(e);const l=i.offset-20-56;if(ke(r,0)!=Wt&&s!=l){const t=s;s=l,c=s-t,e=await Ee(n,s,56),r=Ae(e)}if(ke(r,0)!=Wt)throw new Error(ne);o=ve(r,24),a=ke(t,4),s-=ve(r,40)}if(s<0||s>=n.size)throw new Error($t);let l=0,d=await Ee(n,s,n.size-s),u=Ae(d);const f=i.offset-a;if(ke(u,l)!=Mt&&s!=f){const t=s;s=f,c=s-t,d=await Ee(n,s,n.size-s),u=Ae(d)}if(s<0||s>=n.size)throw new Error($t);const h=[];for(let i=0;i<o;i++){const r=new fe(n,e.config,e.options);if(ke(u,l)!=Mt)throw new Error(ie);he(r,u,l+6);const a=Boolean(r.bitFlag.languageEncodingFlag),s=l+46,f=s+r.filenameLength,p=f+r.extraFieldLength,_=xe(u,l+4),w=0==(0&_);Object.assign(r,{versionMadeBy:_,msDosCompatible:w,compressedSize:0,uncompressedSize:0,commentLength:xe(u,l+32),directory:w&&16==(16&me(u,l+38)),offset:ke(u,l+42)+c,internalFileAttribute:ke(u,l+34),externalFileAttribute:ke(u,l+38),rawFilename:d.subarray(s,f),filenameUTF8:a,commentUTF8:a,rawExtraField:d.subarray(f,p)});const g=p+r.commentLength;r.rawComment=d.subarray(p,g),r.filename=ge(r.rawFilename,r.filenameUTF8?le:we(e,t,"filenameEncoding")),r.comment=ge(r.rawComment,r.commentUTF8?le:we(e,t,"commentEncoding")),!r.directory&&r.filename.endsWith(Pt)&&(r.directory=!0),pe(r,r,u,l+6);const y=new Qt(r);if(y.getData=(t,e)=>r.getData(t,y,e),h.push(y),l=g,t.onprogress)try{t.onprogress(i+1,o,new Qt(r))}catch(t){}}return h}async close(){}}class fe{constructor(t,e,n){Object.assign(this,{reader:t,config:e,options:n})}async getData(t,e,n={}){const i=this,{reader:r,offset:a,extraFieldAES:s,compressionMethod:o,config:c,bitFlag:l,signature:d,rawLastModDate:u,compressedSize:f}=i,h=i.localDirectory={};r.initialized||await r.init();let p=await Ee(r,a,30);const _=Ae(p);let w=we(i,n,"password");if(w=w&&w.length&&w,s&&99!=s.originalCompressionMethod)throw new Error(ce);if(0!=o&&8!=o)throw new Error(ce);if(ke(_,0)!=It)throw new Error(re);he(h,_,4),p=await Ee(r,a,30+h.filenameLength+h.extraFieldLength),h.rawExtraField=p.subarray(30+h.filenameLength),pe(i,h,_,4),e.lastAccessDate=h.lastAccessDate,e.creationDate=h.creationDate;const g=i.encrypted&&h.encrypted,y=g&&!s;if(g){if(!y&&void 0===s.strength)throw new Error(oe);if(!w)throw new Error(se)}const b=await it(c.Inflate,{codecType:q,password:w,zipCrypto:y,encryptionStrength:s&&s.strength,signed:we(i,n,"checkSignature"),passwordVerification:y&&(l.dataDescriptor?u>>>8&255:d>>>24&255),signature:d,compressed:0!=o,encrypted:g,useWebWorkers:we(i,n,"useWebWorkers")},c);t.initialized||await t.init();const m=we(i,n,"signal"),x=a+30+h.filenameLength+h.extraFieldLength;return await Gt(b,r,t,x,f,c,{onprogress:n.onprogress,signal:m}),t.getData()}}function he(t,e,n){const i=t.rawBitFlag=xe(e,n+2),r=1==(1&i),a=ke(e,n+6);Object.assign(t,{encrypted:r,version:xe(e,n),bitFlag:{level:(6&i)>>1,dataDescriptor:8==(8&i),languageEncodingFlag:(i&jt)==jt},rawLastModDate:a,lastModDate:ye(a),filenameLength:xe(e,n+22),extraFieldLength:xe(e,n+24)})}function pe(t,e,n,i){const r=e.rawExtraField,a=e.extraField=new Map,s=Ae(new Uint8Array(r));let o=0;try{for(;o<r.length;){const t=xe(s,o),e=xe(s,o+2);a.set(t,{type:t,data:r.slice(o+4,o+4+e)}),o+=4+e}}catch(t){}const c=xe(n,i+4);e.signature=ke(n,i+10),e.uncompressedSize=ke(n,i+18),e.compressedSize=ke(n,i+14);const l=a.get(1);l&&(!function(t,e){e.zip64=!0;const n=Ae(t.data);t.values=[];for(let e=0;e<Math.floor(t.data.length/8);e++)t.values.push(ve(n,0+8*e));const i=de.filter((t=>e[t]==Tt));for(let e=0;e<i.length;e++)t[i[e]]=t.values[e];de.forEach((n=>{if(e[n]==Tt){if(void 0===t[n])throw new Error(ae);e[n]=t[n]}}))}(l,e),e.extraFieldZip64=l);const d=a.get(28789);d&&(_e(d,"filename","rawFilename",e,t),e.extraFieldUnicodePath=d);const u=a.get(25461);u&&(_e(u,"comment","rawComment",e,t),e.extraFieldUnicodeComment=u);const f=a.get(39169);f?(!function(t,e,n){const i=Ae(t.data);t.vendorVersion=me(i,0),t.vendorId=me(i,2);const r=me(i,4);t.strength=r,t.originalCompressionMethod=n,e.compressionMethod=t.compressionMethod=xe(i,5)}(f,e,c),e.extraFieldAES=f):e.compressionMethod=c;const h=a.get(10);h&&(!function(t,e){const n=Ae(t.data);let i,r=4;try{for(;r<t.data.length&&!i;){const e=xe(n,r),a=xe(n,r+2);1==e&&(i=t.data.slice(r+4,r+4+a)),r+=4+a}}catch(t){}try{if(i&&24==i.length){const n=Ae(i),r=n.getBigUint64(0,!0),a=n.getBigUint64(8,!0),s=n.getBigUint64(16,!0);Object.assign(t,{rawLastModDate:r,rawLastAccessDate:a,rawCreationDate:s});const o=be(r),c=be(a),l={lastModDate:o,lastAccessDate:c,creationDate:be(s)};Object.assign(t,l),Object.assign(e,l)}}catch(t){}}(h,e),e.extraFieldNTFS=h);const p=a.get(Lt);p&&(!function(t,e){const n=Ae(t.data),i=me(n,0),r=[],a=[];1==(1&i)&&(r.push("lastModDate"),a.push("rawLastModDate"));2==(2&i)&&(r.push("lastAccessDate"),a.push("rawLastAccessDate"));4==(4&i)&&(r.push("creationDate"),a.push("rawCreationDate"));let s=1;r.forEach(((i,r)=>{if(t.data.length>=s+4){const o=ke(n,s);e[i]=t[i]=new Date(1e3*o);const c=a[r];t[c]=o}s+=4}))}(p,e),e.extraFieldExtendedTimestamp=p)}function _e(t,e,n,i,r){const a=Ae(t.data);t.version=me(a,0),t.signature=ke(a,1);const s=new o;s.append(r[n]);const c=Ae(new Uint8Array(4));c.setUint32(0,s.get(),!0),t[e]=(new TextDecoder).decode(t.data.subarray(5)),t.valid=!r.bitFlag.languageEncodingFlag&&t.signature==ke(c,0),t.valid&&(i[e]=t[e],i[e+"UTF8"]=!0)}function we(t,e,n){return void 0===e[n]?t.options[n]:e[n]}function ge(t,e){return e&&"cp437"!=e.trim().toLowerCase()?new TextDecoder(e).decode(t):(t=>{let e="";for(let n=0;n<t.length;n++)e+=qt[t[n]];return e})(t)}function ye(t){const e=(4294901760&t)>>16,n=65535&t;try{return new Date(1980+((65024&e)>>9),((480&e)>>5)-1,31&e,(63488&n)>>11,(2016&n)>>5,2*(31&n),0)}catch(t){}}function be(t){return new Date(Number(t/10000n-11644473600000n))}function me(t,e){return t.getUint8(e)}function xe(t,e){return t.getUint16(e,!0)}function ke(t,e){return t.getUint32(e,!0)}function ve(t,e){return Number(t.getBigUint64(e,!0))}function Ae(t){return new DataView(t.buffer)}function Ee(t,e,n){return t.readUint8Array(e,n)}const Ue="File already exists",Re="Zip file comment exceeds 64KB",De="File entry comment exceeds 64KB",ze="File entry name exceeds 64KB",Se="Version exceeds 65535",Fe="The strength must equal 1, 2, or 3",Te="Extra field type exceeds 65535",Ce="Extra field data exceeds 64KB",Ie="Zip64 is not supported",Be=new Uint8Array([7,0,2,0,65,69,3,0,0]);let Me=0;class Oe{constructor(t,e={}){Object.assign(this,{writer:t,options:e,config:i(),files:new Map,offset:t.size,pendingCompressedSize:0,pendingEntries:[]})}async add(t="",e,n={}){const i=this;if(!(Me<i.config.maxWorkers))return new Promise(((r,a)=>i.pendingEntries.push({name:t,reader:e,options:n,resolve:r,reject:a})));Me++;try{return await async function(t,e,n,i){e=e.trim(),i.directory&&!e.endsWith(Pt)?e+=Pt:i.directory=e.endsWith(Pt);if(t.files.has(e))throw new Error(Ue);const r=(new TextEncoder).encode(e);if(r.length>Ct)throw new Error(ze);const a=i.comment||"",s=(new TextEncoder).encode(a);if(s.length>Ct)throw new Error(De);const o=t.options.version||i.version||0;if(o>Ct)throw new Error(Se);const c=t.options.versionMadeBy||i.versionMadeBy||20;if(c>Ct)throw new Error(Se);const l=Ne(t,i,"lastModDate")||new Date,d=Ne(t,i,"lastAccessDate"),u=Ne(t,i,"creationDate"),f=Ne(t,i,"password"),h=Ne(t,i,"encryptionStrength")||3,p=Ne(t,i,"zipCrypto");if(void 0!==f&&void 0!==h&&(h<1||h>3))throw new Error(Fe);let _=new Uint8Array(0);const w=i.extraField;if(w){let t=0,e=0;w.forEach((e=>t+=4+e.length)),_=new Uint8Array(t),w.forEach(((t,n)=>{if(n>Ct)throw new Error(Te);if(t.length>Ct)throw new Error(Ce);Ze(_,new Uint16Array([n]),e),Ze(_,new Uint16Array([t.length]),e+2),Ze(_,t,e+4),e+=4+t.length}))}let g=Ne(t,i,"extendedTimestamp");void 0===g&&(g=!0);let y=0,b=Ne(t,i,"keepOrder");void 0===b&&(b=!0);let m=0,x=Ne(t,i,"msDosCompatible");void 0===x&&(x=!0);const k=Ne(t,i,"internalFileAttribute")||0,v=Ne(t,i,"externalFileAttribute")||0;n&&(n.initialized||await n.init(),m=n.size,y=function(t){return t+5*(Math.floor(t/16383)+1)}(m));let A=i.zip64||t.options.zip64||!1;if(t.offset+t.pendingCompressedSize>=Tt||m>=Tt||y>=Tt){if(!1===i.zip64||!1===t.options.zip64||!b)throw new Error(Ie);A=!0}t.pendingCompressedSize+=y,await Promise.resolve();const E=Ne(t,i,"level"),U=Ne(t,i,"useWebWorkers"),R=Ne(t,i,"bufferedWrite");let D=Ne(t,i,"dataDescriptor");const z=Ne(t,i,"signal");void 0===D&&(D=!0);const S=await async function(t,e,n,i){const r=t.files,a=t.writer,s=Array.from(r.values()).pop();let o,c,l,d={};r.set(e,d);try{let u,f,h;if(i.keepOrder&&(u=s&&s.lock),d.lock=h=new Promise((t=>l=t)),i.bufferedWrite||t.lockWrite||!i.dataDescriptor?(f=new xt,f.init(),o=!0):(t.lockWrite=new Promise((t=>c=t)),a.initialized||await a.init(),f=a),d=await async function(t,e,n,i){const{rawFilename:r,lastAccessDate:a,creationDate:s,password:o,level:c,zip64:l,zipCrypto:d,dataDescriptor:u,directory:f,version:h,versionMadeBy:p,rawComment:_,rawExtraField:w,useWebWorkers:g,onprogress:y,signal:b,encryptionStrength:m,extendedTimestamp:x,msDosCompatible:k,internalFileAttribute:v,externalFileAttribute:A}=i,E=Boolean(o&&o.length),U=0!==c&&!f;let R,D,z;if(E&&!d){R=new Uint8Array(Be.length+2);const t=qe(R);je(t,0,Nt),Ze(R,Be,2),Le(t,8,m)}else R=new Uint8Array(0);if(x){z=new Uint8Array(9+(a?4:0)+(s?4:0));const t=qe(z);je(t,0,Lt),je(t,2,z.length-4);Le(t,4,1+(a?2:0)+(s?4:0)),Pe(t,5,Math.floor(i.lastModDate.getTime()/1e3)),a&&Pe(t,9,Math.floor(a.getTime()/1e3)),s&&Pe(t,13,Math.floor(s.getTime()/1e3));try{D=new Uint8Array(36);const t=qe(D),e=He(i.lastModDate);je(t,0,10),je(t,2,32),je(t,8,1),je(t,10,24),Ve(t,12,e),Ve(t,20,He(a)||e),Ve(t,28,He(s)||e)}catch(t){D=new Uint8Array(0)}}else D=z=new Uint8Array(0);const S={version:h||20,versionMadeBy:p,zip64:l,directory:Boolean(f),filenameUTF8:!0,rawFilename:r,commentUTF8:!0,rawComment:_,rawExtraFieldZip64:l?new Uint8Array(28):new Uint8Array(0),rawExtraFieldExtendedTimestamp:z,rawExtraFieldNTFS:D,rawExtraFieldAES:R,rawExtraField:w,extendedTimestamp:x,msDosCompatible:k,internalFileAttribute:v,externalFileAttribute:A};let F=S.uncompressedSize=0,T=jt;u&&(T|=8);let C=0;U&&(C=8);l&&(S.version=S.version>45?S.version:45);E&&(T|=1,d||(S.version=S.version>51?S.version:51,C=99,U&&(S.rawExtraFieldAES[9]=8)));S.compressionMethod=C;const I=S.headerArray=new Uint8Array(26),B=qe(I);je(B,0,S.version),je(B,2,T),je(B,4,C);const M=new Uint32Array(1),O=qe(M);let W;W=i.lastModDate<Zt?Zt:i.lastModDate>Vt?Vt:i.lastModDate;je(O,0,(W.getHours()<<6|W.getMinutes())<<5|W.getSeconds()/2),je(O,2,(W.getFullYear()-1980<<4|W.getMonth()+1)<<5|W.getDate());const H=M[0];Pe(B,6,H),je(B,22,r.length);const N=R.length+z.length+D.length+S.rawExtraField.length;je(B,24,N);const L=new Uint8Array(30+r.length+N);let j;Pe(qe(L),0,It),Ze(L,I,4),Ze(L,r,30),Ze(L,R,30+r.length),Ze(L,z,30+r.length+R.length),Ze(L,D,30+r.length+R.length+z.length),Ze(L,S.rawExtraField,30+r.length+R.length+z.length+D.length);let P=0;if(t){F=S.uncompressedSize=t.size;const i=await it(n.Deflate,{codecType:Z,level:c,password:o,encryptionStrength:m,zipCrypto:E&&d,passwordVerification:E&&d&&H>>8&255,signed:!0,compressed:U,encrypted:E,useWebWorkers:g},n);await e.writeUint8Array(L),S.dataWritten=!0,j=await Gt(i,t,e,0,F,n,{onprogress:y,signal:b}),P=j.length}else await e.writeUint8Array(L),S.dataWritten=!0;let V,q=new Uint8Array(0);u&&(q=new Uint8Array(l?24:16),V=qe(q),Pe(V,0,Bt));if(t){const t=j.signature;if(E&&!d||void 0===t||(Pe(B,10,t),S.signature=t,u&&Pe(V,4,t)),l){const t=qe(S.rawExtraFieldZip64);je(t,0,1),je(t,2,24),Pe(B,14,Tt),Ve(t,12,BigInt(P)),Pe(B,18,Tt),Ve(t,4,BigInt(F)),u&&(Ve(V,8,BigInt(P)),Ve(V,16,BigInt(F)))}else Pe(B,14,P),Pe(B,18,F),u&&(Pe(V,8,P),Pe(V,12,F))}u&&await e.writeUint8Array(q);const K=L.length+P+q.length;return Object.assign(S,{compressedSize:P,lastModDate:W,rawLastModDate:H,creationDate:s,lastAccessDate:a,encrypted:E,length:K}),S}(n,f,t.config,i),d.lock=h,r.set(e,d),d.filename=e,o){let e=0;const n=f.getData();let s;await Promise.all([t.lockWrite,u]);do{s=Array.from(r.values()).find((t=>t.writingBufferedData)),s&&await s.lock}while(s&&s.lock);if(d.writingBufferedData=!0,!i.dataDescriptor){const t=26,r=await We(n,0,t),s=new DataView(r);d.encrypted&&!i.zipCrypto||Pe(s,14,d.signature),d.zip64?(Pe(s,18,Tt),Pe(s,22,Tt)):(Pe(s,18,d.compressedSize),Pe(s,22,d.uncompressedSize)),await a.writeUint8Array(new Uint8Array(r)),e=t}await async function(t,e,n=0){const i=536870912;async function r(){if(n<e.size){const a=await We(e,n,n+i);await t.writeUint8Array(new Uint8Array(a)),n+=i,await r()}}await r()}(a,n,e),delete d.writingBufferedData}if(d.offset=t.offset,d.zip64){Ve(qe(d.rawExtraFieldZip64),20,BigInt(d.offset))}else if(d.offset>=Tt)throw new Error(Ie);return t.offset+=d.length,d}catch(n){throw(o&&d.writingBufferedData||!o&&d.dataWritten)&&(n.corruptedEntry=t.hasCorruptedEntries=!0,d.uncompressedSize&&(t.offset+=d.uncompressedSize)),r.delete(e),n}finally{l(),c&&c()}}(t,e,n,Object.assign({},i,{rawFilename:r,rawComment:s,version:o,versionMadeBy:c,lastModDate:l,lastAccessDate:d,creationDate:u,rawExtraField:_,zip64:A,password:f,level:E,useWebWorkers:U,encryptionStrength:h,extendedTimestamp:g,zipCrypto:p,bufferedWrite:R,keepOrder:b,dataDescriptor:D,signal:z,msDosCompatible:x,internalFileAttribute:k,externalFileAttribute:v}));y&&(t.pendingCompressedSize-=y);return Object.assign(S,{name:e,comment:a,extraField:w}),new Qt(S)}(i,t,e,n)}finally{Me--;const t=i.pendingEntries.shift();t&&i.add(t.name,t.reader,t.options).then(t.resolve).catch(t.reject)}}async close(t=new Uint8Array(0),e={}){return await async function(t,e,n){const i=t.writer,r=t.files;let a=0,s=0,o=t.offset,c=r.size;for(const[,t]of r)s+=46+t.rawFilename.length+t.rawComment.length+t.rawExtraFieldZip64.length+t.rawExtraFieldAES.length+t.rawExtraFieldExtendedTimestamp.length+t.rawExtraFieldNTFS.length+t.rawExtraField.length;let l=n.zip64||t.options.zip64||!1;if(o>=Tt||s>=Tt||c>=Ct){if(!1===n.zip64||!1===t.options.zip64)throw new Error(Ie);l=!0}const d=new Uint8Array(s+(l?98:22)),u=qe(d);if(e&&e.length){if(!(e.length<=Ct))throw new Error(Re);je(u,a+20,e.length)}for(const[t,e]of Array.from(r.values()).entries()){const{rawFilename:i,rawExtraFieldZip64:s,rawExtraFieldAES:o,rawExtraField:c,rawComment:l,versionMadeBy:f,headerArray:h,directory:p,zip64:_,msDosCompatible:w,internalFileAttribute:g,externalFileAttribute:y}=e;let b,m;if(e.extendedTimestamp){m=e.rawExtraFieldNTFS,b=new Uint8Array(9);const t=qe(b);je(t,0,Lt),je(t,2,b.length-4),Le(t,4,1),Pe(t,5,Math.floor(e.lastModDate.getTime()/1e3))}else m=b=new Uint8Array(0);const x=s.length+o.length+b.length+m.length+c.length;if(Pe(u,a,Mt),je(u,a+4,f),Ze(d,h,a+6),je(u,a+30,x),je(u,a+32,l.length),Pe(u,a+34,g),y?Pe(u,a+38,y):p&&w&&Le(u,a+38,16),Pe(u,a+42,_?Tt:e.offset),Ze(d,i,a+46),Ze(d,s,a+46+i.length),Ze(d,o,a+46+i.length+s.length),Ze(d,b,a+46+i.length+s.length+o.length),Ze(d,m,a+46+i.length+s.length+o.length+b.length),Ze(d,c,a+46+i.length+s.length+o.length+b.length+m.length),Ze(d,l,a+46+i.length+x),a+=46+i.length+x+l.length,n.onprogress)try{n.onprogress(t+1,r.size,new Qt(e))}catch(t){}}l&&(Pe(u,a,Wt),Ve(u,a+4,BigInt(44)),je(u,a+12,45),je(u,a+14,45),Ve(u,a+24,BigInt(c)),Ve(u,a+32,BigInt(c)),Ve(u,a+40,BigInt(s)),Ve(u,a+48,BigInt(o)),Pe(u,a+56,Ht),Ve(u,a+64,BigInt(o)+BigInt(s)),Pe(u,a+72,1),c=Ct,o=Tt,s=Tt,a+=76);Pe(u,a,Ot),je(u,a+8,c),je(u,a+10,c),Pe(u,a+12,s),Pe(u,a+16,o),await i.writeUint8Array(d),e&&e.length&&await i.writeUint8Array(e)}(this,t,e),this.writer.getData()}}function We(t,e,n){const i=new FileReader;return new Promise(((r,a)=>{i.onload=t=>r(t.target.result),i.onerror=()=>a(i.error),i.readAsArrayBuffer(e||n?t.slice(e,n):t)}))}function He(t){if(t)return 10000n*(BigInt(t.getTime())+11644473600000n)}function Ne(t,e,n){return void 0===e[n]?t.options[n]:e[n]}function Le(t,e,n){t.setUint8(e,n)}function je(t,e,n){t.setUint16(e,n,!0)}function Pe(t,e,n){t.setUint32(e,n,!0)}function Ve(t,e,n){t.setBigUint64(e,n,!0)}function Ze(t,e,n){t.set(e,n)}function qe(t){return new DataView(t.buffer)}const Ke=524288;class Ge{constructor(t,e,n,i){const r=this;if(t.root&&i&&i.getChildByName(e))throw new Error("Entry filename already exists");n||(n={}),Object.assign(r,{fs:t,name:e,data:n.data,id:t.entries.length,parent:i,children:[],uncompressedSize:0}),t.entries.push(r),i&&r.parent.children.push(r)}moveTo(t){this.fs.move(this,t)}getFullname(){return this.getRelativeName()}getRelativeName(t=this.fs.root){let e=this.name,n=this.parent;for(;n&&n!=t;)e=(n.name?n.name+"/":"")+e,n=n.parent;return e}isDescendantOf(t){let e=this.parent;for(;e&&e.id!=t.id;)e=e.parent;return Boolean(e)}}class Ye extends Ge{constructor(t,e,n,i){super(t,e,n,i);const r=this;r.Reader=n.Reader,r.Writer=n.Writer,n.getData&&(r.getData=n.getData)}async getData(t,e={}){const n=this;return!t||t.constructor==n.Writer&&n.data?n.data:(n.reader=new n.Reader(n.data,e),await n.reader.init(),t.initialized||await t.init(),n.uncompressedSize=n.reader.size,async function(t,e){return n();async function n(i=0){const r=i*Ke;if(r<t.size){const a=await t.readUint8Array(r,Math.min(Ke,t.size-r));return await e.writeUint8Array(a),n(i+1)}return e.getData()}}(n.reader,t))}getText(t,e){return this.getData(new gt(t),e)}getBlob(t,e){return this.getData(new xt(t),e)}getData64URI(t,e){return this.getData(new bt(t),e)}getUint8Array(t){return this.getData(new St,t)}replaceBlob(t){Object.assign(this,{data:t,Reader:mt,Writer:xt,reader:null})}replaceText(t){Object.assign(this,{data:t,Reader:wt,Writer:gt,reader:null})}replaceData64URI(t){Object.assign(this,{data:t,Reader:yt,Writer:bt,reader:null})}replaceUint8Array(t){Object.assign(this,{data:t,Reader:zt,Writer:St,reader:null})}}class Xe extends Ge{constructor(t,e,n,i){super(t,e,n,i),this.directory=!0}addDirectory(t){return nn(this,t,null,!0)}addText(t,e){return nn(this,t,{data:e,Reader:wt,Writer:gt})}addBlob(t,e){return nn(this,t,{data:e,Reader:mt,Writer:xt})}addData64URI(t,e){return nn(this,t,{data:e,Reader:yt,Writer:bt})}addUint8Array(t,e){return nn(this,t,{data:e,Reader:zt,Writer:St})}addHttpContent(t,e,n={}){return nn(this,t,{data:e,Reader:class extends Dt{constructor(t){super(t,n)}}})}async addFileSystemEntry(t){return async function(t,e){if(e.isDirectory){const i=t.addDirectory(e.name);return await n(i,e),i}return new Promise(((n,i)=>e.file((i=>n(t.addBlob(e.name,i))),i)));async function n(t,e){const r=await i(e);for(const e of r)e.isDirectory?await n(t.addDirectory(e.name),e):await new Promise(((n,i)=>{e.file((i=>{const r=t.addBlob(e.name,i);r.uncompressedSize=i.size,n(r)}),i)}))}function i(t){return new Promise(((e,n)=>{let i=[];function r(t){t.readEntries((n=>{n.length?(i=i.concat(n),r(t)):e(i)}),n)}t.isDirectory&&r(t.createReader()),t.isFile&&e(i)}))}}(this,t)}async addData(t,e){return nn(this,t,e)}async importBlob(t,e={}){await this.importZip(new mt(t),e)}async importData64URI(t,e={}){await this.importZip(new yt(t),e)}async importUint8Array(t,e={}){await this.importZip(new zt(t),e)}async importHttpContent(t,e={}){await this.importZip(new Dt(t,e),e)}async exportBlob(t={}){return this.exportZip(new xt("application/zip"),t)}async exportData64URI(t={}){return this.exportZip(new bt("application/zip"),t)}async exportUint8Array(t={}){return this.exportZip(new St,t)}async importZip(t,e){t.initialized||await t.init();const n=new ue(t,e);(await n.getEntries()).forEach((t=>{let n=this;const i=t.filename.split("/"),r=i.pop();i.forEach((t=>n=n.getChildByName(t)||new Xe(this.fs,t,null,n))),t.directory||nn(n,r,{data:t,Reader:Qe(Object.assign({},e))})}))}async exportZip(t,e){const n=this;await $e(n),await t.init();const i=new Oe(t,e);return await async function(t,e,n,i){const r=e,a=new Map;async function s(t,e){async function o(){if(i.bufferedWrite)await Promise.all(e.children.map(c));else for(const t of e.children)await c(t)}async function c(e){const o=i.relativePath?e.getRelativeName(r):e.getFullname();await t.add(o,e.reader,Object.assign({directory:e.directory},Object.assign({},i,{onprogress:t=>{if(i.onprogress){a.set(o,t);try{i.onprogress(Array.from(a.values()).reduce(((t,e)=>t+e)),n)}catch(t){}}}}))),await s(t,e)}await o()}await s(t,e)}(i,n,function(t,e){let n=0;return t.forEach(i),n;function i(t){n+=t[e],t.children&&t.children.forEach(i)}}([n],"uncompressedSize"),e),await i.close(),t.getData()}getChildByName(t){const e=this.children;for(let n=0;n<e.length;n++){const i=e[n];if(i.name==t)return i}}}const Je={FS:class{constructor(){en(this)}get children(){return this.root.children}remove(t){tn(t),this.entries[t.id]=null}move(t,e){if(t==this.root)throw new Error("Root directory cannot be moved");if(!e.directory)throw new Error("Target entry is not a directory");if(e.isDescendantOf(t))throw new Error("Entry is a ancestor of target entry");if(t!=e){if(e.getChildByName(t.name))throw new Error("Entry filename already exists");tn(t),t.parent=e,e.children.push(t)}}find(t){const e=t.split("/");let n=this.root;for(let t=0;n&&t<e.length;t++)n=n.getChildByName(e[t]);return n}getById(t){return this.entries[t]}getChildByName(t){return this.root.getChildByName(t)}addDirectory(t){return this.root.addDirectory(t)}addText(t,e){return this.root.addText(t,e)}addBlob(t,e){return this.root.addBlob(t,e)}addData64URI(t,e){return this.root.addData64URI(t,e)}addHttpContent(t,e,n){return this.root.addHttpContent(t,e,n)}async addFileSystemEntry(t){return this.root.addFileSystemEntry(t)}async addData(t,e){return this.root.addData(t,e)}async importBlob(t,e){en(this),await this.root.importBlob(t,e)}async importData64URI(t,e){en(this),await this.root.importData64URI(t,e)}async importHttpContent(t,e){en(this),await this.root.importHttpContent(t,e)}async exportBlob(t){return this.root.exportBlob(t)}async exportData64URI(t){return this.root.exportData64URI(t)}},ZipDirectoryEntry:Xe,ZipFileEntry:Ye};function Qe(t){return class extends pt{constructor(t,e={}){super(),this.entry=t,this.options=e}async init(){const e=this;e.size=e.entry.uncompressedSize;const n=await e.entry.getData(new xt,Object.assign({},e.options,t));e.data=n,e.blobReader=new mt(n)}async readUint8Array(t,e){return this.blobReader.readUint8Array(t,e)}}}async function $e(t){if(t.children.length)for(const e of t.children)e.directory?await $e(e):(e.reader=new e.Reader(e.data),await e.reader.init(),e.uncompressedSize=e.reader.size)}function tn(t){const e=t.parent.children;e.forEach(((n,i)=>{n.id==t.id&&e.splice(i,1)}))}function en(t){t.entries=[],t.root=new Xe(t)}function nn(t,e,n,i){if(t.directory)return i?new Xe(t.fs,e,n,t):new Ye(t.fs,e,n,t);throw new Error("Parent entry is not a directory")}(()=>{if("function"==typeof URL.createObjectURL){const t=(()=>{const t=[];for(let e=0;e<256;e++){let n=e;for(let t=0;t<8;t++)1&n?n=n>>>1^3988292384:n>>>=1;t[e]=n}class e{constructor(t){this.crc=t||-1}append(e){let n=0|this.crc;for(let i=0,r=0|e.length;i<r;i++)n=n>>>8^t[255&(n^e[i])];this.crc=n}get(){return~this.crc}}const n={concat(t,e){if(0===t.length||0===e.length)return t.concat(e);const i=t[t.length-1],r=n.getPartial(i);return 32===r?t.concat(e):n._shiftRight(e,r,0|i,t.slice(0,t.length-1))},bitLength(t){const e=t.length;if(0===e)return 0;const i=t[e-1];return 32*(e-1)+n.getPartial(i)},clamp(t,e){if(32*t.length<e)return t;const i=(t=t.slice(0,Math.ceil(e/32))).length;return e&=31,i>0&&e&&(t[i-1]=n.partial(e,t[i-1]&2147483648>>e-1,1)),t},partial:(t,e,n)=>32===t?e:(n?0|e:e<<32-t)+1099511627776*t,getPartial:t=>Math.round(t/1099511627776)||32,_shiftRight(t,e,i,r){for(void 0===r&&(r=[]);e>=32;e-=32)r.push(i),i=0;if(0===e)return r.concat(t);for(let n=0;n<t.length;n++)r.push(i|t[n]>>>e),i=t[n]<<32-e;const a=t.length?t[t.length-1]:0,s=n.getPartial(a);return r.push(n.partial(e+s&31,e+s>32?i:r.pop(),1)),r}},i={bytes:{fromBits(t){const e=n.bitLength(t)/8,i=new Uint8Array(e);let r;for(let n=0;n<e;n++)0==(3&n)&&(r=t[n/4]),i[n]=r>>>24,r<<=8;return i},toBits(t){const e=[];let i,r=0;for(i=0;i<t.length;i++)r=r<<8|t[i],3==(3&i)&&(e.push(r),r=0);return 3&i&&e.push(n.partial(8*(3&i),r)),e}}},r={sha1:function(t){t?(this._h=t._h.slice(0),this._buffer=t._buffer.slice(0),this._length=t._length):this.reset()}};r.sha1.prototype={blockSize:512,reset:function(){const t=this;return t._h=this._init.slice(0),t._buffer=[],t._length=0,t},update:function(t){const e=this;"string"==typeof t&&(t=i.utf8String.toBits(t));const r=e._buffer=n.concat(e._buffer,t),a=e._length,s=e._length=a+n.bitLength(t);if(s>9007199254740991)throw new Error("Cannot hash more than 2^53 - 1 bits");const o=new Uint32Array(r);let c=0;for(let t=e.blockSize+a-(e.blockSize+a&e.blockSize-1);t<=s;t+=e.blockSize)e._block(o.subarray(16*c,16*(c+1))),c+=1;return r.splice(0,16*c),e},finalize:function(){const t=this;let e=t._buffer;const i=t._h;e=n.concat(e,[n.partial(1,1)]);for(let t=e.length+2;15&t;t++)e.push(0);for(e.push(Math.floor(t._length/4294967296)),e.push(0|t._length);e.length;)t._block(e.splice(0,16));return t.reset(),i},_init:[1732584193,4023233417,2562383102,271733878,3285377520],_key:[1518500249,1859775393,2400959708,3395469782],_f:function(t,e,n,i){return t<=19?e&n|~e&i:t<=39?e^n^i:t<=59?e&n|e&i|n&i:t<=79?e^n^i:void 0},_S:function(t,e){return e<<t|e>>>32-t},_block:function(t){const e=this,n=e._h,i=Array(80);for(let e=0;e<16;e++)i[e]=t[e];let r=n[0],a=n[1],s=n[2],o=n[3],c=n[4];for(let t=0;t<=79;t++){t>=16&&(i[t]=e._S(1,i[t-3]^i[t-8]^i[t-14]^i[t-16]));const n=e._S(5,r)+e._f(t,a,s,o)+c+i[t]+e._key[Math.floor(t/20)]|0;c=o,o=s,s=e._S(30,a),a=r,r=n}n[0]=n[0]+r|0,n[1]=n[1]+a|0,n[2]=n[2]+s|0,n[3]=n[3]+o|0,n[4]=n[4]+c|0}};const a={name:"PBKDF2"},s=Object.assign({hash:{name:"HMAC"}},a),o=Object.assign({iterations:1e3,hash:{name:"SHA-1"}},a),c=["deriveBits"],l=[8,12,16],d=[16,24,32],u=[0,0,0,0],f=crypto.subtle,h=i.bytes,p=class{constructor(t){const e=this;e._tables=[[[],[],[],[],[]],[[],[],[],[],[]]],e._tables[0][0][0]||e._precompute();const n=e._tables[0][4],i=e._tables[1],r=t.length;let a,s,o,c=1;if(4!==r&&6!==r&&8!==r)throw new Error("invalid aes key size");for(e._key=[s=t.slice(0),o=[]],a=r;a<4*r+28;a++){let t=s[a-1];(a%r==0||8===r&&a%r==4)&&(t=n[t>>>24]<<24^n[t>>16&255]<<16^n[t>>8&255]<<8^n[255&t],a%r==0&&(t=t<<8^t>>>24^c<<24,c=c<<1^283*(c>>7))),s[a]=s[a-r]^t}for(let t=0;a;t++,a--){const e=s[3&t?a:a-4];o[t]=a<=4||t<4?e:i[0][n[e>>>24]]^i[1][n[e>>16&255]]^i[2][n[e>>8&255]]^i[3][n[255&e]]}}encrypt(t){return this._crypt(t,0)}decrypt(t){return this._crypt(t,1)}_precompute(){const t=this._tables[0],e=this._tables[1],n=t[4],i=e[4],r=[],a=[];let s,o,c,l;for(let t=0;t<256;t++)a[(r[t]=t<<1^283*(t>>7))^t]=t;for(let d=s=0;!n[d];d^=o||1,s=a[s]||1){let a=s^s<<1^s<<2^s<<3^s<<4;a=a>>8^255&a^99,n[d]=a,i[a]=d,l=r[c=r[o=r[d]]];let u=16843009*l^65537*c^257*o^16843008*d,f=257*r[a]^16843008*a;for(let n=0;n<4;n++)t[n][d]=f=f<<24^f>>>8,e[n][a]=u=u<<24^u>>>8}for(let n=0;n<5;n++)t[n]=t[n].slice(0),e[n]=e[n].slice(0)}_crypt(t,e){if(4!==t.length)throw new Error("invalid aes block size");const n=this._key[e],i=n.length/4-2,r=[0,0,0,0],a=this._tables[e],s=a[0],o=a[1],c=a[2],l=a[3],d=a[4];let u,f,h,p=t[0]^n[0],_=t[e?3:1]^n[1],w=t[2]^n[2],g=t[e?1:3]^n[3],y=4;for(let t=0;t<i;t++)u=s[p>>>24]^o[_>>16&255]^c[w>>8&255]^l[255&g]^n[y],f=s[_>>>24]^o[w>>16&255]^c[g>>8&255]^l[255&p]^n[y+1],h=s[w>>>24]^o[g>>16&255]^c[p>>8&255]^l[255&_]^n[y+2],g=s[g>>>24]^o[p>>16&255]^c[_>>8&255]^l[255&w]^n[y+3],y+=4,p=u,_=f,w=h;for(let t=0;t<4;t++)r[e?3&-t:t]=d[p>>>24]<<24^d[_>>16&255]<<16^d[w>>8&255]<<8^d[255&g]^n[y++],u=p,p=_,_=w,w=g,g=u;return r}},_=class{constructor(t,e){this._prf=t,this._initIv=e,this._iv=e}reset(){this._iv=this._initIv}update(t){return this.calculate(this._prf,t,this._iv)}incWord(t){if(255==(t>>24&255)){let e=t>>16&255,n=t>>8&255,i=255&t;255===e?(e=0,255===n?(n=0,255===i?i=0:++i):++n):++e,t=0,t+=e<<16,t+=n<<8,t+=i}else t+=1<<24;return t}incCounter(t){0===(t[0]=this.incWord(t[0]))&&(t[1]=this.incWord(t[1]))}calculate(t,e,i){let r;if(!(r=e.length))return[];const a=n.bitLength(e);for(let n=0;n<r;n+=4){this.incCounter(i);const r=t.encrypt(i);e[n]^=r[0],e[n+1]^=r[1],e[n+2]^=r[2],e[n+3]^=r[3]}return n.clamp(e,a)}},w=class{constructor(t){const e=this,n=e._hash=r.sha1,i=[[],[]],a=n.prototype.blockSize/32;e._baseHash=[new n,new n],t.length>a&&(t=n.hash(t));for(let e=0;e<a;e++)i[0][e]=909522486^t[e],i[1][e]=1549556828^t[e];e._baseHash[0].update(i[0]),e._baseHash[1].update(i[1]),e._resultHash=new n(e._baseHash[0])}reset(){const t=this;t._resultHash=new t._hash(t._baseHash[0]),t._updated=!1}update(t){this._updated=!0,this._resultHash.update(t)}digest(){const t=this,e=t._resultHash.finalize(),n=new t._hash(t._baseHash[1]).update(e).finalize();return t.reset(),n}};class g{constructor(t,e,n){Object.assign(this,{password:t,signed:e,strength:n-1,pendingInput:new Uint8Array(0)})}async append(t){const e=this;if(e.password){const n=k(t,0,l[e.strength]+2);await async function(t,e,n){await m(t,n,k(e,0,l[t.strength]));const i=k(e,l[t.strength]),r=t.keys.passwordVerification;if(r[0]!=i[0]||r[1]!=i[1])throw new Error("Invalid pasword")}(e,n,e.password),e.password=null,e.aesCtrGladman=new _(new p(e.keys.key),Array.from(u)),e.hmac=new w(e.keys.authentication),t=k(t,l[e.strength]+2)}return b(e,t,new Uint8Array(t.length-10-(t.length-10)%16),0,10,!0)}async flush(){const t=this,e=t.pendingInput,n=k(e,0,e.length-10),i=k(e,e.length-10);let r=new Uint8Array(0);if(n.length){const e=h.toBits(n);t.hmac.update(e);const i=t.aesCtrGladman.update(e);r=h.fromBits(i)}let a=!0;if(t.signed){const e=k(h.fromBits(t.hmac.digest()),0,10);for(let t=0;t<10;t++)e[t]!=i[t]&&(a=!1)}return{valid:a,data:r}}}class y{constructor(t,e){Object.assign(this,{password:t,strength:e-1,pendingInput:new Uint8Array(0)})}async append(t){const e=this;let n=new Uint8Array(0);e.password&&(n=await async function(t,e){const n=crypto.getRandomValues(new Uint8Array(l[t.strength]));return await m(t,e,n),x(n,t.keys.passwordVerification)}(e,e.password),e.password=null,e.aesCtrGladman=new _(new p(e.keys.key),Array.from(u)),e.hmac=new w(e.keys.authentication));const i=new Uint8Array(n.length+t.length-t.length%16);return i.set(n,0),b(e,t,i,n.length,0)}async flush(){const t=this;let e=new Uint8Array(0);if(t.pendingInput.length){const n=t.aesCtrGladman.update(h.toBits(t.pendingInput));t.hmac.update(n),e=h.fromBits(n)}const n=k(h.fromBits(t.hmac.digest()),0,10);return{data:x(e,n),signature:n}}}function b(t,e,n,i,r,a){const s=e.length-r;let o;for(t.pendingInput.length&&(e=x(t.pendingInput,e),n=function(t,e){if(e&&e>t.length){const n=t;(t=new Uint8Array(e)).set(n,0)}return t}(n,s-s%16)),o=0;o<=s-16;o+=16){const r=h.toBits(k(e,o,o+16));a&&t.hmac.update(r);const s=t.aesCtrGladman.update(r);a||t.hmac.update(s),n.set(h.fromBits(s),o+i)}return t.pendingInput=k(e,o),n}async function m(t,e,n){const i=(new TextEncoder).encode(e),r=await f.importKey("raw",i,s,!1,c),a=await f.deriveBits(Object.assign({salt:n},o),r,8*(2*d[t.strength]+2)),l=new Uint8Array(a);t.keys={key:h.toBits(k(l,0,d[t.strength])),authentication:h.toBits(k(l,d[t.strength],2*d[t.strength])),passwordVerification:k(l,2*d[t.strength])}}function x(t,e){let n=t;return t.length+e.length&&(n=new Uint8Array(t.length+e.length),n.set(t,0),n.set(e,t.length)),n}function k(t,e,n){return t.subarray(e,n)}class v{constructor(t,e){Object.assign(this,{password:t,passwordVerification:e}),R(this,t)}async append(t){const e=this;if(e.password){const n=E(e,t.subarray(0,12));if(e.password=null,n[11]!=e.passwordVerification)throw new Error("Invalid pasword");t=t.subarray(12)}return E(e,t)}async flush(){return{valid:!0,data:new Uint8Array(0)}}}class A{constructor(t,e){Object.assign(this,{password:t,passwordVerification:e}),R(this,t)}async append(t){const e=this;let n,i;if(e.password){e.password=null;const r=crypto.getRandomValues(new Uint8Array(12));r[11]=e.passwordVerification,n=new Uint8Array(t.length+r.length),n.set(U(e,r),0),i=12}else n=new Uint8Array(t.length),i=0;return n.set(U(e,t),i),n}async flush(){return{data:new Uint8Array(0)}}}function E(t,e){const n=new Uint8Array(e.length);for(let i=0;i<e.length;i++)n[i]=z(t)^e[i],D(t,n[i]);return n}function U(t,e){const n=new Uint8Array(e.length);for(let i=0;i<e.length;i++)n[i]=z(t)^e[i],D(t,e[i]);return n}function R(t,n){t.keys=[305419896,591751049,878082192],t.crcKey0=new e(t.keys[0]),t.crcKey2=new e(t.keys[2]);for(let e=0;e<n.length;e++)D(t,n.charCodeAt(e))}function D(t,e){t.crcKey0.append([e]),t.keys[0]=~t.crcKey0.get(),t.keys[1]=F(t.keys[1]+S(t.keys[0])),t.keys[1]=F(Math.imul(t.keys[1],134775813)+1),t.crcKey2.append([t.keys[1]>>>24]),t.keys[2]=~t.crcKey2.get()}function z(t){const e=2|t.keys[2];return S(Math.imul(e,1^e)>>>8)}function S(t){return 255&t}function F(t){return 4294967295&t}class T{constructor(t,{signature:n,password:i,signed:r,compressed:a,zipCrypto:s,passwordVerification:o,encryptionStrength:c},{chunkSize:l}){const d=Boolean(i);Object.assign(this,{signature:n,encrypted:d,signed:r,compressed:a,inflate:a&&new t({chunkSize:l}),crc32:r&&new e,zipCrypto:s,decrypt:d&&s?new v(i,o):new g(i,r,c)})}async append(t){const e=this;return e.encrypted&&t.length&&(t=await e.decrypt.append(t)),e.compressed&&t.length&&(t=await e.inflate.append(t)),(!e.encrypted||e.zipCrypto)&&e.signed&&t.length&&e.crc32.append(t),t}async flush(){const t=this;let e,n=new Uint8Array(0);if(t.encrypted){const e=await t.decrypt.flush();if(!e.valid)throw new Error("Invalid signature");n=e.data}if((!t.encrypted||t.zipCrypto)&&t.signed){const n=new DataView(new Uint8Array(4).buffer);if(e=t.crc32.get(),n.setUint32(0,e),t.signature!=n.getUint32(0,!1))throw new Error("Invalid signature")}return t.compressed&&(n=await t.inflate.append(n)||new Uint8Array(0),await t.inflate.flush()),{data:n,signature:e}}}class C{constructor(t,{encrypted:n,signed:i,compressed:r,level:a,zipCrypto:s,password:o,passwordVerification:c,encryptionStrength:l},{chunkSize:d}){Object.assign(this,{encrypted:n,signed:i,compressed:r,deflate:r&&new t({level:a||5,chunkSize:d}),crc32:i&&new e,zipCrypto:s,encrypt:n&&s?new A(o,c):new y(o,l)})}async append(t){const e=this;let n=t;return e.compressed&&t.length&&(n=await e.deflate.append(t)),e.encrypted&&n.length&&(n=await e.encrypt.append(n)),(!e.encrypted||e.zipCrypto)&&e.signed&&t.length&&e.crc32.append(t),n}async flush(){const t=this;let e,n=new Uint8Array(0);if(t.compressed&&(n=await t.deflate.flush()||new Uint8Array(0)),t.encrypted){n=await t.encrypt.append(n);const i=await t.encrypt.flush();e=i.signature;const r=new Uint8Array(n.length+i.data.length);r.set(n,0),r.set(i.data,n.length),n=r}return t.encrypted&&!t.zipCrypto||!t.signed||(e=t.crc32.get()),{data:n,signature:e}}}const I={init(t){t.scripts&&t.scripts.length&&importScripts.apply(void 0,t.scripts);const e=t.options;let n;self.initCodec&&self.initCodec(),e.codecType.startsWith("deflate")?n=self.Deflate:e.codecType.startsWith("inflate")&&(n=self.Inflate),B=function(t,e,n){return e.codecType.startsWith("deflate")?new C(t,e,n):e.codecType.startsWith("inflate")?new T(t,e,n):void 0}(n,e,t.config)},append:async t=>({data:await B.append(t.data)}),flush:()=>B.flush()};let B;function M(t){return t.map((([t,e])=>new Array(t).fill(e,0,t))).flat()}addEventListener("message",(async t=>{const e=t.data,n=e.type,i=I[n];if(i)try{e.data&&(e.data=new Uint8Array(e.data));const t=await i(e)||{};if(t.type=n,t.data)try{t.data=t.data.buffer,postMessage(t,[t.data])}catch(e){postMessage(t)}else postMessage(t)}catch(t){postMessage({type:n,error:{message:t.message,stack:t.stack}})}}));const O=[0,1,2,3].concat(...M([[2,4],[2,5],[4,6],[4,7],[8,8],[8,9],[16,10],[16,11],[32,12],[32,13],[64,14],[64,15],[2,0],[1,16],[1,17],[2,18],[2,19],[4,20],[4,21],[8,22],[8,23],[16,24],[16,25],[32,26],[32,27],[64,28],[64,29]]));function W(){const t=this;function e(t,e){let n=0;do{n|=1&t,t>>>=1,n<<=1}while(--e>0);return n>>>1}t.build_tree=function(n){const i=t.dyn_tree,r=t.stat_desc.static_tree,a=t.stat_desc.elems;let s,o,c,l=-1;for(n.heap_len=0,n.heap_max=573,s=0;s<a;s++)0!==i[2*s]?(n.heap[++n.heap_len]=l=s,n.depth[s]=0):i[2*s+1]=0;for(;n.heap_len<2;)c=n.heap[++n.heap_len]=l<2?++l:0,i[2*c]=1,n.depth[c]=0,n.opt_len--,r&&(n.static_len-=r[2*c+1]);for(t.max_code=l,s=Math.floor(n.heap_len/2);s>=1;s--)n.pqdownheap(i,s);c=a;do{s=n.heap[1],n.heap[1]=n.heap[n.heap_len--],n.pqdownheap(i,1),o=n.heap[1],n.heap[--n.heap_max]=s,n.heap[--n.heap_max]=o,i[2*c]=i[2*s]+i[2*o],n.depth[c]=Math.max(n.depth[s],n.depth[o])+1,i[2*s+1]=i[2*o+1]=c,n.heap[1]=c++,n.pqdownheap(i,1)}while(n.heap_len>=2);n.heap[--n.heap_max]=n.heap[1],function(e){const n=t.dyn_tree,i=t.stat_desc.static_tree,r=t.stat_desc.extra_bits,a=t.stat_desc.extra_base,s=t.stat_desc.max_length;let o,c,l,d,u,f,h=0;for(d=0;d<=15;d++)e.bl_count[d]=0;for(n[2*e.heap[e.heap_max]+1]=0,o=e.heap_max+1;o<573;o++)c=e.heap[o],d=n[2*n[2*c+1]+1]+1,d>s&&(d=s,h++),n[2*c+1]=d,c>t.max_code||(e.bl_count[d]++,u=0,c>=a&&(u=r[c-a]),f=n[2*c],e.opt_len+=f*(d+u),i&&(e.static_len+=f*(i[2*c+1]+u)));if(0!==h){do{for(d=s-1;0===e.bl_count[d];)d--;e.bl_count[d]--,e.bl_count[d+1]+=2,e.bl_count[s]--,h-=2}while(h>0);for(d=s;0!==d;d--)for(c=e.bl_count[d];0!==c;)l=e.heap[--o],l>t.max_code||(n[2*l+1]!=d&&(e.opt_len+=(d-n[2*l+1])*n[2*l],n[2*l+1]=d),c--)}}(n),function(t,n,i){const r=[];let a,s,o,c=0;for(a=1;a<=15;a++)r[a]=c=c+i[a-1]<<1;for(s=0;s<=n;s++)o=t[2*s+1],0!==o&&(t[2*s]=e(r[o]++,o))}(i,t.max_code,n.bl_count)}}function H(t,e,n,i,r){const a=this;a.static_tree=t,a.extra_bits=e,a.extra_base=n,a.elems=i,a.max_length=r}function N(t,e,n,i,r){const a=this;a.good_length=t,a.max_lazy=e,a.nice_length=n,a.max_chain=i,a.func=r}W._length_code=[0,1,2,3,4,5,6,7].concat(...M([[2,8],[2,9],[2,10],[2,11],[4,12],[4,13],[4,14],[4,15],[8,16],[8,17],[8,18],[8,19],[16,20],[16,21],[16,22],[16,23],[32,24],[32,25],[32,26],[31,27],[1,28]])),W.base_length=[0,1,2,3,4,5,6,7,8,10,12,14,16,20,24,28,32,40,48,56,64,80,96,112,128,160,192,224,0],W.base_dist=[0,1,2,3,4,6,8,12,16,24,32,48,64,96,128,192,256,384,512,768,1024,1536,2048,3072,4096,6144,8192,12288,16384,24576],W.d_code=function(t){return t<256?O[t]:O[256+(t>>>7)]},W.extra_lbits=[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],W.extra_dbits=[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],W.extra_blbits=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],W.bl_order=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],H.static_ltree=[12,8,140,8,76,8,204,8,44,8,172,8,108,8,236,8,28,8,156,8,92,8,220,8,60,8,188,8,124,8,252,8,2,8,130,8,66,8,194,8,34,8,162,8,98,8,226,8,18,8,146,8,82,8,210,8,50,8,178,8,114,8,242,8,10,8,138,8,74,8,202,8,42,8,170,8,106,8,234,8,26,8,154,8,90,8,218,8,58,8,186,8,122,8,250,8,6,8,134,8,70,8,198,8,38,8,166,8,102,8,230,8,22,8,150,8,86,8,214,8,54,8,182,8,118,8,246,8,14,8,142,8,78,8,206,8,46,8,174,8,110,8,238,8,30,8,158,8,94,8,222,8,62,8,190,8,126,8,254,8,1,8,129,8,65,8,193,8,33,8,161,8,97,8,225,8,17,8,145,8,81,8,209,8,49,8,177,8,113,8,241,8,9,8,137,8,73,8,201,8,41,8,169,8,105,8,233,8,25,8,153,8,89,8,217,8,57,8,185,8,121,8,249,8,5,8,133,8,69,8,197,8,37,8,165,8,101,8,229,8,21,8,149,8,85,8,213,8,53,8,181,8,117,8,245,8,13,8,141,8,77,8,205,8,45,8,173,8,109,8,237,8,29,8,157,8,93,8,221,8,61,8,189,8,125,8,253,8,19,9,275,9,147,9,403,9,83,9,339,9,211,9,467,9,51,9,307,9,179,9,435,9,115,9,371,9,243,9,499,9,11,9,267,9,139,9,395,9,75,9,331,9,203,9,459,9,43,9,299,9,171,9,427,9,107,9,363,9,235,9,491,9,27,9,283,9,155,9,411,9,91,9,347,9,219,9,475,9,59,9,315,9,187,9,443,9,123,9,379,9,251,9,507,9,7,9,263,9,135,9,391,9,71,9,327,9,199,9,455,9,39,9,295,9,167,9,423,9,103,9,359,9,231,9,487,9,23,9,279,9,151,9,407,9,87,9,343,9,215,9,471,9,55,9,311,9,183,9,439,9,119,9,375,9,247,9,503,9,15,9,271,9,143,9,399,9,79,9,335,9,207,9,463,9,47,9,303,9,175,9,431,9,111,9,367,9,239,9,495,9,31,9,287,9,159,9,415,9,95,9,351,9,223,9,479,9,63,9,319,9,191,9,447,9,127,9,383,9,255,9,511,9,0,7,64,7,32,7,96,7,16,7,80,7,48,7,112,7,8,7,72,7,40,7,104,7,24,7,88,7,56,7,120,7,4,7,68,7,36,7,100,7,20,7,84,7,52,7,116,7,3,8,131,8,67,8,195,8,35,8,163,8,99,8,227,8],H.static_dtree=[0,5,16,5,8,5,24,5,4,5,20,5,12,5,28,5,2,5,18,5,10,5,26,5,6,5,22,5,14,5,30,5,1,5,17,5,9,5,25,5,5,5,21,5,13,5,29,5,3,5,19,5,11,5,27,5,7,5,23,5],H.static_l_desc=new H(H.static_ltree,W.extra_lbits,257,286,15),H.static_d_desc=new H(H.static_dtree,W.extra_dbits,0,30,15),H.static_bl_desc=new H(null,W.extra_blbits,0,19,7);const L=[new N(0,0,0,0,0),new N(4,4,8,4,1),new N(4,5,16,8,1),new N(4,6,32,32,1),new N(4,4,16,16,2),new N(8,16,32,32,2),new N(8,16,128,128,2),new N(8,32,128,256,2),new N(32,128,258,1024,2),new N(32,258,258,4096,2)],j=["need dictionary","stream end","","","stream error","data error","","buffer error","",""];function P(t,e,n,i){const r=t[2*e],a=t[2*n];return r<a||r==a&&i[e]<=i[n]}function V(){const t=this;let e,n,i,r,a,s,o,c,l,d,u,f,h,p,_,w,g,y,b,m,x,k,v,A,E,U,R,D,z,S,F,T,C;const I=new W,B=new W,M=new W;let O,N,V,Z,q,K,G,Y;function X(){let e;for(e=0;e<286;e++)F[2*e]=0;for(e=0;e<30;e++)T[2*e]=0;for(e=0;e<19;e++)C[2*e]=0;F[512]=1,t.opt_len=t.static_len=0,V=q=0}function J(t,e){let n,i=-1,r=t[1],a=0,s=7,o=4;0===r&&(s=138,o=3),t[2*(e+1)+1]=65535;for(let c=0;c<=e;c++)n=r,r=t[2*(c+1)+1],++a<s&&n==r||(a<o?C[2*n]+=a:0!==n?(n!=i&&C[2*n]++,C[32]++):a<=10?C[34]++:C[36]++,a=0,i=n,0===r?(s=138,o=3):n==r?(s=6,o=3):(s=7,o=4))}function Q(e){t.pending_buf[t.pending++]=e}function $(t){Q(255&t),Q(t>>>8&255)}function tt(t,e){let n;const i=e;Y>16-i?(n=t,G|=n<<Y&65535,$(G),G=n>>>16-Y,Y+=i-16):(G|=t<<Y&65535,Y+=i)}function et(t,e){const n=2*t;tt(65535&e[n],65535&e[n+1])}function nt(t,e){let n,i,r=-1,a=t[1],s=0,o=7,c=4;for(0===a&&(o=138,c=3),n=0;n<=e;n++)if(i=a,a=t[2*(n+1)+1],!(++s<o&&i==a)){if(s<c)do{et(i,C)}while(0!=--s);else 0!==i?(i!=r&&(et(i,C),s--),et(16,C),tt(s-3,2)):s<=10?(et(17,C),tt(s-3,3)):(et(18,C),tt(s-11,7));s=0,r=i,0===a?(o=138,c=3):i==a?(o=6,c=3):(o=7,c=4)}}function it(){16==Y?($(G),G=0,Y=0):Y>=8&&(Q(255&G),G>>>=8,Y-=8)}function rt(e,n){let i,r,a;if(t.pending_buf[Z+2*V]=e>>>8&255,t.pending_buf[Z+2*V+1]=255&e,t.pending_buf[O+V]=255&n,V++,0===e?F[2*n]++:(q++,e--,F[2*(W._length_code[n]+256+1)]++,T[2*W.d_code(e)]++),0==(8191&V)&&R>2){for(i=8*V,r=x-g,a=0;a<30;a++)i+=T[2*a]*(5+W.extra_dbits[a]);if(i>>>=3,q<Math.floor(V/2)&&i<Math.floor(r/2))return!0}return V==N-1}function at(e,n){let i,r,a,s,o=0;if(0!==V)do{i=t.pending_buf[Z+2*o]<<8&65280|255&t.pending_buf[Z+2*o+1],r=255&t.pending_buf[O+o],o++,0===i?et(r,e):(a=W._length_code[r],et(a+256+1,e),s=W.extra_lbits[a],0!==s&&(r-=W.base_length[a],tt(r,s)),i--,a=W.d_code(i),et(a,n),s=W.extra_dbits[a],0!==s&&(i-=W.base_dist[a],tt(i,s)))}while(o<V);et(256,e),K=e[513]}function st(){Y>8?$(G):Y>0&&Q(255&G),G=0,Y=0}function ot(e,n,i){tt(0+(i?1:0),3),function(e,n,i){st(),K=8,$(n),$(~n),t.pending_buf.set(c.subarray(e,e+n),t.pending),t.pending+=n}(e,n)}function ct(e,n,i){let r,a,s=0;R>0?(I.build_tree(t),B.build_tree(t),s=function(){let e;for(J(F,I.max_code),J(T,B.max_code),M.build_tree(t),e=18;e>=3&&0===C[2*W.bl_order[e]+1];e--);return t.opt_len+=3*(e+1)+5+5+4,e}(),r=t.opt_len+3+7>>>3,a=t.static_len+3+7>>>3,a<=r&&(r=a)):r=a=n+5,n+4<=r&&-1!=e?ot(e,n,i):a==r?(tt(2+(i?1:0),3),at(H.static_ltree,H.static_dtree)):(tt(4+(i?1:0),3),function(t,e,n){let i;for(tt(t-257,5),tt(e-1,5),tt(n-4,4),i=0;i<n;i++)tt(C[2*W.bl_order[i]+1],3);nt(F,t-1),nt(T,e-1)}(I.max_code+1,B.max_code+1,s+1),at(F,T)),X(),i&&st()}function lt(t){ct(g>=0?g:-1,x-g,t),g=x,e.flush_pending()}function dt(){let t,n,i,r;do{if(r=l-v-x,0===r&&0===x&&0===v)r=a;else if(-1==r)r--;else if(x>=a+a-262){c.set(c.subarray(a,a+a),0),k-=a,x-=a,g-=a,t=h,i=t;do{n=65535&u[--i],u[i]=n>=a?n-a:0}while(0!=--t);t=a,i=t;do{n=65535&d[--i],d[i]=n>=a?n-a:0}while(0!=--t);r+=a}if(0===e.avail_in)return;t=e.read_buf(c,x+v,r),v+=t,v>=3&&(f=255&c[x],f=(f<<w^255&c[x+1])&_)}while(v<262&&0!==e.avail_in)}function ut(t){let e,n,i=E,r=x,s=A;const l=x>a-262?x-(a-262):0;let u=S;const f=o,h=x+258;let p=c[r+s-1],_=c[r+s];A>=z&&(i>>=2),u>v&&(u=v);do{if(e=t,c[e+s]==_&&c[e+s-1]==p&&c[e]==c[r]&&c[++e]==c[r+1]){r+=2,e++;do{}while(c[++r]==c[++e]&&c[++r]==c[++e]&&c[++r]==c[++e]&&c[++r]==c[++e]&&c[++r]==c[++e]&&c[++r]==c[++e]&&c[++r]==c[++e]&&c[++r]==c[++e]&&r<h);if(n=258-(h-r),r=h-258,n>s){if(k=t,s=n,n>=u)break;p=c[r+s-1],_=c[r+s]}}}while((t=65535&d[t&f])>l&&0!=--i);return s<=v?s:v}function ft(e){return e.total_in=e.total_out=0,e.msg=null,t.pending=0,t.pending_out=0,n=113,r=0,I.dyn_tree=F,I.stat_desc=H.static_l_desc,B.dyn_tree=T,B.stat_desc=H.static_d_desc,M.dyn_tree=C,M.stat_desc=H.static_bl_desc,G=0,Y=0,K=8,X(),function(){l=2*a,u[h-1]=0;for(let t=0;t<h-1;t++)u[t]=0;U=L[R].max_lazy,z=L[R].good_length,S=L[R].nice_length,E=L[R].max_chain,x=0,g=0,v=0,y=A=2,m=0,f=0}(),0}t.depth=[],t.bl_count=[],t.heap=[],F=[],T=[],C=[],t.pqdownheap=function(e,n){const i=t.heap,r=i[n];let a=n<<1;for(;a<=t.heap_len&&(a<t.heap_len&&P(e,i[a+1],i[a],t.depth)&&a++,!P(e,r,i[a],t.depth));)i[n]=i[a],n=a,a<<=1;i[n]=r},t.deflateInit=function(e,n,r,l,f,g){return l||(l=8),f||(f=8),g||(g=0),e.msg=null,-1==n&&(n=6),f<1||f>9||8!=l||r<9||r>15||n<0||n>9||g<0||g>2?-2:(e.dstate=t,s=r,a=1<<s,o=a-1,p=f+7,h=1<<p,_=h-1,w=Math.floor((p+3-1)/3),c=new Uint8Array(2*a),d=[],u=[],N=1<<f+6,t.pending_buf=new Uint8Array(4*N),i=4*N,Z=Math.floor(N/2),O=3*N,R=n,D=g,ft(e))},t.deflateEnd=function(){return 42!=n&&113!=n&&666!=n?-2:(t.pending_buf=null,u=null,d=null,c=null,t.dstate=null,113==n?-3:0)},t.deflateParams=function(t,e,n){let i=0;return-1==e&&(e=6),e<0||e>9||n<0||n>2?-2:(L[R].func!=L[e].func&&0!==t.total_in&&(i=t.deflate(1)),R!=e&&(R=e,U=L[R].max_lazy,z=L[R].good_length,S=L[R].nice_length,E=L[R].max_chain),D=n,i)},t.deflateSetDictionary=function(t,e,i){let r,s=i,l=0;if(!e||42!=n)return-2;if(s<3)return 0;for(s>a-262&&(s=a-262,l=i-s),c.set(e.subarray(l,l+s),0),x=s,g=s,f=255&c[0],f=(f<<w^255&c[1])&_,r=0;r<=s-3;r++)f=(f<<w^255&c[r+2])&_,d[r&o]=u[f],u[f]=r;return 0},t.deflate=function(l,p){let E,z,S,F,T;if(p>4||p<0)return-2;if(!l.next_out||!l.next_in&&0!==l.avail_in||666==n&&4!=p)return l.msg=j[4],-2;if(0===l.avail_out)return l.msg=j[7],-5;var C;if(e=l,F=r,r=p,42==n&&(z=8+(s-8<<4)<<8,S=(R-1&255)>>1,S>3&&(S=3),z|=S<<6,0!==x&&(z|=32),z+=31-z%31,n=113,Q((C=z)>>8&255),Q(255&C)),0!==t.pending){if(e.flush_pending(),0===e.avail_out)return r=-1,0}else if(0===e.avail_in&&p<=F&&4!=p)return e.msg=j[7],-5;if(666==n&&0!==e.avail_in)return l.msg=j[7],-5;if(0!==e.avail_in||0!==v||0!=p&&666!=n){switch(T=-1,L[R].func){case 0:T=function(t){let n,r=65535;for(r>i-5&&(r=i-5);;){if(v<=1){if(dt(),0===v&&0==t)return 0;if(0===v)break}if(x+=v,v=0,n=g+r,(0===x||x>=n)&&(v=x-n,x=n,lt(!1),0===e.avail_out))return 0;if(x-g>=a-262&&(lt(!1),0===e.avail_out))return 0}return lt(4==t),0===e.avail_out?4==t?2:0:4==t?3:1}(p);break;case 1:T=function(t){let n,i=0;for(;;){if(v<262){if(dt(),v<262&&0==t)return 0;if(0===v)break}if(v>=3&&(f=(f<<w^255&c[x+2])&_,i=65535&u[f],d[x&o]=u[f],u[f]=x),0!==i&&(x-i&65535)<=a-262&&2!=D&&(y=ut(i)),y>=3)if(n=rt(x-k,y-3),v-=y,y<=U&&v>=3){y--;do{x++,f=(f<<w^255&c[x+2])&_,i=65535&u[f],d[x&o]=u[f],u[f]=x}while(0!=--y);x++}else x+=y,y=0,f=255&c[x],f=(f<<w^255&c[x+1])&_;else n=rt(0,255&c[x]),v--,x++;if(n&&(lt(!1),0===e.avail_out))return 0}return lt(4==t),0===e.avail_out?4==t?2:0:4==t?3:1}(p);break;case 2:T=function(t){let n,i,r=0;for(;;){if(v<262){if(dt(),v<262&&0==t)return 0;if(0===v)break}if(v>=3&&(f=(f<<w^255&c[x+2])&_,r=65535&u[f],d[x&o]=u[f],u[f]=x),A=y,b=k,y=2,0!==r&&A<U&&(x-r&65535)<=a-262&&(2!=D&&(y=ut(r)),y<=5&&(1==D||3==y&&x-k>4096)&&(y=2)),A>=3&&y<=A){i=x+v-3,n=rt(x-1-b,A-3),v-=A-1,A-=2;do{++x<=i&&(f=(f<<w^255&c[x+2])&_,r=65535&u[f],d[x&o]=u[f],u[f]=x)}while(0!=--A);if(m=0,y=2,x++,n&&(lt(!1),0===e.avail_out))return 0}else if(0!==m){if(n=rt(0,255&c[x-1]),n&&lt(!1),x++,v--,0===e.avail_out)return 0}else m=1,x++,v--}return 0!==m&&(n=rt(0,255&c[x-1]),m=0),lt(4==t),0===e.avail_out?4==t?2:0:4==t?3:1}(p)}if(2!=T&&3!=T||(n=666),0==T||2==T)return 0===e.avail_out&&(r=-1),0;if(1==T){if(1==p)tt(2,3),et(256,H.static_ltree),it(),1+K+10-Y<9&&(tt(2,3),et(256,H.static_ltree),it()),K=7;else if(ot(0,0,!1),3==p)for(E=0;E<h;E++)u[E]=0;if(e.flush_pending(),0===e.avail_out)return r=-1,0}}return 4!=p?0:1}}function Z(){const t=this;t.next_in_index=0,t.next_out_index=0,t.avail_in=0,t.total_in=0,t.avail_out=0,t.total_out=0}function q(t){const e=new Z,n=(i=t&&t.chunkSize?t.chunkSize:65536)+5*(Math.floor(i/16383)+1);var i;const r=new Uint8Array(n);let a=t?t.level:-1;void 0===a&&(a=-1),e.deflateInit(a),e.next_out=r,this.append=function(t,i){let a,s,o=0,c=0,l=0;const d=[];if(t.length){e.next_in_index=0,e.next_in=t,e.avail_in=t.length;do{if(e.next_out_index=0,e.avail_out=n,a=e.deflate(0),0!=a)throw new Error("deflating: "+e.msg);e.next_out_index&&(e.next_out_index==n?d.push(new Uint8Array(r)):d.push(r.slice(0,e.next_out_index))),l+=e.next_out_index,i&&e.next_in_index>0&&e.next_in_index!=o&&(i(e.next_in_index),o=e.next_in_index)}while(e.avail_in>0||0===e.avail_out);return d.length>1?(s=new Uint8Array(l),d.forEach((function(t){s.set(t,c),c+=t.length}))):s=d[0]||new Uint8Array(0),s}},this.flush=function(){let t,i,a=0,s=0;const o=[];do{if(e.next_out_index=0,e.avail_out=n,t=e.deflate(4),1!=t&&0!=t)throw new Error("deflating: "+e.msg);n-e.avail_out>0&&o.push(r.slice(0,e.next_out_index)),s+=e.next_out_index}while(e.avail_in>0||0===e.avail_out);return e.deflateEnd(),i=new Uint8Array(s),o.forEach((function(t){i.set(t,a),a+=t.length})),i}}Z.prototype={deflateInit:function(t,e){const n=this;return n.dstate=new V,e||(e=15),n.dstate.deflateInit(n,t,e)},deflate:function(t){const e=this;return e.dstate?e.dstate.deflate(e,t):-2},deflateEnd:function(){const t=this;if(!t.dstate)return-2;const e=t.dstate.deflateEnd();return t.dstate=null,e},deflateParams:function(t,e){const n=this;return n.dstate?n.dstate.deflateParams(n,t,e):-2},deflateSetDictionary:function(t,e){const n=this;return n.dstate?n.dstate.deflateSetDictionary(n,t,e):-2},read_buf:function(t,e,n){const i=this;let r=i.avail_in;return r>n&&(r=n),0===r?0:(i.avail_in-=r,t.set(i.next_in.subarray(i.next_in_index,i.next_in_index+r),e),i.next_in_index+=r,i.total_in+=r,r)},flush_pending:function(){const t=this;let e=t.dstate.pending;e>t.avail_out&&(e=t.avail_out),0!==e&&(t.next_out.set(t.dstate.pending_buf.subarray(t.dstate.pending_out,t.dstate.pending_out+e),t.next_out_index),t.next_out_index+=e,t.dstate.pending_out+=e,t.total_out+=e,t.avail_out-=e,t.dstate.pending-=e,0===t.dstate.pending&&(t.dstate.pending_out=0))}};const K=[0,1,3,7,15,31,63,127,255,511,1023,2047,4095,8191,16383,32767,65535],G=[96,7,256,0,8,80,0,8,16,84,8,115,82,7,31,0,8,112,0,8,48,0,9,192,80,7,10,0,8,96,0,8,32,0,9,160,0,8,0,0,8,128,0,8,64,0,9,224,80,7,6,0,8,88,0,8,24,0,9,144,83,7,59,0,8,120,0,8,56,0,9,208,81,7,17,0,8,104,0,8,40,0,9,176,0,8,8,0,8,136,0,8,72,0,9,240,80,7,4,0,8,84,0,8,20,85,8,227,83,7,43,0,8,116,0,8,52,0,9,200,81,7,13,0,8,100,0,8,36,0,9,168,0,8,4,0,8,132,0,8,68,0,9,232,80,7,8,0,8,92,0,8,28,0,9,152,84,7,83,0,8,124,0,8,60,0,9,216,82,7,23,0,8,108,0,8,44,0,9,184,0,8,12,0,8,140,0,8,76,0,9,248,80,7,3,0,8,82,0,8,18,85,8,163,83,7,35,0,8,114,0,8,50,0,9,196,81,7,11,0,8,98,0,8,34,0,9,164,0,8,2,0,8,130,0,8,66,0,9,228,80,7,7,0,8,90,0,8,26,0,9,148,84,7,67,0,8,122,0,8,58,0,9,212,82,7,19,0,8,106,0,8,42,0,9,180,0,8,10,0,8,138,0,8,74,0,9,244,80,7,5,0,8,86,0,8,22,192,8,0,83,7,51,0,8,118,0,8,54,0,9,204,81,7,15,0,8,102,0,8,38,0,9,172,0,8,6,0,8,134,0,8,70,0,9,236,80,7,9,0,8,94,0,8,30,0,9,156,84,7,99,0,8,126,0,8,62,0,9,220,82,7,27,0,8,110,0,8,46,0,9,188,0,8,14,0,8,142,0,8,78,0,9,252,96,7,256,0,8,81,0,8,17,85,8,131,82,7,31,0,8,113,0,8,49,0,9,194,80,7,10,0,8,97,0,8,33,0,9,162,0,8,1,0,8,129,0,8,65,0,9,226,80,7,6,0,8,89,0,8,25,0,9,146,83,7,59,0,8,121,0,8,57,0,9,210,81,7,17,0,8,105,0,8,41,0,9,178,0,8,9,0,8,137,0,8,73,0,9,242,80,7,4,0,8,85,0,8,21,80,8,258,83,7,43,0,8,117,0,8,53,0,9,202,81,7,13,0,8,101,0,8,37,0,9,170,0,8,5,0,8,133,0,8,69,0,9,234,80,7,8,0,8,93,0,8,29,0,9,154,84,7,83,0,8,125,0,8,61,0,9,218,82,7,23,0,8,109,0,8,45,0,9,186,0,8,13,0,8,141,0,8,77,0,9,250,80,7,3,0,8,83,0,8,19,85,8,195,83,7,35,0,8,115,0,8,51,0,9,198,81,7,11,0,8,99,0,8,35,0,9,166,0,8,3,0,8,131,0,8,67,0,9,230,80,7,7,0,8,91,0,8,27,0,9,150,84,7,67,0,8,123,0,8,59,0,9,214,82,7,19,0,8,107,0,8,43,0,9,182,0,8,11,0,8,139,0,8,75,0,9,246,80,7,5,0,8,87,0,8,23,192,8,0,83,7,51,0,8,119,0,8,55,0,9,206,81,7,15,0,8,103,0,8,39,0,9,174,0,8,7,0,8,135,0,8,71,0,9,238,80,7,9,0,8,95,0,8,31,0,9,158,84,7,99,0,8,127,0,8,63,0,9,222,82,7,27,0,8,111,0,8,47,0,9,190,0,8,15,0,8,143,0,8,79,0,9,254,96,7,256,0,8,80,0,8,16,84,8,115,82,7,31,0,8,112,0,8,48,0,9,193,80,7,10,0,8,96,0,8,32,0,9,161,0,8,0,0,8,128,0,8,64,0,9,225,80,7,6,0,8,88,0,8,24,0,9,145,83,7,59,0,8,120,0,8,56,0,9,209,81,7,17,0,8,104,0,8,40,0,9,177,0,8,8,0,8,136,0,8,72,0,9,241,80,7,4,0,8,84,0,8,20,85,8,227,83,7,43,0,8,116,0,8,52,0,9,201,81,7,13,0,8,100,0,8,36,0,9,169,0,8,4,0,8,132,0,8,68,0,9,233,80,7,8,0,8,92,0,8,28,0,9,153,84,7,83,0,8,124,0,8,60,0,9,217,82,7,23,0,8,108,0,8,44,0,9,185,0,8,12,0,8,140,0,8,76,0,9,249,80,7,3,0,8,82,0,8,18,85,8,163,83,7,35,0,8,114,0,8,50,0,9,197,81,7,11,0,8,98,0,8,34,0,9,165,0,8,2,0,8,130,0,8,66,0,9,229,80,7,7,0,8,90,0,8,26,0,9,149,84,7,67,0,8,122,0,8,58,0,9,213,82,7,19,0,8,106,0,8,42,0,9,181,0,8,10,0,8,138,0,8,74,0,9,245,80,7,5,0,8,86,0,8,22,192,8,0,83,7,51,0,8,118,0,8,54,0,9,205,81,7,15,0,8,102,0,8,38,0,9,173,0,8,6,0,8,134,0,8,70,0,9,237,80,7,9,0,8,94,0,8,30,0,9,157,84,7,99,0,8,126,0,8,62,0,9,221,82,7,27,0,8,110,0,8,46,0,9,189,0,8,14,0,8,142,0,8,78,0,9,253,96,7,256,0,8,81,0,8,17,85,8,131,82,7,31,0,8,113,0,8,49,0,9,195,80,7,10,0,8,97,0,8,33,0,9,163,0,8,1,0,8,129,0,8,65,0,9,227,80,7,6,0,8,89,0,8,25,0,9,147,83,7,59,0,8,121,0,8,57,0,9,211,81,7,17,0,8,105,0,8,41,0,9,179,0,8,9,0,8,137,0,8,73,0,9,243,80,7,4,0,8,85,0,8,21,80,8,258,83,7,43,0,8,117,0,8,53,0,9,203,81,7,13,0,8,101,0,8,37,0,9,171,0,8,5,0,8,133,0,8,69,0,9,235,80,7,8,0,8,93,0,8,29,0,9,155,84,7,83,0,8,125,0,8,61,0,9,219,82,7,23,0,8,109,0,8,45,0,9,187,0,8,13,0,8,141,0,8,77,0,9,251,80,7,3,0,8,83,0,8,19,85,8,195,83,7,35,0,8,115,0,8,51,0,9,199,81,7,11,0,8,99,0,8,35,0,9,167,0,8,3,0,8,131,0,8,67,0,9,231,80,7,7,0,8,91,0,8,27,0,9,151,84,7,67,0,8,123,0,8,59,0,9,215,82,7,19,0,8,107,0,8,43,0,9,183,0,8,11,0,8,139,0,8,75,0,9,247,80,7,5,0,8,87,0,8,23,192,8,0,83,7,51,0,8,119,0,8,55,0,9,207,81,7,15,0,8,103,0,8,39,0,9,175,0,8,7,0,8,135,0,8,71,0,9,239,80,7,9,0,8,95,0,8,31,0,9,159,84,7,99,0,8,127,0,8,63,0,9,223,82,7,27,0,8,111,0,8,47,0,9,191,0,8,15,0,8,143,0,8,79,0,9,255],Y=[80,5,1,87,5,257,83,5,17,91,5,4097,81,5,5,89,5,1025,85,5,65,93,5,16385,80,5,3,88,5,513,84,5,33,92,5,8193,82,5,9,90,5,2049,86,5,129,192,5,24577,80,5,2,87,5,385,83,5,25,91,5,6145,81,5,7,89,5,1537,85,5,97,93,5,24577,80,5,4,88,5,769,84,5,49,92,5,12289,82,5,13,90,5,3073,86,5,193,192,5,24577],X=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],J=[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,112,112],Q=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577],$=[0,0,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];function tt(){let t,e,n,i,r,a;function s(t,e,s,o,c,l,d,u,f,h,p){let _,w,g,y,b,m,x,k,v,A,E,U,R,D,z;A=0,b=s;do{n[t[e+A]]++,A++,b--}while(0!==b);if(n[0]==s)return d[0]=-1,u[0]=0,0;for(k=u[0],m=1;m<=15&&0===n[m];m++);for(x=m,k<m&&(k=m),b=15;0!==b&&0===n[b];b--);for(g=b,k>b&&(k=b),u[0]=k,D=1<<m;m<b;m++,D<<=1)if((D-=n[m])<0)return-3;if((D-=n[b])<0)return-3;for(n[b]+=D,a[1]=m=0,A=1,R=2;0!=--b;)a[R]=m+=n[A],R++,A++;b=0,A=0;do{0!==(m=t[e+A])&&(p[a[m]++]=b),A++}while(++b<s);for(s=a[g],a[0]=b=0,A=0,y=-1,U=-k,r[0]=0,E=0,z=0;x<=g;x++)for(_=n[x];0!=_--;){for(;x>U+k;){if(y++,U+=k,z=g-U,z=z>k?k:z,(w=1<<(m=x-U))>_+1&&(w-=_+1,R=x,m<z))for(;++m<z&&!((w<<=1)<=n[++R]);)w-=n[R];if(z=1<<m,h[0]+z>1440)return-3;r[y]=E=h[0],h[0]+=z,0!==y?(a[y]=b,i[0]=m,i[1]=k,m=b>>>U-k,i[2]=E-r[y-1]-m,f.set(i,3*(r[y-1]+m))):d[0]=E}for(i[1]=x-U,A>=s?i[0]=192:p[A]<o?(i[0]=p[A]<256?0:96,i[2]=p[A++]):(i[0]=l[p[A]-o]+16+64,i[2]=c[p[A++]-o]),w=1<<x-U,m=b>>>U;m<z;m+=w)f.set(i,3*(E+m));for(m=1<<x-1;0!=(b&m);m>>>=1)b^=m;for(b^=m,v=(1<<U)-1;(b&v)!=a[y];)y--,U-=k,v=(1<<U)-1}return 0!==D&&1!=g?-5:0}function o(s){let o;for(t||(t=[],e=[],n=new Int32Array(16),i=[],r=new Int32Array(15),a=new Int32Array(16)),e.length<s&&(e=[]),o=0;o<s;o++)e[o]=0;for(o=0;o<16;o++)n[o]=0;for(o=0;o<3;o++)i[o]=0;r.set(n.subarray(0,15),0),a.set(n.subarray(0,16),0)}this.inflate_trees_bits=function(n,i,r,a,c){let l;return o(19),t[0]=0,l=s(n,0,19,19,null,null,r,i,a,t,e),-3==l?c.msg="oversubscribed dynamic bit lengths tree":-5!=l&&0!==i[0]||(c.msg="incomplete dynamic bit lengths tree",l=-3),l},this.inflate_trees_dynamic=function(n,i,r,a,c,l,d,u,f){let h;return o(288),t[0]=0,h=s(r,0,n,257,X,J,l,a,u,t,e),0!=h||0===a[0]?(-3==h?f.msg="oversubscribed literal/length tree":-4!=h&&(f.msg="incomplete literal/length tree",h=-3),h):(o(288),h=s(r,n,i,0,Q,$,d,c,u,t,e),0!=h||0===c[0]&&n>257?(-3==h?f.msg="oversubscribed distance tree":-5==h?(f.msg="incomplete distance tree",h=-3):-4!=h&&(f.msg="empty distance tree with lengths",h=-3),h):0)}}function et(){const t=this;let e,n,i,r,a=0,s=0,o=0,c=0,l=0,d=0,u=0,f=0,h=0,p=0;function _(t,e,n,i,r,a,s,o){let c,l,d,u,f,h,p,_,w,g,y,b,m,x,k,v;p=o.next_in_index,_=o.avail_in,f=s.bitb,h=s.bitk,w=s.write,g=w<s.read?s.read-w-1:s.end-w,y=K[t],b=K[e];do{for(;h<20;)_--,f|=(255&o.read_byte(p++))<<h,h+=8;if(c=f&y,l=n,d=i,v=3*(d+c),0!==(u=l[v]))for(;;){if(f>>=l[v+1],h-=l[v+1],0!=(16&u)){for(u&=15,m=l[v+2]+(f&K[u]),f>>=u,h-=u;h<15;)_--,f|=(255&o.read_byte(p++))<<h,h+=8;for(c=f&b,l=r,d=a,v=3*(d+c),u=l[v];;){if(f>>=l[v+1],h-=l[v+1],0!=(16&u)){for(u&=15;h<u;)_--,f|=(255&o.read_byte(p++))<<h,h+=8;if(x=l[v+2]+(f&K[u]),f>>=u,h-=u,g-=m,w>=x)k=w-x,w-k>0&&2>w-k?(s.window[w++]=s.window[k++],s.window[w++]=s.window[k++],m-=2):(s.window.set(s.window.subarray(k,k+2),w),w+=2,k+=2,m-=2);else{k=w-x;do{k+=s.end}while(k<0);if(u=s.end-k,m>u){if(m-=u,w-k>0&&u>w-k)do{s.window[w++]=s.window[k++]}while(0!=--u);else s.window.set(s.window.subarray(k,k+u),w),w+=u,k+=u,u=0;k=0}}if(w-k>0&&m>w-k)do{s.window[w++]=s.window[k++]}while(0!=--m);else s.window.set(s.window.subarray(k,k+m),w),w+=m,k+=m,m=0;break}if(0!=(64&u))return o.msg="invalid distance code",m=o.avail_in-_,m=h>>3<m?h>>3:m,_+=m,p-=m,h-=m<<3,s.bitb=f,s.bitk=h,o.avail_in=_,o.total_in+=p-o.next_in_index,o.next_in_index=p,s.write=w,-3;c+=l[v+2],c+=f&K[u],v=3*(d+c),u=l[v]}break}if(0!=(64&u))return 0!=(32&u)?(m=o.avail_in-_,m=h>>3<m?h>>3:m,_+=m,p-=m,h-=m<<3,s.bitb=f,s.bitk=h,o.avail_in=_,o.total_in+=p-o.next_in_index,o.next_in_index=p,s.write=w,1):(o.msg="invalid literal/length code",m=o.avail_in-_,m=h>>3<m?h>>3:m,_+=m,p-=m,h-=m<<3,s.bitb=f,s.bitk=h,o.avail_in=_,o.total_in+=p-o.next_in_index,o.next_in_index=p,s.write=w,-3);if(c+=l[v+2],c+=f&K[u],v=3*(d+c),0===(u=l[v])){f>>=l[v+1],h-=l[v+1],s.window[w++]=l[v+2],g--;break}}else f>>=l[v+1],h-=l[v+1],s.window[w++]=l[v+2],g--}while(g>=258&&_>=10);return m=o.avail_in-_,m=h>>3<m?h>>3:m,_+=m,p-=m,h-=m<<3,s.bitb=f,s.bitk=h,o.avail_in=_,o.total_in+=p-o.next_in_index,o.next_in_index=p,s.write=w,0}t.init=function(t,a,s,o,c,l){e=0,u=t,f=a,i=s,h=o,r=c,p=l,n=null},t.proc=function(t,w,g){let y,b,m,x,k,v,A,E=0,U=0,R=0;for(R=w.next_in_index,x=w.avail_in,E=t.bitb,U=t.bitk,k=t.write,v=k<t.read?t.read-k-1:t.end-k;;)switch(e){case 0:if(v>=258&&x>=10&&(t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,g=_(u,f,i,h,r,p,t,w),R=w.next_in_index,x=w.avail_in,E=t.bitb,U=t.bitk,k=t.write,v=k<t.read?t.read-k-1:t.end-k,0!=g)){e=1==g?7:9;break}o=u,n=i,s=h,e=1;case 1:for(y=o;U<y;){if(0===x)return t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);g=0,x--,E|=(255&w.read_byte(R++))<<U,U+=8}if(b=3*(s+(E&K[y])),E>>>=n[b+1],U-=n[b+1],m=n[b],0===m){c=n[b+2],e=6;break}if(0!=(16&m)){l=15&m,a=n[b+2],e=2;break}if(0==(64&m)){o=m,s=b/3+n[b+2];break}if(0!=(32&m)){e=7;break}return e=9,w.msg="invalid literal/length code",g=-3,t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);case 2:for(y=l;U<y;){if(0===x)return t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);g=0,x--,E|=(255&w.read_byte(R++))<<U,U+=8}a+=E&K[y],E>>=y,U-=y,o=f,n=r,s=p,e=3;case 3:for(y=o;U<y;){if(0===x)return t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);g=0,x--,E|=(255&w.read_byte(R++))<<U,U+=8}if(b=3*(s+(E&K[y])),E>>=n[b+1],U-=n[b+1],m=n[b],0!=(16&m)){l=15&m,d=n[b+2],e=4;break}if(0==(64&m)){o=m,s=b/3+n[b+2];break}return e=9,w.msg="invalid distance code",g=-3,t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);case 4:for(y=l;U<y;){if(0===x)return t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);g=0,x--,E|=(255&w.read_byte(R++))<<U,U+=8}d+=E&K[y],E>>=y,U-=y,e=5;case 5:for(A=k-d;A<0;)A+=t.end;for(;0!==a;){if(0===v&&(k==t.end&&0!==t.read&&(k=0,v=k<t.read?t.read-k-1:t.end-k),0===v&&(t.write=k,g=t.inflate_flush(w,g),k=t.write,v=k<t.read?t.read-k-1:t.end-k,k==t.end&&0!==t.read&&(k=0,v=k<t.read?t.read-k-1:t.end-k),0===v)))return t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);t.window[k++]=t.window[A++],v--,A==t.end&&(A=0),a--}e=0;break;case 6:if(0===v&&(k==t.end&&0!==t.read&&(k=0,v=k<t.read?t.read-k-1:t.end-k),0===v&&(t.write=k,g=t.inflate_flush(w,g),k=t.write,v=k<t.read?t.read-k-1:t.end-k,k==t.end&&0!==t.read&&(k=0,v=k<t.read?t.read-k-1:t.end-k),0===v)))return t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);g=0,t.window[k++]=c,v--,e=0;break;case 7:if(U>7&&(U-=8,x++,R--),t.write=k,g=t.inflate_flush(w,g),k=t.write,v=k<t.read?t.read-k-1:t.end-k,t.read!=t.write)return t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);e=8;case 8:return g=1,t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);case 9:return g=-3,t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g);default:return g=-2,t.bitb=E,t.bitk=U,w.avail_in=x,w.total_in+=R-w.next_in_index,w.next_in_index=R,t.write=k,t.inflate_flush(w,g)}},t.free=function(){}}tt.inflate_trees_fixed=function(t,e,n,i){return t[0]=9,e[0]=5,n[0]=G,i[0]=Y,0};const nt=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];function it(t,e){const n=this;let i,r=0,a=0,s=0,o=0;const c=[0],l=[0],d=new et;let u=0,f=new Int32Array(4320);const h=new tt;n.bitk=0,n.bitb=0,n.window=new Uint8Array(e),n.end=e,n.read=0,n.write=0,n.reset=function(t,e){e&&(e[0]=0),6==r&&d.free(t),r=0,n.bitk=0,n.bitb=0,n.read=n.write=0},n.reset(t,null),n.inflate_flush=function(t,e){let i,r,a;return r=t.next_out_index,a=n.read,i=(a<=n.write?n.write:n.end)-a,i>t.avail_out&&(i=t.avail_out),0!==i&&-5==e&&(e=0),t.avail_out-=i,t.total_out+=i,t.next_out.set(n.window.subarray(a,a+i),r),r+=i,a+=i,a==n.end&&(a=0,n.write==n.end&&(n.write=0),i=n.write-a,i>t.avail_out&&(i=t.avail_out),0!==i&&-5==e&&(e=0),t.avail_out-=i,t.total_out+=i,t.next_out.set(n.window.subarray(a,a+i),r),r+=i,a+=i),t.next_out_index=r,n.read=a,e},n.proc=function(t,e){let p,_,w,g,y,b,m,x;for(g=t.next_in_index,y=t.avail_in,_=n.bitb,w=n.bitk,b=n.write,m=b<n.read?n.read-b-1:n.end-b;;){let k,v,A,E,U,R,D,z;switch(r){case 0:for(;w<3;){if(0===y)return n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);e=0,y--,_|=(255&t.read_byte(g++))<<w,w+=8}switch(p=7&_,u=1&p,p>>>1){case 0:_>>>=3,w-=3,p=7&w,_>>>=p,w-=p,r=1;break;case 1:k=[],v=[],A=[[]],E=[[]],tt.inflate_trees_fixed(k,v,A,E),d.init(k[0],v[0],A[0],0,E[0],0),_>>>=3,w-=3,r=6;break;case 2:_>>>=3,w-=3,r=3;break;case 3:return _>>>=3,w-=3,r=9,t.msg="invalid block type",e=-3,n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e)}break;case 1:for(;w<32;){if(0===y)return n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);e=0,y--,_|=(255&t.read_byte(g++))<<w,w+=8}if((~_>>>16&65535)!=(65535&_))return r=9,t.msg="invalid stored block lengths",e=-3,n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);a=65535&_,_=w=0,r=0!==a?2:0!==u?7:0;break;case 2:if(0===y)return n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);if(0===m&&(b==n.end&&0!==n.read&&(b=0,m=b<n.read?n.read-b-1:n.end-b),0===m&&(n.write=b,e=n.inflate_flush(t,e),b=n.write,m=b<n.read?n.read-b-1:n.end-b,b==n.end&&0!==n.read&&(b=0,m=b<n.read?n.read-b-1:n.end-b),0===m)))return n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);if(e=0,p=a,p>y&&(p=y),p>m&&(p=m),n.window.set(t.read_buf(g,p),b),g+=p,y-=p,b+=p,m-=p,0!=(a-=p))break;r=0!==u?7:0;break;case 3:for(;w<14;){if(0===y)return n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);e=0,y--,_|=(255&t.read_byte(g++))<<w,w+=8}if(s=p=16383&_,(31&p)>29||(p>>5&31)>29)return r=9,t.msg="too many length or distance symbols",e=-3,n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);if(p=258+(31&p)+(p>>5&31),!i||i.length<p)i=[];else for(x=0;x<p;x++)i[x]=0;_>>>=14,w-=14,o=0,r=4;case 4:for(;o<4+(s>>>10);){for(;w<3;){if(0===y)return n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);e=0,y--,_|=(255&t.read_byte(g++))<<w,w+=8}i[nt[o++]]=7&_,_>>>=3,w-=3}for(;o<19;)i[nt[o++]]=0;if(c[0]=7,p=h.inflate_trees_bits(i,c,l,f,t),0!=p)return-3==(e=p)&&(i=null,r=9),n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);o=0,r=5;case 5:for(;p=s,!(o>=258+(31&p)+(p>>5&31));){let a,d;for(p=c[0];w<p;){if(0===y)return n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);e=0,y--,_|=(255&t.read_byte(g++))<<w,w+=8}if(p=f[3*(l[0]+(_&K[p]))+1],d=f[3*(l[0]+(_&K[p]))+2],d<16)_>>>=p,w-=p,i[o++]=d;else{for(x=18==d?7:d-14,a=18==d?11:3;w<p+x;){if(0===y)return n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);e=0,y--,_|=(255&t.read_byte(g++))<<w,w+=8}if(_>>>=p,w-=p,a+=_&K[x],_>>>=x,w-=x,x=o,p=s,x+a>258+(31&p)+(p>>5&31)||16==d&&x<1)return i=null,r=9,t.msg="invalid bit length repeat",e=-3,n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);d=16==d?i[x-1]:0;do{i[x++]=d}while(0!=--a);o=x}}if(l[0]=-1,U=[],R=[],D=[],z=[],U[0]=9,R[0]=6,p=s,p=h.inflate_trees_dynamic(257+(31&p),1+(p>>5&31),i,U,R,D,z,f,t),0!=p)return-3==p&&(i=null,r=9),e=p,n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);d.init(U[0],R[0],f,D[0],f,z[0]),r=6;case 6:if(n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,1!=(e=d.proc(n,t,e)))return n.inflate_flush(t,e);if(e=0,d.free(t),g=t.next_in_index,y=t.avail_in,_=n.bitb,w=n.bitk,b=n.write,m=b<n.read?n.read-b-1:n.end-b,0===u){r=0;break}r=7;case 7:if(n.write=b,e=n.inflate_flush(t,e),b=n.write,m=b<n.read?n.read-b-1:n.end-b,n.read!=n.write)return n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);r=8;case 8:return e=1,n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);case 9:return e=-3,n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e);default:return e=-2,n.bitb=_,n.bitk=w,t.avail_in=y,t.total_in+=g-t.next_in_index,t.next_in_index=g,n.write=b,n.inflate_flush(t,e)}}},n.free=function(t){n.reset(t,null),n.window=null,f=null},n.set_dictionary=function(t,e,i){n.window.set(t.subarray(e,e+i),0),n.read=n.write=i},n.sync_point=function(){return 1==r?1:0}}const rt=[0,0,255,255];function at(){const t=this;function e(t){return t&&t.istate?(t.total_in=t.total_out=0,t.msg=null,t.istate.mode=7,t.istate.blocks.reset(t,null),0):-2}t.mode=0,t.method=0,t.was=[0],t.need=0,t.marker=0,t.wbits=0,t.inflateEnd=function(e){return t.blocks&&t.blocks.free(e),t.blocks=null,0},t.inflateInit=function(n,i){return n.msg=null,t.blocks=null,i<8||i>15?(t.inflateEnd(n),-2):(t.wbits=i,n.istate.blocks=new it(n,1<<i),e(n),0)},t.inflate=function(t,e){let n,i;if(!t||!t.istate||!t.next_in)return-2;const r=t.istate;for(e=4==e?-5:0,n=-5;;)switch(r.mode){case 0:if(0===t.avail_in)return n;if(n=e,t.avail_in--,t.total_in++,8!=(15&(r.method=t.read_byte(t.next_in_index++)))){r.mode=13,t.msg="unknown compression method",r.marker=5;break}if(8+(r.method>>4)>r.wbits){r.mode=13,t.msg="invalid window size",r.marker=5;break}r.mode=1;case 1:if(0===t.avail_in)return n;if(n=e,t.avail_in--,t.total_in++,i=255&t.read_byte(t.next_in_index++),((r.method<<8)+i)%31!=0){r.mode=13,t.msg="incorrect header check",r.marker=5;break}if(0==(32&i)){r.mode=7;break}r.mode=2;case 2:if(0===t.avail_in)return n;n=e,t.avail_in--,t.total_in++,r.need=(255&t.read_byte(t.next_in_index++))<<24&4278190080,r.mode=3;case 3:if(0===t.avail_in)return n;n=e,t.avail_in--,t.total_in++,r.need+=(255&t.read_byte(t.next_in_index++))<<16&16711680,r.mode=4;case 4:if(0===t.avail_in)return n;n=e,t.avail_in--,t.total_in++,r.need+=(255&t.read_byte(t.next_in_index++))<<8&65280,r.mode=5;case 5:return 0===t.avail_in?n:(n=e,t.avail_in--,t.total_in++,r.need+=255&t.read_byte(t.next_in_index++),r.mode=6,2);case 6:return r.mode=13,t.msg="need dictionary",r.marker=0,-2;case 7:if(n=r.blocks.proc(t,n),-3==n){r.mode=13,r.marker=0;break}if(0==n&&(n=e),1!=n)return n;n=e,r.blocks.reset(t,r.was),r.mode=12;case 12:return 1;case 13:return-3;default:return-2}},t.inflateSetDictionary=function(t,e,n){let i=0,r=n;if(!t||!t.istate||6!=t.istate.mode)return-2;const a=t.istate;return r>=1<<a.wbits&&(r=(1<<a.wbits)-1,i=n-r),a.blocks.set_dictionary(e,i,r),a.mode=7,0},t.inflateSync=function(t){let n,i,r,a,s;if(!t||!t.istate)return-2;const o=t.istate;if(13!=o.mode&&(o.mode=13,o.marker=0),0===(n=t.avail_in))return-5;for(i=t.next_in_index,r=o.marker;0!==n&&r<4;)t.read_byte(i)==rt[r]?r++:r=0!==t.read_byte(i)?0:4-r,i++,n--;return t.total_in+=i-t.next_in_index,t.next_in_index=i,t.avail_in=n,o.marker=r,4!=r?-3:(a=t.total_in,s=t.total_out,e(t),t.total_in=a,t.total_out=s,o.mode=7,0)},t.inflateSyncPoint=function(t){return t&&t.istate&&t.istate.blocks?t.istate.blocks.sync_point():-2}}function st(){}function ot(t){const e=new st,n=t&&t.chunkSize?Math.floor(2*t.chunkSize):131072,i=new Uint8Array(n);let r=!1;e.inflateInit(),e.next_out=i,this.append=function(t,a){const s=[];let o,c,l=0,d=0,u=0;if(0!==t.length){e.next_in_index=0,e.next_in=t,e.avail_in=t.length;do{if(e.next_out_index=0,e.avail_out=n,0!==e.avail_in||r||(e.next_in_index=0,r=!0),o=e.inflate(0),r&&-5===o){if(0!==e.avail_in)throw new Error("inflating: bad input")}else if(0!==o&&1!==o)throw new Error("inflating: "+e.msg);if((r||1===o)&&e.avail_in===t.length)throw new Error("inflating: bad input");e.next_out_index&&(e.next_out_index===n?s.push(new Uint8Array(i)):s.push(i.slice(0,e.next_out_index))),u+=e.next_out_index,a&&e.next_in_index>0&&e.next_in_index!=l&&(a(e.next_in_index),l=e.next_in_index)}while(e.avail_in>0||0===e.avail_out);return s.length>1?(c=new Uint8Array(u),s.forEach((function(t){c.set(t,d),d+=t.length}))):c=s[0]||new Uint8Array(0),c}},this.flush=function(){e.inflateEnd()}}st.prototype={inflateInit:function(t){const e=this;return e.istate=new at,t||(t=15),e.istate.inflateInit(e,t)},inflate:function(t){const e=this;return e.istate?e.istate.inflate(e,t):-2},inflateEnd:function(){const t=this;if(!t.istate)return-2;const e=t.istate.inflateEnd(t);return t.istate=null,e},inflateSync:function(){const t=this;return t.istate?t.istate.inflateSync(t):-2},inflateSetDictionary:function(t,e){const n=this;return n.istate?n.istate.inflateSetDictionary(n,t,e):-2},read_byte:function(t){return this.next_in[t]},read_buf:function(t,e){return this.next_in.subarray(t,t+e)}},self.initCodec=()=>{self.Deflate=q,self.Inflate=ot}}).toString(),e=URL.createObjectURL(new Blob(["("+t+")()"],{type:"text/javascript"}));r({workerScripts:{inflate:[e],deflate:[e]}})}})(),t.BlobReader=mt,t.BlobWriter=xt,t.Data64URIReader=yt,t.Data64URIWriter=bt,t.ERR_ABORT=Kt,t.ERR_BAD_FORMAT=$t,t.ERR_CENTRAL_DIRECTORY_NOT_FOUND=ie,t.ERR_DUPLICATED_NAME=Ue,t.ERR_ENCRYPTED=se,t.ERR_EOCDR_LOCATOR_ZIP64_NOT_FOUND=ne,t.ERR_EOCDR_NOT_FOUND=te,t.ERR_EOCDR_ZIP64_NOT_FOUND=ee,t.ERR_EXTRAFIELD_ZIP64_NOT_FOUND=ae,t.ERR_HTTP_RANGE=st,t.ERR_INVALID_COMMENT=Re,t.ERR_INVALID_ENCRYPTION_STRENGTH=Fe,t.ERR_INVALID_ENTRY_COMMENT=De,t.ERR_INVALID_ENTRY_NAME=ze,t.ERR_INVALID_EXTRAFIELD_DATA=Ce,t.ERR_INVALID_EXTRAFIELD_TYPE=Te,t.ERR_INVALID_PASSWORD=p,t.ERR_INVALID_SIGNATURE=K,t.ERR_INVALID_VERSION=Se,t.ERR_LOCAL_FILE_HEADER_NOT_FOUND=re,t.ERR_UNSUPPORTED_COMPRESSION=ce,t.ERR_UNSUPPORTED_ENCRYPTION=oe,t.ERR_UNSUPPORTED_FORMAT=Ie,t.HttpRangeReader=class extends Dt{constructor(t,e={}){e.useRangeHeader=!0,super(t,e)}},t.HttpReader=Dt,t.Reader=pt,t.TextReader=wt,t.TextWriter=gt,t.Uint8ArrayReader=zt,t.Uint8ArrayWriter=St,t.Writer=_t,t.ZipReader=ue,t.ZipWriter=Oe,t.configure=r,t.fs=Je,t.getMimeType=function(){return"application/octet-stream"},t.initShimAsyncCodec=(t,e={},n)=>({Deflate:a(t.Deflate,e.deflate,n),Inflate:a(t.Inflate,e.inflate,n)}),t.terminateWorkers=function(){et.forEach((t=>t.terminate()))},Object.defineProperty(t,"__esModule",{value:!0})}));
  