=128&&r("not-basic"),B.push(A.charCodeAt(n));for(i=e>0?e+1:0;i=p&&r("invalid-input"),((h=c(A.charCodeAt(i++)))>=Q||h>S((m-g)/a))&&r("overflow"),g+=h*a,d=l<=v?C:l>=v+y?y:l-v,!(hS(m/(f=Q-d))&&r("overflow"),a*=f;v=u(g-o,t=B.length+1,0==o),S(g/t)>m-w&&r("overflow"),w+=S(g/t),g%=t,B.splice(g++,0,w)}return s(B)}function d(A){var t,e,n,i,o,s,c,h,d,f,B,p,g,w,v,U=[];for(p=(A=a(A)).length,t=E,e=0,o=F,s=0;s=t&&BS((m-e)/(g=n+1))&&r("overflow"),e+=(c-t)*g,t=c,s=0;sm&&r("overflow"),B==t){for(h=e,d=Q;f=d<=o?C:d>=o+y?y:d-o,!(h= 0x80 (not a basic code point)","invalid-input":"Invalid input"},T=Q-C,S=Math.floor,N=String.fromCharCode;if(g={version:"1.2.4",ucs2:{decode:a,encode:s},decode:h,encode:d,toASCII:function(A){return o(A,function(A){return x.test(A)?"xn--"+d(A):A})},toUnicode:function(A){return o(A,function(A){return H.test(A)?h(A.slice(4).toLowerCase()):A})}},f&&!f.nodeType)if(B)B.exports=g;else for(w in g)g.hasOwnProperty(w)&&(f[w]=g[w]);else n.punycode=g}(this)}).call(this,void 0!==n?n:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],2:[function(A,t,e){function n(A,t){for(var e=3===A.nodeType?document.createTextNode(A.nodeValue):A.cloneNode(!1),r=A.firstChild;r;)!0!==t&&1===r.nodeType&&"SCRIPT"===r.nodeName||e.appendChild(n(r,t)),r=r.nextSibling;return 1===A.nodeType&&(e._scrollTop=A.scrollTop,e._scrollLeft=A.scrollLeft,"CANVAS"===A.nodeName?function(A,t){try{t&&(t.width=A.width,t.height=A.height,t.getContext("2d").putImageData(A.getContext("2d").getImageData(0,0,A.width,A.height),0,0))}catch(t){i("Unable to copy canvas content from",A,t)}}(A,e):"TEXTAREA"!==A.nodeName&&"SELECT"!==A.nodeName||(e.value=A.value)),e}function r(A){if(1===A.nodeType){A.scrollTop=A._scrollTop,A.scrollLeft=A._scrollLeft;for(var t=A.firstChild;t;)r(t),t=t.nextSibling}}var i=A("./log");t.exports=function(A,t,e,i,o,a,s){var c=n(A.documentElement,o.javascriptEnabled),l=t.createElement("iframe");return l.className="html2canvas-container",l.style.visibility="hidden",l.style.position="fixed",l.style.left="-10000px",l.style.top="0px",l.style.border="0",l.width=e,l.height=i,l.scrolling="no",t.body.appendChild(l),new Promise(function(t){var e=l.contentWindow.document;l.contentWindow.onload=l.onload=function(){var A=setInterval(function(){e.body.childNodes.length>0&&(r(e.documentElement),clearInterval(A),"view"===o.type&&(l.contentWindow.scrollTo(a,s),!/(iPad|iPhone|iPod)/g.test(navigator.userAgent)||l.contentWindow.scrollY===s&&l.contentWindow.scrollX===a||(e.documentElement.style.top=-s+"px",e.documentElement.style.left=-a+"px",e.documentElement.style.position="absolute")),t(l))},50)},e.open(),e.write(""),function(A,t,e){!A.defaultView||t===A.defaultView.pageXOffset&&e===A.defaultView.pageYOffset||A.defaultView.scrollTo(t,e)}(A,a,s),e.replaceChild(e.adoptNode(c),e.documentElement),e.close()})}},{"./log":13}],3:[function(A,t,e){function n(A){this.r=0,this.g=0,this.b=0,this.a=null,this.fromArray(A)||this.namedColor(A)||this.rgb(A)||this.rgba(A)||this.hex6(A)||this.hex3(A)}n.prototype.darken=function(A){var t=1-A;return new n([Math.round(this.r*t),Math.round(this.g*t),Math.round(this.b*t),this.a])},n.prototype.isTransparent=function(){return 0===this.a},n.prototype.isBlack=function(){return 0===this.r&&0===this.g&&0===this.b},n.prototype.fromArray=function(A){return Array.isArray(A)&&(this.r=Math.min(A[0],255),this.g=Math.min(A[1],255),this.b=Math.min(A[2],255),A.length>3&&(this.a=A[3])),Array.isArray(A)};var r=/^#([a-f0-9]{3})$/i;n.prototype.hex3=function(A){var t=null;return null!==(t=A.match(r))&&(this.r=parseInt(t[1][0]+t[1][0],16),this.g=parseInt(t[1][1]+t[1][1],16),this.b=parseInt(t[1][2]+t[1][2],16)),null!==t};var i=/^#([a-f0-9]{6})$/i;n.prototype.hex6=function(A){var t=null;return null!==(t=A.match(i))&&(this.r=parseInt(t[1].substring(0,2),16),this.g=parseInt(t[1].substring(2,4),16),this.b=parseInt(t[1].substring(4,6),16)),null!==t};var o=/^rgb\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*\)$/;n.prototype.rgb=function(A){var t=null;return null!==(t=A.match(o))&&(this.r=Number(t[1]),this.g=Number(t[2]),this.b=Number(t[3])),null!==t};var a=/^rgba\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d?\.?\d+)\s*\)$/;n.prototype.rgba=function(A){var t=null;return null!==(t=A.match(a))&&(this.r=Number(t[1]),this.g=Number(t[2]),this.b=Number(t[3]),this.a=Number(t[4])),null!==t},n.prototype.toString=function(){return null!==this.a&&1!==this.a?"rgba("+[this.r,this.g,this.b,this.a].join(",")+")":"rgb("+[this.r,this.g,this.b].join(",")+")"},n.prototype.namedColor=function(A){A=A.toLowerCase();var t=s[A];if(t)this.r=t[0],this.g=t[1],this.b=t[2];else if("transparent"===A)return this.r=this.g=this.b=this.a=0,!0;return!!t},n.prototype.isColor=!0;var s={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};t.exports=n},{}],4:[function(A,t,e){function n(A,t){var e=g++;if((t=t||{}).logging&&(u.options.logging=!0,u.options.start=Date.now()),t.async=void 0===t.async||t.async,t.allowTaint=void 0!==t.allowTaint&&t.allowTaint,t.removeContainer=void 0===t.removeContainer||t.removeContainer,t.javascriptEnabled=void 0!==t.javascriptEnabled&&t.javascriptEnabled,t.imageTimeout=void 0===t.imageTimeout?1e4:t.imageTimeout,t.renderer="function"==typeof t.renderer?t.renderer:a,t.strict=!!t.strict,"string"==typeof A){if("string"!=typeof t.proxy)return Promise.reject("Proxy must be used when rendering url");var n=null!=t.width?t.width:window.innerWidth,i=null!=t.height?t.height:window.innerHeight;return f(function(A){var t=document.createElement("a");return t.href=A,t.href=t.href,t}(A),t.proxy,document,n,i,t).then(function(A){return r(A.contentWindow.document.documentElement,A,t,n,i)})}var o=(void 0===A?[document.documentElement]:A.length?A:[A])[0];return o.setAttribute(p+e,e),function(A,t,e,n,i){return d(A,A,e,n,t,A.defaultView.pageXOffset,A.defaultView.pageYOffset).then(function(o){u("Document cloned");var a=p+i,s="["+a+"='"+i+"']";A.querySelector(s).removeAttribute(a);var c=o.contentWindow,l=c.document.querySelector(s);return("function"==typeof t.onclone?Promise.resolve(t.onclone(c.document)):Promise.resolve(!0)).then(function(){return r(l,o,t,e,n)})})}(o.ownerDocument,t,o.ownerDocument.defaultView.innerWidth,o.ownerDocument.defaultView.innerHeight,e).then(function(A){return"function"==typeof t.onrendered&&(u("options.onrendered is deprecated, html2canvas returns a Promise containing the canvas"),t.onrendered(A)),A})}function r(A,t,e,n,r){var a=t.contentWindow,l=new o(a.document),h=new s(e,l),d=B(A),f="view"===e.type?n:function(A){return Math.max(Math.max(A.body.scrollWidth,A.documentElement.scrollWidth),Math.max(A.body.offsetWidth,A.documentElement.offsetWidth),Math.max(A.body.clientWidth,A.documentElement.clientWidth))}(a.document),p="view"===e.type?r:function(A){return Math.max(Math.max(A.body.scrollHeight,A.documentElement.scrollHeight),Math.max(A.body.offsetHeight,A.documentElement.offsetHeight),Math.max(A.body.clientHeight,A.documentElement.clientHeight))}(a.document),g=new e.renderer(f,p,h,e,document);return new c(A,g,l,h,e).ready.then(function(){u("Finished rendering");var n;return n="view"===e.type?i(g.canvas,{width:g.canvas.width,height:g.canvas.height,top:0,left:0,x:0,y:0}):A===a.document.body||A===a.document.documentElement||null!=e.canvas?g.canvas:i(g.canvas,{width:null!=e.width?e.width:d.width,height:null!=e.height?e.height:d.height,top:d.top,left:d.left,x:0,y:0}),function(A,t){t.removeContainer&&(A.parentNode.removeChild(A),u("Cleaned up container"))}(t,e),n})}function i(A,t){var e=document.createElement("canvas"),n=Math.min(A.width-1,Math.max(0,t.left)),r=Math.min(A.width,Math.max(1,t.left+t.width)),i=Math.min(A.height-1,Math.max(0,t.top)),o=Math.min(A.height,Math.max(1,t.top+t.height));e.width=t.width,e.height=t.height;var a=r-n,s=o-i;return u("Cropping canvas at:","left:",t.left,"top:",t.top,"width:",a,"height:",s),u("Resulting crop with width",t.width,"and height",t.height,"with x",n,"and y",i),e.getContext("2d").drawImage(A,n,i,a,s,t.x,t.y,a,s),e}var o=A("./support"),a=A("./renderers/canvas"),s=A("./imageloader"),c=A("./nodeparser"),l=A("./nodecontainer"),u=A("./log"),h=A("./utils"),d=A("./clone"),f=A("./proxy").loadUrlDocument,B=h.getBounds,p="data-html2canvas-node",g=0;n.CanvasRenderer=a,n.NodeContainer=l,n.log=u,n.utils=h;var w="undefined"==typeof document||"function"!=typeof Object.create||"function"!=typeof document.createElement("canvas").getContext?function(){return Promise.reject("No canvas support")}:n;t.exports=w},{"./clone":2,"./imageloader":11,"./log":13,"./nodecontainer":14,"./nodeparser":15,"./proxy":16,"./renderers/canvas":20,"./support":22,"./utils":26}],5:[function(A,t,e){function n(A){if(this.src=A,r("DummyImageContainer for",A),!this.promise||!this.image){r("Initiating DummyImageContainer"),n.prototype.image=new Image;var t=this.image;n.prototype.promise=new Promise(function(A,e){t.onload=A,t.onerror=e,t.src=i(),!0===t.complete&&A(t)})}}var r=A("./log"),i=A("./utils").smallImage;t.exports=n},{"./log":13,"./utils":26}],6:[function(A,t,e){var n=A("./utils").smallImage;t.exports=function(A,t){var e,r,i=document.createElement("div"),o=document.createElement("img"),a=document.createElement("span");i.style.visibility="hidden",i.style.fontFamily=A,i.style.fontSize=t,i.style.margin=0,i.style.padding=0,document.body.appendChild(i),o.src=n(),o.width=1,o.height=1,o.style.margin=0,o.style.padding=0,o.style.verticalAlign="baseline",a.style.fontFamily=A,a.style.fontSize=t,a.style.margin=0,a.style.padding=0,a.appendChild(document.createTextNode("Hidden Text")),i.appendChild(a),i.appendChild(o),e=o.offsetTop-a.offsetTop+1,i.removeChild(a),i.appendChild(document.createTextNode("Hidden Text")),i.style.lineHeight="normal",o.style.verticalAlign="super",r=o.offsetTop-i.offsetTop+1,document.body.removeChild(i),this.baseline=e,this.lineWidth=1,this.middle=r}},{"./utils":26}],7:[function(A,t,e){function n(){this.data={}}var r=A("./font");n.prototype.getMetrics=function(A,t){return void 0===this.data[A+"-"+t]&&(this.data[A+"-"+t]=new r(A,t)),this.data[A+"-"+t]},t.exports=n},{"./font":6}],8:[function(A,t,e){function n(t,e,n){this.image=null,this.src=t;var i=this,o=r(t);this.promise=(e?new Promise(function(A){"about:blank"===t.contentWindow.document.URL||null==t.contentWindow.document.documentElement?t.contentWindow.onload=t.onload=function(){A(t)}:A(t)}):this.proxyLoad(n.proxy,o,n)).then(function(t){return A("./core")(t.contentWindow.document.documentElement,{type:"view",width:t.width,height:t.height,proxy:n.proxy,javascriptEnabled:n.javascriptEnabled,removeContainer:n.removeContainer,allowTaint:n.allowTaint,imageTimeout:n.imageTimeout/2})}).then(function(A){return i.image=A})}var r=A("./utils").getBounds,i=A("./proxy").loadUrlDocument;n.prototype.proxyLoad=function(A,t,e){var n=this.src;return i(n.src,A,n.ownerDocument,t.width,t.height,e)},t.exports=n},{"./core":4,"./proxy":16,"./utils":26}],9:[function(A,t,e){function n(A){this.src=A.value,this.colorStops=[],this.type=null,this.x0=.5,this.y0=.5,this.x1=.5,this.y1=.5,this.promise=Promise.resolve(!0)}n.TYPES={LINEAR:1,RADIAL:2},n.REGEXP_COLORSTOP=/^\s*(rgba?\(\s*\d{1,3},\s*\d{1,3},\s*\d{1,3}(?:,\s*[0-9\.]+)?\s*\)|[a-z]{3,20}|#[a-f0-9]{3,6})(?:\s+(\d{1,3}(?:\.\d+)?)(%|px)?)?(?:\s|$)/i,t.exports=n},{}],10:[function(A,t,e){t.exports=function(A,t){this.src=A,this.image=new Image;var e=this;this.tainted=null,this.promise=new Promise(function(n,r){e.image.onload=n,e.image.onerror=r,t&&(e.image.crossOrigin="anonymous"),e.image.src=A,!0===e.image.complete&&n(e.image)})}},{}],11:[function(A,t,e){function n(A,t){this.link=null,this.options=A,this.support=t,this.origin=this.getOrigin(window.location.href)}var r=A("./log"),i=A("./imagecontainer"),o=A("./dummyimagecontainer"),a=A("./proxyimagecontainer"),s=A("./framecontainer"),c=A("./svgcontainer"),l=A("./svgnodecontainer"),u=A("./lineargradientcontainer"),h=A("./webkitgradientcontainer"),d=A("./utils").bind;n.prototype.findImages=function(A){var t=[];return A.reduce(function(A,t){switch(t.node.nodeName){case"IMG":return A.concat([{args:[t.node.src],method:"url"}]);case"svg":case"IFRAME":return A.concat([{args:[t.node],method:t.node.nodeName}])}return A},[]).forEach(this.addImage(t,this.loadImage),this),t},n.prototype.findBackgroundImage=function(A,t){return t.parseBackgroundImages().filter(this.hasImageBackground).forEach(this.addImage(A,this.loadImage),this),A},n.prototype.addImage=function(A,t){return function(e){e.args.forEach(function(n){this.imageExists(A,n)||(A.splice(0,0,t.call(this,e)),r("Added image #"+A.length,"string"==typeof n?n.substring(0,100):n))},this)}},n.prototype.hasImageBackground=function(A){return"none"!==A.method},n.prototype.loadImage=function(A){if("url"===A.method){var t=A.args[0];return!this.isSVG(t)||this.support.svg||this.options.allowTaint?t.match(/data:image\/.*;base64,/i)?new i(t.replace(/url\(['"]{0,}|['"]{0,}\)$/gi,""),!1):this.isSameOrigin(t)||!0===this.options.allowTaint||this.isSVG(t)?new i(t,!1):this.support.cors&&!this.options.allowTaint&&this.options.useCORS?new i(t,!0):this.options.proxy?new a(t,this.options.proxy):new o(t):new c(t)}return"linear-gradient"===A.method?new u(A):"gradient"===A.method?new h(A):"svg"===A.method?new l(A.args[0],this.support.svg):"IFRAME"===A.method?new s(A.args[0],this.isSameOrigin(A.args[0].src),this.options):new o(A)},n.prototype.isSVG=function(A){return"svg"===A.substring(A.length-3).toLowerCase()||c.prototype.isInline(A)},n.prototype.imageExists=function(A,t){return A.some(function(A){return A.src===t})},n.prototype.isSameOrigin=function(A){return this.getOrigin(A)===this.origin},n.prototype.getOrigin=function(A){var t=this.link||(this.link=document.createElement("a"));return t.href=A,t.href=t.href,t.protocol+t.hostname+t.port},n.prototype.getPromise=function(A){return this.timeout(A,this.options.imageTimeout).catch(function(){return new o(A.src).promise.then(function(t){A.image=t})})},n.prototype.get=function(A){var t=null;return this.images.some(function(e){return(t=e).src===A})?t:null},n.prototype.fetch=function(A){return this.images=A.reduce(d(this.findBackgroundImage,this),this.findImages(A)),this.images.forEach(function(A,t){A.promise.then(function(){r("Succesfully loaded image #"+(t+1),A)},function(e){r("Failed loading image #"+(t+1),A,e)})}),this.ready=Promise.all(this.images.map(this.getPromise,this)),r("Finished searching images"),this},n.prototype.timeout=function(A,t){var e,n=Promise.race([A.promise,new Promise(function(n,i){e=setTimeout(function(){r("Timed out loading image",A),i(A)},t)})]).then(function(A){return clearTimeout(e),A});return n.catch(function(){clearTimeout(e)}),n},t.exports=n},{"./dummyimagecontainer":5,"./framecontainer":8,"./imagecontainer":10,"./lineargradientcontainer":12,"./log":13,"./proxyimagecontainer":17,"./svgcontainer":23,"./svgnodecontainer":24,"./utils":26,"./webkitgradientcontainer":27}],12:[function(A,t,e){function n(A){r.apply(this,arguments),this.type=r.TYPES.LINEAR;var t=n.REGEXP_DIRECTION.test(A.args[0])||!r.REGEXP_COLORSTOP.test(A.args[0]);t?A.args[0].split(/\s+/).reverse().forEach(function(A,t){switch(A){case"left":this.x0=0,this.x1=1;break;case"top":this.y0=0,this.y1=1;break;case"right":this.x0=1,this.x1=0;break;case"bottom":this.y0=1,this.y1=0;break;case"to":var e=this.y0,n=this.x0;this.y0=this.y1,this.x0=this.x1,this.x1=n,this.y1=e;break;case"center":break;default:var r=.01*parseFloat(A,10);if(isNaN(r))break;0===t?(this.y0=r,this.y1=1-this.y0):(this.x0=r,this.x1=1-this.x0)}},this):(this.y0=0,this.y1=1),this.colorStops=A.args.slice(t?1:0).map(function(A){var t=A.match(r.REGEXP_COLORSTOP),e=+t[2],n=0===e?"%":t[3];return{color:new i(t[1]),stop:"%"===n?e/100:null}}),null===this.colorStops[0].stop&&(this.colorStops[0].stop=0),null===this.colorStops[this.colorStops.length-1].stop&&(this.colorStops[this.colorStops.length-1].stop=1),this.colorStops.forEach(function(A,t){null===A.stop&&this.colorStops.slice(t).some(function(e,n){return null!==e.stop&&(A.stop=(e.stop-this.colorStops[t-1].stop)/(n+1)+this.colorStops[t-1].stop,!0)},this)},this)}var r=A("./gradientcontainer"),i=A("./color");n.prototype=Object.create(r.prototype),n.REGEXP_DIRECTION=/^\s*(?:to|left|right|top|bottom|center|\d{1,3}(?:\.\d+)?%?)(?:\s|$)/i,t.exports=n},{"./color":3,"./gradientcontainer":9}],13:[function(A,t,e){var n=function(){n.options.logging&&window.console&&window.console.log&&Function.prototype.bind.call(window.console.log,window.console).apply(window.console,[Date.now()-n.options.start+"ms","html2canvas:"].concat([].slice.call(arguments,0)))};n.options={logging:!1},t.exports=n},{}],14:[function(A,t,e){function n(A,t){this.node=A,this.parent=t,this.stack=null,this.bounds=null,this.borders=null,this.clip=[],this.backgroundClip=[],this.offsetBounds=null,this.visible=null,this.computedStyles=null,this.colors={},this.styles={},this.backgroundImages=null,this.transformData=null,this.transformMatrix=null,this.isPseudoElement=!1,this.opacity=null}function r(A){return-1!==A.toString().indexOf("%")}function i(A){return A.replace("px","")}function o(A){return parseFloat(A)}var a=A("./color"),s=A("./utils"),c=s.getBounds,l=s.parseBackgrounds,u=s.offsetBounds;n.prototype.cloneTo=function(A){A.visible=this.visible,A.borders=this.borders,A.bounds=this.bounds,A.clip=this.clip,A.backgroundClip=this.backgroundClip,A.computedStyles=this.computedStyles,A.styles=this.styles,A.backgroundImages=this.backgroundImages,A.opacity=this.opacity},n.prototype.getOpacity=function(){return null===this.opacity?this.opacity=this.cssFloat("opacity"):this.opacity},n.prototype.assignStack=function(A){this.stack=A,A.children.push(this)},n.prototype.isElementVisible=function(){return this.node.nodeType===Node.TEXT_NODE?this.parent.visible:"none"!==this.css("display")&&"hidden"!==this.css("visibility")&&!this.node.hasAttribute("data-html2canvas-ignore")&&("INPUT"!==this.node.nodeName||"hidden"!==this.node.getAttribute("type"))},n.prototype.css=function(A){return this.computedStyles||(this.computedStyles=this.isPseudoElement?this.parent.computedStyle(this.before?":before":":after"):this.computedStyle(null)),this.styles[A]||(this.styles[A]=this.computedStyles[A])},n.prototype.prefixedCss=function(A){var t=this.css(A);return void 0===t&&["webkit","moz","ms","o"].some(function(e){return void 0!==(t=this.css(e+A.substr(0,1).toUpperCase()+A.substr(1)))},this),void 0===t?null:t},n.prototype.computedStyle=function(A){return this.node.ownerDocument.defaultView.getComputedStyle(this.node,A)},n.prototype.cssInt=function(A){var t=parseInt(this.css(A),10);return isNaN(t)?0:t},n.prototype.color=function(A){return this.colors[A]||(this.colors[A]=new a(this.css(A)))},n.prototype.cssFloat=function(A){var t=parseFloat(this.css(A));return isNaN(t)?0:t},n.prototype.fontWeight=function(){var A=this.css("fontWeight");switch(parseInt(A,10)){case 401:A="bold";break;case 400:A="normal"}return A},n.prototype.parseClip=function(){var A=this.css("clip").match(this.CLIP);return A?{top:parseInt(A[1],10),right:parseInt(A[2],10),bottom:parseInt(A[3],10),left:parseInt(A[4],10)}:null},n.prototype.parseBackgroundImages=function(){return this.backgroundImages||(this.backgroundImages=l(this.css("backgroundImage")))},n.prototype.cssList=function(A,t){var e=(this.css(A)||"").split(",");return e=e[t||0]||e[0]||"auto",1===(e=e.trim().split(" ")).length&&(e=[e[0],r(e[0])?"auto":e[0]]),e},n.prototype.parseBackgroundSize=function(A,t,e){var n,i,o=this.cssList("backgroundSize",e);if(r(o[0]))n=A.width*parseFloat(o[0])/100;else{if(/contain|cover/.test(o[0])){var a=A.width/A.height,s=t.width/t.height;return a0?(this.renderIndex=0,this.asyncRenderer(this.renderQueue,A)):A():(this.renderQueue.forEach(this.paint,this),A())},this))},this))}function r(A){return A.parent&&A.parent.clip.length}function i(A){return A.replace(/(\-[a-z])/g,function(A){return A.toUpperCase().replace("-","")})}function o(){}function a(A,t,e,n){return A.map(function(r,i){if(r.width>0){var o=t.left,a=t.top,s=t.width,c=t.height-A[2].width;switch(i){case 0:c=A[0].width,r.args=u({c1:[o,a],c2:[o+s,a],c3:[o+s-A[1].width,a+c],c4:[o+A[3].width,a+c]},n[0],n[1],e.topLeftOuter,e.topLeftInner,e.topRightOuter,e.topRightInner);break;case 1:o=t.left+t.width-A[1].width,s=A[1].width,r.args=u({c1:[o+s,a],c2:[o+s,a+c+A[2].width],c3:[o,a+c],c4:[o,a+A[0].width]},n[1],n[2],e.topRightOuter,e.topRightInner,e.bottomRightOuter,e.bottomRightInner);break;case 2:a=a+t.height-A[2].width,c=A[2].width,r.args=u({c1:[o+s,a+c],c2:[o,a+c],c3:[o+A[3].width,a],c4:[o+s-A[3].width,a]},n[2],n[3],e.bottomRightOuter,e.bottomRightInner,e.bottomLeftOuter,e.bottomLeftInner);break;case 3:s=A[3].width,r.args=u({c1:[o,a+c+A[2].width],c2:[o,a],c3:[o+s,a+A[0].width],c4:[o+s,a+c]},n[3],n[0],e.bottomLeftOuter,e.bottomLeftInner,e.topLeftOuter,e.topLeftInner)}}return r})}function s(A,t,e,n){var r=(Math.sqrt(2)-1)/3*4,i=e*r,o=n*r,a=A+e,s=t+n;return{topLeft:l({x:A,y:s},{x:A,y:s-o},{x:a-i,y:t},{x:a,y:t}),topRight:l({x:A,y:t},{x:A+i,y:t},{x:a,y:s-o},{x:a,y:s}),bottomRight:l({x:a,y:t},{x:a,y:t+o},{x:A+i,y:s},{x:A,y:s}),bottomLeft:l({x:a,y:s},{x:a-i,y:s},{x:A,y:t+o},{x:A,y:t})}}function c(A,t,e){var n=A.left,r=A.top,i=A.width,o=A.height,a=t[0][0]i+e[3].width?0:l-e[3].width,u-e[0].width).topRight.subdivide(.5),bottomRightOuter:s(n+w,r+g,h,d).bottomRight.subdivide(.5),bottomRightInner:s(n+Math.min(w,i-e[3].width),r+Math.min(g,o+e[0].width),Math.max(0,h-e[1].width),d-e[2].width).bottomRight.subdivide(.5),bottomLeftOuter:s(n,r+m,f,B).bottomLeft.subdivide(.5),bottomLeftInner:s(n+e[3].width,r+m,Math.max(0,f-e[3].width),B-e[2].width).bottomLeft.subdivide(.5)}}function l(A,t,e,n){var r=function(A,t,e){return{x:A.x+(t.x-A.x)*e,y:A.y+(t.y-A.y)*e}};return{start:A,startControl:t,endControl:e,end:n,subdivide:function(i){var o=r(A,t,i),a=r(t,e,i),s=r(e,n,i),c=r(o,a,i),u=r(a,s,i),h=r(c,u,i);return[l(A,o,c,h),l(h,u,s,n)]},curveTo:function(A){A.push(["bezierCurve",t.x,t.y,e.x,e.y,n.x,n.y])},curveToReversed:function(n){n.push(["bezierCurve",e.x,e.y,t.x,t.y,A.x,A.y])}}}function u(A,t,e,n,r,i,o){var a=[];return t[0]>0||t[1]>0?(a.push(["line",n[1].start.x,n[1].start.y]),n[1].curveTo(a)):a.push(["line",A.c1[0],A.c1[1]]),e[0]>0||e[1]>0?(a.push(["line",i[0].start.x,i[0].start.y]),i[0].curveTo(a),a.push(["line",o[0].end.x,o[0].end.y]),o[0].curveToReversed(a)):(a.push(["line",A.c2[0],A.c2[1]]),a.push(["line",A.c3[0],A.c3[1]])),t[0]>0||t[1]>0?(a.push(["line",r[1].end.x,r[1].end.y]),r[1].curveToReversed(a)):a.push(["line",A.c4[0],A.c4[1]]),a}function h(A,t,e,n,r,i,o){t[0]>0||t[1]>0?(A.push(["line",n[0].start.x,n[0].start.y]),n[0].curveTo(A),n[1].curveTo(A)):A.push(["line",i,o]),(e[0]>0||e[1]>0)&&A.push(["line",r[0].start.x,r[0].start.y])}function d(A){return A.cssInt("zIndex")<0}function f(A){return A.cssInt("zIndex")>0}function B(A){return 0===A.cssInt("zIndex")}function p(A){return-1!==["inline","inline-block","inline-table"].indexOf(A.css("display"))}function g(A){return A instanceof P}function w(A){return A.node.data.trim().length>0}function m(A){return A.nodeType===Node.TEXT_NODE||A.nodeType===Node.ELEMENT_NODE}function Q(A){return"static"!==A.css("position")}function C(A){return"none"!==A.css("float")}function y(A){var t=this;return function(){return!A.apply(t,arguments)}}function v(A){return A.node.nodeType===Node.ELEMENT_NODE}function U(A){return!0===A.isPseudoElement}function F(A){return A.node.nodeType===Node.TEXT_NODE}function E(A){return parseInt(A,10)}function b(A){return A.width}function H(A){return A.node.nodeType!==Node.ELEMENT_NODE||-1===["SCRIPT","HEAD","TITLE","OBJECT","BR","OPTION"].indexOf(A.node.nodeName)}function x(A){return[].concat.apply([],A)}var _=A("./log"),I=A("punycode"),T=A("./nodecontainer"),S=A("./textcontainer"),N=A("./pseudoelementcontainer"),O=A("./fontmetrics"),k=A("./color"),P=A("./stackingcontext"),L=A("./utils"),D=L.bind,R=L.getBounds,K=L.parseBackgrounds,M=L.offsetBounds;n.prototype.calculateOverflowClips=function(){this.nodes.forEach(function(A){if(v(A)){U(A)&&A.appendToDOM(),A.borders=this.parseBorders(A);var t="hidden"===A.css("overflow")?[A.borders.clip]:[],e=A.parseClip();e&&-1!==["absolute","fixed"].indexOf(A.css("position"))&&t.push([["rect",A.bounds.left+e.left,A.bounds.top+e.top,e.right-e.left,e.bottom-e.top]]),A.clip=r(A)?A.parent.clip.concat(t):t,A.backgroundClip="hidden"!==A.css("overflow")?A.clip.concat([A.borders.clip]):A.clip,U(A)&&A.cleanDOM()}else F(A)&&(A.clip=r(A)?A.parent.clip:[]);U(A)||(A.bounds=null)},this)},n.prototype.asyncRenderer=function(A,t,e){e=e||Date.now(),this.paint(A[this.renderIndex++]),A.length===this.renderIndex?t():e+20>Date.now()?this.asyncRenderer(A,t,e):setTimeout(D(function(){this.asyncRenderer(A,t)},this),0)},n.prototype.createPseudoHideStyles=function(A){this.createStyles(A,"."+N.prototype.PSEUDO_HIDE_ELEMENT_CLASS_BEFORE+':before { content: "" !important; display: none !important; }.'+N.prototype.PSEUDO_HIDE_ELEMENT_CLASS_AFTER+':after { content: "" !important; display: none !important; }')},n.prototype.disableAnimations=function(A){this.createStyles(A,"* { -webkit-animation: none !important; -moz-animation: none !important; -o-animation: none !important; animation: none !important; -webkit-transition: none !important; -moz-transition: none !important; -o-transition: none !important; transition: none !important;}")},n.prototype.createStyles=function(A,t){var e=A.createElement("style");e.innerHTML=t,A.body.appendChild(e)},n.prototype.getPseudoElements=function(A){var t=[[A]];if(A.node.nodeType===Node.ELEMENT_NODE){var e=this.getPseudoElement(A,":before"),n=this.getPseudoElement(A,":after");e&&t.push(e),n&&t.push(n)}return x(t)},n.prototype.getPseudoElement=function(A,t){var e=A.computedStyle(t);if(!e||!e.content||"none"===e.content||"-moz-alt-content"===e.content||"none"===e.display)return null;for(var n=function(A){var t=A.substr(0,1);return t===A.substr(A.length-1)&&t.match(/'|"/)?A.substr(1,A.length-2):A}(e.content),r="url"===n.substr(0,3),o=document.createElement(r?"img":"html2canvaspseudoelement"),a=new N(o,A,t),s=e.length-1;s>=0;s--){var c=i(e.item(s));o.style[c]=e[c]}if(o.className=N.prototype.PSEUDO_HIDE_ELEMENT_CLASS_BEFORE+" "+N.prototype.PSEUDO_HIDE_ELEMENT_CLASS_AFTER,r)return o.src=K(n)[0].args[0],[a];var l=document.createTextNode(n);return o.appendChild(l),[a,new S(l,a)]},n.prototype.getChildren=function(A){return x([].filter.call(A.node.childNodes,m).map(function(t){var e=[t.nodeType===Node.TEXT_NODE?new S(t,A):new T(t,A)].filter(H);return t.nodeType===Node.ELEMENT_NODE&&e.length&&"TEXTAREA"!==t.tagName?e[0].isElementVisible()?e.concat(this.getChildren(e[0])):[]:e},this))},n.prototype.newStackingContext=function(A,t){var e=new P(t,A.getOpacity(),A.node,A.parent);A.cloneTo(e),(t?e.getParentStack(this):e.parent.stack).contexts.push(e),A.stack=e},n.prototype.createStackingContexts=function(){this.nodes.forEach(function(A){v(A)&&(this.isRootElement(A)||function(A){return A.getOpacity()<1}(A)||function(A){var t=A.css("position");return"auto"!==(-1!==["absolute","relative","fixed"].indexOf(t)?A.css("zIndex"):"auto")}(A)||this.isBodyWithTransparentRoot(A)||A.hasTransform())?this.newStackingContext(A,!0):v(A)&&(Q(A)&&B(A)||function(A){return-1!==["inline-block","inline-table"].indexOf(A.css("display"))}(A)||C(A))?this.newStackingContext(A,!1):A.assignStack(A.parent.stack)},this)},n.prototype.isBodyWithTransparentRoot=function(A){return"BODY"===A.node.nodeName&&A.parent.color("backgroundColor").isTransparent()},n.prototype.isRootElement=function(A){return null===A.parent},n.prototype.sortStackingContexts=function(A){A.contexts.sort(function(A){return function(t,e){return t.cssInt("zIndex")+A.indexOf(t)/A.length-(e.cssInt("zIndex")+A.indexOf(e)/A.length)}}(A.contexts.slice(0))),A.contexts.forEach(this.sortStackingContexts,this)},n.prototype.parseTextBounds=function(A){return function(t,e,n){if("none"!==A.parent.css("textDecoration").substr(0,4)||0!==t.trim().length){if(this.support.rangeBounds&&!A.parent.hasTransform()){var r=n.slice(0,e).join("").length;return this.getRangeBounds(A.node,r,t.length)}if(A.node&&"string"==typeof A.node.data){var i=A.node.splitText(t.length),o=this.getWrapperBounds(A.node,A.parent.hasTransform());return A.node=i,o}}else this.support.rangeBounds&&!A.parent.hasTransform()||(A.node=A.node.splitText(t.length));return{}}},n.prototype.getWrapperBounds=function(A,t){var e=A.ownerDocument.createElement("html2canvaswrapper"),n=A.parentNode,r=A.cloneNode(!0);e.appendChild(A.cloneNode(!0)),n.replaceChild(e,A);var i=t?M(e):R(e);return n.replaceChild(r,e),i},n.prototype.getRangeBounds=function(A,t,e){var n=this.range||(this.range=A.ownerDocument.createRange());return n.setStart(A,t),n.setEnd(A,t+e),n.getBoundingClientRect()},n.prototype.parse=function(A){var t=A.contexts.filter(d),e=A.children.filter(v),n=e.filter(y(C)),r=n.filter(y(Q)).filter(y(p)),i=e.filter(y(Q)).filter(C),a=n.filter(y(Q)).filter(p),s=A.contexts.concat(n.filter(Q)).filter(B),c=A.children.filter(F).filter(w),l=A.contexts.filter(f);t.concat(r).concat(i).concat(a).concat(s).concat(c).concat(l).forEach(function(A){this.renderQueue.push(A),g(A)&&(this.parse(A),this.renderQueue.push(new o))},this)},n.prototype.paint=function(A){try{A instanceof o?this.renderer.ctx.restore():F(A)?(U(A.parent)&&A.parent.appendToDOM(),this.paintText(A),U(A.parent)&&A.parent.cleanDOM()):this.paintNode(A)}catch(A){if(_(A),this.options.strict)throw A}},n.prototype.paintNode=function(A){g(A)&&(this.renderer.setOpacity(A.opacity),this.renderer.ctx.save(),A.hasTransform()&&this.renderer.setTransform(A.parseTransform())),"INPUT"===A.node.nodeName&&"checkbox"===A.node.type?this.paintCheckbox(A):"INPUT"===A.node.nodeName&&"radio"===A.node.type?this.paintRadio(A):this.paintElement(A)},n.prototype.paintElement=function(A){var t=A.parseBounds();this.renderer.clip(A.backgroundClip,function(){this.renderer.renderBackground(A,t,A.borders.borders.map(b))},this),this.renderer.clip(A.clip,function(){this.renderer.renderBorders(A.borders.borders)},this),this.renderer.clip(A.backgroundClip,function(){switch(A.node.nodeName){case"svg":case"IFRAME":var e=this.images.get(A.node);e?this.renderer.renderImage(A,t,A.borders,e):_("Error loading <"+A.node.nodeName+">",A.node);break;case"IMG":var n=this.images.get(A.node.src);n?this.renderer.renderImage(A,t,A.borders,n):_("Error loading
",A.node.src);break;case"CANVAS":this.renderer.renderImage(A,t,A.borders,{image:A.node});break;case"SELECT":case"INPUT":case"TEXTAREA":this.paintFormValue(A)}},this)},n.prototype.paintCheckbox=function(A){var t=A.parseBounds(),e=Math.min(t.width,t.height),n={width:e-1,height:e-1,top:t.top,left:t.left},r=[3,3],i=[r,r,r,r],o=[1,1,1,1].map(function(A){return{color:new k("#A5A5A5"),width:A}}),s=c(n,i,o);this.renderer.clip(A.backgroundClip,function(){this.renderer.rectangle(n.left+1,n.top+1,n.width-2,n.height-2,new k("#DEDEDE")),this.renderer.renderBorders(a(o,n,s,i)),A.node.checked&&(this.renderer.font(new k("#424242"),"normal","normal","bold",e-3+"px","arial"),this.renderer.text("✔",n.left+e/6,n.top+e-1))},this)},n.prototype.paintRadio=function(A){var t=A.parseBounds(),e=Math.min(t.width,t.height)-2;this.renderer.clip(A.backgroundClip,function(){this.renderer.circleStroke(t.left+1,t.top+1,e,new k("#DEDEDE"),1,new k("#A5A5A5")),A.node.checked&&this.renderer.circle(Math.ceil(t.left+e/4)+1,Math.ceil(t.top+e/4)+1,Math.floor(e/2),new k("#424242"))},this)},n.prototype.paintFormValue=function(A){var t=A.getValue();if(t.length>0){var e=A.node.ownerDocument,n=e.createElement("html2canvaswrapper");["lineHeight","textAlign","fontFamily","fontWeight","fontSize","color","paddingLeft","paddingTop","paddingRight","paddingBottom","width","height","borderLeftStyle","borderTopStyle","borderLeftWidth","borderTopWidth","boxSizing","whiteSpace","wordWrap"].forEach(function(t){try{n.style[t]=A.css(t)}catch(A){_("html2canvas: Parse: Exception caught in renderFormValue: "+A.message)}});var r=A.parseBounds();n.style.position="fixed",n.style.left=r.left+"px",n.style.top=r.top+"px",n.textContent=t,e.body.appendChild(n),this.paintText(new S(n.firstChild,A)),e.body.removeChild(n)}},n.prototype.paintText=function(A){A.applyTextTransform();var t=I.ucs2.decode(A.node.data),e=this.options.letterRendering&&!function(A){return/^(normal|none|0px)$/.test(A.parent.css("letterSpacing"))}(A)||function(A){return/[^\u0000-\u00ff]/.test(A)}(A.node.data)?t.map(function(A){return I.ucs2.encode([A])}):function(A){for(var t,e=[],n=0,r=!1;A.length;)(function(A){return-1!==[32,13,10,9,45].indexOf(A)})(A[n])===r?((t=A.splice(0,n)).length&&e.push(I.ucs2.encode(t)),r=!r,n=0):n++,n>=A.length&&(t=A.splice(0,n)).length&&e.push(I.ucs2.encode(t));return e}(t),n=A.parent.fontWeight(),r=A.parent.css("fontSize"),i=A.parent.css("fontFamily"),o=A.parent.parseTextShadows();this.renderer.font(A.parent.color("color"),A.parent.css("fontStyle"),A.parent.css("fontVariant"),n,r,i),o.length?this.renderer.fontShadow(o[0].color,o[0].offsetX,o[0].offsetY,o[0].blur):this.renderer.clearShadow(),this.renderer.clip(A.parent.clip,function(){e.map(this.parseTextBounds(A),this).forEach(function(t,n){t&&(this.renderer.text(e[n],t.left,t.bottom),this.renderTextDecoration(A.parent,t,this.fontMetrics.getMetrics(i,r)))},this)},this)},n.prototype.renderTextDecoration=function(A,t,e){switch(A.css("textDecoration").split(" ")[0]){case"underline":this.renderer.rectangle(t.left,Math.round(t.top+e.baseline+e.lineWidth),t.width,1,A.color("color"));break;case"overline":this.renderer.rectangle(t.left,Math.round(t.top),t.width,1,A.color("color"));break;case"line-through":this.renderer.rectangle(t.left,Math.ceil(t.top+e.middle+e.lineWidth),t.width,1,A.color("color"))}};var z={inset:[["darken",.6],["darken",.1],["darken",.1],["darken",.6]]};n.prototype.parseBorders=function(A){var t=A.parseBounds(),e=function(A){return["TopLeft","TopRight","BottomRight","BottomLeft"].map(function(t){var e=A.css("border"+t+"Radius").split(" ");return e.length<=1&&(e[1]=e[0]),e.map(E)})}(A),n=["Top","Right","Bottom","Left"].map(function(t,e){var n=A.css("border"+t+"Style"),r=A.color("border"+t+"Color");"inset"===n&&r.isBlack()&&(r=new k([255,255,255,r.a]));var i=z[n]?z[n][e]:null;return{width:A.cssInt("border"+t+"Width"),color:i?r[i[0]](i[1]):r,args:null}}),r=c(t,e,n);return{clip:this.parseBackgroundClip(A,r,n,e,t),borders:a(n,t,r,e)}},n.prototype.parseBackgroundClip=function(A,t,e,n,r){var i=[];switch(A.css("backgroundClip")){case"content-box":case"padding-box":h(i,n[0],n[1],t.topLeftInner,t.topRightInner,r.left+e[3].width,r.top+e[0].width),h(i,n[1],n[2],t.topRightInner,t.bottomRightInner,r.left+r.width-e[1].width,r.top+e[0].width),h(i,n[2],n[3],t.bottomRightInner,t.bottomLeftInner,r.left+r.width-e[1].width,r.top+r.height-e[2].width),h(i,n[3],n[0],t.bottomLeftInner,t.topLeftInner,r.left+e[3].width,r.top+r.height-e[2].width);break;default:h(i,n[0],n[1],t.topLeftOuter,t.topRightOuter,r.left,r.top),h(i,n[1],n[2],t.topRightOuter,t.bottomRightOuter,r.left+r.width,r.top),h(i,n[2],n[3],t.bottomRightOuter,t.bottomLeftOuter,r.left+r.width,r.top+r.height),h(i,n[3],n[0],t.bottomLeftOuter,t.topLeftOuter,r.left,r.top+r.height)}return i},t.exports=n},{"./color":3,"./fontmetrics":7,"./log":13,"./nodecontainer":14,"./pseudoelementcontainer":18,"./stackingcontext":21,"./textcontainer":25,"./utils":26,punycode:1}],16:[function(A,t,e){function n(A,t,e){var n="withCredentials"in new XMLHttpRequest;if(!t)return Promise.reject("No proxy configured");var s=i(n),c=o(t,A,s);return n?a(c):r(e,c,s).then(function(A){return u(A.content)})}function r(A,t,e){return new Promise(function(n,r){var i=A.createElement("script"),o=function(){delete window.html2canvas.proxy[e],A.body.removeChild(i)};window.html2canvas.proxy[e]=function(A){o(),n(A)},i.src=t,i.onerror=function(A){o(),r(A)},A.body.appendChild(i)})}function i(A){return A?"":"html2canvas_"+Date.now()+"_"+ ++h+"_"+Math.round(1e5*Math.random())}function o(A,t,e){return A+"?url="+encodeURIComponent(t)+(e.length?"&callback=html2canvas.proxy."+e:"")}var a=A("./xhr"),s=A("./utils"),c=A("./log"),l=A("./clone"),u=s.decode64,h=0;e.Proxy=n,e.ProxyURL=function(A,t,e){var n="crossOrigin"in new Image,a=i(n),s=o(t,A,a);return n?Promise.resolve(s):r(e,s,a).then(function(A){return"data:"+A.type+";base64,"+A.content})},e.loadUrlDocument=function(A,t,e,r,i,o){return new n(A,t,window.document).then(function(A){return function(t){var e,n=new DOMParser;try{e=n.parseFromString(t,"text/html")}catch(A){c("DOMParser not supported, falling back to createHTMLDocument"),e=document.implementation.createHTMLDocument("");try{e.open(),e.write(t),e.close()}catch(A){c("createHTMLDocument write not supported, falling back to document.body.innerHTML"),e.body.innerHTML=t}}var r=e.querySelector("base");if(!r||!r.href.host){var i=e.createElement("base");i.href=A,e.head.insertBefore(i,e.head.firstChild)}return e}}(A)).then(function(A){return l(A,e,r,i,o,0,0)})}},{"./clone":2,"./log":13,"./utils":26,"./xhr":28}],17:[function(A,t,e){var n=A("./proxy").ProxyURL;t.exports=function(A,t){var e=document.createElement("a");e.href=A,A=e.href,this.src=A,this.image=new Image;var r=this;this.promise=new Promise(function(e,i){r.image.crossOrigin="Anonymous",r.image.onload=e,r.image.onerror=i,new n(A,t,document).then(function(A){r.image.src=A}).catch(i)})}},{"./proxy":16}],18:[function(A,t,e){function n(A,t,e){r.call(this,A,t),this.isPseudoElement=!0,this.before=":before"===e}var r=A("./nodecontainer");n.prototype.cloneTo=function(A){n.prototype.cloneTo.call(this,A),A.isPseudoElement=!0,A.before=this.before},(n.prototype=Object.create(r.prototype)).appendToDOM=function(){this.before?this.parent.node.insertBefore(this.node,this.parent.node.firstChild):this.parent.node.appendChild(this.node),this.parent.node.className+=" "+this.getHideClass()},n.prototype.cleanDOM=function(){this.node.parentNode.removeChild(this.node),this.parent.node.className=this.parent.node.className.replace(this.getHideClass(),"")},n.prototype.getHideClass=function(){return this["PSEUDO_HIDE_ELEMENT_CLASS_"+(this.before?"BEFORE":"AFTER")]},n.prototype.PSEUDO_HIDE_ELEMENT_CLASS_BEFORE="___html2canvas___pseudoelement_before",n.prototype.PSEUDO_HIDE_ELEMENT_CLASS_AFTER="___html2canvas___pseudoelement_after",t.exports=n},{"./nodecontainer":14}],19:[function(A,t,e){function n(A,t,e,n,r){this.width=A,this.height=t,this.images=e,this.options=n,this.document=r}var r=A("./log");n.prototype.renderImage=function(A,t,e,n){var r=A.cssInt("paddingLeft"),i=A.cssInt("paddingTop"),o=A.cssInt("paddingRight"),a=A.cssInt("paddingBottom"),s=e.borders,c=t.width-(s[1].width+s[3].width+r+o),l=t.height-(s[0].width+s[2].width+i+a);this.drawImage(n,0,0,n.image.width||c,n.image.height||l,t.left+r+s[3].width,t.top+i+s[0].width,c,l)},n.prototype.renderBackground=function(A,t,e){t.height>0&&t.width>0&&(this.renderBackgroundColor(A,t),this.renderBackgroundImage(A,t,e))},n.prototype.renderBackgroundColor=function(A,t){var e=A.color("backgroundColor");e.isTransparent()||this.rectangle(t.left,t.top,t.width,t.height,e)},n.prototype.renderBorders=function(A){A.forEach(this.renderBorder,this)},n.prototype.renderBorder=function(A){A.color.isTransparent()||null===A.args||this.drawShape(A.args,A.color)},n.prototype.renderBackgroundImage=function(A,t,e){A.parseBackgroundImages().reverse().forEach(function(n,i,o){switch(n.method){case"url":var a=this.images.get(n.args[0]);a?this.renderBackgroundRepeating(A,t,a,o.length-(i+1),e):r("Error loading background-image",n.args[0]);break;case"linear-gradient":case"gradient":var s=this.images.get(n.value);s?this.renderBackgroundGradient(s,t,e):r("Error loading background-image",n.args[0]);break;case"none":break;default:r("Unknown background-image type",n.args[0])}},this)},n.prototype.renderBackgroundRepeating=function(A,t,e,n,r){var i=A.parseBackgroundSize(t,e.image,n),o=A.parseBackgroundPosition(t,e.image,n,i);switch(A.parseBackgroundRepeat(n)){case"repeat-x":case"repeat no-repeat":this.backgroundRepeatShape(e,o,i,t,t.left+r[3],t.top+o.top+r[0],99999,i.height,r);break;case"repeat-y":case"no-repeat repeat":this.backgroundRepeatShape(e,o,i,t,t.left+o.left+r[3],t.top+r[0],i.width,99999,r);break;case"no-repeat":this.backgroundRepeatShape(e,o,i,t,t.left+o.left+r[3],t.top+o.top+r[0],i.width,i.height,r);break;default:this.renderBackgroundRepeat(e,o,i,{top:t.top,left:t.left},r[3],r[0])}},t.exports=n},{"./log":13}],20:[function(A,t,e){function n(A,t){i.apply(this,arguments),this.canvas=this.options.canvas||this.document.createElement("canvas"),this.options.canvas||(this.canvas.width=A,this.canvas.height=t),this.ctx=this.canvas.getContext("2d"),this.taintCtx=this.document.createElement("canvas").getContext("2d"),this.ctx.textBaseline="bottom",this.variables={},a("Initialized CanvasRenderer with size",A,"x",t)}function r(A){return A.length>0}var i=A("../renderer"),o=A("../lineargradientcontainer"),a=A("../log");(n.prototype=Object.create(i.prototype)).setFillStyle=function(A){return this.ctx.fillStyle="object"==typeof A&&A.isColor?A.toString():A,this.ctx},n.prototype.rectangle=function(A,t,e,n,r){this.setFillStyle(r).fillRect(A,t,e,n)},n.prototype.circle=function(A,t,e,n){this.setFillStyle(n),this.ctx.beginPath(),this.ctx.arc(A+e/2,t+e/2,e/2,0,2*Math.PI,!0),this.ctx.closePath(),this.ctx.fill()},n.prototype.circleStroke=function(A,t,e,n,r,i){this.circle(A,t,e,n),this.ctx.strokeStyle=i.toString(),this.ctx.stroke()},n.prototype.drawShape=function(A,t){this.shape(A),this.setFillStyle(t).fill()},n.prototype.taints=function(A){if(null===A.tainted){this.taintCtx.drawImage(A.image,0,0);try{this.taintCtx.getImageData(0,0,1,1),A.tainted=!1}catch(t){this.taintCtx=document.createElement("canvas").getContext("2d"),A.tainted=!0}}return A.tainted},n.prototype.drawImage=function(A,t,e,n,r,i,o,a,s){this.taints(A)&&!this.options.allowTaint||this.ctx.drawImage(A.image,t,e,n,r,i,o,a,s)},n.prototype.clip=function(A,t,e){this.ctx.save(),A.filter(r).forEach(function(A){this.shape(A).clip()},this),t.call(e),this.ctx.restore()},n.prototype.shape=function(A){return this.ctx.beginPath(),A.forEach(function(A,t){"rect"===A[0]?this.ctx.rect.apply(this.ctx,A.slice(1)):this.ctx[0===t?"moveTo":A[0]+"To"].apply(this.ctx,A.slice(1))},this),this.ctx.closePath(),this.ctx},n.prototype.font=function(A,t,e,n,r,i){this.setFillStyle(A).font=[t,e,n,r,i].join(" ").split(",")[0]},n.prototype.fontShadow=function(A,t,e,n){this.setVariable("shadowColor",A.toString()).setVariable("shadowOffsetY",t).setVariable("shadowOffsetX",e).setVariable("shadowBlur",n)},n.prototype.clearShadow=function(){this.setVariable("shadowColor","rgba(0,0,0,0)")},n.prototype.setOpacity=function(A){this.ctx.globalAlpha=A},n.prototype.setTransform=function(A){this.ctx.translate(A.origin[0],A.origin[1]),this.ctx.transform.apply(this.ctx,A.matrix),this.ctx.translate(-A.origin[0],-A.origin[1])},n.prototype.setVariable=function(A,t){return this.variables[A]!==t&&(this.variables[A]=this.ctx[A]=t),this},n.prototype.text=function(A,t,e){this.ctx.fillText(A,t,e)},n.prototype.backgroundRepeatShape=function(A,t,e,n,r,i,o,a,s){var c=[["line",Math.round(r),Math.round(i)],["line",Math.round(r+o),Math.round(i)],["line",Math.round(r+o),Math.round(a+i)],["line",Math.round(r),Math.round(a+i)]];this.clip([c],function(){this.renderBackgroundRepeat(A,t,e,n,s[3],s[0])},this)},n.prototype.renderBackgroundRepeat=function(A,t,e,n,r,i){var o=Math.round(n.left+t.left+r),a=Math.round(n.top+t.top+i);this.setFillStyle(this.ctx.createPattern(this.resizeImage(A,e),"repeat")),this.ctx.translate(o,a),this.ctx.fill(),this.ctx.translate(-o,-a)},n.prototype.renderBackgroundGradient=function(A,t){if(A instanceof o){var e=this.ctx.createLinearGradient(t.left+t.width*A.x0,t.top+t.height*A.y0,t.left+t.width*A.x1,t.top+t.height*A.y1);A.colorStops.forEach(function(A){e.addColorStop(A.stop,A.color.toString())}),this.rectangle(t.left,t.top,t.width,t.height,e)}},n.prototype.resizeImage=function(A,t){var e=A.image;if(e.width===t.width&&e.height===t.height)return e;var n=document.createElement("canvas");return n.width=t.width,n.height=t.height,n.getContext("2d").drawImage(e,0,0,e.width,e.height,0,0,t.width,t.height),n},t.exports=n},{"../lineargradientcontainer":12,"../log":13,"../renderer":19}],21:[function(A,t,e){function n(A,t,e,n){r.call(this,e,n),this.ownStacking=A,this.contexts=[],this.children=[],this.opacity=(this.parent?this.parent.stack.opacity:1)*t}var r=A("./nodecontainer");(n.prototype=Object.create(r.prototype)).getParentStack=function(A){var t=this.parent?this.parent.stack:null;return t?t.ownStacking?t:t.getParentStack(A):A.stack},t.exports=n},{"./nodecontainer":14}],22:[function(A,t,e){function n(A){this.rangeBounds=this.testRangeBounds(A),this.cors=this.testCORS(),this.svg=this.testSVG()}n.prototype.testRangeBounds=function(A){var t,e,n=!1;return A.createRange&&(t=A.createRange()).getBoundingClientRect&&((e=A.createElement("boundtest")).style.height="123px",e.style.display="block",A.body.appendChild(e),t.selectNode(e),123===t.getBoundingClientRect().height&&(n=!0),A.body.removeChild(e)),n},n.prototype.testCORS=function(){return void 0!==(new Image).crossOrigin},n.prototype.testSVG=function(){var A=new Image,t=document.createElement("canvas"),e=t.getContext("2d");A.src="data:image/svg+xml,";try{e.drawImage(A,0,0),t.toDataURL()}catch(A){return!1}return!0},t.exports=n},{}],23:[function(A,t,e){function n(A){this.src=A,this.image=null;var t=this;this.promise=this.hasFabric().then(function(){return t.isInline(A)?Promise.resolve(t.inlineFormatting(A)):r(A)}).then(function(A){return new Promise(function(e){window.html2canvas.svg.fabric.loadSVGFromString(A,t.createCanvas.call(t,e))})})}var r=A("./xhr"),i=A("./utils").decode64;n.prototype.hasFabric=function(){return window.html2canvas.svg&&window.html2canvas.svg.fabric?Promise.resolve():Promise.reject(new Error("html2canvas.svg.js is not loaded, cannot render svg"))},n.prototype.inlineFormatting=function(A){return/^data:image\/svg\+xml;base64,/.test(A)?this.decode64(this.removeContentType(A)):this.removeContentType(A)},n.prototype.removeContentType=function(A){return A.replace(/^data:image\/svg\+xml(;base64)?,/,"")},n.prototype.isInline=function(A){return/^data:image\/svg\+xml/i.test(A)},n.prototype.createCanvas=function(A){var t=this;return function(e,n){var r=new window.html2canvas.svg.fabric.StaticCanvas("c");t.image=r.lowerCanvasEl,r.setWidth(n.width).setHeight(n.height).add(window.html2canvas.svg.fabric.util.groupSVGElements(e,n)).renderAll(),A(r.lowerCanvasEl)}},n.prototype.decode64=function(A){return"function"==typeof window.atob?window.atob(A):i(A)},t.exports=n},{"./utils":26,"./xhr":28}],24:[function(A,t,e){function n(A,t){this.src=A,this.image=null;var e=this;this.promise=t?new Promise(function(t,n){e.image=new Image,e.image.onload=t,e.image.onerror=n,e.image.src="data:image/svg+xml,"+(new XMLSerializer).serializeToString(A),!0===e.image.complete&&t(e.image)}):this.hasFabric().then(function(){return new Promise(function(t){window.html2canvas.svg.fabric.parseSVGDocument(A,e.createCanvas.call(e,t))})})}var r=A("./svgcontainer");n.prototype=Object.create(r.prototype),t.exports=n},{"./svgcontainer":23}],25:[function(A,t,e){function n(A,t){i.call(this,A,t)}function r(A,t,e){if(A.length>0)return t+e.toUpperCase()}var i=A("./nodecontainer");(n.prototype=Object.create(i.prototype)).applyTextTransform=function(){this.node.data=this.transform(this.parent.css("textTransform"))},n.prototype.transform=function(A){var t=this.node.data;switch(A){case"lowercase":return t.toLowerCase();case"capitalize":return t.replace(/(^|\s|:|-|\(|\))([a-z])/g,r);case"uppercase":return t.toUpperCase();default:return t}},t.exports=n},{"./nodecontainer":14}],26:[function(A,t,e){e.smallImage=function(){return"data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"},e.bind=function(A,t){return function(){return A.apply(t,arguments)}},e.decode64=function(A){var t,e,n,r,i,o,a,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",c=A.length,l="";for(t=0;t>4,o=(15&e)<<4|(n=s.indexOf(A[t+2]))>>2,a=(3&n)<<6|(r=s.indexOf(A[t+3])),l+=64===n?String.fromCharCode(i):64===r||-1===r?String.fromCharCode(i,o):String.fromCharCode(i,o,a);return l},e.getBounds=function(A){if(A.getBoundingClientRect){var t=A.getBoundingClientRect(),e=null==A.offsetWidth?t.width:A.offsetWidth;return{top:t.top,bottom:t.bottom||t.top+t.height,right:t.left+e,left:t.left,width:e,height:null==A.offsetHeight?t.height:A.offsetHeight}}return{}},e.offsetBounds=function(A){var t=A.offsetParent?e.offsetBounds(A.offsetParent):{top:0,left:0};return{top:A.offsetTop+t.top,bottom:A.offsetTop+A.offsetHeight+t.top,right:A.offsetLeft+t.left+A.offsetWidth,left:A.offsetLeft+t.left,width:A.offsetWidth,height:A.offsetHeight}},e.parseBackgrounds=function(A){var t,e,n,r,i,o,a,s=[],c=0,l=0,u=function(){t&&('"'===e.substr(0,1)&&(e=e.substr(1,e.length-2)),e&&a.push(e),"-"===t.substr(0,1)&&(r=t.indexOf("-",1)+1)>0&&(n=t.substr(0,r),t=t.substr(r)),s.push({prefix:n,method:t.toLowerCase(),value:i,args:a,image:null})),a=[],t=n=e=i=""};return a=[],t=n=e=i="",A.split("").forEach(function(A){if(!(0===c&&" \r\n\t".indexOf(A)>-1)){switch(A){case'"':o?o===A&&(o=null):o=A;break;case"(":if(o)break;if(0===c)return c=1,void(i+=A);l++;break;case")":if(o)break;if(1===c){if(0===l)return c=0,i+=A,void u();l--}break;case",":if(o)break;if(0===c)return void u();if(1===c&&0===l&&!t.match(/^url$/i))return a.push(e),e="",void(i+=A)}i+=A,0===c?t+=A:e+=A}}),u(),s}},{}],27:[function(A,t,e){function n(A){r.apply(this,arguments),this.type="linear"===A.args[0]?r.TYPES.LINEAR:r.TYPES.RADIAL}var r=A("./gradientcontainer");n.prototype=Object.create(r.prototype),t.exports=n},{"./gradientcontainer":9}],28:[function(A,t,e){t.exports=function(A){return new Promise(function(t,e){var n=new XMLHttpRequest;n.open("GET",A),n.onload=function(){200===n.status?t(n.responseText):e(new Error(n.statusText))},n.onerror=function(){e(new Error("Network Error"))},n.send()})}},{}]},{},[4])(4),function(A){var t;t=function(){function t(A){var t,e,n,r,i,o,a,s,c,l,u,h,d,f,B;for(this.data=A,this.pos=8,this.palette=[],this.imgData=[],this.transparency={},this.animation=null,this.text={},o=null;;){switch(t=this.readUInt32(),l=function(){var A,t;for(t=[],a=A=0;A<4;a=++A)t.push(String.fromCharCode(this.data[this.pos++]));return t}.call(this).join("")){case"IHDR":this.width=this.readUInt32(),this.height=this.readUInt32(),this.bits=this.data[this.pos++],this.colorType=this.data[this.pos++],this.compressionMethod=this.data[this.pos++],this.filterMethod=this.data[this.pos++],this.interlaceMethod=this.data[this.pos++];break;case"acTL":this.animation={numFrames:this.readUInt32(),numPlays:this.readUInt32()||1/0,frames:[]};break;case"PLTE":this.palette=this.read(t);break;case"fcTL":o&&this.animation.frames.push(o),this.pos+=4,o={width:this.readUInt32(),height:this.readUInt32(),xOffset:this.readUInt32(),yOffset:this.readUInt32()},i=this.readUInt16(),r=this.readUInt16()||100,o.delay=1e3*i/r,o.disposeOp=this.data[this.pos++],o.blendOp=this.data[this.pos++],o.data=[];break;case"IDAT":case"fdAT":for("fdAT"===l&&(this.pos+=4,t-=4),A=(null!=o?o.data:void 0)||this.imgData,a=d=0;0<=t?dt;a=0<=t?++d:--d)A.push(this.data[this.pos++]);break;case"tRNS":switch(this.transparency={},this.colorType){case 3:if(n=this.palette.length/3,this.transparency.indexed=this.read(t),this.transparency.indexed.length>n)throw new Error("More transparent colors than palette size");if((u=n-this.transparency.indexed.length)>0)for(a=f=0;0<=u?fu;a=0<=u?++f:--f)this.transparency.indexed.push(255);break;case 0:this.transparency.grayscale=this.read(t)[0];break;case 2:this.transparency.rgb=this.read(t)}break;case"tEXt":s=(h=this.read(t)).indexOf(0),c=String.fromCharCode.apply(String,h.slice(0,s)),this.text[c]=String.fromCharCode.apply(String,h.slice(s+1));break;case"IEND":return o&&this.animation.frames.push(o),this.colors=function(){switch(this.colorType){case 0:case 3:case 4:return 1;case 2:case 6:return 3}}.call(this),this.hasAlphaChannel=4===(B=this.colorType)||6===B,e=this.colors+(this.hasAlphaChannel?1:0),this.pixelBitlength=this.bits*e,this.colorSpace=function(){switch(this.colors){case 1:return"DeviceGray";case 3:return"DeviceRGB"}}.call(this),void(this.imgData=new Uint8Array(this.imgData));default:this.pos+=t}if(this.pos+=4,this.pos>this.data.length)throw new Error("Incomplete or corrupt PNG file")}}var e,n,r;t.load=function(A,e,n){var r;return"function"==typeof e&&(n=e),(r=new XMLHttpRequest).open("GET",A,!0),r.responseType="arraybuffer",r.onload=function(){var A,i;return A=new Uint8Array(r.response||r.mozResponseArrayBuffer),i=new t(A),"function"==typeof(null!=e?e.getContext:void 0)&&i.render(e),"function"==typeof n?n(i):void 0},r.send(null)},t.prototype.read=function(A){var t,e;for(e=[],t=0;0<=A?tA;0<=A?++t:--t)e.push(this.data[this.pos++]);return e},t.prototype.readUInt32=function(){var A,t,e,n;return A=this.data[this.pos++]<<24,t=this.data[this.pos++]<<16,e=this.data[this.pos++]<<8,n=this.data[this.pos++],A|t|e|n},t.prototype.readUInt16=function(){var A,t;return A=this.data[this.pos++]<<8,t=this.data[this.pos++],A|t},t.prototype.decodePixels=function(A){var t,e,n,r,i,o,a,s,c,u,h,d,f,B,p,g,w,m,Q,C,y,v,U;if(null==A&&(A=this.imgData),0===A.length)return new Uint8Array(0);for(A=(A=new l(A)).getBytes(),g=(d=this.pixelBitlength/8)*this.width,f=new Uint8Array(g*this.height),o=A.length,p=0,B=0,e=0;B1&&e/re&&(n=e)}else{for(;!this.eof;)this.readBlock();var n=this.bufferLength}return this.pos=n,this.buffer.subarray(t,n)},lookChar:function(){for(var A=this.pos;this.bufferLength<=A;){if(this.eof)return null;this.readBlock()}return String.fromCharCode(this.buffer[this.pos])},getChar:function(){for(var A=this.pos;this.bufferLength<=A;){if(this.eof)return null;this.readBlock()}return String.fromCharCode(this.buffer[this.pos++])},makeSubStream:function(A,t,e){for(var n=A+t;this.bufferLength<=n&&!this.eof;)this.readBlock();return new Stream(this.buffer,A,t,e)},skip:function(A){A||(A=1),this.pos+=A},reset:function(){this.pos=0}},A}(),l=function(){function A(A){throw new Error(A)}function t(t){var e=0,n=t[e++],r=t[e++];-1!=n&&-1!=r||A("Invalid header in flate stream"),8!=(15&n)&&A("Unknown compression method in flate stream"),((n<<8)+r)%31!=0&&A("Bad FCHECK in flate stream"),32&r&&A("FDICT bit set in flate stream"),this.bytes=t,this.bytesPos=e,this.codeSize=0,this.codeBuf=0,c.call(this)}if("undefined"!=typeof Uint32Array){var e=new Uint32Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),n=new Uint32Array([3,4,5,6,7,8,9,10,65547,65549,65551,65553,131091,131095,131099,131103,196643,196651,196659,196667,262211,262227,262243,262259,327811,327843,327875,327907,258,258,258]),r=new Uint32Array([1,2,3,4,65541,65543,131081,131085,196625,196633,262177,262193,327745,327777,393345,393409,459009,459137,524801,525057,590849,591361,657409,658433,724993,727041,794625,798721,868353,876545]),i=[new Uint32Array([459008,524368,524304,524568,459024,524400,524336,590016,459016,524384,524320,589984,524288,524416,524352,590048,459012,524376,524312,589968,459028,524408,524344,590032,459020,524392,524328,59e4,524296,524424,524360,590064,459010,524372,524308,524572,459026,524404,524340,590024,459018,524388,524324,589992,524292,524420,524356,590056,459014,524380,524316,589976,459030,524412,524348,590040,459022,524396,524332,590008,524300,524428,524364,590072,459009,524370,524306,524570,459025,524402,524338,590020,459017,524386,524322,589988,524290,524418,524354,590052,459013,524378,524314,589972,459029,524410,524346,590036,459021,524394,524330,590004,524298,524426,524362,590068,459011,524374,524310,524574,459027,524406,524342,590028,459019,524390,524326,589996,524294,524422,524358,590060,459015,524382,524318,589980,459031,524414,524350,590044,459023,524398,524334,590012,524302,524430,524366,590076,459008,524369,524305,524569,459024,524401,524337,590018,459016,524385,524321,589986,524289,524417,524353,590050,459012,524377,524313,589970,459028,524409,524345,590034,459020,524393,524329,590002,524297,524425,524361,590066,459010,524373,524309,524573,459026,524405,524341,590026,459018,524389,524325,589994,524293,524421,524357,590058,459014,524381,524317,589978,459030,524413,524349,590042,459022,524397,524333,590010,524301,524429,524365,590074,459009,524371,524307,524571,459025,524403,524339,590022,459017,524387,524323,589990,524291,524419,524355,590054,459013,524379,524315,589974,459029,524411,524347,590038,459021,524395,524331,590006,524299,524427,524363,590070,459011,524375,524311,524575,459027,524407,524343,590030,459019,524391,524327,589998,524295,524423,524359,590062,459015,524383,524319,589982,459031,524415,524351,590046,459023,524399,524335,590014,524303,524431,524367,590078,459008,524368,524304,524568,459024,524400,524336,590017,459016,524384,524320,589985,524288,524416,524352,590049,459012,524376,524312,589969,459028,524408,524344,590033,459020,524392,524328,590001,524296,524424,524360,590065,459010,524372,524308,524572,459026,524404,524340,590025,459018,524388,524324,589993,524292,524420,524356,590057,459014,524380,524316,589977,459030,524412,524348,590041,459022,524396,524332,590009,524300,524428,524364,590073,459009,524370,524306,524570,459025,524402,524338,590021,459017,524386,524322,589989,524290,524418,524354,590053,459013,524378,524314,589973,459029,524410,524346,590037,459021,524394,524330,590005,524298,524426,524362,590069,459011,524374,524310,524574,459027,524406,524342,590029,459019,524390,524326,589997,524294,524422,524358,590061,459015,524382,524318,589981,459031,524414,524350,590045,459023,524398,524334,590013,524302,524430,524366,590077,459008,524369,524305,524569,459024,524401,524337,590019,459016,524385,524321,589987,524289,524417,524353,590051,459012,524377,524313,589971,459028,524409,524345,590035,459020,524393,524329,590003,524297,524425,524361,590067,459010,524373,524309,524573,459026,524405,524341,590027,459018,524389,524325,589995,524293,524421,524357,590059,459014,524381,524317,589979,459030,524413,524349,590043,459022,524397,524333,590011,524301,524429,524365,590075,459009,524371,524307,524571,459025,524403,524339,590023,459017,524387,524323,589991,524291,524419,524355,590055,459013,524379,524315,589975,459029,524411,524347,590039,459021,524395,524331,590007,524299,524427,524363,590071,459011,524375,524311,524575,459027,524407,524343,590031,459019,524391,524327,589999,524295,524423,524359,590063,459015,524383,524319,589983,459031,524415,524351,590047,459023,524399,524335,590015,524303,524431,524367,590079]),9],o=[new Uint32Array([327680,327696,327688,327704,327684,327700,327692,327708,327682,327698,327690,327706,327686,327702,327694,0,327681,327697,327689,327705,327685,327701,327693,327709,327683,327699,327691,327707,327687,327703,327695,0]),5];return t.prototype=Object.create(c.prototype),t.prototype.getBits=function(t){for(var e,n=this.codeSize,r=this.codeBuf,i=this.bytes,o=this.bytesPos;n>t,this.codeSize=n-=t,this.bytesPos=o,e},t.prototype.getCode=function(t){for(var e=t[0],n=t[1],r=this.codeSize,i=this.codeBuf,o=this.bytes,a=this.bytesPos;r>16,u=65535&c;return(0==r||r>l,this.codeSize=r-l,this.bytesPos=a,u},t.prototype.generateHuffmanTable=function(A){for(var t=A.length,e=0,n=0;ne&&(e=A[n]);for(var r=1<>=1;for(n=l;n0;)t[f++]=r}var a=this.getBits(3);if(1&a&&(this.eof=!0),0!=(a>>=1)){var s,c;if(1==a)s=i,c=o;else if(2==a){for(var l=this.getBits(5)+257,u=this.getBits(5)+1,h=this.getBits(4)+4,d=Array(e.length),f=0;f=Q&&(Q=(T=this.ensureBuffer(C+1)).length),T[C++]=y;else{if(256==y)return void(this.bufferLength=C);var v=(y=n[y-=257])>>16;v>0&&(v=this.getBits(v)),p=(65535&y)+v,y=this.getCode(c),(v=(y=r[y])>>16)>0&&(v=this.getBits(v));var U=(65535&y)+v;C+p>=Q&&(Q=(T=this.ensureBuffer(C+p)).length);for(var F=0;F>18&63,n=o>>12&63,r=o>>6&63,i=63&o,l[s++]=t.charAt(e)+t.charAt(n)+t.charAt(r)+t.charAt(i)}while(a>16&255,n=a>>8&255,r=255&a,l[c++]=64==i?String.fromCharCode(e):64==o?String.fromCharCode(e,n):String.fromCharCode(e,n,r)}while(s>>0,n=new Array(e),r=arguments.length>1?arguments[1]:void 0,i=0;i>>0,r=0;r4)&&[Number(t[1]),Number(t[2]),Number(t[3]),Number(t[4])]},h=function(A){return[Math.min(A[0],255),Math.min(A[1],255),Math.min(A[2],255),A.length>3?A[3]:null]},d=function(A){var t=B[A.toLowerCase()];return t||!1},f=function(){function A(t){!function(A,t){if(!(A instanceof t))throw new TypeError("Cannot call a class as a function")}(this,A);var n=Array.isArray(t)?h(t):i(t)||c(t)||u(t)||d(t)||a(t)||[0,0,0,null],r=e(n,4),o=r[0],s=r[1],l=r[2],f=r[3];this.r=o,this.g=s,this.b=l,this.a=f}return n(A,[{key:"isTransparent",value:function(){return 0===this.a}},{key:"toString",value:function(){return null!==this.a&&1!==this.a?"rgba("+this.r+","+this.g+","+this.b+","+this.a+")":"rgb("+this.r+","+this.g+","+this.b+")"}}]),A}();t.default=f;var B={transparent:[0,0,0,0],aliceblue:[240,248,255,null],antiquewhite:[250,235,215,null],aqua:[0,255,255,null],aquamarine:[127,255,212,null],azure:[240,255,255,null],beige:[245,245,220,null],bisque:[255,228,196,null],black:[0,0,0,null],blanchedalmond:[255,235,205,null],blue:[0,0,255,null],blueviolet:[138,43,226,null],brown:[165,42,42,null],burlywood:[222,184,135,null],cadetblue:[95,158,160,null],chartreuse:[127,255,0,null],chocolate:[210,105,30,null],coral:[255,127,80,null],cornflowerblue:[100,149,237,null],cornsilk:[255,248,220,null],crimson:[220,20,60,null],cyan:[0,255,255,null],darkblue:[0,0,139,null],darkcyan:[0,139,139,null],darkgoldenrod:[184,134,11,null],darkgray:[169,169,169,null],darkgreen:[0,100,0,null],darkgrey:[169,169,169,null],darkkhaki:[189,183,107,null],darkmagenta:[139,0,139,null],darkolivegreen:[85,107,47,null],darkorange:[255,140,0,null],darkorchid:[153,50,204,null],darkred:[139,0,0,null],darksalmon:[233,150,122,null],darkseagreen:[143,188,143,null],darkslateblue:[72,61,139,null],darkslategray:[47,79,79,null],darkslategrey:[47,79,79,null],darkturquoise:[0,206,209,null],darkviolet:[148,0,211,null],deeppink:[255,20,147,null],deepskyblue:[0,191,255,null],dimgray:[105,105,105,null],dimgrey:[105,105,105,null],dodgerblue:[30,144,255,null],firebrick:[178,34,34,null],floralwhite:[255,250,240,null],forestgreen:[34,139,34,null],fuchsia:[255,0,255,null],gainsboro:[220,220,220,null],ghostwhite:[248,248,255,null],gold:[255,215,0,null],goldenrod:[218,165,32,null],gray:[128,128,128,null],green:[0,128,0,null],greenyellow:[173,255,47,null],grey:[128,128,128,null],honeydew:[240,255,240,null],hotpink:[255,105,180,null],indianred:[205,92,92,null],indigo:[75,0,130,null],ivory:[255,255,240,null],khaki:[240,230,140,null],lavender:[230,230,250,null],lavenderblush:[255,240,245,null],lawngreen:[124,252,0,null],lemonchiffon:[255,250,205,null],lightblue:[173,216,230,null],lightcoral:[240,128,128,null],lightcyan:[224,255,255,null],lightgoldenrodyellow:[250,250,210,null],lightgray:[211,211,211,null],lightgreen:[144,238,144,null],lightgrey:[211,211,211,null],lightpink:[255,182,193,null],lightsalmon:[255,160,122,null],lightseagreen:[32,178,170,null],lightskyblue:[135,206,250,null],lightslategray:[119,136,153,null],lightslategrey:[119,136,153,null],lightsteelblue:[176,196,222,null],lightyellow:[255,255,224,null],lime:[0,255,0,null],limegreen:[50,205,50,null],linen:[250,240,230,null],magenta:[255,0,255,null],maroon:[128,0,0,null],mediumaquamarine:[102,205,170,null],mediumblue:[0,0,205,null],mediumorchid:[186,85,211,null],mediumpurple:[147,112,219,null],mediumseagreen:[60,179,113,null],mediumslateblue:[123,104,238,null],mediumspringgreen:[0,250,154,null],mediumturquoise:[72,209,204,null],mediumvioletred:[199,21,133,null],midnightblue:[25,25,112,null],mintcream:[245,255,250,null],mistyrose:[255,228,225,null],moccasin:[255,228,181,null],navajowhite:[255,222,173,null],navy:[0,0,128,null],oldlace:[253,245,230,null],olive:[128,128,0,null],olivedrab:[107,142,35,null],orange:[255,165,0,null],orangered:[255,69,0,null],orchid:[218,112,214,null],palegoldenrod:[238,232,170,null],palegreen:[152,251,152,null],paleturquoise:[175,238,238,null],palevioletred:[219,112,147,null],papayawhip:[255,239,213,null],peachpuff:[255,218,185,null],peru:[205,133,63,null],pink:[255,192,203,null],plum:[221,160,221,null],powderblue:[176,224,230,null],purple:[128,0,128,null],rebeccapurple:[102,51,153,null],red:[255,0,0,null],rosybrown:[188,143,143,null],royalblue:[65,105,225,null],saddlebrown:[139,69,19,null],salmon:[250,128,114,null],sandybrown:[244,164,96,null],seagreen:[46,139,87,null],seashell:[255,245,238,null],sienna:[160,82,45,null],silver:[192,192,192,null],skyblue:[135,206,235,null],slateblue:[106,90,205,null],slategray:[112,128,144,null],slategrey:[112,128,144,null],snow:[255,250,250,null],springgreen:[0,255,127,null],steelblue:[70,130,180,null],tan:[210,180,140,null],teal:[0,128,128,null],thistle:[216,191,216,null],tomato:[255,99,71,null],turquoise:[64,224,208,null],violet:[238,130,238,null],wheat:[245,222,179,null],white:[255,255,255,null],whitesmoke:[245,245,245,null],yellow:[255,255,0,null],yellowgreen:[154,205,50,null]};t.TRANSPARENT=new f([0,0,0,0])});t(o);o.TRANSPARENT;var a=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0}),t.parseTextDecoration=t.TEXT_DECORATION_LINE=t.TEXT_DECORATION=t.TEXT_DECORATION_STYLE=void 0;var e=function(A){return A&&A.__esModule?A:{default:A}}(o),n=t.TEXT_DECORATION_STYLE={SOLID:0,DOUBLE:1,DOTTED:2,DASHED:3,WAVY:4},r=t.TEXT_DECORATION={NONE:null},i=t.TEXT_DECORATION_LINE={UNDERLINE:1,OVERLINE:2,LINE_THROUGH:3,BLINK:4},a=function(A){switch(A){case"underline":return i.UNDERLINE;case"overline":return i.OVERLINE;case"line-through":return i.LINE_THROUGH}return i.BLINK};t.parseTextDecoration=function(A){var t=function(A){return"none"===A?null:A.split(" ").map(a)}(A.textDecorationLine?A.textDecorationLine:A.textDecoration);if(null===t)return r.NONE;return{textDecorationLine:t,textDecorationColor:A.textDecorationColor?new e.default(A.textDecorationColor):null,textDecorationStyle:function(A){switch(A){case"double":return n.DOUBLE;case"dotted":return n.DOTTED;case"dashed":return n.DASHED;case"wavy":return n.WAVY}return n.SOLID}(A.textDecorationStyle)}}});t(a);a.parseTextDecoration,a.TEXT_DECORATION_LINE,a.TEXT_DECORATION,a.TEXT_DECORATION_STYLE;var s=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});var e=function(){function A(A,t){for(var e=0;e=0;e--){var n=A.item(e);"content"!==n&&t.style.setProperty(n,A.getPropertyValue(n))}return t},t.SMALL_IMAGE="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"});t(l);l.contains,l.distance,l.copyCSSStyles,l.SMALL_IMAGE;var u=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0}),t.calculateLengthFromValueWithUnit=t.LENGTH_TYPE=void 0;var e=function(){function A(A,t){for(var e=0;e1&&(n/=B,i/=B,o/=B,a/=B,l/=B,u/=B,h/=B,d/=B);var p=A.width-o,g=A.height-u,w=A.width-l,m=A.height-d;return{topLeftOuter:n>0||i>0?c(A.left,A.top,n,i,s.TOP_LEFT):new r.default(A.left,A.top),topLeftInner:n>0||i>0?c(A.left+t[3].borderWidth,A.top+t[0].borderWidth,Math.max(0,n-t[3].borderWidth),Math.max(0,i-t[0].borderWidth),s.TOP_LEFT):new r.default(A.left+t[3].borderWidth,A.top+t[0].borderWidth),topRightOuter:o>0||a>0?c(A.left+p,A.top,o,a,s.TOP_RIGHT):new r.default(A.left+A.width,A.top),topRightInner:o>0||a>0?c(A.left+Math.min(p,A.width+t[3].borderWidth),A.top+t[0].borderWidth,p>A.width+t[3].borderWidth?0:o-t[3].borderWidth,a-t[0].borderWidth,s.TOP_RIGHT):new r.default(A.left+A.width-t[1].borderWidth,A.top+t[0].borderWidth),bottomRightOuter:l>0||u>0?c(A.left+w,A.top+g,l,u,s.BOTTOM_RIGHT):new r.default(A.left+A.width,A.top+A.height),bottomRightInner:l>0||u>0?c(A.left+Math.min(w,A.width-t[3].borderWidth),A.top+Math.min(g,A.height+t[0].borderWidth),Math.max(0,l-t[1].borderWidth),u-t[2].borderWidth,s.BOTTOM_RIGHT):new r.default(A.left+A.width-t[1].borderWidth,A.top+A.height-t[2].borderWidth),bottomLeftOuter:h>0||d>0?c(A.left,A.top+m,h,d,s.BOTTOM_LEFT):new r.default(A.left,A.top+A.height),bottomLeftInner:h>0||d>0?c(A.left+t[3].borderWidth,A.top+m,Math.max(0,h-t[3].borderWidth),d-t[2].borderWidth,s.BOTTOM_LEFT):new r.default(A.left+t[3].borderWidth,A.top+A.height-t[2].borderWidth)}},{TOP_LEFT:0,TOP_RIGHT:1,BOTTOM_RIGHT:2,BOTTOM_LEFT:3}),c=function(A,t,e,n,o){var a=(Math.sqrt(2)-1)/3*4,c=e*a,l=n*a,u=A+e,h=t+n;switch(o){case s.TOP_LEFT:return new i.default(new r.default(A,h),new r.default(A,h-l),new r.default(u-c,t),new r.default(u,t));case s.TOP_RIGHT:return new i.default(new r.default(A,t),new r.default(A+c,t),new r.default(u,h-l),new r.default(u,h));case s.BOTTOM_RIGHT:return new i.default(new r.default(u,t),new r.default(u,t+l),new r.default(A+c,h),new r.default(A,h));case s.BOTTOM_LEFT:default:return new i.default(new r.default(u,h),new r.default(u-c,h),new r.default(A,t+l),new r.default(A,t))}}});t(B);B.parseBoundCurves,B.calculatePaddingBoxPath,B.calculateBorderBoxPath,B.parsePathForBorder,B.parseDocumentSize,B.calculateContentBox,B.calculatePaddingBox,B.parseBounds,B.Bounds;var p=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0}),t.parsePadding=t.PADDING_SIDES=void 0;var e=function(A){return A&&A.__esModule?A:{default:A}}(u),n=(t.PADDING_SIDES={TOP:0,RIGHT:1,BOTTOM:2,LEFT:3},["top","right","bottom","left"]);t.parsePadding=function(A){return n.map(function(t){return new e.default(A.getPropertyValue("padding-"+t))})}});t(p);p.parsePadding,p.PADDING_SIDES;var g=e(function(A,t){function e(A){return A&&A.__esModule?A:{default:A}}Object.defineProperty(t,"__esModule",{value:!0}),t.parseBackgroundImage=t.parseBackground=t.calculateBackgroundRepeatPath=t.calculateBackgroundPosition=t.calculateBackgroungPositioningArea=t.calculateBackgroungPaintingArea=t.calculateGradientBackgroundSize=t.calculateBackgroundSize=t.BACKGROUND_ORIGIN=t.BACKGROUND_CLIP=t.BACKGROUND_SIZE=t.BACKGROUND_REPEAT=void 0;var n=e(o),r=e(u),i=e(h),a=e(d),s=t.BACKGROUND_REPEAT={REPEAT:0,NO_REPEAT:1,REPEAT_X:2,REPEAT_Y:3},c=t.BACKGROUND_SIZE={AUTO:0,CONTAIN:1,COVER:2,LENGTH:3},l=t.BACKGROUND_CLIP={BORDER_BOX:0,PADDING_BOX:1,CONTENT_BOX:2},f=t.BACKGROUND_ORIGIN=l,g=function A(t){switch(function(A,t){if(!(A instanceof t))throw new TypeError("Cannot call a class as a function")}(this,A),t){case"contain":this.size=c.CONTAIN;break;case"cover":this.size=c.COVER;break;case"auto":this.size=c.AUTO;break;default:this.value=new r.default(t)}},w=(t.calculateBackgroundSize=function(A,t,e){var n=0,r=0,o=A.size;if(o[0].size===c.CONTAIN||o[0].size===c.COVER){var a=e.width/e.height,s=t.width/t.height;return a0&&(A=r.substr(0,t).toLowerCase(),r=r.substr(t)),"none"!==(r=r.toLowerCase())&&e.push({prefix:A,method:r,args:n})}n=[],r=o=""};return A.split("").forEach(function(A){if(0!==a||!t.test(A)){switch(A){case'"':i?i===A&&(i=null):i=A;break;case"(":if(i)break;if(0===a)return void(a=1);s++;break;case")":if(i)break;if(1===a){if(0===s)return a=0,void c();s--}break;case",":if(i)break;if(0===a)return void c();if(1===a&&0===s&&!r.match(/^url$/i))return n.push(o.trim()),void(o="")}0===a?r+=A:o+=A}}),c(),e}});t(g);g.parseBackgroundImage,g.parseBackground,g.calculateBackgroundRepeatPath,g.calculateBackgroundPosition,g.calculateBackgroungPositioningArea,g.calculateBackgroungPaintingArea,g.calculateGradientBackgroundSize,g.calculateBackgroundSize,g.BACKGROUND_ORIGIN,g.BACKGROUND_CLIP,g.BACKGROUND_SIZE,g.BACKGROUND_REPEAT;var w=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0}),t.parseBorder=t.BORDER_SIDES=t.BORDER_STYLE=void 0;var e=function(A){return A&&A.__esModule?A:{default:A}}(o),n=t.BORDER_STYLE={NONE:0,SOLID:1},r=t.BORDER_SIDES={TOP:0,RIGHT:1,BOTTOM:2,LEFT:3},i=Object.keys(r).map(function(A){return A.toLowerCase()});t.parseBorder=function(A){return i.map(function(t){var r=new e.default(A.getPropertyValue("border-"+t+"-color")),i=function(A){switch(A){case"none":return n.NONE}return n.SOLID}(A.getPropertyValue("border-"+t+"-style")),o=parseFloat(A.getPropertyValue("border-"+t+"-width"));return{borderColor:r,borderStyle:i,borderWidth:isNaN(o)?0:o}})}});t(w);w.parseBorder,w.BORDER_SIDES,w.BORDER_STYLE;var m=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0}),t.parseBorderRadius=void 0;var e=function(){return function(A,t){if(Array.isArray(A))return A;if(Symbol.iterator in Object(A))return function(A,t){var e=[],n=!0,r=!1,i=void 0;try{for(var o,a=A[Symbol.iterator]();!(n=(o=a.next()).done)&&(e.push(o.value),!t||e.length!==t);n=!0);}catch(A){r=!0,i=A}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}return e}(A,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),n=function(A){return A&&A.__esModule?A:{default:A}}(u),r=["top-left","top-right","bottom-right","bottom-left"];t.parseBorderRadius=function(A){return r.map(function(t){var r=A.getPropertyValue("border-"+t+"-radius").split(" ").map(n.default.create),i=e(r,2),o=i[0],a=i[1];return void 0===a?[o,o]:[o,a]})}});t(m);m.parseBorderRadius;var Q=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});var e=t.DISPLAY={NONE:1,BLOCK:2,INLINE:4,RUN_IN:8,FLOW:16,FLOW_ROOT:32,TABLE:64,FLEX:128,GRID:256,RUBY:512,SUBGRID:1024,LIST_ITEM:2048,TABLE_ROW_GROUP:4096,TABLE_HEADER_GROUP:8192,TABLE_FOOTER_GROUP:16384,TABLE_ROW:32768,TABLE_CELL:65536,TABLE_COLUMN_GROUP:1<<17,TABLE_COLUMN:1<<18,TABLE_CAPTION:1<<19,RUBY_BASE:1<<20,RUBY_TEXT:1<<21,RUBY_BASE_CONTAINER:1<<22,RUBY_TEXT_CONTAINER:1<<23,CONTENTS:1<<24,INLINE_BLOCK:1<<25,INLINE_LIST_ITEM:1<<26,INLINE_TABLE:1<<27,INLINE_FLEX:1<<28,INLINE_GRID:1<<29},n=function(A,t){return A|function(A){switch(A){case"block":return e.BLOCK;case"inline":return e.INLINE;case"run-in":return e.RUN_IN;case"flow":return e.FLOW;case"flow-root":return e.FLOW_ROOT;case"table":return e.TABLE;case"flex":return e.FLEX;case"grid":return e.GRID;case"ruby":return e.RUBY;case"subgrid":return e.SUBGRID;case"list-item":return e.LIST_ITEM;case"table-row-group":return e.TABLE_ROW_GROUP;case"table-header-group":return e.TABLE_HEADER_GROUP;case"table-footer-group":return e.TABLE_FOOTER_GROUP;case"table-row":return e.TABLE_ROW;case"table-cell":return e.TABLE_CELL;case"table-column-group":return e.TABLE_COLUMN_GROUP;case"table-column":return e.TABLE_COLUMN;case"table-caption":return e.TABLE_CAPTION;case"ruby-base":return e.RUBY_BASE;case"ruby-text":return e.RUBY_TEXT;case"ruby-base-container":return e.RUBY_BASE_CONTAINER;case"ruby-text-container":return e.RUBY_TEXT_CONTAINER;case"contents":return e.CONTENTS;case"inline-block":return e.INLINE_BLOCK;case"inline-list-item":return e.INLINE_LIST_ITEM;case"inline-table":return e.INLINE_TABLE;case"inline-flex":return e.INLINE_FLEX;case"inline-grid":return e.INLINE_GRID}return e.NONE}(t)};t.parseDisplay=function(A){return A.split(" ").reduce(n,0)}});t(Q);Q.DISPLAY,Q.parseDisplay;var C=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});var e=t.FLOAT={NONE:0,LEFT:1,RIGHT:2,INLINE_START:3,INLINE_END:4};t.parseCSSFloat=function(A){switch(A){case"left":return e.LEFT;case"right":return e.RIGHT;case"inline-start":return e.INLINE_START;case"inline-end":return e.INLINE_END}return e.NONE}});t(C);C.FLOAT,C.parseCSSFloat;var y=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});t.parseFont=function(A){return{fontFamily:A.fontFamily,fontSize:A.fontSize,fontStyle:A.fontStyle,fontVariant:A.fontVariant,fontWeight:function(A){switch(A){case"normal":return 400;case"bold":return 700}var t=parseInt(A,10);return isNaN(t)?400:t}(A.fontWeight)}}});t(y);y.parseFont;var v=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});t.parseLetterSpacing=function(A){if("normal"===A)return 0;var t=parseFloat(A);return isNaN(t)?0:t}});t(v);v.parseLetterSpacing;var U=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});var e=t.LINE_BREAK={NORMAL:"normal",STRICT:"strict"};t.parseLineBreak=function(A){switch(A){case"strict":return e.STRICT;case"normal":default:return e.NORMAL}}});t(U);U.LINE_BREAK,U.parseLineBreak;var F=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0}),t.parseListStyle=t.parseListStyleType=t.LIST_STYLE_TYPE=t.LIST_STYLE_POSITION=void 0;var e=t.LIST_STYLE_POSITION={INSIDE:0,OUTSIDE:1},n=t.LIST_STYLE_TYPE={NONE:-1,DISC:0,CIRCLE:1,SQUARE:2,DECIMAL:3,CJK_DECIMAL:4,DECIMAL_LEADING_ZERO:5,LOWER_ROMAN:6,UPPER_ROMAN:7,LOWER_GREEK:8,LOWER_ALPHA:9,UPPER_ALPHA:10,ARABIC_INDIC:11,ARMENIAN:12,BENGALI:13,CAMBODIAN:14,CJK_EARTHLY_BRANCH:15,CJK_HEAVENLY_STEM:16,CJK_IDEOGRAPHIC:17,DEVANAGARI:18,ETHIOPIC_NUMERIC:19,GEORGIAN:20,GUJARATI:21,GURMUKHI:22,HEBREW:22,HIRAGANA:23,HIRAGANA_IROHA:24,JAPANESE_FORMAL:25,JAPANESE_INFORMAL:26,KANNADA:27,KATAKANA:28,KATAKANA_IROHA:29,KHMER:30,KOREAN_HANGUL_FORMAL:31,KOREAN_HANJA_FORMAL:32,KOREAN_HANJA_INFORMAL:33,LAO:34,LOWER_ARMENIAN:35,MALAYALAM:36,MONGOLIAN:37,MYANMAR:38,ORIYA:39,PERSIAN:40,SIMP_CHINESE_FORMAL:41,SIMP_CHINESE_INFORMAL:42,TAMIL:43,TELUGU:44,THAI:45,TIBETAN:46,TRAD_CHINESE_FORMAL:47,TRAD_CHINESE_INFORMAL:48,UPPER_ARMENIAN:49,DISCLOSURE_OPEN:50,DISCLOSURE_CLOSED:51},r=t.parseListStyleType=function(A){switch(A){case"disc":return n.DISC;case"circle":return n.CIRCLE;case"square":return n.SQUARE;case"decimal":return n.DECIMAL;case"cjk-decimal":return n.CJK_DECIMAL;case"decimal-leading-zero":return n.DECIMAL_LEADING_ZERO;case"lower-roman":return n.LOWER_ROMAN;case"upper-roman":return n.UPPER_ROMAN;case"lower-greek":return n.LOWER_GREEK;case"lower-alpha":return n.LOWER_ALPHA;case"upper-alpha":return n.UPPER_ALPHA;case"arabic-indic":return n.ARABIC_INDIC;case"armenian":return n.ARMENIAN;case"bengali":return n.BENGALI;case"cambodian":return n.CAMBODIAN;case"cjk-earthly-branch":return n.CJK_EARTHLY_BRANCH;case"cjk-heavenly-stem":return n.CJK_HEAVENLY_STEM;case"cjk-ideographic":return n.CJK_IDEOGRAPHIC;case"devanagari":return n.DEVANAGARI;case"ethiopic-numeric":return n.ETHIOPIC_NUMERIC;case"georgian":return n.GEORGIAN;case"gujarati":return n.GUJARATI;case"gurmukhi":return n.GURMUKHI;case"hebrew":return n.HEBREW;case"hiragana":return n.HIRAGANA;case"hiragana-iroha":return n.HIRAGANA_IROHA;case"japanese-formal":return n.JAPANESE_FORMAL;case"japanese-informal":return n.JAPANESE_INFORMAL;case"kannada":return n.KANNADA;case"katakana":return n.KATAKANA;case"katakana-iroha":return n.KATAKANA_IROHA;case"khmer":return n.KHMER;case"korean-hangul-formal":return n.KOREAN_HANGUL_FORMAL;case"korean-hanja-formal":return n.KOREAN_HANJA_FORMAL;case"korean-hanja-informal":return n.KOREAN_HANJA_INFORMAL;case"lao":return n.LAO;case"lower-armenian":return n.LOWER_ARMENIAN;case"malayalam":return n.MALAYALAM;case"mongolian":return n.MONGOLIAN;case"myanmar":return n.MYANMAR;case"oriya":return n.ORIYA;case"persian":return n.PERSIAN;case"simp-chinese-formal":return n.SIMP_CHINESE_FORMAL;case"simp-chinese-informal":return n.SIMP_CHINESE_INFORMAL;case"tamil":return n.TAMIL;case"telugu":return n.TELUGU;case"thai":return n.THAI;case"tibetan":return n.TIBETAN;case"trad-chinese-formal":return n.TRAD_CHINESE_FORMAL;case"trad-chinese-informal":return n.TRAD_CHINESE_INFORMAL;case"upper-armenian":return n.UPPER_ARMENIAN;case"disclosure-open":return n.DISCLOSURE_OPEN;case"disclosure-closed":return n.DISCLOSURE_CLOSED;case"none":default:return n.NONE}},i=(t.parseListStyle=function(A){var t=(0,g.parseBackgroundImage)(A.getPropertyValue("list-style-image"));return{listStyleType:r(A.getPropertyValue("list-style-type")),listStyleImage:t.length?t[0]:null,listStylePosition:i(A.getPropertyValue("list-style-position"))}},function(A){switch(A){case"inside":return e.INSIDE;case"outside":default:return e.OUTSIDE}})});t(F);F.parseListStyle,F.parseListStyleType,F.LIST_STYLE_TYPE,F.LIST_STYLE_POSITION;var E=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0}),t.parseMargin=void 0;var e=function(A){return A&&A.__esModule?A:{default:A}}(u),n=["top","right","bottom","left"];t.parseMargin=function(A){return n.map(function(t){return new e.default(A.getPropertyValue("margin-"+t))})}});t(E);E.parseMargin;var b=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});var e=t.OVERFLOW={VISIBLE:0,HIDDEN:1,SCROLL:2,AUTO:3};t.parseOverflow=function(A){switch(A){case"hidden":return e.HIDDEN;case"scroll":return e.SCROLL;case"auto":return e.AUTO;case"visible":default:return e.VISIBLE}}});t(b);b.OVERFLOW,b.parseOverflow;var H=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});var e=t.OVERFLOW_WRAP={NORMAL:0,BREAK_WORD:1};t.parseOverflowWrap=function(A){switch(A){case"break-word":return e.BREAK_WORD;case"normal":default:return e.NORMAL}}});t(H);H.OVERFLOW_WRAP,H.parseOverflowWrap;var x=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});var e=t.POSITION={STATIC:0,RELATIVE:1,ABSOLUTE:2,FIXED:3,STICKY:4};t.parsePosition=function(A){switch(A){case"relative":return e.RELATIVE;case"absolute":return e.ABSOLUTE;case"fixed":return e.FIXED;case"sticky":return e.STICKY}return e.STATIC}});t(x);x.POSITION,x.parsePosition;var _=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0}),t.parseTextShadow=void 0;var e=function(A){return A&&A.__esModule?A:{default:A}}(o),n=/^([+-]|\d|\.)$/i;t.parseTextShadow=function(A){if("none"===A||"string"!=typeof A)return null;for(var t="",r=!1,i=[],o=[],a=0,s=null,c=function(){t.length&&(r?i.push(parseFloat(t)):s=new e.default(t)),r=!1,t=""},l=function(){i.length&&null!==s&&o.push({color:s,offsetX:i[0]||0,offsetY:i[1]||0,blur:i[2]||0}),i.splice(0,i.length),s=null},u=0;u";try{n.drawImage(t,0,0),e.toDataURL()}catch(A){return!1}return!0}(document);return Object.defineProperty(n,"SUPPORT_SVG_DRAWING",{value:A}),A},get SUPPORT_BASE64_DRAWING(){return function(A){var t=function(A,t){var e=new Image,n=A.createElement("canvas"),r=n.getContext("2d");return new Promise(function(A){e.src=t;var i=function(){try{r.drawImage(e,0,0),n.toDataURL()}catch(t){return A(!1)}return A(!0)};e.onload=i,e.onerror=function(){return A(!1)},!0===e.complete&&setTimeout(function(){i()},500)})}(document,A);return Object.defineProperty(n,"SUPPORT_BASE64_DRAWING",{value:function(){return t}}),t}},get SUPPORT_FOREIGNOBJECT_DRAWING(){var A="function"==typeof Array.from&&"function"==typeof window.fetch?function(A){var t=A.createElement("canvas");t.width=100,t.height=100;var n=t.getContext("2d");n.fillStyle="rgb(0, 255, 0)",n.fillRect(0,0,100,100);var r=new Image,i=t.toDataURL();r.src=i;var o=(0,k.createForeignObjectSVG)(100,100,0,0,r);return n.fillStyle="red",n.fillRect(0,0,100,100),(0,k.loadSerializedSVG)(o).then(function(t){n.drawImage(t,0,0);var r=n.getImageData(0,0,100,100).data;n.fillStyle="red",n.fillRect(0,0,100,100);var o=A.createElement("div");return o.style.backgroundImage="url("+i+")",o.style.height="100px",e(r)?(0,k.loadSerializedSVG)((0,k.createForeignObjectSVG)(100,100,0,0,o)):Promise.reject(!1)}).then(function(A){return n.drawImage(A,0,0),e(n.getImageData(0,0,100,100).data)}).catch(function(A){return!1})}(document):Promise.resolve(!1);return Object.defineProperty(n,"SUPPORT_FOREIGNOBJECT_DRAWING",{value:A}),A},get SUPPORT_CORS_IMAGES(){var A=void 0!==(new Image).crossOrigin;return Object.defineProperty(n,"SUPPORT_CORS_IMAGES",{value:A}),A},get SUPPORT_RESPONSE_TYPE(){var A="string"==typeof(new XMLHttpRequest).responseType;return Object.defineProperty(n,"SUPPORT_RESPONSE_TYPE",{value:A}),A},get SUPPORT_CORS_XHR(){var A="withCredentials"in new XMLHttpRequest;return Object.defineProperty(n,"SUPPORT_CORS_XHR",{value:A}),A}};t.default=n});t(P);var L=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});t.toCodePoints=function(A){for(var t=[],e=0,n=A.length;e=55296&&r<=56319&&e>10),r%1024+56320)),(e+1===A||t.length>16384)&&(n+=String.fromCharCode.apply(String,t),t.length=0)}return n};for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",n="undefined"==typeof Uint8Array?[]:new Uint8Array(256),r=0;r>4,u[i++]=(15&a)<<4|s>>2,u[i++]=(3&s)<<6|63&c;return l},t.polyUint16Array=function(A){for(var t=A.length,e=[],n=0;n>n,s=t.UTRIE2_DATA_BLOCK_LENGTH=1<>n,u=t.UTRIE2_INDEX_2_BMP_LENGTH=a+l,h=t.UTRIE2_UTF8_2B_INDEX_2_OFFSET=u,d=t.UTRIE2_UTF8_2B_INDEX_2_LENGTH=32,f=t.UTRIE2_INDEX_1_OFFSET=h+d,B=t.UTRIE2_OMITTED_BMP_INDEX_1_LENGTH=65536>>r,p=t.UTRIE2_INDEX_2_BLOCK_LENGTH=1<=0){if(A<55296||A>56319&&A<=65535)return t=this.index[A>>n],t=(t<>n)],t=(t<>r),t=this.index[t],t+=A>>n&g,t=this.index[t],t=(t<1&&void 0!==arguments[1]?arguments[1]:"strict",e=[],n=[],r=[];return A.forEach(function(A,o){var a=S.get(A);if(a>i?(r.push(!0),a-=i):r.push(!1),-1!==["normal","auto","loose"].indexOf(t)&&-1!==[8208,8211,12316,12448].indexOf(A))return n.push(o),e.push(16);if(4===a||11===a){if(0===o)return n.push(o),e.push(Q);var s=e[o-1];return-1===R.indexOf(s)?(n.push(n[o-1]),e.push(s)):(n.push(o),e.push(Q))}return n.push(o),31===a?e.push("strict"===t?d:F):a===x?e.push(Q):29===a?e.push(Q):43===a?A>=131072&&A<=196605||A>=196608&&A<=262141?e.push(F):e.push(Q):void e.push(a)}),[n,e,r]},q=function(A,t,e,n){var r=n[e];if(Array.isArray(A)?-1!==A.indexOf(r):A===r)for(var i=e;i<=n.length;){var a=n[++i];if(a===t)return!0;if(a!==o)break}if(r===o)for(var s=e;s>0;){var c=n[--s];if(Array.isArray(A)?-1!==A.indexOf(c):A===c)for(var l=e;l<=n.length;){var u=n[++l];if(u===t)return!0;if(u!==o)break}if(c!==o)break}return!1},X=function(A,t){for(var e=A;e>=0;){var n=t[e];if(n!==o)return n;e--}return 0},V=function(A,t,e,n,r){if(0===e[n])return I;var i=n-1;if(Array.isArray(r)&&!0===r[i])return I;var Q=i-1,x=i+1,L=t[i],D=Q>=0?t[Q]:0,R=t[x];if(2===L&&3===R)return I;if(-1!==O.indexOf(L))return _;if(-1!==O.indexOf(R))return I;if(-1!==k.indexOf(R))return I;if(8===X(i,t))return T;if(11===S.get(A[i])&&(R===F||R===C||R===y))return I;if(7===L||7===R)return I;if(9===L)return I;if(-1===[o,a,s].indexOf(L)&&9===R)return I;if(-1!==[c,l,u,B,m].indexOf(R))return I;if(X(i,t)===f)return I;if(q(23,f,i,t))return I;if(q([c,l],d,i,t))return I;if(q(12,12,i,t))return I;if(L===o)return T;if(23===L||23===R)return I;if(16===R||16===L)return T;if(-1!==[a,s,d].indexOf(R)||14===L)return I;if(36===D&&-1!==M.indexOf(L))return I;if(L===m&&36===R)return I;if(R===h&&-1!==N.concat(h,u,p,F,C,y).indexOf(L))return I;if(-1!==N.indexOf(R)&&L===p||-1!==N.indexOf(L)&&R===p)return I;if(L===w&&-1!==[F,C,y].indexOf(R)||-1!==[F,C,y].indexOf(L)&&R===g)return I;if(-1!==N.indexOf(L)&&-1!==P.indexOf(R)||-1!==P.indexOf(L)&&-1!==N.indexOf(R))return I;if(-1!==[w,g].indexOf(L)&&(R===p||-1!==[f,s].indexOf(R)&&t[x+1]===p)||-1!==[f,s].indexOf(L)&&R===p||L===p&&-1!==[p,m,B].indexOf(R))return I;if(-1!==[p,m,B,c,l].indexOf(R))for(var z=i;z>=0;){var V=t[z];if(V===p)return I;if(-1===[m,B].indexOf(V))break;z--}if(-1!==[w,g].indexOf(R))for(var j=-1!==[c,l].indexOf(L)?Q:i;j>=0;){var G=t[j];if(G===p)return I;if(-1===[m,B].indexOf(G))break;j--}if(E===L&&-1!==[E,b,v,U].indexOf(R)||-1!==[b,v].indexOf(L)&&-1!==[b,H].indexOf(R)||-1!==[H,U].indexOf(L)&&R===H)return I;if(-1!==K.indexOf(L)&&-1!==[h,g].indexOf(R)||-1!==K.indexOf(R)&&L===w)return I;if(-1!==N.indexOf(L)&&-1!==N.indexOf(R))return I;if(L===B&&-1!==N.indexOf(R))return I;if(-1!==N.concat(p).indexOf(L)&&R===f||-1!==N.concat(p).indexOf(R)&&L===l)return I;if(41===L&&41===R){for(var Y=e[i],J=1;Y>0&&(Y--,41===t[Y]);)J++;if(J%2!=0)return I}return L===C&&R===y?I:T},j=(t.lineBreakAtIndex=function(A,t){if(0===t)return I;if(t>=A.length)return _;var e=z(A),r=n(e,2),i=r[0],o=r[1];return V(A,o,i,t)},function(A,t){t||(t={lineBreak:"normal",wordBreak:"normal"});var e=z(A,t.lineBreak),r=n(e,3),i=r[0],o=r[1],a=r[2];"break-all"!==t.wordBreak&&"break-word"!==t.wordBreak||(o=o.map(function(A){return-1!==[p,Q,x].indexOf(A)?F:A}));return[i,o,"keep-all"===t.wordBreak?a.map(function(t,e){return t&&A[e]>=19968&&A[e]<=40959}):null]}),G=(t.inlineBreakOpportunities=function(A,t){var e=(0,L.toCodePoints)(A),r=I,i=j(e,t),o=n(i,3),a=o[0],s=o[1],c=o[2];return e.forEach(function(A,t){r+=(0,L.fromCodePoint)(A)+(t>=e.length-1?_:V(e,s,a,t+1,c))}),r},function(){function A(t,e,n,r){!function(A,t){if(!(A instanceof t))throw new TypeError("Cannot call a class as a function")}(this,A),this._codePoints=t,this.required=e===_,this.start=n,this.end=r}return e(A,[{key:"slice",value:function(){return L.fromCodePoint.apply(void 0,function(A){if(Array.isArray(A)){for(var t=0,e=Array(A.length);t=c)return{done:!0};for(var A=I;u0)if(e.default.SUPPORT_RANGE_BOUNDS)d.push(new n(p,i(o,f,p.length,u,h)));else{var g=o.splitText(p.length);d.push(new n(p,r(o,u,h))),o=g}else e.default.SUPPORT_RANGE_BOUNDS||(o=o.splitText(p.length));f+=p.length}return d},function(A,t,e){var n=A.ownerDocument.createElement("html2canvaswrapper");n.appendChild(A.cloneNode(!0));var r=A.parentNode;if(r){r.replaceChild(n,A);var i=(0,B.parseBounds)(n,t,e);return n.firstChild&&r.replaceChild(n.firstChild,n),i}return new B.Bounds(0,0,0,0)}),i=function(A,t,e,n,r){var i=A.ownerDocument.createRange();return i.setStart(A,t),i.setEnd(A,t+e),B.Bounds.fromClientRect(i.getBoundingClientRect(),n,r)}});t(z);z.parseTextBounds,z.TextBounds;var q=e(function(A,t){function e(A,t,e){return A.length>0?t+e.toUpperCase():A}Object.defineProperty(t,"__esModule",{value:!0});var n=function(){function A(A,t){for(var e=0;eA.height?(A.left+=(A.width-A.height)/2,A.width=A.height):A.width0&&i){var o=t.ownerDocument.createElement("html2canvaswrapper");(0,l.copyCSSStyles)(t.ownerDocument.defaultView.getComputedStyle(t,null),o),o.style.position="absolute",o.style.left=e.bounds.left+"px",o.style.top=e.bounds.top+"px",r||(o.style.whiteSpace="nowrap");var a=t.ownerDocument.createTextNode(A);o.appendChild(a),i.appendChild(o),e.childNodes.push(n.default.fromTextNode(a,e)),i.removeChild(o)}}),U=function(A){var t="password"===A.type?new Array(A.value.length+1).join("•"):A.value;return 0===t.length?A.placeholder||"":t}});t(V);V.reformatInputBounds,V.inlineSelectElement,V.inlineTextAreaElement,V.inlineInputElement,V.getInputBorderRadius,V.INPUT_BACKGROUND,V.INPUT_BORDERS,V.INPUT_COLOR;var j=e(function(A,t){function e(A){return A&&A.__esModule?A:{default:A}}Object.defineProperty(t,"__esModule",{value:!0}),t.createCounterText=t.inlineListItemElement=t.getListOwner=void 0;var n=e(G),r=e(q),i=["OL","UL","MENU"],o=(t.getListOwner=function(A){var t=A.parent;if(!t)return null;do{if(-1!==i.indexOf(t.tagName))return t;t=t.parent}while(t);return A.parent},t.inlineListItemElement=function(A,t,e){var i=t.style.listStyle;if(i){var o=A.ownerDocument.defaultView.getComputedStyle(A,null),a=A.ownerDocument.createElement("html2canvaswrapper");switch((0,l.copyCSSStyles)(o,a),a.style.position="absolute",a.style.bottom="auto",a.style.display="block",a.style.letterSpacing="normal",i.listStylePosition){case F.LIST_STYLE_POSITION.OUTSIDE:a.style.left="auto",a.style.right=A.ownerDocument.defaultView.innerWidth-t.bounds.left-t.style.margin[1].getAbsoluteValue(t.bounds.width)+7+"px",a.style.textAlign="right";break;case F.LIST_STYLE_POSITION.INSIDE:a.style.left=t.bounds.left-t.style.margin[3].getAbsoluteValue(t.bounds.width)+"px",a.style.right="auto",a.style.textAlign="left"}var s=void 0,c=t.style.margin[0].getAbsoluteValue(t.bounds.width),u=i.listStyleImage;if(u)if("url"===u.method){var h=A.ownerDocument.createElement("img");h.src=u.args[0],a.style.top=t.bounds.top-c+"px",a.style.width="auto",a.style.height="auto",a.appendChild(h)}else{var d=.5*parseFloat(t.style.font.fontSize);a.style.top=t.bounds.top-c+t.bounds.height-1.5*d+"px",a.style.width=d+"px",a.style.height=d+"px",a.style.backgroundImage=o.listStyleImage}else"number"==typeof t.listIndex&&(s=A.ownerDocument.createTextNode(p(t.listIndex,i.listStyleType,!0)),a.appendChild(s),a.style.top=t.bounds.top-c+"px");var f=A.ownerDocument.body;f.appendChild(a),s?(t.childNodes.push(r.default.fromTextNode(s,t)),f.removeChild(a)):t.childNodes.push(new n.default(a,t,e,0))}},{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"]}),a={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:["Ք","Փ","Ւ","Ց","Ր","Տ","Վ","Ս","Ռ","Ջ","Պ","Չ","Ո","Շ","Ն","Յ","Մ","Ճ","Ղ","Ձ","Հ","Կ","Ծ","Խ","Լ","Ի","Ժ","Թ","Ը","Է","Զ","Ե","Դ","Գ","Բ","Ա"]},s={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:["י׳","ט׳","ח׳","ז׳","ו׳","ה׳","ד׳","ג׳","ב׳","א׳","ת","ש","ר","ק","צ","פ","ע","ס","נ","מ","ל","כ","יט","יח","יז","טז","טו","י","ט","ח","ז","ו","ה","ד","ג","ב","א"]},c={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:["ჵ","ჰ","ჯ","ჴ","ხ","ჭ","წ","ძ","ც","ჩ","შ","ყ","ღ","ქ","ფ","ჳ","ტ","ს","რ","ჟ","პ","ო","ჲ","ნ","მ","ლ","კ","ი","თ","ჱ","ზ","ვ","ე","დ","გ","ბ","ა"]},u=function(A,t,e,n,r,i){return Ae?p(A,r,i.length>0):n.integers.reduce(function(t,e,r){for(;A>=e;)A-=e,t+=n.values[r];return t},"")+i},h=function(A,t,e,n){var r="";do{e||A--,r=n(A)+r,A/=t}while(A*t>=t);return r},d=function(A,t,e,n,r){var i=e-t+1;return(A<0?"-":"")+(h(Math.abs(A),i,n,function(A){return(0,M.fromCodePoint)(Math.floor(A%i)+t)})+r)},f=function(A,t){var e=arguments.length>2&&void 0!==arguments[2]?arguments[2]:". ",n=t.length;return h(Math.abs(A),n,!1,function(A){return t[Math.floor(A%n)]})+e},B=function(A,t,e,n,r,i){if(A<-9999||A>9999)return p(A,F.LIST_STYLE_TYPE.CJK_DECIMAL,r.length>0);var o=Math.abs(A),a=r;if(0===o)return t[0]+a;for(var s=0;o>0&&s<=4;s++){var c=o%10;0===c&&(0,l.contains)(i,1)&&""!==a?a=t[c]+a:c>1||1===c&&0===s||1===c&&1===s&&(0,l.contains)(i,2)||1===c&&1===s&&(0,l.contains)(i,4)&&A>100||1===c&&s>1&&(0,l.contains)(i,8)?a=t[c]+(s>0?e[s-1]:"")+a:1===c&&s>0&&(a=e[s-1]+a),o=Math.floor(o/10)}return(A<0?n:"")+a},p=t.createCounterText=function(A,t,e){var n=e?". ":"",r=e?"、":"",i=e?", ":"";switch(t){case F.LIST_STYLE_TYPE.DISC:return"•";case F.LIST_STYLE_TYPE.CIRCLE:return"◦";case F.LIST_STYLE_TYPE.SQUARE:return"◾";case F.LIST_STYLE_TYPE.DECIMAL_LEADING_ZERO:var l=d(A,48,57,!0,n);return l.length<4?"0"+l:l;case F.LIST_STYLE_TYPE.CJK_DECIMAL:return f(A,"〇一二三四五六七八九",r);case F.LIST_STYLE_TYPE.LOWER_ROMAN:return u(A,1,3999,o,F.LIST_STYLE_TYPE.DECIMAL,n).toLowerCase();case F.LIST_STYLE_TYPE.UPPER_ROMAN:return u(A,1,3999,o,F.LIST_STYLE_TYPE.DECIMAL,n);case F.LIST_STYLE_TYPE.LOWER_GREEK:return d(A,945,969,!1,n);case F.LIST_STYLE_TYPE.LOWER_ALPHA:return d(A,97,122,!1,n);case F.LIST_STYLE_TYPE.UPPER_ALPHA:return d(A,65,90,!1,n);case F.LIST_STYLE_TYPE.ARABIC_INDIC:return d(A,1632,1641,!0,n);case F.LIST_STYLE_TYPE.ARMENIAN:case F.LIST_STYLE_TYPE.UPPER_ARMENIAN:return u(A,1,9999,a,F.LIST_STYLE_TYPE.DECIMAL,n);case F.LIST_STYLE_TYPE.LOWER_ARMENIAN:return u(A,1,9999,a,F.LIST_STYLE_TYPE.DECIMAL,n).toLowerCase();case F.LIST_STYLE_TYPE.BENGALI:return d(A,2534,2543,!0,n);case F.LIST_STYLE_TYPE.CAMBODIAN:case F.LIST_STYLE_TYPE.KHMER:return d(A,6112,6121,!0,n);case F.LIST_STYLE_TYPE.CJK_EARTHLY_BRANCH:return f(A,"子丑寅卯辰巳午未申酉戌亥",r);case F.LIST_STYLE_TYPE.CJK_HEAVENLY_STEM:return f(A,"甲乙丙丁戊己庚辛壬癸",r);case F.LIST_STYLE_TYPE.CJK_IDEOGRAPHIC:case F.LIST_STYLE_TYPE.TRAD_CHINESE_INFORMAL:return B(A,"零一二三四五六七八九","十百千萬","負",r,14);case F.LIST_STYLE_TYPE.TRAD_CHINESE_FORMAL:return B(A,"零壹貳參肆伍陸柒捌玖","拾佰仟萬","負",r,15);case F.LIST_STYLE_TYPE.SIMP_CHINESE_INFORMAL:return B(A,"零一二三四五六七八九","十百千萬","负",r,14);case F.LIST_STYLE_TYPE.SIMP_CHINESE_FORMAL:return B(A,"零壹贰叁肆伍陆柒捌玖","拾佰仟萬","负",r,15);case F.LIST_STYLE_TYPE.JAPANESE_INFORMAL:return B(A,"〇一二三四五六七八九","十百千万","マイナス",r,0);case F.LIST_STYLE_TYPE.JAPANESE_FORMAL:return B(A,"零壱弐参四伍六七八九","拾百千万","マイナス",r,7);case F.LIST_STYLE_TYPE.KOREAN_HANGUL_FORMAL:return B(A,"영일이삼사오육칠팔구","십백천만","마이너스 ",i,7);case F.LIST_STYLE_TYPE.KOREAN_HANJA_INFORMAL:return B(A,"零一二三四五六七八九","十百千萬","마이너스 ",i,0);case F.LIST_STYLE_TYPE.KOREAN_HANJA_FORMAL:return B(A,"零壹貳參四五六七八九","拾百千","마이너스 ",i,7);case F.LIST_STYLE_TYPE.DEVANAGARI:return d(A,2406,2415,!0,n);case F.LIST_STYLE_TYPE.GEORGIAN:return u(A,1,19999,c,F.LIST_STYLE_TYPE.DECIMAL,n);case F.LIST_STYLE_TYPE.GUJARATI:return d(A,2790,2799,!0,n);case F.LIST_STYLE_TYPE.GURMUKHI:return d(A,2662,2671,!0,n);case F.LIST_STYLE_TYPE.HEBREW:return u(A,1,10999,s,F.LIST_STYLE_TYPE.DECIMAL,n);case F.LIST_STYLE_TYPE.HIRAGANA:return f(A,"あいうえおかきくけこさしすせそたちつてとなにぬねのはひふへほまみむめもやゆよらりるれろわゐゑをん");case F.LIST_STYLE_TYPE.HIRAGANA_IROHA:return f(A,"いろはにほへとちりぬるをわかよたれそつねならむうゐのおくやまけふこえてあさきゆめみしゑひもせす");case F.LIST_STYLE_TYPE.KANNADA:return d(A,3302,3311,!0,n);case F.LIST_STYLE_TYPE.KATAKANA:return f(A,"アイウエオカキクケコサシスセソタチツテトナニヌネノハヒフヘホマミムメモヤユヨラリルレロワヰヱヲン",r);case F.LIST_STYLE_TYPE.KATAKANA_IROHA:return f(A,"イロハニホヘトチリヌルヲワカヨタレソツネナラムウヰノオクヤマケフコエテアサキユメミシヱヒモセス",r);case F.LIST_STYLE_TYPE.LAO:return d(A,3792,3801,!0,n);case F.LIST_STYLE_TYPE.MONGOLIAN:return d(A,6160,6169,!0,n);case F.LIST_STYLE_TYPE.MYANMAR:return d(A,4160,4169,!0,n);case F.LIST_STYLE_TYPE.ORIYA:return d(A,2918,2927,!0,n);case F.LIST_STYLE_TYPE.PERSIAN:return d(A,1776,1785,!0,n);case F.LIST_STYLE_TYPE.TAMIL:return d(A,3046,3055,!0,n);case F.LIST_STYLE_TYPE.TELUGU:return d(A,3174,3183,!0,n);case F.LIST_STYLE_TYPE.THAI:return d(A,3664,3673,!0,n);case F.LIST_STYLE_TYPE.TIBETAN:return d(A,3872,3881,!0,n);case F.LIST_STYLE_TYPE.DECIMAL:default:return d(A,48,57,!0,n)}}});t(j);j.createCounterText,j.inlineListItemElement,j.getListOwner;var G=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});var e=function(){function A(A,t){for(var e=0;e0&&this.style.visibility===S.VISIBILITY.VISIBLE}},{key:"isAbsolutelyPositioned",value:function(){return this.style.position!==x.POSITION.STATIC&&this.style.position!==x.POSITION.RELATIVE}},{key:"isPositioned",value:function(){return this.style.position!==x.POSITION.STATIC}},{key:"isFloating",value:function(){return this.style.float!==C.FLOAT.NONE}},{key:"isRootElement",value:function(){return null===this.parent}},{key:"isTransformed",value:function(){return null!==this.style.transform}},{key:"isPositionedWithZIndex",value:function(){return this.isPositioned()&&!this.style.zIndex.auto}},{key:"isInlineLevel",value:function(){return(0,l.contains)(this.style.display,Q.DISPLAY.INLINE)||(0,l.contains)(this.style.display,Q.DISPLAY.INLINE_BLOCK)||(0,l.contains)(this.style.display,Q.DISPLAY.INLINE_FLEX)||(0,l.contains)(this.style.display,Q.DISPLAY.INLINE_GRID)||(0,l.contains)(this.style.display,Q.DISPLAY.INLINE_LIST_ITEM)||(0,l.contains)(this.style.display,Q.DISPLAY.INLINE_TABLE)}},{key:"isInlineBlockOrInlineTable",value:function(){return(0,l.contains)(this.style.display,Q.DISPLAY.INLINE_BLOCK)||(0,l.contains)(this.style.display,Q.DISPLAY.INLINE_TABLE)}}]),A}();t.default=i;var s=function(A,t){if(A instanceof A.ownerDocument.defaultView.SVGSVGElement||A instanceof SVGSVGElement){var e=new XMLSerializer;return t.loadImage("data:image/svg+xml,"+encodeURIComponent(e.serializeToString(A)))}switch(A.tagName){case"IMG":var n=A;return t.loadImage(n.currentSrc||n.src);case"CANVAS":var r=A;return t.loadCanvas(r);case"IFRAME":var i=A.getAttribute("data-html2canvas-internal-iframe-key");if(i)return i}return null}});t(G);var Y=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});var e=function(){function A(A,t){for(var e=0;e0&&e.childNodes.push(i.default.fromTextNode(d,e));else if(d instanceof f.HTMLElement||d instanceof HTMLElement||f.parent&&d instanceof f.parent.HTMLElement){if(-1===o.indexOf(d.nodeName)){var B=new r.default(d,e,l,u++);if(B.isVisible()){"INPUT"===d.tagName?(0,V.inlineInputElement)(d,B):"TEXTAREA"===d.tagName?(0,V.inlineTextAreaElement)(d,B):"SELECT"===d.tagName?(0,V.inlineSelectElement)(d,B):B.style.listStyle&&B.style.listStyle.listStyleType!==F.LIST_STYLE_TYPE.NONE&&(0,j.inlineListItemElement)(d,B,l);var p="TEXTAREA"!==d.tagName,g=s(B,d);if(g||c(B)){var w=g||B.isPositioned()?a.getRealParentStackingContext():a,m=new n.default(B,w,g);w.contexts.push(m),p&&A(d,B,m,l,u)}else a.children.push(B),p&&A(d,B,a,l,u)}}}else if(d instanceof f.SVGSVGElement||d instanceof SVGSVGElement||f.parent&&d instanceof f.parent.SVGSVGElement){var Q=new r.default(d,e,l,u++),C=s(Q,d);if(C||c(Q)){var y=C||Q.isPositioned()?a.getRealParentStackingContext():a,v=new n.default(Q,y,C);y.contexts.push(v)}else a.children.push(Q)}}},s=function(A,t){return A.isRootElement()||A.isPositionedWithZIndex()||A.style.opacity<1||A.isTransformed()||l(A,t)},c=function(A){return A.isPositioned()||A.isFloating()},l=function(A,t){return"BODY"===t.nodeName&&A.parent instanceof r.default&&A.parent.style.background.backgroundColor.isTransparent()}});t(J);J.NodeParser;var W=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0}),t.FontMetrics=void 0;var e=function(){function A(A,t){for(var e=0;eA.optimumDistance)?{optimumCorner:r,optimumDistance:i}:A},{optimumDistance:n?1/0:-1/0,optimumCorner:null}).optimumCorner},H=function(A,t,e,n,r){var i=e.x,o=e.y,a=0,s=0;switch(A){case"closest-side":t===p.CIRCLE?a=s=Math.min(Math.abs(i),Math.abs(i-r.width),Math.abs(o),Math.abs(o-r.height)):t===p.ELLIPSE&&(a=Math.min(Math.abs(i),Math.abs(i-r.width)),s=Math.min(Math.abs(o),Math.abs(o-r.height)));break;case"closest-corner":if(t===p.CIRCLE)a=s=Math.min((0,l.distance)(i,o),(0,l.distance)(i,o-r.height),(0,l.distance)(i-r.width,o),(0,l.distance)(i-r.width,o-r.height));else if(t===p.ELLIPSE){var c=Math.min(Math.abs(o),Math.abs(o-r.height))/Math.min(Math.abs(i),Math.abs(i-r.width)),u=b(r,i,o,!0);s=c*(a=(0,l.distance)(u.x-i,(u.y-o)/c))}break;case"farthest-side":t===p.CIRCLE?a=s=Math.max(Math.abs(i),Math.abs(i-r.width),Math.abs(o),Math.abs(o-r.height)):t===p.ELLIPSE&&(a=Math.max(Math.abs(i),Math.abs(i-r.width)),s=Math.max(Math.abs(o),Math.abs(o-r.height)));break;case"farthest-corner":if(t===p.CIRCLE)a=s=Math.max((0,l.distance)(i,o),(0,l.distance)(i,o-r.height),(0,l.distance)(i-r.width,o),(0,l.distance)(i-r.width,o-r.height));else if(t===p.ELLIPSE){var h=Math.max(Math.abs(o),Math.abs(o-r.height))/Math.max(Math.abs(i),Math.abs(i-r.width)),d=b(r,i,o,!1);s=h*(a=(0,l.distance)(d.x-i,(d.y-o)/h))}break;default:a=n.x||0,s=void 0!==n.y?n.y:a}return{x:a,y:s}},x=t.transformWebkitRadialGradientArgs=function(A){var t="",e="",n="",r="",i=0,o=/^(left|center|right|\d+(?:px|r?em|%)?)(?:\s+(top|center|bottom|\d+(?:px|r?em|%)?))?$/i,a=/^\d+(px|r?em|%)?(?:\s+\d+(px|r?em|%)?)?$/i,s=A[i].match(o);s&&i++;var c=A[i].match(/^(circle|ellipse)?\s*(closest-side|closest-corner|farthest-side|farthest-corner|contain|cover)?$/i);c&&(t=c[1]||"","contain"===(n=c[2]||"")?n="closest-side":"cover"===n&&(n="farthest-corner"),i++);var l=A[i].match(a);l&&i++;var u=A[i].match(o);u&&i++;var h=A[i].match(a);h&&i++;var d=u||s;d&&d[1]&&(r=d[1]+(/^\d+$/.test(d[1])?"px":""),d[2]&&(r+=" "+d[2]+(/^\d+$/.test(d[2])?"px":"")));var f=h||l;return f&&(e=f[0],f[1]||(e+="px")),!r||t||e||n||(e=r,r=""),r&&(r="at "+r),[[t,n,e,r].filter(function(A){return!!A}).join(" ")].concat(A.slice(i))},_=function(A){return A.map(function(A){return A.match(d)}).map(function(t,e){if(!t)return A[e];switch(t[1]){case"from":return t[4]+" 0%";case"to":return t[4]+" 100%";case"color-stop":return"%"===t[3]?t[4]+" "+t[2]:t[4]+" "+100*parseFloat(t[2])+"%"}})}});t($);$.transformWebkitRadialGradientArgs,$.parseGradient,$.RadialGradient,$.LinearGradient,$.RADIAL_GRADIENT_SHAPE,$.GRADIENT_TYPE;var AA=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0});var e=function(){return function(A,t){if(Array.isArray(A))return A;if(Symbol.iterator in Object(A))return function(A,t){var e=[],n=!0,r=!1,i=void 0;try{for(var o,a=A[Symbol.iterator]();!(n=(o=a.next()).done)&&(e.push(o.value),!t||e.length!==t);n=!0);}catch(A){r=!0,i=A}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}return e}(A,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),n=function(){function A(A,t){for(var e=0;e0?e.width:n.width,o="number"==typeof e.height&&e.height>0?e.height:n.height;i>0&&o>0&&t.target.clip([(0,B.calculatePaddingBoxPath)(A.curvedBounds)],function(){t.target.drawImage(e,new B.Bounds(0,0,i,o),n)})}}},n=A.getClipPaths();n.length?this.target.clip(n,e):e()}},{key:"renderNodeBackgroundAndBorders",value:function(A){var t=this,e=!A.style.background.backgroundColor.isTransparent()||A.style.background.backgroundImage.length,n=A.style.border.some(function(A){return A.borderStyle!==w.BORDER_STYLE.NONE&&!A.borderColor.isTransparent()}),r=function(){var n=(0,g.calculateBackgroungPaintingArea)(A.curvedBounds,A.style.background.backgroundClip);e&&t.target.clip([n],function(){A.style.background.backgroundColor.isTransparent()||t.target.fill(A.style.background.backgroundColor),t.renderBackgroundImage(A)}),A.style.border.forEach(function(e,n){e.borderStyle===w.BORDER_STYLE.NONE||e.borderColor.isTransparent()||t.renderBorder(e,n,A.curvedBounds)})};if(e||n){var i=A.parent?A.parent.getClipPaths():[];i.length?this.target.clip(i,r):r()}}},{key:"renderBackgroundImage",value:function(A){var t=this;A.style.background.backgroundImage.slice(0).reverse().forEach(function(e){"url"===e.source.method&&e.source.args.length?t.renderBackgroundRepeat(A,e):/gradient/i.test(e.source.method)&&t.renderBackgroundGradient(A,e)})}},{key:"renderBackgroundRepeat",value:function(A,t){var e=this.options.imageStore.get(t.source.args[0]);if(e){var n=(0,g.calculateBackgroungPositioningArea)(A.style.background.backgroundOrigin,A.bounds,A.style.padding,A.style.border),r=(0,g.calculateBackgroundSize)(t,e,n),i=(0,g.calculateBackgroundPosition)(t.position,r,n),o=(0,g.calculateBackgroundRepeatPath)(t,i,r,n,A.bounds),a=Math.round(n.left+i.x),s=Math.round(n.top+i.y);this.target.renderRepeat(o,e,r,a,s)}}},{key:"renderBackgroundGradient",value:function(A,t){var e=(0,g.calculateBackgroungPositioningArea)(A.style.background.backgroundOrigin,A.bounds,A.style.padding,A.style.border),n=(0,g.calculateGradientBackgroundSize)(t,e),r=(0,g.calculateBackgroundPosition)(t.position,n,e),i=new B.Bounds(Math.round(e.left+r.x),Math.round(e.top+r.y),n.width,n.height),o=(0,$.parseGradient)(A,t.source,i);if(o)switch(o.type){case $.GRADIENT_TYPE.LINEAR_GRADIENT:this.target.renderLinearGradient(i,o);break;case $.GRADIENT_TYPE.RADIAL_GRADIENT:this.target.renderRadialGradient(i,o)}}},{key:"renderBorder",value:function(A,t,e){this.target.drawShape((0,B.parsePathForBorder)(e,t),A.borderColor)}},{key:"renderStack",value:function(A){var t=this;if(A.container.isVisible()){var e=A.getOpacity();e!==this._opacity&&(this.target.setOpacity(A.getOpacity()),this._opacity=e);var n=A.container.style.transform;null!==n?this.target.transform(A.container.bounds.left+n.transformOrigin[0].value,A.container.bounds.top+n.transformOrigin[1].value,n.transform,function(){return t.renderStackContent(A)}):this.renderStackContent(A)}}},{key:"renderStackContent",value:function(A){var t=a(A),n=e(t,5),r=n[0],i=n[1],c=n[2],l=n[3],u=n[4],h=o(A),d=e(h,2),f=d[0],B=d[1];this.renderNodeBackgroundAndBorders(A.container),r.sort(s).forEach(this.renderStack,this),this.renderNodeContent(A.container),B.forEach(this.renderNode,this),l.forEach(this.renderStack,this),u.forEach(this.renderStack,this),f.forEach(this.renderNode,this),i.forEach(this.renderStack,this),c.sort(s).forEach(this.renderStack,this)}},{key:"render",value:function(A){this.options.backgroundColor&&this.target.rectangle(this.options.x,this.options.y,this.options.width,this.options.height,this.options.backgroundColor),this.renderStack(A);return this.target.getTarget()}}]),A}();t.default=i;var o=function(A){for(var t=[],e=[],n=A.children.length,r=0;r0?n.push(s):e.push(s):s.container.isFloating()?r.push(s):i.push(s)}return[t,e,n,r,i]},s=function(A,t){return A.container.style.zIndex.order>t.container.style.zIndex.order?1:A.container.style.zIndex.ordert.container.index?1:-1}});t(AA);var tA=e(function(A,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Proxy=void 0;var e=function(A){return A&&A.__esModule?A:{default:A}}(P);t.Proxy=function(A,t){if(!t.proxy)return Promise.reject(null);var n=t.proxy;return new Promise(function(r,i){var o=e.default.SUPPORT_CORS_XHR&&e.default.SUPPORT_RESPONSE_TYPE?"blob":"text",a=e.default.SUPPORT_CORS_XHR?new XMLHttpRequest:new XDomainRequest;if(a.onload=function(){if(a instanceof XMLHttpRequest)if(200===a.status)if("text"===o)r(a.response);else{var A=new FileReader;A.addEventListener("load",function(){return r(A.result)},!1),A.addEventListener("error",function(A){return i(A)},!1),A.readAsDataURL(a.response)}else i("");else r(a.responseText)},a.onerror=i,a.open("GET",n+"?url="+encodeURIComponent(A)+"&responseType="+o),"text"!==o&&a instanceof XMLHttpRequest&&(a.responseType=o),t.imageTimeout){var s=t.imageTimeout;a.timeout=s,a.ontimeout=function(){return i("")}}a.send()})}});t(tA);tA.Proxy;var eA=e(function(A,t){function e(A,t){if(!(A instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0}),t.ResourceStore=void 0;var n=function(){function A(A,t){for(var e=0;e0&&e.push({type:r.ATTRIBUTE,value:u[0]});break;case"counter":if(u.length>0){var f={type:r.COUNTER,name:u[0]};u.length>1&&(f.format=u[1]),e.push(f)}break;case"counters":if(u.length>0){var B={type:r.COUNTERS,name:u[0]};u.length>1&&(B.glue=u[1]),u.length>2&&(B.format=u[2]),e.push(B)}break;case"url":u.length>0&&e.push({type:r.URL,value:u[0]})}s=!1,c=""}break;case",":i?c+=d:s&&(u.push(c),c="");break;case" ":case"\t":i?c+=d:c&&(o(e,c),c="");break;default:c+=d}"\\"!==d&&(a=!1)}return c&&o(e,c),t&&(t[A]=e),e}),o=function(A,t){switch(t){case"open-quote":A.push({type:r.OPENQUOTE});break;case"close-quote":A.push({type:r.CLOSEQUOTE})}},a=function(A,t,e){var n=A.quotes?A.quotes.split(/\s+/):["'\"'","'\"'"],r=2*e;return r>=n.length&&(r=n.length-2),t||++r,n[r].replace(/^["']|["']$/g,"")},s=function(A,t,e){for(var n=A.length,r="",i=0;i0&&(r+=t||""),r+=(0,j.createCounterText)(A[i],(0,F.parseListStyleType)(e||"decimal"),!1);return r}});t(nA);nA.parseContent,nA.resolvePseudoContent,nA.popCounters,nA.parseCounterReset,nA.TOKEN_TYPE,nA.PSEUDO_CONTENT_ITEM_TYPE;var rA=e(function(A,t){function e(A){return A&&A.__esModule?A:{default:A}}Object.defineProperty(t,"__esModule",{value:!0}),t.cloneWindow=t.DocumentCloner=void 0;var n=function(){return function(A,t){if(Array.isArray(A))return A;if(Symbol.iterator in Object(A))return function(A,t){var e=[],n=!0,r=!1,i=void 0;try{for(var o,a=A[Symbol.iterator]();!(n=(o=a.next()).done)&&(e.push(o.value),!t||e.length!==t);n=!0);}catch(A){r=!0,i=A}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}return e}(A,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),r=function(){function A(A,t){for(var e=0;e1&&(e.backgroundColor=""),e.backgroundImage=A.join(",")}),A instanceof HTMLImageElement&&this.resourceLoader.inlineImage(A.src).then(function(t){if(t&&A instanceof HTMLImageElement&&A.parentNode){var e=A.parentNode,n=(0,l.copyCSSStyles)(A.style,t.cloneNode(!1));e.replaceChild(n,A)}}).catch(function(A){})}}},{key:"inlineFonts",value:function(A){var t=this;return Promise.all(Array.from(A.styleSheets).map(function(t){return t.href?fetch(t.href).then(function(A){return A.text()}).then(function(A){return u(A,t.href)}).catch(function(A){return[]}):c(t,A)})).then(function(A){return A.reduce(function(A,t){return A.concat(t)},[])}).then(function(A){return Promise.all(A.map(function(A){return fetch(A.formats[0].src).then(function(A){return A.blob()}).then(function(A){return new Promise(function(t,e){var n=new FileReader;n.onerror=e,n.onload=function(){var A=n.result;t(A)},n.readAsDataURL(A)})}).then(function(t){return A.fontFace.setProperty("src",'url("'+t+'")'),"@font-face {"+A.fontFace.cssText+" "})}))}).then(function(e){var n=A.createElement("style");n.textContent=e.join("\n"),t.documentElement.appendChild(n)})}},{key:"createElementClone",value:function(A){var t=this;if(this.copyStyles&&A instanceof HTMLCanvasElement){var e=A.ownerDocument.createElement("img");try{return e.src=A.toDataURL(),e}catch(A){}}if(A instanceof HTMLIFrameElement){var n=A.cloneNode(!1),r=v();n.setAttribute("data-html2canvas-internal-iframe-key",r);var i=(0,B.parseBounds)(A,0,0),a=i.width,s=i.height;return this.resourceLoader.cache[r]=F(A,this.options).then(function(A){return t.renderer(A,{async:t.options.async,allowTaint:t.options.allowTaint,backgroundColor:"#ffffff",canvas:null,imageTimeout:t.options.imageTimeout,logging:t.options.logging,proxy:t.options.proxy,removeContainer:t.options.removeContainer,scale:t.options.scale,foreignObjectRendering:t.options.foreignObjectRendering,useCORS:t.options.useCORS,target:new o.default,width:a,height:s,x:0,y:0,windowWidth:A.ownerDocument.defaultView.innerWidth,windowHeight:A.ownerDocument.defaultView.innerHeight,scrollX:A.ownerDocument.defaultView.pageXOffset,scrollY:A.ownerDocument.defaultView.pageYOffset},t.logger.child(r))}).then(function(t){return new Promise(function(e,r){var i=document.createElement("img");i.onload=function(){return e(t)},i.onerror=r,i.src=t.toDataURL(),n.parentNode&&n.parentNode.replaceChild((0,l.copyCSSStyles)(A.ownerDocument.defaultView.getComputedStyle(A),i),n)})}),n}if(A instanceof HTMLStyleElement&&A.sheet&&A.sheet.cssRules){var c=[].slice.call(A.sheet.cssRules,0).reduce(function(A,e){try{return e&&e.cssText?A+e.cssText:A}catch(n){return t.logger.log("Unable to access cssText property",e.name),A}},""),u=A.cloneNode(!1);return u.textContent=c,u}return A.cloneNode(!1)}},{key:"cloneNode",value:function(A){var t=A.nodeType===Node.TEXT_NODE?document.createTextNode(A.nodeValue):this.createElementClone(A),e=A.ownerDocument.defaultView,n=A instanceof e.HTMLElement?e.getComputedStyle(A):null,r=A instanceof e.HTMLElement?e.getComputedStyle(A,":before"):null,i=A instanceof e.HTMLElement?e.getComputedStyle(A,":after"):null;this.referenceElement===A&&t instanceof e.HTMLElement&&(this.clonedReferenceElement=t),t instanceof e.HTMLBodyElement&&Q(t);for(var o=(0,nA.parseCounterReset)(n,this.pseudoContentData),a=(0,nA.resolvePseudoContent)(A,r,this.pseudoContentData),s=A.firstChild;s;s=s.nextSibling)s.nodeType===Node.ELEMENT_NODE&&("SCRIPT"===s.nodeName||s.hasAttribute("data-html2canvas-ignore")||"function"==typeof this.options.ignoreElements&&this.options.ignoreElements(s))||this.copyStyles&&"STYLE"===s.nodeName||t.appendChild(this.cloneNode(s));var c=(0,nA.resolvePseudoContent)(A,i,this.pseudoContentData);if((0,nA.popCounters)(o,this.pseudoContentData),A instanceof e.HTMLElement&&t instanceof e.HTMLElement)switch(r&&this.inlineAllImages(d(A,t,r,a,f)),i&&this.inlineAllImages(d(A,t,i,c,p)),!n||!this.copyStyles||A instanceof HTMLIFrameElement||(0,l.copyCSSStyles)(n,t),this.inlineAllImages(t),0===A.scrollTop&&0===A.scrollLeft||this.scrolledElements.push([t,A.scrollLeft,A.scrollTop]),A.nodeName){case"CANVAS":this.copyStyles||h(A,t);break;case"TEXTAREA":case"SELECT":t.value=A.value}return t}}]),A}(),c=function(A,t){return(A.cssRules?Array.from(A.cssRules):[]).filter(function(A){return A.type===CSSRule.FONT_FACE_RULE}).map(function(A){for(var e=(0,g.parseBackgroundImage)(A.style.getPropertyValue("src")),n=[],r=0;r0&&"complete"===e.readyState&&(clearInterval(t),n(A))},50)}})},H=(t.cloneWindow=function(A,t,e,n,r,i){var o=new a(e,n,r,!1,i),s=A.defaultView.pageXOffset,c=A.defaultView.pageYOffset;return E(A,t).then(function(r){var i=r.contentWindow,a=i.document,l=b(r).then(function(){o.scrolledElements.forEach(y),i.scrollTo(t.left,t.top),!/(iPad|iPhone|iPod)/g.test(navigator.userAgent)||i.scrollY===t.top&&i.scrollX===t.left||(a.documentElement.style.top=-t.top+"px",a.documentElement.style.left=-t.left+"px",a.documentElement.style.position="absolute");var e=Promise.resolve([r,o.clonedReferenceElement,o.resourceLoader]),s=n.onclone;return o.clonedReferenceElement instanceof i.HTMLElement||o.clonedReferenceElement instanceof A.defaultView.HTMLElement||o.clonedReferenceElement instanceof HTMLElement?"function"==typeof s?Promise.resolve().then(function(){return s(a)}).then(function(){return e}):e:Promise.reject("")});return a.open(),a.write(H(document.doctype)+""),function(A,t,e){!A.defaultView||t===A.defaultView.pageXOffset&&e===A.defaultView.pageYOffset||A.defaultView.scrollTo(t,e)}(e.ownerDocument,s,c),a.replaceChild(a.adoptNode(o.documentElement),a.documentElement),a.close(),l})},function(A){var t="";return A&&(t+=""),t})});t(rA);rA.cloneWindow,rA.DocumentCloner;var iA=e(function(A,t){function e(A){return A&&A.__esModule?A:{default:A}}Object.defineProperty(t,"__esModule",{value:!0}),t.renderElement=void 0;var n=function(){return function(A,t){if(Array.isArray(A))return A;if(Symbol.iterator in Object(A))return function(A,t){var e=[],n=!0,r=!1,i=void 0;try{for(var o,a=A[Symbol.iterator]();!(n=(o=a.next()).done)&&(e.push(o.value),!t||e.length!==t);n=!0);}catch(A){r=!0,i=A}finally{try{!n&&a.return&&a.return()}finally{if(r)throw i}}return e}(A,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),r=(e(c),e(AA)),i=e(k),a=e(P),s=e(o);t.renderElement=function A(t,e,c){var l=t.ownerDocument,u=new B.Bounds(e.scrollX,e.scrollY,e.windowWidth,e.windowHeight),h=l.documentElement?new s.default(getComputedStyle(l.documentElement).backgroundColor):o.TRANSPARENT,d=l.body?new s.default(getComputedStyle(l.body).backgroundColor):o.TRANSPARENT,f=t===l.documentElement?h.isTransparent()?d.isTransparent()?e.backgroundColor?new s.default(e.backgroundColor):null:d:h:e.backgroundColor?new s.default(e.backgroundColor):null;return(e.foreignObjectRendering?a.default.SUPPORT_FOREIGNOBJECT_DRAWING:Promise.resolve(!1)).then(function(a){return a?function(A){return A.inlineFonts(l).then(function(){return A.resourceLoader.ready()}).then(function(){var n=new i.default(A.documentElement),r=l.defaultView,o=r.pageXOffset,a=r.pageYOffset,s="HTML"===t.tagName||"BODY"===t.tagName?(0,B.parseDocumentSize)(l):(0,B.parseBounds)(t,o,a),u=s.width,h=s.height,d=s.left,p=s.top;return n.render({backgroundColor:f,logger:c,scale:e.scale,x:"number"==typeof e.x?e.x:d,y:"number"==typeof e.y?e.y:p,width:"number"==typeof e.width?e.width:Math.ceil(u),height:"number"==typeof e.height?e.height:Math.ceil(h),windowWidth:e.windowWidth,windowHeight:e.windowHeight,scrollX:e.scrollX,scrollY:e.scrollY})})}(new rA.DocumentCloner(t,e,c,!0,A)):(0,rA.cloneWindow)(l,u,t,e,c,A).then(function(A){var t=n(A,3),i=t[0],a=t[1],s=t[2],u=(0,J.NodeParser)(a,s,c),h=a.ownerDocument;return f===u.container.style.background.backgroundColor&&(u.container.style.background.backgroundColor=o.TRANSPARENT),s.ready().then(function(A){var t=new W.FontMetrics(h),n=h.defaultView,o=n.pageXOffset,s=n.pageYOffset,d="HTML"===a.tagName||"BODY"===a.tagName?(0,B.parseDocumentSize)(l):(0,B.parseBounds)(a,o,s),p=d.width,g=d.height,w=d.left,m=d.top,Q={backgroundColor:f,fontMetrics:t,imageStore:A,logger:c,scale:e.scale,x:"number"==typeof e.x?e.x:w,y:"number"==typeof e.y?e.y:m,width:"number"==typeof e.width?e.width:Math.ceil(p),height:"number"==typeof e.height?e.height:Math.ceil(g)};if(Array.isArray(e.target))return Promise.all(e.target.map(function(A){return new r.default(A,Q).render(u)}));var C=new r.default(e.target,Q).render(u);return!0===e.removeContainer&&i.parentNode&&i.parentNode.removeChild(i),C})})})}});t(iA);iA.renderElement;var oA=t(e(function(A){function t(A){return A&&A.__esModule?A:{default:A}}var e=Object.assign||function(A){for(var t=1;t0;null)n[r].parentNode.removeChild(n[r])}for(var i in t.style)e.style[i]=t.style[i];return e},uA=function(A,t){var e={};for(var n in A)e[n]=72*A[n]/96/t;return e},hA=function A(t){var e=sA(A.convert(Promise.resolve()),JSON.parse(JSON.stringify(A.template))),n=A.convert(Promise.resolve(),e);return n=n.setProgress(1,A,1,[A]),n=n.set(t)};(hA.prototype=Object.create(Promise.prototype)).constructor=hA,hA.convert=function(A,t){return A.__proto__=t||hA.prototype,A},hA.template={prop:{src:null,container:null,overlay:null,canvas:null,img:null,pdf:null,pageSize:null},progress:{val:0,state:null,n:0,stack:[]},opt:{filename:"file.pdf",margin:[0,0,0,0],image:{type:"jpeg",quality:.95},enableLinks:!0,html2canvas:{},jsPDF:{}}},hA.prototype.from=function(A,t){return this.then(function(){switch(t=t||function(A){switch(cA(A)){case"string":return"string";case"element":return"canvas"===A.nodeName.toLowerCase?"canvas":"element";default:return"unknown"}}(A)){case"string":return this.set({src:lA("div",{innerHTML:A})});case"element":return this.set({src:A});case"canvas":return this.set({canvas:A});case"img":return this.set({img:A});default:return this.error("Unknown source type.")}})},hA.prototype.to=function(A){switch(A){case"container":return this.toContainer();case"canvas":return this.toCanvas();case"img":return this.toImg();case"pdf":return this.toPdf();default:return this.error("Invalid target.")}},hA.prototype.toContainer=function(){return this.thenList([function(){return this.prop.src||this.error("Cannot duplicate - no source HTML.")},function(){return this.prop.pageSize||this.setPageSize()}]).then(function(){var A={position:"fixed",overflow:"hidden",zIndex:1e3,left:0,right:0,bottom:0,top:0,backgroundColor:"rgba(0,0,0,0.8)"},t={position:"absolute",width:this.prop.pageSize.inner.width+this.prop.pageSize.unit,left:0,right:0,top:0,height:"auto",margin:"auto",backgroundColor:"white"};A.opacity=0;var e=function A(t,e){for(var n=3===t.nodeType?document.createTextNode(t.nodeValue):t.cloneNode(!1),r=t.firstChild;r;r=r.nextSibling)!0!==e&&1===r.nodeType&&"SCRIPT"===r.nodeName||n.appendChild(A(r,e));return 1===t.nodeType&&("CANVAS"===t.nodeName?(n.width=t.width,n.height=t.height,n.getContext("2d").drawImage(t,0,0)):"TEXTAREA"!==t.nodeName&&"SELECT"!==t.nodeName||(n.value=t.value),n.addEventListener("load",function(){n.scrollTop=t.scrollTop,n.scrollLeft=t.scrollLeft},!0)),n}(this.prop.src,this.opt.html2canvas.javascriptEnabled);this.prop.overlay=lA("div",{className:"html2pdf__overlay",style:A}),this.prop.container=lA("div",{className:"html2pdf__container",style:t}),this.prop.container.appendChild(e),this.prop.overlay.appendChild(this.prop.container),document.body.appendChild(this.prop.overlay)})},hA.prototype.toCanvas=function(){var A=[function(){return document.body.contains(this.prop.container)||this.toContainer()}];return this.thenList(A).then(function(){var A=sA({},this.opt.html2canvas);return delete A.onrendered,oA(this.prop.container,A)}).then(function(A){(this.opt.html2canvas.onrendered||function(){})(A),this.prop.canvas=A,document.body.removeChild(this.prop.overlay)})},hA.prototype.toImg=function(){return this.thenList([function(){return this.prop.canvas||this.toCanvas()}]).then(function(){var A=this.prop.canvas.toDataURL("image/"+this.opt.image.type,this.opt.image.quality);this.prop.img=document.createElement("img"),this.prop.img.src=A})},hA.prototype.toPdf=function(){return this.thenList([function(){return this.prop.canvas||this.toCanvas()}]).then(function(){var A=this.prop.canvas,t=this.opt,e=(A.getContext("2d"),A.height),n=Math.floor(A.width*this.prop.pageSize.inner.ratio),i=Math.ceil(e/n),o=this.prop.pageSize.inner.height,a=document.createElement("canvas"),s=a.getContext("2d");a.width=A.width,a.height=n,this.prop.pdf=this.prop.pdf||new r(t.jsPDF);for(var c=0;ca){c=s;s=a,a=c}}else{if("l"!==A&&"landscape"!==A)throw"Invalid orientation: "+A;if(A="l",a>s){var c=s;s=a,a=c}}return{width:s,height:a,unit:t,k:o}};var dA={toContainer:hA.prototype.toContainer};hA.prototype.toContainer=function(){return dA.toContainer.call(this).then(function(){var A=this.prop.container.querySelectorAll(".html2pdf__page-break"),t=this.prop.pageSize.inner.px.height;Array.prototype.forEach.call(A,function(A){A.style.display="block";var e=A.getBoundingClientRect();A.style.height=t-e.top%t+"px"},this)})};var fA=[],BA={toContainer:hA.prototype.toContainer,toPdf:hA.prototype.toPdf};hA.prototype.toContainer=function(){return BA.toContainer.call(this).then(function(){if(this.opt.enableLinks){var A=this.prop.container,t=A.querySelectorAll("a"),e=uA(A.getBoundingClientRect(),this.prop.pageSize.k);fA=[],Array.prototype.forEach.call(t,function(A){for(var t=A.getClientRects(),n=0;n