"use strict";(globalThis.webpackChunk_affine_web=globalThis.webpackChunk_affine_web||[]).push([[2394],{24899:(r,e,t)=>{t.d(e,{p6:()=>m,KQ:()=>q,sD:()=>n});for(var n,i=t(78530),a=t.n(i),o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",f=new Uint8Array(256),u=0;u>4,l[c++]=(15&n)<<4|i>>2,l[c++]=(3&i)<<6|63&a;return l},l=function(r){for(var e="",t=0;t{t.d(e,{A:()=>o});var n=t(78530),i=t.n(n),a={};a.toRGBA8=function(r){var e=r.width,t=r.height;if(null==r.tabs.acTL)return[a.toRGBA8.decodeImage(r.data,e,t,r).buffer];var n=[];null==r.frames[0].data&&(r.frames[0].data=r.data);for(var i=e*t*4,o=new Uint8Array(i),f=new Uint8Array(i),u=new Uint8Array(i),c=0;c>3)]>>7-((7&s)<<0)&1,K=3*N;f[U]=R[K],f[U+1]=R[K+1],f[U+2]=R[K+2],f[U+3]=N>2)]>>6-((3&s)<<1)&3,K=3*N;f[U]=R[K],f[U+1]=R[K+1],f[U+2]=R[K+2],f[U+3]=N>1)]>>4-((1&s)<<2)&15,K=3*N;f[U]=R[K],f[U+1]=R[K+1],f[U+2]=R[K+2],f[U+3]=N>>3)]>>>7-(7&x)&1),M=g==255*h?0:255;u[T+x]=M<<24|g<<16|g<<8|g}else if(2==l)for(var x=0;x>>2)]>>>6-((3&x)<<1)&3),M=g==85*h?0:255;u[T+x]=M<<24|g<<16|g<<8|g}else if(4==l)for(var x=0;x>>1)]>>>4-((1&x)<<2)&15),M=g==17*h?0:255;u[T+x]=M<<24|g<<16|g<<8|g}else if(8==l)for(var x=0;x>>2<<3));0==o;){if(o=h(r,V,1),f=h(r,V+1,2),V+=3,0==f){(7&V)!=0&&(V+=8-(7&V));var G=(V>>>3)+4,O=r[G-4]|r[G-3]<<8;X&&(e=t.H.W(e,s+O)),e.set(new a(r.buffer,r.byteOffset+G,O),s),V=G+O<<3,s+=O;continue}if(X&&(e=t.H.W(e,s+131072)),1==f&&(n=p.J,i=p.h,v=511,d=31),2==f){u=y(r,V,5)+257,c=y(r,V+5,5)+1,l=y(r,V+10,4)+4,V+=14;for(var N=1,K=0;K<38;K+=2)p.Q[K]=0,p.Q[K+1]=0;for(var K=0;KN&&(N=j)}V+=3*l,U(p.Q,N),R(p.Q,N,p.u),n=p.w,i=p.d,V=m(p.u,(1<>>4;if(x>>>8==0)e[s++]=x;else if(256==x)break;else{var M=s+x-254;if(x>264){var z=p.q[x-257];M=s+(z>>>3)+y(r,V,7&z),V+=7&z}var P=i[F(r,V)&d];V+=15&P;var W=P>>>4,H=p.c[W],S=(H>>>4)+h(r,V,15&H);for(V+=15&H;s>>4;if(v<=15)o[c]=v,c++;else{var d=0,s=0;16==v?(s=3+f(i,a,2),a+=2,d=o[c-1]):17==v?(s=3+f(i,a,3),a+=3):18==v&&(s=11+f(i,a,7),a+=7);for(var V=c+s;c>>1;ai&&(i=f),a++}for(;a>1,u=r[o+1],c=f<<4|u,l=e-u,v=r[o]<>>15-e]=c,v++},t.H.l=function(r,e){for(var n=t.H.m.r,i=15-e,a=0;a>>i}},t.H.M=function(r,e,t){t<<=7&e;var n=e>>>3;r[n]|=t,r[n+1]|=t>>>8},t.H.I=function(r,e,t){t<<=7&e;var n=e>>>3;r[n]|=t,r[n+1]|=t>>>8,r[n+2]|=t>>>16},t.H.e=function(r,e,t){return(r[e>>>3]|r[(e>>>3)+1]<<8)>>>(7&e)&(1<>>3]|r[(e>>>3)+1]<<8|r[(e>>>3)+2]<<16)>>>(7&e)&(1<>>3]|r[(e>>>3)+1]<<8|r[(e>>>3)+2]<<16)>>>(7&e)},t.H.i=function(r,e){return(r[e>>>3]|r[(e>>>3)+1]<<8|r[(e>>>3)+2]<<16|r[(e>>>3)+3]<<24)>>>(7&e)},t.H.m=(r=Uint16Array,e=Uint32Array,{K:new r(16),j:new r(16),X:[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],S:[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,999,999,999],T:[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],q:new r(32),p:[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,65535,65535],z:[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],c:new e(32),J:new r(512),_:[],h:new r(32),$:[],w:new r(32768),C:[],v:[],d:new r(32768),D:[],u:new r(512),Q:[],r:new r(32768),s:new e(286),Y:new e(30),a:new e(19),t:new e(15e3),k:new r(65536),g:new r(32768)}),function(){for(var r=t.H.m,e=0;e<32768;e++){var n=e;n=(4278255360&(n=(4042322160&(n=(3435973836&(n=(2863311530&n)>>>1|(1431655765&n)<<1))>>>2|(858993459&n)<<2))>>>4|(252645135&n)<<4))>>>8|(16711935&n)<<8,r.r[e]=(n>>>16|n<<16)>>>17}function i(r,e,t){for(;0!=e--;)r.push(0,t)}for(var e=0;e<32;e++)r.q[e]=r.S[e]<<3|r.T[e],r.c[e]=r.p[e]<<4|r.z[e];i(r._,144,8),i(r._,112,9),i(r._,24,7),i(r._,8,8),t.H.n(r._,9),t.H.A(r._,9,r.J),t.H.l(r._,9),i(r.$,32,5),t.H.n(r.$,5),t.H.A(r.$,5,r.h),t.H.l(r.$,5),i(r.Q,19,0),i(r.C,286,0),i(r.D,30,0),i(r.v,320,0)}(),t.H.N}(),a.decode._readInterlace=function(r,e){for(var t=e.width,n=e.height,i=a.decode._getBPP(e),o=i>>3,f=Math.ceil(t*i/8),u=new Uint8Array(n*f),c=0,l=[0,0,4,0,2,0,1],v=[0,4,0,2,0,1,0],d=[8,8,8,4,4,2,2],s=[8,8,4,4,2,2,1],V=0;V<7;){for(var q=d[V],h=s[V],y=0,m=0,U=l[V];U>3];N=N>>7-(7&O)&1,u[X*f+(G>>3)]|=N<<7-((7&G)<<0)}if(2==i){var N=r[O>>3];N=N>>6-(7&O)&3,u[X*f+(G>>2)]|=N<<6-((3&G)<<1)}if(4==i){var N=r[O>>3];N=N>>4-(7&O)&15,u[X*f+(G>>1)]|=N<<4-((1&G)<<2)}if(i>=8)for(var K=X*f+G*o,j=0;j>3)+j];O+=i,G+=h}p++,X+=q}y*m!=0&&(c+=m*(1+F)),V+=1}return u},a.decode._getBPP=function(r){return[1,null,3,1,2,null,4][r.ctype]*r.depth},a.decode._filterZero=function(r,e,t,n,i){var o=a.decode._getBPP(e),f=Math.ceil(n*o/8),u=a.decode._paeth;o=Math.ceil(o/8);var c=0,l=1,v=r[t],d=0;if(v>1&&(r[t]=[0,0,1][v-2]),3==v)for(d=o;d>>1)&255;for(var s=0;s>>1);for(;d>>1)}else{for(;d>8&255,r[e+1]=255&t},readUint:function(r,e){return 16777216*r[e]+(r[e+1]<<16|r[e+2]<<8|r[e+3])},writeUint:function(r,e,t){r[e]=t>>24&255,r[e+1]=t>>16&255,r[e+2]=t>>8&255,r[e+3]=255&t},readASCII:function(r,e,t){for(var n="",i=0;i=0&&f>=0?(v=s*e+V<<2,d=(f+s)*i+o+V<<2):(v=(-f+s)*e-o+V<<2,d=s*i+V<<2),0==u)n[d]=r[v],n[d+1]=r[v+1],n[d+2]=r[v+2],n[d+3]=r[v+3];else if(1==u){var q=r[v+3]*(1/255),h=r[v]*q,y=r[v+1]*q,m=r[v+2]*q,U=n[d+3]*(1/255),R=n[d]*U,F=n[d+1]*U,p=n[d+2]*U,X=1-q,G=q+U*X,O=0==G?0:1/G;n[d+3]=255*G,n[d+0]=(h+R*X)*O,n[d+1]=(y+F*X)*O,n[d+2]=(m+p*X)*O}else if(2==u){var q=r[v+3],h=r[v],y=r[v+1],m=r[v+2],U=n[d+3],R=n[d],F=n[d+1],p=n[d+2];q==U&&h==R&&y==F&&m==p?(n[d]=0,n[d+1]=0,n[d+2]=0,n[d+3]=0):(n[d]=h,n[d+1]=y,n[d+2]=m,n[d+3]=q)}else if(3==u){var q=r[v+3],h=r[v],y=r[v+1],m=r[v+2],U=n[d+3],R=n[d],F=n[d+1],p=n[d+2];if(q==U&&h==R&&y==F&&m==p)continue;if(q<220&&U>20)return!1}return!0},a.encode=function(r,e,t,n,i,o,f){null==n&&(n=0),null==f&&(f=!1);var u=a.encode.compress(r,e,t,n,[!1,!1,!1,0,f]);return a.encode.compressPNG(u,-1),a.encode._main(u,e,t,i,o)},a.encodeLL=function(r,e,t,n,i,o,f,u){var c={ctype:0+(1==n?0:2)+(0==i?0:4),depth:o,frames:[]};Date.now();for(var l=(n+i)*o,v=l*e,d=0;d1,d=!1,s=33+(v?20:0);if(null!=i.sRGB&&(s+=13),null!=i.pHYs&&(s+=21),3==r.ctype){for(var V=r.plte.length,q=0;q>>24!=255&&(d=!0);s+=8+3*V+4+(d?8+1*V+4:0)}for(var h=0;h>>8&255,G=F>>>16&255;m[l+R+0]=p,m[l+R+1]=X,m[l+R+2]=G}if(f(m,l+=3*V,o(m,l-3*V-4,3*V+4)),l+=4,d){f(m,l,V),c(m,l+=4,"tRNS"),l+=4;for(var q=0;q>>24&255;f(m,l+=V,o(m,l-V-4,V+4)),l+=4}}for(var O=0,h=0;h>2,g>>2));for(var V=0;Vx&&z==T[y-x])M[y]=M[y-x];else{var P=R[z];if(null==P&&(R[z]=P=F.length,F.push(z),F.length>=300))break;M[y]=P}}}var W=F.length;W<=256&&!1==l&&(d=Math.max(d=W<=2?1:W<=4?2:W<=16?4:8,c));for(var V=0;V>1)]|=k[Y+L]<<4-(1&L)*4;else if(2==d)for(var L=0;L>2)]|=k[Y+L]<<6-(3&L)*2;else if(1==d)for(var L=0;L>3)]|=k[Y+L]<<7-(7&L)*1}S=I,v=3,Z=1}else if(!1==m&&1==U.length){for(var I=new Uint8Array(x*H*3),J=x*H,y=0;yO&&(O=j),KN&&(N=K))}-1==O&&(X=G=O=N=0),i&&((1&X)==1&&X--,(1&G)==1&&G--);var b=(O-X+1)*(N-G+1);by&&(y=F),pm&&(m=p))}-1==y&&(q=h=y=m=0),f&&((1&q)==1&&q--,(1&h)==1&&h--),o={x:q,y:h,width:y-q+1,height:m-h+1};var O=n[i];O.rect=o,O.blend=1,O.img=new Uint8Array(o.width*o.height*4),0==n[i-1].dispose?(a._copyTile(l,e,t,O.img,o.width,o.height,-o.x,-o.y,0),a.encode._prepareDiff(s,e,t,O.img,o)):a._copyTile(s,e,t,O.img,o.width,o.height,-o.x,-o.y,0)},a.encode._prepareDiff=function(r,e,t,n,i){a._copyTile(r,e,t,n,i.width,i.height,-i.x,-i.y,2)},a.encode._filterZero=function(r,e,t,n,o,f,u){var c=[],l=[0,1,2,3,4];-1!=f?l=[f]:(e*n>5e5||1==t)&&(l=[0]),u&&(V={level:0});for(var v=u&&null!=UZIP?UZIP:i(),d=0;d>1)+256&255;if(4==o)for(var l=i;l>1)&255;for(var l=i;l>1)&255}if(4==o){for(var l=0;l>>1:t>>>=1;r[e]=t}return r}(),update:function(r,e,t,n){for(var i=0;i>>8;return r},crc:function(r,e,t){return 4294967295^a.crc.update(4294967295,r,e,t)}},a.quantize=function(r,e){var t=new Uint8Array(r),n=t.slice(0),i=new Uint32Array(n.buffer),o=a.quantize.getKDtree(n,e),f=o[0],u=o[1];a.quantize.planeDst;for(var c=t.length,l=new Uint8Array(t.length>>2),v=0;v>2]=h.ind,i[v>>2]=h.est.rgba}return{abuf:n.buffer,inds:l,plte:u}},a.quantize.getKDtree=function(r,e,t){null==t&&(t=1e-4);var n=new Uint32Array(r.buffer),i={i0:0,i1:r.length,bst:null,est:null,tdst:0,left:null,right:null};i.bst=a.quantize.stats(r,i.i0,i.i1),i.est=a.quantize.estats(i.bst);for(var o=[i];o.lengthf&&(f=o[c].est.L,u=c);if(f=v||l.i1<=v){l.est.L=0;continue}var d={i0:l.i0,i1:v,bst:null,est:null,tdst:0,left:null,right:null};d.bst=a.quantize.stats(r,d.i0,d.i1),d.est=a.quantize.estats(d.bst);var s={i0:v,i1:l.i1,bst:null,est:null,tdst:0,left:null,right:null};s.bst={R:[],m:[],N:l.bst.N-d.bst.N};for(var c=0;c<16;c++)s.bst.R[c]=l.bst.R[c]-d.bst.R[c];for(var c=0;c<4;c++)s.bst.m[c]=l.bst.m[c]-d.bst.m[c];s.est=a.quantize.estats(s.bst),l.left=d,l.right=s,o[u]=d,o.push(s)}o.sort(function(r,e){return e.bst.N-r.bst.N});for(var c=0;c0&&(f=r.right,u=r.left);var c=a.quantize.getNearest(f,e,t,n,i);if(c.tdst<=o*o)return c;var l=a.quantize.getNearest(u,e,t,n,i);return l.tdsto;)n-=4;if(t>=n)break;var u=e[t>>2];e[t>>2]=e[n>>2],e[n>>2]=u,t+=4,n-=4}for(;f(r,t,i)>o;)t-=4;return t+4},a.quantize.vecDot=function(r,e,t){return r[e]*t[0]+r[e+1]*t[1]+r[e+2]*t[2]+r[e+3]*t[3]},a.quantize.stats=function(r,e,t){for(var n=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],i=[0,0,0,0],a=e;a>2}},a.quantize.estats=function(r){var e=r.R,t=r.m,n=r.N,i=t[0],o=t[1],f=t[2],u=t[3],c=0==n?0:1/n,l=[e[0]-i*i*c,e[1]-i*o*c,e[2]-i*f*c,e[3]-i*u*c,e[4]-o*i*c,e[5]-o*o*c,e[6]-o*f*c,e[7]-o*u*c,e[8]-f*i*c,e[9]-f*o*c,e[10]-f*f*c,e[11]-f*u*c,e[12]-u*i*c,e[13]-u*o*c,e[14]-u*f*c,e[15]-u*u*c],v=a.M4,d=[.5,.5,.5,.5],s=0,V=0;if(0!=n)for(var q=0;q<10&&(d=v.multVec(l,d),V=Math.sqrt(v.dot(d,d)),d=v.sml(1/V,d),!(1e-9>Math.abs(V-s)));q++)s=V;var h=[i*c,o*c,f*c,u*c],y=v.dot(v.sml(255,h),d);return{Cov:l,q:h,e:d,L:s,eMq255:y,eMq:v.dot(d,h),rgba:(Math.round(255*h[3])<<24|Math.round(255*h[2])<<16|Math.round(255*h[1])<<8|Math.round(255*h[0])<<0)>>>0}},a.M4={multVec:function(r,e){return[r[0]*e[0]+r[1]*e[1]+r[2]*e[2]+r[3]*e[3],r[4]*e[0]+r[5]*e[1]+r[6]*e[2]+r[7]*e[3],r[8]*e[0]+r[9]*e[1]+r[10]*e[2]+r[11]*e[3],r[12]*e[0]+r[13]*e[1]+r[14]*e[2]+r[15]*e[3]]},dot:function(r,e){return r[0]*e[0]+r[1]*e[1]+r[2]*e[2]+r[3]*e[3]},sml:function(r,e){return[r*e[0],r*e[1],r*e[2],r*e[3]]}},a.encode.concatRGBA=function(r){for(var e=0,t=0;t