@incodetech/tri-sdk 0.4.0-rc.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +0,0 @@
1
- "use strict";var t={},n=Uint8Array,i=Uint16Array,r=Int32Array,e=new n([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,0,0,0]),o=new n([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,0,0]),s=new n([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),f=function(t,n){for(var e=new i(31),o=0;o<31;++o)e[o]=n+=1<<t[o-1];var s=new r(e[30]);for(o=1;o<30;++o)for(var f=e[o];f<e[o+1];++f)s[f]=f-e[o]<<5|o;return{b:e,r:s}},u=f(e,2),a=u.b,h=u.r;a[28]=258,h[258]=28;for(var c=f(o,0),v=c.b,l=c.r,p=new i(32768),w=0;w<32768;++w){var d=(43690&w)>>1|(21845&w)<<1;p[w]=((65280&(d=(61680&(d=(52428&d)>>2|(13107&d)<<2))>>4|(3855&d)<<4))>>8|(255&d)<<8)>>1}var x=function(t,n,r){for(var e=t.length,o=0,s=new i(n);o<e;++o)t[o]&&++s[t[o]-1];var f,u=new i(n);for(o=1;o<n;++o)u[o]=u[o-1]+s[o-1]<<1;if(r){f=new i(1<<n);var a=15-n;for(o=0;o<e;++o)if(t[o])for(var h=o<<4|t[o],c=n-t[o],v=u[t[o]-1]++<<c,l=v|(1<<c)-1;v<=l;++v)f[p[v]>>a]=h}else for(f=new i(e),o=0;o<e;++o)t[o]&&(f[o]=p[u[t[o]-1]++]>>15-t[o]);return f},y=new n(288);for(w=0;w<144;++w)y[w]=8;for(w=144;w<256;++w)y[w]=9;for(w=256;w<280;++w)y[w]=7;for(w=280;w<288;++w)y[w]=8;var m=new n(32);for(w=0;w<32;++w)m[w]=5;var g=x(y,9,0),k=x(y,9,1),M=x(m,5,0),b=x(m,5,1),z=function(t){for(var n=t[0],i=1;i<t.length;++i)t[i]>n&&(n=t[i]);return n},T=function(t,n,i){var r=n/8|0;return(t[r]|t[r+1]<<8)>>(7&n)&i},D=function(t,n){var i=n/8|0;return(t[i]|t[i+1]<<8|t[i+2]<<16)>>(7&n)},E=function(t){return(t+7)/8|0},I=function(t,i,r){return(null==i||i<0)&&(i=0),(null==r||r>t.length)&&(r=t.length),new n(t.subarray(i,r))},S=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],F=function(t,n,i){var r=new Error(n||S[t]);if(r.code=t,Error.captureStackTrace&&Error.captureStackTrace(r,F),!i)throw r;return r},A=function(t,i,r,f){var u=t.length,h=f?f.length:0;if(!u||i.f&&!i.l)return r||new n(0);var c=!r,l=c||2!=i.i,p=i.i;c&&(r=new n(3*u));var w=function(t){var i=r.length;if(t>i){var e=new n(Math.max(2*i,t));e.set(r),r=e}},d=i.f||0,y=i.p||0,m=i.b||0,g=i.l,M=i.d,S=i.m,A=i.n,U=8*u;do{if(!g){d=T(t,y,1);var L=T(t,y+1,3);if(y+=3,!L){var O=t[(G=E(y)+4)-4]|t[G-3]<<8,j=G+O;if(j>u){p&&F(0);break}l&&w(m+O),r.set(t.subarray(G,j),m),i.b=m+=O,i.p=y=8*j,i.f=d;continue}if(1==L)g=k,M=b,S=9,A=5;else if(2==L){var q=T(t,y,31)+257,B=T(t,y+10,15)+4,C=q+T(t,y+5,31)+1;y+=14;for(var H=new n(C),N=new n(19),$=0;$<B;++$)N[s[$]]=T(t,y+3*$,7);y+=3*B;var R=z(N),W=(1<<R)-1,Z=x(N,R,1);for($=0;$<C;){var G,J=Z[T(t,y,W)];if(y+=15&J,(G=J>>4)<16)H[$++]=G;else{var K=0,P=0;for(16==G?(P=3+T(t,y,3),y+=2,K=H[$-1]):17==G?(P=3+T(t,y,7),y+=3):18==G&&(P=11+T(t,y,127),y+=7);P--;)H[$++]=K}}var Q=H.subarray(0,q),V=H.subarray(q);S=z(Q),A=z(V),g=x(Q,S,1),M=x(V,A,1)}else F(1);if(y>U){p&&F(0);break}}l&&w(m+131072);for(var X=(1<<S)-1,Y=(1<<A)-1,_=y;;_=y){var tt=(K=g[D(t,y)&X])>>4;if((y+=15&K)>U){p&&F(0);break}if(K||F(2),tt<256)r[m++]=tt;else{if(256==tt){_=y,g=null;break}var nt=tt-254;tt>264&&(nt=T(t,y,(1<<(et=e[$=tt-257]))-1)+a[$],y+=et);var it=M[D(t,y)&Y],rt=it>>4;if(it||F(3),y+=15&it,V=v[rt],rt>3){var et=o[rt];V+=D(t,y)&(1<<et)-1,y+=et}if(y>U){p&&F(0);break}l&&w(m+131072);var ot=m+nt;if(m<V){var st=h-V,ft=Math.min(V,ot);for(st+m<0&&F(3);m<ft;++m)r[m]=f[st+m]}for(;m<ot;++m)r[m]=r[m-V]}}i.l=g,i.p=_,i.b=m,i.f=d,g&&(d=1,i.m=S,i.d=M,i.n=A)}while(!d);return m!=r.length&&c?I(r,0,m):r.subarray(0,m)},U=function(t,n,i){var r=n/8|0;t[r]|=i<<=7&n,t[r+1]|=i>>8},L=function(t,n,i){var r=n/8|0;t[r]|=i<<=7&n,t[r+1]|=i>>8,t[r+2]|=i>>16},O=function(t,r){for(var e=[],o=0;o<t.length;++o)t[o]&&e.push({s:o,f:t[o]});var s=e.length,f=e.slice();if(!s)return{t:$,l:0};if(1==s){var u=new n(e[0].s+1);return u[e[0].s]=1,{t:u,l:1}}e.sort(function(t,n){return t.f-n.f}),e.push({s:-1,f:25001});var a=e[0],h=e[1],c=0,v=1,l=2;for(e[0]={s:-1,f:a.f+h.f,l:a,r:h};v!=s-1;)a=e[e[c].f<e[l].f?c++:l++],h=e[c!=v&&e[c].f<e[l].f?c++:l++],e[v++]={s:-1,f:a.f+h.f,l:a,r:h};var p=f[0].s;for(o=1;o<s;++o)f[o].s>p&&(p=f[o].s);var w=new i(p+1),d=j(e[v-1],w,0);if(d>r){o=0;var x=0,y=d-r,m=1<<y;for(f.sort(function(t,n){return w[n.s]-w[t.s]||t.f-n.f});o<s;++o){var g=f[o].s;if(!(w[g]>r))break;x+=m-(1<<d-w[g]),w[g]=r}for(x>>=y;x>0;){var k=f[o].s;w[k]<r?x-=1<<r-w[k]++-1:++o}for(;o>=0&&x;--o){var M=f[o].s;w[M]==r&&(--w[M],++x)}d=r}return{t:new n(w),l:d}},j=function(t,n,i){return-1==t.s?Math.max(j(t.l,n,i+1),j(t.r,n,i+1)):n[t.s]=i},q=function(t){for(var n=t.length;n&&!t[--n];);for(var r=new i(++n),e=0,o=t[0],s=1,f=function(t){r[e++]=t},u=1;u<=n;++u)if(t[u]==o&&u!=n)++s;else{if(!o&&s>2){for(;s>138;s-=138)f(32754);s>2&&(f(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(f(o),--s;s>6;s-=6)f(8304);s>2&&(f(s-3<<5|8208),s=0)}for(;s--;)f(o);s=1,o=t[u]}return{c:r.subarray(0,e),n:n}},B=function(t,n){for(var i=0,r=0;r<n.length;++r)i+=t[r]*n[r];return i},C=function(t,n,i){var r=i.length,e=E(n+2);t[e]=255&r,t[e+1]=r>>8,t[e+2]=255^t[e],t[e+3]=255^t[e+1];for(var o=0;o<r;++o)t[e+o+4]=i[o];return 8*(e+4+r)},H=function(t,n,r,f,u,a,h,c,v,l,p){U(n,p++,r),++u[256];for(var w=O(u,15),d=w.t,k=w.l,b=O(a,15),z=b.t,T=b.l,D=q(d),E=D.c,I=D.n,S=q(z),F=S.c,A=S.n,j=new i(19),H=0;H<E.length;++H)++j[31&E[H]];for(H=0;H<F.length;++H)++j[31&F[H]];for(var N=O(j,7),$=N.t,R=N.l,W=19;W>4&&!$[s[W-1]];--W);var Z,G,J,K,P=l+5<<3,Q=B(u,y)+B(a,m)+h,V=B(u,d)+B(a,z)+h+14+3*W+B(j,$)+2*j[16]+3*j[17]+7*j[18];if(v>=0&&P<=Q&&P<=V)return C(n,p,t.subarray(v,v+l));if(U(n,p,1+(V<Q)),p+=2,V<Q){Z=x(d,k,0),G=d,J=x(z,T,0),K=z;var X=x($,R,0);for(U(n,p,I-257),U(n,p+5,A-1),U(n,p+10,W-4),p+=14,H=0;H<W;++H)U(n,p+3*H,$[s[H]]);p+=3*W;for(var Y=[E,F],_=0;_<2;++_){var tt=Y[_];for(H=0;H<tt.length;++H)U(n,p,X[it=31&tt[H]]),p+=$[it],it>15&&(U(n,p,tt[H]>>5&127),p+=tt[H]>>12)}}else Z=g,G=y,J=M,K=m;for(H=0;H<c;++H){var nt=f[H];if(nt>255){var it;L(n,p,Z[257+(it=nt>>18&31)]),p+=G[it+257],it>7&&(U(n,p,nt>>23&31),p+=e[it]);var rt=31&nt;L(n,p,J[rt]),p+=K[rt],rt>3&&(L(n,p,nt>>5&8191),p+=o[rt])}else L(n,p,Z[nt]),p+=G[nt]}return L(n,p,Z[256]),p+G[256]},N=new r([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),$=new n(0),R=function(t,s,f,u,a,c){var v=c.z||t.length,p=new n(u+v+5*(1+Math.ceil(v/7e3))+a),w=p.subarray(u,p.length-a),d=c.l,x=7&(c.r||0);if(s){x&&(w[0]=c.r>>3);for(var y=N[s-1],m=y>>13,g=8191&y,k=(1<<f)-1,M=c.p||new i(32768),b=c.h||new i(k+1),z=Math.ceil(f/3),T=2*z,D=function(n){return(t[n]^t[n+1]<<z^t[n+2]<<T)&k},S=new r(25e3),F=new i(288),A=new i(32),U=0,L=0,O=c.i||0,j=0,q=c.w||0,B=0;O+2<v;++O){var $=D(O),R=32767&O,W=b[$];if(M[R]=W,b[$]=R,q<=O){var Z=v-O;if((U>7e3||j>24576)&&(Z>423||!d)){x=H(t,w,0,S,F,A,L,j,B,O-B,x),j=U=L=0,B=O;for(var G=0;G<286;++G)F[G]=0;for(G=0;G<30;++G)A[G]=0}var J=2,K=0,P=g,Q=R-W&32767;if(Z>2&&$==D(O-Q))for(var V=Math.min(m,Z)-1,X=Math.min(32767,O),Y=Math.min(258,Z);Q<=X&&--P&&R!=W;){if(t[O+J]==t[O+J-Q]){for(var _=0;_<Y&&t[O+_]==t[O+_-Q];++_);if(_>J){if(J=_,K=Q,_>V)break;var tt=Math.min(Q,_-2),nt=0;for(G=0;G<tt;++G){var it=O-Q+G&32767,rt=it-M[it]&32767;rt>nt&&(nt=rt,W=it)}}}Q+=(R=W)-(W=M[R])&32767}if(K){S[j++]=268435456|h[J]<<18|l[K];var et=31&h[J],ot=31&l[K];L+=e[et]+o[ot],++F[257+et],++A[ot],q=O+J,++U}else S[j++]=t[O],++F[t[O]]}}for(O=Math.max(O,q);O<v;++O)S[j++]=t[O],++F[t[O]];x=H(t,w,d,S,F,A,L,j,B,O-B,x),d||(c.r=7&x|w[x/8|0]<<3,x-=7,c.h=b,c.p=M,c.i=O,c.w=q)}else{for(O=c.w||0;O<v+d;O+=65535){var st=O+65535;st>=v&&(w[x/8|0]=d,st=v),x=C(w,x+1,t.subarray(O,st))}c.i=v}return I(p,0,u+E(x)+a)},W=function(){for(var t=new Int32Array(256),n=0;n<256;++n){for(var i=n,r=9;--r;)i=(1&i&&-306674912)^i>>>1;t[n]=i}return t}(),Z=function(){var t=-1;return{p:function(n){for(var i=t,r=0;r<n.length;++r)i=W[255&i^n[r]]^i>>>8;t=i},d:function(){return~t}}},G=function(){var t=1,n=0;return{p:function(i){for(var r=t,e=n,o=0|i.length,s=0;s!=o;){for(var f=Math.min(s+2655,o);s<f;++s)e+=r+=i[s];r=(65535&r)+15*(r>>16),e=(65535&e)+15*(e>>16)}t=r,n=e},d:function(){return(255&(t%=65521))<<24|(65280&t)<<8|(255&(n%=65521))<<8|n>>8}}},J=function(t,i,r,e,o){if(!o&&(o={l:1},i.dictionary)){var s=i.dictionary.subarray(-32768),f=new n(s.length+t.length);f.set(s),f.set(t,s.length),t=f,o.w=s.length}return R(t,null==i.level?6:i.level,null==i.mem?o.l?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(t.length)))):20:12+i.mem,r,e,o)},K=function(t,n){var i={};for(var r in t)i[r]=t[r];for(var r in n)i[r]=n[r];return i},P=function(t,n,i){for(var r=t(),e=t.toString(),o=e.slice(e.indexOf("[")+1,e.lastIndexOf("]")).replace(/\s+/g,"").split(","),s=0;s<r.length;++s){var f=r[s],u=o[s];if("function"==typeof f){n+=";"+u+"=";var a=f.toString();if(f.prototype)if(-1!=a.indexOf("[native code]")){var h=a.indexOf(" ",8)+1;n+=a.slice(h,a.indexOf("(",h))}else for(var c in n+=a,f.prototype)n+=";"+u+".prototype."+c+"="+f.prototype[c].toString();else n+=a}else i[u]=f}return n},Q=[],V=function(n,i,r,e){if(!Q[r]){for(var o="",s={},f=n.length-1,u=0;u<f;++u)o=P(n[u],o,s);Q[r]={c:P(n[f],o,s),e:s}}var a=K({},Q[r].e);return function(n,i,r,e,o){var s=new Worker(t[i]||(t[i]=URL.createObjectURL(new Blob([n+';addEventListener("error",function(e){e=e.error;postMessage({$e$:[e.message,e.code,e.stack]})})'],{type:"text/javascript"}))));return s.onmessage=function(t){var n=t.data,i=n.$e$;if(i){var r=new Error(i[0]);r.code=i[1],r.stack=i[2],o(r,null)}else o(null,n)},s.postMessage(r,e),s}(Q[r].c+";onmessage=function(e){for(var k in e.data)self[k]=e.data[k];onmessage="+i.toString()+"}",r,a,function(t){var n=[];for(var i in t)t[i].buffer&&n.push((t[i]=new t[i].constructor(t[i])).buffer);return n}(a),e)},X=function(){return[n,i,r,e,o,s,a,v,k,b,p,S,x,z,T,D,E,I,F,A,Dt,rt,et]},Y=function(){return[n,i,r,e,o,s,h,l,g,y,M,m,p,N,$,x,U,L,O,j,q,B,C,H,E,I,R,J,Mt,rt]},_=function(){return[vt,wt,ct,Z,W]},tt=function(){return[lt,pt]},nt=function(){return[dt,ct,G]},it=function(){return[xt]},rt=function(t){return postMessage(t,[t.buffer])},et=function(t){return t&&{out:t.size&&new n(t.size),dictionary:t.dictionary}},ot=function(t,n,i,r,e,o){var s=V(i,r,e,function(t,n){s.terminate(),o(t,n)});return s.postMessage([t,n],n.consume?[t.buffer]:[]),function(){s.terminate()}},st=function(t){return t.ondata=function(t,n){return postMessage([t,n],[t.buffer])},function(n){n.data.length?(t.push(n.data[0],n.data[1]),postMessage([n.data[0].length])):t.flush()}},ft=function(t,n,i,r,e,o,s){var f,u=V(t,r,e,function(t,i){t?(u.terminate(),n.ondata.call(n,t)):Array.isArray(i)?1==i.length?(n.queuedSize-=i[0],n.ondrain&&n.ondrain(i[0])):(i[1]&&u.terminate(),n.ondata.call(n,t,i[0],i[1])):s(i)});u.postMessage(i),n.queuedSize=0,n.push=function(t,i){n.ondata||F(5),f&&n.ondata(F(4,0,1),null,!!i),n.queuedSize+=t.length,u.postMessage([t,f=i],[t.buffer])},n.terminate=function(){u.terminate()},o&&(n.flush=function(){u.postMessage([])})},ut=function(t,n){return t[n]|t[n+1]<<8},at=function(t,n){return(t[n]|t[n+1]<<8|t[n+2]<<16|t[n+3]<<24)>>>0},ht=function(t,n){return at(t,n)+4294967296*at(t,n+4)},ct=function(t,n,i){for(;i;++n)t[n]=i,i>>>=8},vt=function(t,n){var i=n.filename;if(t[0]=31,t[1]=139,t[2]=8,t[8]=n.level<2?4:9==n.level?2:0,t[9]=3,0!=n.mtime&&ct(t,4,Math.floor(new Date(n.mtime||Date.now())/1e3)),i){t[3]=8;for(var r=0;r<=i.length;++r)t[r+10]=i.charCodeAt(r)}},lt=function(t){31==t[0]&&139==t[1]&&8==t[2]||F(6,"invalid gzip data");var n=t[3],i=10;4&n&&(i+=2+(t[10]|t[11]<<8));for(var r=(n>>3&1)+(n>>4&1);r>0;r-=!t[i++]);return i+(2&n)},pt=function(t){var n=t.length;return(t[n-4]|t[n-3]<<8|t[n-2]<<16|t[n-1]<<24)>>>0},wt=function(t){return 10+(t.filename?t.filename.length+1:0)},dt=function(t,n){var i=n.level,r=0==i?0:i<6?1:9==i?3:2;if(t[0]=120,t[1]=r<<6|(n.dictionary&&32),t[1]|=31-(t[0]<<8|t[1])%31,n.dictionary){var e=G();e.p(n.dictionary),ct(t,2,e.d())}},xt=function(t,n){return(8!=(15&t[0])||t[0]>>4>7||(t[0]<<8|t[1])%31)&&F(6,"invalid zlib data"),(t[1]>>5&1)==+!n&&F(6,"invalid zlib data: "+(32&t[1]?"need":"unexpected")+" dictionary"),2+(t[1]>>3&4)};function yt(t,n){return"function"==typeof t&&(n=t,t={}),this.ondata=n,t}var mt=function(){function t(t,i){if("function"==typeof t&&(i=t,t={}),this.ondata=i,this.o=t||{},this.s={l:0,i:32768,w:32768,z:32768},this.b=new n(98304),this.o.dictionary){var r=this.o.dictionary.subarray(-32768);this.b.set(r,32768-r.length),this.s.i=32768-r.length}}return t.prototype.p=function(t,n){this.ondata(J(t,this.o,0,0,this.s),n)},t.prototype.push=function(t,i){this.ondata||F(5),this.s.l&&F(4);var r=t.length+this.s.z;if(r>this.b.length){if(r>2*this.b.length-32768){var e=new n(-32768&r);e.set(this.b.subarray(0,this.s.z)),this.b=e}var o=this.b.length-this.s.z;this.b.set(t.subarray(0,o),this.s.z),this.s.z=this.b.length,this.p(this.b,0),this.b.set(this.b.subarray(-32768)),this.b.set(t.subarray(o),32768),this.s.z=t.length-o+32768,this.s.i=32766,this.s.w=32768}else this.b.set(t,this.s.z),this.s.z+=t.length;this.s.l=1&i,(this.s.z>this.s.w+8191||i)&&(this.p(this.b,i||0),this.s.w=this.s.i,this.s.i-=2)},t.prototype.flush=function(){this.ondata||F(5),this.s.l&&F(4),this.p(this.b,0),this.s.w=this.s.i,this.s.i-=2},t}(),gt=function(){return function(t,n){ft([Y,function(){return[st,mt]}],this,yt.call(this,t,n),function(t){var n=new mt(t.data);onmessage=st(n)},6,1)}}();function kt(t,n,i){return i||(i=n,n={}),"function"!=typeof i&&F(7),ot(t,n,[Y],function(t){return rt(Mt(t.data[0],t.data[1]))},0,i)}function Mt(t,n){return J(t,n||{},0,0)}var bt=function(){function t(t,i){"function"==typeof t&&(i=t,t={}),this.ondata=i;var r=t&&t.dictionary&&t.dictionary.subarray(-32768);this.s={i:0,b:r?r.length:0},this.o=new n(32768),this.p=new n(0),r&&this.o.set(r)}return t.prototype.e=function(t){if(this.ondata||F(5),this.d&&F(4),this.p.length){if(t.length){var i=new n(this.p.length+t.length);i.set(this.p),i.set(t,this.p.length),this.p=i}}else this.p=t},t.prototype.c=function(t){this.s.i=+(this.d=t||0);var n=this.s.b,i=A(this.p,this.s,this.o);this.ondata(I(i,n,this.s.b),this.d),this.o=I(i,this.s.b-32768),this.s.b=this.o.length,this.p=I(this.p,this.s.p/8|0),this.s.p&=7},t.prototype.push=function(t,n){this.e(t),this.c(n)},t}(),zt=function(){return function(t,n){ft([X,function(){return[st,bt]}],this,yt.call(this,t,n),function(t){var n=new bt(t.data);onmessage=st(n)},7,0)}}();function Tt(t,n,i){return i||(i=n,n={}),"function"!=typeof i&&F(7),ot(t,n,[X],function(t){return rt(Dt(t.data[0],et(t.data[1])))},1,i)}function Dt(t,n){return A(t,{i:2},n&&n.out,n&&n.dictionary)}var Et=function(){function t(t,n){this.c=Z(),this.l=0,this.v=1,mt.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),this.l+=t.length,mt.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var i=J(t,this.o,this.v&&wt(this.o),n&&8,this.s);this.v&&(vt(i,this.o),this.v=0),n&&(ct(i,i.length-8,this.c.d()),ct(i,i.length-4,this.l)),this.ondata(i,n)},t.prototype.flush=function(){mt.prototype.flush.call(this)},t}(),It=function(){return function(t,n){ft([Y,_,function(){return[st,mt,Et]}],this,yt.call(this,t,n),function(t){var n=new Et(t.data);onmessage=st(n)},8,1)}}();function St(t,n,i){return i||(i=n,n={}),"function"!=typeof i&&F(7),ot(t,n,[Y,_,function(){return[Ft]}],function(t){return rt(Ft(t.data[0],t.data[1]))},2,i)}function Ft(t,n){n||(n={});var i=Z(),r=t.length;i.p(t);var e=J(t,n,wt(n),8),o=e.length;return vt(e,n),ct(e,o-8,i.d()),ct(e,o-4,r),e}var At=function(){function t(t,n){this.v=1,this.r=0,bt.call(this,t,n)}return t.prototype.push=function(t,i){if(bt.prototype.e.call(this,t),this.r+=t.length,this.v){var r=this.p.subarray(this.v-1),e=r.length>3?lt(r):4;if(e>r.length){if(!i)return}else this.v>1&&this.onmember&&this.onmember(this.r-r.length);this.p=r.subarray(e),this.v=0}bt.prototype.c.call(this,i),!this.s.f||this.s.l||i||(this.v=E(this.s.p)+9,this.s={i:0},this.o=new n(0),this.push(new n(0),i))},t}(),Ut=function(){return function(t,n){var i=this;ft([X,tt,function(){return[st,bt,At]}],this,yt.call(this,t,n),function(t){var n=new At(t.data);n.onmember=function(t){return postMessage(t)},onmessage=st(n)},9,0,function(t){return i.onmember&&i.onmember(t)})}}();function Lt(t,n,i){return i||(i=n,n={}),"function"!=typeof i&&F(7),ot(t,n,[X,tt,function(){return[Ot]}],function(t){return rt(Ot(t.data[0],t.data[1]))},3,i)}function Ot(t,i){var r=lt(t);return r+8>t.length&&F(6,"invalid gzip data"),A(t.subarray(r,-8),{i:2},i&&i.out||new n(pt(t)),i&&i.dictionary)}var jt=function(){function t(t,n){this.c=G(),this.v=1,mt.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),mt.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var i=J(t,this.o,this.v&&(this.o.dictionary?6:2),n&&4,this.s);this.v&&(dt(i,this.o),this.v=0),n&&ct(i,i.length-4,this.c.d()),this.ondata(i,n)},t.prototype.flush=function(){mt.prototype.flush.call(this)},t}(),qt=function(){return function(t,n){ft([Y,nt,function(){return[st,mt,jt]}],this,yt.call(this,t,n),function(t){var n=new jt(t.data);onmessage=st(n)},10,1)}}();function Bt(t,n){n||(n={});var i=G();i.p(t);var r=J(t,n,n.dictionary?6:2,4);return dt(r,n),ct(r,r.length-4,i.d()),r}var Ct=function(){function t(t,n){bt.call(this,t,n),this.v=t&&t.dictionary?2:1}return t.prototype.push=function(t,n){if(bt.prototype.e.call(this,t),this.v){if(this.p.length<6&&!n)return;this.p=this.p.subarray(xt(this.p,this.v-1)),this.v=0}n&&(this.p.length<4&&F(6,"invalid zlib data"),this.p=this.p.subarray(0,-4)),bt.prototype.c.call(this,n)},t}(),Ht=function(){return function(t,n){ft([X,it,function(){return[st,bt,Ct]}],this,yt.call(this,t,n),function(t){var n=new Ct(t.data);onmessage=st(n)},11,0)}}();function Nt(t,n,i){return i||(i=n,n={}),"function"!=typeof i&&F(7),ot(t,n,[X,it,function(){return[$t]}],function(t){return rt($t(t.data[0],et(t.data[1])))},5,i)}function $t(t,n){return A(t.subarray(xt(t,n&&n.dictionary),-4),{i:2},n&&n.out,n&&n.dictionary)}var Rt=function(){function t(t,n){this.o=yt.call(this,t,n)||{},this.G=At,this.I=bt,this.Z=Ct}return t.prototype.i=function(){var t=this;this.s.ondata=function(n,i){t.ondata(n,i)}},t.prototype.push=function(t,i){if(this.ondata||F(5),this.s)this.s.push(t,i);else{if(this.p&&this.p.length){var r=new n(this.p.length+t.length);r.set(this.p),r.set(t,this.p.length)}else this.p=t;this.p.length>2&&(this.s=31==this.p[0]&&139==this.p[1]&&8==this.p[2]?new this.G(this.o):8!=(15&this.p[0])||this.p[0]>>4>7||(this.p[0]<<8|this.p[1])%31?new this.I(this.o):new this.Z(this.o),this.i(),this.s.push(this.p,i),this.p=null)}},t}(),Wt=function(){function t(t,n){Rt.call(this,t,n),this.queuedSize=0,this.G=Ut,this.I=zt,this.Z=Ht}return t.prototype.i=function(){var t=this;this.s.ondata=function(n,i,r){t.ondata(n,i,r)},this.s.ondrain=function(n){t.queuedSize-=n,t.ondrain&&t.ondrain(n)}},t.prototype.push=function(t,n){this.queuedSize+=t.length,Rt.prototype.push.call(this,t,n)},t}(),Zt=function(t,i,r,e){for(var o in t){var s=t[o],f=i+o,u=e;Array.isArray(s)&&(u=K(e,s[1]),s=s[0]),s instanceof n?r[f]=[s,u]:(r[f+="/"]=[new n(0),u],Zt(s,f,r,e))}},Gt="undefined"!=typeof TextEncoder&&new TextEncoder,Jt="undefined"!=typeof TextDecoder&&new TextDecoder,Kt=0;try{Jt.decode($,{stream:1}),Kt=1}catch(t){}var Pt=function(t){for(var n="",i=0;;){var r=t[i++],e=(r>127)+(r>223)+(r>239);if(i+e>t.length)return{s:n,r:I(t,i-1)};e?3==e?(r=((15&r)<<18|(63&t[i++])<<12|(63&t[i++])<<6|63&t[i++])-65536,n+=String.fromCharCode(55296|r>>10,56320|1023&r)):n+=String.fromCharCode(1&e?(31&r)<<6|63&t[i++]:(15&r)<<12|(63&t[i++])<<6|63&t[i++]):n+=String.fromCharCode(r)}},Qt=function(){function t(t){this.ondata=t,Kt?this.t=new TextDecoder:this.p=$}return t.prototype.push=function(t,i){if(this.ondata||F(5),i=!!i,this.t)return this.ondata(this.t.decode(t,{stream:1}),i),void(i&&(this.t.decode().length&&F(8),this.t=null));this.p||F(4);var r=new n(this.p.length+t.length);r.set(this.p),r.set(t,this.p.length);var e=Pt(r),o=e.s,s=e.r;i?(s.length&&F(8),this.p=null):this.p=s,this.ondata(o,i)},t}(),Vt=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||F(5),this.d&&F(4),this.ondata(Xt(t),this.d=n||0)},t}();function Xt(t,i){if(i){for(var r=new n(t.length),e=0;e<t.length;++e)r[e]=t.charCodeAt(e);return r}if(Gt)return Gt.encode(t);var o=t.length,s=new n(t.length+(t.length>>1)),f=0,u=function(t){s[f++]=t};for(e=0;e<o;++e){if(f+5>s.length){var a=new n(f+8+(o-e<<1));a.set(s),s=a}var h=t.charCodeAt(e);h<128||i?u(h):h<2048?(u(192|h>>6),u(128|63&h)):h>55295&&h<57344?(u(240|(h=65536+(1047552&h)|1023&t.charCodeAt(++e))>>18),u(128|h>>12&63),u(128|h>>6&63),u(128|63&h)):(u(224|h>>12),u(128|h>>6&63),u(128|63&h))}return I(s,0,f)}function Yt(t,n){if(n){for(var i="",r=0;r<t.length;r+=16384)i+=String.fromCharCode.apply(null,t.subarray(r,r+16384));return i}if(Jt)return Jt.decode(t);var e=Pt(t),o=e.s;return(i=e.r).length&&F(8),o}var _t=function(t){return 1==t?3:t<6?2:9==t?1:0},tn=function(t,n){return n+30+ut(t,n+26)+ut(t,n+28)},nn=function(t,n,i){var r=ut(t,n+28),e=Yt(t.subarray(n+46,n+46+r),!(2048&ut(t,n+8))),o=n+46+r,s=at(t,n+20),f=i&&4294967295==s?rn(t,o):[s,at(t,n+24),at(t,n+42)],u=f[0],a=f[1],h=f[2];return[ut(t,n+10),u,a,e,o+ut(t,n+30)+ut(t,n+32),h]},rn=function(t,n){for(;1!=ut(t,n);n+=4+ut(t,n+2));return[ht(t,n+12),ht(t,n+4),ht(t,n+20)]},en=function(t){var n=0;if(t)for(var i in t){var r=t[i].length;r>65535&&F(9),n+=r+4}return n},on=function(t,n,i,r,e,o,s,f){var u=r.length,a=i.extra,h=f&&f.length,c=en(a);ct(t,n,null!=s?33639248:67324752),n+=4,null!=s&&(t[n++]=20,t[n++]=i.os),t[n]=20,n+=2,t[n++]=i.flag<<1|(o<0&&8),t[n++]=e&&8,t[n++]=255&i.compression,t[n++]=i.compression>>8;var v=new Date(null==i.mtime?Date.now():i.mtime),l=v.getFullYear()-1980;if((l<0||l>119)&&F(10),ct(t,n,l<<25|v.getMonth()+1<<21|v.getDate()<<16|v.getHours()<<11|v.getMinutes()<<5|v.getSeconds()>>1),n+=4,-1!=o&&(ct(t,n,i.crc),ct(t,n+4,o<0?-o-2:o),ct(t,n+8,i.size)),ct(t,n+12,u),ct(t,n+14,c),n+=16,null!=s&&(ct(t,n,h),ct(t,n+6,i.attrs),ct(t,n+10,s),n+=14),t.set(r,n),n+=u,c)for(var p in a){var w=a[p],d=w.length;ct(t,n,+p),ct(t,n+2,d),t.set(w,n+4),n+=4+d}return h&&(t.set(f,n),n+=h),n},sn=function(t,n,i,r,e){ct(t,n,101010256),ct(t,n+8,i),ct(t,n+10,i),ct(t,n+12,r),ct(t,n+16,e)},fn=function(){function t(t){this.filename=t,this.c=Z(),this.size=0,this.compression=0}return t.prototype.process=function(t,n){this.ondata(null,t,n)},t.prototype.push=function(t,n){this.ondata||F(5),this.c.p(t),this.size+=t.length,n&&(this.crc=this.c.d()),this.process(t,n||0)},t}(),un=function(){function t(t,n){var i=this;n||(n={}),fn.call(this,t),this.d=new mt(n,function(t,n){i.ondata(null,t,n)}),this.compression=8,this.flag=_t(n.level)}return t.prototype.process=function(t,n){try{this.d.push(t,n)}catch(t){this.ondata(t,null,n)}},t.prototype.push=function(t,n){fn.prototype.push.call(this,t,n)},t}(),an=function(){function t(t,n){var i=this;n||(n={}),fn.call(this,t),this.d=new gt(n,function(t,n,r){i.ondata(t,n,r)}),this.compression=8,this.flag=_t(n.level),this.terminate=this.d.terminate}return t.prototype.process=function(t,n){this.d.push(t,n)},t.prototype.push=function(t,n){fn.prototype.push.call(this,t,n)},t}(),hn=function(){function t(t){this.ondata=t,this.u=[],this.d=1}return t.prototype.add=function(t){var i=this;if(this.ondata||F(5),2&this.d)this.ondata(F(4+8*(1&this.d),0,1),null,0);else{var r=Xt(t.filename),e=r.length,o=t.comment,s=o&&Xt(o),f=e!=t.filename.length||s&&o.length!=s.length,u=e+en(t.extra)+30;e>65535&&this.ondata(F(11,0,1),null,0);var a=new n(u);on(a,0,t,r,f,-1);var h=[a],c=function(){for(var t=0,n=h;t<n.length;t++)i.ondata(null,n[t],0);h=[]},v=this.d;this.d=0;var l=this.u.length,p=K(t,{f:r,u:f,o:s,t:function(){t.terminate&&t.terminate()},r:function(){if(c(),v){var t=i.u[l+1];t?t.r():i.d=1}v=1}}),w=0;t.ondata=function(r,e,o){if(r)i.ondata(r,e,o),i.terminate();else if(w+=e.length,h.push(e),o){var s=new n(16);ct(s,0,134695760),ct(s,4,t.crc),ct(s,8,w),ct(s,12,t.size),h.push(s),p.c=w,p.b=u+w+16,p.crc=t.crc,p.size=t.size,v&&p.r(),v=1}else v&&c()},this.u.push(p)}},t.prototype.end=function(){var t=this;2&this.d?this.ondata(F(4+8*(1&this.d),0,1),null,1):(this.d?this.e():this.u.push({r:function(){1&t.d&&(t.u.splice(-1,1),t.e())},t:function(){}}),this.d=3)},t.prototype.e=function(){for(var t=0,i=0,r=0,e=0,o=this.u;e<o.length;e++)r+=46+(a=o[e]).f.length+en(a.extra)+(a.o?a.o.length:0);for(var s=new n(r+22),f=0,u=this.u;f<u.length;f++){var a;on(s,t,a=u[f],a.f,a.u,-a.c-2,i,a.o),t+=46+a.f.length+en(a.extra)+(a.o?a.o.length:0),i+=a.b}sn(s,t,this.u.length,r,i),this.ondata(null,s,1),this.d=2},t.prototype.terminate=function(){for(var t=0,n=this.u;t<n.length;t++)n[t].t();this.d=2},t}(),cn=function(){function t(){}return t.prototype.push=function(t,n){this.ondata(null,t,n)},t.compression=0,t}(),vn=function(){function t(){var t=this;this.i=new bt(function(n,i){t.ondata(null,n,i)})}return t.prototype.push=function(t,n){try{this.i.push(t,n)}catch(t){this.ondata(t,null,n)}},t.compression=8,t}(),ln=function(){function t(t,n){var i=this;n<32e4?this.i=new bt(function(t,n){i.ondata(null,t,n)}):(this.i=new zt(function(t,n,r){i.ondata(t,n,r)}),this.terminate=this.i.terminate)}return t.prototype.push=function(t,n){this.i.terminate&&(t=I(t,0)),this.i.push(t,n)},t.compression=8,t}(),pn=function(){function t(t){this.onfile=t,this.k=[],this.o={0:cn},this.p=$}return t.prototype.push=function(t,i){var r=this;if(this.onfile||F(5),this.p||F(4),this.c>0){var e=Math.min(this.c,t.length),o=t.subarray(0,e);if(this.c-=e,this.d?this.d.push(o,!this.c):this.k[0].push(o),(t=t.subarray(e)).length)return this.push(t,i)}else{var s=0,f=0,u=void 0,a=void 0;this.p.length?t.length?((a=new n(this.p.length+t.length)).set(this.p),a.set(t,this.p.length)):a=this.p:a=t;for(var h=a.length,c=this.c,v=c&&this.d,l=function(){var t,n=at(a,f);if(67324752==n){s=1,u=f,p.d=null,p.c=0;var i=ut(a,f+6),e=ut(a,f+8),o=2048&i,v=8&i,l=ut(a,f+26),w=ut(a,f+28);if(h>f+30+l+w){var d=[];p.k.unshift(d),s=2;var x,y=at(a,f+18),m=at(a,f+22),g=Yt(a.subarray(f+30,f+=30+l),!o);4294967295==y?(t=v?[-2]:rn(a,f),y=t[0],m=t[1]):v&&(y=-1),f+=w,p.c=y;var k={name:g,compression:e,start:function(){if(k.ondata||F(5),y){var t=r.o[e];t||k.ondata(F(14,"unknown compression type "+e,1),null,0),(x=y<0?new t(g):new t(g,y,m)).ondata=function(t,n,i){k.ondata(t,n,i)};for(var n=0,i=d;n<i.length;n++)x.push(i[n],0);r.k[0]==d&&r.c?r.d=x:x.push($,1)}else k.ondata(null,$,1)},terminate:function(){x&&x.terminate&&x.terminate()}};y>=0&&(k.size=y,k.originalSize=m),p.onfile(k)}return"break"}if(c){if(134695760==n)return u=f+=12+(-2==c&&8),s=3,p.c=0,"break";if(33639248==n)return u=f-=4,s=3,p.c=0,"break"}},p=this;f<h-4&&"break"!==l();++f);if(this.p=$,c<0){var w=a.subarray(0,s?u-12-(-2==c&&8)-(134695760==at(a,u-16)&&4):f);v?v.push(w,!!s):this.k[+(2==s)].push(w)}if(2&s)return this.push(a.subarray(f),i);this.p=a.subarray(f)}i&&(this.c&&F(13),this.p=null)},t.prototype.register=function(t){this.o[t.compression]=t},t}(),wn="function"==typeof queueMicrotask?queueMicrotask:"function"==typeof setTimeout?setTimeout:function(t){t()};exports.AsyncCompress=It,exports.AsyncDecompress=Wt,exports.AsyncDeflate=gt,exports.AsyncGunzip=Ut,exports.AsyncGzip=It,exports.AsyncInflate=zt,exports.AsyncUnzipInflate=ln,exports.AsyncUnzlib=Ht,exports.AsyncZipDeflate=an,exports.AsyncZlib=qt,exports.Compress=Et,exports.DecodeUTF8=Qt,exports.Decompress=Rt,exports.Deflate=mt,exports.EncodeUTF8=Vt,exports.FlateErrorCode={UnexpectedEOF:0,InvalidBlockType:1,InvalidLengthLiteral:2,InvalidDistance:3,StreamFinished:4,NoStreamHandler:5,InvalidHeader:6,NoCallback:7,InvalidUTF8:8,ExtraFieldTooLong:9,InvalidDate:10,FilenameTooLong:11,StreamFinishing:12,InvalidZipData:13,UnknownCompressionMethod:14},exports.Gunzip=At,exports.Gzip=Et,exports.Inflate=bt,exports.Unzip=pn,exports.UnzipInflate=vn,exports.UnzipPassThrough=cn,exports.Unzlib=Ct,exports.Zip=hn,exports.ZipDeflate=un,exports.ZipPassThrough=fn,exports.Zlib=jt,exports.compress=St,exports.compressSync=Ft,exports.decompress=function(t,n,i){return i||(i=n,n={}),"function"!=typeof i&&F(7),31==t[0]&&139==t[1]&&8==t[2]?Lt(t,n,i):8!=(15&t[0])||t[0]>>4>7||(t[0]<<8|t[1])%31?Tt(t,n,i):Nt(t,n,i)},exports.decompressSync=function(t,n){return 31==t[0]&&139==t[1]&&8==t[2]?Ot(t,n):8!=(15&t[0])||t[0]>>4>7||(t[0]<<8|t[1])%31?Dt(t,n):$t(t,n)},exports.deflate=kt,exports.deflateSync=Mt,exports.gunzip=Lt,exports.gunzipSync=Ot,exports.gzip=St,exports.gzipSync=Ft,exports.inflate=Tt,exports.inflateSync=Dt,exports.strFromU8=Yt,exports.strToU8=Xt,exports.unzip=function(t,i,r){r||(r=i,i={}),"function"!=typeof r&&F(7);var e=[],o=function(){for(var t=0;t<e.length;++t)e[t]()},s={},f=function(t,n){wn(function(){r(t,n)})};wn(function(){f=r});for(var u=t.length-22;101010256!=at(t,u);--u)if(!u||t.length-u>65558)return f(F(13,0,1),null),o;var a=ut(t,u+8);if(a){var h=a,c=at(t,u+16),v=4294967295==c||65535==h;if(v){var l=at(t,u-12);(v=101075792==at(t,l))&&(h=a=at(t,l+32),c=at(t,l+48))}for(var p=i&&i.filter,w=function(i){var r=nn(t,c,v),u=r[0],h=r[1],l=r[2],w=r[3],d=r[4],x=tn(t,r[5]);c=d;var y=function(t,n){t?(o(),f(t,null)):(n&&(s[w]=n),--a||f(null,s))};if(!p||p({name:w,size:h,originalSize:l,compression:u}))if(u)if(8==u){var m=t.subarray(x,x+h);if(l<524288||h>.8*l)try{y(null,Dt(m,{out:new n(l)}))}catch(t){y(t,null)}else e.push(Tt(m,{size:l},y))}else y(F(14,"unknown compression type "+u,1),null);else y(null,I(t,x,x+h));else y(null,null)},d=0;d<h;++d)w()}else f(null,{});return o},exports.unzipSync=function(t,i){for(var r={},e=t.length-22;101010256!=at(t,e);--e)(!e||t.length-e>65558)&&F(13);var o=ut(t,e+8);if(!o)return{};var s=at(t,e+16),f=4294967295==s||65535==o;if(f){var u=at(t,e-12);(f=101075792==at(t,u))&&(o=at(t,u+32),s=at(t,u+48))}for(var a=i&&i.filter,h=0;h<o;++h){var c=nn(t,s,f),v=c[0],l=c[1],p=c[2],w=c[3],d=c[4],x=tn(t,c[5]);s=d,a&&!a({name:w,size:l,originalSize:p,compression:v})||(v?8==v?r[w]=Dt(t.subarray(x,x+l),{out:new n(p)}):F(14,"unknown compression type "+v):r[w]=I(t,x,x+l))}return r},exports.unzlib=Nt,exports.unzlibSync=$t,exports.zip=function(t,i,r){r||(r=i,i={}),"function"!=typeof r&&F(7);var e={};Zt(t,"",e,i);var o=Object.keys(e),s=o.length,f=0,u=0,a=s,h=new Array(s),c=[],v=function(){for(var t=0;t<c.length;++t)c[t]()},l=function(t,n){wn(function(){r(t,n)})};wn(function(){l=r});var p=function(){var t=new n(u+22),i=f,r=u-f;u=0;for(var e=0;e<a;++e){var o=h[e];try{var s=o.c.length;on(t,u,o,o.f,o.u,s);var c=30+o.f.length+en(o.extra),v=u+c;t.set(o.c,v),on(t,f,o,o.f,o.u,s,u,o.m),f+=16+c+(o.m?o.m.length:0),u=v+s}catch(t){return l(t,null)}}sn(t,f,h.length,r,i),l(null,t)};s||p();for(var w=function(t){var n=o[t],i=e[n],r=i[0],a=i[1],w=Z(),d=r.length;w.p(r);var x=Xt(n),y=x.length,m=a.comment,g=m&&Xt(m),k=g&&g.length,M=en(a.extra),b=0==a.level?0:8,z=function(i,r){if(i)v(),l(i,null);else{var e=r.length;h[t]=K(a,{size:d,crc:w.d(),c:r,f:x,m:g,u:y!=n.length||g&&m.length!=k,compression:b}),f+=30+y+M+e,u+=76+2*(y+M)+(k||0)+e,--s||p()}};if(y>65535&&z(F(11,0,1),null),b)if(d<16e4)try{z(null,Mt(r,a))}catch(t){z(t,null)}else c.push(kt(r,a,z));else z(null,r)},d=0;d<a;++d)w(d);return v},exports.zipSync=function(t,i){i||(i={});var r={},e=[];Zt(t,"",r,i);var o=0,s=0;for(var f in r){var u=r[f],a=u[0],h=u[1],c=0==h.level?0:8,v=(z=Xt(f)).length,l=h.comment,p=l&&Xt(l),w=p&&p.length,d=en(h.extra);v>65535&&F(11);var x=c?Mt(a,h):a,y=x.length,m=Z();m.p(a),e.push(K(h,{size:a.length,crc:m.d(),c:x,f:z,m:p,u:v!=f.length||p&&l.length!=w,o:o,compression:c})),o+=30+v+d+y,s+=76+2*(v+d)+(w||0)+y}for(var g=new n(s+22),k=o,M=s-o,b=0;b<e.length;++b){var z;on(g,(z=e[b]).o,z,z.f,z.u,z.c.length);var T=30+z.f.length+en(z.extra);g.set(z.c,z.o+T),on(g,o,z,z.f,z.u,z.c.length,z.o,z.m),o+=16+T+(z.m?z.m.length:0)}return sn(g,o,e.length,M,k),g},exports.zlib=function(t,n,i){return i||(i=n,n={}),"function"!=typeof i&&F(7),ot(t,n,[Y,nt,function(){return[Bt]}],function(t){return rt(Bt(t.data[0],t.data[1]))},4,i)},exports.zlibSync=Bt;