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