@drawo-app/drawo 2.0.7 → 2.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,79 @@
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index.es-Dqr-Y4Tn.js","assets/index-C2UxGHff.js","assets/index-C8x8KD-Y.css"])))=>i.map(i=>d[i]);
2
+ import{_ as mo}from"./index-C2UxGHff.js";function xe(n){"@babel/helpers - typeof";return xe=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xe(n)}var Qn=Uint8Array,Mn=Uint16Array,Ko=Int32Array,Xo=new Qn([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),$o=new Qn([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]),Bl=new Qn([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),Yu=function(n,t){for(var e=new Mn(31),i=0;i<31;++i)e[i]=t+=1<<n[i-1];for(var o=new Ko(e[30]),i=1;i<30;++i)for(var a=e[i];a<e[i+1];++a)o[a]=a-e[i]<<5|i;return{b:e,r:o}},Ju=Yu(Xo,2),_h=Ju.b,To=Ju.r;_h[28]=258,To[258]=28;var Ah=Yu($o,0),Ml=Ah.r,Do=new Mn(32768);for(var Ee=0;Ee<32768;++Ee){var Jr=(Ee&43690)>>1|(Ee&21845)<<1;Jr=(Jr&52428)>>2|(Jr&13107)<<2,Jr=(Jr&61680)>>4|(Jr&3855)<<4,Do[Ee]=((Jr&65280)>>8|(Jr&255)<<8)>>1}var Ia=(function(n,t,e){for(var i=n.length,o=0,a=new Mn(t);o<i;++o)n[o]&&++a[n[o]-1];var c=new Mn(t);for(o=1;o<t;++o)c[o]=c[o-1]+a[o-1]<<1;var l;if(e){l=new Mn(1<<t);var h=15-t;for(o=0;o<i;++o)if(n[o])for(var d=o<<4|n[o],m=t-n[o],_=c[n[o]-1]++<<m,k=_|(1<<m)-1;_<=k;++_)l[Do[_]>>h]=d}else for(l=new Mn(i),o=0;o<i;++o)n[o]&&(l[o]=Do[c[n[o]-1]++]>>15-n[o]);return l}),Li=new Qn(288);for(var Ee=0;Ee<144;++Ee)Li[Ee]=8;for(var Ee=144;Ee<256;++Ee)Li[Ee]=9;for(var Ee=256;Ee<280;++Ee)Li[Ee]=7;for(var Ee=280;Ee<288;++Ee)Li[Ee]=8;var Is=new Qn(32);for(var Ee=0;Ee<32;++Ee)Is[Ee]=5;var Nh=Ia(Li,9,0),Lh=Ia(Is,5,0),Ku=function(n){return(n+7)/8|0},Sh=function(n,t,e){return(e==null||e>n.length)&&(e=n.length),new Qn(n.subarray(t,e))},Cr=function(n,t,e){e<<=t&7;var i=t/8|0;n[i]|=e,n[i+1]|=e>>8},ka=function(n,t,e){e<<=t&7;var i=t/8|0;n[i]|=e,n[i+1]|=e>>8,n[i+2]|=e>>16},vo=function(n,t){for(var e=[],i=0;i<n.length;++i)n[i]&&e.push({s:i,f:n[i]});var o=e.length,a=e.slice();if(!o)return{t:$u,l:0};if(o==1){var c=new Qn(e[0].s+1);return c[e[0].s]=1,{t:c,l:1}}e.sort(function(it,vt){return it.f-vt.f}),e.push({s:-1,f:25001});var l=e[0],h=e[1],d=0,m=1,_=2;for(e[0]={s:-1,f:l.f+h.f,l,r:h};m!=o-1;)l=e[e[d].f<e[_].f?d++:_++],h=e[d!=m&&e[d].f<e[_].f?d++:_++],e[m++]={s:-1,f:l.f+h.f,l,r:h};for(var k=a[0].s,i=1;i<o;++i)a[i].s>k&&(k=a[i].s);var p=new Mn(k+1),j=qo(e[m-1],p,0);if(j>t){var i=0,O=0,M=j-t,S=1<<M;for(a.sort(function(vt,dt){return p[dt.s]-p[vt.s]||vt.f-dt.f});i<o;++i){var V=a[i].s;if(p[V]>t)O+=S-(1<<j-p[V]),p[V]=t;else break}for(O>>=M;O>0;){var G=a[i].s;p[G]<t?O-=1<<t-p[G]++-1:++i}for(;i>=0&&O;--i){var q=a[i].s;p[q]==t&&(--p[q],++O)}j=t}return{t:new Qn(p),l:j}},qo=function(n,t,e){return n.s==-1?Math.max(qo(n.l,t,e+1),qo(n.r,t,e+1)):t[n.s]=e},Rl=function(n){for(var t=n.length;t&&!n[--t];);for(var e=new Mn(++t),i=0,o=n[0],a=1,c=function(h){e[i++]=h},l=1;l<=t;++l)if(n[l]==o&&l!=t)++a;else{if(!o&&a>2){for(;a>138;a-=138)c(32754);a>2&&(c(a>10?a-11<<5|28690:a-3<<5|12305),a=0)}else if(a>3){for(c(o),--a;a>6;a-=6)c(8304);a>2&&(c(a-3<<5|8208),a=0)}for(;a--;)c(o);a=1,o=n[l]}return{c:e.subarray(0,i),n:t}},Pa=function(n,t){for(var e=0,i=0;i<t.length;++i)e+=n[i]*t[i];return e},Xu=function(n,t,e){var i=e.length,o=Ku(t+2);n[o]=i&255,n[o+1]=i>>8,n[o+2]=n[o]^255,n[o+3]=n[o+1]^255;for(var a=0;a<i;++a)n[o+a+4]=e[a];return(o+4+i)*8},Tl=function(n,t,e,i,o,a,c,l,h,d,m){Cr(t,m++,e),++o[256];for(var _=vo(o,15),k=_.t,p=_.l,j=vo(a,15),O=j.t,M=j.l,S=Rl(k),V=S.c,G=S.n,q=Rl(O),it=q.c,vt=q.n,dt=new Mn(19),X=0;X<V.length;++X)++dt[V[X]&31];for(var X=0;X<it.length;++X)++dt[it[X]&31];for(var R=vo(dt,7),tt=R.t,N=R.l,E=19;E>4&&!tt[Bl[E-1]];--E);var z=d+5<<3,U=Pa(o,Li)+Pa(a,Is)+c,rt=Pa(o,k)+Pa(a,O)+c+14+3*E+Pa(dt,tt)+2*dt[16]+3*dt[17]+7*dt[18];if(h>=0&&z<=U&&z<=rt)return Xu(t,m,n.subarray(h,h+d));var ot,ft,nt,ct;if(Cr(t,m,1+(rt<U)),m+=2,rt<U){ot=Ia(k,p,0),ft=k,nt=Ia(O,M,0),ct=O;var At=Ia(tt,N,0);Cr(t,m,G-257),Cr(t,m+5,vt-1),Cr(t,m+10,E-4),m+=14;for(var X=0;X<E;++X)Cr(t,m+3*X,tt[Bl[X]]);m+=3*E;for(var wt=[V,it],x=0;x<2;++x)for(var B=wt[x],X=0;X<B.length;++X){var T=B[X]&31;Cr(t,m,At[T]),m+=tt[T],T>15&&(Cr(t,m,B[X]>>5&127),m+=B[X]>>12)}}else ot=Nh,ft=Li,nt=Lh,ct=Is;for(var X=0;X<l;++X){var H=i[X];if(H>255){var T=H>>18&31;ka(t,m,ot[T+257]),m+=ft[T+257],T>7&&(Cr(t,m,H>>23&31),m+=Xo[T]);var J=H&31;ka(t,m,nt[J]),m+=ct[J],J>3&&(ka(t,m,H>>5&8191),m+=$o[J])}else ka(t,m,ot[H]),m+=ft[H]}return ka(t,m,ot[256]),m+ft[256]},kh=new Ko([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),$u=new Qn(0),Ph=function(n,t,e,i,o,a){var c=a.z||n.length,l=new Qn(i+c+5*(1+Math.ceil(c/7e3))+o),h=l.subarray(i,l.length-o),d=a.l,m=(a.r||0)&7;if(t){m&&(h[0]=a.r>>3);for(var _=kh[t-1],k=_>>13,p=_&8191,j=(1<<e)-1,O=a.p||new Mn(32768),M=a.h||new Mn(j+1),S=Math.ceil(e/3),V=2*S,G=function(Dt){return(n[Dt]^n[Dt+1]<<S^n[Dt+2]<<V)&j},q=new Ko(25e3),it=new Mn(288),vt=new Mn(32),dt=0,X=0,R=a.i||0,tt=0,N=a.w||0,E=0;R+2<c;++R){var z=G(R),U=R&32767,rt=M[z];if(O[U]=rt,M[z]=U,N<=R){var ot=c-R;if((dt>7e3||tt>24576)&&(ot>423||!d)){m=Tl(n,h,0,q,it,vt,X,tt,E,R-E,m),tt=dt=X=0,E=R;for(var ft=0;ft<286;++ft)it[ft]=0;for(var ft=0;ft<30;++ft)vt[ft]=0}var nt=2,ct=0,At=p,wt=U-rt&32767;if(ot>2&&z==G(R-wt))for(var x=Math.min(k,ot)-1,B=Math.min(32767,R),T=Math.min(258,ot);wt<=B&&--At&&U!=rt;){if(n[R+nt]==n[R+nt-wt]){for(var H=0;H<T&&n[R+H]==n[R+H-wt];++H);if(H>nt){if(nt=H,ct=wt,H>x)break;for(var J=Math.min(wt,H-2),Z=0,ft=0;ft<J;++ft){var at=R-wt+ft&32767,st=O[at],gt=at-st&32767;gt>Z&&(Z=gt,rt=at)}}}U=rt,rt=O[U],wt+=U-rt&32767}if(ct){q[tt++]=268435456|To[nt]<<18|Ml[ct];var _t=To[nt]&31,kt=Ml[ct]&31;X+=Xo[_t]+$o[kt],++it[257+_t],++vt[kt],N=R+nt,++dt}else q[tt++]=n[R],++it[n[R]]}}for(R=Math.max(R,N);R<c;++R)q[tt++]=n[R],++it[n[R]];m=Tl(n,h,d,q,it,vt,X,tt,E,R-E,m),d||(a.r=m&7|h[m/8|0]<<3,m-=7,a.h=M,a.p=O,a.i=R,a.w=N)}else{for(var R=a.w||0;R<c+d;R+=65535){var St=R+65535;St>=c&&(h[m/8|0]=d,St=c),m=Xu(h,m+1,n.subarray(R,St))}a.i=c}return Sh(l,0,i+Ku(m)+o)},Zu=function(){var n=1,t=0;return{p:function(e){for(var i=n,o=t,a=e.length|0,c=0;c!=a;){for(var l=Math.min(c+2655,a);c<l;++c)o+=i+=e[c];i=(i&65535)+15*(i>>16),o=(o&65535)+15*(o>>16)}n=i,t=o},d:function(){return n%=65521,t%=65521,(n&255)<<24|(n&65280)<<8|(t&255)<<8|t>>8}}},Ih=function(n,t,e,i,o){if(!o&&(o={l:1},t.dictionary)){var a=t.dictionary.subarray(-32768),c=new Qn(a.length+n.length);c.set(a),c.set(n,a.length),n=c,o.w=a.length}return Ph(n,t.level==null?6:t.level,t.mem==null?o.l?Math.ceil(Math.max(8,Math.min(13,Math.log(n.length)))*1.5):20:12+t.mem,e,i,o)},Qu=function(n,t,e){for(;e;++t)n[t]=e,e>>>=8},Ch=function(n,t){var e=t.level,i=e==0?0:e<6?1:e==9?3:2;if(n[0]=120,n[1]=i<<6|(t.dictionary&&32),n[1]|=31-(n[0]<<8|n[1])%31,t.dictionary){var o=Zu();o.p(t.dictionary),Qu(n,2,o.d())}};function Uo(n,t){t||(t={});var e=Zu();e.p(n);var i=Ih(n,t,t.dictionary?6:2,4);return Ch(i,t),Qu(i,i.length-4,e.d()),i}var Fh=typeof TextDecoder<"u"&&new TextDecoder,Eh=0;try{Fh.decode($u,{stream:!0}),Eh=1}catch{}function Oh(n){if(Array.isArray(n))return n}function jh(n,t){var e=n==null?null:typeof Symbol<"u"&&n[Symbol.iterator]||n["@@iterator"];if(e!=null){var i,o,a,c,l=[],h=!0,d=!1;try{if(a=(e=e.call(n)).next,t!==0)for(;!(h=(i=a.call(e)).done)&&(l.push(i.value),l.length!==t);h=!0);}catch(m){d=!0,o=m}finally{try{if(!h&&e.return!=null&&(c=e.return(),Object(c)!==c))return}finally{if(d)throw o}}return l}}function Dl(n,t){(t==null||t>n.length)&&(t=n.length);for(var e=0,i=Array(t);e<t;e++)i[e]=n[e];return i}function Bh(n,t){if(n){if(typeof n=="string")return Dl(n,t);var e={}.toString.call(n).slice(8,-1);return e==="Object"&&n.constructor&&(e=n.constructor.name),e==="Map"||e==="Set"?Array.from(n):e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?Dl(n,t):void 0}}function Mh(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
3
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ql(n,t){return Oh(n)||jh(n,t)||Bh(n,t)||Mh()}function Ul(n,t="utf8"){return new TextDecoder(t).decode(n)}const Rh=new TextEncoder;function Th(n){return Rh.encode(n)}const Dh=1024*8,qh=(()=>{const n=new Uint8Array(4),t=new Uint32Array(n.buffer);return!((t[0]=1)&n[0])})(),bo={int8:globalThis.Int8Array,uint8:globalThis.Uint8Array,int16:globalThis.Int16Array,uint16:globalThis.Uint16Array,int32:globalThis.Int32Array,uint32:globalThis.Uint32Array,uint64:globalThis.BigUint64Array,int64:globalThis.BigInt64Array,float32:globalThis.Float32Array,float64:globalThis.Float64Array};class Zo{buffer;byteLength;byteOffset;length;offset;lastWrittenByte;littleEndian;_data;_mark;_marks;constructor(t=Dh,e={}){let i=!1;typeof t=="number"?t=new ArrayBuffer(t):(i=!0,this.lastWrittenByte=t.byteLength);const o=e.offset?e.offset>>>0:0,a=t.byteLength-o;let c=o;(ArrayBuffer.isView(t)||t instanceof Zo)&&(t.byteLength!==t.buffer.byteLength&&(c=t.byteOffset+o),t=t.buffer),i?this.lastWrittenByte=a:this.lastWrittenByte=0,this.buffer=t,this.length=a,this.byteLength=a,this.byteOffset=c,this.offset=0,this.littleEndian=!0,this._data=new DataView(this.buffer,c,a),this._mark=0,this._marks=[]}available(t=1){return this.offset+t<=this.length}isLittleEndian(){return this.littleEndian}setLittleEndian(){return this.littleEndian=!0,this}isBigEndian(){return!this.littleEndian}setBigEndian(){return this.littleEndian=!1,this}skip(t=1){return this.offset+=t,this}back(t=1){return this.offset-=t,this}seek(t){return this.offset=t,this}mark(){return this._mark=this.offset,this}reset(){return this.offset=this._mark,this}pushMark(){return this._marks.push(this.offset),this}popMark(){const t=this._marks.pop();if(t===void 0)throw new Error("Mark stack empty");return this.seek(t),this}rewind(){return this.offset=0,this}ensureAvailable(t=1){if(!this.available(t)){const i=(this.offset+t)*2,o=new Uint8Array(i);o.set(new Uint8Array(this.buffer)),this.buffer=o.buffer,this.length=i,this.byteLength=i,this._data=new DataView(this.buffer)}return this}readBoolean(){return this.readUint8()!==0}readInt8(){return this._data.getInt8(this.offset++)}readUint8(){return this._data.getUint8(this.offset++)}readByte(){return this.readUint8()}readBytes(t=1){return this.readArray(t,"uint8")}readArray(t,e){const i=bo[e].BYTES_PER_ELEMENT*t,o=this.byteOffset+this.offset,a=this.buffer.slice(o,o+i);if(this.littleEndian===qh&&e!=="uint8"&&e!=="int8"){const l=new Uint8Array(this.buffer.slice(o,o+i));l.reverse();const h=new bo[e](l.buffer);return this.offset+=i,h.reverse(),h}const c=new bo[e](a);return this.offset+=i,c}readInt16(){const t=this._data.getInt16(this.offset,this.littleEndian);return this.offset+=2,t}readUint16(){const t=this._data.getUint16(this.offset,this.littleEndian);return this.offset+=2,t}readInt32(){const t=this._data.getInt32(this.offset,this.littleEndian);return this.offset+=4,t}readUint32(){const t=this._data.getUint32(this.offset,this.littleEndian);return this.offset+=4,t}readFloat32(){const t=this._data.getFloat32(this.offset,this.littleEndian);return this.offset+=4,t}readFloat64(){const t=this._data.getFloat64(this.offset,this.littleEndian);return this.offset+=8,t}readBigInt64(){const t=this._data.getBigInt64(this.offset,this.littleEndian);return this.offset+=8,t}readBigUint64(){const t=this._data.getBigUint64(this.offset,this.littleEndian);return this.offset+=8,t}readChar(){return String.fromCharCode(this.readInt8())}readChars(t=1){let e="";for(let i=0;i<t;i++)e+=this.readChar();return e}readUtf8(t=1){return Ul(this.readBytes(t))}decodeText(t=1,e="utf8"){return Ul(this.readBytes(t),e)}writeBoolean(t){return this.writeUint8(t?255:0),this}writeInt8(t){return this.ensureAvailable(1),this._data.setInt8(this.offset++,t),this._updateLastWrittenByte(),this}writeUint8(t){return this.ensureAvailable(1),this._data.setUint8(this.offset++,t),this._updateLastWrittenByte(),this}writeByte(t){return this.writeUint8(t)}writeBytes(t){this.ensureAvailable(t.length);for(let e=0;e<t.length;e++)this._data.setUint8(this.offset++,t[e]);return this._updateLastWrittenByte(),this}writeInt16(t){return this.ensureAvailable(2),this._data.setInt16(this.offset,t,this.littleEndian),this.offset+=2,this._updateLastWrittenByte(),this}writeUint16(t){return this.ensureAvailable(2),this._data.setUint16(this.offset,t,this.littleEndian),this.offset+=2,this._updateLastWrittenByte(),this}writeInt32(t){return this.ensureAvailable(4),this._data.setInt32(this.offset,t,this.littleEndian),this.offset+=4,this._updateLastWrittenByte(),this}writeUint32(t){return this.ensureAvailable(4),this._data.setUint32(this.offset,t,this.littleEndian),this.offset+=4,this._updateLastWrittenByte(),this}writeFloat32(t){return this.ensureAvailable(4),this._data.setFloat32(this.offset,t,this.littleEndian),this.offset+=4,this._updateLastWrittenByte(),this}writeFloat64(t){return this.ensureAvailable(8),this._data.setFloat64(this.offset,t,this.littleEndian),this.offset+=8,this._updateLastWrittenByte(),this}writeBigInt64(t){return this.ensureAvailable(8),this._data.setBigInt64(this.offset,t,this.littleEndian),this.offset+=8,this._updateLastWrittenByte(),this}writeBigUint64(t){return this.ensureAvailable(8),this._data.setBigUint64(this.offset,t,this.littleEndian),this.offset+=8,this._updateLastWrittenByte(),this}writeChar(t){return this.writeUint8(t.charCodeAt(0))}writeChars(t){for(let e=0;e<t.length;e++)this.writeUint8(t.charCodeAt(e));return this}writeUtf8(t){return this.writeBytes(Th(t))}toArray(){return new Uint8Array(this.buffer,this.byteOffset,this.lastWrittenByte)}getWrittenByteLength(){return this.lastWrittenByte-this.byteOffset}_updateLastWrittenByte(){this.offset>this.lastWrittenByte&&(this.lastWrittenByte=this.offset)}}function ra(n){let t=n.length;for(;--t>=0;)n[t]=0}const Uh=3,zh=258,tf=29,Hh=256,Wh=Hh+1+tf,ef=30,Vh=512,Gh=new Array((Wh+2)*2);ra(Gh);const Yh=new Array(ef*2);ra(Yh);const Jh=new Array(Vh);ra(Jh);const Kh=new Array(zh-Uh+1);ra(Kh);const Xh=new Array(tf);ra(Xh);const $h=new Array(ef);ra($h);const Zh=(n,t,e,i)=>{let o=n&65535|0,a=n>>>16&65535|0,c=0;for(;e!==0;){c=e>2e3?2e3:e,e-=c;do o=o+t[i++]|0,a=a+o|0;while(--c);o%=65521,a%=65521}return o|a<<16|0};var zo=Zh;const Qh=()=>{let n,t=[];for(var e=0;e<256;e++){n=e;for(var i=0;i<8;i++)n=n&1?3988292384^n>>>1:n>>>1;t[e]=n}return t},tc=new Uint32Array(Qh()),ec=(n,t,e,i)=>{const o=tc,a=i+e;n^=-1;for(let c=i;c<a;c++)n=n>>>8^o[(n^t[c])&255];return n^-1};var cr=ec,Ho={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},nf={Z_NO_FLUSH:0,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_DEFLATED:8};const nc=(n,t)=>Object.prototype.hasOwnProperty.call(n,t);var rc=function(n){const t=Array.prototype.slice.call(arguments,1);for(;t.length;){const e=t.shift();if(e){if(typeof e!="object")throw new TypeError(e+"must be non-object");for(const i in e)nc(e,i)&&(n[i]=e[i])}}return n},ic=n=>{let t=0;for(let i=0,o=n.length;i<o;i++)t+=n[i].length;const e=new Uint8Array(t);for(let i=0,o=0,a=n.length;i<a;i++){let c=n[i];e.set(c,o),o+=c.length}return e},rf={assign:rc,flattenChunks:ic};let af=!0;try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{af=!1}const Ba=new Uint8Array(256);for(let n=0;n<256;n++)Ba[n]=n>=252?6:n>=248?5:n>=240?4:n>=224?3:n>=192?2:1;Ba[254]=Ba[254]=1;var ac=n=>{if(typeof TextEncoder=="function"&&TextEncoder.prototype.encode)return new TextEncoder().encode(n);let t,e,i,o,a,c=n.length,l=0;for(o=0;o<c;o++)e=n.charCodeAt(o),(e&64512)===55296&&o+1<c&&(i=n.charCodeAt(o+1),(i&64512)===56320&&(e=65536+(e-55296<<10)+(i-56320),o++)),l+=e<128?1:e<2048?2:e<65536?3:4;for(t=new Uint8Array(l),a=0,o=0;a<l;o++)e=n.charCodeAt(o),(e&64512)===55296&&o+1<c&&(i=n.charCodeAt(o+1),(i&64512)===56320&&(e=65536+(e-55296<<10)+(i-56320),o++)),e<128?t[a++]=e:e<2048?(t[a++]=192|e>>>6,t[a++]=128|e&63):e<65536?(t[a++]=224|e>>>12,t[a++]=128|e>>>6&63,t[a++]=128|e&63):(t[a++]=240|e>>>18,t[a++]=128|e>>>12&63,t[a++]=128|e>>>6&63,t[a++]=128|e&63);return t};const sc=(n,t)=>{if(t<65534&&n.subarray&&af)return String.fromCharCode.apply(null,n.length===t?n:n.subarray(0,t));let e="";for(let i=0;i<t;i++)e+=String.fromCharCode(n[i]);return e};var oc=(n,t)=>{const e=t||n.length;if(typeof TextDecoder=="function"&&TextDecoder.prototype.decode)return new TextDecoder().decode(n.subarray(0,t));let i,o;const a=new Array(e*2);for(o=0,i=0;i<e;){let c=n[i++];if(c<128){a[o++]=c;continue}let l=Ba[c];if(l>4){a[o++]=65533,i+=l-1;continue}for(c&=l===2?31:l===3?15:7;l>1&&i<e;)c=c<<6|n[i++]&63,l--;if(l>1){a[o++]=65533;continue}c<65536?a[o++]=c:(c-=65536,a[o++]=55296|c>>10&1023,a[o++]=56320|c&1023)}return sc(a,o)},lc=(n,t)=>{t=t||n.length,t>n.length&&(t=n.length);let e=t-1;for(;e>=0&&(n[e]&192)===128;)e--;return e<0||e===0?t:e+Ba[n[e]]>t?e:t},Wo={string2buf:ac,buf2string:oc,utf8border:lc};function uc(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}var fc=uc;const ws=16209,hc=16191;var cc=function(t,e){let i,o,a,c,l,h,d,m,_,k,p,j,O,M,S,V,G,q,it,vt,dt,X,R,tt;const N=t.state;i=t.next_in,R=t.input,o=i+(t.avail_in-5),a=t.next_out,tt=t.output,c=a-(e-t.avail_out),l=a+(t.avail_out-257),h=N.dmax,d=N.wsize,m=N.whave,_=N.wnext,k=N.window,p=N.hold,j=N.bits,O=N.lencode,M=N.distcode,S=(1<<N.lenbits)-1,V=(1<<N.distbits)-1;t:do{j<15&&(p+=R[i++]<<j,j+=8,p+=R[i++]<<j,j+=8),G=O[p&S];e:for(;;){if(q=G>>>24,p>>>=q,j-=q,q=G>>>16&255,q===0)tt[a++]=G&65535;else if(q&16){it=G&65535,q&=15,q&&(j<q&&(p+=R[i++]<<j,j+=8),it+=p&(1<<q)-1,p>>>=q,j-=q),j<15&&(p+=R[i++]<<j,j+=8,p+=R[i++]<<j,j+=8),G=M[p&V];n:for(;;){if(q=G>>>24,p>>>=q,j-=q,q=G>>>16&255,q&16){if(vt=G&65535,q&=15,j<q&&(p+=R[i++]<<j,j+=8,j<q&&(p+=R[i++]<<j,j+=8)),vt+=p&(1<<q)-1,vt>h){t.msg="invalid distance too far back",N.mode=ws;break t}if(p>>>=q,j-=q,q=a-c,vt>q){if(q=vt-q,q>m&&N.sane){t.msg="invalid distance too far back",N.mode=ws;break t}if(dt=0,X=k,_===0){if(dt+=d-q,q<it){it-=q;do tt[a++]=k[dt++];while(--q);dt=a-vt,X=tt}}else if(_<q){if(dt+=d+_-q,q-=_,q<it){it-=q;do tt[a++]=k[dt++];while(--q);if(dt=0,_<it){q=_,it-=q;do tt[a++]=k[dt++];while(--q);dt=a-vt,X=tt}}}else if(dt+=_-q,q<it){it-=q;do tt[a++]=k[dt++];while(--q);dt=a-vt,X=tt}for(;it>2;)tt[a++]=X[dt++],tt[a++]=X[dt++],tt[a++]=X[dt++],it-=3;it&&(tt[a++]=X[dt++],it>1&&(tt[a++]=X[dt++]))}else{dt=a-vt;do tt[a++]=tt[dt++],tt[a++]=tt[dt++],tt[a++]=tt[dt++],it-=3;while(it>2);it&&(tt[a++]=tt[dt++],it>1&&(tt[a++]=tt[dt++]))}}else if((q&64)===0){G=M[(G&65535)+(p&(1<<q)-1)];continue n}else{t.msg="invalid distance code",N.mode=ws;break t}break}}else if((q&64)===0){G=O[(G&65535)+(p&(1<<q)-1)];continue e}else if(q&32){N.mode=hc;break t}else{t.msg="invalid literal/length code",N.mode=ws;break t}break}}while(i<o&&a<l);it=j>>3,i-=it,j-=it<<3,p&=(1<<j)-1,t.next_in=i,t.next_out=a,t.avail_in=i<o?5+(o-i):5-(i-o),t.avail_out=a<l?257+(l-a):257-(a-l),N.hold=p,N.bits=j};const Zi=15,zl=852,Hl=592,Wl=0,wo=1,Vl=2,dc=new Uint16Array([3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0]),pc=new Uint8Array([16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78]),gc=new Uint16Array([1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0]),mc=new Uint8Array([16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64]),vc=(n,t,e,i,o,a,c,l)=>{const h=l.bits;let d=0,m=0,_=0,k=0,p=0,j=0,O=0,M=0,S=0,V=0,G,q,it,vt,dt,X=null,R;const tt=new Uint16Array(Zi+1),N=new Uint16Array(Zi+1);let E=null,z,U,rt;for(d=0;d<=Zi;d++)tt[d]=0;for(m=0;m<i;m++)tt[t[e+m]]++;for(p=h,k=Zi;k>=1&&tt[k]===0;k--);if(p>k&&(p=k),k===0)return o[a++]=1<<24|64<<16|0,o[a++]=1<<24|64<<16|0,l.bits=1,0;for(_=1;_<k&&tt[_]===0;_++);for(p<_&&(p=_),M=1,d=1;d<=Zi;d++)if(M<<=1,M-=tt[d],M<0)return-1;if(M>0&&(n===Wl||k!==1))return-1;for(N[1]=0,d=1;d<Zi;d++)N[d+1]=N[d]+tt[d];for(m=0;m<i;m++)t[e+m]!==0&&(c[N[t[e+m]]++]=m);if(n===Wl?(X=E=c,R=20):n===wo?(X=dc,E=pc,R=257):(X=gc,E=mc,R=0),V=0,m=0,d=_,dt=a,j=p,O=0,it=-1,S=1<<p,vt=S-1,n===wo&&S>zl||n===Vl&&S>Hl)return 1;for(;;){z=d-O,c[m]+1<R?(U=0,rt=c[m]):c[m]>=R?(U=E[c[m]-R],rt=X[c[m]-R]):(U=96,rt=0),G=1<<d-O,q=1<<j,_=q;do q-=G,o[dt+(V>>O)+q]=z<<24|U<<16|rt|0;while(q!==0);for(G=1<<d-1;V&G;)G>>=1;if(G!==0?(V&=G-1,V+=G):V=0,m++,--tt[d]===0){if(d===k)break;d=t[e+c[m]]}if(d>p&&(V&vt)!==it){for(O===0&&(O=p),dt+=_,j=d-O,M=1<<j;j+O<k&&(M-=tt[j+O],!(M<=0));)j++,M<<=1;if(S+=1<<j,n===wo&&S>zl||n===Vl&&S>Hl)return 1;it=V&vt,o[it]=p<<24|j<<16|dt-a|0}}return V!==0&&(o[dt+V]=d-O<<24|64<<16|0),l.bits=p,0};var Ca=vc;const bc=0,sf=1,of=2,{Z_FINISH:Gl,Z_BLOCK:wc,Z_TREES:ys,Z_OK:Si,Z_STREAM_END:yc,Z_NEED_DICT:xc,Z_STREAM_ERROR:Wn,Z_DATA_ERROR:lf,Z_MEM_ERROR:uf,Z_BUF_ERROR:_c,Z_DEFLATED:Yl}=nf,Es=16180,Jl=16181,Kl=16182,Xl=16183,$l=16184,Zl=16185,Ql=16186,tu=16187,eu=16188,nu=16189,Cs=16190,Fr=16191,yo=16192,ru=16193,xo=16194,iu=16195,au=16196,su=16197,ou=16198,xs=16199,_s=16200,lu=16201,uu=16202,fu=16203,hu=16204,cu=16205,_o=16206,du=16207,pu=16208,Be=16209,ff=16210,hf=16211,Ac=852,Nc=592,Lc=15,Sc=Lc,gu=n=>(n>>>24&255)+(n>>>8&65280)+((n&65280)<<8)+((n&255)<<24);function kc(){this.strm=null,this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new Uint16Array(320),this.work=new Uint16Array(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}const Pi=n=>{if(!n)return 1;const t=n.state;return!t||t.strm!==n||t.mode<Es||t.mode>hf?1:0},cf=n=>{if(Pi(n))return Wn;const t=n.state;return n.total_in=n.total_out=t.total=0,n.msg="",t.wrap&&(n.adler=t.wrap&1),t.mode=Es,t.last=0,t.havedict=0,t.flags=-1,t.dmax=32768,t.head=null,t.hold=0,t.bits=0,t.lencode=t.lendyn=new Int32Array(Ac),t.distcode=t.distdyn=new Int32Array(Nc),t.sane=1,t.back=-1,Si},df=n=>{if(Pi(n))return Wn;const t=n.state;return t.wsize=0,t.whave=0,t.wnext=0,cf(n)},pf=(n,t)=>{let e;if(Pi(n))return Wn;const i=n.state;return t<0?(e=0,t=-t):(e=(t>>4)+5,t<48&&(t&=15)),t&&(t<8||t>15)?Wn:(i.window!==null&&i.wbits!==t&&(i.window=null),i.wrap=e,i.wbits=t,df(n))},gf=(n,t)=>{if(!n)return Wn;const e=new kc;n.state=e,e.strm=n,e.window=null,e.mode=Es;const i=pf(n,t);return i!==Si&&(n.state=null),i},Pc=n=>gf(n,Sc);let mu=!0,Ao,No;const Ic=n=>{if(mu){Ao=new Int32Array(512),No=new Int32Array(32);let t=0;for(;t<144;)n.lens[t++]=8;for(;t<256;)n.lens[t++]=9;for(;t<280;)n.lens[t++]=7;for(;t<288;)n.lens[t++]=8;for(Ca(sf,n.lens,0,288,Ao,0,n.work,{bits:9}),t=0;t<32;)n.lens[t++]=5;Ca(of,n.lens,0,32,No,0,n.work,{bits:5}),mu=!1}n.lencode=Ao,n.lenbits=9,n.distcode=No,n.distbits=5},mf=(n,t,e,i)=>{let o;const a=n.state;return a.window===null&&(a.wsize=1<<a.wbits,a.wnext=0,a.whave=0,a.window=new Uint8Array(a.wsize)),i>=a.wsize?(a.window.set(t.subarray(e-a.wsize,e),0),a.wnext=0,a.whave=a.wsize):(o=a.wsize-a.wnext,o>i&&(o=i),a.window.set(t.subarray(e-i,e-i+o),a.wnext),i-=o,i?(a.window.set(t.subarray(e-i,e),0),a.wnext=i,a.whave=a.wsize):(a.wnext+=o,a.wnext===a.wsize&&(a.wnext=0),a.whave<a.wsize&&(a.whave+=o))),0},Cc=(n,t)=>{let e,i,o,a,c,l,h,d,m,_,k,p,j,O,M=0,S,V,G,q,it,vt,dt,X;const R=new Uint8Array(4);let tt,N;const E=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]);if(Pi(n)||!n.output||!n.input&&n.avail_in!==0)return Wn;e=n.state,e.mode===Fr&&(e.mode=yo),c=n.next_out,o=n.output,h=n.avail_out,a=n.next_in,i=n.input,l=n.avail_in,d=e.hold,m=e.bits,_=l,k=h,X=Si;t:for(;;)switch(e.mode){case Es:if(e.wrap===0){e.mode=yo;break}for(;m<16;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}if(e.wrap&2&&d===35615){e.wbits===0&&(e.wbits=15),e.check=0,R[0]=d&255,R[1]=d>>>8&255,e.check=cr(e.check,R,2,0),d=0,m=0,e.mode=Jl;break}if(e.head&&(e.head.done=!1),!(e.wrap&1)||(((d&255)<<8)+(d>>8))%31){n.msg="incorrect header check",e.mode=Be;break}if((d&15)!==Yl){n.msg="unknown compression method",e.mode=Be;break}if(d>>>=4,m-=4,dt=(d&15)+8,e.wbits===0&&(e.wbits=dt),dt>15||dt>e.wbits){n.msg="invalid window size",e.mode=Be;break}e.dmax=1<<e.wbits,e.flags=0,n.adler=e.check=1,e.mode=d&512?nu:Fr,d=0,m=0;break;case Jl:for(;m<16;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}if(e.flags=d,(e.flags&255)!==Yl){n.msg="unknown compression method",e.mode=Be;break}if(e.flags&57344){n.msg="unknown header flags set",e.mode=Be;break}e.head&&(e.head.text=d>>8&1),e.flags&512&&e.wrap&4&&(R[0]=d&255,R[1]=d>>>8&255,e.check=cr(e.check,R,2,0)),d=0,m=0,e.mode=Kl;case Kl:for(;m<32;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}e.head&&(e.head.time=d),e.flags&512&&e.wrap&4&&(R[0]=d&255,R[1]=d>>>8&255,R[2]=d>>>16&255,R[3]=d>>>24&255,e.check=cr(e.check,R,4,0)),d=0,m=0,e.mode=Xl;case Xl:for(;m<16;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}e.head&&(e.head.xflags=d&255,e.head.os=d>>8),e.flags&512&&e.wrap&4&&(R[0]=d&255,R[1]=d>>>8&255,e.check=cr(e.check,R,2,0)),d=0,m=0,e.mode=$l;case $l:if(e.flags&1024){for(;m<16;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}e.length=d,e.head&&(e.head.extra_len=d),e.flags&512&&e.wrap&4&&(R[0]=d&255,R[1]=d>>>8&255,e.check=cr(e.check,R,2,0)),d=0,m=0}else e.head&&(e.head.extra=null);e.mode=Zl;case Zl:if(e.flags&1024&&(p=e.length,p>l&&(p=l),p&&(e.head&&(dt=e.head.extra_len-e.length,e.head.extra||(e.head.extra=new Uint8Array(e.head.extra_len)),e.head.extra.set(i.subarray(a,a+p),dt)),e.flags&512&&e.wrap&4&&(e.check=cr(e.check,i,p,a)),l-=p,a+=p,e.length-=p),e.length))break t;e.length=0,e.mode=Ql;case Ql:if(e.flags&2048){if(l===0)break t;p=0;do dt=i[a+p++],e.head&&dt&&e.length<65536&&(e.head.name+=String.fromCharCode(dt));while(dt&&p<l);if(e.flags&512&&e.wrap&4&&(e.check=cr(e.check,i,p,a)),l-=p,a+=p,dt)break t}else e.head&&(e.head.name=null);e.length=0,e.mode=tu;case tu:if(e.flags&4096){if(l===0)break t;p=0;do dt=i[a+p++],e.head&&dt&&e.length<65536&&(e.head.comment+=String.fromCharCode(dt));while(dt&&p<l);if(e.flags&512&&e.wrap&4&&(e.check=cr(e.check,i,p,a)),l-=p,a+=p,dt)break t}else e.head&&(e.head.comment=null);e.mode=eu;case eu:if(e.flags&512){for(;m<16;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}if(e.wrap&4&&d!==(e.check&65535)){n.msg="header crc mismatch",e.mode=Be;break}d=0,m=0}e.head&&(e.head.hcrc=e.flags>>9&1,e.head.done=!0),n.adler=e.check=0,e.mode=Fr;break;case nu:for(;m<32;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}n.adler=e.check=gu(d),d=0,m=0,e.mode=Cs;case Cs:if(e.havedict===0)return n.next_out=c,n.avail_out=h,n.next_in=a,n.avail_in=l,e.hold=d,e.bits=m,xc;n.adler=e.check=1,e.mode=Fr;case Fr:if(t===wc||t===ys)break t;case yo:if(e.last){d>>>=m&7,m-=m&7,e.mode=_o;break}for(;m<3;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}switch(e.last=d&1,d>>>=1,m-=1,d&3){case 0:e.mode=ru;break;case 1:if(Ic(e),e.mode=xs,t===ys){d>>>=2,m-=2;break t}break;case 2:e.mode=au;break;case 3:n.msg="invalid block type",e.mode=Be}d>>>=2,m-=2;break;case ru:for(d>>>=m&7,m-=m&7;m<32;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}if((d&65535)!==(d>>>16^65535)){n.msg="invalid stored block lengths",e.mode=Be;break}if(e.length=d&65535,d=0,m=0,e.mode=xo,t===ys)break t;case xo:e.mode=iu;case iu:if(p=e.length,p){if(p>l&&(p=l),p>h&&(p=h),p===0)break t;o.set(i.subarray(a,a+p),c),l-=p,a+=p,h-=p,c+=p,e.length-=p;break}e.mode=Fr;break;case au:for(;m<14;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}if(e.nlen=(d&31)+257,d>>>=5,m-=5,e.ndist=(d&31)+1,d>>>=5,m-=5,e.ncode=(d&15)+4,d>>>=4,m-=4,e.nlen>286||e.ndist>30){n.msg="too many length or distance symbols",e.mode=Be;break}e.have=0,e.mode=su;case su:for(;e.have<e.ncode;){for(;m<3;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}e.lens[E[e.have++]]=d&7,d>>>=3,m-=3}for(;e.have<19;)e.lens[E[e.have++]]=0;if(e.lencode=e.lendyn,e.lenbits=7,tt={bits:e.lenbits},X=Ca(bc,e.lens,0,19,e.lencode,0,e.work,tt),e.lenbits=tt.bits,X){n.msg="invalid code lengths set",e.mode=Be;break}e.have=0,e.mode=ou;case ou:for(;e.have<e.nlen+e.ndist;){for(;M=e.lencode[d&(1<<e.lenbits)-1],S=M>>>24,V=M>>>16&255,G=M&65535,!(S<=m);){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}if(G<16)d>>>=S,m-=S,e.lens[e.have++]=G;else{if(G===16){for(N=S+2;m<N;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}if(d>>>=S,m-=S,e.have===0){n.msg="invalid bit length repeat",e.mode=Be;break}dt=e.lens[e.have-1],p=3+(d&3),d>>>=2,m-=2}else if(G===17){for(N=S+3;m<N;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}d>>>=S,m-=S,dt=0,p=3+(d&7),d>>>=3,m-=3}else{for(N=S+7;m<N;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}d>>>=S,m-=S,dt=0,p=11+(d&127),d>>>=7,m-=7}if(e.have+p>e.nlen+e.ndist){n.msg="invalid bit length repeat",e.mode=Be;break}for(;p--;)e.lens[e.have++]=dt}}if(e.mode===Be)break;if(e.lens[256]===0){n.msg="invalid code -- missing end-of-block",e.mode=Be;break}if(e.lenbits=9,tt={bits:e.lenbits},X=Ca(sf,e.lens,0,e.nlen,e.lencode,0,e.work,tt),e.lenbits=tt.bits,X){n.msg="invalid literal/lengths set",e.mode=Be;break}if(e.distbits=6,e.distcode=e.distdyn,tt={bits:e.distbits},X=Ca(of,e.lens,e.nlen,e.ndist,e.distcode,0,e.work,tt),e.distbits=tt.bits,X){n.msg="invalid distances set",e.mode=Be;break}if(e.mode=xs,t===ys)break t;case xs:e.mode=_s;case _s:if(l>=6&&h>=258){n.next_out=c,n.avail_out=h,n.next_in=a,n.avail_in=l,e.hold=d,e.bits=m,cc(n,k),c=n.next_out,o=n.output,h=n.avail_out,a=n.next_in,i=n.input,l=n.avail_in,d=e.hold,m=e.bits,e.mode===Fr&&(e.back=-1);break}for(e.back=0;M=e.lencode[d&(1<<e.lenbits)-1],S=M>>>24,V=M>>>16&255,G=M&65535,!(S<=m);){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}if(V&&(V&240)===0){for(q=S,it=V,vt=G;M=e.lencode[vt+((d&(1<<q+it)-1)>>q)],S=M>>>24,V=M>>>16&255,G=M&65535,!(q+S<=m);){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}d>>>=q,m-=q,e.back+=q}if(d>>>=S,m-=S,e.back+=S,e.length=G,V===0){e.mode=cu;break}if(V&32){e.back=-1,e.mode=Fr;break}if(V&64){n.msg="invalid literal/length code",e.mode=Be;break}e.extra=V&15,e.mode=lu;case lu:if(e.extra){for(N=e.extra;m<N;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}e.length+=d&(1<<e.extra)-1,d>>>=e.extra,m-=e.extra,e.back+=e.extra}e.was=e.length,e.mode=uu;case uu:for(;M=e.distcode[d&(1<<e.distbits)-1],S=M>>>24,V=M>>>16&255,G=M&65535,!(S<=m);){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}if((V&240)===0){for(q=S,it=V,vt=G;M=e.distcode[vt+((d&(1<<q+it)-1)>>q)],S=M>>>24,V=M>>>16&255,G=M&65535,!(q+S<=m);){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}d>>>=q,m-=q,e.back+=q}if(d>>>=S,m-=S,e.back+=S,V&64){n.msg="invalid distance code",e.mode=Be;break}e.offset=G,e.extra=V&15,e.mode=fu;case fu:if(e.extra){for(N=e.extra;m<N;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}e.offset+=d&(1<<e.extra)-1,d>>>=e.extra,m-=e.extra,e.back+=e.extra}if(e.offset>e.dmax){n.msg="invalid distance too far back",e.mode=Be;break}e.mode=hu;case hu:if(h===0)break t;if(p=k-h,e.offset>p){if(p=e.offset-p,p>e.whave&&e.sane){n.msg="invalid distance too far back",e.mode=Be;break}p>e.wnext?(p-=e.wnext,j=e.wsize-p):j=e.wnext-p,p>e.length&&(p=e.length),O=e.window}else O=o,j=c-e.offset,p=e.length;p>h&&(p=h),h-=p,e.length-=p;do o[c++]=O[j++];while(--p);e.length===0&&(e.mode=_s);break;case cu:if(h===0)break t;o[c++]=e.length,h--,e.mode=_s;break;case _o:if(e.wrap){for(;m<32;){if(l===0)break t;l--,d|=i[a++]<<m,m+=8}if(k-=h,n.total_out+=k,e.total+=k,e.wrap&4&&k&&(n.adler=e.check=e.flags?cr(e.check,o,k,c-k):zo(e.check,o,k,c-k)),k=h,e.wrap&4&&(e.flags?d:gu(d))!==e.check){n.msg="incorrect data check",e.mode=Be;break}d=0,m=0}e.mode=du;case du:if(e.wrap&&e.flags){for(;m<32;){if(l===0)break t;l--,d+=i[a++]<<m,m+=8}if(e.wrap&4&&d!==(e.total&4294967295)){n.msg="incorrect length check",e.mode=Be;break}d=0,m=0}e.mode=pu;case pu:X=yc;break t;case Be:X=lf;break t;case ff:return uf;case hf:default:return Wn}return n.next_out=c,n.avail_out=h,n.next_in=a,n.avail_in=l,e.hold=d,e.bits=m,(e.wsize||k!==n.avail_out&&e.mode<Be&&(e.mode<_o||t!==Gl))&&mf(n,n.output,n.next_out,k-n.avail_out),_-=n.avail_in,k-=n.avail_out,n.total_in+=_,n.total_out+=k,e.total+=k,e.wrap&4&&k&&(n.adler=e.check=e.flags?cr(e.check,o,k,n.next_out-k):zo(e.check,o,k,n.next_out-k)),n.data_type=e.bits+(e.last?64:0)+(e.mode===Fr?128:0)+(e.mode===xs||e.mode===xo?256:0),(_===0&&k===0||t===Gl)&&X===Si&&(X=_c),X},Fc=n=>{if(Pi(n))return Wn;let t=n.state;return t.window&&(t.window=null),n.state=null,Si},Ec=(n,t)=>{if(Pi(n))return Wn;const e=n.state;return(e.wrap&2)===0?Wn:(e.head=t,t.done=!1,Si)},Oc=(n,t)=>{const e=t.length;let i,o,a;return Pi(n)||(i=n.state,i.wrap!==0&&i.mode!==Cs)?Wn:i.mode===Cs&&(o=1,o=zo(o,t,e,0),o!==i.check)?lf:(a=mf(n,t,e,e),a?(i.mode=ff,uf):(i.havedict=1,Si))};var jc=df,Bc=pf,Mc=cf,Rc=Pc,Tc=gf,Dc=Cc,qc=Fc,Uc=Ec,zc=Oc,Hc="pako inflate (from Nodeca project)",Er={inflateReset:jc,inflateReset2:Bc,inflateResetKeep:Mc,inflateInit:Rc,inflateInit2:Tc,inflate:Dc,inflateEnd:qc,inflateGetHeader:Uc,inflateSetDictionary:zc,inflateInfo:Hc};function Wc(){this.text=0,this.time=0,this.xflags=0,this.os=0,this.extra=null,this.extra_len=0,this.name="",this.comment="",this.hcrc=0,this.done=!1}var Vc=Wc;const vf=Object.prototype.toString,{Z_NO_FLUSH:Gc,Z_FINISH:Yc,Z_OK:Ma,Z_STREAM_END:Lo,Z_NEED_DICT:So,Z_STREAM_ERROR:Jc,Z_DATA_ERROR:vu,Z_MEM_ERROR:Kc}=nf;function Ta(n){this.options=rf.assign({chunkSize:1024*64,windowBits:15,to:""},n||{});const t=this.options;t.raw&&t.windowBits>=0&&t.windowBits<16&&(t.windowBits=-t.windowBits,t.windowBits===0&&(t.windowBits=-15)),t.windowBits>=0&&t.windowBits<16&&!(n&&n.windowBits)&&(t.windowBits+=32),t.windowBits>15&&t.windowBits<48&&(t.windowBits&15)===0&&(t.windowBits|=15),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new fc,this.strm.avail_out=0;let e=Er.inflateInit2(this.strm,t.windowBits);if(e!==Ma)throw new Error(Ho[e]);if(this.header=new Vc,Er.inflateGetHeader(this.strm,this.header),t.dictionary&&(typeof t.dictionary=="string"?t.dictionary=Wo.string2buf(t.dictionary):vf.call(t.dictionary)==="[object ArrayBuffer]"&&(t.dictionary=new Uint8Array(t.dictionary)),t.raw&&(e=Er.inflateSetDictionary(this.strm,t.dictionary),e!==Ma)))throw new Error(Ho[e])}Ta.prototype.push=function(n,t){const e=this.strm,i=this.options.chunkSize,o=this.options.dictionary;let a,c,l;if(this.ended)return!1;for(t===~~t?c=t:c=t===!0?Yc:Gc,vf.call(n)==="[object ArrayBuffer]"?e.input=new Uint8Array(n):e.input=n,e.next_in=0,e.avail_in=e.input.length;;){for(e.avail_out===0&&(e.output=new Uint8Array(i),e.next_out=0,e.avail_out=i),a=Er.inflate(e,c),a===So&&o&&(a=Er.inflateSetDictionary(e,o),a===Ma?a=Er.inflate(e,c):a===vu&&(a=So));e.avail_in>0&&a===Lo&&e.state.wrap>0&&n[e.next_in]!==0;)Er.inflateReset(e),a=Er.inflate(e,c);switch(a){case Jc:case vu:case So:case Kc:return this.onEnd(a),this.ended=!0,!1}if(l=e.avail_out,e.next_out&&(e.avail_out===0||a===Lo))if(this.options.to==="string"){let h=Wo.utf8border(e.output,e.next_out),d=e.next_out-h,m=Wo.buf2string(e.output,h);e.next_out=d,e.avail_out=i-d,d&&e.output.set(e.output.subarray(h,h+d),0),this.onData(m)}else this.onData(e.output.length===e.next_out?e.output:e.output.subarray(0,e.next_out));if(!(a===Ma&&l===0)){if(a===Lo)return a=Er.inflateEnd(this.strm),this.onEnd(a),this.ended=!0,!0;if(e.avail_in===0)break}}return!0};Ta.prototype.onData=function(n){this.chunks.push(n)};Ta.prototype.onEnd=function(n){n===Ma&&(this.options.to==="string"?this.result=this.chunks.join(""):this.result=rf.flattenChunks(this.chunks)),this.chunks=[],this.err=n,this.msg=this.strm.msg};function Xc(n,t){const e=new Ta(t);if(e.push(n),e.err)throw e.msg||Ho[e.err];return e.result}var $c=Ta,Zc=Xc,Qc={Inflate:$c,inflate:Zc};const{Inflate:t1,inflate:e1}=Qc;var bu=t1,n1=e1;const bf=[];for(let n=0;n<256;n++){let t=n;for(let e=0;e<8;e++)t&1?t=3988292384^t>>>1:t=t>>>1;bf[n]=t}const wu=4294967295;function r1(n,t,e){let i=n;for(let o=0;o<e;o++)i=bf[(i^t[o])&255]^i>>>8;return i}function i1(n,t){return(r1(wu,n,t)^wu)>>>0}function yu(n,t,e){const i=n.readUint32(),o=i1(new Uint8Array(n.buffer,n.byteOffset+n.offset-t-4,t),t);if(o!==i)throw new Error(`CRC mismatch for chunk ${e}. Expected ${i}, found ${o}`)}function wf(n,t,e){for(let i=0;i<e;i++)t[i]=n[i]}function yf(n,t,e,i){let o=0;for(;o<i;o++)t[o]=n[o];for(;o<e;o++)t[o]=n[o]+t[o-i]&255}function xf(n,t,e,i){let o=0;if(e.length===0)for(;o<i;o++)t[o]=n[o];else for(;o<i;o++)t[o]=n[o]+e[o]&255}function _f(n,t,e,i,o){let a=0;if(e.length===0){for(;a<o;a++)t[a]=n[a];for(;a<i;a++)t[a]=n[a]+(t[a-o]>>1)&255}else{for(;a<o;a++)t[a]=n[a]+(e[a]>>1)&255;for(;a<i;a++)t[a]=n[a]+(t[a-o]+e[a]>>1)&255}}function Af(n,t,e,i,o){let a=0;if(e.length===0){for(;a<o;a++)t[a]=n[a];for(;a<i;a++)t[a]=n[a]+t[a-o]&255}else{for(;a<o;a++)t[a]=n[a]+e[a]&255;for(;a<i;a++)t[a]=n[a]+a1(t[a-o],e[a],e[a-o])&255}}function a1(n,t,e){const i=n+t-e,o=Math.abs(i-n),a=Math.abs(i-t),c=Math.abs(i-e);return o<=a&&o<=c?n:a<=c?t:e}function s1(n,t,e,i,o,a){switch(n){case 0:wf(t,e,o);break;case 1:yf(t,e,o,a);break;case 2:xf(t,e,i,o);break;case 3:_f(t,e,i,o,a);break;case 4:Af(t,e,i,o,a);break;default:throw new Error(`Unsupported filter: ${n}`)}}const o1=new Uint16Array([255]),l1=new Uint8Array(o1.buffer),u1=l1[0]===255;function f1(n){const{data:t,width:e,height:i,channels:o,depth:a}=n,c=[{x:0,y:0,xStep:8,yStep:8},{x:4,y:0,xStep:8,yStep:8},{x:0,y:4,xStep:4,yStep:8},{x:2,y:0,xStep:4,yStep:4},{x:0,y:2,xStep:2,yStep:4},{x:1,y:0,xStep:2,yStep:2},{x:0,y:1,xStep:1,yStep:2}],l=Math.ceil(a/8)*o,h=new Uint8Array(i*e*l);let d=0;for(let m=0;m<7;m++){const _=c[m],k=Math.ceil((e-_.x)/_.xStep),p=Math.ceil((i-_.y)/_.yStep);if(k<=0||p<=0)continue;const j=k*l,O=new Uint8Array(j);for(let M=0;M<p;M++){const S=t[d++],V=t.subarray(d,d+j);d+=j;const G=new Uint8Array(j);s1(S,V,G,O,j,l),O.set(G);for(let q=0;q<k;q++){const it=_.x+q*_.xStep,vt=_.y+M*_.yStep;if(!(it>=e||vt>=i))for(let dt=0;dt<l;dt++)h[(vt*e+it)*l+dt]=G[q*l+dt]}}}if(a===16){const m=new Uint16Array(h.buffer);if(u1)for(let _=0;_<m.length;_++)m[_]=h1(m[_]);return m}else return h}function h1(n){return(n&255)<<8|n>>8&255}const c1=new Uint16Array([255]),d1=new Uint8Array(c1.buffer),p1=d1[0]===255,g1=new Uint8Array(0);function xu(n){const{data:t,width:e,height:i,channels:o,depth:a}=n,c=Math.ceil(a/8)*o,l=Math.ceil(a/8*o*e),h=new Uint8Array(i*l);let d=g1,m=0,_,k;for(let p=0;p<i;p++){switch(_=t.subarray(m+1,m+1+l),k=h.subarray(p*l,(p+1)*l),t[m]){case 0:wf(_,k,l);break;case 1:yf(_,k,l,c);break;case 2:xf(_,k,d,l);break;case 3:_f(_,k,d,l,c);break;case 4:Af(_,k,d,l,c);break;default:throw new Error(`Unsupported filter: ${t[m]}`)}d=k,m+=l+1}if(a===16){const p=new Uint16Array(h.buffer);if(p1)for(let j=0;j<p.length;j++)p[j]=m1(p[j]);return p}else return h}function m1(n){return(n&255)<<8|n>>8&255}const ks=Uint8Array.of(137,80,78,71,13,10,26,10);function _u(n){if(!v1(n.readBytes(ks.length)))throw new Error("wrong PNG signature")}function v1(n){if(n.length<ks.length)return!1;for(let t=0;t<ks.length;t++)if(n[t]!==ks[t])return!1;return!0}const b1="tEXt",w1=0,Nf=new TextDecoder("latin1");function y1(n){if(_1(n),n.length===0||n.length>79)throw new Error("keyword length must be between 1 and 79")}const x1=/^[\u0000-\u00FF]*$/;function _1(n){if(!x1.test(n))throw new Error("invalid latin1 text")}function A1(n,t,e){const i=Lf(t);n[i]=N1(t,e-i.length-1)}function Lf(n){for(n.mark();n.readByte()!==w1;);const t=n.offset;n.reset();const e=Nf.decode(n.readBytes(t-n.offset-1));return n.skip(1),y1(e),e}function N1(n,t){return Nf.decode(n.readBytes(t))}const Bn={UNKNOWN:-1,GREYSCALE:0,TRUECOLOUR:2,INDEXED_COLOUR:3,GREYSCALE_ALPHA:4,TRUECOLOUR_ALPHA:6},ko={UNKNOWN:-1,DEFLATE:0},Au={UNKNOWN:-1,ADAPTIVE:0},Po={UNKNOWN:-1,NO_INTERLACE:0,ADAM7:1},As={NONE:0,BACKGROUND:1,PREVIOUS:2},Io={SOURCE:0,OVER:1};class L1 extends Zo{_checkCrc;_inflator;_png;_apng;_end;_hasPalette;_palette;_hasTransparency;_transparency;_compressionMethod;_filterMethod;_interlaceMethod;_colorType;_isAnimated;_numberOfFrames;_numberOfPlays;_frames;_writingDataChunks;constructor(t,e={}){super(t);const{checkCrc:i=!1}=e;this._checkCrc=i,this._inflator=new bu,this._png={width:-1,height:-1,channels:-1,data:new Uint8Array(0),depth:1,text:{}},this._apng={width:-1,height:-1,channels:-1,depth:1,numberOfFrames:1,numberOfPlays:0,text:{},frames:[]},this._end=!1,this._hasPalette=!1,this._palette=[],this._hasTransparency=!1,this._transparency=new Uint16Array(0),this._compressionMethod=ko.UNKNOWN,this._filterMethod=Au.UNKNOWN,this._interlaceMethod=Po.UNKNOWN,this._colorType=Bn.UNKNOWN,this._isAnimated=!1,this._numberOfFrames=1,this._numberOfPlays=0,this._frames=[],this._writingDataChunks=!1,this.setBigEndian()}decode(){for(_u(this);!this._end;){const t=this.readUint32(),e=this.readChars(4);this.decodeChunk(t,e)}return this.decodeImage(),this._png}decodeApng(){for(_u(this);!this._end;){const t=this.readUint32(),e=this.readChars(4);this.decodeApngChunk(t,e)}return this.decodeApngImage(),this._apng}decodeChunk(t,e){const i=this.offset;switch(e){case"IHDR":this.decodeIHDR();break;case"PLTE":this.decodePLTE(t);break;case"IDAT":this.decodeIDAT(t);break;case"IEND":this._end=!0;break;case"tRNS":this.decodetRNS(t);break;case"iCCP":this.decodeiCCP(t);break;case b1:A1(this._png.text,this,t);break;case"pHYs":this.decodepHYs();break;default:this.skip(t);break}if(this.offset-i!==t)throw new Error(`Length mismatch while decoding chunk ${e}`);this._checkCrc?yu(this,t+4,e):this.skip(4)}decodeApngChunk(t,e){const i=this.offset;switch(e!=="fdAT"&&e!=="IDAT"&&this._writingDataChunks&&this.pushDataToFrame(),e){case"acTL":this.decodeACTL();break;case"fcTL":this.decodeFCTL();break;case"fdAT":this.decodeFDAT(t);break;default:this.decodeChunk(t,e),this.offset=i+t;break}if(this.offset-i!==t)throw new Error(`Length mismatch while decoding chunk ${e}`);this._checkCrc?yu(this,t+4,e):this.skip(4)}decodeIHDR(){const t=this._png;t.width=this.readUint32(),t.height=this.readUint32(),t.depth=S1(this.readUint8());const e=this.readUint8();this._colorType=e;let i;switch(e){case Bn.GREYSCALE:i=1;break;case Bn.TRUECOLOUR:i=3;break;case Bn.INDEXED_COLOUR:i=1;break;case Bn.GREYSCALE_ALPHA:i=2;break;case Bn.TRUECOLOUR_ALPHA:i=4;break;case Bn.UNKNOWN:default:throw new Error(`Unknown color type: ${e}`)}if(this._png.channels=i,this._compressionMethod=this.readUint8(),this._compressionMethod!==ko.DEFLATE)throw new Error(`Unsupported compression method: ${this._compressionMethod}`);this._filterMethod=this.readUint8(),this._interlaceMethod=this.readUint8()}decodeACTL(){this._numberOfFrames=this.readUint32(),this._numberOfPlays=this.readUint32(),this._isAnimated=!0}decodeFCTL(){const t={sequenceNumber:this.readUint32(),width:this.readUint32(),height:this.readUint32(),xOffset:this.readUint32(),yOffset:this.readUint32(),delayNumber:this.readUint16(),delayDenominator:this.readUint16(),disposeOp:this.readUint8(),blendOp:this.readUint8(),data:new Uint8Array(0)};this._frames.push(t)}decodePLTE(t){if(t%3!==0)throw new RangeError(`PLTE field length must be a multiple of 3. Got ${t}`);const e=t/3;this._hasPalette=!0;const i=[];this._palette=i;for(let o=0;o<e;o++)i.push([this.readUint8(),this.readUint8(),this.readUint8()])}decodeIDAT(t){this._writingDataChunks=!0;const e=t,i=this.offset+this.byteOffset;if(this._inflator.push(new Uint8Array(this.buffer,i,e)),this._inflator.err)throw new Error(`Error while decompressing the data: ${this._inflator.err}`);this.skip(t)}decodeFDAT(t){this._writingDataChunks=!0;let e=t,i=this.offset+this.byteOffset;if(i+=4,e-=4,this._inflator.push(new Uint8Array(this.buffer,i,e)),this._inflator.err)throw new Error(`Error while decompressing the data: ${this._inflator.err}`);this.skip(t)}decodetRNS(t){switch(this._colorType){case Bn.GREYSCALE:case Bn.TRUECOLOUR:{if(t%2!==0)throw new RangeError(`tRNS chunk length must be a multiple of 2. Got ${t}`);if(t/2>this._png.width*this._png.height)throw new Error(`tRNS chunk contains more alpha values than there are pixels (${t/2} vs ${this._png.width*this._png.height})`);this._hasTransparency=!0,this._transparency=new Uint16Array(t/2);for(let e=0;e<t/2;e++)this._transparency[e]=this.readUint16();break}case Bn.INDEXED_COLOUR:{if(t>this._palette.length)throw new Error(`tRNS chunk contains more alpha values than there are palette colors (${t} vs ${this._palette.length})`);let e=0;for(;e<t;e++){const i=this.readByte();this._palette[e].push(i)}for(;e<this._palette.length;e++)this._palette[e].push(255);break}case Bn.UNKNOWN:case Bn.GREYSCALE_ALPHA:case Bn.TRUECOLOUR_ALPHA:default:throw new Error(`tRNS chunk is not supported for color type ${this._colorType}`)}}decodeiCCP(t){const e=Lf(this),i=this.readUint8();if(i!==ko.DEFLATE)throw new Error(`Unsupported iCCP compression method: ${i}`);const o=this.readBytes(t-e.length-2);this._png.iccEmbeddedProfile={name:e,profile:n1(o)}}decodepHYs(){const t=this.readUint32(),e=this.readUint32(),i=this.readByte();this._png.resolution={x:t,y:e,unit:i}}decodeApngImage(){this._apng.width=this._png.width,this._apng.height=this._png.height,this._apng.channels=this._png.channels,this._apng.depth=this._png.depth,this._apng.numberOfFrames=this._numberOfFrames,this._apng.numberOfPlays=this._numberOfPlays,this._apng.text=this._png.text,this._apng.resolution=this._png.resolution;for(let t=0;t<this._numberOfFrames;t++){const e={sequenceNumber:this._frames[t].sequenceNumber,delayNumber:this._frames[t].delayNumber,delayDenominator:this._frames[t].delayDenominator,data:this._apng.depth===8?new Uint8Array(this._apng.width*this._apng.height*this._apng.channels):new Uint16Array(this._apng.width*this._apng.height*this._apng.channels)},i=this._frames.at(t);if(i){if(i.data=xu({data:i.data,width:i.width,height:i.height,channels:this._apng.channels,depth:this._apng.depth}),this._hasPalette&&(this._apng.palette=this._palette),this._hasTransparency&&(this._apng.transparency=this._transparency),t===0||i.xOffset===0&&i.yOffset===0&&i.width===this._png.width&&i.height===this._png.height)e.data=i.data;else{const o=this._apng.frames.at(t-1);this.disposeFrame(i,o,e),this.addFrameDataToCanvas(e,i)}this._apng.frames.push(e)}}return this._apng}disposeFrame(t,e,i){switch(t.disposeOp){case As.NONE:break;case As.BACKGROUND:for(let o=0;o<this._png.height;o++)for(let a=0;a<this._png.width;a++){const c=(o*t.width+a)*this._png.channels;for(let l=0;l<this._png.channels;l++)i.data[c+l]=0}break;case As.PREVIOUS:i.data.set(e.data);break;default:throw new Error("Unknown disposeOp")}}addFrameDataToCanvas(t,e){const i=1<<this._png.depth,o=(a,c)=>{const l=((a+e.yOffset)*this._png.width+e.xOffset+c)*this._png.channels,h=(a*e.width+c)*this._png.channels;return{index:l,frameIndex:h}};switch(e.blendOp){case Io.SOURCE:for(let a=0;a<e.height;a++)for(let c=0;c<e.width;c++){const{index:l,frameIndex:h}=o(a,c);for(let d=0;d<this._png.channels;d++)t.data[l+d]=e.data[h+d]}break;case Io.OVER:for(let a=0;a<e.height;a++)for(let c=0;c<e.width;c++){const{index:l,frameIndex:h}=o(a,c);for(let d=0;d<this._png.channels;d++){const m=e.data[h+this._png.channels-1]/i,_=d%(this._png.channels-1)===0?1:e.data[h+d],k=Math.floor(m*_+(1-m)*t.data[l+d]);t.data[l+d]+=k}}break;default:throw new Error("Unknown blendOp")}}decodeImage(){if(this._inflator.err)throw new Error(`Error while decompressing the data: ${this._inflator.err}`);const t=this._isAnimated?(this._frames?.at(0)).data:this._inflator.result;if(this._filterMethod!==Au.ADAPTIVE)throw new Error(`Filter method ${this._filterMethod} not supported`);if(this._interlaceMethod===Po.NO_INTERLACE)this._png.data=xu({data:t,width:this._png.width,height:this._png.height,channels:this._png.channels,depth:this._png.depth});else if(this._interlaceMethod===Po.ADAM7)this._png.data=f1({data:t,width:this._png.width,height:this._png.height,channels:this._png.channels,depth:this._png.depth});else throw new Error(`Interlace method ${this._interlaceMethod} not supported`);this._hasPalette&&(this._png.palette=this._palette),this._hasTransparency&&(this._png.transparency=this._transparency)}pushDataToFrame(){const t=this._inflator.result,e=this._frames.at(-1);e?e.data=t:this._frames.push({sequenceNumber:0,width:this._png.width,height:this._png.height,xOffset:0,yOffset:0,delayNumber:0,delayDenominator:0,disposeOp:As.NONE,blendOp:Io.SOURCE,data:t}),this._inflator=new bu,this._writingDataChunks=!1}}function S1(n){if(n!==1&&n!==2&&n!==4&&n!==8&&n!==16)throw new Error(`invalid bit depth: ${n}`);return n}var Nu;(function(n){n[n.UNKNOWN=0]="UNKNOWN",n[n.METRE=1]="METRE"})(Nu||(Nu={}));function k1(n,t){return new L1(n,t).decode()}var Kt=(function(){return typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:this})();function Co(){Kt.console&&typeof Kt.console.log=="function"&&Kt.console.log.apply(Kt.console,arguments)}var Le={log:Co,warn:function(n){Kt.console&&(typeof Kt.console.warn=="function"?Kt.console.warn.apply(Kt.console,arguments):Co.call(null,arguments))},error:function(n){Kt.console&&(typeof Kt.console.error=="function"?Kt.console.error.apply(Kt.console,arguments):Co(n))}};function Fo(n,t,e){var i=new XMLHttpRequest;i.open("GET",n),i.responseType="blob",i.onload=function(){wi(i.response,t,e)},i.onerror=function(){Le.error("could not download file")},i.send()}function Lu(n){var t=new XMLHttpRequest;t.open("HEAD",n,!1);try{t.send()}catch{}return t.status>=200&&t.status<=299}function Ns(n){try{n.dispatchEvent(new MouseEvent("click"))}catch{var t=document.createEvent("MouseEvents");t.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),n.dispatchEvent(t)}}var wi=Kt.saveAs||((typeof window>"u"?"undefined":xe(window))!=="object"||window!==Kt?function(){}:typeof HTMLAnchorElement<"u"&&"download"in HTMLAnchorElement.prototype?function(n,t,e){var i=Kt.URL||Kt.webkitURL,o=document.createElement("a");t=t||n.name||"download",o.download=t,o.rel="noopener",typeof n=="string"?(o.href=n,o.origin!==location.origin?Lu(o.href)?Fo(n,t,e):Ns(o,o.target="_blank"):Ns(o)):(o.href=i.createObjectURL(n),setTimeout(function(){i.revokeObjectURL(o.href)},4e4),setTimeout(function(){Ns(o)},0))}:"msSaveOrOpenBlob"in navigator?function(n,t,e){if(t=t||n.name||"download",typeof n=="string")if(Lu(n))Fo(n,t,e);else{var i=document.createElement("a");i.href=n,i.target="_blank",setTimeout(function(){Ns(i)})}else navigator.msSaveOrOpenBlob((function(o,a){return a===void 0?a={autoBom:!1}:xe(a)!=="object"&&(Le.warn("Deprecated: Expected third argument to be a object"),a={autoBom:!a}),a.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(o.type)?new Blob(["\uFEFF",o],{type:o.type}):o})(n,e),t)}:function(n,t,e,i){if((i=i||open("","_blank"))&&(i.document.title=i.document.body.innerText="downloading..."),typeof n=="string")return Fo(n,t,e);var o=n.type==="application/octet-stream",a=/constructor/i.test(Kt.HTMLElement)||Kt.safari,c=/CriOS\/[\d]+/.test(navigator.userAgent);if((c||o&&a)&&(typeof FileReader>"u"?"undefined":xe(FileReader))==="object"){var l=new FileReader;l.onloadend=function(){var m=l.result;m=c?m:m.replace(/^data:[^;]*;/,"data:attachment/file;"),i?i.location.href=m:location=m,i=null},l.readAsDataURL(n)}else{var h=Kt.URL||Kt.webkitURL,d=h.createObjectURL(n);i?i.location=d:location.href=d,i=null,setTimeout(function(){h.revokeObjectURL(d)},4e4)}});function Sf(n){var t;n=n||"",this.ok=!1,n.charAt(0)=="#"&&(n=n.substr(1,6)),n={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dodgerblue:"1e90ff",feldspar:"d19275",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslateblue:"8470ff",lightslategray:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",violetred:"d02090",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"}[n=(n=n.replace(/ /g,"")).toLowerCase()]||n;for(var e=[{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,example:["rgb(123, 234, 45)","rgb(255,234,245)"],process:function(l){return[parseInt(l[1]),parseInt(l[2]),parseInt(l[3])]}},{re:/^(\w{2})(\w{2})(\w{2})$/,example:["#00ff00","336699"],process:function(l){return[parseInt(l[1],16),parseInt(l[2],16),parseInt(l[3],16)]}},{re:/^(\w{1})(\w{1})(\w{1})$/,example:["#fb0","f0f"],process:function(l){return[parseInt(l[1]+l[1],16),parseInt(l[2]+l[2],16),parseInt(l[3]+l[3],16)]}}],i=0;i<e.length;i++){var o=e[i].re,a=e[i].process,c=o.exec(n);c&&(t=a(c),this.r=t[0],this.g=t[1],this.b=t[2],this.ok=!0)}this.r=this.r<0||isNaN(this.r)?0:this.r>255?255:this.r,this.g=this.g<0||isNaN(this.g)?0:this.g>255?255:this.g,this.b=this.b<0||isNaN(this.b)?0:this.b>255?255:this.b,this.toRGB=function(){return"rgb("+this.r+", "+this.g+", "+this.b+")"},this.toHex=function(){var l=this.r.toString(16),h=this.g.toString(16),d=this.b.toString(16);return l.length==1&&(l="0"+l),h.length==1&&(h="0"+h),d.length==1&&(d="0"+d),"#"+l+h+d}}var Ps=Kt.atob.bind(Kt),Su=Kt.btoa.bind(Kt);function Eo(n,t){var e=n[0],i=n[1],o=n[2],a=n[3];e=gn(e,i,o,a,t[0],7,-680876936),a=gn(a,e,i,o,t[1],12,-389564586),o=gn(o,a,e,i,t[2],17,606105819),i=gn(i,o,a,e,t[3],22,-1044525330),e=gn(e,i,o,a,t[4],7,-176418897),a=gn(a,e,i,o,t[5],12,1200080426),o=gn(o,a,e,i,t[6],17,-1473231341),i=gn(i,o,a,e,t[7],22,-45705983),e=gn(e,i,o,a,t[8],7,1770035416),a=gn(a,e,i,o,t[9],12,-1958414417),o=gn(o,a,e,i,t[10],17,-42063),i=gn(i,o,a,e,t[11],22,-1990404162),e=gn(e,i,o,a,t[12],7,1804603682),a=gn(a,e,i,o,t[13],12,-40341101),o=gn(o,a,e,i,t[14],17,-1502002290),e=mn(e,i=gn(i,o,a,e,t[15],22,1236535329),o,a,t[1],5,-165796510),a=mn(a,e,i,o,t[6],9,-1069501632),o=mn(o,a,e,i,t[11],14,643717713),i=mn(i,o,a,e,t[0],20,-373897302),e=mn(e,i,o,a,t[5],5,-701558691),a=mn(a,e,i,o,t[10],9,38016083),o=mn(o,a,e,i,t[15],14,-660478335),i=mn(i,o,a,e,t[4],20,-405537848),e=mn(e,i,o,a,t[9],5,568446438),a=mn(a,e,i,o,t[14],9,-1019803690),o=mn(o,a,e,i,t[3],14,-187363961),i=mn(i,o,a,e,t[8],20,1163531501),e=mn(e,i,o,a,t[13],5,-1444681467),a=mn(a,e,i,o,t[2],9,-51403784),o=mn(o,a,e,i,t[7],14,1735328473),e=vn(e,i=mn(i,o,a,e,t[12],20,-1926607734),o,a,t[5],4,-378558),a=vn(a,e,i,o,t[8],11,-2022574463),o=vn(o,a,e,i,t[11],16,1839030562),i=vn(i,o,a,e,t[14],23,-35309556),e=vn(e,i,o,a,t[1],4,-1530992060),a=vn(a,e,i,o,t[4],11,1272893353),o=vn(o,a,e,i,t[7],16,-155497632),i=vn(i,o,a,e,t[10],23,-1094730640),e=vn(e,i,o,a,t[13],4,681279174),a=vn(a,e,i,o,t[0],11,-358537222),o=vn(o,a,e,i,t[3],16,-722521979),i=vn(i,o,a,e,t[6],23,76029189),e=vn(e,i,o,a,t[9],4,-640364487),a=vn(a,e,i,o,t[12],11,-421815835),o=vn(o,a,e,i,t[15],16,530742520),e=bn(e,i=vn(i,o,a,e,t[2],23,-995338651),o,a,t[0],6,-198630844),a=bn(a,e,i,o,t[7],10,1126891415),o=bn(o,a,e,i,t[14],15,-1416354905),i=bn(i,o,a,e,t[5],21,-57434055),e=bn(e,i,o,a,t[12],6,1700485571),a=bn(a,e,i,o,t[3],10,-1894986606),o=bn(o,a,e,i,t[10],15,-1051523),i=bn(i,o,a,e,t[1],21,-2054922799),e=bn(e,i,o,a,t[8],6,1873313359),a=bn(a,e,i,o,t[15],10,-30611744),o=bn(o,a,e,i,t[6],15,-1560198380),i=bn(i,o,a,e,t[13],21,1309151649),e=bn(e,i,o,a,t[4],6,-145523070),a=bn(a,e,i,o,t[11],10,-1120210379),o=bn(o,a,e,i,t[2],15,718787259),i=bn(i,o,a,e,t[9],21,-343485551),n[0]=$r(e,n[0]),n[1]=$r(i,n[1]),n[2]=$r(o,n[2]),n[3]=$r(a,n[3])}function Os(n,t,e,i,o,a){return t=$r($r(t,n),$r(i,a)),$r(t<<o|t>>>32-o,e)}function gn(n,t,e,i,o,a,c){return Os(t&e|~t&i,n,t,o,a,c)}function mn(n,t,e,i,o,a,c){return Os(t&i|e&~i,n,t,o,a,c)}function vn(n,t,e,i,o,a,c){return Os(t^e^i,n,t,o,a,c)}function bn(n,t,e,i,o,a,c){return Os(e^(t|~i),n,t,o,a,c)}function kf(n){var t,e=n.length,i=[1732584193,-271733879,-1732584194,271733878];for(t=64;t<=n.length;t+=64)Eo(i,P1(n.substring(t-64,t)));n=n.substring(t-64);var o=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(t=0;t<n.length;t++)o[t>>2]|=n.charCodeAt(t)<<(t%4<<3);if(o[t>>2]|=128<<(t%4<<3),t>55)for(Eo(i,o),t=0;t<16;t++)o[t]=0;return o[14]=8*e,Eo(i,o),i}function P1(n){var t,e=[];for(t=0;t<64;t+=4)e[t>>2]=n.charCodeAt(t)+(n.charCodeAt(t+1)<<8)+(n.charCodeAt(t+2)<<16)+(n.charCodeAt(t+3)<<24);return e}var ku="0123456789abcdef".split("");function I1(n){for(var t="",e=0;e<4;e++)t+=ku[n>>8*e+4&15]+ku[n>>8*e&15];return t}function C1(n){return String.fromCharCode(255&n,(65280&n)>>8,(16711680&n)>>16,(4278190080&n)>>24)}function Vo(n){return kf(n).map(C1).join("")}var F1=(function(n){for(var t=0;t<n.length;t++)n[t]=I1(n[t]);return n.join("")})(kf("hello"))!="5d41402abc4b2a76b9719d911017c592";function $r(n,t){if(F1){var e=(65535&n)+(65535&t);return(n>>16)+(t>>16)+(e>>16)<<16|65535&e}return n+t&4294967295}function Go(n,t){var e,i,o,a;if(n!==e){for(var c=(o=n,a=1+(256/n.length|0),new Array(a+1).join(o)),l=[],h=0;h<256;h++)l[h]=h;var d=0;for(h=0;h<256;h++){var m=l[h];d=(d+m+c.charCodeAt(h))%256,l[h]=l[d],l[d]=m}e=n,i=l}else l=i;var _=t.length,k=0,p=0,j="";for(h=0;h<_;h++)p=(p+(m=l[k=(k+1)%256]))%256,l[k]=l[p],l[p]=m,c=l[(l[k]+l[p])%256],j+=String.fromCharCode(t.charCodeAt(h)^c);return j}var Pu={print:4,modify:8,copy:16,"annot-forms":32};function ea(n,t,e,i){this.v=1,this.r=2;var o=192;n.forEach(function(l){if(Pu.perm!==void 0)throw new Error("Invalid permission: "+l);o+=Pu[l]}),this.padding="(¿N^NuŠAd\0NVÿú\b..\0¶Ðh>€/\f©þdSiz";var a=(t+this.padding).substr(0,32),c=(e+this.padding).substr(0,32);this.O=this.processOwnerPassword(a,c),this.P=-(1+(255^o)),this.encryptionKey=Vo(a+this.O+this.lsbFirstWord(this.P)+this.hexToBytes(i)).substr(0,5),this.U=Go(this.encryptionKey,this.padding)}function na(n){if(/[^\u0000-\u00ff]/.test(n))throw new Error("Invalid PDF Name Object: "+n+", Only accept ASCII characters.");for(var t="",e=n.length,i=0;i<e;i++){var o=n.charCodeAt(i);t+=o<33||o===35||o===37||o===40||o===41||o===47||o===60||o===62||o===91||o===93||o===123||o===125||o>126?"#"+("0"+o.toString(16)).slice(-2):n[i]}return t}function Iu(n){if(xe(n)!=="object")throw new Error("Invalid Context passed to initialize PubSub (jsPDF-module)");var t={};this.subscribe=function(e,i,o){if(o=o||!1,typeof e!="string"||typeof i!="function"||typeof o!="boolean")throw new Error("Invalid arguments passed to PubSub.subscribe (jsPDF-module)");t.hasOwnProperty(e)||(t[e]={});var a=Math.random().toString(35);return t[e][a]=[i,!!o],a},this.unsubscribe=function(e){for(var i in t)if(t[i][e])return delete t[i][e],Object.keys(t[i]).length===0&&delete t[i],!0;return!1},this.publish=function(e){if(t.hasOwnProperty(e)){var i=Array.prototype.slice.call(arguments,1),o=[];for(var a in t[e]){var c=t[e][a];try{c[0].apply(n,i)}catch(l){Kt.console&&Le.error("jsPDF PubSub Error",l.message,l)}c[1]&&o.push(a)}o.length&&o.forEach(this.unsubscribe)}},this.getTopics=function(){return t}}function Ra(n){if(!(this instanceof Ra))return new Ra(n);var t="opacity,stroke-opacity".split(",");for(var e in n)n.hasOwnProperty(e)&&t.indexOf(e)>=0&&(this[e]=n[e]);this.id="",this.objectNumber=-1}function Pf(n,t){this.gState=n,this.matrix=t,this.id="",this.objectNumber=-1}function Xr(n,t,e,i,o){if(!(this instanceof Xr))return new Xr(n,t,e,i,o);this.type=n==="axial"?2:3,this.coords=t,this.colors=e,Pf.call(this,i,o)}function yi(n,t,e,i,o){if(!(this instanceof yi))return new yi(n,t,e,i,o);this.boundingBox=n,this.xStep=t,this.yStep=e,this.stream="",this.cloneIndex=0,Pf.call(this,i,o)}function Mt(n){var t,e=typeof arguments[0]=="string"?arguments[0]:"p",i=arguments[1],o=arguments[2],a=arguments[3],c=[],l=1,h=16,d="S",m=null;xe(n=n||{})==="object"&&(e=n.orientation,i=n.unit||i,o=n.format||o,a=n.compress||n.compressPdf||a,(m=n.encryption||null)!==null&&(m.userPassword=m.userPassword||"",m.ownerPassword=m.ownerPassword||"",m.userPermissions=m.userPermissions||[]),l=typeof n.userUnit=="number"?Math.abs(n.userUnit):1,n.precision!==void 0&&(t=n.precision),n.floatPrecision!==void 0&&(h=n.floatPrecision),d=n.defaultPathOperation||"S"),c=n.filters||(a===!0?["FlateEncode"]:c),i=i||"mm",e=(""+(e||"P")).toLowerCase();var _=n.putOnlyUsedFonts||!1,k={},p={internal:{},__private__:{}};p.__private__.PubSub=Iu;var j="1.3",O=p.__private__.getPdfVersion=function(){return j};p.__private__.setPdfVersion=function(u){j=u};var M={a0:[2383.94,3370.39],a1:[1683.78,2383.94],a2:[1190.55,1683.78],a3:[841.89,1190.55],a4:[595.28,841.89],a5:[419.53,595.28],a6:[297.64,419.53],a7:[209.76,297.64],a8:[147.4,209.76],a9:[104.88,147.4],a10:[73.7,104.88],b0:[2834.65,4008.19],b1:[2004.09,2834.65],b2:[1417.32,2004.09],b3:[1000.63,1417.32],b4:[708.66,1000.63],b5:[498.9,708.66],b6:[354.33,498.9],b7:[249.45,354.33],b8:[175.75,249.45],b9:[124.72,175.75],b10:[87.87,124.72],c0:[2599.37,3676.54],c1:[1836.85,2599.37],c2:[1298.27,1836.85],c3:[918.43,1298.27],c4:[649.13,918.43],c5:[459.21,649.13],c6:[323.15,459.21],c7:[229.61,323.15],c8:[161.57,229.61],c9:[113.39,161.57],c10:[79.37,113.39],dl:[311.81,623.62],letter:[612,792],"government-letter":[576,756],legal:[612,1008],"junior-legal":[576,360],ledger:[1224,792],tabloid:[792,1224],"credit-card":[153,243]};p.__private__.getPageFormats=function(){return M};var S=p.__private__.getPageFormat=function(u){return M[u]};o=o||"a4";var V="compat",G="advanced",q=V;function it(){this.saveGraphicsState(),P(new Gt(ne,0,0,-ne,0,si()*ne).toString()+" cm"),this.setFontSize(this.getFontSize()/ne),d="n",q=G}function vt(){this.restoreGraphicsState(),d="S",q=V}var dt=p.__private__.combineFontStyleAndFontWeight=function(u,v){if(u=="bold"&&v=="normal"||u=="bold"&&v==400||u=="normal"&&v=="italic"||u=="bold"&&v=="italic")throw new Error("Invalid Combination of fontweight and fontstyle");return v&&(u=v==400||v==="normal"?u==="italic"?"italic":"normal":v!=700&&v!=="bold"||u!=="normal"?(v==700?"bold":v)+""+u:"bold"),u};p.advancedAPI=function(u){var v=q===V;return v&&it.call(this),typeof u!="function"||(u(this),v&&vt.call(this)),this},p.compatAPI=function(u){var v=q===G;return v&&vt.call(this),typeof u!="function"||(u(this),v&&it.call(this)),this},p.isAdvancedAPI=function(){return q===G};var X,R=function(u){if(q!==G)throw new Error(u+" is only available in 'advanced' API mode. You need to call advancedAPI() first.")},tt=p.roundToPrecision=p.__private__.roundToPrecision=function(u,v){var I=t||v;if(isNaN(u)||isNaN(I))throw new Error("Invalid argument passed to jsPDF.roundToPrecision");return u.toFixed(I).replace(/0+$/,"")};X=p.hpf=p.__private__.hpf=typeof h=="number"?function(u){if(isNaN(u))throw new Error("Invalid argument passed to jsPDF.hpf");return tt(u,h)}:h==="smart"?function(u){if(isNaN(u))throw new Error("Invalid argument passed to jsPDF.hpf");return tt(u,u>-1&&u<1?16:5)}:function(u){if(isNaN(u))throw new Error("Invalid argument passed to jsPDF.hpf");return tt(u,16)};var N=p.f2=p.__private__.f2=function(u){if(isNaN(u))throw new Error("Invalid argument passed to jsPDF.f2");return tt(u,2)},E=p.__private__.f3=function(u){if(isNaN(u))throw new Error("Invalid argument passed to jsPDF.f3");return tt(u,3)},z=p.scale=p.__private__.scale=function(u){if(isNaN(u))throw new Error("Invalid argument passed to jsPDF.scale");return q===V?u*ne:q===G?u:void 0},U=function(u){return z((function(v){return q===V?si()-v:q===G?v:void 0})(u))};p.__private__.setPrecision=p.setPrecision=function(u){typeof parseInt(u,10)=="number"&&(t=parseInt(u,10))};var rt,ot="00000000000000000000000000000000",ft=p.__private__.getFileId=function(){return ot},nt=p.__private__.setFileId=function(u){return ot=u!==void 0&&/^[a-fA-F0-9]{32}$/.test(u)?u.toUpperCase():ot.split("").map(function(){return"ABCDEF0123456789".charAt(Math.floor(16*Math.random()))}).join(""),m!==null&&(sn=new ea(m.userPermissions,m.userPassword,m.ownerPassword,ot)),ot};p.setFileId=function(u){return nt(u),this},p.getFileId=function(){return ft()};var ct=p.__private__.convertDateToPDFDate=function(u){var v=u.getTimezoneOffset(),I=v<0?"+":"-",D=Math.floor(Math.abs(v/60)),K=Math.abs(v%60),lt=[I,T(D),"'",T(K),"'"].join("");return["D:",u.getFullYear(),T(u.getMonth()+1),T(u.getDate()),T(u.getHours()),T(u.getMinutes()),T(u.getSeconds()),lt].join("")},At=p.__private__.convertPDFDateToDate=function(u){var v=parseInt(u.substr(2,4),10),I=parseInt(u.substr(6,2),10)-1,D=parseInt(u.substr(8,2),10),K=parseInt(u.substr(10,2),10),lt=parseInt(u.substr(12,2),10),mt=parseInt(u.substr(14,2),10);return new Date(v,I,D,K,lt,mt,0)},wt=p.__private__.setCreationDate=function(u){var v;if(u===void 0&&(u=new Date),u instanceof Date)v=ct(u);else{if(!/^D:(20[0-2][0-9]|203[0-7]|19[7-9][0-9])(0[0-9]|1[0-2])([0-2][0-9]|3[0-1])(0[0-9]|1[0-9]|2[0-3])(0[0-9]|[1-5][0-9])(0[0-9]|[1-5][0-9])(\+0[0-9]|\+1[0-4]|-0[0-9]|-1[0-1])'(0[0-9]|[1-5][0-9])'?$/.test(u))throw new Error("Invalid argument passed to jsPDF.setCreationDate");v=u}return rt=v},x=p.__private__.getCreationDate=function(u){var v=rt;return u==="jsDate"&&(v=At(rt)),v};p.setCreationDate=function(u){return wt(u),this},p.getCreationDate=function(u){return x(u)};var B,T=p.__private__.padd2=function(u){return("0"+parseInt(u)).slice(-2)},H=p.__private__.padd2Hex=function(u){return("00"+(u=u.toString())).substr(u.length)},J=0,Z=[],at=[],st=0,gt=[],_t=[],kt=!1,St=at;p.__private__.setCustomOutputDestination=function(u){kt=!0,St=u};var Dt=function(u){kt||(St=u)};p.__private__.resetCustomOutputDestination=function(){kt=!1,St=at};var P=p.__private__.out=function(u){return u=u.toString(),st+=u.length+1,St.push(u),St},Lt=p.__private__.write=function(u){return P(arguments.length===1?u.toString():Array.prototype.join.call(arguments," "))},ae=p.__private__.getArrayBuffer=function(u){for(var v=u.length,I=new ArrayBuffer(v),D=new Uint8Array(I);v--;)D[v]=u.charCodeAt(v);return I},Ht=[["Helvetica","helvetica","normal","WinAnsiEncoding"],["Helvetica-Bold","helvetica","bold","WinAnsiEncoding"],["Helvetica-Oblique","helvetica","italic","WinAnsiEncoding"],["Helvetica-BoldOblique","helvetica","bolditalic","WinAnsiEncoding"],["Courier","courier","normal","WinAnsiEncoding"],["Courier-Bold","courier","bold","WinAnsiEncoding"],["Courier-Oblique","courier","italic","WinAnsiEncoding"],["Courier-BoldOblique","courier","bolditalic","WinAnsiEncoding"],["Times-Roman","times","normal","WinAnsiEncoding"],["Times-Bold","times","bold","WinAnsiEncoding"],["Times-Italic","times","italic","WinAnsiEncoding"],["Times-BoldItalic","times","bolditalic","WinAnsiEncoding"],["ZapfDingbats","zapfdingbats","normal",null],["Symbol","symbol","normal",null]];p.__private__.getStandardFonts=function(){return Ht};var yt=n.fontSize||16;p.__private__.setFontSize=p.setFontSize=function(u){return yt=q===G?u/ne:u,this};var Wt,Ct=p.__private__.getFontSize=p.getFontSize=function(){return q===V?yt:yt*ne},zt=n.R2L||!1;p.__private__.setR2L=p.setR2L=function(u){return zt=u,this},p.__private__.getR2L=p.getR2L=function(){return zt};var qt,ve=p.__private__.setZoomMode=function(u){if(/^(?:\d+\.\d*|\d*\.\d+|\d+)%$/.test(u))Wt=u;else if(isNaN(u)){if([void 0,null,"fullwidth","fullheight","fullpage","original"].indexOf(u)===-1)throw new Error('zoom must be Integer (e.g. 2), a percentage Value (e.g. 300%) or fullwidth, fullheight, fullpage, original. "'+u+'" is not recognized.');Wt=u}else Wt=parseInt(u,10)};p.__private__.getZoomMode=function(){return Wt};var ue,Zt=p.__private__.setPageMode=function(u){if([void 0,null,"UseNone","UseOutlines","UseThumbs","FullScreen"].indexOf(u)==-1)throw new Error('Page mode must be one of UseNone, UseOutlines, UseThumbs, or FullScreen. "'+u+'" is not recognized.');qt=u};p.__private__.getPageMode=function(){return qt};var he=p.__private__.setLayoutMode=function(u){if([void 0,null,"continuous","single","twoleft","tworight","two"].indexOf(u)==-1)throw new Error('Layout mode must be one of continuous, single, twoleft, tworight. "'+u+'" is not recognized.');ue=u};p.__private__.getLayoutMode=function(){return ue},p.__private__.setDisplayMode=p.setDisplayMode=function(u,v,I){return ve(u),he(v),Zt(I),this};var fe={title:"",subject:"",author:"",keywords:"",creator:""};p.__private__.getDocumentProperty=function(u){if(Object.keys(fe).indexOf(u)===-1)throw new Error("Invalid argument passed to jsPDF.getDocumentProperty");return fe[u]},p.__private__.getDocumentProperties=function(){return fe},p.__private__.setDocumentProperties=p.setProperties=p.setDocumentProperties=function(u){for(var v in fe)fe.hasOwnProperty(v)&&u[v]&&(fe[v]=u[v]);return this},p.__private__.setDocumentProperty=function(u,v){if(Object.keys(fe).indexOf(u)===-1)throw new Error("Invalid arguments passed to jsPDF.setDocumentProperty");return fe[u]=v};var Bt,ne,Tt,ze,ge,se={},oe={},Oe=[],Ut={},Se={},Yt={},Qt={},je=null,le=0,Vt=[],be=new Iu(p),ti=n.hotfixes||[],fn={},mr={},nr=[],Gt=function u(v,I,D,K,lt,mt){if(!(this instanceof u))return new u(v,I,D,K,lt,mt);isNaN(v)&&(v=1),isNaN(I)&&(I=0),isNaN(D)&&(D=0),isNaN(K)&&(K=1),isNaN(lt)&&(lt=0),isNaN(mt)&&(mt=0),this._matrix=[v,I,D,K,lt,mt]};Object.defineProperty(Gt.prototype,"sx",{get:function(){return this._matrix[0]},set:function(u){this._matrix[0]=u}}),Object.defineProperty(Gt.prototype,"shy",{get:function(){return this._matrix[1]},set:function(u){this._matrix[1]=u}}),Object.defineProperty(Gt.prototype,"shx",{get:function(){return this._matrix[2]},set:function(u){this._matrix[2]=u}}),Object.defineProperty(Gt.prototype,"sy",{get:function(){return this._matrix[3]},set:function(u){this._matrix[3]=u}}),Object.defineProperty(Gt.prototype,"tx",{get:function(){return this._matrix[4]},set:function(u){this._matrix[4]=u}}),Object.defineProperty(Gt.prototype,"ty",{get:function(){return this._matrix[5]},set:function(u){this._matrix[5]=u}}),Object.defineProperty(Gt.prototype,"a",{get:function(){return this._matrix[0]},set:function(u){this._matrix[0]=u}}),Object.defineProperty(Gt.prototype,"b",{get:function(){return this._matrix[1]},set:function(u){this._matrix[1]=u}}),Object.defineProperty(Gt.prototype,"c",{get:function(){return this._matrix[2]},set:function(u){this._matrix[2]=u}}),Object.defineProperty(Gt.prototype,"d",{get:function(){return this._matrix[3]},set:function(u){this._matrix[3]=u}}),Object.defineProperty(Gt.prototype,"e",{get:function(){return this._matrix[4]},set:function(u){this._matrix[4]=u}}),Object.defineProperty(Gt.prototype,"f",{get:function(){return this._matrix[5]},set:function(u){this._matrix[5]=u}}),Object.defineProperty(Gt.prototype,"rotation",{get:function(){return Math.atan2(this.shx,this.sx)}}),Object.defineProperty(Gt.prototype,"scaleX",{get:function(){return this.decompose().scale.sx}}),Object.defineProperty(Gt.prototype,"scaleY",{get:function(){return this.decompose().scale.sy}}),Object.defineProperty(Gt.prototype,"isIdentity",{get:function(){return this.sx===1&&this.shy===0&&this.shx===0&&this.sy===1&&this.tx===0&&this.ty===0}}),Gt.prototype.join=function(u){return[this.sx,this.shy,this.shx,this.sy,this.tx,this.ty].map(X).join(u)},Gt.prototype.multiply=function(u){var v=u.sx*this.sx+u.shy*this.shx,I=u.sx*this.shy+u.shy*this.sy,D=u.shx*this.sx+u.sy*this.shx,K=u.shx*this.shy+u.sy*this.sy,lt=u.tx*this.sx+u.ty*this.shx+this.tx,mt=u.tx*this.shy+u.ty*this.sy+this.ty;return new Gt(v,I,D,K,lt,mt)},Gt.prototype.decompose=function(){var u=this.sx,v=this.shy,I=this.shx,D=this.sy,K=this.tx,lt=this.ty,mt=Math.sqrt(u*u+v*v),Et=(u/=mt)*I+(v/=mt)*D;I-=u*Et,D-=v*Et;var Ft=Math.sqrt(I*I+D*D);return Et/=Ft,u*(D/=Ft)<v*(I/=Ft)&&(u=-u,v=-v,Et=-Et,mt=-mt),{scale:new Gt(mt,0,0,Ft,0,0),translate:new Gt(1,0,0,1,K,lt),rotate:new Gt(u,v,-v,u,0,0),skew:new Gt(1,0,Et,1,0,0)}},Gt.prototype.toString=function(u){return this.join(" ")},Gt.prototype.inversed=function(){var u=this.sx,v=this.shy,I=this.shx,D=this.sy,K=this.tx,lt=this.ty,mt=1/(u*D-v*I),Et=D*mt,Ft=-v*mt,Xt=-I*mt,te=u*mt;return new Gt(Et,Ft,Xt,te,-Et*K-Xt*lt,-Ft*K-te*lt)},Gt.prototype.applyToPoint=function(u){var v=u.x*this.sx+u.y*this.shx+this.tx,I=u.x*this.shy+u.y*this.sy+this.ty;return new ai(v,I)},Gt.prototype.applyToRectangle=function(u){var v=this.applyToPoint(u),I=this.applyToPoint(new ai(u.x+u.w,u.y+u.h));return new ca(v.x,v.y,I.x-v.x,I.y-v.y)},Gt.prototype.clone=function(){var u=this.sx,v=this.shy,I=this.shx,D=this.sy,K=this.tx,lt=this.ty;return new Gt(u,v,I,D,K,lt)},p.Matrix=Gt;var vr=p.matrixMult=function(u,v){return v.multiply(u)},br=new Gt(1,0,0,1,0,0);p.unitMatrix=p.identityMatrix=br;var Rn=function(u,v){if(!Se[u]){var I=(v instanceof Xr?"Sh":"P")+(Object.keys(Ut).length+1).toString(10);v.id=I,Se[u]=I,Ut[I]=v,be.publish("addPattern",v)}};p.ShadingPattern=Xr,p.TilingPattern=yi,p.addShadingPattern=function(u,v){return R("addShadingPattern()"),Rn(u,v),this},p.beginTilingPattern=function(u){R("beginTilingPattern()"),da(u.boundingBox[0],u.boundingBox[1],u.boundingBox[2]-u.boundingBox[0],u.boundingBox[3]-u.boundingBox[1],u.matrix)},p.endTilingPattern=function(u,v){R("endTilingPattern()"),v.stream=_t[B].join(`
4
+ `),Rn(u,v),be.publish("endTilingPattern",v),nr.pop().restore()};var Tn,Te=p.__private__.newObject=function(){var u=rn();return an(u,!0),u},rn=p.__private__.newObjectDeferred=function(){return J++,Z[J]=function(){return st},J},an=function(u,v){return v=typeof v=="boolean"&&v,Z[u]=st,v&&P(u+" 0 obj"),u},ei=p.__private__.newAdditionalObject=function(){var u={objId:rn(),content:""};return gt.push(u),u},Or=rn(),Vn=rn(),rr=p.__private__.decodeColorString=function(u){var v=u.split(" ");if(v.length!==2||v[1]!=="g"&&v[1]!=="G")v.length!==5||v[4]!=="k"&&v[4]!=="K"||(v=[(1-v[0])*(1-v[3]),(1-v[1])*(1-v[3]),(1-v[2])*(1-v[3]),"r"]);else{var I=parseFloat(v[0]);v=[I,I,I,"r"]}for(var D="#",K=0;K<3;K++)D+=("0"+Math.floor(255*parseFloat(v[K])).toString(16)).slice(-2);return D},Gn=p.__private__.encodeColorString=function(u){var v;typeof u=="string"&&(u={ch1:u});var I=u.ch1,D=u.ch2,K=u.ch3,lt=u.ch4,mt=u.pdfColorType==="draw"?["G","RG","K"]:["g","rg","k"];if(typeof I=="string"&&I.charAt(0)!=="#"){var Et=new Sf(I);if(Et.ok)I=Et.toHex();else if(!/^\d*\.?\d*$/.test(I))throw new Error('Invalid color "'+I+'" passed to jsPDF.encodeColorString.')}if(typeof I=="string"&&/^#[0-9A-Fa-f]{3}$/.test(I)&&(I="#"+I[1]+I[1]+I[2]+I[2]+I[3]+I[3]),typeof I=="string"&&/^#[0-9A-Fa-f]{6}$/.test(I)){var Ft=parseInt(I.substr(1),16);I=Ft>>16&255,D=Ft>>8&255,K=255&Ft}if(D===void 0||lt===void 0&&I===D&&D===K)v=typeof I=="string"?I+" "+mt[0]:u.precision===2?N(I/255)+" "+mt[0]:E(I/255)+" "+mt[0];else if(lt===void 0||xe(lt)==="object"){if(lt&&!isNaN(lt.a)&&lt.a===0)return["1.","1.","1.",mt[1]].join(" ");v=typeof I=="string"?[I,D,K,mt[1]].join(" "):u.precision===2?[N(I/255),N(D/255),N(K/255),mt[1]].join(" "):[E(I/255),E(D/255),E(K/255),mt[1]].join(" ")}else v=typeof I=="string"?[I,D,K,lt,mt[2]].join(" "):u.precision===2?[N(I),N(D),N(K),N(lt),mt[2]].join(" "):[E(I),E(D),E(K),E(lt),mt[2]].join(" ");return v},Yn=p.__private__.getFilters=function(){return c},Dn=p.__private__.putStream=function(u){var v=(u=u||{}).data||"",I=u.filters||Yn(),D=u.alreadyAppliedFilters||[],K=u.addLength1||!1,lt=v.length,mt=u.objectId,Et=function(Ce){return Ce};if(m!==null&&mt===void 0)throw new Error("ObjectId must be passed to putStream for file encryption");m!==null&&(Et=sn.encryptor(mt,0));var Ft={};I===!0&&(I=["FlateEncode"]);var Xt=u.additionalKeyValues||[],te=(Ft=Mt.API.processDataByFilters!==void 0?Mt.API.processDataByFilters(v,I):{data:v,reverseChain:[]}).reverseChain+(Array.isArray(D)?D.join(" "):D.toString());if(Ft.data.length!==0&&(Xt.push({key:"Length",value:Ft.data.length}),K===!0&&Xt.push({key:"Length1",value:lt})),te.length!=0)if(te.split("/").length-1==1)Xt.push({key:"Filter",value:te});else{Xt.push({key:"Filter",value:"["+te+"]"});for(var de=0;de<Xt.length;de+=1)if(Xt[de].key==="DecodeParms"){for(var Xe=[],Ae=0;Ae<Ft.reverseChain.split("/").length-1;Ae+=1)Xe.push("null");Xe.push(Xt[de].value),Xt[de].value="["+Xe.join(" ")+"]"}}P("<<");for(var _e=0;_e<Xt.length;_e++)P("/"+Xt[_e].key+" "+Xt[_e].value);P(">>"),Ft.data.length!==0&&(P("stream"),P(Et(Ft.data)),P("endstream"))},ni=p.__private__.putPage=function(u){var v=u.number,I=u.data,D=u.objId,K=u.contentsObjId;an(D,!0),P("<</Type /Page"),P("/Parent "+u.rootDictionaryObjId+" 0 R"),P("/Resources "+u.resourceDictionaryObjId+" 0 R"),P("/MediaBox ["+parseFloat(X(u.mediaBox.bottomLeftX))+" "+parseFloat(X(u.mediaBox.bottomLeftY))+" "+X(u.mediaBox.topRightX)+" "+X(u.mediaBox.topRightY)+"]"),u.cropBox!==null&&P("/CropBox ["+X(u.cropBox.bottomLeftX)+" "+X(u.cropBox.bottomLeftY)+" "+X(u.cropBox.topRightX)+" "+X(u.cropBox.topRightY)+"]"),u.bleedBox!==null&&P("/BleedBox ["+X(u.bleedBox.bottomLeftX)+" "+X(u.bleedBox.bottomLeftY)+" "+X(u.bleedBox.topRightX)+" "+X(u.bleedBox.topRightY)+"]"),u.trimBox!==null&&P("/TrimBox ["+X(u.trimBox.bottomLeftX)+" "+X(u.trimBox.bottomLeftY)+" "+X(u.trimBox.topRightX)+" "+X(u.trimBox.topRightY)+"]"),u.artBox!==null&&P("/ArtBox ["+X(u.artBox.bottomLeftX)+" "+X(u.artBox.bottomLeftY)+" "+X(u.artBox.topRightX)+" "+X(u.artBox.topRightY)+"]"),typeof u.userUnit=="number"&&u.userUnit!==1&&P("/UserUnit "+u.userUnit),be.publish("putPage",{objId:D,pageContext:Vt[v],pageNumber:v,page:I}),P("/Contents "+K+" 0 R"),P(">>"),P("endobj");var lt=I.join(`
5
+ `);return q===G&&(lt+=`
6
+ Q`),an(K,!0),Dn({data:lt,filters:Yn(),objectId:K}),P("endobj"),D},ir=p.__private__.putPages=function(){var u,v,I=[];for(u=1;u<=le;u++)Vt[u].objId=rn(),Vt[u].contentsObjId=rn();for(u=1;u<=le;u++)I.push(ni({number:u,data:_t[u],objId:Vt[u].objId,contentsObjId:Vt[u].contentsObjId,mediaBox:Vt[u].mediaBox,cropBox:Vt[u].cropBox,bleedBox:Vt[u].bleedBox,trimBox:Vt[u].trimBox,artBox:Vt[u].artBox,userUnit:Vt[u].userUnit,rootDictionaryObjId:Or,resourceDictionaryObjId:Vn}));an(Or,!0),P("<</Type /Pages");var D="/Kids [";for(v=0;v<le;v++)D+=I[v]+" 0 R ";P(D+"]"),P("/Count "+le),P(">>"),P("endobj"),be.publish("postPutPages")},ri=function(u){be.publish("putFont",{font:u,out:P,newObject:Te,putStream:Dn}),u.isAlreadyPutted!==!0&&(u.objectNumber=Te(),P("<<"),P("/Type /Font"),P("/BaseFont /"+na(u.postScriptName)),P("/Subtype /Type1"),typeof u.encoding=="string"&&P("/Encoding /"+u.encoding),P("/FirstChar 32"),P("/LastChar 255"),P(">>"),P("endobj"))},Ci=function(u){u.objectNumber=Te();var v=[];v.push({key:"Type",value:"/XObject"}),v.push({key:"Subtype",value:"/Form"}),v.push({key:"BBox",value:"["+[X(u.x),X(u.y),X(u.x+u.width),X(u.y+u.height)].join(" ")+"]"}),v.push({key:"Matrix",value:"["+u.matrix.toString()+"]"});var I=u.pages[1].join(`
7
+ `);Dn({data:I,additionalKeyValues:v,objectId:u.objectNumber}),P("endobj")},Fi=function(u,v){v||(v=21);var I=Te(),D=(function(mt,Et){var Ft,Xt=[],te=1/(Et-1);for(Ft=0;Ft<1;Ft+=te)Xt.push(Ft);if(Xt.push(1),mt[0].offset!=0){var de={offset:0,color:mt[0].color};mt.unshift(de)}if(mt[mt.length-1].offset!=1){var Xe={offset:1,color:mt[mt.length-1].color};mt.push(Xe)}for(var Ae="",_e=0,Ce=0;Ce<Xt.length;Ce++){for(Ft=Xt[Ce];Ft>mt[_e+1].offset;)_e++;var Me=mt[_e].offset,Re=(Ft-Me)/(mt[_e+1].offset-Me),hn=mt[_e].color,Nr=mt[_e+1].color;Ae+=H(Math.round((1-Re)*hn[0]+Re*Nr[0]).toString(16))+H(Math.round((1-Re)*hn[1]+Re*Nr[1]).toString(16))+H(Math.round((1-Re)*hn[2]+Re*Nr[2]).toString(16))}return Ae.trim()})(u.colors,v),K=[];K.push({key:"FunctionType",value:"0"}),K.push({key:"Domain",value:"[0.0 1.0]"}),K.push({key:"Size",value:"["+v+"]"}),K.push({key:"BitsPerSample",value:"8"}),K.push({key:"Range",value:"[0.0 1.0 0.0 1.0 0.0 1.0]"}),K.push({key:"Decode",value:"[0.0 1.0 0.0 1.0 0.0 1.0]"}),Dn({data:D,additionalKeyValues:K,alreadyAppliedFilters:["/ASCIIHexDecode"],objectId:I}),P("endobj"),u.objectNumber=Te(),P("<< /ShadingType "+u.type),P("/ColorSpace /DeviceRGB");var lt="/Coords ["+X(parseFloat(u.coords[0]))+" "+X(parseFloat(u.coords[1]))+" ";u.type===2?lt+=X(parseFloat(u.coords[2]))+" "+X(parseFloat(u.coords[3])):lt+=X(parseFloat(u.coords[2]))+" "+X(parseFloat(u.coords[3]))+" "+X(parseFloat(u.coords[4]))+" "+X(parseFloat(u.coords[5])),P(lt+="]"),u.matrix&&P("/Matrix ["+u.matrix.toString()+"]"),P("/Function "+I+" 0 R"),P("/Extend [true true]"),P(">>"),P("endobj")},Ei=function(u,v){var I=rn(),D=Te();v.push({resourcesOid:I,objectOid:D}),u.objectNumber=D;var K=[];K.push({key:"Type",value:"/Pattern"}),K.push({key:"PatternType",value:"1"}),K.push({key:"PaintType",value:"1"}),K.push({key:"TilingType",value:"1"}),K.push({key:"BBox",value:"["+u.boundingBox.map(X).join(" ")+"]"}),K.push({key:"XStep",value:X(u.xStep)}),K.push({key:"YStep",value:X(u.yStep)}),K.push({key:"Resources",value:I+" 0 R"}),u.matrix&&K.push({key:"Matrix",value:"["+u.matrix.toString()+"]"}),Dn({data:u.stream,additionalKeyValues:K,objectId:u.objectNumber}),P("endobj")},js=function(u){for(var v in u.objectNumber=Te(),P("<<"),u)switch(v){case"opacity":P("/ca "+N(u[v]));break;case"stroke-opacity":P("/CA "+N(u[v]))}P(">>"),P("endobj")},ia=function(u){an(u.resourcesOid,!0),P("<<"),P("/ProcSet [/PDF /Text /ImageB /ImageC /ImageI]"),(function(){for(var v in P("/Font <<"),se)se.hasOwnProperty(v)&&(_===!1||_===!0&&k.hasOwnProperty(v))&&P("/"+v+" "+se[v].objectNumber+" 0 R");P(">>")})(),(function(){if(Object.keys(Ut).length>0){for(var v in P("/Shading <<"),Ut)Ut.hasOwnProperty(v)&&Ut[v]instanceof Xr&&Ut[v].objectNumber>=0&&P("/"+v+" "+Ut[v].objectNumber+" 0 R");be.publish("putShadingPatternDict"),P(">>")}})(),(function(v){if(Object.keys(Ut).length>0){for(var I in P("/Pattern <<"),Ut)Ut.hasOwnProperty(I)&&Ut[I]instanceof p.TilingPattern&&Ut[I].objectNumber>=0&&Ut[I].objectNumber<v&&P("/"+I+" "+Ut[I].objectNumber+" 0 R");be.publish("putTilingPatternDict"),P(">>")}})(u.objectOid),(function(){if(Object.keys(Yt).length>0){var v;for(v in P("/ExtGState <<"),Yt)Yt.hasOwnProperty(v)&&Yt[v].objectNumber>=0&&P("/"+v+" "+Yt[v].objectNumber+" 0 R");be.publish("putGStateDict"),P(">>")}})(),(function(){for(var v in P("/XObject <<"),fn)fn.hasOwnProperty(v)&&fn[v].objectNumber>=0&&P("/"+v+" "+fn[v].objectNumber+" 0 R");be.publish("putXobjectDict"),P(">>")})(),P(">>"),P("endobj")},Da=function(u){oe[u.fontName]=oe[u.fontName]||{},oe[u.fontName][u.fontStyle]=u.id},qa=function(u,v,I,D,K){var lt={id:"F"+(Object.keys(se).length+1).toString(10),postScriptName:u,fontName:v,fontStyle:I,encoding:D,isStandardFont:K||!1,metadata:{}};return be.publish("addFont",{font:lt,instance:this}),se[lt.id]=lt,Da(lt),lt.id},qn=p.__private__.pdfEscape=p.pdfEscape=function(u,v){return(function(I,D){var K,lt,mt,Et,Ft,Xt,te,de,Xe;if(mt=(D=D||{}).sourceEncoding||"Unicode",Ft=D.outputEncoding,(D.autoencode||Ft)&&se[Bt].metadata&&se[Bt].metadata[mt]&&se[Bt].metadata[mt].encoding&&(Et=se[Bt].metadata[mt].encoding,!Ft&&se[Bt].encoding&&(Ft=se[Bt].encoding),!Ft&&Et.codePages&&(Ft=Et.codePages[0]),typeof Ft=="string"&&(Ft=Et[Ft]),Ft)){for(te=!1,Xt=[],K=0,lt=I.length;K<lt;K++)(de=Ft[I.charCodeAt(K)])?Xt.push(String.fromCharCode(de)):Xt.push(I[K]),Xt[K].charCodeAt(0)>>8&&(te=!0);I=Xt.join("")}for(K=I.length;te===void 0&&K!==0;)I.charCodeAt(K-1)>>8&&(te=!0),K--;if(!te)return I;for(Xt=D.noBOM?[]:[254,255],K=0,lt=I.length;K<lt;K++){if((Xe=(de=I.charCodeAt(K))>>8)>>8)throw new Error("Character at position "+K+" of string '"+I+"' exceeds 16bits. Cannot be encoded into UCS-2 BE");Xt.push(Xe),Xt.push(de-(Xe<<8))}return String.fromCharCode.apply(void 0,Xt)})(u,v).replace(/\\/g,"\\\\").replace(/\(/g,"\\(").replace(/\)/g,"\\)")},aa=p.__private__.beginPage=function(u){_t[++le]=[],Vt[le]={objId:0,contentsObjId:0,userUnit:Number(l),artBox:null,bleedBox:null,cropBox:null,trimBox:null,mediaBox:{bottomLeftX:0,bottomLeftY:0,topRightX:Number(u[0]),topRightY:Number(u[1])}},za(le),Dt(_t[B])},Ua=function(u,v){var I,D,K;switch(e=v||e,typeof u=="string"&&(I=S(u.toLowerCase()),Array.isArray(I)&&(D=I[0],K=I[1])),Array.isArray(u)&&(D=u[0]*ne,K=u[1]*ne),isNaN(D)&&(D=o[0],K=o[1]),(D>14400||K>14400)&&(Le.warn("A page in a PDF can not be wider or taller than 14400 userUnit. jsPDF limits the width/height to 14400"),D=Math.min(14400,D),K=Math.min(14400,K)),o=[D,K],e.substr(0,1)){case"l":K>D&&(o=[K,D]);break;case"p":D>K&&(o=[K,D])}aa(o),Ws(Jt),P(Ti),fa!==0&&P(fa+" J"),Mr!==0&&P(Mr+" j"),be.publish("addPage",{pageNumber:le})},sa=function(u){u>0&&u<=le&&(_t.splice(u,1),Vt.splice(u,1),le--,B>le&&(B=le),this.setPage(B))},za=function(u){u>0&&u<=le&&(B=u)},Ha=p.__private__.getNumberOfPages=p.getNumberOfPages=function(){return _t.length-1},Wa=function(u,v,I){var D,K=void 0;return I=I||{},u=u!==void 0?u:se[Bt].fontName,v=v!==void 0?v:se[Bt].fontStyle,D=u.toLowerCase(),oe[D]!==void 0&&oe[D][v]!==void 0?K=oe[D][v]:oe[u]!==void 0&&oe[u][v]!==void 0?K=oe[u][v]:I.disableWarning===!1&&Le.warn("Unable to look up font label for font '"+u+"', '"+v+"'. Refer to getFontList() for available fonts."),K||I.noFallback||(K=oe.times[v])==null&&(K=oe.times.normal),K},ar=p.__private__.putInfo=function(){var u=Te(),v=function(D){return D};for(var I in m!==null&&(v=sn.encryptor(u,0)),P("<<"),P("/Producer ("+qn(v("jsPDF "+Mt.version))+")"),fe)fe.hasOwnProperty(I)&&fe[I]&&P("/"+I.substr(0,1).toUpperCase()+I.substr(1)+" ("+qn(v(fe[I]))+")");P("/CreationDate ("+qn(v(rt))+")"),P(">>"),P("endobj")},Oi=p.__private__.putCatalog=function(u){var v=(u=u||{}).rootDictionaryObjId||Or;switch(Te(),P("<<"),P("/Type /Catalog"),P("/Pages "+v+" 0 R"),Wt||(Wt="fullwidth"),Wt){case"fullwidth":P("/OpenAction [3 0 R /FitH null]");break;case"fullheight":P("/OpenAction [3 0 R /FitV null]");break;case"fullpage":P("/OpenAction [3 0 R /Fit]");break;case"original":P("/OpenAction [3 0 R /XYZ null null 1]");break;default:var I=""+Wt;I.substr(I.length-1)==="%"&&(Wt=parseInt(Wt)/100),typeof Wt=="number"&&P("/OpenAction [3 0 R /XYZ null null "+N(Wt)+"]")}switch(ue||(ue="continuous"),ue){case"continuous":P("/PageLayout /OneColumn");break;case"single":P("/PageLayout /SinglePage");break;case"two":case"twoleft":P("/PageLayout /TwoColumnLeft");break;case"tworight":P("/PageLayout /TwoColumnRight")}qt&&P("/PageMode /"+qt),be.publish("putCatalog"),P(">>"),P("endobj")},Bs=p.__private__.putTrailer=function(){P("trailer"),P("<<"),P("/Size "+(J+1)),P("/Root "+J+" 0 R"),P("/Info "+(J-1)+" 0 R"),m!==null&&P("/Encrypt "+sn.oid+" 0 R"),P("/ID [ <"+ot+"> <"+ot+"> ]"),P(">>")},Ke=p.__private__.putHeader=function(){P("%PDF-"+j),P("%ºß¬à")},Va=p.__private__.putXRef=function(){var u="0000000000";P("xref"),P("0 "+(J+1)),P("0000000000 65535 f ");for(var v=1;v<=J;v++)typeof Z[v]=="function"?P((u+Z[v]()).slice(-10)+" 00000 n "):Z[v]!==void 0?P((u+Z[v]).slice(-10)+" 00000 n "):P("0000000000 00000 n ")},sr=p.__private__.buildDocument=function(){var u;J=0,st=0,at=[],Z=[],gt=[],Or=rn(),Vn=rn(),Dt(at),be.publish("buildDocument"),Ke(),ir(),(function(){be.publish("putAdditionalObjects");for(var I=0;I<gt.length;I++){var D=gt[I];an(D.objId,!0),P(D.content),P("endobj")}be.publish("postPutAdditionalObjects")})(),u=[],(function(){for(var I in se)se.hasOwnProperty(I)&&(_===!1||_===!0&&k.hasOwnProperty(I))&&ri(se[I])})(),(function(){var I;for(I in Yt)Yt.hasOwnProperty(I)&&js(Yt[I])})(),(function(){for(var I in fn)fn.hasOwnProperty(I)&&Ci(fn[I])})(),(function(I){var D;for(D in Ut)Ut.hasOwnProperty(D)&&(Ut[D]instanceof Xr?Fi(Ut[D]):Ut[D]instanceof yi&&Ei(Ut[D],I))})(u),be.publish("putResources"),u.forEach(ia),ia({resourcesOid:Vn,objectOid:Number.MAX_SAFE_INTEGER}),be.publish("postPutResources"),m!==null&&(sn.oid=Te(),P("<<"),P("/Filter /Standard"),P("/V "+sn.v),P("/R "+sn.r),P("/U <"+sn.toHexString(sn.U)+">"),P("/O <"+sn.toHexString(sn.O)+">"),P("/P "+sn.P),P(">>"),P("endobj")),ar(),Oi();var v=st;return Va(),Bs(),P("startxref"),P(""+v),P("%%EOF"),Dt(_t[B]),at.join(`
8
+ `)},ji=p.__private__.getBlob=function(u){return new Blob([ae(u)],{type:"application/pdf"})},oa=function(u){for(;u.firstChild;)u.removeChild(u.firstChild)},Pn=function(u){var v,I=u.document,D=I.documentElement,K=I.head,lt=I.body;return K||(K=I.createElement("head"),D.appendChild(K)),lt||(lt=I.createElement("body"),D.appendChild(lt)),oa(K),oa(lt),(v=I.createElement("style")).appendChild(I.createTextNode("html, body { padding: 0; margin: 0; } iframe { width: 100%; height: 100%; border: 0;}")),K.appendChild(v),{document:I,body:lt}},Bi=p.output=p.__private__.output=(Tn=function(u,v){switch(typeof(v=v||{})=="string"?v={filename:v}:v.filename=v.filename||"generated.pdf",u){case void 0:return sr();case"save":p.save(v.filename);break;case"arraybuffer":return ae(sr());case"blob":return ji(sr());case"bloburi":case"bloburl":if(Kt.URL!==void 0&&typeof Kt.URL.createObjectURL=="function")return Kt.URL&&Kt.URL.createObjectURL(ji(sr()))||void 0;Le.warn("bloburl is not supported by your system, because URL.createObjectURL is not supported by your browser.");break;case"datauristring":case"dataurlstring":var I="",D=sr();try{I=Su(D)}catch{I=Su(unescape(encodeURIComponent(D)))}return"data:application/pdf;filename="+encodeURIComponent(v.filename)+";base64,"+I;case"pdfobjectnewwindow":if(Object.prototype.toString.call(Kt)==="[object Window]"){var K="https://cdnjs.cloudflare.com/ajax/libs/pdfobject/2.1.1/pdfobject.min.js",lt=!v.pdfObjectUrl;lt||(K=v.pdfObjectUrl);var mt=Kt.open();if(mt!==null){var Et=Pn(mt),Ft=Et.document.createElement("script"),Xt=this;Ft.src=K,lt&&(Ft.integrity="sha512-4ze/a9/4jqu+tX9dfOqJYSvyYd5M6qum/3HpCLr+/Jqf0whc37VUbkpNGHR7/8pSnCFw47T1fmIpwBV7UySh3g==",Ft.crossOrigin="anonymous"),Ft.onload=function(){mt.PDFObject.embed(Xt.output("dataurlstring"),v)},Et.body.appendChild(Ft)}return mt}throw new Error("The option pdfobjectnewwindow just works in a browser-environment.");case"pdfjsnewwindow":if(Object.prototype.toString.call(Kt)==="[object Window]"){var te=v.pdfJsUrl||"examples/PDF.js/web/viewer.html",de=Kt.open();if(de!==null){var Xe=Pn(de),Ae=Xe.document.createElement("iframe"),_e=te.indexOf("?")===-1?"?":"&";Xt=this,Ae.id="pdfViewer",Ae.width="500px",Ae.height="400px",Ae.src=te+_e+"file=&downloadName="+encodeURIComponent(v.filename),Ae.onload=function(){de.document.title=v.filename,Ae.contentWindow.PDFViewerApplication.open(Xt.output("bloburl"))},Xe.body.appendChild(Ae)}return de}throw new Error("The option pdfjsnewwindow just works in a browser-environment.");case"dataurlnewwindow":if(Object.prototype.toString.call(Kt)!=="[object Window]")throw new Error("The option dataurlnewwindow just works in a browser-environment.");var Ce=Kt.open();if(Ce!==null){var Me=Pn(Ce),Re=Me.document.createElement("iframe");Re.src=this.output("datauristring",v),Me.body.appendChild(Re),Ce.document.title=v.filename}if(Ce||typeof safari>"u")return Ce;break;case"datauri":case"dataurl":return Kt.document.location.href=this.output("datauristring",v);default:return null}},Tn.foo=function(){try{return Tn.apply(this,arguments)}catch(I){var u=I.stack||"";~u.indexOf(" at ")&&(u=u.split(" at ")[1]);var v="Error in function "+u.split(`
9
+ `)[0].split("<")[0]+": "+I.message;if(!Kt.console)throw new Error(v);Kt.console.error(v,I),Kt.alert&&alert(v)}},Tn.foo.bar=Tn,Tn.foo),wr=function(u){return Array.isArray(ti)===!0&&ti.indexOf(u)>-1};switch(i){case"pt":ne=1;break;case"mm":ne=72/25.4;break;case"cm":ne=72/2.54;break;case"in":ne=72;break;case"px":ne=wr("px_scaling")==1?.75:96/72;break;case"pc":case"em":ne=12;break;case"ex":ne=6;break;default:if(typeof i!="number")throw new Error("Invalid unit: "+i);ne=i}var sn=null;wt(),nt();var Ga=p.__private__.getPageInfo=p.getPageInfo=function(u){if(isNaN(u)||u%1!=0)throw new Error("Invalid argument passed to jsPDF.getPageInfo");return{objId:Vt[u].objId,pageNumber:u,pageContext:Vt[u]}},Ms=p.__private__.getPageInfoByObjId=function(u){if(isNaN(u)||u%1!=0)throw new Error("Invalid argument passed to jsPDF.getPageInfoByObjId");for(var v in Vt)if(Vt[v].objId===u)break;return Ga(v)},Rs=p.__private__.getCurrentPageInfo=p.getCurrentPageInfo=function(){return{objId:Vt[B].objId,pageNumber:B,pageContext:Vt[B]}};p.addPage=function(){return Ua.apply(this,arguments),this},p.setPage=function(){return za.apply(this,arguments),Dt.call(this,_t[B]),this},p.insertPage=function(u){return this.addPage(),this.movePage(B,u),this},p.movePage=function(u,v){var I,D;if(u>v){I=_t[u],D=Vt[u];for(var K=u;K>v;K--)_t[K]=_t[K-1],Vt[K]=Vt[K-1];_t[v]=I,Vt[v]=D,this.setPage(v)}else if(u<v){I=_t[u],D=Vt[u];for(var lt=u;lt<v;lt++)_t[lt]=_t[lt+1],Vt[lt]=Vt[lt+1];_t[v]=I,Vt[v]=D,this.setPage(v)}return this},p.deletePage=function(){return sa.apply(this,arguments),this},p.__private__.text=p.text=function(u,v,I,D,K){var lt,mt,Et,Ft,Xt,te,de,Xe,Ae,_e=(D=D||{}).scope||this;if(typeof u=="number"&&typeof v=="number"&&(typeof I=="string"||Array.isArray(I))){var Ce=I;I=v,v=u,u=Ce}if(arguments[3]instanceof Gt==0?(Et=arguments[4],Ft=arguments[5],xe(de=arguments[3])==="object"&&de!==null||(typeof Et=="string"&&(Ft=Et,Et=null),typeof de=="string"&&(Ft=de,de=null),typeof de=="number"&&(Et=de,de=null),D={flags:de,angle:Et,align:Ft})):(R("The transform parameter of text() with a Matrix value"),Ae=K),isNaN(v)||isNaN(I)||u==null)throw new Error("Invalid arguments passed to jsPDF.text");if(u.length===0)return _e;var Me,Re="",hn=typeof D.lineHeightFactor=="number"?D.lineHeightFactor:ii,Nr=_e.internal.scaleFactor;function pa(ke){return ke=ke.split(" ").join(Array(D.TabLen||9).join(" ")),qn(ke,de)}function oi(ke){for(var Pe,He=ke.concat(),Ze=[],Sr=He.length;Sr--;)typeof(Pe=He.shift())=="string"?Ze.push(Pe):Array.isArray(ke)&&(Pe.length===1||Pe[1]===void 0&&Pe[2]===void 0)?Ze.push(Pe[0]):Ze.push([Pe[0],Pe[1],Pe[2]]);return Ze}function li(ke,Pe){var He;if(typeof ke=="string")He=Pe(ke)[0];else if(Array.isArray(ke)){for(var Ze,Sr,ya=ke.concat(),Xi=[],ns=ya.length;ns--;)typeof(Ze=ya.shift())=="string"?Xi.push(Pe(Ze)[0]):Array.isArray(Ze)&&typeof Ze[0]=="string"&&(Sr=Pe(Ze[0],Ze[1],Ze[2]),Xi.push([Sr[0],Sr[1],Sr[2]]));He=Xi}return He}var Rr=!1,ui=!0;if(typeof u=="string")Rr=!0;else if(Array.isArray(u)){var zi=u.concat();mt=[];for(var Hi,cn=zi.length;cn--;)(typeof(Hi=zi.shift())!="string"||Array.isArray(Hi)&&typeof Hi[0]!="string")&&(ui=!1);Rr=ui}if(Rr===!1)throw new Error('Type of text must be string or Array. "'+u+'" is not recognized.');typeof u=="string"&&(u=u.match(/[\r?\n]/)?u.split(/\r\n|\r|\n/g):[u]);var fi=yt/_e.internal.scaleFactor,hi=fi*(hn-1);switch(D.baseline){case"bottom":I-=hi;break;case"top":I+=fi-hi;break;case"hanging":I+=fi-2*hi;break;case"middle":I+=fi/2-hi}if((te=D.maxWidth||0)>0&&(typeof u=="string"?u=_e.splitTextToSize(u,te):Object.prototype.toString.call(u)==="[object Array]"&&(u=u.reduce(function(ke,Pe){return ke.concat(_e.splitTextToSize(Pe,te))},[]))),lt={text:u,x:v,y:I,options:D,mutex:{pdfEscape:qn,activeFontKey:Bt,fonts:se,activeFontSize:yt}},be.publish("preProcessText",lt),u=lt.text,Et=(D=lt.options).angle,Ae instanceof Gt==0&&Et&&typeof Et=="number"){Et*=Math.PI/180,D.rotationDirection===0&&(Et=-Et),q===G&&(Et=-Et);var ga=Math.cos(Et),ur=Math.sin(Et);Ae=new Gt(ga,ur,-ur,ga,0,0)}else Et&&Et instanceof Gt&&(Ae=Et);q!==G||Ae||(Ae=br),(Xt=D.charSpace||Di)!==void 0&&(Re+=X(z(Xt))+` Tc
10
+ `,this.setCharSpace(this.getCharSpace()||0)),(Xe=D.horizontalScale)!==void 0&&(Re+=X(100*Xe)+` Tz
11
+ `),D.lang;var wn=-1,ts=D.renderingMode!==void 0?D.renderingMode:D.stroke,Wi=_e.internal.getCurrentPageInfo().pageContext;switch(ts){case 0:case!1:case"fill":wn=0;break;case 1:case!0:case"stroke":wn=1;break;case 2:case"fillThenStroke":wn=2;break;case 3:case"invisible":wn=3;break;case 4:case"fillAndAddForClipping":wn=4;break;case 5:case"strokeAndAddPathForClipping":wn=5;break;case 6:case"fillThenStrokeAndAddToPathForClipping":wn=6;break;case 7:case"addToPathForClipping":wn=7}var es=Wi.usedRenderingMode!==void 0?Wi.usedRenderingMode:-1;wn!==-1?Re+=wn+` Tr
12
+ `:es!==-1&&(Re+=`0 Tr
13
+ `),wn!==-1&&(Wi.usedRenderingMode=wn),Ft=D.align||"left";var Un,ci=yt*hn,ma=_e.internal.pageSize.getWidth(),Vi=se[Bt];Xt=D.charSpace||Di,te=D.maxWidth||0,de=Object.assign({autoencode:!0,noBOM:!0},D.flags);var di=[],va=function(ke){return _e.getStringUnitWidth(ke,{font:Vi,charSpace:Xt,fontSize:yt,doKerning:!1})*yt/Nr};if(Object.prototype.toString.call(u)==="[object Array]"){var yn;mt=oi(u),Ft!=="left"&&(Un=mt.map(va));var Nn,Gi=0;if(Ft==="right"){v-=Un[0],u=[],cn=mt.length;for(var Tr=0;Tr<cn;Tr++)Tr===0?(Nn=yr(v),yn=xr(I)):(Nn=z(Gi-Un[Tr]),yn=-ci),u.push([mt[Tr],Nn,yn]),Gi=Un[Tr]}else if(Ft==="center"){v-=Un[0]/2,u=[],cn=mt.length;for(var Dr=0;Dr<cn;Dr++)Dr===0?(Nn=yr(v),yn=xr(I)):(Nn=z((Gi-Un[Dr])/2),yn=-ci),u.push([mt[Dr],Nn,yn]),Gi=Un[Dr]}else if(Ft==="left"){u=[],cn=mt.length;for(var Yi=0;Yi<cn;Yi++)u.push(mt[Yi])}else if(Ft==="justify"&&Vi.encoding==="Identity-H"){u=[],cn=mt.length,te=te!==0?te:ma;for(var pi=0,$e=0;$e<cn;$e++)if(yn=$e===0?xr(I):-ci,Nn=$e===0?yr(v):pi,$e<cn-1){var Zs=z((te-Un[$e])/(mt[$e].split(" ").length-1)),fr=mt[$e].split(" ");u.push([fr[0]+" ",Nn,yn]),pi=0;for(var Jn=1;Jn<fr.length;Jn++){var gi=(va(fr[Jn-1]+" "+fr[Jn])-va(fr[Jn]))*Nr+Zs;Jn==fr.length-1?u.push([fr[Jn],gi,0]):u.push([fr[Jn]+" ",gi,0]),pi-=gi}}else u.push([mt[$e],Nn,yn]);u.push(["",pi,0])}else{if(Ft!=="justify")throw new Error('Unrecognized alignment option, use "left", "center", "right" or "justify".');for(u=[],cn=mt.length,te=te!==0?te:ma,$e=0;$e<cn;$e++){yn=$e===0?xr(I):-ci,Nn=$e===0?yr(v):0;var ba=mt[$e].split(" ").length-1,wa=ba>0?(te-Un[$e])/ba:0;$e<cn-1?di.push(X(z(wa))):di.push(0),u.push([mt[$e],Nn,yn])}}}(typeof D.R2L=="boolean"?D.R2L:zt)===!0&&(u=li(u,function(ke,Pe,He){return[ke.split("").reverse().join(""),Pe,He]})),lt={text:u,x:v,y:I,options:D,mutex:{pdfEscape:qn,activeFontKey:Bt,fonts:se,activeFontSize:yt}},be.publish("postProcessText",lt),u=lt.text,Me=lt.mutex.isHex||!1;var Ji=se[Bt].encoding;Ji!=="WinAnsiEncoding"&&Ji!=="StandardEncoding"||(u=li(u,function(ke,Pe,He){return[pa(ke),Pe,He]})),mt=oi(u),u=[];for(var mi,vi,qr,Lr=Array.isArray(mt[0])?1:0,Ur="",Ki=function(ke,Pe,He){var Ze="";return He instanceof Gt?(He=typeof D.angle=="number"?vr(He,new Gt(1,0,0,1,ke,Pe)):vr(new Gt(1,0,0,1,ke,Pe),He),q===G&&(He=vr(new Gt(1,0,0,-1,0,0),He)),Ze=He.join(" ")+` Tm
14
+ `):Ze=X(ke)+" "+X(Pe)+` Td
15
+ `,Ze},dn=0;dn<mt.length;dn++){switch(Ur="",Lr){case 1:qr=(Me?"<":"(")+mt[dn][0]+(Me?">":")"),mi=parseFloat(mt[dn][1]),vi=parseFloat(mt[dn][2]);break;case 0:qr=(Me?"<":"(")+mt[dn]+(Me?">":")"),mi=yr(v),vi=xr(I)}di!==void 0&&di[dn]!==void 0&&(Ur=di[dn]+` Tw
16
+ `),dn===0?u.push(Ur+Ki(mi,vi,Ae)+qr):Lr===0?u.push(Ur+qr):Lr===1&&u.push(Ur+Ki(mi,vi,Ae)+qr)}u=Lr===0?u.join(` Tj
17
+ T* `):u.join(` Tj
18
+ `),u+=` Tj
19
+ `;var hr=`BT
20
+ /`;return hr+=Bt+" "+yt+` Tf
21
+ `,hr+=X(yt*hn)+` TL
22
+ `,hr+=lr+`
23
+ `,hr+=Re,hr+=u,P(hr+="ET"),k[Bt]=!0,_e};var Ts=p.__private__.clip=p.clip=function(u){return P(u==="evenodd"?"W*":"W"),this};p.clipEvenOdd=function(){return Ts("evenodd")},p.__private__.discardPath=p.discardPath=function(){return P("n"),this};var or=p.__private__.isValidStyle=function(u){var v=!1;return[void 0,null,"S","D","F","DF","FD","f","f*","B","B*","n"].indexOf(u)!==-1&&(v=!0),v};p.__private__.setDefaultPathOperation=p.setDefaultPathOperation=function(u){return or(u)&&(d=u),this};var Ya=p.__private__.getStyle=p.getStyle=function(u){var v=d;switch(u){case"D":case"S":v="S";break;case"F":v="f";break;case"FD":case"DF":v="B";break;case"f":case"f*":case"B":case"B*":v=u}return v},Mi=p.close=function(){return P("h"),this};p.stroke=function(){return P("S"),this},p.fill=function(u){return Ri("f",u),this},p.fillEvenOdd=function(u){return Ri("f*",u),this},p.fillStroke=function(u){return Ri("B",u),this},p.fillStrokeEvenOdd=function(u){return Ri("B*",u),this};var Ri=function(u,v){xe(v)==="object"?qs(v,u):P(u)},la=function(u){u===null||q===G&&u===void 0||(u=Ya(u),P(u))};function Ds(u,v,I,D,K){var lt=new yi(v||this.boundingBox,I||this.xStep,D||this.yStep,this.gState,K||this.matrix);lt.stream=this.stream;var mt=u+"$$"+this.cloneIndex+++"$$";return Rn(mt,lt),lt}var qs=function(u,v){var I=Se[u.key],D=Ut[I];if(D instanceof Xr)P("q"),P(Us(v)),D.gState&&p.setGState(D.gState),P(u.matrix.toString()+" cm"),P("/"+I+" sh"),P("Q");else if(D instanceof yi){var K=new Gt(1,0,0,-1,0,si());u.matrix&&(K=K.multiply(u.matrix||br),I=Ds.call(D,u.key,u.boundingBox,u.xStep,u.yStep,K).id),P("q"),P("/Pattern cs"),P("/"+I+" scn"),D.gState&&p.setGState(D.gState),P(v),P("Q")}},Us=function(u){switch(u){case"f":case"F":case"n":return"W n";case"f*":return"W* n";case"B":case"S":return"W S";case"B*":return"W* S"}},jr=p.moveTo=function(u,v){return P(X(z(u))+" "+X(U(v))+" m"),this},Ja=p.lineTo=function(u,v){return P(X(z(u))+" "+X(U(v))+" l"),this},Br=p.curveTo=function(u,v,I,D,K,lt){return P([X(z(u)),X(U(v)),X(z(I)),X(U(D)),X(z(K)),X(U(lt)),"c"].join(" ")),this};p.__private__.line=p.line=function(u,v,I,D,K){if(isNaN(u)||isNaN(v)||isNaN(I)||isNaN(D)||!or(K))throw new Error("Invalid arguments passed to jsPDF.line");return q===V?this.lines([[I-u,D-v]],u,v,[1,1],K||"S"):this.lines([[I-u,D-v]],u,v,[1,1]).stroke()},p.__private__.lines=p.lines=function(u,v,I,D,K,lt){var mt,Et,Ft,Xt,te,de,Xe,Ae,_e,Ce,Me,Re;if(typeof u=="number"&&(Re=I,I=v,v=u,u=Re),D=D||[1,1],lt=lt||!1,isNaN(v)||isNaN(I)||!Array.isArray(u)||!Array.isArray(D)||!or(K)||typeof lt!="boolean")throw new Error("Invalid arguments passed to jsPDF.lines");for(jr(v,I),mt=D[0],Et=D[1],Xt=u.length,Ce=v,Me=I,Ft=0;Ft<Xt;Ft++)(te=u[Ft]).length===2?(Ce=te[0]*mt+Ce,Me=te[1]*Et+Me,Ja(Ce,Me)):(de=te[0]*mt+Ce,Xe=te[1]*Et+Me,Ae=te[2]*mt+Ce,_e=te[3]*Et+Me,Ce=te[4]*mt+Ce,Me=te[5]*Et+Me,Br(de,Xe,Ae,_e,Ce,Me));return lt&&Mi(),la(K),this},p.path=function(u){for(var v=0;v<u.length;v++){var I=u[v],D=I.c;switch(I.op){case"m":jr(D[0],D[1]);break;case"l":Ja(D[0],D[1]);break;case"c":Br.apply(this,D);break;case"h":Mi()}}return this},p.__private__.rect=p.rect=function(u,v,I,D,K){if(isNaN(u)||isNaN(v)||isNaN(I)||isNaN(D)||!or(K))throw new Error("Invalid arguments passed to jsPDF.rect");return q===V&&(D=-D),P([X(z(u)),X(U(v)),X(z(I)),X(z(D)),"re"].join(" ")),la(K),this},p.__private__.triangle=p.triangle=function(u,v,I,D,K,lt,mt){if(isNaN(u)||isNaN(v)||isNaN(I)||isNaN(D)||isNaN(K)||isNaN(lt)||!or(mt))throw new Error("Invalid arguments passed to jsPDF.triangle");return this.lines([[I-u,D-v],[K-I,lt-D],[u-K,v-lt]],u,v,[1,1],mt,!0),this},p.__private__.roundedRect=p.roundedRect=function(u,v,I,D,K,lt,mt){if(isNaN(u)||isNaN(v)||isNaN(I)||isNaN(D)||isNaN(K)||isNaN(lt)||!or(mt))throw new Error("Invalid arguments passed to jsPDF.roundedRect");var Et=4/3*(Math.SQRT2-1);return K=Math.min(K,.5*I),lt=Math.min(lt,.5*D),this.lines([[I-2*K,0],[K*Et,0,K,lt-lt*Et,K,lt],[0,D-2*lt],[0,lt*Et,-K*Et,lt,-K,lt],[2*K-I,0],[-K*Et,0,-K,-lt*Et,-K,-lt],[0,2*lt-D],[0,-lt*Et,K*Et,-lt,K,-lt]],u+K,v,[1,1],mt,!0),this},p.__private__.ellipse=p.ellipse=function(u,v,I,D,K){if(isNaN(u)||isNaN(v)||isNaN(I)||isNaN(D)||!or(K))throw new Error("Invalid arguments passed to jsPDF.ellipse");var lt=4/3*(Math.SQRT2-1)*I,mt=4/3*(Math.SQRT2-1)*D;return jr(u+I,v),Br(u+I,v-mt,u+lt,v-D,u,v-D),Br(u-lt,v-D,u-I,v-mt,u-I,v),Br(u-I,v+mt,u-lt,v+D,u,v+D),Br(u+lt,v+D,u+I,v+mt,u+I,v),la(K),this},p.__private__.circle=p.circle=function(u,v,I,D){if(isNaN(u)||isNaN(v)||isNaN(I)||!or(D))throw new Error("Invalid arguments passed to jsPDF.circle");return this.ellipse(u,v,I,I,D)},p.setFont=function(u,v,I){return I&&(v=dt(v,I)),Bt=Wa(u,v,{disableWarning:!1}),this};var zs=p.__private__.getFont=p.getFont=function(){return se[Wa.apply(p,arguments)]};p.__private__.getFontList=p.getFontList=function(){var u,v,I={};for(u in oe)if(oe.hasOwnProperty(u))for(v in I[u]=[],oe[u])oe[u].hasOwnProperty(v)&&I[u].push(v);return I},p.addFont=function(u,v,I,D,K){var lt=["StandardEncoding","MacRomanEncoding","Identity-H","WinAnsiEncoding"];return arguments[3]&&lt.indexOf(arguments[3])!==-1?K=arguments[3]:arguments[3]&&lt.indexOf(arguments[3])==-1&&(I=dt(I,D)),qa.call(this,u,v,I,K=K||"Identity-H")};var ii,Jt=n.lineWidth||.200025,Hs=p.__private__.getLineWidth=p.getLineWidth=function(){return Jt},Ws=p.__private__.setLineWidth=p.setLineWidth=function(u){return Jt=u,P(X(z(u))+" w"),this};p.__private__.setLineDash=Mt.API.setLineDash=Mt.API.setLineDashPattern=function(u,v){if(u=u||[],v=v||0,isNaN(v)||!Array.isArray(u))throw new Error("Invalid arguments passed to jsPDF.setLineDash");return u=u.map(function(I){return X(z(I))}).join(" "),v=X(z(v)),P("["+u+"] "+v+" d"),this};var Vs=p.__private__.getLineHeight=p.getLineHeight=function(){return yt*ii};p.__private__.getLineHeight=p.getLineHeight=function(){return yt*ii};var Gs=p.__private__.setLineHeightFactor=p.setLineHeightFactor=function(u){return typeof(u=u||1.15)=="number"&&(ii=u),this},Ys=p.__private__.getLineHeightFactor=p.getLineHeightFactor=function(){return ii};Gs(n.lineHeight);var yr=p.__private__.getHorizontalCoordinate=function(u){return z(u)},xr=p.__private__.getVerticalCoordinate=function(u){return q===G?u:Vt[B].mediaBox.topRightY-Vt[B].mediaBox.bottomLeftY-z(u)},Js=p.__private__.getHorizontalCoordinateString=p.getHorizontalCoordinateString=function(u){return X(yr(u))},Ks=p.__private__.getVerticalCoordinateString=p.getVerticalCoordinateString=function(u){return X(xr(u))},Ti=n.strokeColor||"0 G";p.__private__.getStrokeColor=p.getDrawColor=function(){return rr(Ti)},p.__private__.setStrokeColor=p.setDrawColor=function(u,v,I,D){return Ti=Gn({ch1:u,ch2:v,ch3:I,ch4:D,pdfColorType:"draw",precision:2}),P(Ti),this};var ua=n.fillColor||"0 g";p.__private__.getFillColor=p.getFillColor=function(){return rr(ua)},p.__private__.setFillColor=p.setFillColor=function(u,v,I,D){return ua=Gn({ch1:u,ch2:v,ch3:I,ch4:D,pdfColorType:"fill",precision:2}),P(ua),this};var lr=n.textColor||"0 g",Xs=p.__private__.getTextColor=p.getTextColor=function(){return rr(lr)};p.__private__.setTextColor=p.setTextColor=function(u,v,I,D){return lr=Gn({ch1:u,ch2:v,ch3:I,ch4:D,pdfColorType:"text",precision:3}),this};var Di=n.charSpace,$s=p.__private__.getCharSpace=p.getCharSpace=function(){return parseFloat(Di||0)};p.__private__.setCharSpace=p.setCharSpace=function(u){if(isNaN(u))throw new Error("Invalid argument passed to jsPDF.setCharSpace");return Di=u,this};var fa=0;p.CapJoinStyles={0:0,butt:0,but:0,miter:0,1:1,round:1,rounded:1,circle:1,2:2,projecting:2,project:2,square:2,bevel:2},p.__private__.setLineCap=p.setLineCap=function(u){var v=p.CapJoinStyles[u];if(v===void 0)throw new Error("Line cap style of '"+u+"' is not recognized. See or extend .CapJoinStyles property for valid styles");return fa=v,P(v+" J"),this};var Mr=0;p.__private__.setLineJoin=p.setLineJoin=function(u){var v=p.CapJoinStyles[u];if(v===void 0)throw new Error("Line join style of '"+u+"' is not recognized. See or extend .CapJoinStyles property for valid styles");return Mr=v,P(v+" j"),this},p.__private__.setLineMiterLimit=p.__private__.setMiterLimit=p.setLineMiterLimit=p.setMiterLimit=function(u){if(u=u||0,isNaN(u))throw new Error("Invalid argument passed to jsPDF.setLineMiterLimit");return P(X(z(u))+" M"),this},p.GState=Ra,p.setGState=function(u){(u=typeof u=="string"?Yt[Qt[u]]:ha(null,u)).equals(je)||(P("/"+u.id+" gs"),je=u)};var ha=function(u,v){if(!u||!Qt[u]){var I=!1;for(var D in Yt)if(Yt.hasOwnProperty(D)&&Yt[D].equals(v)){I=!0;break}if(I)v=Yt[D];else{var K="GS"+(Object.keys(Yt).length+1).toString(10);Yt[K]=v,v.id=K}return u&&(Qt[u]=v.id),be.publish("addGState",v),v}};p.addGState=function(u,v){return ha(u,v),this},p.saveGraphicsState=function(){return P("q"),Oe.push({key:Bt,size:yt,color:lr}),this},p.restoreGraphicsState=function(){P("Q");var u=Oe.pop();return Bt=u.key,yt=u.size,lr=u.color,je=null,this},p.setCurrentTransformationMatrix=function(u){return P(u.toString()+" cm"),this},p.comment=function(u){return P("#"+u),this};var ai=function(u,v){var I=u||0;Object.defineProperty(this,"x",{enumerable:!0,get:function(){return I},set:function(lt){isNaN(lt)||(I=parseFloat(lt))}});var D=v||0;Object.defineProperty(this,"y",{enumerable:!0,get:function(){return D},set:function(lt){isNaN(lt)||(D=parseFloat(lt))}});var K="pt";return Object.defineProperty(this,"type",{enumerable:!0,get:function(){return K},set:function(lt){K=lt.toString()}}),this},ca=function(u,v,I,D){ai.call(this,u,v),this.type="rect";var K=I||0;Object.defineProperty(this,"w",{enumerable:!0,get:function(){return K},set:function(mt){isNaN(mt)||(K=parseFloat(mt))}});var lt=D||0;return Object.defineProperty(this,"h",{enumerable:!0,get:function(){return lt},set:function(mt){isNaN(mt)||(lt=parseFloat(mt))}}),this},qi=function(){this.page=le,this.currentPage=B,this.pages=_t.slice(0),this.pagesContext=Vt.slice(0),this.x=Tt,this.y=ze,this.matrix=ge,this.width=Ka(B),this.height=Ar(B),this.outputDestination=St,this.id="",this.objectNumber=-1};qi.prototype.restore=function(){le=this.page,B=this.currentPage,Vt=this.pagesContext,_t=this.pages,Tt=this.x,ze=this.y,ge=this.matrix,_r(B,this.width),Xa(B,this.height),St=this.outputDestination};var da=function(u,v,I,D,K){nr.push(new qi),le=B=0,_t=[],Tt=u,ze=v,ge=K,aa([I,D])};for(var Ui in p.beginFormObject=function(u,v,I,D,K){return da(u,v,I,D,K),this},p.endFormObject=function(u){return(function(v){if(mr[v])nr.pop().restore();else{var I=new qi,D="Xo"+(Object.keys(fn).length+1).toString(10);I.id=D,mr[v]=D,fn[D]=I,be.publish("addFormObject",I),nr.pop().restore()}})(u),this},p.doFormObject=function(u,v){var I=fn[mr[u]];return P("q"),P(v.toString()+" cm"),P("/"+I.id+" Do"),P("Q"),this},p.getFormObject=function(u){var v=fn[mr[u]];return{x:v.x,y:v.y,width:v.width,height:v.height,matrix:v.matrix}},p.save=function(u,v){return u=u||"generated.pdf",(v=v||{}).returnPromise=v.returnPromise||!1,v.returnPromise===!1?(wi(ji(sr()),u),typeof wi.unload=="function"&&Kt.setTimeout&&setTimeout(wi.unload,911),this):new Promise(function(I,D){try{var K=wi(ji(sr()),u);typeof wi.unload=="function"&&Kt.setTimeout&&setTimeout(wi.unload,911),I(K)}catch(lt){D(lt.message)}})},Mt.API)Mt.API.hasOwnProperty(Ui)&&(Ui==="events"&&Mt.API.events.length?(function(u,v){var I,D,K;for(K=v.length-1;K!==-1;K--)I=v[K][0],D=v[K][1],u.subscribe.apply(u,[I].concat(typeof D=="function"?[D]:D))})(be,Mt.API.events):p[Ui]=Mt.API[Ui]);function Ka(u){return Vt[u].mediaBox.topRightX-Vt[u].mediaBox.bottomLeftX}function _r(u,v){Vt[u].mediaBox.topRightX=v+Vt[u].mediaBox.bottomLeftX}function Ar(u){return Vt[u].mediaBox.topRightY-Vt[u].mediaBox.bottomLeftY}function Xa(u,v){Vt[u].mediaBox.topRightY=v+Vt[u].mediaBox.bottomLeftY}var $a=p.getPageWidth=function(u){return Ka(u=u||B)/ne},Za=p.setPageWidth=function(u,v){_r(u,v*ne)},si=p.getPageHeight=function(u){return Ar(u=u||B)/ne},Qa=p.setPageHeight=function(u,v){Xa(u,v*ne)};return p.internal={pdfEscape:qn,getStyle:Ya,getFont:zs,getFontSize:Ct,getCharSpace:$s,getTextColor:Xs,getLineHeight:Vs,getLineHeightFactor:Ys,getLineWidth:Hs,write:Lt,getHorizontalCoordinate:yr,getVerticalCoordinate:xr,getCoordinateString:Js,getVerticalCoordinateString:Ks,collections:{},newObject:Te,newAdditionalObject:ei,newObjectDeferred:rn,newObjectDeferredBegin:an,getFilters:Yn,putStream:Dn,events:be,scaleFactor:ne,pageSize:{getWidth:function(){return $a(B)},setWidth:function(u){Za(B,u)},getHeight:function(){return si(B)},setHeight:function(u){Qa(B,u)}},encryptionOptions:m,encryption:sn,getEncryptor:function(u){return m!==null?sn.encryptor(u,0):function(v){return v}},output:Bi,getNumberOfPages:Ha,get pages(){return _t},out:P,f2:N,f3:E,getPageInfo:Ga,getPageInfoByObjId:Ms,getCurrentPageInfo:Rs,getPDFVersion:O,Point:ai,Rectangle:ca,Matrix:Gt,hasHotfix:wr},Object.defineProperty(p.internal.pageSize,"width",{get:function(){return $a(B)},set:function(u){Za(B,u)},enumerable:!0,configurable:!0}),Object.defineProperty(p.internal.pageSize,"height",{get:function(){return si(B)},set:function(u){Qa(B,u)},enumerable:!0,configurable:!0}),(function(u){for(var v=0,I=Ht.length;v<I;v++){var D=qa.call(this,u[v][0],u[v][1],u[v][2],Ht[v][3],!0);_===!1&&(k[D]=!0);var K=u[v][0].split("-");Da({id:D,fontName:K[0],fontStyle:K[1]||""})}be.publish("addFonts",{fonts:se,dictionary:oe})}).call(p,Ht),Bt="F1",Ua(o,e),be.publish("initialized"),p}ea.prototype.lsbFirstWord=function(n){return String.fromCharCode(255&n,n>>8&255,n>>16&255,n>>24&255)},ea.prototype.toHexString=function(n){return n.split("").map(function(t){return("0"+(255&t.charCodeAt(0)).toString(16)).slice(-2)}).join("")},ea.prototype.hexToBytes=function(n){for(var t=[],e=0;e<n.length;e+=2)t.push(String.fromCharCode(parseInt(n.substr(e,2),16)));return t.join("")},ea.prototype.processOwnerPassword=function(n,t){return Go(Vo(t).substr(0,5),n)},ea.prototype.encryptor=function(n,t){var e=Vo(this.encryptionKey+String.fromCharCode(255&n,n>>8&255,n>>16&255,255&t,t>>8&255)).substr(0,10);return function(i){return Go(e,i)}},Ra.prototype.equals=function(n){var t,e="id,objectNumber,equals";if(!n||xe(n)!==xe(this))return!1;var i=0;for(t in this)if(!(e.indexOf(t)>=0)){if(this.hasOwnProperty(t)&&!n.hasOwnProperty(t)||this[t]!==n[t])return!1;i++}for(t in n)n.hasOwnProperty(t)&&e.indexOf(t)<0&&i--;return i===0},Mt.API={events:[]},Mt.version="4.2.1";var Ue=Mt.API,Qo=1,Ii=function(n){return n.replace(/\\/g,"\\\\").replace(/\(/g,"\\(").replace(/\)/g,"\\)")},Qi=function(n){return n.replace(/\\\\/g,"\\").replace(/\\\(/g,"(").replace(/\\\)/g,")")},ki=function(n){return n.toString().replace(/#/g,"#23").replace(/[\s\n\r()<>[\]{}\/%]/g,function(t){var e=t.charCodeAt(0).toString(16).toUpperCase();return"#"+(e.length===1?"0"+e:e)})},$t=function(n){return n.toFixed(2)},Kr=function(n){return n.toFixed(5)};Ue.__acroform__={};var kn=function(n,t){n.prototype=Object.create(t.prototype),n.prototype.constructor=n},Cu=function(n){return n*Qo},dr=function(n){var t=new Cf,e=It.internal.getHeight(n)||0,i=It.internal.getWidth(n)||0;return t.BBox=[0,0,Number($t(i)),Number($t(e))],t},E1=Ue.__acroform__.setBit=function(n,t){if(n=n||0,t=t||0,isNaN(n)||isNaN(t))throw new Error("Invalid arguments passed to jsPDF.API.__acroform__.setBit");return n|1<<t},O1=Ue.__acroform__.clearBit=function(n,t){if(n=n||0,t=t||0,isNaN(n)||isNaN(t))throw new Error("Invalid arguments passed to jsPDF.API.__acroform__.clearBit");return n&~(1<<t)},j1=Ue.__acroform__.getBit=function(n,t){if(isNaN(n)||isNaN(t))throw new Error("Invalid arguments passed to jsPDF.API.__acroform__.getBit");return n&1<<t?1:0},Ge=Ue.__acroform__.getBitForPdf=function(n,t){if(isNaN(n)||isNaN(t))throw new Error("Invalid arguments passed to jsPDF.API.__acroform__.getBitForPdf");return j1(n,t-1)},Ye=Ue.__acroform__.setBitForPdf=function(n,t){if(isNaN(n)||isNaN(t))throw new Error("Invalid arguments passed to jsPDF.API.__acroform__.setBitForPdf");return E1(n,t-1)},Je=Ue.__acroform__.clearBitForPdf=function(n,t){if(isNaN(n)||isNaN(t))throw new Error("Invalid arguments passed to jsPDF.API.__acroform__.clearBitForPdf");return O1(n,t-1)},B1=Ue.__acroform__.calculateCoordinates=function(n,t){var e=t.internal.getHorizontalCoordinate,i=t.internal.getVerticalCoordinate,o=n[0],a=n[1],c=n[2],l=n[3],h={};return h.lowerLeft_X=e(o)||0,h.lowerLeft_Y=i(a+l)||0,h.upperRight_X=e(o+c)||0,h.upperRight_Y=i(a)||0,[Number($t(h.lowerLeft_X)),Number($t(h.lowerLeft_Y)),Number($t(h.upperRight_X)),Number($t(h.upperRight_Y))]},M1=function(n){if(n.appearanceStreamContent)return n.appearanceStreamContent;if(n.V||n.DV){var t=[],e=n._V||n.DV,i=Yo(n,e),o=n.scope.internal.getFont(n.fontName,n.fontStyle).id;t.push("/Tx BMC"),t.push("q"),t.push("BT"),t.push(n.scope.__private__.encodeColorString(n.color)),t.push("/"+o+" "+$t(i.fontSize)+" Tf"),t.push("1 0 0 1 0 0 Tm"),t.push(i.text),t.push("ET"),t.push("Q"),t.push("EMC");var a=dr(n);return a.scope=n.scope,a.stream=t.join(`
24
+ `),a}},Yo=function(n,t){var e=n.fontSize===0?n.maxFontSize:n.fontSize,i={text:"",fontSize:""},o=(t=(t=t.substr(0,1)=="("?t.substr(1):t).substr(t.length-1)==")"?t.substr(0,t.length-1):t).split(" ");o=n.multiline?o.map(function(N){return N.split(`
25
+ `)}):o.map(function(N){return[N]});var a=e,c=It.internal.getHeight(n)||0;c=c<0?-c:c;var l=It.internal.getWidth(n)||0;l=l<0?-l:l;var h=function(N,E,z){if(N+1<o.length){var U=E+" "+o[N+1][0];return Ls(U,n,z).width<=l-4}return!1};a++;t:for(;a>0;){t="",a--;var d,m,_=Ls("3",n,a).height,k=n.multiline?c-a:(c-_)/2,p=k+=2,j=0,O=0,M=0;if(a<=0){t=`(...) Tj
26
+ `,t+="% Width of Text: "+Ls(t,n,a=12).width+", FieldWidth:"+l+`
27
+ `;break}for(var S="",V=0,G=0;G<o.length;G++)if(o.hasOwnProperty(G)){var q=!1;if(o[G].length!==1&&M!==o[G].length-1){if((_+2)*(V+2)+2>c)continue t;S+=o[G][M],q=!0,O=G,G--}else{S=(S+=o[G][M]+" ").substr(S.length-1)==" "?S.substr(0,S.length-1):S;var it=parseInt(G),vt=h(it,S,a),dt=G>=o.length-1;if(vt&&!dt){S+=" ",M=0;continue}if(vt||dt){if(dt)O=it;else if(n.multiline&&(_+2)*(V+2)+2>c)continue t}else{if(!n.multiline||(_+2)*(V+2)+2>c)continue t;O=it}}for(var X="",R=j;R<=O;R++){var tt=o[R];if(n.multiline){if(R===O){X+=tt[M]+" ",M=(M+1)%tt.length;continue}if(R===j){X+=tt[tt.length-1]+" ";continue}}X+=tt[0]+" "}switch(X=X.substr(X.length-1)==" "?X.substr(0,X.length-1):X,m=Ls(X,n,a).width,n.textAlign){case"right":d=l-m-2;break;case"center":d=(l-m)/2;break;default:d=2}t+=$t(d)+" "+$t(p)+` Td
28
+ `,t+="("+Ii(X)+`) Tj
29
+ `,t+=-$t(d)+` 0 Td
30
+ `,p=-(a+2),m=0,j=q?O:O+1,V++,S=""}break}return i.text=t,i.fontSize=a,i},Ls=function(n,t,e){var i=t.scope.internal.getFont(t.fontName,t.fontStyle),o=t.scope.getStringUnitWidth(n,{font:i,fontSize:parseFloat(e),charSpace:0})*parseFloat(e);return{height:t.scope.getStringUnitWidth("3",{font:i,fontSize:parseFloat(e),charSpace:0})*parseFloat(e)*1.5,width:o}},R1={fields:[],xForms:[],acroFormDictionaryRoot:null,printedOut:!1,internal:null,isInitialized:!1},T1=function(n,t){var e={type:"reference",object:n};t.internal.getPageInfo(n.page).pageContext.annotations.find(function(i){return i.type===e.type&&i.object===e.object})===void 0&&t.internal.getPageInfo(n.page).pageContext.annotations.push(e)},D1=function(n,t){if(t.scope=n,n.internal!==void 0&&(n.internal.acroformPlugin===void 0||n.internal.acroformPlugin.isInitialized===!1)){if(tr.FieldNum=0,n.internal.acroformPlugin=JSON.parse(JSON.stringify(R1)),n.internal.acroformPlugin.acroFormDictionaryRoot)throw new Error("Exception while creating AcroformDictionary");Qo=n.internal.scaleFactor,n.internal.acroformPlugin.acroFormDictionaryRoot=new Ff,n.internal.acroformPlugin.acroFormDictionaryRoot.scope=n,n.internal.acroformPlugin.acroFormDictionaryRoot._eventID=n.internal.events.subscribe("postPutResources",function(){(function(e){e.internal.events.unsubscribe(e.internal.acroformPlugin.acroFormDictionaryRoot._eventID),delete e.internal.acroformPlugin.acroFormDictionaryRoot._eventID,e.internal.acroformPlugin.printedOut=!0})(n)}),n.internal.events.subscribe("buildDocument",function(){(function(e){e.internal.acroformPlugin.acroFormDictionaryRoot.objId=void 0;var i=e.internal.acroformPlugin.acroFormDictionaryRoot.Fields;for(var o in i)if(i.hasOwnProperty(o)){var a=i[o];a.objId=void 0,a.hasAnnotation&&T1(a,e)}})(n)}),n.internal.events.subscribe("putCatalog",function(){(function(e){if(e.internal.acroformPlugin.acroFormDictionaryRoot===void 0)throw new Error("putCatalogCallback: Root missing.");e.internal.write("/AcroForm "+e.internal.acroformPlugin.acroFormDictionaryRoot.objId+" 0 R")})(n)}),n.internal.events.subscribe("postPutPages",function(e){(function(i,o){var a=!i;for(var c in i||(o.internal.newObjectDeferredBegin(o.internal.acroformPlugin.acroFormDictionaryRoot.objId,!0),o.internal.acroformPlugin.acroFormDictionaryRoot.putStream()),i=i||o.internal.acroformPlugin.acroFormDictionaryRoot.Kids)if(i.hasOwnProperty(c)){var l=i[c],h=[],d=l.Rect;if(l.Rect&&(l.Rect=B1(l.Rect,o)),o.internal.newObjectDeferredBegin(l.objId,!0),l.DA=It.createDefaultAppearanceStream(l),xe(l)==="object"&&typeof l.getKeyValueListForStream=="function"&&(h=l.getKeyValueListForStream()),l.Rect=d,l.hasAppearanceStream&&!l.appearanceStreamContent){var m=M1(l);h.push({key:"AP",value:"<</N "+m+">>"}),o.internal.acroformPlugin.xForms.push(m)}if(l.appearanceStreamContent){var _="";for(var k in l.appearanceStreamContent)if(l.appearanceStreamContent.hasOwnProperty(k)){var p=l.appearanceStreamContent[k];if(_+="/"+k+" ",_+="<<",Object.keys(p).length>=1||Array.isArray(p)){for(var c in p)if(p.hasOwnProperty(c)){var j=p[c];typeof j=="function"&&(j=j.call(o,l)),_+="/"+c+" "+j+" ",o.internal.acroformPlugin.xForms.indexOf(j)>=0||o.internal.acroformPlugin.xForms.push(j)}}else typeof(j=p)=="function"&&(j=j.call(o,l)),_+="/"+c+" "+j,o.internal.acroformPlugin.xForms.indexOf(j)>=0||o.internal.acroformPlugin.xForms.push(j);_+=">>"}h.push({key:"AP",value:`<<
31
+ `+_+">>"})}o.internal.putStream({additionalKeyValues:h,objectId:l.objId}),o.internal.out("endobj")}a&&(function(O,M){for(var S in O)if(O.hasOwnProperty(S)){var V=S,G=O[S];M.internal.newObjectDeferredBegin(G.objId,!0),xe(G)==="object"&&typeof G.putStream=="function"&&G.putStream(),delete O[V]}})(o.internal.acroformPlugin.xForms,o)})(e,n)}),n.internal.acroformPlugin.isInitialized=!0}},If=Ue.__acroform__.arrayToPdfArray=function(n,t,e){var i=function(c){return c};if(Array.isArray(n)){for(var o="[",a=0;a<n.length;a++)switch(a!==0&&(o+=" "),xe(n[a])){case"boolean":case"number":case"object":o+=n[a].toString();break;case"string":n[a].substr(0,1)==="/"?o+="/"+ki(n[a].substr(1)):(t!==void 0&&e&&(i=e.internal.getEncryptor(t)),o+="("+Ii(i(n[a].toString()))+")")}return o+"]"}throw new Error("Invalid argument passed to jsPDF.__acroform__.arrayToPdfArray")},Oo=function(n,t,e){var i=function(o){return o};return t!==void 0&&e&&(i=e.internal.getEncryptor(t)),(n=n||"").toString(),"("+Ii(i(n))+")"},pr=function(){this._objId=void 0,this._scope=void 0,Object.defineProperty(this,"objId",{get:function(){if(this._objId===void 0){if(this.scope===void 0)return;this._objId=this.scope.internal.newObjectDeferred()}return this._objId},set:function(n){this._objId=n}}),Object.defineProperty(this,"scope",{value:this._scope,writable:!0})};pr.prototype.toString=function(){return this.objId+" 0 R"},pr.prototype.putStream=function(){var n=this.getKeyValueListForStream();this.scope.internal.putStream({data:this.stream,additionalKeyValues:n,objectId:this.objId}),this.scope.internal.out("endobj")},pr.prototype.getKeyValueListForStream=function(){var n=[],t=Object.getOwnPropertyNames(this).filter(function(a){return a!="content"&&a!="appearanceStreamContent"&&a!="scope"&&a!="objId"&&a.substring(0,1)!="_"});for(var e in t)if(Object.getOwnPropertyDescriptor(this,t[e]).configurable===!1){var i=t[e],o=this[i];o&&(Array.isArray(o)?n.push({key:i,value:If(o,this.objId,this.scope)}):o instanceof pr?(o.scope=this.scope,n.push({key:i,value:o.objId+" 0 R"})):typeof o!="function"&&n.push({key:i,value:o}))}return n};var Cf=function(){pr.call(this),Object.defineProperty(this,"Type",{value:"/XObject",configurable:!1,writable:!0}),Object.defineProperty(this,"Subtype",{value:"/Form",configurable:!1,writable:!0}),Object.defineProperty(this,"FormType",{value:1,configurable:!1,writable:!0});var n,t=[];Object.defineProperty(this,"BBox",{configurable:!1,get:function(){return t},set:function(e){t=e}}),Object.defineProperty(this,"Resources",{value:"2 0 R",configurable:!1,writable:!0}),Object.defineProperty(this,"stream",{enumerable:!1,configurable:!0,set:function(e){n=e.trim()},get:function(){return n||null}})};kn(Cf,pr);var Ff=function(){pr.call(this);var n,t=[];Object.defineProperty(this,"Kids",{enumerable:!1,configurable:!0,get:function(){return t.length>0?t:void 0}}),Object.defineProperty(this,"Fields",{enumerable:!1,configurable:!1,get:function(){return t}}),Object.defineProperty(this,"DA",{enumerable:!1,configurable:!1,get:function(){if(n){var e=function(i){return i};return this.scope&&(e=this.scope.internal.getEncryptor(this.objId)),"("+Ii(e(n))+")"}},set:function(e){n=e}})};kn(Ff,pr);var tr=function n(){pr.call(this);var t=4;Object.defineProperty(this,"F",{enumerable:!1,configurable:!1,get:function(){return t},set:function(S){if(isNaN(S))throw new Error('Invalid value "'+S+'" for attribute F supplied.');t=S}}),Object.defineProperty(this,"showWhenPrinted",{enumerable:!0,configurable:!0,get:function(){return!!Ge(t,3)},set:function(S){S?this.F=Ye(t,3):this.F=Je(t,3)}});var e=0;Object.defineProperty(this,"Ff",{enumerable:!1,configurable:!1,get:function(){return e},set:function(S){if(isNaN(S))throw new Error('Invalid value "'+S+'" for attribute Ff supplied.');e=S}});var i=[];Object.defineProperty(this,"Rect",{enumerable:!1,configurable:!1,get:function(){if(i.length!==0)return i},set:function(S){i=S!==void 0?S:[]}}),Object.defineProperty(this,"x",{enumerable:!0,configurable:!0,get:function(){return!i||isNaN(i[0])?0:i[0]},set:function(S){i[0]=S}}),Object.defineProperty(this,"y",{enumerable:!0,configurable:!0,get:function(){return!i||isNaN(i[1])?0:i[1]},set:function(S){i[1]=S}}),Object.defineProperty(this,"width",{enumerable:!0,configurable:!0,get:function(){return!i||isNaN(i[2])?0:i[2]},set:function(S){i[2]=S}}),Object.defineProperty(this,"height",{enumerable:!0,configurable:!0,get:function(){return!i||isNaN(i[3])?0:i[3]},set:function(S){i[3]=S}});var o="";Object.defineProperty(this,"FT",{enumerable:!0,configurable:!1,get:function(){return o},set:function(S){switch(S){case"/Btn":case"/Tx":case"/Ch":case"/Sig":o=S;break;default:throw new Error('Invalid value "'+S+'" for attribute FT supplied.')}}});var a=null;Object.defineProperty(this,"T",{enumerable:!0,configurable:!1,get:function(){if(!a||a.length<1){if(this instanceof Fs)return;a="FieldObject"+n.FieldNum++}var S=function(V){return V};return this.scope&&(S=this.scope.internal.getEncryptor(this.objId)),"("+Ii(S(a))+")"},set:function(S){a=S.toString()}}),Object.defineProperty(this,"fieldName",{configurable:!0,enumerable:!0,get:function(){return a},set:function(S){a=S}});var c="helvetica";Object.defineProperty(this,"fontName",{enumerable:!0,configurable:!0,get:function(){return c},set:function(S){c=S}});var l="normal";Object.defineProperty(this,"fontStyle",{enumerable:!0,configurable:!0,get:function(){return l},set:function(S){l=S}});var h=0;Object.defineProperty(this,"fontSize",{enumerable:!0,configurable:!0,get:function(){return h},set:function(S){h=S}});var d=void 0;Object.defineProperty(this,"maxFontSize",{enumerable:!0,configurable:!0,get:function(){return d===void 0?50/Qo:d},set:function(S){d=S}});var m="black";Object.defineProperty(this,"color",{enumerable:!0,configurable:!0,get:function(){return m},set:function(S){m=S}});var _="/F1 0 Tf 0 g";Object.defineProperty(this,"DA",{enumerable:!0,configurable:!1,get:function(){if(!(!_||this instanceof Fs||this instanceof Zr))return Oo(_,this.objId,this.scope)},set:function(S){S=S.toString(),_=S}});var k=null;Object.defineProperty(this,"DV",{enumerable:!1,configurable:!1,get:function(){if(k)return this instanceof nn==0?Oo(k,this.objId,this.scope):k},set:function(S){S=S.toString(),k=this instanceof nn==0?S.substr(0,1)==="("?Qi(S.substr(1,S.length-2)):Qi(S):S}}),Object.defineProperty(this,"defaultValue",{enumerable:!0,configurable:!0,get:function(){return this instanceof nn==1?Qi(k.substr(1,k.length-1)):k},set:function(S){S=S.toString(),k=this instanceof nn==1?"/"+ki(S):S}});var p=null;Object.defineProperty(this,"_V",{enumerable:!1,configurable:!1,get:function(){if(p)return p},set:function(S){this.V=S}}),Object.defineProperty(this,"V",{enumerable:!1,configurable:!1,get:function(){if(p)return this instanceof nn==0?Oo(p,this.objId,this.scope):p},set:function(S){S=S.toString(),p=this instanceof nn==0?S.substr(0,1)==="("?Qi(S.substr(1,S.length-2)):Qi(S):S}}),Object.defineProperty(this,"value",{enumerable:!0,configurable:!0,get:function(){return this instanceof nn==1?Qi(p.substr(1,p.length-1)):p},set:function(S){S=S.toString(),p=this instanceof nn==1?"/"+ki(S):S}}),Object.defineProperty(this,"hasAnnotation",{enumerable:!0,configurable:!0,get:function(){return this.Rect}}),Object.defineProperty(this,"Type",{enumerable:!0,configurable:!1,get:function(){return this.hasAnnotation?"/Annot":null}}),Object.defineProperty(this,"Subtype",{enumerable:!0,configurable:!1,get:function(){return this.hasAnnotation?"/Widget":null}});var j,O=!1;Object.defineProperty(this,"hasAppearanceStream",{enumerable:!0,configurable:!0,get:function(){return O},set:function(S){S=!!S,O=S}}),Object.defineProperty(this,"page",{enumerable:!0,configurable:!0,get:function(){if(j)return j},set:function(S){j=S}}),Object.defineProperty(this,"readOnly",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,1)},set:function(S){S?this.Ff=Ye(this.Ff,1):this.Ff=Je(this.Ff,1)}}),Object.defineProperty(this,"required",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,2)},set:function(S){S?this.Ff=Ye(this.Ff,2):this.Ff=Je(this.Ff,2)}}),Object.defineProperty(this,"noExport",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,3)},set:function(S){S?this.Ff=Ye(this.Ff,3):this.Ff=Je(this.Ff,3)}});var M=null;Object.defineProperty(this,"Q",{enumerable:!0,configurable:!1,get:function(){if(M!==null)return M},set:function(S){if([0,1,2].indexOf(S)===-1)throw new Error('Invalid value "'+S+'" for attribute Q supplied.');M=S}}),Object.defineProperty(this,"textAlign",{get:function(){var S;switch(M){case 0:default:S="left";break;case 1:S="center";break;case 2:S="right"}return S},configurable:!0,enumerable:!0,set:function(S){switch(S){case"right":case 2:M=2;break;case"center":case 1:M=1;break;default:M=0}}})};kn(tr,pr);var xi=function(){tr.call(this),this.FT="/Ch",this.V="()",this.fontName="zapfdingbats";var n=0;Object.defineProperty(this,"TI",{enumerable:!0,configurable:!1,get:function(){return n},set:function(e){n=e}}),Object.defineProperty(this,"topIndex",{enumerable:!0,configurable:!0,get:function(){return n},set:function(e){n=e}});var t=[];Object.defineProperty(this,"Opt",{enumerable:!0,configurable:!1,get:function(){return If(t,this.objId,this.scope)},set:function(e){var i,o;o=[],typeof(i=e)=="string"&&(o=(function(a,c,l){l||(l=1);for(var h,d=[];h=c.exec(a);)d.push(h[l]);return d})(i,/\((.*?)\)/g)),t=o}}),this.getOptions=function(){return t},this.setOptions=function(e){t=e,this.sort&&t.sort()},this.addOption=function(e){e=(e=e||"").toString(),t.push(e),this.sort&&t.sort()},this.removeOption=function(e,i){for(i=i||!1,e=(e=e||"").toString();t.indexOf(e)!==-1&&(t.splice(t.indexOf(e),1),i!==!1););},Object.defineProperty(this,"combo",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,18)},set:function(e){e?this.Ff=Ye(this.Ff,18):this.Ff=Je(this.Ff,18)}}),Object.defineProperty(this,"edit",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,19)},set:function(e){this.combo===!0&&(e?this.Ff=Ye(this.Ff,19):this.Ff=Je(this.Ff,19))}}),Object.defineProperty(this,"sort",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,20)},set:function(e){e?(this.Ff=Ye(this.Ff,20),t.sort()):this.Ff=Je(this.Ff,20)}}),Object.defineProperty(this,"multiSelect",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,22)},set:function(e){e?this.Ff=Ye(this.Ff,22):this.Ff=Je(this.Ff,22)}}),Object.defineProperty(this,"doNotSpellCheck",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,23)},set:function(e){e?this.Ff=Ye(this.Ff,23):this.Ff=Je(this.Ff,23)}}),Object.defineProperty(this,"commitOnSelChange",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,27)},set:function(e){e?this.Ff=Ye(this.Ff,27):this.Ff=Je(this.Ff,27)}}),this.hasAppearanceStream=!1};kn(xi,tr);var _i=function(){xi.call(this),this.fontName="helvetica",this.combo=!1};kn(_i,xi);var Ai=function(){_i.call(this),this.combo=!0};kn(Ai,_i);var Fa=function(){Ai.call(this),this.edit=!0};kn(Fa,Ai);var nn=function(){tr.call(this),this.FT="/Btn",Object.defineProperty(this,"noToggleToOff",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,15)},set:function(e){e?this.Ff=Ye(this.Ff,15):this.Ff=Je(this.Ff,15)}}),Object.defineProperty(this,"radio",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,16)},set:function(e){e?this.Ff=Ye(this.Ff,16):this.Ff=Je(this.Ff,16)}}),Object.defineProperty(this,"pushButton",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,17)},set:function(e){e?this.Ff=Ye(this.Ff,17):this.Ff=Je(this.Ff,17)}}),Object.defineProperty(this,"radioIsUnison",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,26)},set:function(e){e?this.Ff=Ye(this.Ff,26):this.Ff=Je(this.Ff,26)}});var n,t={};Object.defineProperty(this,"MK",{enumerable:!1,configurable:!1,get:function(){var e=function(a){return a};if(this.scope&&(e=this.scope.internal.getEncryptor(this.objId)),Object.keys(t).length!==0){var i,o=[];for(i in o.push("<<"),t)o.push("/"+i+" ("+Ii(e(t[i]))+")");return o.push(">>"),o.join(`
32
+ `)}},set:function(e){xe(e)==="object"&&(t=e)}}),Object.defineProperty(this,"caption",{enumerable:!0,configurable:!0,get:function(){return t.CA||""},set:function(e){typeof e=="string"&&(t.CA=e)}}),Object.defineProperty(this,"AS",{enumerable:!1,configurable:!1,get:function(){return n},set:function(e){var i=e==null?"":e.toString();i.substr(0,1)==="/"&&(i=i.substr(1)),n="/"+ki(i)}}),Object.defineProperty(this,"appearanceState",{enumerable:!0,configurable:!0,get:function(){return n.substr(1,n.length-1)},set:function(e){n="/"+ki(e)}})};kn(nn,tr);var Ea=function(){nn.call(this),this.pushButton=!0};kn(Ea,nn);var Ni=function(){nn.call(this),this.radio=!0,this.pushButton=!1;var n=[];Object.defineProperty(this,"Kids",{enumerable:!0,configurable:!1,get:function(){return n},set:function(t){n=t!==void 0?t:[]}})};kn(Ni,nn);var Fs=function(){var n,t;tr.call(this),Object.defineProperty(this,"Parent",{enumerable:!1,configurable:!1,get:function(){return n},set:function(o){n=o}}),Object.defineProperty(this,"optionName",{enumerable:!1,configurable:!0,get:function(){return t},set:function(o){t=o}});var e,i={};Object.defineProperty(this,"MK",{enumerable:!1,configurable:!1,get:function(){var o=function(l){return l};this.scope&&(o=this.scope.internal.getEncryptor(this.objId));var a,c=[];for(a in c.push("<<"),i)c.push("/"+a+" ("+Ii(o(i[a]))+")");return c.push(">>"),c.join(`
33
+ `)},set:function(o){xe(o)==="object"&&(i=o)}}),Object.defineProperty(this,"caption",{enumerable:!0,configurable:!0,get:function(){return i.CA||""},set:function(o){typeof o=="string"&&(i.CA=o)}}),Object.defineProperty(this,"AS",{enumerable:!1,configurable:!1,get:function(){return e},set:function(o){var a=o==null?"":o.toString();a.substr(0,1)==="/"&&(a=a.substr(1)),e="/"+ki(a)}}),Object.defineProperty(this,"appearanceState",{enumerable:!0,configurable:!0,get:function(){return e.substr(1,e.length-1)},set:function(o){var a=o==null?"":o.toString();a.substr(0,1)==="/"&&(a=a.substr(1)),e="/"+ki(a)}}),this.caption="l",this.appearanceState="Off",this._AppearanceType=It.RadioButton.Circle,this.appearanceStreamContent=this._AppearanceType.createAppearanceStream(this.optionName)};kn(Fs,tr),Ni.prototype.setAppearance=function(n){if(!("createAppearanceStream"in n)||!("getCA"in n))throw new Error("Couldn't assign Appearance to RadioButton. Appearance was Invalid!");for(var t in this.Kids)if(this.Kids.hasOwnProperty(t)){var e=this.Kids[t];e.appearanceStreamContent=n.createAppearanceStream(e.optionName),e.caption=n.getCA()}},Ni.prototype.createOption=function(n){var t=new Fs;return t.Parent=this,t.optionName=n,this.Kids.push(t),q1.call(this.scope,t),t};var Oa=function(){nn.call(this),this.fontName="zapfdingbats",this.caption="3",this.appearanceState="On",this.value="On",this.textAlign="center",this.appearanceStreamContent=It.CheckBox.createAppearanceStream()};kn(Oa,nn);var Zr=function(){tr.call(this),this.FT="/Tx",Object.defineProperty(this,"multiline",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,13)},set:function(t){t?this.Ff=Ye(this.Ff,13):this.Ff=Je(this.Ff,13)}}),Object.defineProperty(this,"fileSelect",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,21)},set:function(t){t?this.Ff=Ye(this.Ff,21):this.Ff=Je(this.Ff,21)}}),Object.defineProperty(this,"doNotSpellCheck",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,23)},set:function(t){t?this.Ff=Ye(this.Ff,23):this.Ff=Je(this.Ff,23)}}),Object.defineProperty(this,"doNotScroll",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,24)},set:function(t){t?this.Ff=Ye(this.Ff,24):this.Ff=Je(this.Ff,24)}}),Object.defineProperty(this,"comb",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,25)},set:function(t){t?this.Ff=Ye(this.Ff,25):this.Ff=Je(this.Ff,25)}}),Object.defineProperty(this,"richText",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,26)},set:function(t){t?this.Ff=Ye(this.Ff,26):this.Ff=Je(this.Ff,26)}});var n=null;Object.defineProperty(this,"MaxLen",{enumerable:!0,configurable:!1,get:function(){return n},set:function(t){n=t}}),Object.defineProperty(this,"maxLength",{enumerable:!0,configurable:!0,get:function(){return n},set:function(t){Number.isInteger(t)&&(n=t)}}),Object.defineProperty(this,"hasAppearanceStream",{enumerable:!0,configurable:!0,get:function(){return this.V||this.DV}})};kn(Zr,tr);var ja=function(){Zr.call(this),Object.defineProperty(this,"password",{enumerable:!0,configurable:!0,get:function(){return!!Ge(this.Ff,14)},set:function(n){n?this.Ff=Ye(this.Ff,14):this.Ff=Je(this.Ff,14)}}),this.password=!0};kn(ja,Zr);var It={CheckBox:{createAppearanceStream:function(){return{N:{On:It.CheckBox.YesNormal},D:{On:It.CheckBox.YesPushDown,Off:It.CheckBox.OffPushDown}}},YesPushDown:function(n){var t=dr(n);t.scope=n.scope;var e=[],i=n.scope.internal.getFont(n.fontName,n.fontStyle).id,o=n.scope.__private__.encodeColorString(n.color),a=Yo(n,n.caption);return e.push("0.749023 g"),e.push("0 0 "+$t(It.internal.getWidth(n))+" "+$t(It.internal.getHeight(n))+" re"),e.push("f"),e.push("BMC"),e.push("q"),e.push("0 0 1 rg"),e.push("/"+i+" "+$t(a.fontSize)+" Tf "+o),e.push("BT"),e.push(a.text),e.push("ET"),e.push("Q"),e.push("EMC"),t.stream=e.join(`
34
+ `),t},YesNormal:function(n){var t=dr(n);t.scope=n.scope;var e=n.scope.internal.getFont(n.fontName,n.fontStyle).id,i=n.scope.__private__.encodeColorString(n.color),o=[],a=It.internal.getHeight(n),c=It.internal.getWidth(n),l=Yo(n,n.caption);return o.push("1 g"),o.push("0 0 "+$t(c)+" "+$t(a)+" re"),o.push("f"),o.push("q"),o.push("0 0 1 rg"),o.push("0 0 "+$t(c-1)+" "+$t(a-1)+" re"),o.push("W"),o.push("n"),o.push("0 g"),o.push("BT"),o.push("/"+e+" "+$t(l.fontSize)+" Tf "+i),o.push(l.text),o.push("ET"),o.push("Q"),t.stream=o.join(`
35
+ `),t},OffPushDown:function(n){var t=dr(n);t.scope=n.scope;var e=[];return e.push("0.749023 g"),e.push("0 0 "+$t(It.internal.getWidth(n))+" "+$t(It.internal.getHeight(n))+" re"),e.push("f"),t.stream=e.join(`
36
+ `),t}},RadioButton:{Circle:{createAppearanceStream:function(n){var t={D:{Off:It.RadioButton.Circle.OffPushDown},N:{}};return t.N[n]=It.RadioButton.Circle.YesNormal,t.D[n]=It.RadioButton.Circle.YesPushDown,t},getCA:function(){return"l"},YesNormal:function(n){var t=dr(n);t.scope=n.scope;var e=[],i=It.internal.getWidth(n)<=It.internal.getHeight(n)?It.internal.getWidth(n)/4:It.internal.getHeight(n)/4;i=Number((.9*i).toFixed(5));var o=It.internal.Bezier_C,a=Number((i*o).toFixed(5));return e.push("q"),e.push("1 0 0 1 "+Kr(It.internal.getWidth(n)/2)+" "+Kr(It.internal.getHeight(n)/2)+" cm"),e.push(i+" 0 m"),e.push(i+" "+a+" "+a+" "+i+" 0 "+i+" c"),e.push("-"+a+" "+i+" -"+i+" "+a+" -"+i+" 0 c"),e.push("-"+i+" -"+a+" -"+a+" -"+i+" 0 -"+i+" c"),e.push(a+" -"+i+" "+i+" -"+a+" "+i+" 0 c"),e.push("f"),e.push("Q"),t.stream=e.join(`
37
+ `),t},YesPushDown:function(n){var t=dr(n);t.scope=n.scope;var e=[],i=It.internal.getWidth(n)<=It.internal.getHeight(n)?It.internal.getWidth(n)/4:It.internal.getHeight(n)/4;i=Number((.9*i).toFixed(5));var o=Number((2*i).toFixed(5)),a=Number((o*It.internal.Bezier_C).toFixed(5)),c=Number((i*It.internal.Bezier_C).toFixed(5));return e.push("0.749023 g"),e.push("q"),e.push("1 0 0 1 "+Kr(It.internal.getWidth(n)/2)+" "+Kr(It.internal.getHeight(n)/2)+" cm"),e.push(o+" 0 m"),e.push(o+" "+a+" "+a+" "+o+" 0 "+o+" c"),e.push("-"+a+" "+o+" -"+o+" "+a+" -"+o+" 0 c"),e.push("-"+o+" -"+a+" -"+a+" -"+o+" 0 -"+o+" c"),e.push(a+" -"+o+" "+o+" -"+a+" "+o+" 0 c"),e.push("f"),e.push("Q"),e.push("0 g"),e.push("q"),e.push("1 0 0 1 "+Kr(It.internal.getWidth(n)/2)+" "+Kr(It.internal.getHeight(n)/2)+" cm"),e.push(i+" 0 m"),e.push(i+" "+c+" "+c+" "+i+" 0 "+i+" c"),e.push("-"+c+" "+i+" -"+i+" "+c+" -"+i+" 0 c"),e.push("-"+i+" -"+c+" -"+c+" -"+i+" 0 -"+i+" c"),e.push(c+" -"+i+" "+i+" -"+c+" "+i+" 0 c"),e.push("f"),e.push("Q"),t.stream=e.join(`
38
+ `),t},OffPushDown:function(n){var t=dr(n);t.scope=n.scope;var e=[],i=It.internal.getWidth(n)<=It.internal.getHeight(n)?It.internal.getWidth(n)/4:It.internal.getHeight(n)/4;i=Number((.9*i).toFixed(5));var o=Number((2*i).toFixed(5)),a=Number((o*It.internal.Bezier_C).toFixed(5));return e.push("0.749023 g"),e.push("q"),e.push("1 0 0 1 "+Kr(It.internal.getWidth(n)/2)+" "+Kr(It.internal.getHeight(n)/2)+" cm"),e.push(o+" 0 m"),e.push(o+" "+a+" "+a+" "+o+" 0 "+o+" c"),e.push("-"+a+" "+o+" -"+o+" "+a+" -"+o+" 0 c"),e.push("-"+o+" -"+a+" -"+a+" -"+o+" 0 -"+o+" c"),e.push(a+" -"+o+" "+o+" -"+a+" "+o+" 0 c"),e.push("f"),e.push("Q"),t.stream=e.join(`
39
+ `),t}},Cross:{createAppearanceStream:function(n){var t={D:{Off:It.RadioButton.Cross.OffPushDown},N:{}};return t.N[n]=It.RadioButton.Cross.YesNormal,t.D[n]=It.RadioButton.Cross.YesPushDown,t},getCA:function(){return"8"},YesNormal:function(n){var t=dr(n);t.scope=n.scope;var e=[],i=It.internal.calculateCross(n);return e.push("q"),e.push("1 1 "+$t(It.internal.getWidth(n)-2)+" "+$t(It.internal.getHeight(n)-2)+" re"),e.push("W"),e.push("n"),e.push($t(i.x1.x)+" "+$t(i.x1.y)+" m"),e.push($t(i.x2.x)+" "+$t(i.x2.y)+" l"),e.push($t(i.x4.x)+" "+$t(i.x4.y)+" m"),e.push($t(i.x3.x)+" "+$t(i.x3.y)+" l"),e.push("s"),e.push("Q"),t.stream=e.join(`
40
+ `),t},YesPushDown:function(n){var t=dr(n);t.scope=n.scope;var e=It.internal.calculateCross(n),i=[];return i.push("0.749023 g"),i.push("0 0 "+$t(It.internal.getWidth(n))+" "+$t(It.internal.getHeight(n))+" re"),i.push("f"),i.push("q"),i.push("1 1 "+$t(It.internal.getWidth(n)-2)+" "+$t(It.internal.getHeight(n)-2)+" re"),i.push("W"),i.push("n"),i.push($t(e.x1.x)+" "+$t(e.x1.y)+" m"),i.push($t(e.x2.x)+" "+$t(e.x2.y)+" l"),i.push($t(e.x4.x)+" "+$t(e.x4.y)+" m"),i.push($t(e.x3.x)+" "+$t(e.x3.y)+" l"),i.push("s"),i.push("Q"),t.stream=i.join(`
41
+ `),t},OffPushDown:function(n){var t=dr(n);t.scope=n.scope;var e=[];return e.push("0.749023 g"),e.push("0 0 "+$t(It.internal.getWidth(n))+" "+$t(It.internal.getHeight(n))+" re"),e.push("f"),t.stream=e.join(`
42
+ `),t}}},createDefaultAppearanceStream:function(n){var t=n.scope.internal.getFont(n.fontName,n.fontStyle).id,e=n.scope.__private__.encodeColorString(n.color);return"/"+t+" "+n.fontSize+" Tf "+e}};It.internal={Bezier_C:.551915024494,calculateCross:function(n){var t=It.internal.getWidth(n),e=It.internal.getHeight(n),i=Math.min(t,e);return{x1:{x:(t-i)/2,y:(e-i)/2+i},x2:{x:(t-i)/2+i,y:(e-i)/2},x3:{x:(t-i)/2,y:(e-i)/2},x4:{x:(t-i)/2+i,y:(e-i)/2+i}}}},It.internal.getWidth=function(n){var t=0;return xe(n)==="object"&&(t=Cu(n.Rect[2])),t},It.internal.getHeight=function(n){var t=0;return xe(n)==="object"&&(t=Cu(n.Rect[3])),t};var q1=Ue.addField=function(n){if(D1(this,n),!(n instanceof tr))throw new Error("Invalid argument passed to jsPDF.addField.");var t;return(t=n).scope.internal.acroformPlugin.printedOut&&(t.scope.internal.acroformPlugin.printedOut=!1,t.scope.internal.acroformPlugin.acroFormDictionaryRoot=null),t.scope.internal.acroformPlugin.acroFormDictionaryRoot.Fields.push(t),n.page=n.scope.internal.getCurrentPageInfo().pageNumber,this};Ue.AcroFormChoiceField=xi,Ue.AcroFormListBox=_i,Ue.AcroFormComboBox=Ai,Ue.AcroFormEditBox=Fa,Ue.AcroFormButton=nn,Ue.AcroFormPushButton=Ea,Ue.AcroFormRadioButton=Ni,Ue.AcroFormCheckBox=Oa,Ue.AcroFormTextField=Zr,Ue.AcroFormPasswordField=ja,Ue.AcroFormAppearance=It,Ue.AcroForm={ChoiceField:xi,ListBox:_i,ComboBox:Ai,EditBox:Fa,Button:nn,PushButton:Ea,RadioButton:Ni,CheckBox:Oa,TextField:Zr,PasswordField:ja,Appearance:It},Mt.AcroForm={ChoiceField:xi,ListBox:_i,ComboBox:Ai,EditBox:Fa,Button:nn,PushButton:Ea,RadioButton:Ni,CheckBox:Oa,TextField:Zr,PasswordField:ja,Appearance:It};Mt.AcroForm;function Ef(n){return n.reduce(function(t,e,i){return t[e]=i,t},{})}(function(n){var t="addImage_";n.__addimage__={};var e="UNKNOWN",i={PNG:[[137,80,78,71]],TIFF:[[77,77,0,42],[73,73,42,0]],JPEG:[[255,216,255,224,void 0,void 0,74,70,73,70,0],[255,216,255,225,void 0,void 0,69,120,105,102,0,0],[255,216,255,219],[255,216,255,238]],JPEG2000:[[0,0,0,12,106,80,32,32]],GIF87a:[[71,73,70,56,55,97]],GIF89a:[[71,73,70,56,57,97]],WEBP:[[82,73,70,70,void 0,void 0,void 0,void 0,87,69,66,80]],BMP:[[66,77],[66,65],[67,73],[67,80],[73,67],[80,84]]},o=n.__addimage__.getImageFileTypeByImageData=function(N,E){var z,U,rt,ot,ft,nt=e;if((E=E||e)==="RGBA"||N.data!==void 0&&N.data instanceof Uint8ClampedArray&&"height"in N&&"width"in N)return"RGBA";if(vt(N))for(ft in i)for(rt=i[ft],z=0;z<rt.length;z+=1){for(ot=!0,U=0;U<rt[z].length;U+=1)if(rt[z][U]!==void 0&&rt[z][U]!==N[U]){ot=!1;break}if(ot===!0){nt=ft;break}}else for(ft in i)for(rt=i[ft],z=0;z<rt.length;z+=1){for(ot=!0,U=0;U<rt[z].length;U+=1)if(rt[z][U]!==void 0&&rt[z][U]!==N.charCodeAt(U)){ot=!1;break}if(ot===!0){nt=ft;break}}return nt===e&&E!==e&&(nt=E),nt},a=function N(E){for(var z=this.internal.write,U=this.internal.putStream,rt=(0,this.internal.getFilters)();rt.indexOf("FlateEncode")!==-1;)rt.splice(rt.indexOf("FlateEncode"),1);E.objectId=this.internal.newObject();var ot=[];if(ot.push({key:"Type",value:"/XObject"}),ot.push({key:"Subtype",value:"/Image"}),ot.push({key:"Width",value:E.width}),ot.push({key:"Height",value:E.height}),E.colorSpace===S.INDEXED?ot.push({key:"ColorSpace",value:"[/Indexed /DeviceRGB "+(E.palette.length/3-1)+" "+("sMask"in E&&E.sMask!==void 0?E.objectId+2:E.objectId+1)+" 0 R]"}):(ot.push({key:"ColorSpace",value:"/"+E.colorSpace}),E.colorSpace===S.DEVICE_CMYK&&ot.push({key:"Decode",value:"[1 0 1 0 1 0 1 0]"})),ot.push({key:"BitsPerComponent",value:E.bitsPerComponent}),"decodeParameters"in E&&E.decodeParameters!==void 0&&ot.push({key:"DecodeParms",value:"<<"+E.decodeParameters+">>"}),"transparency"in E&&Array.isArray(E.transparency)&&E.transparency.length>0){for(var ft="",nt=0,ct=E.transparency.length;nt<ct;nt++)ft+=E.transparency[nt]+" "+E.transparency[nt]+" ";ot.push({key:"Mask",value:"["+ft+"]"})}E.sMask!==void 0&&ot.push({key:"SMask",value:E.objectId+1+" 0 R"});var At=E.filter!==void 0?["/"+E.filter]:void 0;if(U({data:E.data,additionalKeyValues:ot,alreadyAppliedFilters:At,objectId:E.objectId}),z("endobj"),"sMask"in E&&E.sMask!==void 0){var wt,x=(wt=E.sMaskBitsPerComponent)!==null&&wt!==void 0?wt:E.bitsPerComponent,B={width:E.width,height:E.height,colorSpace:"DeviceGray",bitsPerComponent:x,data:E.sMask};"filter"in E&&(B.decodeParameters="/Predictor ".concat(E.predictor," /Colors 1 /BitsPerComponent ").concat(x," /Columns ").concat(E.width),B.filter=E.filter),N.call(this,B)}if(E.colorSpace===S.INDEXED){var T=this.internal.newObject();U({data:X(new Uint8Array(E.palette)),objectId:T}),z("endobj")}},c=function(){var N=this.internal.collections[t+"images"];for(var E in N)a.call(this,N[E])},l=function(){var N,E=this.internal.collections[t+"images"],z=this.internal.write;for(var U in E)z("/I"+(N=E[U]).index,N.objectId,"0","R")},h=function(){this.internal.collections[t+"images"]||(this.internal.collections[t+"images"]={},this.internal.events.subscribe("putResources",c),this.internal.events.subscribe("putXobjectDict",l))},d=function(){var N=this.internal.collections[t+"images"];return h.call(this),N},m=function(){return Object.keys(this.internal.collections[t+"images"]).length},_=function(N){return typeof n["process"+N.toUpperCase()]=="function"},k=function(N){return xe(N)==="object"&&N.nodeType===1},p=function(N,E){if(N.nodeName==="IMG"&&N.hasAttribute("src")){var z=""+N.getAttribute("src");if(z.indexOf("data:image/")===0)return Ps(unescape(z).split("base64,").pop());var U=n.loadFile(z,!0);if(U!==void 0)return U}if(N.nodeName==="CANVAS"){if(N.width===0||N.height===0)throw new Error("Given canvas must have data. Canvas width: "+N.width+", height: "+N.height);var rt;switch(E){case"PNG":rt="image/png";break;case"WEBP":rt="image/webp";break;default:rt="image/jpeg"}return Ps(N.toDataURL(rt,1).split("base64,").pop())}},j=function(N){var E=this.internal.collections[t+"images"];if(E){for(var z in E)if(N===E[z].alias)return E[z]}},O=function(N,E,z){return N||E||(N=-96,E=-96),N<0&&(N=-1*z.width*72/N/this.internal.scaleFactor),E<0&&(E=-1*z.height*72/E/this.internal.scaleFactor),N===0&&(N=E*z.width/z.height),E===0&&(E=N*z.height/z.width),[N,E]},M=function(N,E,z,U,rt,ot){var ft=O.call(this,z,U,rt),nt=this.internal.getCoordinateString,ct=this.internal.getVerticalCoordinateString,At=d.call(this);if(z=ft[0],U=ft[1],At[rt.index]=rt,ot){ot*=Math.PI/180;var wt=Math.cos(ot),x=Math.sin(ot),B=function(H){return H.toFixed(4)},T=[B(wt),B(x),B(-1*x),B(wt),0,0,"cm"]}this.internal.write("q"),ot?(this.internal.write([1,"0","0",1,nt(N),ct(E+U),"cm"].join(" ")),this.internal.write(T.join(" ")),this.internal.write([nt(z),"0","0",nt(U),"0","0","cm"].join(" "))):this.internal.write([nt(z),"0","0",nt(U),nt(N),ct(E+U),"cm"].join(" ")),this.isAdvancedAPI()&&this.internal.write([1,0,0,-1,0,0,"cm"].join(" ")),this.internal.write("/I"+rt.index+" Do"),this.internal.write("Q")},S=n.color_spaces={DEVICE_RGB:"DeviceRGB",DEVICE_GRAY:"DeviceGray",DEVICE_CMYK:"DeviceCMYK",CAL_GREY:"CalGray",CAL_RGB:"CalRGB",LAB:"Lab",ICC_BASED:"ICCBased",INDEXED:"Indexed",PATTERN:"Pattern",SEPARATION:"Separation",DEVICE_N:"DeviceN"};n.decode={DCT_DECODE:"DCTDecode",FLATE_DECODE:"FlateDecode",LZW_DECODE:"LZWDecode",JPX_DECODE:"JPXDecode",JBIG2_DECODE:"JBIG2Decode",ASCII85_DECODE:"ASCII85Decode",ASCII_HEX_DECODE:"ASCIIHexDecode",RUN_LENGTH_DECODE:"RunLengthDecode",CCITT_FAX_DECODE:"CCITTFaxDecode"};var V=n.image_compression={NONE:"NONE",FAST:"FAST",MEDIUM:"MEDIUM",SLOW:"SLOW"},G=n.__addimage__.sHashCode=function(N){var E,z,U=0;if(typeof N=="string")for(z=N.length,E=0;E<z;E++)U=(U<<5)-U+N.charCodeAt(E),U|=0;else if(vt(N))for(z=N.byteLength/2,E=0;E<z;E++)U=(U<<5)-U+N[E],U|=0;return U},q=n.__addimage__.validateStringAsBase64=function(N){(N=N||"").toString().trim();var E=!0;return N.length===0&&(E=!1),N.length%4!=0&&(E=!1),/^[A-Za-z0-9+/]+$/.test(N.substr(0,N.length-2))===!1&&(E=!1),/^[A-Za-z0-9/][A-Za-z0-9+/]|[A-Za-z0-9+/]=|==$/.test(N.substr(-2))===!1&&(E=!1),E},it=n.__addimage__.extractImageFromDataUrl=function(N){if(N==null||!(N=N.trim()).startsWith("data:"))return null;var E=N.indexOf(",");return E<0?null:N.substring(0,E).trim().endsWith("base64")?N.substring(E+1):null};n.__addimage__.isArrayBuffer=function(N){return N instanceof ArrayBuffer};var vt=n.__addimage__.isArrayBufferView=function(N){return N instanceof Int8Array||N instanceof Uint8Array||N instanceof Uint8ClampedArray||N instanceof Int16Array||N instanceof Uint16Array||N instanceof Int32Array||N instanceof Uint32Array||N instanceof Float32Array||N instanceof Float64Array},dt=n.__addimage__.binaryStringToUint8Array=function(N){for(var E=N.length,z=new Uint8Array(E),U=0;U<E;U++)z[U]=N.charCodeAt(U);return z},X=n.__addimage__.arrayBufferToBinaryString=function(N){for(var E="",z=vt(N)?N:new Uint8Array(N),U=0;U<z.length;U+=8192)E+=String.fromCharCode.apply(null,z.subarray(U,U+8192));return E};n.addImage=function(){var N,E,z,U,rt,ot,ft,nt,ct;if(typeof arguments[1]=="number"?(E=e,z=arguments[1],U=arguments[2],rt=arguments[3],ot=arguments[4],ft=arguments[5],nt=arguments[6],ct=arguments[7]):(E=arguments[1],z=arguments[2],U=arguments[3],rt=arguments[4],ot=arguments[5],ft=arguments[6],nt=arguments[7],ct=arguments[8]),xe(N=arguments[0])==="object"&&!k(N)&&"imageData"in N){var At=N;N=At.imageData,E=At.format||E||e,z=At.x||z||0,U=At.y||U||0,rt=At.w||At.width||rt,ot=At.h||At.height||ot,ft=At.alias||ft,nt=At.compression||nt,ct=At.rotation||At.angle||ct}var wt=this.internal.getFilters();if(nt===void 0&&wt.indexOf("FlateEncode")!==-1&&(nt="SLOW"),isNaN(z)||isNaN(U))throw new Error("Invalid coordinates passed to jsPDF.addImage");h.call(this);var x=R.call(this,N,E,ft,nt);return M.call(this,z,U,rt,ot,x,ct),this};var R=function(N,E,z,U){var rt,ot,ft;if(typeof N=="string"&&o(N)===e){N=unescape(N);var nt=tt(N,!1);(nt!==""||(nt=n.loadFile(N,!0))!==void 0)&&(N=nt)}if(k(N)&&(N=p(N,E)),E=o(N,E),!_(E))throw new Error("addImage does not support files of type '"+E+"', please ensure that a plugin for '"+E+"' support is added.");if(((ft=z)==null||ft.length===0)&&(z=(function(ct){return typeof ct=="string"||vt(ct)?G(ct):vt(ct.data)?G(ct.data):null})(N)),(rt=j.call(this,z))||(N instanceof Uint8Array||E==="RGBA"||(ot=N,N=dt(N)),rt=this["process"+E.toUpperCase()](N,m.call(this),z,(function(ct){return ct&&typeof ct=="string"&&(ct=ct.toUpperCase()),ct in n.image_compression?ct:V.NONE})(U),ot)),!rt)throw new Error("An unknown error occurred whilst processing the image.");return rt},tt=n.__addimage__.convertBase64ToBinaryString=function(N,E){E=typeof E!="boolean"||E;var z,U="";if(typeof N=="string"){var rt;z=(rt=it(N))!==null&&rt!==void 0?rt:N;try{U=Ps(z)}catch(ot){if(E)throw q(z)?new Error("atob-Error in jsPDF.convertBase64ToBinaryString "+ot.message):new Error("Supplied Data is not a valid base64-String jsPDF.convertBase64ToBinaryString ")}}return U};n.getImageProperties=function(N){var E,z,U="";if(k(N)&&(N=p(N)),typeof N=="string"&&o(N)===e&&((U=tt(N,!1))===""&&(U=n.loadFile(N)||""),N=U),z=o(N),!_(z))throw new Error("addImage does not support files of type '"+z+"', please ensure that a plugin for '"+z+"' support is added.");if(N instanceof Uint8Array||(N=dt(N)),!(E=this["process"+z.toUpperCase()](N)))throw new Error("An unknown error occurred whilst processing the image");return E.fileType=z,E}})(Mt.API),(function(n){var t=function(e){if(e!==void 0&&e!="")return!0};Mt.API.events.push(["addPage",function(e){this.internal.getPageInfo(e.pageNumber).pageContext.annotations=[]}]),n.events.push(["putPage",function(e){for(var i,o,a,c=this.internal.getCoordinateString,l=this.internal.getVerticalCoordinateString,h=this.internal.getPageInfoByObjId(e.objId),d=e.pageContext.annotations,m=!1,_=0;_<d.length&&!m;_++)switch((i=d[_]).type){case"link":(t(i.options.url)||t(i.options.pageNumber))&&(m=!0);break;case"reference":case"text":case"freetext":m=!0}if(m!=0){this.internal.write("/Annots [");for(var k=0;k<d.length;k++){i=d[k];var p=this.internal.pdfEscape,j=this.internal.getEncryptor(e.objId);switch(i.type){case"reference":this.internal.write(" "+i.object.objId+" 0 R ");break;case"text":var O=this.internal.newAdditionalObject(),M=this.internal.newAdditionalObject(),S=this.internal.getEncryptor(O.objId),V=i.title||"Note";a="<</Type /Annot /Subtype /Text "+(o="/Rect ["+c(i.bounds.x)+" "+l(i.bounds.y+i.bounds.h)+" "+c(i.bounds.x+i.bounds.w)+" "+l(i.bounds.y)+"] ")+"/Contents ("+p(S(i.contents))+")",a+=" /Popup "+M.objId+" 0 R",a+=" /P "+h.objId+" 0 R",a+=" /T ("+p(S(V))+") >>",O.content=a;var G=O.objId+" 0 R";a="<</Type /Annot /Subtype /Popup "+(o="/Rect ["+c(i.bounds.x+30)+" "+l(i.bounds.y+i.bounds.h)+" "+c(i.bounds.x+i.bounds.w+30)+" "+l(i.bounds.y)+"] ")+" /Parent "+G,i.open&&(a+=" /Open true"),a+=" >>",M.content=a,this.internal.write(O.objId,"0 R",M.objId,"0 R");break;case"freetext":o="/Rect ["+c(i.bounds.x)+" "+l(i.bounds.y)+" "+c(i.bounds.x+i.bounds.w)+" "+l(i.bounds.y+i.bounds.h)+"] ";var q="font: Helvetica,sans-serif 12.0pt; text-align:left; color:#"+(i.color||"#000000");a="<</Type /Annot /Subtype /FreeText "+o+"/Contents ("+p(j(i.contents))+")",a+=" /DS("+p(j(q))+")",a+=" /Border [0 0 0]",a+=" >>",this.internal.write(a);break;case"link":if(i.options.name){var it=this.annotations._nameMap[i.options.name];i.options.pageNumber=it.page,i.options.top=it.y}else i.options.top||(i.options.top=0);if(o="/Rect ["+i.finalBounds.x+" "+i.finalBounds.y+" "+i.finalBounds.w+" "+i.finalBounds.h+"] ",a="",i.options.url)a="<</Type /Annot /Subtype /Link "+o+"/Border [0 0 0] /A <</S /URI /URI ("+p(j(i.options.url))+") >>";else if(i.options.pageNumber)switch(a="<</Type /Annot /Subtype /Link "+o+"/Border [0 0 0] /Dest ["+this.internal.getPageInfo(i.options.pageNumber).objId+" 0 R",i.options.magFactor=i.options.magFactor||"XYZ",i.options.magFactor){case"Fit":a+=" /Fit]";break;case"FitH":a+=" /FitH "+i.options.top+"]";break;case"FitV":i.options.left=i.options.left||0,a+=" /FitV "+i.options.left+"]";break;default:var vt=l(i.options.top);i.options.left=i.options.left||0,i.options.zoom===void 0&&(i.options.zoom=0),a+=" /XYZ "+i.options.left+" "+vt+" "+i.options.zoom+"]"}a!=""&&(a+=" >>",this.internal.write(a))}}this.internal.write("]")}}]),n.createAnnotation=function(e){var i=this.internal.getCurrentPageInfo();switch(e.type){case"link":this.link(e.bounds.x,e.bounds.y,e.bounds.w,e.bounds.h,e);break;case"text":case"freetext":i.pageContext.annotations.push(e)}},n.link=function(e,i,o,a,c){var l=this.internal.getCurrentPageInfo(),h=this.internal.getCoordinateString,d=this.internal.getVerticalCoordinateString;l.pageContext.annotations.push({finalBounds:{x:h(e),y:d(i),w:h(e+o),h:d(i+a)},options:c,type:"link"})},n.textWithLink=function(e,i,o,a){var c,l,h=this.getTextWidth(e),d=this.internal.getLineHeight()/this.internal.scaleFactor;if(a.maxWidth!==void 0){l=a.maxWidth;var m=this.splitTextToSize(e,l).length;c=Math.ceil(d*m)}else l=h,c=d;return this.text(e,i,o,a),o+=.2*d,a.align==="center"&&(i-=h/2),a.align==="right"&&(i-=h),this.link(i,o-d,l,c,a),h},n.getTextWidth=function(e){var i=this.internal.getFontSize();return this.getStringUnitWidth(e)*i/this.internal.scaleFactor}})(Mt.API),(function(n){var t={1569:[65152],1570:[65153,65154],1571:[65155,65156],1572:[65157,65158],1573:[65159,65160],1574:[65161,65162,65163,65164],1575:[65165,65166],1576:[65167,65168,65169,65170],1577:[65171,65172],1578:[65173,65174,65175,65176],1579:[65177,65178,65179,65180],1580:[65181,65182,65183,65184],1581:[65185,65186,65187,65188],1582:[65189,65190,65191,65192],1583:[65193,65194],1584:[65195,65196],1585:[65197,65198],1586:[65199,65200],1587:[65201,65202,65203,65204],1588:[65205,65206,65207,65208],1589:[65209,65210,65211,65212],1590:[65213,65214,65215,65216],1591:[65217,65218,65219,65220],1592:[65221,65222,65223,65224],1593:[65225,65226,65227,65228],1594:[65229,65230,65231,65232],1601:[65233,65234,65235,65236],1602:[65237,65238,65239,65240],1603:[65241,65242,65243,65244],1604:[65245,65246,65247,65248],1605:[65249,65250,65251,65252],1606:[65253,65254,65255,65256],1607:[65257,65258,65259,65260],1608:[65261,65262],1609:[65263,65264,64488,64489],1610:[65265,65266,65267,65268],1649:[64336,64337],1655:[64477],1657:[64358,64359,64360,64361],1658:[64350,64351,64352,64353],1659:[64338,64339,64340,64341],1662:[64342,64343,64344,64345],1663:[64354,64355,64356,64357],1664:[64346,64347,64348,64349],1667:[64374,64375,64376,64377],1668:[64370,64371,64372,64373],1670:[64378,64379,64380,64381],1671:[64382,64383,64384,64385],1672:[64392,64393],1676:[64388,64389],1677:[64386,64387],1678:[64390,64391],1681:[64396,64397],1688:[64394,64395],1700:[64362,64363,64364,64365],1702:[64366,64367,64368,64369],1705:[64398,64399,64400,64401],1709:[64467,64468,64469,64470],1711:[64402,64403,64404,64405],1713:[64410,64411,64412,64413],1715:[64406,64407,64408,64409],1722:[64414,64415],1723:[64416,64417,64418,64419],1726:[64426,64427,64428,64429],1728:[64420,64421],1729:[64422,64423,64424,64425],1733:[64480,64481],1734:[64473,64474],1735:[64471,64472],1736:[64475,64476],1737:[64482,64483],1739:[64478,64479],1740:[64508,64509,64510,64511],1744:[64484,64485,64486,64487],1746:[64430,64431],1747:[64432,64433]},e={65247:{65154:65269,65156:65271,65160:65273,65166:65275},65248:{65154:65270,65156:65272,65160:65274,65166:65276},65165:{65247:{65248:{65258:65010}}},1617:{1612:64606,1613:64607,1614:64608,1615:64609,1616:64610}},i={1612:64606,1613:64607,1614:64608,1615:64609,1616:64610},o=[1570,1571,1573,1575];n.__arabicParser__={};var a=n.__arabicParser__.isInArabicSubstitutionA=function(O){return t[O.charCodeAt(0)]!==void 0},c=n.__arabicParser__.isArabicLetter=function(O){return typeof O=="string"&&/^[\u0600-\u06FF\u0750-\u077F\u08A0-\u08FF\uFB50-\uFDFF\uFE70-\uFEFF]+$/.test(O)},l=n.__arabicParser__.isArabicEndLetter=function(O){return c(O)&&a(O)&&t[O.charCodeAt(0)].length<=2},h=n.__arabicParser__.isArabicAlfLetter=function(O){return c(O)&&o.indexOf(O.charCodeAt(0))>=0};n.__arabicParser__.arabicLetterHasIsolatedForm=function(O){return c(O)&&a(O)&&t[O.charCodeAt(0)].length>=1};var d=n.__arabicParser__.arabicLetterHasFinalForm=function(O){return c(O)&&a(O)&&t[O.charCodeAt(0)].length>=2};n.__arabicParser__.arabicLetterHasInitialForm=function(O){return c(O)&&a(O)&&t[O.charCodeAt(0)].length>=3};var m=n.__arabicParser__.arabicLetterHasMedialForm=function(O){return c(O)&&a(O)&&t[O.charCodeAt(0)].length==4},_=n.__arabicParser__.resolveLigatures=function(O){var M=0,S=e,V="",G=0;for(M=0;M<O.length;M+=1)S[O.charCodeAt(M)]!==void 0?(G++,typeof(S=S[O.charCodeAt(M)])=="number"&&(V+=String.fromCharCode(S),S=e,G=0),M===O.length-1&&(S=e,V+=O.charAt(M-(G-1)),M-=G-1,G=0)):(S=e,V+=O.charAt(M-G),M-=G,G=0);return V};n.__arabicParser__.isArabicDiacritic=function(O){return O!==void 0&&i[O.charCodeAt(0)]!==void 0};var k=n.__arabicParser__.getCorrectForm=function(O,M,S){return c(O)?a(O)===!1?-1:!d(O)||!c(M)&&!c(S)||!c(S)&&l(M)||l(O)&&!c(M)||l(O)&&h(M)||l(O)&&l(M)?0:m(O)&&c(M)&&!l(M)&&c(S)&&d(S)?3:l(O)||!c(S)?1:2:-1},p=function(O){var M=0,S=0,V=0,G="",q="",it="",vt=(O=O||"").split("\\s+"),dt=[];for(M=0;M<vt.length;M+=1){for(dt.push(""),S=0;S<vt[M].length;S+=1)G=vt[M][S],q=vt[M][S-1],it=vt[M][S+1],c(G)?(V=k(G,q,it),dt[M]+=V!==-1?String.fromCharCode(t[G.charCodeAt(0)][V]):G):dt[M]+=G;dt[M]=_(dt[M])}return dt.join(" ")},j=n.__arabicParser__.processArabic=n.processArabic=function(){var O,M=typeof arguments[0]=="string"?arguments[0]:arguments[0].text,S=[];if(Array.isArray(M)){var V=0;for(S=[],V=0;V<M.length;V+=1)Array.isArray(M[V])?S.push([p(M[V][0]),M[V][1],M[V][2]]):S.push([p(M[V])]);O=S}else O=p(M);return typeof arguments[0]=="string"?O:(arguments[0].text=O,arguments[0])};n.events.push(["preProcessText",j])})(Mt.API),Mt.API.autoPrint=function(n){var t;return(n=n||{}).variant=n.variant||"non-conform",n.variant==="javascript"?this.addJS("print({});"):(this.internal.events.subscribe("postPutResources",function(){t=this.internal.newObject(),this.internal.out("<<"),this.internal.out("/S /Named"),this.internal.out("/Type /Action"),this.internal.out("/N /Print"),this.internal.out(">>"),this.internal.out("endobj")}),this.internal.events.subscribe("putCatalog",function(){this.internal.out("/OpenAction "+t+" 0 R")})),this},(function(n){var t=function(){var e=void 0;Object.defineProperty(this,"pdf",{get:function(){return e},set:function(l){e=l}});var i=150;Object.defineProperty(this,"width",{get:function(){return i},set:function(l){i=isNaN(l)||Number.isInteger(l)===!1||l<0?150:l,this.getContext("2d").pageWrapXEnabled&&(this.getContext("2d").pageWrapX=i+1)}});var o=300;Object.defineProperty(this,"height",{get:function(){return o},set:function(l){o=isNaN(l)||Number.isInteger(l)===!1||l<0?300:l,this.getContext("2d").pageWrapYEnabled&&(this.getContext("2d").pageWrapY=o+1)}});var a=[];Object.defineProperty(this,"childNodes",{get:function(){return a},set:function(l){a=l}});var c={};Object.defineProperty(this,"style",{get:function(){return c},set:function(l){c=l}}),Object.defineProperty(this,"parentNode",{})};t.prototype.getContext=function(e,i){var o;if((e=e||"2d")!=="2d")return null;for(o in i)this.pdf.context2d.hasOwnProperty(o)&&(this.pdf.context2d[o]=i[o]);return this.pdf.context2d._canvas=this,this.pdf.context2d},t.prototype.toDataURL=function(){throw new Error("toDataURL is not implemented.")},n.events.push(["initialized",function(){this.canvas=new t,this.canvas.pdf=this}])})(Mt.API),(function(n){var t={left:0,top:0,bottom:0,right:0},e=!1,i=function(){this.internal.__cell__===void 0&&(this.internal.__cell__={},this.internal.__cell__.padding=3,this.internal.__cell__.headerFunction=void 0,this.internal.__cell__.margins=Object.assign({},t),this.internal.__cell__.margins.width=this.getPageWidth(),o.call(this))},o=function(){this.internal.__cell__.lastCell=new a,this.internal.__cell__.pages=1},a=function(){var h=arguments[0];Object.defineProperty(this,"x",{enumerable:!0,get:function(){return h},set:function(O){h=O}});var d=arguments[1];Object.defineProperty(this,"y",{enumerable:!0,get:function(){return d},set:function(O){d=O}});var m=arguments[2];Object.defineProperty(this,"width",{enumerable:!0,get:function(){return m},set:function(O){m=O}});var _=arguments[3];Object.defineProperty(this,"height",{enumerable:!0,get:function(){return _},set:function(O){_=O}});var k=arguments[4];Object.defineProperty(this,"text",{enumerable:!0,get:function(){return k},set:function(O){k=O}});var p=arguments[5];Object.defineProperty(this,"lineNumber",{enumerable:!0,get:function(){return p},set:function(O){p=O}});var j=arguments[6];return Object.defineProperty(this,"align",{enumerable:!0,get:function(){return j},set:function(O){j=O}}),this};a.prototype.clone=function(){return new a(this.x,this.y,this.width,this.height,this.text,this.lineNumber,this.align)},a.prototype.toArray=function(){return[this.x,this.y,this.width,this.height,this.text,this.lineNumber,this.align]},n.setHeaderFunction=function(h){return i.call(this),this.internal.__cell__.headerFunction=typeof h=="function"?h:void 0,this},n.getTextDimensions=function(h,d){i.call(this);var m=(d=d||{}).fontSize||this.getFontSize(),_=d.font||this.getFont(),k=d.scaleFactor||this.internal.scaleFactor,p=0,j=0,O=0,M=this;if(!Array.isArray(h)&&typeof h!="string"){if(typeof h!="number")throw new Error("getTextDimensions expects text-parameter to be of type String or type Number or an Array of Strings.");h=String(h)}var S=d.maxWidth;S>0?typeof h=="string"?h=this.splitTextToSize(h,S):Object.prototype.toString.call(h)==="[object Array]"&&(h=h.reduce(function(G,q){return G.concat(M.splitTextToSize(q,S))},[])):h=Array.isArray(h)?h:[h];for(var V=0;V<h.length;V++)p<(O=this.getStringUnitWidth(h[V],{font:_})*m)&&(p=O);return p!==0&&(j=h.length),{w:p/=k,h:Math.max((j*m*this.getLineHeightFactor()-m*(this.getLineHeightFactor()-1))/k,0)}},n.cellAddPage=function(){i.call(this),this.addPage();var h=this.internal.__cell__.margins||t;return this.internal.__cell__.lastCell=new a(h.left,h.top,void 0,void 0),this.internal.__cell__.pages+=1,this};var c=n.cell=function(){var h;h=arguments[0]instanceof a?arguments[0]:new a(arguments[0],arguments[1],arguments[2],arguments[3],arguments[4],arguments[5],arguments[6]),i.call(this);var d=this.internal.__cell__.lastCell,m=this.internal.__cell__.padding,_=this.internal.__cell__.margins||t,k=this.internal.__cell__.tableHeaderRow,p=this.internal.__cell__.printHeaders;return d.lineNumber!==void 0&&(d.lineNumber===h.lineNumber?(h.x=(d.x||0)+(d.width||0),h.y=d.y||0):d.y+d.height+h.height+_.bottom>this.getPageHeight()?(this.cellAddPage(),h.y=_.top,p&&k&&(this.printHeaderRow(h.lineNumber,!0),h.y+=k[0].height)):h.y=d.y+d.height||h.y),h.text[0]!==void 0&&(this.rect(h.x,h.y,h.width,h.height,e===!0?"FD":void 0),h.align==="right"?this.text(h.text,h.x+h.width-m,h.y+m,{align:"right",baseline:"top"}):h.align==="center"?this.text(h.text,h.x+h.width/2,h.y+m,{align:"center",baseline:"top",maxWidth:h.width-m-m}):this.text(h.text,h.x+m,h.y+m,{align:"left",baseline:"top",maxWidth:h.width-m-m})),this.internal.__cell__.lastCell=h,this};n.table=function(h,d,m,_,k){if(i.call(this),!m)throw new Error("No data for PDF table.");var p,j,O,M,S=[],V=[],G=[],q={},it={},vt=[],dt=[],X=(k=k||{}).autoSize||!1,R=k.printHeaders!==!1,tt=k.css&&k.css["font-size"]!==void 0?16*k.css["font-size"]:k.fontSize||12,N=k.margins||Object.assign({width:this.getPageWidth()},t),E=typeof k.padding=="number"?k.padding:3,z=k.headerBackgroundColor||"#c8c8c8",U=k.headerTextColor||"#000";if(o.call(this),this.internal.__cell__.printHeaders=R,this.internal.__cell__.margins=N,this.internal.__cell__.table_font_size=tt,this.internal.__cell__.padding=E,this.internal.__cell__.headerBackgroundColor=z,this.internal.__cell__.headerTextColor=U,this.setFontSize(tt),_==null)V=S=Object.keys(m[0]),G=S.map(function(){return"left"});else if(Array.isArray(_)&&xe(_[0])==="object")for(S=_.map(function(At){return At.name}),V=_.map(function(At){return At.prompt||At.name||""}),G=_.map(function(At){return At.align||"left"}),p=0;p<_.length;p+=1)it[_[p].name]=.7499990551181103*_[p].width;else Array.isArray(_)&&typeof _[0]=="string"&&(V=S=_,G=S.map(function(){return"left"}));if(X||Array.isArray(_)&&typeof _[0]=="string")for(p=0;p<S.length;p+=1){for(q[M=S[p]]=m.map(function(At){return At[M]}),this.setFont(void 0,"bold"),vt.push(this.getTextDimensions(V[p],{fontSize:this.internal.__cell__.table_font_size,scaleFactor:this.internal.scaleFactor}).w),j=q[M],this.setFont(void 0,"normal"),O=0;O<j.length;O+=1)vt.push(this.getTextDimensions(j[O],{fontSize:this.internal.__cell__.table_font_size,scaleFactor:this.internal.scaleFactor}).w);it[M]=Math.max.apply(null,vt)+E+E,vt=[]}if(R){var rt={};for(p=0;p<S.length;p+=1)rt[S[p]]={},rt[S[p]].text=V[p],rt[S[p]].align=G[p];var ot=l.call(this,rt,it);dt=S.map(function(At){return new a(h,d,it[At],ot,rt[At].text,void 0,rt[At].align)}),this.setTableHeaderRow(dt),this.printHeaderRow(1,!1)}var ft=_.reduce(function(At,wt){return At[wt.name]=wt.align,At},{});for(p=0;p<m.length;p+=1){"rowStart"in k&&k.rowStart instanceof Function&&k.rowStart({row:p,data:m[p]},this);var nt=l.call(this,m[p],it);for(O=0;O<S.length;O+=1){var ct=m[p][S[O]];"cellStart"in k&&k.cellStart instanceof Function&&k.cellStart({row:p,col:O,data:ct},this),c.call(this,new a(h,d,it[S[O]],nt,ct,p+2,ft[S[O]]))}}return this.internal.__cell__.table_x=h,this.internal.__cell__.table_y=d,this};var l=function(h,d){var m=this.internal.__cell__.padding,_=this.internal.__cell__.table_font_size,k=this.internal.scaleFactor;return Object.keys(h).map(function(p){var j=h[p];return this.splitTextToSize(j.hasOwnProperty("text")?j.text:j,d[p]-m-m)},this).map(function(p){return this.getLineHeightFactor()*p.length*_/k+m+m},this).reduce(function(p,j){return Math.max(p,j)},0)};n.setTableHeaderRow=function(h){i.call(this),this.internal.__cell__.tableHeaderRow=h},n.printHeaderRow=function(h,d){if(i.call(this),!this.internal.__cell__.tableHeaderRow)throw new Error("Property tableHeaderRow does not exist.");var m;if(e=!0,typeof this.internal.__cell__.headerFunction=="function"){var _=this.internal.__cell__.headerFunction(this,this.internal.__cell__.pages);this.internal.__cell__.lastCell=new a(_[0],_[1],_[2],_[3],void 0,-1)}this.setFont(void 0,"bold");for(var k=[],p=0;p<this.internal.__cell__.tableHeaderRow.length;p+=1){m=this.internal.__cell__.tableHeaderRow[p].clone(),d&&(m.y=this.internal.__cell__.margins.top||0,k.push(m)),m.lineNumber=h;var j=this.getTextColor();this.setTextColor(this.internal.__cell__.headerTextColor),this.setFillColor(this.internal.__cell__.headerBackgroundColor),c.call(this,m),this.setTextColor(j)}k.length>0&&this.setTableHeaderRow(k),this.setFont(void 0,"normal"),e=!1}})(Mt.API);var Of={italic:["italic","oblique","normal"],oblique:["oblique","italic","normal"],normal:["normal","oblique","italic"]},jf=["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded"],Jo=Ef(jf),Bf=[100,200,300,400,500,600,700,800,900],U1=Ef(Bf);function jo(n){var t=n.family.replace(/"|'/g,"").toLowerCase(),e=(function(a){return Of[a=a||"normal"]?a:"normal"})(n.style),i=(function(a){return a?typeof a=="number"?a>=100&&a<=900&&a%100==0?a:400:/^\d00$/.test(a)?parseInt(a):a==="bold"?700:400:400})(n.weight),o=(function(a){return typeof Jo[a=a||"normal"]=="number"?a:"normal"})(n.stretch);return{family:t,style:e,weight:i,stretch:o,src:n.src||[],ref:n.ref||{name:t,style:[o,e,i].join(" ")}}}function Fu(n,t,e,i){var o;for(o=e;o>=0&&o<t.length;o+=i)if(n[t[o]])return n[t[o]];for(o=e;o>=0&&o<t.length;o-=i)if(n[t[o]])return n[t[o]]}var z1={"sans-serif":"helvetica",fixed:"courier",monospace:"courier",terminal:"courier",cursive:"times",fantasy:"times",serif:"times"},Eu={caption:"times",icon:"times",menu:"times","message-box":"times","small-caption":"times","status-bar":"times"};function Ou(n){return[n.stretch,n.style,n.weight,n.family].join(" ")}function ju(n){return n.trimLeft()}function H1(n,t){for(var e=0;e<n.length;){if(n.charAt(e)===t)return[n.substring(0,e),n.substring(e+1)];e+=1}return null}function W1(n){var t=n.match(/^(-[a-z_]|[a-z_])[a-z0-9_-]*/i);return t===null?null:[t[0],n.substring(t[0].length)]}var ta,Ss,Bu,Mu,Ru,Bo=["times"];function Tu(n,t,e,i,o){var a=4,c=qu;switch(o){case Mt.API.image_compression.FAST:a=1,c=Du;break;case Mt.API.image_compression.MEDIUM:a=6,c=Uu;break;case Mt.API.image_compression.SLOW:a=9,c=zu}n=(function(h,d,m,_){for(var k,p=h.length/d,j=new Uint8Array(h.length+p),O=[V1,Du,qu,Uu,zu],M=0;M<p;M+=1){var S=M*d,V=h.subarray(S,S+d);if(_)j.set(_(V,m,k),S+M);else{for(var G=O.length,q=[],it=0;it<G;it+=1)q[it]=O[it](V,m,k);var vt=Y1(q.concat());j.set(q[vt],S+M)}k=V}return j})(n,t,Math.ceil(e*i/8),c);var l=Uo(n,{level:a});return Mt.API.__addimage__.arrayBufferToBinaryString(l)}function V1(n){var t=Array.apply([],n);return t.unshift(0),t}function Du(n,t){var e=n.length,i=[];i[0]=1;for(var o=0;o<e;o+=1){var a=n[o-t]||0;i[o+1]=n[o]-a+256&255}return i}function qu(n,t,e){var i=n.length,o=[];o[0]=2;for(var a=0;a<i;a+=1){var c=e&&e[a]||0;o[a+1]=n[a]-c+256&255}return o}function Uu(n,t,e){var i=n.length,o=[];o[0]=3;for(var a=0;a<i;a+=1){var c=n[a-t]||0,l=e&&e[a]||0;o[a+1]=n[a]+256-(c+l>>>1)&255}return o}function zu(n,t,e){var i=n.length,o=[];o[0]=4;for(var a=0;a<i;a+=1){var c=G1(n[a-t]||0,e&&e[a]||0,e&&e[a-t]||0);o[a+1]=n[a]-c+256&255}return o}function G1(n,t,e){if(n===t&&t===e)return n;var i=Math.abs(t-e),o=Math.abs(n-e),a=Math.abs(n+t-e-e);return i<=o&&i<=a?n:o<=a?t:e}function Y1(n){var t=n.map(function(e){return e.reduce(function(i,o){return i+Math.abs(o)},0)});return t.indexOf(Math.min.apply(null,t))}function Mo(n,t,e){var i=t*e,o=Math.floor(i/8),a=16-(i-8*o+e),c=(1<<e)-1;return Mf(n,o)>>a&c}function Hu(n,t,e,i){var o=e*i,a=Math.floor(o/8),c=16-(o-8*a+i),l=(1<<i)-1,h=(t&l)<<c;(function(d,m,_){if(m+1<d.byteLength)d.setUint16(m,_,!1);else{var k=_>>8&255;d.setUint8(m,k)}})(n,a,Mf(n,a)&~(l<<c)&65535|h)}function Mf(n,t){return t+1<n.byteLength?n.getUint16(t,!1):n.getUint8(t)<<8}function J1(n){var t=0;if(n[t++]!==71||n[t++]!==73||n[t++]!==70||n[t++]!==56||(n[t++]+1&253)!=56||n[t++]!==97)throw new Error("Invalid GIF 87a/89a header.");var e=n[t++]|n[t++]<<8,i=n[t++]|n[t++]<<8,o=n[t++],a=o>>7,c=1<<1+(7&o);n[t++],n[t++];var l=null,h=null;a&&(l=t,h=c,t+=3*c);var d=!0,m=[],_=0,k=null,p=0,j=null;for(this.width=e,this.height=i;d&&t<n.length;)switch(n[t++]){case 33:switch(n[t++]){case 255:if(n[t]!==11||n[t+1]==78&&n[t+2]==69&&n[t+3]==84&&n[t+4]==83&&n[t+5]==67&&n[t+6]==65&&n[t+7]==80&&n[t+8]==69&&n[t+9]==50&&n[t+10]==46&&n[t+11]==48&&n[t+12]==3&&n[t+13]==1&&n[t+16]==0)t+=14,j=n[t++]|n[t++]<<8,t++;else for(t+=12;;){if(!((N=n[t++])>=0))throw Error("Invalid block size");if(N===0)break;t+=N}break;case 249:if(n[t++]!==4||n[t+4]!==0)throw new Error("Invalid graphics extension block.");var O=n[t++];_=n[t++]|n[t++]<<8,k=n[t++],1&O||(k=null),p=O>>2&7,t++;break;case 254:for(;;){if(!((N=n[t++])>=0))throw Error("Invalid block size");if(N===0)break;t+=N}break;default:throw new Error("Unknown graphic control label: 0x"+n[t-1].toString(16))}break;case 44:var M=n[t++]|n[t++]<<8,S=n[t++]|n[t++]<<8,V=n[t++]|n[t++]<<8,G=n[t++]|n[t++]<<8,q=n[t++],it=q>>6&1,vt=1<<1+(7&q),dt=l,X=h,R=!1;q>>7&&(R=!0,dt=t,X=vt,t+=3*vt);var tt=t;for(t++;;){var N;if(!((N=n[t++])>=0))throw Error("Invalid block size");if(N===0)break;t+=N}m.push({x:M,y:S,width:V,height:G,has_local_palette:R,palette_offset:dt,palette_size:X,data_offset:tt,data_length:t-tt,transparent_index:k,interlaced:!!it,delay:_,disposal:p});break;case 59:d=!1;break;default:throw new Error("Unknown gif block: 0x"+n[t-1].toString(16))}this.numFrames=function(){return m.length},this.loopCount=function(){return j},this.frameInfo=function(E){if(E<0||E>=m.length)throw new Error("Frame index out of range.");return m[E]},this.decodeAndBlitFrameBGRA=function(E,z){var U=this.frameInfo(E),rt=U.width*U.height;if(rt>536870912)throw new Error("Image dimensions exceed 512MB, which is too large.");var ot=new Uint8Array(rt);Wu(n,U.data_offset,ot,rt);var ft=U.palette_offset,nt=U.transparent_index;nt===null&&(nt=256);var ct=U.width,At=e-ct,wt=ct,x=4*(U.y*e+U.x),B=4*((U.y+U.height)*e+U.x),T=x,H=4*At;U.interlaced===!0&&(H+=4*e*7);for(var J=8,Z=0,at=ot.length;Z<at;++Z){var st=ot[Z];if(wt===0&&(wt=ct,(T+=H)>=B&&(H=4*At+4*e*(J-1),T=x+(ct+At)*(J<<1),J>>=1)),st===nt)T+=4;else{var gt=n[ft+3*st],_t=n[ft+3*st+1],kt=n[ft+3*st+2];z[T++]=kt,z[T++]=_t,z[T++]=gt,z[T++]=255}--wt}},this.decodeAndBlitFrameRGBA=function(E,z){var U=this.frameInfo(E),rt=U.width*U.height;if(rt>536870912)throw new Error("Image dimensions exceed 512MB, which is too large.");var ot=new Uint8Array(rt);Wu(n,U.data_offset,ot,rt);var ft=U.palette_offset,nt=U.transparent_index;nt===null&&(nt=256);var ct=U.width,At=e-ct,wt=ct,x=4*(U.y*e+U.x),B=4*((U.y+U.height)*e+U.x),T=x,H=4*At;U.interlaced===!0&&(H+=4*e*7);for(var J=8,Z=0,at=ot.length;Z<at;++Z){var st=ot[Z];if(wt===0&&(wt=ct,(T+=H)>=B&&(H=4*At+4*e*(J-1),T=x+(ct+At)*(J<<1),J>>=1)),st===nt)T+=4;else{var gt=n[ft+3*st],_t=n[ft+3*st+1],kt=n[ft+3*st+2];z[T++]=gt,z[T++]=_t,z[T++]=kt,z[T++]=255}--wt}}}function Wu(n,t,e,i){for(var o=n[t++],a=1<<o,c=a+1,l=c+1,h=o+1,d=(1<<h)-1,m=0,_=0,k=0,p=n[t++],j=new Int32Array(4096),O=null;;){for(;m<16&&p!==0;)_|=n[t++]<<m,m+=8,p===1?p=n[t++]:--p;if(m<h)break;var M=_&d;if(_>>=h,m-=h,M!==a){if(M===c)break;for(var S=M<l?M:O,V=0,G=S;G>a;)G=j[G]>>8,++V;var q=G;if(k+V+(S!==M?1:0)>i)return void Le.log("Warning, gif stream longer than expected.");e[k++]=q;var it=k+=V;for(S!==M&&(e[k++]=q),G=S;V--;)G=j[G],e[--it]=255&G,G>>=8;O!==null&&l<4096&&(j[l++]=O<<8|q,l>=d+1&&h<12&&(++h,d=d<<1|1)),O=M}else l=c+1,d=(1<<(h=o+1))-1,O=null}return k!==i&&Le.log("Warning, gif stream shorter than expected."),e}function Ro(n){var t,e,i,o,a,c=Math.floor,l=new Array(64),h=new Array(64),d=new Array(64),m=new Array(64),_=new Array(65535),k=new Array(65535),p=new Array(64),j=new Array(64),O=[],M=0,S=7,V=new Array(64),G=new Array(64),q=new Array(64),it=new Array(256),vt=new Array(2048),dt=[0,1,5,6,14,15,27,28,2,4,7,13,16,26,29,42,3,8,12,17,25,30,41,43,9,11,18,24,31,40,44,53,10,19,23,32,39,45,52,54,20,22,33,38,46,51,55,60,21,34,37,47,50,56,59,61,35,36,48,49,57,58,62,63],X=[0,0,1,5,1,1,1,1,1,1,0,0,0,0,0,0,0],R=[0,1,2,3,4,5,6,7,8,9,10,11],tt=[0,0,2,1,3,3,2,4,3,5,5,4,4,0,0,1,125],N=[1,2,3,0,4,17,5,18,33,49,65,6,19,81,97,7,34,113,20,50,129,145,161,8,35,66,177,193,21,82,209,240,36,51,98,114,130,9,10,22,23,24,25,26,37,38,39,40,41,42,52,53,54,55,56,57,58,67,68,69,70,71,72,73,74,83,84,85,86,87,88,89,90,99,100,101,102,103,104,105,106,115,116,117,118,119,120,121,122,131,132,133,134,135,136,137,138,146,147,148,149,150,151,152,153,154,162,163,164,165,166,167,168,169,170,178,179,180,181,182,183,184,185,186,194,195,196,197,198,199,200,201,202,210,211,212,213,214,215,216,217,218,225,226,227,228,229,230,231,232,233,234,241,242,243,244,245,246,247,248,249,250],E=[0,0,3,1,1,1,1,1,1,1,1,1,0,0,0,0,0],z=[0,1,2,3,4,5,6,7,8,9,10,11],U=[0,0,2,1,2,4,4,3,4,7,5,4,4,0,1,2,119],rt=[0,1,2,3,17,4,5,33,49,6,18,65,81,7,97,113,19,34,50,129,8,20,66,145,161,177,193,9,35,51,82,240,21,98,114,209,10,22,36,52,225,37,241,23,24,25,26,38,39,40,41,42,53,54,55,56,57,58,67,68,69,70,71,72,73,74,83,84,85,86,87,88,89,90,99,100,101,102,103,104,105,106,115,116,117,118,119,120,121,122,130,131,132,133,134,135,136,137,138,146,147,148,149,150,151,152,153,154,162,163,164,165,166,167,168,169,170,178,179,180,181,182,183,184,185,186,194,195,196,197,198,199,200,201,202,210,211,212,213,214,215,216,217,218,226,227,228,229,230,231,232,233,234,242,243,244,245,246,247,248,249,250];function ot(x,B){for(var T=0,H=0,J=new Array,Z=1;Z<=16;Z++){for(var at=1;at<=x[Z];at++)J[B[H]]=[],J[B[H]][0]=T,J[B[H]][1]=Z,H++,T++;T*=2}return J}function ft(x){for(var B=x[0],T=x[1]-1;T>=0;)B&1<<T&&(M|=1<<S),T--,--S<0&&(M==255?(nt(255),nt(0)):nt(M),S=7,M=0)}function nt(x){O.push(x)}function ct(x){nt(x>>8&255),nt(255&x)}function At(x,B,T,H,J){for(var Z,at=J[0],st=J[240],gt=(function(yt,Wt){var Ct,zt,qt,ve,ue,Zt,he,fe,Bt,ne,Tt=0;for(Bt=0;Bt<8;++Bt){Ct=yt[Tt],zt=yt[Tt+1],qt=yt[Tt+2],ve=yt[Tt+3],ue=yt[Tt+4],Zt=yt[Tt+5],he=yt[Tt+6];var ze=Ct+(fe=yt[Tt+7]),ge=Ct-fe,se=zt+he,oe=zt-he,Oe=qt+Zt,Ut=qt-Zt,Se=ve+ue,Yt=ve-ue,Qt=ze+Se,je=ze-Se,le=se+Oe,Vt=se-Oe;yt[Tt]=Qt+le,yt[Tt+4]=Qt-le;var be=.707106781*(Vt+je);yt[Tt+2]=je+be,yt[Tt+6]=je-be;var ti=.382683433*((Qt=Yt+Ut)-(Vt=oe+ge)),fn=.5411961*Qt+ti,mr=1.306562965*Vt+ti,nr=.707106781*(le=Ut+oe),Gt=ge+nr,vr=ge-nr;yt[Tt+5]=vr+fn,yt[Tt+3]=vr-fn,yt[Tt+1]=Gt+mr,yt[Tt+7]=Gt-mr,Tt+=8}for(Tt=0,Bt=0;Bt<8;++Bt){Ct=yt[Tt],zt=yt[Tt+8],qt=yt[Tt+16],ve=yt[Tt+24],ue=yt[Tt+32],Zt=yt[Tt+40],he=yt[Tt+48];var br=Ct+(fe=yt[Tt+56]),Rn=Ct-fe,Tn=zt+he,Te=zt-he,rn=qt+Zt,an=qt-Zt,ei=ve+ue,Or=ve-ue,Vn=br+ei,rr=br-ei,Gn=Tn+rn,Yn=Tn-rn;yt[Tt]=Vn+Gn,yt[Tt+32]=Vn-Gn;var Dn=.707106781*(Yn+rr);yt[Tt+16]=rr+Dn,yt[Tt+48]=rr-Dn;var ni=.382683433*((Vn=Or+an)-(Yn=Te+Rn)),ir=.5411961*Vn+ni,ri=1.306562965*Yn+ni,Ci=.707106781*(Gn=an+Te),Fi=Rn+Ci,Ei=Rn-Ci;yt[Tt+40]=Ei+ir,yt[Tt+24]=Ei-ir,yt[Tt+8]=Fi+ri,yt[Tt+56]=Fi-ri,Tt++}for(Bt=0;Bt<64;++Bt)ne=yt[Bt]*Wt[Bt],p[Bt]=ne>0?ne+.5|0:ne-.5|0;return p})(x,B),_t=0;_t<64;++_t)j[dt[_t]]=gt[_t];var kt=j[0]-T;T=j[0],kt==0?ft(H[0]):(ft(H[k[Z=32767+kt]]),ft(_[Z]));for(var St=63;St>0&&j[St]==0;)St--;if(St==0)return ft(at),T;for(var Dt,P=1;P<=St;){for(var Lt=P;j[P]==0&&P<=St;)++P;var ae=P-Lt;if(ae>=16){Dt=ae>>4;for(var Ht=1;Ht<=Dt;++Ht)ft(st);ae&=15}Z=32767+j[P],ft(J[(ae<<4)+k[Z]]),ft(_[Z]),P++}return St!=63&&ft(at),T}function wt(x){x=Math.min(Math.max(x,1),100),a!=x&&((function(B){for(var T=[16,11,10,16,24,40,51,61,12,12,14,19,26,58,60,55,14,13,16,24,40,57,69,56,14,17,22,29,51,87,80,62,18,22,37,56,68,109,103,77,24,35,55,64,81,104,113,92,49,64,78,87,103,121,120,101,72,92,95,98,112,100,103,99],H=0;H<64;H++){var J=c((T[H]*B+50)/100);J=Math.min(Math.max(J,1),255),l[dt[H]]=J}for(var Z=[17,18,24,47,99,99,99,99,18,21,26,66,99,99,99,99,24,26,56,99,99,99,99,99,47,66,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99,99],at=0;at<64;at++){var st=c((Z[at]*B+50)/100);st=Math.min(Math.max(st,1),255),h[dt[at]]=st}for(var gt=[1,1.387039845,1.306562965,1.175875602,1,.785694958,.5411961,.275899379],_t=0,kt=0;kt<8;kt++)for(var St=0;St<8;St++)d[_t]=1/(l[dt[_t]]*gt[kt]*gt[St]*8),m[_t]=1/(h[dt[_t]]*gt[kt]*gt[St]*8),_t++})(x<50?Math.floor(5e3/x):Math.floor(200-2*x)),a=x)}this.encode=function(x,B){B&&wt(B),O=new Array,M=0,S=7,ct(65496),ct(65504),ct(16),nt(74),nt(70),nt(73),nt(70),nt(0),nt(1),nt(1),nt(0),ct(1),ct(1),nt(0),nt(0),(function(){ct(65499),ct(132),nt(0);for(var zt=0;zt<64;zt++)nt(l[zt]);nt(1);for(var qt=0;qt<64;qt++)nt(h[qt])})(),(function(zt,qt){ct(65472),ct(17),nt(8),ct(qt),ct(zt),nt(3),nt(1),nt(17),nt(0),nt(2),nt(17),nt(1),nt(3),nt(17),nt(1)})(x.width,x.height),(function(){ct(65476),ct(418),nt(0);for(var zt=0;zt<16;zt++)nt(X[zt+1]);for(var qt=0;qt<=11;qt++)nt(R[qt]);nt(16);for(var ve=0;ve<16;ve++)nt(tt[ve+1]);for(var ue=0;ue<=161;ue++)nt(N[ue]);nt(1);for(var Zt=0;Zt<16;Zt++)nt(E[Zt+1]);for(var he=0;he<=11;he++)nt(z[he]);nt(17);for(var fe=0;fe<16;fe++)nt(U[fe+1]);for(var Bt=0;Bt<=161;Bt++)nt(rt[Bt])})(),ct(65498),ct(12),nt(3),nt(1),nt(0),nt(2),nt(17),nt(3),nt(17),nt(0),nt(63),nt(0);var T=0,H=0,J=0;M=0,S=7,this.encode.displayName="_encode_";for(var Z,at,st,gt,_t,kt,St,Dt,P,Lt=x.data,ae=x.width,Ht=x.height,yt=4*ae,Wt=0;Wt<Ht;){for(Z=0;Z<yt;){for(_t=yt*Wt+Z,St=-1,Dt=0,P=0;P<64;P++)kt=_t+(Dt=P>>3)*yt+(St=4*(7&P)),Wt+Dt>=Ht&&(kt-=yt*(Wt+1+Dt-Ht)),Z+St>=yt&&(kt-=Z+St-yt+4),at=Lt[kt++],st=Lt[kt++],gt=Lt[kt++],V[P]=(vt[at]+vt[st+256|0]+vt[gt+512|0]>>16)-128,G[P]=(vt[at+768|0]+vt[st+1024|0]+vt[gt+1280|0]>>16)-128,q[P]=(vt[at+1280|0]+vt[st+1536|0]+vt[gt+1792|0]>>16)-128;T=At(V,d,T,t,i),H=At(G,m,H,e,o),J=At(q,m,J,e,o),Z+=32}Wt+=8}if(S>=0){var Ct=[];Ct[1]=S+1,Ct[0]=(1<<S+1)-1,ft(Ct)}return ct(65497),new Uint8Array(O)},n=n||50,(function(){for(var x=String.fromCharCode,B=0;B<256;B++)it[B]=x(B)})(),t=ot(X,R),e=ot(E,z),i=ot(tt,N),o=ot(U,rt),(function(){for(var x=1,B=2,T=1;T<=15;T++){for(var H=x;H<B;H++)k[32767+H]=T,_[32767+H]=[],_[32767+H][1]=T,_[32767+H][0]=H;for(var J=-(B-1);J<=-x;J++)k[32767+J]=T,_[32767+J]=[],_[32767+J][1]=T,_[32767+J][0]=B-1+J;x<<=1,B<<=1}})(),(function(){for(var x=0;x<256;x++)vt[x]=19595*x,vt[x+256|0]=38470*x,vt[x+512|0]=7471*x+32768,vt[x+768|0]=-11059*x,vt[x+1024|0]=-21709*x,vt[x+1280|0]=32768*x+8421375,vt[x+1536|0]=-27439*x,vt[x+1792|0]=-5329*x})(),wt(n)}function Zn(n,t){if(this.pos=0,this.buffer=n,this.datav=new DataView(n.buffer),this.is_with_alpha=!!t,this.bottom_up=!0,this.flag=String.fromCharCode(this.buffer[0])+String.fromCharCode(this.buffer[1]),this.pos+=2,["BM","BA","CI","CP","IC","PT"].indexOf(this.flag)===-1)throw new Error("Invalid BMP File");this.parseHeader(),this.parseBGR()}function Vu(n){function t(R){if(!R)throw Error("assert :P")}function e(R,tt,N){for(var E=0;4>E;E++)if(R[tt+E]!=N.charCodeAt(E))return!0;return!1}function i(R,tt,N,E,z){for(var U=0;U<z;U++)R[tt+U]=N[E+U]}function o(R,tt,N,E){for(var z=0;z<E;z++)R[tt+z]=N}function a(R){return new Int32Array(R)}function c(R,tt){for(var N=[],E=0;E<R;E++)N.push(new tt);return N}function l(R,tt){var N=[];return(function E(z,U,rt){for(var ot=rt[U],ft=0;ft<ot&&(z.push(rt.length>U+1?[]:new tt),!(rt.length<U+1));ft++)E(z[ft],U+1,rt)})(N,0,R),N}var h=function(){var R=this;function tt(r,s){for(var f=1<<s-1>>>0;r&f;)f>>>=1;return f?(r&f-1)+f:r}function N(r,s,f,g,b){t(!(g%f));do r[s+(g-=f)]=b;while(0<g)}function E(r,s,f,g,b){if(t(2328>=b),512>=b)var w=a(512);else if((w=a(b))==null)return 0;return(function(y,A,L,C,W,et){var F,Y,$=A,ut=1<<L,Q=a(16),ht=a(16);for(t(W!=0),t(C!=null),t(y!=null),t(0<L),Y=0;Y<W;++Y){if(15<C[Y])return 0;++Q[C[Y]]}if(Q[0]==W)return 0;for(ht[1]=0,F=1;15>F;++F){if(Q[F]>1<<F)return 0;ht[F+1]=ht[F]+Q[F]}for(Y=0;Y<W;++Y)F=C[Y],0<C[Y]&&(et[ht[F]++]=Y);if(ht[15]==1)return(C=new z).g=0,C.value=et[0],N(y,$,1,ut,C),ut;var pt,xt=-1,bt=ut-1,Rt=0,Pt=1,re=1,Ot=1<<L;for(Y=0,F=1,W=2;F<=L;++F,W<<=1){if(Pt+=re<<=1,0>(re-=Q[F]))return 0;for(;0<Q[F];--Q[F])(C=new z).g=F,C.value=et[Y++],N(y,$+Rt,W,Ot,C),Rt=tt(Rt,F)}for(F=L+1,W=2;15>=F;++F,W<<=1){if(Pt+=re<<=1,0>(re-=Q[F]))return 0;for(;0<Q[F];--Q[F]){if(C=new z,(Rt&bt)!=xt){for($+=Ot,pt=1<<(xt=F)-L;15>xt&&!(0>=(pt-=Q[xt]));)++xt,pt<<=1;ut+=Ot=1<<(pt=xt-L),y[A+(xt=Rt&bt)].g=pt+L,y[A+xt].value=$-A-xt}C.g=F-L,C.value=et[Y++],N(y,$+(Rt>>L),W,Ot,C),Rt=tt(Rt,F)}}return Pt!=2*ht[15]-1?0:ut})(r,s,f,g,b,w)}function z(){this.value=this.g=0}function U(){this.value=this.g=0}function rt(){this.G=c(5,z),this.H=a(5),this.jc=this.Qb=this.qb=this.nd=0,this.pd=c(Vi,U)}function ot(r,s,f,g){t(r!=null),t(s!=null),t(2147483648>g),r.Ca=254,r.I=0,r.b=-8,r.Ka=0,r.oa=s,r.pa=f,r.Jd=s,r.Yc=f+g,r.Zc=4<=g?f+g-4+1:f,at(r)}function ft(r,s){for(var f=0;0<s--;)f|=gt(r,128)<<s;return f}function nt(r,s){var f=ft(r,s);return st(r)?-f:f}function ct(r,s,f,g){var b,w=0;for(t(r!=null),t(s!=null),t(4294967288>g),r.Sb=g,r.Ra=0,r.u=0,r.h=0,4<g&&(g=4),b=0;b<g;++b)w+=s[f+b]<<8*b;r.Ra=w,r.bb=g,r.oa=s,r.pa=f}function At(r){for(;8<=r.u&&r.bb<r.Sb;)r.Ra>>>=8,r.Ra+=r.oa[r.pa+r.bb]<<yn-8>>>0,++r.bb,r.u-=8;H(r)&&(r.h=1,r.u=0)}function wt(r,s){if(t(0<=s),!r.h&&s<=va){var f=T(r)&di[s];return r.u+=s,At(r),f}return r.h=1,r.u=0}function x(){this.b=this.Ca=this.I=0,this.oa=[],this.pa=0,this.Jd=[],this.Yc=0,this.Zc=[],this.Ka=0}function B(){this.Ra=0,this.oa=[],this.h=this.u=this.bb=this.Sb=this.pa=0}function T(r){return r.Ra>>>(r.u&yn-1)>>>0}function H(r){return t(r.bb<=r.Sb),r.h||r.bb==r.Sb&&r.u>yn}function J(r,s){r.u=s,r.h=H(r)}function Z(r){r.u>=Nn&&(t(r.u>=Nn),At(r))}function at(r){t(r!=null&&r.oa!=null),r.pa<r.Zc?(r.I=(r.oa[r.pa++]|r.I<<8)>>>0,r.b+=8):(t(r!=null&&r.oa!=null),r.pa<r.Yc?(r.b+=8,r.I=r.oa[r.pa++]|r.I<<8):r.Ka?r.b=0:(r.I<<=8,r.b+=8,r.Ka=1))}function st(r){return ft(r,1)}function gt(r,s){var f=r.Ca;0>r.b&&at(r);var g=r.b,b=f*s>>>8,w=(r.I>>>g>b)+0;for(w?(f-=b,r.I-=b+1<<g>>>0):f=b+1,g=f,b=0;256<=g;)b+=8,g>>=8;return g=7^b+Gi[g],r.b-=g,r.Ca=(f<<g)-1,w}function _t(r,s,f){r[s+0]=f>>24&255,r[s+1]=f>>16&255,r[s+2]=f>>8&255,r[s+3]=255&f}function kt(r,s){return r[s+0]|r[s+1]<<8}function St(r,s){return kt(r,s)|r[s+2]<<16}function Dt(r,s){return kt(r,s)|kt(r,s+2)<<16}function P(r,s){var f=1<<s;return t(r!=null),t(0<s),r.X=a(f),r.X==null?0:(r.Mb=32-s,r.Xa=s,1)}function Lt(r,s){t(r!=null),t(s!=null),t(r.Xa==s.Xa),i(s.X,0,r.X,0,1<<s.Xa)}function ae(){this.X=[],this.Xa=this.Mb=0}function Ht(r,s,f,g){t(f!=null),t(g!=null);var b=f[0],w=g[0];return b==0&&(b=(r*w+s/2)/s),w==0&&(w=(s*b+r/2)/r),0>=b||0>=w?0:(f[0]=b,g[0]=w,1)}function yt(r,s){return r+(1<<s)-1>>>s}function Wt(r,s){return((4278255360&r)+(4278255360&s)>>>0&4278255360)+((16711935&r)+(16711935&s)>>>0&16711935)>>>0}function Ct(r,s){R[s]=function(f,g,b,w,y,A,L){var C;for(C=0;C<y;++C){var W=R[r](A[L+C-1],b,w+C);A[L+C]=Wt(f[g+C],W)}}}function zt(){this.ud=this.hd=this.jd=0}function qt(r,s){return((4278124286&(r^s))>>>1)+(r&s)>>>0}function ve(r){return 0<=r&&256>r?r:0>r?0:255<r?255:void 0}function ue(r,s){return ve(r+(r-s+.5>>1))}function Zt(r,s,f){return Math.abs(s-f)-Math.abs(r-f)}function he(r,s,f,g,b,w,y){for(g=w[y-1],f=0;f<b;++f)w[y+f]=g=Wt(r[s+f],g)}function fe(r,s,f,g,b){var w;for(w=0;w<f;++w){var y=r[s+w],A=y>>8&255,L=16711935&(L=(L=16711935&y)+((A<<16)+A));g[b+w]=(4278255360&y)+L>>>0}}function Bt(r,s){s.jd=255&r,s.hd=r>>8&255,s.ud=r>>16&255}function ne(r,s,f,g,b,w){var y;for(y=0;y<g;++y){var A=s[f+y],L=A>>>8,C=A,W=255&(W=(W=A>>>16)+((r.jd<<24>>24)*(L<<24>>24)>>>5));C=255&(C=(C+=(r.hd<<24>>24)*(L<<24>>24)>>>5)+((r.ud<<24>>24)*(W<<24>>24)>>>5)),b[w+y]=(4278255360&A)+(W<<16)+C}}function Tt(r,s,f,g,b){R[s]=function(w,y,A,L,C,W,et,F,Y){for(L=et;L<F;++L)for(et=0;et<Y;++et)C[W++]=b(A[g(w[y++])])},R[r]=function(w,y,A,L,C,W,et){var F=8>>w.b,Y=w.Ea,$=w.K[0],ut=w.w;if(8>F)for(w=(1<<w.b)-1,ut=(1<<F)-1;y<A;++y){var Q,ht=0;for(Q=0;Q<Y;++Q)Q&w||(ht=g(L[C++])),W[et++]=b($[ht&ut]),ht>>=F}else R["VP8LMapColor"+f](L,C,$,ut,W,et,y,A,Y)}}function ze(r,s,f,g,b){for(f=s+f;s<f;){var w=r[s++];g[b++]=w>>16&255,g[b++]=w>>8&255,g[b++]=255&w}}function ge(r,s,f,g,b){for(f=s+f;s<f;){var w=r[s++];g[b++]=w>>16&255,g[b++]=w>>8&255,g[b++]=255&w,g[b++]=w>>24&255}}function se(r,s,f,g,b){for(f=s+f;s<f;){var w=(y=r[s++])>>16&240|y>>12&15,y=240&y|y>>28&15;g[b++]=w,g[b++]=y}}function oe(r,s,f,g,b){for(f=s+f;s<f;){var w=(y=r[s++])>>16&248|y>>13&7,y=y>>5&224|y>>3&31;g[b++]=w,g[b++]=y}}function Oe(r,s,f,g,b){for(f=s+f;s<f;){var w=r[s++];g[b++]=255&w,g[b++]=w>>8&255,g[b++]=w>>16&255}}function Ut(r,s,f,g,b,w){if(w==0)for(f=s+f;s<f;)_t(g,((w=r[s++])[0]>>24|w[1]>>8&65280|w[2]<<8&16711680|w[3]<<24)>>>0),b+=32;else i(g,b,r,s,f)}function Se(r,s){R[s][0]=R[r+"0"],R[s][1]=R[r+"1"],R[s][2]=R[r+"2"],R[s][3]=R[r+"3"],R[s][4]=R[r+"4"],R[s][5]=R[r+"5"],R[s][6]=R[r+"6"],R[s][7]=R[r+"7"],R[s][8]=R[r+"8"],R[s][9]=R[r+"9"],R[s][10]=R[r+"10"],R[s][11]=R[r+"11"],R[s][12]=R[r+"12"],R[s][13]=R[r+"13"],R[s][14]=R[r+"0"],R[s][15]=R[r+"0"]}function Yt(r){return r==eo||r==no||r==ls||r==ro}function Qt(){this.eb=[],this.size=this.A=this.fb=0}function je(){this.y=[],this.f=[],this.ea=[],this.F=[],this.Tc=this.Ed=this.Cd=this.Fd=this.lb=this.Db=this.Ab=this.fa=this.J=this.W=this.N=this.O=0}function le(){this.Rd=this.height=this.width=this.S=0,this.f={},this.f.RGBA=new Qt,this.f.kb=new je,this.sd=null}function Vt(){this.width=[0],this.height=[0],this.Pd=[0],this.Qd=[0],this.format=[0]}function be(){this.Id=this.fd=this.Md=this.hb=this.ib=this.da=this.bd=this.cd=this.j=this.v=this.Da=this.Sd=this.ob=0}function ti(r){return alert("todo:WebPSamplerProcessPlane"),r.T}function fn(r,s){var f=r.T,g=s.ba.f.RGBA,b=g.eb,w=g.fb+r.ka*g.A,y=Hn[s.ba.S],A=r.y,L=r.O,C=r.f,W=r.N,et=r.ea,F=r.W,Y=s.cc,$=s.dc,ut=s.Mc,Q=s.Nc,ht=r.ka,pt=r.ka+r.T,xt=r.U,bt=xt+1>>1;for(ht==0?y(A,L,null,null,C,W,et,F,C,W,et,F,b,w,null,null,xt):(y(s.ec,s.fc,A,L,Y,$,ut,Q,C,W,et,F,b,w-g.A,b,w,xt),++f);ht+2<pt;ht+=2)Y=C,$=W,ut=et,Q=F,W+=r.Rc,F+=r.Rc,w+=2*g.A,y(A,(L+=2*r.fa)-r.fa,A,L,Y,$,ut,Q,C,W,et,F,b,w-g.A,b,w,xt);return L+=r.fa,r.j+pt<r.o?(i(s.ec,s.fc,A,L,xt),i(s.cc,s.dc,C,W,bt),i(s.Mc,s.Nc,et,F,bt),f--):1&pt||y(A,L,null,null,C,W,et,F,C,W,et,F,b,w+g.A,null,null,xt),f}function mr(r,s,f){var g=r.F,b=[r.J];if(g!=null){var w=r.U,y=s.ba.S,A=y==os||y==ls;s=s.ba.f.RGBA;var L=[0],C=r.ka;L[0]=r.T,r.Kb&&(C==0?--L[0]:(--C,b[0]-=r.width),r.j+r.ka+r.T==r.o&&(L[0]=r.o-r.j-C));var W=s.eb;C=s.fb+C*s.A,r=al(g,b[0],r.width,w,L,W,C+(A?0:3),s.A),t(f==L),r&&Yt(y)&&xa(W,C,A,w,L,s.A)}return 0}function nr(r){var s=r.ma,f=s.ba.S,g=11>f,b=f==as||f==ss||f==os||f==to||f==12||Yt(f);if(s.memory=null,s.Ib=null,s.Jb=null,s.Nd=null,!Un(s.Oa,r,b?11:12))return 0;if(b&&Yt(f)&&Nr(),r.da)alert("todo:use_scaling");else{if(g){if(s.Ib=ti,r.Kb){if(f=r.U+1>>1,s.memory=a(r.U+2*f),s.memory==null)return 0;s.ec=s.memory,s.fc=0,s.cc=s.ec,s.dc=s.fc+r.U,s.Mc=s.cc,s.Nc=s.dc+f,s.Ib=fn,Nr()}}else alert("todo:EmitYUV");b&&(s.Jb=mr,g&&Re())}if(g&&!xl){for(r=0;256>r;++r)rh[r]=89858*(r-128)+fs>>us,sh[r]=-22014*(r-128)+fs,ah[r]=-45773*(r-128),ih[r]=113618*(r-128)+fs>>us;for(r=Aa;r<so;++r)s=76283*(r-16)+fs>>us,oh[r-Aa]=ar(s,255),lh[r-Aa]=ar(s+8>>4,15);xl=1}return 1}function Gt(r){var s=r.ma,f=r.U,g=r.T;return t(!(1&r.ka)),0>=f||0>=g?0:(f=s.Ib(r,s),s.Jb!=null&&s.Jb(r,s,f),s.Dc+=f,1)}function vr(r){r.ma.memory=null}function br(r,s,f,g){return wt(r,8)!=47?0:(s[0]=wt(r,14)+1,f[0]=wt(r,14)+1,g[0]=wt(r,1),wt(r,3)!=0?0:!r.h)}function Rn(r,s){if(4>r)return r+1;var f=r-2>>1;return(2+(1&r)<<f)+wt(s,f)+1}function Tn(r,s){return 120<s?s-120:1<=(f=((f=Hf[s-1])>>4)*r+(8-(15&f)))?f:1;var f}function Te(r,s,f){var g=T(f),b=r[s+=255&g].g-8;return 0<b&&(J(f,f.u+8),g=T(f),s+=r[s].value,s+=g&(1<<b)-1),J(f,f.u+r[s].g),r[s].value}function rn(r,s,f){return f.g+=r.g,f.value+=r.value<<s>>>0,t(8>=f.g),r.g}function an(r,s,f){var g=r.xc;return t((s=g==0?0:r.vc[r.md*(f>>g)+(s>>g)])<r.Wb),r.Ya[s]}function ei(r,s,f,g){var b=r.ab,w=r.c*s,y=r.C;s=y+s;var A=f,L=g;for(g=r.Ta,f=r.Ua;0<b--;){var C=r.gc[b],W=y,et=s,F=A,Y=L,$=(L=g,A=f,C.Ea);switch(t(W<et),t(et<=C.nc),C.hc){case 2:Yi(F,Y,(et-W)*$,L,A);break;case 0:var ut=W,Q=et,ht=L,pt=A,xt=(Ot=C).Ea;ut==0&&(Tr(F,Y,null,null,1,ht,pt),he(F,Y+1,0,0,xt-1,ht,pt+1),Y+=xt,pt+=xt,++ut);for(var bt=1<<Ot.b,Rt=bt-1,Pt=yt(xt,Ot.b),re=Ot.K,Ot=Ot.w+(ut>>Ot.b)*Pt;ut<Q;){var ce=re,Qe=Ot,ie=1;for(Dr(F,Y,ht,pt-xt,1,ht,pt);ie<xt;){var jt=(ie&~Rt)+bt;jt>xt&&(jt=xt),(0,Jn[ce[Qe++]>>8&15])(F,Y+ +ie,ht,pt+ie-xt,jt-ie,ht,pt+ie),ie=jt}Y+=xt,pt+=xt,++ut&Rt||(Ot+=Pt)}et!=C.nc&&i(L,A-$,L,A+(et-W-1)*$,$);break;case 1:for($=F,Q=Y,xt=(F=C.Ea)-(pt=F&~(ht=(Y=1<<C.b)-1)),ut=yt(F,C.b),bt=C.K,C=C.w+(W>>C.b)*ut;W<et;){for(Rt=bt,Pt=C,re=new zt,Ot=Q+pt,ce=Q+F;Q<Ot;)Bt(Rt[Pt++],re),gi(re,$,Q,Y,L,A),Q+=Y,A+=Y;Q<ce&&(Bt(Rt[Pt++],re),gi(re,$,Q,xt,L,A),Q+=xt,A+=xt),++W&ht||(C+=ut)}break;case 3:if(F==L&&Y==A&&0<C.b){for(Q=L,F=$=A+(et-W)*$-(pt=(et-W)*yt(C.Ea,C.b)),Y=L,ht=A,ut=[],pt=(xt=pt)-1;0<=pt;--pt)ut[pt]=Y[ht+pt];for(pt=xt-1;0<=pt;--pt)Q[F+pt]=ut[pt];pi(C,W,et,L,$,L,A)}else pi(C,W,et,F,Y,L,A)}A=g,L=f}L!=f&&i(g,f,A,L,w)}function Or(r,s){var f=r.V,g=r.Ba+r.c*r.C,b=s-r.C;if(t(s<=r.l.o),t(16>=b),0<b){var w=r.l,y=r.Ta,A=r.Ua,L=w.width;if(ei(r,b,f,g),b=A=[A],t((f=r.C)<(g=s)),t(w.v<w.va),g>w.o&&(g=w.o),f<w.j){var C=w.j-f;f=w.j,b[0]+=C*L}if(f>=g?f=0:(b[0]+=4*w.v,w.ka=f-w.j,w.U=w.va-w.v,w.T=g-f,f=1),f){if(A=A[0],11>(f=r.ca).S){var W=f.f.RGBA,et=(g=f.S,b=w.U,w=w.T,C=W.eb,W.A),F=w;for(W=W.fb+r.Ma*W.A;0<F--;){var Y=y,$=A,ut=b,Q=C,ht=W;switch(g){case is:ba(Y,$,ut,Q,ht);break;case as:wa(Y,$,ut,Q,ht);break;case eo:wa(Y,$,ut,Q,ht),xa(Q,ht,0,ut,1,0);break;case cl:vi(Y,$,ut,Q,ht);break;case ss:Ut(Y,$,ut,Q,ht,1);break;case no:Ut(Y,$,ut,Q,ht,1),xa(Q,ht,0,ut,1,0);break;case os:Ut(Y,$,ut,Q,ht,0);break;case ls:Ut(Y,$,ut,Q,ht,0),xa(Q,ht,1,ut,1,0);break;case to:Ji(Y,$,ut,Q,ht);break;case ro:Ji(Y,$,ut,Q,ht),il(Q,ht,ut,1,0);break;case dl:mi(Y,$,ut,Q,ht);break;default:t(0)}A+=L,W+=et}r.Ma+=w}else alert("todo:EmitRescaledRowsYUVA");t(r.Ma<=f.height)}}r.C=s,t(r.C<=r.i)}function Vn(r){var s;if(0<r.ua)return 0;for(s=0;s<r.Wb;++s){var f=r.Ya[s].G,g=r.Ya[s].H;if(0<f[1][g[1]+0].g||0<f[2][g[2]+0].g||0<f[3][g[3]+0].g)return 0}return 1}function rr(r,s,f,g,b,w){if(r.Z!=0){var y=r.qd,A=r.rd;for(t(Hr[r.Z]!=null);s<f;++s)Hr[r.Z](y,A,g,b,g,b,w),y=g,A=b,b+=w;r.qd=y,r.rd=A}}function Gn(r,s){var f=r.l.ma,g=f.Z==0||f.Z==1?r.l.j:r.C;if(g=r.C<g?g:r.C,t(s<=r.l.o),s>g){var b=r.l.width,w=f.ca,y=f.tb+b*g,A=r.V,L=r.Ba+r.c*g,C=r.gc;t(r.ab==1),t(C[0].hc==3),Zs(C[0],g,s,A,L,w,y),rr(f,g,s,w,y,b)}r.C=r.Ma=s}function Yn(r,s,f,g,b,w,y){var A=r.$/g,L=r.$%g,C=r.m,W=r.s,et=f+r.$,F=et;b=f+g*b;var Y=f+g*w,$=280+W.ua,ut=r.Pb?A:16777216,Q=0<W.ua?W.Wa:null,ht=W.wc,pt=et<Y?an(W,L,A):null;t(r.C<w),t(Y<=b);var xt=!1;t:for(;;){for(;xt||et<Y;){var bt=0;if(A>=ut){var Rt=et-f;t((ut=r).Pb),ut.wd=ut.m,ut.xd=Rt,0<ut.s.ua&&Lt(ut.s.Wa,ut.s.vb),ut=A+Vf}if(L&ht||(pt=an(W,L,A)),t(pt!=null),pt.Qb&&(s[et]=pt.qb,xt=!0),!xt)if(Z(C),pt.jc){bt=C,Rt=s;var Pt=et,re=pt.pd[T(bt)&Vi-1];t(pt.jc),256>re.g?(J(bt,bt.u+re.g),Rt[Pt]=re.value,bt=0):(J(bt,bt.u+re.g-256),t(256<=re.value),bt=re.value),bt==0&&(xt=!0)}else bt=Te(pt.G[0],pt.H[0],C);if(C.h)break;if(xt||256>bt){if(!xt)if(pt.nd)s[et]=(pt.qb|bt<<8)>>>0;else{if(Z(C),xt=Te(pt.G[1],pt.H[1],C),Z(C),Rt=Te(pt.G[2],pt.H[2],C),Pt=Te(pt.G[3],pt.H[3],C),C.h)break;s[et]=(Pt<<24|xt<<16|bt<<8|Rt)>>>0}if(xt=!1,++et,++L>=g&&(L=0,++A,y!=null&&A<=w&&!(A%16)&&y(r,A),Q!=null))for(;F<et;)bt=s[F++],Q.X[(506832829*bt&4294967295)>>>Q.Mb]=bt}else if(280>bt){if(bt=Rn(bt-256,C),Rt=Te(pt.G[4],pt.H[4],C),Z(C),Rt=Tn(g,Rt=Rn(Rt,C)),C.h)break;if(et-f<Rt||b-et<bt)break t;for(Pt=0;Pt<bt;++Pt)s[et+Pt]=s[et+Pt-Rt];for(et+=bt,L+=bt;L>=g;)L-=g,++A,y!=null&&A<=w&&!(A%16)&&y(r,A);if(t(et<=b),L&ht&&(pt=an(W,L,A)),Q!=null)for(;F<et;)bt=s[F++],Q.X[(506832829*bt&4294967295)>>>Q.Mb]=bt}else{if(!(bt<$))break t;for(xt=bt-280,t(Q!=null);F<et;)bt=s[F++],Q.X[(506832829*bt&4294967295)>>>Q.Mb]=bt;bt=et,t(!(xt>>>(Rt=Q).Xa)),s[bt]=Rt.X[xt],xt=!0}xt||t(C.h==H(C))}if(r.Pb&&C.h&&et<b)t(r.m.h),r.a=5,r.m=r.wd,r.$=r.xd,0<r.s.ua&&Lt(r.s.vb,r.s.Wa);else{if(C.h)break t;y?.(r,A>w?w:A),r.a=0,r.$=et-f}return 1}return r.a=3,0}function Dn(r){t(r!=null),r.vc=null,r.yc=null,r.Ya=null;var s=r.Wa;s!=null&&(s.X=null),r.vb=null,t(r!=null)}function ni(){var r=new Et;return r==null?null:(r.a=0,r.xb=ml,Se("Predictor","VP8LPredictors"),Se("Predictor","VP8LPredictors_C"),Se("PredictorAdd","VP8LPredictorsAdd"),Se("PredictorAdd","VP8LPredictorsAdd_C"),Yi=fe,gi=ne,ba=ze,wa=ge,Ji=se,mi=oe,vi=Oe,R.VP8LMapColor32b=$e,R.VP8LMapColor8b=fr,r)}function ir(r,s,f,g,b){var w=1,y=[r],A=[s],L=g.m,C=g.s,W=null,et=0;t:for(;;){if(f)for(;w&&wt(L,1);){var F=y,Y=A,$=g,ut=1,Q=$.m,ht=$.gc[$.ab],pt=wt(Q,2);if($.Oc&1<<pt)w=0;else{switch($.Oc|=1<<pt,ht.hc=pt,ht.Ea=F[0],ht.nc=Y[0],ht.K=[null],++$.ab,t(4>=$.ab),pt){case 0:case 1:ht.b=wt(Q,3)+2,ut=ir(yt(ht.Ea,ht.b),yt(ht.nc,ht.b),0,$,ht.K),ht.K=ht.K[0];break;case 3:var xt,bt=wt(Q,8)+1,Rt=16<bt?0:4<bt?1:2<bt?2:3;if(F[0]=yt(ht.Ea,Rt),ht.b=Rt,xt=ut=ir(bt,1,0,$,ht.K)){var Pt,re=bt,Ot=ht,ce=1<<(8>>Ot.b),Qe=a(ce);if(Qe==null)xt=0;else{var ie=Ot.K[0],jt=Ot.w;for(Qe[0]=Ot.K[0][0],Pt=1;Pt<1*re;++Pt)Qe[Pt]=Wt(ie[jt+Pt],Qe[Pt-1]);for(;Pt<4*ce;++Pt)Qe[Pt]=0;Ot.K[0]=null,Ot.K[0]=Qe,xt=1}}ut=xt;break;case 2:break;default:t(0)}w=ut}}if(y=y[0],A=A[0],w&&wt(L,1)&&!(w=1<=(et=wt(L,4))&&11>=et)){g.a=3;break t}var Nt;if(Nt=w)e:{var We,ee,pe,Fe=g,on=y,xn=A,De=et,pn=f,_n=Fe.m,tn=Fe.s,me=[null],we=1,qe=0,ye=Wf[De];n:for(;;){if(pn&&wt(_n,1)){var ln=wt(_n,3)+2,Xn=yt(on,ln),Ve=yt(xn,ln),Ln=Xn*Ve;if(!ir(Xn,Ve,0,Fe,me))break n;for(me=me[0],tn.xc=ln,We=0;We<Ln;++We){var Ne=me[We]>>8&65535;me[We]=Ne,Ne>=we&&(we=Ne+1)}}if(_n.h)break n;for(ee=0;5>ee;++ee){var en=pl[ee];!ee&&0<De&&(en+=1<<De),qe<en&&(qe=en)}var Cn=c(we*ye,z),An=we,Fn=c(An,rt);if(Fn==null)var En=null;else t(65536>=An),En=Fn;var Sn=a(qe);if(En==null||Sn==null||Cn==null){Fe.a=1;break n}var On=Cn;for(We=pe=0;We<we;++We){var Ie=En[We],jn=Ie.G,$n=Ie.H,bi=0,Pr=1,un=0;for(ee=0;5>ee;++ee){en=pl[ee],jn[ee]=On,$n[ee]=pe,!ee&&0<De&&(en+=1<<De);i:{var cs,oo=en,ds=Fe,Na=Sn,hh=On,ch=pe,lo=0,Wr=ds.m,dh=wt(Wr,1);if(o(Na,0,0,oo),dh){var ph=wt(Wr,1)+1,gh=wt(Wr,1),Nl=wt(Wr,gh==0?1:8);Na[Nl]=1,ph==2&&(Na[Nl=wt(Wr,8)]=1);var ps=1}else{var Ll=a(19),Sl=wt(Wr,4)+4;if(19<Sl){ds.a=3;var gs=0;break i}for(cs=0;cs<Sl;++cs)Ll[zf[cs]]=wt(Wr,3);var uo=void 0,La=void 0,kl=ds,mh=Ll,ms=oo,Pl=Na,fo=0,Vr=kl.m,Il=8,Cl=c(128,z);r:for(;E(Cl,0,7,mh,19);){if(wt(Vr,1)){var vh=2+2*wt(Vr,3);if((uo=2+wt(Vr,vh))>ms)break r}else uo=ms;for(La=0;La<ms&&uo--;){Z(Vr);var Fl=Cl[0+(127&T(Vr))];J(Vr,Vr.u+Fl.g);var $i=Fl.value;if(16>$i)Pl[La++]=$i,$i!=0&&(Il=$i);else{var bh=$i==16,El=$i-16,wh=qf[El],Ol=wt(Vr,Df[El])+wh;if(La+Ol>ms)break r;for(var yh=bh?Il:0;0<Ol--;)Pl[La++]=yh}}fo=1;break r}fo||(kl.a=3),ps=fo}(ps=ps&&!Wr.h)&&(lo=E(hh,ch,8,Na,oo)),ps&&lo!=0?gs=lo:(ds.a=3,gs=0)}if(gs==0)break n;if(Pr&&Uf[ee]==1&&(Pr=On[pe].g==0),bi+=On[pe].g,pe+=gs,3>=ee){var Sa,ho=Sn[0];for(Sa=1;Sa<en;++Sa)Sn[Sa]>ho&&(ho=Sn[Sa]);un+=ho}}if(Ie.nd=Pr,Ie.Qb=0,Pr&&(Ie.qb=(jn[3][$n[3]+0].value<<24|jn[1][$n[1]+0].value<<16|jn[2][$n[2]+0].value)>>>0,bi==0&&256>jn[0][$n[0]+0].value&&(Ie.Qb=1,Ie.qb+=jn[0][$n[0]+0].value<<8)),Ie.jc=!Ie.Qb&&6>un,Ie.jc){var vs,Ir=Ie;for(vs=0;vs<Vi;++vs){var Gr=vs,Yr=Ir.pd[Gr],bs=Ir.G[0][Ir.H[0]+Gr];256<=bs.value?(Yr.g=bs.g+256,Yr.value=bs.value):(Yr.g=0,Yr.value=0,Gr>>=rn(bs,8,Yr),Gr>>=rn(Ir.G[1][Ir.H[1]+Gr],16,Yr),Gr>>=rn(Ir.G[2][Ir.H[2]+Gr],0,Yr),rn(Ir.G[3][Ir.H[3]+Gr],24,Yr))}}}tn.vc=me,tn.Wb=we,tn.Ya=En,tn.yc=Cn,Nt=1;break e}Nt=0}if(!(w=Nt)){g.a=3;break t}if(0<et){if(C.ua=1<<et,!P(C.Wa,et)){g.a=1,w=0;break t}}else C.ua=0;var co=g,jl=y,xh=A,po=co.s,go=po.xc;if(co.c=jl,co.i=xh,po.md=yt(jl,go),po.wc=go==0?-1:(1<<go)-1,f){g.xb=Zf;break t}if((W=a(y*A))==null){g.a=1,w=0;break t}w=(w=Yn(g,W,0,y,A,A,null))&&!L.h;break t}return w?(b!=null?b[0]=W:(t(W==null),t(f)),g.$=0,f||Dn(C)):Dn(C),w}function ri(r,s){var f=r.c*r.i,g=f+s+16*s;return t(r.c<=s),r.V=a(g),r.V==null?(r.Ta=null,r.Ua=0,r.a=1,0):(r.Ta=r.V,r.Ua=r.Ba+f+s,1)}function Ci(r,s){var f=r.C,g=s-f,b=r.V,w=r.Ba+r.c*f;for(t(s<=r.l.o);0<g;){var y=16<g?16:g,A=r.l.ma,L=r.l.width,C=L*y,W=A.ca,et=A.tb+L*f,F=r.Ta,Y=r.Ua;ei(r,y,b,w),sl(F,Y,W,et,C),rr(A,f,f+y,W,et,L),g-=y,b+=y*r.c,f+=y}t(f==s),r.C=r.Ma=s}function Fi(){this.ub=this.yd=this.td=this.Rb=0}function Ei(){this.Kd=this.Ld=this.Ud=this.Td=this.i=this.c=0}function js(){this.Fb=this.Bb=this.Cb=0,this.Zb=a(4),this.Lb=a(4)}function ia(){this.Yb=(function(){var r=[];return(function s(f,g,b){for(var w=b[g],y=0;y<w&&(f.push(b.length>g+1?[]:0),!(b.length<g+1));y++)s(f[y],g+1,b)})(r,0,[3,11]),r})()}function Da(){this.jb=a(3),this.Wc=l([4,8],ia),this.Xc=l([4,17],ia)}function qa(){this.Pc=this.wb=this.Tb=this.zd=0,this.vd=new a(4),this.od=new a(4)}function qn(){this.ld=this.La=this.dd=this.tc=0}function aa(){this.Na=this.la=0}function Ua(){this.Sc=[0,0],this.Eb=[0,0],this.Qc=[0,0],this.ia=this.lc=0}function sa(){this.ad=a(384),this.Za=0,this.Ob=a(16),this.$b=this.Ad=this.ia=this.Gc=this.Hc=this.Dd=0}function za(){this.uc=this.M=this.Nb=0,this.wa=Array(new qn),this.Y=0,this.ya=Array(new sa),this.aa=0,this.l=new Oi}function Ha(){this.y=a(16),this.f=a(8),this.ea=a(8)}function Wa(){this.cb=this.a=0,this.sc="",this.m=new x,this.Od=new Fi,this.Kc=new Ei,this.ed=new qa,this.Qa=new js,this.Ic=this.$c=this.Aa=0,this.D=new za,this.Xb=this.Va=this.Hb=this.zb=this.yb=this.Ub=this.za=0,this.Jc=c(8,x),this.ia=0,this.pb=c(4,Ua),this.Pa=new Da,this.Bd=this.kc=0,this.Ac=[],this.Bc=0,this.zc=[0,0,0,0],this.Gd=Array(new Ha),this.Hd=0,this.rb=Array(new aa),this.sb=0,this.wa=Array(new qn),this.Y=0,this.oc=[],this.pc=0,this.sa=[],this.ta=0,this.qa=[],this.ra=0,this.Ha=[],this.B=this.R=this.Ia=0,this.Ec=[],this.M=this.ja=this.Vb=this.Fc=0,this.ya=Array(new sa),this.L=this.aa=0,this.gd=l([4,2],qn),this.ga=null,this.Fa=[],this.Cc=this.qc=this.P=0,this.Gb=[],this.Uc=0,this.mb=[],this.nb=0,this.rc=[],this.Ga=this.Vc=0}function ar(r,s){return 0>r?0:r>s?s:r}function Oi(){this.T=this.U=this.ka=this.height=this.width=0,this.y=[],this.f=[],this.ea=[],this.Rc=this.fa=this.W=this.N=this.O=0,this.ma="void",this.put="VP8IoPutHook",this.ac="VP8IoSetupHook",this.bc="VP8IoTeardownHook",this.ha=this.Kb=0,this.data=[],this.hb=this.ib=this.da=this.o=this.j=this.va=this.v=this.Da=this.ob=this.w=0,this.F=[],this.J=0}function Bs(){var r=new Wa;return r!=null&&(r.a=0,r.sc="OK",r.cb=0,r.Xb=0,_a||(_a=ji)),r}function Ke(r,s,f){return r.a==0&&(r.a=s,r.sc=f,r.cb=0),0}function Va(r,s,f){return 3<=f&&r[s+0]==157&&r[s+1]==1&&r[s+2]==42}function sr(r,s){if(r==null)return 0;if(r.a=0,r.sc="OK",s==null)return Ke(r,2,"null VP8Io passed to VP8GetHeaders()");var f=s.data,g=s.w,b=s.ha;if(4>b)return Ke(r,7,"Truncated header.");var w=f[g+0]|f[g+1]<<8|f[g+2]<<16,y=r.Od;if(y.Rb=!(1&w),y.td=w>>1&7,y.yd=w>>4&1,y.ub=w>>5,3<y.td)return Ke(r,3,"Incorrect keyframe parameters.");if(!y.yd)return Ke(r,4,"Frame not displayable.");g+=3,b-=3;var A=r.Kc;if(y.Rb){if(7>b)return Ke(r,7,"cannot parse picture header");if(!Va(f,g,b))return Ke(r,3,"Bad code word");A.c=16383&(f[g+4]<<8|f[g+3]),A.Td=f[g+4]>>6,A.i=16383&(f[g+6]<<8|f[g+5]),A.Ud=f[g+6]>>6,g+=7,b-=7,r.za=A.c+15>>4,r.Ub=A.i+15>>4,s.width=A.c,s.height=A.i,s.Da=0,s.j=0,s.v=0,s.va=s.width,s.o=s.height,s.da=0,s.ib=s.width,s.hb=s.height,s.U=s.width,s.T=s.height,o((w=r.Pa).jb,0,255,w.jb.length),t((w=r.Qa)!=null),w.Cb=0,w.Bb=0,w.Fb=1,o(w.Zb,0,0,w.Zb.length),o(w.Lb,0,0,w.Lb)}if(y.ub>b)return Ke(r,7,"bad partition length");ot(w=r.m,f,g,y.ub),g+=y.ub,b-=y.ub,y.Rb&&(A.Ld=st(w),A.Kd=st(w)),A=r.Qa;var L,C=r.Pa;if(t(w!=null),t(A!=null),A.Cb=st(w),A.Cb){if(A.Bb=st(w),st(w)){for(A.Fb=st(w),L=0;4>L;++L)A.Zb[L]=st(w)?nt(w,7):0;for(L=0;4>L;++L)A.Lb[L]=st(w)?nt(w,6):0}if(A.Bb)for(L=0;3>L;++L)C.jb[L]=st(w)?ft(w,8):255}else A.Bb=0;if(w.Ka)return Ke(r,3,"cannot parse segment header");if((A=r.ed).zd=st(w),A.Tb=ft(w,6),A.wb=ft(w,3),A.Pc=st(w),A.Pc&&st(w)){for(C=0;4>C;++C)st(w)&&(A.vd[C]=nt(w,6));for(C=0;4>C;++C)st(w)&&(A.od[C]=nt(w,6))}if(r.L=A.Tb==0?0:A.zd?1:2,w.Ka)return Ke(r,3,"cannot parse filter header");var W=b;if(b=L=g,g=L+W,A=W,r.Xb=(1<<ft(r.m,2))-1,W<3*(C=r.Xb))f=7;else{for(L+=3*C,A-=3*C,W=0;W<C;++W){var et=f[b+0]|f[b+1]<<8|f[b+2]<<16;et>A&&(et=A),ot(r.Jc[+W],f,L,et),L+=et,A-=et,b+=3}ot(r.Jc[+C],f,L,A),f=L<g?0:5}if(f!=0)return Ke(r,f,"cannot parse partitions");for(f=ft(L=r.m,7),b=st(L)?nt(L,4):0,g=st(L)?nt(L,4):0,A=st(L)?nt(L,4):0,C=st(L)?nt(L,4):0,L=st(L)?nt(L,4):0,W=r.Qa,et=0;4>et;++et){if(W.Cb){var F=W.Zb[et];W.Fb||(F+=f)}else{if(0<et){r.pb[et]=r.pb[0];continue}F=f}var Y=r.pb[et];Y.Sc[0]=io[ar(F+b,127)],Y.Sc[1]=ao[ar(F+0,127)],Y.Eb[0]=2*io[ar(F+g,127)],Y.Eb[1]=101581*ao[ar(F+A,127)]>>16,8>Y.Eb[1]&&(Y.Eb[1]=8),Y.Qc[0]=io[ar(F+C,117)],Y.Qc[1]=ao[ar(F+L,127)],Y.lc=F+L}if(!y.Rb)return Ke(r,4,"Not a key frame.");for(st(w),y=r.Pa,f=0;4>f;++f){for(b=0;8>b;++b)for(g=0;3>g;++g)for(A=0;11>A;++A)C=gt(w,Xf[f][b][g][A])?ft(w,8):Jf[f][b][g][A],y.Wc[f][b].Yb[g][A]=C;for(b=0;17>b;++b)y.Xc[f][b]=y.Wc[f][$f[b]]}return r.kc=st(w),r.kc&&(r.Bd=ft(w,8)),r.cb=1}function ji(r,s,f,g,b,w,y){var A=s[b].Yb[f];for(f=0;16>b;++b){if(!gt(r,A[f+0]))return b;for(;!gt(r,A[f+1]);)if(A=s[++b].Yb[0],f=0,b==16)return 16;var L=s[b+1].Yb;if(gt(r,A[f+2])){var C=r,W=0;if(gt(C,(F=A)[(et=f)+3]))if(gt(C,F[et+6])){for(A=0,et=2*(W=gt(C,F[et+8]))+(F=gt(C,F[et+9+W])),W=0,F=Gf[et];F[A];++A)W+=W+gt(C,F[A]);W+=3+(8<<et)}else gt(C,F[et+7])?(W=7+2*gt(C,165),W+=gt(C,145)):W=5+gt(C,159);else W=gt(C,F[et+4])?3+gt(C,F[et+5]):2;A=L[2]}else W=1,A=L[1];L=y+Yf[b],0>(C=r).b&&at(C);var et,F=C.b,Y=(et=C.Ca>>1)-(C.I>>F)>>31;--C.b,C.Ca+=Y,C.Ca|=1,C.I-=(et+1&Y)<<F,w[L]=((W^Y)-Y)*g[(0<b)+0]}return 16}function oa(r){var s=r.rb[r.sb-1];s.la=0,s.Na=0,o(r.zc,0,0,r.zc.length),r.ja=0}function Pn(r,s,f,g,b){b=r[s+f+32*g]+(b>>3),r[s+f+32*g]=-256&b?0>b?0:255:b}function Bi(r,s,f,g,b,w){Pn(r,s,0,f,g+b),Pn(r,s,1,f,g+w),Pn(r,s,2,f,g-w),Pn(r,s,3,f,g-b)}function wr(r){return(20091*r>>16)+r}function sn(r,s,f,g){var b,w=0,y=a(16);for(b=0;4>b;++b){var A=r[s+0]+r[s+8],L=r[s+0]-r[s+8],C=(35468*r[s+4]>>16)-wr(r[s+12]),W=wr(r[s+4])+(35468*r[s+12]>>16);y[w+0]=A+W,y[w+1]=L+C,y[w+2]=L-C,y[w+3]=A-W,w+=4,s++}for(b=w=0;4>b;++b)A=(r=y[w+0]+4)+y[w+8],L=r-y[w+8],C=(35468*y[w+4]>>16)-wr(y[w+12]),Pn(f,g,0,0,A+(W=wr(y[w+4])+(35468*y[w+12]>>16))),Pn(f,g,1,0,L+C),Pn(f,g,2,0,L-C),Pn(f,g,3,0,A-W),w++,g+=32}function Ga(r,s,f,g){var b=r[s+0]+4,w=35468*r[s+4]>>16,y=wr(r[s+4]),A=35468*r[s+1]>>16;Bi(f,g,0,b+y,r=wr(r[s+1]),A),Bi(f,g,1,b+w,r,A),Bi(f,g,2,b-w,r,A),Bi(f,g,3,b-y,r,A)}function Ms(r,s,f,g,b){sn(r,s,f,g),b&&sn(r,s+16,f,g+4)}function Rs(r,s,f,g){Lr(r,s+0,f,g,1),Lr(r,s+32,f,g+128,1)}function Ts(r,s,f,g){var b;for(r=r[s+0]+4,b=0;4>b;++b)for(s=0;4>s;++s)Pn(f,g,s,b,r)}function or(r,s,f,g){r[s+0]&&dn(r,s+0,f,g),r[s+16]&&dn(r,s+16,f,g+4),r[s+32]&&dn(r,s+32,f,g+128),r[s+48]&&dn(r,s+48,f,g+128+4)}function Ya(r,s,f,g){var b,w=a(16);for(b=0;4>b;++b){var y=r[s+0+b]+r[s+12+b],A=r[s+4+b]+r[s+8+b],L=r[s+4+b]-r[s+8+b],C=r[s+0+b]-r[s+12+b];w[0+b]=y+A,w[8+b]=y-A,w[4+b]=C+L,w[12+b]=C-L}for(b=0;4>b;++b)y=(r=w[0+4*b]+3)+w[3+4*b],A=w[1+4*b]+w[2+4*b],L=w[1+4*b]-w[2+4*b],C=r-w[3+4*b],f[g+0]=y+A>>3,f[g+16]=C+L>>3,f[g+32]=y-A>>3,f[g+48]=C-L>>3,g+=64}function Mi(r,s,f){var g,b=s-32,w=In,y=255-r[b-1];for(g=0;g<f;++g){var A,L=w,C=y+r[s-1];for(A=0;A<f;++A)r[s+A]=L[C+r[b+A]];s+=32}}function Ri(r,s){Mi(r,s,4)}function la(r,s){Mi(r,s,8)}function Ds(r,s){Mi(r,s,16)}function qs(r,s){var f;for(f=0;16>f;++f)i(r,s+32*f,r,s-32,16)}function Us(r,s){var f;for(f=16;0<f;--f)o(r,s,r[s-1],16),s+=32}function jr(r,s,f){var g;for(g=0;16>g;++g)o(s,f+32*g,r,16)}function Ja(r,s){var f,g=16;for(f=0;16>f;++f)g+=r[s-1+32*f]+r[s+f-32];jr(g>>5,r,s)}function Br(r,s){var f,g=8;for(f=0;16>f;++f)g+=r[s-1+32*f];jr(g>>4,r,s)}function zs(r,s){var f,g=8;for(f=0;16>f;++f)g+=r[s+f-32];jr(g>>4,r,s)}function ii(r,s){jr(128,r,s)}function Jt(r,s,f){return r+2*s+f+2>>2}function Hs(r,s){var f,g=s-32;for(g=new Uint8Array([Jt(r[g-1],r[g+0],r[g+1]),Jt(r[g+0],r[g+1],r[g+2]),Jt(r[g+1],r[g+2],r[g+3]),Jt(r[g+2],r[g+3],r[g+4])]),f=0;4>f;++f)i(r,s+32*f,g,0,g.length)}function Ws(r,s){var f=r[s-1],g=r[s-1+32],b=r[s-1+64],w=r[s-1+96];_t(r,s+0,16843009*Jt(r[s-1-32],f,g)),_t(r,s+32,16843009*Jt(f,g,b)),_t(r,s+64,16843009*Jt(g,b,w)),_t(r,s+96,16843009*Jt(b,w,w))}function Vs(r,s){var f,g=4;for(f=0;4>f;++f)g+=r[s+f-32]+r[s-1+32*f];for(g>>=3,f=0;4>f;++f)o(r,s+32*f,g,4)}function Gs(r,s){var f=r[s-1+0],g=r[s-1+32],b=r[s-1+64],w=r[s-1-32],y=r[s+0-32],A=r[s+1-32],L=r[s+2-32],C=r[s+3-32];r[s+0+96]=Jt(g,b,r[s-1+96]),r[s+1+96]=r[s+0+64]=Jt(f,g,b),r[s+2+96]=r[s+1+64]=r[s+0+32]=Jt(w,f,g),r[s+3+96]=r[s+2+64]=r[s+1+32]=r[s+0+0]=Jt(y,w,f),r[s+3+64]=r[s+2+32]=r[s+1+0]=Jt(A,y,w),r[s+3+32]=r[s+2+0]=Jt(L,A,y),r[s+3+0]=Jt(C,L,A)}function Ys(r,s){var f=r[s+1-32],g=r[s+2-32],b=r[s+3-32],w=r[s+4-32],y=r[s+5-32],A=r[s+6-32],L=r[s+7-32];r[s+0+0]=Jt(r[s+0-32],f,g),r[s+1+0]=r[s+0+32]=Jt(f,g,b),r[s+2+0]=r[s+1+32]=r[s+0+64]=Jt(g,b,w),r[s+3+0]=r[s+2+32]=r[s+1+64]=r[s+0+96]=Jt(b,w,y),r[s+3+32]=r[s+2+64]=r[s+1+96]=Jt(w,y,A),r[s+3+64]=r[s+2+96]=Jt(y,A,L),r[s+3+96]=Jt(A,L,L)}function yr(r,s){var f=r[s-1+0],g=r[s-1+32],b=r[s-1+64],w=r[s-1-32],y=r[s+0-32],A=r[s+1-32],L=r[s+2-32],C=r[s+3-32];r[s+0+0]=r[s+1+64]=w+y+1>>1,r[s+1+0]=r[s+2+64]=y+A+1>>1,r[s+2+0]=r[s+3+64]=A+L+1>>1,r[s+3+0]=L+C+1>>1,r[s+0+96]=Jt(b,g,f),r[s+0+64]=Jt(g,f,w),r[s+0+32]=r[s+1+96]=Jt(f,w,y),r[s+1+32]=r[s+2+96]=Jt(w,y,A),r[s+2+32]=r[s+3+96]=Jt(y,A,L),r[s+3+32]=Jt(A,L,C)}function xr(r,s){var f=r[s+0-32],g=r[s+1-32],b=r[s+2-32],w=r[s+3-32],y=r[s+4-32],A=r[s+5-32],L=r[s+6-32],C=r[s+7-32];r[s+0+0]=f+g+1>>1,r[s+1+0]=r[s+0+64]=g+b+1>>1,r[s+2+0]=r[s+1+64]=b+w+1>>1,r[s+3+0]=r[s+2+64]=w+y+1>>1,r[s+0+32]=Jt(f,g,b),r[s+1+32]=r[s+0+96]=Jt(g,b,w),r[s+2+32]=r[s+1+96]=Jt(b,w,y),r[s+3+32]=r[s+2+96]=Jt(w,y,A),r[s+3+64]=Jt(y,A,L),r[s+3+96]=Jt(A,L,C)}function Js(r,s){var f=r[s-1+0],g=r[s-1+32],b=r[s-1+64],w=r[s-1+96];r[s+0+0]=f+g+1>>1,r[s+2+0]=r[s+0+32]=g+b+1>>1,r[s+2+32]=r[s+0+64]=b+w+1>>1,r[s+1+0]=Jt(f,g,b),r[s+3+0]=r[s+1+32]=Jt(g,b,w),r[s+3+32]=r[s+1+64]=Jt(b,w,w),r[s+3+64]=r[s+2+64]=r[s+0+96]=r[s+1+96]=r[s+2+96]=r[s+3+96]=w}function Ks(r,s){var f=r[s-1+0],g=r[s-1+32],b=r[s-1+64],w=r[s-1+96],y=r[s-1-32],A=r[s+0-32],L=r[s+1-32],C=r[s+2-32];r[s+0+0]=r[s+2+32]=f+y+1>>1,r[s+0+32]=r[s+2+64]=g+f+1>>1,r[s+0+64]=r[s+2+96]=b+g+1>>1,r[s+0+96]=w+b+1>>1,r[s+3+0]=Jt(A,L,C),r[s+2+0]=Jt(y,A,L),r[s+1+0]=r[s+3+32]=Jt(f,y,A),r[s+1+32]=r[s+3+64]=Jt(g,f,y),r[s+1+64]=r[s+3+96]=Jt(b,g,f),r[s+1+96]=Jt(w,b,g)}function Ti(r,s){var f;for(f=0;8>f;++f)i(r,s+32*f,r,s-32,8)}function ua(r,s){var f;for(f=0;8>f;++f)o(r,s,r[s-1],8),s+=32}function lr(r,s,f){var g;for(g=0;8>g;++g)o(s,f+32*g,r,8)}function Xs(r,s){var f,g=8;for(f=0;8>f;++f)g+=r[s+f-32]+r[s-1+32*f];lr(g>>4,r,s)}function Di(r,s){var f,g=4;for(f=0;8>f;++f)g+=r[s+f-32];lr(g>>3,r,s)}function $s(r,s){var f,g=4;for(f=0;8>f;++f)g+=r[s-1+32*f];lr(g>>3,r,s)}function fa(r,s){lr(128,r,s)}function Mr(r,s,f){var g=r[s-f],b=r[s+0],w=3*(b-g)+Qs[1020+r[s-2*f]-r[s+f]],y=rs[112+(w+4>>3)];r[s-f]=In[255+g+rs[112+(w+3>>3)]],r[s+0]=In[255+b-y]}function ha(r,s,f,g){var b=r[s+0],w=r[s+f];return zn[255+r[s-2*f]-r[s-f]]>g||zn[255+w-b]>g}function ai(r,s,f,g){return 4*zn[255+r[s-f]-r[s+0]]+zn[255+r[s-2*f]-r[s+f]]<=g}function ca(r,s,f,g,b){var w=r[s-3*f],y=r[s-2*f],A=r[s-f],L=r[s+0],C=r[s+f],W=r[s+2*f],et=r[s+3*f];return 4*zn[255+A-L]+zn[255+y-C]>g?0:zn[255+r[s-4*f]-w]<=b&&zn[255+w-y]<=b&&zn[255+y-A]<=b&&zn[255+et-W]<=b&&zn[255+W-C]<=b&&zn[255+C-L]<=b}function qi(r,s,f,g){var b=2*g+1;for(g=0;16>g;++g)ai(r,s+g,f,b)&&Mr(r,s+g,f)}function da(r,s,f,g){var b=2*g+1;for(g=0;16>g;++g)ai(r,s+g*f,1,b)&&Mr(r,s+g*f,1)}function Ui(r,s,f,g){var b;for(b=3;0<b;--b)qi(r,s+=4*f,f,g)}function Ka(r,s,f,g){var b;for(b=3;0<b;--b)da(r,s+=4,f,g)}function _r(r,s,f,g,b,w,y,A){for(w=2*w+1;0<b--;){if(ca(r,s,f,w,y))if(ha(r,s,f,A))Mr(r,s,f);else{var L=r,C=s,W=f,et=L[C-2*W],F=L[C-W],Y=L[C+0],$=L[C+W],ut=L[C+2*W],Q=27*(pt=Qs[1020+3*(Y-F)+Qs[1020+et-$]])+63>>7,ht=18*pt+63>>7,pt=9*pt+63>>7;L[C-3*W]=In[255+L[C-3*W]+pt],L[C-2*W]=In[255+et+ht],L[C-W]=In[255+F+Q],L[C+0]=In[255+Y-Q],L[C+W]=In[255+$-ht],L[C+2*W]=In[255+ut-pt]}s+=g}}function Ar(r,s,f,g,b,w,y,A){for(w=2*w+1;0<b--;){if(ca(r,s,f,w,y))if(ha(r,s,f,A))Mr(r,s,f);else{var L=r,C=s,W=f,et=L[C-W],F=L[C+0],Y=L[C+W],$=rs[112+(4+(ut=3*(F-et))>>3)],ut=rs[112+(ut+3>>3)],Q=$+1>>1;L[C-2*W]=In[255+L[C-2*W]+Q],L[C-W]=In[255+et+ut],L[C+0]=In[255+F-$],L[C+W]=In[255+Y-Q]}s+=g}}function Xa(r,s,f,g,b,w){_r(r,s,f,1,16,g,b,w)}function $a(r,s,f,g,b,w){_r(r,s,1,f,16,g,b,w)}function Za(r,s,f,g,b,w){var y;for(y=3;0<y;--y)Ar(r,s+=4*f,f,1,16,g,b,w)}function si(r,s,f,g,b,w){var y;for(y=3;0<y;--y)Ar(r,s+=4,1,f,16,g,b,w)}function Qa(r,s,f,g,b,w,y,A){_r(r,s,b,1,8,w,y,A),_r(f,g,b,1,8,w,y,A)}function u(r,s,f,g,b,w,y,A){_r(r,s,1,b,8,w,y,A),_r(f,g,1,b,8,w,y,A)}function v(r,s,f,g,b,w,y,A){Ar(r,s+4*b,b,1,8,w,y,A),Ar(f,g+4*b,b,1,8,w,y,A)}function I(r,s,f,g,b,w,y,A){Ar(r,s+4,1,b,8,w,y,A),Ar(f,g+4,1,b,8,w,y,A)}function D(){this.ba=new le,this.ec=[],this.cc=[],this.Mc=[],this.Dc=this.Nc=this.dc=this.fc=0,this.Oa=new be,this.memory=0,this.Ib="OutputFunc",this.Jb="OutputAlphaFunc",this.Nd="OutputRowFunc"}function K(){this.data=[],this.offset=this.kd=this.ha=this.w=0,this.na=[],this.xa=this.gb=this.Ja=this.Sa=this.P=0}function lt(){this.nc=this.Ea=this.b=this.hc=0,this.K=[],this.w=0}function mt(){this.ua=0,this.Wa=new ae,this.vb=new ae,this.md=this.xc=this.wc=0,this.vc=[],this.Wb=0,this.Ya=new rt,this.yc=new z}function Et(){this.xb=this.a=0,this.l=new Oi,this.ca=new le,this.V=[],this.Ba=0,this.Ta=[],this.Ua=0,this.m=new B,this.Pb=0,this.wd=new B,this.Ma=this.$=this.C=this.i=this.c=this.xd=0,this.s=new mt,this.ab=0,this.gc=c(4,lt),this.Oc=0}function Ft(){this.Lc=this.Z=this.$a=this.i=this.c=0,this.l=new Oi,this.ic=0,this.ca=[],this.tb=0,this.qd=null,this.rd=0}function Xt(r,s,f,g,b,w,y){for(r=r==null?0:r[s+0],s=0;s<y;++s)b[w+s]=r+f[g+s]&255,r=b[w+s]}function te(r,s,f,g,b,w,y){var A;if(r==null)Xt(null,null,f,g,b,w,y);else for(A=0;A<y;++A)b[w+A]=r[s+A]+f[g+A]&255}function de(r,s,f,g,b,w,y){if(r==null)Xt(null,null,f,g,b,w,y);else{var A,L=r[s+0],C=L,W=L;for(A=0;A<y;++A)C=W+(L=r[s+A])-C,W=f[g+A]+(-256&C?0>C?0:255:C)&255,C=L,b[w+A]=W}}function Xe(r,s,f,g){var b=s.width,w=s.o;if(t(r!=null&&s!=null),0>f||0>=g||f+g>w)return null;if(!r.Cc){if(r.ga==null){var y;if(r.ga=new Ft,(y=r.ga==null)||(y=s.width*s.o,t(r.Gb.length==0),r.Gb=a(y),r.Uc=0,r.Gb==null?y=0:(r.mb=r.Gb,r.nb=r.Uc,r.rc=null,y=1),y=!y),!y){y=r.ga;var A=r.Fa,L=r.P,C=r.qc,W=r.mb,et=r.nb,F=L+1,Y=C-1,$=y.l;if(t(A!=null&&W!=null&&s!=null),Hr[0]=null,Hr[1]=Xt,Hr[2]=te,Hr[3]=de,y.ca=W,y.tb=et,y.c=s.width,y.i=s.height,t(0<y.c&&0<y.i),1>=C)s=0;else if(y.$a=3&A[L+0],y.Z=A[L+0]>>2&3,y.Lc=A[L+0]>>4&3,L=A[L+0]>>6&3,0>y.$a||1<y.$a||4<=y.Z||1<y.Lc||L)s=0;else if($.put=Gt,$.ac=nr,$.bc=vr,$.ma=y,$.width=s.width,$.height=s.height,$.Da=s.Da,$.v=s.v,$.va=s.va,$.j=s.j,$.o=s.o,y.$a)t:{t(y.$a==1),s=ni();e:for(;;){if(s==null){s=0;break t}if(t(y!=null),y.mc=s,s.c=y.c,s.i=y.i,s.l=y.l,s.l.ma=y,s.l.width=y.c,s.l.height=y.i,s.a=0,ct(s.m,A,F,Y),!ir(y.c,y.i,1,s,null)||(s.ab==1&&s.gc[0].hc==3&&Vn(s.s)?(y.ic=1,A=s.c*s.i,s.Ta=null,s.Ua=0,s.V=a(A),s.Ba=0,s.V==null?(s.a=1,s=0):s=1):(y.ic=0,s=ri(s,y.c)),!s))break e;s=1;break t}y.mc=null,s=0}else s=Y>=y.c*y.i;y=!s}if(y)return null;r.ga.Lc!=1?r.Ga=0:g=w-f}t(r.ga!=null),t(f+g<=w);t:{if(s=(A=r.ga).c,w=A.l.o,A.$a==0){if(F=r.rc,Y=r.Vc,$=r.Fa,L=r.P+1+f*s,C=r.mb,W=r.nb+f*s,t(L<=r.P+r.qc),A.Z!=0)for(t(Hr[A.Z]!=null),y=0;y<g;++y)Hr[A.Z](F,Y,$,L,C,W,s),F=C,Y=W,W+=s,L+=s;else for(y=0;y<g;++y)i(C,W,$,L,s),F=C,Y=W,W+=s,L+=s;r.rc=F,r.Vc=Y}else{if(t(A.mc!=null),s=f+g,t((y=A.mc)!=null),t(s<=y.i),y.C>=s)s=1;else if(A.ic||Re(),A.ic){A=y.V,F=y.Ba,Y=y.c;var ut=y.i,Q=($=1,L=y.$/Y,C=y.$%Y,W=y.m,et=y.s,y.$),ht=Y*ut,pt=Y*s,xt=et.wc,bt=Q<pt?an(et,C,L):null;t(Q<=ht),t(s<=ut),t(Vn(et));e:for(;;){for(;!W.h&&Q<pt;){if(C&xt||(bt=an(et,C,L)),t(bt!=null),Z(W),256>(ut=Te(bt.G[0],bt.H[0],W)))A[F+Q]=ut,++Q,++C>=Y&&(C=0,++L<=s&&!(L%16)&&Gn(y,L));else{if(!(280>ut)){$=0;break e}ut=Rn(ut-256,W);var Rt,Pt=Te(bt.G[4],bt.H[4],W);if(Z(W),!(Q>=(Pt=Tn(Y,Pt=Rn(Pt,W)))&&ht-Q>=ut)){$=0;break e}for(Rt=0;Rt<ut;++Rt)A[F+Q+Rt]=A[F+Q+Rt-Pt];for(Q+=ut,C+=ut;C>=Y;)C-=Y,++L<=s&&!(L%16)&&Gn(y,L);Q<pt&&C&xt&&(bt=an(et,C,L))}t(W.h==H(W))}Gn(y,L>s?s:L);break e}!$||W.h&&Q<ht?($=0,y.a=W.h?5:3):y.$=Q,s=$}else s=Yn(y,y.V,y.Ba,y.c,y.i,s,Ci);if(!s){g=0;break t}}f+g>=w&&(r.Cc=1),g=1}if(!g)return null;if(r.Cc&&((g=r.ga)!=null&&(g.mc=null),r.ga=null,0<r.Ga))return alert("todo:WebPDequantizeLevels"),null}return r.nb+f*b}function Ae(r,s,f,g,b,w){for(;0<b--;){var y,A=r,L=s+(f?1:0),C=r,W=s+(f?0:3);for(y=0;y<g;++y){var et=C[W+4*y];et!=255&&(et*=32897,A[L+4*y+0]=A[L+4*y+0]*et>>23,A[L+4*y+1]=A[L+4*y+1]*et>>23,A[L+4*y+2]=A[L+4*y+2]*et>>23)}s+=w}}function _e(r,s,f,g,b){for(;0<g--;){var w;for(w=0;w<f;++w){var y=r[s+2*w+0],A=15&(C=r[s+2*w+1]),L=4369*A,C=(240&C|C>>4)*L>>16;r[s+2*w+0]=(240&y|y>>4)*L>>16&240|(15&y|y<<4)*L>>16>>4&15,r[s+2*w+1]=240&C|A}s+=b}}function Ce(r,s,f,g,b,w,y,A){var L,C,W=255;for(C=0;C<b;++C){for(L=0;L<g;++L){var et=r[s+L];w[y+4*L]=et,W&=et}s+=f,y+=A}return W!=255}function Me(r,s,f,g,b){var w;for(w=0;w<b;++w)f[g+w]=r[s+w]>>8}function Re(){xa=Ae,il=_e,al=Ce,sl=Me}function hn(r,s,f){R[r]=function(g,b,w,y,A,L,C,W,et,F,Y,$,ut,Q,ht,pt,xt){var bt,Rt=xt-1>>1,Pt=A[L+0]|C[W+0]<<16,re=et[F+0]|Y[$+0]<<16;t(g!=null);var Ot=3*Pt+re+131074>>2;for(s(g[b+0],255&Ot,Ot>>16,ut,Q),w!=null&&(Ot=3*re+Pt+131074>>2,s(w[y+0],255&Ot,Ot>>16,ht,pt)),bt=1;bt<=Rt;++bt){var ce=A[L+bt]|C[W+bt]<<16,Qe=et[F+bt]|Y[$+bt]<<16,ie=Pt+ce+re+Qe+524296,jt=ie+2*(ce+re)>>3;Ot=jt+Pt>>1,Pt=(ie=ie+2*(Pt+Qe)>>3)+ce>>1,s(g[b+2*bt-1],255&Ot,Ot>>16,ut,Q+(2*bt-1)*f),s(g[b+2*bt-0],255&Pt,Pt>>16,ut,Q+(2*bt-0)*f),w!=null&&(Ot=ie+re>>1,Pt=jt+Qe>>1,s(w[y+2*bt-1],255&Ot,Ot>>16,ht,pt+(2*bt-1)*f),s(w[y+2*bt+0],255&Pt,Pt>>16,ht,pt+(2*bt+0)*f)),Pt=ce,re=Qe}1&xt||(Ot=3*Pt+re+131074>>2,s(g[b+xt-1],255&Ot,Ot>>16,ut,Q+(xt-1)*f),w!=null&&(Ot=3*re+Pt+131074>>2,s(w[y+xt-1],255&Ot,Ot>>16,ht,pt+(xt-1)*f)))}}function Nr(){Hn[is]=Qf,Hn[as]=vl,Hn[cl]=th,Hn[ss]=bl,Hn[os]=wl,Hn[to]=yl,Hn[dl]=eh,Hn[eo]=vl,Hn[no]=bl,Hn[ls]=wl,Hn[ro]=yl}function pa(r){return r&-16384?0>r?0:255:r>>nh}function oi(r,s){return pa((19077*r>>8)+(26149*s>>8)-14234)}function li(r,s,f){return pa((19077*r>>8)-(6419*s>>8)-(13320*f>>8)+8708)}function Rr(r,s){return pa((19077*r>>8)+(33050*s>>8)-17685)}function ui(r,s,f,g,b){g[b+0]=oi(r,f),g[b+1]=li(r,s,f),g[b+2]=Rr(r,s)}function zi(r,s,f,g,b){g[b+0]=Rr(r,s),g[b+1]=li(r,s,f),g[b+2]=oi(r,f)}function Hi(r,s,f,g,b){var w=li(r,s,f);s=w<<3&224|Rr(r,s)>>3,g[b+0]=248&oi(r,f)|w>>5,g[b+1]=s}function cn(r,s,f,g,b){var w=240&Rr(r,s)|15;g[b+0]=240&oi(r,f)|li(r,s,f)>>4,g[b+1]=w}function fi(r,s,f,g,b){g[b+0]=255,ui(r,s,f,g,b+1)}function hi(r,s,f,g,b){zi(r,s,f,g,b),g[b+3]=255}function ga(r,s,f,g,b){ui(r,s,f,g,b),g[b+3]=255}function ur(r,s,f){R[r]=function(g,b,w,y,A,L,C,W,et){for(var F=W+(-2&et)*f;W!=F;)s(g[b+0],w[y+0],A[L+0],C,W),s(g[b+1],w[y+0],A[L+0],C,W+f),b+=2,++y,++L,W+=2*f;1&et&&s(g[b+0],w[y+0],A[L+0],C,W)}}function wn(r,s,f){return f==0?r==0?s==0?6:5:s==0?4:0:f}function ts(r,s,f,g,b){switch(r>>>30){case 3:Lr(s,f,g,b,0);break;case 2:Ur(s,f,g,b);break;case 1:dn(s,f,g,b)}}function Wi(r,s){var f,g,b=s.M,w=s.Nb,y=r.oc,A=r.pc+40,L=r.oc,C=r.pc+584,W=r.oc,et=r.pc+600;for(f=0;16>f;++f)y[A+32*f-1]=129;for(f=0;8>f;++f)L[C+32*f-1]=129,W[et+32*f-1]=129;for(0<b?y[A-1-32]=L[C-1-32]=W[et-1-32]=129:(o(y,A-32-1,127,21),o(L,C-32-1,127,9),o(W,et-32-1,127,9)),g=0;g<r.za;++g){var F=s.ya[s.aa+g];if(0<g){for(f=-1;16>f;++f)i(y,A+32*f-4,y,A+32*f+12,4);for(f=-1;8>f;++f)i(L,C+32*f-4,L,C+32*f+4,4),i(W,et+32*f-4,W,et+32*f+4,4)}var Y=r.Gd,$=r.Hd+g,ut=F.ad,Q=F.Hc;if(0<b&&(i(y,A-32,Y[$].y,0,16),i(L,C-32,Y[$].f,0,8),i(W,et-32,Y[$].ea,0,8)),F.Za){var ht=y,pt=A-32+16;for(0<b&&(g>=r.za-1?o(ht,pt,Y[$].y[15],4):i(ht,pt,Y[$+1].y,0,4)),f=0;4>f;f++)ht[pt+128+f]=ht[pt+256+f]=ht[pt+384+f]=ht[pt+0+f];for(f=0;16>f;++f,Q<<=2)ht=y,pt=A+_l[f],Kn[F.Ob[f]](ht,pt),ts(Q,ut,16*+f,ht,pt)}else if(ht=wn(g,b,F.Ob[0]),zr[ht](y,A),Q!=0)for(f=0;16>f;++f,Q<<=2)ts(Q,ut,16*+f,y,A+_l[f]);for(f=F.Gc,ht=wn(g,b,F.Dd),kr[ht](L,C),kr[ht](W,et),Q=ut,ht=L,pt=C,255&(F=0|f)&&(170&F?Ki(Q,256,ht,pt):hr(Q,256,ht,pt)),F=W,Q=et,255&(f>>=8)&&(170&f?Ki(ut,320,F,Q):hr(ut,320,F,Q)),b<r.Ub-1&&(i(Y[$].y,0,y,A+480,16),i(Y[$].f,0,L,C+224,8),i(Y[$].ea,0,W,et+224,8)),f=8*w*r.B,Y=r.sa,$=r.ta+16*g+16*w*r.R,ut=r.qa,F=r.ra+8*g+f,Q=r.Ha,ht=r.Ia+8*g+f,f=0;16>f;++f)i(Y,$+f*r.R,y,A+32*f,16);for(f=0;8>f;++f)i(ut,F+f*r.B,L,C+32*f,8),i(Q,ht+f*r.B,W,et+32*f,8)}}function es(r,s,f,g,b,w,y,A,L){var C=[0],W=[0],et=0,F=L!=null?L.kd:0,Y=L??new K;if(r==null||12>f)return 7;Y.data=r,Y.w=s,Y.ha=f,s=[s],f=[f],Y.gb=[Y.gb];t:{var $=s,ut=f,Q=Y.gb;if(t(r!=null),t(ut!=null),t(Q!=null),Q[0]=0,12<=ut[0]&&!e(r,$[0],"RIFF")){if(e(r,$[0]+8,"WEBP")){Q=3;break t}var ht=Dt(r,$[0]+4);if(12>ht||4294967286<ht){Q=3;break t}if(F&&ht>ut[0]-8){Q=7;break t}Q[0]=ht,$[0]+=12,ut[0]-=12}Q=0}if(Q!=0)return Q;for(ht=0<Y.gb[0],f=f[0];;){t:{var pt=r;ut=s,Q=f;var xt=C,bt=W,Rt=$=[0];if((Ot=et=[et])[0]=0,8>Q[0])Q=7;else{if(!e(pt,ut[0],"VP8X")){if(Dt(pt,ut[0]+4)!=10){Q=3;break t}if(18>Q[0]){Q=7;break t}var Pt=Dt(pt,ut[0]+8),re=1+St(pt,ut[0]+12);if(2147483648<=re*(pt=1+St(pt,ut[0]+15))){Q=3;break t}Rt!=null&&(Rt[0]=Pt),xt!=null&&(xt[0]=re),bt!=null&&(bt[0]=pt),ut[0]+=18,Q[0]-=18,Ot[0]=1}Q=0}}if(et=et[0],$=$[0],Q!=0)return Q;if(ut=!!(2&$),!ht&&et)return 3;if(w!=null&&(w[0]=!!(16&$)),y!=null&&(y[0]=ut),A!=null&&(A[0]=0),y=C[0],$=W[0],et&&ut&&L==null){Q=0;break}if(4>f){Q=7;break}if(ht&&et||!ht&&!et&&!e(r,s[0],"ALPH")){f=[f],Y.na=[Y.na],Y.P=[Y.P],Y.Sa=[Y.Sa];t:{Pt=r,Q=s,ht=f;var Ot=Y.gb;xt=Y.na,bt=Y.P,Rt=Y.Sa,re=22,t(Pt!=null),t(ht!=null),pt=Q[0];var ce=ht[0];for(t(xt!=null),t(Rt!=null),xt[0]=null,bt[0]=null,Rt[0]=0;;){if(Q[0]=pt,ht[0]=ce,8>ce){Q=7;break t}var Qe=Dt(Pt,pt+4);if(4294967286<Qe){Q=3;break t}var ie=8+Qe+1&-2;if(re+=ie,0<Ot&&re>Ot){Q=3;break t}if(!e(Pt,pt,"VP8 ")||!e(Pt,pt,"VP8L")){Q=0;break t}if(ce[0]<ie){Q=7;break t}e(Pt,pt,"ALPH")||(xt[0]=Pt,bt[0]=pt+8,Rt[0]=Qe),pt+=ie,ce-=ie}}if(f=f[0],Y.na=Y.na[0],Y.P=Y.P[0],Y.Sa=Y.Sa[0],Q!=0)break}f=[f],Y.Ja=[Y.Ja],Y.xa=[Y.xa];t:if(Ot=r,Q=s,ht=f,xt=Y.gb[0],bt=Y.Ja,Rt=Y.xa,Pt=Q[0],pt=!e(Ot,Pt,"VP8 "),re=!e(Ot,Pt,"VP8L"),t(Ot!=null),t(ht!=null),t(bt!=null),t(Rt!=null),8>ht[0])Q=7;else{if(pt||re){if(Ot=Dt(Ot,Pt+4),12<=xt&&Ot>xt-12){Q=3;break t}if(F&&Ot>ht[0]-8){Q=7;break t}bt[0]=Ot,Q[0]+=8,ht[0]-=8,Rt[0]=re}else Rt[0]=5<=ht[0]&&Ot[Pt+0]==47&&!(Ot[Pt+4]>>5),bt[0]=ht[0];Q=0}if(f=f[0],Y.Ja=Y.Ja[0],Y.xa=Y.xa[0],s=s[0],Q!=0)break;if(4294967286<Y.Ja)return 3;if(A==null||ut||(A[0]=Y.xa?2:1),y=[y],$=[$],Y.xa){if(5>f){Q=7;break}A=y,F=$,ut=w,r==null||5>f?r=0:5<=f&&r[s+0]==47&&!(r[s+4]>>5)?(ht=[0],Ot=[0],xt=[0],ct(bt=new B,r,s,f),br(bt,ht,Ot,xt)?(A!=null&&(A[0]=ht[0]),F!=null&&(F[0]=Ot[0]),ut!=null&&(ut[0]=xt[0]),r=1):r=0):r=0}else{if(10>f){Q=7;break}A=$,r==null||10>f||!Va(r,s+3,f-3)?r=0:(F=r[s+0]|r[s+1]<<8|r[s+2]<<16,ut=16383&(r[s+7]<<8|r[s+6]),r=16383&(r[s+9]<<8|r[s+8]),1&F||3<(F>>1&7)||!(F>>4&1)||F>>5>=Y.Ja||!ut||!r?r=0:(y&&(y[0]=ut),A&&(A[0]=r),r=1))}if(!r||(y=y[0],$=$[0],et&&(C[0]!=y||W[0]!=$)))return 3;L!=null&&(L[0]=Y,L.offset=s-L.w,t(4294967286>s-L.w),t(L.offset==L.ha-f));break}return Q==0||Q==7&&et&&L==null?(w!=null&&(w[0]|=Y.na!=null&&0<Y.na.length),g!=null&&(g[0]=y),b!=null&&(b[0]=$),0):Q}function Un(r,s,f){var g=s.width,b=s.height,w=0,y=0,A=g,L=b;if(s.Da=r!=null&&0<r.Da,s.Da&&(A=r.cd,L=r.bd,w=r.v,y=r.j,11>f||(w&=-2,y&=-2),0>w||0>y||0>=A||0>=L||w+A>g||y+L>b))return 0;if(s.v=w,s.j=y,s.va=w+A,s.o=y+L,s.U=A,s.T=L,s.da=r!=null&&0<r.da,s.da){if(!Ht(A,L,f=[r.ib],w=[r.hb]))return 0;s.ib=f[0],s.hb=w[0]}return s.ob=r!=null&&r.ob,s.Kb=r==null||!r.Sd,s.da&&(s.ob=s.ib<3*g/4&&s.hb<3*b/4,s.Kb=0),1}function ci(r){if(r==null)return 2;if(11>r.S){var s=r.f.RGBA;s.fb+=(r.height-1)*s.A,s.A=-s.A}else s=r.f.kb,r=r.height,s.O+=(r-1)*s.fa,s.fa=-s.fa,s.N+=(r-1>>1)*s.Ab,s.Ab=-s.Ab,s.W+=(r-1>>1)*s.Db,s.Db=-s.Db,s.F!=null&&(s.J+=(r-1)*s.lb,s.lb=-s.lb);return 0}function ma(r,s,f,g){if(g==null||0>=r||0>=s)return 2;if(f!=null){if(f.Da){var b=f.cd,w=f.bd,y=-2&f.v,A=-2&f.j;if(0>y||0>A||0>=b||0>=w||y+b>r||A+w>s)return 2;r=b,s=w}if(f.da){if(!Ht(r,s,b=[f.ib],w=[f.hb]))return 2;r=b[0],s=w[0]}}g.width=r,g.height=s;t:{var L=g.width,C=g.height;if(r=g.S,0>=L||0>=C||!(r>=is&&13>r))r=2;else{if(0>=g.Rd&&g.sd==null){y=w=b=s=0;var W=(A=L*Al[r])*C;if(11>r||(w=(C+1)/2*(s=(L+1)/2),r==12&&(y=(b=L)*C)),(C=a(W+2*w+y))==null){r=1;break t}g.sd=C,11>r?((L=g.f.RGBA).eb=C,L.fb=0,L.A=A,L.size=W):((L=g.f.kb).y=C,L.O=0,L.fa=A,L.Fd=W,L.f=C,L.N=0+W,L.Ab=s,L.Cd=w,L.ea=C,L.W=0+W+w,L.Db=s,L.Ed=w,r==12&&(L.F=C,L.J=0+W+2*w),L.Tc=y,L.lb=b)}if(s=1,b=g.S,w=g.width,y=g.height,b>=is&&13>b)if(11>b)r=g.f.RGBA,s&=(A=Math.abs(r.A))*(y-1)+w<=r.size,s&=A>=w*Al[b],s&=r.eb!=null;else{r=g.f.kb,A=(w+1)/2,W=(y+1)/2,L=Math.abs(r.fa),C=Math.abs(r.Ab);var et=Math.abs(r.Db),F=Math.abs(r.lb),Y=F*(y-1)+w;s&=L*(y-1)+w<=r.Fd,s&=C*(W-1)+A<=r.Cd,s=(s&=et*(W-1)+A<=r.Ed)&L>=w&C>=A&et>=A,s&=r.y!=null,s&=r.f!=null,s&=r.ea!=null,b==12&&(s&=F>=w,s&=Y<=r.Tc,s&=r.F!=null)}else s=0;r=s?0:2}}return r!=0||f!=null&&f.fd&&(r=ci(g)),r}var Vi=64,di=[0,1,3,7,15,31,63,127,255,511,1023,2047,4095,8191,16383,32767,65535,131071,262143,524287,1048575,2097151,4194303,8388607,16777215],va=24,yn=32,Nn=8,Gi=[0,0,1,1,2,2,2,2,3,3,3,3,3,3,3,3,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,4,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7,7];Ct("Predictor0","PredictorAdd0"),R.Predictor0=function(){return 4278190080},R.Predictor1=function(r){return r},R.Predictor2=function(r,s,f){return s[f+0]},R.Predictor3=function(r,s,f){return s[f+1]},R.Predictor4=function(r,s,f){return s[f-1]},R.Predictor5=function(r,s,f){return qt(qt(r,s[f+1]),s[f+0])},R.Predictor6=function(r,s,f){return qt(r,s[f-1])},R.Predictor7=function(r,s,f){return qt(r,s[f+0])},R.Predictor8=function(r,s,f){return qt(s[f-1],s[f+0])},R.Predictor9=function(r,s,f){return qt(s[f+0],s[f+1])},R.Predictor10=function(r,s,f){return qt(qt(r,s[f-1]),qt(s[f+0],s[f+1]))},R.Predictor11=function(r,s,f){var g=s[f+0];return 0>=Zt(g>>24&255,r>>24&255,(s=s[f-1])>>24&255)+Zt(g>>16&255,r>>16&255,s>>16&255)+Zt(g>>8&255,r>>8&255,s>>8&255)+Zt(255&g,255&r,255&s)?g:r},R.Predictor12=function(r,s,f){var g=s[f+0];return(ve((r>>24&255)+(g>>24&255)-((s=s[f-1])>>24&255))<<24|ve((r>>16&255)+(g>>16&255)-(s>>16&255))<<16|ve((r>>8&255)+(g>>8&255)-(s>>8&255))<<8|ve((255&r)+(255&g)-(255&s)))>>>0},R.Predictor13=function(r,s,f){var g=s[f-1];return(ue((r=qt(r,s[f+0]))>>24&255,g>>24&255)<<24|ue(r>>16&255,g>>16&255)<<16|ue(r>>8&255,g>>8&255)<<8|ue(255&r,255&g))>>>0};var Tr=R.PredictorAdd0;R.PredictorAdd1=he,Ct("Predictor2","PredictorAdd2"),Ct("Predictor3","PredictorAdd3"),Ct("Predictor4","PredictorAdd4"),Ct("Predictor5","PredictorAdd5"),Ct("Predictor6","PredictorAdd6"),Ct("Predictor7","PredictorAdd7"),Ct("Predictor8","PredictorAdd8"),Ct("Predictor9","PredictorAdd9"),Ct("Predictor10","PredictorAdd10"),Ct("Predictor11","PredictorAdd11"),Ct("Predictor12","PredictorAdd12"),Ct("Predictor13","PredictorAdd13");var Dr=R.PredictorAdd2;Tt("ColorIndexInverseTransform","MapARGB","32b",function(r){return r>>8&255},function(r){return r}),Tt("VP8LColorIndexInverseTransformAlpha","MapAlpha","8b",function(r){return r},function(r){return r>>8&255});var Yi,pi=R.ColorIndexInverseTransform,$e=R.MapARGB,Zs=R.VP8LColorIndexInverseTransformAlpha,fr=R.MapAlpha,Jn=R.VP8LPredictorsAdd=[];Jn.length=16,(R.VP8LPredictors=[]).length=16,(R.VP8LPredictorsAdd_C=[]).length=16,(R.VP8LPredictors_C=[]).length=16;var gi,ba,wa,Ji,mi,vi,qr,Lr,Ur,Ki,dn,hr,ke,Pe,He,Ze,Sr,ya,Xi,ns,tl,el,nl,rl,xa,il,al,sl,ol=a(511),ll=a(2041),ul=a(225),fl=a(767),hl=0,Qs=ll,rs=ul,In=fl,zn=ol,is=0,as=1,cl=2,ss=3,os=4,to=5,dl=6,eo=7,no=8,ls=9,ro=10,Df=[2,3,7],qf=[3,3,11],pl=[280,256,256,256,40],Uf=[0,1,1,1,0],zf=[17,18,0,1,2,3,4,5,16,6,7,8,9,10,11,12,13,14,15],Hf=[24,7,23,25,40,6,39,41,22,26,38,42,56,5,55,57,21,27,54,58,37,43,72,4,71,73,20,28,53,59,70,74,36,44,88,69,75,52,60,3,87,89,19,29,86,90,35,45,68,76,85,91,51,61,104,2,103,105,18,30,102,106,34,46,84,92,67,77,101,107,50,62,120,1,119,121,83,93,17,31,100,108,66,78,118,122,33,47,117,123,49,63,99,109,82,94,0,116,124,65,79,16,32,98,110,48,115,125,81,95,64,114,126,97,111,80,113,127,96,112],Wf=[2954,2956,2958,2962,2970,2986,3018,3082,3212,3468,3980,5004],Vf=8,io=[4,5,6,7,8,9,10,10,11,12,13,14,15,16,17,17,18,19,20,20,21,21,22,22,23,23,24,25,25,26,27,28,29,30,31,32,33,34,35,36,37,37,38,39,40,41,42,43,44,45,46,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,76,77,78,79,80,81,82,83,84,85,86,87,88,89,91,93,95,96,98,100,101,102,104,106,108,110,112,114,116,118,122,124,126,128,130,132,134,136,138,140,143,145,148,151,154,157],ao=[4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,60,62,64,66,68,70,72,74,76,78,80,82,84,86,88,90,92,94,96,98,100,102,104,106,108,110,112,114,116,119,122,125,128,131,134,137,140,143,146,149,152,155,158,161,164,167,170,173,177,181,185,189,193,197,201,205,209,213,217,221,225,229,234,239,245,249,254,259,264,269,274,279,284],_a=null,Gf=[[173,148,140,0],[176,155,140,135,0],[180,157,141,134,130,0],[254,254,243,230,196,177,153,140,133,130,129,0]],Yf=[0,1,4,8,5,2,3,6,9,12,13,10,7,11,14,15],gl=[-0,1,-1,2,-2,3,4,6,-3,5,-4,-5,-6,7,-7,8,-8,-9],Jf=[[[[128,128,128,128,128,128,128,128,128,128,128],[128,128,128,128,128,128,128,128,128,128,128],[128,128,128,128,128,128,128,128,128,128,128]],[[253,136,254,255,228,219,128,128,128,128,128],[189,129,242,255,227,213,255,219,128,128,128],[106,126,227,252,214,209,255,255,128,128,128]],[[1,98,248,255,236,226,255,255,128,128,128],[181,133,238,254,221,234,255,154,128,128,128],[78,134,202,247,198,180,255,219,128,128,128]],[[1,185,249,255,243,255,128,128,128,128,128],[184,150,247,255,236,224,128,128,128,128,128],[77,110,216,255,236,230,128,128,128,128,128]],[[1,101,251,255,241,255,128,128,128,128,128],[170,139,241,252,236,209,255,255,128,128,128],[37,116,196,243,228,255,255,255,128,128,128]],[[1,204,254,255,245,255,128,128,128,128,128],[207,160,250,255,238,128,128,128,128,128,128],[102,103,231,255,211,171,128,128,128,128,128]],[[1,152,252,255,240,255,128,128,128,128,128],[177,135,243,255,234,225,128,128,128,128,128],[80,129,211,255,194,224,128,128,128,128,128]],[[1,1,255,128,128,128,128,128,128,128,128],[246,1,255,128,128,128,128,128,128,128,128],[255,128,128,128,128,128,128,128,128,128,128]]],[[[198,35,237,223,193,187,162,160,145,155,62],[131,45,198,221,172,176,220,157,252,221,1],[68,47,146,208,149,167,221,162,255,223,128]],[[1,149,241,255,221,224,255,255,128,128,128],[184,141,234,253,222,220,255,199,128,128,128],[81,99,181,242,176,190,249,202,255,255,128]],[[1,129,232,253,214,197,242,196,255,255,128],[99,121,210,250,201,198,255,202,128,128,128],[23,91,163,242,170,187,247,210,255,255,128]],[[1,200,246,255,234,255,128,128,128,128,128],[109,178,241,255,231,245,255,255,128,128,128],[44,130,201,253,205,192,255,255,128,128,128]],[[1,132,239,251,219,209,255,165,128,128,128],[94,136,225,251,218,190,255,255,128,128,128],[22,100,174,245,186,161,255,199,128,128,128]],[[1,182,249,255,232,235,128,128,128,128,128],[124,143,241,255,227,234,128,128,128,128,128],[35,77,181,251,193,211,255,205,128,128,128]],[[1,157,247,255,236,231,255,255,128,128,128],[121,141,235,255,225,227,255,255,128,128,128],[45,99,188,251,195,217,255,224,128,128,128]],[[1,1,251,255,213,255,128,128,128,128,128],[203,1,248,255,255,128,128,128,128,128,128],[137,1,177,255,224,255,128,128,128,128,128]]],[[[253,9,248,251,207,208,255,192,128,128,128],[175,13,224,243,193,185,249,198,255,255,128],[73,17,171,221,161,179,236,167,255,234,128]],[[1,95,247,253,212,183,255,255,128,128,128],[239,90,244,250,211,209,255,255,128,128,128],[155,77,195,248,188,195,255,255,128,128,128]],[[1,24,239,251,218,219,255,205,128,128,128],[201,51,219,255,196,186,128,128,128,128,128],[69,46,190,239,201,218,255,228,128,128,128]],[[1,191,251,255,255,128,128,128,128,128,128],[223,165,249,255,213,255,128,128,128,128,128],[141,124,248,255,255,128,128,128,128,128,128]],[[1,16,248,255,255,128,128,128,128,128,128],[190,36,230,255,236,255,128,128,128,128,128],[149,1,255,128,128,128,128,128,128,128,128]],[[1,226,255,128,128,128,128,128,128,128,128],[247,192,255,128,128,128,128,128,128,128,128],[240,128,255,128,128,128,128,128,128,128,128]],[[1,134,252,255,255,128,128,128,128,128,128],[213,62,250,255,255,128,128,128,128,128,128],[55,93,255,128,128,128,128,128,128,128,128]],[[128,128,128,128,128,128,128,128,128,128,128],[128,128,128,128,128,128,128,128,128,128,128],[128,128,128,128,128,128,128,128,128,128,128]]],[[[202,24,213,235,186,191,220,160,240,175,255],[126,38,182,232,169,184,228,174,255,187,128],[61,46,138,219,151,178,240,170,255,216,128]],[[1,112,230,250,199,191,247,159,255,255,128],[166,109,228,252,211,215,255,174,128,128,128],[39,77,162,232,172,180,245,178,255,255,128]],[[1,52,220,246,198,199,249,220,255,255,128],[124,74,191,243,183,193,250,221,255,255,128],[24,71,130,219,154,170,243,182,255,255,128]],[[1,182,225,249,219,240,255,224,128,128,128],[149,150,226,252,216,205,255,171,128,128,128],[28,108,170,242,183,194,254,223,255,255,128]],[[1,81,230,252,204,203,255,192,128,128,128],[123,102,209,247,188,196,255,233,128,128,128],[20,95,153,243,164,173,255,203,128,128,128]],[[1,222,248,255,216,213,128,128,128,128,128],[168,175,246,252,235,205,255,255,128,128,128],[47,116,215,255,211,212,255,255,128,128,128]],[[1,121,236,253,212,214,255,255,128,128,128],[141,84,213,252,201,202,255,219,128,128,128],[42,80,160,240,162,185,255,205,128,128,128]],[[1,1,255,128,128,128,128,128,128,128,128],[244,1,255,128,128,128,128,128,128,128,128],[238,1,255,128,128,128,128,128,128,128,128]]]],Kf=[[[231,120,48,89,115,113,120,152,112],[152,179,64,126,170,118,46,70,95],[175,69,143,80,85,82,72,155,103],[56,58,10,171,218,189,17,13,152],[114,26,17,163,44,195,21,10,173],[121,24,80,195,26,62,44,64,85],[144,71,10,38,171,213,144,34,26],[170,46,55,19,136,160,33,206,71],[63,20,8,114,114,208,12,9,226],[81,40,11,96,182,84,29,16,36]],[[134,183,89,137,98,101,106,165,148],[72,187,100,130,157,111,32,75,80],[66,102,167,99,74,62,40,234,128],[41,53,9,178,241,141,26,8,107],[74,43,26,146,73,166,49,23,157],[65,38,105,160,51,52,31,115,128],[104,79,12,27,217,255,87,17,7],[87,68,71,44,114,51,15,186,23],[47,41,14,110,182,183,21,17,194],[66,45,25,102,197,189,23,18,22]],[[88,88,147,150,42,46,45,196,205],[43,97,183,117,85,38,35,179,61],[39,53,200,87,26,21,43,232,171],[56,34,51,104,114,102,29,93,77],[39,28,85,171,58,165,90,98,64],[34,22,116,206,23,34,43,166,73],[107,54,32,26,51,1,81,43,31],[68,25,106,22,64,171,36,225,114],[34,19,21,102,132,188,16,76,124],[62,18,78,95,85,57,50,48,51]],[[193,101,35,159,215,111,89,46,111],[60,148,31,172,219,228,21,18,111],[112,113,77,85,179,255,38,120,114],[40,42,1,196,245,209,10,25,109],[88,43,29,140,166,213,37,43,154],[61,63,30,155,67,45,68,1,209],[100,80,8,43,154,1,51,26,71],[142,78,78,16,255,128,34,197,171],[41,40,5,102,211,183,4,1,221],[51,50,17,168,209,192,23,25,82]],[[138,31,36,171,27,166,38,44,229],[67,87,58,169,82,115,26,59,179],[63,59,90,180,59,166,93,73,154],[40,40,21,116,143,209,34,39,175],[47,15,16,183,34,223,49,45,183],[46,17,33,183,6,98,15,32,183],[57,46,22,24,128,1,54,17,37],[65,32,73,115,28,128,23,128,205],[40,3,9,115,51,192,18,6,223],[87,37,9,115,59,77,64,21,47]],[[104,55,44,218,9,54,53,130,226],[64,90,70,205,40,41,23,26,57],[54,57,112,184,5,41,38,166,213],[30,34,26,133,152,116,10,32,134],[39,19,53,221,26,114,32,73,255],[31,9,65,234,2,15,1,118,73],[75,32,12,51,192,255,160,43,51],[88,31,35,67,102,85,55,186,85],[56,21,23,111,59,205,45,37,192],[55,38,70,124,73,102,1,34,98]],[[125,98,42,88,104,85,117,175,82],[95,84,53,89,128,100,113,101,45],[75,79,123,47,51,128,81,171,1],[57,17,5,71,102,57,53,41,49],[38,33,13,121,57,73,26,1,85],[41,10,67,138,77,110,90,47,114],[115,21,2,10,102,255,166,23,6],[101,29,16,10,85,128,101,196,26],[57,18,10,102,102,213,34,20,43],[117,20,15,36,163,128,68,1,26]],[[102,61,71,37,34,53,31,243,192],[69,60,71,38,73,119,28,222,37],[68,45,128,34,1,47,11,245,171],[62,17,19,70,146,85,55,62,70],[37,43,37,154,100,163,85,160,1],[63,9,92,136,28,64,32,201,85],[75,15,9,9,64,255,184,119,16],[86,6,28,5,64,255,25,248,1],[56,8,17,132,137,255,55,116,128],[58,15,20,82,135,57,26,121,40]],[[164,50,31,137,154,133,25,35,218],[51,103,44,131,131,123,31,6,158],[86,40,64,135,148,224,45,183,128],[22,26,17,131,240,154,14,1,209],[45,16,21,91,64,222,7,1,197],[56,21,39,155,60,138,23,102,213],[83,12,13,54,192,255,68,47,28],[85,26,85,85,128,128,32,146,171],[18,11,7,63,144,171,4,4,246],[35,27,10,146,174,171,12,26,128]],[[190,80,35,99,180,80,126,54,45],[85,126,47,87,176,51,41,20,32],[101,75,128,139,118,146,116,128,85],[56,41,15,176,236,85,37,9,62],[71,30,17,119,118,255,17,18,138],[101,38,60,138,55,70,43,26,142],[146,36,19,30,171,255,97,27,20],[138,45,61,62,219,1,81,188,64],[32,41,20,117,151,142,20,21,163],[112,19,12,61,195,128,48,4,24]]],Xf=[[[[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[176,246,255,255,255,255,255,255,255,255,255],[223,241,252,255,255,255,255,255,255,255,255],[249,253,253,255,255,255,255,255,255,255,255]],[[255,244,252,255,255,255,255,255,255,255,255],[234,254,254,255,255,255,255,255,255,255,255],[253,255,255,255,255,255,255,255,255,255,255]],[[255,246,254,255,255,255,255,255,255,255,255],[239,253,254,255,255,255,255,255,255,255,255],[254,255,254,255,255,255,255,255,255,255,255]],[[255,248,254,255,255,255,255,255,255,255,255],[251,255,254,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[255,253,254,255,255,255,255,255,255,255,255],[251,254,254,255,255,255,255,255,255,255,255],[254,255,254,255,255,255,255,255,255,255,255]],[[255,254,253,255,254,255,255,255,255,255,255],[250,255,254,255,254,255,255,255,255,255,255],[254,255,255,255,255,255,255,255,255,255,255]],[[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]]],[[[217,255,255,255,255,255,255,255,255,255,255],[225,252,241,253,255,255,254,255,255,255,255],[234,250,241,250,253,255,253,254,255,255,255]],[[255,254,255,255,255,255,255,255,255,255,255],[223,254,254,255,255,255,255,255,255,255,255],[238,253,254,254,255,255,255,255,255,255,255]],[[255,248,254,255,255,255,255,255,255,255,255],[249,254,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[255,253,255,255,255,255,255,255,255,255,255],[247,254,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[255,253,254,255,255,255,255,255,255,255,255],[252,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[255,254,254,255,255,255,255,255,255,255,255],[253,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[255,254,253,255,255,255,255,255,255,255,255],[250,255,255,255,255,255,255,255,255,255,255],[254,255,255,255,255,255,255,255,255,255,255]],[[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]]],[[[186,251,250,255,255,255,255,255,255,255,255],[234,251,244,254,255,255,255,255,255,255,255],[251,251,243,253,254,255,254,255,255,255,255]],[[255,253,254,255,255,255,255,255,255,255,255],[236,253,254,255,255,255,255,255,255,255,255],[251,253,253,254,254,255,255,255,255,255,255]],[[255,254,254,255,255,255,255,255,255,255,255],[254,254,254,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[255,254,255,255,255,255,255,255,255,255,255],[254,254,255,255,255,255,255,255,255,255,255],[254,255,255,255,255,255,255,255,255,255,255]],[[255,255,255,255,255,255,255,255,255,255,255],[254,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]]],[[[248,255,255,255,255,255,255,255,255,255,255],[250,254,252,254,255,255,255,255,255,255,255],[248,254,249,253,255,255,255,255,255,255,255]],[[255,253,253,255,255,255,255,255,255,255,255],[246,253,253,255,255,255,255,255,255,255,255],[252,254,251,254,254,255,255,255,255,255,255]],[[255,254,252,255,255,255,255,255,255,255,255],[248,254,253,255,255,255,255,255,255,255,255],[253,255,254,254,255,255,255,255,255,255,255]],[[255,251,254,255,255,255,255,255,255,255,255],[245,251,254,255,255,255,255,255,255,255,255],[253,253,254,255,255,255,255,255,255,255,255]],[[255,251,253,255,255,255,255,255,255,255,255],[252,253,254,255,255,255,255,255,255,255,255],[255,254,255,255,255,255,255,255,255,255,255]],[[255,252,255,255,255,255,255,255,255,255,255],[249,255,254,255,255,255,255,255,255,255,255],[255,255,254,255,255,255,255,255,255,255,255]],[[255,255,253,255,255,255,255,255,255,255,255],[250,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]],[[255,255,255,255,255,255,255,255,255,255,255],[254,255,255,255,255,255,255,255,255,255,255],[255,255,255,255,255,255,255,255,255,255,255]]]],$f=[0,1,2,3,6,4,5,6,6,6,6,6,6,6,6,7,0],zr=[],Kn=[],kr=[],Zf=1,ml=2,Hr=[],Hn=[];hn("UpsampleRgbLinePair",ui,3),hn("UpsampleBgrLinePair",zi,3),hn("UpsampleRgbaLinePair",ga,4),hn("UpsampleBgraLinePair",hi,4),hn("UpsampleArgbLinePair",fi,4),hn("UpsampleRgba4444LinePair",cn,2),hn("UpsampleRgb565LinePair",Hi,2);var Qf=R.UpsampleRgbLinePair,th=R.UpsampleBgrLinePair,vl=R.UpsampleRgbaLinePair,bl=R.UpsampleBgraLinePair,wl=R.UpsampleArgbLinePair,yl=R.UpsampleRgba4444LinePair,eh=R.UpsampleRgb565LinePair,us=16,fs=1<<us-1,Aa=-227,so=482,nh=6,xl=0,rh=a(256),ih=a(256),ah=a(256),sh=a(256),oh=a(so-Aa),lh=a(so-Aa);ur("YuvToRgbRow",ui,3),ur("YuvToBgrRow",zi,3),ur("YuvToRgbaRow",ga,4),ur("YuvToBgraRow",hi,4),ur("YuvToArgbRow",fi,4),ur("YuvToRgba4444Row",cn,2),ur("YuvToRgb565Row",Hi,2);var _l=[0,4,8,12,128,132,136,140,256,260,264,268,384,388,392,396],hs=[0,2,8],uh=[8,7,6,4,4,2,2,2,1,1,1,1],fh=1;this.WebPDecodeRGBA=function(r,s,f,g,b){var w=as,y=new D,A=new le;y.ba=A,A.S=w,A.width=[A.width],A.height=[A.height];var L=A.width,C=A.height,W=new Vt;if(W==null||r==null)var et=2;else t(W!=null),et=es(r,s,f,W.width,W.height,W.Pd,W.Qd,W.format,null);if(et!=0?L=0:(L!=null&&(L[0]=W.width[0]),C!=null&&(C[0]=W.height[0]),L=1),L){A.width=A.width[0],A.height=A.height[0],g!=null&&(g[0]=A.width),b!=null&&(b[0]=A.height);t:{if(g=new Oi,(b=new K).data=r,b.w=s,b.ha=f,b.kd=1,s=[0],t(b!=null),((r=es(b.data,b.w,b.ha,null,null,null,s,null,b))==0||r==7)&&s[0]&&(r=4),(s=r)==0){if(t(y!=null),g.data=b.data,g.w=b.w+b.offset,g.ha=b.ha-b.offset,g.put=Gt,g.ac=nr,g.bc=vr,g.ma=y,b.xa){if((r=ni())==null){y=1;break t}if((function(F,Y){var $=[0],ut=[0],Q=[0];e:for(;;){if(F==null)return 0;if(Y==null)return F.a=2,0;if(F.l=Y,F.a=0,ct(F.m,Y.data,Y.w,Y.ha),!br(F.m,$,ut,Q)){F.a=3;break e}if(F.xb=ml,Y.width=$[0],Y.height=ut[0],!ir($[0],ut[0],1,F,null))break e;return 1}return t(F.a!=0),0})(r,g)){if(g=(s=ma(g.width,g.height,y.Oa,y.ba))==0){e:{g=r;n:for(;;){if(g==null){g=0;break e}if(t(g.s.yc!=null),t(g.s.Ya!=null),t(0<g.s.Wb),t((f=g.l)!=null),t((b=f.ma)!=null),g.xb!=0){if(g.ca=b.ba,g.tb=b.tb,t(g.ca!=null),!Un(b.Oa,f,ss)){g.a=2;break n}if(!ri(g,f.width)||f.da)break n;if((f.da||Yt(g.ca.S))&&Re(),11>g.ca.S||(alert("todo:WebPInitConvertARGBToYUV"),g.ca.f.kb.F!=null&&Re()),g.Pb&&0<g.s.ua&&g.s.vb.X==null&&!P(g.s.vb,g.s.Wa.Xa)){g.a=1;break n}g.xb=0}if(!Yn(g,g.V,g.Ba,g.c,g.i,f.o,Or))break n;b.Dc=g.Ma,g=1;break e}t(g.a!=0),g=0}g=!g}g&&(s=r.a)}else s=r.a}else{if((r=new Bs)==null){y=1;break t}if(r.Fa=b.na,r.P=b.P,r.qc=b.Sa,sr(r,g)){if((s=ma(g.width,g.height,y.Oa,y.ba))==0){if(r.Aa=0,f=y.Oa,t((b=r)!=null),f!=null){if(0<(L=0>(L=f.Md)?0:100<L?255:255*L/100)){for(C=W=0;4>C;++C)12>(et=b.pb[C]).lc&&(et.ia=L*uh[0>et.lc?0:et.lc]>>3),W|=et.ia;W&&(alert("todo:VP8InitRandom"),b.ia=1)}b.Ga=f.Id,100<b.Ga?b.Ga=100:0>b.Ga&&(b.Ga=0)}(function(F,Y){if(F==null)return 0;if(Y==null)return Ke(F,2,"NULL VP8Io parameter in VP8Decode().");if(!F.cb&&!sr(F,Y))return 0;if(t(F.cb),Y.ac==null||Y.ac(Y)){Y.ob&&(F.L=0);var $=hs[F.L];if(F.L==2?(F.yb=0,F.zb=0):(F.yb=Y.v-$>>4,F.zb=Y.j-$>>4,0>F.yb&&(F.yb=0),0>F.zb&&(F.zb=0)),F.Va=Y.o+15+$>>4,F.Hb=Y.va+15+$>>4,F.Hb>F.za&&(F.Hb=F.za),F.Va>F.Ub&&(F.Va=F.Ub),0<F.L){var ut=F.ed;for($=0;4>$;++$){var Q;if(F.Qa.Cb){var ht=F.Qa.Lb[$];F.Qa.Fb||(ht+=ut.Tb)}else ht=ut.Tb;for(Q=0;1>=Q;++Q){var pt=F.gd[$][Q],xt=ht;if(ut.Pc&&(xt+=ut.vd[0],Q&&(xt+=ut.od[0])),0<(xt=0>xt?0:63<xt?63:xt)){var bt=xt;0<ut.wb&&(bt=4<ut.wb?bt>>2:bt>>1)>9-ut.wb&&(bt=9-ut.wb),1>bt&&(bt=1),pt.dd=bt,pt.tc=2*xt+bt,pt.ld=40<=xt?2:15<=xt?1:0}else pt.tc=0;pt.La=Q}}}$=0}else Ke(F,6,"Frame setup failed"),$=F.a;if($=$==0){if($){F.$c=0,0<F.Aa||(F.Ic=fh);e:{$=F.Ic,ut=4*(bt=F.za);var Rt=32*bt,Pt=bt+1,re=0<F.L?bt*(0<F.Aa?2:1):0,Ot=(F.Aa==2?2:1)*bt;if((pt=ut+832+(Q=3*(16*$+hs[F.L])/2*Rt)+(ht=F.Fa!=null&&0<F.Fa.length?F.Kc.c*F.Kc.i:0))!=pt)$=0;else{if(pt>F.Vb){if(F.Vb=0,F.Ec=a(pt),F.Fc=0,F.Ec==null){$=Ke(F,1,"no memory during frame initialization.");break e}F.Vb=pt}pt=F.Ec,xt=F.Fc,F.Ac=pt,F.Bc=xt,xt+=ut,F.Gd=c(Rt,Ha),F.Hd=0,F.rb=c(Pt+1,aa),F.sb=1,F.wa=re?c(re,qn):null,F.Y=0,F.D.Nb=0,F.D.wa=F.wa,F.D.Y=F.Y,0<F.Aa&&(F.D.Y+=bt),t(!0),F.oc=pt,F.pc=xt,xt+=832,F.ya=c(Ot,sa),F.aa=0,F.D.ya=F.ya,F.D.aa=F.aa,F.Aa==2&&(F.D.aa+=bt),F.R=16*bt,F.B=8*bt,bt=(Rt=hs[F.L])*F.R,Rt=Rt/2*F.B,F.sa=pt,F.ta=xt+bt,F.qa=F.sa,F.ra=F.ta+16*$*F.R+Rt,F.Ha=F.qa,F.Ia=F.ra+8*$*F.B+Rt,F.$c=0,xt+=Q,F.mb=ht?pt:null,F.nb=ht?xt:null,t(xt+ht<=F.Fc+F.Vb),oa(F),o(F.Ac,F.Bc,0,ut),$=1}}if($){if(Y.ka=0,Y.y=F.sa,Y.O=F.ta,Y.f=F.qa,Y.N=F.ra,Y.ea=F.Ha,Y.Vd=F.Ia,Y.fa=F.R,Y.Rc=F.B,Y.F=null,Y.J=0,!hl){for($=-255;255>=$;++$)ol[255+$]=0>$?-$:$;for($=-1020;1020>=$;++$)ll[1020+$]=-128>$?-128:127<$?127:$;for($=-112;112>=$;++$)ul[112+$]=-16>$?-16:15<$?15:$;for($=-255;510>=$;++$)fl[255+$]=0>$?0:255<$?255:$;hl=1}qr=Ya,Lr=Ms,Ki=Rs,dn=Ts,hr=or,Ur=Ga,ke=Xa,Pe=$a,He=Qa,Ze=u,Sr=Za,ya=si,Xi=v,ns=I,tl=qi,el=da,nl=Ui,rl=Ka,Kn[0]=Vs,Kn[1]=Ri,Kn[2]=Hs,Kn[3]=Ws,Kn[4]=Gs,Kn[5]=yr,Kn[6]=Ys,Kn[7]=xr,Kn[8]=Ks,Kn[9]=Js,zr[0]=Ja,zr[1]=Ds,zr[2]=qs,zr[3]=Us,zr[4]=Br,zr[5]=zs,zr[6]=ii,kr[0]=Xs,kr[1]=la,kr[2]=Ti,kr[3]=ua,kr[4]=$s,kr[5]=Di,kr[6]=fa,$=1}else $=0}$&&($=(function(ce,Qe){for(ce.M=0;ce.M<ce.Va;++ce.M){var ie,jt=ce.Jc[ce.M&ce.Xb],Nt=ce.m,We=ce;for(ie=0;ie<We.za;++ie){var ee=Nt,pe=We,Fe=pe.Ac,on=pe.Bc+4*ie,xn=pe.zc,De=pe.ya[pe.aa+ie];if(pe.Qa.Bb?De.$b=gt(ee,pe.Pa.jb[0])?2+gt(ee,pe.Pa.jb[2]):gt(ee,pe.Pa.jb[1]):De.$b=0,pe.kc&&(De.Ad=gt(ee,pe.Bd)),De.Za=!gt(ee,145)+0,De.Za){var pn=De.Ob,_n=0;for(pe=0;4>pe;++pe){var tn,me=xn[0+pe];for(tn=0;4>tn;++tn){me=Kf[Fe[on+tn]][me];for(var we=gl[gt(ee,me[0])];0<we;)we=gl[2*we+gt(ee,me[we])];me=-we,Fe[on+tn]=me}i(pn,_n,Fe,on,4),_n+=4,xn[0+pe]=me}}else me=gt(ee,156)?gt(ee,128)?1:3:gt(ee,163)?2:0,De.Ob[0]=me,o(Fe,on,me,4),o(xn,0,me,4);De.Dd=gt(ee,142)?gt(ee,114)?gt(ee,183)?1:3:2:0}if(We.m.Ka)return Ke(ce,7,"Premature end-of-partition0 encountered.");for(;ce.ja<ce.za;++ce.ja){if(We=jt,ee=(Nt=ce).rb[Nt.sb-1],Fe=Nt.rb[Nt.sb+Nt.ja],ie=Nt.ya[Nt.aa+Nt.ja],on=Nt.kc?ie.Ad:0)ee.la=Fe.la=0,ie.Za||(ee.Na=Fe.Na=0),ie.Hc=0,ie.Gc=0,ie.ia=0;else{var qe,ye;if(ee=Fe,Fe=We,on=Nt.Pa.Xc,xn=Nt.ya[Nt.aa+Nt.ja],De=Nt.pb[xn.$b],pe=xn.ad,pn=0,_n=Nt.rb[Nt.sb-1],me=tn=0,o(pe,pn,0,384),xn.Za)var ln=0,Xn=on[3];else{we=a(16);var Ve=ee.Na+_n.Na;if(Ve=_a(Fe,on[1],Ve,De.Eb,0,we,0),ee.Na=_n.Na=(0<Ve)+0,1<Ve)qr(we,0,pe,pn);else{var Ln=we[0]+3>>3;for(we=0;256>we;we+=16)pe[pn+we]=Ln}ln=1,Xn=on[0]}var Ne=15&ee.la,en=15&_n.la;for(we=0;4>we;++we){var Cn=1&en;for(Ln=ye=0;4>Ln;++Ln)Ne=Ne>>1|(Cn=(Ve=_a(Fe,Xn,Ve=Cn+(1&Ne),De.Sc,ln,pe,pn))>ln)<<7,ye=ye<<2|(3<Ve?3:1<Ve?2:pe[pn+0]!=0),pn+=16;Ne>>=4,en=en>>1|Cn<<7,tn=(tn<<8|ye)>>>0}for(Xn=Ne,ln=en>>4,qe=0;4>qe;qe+=2){for(ye=0,Ne=ee.la>>4+qe,en=_n.la>>4+qe,we=0;2>we;++we){for(Cn=1&en,Ln=0;2>Ln;++Ln)Ve=Cn+(1&Ne),Ne=Ne>>1|(Cn=0<(Ve=_a(Fe,on[2],Ve,De.Qc,0,pe,pn)))<<3,ye=ye<<2|(3<Ve?3:1<Ve?2:pe[pn+0]!=0),pn+=16;Ne>>=2,en=en>>1|Cn<<5}me|=ye<<4*qe,Xn|=Ne<<4<<qe,ln|=(240&en)<<qe}ee.la=Xn,_n.la=ln,xn.Hc=tn,xn.Gc=me,xn.ia=43690&me?0:De.ia,on=!(tn|me)}if(0<Nt.L&&(Nt.wa[Nt.Y+Nt.ja]=Nt.gd[ie.$b][ie.Za],Nt.wa[Nt.Y+Nt.ja].La|=!on),We.Ka)return Ke(ce,7,"Premature end-of-file encountered.")}if(oa(ce),Nt=Qe,We=1,ie=(jt=ce).D,ee=0<jt.L&&jt.M>=jt.zb&&jt.M<=jt.Va,jt.Aa==0)e:{if(ie.M=jt.M,ie.uc=ee,Wi(jt,ie),We=1,ie=(ye=jt.D).Nb,ee=(me=hs[jt.L])*jt.R,Fe=me/2*jt.B,we=16*ie*jt.R,Ln=8*ie*jt.B,on=jt.sa,xn=jt.ta-ee+we,De=jt.qa,pe=jt.ra-Fe+Ln,pn=jt.Ha,_n=jt.Ia-Fe+Ln,en=(Ne=ye.M)==0,tn=Ne>=jt.Va-1,jt.Aa==2&&Wi(jt,ye),ye.uc)for(Cn=(Ve=jt).D.M,t(Ve.D.uc),ye=Ve.yb;ye<Ve.Hb;++ye){ln=ye,Xn=Cn;var An=(Fn=(un=Ve).D).Nb;qe=un.R;var Fn=Fn.wa[Fn.Y+ln],En=un.sa,Sn=un.ta+16*An*qe+16*ln,On=Fn.dd,Ie=Fn.tc;if(Ie!=0)if(t(3<=Ie),un.L==1)0<ln&&el(En,Sn,qe,Ie+4),Fn.La&&rl(En,Sn,qe,Ie),0<Xn&&tl(En,Sn,qe,Ie+4),Fn.La&&nl(En,Sn,qe,Ie);else{var jn=un.B,$n=un.qa,bi=un.ra+8*An*jn+8*ln,Pr=un.Ha,un=un.Ia+8*An*jn+8*ln;An=Fn.ld,0<ln&&(Pe(En,Sn,qe,Ie+4,On,An),Ze($n,bi,Pr,un,jn,Ie+4,On,An)),Fn.La&&(ya(En,Sn,qe,Ie,On,An),ns($n,bi,Pr,un,jn,Ie,On,An)),0<Xn&&(ke(En,Sn,qe,Ie+4,On,An),He($n,bi,Pr,un,jn,Ie+4,On,An)),Fn.La&&(Sr(En,Sn,qe,Ie,On,An),Xi($n,bi,Pr,un,jn,Ie,On,An))}}if(jt.ia&&alert("todo:DitherRow"),Nt.put!=null){if(ye=16*Ne,Ne=16*(Ne+1),en?(Nt.y=jt.sa,Nt.O=jt.ta+we,Nt.f=jt.qa,Nt.N=jt.ra+Ln,Nt.ea=jt.Ha,Nt.W=jt.Ia+Ln):(ye-=me,Nt.y=on,Nt.O=xn,Nt.f=De,Nt.N=pe,Nt.ea=pn,Nt.W=_n),tn||(Ne-=me),Ne>Nt.o&&(Ne=Nt.o),Nt.F=null,Nt.J=null,jt.Fa!=null&&0<jt.Fa.length&&ye<Ne&&(Nt.J=Xe(jt,Nt,ye,Ne-ye),Nt.F=jt.mb,Nt.F==null&&Nt.F.length==0)){We=Ke(jt,3,"Could not decode alpha data.");break e}ye<Nt.j&&(me=Nt.j-ye,ye=Nt.j,t(!(1&me)),Nt.O+=jt.R*me,Nt.N+=jt.B*(me>>1),Nt.W+=jt.B*(me>>1),Nt.F!=null&&(Nt.J+=Nt.width*me)),ye<Ne&&(Nt.O+=Nt.v,Nt.N+=Nt.v>>1,Nt.W+=Nt.v>>1,Nt.F!=null&&(Nt.J+=Nt.v),Nt.ka=ye-Nt.j,Nt.U=Nt.va-Nt.v,Nt.T=Ne-ye,We=Nt.put(Nt))}ie+1!=jt.Ic||tn||(i(jt.sa,jt.ta-ee,on,xn+16*jt.R,ee),i(jt.qa,jt.ra-Fe,De,pe+8*jt.B,Fe),i(jt.Ha,jt.Ia-Fe,pn,_n+8*jt.B,Fe))}if(!We)return Ke(ce,6,"Output aborted.")}return 1})(F,Y)),Y.bc!=null&&Y.bc(Y),$&=1}return $?(F.cb=0,$):0})(r,g)||(s=r.a)}}else s=r.a}s==0&&y.Oa!=null&&y.Oa.fd&&(s=ci(y.ba))}y=s}w=y!=0?null:11>w?A.f.RGBA.eb:A.f.kb.y}else w=null;return w};var Al=[3,4,3,4,4,2,2,4,4,4,2,1,1]};function d(R,tt){for(var N="",E=0;E<4;E++)N+=String.fromCharCode(R[tt++]);return N}function m(R,tt){return R[tt+0]|R[tt+1]<<8}function _(R,tt){return(R[tt+0]|R[tt+1]<<8|R[tt+2]<<16)>>>0}function k(R,tt){return(R[tt+0]|R[tt+1]<<8|R[tt+2]<<16|R[tt+3]<<24)>>>0}new h;var p=[0],j=[0],O=[],M=new h,S=n,V=(function(R,tt){var N={},E=0,z=!1,U=0,rt=0;if(N.frames=[],!(function(x,B){for(var T=0;T<4;T++)if(x[B+T]!="RIFF".charCodeAt(T))return!0;return!1})(R,tt)){for(k(R,tt+=4),tt+=8;tt<R.length;){var ot=d(R,tt),ft=k(R,tt+=4);tt+=4;var nt=ft+(1&ft);switch(ot){case"VP8 ":case"VP8L":N.frames[E]===void 0&&(N.frames[E]={}),(wt=N.frames[E]).src_off=z?rt:tt-8,wt.src_size=U+ft+8,E++,z&&(z=!1,U=0,rt=0);break;case"VP8X":(wt=N.header={}).feature_flags=R[tt];var ct=tt+4;wt.canvas_width=1+_(R,ct),ct+=3,wt.canvas_height=1+_(R,ct),ct+=3;break;case"ALPH":z=!0,U=nt+8,rt=tt-8;break;case"ANIM":(wt=N.header).bgcolor=k(R,tt),ct=tt+4,wt.loop_count=m(R,ct),ct+=2;break;case"ANMF":var At,wt;(wt=N.frames[E]={}).offset_x=2*_(R,tt),tt+=3,wt.offset_y=2*_(R,tt),tt+=3,wt.width=1+_(R,tt),tt+=3,wt.height=1+_(R,tt),tt+=3,wt.duration=_(R,tt),tt+=3,At=R[tt++],wt.dispose=1&At,wt.blend=At>>1&1}ot!="ANMF"&&(tt+=nt)}return N}})(S,0);V.response=S,V.rgbaoutput=!0,V.dataurl=!1;var G=V.header?V.header:null,q=V.frames?V.frames:null;if(G){G.loop_counter=G.loop_count,p=[G.canvas_height],j=[G.canvas_width];for(var it=0;it<q.length&&q[it].blend!=0;it++);}var vt=q[0],dt=M.WebPDecodeRGBA(S,vt.src_off,vt.src_size,j,p);vt.rgba=dt,vt.imgwidth=j[0],vt.imgheight=p[0];for(var X=0;X<j[0]*p[0]*4;X++)O[X]=dt[X];return this.width=j,this.height=p,this.data=O,this}function K1(){var n,t=this.internal.__metadata__.metadata,e=unescape(encodeURIComponent(t));n=this.internal.__metadata__.rawXml?e:'<x:xmpmeta xmlns:x="adobe:ns:meta/"><rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"><rdf:Description rdf:about="" xmlns:jspdf="'+this.internal.__metadata__.namespaceUri+'"><jspdf:metadata>'+e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")+"</jspdf:metadata></rdf:Description></rdf:RDF></x:xmpmeta>",this.internal.__metadata__.metadataObjectNumber=this.internal.newObject(),this.internal.write("<< /Type /Metadata /Subtype /XML /Length "+n.length+" >>"),this.internal.write("stream"),this.internal.write(n),this.internal.write("endstream"),this.internal.write("endobj")}function X1(){this.internal.__metadata__.metadataObjectNumber&&this.internal.write("/Metadata "+this.internal.__metadata__.metadataObjectNumber+" 0 R")}(function(n){var t,e,i,o,a,c,l,h,d,m=function(x){return x=x||{},this.isStrokeTransparent=x.isStrokeTransparent||!1,this.strokeOpacity=x.strokeOpacity||1,this.strokeStyle=x.strokeStyle||"#000000",this.fillStyle=x.fillStyle||"#000000",this.isFillTransparent=x.isFillTransparent||!1,this.fillOpacity=x.fillOpacity||1,this.font=x.font||"10px sans-serif",this.textBaseline=x.textBaseline||"alphabetic",this.textAlign=x.textAlign||"left",this.lineWidth=x.lineWidth||1,this.lineJoin=x.lineJoin||"miter",this.lineCap=x.lineCap||"butt",this.path=x.path||[],this.transform=x.transform!==void 0?x.transform.clone():new h,this.globalCompositeOperation=x.globalCompositeOperation||"normal",this.globalAlpha=x.globalAlpha||1,this.clip_path=x.clip_path||[],this.currentPoint=x.currentPoint||new c,this.miterLimit=x.miterLimit||10,this.lastPoint=x.lastPoint||new c,this.lineDashOffset=x.lineDashOffset||0,this.lineDash=x.lineDash||[],this.margin=x.margin||[0,0,0,0],this.prevPageLastElemOffset=x.prevPageLastElemOffset||0,this.ignoreClearRect=typeof x.ignoreClearRect!="boolean"||x.ignoreClearRect,this};n.events.push(["initialized",function(){this.context2d=new _(this),t=this.internal.f2,e=this.internal.getCoordinateString,i=this.internal.getVerticalCoordinateString,o=this.internal.getHorizontalCoordinate,a=this.internal.getVerticalCoordinate,c=this.internal.Point,l=this.internal.Rectangle,h=this.internal.Matrix,d=new m}]);var _=function(x){Object.defineProperty(this,"canvas",{get:function(){return{parentNode:!1,style:!1}}});var B=x;Object.defineProperty(this,"pdf",{get:function(){return B}});var T=!1;Object.defineProperty(this,"pageWrapXEnabled",{get:function(){return T},set:function(P){T=!!P}});var H=!1;Object.defineProperty(this,"pageWrapYEnabled",{get:function(){return H},set:function(P){H=!!P}});var J=0;Object.defineProperty(this,"posX",{get:function(){return J},set:function(P){isNaN(P)||(J=P)}});var Z=0;Object.defineProperty(this,"posY",{get:function(){return Z},set:function(P){isNaN(P)||(Z=P)}}),Object.defineProperty(this,"margin",{get:function(){return d.margin},set:function(P){var Lt;typeof P=="number"?Lt=[P,P,P,P]:((Lt=new Array(4))[0]=P[0],Lt[1]=P.length>=2?P[1]:Lt[0],Lt[2]=P.length>=3?P[2]:Lt[0],Lt[3]=P.length>=4?P[3]:Lt[1]),d.margin=Lt}});var at=!1;Object.defineProperty(this,"autoPaging",{get:function(){return at},set:function(P){at=P}});var st=0;Object.defineProperty(this,"lastBreak",{get:function(){return st},set:function(P){st=P}});var gt=[];Object.defineProperty(this,"pageBreaks",{get:function(){return gt},set:function(P){gt=P}}),Object.defineProperty(this,"ctx",{get:function(){return d},set:function(P){P instanceof m&&(d=P)}}),Object.defineProperty(this,"path",{get:function(){return d.path},set:function(P){d.path=P}});var _t=[];Object.defineProperty(this,"ctxStack",{get:function(){return _t},set:function(P){_t=P}}),Object.defineProperty(this,"fillStyle",{get:function(){return this.ctx.fillStyle},set:function(P){var Lt;Lt=k(P),this.ctx.fillStyle=Lt.style,this.ctx.isFillTransparent=Lt.a===0,this.ctx.fillOpacity=Lt.a,this.pdf.setFillColor(Lt.r,Lt.g,Lt.b,{a:Lt.a}),this.pdf.setTextColor(Lt.r,Lt.g,Lt.b,{a:Lt.a})}}),Object.defineProperty(this,"strokeStyle",{get:function(){return this.ctx.strokeStyle},set:function(P){var Lt=k(P);this.ctx.strokeStyle=Lt.style,this.ctx.isStrokeTransparent=Lt.a===0,this.ctx.strokeOpacity=Lt.a,Lt.a===0?this.pdf.setDrawColor(255,255,255):(Lt.a,this.pdf.setDrawColor(Lt.r,Lt.g,Lt.b))}}),Object.defineProperty(this,"lineCap",{get:function(){return this.ctx.lineCap},set:function(P){["butt","round","square"].indexOf(P)!==-1&&(this.ctx.lineCap=P,this.pdf.setLineCap(P))}}),Object.defineProperty(this,"lineWidth",{get:function(){return this.ctx.lineWidth},set:function(P){isNaN(P)||(this.ctx.lineWidth=P,this.pdf.setLineWidth(P))}}),Object.defineProperty(this,"lineJoin",{get:function(){return this.ctx.lineJoin},set:function(P){["bevel","round","miter"].indexOf(P)!==-1&&(this.ctx.lineJoin=P,this.pdf.setLineJoin(P))}}),Object.defineProperty(this,"miterLimit",{get:function(){return this.ctx.miterLimit},set:function(P){isNaN(P)||(this.ctx.miterLimit=P,this.pdf.setMiterLimit(P))}}),Object.defineProperty(this,"textBaseline",{get:function(){return this.ctx.textBaseline},set:function(P){this.ctx.textBaseline=P}}),Object.defineProperty(this,"textAlign",{get:function(){return this.ctx.textAlign},set:function(P){["right","end","center","left","start"].indexOf(P)!==-1&&(this.ctx.textAlign=P)}});var kt=null,St=null,Dt=null;Object.defineProperty(this,"fontFaces",{get:function(){return Dt},set:function(P){kt=null,St=null,Dt=P}}),Object.defineProperty(this,"font",{get:function(){return this.ctx.font},set:function(P){var Lt;if(this.ctx.font=P,(Lt=/^\s*(?=(?:(?:[-a-z]+\s*){0,2}(italic|oblique))?)(?=(?:(?:[-a-z]+\s*){0,2}(small-caps))?)(?=(?:(?:[-a-z]+\s*){0,2}(bold(?:er)?|lighter|[1-9]00))?)(?:(?:normal|\1|\2|\3)\s*){0,3}((?:xx?-)?(?:small|large)|medium|smaller|larger|[.\d]+(?:\%|in|[cem]m|ex|p[ctx]))(?:\s*\/\s*(normal|[.\d]+(?:\%|in|[cem]m|ex|p[ctx])))?\s*([-_,\"\'\sa-z0-9]+?)\s*$/i.exec(P))!==null){var ae=Lt[1];Lt[2];var Ht=Lt[3],yt=Lt[4];Lt[5];var Wt=Lt[6],Ct=/^([.\d]+)((?:%|in|[cem]m|ex|p[ctx]))$/i.exec(yt)[2];yt=Math.floor(Ct==="px"?parseFloat(yt)*this.pdf.internal.scaleFactor:Ct==="em"?parseFloat(yt)*this.pdf.getFontSize():parseFloat(yt)*this.pdf.internal.scaleFactor),this.pdf.setFontSize(yt);var zt=(function(Tt){var ze,ge,se=[],oe=Tt.trim();if(oe==="")return Bo;if(oe in Eu)return[Eu[oe]];for(;oe!=="";){switch(ge=null,ze=(oe=ju(oe)).charAt(0)){case'"':case"'":ge=H1(oe.substring(1),ze);break;default:ge=W1(oe)}if(ge===null||(se.push(ge[0]),(oe=ju(ge[1]))!==""&&oe.charAt(0)!==","))return Bo;oe=oe.replace(/^,/,"")}return se})(Wt);if(this.fontFaces){var qt=(function(Tt,ze){var ge=Tt.getFontList(),se=JSON.stringify(ge);if(kt===null||St!==se){var oe=(function(Oe){var Ut=[];return Object.keys(Oe).forEach(function(Se){Oe[Se].forEach(function(Yt){var Qt=null;switch(Yt){case"bold":Qt={family:Se,weight:"bold"};break;case"italic":Qt={family:Se,style:"italic"};break;case"bolditalic":Qt={family:Se,weight:"bold",style:"italic"};break;case"":case"normal":Qt={family:Se}}Qt!==null&&(Qt.ref={name:Se,style:Yt},Ut.push(Qt))})}),Ut})(ge);kt=(function(Oe){for(var Ut={},Se=0;Se<Oe.length;++Se){var Yt=jo(Oe[Se]),Qt=Yt.family,je=Yt.stretch,le=Yt.style,Vt=Yt.weight;Ut[Qt]=Ut[Qt]||{},Ut[Qt][je]=Ut[Qt][je]||{},Ut[Qt][je][le]=Ut[Qt][je][le]||{},Ut[Qt][je][le][Vt]=Yt}return Ut})(oe.concat(ze)),St=se}return kt})(this.pdf,this.fontFaces),ve=zt.map(function(Tt){return{family:Tt,stretch:"normal",weight:Ht,style:ae}}),ue=(function(Tt,ze,ge){for(var se=(ge=ge||{}).defaultFontFamily||"times",oe=Object.assign({},z1,ge.genericFontFamilies||{}),Oe=null,Ut=null,Se=0;Se<ze.length;++Se)if(oe[(Oe=jo(ze[Se])).family]&&(Oe.family=oe[Oe.family]),Tt.hasOwnProperty(Oe.family)){Ut=Tt[Oe.family];break}if(!(Ut=Ut||Tt[se]))throw new Error("Could not find a font-family for the rule '"+Ou(Oe)+"' and default family '"+se+"'.");if(Ut=(function(Yt,Qt){if(Qt[Yt])return Qt[Yt];var je=Jo[Yt],le=je<=Jo.normal?-1:1,Vt=Fu(Qt,jf,je,le);if(!Vt)throw new Error("Could not find a matching font-stretch value for "+Yt);return Vt})(Oe.stretch,Ut),Ut=(function(Yt,Qt){if(Qt[Yt])return Qt[Yt];for(var je=Of[Yt],le=0;le<je.length;++le)if(Qt[je[le]])return Qt[je[le]];throw new Error("Could not find a matching font-style for "+Yt)})(Oe.style,Ut),!(Ut=(function(Yt,Qt){if(Qt[Yt])return Qt[Yt];if(Yt===400&&Qt[500])return Qt[500];if(Yt===500&&Qt[400])return Qt[400];var je=U1[Yt],le=Fu(Qt,Bf,je,Yt<400?-1:1);if(!le)throw new Error("Could not find a matching font-weight for value "+Yt);return le})(Oe.weight,Ut)))throw new Error("Failed to resolve a font for the rule '"+Ou(Oe)+"'.");return Ut})(qt,ve);this.pdf.setFont(ue.ref.name,ue.ref.style)}else{var Zt="";(Ht==="bold"||parseInt(Ht,10)>=700||ae==="bold")&&(Zt="bold"),ae==="italic"&&(Zt+="italic"),Zt.length===0&&(Zt="normal");for(var he="",fe={arial:"Helvetica",Arial:"Helvetica",verdana:"Helvetica",Verdana:"Helvetica",helvetica:"Helvetica",Helvetica:"Helvetica","sans-serif":"Helvetica",fixed:"Courier",monospace:"Courier",terminal:"Courier",cursive:"Times",fantasy:"Times",serif:"Times"},Bt=0;Bt<zt.length;Bt++){if(this.pdf.internal.getFont(zt[Bt],Zt,{noFallback:!0,disableWarning:!0})!==void 0){he=zt[Bt];break}if(Zt==="bolditalic"&&this.pdf.internal.getFont(zt[Bt],"bold",{noFallback:!0,disableWarning:!0})!==void 0)he=zt[Bt],Zt="bold";else if(this.pdf.internal.getFont(zt[Bt],"normal",{noFallback:!0,disableWarning:!0})!==void 0){he=zt[Bt],Zt="normal";break}}if(he===""){for(var ne=0;ne<zt.length;ne++)if(fe[zt[ne]]){he=fe[zt[ne]];break}}he=he===""?"Times":he,this.pdf.setFont(he,Zt)}}}}),Object.defineProperty(this,"globalCompositeOperation",{get:function(){return this.ctx.globalCompositeOperation},set:function(P){this.ctx.globalCompositeOperation=P}}),Object.defineProperty(this,"globalAlpha",{get:function(){return this.ctx.globalAlpha},set:function(P){this.ctx.globalAlpha=P}}),Object.defineProperty(this,"lineDashOffset",{get:function(){return this.ctx.lineDashOffset},set:function(P){this.ctx.lineDashOffset=P,wt.call(this)}}),Object.defineProperty(this,"lineDash",{get:function(){return this.ctx.lineDash},set:function(P){this.ctx.lineDash=P,wt.call(this)}}),Object.defineProperty(this,"ignoreClearRect",{get:function(){return this.ctx.ignoreClearRect},set:function(P){this.ctx.ignoreClearRect=!!P}})};_.prototype.setLineDash=function(x){this.lineDash=x},_.prototype.getLineDash=function(){return this.lineDash.length%2?this.lineDash.concat(this.lineDash):this.lineDash.slice()},_.prototype.fill=function(){q.call(this,"fill",!1)},_.prototype.stroke=function(){q.call(this,"stroke",!1)},_.prototype.beginPath=function(){this.path=[{type:"begin"}]},_.prototype.moveTo=function(x,B){if(isNaN(x)||isNaN(B))throw Le.error("jsPDF.context2d.moveTo: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.moveTo");var T=this.ctx.transform.applyToPoint(new c(x,B));this.path.push({type:"mt",x:T.x,y:T.y}),this.ctx.lastPoint=new c(x,B)},_.prototype.closePath=function(){var x=new c(0,0),B=0;for(B=this.path.length-1;B!==-1;B--)if(this.path[B].type==="begin"&&xe(this.path[B+1])==="object"&&typeof this.path[B+1].x=="number"){x=new c(this.path[B+1].x,this.path[B+1].y);break}this.path.push({type:"close"}),this.ctx.lastPoint=new c(x.x,x.y)},_.prototype.lineTo=function(x,B){if(isNaN(x)||isNaN(B))throw Le.error("jsPDF.context2d.lineTo: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.lineTo");var T=this.ctx.transform.applyToPoint(new c(x,B));this.path.push({type:"lt",x:T.x,y:T.y}),this.ctx.lastPoint=new c(T.x,T.y)},_.prototype.clip=function(){this.ctx.clip_path=JSON.parse(JSON.stringify(this.path)),q.call(this,null,!0)},_.prototype.quadraticCurveTo=function(x,B,T,H){if(isNaN(T)||isNaN(H)||isNaN(x)||isNaN(B))throw Le.error("jsPDF.context2d.quadraticCurveTo: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.quadraticCurveTo");var J=this.ctx.transform.applyToPoint(new c(T,H)),Z=this.ctx.transform.applyToPoint(new c(x,B));this.path.push({type:"qct",x1:Z.x,y1:Z.y,x:J.x,y:J.y}),this.ctx.lastPoint=new c(J.x,J.y)},_.prototype.bezierCurveTo=function(x,B,T,H,J,Z){if(isNaN(J)||isNaN(Z)||isNaN(x)||isNaN(B)||isNaN(T)||isNaN(H))throw Le.error("jsPDF.context2d.bezierCurveTo: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.bezierCurveTo");var at=this.ctx.transform.applyToPoint(new c(J,Z)),st=this.ctx.transform.applyToPoint(new c(x,B)),gt=this.ctx.transform.applyToPoint(new c(T,H));this.path.push({type:"bct",x1:st.x,y1:st.y,x2:gt.x,y2:gt.y,x:at.x,y:at.y}),this.ctx.lastPoint=new c(at.x,at.y)},_.prototype.arc=function(x,B,T,H,J,Z){if(isNaN(x)||isNaN(B)||isNaN(T)||isNaN(H)||isNaN(J))throw Le.error("jsPDF.context2d.arc: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.arc");if(Z=!!Z,!this.ctx.transform.isIdentity){var at=this.ctx.transform.applyToPoint(new c(x,B));x=at.x,B=at.y;var st=this.ctx.transform.applyToPoint(new c(0,T)),gt=this.ctx.transform.applyToPoint(new c(0,0));T=Math.sqrt(Math.pow(st.x-gt.x,2)+Math.pow(st.y-gt.y,2))}Math.abs(J-H)>=2*Math.PI&&(H=0,J=2*Math.PI),this.path.push({type:"arc",x,y:B,radius:T,startAngle:H,endAngle:J,counterclockwise:Z})},_.prototype.arcTo=function(x,B,T,H,J){throw new Error("arcTo not implemented.")},_.prototype.rect=function(x,B,T,H){if(isNaN(x)||isNaN(B)||isNaN(T)||isNaN(H))throw Le.error("jsPDF.context2d.rect: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.rect");this.moveTo(x,B),this.lineTo(x+T,B),this.lineTo(x+T,B+H),this.lineTo(x,B+H),this.lineTo(x,B),this.lineTo(x+T,B),this.lineTo(x,B)},_.prototype.fillRect=function(x,B,T,H){if(isNaN(x)||isNaN(B)||isNaN(T)||isNaN(H))throw Le.error("jsPDF.context2d.fillRect: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.fillRect");if(!p.call(this)){var J={};this.lineCap!=="butt"&&(J.lineCap=this.lineCap,this.lineCap="butt"),this.lineJoin!=="miter"&&(J.lineJoin=this.lineJoin,this.lineJoin="miter"),this.beginPath(),this.rect(x,B,T,H),this.fill(),J.hasOwnProperty("lineCap")&&(this.lineCap=J.lineCap),J.hasOwnProperty("lineJoin")&&(this.lineJoin=J.lineJoin)}},_.prototype.strokeRect=function(x,B,T,H){if(isNaN(x)||isNaN(B)||isNaN(T)||isNaN(H))throw Le.error("jsPDF.context2d.strokeRect: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.strokeRect");j.call(this)||(this.beginPath(),this.rect(x,B,T,H),this.stroke())},_.prototype.clearRect=function(x,B,T,H){if(isNaN(x)||isNaN(B)||isNaN(T)||isNaN(H))throw Le.error("jsPDF.context2d.clearRect: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.clearRect");this.ignoreClearRect||(this.fillStyle="#ffffff",this.fillRect(x,B,T,H))},_.prototype.save=function(x){x=typeof x!="boolean"||x;for(var B=this.pdf.internal.getCurrentPageInfo().pageNumber,T=0;T<this.pdf.internal.getNumberOfPages();T++)this.pdf.setPage(T+1),this.pdf.internal.out("q");if(this.pdf.setPage(B),x){this.ctx.fontSize=this.pdf.internal.getFontSize();var H=new m(this.ctx);this.ctxStack.push(this.ctx),this.ctx=H}},_.prototype.restore=function(x){x=typeof x!="boolean"||x;for(var B=this.pdf.internal.getCurrentPageInfo().pageNumber,T=0;T<this.pdf.internal.getNumberOfPages();T++)this.pdf.setPage(T+1),this.pdf.internal.out("Q");this.pdf.setPage(B),x&&this.ctxStack.length!==0&&(this.ctx=this.ctxStack.pop(),this.fillStyle=this.ctx.fillStyle,this.strokeStyle=this.ctx.strokeStyle,this.font=this.ctx.font,this.lineCap=this.ctx.lineCap,this.lineWidth=this.ctx.lineWidth,this.lineJoin=this.ctx.lineJoin,this.lineDash=this.ctx.lineDash,this.lineDashOffset=this.ctx.lineDashOffset)},_.prototype.toDataURL=function(){throw new Error("toDataUrl not implemented.")};var k=function(x){var B,T,H,J;if(x.isCanvasGradient===!0&&(x=x.getColor()),!x)return{r:0,g:0,b:0,a:0,style:x};if(/transparent|rgba\s*\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*,\s*0+\s*\)/.test(x))B=0,T=0,H=0,J=0;else{var Z=/rgb\s*\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*\)/.exec(x);if(Z!==null)B=parseInt(Z[1]),T=parseInt(Z[2]),H=parseInt(Z[3]),J=1;else if((Z=/rgba\s*\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*,\s*([\d.]+)\s*\)/.exec(x))!==null)B=parseInt(Z[1]),T=parseInt(Z[2]),H=parseInt(Z[3]),J=parseFloat(Z[4]);else{if(J=1,typeof x=="string"&&x.charAt(0)!=="#"){var at=new Sf(x);x=at.ok?at.toHex():"#000000"}x.length===4?(B=x.substring(1,2),B+=B,T=x.substring(2,3),T+=T,H=x.substring(3,4),H+=H):(B=x.substring(1,3),T=x.substring(3,5),H=x.substring(5,7)),B=parseInt(B,16),T=parseInt(T,16),H=parseInt(H,16)}}return{r:B,g:T,b:H,a:J,style:x}},p=function(){return this.ctx.isFillTransparent||this.globalAlpha==0},j=function(){return!!(this.ctx.isStrokeTransparent||this.globalAlpha==0)};_.prototype.fillText=function(x,B,T,H){if(isNaN(B)||isNaN(T)||typeof x!="string")throw Le.error("jsPDF.context2d.fillText: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.fillText");if(H=isNaN(H)?void 0:H,!p.call(this)){var J=nt(this.ctx.transform.rotation),Z=this.ctx.transform.scaleX;E.call(this,{text:x,x:B,y:T,scale:Z,angle:J,align:this.textAlign,maxWidth:H})}},_.prototype.strokeText=function(x,B,T,H){if(isNaN(B)||isNaN(T)||typeof x!="string")throw Le.error("jsPDF.context2d.strokeText: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.strokeText");if(!j.call(this)){H=isNaN(H)?void 0:H;var J=nt(this.ctx.transform.rotation),Z=this.ctx.transform.scaleX;E.call(this,{text:x,x:B,y:T,scale:Z,renderingMode:"stroke",angle:J,align:this.textAlign,maxWidth:H})}},_.prototype.measureText=function(x){if(typeof x!="string")throw Le.error("jsPDF.context2d.measureText: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.measureText");var B=this.pdf,T=this.pdf.internal.scaleFactor,H=B.internal.getFontSize(),J=B.getStringUnitWidth(x)*H/B.internal.scaleFactor;return new function(Z){var at=(Z=Z||{}).width||0;return Object.defineProperty(this,"width",{get:function(){return at}}),this}({width:J*=Math.round(96*T/72*1e4)/1e4})},_.prototype.scale=function(x,B){if(isNaN(x)||isNaN(B))throw Le.error("jsPDF.context2d.scale: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.scale");var T=new h(x,0,0,B,0,0);this.ctx.transform=this.ctx.transform.multiply(T)},_.prototype.rotate=function(x){if(isNaN(x))throw Le.error("jsPDF.context2d.rotate: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.rotate");var B=new h(Math.cos(x),Math.sin(x),-Math.sin(x),Math.cos(x),0,0);this.ctx.transform=this.ctx.transform.multiply(B)},_.prototype.translate=function(x,B){if(isNaN(x)||isNaN(B))throw Le.error("jsPDF.context2d.translate: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.translate");var T=new h(1,0,0,1,x,B);this.ctx.transform=this.ctx.transform.multiply(T)},_.prototype.transform=function(x,B,T,H,J,Z){if(isNaN(x)||isNaN(B)||isNaN(T)||isNaN(H)||isNaN(J)||isNaN(Z))throw Le.error("jsPDF.context2d.transform: Invalid arguments",arguments),new Error("Invalid arguments passed to jsPDF.context2d.transform");var at=new h(x,B,T,H,J,Z);this.ctx.transform=this.ctx.transform.multiply(at)},_.prototype.setTransform=function(x,B,T,H,J,Z){x=isNaN(x)?1:x,B=isNaN(B)?0:B,T=isNaN(T)?0:T,H=isNaN(H)?1:H,J=isNaN(J)?0:J,Z=isNaN(Z)?0:Z,this.ctx.transform=new h(x,B,T,H,J,Z)};var O=function(){return this.margin[0]>0||this.margin[1]>0||this.margin[2]>0||this.margin[3]>0};_.prototype.drawImage=function(x,B,T,H,J,Z,at,st,gt){var _t=this.pdf.getImageProperties(x),kt=1,St=1,Dt=1,P=1;H!==void 0&&st!==void 0&&(Dt=st/H,P=gt/J,kt=_t.width/H*st/H,St=_t.height/J*gt/J),Z===void 0&&(Z=B,at=T,B=0,T=0),H!==void 0&&st===void 0&&(st=H,gt=J),H===void 0&&st===void 0&&(st=_t.width,gt=_t.height);var Lt=this.ctx.transform.decompose(),ae=nt(Lt.rotate.shx),Ht=new h,yt=(Ht=(Ht=(Ht=Ht.multiply(Lt.translate)).multiply(Lt.skew)).multiply(Lt.scale)).applyToRectangle(new l(Z-B*Dt,at-T*P,H*kt,J*St));if(this.autoPaging){for(var Wt,Ct=M.call(this,yt),zt=[],qt=0;qt<Ct.length;qt+=1)zt.indexOf(Ct[qt])===-1&&zt.push(Ct[qt]);G(zt);for(var ve=zt[0],ue=zt[zt.length-1],Zt=ve;Zt<ue+1;Zt++){this.pdf.setPage(Zt);var he=this.pdf.internal.pageSize.width-this.margin[3]-this.margin[1],fe=Zt===1?this.posY+this.margin[0]:this.margin[0],Bt=this.pdf.internal.pageSize.height-this.posY-this.margin[0]-this.margin[2],ne=this.pdf.internal.pageSize.height-this.margin[0]-this.margin[2],Tt=Zt===1?0:Bt+(Zt-2)*ne;if(this.ctx.clip_path.length!==0){var ze=this.path;Wt=JSON.parse(JSON.stringify(this.ctx.clip_path)),this.path=V(Wt,this.posX+this.margin[3],-Tt+fe+this.ctx.prevPageLastElemOffset),it.call(this,"fill",!0),this.path=ze}var ge=JSON.parse(JSON.stringify(yt));ge=V([ge],this.posX+this.margin[3],-Tt+fe+this.ctx.prevPageLastElemOffset)[0];var se=(Zt>ve||Zt<ue)&&O.call(this);se&&(this.pdf.saveGraphicsState(),this.pdf.rect(this.margin[3],this.margin[0],he,ne,null).clip().discardPath()),this.pdf.addImage(x,"JPEG",ge.x,ge.y,ge.w,ge.h,null,null,ae),se&&this.pdf.restoreGraphicsState()}}else this.pdf.addImage(x,"JPEG",yt.x,yt.y,yt.w,yt.h,null,null,ae)};var M=function(x,B,T){var H=[];B=B||this.pdf.internal.pageSize.width,T=T||this.pdf.internal.pageSize.height-this.margin[0]-this.margin[2];var J=this.posY+this.ctx.prevPageLastElemOffset;switch(x.type){default:case"mt":case"lt":H.push(Math.floor((x.y+J)/T)+1);break;case"arc":H.push(Math.floor((x.y+J-x.radius)/T)+1),H.push(Math.floor((x.y+J+x.radius)/T)+1);break;case"qct":var Z=ct(this.ctx.lastPoint.x,this.ctx.lastPoint.y,x.x1,x.y1,x.x,x.y);H.push(Math.floor((Z.y+J)/T)+1),H.push(Math.floor((Z.y+Z.h+J)/T)+1);break;case"bct":var at=At(this.ctx.lastPoint.x,this.ctx.lastPoint.y,x.x1,x.y1,x.x2,x.y2,x.x,x.y);H.push(Math.floor((at.y+J)/T)+1),H.push(Math.floor((at.y+at.h+J)/T)+1);break;case"rect":H.push(Math.floor((x.y+J)/T)+1),H.push(Math.floor((x.y+x.h+J)/T)+1)}for(var st=0;st<H.length;st+=1)for(;this.pdf.internal.getNumberOfPages()<H[st];)S.call(this);return H},S=function(){var x=this.fillStyle,B=this.strokeStyle,T=this.font,H=this.lineCap,J=this.lineWidth,Z=this.lineJoin;this.pdf.addPage(),this.fillStyle=x,this.strokeStyle=B,this.font=T,this.lineCap=H,this.lineWidth=J,this.lineJoin=Z},V=function(x,B,T){for(var H=0;H<x.length;H++)switch(x[H].type){case"bct":x[H].x2+=B,x[H].y2+=T;case"qct":x[H].x1+=B,x[H].y1+=T;default:x[H].x+=B,x[H].y+=T}return x},G=function(x){return x.sort(function(B,T){return B-T})},q=function(x,B){var T=this.fillStyle,H=this.strokeStyle,J=this.lineCap,Z=this.lineWidth,at=Math.abs(Z*this.ctx.transform.scaleX),st=this.lineJoin;if(this.autoPaging){for(var gt,_t,kt=JSON.parse(JSON.stringify(this.path)),St=JSON.parse(JSON.stringify(this.path)),Dt=[],P=0;P<St.length;P++)if(St[P].x!==void 0)for(var Lt=M.call(this,St[P]),ae=0;ae<Lt.length;ae+=1)Dt.indexOf(Lt[ae])===-1&&Dt.push(Lt[ae]);for(var Ht=0;Ht<Dt.length;Ht++)for(;this.pdf.internal.getNumberOfPages()<Dt[Ht];)S.call(this);G(Dt);for(var yt=Dt[0],Wt=Dt[Dt.length-1],Ct=yt;Ct<Wt+1;Ct++){this.pdf.setPage(Ct),this.fillStyle=T,this.strokeStyle=H,this.lineCap=J,this.lineWidth=at,this.lineJoin=st;var zt=this.pdf.internal.pageSize.width-this.margin[3]-this.margin[1],qt=Ct===1?this.posY+this.margin[0]:this.margin[0],ve=this.pdf.internal.pageSize.height-this.posY-this.margin[0]-this.margin[2],ue=this.pdf.internal.pageSize.height-this.margin[0]-this.margin[2],Zt=Ct===1?0:ve+(Ct-2)*ue;if(this.ctx.clip_path.length!==0){var he=this.path;gt=JSON.parse(JSON.stringify(this.ctx.clip_path)),this.path=V(gt,this.posX+this.margin[3],-Zt+qt+this.ctx.prevPageLastElemOffset),it.call(this,x,!0),this.path=he}if(_t=JSON.parse(JSON.stringify(kt)),this.path=V(_t,this.posX+this.margin[3],-Zt+qt+this.ctx.prevPageLastElemOffset),B===!1||Ct===0){var fe=(Ct>yt||Ct<Wt)&&O.call(this);fe&&(this.pdf.saveGraphicsState(),this.pdf.rect(this.margin[3],this.margin[0],zt,ue,null).clip().discardPath()),it.call(this,x,B),fe&&this.pdf.restoreGraphicsState()}this.lineWidth=Z}this.path=kt}else this.lineWidth=at,it.call(this,x,B),this.lineWidth=Z},it=function(x,B){if((x!=="stroke"||B||!j.call(this))&&(x==="stroke"||B||!p.call(this))){for(var T,H,J=[],Z=this.path,at=0;at<Z.length;at++){var st=Z[at];switch(st.type){case"begin":J.push({begin:!0});break;case"close":J.push({close:!0});break;case"mt":J.push({start:st,deltas:[],abs:[]});break;case"lt":var gt=J.length;if(Z[at-1]&&!isNaN(Z[at-1].x)&&(T=[st.x-Z[at-1].x,st.y-Z[at-1].y],gt>0)){for(;gt>=0;gt--)if(J[gt-1].close!==!0&&J[gt-1].begin!==!0){J[gt-1].deltas.push(T),J[gt-1].abs.push(st);break}}break;case"bct":T=[st.x1-Z[at-1].x,st.y1-Z[at-1].y,st.x2-Z[at-1].x,st.y2-Z[at-1].y,st.x-Z[at-1].x,st.y-Z[at-1].y],J[J.length-1].deltas.push(T);break;case"qct":var _t=Z[at-1].x+2/3*(st.x1-Z[at-1].x),kt=Z[at-1].y+2/3*(st.y1-Z[at-1].y),St=st.x+2/3*(st.x1-st.x),Dt=st.y+2/3*(st.y1-st.y),P=st.x,Lt=st.y;T=[_t-Z[at-1].x,kt-Z[at-1].y,St-Z[at-1].x,Dt-Z[at-1].y,P-Z[at-1].x,Lt-Z[at-1].y],J[J.length-1].deltas.push(T);break;case"arc":J.push({deltas:[],abs:[],arc:!0}),Array.isArray(J[J.length-1].abs)&&J[J.length-1].abs.push(st)}}H=B?null:x==="stroke"?"stroke":"fill";for(var ae=!1,Ht=0;Ht<J.length;Ht++)if(J[Ht].arc)for(var yt=J[Ht].abs,Wt=0;Wt<yt.length;Wt++){var Ct=yt[Wt];Ct.type==="arc"?X.call(this,Ct.x,Ct.y,Ct.radius,Ct.startAngle,Ct.endAngle,Ct.counterclockwise,void 0,B,!ae):z.call(this,Ct.x,Ct.y),ae=!0}else if(J[Ht].close===!0)this.pdf.internal.out("h"),ae=!1;else if(J[Ht].begin!==!0){var zt=J[Ht].start.x,qt=J[Ht].start.y;U.call(this,J[Ht].deltas,zt,qt),ae=!0}H&&R.call(this,H),B&&tt.call(this)}},vt=function(x){var B=this.pdf.internal.getFontSize()/this.pdf.internal.scaleFactor,T=B*(this.pdf.internal.getLineHeightFactor()-1);switch(this.ctx.textBaseline){case"bottom":return x-T;case"top":return x+B-T;case"hanging":return x+B-2*T;case"middle":return x+B/2-T;default:return x}},dt=function(x){return x+this.pdf.internal.getFontSize()/this.pdf.internal.scaleFactor*(this.pdf.internal.getLineHeightFactor()-1)};_.prototype.createLinearGradient=function(){var x=function(){};return x.colorStops=[],x.addColorStop=function(B,T){this.colorStops.push([B,T])},x.getColor=function(){return this.colorStops.length===0?"#000000":this.colorStops[0][1]},x.isCanvasGradient=!0,x},_.prototype.createPattern=function(){return this.createLinearGradient()},_.prototype.createRadialGradient=function(){return this.createLinearGradient()};var X=function(x,B,T,H,J,Z,at,st,gt){for(var _t=ot.call(this,T,H,J,Z),kt=0;kt<_t.length;kt++){var St=_t[kt];kt===0&&(gt?N.call(this,St.x1+x,St.y1+B):z.call(this,St.x1+x,St.y1+B)),rt.call(this,x,B,St.x2,St.y2,St.x3,St.y3,St.x4,St.y4)}st?tt.call(this):R.call(this,at)},R=function(x){switch(x){case"stroke":this.pdf.internal.out("S");break;case"fill":this.pdf.internal.out("f")}},tt=function(){this.pdf.clip(),this.pdf.discardPath()},N=function(x,B){this.pdf.internal.out(e(x)+" "+i(B)+" m")},E=function(x){var B;switch(x.align){case"right":case"end":B="right";break;case"center":B="center";break;default:B="left"}var T,H,J,Z=this.pdf.getTextDimensions(x.text),at=vt.call(this,x.y),st=dt.call(this,at)-Z.h,gt=this.ctx.transform.applyToPoint(new c(x.x,at));if(this.autoPaging){var _t=this.ctx.transform.decompose(),kt=new h;kt=(kt=(kt=kt.multiply(_t.translate)).multiply(_t.skew)).multiply(_t.scale);for(var St=this.ctx.transform.applyToRectangle(new l(x.x,at,Z.w,Z.h)),Dt=kt.applyToRectangle(new l(x.x,st,Z.w,Z.h)),P=M.call(this,Dt),Lt=[],ae=0;ae<P.length;ae+=1)Lt.indexOf(P[ae])===-1&&Lt.push(P[ae]);G(Lt);for(var Ht=Lt[0],yt=Lt[Lt.length-1],Wt=Ht;Wt<yt+1;Wt++){this.pdf.setPage(Wt);var Ct=Wt===1?this.posY+this.margin[0]:this.margin[0],zt=this.pdf.internal.pageSize.height-this.posY-this.margin[0]-this.margin[2],qt=this.pdf.internal.pageSize.height-this.margin[2],ve=qt-this.margin[0],ue=this.pdf.internal.pageSize.width-this.margin[1],Zt=ue-this.margin[3],he=Wt===1?0:zt+(Wt-2)*ve;if(this.ctx.clip_path.length!==0){var fe=this.path;T=JSON.parse(JSON.stringify(this.ctx.clip_path)),this.path=V(T,this.posX+this.margin[3],-1*he+Ct),it.call(this,"fill",!0),this.path=fe}var Bt=V([JSON.parse(JSON.stringify(Dt))],this.posX+this.margin[3],-he+Ct+this.ctx.prevPageLastElemOffset)[0];x.scale>=.01&&(H=this.pdf.internal.getFontSize(),this.pdf.setFontSize(H*x.scale),J=this.lineWidth,this.lineWidth=J*x.scale);var ne=this.autoPaging!=="text";if(ne||Bt.y+Bt.h<=qt){if(ne||Bt.y>=Ct&&Bt.x<=ue){var Tt=ne?x.text:this.pdf.splitTextToSize(x.text,x.maxWidth||ue-Bt.x)[0],ze=V([JSON.parse(JSON.stringify(St))],this.posX+this.margin[3],-he+Ct+this.ctx.prevPageLastElemOffset)[0],ge=ne&&(Wt>Ht||Wt<yt)&&O.call(this);ge&&(this.pdf.saveGraphicsState(),this.pdf.rect(this.margin[3],this.margin[0],Zt,ve,null).clip().discardPath()),this.pdf.text(Tt,ze.x,ze.y,{angle:x.angle,align:B,renderingMode:x.renderingMode}),ge&&this.pdf.restoreGraphicsState()}}else Bt.y<qt&&(this.ctx.prevPageLastElemOffset+=qt-Bt.y);x.scale>=.01&&(this.pdf.setFontSize(H),this.lineWidth=J)}}else x.scale>=.01&&(H=this.pdf.internal.getFontSize(),this.pdf.setFontSize(H*x.scale),J=this.lineWidth,this.lineWidth=J*x.scale),this.pdf.text(x.text,gt.x+this.posX,gt.y+this.posY,{angle:x.angle,align:B,renderingMode:x.renderingMode,maxWidth:x.maxWidth}),x.scale>=.01&&(this.pdf.setFontSize(H),this.lineWidth=J)},z=function(x,B,T,H){T=T||0,H=H||0,this.pdf.internal.out(e(x+T)+" "+i(B+H)+" l")},U=function(x,B,T){return this.pdf.lines(x,B,T,null,null)},rt=function(x,B,T,H,J,Z,at,st){this.pdf.internal.out([t(o(T+x)),t(a(H+B)),t(o(J+x)),t(a(Z+B)),t(o(at+x)),t(a(st+B)),"c"].join(" "))},ot=function(x,B,T,H){for(var J=2*Math.PI,Z=Math.PI/2;B>T;)B-=J;var at=Math.abs(T-B);at<J&&H&&(at=J-at);for(var st=[],gt=H?-1:1,_t=B;at>1e-5;){var kt=_t+gt*Math.min(at,Z);st.push(ft.call(this,x,_t,kt)),at-=Math.abs(kt-_t),_t=kt}return st},ft=function(x,B,T){var H=(T-B)/2,J=x*Math.cos(H),Z=x*Math.sin(H),at=J,st=-Z,gt=at*at+st*st,_t=gt+at*J+st*Z,kt=4/3*(Math.sqrt(2*gt*_t)-_t)/(at*Z-st*J),St=at-kt*st,Dt=st+kt*at,P=St,Lt=-Dt,ae=H+B,Ht=Math.cos(ae),yt=Math.sin(ae);return{x1:x*Math.cos(B),y1:x*Math.sin(B),x2:St*Ht-Dt*yt,y2:St*yt+Dt*Ht,x3:P*Ht-Lt*yt,y3:P*yt+Lt*Ht,x4:x*Math.cos(T),y4:x*Math.sin(T)}},nt=function(x){return 180*x/Math.PI},ct=function(x,B,T,H,J,Z){var at=x+.5*(T-x),st=B+.5*(H-B),gt=J+.5*(T-J),_t=Z+.5*(H-Z),kt=Math.min(x,J,at,gt),St=Math.max(x,J,at,gt),Dt=Math.min(B,Z,st,_t),P=Math.max(B,Z,st,_t);return new l(kt,Dt,St-kt,P-Dt)},At=function(x,B,T,H,J,Z,at,st){var gt,_t,kt,St,Dt,P,Lt,ae,Ht,yt,Wt,Ct,zt,qt,ve=T-x,ue=H-B,Zt=J-T,he=Z-H,fe=at-J,Bt=st-Z;for(_t=0;_t<41;_t++)Ht=(Lt=(kt=x+(gt=_t/40)*ve)+gt*((Dt=T+gt*Zt)-kt))+gt*(Dt+gt*(J+gt*fe-Dt)-Lt),yt=(ae=(St=B+gt*ue)+gt*((P=H+gt*he)-St))+gt*(P+gt*(Z+gt*Bt-P)-ae),_t==0?(Wt=Ht,Ct=yt,zt=Ht,qt=yt):(Wt=Math.min(Wt,Ht),Ct=Math.min(Ct,yt),zt=Math.max(zt,Ht),qt=Math.max(qt,yt));return new l(Math.round(Wt),Math.round(Ct),Math.round(zt-Wt),Math.round(qt-Ct))},wt=function(){if(this.prevLineDash||this.ctx.lineDash.length||this.ctx.lineDashOffset){var x,B,T=(x=this.ctx.lineDash,B=this.ctx.lineDashOffset,JSON.stringify({lineDash:x,lineDashOffset:B}));this.prevLineDash!==T&&(this.pdf.setLineDash(this.ctx.lineDash,this.ctx.lineDashOffset),this.prevLineDash=T)}}})(Mt.API),(function(n){var t=function(c){var l,h,d,m,_,k,p,j,O,M;for(h=[],d=0,m=(c+=l="\0\0\0\0".slice(c.length%4||4)).length;m>d;d+=4)(_=(c.charCodeAt(d)<<24)+(c.charCodeAt(d+1)<<16)+(c.charCodeAt(d+2)<<8)+c.charCodeAt(d+3))!==0?(k=(_=((_=((_=((_=(_-(M=_%85))/85)-(O=_%85))/85)-(j=_%85))/85)-(p=_%85))/85)%85,h.push(k+33,p+33,j+33,O+33,M+33)):h.push(122);return(function(S,V){for(var G=V;G>0;G--)S.pop()})(h,l.length),String.fromCharCode.apply(String,h)+"~>"},e=function(c){var l,h,d,m,_,k=String,p="length",j=255,O="charCodeAt",M="slice",S="replace";for(c[M](-2),c=c[M](0,-2)[S](/\s/g,"")[S]("z","!!!!!"),d=[],m=0,_=(c+=l="uuuuu"[M](c[p]%5||5))[p];_>m;m+=5)h=52200625*(c[O](m)-33)+614125*(c[O](m+1)-33)+7225*(c[O](m+2)-33)+85*(c[O](m+3)-33)+(c[O](m+4)-33),d.push(j&h>>24,j&h>>16,j&h>>8,j&h);return(function(V,G){for(var q=G;q>0;q--)V.pop()})(d,l[p]),k.fromCharCode.apply(k,d)},i=function(c){return c.split("").map(function(l){return("0"+l.charCodeAt().toString(16)).slice(-2)}).join("")+">"},o=function(c){var l=new RegExp(/^([0-9A-Fa-f]{2})+$/);if((c=c.replace(/\s/g,"")).indexOf(">")!==-1&&(c=c.substr(0,c.indexOf(">"))),c.length%2&&(c+="0"),l.test(c)===!1)return"";for(var h="",d=0;d<c.length;d+=2)h+=String.fromCharCode("0x"+(c[d]+c[d+1]));return h},a=function(c){for(var l=new Uint8Array(c.length),h=c.length;h--;)l[h]=c.charCodeAt(h);return(l=Uo(l)).reduce(function(d,m){return d+String.fromCharCode(m)},"")};n.processDataByFilters=function(c,l){var h=0,d=c||"",m=[];for(typeof(l=l||[])=="string"&&(l=[l]),h=0;h<l.length;h+=1)switch(l[h]){case"ASCII85Decode":case"/ASCII85Decode":d=e(d),m.push("/ASCII85Encode");break;case"ASCII85Encode":case"/ASCII85Encode":d=t(d),m.push("/ASCII85Decode");break;case"ASCIIHexDecode":case"/ASCIIHexDecode":d=o(d),m.push("/ASCIIHexEncode");break;case"ASCIIHexEncode":case"/ASCIIHexEncode":d=i(d),m.push("/ASCIIHexDecode");break;case"FlateEncode":case"/FlateEncode":d=a(d),m.push("/FlateDecode");break;default:throw new Error('The filter: "'+l[h]+'" is not implemented')}return{data:d,reverseChain:m.reverse().join(" ")}}})(Mt.API),(function(n){n.loadFile=function(t,e,i){return(function(o,a,c){a=a!==!1,c=typeof c=="function"?c:function(){};var l=void 0;try{l=(function(h,d,m){var _=new XMLHttpRequest,k=0,p=function(j){var O=j.length,M=[],S=String.fromCharCode;for(k=0;k<O;k+=1)M.push(S(255&j.charCodeAt(k)));return M.join("")};if(_.open("GET",h,!d),_.overrideMimeType("text/plain; charset=x-user-defined"),d===!1&&(_.onload=function(){_.status===200?m(p(this.responseText)):m(void 0)}),_.send(null),d&&_.status===200)return p(_.responseText)})(o,a,c)}catch{}return l})(t,e,i)},n.allowFsRead=void 0,n.loadImageFile=n.loadFile})(Mt.API),(function(n){function t(){return(Kt.html2canvas?Promise.resolve(Kt.html2canvas):mo(()=>import("./html2canvas.esm-DXEQVQnt.js"),[])).catch(function(l){return Promise.reject(new Error("Could not load html2canvas: "+l))}).then(function(l){return l.default?l.default:l})}function e(){return(Kt.DOMPurify?Promise.resolve(Kt.DOMPurify):mo(()=>import("./purify.es-CovBOfck.js"),[])).catch(function(l){return Promise.reject(new Error("Could not load dompurify: "+l))}).then(function(l){return l.default?l.default:l})}var i=function(l){var h=xe(l);return h==="undefined"?"undefined":h==="string"||l instanceof String?"string":h==="number"||l instanceof Number?"number":h==="function"||l instanceof Function?"function":l&&l.constructor===Array?"array":l&&l.nodeType===1?"element":h==="object"?"object":"unknown"},o=function(l,h){var d=document.createElement(l);for(var m in h.className&&(d.className=h.className),h.innerHTML&&h.dompurify&&(d.innerHTML=h.dompurify.sanitize(h.innerHTML)),h.style)d.style[m]=h.style[m];return d},a=function l(h,d){for(var m=h.nodeType===3?document.createTextNode(h.nodeValue):h.cloneNode(!1),_=h.firstChild;_;_=_.nextSibling)d!==!0&&_.nodeType===1&&_.nodeName==="SCRIPT"||m.appendChild(l(_,d));return h.nodeType===1&&(h.nodeName==="CANVAS"?(m.width=h.width,m.height=h.height,m.getContext("2d").drawImage(h,0,0)):h.nodeName!=="TEXTAREA"&&h.nodeName!=="SELECT"||(m.value=h.value),m.addEventListener("load",function(){m.scrollTop=h.scrollTop,m.scrollLeft=h.scrollLeft},!0)),m},c=function l(h){var d=Object.assign(l.convert(Promise.resolve()),JSON.parse(JSON.stringify(l.template))),m=l.convert(Promise.resolve(),d);return(m=m.setProgress(1,l,1,[l])).set(h)};(c.prototype=Object.create(Promise.prototype)).constructor=c,c.convert=function(l,h){return l.__proto__=h||c.prototype,l},c.template={prop:{src:null,container:null,overlay:null,canvas:null,img:null,pdf:null,pageSize:null,callback:function(){}},progress:{val:0,state:null,n:0,stack:[]},opt:{filename:"file.pdf",margin:[0,0,0,0],enableLinks:!0,x:0,y:0,html2canvas:{},jsPDF:{},backgroundColor:"transparent"}},c.prototype.from=function(l,h){return this.then(function(){switch(h=h||(function(d){switch(i(d)){case"string":return"string";case"element":return d.nodeName.toLowerCase()==="canvas"?"canvas":"element";default:return"unknown"}})(l),h){case"string":return this.then(e).then(function(d){return this.set({src:o("div",{innerHTML:l,dompurify:d})})});case"element":return this.set({src:l});case"canvas":return this.set({canvas:l});case"img":return this.set({img:l});default:return this.error("Unknown source type.")}})},c.prototype.to=function(l){switch(l){case"container":return this.toContainer();case"canvas":return this.toCanvas();case"img":return this.toImg();case"pdf":return this.toPdf();default:return this.error("Invalid target.")}},c.prototype.toContainer=function(){return this.thenList([function(){return this.prop.src||this.error("Cannot duplicate - no source HTML.")},function(){return this.prop.pageSize||this.setPageSize()}]).then(function(){var l={position:"relative",display:"inline-block",width:(typeof this.opt.width!="number"||isNaN(this.opt.width)||typeof this.opt.windowWidth!="number"||isNaN(this.opt.windowWidth)?Math.max(this.prop.src.clientWidth,this.prop.src.scrollWidth,this.prop.src.offsetWidth):this.opt.windowWidth)+"px",left:0,right:0,top:0,margin:"auto",backgroundColor:this.opt.backgroundColor},h=a(this.prop.src,this.opt.html2canvas.javascriptEnabled);h.tagName==="BODY"&&(l.height=Math.max(document.body.scrollHeight,document.body.offsetHeight,document.documentElement.clientHeight,document.documentElement.scrollHeight,document.documentElement.offsetHeight)+"px"),this.prop.overlay=o("div",{className:"html2pdf__overlay",style:{position:"fixed",overflow:"hidden",zIndex:1e3,left:"-100000px",right:0,bottom:0,top:0}}),this.prop.container=o("div",{className:"html2pdf__container",style:l}),this.prop.container.appendChild(h),this.prop.container.firstChild.appendChild(o("div",{style:{clear:"both",border:"0 none transparent",margin:0,padding:0,height:0}})),this.prop.container.style.float="none",this.prop.overlay.appendChild(this.prop.container),document.body.appendChild(this.prop.overlay),this.prop.container.firstChild.style.position="relative",this.prop.container.height=Math.max(this.prop.container.firstChild.clientHeight,this.prop.container.firstChild.scrollHeight,this.prop.container.firstChild.offsetHeight)+"px"})},c.prototype.toCanvas=function(){var l=[function(){return document.body.contains(this.prop.container)||this.toContainer()}];return this.thenList(l).then(t).then(function(h){var d=Object.assign({},this.opt.html2canvas);return delete d.onrendered,h(this.prop.container,d)}).then(function(h){(this.opt.html2canvas.onrendered||function(){})(h),this.prop.canvas=h,document.body.removeChild(this.prop.overlay)})},c.prototype.toContext2d=function(){var l=[function(){return document.body.contains(this.prop.container)||this.toContainer()}];return this.thenList(l).then(t).then(function(h){var d=this.opt.jsPDF,m=this.opt.fontFaces,_=typeof this.opt.width!="number"||isNaN(this.opt.width)||typeof this.opt.windowWidth!="number"||isNaN(this.opt.windowWidth)?1:this.opt.width/this.opt.windowWidth,k=Object.assign({async:!0,allowTaint:!0,scale:_,scrollX:this.opt.scrollX||0,scrollY:this.opt.scrollY||0,backgroundColor:"#ffffff",imageTimeout:15e3,logging:!0,proxy:null,removeContainer:!0,foreignObjectRendering:!1,useCORS:!1},this.opt.html2canvas);if(delete k.onrendered,d.context2d.autoPaging=this.opt.autoPaging===void 0||this.opt.autoPaging,d.context2d.posX=this.opt.x,d.context2d.posY=this.opt.y,d.context2d.margin=this.opt.margin,d.context2d.fontFaces=m,m)for(var p=0;p<m.length;++p){var j=m[p],O=j.src.find(function(M){return M.format==="truetype"});O&&d.addFont(O.url,j.ref.name,j.ref.style)}return k.windowHeight=k.windowHeight||0,k.windowHeight=k.windowHeight==0?Math.max(this.prop.container.clientHeight,this.prop.container.scrollHeight,this.prop.container.offsetHeight):k.windowHeight,d.context2d.save(!0),h(this.prop.container,k)}).then(function(h){this.opt.jsPDF.context2d.restore(!0),(this.opt.html2canvas.onrendered||function(){})(h),this.prop.canvas=h,document.body.removeChild(this.prop.overlay)})},c.prototype.toImg=function(){return this.thenList([function(){return this.prop.canvas||this.toCanvas()}]).then(function(){var l=this.prop.canvas.toDataURL("image/"+this.opt.image.type,this.opt.image.quality);this.prop.img=document.createElement("img"),this.prop.img.src=l})},c.prototype.toPdf=function(){return this.thenList([function(){return this.toContext2d()}]).then(function(){this.prop.pdf=this.prop.pdf||this.opt.jsPDF})},c.prototype.output=function(l,h,d){return(d=d||"pdf").toLowerCase()==="img"||d.toLowerCase()==="image"?this.outputImg(l,h):this.outputPdf(l,h)},c.prototype.outputPdf=function(l,h){return this.thenList([function(){return this.prop.pdf||this.toPdf()}]).then(function(){return this.prop.pdf.output(l,h)})},c.prototype.outputImg=function(l){return this.thenList([function(){return this.prop.img||this.toImg()}]).then(function(){switch(l){case void 0:case"img":return this.prop.img;case"datauristring":case"dataurlstring":return this.prop.img.src;case"datauri":case"dataurl":return document.location.href=this.prop.img.src;default:throw'Image output type "'+l+'" is not supported.'}})},c.prototype.save=function(l){return this.thenList([function(){return this.prop.pdf||this.toPdf()}]).set(l?{filename:l}:null).then(function(){this.prop.pdf.save(this.opt.filename)})},c.prototype.doCallback=function(){return this.thenList([function(){return this.prop.pdf||this.toPdf()}]).then(function(){this.prop.callback(this.prop.pdf)})},c.prototype.set=function(l){if(i(l)!=="object")return this;var h=Object.keys(l||{}).map(function(d){if(d in c.template.prop)return function(){this.prop[d]=l[d]};switch(d){case"margin":return this.setMargin.bind(this,l.margin);case"jsPDF":return function(){return this.opt.jsPDF=l.jsPDF,this.setPageSize()};case"pageSize":return this.setPageSize.bind(this,l.pageSize);default:return function(){this.opt[d]=l[d]}}},this);return this.then(function(){return this.thenList(h)})},c.prototype.get=function(l,h){return this.then(function(){var d=l in c.template.prop?this.prop[l]:this.opt[l];return h?h(d):d})},c.prototype.setMargin=function(l){return this.then(function(){switch(i(l)){case"number":l=[l,l,l,l];case"array":if(l.length===2&&(l=[l[0],l[1],l[0],l[1]]),l.length===4)break;default:return this.error("Invalid margin array.")}this.opt.margin=l}).then(this.setPageSize)},c.prototype.setPageSize=function(l){function h(d,m){return Math.floor(d*m/72*96)}return this.then(function(){(l=l||Mt.getPageSize(this.opt.jsPDF)).hasOwnProperty("inner")||(l.inner={width:l.width-this.opt.margin[1]-this.opt.margin[3],height:l.height-this.opt.margin[0]-this.opt.margin[2]},l.inner.px={width:h(l.inner.width,l.k),height:h(l.inner.height,l.k)},l.inner.ratio=l.inner.height/l.inner.width),this.prop.pageSize=l})},c.prototype.setProgress=function(l,h,d,m){return l!=null&&(this.progress.val=l),h!=null&&(this.progress.state=h),d!=null&&(this.progress.n=d),m!=null&&(this.progress.stack=m),this.progress.ratio=this.progress.val/this.progress.state,this},c.prototype.updateProgress=function(l,h,d,m){return this.setProgress(l?this.progress.val+l:null,h||null,d?this.progress.n+d:null,m?this.progress.stack.concat(m):null)},c.prototype.then=function(l,h){var d=this;return this.thenCore(l,h,function(m,_){return d.updateProgress(null,null,1,[m]),Promise.prototype.then.call(this,function(k){return d.updateProgress(null,m),k}).then(m,_).then(function(k){return d.updateProgress(1),k})})},c.prototype.thenCore=function(l,h,d){d=d||Promise.prototype.then;var m=this;l&&(l=l.bind(m)),h&&(h=h.bind(m));var _=Promise.toString().indexOf("[native code]")!==-1&&Promise.name==="Promise"?m:c.convert(Object.assign({},m),Promise.prototype),k=d.call(_,l,h);return c.convert(k,m.__proto__)},c.prototype.thenExternal=function(l,h){return Promise.prototype.then.call(this,l,h)},c.prototype.thenList=function(l){var h=this;return l.forEach(function(d){h=h.thenCore(d)}),h},c.prototype.catch=function(l){l&&(l=l.bind(this));var h=Promise.prototype.catch.call(this,l);return c.convert(h,this)},c.prototype.catchExternal=function(l){return Promise.prototype.catch.call(this,l)},c.prototype.error=function(l){return this.then(function(){throw new Error(l)})},c.prototype.using=c.prototype.set,c.prototype.saveAs=c.prototype.save,c.prototype.export=c.prototype.output,c.prototype.run=c.prototype.then,Mt.getPageSize=function(l,h,d){if(xe(l)==="object"){var m=l;l=m.orientation,h=m.unit||h,d=m.format||d}h=h||"mm",d=d||"a4",l=(""+(l||"P")).toLowerCase();var _,k=(""+d).toLowerCase(),p={a0:[2383.94,3370.39],a1:[1683.78,2383.94],a2:[1190.55,1683.78],a3:[841.89,1190.55],a4:[595.28,841.89],a5:[419.53,595.28],a6:[297.64,419.53],a7:[209.76,297.64],a8:[147.4,209.76],a9:[104.88,147.4],a10:[73.7,104.88],b0:[2834.65,4008.19],b1:[2004.09,2834.65],b2:[1417.32,2004.09],b3:[1000.63,1417.32],b4:[708.66,1000.63],b5:[498.9,708.66],b6:[354.33,498.9],b7:[249.45,354.33],b8:[175.75,249.45],b9:[124.72,175.75],b10:[87.87,124.72],c0:[2599.37,3676.54],c1:[1836.85,2599.37],c2:[1298.27,1836.85],c3:[918.43,1298.27],c4:[649.13,918.43],c5:[459.21,649.13],c6:[323.15,459.21],c7:[229.61,323.15],c8:[161.57,229.61],c9:[113.39,161.57],c10:[79.37,113.39],dl:[311.81,623.62],letter:[612,792],"government-letter":[576,756],legal:[612,1008],"junior-legal":[576,360],ledger:[1224,792],tabloid:[792,1224],"credit-card":[153,243]};switch(h){case"pt":_=1;break;case"mm":_=72/25.4;break;case"cm":_=72/2.54;break;case"in":_=72;break;case"px":_=.75;break;case"pc":case"em":_=12;break;case"ex":_=6;break;default:throw"Invalid unit: "+h}var j,O=0,M=0;if(p.hasOwnProperty(k))O=p[k][1]/_,M=p[k][0]/_;else try{O=d[1],M=d[0]}catch{throw new Error("Invalid format: "+d)}if(l==="p"||l==="portrait")l="p",M>O&&(j=M,M=O,O=j);else{if(l!=="l"&&l!=="landscape")throw"Invalid orientation: "+l;l="l",O>M&&(j=M,M=O,O=j)}return{width:M,height:O,unit:h,k:_,orientation:l}},n.html=function(l,h){(h=h||{}).callback=h.callback||function(){},h.html2canvas=h.html2canvas||{},h.html2canvas.canvas=h.html2canvas.canvas||this.canvas,h.jsPDF=h.jsPDF||this,h.fontFaces=h.fontFaces?h.fontFaces.map(jo):null;var d=new c(h);return h.worker?d:d.from(l).doCallback()}})(Mt.API),Mt.API.addJS=function(n){var t,e,i=(function(o){for(var a="",c=0;c<o.length;c++){var l=o[c];if(l==="("||l===")"){for(var h=0,d=c-1;d>=0&&o[d]==="\\";d--)h++;a+=h%2==0?"\\"+l:l}else a+=l}return a})(n);return this.internal.events.subscribe("postPutResources",function(){t=this.internal.newObject(),this.internal.out("<<"),this.internal.out("/Names [(EmbeddedJS) "+(t+1)+" 0 R]"),this.internal.out(">>"),this.internal.out("endobj"),e=this.internal.newObject(),this.internal.out("<<"),this.internal.out("/S /JavaScript"),this.internal.out("/JS ("+i+")"),this.internal.out(">>"),this.internal.out("endobj")}),this.internal.events.subscribe("putCatalog",function(){t!==void 0&&e!==void 0&&this.internal.out("/Names <</JavaScript "+t+" 0 R>>")}),this},(function(n){var t;n.events.push(["postPutResources",function(){var e=this,i=/^(\d+) 0 obj$/;if(this.outline.root.children.length>0)for(var o=e.outline.render().split(/\r\n/),a=0;a<o.length;a++){var c=o[a],l=i.exec(c);if(l!=null){var h=l[1];e.internal.newObjectDeferredBegin(h,!1)}e.internal.write(c)}if(this.outline.createNamedDestinations){var d=this.internal.pages.length,m=[];for(a=0;a<d;a++){var _=e.internal.newObject();m.push(_);var k=e.internal.getPageInfo(a+1);e.internal.write("<< /D["+k.objId+" 0 R /XYZ null null null]>> endobj")}var p=e.internal.newObject();for(e.internal.write("<< /Names [ "),a=0;a<m.length;a++)e.internal.write("(page_"+(a+1)+")"+m[a]+" 0 R");e.internal.write(" ] >>","endobj"),t=e.internal.newObject(),e.internal.write("<< /Dests "+p+" 0 R"),e.internal.write(">>","endobj")}}]),n.events.push(["putCatalog",function(){var e=this;e.outline.root.children.length>0&&(e.internal.write("/Outlines",this.outline.makeRef(this.outline.root)),this.outline.createNamedDestinations&&e.internal.write("/Names "+t+" 0 R"))}]),n.events.push(["initialized",function(){var e=this;e.outline={createNamedDestinations:!1,root:{children:[]}},e.outline.add=function(i,o,a){var c={title:o,options:a,children:[]};return i==null&&(i=this.root),i.children.push(c),c},e.outline.render=function(){return this.ctx={},this.ctx.val="",this.ctx.pdf=e,this.genIds_r(this.root),this.renderRoot(this.root),this.renderItems(this.root),this.ctx.val},e.outline.genIds_r=function(i){i.id=e.internal.newObjectDeferred();for(var o=0;o<i.children.length;o++)this.genIds_r(i.children[o])},e.outline.renderRoot=function(i){this.objStart(i),this.line("/Type /Outlines"),i.children.length>0&&(this.line("/First "+this.makeRef(i.children[0])),this.line("/Last "+this.makeRef(i.children[i.children.length-1]))),this.line("/Count "+this.count_r({count:0},i)),this.objEnd()},e.outline.renderItems=function(i){for(var o=this.ctx.pdf.internal.getVerticalCoordinateString,a=0;a<i.children.length;a++){var c=i.children[a];this.objStart(c),this.line("/Title "+this.makeString(c.title)),this.line("/Parent "+this.makeRef(i)),a>0&&this.line("/Prev "+this.makeRef(i.children[a-1])),a<i.children.length-1&&this.line("/Next "+this.makeRef(i.children[a+1])),c.children.length>0&&(this.line("/First "+this.makeRef(c.children[0])),this.line("/Last "+this.makeRef(c.children[c.children.length-1])));var l=this.count=this.count_r({count:0},c);if(l>0&&this.line("/Count "+l),c.options&&c.options.pageNumber){var h=e.internal.getPageInfo(c.options.pageNumber);this.line("/Dest ["+h.objId+" 0 R /XYZ 0 "+o(0)+" 0]")}this.objEnd()}for(var d=0;d<i.children.length;d++)this.renderItems(i.children[d])},e.outline.line=function(i){this.ctx.val+=i+`\r
43
+ `},e.outline.makeRef=function(i){return i.id+" 0 R"},e.outline.makeString=function(i){return"("+e.internal.pdfEscape(i)+")"},e.outline.objStart=function(i){this.ctx.val+=`\r
44
+ `+i.id+` 0 obj\r
45
+ <<\r
46
+ `},e.outline.objEnd=function(){this.ctx.val+=`>> \r
47
+ endobj\r
48
+ `},e.outline.count_r=function(i,o){for(var a=0;a<o.children.length;a++)i.count++,this.count_r(i,o.children[a]);return i.count}}])})(Mt.API),(function(n){var t=[192,193,194,195,196,197,198,199];n.processJPEG=function(e,i,o,a,c,l){var h,d=this.decode.DCT_DECODE,m=null;if(typeof e=="string"||this.__addimage__.isArrayBuffer(e)||this.__addimage__.isArrayBufferView(e)){switch(e=c||e,e=this.__addimage__.isArrayBuffer(e)?new Uint8Array(e):e,h=(function(_){for(var k,p=256*_.charCodeAt(4)+_.charCodeAt(5),j=_.length,O={width:0,height:0,numcomponents:1},M=4;M<j;M+=2){if(M+=p,t.indexOf(_.charCodeAt(M+1))!==-1){k=256*_.charCodeAt(M+5)+_.charCodeAt(M+6),O={width:256*_.charCodeAt(M+7)+_.charCodeAt(M+8),height:k,numcomponents:_.charCodeAt(M+9)};break}p=256*_.charCodeAt(M+2)+_.charCodeAt(M+3)}return O})(e=this.__addimage__.isArrayBufferView(e)?this.__addimage__.arrayBufferToBinaryString(e):e),h.numcomponents){case 1:l=this.color_spaces.DEVICE_GRAY;break;case 4:l=this.color_spaces.DEVICE_CMYK;break;case 3:l=this.color_spaces.DEVICE_RGB}m={data:e,width:h.width,height:h.height,colorSpace:l,bitsPerComponent:8,filter:d,index:i,alias:o}}return m}})(Mt.API),Mt.API.processPNG=function(n,t,e,i){if(this.__addimage__.isArrayBuffer(n)&&(n=new Uint8Array(n)),this.__addimage__.isArrayBufferView(n)){var o,a=k1(n,{checkCrc:!0}),c=a.width,l=a.height,h=a.channels,d=a.palette,m=a.depth;o=d&&h===1?(function(X){for(var R=X.width,tt=X.height,N=X.data,E=X.palette,z=X.depth,U=!1,rt=[],ot=[],ft=void 0,nt=!1,ct=0,At=0;At<E.length;At++){var wt=ql(E[At],4),x=wt[0],B=wt[1],T=wt[2],H=wt[3];rt.push(x,B,T),H!=null&&(H===0?(ct++,ot.length<1&&ot.push(At)):H<255&&(nt=!0))}if(nt||ct>1){U=!0,ot=void 0;var J=R*tt;ft=new Uint8Array(J);for(var Z=new DataView(N.buffer),at=0;at<J;at++){var st=Mo(Z,at,z),gt=ql(E[st],4)[3];ft[at]=gt}}else ct===0&&(ot=void 0);return{colorSpace:"Indexed",colorsPerPixel:1,sMaskBitsPerComponent:U?8:void 0,colorBytes:N,alphaBytes:ft,needSMask:U,palette:rt,mask:ot}})(a):h===2||h===4?(function(X){for(var R=X.data,tt=X.width,N=X.height,E=X.channels,z=X.depth,U=E===2?"DeviceGray":"DeviceRGB",rt=E-1,ot=tt*N,ft=rt,nt=ot*ft,ct=1*ot,At=Math.ceil(nt*z/8),wt=Math.ceil(ct*z/8),x=new Uint8Array(At),B=new Uint8Array(wt),T=new DataView(R.buffer),H=new DataView(x.buffer),J=new DataView(B.buffer),Z=!1,at=0;at<ot;at++){for(var st=at*E,gt=0;gt<ft;gt++)Hu(H,Mo(T,st+gt,z),at*ft+gt,z);var _t=Mo(T,st+ft,z);_t<(1<<z)-1&&(Z=!0),Hu(J,_t,1*at,z)}return{colorSpace:U,colorsPerPixel:rt,sMaskBitsPerComponent:Z?z:void 0,colorBytes:x,alphaBytes:B,needSMask:Z}})(a):(function(X){var R=X.data,tt=X.channels===1?"DeviceGray":"DeviceRGB";return{colorSpace:tt,colorsPerPixel:tt==="DeviceGray"?1:3,colorBytes:R instanceof Uint16Array?(function(N){for(var E=N.length,z=new Uint8Array(2*E),U=new DataView(z.buffer,z.byteOffset,z.byteLength),rt=0;rt<E;rt++)U.setUint16(2*rt,N[rt],!1);return z})(R):R,needSMask:!1}})(a);var _,k,p,j=o,O=j.colorSpace,M=j.colorsPerPixel,S=j.sMaskBitsPerComponent,V=j.colorBytes,G=j.alphaBytes,q=j.needSMask,it=j.palette,vt=j.mask,dt=null;return i!==Mt.API.image_compression.NONE&&typeof Uo=="function"?(dt=(function(X){var R;switch(X){case Mt.API.image_compression.FAST:R=11;break;case Mt.API.image_compression.MEDIUM:R=13;break;case Mt.API.image_compression.SLOW:R=14;break;default:R=12}return R})(i),_=this.decode.FLATE_DECODE,k="/Predictor ".concat(dt," /Colors ").concat(M," /BitsPerComponent ").concat(m," /Columns ").concat(c),n=Tu(V,Math.ceil(c*M*m/8),M,m,i),q&&(p=Tu(G,Math.ceil(c*S/8),1,S,i))):(_=void 0,k=void 0,n=V,q&&(p=G)),(this.__addimage__.isArrayBuffer(n)||this.__addimage__.isArrayBufferView(n))&&(n=this.__addimage__.arrayBufferToBinaryString(n)),(p&&this.__addimage__.isArrayBuffer(p)||this.__addimage__.isArrayBufferView(p))&&(p=this.__addimage__.arrayBufferToBinaryString(p)),{alias:e,data:n,index:t,filter:_,decodeParameters:k,transparency:vt,palette:it,sMask:p,predictor:dt,width:c,height:l,bitsPerComponent:m,sMaskBitsPerComponent:S,colorSpace:O}}},(function(n){n.processGIF89A=function(t,e,i,o){var a=new J1(t),c=a.width,l=a.height,h=[];a.decodeAndBlitFrameRGBA(0,h);var d={data:h,width:c,height:l},m=new Ro(100).encode(d,100);return n.processJPEG.call(this,m,e,i,o)},n.processGIF87A=n.processGIF89A})(Mt.API),Zn.prototype.parseHeader=function(){if(this.fileSize=this.datav.getUint32(this.pos,!0),this.pos+=4,this.reserved=this.datav.getUint32(this.pos,!0),this.pos+=4,this.offset=this.datav.getUint32(this.pos,!0),this.pos+=4,this.headerSize=this.datav.getUint32(this.pos,!0),this.pos+=4,this.width=this.datav.getUint32(this.pos,!0),this.pos+=4,this.height=this.datav.getInt32(this.pos,!0),this.pos+=4,this.planes=this.datav.getUint16(this.pos,!0),this.pos+=2,this.bitPP=this.datav.getUint16(this.pos,!0),this.pos+=2,this.compress=this.datav.getUint32(this.pos,!0),this.pos+=4,this.rawSize=this.datav.getUint32(this.pos,!0),this.pos+=4,this.hr=this.datav.getUint32(this.pos,!0),this.pos+=4,this.vr=this.datav.getUint32(this.pos,!0),this.pos+=4,this.colors=this.datav.getUint32(this.pos,!0),this.pos+=4,this.importantColors=this.datav.getUint32(this.pos,!0),this.pos+=4,this.bitPP===16&&this.is_with_alpha&&(this.bitPP=15),this.bitPP<15){var n=this.colors===0?1<<this.bitPP:this.colors;this.palette=new Array(n);for(var t=0;t<n;t++){var e=this.datav.getUint8(this.pos++,!0),i=this.datav.getUint8(this.pos++,!0),o=this.datav.getUint8(this.pos++,!0),a=this.datav.getUint8(this.pos++,!0);this.palette[t]={red:o,green:i,blue:e,quad:a}}}this.height<0&&(this.height*=-1,this.bottom_up=!1)},Zn.prototype.parseBGR=function(){this.pos=this.offset;var n="bit"+this.bitPP,t=this.width*this.height*4;if(t>536870912)throw new Error("Image dimensions exceed 512MB, which is too large.");this.data=new Uint8Array(t);try{this[n]()}catch(e){Le.log("bit decode error:"+e)}},Zn.prototype.bit1=function(){var n,t=Math.ceil(this.width/8),e=t%4;for(n=this.height-1;n>=0;n--){for(var i=this.bottom_up?n:this.height-1-n,o=0;o<t;o++)for(var a=this.datav.getUint8(this.pos++,!0),c=i*this.width*4+8*o*4,l=0;l<8&&8*o+l<this.width;l++){var h=this.palette[a>>7-l&1];this.data[c+4*l]=h.blue,this.data[c+4*l+1]=h.green,this.data[c+4*l+2]=h.red,this.data[c+4*l+3]=255}e!==0&&(this.pos+=4-e)}},Zn.prototype.bit4=function(){for(var n=Math.ceil(this.width/2),t=n%4,e=this.height-1;e>=0;e--){for(var i=this.bottom_up?e:this.height-1-e,o=0;o<n;o++){var a=this.datav.getUint8(this.pos++,!0),c=i*this.width*4+2*o*4,l=a>>4,h=15&a,d=this.palette[l];if(this.data[c]=d.blue,this.data[c+1]=d.green,this.data[c+2]=d.red,this.data[c+3]=255,2*o+1>=this.width)break;d=this.palette[h],this.data[c+4]=d.blue,this.data[c+4+1]=d.green,this.data[c+4+2]=d.red,this.data[c+4+3]=255}t!==0&&(this.pos+=4-t)}},Zn.prototype.bit8=function(){for(var n=this.width%4,t=this.height-1;t>=0;t--){for(var e=this.bottom_up?t:this.height-1-t,i=0;i<this.width;i++){var o=this.datav.getUint8(this.pos++,!0),a=e*this.width*4+4*i;if(o<this.palette.length){var c=this.palette[o];this.data[a]=c.red,this.data[a+1]=c.green,this.data[a+2]=c.blue,this.data[a+3]=255}else this.data[a]=255,this.data[a+1]=255,this.data[a+2]=255,this.data[a+3]=255}n!==0&&(this.pos+=4-n)}},Zn.prototype.bit15=function(){for(var n=this.width%3,t=parseInt("11111",2),e=this.height-1;e>=0;e--){for(var i=this.bottom_up?e:this.height-1-e,o=0;o<this.width;o++){var a=this.datav.getUint16(this.pos,!0);this.pos+=2;var c=(a&t)/t*255|0,l=(a>>5&t)/t*255|0,h=(a>>10&t)/t*255|0,d=a>>15?255:0,m=i*this.width*4+4*o;this.data[m]=h,this.data[m+1]=l,this.data[m+2]=c,this.data[m+3]=d}this.pos+=n}},Zn.prototype.bit16=function(){for(var n=this.width%3,t=parseInt("11111",2),e=parseInt("111111",2),i=this.height-1;i>=0;i--){for(var o=this.bottom_up?i:this.height-1-i,a=0;a<this.width;a++){var c=this.datav.getUint16(this.pos,!0);this.pos+=2;var l=(c&t)/t*255|0,h=(c>>5&e)/e*255|0,d=(c>>11)/t*255|0,m=o*this.width*4+4*a;this.data[m]=d,this.data[m+1]=h,this.data[m+2]=l,this.data[m+3]=255}this.pos+=n}},Zn.prototype.bit24=function(){for(var n=this.height-1;n>=0;n--){for(var t=this.bottom_up?n:this.height-1-n,e=0;e<this.width;e++){var i=this.datav.getUint8(this.pos++,!0),o=this.datav.getUint8(this.pos++,!0),a=this.datav.getUint8(this.pos++,!0),c=t*this.width*4+4*e;this.data[c]=a,this.data[c+1]=o,this.data[c+2]=i,this.data[c+3]=255}this.pos+=this.width%4}},Zn.prototype.bit32=function(){for(var n=this.height-1;n>=0;n--)for(var t=this.bottom_up?n:this.height-1-n,e=0;e<this.width;e++){var i=this.datav.getUint8(this.pos++,!0),o=this.datav.getUint8(this.pos++,!0),a=this.datav.getUint8(this.pos++,!0),c=this.datav.getUint8(this.pos++,!0),l=t*this.width*4+4*e;this.data[l]=a,this.data[l+1]=o,this.data[l+2]=i,this.data[l+3]=c}},Zn.prototype.getData=function(){return this.data},(function(n){n.processBMP=function(t,e,i,o){var a=new Zn(t,!1),c=a.width,l=a.height,h={data:a.getData(),width:c,height:l},d=new Ro(100).encode(h,100);return n.processJPEG.call(this,d,e,i,o)}})(Mt.API),Vu.prototype.getData=function(){return this.data},(function(n){n.processWEBP=function(t,e,i,o){var a=new Vu(t),c=a.width,l=a.height,h={data:a.getData(),width:c,height:l},d=new Ro(100).encode(h,100);return n.processJPEG.call(this,d,e,i,o)}})(Mt.API),Mt.API.processRGBA=function(n,t,e){for(var i=n.data,o=i.length,a=new Uint8Array(o/4*3),c=new Uint8Array(o/4),l=0,h=0,d=0;d<o;d+=4){var m=i[d],_=i[d+1],k=i[d+2],p=i[d+3];a[l++]=m,a[l++]=_,a[l++]=k,c[h++]=p}var j=this.__addimage__.arrayBufferToBinaryString(a);return{alpha:this.__addimage__.arrayBufferToBinaryString(c),data:j,index:t,alias:e,colorSpace:"DeviceRGB",bitsPerComponent:8,width:n.width,height:n.height}},Mt.API.setLanguage=function(n){return this.internal.languageSettings===void 0&&(this.internal.languageSettings={},this.internal.languageSettings.isSubscribed=!1),{af:"Afrikaans",sq:"Albanian",ar:"Arabic (Standard)","ar-DZ":"Arabic (Algeria)","ar-BH":"Arabic (Bahrain)","ar-EG":"Arabic (Egypt)","ar-IQ":"Arabic (Iraq)","ar-JO":"Arabic (Jordan)","ar-KW":"Arabic (Kuwait)","ar-LB":"Arabic (Lebanon)","ar-LY":"Arabic (Libya)","ar-MA":"Arabic (Morocco)","ar-OM":"Arabic (Oman)","ar-QA":"Arabic (Qatar)","ar-SA":"Arabic (Saudi Arabia)","ar-SY":"Arabic (Syria)","ar-TN":"Arabic (Tunisia)","ar-AE":"Arabic (U.A.E.)","ar-YE":"Arabic (Yemen)",an:"Aragonese",hy:"Armenian",as:"Assamese",ast:"Asturian",az:"Azerbaijani",eu:"Basque",be:"Belarusian",bn:"Bengali",bs:"Bosnian",br:"Breton",bg:"Bulgarian",my:"Burmese",ca:"Catalan",ch:"Chamorro",ce:"Chechen",zh:"Chinese","zh-HK":"Chinese (Hong Kong)","zh-CN":"Chinese (PRC)","zh-SG":"Chinese (Singapore)","zh-TW":"Chinese (Taiwan)",cv:"Chuvash",co:"Corsican",cr:"Cree",hr:"Croatian",cs:"Czech",da:"Danish",nl:"Dutch (Standard)","nl-BE":"Dutch (Belgian)",en:"English","en-AU":"English (Australia)","en-BZ":"English (Belize)","en-CA":"English (Canada)","en-IE":"English (Ireland)","en-JM":"English (Jamaica)","en-NZ":"English (New Zealand)","en-PH":"English (Philippines)","en-ZA":"English (South Africa)","en-TT":"English (Trinidad & Tobago)","en-GB":"English (United Kingdom)","en-US":"English (United States)","en-ZW":"English (Zimbabwe)",eo:"Esperanto",et:"Estonian",fo:"Faeroese",fj:"Fijian",fi:"Finnish",fr:"French (Standard)","fr-BE":"French (Belgium)","fr-CA":"French (Canada)","fr-FR":"French (France)","fr-LU":"French (Luxembourg)","fr-MC":"French (Monaco)","fr-CH":"French (Switzerland)",fy:"Frisian",fur:"Friulian",gd:"Gaelic (Scots)","gd-IE":"Gaelic (Irish)",gl:"Galacian",ka:"Georgian",de:"German (Standard)","de-AT":"German (Austria)","de-DE":"German (Germany)","de-LI":"German (Liechtenstein)","de-LU":"German (Luxembourg)","de-CH":"German (Switzerland)",el:"Greek",gu:"Gujurati",ht:"Haitian",he:"Hebrew",hi:"Hindi",hu:"Hungarian",is:"Icelandic",id:"Indonesian",iu:"Inuktitut",ga:"Irish",it:"Italian (Standard)","it-CH":"Italian (Switzerland)",ja:"Japanese",kn:"Kannada",ks:"Kashmiri",kk:"Kazakh",km:"Khmer",ky:"Kirghiz",tlh:"Klingon",ko:"Korean","ko-KP":"Korean (North Korea)","ko-KR":"Korean (South Korea)",la:"Latin",lv:"Latvian",lt:"Lithuanian",lb:"Luxembourgish",mk:"North Macedonia",ms:"Malay",ml:"Malayalam",mt:"Maltese",mi:"Maori",mr:"Marathi",mo:"Moldavian",nv:"Navajo",ng:"Ndonga",ne:"Nepali",no:"Norwegian",nb:"Norwegian (Bokmal)",nn:"Norwegian (Nynorsk)",oc:"Occitan",or:"Oriya",om:"Oromo",fa:"Persian","fa-IR":"Persian/Iran",pl:"Polish",pt:"Portuguese","pt-BR":"Portuguese (Brazil)",pa:"Punjabi","pa-IN":"Punjabi (India)","pa-PK":"Punjabi (Pakistan)",qu:"Quechua",rm:"Rhaeto-Romanic",ro:"Romanian","ro-MO":"Romanian (Moldavia)",ru:"Russian","ru-MO":"Russian (Moldavia)",sz:"Sami (Lappish)",sg:"Sango",sa:"Sanskrit",sc:"Sardinian",sd:"Sindhi",si:"Singhalese",sr:"Serbian",sk:"Slovak",sl:"Slovenian",so:"Somani",sb:"Sorbian",es:"Spanish","es-AR":"Spanish (Argentina)","es-BO":"Spanish (Bolivia)","es-CL":"Spanish (Chile)","es-CO":"Spanish (Colombia)","es-CR":"Spanish (Costa Rica)","es-DO":"Spanish (Dominican Republic)","es-EC":"Spanish (Ecuador)","es-SV":"Spanish (El Salvador)","es-GT":"Spanish (Guatemala)","es-HN":"Spanish (Honduras)","es-MX":"Spanish (Mexico)","es-NI":"Spanish (Nicaragua)","es-PA":"Spanish (Panama)","es-PY":"Spanish (Paraguay)","es-PE":"Spanish (Peru)","es-PR":"Spanish (Puerto Rico)","es-ES":"Spanish (Spain)","es-UY":"Spanish (Uruguay)","es-VE":"Spanish (Venezuela)",sx:"Sutu",sw:"Swahili",sv:"Swedish","sv-FI":"Swedish (Finland)","sv-SV":"Swedish (Sweden)",ta:"Tamil",tt:"Tatar",te:"Teluga",th:"Thai",tig:"Tigre",ts:"Tsonga",tn:"Tswana",tr:"Turkish",tk:"Turkmen",uk:"Ukrainian",hsb:"Upper Sorbian",ur:"Urdu",ve:"Venda",vi:"Vietnamese",vo:"Volapuk",wa:"Walloon",cy:"Welsh",xh:"Xhosa",ji:"Yiddish",zu:"Zulu"}[n]!==void 0&&(this.internal.languageSettings.languageCode=n,this.internal.languageSettings.isSubscribed===!1&&(this.internal.events.subscribe("putCatalog",function(){this.internal.write("/Lang ("+this.internal.languageSettings.languageCode+")")}),this.internal.languageSettings.isSubscribed=!0)),this},ta=Mt.API,Ss=ta.getCharWidthsArray=function(n,t){var e,i,o=(t=t||{}).font||this.internal.getFont(),a=t.fontSize||this.internal.getFontSize(),c=t.charSpace||this.internal.getCharSpace(),l=t.widths?t.widths:o.metadata.Unicode.widths,h=l.fof?l.fof:1,d=t.kerning?t.kerning:o.metadata.Unicode.kerning,m=d.fof?d.fof:1,_=t.doKerning!==!1,k=0,p=n.length,j=0,O=l[0]||h,M=[];for(e=0;e<p;e++)i=n.charCodeAt(e),typeof o.metadata.widthOfString=="function"?M.push((o.metadata.widthOfGlyph(o.metadata.characterToGlyph(i))+c*(1e3/a)||0)/1e3):(k=_&&xe(d[i])==="object"&&!isNaN(parseInt(d[i][j],10))?d[i][j]/m:0,M.push((l[i]||O)/h+k)),j=i;return M},Bu=ta.getStringUnitWidth=function(n,t){var e=(t=t||{}).fontSize||this.internal.getFontSize(),i=t.font||this.internal.getFont(),o=t.charSpace||this.internal.getCharSpace();return ta.processArabic&&(n=ta.processArabic(n)),typeof i.metadata.widthOfString=="function"?i.metadata.widthOfString(n,e,o)/e:Ss.apply(this,arguments).reduce(function(a,c){return a+c},0)},Mu=function(n,t,e,i){for(var o=[],a=0,c=n.length,l=0;a!==c&&l+t[a]<e;)l+=t[a],a++;o.push(n.slice(0,a));var h=a;for(l=0;a!==c;)l+t[a]>i&&(o.push(n.slice(h,a)),l=0,h=a),l+=t[a],a++;return h!==a&&o.push(n.slice(h,a)),o},Ru=function(n,t,e){e||(e={});var i,o,a,c,l,h,d,m=[],_=[m],k=e.textIndent||0,p=0,j=0,O=n.split(" "),M=Ss.apply(this,[" ",e])[0];if(h=e.lineIndent===-1?O[0].length+2:e.lineIndent||0){var S=Array(h).join(" "),V=[];O.map(function(q){(q=q.split(/\s*\n/)).length>1?V=V.concat(q.map(function(it,vt){return(vt&&it.length?`
49
+ `:"")+it})):V.push(q[0])}),O=V,h=Bu.apply(this,[S,e])}for(a=0,c=O.length;a<c;a++){var G=0;if(i=O[a],h&&i[0]==`
50
+ `&&(i=i.substr(1),G=1),k+p+(j=(o=Ss.apply(this,[i,e])).reduce(function(q,it){return q+it},0))>t||G){if(j>t){for(l=Mu.apply(this,[i,o,t-(k+p),t]),m.push(l.shift()),m=[l.pop()];l.length;)_.push([l.shift()]);j=o.slice(i.length-(m[0]?m[0].length:0)).reduce(function(q,it){return q+it},0)}else m=[i];_.push(m),k=j+h,p=M}else m.push(i),k+=p+j,p=M}return d=h?function(q,it){return(it?S:"")+q.join(" ")}:function(q){return q.join(" ")},_.map(d)},ta.splitTextToSize=function(n,t,e){var i,o=(e=e||{}).fontSize||this.internal.getFontSize(),a=(function(m){if(m.widths&&m.kerning)return{widths:m.widths,kerning:m.kerning};var _=this.internal.getFont(m.fontName,m.fontStyle),k="Unicode";return _.metadata[k]?{widths:_.metadata[k].widths||{0:1},kerning:_.metadata[k].kerning||{}}:{font:_.metadata,fontSize:this.internal.getFontSize(),charSpace:this.internal.getCharSpace()}}).call(this,e);i=Array.isArray(n)?n:String(n).split(/\r?\n/);var c=1*this.internal.scaleFactor*t/o;a.textIndent=e.textIndent?1*e.textIndent*this.internal.scaleFactor/o:0,a.lineIndent=e.lineIndent;var l,h,d=[];for(l=0,h=i.length;l<h;l++)d=d.concat(Ru.apply(this,[i[l],c,a]));return d},(function(n){n.__fontmetrics__=n.__fontmetrics__||{};for(var t="0123456789abcdef",e="klmnopqrstuvwxyz",i={},o={},a=0;a<16;a++)i[e[a]]=t[a],o[t[a]]=e[a];var c=function(k){return"0x"+parseInt(k,10).toString(16)},l=n.__fontmetrics__.compress=function(k){var p,j,O,M,S=["{"];for(var V in k){if(p=k[V],isNaN(parseInt(V,10))?j="'"+V+"'":(V=parseInt(V,10),j=(j=c(V).slice(2)).slice(0,-1)+o[j.slice(-1)]),typeof p=="number")p<0?(O=c(p).slice(3),M="-"):(O=c(p).slice(2),M=""),O=M+O.slice(0,-1)+o[O.slice(-1)];else{if(xe(p)!=="object")throw new Error("Don't know what to do with value type "+xe(p)+".");O=l(p)}S.push(j+O)}return S.push("}"),S.join("")},h=n.__fontmetrics__.uncompress=function(k){if(typeof k!="string")throw new Error("Invalid argument passed to uncompress.");for(var p,j,O,M,S={},V=1,G=S,q=[],it="",vt="",dt=k.length-1,X=1;X<dt;X+=1)(M=k[X])=="'"?p?(O=p.join(""),p=void 0):p=[]:p?p.push(M):M=="{"?(q.push([G,O]),G={},O=void 0):M=="}"?((j=q.pop())[0][j[1]]=G,O=void 0,G=j[0]):M=="-"?V=-1:O===void 0?i.hasOwnProperty(M)?(it+=i[M],O=parseInt(it,16)*V,V=1,it=""):it+=M:i.hasOwnProperty(M)?(vt+=i[M],G[O]=parseInt(vt,16)*V,V=1,O=void 0,vt=""):vt+=M;return S},d={codePages:["WinAnsiEncoding"],WinAnsiEncoding:h("{19m8n201n9q201o9r201s9l201t9m201u8m201w9n201x9o201y8o202k8q202l8r202m9p202q8p20aw8k203k8t203t8v203u9v2cq8s212m9t15m8w15n9w2dw9s16k8u16l9u17s9z17x8y17y9y}")},m={Unicode:{Courier:d,"Courier-Bold":d,"Courier-BoldOblique":d,"Courier-Oblique":d,Helvetica:d,"Helvetica-Bold":d,"Helvetica-BoldOblique":d,"Helvetica-Oblique":d,"Times-Roman":d,"Times-Bold":d,"Times-BoldItalic":d,"Times-Italic":d}},_={Unicode:{"Courier-Oblique":h("{'widths'{k3w'fof'6o}'kerning'{'fof'-6o}}"),"Times-BoldItalic":h("{'widths'{k3o2q4ycx2r201n3m201o6o201s2l201t2l201u2l201w3m201x3m201y3m2k1t2l2r202m2n2n3m2o3m2p5n202q6o2r1w2s2l2t2l2u3m2v3t2w1t2x2l2y1t2z1w3k3m3l3m3m3m3n3m3o3m3p3m3q3m3r3m3s3m203t2l203u2l3v2l3w3t3x3t3y3t3z3m4k5n4l4m4m4m4n4m4o4s4p4m4q4m4r4s4s4y4t2r4u3m4v4m4w3x4x5t4y4s4z4s5k3x5l4s5m4m5n3r5o3x5p4s5q4m5r5t5s4m5t3x5u3x5v2l5w1w5x2l5y3t5z3m6k2l6l3m6m3m6n2w6o3m6p2w6q2l6r3m6s3r6t1w6u1w6v3m6w1w6x4y6y3r6z3m7k3m7l3m7m2r7n2r7o1w7p3r7q2w7r4m7s3m7t2w7u2r7v2n7w1q7x2n7y3t202l3mcl4mal2ram3man3mao3map3mar3mas2lat4uau1uav3maw3way4uaz2lbk2sbl3t'fof'6obo2lbp3tbq3mbr1tbs2lbu1ybv3mbz3mck4m202k3mcm4mcn4mco4mcp4mcq5ycr4mcs4mct4mcu4mcv4mcw2r2m3rcy2rcz2rdl4sdm4sdn4sdo4sdp4sdq4sds4sdt4sdu4sdv4sdw4sdz3mek3mel3mem3men3meo3mep3meq4ser2wes2wet2weu2wev2wew1wex1wey1wez1wfl3rfm3mfn3mfo3mfp3mfq3mfr3tfs3mft3rfu3rfv3rfw3rfz2w203k6o212m6o2dw2l2cq2l3t3m3u2l17s3x19m3m}'kerning'{cl{4qu5kt5qt5rs17ss5ts}201s{201ss}201t{cks4lscmscnscoscpscls2wu2yu201ts}201x{2wu2yu}2k{201ts}2w{4qx5kx5ou5qx5rs17su5tu}2x{17su5tu5ou}2y{4qx5kx5ou5qx5rs17ss5ts}'fof'-6ofn{17sw5tw5ou5qw5rs}7t{cksclscmscnscoscps4ls}3u{17su5tu5os5qs}3v{17su5tu5os5qs}7p{17su5tu}ck{4qu5kt5qt5rs17ss5ts}4l{4qu5kt5qt5rs17ss5ts}cm{4qu5kt5qt5rs17ss5ts}cn{4qu5kt5qt5rs17ss5ts}co{4qu5kt5qt5rs17ss5ts}cp{4qu5kt5qt5rs17ss5ts}6l{4qu5ou5qw5rt17su5tu}5q{ckuclucmucnucoucpu4lu}5r{ckuclucmucnucoucpu4lu}7q{cksclscmscnscoscps4ls}6p{4qu5ou5qw5rt17sw5tw}ek{4qu5ou5qw5rt17su5tu}el{4qu5ou5qw5rt17su5tu}em{4qu5ou5qw5rt17su5tu}en{4qu5ou5qw5rt17su5tu}eo{4qu5ou5qw5rt17su5tu}ep{4qu5ou5qw5rt17su5tu}es{17ss5ts5qs4qu}et{4qu5ou5qw5rt17sw5tw}eu{4qu5ou5qw5rt17ss5ts}ev{17ss5ts5qs4qu}6z{17sw5tw5ou5qw5rs}fm{17sw5tw5ou5qw5rs}7n{201ts}fo{17sw5tw5ou5qw5rs}fp{17sw5tw5ou5qw5rs}fq{17sw5tw5ou5qw5rs}7r{cksclscmscnscoscps4ls}fs{17sw5tw5ou5qw5rs}ft{17su5tu}fu{17su5tu}fv{17su5tu}fw{17su5tu}fz{cksclscmscnscoscps4ls}}}"),"Helvetica-Bold":h("{'widths'{k3s2q4scx1w201n3r201o6o201s1w201t1w201u1w201w3m201x3m201y3m2k1w2l2l202m2n2n3r2o3r2p5t202q6o2r1s2s2l2t2l2u2r2v3u2w1w2x2l2y1w2z1w3k3r3l3r3m3r3n3r3o3r3p3r3q3r3r3r3s3r203t2l203u2l3v2l3w3u3x3u3y3u3z3x4k6l4l4s4m4s4n4s4o4s4p4m4q3x4r4y4s4s4t1w4u3r4v4s4w3x4x5n4y4s4z4y5k4m5l4y5m4s5n4m5o3x5p4s5q4m5r5y5s4m5t4m5u3x5v2l5w1w5x2l5y3u5z3r6k2l6l3r6m3x6n3r6o3x6p3r6q2l6r3x6s3x6t1w6u1w6v3r6w1w6x5t6y3x6z3x7k3x7l3x7m2r7n3r7o2l7p3x7q3r7r4y7s3r7t3r7u3m7v2r7w1w7x2r7y3u202l3rcl4sal2lam3ran3rao3rap3rar3ras2lat4tau2pav3raw3uay4taz2lbk2sbl3u'fof'6obo2lbp3xbq3rbr1wbs2lbu2obv3rbz3xck4s202k3rcm4scn4sco4scp4scq6ocr4scs4mct4mcu4mcv4mcw1w2m2zcy1wcz1wdl4sdm4ydn4ydo4ydp4ydq4yds4ydt4sdu4sdv4sdw4sdz3xek3rel3rem3ren3reo3rep3req5ter3res3ret3reu3rev3rew1wex1wey1wez1wfl3xfm3xfn3xfo3xfp3xfq3xfr3ufs3xft3xfu3xfv3xfw3xfz3r203k6o212m6o2dw2l2cq2l3t3r3u2l17s4m19m3r}'kerning'{cl{4qs5ku5ot5qs17sv5tv}201t{2ww4wy2yw}201w{2ks}201x{2ww4wy2yw}2k{201ts201xs}2w{7qs4qu5kw5os5qw5rs17su5tu7tsfzs}2x{5ow5qs}2y{7qs4qu5kw5os5qw5rs17su5tu7tsfzs}'fof'-6o7p{17su5tu5ot}ck{4qs5ku5ot5qs17sv5tv}4l{4qs5ku5ot5qs17sv5tv}cm{4qs5ku5ot5qs17sv5tv}cn{4qs5ku5ot5qs17sv5tv}co{4qs5ku5ot5qs17sv5tv}cp{4qs5ku5ot5qs17sv5tv}6l{17st5tt5os}17s{2kwclvcmvcnvcovcpv4lv4wwckv}5o{2kucltcmtcntcotcpt4lt4wtckt}5q{2ksclscmscnscoscps4ls4wvcks}5r{2ks4ws}5t{2kwclvcmvcnvcovcpv4lv4wwckv}eo{17st5tt5os}fu{17su5tu5ot}6p{17ss5ts}ek{17st5tt5os}el{17st5tt5os}em{17st5tt5os}en{17st5tt5os}6o{201ts}ep{17st5tt5os}es{17ss5ts}et{17ss5ts}eu{17ss5ts}ev{17ss5ts}6z{17su5tu5os5qt}fm{17su5tu5os5qt}fn{17su5tu5os5qt}fo{17su5tu5os5qt}fp{17su5tu5os5qt}fq{17su5tu5os5qt}fs{17su5tu5os5qt}ft{17su5tu5ot}7m{5os}fv{17su5tu5ot}fw{17su5tu5ot}}}"),Courier:h("{'widths'{k3w'fof'6o}'kerning'{'fof'-6o}}"),"Courier-BoldOblique":h("{'widths'{k3w'fof'6o}'kerning'{'fof'-6o}}"),"Times-Bold":h("{'widths'{k3q2q5ncx2r201n3m201o6o201s2l201t2l201u2l201w3m201x3m201y3m2k1t2l2l202m2n2n3m2o3m2p6o202q6o2r1w2s2l2t2l2u3m2v3t2w1t2x2l2y1t2z1w3k3m3l3m3m3m3n3m3o3m3p3m3q3m3r3m3s3m203t2l203u2l3v2l3w3t3x3t3y3t3z3m4k5x4l4s4m4m4n4s4o4s4p4m4q3x4r4y4s4y4t2r4u3m4v4y4w4m4x5y4y4s4z4y5k3x5l4y5m4s5n3r5o4m5p4s5q4s5r6o5s4s5t4s5u4m5v2l5w1w5x2l5y3u5z3m6k2l6l3m6m3r6n2w6o3r6p2w6q2l6r3m6s3r6t1w6u2l6v3r6w1w6x5n6y3r6z3m7k3r7l3r7m2w7n2r7o2l7p3r7q3m7r4s7s3m7t3m7u2w7v2r7w1q7x2r7y3o202l3mcl4sal2lam3man3mao3map3mar3mas2lat4uau1yav3maw3tay4uaz2lbk2sbl3t'fof'6obo2lbp3rbr1tbs2lbu2lbv3mbz3mck4s202k3mcm4scn4sco4scp4scq6ocr4scs4mct4mcu4mcv4mcw2r2m3rcy2rcz2rdl4sdm4ydn4ydo4ydp4ydq4yds4ydt4sdu4sdv4sdw4sdz3rek3mel3mem3men3meo3mep3meq4ser2wes2wet2weu2wev2wew1wex1wey1wez1wfl3rfm3mfn3mfo3mfp3mfq3mfr3tfs3mft3rfu3rfv3rfw3rfz3m203k6o212m6o2dw2l2cq2l3t3m3u2l17s4s19m3m}'kerning'{cl{4qt5ks5ot5qy5rw17sv5tv}201t{cks4lscmscnscoscpscls4wv}2k{201ts}2w{4qu5ku7mu5os5qx5ru17su5tu}2x{17su5tu5ou5qs}2y{4qv5kv7mu5ot5qz5ru17su5tu}'fof'-6o7t{cksclscmscnscoscps4ls}3u{17su5tu5os5qu}3v{17su5tu5os5qu}fu{17su5tu5ou5qu}7p{17su5tu5ou5qu}ck{4qt5ks5ot5qy5rw17sv5tv}4l{4qt5ks5ot5qy5rw17sv5tv}cm{4qt5ks5ot5qy5rw17sv5tv}cn{4qt5ks5ot5qy5rw17sv5tv}co{4qt5ks5ot5qy5rw17sv5tv}cp{4qt5ks5ot5qy5rw17sv5tv}6l{17st5tt5ou5qu}17s{ckuclucmucnucoucpu4lu4wu}5o{ckuclucmucnucoucpu4lu4wu}5q{ckzclzcmzcnzcozcpz4lz4wu}5r{ckxclxcmxcnxcoxcpx4lx4wu}5t{ckuclucmucnucoucpu4lu4wu}7q{ckuclucmucnucoucpu4lu}6p{17sw5tw5ou5qu}ek{17st5tt5qu}el{17st5tt5ou5qu}em{17st5tt5qu}en{17st5tt5qu}eo{17st5tt5qu}ep{17st5tt5ou5qu}es{17ss5ts5qu}et{17sw5tw5ou5qu}eu{17sw5tw5ou5qu}ev{17ss5ts5qu}6z{17sw5tw5ou5qu5rs}fm{17sw5tw5ou5qu5rs}fn{17sw5tw5ou5qu5rs}fo{17sw5tw5ou5qu5rs}fp{17sw5tw5ou5qu5rs}fq{17sw5tw5ou5qu5rs}7r{cktcltcmtcntcotcpt4lt5os}fs{17sw5tw5ou5qu5rs}ft{17su5tu5ou5qu}7m{5os}fv{17su5tu5ou5qu}fw{17su5tu5ou5qu}fz{cksclscmscnscoscps4ls}}}"),Symbol:h("{'widths'{k3uaw4r19m3m2k1t2l2l202m2y2n3m2p5n202q6o3k3m2s2l2t2l2v3r2w1t3m3m2y1t2z1wbk2sbl3r'fof'6o3n3m3o3m3p3m3q3m3r3m3s3m3t3m3u1w3v1w3w3r3x3r3y3r3z2wbp3t3l3m5v2l5x2l5z3m2q4yfr3r7v3k7w1o7x3k}'kerning'{'fof'-6o}}"),Helvetica:h("{'widths'{k3p2q4mcx1w201n3r201o6o201s1q201t1q201u1q201w2l201x2l201y2l2k1w2l1w202m2n2n3r2o3r2p5t202q6o2r1n2s2l2t2l2u2r2v3u2w1w2x2l2y1w2z1w3k3r3l3r3m3r3n3r3o3r3p3r3q3r3r3r3s3r203t2l203u2l3v1w3w3u3x3u3y3u3z3r4k6p4l4m4m4m4n4s4o4s4p4m4q3x4r4y4s4s4t1w4u3m4v4m4w3r4x5n4y4s4z4y5k4m5l4y5m4s5n4m5o3x5p4s5q4m5r5y5s4m5t4m5u3x5v1w5w1w5x1w5y2z5z3r6k2l6l3r6m3r6n3m6o3r6p3r6q1w6r3r6s3r6t1q6u1q6v3m6w1q6x5n6y3r6z3r7k3r7l3r7m2l7n3m7o1w7p3r7q3m7r4s7s3m7t3m7u3m7v2l7w1u7x2l7y3u202l3rcl4mal2lam3ran3rao3rap3rar3ras2lat4tau2pav3raw3uay4taz2lbk2sbl3u'fof'6obo2lbp3rbr1wbs2lbu2obv3rbz3xck4m202k3rcm4mcn4mco4mcp4mcq6ocr4scs4mct4mcu4mcv4mcw1w2m2ncy1wcz1wdl4sdm4ydn4ydo4ydp4ydq4yds4ydt4sdu4sdv4sdw4sdz3xek3rel3rem3ren3reo3rep3req5ter3mes3ret3reu3rev3rew1wex1wey1wez1wfl3rfm3rfn3rfo3rfp3rfq3rfr3ufs3xft3rfu3rfv3rfw3rfz3m203k6o212m6o2dw2l2cq2l3t3r3u1w17s4m19m3r}'kerning'{5q{4wv}cl{4qs5kw5ow5qs17sv5tv}201t{2wu4w1k2yu}201x{2wu4wy2yu}17s{2ktclucmucnu4otcpu4lu4wycoucku}2w{7qs4qz5k1m17sy5ow5qx5rsfsu5ty7tufzu}2x{17sy5ty5oy5qs}2y{7qs4qz5k1m17sy5ow5qx5rsfsu5ty7tufzu}'fof'-6o7p{17sv5tv5ow}ck{4qs5kw5ow5qs17sv5tv}4l{4qs5kw5ow5qs17sv5tv}cm{4qs5kw5ow5qs17sv5tv}cn{4qs5kw5ow5qs17sv5tv}co{4qs5kw5ow5qs17sv5tv}cp{4qs5kw5ow5qs17sv5tv}6l{17sy5ty5ow}do{17st5tt}4z{17st5tt}7s{fst}dm{17st5tt}dn{17st5tt}5o{ckwclwcmwcnwcowcpw4lw4wv}dp{17st5tt}dq{17st5tt}7t{5ow}ds{17st5tt}5t{2ktclucmucnu4otcpu4lu4wycoucku}fu{17sv5tv5ow}6p{17sy5ty5ow5qs}ek{17sy5ty5ow}el{17sy5ty5ow}em{17sy5ty5ow}en{5ty}eo{17sy5ty5ow}ep{17sy5ty5ow}es{17sy5ty5qs}et{17sy5ty5ow5qs}eu{17sy5ty5ow5qs}ev{17sy5ty5ow5qs}6z{17sy5ty5ow5qs}fm{17sy5ty5ow5qs}fn{17sy5ty5ow5qs}fo{17sy5ty5ow5qs}fp{17sy5ty5qs}fq{17sy5ty5ow5qs}7r{5ow}fs{17sy5ty5ow5qs}ft{17sv5tv5ow}7m{5ow}fv{17sv5tv5ow}fw{17sv5tv5ow}}}"),"Helvetica-BoldOblique":h("{'widths'{k3s2q4scx1w201n3r201o6o201s1w201t1w201u1w201w3m201x3m201y3m2k1w2l2l202m2n2n3r2o3r2p5t202q6o2r1s2s2l2t2l2u2r2v3u2w1w2x2l2y1w2z1w3k3r3l3r3m3r3n3r3o3r3p3r3q3r3r3r3s3r203t2l203u2l3v2l3w3u3x3u3y3u3z3x4k6l4l4s4m4s4n4s4o4s4p4m4q3x4r4y4s4s4t1w4u3r4v4s4w3x4x5n4y4s4z4y5k4m5l4y5m4s5n4m5o3x5p4s5q4m5r5y5s4m5t4m5u3x5v2l5w1w5x2l5y3u5z3r6k2l6l3r6m3x6n3r6o3x6p3r6q2l6r3x6s3x6t1w6u1w6v3r6w1w6x5t6y3x6z3x7k3x7l3x7m2r7n3r7o2l7p3x7q3r7r4y7s3r7t3r7u3m7v2r7w1w7x2r7y3u202l3rcl4sal2lam3ran3rao3rap3rar3ras2lat4tau2pav3raw3uay4taz2lbk2sbl3u'fof'6obo2lbp3xbq3rbr1wbs2lbu2obv3rbz3xck4s202k3rcm4scn4sco4scp4scq6ocr4scs4mct4mcu4mcv4mcw1w2m2zcy1wcz1wdl4sdm4ydn4ydo4ydp4ydq4yds4ydt4sdu4sdv4sdw4sdz3xek3rel3rem3ren3reo3rep3req5ter3res3ret3reu3rev3rew1wex1wey1wez1wfl3xfm3xfn3xfo3xfp3xfq3xfr3ufs3xft3xfu3xfv3xfw3xfz3r203k6o212m6o2dw2l2cq2l3t3r3u2l17s4m19m3r}'kerning'{cl{4qs5ku5ot5qs17sv5tv}201t{2ww4wy2yw}201w{2ks}201x{2ww4wy2yw}2k{201ts201xs}2w{7qs4qu5kw5os5qw5rs17su5tu7tsfzs}2x{5ow5qs}2y{7qs4qu5kw5os5qw5rs17su5tu7tsfzs}'fof'-6o7p{17su5tu5ot}ck{4qs5ku5ot5qs17sv5tv}4l{4qs5ku5ot5qs17sv5tv}cm{4qs5ku5ot5qs17sv5tv}cn{4qs5ku5ot5qs17sv5tv}co{4qs5ku5ot5qs17sv5tv}cp{4qs5ku5ot5qs17sv5tv}6l{17st5tt5os}17s{2kwclvcmvcnvcovcpv4lv4wwckv}5o{2kucltcmtcntcotcpt4lt4wtckt}5q{2ksclscmscnscoscps4ls4wvcks}5r{2ks4ws}5t{2kwclvcmvcnvcovcpv4lv4wwckv}eo{17st5tt5os}fu{17su5tu5ot}6p{17ss5ts}ek{17st5tt5os}el{17st5tt5os}em{17st5tt5os}en{17st5tt5os}6o{201ts}ep{17st5tt5os}es{17ss5ts}et{17ss5ts}eu{17ss5ts}ev{17ss5ts}6z{17su5tu5os5qt}fm{17su5tu5os5qt}fn{17su5tu5os5qt}fo{17su5tu5os5qt}fp{17su5tu5os5qt}fq{17su5tu5os5qt}fs{17su5tu5os5qt}ft{17su5tu5ot}7m{5os}fv{17su5tu5ot}fw{17su5tu5ot}}}"),ZapfDingbats:h("{'widths'{k4u2k1w'fof'6o}'kerning'{'fof'-6o}}"),"Courier-Bold":h("{'widths'{k3w'fof'6o}'kerning'{'fof'-6o}}"),"Times-Italic":h("{'widths'{k3n2q4ycx2l201n3m201o5t201s2l201t2l201u2l201w3r201x3r201y3r2k1t2l2l202m2n2n3m2o3m2p5n202q5t2r1p2s2l2t2l2u3m2v4n2w1t2x2l2y1t2z1w3k3m3l3m3m3m3n3m3o3m3p3m3q3m3r3m3s3m203t2l203u2l3v2l3w4n3x4n3y4n3z3m4k5w4l3x4m3x4n4m4o4s4p3x4q3x4r4s4s4s4t2l4u2w4v4m4w3r4x5n4y4m4z4s5k3x5l4s5m3x5n3m5o3r5p4s5q3x5r5n5s3x5t3r5u3r5v2r5w1w5x2r5y2u5z3m6k2l6l3m6m3m6n2w6o3m6p2w6q1w6r3m6s3m6t1w6u1w6v2w6w1w6x4s6y3m6z3m7k3m7l3m7m2r7n2r7o1w7p3m7q2w7r4m7s2w7t2w7u2r7v2s7w1v7x2s7y3q202l3mcl3xal2ram3man3mao3map3mar3mas2lat4wau1vav3maw4nay4waz2lbk2sbl4n'fof'6obo2lbp3mbq3obr1tbs2lbu1zbv3mbz3mck3x202k3mcm3xcn3xco3xcp3xcq5tcr4mcs3xct3xcu3xcv3xcw2l2m2ucy2lcz2ldl4mdm4sdn4sdo4sdp4sdq4sds4sdt4sdu4sdv4sdw4sdz3mek3mel3mem3men3meo3mep3meq4mer2wes2wet2weu2wev2wew1wex1wey1wez1wfl3mfm3mfn3mfo3mfp3mfq3mfr4nfs3mft3mfu3mfv3mfw3mfz2w203k6o212m6m2dw2l2cq2l3t3m3u2l17s3r19m3m}'kerning'{cl{5kt4qw}201s{201sw}201t{201tw2wy2yy6q-t}201x{2wy2yy}2k{201tw}2w{7qs4qy7rs5ky7mw5os5qx5ru17su5tu}2x{17ss5ts5os}2y{7qs4qy7rs5ky7mw5os5qx5ru17su5tu}'fof'-6o6t{17ss5ts5qs}7t{5os}3v{5qs}7p{17su5tu5qs}ck{5kt4qw}4l{5kt4qw}cm{5kt4qw}cn{5kt4qw}co{5kt4qw}cp{5kt4qw}6l{4qs5ks5ou5qw5ru17su5tu}17s{2ks}5q{ckvclvcmvcnvcovcpv4lv}5r{ckuclucmucnucoucpu4lu}5t{2ks}6p{4qs5ks5ou5qw5ru17su5tu}ek{4qs5ks5ou5qw5ru17su5tu}el{4qs5ks5ou5qw5ru17su5tu}em{4qs5ks5ou5qw5ru17su5tu}en{4qs5ks5ou5qw5ru17su5tu}eo{4qs5ks5ou5qw5ru17su5tu}ep{4qs5ks5ou5qw5ru17su5tu}es{5ks5qs4qs}et{4qs5ks5ou5qw5ru17su5tu}eu{4qs5ks5qw5ru17su5tu}ev{5ks5qs4qs}ex{17ss5ts5qs}6z{4qv5ks5ou5qw5ru17su5tu}fm{4qv5ks5ou5qw5ru17su5tu}fn{4qv5ks5ou5qw5ru17su5tu}fo{4qv5ks5ou5qw5ru17su5tu}fp{4qv5ks5ou5qw5ru17su5tu}fq{4qv5ks5ou5qw5ru17su5tu}7r{5os}fs{4qv5ks5ou5qw5ru17su5tu}ft{17su5tu5qs}fu{17su5tu5qs}fv{17su5tu5qs}fw{17su5tu5qs}}}"),"Times-Roman":h("{'widths'{k3n2q4ycx2l201n3m201o6o201s2l201t2l201u2l201w2w201x2w201y2w2k1t2l2l202m2n2n3m2o3m2p5n202q6o2r1m2s2l2t2l2u3m2v3s2w1t2x2l2y1t2z1w3k3m3l3m3m3m3n3m3o3m3p3m3q3m3r3m3s3m203t2l203u2l3v1w3w3s3x3s3y3s3z2w4k5w4l4s4m4m4n4m4o4s4p3x4q3r4r4s4s4s4t2l4u2r4v4s4w3x4x5t4y4s4z4s5k3r5l4s5m4m5n3r5o3x5p4s5q4s5r5y5s4s5t4s5u3x5v2l5w1w5x2l5y2z5z3m6k2l6l2w6m3m6n2w6o3m6p2w6q2l6r3m6s3m6t1w6u1w6v3m6w1w6x4y6y3m6z3m7k3m7l3m7m2l7n2r7o1w7p3m7q3m7r4s7s3m7t3m7u2w7v3k7w1o7x3k7y3q202l3mcl4sal2lam3man3mao3map3mar3mas2lat4wau1vav3maw3say4waz2lbk2sbl3s'fof'6obo2lbp3mbq2xbr1tbs2lbu1zbv3mbz2wck4s202k3mcm4scn4sco4scp4scq5tcr4mcs3xct3xcu3xcv3xcw2l2m2tcy2lcz2ldl4sdm4sdn4sdo4sdp4sdq4sds4sdt4sdu4sdv4sdw4sdz3mek2wel2wem2wen2weo2wep2weq4mer2wes2wet2weu2wev2wew1wex1wey1wez1wfl3mfm3mfn3mfo3mfp3mfq3mfr3sfs3mft3mfu3mfv3mfw3mfz3m203k6o212m6m2dw2l2cq2l3t3m3u1w17s4s19m3m}'kerning'{cl{4qs5ku17sw5ou5qy5rw201ss5tw201ws}201s{201ss}201t{ckw4lwcmwcnwcowcpwclw4wu201ts}2k{201ts}2w{4qs5kw5os5qx5ru17sx5tx}2x{17sw5tw5ou5qu}2y{4qs5kw5os5qx5ru17sx5tx}'fof'-6o7t{ckuclucmucnucoucpu4lu5os5rs}3u{17su5tu5qs}3v{17su5tu5qs}7p{17sw5tw5qs}ck{4qs5ku17sw5ou5qy5rw201ss5tw201ws}4l{4qs5ku17sw5ou5qy5rw201ss5tw201ws}cm{4qs5ku17sw5ou5qy5rw201ss5tw201ws}cn{4qs5ku17sw5ou5qy5rw201ss5tw201ws}co{4qs5ku17sw5ou5qy5rw201ss5tw201ws}cp{4qs5ku17sw5ou5qy5rw201ss5tw201ws}6l{17su5tu5os5qw5rs}17s{2ktclvcmvcnvcovcpv4lv4wuckv}5o{ckwclwcmwcnwcowcpw4lw4wu}5q{ckyclycmycnycoycpy4ly4wu5ms}5r{cktcltcmtcntcotcpt4lt4ws}5t{2ktclvcmvcnvcovcpv4lv4wuckv}7q{cksclscmscnscoscps4ls}6p{17su5tu5qw5rs}ek{5qs5rs}el{17su5tu5os5qw5rs}em{17su5tu5os5qs5rs}en{17su5qs5rs}eo{5qs5rs}ep{17su5tu5os5qw5rs}es{5qs}et{17su5tu5qw5rs}eu{17su5tu5qs5rs}ev{5qs}6z{17sv5tv5os5qx5rs}fm{5os5qt5rs}fn{17sv5tv5os5qx5rs}fo{17sv5tv5os5qx5rs}fp{5os5qt5rs}fq{5os5qt5rs}7r{ckuclucmucnucoucpu4lu5os}fs{17sv5tv5os5qx5rs}ft{17ss5ts5qs}fu{17sw5tw5qs}fv{17sw5tw5qs}fw{17ss5ts5qs}fz{ckuclucmucnucoucpu4lu5os5rs}}}"),"Helvetica-Oblique":h("{'widths'{k3p2q4mcx1w201n3r201o6o201s1q201t1q201u1q201w2l201x2l201y2l2k1w2l1w202m2n2n3r2o3r2p5t202q6o2r1n2s2l2t2l2u2r2v3u2w1w2x2l2y1w2z1w3k3r3l3r3m3r3n3r3o3r3p3r3q3r3r3r3s3r203t2l203u2l3v1w3w3u3x3u3y3u3z3r4k6p4l4m4m4m4n4s4o4s4p4m4q3x4r4y4s4s4t1w4u3m4v4m4w3r4x5n4y4s4z4y5k4m5l4y5m4s5n4m5o3x5p4s5q4m5r5y5s4m5t4m5u3x5v1w5w1w5x1w5y2z5z3r6k2l6l3r6m3r6n3m6o3r6p3r6q1w6r3r6s3r6t1q6u1q6v3m6w1q6x5n6y3r6z3r7k3r7l3r7m2l7n3m7o1w7p3r7q3m7r4s7s3m7t3m7u3m7v2l7w1u7x2l7y3u202l3rcl4mal2lam3ran3rao3rap3rar3ras2lat4tau2pav3raw3uay4taz2lbk2sbl3u'fof'6obo2lbp3rbr1wbs2lbu2obv3rbz3xck4m202k3rcm4mcn4mco4mcp4mcq6ocr4scs4mct4mcu4mcv4mcw1w2m2ncy1wcz1wdl4sdm4ydn4ydo4ydp4ydq4yds4ydt4sdu4sdv4sdw4sdz3xek3rel3rem3ren3reo3rep3req5ter3mes3ret3reu3rev3rew1wex1wey1wez1wfl3rfm3rfn3rfo3rfp3rfq3rfr3ufs3xft3rfu3rfv3rfw3rfz3m203k6o212m6o2dw2l2cq2l3t3r3u1w17s4m19m3r}'kerning'{5q{4wv}cl{4qs5kw5ow5qs17sv5tv}201t{2wu4w1k2yu}201x{2wu4wy2yu}17s{2ktclucmucnu4otcpu4lu4wycoucku}2w{7qs4qz5k1m17sy5ow5qx5rsfsu5ty7tufzu}2x{17sy5ty5oy5qs}2y{7qs4qz5k1m17sy5ow5qx5rsfsu5ty7tufzu}'fof'-6o7p{17sv5tv5ow}ck{4qs5kw5ow5qs17sv5tv}4l{4qs5kw5ow5qs17sv5tv}cm{4qs5kw5ow5qs17sv5tv}cn{4qs5kw5ow5qs17sv5tv}co{4qs5kw5ow5qs17sv5tv}cp{4qs5kw5ow5qs17sv5tv}6l{17sy5ty5ow}do{17st5tt}4z{17st5tt}7s{fst}dm{17st5tt}dn{17st5tt}5o{ckwclwcmwcnwcowcpw4lw4wv}dp{17st5tt}dq{17st5tt}7t{5ow}ds{17st5tt}5t{2ktclucmucnu4otcpu4lu4wycoucku}fu{17sv5tv5ow}6p{17sy5ty5ow5qs}ek{17sy5ty5ow}el{17sy5ty5ow}em{17sy5ty5ow}en{5ty}eo{17sy5ty5ow}ep{17sy5ty5ow}es{17sy5ty5qs}et{17sy5ty5ow5qs}eu{17sy5ty5ow5qs}ev{17sy5ty5ow5qs}6z{17sy5ty5ow5qs}fm{17sy5ty5ow5qs}fn{17sy5ty5ow5qs}fo{17sy5ty5ow5qs}fp{17sy5ty5qs}fq{17sy5ty5ow5qs}7r{5ow}fs{17sy5ty5ow5qs}ft{17sv5tv5ow}7m{5ow}fv{17sv5tv5ow}fw{17sv5tv5ow}}}")}};n.events.push(["addFont",function(k){var p=k.font,j=_.Unicode[p.postScriptName];j&&(p.metadata.Unicode={},p.metadata.Unicode.widths=j.widths,p.metadata.Unicode.kerning=j.kerning);var O=m.Unicode[p.postScriptName];O&&(p.metadata.Unicode.encoding=O,p.encoding=O.codePages[0])}])})(Mt.API),(function(n){var t=function(e){for(var i=e.length,o=new Uint8Array(i),a=0;a<i;a++)o[a]=e.charCodeAt(a);return o};n.API.events.push(["addFont",function(e){var i=void 0,o=e.font,a=e.instance;if(!o.isStandardFont){if(a===void 0)throw new Error("Font does not exist in vFS, import fonts or remove declaration doc.addFont('"+o.postScriptName+"').");if(typeof(i=a.existsFileInVFS(o.postScriptName)===!1?a.loadFile(o.postScriptName):a.getFileFromVFS(o.postScriptName))!="string")throw new Error("Font is not stored as string-data in vFS, import fonts or remove declaration doc.addFont('"+o.postScriptName+"').");(function(c,l){l=/^\x00\x01\x00\x00/.test(l)?t(l):t(Ps(l)),c.metadata=n.API.TTFFont.open(l),c.metadata.Unicode=c.metadata.Unicode||{encoding:{},kerning:{},widths:[]},c.metadata.glyIdsUsed=[0]})(o,i)}}])})(Mt),Mt.API.addSvgAsImage=function(n,t,e,i,o,a,c,l){if(isNaN(t)||isNaN(e))throw Le.error("jsPDF.addSvgAsImage: Invalid coordinates",arguments),new Error("Invalid coordinates passed to jsPDF.addSvgAsImage");if(isNaN(i)||isNaN(o))throw Le.error("jsPDF.addSvgAsImage: Invalid measurements",arguments),new Error("Invalid measurements (width and/or height) passed to jsPDF.addSvgAsImage");var h=document.createElement("canvas");h.width=i,h.height=o;var d=h.getContext("2d");d.fillStyle="#fff",d.fillRect(0,0,h.width,h.height);var m={ignoreMouse:!0,ignoreAnimation:!0,ignoreDimensions:!0},_=this;return(Kt.canvg?Promise.resolve(Kt.canvg):mo(()=>import("./index.es-Dqr-Y4Tn.js"),__vite__mapDeps([0,1,2]))).catch(function(k){return Promise.reject(new Error("Could not load canvg: "+k))}).then(function(k){return k.default?k.default:k}).then(function(k){return k.fromString(d,n,m)},function(){return Promise.reject(new Error("Could not load canvg."))}).then(function(k){return k.render(m)}).then(function(){_.addImage(h.toDataURL("image/jpeg",1),t,e,i,o,c,l)})},Mt.API.putTotalPages=function(n){var t,e=0;parseInt(this.internal.getFont().id.substr(1),10)<15?(t=new RegExp(n,"g"),e=this.internal.getNumberOfPages()):(t=new RegExp(this.pdfEscape16(n,this.internal.getFont()),"g"),e=this.pdfEscape16(this.internal.getNumberOfPages()+"",this.internal.getFont()));for(var i=1;i<=this.internal.getNumberOfPages();i++)for(var o=0;o<this.internal.pages[i].length;o++)this.internal.pages[i][o]=this.internal.pages[i][o].replace(t,e);return this},Mt.API.viewerPreferences=function(n,t){var e;n=n||{},t=t||!1;var i,o,a,c={HideToolbar:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.3},HideMenubar:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.3},HideWindowUI:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.3},FitWindow:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.3},CenterWindow:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.3},DisplayDocTitle:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.4},NonFullScreenPageMode:{defaultValue:"UseNone",value:"UseNone",type:"name",explicitSet:!1,valueSet:["UseNone","UseOutlines","UseThumbs","UseOC"],pdfVersion:1.3},Direction:{defaultValue:"L2R",value:"L2R",type:"name",explicitSet:!1,valueSet:["L2R","R2L"],pdfVersion:1.3},ViewArea:{defaultValue:"CropBox",value:"CropBox",type:"name",explicitSet:!1,valueSet:["MediaBox","CropBox","TrimBox","BleedBox","ArtBox"],pdfVersion:1.4},ViewClip:{defaultValue:"CropBox",value:"CropBox",type:"name",explicitSet:!1,valueSet:["MediaBox","CropBox","TrimBox","BleedBox","ArtBox"],pdfVersion:1.4},PrintArea:{defaultValue:"CropBox",value:"CropBox",type:"name",explicitSet:!1,valueSet:["MediaBox","CropBox","TrimBox","BleedBox","ArtBox"],pdfVersion:1.4},PrintClip:{defaultValue:"CropBox",value:"CropBox",type:"name",explicitSet:!1,valueSet:["MediaBox","CropBox","TrimBox","BleedBox","ArtBox"],pdfVersion:1.4},PrintScaling:{defaultValue:"AppDefault",value:"AppDefault",type:"name",explicitSet:!1,valueSet:["AppDefault","None"],pdfVersion:1.6},Duplex:{defaultValue:"",value:"none",type:"name",explicitSet:!1,valueSet:["Simplex","DuplexFlipShortEdge","DuplexFlipLongEdge","none"],pdfVersion:1.7},PickTrayByPDFSize:{defaultValue:!1,value:!1,type:"boolean",explicitSet:!1,valueSet:[!0,!1],pdfVersion:1.7},PrintPageRange:{defaultValue:"",value:"",type:"array",explicitSet:!1,valueSet:null,pdfVersion:1.7},NumCopies:{defaultValue:1,value:1,type:"integer",explicitSet:!1,valueSet:null,pdfVersion:1.7}},l=Object.keys(c),h=[],d=0,m=0,_=0;function k(j,O){var M,S=!1;for(M=0;M<j.length;M+=1)j[M]===O&&(S=!0);return S}if(this.internal.viewerpreferences===void 0&&(this.internal.viewerpreferences={},this.internal.viewerpreferences.configuration=JSON.parse(JSON.stringify(c)),this.internal.viewerpreferences.isSubscribed=!1),e=this.internal.viewerpreferences.configuration,n==="reset"||t===!0){var p=l.length;for(_=0;_<p;_+=1)e[l[_]].value=e[l[_]].defaultValue,e[l[_]].explicitSet=!1}if(xe(n)==="object"){for(o in n)if(a=n[o],k(l,o)&&a!==void 0){if(e[o].type==="boolean"&&typeof a=="boolean")e[o].value=a;else if(e[o].type==="name"&&k(e[o].valueSet,a))e[o].value=a;else if(e[o].type==="integer"&&Number.isInteger(a))e[o].value=a;else if(e[o].type==="array"){for(d=0;d<a.length;d+=1)if(i=!0,a[d].length===1&&typeof a[d][0]=="number")h.push(String(a[d]-1));else if(a[d].length>1){for(m=0;m<a[d].length;m+=1)typeof a[d][m]!="number"&&(i=!1);i===!0&&h.push([a[d][0]-1,a[d][1]-1].join(" "))}e[o].value="["+h.join(" ")+"]"}else e[o].value=e[o].defaultValue;e[o].explicitSet=!0}}return this.internal.viewerpreferences.isSubscribed===!1&&(this.internal.events.subscribe("putCatalog",function(){var j,O=[];for(j in e)e[j].explicitSet===!0&&(e[j].type==="name"?O.push("/"+j+" /"+e[j].value):O.push("/"+j+" "+e[j].value));O.length!==0&&this.internal.write(`/ViewerPreferences
51
+ <<
52
+ `+O.join(`
53
+ `)+`
54
+ >>`)}),this.internal.viewerpreferences.isSubscribed=!0),this.internal.viewerpreferences.configuration=e,this},Mt.API.addMetadata=function(n,t){return this.internal.__metadata__===void 0&&(this.internal.__metadata__={metadata:n,namespaceUri:t??"http://jspdf.default.namespaceuri/",rawXml:typeof t=="boolean"&&t},this.internal.events.subscribe("putCatalog",X1),this.internal.events.subscribe("postPutResources",K1)),this},(function(n){var t=n.API,e=t.pdfEscape16=function(a,c){for(var l,h=c.metadata.Unicode.widths,d=["","0","00","000","0000"],m=[""],_=0,k=a.length;_<k;++_){if(l=c.metadata.characterToGlyph(a.charCodeAt(_)),c.metadata.glyIdsUsed.push(l),c.metadata.toUnicode[l]=a.charCodeAt(_),h.indexOf(l)==-1&&(h.push(l),h.push([parseInt(c.metadata.widthOfGlyph(l),10)])),l=="0")return m.join("");l=l.toString(16),m.push(d[4-l.length],l)}return m.join("")},i=function(a){var c,l,h,d,m,_,k;for(m=`/CIDInit /ProcSet findresource begin
55
+ 12 dict begin
56
+ begincmap
57
+ /CIDSystemInfo <<
58
+ /Registry (Adobe)
59
+ /Ordering (UCS)
60
+ /Supplement 0
61
+ >> def
62
+ /CMapName /Adobe-Identity-UCS def
63
+ /CMapType 2 def
64
+ 1 begincodespacerange
65
+ <0000><ffff>
66
+ endcodespacerange`,h=[],_=0,k=(l=Object.keys(a).sort(function(p,j){return p-j})).length;_<k;_++)c=l[_],h.length>=100&&(m+=`
67
+ `+h.length+` beginbfchar
68
+ `+h.join(`
69
+ `)+`
70
+ endbfchar`,h=[]),a[c]!==void 0&&a[c]!==null&&typeof a[c].toString=="function"&&(d=("0000"+a[c].toString(16)).slice(-4),c=("0000"+(+c).toString(16)).slice(-4),h.push("<"+c+"><"+d+">"));return h.length&&(m+=`
71
+ `+h.length+` beginbfchar
72
+ `+h.join(`
73
+ `)+`
74
+ endbfchar
75
+ `),m+`endcmap
76
+ CMapName currentdict /CMap defineresource pop
77
+ end
78
+ end`};t.events.push(["putFont",function(a){(function(c){var l=c.font,h=c.out,d=c.newObject,m=c.putStream;if(l.metadata instanceof n.API.TTFFont&&l.encoding==="Identity-H"){for(var _=l.metadata.Unicode.widths,k=l.metadata.subset.encode(l.metadata.glyIdsUsed,1),p="",j=0;j<k.length;j++)p+=String.fromCharCode(k[j]);var O=d();m({data:p,addLength1:!0,objectId:O}),h("endobj");var M=d();m({data:i(l.metadata.toUnicode),addLength1:!0,objectId:M}),h("endobj");var S=d();h("<<"),h("/Type /FontDescriptor"),h("/FontName /"+na(l.fontName)),h("/FontFile2 "+O+" 0 R"),h("/FontBBox "+n.API.PDFObject.convert(l.metadata.bbox)),h("/Flags "+l.metadata.flags),h("/StemV "+l.metadata.stemV),h("/ItalicAngle "+l.metadata.italicAngle),h("/Ascent "+l.metadata.ascender),h("/Descent "+l.metadata.decender),h("/CapHeight "+l.metadata.capHeight),h(">>"),h("endobj");var V=d();h("<<"),h("/Type /Font"),h("/BaseFont /"+na(l.fontName)),h("/FontDescriptor "+S+" 0 R"),h("/W "+n.API.PDFObject.convert(_)),h("/CIDToGIDMap /Identity"),h("/DW 1000"),h("/Subtype /CIDFontType2"),h("/CIDSystemInfo"),h("<<"),h("/Supplement 0"),h("/Registry (Adobe)"),h("/Ordering ("+l.encoding+")"),h(">>"),h(">>"),h("endobj"),l.objectNumber=d(),h("<<"),h("/Type /Font"),h("/Subtype /Type0"),h("/ToUnicode "+M+" 0 R"),h("/BaseFont /"+na(l.fontName)),h("/Encoding /"+l.encoding),h("/DescendantFonts ["+V+" 0 R]"),h(">>"),h("endobj"),l.isAlreadyPutted=!0}})(a)}]),t.events.push(["putFont",function(a){(function(c){var l=c.font,h=c.out,d=c.newObject,m=c.putStream;if(l.metadata instanceof n.API.TTFFont&&l.encoding==="WinAnsiEncoding"){for(var _=l.metadata.rawData,k="",p=0;p<_.length;p++)k+=String.fromCharCode(_[p]);var j=d();m({data:k,addLength1:!0,objectId:j}),h("endobj");var O=d();m({data:i(l.metadata.toUnicode),addLength1:!0,objectId:O}),h("endobj");var M=d();h("<<"),h("/Descent "+l.metadata.decender),h("/CapHeight "+l.metadata.capHeight),h("/StemV "+l.metadata.stemV),h("/Type /FontDescriptor"),h("/FontFile2 "+j+" 0 R"),h("/Flags 96"),h("/FontBBox "+n.API.PDFObject.convert(l.metadata.bbox)),h("/FontName /"+na(l.fontName)),h("/ItalicAngle "+l.metadata.italicAngle),h("/Ascent "+l.metadata.ascender),h(">>"),h("endobj"),l.objectNumber=d();for(var S=0;S<l.metadata.hmtx.widths.length;S++)l.metadata.hmtx.widths[S]=parseInt(l.metadata.hmtx.widths[S]*(1e3/l.metadata.head.unitsPerEm));h("<</Subtype/TrueType/Type/Font/ToUnicode "+O+" 0 R/BaseFont/"+na(l.fontName)+"/FontDescriptor "+M+" 0 R/Encoding/"+l.encoding+" /FirstChar 29 /LastChar 255 /Widths "+n.API.PDFObject.convert(l.metadata.hmtx.widths)+">>"),h("endobj"),l.isAlreadyPutted=!0}})(a)}]);var o=function(a){var c,l=a.text||"",h=a.x,d=a.y,m=a.options||{},_=a.mutex||{},k=_.pdfEscape,p=_.activeFontKey,j=_.fonts,O=p,M="",S=0,V="",G=j[O].encoding;if(j[O].encoding!=="Identity-H")return{text:l,x:h,y:d,options:m,mutex:_};for(V=l,O=p,Array.isArray(l)&&(V=l[0]),S=0;S<V.length;S+=1)j[O].metadata.hasOwnProperty("cmap")&&(c=j[O].metadata.cmap.unicode.codeMap[V[S].charCodeAt(0)]),c||V[S].charCodeAt(0)<256&&j[O].metadata.hasOwnProperty("Unicode")?M+=V[S]:M+="";var q="";return parseInt(O.slice(1))<14||G==="WinAnsiEncoding"?q=k(M,O).split("").map(function(it){return it.charCodeAt(0).toString(16)}).join(""):G==="Identity-H"&&(q=e(M,j[O])),_.isHex=!0,{text:q,x:h,y:d,options:m,mutex:_}};t.events.push(["postProcessText",function(a){var c=a.text||"",l=[],h={text:c,x:a.x,y:a.y,options:a.options,mutex:a.mutex};if(Array.isArray(c)){var d=0;for(d=0;d<c.length;d+=1)Array.isArray(c[d])&&c[d].length===3?l.push([o(Object.assign({},h,{text:c[d][0]})).text,c[d][1],c[d][2]]):l.push(o(Object.assign({},h,{text:c[d]})).text);a.text=l}else a.text=o(Object.assign({},h,{text:c})).text}])})(Mt),(function(n){var t=function(){return this.internal.vFS===void 0&&(this.internal.vFS={}),!0};n.existsFileInVFS=function(e){return t.call(this),this.internal.vFS[e]!==void 0},n.addFileToVFS=function(e,i){return t.call(this),this.internal.vFS[e]=i,this},n.getFileFromVFS=function(e){return t.call(this),this.internal.vFS[e]!==void 0?this.internal.vFS[e]:null}})(Mt.API),(function(n){n.__bidiEngine__=n.prototype.__bidiEngine__=function(i){var o,a,c,l,h,d,m,_=t,k=[[0,3,0,1,0,0,0],[0,3,0,1,2,2,0],[0,3,0,17,2,0,1],[0,3,5,5,4,1,0],[0,3,21,21,4,0,1],[0,3,5,5,4,2,0]],p=[[2,0,1,1,0,1,0],[2,0,1,1,0,2,0],[2,0,2,1,3,2,0],[2,0,2,33,3,1,1]],j={L:0,R:1,EN:2,AN:3,N:4,B:5,S:6},O={0:0,5:1,6:2,7:3,32:4,251:5,254:6,255:7},M=["(",")","(","<",">","<","[","]","[","{","}","{","«","»","«","‹","›","‹","⁅","⁆","⁅","⁽","⁾","⁽","₍","₎","₍","≤","≥","≤","〈","〉","〈","﹙","﹚","﹙","﹛","﹜","﹛","﹝","﹞","﹝","﹤","﹥","﹤"],S=new RegExp(/^([1-4|9]|1[0-9]|2[0-9]|3[0168]|4[04589]|5[012]|7[78]|159|16[0-9]|17[0-2]|21[569]|22[03489]|250)$/),V=!1,G=0;this.__bidiEngine__={};var q=function(N){var E=N.charCodeAt(),z=E>>8,U=O[z];return U!==void 0?_[256*U+(255&E)]:z===252||z===253?"AL":S.test(z)?"L":z===8?"R":"N"},it=function(N){for(var E,z=0;z<N.length;z++){if((E=q(N.charAt(z)))==="L")return!1;if(E==="R")return!0}return!1},vt=function(N,E,z,U){var rt,ot,ft,nt,ct=E[U];switch(ct){case"L":case"R":case"LRE":case"RLE":case"LRO":case"RLO":case"PDF":V=!1;break;case"N":case"AN":break;case"EN":V&&(ct="AN");break;case"AL":V=!0,ct="R";break;case"WS":case"BN":ct="N";break;case"CS":U<1||U+1>=E.length||(rt=z[U-1])!=="EN"&&rt!=="AN"||(ot=E[U+1])!=="EN"&&ot!=="AN"?ct="N":V&&(ot="AN"),ct=ot===rt?ot:"N";break;case"ES":ct=(rt=U>0?z[U-1]:"B")==="EN"&&U+1<E.length&&E[U+1]==="EN"?"EN":"N";break;case"ET":if(U>0&&z[U-1]==="EN"){ct="EN";break}if(V){ct="N";break}for(ft=U+1,nt=E.length;ft<nt&&E[ft]==="ET";)ft++;ct=ft<nt&&E[ft]==="EN"?"EN":"N";break;case"NSM":if(c&&!l){for(nt=E.length,ft=U+1;ft<nt&&E[ft]==="NSM";)ft++;if(ft<nt){var At=N[U],wt=At>=1425&&At<=2303||At===64286;if(rt=E[ft],wt&&(rt==="R"||rt==="AL")){ct="R";break}}}ct=U<1||(rt=E[U-1])==="B"?"N":z[U-1];break;case"B":V=!1,o=!0,ct=G;break;case"S":a=!0,ct="N"}return ct},dt=function(N,E,z){var U=N.split("");return z&&X(U,z,{hiLevel:G}),U.reverse(),E&&E.reverse(),U.join("")},X=function(N,E,z){var U,rt,ot,ft,nt,ct=-1,At=N.length,wt=0,x=[],B=G?p:k,T=[];for(V=!1,o=!1,a=!1,rt=0;rt<At;rt++)T[rt]=q(N[rt]);for(ot=0;ot<At;ot++){if(nt=wt,x[ot]=vt(N,T,x,ot),U=240&(wt=B[nt][j[x[ot]]]),wt&=15,E[ot]=ft=B[wt][5],U>0)if(U===16){for(rt=ct;rt<ot;rt++)E[rt]=1;ct=-1}else ct=-1;if(B[wt][6])ct===-1&&(ct=ot);else if(ct>-1){for(rt=ct;rt<ot;rt++)E[rt]=ft;ct=-1}T[ot]==="B"&&(E[ot]=0),z.hiLevel|=ft}a&&(function(H,J,Z){for(var at=0;at<Z;at++)if(H[at]==="S"){J[at]=G;for(var st=at-1;st>=0&&H[st]==="WS";st--)J[st]=G}})(T,E,At)},R=function(N,E,z,U,rt){if(!(rt.hiLevel<N)){if(N===1&&G===1&&!o)return E.reverse(),void(z&&z.reverse());for(var ot,ft,nt,ct,At=E.length,wt=0;wt<At;){if(U[wt]>=N){for(nt=wt+1;nt<At&&U[nt]>=N;)nt++;for(ct=wt,ft=nt-1;ct<ft;ct++,ft--)ot=E[ct],E[ct]=E[ft],E[ft]=ot,z&&(ot=z[ct],z[ct]=z[ft],z[ft]=ot);wt=nt}wt++}}},tt=function(N,E,z){var U=N.split(""),rt={hiLevel:G};return z||(z=[]),X(U,z,rt),(function(ot,ft,nt){if(nt.hiLevel!==0&&m)for(var ct,At=0;At<ot.length;At++)ft[At]===1&&(ct=M.indexOf(ot[At]))>=0&&(ot[At]=M[ct+1])})(U,z,rt),R(2,U,E,z,rt),R(1,U,E,z,rt),U.join("")};return this.__bidiEngine__.doBidiReorder=function(N,E,z){if((function(rt,ot){if(ot)for(var ft=0;ft<rt.length;ft++)ot[ft]=ft;l===void 0&&(l=it(rt)),d===void 0&&(d=it(rt))})(N,E),c||!h||d)if(c&&h&&l^d)G=l?1:0,N=dt(N,E,z);else if(!c&&h&&d)G=l?1:0,N=tt(N,E,z),N=dt(N,E);else if(!c||l||h||d){if(c&&!h&&l^d)N=dt(N,E),l?(G=0,N=tt(N,E,z)):(G=1,N=tt(N,E,z),N=dt(N,E));else if(c&&l&&!h&&d)G=1,N=tt(N,E,z),N=dt(N,E);else if(!c&&!h&&l^d){var U=m;l?(G=1,N=tt(N,E,z),G=0,m=!1,N=tt(N,E,z),m=U):(G=0,N=tt(N,E,z),N=dt(N,E),G=1,m=!1,N=tt(N,E,z),m=U,N=dt(N,E))}}else G=0,N=tt(N,E,z);else G=l?1:0,N=tt(N,E,z);return N},this.__bidiEngine__.setOptions=function(N){N&&(c=N.isInputVisual,h=N.isOutputVisual,l=N.isInputRtl,d=N.isOutputRtl,m=N.isSymmetricSwapping)},this.__bidiEngine__.setOptions(i),this.__bidiEngine__};var t=["BN","BN","BN","BN","BN","BN","BN","BN","BN","S","B","S","WS","B","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","B","B","B","S","WS","N","N","ET","ET","ET","N","N","N","N","N","ES","CS","ES","CS","CS","EN","EN","EN","EN","EN","EN","EN","EN","EN","EN","CS","N","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","N","BN","BN","BN","BN","BN","BN","B","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","BN","CS","N","ET","ET","ET","ET","N","N","N","N","L","N","N","BN","N","N","ET","ET","EN","EN","N","L","N","N","N","EN","L","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","L","L","L","L","L","L","L","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","L","N","N","N","N","N","ET","N","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","R","NSM","R","NSM","NSM","R","NSM","NSM","R","NSM","N","N","N","N","N","N","N","N","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","N","N","N","N","N","R","R","R","R","R","N","N","N","N","N","N","N","N","N","N","N","AN","AN","AN","AN","AN","AN","N","N","AL","ET","ET","AL","CS","AL","N","N","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","AL","AL","N","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","AN","AN","AN","AN","AN","AN","AN","AN","AN","AN","ET","AN","AN","AL","AL","AL","NSM","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","NSM","NSM","NSM","NSM","NSM","NSM","NSM","AN","N","NSM","NSM","NSM","NSM","NSM","NSM","AL","AL","NSM","NSM","N","NSM","NSM","NSM","NSM","AL","AL","EN","EN","EN","EN","EN","EN","EN","EN","EN","EN","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","N","AL","AL","NSM","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","N","N","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","AL","N","N","N","N","N","N","N","N","N","N","N","N","N","N","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","R","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","R","R","N","N","N","N","R","N","N","N","N","N","WS","WS","WS","WS","WS","WS","WS","WS","WS","WS","WS","BN","BN","BN","L","R","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","WS","B","LRE","RLE","PDF","LRO","RLO","CS","ET","ET","ET","ET","ET","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","CS","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","WS","BN","BN","BN","BN","BN","N","LRI","RLI","FSI","PDI","BN","BN","BN","BN","BN","BN","EN","L","N","N","EN","EN","EN","EN","EN","EN","ES","ES","N","N","N","L","EN","EN","EN","EN","EN","EN","EN","EN","EN","EN","ES","ES","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","ET","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","L","L","L","L","L","L","L","N","N","N","N","N","N","N","N","N","N","N","N","L","L","L","L","L","N","N","N","N","N","R","NSM","R","R","R","R","R","R","R","R","R","R","ES","R","R","R","R","R","R","R","R","R","R","R","R","R","N","R","R","R","R","R","N","R","N","R","R","N","R","R","N","R","R","R","R","R","R","R","R","R","R","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","NSM","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","CS","N","CS","N","N","CS","N","N","N","N","N","N","N","N","N","ET","N","N","ES","ES","N","N","N","N","N","ET","ET","N","N","N","N","N","AL","AL","AL","AL","AL","N","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","AL","N","N","BN","N","N","N","ET","ET","ET","N","N","N","N","N","ES","CS","ES","CS","CS","EN","EN","EN","EN","EN","EN","EN","EN","EN","EN","CS","N","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","N","N","N","N","N","N","N","N","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","L","N","N","N","L","L","L","L","L","L","N","N","L","L","L","L","L","L","N","N","L","L","L","L","L","L","N","N","L","L","L","N","N","N","ET","ET","N","N","N","ET","ET","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N","N"],e=new n.__bidiEngine__({isInputVisual:!0});n.API.events.push(["postProcessText",function(i){var o=i.text;i.x,i.y;var a=i.options||{};i.mutex,a.lang;var c=[];if(a.isInputVisual=typeof a.isInputVisual!="boolean"||a.isInputVisual,e.setOptions(a),Object.prototype.toString.call(o)==="[object Array]"){var l=0;for(c=[],l=0;l<o.length;l+=1)Object.prototype.toString.call(o[l])==="[object Array]"?c.push([e.doBidiReorder(o[l][0]),o[l][1],o[l][2]]):c.push([e.doBidiReorder(o[l])]);i.text=c}else i.text=e.doBidiReorder(o);e.setOptions({isInputVisual:!0})}])})(Mt),Mt.API.TTFFont=(function(){function n(t){var e;if(this.rawData=t,e=this.contents=new Qr(t),this.contents.pos=4,e.readString(4)==="ttcf")throw new Error("TTCF not supported.");e.pos=0,this.parse(),this.subset=new h2(this),this.registerTTF()}return n.open=function(t){return new n(t)},n.prototype.parse=function(){return this.directory=new $1(this.contents),this.head=new Q1(this),this.name=new i2(this),this.cmap=new Rf(this),this.toUnicode={},this.hhea=new t2(this),this.maxp=new a2(this),this.hmtx=new s2(this),this.post=new n2(this),this.os2=new e2(this),this.loca=new f2(this),this.glyf=new o2(this),this.ascender=this.os2.exists&&this.os2.ascender||this.hhea.ascender,this.decender=this.os2.exists&&this.os2.decender||this.hhea.decender,this.lineGap=this.os2.exists&&this.os2.lineGap||this.hhea.lineGap,this.bbox=[this.head.xMin,this.head.yMin,this.head.xMax,this.head.yMax]},n.prototype.registerTTF=function(){var t,e,i,o,a;if(this.scaleFactor=1e3/this.head.unitsPerEm,this.bbox=(function(){var c,l,h,d;for(d=[],c=0,l=(h=this.bbox).length;c<l;c++)t=h[c],d.push(Math.round(t*this.scaleFactor));return d}).call(this),this.stemV=0,this.post.exists?(i=255&(o=this.post.italic_angle),32768&(e=o>>16)&&(e=-(1+(65535^e))),this.italicAngle=+(e+"."+i)):this.italicAngle=0,this.ascender=Math.round(this.ascender*this.scaleFactor),this.decender=Math.round(this.decender*this.scaleFactor),this.lineGap=Math.round(this.lineGap*this.scaleFactor),this.capHeight=this.os2.exists&&this.os2.capHeight||this.ascender,this.xHeight=this.os2.exists&&this.os2.xHeight||0,this.familyClass=(this.os2.exists&&this.os2.familyClass||0)>>8,this.isSerif=(a=this.familyClass)===1||a===2||a===3||a===4||a===5||a===7,this.isScript=this.familyClass===10,this.flags=0,this.post.isFixedPitch&&(this.flags|=1),this.isSerif&&(this.flags|=2),this.isScript&&(this.flags|=8),this.italicAngle!==0&&(this.flags|=64),this.flags|=32,!this.cmap.unicode)throw new Error("No unicode cmap for font")},n.prototype.characterToGlyph=function(t){var e;return((e=this.cmap.unicode)!=null?e.codeMap[t]:void 0)||0},n.prototype.widthOfGlyph=function(t){var e;return e=1e3/this.head.unitsPerEm,this.hmtx.forGlyph(t).advance*e},n.prototype.widthOfString=function(t,e,i){var o,a,c,l;for(c=0,a=0,l=(t=""+t).length;0<=l?a<l:a>l;a=0<=l?++a:--a)o=t.charCodeAt(a),c+=this.widthOfGlyph(this.characterToGlyph(o))+i*(1e3/e)||0;return c*(e/1e3)},n.prototype.lineHeight=function(t,e){var i;return e==null&&(e=!1),i=e?this.lineGap:0,(this.ascender+i-this.decender)/1e3*t},n})();var er,Qr=(function(){function n(t){this.data=t??[],this.pos=0,this.length=this.data.length}return n.prototype.readByte=function(){return this.data[this.pos++]},n.prototype.writeByte=function(t){return this.data[this.pos++]=t},n.prototype.readUInt32=function(){return 16777216*this.readByte()+(this.readByte()<<16)+(this.readByte()<<8)+this.readByte()},n.prototype.writeUInt32=function(t){return this.writeByte(t>>>24&255),this.writeByte(t>>16&255),this.writeByte(t>>8&255),this.writeByte(255&t)},n.prototype.readInt32=function(){var t;return(t=this.readUInt32())>=2147483648?t-4294967296:t},n.prototype.writeInt32=function(t){return t<0&&(t+=4294967296),this.writeUInt32(t)},n.prototype.readUInt16=function(){return this.readByte()<<8|this.readByte()},n.prototype.writeUInt16=function(t){return this.writeByte(t>>8&255),this.writeByte(255&t)},n.prototype.readInt16=function(){var t;return(t=this.readUInt16())>=32768?t-65536:t},n.prototype.writeInt16=function(t){return t<0&&(t+=65536),this.writeUInt16(t)},n.prototype.readString=function(t){var e,i;for(i=[],e=0;0<=t?e<t:e>t;e=0<=t?++e:--e)i[e]=String.fromCharCode(this.readByte());return i.join("")},n.prototype.writeString=function(t){var e,i,o;for(o=[],e=0,i=t.length;0<=i?e<i:e>i;e=0<=i?++e:--e)o.push(this.writeByte(t.charCodeAt(e)));return o},n.prototype.readShort=function(){return this.readInt16()},n.prototype.writeShort=function(t){return this.writeInt16(t)},n.prototype.readLongLong=function(){var t,e,i,o,a,c,l,h;return t=this.readByte(),e=this.readByte(),i=this.readByte(),o=this.readByte(),a=this.readByte(),c=this.readByte(),l=this.readByte(),h=this.readByte(),128&t?-1*(72057594037927940*(255^t)+281474976710656*(255^e)+1099511627776*(255^i)+4294967296*(255^o)+16777216*(255^a)+65536*(255^c)+256*(255^l)+(255^h)+1):72057594037927940*t+281474976710656*e+1099511627776*i+4294967296*o+16777216*a+65536*c+256*l+h},n.prototype.writeLongLong=function(t){var e,i;return e=Math.floor(t/4294967296),i=4294967295&t,this.writeByte(e>>24&255),this.writeByte(e>>16&255),this.writeByte(e>>8&255),this.writeByte(255&e),this.writeByte(i>>24&255),this.writeByte(i>>16&255),this.writeByte(i>>8&255),this.writeByte(255&i)},n.prototype.readInt=function(){return this.readInt32()},n.prototype.writeInt=function(t){return this.writeInt32(t)},n.prototype.read=function(t){var e,i;for(e=[],i=0;0<=t?i<t:i>t;i=0<=t?++i:--i)e.push(this.readByte());return e},n.prototype.write=function(t){var e,i,o,a;for(a=[],i=0,o=t.length;i<o;i++)e=t[i],a.push(this.writeByte(e));return a},n})(),$1=(function(){var n;function t(e){var i,o,a;for(this.scalarType=e.readInt(),this.tableCount=e.readShort(),this.searchRange=e.readShort(),this.entrySelector=e.readShort(),this.rangeShift=e.readShort(),this.tables={},o=0,a=this.tableCount;0<=a?o<a:o>a;o=0<=a?++o:--o)i={tag:e.readString(4),checksum:e.readInt(),offset:e.readInt(),length:e.readInt()},this.tables[i.tag]=i}return t.prototype.encode=function(e){var i,o,a,c,l,h,d,m,_,k,p,j,O;for(O in p=Object.keys(e).length,h=Math.log(2),_=16*Math.floor(Math.log(p)/h),c=Math.floor(_/h),m=16*p-_,(o=new Qr).writeInt(this.scalarType),o.writeShort(p),o.writeShort(_),o.writeShort(c),o.writeShort(m),a=16*p,d=o.pos+a,l=null,j=[],e)for(k=e[O],o.writeString(O),o.writeInt(n(k)),o.writeInt(d),o.writeInt(k.length),j=j.concat(k),O==="head"&&(l=d),d+=k.length;d%4;)j.push(0),d++;return o.write(j),i=2981146554-n(o.data),o.pos=l+8,o.writeUInt32(i),o.data},n=function(e){var i,o,a,c;for(e=Tf.call(e);e.length%4;)e.push(0);for(a=new Qr(e),o=0,i=0,c=e.length;i<c;i=i+=4)o+=a.readUInt32();return 4294967295&o},t})(),Z1={}.hasOwnProperty,gr=function(n,t){for(var e in t)Z1.call(t,e)&&(n[e]=t[e]);function i(){this.constructor=n}return i.prototype=t.prototype,n.prototype=new i,n.__super__=t.prototype,n};er=(function(){function n(t){var e;this.file=t,e=this.file.directory.tables[this.tag],this.exists=!!e,e&&(this.offset=e.offset,this.length=e.length,this.parse(this.file.contents))}return n.prototype.parse=function(){},n.prototype.encode=function(){},n.prototype.raw=function(){return this.exists?(this.file.contents.pos=this.offset,this.file.contents.read(this.length)):null},n})();var Q1=(function(){function n(){return n.__super__.constructor.apply(this,arguments)}return gr(n,er),n.prototype.tag="head",n.prototype.parse=function(t){return t.pos=this.offset,this.version=t.readInt(),this.revision=t.readInt(),this.checkSumAdjustment=t.readInt(),this.magicNumber=t.readInt(),this.flags=t.readShort(),this.unitsPerEm=t.readShort(),this.created=t.readLongLong(),this.modified=t.readLongLong(),this.xMin=t.readShort(),this.yMin=t.readShort(),this.xMax=t.readShort(),this.yMax=t.readShort(),this.macStyle=t.readShort(),this.lowestRecPPEM=t.readShort(),this.fontDirectionHint=t.readShort(),this.indexToLocFormat=t.readShort(),this.glyphDataFormat=t.readShort()},n.prototype.encode=function(t){var e;return(e=new Qr).writeInt(this.version),e.writeInt(this.revision),e.writeInt(this.checkSumAdjustment),e.writeInt(this.magicNumber),e.writeShort(this.flags),e.writeShort(this.unitsPerEm),e.writeLongLong(this.created),e.writeLongLong(this.modified),e.writeShort(this.xMin),e.writeShort(this.yMin),e.writeShort(this.xMax),e.writeShort(this.yMax),e.writeShort(this.macStyle),e.writeShort(this.lowestRecPPEM),e.writeShort(this.fontDirectionHint),e.writeShort(t),e.writeShort(this.glyphDataFormat),e.data},n})(),Gu=(function(){function n(t,e){var i,o,a,c,l,h,d,m,_,k,p,j,O,M,S,V,G;switch(this.platformID=t.readUInt16(),this.encodingID=t.readShort(),this.offset=e+t.readInt(),_=t.pos,t.pos=this.offset,this.format=t.readUInt16(),this.length=t.readUInt16(),this.language=t.readUInt16(),this.isUnicode=this.platformID===3&&this.encodingID===1&&this.format===4||this.platformID===0&&this.format===4,this.codeMap={},this.format){case 0:for(h=0;h<256;++h)this.codeMap[h]=t.readByte();break;case 4:for(p=t.readUInt16(),k=p/2,t.pos+=6,a=(function(){var q,it;for(it=[],h=q=0;0<=k?q<k:q>k;h=0<=k?++q:--q)it.push(t.readUInt16());return it})(),t.pos+=2,O=(function(){var q,it;for(it=[],h=q=0;0<=k?q<k:q>k;h=0<=k?++q:--q)it.push(t.readUInt16());return it})(),d=(function(){var q,it;for(it=[],h=q=0;0<=k?q<k:q>k;h=0<=k?++q:--q)it.push(t.readUInt16());return it})(),m=(function(){var q,it;for(it=[],h=q=0;0<=k?q<k:q>k;h=0<=k?++q:--q)it.push(t.readUInt16());return it})(),o=(this.length-t.pos+this.offset)/2,l=(function(){var q,it;for(it=[],h=q=0;0<=o?q<o:q>o;h=0<=o?++q:--q)it.push(t.readUInt16());return it})(),h=S=0,G=a.length;S<G;h=++S)for(M=a[h],i=V=j=O[h];j<=M?V<=M:V>=M;i=j<=M?++V:--V)m[h]===0?c=i+d[h]:(c=l[m[h]/2+(i-j)-(k-h)]||0)!==0&&(c+=d[h]),this.codeMap[i]=65535&c}t.pos=_}return n.encode=function(t,e){var i,o,a,c,l,h,d,m,_,k,p,j,O,M,S,V,G,q,it,vt,dt,X,R,tt,N,E,z,U,rt,ot,ft,nt,ct,At,wt,x,B,T,H,J,Z,at,st,gt,_t,kt;switch(U=new Qr,c=Object.keys(t).sort(function(St,Dt){return St-Dt}),e){case"macroman":for(O=0,M=(function(){var St=[];for(j=0;j<256;++j)St.push(0);return St})(),V={0:0},a={},rt=0,ct=c.length;rt<ct;rt++)V[st=t[o=c[rt]]]==null&&(V[st]=++O),a[o]={old:t[o],new:V[t[o]]},M[o]=V[t[o]];return U.writeUInt16(1),U.writeUInt16(0),U.writeUInt32(12),U.writeUInt16(0),U.writeUInt16(262),U.writeUInt16(0),U.write(M),{charMap:a,subtable:U.data,maxGlyphID:O+1};case"unicode":for(E=[],_=[],G=0,V={},i={},S=d=null,ot=0,At=c.length;ot<At;ot++)V[it=t[o=c[ot]]]==null&&(V[it]=++G),i[o]={old:it,new:V[it]},l=V[it]-o,S!=null&&l===d||(S&&_.push(S),E.push(o),d=l),S=o;for(S&&_.push(S),_.push(65535),E.push(65535),tt=2*(R=E.length),X=2*Math.pow(Math.log(R)/Math.LN2,2),k=Math.log(X/2)/Math.LN2,dt=2*R-X,h=[],vt=[],p=[],j=ft=0,wt=E.length;ft<wt;j=++ft){if(N=E[j],m=_[j],N===65535){h.push(0),vt.push(0);break}if(N-(z=i[N].new)>=32768)for(h.push(0),vt.push(2*(p.length+R-j)),o=nt=N;N<=m?nt<=m:nt>=m;o=N<=m?++nt:--nt)p.push(i[o].new);else h.push(z-N),vt.push(0)}for(U.writeUInt16(3),U.writeUInt16(1),U.writeUInt32(12),U.writeUInt16(4),U.writeUInt16(16+8*R+2*p.length),U.writeUInt16(0),U.writeUInt16(tt),U.writeUInt16(X),U.writeUInt16(k),U.writeUInt16(dt),Z=0,x=_.length;Z<x;Z++)o=_[Z],U.writeUInt16(o);for(U.writeUInt16(0),at=0,B=E.length;at<B;at++)o=E[at],U.writeUInt16(o);for(gt=0,T=h.length;gt<T;gt++)l=h[gt],U.writeUInt16(l);for(_t=0,H=vt.length;_t<H;_t++)q=vt[_t],U.writeUInt16(q);for(kt=0,J=p.length;kt<J;kt++)O=p[kt],U.writeUInt16(O);return{charMap:i,subtable:U.data,maxGlyphID:G+1}}},n})(),Rf=(function(){function n(){return n.__super__.constructor.apply(this,arguments)}return gr(n,er),n.prototype.tag="cmap",n.prototype.parse=function(t){var e,i,o;for(t.pos=this.offset,this.version=t.readUInt16(),o=t.readUInt16(),this.tables=[],this.unicode=null,i=0;0<=o?i<o:i>o;i=0<=o?++i:--i)e=new Gu(t,this.offset),this.tables.push(e),e.isUnicode&&this.unicode==null&&(this.unicode=e);return!0},n.encode=function(t,e){var i,o;return e==null&&(e="macroman"),i=Gu.encode(t,e),(o=new Qr).writeUInt16(0),o.writeUInt16(1),i.table=o.data.concat(i.subtable),i},n})(),t2=(function(){function n(){return n.__super__.constructor.apply(this,arguments)}return gr(n,er),n.prototype.tag="hhea",n.prototype.parse=function(t){return t.pos=this.offset,this.version=t.readInt(),this.ascender=t.readShort(),this.decender=t.readShort(),this.lineGap=t.readShort(),this.advanceWidthMax=t.readShort(),this.minLeftSideBearing=t.readShort(),this.minRightSideBearing=t.readShort(),this.xMaxExtent=t.readShort(),this.caretSlopeRise=t.readShort(),this.caretSlopeRun=t.readShort(),this.caretOffset=t.readShort(),t.pos+=8,this.metricDataFormat=t.readShort(),this.numberOfMetrics=t.readUInt16()},n})(),e2=(function(){function n(){return n.__super__.constructor.apply(this,arguments)}return gr(n,er),n.prototype.tag="OS/2",n.prototype.parse=function(t){if(t.pos=this.offset,this.version=t.readUInt16(),this.averageCharWidth=t.readShort(),this.weightClass=t.readUInt16(),this.widthClass=t.readUInt16(),this.type=t.readShort(),this.ySubscriptXSize=t.readShort(),this.ySubscriptYSize=t.readShort(),this.ySubscriptXOffset=t.readShort(),this.ySubscriptYOffset=t.readShort(),this.ySuperscriptXSize=t.readShort(),this.ySuperscriptYSize=t.readShort(),this.ySuperscriptXOffset=t.readShort(),this.ySuperscriptYOffset=t.readShort(),this.yStrikeoutSize=t.readShort(),this.yStrikeoutPosition=t.readShort(),this.familyClass=t.readShort(),this.panose=(function(){var e,i;for(i=[],e=0;e<10;++e)i.push(t.readByte());return i})(),this.charRange=(function(){var e,i;for(i=[],e=0;e<4;++e)i.push(t.readInt());return i})(),this.vendorID=t.readString(4),this.selection=t.readShort(),this.firstCharIndex=t.readShort(),this.lastCharIndex=t.readShort(),this.version>0&&(this.ascent=t.readShort(),this.descent=t.readShort(),this.lineGap=t.readShort(),this.winAscent=t.readShort(),this.winDescent=t.readShort(),this.codePageRange=(function(){var e,i;for(i=[],e=0;e<2;e=++e)i.push(t.readInt());return i})(),this.version>1))return this.xHeight=t.readShort(),this.capHeight=t.readShort(),this.defaultChar=t.readShort(),this.breakChar=t.readShort(),this.maxContext=t.readShort()},n})(),n2=(function(){function n(){return n.__super__.constructor.apply(this,arguments)}return gr(n,er),n.prototype.tag="post",n.prototype.parse=function(t){var e,i,o;switch(t.pos=this.offset,this.format=t.readInt(),this.italicAngle=t.readInt(),this.underlinePosition=t.readShort(),this.underlineThickness=t.readShort(),this.isFixedPitch=t.readInt(),this.minMemType42=t.readInt(),this.maxMemType42=t.readInt(),this.minMemType1=t.readInt(),this.maxMemType1=t.readInt(),this.format){case 65536:case 196608:break;case 131072:var a;for(i=t.readUInt16(),this.glyphNameIndex=[],a=0;0<=i?a<i:a>i;a=0<=i?++a:--a)this.glyphNameIndex.push(t.readUInt16());for(this.names=[],o=[];t.pos<this.offset+this.length;)e=t.readByte(),o.push(this.names.push(t.readString(e)));return o;case 151552:return i=t.readUInt16(),this.offsets=t.read(i);case 262144:return this.map=(function(){var c,l,h;for(h=[],a=c=0,l=this.file.maxp.numGlyphs;0<=l?c<l:c>l;a=0<=l?++c:--c)h.push(t.readUInt32());return h}).call(this)}},n})(),r2=function(n,t){this.raw=n,this.length=n.length,this.platformID=t.platformID,this.encodingID=t.encodingID,this.languageID=t.languageID},i2=(function(){function n(){return n.__super__.constructor.apply(this,arguments)}return gr(n,er),n.prototype.tag="name",n.prototype.parse=function(t){var e,i,o,a,c,l,h,d,m,_,k;for(t.pos=this.offset,t.readShort(),e=t.readShort(),l=t.readShort(),i=[],a=0;0<=e?a<e:a>e;a=0<=e?++a:--a)i.push({platformID:t.readShort(),encodingID:t.readShort(),languageID:t.readShort(),nameID:t.readShort(),length:t.readShort(),offset:this.offset+l+t.readShort()});for(h={},a=m=0,_=i.length;m<_;a=++m)o=i[a],t.pos=o.offset,d=t.readString(o.length),c=new r2(d,o),h[k=o.nameID]==null&&(h[k]=[]),h[o.nameID].push(c);this.strings=h,this.copyright=h[0],this.fontFamily=h[1],this.fontSubfamily=h[2],this.uniqueSubfamily=h[3],this.fontName=h[4],this.version=h[5];try{this.postscriptName=h[6][0].raw.replace(/[\x00-\x19\x80-\xff]/g,"")}catch{this.postscriptName=h[4][0].raw.replace(/[\x00-\x19\x80-\xff]/g,"")}return this.trademark=h[7],this.manufacturer=h[8],this.designer=h[9],this.description=h[10],this.vendorUrl=h[11],this.designerUrl=h[12],this.license=h[13],this.licenseUrl=h[14],this.preferredFamily=h[15],this.preferredSubfamily=h[17],this.compatibleFull=h[18],this.sampleText=h[19]},n})(),a2=(function(){function n(){return n.__super__.constructor.apply(this,arguments)}return gr(n,er),n.prototype.tag="maxp",n.prototype.parse=function(t){return t.pos=this.offset,this.version=t.readInt(),this.numGlyphs=t.readUInt16(),this.maxPoints=t.readUInt16(),this.maxContours=t.readUInt16(),this.maxCompositePoints=t.readUInt16(),this.maxComponentContours=t.readUInt16(),this.maxZones=t.readUInt16(),this.maxTwilightPoints=t.readUInt16(),this.maxStorage=t.readUInt16(),this.maxFunctionDefs=t.readUInt16(),this.maxInstructionDefs=t.readUInt16(),this.maxStackElements=t.readUInt16(),this.maxSizeOfInstructions=t.readUInt16(),this.maxComponentElements=t.readUInt16(),this.maxComponentDepth=t.readUInt16()},n})(),s2=(function(){function n(){return n.__super__.constructor.apply(this,arguments)}return gr(n,er),n.prototype.tag="hmtx",n.prototype.parse=function(t){var e,i,o,a,c,l,h;for(t.pos=this.offset,this.metrics=[],e=0,l=this.file.hhea.numberOfMetrics;0<=l?e<l:e>l;e=0<=l?++e:--e)this.metrics.push({advance:t.readUInt16(),lsb:t.readInt16()});for(o=this.file.maxp.numGlyphs-this.file.hhea.numberOfMetrics,this.leftSideBearings=(function(){var d,m;for(m=[],e=d=0;0<=o?d<o:d>o;e=0<=o?++d:--d)m.push(t.readInt16());return m})(),this.widths=(function(){var d,m,_,k;for(k=[],d=0,m=(_=this.metrics).length;d<m;d++)a=_[d],k.push(a.advance);return k}).call(this),i=this.widths[this.widths.length-1],h=[],e=c=0;0<=o?c<o:c>o;e=0<=o?++c:--c)h.push(this.widths.push(i));return h},n.prototype.forGlyph=function(t){return t in this.metrics?this.metrics[t]:{advance:this.metrics[this.metrics.length-1].advance,lsb:this.leftSideBearings[t-this.metrics.length]}},n})(),Tf=[].slice,o2=(function(){function n(){return n.__super__.constructor.apply(this,arguments)}return gr(n,er),n.prototype.tag="glyf",n.prototype.parse=function(){return this.cache={}},n.prototype.glyphFor=function(t){var e,i,o,a,c,l,h,d,m,_;return t in this.cache?this.cache[t]:(a=this.file.loca,e=this.file.contents,i=a.indexOf(t),(o=a.lengthOf(t))===0?this.cache[t]=null:(e.pos=this.offset+i,c=(l=new Qr(e.read(o))).readShort(),d=l.readShort(),_=l.readShort(),h=l.readShort(),m=l.readShort(),this.cache[t]=c===-1?new u2(l,d,_,h,m):new l2(l,c,d,_,h,m),this.cache[t]))},n.prototype.encode=function(t,e,i){var o,a,c,l,h;for(c=[],a=[],l=0,h=e.length;l<h;l++)o=t[e[l]],a.push(c.length),o&&(c=c.concat(o.encode(i)));return a.push(c.length),{table:c,offsets:a}},n})(),l2=(function(){function n(t,e,i,o,a,c){this.raw=t,this.numberOfContours=e,this.xMin=i,this.yMin=o,this.xMax=a,this.yMax=c,this.compound=!1}return n.prototype.encode=function(){return this.raw.data},n})(),u2=(function(){function n(t,e,i,o,a){var c,l;for(this.raw=t,this.xMin=e,this.yMin=i,this.xMax=o,this.yMax=a,this.compound=!0,this.glyphIDs=[],this.glyphOffsets=[],c=this.raw;l=c.readShort(),this.glyphOffsets.push(c.pos),this.glyphIDs.push(c.readUInt16()),32&l;)c.pos+=1&l?4:2,128&l?c.pos+=8:64&l?c.pos+=4:8&l&&(c.pos+=2)}return n.prototype.encode=function(){var t,e,i;for(e=new Qr(Tf.call(this.raw.data)),t=0,i=this.glyphIDs.length;t<i;++t)e.pos=this.glyphOffsets[t];return e.data},n})(),f2=(function(){function n(){return n.__super__.constructor.apply(this,arguments)}return gr(n,er),n.prototype.tag="loca",n.prototype.parse=function(t){var e,i;return t.pos=this.offset,e=this.file.head.indexToLocFormat,this.offsets=e===0?(function(){var o,a;for(a=[],i=0,o=this.length;i<o;i+=2)a.push(2*t.readUInt16());return a}).call(this):(function(){var o,a;for(a=[],i=0,o=this.length;i<o;i+=4)a.push(t.readUInt32());return a}).call(this)},n.prototype.indexOf=function(t){return this.offsets[t]},n.prototype.lengthOf=function(t){return this.offsets[t+1]-this.offsets[t]},n.prototype.encode=function(t,e){for(var i=new Uint32Array(this.offsets.length),o=0,a=0,c=0;c<i.length;++c)if(i[c]=o,a<e.length&&e[a]==c){++a,i[c]=o;var l=this.offsets[c],h=this.offsets[c+1]-l;h>0&&(o+=h)}for(var d=new Array(4*i.length),m=0;m<i.length;++m)d[4*m+3]=255&i[m],d[4*m+2]=(65280&i[m])>>8,d[4*m+1]=(16711680&i[m])>>16,d[4*m]=(4278190080&i[m])>>24;return d},n})(),h2=(function(){function n(t){this.font=t,this.subset={},this.unicodes={},this.next=33}return n.prototype.generateCmap=function(){var t,e,i,o,a;for(e in o=this.font.cmap.tables[0].codeMap,t={},a=this.subset)i=a[e],t[e]=o[i];return t},n.prototype.glyphsFor=function(t){var e,i,o,a,c,l,h;for(o={},c=0,l=t.length;c<l;c++)o[a=t[c]]=this.font.glyf.glyphFor(a);for(a in e=[],o)(i=o[a])!=null&&i.compound&&e.push.apply(e,i.glyphIDs);if(e.length>0)for(a in h=this.glyphsFor(e))i=h[a],o[a]=i;return o},n.prototype.encode=function(t,e){var i,o,a,c,l,h,d,m,_,k,p,j,O,M,S;for(o in i=Rf.encode(this.generateCmap(),"unicode"),c=this.glyphsFor(t),p={0:0},S=i.charMap)p[(h=S[o]).old]=h.new;for(j in k=i.maxGlyphID,c)j in p||(p[j]=k++);return m=(function(V){var G,q;for(G in q={},V)q[V[G]]=G;return q})(p),_=Object.keys(m).sort(function(V,G){return V-G}),O=(function(){var V,G,q;for(q=[],V=0,G=_.length;V<G;V++)l=_[V],q.push(m[l]);return q})(),a=this.font.glyf.encode(c,O,p),d=this.font.loca.encode(a.offsets,O),M={cmap:this.font.cmap.raw(),glyf:a.table,loca:d,hmtx:this.font.hmtx.raw(),hhea:this.font.hhea.raw(),maxp:this.font.maxp.raw(),post:this.font.post.raw(),name:this.font.name.raw(),head:this.font.head.encode(e)},this.font.os2.exists&&(M["OS/2"]=this.font.os2.raw()),this.font.directory.encode(M)},n})();Mt.API.PDFObject=(function(){var n;function t(){}return n=function(e,i){return(Array(i+1).join("0")+e).slice(-i)},t.convert=function(e){var i,o,a,c;if(Array.isArray(e))return"["+(function(){var l,h,d;for(d=[],l=0,h=e.length;l<h;l++)i=e[l],d.push(t.convert(i));return d})().join(" ")+"]";if(typeof e=="string")return"/"+e;if(e?.isString)return"("+e+")";if(e instanceof Date)return"(D:"+n(e.getUTCFullYear(),4)+n(e.getUTCMonth(),2)+n(e.getUTCDate(),2)+n(e.getUTCHours(),2)+n(e.getUTCMinutes(),2)+n(e.getUTCSeconds(),2)+"Z)";if({}.toString.call(e)==="[object Object]"){for(o in a=["<<"],e)c=e[o],a.push("/"+o+" "+t.convert(c));return a.push(">>"),a.join(`
79
+ `)}return""+e},t})();const d2=Object.freeze(Object.defineProperty({__proto__:null,AcroFormAppearance:It,AcroFormButton:nn,AcroFormCheckBox:Oa,AcroFormChoiceField:xi,AcroFormComboBox:Ai,AcroFormEditBox:Fa,AcroFormListBox:_i,AcroFormPasswordField:ja,AcroFormPushButton:Ea,AcroFormRadioButton:Ni,AcroFormTextField:Zr,GState:Ra,ShadingPattern:Xr,TilingPattern:yi,default:Mt,jsPDF:Mt},Symbol.toStringTag,{value:"Module"}));export{xe as _,d2 as j};