/*! Copyright (c) 2022 WhatsApp Inc. All Rights Reserved. */ (self.webpackChunkwhatsapp_web_client=self.webpackChunkwhatsapp_web_client||[]).push([[6177],{214462:(e,t,n)=>{!function(e){"use strict";var t=function(e){var t,n=new Float64Array(16);if(e)for(t=0;t>24&255,e[t+1]=n>>16&255,e[t+2]=n>>8&255,e[t+3]=255&n,e[t+4]=r>>24&255,e[t+5]=r>>16&255,e[t+6]=r>>8&255,e[t+7]=255&r}function m(e,t,n,r,i){var o,a=0;for(o=0;o>>8)-1}function v(e,t,n,r){return m(e,t,n,r,16)}function g(e,t,n,r){return m(e,t,n,r,32)}function y(e,t,n,r){!function(e,t,n,r){for(var i,o=255&r[0]|(255&r[1])<<8|(255&r[2])<<16|(255&r[3])<<24,a=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,s=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,u=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,l=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,c=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,f=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,d=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,h=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,p=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,m=255&r[8]|(255&r[9])<<8|(255&r[10])<<16|(255&r[11])<<24,v=255&n[16]|(255&n[17])<<8|(255&n[18])<<16|(255&n[19])<<24,g=255&n[20]|(255&n[21])<<8|(255&n[22])<<16|(255&n[23])<<24,y=255&n[24]|(255&n[25])<<8|(255&n[26])<<16|(255&n[27])<<24,b=255&n[28]|(255&n[29])<<8|(255&n[30])<<16|(255&n[31])<<24,w=255&r[12]|(255&r[13])<<8|(255&r[14])<<16|(255&r[15])<<24,_=o,x=a,S=s,E=u,k=l,O=c,T=f,A=d,M=h,N=p,R=m,P=v,C=g,D=y,U=b,I=w,j=0;j<20;j+=2)_^=(i=(C^=(i=(M^=(i=(k^=(i=_+C|0)<<7|i>>>25)+_|0)<<9|i>>>23)+k|0)<<13|i>>>19)+M|0)<<18|i>>>14,O^=(i=(x^=(i=(D^=(i=(N^=(i=O+x|0)<<7|i>>>25)+O|0)<<9|i>>>23)+N|0)<<13|i>>>19)+D|0)<<18|i>>>14,R^=(i=(T^=(i=(S^=(i=(U^=(i=R+T|0)<<7|i>>>25)+R|0)<<9|i>>>23)+U|0)<<13|i>>>19)+S|0)<<18|i>>>14,I^=(i=(P^=(i=(A^=(i=(E^=(i=I+P|0)<<7|i>>>25)+I|0)<<9|i>>>23)+E|0)<<13|i>>>19)+A|0)<<18|i>>>14,_^=(i=(E^=(i=(S^=(i=(x^=(i=_+E|0)<<7|i>>>25)+_|0)<<9|i>>>23)+x|0)<<13|i>>>19)+S|0)<<18|i>>>14,O^=(i=(k^=(i=(A^=(i=(T^=(i=O+k|0)<<7|i>>>25)+O|0)<<9|i>>>23)+T|0)<<13|i>>>19)+A|0)<<18|i>>>14,R^=(i=(N^=(i=(M^=(i=(P^=(i=R+N|0)<<7|i>>>25)+R|0)<<9|i>>>23)+P|0)<<13|i>>>19)+M|0)<<18|i>>>14,I^=(i=(U^=(i=(D^=(i=(C^=(i=I+U|0)<<7|i>>>25)+I|0)<<9|i>>>23)+C|0)<<13|i>>>19)+D|0)<<18|i>>>14;_=_+o|0,x=x+a|0,S=S+s|0,E=E+u|0,k=k+l|0,O=O+c|0,T=T+f|0,A=A+d|0,M=M+h|0,N=N+p|0,R=R+m|0,P=P+v|0,C=C+g|0,D=D+y|0,U=U+b|0,I=I+w|0,e[0]=_>>>0&255,e[1]=_>>>8&255,e[2]=_>>>16&255,e[3]=_>>>24&255,e[4]=x>>>0&255,e[5]=x>>>8&255,e[6]=x>>>16&255,e[7]=x>>>24&255,e[8]=S>>>0&255,e[9]=S>>>8&255,e[10]=S>>>16&255,e[11]=S>>>24&255,e[12]=E>>>0&255,e[13]=E>>>8&255,e[14]=E>>>16&255,e[15]=E>>>24&255,e[16]=k>>>0&255,e[17]=k>>>8&255,e[18]=k>>>16&255,e[19]=k>>>24&255,e[20]=O>>>0&255,e[21]=O>>>8&255,e[22]=O>>>16&255,e[23]=O>>>24&255,e[24]=T>>>0&255,e[25]=T>>>8&255,e[26]=T>>>16&255,e[27]=T>>>24&255,e[28]=A>>>0&255,e[29]=A>>>8&255,e[30]=A>>>16&255,e[31]=A>>>24&255,e[32]=M>>>0&255,e[33]=M>>>8&255,e[34]=M>>>16&255,e[35]=M>>>24&255,e[36]=N>>>0&255,e[37]=N>>>8&255,e[38]=N>>>16&255,e[39]=N>>>24&255,e[40]=R>>>0&255,e[41]=R>>>8&255,e[42]=R>>>16&255,e[43]=R>>>24&255,e[44]=P>>>0&255,e[45]=P>>>8&255,e[46]=P>>>16&255,e[47]=P>>>24&255,e[48]=C>>>0&255,e[49]=C>>>8&255,e[50]=C>>>16&255,e[51]=C>>>24&255,e[52]=D>>>0&255,e[53]=D>>>8&255,e[54]=D>>>16&255,e[55]=D>>>24&255,e[56]=U>>>0&255,e[57]=U>>>8&255,e[58]=U>>>16&255,e[59]=U>>>24&255,e[60]=I>>>0&255,e[61]=I>>>8&255,e[62]=I>>>16&255,e[63]=I>>>24&255}(e,t,n,r)}function b(e,t,n,r){!function(e,t,n,r){for(var i,o=255&r[0]|(255&r[1])<<8|(255&r[2])<<16|(255&r[3])<<24,a=255&n[0]|(255&n[1])<<8|(255&n[2])<<16|(255&n[3])<<24,s=255&n[4]|(255&n[5])<<8|(255&n[6])<<16|(255&n[7])<<24,u=255&n[8]|(255&n[9])<<8|(255&n[10])<<16|(255&n[11])<<24,l=255&n[12]|(255&n[13])<<8|(255&n[14])<<16|(255&n[15])<<24,c=255&r[4]|(255&r[5])<<8|(255&r[6])<<16|(255&r[7])<<24,f=255&t[0]|(255&t[1])<<8|(255&t[2])<<16|(255&t[3])<<24,d=255&t[4]|(255&t[5])<<8|(255&t[6])<<16|(255&t[7])<<24,h=255&t[8]|(255&t[9])<<8|(255&t[10])<<16|(255&t[11])<<24,p=255&t[12]|(255&t[13])<<8|(255&t[14])<<16|(255&t[15])<<24,m=255&r[8]|(255&r[9])<<8|(255&r[10])<<16|(255&r[11])<<24,v=255&n[16]|(255&n[17])<<8|(255&n[18])<<16|(255&n[19])<<24,g=255&n[20]|(255&n[21])<<8|(255&n[22])<<16|(255&n[23])<<24,y=255&n[24]|(255&n[25])<<8|(255&n[26])<<16|(255&n[27])<<24,b=255&n[28]|(255&n[29])<<8|(255&n[30])<<16|(255&n[31])<<24,w=255&r[12]|(255&r[13])<<8|(255&r[14])<<16|(255&r[15])<<24,_=0;_<20;_+=2)o^=(i=(g^=(i=(h^=(i=(l^=(i=o+g|0)<<7|i>>>25)+o|0)<<9|i>>>23)+l|0)<<13|i>>>19)+h|0)<<18|i>>>14,c^=(i=(a^=(i=(y^=(i=(p^=(i=c+a|0)<<7|i>>>25)+c|0)<<9|i>>>23)+p|0)<<13|i>>>19)+y|0)<<18|i>>>14,m^=(i=(f^=(i=(s^=(i=(b^=(i=m+f|0)<<7|i>>>25)+m|0)<<9|i>>>23)+b|0)<<13|i>>>19)+s|0)<<18|i>>>14,w^=(i=(v^=(i=(d^=(i=(u^=(i=w+v|0)<<7|i>>>25)+w|0)<<9|i>>>23)+u|0)<<13|i>>>19)+d|0)<<18|i>>>14,o^=(i=(u^=(i=(s^=(i=(a^=(i=o+u|0)<<7|i>>>25)+o|0)<<9|i>>>23)+a|0)<<13|i>>>19)+s|0)<<18|i>>>14,c^=(i=(l^=(i=(d^=(i=(f^=(i=c+l|0)<<7|i>>>25)+c|0)<<9|i>>>23)+f|0)<<13|i>>>19)+d|0)<<18|i>>>14,m^=(i=(p^=(i=(h^=(i=(v^=(i=m+p|0)<<7|i>>>25)+m|0)<<9|i>>>23)+v|0)<<13|i>>>19)+h|0)<<18|i>>>14,w^=(i=(b^=(i=(y^=(i=(g^=(i=w+b|0)<<7|i>>>25)+w|0)<<9|i>>>23)+g|0)<<13|i>>>19)+y|0)<<18|i>>>14;e[0]=o>>>0&255,e[1]=o>>>8&255,e[2]=o>>>16&255,e[3]=o>>>24&255,e[4]=c>>>0&255,e[5]=c>>>8&255,e[6]=c>>>16&255,e[7]=c>>>24&255,e[8]=m>>>0&255,e[9]=m>>>8&255,e[10]=m>>>16&255,e[11]=m>>>24&255,e[12]=w>>>0&255,e[13]=w>>>8&255,e[14]=w>>>16&255,e[15]=w>>>24&255,e[16]=f>>>0&255,e[17]=f>>>8&255,e[18]=f>>>16&255,e[19]=f>>>24&255,e[20]=d>>>0&255,e[21]=d>>>8&255,e[22]=d>>>16&255,e[23]=d>>>24&255,e[24]=h>>>0&255,e[25]=h>>>8&255,e[26]=h>>>16&255,e[27]=h>>>24&255,e[28]=p>>>0&255,e[29]=p>>>8&255,e[30]=p>>>16&255,e[31]=p>>>24&255}(e,t,n,r)}var w=new Uint8Array([101,120,112,97,110,100,32,51,50,45,98,121,116,101,32,107]);function _(e,t,n,r,i,o,a){var s,u,l=new Uint8Array(16),c=new Uint8Array(64);for(u=0;u<16;u++)l[u]=0;for(u=0;u<8;u++)l[u]=o[u];for(;i>=64;){for(y(c,l,a,w),u=0;u<64;u++)e[t+u]=n[r+u]^c[u];for(s=1,u=8;u<16;u++)s=s+(255&l[u])|0,l[u]=255&s,s>>>=8;i-=64,t+=64,r+=64}if(i>0)for(y(c,l,a,w),u=0;u=64;){for(y(u,s,i,w),a=0;a<64;a++)e[t+a]=u[a];for(o=1,a=8;a<16;a++)o=o+(255&s[a])|0,s[a]=255&o,o>>>=8;n-=64,t+=64}if(n>0)for(y(u,s,i,w),a=0;a>>13|n<<3),r=255&e[4]|(255&e[5])<<8,this.r[2]=7939&(n>>>10|r<<6),i=255&e[6]|(255&e[7])<<8,this.r[3]=8191&(r>>>7|i<<9),o=255&e[8]|(255&e[9])<<8,this.r[4]=255&(i>>>4|o<<12),this.r[5]=o>>>1&8190,a=255&e[10]|(255&e[11])<<8,this.r[6]=8191&(o>>>14|a<<2),s=255&e[12]|(255&e[13])<<8,this.r[7]=8065&(a>>>11|s<<5),u=255&e[14]|(255&e[15])<<8,this.r[8]=8191&(s>>>8|u<<8),this.r[9]=u>>>5&127,this.pad[0]=255&e[16]|(255&e[17])<<8,this.pad[1]=255&e[18]|(255&e[19])<<8,this.pad[2]=255&e[20]|(255&e[21])<<8,this.pad[3]=255&e[22]|(255&e[23])<<8,this.pad[4]=255&e[24]|(255&e[25])<<8,this.pad[5]=255&e[26]|(255&e[27])<<8,this.pad[6]=255&e[28]|(255&e[29])<<8,this.pad[7]=255&e[30]|(255&e[31])<<8};function O(e,t,n,r,i,o){var a=new k(o);return a.update(n,r,i),a.finish(e,t),0}function T(e,t,n,r,i,o){var a=new Uint8Array(16);return O(a,0,n,r,i,o),v(e,t,a,0)}function A(e,t,n,r,i){var o;if(n<32)return-1;for(E(e,0,t,0,n,r,i),O(e,16,e,32,n-32,e),o=0;o<16;o++)e[o]=0;return 0}function M(e,t,n,r,i){var o,a=new Uint8Array(32);if(n<32)return-1;if(S(a,0,32,r,i),0!==T(t,16,t,32,n-32,a))return-1;for(E(e,0,t,0,n,r,i),o=0;o<32;o++)e[o]=0;return 0}function N(e,t){var n;for(n=0;n<16;n++)e[n]=0|t[n]}function R(e){var t,n,r=1;for(t=0;t<16;t++)n=e[t]+r+65535,r=Math.floor(n/65536),e[t]=n-65536*r;e[0]+=r-1+37*(r-1)}function P(e,t,n){for(var r,i=~(n-1),o=0;o<16;o++)r=i&(e[o]^t[o]),e[o]^=r,t[o]^=r}function C(e,n){var r,i,o,a=t(),s=t();for(r=0;r<16;r++)s[r]=n[r];for(R(s),R(s),R(s),i=0;i<2;i++){for(a[0]=s[0]-65517,r=1;r<15;r++)a[r]=s[r]-65535-(a[r-1]>>16&1),a[r-1]&=65535;a[15]=s[15]-32767-(a[14]>>16&1),o=a[15]>>16&1,a[14]&=65535,P(s,a,1-o)}for(r=0;r<16;r++)e[2*r]=255&s[r],e[2*r+1]=s[r]>>8}function D(e,t){var n=new Uint8Array(32),r=new Uint8Array(32);return C(n,e),C(r,t),g(n,0,r,0)}function U(e){var t=new Uint8Array(32);return C(t,e),1&t[0]}function I(e,t){var n;for(n=0;n<16;n++)e[n]=t[2*n]+(t[2*n+1]<<8);e[15]&=32767}function j(e,t,n){for(var r=0;r<16;r++)e[r]=t[r]+n[r]}function L(e,t,n){for(var r=0;r<16;r++)e[r]=t[r]-n[r]}function F(e,t,n){var r,i,o=0,a=0,s=0,u=0,l=0,c=0,f=0,d=0,h=0,p=0,m=0,v=0,g=0,y=0,b=0,w=0,_=0,x=0,S=0,E=0,k=0,O=0,T=0,A=0,M=0,N=0,R=0,P=0,C=0,D=0,U=0,I=n[0],j=n[1],L=n[2],F=n[3],z=n[4],B=n[5],V=n[6],Y=n[7],H=n[8],$=n[9],W=n[10],G=n[11],q=n[12],K=n[13],X=n[14],Z=n[15];o+=(r=t[0])*I,a+=r*j,s+=r*L,u+=r*F,l+=r*z,c+=r*B,f+=r*V,d+=r*Y,h+=r*H,p+=r*$,m+=r*W,v+=r*G,g+=r*q,y+=r*K,b+=r*X,w+=r*Z,a+=(r=t[1])*I,s+=r*j,u+=r*L,l+=r*F,c+=r*z,f+=r*B,d+=r*V,h+=r*Y,p+=r*H,m+=r*$,v+=r*W,g+=r*G,y+=r*q,b+=r*K,w+=r*X,_+=r*Z,s+=(r=t[2])*I,u+=r*j,l+=r*L,c+=r*F,f+=r*z,d+=r*B,h+=r*V,p+=r*Y,m+=r*H,v+=r*$,g+=r*W,y+=r*G,b+=r*q,w+=r*K,_+=r*X,x+=r*Z,u+=(r=t[3])*I,l+=r*j,c+=r*L,f+=r*F,d+=r*z,h+=r*B,p+=r*V,m+=r*Y,v+=r*H,g+=r*$,y+=r*W,b+=r*G,w+=r*q,_+=r*K,x+=r*X,S+=r*Z,l+=(r=t[4])*I,c+=r*j,f+=r*L,d+=r*F,h+=r*z,p+=r*B,m+=r*V,v+=r*Y,g+=r*H,y+=r*$,b+=r*W,w+=r*G,_+=r*q,x+=r*K,S+=r*X,E+=r*Z,c+=(r=t[5])*I,f+=r*j,d+=r*L,h+=r*F,p+=r*z,m+=r*B,v+=r*V,g+=r*Y,y+=r*H,b+=r*$,w+=r*W,_+=r*G,x+=r*q,S+=r*K,E+=r*X,k+=r*Z,f+=(r=t[6])*I,d+=r*j,h+=r*L,p+=r*F,m+=r*z,v+=r*B,g+=r*V,y+=r*Y,b+=r*H,w+=r*$,_+=r*W,x+=r*G,S+=r*q,E+=r*K,k+=r*X,O+=r*Z,d+=(r=t[7])*I,h+=r*j,p+=r*L,m+=r*F,v+=r*z,g+=r*B,y+=r*V,b+=r*Y,w+=r*H,_+=r*$,x+=r*W,S+=r*G,E+=r*q,k+=r*K,O+=r*X,T+=r*Z,h+=(r=t[8])*I,p+=r*j,m+=r*L,v+=r*F,g+=r*z,y+=r*B,b+=r*V,w+=r*Y,_+=r*H,x+=r*$,S+=r*W,E+=r*G,k+=r*q,O+=r*K,T+=r*X,A+=r*Z,p+=(r=t[9])*I,m+=r*j,v+=r*L,g+=r*F,y+=r*z,b+=r*B,w+=r*V,_+=r*Y,x+=r*H,S+=r*$,E+=r*W,k+=r*G,O+=r*q,T+=r*K,A+=r*X,M+=r*Z,m+=(r=t[10])*I,v+=r*j,g+=r*L,y+=r*F,b+=r*z,w+=r*B,_+=r*V,x+=r*Y,S+=r*H,E+=r*$,k+=r*W,O+=r*G,T+=r*q,A+=r*K,M+=r*X,N+=r*Z,v+=(r=t[11])*I,g+=r*j,y+=r*L,b+=r*F,w+=r*z,_+=r*B,x+=r*V,S+=r*Y,E+=r*H,k+=r*$,O+=r*W,T+=r*G,A+=r*q,M+=r*K,N+=r*X,R+=r*Z,g+=(r=t[12])*I,y+=r*j,b+=r*L,w+=r*F,_+=r*z,x+=r*B,S+=r*V,E+=r*Y,k+=r*H,O+=r*$,T+=r*W,A+=r*G,M+=r*q,N+=r*K,R+=r*X,P+=r*Z,y+=(r=t[13])*I,b+=r*j,w+=r*L,_+=r*F,x+=r*z,S+=r*B,E+=r*V,k+=r*Y,O+=r*H,T+=r*$,A+=r*W,M+=r*G,N+=r*q,R+=r*K,P+=r*X,C+=r*Z,b+=(r=t[14])*I,w+=r*j,_+=r*L,x+=r*F,S+=r*z,E+=r*B,k+=r*V,O+=r*Y,T+=r*H,A+=r*$,M+=r*W,N+=r*G,R+=r*q,P+=r*K,C+=r*X,D+=r*Z,w+=(r=t[15])*I,a+=38*(x+=r*L),s+=38*(S+=r*F),u+=38*(E+=r*z),l+=38*(k+=r*B),c+=38*(O+=r*V),f+=38*(T+=r*Y),d+=38*(A+=r*H),h+=38*(M+=r*$),p+=38*(N+=r*W),m+=38*(R+=r*G),v+=38*(P+=r*q),g+=38*(C+=r*K),y+=38*(D+=r*X),b+=38*(U+=r*Z),o=(r=(o+=38*(_+=r*j))+(i=1)+65535)-65536*(i=Math.floor(r/65536)),a=(r=a+i+65535)-65536*(i=Math.floor(r/65536)),s=(r=s+i+65535)-65536*(i=Math.floor(r/65536)),u=(r=u+i+65535)-65536*(i=Math.floor(r/65536)),l=(r=l+i+65535)-65536*(i=Math.floor(r/65536)),c=(r=c+i+65535)-65536*(i=Math.floor(r/65536)),f=(r=f+i+65535)-65536*(i=Math.floor(r/65536)),d=(r=d+i+65535)-65536*(i=Math.floor(r/65536)),h=(r=h+i+65535)-65536*(i=Math.floor(r/65536)),p=(r=p+i+65535)-65536*(i=Math.floor(r/65536)),m=(r=m+i+65535)-65536*(i=Math.floor(r/65536)),v=(r=v+i+65535)-65536*(i=Math.floor(r/65536)),g=(r=g+i+65535)-65536*(i=Math.floor(r/65536)),y=(r=y+i+65535)-65536*(i=Math.floor(r/65536)),b=(r=b+i+65535)-65536*(i=Math.floor(r/65536)),w=(r=w+i+65535)-65536*(i=Math.floor(r/65536)),o=(r=(o+=i-1+37*(i-1))+(i=1)+65535)-65536*(i=Math.floor(r/65536)),a=(r=a+i+65535)-65536*(i=Math.floor(r/65536)),s=(r=s+i+65535)-65536*(i=Math.floor(r/65536)),u=(r=u+i+65535)-65536*(i=Math.floor(r/65536)),l=(r=l+i+65535)-65536*(i=Math.floor(r/65536)),c=(r=c+i+65535)-65536*(i=Math.floor(r/65536)),f=(r=f+i+65535)-65536*(i=Math.floor(r/65536)),d=(r=d+i+65535)-65536*(i=Math.floor(r/65536)),h=(r=h+i+65535)-65536*(i=Math.floor(r/65536)),p=(r=p+i+65535)-65536*(i=Math.floor(r/65536)),m=(r=m+i+65535)-65536*(i=Math.floor(r/65536)),v=(r=v+i+65535)-65536*(i=Math.floor(r/65536)),g=(r=g+i+65535)-65536*(i=Math.floor(r/65536)),y=(r=y+i+65535)-65536*(i=Math.floor(r/65536)),b=(r=b+i+65535)-65536*(i=Math.floor(r/65536)),w=(r=w+i+65535)-65536*(i=Math.floor(r/65536)),o+=i-1+37*(i-1),e[0]=o,e[1]=a,e[2]=s,e[3]=u,e[4]=l,e[5]=c,e[6]=f,e[7]=d,e[8]=h,e[9]=p,e[10]=m,e[11]=v,e[12]=g,e[13]=y,e[14]=b,e[15]=w}function z(e,t){F(e,t,t)}function B(e,n){var r,i=t();for(r=0;r<16;r++)i[r]=n[r];for(r=253;r>=0;r--)z(i,i),2!==r&&4!==r&&F(i,i,n);for(r=0;r<16;r++)e[r]=i[r]}function V(e,n){var r,i=t();for(r=0;r<16;r++)i[r]=n[r];for(r=250;r>=0;r--)z(i,i),1!==r&&F(i,i,n);for(r=0;r<16;r++)e[r]=i[r]}function Y(e,n,r){var i,o,a=new Uint8Array(32),s=new Float64Array(80),l=t(),c=t(),f=t(),d=t(),h=t(),p=t();for(o=0;o<31;o++)a[o]=n[o];for(a[31]=127&n[31]|64,a[0]&=248,I(s,r),o=0;o<16;o++)c[o]=s[o],d[o]=l[o]=f[o]=0;for(l[0]=d[0]=1,o=254;o>=0;--o)P(l,c,i=a[o>>>3]>>>(7&o)&1),P(f,d,i),j(h,l,f),L(l,l,f),j(f,c,d),L(c,c,d),z(d,h),z(p,l),F(l,f,l),F(f,c,h),j(h,l,f),L(l,l,f),z(c,l),L(f,d,p),F(l,f,u),j(l,l,d),F(f,f,l),F(l,d,p),F(d,c,s),z(c,h),P(l,c,i),P(f,d,i);for(o=0;o<16;o++)s[o+16]=l[o],s[o+32]=f[o],s[o+48]=c[o],s[o+64]=d[o];var m=s.subarray(32),v=s.subarray(16);return B(m,m),F(v,v,m),C(e,v),0}function H(e,t){return Y(e,t,o)}function $(e,t){return r(t,32),H(e,t)}function W(e,t,n){var r=new Uint8Array(32);return Y(r,n,t),b(e,i,r,w)}k.prototype.blocks=function(e,t,n){for(var r,i,o,a,s,u,l,c,f,d,h,p,m,v,g,y,b,w,_,x=this.fin?0:2048,S=this.h[0],E=this.h[1],k=this.h[2],O=this.h[3],T=this.h[4],A=this.h[5],M=this.h[6],N=this.h[7],R=this.h[8],P=this.h[9],C=this.r[0],D=this.r[1],U=this.r[2],I=this.r[3],j=this.r[4],L=this.r[5],F=this.r[6],z=this.r[7],B=this.r[8],V=this.r[9];n>=16;)d=f=0,d+=(S+=8191&(r=255&e[t+0]|(255&e[t+1])<<8))*C,d+=(E+=8191&(r>>>13|(i=255&e[t+2]|(255&e[t+3])<<8)<<3))*(5*V),d+=(k+=8191&(i>>>10|(o=255&e[t+4]|(255&e[t+5])<<8)<<6))*(5*B),d+=(O+=8191&(o>>>7|(a=255&e[t+6]|(255&e[t+7])<<8)<<9))*(5*z),f=(d+=(T+=8191&(a>>>4|(s=255&e[t+8]|(255&e[t+9])<<8)<<12))*(5*F))>>>13,d&=8191,d+=(A+=s>>>1&8191)*(5*L),d+=(M+=8191&(s>>>14|(u=255&e[t+10]|(255&e[t+11])<<8)<<2))*(5*j),d+=(N+=8191&(u>>>11|(l=255&e[t+12]|(255&e[t+13])<<8)<<5))*(5*I),d+=(R+=8191&(l>>>8|(c=255&e[t+14]|(255&e[t+15])<<8)<<8))*(5*U),h=f+=(d+=(P+=c>>>5|x)*(5*D))>>>13,h+=S*D,h+=E*C,h+=k*(5*V),h+=O*(5*B),f=(h+=T*(5*z))>>>13,h&=8191,h+=A*(5*F),h+=M*(5*L),h+=N*(5*j),h+=R*(5*I),f+=(h+=P*(5*U))>>>13,h&=8191,p=f,p+=S*U,p+=E*D,p+=k*C,p+=O*(5*V),f=(p+=T*(5*B))>>>13,p&=8191,p+=A*(5*z),p+=M*(5*F),p+=N*(5*L),p+=R*(5*j),m=f+=(p+=P*(5*I))>>>13,m+=S*I,m+=E*U,m+=k*D,m+=O*C,f=(m+=T*(5*V))>>>13,m&=8191,m+=A*(5*B),m+=M*(5*z),m+=N*(5*F),m+=R*(5*L),v=f+=(m+=P*(5*j))>>>13,v+=S*j,v+=E*I,v+=k*U,v+=O*D,f=(v+=T*C)>>>13,v&=8191,v+=A*(5*V),v+=M*(5*B),v+=N*(5*z),v+=R*(5*F),g=f+=(v+=P*(5*L))>>>13,g+=S*L,g+=E*j,g+=k*I,g+=O*U,f=(g+=T*D)>>>13,g&=8191,g+=A*C,g+=M*(5*V),g+=N*(5*B),g+=R*(5*z),y=f+=(g+=P*(5*F))>>>13,y+=S*F,y+=E*L,y+=k*j,y+=O*I,f=(y+=T*U)>>>13,y&=8191,y+=A*D,y+=M*C,y+=N*(5*V),y+=R*(5*B),b=f+=(y+=P*(5*z))>>>13,b+=S*z,b+=E*F,b+=k*L,b+=O*j,f=(b+=T*I)>>>13,b&=8191,b+=A*U,b+=M*D,b+=N*C,b+=R*(5*V),w=f+=(b+=P*(5*B))>>>13,w+=S*B,w+=E*z,w+=k*F,w+=O*L,f=(w+=T*j)>>>13,w&=8191,w+=A*I,w+=M*U,w+=N*D,w+=R*C,_=f+=(w+=P*(5*V))>>>13,_+=S*V,_+=E*B,_+=k*z,_+=O*F,f=(_+=T*L)>>>13,_&=8191,_+=A*j,_+=M*I,_+=N*U,_+=R*D,S=d=8191&(f=(f=((f+=(_+=P*C)>>>13)<<2)+f|0)+(d&=8191)|0),E=h+=f>>>=13,k=p&=8191,O=m&=8191,T=v&=8191,A=g&=8191,M=y&=8191,N=b&=8191,R=w&=8191,P=_&=8191,t+=16,n-=16;this.h[0]=S,this.h[1]=E,this.h[2]=k,this.h[3]=O,this.h[4]=T,this.h[5]=A,this.h[6]=M,this.h[7]=N,this.h[8]=R,this.h[9]=P},k.prototype.finish=function(e,t){var n,r,i,o,a=new Uint16Array(10);if(this.leftover){for(o=this.leftover,this.buffer[o++]=1;o<16;o++)this.buffer[o]=0;this.fin=1,this.blocks(this.buffer,0,16)}for(n=this.h[1]>>>13,this.h[1]&=8191,o=2;o<10;o++)this.h[o]+=n,n=this.h[o]>>>13,this.h[o]&=8191;for(this.h[0]+=5*n,n=this.h[0]>>>13,this.h[0]&=8191,this.h[1]+=n,n=this.h[1]>>>13,this.h[1]&=8191,this.h[2]+=n,a[0]=this.h[0]+5,n=a[0]>>>13,a[0]&=8191,o=1;o<10;o++)a[o]=this.h[o]+n,n=a[o]>>>13,a[o]&=8191;for(a[9]-=8192,r=(1^n)-1,o=0;o<10;o++)a[o]&=r;for(r=~r,o=0;o<10;o++)this.h[o]=this.h[o]&r|a[o];for(this.h[0]=65535&(this.h[0]|this.h[1]<<13),this.h[1]=65535&(this.h[1]>>>3|this.h[2]<<10),this.h[2]=65535&(this.h[2]>>>6|this.h[3]<<7),this.h[3]=65535&(this.h[3]>>>9|this.h[4]<<4),this.h[4]=65535&(this.h[4]>>>12|this.h[5]<<1|this.h[6]<<14),this.h[5]=65535&(this.h[6]>>>2|this.h[7]<<11),this.h[6]=65535&(this.h[7]>>>5|this.h[8]<<8),this.h[7]=65535&(this.h[8]>>>8|this.h[9]<<5),i=this.h[0]+this.pad[0],this.h[0]=65535&i,o=1;o<8;o++)i=(this.h[o]+this.pad[o]|0)+(i>>>16)|0,this.h[o]=65535&i;e[t+0]=this.h[0]>>>0&255,e[t+1]=this.h[0]>>>8&255,e[t+2]=this.h[1]>>>0&255,e[t+3]=this.h[1]>>>8&255,e[t+4]=this.h[2]>>>0&255,e[t+5]=this.h[2]>>>8&255,e[t+6]=this.h[3]>>>0&255,e[t+7]=this.h[3]>>>8&255,e[t+8]=this.h[4]>>>0&255,e[t+9]=this.h[4]>>>8&255,e[t+10]=this.h[5]>>>0&255,e[t+11]=this.h[5]>>>8&255,e[t+12]=this.h[6]>>>0&255,e[t+13]=this.h[6]>>>8&255,e[t+14]=this.h[7]>>>0&255,e[t+15]=this.h[7]>>>8&255},k.prototype.update=function(e,t,n){var r,i;if(this.leftover){for((i=16-this.leftover)>n&&(i=n),r=0;r=16&&(i=n-n%16,this.blocks(e,t,i),t+=i,n-=i),n){for(r=0;r=128;){for(x=0;x<16;x++)S=8*x+q,N[x]=n[S+0]<<24|n[S+1]<<16|n[S+2]<<8|n[S+3],R[x]=n[S+4]<<24|n[S+5]<<16|n[S+6]<<8|n[S+7];for(x=0;x<80;x++)if(i=P,o=C,a=D,s=U,u=I,l=j,c=L,F,d=z,h=B,p=V,m=Y,v=H,g=$,y=W,G,O=65535&(k=G),T=k>>>16,A=65535&(E=F),M=E>>>16,O+=65535&(k=(H>>>14|I<<18)^(H>>>18|I<<14)^(I>>>9|H<<23)),T+=k>>>16,A+=65535&(E=(I>>>14|H<<18)^(I>>>18|H<<14)^(H>>>9|I<<23)),M+=E>>>16,O+=65535&(k=H&$^~H&W),T+=k>>>16,A+=65535&(E=I&j^~I&L),M+=E>>>16,O+=65535&(k=K[2*x+1]),T+=k>>>16,A+=65535&(E=K[2*x]),M+=E>>>16,E=N[x%16],T+=(k=R[x%16])>>>16,A+=65535&E,M+=E>>>16,A+=(T+=(O+=65535&k)>>>16)>>>16,O=65535&(k=_=65535&O|T<<16),T=k>>>16,A=65535&(E=w=65535&A|(M+=A>>>16)<<16),M=E>>>16,O+=65535&(k=(z>>>28|P<<4)^(P>>>2|z<<30)^(P>>>7|z<<25)),T+=k>>>16,A+=65535&(E=(P>>>28|z<<4)^(z>>>2|P<<30)^(z>>>7|P<<25)),M+=E>>>16,T+=(k=z&B^z&V^B&V)>>>16,A+=65535&(E=P&C^P&D^C&D),M+=E>>>16,f=65535&(A+=(T+=(O+=65535&k)>>>16)>>>16)|(M+=A>>>16)<<16,b=65535&O|T<<16,O=65535&(k=m),T=k>>>16,A=65535&(E=s),M=E>>>16,T+=(k=_)>>>16,A+=65535&(E=w),M+=E>>>16,C=i,D=o,U=a,I=s=65535&(A+=(T+=(O+=65535&k)>>>16)>>>16)|(M+=A>>>16)<<16,j=u,L=l,F=c,P=f,B=d,V=h,Y=p,H=m=65535&O|T<<16,$=v,W=g,G=y,z=b,x%16==15)for(S=0;S<16;S++)E=N[S],O=65535&(k=R[S]),T=k>>>16,A=65535&E,M=E>>>16,E=N[(S+9)%16],O+=65535&(k=R[(S+9)%16]),T+=k>>>16,A+=65535&E,M+=E>>>16,w=N[(S+1)%16],O+=65535&(k=((_=R[(S+1)%16])>>>1|w<<31)^(_>>>8|w<<24)^(_>>>7|w<<25)),T+=k>>>16,A+=65535&(E=(w>>>1|_<<31)^(w>>>8|_<<24)^w>>>7),M+=E>>>16,w=N[(S+14)%16],T+=(k=((_=R[(S+14)%16])>>>19|w<<13)^(w>>>29|_<<3)^(_>>>6|w<<26))>>>16,A+=65535&(E=(w>>>19|_<<13)^(_>>>29|w<<3)^w>>>6),M+=E>>>16,M+=(A+=(T+=(O+=65535&k)>>>16)>>>16)>>>16,N[S]=65535&A|M<<16,R[S]=65535&O|T<<16;O=65535&(k=z),T=k>>>16,A=65535&(E=P),M=E>>>16,E=e[0],T+=(k=t[0])>>>16,A+=65535&E,M+=E>>>16,M+=(A+=(T+=(O+=65535&k)>>>16)>>>16)>>>16,e[0]=P=65535&A|M<<16,t[0]=z=65535&O|T<<16,O=65535&(k=B),T=k>>>16,A=65535&(E=C),M=E>>>16,E=e[1],T+=(k=t[1])>>>16,A+=65535&E,M+=E>>>16,M+=(A+=(T+=(O+=65535&k)>>>16)>>>16)>>>16,e[1]=C=65535&A|M<<16,t[1]=B=65535&O|T<<16,O=65535&(k=V),T=k>>>16,A=65535&(E=D),M=E>>>16,E=e[2],T+=(k=t[2])>>>16,A+=65535&E,M+=E>>>16,M+=(A+=(T+=(O+=65535&k)>>>16)>>>16)>>>16,e[2]=D=65535&A|M<<16,t[2]=V=65535&O|T<<16,O=65535&(k=Y),T=k>>>16,A=65535&(E=U),M=E>>>16,E=e[3],T+=(k=t[3])>>>16,A+=65535&E,M+=E>>>16,M+=(A+=(T+=(O+=65535&k)>>>16)>>>16)>>>16,e[3]=U=65535&A|M<<16,t[3]=Y=65535&O|T<<16,O=65535&(k=H),T=k>>>16,A=65535&(E=I),M=E>>>16,E=e[4],T+=(k=t[4])>>>16,A+=65535&E,M+=E>>>16,M+=(A+=(T+=(O+=65535&k)>>>16)>>>16)>>>16,e[4]=I=65535&A|M<<16,t[4]=H=65535&O|T<<16,O=65535&(k=$),T=k>>>16,A=65535&(E=j),M=E>>>16,E=e[5],T+=(k=t[5])>>>16,A+=65535&E,M+=E>>>16,M+=(A+=(T+=(O+=65535&k)>>>16)>>>16)>>>16,e[5]=j=65535&A|M<<16,t[5]=$=65535&O|T<<16,O=65535&(k=W),T=k>>>16,A=65535&(E=L),M=E>>>16,E=e[6],T+=(k=t[6])>>>16,A+=65535&E,M+=E>>>16,M+=(A+=(T+=(O+=65535&k)>>>16)>>>16)>>>16,e[6]=L=65535&A|M<<16,t[6]=W=65535&O|T<<16,O=65535&(k=G),T=k>>>16,A=65535&(E=F),M=E>>>16,E=e[7],T+=(k=t[7])>>>16,A+=65535&E,M+=E>>>16,M+=(A+=(T+=(O+=65535&k)>>>16)>>>16)>>>16,e[7]=F=65535&A|M<<16,t[7]=G=65535&O|T<<16,q+=128,r-=128}return r}function Z(e,t,n){var r,i=new Int32Array(8),o=new Int32Array(8),a=new Uint8Array(256),s=n;for(i[0]=1779033703,i[1]=3144134277,i[2]=1013904242,i[3]=2773480762,i[4]=1359893119,i[5]=2600822924,i[6]=528734635,i[7]=1541459225,o[0]=4089235720,o[1]=2227873595,o[2]=4271175723,o[3]=1595750129,o[4]=2917565137,o[5]=725511199,o[6]=4215389547,o[7]=327033209,X(i,o,t,n),n%=128,r=0;r=0;--i)J(e,t,r=n[i/8|0]>>(7&i)&1),Q(t,e),Q(e,e),J(e,t,r)}function ne(e,n){var r=[t(),t(),t(),t()];N(r[0],f),N(r[1],d),N(r[2],s),F(r[3],f,d),te(e,r,n)}function re(e,n,i){var o,a=new Uint8Array(64),s=[t(),t(),t(),t()];for(i||r(n,32),Z(a,n,32),a[0]&=248,a[31]&=127,a[31]|=64,ne(s,a),ee(e,s),o=0;o<32;o++)n[o+32]=e[o];return 0}var ie=new Float64Array([237,211,245,92,26,99,18,88,214,156,247,162,222,249,222,20,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,16]);function oe(e,t){var n,r,i,o;for(r=63;r>=32;--r){for(n=0,i=r-32,o=r-12;i>4)*ie[i],n=t[i]>>8,t[i]&=255;for(i=0;i<32;i++)t[i]-=n*ie[i];for(r=0;r<32;r++)t[r+1]+=t[r]>>8,e[r]=255&t[r]}function ae(e){var t,n=new Float64Array(64);for(t=0;t<64;t++)n[t]=e[t];for(t=0;t<64;t++)e[t]=0;oe(e,n)}function se(e,n,r,i){var o,a,s=new Uint8Array(64),u=new Uint8Array(64),l=new Uint8Array(64),c=new Float64Array(64),f=[t(),t(),t(),t()];Z(s,i,32),s[0]&=248,s[31]&=127,s[31]|=64;var d=r+64;for(o=0;o>7&&L(e[0],a,e[0]),F(e[3],e[0],e[1]),0)}(d,i))return-1;for(o=0;o=0},e.sign.keyPair=function(){var e=new Uint8Array(fe),t=new Uint8Array(de);return re(e,t),{publicKey:e,secretKey:t}},e.sign.keyPair.fromSecretKey=function(e){if(pe(e),e.length!==de)throw new Error("bad secret key size");for(var t=new Uint8Array(fe),n=0;n{function t(e,t,n,r,i,o,a){try{var s=e[o](a),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,i)}e.exports=function(e){return function(){var n=this,r=arguments;return new Promise((function(i,o){var a=e.apply(n,r);function s(e){t(a,i,o,s,u,"next",e)}function u(e){t(a,i,o,s,u,"throw",e)}s(void 0)}))}}},765526:e=>{e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}},307914:e=>{e.exports=function(e){return e&&e.__esModule?e:{default:e}}},73982:(e,t,n)=>{var r=n(765526);function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}e.exports=function(e){for(var t=1;t{var r=n(915600);e.exports=function(e,t){if(null==e)return{};var n,i,o=r(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}},915600:e=>{e.exports=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}},256856:(e,t,n)=>{"use strict";var r=n(445051),i=Uint8Array,o=Uint16Array,a=Uint32Array,s=new i([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]),u=new i([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]),l=new i([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),c=function(e,t){for(var n=new o(31),r=0;r<31;++r)n[r]=t+=1<>>1|(21845&y)<<1;b=(61680&(b=(52428&b)>>>2|(13107&b)<<2))>>>4|(3855&b)<<4,g[y]=((65280&b)>>>8|(255&b)<<8)>>>1}var w=function(e,t,n){for(var r=e.length,i=0,a=new o(t);i>>l]=c}else for(s=new o(r),i=0;i>>15-e[i]);return s},_=new i(288);for(y=0;y<144;++y)_[y]=8;for(y=144;y<256;++y)_[y]=9;for(y=256;y<280;++y)_[y]=7;for(y=280;y<288;++y)_[y]=8;var x=new i(32);for(y=0;y<32;++y)x[y]=5;var S=w(_,9,0),E=w(_,9,1),k=w(x,5,0),O=w(x,5,1),T=function(e){for(var t=e[0],n=1;nt&&(t=e[n]);return t},A=function(e,t,n){var r=t/8|0;return(e[r]|e[r+1]<<8)>>(7&t)&n},M=function(e,t){var n=t/8|0;return(e[n]|e[n+1]<<8|e[n+2]<<16)>>(7&t)},N=function(e){return(e/8|0)+(7&e&&1)},R=function(e,t,n){(null==t||t<0)&&(t=0),(null==n||n>e.length)&&(n=e.length);var r=new(e instanceof o?o:e instanceof a?a:i)(n-t);return r.set(e.subarray(t,n)),r},P=function(e,t,n){var r=e.length;if(!r||n&&!n.l&&r<5)return t||new i(0);var o=!t||n,a=!n||n.i;n||(n={}),t||(t=new i(3*r));var c=function(e){var n=t.length;if(e>n){var r=new i(Math.max(2*n,e));r.set(t),t=r}},f=n.f||0,h=n.p||0,p=n.b||0,v=n.l,g=n.d,y=n.m,b=n.n,_=8*r;do{if(!v){n.f=f=A(e,h,1);var x=A(e,h+1,3);if(h+=3,!x){var S=e[(B=N(h)+4)-4]|e[B-3]<<8,k=B+S;if(k>r){if(a)throw"unexpected EOF";break}o&&c(p+S),t.set(e.subarray(B,k),p),n.b=p+=S,n.p=h=8*k;continue}if(1==x)v=E,g=O,y=9,b=5;else{if(2!=x)throw"invalid block type";var P=A(e,h,31)+257,C=A(e,h+10,15)+4,D=P+A(e,h+5,31)+1;h+=14;for(var U=new i(D),I=new i(19),j=0;j_)break;var z=w(I,L,1);for(j=0;j>>4)<16)U[j++]=B;else{var Y=0,H=0;for(16==B?(H=3+A(e,h,3),h+=2,Y=U[j-1]):17==B?(H=3+A(e,h,7),h+=3):18==B&&(H=11+A(e,h,127),h+=7);H--;)U[j++]=Y}}var $=U.subarray(0,P),W=U.subarray(P);y=T($),b=T(W),v=w($,y,1),g=w(W,b,1)}if(h>_)throw"unexpected EOF"}o&&c(p+131072);for(var G=(1<>>4;if((h+=15&Y)>_)throw"unexpected EOF";if(!Y)throw"invalid length/literal";if(X<256)t[p++]=X;else{if(256==X){v=null;break}var Z=X-254;if(X>264){var Q=s[j=X-257];Z=A(e,h,(1<>>4;if(!J)throw"invalid distance";h+=15&J;W=m[ee];if(ee>3){Q=u[ee];W+=M(e,h)&(1<_)throw"unexpected EOF";o&&c(p+131072);for(var te=p+Z;p>>8},D=function(e,t,n){n<<=7&t;var r=t/8|0;e[r]|=n,e[r+1]|=n>>>8,e[r+2]|=n>>>16},U=function(e,t){for(var n=[],r=0;rp&&(p=s[r].s);var m=new o(p+1),v=I(n[d-1],m,0);if(v>t){r=0;var g=0,y=v-t,b=1<t))break;g+=b-(1<>>=y;g>0;){var _=s[r].s;m[_]=0&&g;--r){var x=s[r].s;m[x]==t&&(--m[x],++g)}v=t}return[new i(m),v]},I=function(e,t,n){return-1==e.s?Math.max(I(e.l,t,n+1),I(e.r,t,n+1)):t[e.s]=n},j=function(e){for(var t=e.length;t&&!e[--t];);for(var n=new o(++t),r=0,i=e[0],a=1,s=function(e){n[r++]=e},u=1;u<=t;++u)if(e[u]==i&&u!=t)++a;else{if(!i&&a>2){for(;a>138;a-=138)s(32754);a>2&&(s(a>10?a-11<<5|28690:a-3<<5|12305),a=0)}else if(a>3){for(s(i),--a;a>6;a-=6)s(8304);a>2&&(s(a-3<<5|8208),a=0)}for(;a--;)s(i);a=1,i=e[u]}return[n.subarray(0,r),t]},L=function(e,t){for(var n=0,r=0;r>>8,e[i+2]=255^e[i],e[i+3]=255^e[i+1];for(var o=0;o4&&!B[l[Y-1]];--Y);var H,$,W,G,q=h+5<<3,K=L(i,_)+L(a,x)+c,X=L(i,v)+L(a,b)+c+14+3*Y+L(P,B)+(2*P[16]+3*P[17]+7*P[18]);if(q<=K&&q<=X)return F(t,p,e.subarray(d,d+h));if(C(t,p,1+(X15&&(C(t,p,ee[I]>>>5&127),p+=ee[I]>>>12)}}}else H=S,$=_,W=k,G=x;for(I=0;I255){te=r[I]>>>18&31;D(t,p,H[te+257]),p+=$[te+257],te>7&&(C(t,p,r[I]>>>23&31),p+=s[te]);var ne=31&r[I];D(t,p,W[ne]),p+=G[ne],ne>3&&(D(t,p,r[I]>>>5&8191),p+=u[ne])}else D(t,p,H[r[I]]),p+=$[r[I]];return D(t,p,H[256]),p+$[256]},B=new a([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),V=new i(0),Y=function(e,t,n,r,l,c){var f=e.length,d=new i(r+f+5*(1+Math.ceil(f/7e3))+l),p=d.subarray(r,d.length-l),m=0;if(!t||f<8)for(var g=0;g<=f;g+=65535){var y=g+65535;y>>13,_=8191&b,x=(1<7e3||U>24576)&&$>423){m=z(e,p,0,A,M,P,D,U,j,g-j,m),U=C=D=0,j=g;for(var W=0;W<286;++W)M[W]=0;for(W=0;W<30;++W)P[W]=0}var G=2,q=0,K=_,X=Y-H&32767;if($>2&&L==T(g-X))for(var Z=Math.min(w,$)-1,Q=Math.min(32767,g),J=Math.min(258,$);X<=Q&&--K&&Y!=H;){if(e[g+G]==e[g+G-X]){for(var ee=0;eeG){if(G=ee,q=X,ee>Z)break;var te=Math.min(X,ee-2),ne=0;for(W=0;Wne&&(ne=ie,H=re)}}}X+=(Y=H)-(H=S[Y])+32768&32767}if(q){A[U++]=268435456|h[G]<<18|v[q];var oe=31&h[G],ae=31&v[q];D+=s[oe]+u[ae],++M[257+oe],++P[ae],I=g+G,++C}else A[U++]=e[g],++M[e[g]]}}m=z(e,p,c,A,M,P,D,U,j,g-j,m),!c&&7&m&&(m=F(p,m+1,V))}return R(d,0,r+N(m)+l)},H=function(){for(var e=new a(256),t=0;t<256;++t){for(var n=t,r=9;--r;)n=(1&n&&3988292384)^n>>>1;e[t]=n}return e}(),$=function(){var e=-1;return{p:function(t){for(var n=e,r=0;r>>8;e=n},d:function(){return~e}}},W=function(){var e=1,t=0;return{p:function(n){for(var r=e,i=t,o=n.length,a=0;a!=o;){for(var s=Math.min(a+2655,o);a>16),i=(65535&i)+15*(i>>16)}e=r,t=i},d:function(){return((e%=65521)>>>8<<16|(255&(t%=65521))<<8|t>>>8)+2*((255&e)<<23)}}},G=function(e,t,n,r,i){return Y(e,null==t.level?6:t.level,null==t.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(e.length)))):12+t.mem,n,r,!i)},q=function(e,t){var n={};for(var r in e)n[r]=e[r];for(var r in t)n[r]=t[r];return n},K=function(e,t,n){for(var r=e(),i=e.toString(),o=i.slice(i.indexOf("[")+1,i.lastIndexOf("]")).replace(/ /g,"").split(","),a=0;a>>=8},he=function(e,t){var n=t.filename;if(e[0]=31,e[1]=139,e[2]=8,e[8]=t.level<2?4:9==t.level?2:0,e[9]=3,0!=t.mtime&&de(e,4,Math.floor(new Date(t.mtime||Date.now())/1e3)),n){e[3]=8;for(var r=0;r<=n.length;++r)e[r+10]=n.charCodeAt(r)}},pe=function(e){if(31!=e[0]||139!=e[1]||8!=e[2])throw"invalid gzip data";var t=e[3],n=10;4&t&&(n+=e[10]|2+(e[11]<<8));for(var r=(t>>3&1)+(t>>4&1);r>0;r-=!e[n++]);return n+(2&t)},me=function(e){var t=e.length;return(e[t-4]|e[t-3]<<8|e[t-2]<<16)+2*(e[t-1]<<23)},ve=function(e){return 10+(e.filename&&e.filename.length+1||0)},ge=function(e,t){var n=t.level,r=0==n?0:n<6?1:9==n?3:2;e[0]=120,e[1]=r<<6|(r?32-2*r:1)},ye=function(e){if(8!=(15&e[0])||e[0]>>>4>7||(e[0]<<8|e[1])%31)throw"invalid zlib data";if(32&e[1])throw"invalid zlib data: preset dictionaries not supported"};function be(e,t){return t||"function"!=typeof e||(t=e,e={}),this.ondata=t,e}var we=function(){function e(e,t){t||"function"!=typeof e||(t=e,e={}),this.ondata=t,this.o=e||{}}return e.prototype.p=function(e,t){this.ondata(G(e,this.o,0,0,!t),t)},e.prototype.push=function(e,t){if(this.d)throw"stream finished";if(!this.ondata)throw"no stream handler";this.d=t,this.p(e,t||!1)},e}();t.Deflate=we;var _e=function(){return function(e,t){ue([J,function(){return[se,we]}],this,be.call(this,e,t),(function(e){var t=new we(e.data);onmessage=se(t)}),6)}}();function xe(e,t,n){if(n||(n=t,t={}),"function"!=typeof n)throw"no callback";return ae(e,t,[J],(function(e){return ie(Se(e.data[0],e.data[1]))}),0,n)}function Se(e,t){return G(e,t||{},0,0)}t.AsyncDeflate=_e,t.deflate=xe,t.deflateSync=Se;var Ee=function(){function e(e){this.s={},this.p=new i(0),this.ondata=e}return e.prototype.e=function(e){if(this.d)throw"stream finished";if(!this.ondata)throw"no stream handler";var t=this.p.length,n=new i(t+e.length);n.set(this.p),n.set(e,t),this.p=n},e.prototype.c=function(e){this.d=this.s.i=e||!1;var t=this.s.b,n=P(this.p,this.o,this.s);this.ondata(R(n,t,this.s.b),this.d),this.o=R(n,this.s.b-32768),this.s.b=this.o.length,this.p=R(this.p,this.s.p/8|0),this.s.p&=7},e.prototype.push=function(e,t){this.e(e),this.c(t)},e}();t.Inflate=Ee;var ke=function(){return function(e){this.ondata=e,ue([Q,function(){return[se,Ee]}],this,0,(function(){var e=new Ee;onmessage=se(e)}),7)}}();function Oe(e,t,n){if(n||(n=t,t={}),"function"!=typeof n)throw"no callback";return ae(e,t,[Q],(function(e){return ie(Te(e.data[0],oe(e.data[1])))}),1,n)}function Te(e,t){return P(e,t)}t.AsyncInflate=ke,t.inflate=Oe,t.inflateSync=Te;var Ae=function(){function e(e,t){this.c=$(),this.l=0,this.v=1,we.call(this,e,t)}return e.prototype.push=function(e,t){we.prototype.push.call(this,e,t)},e.prototype.p=function(e,t){this.c.p(e),this.l+=e.length;var n=G(e,this.o,this.v&&ve(this.o),t&&8,!t);this.v&&(he(n,this.o),this.v=0),t&&(de(n,n.length-8,this.c.d()),de(n,n.length-4,this.l)),this.ondata(n,t)},e}();t.Gzip=Ae,t.Compress=Ae;var Me=function(){return function(e,t){ue([J,ee,function(){return[se,we,Ae]}],this,be.call(this,e,t),(function(e){var t=new Ae(e.data);onmessage=se(t)}),8)}}();function Ne(e,t,n){if(n||(n=t,t={}),"function"!=typeof n)throw"no callback";return ae(e,t,[J,ee,function(){return[Re]}],(function(e){return ie(Re(e.data[0],e.data[1]))}),2,n)}function Re(e,t){t||(t={});var n=$(),r=e.length;n.p(e);var i=G(e,t,ve(t),8),o=i.length;return he(i,t),de(i,o-8,n.d()),de(i,o-4,r),i}t.AsyncGzip=Me,t.AsyncCompress=Me,t.gzip=Ne,t.compress=Ne,t.gzipSync=Re,t.compressSync=Re;var Pe=function(){function e(e){this.v=1,Ee.call(this,e)}return e.prototype.push=function(e,t){if(Ee.prototype.e.call(this,e),this.v){var n=this.p.length>3?pe(this.p):4;if(n>=this.p.length&&!t)return;this.p=this.p.subarray(n),this.v=0}if(t){if(this.p.length<8)throw"invalid gzip stream";this.p=this.p.subarray(0,-8)}Ee.prototype.c.call(this,t)},e}();t.Gunzip=Pe;var Ce=function(){return function(e){this.ondata=e,ue([Q,te,function(){return[se,Ee,Pe]}],this,0,(function(){var e=new Pe;onmessage=se(e)}),9)}}();function De(e,t,n){if(n||(n=t,t={}),"function"!=typeof n)throw"no callback";return ae(e,t,[Q,te,function(){return[Ue]}],(function(e){return ie(Ue(e.data[0]))}),3,n)}function Ue(e,t){return P(e.subarray(pe(e),-8),t||new i(me(e)))}t.AsyncGunzip=Ce,t.gunzip=De,t.gunzipSync=Ue;var Ie=function(){function e(e,t){this.c=W(),this.v=1,we.call(this,e,t)}return e.prototype.push=function(e,t){we.prototype.push.call(this,e,t)},e.prototype.p=function(e,t){this.c.p(e);var n=G(e,this.o,this.v&&2,t&&4,!t);this.v&&(ge(n,this.o),this.v=0),t&&de(n,n.length-4,this.c.d()),this.ondata(n,t)},e}();t.Zlib=Ie;var je=function(){return function(e,t){ue([J,ne,function(){return[se,we,Ie]}],this,be.call(this,e,t),(function(e){var t=new Ie(e.data);onmessage=se(t)}),10)}}();function Le(e,t){t||(t={});var n=W();n.p(e);var r=G(e,t,2,4);return ge(r,t),de(r,r.length-4,n.d()),r}t.AsyncZlib=je,t.zlib=function(e,t,n){if(n||(n=t,t={}),"function"!=typeof n)throw"no callback";return ae(e,t,[J,ne,function(){return[Le]}],(function(e){return ie(Le(e.data[0],e.data[1]))}),4,n)},t.zlibSync=Le;var Fe=function(){function e(e){this.v=1,Ee.call(this,e)}return e.prototype.push=function(e,t){if(Ee.prototype.e.call(this,e),this.v){if(this.p.length<2&&!t)return;this.p=this.p.subarray(2),this.v=0}if(t){if(this.p.length<4)throw"invalid zlib stream";this.p=this.p.subarray(0,-4)}Ee.prototype.c.call(this,t)},e}();t.Unzlib=Fe;var ze=function(){return function(e){this.ondata=e,ue([Q,re,function(){return[se,Ee,Fe]}],this,0,(function(){var e=new Fe;onmessage=se(e)}),11)}}();function Be(e,t,n){if(n||(n=t,t={}),"function"!=typeof n)throw"no callback";return ae(e,t,[Q,re,function(){return[Ve]}],(function(e){return ie(Ve(e.data[0],oe(e.data[1])))}),5,n)}function Ve(e,t){return P((ye(e),e.subarray(2,-4)),t)}t.AsyncUnzlib=ze,t.unzlib=Be,t.unzlibSync=Ve;var Ye=function(){function e(e){this.G=Pe,this.I=Ee,this.Z=Fe,this.ondata=e}return e.prototype.push=function(e,t){if(!this.ondata)throw"no stream handler";if(this.s)this.s.push(e,t);else{if(this.p&&this.p.length){var n=new i(this.p.length+e.length);n.set(this.p),n.set(e,this.p.length)}else this.p=e;if(this.p.length>2){var r=this,o=function(){r.ondata.apply(r,arguments)};this.s=31==this.p[0]&&139==this.p[1]&&8==this.p[2]?new this.G(o):8!=(15&this.p[0])||this.p[0]>>4>7||(this.p[0]<<8|this.p[1])%31?new this.I(o):new this.Z(o),this.s.push(this.p,t),this.p=null}}},e}();t.Decompress=Ye;var He=function(){function e(e){this.G=Ce,this.I=ke,this.Z=ze,this.ondata=e}return e.prototype.push=function(e,t){Ye.prototype.push.call(this,e,t)},e}();t.AsyncDecompress=He,t.decompress=function(e,t,n){if(n||(n=t,t={}),"function"!=typeof n)throw"no callback";return 31==e[0]&&139==e[1]&&8==e[2]?De(e,t,n):8!=(15&e[0])||e[0]>>4>7||(e[0]<<8|e[1])%31?Oe(e,t,n):Be(e,t,n)},t.decompressSync=function(e,t){return 31==e[0]&&139==e[1]&&8==e[2]?Ue(e,t):8!=(15&e[0])||e[0]>>4>7||(e[0]<<8|e[1])%31?Te(e,t):Ve(e,t)};var $e=function(e,t,n,r){for(var o in e){var a=e[o],s=t+o;a instanceof i?n[s]=[a,r]:Array.isArray(a)?n[s]=[a[0],q(r,a[1])]:$e(a,s+"/",n,r)}},We="undefined"!=typeof TextEncoder&&new TextEncoder,Ge="undefined"!=typeof TextDecoder&&new TextDecoder,qe=0;try{Ge.decode(V,{stream:!0}),qe=1}catch(e){}var Ke=function(e){for(var t="",n=0;;){var r=e[n++],i=(r>127)+(r>223)+(r>239);if(n+i>e.length)return[t,R(e,n-1)];i?3==i?(r=((15&r)<<18|(63&e[n++])<<12|(63&e[n++])<<6|63&e[n++])-65536,t+=String.fromCharCode(55296|r>>10,56320|1023&r)):t+=1&i?String.fromCharCode((31&r)<<6|63&e[n++]):String.fromCharCode((15&r)<<12|(63&e[n++])<<6|63&e[n++]):t+=String.fromCharCode(r)}},Xe=function(){function e(e){this.ondata=e,qe?this.t=new TextDecoder:this.p=V}return e.prototype.push=function(e,t){if(!this.ondata)throw"no callback";if(t||(t=!1),this.t)return this.ondata(this.t.decode(e,{stream:!t}),t);var n=new i(this.p.length+e.length);n.set(this.p),n.set(e,this.p.length);var r=Ke(n),o=r[0],a=r[1];if(t&&a.length)throw"invalid utf-8 data";this.p=a,this.ondata(o,t)},e}();t.DecodeUTF8=Xe;var Ze=function(){function e(e){this.ondata=e}return e.prototype.push=function(e,t){if(!this.ondata)throw"no callback";this.ondata(Qe(e),t||!1)},e}();function Qe(e,t){if(t){for(var n=new i(e.length),r=0;r>1)),s=0,u=function(e){a[s++]=e};for(r=0;ra.length){var l=new i(s+8+(o-r<<1));l.set(a),a=l}var c=e.charCodeAt(r);c<128||t?u(c):c<2048?(u(192|c>>6),u(128|63&c)):c>55295&&c<57344?(u(240|(c=65536+(1047552&c)|1023&e.charCodeAt(++r))>>18),u(128|c>>12&63),u(128|c>>6&63),u(128|63&c)):(u(224|c>>12),u(128|c>>6&63),u(128|63&c))}return R(a,0,s)}function Je(e,t){if(t){for(var n="",r=0;r65535)throw"extra field too long";t+=r+4}return t},ot=function(e,t,n,r,i,o,a,s){var u=r.length,l=n.extra,c=s&&s.length,f=it(l);de(e,t,null!=a?33639248:67324752),t+=4,null!=a&&(e[t++]=20,e[t++]=n.os),e[t]=20,t+=2,e[t++]=n.flag<<1|(null==o&&8),e[t++]=i&&8,e[t++]=255&n.compression,e[t++]=n.compression>>8;var d=new Date(null==n.mtime?Date.now():n.mtime),h=d.getFullYear()-1980;if(h<0||h>119)throw"date not in range 1980-2099";if(de(e,t,2*(h<<24)|d.getMonth()+1<<21|d.getDate()<<16|d.getHours()<<11|d.getMinutes()<<5|d.getSeconds()>>>1),t+=4,null!=o&&(de(e,t,n.crc),de(e,t+4,o),de(e,t+8,n.size)),de(e,t+12,u),de(e,t+14,f),t+=16,null!=a&&(de(e,t,c),de(e,t+6,n.attrs),de(e,t+10,a),t+=14),e.set(r,t),t+=u,f)for(var p in l){var m=l[p],v=m.length;de(e,t,+p),de(e,t+2,v),e.set(m,t+4),t+=4+v}return c&&(e.set(s,t),t+=c),t},at=function(e,t,n,r,i){de(e,t,101010256),de(e,t+8,n),de(e,t+10,n),de(e,t+12,r),de(e,t+16,i)},st=function(){function e(e){this.filename=e,this.c=$(),this.size=0,this.compression=0}return e.prototype.process=function(e,t){this.ondata(null,e,t)},e.prototype.push=function(e,t){if(!this.ondata)throw"no callback - add to ZIP archive before pushing";this.c.p(e),this.size+=e.length,t&&(this.crc=this.c.d()),this.process(e,t||!1)},e}();t.ZipPassThrough=st;var ut=function(){function e(e,t){var n=this;t||(t={}),st.call(this,e),this.d=new we(t,(function(e,t){n.ondata(null,e,t)})),this.compression=8,this.flag=et(t.level)}return e.prototype.process=function(e,t){try{this.d.push(e,t)}catch(e){this.ondata(e,null,t)}},e.prototype.push=function(e,t){st.prototype.push.call(this,e,t)},e}();t.ZipDeflate=ut;var lt=function(){function e(e,t){var n=this;t||(t={}),st.call(this,e),this.d=new _e(t,(function(e,t,r){n.ondata(e,t,r)})),this.compression=8,this.flag=et(t.level),this.terminate=this.d.terminate}return e.prototype.process=function(e,t){this.d.push(e,t)},e.prototype.push=function(e,t){st.prototype.push.call(this,e,t)},e}();t.AsyncZipDeflate=lt;var ct=function(){function e(e){this.ondata=e,this.u=[],this.d=1}return e.prototype.add=function(e){var t=this;if(2&this.d)throw"stream finished";var n=Qe(e.filename),r=n.length,o=e.comment,a=o&&Qe(o),s=r!=e.filename.length||a&&o.length!=a.length,u=r+it(e.extra)+30;if(r>65535)throw"filename too long";var l=new i(u);ot(l,0,e,n,s);var c=[l],f=function(){for(var e=0,n=c;e65535&&E("filename too long",null),S)if(v<16e4)try{E(null,Se(l,p))}catch(e){E(e,null)}else f.push(xe(l,p,E));else E(null,l)},m=0;m65535)throw"filename too long";var g=f?Se(l,c):l,y=g.length,b=$();b.p(l),r.push(q(c,{size:l.length,crc:b.d(),c:g,f:E,m:p,u:d!=s.length||p&&h.length!=m,o,compression:f})),o+=30+d+v+y,a+=76+2*(d+v)+(m||0)+y}for(var w=new i(a+22),_=o,x=a-o,S=0;S0){var r=Math.min(this.c,e.length),o=e.subarray(0,r);if(this.c-=r,this.d?this.d.push(o,!this.c):this.k[0].push(o),(e=e.subarray(r)).length)return this.push(e,t)}else{var a=0,s=0,u=void 0,l=void 0;this.p.length?e.length?((l=new i(this.p.length+e.length)).set(this.p),l.set(e,this.p.length)):l=this.p:l=e;for(var c=l.length,f=this.c,d=f&&this.d,h=function(){var e,t=ce(l,s);if(67324752==t){a=1,u=s,p.d=null,p.c=0;var r=le(l,s+6),i=le(l,s+8),o=2048&r,d=8&r,h=le(l,s+26),m=le(l,s+28);if(c>s+30+h+m){var v=[];p.k.unshift(v),a=2;var g=ce(l,s+18),y=ce(l,s+22),b=Je(l.subarray(s+30,s+=30+h),!o);4294967295==g?(e=d?[-2]:rt(l,s),g=e[0],y=e[1]):d&&(g=-1),s+=m,p.c=g;var w={name:b,compression:i,start:function(){if(!w.ondata)throw"no callback";if(g){var e=n.o[i];if(!e)throw"unknown compression type "+i;var t=g<0?new e(b):new e(b,g,y);t.ondata=function(e,t,n){w.ondata(e,t,n)};for(var r=0,o=v;r=0&&(w.size=g,w.originalSize=y),p.onfile(w)}return"break"}if(f){if(134695760==t)return u=s+=12+(-2==f&&8),a=3,p.c=0,"break";if(33639248==t)return u=s-=4,a=3,p.c=0,"break"}},p=this;s65558)return void t("invalid zip file",null);var s=le(e,a+8);s||t(null,{});var u=s,l=ce(e,a+16),c=4294967295==l;if(c){if(a=ce(e,a-12),101075792!=ce(e,a))return void t("invalid zip file",null);u=s=ce(e,a+32),l=ce(e,a+48)}for(var f=function(a){var u=nt(e,l,c),f=u[0],d=u[1],h=u[2],p=u[3],m=u[4],v=u[5],g=tt(e,v);l=m;var y=function(e,n){e?(r(),t(e,null)):(o[p]=n,--s||t(null,o))};if(f)if(8==f){var b=e.subarray(g,g+d);if(d<32e4)try{y(null,Te(b,new i(h)))}catch(e){y(e,null)}else n.push(Oe(b,{size:h},y))}else y("unknown compression type "+f,null);else y(null,R(e,g,g+d))},d=0;d65558)throw"invalid zip file";var r=le(e,n+8);if(!r)return{};var o=ce(e,n+16),a=4294967295==o;if(a){if(n=ce(e,n-12),101075792!=ce(e,n))throw"invalid zip file";r=ce(e,n+32),o=ce(e,n+48)}for(var s=0;s{"use strict";var n={};t.default=function(e,t,r,i,o){var a=n[t]||(n[t]=URL.createObjectURL(new Blob([e],{type:"text/javascript"}))),s=new Worker(a);return s.onerror=function(e){return o(e.error,null)},s.onmessage=function(e){return o(null,e.data)},s.postMessage(r,i),s}},654302:e=>{"use strict";var t=Object.prototype.hasOwnProperty,n="function"==typeof WeakMap?new WeakMap:new Map;function r(e){var t=n.get(e);if(void 0!==t)return t;var r=new Map;return Object.getOwnPropertyNames(e).forEach((function(t){r.set(e[t],t)})),n.set(e,r),r}var i=Object.freeze(Object.defineProperties(Object.create(null),{isValid:{value:function(e){return r(this).has(e)}},cast:{value:function(e){return this.isValid(e)?e:void 0}},members:{value:function(){return r(this).keys()}},getName:{value:function(e){return r(this).get(e)}}}));function o(e){var n=Object.create(i);for(var r in e)t.call(e,r)&&Object.defineProperty(n,r,{value:e[r]});return Object.freeze(n)}var a=Object.freeze(Object.defineProperties(Object.create(null),{isValid:{value:function(e){return"string"==typeof e&&t.call(this,e)}},cast:{value:i.cast},members:{value:function(){return Object.getOwnPropertyNames(this)}},getName:{value:function(e){return e}}}));o.Mirrored=function(e){for(var t=Object.create(a),n=0,r=e.length;n{"use strict";n.r(t),n.d(t,{ucs2decode:()=>h,ucs2encode:()=>p,decode:()=>g,encode:()=>y,toASCII:()=>w,toUnicode:()=>b,default:()=>_});const r=2147483647,i=36,o=/^xn--/,a=/[^\0-\x7E]/,s=/[\x2E\u3002\uFF0E\uFF61]/g,u={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},l=Math.floor,c=String.fromCharCode;function f(e){throw new RangeError(u[e])}function d(e,t){const n=e.split("@");let r="";n.length>1&&(r=n[0]+"@",e=n[1]);const i=function(e,t){const n=[];let r=e.length;for(;r--;)n[r]=t(e[r]);return n}((e=e.replace(s,".")).split("."),t).join(".");return r+i}function h(e){const t=[];let n=0;const r=e.length;for(;n=55296&&i<=56319&&nString.fromCodePoint(...e),m=function(e,t){return e+22+75*(e<26)-((0!=t)<<5)},v=function(e,t,n){let r=0;for(e=n?l(e/700):e>>1,e+=l(e/t);e>455;r+=i)e=l(e/35);return l(r+36*e/(e+38))},g=function(e){const t=[],n=e.length;let o=0,a=128,s=72,u=e.lastIndexOf("-");u<0&&(u=0);for(let n=0;n=128&&f("not-basic"),t.push(e.charCodeAt(n));for(let d=u>0?u+1:0;d=n&&f("invalid-input");const u=(c=e.charCodeAt(d++))-48<10?c-22:c-65<26?c-65:c-97<26?c-97:i;(u>=i||u>l((r-o)/t))&&f("overflow"),o+=u*t;const h=a<=s?1:a>=s+26?26:a-s;if(ul(r/p)&&f("overflow"),t*=p}const h=t.length+1;s=v(o-u,h,0==u),l(o/h)>r-a&&f("overflow"),a+=l(o/h),o%=h,t.splice(o++,0,a)}var c;return String.fromCodePoint(...t)},y=function(e){const t=[];let n=(e=h(e)).length,o=128,a=0,s=72;for(const n of e)n<128&&t.push(c(n));let u=t.length,d=u;for(u&&t.push("-");d=o&&tl((r-a)/h)&&f("overflow"),a+=(n-o)*h,o=n;for(const n of e)if(nr&&f("overflow"),n==o){let e=a;for(let n=i;;n+=i){const r=n<=s?1:n>=s+26?26:n-s;if(e{function n(e,t){for(var n=e.length,r=new Array(n),i={},o=n;o--;)i[o]||a(e[o],o,[]);return r;function a(o,s,u){if(u.indexOf(o)>=0)throw new Error("Cyclic dependency: "+JSON.stringify(o));if(!~e.indexOf(o))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(o));if(!i[s]){i[s]=!0;var l=t.filter((function(e){return e[0]===o}));if(s=l.length){var c=u.concat(o);do{var f=l[--s][1];a(f,e.indexOf(f),c)}while(s)}r[--n]=o}}}e.exports=t=function(e){return n(function(e){for(var t=[],n=0,r=e.length;n{function t(e,t,n,r,i,o,a){try{var s=e[o](a),u=s.value}catch(e){return void n(e)}s.done?t(u):Promise.resolve(u).then(r,i)}e.exports=function(e){return function(){var n=this,r=arguments;return new Promise((function(i,o){var a=e.apply(n,r);function s(e){t(a,i,o,s,u,"next",e)}function u(e){t(a,i,o,s,u,"throw",e)}s(void 0)}))}},e.exports.default=e.exports,e.exports.__esModule=!0},859713:e=>{e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.default=e.exports,e.exports.__esModule=!0},967154:e=>{function t(){return e.exports=t=Object.assign||function(e){for(var t=1;t{e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.default=e.exports,e.exports.__esModule=!0},81109:(e,t,n)=>{var r=n(859713);function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}e.exports=function(e){for(var t=1;t{var r=n(337316);e.exports=function(e,t){if(null==e)return{};var n,i,o=r(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o},e.exports.default=e.exports,e.exports.__esModule=!0},337316:e=>{e.exports=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i},e.exports.default=e.exports,e.exports.__esModule=!0},34088:e=>{e.exports=function(){for(var e=arguments.length,t=[],n=0;n{var n; /*! Copyright (c) 2016 Jed Watson. Licensed under the MIT License (MIT), see http://jedwatson.github.io/classnames */!function(){"use strict";var r={}.hasOwnProperty;function i(){for(var e=[],t=0;t{"use strict";n.r(t),n.d(t,{default:()=>Ft});var r=Object.keys,i=Array.isArray,o="undefined"!=typeof self?self:"undefined"!=typeof window?window:n.g;function a(e,t){return"object"!=typeof t||r(t).forEach((function(n){e[n]=t[n]})),e}var s=Object.getPrototypeOf,u={}.hasOwnProperty;function l(e,t){return u.call(e,t)}function c(e,t){"function"==typeof t&&(t=t(s(e))),r(t).forEach((function(n){d(e,n,t[n])}))}var f=Object.defineProperty;function d(e,t,n,r){f(e,t,a(n&&l(n,"get")&&"function"==typeof n.get?{get:n.get,set:n.set,configurable:!0}:{value:n,configurable:!0,writable:!0},r))}function h(e){return{from:function(t){return e.prototype=Object.create(t.prototype),d(e.prototype,"constructor",e),{extend:c.bind(null,e.prototype)}}}}var p=Object.getOwnPropertyDescriptor;function m(e,t){var n;return p(e,t)||(n=s(e))&&m(n,t)}var v=[].slice;function g(e,t,n){return v.call(e,t,n)}function y(e,t){return t(e)}function b(e){if(!e)throw new Error("Assertion Failed")}function w(e){o.setImmediate?setImmediate(e):setTimeout(e,0)}function _(e,t){return e.reduce((function(e,n,r){var i=t(n,r);return i&&(e[i[0]]=i[1]),e}),{})}function x(e,t){return function(){try{e.apply(this,arguments)}catch(e){t(e)}}}function S(e,t,n){try{e.apply(null,n)}catch(e){t&&t(e)}}function E(e,t){if(l(e,t))return e[t];if(!t)return e;if("string"!=typeof t){for(var n=[],r=0,i=t.length;r=0)t=e;else for(var o in t=e.constructor?Object.create(e.constructor.prototype):{},e)l(e,o)&&(t[o]=N(e[o]));return t}function R(e,t,n,i){return n=n||{},i=i||"",r(e).forEach((function(r){if(l(t,r)){var o=e[r],a=t[r];"object"==typeof o&&"object"==typeof a&&o&&a&&""+o.constructor==""+a.constructor?R(o,a,n,i+r+"."):o!==a&&(n[i+r]=t[r])}else n[i+r]=void 0})),r(t).forEach((function(r){l(e,r)||(n[i+r]=t[r])})),n}var P="undefined"!=typeof Symbol&&Symbol.iterator,C=P?function(e){var t;return null!=e&&(t=e[P])&&t.apply(e)}:function(){return null},D={};function U(e){var t,n,r,o;if(1===arguments.length){if(i(e))return e.slice();if(this===D&&"string"==typeof e)return[e];if(o=C(e)){for(n=[];!(r=o.next()).done;)n.push(r.value);return n}if(null==e)return[e];if("number"==typeof(t=e.length)){for(n=new Array(t);t--;)n[t]=e[t];return n}return[e]}for(t=arguments.length,n=new Array(t);t--;)n[t]=arguments[t];return n}var I="undefined"!=typeof location&&/^(http|https):\/\/(localhost|127\.0\.0\.1)/.test(location.href);function j(e,t){I=e,L=t}var L=function(){return!0},F=!new Error("").stack;function z(){if(F)try{throw z.arguments,new Error}catch(e){return e}return new Error}function B(e,t){var n=e.stack;return n?(t=t||0,0===n.indexOf(e.name)&&(t+=(e.name+e.message).split("\n").length),n.split("\n").slice(t).filter(L).map((function(e){return"\n"+e})).join("")):""}var V=["Unknown","Constraint","Data","TransactionInactive","ReadOnly","Version","NotFound","InvalidState","InvalidAccess","Abort","Timeout","QuotaExceeded","Syntax","DataClone"],Y=["Modify","Bulk","OpenFailed","VersionChange","Schema","Upgrade","InvalidTable","MissingAPI","NoSuchDatabase","InvalidArgument","SubTransaction","Unsupported","Internal","DatabaseClosed","PrematureCommit","ForeignAwait"].concat(V),H={VersionChanged:"Database version changed by other database connection",DatabaseClosed:"Database has been closed",Abort:"Transaction aborted",TransactionInactive:"Transaction has already completed or failed"};function $(e,t){this._e=z(),this.name=e,this.message=t}function W(e,t,n,r){this._e=z(),this.failures=t,this.failedKeys=r,this.successCount=n}function G(e,t){this._e=z(),this.name="BulkError",this.failures=t,this.message=function(e,t){return e+". Errors: "+t.map((function(e){return e.toString()})).filter((function(e,t,n){return n.indexOf(e)===t})).join("\n")}(e,t)}h($).from(Error).extend({stack:{get:function(){return this._stack||(this._stack=this.name+": "+this.message+B(this._e,2))}},toString:function(){return this.name+": "+this.message}}),h(W).from($),h(G).from($);var q=Y.reduce((function(e,t){return e[t]=t+"Error",e}),{}),K=$,X=Y.reduce((function(e,t){var n=t+"Error";function r(e,r){this._e=z(),this.name=n,e?"string"==typeof e?(this.message=e,this.inner=r||null):"object"==typeof e&&(this.message=e.name+" "+e.message,this.inner=e):(this.message=H[t]||n,this.inner=null)}return h(r).from(K),e[t]=r,e}),{});X.Syntax=SyntaxError,X.Type=TypeError,X.Range=RangeError;var Z=V.reduce((function(e,t){return e[t+"Error"]=X[t],e}),{});var Q=Y.reduce((function(e,t){return-1===["Syntax","Type","Range"].indexOf(t)&&(e[t+"Error"]=X[t]),e}),{});function J(){}function ee(e){return e}function te(e,t){return null==e||e===ee?t:function(n){return t(e(n))}}function ne(e,t){return function(){e.apply(this,arguments),t.apply(this,arguments)}}function re(e,t){return e===J?t:function(){var n=e.apply(this,arguments);void 0!==n&&(arguments[0]=n);var r=this.onsuccess,i=this.onerror;this.onsuccess=null,this.onerror=null;var o=t.apply(this,arguments);return r&&(this.onsuccess=this.onsuccess?ne(r,this.onsuccess):r),i&&(this.onerror=this.onerror?ne(i,this.onerror):i),void 0!==o?o:n}}function ie(e,t){return e===J?t:function(){e.apply(this,arguments);var n=this.onsuccess,r=this.onerror;this.onsuccess=this.onerror=null,t.apply(this,arguments),n&&(this.onsuccess=this.onsuccess?ne(n,this.onsuccess):n),r&&(this.onerror=this.onerror?ne(r,this.onerror):r)}}function oe(e,t){return e===J?t:function(n){var r=e.apply(this,arguments);a(n,r);var i=this.onsuccess,o=this.onerror;this.onsuccess=null,this.onerror=null;var s=t.apply(this,arguments);return i&&(this.onsuccess=this.onsuccess?ne(i,this.onsuccess):i),o&&(this.onerror=this.onerror?ne(o,this.onerror):o),void 0===r?void 0===s?void 0:s:a(r,s)}}function ae(e,t){return e===J?t:function(){return!1!==t.apply(this,arguments)&&e.apply(this,arguments)}}function se(e,t){return e===J?t:function(){var n=e.apply(this,arguments);if(n&&"function"==typeof n.then){for(var r=this,i=arguments.length,o=new Array(i);i--;)o[i]=arguments[i];return n.then((function(){return t.apply(r,o)}))}return t.apply(this,arguments)}}Q.ModifyError=W,Q.DexieError=$,Q.BulkError=G;var ue={},le=function(){try{return new Function("let F=async ()=>{},p=F();return [p,Object.getPrototypeOf(p),Promise.resolve(),F.constructor];")()}catch(t){var e=o.Promise;return e?[e.resolve(),e.prototype,e.resolve()]:[]}}(),ce=le[0],fe=le[1],de=le[2],he=fe&&fe.then,pe=ce&&ce.constructor,me=le[3],ve=!!de,ge=!1,ye=de?function(){de.then(Be)}:o.setImmediate?setImmediate.bind(null,Be):o.MutationObserver?function(){var e=document.createElement("div");new MutationObserver((function(){Be(),e=null})).observe(e,{attributes:!0}),e.setAttribute("i","1")}:function(){setTimeout(Be,0)},be=function(e,t){Ae.push([e,t]),_e&&(ye(),_e=!1)},we=!0,_e=!0,xe=[],Se=[],Ee=null,ke=ee,Oe={id:"global",global:!0,ref:0,unhandleds:[],onunhandled:ft,txRelaxedDurabilityEnabled:!1,pgp:!1,env:{},finalize:function(){this.unhandleds.forEach((function(e){try{ft(e[0],e[1])}catch(e){}}))}},Te=Oe,Ae=[],Me=0,Ne=[];function Re(e){if("object"!=typeof this)throw new TypeError("Promises must be constructed via new");this._listeners=[],this.onuncatched=J,this._lib=!1;var t=this._PSD=Te;if(I&&(this._stackHolder=z(),this._prev=null,this._numPrev=0),"function"!=typeof e){if(e!==ue)throw new TypeError("Not a function");return this._state=arguments[1],this._value=arguments[2],void(!1===this._state&&Ue(this,this._value))}this._state=null,this._value=null,++t.ref,De(this,e)}var Pe={get:function(){var e=Te,t=Ze;function n(n,r){var i=this,o=!e.global&&(e!==Te||t!==Ze);o&&tt();var a=new Re((function(t,a){je(i,new Ce(ut(n,e,o),ut(r,e,o),t,a,e))}));return I&&ze(a,this),a}return n.prototype=ue,n},set:function(e){d(this,"then",e&&e.prototype===ue?Pe:{get:function(){return e},set:Pe.set})}};function Ce(e,t,n,r,i){this.onFulfilled="function"==typeof e?e:null,this.onRejected="function"==typeof t?t:null,this.resolve=n,this.reject=r,this.psd=i}function De(e,t){try{t((function(t){if(null===e._state){if(t===e)throw new TypeError("A promise cannot be resolved with itself.");var n=e._lib&&Ve();t&&"function"==typeof t.then?De(e,(function(e,n){t instanceof Re?t._then(e,n):t.then(e,n)})):(e._state=!0,e._value=t,Ie(e)),n&&Ye()}}),Ue.bind(null,e))}catch(t){Ue(e,t)}}function Ue(e,t){if(Se.push(t),null===e._state){var n=e._lib&&Ve();t=ke(t),e._state=!1,e._value=t,I&&null!==t&&"object"==typeof t&&!t._promise&&S((function(){var n=m(t,"stack");t._promise=e,d(t,"stack",{get:function(){return ge?n&&(n.get?n.get.apply(t):n.value):e.stack}})})),function(e){xe.some((function(t){return t._value===e._value}))||xe.push(e)}(e),Ie(e),n&&Ye()}}function Ie(e){var t=e._listeners;e._listeners=[];for(var n=0,r=t.length;n0;)for(e=Ae,Ae=[],n=e.length,t=0;t0);we=!0,_e=!0}function He(){var e=xe;xe=[],e.forEach((function(e){e._PSD.onunhandled.call(null,e._value,e)}));for(var t=Ne.slice(0),n=t.length;n;)t[--n]()}function $e(e){return new Re(ue,!1,e)}function We(e,t){var n=Te;return function(){var r=Ve(),i=Te;try{return ot(n,!0),e.apply(this,arguments)}catch(e){t&&t(e)}finally{ot(i,!1),r&&Ye()}}}c(Re.prototype,{then:Pe,_then:function(e,t){je(this,new Ce(null,null,e,t,Te))},catch:function(e){if(1===arguments.length)return this.then(null,e);var t=arguments[0],n=arguments[1];return"function"==typeof t?this.then(null,(function(e){return e instanceof t?n(e):$e(e)})):this.then(null,(function(e){return e&&e.name===t?n(e):$e(e)}))},finally:function(e){return this.then((function(t){return e(),t}),(function(t){return e(),$e(t)}))},stack:{get:function(){if(this._stack)return this._stack;try{ge=!0;var e=Fe(this,[],20).join("\nFrom previous: ");return null!==this._state&&(this._stack=e),e}finally{ge=!1}}},timeout:function(e,t){var n=this;return e<1/0?new Re((function(r,i){var o=setTimeout((function(){return i(new X.Timeout(t))}),e);n.then(r,i).finally(clearTimeout.bind(null,o))})):this}}),"undefined"!=typeof Symbol&&Symbol.toStringTag&&d(Re.prototype,Symbol.toStringTag,"Promise"),Oe.env=at(),c(Re,{all:function(){var e=U.apply(null,arguments).map(nt);return new Re((function(t,n){0===e.length&&t([]);var r=e.length;e.forEach((function(i,o){return Re.resolve(i).then((function(n){e[o]=n,--r||t(e)}),n)}))}))},resolve:function(e){if(e instanceof Re)return e;if(e&&"function"==typeof e.then)return new Re((function(t,n){e.then(t,n)}));var t=new Re(ue,!0,e);return ze(t,Ee),t},reject:$e,race:function(){var e=U.apply(null,arguments).map(nt);return new Re((function(t,n){e.map((function(e){return Re.resolve(e).then(t,n)}))}))},PSD:{get:function(){return Te},set:function(e){return Te=e}},newPSD:Je,usePSD:st,scheduler:{get:function(){return be},set:function(e){be=e}},rejectionMapper:{get:function(){return ke},set:function(e){ke=e}},follow:function(e,t){return new Re((function(n,r){return Je((function(t,n){var r=Te;r.unhandleds=[],r.onunhandled=n,r.finalize=ne((function(){var e=this;!function(e){function t(){e(),Ne.splice(Ne.indexOf(t),1)}Ne.push(t),++Me,be((function(){0==--Me&&He()}),[])}((function(){0===e.unhandleds.length?t():n(e.unhandleds[0])}))}),r.finalize),e()}),t,n,r)}))}});var Ge={awaits:0,echoes:0,id:0},qe=0,Ke=[],Xe=0,Ze=0,Qe=0;function Je(e,t,n,r){var i=Te,o=Object.create(i);o.parent=i,o.ref=0,o.global=!1,o.id=++Qe;var s=Oe.env;o.env=ve?{Promise:Re,PromiseProp:{value:Re,configurable:!0,writable:!0},all:Re.all,race:Re.race,resolve:Re.resolve,reject:Re.reject,nthen:lt(s.nthen,o),gthen:lt(s.gthen,o)}:{},t&&a(o,t),++i.ref,o.finalize=function(){--this.parent.ref||this.parent.finalize()};var u=st(o,e,n,r);return 0===o.ref&&o.finalize(),u}function et(){return Ge.id||(Ge.id=++qe),++Ge.awaits,Ge.echoes+=7,Ge.id}function tt(e){!Ge.awaits||e&&e!==Ge.id||(0==--Ge.awaits&&(Ge.id=0),Ge.echoes=7*Ge.awaits)}function nt(e){return Ge.echoes&&e&&e.constructor===pe?(et(),e.then((function(e){return tt(),e}),(function(e){return tt(),dt(e)}))):e}function rt(e){++Ze,Ge.echoes&&0!=--Ge.echoes||(Ge.echoes=Ge.id=0),Ke.push(Te),ot(e,!0)}function it(){var e=Ke[Ke.length-1];Ke.pop(),ot(e,!1)}function ot(e,t){var n,r=Te;if((t?!Ge.echoes||Xe++&&e===Te:!Xe||--Xe&&e===Te)||(n=t?rt.bind(null,e):it,he.call(ce,n)),e!==Te&&(Te=e,r===Oe&&(Oe.env=at()),ve)){var i=Oe.env.Promise,a=e.env;fe.then=a.nthen,i.prototype.then=a.gthen,(r.global||e.global)&&(Object.defineProperty(o,"Promise",a.PromiseProp),i.all=a.all,i.race=a.race,i.resolve=a.resolve,i.reject=a.reject)}}function at(){var e=o.Promise;return ve?{Promise:e,PromiseProp:Object.getOwnPropertyDescriptor(o,"Promise"),all:e.all,race:e.race,resolve:e.resolve,reject:e.reject,nthen:fe.then,gthen:e.prototype.then}:{}}function st(e,t,n,r,i){var o=Te;try{return ot(e,!0),t(n,r,i)}finally{ot(o,!1)}}function ut(e,t,n){return"function"!=typeof e?e:function(){var r=Te;n&&et(),ot(t,!0);try{return e.apply(this,arguments)}finally{ot(r,!1)}}}function lt(e,t){return function(n,r){return e.call(this,ut(n,t,!1),ut(r,t,!1))}}var ct="unhandledrejection";function ft(e,t){var n;try{n=t.onuncatched(e)}catch(e){}if(!1!==n)try{var r,i={promise:t,reason:e};if(o.document&&document.createEvent?((r=document.createEvent("Event")).initEvent(ct,!0,!0),a(r,i)):o.CustomEvent&&a(r=new CustomEvent(ct,{detail:i}),i),r&&o.dispatchEvent&&(dispatchEvent(r),!o.PromiseRejectionEvent&&o.onunhandledrejection))try{o.onunhandledrejection(r)}catch(e){}r.defaultPrevented||console.warn("Unhandled rejection: "+(e.stack||e))}catch(e){}}var dt=Re.reject;function ht(e){var t={},n=function(n,r){if(r){for(var i=arguments.length,o=new Array(i-1);--i;)o[i-1]=arguments[i];return t[n].subscribe.apply(null,o),e}if("string"==typeof n)return t[n]};n.addEventType=s;for(var o=1,a=arguments.length;o.",wt="String expected.",_t=[],xt="undefined"!=typeof navigator&&/(MSIE|Trident|Edge)/.test(navigator.userAgent),St=xt,Et=xt,kt=function(e){return!/(dexie\.js|dexie\.min\.js)/.test(e)};function Ot(e,t){var n,s,u,f,h,p=Ot.dependencies,m=a({addons:Ot.addons,autoOpen:!0,indexedDB:p.indexedDB,IDBKeyRange:p.IDBKeyRange},t),v=m.addons,w=m.autoOpen,T=m.indexedDB,M=m.IDBKeyRange,P=this._dbSchema={},C=[],j=[],L={},F=null,V=null,Y=!1,H=null,$=!1,q="readonly",K="readwrite",Z=this,Q=new Re((function(e){n=e})),ne=new Re((function(e,t){s=t})),ae=!0,ue=!!Lt(T);function le(e){this._cfg={version:e,storesSource:null,dbschema:{},tables:{},contentUpgrade:null},this.stores({})}function ce(e,t,n){var i=Z._createTransaction(K,j,P);i.create(t),i._completion.catch(n);var o=i._reject.bind(i);Je((function(){Te.trans=i,0===e?(r(P).forEach((function(e){fe(t,e,P[e].primKey,P[e].indexes)})),Re.follow((function(){return Z.on.populate.fire(i)})).catch(o)):function(e,t,n){var i=[],o=C.filter((function(t){return t._cfg.version===e}))[0];if(!o)throw new X.Upgrade("Dexie specification of currently installed DB version is missing");P=Z._dbSchema=o._cfg.dbschema;var a=!1;function s(){return i.length?Re.resolve(i.shift()(t.idbtrans)).then(s):Re.resolve()}return C.filter((function(t){return t._cfg.version>e})).forEach((function(e){i.push((function(){var r=P,i=e._cfg.dbschema;Ie(r,n),Ie(i,n),P=Z._dbSchema=i;var o=function(e,t){var n={del:[],add:[],change:[]};for(var r in e)t[r]||n.del.push(r);for(r in t){var i=e[r],o=t[r];if(i){var a={name:r,def:o,recreate:!1,del:[],add:[],change:[]};if(i.primKey.src!==o.primKey.src)a.recreate=!0,n.change.push(a);else{var s=i.idxByName,u=o.idxByName;for(var l in s)u[l]||a.del.push(l);for(l in u){var c=s[l],f=u[l];c?c.src!==f.src&&a.change.push(f):a.add.push(f)}(a.del.length>0||a.add.length>0||a.change.length>0)&&n.change.push(a)}}else n.add.push([r,o])}return n}(r,i);if(o.add.forEach((function(e){fe(n,e[0],e[1].primKey,e[1].indexes)})),o.change.forEach((function(e){if(e.recreate)throw new X.Upgrade("Not yet support for changing primary key");var t=n.objectStore(e.name);e.add.forEach((function(e){de(t,e)})),e.change.forEach((function(e){t.deleteIndex(e.name),de(t,e)})),e.del.forEach((function(e){t.deleteIndex(e)}))})),e._cfg.contentUpgrade)return a=!0,Re.follow((function(){e._cfg.contentUpgrade(t)}))})),i.push((function(t){a&&St||function(e,t){for(var n=0;n0?e:t}function Ne(e,t){return T.cmp(e,t)}function Pe(e,t){return T.cmp(t,e)}function Ce(e,t){return et?-1:e===t?0:1}function Ue(e,t){return e?t?function(){return e.apply(this,arguments)&&t.apply(this,arguments)}:e:t}function Ie(e,t){for(var n=t.db.objectStoreNames,r=0;rMath.pow(2,62)?0:t.oldVersion)/10,i,n)}}),n),o.onsuccess=We((function(){if(i=null,F=o.result,_t.push(Z),ae)!function(){if(Z.verno=F.version/10,Z._dbSchema=P={},0===(j=g(F.objectStoreNames,0)).length)return;const e=Te.txRelaxedDurabilityEnabled?{durability:"relaxed"}:{durability:"default"};var t=F.transaction(jt(j),"readonly",e);j.forEach((function(e){for(var n=t.objectStore(e),r=n.keyPath,i=r&&"string"==typeof r&&-1!==r.indexOf("."),o=new Ut(r,r||"",!1,!1,!!n.autoIncrement,r&&"string"!=typeof r,i),a=[],s=0;s0)try{const e=Te.txRelaxedDurabilityEnabled?{durability:"relaxed"}:{durability:"default"};Ie(P,F.transaction(jt(F.objectStoreNames),q,e))}catch(e){}F.onversionchange=We((function(e){Z._vcFired=!0,Z.on("versionchange").fire(e)})),ue||"__dbnames"===e||pt.dbnames.put({name:e}).catch(J),t()}),n)}))]).then((function(){return H=[],Re.resolve(Ot.vip(Z.on.ready.fire)).then((function e(){if(H.length>0){var t=H.reduce(se,J);return H=[],Re.resolve(Ot.vip(t)).then(e)}}))})).finally((function(){H=null})).then((function(){return Y=!1,Z})).catch((function(e){try{i&&i.abort()}catch(e){}return Y=!1,Z.close(),dt(V=e)})).finally((function(){$=!0,t()}))},this.close=function(){var e=_t.indexOf(Z);if(e>=0&&_t.splice(e,1),F){try{F.close()}catch(e){}F=null}w=!1,V=new X.DatabaseClosed,Y&&s(V),Q=new Re((function(e){n=e})),ne=new Re((function(e,t){s=t}))},this.delete=function(){var t=arguments.length>0;return new Re((function(n,r){if(t)throw new X.InvalidArgument("Arguments not allowed in db.delete()");function i(){Z.close();var t=T.deleteDatabase(e);t.onsuccess=We((function(){ue||pt.dbnames.delete(e).catch(J),n()})),t.onerror=Nt(r),t.onblocked=je}Y?Q.then(i):i()}))},this.backendDB=function(){return F},this.isOpen=function(){return null!==F},this.hasBeenClosed=function(){return V&&V instanceof X.DatabaseClosed},this.hasFailed=function(){return null!==V},this.dynamicallyOpened=function(){return ae},this.name=e,c(this,{tables:{get:function(){return r(L).map((function(e){return L[e]}))}}}),this.on=ht(this,"populate","blocked","versionchange",{ready:[se,J]}),this.on.ready.subscribe=y(this.on.ready.subscribe,(function(e){return function(t,n){Ot.vip((function(){$?(V||Re.resolve().then(t),n&&e(t)):H?(H.push(t),n&&e(t)):(e(t),n||e((function e(){Z.on.ready.unsubscribe(t),Z.on.ready.unsubscribe(e)})))}))}})),this.transaction=function(){var e=ve.apply(this,arguments);return this._transaction.apply(this,e)},this._transaction=function(e,t,n){var r=Te.trans;r&&r.db===Z&&-1===e.indexOf("!")||(r=null);var i=-1!==e.indexOf("?");e=e.replace("!","").replace("?","");try{var o=t.map((function(e){var t=e instanceof ge?e.name:e;if("string"!=typeof t)throw new TypeError("Invalid table argument to Dexie.transaction(). Only Table or String are allowed");return t}));if("r"==e||e==q)e=q;else{if("rw"!=e&&e!=K)throw new X.InvalidArgument("Invalid transaction mode: "+e);e=K}if(r){if(r.mode===q&&e===K){if(!i)throw new X.SubTransaction("Cannot enter a sub-transaction with READWRITE mode when parent transaction is READONLY");r=null}r&&o.forEach((function(e){if(r&&-1===r.storeNames.indexOf(e)){if(!i)throw new X.SubTransaction("Table "+e+" not included in parent transaction.");r=null}})),i&&r&&!r.active&&(r=null)}}catch(e){return r?r._promise(null,(function(t,n){n(e)})):dt(e)}return r?r._promise(e,a,"lock"):Te.trans?st(Te.transless,(function(){return Z._whenReady(a)})):Z._whenReady(a);function a(){return Re.resolve().then((function(){var t,i=Te.transless||Te,a=Z._createTransaction(e,o,P,r),s={trans:a,transless:i};r?a.idbtrans=r.idbtrans:a.create(),n.constructor===me&&et();var u=Re.follow((function(){if(t=n.call(a,a))if(t.constructor===pe){var e=tt.bind(null,null);t.then(e,e)}else"function"==typeof t.next&&"function"==typeof t.throw&&(t=Dt(t))}),s);return(t&&"function"==typeof t.then?Re.resolve(t).then((function(e){return a.active?e:dt(new X.PrematureCommit("Transaction committed too early. See http://bit.ly/2kdckMn"))})):u.then((function(){return t}))).then((function(e){return r&&a._resolve(),a._completion.then((function(){return e}))})).catch((function(e){return a._reject(e),dt(e)}))}))}},this.table=function(e){if(!l(L,e))throw new X.InvalidTable("Table "+e+" does not exist");return L[e]},c(ge.prototype,{_trans:function(e,t,n){var r=this._tx||Te.trans;return r&&r.db===Z?r===Te.trans?r._promise(e,t,n):Je((function(){return r._promise(e,t,n)}),{trans:r,transless:Te.transless||Te}):he(e,[this.name],t)},_idbstore:function(e,t,n){var r=this.name;return this._trans(e,(function(e,n,i){if(-1===i.storeNames.indexOf(r))throw new X.NotFound("Table"+r+" not part of transaction");return t(e,n,i.idbtrans.objectStore(r),i)}),n)},get:function(e,t){if(e&&e.constructor===Object)return this.where(e).first(t);var n=this;return this._idbstore(q,(function(t,r,i){var o=i.get(e);o.onerror=Nt(r),o.onsuccess=We((function(){t(n.hook.reading.fire(o.result))}),r)})).then(t)},where:function(e){if("string"==typeof e)return new _e(this,e);if(i(e))return new _e(this,"["+e.join("+")+"]");var t=r(e);if(1===t.length)return this.where(t[0]).equals(e[t[0]]);var n=this.schema.indexes.concat(this.schema.primKey).filter((function(e){return e.compound&&t.every((function(t){return e.keyPath.indexOf(t)>=0}))&&e.keyPath.every((function(e){return t.indexOf(e)>=0}))}))[0];if(n&>!==vt)return this.where(n.name).equals(n.keyPath.map((function(t){return e[t]})));n||console.warn("The query "+JSON.stringify(e)+" on "+this.name+" would benefit of a compound index ["+t.join("+")+"]");var o=this.schema.idxByName,a=t.reduce((function(t,n){return[t[0]||o[n],t[0]||!o[n]?Ue(t[1],(function(t){return""+E(t,n)==""+e[n]})):t[1]]}),[null,null]),s=a[0];return s?this.where(s.name).equals(e[s.keyPath]).filter(a[1]):n?this.filter(a[1]):this.where(t).equals("")},count:function(e){return this.toCollection().count(e)},offset:function(e){return this.toCollection().offset(e)},limit:function(e){return this.toCollection().limit(e)},reverse:function(){return this.toCollection().reverse()},filter:function(e){return this.toCollection().and(e)},each:function(e){return this.toCollection().each(e)},toArray:function(e){return this.toCollection().toArray(e)},orderBy:function(e){return new xe(new _e(this,i(e)?"["+e.join("+")+"]":e))},toCollection:function(){return new xe(new _e(this))},mapToClass:function(e,t){this.schema.mappedClass=e;var n=Object.create(e.prototype);t&&At(n,t),this.schema.instanceTemplate=n;var r=function(t){if(!t)return t;var n=Object.create(e.prototype);for(var r in t)if(l(t,r))try{n[r]=t[r]}catch(e){}return n};return this.schema.readHook&&this.hook.reading.unsubscribe(this.schema.readHook),this.schema.readHook=r,this.hook("reading",r),e},defineClass:function(e){return this.mapToClass(Ot.defineClass(e),e)},bulkDelete:function(e){return this.hook.deleting.fire===J?this._idbstore(K,(function(t,n,r,i){t(be(r,i,e,!1,J))})):this.where(":id").anyOf(e).delete().then((function(){}))},bulkPut:function(e,t){var n=this;return this._idbstore(K,(function(r,i,o){if(!o.keyPath&&!n.schema.primKey.auto&&!t)throw new X.InvalidArgument("bulkPut() with non-inbound keys requires keys array in second argument");if(o.keyPath&&t)throw new X.InvalidArgument("bulkPut(): keys argument invalid on tables with inbound keys");if(t&&t.length!==e.length)throw new X.InvalidArgument("Arguments objects and keys must have the same length");if(0===e.length)return r();var a,s,u=function(e){0===l.length?r(e):i(new G(n.name+".bulkPut(): "+l.length+" of "+c+" operations failed",l))},l=[],c=e.length,f=n;if(n.hook.creating.fire===J&&n.hook.updating.fire===J){s=ye(l);for(var d=0,h=e.length;d=0;--i){var o=p[i];(null==o||m[o])&&(n.push(e[i]),t&&r.push(o),null!=o&&(m[o]=null))}return n.reverse(),t&&r.reverse(),f.bulkAdd(n,r)})).then((function(e){var t=p[p.length-1];return null!=t?t:e})):f.bulkAdd(e)).then(u).catch(G,(function(e){l=l.concat(e.failures),u()})).catch(i)}}),"locked")},bulkAdd:function(e,t){var n=this,r=this.hook.creating.fire;return this._idbstore(K,(function(i,o,a,s){if(!a.keyPath&&!n.schema.primKey.auto&&!t)throw new X.InvalidArgument("bulkAdd() with non-inbound keys requires keys array in second argument");if(a.keyPath&&t)throw new X.InvalidArgument("bulkAdd(): keys argument invalid on tables with inbound keys");if(t&&t.length!==e.length)throw new X.InvalidArgument("Arguments objects and keys must have the same length");if(0===e.length)return i();function u(e){0===d.length?i(e):o(new G(n.name+".bulkAdd(): "+d.length+" of "+h+" operations failed",d))}var l,c,f,d=[],h=e.length;if(r!==J){var p,m=a.keyPath;c=ye(d,null,!0),f=Mt(null),S((function(){for(var n=0,i=e.length;n0&&!this._locked();){var e=this._blockedFuncs.shift();try{st(e[1],e[0])}catch(e){}}return this},_locked:function(){return this._reculock&&Te.lockOwnerFor!==this},create:function(e){var t=this;if(!this.mode)return this;if(b(!this.idbtrans),!e&&!F)switch(V&&V.name){case"DatabaseClosedError":throw new X.DatabaseClosed(V);case"MissingAPIError":throw new X.MissingAPI(V.message,V);default:throw new X.OpenFailed(V)}if(!this.active)throw new X.TransactionInactive;b(null===this._completion._state);const n=Te.txRelaxedDurabilityEnabled?{durability:"relaxed"}:{durability:"default"};return(e=this.idbtrans=e||F.transaction(jt(this.storeNames),this.mode,n)).onerror=We((function(n){Ct(n),t._reject(e.error)})),e.onabort=We((function(n){Ct(n),t.active&&t._reject(new X.Abort(e.error)),t.active=!1,t.on("abort").fire(n)})),e.oncomplete=We((function(){t.active=!1,t._resolve()})),this},_promise:function(e,t,n){var r=this;if(e===K&&this.mode!==K)return dt(new X.ReadOnly("Transaction is readonly"));if(!this.active)return dt(new X.TransactionInactive);if(this._locked())return new Re((function(i,o){r._blockedFuncs.push([function(){r._promise(e,t,n).then(i,o)},Te])}));if(n)return Je((function(){var e=new Re((function(e,n){r._lock();var i=t(e,n,r);i&&i.then&&i.then(e,n)}));return e.finally((function(){return r._unlock()})),e._lib=!0,e}));var i=new Re((function(e,n){var i=t(e,n,r);i&&i.then&&i.then(e,n)}));return i._lib=!0,i},_root:function(){return this.parent?this.parent._root():this},waitFor:function(e){var t=this._root();if(e=Re.resolve(e),t._waitingFor)t._waitingFor=t._waitingFor.then((function(){return e}));else{t._waitingFor=e,t._waitingQueue=[];var n=t.idbtrans.objectStore(t.storeNames[0]);!function e(){for(++t._spinCount;t._waitingQueue.length;)t._waitingQueue.shift()();t._waitingFor&&(n.get(-1/0).onsuccess=e)}()}var r=t._waitingFor;return new Re((function(n,i){e.then((function(e){return t._waitingQueue.push(We(n.bind(null,e)))}),(function(e){return t._waitingQueue.push(We(i.bind(null,e)))})).finally((function(){t._waitingFor===r&&(t._waitingFor=null)}))}))},abort:function(){this.active&&this._reject(new X.Abort),this.active=!1},tables:{get:(f="Transaction.tables",h=function(){return L},function(){return console.warn(f+" is deprecated. See https://github.com/dfahlander/Dexie.js/wiki/Deprecations. "+B(z(),1)),h.apply(this,arguments)})},table:function(e){return new ge(e,Z.table(e).schema,this)}}),c(_e.prototype,(function(){function e(e,t,n){var r=e instanceof _e?new xe(e):e;return r._ctx.error=n?new n(t):new TypeError(t),r}function t(e){return new xe(e,(function(){return M.only("")})).limit(0)}function n(e,t,n,r,i,o){for(var a=Math.min(e.length,r.length),s=-1,u=0;u=0?e.substr(0,s)+t[s]+n.substr(s+1):null;i(e[u],l)<0&&(s=u)}return a0)&&(p=g)}return t(null!==p?function(){e.continue(p+d)}:i),!1})),m}return{between:function(n,r,i,o){i=!1!==i,o=!0===o;try{return Ae(n,r)>0||0===Ae(n,r)&&(i||o)&&(!i||!o)?t(this):new xe(this,(function(){return M.bound(n,r,!i,!o)}))}catch(t){return e(this,bt)}},equals:function(e){return new xe(this,(function(){return M.only(e)}))},above:function(e){return new xe(this,(function(){return M.lowerBound(e,!0)}))},aboveOrEqual:function(e){return new xe(this,(function(){return M.lowerBound(e)}))},below:function(e){return new xe(this,(function(){return M.upperBound(e,!0)}))},belowOrEqual:function(e){return new xe(this,(function(){return M.upperBound(e)}))},startsWith:function(t){return"string"!=typeof t?e(this,wt):this.between(t,t+vt,!0,!0)},startsWithIgnoreCase:function(e){return""===e?this.startsWith(e):r(this,(function(e,t){return 0===e.indexOf(t[0])}),[e],vt)},equalsIgnoreCase:function(e){return r(this,(function(e,t){return e===t[0]}),[e],"")},anyOfIgnoreCase:function(){var e=U.apply(D,arguments);return 0===e.length?t(this):r(this,(function(e,t){return-1!==t.indexOf(e)}),e,"")},startsWithAnyOfIgnoreCase:function(){var e=U.apply(D,arguments);return 0===e.length?t(this):r(this,(function(e,t){return t.some((function(t){return 0===e.indexOf(t)}))}),e,vt)},anyOf:function(){var n=U.apply(D,arguments),r=Ne;try{n.sort(r)}catch(t){return e(this,bt)}if(0===n.length)return t(this);var i=new xe(this,(function(){return M.bound(n[0],n[n.length-1])}));i._ondirectionchange=function(e){r="next"===e?Ne:Pe,n.sort(r)};var o=0;return i._addAlgorithm((function(e,t,i){for(var a=e.key;r(a,n[o])>0;)if(++o===n.length)return t(i),!1;return 0===r(a,n[o])||(t((function(){e.continue(n[o])})),!1)})),i},notEqual:function(e){return this.inAnyRange([[yt,e],[e,gt]],{includeLowers:!1,includeUppers:!1})},noneOf:function(){var t=U.apply(D,arguments);if(0===t.length)return new xe(this);try{t.sort(Ne)}catch(t){return e(this,bt)}var n=t.reduce((function(e,t){return e?e.concat([[e[e.length-1][1],t]]):[[yt,t]]}),null);return n.push([t[t.length-1],gt]),this.inAnyRange(n,{includeLowers:!1,includeUppers:!1})},inAnyRange:function(n,r){if(0===n.length)return t(this);if(!n.every((function(e){return void 0!==e[0]&&void 0!==e[1]&&Ne(e[0],e[1])<=0})))return e(this,"First argument to inAnyRange() must be an Array of two-value Arrays [lower,upper] where upper must not be lower than lower",X.InvalidArgument);var i=!r||!1!==r.includeLowers,o=r&&!0===r.includeUppers;var a,s=Ne;function u(e,t){return s(e[0],t[0])}try{(a=n.reduce((function(e,t){for(var n=0,r=e.length;n0){i[0]=Ae(o=i[0],a=t[0])<0?o:a,i[1]=Me(i[1],t[1]);break}}var o,a;return n===r&&e.push(t),e}),[])).sort(u)}catch(t){return e(this,bt)}var l=0,c=o?function(e){return Ne(e,a[l][1])>0}:function(e){return Ne(e,a[l][1])>=0},f=i?function(e){return Pe(e,a[l][0])>0}:function(e){return Pe(e,a[l][0])>=0};var d=c,h=new xe(this,(function(){return M.bound(a[0][0],a[a.length-1][1],!i,!o)}));return h._ondirectionchange=function(e){"next"===e?(d=c,s=Ne):(d=f,s=Pe),a.sort(u)},h._addAlgorithm((function(e,t,n){for(var r=e.key;d(r);)if(++l===a.length)return t(n),!1;return!!function(e){return!c(e)&&!f(e)}(r)||(0===Ae(r,a[l][1])||0===Ae(r,a[l][0])||t((function(){s===Ne?e.continue(a[l][0]):e.continue(a[l][1])})),!1)})),h},startsWithAnyOf:function(){var n=U.apply(D,arguments);return n.every((function(e){return"string"==typeof e}))?0===n.length?t(this):this.inAnyRange(n.map((function(e){return[e,e+vt]}))):e(this,"startsWithAnyOf() only works with strings")}}})),c(xe.prototype,(function(){function e(e,t){e.filter=Ue(e.filter,t)}function t(e,t,n){var r=e.replayFilter;e.replayFilter=r?function(){return Ue(r(),t())}:t,e.justLimit=n&&!r}function n(e,t){if(e.isPrimKey)return t;var n=e.table.schema.idxByName[e.index];if(!n)throw new X.Schema("KeyPath "+e.index+" on object store "+t.name+" is not indexed");return t.index(n.name)}function i(e,t){var r=n(e,t);return e.keysOnly&&"openKeyCursor"in r?r.openKeyCursor(e.range||null,e.dir+e.unique):r.openCursor(e.range||null,e.dir+e.unique)}function o(e,t,n,r,o){var a=e.replayFilter?Ue(e.filter,e.replayFilter()):e.filter;e.or?function(){var s={},u=0;function c(){2==++u&&n()}function f(e,n,i){if(!a||a(n,i,c,r)){var o=n.primaryKey,u=""+o;"[object ArrayBuffer]"===u&&(u=""+new Uint8Array(o)),l(s,u)||(s[u]=!0,t(e,n,i))}}e.or._iterate(f,c,r,o),Oe(i(e,o),e.algorithm,f,c,r,!e.keysOnly&&e.valueMapper)}():Oe(i(e,o),Ue(e.algorithm,a),t,n,r,!e.keysOnly&&e.valueMapper)}return{_read:function(e,t){var n=this._ctx;return n.error?n.table._trans(null,dt.bind(null,n.error)):n.table._idbstore(q,e).then(t)},_write:function(e){var t=this._ctx;return t.error?t.table._trans(null,dt.bind(null,t.error)):t.table._idbstore(K,e,"locked")},_addAlgorithm:function(e){var t=this._ctx;t.algorithm=Ue(t.algorithm,e)},_iterate:function(e,t,n,r){return o(this._ctx,e,t,n,r)},clone:function(e){var t=Object.create(this.constructor.prototype),n=Object.create(this._ctx);return e&&a(n,e),t._ctx=n,t},raw:function(){return this._ctx.valueMapper=null,this},each:function(e){var t=this._ctx;return this._read((function(n,r,i){o(t,e,n,r,i)}))},count:function(e){var t=this._ctx;if(Se(t,!0))return this._read((function(e,r,i){var o=n(t,i),a=t.range?o.count(t.range):o.count();a.onerror=Nt(r),a.onsuccess=function(n){e(Math.min(n.target.result,t.limit))}}),e);var r=0;return this._read((function(e,n,i){o(t,(function(){return++r,!1}),(function(){e(r)}),n,i)}),e)},sortBy:function(e,t){var n=e.split(".").reverse(),r=n[0],i=n.length-1;function o(e,t){return t?o(e[n[t]],t-1):e[r]}var a="next"===this._ctx.dir?1:-1;function s(e,t){var n=o(e,i),r=o(t,i);return nr?a:0}return this.toArray((function(e){return e.sort(s)})).then(t)},toArray:function(e){var t=this._ctx;return this._read((function(e,r,i){if(u&&"next"===t.dir&&Se(t,!0)&&t.limit>0){var a=t.table.hook.reading.fire,s=n(t,i),l=t.limit<1/0?s.getAll(t.range,t.limit):s.getAll(t.range);l.onerror=Nt(r),l.onsuccess=Rt(a===ee?e:function(t){try{e(t.map(a))}catch(e){r(e)}})}else{var c=[];o(t,(function(e){c.push(e)}),(function(){e(c)}),r,i)}}),e)},offset:function(e){var n=this._ctx;return e<=0||(n.offset+=e,Se(n)?t(n,(function(){var t=e;return function(e,n){return 0===t||(1===t?(--t,!1):(n((function(){e.advance(t),t=0})),!1))}})):t(n,(function(){var t=e;return function(){return--t<0}}))),this},limit:function(e){return this._ctx.limit=Math.min(this._ctx.limit,e),t(this._ctx,(function(){var t=e;return function(e,n,r){return--t<=0&&n(r),t>=0}}),!0),this},until:function(t,n){return e(this._ctx,(function(e,r,i){return!t(e.value)||(r(i),n)})),this},first:function(e){return this.limit(1).toArray((function(e){return e[0]})).then(e)},last:function(e){return this.reverse().first(e)},filter:function(t){return e(this._ctx,(function(e){return t(e.value)})),function(e,t){e.isMatch=Ue(e.isMatch,t)}(this._ctx,t),this},and:function(e){return this.filter(e)},or:function(e){return new _e(this._ctx.table,e,this)},reverse:function(){return this._ctx.dir="prev"===this._ctx.dir?"next":"prev",this._ondirectionchange&&this._ondirectionchange(this._ctx.dir),this},desc:function(){return this.reverse()},eachKey:function(e){var t=this._ctx;return t.keysOnly=!t.isMatch,this.each((function(t,n){e(n.key,n)}))},eachUniqueKey:function(e){return this._ctx.unique="unique",this.eachKey(e)},eachPrimaryKey:function(e){var t=this._ctx;return t.keysOnly=!t.isMatch,this.each((function(t,n){e(n.primaryKey,n)}))},keys:function(e){var t=this._ctx;t.keysOnly=!t.isMatch;var n=[];return this.each((function(e,t){n.push(t.key)})).then((function(){return n})).then(e)},primaryKeys:function(e){var t=this._ctx;if(u&&"next"===t.dir&&Se(t,!0)&&t.limit>0)return this._read((function(e,r,i){var o=n(t,i),a=t.limit<1/0?o.getAllKeys(t.range,t.limit):o.getAllKeys(t.range);a.onerror=Nt(r),a.onsuccess=Rt(e)})).then(e);t.keysOnly=!t.isMatch;var r=[];return this.each((function(e,t){r.push(t.primaryKey)})).then((function(){return r})).then(e)},uniqueKeys:function(e){return this._ctx.unique="unique",this.keys(e)},firstKey:function(e){return this.limit(1).keys((function(e){return e[0]})).then(e)},lastKey:function(e){return this.reverse().firstKey(e)},distinct:function(){var t=this._ctx,n=t.index&&t.table.schema.idxByName[t.index];if(!n||!n.multi)return this;var r={};return e(this._ctx,(function(e){var t=e.primaryKey.toString(),n=l(r,t);return r[t]=!0,!n})),this},modify:function(e){var t=this,n=this._ctx.table.hook,i=n.updating.fire,o=n.deleting.fire;return this._write((function(n,s,u,c){var f;if("function"==typeof e)f=i===J&&o===J?e:function(t){var n=N(t);if(!1===e.call(this,t,this))return!1;if(l(this,"value")){var a=R(n,this.value),s=i.call(this,a,this.primKey,n,c);s&&(t=this.value,r(s).forEach((function(e){k(t,e,s[e])})))}else o.call(this,this.primKey,t,c)};else if(i===J){var d=r(e),h=d.length;f=function(t){for(var n=!1,r=0;r0?_():n(v))}t.clone().raw()._iterate((function(e,t){w=t.primaryKey;var n={primKey:t.primaryKey,value:e,onsuccess:null,onerror:null};function r(e){return y.push(e),b.push(n.primKey),x(),!0}if(!1!==f.call(n,e,n)){var i=!l(n,"value");++m,S((function(){var e=i?t.delete():t.update(n.value);e._hookCtx=n,e.onerror=Pt(r),e.onsuccess=Mt((function(){++v,x()}))}),r)}else n.onsuccess&&n.onsuccess(n.value)}),(function(){g=!0,x()}),_,u)}))},delete:function(){var e=this,t=this._ctx,n=t.range,r=t.table.hook.deleting.fire,i=r!==J;if(!i&&Se(t)&&(t.isPrimKey&&!Et||!n))return this._write((function(e,t,r){var i=Nt(t),o=n?r.count(n):r.count();o.onerror=i,o.onsuccess=function(){var a=o.result;S((function(){var t=n?r.delete(n):r.clear();t.onerror=i,t.onsuccess=function(){return e(a)}}),(function(e){return t(e)}))}}));var o=i?2e3:1e4;return this._write((function(n,a,s,u){var l=0,c=e.clone({keysOnly:!t.isMatch&&!i}).distinct().limit(o).raw(),f=[],d=function(){return c.each(i?function(e,t){f.push([t.primaryKey,t.value])}:function(e,t){f.push(t.primaryKey)}).then((function(){return i?f.sort((function(e,t){return Ne(e[0],t[0])})):f.sort(Ne),be(s,u,f,i,r)})).then((function(){var e=f.length;return l+=e,f=[],e0?console.warn("Another connection wants to upgrade database '"+Z.name+"'. Closing db now to resume the upgrade."):console.warn("Another connection wants to delete database '"+Z.name+"'. Closing db now to resume the delete request."),Z.close()})),Z.on("blocked",(function(e){!e.newVersion||e.newVersion1?n-1:0),i=1;i/gm),z=s(/^data-[\-\w.\u00B7-\uFFFF]/),B=s(/^aria-[\-\w]+$/),V=s(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Y=s(/^(?:\w+script|data):/i),H=s(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),$="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function W(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t0&&void 0!==arguments[0]?arguments[0]:G(),t=function(e){return K(e)};if(t.version="2.3.1",t.removed=[],!e||!e.document||9!==e.document.nodeType)return t.isSupported=!1,t;var n=e.document,r=e.document,i=e.DocumentFragment,o=e.HTMLTemplateElement,s=e.Node,u=e.Element,l=e.NodeFilter,c=e.NamedNodeMap,f=void 0===c?e.NamedNodeMap||e.MozNamedAttrMap:c,x=e.Text,S=e.Comment,X=e.DOMParser,Z=e.trustedTypes,Q=u.prototype,J=O(Q,"cloneNode"),ee=O(Q,"nextSibling"),te=O(Q,"childNodes"),ne=O(Q,"parentNode");if("function"==typeof o){var re=r.createElement("template");re.content&&re.content.ownerDocument&&(r=re.content.ownerDocument)}var ie=q(Z,n),oe=ie&&je?ie.createHTML(""):"",ae=r,se=ae.implementation,ue=ae.createNodeIterator,le=ae.createDocumentFragment,ce=ae.getElementsByTagName,fe=n.importNode,de={};try{de=k(r).documentMode?r.documentMode:{}}catch(e){}var he={};t.isSupported="function"==typeof ne&&se&&void 0!==se.createHTMLDocument&&9!==de;var pe=L,me=F,ve=z,ge=B,ye=Y,be=H,we=V,_e=null,xe=E({},[].concat(W(T),W(A),W(M),W(R),W(C))),Se=null,Ee=E({},[].concat(W(D),W(U),W(I),W(j))),ke=null,Oe=null,Te=!0,Ae=!0,Me=!1,Ne=!1,Re=!1,Pe=!1,Ce=!1,De=!1,Ue=!1,Ie=!0,je=!1,Le=!0,Fe=!0,ze=!1,Be={},Ve=null,Ye=E({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]),He=null,$e=E({},["audio","video","img","source","image","track"]),We=null,Ge=E({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),qe="http://www.w3.org/1998/Math/MathML",Ke="http://www.w3.org/2000/svg",Xe="http://www.w3.org/1999/xhtml",Ze=Xe,Qe=!1,Je=null,et=r.createElement("form"),tt=function(e){Je&&Je===e||(e&&"object"===(void 0===e?"undefined":$(e))||(e={}),e=k(e),_e="ALLOWED_TAGS"in e?E({},e.ALLOWED_TAGS):xe,Se="ALLOWED_ATTR"in e?E({},e.ALLOWED_ATTR):Ee,We="ADD_URI_SAFE_ATTR"in e?E(k(Ge),e.ADD_URI_SAFE_ATTR):Ge,He="ADD_DATA_URI_TAGS"in e?E(k($e),e.ADD_DATA_URI_TAGS):$e,Ve="FORBID_CONTENTS"in e?E({},e.FORBID_CONTENTS):Ye,ke="FORBID_TAGS"in e?E({},e.FORBID_TAGS):{},Oe="FORBID_ATTR"in e?E({},e.FORBID_ATTR):{},Be="USE_PROFILES"in e&&e.USE_PROFILES,Te=!1!==e.ALLOW_ARIA_ATTR,Ae=!1!==e.ALLOW_DATA_ATTR,Me=e.ALLOW_UNKNOWN_PROTOCOLS||!1,Ne=e.SAFE_FOR_TEMPLATES||!1,Re=e.WHOLE_DOCUMENT||!1,De=e.RETURN_DOM||!1,Ue=e.RETURN_DOM_FRAGMENT||!1,Ie=!1!==e.RETURN_DOM_IMPORT,je=e.RETURN_TRUSTED_TYPE||!1,Ce=e.FORCE_BODY||!1,Le=!1!==e.SANITIZE_DOM,Fe=!1!==e.KEEP_CONTENT,ze=e.IN_PLACE||!1,we=e.ALLOWED_URI_REGEXP||we,Ze=e.NAMESPACE||Xe,Ne&&(Ae=!1),Ue&&(De=!0),Be&&(_e=E({},[].concat(W(C))),Se=[],!0===Be.html&&(E(_e,T),E(Se,D)),!0===Be.svg&&(E(_e,A),E(Se,U),E(Se,j)),!0===Be.svgFilters&&(E(_e,M),E(Se,U),E(Se,j)),!0===Be.mathMl&&(E(_e,R),E(Se,I),E(Se,j))),e.ADD_TAGS&&(_e===xe&&(_e=k(_e)),E(_e,e.ADD_TAGS)),e.ADD_ATTR&&(Se===Ee&&(Se=k(Se)),E(Se,e.ADD_ATTR)),e.ADD_URI_SAFE_ATTR&&E(We,e.ADD_URI_SAFE_ATTR),e.FORBID_CONTENTS&&(Ve===Ye&&(Ve=k(Ve)),E(Ve,e.FORBID_CONTENTS)),Fe&&(_e["#text"]=!0),Re&&E(_e,["html","head","body"]),_e.table&&(E(_e,["tbody"]),delete ke.tbody),a&&a(e),Je=e)},nt=E({},["mi","mo","mn","ms","mtext"]),rt=E({},["foreignobject","desc","title","annotation-xml"]),it=E({},A);E(it,M),E(it,N);var ot=E({},R);E(ot,P);var at=function(e){var t=ne(e);t&&t.tagName||(t={namespaceURI:Xe,tagName:"template"});var n=m(e.tagName),r=m(t.tagName);if(e.namespaceURI===Ke)return t.namespaceURI===Xe?"svg"===n:t.namespaceURI===qe?"svg"===n&&("annotation-xml"===r||nt[r]):Boolean(it[n]);if(e.namespaceURI===qe)return t.namespaceURI===Xe?"math"===n:t.namespaceURI===Ke?"math"===n&&rt[r]:Boolean(ot[n]);if(e.namespaceURI===Xe){if(t.namespaceURI===Ke&&!rt[r])return!1;if(t.namespaceURI===qe&&!nt[r])return!1;var i=E({},["title","style","font","a","script"]);return!ot[n]&&(i[n]||!it[n])}return!1},st=function(e){p(t.removed,{element:e});try{e.parentNode.removeChild(e)}catch(t){try{e.outerHTML=oe}catch(t){e.remove()}}},ut=function(e,n){try{p(t.removed,{attribute:n.getAttributeNode(e),from:n})}catch(e){p(t.removed,{attribute:null,from:n})}if(n.removeAttribute(e),"is"===e&&!Se[e])if(De||Ue)try{st(n)}catch(e){}else try{n.setAttribute(e,"")}catch(e){}},lt=function(e){var t=void 0,n=void 0;if(Ce)e=""+e;else{var i=v(e,/^[\r\n\t ]+/);n=i&&i[0]}var o=ie?ie.createHTML(e):e;if(Ze===Xe)try{t=(new X).parseFromString(o,"text/html")}catch(e){}if(!t||!t.documentElement){t=se.createDocument(Ze,"template",null);try{t.documentElement.innerHTML=Qe?"":o}catch(e){}}var a=t.body||t.documentElement;return e&&n&&a.insertBefore(r.createTextNode(n),a.childNodes[0]||null),Ze===Xe?ce.call(t,Re?"html":"body")[0]:Re?t.documentElement:a},ct=function(e){return ue.call(e.ownerDocument||e,e,l.SHOW_ELEMENT|l.SHOW_COMMENT|l.SHOW_TEXT,null,!1)},ft=function(e){return!(e instanceof x||e instanceof S||"string"==typeof e.nodeName&&"string"==typeof e.textContent&&"function"==typeof e.removeChild&&e.attributes instanceof f&&"function"==typeof e.removeAttribute&&"function"==typeof e.setAttribute&&"string"==typeof e.namespaceURI&&"function"==typeof e.insertBefore)},dt=function(e){return"object"===(void 0===s?"undefined":$(s))?e instanceof s:e&&"object"===(void 0===e?"undefined":$(e))&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName},ht=function(e,n,r){he[e]&&d(he[e],(function(e){e.call(t,n,r,Je)}))},pt=function(e){var n=void 0;if(ht("beforeSanitizeElements",e,null),ft(e))return st(e),!0;if(v(e.nodeName,/[\u0080-\uFFFF]/))return st(e),!0;var r=m(e.nodeName);if(ht("uponSanitizeElement",e,{tagName:r,allowedTags:_e}),!dt(e.firstElementChild)&&(!dt(e.content)||!dt(e.content.firstElementChild))&&w(/<[/\w]/g,e.innerHTML)&&w(/<[/\w]/g,e.textContent))return st(e),!0;if("select"===r&&w(/