(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5443],{61120:function(a){!function(b,c){a.exports=c()}(this,function(){"use strict";/*! *****************************************************************************
    Copyright (c) Microsoft Corporation.

    Permission to use, copy, modify, and/or distribute this software for any
    purpose with or without fee is hereby granted.

    THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
    REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
    AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
    INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
    LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
    OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
    PERFORMANCE OF THIS SOFTWARE.
    ***************************************************************************** */ var a,b,c,d,e,f=function(a,b){return(f=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(a,b){a.__proto__=b}||function(a,b){for(var c in b)Object.prototype.hasOwnProperty.call(b,c)&&(a[c]=b[c])})(a,b)};function g(a,b){if("function"!=typeof b&&null!==b)throw TypeError("Class extends value "+String(b)+" is not a constructor or null");function c(){this.constructor=a}f(a,b),a.prototype=null===b?Object.create(b):(c.prototype=b.prototype,new c)}var h=function(){return(h=Object.assign||function(a){for(var b,c=1,d=arguments.length;c<d;c++)for(var e in b=arguments[c])Object.prototype.hasOwnProperty.call(b,e)&&(a[e]=b[e]);return a}).apply(this,arguments)};function i(a,b,c,d){return new(c||(c=Promise))(function(e,f){function g(a){try{i(d.next(a))}catch(b){f(b)}}function h(a){try{i(d.throw(a))}catch(b){f(b)}}function i(a){var b;a.done?e(a.value):((b=a.value)instanceof c?b:new c(function(a){a(b)})).then(g,h)}i((d=d.apply(a,b||[])).next())})}function j(a,b){var c,d,e,f,g={label:0,sent:function(){if(1&e[0])throw e[1];return e[1]},trys:[],ops:[]};return f={next:h(0),throw:h(1),return:h(2)},"function"==typeof Symbol&&(f[Symbol.iterator]=function(){return this}),f;function h(a){return function(b){return i([a,b])}}function i(f){if(c)throw TypeError("Generator is already executing.");for(;g;)try{if(c=1,d&&(e=2&f[0]?d.return:f[0]?d.throw||((e=d.return)&&e.call(d),0):d.next)&&!(e=e.call(d,f[1])).done)return e;switch(d=0,e&&(f=[2&f[0],e.value]),f[0]){case 0:case 1:e=f;break;case 4:return g.label++,{value:f[1],done:!1};case 5:g.label++,d=f[1],f=[0];continue;case 7:f=g.ops.pop(),g.trys.pop();continue;default:if(!(e=(e=g.trys).length>0&&e[e.length-1])&&(6===f[0]||2===f[0])){g=0;continue}if(3===f[0]&&(!e||f[1]>e[0]&&f[1]<e[3])){g.label=f[1];break}if(6===f[0]&&g.label<e[1]){g.label=e[1],e=f;break}if(e&&g.label<e[2]){g.label=e[2],g.ops.push(f);break}e[2]&&g.ops.pop(),g.trys.pop();continue}f=b.call(a,g)}catch(h){f=[6,h],d=0}finally{c=e=0}if(5&f[0])throw f[1];return{value:f[0]?f[1]:void 0,done:!0}}}function k(a,b,c){if(c||2===arguments.length)for(var d,e=0,f=b.length;e<f;e++)!d&&e in b||(d||(d=Array.prototype.slice.call(b,0,e)),d[e]=b[e]);return a.concat(d||b)}for(var l=function(){function a(a,b,c,d){this.left=a,this.top=b,this.width=c,this.height=d}return a.prototype.add=function(b,c,d,e){return new a(this.left+b,this.top+c,this.width+d,this.height+e)},a.fromClientRect=function(b,c){return new a(c.left+b.windowBounds.left,c.top+b.windowBounds.top,c.width,c.height)},a.fromDOMRectList=function(b,c){var d=Array.from(c).find(function(a){return 0!==a.width});return d?new a(d.left+b.windowBounds.left,d.top+b.windowBounds.top,d.width,d.height):a.EMPTY},a.EMPTY=new a(0,0,0,0),a}(),m=function(a,b){return l.fromClientRect(a,b.getBoundingClientRect())},n=function(a){var b=a.body,c=a.documentElement;if(!b||!c)throw Error("Unable to get document size");var d=Math.max(Math.max(b.scrollWidth,c.scrollWidth),Math.max(b.offsetWidth,c.offsetWidth),Math.max(b.clientWidth,c.clientWidth)),e=Math.max(Math.max(b.scrollHeight,c.scrollHeight),Math.max(b.offsetHeight,c.offsetHeight),Math.max(b.clientHeight,c.clientHeight));return new l(0,0,d,e)},o=function(a){for(var b=[],c=0,d=a.length;c<d;){var e=a.charCodeAt(c++);if(e>=55296&&e<=56319&&c<d){var f=a.charCodeAt(c++);(64512&f)==56320?b.push(((1023&e)<<10)+(1023&f)+65536):(b.push(e),c--)}else b.push(e)}return b},p=function(){for(var a=[],b=0;b<arguments.length;b++)a[b]=arguments[b];if(String.fromCodePoint)return String.fromCodePoint.apply(String,a);var c=a.length;if(!c)return"";for(var d=[],e=-1,f="";++e<c;){var g=a[e];g<=65535?d.push(g):(g-=65536,d.push((g>>10)+55296,g%1024+56320)),(e+1===c||d.length>16384)&&(f+=String.fromCharCode.apply(String,d),d.length=0)}return f},q="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r="undefined"==typeof Uint8Array?[]:new Uint8Array(256),s=0;s<q.length;s++)r[q.charCodeAt(s)]=s;for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",u="undefined"==typeof Uint8Array?[]:new Uint8Array(256),v=0;v<t.length;v++)u[t.charCodeAt(v)]=v;for(var w=function(a){var b,c,d,e,f,g=.75*a.length,h=a.length,i=0;"="===a[a.length-1]&&(g--,"="===a[a.length-2]&&g--);var j="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array&& void 0!==Uint8Array.prototype.slice?new ArrayBuffer(g):Array(g),k=Array.isArray(j)?j:new Uint8Array(j);for(b=0;b<h;b+=4)c=u[a.charCodeAt(b)],d=u[a.charCodeAt(b+1)],e=u[a.charCodeAt(b+2)],f=u[a.charCodeAt(b+3)],k[i++]=c<<2|d>>4,k[i++]=(15&d)<<4|e>>2,k[i++]=(3&e)<<6|63&f;return j},x=function(a){for(var b=a.length,c=[],d=0;d<b;d+=2)c.push(a[d+1]<<8|a[d]);return c},y=function(a){for(var b=a.length,c=[],d=0;d<b;d+=4)c.push(a[d+3]<<24|a[d+2]<<16|a[d+1]<<8|a[d]);return c},z=5,A=11,B=2,C=A-z,D=65536>>z,E=1<<z,F=E-1,G=1024>>z,H=D+G,I=H,J=32,K=I+J,L=65536>>A,M=1<<C,N=M-1,O=function(a,b,c){return a.slice?a.slice(b,c):new Uint16Array(Array.prototype.slice.call(a,b,c))},P=function(a,b,c){return a.slice?a.slice(b,c):new Uint32Array(Array.prototype.slice.call(a,b,c))},Q=function(a,b){var c=w(a),d=Array.isArray(c)?y(c):new Uint32Array(c),e=Array.isArray(c)?x(c):new Uint16Array(c),f=24,g=O(e,f/2,d[4]/2),h=2===d[5]?O(e,(f+d[4])/2):P(d,Math.ceil((f+d[4])/4));return new R(d[0],d[1],d[2],d[3],g,h)},R=function(){function a(a,b,c,d,e,f){this.initialValue=a,this.errorValue=b,this.highStart=c,this.highValueIndex=d,this.index=e,this.data=f}return a.prototype.get=function(a){var b;if(a>=0){if(a<55296||a>56319&&a<=65535)return b=((b=this.index[a>>z])<<B)+(a&F),this.data[b];if(a<=65535)return b=((b=this.index[D+(a-55296>>z)])<<B)+(a&F),this.data[b];if(a<this.highStart)return b=K-L+(a>>A),b=this.index[b],b+=a>>z&N,b=((b=this.index[b])<<B)+(a&F),this.data[b];if(a<=1114111)return this.data[this.highValueIndex]}return this.errorValue},a}(),S="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",T="undefined"==typeof Uint8Array?[]:new Uint8Array(256),U=0;U<S.length;U++)T[S.charCodeAt(U)]=U;var V=50,W=1,X=2,Y=3,Z=4,$=5,_=7,aa=8,ab=9,ac=10,ad=11,ae=12,af=13,ag=14,ah=15,ai=16,aj=17,ak=18,al=19,am=20,an=21,ao=22,ap=23,aq=24,ar=25,as=26,at=27,au=28,av=29,aw=30,ax=31,ay=32,az=33,aA=34,aB=35,aC=36,aD=37,aE=38,aF=39,aG=40,aH=41,aI=42,aJ=43,aK=[9001,65288],aL="!",aM="\xd7",aN="\xf7",aO=Q(" "),aP=[aw,aC],aQ=[W,X,Y,$],aR=[ac,aa],aS=[at,as],aT=aQ.concat(aR),aU=[aE,aF,aG,aA,aB],aV=[ah,af],aW=function(a,b){void 0===b&&(b="strict");var c=[],d=[],e=[];return a.forEach(function(a,f){var g=aO.get(a);if(g>V?(e.push(!0),g-=V):e.push(!1),-1!==["normal","auto","loose"].indexOf(b)&& -1!==[8208,8211,12316,12448].indexOf(a))return d.push(f),c.push(ai);if(g===Z||g===ad){if(0===f)return d.push(f),c.push(aw);var h=c[f-1];return -1===aT.indexOf(h)?(d.push(d[f-1]),c.push(h)):(d.push(f),c.push(aw))}return(d.push(f),g===ax)?c.push("strict"===b?an:aD):g===aI||g===av?c.push(aw):g===aJ?a>=131072&&a<=196605||a>=196608&&a<=262141?c.push(aD):c.push(aw):void c.push(g)}),[d,c,e]},aX=function(a,b,c,d){var e=d[c];if(Array.isArray(a)?-1!==a.indexOf(e):a===e)for(var f=c;f<=d.length;){var g=d[++f];if(g===b)return!0;if(g!==ac)break}if(e===ac)for(var f=c;f>0;){var h=d[--f];if(Array.isArray(a)?-1!==a.indexOf(h):a===h)for(var i=c;i<=d.length;){var g=d[++i];if(g===b)return!0;if(g!==ac)break}if(h!==ac)break}return!1},aY=function(a,b){for(var c=a;c>=0;){var d=b[c];if(d!==ac)return d;c--}return 0},aZ=function(a,b,c,d,e){if(0===c[d])return aM;var f=d-1;if(Array.isArray(e)&& !0===e[f])return aM;var g=f-1,h=f+1,i=b[f],j=g>=0?b[g]:0,k=b[h];if(i===X&&k===Y)return aM;if(-1!==aQ.indexOf(i))return aL;if(-1!==aQ.indexOf(k)|| -1!==aR.indexOf(k))return aM;if(aY(f,b)===aa)return aN;if(aO.get(a[f])===ad||(i===ay||i===az)&&aO.get(a[h])===ad||i===_||k===_||i===ab|| -1===[ac,af,ah].indexOf(i)&&k===ab|| -1!==[aj,ak,al,aq,au].indexOf(k)||aY(f,b)===ao||aX(ap,ao,f,b)||aX([aj,ak],an,f,b)||aX(ae,ae,f,b))return aM;if(i===ac)return aN;if(i===ap||k===ap)return aM;if(k===ai||i===ai)return aN;if(-1!==[af,ah,an].indexOf(k)||i===ag||j===aC&& -1!==aV.indexOf(i)||i===au&&k===aC||k===am|| -1!==aP.indexOf(k)&&i===ar|| -1!==aP.indexOf(i)&&k===ar||i===at&& -1!==[aD,ay,az].indexOf(k)|| -1!==[aD,ay,az].indexOf(i)&&k===as|| -1!==aP.indexOf(i)&& -1!==aS.indexOf(k)|| -1!==aS.indexOf(i)&& -1!==aP.indexOf(k)|| -1!==[at,as].indexOf(i)&&(k===ar|| -1!==[ao,ah].indexOf(k)&&b[h+1]===ar)|| -1!==[ao,ah].indexOf(i)&&k===ar||i===ar&& -1!==[ar,au,aq].indexOf(k))return aM;if(-1!==[ar,au,aq,aj,ak].indexOf(k))for(var l=f;l>=0;){var m=b[l];if(m===ar)return aM;if(-1!==[au,aq].indexOf(m))l--;else break}if(-1!==[at,as].indexOf(k))for(var l=-1!==[aj,ak].indexOf(i)?g:f;l>=0;){var m=b[l];if(m===ar)return aM;if(-1!==[au,aq].indexOf(m))l--;else break}if(aE===i&& -1!==[aE,aF,aA,aB].indexOf(k)|| -1!==[aF,aA].indexOf(i)&& -1!==[aF,aG].indexOf(k)|| -1!==[aG,aB].indexOf(i)&&k===aG|| -1!==aU.indexOf(i)&& -1!==[am,as].indexOf(k)|| -1!==aU.indexOf(k)&&i===at|| -1!==aP.indexOf(i)&& -1!==aP.indexOf(k)||i===aq&& -1!==aP.indexOf(k)|| -1!==aP.concat(ar).indexOf(i)&&k===ao&& -1===aK.indexOf(a[h])|| -1!==aP.concat(ar).indexOf(k)&&i===ak)return aM;if(i===aH&&k===aH){for(var n=c[f],o=1;n>0;)if(b[--n]===aH)o++;else break;if(o%2!=0)return aM}return i===ay&&k===az?aM:aN},a$=function(a,b){b||(b={lineBreak:"normal",wordBreak:"normal"});var c=aW(a,b.lineBreak),d=c[0],e=c[1],f=c[2];("break-all"===b.wordBreak||"break-word"===b.wordBreak)&&(e=e.map(function(a){return -1!==[ar,aw,aI].indexOf(a)?aD:a}));var g="keep-all"===b.wordBreak?f.map(function(b,c){return b&&a[c]>=19968&&a[c]<=40959}):void 0;return[d,e,g]},a_=function(){function a(a,b,c,d){this.codePoints=a,this.required=b===aL,this.start=c,this.end=d}return a.prototype.slice=function(){return p.apply(void 0,this.codePoints.slice(this.start,this.end))},a}(),a0=function(a,b){var c=o(a),d=a$(c,b),e=d[0],f=d[1],g=d[2],h=c.length,i=0,j=0;return{next:function(){if(j>=h)return{done:!0,value:null};for(var a=aM;j<h&&(a=aZ(c,f,e,++j,g))===aM;);if(a!==aM||j===h){var b=new a_(c,a,i,j);return i=j,{value:b,done:!1}}return{done:!0,value:null}}}},a1=1,a2=2,a3=4,a4=8,a5=10,a6=47,a7=92,a8=9,a9=32,ba=34,bb=61,bc=35,bd=36,be=37,bf=39,bg=40,bh=41,bi=95,bj=45,bk=33,bl=60,bm=62,bn=64,bo=91,bp=93,bq=61,br=123,bs=63,bt=125,bu=124,bv=126,bw=128,bx=65533,by=42,bz=43,bA=44,bB=58,bC=59,bD=46,bE=0,bF=8,bG=11,bH=14,bI=31,bJ=127,bK=-1,bL=48,bM=97,bN=101,bO=102,bP=117,bQ=122,bR=65,bS=69,bT=70,bU=85,bV=90,bW=function(a){return a>=bL&&a<=57},bX=function(a){return a>=55296&&a<=57343},bY=function(a){return bW(a)||a>=bR&&a<=bT||a>=bM&&a<=bO},bZ=function(a){return a>=bM&&a<=bQ},b$=function(a){return a>=bR&&a<=bV},b_=function(a){return bZ(a)||b$(a)},b0=function(a){return a>=bw},b1=function(a){return a===a5||a===a8||a===a9},b2=function(a){return b_(a)||b0(a)||a===bi},b3=function(a){return b2(a)||bW(a)||a===bj},b4=function(a){return a>=bE&&a<=bF||a===bG||a>=bH&&a<=bI||a===bJ},b5=function(a,b){return a===a7&&b!==a5},b6=function(a,b,c){return a===bj?b2(b)||b5(b,c):!!(b2(a)||a===a7&&b5(a,b))},b7=function(a,b,c){return a===bz||a===bj?!!bW(b)||b===bD&&bW(c):a===bD?bW(b):bW(a)},b8=function(a){var b=0,c=1;(a[b]===bz||a[b]===bj)&&(a[b]===bj&&(c=-1),b++);for(var d=[];bW(a[b]);)d.push(a[b++]);var e=d.length?parseInt(p.apply(void 0,d),10):0;a[b]===bD&&b++;for(var f=[];bW(a[b]);)f.push(a[b++]);var g=f.length,h=g?parseInt(p.apply(void 0,f),10):0;(a[b]===bS||a[b]===bN)&&b++;var i=1;(a[b]===bz||a[b]===bj)&&(a[b]===bj&&(i=-1),b++);for(var j=[];bW(a[b]);)j.push(a[b++]);var k=j.length?parseInt(p.apply(void 0,j),10):0;return c*(e+h*Math.pow(10,-g))*Math.pow(10,i*k)},b9={type:2},ca={type:3},cb={type:4},cc={type:13},cd={type:8},ce={type:21},cf={type:9},cg={type:10},ch={type:11},ci={type:12},cj={type:14},ck={type:23},cl={type:1},cm={type:25},cn={type:24},co={type:26},cp={type:27},cq={type:28},cr={type:29},cs={type:31},ct={type:32},cu=function(){function a(){this._value=[]}return a.prototype.write=function(a){this._value=this._value.concat(o(a))},a.prototype.read=function(){for(var a=[],b=this.consumeToken();b!==ct;)a.push(b),b=this.consumeToken();return a},a.prototype.consumeToken=function(){var a=this.consumeCodePoint();switch(a){case ba:return this.consumeStringToken(ba);case bc:var b=this.peekCodePoint(0),c=this.peekCodePoint(1),d=this.peekCodePoint(2);if(b3(b)||b5(c,d)){var e=b6(b,c,d)?a2:a1,f=this.consumeName();return{type:5,value:f,flags:e}}break;case bd:if(this.peekCodePoint(0)===bb)return this.consumeCodePoint(),cc;break;case bf:return this.consumeStringToken(bf);case bg:return b9;case bh:return ca;case by:if(this.peekCodePoint(0)===bb)return this.consumeCodePoint(),cj;break;case bz:if(b7(a,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(a),this.consumeNumericToken();break;case bA:return cb;case bj:var g=a,h=this.peekCodePoint(0),i=this.peekCodePoint(1);if(b7(g,h,i))return this.reconsumeCodePoint(a),this.consumeNumericToken();if(b6(g,h,i))return this.reconsumeCodePoint(a),this.consumeIdentLikeToken();if(h===bj&&i===bm)return this.consumeCodePoint(),this.consumeCodePoint(),cn;break;case bD:if(b7(a,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(a),this.consumeNumericToken();break;case a6:if(this.peekCodePoint(0)===by)for(this.consumeCodePoint();;){var j=this.consumeCodePoint();if(j===by&&(j=this.consumeCodePoint())===a6||j===bK)return this.consumeToken()}break;case bB:return co;case bC:return cp;case bl:if(this.peekCodePoint(0)===bk&&this.peekCodePoint(1)===bj&&this.peekCodePoint(2)===bj)return this.consumeCodePoint(),this.consumeCodePoint(),cm;break;case bn:var k,l=this.peekCodePoint(0);if(b6(l,this.peekCodePoint(1),this.peekCodePoint(2))){var f=this.consumeName();return{type:7,value:f}}break;case bo:return cq;case a7:if(b5(a,this.peekCodePoint(0)))return this.reconsumeCodePoint(a),this.consumeIdentLikeToken();break;case bp:return cr;case bq:if(this.peekCodePoint(0)===bb)return this.consumeCodePoint(),cd;break;case br:return ch;case bt:return ci;case bP:case bU:var m=this.peekCodePoint(0),n=this.peekCodePoint(1);return m===bz&&(bY(n)||n===bs)&&(this.consumeCodePoint(),this.consumeUnicodeRangeToken()),this.reconsumeCodePoint(a),this.consumeIdentLikeToken();case bu:if(this.peekCodePoint(0)===bb)return this.consumeCodePoint(),cf;if(this.peekCodePoint(0)===bu)return this.consumeCodePoint(),ce;break;case bv:if(this.peekCodePoint(0)===bb)return this.consumeCodePoint(),cg;break;case bK:return ct}return b1(a)?(this.consumeWhiteSpace(),cs):bW(a)?(this.reconsumeCodePoint(a),this.consumeNumericToken()):b2(a)?(this.reconsumeCodePoint(a),this.consumeIdentLikeToken()):{type:6,value:p(a)}},a.prototype.consumeCodePoint=function(){var a=this._value.shift();return void 0===a?-1:a},a.prototype.reconsumeCodePoint=function(a){this._value.unshift(a)},a.prototype.peekCodePoint=function(a){return a>=this._value.length?-1:this._value[a]},a.prototype.consumeUnicodeRangeToken=function(){for(var a=[],b=this.consumeCodePoint();bY(b)&&a.length<6;)a.push(b),b=this.consumeCodePoint();for(var c=!1;b===bs&&a.length<6;)a.push(b),b=this.consumeCodePoint(),c=!0;if(c){var d=parseInt(p.apply(void 0,a.map(function(a){return a===bs?bL:a})),16),e=parseInt(p.apply(void 0,a.map(function(a){return a===bs?bT:a})),16);return{type:30,start:d,end:e}}var f=parseInt(p.apply(void 0,a),16);if(!(this.peekCodePoint(0)===bj&&bY(this.peekCodePoint(1))))return{type:30,start:f,end:f};this.consumeCodePoint(),b=this.consumeCodePoint();for(var g=[];bY(b)&&g.length<6;)g.push(b),b=this.consumeCodePoint();var e=parseInt(p.apply(void 0,g),16);return{type:30,start:f,end:e}},a.prototype.consumeIdentLikeToken=function(){var a=this.consumeName();return"url"===a.toLowerCase()&&this.peekCodePoint(0)===bg?(this.consumeCodePoint(),this.consumeUrlToken()):this.peekCodePoint(0)===bg?(this.consumeCodePoint(),{type:19,value:a}):{type:20,value:a}},a.prototype.consumeUrlToken=function(){var a=[];if(this.consumeWhiteSpace(),this.peekCodePoint(0)===bK)return{type:22,value:""};var b=this.peekCodePoint(0);if(b===bf||b===ba){var c=this.consumeStringToken(this.consumeCodePoint());return 0===c.type&&(this.consumeWhiteSpace(),this.peekCodePoint(0)===bK||this.peekCodePoint(0)===bh)?(this.consumeCodePoint(),{type:22,value:c.value}):(this.consumeBadUrlRemnants(),ck)}for(;;){var d=this.consumeCodePoint();if(d===bK||d===bh)return{type:22,value:p.apply(void 0,a)};if(b1(d)){if(this.consumeWhiteSpace(),this.peekCodePoint(0)===bK||this.peekCodePoint(0)===bh)return this.consumeCodePoint(),{type:22,value:p.apply(void 0,a)};return this.consumeBadUrlRemnants(),ck}if(d===ba||d===bf||d===bg||b4(d))return this.consumeBadUrlRemnants(),ck;else if(d===a7){if(!b5(d,this.peekCodePoint(0)))return this.consumeBadUrlRemnants(),ck;a.push(this.consumeEscapedCodePoint())}else a.push(d)}},a.prototype.consumeWhiteSpace=function(){for(;b1(this.peekCodePoint(0));)this.consumeCodePoint()},a.prototype.consumeBadUrlRemnants=function(){for(;;){var a=this.consumeCodePoint();if(a===bh||a===bK)return;b5(a,this.peekCodePoint(0))&&this.consumeEscapedCodePoint()}},a.prototype.consumeStringSlice=function(a){for(var b=5e4,c="";a>0;){var d=Math.min(b,a);c+=p.apply(void 0,this._value.splice(0,d)),a-=d}return this._value.shift(),c},a.prototype.consumeStringToken=function(a){for(var b="",c=0;;){var d=this._value[c];if(d===bK|| void 0===d||d===a)return{type:0,value:b+=this.consumeStringSlice(c)};if(d===a5)return this._value.splice(0,c),cl;if(d===a7){var e=this._value[c+1];e!==bK&& void 0!==e&&(e===a5?(b+=this.consumeStringSlice(c),c=-1,this._value.shift()):b5(d,e)&&(b+=this.consumeStringSlice(c),b+=p(this.consumeEscapedCodePoint()),c=-1))}c++}},a.prototype.consumeNumber=function(){var a=[],b=a3,c=this.peekCodePoint(0);for((c===bz||c===bj)&&a.push(this.consumeCodePoint());bW(this.peekCodePoint(0));)a.push(this.consumeCodePoint());c=this.peekCodePoint(0);var d=this.peekCodePoint(1);if(c===bD&&bW(d))for(a.push(this.consumeCodePoint(),this.consumeCodePoint()),b=a4;bW(this.peekCodePoint(0));)a.push(this.consumeCodePoint());c=this.peekCodePoint(0),d=this.peekCodePoint(1);var e=this.peekCodePoint(2);if((c===bS||c===bN)&&((d===bz||d===bj)&&bW(e)||bW(d)))for(a.push(this.consumeCodePoint(),this.consumeCodePoint()),b=a4;bW(this.peekCodePoint(0));)a.push(this.consumeCodePoint());return[b8(a),b]},a.prototype.consumeNumericToken=function(){var a,b=this.consumeNumber(),c=b[0],d=b[1],e=this.peekCodePoint(0);return b6(e,this.peekCodePoint(1),this.peekCodePoint(2))?{type:15,number:c,flags:d,unit:this.consumeName()}:e===be?(this.consumeCodePoint(),{type:16,number:c,flags:d}):{type:17,number:c,flags:d}},a.prototype.consumeEscapedCodePoint=function(){var a=this.consumeCodePoint();if(bY(a)){for(var b=p(a);bY(this.peekCodePoint(0))&&b.length<6;)b+=p(this.consumeCodePoint());b1(this.peekCodePoint(0))&&this.consumeCodePoint();var c=parseInt(b,16);return 0===c||bX(c)||c>1114111?bx:c}return a===bK?bx:a},a.prototype.consumeName=function(){for(var a="";;){var b=this.consumeCodePoint();if(b3(b))a+=p(b);else{if(!b5(b,this.peekCodePoint(0)))return this.reconsumeCodePoint(b),a;a+=p(this.consumeEscapedCodePoint())}}},a}(),cv=function(){function a(a){this._tokens=a}return a.create=function(b){var c=new cu;return c.write(b),new a(c.read())},a.parseValue=function(b){return a.create(b).parseComponentValue()},a.parseValues=function(b){return a.create(b).parseComponentValues()},a.prototype.parseComponentValue=function(){for(var a=this.consumeToken();31===a.type;)a=this.consumeToken();if(32===a.type)throw SyntaxError("Error parsing CSS component value, unexpected EOF");this.reconsumeToken(a);var b=this.consumeComponentValue();do a=this.consumeToken();while(31===a.type);if(32===a.type)return b;throw SyntaxError("Error parsing CSS component value, multiple values found when expecting only one")},a.prototype.parseComponentValues=function(){for(var a=[];;){var b=this.consumeComponentValue();if(32===b.type)return a;a.push(b),a.push()}},a.prototype.consumeComponentValue=function(){var a=this.consumeToken();switch(a.type){case 11:case 28:case 2:return this.consumeSimpleBlock(a.type);case 19:return this.consumeFunction(a)}return a},a.prototype.consumeSimpleBlock=function(a){for(var b={type:a,values:[]},c=this.consumeToken();;){if(32===c.type||cE(c,a))return b;this.reconsumeToken(c),b.values.push(this.consumeComponentValue()),c=this.consumeToken()}},a.prototype.consumeFunction=function(a){for(var b={name:a.value,values:[],type:18};;){var c=this.consumeToken();if(32===c.type||3===c.type)return b;this.reconsumeToken(c),b.values.push(this.consumeComponentValue())}},a.prototype.consumeToken=function(){var a=this._tokens.shift();return void 0===a?ct:a},a.prototype.reconsumeToken=function(a){this._tokens.unshift(a)},a}(),cw=function(a){return 15===a.type},cx=function(a){return 17===a.type},cy=function(a){return 20===a.type},cz=function(a){return 0===a.type},cA=function(a,b){return cy(a)&&a.value===b},cB=function(a){return 31!==a.type},cC=function(a){return 31!==a.type&&4!==a.type},cD=function(a){var b=[],c=[];return a.forEach(function(a){if(4===a.type){if(0===c.length)throw Error("Error parsing function args, zero tokens for arg");b.push(c),c=[];return}31!==a.type&&c.push(a)}),c.length&&b.push(c),b},cE=function(a,b){return 11===b&&12===a.type||28===b&&29===a.type||2===b&&3===a.type},cF=function(a){return 17===a.type||15===a.type},cG=function(a){return 16===a.type||cF(a)},cH=function(a){return a.length>1?[a[0],a[1]]:[a[0]]},cI={type:17,number:0,flags:a3},cJ={type:16,number:50,flags:a3},cK={type:16,number:100,flags:a3},cL=function(a,b,c){var d=a[0],e=a[1];return[cM(d,b),cM(void 0!==e?e:d,c)]},cM=function(a,b){if(16===a.type)return a.number/100*b;if(cw(a))switch(a.unit){case"rem":case"em":return 16*a.number}return a.number},cN="deg",cO="grad",cP="rad",cQ="turn",cR={name:"angle",parse:function(a,b){if(15===b.type)switch(b.unit){case cN:return Math.PI*b.number/180;case cO:return Math.PI/200*b.number;case cP:return b.number;case cQ:return 2*Math.PI*b.number}throw Error("Unsupported angle type")}},cS=function(a){return 15===a.type&&(a.unit===cN||a.unit===cO||a.unit===cP||a.unit===cQ)},cT=function(a){var b=a.filter(cy).map(function(a){return a.value}).join(" ");switch(b){case"to bottom right":case"to right bottom":case"left top":case"top left":return[cI,cI];case"to top":case"bottom":return cU(0);case"to bottom left":case"to left bottom":case"right top":case"top right":return[cI,cK];case"to right":case"left":return cU(90);case"to top left":case"to left top":case"right bottom":case"bottom right":return[cK,cK];case"to bottom":case"top":return cU(180);case"to top right":case"to right top":case"left bottom":case"bottom left":return[cK,cI];case"to left":case"right":return cU(270)}return 0},cU=function(a){return Math.PI*a/180},cV={name:"color",parse:function(a,b){if(18===b.type){var c=c3[b.name];if(void 0===c)throw Error('Attempting to parse an unsupported color function "'+b.name+'"');return c(a,b.values)}if(5===b.type){if(3===b.value.length){var d=b.value.substring(0,1),e=b.value.substring(1,2),f=b.value.substring(2,3);return cY(parseInt(d+d,16),parseInt(e+e,16),parseInt(f+f,16),1)}if(4===b.value.length){var d=b.value.substring(0,1),e=b.value.substring(1,2),f=b.value.substring(2,3),g=b.value.substring(3,4);return cY(parseInt(d+d,16),parseInt(e+e,16),parseInt(f+f,16),parseInt(g+g,16)/255)}if(6===b.value.length){var d=b.value.substring(0,2),e=b.value.substring(2,4),f=b.value.substring(4,6);return cY(parseInt(d,16),parseInt(e,16),parseInt(f,16),1)}if(8===b.value.length){var d=b.value.substring(0,2),e=b.value.substring(2,4),f=b.value.substring(4,6),g=b.value.substring(6,8);return cY(parseInt(d,16),parseInt(e,16),parseInt(f,16),parseInt(g,16)/255)}}if(20===b.type){var h=c5[b.value.toUpperCase()];if(void 0!==h)return h}return c5.TRANSPARENT}},cW=function(a){return(255&a)==0},cX=function(a){var b=255&a,c=255&a>>8,d=255&a>>16,e=255&a>>24;return b<255?"rgba("+e+","+d+","+c+","+b/255+")":"rgb("+e+","+d+","+c+")"},cY=function(a,b,c,d){return(a<<24|b<<16|c<<8|Math.round(255*d)<<0)>>>0},cZ=function(a,b){if(17===a.type)return a.number;if(16===a.type){var c=3===b?1:255;return 3===b?a.number/100*c:Math.round(a.number/100*c)}return 0},c$=function(a,b){var c=b.filter(cC);if(3===c.length){var d=c.map(cZ),e=d[0],f=d[1],g=d[2];return cY(e,f,g,1)}if(4===c.length){var h=c.map(cZ),e=h[0],f=h[1],g=h[2];return cY(e,f,g,h[3])}return 0};function c_(a,b,c){return(c<0&&(c+=1),c>=1&&(c-=1),c<1/6)?(b-a)*c*6+a:c<.5?b:c<2/3?(b-a)*6*(2/3-c)+a:a}var c0,c1,c2=function(a,b){var c=b.filter(cC),d=c[0],e=c[1],f=c[2],g=c[3],h=(17===d.type?cU(d.number):cR.parse(a,d))/(2*Math.PI),i=cG(e)?e.number/100:0,j=cG(f)?f.number/100:0,k=void 0!==g&&cG(g)?cM(g,1):1;if(0===i)return cY(255*j,255*j,255*j,1);var l=j<=.5?j*(i+1):j+i-j*i,m=2*j-l,n=c_(m,l,h+1/3),o=c_(m,l,h),p=c_(m,l,h-1/3);return cY(255*n,255*o,255*p,k)},c3={hsl:c2,hsla:c2,rgb:c$,rgba:c$},c4=function(a,b){return cV.parse(a,cv.create(b).parseComponentValue())},c5={ALICEBLUE:4042850303,ANTIQUEWHITE:4209760255,AQUA:16777215,AQUAMARINE:2147472639,AZURE:4043309055,BEIGE:4126530815,BISQUE:4293182719,BLACK:255,BLANCHEDALMOND:4293643775,BLUE:65535,BLUEVIOLET:2318131967,BROWN:2771004159,BURLYWOOD:3736635391,CADETBLUE:1604231423,CHARTREUSE:2147418367,CHOCOLATE:3530104575,CORAL:4286533887,CORNFLOWERBLUE:1687547391,CORNSILK:4294499583,CRIMSON:3692313855,CYAN:16777215,DARKBLUE:35839,DARKCYAN:9145343,DARKGOLDENROD:3095837695,DARKGRAY:2846468607,DARKGREEN:6553855,DARKGREY:2846468607,DARKKHAKI:3182914559,DARKMAGENTA:2332068863,DARKOLIVEGREEN:1433087999,DARKORANGE:4287365375,DARKORCHID:2570243327,DARKRED:2332033279,DARKSALMON:3918953215,DARKSEAGREEN:2411499519,DARKSLATEBLUE:1211993087,DARKSLATEGRAY:793726975,DARKSLATEGREY:793726975,DARKTURQUOISE:13554175,DARKVIOLET:2483082239,DEEPPINK:4279538687,DEEPSKYBLUE:12582911,DIMGRAY:1768516095,DIMGREY:1768516095,DODGERBLUE:512819199,FIREBRICK:2988581631,FLORALWHITE:4294635775,FORESTGREEN:579543807,FUCHSIA:4278255615,GAINSBORO:3705462015,GHOSTWHITE:4177068031,GOLD:4292280575,GOLDENROD:3668254975,GRAY:2155905279,GREEN:8388863,GREENYELLOW:2919182335,GREY:2155905279,HONEYDEW:4043305215,HOTPINK:4285117695,INDIANRED:3445382399,INDIGO:1258324735,IVORY:4294963455,KHAKI:4041641215,LAVENDER:3873897215,LAVENDERBLUSH:4293981695,LAWNGREEN:2096890111,LEMONCHIFFON:4294626815,LIGHTBLUE:2916673279,LIGHTCORAL:4034953471,LIGHTCYAN:3774873599,LIGHTGOLDENRODYELLOW:4210742015,LIGHTGRAY:3553874943,LIGHTGREEN:2431553791,LIGHTGREY:3553874943,LIGHTPINK:4290167295,LIGHTSALMON:4288707327,LIGHTSEAGREEN:548580095,LIGHTSKYBLUE:2278488831,LIGHTSLATEGRAY:2005441023,LIGHTSLATEGREY:2005441023,LIGHTSTEELBLUE:2965692159,LIGHTYELLOW:4294959359,LIME:16711935,LIMEGREEN:852308735,LINEN:4210091775,MAGENTA:4278255615,MAROON:2147483903,MEDIUMAQUAMARINE:1724754687,MEDIUMBLUE:52735,MEDIUMORCHID:3126187007,MEDIUMPURPLE:2473647103,MEDIUMSEAGREEN:1018393087,MEDIUMSLATEBLUE:2070474495,MEDIUMSPRINGGREEN:16423679,MEDIUMTURQUOISE:1221709055,MEDIUMVIOLETRED:3340076543,MIDNIGHTBLUE:421097727,MINTCREAM:4127193855,MISTYROSE:4293190143,MOCCASIN:4293178879,NAVAJOWHITE:4292783615,NAVY:33023,OLDLACE:4260751103,OLIVE:2155872511,OLIVEDRAB:1804477439,ORANGE:4289003775,ORANGERED:4282712319,ORCHID:3664828159,PALEGOLDENROD:4008225535,PALEGREEN:2566625535,PALETURQUOISE:2951671551,PALEVIOLETRED:3681588223,PAPAYAWHIP:4293907967,PEACHPUFF:4292524543,PERU:3448061951,PINK:4290825215,PLUM:3718307327,POWDERBLUE:2967529215,PURPLE:2147516671,REBECCAPURPLE:1714657791,RED:4278190335,ROSYBROWN:3163525119,ROYALBLUE:1097458175,SADDLEBROWN:2336560127,SALMON:4202722047,SANDYBROWN:4104413439,SEAGREEN:780883967,SEASHELL:4294307583,SIENNA:2689740287,SILVER:3233857791,SKYBLUE:2278484991,SLATEBLUE:1784335871,SLATEGRAY:1887473919,SLATEGREY:1887473919,SNOW:4294638335,SPRINGGREEN:16744447,STEELBLUE:1182971135,TAN:3535047935,TEAL:8421631,THISTLE:3636451583,TOMATO:4284696575,TRANSPARENT:0,TURQUOISE:1088475391,VIOLET:4001558271,WHEAT:4125012991,WHITE:4294967295,WHITESMOKE:4126537215,YELLOW:4294902015,YELLOWGREEN:2597139199},c6={name:"background-clip",initialValue:"border-box",prefix:!1,type:1,parse:function(a,b){return b.map(function(a){if(cy(a))switch(a.value){case"padding-box":return 1;case"content-box":return 2}return 0})}},c7={name:"background-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},c8=function(a,b){var c=cV.parse(a,b[0]),d=b[1];return d&&cG(d)?{color:c,stop:d}:{color:c,stop:null}},c9=function(a,b){var c=a[0],d=a[a.length-1];null===c.stop&&(c.stop=cI),null===d.stop&&(d.stop=cK);for(var e=[],f=0,g=0;g<a.length;g++){var h=a[g].stop;if(null!==h){var i=cM(h,b);i>f?e.push(i):e.push(f),f=i}else e.push(null)}for(var j=null,g=0;g<e.length;g++){var k=e[g];if(null===k)null===j&&(j=g);else if(null!==j){for(var l=g-j,m=(k-e[j-1])/(l+1),n=1;n<=l;n++)e[j+n-1]=m*n;j=null}}return a.map(function(a,c){return{color:a.color,stop:Math.max(Math.min(1,e[c]/b),0)}})},da=function(a,b,c){var d=b/2,e=cM(a[0],b)-d;return(Math.atan2(c/2-cM(a[1],c),e)+2*Math.PI)%(2*Math.PI)},db=function(a,b,c){var d="number"==typeof a?a:da(a,b,c),e=Math.abs(b*Math.sin(d))+Math.abs(c*Math.cos(d)),f=b/2,g=c/2,h=e/2,i=Math.sin(d-Math.PI/2)*h,j=Math.cos(d-Math.PI/2)*h;return[e,f-j,f+j,g-i,g+i]},dc=function(a,b){return Math.sqrt(a*a+b*b)},dd=function(a,b,c,d,e){return[[0,0],[0,b],[a,0],[a,b]].reduce(function(a,b){var f=b[0],g=b[1],h=dc(c-f,d-g);return(e?h<a.optimumDistance:h>a.optimumDistance)?{optimumCorner:b,optimumDistance:h}:a},{optimumDistance:e?1/0:-1/0,optimumCorner:null}).optimumCorner},de=function(a,b,c,d,e){var f=0,g=0;switch(a.size){case 0:0===a.shape?f=g=Math.min(Math.abs(b),Math.abs(b-d),Math.abs(c),Math.abs(c-e)):1===a.shape&&(f=Math.min(Math.abs(b),Math.abs(b-d)),g=Math.min(Math.abs(c),Math.abs(c-e)));break;case 2:if(0===a.shape)f=g=Math.min(dc(b,c),dc(b,c-e),dc(b-d,c),dc(b-d,c-e));else if(1===a.shape){var h=Math.min(Math.abs(c),Math.abs(c-e))/Math.min(Math.abs(b),Math.abs(b-d)),i=dd(d,e,b,c,!0),j=i[0],k=i[1];f=dc(j-b,(k-c)/h),g=h*f}break;case 1:0===a.shape?f=g=Math.max(Math.abs(b),Math.abs(b-d),Math.abs(c),Math.abs(c-e)):1===a.shape&&(f=Math.max(Math.abs(b),Math.abs(b-d)),g=Math.max(Math.abs(c),Math.abs(c-e)));break;case 3:if(0===a.shape)f=g=Math.max(dc(b,c),dc(b,c-e),dc(b-d,c),dc(b-d,c-e));else if(1===a.shape){var h=Math.max(Math.abs(c),Math.abs(c-e))/Math.max(Math.abs(b),Math.abs(b-d)),l=dd(d,e,b,c,!1),j=l[0],k=l[1];f=dc(j-b,(k-c)/h),g=h*f}}return Array.isArray(a.size)&&(f=cM(a.size[0],d),g=2===a.size.length?cM(a.size[1],e):f),[f,g]},df=function(a,b){var c=cU(180),d=[];return cD(b).forEach(function(b,e){if(0===e){var f=b[0];if(20===f.type&& -1!==["top","left","right","bottom"].indexOf(f.value)){c=cT(b);return}if(cS(f)){c=(cR.parse(a,f)+cU(270))%cU(360);return}}var g=c8(a,b);d.push(g)}),{angle:c,stops:d,type:1}},dg=function(a,b){var c=cU(180),d=[],e=1;return cD(b).forEach(function(b,c){var f=b[0];if(0===c){if(cy(f)&&"linear"===f.value){e=1;return}if(cy(f)&&"radial"===f.value){e=2;return}}if(18===f.type){if("from"===f.name){var g=cV.parse(a,f.values[0]);d.push({stop:cI,color:g})}else if("to"===f.name){var g=cV.parse(a,f.values[0]);d.push({stop:cK,color:g})}else if("color-stop"===f.name){var h=f.values.filter(cC);if(2===h.length){var g=cV.parse(a,h[1]),i=h[0];cx(i)&&d.push({stop:{type:16,number:100*i.number,flags:i.flags},color:g})}}}}),1===e?{angle:(c+cU(180))%cU(360),stops:d,type:e}:{size:3,shape:0,stops:d,position:[],type:e}},dh="closest-side",di="farthest-side",dj="closest-corner",dk="farthest-corner",dl="circle",dm="ellipse",dn="cover",dp="contain",dq=function(a,b){var c=0,d=3,e=[],f=[];return cD(b).forEach(function(b,g){var h=!0;if(0===g){var i=!1;h=b.reduce(function(a,b){if(i){if(cy(b))switch(b.value){case"center":f.push(cJ);break;case"top":case"left":f.push(cI);break;case"right":case"bottom":f.push(cK)}else(cG(b)||cF(b))&&f.push(b)}else if(cy(b))switch(b.value){case dl:return c=0,!1;case dm:return c=1,!1;case"at":return i=!0,!1;case dh:return d=0,!1;case dn:case di:return d=1,!1;case dp:case dj:return d=2,!1;case dk:return d=3,!1}else if(cF(b)||cG(b))return Array.isArray(d)||(d=[]),d.push(b),!1;return a},h)}if(h){var j=c8(a,b);e.push(j)}}),{size:d,shape:c,stops:e,position:f,type:2}},dr=function(a,b){var c=0,d=3,e=[],f=[];return cD(b).forEach(function(b,g){var h=!0;if(0===g?h=b.reduce(function(a,b){if(cy(b))switch(b.value){case"center":return f.push(cJ),!1;case"top":case"left":return f.push(cI),!1;case"right":case"bottom":return f.push(cK),!1}else if(cG(b)||cF(b))return f.push(b),!1;return a},h):1===g&&(h=b.reduce(function(a,b){if(cy(b))switch(b.value){case dl:return c=0,!1;case dm:return c=1,!1;case dp:case dh:return d=0,!1;case di:return d=1,!1;case dj:return d=2,!1;case dn:case dk:return d=3,!1}else if(cF(b)||cG(b))return Array.isArray(d)||(d=[]),d.push(b),!1;return a},h)),h){var i=c8(a,b);e.push(i)}}),{size:d,shape:c,stops:e,position:f,type:2}},ds={name:"image",parse:function(a,b){if(22===b.type){var c={url:b.value,type:0};return a.cache.addImage(b.value),c}if(18===b.type){var d=dt[b.name];if(void 0===d)throw Error('Attempting to parse an unsupported image function "'+b.name+'"');return d(a,b.values)}throw Error("Unsupported image type "+b.type)}},dt={"linear-gradient":function(a,b){var c=cU(180),d=[];return cD(b).forEach(function(b,e){if(0===e){var f=b[0];if(20===f.type&&"to"===f.value){c=cT(b);return}if(cS(f)){c=cR.parse(a,f);return}}var g=c8(a,b);d.push(g)}),{angle:c,stops:d,type:1}},"-moz-linear-gradient":df,"-ms-linear-gradient":df,"-o-linear-gradient":df,"-webkit-linear-gradient":df,"radial-gradient":dq,"-moz-radial-gradient":dr,"-ms-radial-gradient":dr,"-o-radial-gradient":dr,"-webkit-radial-gradient":dr,"-webkit-gradient":dg},du={name:"background-image",initialValue:"none",type:1,prefix:!1,parse:function(a,b){if(0===b.length)return[];var c=b[0];return 20===c.type&&"none"===c.value?[]:b.filter(function(a){var b;return cC(a)&&!(20===(b=a).type&&"none"===b.value)&&(18!==b.type||!!dt[b.name])}).map(function(b){return ds.parse(a,b)})}},dv={name:"background-origin",initialValue:"border-box",prefix:!1,type:1,parse:function(a,b){return b.map(function(a){if(cy(a))switch(a.value){case"padding-box":return 1;case"content-box":return 2}return 0})}},dw={name:"background-position",initialValue:"0% 0%",type:1,prefix:!1,parse:function(a,b){return cD(b).map(function(a){return a.filter(cG)}).map(cH)}},dx={name:"background-repeat",initialValue:"repeat",prefix:!1,type:1,parse:function(a,b){return cD(b).map(function(a){return a.filter(cy).map(function(a){return a.value}).join(" ")}).map(dy)}},dy=function(a){switch(a){case"no-repeat":return 1;case"repeat-x":case"repeat no-repeat":return 2;case"repeat-y":case"no-repeat repeat":return 3;default:return 0}};(c0=a||(a={})).AUTO="auto",c0.CONTAIN="contain",c0.COVER="cover";var dz,dA={name:"background-size",initialValue:"0",prefix:!1,type:1,parse:function(a,b){return cD(b).map(function(a){return a.filter(dB)})}},dB=function(a){return cy(a)||cG(a)},dC=function(a){return{name:"border-"+a+"-color",initialValue:"transparent",prefix:!1,type:3,format:"color"}},dD=dC("top"),dE=dC("right"),dF=dC("bottom"),dG=dC("left"),dH=function(a){return{name:"border-radius-"+a,initialValue:"0 0",prefix:!1,type:1,parse:function(a,b){return cH(b.filter(cG))}}},dI=dH("top-left"),dJ=dH("top-right"),dK=dH("bottom-right"),dL=dH("bottom-left"),dM=function(a){return{name:"border-"+a+"-style",initialValue:"solid",prefix:!1,type:2,parse:function(a,b){switch(b){case"none":return 0;case"dashed":return 2;case"dotted":return 3;case"double":return 4}return 1}}},dN=dM("top"),dO=dM("right"),dP=dM("bottom"),dQ=dM("left"),dR=function(a){return{name:"border-"+a+"-width",initialValue:"0",type:0,prefix:!1,parse:function(a,b){return cw(b)?b.number:0}}},dS=dR("top"),dT=dR("right"),dU=dR("bottom"),dV=dR("left"),dW={name:"color",initialValue:"transparent",prefix:!1,type:3,format:"color"},dX={name:"direction",initialValue:"ltr",prefix:!1,type:2,parse:function(a,b){return"rtl"===b?1:0}},dY={name:"display",initialValue:"inline-block",prefix:!1,type:1,parse:function(a,b){return b.filter(cy).reduce(function(a,b){return a|dZ(b.value)},0)}},dZ=function(a){switch(a){case"block":case"-webkit-box":return 2;case"inline":return 4;case"run-in":return 8;case"flow":return 16;case"flow-root":return 32;case"table":return 64;case"flex":case"-webkit-flex":return 128;case"grid":case"-ms-grid":return 256;case"ruby":return 512;case"subgrid":return 1024;case"list-item":return 2048;case"table-row-group":return 4096;case"table-header-group":return 8192;case"table-footer-group":return 16384;case"table-row":return 32768;case"table-cell":return 65536;case"table-column-group":return 131072;case"table-column":return 262144;case"table-caption":return 524288;case"ruby-base":return 1048576;case"ruby-text":return 2097152;case"ruby-base-container":return 4194304;case"ruby-text-container":return 8388608;case"contents":return 16777216;case"inline-block":return 33554432;case"inline-list-item":return 67108864;case"inline-table":return 134217728;case"inline-flex":return 268435456;case"inline-grid":return 536870912}return 0},d$={name:"float",initialValue:"none",prefix:!1,type:2,parse:function(a,b){switch(b){case"left":return 1;case"right":return 2;case"inline-start":return 3;case"inline-end":return 4}return 0}},d_={name:"letter-spacing",initialValue:"0",prefix:!1,type:0,parse:function(a,b){return 20===b.type&&"normal"===b.value?0:17===b.type||15===b.type?b.number:0}};(dz=b||(b={})).NORMAL="normal",dz.STRICT="strict";var d0,d1={name:"line-break",initialValue:"normal",prefix:!1,type:2,parse:function(a,c){return"strict"===c?b.STRICT:(0,b.NORMAL)}},d2={name:"line-height",initialValue:"normal",prefix:!1,type:4},d3=function(a,b){return cy(a)&&"normal"===a.value?1.2*b:17===a.type?b*a.number:cG(a)?cM(a,b):b},d4={name:"list-style-image",initialValue:"none",type:0,prefix:!1,parse:function(a,b){return 20===b.type&&"none"===b.value?null:ds.parse(a,b)}},d5={name:"list-style-position",initialValue:"outside",prefix:!1,type:2,parse:function(a,b){return"inside"===b?0:1}},d6={name:"list-style-type",initialValue:"none",prefix:!1,type:2,parse:function(a,b){switch(b){case"disc":return 0;case"circle":return 1;case"square":return 2;case"decimal":return 3;case"cjk-decimal":return 4;case"decimal-leading-zero":return 5;case"lower-roman":return 6;case"upper-roman":return 7;case"lower-greek":return 8;case"lower-alpha":return 9;case"upper-alpha":return 10;case"arabic-indic":return 11;case"armenian":return 12;case"bengali":return 13;case"cambodian":return 14;case"cjk-earthly-branch":return 15;case"cjk-heavenly-stem":return 16;case"cjk-ideographic":return 17;case"devanagari":return 18;case"ethiopic-numeric":return 19;case"georgian":return 20;case"gujarati":return 21;case"gurmukhi":case"hebrew":return 22;case"hiragana":return 23;case"hiragana-iroha":return 24;case"japanese-formal":return 25;case"japanese-informal":return 26;case"kannada":return 27;case"katakana":return 28;case"katakana-iroha":return 29;case"khmer":return 30;case"korean-hangul-formal":return 31;case"korean-hanja-formal":return 32;case"korean-hanja-informal":return 33;case"lao":return 34;case"lower-armenian":return 35;case"malayalam":return 36;case"mongolian":return 37;case"myanmar":return 38;case"oriya":return 39;case"persian":return 40;case"simp-chinese-formal":return 41;case"simp-chinese-informal":return 42;case"tamil":return 43;case"telugu":return 44;case"thai":return 45;case"tibetan":return 46;case"trad-chinese-formal":return 47;case"trad-chinese-informal":return 48;case"upper-armenian":return 49;case"disclosure-open":return 50;case"disclosure-closed":return 51;default:return -1}}},d7=function(a){return{name:"margin-"+a,initialValue:"0",prefix:!1,type:4}},d8=d7("top"),d9=d7("right"),ea=d7("bottom"),eb=d7("left"),ec={name:"overflow",initialValue:"visible",prefix:!1,type:1,parse:function(a,b){return b.filter(cy).map(function(a){switch(a.value){case"hidden":return 1;case"scroll":return 2;case"clip":return 3;case"auto":return 4;default:return 0}})}},ed={name:"overflow-wrap",initialValue:"normal",prefix:!1,type:2,parse:function(a,b){return"break-word"===b?"break-word":"normal"}},ee=function(a){return{name:"padding-"+a,initialValue:"0",prefix:!1,type:3,format:"length-percentage"}},ef=ee("top"),eg=ee("right"),eh=ee("bottom"),ei=ee("left"),ej={name:"text-align",initialValue:"left",prefix:!1,type:2,parse:function(a,b){switch(b){case"right":return 2;case"center":case"justify":return 1;default:return 0}}},ek={name:"position",initialValue:"static",prefix:!1,type:2,parse:function(a,b){switch(b){case"relative":return 1;case"absolute":return 2;case"fixed":return 3;case"sticky":return 4}return 0}},el={name:"text-shadow",initialValue:"none",type:1,prefix:!1,parse:function(a,b){return 1===b.length&&cA(b[0],"none")?[]:cD(b).map(function(b){for(var c={color:c5.TRANSPARENT,offsetX:cI,offsetY:cI,blur:cI},d=0,e=0;e<b.length;e++){var f=b[e];cF(f)?(0===d?c.offsetX=f:1===d?c.offsetY=f:c.blur=f,d++):c.color=cV.parse(a,f)}return c})}},em={name:"text-transform",initialValue:"none",prefix:!1,type:2,parse:function(a,b){switch(b){case"uppercase":return 2;case"lowercase":return 1;case"capitalize":return 3}return 0}},en={name:"transform",initialValue:"none",prefix:!0,type:0,parse:function(a,b){if(20===b.type&&"none"===b.value)return null;if(18===b.type){var c=eo[b.name];if(void 0===c)throw Error('Attempting to parse an unsupported transform function "'+b.name+'"');return c(b.values)}return null}},eo={matrix:function(a){var b=a.filter(function(a){return 17===a.type}).map(function(a){return a.number});return 6===b.length?b:null},matrix3d:function(a){var b=a.filter(function(a){return 17===a.type}).map(function(a){return a.number}),c=b[0],d=b[1];b[2],b[3];var e=b[4],f=b[5];b[6],b[7],b[8],b[9],b[10],b[11];var g=b[12],h=b[13];return b[14],b[15],16===b.length?[c,d,e,f,g,h]:null}},ep={type:16,number:50,flags:a3},eq=[ep,ep],er={name:"transform-origin",initialValue:"50% 50%",prefix:!0,type:1,parse:function(a,b){var c=b.filter(cG);return 2!==c.length?eq:[c[0],c[1]]}},es={name:"visible",initialValue:"none",prefix:!1,type:2,parse:function(a,b){switch(b){case"hidden":return 1;case"collapse":return 2;default:return 0}}};(d0=c||(c={})).NORMAL="normal",d0.BREAK_ALL="break-all",d0.KEEP_ALL="keep-all";for(var et={name:"word-break",initialValue:"normal",prefix:!1,type:2,parse:function(a,b){switch(b){case"break-all":return c.BREAK_ALL;case"keep-all":return c.KEEP_ALL;default:return c.NORMAL}}},eu={name:"z-index",initialValue:"auto",prefix:!1,type:0,parse:function(a,b){if(20===b.type)return{auto:!0,order:0};if(cx(b))return{auto:!1,order:b.number};throw Error("Invalid z-index number parsed")}},ev={name:"time",parse:function(a,b){if(15===b.type)switch(b.unit.toLowerCase()){case"s":return 1e3*b.number;case"ms":return b.number}throw Error("Unsupported time type")}},ew={name:"opacity",initialValue:"1",type:0,prefix:!1,parse:function(a,b){return cx(b)?b.number:1}},ex={name:"text-decoration-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},ey={name:"text-decoration-line",initialValue:"none",prefix:!1,type:1,parse:function(a,b){return b.filter(cy).map(function(a){switch(a.value){case"underline":return 1;case"overline":return 2;case"line-through":return 3;case"none":return 4}return 0}).filter(function(a){return 0!==a})}},ez={name:"font-family",initialValue:"",prefix:!1,type:1,parse:function(a,b){var c=[],d=[];return b.forEach(function(a){switch(a.type){case 20:case 0:c.push(a.value);break;case 17:c.push(a.number.toString());break;case 4:d.push(c.join(" ")),c.length=0}}),c.length&&d.push(c.join(" ")),d.map(function(a){return -1===a.indexOf(" ")?a:"'"+a+"'"})}},eA={name:"font-size",initialValue:"0",prefix:!1,type:3,format:"length"},eB={name:"font-weight",initialValue:"normal",type:0,prefix:!1,parse:function(a,b){return cx(b)?b.number:cy(b)&&"bold"===b.value?700:400}},eC={name:"font-variant",initialValue:"none",type:1,prefix:!1,parse:function(a,b){return b.filter(cy).map(function(a){return a.value})}},eD={name:"font-style",initialValue:"normal",prefix:!1,type:2,parse:function(a,b){switch(b){case"oblique":return"oblique";case"italic":return"italic";default:return"normal"}}},eE=function(a,b){return(a&b)!=0},eF={name:"content",initialValue:"none",type:1,prefix:!1,parse:function(a,b){if(0===b.length)return[];var c=b[0];return 20===c.type&&"none"===c.value?[]:b}},eG={name:"counter-increment",initialValue:"none",prefix:!0,type:1,parse:function(a,b){if(0===b.length)return null;var c=b[0];if(20===c.type&&"none"===c.value)return null;for(var d=[],e=b.filter(cB),f=0;f<e.length;f++){var g=e[f],h=e[f+1];if(20===g.type){var i=h&&cx(h)?h.number:1;d.push({counter:g.value,increment:i})}}return d}},eH={name:"counter-reset",initialValue:"none",prefix:!0,type:1,parse:function(a,b){if(0===b.length)return[];for(var c=[],d=b.filter(cB),e=0;e<d.length;e++){var f=d[e],g=d[e+1];if(cy(f)&&"none"!==f.value){var h=g&&cx(g)?g.number:0;c.push({counter:f.value,reset:h})}}return c}},eI={name:"duration",initialValue:"0s",prefix:!1,type:1,parse:function(a,b){return b.filter(cw).map(function(b){return ev.parse(a,b)})}},eJ={name:"quotes",initialValue:"none",prefix:!0,type:1,parse:function(a,b){if(0===b.length)return null;var c=b[0];if(20===c.type&&"none"===c.value)return null;var d=[],e=b.filter(cz);if(e.length%2!=0)return null;for(var f=0;f<e.length;f+=2){var g=e[f].value,h=e[f+1].value;d.push({open:g,close:h})}return d}},eK=function(a,b,c){if(!a)return"";var d=a[Math.min(b,a.length-1)];return d?c?d.open:d.close:""},eL={name:"box-shadow",initialValue:"none",type:1,prefix:!1,parse:function(a,b){return 1===b.length&&cA(b[0],"none")?[]:cD(b).map(function(b){for(var c={color:255,offsetX:cI,offsetY:cI,blur:cI,spread:cI,inset:!1},d=0,e=0;e<b.length;e++){var f=b[e];cA(f,"inset")?c.inset=!0:cF(f)?(0===d?c.offsetX=f:1===d?c.offsetY=f:2===d?c.blur=f:c.spread=f,d++):c.color=cV.parse(a,f)}return c})}},eM={name:"paint-order",initialValue:"normal",prefix:!1,type:1,parse:function(a,b){var c=[];return b.filter(cy).forEach(function(a){switch(a.value){case"stroke":c.push(1);break;case"fill":c.push(0);break;case"markers":c.push(2)}}),[0,1,2].forEach(function(a){-1===c.indexOf(a)&&c.push(a)}),c}},eN={name:"-webkit-text-stroke-color",initialValue:"currentcolor",prefix:!1,type:3,format:"color"},eO={name:"-webkit-text-stroke-width",initialValue:"0",type:0,prefix:!1,parse:function(a,b){return cw(b)?b.number:0}},eP=function(){function a(a,b){this.animationDuration=eS(a,eI,b.animationDuration),this.backgroundClip=eS(a,c6,b.backgroundClip),this.backgroundColor=eS(a,c7,b.backgroundColor),this.backgroundImage=eS(a,du,b.backgroundImage),this.backgroundOrigin=eS(a,dv,b.backgroundOrigin),this.backgroundPosition=eS(a,dw,b.backgroundPosition),this.backgroundRepeat=eS(a,dx,b.backgroundRepeat),this.backgroundSize=eS(a,dA,b.backgroundSize),this.borderTopColor=eS(a,dD,b.borderTopColor),this.borderRightColor=eS(a,dE,b.borderRightColor),this.borderBottomColor=eS(a,dF,b.borderBottomColor),this.borderLeftColor=eS(a,dG,b.borderLeftColor),this.borderTopLeftRadius=eS(a,dI,b.borderTopLeftRadius),this.borderTopRightRadius=eS(a,dJ,b.borderTopRightRadius),this.borderBottomRightRadius=eS(a,dK,b.borderBottomRightRadius),this.borderBottomLeftRadius=eS(a,dL,b.borderBottomLeftRadius),this.borderTopStyle=eS(a,dN,b.borderTopStyle),this.borderRightStyle=eS(a,dO,b.borderRightStyle),this.borderBottomStyle=eS(a,dP,b.borderBottomStyle),this.borderLeftStyle=eS(a,dQ,b.borderLeftStyle),this.borderTopWidth=eS(a,dS,b.borderTopWidth),this.borderRightWidth=eS(a,dT,b.borderRightWidth),this.borderBottomWidth=eS(a,dU,b.borderBottomWidth),this.borderLeftWidth=eS(a,dV,b.borderLeftWidth),this.boxShadow=eS(a,eL,b.boxShadow),this.color=eS(a,dW,b.color),this.direction=eS(a,dX,b.direction),this.display=eS(a,dY,b.display),this.float=eS(a,d$,b.cssFloat),this.fontFamily=eS(a,ez,b.fontFamily),this.fontSize=eS(a,eA,b.fontSize),this.fontStyle=eS(a,eD,b.fontStyle),this.fontVariant=eS(a,eC,b.fontVariant),this.fontWeight=eS(a,eB,b.fontWeight),this.letterSpacing=eS(a,d_,b.letterSpacing),this.lineBreak=eS(a,d1,b.lineBreak),this.lineHeight=eS(a,d2,b.lineHeight),this.listStyleImage=eS(a,d4,b.listStyleImage),this.listStylePosition=eS(a,d5,b.listStylePosition),this.listStyleType=eS(a,d6,b.listStyleType),this.marginTop=eS(a,d8,b.marginTop),this.marginRight=eS(a,d9,b.marginRight),this.marginBottom=eS(a,ea,b.marginBottom),this.marginLeft=eS(a,eb,b.marginLeft),this.opacity=eS(a,ew,b.opacity);var c,d,e=eS(a,ec,b.overflow);this.overflowX=e[0],this.overflowY=e[e.length>1?1:0],this.overflowWrap=eS(a,ed,b.overflowWrap),this.paddingTop=eS(a,ef,b.paddingTop),this.paddingRight=eS(a,eg,b.paddingRight),this.paddingBottom=eS(a,eh,b.paddingBottom),this.paddingLeft=eS(a,ei,b.paddingLeft),this.paintOrder=eS(a,eM,b.paintOrder),this.position=eS(a,ek,b.position),this.textAlign=eS(a,ej,b.textAlign),this.textDecorationColor=eS(a,ex,null!==(c=b.textDecorationColor)&& void 0!==c?c:b.color),this.textDecorationLine=eS(a,ey,null!==(d=b.textDecorationLine)&& void 0!==d?d:b.textDecoration),this.textShadow=eS(a,el,b.textShadow),this.textTransform=eS(a,em,b.textTransform),this.transform=eS(a,en,b.transform),this.transformOrigin=eS(a,er,b.transformOrigin),this.visibility=eS(a,es,b.visibility),this.webkitTextStrokeColor=eS(a,eN,b.webkitTextStrokeColor),this.webkitTextStrokeWidth=eS(a,eO,b.webkitTextStrokeWidth),this.wordBreak=eS(a,et,b.wordBreak),this.zIndex=eS(a,eu,b.zIndex)}return a.prototype.isVisible=function(){return this.display>0&&this.opacity>0&&0===this.visibility},a.prototype.isTransparent=function(){return cW(this.backgroundColor)},a.prototype.isTransformed=function(){return null!==this.transform},a.prototype.isPositioned=function(){return 0!==this.position},a.prototype.isPositionedWithZIndex=function(){return this.isPositioned()&&!this.zIndex.auto},a.prototype.isFloating=function(){return 0!==this.float},a.prototype.isInlineLevel=function(){return eE(this.display,4)||eE(this.display,33554432)||eE(this.display,268435456)||eE(this.display,536870912)||eE(this.display,67108864)||eE(this.display,134217728)},a}(),eQ=function(a,b){this.content=eS(a,eF,b.content),this.quotes=eS(a,eJ,b.quotes)},eR=function(a,b){this.counterIncrement=eS(a,eG,b.counterIncrement),this.counterReset=eS(a,eH,b.counterReset)},eS=function(a,b,c){var d=new cu,e=null!=c?c.toString():b.initialValue;d.write(e);var f=new cv(d.read());switch(b.type){case 2:var g=f.parseComponentValue();return b.parse(a,cy(g)?g.value:b.initialValue);case 0:return b.parse(a,f.parseComponentValue());case 1:return b.parse(a,f.parseComponentValues());case 4:return f.parseComponentValue();case 3:switch(b.format){case"angle":return cR.parse(a,f.parseComponentValue());case"color":return cV.parse(a,f.parseComponentValue());case"image":return ds.parse(a,f.parseComponentValue());case"length":var h=f.parseComponentValue();return cF(h)?h:cI;case"length-percentage":var i=f.parseComponentValue();return cG(i)?i:cI;case"time":return ev.parse(a,f.parseComponentValue())}}},eT="data-html2canvas-debug",eU=function(a){var b=a.getAttribute(eT);switch(b){case"all":return 1;case"clone":return 2;case"parse":return 3;case"render":return 4;default:return 0}},eV=function(a,b){var c=eU(a);return 1===c||b===c},eW=function(a,b){this.context=a,this.textNodes=[],this.elements=[],this.flags=0,eV(b,3),this.styles=new eP(a,window.getComputedStyle(b,null)),gD(b)&&(this.styles.animationDuration.some(function(a){return a>0})&&(b.style.animationDuration="0s"),null!==this.styles.transform&&(b.style.transform="none")),this.bounds=m(this.context,b),eV(b,4)&&(this.flags|=16)},eX=" ",eY="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",eZ="undefined"==typeof Uint8Array?[]:new Uint8Array(256),e$=0;e$<eY.length;e$++)eZ[eY.charCodeAt(e$)]=e$;for(var e_=function(a){var b,c,d,e,f,g=.75*a.length,h=a.length,i=0;"="===a[a.length-1]&&(g--,"="===a[a.length-2]&&g--);var j="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array&& void 0!==Uint8Array.prototype.slice?new ArrayBuffer(g):Array(g),k=Array.isArray(j)?j:new Uint8Array(j);for(b=0;b<h;b+=4)c=eZ[a.charCodeAt(b)],d=eZ[a.charCodeAt(b+1)],e=eZ[a.charCodeAt(b+2)],f=eZ[a.charCodeAt(b+3)],k[i++]=c<<2|d>>4,k[i++]=(15&d)<<4|e>>2,k[i++]=(3&e)<<6|63&f;return j},e0=function(a){for(var b=a.length,c=[],d=0;d<b;d+=2)c.push(a[d+1]<<8|a[d]);return c},e1=function(a){for(var b=a.length,c=[],d=0;d<b;d+=4)c.push(a[d+3]<<24|a[d+2]<<16|a[d+1]<<8|a[d]);return c},e2=5,e3=11,e4=2,e5=e3-e2,e6=65536>>e2,e7=1<<e2,e8=e7-1,e9=1024>>e2,fa=e6+e9,fb=fa,fc=32,fd=fb+fc,fe=65536>>e3,ff=1<<e5,fg=ff-1,fh=function(a,b,c){return a.slice?a.slice(b,c):new Uint16Array(Array.prototype.slice.call(a,b,c))},fi=function(a,b,c){return a.slice?a.slice(b,c):new Uint32Array(Array.prototype.slice.call(a,b,c))},fj=function(a,b){var c=e_(a),d=Array.isArray(c)?e1(c):new Uint32Array(c),e=Array.isArray(c)?e0(c):new Uint16Array(c),f=24,g=fh(e,f/2,d[4]/2),h=2===d[5]?fh(e,(f+d[4])/2):fi(d,Math.ceil((f+d[4])/4));return new fk(d[0],d[1],d[2],d[3],g,h)},fk=function(){function a(a,b,c,d,e,f){this.initialValue=a,this.errorValue=b,this.highStart=c,this.highValueIndex=d,this.index=e,this.data=f}return a.prototype.get=function(a){var b;if(a>=0){if(a<55296||a>56319&&a<=65535)return b=((b=this.index[a>>e2])<<e4)+(a&e8),this.data[b];if(a<=65535)return b=((b=this.index[e6+(a-55296>>e2)])<<e4)+(a&e8),this.data[b];if(a<this.highStart)return b=fd-fe+(a>>e3),b=this.index[b],b+=a>>e2&fg,b=((b=this.index[b])<<e4)+(a&e8),this.data[b];if(a<=1114111)return this.data[this.highValueIndex]}return this.errorValue},a}(),fl="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",fm="undefined"==typeof Uint8Array?[]:new Uint8Array(256),fn=0;fn<fl.length;fn++)fm[fl.charCodeAt(fn)]=fn;var fo,fp=1,fq=2,fr=3,fs=4,ft=5,fu=7,fv=8,fw=9,fx=10,fy=11,fz=12,fA=13,fB=14,fC=15,fD=function(a){for(var b=[],c=0,d=a.length;c<d;){var e=a.charCodeAt(c++);if(e>=55296&&e<=56319&&c<d){var f=a.charCodeAt(c++);(64512&f)==56320?b.push(((1023&e)<<10)+(1023&f)+65536):(b.push(e),c--)}else b.push(e)}return b},fE=function(){for(var a=[],b=0;b<arguments.length;b++)a[b]=arguments[b];if(String.fromCodePoint)return String.fromCodePoint.apply(String,a);var c=a.length;if(!c)return"";for(var d=[],e=-1,f="";++e<c;){var g=a[e];g<=65535?d.push(g):(g-=65536,d.push((g>>10)+55296,g%1024+56320)),(e+1===c||d.length>16384)&&(f+=String.fromCharCode.apply(String,d),d.length=0)}return f},fF=fj(eX),fG="\xd7",fH="\xf7",fI=function(a){return fF.get(a)},fJ=function(a,b,c){var d=c-2,e=b[d],f=b[c-1],g=b[c];if(f===fq&&g===fr)return fG;if(f===fq||f===fr||f===fs||g===fq||g===fr||g===fs)return fH;if(f===fv&& -1!==[fv,fw,fy,fz].indexOf(g)||(f===fy||f===fw)&&(g===fw||g===fx)||(f===fz||f===fx)&&g===fx||g===fA||g===ft||g===fu||f===fp)return fG;if(f===fA&&g===fB){for(;e===ft;)e=b[--d];if(e===fB)return fG}if(f===fC&&g===fC){for(var h=0;e===fC;)h++,e=b[--d];if(h%2==0)return fG}return fH},fK=function(a){var b=fD(a),c=b.length,d=0,e=0,f=b.map(fI);return{next:function(){if(d>=c)return{done:!0,value:null};for(var a=fG;d<c&&(a=fJ(b,f,++d))===fG;);if(a!==fG||d===c){var g=fE.apply(null,b.slice(e,d));return e=d,{value:g,done:!1}}return{done:!0,value:null}}}},fL=function(a){for(var b,c=fK(a),d=[];!(b=c.next()).done;)b.value&&d.push(b.value.slice());return d},fM=function(a){if(a.createRange){var b=a.createRange();if(b.getBoundingClientRect){var c=a.createElement("boundtest");c.style.height="123px",c.style.display="block",a.body.appendChild(c),b.selectNode(c);var d=Math.round(b.getBoundingClientRect().height);if(a.body.removeChild(c),123===d)return!0}}return!1},fN=function(a){var b=a.createElement("boundtest");b.style.width="50px",b.style.display="block",b.style.fontSize="12px",b.style.letterSpacing="0px",b.style.wordSpacing="0px",a.body.appendChild(b);var c=a.createRange();b.innerHTML="function"==typeof"".repeat?"&#128104;".repeat(10):"";var d=b.firstChild,e=o(d.data).map(function(a){return p(a)}),f=0,g={},h=e.every(function(a,b){c.setStart(d,f),c.setEnd(d,f+a.length);var e=c.getBoundingClientRect();f+=a.length;var h=e.x>g.x||e.y>g.y;return g=e,0===b||h});return a.body.removeChild(b),h},fO=function(){return void 0!==new Image().crossOrigin},fP=function(){return"string"==typeof new XMLHttpRequest().responseType},fQ=function(a){var b=new Image,c=a.createElement("canvas"),d=c.getContext("2d");if(!d)return!1;b.src="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg'></svg>";try{d.drawImage(b,0,0),c.toDataURL()}catch(e){return!1}return!0},fR=function(a){return 0===a[0]&&255===a[1]&&0===a[2]&&255===a[3]},fS=function(a){var b=a.createElement("canvas"),c=100;b.width=c,b.height=c;var d=b.getContext("2d");if(!d)return Promise.reject(!1);d.fillStyle="rgb(0, 255, 0)",d.fillRect(0,0,c,c);var e=new Image,f=b.toDataURL();e.src=f;var g=fT(c,c,0,0,e);return d.fillStyle="red",d.fillRect(0,0,c,c),fU(g).then(function(b){d.drawImage(b,0,0);var e=d.getImageData(0,0,c,c).data;d.fillStyle="red",d.fillRect(0,0,c,c);var g=a.createElement("div");return g.style.backgroundImage="url("+f+")",g.style.height=c+"px",fR(e)?fU(fT(c,c,0,0,g)):Promise.reject(!1)}).then(function(a){return d.drawImage(a,0,0),fR(d.getImageData(0,0,c,c).data)}).catch(function(){return!1})},fT=function(a,b,c,d,e){var f="http://www.w3.org/2000/svg",g=document.createElementNS(f,"svg"),h=document.createElementNS(f,"foreignObject");return g.setAttributeNS(null,"width",a.toString()),g.setAttributeNS(null,"height",b.toString()),h.setAttributeNS(null,"width","100%"),h.setAttributeNS(null,"height","100%"),h.setAttributeNS(null,"x",c.toString()),h.setAttributeNS(null,"y",d.toString()),h.setAttributeNS(null,"externalResourcesRequired","true"),g.appendChild(h),h.appendChild(e),g},fU=function(a){return new Promise(function(b,c){var d=new Image;d.onload=function(){return b(d)},d.onerror=c,d.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(new XMLSerializer().serializeToString(a))})},fV={get SUPPORT_RANGE_BOUNDS(){var fW=fM(document);return Object.defineProperty(fV,"SUPPORT_RANGE_BOUNDS",{value:fW}),fW},get SUPPORT_WORD_BREAKING(){var fX=fV.SUPPORT_RANGE_BOUNDS&&fN(document);return Object.defineProperty(fV,"SUPPORT_WORD_BREAKING",{value:fX}),fX},get SUPPORT_SVG_DRAWING(){var fY=fQ(document);return Object.defineProperty(fV,"SUPPORT_SVG_DRAWING",{value:fY}),fY},get SUPPORT_FOREIGNOBJECT_DRAWING(){var fZ="function"==typeof Array.from&&"function"==typeof window.fetch?fS(document):Promise.resolve(!1);return Object.defineProperty(fV,"SUPPORT_FOREIGNOBJECT_DRAWING",{value:fZ}),fZ},get SUPPORT_CORS_IMAGES(){var f$=fO();return Object.defineProperty(fV,"SUPPORT_CORS_IMAGES",{value:f$}),f$},get SUPPORT_RESPONSE_TYPE(){var f_=fP();return Object.defineProperty(fV,"SUPPORT_RESPONSE_TYPE",{value:f_}),f_},get SUPPORT_CORS_XHR(){var f0="withCredentials"in new XMLHttpRequest;return Object.defineProperty(fV,"SUPPORT_CORS_XHR",{value:f0}),f0},get SUPPORT_NATIVE_TEXT_SEGMENTATION(){var f1=!!("undefined"!=typeof Intl&&Intl.Segmenter);return Object.defineProperty(fV,"SUPPORT_NATIVE_TEXT_SEGMENTATION",{value:f1}),f1}},f2=function(a,b){this.text=a,this.bounds=b},f3=function(a,b,c,d){var e=f8(b,c),f=[],g=0;return e.forEach(function(b){if(c.textDecorationLine.length||b.trim().length>0){if(fV.SUPPORT_RANGE_BOUNDS){var e=f5(d,g,b.length).getClientRects();if(e.length>1){var h=f6(b),i=0;h.forEach(function(b){f.push(new f2(b,l.fromDOMRectList(a,f5(d,i+g,b.length).getClientRects()))),i+=b.length})}else f.push(new f2(b,l.fromDOMRectList(a,e)))}else{var j=d.splitText(b.length);f.push(new f2(b,f4(a,d))),d=j}}else fV.SUPPORT_RANGE_BOUNDS||(d=d.splitText(b.length));g+=b.length}),f},f4=function(a,b){var c=b.ownerDocument;if(c){var d=c.createElement("html2canvaswrapper");d.appendChild(b.cloneNode(!0));var e=b.parentNode;if(e){e.replaceChild(d,b);var f=m(a,d);return d.firstChild&&e.replaceChild(d.firstChild,d),f}}return l.EMPTY},f5=function(a,b,c){var d=a.ownerDocument;if(!d)throw Error("Node has no owner document");var e=d.createRange();return e.setStart(a,b),e.setEnd(a,b+c),e},f6=function(a){return fV.SUPPORT_NATIVE_TEXT_SEGMENTATION?Array.from(new Intl.Segmenter(void 0,{granularity:"grapheme"}).segment(a)).map(function(a){return a.segment}):fL(a)},f7=function(a,b){return fV.SUPPORT_NATIVE_TEXT_SEGMENTATION?Array.from(new Intl.Segmenter(void 0,{granularity:"word"}).segment(a)).map(function(a){return a.segment}):ga(a,b)},f8=function(a,b){return 0!==b.letterSpacing?f6(a):f7(a,b)},f9=[32,160,4961,65792,65793,4153,4241],ga=function(a,b){for(var c,d=a0(a,{lineBreak:b.lineBreak,wordBreak:"break-word"===b.overflowWrap?"break-word":b.wordBreak}),e=[],f=function(){if(c.value){var a=o(c.value.slice()),b="";a.forEach(function(a){-1===f9.indexOf(a)?b+=p(a):(b.length&&e.push(b),e.push(p(a)),b="")}),b.length&&e.push(b)}};!(c=d.next()).done;)f();return e},gb=function(a,b,c){this.text=gc(b.data,c.textTransform),this.textBounds=f3(a,this.text,c,b)},gc=function(a,b){switch(b){case 1:return a.toLowerCase();case 3:return a.replace(gd,ge);case 2:return a.toUpperCase();default:return a}},gd=/(^|\s|:|-|\(|\))([a-z])/g,ge=function(a,b,c){return a.length>0?b+c.toUpperCase():a},gf=function(a){function b(b,c){var d=a.call(this,b,c)||this;return d.src=c.currentSrc||c.src,d.intrinsicWidth=c.naturalWidth,d.intrinsicHeight=c.naturalHeight,d.context.cache.addImage(d.src),d}return g(b,a),b}(eW),gg=function(a){function b(b,c){var d=a.call(this,b,c)||this;return d.canvas=c,d.intrinsicWidth=c.width,d.intrinsicHeight=c.height,d}return g(b,a),b}(eW),gh=function(a){function b(b,c){var d=a.call(this,b,c)||this,e=new XMLSerializer,f=m(b,c);return c.setAttribute("width",f.width+"px"),c.setAttribute("height",f.height+"px"),d.svg="data:image/svg+xml,"+encodeURIComponent(e.serializeToString(c)),d.intrinsicWidth=c.width.baseVal.value,d.intrinsicHeight=c.height.baseVal.value,d.context.cache.addImage(d.svg),d}return g(b,a),b}(eW),gi=function(a){function b(b,c){var d=a.call(this,b,c)||this;return d.value=c.value,d}return g(b,a),b}(eW),gj=function(a){function b(b,c){var d=a.call(this,b,c)||this;return d.start=c.start,d.reversed="boolean"==typeof c.reversed&& !0===c.reversed,d}return g(b,a),b}(eW),gk=[{type:15,flags:0,unit:"px",number:3}],gl=[{type:16,flags:0,number:50}],gm=function(a){return a.width>a.height?new l(a.left+(a.width-a.height)/2,a.top,a.height,a.height):a.width<a.height?new l(a.left,a.top+(a.height-a.width)/2,a.width,a.width):a},gn=function(a){var b=a.type===gq?Array(a.value.length+1).join("•"):a.value;return 0===b.length?a.placeholder||"":b},go="checkbox",gp="radio",gq="password",gr=function(a){function b(b,c){var d=a.call(this,b,c)||this;switch(d.type=c.type.toLowerCase(),d.checked=c.checked,d.value=gn(c),(d.type===go||d.type===gp)&&(d.styles.backgroundColor=3739148031,d.styles.borderTopColor=d.styles.borderRightColor=d.styles.borderBottomColor=d.styles.borderLeftColor=2779096575,d.styles.borderTopWidth=d.styles.borderRightWidth=d.styles.borderBottomWidth=d.styles.borderLeftWidth=1,d.styles.borderTopStyle=d.styles.borderRightStyle=d.styles.borderBottomStyle=d.styles.borderLeftStyle=1,d.styles.backgroundClip=[0],d.styles.backgroundOrigin=[0],d.bounds=gm(d.bounds)),d.type){case go:d.styles.borderTopRightRadius=d.styles.borderTopLeftRadius=d.styles.borderBottomRightRadius=d.styles.borderBottomLeftRadius=gk;break;case gp:d.styles.borderTopRightRadius=d.styles.borderTopLeftRadius=d.styles.borderBottomRightRadius=d.styles.borderBottomLeftRadius=gl}return d}return g(b,a),b}(eW),gs=function(a){function b(b,c){var d=a.call(this,b,c)||this,e=c.options[c.selectedIndex||0];return d.value=e&&e.text||"",d}return g(b,a),b}(eW),gt=function(a){function b(b,c){var d=a.call(this,b,c)||this;return d.value=c.value,d}return g(b,a),b}(eW),gu=function(a){function b(b,c){var d=a.call(this,b,c)||this;d.src=c.src,d.width=parseInt(c.width,10)||0,d.height=parseInt(c.height,10)||0,d.backgroundColor=d.styles.backgroundColor;try{if(c.contentWindow&&c.contentWindow.document&&c.contentWindow.document.documentElement){d.tree=gy(b,c.contentWindow.document.documentElement);var e=c.contentWindow.document.documentElement?c4(b,getComputedStyle(c.contentWindow.document.documentElement).backgroundColor):c5.TRANSPARENT,f=c.contentWindow.document.body?c4(b,getComputedStyle(c.contentWindow.document.body).backgroundColor):c5.TRANSPARENT;d.backgroundColor=cW(e)?cW(f)?d.styles.backgroundColor:f:e}}catch(g){}return d}return g(b,a),b}(eW),gv=["OL","UL","MENU"],gw=function(a,b,c,d){for(var e=b.firstChild,f=void 0;e;e=f)if(f=e.nextSibling,gB(e)&&e.data.trim().length>0)c.textNodes.push(new gb(a,e,c.styles));else if(gC(e)){if(gS(e)&&e.assignedNodes)e.assignedNodes().forEach(function(b){return gw(a,b,c,d)});else{var g=gx(a,e);!g.styles.isVisible()||(gz(e,g,d)?g.flags|=4:gA(g.styles)&&(g.flags|=2),-1!==gv.indexOf(e.tagName)&&(g.flags|=8),c.elements.push(g),e.slot,e.shadowRoot?gw(a,e.shadowRoot,g,d):gQ(e)||gI(e)||gR(e)||gw(a,e,g,d))}}},gx=function(a,b){return gM(b)?new gf(a,b):gK(b)?new gg(a,b):gI(b)?new gh(a,b):gF(b)?new gi(a,b):gG(b)?new gj(a,b):gH(b)?new gr(a,b):gR(b)?new gs(a,b):gQ(b)?new gt(a,b):gN(b)?new gu(a,b):new eW(a,b)},gy=function(a,b){var c=gx(a,b);return c.flags|=4,gw(a,b,c,c),c},gz=function(a,b,c){return b.styles.isPositionedWithZIndex()||b.styles.opacity<1||b.styles.isTransformed()||gJ(a)&&c.styles.isTransparent()},gA=function(a){return a.isPositioned()||a.isFloating()},gB=function(a){return a.nodeType===Node.TEXT_NODE},gC=function(a){return a.nodeType===Node.ELEMENT_NODE},gD=function(a){return gC(a)&& void 0!==a.style&&!gE(a)},gE=function(a){return"object"==typeof a.className},gF=function(a){return"LI"===a.tagName},gG=function(a){return"OL"===a.tagName},gH=function(a){return"INPUT"===a.tagName},gI=function(a){return"svg"===a.tagName},gJ=function(a){return"BODY"===a.tagName},gK=function(a){return"CANVAS"===a.tagName},gL=function(a){return"VIDEO"===a.tagName},gM=function(a){return"IMG"===a.tagName},gN=function(a){return"IFRAME"===a.tagName},gO=function(a){return"STYLE"===a.tagName},gP=function(a){return"SCRIPT"===a.tagName},gQ=function(a){return"TEXTAREA"===a.tagName},gR=function(a){return"SELECT"===a.tagName},gS=function(a){return"SLOT"===a.tagName},gT=function(a){return a.tagName.indexOf("-")>0},gU=function(){function a(){this.counters={}}return a.prototype.getCounterValue=function(a){var b=this.counters[a];return b&&b.length?b[b.length-1]:1},a.prototype.getCounterValues=function(a){var b;return this.counters[a]||[]},a.prototype.pop=function(a){var b=this;a.forEach(function(a){return b.counters[a].pop()})},a.prototype.parse=function(a){var b=this,c=a.counterIncrement,d=a.counterReset,e=!0;null!==c&&c.forEach(function(a){var c=b.counters[a.counter];c&&0!==a.increment&&(e=!1,c.length||c.push(1),c[Math.max(0,c.length-1)]+=a.increment)});var f=[];return e&&d.forEach(function(a){var c=b.counters[a.counter];f.push(a.counter),c||(c=b.counters[a.counter]=[]),c.push(a.reset)}),f},a}(),gV={integers:[1e3,900,500,400,100,90,50,40,10,9,5,4,1],values:["M","CM","D","CD","C","XC","L","XL","X","IX","V","IV","I"]},gW={integers:[9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],values:["Ք","Փ","Ւ","Ց","Ր","Տ","Վ","Ս","Ռ","Ջ","Պ","Չ","Ո","Շ","Ն","Յ","Մ","Ճ","Ղ","Ձ","Հ","Կ","Ծ","Խ","Լ","Ի","Ժ","Թ","Ը","Է","Զ","Ե","Դ","Գ","Բ","Ա"]},gX={integers:[1e4,9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,400,300,200,100,90,80,70,60,50,40,30,20,19,18,17,16,15,10,9,8,7,6,5,4,3,2,1],values:["י׳","ט׳","ח׳","ז׳","ו׳","ה׳","ד׳","ג׳","ב׳","א׳","ת","ש","ר","ק","צ","פ","ע","ס","נ","מ","ל","כ","יט","יח","יז","טז","טו","י","ט","ח","ז","ו","ה","ד","ג","ב","א"]},gY={integers:[1e4,9e3,8e3,7e3,6e3,5e3,4e3,3e3,2e3,1e3,900,800,700,600,500,400,300,200,100,90,80,70,60,50,40,30,20,10,9,8,7,6,5,4,3,2,1],values:["ჵ","ჰ","ჯ","ჴ","ხ","ჭ","წ","ძ","ც","ჩ","შ","ყ","ღ","ქ","ფ","ჳ","ტ","ს","რ","ჟ","პ","ო","ჲ","ნ","მ","ლ","კ","ი","თ","ჱ","ზ","ვ","ე","დ","გ","ბ","ა"]},gZ=function(a,b,c,d,e,f){return a<b||a>c?ha(a,e,f.length>0):d.integers.reduce(function(b,c,e){for(;a>=c;)a-=c,b+=d.values[e];return b},"")+f},g$=function(a,b,c,d){var e="";do!c&&a--,e=d(a)+e,a/=b;while(a*b>=b);return e},g_=function(a,b,c,d,e){var f=c-b+1;return(a<0?"-":"")+(g$(Math.abs(a),f,d,function(a){return p(Math.floor(a%f)+b)})+e)},g0=function(a,b,c){void 0===c&&(c=". ");var d=b.length;return g$(Math.abs(a),d,!1,function(a){return b[Math.floor(a%d)]})+c},g1=1,g2=2,g3=4,g4=8,g5=function(a,b,c,d,e,f){if(a< -9999||a>9999)return ha(a,4,e.length>0);var g=Math.abs(a),h=e;if(0===g)return b[0]+h;for(var i=0;g>0&&i<=4;i++){var j=g%10;0===j&&eE(f,g1)&&""!==h?h=b[j]+h:j>1||1===j&&0===i||1===j&&1===i&&eE(f,g2)||1===j&&1===i&&eE(f,g3)&&a>100||1===j&&i>1&&eE(f,g4)?h=b[j]+(i>0?c[i-1]:"")+h:1===j&&i>0&&(h=c[i-1]+h),g=Math.floor(g/10)}return(a<0?d:"")+h},g6="十百千萬",g7="拾佰仟萬",g8="マイナス",g9="마이너스",ha=function(a,b,c){var d=c?". ":"",e=c?"、":"",f=c?", ":"",g=c?" ":"";switch(b){case 0:return"•"+g;case 1:return"◦"+g;case 2:return"◾"+g;case 5:var h=g_(a,48,57,!0,d);return h.length<4?"0"+h:h;case 4:return g0(a,"〇一二三四五六七八九",e);case 6:return gZ(a,1,3999,gV,3,d).toLowerCase();case 7:return gZ(a,1,3999,gV,3,d);case 8:return g_(a,945,969,!1,d);case 9:return g_(a,97,122,!1,d);case 10:return g_(a,65,90,!1,d);case 11:return g_(a,1632,1641,!0,d);case 12:case 49:return gZ(a,1,9999,gW,3,d);case 35:return gZ(a,1,9999,gW,3,d).toLowerCase();case 13:return g_(a,2534,2543,!0,d);case 14:case 30:return g_(a,6112,6121,!0,d);case 15:return g0(a,"子丑寅卯辰巳午未申酉戌亥",e);case 16:return g0(a,"甲乙丙丁戊己庚辛壬癸",e);case 17:case 48:return g5(a,"零一二三四五六七八九",g6,"負",e,g2|g3|g4);case 47:return g5(a,"零壹貳參肆伍陸柒捌玖",g7,"負",e,g1|g2|g3|g4);case 42:return g5(a,"零一二三四五六七八九",g6,"负",e,g2|g3|g4);case 41:return g5(a,"零壹贰叁肆伍陆柒捌玖",g7,"负",e,g1|g2|g3|g4);case 26:return g5(a,"〇一二三四五六七八九","十百千万",g8,e,0);case 25:return g5(a,"零壱弐参四伍六七八九","拾百千万",g8,e,g1|g2|g3);case 31:return g5(a,"영일이삼사오육칠팔구","십백천만",g9,f,g1|g2|g3);case 33:return g5(a,"零一二三四五六七八九","十百千萬",g9,f,0);case 32:return g5(a,"零壹貳參四五六七八九","拾百千",g9,f,g1|g2|g3);case 18:return g_(a,2406,2415,!0,d);case 20:return gZ(a,1,19999,gY,3,d);case 21:return g_(a,2790,2799,!0,d);case 22:return g_(a,2662,2671,!0,d);case 22:return gZ(a,1,10999,gX,3,d);case 23:return g0(a,"あいうえおかきくけこさしすせそたちつてとなにぬねのはひふへほまみむめもやゆよらりるれろわゐゑをん");case 24:return g0(a,"いろはにほへとちりぬるをわかよたれそつねならむうゐのおくやまけふこえてあさきゆめみしゑひもせす");case 27:return g_(a,3302,3311,!0,d);case 28:return g0(a,"アイウエオカキクケコサシスセソタチツテトナニヌネノハヒフヘホマミムメモヤユヨラリルレロワヰヱヲン",e);case 29:return g0(a,"イロハニホヘトチリヌルヲワカヨタレソツネナラムウヰノオクヤマケフコエテアサキユメミシヱヒモセス",e);case 34:return g_(a,3792,3801,!0,d);case 37:return g_(a,6160,6169,!0,d);case 38:return g_(a,4160,4169,!0,d);case 39:return g_(a,2918,2927,!0,d);case 40:return g_(a,1776,1785,!0,d);case 43:return g_(a,3046,3055,!0,d);case 44:return g_(a,3174,3183,!0,d);case 45:return g_(a,3664,3673,!0,d);case 46:return g_(a,3872,3881,!0,d);default:return g_(a,48,57,!0,d)}},hb="data-html2canvas-ignore",hc=function(){function a(a,b,c){if(this.context=a,this.options=c,this.scrolledElements=[],this.referenceElement=b,this.counters=new gU,this.quoteDepth=0,!b.ownerDocument)throw Error("Cloned element does not have an owner document");this.documentElement=this.cloneNode(b.ownerDocument.documentElement,!1)}return a.prototype.toIFrame=function(a,b){var c=this,d=he(a,b);if(!d.contentWindow)return Promise.reject("Unable to find iframe window");var e=a.defaultView.pageXOffset,f=a.defaultView.pageYOffset,g=d.contentWindow,h=g.document,k=hh(d).then(function(){return i(c,void 0,void 0,function(){var a,c;return j(this,function(e){switch(e.label){case 0:if(this.scrolledElements.forEach(hm),g&&(g.scrollTo(b.left,b.top),/(iPad|iPhone|iPod)/g.test(navigator.userAgent)&&(g.scrollY!==b.top||g.scrollX!==b.left)&&(this.context.logger.warn("Unable to restore scroll position for cloned document"),this.context.windowBounds=this.context.windowBounds.add(g.scrollX-b.left,g.scrollY-b.top,0,0))),a=this.options.onclone,void 0===(c=this.clonedReferenceElement))return[2,Promise.reject("Error finding the "+this.referenceElement.nodeName+" in the cloned document")];if(!(h.fonts&&h.fonts.ready))return[3,2];return[4,h.fonts.ready];case 1:e.sent(),e.label=2;case 2:if(!/(AppleWebKit)/g.test(navigator.userAgent))return[3,4];return[4,hg(h)];case 3:e.sent(),e.label=4;case 4:if("function"==typeof a)return[2,Promise.resolve().then(function(){return a(h,c)}).then(function(){return d})];return[2,d]}})})});return h.open(),h.write(hk(document.doctype)+"<html></html>"),hl(this.referenceElement.ownerDocument,e,f),h.replaceChild(h.adoptNode(this.documentElement),h.documentElement),h.close(),k},a.prototype.createElementClone=function(a){if(eV(a,2),gK(a))return this.createCanvasClone(a);if(gL(a))return this.createVideoClone(a);if(gO(a))return this.createStyleClone(a);var b=a.cloneNode(!1);return(gM(b)&&(gM(a)&&a.currentSrc&&a.currentSrc!==a.src&&(b.src=a.currentSrc,b.srcset=""),"lazy"===b.loading&&(b.loading="eager")),gT(b))?this.createCustomElementClone(b):b},a.prototype.createCustomElementClone=function(a){var b=document.createElement("html2canvascustomelement");return hj(a.style,b),b},a.prototype.createStyleClone=function(a){try{var b=a.sheet;if(b&&b.cssRules){var c=[].slice.call(b.cssRules,0).reduce(function(a,b){return b&&"string"==typeof b.cssText?a+b.cssText:a},""),d=a.cloneNode(!1);return d.textContent=c,d}}catch(e){if(this.context.logger.error("Unable to access cssRules property",e),"SecurityError"!==e.name)throw e}return a.cloneNode(!1)},a.prototype.createCanvasClone=function(a){if(this.options.inlineImages&&a.ownerDocument){var b,c=a.ownerDocument.createElement("img");try{return c.src=a.toDataURL(),c}catch(d){this.context.logger.info("Unable to inline canvas contents, canvas is tainted",a)}}var e=a.cloneNode(!1);try{e.width=a.width,e.height=a.height;var f=a.getContext("2d"),g=e.getContext("2d");if(g){if(!this.options.allowTaint&&f)g.putImageData(f.getImageData(0,0,a.width,a.height),0,0);else{var h=null!==(b=a.getContext("webgl2"))&& void 0!==b?b:a.getContext("webgl");if(h){var i=h.getContextAttributes();(null==i?void 0:i.preserveDrawingBuffer)=== !1&&this.context.logger.warn("Unable to clone WebGL context as it has preserveDrawingBuffer=false",a)}g.drawImage(a,0,0)}}}catch(j){this.context.logger.info("Unable to clone canvas as it is tainted",a)}return e},a.prototype.createVideoClone=function(a){var b=a.ownerDocument.createElement("canvas");b.width=a.offsetWidth,b.height=a.offsetHeight;var c=b.getContext("2d");try{return c&&(c.drawImage(a,0,0,b.width,b.height),this.options.allowTaint||c.getImageData(0,0,b.width,b.height)),b}catch(d){this.context.logger.info("Unable to clone video as it is tainted",a)}var e=a.ownerDocument.createElement("canvas");return e.width=a.offsetWidth,e.height=a.offsetHeight,e},a.prototype.appendChildNode=function(a,b,c){gC(b)&&(gP(b)||b.hasAttribute(hb)||"function"==typeof this.options.ignoreElements&&this.options.ignoreElements(b))||this.options.copyStyles&&gC(b)&&gO(b)||a.appendChild(this.cloneNode(b,c))},a.prototype.cloneChildNodes=function(a,b,c){for(var d=this,e=a.shadowRoot?a.shadowRoot.firstChild:a.firstChild;e;e=e.nextSibling)if(gC(e)&&gS(e)&&"function"==typeof e.assignedNodes){var f=e.assignedNodes();f.length&&f.forEach(function(a){return d.appendChildNode(b,a,c)})}else this.appendChildNode(b,e,c)},a.prototype.cloneNode=function(a,b){if(gB(a))return document.createTextNode(a.data);if(!a.ownerDocument)return a.cloneNode(!1);var c=a.ownerDocument.defaultView;if(c&&gC(a)&&(gD(a)||gE(a))){var e=this.createElementClone(a);e.style.transitionProperty="none";var f=c.getComputedStyle(a),g=c.getComputedStyle(a,":before"),h=c.getComputedStyle(a,":after");this.referenceElement===a&&gD(e)&&(this.clonedReferenceElement=e),gJ(e)&&hs(e);var i=this.counters.parse(new eR(this.context,f)),j=this.resolvePseudoContent(a,e,g,d.BEFORE);gT(a)&&(b=!0),gL(a)||this.cloneChildNodes(a,e,b),j&&e.insertBefore(j,e.firstChild);var k=this.resolvePseudoContent(a,e,h,d.AFTER);return k&&e.appendChild(k),this.counters.pop(i),(f&&(this.options.copyStyles||gE(a))&&!gN(a)||b)&&hj(f,e),(0!==a.scrollTop||0!==a.scrollLeft)&&this.scrolledElements.push([e,a.scrollLeft,a.scrollTop]),(gQ(a)||gR(a))&&(gQ(e)||gR(e))&&(e.value=a.value),e}return a.cloneNode(!1)},a.prototype.resolvePseudoContent=function(a,b,c,e){var f=this;if(c){var g=c.content,h=b.ownerDocument;if(h&&g&&"none"!==g&&"-moz-alt-content"!==g&&"none"!==c.display){this.counters.parse(new eR(this.context,c));var i=new eQ(this.context,c),j=h.createElement("html2canvaspseudoelement");hj(c,j),i.content.forEach(function(b){if(0===b.type)j.appendChild(h.createTextNode(b.value));else if(22===b.type){var c=h.createElement("img");c.src=b.value,c.style.opacity="1",j.appendChild(c)}else if(18===b.type){if("attr"===b.name){var d=b.values.filter(cy);d.length&&j.appendChild(h.createTextNode(a.getAttribute(d[0].value)||""))}else if("counter"===b.name){var e=b.values.filter(cC),g=e[0],k=e[1];if(g&&cy(g)){var l=f.counters.getCounterValue(g.value),m=k&&cy(k)?d6.parse(f.context,k.value):3;j.appendChild(h.createTextNode(ha(l,m,!1)))}}else if("counters"===b.name){var n=b.values.filter(cC),g=n[0],o=n[1],k=n[2];if(g&&cy(g)){var p=f.counters.getCounterValues(g.value),q=k&&cy(k)?d6.parse(f.context,k.value):3,r=o&&0===o.type?o.value:"",s=p.map(function(a){return ha(a,q,!1)}).join(r);j.appendChild(h.createTextNode(s))}}}else if(20===b.type)switch(b.value){case"open-quote":j.appendChild(h.createTextNode(eK(i.quotes,f.quoteDepth++,!0)));break;case"close-quote":j.appendChild(h.createTextNode(eK(i.quotes,--f.quoteDepth,!1)));break;default:j.appendChild(h.createTextNode(b.value))}}),j.className=hp+" "+hq;var k=e===d.BEFORE?" "+hp:" "+hq;return gE(b)?b.className.baseValue+=k:b.className+=k,j}}},a.destroy=function(a){return!!a.parentNode&&(a.parentNode.removeChild(a),!0)},a}();(fo=d||(d={}))[fo.BEFORE=0]="BEFORE",fo[fo.AFTER=1]="AFTER";var hd,he=function(a,b){var c=a.createElement("iframe");return c.className="html2canvas-container",c.style.visibility="hidden",c.style.position="fixed",c.style.left="-10000px",c.style.top="0px",c.style.border="0",c.width=b.width.toString(),c.height=b.height.toString(),c.scrolling="no",c.setAttribute(hb,"true"),a.body.appendChild(c),c},hf=function(a){return new Promise(function(b){if(a.complete||!a.src){b();return}a.onload=b,a.onerror=b})},hg=function(a){return Promise.all([].slice.call(a.images,0).map(hf))},hh=function(a){return new Promise(function(b,c){var d=a.contentWindow;if(!d)return c("No window assigned for iframe");var e=d.document;d.onload=a.onload=function(){d.onload=a.onload=null;var c=setInterval(function(){e.body.childNodes.length>0&&"complete"===e.readyState&&(clearInterval(c),b(a))},50)}})},hi=["all","d","content"],hj=function(a,b){for(var c=a.length-1;c>=0;c--){var d=a.item(c);-1===hi.indexOf(d)&&b.style.setProperty(d,a.getPropertyValue(d))}return b},hk=function(a){var b="";return a&&(b+="<!DOCTYPE ",a.name&&(b+=a.name),a.internalSubset&&(b+=a.internalSubset),a.publicId&&(b+='"'+a.publicId+'"'),a.systemId&&(b+='"'+a.systemId+'"'),b+=">"),b},hl=function(a,b,c){a&&a.defaultView&&(b!==a.defaultView.pageXOffset||c!==a.defaultView.pageYOffset)&&a.defaultView.scrollTo(b,c)},hm=function(a){var b=a[0],c=a[1],d=a[2];b.scrollLeft=c,b.scrollTop=d},hn=":before",ho=":after",hp="___html2canvas___pseudoelement_before",hq="___html2canvas___pseudoelement_after",hr='{\n    content: "" !important;\n    display: none !important;\n}',hs=function(a){ht(a,"."+hp+hn+hr+"\n         ."+hq+ho+hr)},ht=function(a,b){var c=a.ownerDocument;if(c){var d=c.createElement("style");d.textContent=b,a.appendChild(d)}},hu=function(){function a(){}return a.getOrigin=function(b){var c=a._link;return c?(c.href=b,c.href=c.href,c.protocol+c.hostname+c.port):"about:blank"},a.isSameOrigin=function(b){return a.getOrigin(b)===a._origin},a.setContext=function(b){a._link=b.document.createElement("a"),a._origin=a.getOrigin(b.location.href)},a._origin="about:blank",a}(),hv=function(){function a(a,b){this.context=a,this._options=b,this._cache={}}return a.prototype.addImage=function(a){var b=Promise.resolve();return this.has(a)||(hC(a)||hz(a))&&(this._cache[a]=this.loadImage(a)).catch(function(){}),b},a.prototype.match=function(a){return this._cache[a]},a.prototype.loadImage=function(a){return i(this,void 0,void 0,function(){var b,c,d,e,f=this;return j(this,function(g){switch(g.label){case 0:if(b=hu.isSameOrigin(a),c=!hA(a)&& !0===this._options.useCORS&&fV.SUPPORT_CORS_IMAGES&&!b,d=!hA(a)&&!b&&!hC(a)&&"string"==typeof this._options.proxy&&fV.SUPPORT_CORS_XHR&&!c,!b&& !1===this._options.allowTaint&&!hA(a)&&!hC(a)&&!d&&!c)return[2];if(e=a,!d)return[3,2];return[4,this.proxy(e)];case 1:e=g.sent(),g.label=2;case 2:return this.context.logger.debug("Added image "+a.substring(0,256)),[4,new Promise(function(a,b){var d=new Image;d.onload=function(){return a(d)},d.onerror=b,(hB(e)||c)&&(d.crossOrigin="anonymous"),d.src=e,!0===d.complete&&setTimeout(function(){return a(d)},500),f._options.imageTimeout>0&&setTimeout(function(){return b("Timed out ("+f._options.imageTimeout+"ms) loading image")},f._options.imageTimeout)})];case 3:return[2,g.sent()]}})})},a.prototype.has=function(a){return void 0!==this._cache[a]},a.prototype.keys=function(){return Promise.resolve(Object.keys(this._cache))},a.prototype.proxy=function(a){var b=this,c=this._options.proxy;if(!c)throw Error("No proxy defined");var d=a.substring(0,256);return new Promise(function(e,f){var g=fV.SUPPORT_RESPONSE_TYPE?"blob":"text",h=new XMLHttpRequest;h.onload=function(){if(200===h.status){if("text"===g)e(h.response);else{var a=new FileReader;a.addEventListener("load",function(){return e(a.result)},!1),a.addEventListener("error",function(a){return f(a)},!1),a.readAsDataURL(h.response)}}else f("Failed to proxy resource "+d+" with status code "+h.status)},h.onerror=f;var i=c.indexOf("?")> -1?"&":"?";if(h.open("GET",""+c+i+"url="+encodeURIComponent(a)+"&responseType="+g),"text"!==g&&h instanceof XMLHttpRequest&&(h.responseType=g),b._options.imageTimeout){var j=b._options.imageTimeout;h.timeout=j,h.ontimeout=function(){return f("Timed out ("+j+"ms) proxying "+d)}}h.send()})},a}(),hw=/^data:image\/svg\+xml/i,hx=/^data:image\/.*;base64,/i,hy=/^data:image\/.*/i,hz=function(a){return fV.SUPPORT_SVG_DRAWING||!hD(a)},hA=function(a){return hy.test(a)},hB=function(a){return hx.test(a)},hC=function(a){return"blob"===a.substr(0,4)},hD=function(a){return"svg"===a.substr(-3).toLowerCase()||hw.test(a)},hE=function(){function a(a,b){this.type=0,this.x=a,this.y=b}return a.prototype.add=function(b,c){return new a(this.x+b,this.y+c)},a}(),hF=function(a,b,c){return new hE(a.x+(b.x-a.x)*c,a.y+(b.y-a.y)*c)},hG=function(){function a(a,b,c,d){this.type=1,this.start=a,this.startControl=b,this.endControl=c,this.end=d}return a.prototype.subdivide=function(b,c){var d=hF(this.start,this.startControl,b),e=hF(this.startControl,this.endControl,b),f=hF(this.endControl,this.end,b),g=hF(d,e,b),h=hF(e,f,b),i=hF(g,h,b);return c?new a(this.start,d,g,i):new a(i,h,f,this.end)},a.prototype.add=function(b,c){return new a(this.start.add(b,c),this.startControl.add(b,c),this.endControl.add(b,c),this.end.add(b,c))},a.prototype.reverse=function(){return new a(this.end,this.endControl,this.startControl,this.start)},a}(),hH=function(a){return 1===a.type},hI=function(a){var b=a.styles,c=a.bounds,d=cL(b.borderTopLeftRadius,c.width,c.height),f=d[0],g=d[1],h=cL(b.borderTopRightRadius,c.width,c.height),i=h[0],j=h[1],k=cL(b.borderBottomRightRadius,c.width,c.height),l=k[0],m=k[1],n=cL(b.borderBottomLeftRadius,c.width,c.height),o=n[0],p=n[1],q=[];q.push((f+i)/c.width),q.push((o+l)/c.width),q.push((g+p)/c.height),q.push((j+m)/c.height);var r=Math.max.apply(Math,q);r>1&&(f/=r,g/=r,i/=r,j/=r,l/=r,m/=r,o/=r,p/=r);var s=c.width-i,t=c.height-m,u=c.width-l,v=c.height-p,w=b.borderTopWidth,x=b.borderRightWidth,y=b.borderBottomWidth,z=b.borderLeftWidth,A=cM(b.paddingTop,a.bounds.width),B=cM(b.paddingRight,a.bounds.width),C=cM(b.paddingBottom,a.bounds.width),D=cM(b.paddingLeft,a.bounds.width);this.topLeftBorderDoubleOuterBox=f>0||g>0?hJ(c.left+z/3,c.top+w/3,f-z/3,g-w/3,e.TOP_LEFT):new hE(c.left+z/3,c.top+w/3),this.topRightBorderDoubleOuterBox=f>0||g>0?hJ(c.left+s,c.top+w/3,i-x/3,j-w/3,e.TOP_RIGHT):new hE(c.left+c.width-x/3,c.top+w/3),this.bottomRightBorderDoubleOuterBox=l>0||m>0?hJ(c.left+u,c.top+t,l-x/3,m-y/3,e.BOTTOM_RIGHT):new hE(c.left+c.width-x/3,c.top+c.height-y/3),this.bottomLeftBorderDoubleOuterBox=o>0||p>0?hJ(c.left+z/3,c.top+v,o-z/3,p-y/3,e.BOTTOM_LEFT):new hE(c.left+z/3,c.top+c.height-y/3),this.topLeftBorderDoubleInnerBox=f>0||g>0?hJ(c.left+2*z/3,c.top+2*w/3,f-2*z/3,g-2*w/3,e.TOP_LEFT):new hE(c.left+2*z/3,c.top+2*w/3),this.topRightBorderDoubleInnerBox=f>0||g>0?hJ(c.left+s,c.top+2*w/3,i-2*x/3,j-2*w/3,e.TOP_RIGHT):new hE(c.left+c.width-2*x/3,c.top+2*w/3),this.bottomRightBorderDoubleInnerBox=l>0||m>0?hJ(c.left+u,c.top+t,l-2*x/3,m-2*y/3,e.BOTTOM_RIGHT):new hE(c.left+c.width-2*x/3,c.top+c.height-2*y/3),this.bottomLeftBorderDoubleInnerBox=o>0||p>0?hJ(c.left+2*z/3,c.top+v,o-2*z/3,p-2*y/3,e.BOTTOM_LEFT):new hE(c.left+2*z/3,c.top+c.height-2*y/3),this.topLeftBorderStroke=f>0||g>0?hJ(c.left+z/2,c.top+w/2,f-z/2,g-w/2,e.TOP_LEFT):new hE(c.left+z/2,c.top+w/2),this.topRightBorderStroke=f>0||g>0?hJ(c.left+s,c.top+w/2,i-x/2,j-w/2,e.TOP_RIGHT):new hE(c.left+c.width-x/2,c.top+w/2),this.bottomRightBorderStroke=l>0||m>0?hJ(c.left+u,c.top+t,l-x/2,m-y/2,e.BOTTOM_RIGHT):new hE(c.left+c.width-x/2,c.top+c.height-y/2),this.bottomLeftBorderStroke=o>0||p>0?hJ(c.left+z/2,c.top+v,o-z/2,p-y/2,e.BOTTOM_LEFT):new hE(c.left+z/2,c.top+c.height-y/2),this.topLeftBorderBox=f>0||g>0?hJ(c.left,c.top,f,g,e.TOP_LEFT):new hE(c.left,c.top),this.topRightBorderBox=i>0||j>0?hJ(c.left+s,c.top,i,j,e.TOP_RIGHT):new hE(c.left+c.width,c.top),this.bottomRightBorderBox=l>0||m>0?hJ(c.left+u,c.top+t,l,m,e.BOTTOM_RIGHT):new hE(c.left+c.width,c.top+c.height),this.bottomLeftBorderBox=o>0||p>0?hJ(c.left,c.top+v,o,p,e.BOTTOM_LEFT):new hE(c.left,c.top+c.height),this.topLeftPaddingBox=f>0||g>0?hJ(c.left+z,c.top+w,Math.max(0,f-z),Math.max(0,g-w),e.TOP_LEFT):new hE(c.left+z,c.top+w),this.topRightPaddingBox=i>0||j>0?hJ(c.left+Math.min(s,c.width-x),c.top+w,s>c.width+x?0:Math.max(0,i-x),Math.max(0,j-w),e.TOP_RIGHT):new hE(c.left+c.width-x,c.top+w),this.bottomRightPaddingBox=l>0||m>0?hJ(c.left+Math.min(u,c.width-z),c.top+Math.min(t,c.height-y),Math.max(0,l-x),Math.max(0,m-y),e.BOTTOM_RIGHT):new hE(c.left+c.width-x,c.top+c.height-y),this.bottomLeftPaddingBox=o>0||p>0?hJ(c.left+z,c.top+Math.min(v,c.height-y),Math.max(0,o-z),Math.max(0,p-y),e.BOTTOM_LEFT):new hE(c.left+z,c.top+c.height-y),this.topLeftContentBox=f>0||g>0?hJ(c.left+z+D,c.top+w+A,Math.max(0,f-(z+D)),Math.max(0,g-(w+A)),e.TOP_LEFT):new hE(c.left+z+D,c.top+w+A),this.topRightContentBox=i>0||j>0?hJ(c.left+Math.min(s,c.width+z+D),c.top+w+A,s>c.width+z+D?0:i-z+D,j-(w+A),e.TOP_RIGHT):new hE(c.left+c.width-(x+B),c.top+w+A),this.bottomRightContentBox=l>0||m>0?hJ(c.left+Math.min(u,c.width-(z+D)),c.top+Math.min(t,c.height+w+A),Math.max(0,l-(x+B)),m-(y+C),e.BOTTOM_RIGHT):new hE(c.left+c.width-(x+B),c.top+c.height-(y+C)),this.bottomLeftContentBox=o>0||p>0?hJ(c.left+z+D,c.top+v,Math.max(0,o-(z+D)),p-(y+C),e.BOTTOM_LEFT):new hE(c.left+z+D,c.top+c.height-(y+C))};(hd=e||(e={}))[hd.TOP_LEFT=0]="TOP_LEFT",hd[hd.TOP_RIGHT=1]="TOP_RIGHT",hd[hd.BOTTOM_RIGHT=2]="BOTTOM_RIGHT",hd[hd.BOTTOM_LEFT=3]="BOTTOM_LEFT";var hJ=function(a,b,c,d,f){var g=4*((Math.sqrt(2)-1)/3),h=c*g,i=d*g,j=a+c,k=b+d;switch(f){case e.TOP_LEFT:return new hG(new hE(a,k),new hE(a,k-i),new hE(j-h,b),new hE(j,b));case e.TOP_RIGHT:return new hG(new hE(a,b),new hE(a+h,b),new hE(j,k-i),new hE(j,k));case e.BOTTOM_RIGHT:return new hG(new hE(j,b),new hE(j,b+i),new hE(a+h,k),new hE(a,k));case e.BOTTOM_LEFT:default:return new hG(new hE(j,k),new hE(j-h,k),new hE(a,b+i),new hE(a,b))}},hK=function(a){return[a.topLeftBorderBox,a.topRightBorderBox,a.bottomRightBorderBox,a.bottomLeftBorderBox]},hL=function(a){return[a.topLeftPaddingBox,a.topRightPaddingBox,a.bottomRightPaddingBox,a.bottomLeftPaddingBox]},hM=function(a,b,c){this.offsetX=a,this.offsetY=b,this.matrix=c,this.type=0,this.target=6},hN=function(a,b){this.path=a,this.target=b,this.type=1},hO=function(a){this.opacity=a,this.type=2,this.target=6},hP=function(a){return 1===a.type},hQ=function(a,b){return a.length===b.length&&a.some(function(a,c){return a===b[c]})},hR=function(a){this.element=a,this.inlineLevel=[],this.nonInlineLevel=[],this.negativeZIndex=[],this.zeroOrAutoZIndexOrTransformedOrOpacity=[],this.positiveZIndex=[],this.nonPositionedFloats=[],this.nonPositionedInlineLevel=[]},hS=function(){function a(a,b){if(this.container=a,this.parent=b,this.effects=[],this.curves=new hI(this.container),this.container.styles.opacity<1&&this.effects.push(new hO(this.container.styles.opacity)),null!==this.container.styles.transform){var c=this.container.bounds.left+this.container.styles.transformOrigin[0].number,d=this.container.bounds.top+this.container.styles.transformOrigin[1].number,e=this.container.styles.transform;this.effects.push(new hM(c,d,e))}if(0!==this.container.styles.overflowX){var f=hK(this.curves),g=hL(this.curves);hQ(f,g)?this.effects.push(new hN(f,6)):(this.effects.push(new hN(f,2)),this.effects.push(new hN(g,4)))}}return a.prototype.getEffects=function(a){for(var b=-1===[2,3].indexOf(this.container.styles.position),c=this.parent,d=this.effects.slice(0);c;){var e=c.effects.filter(function(a){return!hP(a)});if(b||0!==c.container.styles.position||!c.parent){if(d.unshift.apply(d,e),b=-1===[2,3].indexOf(c.container.styles.position),0!==c.container.styles.overflowX){var f=hK(c.curves),g=hL(c.curves);hQ(f,g)||d.unshift(new hN(g,6))}}else d.unshift.apply(d,e);c=c.parent}return d.filter(function(b){return eE(b.target,a)})},a}(),hT=function(a,b,c,d){a.container.elements.forEach(function(e){var f=eE(e.flags,4),g=eE(e.flags,2),h=new hS(e,a);eE(e.styles.display,2048)&&d.push(h);var i=eE(e.flags,8)?[]:d;if(f||g){var j=f||e.styles.isPositioned()?c:b,k=new hR(h);if(e.styles.isPositioned()||e.styles.opacity<1||e.styles.isTransformed()){var l=e.styles.zIndex.order;if(l<0){var m=0;j.negativeZIndex.some(function(a,b){if(l>a.element.container.styles.zIndex.order)m=b;else if(m>0)return!0;return!1}),j.negativeZIndex.splice(m,0,k)}else if(l>0){var n=0;j.positiveZIndex.some(function(a,b){if(l>=a.element.container.styles.zIndex.order)n=b+1;else if(n>0)return!0;return!1}),j.positiveZIndex.splice(n,0,k)}else j.zeroOrAutoZIndexOrTransformedOrOpacity.push(k)}else e.styles.isFloating()?j.nonPositionedFloats.push(k):j.nonPositionedInlineLevel.push(k);hT(h,k,f?k:c,i)}else e.styles.isInlineLevel()?b.inlineLevel.push(h):b.nonInlineLevel.push(h),hT(h,b,c,i);eE(e.flags,8)&&hU(e,i)})},hU=function(a,b){for(var c=a instanceof gj?a.start:1,d=a instanceof gj&&a.reversed,e=0;e<b.length;e++){var f=b[e];f.container instanceof gi&&"number"==typeof f.container.value&&0!==f.container.value&&(c=f.container.value),f.listValue=ha(c,f.container.styles.listStyleType,!0),c+=d?-1:1}},hV=function(a){var b=new hS(a,null),c=new hR(b),d=[];return hT(b,c,c,d),hU(b.container,d),c},hW=function(a,b){switch(b){case 0:return h_(a.topLeftBorderBox,a.topLeftPaddingBox,a.topRightBorderBox,a.topRightPaddingBox);case 1:return h_(a.topRightBorderBox,a.topRightPaddingBox,a.bottomRightBorderBox,a.bottomRightPaddingBox);case 2:return h_(a.bottomRightBorderBox,a.bottomRightPaddingBox,a.bottomLeftBorderBox,a.bottomLeftPaddingBox);default:return h_(a.bottomLeftBorderBox,a.bottomLeftPaddingBox,a.topLeftBorderBox,a.topLeftPaddingBox)}},hX=function(a,b){switch(b){case 0:return h_(a.topLeftBorderBox,a.topLeftBorderDoubleOuterBox,a.topRightBorderBox,a.topRightBorderDoubleOuterBox);case 1:return h_(a.topRightBorderBox,a.topRightBorderDoubleOuterBox,a.bottomRightBorderBox,a.bottomRightBorderDoubleOuterBox);case 2:return h_(a.bottomRightBorderBox,a.bottomRightBorderDoubleOuterBox,a.bottomLeftBorderBox,a.bottomLeftBorderDoubleOuterBox);default:return h_(a.bottomLeftBorderBox,a.bottomLeftBorderDoubleOuterBox,a.topLeftBorderBox,a.topLeftBorderDoubleOuterBox)}},hY=function(a,b){switch(b){case 0:return h_(a.topLeftBorderDoubleInnerBox,a.topLeftPaddingBox,a.topRightBorderDoubleInnerBox,a.topRightPaddingBox);case 1:return h_(a.topRightBorderDoubleInnerBox,a.topRightPaddingBox,a.bottomRightBorderDoubleInnerBox,a.bottomRightPaddingBox);case 2:return h_(a.bottomRightBorderDoubleInnerBox,a.bottomRightPaddingBox,a.bottomLeftBorderDoubleInnerBox,a.bottomLeftPaddingBox);default:return h_(a.bottomLeftBorderDoubleInnerBox,a.bottomLeftPaddingBox,a.topLeftBorderDoubleInnerBox,a.topLeftPaddingBox)}},hZ=function(a,b){switch(b){case 0:return h$(a.topLeftBorderStroke,a.topRightBorderStroke);case 1:return h$(a.topRightBorderStroke,a.bottomRightBorderStroke);case 2:return h$(a.bottomRightBorderStroke,a.bottomLeftBorderStroke);default:return h$(a.bottomLeftBorderStroke,a.topLeftBorderStroke)}},h$=function(a,b){var c=[];return hH(a)?c.push(a.subdivide(.5,!1)):c.push(a),hH(b)?c.push(b.subdivide(.5,!0)):c.push(b),c},h_=function(a,b,c,d){var e=[];return hH(a)?e.push(a.subdivide(.5,!1)):e.push(a),hH(c)?e.push(c.subdivide(.5,!0)):e.push(c),hH(d)?e.push(d.subdivide(.5,!0).reverse()):e.push(d),hH(b)?e.push(b.subdivide(.5,!1).reverse()):e.push(b),e},h0=function(a){var b=a.bounds,c=a.styles;return b.add(c.borderLeftWidth,c.borderTopWidth,-(c.borderRightWidth+c.borderLeftWidth),-(c.borderTopWidth+c.borderBottomWidth))},h1=function(a){var b=a.styles,c=a.bounds,d=cM(b.paddingLeft,c.width),e=cM(b.paddingRight,c.width),f=cM(b.paddingTop,c.width),g=cM(b.paddingBottom,c.width);return c.add(d+b.borderLeftWidth,f+b.borderTopWidth,-(b.borderRightWidth+b.borderLeftWidth+d+e),-(b.borderTopWidth+b.borderBottomWidth+f+g))},h2=function(a,b,c){var d,e,f,g,h=(d=h6(a.styles.backgroundOrigin,b),e=a,0===d?e.bounds:2===d?h1(e):h0(e)),i=(f=h6(a.styles.backgroundClip,b),g=a,0===f?g.bounds:2===f?h1(g):h0(g)),j=h5(h6(a.styles.backgroundSize,b),c,h),k=j[0],l=j[1],m=cL(h6(a.styles.backgroundPosition,b),h.width-k,h.height-l),n=h7(h6(a.styles.backgroundRepeat,b),m,j,h,i),o=Math.round(h.left+m[0]),p=Math.round(h.top+m[1]);return[n,o,p,k,l]},h3=function(b){return cy(b)&&b.value===a.AUTO},h4=function(a){return"number"==typeof a},h5=function(b,c,d){var e=c[0],f=c[1],g=c[2],h=b[0],i=b[1];if(!h)return[0,0];if(cG(h)&&i&&cG(i))return[cM(h,d.width),cM(i,d.height)];var j=h4(g);if(cy(h)&&(h.value===a.CONTAIN||h.value===a.COVER))return h4(g)?d.width/d.height<g!=(h.value===a.COVER)?[d.width,d.width/g]:[d.height*g,d.height]:[d.width,d.height];var k=h4(e),l=h4(f),m=k||l;if(h3(h)&&(!i||h3(i))){if(k&&l)return[e,f];if(!j&&!m)return[d.width,d.height];if(m&&j){var n=k?e:f*g,o=l?f:e/g;return[n,o]}var p=k?e:d.width,q=l?f:d.height;return[p,q]}if(j){var r=0,s=0;return cG(h)?r=cM(h,d.width):cG(i)&&(s=cM(i,d.height)),h3(h)?r=s*g:(!i||h3(i))&&(s=r/g),[r,s]}var t=null,u=null;if(cG(h)?t=cM(h,d.width):i&&cG(i)&&(u=cM(i,d.height)),null!==t&&(!i||h3(i))&&(u=k&&l?t/e*f:d.height),null!==u&&h3(h)&&(t=k&&l?u/f*e:d.width),null!==t&&null!==u)return[t,u];throw Error("Unable to calculate background-size for element")},h6=function(a,b){var c=a[b];return void 0===c?a[0]:c},h7=function(a,b,c,d,e){var f=b[0],g=b[1],h=c[0],i=c[1];switch(a){case 2:return[new hE(Math.round(d.left),Math.round(d.top+g)),new hE(Math.round(d.left+d.width),Math.round(d.top+g)),new hE(Math.round(d.left+d.width),Math.round(i+d.top+g)),new hE(Math.round(d.left),Math.round(i+d.top+g))];case 3:return[new hE(Math.round(d.left+f),Math.round(d.top)),new hE(Math.round(d.left+f+h),Math.round(d.top)),new hE(Math.round(d.left+f+h),Math.round(d.height+d.top)),new hE(Math.round(d.left+f),Math.round(d.height+d.top))];case 1:return[new hE(Math.round(d.left+f),Math.round(d.top+g)),new hE(Math.round(d.left+f+h),Math.round(d.top+g)),new hE(Math.round(d.left+f+h),Math.round(d.top+g+i)),new hE(Math.round(d.left+f),Math.round(d.top+g+i))];default:return[new hE(Math.round(e.left),Math.round(e.top)),new hE(Math.round(e.left+e.width),Math.round(e.top)),new hE(Math.round(e.left+e.width),Math.round(e.height+e.top)),new hE(Math.round(e.left),Math.round(e.height+e.top))]}},h8="Hidden Text",h9=function(){function a(a){this._data={},this._document=a}return a.prototype.parseMetrics=function(a,b){var c=this._document.createElement("div"),d=this._document.createElement("img"),e=this._document.createElement("span"),f=this._document.body;c.style.visibility="hidden",c.style.fontFamily=a,c.style.fontSize=b,c.style.margin="0",c.style.padding="0",c.style.whiteSpace="nowrap",f.appendChild(c),d.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",d.width=1,d.height=1,d.style.margin="0",d.style.padding="0",d.style.verticalAlign="baseline",e.style.fontFamily=a,e.style.fontSize=b,e.style.margin="0",e.style.padding="0",e.appendChild(this._document.createTextNode(h8)),c.appendChild(e),c.appendChild(d);var g=d.offsetTop-e.offsetTop+2;c.removeChild(e),c.appendChild(this._document.createTextNode(h8)),c.style.lineHeight="normal",d.style.verticalAlign="super";var h=d.offsetTop-c.offsetTop+2;return f.removeChild(c),{baseline:g,middle:h}},a.prototype.getMetrics=function(a,b){var c=a+" "+b;return void 0===this._data[c]&&(this._data[c]=this.parseMetrics(a,b)),this._data[c]},a}(),ia=function(a,b){this.context=a,this.options=b},ib=function(a){function b(b,c){var d=a.call(this,b,c)||this;return d._activeEffects=[],d.canvas=c.canvas?c.canvas:document.createElement("canvas"),d.ctx=d.canvas.getContext("2d"),c.canvas||(d.canvas.width=Math.floor(c.width*c.scale),d.canvas.height=Math.floor(c.height*c.scale),d.canvas.style.width=c.width+"px",d.canvas.style.height=c.height+"px"),d.fontMetrics=new h9(document),d.ctx.scale(d.options.scale,d.options.scale),d.ctx.translate(-c.x,-c.y),d.ctx.textBaseline="bottom",d._activeEffects=[],d.context.logger.debug("Canvas renderer initialized ("+c.width+"x"+c.height+") with scale "+c.scale),d}return g(b,a),b.prototype.applyEffects=function(a){for(var b=this;this._activeEffects.length;)this.popEffect();a.forEach(function(a){return b.applyEffect(a)})},b.prototype.applyEffect=function(a){var b,c;this.ctx.save(),2===(b=a).type&&(this.ctx.globalAlpha=a.opacity),0===(c=a).type&&(this.ctx.translate(a.offsetX,a.offsetY),this.ctx.transform(a.matrix[0],a.matrix[1],a.matrix[2],a.matrix[3],a.matrix[4],a.matrix[5]),this.ctx.translate(-a.offsetX,-a.offsetY)),hP(a)&&(this.path(a.path),this.ctx.clip()),this._activeEffects.push(a)},b.prototype.popEffect=function(){this._activeEffects.pop(),this.ctx.restore()},b.prototype.renderStack=function(a){return i(this,void 0,void 0,function(){var b;return j(this,function(c){switch(c.label){case 0:if(!(b=a.element.container.styles).isVisible())return[3,2];return[4,this.renderStackContent(a)];case 1:c.sent(),c.label=2;case 2:return[2]}})})},b.prototype.renderNode=function(a){return i(this,void 0,void 0,function(){return j(this,function(b){switch(b.label){case 0:if(eE(a.container.flags,16),!a.container.styles.isVisible())return[3,3];return[4,this.renderNodeBackgroundAndBorders(a)];case 1:return b.sent(),[4,this.renderNodeContent(a)];case 2:b.sent(),b.label=3;case 3:return[2]}})})},b.prototype.renderTextWithLetterSpacing=function(a,b,c){var d=this;0===b?this.ctx.fillText(a.text,a.bounds.left,a.bounds.top+c):f6(a.text).reduce(function(b,e){return d.ctx.fillText(e,b,a.bounds.top+c),b+d.ctx.measureText(e).width},a.bounds.left)},b.prototype.createFontStyle=function(a){var b=a.fontVariant.filter(function(a){return"normal"===a||"small-caps"===a}).join(""),c=ih(a.fontFamily).join(", "),d=cw(a.fontSize)?""+a.fontSize.number+a.fontSize.unit:a.fontSize.number+"px";return[[a.fontStyle,b,a.fontWeight,d,c].join(" "),c,d]},b.prototype.renderTextNode=function(a,b){return i(this,void 0,void 0,function(){var c,d,e,f,g,h,i,k,l=this;return j(this,function(j){return d=(c=this.createFontStyle(b))[0],e=c[1],f=c[2],this.ctx.font=d,this.ctx.direction=1===b.direction?"rtl":"ltr",this.ctx.textAlign="left",this.ctx.textBaseline="alphabetic",h=(g=this.fontMetrics.getMetrics(e,f)).baseline,i=g.middle,k=b.paintOrder,a.textBounds.forEach(function(a){k.forEach(function(c){switch(c){case 0:l.ctx.fillStyle=cX(b.color),l.renderTextWithLetterSpacing(a,b.letterSpacing,h);var d=b.textShadow;d.length&&a.text.trim().length&&(d.slice(0).reverse().forEach(function(c){l.ctx.shadowColor=cX(c.color),l.ctx.shadowOffsetX=c.offsetX.number*l.options.scale,l.ctx.shadowOffsetY=c.offsetY.number*l.options.scale,l.ctx.shadowBlur=c.blur.number,l.renderTextWithLetterSpacing(a,b.letterSpacing,h)}),l.ctx.shadowColor="",l.ctx.shadowOffsetX=0,l.ctx.shadowOffsetY=0,l.ctx.shadowBlur=0),b.textDecorationLine.length&&(l.ctx.fillStyle=cX(b.textDecorationColor||b.color),b.textDecorationLine.forEach(function(b){switch(b){case 1:l.ctx.fillRect(a.bounds.left,Math.round(a.bounds.top+h),a.bounds.width,1);break;case 2:l.ctx.fillRect(a.bounds.left,Math.round(a.bounds.top),a.bounds.width,1);break;case 3:l.ctx.fillRect(a.bounds.left,Math.ceil(a.bounds.top+i),a.bounds.width,1)}}));break;case 1:b.webkitTextStrokeWidth&&a.text.trim().length&&(l.ctx.strokeStyle=cX(b.webkitTextStrokeColor),l.ctx.lineWidth=b.webkitTextStrokeWidth,l.ctx.lineJoin=window.chrome?"miter":"round",l.ctx.strokeText(a.text,a.bounds.left,a.bounds.top+h)),l.ctx.strokeStyle="",l.ctx.lineWidth=0,l.ctx.lineJoin="miter"}})}),[2]})})},b.prototype.renderReplacedElement=function(a,b,c){if(c&&a.intrinsicWidth>0&&a.intrinsicHeight>0){var d=h1(a),e=hL(b);this.path(e),this.ctx.save(),this.ctx.clip(),this.ctx.drawImage(c,0,0,a.intrinsicWidth,a.intrinsicHeight,d.left,d.top,d.width,d.height),this.ctx.restore()}},b.prototype.renderNodeContent=function(a){return i(this,void 0,void 0,function(){var c,d,e,f,g,h,i,k,m,n,o,p,q,r,s,t,u,v,w;return j(this,function(j){switch(j.label){case 0:this.applyEffects(a.getEffects(4)),c=a.container,d=a.curves,e=c.styles,f=0,g=c.textNodes,j.label=1;case 1:if(!(f<g.length))return[3,4];return h=g[f],[4,this.renderTextNode(h,e)];case 2:j.sent(),j.label=3;case 3:return f++,[3,1];case 4:if(!(c instanceof gf))return[3,8];j.label=5;case 5:return j.trys.push([5,7,,8]),[4,this.context.cache.match(c.src)];case 6:return t=j.sent(),this.renderReplacedElement(c,d,t),[3,8];case 7:return j.sent(),this.context.logger.error("Error loading image "+c.src),[3,8];case 8:if(c instanceof gg&&this.renderReplacedElement(c,d,c.canvas),!(c instanceof gh))return[3,12];j.label=9;case 9:return j.trys.push([9,11,,12]),[4,this.context.cache.match(c.svg)];case 10:return t=j.sent(),this.renderReplacedElement(c,d,t),[3,12];case 11:return j.sent(),this.context.logger.error("Error loading svg "+c.svg.substring(0,255)),[3,12];case 12:if(!(c instanceof gu&&c.tree))return[3,14];return[4,(i=new b(this.context,{scale:this.options.scale,backgroundColor:c.backgroundColor,x:0,y:0,width:c.width,height:c.height})).render(c.tree)];case 13:k=j.sent(),c.width&&c.height&&this.ctx.drawImage(k,0,0,c.width,c.height,c.bounds.left,c.bounds.top,c.bounds.width,c.bounds.height),j.label=14;case 14:if(c instanceof gr&&(m=Math.min(c.bounds.width,c.bounds.height),c.type===go?c.checked&&(this.ctx.save(),this.path([new hE(c.bounds.left+.39363*m,c.bounds.top+.79*m),new hE(c.bounds.left+.16*m,c.bounds.top+.5549*m),new hE(c.bounds.left+.27347*m,c.bounds.top+.44071*m),new hE(c.bounds.left+.39694*m,c.bounds.top+.5649*m),new hE(c.bounds.left+.72983*m,c.bounds.top+.23*m),new hE(c.bounds.left+.84*m,c.bounds.top+.34085*m),new hE(c.bounds.left+.39363*m,c.bounds.top+.79*m)]),this.ctx.fillStyle=cX(707406591),this.ctx.fill(),this.ctx.restore()):c.type===gp&&c.checked&&(this.ctx.save(),this.ctx.beginPath(),this.ctx.arc(c.bounds.left+m/2,c.bounds.top+m/2,m/4,0,2*Math.PI,!0),this.ctx.fillStyle=cX(707406591),this.ctx.fill(),this.ctx.restore())),ic(c)&&c.value.length){switch(v=(n=this.createFontStyle(e))[0],o=n[1],p=this.fontMetrics.getMetrics(v,o).baseline,this.ctx.font=v,this.ctx.fillStyle=cX(e.color),this.ctx.textBaseline="alphabetic",this.ctx.textAlign=ie(c.styles.textAlign),w=h1(c),q=0,c.styles.textAlign){case 1:q+=w.width/2;break;case 2:q+=w.width}r=w.add(q,0,0,-w.height/2+1),this.ctx.save(),this.path([new hE(w.left,w.top),new hE(w.left+w.width,w.top),new hE(w.left+w.width,w.top+w.height),new hE(w.left,w.top+w.height)]),this.ctx.clip(),this.renderTextWithLetterSpacing(new f2(c.value,r),e.letterSpacing,p),this.ctx.restore(),this.ctx.textBaseline="alphabetic",this.ctx.textAlign="left"}if(!eE(c.styles.display,2048))return[3,20];if(!(null!==c.styles.listStyleImage))return[3,19];if(0!==(s=c.styles.listStyleImage).type)return[3,18];t=void 0,u=s.url,j.label=15;case 15:return j.trys.push([15,17,,18]),[4,this.context.cache.match(u)];case 16:return t=j.sent(),this.ctx.drawImage(t,c.bounds.left-(t.width+10),c.bounds.top),[3,18];case 17:return j.sent(),this.context.logger.error("Error loading list-style-image "+u),[3,18];case 18:return[3,20];case 19:a.listValue&& -1!==c.styles.listStyleType&&(v=this.createFontStyle(e)[0],this.ctx.font=v,this.ctx.fillStyle=cX(e.color),this.ctx.textBaseline="middle",this.ctx.textAlign="right",w=new l(c.bounds.left,c.bounds.top+cM(c.styles.paddingTop,c.bounds.width),c.bounds.width,d3(e.lineHeight,e.fontSize.number)/2+1),this.renderTextWithLetterSpacing(new f2(a.listValue,w),e.letterSpacing,d3(e.lineHeight,e.fontSize.number)/2+2),this.ctx.textBaseline="bottom",this.ctx.textAlign="left"),j.label=20;case 20:return[2]}})})},b.prototype.renderStackContent=function(a){return i(this,void 0,void 0,function(){var b,c,d,e,f,g,h,i,k,l,m,n,o,p,q;return j(this,function(j){switch(j.label){case 0:return eE(a.element.container.flags,16),[4,this.renderNodeBackgroundAndBorders(a.element)];case 1:j.sent(),b=0,c=a.negativeZIndex,j.label=2;case 2:if(!(b<c.length))return[3,5];return q=c[b],[4,this.renderStack(q)];case 3:j.sent(),j.label=4;case 4:return b++,[3,2];case 5:return[4,this.renderNodeContent(a.element)];case 6:j.sent(),d=0,e=a.nonInlineLevel,j.label=7;case 7:if(!(d<e.length))return[3,10];return q=e[d],[4,this.renderNode(q)];case 8:j.sent(),j.label=9;case 9:return d++,[3,7];case 10:f=0,g=a.nonPositionedFloats,j.label=11;case 11:if(!(f<g.length))return[3,14];return q=g[f],[4,this.renderStack(q)];case 12:j.sent(),j.label=13;case 13:return f++,[3,11];case 14:h=0,i=a.nonPositionedInlineLevel,j.label=15;case 15:if(!(h<i.length))return[3,18];return q=i[h],[4,this.renderStack(q)];case 16:j.sent(),j.label=17;case 17:return h++,[3,15];case 18:k=0,l=a.inlineLevel,j.label=19;case 19:if(!(k<l.length))return[3,22];return q=l[k],[4,this.renderNode(q)];case 20:j.sent(),j.label=21;case 21:return k++,[3,19];case 22:m=0,n=a.zeroOrAutoZIndexOrTransformedOrOpacity,j.label=23;case 23:if(!(m<n.length))return[3,26];return q=n[m],[4,this.renderStack(q)];case 24:j.sent(),j.label=25;case 25:return m++,[3,23];case 26:o=0,p=a.positiveZIndex,j.label=27;case 27:if(!(o<p.length))return[3,30];return q=p[o],[4,this.renderStack(q)];case 28:j.sent(),j.label=29;case 29:return o++,[3,27];case 30:return[2]}})})},b.prototype.mask=function(a){this.ctx.beginPath(),this.ctx.moveTo(0,0),this.ctx.lineTo(this.canvas.width,0),this.ctx.lineTo(this.canvas.width,this.canvas.height),this.ctx.lineTo(0,this.canvas.height),this.ctx.lineTo(0,0),this.formatPath(a.slice(0).reverse()),this.ctx.closePath()},b.prototype.path=function(a){this.ctx.beginPath(),this.formatPath(a),this.ctx.closePath()},b.prototype.formatPath=function(a){var b=this;a.forEach(function(a,c){var d=hH(a)?a.start:a;0===c?b.ctx.moveTo(d.x,d.y):b.ctx.lineTo(d.x,d.y),hH(a)&&b.ctx.bezierCurveTo(a.startControl.x,a.startControl.y,a.endControl.x,a.endControl.y,a.end.x,a.end.y)})},b.prototype.renderRepeat=function(a,b,c,d){this.path(a),this.ctx.fillStyle=b,this.ctx.translate(c,d),this.ctx.fill(),this.ctx.translate(-c,-d)},b.prototype.resizeImage=function(a,b,c){if(a.width===b&&a.height===c)return a;var d,e=(null!==(d=this.canvas.ownerDocument)&& void 0!==d?d:document).createElement("canvas");return e.width=Math.max(1,b),e.height=Math.max(1,c),e.getContext("2d").drawImage(a,0,0,a.width,a.height,0,0,b,c),e},b.prototype.renderBackgroundImage=function(a){return i(this,void 0,void 0,function(){var b,c,d,e,f,g;return j(this,function(h){switch(h.label){case 0:b=a.styles.backgroundImage.length-1,c=function(c){var e,f,g,h,i,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J;return j(this,function(j){switch(j.label){case 0:if(0!==c.type)return[3,5];e=void 0,f=c.url,j.label=1;case 1:return j.trys.push([1,3,,4]),[4,d.context.cache.match(f)];case 2:return e=j.sent(),[3,4];case 3:return j.sent(),d.context.logger.error("Error loading background-image "+f),[3,4];case 4:return e&&(u=(g=h2(a,b,[e.width,e.height,e.width/e.height]))[0],A=g[1],B=g[2],x=g[3],y=g[4],s=d.ctx.createPattern(d.resizeImage(e,x,y),"repeat"),d.renderRepeat(u,s,A,B)),[3,6];case 5:var K,L;1===(K=c).type?(u=(h=h2(a,b,[null,null,null]))[0],A=h[1],B=h[2],x=h[3],y=h[4],k=(i=db(c.angle,x,y))[0],l=i[1],m=i[2],n=i[3],o=i[4],(p=document.createElement("canvas")).width=x,p.height=y,r=(q=p.getContext("2d")).createLinearGradient(l,n,m,o),c9(c.stops,k).forEach(function(a){return r.addColorStop(a.stop,cX(a.color))}),q.fillStyle=r,q.fillRect(0,0,x,y),x>0&&y>0&&(s=d.ctx.createPattern(p,"repeat"),d.renderRepeat(u,s,A,B))):2===(L=c).type&&(u=(t=h2(a,b,[null,null,null]))[0],v=t[1],w=t[2],x=t[3],y=t[4],z=0===c.position.length?[cJ]:c.position,A=cM(z[0],x),B=cM(z[z.length-1],y),D=(C=de(c,A,B,x,y))[0],E=C[1],D>0&&E>0&&(F=d.ctx.createRadialGradient(v+A,w+B,0,v+A,w+B,D),c9(c.stops,2*D).forEach(function(a){return F.addColorStop(a.stop,cX(a.color))}),d.path(u),d.ctx.fillStyle=F,D!==E?(G=a.bounds.left+.5*a.bounds.width,H=a.bounds.top+.5*a.bounds.height,I=E/D,J=1/I,d.ctx.save(),d.ctx.translate(G,H),d.ctx.transform(1,0,0,I,0,0),d.ctx.translate(-G,-H),d.ctx.fillRect(v,J*(w-H)+H,x,y*J),d.ctx.restore()):d.ctx.fill())),j.label=6;case 6:return b--,[2]}})},d=this,e=0,f=a.styles.backgroundImage.slice(0).reverse(),h.label=1;case 1:if(!(e<f.length))return[3,4];return[5,c(g=f[e])];case 2:h.sent(),h.label=3;case 3:return e++,[3,1];case 4:return[2]}})})},b.prototype.renderSolidBorder=function(a,b,c){return i(this,void 0,void 0,function(){return j(this,function(d){return this.path(hW(c,b)),this.ctx.fillStyle=cX(a),this.ctx.fill(),[2]})})},b.prototype.renderDoubleBorder=function(a,b,c,d){return i(this,void 0,void 0,function(){var e,f;return j(this,function(g){switch(g.label){case 0:if(!(b<3))return[3,2];return[4,this.renderSolidBorder(a,c,d)];case 1:return g.sent(),[2];case 2:return e=hX(d,c),this.path(e),this.ctx.fillStyle=cX(a),this.ctx.fill(),f=hY(d,c),this.path(f),this.ctx.fill(),[2]}})})},b.prototype.renderNodeBackgroundAndBorders=function(a){return i(this,void 0,void 0,function(){var b,c,d,e,f,g,h,i,k=this;return j(this,function(j){switch(j.label){case 0:if(this.applyEffects(a.getEffects(2)),c=!cW((b=a.container.styles).backgroundColor)||b.backgroundImage.length,d=[{style:b.borderTopStyle,color:b.borderTopColor,width:b.borderTopWidth},{style:b.borderRightStyle,color:b.borderRightColor,width:b.borderRightWidth},{style:b.borderBottomStyle,color:b.borderBottomColor,width:b.borderBottomWidth},{style:b.borderLeftStyle,color:b.borderLeftColor,width:b.borderLeftWidth}],e=id(h6(b.backgroundClip,0),a.curves),!(c||b.boxShadow.length))return[3,2];return this.ctx.save(),this.path(e),this.ctx.clip(),cW(b.backgroundColor)||(this.ctx.fillStyle=cX(b.backgroundColor),this.ctx.fill()),[4,this.renderBackgroundImage(a.container)];case 1:j.sent(),this.ctx.restore(),b.boxShadow.slice(0).reverse().forEach(function(b){k.ctx.save();var c,d,e,f,g,h=hK(a.curves),i=b.inset?0:1e4,j=(c=h,d=-i+(b.inset?1:-1)*b.spread.number,e=(b.inset?1:-1)*b.spread.number,f=b.spread.number*(b.inset?-2:2),g=b.spread.number*(b.inset?-2:2),c.map(function(a,b){switch(b){case 0:return a.add(d,e);case 1:return a.add(d+f,e);case 2:return a.add(d+f,e+g);case 3:return a.add(d,e+g)}return a}));b.inset?(k.path(h),k.ctx.clip(),k.mask(j)):(k.mask(h),k.ctx.clip(),k.path(j)),k.ctx.shadowOffsetX=b.offsetX.number+i,k.ctx.shadowOffsetY=b.offsetY.number,k.ctx.shadowColor=cX(b.color),k.ctx.shadowBlur=b.blur.number,k.ctx.fillStyle=b.inset?cX(b.color):"rgba(0,0,0,1)",k.ctx.fill(),k.ctx.restore()}),j.label=2;case 2:f=0,g=0,h=d,j.label=3;case 3:if(!(g<h.length))return[3,13];if(!(0!==(i=h[g]).style&&!cW(i.color)&&i.width>0))return[3,11];if(2!==i.style)return[3,5];return[4,this.renderDashedDottedBorder(i.color,i.width,f,a.curves,2)];case 4:case 6:case 8:return j.sent(),[3,11];case 5:if(3!==i.style)return[3,7];return[4,this.renderDashedDottedBorder(i.color,i.width,f,a.curves,3)];case 7:if(4!==i.style)return[3,9];return[4,this.renderDoubleBorder(i.color,i.width,f,a.curves)];case 9:return[4,this.renderSolidBorder(i.color,f,a.curves)];case 10:j.sent(),j.label=11;case 11:f++,j.label=12;case 12:return g++,[3,3];case 13:return[2]}})})},b.prototype.renderDashedDottedBorder=function(a,b,c,d,e){return i(this,void 0,void 0,function(){var f,g,h,i,k,l,m,n,o,p,q,r,s,t,u,v;return j(this,function(j){return this.ctx.save(),f=hZ(d,c),g=hW(d,c),2===e&&(this.path(g),this.ctx.clip()),hH(g[0])?(h=g[0].start.x,i=g[0].start.y):(h=g[0].x,i=g[0].y),hH(g[1])?(k=g[1].end.x,l=g[1].end.y):(k=g[1].x,l=g[1].y),m=0===c||2===c?Math.abs(h-k):Math.abs(i-l),this.ctx.beginPath(),3===e?this.formatPath(f):this.formatPath(g.slice(0,2)),n=b<3?3*b:2*b,o=b<3?2*b:b,3===e&&(n=b,o=b),p=!0,m<=2*n?p=!1:m<=2*n+o?(q=m/(2*n+o),n*=q,o*=q):(r=Math.floor((m+o)/(n+o)),s=(m-r*n)/(r-1),t=(m-(r+1)*n)/r,o=t<=0||Math.abs(o-s)<Math.abs(o-t)?s:t),p&&(3===e?this.ctx.setLineDash([0,n+o]):this.ctx.setLineDash([n,o])),3===e?(this.ctx.lineCap="round",this.ctx.lineWidth=b):this.ctx.lineWidth=2*b+1.1,this.ctx.strokeStyle=cX(a),this.ctx.stroke(),this.ctx.setLineDash([]),2===e&&(hH(g[0])&&(u=g[3],v=g[0],this.ctx.beginPath(),this.formatPath([new hE(u.end.x,u.end.y),new hE(v.start.x,v.start.y)]),this.ctx.stroke()),hH(g[1])&&(u=g[1],v=g[2],this.ctx.beginPath(),this.formatPath([new hE(u.end.x,u.end.y),new hE(v.start.x,v.start.y)]),this.ctx.stroke())),this.ctx.restore(),[2]})})},b.prototype.render=function(a){return i(this,void 0,void 0,function(){var b;return j(this,function(c){switch(c.label){case 0:return this.options.backgroundColor&&(this.ctx.fillStyle=cX(this.options.backgroundColor),this.ctx.fillRect(this.options.x,this.options.y,this.options.width,this.options.height)),b=hV(a),[4,this.renderStack(b)];case 1:return c.sent(),this.applyEffects([]),[2,this.canvas]}})})},b}(ia),ic=function(a){return a instanceof gt||a instanceof gs||a instanceof gr&&a.type!==gp&&a.type!==go},id=function(a,b){switch(a){case 0:return hK(b);case 2:var c;return[(c=b).topLeftContentBox,c.topRightContentBox,c.bottomRightContentBox,c.bottomLeftContentBox];default:return hL(b)}},ie=function(a){switch(a){case 1:return"center";case 2:return"right";default:return"left"}},ig=["-apple-system","system-ui"],ih=function(a){return/iPhone OS 15_(0|1)/.test(window.navigator.userAgent)?a.filter(function(a){return -1===ig.indexOf(a)}):a},ii=function(a){function b(b,c){var d=a.call(this,b,c)||this;return d.canvas=c.canvas?c.canvas:document.createElement("canvas"),d.ctx=d.canvas.getContext("2d"),d.options=c,d.canvas.width=Math.floor(c.width*c.scale),d.canvas.height=Math.floor(c.height*c.scale),d.canvas.style.width=c.width+"px",d.canvas.style.height=c.height+"px",d.ctx.scale(d.options.scale,d.options.scale),d.ctx.translate(-c.x,-c.y),d.context.logger.debug("EXPERIMENTAL ForeignObject renderer initialized ("+c.width+"x"+c.height+" at "+c.x+","+c.y+") with scale "+c.scale),d}return g(b,a),b.prototype.render=function(a){return i(this,void 0,void 0,function(){var b,c;return j(this,function(d){switch(d.label){case 0:return b=fT(this.options.width*this.options.scale,this.options.height*this.options.scale,this.options.scale,this.options.scale,a),[4,ij(b)];case 1:return c=d.sent(),this.options.backgroundColor&&(this.ctx.fillStyle=cX(this.options.backgroundColor),this.ctx.fillRect(0,0,this.options.width*this.options.scale,this.options.height*this.options.scale)),this.ctx.drawImage(c,-this.options.x*this.options.scale,-this.options.y*this.options.scale),[2,this.canvas]}})})},b}(ia),ij=function(a){return new Promise(function(b,c){var d=new Image;d.onload=function(){b(d)},d.onerror=c,d.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(new XMLSerializer().serializeToString(a))})},ik=function(){function a(a){var b=a.id,c=a.enabled;this.id=b,this.enabled=c,this.start=Date.now()}return a.prototype.debug=function(){for(var a=[],b=0;b<arguments.length;b++)a[b]=arguments[b];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.debug?console.debug.apply(console,k([this.id,this.getTime()+"ms"],a)):this.info.apply(this,a))},a.prototype.getTime=function(){return Date.now()-this.start},a.prototype.info=function(){for(var a=[],b=0;b<arguments.length;b++)a[b]=arguments[b];this.enabled&&"undefined"!=typeof window&&window.console&&"function"==typeof console.info&&console.info.apply(console,k([this.id,this.getTime()+"ms"],a))},a.prototype.warn=function(){for(var a=[],b=0;b<arguments.length;b++)a[b]=arguments[b];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.warn?console.warn.apply(console,k([this.id,this.getTime()+"ms"],a)):this.info.apply(this,a))},a.prototype.error=function(){for(var a=[],b=0;b<arguments.length;b++)a[b]=arguments[b];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.error?console.error.apply(console,k([this.id,this.getTime()+"ms"],a)):this.info.apply(this,a))},a.instances={},a}(),il=function(){function a(b,c){var d;this.windowBounds=c,this.instanceName="#"+a.instanceCount++,this.logger=new ik({id:this.instanceName,enabled:b.logging}),this.cache=null!==(d=b.cache)&& void 0!==d?d:new hv(this,b)}return a.instanceCount=1,a}(),im=function(a,b){return void 0===b&&(b={}),io(a,b)};"undefined"!=typeof window&&hu.setContext(window);var io=function(a,b){return i(void 0,void 0,void 0,function(){var c,d,e,f,g,i,k,o,p,q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T;return j(this,function(j){switch(j.label){case 0:if(!a||"object"!=typeof a)return[2,Promise.reject("Invalid element provided as first argument")];if(!(c=a.ownerDocument))throw Error("Element is not attached to a Document");if(!(d=c.defaultView))throw Error("Document is not attached to a Window");if(e={allowTaint:null!==(D=b.allowTaint)&& void 0!==D&&D,imageTimeout:null!==(E=b.imageTimeout)&& void 0!==E?E:15e3,proxy:b.proxy,useCORS:null!==(F=b.useCORS)&& void 0!==F&&F},f=h({logging:null===(G=b.logging)|| void 0===G||G,cache:b.cache},e),g={windowWidth:null!==(H=b.windowWidth)&& void 0!==H?H:d.innerWidth,windowHeight:null!==(I=b.windowHeight)&& void 0!==I?I:d.innerHeight,scrollX:null!==(J=b.scrollX)&& void 0!==J?J:d.pageXOffset,scrollY:null!==(K=b.scrollY)&& void 0!==K?K:d.pageYOffset},i=new l(g.scrollX,g.scrollY,g.windowWidth,g.windowHeight),k=new il(f,i),o=null!==(L=b.foreignObjectRendering)&& void 0!==L&&L,p={allowTaint:null!==(M=b.allowTaint)&& void 0!==M&&M,onclone:b.onclone,ignoreElements:b.ignoreElements,inlineImages:o,copyStyles:o},k.logger.debug("Starting document clone with size "+i.width+"x"+i.height+" scrolled to "+ -i.left+","+ -i.top),q=new hc(k,a,p),r=q.clonedReferenceElement,!r)return[2,Promise.reject("Unable to find element in cloned iframe")];return[4,q.toIFrame(c,i)];case 1:var U;if(s=j.sent(),u=(t=gJ(r)||"HTML"===(U=r).tagName?n(r.ownerDocument):m(k,r)).width,v=t.height,w=t.left,x=t.top,y=ip(k,r,b.backgroundColor),z={canvas:b.canvas,backgroundColor:y,scale:null!==(O=null!==(N=b.scale)&& void 0!==N?N:d.devicePixelRatio)&& void 0!==O?O:1,x:(null!==(P=b.x)&& void 0!==P?P:0)+w,y:(null!==(Q=b.y)&& void 0!==Q?Q:0)+x,width:null!==(R=b.width)&& void 0!==R?R:Math.ceil(u),height:null!==(S=b.height)&& void 0!==S?S:Math.ceil(v)},!o)return[3,3];return k.logger.debug("Document cloned, using foreign object rendering"),[4,(C=new ii(k,z)).render(r)];case 2:return A=j.sent(),[3,5];case 3:return k.logger.debug("Document cloned, element located at "+w+","+x+" with size "+u+"x"+v+" using computed rendering"),k.logger.debug("Starting DOM parsing"),B=gy(k,r),y===B.styles.backgroundColor&&(B.styles.backgroundColor=c5.TRANSPARENT),k.logger.debug("Starting renderer for element at "+z.x+","+z.y+" with size "+z.width+"x"+z.height),[4,(C=new ib(k,z)).render(B)];case 4:A=j.sent(),j.label=5;case 5:return(null===(T=b.removeContainer)|| void 0===T||T)&&!hc.destroy(s)&&k.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore"),k.logger.debug("Finished rendering"),[2,A]}})})},ip=function(a,b,c){var d=b.ownerDocument,e=d.documentElement?c4(a,getComputedStyle(d.documentElement).backgroundColor):c5.TRANSPARENT,f=d.body?c4(a,getComputedStyle(d.body).backgroundColor):c5.TRANSPARENT,g="string"==typeof c?c4(a,c):null===c?c5.TRANSPARENT:4294967295;return b===d.documentElement?cW(e)?cW(f)?g:f:e:g};return im})}}])
//# sourceMappingURL=ad7f724d.af486d530dead9c2.js.map