(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[599],{55201:function(A){/*!
 * html2canvas 1.4.1 <https://html2canvas.hertzen.com>
 * Copyright (c) 2022 Niklas von Hertzen <https://hertzen.com>
 * Released under MIT License
 */A.exports=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,e,t,r,n,B,s,o,i,a,c,g,Q,l,w,u,C,F,U,d,h,p,f,H,extendStatics=function(A,e){return(extendStatics=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(A,e){A.__proto__=e}||function(A,e){for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&(A[t]=e[t])})(A,e)};function __extends(A,e){if("function"!=typeof e&&null!==e)throw TypeError("Class extends value "+String(e)+" is not a constructor or null");function __(){this.constructor=A}extendStatics(A,e),A.prototype=null===e?Object.create(e):(__.prototype=e.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function(A){for(var e,t=1,r=arguments.length;t<r;t++)for(var n in e=arguments[t])Object.prototype.hasOwnProperty.call(e,n)&&(A[n]=e[n]);return A}).apply(this,arguments)};function __awaiter(A,e,t,r){function adopt(A){return A instanceof t?A:new t(function(e){e(A)})}return new(t||(t=Promise))(function(t,n){function fulfilled(A){try{step(r.next(A))}catch(A){n(A)}}function rejected(A){try{step(r.throw(A))}catch(A){n(A)}}function step(A){A.done?t(A.value):adopt(A.value).then(fulfilled,rejected)}step((r=r.apply(A,e||[])).next())})}function __generator(A,e){var t,r,n,B,s={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return B={next:verb(0),throw:verb(1),return:verb(2)},"function"==typeof Symbol&&(B[Symbol.iterator]=function(){return this}),B;function verb(A){return function(e){return step([A,e])}}function step(B){if(t)throw TypeError("Generator is already executing.");for(;s;)try{if(t=1,r&&(n=2&B[0]?r.return:B[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,B[1])).done)return n;switch(r=0,n&&(B=[2&B[0],n.value]),B[0]){case 0:case 1:n=B;break;case 4:return s.label++,{value:B[1],done:!1};case 5:s.label++,r=B[1],B=[0];continue;case 7:B=s.ops.pop(),s.trys.pop();continue;default:if(!(n=(n=s.trys).length>0&&n[n.length-1])&&(6===B[0]||2===B[0])){s=0;continue}if(3===B[0]&&(!n||B[1]>n[0]&&B[1]<n[3])){s.label=B[1];break}if(6===B[0]&&s.label<n[1]){s.label=n[1],n=B;break}if(n&&s.label<n[2]){s.label=n[2],s.ops.push(B);break}n[2]&&s.ops.pop(),s.trys.pop();continue}B=e.call(A,s)}catch(A){B=[6,A],r=0}finally{t=n=0}if(5&B[0])throw B[1];return{value:B[0]?B[1]:void 0,done:!0}}}function __spreadArray(A,e,t){if(t||2==arguments.length)for(var r,n=0,B=e.length;n<B;n++)!r&&n in e||(r||(r=Array.prototype.slice.call(e,0,n)),r[n]=e[n]);return A.concat(r||e)}for(var E=function(){function Bounds(A,e,t,r){this.left=A,this.top=e,this.width=t,this.height=r}return Bounds.prototype.add=function(A,e,t,r){return new Bounds(this.left+A,this.top+e,this.width+t,this.height+r)},Bounds.fromClientRect=function(A,e){return new Bounds(e.left+A.windowBounds.left,e.top+A.windowBounds.top,e.width,e.height)},Bounds.fromDOMRectList=function(A,e){var t=Array.from(e).find(function(A){return 0!==A.width});return t?new Bounds(t.left+A.windowBounds.left,t.top+A.windowBounds.top,t.width,t.height):Bounds.EMPTY},Bounds.EMPTY=new Bounds(0,0,0,0),Bounds}(),parseBounds=function(A,e){return E.fromClientRect(A,e.getBoundingClientRect())},parseDocumentSize=function(A){var e=A.body,t=A.documentElement;if(!e||!t)throw Error("Unable to get document size");return new E(0,0,Math.max(Math.max(e.scrollWidth,t.scrollWidth),Math.max(e.offsetWidth,t.offsetWidth),Math.max(e.clientWidth,t.clientWidth)),Math.max(Math.max(e.scrollHeight,t.scrollHeight),Math.max(e.offsetHeight,t.offsetHeight),Math.max(e.clientHeight,t.clientHeight)))},toCodePoints$1=function(A){for(var e=[],t=0,r=A.length;t<r;){var n=A.charCodeAt(t++);if(n>=55296&&n<=56319&&t<r){var B=A.charCodeAt(t++);(64512&B)==56320?e.push(((1023&n)<<10)+(1023&B)+65536):(e.push(n),t--)}else e.push(n)}return e},fromCodePoint$1=function(){for(var A=[],e=0;e<arguments.length;e++)A[e]=arguments[e];if(String.fromCodePoint)return String.fromCodePoint.apply(String,A);var t=A.length;if(!t)return"";for(var r=[],n=-1,B="";++n<t;){var s=A[n];s<=65535?r.push(s):(s-=65536,r.push((s>>10)+55296,s%1024+56320)),(n+1===t||r.length>16384)&&(B+=String.fromCharCode.apply(String,r),r.length=0)}return B},I="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",m="undefined"==typeof Uint8Array?[]:new Uint8Array(256),y=0;y<I.length;y++)m[I.charCodeAt(y)]=y;for(var K="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",L="undefined"==typeof Uint8Array?[]:new Uint8Array(256),b=0;b<K.length;b++)L[K.charCodeAt(b)]=b;for(var slice16$1=function(A,e,t){return A.slice?A.slice(e,t):new Uint16Array(Array.prototype.slice.call(A,e,t))},v=function(){function Trie(A,e,t,r,n,B){this.initialValue=A,this.errorValue=e,this.highStart=t,this.highValueIndex=r,this.index=n,this.data=B}return Trie.prototype.get=function(A){var e;if(A>=0){if(A<55296||A>56319&&A<=65535)return e=((e=this.index[A>>5])<<2)+(31&A),this.data[e];if(A<=65535)return e=((e=this.index[2048+(A-55296>>5)])<<2)+(31&A),this.data[e];if(A<this.highStart)return e=2080+(A>>11),e=this.index[e]+(A>>5&63),e=((e=this.index[e])<<2)+(31&A),this.data[e];if(A<=1114111)return this.data[this.highValueIndex]}return this.errorValue},Trie}(),S="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",D="undefined"==typeof Uint8Array?[]:new Uint8Array(256),x=0;x<S.length;x++)D[S.charCodeAt(x)]=x;var T=[9001,65288],V=(e=Array.isArray(A=function(A){var e,t,r,n,B,s=.75*A.length,o=A.length,i=0;"="===A[A.length-1]&&(s--,"="===A[A.length-2]&&s--);var a="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array&&void 0!==Uint8Array.prototype.slice?new ArrayBuffer(s):Array(s),c=Array.isArray(a)?a:new Uint8Array(a);for(e=0;e<o;e+=4)t=L[A.charCodeAt(e)],r=L[A.charCodeAt(e+1)],n=L[A.charCodeAt(e+2)],B=L[A.charCodeAt(e+3)],c[i++]=t<<2|r>>4,c[i++]=(15&r)<<4|n>>2,c[i++]=(3&n)<<6|63&B;return a}(" "))?function(A){for(var e=A.length,t=[],r=0;r<e;r+=4)t.push(A[r+3]<<24|A[r+2]<<16|A[r+1]<<8|A[r]);return t}(A):new Uint32Array(A),r=slice16$1(t=Array.isArray(A)?function(A){for(var e=A.length,t=[],r=0;r<e;r+=2)t.push(A[r+1]<<8|A[r]);return t}(A):new Uint16Array(A),12,e[4]/2),s=2===e[5]?slice16$1(t,(24+e[4])/2):(n=Math.ceil((24+e[4])/4),e.slice?e.slice(n,B):new Uint32Array(Array.prototype.slice.call(e,n,B))),new v(e[0],e[1],e[2],e[3],r,s)),M=[30,36],G=[1,2,3,5],O=[10,8],k=[27,26],P=G.concat(O),R=[38,39,40,34,35],N=[15,13],codePointsToCharacterClasses=function(A,e){void 0===e&&(e="strict");var t=[],r=[],n=[];return A.forEach(function(A,B){var s=V.get(A);if(s>50?(n.push(!0),s-=50):n.push(!1),-1!==["normal","auto","loose"].indexOf(e)&&-1!==[8208,8211,12316,12448].indexOf(A))return r.push(B),t.push(16);if(4===s||11===s){if(0===B)return r.push(B),t.push(30);var o=t[B-1];return -1===P.indexOf(o)?(r.push(r[B-1]),t.push(o)):(r.push(B),t.push(30))}return(r.push(B),31===s)?t.push("strict"===e?21:37):42===s||29===s?t.push(30):43===s?A>=131072&&A<=196605||A>=196608&&A<=262141?t.push(37):t.push(30):void t.push(s)}),[r,t,n]},isAdjacentWithSpaceIgnored=function(A,e,t,r){var n=r[t];if(Array.isArray(A)?-1!==A.indexOf(n):A===n)for(var B=t;B<=r.length;){var s=r[++B];if(s===e)return!0;if(10!==s)break}if(10===n)for(var B=t;B>0;){var o=r[--B];if(Array.isArray(A)?-1!==A.indexOf(o):A===o)for(var i=t;i<=r.length;){var s=r[++i];if(s===e)return!0;if(10!==s)break}if(10!==o)break}return!1},previousNonSpaceClassType=function(A,e){for(var t=A;t>=0;){var r=e[t];if(10!==r)return r;t--}return 0},_lineBreakAtIndex=function(A,e,t,r,n){if(0===t[r])return"\xd7";var B=r-1;if(Array.isArray(n)&&!0===n[B])return"\xd7";var s=B-1,o=B+1,i=e[B],a=s>=0?e[s]:0,c=e[o];if(2===i&&3===c)return"\xd7";if(-1!==G.indexOf(i))return"!";if(-1!==G.indexOf(c)||-1!==O.indexOf(c))return"\xd7";if(8===previousNonSpaceClassType(B,e))return"\xf7";if(11===V.get(A[B])||(32===i||33===i)&&11===V.get(A[o])||7===i||7===c||9===i||-1===[10,13,15].indexOf(i)&&9===c||-1!==[17,18,19,24,28].indexOf(c)||22===previousNonSpaceClassType(B,e)||isAdjacentWithSpaceIgnored(23,22,B,e)||isAdjacentWithSpaceIgnored([17,18],21,B,e)||isAdjacentWithSpaceIgnored(12,12,B,e))return"\xd7";if(10===i)return"\xf7";if(23===i||23===c)return"\xd7";if(16===c||16===i)return"\xf7";if(-1!==[13,15,21].indexOf(c)||14===i||36===a&&-1!==N.indexOf(i)||28===i&&36===c||20===c||-1!==M.indexOf(c)&&25===i||-1!==M.indexOf(i)&&25===c||27===i&&-1!==[37,32,33].indexOf(c)||-1!==[37,32,33].indexOf(i)&&26===c||-1!==M.indexOf(i)&&-1!==k.indexOf(c)||-1!==k.indexOf(i)&&-1!==M.indexOf(c)||-1!==[27,26].indexOf(i)&&(25===c||-1!==[22,15].indexOf(c)&&25===e[o+1])||-1!==[22,15].indexOf(i)&&25===c||25===i&&-1!==[25,28,24].indexOf(c))return"\xd7";if(-1!==[25,28,24,17,18].indexOf(c))for(var g=B;g>=0;){var Q=e[g];if(25===Q)return"\xd7";if(-1!==[28,24].indexOf(Q))g--;else break}if(-1!==[27,26].indexOf(c))for(var g=-1!==[17,18].indexOf(i)?s:B;g>=0;){var Q=e[g];if(25===Q)return"\xd7";if(-1!==[28,24].indexOf(Q))g--;else break}if(38===i&&-1!==[38,39,34,35].indexOf(c)||-1!==[39,34].indexOf(i)&&-1!==[39,40].indexOf(c)||-1!==[40,35].indexOf(i)&&40===c||-1!==R.indexOf(i)&&-1!==[20,26].indexOf(c)||-1!==R.indexOf(c)&&27===i||-1!==M.indexOf(i)&&-1!==M.indexOf(c)||24===i&&-1!==M.indexOf(c)||-1!==M.concat(25).indexOf(i)&&22===c&&-1===T.indexOf(A[o])||-1!==M.concat(25).indexOf(c)&&18===i)return"\xd7";if(41===i&&41===c){for(var l=t[B],w=1;l>0;)if(41===e[--l])w++;else break;if(w%2!=0)return"\xd7"}return 32===i&&33===c?"\xd7":"\xf7"},cssFormattedClasses=function(A,e){e||(e={lineBreak:"normal",wordBreak:"normal"});var t=codePointsToCharacterClasses(A,e.lineBreak),r=t[0],n=t[1],B=t[2];return("break-all"===e.wordBreak||"break-word"===e.wordBreak)&&(n=n.map(function(A){return -1!==[25,30,42].indexOf(A)?37:A})),[r,n,"keep-all"===e.wordBreak?B.map(function(e,t){return e&&A[t]>=19968&&A[t]<=40959}):void 0]},J=function(){function Break(A,e,t,r){this.codePoints=A,this.required="!"===e,this.start=t,this.end=r}return Break.prototype.slice=function(){return fromCodePoint$1.apply(void 0,this.codePoints.slice(this.start,this.end))},Break}(),LineBreaker=function(A,e){var t=toCodePoints$1(A),r=cssFormattedClasses(t,e),n=r[0],B=r[1],s=r[2],o=t.length,i=0,a=0;return{next:function(){if(a>=o)return{done:!0,value:null};for(var A="\xd7";a<o&&"\xd7"===(A=_lineBreakAtIndex(t,B,n,++a,s)););if("\xd7"!==A||a===o){var e=new J(t,A,i,a);return i=a,{value:e,done:!1}}return{done:!0,value:null}}}},isDigit=function(A){return A>=48&&A<=57},isHex=function(A){return isDigit(A)||A>=65&&A<=70||A>=97&&A<=102},isWhiteSpace=function(A){return 10===A||9===A||32===A},isNameStartCodePoint=function(A){var e;return(e=A)>=97&&e<=122||e>=65&&e<=90||A>=128||95===A},isNameCodePoint=function(A){return isNameStartCodePoint(A)||isDigit(A)||45===A},isValidEscape=function(A,e){return 92===A&&10!==e},isIdentifierStart=function(A,e,t){return 45===A?isNameStartCodePoint(e)||isValidEscape(e,t):!!(isNameStartCodePoint(A)||92===A&&isValidEscape(A,e))},isNumberStart=function(A,e,t){return 43===A||45===A?!!isDigit(e)||46===e&&isDigit(t):46===A?isDigit(e):isDigit(A)},stringToNumber=function(A){var e=0,t=1;(43===A[0]||45===A[e])&&(45===A[e]&&(t=-1),e++);for(var r=[];isDigit(A[e]);)r.push(A[e++]);var n=r.length?parseInt(fromCodePoint$1.apply(void 0,r),10):0;46===A[e]&&e++;for(var B=[];isDigit(A[e]);)B.push(A[e++]);var s=B.length,o=s?parseInt(fromCodePoint$1.apply(void 0,B),10):0;(69===A[e]||101===A[e])&&e++;var i=1;(43===A[e]||45===A[e])&&(45===A[e]&&(i=-1),e++);for(var a=[];isDigit(A[e]);)a.push(A[e++]);return t*(n+o*Math.pow(10,-s))*Math.pow(10,i*(a.length?parseInt(fromCodePoint$1.apply(void 0,a),10):0))},X={type:2},Y={type:3},W={type:4},_={type:13},Z={type:8},z={type:21},q={type:9},j={type:10},$={type:11},AA={type:12},Ae={type:14},At={type:23},Ar={type:1},An={type:25},AB={type:24},As={type:26},Ao={type:27},Ai={type:28},Aa={type:29},Ac={type:31},Ag={type:32},AQ=function(){function Tokenizer(){this._value=[]}return Tokenizer.prototype.write=function(A){this._value=this._value.concat(toCodePoints$1(A))},Tokenizer.prototype.read=function(){for(var A=[],e=this.consumeToken();e!==Ag;)A.push(e),e=this.consumeToken();return A},Tokenizer.prototype.consumeToken=function(){var A=this.consumeCodePoint();switch(A){case 34:return this.consumeStringToken(34);case 35:var e=this.peekCodePoint(0),t=this.peekCodePoint(1),r=this.peekCodePoint(2);if(isNameCodePoint(e)||isValidEscape(t,r)){var n=isIdentifierStart(e,t,r)?2:1,B=this.consumeName();return{type:5,value:B,flags:n}}break;case 36:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),_;break;case 39:return this.consumeStringToken(39);case 40:return X;case 41:return Y;case 42:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Ae;break;case 43:case 46:if(isNumberStart(A,this.peekCodePoint(0),this.peekCodePoint(1)))return this.reconsumeCodePoint(A),this.consumeNumericToken();break;case 44:return W;case 45:var s=this.peekCodePoint(0),o=this.peekCodePoint(1);if(isNumberStart(A,s,o))return this.reconsumeCodePoint(A),this.consumeNumericToken();if(isIdentifierStart(A,s,o))return this.reconsumeCodePoint(A),this.consumeIdentLikeToken();if(45===s&&62===o)return this.consumeCodePoint(),this.consumeCodePoint(),AB;break;case 47:if(42===this.peekCodePoint(0))for(this.consumeCodePoint();;){var i=this.consumeCodePoint();if(42===i&&47===(i=this.consumeCodePoint())||-1===i)return this.consumeToken()}break;case 58:return As;case 59:return Ao;case 60:if(33===this.peekCodePoint(0)&&45===this.peekCodePoint(1)&&45===this.peekCodePoint(2))return this.consumeCodePoint(),this.consumeCodePoint(),An;break;case 64:if(isIdentifierStart(this.peekCodePoint(0),this.peekCodePoint(1),this.peekCodePoint(2))){var B=this.consumeName();return{type:7,value:B}}break;case 91:return Ai;case 92:if(isValidEscape(A,this.peekCodePoint(0)))return this.reconsumeCodePoint(A),this.consumeIdentLikeToken();break;case 93:return Aa;case 61:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),Z;break;case 123:return $;case 125:return AA;case 117:case 85:var a=this.peekCodePoint(0),c=this.peekCodePoint(1);return 43===a&&(isHex(c)||63===c)&&(this.consumeCodePoint(),this.consumeUnicodeRangeToken()),this.reconsumeCodePoint(A),this.consumeIdentLikeToken();case 124:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),q;if(124===this.peekCodePoint(0))return this.consumeCodePoint(),z;break;case 126:if(61===this.peekCodePoint(0))return this.consumeCodePoint(),j;break;case -1:return Ag}return isWhiteSpace(A)?(this.consumeWhiteSpace(),Ac):isDigit(A)?(this.reconsumeCodePoint(A),this.consumeNumericToken()):isNameStartCodePoint(A)?(this.reconsumeCodePoint(A),this.consumeIdentLikeToken()):{type:6,value:fromCodePoint$1(A)}},Tokenizer.prototype.consumeCodePoint=function(){var A=this._value.shift();return void 0===A?-1:A},Tokenizer.prototype.reconsumeCodePoint=function(A){this._value.unshift(A)},Tokenizer.prototype.peekCodePoint=function(A){return A>=this._value.length?-1:this._value[A]},Tokenizer.prototype.consumeUnicodeRangeToken=function(){for(var A=[],e=this.consumeCodePoint();isHex(e)&&A.length<6;)A.push(e),e=this.consumeCodePoint();for(var t=!1;63===e&&A.length<6;)A.push(e),e=this.consumeCodePoint(),t=!0;if(t){var r=parseInt(fromCodePoint$1.apply(void 0,A.map(function(A){return 63===A?48:A})),16),n=parseInt(fromCodePoint$1.apply(void 0,A.map(function(A){return 63===A?70:A})),16);return{type:30,start:r,end:n}}var B=parseInt(fromCodePoint$1.apply(void 0,A),16);if(!(45===this.peekCodePoint(0)&&isHex(this.peekCodePoint(1))))return{type:30,start:B,end:B};this.consumeCodePoint(),e=this.consumeCodePoint();for(var s=[];isHex(e)&&s.length<6;)s.push(e),e=this.consumeCodePoint();var n=parseInt(fromCodePoint$1.apply(void 0,s),16);return{type:30,start:B,end:n}},Tokenizer.prototype.consumeIdentLikeToken=function(){var A=this.consumeName();return"url"===A.toLowerCase()&&40===this.peekCodePoint(0)?(this.consumeCodePoint(),this.consumeUrlToken()):40===this.peekCodePoint(0)?(this.consumeCodePoint(),{type:19,value:A}):{type:20,value:A}},Tokenizer.prototype.consumeUrlToken=function(){var A=[];if(this.consumeWhiteSpace(),-1===this.peekCodePoint(0))return{type:22,value:""};var e=this.peekCodePoint(0);if(39===e||34===e){var t=this.consumeStringToken(this.consumeCodePoint());return 0===t.type&&(this.consumeWhiteSpace(),-1===this.peekCodePoint(0)||41===this.peekCodePoint(0))?(this.consumeCodePoint(),{type:22,value:t.value}):(this.consumeBadUrlRemnants(),At)}for(;;){var r,n=this.consumeCodePoint();if(-1===n||41===n)return{type:22,value:fromCodePoint$1.apply(void 0,A)};if(isWhiteSpace(n)){if(this.consumeWhiteSpace(),-1===this.peekCodePoint(0)||41===this.peekCodePoint(0))return this.consumeCodePoint(),{type:22,value:fromCodePoint$1.apply(void 0,A)};return this.consumeBadUrlRemnants(),At}if(34===n||39===n||40===n||(r=n)>=0&&r<=8||11===r||r>=14&&r<=31||127===r)return this.consumeBadUrlRemnants(),At;if(92===n){if(!isValidEscape(n,this.peekCodePoint(0)))return this.consumeBadUrlRemnants(),At;A.push(this.consumeEscapedCodePoint())}else A.push(n)}},Tokenizer.prototype.consumeWhiteSpace=function(){for(;isWhiteSpace(this.peekCodePoint(0));)this.consumeCodePoint()},Tokenizer.prototype.consumeBadUrlRemnants=function(){for(;;){var A=this.consumeCodePoint();if(41===A||-1===A)return;isValidEscape(A,this.peekCodePoint(0))&&this.consumeEscapedCodePoint()}},Tokenizer.prototype.consumeStringSlice=function(A){for(var e="";A>0;){var t=Math.min(5e4,A);e+=fromCodePoint$1.apply(void 0,this._value.splice(0,t)),A-=t}return this._value.shift(),e},Tokenizer.prototype.consumeStringToken=function(A){for(var e="",t=0;;){var r=this._value[t];if(-1===r||void 0===r||r===A)return{type:0,value:e+=this.consumeStringSlice(t)};if(10===r)return this._value.splice(0,t),Ar;if(92===r){var n=this._value[t+1];-1!==n&&void 0!==n&&(10===n?(e+=this.consumeStringSlice(t),t=-1,this._value.shift()):isValidEscape(r,n)&&(e+=this.consumeStringSlice(t)+fromCodePoint$1(this.consumeEscapedCodePoint()),t=-1))}t++}},Tokenizer.prototype.consumeNumber=function(){var A=[],e=4,t=this.peekCodePoint(0);for((43===t||45===t)&&A.push(this.consumeCodePoint());isDigit(this.peekCodePoint(0));)A.push(this.consumeCodePoint());t=this.peekCodePoint(0);var r=this.peekCodePoint(1);if(46===t&&isDigit(r))for(A.push(this.consumeCodePoint(),this.consumeCodePoint()),e=8;isDigit(this.peekCodePoint(0));)A.push(this.consumeCodePoint());t=this.peekCodePoint(0),r=this.peekCodePoint(1);var n=this.peekCodePoint(2);if((69===t||101===t)&&((43===r||45===r)&&isDigit(n)||isDigit(r)))for(A.push(this.consumeCodePoint(),this.consumeCodePoint()),e=8;isDigit(this.peekCodePoint(0));)A.push(this.consumeCodePoint());return[stringToNumber(A),e]},Tokenizer.prototype.consumeNumericToken=function(){var A=this.consumeNumber(),e=A[0],t=A[1],r=this.peekCodePoint(0);return isIdentifierStart(r,this.peekCodePoint(1),this.peekCodePoint(2))?{type:15,number:e,flags:t,unit:this.consumeName()}:37===r?(this.consumeCodePoint(),{type:16,number:e,flags:t}):{type:17,number:e,flags:t}},Tokenizer.prototype.consumeEscapedCodePoint=function(){var A=this.consumeCodePoint();if(isHex(A)){for(var e=fromCodePoint$1(A);isHex(this.peekCodePoint(0))&&e.length<6;)e+=fromCodePoint$1(this.consumeCodePoint());isWhiteSpace(this.peekCodePoint(0))&&this.consumeCodePoint();var t=parseInt(e,16);return 0===t||t>=55296&&t<=57343||t>1114111?65533:t}return -1===A?65533:A},Tokenizer.prototype.consumeName=function(){for(var A="";;){var e=this.consumeCodePoint();if(isNameCodePoint(e))A+=fromCodePoint$1(e);else{if(!isValidEscape(e,this.peekCodePoint(0)))return this.reconsumeCodePoint(e),A;A+=fromCodePoint$1(this.consumeEscapedCodePoint())}}},Tokenizer}(),Al=function(){function Parser(A){this._tokens=A}return Parser.create=function(A){var e=new AQ;return e.write(A),new Parser(e.read())},Parser.parseValue=function(A){return Parser.create(A).parseComponentValue()},Parser.parseValues=function(A){return Parser.create(A).parseComponentValues()},Parser.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 e=this.consumeComponentValue();do A=this.consumeToken();while(31===A.type);if(32===A.type)return e;throw SyntaxError("Error parsing CSS component value, multiple values found when expecting only one")},Parser.prototype.parseComponentValues=function(){for(var A=[];;){var e=this.consumeComponentValue();if(32===e.type)return A;A.push(e),A.push()}},Parser.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},Parser.prototype.consumeSimpleBlock=function(A){for(var e={type:A,values:[]},t=this.consumeToken();;){if(32===t.type||isEndingTokenFor(t,A))return e;this.reconsumeToken(t),e.values.push(this.consumeComponentValue()),t=this.consumeToken()}},Parser.prototype.consumeFunction=function(A){for(var e={name:A.value,values:[],type:18};;){var t=this.consumeToken();if(32===t.type||3===t.type)return e;this.reconsumeToken(t),e.values.push(this.consumeComponentValue())}},Parser.prototype.consumeToken=function(){var A=this._tokens.shift();return void 0===A?Ag:A},Parser.prototype.reconsumeToken=function(A){this._tokens.unshift(A)},Parser}(),isDimensionToken=function(A){return 15===A.type},isNumberToken=function(A){return 17===A.type},isIdentToken=function(A){return 20===A.type},isStringToken=function(A){return 0===A.type},isIdentWithValue=function(A,e){return isIdentToken(A)&&A.value===e},nonWhiteSpace=function(A){return 31!==A.type},nonFunctionArgSeparator=function(A){return 31!==A.type&&4!==A.type},parseFunctionArgs=function(A){var e=[],t=[];return A.forEach(function(A){if(4===A.type){if(0===t.length)throw Error("Error parsing function args, zero tokens for arg");e.push(t),t=[];return}31!==A.type&&t.push(A)}),t.length&&e.push(t),e},isEndingTokenFor=function(A,e){return 11===e&&12===A.type||28===e&&29===A.type||2===e&&3===A.type},isLength=function(A){return 17===A.type||15===A.type},isLengthPercentage=function(A){return 16===A.type||isLength(A)},parseLengthPercentageTuple=function(A){return A.length>1?[A[0],A[1]]:[A[0]]},Aw={type:17,number:0,flags:4},Au={type:16,number:50,flags:4},AC={type:16,number:100,flags:4},getAbsoluteValueForTuple=function(A,e,t){var r=A[0],n=A[1];return[getAbsoluteValue(r,e),getAbsoluteValue(void 0!==n?n:r,t)]},getAbsoluteValue=function(A,e){if(16===A.type)return A.number/100*e;if(isDimensionToken(A))switch(A.unit){case"rem":case"em":return 16*A.number}return A.number},AF="grad",AU="turn",Ad={name:"angle",parse:function(A,e){if(15===e.type)switch(e.unit){case"deg":return Math.PI*e.number/180;case AF:return Math.PI/200*e.number;case"rad":return e.number;case AU:return 2*Math.PI*e.number}throw Error("Unsupported angle type")}},isAngle=function(A){return 15===A.type&&("deg"===A.unit||A.unit===AF||"rad"===A.unit||A.unit===AU)},parseNamedSide=function(A){switch(A.filter(isIdentToken).map(function(A){return A.value}).join(" ")){case"to bottom right":case"to right bottom":case"left top":case"top left":return[Aw,Aw];case"to top":case"bottom":return deg(0);case"to bottom left":case"to left bottom":case"right top":case"top right":return[Aw,AC];case"to right":case"left":return deg(90);case"to top left":case"to left top":case"right bottom":case"bottom right":return[AC,AC];case"to bottom":case"top":return deg(180);case"to top right":case"to right top":case"left bottom":case"bottom left":return[AC,Aw];case"to left":case"right":return deg(270)}return 0},deg=function(A){return Math.PI*A/180},Ah={name:"color",parse:function(A,e){if(18===e.type){var t=Ap[e.name];if(void 0===t)throw Error('Attempting to parse an unsupported color function "'+e.name+'"');return t(A,e.values)}if(5===e.type){if(3===e.value.length){var r=e.value.substring(0,1),n=e.value.substring(1,2),B=e.value.substring(2,3);return pack(parseInt(r+r,16),parseInt(n+n,16),parseInt(B+B,16),1)}if(4===e.value.length){var r=e.value.substring(0,1),n=e.value.substring(1,2),B=e.value.substring(2,3),s=e.value.substring(3,4);return pack(parseInt(r+r,16),parseInt(n+n,16),parseInt(B+B,16),parseInt(s+s,16)/255)}if(6===e.value.length){var r=e.value.substring(0,2),n=e.value.substring(2,4),B=e.value.substring(4,6);return pack(parseInt(r,16),parseInt(n,16),parseInt(B,16),1)}if(8===e.value.length){var r=e.value.substring(0,2),n=e.value.substring(2,4),B=e.value.substring(4,6),s=e.value.substring(6,8);return pack(parseInt(r,16),parseInt(n,16),parseInt(B,16),parseInt(s,16)/255)}}if(20===e.type){var o=Af[e.value.toUpperCase()];if(void 0!==o)return o}return Af.TRANSPARENT}},isTransparent=function(A){return(255&A)==0},asString=function(A){var e=255&A,t=255&A>>8,r=255&A>>16,n=255&A>>24;return e<255?"rgba("+n+","+r+","+t+","+e/255+")":"rgb("+n+","+r+","+t+")"},pack=function(A,e,t,r){return(A<<24|e<<16|t<<8|Math.round(255*r)<<0)>>>0},getTokenColorValue=function(A,e){if(17===A.type)return A.number;if(16===A.type){var t=3===e?1:255;return 3===e?A.number/100*t:Math.round(A.number/100*t)}return 0},rgb=function(A,e){var t=e.filter(nonFunctionArgSeparator);if(3===t.length){var r=t.map(getTokenColorValue),n=r[0],B=r[1],s=r[2];return pack(n,B,s,1)}if(4===t.length){var o=t.map(getTokenColorValue),n=o[0],B=o[1],s=o[2];return pack(n,B,s,o[3])}return 0};function hue2rgb(A,e,t){return(t<0&&(t+=1),t>=1&&(t-=1),t<1/6)?(e-A)*t*6+A:t<.5?e:t<2/3?(e-A)*6*(2/3-t)+A:A}var hsl=function(A,e){var t=e.filter(nonFunctionArgSeparator),r=t[0],n=t[1],B=t[2],s=t[3],o=(17===r.type?deg(r.number):Ad.parse(A,r))/(2*Math.PI),i=isLengthPercentage(n)?n.number/100:0,a=isLengthPercentage(B)?B.number/100:0,c=void 0!==s&&isLengthPercentage(s)?getAbsoluteValue(s,1):1;if(0===i)return pack(255*a,255*a,255*a,1);var g=a<=.5?a*(i+1):a+i-a*i,Q=2*a-g;return pack(255*hue2rgb(Q,g,o+1/3),255*hue2rgb(Q,g,o),255*hue2rgb(Q,g,o-1/3),c)},Ap={hsl:hsl,hsla:hsl,rgb:rgb,rgba:rgb},parseColor=function(A,e){return Ah.parse(A,Al.create(e).parseComponentValue())},Af={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},AH={name:"background-clip",initialValue:"border-box",prefix:!1,type:1,parse:function(A,e){return e.map(function(A){if(isIdentToken(A))switch(A.value){case"padding-box":return 1;case"content-box":return 2}return 0})}},AE={name:"background-color",initialValue:"transparent",prefix:!1,type:3,format:"color"},parseColorStop=function(A,e){var t=Ah.parse(A,e[0]),r=e[1];return r&&isLengthPercentage(r)?{color:t,stop:r}:{color:t,stop:null}},processColorStops=function(A,e){var t=A[0],r=A[A.length-1];null===t.stop&&(t.stop=Aw),null===r.stop&&(r.stop=AC);for(var n=[],B=0,s=0;s<A.length;s++){var o=A[s].stop;if(null!==o){var i=getAbsoluteValue(o,e);i>B?n.push(i):n.push(B),B=i}else n.push(null)}for(var a=null,s=0;s<n.length;s++){var c=n[s];if(null===c)null===a&&(a=s);else if(null!==a){for(var g=s-a,Q=(c-n[a-1])/(g+1),l=1;l<=g;l++)n[a+l-1]=Q*l;a=null}}return A.map(function(A,t){return{color:A.color,stop:Math.max(Math.min(1,n[t]/e),0)}})},getAngleFromCorner=function(A,e,t){var r=e/2,n=t/2,B=getAbsoluteValue(A[0],e)-r;return(Math.atan2(n-getAbsoluteValue(A[1],t),B)+2*Math.PI)%(2*Math.PI)},calculateGradientDirection=function(A,e,t){var r="number"==typeof A?A:getAngleFromCorner(A,e,t),n=Math.abs(e*Math.sin(r))+Math.abs(t*Math.cos(r)),B=e/2,s=t/2,o=n/2,i=Math.sin(r-Math.PI/2)*o,a=Math.cos(r-Math.PI/2)*o;return[n,B-a,B+a,s-i,s+i]},distance=function(A,e){return Math.sqrt(A*A+e*e)},findCorner=function(A,e,t,r,n){return[[0,0],[0,e],[A,0],[A,e]].reduce(function(A,e){var B=distance(t-e[0],r-e[1]);return(n?B<A.optimumDistance:B>A.optimumDistance)?{optimumCorner:e,optimumDistance:B}:A},{optimumDistance:n?1/0:-1/0,optimumCorner:null}).optimumCorner},calculateRadius=function(A,e,t,r,n){var B=0,s=0;switch(A.size){case 0:0===A.shape?B=s=Math.min(Math.abs(e),Math.abs(e-r),Math.abs(t),Math.abs(t-n)):1===A.shape&&(B=Math.min(Math.abs(e),Math.abs(e-r)),s=Math.min(Math.abs(t),Math.abs(t-n)));break;case 2:if(0===A.shape)B=s=Math.min(distance(e,t),distance(e,t-n),distance(e-r,t),distance(e-r,t-n));else if(1===A.shape){var o=Math.min(Math.abs(t),Math.abs(t-n))/Math.min(Math.abs(e),Math.abs(e-r)),i=findCorner(r,n,e,t,!0),a=i[0],c=i[1];B=distance(a-e,(c-t)/o),s=o*B}break;case 1:0===A.shape?B=s=Math.max(Math.abs(e),Math.abs(e-r),Math.abs(t),Math.abs(t-n)):1===A.shape&&(B=Math.max(Math.abs(e),Math.abs(e-r)),s=Math.max(Math.abs(t),Math.abs(t-n)));break;case 3:if(0===A.shape)B=s=Math.max(distance(e,t),distance(e,t-n),distance(e-r,t),distance(e-r,t-n));else if(1===A.shape){var o=Math.max(Math.abs(t),Math.abs(t-n))/Math.max(Math.abs(e),Math.abs(e-r)),g=findCorner(r,n,e,t,!1),a=g[0],c=g[1];B=distance(a-e,(c-t)/o),s=o*B}}return Array.isArray(A.size)&&(B=getAbsoluteValue(A.size[0],r),s=2===A.size.length?getAbsoluteValue(A.size[1],n):B),[B,s]},prefixLinearGradient=function(A,e){var t=deg(180),r=[];return parseFunctionArgs(e).forEach(function(e,n){if(0===n){var B=e[0];if(20===B.type&&-1!==["top","left","right","bottom"].indexOf(B.value)){t=parseNamedSide(e);return}if(isAngle(B)){t=(Ad.parse(A,B)+deg(270))%deg(360);return}}var s=parseColorStop(A,e);r.push(s)}),{angle:t,stops:r,type:1}},AI="closest-side",Am="farthest-side",Ay="closest-corner",AK="farthest-corner",AL="circle",Ab="ellipse",Av="cover",AS="contain",prefixRadialGradient=function(A,e){var t=0,r=3,n=[],B=[];return parseFunctionArgs(e).forEach(function(e,s){var o=!0;if(0===s?o=e.reduce(function(A,e){if(isIdentToken(e))switch(e.value){case"center":return B.push(Au),!1;case"top":case"left":return B.push(Aw),!1;case"right":case"bottom":return B.push(AC),!1}else if(isLengthPercentage(e)||isLength(e))return B.push(e),!1;return A},o):1===s&&(o=e.reduce(function(A,e){if(isIdentToken(e))switch(e.value){case AL:return t=0,!1;case Ab:return t=1,!1;case AS:case AI:return r=0,!1;case Am:return r=1,!1;case Ay:return r=2,!1;case Av:case AK:return r=3,!1}else if(isLength(e)||isLengthPercentage(e))return Array.isArray(r)||(r=[]),r.push(e),!1;return A},o)),o){var i=parseColorStop(A,e);n.push(i)}}),{size:r,shape:t,stops:n,position:B,type:2}},AD={name:"image",parse:function(A,e){if(22===e.type){var t={url:e.value,type:0};return A.cache.addImage(e.value),t}if(18===e.type){var r=Ax[e.name];if(void 0===r)throw Error('Attempting to parse an unsupported image function "'+e.name+'"');return r(A,e.values)}throw Error("Unsupported image type "+e.type)}};function isSupportedImage(A){return!(20===A.type&&"none"===A.value)&&(18!==A.type||!!Ax[A.name])}var Ax={"linear-gradient":function(A,e){var t=deg(180),r=[];return parseFunctionArgs(e).forEach(function(e,n){if(0===n){var B=e[0];if(20===B.type&&"to"===B.value){t=parseNamedSide(e);return}if(isAngle(B)){t=Ad.parse(A,B);return}}var s=parseColorStop(A,e);r.push(s)}),{angle:t,stops:r,type:1}},"-moz-linear-gradient":prefixLinearGradient,"-ms-linear-gradient":prefixLinearGradient,"-o-linear-gradient":prefixLinearGradient,"-webkit-linear-gradient":prefixLinearGradient,"radial-gradient":function(A,e){var t=0,r=3,n=[],B=[];return parseFunctionArgs(e).forEach(function(e,s){var o=!0;if(0===s){var i=!1;o=e.reduce(function(A,e){if(i){if(isIdentToken(e))switch(e.value){case"center":B.push(Au);break;case"top":case"left":B.push(Aw);break;case"right":case"bottom":B.push(AC)}else(isLengthPercentage(e)||isLength(e))&&B.push(e)}else if(isIdentToken(e))switch(e.value){case AL:return t=0,!1;case Ab:return t=1,!1;case"at":return i=!0,!1;case AI:return r=0,!1;case Av:case Am:return r=1,!1;case AS:case Ay:return r=2,!1;case AK:return r=3,!1}else if(isLength(e)||isLengthPercentage(e))return Array.isArray(r)||(r=[]),r.push(e),!1;return A},o)}if(o){var a=parseColorStop(A,e);n.push(a)}}),{size:r,shape:t,stops:n,position:B,type:2}},"-moz-radial-gradient":prefixRadialGradient,"-ms-radial-gradient":prefixRadialGradient,"-o-radial-gradient":prefixRadialGradient,"-webkit-radial-gradient":prefixRadialGradient,"-webkit-gradient":function(A,e){var t=deg(180),r=[],n=1;return parseFunctionArgs(e).forEach(function(e,t){var B=e[0];if(0===t){if(isIdentToken(B)&&"linear"===B.value){n=1;return}if(isIdentToken(B)&&"radial"===B.value){n=2;return}}if(18===B.type){if("from"===B.name){var s=Ah.parse(A,B.values[0]);r.push({stop:Aw,color:s})}else if("to"===B.name){var s=Ah.parse(A,B.values[0]);r.push({stop:AC,color:s})}else if("color-stop"===B.name){var o=B.values.filter(nonFunctionArgSeparator);if(2===o.length){var s=Ah.parse(A,o[1]),i=o[0];isNumberToken(i)&&r.push({stop:{type:16,number:100*i.number,flags:i.flags},color:s})}}}}),1===n?{angle:(t+deg(180))%deg(360),stops:r,type:n}:{size:3,shape:0,stops:r,position:[],type:n}}},AT={name:"background-image",initialValue:"none",type:1,prefix:!1,parse:function(A,e){if(0===e.length)return[];var t=e[0];return 20===t.type&&"none"===t.value?[]:e.filter(function(A){return nonFunctionArgSeparator(A)&&isSupportedImage(A)}).map(function(e){return AD.parse(A,e)})}},AV={name:"background-origin",initialValue:"border-box",prefix:!1,type:1,parse:function(A,e){return e.map(function(A){if(isIdentToken(A))switch(A.value){case"padding-box":return 1;case"content-box":return 2}return 0})}},AM={name:"background-position",initialValue:"0% 0%",type:1,prefix:!1,parse:function(A,e){return parseFunctionArgs(e).map(function(A){return A.filter(isLengthPercentage)}).map(parseLengthPercentageTuple)}},AG={name:"background-repeat",initialValue:"repeat",prefix:!1,type:1,parse:function(A,e){return parseFunctionArgs(e).map(function(A){return A.filter(isIdentToken).map(function(A){return A.value}).join(" ")}).map(parseBackgroundRepeat)}},parseBackgroundRepeat=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}};(o=d||(d={})).AUTO="auto",o.CONTAIN="contain",o.COVER="cover";var AO={name:"background-size",initialValue:"0",prefix:!1,type:1,parse:function(A,e){return parseFunctionArgs(e).map(function(A){return A.filter(isBackgroundSizeInfoToken)})}},isBackgroundSizeInfoToken=function(A){return isIdentToken(A)||isLengthPercentage(A)},borderColorForSide=function(A){return{name:"border-"+A+"-color",initialValue:"transparent",prefix:!1,type:3,format:"color"}},Ak=borderColorForSide("top"),AP=borderColorForSide("right"),AR=borderColorForSide("bottom"),AN=borderColorForSide("left"),borderRadiusForSide=function(A){return{name:"border-radius-"+A,initialValue:"0 0",prefix:!1,type:1,parse:function(A,e){return parseLengthPercentageTuple(e.filter(isLengthPercentage))}}},AJ=borderRadiusForSide("top-left"),AX=borderRadiusForSide("top-right"),AY=borderRadiusForSide("bottom-right"),AW=borderRadiusForSide("bottom-left"),borderStyleForSide=function(A){return{name:"border-"+A+"-style",initialValue:"solid",prefix:!1,type:2,parse:function(A,e){switch(e){case"none":return 0;case"dashed":return 2;case"dotted":return 3;case"double":return 4}return 1}}},A_=borderStyleForSide("top"),AZ=borderStyleForSide("right"),Az=borderStyleForSide("bottom"),Aq=borderStyleForSide("left"),borderWidthForSide=function(A){return{name:"border-"+A+"-width",initialValue:"0",type:0,prefix:!1,parse:function(A,e){return isDimensionToken(e)?e.number:0}}},Aj=borderWidthForSide("top"),A$=borderWidthForSide("right"),A0=borderWidthForSide("bottom"),A4=borderWidthForSide("left"),A1={name:"color",initialValue:"transparent",prefix:!1,type:3,format:"color"},A2={name:"direction",initialValue:"ltr",prefix:!1,type:2,parse:function(A,e){return"rtl"===e?1:0}},A3={name:"display",initialValue:"inline-block",prefix:!1,type:1,parse:function(A,e){return e.filter(isIdentToken).reduce(function(A,e){return A|parseDisplayValue(e.value)},0)}},parseDisplayValue=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},A5={name:"float",initialValue:"none",prefix:!1,type:2,parse:function(A,e){switch(e){case"left":return 1;case"right":return 2;case"inline-start":return 3;case"inline-end":return 4}return 0}},A6={name:"letter-spacing",initialValue:"0",prefix:!1,type:0,parse:function(A,e){return 20===e.type&&"normal"===e.value?0:17===e.type||15===e.type?e.number:0}};(i=h||(h={})).NORMAL="normal",i.STRICT="strict";var A8={name:"line-break",initialValue:"normal",prefix:!1,type:2,parse:function(A,e){return"strict"===e?h.STRICT:h.NORMAL}},A7={name:"line-height",initialValue:"normal",prefix:!1,type:4},computeLineHeight=function(A,e){return isIdentToken(A)&&"normal"===A.value?1.2*e:17===A.type?e*A.number:isLengthPercentage(A)?getAbsoluteValue(A,e):e},A9={name:"list-style-image",initialValue:"none",type:0,prefix:!1,parse:function(A,e){return 20===e.type&&"none"===e.value?null:AD.parse(A,e)}},eA={name:"list-style-position",initialValue:"outside",prefix:!1,type:2,parse:function(A,e){return"inside"===e?0:1}},ee={name:"list-style-type",initialValue:"none",prefix:!1,type:2,parse:function(A,e){switch(e){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}}},marginForSide=function(A){return{name:"margin-"+A,initialValue:"0",prefix:!1,type:4}},et=marginForSide("top"),er=marginForSide("right"),en=marginForSide("bottom"),eB=marginForSide("left"),es={name:"overflow",initialValue:"visible",prefix:!1,type:1,parse:function(A,e){return e.filter(isIdentToken).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}})}},eo={name:"overflow-wrap",initialValue:"normal",prefix:!1,type:2,parse:function(A,e){return"break-word"===e?"break-word":"normal"}},paddingForSide=function(A){return{name:"padding-"+A,initialValue:"0",prefix:!1,type:3,format:"length-percentage"}},ei=paddingForSide("top"),ea=paddingForSide("right"),ec=paddingForSide("bottom"),eg=paddingForSide("left"),eQ={name:"text-align",initialValue:"left",prefix:!1,type:2,parse:function(A,e){switch(e){case"right":return 2;case"center":case"justify":return 1;default:return 0}}},el={name:"position",initialValue:"static",prefix:!1,type:2,parse:function(A,e){switch(e){case"relative":return 1;case"absolute":return 2;case"fixed":return 3;case"sticky":return 4}return 0}},ew={name:"text-shadow",initialValue:"none",type:1,prefix:!1,parse:function(A,e){return 1===e.length&&isIdentWithValue(e[0],"none")?[]:parseFunctionArgs(e).map(function(e){for(var t={color:Af.TRANSPARENT,offsetX:Aw,offsetY:Aw,blur:Aw},r=0,n=0;n<e.length;n++){var B=e[n];isLength(B)?(0===r?t.offsetX=B:1===r?t.offsetY=B:t.blur=B,r++):t.color=Ah.parse(A,B)}return t})}},eu={name:"text-transform",initialValue:"none",prefix:!1,type:2,parse:function(A,e){switch(e){case"uppercase":return 2;case"lowercase":return 1;case"capitalize":return 3}return 0}},eC={name:"transform",initialValue:"none",prefix:!0,type:0,parse:function(A,e){if(20===e.type&&"none"===e.value)return null;if(18===e.type){var t=eF[e.name];if(void 0===t)throw Error('Attempting to parse an unsupported transform function "'+e.name+'"');return t(e.values)}return null}},eF={matrix:function(A){var e=A.filter(function(A){return 17===A.type}).map(function(A){return A.number});return 6===e.length?e:null},matrix3d:function(A){var e=A.filter(function(A){return 17===A.type}).map(function(A){return A.number}),t=e[0],r=e[1];e[2],e[3];var n=e[4],B=e[5];e[6],e[7],e[8],e[9],e[10],e[11];var s=e[12],o=e[13];return e[14],e[15],16===e.length?[t,r,n,B,s,o]:null}},eU={type:16,number:50,flags:4},ed=[eU,eU],eh={name:"transform-origin",initialValue:"50% 50%",prefix:!0,type:1,parse:function(A,e){var t=e.filter(isLengthPercentage);return 2!==t.length?ed:[t[0],t[1]]}},ep={name:"visible",initialValue:"none",prefix:!1,type:2,parse:function(A,e){switch(e){case"hidden":return 1;case"collapse":return 2;default:return 0}}};(a=p||(p={})).NORMAL="normal",a.BREAK_ALL="break-all",a.KEEP_ALL="keep-all";for(var ef={name:"word-break",initialValue:"normal",prefix:!1,type:2,parse:function(A,e){switch(e){case"break-all":return p.BREAK_ALL;case"keep-all":return p.KEEP_ALL;default:return p.NORMAL}}},eH={name:"z-index",initialValue:"auto",prefix:!1,type:0,parse:function(A,e){if(20===e.type)return{auto:!0,order:0};if(isNumberToken(e))return{auto:!1,order:e.number};throw Error("Invalid z-index number parsed")}},eE={name:"time",parse:function(A,e){if(15===e.type)switch(e.unit.toLowerCase()){case"s":return 1e3*e.number;case"ms":return e.number}throw Error("Unsupported time type")}},eI={name:"opacity",initialValue:"1",type:0,prefix:!1,parse:function(A,e){return isNumberToken(e)?e.number:1}},em={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,e){return e.filter(isIdentToken).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})}},eK={name:"font-family",initialValue:"",prefix:!1,type:1,parse:function(A,e){var t=[],r=[];return e.forEach(function(A){switch(A.type){case 20:case 0:t.push(A.value);break;case 17:t.push(A.number.toString());break;case 4:r.push(t.join(" ")),t.length=0}}),t.length&&r.push(t.join(" ")),r.map(function(A){return -1===A.indexOf(" ")?A:"'"+A+"'"})}},eL={name:"font-size",initialValue:"0",prefix:!1,type:3,format:"length"},eb={name:"font-weight",initialValue:"normal",type:0,prefix:!1,parse:function(A,e){return isNumberToken(e)?e.number:isIdentToken(e)&&"bold"===e.value?700:400}},ev={name:"font-variant",initialValue:"none",type:1,prefix:!1,parse:function(A,e){return e.filter(isIdentToken).map(function(A){return A.value})}},eS={name:"font-style",initialValue:"normal",prefix:!1,type:2,parse:function(A,e){switch(e){case"oblique":return"oblique";case"italic":return"italic";default:return"normal"}}},contains=function(A,e){return(A&e)!=0},eD={name:"content",initialValue:"none",type:1,prefix:!1,parse:function(A,e){if(0===e.length)return[];var t=e[0];return 20===t.type&&"none"===t.value?[]:e}},ex={name:"counter-increment",initialValue:"none",prefix:!0,type:1,parse:function(A,e){if(0===e.length)return null;var t=e[0];if(20===t.type&&"none"===t.value)return null;for(var r=[],n=e.filter(nonWhiteSpace),B=0;B<n.length;B++){var s=n[B],o=n[B+1];if(20===s.type){var i=o&&isNumberToken(o)?o.number:1;r.push({counter:s.value,increment:i})}}return r}},eT={name:"counter-reset",initialValue:"none",prefix:!0,type:1,parse:function(A,e){if(0===e.length)return[];for(var t=[],r=e.filter(nonWhiteSpace),n=0;n<r.length;n++){var B=r[n],s=r[n+1];if(isIdentToken(B)&&"none"!==B.value){var o=s&&isNumberToken(s)?s.number:0;t.push({counter:B.value,reset:o})}}return t}},eV={name:"duration",initialValue:"0s",prefix:!1,type:1,parse:function(A,e){return e.filter(isDimensionToken).map(function(e){return eE.parse(A,e)})}},eM={name:"quotes",initialValue:"none",prefix:!0,type:1,parse:function(A,e){if(0===e.length)return null;var t=e[0];if(20===t.type&&"none"===t.value)return null;var r=[],n=e.filter(isStringToken);if(n.length%2!=0)return null;for(var B=0;B<n.length;B+=2){var s=n[B].value,o=n[B+1].value;r.push({open:s,close:o})}return r}},getQuote=function(A,e,t){if(!A)return"";var r=A[Math.min(e,A.length-1)];return r?t?r.open:r.close:""},eG={name:"box-shadow",initialValue:"none",type:1,prefix:!1,parse:function(A,e){return 1===e.length&&isIdentWithValue(e[0],"none")?[]:parseFunctionArgs(e).map(function(e){for(var t={color:255,offsetX:Aw,offsetY:Aw,blur:Aw,spread:Aw,inset:!1},r=0,n=0;n<e.length;n++){var B=e[n];isIdentWithValue(B,"inset")?t.inset=!0:isLength(B)?(0===r?t.offsetX=B:1===r?t.offsetY=B:2===r?t.blur=B:t.spread=B,r++):t.color=Ah.parse(A,B)}return t})}},eO={name:"paint-order",initialValue:"normal",prefix:!1,type:1,parse:function(A,e){var t=[];return e.filter(isIdentToken).forEach(function(A){switch(A.value){case"stroke":t.push(1);break;case"fill":t.push(0);break;case"markers":t.push(2)}}),[0,1,2].forEach(function(A){-1===t.indexOf(A)&&t.push(A)}),t}},ek={name:"-webkit-text-stroke-color",initialValue:"currentcolor",prefix:!1,type:3,format:"color"},eP={name:"-webkit-text-stroke-width",initialValue:"0",type:0,prefix:!1,parse:function(A,e){return isDimensionToken(e)?e.number:0}},eR=function(){function CSSParsedDeclaration(A,e){this.animationDuration=parse(A,eV,e.animationDuration),this.backgroundClip=parse(A,AH,e.backgroundClip),this.backgroundColor=parse(A,AE,e.backgroundColor),this.backgroundImage=parse(A,AT,e.backgroundImage),this.backgroundOrigin=parse(A,AV,e.backgroundOrigin),this.backgroundPosition=parse(A,AM,e.backgroundPosition),this.backgroundRepeat=parse(A,AG,e.backgroundRepeat),this.backgroundSize=parse(A,AO,e.backgroundSize),this.borderTopColor=parse(A,Ak,e.borderTopColor),this.borderRightColor=parse(A,AP,e.borderRightColor),this.borderBottomColor=parse(A,AR,e.borderBottomColor),this.borderLeftColor=parse(A,AN,e.borderLeftColor),this.borderTopLeftRadius=parse(A,AJ,e.borderTopLeftRadius),this.borderTopRightRadius=parse(A,AX,e.borderTopRightRadius),this.borderBottomRightRadius=parse(A,AY,e.borderBottomRightRadius),this.borderBottomLeftRadius=parse(A,AW,e.borderBottomLeftRadius),this.borderTopStyle=parse(A,A_,e.borderTopStyle),this.borderRightStyle=parse(A,AZ,e.borderRightStyle),this.borderBottomStyle=parse(A,Az,e.borderBottomStyle),this.borderLeftStyle=parse(A,Aq,e.borderLeftStyle),this.borderTopWidth=parse(A,Aj,e.borderTopWidth),this.borderRightWidth=parse(A,A$,e.borderRightWidth),this.borderBottomWidth=parse(A,A0,e.borderBottomWidth),this.borderLeftWidth=parse(A,A4,e.borderLeftWidth),this.boxShadow=parse(A,eG,e.boxShadow),this.color=parse(A,A1,e.color),this.direction=parse(A,A2,e.direction),this.display=parse(A,A3,e.display),this.float=parse(A,A5,e.cssFloat),this.fontFamily=parse(A,eK,e.fontFamily),this.fontSize=parse(A,eL,e.fontSize),this.fontStyle=parse(A,eS,e.fontStyle),this.fontVariant=parse(A,ev,e.fontVariant),this.fontWeight=parse(A,eb,e.fontWeight),this.letterSpacing=parse(A,A6,e.letterSpacing),this.lineBreak=parse(A,A8,e.lineBreak),this.lineHeight=parse(A,A7,e.lineHeight),this.listStyleImage=parse(A,A9,e.listStyleImage),this.listStylePosition=parse(A,eA,e.listStylePosition),this.listStyleType=parse(A,ee,e.listStyleType),this.marginTop=parse(A,et,e.marginTop),this.marginRight=parse(A,er,e.marginRight),this.marginBottom=parse(A,en,e.marginBottom),this.marginLeft=parse(A,eB,e.marginLeft),this.opacity=parse(A,eI,e.opacity);var t,r,n=parse(A,es,e.overflow);this.overflowX=n[0],this.overflowY=n[n.length>1?1:0],this.overflowWrap=parse(A,eo,e.overflowWrap),this.paddingTop=parse(A,ei,e.paddingTop),this.paddingRight=parse(A,ea,e.paddingRight),this.paddingBottom=parse(A,ec,e.paddingBottom),this.paddingLeft=parse(A,eg,e.paddingLeft),this.paintOrder=parse(A,eO,e.paintOrder),this.position=parse(A,el,e.position),this.textAlign=parse(A,eQ,e.textAlign),this.textDecorationColor=parse(A,em,null!==(t=e.textDecorationColor)&&void 0!==t?t:e.color),this.textDecorationLine=parse(A,ey,null!==(r=e.textDecorationLine)&&void 0!==r?r:e.textDecoration),this.textShadow=parse(A,ew,e.textShadow),this.textTransform=parse(A,eu,e.textTransform),this.transform=parse(A,eC,e.transform),this.transformOrigin=parse(A,eh,e.transformOrigin),this.visibility=parse(A,ep,e.visibility),this.webkitTextStrokeColor=parse(A,ek,e.webkitTextStrokeColor),this.webkitTextStrokeWidth=parse(A,eP,e.webkitTextStrokeWidth),this.wordBreak=parse(A,ef,e.wordBreak),this.zIndex=parse(A,eH,e.zIndex)}return CSSParsedDeclaration.prototype.isVisible=function(){return this.display>0&&this.opacity>0&&0===this.visibility},CSSParsedDeclaration.prototype.isTransparent=function(){return isTransparent(this.backgroundColor)},CSSParsedDeclaration.prototype.isTransformed=function(){return null!==this.transform},CSSParsedDeclaration.prototype.isPositioned=function(){return 0!==this.position},CSSParsedDeclaration.prototype.isPositionedWithZIndex=function(){return this.isPositioned()&&!this.zIndex.auto},CSSParsedDeclaration.prototype.isFloating=function(){return 0!==this.float},CSSParsedDeclaration.prototype.isInlineLevel=function(){return contains(this.display,4)||contains(this.display,33554432)||contains(this.display,268435456)||contains(this.display,536870912)||contains(this.display,67108864)||contains(this.display,134217728)},CSSParsedDeclaration}(),CSSParsedPseudoDeclaration=function(A,e){this.content=parse(A,eD,e.content),this.quotes=parse(A,eM,e.quotes)},CSSParsedCounterDeclaration=function(A,e){this.counterIncrement=parse(A,ex,e.counterIncrement),this.counterReset=parse(A,eT,e.counterReset)},parse=function(A,e,t){var r=new AQ,n=null!=t?t.toString():e.initialValue;r.write(n);var B=new Al(r.read());switch(e.type){case 2:var s=B.parseComponentValue();return e.parse(A,isIdentToken(s)?s.value:e.initialValue);case 0:return e.parse(A,B.parseComponentValue());case 1:return e.parse(A,B.parseComponentValues());case 4:return B.parseComponentValue();case 3:switch(e.format){case"angle":return Ad.parse(A,B.parseComponentValue());case"color":return Ah.parse(A,B.parseComponentValue());case"image":return AD.parse(A,B.parseComponentValue());case"length":var o=B.parseComponentValue();return isLength(o)?o:Aw;case"length-percentage":var i=B.parseComponentValue();return isLengthPercentage(i)?i:Aw;case"time":return eE.parse(A,B.parseComponentValue())}}},getElementDebugType=function(A){switch(A.getAttribute("data-html2canvas-debug")){case"all":return 1;case"clone":return 2;case"parse":return 3;case"render":return 4;default:return 0}},isDebugging=function(A,e){var t=getElementDebugType(A);return 1===t||e===t},ElementContainer=function(A,e){this.context=A,this.textNodes=[],this.elements=[],this.flags=0,isDebugging(e,3),this.styles=new eR(A,window.getComputedStyle(e,null)),isHTMLElementNode(e)&&(this.styles.animationDuration.some(function(A){return A>0})&&(e.style.animationDuration="0s"),null!==this.styles.transform&&(e.style.transform="none")),this.bounds=parseBounds(this.context,e),isDebugging(e,4)&&(this.flags|=16)},eN="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",eJ="undefined"==typeof Uint8Array?[]:new Uint8Array(256),eX=0;eX<eN.length;eX++)eJ[eN.charCodeAt(eX)]=eX;for(var slice16=function(A,e,t){return A.slice?A.slice(e,t):new Uint16Array(Array.prototype.slice.call(A,e,t))},eY=function(){function Trie(A,e,t,r,n,B){this.initialValue=A,this.errorValue=e,this.highStart=t,this.highValueIndex=r,this.index=n,this.data=B}return Trie.prototype.get=function(A){var e;if(A>=0){if(A<55296||A>56319&&A<=65535)return e=((e=this.index[A>>5])<<2)+(31&A),this.data[e];if(A<=65535)return e=((e=this.index[2048+(A-55296>>5)])<<2)+(31&A),this.data[e];if(A<this.highStart)return e=2080+(A>>11),e=this.index[e]+(A>>5&63),e=((e=this.index[e])<<2)+(31&A),this.data[e];if(A<=1114111)return this.data[this.highValueIndex]}return this.errorValue},Trie}(),eW="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",e_="undefined"==typeof Uint8Array?[]:new Uint8Array(256),eZ=0;eZ<eW.length;eZ++)e_[eW.charCodeAt(eZ)]=eZ;var toCodePoints=function(A){for(var e=[],t=0,r=A.length;t<r;){var n=A.charCodeAt(t++);if(n>=55296&&n<=56319&&t<r){var B=A.charCodeAt(t++);(64512&B)==56320?e.push(((1023&n)<<10)+(1023&B)+65536):(e.push(n),t--)}else e.push(n)}return e},fromCodePoint=function(){for(var A=[],e=0;e<arguments.length;e++)A[e]=arguments[e];if(String.fromCodePoint)return String.fromCodePoint.apply(String,A);var t=A.length;if(!t)return"";for(var r=[],n=-1,B="";++n<t;){var s=A[n];s<=65535?r.push(s):(s-=65536,r.push((s>>10)+55296,s%1024+56320)),(n+1===t||r.length>16384)&&(B+=String.fromCharCode.apply(String,r),r.length=0)}return B},ez=(g=Array.isArray(c=function(A){var e,t,r,n,B,s=.75*A.length,o=A.length,i=0;"="===A[A.length-1]&&(s--,"="===A[A.length-2]&&s--);var a="undefined"!=typeof ArrayBuffer&&"undefined"!=typeof Uint8Array&&void 0!==Uint8Array.prototype.slice?new ArrayBuffer(s):Array(s),c=Array.isArray(a)?a:new Uint8Array(a);for(e=0;e<o;e+=4)t=eJ[A.charCodeAt(e)],r=eJ[A.charCodeAt(e+1)],n=eJ[A.charCodeAt(e+2)],B=eJ[A.charCodeAt(e+3)],c[i++]=t<<2|r>>4,c[i++]=(15&r)<<4|n>>2,c[i++]=(3&n)<<6|63&B;return a}(" "))?function(A){for(var e=A.length,t=[],r=0;r<e;r+=4)t.push(A[r+3]<<24|A[r+2]<<16|A[r+1]<<8|A[r]);return t}(c):new Uint32Array(c),l=slice16(Q=Array.isArray(c)?function(A){for(var e=A.length,t=[],r=0;r<e;r+=2)t.push(A[r+1]<<8|A[r]);return t}(c):new Uint16Array(c),12,g[4]/2),C=2===g[5]?slice16(Q,(24+g[4])/2):(w=Math.ceil((24+g[4])/4),g.slice?g.slice(w,u):new Uint32Array(Array.prototype.slice.call(g,w,u))),new eY(g[0],g[1],g[2],g[3],l,C)),codePointToClass=function(A){return ez.get(A)},_graphemeBreakAtIndex=function(A,e,t){var r=t-2,n=e[r],B=e[t-1],s=e[t];if(2===B&&3===s)return"\xd7";if(2===B||3===B||4===B||2===s||3===s||4===s)return"\xf7";if(8===B&&-1!==[8,9,11,12].indexOf(s)||(11===B||9===B)&&(9===s||10===s)||(12===B||10===B)&&10===s||13===s||5===s||7===s||1===B)return"\xd7";if(13===B&&14===s){for(;5===n;)n=e[--r];if(14===n)return"\xd7"}if(15===B&&15===s){for(var o=0;15===n;)o++,n=e[--r];if(o%2==0)return"\xd7"}return"\xf7"},GraphemeBreaker=function(A){var e=toCodePoints(A),t=e.length,r=0,n=0,B=e.map(codePointToClass);return{next:function(){if(r>=t)return{done:!0,value:null};for(var A="\xd7";r<t&&"\xd7"===(A=_graphemeBreakAtIndex(e,B,++r)););if("\xd7"!==A||r===t){var s=fromCodePoint.apply(null,e.slice(n,r));return n=r,{value:s,done:!1}}return{done:!0,value:null}}}},splitGraphemes=function(A){for(var e,t=GraphemeBreaker(A),r=[];!(e=t.next()).done;)e.value&&r.push(e.value.slice());return r},testRangeBounds=function(A){if(A.createRange){var e=A.createRange();if(e.getBoundingClientRect){var t=A.createElement("boundtest");t.style.height="123px",t.style.display="block",A.body.appendChild(t),e.selectNode(t);var r=Math.round(e.getBoundingClientRect().height);if(A.body.removeChild(t),123===r)return!0}}return!1},testIOSLineBreak=function(A){var e=A.createElement("boundtest");e.style.width="50px",e.style.display="block",e.style.fontSize="12px",e.style.letterSpacing="0px",e.style.wordSpacing="0px",A.body.appendChild(e);var t=A.createRange();e.innerHTML="function"==typeof"".repeat?"&#128104;".repeat(10):"";var r=e.firstChild,n=toCodePoints$1(r.data).map(function(A){return fromCodePoint$1(A)}),B=0,s={},o=n.every(function(A,e){t.setStart(r,B),t.setEnd(r,B+A.length);var n=t.getBoundingClientRect();B+=A.length;var o=n.x>s.x||n.y>s.y;return s=n,0===e||o});return A.body.removeChild(e),o},testSVG=function(A){var e=new Image,t=A.createElement("canvas"),r=t.getContext("2d");if(!r)return!1;e.src="data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg'></svg>";try{r.drawImage(e,0,0),t.toDataURL()}catch(A){return!1}return!0},isGreenPixel=function(A){return 0===A[0]&&255===A[1]&&0===A[2]&&255===A[3]},testForeignObject=function(A){var e=A.createElement("canvas");e.width=100,e.height=100;var t=e.getContext("2d");if(!t)return Promise.reject(!1);t.fillStyle="rgb(0, 255, 0)",t.fillRect(0,0,100,100);var r=new Image,n=e.toDataURL();r.src=n;var B=createForeignObjectSVG(100,100,0,0,r);return t.fillStyle="red",t.fillRect(0,0,100,100),loadSerializedSVG$1(B).then(function(e){t.drawImage(e,0,0);var r=t.getImageData(0,0,100,100).data;t.fillStyle="red",t.fillRect(0,0,100,100);var B=A.createElement("div");return B.style.backgroundImage="url("+n+")",B.style.height="100px",isGreenPixel(r)?loadSerializedSVG$1(createForeignObjectSVG(100,100,0,0,B)):Promise.reject(!1)}).then(function(A){return t.drawImage(A,0,0),isGreenPixel(t.getImageData(0,0,100,100).data)}).catch(function(){return!1})},createForeignObjectSVG=function(A,e,t,r,n){var B="http://www.w3.org/2000/svg",s=document.createElementNS(B,"svg"),o=document.createElementNS(B,"foreignObject");return s.setAttributeNS(null,"width",A.toString()),s.setAttributeNS(null,"height",e.toString()),o.setAttributeNS(null,"width","100%"),o.setAttributeNS(null,"height","100%"),o.setAttributeNS(null,"x",t.toString()),o.setAttributeNS(null,"y",r.toString()),o.setAttributeNS(null,"externalResourcesRequired","true"),s.appendChild(o),o.appendChild(n),s},loadSerializedSVG$1=function(A){return new Promise(function(e,t){var r=new Image;r.onload=function(){return e(r)},r.onerror=t,r.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(new XMLSerializer().serializeToString(A))})},eq={get SUPPORT_RANGE_BOUNDS(){var ej=testRangeBounds(document);return Object.defineProperty(eq,"SUPPORT_RANGE_BOUNDS",{value:ej}),ej},get SUPPORT_WORD_BREAKING(){var e$=eq.SUPPORT_RANGE_BOUNDS&&testIOSLineBreak(document);return Object.defineProperty(eq,"SUPPORT_WORD_BREAKING",{value:e$}),e$},get SUPPORT_SVG_DRAWING(){var e0=testSVG(document);return Object.defineProperty(eq,"SUPPORT_SVG_DRAWING",{value:e0}),e0},get SUPPORT_FOREIGNOBJECT_DRAWING(){var e4="function"==typeof Array.from&&"function"==typeof window.fetch?testForeignObject(document):Promise.resolve(!1);return Object.defineProperty(eq,"SUPPORT_FOREIGNOBJECT_DRAWING",{value:e4}),e4},get SUPPORT_CORS_IMAGES(){var e1=void 0!==new Image().crossOrigin;return Object.defineProperty(eq,"SUPPORT_CORS_IMAGES",{value:e1}),e1},get SUPPORT_RESPONSE_TYPE(){var e2="string"==typeof new XMLHttpRequest().responseType;return Object.defineProperty(eq,"SUPPORT_RESPONSE_TYPE",{value:e2}),e2},get SUPPORT_CORS_XHR(){var e3="withCredentials"in new XMLHttpRequest;return Object.defineProperty(eq,"SUPPORT_CORS_XHR",{value:e3}),e3},get SUPPORT_NATIVE_TEXT_SEGMENTATION(){var e5=!!("undefined"!=typeof Intl&&Intl.Segmenter);return Object.defineProperty(eq,"SUPPORT_NATIVE_TEXT_SEGMENTATION",{value:e5}),e5}},TextBounds=function(A,e){this.text=A,this.bounds=e},parseTextBounds=function(A,e,t,r){var n=breakText(e,t),B=[],s=0;return n.forEach(function(e){if(t.textDecorationLine.length||e.trim().length>0){if(eq.SUPPORT_RANGE_BOUNDS){var n=createRange(r,s,e.length).getClientRects();if(n.length>1){var o=segmentGraphemes(e),i=0;o.forEach(function(e){B.push(new TextBounds(e,E.fromDOMRectList(A,createRange(r,i+s,e.length).getClientRects()))),i+=e.length})}else B.push(new TextBounds(e,E.fromDOMRectList(A,n)))}else{var a=r.splitText(e.length);B.push(new TextBounds(e,getWrapperBounds(A,r))),r=a}}else eq.SUPPORT_RANGE_BOUNDS||(r=r.splitText(e.length));s+=e.length}),B},getWrapperBounds=function(A,e){var t=e.ownerDocument;if(t){var r=t.createElement("html2canvaswrapper");r.appendChild(e.cloneNode(!0));var n=e.parentNode;if(n){n.replaceChild(r,e);var B=parseBounds(A,r);return r.firstChild&&n.replaceChild(r.firstChild,r),B}}return E.EMPTY},createRange=function(A,e,t){var r=A.ownerDocument;if(!r)throw Error("Node has no owner document");var n=r.createRange();return n.setStart(A,e),n.setEnd(A,e+t),n},segmentGraphemes=function(A){return eq.SUPPORT_NATIVE_TEXT_SEGMENTATION?Array.from(new Intl.Segmenter(void 0,{granularity:"grapheme"}).segment(A)).map(function(A){return A.segment}):splitGraphemes(A)},breakText=function(A,e){return 0!==e.letterSpacing?segmentGraphemes(A):eq.SUPPORT_NATIVE_TEXT_SEGMENTATION?Array.from(new Intl.Segmenter(void 0,{granularity:"word"}).segment(A)).map(function(A){return A.segment}):breakWords(A,e)},e6=[32,160,4961,65792,65793,4153,4241],breakWords=function(A,e){for(var t,r=LineBreaker(A,{lineBreak:e.lineBreak,wordBreak:"break-word"===e.overflowWrap?"break-word":e.wordBreak}),n=[];!(t=r.next()).done;)!function(){if(t.value){var A=toCodePoints$1(t.value.slice()),e="";A.forEach(function(A){-1===e6.indexOf(A)?e+=fromCodePoint$1(A):(e.length&&n.push(e),n.push(fromCodePoint$1(A)),e="")}),e.length&&n.push(e)}}();return n},TextContainer=function(A,e,t){this.text=transform(e.data,t.textTransform),this.textBounds=parseTextBounds(A,this.text,t,e)},transform=function(A,e){switch(e){case 1:return A.toLowerCase();case 3:return A.replace(e8,capitalize);case 2:return A.toUpperCase();default:return A}},e8=/(^|\s|:|-|\(|\))([a-z])/g,capitalize=function(A,e,t){return A.length>0?e+t.toUpperCase():A},e7=function(A){function ImageElementContainer(e,t){var r=A.call(this,e,t)||this;return r.src=t.currentSrc||t.src,r.intrinsicWidth=t.naturalWidth,r.intrinsicHeight=t.naturalHeight,r.context.cache.addImage(r.src),r}return __extends(ImageElementContainer,A),ImageElementContainer}(ElementContainer),e9=function(A){function CanvasElementContainer(e,t){var r=A.call(this,e,t)||this;return r.canvas=t,r.intrinsicWidth=t.width,r.intrinsicHeight=t.height,r}return __extends(CanvasElementContainer,A),CanvasElementContainer}(ElementContainer),tA=function(A){function SVGElementContainer(e,t){var r=A.call(this,e,t)||this,n=new XMLSerializer,B=parseBounds(e,t);return t.setAttribute("width",B.width+"px"),t.setAttribute("height",B.height+"px"),r.svg="data:image/svg+xml,"+encodeURIComponent(n.serializeToString(t)),r.intrinsicWidth=t.width.baseVal.value,r.intrinsicHeight=t.height.baseVal.value,r.context.cache.addImage(r.svg),r}return __extends(SVGElementContainer,A),SVGElementContainer}(ElementContainer),te=function(A){function LIElementContainer(e,t){var r=A.call(this,e,t)||this;return r.value=t.value,r}return __extends(LIElementContainer,A),LIElementContainer}(ElementContainer),tt=function(A){function OLElementContainer(e,t){var r=A.call(this,e,t)||this;return r.start=t.start,r.reversed="boolean"==typeof t.reversed&&!0===t.reversed,r}return __extends(OLElementContainer,A),OLElementContainer}(ElementContainer),tr=[{type:15,flags:0,unit:"px",number:3}],tn=[{type:16,flags:0,number:50}],getInputValue=function(A){var e=A.type===to?Array(A.value.length+1).join("•"):A.value;return 0===e.length?A.placeholder||"":e},tB="checkbox",ts="radio",to="password",ti=function(A){function InputElementContainer(e,t){var r,n=A.call(this,e,t)||this;switch(n.type=t.type.toLowerCase(),n.checked=t.checked,n.value=getInputValue(t),(n.type===tB||n.type===ts)&&(n.styles.backgroundColor=3739148031,n.styles.borderTopColor=n.styles.borderRightColor=n.styles.borderBottomColor=n.styles.borderLeftColor=2779096575,n.styles.borderTopWidth=n.styles.borderRightWidth=n.styles.borderBottomWidth=n.styles.borderLeftWidth=1,n.styles.borderTopStyle=n.styles.borderRightStyle=n.styles.borderBottomStyle=n.styles.borderLeftStyle=1,n.styles.backgroundClip=[0],n.styles.backgroundOrigin=[0],n.bounds=(r=n.bounds).width>r.height?new E(r.left+(r.width-r.height)/2,r.top,r.height,r.height):r.width<r.height?new E(r.left,r.top+(r.height-r.width)/2,r.width,r.width):r),n.type){case tB:n.styles.borderTopRightRadius=n.styles.borderTopLeftRadius=n.styles.borderBottomRightRadius=n.styles.borderBottomLeftRadius=tr;break;case ts:n.styles.borderTopRightRadius=n.styles.borderTopLeftRadius=n.styles.borderBottomRightRadius=n.styles.borderBottomLeftRadius=tn}return n}return __extends(InputElementContainer,A),InputElementContainer}(ElementContainer),ta=function(A){function SelectElementContainer(e,t){var r=A.call(this,e,t)||this,n=t.options[t.selectedIndex||0];return r.value=n&&n.text||"",r}return __extends(SelectElementContainer,A),SelectElementContainer}(ElementContainer),tc=function(A){function TextareaElementContainer(e,t){var r=A.call(this,e,t)||this;return r.value=t.value,r}return __extends(TextareaElementContainer,A),TextareaElementContainer}(ElementContainer),tg=function(A){function IFrameElementContainer(e,t){var r=A.call(this,e,t)||this;r.src=t.src,r.width=parseInt(t.width,10)||0,r.height=parseInt(t.height,10)||0,r.backgroundColor=r.styles.backgroundColor;try{if(t.contentWindow&&t.contentWindow.document&&t.contentWindow.document.documentElement){r.tree=parseTree(e,t.contentWindow.document.documentElement);var n=t.contentWindow.document.documentElement?parseColor(e,getComputedStyle(t.contentWindow.document.documentElement).backgroundColor):Af.TRANSPARENT,B=t.contentWindow.document.body?parseColor(e,getComputedStyle(t.contentWindow.document.body).backgroundColor):Af.TRANSPARENT;r.backgroundColor=isTransparent(n)?isTransparent(B)?r.styles.backgroundColor:B:n}}catch(A){}return r}return __extends(IFrameElementContainer,A),IFrameElementContainer}(ElementContainer),tQ=["OL","UL","MENU"],parseNodeTree=function(A,e,t,r){for(var n=e.firstChild,B=void 0;n;n=B)if(B=n.nextSibling,isTextNode(n)&&n.data.trim().length>0)t.textNodes.push(new TextContainer(A,n,t.styles));else if(isElementNode(n)){if(isSlotElement(n)&&n.assignedNodes)n.assignedNodes().forEach(function(e){return parseNodeTree(A,e,t,r)});else{var s=createContainer(A,n);!s.styles.isVisible()||(createsRealStackingContext(n,s,r)?s.flags|=4:createsStackingContext(s.styles)&&(s.flags|=2),-1!==tQ.indexOf(n.tagName)&&(s.flags|=8),t.elements.push(s),n.slot,n.shadowRoot?parseNodeTree(A,n.shadowRoot,s,r):isTextareaElement(n)||isSVGElement(n)||isSelectElement(n)||parseNodeTree(A,n,s,r))}}},createContainer=function(A,e){return isImageElement(e)?new e7(A,e):isCanvasElement(e)?new e9(A,e):isSVGElement(e)?new tA(A,e):isLIElement(e)?new te(A,e):isOLElement(e)?new tt(A,e):isInputElement(e)?new ti(A,e):isSelectElement(e)?new ta(A,e):isTextareaElement(e)?new tc(A,e):isIFrameElement(e)?new tg(A,e):new ElementContainer(A,e)},parseTree=function(A,e){var t=createContainer(A,e);return t.flags|=4,parseNodeTree(A,e,t,t),t},createsRealStackingContext=function(A,e,t){return e.styles.isPositionedWithZIndex()||e.styles.opacity<1||e.styles.isTransformed()||isBodyElement(A)&&t.styles.isTransparent()},createsStackingContext=function(A){return A.isPositioned()||A.isFloating()},isTextNode=function(A){return A.nodeType===Node.TEXT_NODE},isElementNode=function(A){return A.nodeType===Node.ELEMENT_NODE},isHTMLElementNode=function(A){return isElementNode(A)&&void 0!==A.style&&!isSVGElementNode(A)},isSVGElementNode=function(A){return"object"==typeof A.className},isLIElement=function(A){return"LI"===A.tagName},isOLElement=function(A){return"OL"===A.tagName},isInputElement=function(A){return"INPUT"===A.tagName},isSVGElement=function(A){return"svg"===A.tagName},isBodyElement=function(A){return"BODY"===A.tagName},isCanvasElement=function(A){return"CANVAS"===A.tagName},isVideoElement=function(A){return"VIDEO"===A.tagName},isImageElement=function(A){return"IMG"===A.tagName},isIFrameElement=function(A){return"IFRAME"===A.tagName},isStyleElement=function(A){return"STYLE"===A.tagName},isTextareaElement=function(A){return"TEXTAREA"===A.tagName},isSelectElement=function(A){return"SELECT"===A.tagName},isSlotElement=function(A){return"SLOT"===A.tagName},isCustomElement=function(A){return A.tagName.indexOf("-")>0},tl=function(){function CounterState(){this.counters={}}return CounterState.prototype.getCounterValue=function(A){var e=this.counters[A];return e&&e.length?e[e.length-1]:1},CounterState.prototype.getCounterValues=function(A){return this.counters[A]||[]},CounterState.prototype.pop=function(A){var e=this;A.forEach(function(A){return e.counters[A].pop()})},CounterState.prototype.parse=function(A){var e=this,t=A.counterIncrement,r=A.counterReset,n=!0;null!==t&&t.forEach(function(A){var t=e.counters[A.counter];t&&0!==A.increment&&(n=!1,t.length||t.push(1),t[Math.max(0,t.length-1)]+=A.increment)});var B=[];return n&&r.forEach(function(A){var t=e.counters[A.counter];B.push(A.counter),t||(t=e.counters[A.counter]=[]),t.push(A.reset)}),B},CounterState}(),tw={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"]},tu={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:["Ք","Փ","Ւ","Ց","Ր","Տ","Վ","Ս","Ռ","Ջ","Պ","Չ","Ո","Շ","Ն","Յ","Մ","Ճ","Ղ","Ձ","Հ","Կ","Ծ","Խ","Լ","Ի","Ժ","Թ","Ը","Է","Զ","Ե","Դ","Գ","Բ","Ա"]},tC={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:["י׳","ט׳","ח׳","ז׳","ו׳","ה׳","ד׳","ג׳","ב׳","א׳","ת","ש","ר","ק","צ","פ","ע","ס","נ","מ","ל","כ","יט","יח","יז","טז","טו","י","ט","ח","ז","ו","ה","ד","ג","ב","א"]},tF={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:["ჵ","ჰ","ჯ","ჴ","ხ","ჭ","წ","ძ","ც","ჩ","შ","ყ","ღ","ქ","ფ","ჳ","ტ","ს","რ","ჟ","პ","ო","ჲ","ნ","მ","ლ","კ","ი","თ","ჱ","ზ","ვ","ე","დ","გ","ბ","ა"]},createAdditiveCounter=function(A,e,t,r,n,B){return A<e||A>t?createCounterText(A,n,B.length>0):r.integers.reduce(function(e,t,n){for(;A>=t;)A-=t,e+=r.values[n];return e},"")+B},createCounterStyleWithSymbolResolver=function(A,e,t,r){var n="";do!t&&A--,n=r(A)+n,A/=e;while(A*e>=e);return n},createCounterStyleFromRange=function(A,e,t,r,n){var B=t-e+1;return(A<0?"-":"")+(createCounterStyleWithSymbolResolver(Math.abs(A),B,r,function(A){return fromCodePoint$1(Math.floor(A%B)+e)})+n)},createCounterStyleFromSymbols=function(A,e,t){void 0===t&&(t=". ");var r=e.length;return createCounterStyleWithSymbolResolver(Math.abs(A),r,!1,function(A){return e[Math.floor(A%r)]})+t},createCJKCounter=function(A,e,t,r,n,B){if(A<-9999||A>9999)return createCounterText(A,4,n.length>0);var s=Math.abs(A),o=n;if(0===s)return e[0]+o;for(var i=0;s>0&&i<=4;i++){var a=s%10;0===a&&contains(B,1)&&""!==o?o=e[a]+o:a>1||1===a&&0===i||1===a&&1===i&&contains(B,2)||1===a&&1===i&&contains(B,4)&&A>100||1===a&&i>1&&contains(B,8)?o=e[a]+(i>0?t[i-1]:"")+o:1===a&&i>0&&(o=t[i-1]+o),s=Math.floor(s/10)}return(A<0?r:"")+o},tU="十百千萬",td="拾佰仟萬",th="マイナス",tp="마이너스",createCounterText=function(A,e,t){var r=t?". ":"",n=t?"、":"",B=t?", ":"",s=t?" ":"";switch(e){case 0:return"•"+s;case 1:return"◦"+s;case 2:return"◾"+s;case 5:var o=createCounterStyleFromRange(A,48,57,!0,r);return o.length<4?"0"+o:o;case 4:return createCounterStyleFromSymbols(A,"〇一二三四五六七八九",n);case 6:return createAdditiveCounter(A,1,3999,tw,3,r).toLowerCase();case 7:return createAdditiveCounter(A,1,3999,tw,3,r);case 8:return createCounterStyleFromRange(A,945,969,!1,r);case 9:return createCounterStyleFromRange(A,97,122,!1,r);case 10:return createCounterStyleFromRange(A,65,90,!1,r);case 11:return createCounterStyleFromRange(A,1632,1641,!0,r);case 12:case 49:return createAdditiveCounter(A,1,9999,tu,3,r);case 35:return createAdditiveCounter(A,1,9999,tu,3,r).toLowerCase();case 13:return createCounterStyleFromRange(A,2534,2543,!0,r);case 14:case 30:return createCounterStyleFromRange(A,6112,6121,!0,r);case 15:return createCounterStyleFromSymbols(A,"子丑寅卯辰巳午未申酉戌亥",n);case 16:return createCounterStyleFromSymbols(A,"甲乙丙丁戊己庚辛壬癸",n);case 17:case 48:return createCJKCounter(A,"零一二三四五六七八九",tU,"負",n,14);case 47:return createCJKCounter(A,"零壹貳參肆伍陸柒捌玖",td,"負",n,15);case 42:return createCJKCounter(A,"零一二三四五六七八九",tU,"负",n,14);case 41:return createCJKCounter(A,"零壹贰叁肆伍陆柒捌玖",td,"负",n,15);case 26:return createCJKCounter(A,"〇一二三四五六七八九","十百千万",th,n,0);case 25:return createCJKCounter(A,"零壱弐参四伍六七八九","拾百千万",th,n,7);case 31:return createCJKCounter(A,"영일이삼사오육칠팔구","십백천만",tp,B,7);case 33:return createCJKCounter(A,"零一二三四五六七八九","十百千萬",tp,B,0);case 32:return createCJKCounter(A,"零壹貳參四五六七八九","拾百千",tp,B,7);case 18:return createCounterStyleFromRange(A,2406,2415,!0,r);case 20:return createAdditiveCounter(A,1,19999,tF,3,r);case 21:return createCounterStyleFromRange(A,2790,2799,!0,r);case 22:return createCounterStyleFromRange(A,2662,2671,!0,r);case 22:return createAdditiveCounter(A,1,10999,tC,3,r);case 23:return createCounterStyleFromSymbols(A,"あいうえおかきくけこさしすせそたちつてとなにぬねのはひふへほまみむめもやゆよらりるれろわゐゑをん");case 24:return createCounterStyleFromSymbols(A,"いろはにほへとちりぬるをわかよたれそつねならむうゐのおくやまけふこえてあさきゆめみしゑひもせす");case 27:return createCounterStyleFromRange(A,3302,3311,!0,r);case 28:return createCounterStyleFromSymbols(A,"アイウエオカキクケコサシスセソタチツテトナニヌネノハヒフヘホマミムメモヤユヨラリルレロワヰヱヲン",n);case 29:return createCounterStyleFromSymbols(A,"イロハニホヘトチリヌルヲワカヨタレソツネナラムウヰノオクヤマケフコエテアサキユメミシヱヒモセス",n);case 34:return createCounterStyleFromRange(A,3792,3801,!0,r);case 37:return createCounterStyleFromRange(A,6160,6169,!0,r);case 38:return createCounterStyleFromRange(A,4160,4169,!0,r);case 39:return createCounterStyleFromRange(A,2918,2927,!0,r);case 40:return createCounterStyleFromRange(A,1776,1785,!0,r);case 43:return createCounterStyleFromRange(A,3046,3055,!0,r);case 44:return createCounterStyleFromRange(A,3174,3183,!0,r);case 45:return createCounterStyleFromRange(A,3664,3673,!0,r);case 46:return createCounterStyleFromRange(A,3872,3881,!0,r);default:return createCounterStyleFromRange(A,48,57,!0,r)}},tf="data-html2canvas-ignore",tH=function(){function DocumentCloner(A,e,t){if(this.context=A,this.options=t,this.scrolledElements=[],this.referenceElement=e,this.counters=new tl,this.quoteDepth=0,!e.ownerDocument)throw Error("Cloned element does not have an owner document");this.documentElement=this.cloneNode(e.ownerDocument.documentElement,!1)}return DocumentCloner.prototype.toIFrame=function(A,e){var t=this,r=createIFrameContainer(A,e);if(!r.contentWindow)return Promise.reject("Unable to find iframe window");var n=A.defaultView.pageXOffset,B=A.defaultView.pageYOffset,s=r.contentWindow,o=s.document,i=iframeLoader(r).then(function(){return __awaiter(t,void 0,void 0,function(){var A,t;return __generator(this,function(n){switch(n.label){case 0:if(this.scrolledElements.forEach(restoreNodeScroll),s&&(s.scrollTo(e.left,e.top),/(iPad|iPhone|iPod)/g.test(navigator.userAgent)&&(s.scrollY!==e.top||s.scrollX!==e.left)&&(this.context.logger.warn("Unable to restore scroll position for cloned document"),this.context.windowBounds=this.context.windowBounds.add(s.scrollX-e.left,s.scrollY-e.top,0,0))),A=this.options.onclone,void 0===(t=this.clonedReferenceElement))return[2,Promise.reject("Error finding the "+this.referenceElement.nodeName+" in the cloned document")];if(!(o.fonts&&o.fonts.ready))return[3,2];return[4,o.fonts.ready];case 1:n.sent(),n.label=2;case 2:if(!/(AppleWebKit)/g.test(navigator.userAgent))return[3,4];return[4,imagesReady(o)];case 3:n.sent(),n.label=4;case 4:if("function"==typeof A)return[2,Promise.resolve().then(function(){return A(o,t)}).then(function(){return r})];return[2,r]}})})});return o.open(),o.write(serializeDoctype(document.doctype)+"<html></html>"),restoreOwnerScroll(this.referenceElement.ownerDocument,n,B),o.replaceChild(o.adoptNode(this.documentElement),o.documentElement),o.close(),i},DocumentCloner.prototype.createElementClone=function(A){if(isDebugging(A,2),isCanvasElement(A))return this.createCanvasClone(A);if(isVideoElement(A))return this.createVideoClone(A);if(isStyleElement(A))return this.createStyleClone(A);var e=A.cloneNode(!1);return(isImageElement(e)&&(isImageElement(A)&&A.currentSrc&&A.currentSrc!==A.src&&(e.src=A.currentSrc,e.srcset=""),"lazy"===e.loading&&(e.loading="eager")),isCustomElement(e))?this.createCustomElementClone(e):e},DocumentCloner.prototype.createCustomElementClone=function(A){var e=document.createElement("html2canvascustomelement");return copyCSSStyles(A.style,e),e},DocumentCloner.prototype.createStyleClone=function(A){try{var e=A.sheet;if(e&&e.cssRules){var t=[].slice.call(e.cssRules,0).reduce(function(A,e){return e&&"string"==typeof e.cssText?A+e.cssText:A},""),r=A.cloneNode(!1);return r.textContent=t,r}}catch(A){if(this.context.logger.error("Unable to access cssRules property",A),"SecurityError"!==A.name)throw A}return A.cloneNode(!1)},DocumentCloner.prototype.createCanvasClone=function(A){if(this.options.inlineImages&&A.ownerDocument){var e,t=A.ownerDocument.createElement("img");try{return t.src=A.toDataURL(),t}catch(e){this.context.logger.info("Unable to inline canvas contents, canvas is tainted",A)}}var r=A.cloneNode(!1);try{r.width=A.width,r.height=A.height;var n=A.getContext("2d"),B=r.getContext("2d");if(B){if(!this.options.allowTaint&&n)B.putImageData(n.getImageData(0,0,A.width,A.height),0,0);else{var s=null!==(e=A.getContext("webgl2"))&&void 0!==e?e:A.getContext("webgl");if(s){var o=s.getContextAttributes();(null==o?void 0:o.preserveDrawingBuffer)===!1&&this.context.logger.warn("Unable to clone WebGL context as it has preserveDrawingBuffer=false",A)}B.drawImage(A,0,0)}}}catch(e){this.context.logger.info("Unable to clone canvas as it is tainted",A)}return r},DocumentCloner.prototype.createVideoClone=function(A){var e=A.ownerDocument.createElement("canvas");e.width=A.offsetWidth,e.height=A.offsetHeight;var t=e.getContext("2d");try{return t&&(t.drawImage(A,0,0,e.width,e.height),this.options.allowTaint||t.getImageData(0,0,e.width,e.height)),e}catch(e){this.context.logger.info("Unable to clone video as it is tainted",A)}var r=A.ownerDocument.createElement("canvas");return r.width=A.offsetWidth,r.height=A.offsetHeight,r},DocumentCloner.prototype.appendChildNode=function(A,e,t){(!isElementNode(e)||"SCRIPT"!==e.tagName&&!e.hasAttribute(tf)&&("function"!=typeof this.options.ignoreElements||!this.options.ignoreElements(e)))&&(this.options.copyStyles&&isElementNode(e)&&isStyleElement(e)||A.appendChild(this.cloneNode(e,t)))},DocumentCloner.prototype.cloneChildNodes=function(A,e,t){for(var r=this,n=A.shadowRoot?A.shadowRoot.firstChild:A.firstChild;n;n=n.nextSibling)if(isElementNode(n)&&isSlotElement(n)&&"function"==typeof n.assignedNodes){var B=n.assignedNodes();B.length&&B.forEach(function(A){return r.appendChildNode(e,A,t)})}else this.appendChildNode(e,n,t)},DocumentCloner.prototype.cloneNode=function(A,e){if(isTextNode(A))return document.createTextNode(A.data);if(!A.ownerDocument)return A.cloneNode(!1);var t=A.ownerDocument.defaultView;if(t&&isElementNode(A)&&(isHTMLElementNode(A)||isSVGElementNode(A))){var r=this.createElementClone(A);r.style.transitionProperty="none";var n=t.getComputedStyle(A),B=t.getComputedStyle(A,":before"),s=t.getComputedStyle(A,":after");this.referenceElement===A&&isHTMLElementNode(r)&&(this.clonedReferenceElement=r),isBodyElement(r)&&createPseudoHideStyles(r);var o=this.counters.parse(new CSSParsedCounterDeclaration(this.context,n)),i=this.resolvePseudoContent(A,r,B,f.BEFORE);isCustomElement(A)&&(e=!0),isVideoElement(A)||this.cloneChildNodes(A,r,e),i&&r.insertBefore(i,r.firstChild);var a=this.resolvePseudoContent(A,r,s,f.AFTER);return a&&r.appendChild(a),this.counters.pop(o),(n&&(this.options.copyStyles||isSVGElementNode(A))&&!isIFrameElement(A)||e)&&copyCSSStyles(n,r),(0!==A.scrollTop||0!==A.scrollLeft)&&this.scrolledElements.push([r,A.scrollLeft,A.scrollTop]),(isTextareaElement(A)||isSelectElement(A))&&(isTextareaElement(r)||isSelectElement(r))&&(r.value=A.value),r}return A.cloneNode(!1)},DocumentCloner.prototype.resolvePseudoContent=function(A,e,t,r){var n=this;if(t){var B=t.content,s=e.ownerDocument;if(s&&B&&"none"!==B&&"-moz-alt-content"!==B&&"none"!==t.display){this.counters.parse(new CSSParsedCounterDeclaration(this.context,t));var o=new CSSParsedPseudoDeclaration(this.context,t),i=s.createElement("html2canvaspseudoelement");copyCSSStyles(t,i),o.content.forEach(function(e){if(0===e.type)i.appendChild(s.createTextNode(e.value));else if(22===e.type){var t=s.createElement("img");t.src=e.value,t.style.opacity="1",i.appendChild(t)}else if(18===e.type){if("attr"===e.name){var r=e.values.filter(isIdentToken);r.length&&i.appendChild(s.createTextNode(A.getAttribute(r[0].value)||""))}else if("counter"===e.name){var B=e.values.filter(nonFunctionArgSeparator),a=B[0],c=B[1];if(a&&isIdentToken(a)){var g=n.counters.getCounterValue(a.value),Q=c&&isIdentToken(c)?ee.parse(n.context,c.value):3;i.appendChild(s.createTextNode(createCounterText(g,Q,!1)))}}else if("counters"===e.name){var l=e.values.filter(nonFunctionArgSeparator),a=l[0],w=l[1],c=l[2];if(a&&isIdentToken(a)){var u=n.counters.getCounterValues(a.value),C=c&&isIdentToken(c)?ee.parse(n.context,c.value):3,F=w&&0===w.type?w.value:"",U=u.map(function(A){return createCounterText(A,C,!1)}).join(F);i.appendChild(s.createTextNode(U))}}}else if(20===e.type)switch(e.value){case"open-quote":i.appendChild(s.createTextNode(getQuote(o.quotes,n.quoteDepth++,!0)));break;case"close-quote":i.appendChild(s.createTextNode(getQuote(o.quotes,--n.quoteDepth,!1)));break;default:i.appendChild(s.createTextNode(e.value))}}),i.className=tI+" "+tm;var a=r===f.BEFORE?" "+tI:" "+tm;return isSVGElementNode(e)?e.className.baseValue+=a:e.className+=a,i}}},DocumentCloner.destroy=function(A){return!!A.parentNode&&(A.parentNode.removeChild(A),!0)},DocumentCloner}();(F=f||(f={}))[F.BEFORE=0]="BEFORE",F[F.AFTER=1]="AFTER";var createIFrameContainer=function(A,e){var t=A.createElement("iframe");return t.className="html2canvas-container",t.style.visibility="hidden",t.style.position="fixed",t.style.left="-10000px",t.style.top="0px",t.style.border="0",t.width=e.width.toString(),t.height=e.height.toString(),t.scrolling="no",t.setAttribute(tf,"true"),A.body.appendChild(t),t},imageReady=function(A){return new Promise(function(e){if(A.complete||!A.src){e();return}A.onload=e,A.onerror=e})},imagesReady=function(A){return Promise.all([].slice.call(A.images,0).map(imageReady))},iframeLoader=function(A){return new Promise(function(e,t){var r=A.contentWindow;if(!r)return t("No window assigned for iframe");var n=r.document;r.onload=A.onload=function(){r.onload=A.onload=null;var t=setInterval(function(){n.body.childNodes.length>0&&"complete"===n.readyState&&(clearInterval(t),e(A))},50)}})},tE=["all","d","content"],copyCSSStyles=function(A,e){for(var t=A.length-1;t>=0;t--){var r=A.item(t);-1===tE.indexOf(r)&&e.style.setProperty(r,A.getPropertyValue(r))}return e},serializeDoctype=function(A){var e="";return A&&(e+="<!DOCTYPE ",A.name&&(e+=A.name),A.internalSubset&&(e+=A.internalSubset),A.publicId&&(e+='"'+A.publicId+'"'),A.systemId&&(e+='"'+A.systemId+'"'),e+=">"),e},restoreOwnerScroll=function(A,e,t){A&&A.defaultView&&(e!==A.defaultView.pageXOffset||t!==A.defaultView.pageYOffset)&&A.defaultView.scrollTo(e,t)},restoreNodeScroll=function(A){var e=A[0],t=A[1],r=A[2];e.scrollLeft=t,e.scrollTop=r},tI="___html2canvas___pseudoelement_before",tm="___html2canvas___pseudoelement_after",ty='{\n    content: "" !important;\n    display: none !important;\n}',createPseudoHideStyles=function(A){createStyles(A,"."+tI+":before"+ty+"\n         ."+tm+":after"+ty)},createStyles=function(A,e){var t=A.ownerDocument;if(t){var r=t.createElement("style");r.textContent=e,A.appendChild(r)}},tK=function(){function CacheStorage(){}return CacheStorage.getOrigin=function(A){var e=CacheStorage._link;return e?(e.href=A,e.href=e.href,e.protocol+e.hostname+e.port):"about:blank"},CacheStorage.isSameOrigin=function(A){return CacheStorage.getOrigin(A)===CacheStorage._origin},CacheStorage.setContext=function(A){CacheStorage._link=A.document.createElement("a"),CacheStorage._origin=CacheStorage.getOrigin(A.location.href)},CacheStorage._origin="about:blank",CacheStorage}(),tL=function(){function Cache(A,e){this.context=A,this._options=e,this._cache={}}return Cache.prototype.addImage=function(A){var e=Promise.resolve();return this.has(A)||(isBlobImage(A)||isRenderable(A))&&(this._cache[A]=this.loadImage(A)).catch(function(){}),e},Cache.prototype.match=function(A){return this._cache[A]},Cache.prototype.loadImage=function(A){return __awaiter(this,void 0,void 0,function(){var e,t,r,n,B=this;return __generator(this,function(s){switch(s.label){case 0:if(e=tK.isSameOrigin(A),t=!isInlineImage(A)&&!0===this._options.useCORS&&eq.SUPPORT_CORS_IMAGES&&!e,r=!isInlineImage(A)&&!e&&!isBlobImage(A)&&"string"==typeof this._options.proxy&&eq.SUPPORT_CORS_XHR&&!t,!e&&!1===this._options.allowTaint&&!isInlineImage(A)&&!isBlobImage(A)&&!r&&!t)return[2];if(n=A,!r)return[3,2];return[4,this.proxy(n)];case 1:n=s.sent(),s.label=2;case 2:return this.context.logger.debug("Added image "+A.substring(0,256)),[4,new Promise(function(A,e){var r=new Image;r.onload=function(){return A(r)},r.onerror=e,(isInlineBase64Image(n)||t)&&(r.crossOrigin="anonymous"),r.src=n,!0===r.complete&&setTimeout(function(){return A(r)},500),B._options.imageTimeout>0&&setTimeout(function(){return e("Timed out ("+B._options.imageTimeout+"ms) loading image")},B._options.imageTimeout)})];case 3:return[2,s.sent()]}})})},Cache.prototype.has=function(A){return void 0!==this._cache[A]},Cache.prototype.keys=function(){return Promise.resolve(Object.keys(this._cache))},Cache.prototype.proxy=function(A){var e=this,t=this._options.proxy;if(!t)throw Error("No proxy defined");var r=A.substring(0,256);return new Promise(function(n,B){var s=eq.SUPPORT_RESPONSE_TYPE?"blob":"text",o=new XMLHttpRequest;o.onload=function(){if(200===o.status){if("text"===s)n(o.response);else{var A=new FileReader;A.addEventListener("load",function(){return n(A.result)},!1),A.addEventListener("error",function(A){return B(A)},!1),A.readAsDataURL(o.response)}}else B("Failed to proxy resource "+r+" with status code "+o.status)},o.onerror=B;var i=t.indexOf("?")>-1?"&":"?";if(o.open("GET",""+t+i+"url="+encodeURIComponent(A)+"&responseType="+s),"text"!==s&&o instanceof XMLHttpRequest&&(o.responseType=s),e._options.imageTimeout){var a=e._options.imageTimeout;o.timeout=a,o.ontimeout=function(){return B("Timed out ("+a+"ms) proxying "+r)}}o.send()})},Cache}(),tb=/^data:image\/svg\+xml/i,tv=/^data:image\/.*;base64,/i,tS=/^data:image\/.*/i,isRenderable=function(A){return eq.SUPPORT_SVG_DRAWING||!isSVG(A)},isInlineImage=function(A){return tS.test(A)},isInlineBase64Image=function(A){return tv.test(A)},isBlobImage=function(A){return"blob"===A.substr(0,4)},isSVG=function(A){return"svg"===A.substr(-3).toLowerCase()||tb.test(A)},tD=function(){function Vector(A,e){this.type=0,this.x=A,this.y=e}return Vector.prototype.add=function(A,e){return new Vector(this.x+A,this.y+e)},Vector}(),lerp=function(A,e,t){return new tD(A.x+(e.x-A.x)*t,A.y+(e.y-A.y)*t)},tx=function(){function BezierCurve(A,e,t,r){this.type=1,this.start=A,this.startControl=e,this.endControl=t,this.end=r}return BezierCurve.prototype.subdivide=function(A,e){var t=lerp(this.start,this.startControl,A),r=lerp(this.startControl,this.endControl,A),n=lerp(this.endControl,this.end,A),B=lerp(t,r,A),s=lerp(r,n,A),o=lerp(B,s,A);return e?new BezierCurve(this.start,t,B,o):new BezierCurve(o,s,n,this.end)},BezierCurve.prototype.add=function(A,e){return new BezierCurve(this.start.add(A,e),this.startControl.add(A,e),this.endControl.add(A,e),this.end.add(A,e))},BezierCurve.prototype.reverse=function(){return new BezierCurve(this.end,this.endControl,this.startControl,this.start)},BezierCurve}(),isBezierCurve=function(A){return 1===A.type},BoundCurves=function(A){var e=A.styles,t=A.bounds,r=getAbsoluteValueForTuple(e.borderTopLeftRadius,t.width,t.height),n=r[0],B=r[1],s=getAbsoluteValueForTuple(e.borderTopRightRadius,t.width,t.height),o=s[0],i=s[1],a=getAbsoluteValueForTuple(e.borderBottomRightRadius,t.width,t.height),c=a[0],g=a[1],Q=getAbsoluteValueForTuple(e.borderBottomLeftRadius,t.width,t.height),l=Q[0],w=Q[1],u=[];u.push((n+o)/t.width),u.push((l+c)/t.width),u.push((B+w)/t.height),u.push((i+g)/t.height);var C=Math.max.apply(Math,u);C>1&&(n/=C,B/=C,o/=C,i/=C,c/=C,g/=C,l/=C,w/=C);var F=t.width-o,U=t.height-g,d=t.width-c,h=t.height-w,p=e.borderTopWidth,f=e.borderRightWidth,E=e.borderBottomWidth,I=e.borderLeftWidth,m=getAbsoluteValue(e.paddingTop,A.bounds.width),y=getAbsoluteValue(e.paddingRight,A.bounds.width),K=getAbsoluteValue(e.paddingBottom,A.bounds.width),L=getAbsoluteValue(e.paddingLeft,A.bounds.width);this.topLeftBorderDoubleOuterBox=n>0||B>0?getCurvePoints(t.left+I/3,t.top+p/3,n-I/3,B-p/3,H.TOP_LEFT):new tD(t.left+I/3,t.top+p/3),this.topRightBorderDoubleOuterBox=n>0||B>0?getCurvePoints(t.left+F,t.top+p/3,o-f/3,i-p/3,H.TOP_RIGHT):new tD(t.left+t.width-f/3,t.top+p/3),this.bottomRightBorderDoubleOuterBox=c>0||g>0?getCurvePoints(t.left+d,t.top+U,c-f/3,g-E/3,H.BOTTOM_RIGHT):new tD(t.left+t.width-f/3,t.top+t.height-E/3),this.bottomLeftBorderDoubleOuterBox=l>0||w>0?getCurvePoints(t.left+I/3,t.top+h,l-I/3,w-E/3,H.BOTTOM_LEFT):new tD(t.left+I/3,t.top+t.height-E/3),this.topLeftBorderDoubleInnerBox=n>0||B>0?getCurvePoints(t.left+2*I/3,t.top+2*p/3,n-2*I/3,B-2*p/3,H.TOP_LEFT):new tD(t.left+2*I/3,t.top+2*p/3),this.topRightBorderDoubleInnerBox=n>0||B>0?getCurvePoints(t.left+F,t.top+2*p/3,o-2*f/3,i-2*p/3,H.TOP_RIGHT):new tD(t.left+t.width-2*f/3,t.top+2*p/3),this.bottomRightBorderDoubleInnerBox=c>0||g>0?getCurvePoints(t.left+d,t.top+U,c-2*f/3,g-2*E/3,H.BOTTOM_RIGHT):new tD(t.left+t.width-2*f/3,t.top+t.height-2*E/3),this.bottomLeftBorderDoubleInnerBox=l>0||w>0?getCurvePoints(t.left+2*I/3,t.top+h,l-2*I/3,w-2*E/3,H.BOTTOM_LEFT):new tD(t.left+2*I/3,t.top+t.height-2*E/3),this.topLeftBorderStroke=n>0||B>0?getCurvePoints(t.left+I/2,t.top+p/2,n-I/2,B-p/2,H.TOP_LEFT):new tD(t.left+I/2,t.top+p/2),this.topRightBorderStroke=n>0||B>0?getCurvePoints(t.left+F,t.top+p/2,o-f/2,i-p/2,H.TOP_RIGHT):new tD(t.left+t.width-f/2,t.top+p/2),this.bottomRightBorderStroke=c>0||g>0?getCurvePoints(t.left+d,t.top+U,c-f/2,g-E/2,H.BOTTOM_RIGHT):new tD(t.left+t.width-f/2,t.top+t.height-E/2),this.bottomLeftBorderStroke=l>0||w>0?getCurvePoints(t.left+I/2,t.top+h,l-I/2,w-E/2,H.BOTTOM_LEFT):new tD(t.left+I/2,t.top+t.height-E/2),this.topLeftBorderBox=n>0||B>0?getCurvePoints(t.left,t.top,n,B,H.TOP_LEFT):new tD(t.left,t.top),this.topRightBorderBox=o>0||i>0?getCurvePoints(t.left+F,t.top,o,i,H.TOP_RIGHT):new tD(t.left+t.width,t.top),this.bottomRightBorderBox=c>0||g>0?getCurvePoints(t.left+d,t.top+U,c,g,H.BOTTOM_RIGHT):new tD(t.left+t.width,t.top+t.height),this.bottomLeftBorderBox=l>0||w>0?getCurvePoints(t.left,t.top+h,l,w,H.BOTTOM_LEFT):new tD(t.left,t.top+t.height),this.topLeftPaddingBox=n>0||B>0?getCurvePoints(t.left+I,t.top+p,Math.max(0,n-I),Math.max(0,B-p),H.TOP_LEFT):new tD(t.left+I,t.top+p),this.topRightPaddingBox=o>0||i>0?getCurvePoints(t.left+Math.min(F,t.width-f),t.top+p,F>t.width+f?0:Math.max(0,o-f),Math.max(0,i-p),H.TOP_RIGHT):new tD(t.left+t.width-f,t.top+p),this.bottomRightPaddingBox=c>0||g>0?getCurvePoints(t.left+Math.min(d,t.width-I),t.top+Math.min(U,t.height-E),Math.max(0,c-f),Math.max(0,g-E),H.BOTTOM_RIGHT):new tD(t.left+t.width-f,t.top+t.height-E),this.bottomLeftPaddingBox=l>0||w>0?getCurvePoints(t.left+I,t.top+Math.min(h,t.height-E),Math.max(0,l-I),Math.max(0,w-E),H.BOTTOM_LEFT):new tD(t.left+I,t.top+t.height-E),this.topLeftContentBox=n>0||B>0?getCurvePoints(t.left+I+L,t.top+p+m,Math.max(0,n-(I+L)),Math.max(0,B-(p+m)),H.TOP_LEFT):new tD(t.left+I+L,t.top+p+m),this.topRightContentBox=o>0||i>0?getCurvePoints(t.left+Math.min(F,t.width+I+L),t.top+p+m,F>t.width+I+L?0:o-I+L,i-(p+m),H.TOP_RIGHT):new tD(t.left+t.width-(f+y),t.top+p+m),this.bottomRightContentBox=c>0||g>0?getCurvePoints(t.left+Math.min(d,t.width-(I+L)),t.top+Math.min(U,t.height+p+m),Math.max(0,c-(f+y)),g-(E+K),H.BOTTOM_RIGHT):new tD(t.left+t.width-(f+y),t.top+t.height-(E+K)),this.bottomLeftContentBox=l>0||w>0?getCurvePoints(t.left+I+L,t.top+h,Math.max(0,l-(I+L)),w-(E+K),H.BOTTOM_LEFT):new tD(t.left+I+L,t.top+t.height-(E+K))};(U=H||(H={}))[U.TOP_LEFT=0]="TOP_LEFT",U[U.TOP_RIGHT=1]="TOP_RIGHT",U[U.BOTTOM_RIGHT=2]="BOTTOM_RIGHT",U[U.BOTTOM_LEFT=3]="BOTTOM_LEFT";var getCurvePoints=function(A,e,t,r,n){var B=4*((Math.sqrt(2)-1)/3),s=t*B,o=r*B,i=A+t,a=e+r;switch(n){case H.TOP_LEFT:return new tx(new tD(A,a),new tD(A,a-o),new tD(i-s,e),new tD(i,e));case H.TOP_RIGHT:return new tx(new tD(A,e),new tD(A+s,e),new tD(i,a-o),new tD(i,a));case H.BOTTOM_RIGHT:return new tx(new tD(i,e),new tD(i,e+o),new tD(A+s,a),new tD(A,a));case H.BOTTOM_LEFT:default:return new tx(new tD(i,a),new tD(i-s,a),new tD(A,e+o),new tD(A,e))}},calculateBorderBoxPath=function(A){return[A.topLeftBorderBox,A.topRightBorderBox,A.bottomRightBorderBox,A.bottomLeftBorderBox]},calculatePaddingBoxPath=function(A){return[A.topLeftPaddingBox,A.topRightPaddingBox,A.bottomRightPaddingBox,A.bottomLeftPaddingBox]},TransformEffect=function(A,e,t){this.offsetX=A,this.offsetY=e,this.matrix=t,this.type=0,this.target=6},ClipEffect=function(A,e){this.path=A,this.target=e,this.type=1},OpacityEffect=function(A){this.opacity=A,this.type=2,this.target=6},isClipEffect=function(A){return 1===A.type},equalPath=function(A,e){return A.length===e.length&&A.some(function(A,t){return A===e[t]})},StackingContext=function(A){this.element=A,this.inlineLevel=[],this.nonInlineLevel=[],this.negativeZIndex=[],this.zeroOrAutoZIndexOrTransformedOrOpacity=[],this.positiveZIndex=[],this.nonPositionedFloats=[],this.nonPositionedInlineLevel=[]},tT=function(){function ElementPaint(A,e){if(this.container=A,this.parent=e,this.effects=[],this.curves=new BoundCurves(this.container),this.container.styles.opacity<1&&this.effects.push(new OpacityEffect(this.container.styles.opacity)),null!==this.container.styles.transform){var t=this.container.bounds.left+this.container.styles.transformOrigin[0].number,r=this.container.bounds.top+this.container.styles.transformOrigin[1].number,n=this.container.styles.transform;this.effects.push(new TransformEffect(t,r,n))}if(0!==this.container.styles.overflowX){var B=calculateBorderBoxPath(this.curves),s=calculatePaddingBoxPath(this.curves);equalPath(B,s)?this.effects.push(new ClipEffect(B,6)):(this.effects.push(new ClipEffect(B,2)),this.effects.push(new ClipEffect(s,4)))}}return ElementPaint.prototype.getEffects=function(A){for(var e=-1===[2,3].indexOf(this.container.styles.position),t=this.parent,r=this.effects.slice(0);t;){var n=t.effects.filter(function(A){return!isClipEffect(A)});if(e||0!==t.container.styles.position||!t.parent){if(r.unshift.apply(r,n),e=-1===[2,3].indexOf(t.container.styles.position),0!==t.container.styles.overflowX){var B=calculateBorderBoxPath(t.curves),s=calculatePaddingBoxPath(t.curves);equalPath(B,s)||r.unshift(new ClipEffect(s,6))}}else r.unshift.apply(r,n);t=t.parent}return r.filter(function(e){return contains(e.target,A)})},ElementPaint}(),parseStackTree=function(A,e,t,r){A.container.elements.forEach(function(n){var B=contains(n.flags,4),s=contains(n.flags,2),o=new tT(n,A);contains(n.styles.display,2048)&&r.push(o);var i=contains(n.flags,8)?[]:r;if(B||s){var a=B||n.styles.isPositioned()?t:e,c=new StackingContext(o);if(n.styles.isPositioned()||n.styles.opacity<1||n.styles.isTransformed()){var g=n.styles.zIndex.order;if(g<0){var Q=0;a.negativeZIndex.some(function(A,e){if(g>A.element.container.styles.zIndex.order)Q=e;else if(Q>0)return!0;return!1}),a.negativeZIndex.splice(Q,0,c)}else if(g>0){var l=0;a.positiveZIndex.some(function(A,e){if(g>=A.element.container.styles.zIndex.order)l=e+1;else if(l>0)return!0;return!1}),a.positiveZIndex.splice(l,0,c)}else a.zeroOrAutoZIndexOrTransformedOrOpacity.push(c)}else n.styles.isFloating()?a.nonPositionedFloats.push(c):a.nonPositionedInlineLevel.push(c);parseStackTree(o,c,B?c:t,i)}else n.styles.isInlineLevel()?e.inlineLevel.push(o):e.nonInlineLevel.push(o),parseStackTree(o,e,t,i);contains(n.flags,8)&&processListItems(n,i)})},processListItems=function(A,e){for(var t=A instanceof tt?A.start:1,r=A instanceof tt&&A.reversed,n=0;n<e.length;n++){var B=e[n];B.container instanceof te&&"number"==typeof B.container.value&&0!==B.container.value&&(t=B.container.value),B.listValue=createCounterText(t,B.container.styles.listStyleType,!0),t+=r?-1:1}},parseStackingContexts=function(A){var e=new tT(A,null),t=new StackingContext(e),r=[];return parseStackTree(e,t,t,r),processListItems(e.container,r),t},parsePathForBorder=function(A,e){switch(e){case 0:return createPathFromCurves(A.topLeftBorderBox,A.topLeftPaddingBox,A.topRightBorderBox,A.topRightPaddingBox);case 1:return createPathFromCurves(A.topRightBorderBox,A.topRightPaddingBox,A.bottomRightBorderBox,A.bottomRightPaddingBox);case 2:return createPathFromCurves(A.bottomRightBorderBox,A.bottomRightPaddingBox,A.bottomLeftBorderBox,A.bottomLeftPaddingBox);default:return createPathFromCurves(A.bottomLeftBorderBox,A.bottomLeftPaddingBox,A.topLeftBorderBox,A.topLeftPaddingBox)}},parsePathForBorderDoubleOuter=function(A,e){switch(e){case 0:return createPathFromCurves(A.topLeftBorderBox,A.topLeftBorderDoubleOuterBox,A.topRightBorderBox,A.topRightBorderDoubleOuterBox);case 1:return createPathFromCurves(A.topRightBorderBox,A.topRightBorderDoubleOuterBox,A.bottomRightBorderBox,A.bottomRightBorderDoubleOuterBox);case 2:return createPathFromCurves(A.bottomRightBorderBox,A.bottomRightBorderDoubleOuterBox,A.bottomLeftBorderBox,A.bottomLeftBorderDoubleOuterBox);default:return createPathFromCurves(A.bottomLeftBorderBox,A.bottomLeftBorderDoubleOuterBox,A.topLeftBorderBox,A.topLeftBorderDoubleOuterBox)}},parsePathForBorderDoubleInner=function(A,e){switch(e){case 0:return createPathFromCurves(A.topLeftBorderDoubleInnerBox,A.topLeftPaddingBox,A.topRightBorderDoubleInnerBox,A.topRightPaddingBox);case 1:return createPathFromCurves(A.topRightBorderDoubleInnerBox,A.topRightPaddingBox,A.bottomRightBorderDoubleInnerBox,A.bottomRightPaddingBox);case 2:return createPathFromCurves(A.bottomRightBorderDoubleInnerBox,A.bottomRightPaddingBox,A.bottomLeftBorderDoubleInnerBox,A.bottomLeftPaddingBox);default:return createPathFromCurves(A.bottomLeftBorderDoubleInnerBox,A.bottomLeftPaddingBox,A.topLeftBorderDoubleInnerBox,A.topLeftPaddingBox)}},parsePathForBorderStroke=function(A,e){switch(e){case 0:return createStrokePathFromCurves(A.topLeftBorderStroke,A.topRightBorderStroke);case 1:return createStrokePathFromCurves(A.topRightBorderStroke,A.bottomRightBorderStroke);case 2:return createStrokePathFromCurves(A.bottomRightBorderStroke,A.bottomLeftBorderStroke);default:return createStrokePathFromCurves(A.bottomLeftBorderStroke,A.topLeftBorderStroke)}},createStrokePathFromCurves=function(A,e){var t=[];return isBezierCurve(A)?t.push(A.subdivide(.5,!1)):t.push(A),isBezierCurve(e)?t.push(e.subdivide(.5,!0)):t.push(e),t},createPathFromCurves=function(A,e,t,r){var n=[];return isBezierCurve(A)?n.push(A.subdivide(.5,!1)):n.push(A),isBezierCurve(t)?n.push(t.subdivide(.5,!0)):n.push(t),isBezierCurve(r)?n.push(r.subdivide(.5,!0).reverse()):n.push(r),isBezierCurve(e)?n.push(e.subdivide(.5,!1).reverse()):n.push(e),n},paddingBox=function(A){var e=A.bounds,t=A.styles;return e.add(t.borderLeftWidth,t.borderTopWidth,-(t.borderRightWidth+t.borderLeftWidth),-(t.borderTopWidth+t.borderBottomWidth))},contentBox=function(A){var e=A.styles,t=A.bounds,r=getAbsoluteValue(e.paddingLeft,t.width),n=getAbsoluteValue(e.paddingRight,t.width),B=getAbsoluteValue(e.paddingTop,t.width),s=getAbsoluteValue(e.paddingBottom,t.width);return t.add(r+e.borderLeftWidth,B+e.borderTopWidth,-(e.borderRightWidth+e.borderLeftWidth+r+n),-(e.borderTopWidth+e.borderBottomWidth+B+s))},calculateBackgroundRendering=function(A,e,t){var r,n,B=0===(r=getBackgroundValueForIndex(A.styles.backgroundOrigin,e))?A.bounds:2===r?contentBox(A):paddingBox(A),s=0===(n=getBackgroundValueForIndex(A.styles.backgroundClip,e))?A.bounds:2===n?contentBox(A):paddingBox(A),o=calculateBackgroundSize(getBackgroundValueForIndex(A.styles.backgroundSize,e),t,B),i=o[0],a=o[1],c=getAbsoluteValueForTuple(getBackgroundValueForIndex(A.styles.backgroundPosition,e),B.width-i,B.height-a);return[calculateBackgroundRepeatPath(getBackgroundValueForIndex(A.styles.backgroundRepeat,e),c,o,B,s),Math.round(B.left+c[0]),Math.round(B.top+c[1]),i,a]},isAuto=function(A){return isIdentToken(A)&&A.value===d.AUTO},hasIntrinsicValue=function(A){return"number"==typeof A},calculateBackgroundSize=function(A,e,t){var r=e[0],n=e[1],B=e[2],s=A[0],o=A[1];if(!s)return[0,0];if(isLengthPercentage(s)&&o&&isLengthPercentage(o))return[getAbsoluteValue(s,t.width),getAbsoluteValue(o,t.height)];var i=hasIntrinsicValue(B);if(isIdentToken(s)&&(s.value===d.CONTAIN||s.value===d.COVER))return hasIntrinsicValue(B)?t.width/t.height<B!=(s.value===d.COVER)?[t.width,t.width/B]:[t.height*B,t.height]:[t.width,t.height];var a=hasIntrinsicValue(r),c=hasIntrinsicValue(n),g=a||c;if(isAuto(s)&&(!o||isAuto(o)))return a&&c?[r,n]:i||g?g&&i?[a?r:n*B,c?n:r/B]:[a?r:t.width,c?n:t.height]:[t.width,t.height];if(i){var Q=0,l=0;return isLengthPercentage(s)?Q=getAbsoluteValue(s,t.width):isLengthPercentage(o)&&(l=getAbsoluteValue(o,t.height)),isAuto(s)?Q=l*B:(!o||isAuto(o))&&(l=Q/B),[Q,l]}var w=null,u=null;if(isLengthPercentage(s)?w=getAbsoluteValue(s,t.width):o&&isLengthPercentage(o)&&(u=getAbsoluteValue(o,t.height)),null!==w&&(!o||isAuto(o))&&(u=a&&c?w/r*n:t.height),null!==u&&isAuto(s)&&(w=a&&c?u/n*r:t.width),null!==w&&null!==u)return[w,u];throw Error("Unable to calculate background-size for element")},getBackgroundValueForIndex=function(A,e){var t=A[e];return void 0===t?A[0]:t},calculateBackgroundRepeatPath=function(A,e,t,r,n){var B=e[0],s=e[1],o=t[0],i=t[1];switch(A){case 2:return[new tD(Math.round(r.left),Math.round(r.top+s)),new tD(Math.round(r.left+r.width),Math.round(r.top+s)),new tD(Math.round(r.left+r.width),Math.round(i+r.top+s)),new tD(Math.round(r.left),Math.round(i+r.top+s))];case 3:return[new tD(Math.round(r.left+B),Math.round(r.top)),new tD(Math.round(r.left+B+o),Math.round(r.top)),new tD(Math.round(r.left+B+o),Math.round(r.height+r.top)),new tD(Math.round(r.left+B),Math.round(r.height+r.top))];case 1:return[new tD(Math.round(r.left+B),Math.round(r.top+s)),new tD(Math.round(r.left+B+o),Math.round(r.top+s)),new tD(Math.round(r.left+B+o),Math.round(r.top+s+i)),new tD(Math.round(r.left+B),Math.round(r.top+s+i))];default:return[new tD(Math.round(n.left),Math.round(n.top)),new tD(Math.round(n.left+n.width),Math.round(n.top)),new tD(Math.round(n.left+n.width),Math.round(n.height+n.top)),new tD(Math.round(n.left),Math.round(n.height+n.top))]}},tV="Hidden Text",tM=function(){function FontMetrics(A){this._data={},this._document=A}return FontMetrics.prototype.parseMetrics=function(A,e){var t=this._document.createElement("div"),r=this._document.createElement("img"),n=this._document.createElement("span"),B=this._document.body;t.style.visibility="hidden",t.style.fontFamily=A,t.style.fontSize=e,t.style.margin="0",t.style.padding="0",t.style.whiteSpace="nowrap",B.appendChild(t),r.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",r.width=1,r.height=1,r.style.margin="0",r.style.padding="0",r.style.verticalAlign="baseline",n.style.fontFamily=A,n.style.fontSize=e,n.style.margin="0",n.style.padding="0",n.appendChild(this._document.createTextNode(tV)),t.appendChild(n),t.appendChild(r);var s=r.offsetTop-n.offsetTop+2;t.removeChild(n),t.appendChild(this._document.createTextNode(tV)),t.style.lineHeight="normal",r.style.verticalAlign="super";var o=r.offsetTop-t.offsetTop+2;return B.removeChild(t),{baseline:s,middle:o}},FontMetrics.prototype.getMetrics=function(A,e){var t=A+" "+e;return void 0===this._data[t]&&(this._data[t]=this.parseMetrics(A,e)),this._data[t]},FontMetrics}(),Renderer=function(A,e){this.context=A,this.options=e},tG=function(A){function CanvasRenderer(e,t){var r=A.call(this,e,t)||this;return r._activeEffects=[],r.canvas=t.canvas?t.canvas:document.createElement("canvas"),r.ctx=r.canvas.getContext("2d"),t.canvas||(r.canvas.width=Math.floor(t.width*t.scale),r.canvas.height=Math.floor(t.height*t.scale),r.canvas.style.width=t.width+"px",r.canvas.style.height=t.height+"px"),r.fontMetrics=new tM(document),r.ctx.scale(r.options.scale,r.options.scale),r.ctx.translate(-t.x,-t.y),r.ctx.textBaseline="bottom",r._activeEffects=[],r.context.logger.debug("Canvas renderer initialized ("+t.width+"x"+t.height+") with scale "+t.scale),r}return __extends(CanvasRenderer,A),CanvasRenderer.prototype.applyEffects=function(A){for(var e=this;this._activeEffects.length;)this.popEffect();A.forEach(function(A){return e.applyEffect(A)})},CanvasRenderer.prototype.applyEffect=function(A){this.ctx.save(),2===A.type&&(this.ctx.globalAlpha=A.opacity),0===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)),isClipEffect(A)&&(this.path(A.path),this.ctx.clip()),this._activeEffects.push(A)},CanvasRenderer.prototype.popEffect=function(){this._activeEffects.pop(),this.ctx.restore()},CanvasRenderer.prototype.renderStack=function(A){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:if(!A.element.container.styles.isVisible())return[3,2];return[4,this.renderStackContent(A)];case 1:e.sent(),e.label=2;case 2:return[2]}})})},CanvasRenderer.prototype.renderNode=function(A){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(e){switch(e.label){case 0:if(contains(A.container.flags,16),!A.container.styles.isVisible())return[3,3];return[4,this.renderNodeBackgroundAndBorders(A)];case 1:return e.sent(),[4,this.renderNodeContent(A)];case 2:e.sent(),e.label=3;case 3:return[2]}})})},CanvasRenderer.prototype.renderTextWithLetterSpacing=function(A,e,t){var r=this;0===e?this.ctx.fillText(A.text,A.bounds.left,A.bounds.top+t):segmentGraphemes(A.text).reduce(function(e,n){return r.ctx.fillText(n,e,A.bounds.top+t),e+r.ctx.measureText(n).width},A.bounds.left)},CanvasRenderer.prototype.createFontStyle=function(A){var e=A.fontVariant.filter(function(A){return"normal"===A||"small-caps"===A}).join(""),t=fixIOSSystemFonts(A.fontFamily).join(", "),r=isDimensionToken(A.fontSize)?""+A.fontSize.number+A.fontSize.unit:A.fontSize.number+"px";return[[A.fontStyle,e,A.fontWeight,r,t].join(" "),t,r]},CanvasRenderer.prototype.renderTextNode=function(A,e){return __awaiter(this,void 0,void 0,function(){var t,r,n,B,s,o,i,a,c=this;return __generator(this,function(g){return r=(t=this.createFontStyle(e))[0],n=t[1],B=t[2],this.ctx.font=r,this.ctx.direction=1===e.direction?"rtl":"ltr",this.ctx.textAlign="left",this.ctx.textBaseline="alphabetic",o=(s=this.fontMetrics.getMetrics(n,B)).baseline,i=s.middle,a=e.paintOrder,A.textBounds.forEach(function(A){a.forEach(function(t){switch(t){case 0:c.ctx.fillStyle=asString(e.color),c.renderTextWithLetterSpacing(A,e.letterSpacing,o);var r=e.textShadow;r.length&&A.text.trim().length&&(r.slice(0).reverse().forEach(function(t){c.ctx.shadowColor=asString(t.color),c.ctx.shadowOffsetX=t.offsetX.number*c.options.scale,c.ctx.shadowOffsetY=t.offsetY.number*c.options.scale,c.ctx.shadowBlur=t.blur.number,c.renderTextWithLetterSpacing(A,e.letterSpacing,o)}),c.ctx.shadowColor="",c.ctx.shadowOffsetX=0,c.ctx.shadowOffsetY=0,c.ctx.shadowBlur=0),e.textDecorationLine.length&&(c.ctx.fillStyle=asString(e.textDecorationColor||e.color),e.textDecorationLine.forEach(function(e){switch(e){case 1:c.ctx.fillRect(A.bounds.left,Math.round(A.bounds.top+o),A.bounds.width,1);break;case 2:c.ctx.fillRect(A.bounds.left,Math.round(A.bounds.top),A.bounds.width,1);break;case 3:c.ctx.fillRect(A.bounds.left,Math.ceil(A.bounds.top+i),A.bounds.width,1)}}));break;case 1:e.webkitTextStrokeWidth&&A.text.trim().length&&(c.ctx.strokeStyle=asString(e.webkitTextStrokeColor),c.ctx.lineWidth=e.webkitTextStrokeWidth,c.ctx.lineJoin=window.chrome?"miter":"round",c.ctx.strokeText(A.text,A.bounds.left,A.bounds.top+o)),c.ctx.strokeStyle="",c.ctx.lineWidth=0,c.ctx.lineJoin="miter"}})}),[2]})})},CanvasRenderer.prototype.renderReplacedElement=function(A,e,t){if(t&&A.intrinsicWidth>0&&A.intrinsicHeight>0){var r=contentBox(A),n=calculatePaddingBoxPath(e);this.path(n),this.ctx.save(),this.ctx.clip(),this.ctx.drawImage(t,0,0,A.intrinsicWidth,A.intrinsicHeight,r.left,r.top,r.width,r.height),this.ctx.restore()}},CanvasRenderer.prototype.renderNodeContent=function(A){return __awaiter(this,void 0,void 0,function(){var e,t,r,n,B,s,o,i,a,c,g,Q,l,w,u,C,F,U;return __generator(this,function(d){switch(d.label){case 0:this.applyEffects(A.getEffects(4)),e=A.container,t=A.curves,r=e.styles,n=0,B=e.textNodes,d.label=1;case 1:if(!(n<B.length))return[3,4];return s=B[n],[4,this.renderTextNode(s,r)];case 2:d.sent(),d.label=3;case 3:return n++,[3,1];case 4:if(!(e instanceof e7))return[3,8];d.label=5;case 5:return d.trys.push([5,7,,8]),[4,this.context.cache.match(e.src)];case 6:return o=d.sent(),this.renderReplacedElement(e,t,o),[3,8];case 7:return d.sent(),this.context.logger.error("Error loading image "+e.src),[3,8];case 8:if(e instanceof e9&&this.renderReplacedElement(e,t,e.canvas),!(e instanceof tA))return[3,12];d.label=9;case 9:return d.trys.push([9,11,,12]),[4,this.context.cache.match(e.svg)];case 10:return o=d.sent(),this.renderReplacedElement(e,t,o),[3,12];case 11:return d.sent(),this.context.logger.error("Error loading svg "+e.svg.substring(0,255)),[3,12];case 12:if(!(e instanceof tg&&e.tree))return[3,14];return[4,new CanvasRenderer(this.context,{scale:this.options.scale,backgroundColor:e.backgroundColor,x:0,y:0,width:e.width,height:e.height}).render(e.tree)];case 13:i=d.sent(),e.width&&e.height&&this.ctx.drawImage(i,0,0,e.width,e.height,e.bounds.left,e.bounds.top,e.bounds.width,e.bounds.height),d.label=14;case 14:if(e instanceof ti&&(a=Math.min(e.bounds.width,e.bounds.height),e.type===tB?e.checked&&(this.ctx.save(),this.path([new tD(e.bounds.left+.39363*a,e.bounds.top+.79*a),new tD(e.bounds.left+.16*a,e.bounds.top+.5549*a),new tD(e.bounds.left+.27347*a,e.bounds.top+.44071*a),new tD(e.bounds.left+.39694*a,e.bounds.top+.5649*a),new tD(e.bounds.left+.72983*a,e.bounds.top+.23*a),new tD(e.bounds.left+.84*a,e.bounds.top+.34085*a),new tD(e.bounds.left+.39363*a,e.bounds.top+.79*a)]),this.ctx.fillStyle=asString(707406591),this.ctx.fill(),this.ctx.restore()):e.type===ts&&e.checked&&(this.ctx.save(),this.ctx.beginPath(),this.ctx.arc(e.bounds.left+a/2,e.bounds.top+a/2,a/4,0,2*Math.PI,!0),this.ctx.fillStyle=asString(707406591),this.ctx.fill(),this.ctx.restore())),isTextInputElement(e)&&e.value.length){switch(g=(c=this.createFontStyle(r))[0],Q=c[1],l=this.fontMetrics.getMetrics(g,Q).baseline,this.ctx.font=g,this.ctx.fillStyle=asString(r.color),this.ctx.textBaseline="alphabetic",this.ctx.textAlign=canvasTextAlign(e.styles.textAlign),w=contentBox(e),u=0,e.styles.textAlign){case 1:u+=w.width/2;break;case 2:u+=w.width}C=w.add(u,0,0,-w.height/2+1),this.ctx.save(),this.path([new tD(w.left,w.top),new tD(w.left+w.width,w.top),new tD(w.left+w.width,w.top+w.height),new tD(w.left,w.top+w.height)]),this.ctx.clip(),this.renderTextWithLetterSpacing(new TextBounds(e.value,C),r.letterSpacing,l),this.ctx.restore(),this.ctx.textBaseline="alphabetic",this.ctx.textAlign="left"}if(!contains(e.styles.display,2048))return[3,20];if(!(null!==e.styles.listStyleImage))return[3,19];if(0!==(F=e.styles.listStyleImage).type)return[3,18];o=void 0,U=F.url,d.label=15;case 15:return d.trys.push([15,17,,18]),[4,this.context.cache.match(U)];case 16:return o=d.sent(),this.ctx.drawImage(o,e.bounds.left-(o.width+10),e.bounds.top),[3,18];case 17:return d.sent(),this.context.logger.error("Error loading list-style-image "+U),[3,18];case 18:return[3,20];case 19:A.listValue&&-1!==e.styles.listStyleType&&(g=this.createFontStyle(r)[0],this.ctx.font=g,this.ctx.fillStyle=asString(r.color),this.ctx.textBaseline="middle",this.ctx.textAlign="right",w=new E(e.bounds.left,e.bounds.top+getAbsoluteValue(e.styles.paddingTop,e.bounds.width),e.bounds.width,computeLineHeight(r.lineHeight,r.fontSize.number)/2+1),this.renderTextWithLetterSpacing(new TextBounds(A.listValue,w),r.letterSpacing,computeLineHeight(r.lineHeight,r.fontSize.number)/2+2),this.ctx.textBaseline="bottom",this.ctx.textAlign="left"),d.label=20;case 20:return[2]}})})},CanvasRenderer.prototype.renderStackContent=function(A){return __awaiter(this,void 0,void 0,function(){var e,t,r,n,B,s,o,i,a,c,g,Q,l,w,u;return __generator(this,function(C){switch(C.label){case 0:return contains(A.element.container.flags,16),[4,this.renderNodeBackgroundAndBorders(A.element)];case 1:C.sent(),e=0,t=A.negativeZIndex,C.label=2;case 2:if(!(e<t.length))return[3,5];return r=t[e],[4,this.renderStack(r)];case 3:C.sent(),C.label=4;case 4:return e++,[3,2];case 5:return[4,this.renderNodeContent(A.element)];case 6:C.sent(),n=0,B=A.nonInlineLevel,C.label=7;case 7:if(!(n<B.length))return[3,10];return r=B[n],[4,this.renderNode(r)];case 8:C.sent(),C.label=9;case 9:return n++,[3,7];case 10:s=0,o=A.nonPositionedFloats,C.label=11;case 11:if(!(s<o.length))return[3,14];return r=o[s],[4,this.renderStack(r)];case 12:C.sent(),C.label=13;case 13:return s++,[3,11];case 14:i=0,a=A.nonPositionedInlineLevel,C.label=15;case 15:if(!(i<a.length))return[3,18];return r=a[i],[4,this.renderStack(r)];case 16:C.sent(),C.label=17;case 17:return i++,[3,15];case 18:c=0,g=A.inlineLevel,C.label=19;case 19:if(!(c<g.length))return[3,22];return r=g[c],[4,this.renderNode(r)];case 20:C.sent(),C.label=21;case 21:return c++,[3,19];case 22:Q=0,l=A.zeroOrAutoZIndexOrTransformedOrOpacity,C.label=23;case 23:if(!(Q<l.length))return[3,26];return r=l[Q],[4,this.renderStack(r)];case 24:C.sent(),C.label=25;case 25:return Q++,[3,23];case 26:w=0,u=A.positiveZIndex,C.label=27;case 27:if(!(w<u.length))return[3,30];return r=u[w],[4,this.renderStack(r)];case 28:C.sent(),C.label=29;case 29:return w++,[3,27];case 30:return[2]}})})},CanvasRenderer.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()},CanvasRenderer.prototype.path=function(A){this.ctx.beginPath(),this.formatPath(A),this.ctx.closePath()},CanvasRenderer.prototype.formatPath=function(A){var e=this;A.forEach(function(A,t){var r=isBezierCurve(A)?A.start:A;0===t?e.ctx.moveTo(r.x,r.y):e.ctx.lineTo(r.x,r.y),isBezierCurve(A)&&e.ctx.bezierCurveTo(A.startControl.x,A.startControl.y,A.endControl.x,A.endControl.y,A.end.x,A.end.y)})},CanvasRenderer.prototype.renderRepeat=function(A,e,t,r){this.path(A),this.ctx.fillStyle=e,this.ctx.translate(t,r),this.ctx.fill(),this.ctx.translate(-t,-r)},CanvasRenderer.prototype.resizeImage=function(A,e,t){if(A.width===e&&A.height===t)return A;var r,n=(null!==(r=this.canvas.ownerDocument)&&void 0!==r?r:document).createElement("canvas");return n.width=Math.max(1,e),n.height=Math.max(1,t),n.getContext("2d").drawImage(A,0,0,A.width,A.height,0,0,e,t),n},CanvasRenderer.prototype.renderBackgroundImage=function(A){return __awaiter(this,void 0,void 0,function(){var e,t,r,n,B,s;return __generator(this,function(o){switch(o.label){case 0:e=A.styles.backgroundImage.length-1,t=function(t){var n,B,s,o,i,a,c,g,Q,l,w,u,C,F,U,d,h,p,f,H,E,I,m,y,K,L,b,v,S,D,x;return __generator(this,function(T){switch(T.label){case 0:if(0!==t.type)return[3,5];n=void 0,B=t.url,T.label=1;case 1:return T.trys.push([1,3,,4]),[4,r.context.cache.match(B)];case 2:return n=T.sent(),[3,4];case 3:return T.sent(),r.context.logger.error("Error loading background-image "+B),[3,4];case 4:return n&&(o=(s=calculateBackgroundRendering(A,e,[n.width,n.height,n.width/n.height]))[0],i=s[1],a=s[2],c=s[3],g=s[4],Q=r.ctx.createPattern(r.resizeImage(n,c,g),"repeat"),r.renderRepeat(o,Q,i,a)),[3,6];case 5:1===t.type?(o=(l=calculateBackgroundRendering(A,e,[null,null,null]))[0],i=l[1],a=l[2],c=l[3],g=l[4],u=(w=calculateGradientDirection(t.angle,c,g))[0],C=w[1],F=w[2],U=w[3],d=w[4],(h=document.createElement("canvas")).width=c,h.height=g,f=(p=h.getContext("2d")).createLinearGradient(C,U,F,d),processColorStops(t.stops,u).forEach(function(A){return f.addColorStop(A.stop,asString(A.color))}),p.fillStyle=f,p.fillRect(0,0,c,g),c>0&&g>0&&(Q=r.ctx.createPattern(h,"repeat"),r.renderRepeat(o,Q,i,a))):2===t.type&&(o=(H=calculateBackgroundRendering(A,e,[null,null,null]))[0],E=H[1],I=H[2],c=H[3],g=H[4],i=getAbsoluteValue((m=0===t.position.length?[Au]:t.position)[0],c),a=getAbsoluteValue(m[m.length-1],g),K=(y=calculateRadius(t,i,a,c,g))[0],L=y[1],K>0&&L>0&&(b=r.ctx.createRadialGradient(E+i,I+a,0,E+i,I+a,K),processColorStops(t.stops,2*K).forEach(function(A){return b.addColorStop(A.stop,asString(A.color))}),r.path(o),r.ctx.fillStyle=b,K!==L?(v=A.bounds.left+.5*A.bounds.width,S=A.bounds.top+.5*A.bounds.height,x=1/(D=L/K),r.ctx.save(),r.ctx.translate(v,S),r.ctx.transform(1,0,0,D,0,0),r.ctx.translate(-v,-S),r.ctx.fillRect(E,x*(I-S)+S,c,g*x),r.ctx.restore()):r.ctx.fill())),T.label=6;case 6:return e--,[2]}})},r=this,n=0,B=A.styles.backgroundImage.slice(0).reverse(),o.label=1;case 1:if(!(n<B.length))return[3,4];return s=B[n],[5,t(s)];case 2:o.sent(),o.label=3;case 3:return n++,[3,1];case 4:return[2]}})})},CanvasRenderer.prototype.renderSolidBorder=function(A,e,t){return __awaiter(this,void 0,void 0,function(){return __generator(this,function(r){return this.path(parsePathForBorder(t,e)),this.ctx.fillStyle=asString(A),this.ctx.fill(),[2]})})},CanvasRenderer.prototype.renderDoubleBorder=function(A,e,t,r){return __awaiter(this,void 0,void 0,function(){var n,B;return __generator(this,function(s){switch(s.label){case 0:if(!(e<3))return[3,2];return[4,this.renderSolidBorder(A,t,r)];case 1:return s.sent(),[2];case 2:return n=parsePathForBorderDoubleOuter(r,t),this.path(n),this.ctx.fillStyle=asString(A),this.ctx.fill(),B=parsePathForBorderDoubleInner(r,t),this.path(B),this.ctx.fill(),[2]}})})},CanvasRenderer.prototype.renderNodeBackgroundAndBorders=function(A){return __awaiter(this,void 0,void 0,function(){var e,t,r,n,B,s,o,i,a=this;return __generator(this,function(c){switch(c.label){case 0:if(this.applyEffects(A.getEffects(2)),t=!isTransparent((e=A.container.styles).backgroundColor)||e.backgroundImage.length,r=[{style:e.borderTopStyle,color:e.borderTopColor,width:e.borderTopWidth},{style:e.borderRightStyle,color:e.borderRightColor,width:e.borderRightWidth},{style:e.borderBottomStyle,color:e.borderBottomColor,width:e.borderBottomWidth},{style:e.borderLeftStyle,color:e.borderLeftColor,width:e.borderLeftWidth}],n=calculateBackgroundCurvedPaintingArea(getBackgroundValueForIndex(e.backgroundClip,0),A.curves),!(t||e.boxShadow.length))return[3,2];return this.ctx.save(),this.path(n),this.ctx.clip(),isTransparent(e.backgroundColor)||(this.ctx.fillStyle=asString(e.backgroundColor),this.ctx.fill()),[4,this.renderBackgroundImage(A.container)];case 1:c.sent(),this.ctx.restore(),e.boxShadow.slice(0).reverse().forEach(function(e){a.ctx.save();var t,r,n,B,s=calculateBorderBoxPath(A.curves),o=e.inset?0:1e4,i=(t=-o+(e.inset?1:-1)*e.spread.number,r=(e.inset?1:-1)*e.spread.number,n=e.spread.number*(e.inset?-2:2),B=e.spread.number*(e.inset?-2:2),s.map(function(A,e){switch(e){case 0:return A.add(t,r);case 1:return A.add(t+n,r);case 2:return A.add(t+n,r+B);case 3:return A.add(t,r+B)}return A}));e.inset?(a.path(s),a.ctx.clip(),a.mask(i)):(a.mask(s),a.ctx.clip(),a.path(i)),a.ctx.shadowOffsetX=e.offsetX.number+o,a.ctx.shadowOffsetY=e.offsetY.number,a.ctx.shadowColor=asString(e.color),a.ctx.shadowBlur=e.blur.number,a.ctx.fillStyle=e.inset?asString(e.color):"rgba(0,0,0,1)",a.ctx.fill(),a.ctx.restore()}),c.label=2;case 2:B=0,s=0,o=r,c.label=3;case 3:if(!(s<o.length))return[3,13];if(!(0!==(i=o[s]).style&&!isTransparent(i.color)&&i.width>0))return[3,11];if(2!==i.style)return[3,5];return[4,this.renderDashedDottedBorder(i.color,i.width,B,A.curves,2)];case 4:case 6:case 8:return c.sent(),[3,11];case 5:if(3!==i.style)return[3,7];return[4,this.renderDashedDottedBorder(i.color,i.width,B,A.curves,3)];case 7:if(4!==i.style)return[3,9];return[4,this.renderDoubleBorder(i.color,i.width,B,A.curves)];case 9:return[4,this.renderSolidBorder(i.color,B,A.curves)];case 10:c.sent(),c.label=11;case 11:B++,c.label=12;case 12:return s++,[3,3];case 13:return[2]}})})},CanvasRenderer.prototype.renderDashedDottedBorder=function(A,e,t,r,n){return __awaiter(this,void 0,void 0,function(){var B,s,o,i,a,c,g,Q,l,w,u,C,F,U,d,h;return __generator(this,function(p){return this.ctx.save(),B=parsePathForBorderStroke(r,t),s=parsePathForBorder(r,t),2===n&&(this.path(s),this.ctx.clip()),isBezierCurve(s[0])?(o=s[0].start.x,i=s[0].start.y):(o=s[0].x,i=s[0].y),isBezierCurve(s[1])?(a=s[1].end.x,c=s[1].end.y):(a=s[1].x,c=s[1].y),g=0===t||2===t?Math.abs(o-a):Math.abs(i-c),this.ctx.beginPath(),3===n?this.formatPath(B):this.formatPath(s.slice(0,2)),Q=e<3?3*e:2*e,l=e<3?2*e:e,3===n&&(Q=e,l=e),w=!0,g<=2*Q?w=!1:g<=2*Q+l?(u=g/(2*Q+l),Q*=u,l*=u):(C=Math.floor((g+l)/(Q+l)),F=(g-C*Q)/(C-1),l=(U=(g-(C+1)*Q)/C)<=0||Math.abs(l-F)<Math.abs(l-U)?F:U),w&&(3===n?this.ctx.setLineDash([0,Q+l]):this.ctx.setLineDash([Q,l])),3===n?(this.ctx.lineCap="round",this.ctx.lineWidth=e):this.ctx.lineWidth=2*e+1.1,this.ctx.strokeStyle=asString(A),this.ctx.stroke(),this.ctx.setLineDash([]),2===n&&(isBezierCurve(s[0])&&(d=s[3],h=s[0],this.ctx.beginPath(),this.formatPath([new tD(d.end.x,d.end.y),new tD(h.start.x,h.start.y)]),this.ctx.stroke()),isBezierCurve(s[1])&&(d=s[1],h=s[2],this.ctx.beginPath(),this.formatPath([new tD(d.end.x,d.end.y),new tD(h.start.x,h.start.y)]),this.ctx.stroke())),this.ctx.restore(),[2]})})},CanvasRenderer.prototype.render=function(A){return __awaiter(this,void 0,void 0,function(){var e;return __generator(this,function(t){switch(t.label){case 0:return this.options.backgroundColor&&(this.ctx.fillStyle=asString(this.options.backgroundColor),this.ctx.fillRect(this.options.x,this.options.y,this.options.width,this.options.height)),e=parseStackingContexts(A),[4,this.renderStack(e)];case 1:return t.sent(),this.applyEffects([]),[2,this.canvas]}})})},CanvasRenderer}(Renderer),isTextInputElement=function(A){return A instanceof tc||A instanceof ta||A instanceof ti&&A.type!==ts&&A.type!==tB},calculateBackgroundCurvedPaintingArea=function(A,e){switch(A){case 0:return calculateBorderBoxPath(e);case 2:return[e.topLeftContentBox,e.topRightContentBox,e.bottomRightContentBox,e.bottomLeftContentBox];default:return calculatePaddingBoxPath(e)}},canvasTextAlign=function(A){switch(A){case 1:return"center";case 2:return"right";default:return"left"}},tO=["-apple-system","system-ui"],fixIOSSystemFonts=function(A){return/iPhone OS 15_(0|1)/.test(window.navigator.userAgent)?A.filter(function(A){return -1===tO.indexOf(A)}):A},tk=function(A){function ForeignObjectRenderer(e,t){var r=A.call(this,e,t)||this;return r.canvas=t.canvas?t.canvas:document.createElement("canvas"),r.ctx=r.canvas.getContext("2d"),r.options=t,r.canvas.width=Math.floor(t.width*t.scale),r.canvas.height=Math.floor(t.height*t.scale),r.canvas.style.width=t.width+"px",r.canvas.style.height=t.height+"px",r.ctx.scale(r.options.scale,r.options.scale),r.ctx.translate(-t.x,-t.y),r.context.logger.debug("EXPERIMENTAL ForeignObject renderer initialized ("+t.width+"x"+t.height+" at "+t.x+","+t.y+") with scale "+t.scale),r}return __extends(ForeignObjectRenderer,A),ForeignObjectRenderer.prototype.render=function(A){return __awaiter(this,void 0,void 0,function(){var e;return __generator(this,function(t){switch(t.label){case 0:return[4,loadSerializedSVG(createForeignObjectSVG(this.options.width*this.options.scale,this.options.height*this.options.scale,this.options.scale,this.options.scale,A))];case 1:return e=t.sent(),this.options.backgroundColor&&(this.ctx.fillStyle=asString(this.options.backgroundColor),this.ctx.fillRect(0,0,this.options.width*this.options.scale,this.options.height*this.options.scale)),this.ctx.drawImage(e,-this.options.x*this.options.scale,-this.options.y*this.options.scale),[2,this.canvas]}})})},ForeignObjectRenderer}(Renderer),loadSerializedSVG=function(A){return new Promise(function(e,t){var r=new Image;r.onload=function(){e(r)},r.onerror=t,r.src="data:image/svg+xml;charset=utf-8,"+encodeURIComponent(new XMLSerializer().serializeToString(A))})},tP=function(){function Logger(A){var e=A.id,t=A.enabled;this.id=e,this.enabled=t,this.start=Date.now()}return Logger.prototype.debug=function(){for(var A=[],e=0;e<arguments.length;e++)A[e]=arguments[e];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.debug?console.debug.apply(console,__spreadArray([this.id,this.getTime()+"ms"],A)):this.info.apply(this,A))},Logger.prototype.getTime=function(){return Date.now()-this.start},Logger.prototype.info=function(){for(var A=[],e=0;e<arguments.length;e++)A[e]=arguments[e];this.enabled&&"undefined"!=typeof window&&window.console&&"function"==typeof console.info&&console.info.apply(console,__spreadArray([this.id,this.getTime()+"ms"],A))},Logger.prototype.warn=function(){for(var A=[],e=0;e<arguments.length;e++)A[e]=arguments[e];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.warn?console.warn.apply(console,__spreadArray([this.id,this.getTime()+"ms"],A)):this.info.apply(this,A))},Logger.prototype.error=function(){for(var A=[],e=0;e<arguments.length;e++)A[e]=arguments[e];this.enabled&&("undefined"!=typeof window&&window.console&&"function"==typeof console.error?console.error.apply(console,__spreadArray([this.id,this.getTime()+"ms"],A)):this.info.apply(this,A))},Logger.instances={},Logger}(),tR=function(){function Context(A,e){var t;this.windowBounds=e,this.instanceName="#"+Context.instanceCount++,this.logger=new tP({id:this.instanceName,enabled:A.logging}),this.cache=null!==(t=A.cache)&&void 0!==t?t:new tL(this,A)}return Context.instanceCount=1,Context}();"undefined"!=typeof window&&tK.setContext(window);var parseBackgroundColor=function(A,e,t){var r=e.ownerDocument,n=r.documentElement?parseColor(A,getComputedStyle(r.documentElement).backgroundColor):Af.TRANSPARENT,B=r.body?parseColor(A,getComputedStyle(r.body).backgroundColor):Af.TRANSPARENT,s="string"==typeof t?parseColor(A,t):null===t?Af.TRANSPARENT:4294967295;return e===r.documentElement?isTransparent(n)?isTransparent(B)?s:B:n:s};return function(A,e){var t;return void 0===e&&(e={}),t=e,__awaiter(void 0,void 0,void 0,function(){var e,r,n,B,s,o,i,a,c,g,Q,l,w,u,C,F,U,d,h,p,f,H,I,m,y,K,L,b,v,S,D,x,T,V,M,G,O;return __generator(this,function(k){switch(k.label){case 0:if(!A||"object"!=typeof A)return[2,Promise.reject("Invalid element provided as first argument")];if(!(e=A.ownerDocument))throw Error("Element is not attached to a Document");if(!(r=e.defaultView))throw Error("Document is not attached to a Window");if(n={allowTaint:null!==(f=t.allowTaint)&&void 0!==f&&f,imageTimeout:null!==(H=t.imageTimeout)&&void 0!==H?H:15e3,proxy:t.proxy,useCORS:null!==(I=t.useCORS)&&void 0!==I&&I},o=new tR(__assign({logging:null===(m=t.logging)||void 0===m||m,cache:t.cache},n),s=new E((B={windowWidth:null!==(y=t.windowWidth)&&void 0!==y?y:r.innerWidth,windowHeight:null!==(K=t.windowHeight)&&void 0!==K?K:r.innerHeight,scrollX:null!==(L=t.scrollX)&&void 0!==L?L:r.pageXOffset,scrollY:null!==(b=t.scrollY)&&void 0!==b?b:r.pageYOffset}).scrollX,B.scrollY,B.windowWidth,B.windowHeight)),i=null!==(v=t.foreignObjectRendering)&&void 0!==v&&v,a={allowTaint:null!==(S=t.allowTaint)&&void 0!==S&&S,onclone:t.onclone,ignoreElements:t.ignoreElements,inlineImages:i,copyStyles:i},o.logger.debug("Starting document clone with size "+s.width+"x"+s.height+" scrolled to "+-s.left+","+-s.top),!(g=(c=new tH(o,A,a)).clonedReferenceElement))return[2,Promise.reject("Unable to find element in cloned iframe")];return[4,c.toIFrame(e,s)];case 1:if(Q=k.sent(),w=(l=isBodyElement(g)||"HTML"===g.tagName?parseDocumentSize(g.ownerDocument):parseBounds(o,g)).width,u=l.height,C=l.left,F=l.top,U=parseBackgroundColor(o,g,t.backgroundColor),d={canvas:t.canvas,backgroundColor:U,scale:null!==(x=null!==(D=t.scale)&&void 0!==D?D:r.devicePixelRatio)&&void 0!==x?x:1,x:(null!==(T=t.x)&&void 0!==T?T:0)+C,y:(null!==(V=t.y)&&void 0!==V?V:0)+F,width:null!==(M=t.width)&&void 0!==M?M:Math.ceil(w),height:null!==(G=t.height)&&void 0!==G?G:Math.ceil(u)},!i)return[3,3];return o.logger.debug("Document cloned, using foreign object rendering"),[4,new tk(o,d).render(g)];case 2:return h=k.sent(),[3,5];case 3:return o.logger.debug("Document cloned, element located at "+C+","+F+" with size "+w+"x"+u+" using computed rendering"),o.logger.debug("Starting DOM parsing"),p=parseTree(o,g),U===p.styles.backgroundColor&&(p.styles.backgroundColor=Af.TRANSPARENT),o.logger.debug("Starting renderer for element at "+d.x+","+d.y+" with size "+d.width+"x"+d.height),[4,new tG(o,d).render(p)];case 4:h=k.sent(),k.label=5;case 5:return(null===(O=t.removeContainer)||void 0===O||O)&&!tH.destroy(Q)&&o.logger.error("Cannot detach cloned iframe as it is not in the DOM anymore"),o.logger.debug("Finished rendering"),[2,h]}})})}}()}}]);