vendors~canvg.c2910215.js 139 KB

1
  1. (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["vendors~canvg"],{1276:function(t,e,r){"use strict";var n=r("d784"),i=r("44e7"),a=r("825a"),o=r("1d80"),u=r("4840"),s=r("8aa5"),c=r("50c4"),l=r("14c3"),f=r("9263"),h=r("d039"),g=[].push,y=Math.min,p=4294967295,d=!h((function(){return!RegExp(p,"y")}));n("split",2,(function(t,e,r){var n;return n="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(t,r){var n=String(o(this)),a=void 0===r?p:r>>>0;if(0===a)return[];if(void 0===t)return[n];if(!i(t))return e.call(n,t,a);var u,s,c,l=[],h=(t.ignoreCase?"i":"")+(t.multiline?"m":"")+(t.unicode?"u":"")+(t.sticky?"y":""),y=0,d=new RegExp(t.source,h+"g");while(u=f.call(d,n)){if(s=d.lastIndex,s>y&&(l.push(n.slice(y,u.index)),u.length>1&&u.index<n.length&&g.apply(l,u.slice(1)),c=u[0].length,y=s,l.length>=a))break;d.lastIndex===u.index&&d.lastIndex++}return y===n.length?!c&&d.test("")||l.push(""):l.push(n.slice(y)),l.length>a?l.slice(0,a):l}:"0".split(void 0,0).length?function(t,r){return void 0===t&&0===r?[]:e.call(this,t,r)}:e,[function(e,r){var i=o(this),a=void 0==e?void 0:e[t];return void 0!==a?a.call(e,i,r):n.call(String(i),e,r)},function(t,i){var o=r(n,t,this,i,n!==e);if(o.done)return o.value;var f=a(t),h=String(this),g=u(f,RegExp),v=f.unicode,m=(f.ignoreCase?"i":"")+(f.multiline?"m":"")+(f.unicode?"u":"")+(d?"y":"g"),x=new g(d?f:"^(?:"+f.source+")",m),b=void 0===i?p:i>>>0;if(0===b)return[];if(0===h.length)return null===l(x,h)?[h]:[];var k=0,w=0,S=[];while(w<h.length){x.lastIndex=d?w:0;var P,R=l(x,d?h:h.slice(w));if(null===R||(P=y(c(x.lastIndex+(d?0:w)),h.length))===k)w=s(h,w,v);else{if(S.push(h.slice(k,w)),S.length===b)return S;for(var A=1;A<=R.length-1;A++)if(S.push(R[A]),S.length===b)return S;w=k=P}}return S.push(h.slice(k)),S}]}),!d)},"26e9":function(t,e,r){"use strict";var n=r("23e7"),i=r("e8b5"),a=[].reverse,o=[1,2];n({target:"Array",proto:!0,forced:String(o)===String(o.reverse())},{reverse:function(){return i(this)&&(this.length=this.length),a.call(this)}})},"36c6":function(t,e,r){function n(e){return t.exports=n=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},t.exports.__esModule=!0,t.exports["default"]=t.exports,n(e)}r("3410"),r("131a"),t.exports=n,t.exports.__esModule=!0,t.exports["default"]=t.exports},"3c96":function(t,e){function r(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}t.exports=r,t.exports.__esModule=!0,t.exports["default"]=t.exports},4160:function(t,e,r){"use strict";var n=r("23e7"),i=r("17c2");n({target:"Array",proto:!0,forced:[].forEach!=i},{forEach:i})},"45fc":function(t,e,r){"use strict";var n=r("23e7"),i=r("b727").some,a=r("a640"),o=r("ae40"),u=a("some"),s=o("some");n({target:"Array",proto:!0,forced:!u||!s},{some:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},"4a4b":function(t,e,r){function n(e,r){return t.exports=n=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},t.exports.__esModule=!0,t.exports["default"]=t.exports,n(e,r)}r("131a"),t.exports=n,t.exports.__esModule=!0,t.exports["default"]=t.exports},"4ec9":function(t,e,r){"use strict";var n=r("6d61"),i=r("6566");t.exports=n("Map",(function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}}),i)},"58e1":function(t,e){t.exports=function(t){this.ok=!1,this.alpha=1,"#"==t.charAt(0)&&(t=t.substr(1,6)),t=t.replace(/ /g,""),t=t.toLowerCase();var e={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"00ffff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000000",blanchedalmond:"ffebcd",blue:"0000ff",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"00ffff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dodgerblue:"1e90ff",feldspar:"d19275",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"ff00ff",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgrey:"d3d3d3",lightgreen:"90ee90",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslateblue:"8470ff",lightslategray:"778899",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"00ff00",limegreen:"32cd32",linen:"faf0e6",magenta:"ff00ff",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370d8",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"d87093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"ff0000",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",violetred:"d02090",wheat:"f5deb3",white:"ffffff",whitesmoke:"f5f5f5",yellow:"ffff00",yellowgreen:"9acd32"};t=e[t]||t;for(var r=[{re:/^rgba\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3}),\s*((?:\d?\.)?\d)\)$/,example:["rgba(123, 234, 45, 0.8)","rgba(255,234,245,1.0)"],process:function(t){return[parseInt(t[1]),parseInt(t[2]),parseInt(t[3]),parseFloat(t[4])]}},{re:/^rgb\((\d{1,3}),\s*(\d{1,3}),\s*(\d{1,3})\)$/,example:["rgb(123, 234, 45)","rgb(255,234,245)"],process:function(t){return[parseInt(t[1]),parseInt(t[2]),parseInt(t[3])]}},{re:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,example:["#00ff00","336699"],process:function(t){return[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]}},{re:/^([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,example:["#fb0","f0f"],process:function(t){return[parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),parseInt(t[3]+t[3],16)]}}],n=0;n<r.length;n++){var i=r[n].re,a=r[n].process,o=i.exec(t);if(o){var u=a(o);this.r=u[0],this.g=u[1],this.b=u[2],u.length>3&&(this.alpha=u[3]),this.ok=!0}}this.r=this.r<0||isNaN(this.r)?0:this.r>255?255:this.r,this.g=this.g<0||isNaN(this.g)?0:this.g>255?255:this.g,this.b=this.b<0||isNaN(this.b)?0:this.b>255?255:this.b,this.alpha=this.alpha<0?0:this.alpha>1||isNaN(this.alpha)?1:this.alpha,this.toRGB=function(){return"rgb("+this.r+", "+this.g+", "+this.b+")"},this.toRGBA=function(){return"rgba("+this.r+", "+this.g+", "+this.b+", "+this.alpha+")"},this.toHex=function(){var t=this.r.toString(16),e=this.g.toString(16),r=this.b.toString(16);return 1==t.length&&(t="0"+t),1==e.length&&(e="0"+e),1==r.length&&(r="0"+r),"#"+t+e+r},this.getHelpXML=function(){for(var t=new Array,n=0;n<r.length;n++)for(var i=r[n].example,a=0;a<i.length;a++)t[t.length]=i[a];for(var o in e)t[t.length]=o;var u=document.createElement("ul");u.setAttribute("id","rgbcolor-examples");for(n=0;n<t.length;n++)try{var s=document.createElement("li"),c=new RGBColor(t[n]),l=document.createElement("div");l.style.cssText="margin: 3px; border: 1px solid black; background:"+c.toHex()+"; color:"+c.toHex(),l.appendChild(document.createTextNode("test"));var f=document.createTextNode(" "+t[n]+" -> "+c.toRGB()+" -> "+c.toHex());s.appendChild(l),s.appendChild(f),u.appendChild(s)}catch(h){}return u}}},"5bc3":function(t,e,r){var n=r("a395");function i(t,e){for(var r=0;r<e.length;r++){var i=e[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,n(i.key),i)}}function a(t,e,r){return e&&i(t.prototype,e),r&&i(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t}t.exports=a,t.exports.__esModule=!0,t.exports["default"]=t.exports},"5d41":function(t,e,r){var n=r("23e7"),i=r("861d"),a=r("825a"),o=r("5135"),u=r("06cf"),s=r("e163");function c(t,e){var r,n,l=arguments.length<3?t:arguments[2];return a(t)===l?t[e]:(r=u.f(t,e))?o(r,"value")?r.value:void 0===r.get?void 0:r.get.call(l):i(n=s(t))?c(n,e,l):void 0}n({target:"Reflect",stat:!0},{get:c})},"5e9e":function(t,e,r){"use strict";function n(t){return n="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},n(t)}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}r.d(e,"a",(function(){return s}));var a=[512,512,456,512,328,456,335,512,405,328,271,456,388,335,292,512,454,405,364,328,298,271,496,456,420,388,360,335,312,292,273,512,482,454,428,405,383,364,345,328,312,298,284,271,259,496,475,456,437,420,404,388,374,360,347,335,323,312,302,292,282,273,265,512,497,482,468,454,441,428,417,405,394,383,373,364,354,345,337,328,320,312,305,298,291,284,278,271,265,259,507,496,485,475,465,456,446,437,428,420,412,404,396,388,381,374,367,360,354,347,341,335,329,323,318,312,307,302,297,292,287,282,278,273,269,265,261,512,505,497,489,482,475,468,461,454,447,441,435,428,422,417,411,405,399,394,389,383,378,373,368,364,359,354,350,345,341,337,332,328,324,320,316,312,309,305,301,298,294,291,287,284,281,278,274,271,268,265,262,259,257,507,501,496,491,485,480,475,470,465,460,456,451,446,442,437,433,428,424,420,416,412,408,404,400,396,392,388,385,381,377,374,370,367,363,360,357,354,350,347,344,341,338,335,332,329,326,323,320,318,315,312,310,307,304,302,299,297,294,292,289,287,285,282,280,278,275,273,271,269,267,265,263,261,259],o=[9,11,12,13,13,14,14,15,15,15,15,16,16,16,16,17,17,17,17,17,17,17,18,18,18,18,18,18,18,18,18,19,19,19,19,19,19,19,19,19,19,19,19,19,19,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,20,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,21,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,22,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,23,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24,24];function u(t,e,r,i,a){if("string"===typeof t&&(t=document.getElementById(t)),!t||"object"!==n(t)||!("getContext"in t))throw new TypeError("Expecting canvas with `getContext` method in processCanvasRGB(A) calls!");var o=t.getContext("2d");try{return o.getImageData(e,r,i,a)}catch(u){throw new Error("unable to access image data: "+u)}}function s(t,e,r,n,i,a){if(!(isNaN(a)||a<1)){a|=0;var o=u(t,e,r,n,i);o=c(o,e,r,n,i,a),t.getContext("2d").putImageData(o,e,r)}}function c(t,e,r,n,i,u){for(var s,c=t.data,f=2*u+1,h=n-1,g=i-1,y=u+1,p=y*(y+1)/2,d=new l,v=d,m=1;m<f;m++)v=v.next=new l,m===y&&(s=v);v.next=d;for(var x=null,b=null,k=0,w=0,S=a[u],P=o[u],R=0;R<i;R++){v=d;for(var A=c[w],C=c[w+1],M=c[w+2],E=c[w+3],V=0;V<y;V++)v.r=A,v.g=C,v.b=M,v.a=E,v=v.next;for(var D=0,T=0,O=0,N=0,L=y*A,z=y*C,B=y*M,I=y*E,F=p*A,j=p*C,_=p*M,$=p*E,q=1;q<y;q++){var G=w+((h<q?h:q)<<2),H=c[G],X=c[G+1],W=c[G+2],Y=c[G+3],U=y-q;F+=(v.r=H)*U,j+=(v.g=X)*U,_+=(v.b=W)*U,$+=(v.a=Y)*U,D+=H,T+=X,O+=W,N+=Y,v=v.next}x=d,b=s;for(var Q=0;Q<n;Q++){var Z=$*S>>>P;if(c[w+3]=Z,0!==Z){var J=255/Z;c[w]=(F*S>>>P)*J,c[w+1]=(j*S>>>P)*J,c[w+2]=(_*S>>>P)*J}else c[w]=c[w+1]=c[w+2]=0;F-=L,j-=z,_-=B,$-=I,L-=x.r,z-=x.g,B-=x.b,I-=x.a;var K=Q+u+1;K=k+(K<h?K:h)<<2,D+=x.r=c[K],T+=x.g=c[K+1],O+=x.b=c[K+2],N+=x.a=c[K+3],F+=D,j+=T,_+=O,$+=N,x=x.next;var tt=b,et=tt.r,rt=tt.g,nt=tt.b,it=tt.a;L+=et,z+=rt,B+=nt,I+=it,D-=et,T-=rt,O-=nt,N-=it,b=b.next,w+=4}k+=n}for(var at=0;at<n;at++){w=at<<2;var ot=c[w],ut=c[w+1],st=c[w+2],ct=c[w+3],lt=y*ot,ft=y*ut,ht=y*st,gt=y*ct,yt=p*ot,pt=p*ut,dt=p*st,vt=p*ct;v=d;for(var mt=0;mt<y;mt++)v.r=ot,v.g=ut,v.b=st,v.a=ct,v=v.next;for(var xt=n,bt=0,kt=0,wt=0,St=0,Pt=1;Pt<=u;Pt++){w=xt+at<<2;var Rt=y-Pt;yt+=(v.r=ot=c[w])*Rt,pt+=(v.g=ut=c[w+1])*Rt,dt+=(v.b=st=c[w+2])*Rt,vt+=(v.a=ct=c[w+3])*Rt,St+=ot,bt+=ut,kt+=st,wt+=ct,v=v.next,Pt<g&&(xt+=n)}w=at,x=d,b=s;for(var At=0;At<i;At++){var Ct=w<<2;c[Ct+3]=ct=vt*S>>>P,ct>0?(ct=255/ct,c[Ct]=(yt*S>>>P)*ct,c[Ct+1]=(pt*S>>>P)*ct,c[Ct+2]=(dt*S>>>P)*ct):c[Ct]=c[Ct+1]=c[Ct+2]=0,yt-=lt,pt-=ft,dt-=ht,vt-=gt,lt-=x.r,ft-=x.g,ht-=x.b,gt-=x.a,Ct=at+((Ct=At+y)<g?Ct:g)*n<<2,yt+=St+=x.r=c[Ct],pt+=bt+=x.g=c[Ct+1],dt+=kt+=x.b=c[Ct+2],vt+=wt+=x.a=c[Ct+3],x=x.next,lt+=ot=b.r,ft+=ut=b.g,ht+=st=b.b,gt+=ct=b.a,St-=ot,bt-=ut,kt-=st,wt-=ct,b=b.next,w+=n}}return t}var l=function t(){i(this,t),this.r=0,this.g=0,this.b=0,this.a=0,this.next=null}},"6b58":function(t,e,r){var n=r("7037")["default"],i=r("3c96");function a(t,e){if(e&&("object"===n(e)||"function"===typeof e))return e;if(void 0!==e)throw new TypeError("Derived constructors may only return object or undefined");return i(t)}t.exports=a,t.exports.__esModule=!0,t.exports["default"]=t.exports},"7f78":function(t,e,r){var n=r("23e7"),i=r("825a"),a=r("e163"),o=r("e177");n({target:"Reflect",stat:!0,sham:!o},{getPrototypeOf:function(t){return a(i(t))}})},8890:function(t,e,r){"use strict";r.r(e),function(t){r.d(e,"AElement",(function(){return Ar})),r.d(e,"AnimateColorElement",(function(){return rr})),r.d(e,"AnimateElement",(function(){return Ke})),r.d(e,"AnimateTransformElement",(function(){return ar})),r.d(e,"BoundingBox",(function(){return $t})),r.d(e,"CB1",(function(){return K})),r.d(e,"CB2",(function(){return tt})),r.d(e,"CB3",(function(){return et})),r.d(e,"CB4",(function(){return rt})),r.d(e,"Canvg",(function(){return Bn})),r.d(e,"CircleElement",(function(){return ye})),r.d(e,"ClipPathElement",(function(){return on})),r.d(e,"DefsElement",(function(){return Le})),r.d(e,"DescElement",(function(){return Cn})),r.d(e,"Document",(function(){return Nn})),r.d(e,"Element",(function(){return Ot})),r.d(e,"EllipseElement",(function(){return ve})),r.d(e,"FeColorMatrixElement",(function(){return Jr})),r.d(e,"FeCompositeElement",(function(){return mn})),r.d(e,"FeDropShadowElement",(function(){return hn})),r.d(e,"FeGaussianBlurElement",(function(){return kn})),r.d(e,"FeMorphologyElement",(function(){return pn})),r.d(e,"FilterElement",(function(){return cn})),r.d(e,"Font",(function(){return _t})),r.d(e,"FontElement",(function(){return fr})),r.d(e,"FontFaceElement",(function(){return yr})),r.d(e,"GElement",(function(){return Ie})),r.d(e,"GlyphElement",(function(){return br})),r.d(e,"GradientElement",(function(){return _e})),r.d(e,"ImageElement",(function(){return Lr})),r.d(e,"LineElement",(function(){return be})),r.d(e,"LinearGradientElement",(function(){return Ge})),r.d(e,"MarkerElement",(function(){return Te})),r.d(e,"MaskElement",(function(){return en})),r.d(e,"Matrix",(function(){return bt})),r.d(e,"MissingGlyphElement",(function(){return vr})),r.d(e,"Mouse",(function(){return lt})),r.d(e,"PSEUDO_ZERO",(function(){return U})),r.d(e,"Parser",(function(){return dt})),r.d(e,"PathElement",(function(){return ae})),r.d(e,"PathParser",(function(){return re})),r.d(e,"PatternElement",(function(){return Ee})),r.d(e,"Point",(function(){return ct})),r.d(e,"PolygonElement",(function(){return Ae})),r.d(e,"PolylineElement",(function(){return Se})),r.d(e,"Property",(function(){return ut})),r.d(e,"QB1",(function(){return nt})),r.d(e,"QB2",(function(){return it})),r.d(e,"QB3",(function(){return at})),r.d(e,"RadialGradientElement",(function(){return We})),r.d(e,"RectElement",(function(){return fe})),r.d(e,"RenderedElement",(function(){return Ht})),r.d(e,"Rotate",(function(){return mt})),r.d(e,"SVGElement",(function(){return se})),r.d(e,"SVGFontLoader",(function(){return Fr})),r.d(e,"Scale",(function(){return xt})),r.d(e,"Screen",(function(){return gt})),r.d(e,"Skew",(function(){return St})),r.d(e,"SkewX",(function(){return At})),r.d(e,"SkewY",(function(){return Et})),r.d(e,"StopElement",(function(){return Qe})),r.d(e,"StyleElement",(function(){return $r})),r.d(e,"SymbolElement",(function(){return Ir})),r.d(e,"TRefElement",(function(){return Sr})),r.d(e,"TSpanElement",(function(){return Zt})),r.d(e,"TextElement",(function(){return Yt})),r.d(e,"TextPathElement",(function(){return Tr})),r.d(e,"TitleElement",(function(){return Pn})),r.d(e,"Transform",(function(){return Tt})),r.d(e,"Translate",(function(){return vt})),r.d(e,"UnknownElement",(function(){return zt})),r.d(e,"UseElement",(function(){return Hr})),r.d(e,"ViewPort",(function(){return st})),r.d(e,"compressSpaces",(function(){return T})),r.d(e,"getSelectorSpecificity",(function(){return Y})),r.d(e,"normalizeAttributeName",(function(){return B})),r.d(e,"normalizeColor",(function(){return F})),r.d(e,"parseExternalUrl",(function(){return I})),r.d(e,"presets",(function(){return jn})),r.d(e,"toNumbers",(function(){return L})),r.d(e,"trimLeft",(function(){return O})),r.d(e,"trimRight",(function(){return N})),r.d(e,"vectorMagnitude",(function(){return Q})),r.d(e,"vectorsAngle",(function(){return J})),r.d(e,"vectorsRatio",(function(){return Z}));r("d81d"),r("ac1f"),r("466d"),r("5319"),r("2ca0"),r("a15b");var n=r("278c"),i=r.n(n),a=(r("a4d3"),r("4de4"),r("4160"),r("e439"),r("dbb4"),r("b64b"),r("159b"),r("a34a")),o=r.n(a),u=r("c973"),s=r.n(u),c=r("9523"),l=r.n(c),f=r("970b"),h=r.n(f),g=r("5bc3"),y=r.n(g),p=(r("99af"),r("a6231"),r("13d5"),r("d3b7"),r("e6cf"),r("1276"),r("c449")),d=r.n(p),v=(r("b0c0"),r("58e1")),m=r.n(v),x=(r("4ae1"),r("25f0"),r("6b58")),b=r.n(x),k=r("36c6"),w=r.n(k),S=r("ed6d"),P=r.n(S),R=(r("a630"),r("caad"),r("45fc"),r("2532"),r("3ca3"),r("498a"),r("448a")),A=r.n(R),C=(r("c975"),r("26e9"),r("8962")),M=r.n(C),E=(r("a9e3"),r("cb29"),r("ac16"),r("3c96")),V=r.n(E),D=(r("e260"),r("ddb0"),r("e01a"),r("d28b"),r("fb6a"),r("4ec9"),r("a6fd"),r("7f78"),r("5e9e"));function T(t){return t.replace(/(?!\u3000)\s+/gm," ")}function O(t){return t.replace(/^[\n \t]+/,"")}function N(t){return t.replace(/[\n \t]+$/,"")}function L(t){var e=(t||"").match(/-?(\d+(?:\.\d*(?:[eE][+-]?\d+)?)?|\.\d+)(?=\D|$)/gm)||[];return e.map(parseFloat)}var z=/^[A-Z-]+$/;function B(t){return z.test(t)?t.toLowerCase():t}function I(t){var e=t.match(/url\(('([^']+)'|"([^"]+)"|([^'"\)]+))\)/)||[];return e[2]||e[3]||e[4]}function F(t){if(!t.startsWith("rgb"))return t;var e=3,r=t.replace(/\d+(\.\d+)?/g,(function(t,r){return e--&&r?String(Math.round(parseFloat(t))):t}));return r}var j=/(\[[^\]]+\])/g,_=/(#[^\s\+>~\.\[:]+)/g,$=/(\.[^\s\+>~\.\[:]+)/g,q=/(::[^\s\+>~\.\[:]+|:first-line|:first-letter|:before|:after)/gi,G=/(:[\w-]+\([^\)]*\))/gi,H=/(:[^\s\+>~\.\[:]+)/g,X=/([^\s\+>~\.\[:]+)/g;function W(t,e){var r=t.match(e);return r?[t.replace(e," "),r.length]:[t,0]}function Y(t){var e=[0,0,0],r=t.replace(/:not\(([^\)]*)\)/g," $1 ").replace(/{[\s\S]*/gm," "),n=0,a=W(r,j),o=i()(a,2);r=o[0],n=o[1],e[1]+=n;var u=W(r,_),s=i()(u,2);r=s[0],n=s[1],e[0]+=n;var c=W(r,$),l=i()(c,2);r=l[0],n=l[1],e[1]+=n;var f=W(r,q),h=i()(f,2);r=h[0],n=h[1],e[2]+=n;var g=W(r,G),y=i()(g,2);r=y[0],n=y[1],e[1]+=n;var p=W(r,H),d=i()(p,2);r=d[0],n=d[1],e[1]+=n,r=r.replace(/[\*\s\+>~]/g," ").replace(/[#\.]/g," ");var v=W(r,X),m=i()(v,2);return r=m[0],n=m[1],e[2]+=n,e.join("")}var U=1e-8;function Q(t){return Math.sqrt(Math.pow(t[0],2)+Math.pow(t[1],2))}function Z(t,e){return(t[0]*e[0]+t[1]*e[1])/(Q(t)*Q(e))}function J(t,e){return(t[0]*e[1]<t[1]*e[0]?-1:1)*Math.acos(Z(t,e))}function K(t){return t*t*t}function tt(t){return 3*t*t*(1-t)}function et(t){return 3*t*(1-t)*(1-t)}function rt(t){return(1-t)*(1-t)*(1-t)}function nt(t){return t*t}function it(t){return 2*t*(1-t)}function at(t){return(1-t)*(1-t)}function ot(t,e){return e={exports:{}},t(e,e.exports),e.exports}ot((function(t){var e=function(t){var e,r=Object.prototype,n=r.hasOwnProperty,i="function"===typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",o=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function s(t,e,r,n){var i=e&&e.prototype instanceof p?e:p,a=Object.create(i.prototype),o=new M(n||[]);return a._invoke=P(t,r,o),a}function c(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(n){return{type:"throw",arg:n}}}t.wrap=s;var l="suspendedStart",f="suspendedYield",h="executing",g="completed",y={};function p(){}function d(){}function v(){}var m={};m[a]=function(){return this};var x=Object.getPrototypeOf,b=x&&x(x(E([])));b&&b!==r&&n.call(b,a)&&(m=b);var k=v.prototype=p.prototype=Object.create(m);function w(t){["next","throw","return"].forEach((function(e){t[e]=function(t){return this._invoke(e,t)}}))}function S(t,e){function r(i,a,o,u){var s=c(t[i],t,a);if("throw"!==s.type){var l=s.arg,f=l.value;return f&&"object"===typeof f&&n.call(f,"__await")?e.resolve(f.__await).then((function(t){r("next",t,o,u)}),(function(t){r("throw",t,o,u)})):e.resolve(f).then((function(t){l.value=t,o(l)}),(function(t){return r("throw",t,o,u)}))}u(s.arg)}var i;function a(t,n){function a(){return new e((function(e,i){r(t,n,e,i)}))}return i=i?i.then(a,a):a()}this._invoke=a}function P(t,e,r){var n=l;return function(i,a){if(n===h)throw new Error("Generator is already running");if(n===g){if("throw"===i)throw a;return V()}r.method=i,r.arg=a;while(1){var o=r.delegate;if(o){var u=R(o,r);if(u){if(u===y)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===l)throw n=g,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=h;var s=c(t,e,r);if("normal"===s.type){if(n=r.done?g:f,s.arg===y)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n=g,r.method="throw",r.arg=s.arg)}}}function R(t,r){var n=t.iterator[r.method];if(n===e){if(r.delegate=null,"throw"===r.method){if(t.iterator["return"]&&(r.method="return",r.arg=e,R(t,r),"throw"===r.method))return y;r.method="throw",r.arg=new TypeError("The iterator does not provide a 'throw' method")}return y}var i=c(n,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,y;var a=i.arg;return a?a.done?(r[t.resultName]=a.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,y):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function A(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function C(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function M(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(A,this),this.reset(!0)}function E(t){if(t){var r=t[a];if(r)return r.call(t);if("function"===typeof t.next)return t;if(!isNaN(t.length)){var i=-1,o=function r(){while(++i<t.length)if(n.call(t,i))return r.value=t[i],r.done=!1,r;return r.value=e,r.done=!0,r};return o.next=o}}return{next:V}}function V(){return{value:e,done:!0}}return d.prototype=k.constructor=v,v.constructor=d,v[u]=d.displayName="GeneratorFunction",t.isGeneratorFunction=function(t){var e="function"===typeof t&&t.constructor;return!!e&&(e===d||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,v):(t.__proto__=v,u in t||(t[u]="GeneratorFunction")),t.prototype=Object.create(k),t},t.awrap=function(t){return{__await:t}},w(S.prototype),S.prototype[o]=function(){return this},t.AsyncIterator=S,t.async=function(e,r,n,i,a){void 0===a&&(a=Promise);var o=new S(s(e,r,n,i),a);return t.isGeneratorFunction(r)?o:o.next().then((function(t){return t.done?t.value:o.next()}))},w(k),k[u]="Generator",k[a]=function(){return this},k.toString=function(){return"[object Generator]"},t.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function r(){while(e.length){var n=e.pop();if(n in t)return r.value=n,r.done=!1,r}return r.done=!0,r}},t.values=E,M.prototype={constructor:M,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(C),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var t=this.tryEntries[0],e=t.completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function i(n,i){return u.type="throw",u.arg=t,r.next=n,i&&(r.method="next",r.arg=e),!!i}for(var a=this.tryEntries.length-1;a>=0;--a){var o=this.tryEntries[a],u=o.completion;if("root"===o.tryLoc)return i("end");if(o.tryLoc<=this.prev){var s=n.call(o,"catchLoc"),c=n.call(o,"finallyLoc");if(s&&c){if(this.prev<o.catchLoc)return i(o.catchLoc,!0);if(this.prev<o.finallyLoc)return i(o.finallyLoc)}else if(s){if(this.prev<o.catchLoc)return i(o.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return i(o.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var a=i;break}}a&&("break"===t||"continue"===t)&&a.tryLoc<=e&&e<=a.finallyLoc&&(a=null);var o=a?a.completion:{};return o.type=t,o.arg=e,a?(this.method="next",this.next=a.finallyLoc,y):this.complete(o)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),C(r),y}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var i=n.arg;C(r)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:E(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),y}},t}(t.exports);try{regeneratorRuntime=e}catch(r){Function("r","regeneratorRuntime = r")(e)}}));var ut=function(){function t(e,r,n){h()(this,t),this.document=e,this.name=r,this.value=n,this.isNormalizedColor=!1}return y()(t,[{key:"hasValue",value:function(){var t=this.value;return null!==t&&""!==t&&0!==t&&"undefined"!==typeof t}},{key:"isString",value:function(t){var e=this.value,r="string"===typeof e;return r&&t?t.test(e):r}},{key:"isUrlDefinition",value:function(){return this.isString(/^url\(/)}},{key:"isPixels",value:function(){if(!this.hasValue())return!1;var t=this.getString();switch(!0){case/px$/.test(t):case/^[0-9]+$/.test(t):return!0;default:return!1}}},{key:"setValue",value:function(t){return this.value=t,this}},{key:"getValue",value:function(t){return"undefined"===typeof t||this.hasValue()?this.value:t}},{key:"getNumber",value:function(t){if(!this.hasValue())return"undefined"===typeof t?0:parseFloat(t);var e=this.value,r=parseFloat(e);return this.isString(/%$/)&&(r/=100),r}},{key:"getString",value:function(t){return"undefined"===typeof t||this.hasValue()?"undefined"===typeof this.value?"":String(this.value):String(t)}},{key:"getColor",value:function(t){var e=this.getString(t);return this.isNormalizedColor||(this.isNormalizedColor=!0,e=F(e),this.value=e),e}},{key:"getDpi",value:function(){return 96}},{key:"getRem",value:function(){return this.document.rootEmSize}},{key:"getEm",value:function(){return this.document.emSize}},{key:"getUnits",value:function(){return this.getString().replace(/[0-9\.\-]/g,"")}},{key:"getPixels",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!this.hasValue())return 0;var r="boolean"===typeof t?[void 0,t]:[t],n=i()(r,2),a=n[0],o=n[1],u=this.document.screen.viewPort;switch(!0){case this.isString(/vmin$/):return this.getNumber()/100*Math.min(u.computeSize("x"),u.computeSize("y"));case this.isString(/vmax$/):return this.getNumber()/100*Math.max(u.computeSize("x"),u.computeSize("y"));case this.isString(/vw$/):return this.getNumber()/100*u.computeSize("x");case this.isString(/vh$/):return this.getNumber()/100*u.computeSize("y");case this.isString(/rem$/):return this.getNumber()*this.getRem();case this.isString(/em$/):return this.getNumber()*this.getEm();case this.isString(/ex$/):return this.getNumber()*this.getEm()/2;case this.isString(/px$/):return this.getNumber();case this.isString(/pt$/):return this.getNumber()*this.getDpi()*(1/72);case this.isString(/pc$/):return 15*this.getNumber();case this.isString(/cm$/):return this.getNumber()*this.getDpi()/2.54;case this.isString(/mm$/):return this.getNumber()*this.getDpi()/25.4;case this.isString(/in$/):return this.getNumber()*this.getDpi();case this.isString(/%$/)&&o:return this.getNumber()*this.getEm();case this.isString(/%$/):return this.getNumber()*u.computeSize(a);default:var s=this.getNumber();return e&&s<1?s*u.computeSize(a):s}}},{key:"getMilliseconds",value:function(){return this.hasValue()?this.isString(/ms$/)?this.getNumber():1e3*this.getNumber():0}},{key:"getRadians",value:function(){if(!this.hasValue())return 0;switch(!0){case this.isString(/deg$/):return this.getNumber()*(Math.PI/180);case this.isString(/grad$/):return this.getNumber()*(Math.PI/200);case this.isString(/rad$/):return this.getNumber();default:return this.getNumber()*(Math.PI/180)}}},{key:"getDefinition",value:function(){var t=this.getString(),e=t.match(/#([^\)'"]+)/);return e&&(e=e[1]),e||(e=t),this.document.definitions[e]}},{key:"getFillStyleDefinition",value:function(t,e){var r=this.getDefinition();if(!r)return null;if("function"===typeof r.createGradient)return r.createGradient(this.document.ctx,t,e);if("function"===typeof r.createPattern){if(r.getHrefAttribute().hasValue()){var n=r.getAttribute("patternTransform");r=r.getHrefAttribute().getDefinition(),n.hasValue()&&r.getAttribute("patternTransform",!0).setValue(n.value)}return r.createPattern(this.document.ctx,t,e)}return null}},{key:"getTextBaseline",value:function(){return this.hasValue()?t.textBaselineMapping[this.getString()]:null}},{key:"addOpacity",value:function(e){for(var r=this.getColor(),n=r.length,i=0,a=0;a<n;a++)if(","===r[a]&&i++,3===i)break;if(e.hasValue()&&this.isString()&&3!==i){var o=new m.a(r);o.ok&&(o.alpha=e.getNumber(),r=o.toRGBA())}return new t(this.document,this.name,r)}}],[{key:"empty",value:function(e){return new t(e,"EMPTY","")}}]),t}();ut.textBaselineMapping={baseline:"alphabetic","before-edge":"top","text-before-edge":"top",middle:"middle",central:"middle","after-edge":"bottom","text-after-edge":"bottom",ideographic:"ideographic",alphabetic:"alphabetic",hanging:"hanging",mathematical:"alphabetic"};var st=function(){function t(){h()(this,t),this.viewPorts=[]}return y()(t,[{key:"clear",value:function(){this.viewPorts=[]}},{key:"setCurrent",value:function(t,e){this.viewPorts.push({width:t,height:e})}},{key:"removeCurrent",value:function(){this.viewPorts.pop()}},{key:"getCurrent",value:function(){var t=this.viewPorts;return t[t.length-1]}},{key:"computeSize",value:function(t){return"number"===typeof t?t:"x"===t?this.width:"y"===t?this.height:Math.sqrt(Math.pow(this.width,2)+Math.pow(this.height,2))/Math.sqrt(2)}},{key:"width",get:function(){return this.getCurrent().width}},{key:"height",get:function(){return this.getCurrent().height}}]),t}(),ct=function(){function t(e,r){h()(this,t),this.x=e,this.y=r}return y()(t,[{key:"angleTo",value:function(t){return Math.atan2(t.y-this.y,t.x-this.x)}},{key:"applyTransform",value:function(t){var e=this.x,r=this.y,n=e*t[0]+r*t[2]+t[4],i=e*t[1]+r*t[3]+t[5];this.x=n,this.y=i}}],[{key:"parse",value:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=L(e),a=i()(n,2),o=a[0],u=void 0===o?r:o,s=a[1],c=void 0===s?r:s;return new t(u,c)}},{key:"parseScale",value:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=L(e),a=i()(n,2),o=a[0],u=void 0===o?r:o,s=a[1],c=void 0===s?u:s;return new t(u,c)}},{key:"parsePath",value:function(e){for(var r=L(e),n=r.length,i=[],a=0;a<n;a+=2)i.push(new t(r[a],r[a+1]));return i}}]),t}(),lt=function(){function t(e){h()(this,t),this.screen=e,this.working=!1,this.events=[],this.eventElements=[],this.onClick=this.onClick.bind(this),this.onMouseMove=this.onMouseMove.bind(this)}return y()(t,[{key:"isWorking",value:function(){return this.working}},{key:"start",value:function(){if(!this.working){var t=this.screen,e=this.onClick,r=this.onMouseMove,n=t.ctx.canvas;n.onclick=e,n.onmousemove=r,this.working=!0}}},{key:"stop",value:function(){if(this.working){var t=this.screen.ctx.canvas;this.working=!1,t.onclick=null,t.onmousemove=null}}},{key:"hasEvents",value:function(){return this.working&&this.events.length>0}},{key:"runEvents",value:function(){if(this.working){var t=this.screen,e=this.events,r=this.eventElements,n=t.ctx.canvas.style;n&&(n.cursor=""),e.forEach((function(t,e){var n=t.run,i=r[e];while(i)n(i),i=i.parent})),this.events=[],this.eventElements=[]}}},{key:"checkPath",value:function(t,e){if(this.working&&e){var r=this.events,n=this.eventElements;r.forEach((function(r,i){var a=r.x,o=r.y;!n[i]&&e.isPointInPath&&e.isPointInPath(a,o)&&(n[i]=t)}))}}},{key:"checkBoundingBox",value:function(t,e){if(this.working&&e){var r=this.events,n=this.eventElements;r.forEach((function(r,i){var a=r.x,o=r.y;!n[i]&&e.isPointInBox(a,o)&&(n[i]=t)}))}}},{key:"mapXY",value:function(t,e){var r=this.screen,n=r.window,i=r.ctx,a=new ct(t,e),o=i.canvas;while(o)a.x-=o.offsetLeft,a.y-=o.offsetTop,o=o.offsetParent;return n.scrollX&&(a.x+=n.scrollX),n.scrollY&&(a.y+=n.scrollY),a}},{key:"onClick",value:function(t){var e=this.mapXY((t||event).clientX,(t||event).clientY),r=e.x,n=e.y;this.events.push({type:"onclick",x:r,y:n,run:function(t){t.onClick&&t.onClick()}})}},{key:"onMouseMove",value:function(t){var e=this.mapXY((t||event).clientX,(t||event).clientY),r=e.x,n=e.y;this.events.push({type:"onmousemove",x:r,y:n,run:function(t){t.onMouseMove&&t.onMouseMove()}})}}]),t}(),ft="undefined"!==typeof window?window:null,ht="undefined"!==typeof fetch?fetch.bind(void 0):null,gt=function(){function t(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=r.fetch,i=void 0===n?ht:n,a=r.window,o=void 0===a?ft:a;h()(this,t),this.ctx=e,this.FRAMERATE=30,this.MAX_VIRTUAL_PIXELS=3e4,this.CLIENT_WIDTH=800,this.CLIENT_HEIGHT=600,this.viewPort=new st,this.mouse=new lt(this),this.animations=[],this.waits=[],this.frameDuration=0,this.isReadyLock=!1,this.isFirstRender=!0,this.intervalId=null,this.window=o,this.fetch=i}return y()(t,[{key:"wait",value:function(t){this.waits.push(t)}},{key:"ready",value:function(){return this.readyPromise?this.readyPromise:Promise.resolve()}},{key:"isReady",value:function(){if(this.isReadyLock)return!0;var t=this.waits.every((function(t){return t()}));return t&&(this.waits=[],this.resolveReady&&this.resolveReady()),this.isReadyLock=t,t}},{key:"setDefaults",value:function(t){t.strokeStyle="rgba(0,0,0,0)",t.lineCap="butt",t.lineJoin="miter",t.miterLimit=4}},{key:"setViewBox",value:function(t){var e=t.document,r=t.ctx,n=t.aspectRatio,a=t.width,o=t.desiredWidth,u=t.height,s=t.desiredHeight,c=t.minX,l=void 0===c?0:c,f=t.minY,h=void 0===f?0:f,g=t.refX,y=t.refY,p=t.clip,d=void 0!==p&&p,v=t.clipX,m=void 0===v?0:v,x=t.clipY,b=void 0===x?0:x,k=T(n).replace(/^defer\s/,""),w=k.split(" "),S=i()(w,2),P=S[0],R=S[1],A=P||"xMidYMid",C=R||"meet",M=a/o,E=u/s,V=Math.min(M,E),D=Math.max(M,E),O=o,N=s;"meet"===C&&(O*=V,N*=V),"slice"===C&&(O*=D,N*=D);var L=new ut(e,"refX",g),z=new ut(e,"refY",y),B=L.hasValue()&&z.hasValue();if(B&&r.translate(-V*L.getPixels("x"),-V*z.getPixels("y")),d){var I=V*m,F=V*b;r.beginPath(),r.moveTo(I,F),r.lineTo(a,F),r.lineTo(a,u),r.lineTo(I,u),r.closePath(),r.clip()}if(!B){var j="meet"===C&&V===E,_="slice"===C&&D===E,$="meet"===C&&V===M,q="slice"===C&&D===M;/^xMid/.test(A)&&(j||_)&&r.translate(a/2-O/2,0),/YMid$/.test(A)&&($||q)&&r.translate(0,u/2-N/2),/^xMax/.test(A)&&(j||_)&&r.translate(a-O,0),/YMax$/.test(A)&&($||q)&&r.translate(0,u-N)}switch(!0){case"none"===A:r.scale(M,E);break;case"meet"===C:r.scale(V,V);break;case"slice"===C:r.scale(D,D);break}r.translate(-l,-h)}},{key:"start",value:function(t){var e=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=r.enableRedraw,i=void 0!==n&&n,a=r.ignoreMouse,o=void 0!==a&&a,u=r.ignoreAnimation,s=void 0!==u&&u,c=r.ignoreDimensions,l=void 0!==c&&c,f=r.ignoreClear,h=void 0!==f&&f,g=r.forceRedraw,y=r.scaleWidth,p=r.scaleHeight,v=r.offsetX,m=r.offsetY,x=this.FRAMERATE,b=this.mouse,k=1e3/x;if(this.frameDuration=k,this.readyPromise=new Promise((function(t){e.resolveReady=t})),this.isReady()&&this.render(t,l,h,y,p,v,m),i){var w=Date.now(),S=w,P=0,R=function r(){w=Date.now(),P=w-S,P>=k&&(S=w-P%k,e.shouldUpdate(s,g)&&(e.render(t,l,h,y,p,v,m),b.runEvents())),e.intervalId=d()(r)};o||b.start(),this.intervalId=d()(R)}}},{key:"stop",value:function(){this.intervalId&&(d.a.cancel(this.intervalId),this.intervalId=null),this.mouse.stop()}},{key:"shouldUpdate",value:function(t,e){if(!t){var r=this.frameDuration,n=this.animations.reduce((function(t,e){return e.update(r)||t}),!1);if(n)return!0}return!("function"!==typeof e||!e())||(!(this.isReadyLock||!this.isReady())||!!this.mouse.hasEvents())}},{key:"render",value:function(t,e,r,n,i,a,o){var u=this.CLIENT_WIDTH,s=this.CLIENT_HEIGHT,c=this.viewPort,l=this.ctx,f=this.isFirstRender,h=l.canvas;c.clear(),h.width&&h.height?c.setCurrent(h.width,h.height):c.setCurrent(u,s);var g=t.getStyle("width"),y=t.getStyle("height");!e&&(f||"number"!==typeof n&&"number"!==typeof i)&&(g.hasValue()&&(h.width=g.getPixels("x"),h.style&&(h.style.width="".concat(h.width,"px"))),y.hasValue()&&(h.height=y.getPixels("y"),h.style&&(h.style.height="".concat(h.height,"px"))));var p=h.clientWidth||h.width,d=h.clientHeight||h.height;if(e&&g.hasValue()&&y.hasValue()&&(p=g.getPixels("x"),d=y.getPixels("y")),c.setCurrent(p,d),"number"===typeof a&&t.getAttribute("x",!0).setValue(a),"number"===typeof o&&t.getAttribute("y",!0).setValue(o),"number"===typeof n||"number"===typeof i){var v=L(t.getAttribute("viewBox").getString()),m=0,x=0;if("number"===typeof n){var b=t.getStyle("width");b.hasValue()?m=b.getPixels("x")/n:isNaN(v[2])||(m=v[2]/n)}if("number"===typeof i){var k=t.getStyle("height");k.hasValue()?x=k.getPixels("y")/i:isNaN(v[3])||(x=v[3]/i)}m||(m=x),x||(x=m),t.getAttribute("width",!0).setValue(n),t.getAttribute("height",!0).setValue(i);var w=t.getStyle("transform",!0,!0);w.setValue("".concat(w.getString()," scale(").concat(1/m,", ").concat(1/x,")"))}r||l.clearRect(0,0,p,d),t.render(l),f&&(this.isFirstRender=!1)}}]),t}();gt.defaultWindow=ft,gt.defaultFetch=ht;var yt=gt.defaultFetch,pt="undefined"!==typeof DOMParser?DOMParser:null,dt=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=e.fetch,n=void 0===r?yt:r,i=e.DOMParser,a=void 0===i?pt:i;h()(this,t),this.fetch=n,this.DOMParser=a}return y()(t,[{key:"parse",value:function(){var t=s()(o.a.mark((function t(e){return o.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:if(!/^</.test(e)){t.next=2;break}return t.abrupt("return",this.parseFromString(e));case 2:return t.abrupt("return",this.load(e));case 3:case"end":return t.stop()}}),t,this)})));function e(e){return t.apply(this,arguments)}return e}()},{key:"parseFromString",value:function(t){var e=new this.DOMParser;try{return this.checkDocument(e.parseFromString(t,"image/svg+xml"))}catch(r){return this.checkDocument(e.parseFromString(t,"text/xml"))}}},{key:"checkDocument",value:function(t){var e=t.getElementsByTagName("parsererror")[0];if(e)throw new Error(e.textContent);return t}},{key:"load",value:function(){var t=s()(o.a.mark((function t(e){var r,n;return o.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.next=2,this.fetch(e);case 2:return r=t.sent,t.next=5,r.text();case 5:return n=t.sent,t.abrupt("return",this.parseFromString(n));case 7:case"end":return t.stop()}}),t,this)})));function e(e){return t.apply(this,arguments)}return e}()}]),t}(),vt=function(){function t(e,r){h()(this,t),this.type="translate",this.point=null,this.point=ct.parse(r)}return y()(t,[{key:"apply",value:function(t){var e=this.point,r=e.x,n=e.y;t.translate(r||0,n||0)}},{key:"unapply",value:function(t){var e=this.point,r=e.x,n=e.y;t.translate(-1*r||0,-1*n||0)}},{key:"applyToPoint",value:function(t){var e=this.point,r=e.x,n=e.y;t.applyTransform([1,0,0,1,r||0,n||0])}}]),t}(),mt=function(){function t(e,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[];h()(this,t),this.type="rotate",this.angle=null,this.cx=0,this.cy=0;var i=L(r);this.angle=new ut(e,"angle",i[0]),this.cx=(i[1]||0)+(n[0]||0),this.cy=(i[2]||0)+(n[1]||0)}return y()(t,[{key:"apply",value:function(t){var e=this.cx,r=this.cy,n=this.angle;t.translate(e,r),t.rotate(n.getRadians()),t.translate(-e,-r)}},{key:"unapply",value:function(t){var e=this.cx,r=this.cy,n=this.angle;t.translate(e,r),t.rotate(-1*n.getRadians()),t.translate(-e,-r)}},{key:"applyToPoint",value:function(t){var e=this.cx,r=this.cy,n=this.angle,i=n.getRadians();t.applyTransform([1,0,0,1,e||0,r||0]),t.applyTransform([Math.cos(i),Math.sin(i),-Math.sin(i),Math.cos(i),0,0]),t.applyTransform([1,0,0,1,-e||0,-r||0])}}]),t}(),xt=function(){function t(e,r){h()(this,t),this.type="scale",this.scale=null;var n=ct.parseScale(r);0!==n.x&&0!==n.y||(n.x=U,n.y=U),this.scale=n}return y()(t,[{key:"apply",value:function(t){var e=this.scale,r=e.x,n=e.y;t.scale(r,n||r)}},{key:"unapply",value:function(t){var e=this.scale,r=e.x,n=e.y;t.scale(1/r,1/n||r)}},{key:"applyToPoint",value:function(t){var e=this.scale,r=e.x,n=e.y;t.applyTransform([r||0,0,0,n||0,0,0])}}]),t}(),bt=function(){function t(e,r){h()(this,t),this.type="matrix",this.matrix=[],this.matrix=L(r)}return y()(t,[{key:"apply",value:function(t){var e=this.matrix;t.transform(e[0],e[1],e[2],e[3],e[4],e[5])}},{key:"unapply",value:function(t){var e=this.matrix,r=e[0],n=e[2],i=e[4],a=e[1],o=e[3],u=e[5],s=0,c=0,l=1,f=1/(r*(o*l-u*c)-n*(a*l-u*s)+i*(a*c-o*s));t.transform(f*(o*l-u*c),f*(u*s-a*l),f*(i*c-n*l),f*(r*l-i*s),f*(n*u-i*o),f*(i*a-r*u))}},{key:"applyToPoint",value:function(t){t.applyTransform(this.matrix)}}]),t}();function kt(t){return function(){var e,r=w()(t);if(wt()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function wt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var St=function(t){P()(r,t);var e=kt(r);function r(t,n){var i;return h()(this,r),i=e.call(this,t,n),i.type="skew",i.angle=null,i.angle=new ut(t,"angle",n),i}return r}(bt);function Pt(t){return function(){var e,r=w()(t);if(Rt()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Rt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var At=function(t){P()(r,t);var e=Pt(r);function r(t,n){var i;return h()(this,r),i=e.call(this,t,n),i.type="skewX",i.matrix=[1,0,Math.tan(i.angle.getRadians()),1,0,0],i}return r}(St);function Ct(t){return function(){var e,r=w()(t);if(Mt()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Mt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Et=function(t){P()(r,t);var e=Ct(r);function r(t,n){var i;return h()(this,r),i=e.call(this,t,n),i.type="skewY",i.matrix=[1,Math.tan(i.angle.getRadians()),0,1,0,0],i}return r}(St);function Vt(t){return T(t).trim().replace(/\)([a-zA-Z])/g,") $1").replace(/\)(\s?,\s?)/g,") ").split(/\s(?=[a-z])/)}function Dt(t){var e=t.split("("),r=i()(e,2),n=r[0],a=r[1];return[n.trim(),a.trim().replace(")","")]}var Tt=function(){function t(e,r,n){var a=this;h()(this,t),this.document=e,this.transforms=[];var o=Vt(r),u=n?L(n):[];o.forEach((function(e){if("none"!==e){var r=Dt(e),n=i()(r,2),o=n[0],s=n[1],c=t.transformTypes[o];"undefined"!==typeof c&&a.transforms.push(new c(a.document,s,u))}}))}return y()(t,[{key:"apply",value:function(t){for(var e=this.transforms,r=e.length,n=0;n<r;n++)e[n].apply(t)}},{key:"unapply",value:function(t){for(var e=this.transforms,r=e.length,n=r-1;n>=0;n--)e[n].unapply(t)}},{key:"applyToPoint",value:function(t){for(var e=this.transforms,r=e.length,n=0;n<r;n++)e[n].applyToPoint(t)}}],[{key:"fromElement",value:function(e,r){var n=r.getStyle("transform",!1,!0),i=r.getStyle("transform-origin",!1,!0);return n.hasValue()?new t(e,n.getString(),i.getString()):null}}]),t}();Tt.transformTypes={translate:vt,rotate:mt,scale:xt,matrix:bt,skewX:At,skewY:Et};var Ot=function(){function t(e,r){var n=this,a=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(h()(this,t),this.document=e,this.node=r,this.captureTextNodes=a,this.attributes={},this.styles={},this.stylesSpecificity={},this.animationFrozen=!1,this.animationFrozenValue="",this.parent=null,this.children=[],r&&1===r.nodeType){if(Array.from(r.attributes).forEach((function(t){var r=B(t.nodeName);n.attributes[r]=new ut(e,r,t.value)})),this.addStylesFromStyleDefinition(),this.getAttribute("style").hasValue()){var o=this.getAttribute("style").getString().split(";").map((function(t){return t.trim()}));o.forEach((function(t){if(t){var r=t.split(":").map((function(t){return t.trim()})),a=i()(r,2),o=a[0],u=a[1];n.styles[o]=new ut(e,o,u)}}))}var u=e.definitions,s=this.getAttribute("id");s.hasValue()&&(u[s.getValue()]||(u[s.getValue()]=this)),Array.from(r.childNodes).forEach((function(t){if(1===t.nodeType)n.addChild(t);else if(a&&(3===t.nodeType||4===t.nodeType)){var r=e.createTextNode(t);r.getText().length>0&&n.addChild(r)}}))}}return y()(t,[{key:"getAttribute",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=this.attributes[t];if(!r&&e){var n=new ut(this.document,t,"");return this.attributes[t]=n,n}return r||ut.empty(this.document)}},{key:"getHrefAttribute",value:function(){for(var t in this.attributes)if("href"===t||/:href$/.test(t))return this.attributes[t];return ut.empty(this.document)}},{key:"getStyle",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=this.styles[t];if(n)return n;var i=this.getAttribute(t);if(i&&i.hasValue())return this.styles[t]=i,i;if(!r){var a=this.parent;if(a){var o=a.getStyle(t);if(o&&o.hasValue())return o}}if(e){var u=new ut(this.document,t,"");return this.styles[t]=u,u}return n||ut.empty(this.document)}},{key:"render",value:function(t){if("none"!==this.getStyle("display").getString()&&"hidden"!==this.getStyle("visibility").getString()){if(t.save(),this.getStyle("mask").hasValue()){var e=this.getStyle("mask").getDefinition();e&&(this.applyEffects(t),e.apply(t,this))}else if("none"!==this.getStyle("filter").getValue("none")){var r=this.getStyle("filter").getDefinition();r&&(this.applyEffects(t),r.apply(t,this))}else this.setContext(t),this.renderChildren(t),this.clearContext(t);t.restore()}}},{key:"setContext",value:function(t){}},{key:"applyEffects",value:function(t){var e=Tt.fromElement(this.document,this);e&&e.apply(t);var r=this.getStyle("clip-path",!1,!0);if(r.hasValue()){var n=r.getDefinition();n&&n.apply(t)}}},{key:"clearContext",value:function(t){}},{key:"renderChildren",value:function(t){this.children.forEach((function(e){e.render(t)}))}},{key:"addChild",value:function(e){var r=e instanceof t?e:this.document.createElement(e);r.parent=this,t.ignoreChildTypes.includes(r.type)||this.children.push(r)}},{key:"matchesSelector",value:function(t){var e=this.node;if("function"===typeof e.matches)return e.matches(t);var r=e.getAttribute("class");return!(!r||""===r)&&r.split(" ").some((function(e){if(".".concat(e)===t)return!0}))}},{key:"addStylesFromStyleDefinition",value:function(){var t=this.document,e=t.styles,r=t.stylesSpecificity;for(var n in e)if("@"!==n[0]&&this.matchesSelector(n)){var i=e[n],a=r[n];if(i)for(var o in i){var u=this.stylesSpecificity[o];"undefined"===typeof u&&(u="000"),a>=u&&(this.styles[o]=i[o],this.stylesSpecificity[o]=a)}}}},{key:"removeStyles",value:function(t,e){var r=e.reduce((function(e,r){var n=t.getStyle(r);if(!n.hasValue())return e;var i=n.getString();return n.setValue(""),[].concat(A()(e),[[r,i]])}),[]);return r}},{key:"restoreStyles",value:function(t,e){e.forEach((function(e){var r=i()(e,2),n=r[0],a=r[1];t.getStyle(n,!0).setValue(a)}))}}]),t}();function Nt(t){return function(){var e,r=w()(t);if(Lt()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Lt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}Ot.ignoreChildTypes=["title"];var zt=function(t){P()(r,t);var e=Nt(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,i),a}return r}(Ot);function Bt(t){var e=t.trim();return/^('|")/.test(e)?e:'"'.concat(e,'"')}function It(e){return"undefined"===typeof t?e:e.trim().split(",").map(Bt).join(",")}function Ft(t){if(!t)return"";var e=t.trim().toLowerCase();switch(e){case"normal":case"italic":case"oblique":case"inherit":case"initial":case"unset":return e;default:return/^oblique\s+(-|)\d+deg$/.test(e)?e:""}}function jt(t){if(!t)return"";var e=t.trim().toLowerCase();switch(e){case"normal":case"bold":case"lighter":case"bolder":case"inherit":case"initial":case"unset":return e;default:return/^[\d.]+$/.test(e)?e:""}}var _t=function(){function t(e,r,n,i,a,o){h()(this,t);var u=o?"string"===typeof o?t.parse(o):o:{};this.fontFamily=a||u.fontFamily,this.fontSize=i||u.fontSize,this.fontStyle=e||u.fontStyle,this.fontWeight=n||u.fontWeight,this.fontVariant=r||u.fontVariant}return y()(t,[{key:"toString",value:function(){return[Ft(this.fontStyle),this.fontVariant,jt(this.fontWeight),this.fontSize,It(this.fontFamily)].join(" ").trim()}}],[{key:"parse",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",r=arguments.length>1?arguments[1]:void 0,n="",a="",o="",u="",s="",c=T(e).trim().split(" "),l={fontSize:!1,fontStyle:!1,fontWeight:!1,fontVariant:!1};return c.forEach((function(e){switch(!0){case!l.fontStyle&&t.styles.includes(e):"inherit"!==e&&(n=e),l.fontStyle=!0;break;case!l.fontVariant&&t.variants.includes(e):"inherit"!==e&&(a=e),l.fontStyle=!0,l.fontVariant=!0;break;case!l.fontWeight&&t.weights.includes(e):"inherit"!==e&&(o=e),l.fontStyle=!0,l.fontVariant=!0,l.fontWeight=!0;break;case!l.fontSize:if("inherit"!==e){var r=e.split("/"),c=i()(r,1);u=c[0]}l.fontStyle=!0,l.fontVariant=!0,l.fontWeight=!0,l.fontSize=!0;break;default:"inherit"!==e&&(s+=e)}})),new t(n,a,o,u,s,r)}}]),t}();_t.styles="normal|italic|oblique|inherit",_t.variants="normal|small-caps|inherit",_t.weights="normal|bold|bolder|lighter|100|200|300|400|500|600|700|800|900|inherit";var $t=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Number.NaN,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.NaN,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Number.NaN,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:Number.NaN;h()(this,t),this.x1=e,this.y1=r,this.x2=n,this.y2=i,this.addPoint(e,r),this.addPoint(n,i)}return y()(t,[{key:"addPoint",value:function(t,e){"undefined"!==typeof t&&((isNaN(this.x1)||isNaN(this.x2))&&(this.x1=t,this.x2=t),t<this.x1&&(this.x1=t),t>this.x2&&(this.x2=t)),"undefined"!==typeof e&&((isNaN(this.y1)||isNaN(this.y2))&&(this.y1=e,this.y2=e),e<this.y1&&(this.y1=e),e>this.y2&&(this.y2=e))}},{key:"addX",value:function(t){this.addPoint(t,null)}},{key:"addY",value:function(t){this.addPoint(null,t)}},{key:"addBoundingBox",value:function(t){if(t){var e=t.x1,r=t.y1,n=t.x2,i=t.y2;this.addPoint(e,r),this.addPoint(n,i)}}},{key:"sumCubic",value:function(t,e,r,n,i){return Math.pow(1-t,3)*e+3*Math.pow(1-t,2)*t*r+3*(1-t)*Math.pow(t,2)*n+Math.pow(t,3)*i}},{key:"bezierCurveAdd",value:function(t,e,r,n,i){var a=6*e-12*r+6*n,o=-3*e+9*r-9*n+3*i,u=3*r-3*e;if(0!==o){var s=Math.pow(a,2)-4*u*o;if(!(s<0)){var c=(-a+Math.sqrt(s))/(2*o);0<c&&c<1&&(t?this.addX(this.sumCubic(c,e,r,n,i)):this.addY(this.sumCubic(c,e,r,n,i)));var l=(-a-Math.sqrt(s))/(2*o);0<l&&l<1&&(t?this.addX(this.sumCubic(l,e,r,n,i)):this.addY(this.sumCubic(l,e,r,n,i)))}}else{if(0===a)return;var f=-u/a;0<f&&f<1&&(t?this.addX(this.sumCubic(f,e,r,n,i)):this.addY(this.sumCubic(f,e,r,n,i)))}}},{key:"addBezierCurve",value:function(t,e,r,n,i,a,o,u){this.addPoint(t,e),this.addPoint(o,u),this.bezierCurveAdd(!0,t,r,i,o),this.bezierCurveAdd(!1,e,n,a,u)}},{key:"addQuadraticCurve",value:function(t,e,r,n,i,a){var o=t+2/3*(r-t),u=e+2/3*(n-e),s=o+1/3*(i-t),c=u+1/3*(a-e);this.addBezierCurve(t,e,o,s,u,c,i,a)}},{key:"isPointInBox",value:function(t,e){var r=this.x1,n=this.y1,i=this.x2,a=this.y2;return r<=t&&t<=i&&n<=e&&e<=a}},{key:"x",get:function(){return this.x1}},{key:"y",get:function(){return this.y1}},{key:"width",get:function(){return this.x2-this.x1}},{key:"height",get:function(){return this.y2-this.y1}}]),t}();function qt(t){return function(){var e,r=w()(t);if(Gt()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Gt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Ht=function(t){P()(r,t);var e=qt(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.modifiedEmSizeStack=!1,t}return y()(r,[{key:"calculateOpacity",value:function(){var t=1,e=this;while(e){var r=e.getStyle("opacity",!1,!0);r.hasValue()&&(t*=r.getNumber()),e=e.parent}return t}},{key:"setContext",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!e){var r=this.getStyle("fill"),n=this.getStyle("fill-opacity"),i=this.getStyle("stroke"),a=this.getStyle("stroke-opacity");if(r.isUrlDefinition()){var o=r.getFillStyleDefinition(this,n);o&&(t.fillStyle=o)}else if(r.hasValue()){"currentColor"===r.getString()&&r.setValue(this.getStyle("color").getColor());var u=r.getColor();"inherit"!==u&&(t.fillStyle="none"===u?"rgba(0,0,0,0)":u)}if(n.hasValue()){var s=new ut(this.document,"fill",t.fillStyle).addOpacity(n).getColor();t.fillStyle=s}if(i.isUrlDefinition()){var c=i.getFillStyleDefinition(this,a);c&&(t.strokeStyle=c)}else if(i.hasValue()){"currentColor"===i.getString()&&i.setValue(this.getStyle("color").getColor());var l=i.getString();"inherit"!==l&&(t.strokeStyle="none"===l?"rgba(0,0,0,0)":l)}if(a.hasValue()){var f=new ut(this.document,"stroke",t.strokeStyle).addOpacity(a).getString();t.strokeStyle=f}var h=this.getStyle("stroke-width");if(h.hasValue()){var g=h.getPixels();t.lineWidth=g||U}var y=this.getStyle("stroke-linecap"),p=this.getStyle("stroke-linejoin"),d=this.getStyle("stroke-miterlimit"),v=this.getStyle("paint-order"),m=this.getStyle("stroke-dasharray"),x=this.getStyle("stroke-dashoffset");if(y.hasValue()&&(t.lineCap=y.getString()),p.hasValue()&&(t.lineJoin=p.getString()),d.hasValue()&&(t.miterLimit=d.getNumber()),v.hasValue()&&(t.paintOrder=v.getValue()),m.hasValue()&&"none"!==m.getString()){var b=L(m.getString());"undefined"!==typeof t.setLineDash?t.setLineDash(b):"undefined"!==typeof t.webkitLineDash?t.webkitLineDash=b:"undefined"===typeof t.mozDash||1===b.length&&0===b[0]||(t.mozDash=b);var k=x.getPixels();"undefined"!==typeof t.lineDashOffset?t.lineDashOffset=k:"undefined"!==typeof t.webkitLineDashOffset?t.webkitLineDashOffset=k:"undefined"!==typeof t.mozDashOffset&&(t.mozDashOffset=k)}}if(this.modifiedEmSizeStack=!1,"undefined"!==typeof t.font){var w=this.getStyle("font"),S=this.getStyle("font-style"),P=this.getStyle("font-variant"),R=this.getStyle("font-weight"),A=this.getStyle("font-size"),C=this.getStyle("font-family"),M=new _t(S.getString(),P.getString(),R.getString(),A.hasValue()?"".concat(A.getPixels(!0),"px"):"",C.getString(),_t.parse(w.getString(),t.font));S.setValue(M.fontStyle),P.setValue(M.fontVariant),R.setValue(M.fontWeight),A.setValue(M.fontSize),C.setValue(M.fontFamily),t.font=M.toString(),A.isPixels()&&(this.document.emSize=A.getPixels(),this.modifiedEmSizeStack=!0)}e||(this.applyEffects(t),t.globalAlpha=this.calculateOpacity())}},{key:"clearContext",value:function(t){M()(w()(r.prototype),"clearContext",this).call(this,t),this.modifiedEmSizeStack&&this.document.popEmSize()}}]),r}(Ot);function Xt(t){return function(){var e,r=w()(t);if(Wt()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Wt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Yt=function(t){P()(r,t);var e=Xt(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,(this instanceof r?this.constructor:void 0)===r||i),a.type="text",a.x=0,a.y=0,a.measureCache=-1,a}return y()(r,[{key:"setContext",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];M()(w()(r.prototype),"setContext",this).call(this,t,e);var n=this.getStyle("dominant-baseline").getTextBaseline()||this.getStyle("alignment-baseline").getTextBaseline();n&&(t.textBaseline=n)}},{key:"initializeCoordinates",value:function(t){this.x=this.getAttribute("x").getPixels("x"),this.y=this.getAttribute("y").getPixels("y");var e=this.getAttribute("dx"),r=this.getAttribute("dy");e.hasValue()&&(this.x+=e.getPixels("x")),r.hasValue()&&(this.y+=r.getPixels("y")),this.x+=this.getAnchorDelta(t,this,0)}},{key:"getBoundingBox",value:function(t){var e=this;if("text"!==this.type)return this.getTElementBoundingBox(t);this.initializeCoordinates(t);var r=null;return this.children.forEach((function(n,i){var a=e.getChildBoundingBox(t,e,e,i);r?r.addBoundingBox(a):r=a})),r}},{key:"getFontSize",value:function(){var t=this.document,e=this.parent,r=_t.parse(t.ctx.font).fontSize,n=e.getStyle("font-size").getNumber(r);return n}},{key:"getTElementBoundingBox",value:function(t){var e=this.getFontSize();return new $t(this.x,this.y-e,this.x+this.measureText(t),this.y)}},{key:"getGlyph",value:function(t,e,r){var n=e[r],i=null;if(t.isArabic){var a=e.length,o=e[r-1],u=e[r+1],s="isolated";(0===r||" "===o)&&r<a-2&&" "!==u&&(s="terminal"),r>0&&" "!==o&&r<a-2&&" "!==u&&(s="medial"),r>0&&" "!==o&&(r===a-1||" "===u)&&(s="initial"),"undefined"!==typeof t.glyphs[n]&&(i=t.glyphs[n][s],i||"glyph"!==t.glyphs[n].type||(i=t.glyphs[n]))}else i=t.glyphs[n];return i||(i=t.missingGlyph),i}},{key:"getText",value:function(){return""}},{key:"getTextFromNode",value:function(t){var e=t||this.node,r=Array.from(e.parentNode.childNodes),n=r.indexOf(e),i=r.length-1,a=T(e.value||e.text||e.textContent||"");return 0===n&&(a=O(a)),n===i&&(a=N(a)),a}},{key:"renderChildren",value:function(t){var e=this;if("text"===this.type){this.initializeCoordinates(t),this.children.forEach((function(r,n){e.renderChild(t,e,e,n)}));var r=this.document.screen.mouse;r.isWorking()&&r.checkBoundingBox(this,this.getBoundingBox(t))}else this.renderTElementChildren(t)}},{key:"renderTElementChildren",value:function(t){var e=this.document,r=this.parent,n=this.getText(),i=r.getStyle("font-family").getDefinition();if(i)for(var a=i.fontFace.unitsPerEm,o=_t.parse(e.ctx.font),u=r.getStyle("font-size").getNumber(o.fontSize),s=r.getStyle("font-style").getString(o.fontStyle),c=u/a,l=i.isRTL?n.split("").reverse().join(""):n,f=L(r.getAttribute("dx").getString()),h=l.length,g=0;g<h;g++){var y=this.getGlyph(i,l,g);t.translate(this.x,this.y),t.scale(c,-c);var p=t.lineWidth;t.lineWidth=t.lineWidth*a/u,"italic"===s&&t.transform(1,0,.4,1,0,0),y.render(t),"italic"===s&&t.transform(1,0,-.4,1,0,0),t.lineWidth=p,t.scale(1/c,-1/c),t.translate(-this.x,-this.y),this.x+=u*(y.horizAdvX||i.horizAdvX)/a,"undefined"===typeof f[g]||isNaN(f[g])||(this.x+=f[g])}else{var d=this.x,v=this.y;"stroke"===t.paintOrder?(t.strokeStyle&&t.strokeText(n,d,v),t.fillStyle&&t.fillText(n,d,v)):(t.fillStyle&&t.fillText(n,d,v),t.strokeStyle&&t.strokeText(n,d,v))}}},{key:"getAnchorDelta",value:function(t,e,r){var n=this.getStyle("text-anchor").getString("start");if("start"!==n){for(var i=e.children,a=i.length,o=null,u=0,s=r;s<a;s++){if(o=i[s],s>r&&o.getAttribute("x").hasValue()||o.getAttribute("text-anchor").hasValue())break;u+=o.measureTextRecursive(t)}return-1*("end"===n?u:u/2)}return 0}},{key:"adjustChildCoordinates",value:function(t,e,r,n){var i=r.children[n];if("function"!==typeof i.measureText)return i;t.save(),i.setContext(t,!0);var a=i.getAttribute("x"),o=i.getAttribute("y"),u=i.getAttribute("dx"),s=i.getAttribute("dy"),c=i.getAttribute("text-anchor").getString("start");if(0===n&&"textNode"!==i.type&&(a.hasValue()||a.setValue(e.getAttribute("x").getValue("0")),o.hasValue()||o.setValue(e.getAttribute("y").getValue("0")),u.hasValue()||u.setValue(e.getAttribute("dx").getValue("0")),s.hasValue()||s.setValue(e.getAttribute("dy").getValue("0"))),a.hasValue()){if(i.x=a.getPixels("x")+e.getAnchorDelta(t,r,n),"start"!==c){var l=i.measureTextRecursive(t);i.x+=-1*("end"===c?l:l/2)}u.hasValue()&&(i.x+=u.getPixels("x"))}else{if("start"!==c){var f=i.measureTextRecursive(t);e.x+=-1*("end"===c?f:f/2)}u.hasValue()&&(e.x+=u.getPixels("x")),i.x=e.x}return e.x=i.x+i.measureText(t),o.hasValue()?(i.y=o.getPixels("y"),s.hasValue()&&(i.y+=s.getPixels("y"))):(s.hasValue()&&(e.y+=s.getPixels("y")),i.y=e.y),e.y=i.y,i.clearContext(t),t.restore(),i}},{key:"getChildBoundingBox",value:function(t,e,r,n){var i=this.adjustChildCoordinates(t,e,r,n),a=i.getBoundingBox(t);return a?(i.children.forEach((function(r,n){var o=e.getChildBoundingBox(t,e,i,n);a.addBoundingBox(o)})),a):null}},{key:"renderChild",value:function(t,e,r,n){var i=this.adjustChildCoordinates(t,e,r,n);i.render(t),i.children.forEach((function(r,n){e.renderChild(t,e,i,n)}))}},{key:"measureTextRecursive",value:function(t){var e=this.children.reduce((function(e,r){return e+r.measureTextRecursive(t)}),this.measureText(t));return e}},{key:"measureText",value:function(t){var e=this.measureCache;if(~e)return e;var r=this.getText(),n=this.measureTargetText(t,r);return this.measureCache=n,n}},{key:"measureTargetText",value:function(t,e){if(!e.length)return 0;var r=this.parent,n=r.getStyle("font-family").getDefinition();if(n){for(var i=this.getFontSize(),a=n.isRTL?e.split("").reverse().join(""):e,o=L(r.getAttribute("dx").getString()),u=a.length,s=0,c=0;c<u;c++){var l=this.getGlyph(n,a,c);s+=(l.horizAdvX||n.horizAdvX)*i/n.fontFace.unitsPerEm,"undefined"===typeof o[c]||isNaN(o[c])||(s+=o[c])}return s}if(!t.measureText)return 10*e.length;t.save(),this.setContext(t,!0);var f=t.measureText(e),h=f.width;return this.clearContext(t),t.restore(),h}}]),r}(Ht);function Ut(t){return function(){var e,r=w()(t);if(Qt()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Qt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Zt=function(t){P()(r,t);var e=Ut(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,(this instanceof r?this.constructor:void 0)===r||i),a.type="tspan",a.text=a.children.length>0?"":a.getTextFromNode(),a}return y()(r,[{key:"getText",value:function(){return this.text}}]),r}(Yt);function Jt(t){return function(){var e,r=w()(t);if(Kt()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Kt(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var te=function(t){P()(r,t);var e=Jt(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="textNode",t}return r}(Zt);function ee(t){var e=t.replace(/,/gm," ").replace(/([MmZzLlHhVvCcSsQqTtAa])([^\s])/gm,"$1 $2").replace(/([MmZzLlHhVvCcSsQqTtAa])([^\s])/gm,"$1 $2").replace(/([^\s])([MmZzLlHhVvCcSsQqTtAa])/gm,"$1 $2").replace(/([0-9])([+\-])/gm,"$1 $2").replace(/(\.[0-9]*)(\.)/gm,"$1 $2").replace(/(\.[0-9]*)(\.)/gm,"$1 $2").replace(/([Aa](?:\s+(?:[0-9]*\.)?[0-9]+){3})\s+([01])\s*([01])/gm,"$1 $2 $3 ");return T(e).trim()}var re=function(){function t(e){h()(this,t),this.control=null,this.start=null,this.current=null,this.command="",this.tokens=[],this.i=-1,this.previousCommand="",this.points=[],this.angles=[],this.tokens=ee(e).split(" ")}return y()(t,[{key:"reset",value:function(){this.i=-1,this.command="",this.previousCommand="",this.start=new ct(0,0),this.control=new ct(0,0),this.current=new ct(0,0),this.points=[],this.angles=[]}},{key:"isEnd",value:function(){var t=this.i,e=this.tokens;return t>=e.length-1}},{key:"isCommandOrEnd",value:function(){if(this.isEnd())return!0;var t=this.i,e=this.tokens;return/^[A-Za-z]$/.test(e[t+1])}},{key:"isRelativeCommand",value:function(){switch(this.command){case"m":case"l":case"h":case"v":case"c":case"s":case"q":case"t":case"a":case"z":return!0;default:return!1}}},{key:"getToken",value:function(){return this.i++,this.tokens[this.i]}},{key:"getScalar",value:function(){return parseFloat(this.getToken())}},{key:"nextCommand",value:function(){this.previousCommand=this.command,this.command=this.getToken()}},{key:"getPoint",value:function(){var t=new ct(this.getScalar(),this.getScalar());return this.makeAbsolute(t)}},{key:"getAsControlPoint",value:function(){var t=this.getPoint();return this.control=t,t}},{key:"getAsCurrentPoint",value:function(){var t=this.getPoint();return this.current=t,t}},{key:"getReflectedControlPoint",value:function(){var t=this.previousCommand.toLowerCase();if("c"!==t&&"s"!==t&&"q"!==t&&"t"!==t)return this.current;var e=this.current,r=e.x,n=e.y,i=this.control,a=i.x,o=i.y,u=new ct(2*r-a,2*n-o);return u}},{key:"makeAbsolute",value:function(t){if(this.isRelativeCommand()){var e=this.current,r=e.x,n=e.y;t.x+=r,t.y+=n}return t}},{key:"addMarker",value:function(t,e,r){var n=this.points,i=this.angles;r&&i.length>0&&!i[i.length-1]&&(i[i.length-1]=n[n.length-1].angleTo(r)),this.addMarkerAngle(t,e?e.angleTo(t):null)}},{key:"addMarkerAngle",value:function(t,e){this.points.push(t),this.angles.push(e)}},{key:"getMarkerPoints",value:function(){return this.points}},{key:"getMarkerAngles",value:function(){for(var t=this.angles,e=t.length,r=0;r<e;r++)if(!t[r])for(var n=r+1;n<e;n++)if(t[n]){t[r]=t[n];break}return t}}]),t}();function ne(t){return function(){var e,r=w()(t);if(ie()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function ie(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var ae=function(t){P()(r,t);var e=ne(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,i),a.type="path",a.pathParser=null,a.pathParser=new re(a.getAttribute("d").getString()),a}return y()(r,[{key:"path",value:function(t){var e=this.pathParser,r=new $t;e.reset(),t&&t.beginPath();while(!e.isEnd())switch(e.nextCommand(),e.command){case"M":case"m":this.pathM(t,r);break;case"L":case"l":this.pathL(t,r);break;case"H":case"h":this.pathH(t,r);break;case"V":case"v":this.pathV(t,r);break;case"C":case"c":this.pathC(t,r);break;case"S":case"s":this.pathS(t,r);break;case"Q":case"q":this.pathQ(t,r);break;case"T":case"t":this.pathT(t,r);break;case"A":case"a":this.pathA(t,r);break;case"Z":case"z":this.pathZ(t,r);break}return r}},{key:"getBoundingBox",value:function(t){return this.path()}},{key:"getMarkers",value:function(){var t=this.pathParser,e=t.getMarkerPoints(),r=t.getMarkerAngles(),n=e.map((function(t,e){return[t,r[e]]}));return n}},{key:"renderChildren",value:function(t){this.path(t),this.document.screen.mouse.checkPath(this,t);var e=this.getStyle("fill-rule");""!==t.fillStyle&&("inherit"!==e.getString("inherit")?t.fill(e.getString()):t.fill()),""!==t.strokeStyle&&t.stroke();var r=this.getMarkers();if(r){var n=r.length-1,a=this.getStyle("marker-start"),o=this.getStyle("marker-mid"),u=this.getStyle("marker-end");if(a.isUrlDefinition()){var s=a.getDefinition(),c=i()(r[0],2),l=c[0],f=c[1];s.render(t,l,f)}if(o.isUrlDefinition())for(var h=o.getDefinition(),g=1;g<n;g++){var y=i()(r[g],2),p=y[0],d=y[1];h.render(t,p,d)}if(u.isUrlDefinition()){var v=u.getDefinition(),m=i()(r[n],2),x=m[0],b=m[1];v.render(t,x,b)}}}},{key:"pathM",value:function(t,e){var r=this.pathParser,n=r.getAsCurrentPoint(),i=n.x,a=n.y;r.addMarker(n),e.addPoint(i,a),t&&t.moveTo(i,a),r.start=r.current;while(!r.isCommandOrEnd()){var o=r.getAsCurrentPoint(),u=o.x,s=o.y;r.addMarker(o,r.start),e.addPoint(u,s),t&&t.lineTo(u,s)}}},{key:"pathL",value:function(t,e){var r=this.pathParser;while(!r.isCommandOrEnd()){var n=r.current,i=r.getAsCurrentPoint(),a=i.x,o=i.y;r.addMarker(i,n),e.addPoint(a,o),t&&t.lineTo(a,o)}}},{key:"pathH",value:function(t,e){var r=this.pathParser;while(!r.isCommandOrEnd()){var n=r.current,i=new ct((r.isRelativeCommand()?n.x:0)+r.getScalar(),n.y);r.addMarker(i,n),r.current=i,e.addPoint(i.x,i.y),t&&t.lineTo(i.x,i.y)}}},{key:"pathV",value:function(t,e){var r=this.pathParser;while(!r.isCommandOrEnd()){var n=r.current,i=new ct(n.x,(r.isRelativeCommand()?n.y:0)+r.getScalar());r.addMarker(i,n),r.current=i,e.addPoint(i.x,i.y),t&&t.lineTo(i.x,i.y)}}},{key:"pathC",value:function(t,e){var r=this.pathParser;while(!r.isCommandOrEnd()){var n=r.current,i=r.getPoint(),a=r.getAsControlPoint(),o=r.getAsCurrentPoint();r.addMarker(o,a,i),e.addBezierCurve(n.x,n.y,i.x,i.y,a.x,a.y,o.x,o.y),t&&t.bezierCurveTo(i.x,i.y,a.x,a.y,o.x,o.y)}}},{key:"pathS",value:function(t,e){var r=this.pathParser;while(!r.isCommandOrEnd()){var n=r.current,i=r.getReflectedControlPoint(),a=r.getAsControlPoint(),o=r.getAsCurrentPoint();r.addMarker(o,a,i),e.addBezierCurve(n.x,n.y,i.x,i.y,a.x,a.y,o.x,o.y),t&&t.bezierCurveTo(i.x,i.y,a.x,a.y,o.x,o.y)}}},{key:"pathQ",value:function(t,e){var r=this.pathParser;while(!r.isCommandOrEnd()){var n=r.current,i=r.getAsControlPoint(),a=r.getAsCurrentPoint();r.addMarker(a,i,i),e.addQuadraticCurve(n.x,n.y,i.x,i.y,a.x,a.y),t&&t.quadraticCurveTo(i.x,i.y,a.x,a.y)}}},{key:"pathT",value:function(t,e){var r=this.pathParser;while(!r.isCommandOrEnd()){var n=r.current,i=r.getReflectedControlPoint();r.control=i;var a=r.getAsCurrentPoint();r.addMarker(a,i,i),e.addQuadraticCurve(n.x,n.y,i.x,i.y,a.x,a.y),t&&t.quadraticCurveTo(i.x,i.y,a.x,a.y)}}},{key:"pathA",value:function(t,e){var r=this.pathParser;while(!r.isCommandOrEnd()){var n=r.current,i=r.getScalar(),a=r.getScalar(),o=r.getScalar()*(Math.PI/180),u=r.getScalar(),s=r.getScalar(),c=r.getAsCurrentPoint(),l=new ct(Math.cos(o)*(n.x-c.x)/2+Math.sin(o)*(n.y-c.y)/2,-Math.sin(o)*(n.x-c.x)/2+Math.cos(o)*(n.y-c.y)/2),f=Math.pow(l.x,2)/Math.pow(i,2)+Math.pow(l.y,2)/Math.pow(a,2);f>1&&(i*=Math.sqrt(f),a*=Math.sqrt(f));var h=(u===s?-1:1)*Math.sqrt((Math.pow(i,2)*Math.pow(a,2)-Math.pow(i,2)*Math.pow(l.y,2)-Math.pow(a,2)*Math.pow(l.x,2))/(Math.pow(i,2)*Math.pow(l.y,2)+Math.pow(a,2)*Math.pow(l.x,2)));isNaN(h)&&(h=0);var g=new ct(h*i*l.y/a,h*-a*l.x/i),y=new ct((n.x+c.x)/2+Math.cos(o)*g.x-Math.sin(o)*g.y,(n.y+c.y)/2+Math.sin(o)*g.x+Math.cos(o)*g.y),p=J([1,0],[(l.x-g.x)/i,(l.y-g.y)/a]),d=[(l.x-g.x)/i,(l.y-g.y)/a],v=[(-l.x-g.x)/i,(-l.y-g.y)/a],m=J(d,v);Z(d,v)<=-1&&(m=Math.PI),Z(d,v)>=1&&(m=0);var x=1-s?1:-1,b=p+x*(m/2),k=new ct(y.x+i*Math.cos(b),y.y+a*Math.sin(b));if(r.addMarkerAngle(k,b-x*Math.PI/2),r.addMarkerAngle(c,b-x*Math.PI),e.addPoint(c.x,c.y),t&&!isNaN(p)&&!isNaN(m)){var w=i>a?i:a,S=i>a?1:i/a,P=i>a?a/i:1;t.translate(y.x,y.y),t.rotate(o),t.scale(S,P),t.arc(0,0,w,p,p+m,Boolean(1-s)),t.scale(1/S,1/P),t.rotate(-o),t.translate(-y.x,-y.y)}}}},{key:"pathZ",value:function(t,e){var r=this.pathParser;t&&e.x1!==e.x2&&e.y1!==e.y2&&t.closePath(),r.current=r.start}}]),r}(Ht);function oe(t){return function(){var e,r=w()(t);if(ue()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function ue(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var se=function(t){P()(r,t);var e=oe(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="svg",t.root=!1,t}return y()(r,[{key:"clearContext",value:function(t){M()(w()(r.prototype),"clearContext",this).call(this,t),this.document.screen.viewPort.removeCurrent()}},{key:"setContext",value:function(t){var e=this.document,n=e.screen,i=e.window,a=t.canvas;if(n.setDefaults(t),a.style&&"undefined"!==typeof t.font&&i&&"undefined"!==typeof i.getComputedStyle){t.font=i.getComputedStyle(a).getPropertyValue("font");var o=new ut(e,"fontSize",_t.parse(t.font).fontSize);o.hasValue()&&(e.rootEmSize=o.getPixels("y"),e.emSize=e.rootEmSize)}M()(w()(r.prototype),"setContext",this).call(this,t),this.getAttribute("x").hasValue()||this.getAttribute("x",!0).setValue(0),this.getAttribute("y").hasValue()||this.getAttribute("y",!0).setValue(0),t.translate(this.getAttribute("x").getPixels("x"),this.getAttribute("y").getPixels("y"));var u=n.viewPort,s=u.width,c=u.height;this.getStyle("width").hasValue()||this.getStyle("width",!0).setValue("100%"),this.getStyle("height").hasValue()||this.getStyle("height",!0).setValue("100%"),this.getStyle("color").hasValue()||this.getStyle("color",!0).setValue("black");var l=this.getAttribute("refX"),f=this.getAttribute("refY"),h=this.getAttribute("viewBox"),g=h.hasValue()?L(h.getString()):null,y=!this.root&&"visible"!==this.getAttribute("overflow").getValue("hidden"),p=0,d=0,v=0,m=0;g&&(p=g[0],d=g[1]),this.root||(s=this.getStyle("width").getPixels("x"),c=this.getStyle("height").getPixels("y"),"marker"===this.type&&(v=p,m=d,p=0,d=0)),n.viewPort.setCurrent(s,c),g&&(s=g[2],c=g[3]),e.setViewBox({ctx:t,aspectRatio:this.getAttribute("preserveAspectRatio").getString(),width:n.viewPort.width,desiredWidth:s,height:n.viewPort.height,desiredHeight:c,minX:p,minY:d,refX:l.getValue(),refY:f.getValue(),clip:y,clipX:v,clipY:m}),g&&(n.viewPort.removeCurrent(),n.viewPort.setCurrent(s,c))}},{key:"resize",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t,r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=this.getAttribute("width",!0),i=this.getAttribute("height",!0),a=this.getAttribute("viewBox"),o=this.getAttribute("style"),u=n.getNumber(0),s=i.getNumber(0);if(r)if("string"===typeof r)this.getAttribute("preserveAspectRatio",!0).setValue(r);else{var c=this.getAttribute("preserveAspectRatio");c.hasValue()&&c.setValue(c.getString().replace(/^\s*(\S.*\S)\s*$/,"$1"))}if(n.setValue(t),i.setValue(e),a.hasValue()||a.setValue("0 0 ".concat(u||t," ").concat(s||e)),o.hasValue()){var l=this.getStyle("width"),f=this.getStyle("height");l.hasValue()&&l.setValue("".concat(t,"px")),f.hasValue()&&f.setValue("".concat(e,"px"))}}}]),r}(Ht);function ce(t){return function(){var e,r=w()(t);if(le()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function le(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var fe=function(t){P()(r,t);var e=ce(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="rect",t}return y()(r,[{key:"path",value:function(t){var e=this.getAttribute("x").getPixels("x"),r=this.getAttribute("y").getPixels("y"),n=this.getStyle("width").getPixels("x"),i=this.getStyle("height").getPixels("y"),a=this.getAttribute("rx"),o=this.getAttribute("ry"),u=a.getPixels("x"),s=o.getPixels("y");if(a.hasValue()&&!o.hasValue()&&(s=u),o.hasValue()&&!a.hasValue()&&(u=s),u=Math.min(u,n/2),s=Math.min(s,i/2),t){var c=(Math.sqrt(2)-1)/3*4;t.beginPath(),i>0&&n>0&&(t.moveTo(e+u,r),t.lineTo(e+n-u,r),t.bezierCurveTo(e+n-u+c*u,r,e+n,r+s-c*s,e+n,r+s),t.lineTo(e+n,r+i-s),t.bezierCurveTo(e+n,r+i-s+c*s,e+n-u+c*u,r+i,e+n-u,r+i),t.lineTo(e+u,r+i),t.bezierCurveTo(e+u-c*u,r+i,e,r+i-s+c*s,e,r+i-s),t.lineTo(e,r+s),t.bezierCurveTo(e,r+s-c*s,e+u-c*u,r,e+u,r),t.closePath())}return new $t(e,r,e+n,r+i)}},{key:"getMarkers",value:function(){return null}}]),r}(ae);function he(t){return function(){var e,r=w()(t);if(ge()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function ge(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var ye=function(t){P()(r,t);var e=he(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="circle",t}return y()(r,[{key:"path",value:function(t){var e=this.getAttribute("cx").getPixels("x"),r=this.getAttribute("cy").getPixels("y"),n=this.getAttribute("r").getPixels();return t&&n>0&&(t.beginPath(),t.arc(e,r,n,0,2*Math.PI,!1),t.closePath()),new $t(e-n,r-n,e+n,r+n)}},{key:"getMarkers",value:function(){return null}}]),r}(ae);function pe(t){return function(){var e,r=w()(t);if(de()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function de(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var ve=function(t){P()(r,t);var e=pe(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="ellipse",t}return y()(r,[{key:"path",value:function(t){var e=(Math.sqrt(2)-1)/3*4,r=this.getAttribute("rx").getPixels("x"),n=this.getAttribute("ry").getPixels("y"),i=this.getAttribute("cx").getPixels("x"),a=this.getAttribute("cy").getPixels("y");return t&&r>0&&n>0&&(t.beginPath(),t.moveTo(i+r,a),t.bezierCurveTo(i+r,a+e*n,i+e*r,a+n,i,a+n),t.bezierCurveTo(i-e*r,a+n,i-r,a+e*n,i-r,a),t.bezierCurveTo(i-r,a-e*n,i-e*r,a-n,i,a-n),t.bezierCurveTo(i+e*r,a-n,i+r,a-e*n,i+r,a),t.closePath()),new $t(i-r,a-n,i+r,a+n)}},{key:"getMarkers",value:function(){return null}}]),r}(ae);function me(t){return function(){var e,r=w()(t);if(xe()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function xe(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var be=function(t){P()(r,t);var e=me(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="line",t}return y()(r,[{key:"getPoints",value:function(){return[new ct(this.getAttribute("x1").getPixels("x"),this.getAttribute("y1").getPixels("y")),new ct(this.getAttribute("x2").getPixels("x"),this.getAttribute("y2").getPixels("y"))]}},{key:"path",value:function(t){var e=this.getPoints(),r=i()(e,2),n=r[0],a=n.x,o=n.y,u=r[1],s=u.x,c=u.y;return t&&(t.beginPath(),t.moveTo(a,o),t.lineTo(s,c)),new $t(a,o,s,c)}},{key:"getMarkers",value:function(){var t=this.getPoints(),e=i()(t,2),r=e[0],n=e[1],a=r.angleTo(n);return[[r,a],[n,a]]}}]),r}(ae);function ke(t){return function(){var e,r=w()(t);if(we()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function we(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Se=function(t){P()(r,t);var e=ke(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,i),a.type="polyline",a.points=[],a.points=ct.parsePath(a.getAttribute("points").getString()),a}return y()(r,[{key:"path",value:function(t){var e=this.points,r=i()(e,1),n=r[0],a=n.x,o=n.y,u=new $t(a,o);return t&&(t.beginPath(),t.moveTo(a,o)),e.forEach((function(e){var r=e.x,n=e.y;u.addPoint(r,n),t&&t.lineTo(r,n)})),u}},{key:"getMarkers",value:function(){var t=this.points,e=t.length-1,r=[];return t.forEach((function(n,i){i!==e&&r.push([n,n.angleTo(t[i+1])])})),r.length>0&&r.push([t[t.length-1],r[r.length-1][1]]),r}}]),r}(ae);function Pe(t){return function(){var e,r=w()(t);if(Re()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Re(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Ae=function(t){P()(r,t);var e=Pe(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="polygon",t}return y()(r,[{key:"path",value:function(t){var e=M()(w()(r.prototype),"path",this).call(this,t),n=i()(this.points,1),a=n[0],o=a.x,u=a.y;return t&&(t.lineTo(o,u),t.closePath()),e}}]),r}(Se);function Ce(t){return function(){var e,r=w()(t);if(Me()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Me(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Ee=function(t){P()(r,t);var e=Ce(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="pattern",t}return y()(r,[{key:"createPattern",value:function(t,e,r){var n=this.getStyle("width").getPixels("x",!0),i=this.getStyle("height").getPixels("y",!0),a=new se(this.document,null);a.attributes.viewBox=new ut(this.document,"viewBox",this.getAttribute("viewBox").getValue()),a.attributes.width=new ut(this.document,"width","".concat(n,"px")),a.attributes.height=new ut(this.document,"height","".concat(i,"px")),a.attributes.transform=new ut(this.document,"transform",this.getAttribute("patternTransform").getValue()),a.children=this.children;var o=this.document.createCanvas(n,i),u=o.getContext("2d"),s=this.getAttribute("x"),c=this.getAttribute("y");s.hasValue()&&c.hasValue()&&u.translate(s.getPixels("x",!0),c.getPixels("y",!0)),r.hasValue()?this.styles["fill-opacity"]=r:Reflect.deleteProperty(this.styles,"fill-opacity");for(var l=-1;l<=1;l++)for(var f=-1;f<=1;f++)u.save(),a.attributes.x=new ut(this.document,"x",l*o.width),a.attributes.y=new ut(this.document,"y",f*o.height),a.render(u),u.restore();var h=t.createPattern(o,"repeat");return h}}]),r}(Ot);function Ve(t){return function(){var e,r=w()(t);if(De()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function De(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Te=function(t){P()(r,t);var e=Ve(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="marker",t}return y()(r,[{key:"render",value:function(t,e,r){if(e){var n=e.x,i=e.y,a=this.getAttribute("orient").getValue("auto"),o=this.getAttribute("markerUnits").getValue("strokeWidth");t.translate(n,i),"auto"===a&&t.rotate(r),"strokeWidth"===o&&t.scale(t.lineWidth,t.lineWidth),t.save();var u=new se(this.document,null);u.type=this.type,u.attributes.viewBox=new ut(this.document,"viewBox",this.getAttribute("viewBox").getValue()),u.attributes.refX=new ut(this.document,"refX",this.getAttribute("refX").getValue()),u.attributes.refY=new ut(this.document,"refY",this.getAttribute("refY").getValue()),u.attributes.width=new ut(this.document,"width",this.getAttribute("markerWidth").getValue()),u.attributes.height=new ut(this.document,"height",this.getAttribute("markerHeight").getValue()),u.attributes.overflow=new ut(this.document,"overflow",this.getAttribute("overflow").getValue()),u.attributes.fill=new ut(this.document,"fill",this.getAttribute("fill").getColor("black")),u.attributes.stroke=new ut(this.document,"stroke",this.getAttribute("stroke").getValue("none")),u.children=this.children,u.render(t),t.restore(),"strokeWidth"===o&&t.scale(1/t.lineWidth,1/t.lineWidth),"auto"===a&&t.rotate(-r),t.translate(-n,-i)}}}]),r}(Ot);function Oe(t){return function(){var e,r=w()(t);if(Ne()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Ne(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Le=function(t){P()(r,t);var e=Oe(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="defs",t}return y()(r,[{key:"render",value:function(){}}]),r}(Ot);function ze(t){return function(){var e,r=w()(t);if(Be()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Be(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Ie=function(t){P()(r,t);var e=ze(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="g",t}return y()(r,[{key:"getBoundingBox",value:function(t){var e=new $t;return this.children.forEach((function(r){e.addBoundingBox(r.getBoundingBox(t))})),e}}]),r}(Ht);function Fe(t){return function(){var e,r=w()(t);if(je()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function je(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var _e=function(t){P()(r,t);var e=Fe(r);function r(t,n,i){var a;h()(this,r),a=e.call(this,t,n,i),a.attributesToInherit=["gradientUnits"],a.stops=[];var o=V()(a),u=o.stops,s=o.children;return s.forEach((function(t){"stop"===t.type&&u.push(t)})),a}return y()(r,[{key:"getGradientUnits",value:function(){return this.getAttribute("gradientUnits").getString("objectBoundingBox")}},{key:"createGradient",value:function(t,e,r){var n=this,a=this;this.getHrefAttribute().hasValue()&&(a=this.getHrefAttribute().getDefinition(),this.inheritStopContainer(a));var o=a,u=o.stops,s=this.getGradient(t,e);if(!s)return this.addParentOpacity(r,u[u.length-1].color);if(u.forEach((function(t){s.addColorStop(t.offset,n.addParentOpacity(r,t.color))})),this.getAttribute("gradientTransform").hasValue()){var c=this.document,l=c.screen,f=l.MAX_VIRTUAL_PIXELS,h=l.viewPort,g=i()(h.viewPorts,1),y=g[0],p=new fe(c,null);p.attributes.x=new ut(c,"x",-f/3),p.attributes.y=new ut(c,"y",-f/3),p.attributes.width=new ut(c,"width",f),p.attributes.height=new ut(c,"height",f);var d=new Ie(c,null);d.attributes.transform=new ut(c,"transform",this.getAttribute("gradientTransform").getValue()),d.children=[p];var v=new se(c,null);v.attributes.x=new ut(c,"x",0),v.attributes.y=new ut(c,"y",0),v.attributes.width=new ut(c,"width",y.width),v.attributes.height=new ut(c,"height",y.height),v.children=[d];var m=c.createCanvas(y.width,y.height),x=m.getContext("2d");return x.fillStyle=s,v.render(x),x.createPattern(m,"no-repeat")}return s}},{key:"inheritStopContainer",value:function(t){var e=this;this.attributesToInherit.forEach((function(r){!e.getAttribute(r).hasValue()&&t.getAttribute(r).hasValue()&&e.getAttribute(r,!0).setValue(t.getAttribute(r).getValue())}))}},{key:"addParentOpacity",value:function(t,e){if(t.hasValue()){var r=new ut(this.document,"color",e);return r.addOpacity(t).getColor()}return e}}]),r}(Ot);function $e(t){return function(){var e,r=w()(t);if(qe()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function qe(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Ge=function(t){P()(r,t);var e=$e(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,i),a.type="linearGradient",a.attributesToInherit.push("x1","y1","x2","y2"),a}return y()(r,[{key:"getGradient",value:function(t,e){var r="objectBoundingBox"===this.getGradientUnits(),n=r?e.getBoundingBox(t):null;if(r&&!n)return null;this.getAttribute("x1").hasValue()||this.getAttribute("y1").hasValue()||this.getAttribute("x2").hasValue()||this.getAttribute("y2").hasValue()||(this.getAttribute("x1",!0).setValue(0),this.getAttribute("y1",!0).setValue(0),this.getAttribute("x2",!0).setValue(1),this.getAttribute("y2",!0).setValue(0));var i=r?n.x+n.width*this.getAttribute("x1").getNumber():this.getAttribute("x1").getPixels("x"),a=r?n.y+n.height*this.getAttribute("y1").getNumber():this.getAttribute("y1").getPixels("y"),o=r?n.x+n.width*this.getAttribute("x2").getNumber():this.getAttribute("x2").getPixels("x"),u=r?n.y+n.height*this.getAttribute("y2").getNumber():this.getAttribute("y2").getPixels("y");return i===o&&a===u?null:t.createLinearGradient(i,a,o,u)}}]),r}(_e);function He(t){return function(){var e,r=w()(t);if(Xe()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Xe(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var We=function(t){P()(r,t);var e=He(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,i),a.type="radialGradient",a.attributesToInherit.push("cx","cy","r","fx","fy","fr"),a}return y()(r,[{key:"getGradient",value:function(t,e){var r="objectBoundingBox"===this.getGradientUnits(),n=e.getBoundingBox(t);if(r&&!n)return null;this.getAttribute("cx").hasValue()||this.getAttribute("cx",!0).setValue("50%"),this.getAttribute("cy").hasValue()||this.getAttribute("cy",!0).setValue("50%"),this.getAttribute("r").hasValue()||this.getAttribute("r",!0).setValue("50%");var i=r?n.x+n.width*this.getAttribute("cx").getNumber():this.getAttribute("cx").getPixels("x"),a=r?n.y+n.height*this.getAttribute("cy").getNumber():this.getAttribute("cy").getPixels("y"),o=i,u=a;this.getAttribute("fx").hasValue()&&(o=r?n.x+n.width*this.getAttribute("fx").getNumber():this.getAttribute("fx").getPixels("x")),this.getAttribute("fy").hasValue()&&(u=r?n.y+n.height*this.getAttribute("fy").getNumber():this.getAttribute("fy").getPixels("y"));var s=r?(n.width+n.height)/2*this.getAttribute("r").getNumber():this.getAttribute("r").getPixels(),c=this.getAttribute("fr").getPixels();return t.createRadialGradient(o,u,c,i,a,s)}}]),r}(_e);function Ye(t){return function(){var e,r=w()(t);if(Ue()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Ue(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Qe=function(t){P()(r,t);var e=Ye(r);function r(t,n,i){var a;h()(this,r),a=e.call(this,t,n,i),a.type="stop";var o=Math.max(0,Math.min(1,a.getAttribute("offset").getNumber())),u=a.getStyle("stop-opacity"),s=a.getStyle("stop-color",!0);return""===s.getString()&&s.setValue("#000"),u.hasValue()&&(s=s.addOpacity(u)),a.offset=o,a.color=s.getColor(),a}return r}(Ot);function Ze(t){return function(){var e,r=w()(t);if(Je()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Je(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Ke=function(t){P()(r,t);var e=Ze(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,i),a.type="animate",a.duration=0,a.initialValue=null,a.initialUnits="",a.removed=!1,a.frozen=!1,t.screen.animations.push(V()(a)),a.begin=a.getAttribute("begin").getMilliseconds(),a.maxDuration=a.begin+a.getAttribute("dur").getMilliseconds(),a.from=a.getAttribute("from"),a.to=a.getAttribute("to"),a.values=a.getAttribute("values"),a.values.hasValue()&&a.values.setValue(a.values.getString().split(";")),a}return y()(r,[{key:"getProperty",value:function(){var t=this.getAttribute("attributeType").getString(),e=this.getAttribute("attributeName").getString();return"CSS"===t?this.parent.getStyle(e,!0):this.parent.getAttribute(e,!0)}},{key:"calcValue",value:function(){var t=this.initialUnits,e=this.getProgress(),r=e.progress,n=e.from,i=e.to,a=n.getNumber()+(i.getNumber()-n.getNumber())*r;return"%"===t&&(a*=100),"".concat(a).concat(t)}},{key:"update",value:function(t){var e=this.parent,r=this.getProperty();if(this.initialValue||(this.initialValue=r.getString(),this.initialUnits=r.getUnits()),this.duration>this.maxDuration){var n=this.getAttribute("fill").getString("remove");if("indefinite"===this.getAttribute("repeatCount").getString()||"indefinite"===this.getAttribute("repeatDur").getString())this.duration=0;else if("freeze"!==n||this.frozen){if("remove"===n&&!this.removed)return this.removed=!0,r.setValue(e.animationFrozen?e.animationFrozenValue:this.initialValue),!0}else this.frozen=!0,e.animationFrozen=!0,e.animationFrozenValue=r.getString();return!1}this.duration+=t;var i=!1;if(this.begin<this.duration){var a=this.calcValue(),o=this.getAttribute("type");if(o.hasValue()){var u=o.getString();a="".concat(u,"(").concat(a,")")}r.setValue(a),i=!0}return i}},{key:"getProgress",value:function(){var t=this.document,e=this.values,r={progress:(this.duration-this.begin)/(this.maxDuration-this.begin)};if(e.hasValue()){var n=r.progress*(e.getValue().length-1),i=Math.floor(n),a=Math.ceil(n);r.from=new ut(t,"from",parseFloat(e.getValue()[i])),r.to=new ut(t,"to",parseFloat(e.getValue()[a])),r.progress=(n-i)/(a-i)}else r.from=this.from,r.to=this.to;return r}}]),r}(Ot);function tr(t){return function(){var e,r=w()(t);if(er()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function er(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var rr=function(t){P()(r,t);var e=tr(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="animateColor",t}return y()(r,[{key:"calcValue",value:function(){var t=this.getProgress(),e=t.progress,r=t.from,n=t.to,i=new m.a(r.getColor()),a=new m.a(n.getColor());if(i.ok&&a.ok){var o=i.r+(a.r-i.r)*e,u=i.g+(a.g-i.g)*e,s=i.b+(a.b-i.b)*e;return"rgb(".concat(parseInt(o,10),", ").concat(parseInt(u,10),", ").concat(parseInt(s,10),")")}return this.getAttribute("from").getColor()}}]),r}(Ke);function nr(t){return function(){var e,r=w()(t);if(ir()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function ir(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var ar=function(t){P()(r,t);var e=nr(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="animateTransform",t}return y()(r,[{key:"calcValue",value:function(){var t=this.getProgress(),e=t.progress,r=t.from,n=t.to,i=L(r.getString()),a=L(n.getString()),o=i.map((function(t,r){var n=a[r];return t+(n-t)*e})).join(" ");return o}}]),r}(Ke);function or(t){if("undefined"===typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(t=ur(t))){var e=0,r=function(){};return{s:r,n:function(){return e>=t.length?{done:!0}:{done:!1,value:t[e++]}},e:function(t){throw t},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var n,i,a=!0,o=!1;return{s:function(){n=t[Symbol.iterator]()},n:function(){var t=n.next();return a=t.done,t},e:function(t){o=!0,i=t},f:function(){try{a||null==n.return||n.return()}finally{if(o)throw i}}}}function ur(t,e){if(t){if("string"===typeof t)return sr(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(r):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?sr(t,e):void 0}}function sr(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function cr(t){return function(){var e,r=w()(t);if(lr()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function lr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var fr=function(t){P()(r,t);var e=cr(r);function r(t,n,i){var a;h()(this,r),a=e.call(this,t,n,i),a.type="font",a.glyphs={},a.horizAdvX=a.getAttribute("horiz-adv-x").getNumber();var o,u=t.definitions,s=V()(a),c=s.children,l=or(c);try{for(l.s();!(o=l.n()).done;){var f=o.value;switch(f.type){case"font-face":a.fontFace=f;var g=f.getStyle("font-family");g.hasValue()&&(u[g.getString()]=V()(a));break;case"missing-glyph":a.missingGlyph=f;break;case"glyph":var y=f;y.arabicForm?(a.isRTL=!0,a.isArabic=!0,"undefined"===typeof a.glyphs[y.unicode]&&(a.glyphs[y.unicode]={}),a.glyphs[y.unicode][y.arabicForm]=y):a.glyphs[y.unicode]=y;break;default:}}}catch(p){l.e(p)}finally{l.f()}return a}return y()(r,[{key:"render",value:function(){}}]),r}(Ot);function hr(t){return function(){var e,r=w()(t);if(gr()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function gr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var yr=function(t){P()(r,t);var e=hr(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,i),a.type="font-face",a.ascent=a.getAttribute("ascent").getNumber(),a.descent=a.getAttribute("descent").getNumber(),a.unitsPerEm=a.getAttribute("units-per-em").getNumber(),a}return r}(Ot);function pr(t){return function(){var e,r=w()(t);if(dr()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function dr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var vr=function(t){P()(r,t);var e=pr(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="missing-glyph",t.horizAdvX=0,t}return r}(ae);function mr(t){return function(){var e,r=w()(t);if(xr()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function xr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var br=function(t){P()(r,t);var e=mr(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,i),a.type="glyph",a.horizAdvX=a.getAttribute("horiz-adv-x").getNumber(),a.unicode=a.getAttribute("unicode").getString(),a.arabicForm=a.getAttribute("arabic-form").getString(),a}return r}(ae);function kr(t){return function(){var e,r=w()(t);if(wr()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function wr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Sr=function(t){P()(r,t);var e=kr(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="tref",t}return y()(r,[{key:"getText",value:function(){var t=this.getHrefAttribute().getDefinition();if(t){var e=t.children[0];if(e)return e.getText()}return""}}]),r}(Yt);function Pr(t){return function(){var e,r=w()(t);if(Rr()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Rr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Ar=function(t){P()(r,t);var e=Pr(r);function r(t,n,i){var a;h()(this,r),a=e.call(this,t,n,i),a.type="a";var o=n.childNodes,u=o[0],s=o.length>0&&Array.from(o).every((function(t){return 3===t.nodeType}));return a.hasText=s,a.text=s?a.getTextFromNode(u):"",a}return y()(r,[{key:"getText",value:function(){return this.text}},{key:"renderChildren",value:function(t){if(this.hasText){M()(w()(r.prototype),"renderChildren",this).call(this,t);var e=this.document,n=this.x,i=this.y,a=e.screen.mouse,o=new ut(e,"fontSize",_t.parse(e.ctx.font).fontSize);a.isWorking()&&a.checkBoundingBox(this,new $t(n,i-o.getPixels("y"),n+this.measureText(t),i))}else if(this.children.length>0){var u=new Ie(this.document,null);u.children=this.children,u.parent=this,u.render(t)}}},{key:"onClick",value:function(){var t=this.document.window;t&&t.open(this.getHrefAttribute().getString())}},{key:"onMouseMove",value:function(){var t=this.document.ctx;t.canvas.style.cursor="pointer"}}]),r}(Yt);function Cr(t){if("undefined"===typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(t=Mr(t))){var e=0,r=function(){};return{s:r,n:function(){return e>=t.length?{done:!0}:{done:!1,value:t[e++]}},e:function(t){throw t},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var n,i,a=!0,o=!1;return{s:function(){n=t[Symbol.iterator]()},n:function(){var t=n.next();return a=t.done,t},e:function(t){o=!0,i=t},f:function(){try{a||null==n.return||n.return()}finally{if(o)throw i}}}}function Mr(t,e){if(t){if("string"===typeof t)return Er(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(r):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Er(t,e):void 0}}function Er(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}function Vr(t){return function(){var e,r=w()(t);if(Dr()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Dr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Tr=function(t){P()(r,t);var e=Vr(r);function r(t,n,i){var a;h()(this,r),a=e.call(this,t,n,i),a.type="textPath",a.textWidth=0,a.textHeight=0,a.pathLength=-1,a.glyphInfo=null,a.letterSpacingCache=[],a.measuresCache=new Map([["",0]]);var o=a.getHrefAttribute().getDefinition();return a.text=a.getTextFromNode(),a.dataArray=a.parsePathData(o),a}return y()(r,[{key:"getText",value:function(){return this.text}},{key:"path",value:function(t){var e=this.dataArray;t&&t.beginPath(),e.forEach((function(e){var r=e.command,n=e.points;switch(r){case"L":t&&t.lineTo(n[0],n[1]);break;case"M":t&&t.moveTo(n[0],n[1]);break;case"C":t&&t.bezierCurveTo(n[0],n[1],n[2],n[3],n[4],n[5]);break;case"Q":t&&t.quadraticCurveTo(n[0],n[1],n[2],n[3]);break;case"A":var i=n[0],a=n[1],o=n[2],u=n[3],s=n[4],c=n[5],l=n[6],f=n[7],h=o>u?o:u,g=o>u?1:o/u,y=o>u?u/o:1;t&&(t.translate(i,a),t.rotate(l),t.scale(g,y),t.arc(0,0,h,s,s+c,Boolean(1-f)),t.scale(1/g,1/y),t.rotate(-l),t.translate(-i,-a));break;case"z":t&&t.closePath();break}}))}},{key:"renderChildren",value:function(t){this.setTextData(t),t.save();var e=this.parent.getStyle("text-decoration").getString(),r=this.getFontSize(),n=this.glyphInfo,i=t.fillStyle;"underline"===e&&t.beginPath(),n.forEach((function(i,a){var o=i.p0,u=i.p1,s=i.text;t.save(),t.translate(o.x,o.y),t.rotate(n[a].rotation),t.fillStyle&&t.fillText(s,0,0),t.strokeStyle&&t.strokeText(s,0,0),t.restore(),"underline"===e&&(0===a&&t.moveTo(o.x,o.y+r/8),t.lineTo(u.x,u.y+r/5))})),"underline"===e&&(t.lineWidth=r/20,t.strokeStyle=i,t.stroke(),t.closePath()),t.restore()}},{key:"getLetterSpacingAt",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return this.letterSpacingCache[t]||0}},{key:"findSegmentToFitChar",value:function(t,e,r,n,i,a,o,u){var s=a,c=this.measureText(t,o);" "===o&&"justify"===e&&r<n&&(c+=(n-r)/i),u>-1&&(s+=this.getLetterSpacingAt(u));var l=this.textHeight/20,f={p0:this.getEquidistantPointOnPath(s,l),p1:this.getEquidistantPointOnPath(s+c,l)};return s+=c,{offset:s,segment:f}}},{key:"measureText",value:function(t,e){var r=this.measuresCache,n=e||this.getText();if(r.has(n))return r.get(n);var i=this.measureTargetText(t,n);return r.set(n,i),i}},{key:"setTextData",value:function(t){var e=this;if(!this.glyphInfo){var r=this.getText(),n=r.split(""),i=r.split(" ").length-1,a=L(this.parent.getAttribute("dx").getString("0")),o=this.parent.getStyle("text-anchor").getString("start"),u=this.getStyle("letter-spacing"),s=this.parent.getStyle("letter-spacing"),c=0;u.hasValue()&&"inherit"!==u.getValue()?u.hasValue()&&"initial"!==u.getValue()&&"unset"!==u.getValue()&&(c=u.getPixels()):c=s.getPixels();var l=[],f=r.length;this.letterSpacingCache=l;for(var h=0;h<f;h++)l.push("undefined"!==typeof a[h]?a[h]:c);var g=l.reduce((function(t,e){return t+e||0}),0);this.textWidth=this.measureText(t),this.textHeight=this.getFontSize();var y=Math.max(this.textWidth+g,0);this.glyphInfo=[];var p=this.getPathLength(),d=this.getStyle("startOffset").getNumber(0)*p,v=0;"middle"!==o&&"center"!==o||(v=-y/2),"end"!==o&&"right"!==o||(v=-y),v+=d,n.forEach((function(r,a){var u=e.findSegmentToFitChar(t,o,y,p,i,v,r,a),s=u.offset,c=u.segment;if(v=s,c.p0&&c.p1){var l=e.getLineLength(c.p0.x,c.p0.y,c.p1.x,c.p1.y),f=0,h=e.getPointOnLine(f+l/2,c.p0.x,c.p0.y,c.p1.x,c.p1.y),g=Math.atan2(c.p1.y-c.p0.y,c.p1.x-c.p0.x);e.glyphInfo.push({transposeX:h.x,transposeY:h.y,text:n[a],p0:c.p0,p1:c.p1,rotation:g})}}))}}},{key:"parsePathData",value:function(t){if(this.pathLength=-1,!t)return[];var e=[],r=t.pathParser;r.reset();while(!r.isEnd()){var n=r.current,i=n?n.x:0,a=n?n.y:0,o="",u=[];r.nextCommand();var s=r.command.toUpperCase();switch(r.command){case"M":case"m":o=this.pathM(r,u);break;case"L":case"l":o=this.pathL(r,u);break;case"H":case"h":o=this.pathH(r,u);break;case"V":case"v":o=this.pathV(r,u);break;case"C":case"c":this.pathC(r,u);break;case"S":case"s":o=this.pathS(r,u);break;case"Q":case"q":this.pathQ(r,u);break;case"T":case"t":o=this.pathT(r,u);break;case"A":case"a":u=this.pathA(r);break;case"Z":case"z":r.current=r.start;break}"Z"!==s?e.push({command:o||s,points:u,start:{x:i,y:a},pathLength:this.calcLength(i,a,o||s,u)}):e.push({command:"z",points:[],pathLength:0})}return e}},{key:"pathM",value:function(t,e){var r=t.getAsCurrentPoint();e.push(r.x,r.y),t.start=t.current;while(!t.isCommandOrEnd()){var n=t.getAsCurrentPoint();return e.push(n.x,n.y),"L"}}},{key:"pathL",value:function(t,e){while(!t.isCommandOrEnd()){var r=t.getAsCurrentPoint();e.push(r.x,r.y)}return"L"}},{key:"pathH",value:function(t,e){while(!t.isCommandOrEnd()){var r=t.current,n=new ct((t.isRelativeCommand()?r.x:0)+t.getScalar(),r.y);e.push(n.x,n.y),t.current=n}return"L"}},{key:"pathV",value:function(t,e){while(!t.isCommandOrEnd()){var r=t.current,n=new ct(r.x,(t.isRelativeCommand()?r.y:0)+t.getScalar());e.push(n.x,n.y),t.current=n}return"L"}},{key:"pathC",value:function(t,e){while(!t.isCommandOrEnd()){var r=t.getPoint(),n=t.getAsControlPoint(),i=t.getAsCurrentPoint();e.push(r.x,r.y,n.x,n.y,i.x,i.y)}}},{key:"pathS",value:function(t,e){while(!t.isCommandOrEnd()){var r=t.getReflectedControlPoint(),n=t.getAsControlPoint(),i=t.getAsCurrentPoint();e.push(r.x,r.y,n.x,n.y,i.x,i.y)}return"C"}},{key:"pathQ",value:function(t,e){while(!t.isCommandOrEnd()){var r=t.getAsControlPoint(),n=t.getAsCurrentPoint();e.push(r.x,r.y,n.x,n.y)}}},{key:"pathT",value:function(t,e){while(!t.isCommandOrEnd()){var r=t.getReflectedControlPoint();t.control=r;var n=t.getAsCurrentPoint();e.push(r.x,r.y,n.x,n.y)}return"Q"}},{key:"pathA",value:function(t){while(!t.isCommandOrEnd()){var e=t.current,r=t.getScalar(),n=t.getScalar(),i=t.getScalar()*(Math.PI/180),a=t.getScalar(),o=t.getScalar(),u=t.getAsCurrentPoint(),s=new ct(Math.cos(i)*(e.x-u.x)/2+Math.sin(i)*(e.y-u.y)/2,-Math.sin(i)*(e.x-u.x)/2+Math.cos(i)*(e.y-u.y)/2),c=Math.pow(s.x,2)/Math.pow(r,2)+Math.pow(s.y,2)/Math.pow(n,2);c>1&&(r*=Math.sqrt(c),n*=Math.sqrt(c));var l=(a===o?-1:1)*Math.sqrt((Math.pow(r,2)*Math.pow(n,2)-Math.pow(r,2)*Math.pow(s.y,2)-Math.pow(n,2)*Math.pow(s.x,2))/(Math.pow(r,2)*Math.pow(s.y,2)+Math.pow(n,2)*Math.pow(s.x,2)));isNaN(l)&&(l=0);var f=new ct(l*r*s.y/n,l*-n*s.x/r),h=new ct((e.x+u.x)/2+Math.cos(i)*f.x-Math.sin(i)*f.y,(e.y+u.y)/2+Math.sin(i)*f.x+Math.cos(i)*f.y),g=J([1,0],[(s.x-f.x)/r,(s.y-f.y)/n]),y=[(s.x-f.x)/r,(s.y-f.y)/n],p=[(-s.x-f.x)/r,(-s.y-f.y)/n],d=J(y,p);return Z(y,p)<=-1&&(d=Math.PI),Z(y,p)>=1&&(d=0),0===o&&d>0&&(d-=2*Math.PI),1===o&&d<0&&(d+=2*Math.PI),[h.x,h.y,r,n,g,d,i,o]}}},{key:"calcLength",value:function(t,e,r,n){var i=0,a=null,o=null,u=0;switch(r){case"L":return this.getLineLength(t,e,n[0],n[1]);case"C":for(i=0,a=this.getPointOnCubicBezier(0,t,e,n[0],n[1],n[2],n[3],n[4],n[5]),u=.01;u<=1;u+=.01)o=this.getPointOnCubicBezier(u,t,e,n[0],n[1],n[2],n[3],n[4],n[5]),i+=this.getLineLength(a.x,a.y,o.x,o.y),a=o;return i;case"Q":for(i=0,a=this.getPointOnQuadraticBezier(0,t,e,n[0],n[1],n[2],n[3]),u=.01;u<=1;u+=.01)o=this.getPointOnQuadraticBezier(u,t,e,n[0],n[1],n[2],n[3]),i+=this.getLineLength(a.x,a.y,o.x,o.y),a=o;return i;case"A":i=0;var s=n[4],c=n[5],l=n[4]+c,f=Math.PI/180;if(Math.abs(s-l)<f&&(f=Math.abs(s-l)),a=this.getPointOnEllipticalArc(n[0],n[1],n[2],n[3],s,0),c<0)for(u=s-f;u>l;u-=f)o=this.getPointOnEllipticalArc(n[0],n[1],n[2],n[3],u,0),i+=this.getLineLength(a.x,a.y,o.x,o.y),a=o;else for(u=s+f;u<l;u+=f)o=this.getPointOnEllipticalArc(n[0],n[1],n[2],n[3],u,0),i+=this.getLineLength(a.x,a.y,o.x,o.y),a=o;return o=this.getPointOnEllipticalArc(n[0],n[1],n[2],n[3],l,0),i+=this.getLineLength(a.x,a.y,o.x,o.y),i}return 0}},{key:"getPointOnLine",value:function(t,e,r,n,i){var a=arguments.length>5&&void 0!==arguments[5]?arguments[5]:e,o=arguments.length>6&&void 0!==arguments[6]?arguments[6]:r,u=(i-r)/(n-e+U),s=Math.sqrt(t*t/(1+u*u));n<e&&(s*=-1);var c=u*s,l=null;if(n===e)l={x:a,y:o+c};else if((o-r)/(a-e+U)===u)l={x:a+s,y:o+c};else{var f=0,h=0,g=this.getLineLength(e,r,n,i);if(g<U)return null;var y=(a-e)*(n-e)+(o-r)*(i-r);y/=g*g,f=e+y*(n-e),h=r+y*(i-r);var p=this.getLineLength(a,o,f,h),d=Math.sqrt(t*t-p*p);s=Math.sqrt(d*d/(1+u*u)),n<e&&(s*=-1),c=u*s,l={x:f+s,y:h+c}}return l}},{key:"getPointOnPath",value:function(t){var e=this.getPathLength(),r=0,n=null;if(t<-5e-5||t-5e-5>e)return null;var i,a=this.dataArray,o=Cr(a);try{for(o.s();!(i=o.n()).done;){var u=i.value;if(!u||!(u.pathLength<5e-5||r+u.pathLength+5e-5<t)){var s=t-r,c=0;switch(u.command){case"L":n=this.getPointOnLine(s,u.start.x,u.start.y,u.points[0],u.points[1],u.start.x,u.start.y);break;case"A":var l=u.points[4],f=u.points[5],h=u.points[4]+f;if(c=l+s/u.pathLength*f,f<0&&c<h||f>=0&&c>h)break;n=this.getPointOnEllipticalArc(u.points[0],u.points[1],u.points[2],u.points[3],c,u.points[6]);break;case"C":c=s/u.pathLength,c>1&&(c=1),n=this.getPointOnCubicBezier(c,u.start.x,u.start.y,u.points[0],u.points[1],u.points[2],u.points[3],u.points[4],u.points[5]);break;case"Q":c=s/u.pathLength,c>1&&(c=1),n=this.getPointOnQuadraticBezier(c,u.start.x,u.start.y,u.points[0],u.points[1],u.points[2],u.points[3]);break;default:}if(n)return n;break}r+=u.pathLength}}catch(g){o.e(g)}finally{o.f()}return null}},{key:"getLineLength",value:function(t,e,r,n){return Math.sqrt((r-t)*(r-t)+(n-e)*(n-e))}},{key:"getPathLength",value:function(){return-1===this.pathLength&&(this.pathLength=this.dataArray.reduce((function(t,e){return e.pathLength>0?t+e.pathLength:t}),0)),this.pathLength}},{key:"getPointOnCubicBezier",value:function(t,e,r,n,i,a,o,u,s){var c=u*K(t)+a*tt(t)+n*et(t)+e*rt(t),l=s*K(t)+o*tt(t)+i*et(t)+r*rt(t);return{x:c,y:l}}},{key:"getPointOnQuadraticBezier",value:function(t,e,r,n,i,a,o){var u=a*nt(t)+n*it(t)+e*at(t),s=o*nt(t)+i*it(t)+r*at(t);return{x:u,y:s}}},{key:"getPointOnEllipticalArc",value:function(t,e,r,n,i,a){var o=Math.cos(a),u=Math.sin(a),s={x:r*Math.cos(i),y:n*Math.sin(i)};return{x:t+(s.x*o-s.y*u),y:e+(s.x*u+s.y*o)}}},{key:"buildEquidistantCache",value:function(t,e){var r=this.getPathLength(),n=e||.25,i=t||r/100;if(!this.equidistantCache||this.equidistantCache.step!==i||this.equidistantCache.precision!==n){this.equidistantCache={step:i,precision:n,points:[]};for(var a=0,o=0;o<=r;o+=n){var u=this.getPointOnPath(o),s=this.getPointOnPath(o+n);u&&s&&(a+=this.getLineLength(u.x,u.y,s.x,s.y),a>=i&&(this.equidistantCache.points.push({x:u.x,y:u.y,distance:o}),a-=i))}}}},{key:"getEquidistantPointOnPath",value:function(t,e,r){if(this.buildEquidistantCache(e,r),t<0||t-this.getPathLength()>5e-5)return null;var n=Math.round(t/this.getPathLength()*(this.equidistantCache.points.length-1));return this.equidistantCache.points[n]||null}}]),r}(Yt);function Or(t){return function(){var e,r=w()(t);if(Nr()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Nr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Lr=function(t){P()(r,t);var e=Or(r);function r(t,n,i){var a;h()(this,r),a=e.call(this,t,n,i),a.type="image",a.loaded=!1;var o=a.getHrefAttribute().getString();if(!o)return b()(a);var u=/\.svg$/.test(o);return t.images.push(V()(a)),u?a.loadSvg(o):a.loadImage(o),a.isSvg=u,a}return y()(r,[{key:"loadImage",value:function(){var t=s()(o.a.mark((function t(e){var r;return o.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,this.document.createImage(e);case 3:r=t.sent,this.image=r,t.next=10;break;case 7:t.prev=7,t.t0=t["catch"](0),console.error('Error while loading image "'.concat(e,'":'),t.t0);case 10:this.loaded=!0;case 11:case"end":return t.stop()}}),t,this,[[0,7]])})));function e(e){return t.apply(this,arguments)}return e}()},{key:"loadSvg",value:function(){var t=s()(o.a.mark((function t(e){var r,n;return o.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,this.document.fetch(e);case 3:return r=t.sent,t.next=6,r.text();case 6:n=t.sent,this.image=n,t.next=13;break;case 10:t.prev=10,t.t0=t["catch"](0),console.error('Error while loading image "'.concat(e,'":'),t.t0);case 13:this.loaded=!0;case 14:case"end":return t.stop()}}),t,this,[[0,10]])})));function e(e){return t.apply(this,arguments)}return e}()},{key:"renderChildren",value:function(t){var e=this.document,r=this.image,n=this.loaded,i=this.getAttribute("x").getPixels("x"),a=this.getAttribute("y").getPixels("y"),o=this.getStyle("width").getPixels("x"),u=this.getStyle("height").getPixels("y");if(n&&r&&o&&u){if(t.save(),this.isSvg)e.canvg.forkString(t,this.image,{ignoreMouse:!0,ignoreAnimation:!0,ignoreDimensions:!0,ignoreClear:!0,offsetX:i,offsetY:a,scaleWidth:o,scaleHeight:u}).render();else{var s=this.image;t.translate(i,a),e.setViewBox({ctx:t,aspectRatio:this.getAttribute("preserveAspectRatio").getString(),width:o,desiredWidth:s.width,height:u,desiredHeight:s.height}),this.loaded&&("undefined"===typeof s.complete||s.complete)&&t.drawImage(s,0,0)}t.restore()}}},{key:"getBoundingBox",value:function(){var t=this.getAttribute("x").getPixels("x"),e=this.getAttribute("y").getPixels("y"),r=this.getStyle("width").getPixels("x"),n=this.getStyle("height").getPixels("y");return new $t(t,e,t+r,e+n)}}]),r}(Ht);function zr(t){return function(){var e,r=w()(t);if(Br()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Br(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Ir=function(t){P()(r,t);var e=zr(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="symbol",t}return y()(r,[{key:"render",value:function(t){}}]),r}(Ht),Fr=function(){function t(e){h()(this,t),this.document=e,this.loaded=!1,e.fonts.push(this)}return y()(t,[{key:"load",value:function(){var t=s()(o.a.mark((function t(e,r){var n,i,a;return o.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return t.prev=0,n=this.document,t.next=4,n.canvg.parser.load(r);case 4:i=t.sent,a=i.getElementsByTagName("font"),Array.from(a).forEach((function(t){var r=n.createElement(t);n.definitions[e]=r})),t.next=12;break;case 9:t.prev=9,t.t0=t["catch"](0),console.error('Error while loading font "'.concat(r,'":'),t.t0);case 12:this.loaded=!0;case 13:case"end":return t.stop()}}),t,this,[[0,9]])})));function e(e,r){return t.apply(this,arguments)}return e}()}]),t}();function jr(t){return function(){var e,r=w()(t);if(_r()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function _r(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var $r=function(t){P()(r,t);var e=jr(r);function r(t,n,i){var a;h()(this,r),a=e.call(this,t,n,i),a.type="style";var o=T(Array.from(n.childNodes).map((function(t){return t.data})).join("").replace(/(\/\*([^*]|[\r\n]|(\*+([^*\/]|[\r\n])))*\*+\/)|(^[\s]*\/\/.*)/gm,"").replace(/@import.*;/g,"")),u=o.split("}");return u.forEach((function(e){var r=e.trim();if(r){var n=r.split("{"),i=n[0].split(","),a=n[1].split(";");i.forEach((function(e){var r=e.trim();if(r){var n=t.styles[r]||{};if(a.forEach((function(e){var r=e.indexOf(":"),i=e.substr(0,r).trim(),a=e.substr(r+1,e.length-r).trim();i&&a&&(n[i]=new ut(t,i,a))})),t.styles[r]=n,t.stylesSpecificity[r]=Y(r),"@font-face"===r){var i=n["font-family"].getString().replace(/"|'/g,""),o=n.src.getString().split(",");o.forEach((function(e){if(e.indexOf('format("svg")')>0){var r=I(e);r&&new Fr(t).load(i,r)}}))}}}))}})),a}return r}(Ot);function qr(t){return function(){var e,r=w()(t);if(Gr()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Gr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}$r.parseExternalUrl=I;var Hr=function(t){P()(r,t);var e=qr(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="use",t}return y()(r,[{key:"setContext",value:function(t){M()(w()(r.prototype),"setContext",this).call(this,t);var e=this.getAttribute("x"),n=this.getAttribute("y");e.hasValue()&&t.translate(e.getPixels("x"),0),n.hasValue()&&t.translate(0,n.getPixels("y"))}},{key:"path",value:function(t){var e=this.element;e&&e.path(t)}},{key:"renderChildren",value:function(t){var e=this.document,r=this.element;if(r){var n=r;if("symbol"===r.type&&(n=new se(e,null),n.attributes.viewBox=new ut(e,"viewBox",r.getAttribute("viewBox").getString()),n.attributes.preserveAspectRatio=new ut(e,"preserveAspectRatio",r.getAttribute("preserveAspectRatio").getString()),n.attributes.overflow=new ut(e,"overflow",r.getAttribute("overflow").getString()),n.children=r.children),"svg"===n.type){var i=this.getStyle("width",!1,!0),a=this.getStyle("height",!1,!0);i.hasValue()&&(n.attributes.width=new ut(e,"width",i.getString())),a.hasValue()&&(n.attributes.height=new ut(e,"height",a.getString()))}var o=n.parent;n.parent=this,n.render(t),n.parent=o}}},{key:"getBoundingBox",value:function(t){var e=this.element;return e?e.getBoundingBox(t):null}},{key:"elementTransform",value:function(){var t=this.document,e=this.element;return Tt.fromElement(t,e)}},{key:"element",get:function(){return this._element||(this._element=this.getHrefAttribute().getDefinition()),this._element}}]),r}(Ht);function Xr(t){return function(){var e,r=w()(t);if(Wr()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Wr(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}function Yr(t,e,r,n,i,a){return t[r*n*4+4*e+a]}function Ur(t,e,r,n,i,a,o){t[r*n*4+4*e+a]=o}function Qr(t,e,r){var n=t[e];return n*(n<0?r-255:r)}function Zr(t,e,r,n){return e+Math.cos(t)*r+Math.sin(t)*n}var Jr=function(t){P()(r,t);var e=Xr(r);function r(t,n,i){var a;h()(this,r),a=e.call(this,t,n,i),a.type="feColorMatrix";var o=L(a.getAttribute("values").getString());switch(a.getAttribute("type").getString("matrix")){case"saturate":var u=o[0];o=[.213+.787*u,.715-.715*u,.072-.072*u,0,0,.213-.213*u,.715+.285*u,.072-.072*u,0,0,.213-.213*u,.715-.715*u,.072+.928*u,0,0,0,0,0,1,0,0,0,0,0,1];break;case"hueRotate":var s=o[0]*Math.PI/180;o=[Zr(s,.213,.787,-.213),Zr(s,.715,-.715,-.715),Zr(s,.072,-.072,.928),0,0,Zr(s,.213,-.213,.143),Zr(s,.715,.285,.14),Zr(s,.072,-.072,-.283),0,0,Zr(s,.213,-.213,-.787),Zr(s,.715,-.715,.715),Zr(s,.072,.928,.072),0,0,0,0,0,1,0,0,0,0,0,1];break;case"luminanceToAlpha":o=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.2125,.7154,.0721,0,0,0,0,0,0,1];break}return a.matrix=o,a.includeOpacity=a.getAttribute("includeOpacity").hasValue(),a}return y()(r,[{key:"apply",value:function(t,e,r,n,i){for(var a=this.includeOpacity,o=this.matrix,u=t.getImageData(0,0,n,i),s=0;s<i;s++)for(var c=0;c<n;c++){var l=Yr(u.data,c,s,n,i,0),f=Yr(u.data,c,s,n,i,1),h=Yr(u.data,c,s,n,i,2),g=Yr(u.data,c,s,n,i,3),y=Qr(o,0,l)+Qr(o,1,f)+Qr(o,2,h)+Qr(o,3,g)+Qr(o,4,1),p=Qr(o,5,l)+Qr(o,6,f)+Qr(o,7,h)+Qr(o,8,g)+Qr(o,9,1),d=Qr(o,10,l)+Qr(o,11,f)+Qr(o,12,h)+Qr(o,13,g)+Qr(o,14,1),v=Qr(o,15,l)+Qr(o,16,f)+Qr(o,17,h)+Qr(o,18,g)+Qr(o,19,1);a&&(y=p=d=0,v*=g/255),Ur(u.data,c,s,n,i,0,y),Ur(u.data,c,s,n,i,1,p),Ur(u.data,c,s,n,i,2,d),Ur(u.data,c,s,n,i,3,v)}t.clearRect(0,0,n,i),t.putImageData(u,0,0)}}]),r}(Ot);function Kr(t){return function(){var e,r=w()(t);if(tn()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function tn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var en=function(t){P()(r,t);var e=Kr(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="mask",t}return y()(r,[{key:"apply",value:function(t,e){var n=this.document,i=this.getAttribute("x").getPixels("x"),a=this.getAttribute("y").getPixels("y"),o=this.getStyle("width").getPixels("x"),u=this.getStyle("height").getPixels("y");if(!o&&!u){var s=new $t;this.children.forEach((function(e){s.addBoundingBox(e.getBoundingBox(t))})),i=Math.floor(s.x1),a=Math.floor(s.y1),o=Math.floor(s.width),u=Math.floor(s.height)}var c=this.removeStyles(e,r.ignoreStyles),l=n.createCanvas(i+o,a+u),f=l.getContext("2d");n.screen.setDefaults(f),this.renderChildren(f),new Jr(n,{nodeType:1,childNodes:[],attributes:[{nodeName:"type",value:"luminanceToAlpha"},{nodeName:"includeOpacity",value:"true"}]}).apply(f,0,0,i+o,a+u);var h=n.createCanvas(i+o,a+u),g=h.getContext("2d");n.screen.setDefaults(g),e.render(g),g.globalCompositeOperation="destination-in",g.fillStyle=f.createPattern(l,"no-repeat"),g.fillRect(0,0,i+o,a+u),t.fillStyle=g.createPattern(h,"no-repeat"),t.fillRect(0,0,i+o,a+u),this.restoreStyles(e,c)}},{key:"render",value:function(t){}}]),r}(Ot);function rn(t){return function(){var e,r=w()(t);if(nn()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function nn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}en.ignoreStyles=["mask","transform","clip-path"];var an=function(){},on=function(t){P()(r,t);var e=rn(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="clipPath",t}return y()(r,[{key:"apply",value:function(t){var e=this.document,r=Reflect.getPrototypeOf(t),n=t.beginPath,i=t.closePath;r&&(r.beginPath=an,r.closePath=an),Reflect.apply(n,t,[]),this.children.forEach((function(n){if("undefined"!==typeof n.path){var a="undefined"!==typeof n.elementTransform?n.elementTransform():null;a||(a=Tt.fromElement(e,n)),a&&a.apply(t),n.path(t),r&&(r.closePath=i),a&&a.unapply(t)}})),Reflect.apply(i,t,[]),t.clip(),r&&(r.beginPath=n,r.closePath=i)}},{key:"render",value:function(t){}}]),r}(Ot);function un(t){return function(){var e,r=w()(t);if(sn()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function sn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var cn=function(t){P()(r,t);var e=un(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="filter",t}return y()(r,[{key:"apply",value:function(t,e){var n=this.document,i=this.children,a=e.getBoundingBox(t);if(a){var o=0,u=0;i.forEach((function(t){var e=t.extraFilterDistance||0;o=Math.max(o,e),u=Math.max(u,e)}));var s=Math.floor(a.width),c=Math.floor(a.height),l=s+2*o,f=c+2*u;if(!(l<1||f<1)){var h=Math.floor(a.x),g=Math.floor(a.y),y=this.removeStyles(e,r.ignoreStyles),p=n.createCanvas(l,f),d=p.getContext("2d");n.screen.setDefaults(d),d.translate(-h+o,-g+u),e.render(d),i.forEach((function(t){"function"===typeof t.apply&&t.apply(d,0,0,l,f)})),t.drawImage(p,0,0,l,f,h-o,g-u,l,f),this.restoreStyles(e,y)}}}},{key:"render",value:function(t){}}]),r}(Ot);function ln(t){return function(){var e,r=w()(t);if(fn()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function fn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}cn.ignoreStyles=["filter","transform","clip-path"];var hn=function(t){P()(r,t);var e=ln(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,i),a.type="feDropShadow",a.addStylesFromStyleDefinition(),a}return y()(r,[{key:"apply",value:function(t,e,r,n,i){}}]),r}(Ot);function gn(t){return function(){var e,r=w()(t);if(yn()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function yn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var pn=function(t){P()(r,t);var e=gn(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="feMorphology",t}return y()(r,[{key:"apply",value:function(t,e,r,n,i){}}]),r}(Ot);function dn(t){return function(){var e,r=w()(t);if(vn()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function vn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var mn=function(t){P()(r,t);var e=dn(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="feComposite",t}return y()(r,[{key:"apply",value:function(t,e,r,n,i){}}]),r}(Ot);function xn(t){return function(){var e,r=w()(t);if(bn()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function bn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var kn=function(t){P()(r,t);var e=xn(r);function r(t,n,i){var a;return h()(this,r),a=e.call(this,t,n,i),a.type="feGaussianBlur",a.blurRadius=Math.floor(a.getAttribute("stdDeviation").getNumber()),a.extraFilterDistance=a.blurRadius,a}return y()(r,[{key:"apply",value:function(t,e,r,n,i){var a=this.document,o=this.blurRadius,u=a.window?a.window.document.body:null,s=t.canvas;s.id=a.getUniqueId(),u&&(s.style.display="none",u.appendChild(s)),Object(D["a"])(s,e,r,n,i,o),u&&u.removeChild(s)}}]),r}(Ot);function wn(t){return function(){var e,r=w()(t);if(Sn()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function Sn(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Pn=function(t){P()(r,t);var e=wn(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="title",t}return r}(Ot);function Rn(t){return function(){var e,r=w()(t);if(An()){var n=w()(this).constructor;e=Reflect.construct(r,arguments,n)}else e=r.apply(this,arguments);return b()(this,e)}}function An(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}var Cn=function(t){P()(r,t);var e=Rn(r);function r(){var t;return h()(this,r),t=e.apply(this,arguments),t.type="desc",t}return r}(Ot),Mn={svg:se,rect:fe,circle:ye,ellipse:ve,line:be,polyline:Se,polygon:Ae,path:ae,pattern:Ee,marker:Te,defs:Le,linearGradient:Ge,radialGradient:We,stop:Qe,animate:Ke,animateColor:rr,animateTransform:ar,font:fr,"font-face":yr,"missing-glyph":vr,glyph:br,text:Yt,tspan:Zt,tref:Sr,a:Ar,textPath:Tr,image:Lr,g:Ie,symbol:Ir,style:$r,use:Hr,mask:en,clipPath:on,filter:cn,feDropShadow:hn,feMorphology:pn,feComposite:mn,feColorMatrix:Jr,feGaussianBlur:kn,title:Pn,desc:Cn};function En(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function Vn(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?En(Object(r),!0).forEach((function(e){l()(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):En(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Dn(t,e){var r=document.createElement("canvas");return r.width=t,r.height=e,r}function Tn(t){return On.apply(this,arguments)}function On(){return On=s()(o.a.mark((function t(e){var r,n,i=arguments;return o.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return r=i.length>1&&void 0!==i[1]&&i[1],n=document.createElement("img"),r&&(n.crossOrigin="Anonymous"),t.abrupt("return",new Promise((function(t,r){n.onload=function(){t(n)},n.onerror=function(){r()},n.src=e})));case 4:case"end":return t.stop()}}),t)}))),On.apply(this,arguments)}var Nn=function(){function t(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=r.rootEmSize,i=void 0===n?12:n,a=r.emSize,o=void 0===a?12:a,u=r.createCanvas,s=void 0===u?t.createCanvas:u,c=r.createImage,l=void 0===c?t.createImage:c,f=r.anonymousCrossOrigin;h()(this,t),this.canvg=e,this.definitions={},this.styles={},this.stylesSpecificity={},this.images=[],this.fonts=[],this.emSizeStack=[],this.uniqueId=0,this.screen=e.screen,this.rootEmSize=i,this.emSize=o,this.createCanvas=s,this.createImage=this.bindCreateImage(l,f),this.screen.wait(this.isImagesLoaded.bind(this)),this.screen.wait(this.isFontsLoaded.bind(this))}return y()(t,[{key:"bindCreateImage",value:function(t,e){return"boolean"===typeof e?function(r,n){return t(r,"boolean"===typeof n?n:e)}:t}},{key:"popEmSize",value:function(){var t=this.emSizeStack;t.pop()}},{key:"getUniqueId",value:function(){return"canvg".concat(++this.uniqueId)}},{key:"isImagesLoaded",value:function(){return this.images.every((function(t){return t.loaded}))}},{key:"isFontsLoaded",value:function(){return this.fonts.every((function(t){return t.loaded}))}},{key:"createDocumentElement",value:function(t){var e=this.createElement(t.documentElement);return e.root=!0,e.addStylesFromStyleDefinition(),this.documentElement=e,e}},{key:"createElement",value:function(e){var r=e.nodeName.replace(/^[^:]+:/,""),n=t.elementTypes[r];return"undefined"!==typeof n?new n(this,e):new zt(this,e)}},{key:"createTextNode",value:function(t){return new te(this,t)}},{key:"setViewBox",value:function(t){this.screen.setViewBox(Vn({document:this},t))}},{key:"window",get:function(){return this.screen.window}},{key:"fetch",get:function(){return this.screen.fetch}},{key:"ctx",get:function(){return this.screen.ctx}},{key:"emSize",get:function(){var t=this.emSizeStack;return t[t.length-1]},set:function(t){var e=this.emSizeStack;e.push(t)}}]),t}();function Ln(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function zn(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?Ln(Object(r),!0).forEach((function(e){l()(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):Ln(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}Nn.createCanvas=Dn,Nn.createImage=Tn,Nn.elementTypes=Mn;var Bn=function(){function t(e,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};h()(this,t),this.parser=new dt(n),this.screen=new gt(e,n),this.options=n;var i=new Nn(this,n),a=i.createDocumentElement(r);this.document=i,this.documentElement=a}return y()(t,[{key:"fork",value:function(e,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return t.from(e,r,zn({},this.options,{},n))}},{key:"forkString",value:function(e,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return t.fromString(e,r,zn({},this.options,{},n))}},{key:"ready",value:function(){return this.screen.ready()}},{key:"isReady",value:function(){return this.screen.isReady()}},{key:"render",value:function(){var t=s()(o.a.mark((function t(){var e,r=arguments;return o.a.wrap((function(t){while(1)switch(t.prev=t.next){case 0:return e=r.length>0&&void 0!==r[0]?r[0]:{},this.start(zn({enableRedraw:!0,ignoreAnimation:!0,ignoreMouse:!0},e)),t.next=4,this.ready();case 4:this.stop();case 5:case"end":return t.stop()}}),t,this)})));function e(){return t.apply(this,arguments)}return e}()},{key:"start",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=this.documentElement,r=this.screen,n=this.options;r.start(e,zn({enableRedraw:!0},n,{},t))}},{key:"stop",value:function(){this.screen.stop()}},{key:"resize",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t,r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];this.documentElement.resize(t,e,r)}}],[{key:"from",value:function(){var e=s()(o.a.mark((function e(r,n){var i,a,u,s=arguments;return o.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return i=s.length>2&&void 0!==s[2]?s[2]:{},a=new dt(i),e.next=4,a.parse(n);case 4:return u=e.sent,e.abrupt("return",new t(r,u,i));case 6:case"end":return e.stop()}}),e)})));function r(t,r){return e.apply(this,arguments)}return r}()},{key:"fromString",value:function(e,r){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=new dt(n),a=i.parseFromString(r);return new t(e,a,n)}}]),t}();function In(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.DOMParser,r={window:null,ignoreAnimation:!0,ignoreMouse:!0,DOMParser:e,createCanvas:function(t,e){return new OffscreenCanvas(t,e)},createImage:function(t){return s()(o.a.mark((function e(){var r,n,i;return o.a.wrap((function(e){while(1)switch(e.prev=e.next){case 0:return e.next=2,fetch(t);case 2:return r=e.sent,e.next=5,r.blob();case 5:return n=e.sent,e.next=8,createImageBitmap(n);case 8:return i=e.sent,e.abrupt("return",i);case 10:case"end":return e.stop()}}),e)})))()}};return"undefined"===typeof DOMParser&&"undefined"!==typeof e||Reflect.deleteProperty(r,"DOMParser"),r}function Fn(t){var e=t.DOMParser,r=t.canvas,n=t.fetch;return{window:null,ignoreAnimation:!0,ignoreMouse:!0,DOMParser:e,fetch:n,createCanvas:r.createCanvas,createImage:r.loadImage}}var jn=Object.freeze({__proto__:null,offscreen:In,node:Fn});e["default"]=Bn}.call(this,r("4362"))},8962:function(t,e,r){r("e439"),r("d3b7"),r("5d41");var n=r("9f70");function i(){return"undefined"!==typeof Reflect&&Reflect.get?(t.exports=i=Reflect.get.bind(),t.exports.__esModule=!0,t.exports["default"]=t.exports):(t.exports=i=function(t,e,r){var i=n(t,e);if(i){var a=Object.getOwnPropertyDescriptor(i,e);return a.get?a.get.call(arguments.length<3?t:r):a.value}},t.exports.__esModule=!0,t.exports["default"]=t.exports),i.apply(this,arguments)}t.exports=i,t.exports.__esModule=!0,t.exports["default"]=t.exports},"9f70":function(t,e,r){var n=r("36c6");function i(t,e){while(!Object.prototype.hasOwnProperty.call(t,e))if(t=n(t),null===t)break;return t}t.exports=i,t.exports.__esModule=!0,t.exports["default"]=t.exports},a6231:function(t,e,r){"use strict";var n=r("23e7"),i=r("b727").every,a=r("a640"),o=r("ae40"),u=a("every"),s=o("every");n({target:"Array",proto:!0,forced:!u||!s},{every:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0)}})},a6fd:function(t,e,r){var n=r("23e7"),i=r("d066"),a=r("1c0b"),o=r("825a"),u=r("d039"),s=i("Reflect","apply"),c=Function.apply,l=!u((function(){s((function(){}))}));n({target:"Reflect",stat:!0,forced:l},{apply:function(t,e,r){return a(t),o(r),s?s(t,e,r):c.call(t,e,r)}})},ac16:function(t,e,r){var n=r("23e7"),i=r("825a"),a=r("06cf").f;n({target:"Reflect",stat:!0},{deleteProperty:function(t,e){var r=a(i(t),e);return!(r&&!r.configurable)&&delete t[e]}})},c975:function(t,e,r){"use strict";var n=r("23e7"),i=r("4d64").indexOf,a=r("a640"),o=r("ae40"),u=[].indexOf,s=!!u&&1/[1].indexOf(1,-0)<0,c=a("indexOf"),l=o("indexOf",{ACCESSORS:!0,1:0});n({target:"Array",proto:!0,forced:s||!c||!l},{indexOf:function(t){return s?u.apply(this,arguments)||0:i(this,t,arguments.length>1?arguments[1]:void 0)}})},ed6d:function(t,e,r){var n=r("4a4b");function i(t,e){if("function"!==typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),Object.defineProperty(t,"prototype",{writable:!1}),e&&n(t,e)}t.exports=i,t.exports.__esModule=!0,t.exports["default"]=t.exports}}]);