!function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define([],n):"object"==typeof exports?exports.G=n():t.G=n()}(window,(function(){return function(t){var n={};function e(r){if(n[r])return n[r].exports;var i=n[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,e),i.l=!0,i.exports}return e.m=t,e.c=n,e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:r})},e.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n)return t;if(4&n&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(e.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var i in t)e.d(r,i,function(n){return t[n]}.bind(null,i));return r},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},e.p="",e(e.s=38)}([function(t,n,e){"use strict";e.d(n,"g",(function(){return v})),e.d(n,"k",(function(){return g})),e.d(n,"m",(function(){return m})),e.d(n,"o",(function(){return x})),e.d(n,"b",(function(){return s})),e.d(n,"d",(function(){return a})),e.d(n,"e",(function(){return u})),e.d(n,"f",(function(){return d})),e.d(n,"h",(function(){return c})),e.d(n,"i",(function(){return p})),e.d(n,"a",(function(){return f})),e.d(n,"c",(function(){return A})),e.d(n,"j",(function(){return w})),e.d(n,"n",(function(){return S})),e.d(n,"l",(function(){return P}));var r=function(t){return null!==t&&"function"!=typeof t&&isFinite(t.length)},i={}.toString,o=function(t,n){return i.call(t)==="[object "+n+"]"},a=function(t){return o(t,"Function")},u=function(t){return null==t},s=function(t){return Array.isArray?Array.isArray(t):o(t,"Array")},c=function(t){var n=typeof t;return null!==t&&"object"===n||"function"===n};var f=function(t,n){if(t)if(s(t))for(var e=0,r=t.length;e-1},o=function(t,n){if(!r(t))return t;for(var e=[],i=0;i-1;)S.call(t,o,1);return t},T=Array.prototype.splice,j=function(t,n){if(!r(t))return[];for(var e=t?n.length:0,i=e-1;e--;){var o=void 0,a=n[e];e!==i&&a===o||(o=a,T.call(t,a,1))}return t},k=function(t,n,e){if(!l(t)&&!y(t))return t;var r=e;return p(t,(function(t,e){r=n(r,t,e)})),r},E=function(t,n){var e=[];if(!r(t))return e;for(var i=-1,o=[],a=t.length;++in[i])return 1;if(t[i]e?e:t},tt=function(t,n){var e=n.toString(),r=e.indexOf(".");if(-1===r)return Math.round(t);var i=e.substr(r+1).length;return i>20&&(i=20),parseFloat(t.toFixed(i))},nt=function(t){return s(t,"Number")},et=function(t){return nt(t)&&t%1!=0},rt=function(t){return nt(t)&&t%2==0},it=Number.isInteger?Number.isInteger:function(t){return nt(t)&&t%1==0},ot=function(t){return nt(t)&&t<0};function at(t,n,e){return void 0===e&&(e=1e-5),Math.abs(t-n)0},ct=function(t,n){if(l(t)){var e,r,i=t[0];return e=c(n)?n(t[0]):t[0][n],p(t,(function(t){(r=c(n)?n(t):t[n])>e&&(i=t,e=r)})),i}},ft=function(t,n){if(l(t)){var e,r,i=t[0];return e=c(n)?n(t[0]):t[0][n],p(t,(function(t){(r=c(n)?n(t):t[n])n?(r&&(clearTimeout(r),r=null),u=c,a=t.apply(i,o),r||(i=o=null)):r||!1===e.trailing||(r=setTimeout(s,f)),a};return c.cancel=function(){clearTimeout(r),u=0,r=i=o=null},c},dn=function(t){return r(t)?Array.prototype.slice.call(t):[]},vn={},gn=function(t){return vn[t=t||"g"]?vn[t]+=1:vn[t]=1,t+vn[t]},yn=function(){},mn=function(t){return t};function bn(t){return f(t)?0:r(t)?t.length:Object.keys(t).length}var xn=function(){function t(){this.map={}}return t.prototype.has=function(t){return void 0!==this.map[t]},t.prototype.get=function(t,n){var e=this.map[t];return void 0===e?n:e},t.prototype.set=function(t,n){this.map[t]=n},t.prototype.clear=function(){this.map={}},t.prototype.delete=function(t){delete this.map[t]},t.prototype.size=function(){return Object.keys(this.map).length},t}()},function(t,n,e){"use strict";e.r(n),e.d(n,"__extends",(function(){return i})),e.d(n,"__assign",(function(){return o})),e.d(n,"__rest",(function(){return a})),e.d(n,"__decorate",(function(){return u})),e.d(n,"__param",(function(){return s})),e.d(n,"__metadata",(function(){return c})),e.d(n,"__awaiter",(function(){return f})),e.d(n,"__generator",(function(){return l})),e.d(n,"__createBinding",(function(){return h})),e.d(n,"__exportStar",(function(){return p})),e.d(n,"__values",(function(){return d})),e.d(n,"__read",(function(){return v})),e.d(n,"__spread",(function(){return g})),e.d(n,"__spreadArrays",(function(){return y})),e.d(n,"__await",(function(){return m})),e.d(n,"__asyncGenerator",(function(){return b})),e.d(n,"__asyncDelegator",(function(){return x})),e.d(n,"__asyncValues",(function(){return M})),e.d(n,"__makeTemplateObject",(function(){return w})),e.d(n,"__importStar",(function(){return A})),e.d(n,"__importDefault",(function(){return O})),e.d(n,"__classPrivateFieldGet",(function(){return S})),e.d(n,"__classPrivateFieldSet",(function(){return P})); /*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */ var r=function(t,n){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var e in n)Object.prototype.hasOwnProperty.call(n,e)&&(t[e]=n[e])})(t,n)};function i(t,n){function e(){this.constructor=t}r(t,n),t.prototype=null===n?Object.create(n):(e.prototype=n.prototype,new e)}var o=function(){return(o=Object.assign||function(t){for(var n,e=1,r=arguments.length;e=0;u--)(i=t[u])&&(a=(o<3?i(a):o>3?i(n,e,a):i(n,e))||a);return o>3&&a&&Object.defineProperty(n,e,a),a}function s(t,n){return function(e,r){n(e,r,t)}}function c(t,n){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(t,n)}function f(t,n,e,r){return new(e||(e=Promise))((function(i,o){function a(t){try{s(r.next(t))}catch(t){o(t)}}function u(t){try{s(r.throw(t))}catch(t){o(t)}}function s(t){var n;t.done?i(t.value):(n=t.value,n instanceof e?n:new e((function(t){t(n)}))).then(a,u)}s((r=r.apply(t,n||[])).next())}))}function l(t,n){var e,r,i,o,a={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:u(0),throw:u(1),return:u(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function u(o){return function(u){return function(o){if(e)throw new TypeError("Generator is already executing.");for(;a;)try{if(e=1,r&&(i=2&o[0]?r.return:o[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,o[1])).done)return i;switch(r=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return a.label++,{value:o[1],done:!1};case 5:a.label++,r=o[1],o=[0];continue;case 7:o=a.ops.pop(),a.trys.pop();continue;default:if(!(i=a.trys,(i=i.length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){a=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function v(t,n){var e="function"==typeof Symbol&&t[Symbol.iterator];if(!e)return t;var r,i,o=e.call(t),a=[];try{for(;(void 0===n||n-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(t){i={error:t}}finally{try{r&&!r.done&&(e=o.return)&&e.call(o)}finally{if(i)throw i.error}}return a}function g(){for(var t=[],n=0;n1||u(t,n)}))})}function u(t,n){try{(e=i[t](n)).value instanceof m?Promise.resolve(e.value.v).then(s,c):f(o[0][2],e)}catch(t){f(o[0][3],t)}var e}function s(t){u("next",t)}function c(t){u("throw",t)}function f(t,n){t(n),o.shift(),o.length&&u(o[0][0],o[0][1])}}function x(t){var n,e;return n={},r("next"),r("throw",(function(t){throw t})),r("return"),n[Symbol.iterator]=function(){return this},n;function r(r,i){n[r]=t[r]?function(n){return(e=!e)?{value:m(t[r](n)),done:"return"===r}:i?i(n):n}:i}}function M(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n,e=t[Symbol.asyncIterator];return e?e.call(t):(t=d(t),n={},r("next"),r("throw"),r("return"),n[Symbol.asyncIterator]=function(){return this},n);function r(e){n[e]=t[e]&&function(n){return new Promise((function(r,i){(function(t,n,e,r){Promise.resolve(r).then((function(n){t({value:n,done:e})}),n)})(r,i,(n=t[e](n)).done,n.value)}))}}}function w(t,n){return Object.defineProperty?Object.defineProperty(t,"raw",{value:n}):t.raw=n,t}var _=Object.create?function(t,n){Object.defineProperty(t,"default",{enumerable:!0,value:n})}:function(t,n){t.default=n};function A(t){if(t&&t.__esModule)return t;var n={};if(null!=t)for(var e in t)"default"!==e&&Object.prototype.hasOwnProperty.call(t,e)&&h(n,t,e);return _(n,t),n}function O(t){return t&&t.__esModule?t:{default:t}}function S(t,n){if(!n.has(t))throw new TypeError("attempted to get private field on non-instance");return n.get(t)}function P(t,n,e){if(!n.has(t))throw new TypeError("attempted to set private field on non-instance");return n.set(t,e),e}},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.EVENTS=n.SVG_ATTR_MAP=n.SHAPE_TO_TAGS=void 0,n.SHAPE_TO_TAGS={rect:"path",circle:"circle",line:"line",path:"path",marker:"path",text:"text",polyline:"polyline",polygon:"polygon",image:"image",ellipse:"ellipse",dom:"foreignObject"},n.SVG_ATTR_MAP={opacity:"opacity",fillStyle:"fill",fill:"fill",fillOpacity:"fill-opacity",strokeStyle:"stroke",strokeOpacity:"stroke-opacity",stroke:"stroke",x:"x",y:"y",r:"r",rx:"rx",ry:"ry",width:"width",height:"height",x1:"x1",x2:"x2",y1:"y1",y2:"y2",lineCap:"stroke-linecap",lineJoin:"stroke-linejoin",lineWidth:"stroke-width",lineDash:"stroke-dasharray",lineDashOffset:"stroke-dashoffset",miterLimit:"stroke-miterlimit",font:"font",fontSize:"font-size",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",fontFamily:"font-family",startArrow:"marker-start",endArrow:"marker-end",path:"d",class:"class",id:"id",style:"style",preserveAspectRatio:"preserveAspectRatio"},n.EVENTS=["click","mousedown","mouseup","dblclick","contextmenu","mouseenter","mouseleave","mouseover","mouseout","mousemove","wheel"]},function(t,n,e){"use strict";function r(t,n){var e=[],r=t[0],i=t[1],o=t[2],a=t[3],u=t[4],s=t[5],c=t[6],f=t[7],l=t[8],h=n[0],p=n[1],d=n[2],v=n[3],g=n[4],y=n[5],m=n[6],b=n[7],x=n[8];return e[0]=h*r+p*a+d*c,e[1]=h*i+p*u+d*f,e[2]=h*o+p*s+d*l,e[3]=v*r+g*a+y*c,e[4]=v*i+g*u+y*f,e[5]=v*o+g*s+y*l,e[6]=m*r+b*a+x*c,e[7]=m*i+b*u+x*f,e[8]=m*o+b*s+x*l,e}function i(t,n){var e=[],r=n[0],i=n[1];return e[0]=t[0]*r+t[3]*i+t[6],e[1]=t[1]*r+t[4]*i+t[7],e}function o(t){var n=[],e=t[0],r=t[1],i=t[2],o=t[3],a=t[4],u=t[5],s=t[6],c=t[7],f=t[8],l=f*a-u*c,h=-f*o+u*s,p=c*o-a*s,d=e*l+r*h+i*p;return d?(d=1/d,n[0]=l*d,n[1]=(-f*r+i*c)*d,n[2]=(u*r-i*a)*d,n[3]=h*d,n[4]=(f*e-i*s)*d,n[5]=(-u*e+i*o)*d,n[6]=p*d,n[7]=(-c*e+r*s)*d,n[8]=(a*e-r*o)*d,n):null}e.d(n,"b",(function(){return r})),e.d(n,"c",(function(){return i})),e.d(n,"a",(function(){return o}))},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(3),i=e(12),o=e(13),a=e(8),u=e(20),s=e(4),c=e(14),f=e(21),l=e(12),h=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="svg",n.canFill=!1,n.canStroke=!1,n}return r.__extends(n,t),n.prototype.getDefaultAttrs=function(){var n=t.prototype.getDefaultAttrs.call(this);return r.__assign(r.__assign({},n),{lineWidth:1,lineAppendWidth:0,strokeOpacity:1,fillOpacity:1})},n.prototype.afterAttrsChange=function(n){t.prototype.afterAttrsChange.call(this,n);var e=this.get("canvas");if(e&&e.get("autoDraw")){var r=e.get("context");this.draw(r,n)}},n.prototype.getShapeBase=function(){return c},n.prototype.getGroupBase=function(){return f.default},n.prototype.onCanvasChange=function(t){u.refreshElement(this,t)},n.prototype.calculateBBox=function(){var t=this.get("el"),n=null;if(t)n=t.getBBox();else{var e=l.getBBoxMethod(this.get("type"));e&&(n=e(this))}if(n){var r=n.x,i=n.y,o=n.width,a=n.height,u=this.getHitLineWidth(),s=u/2,c=r-s,f=i-s;return{x:c,y:f,minX:c,minY:f,maxX:r+o+s,maxY:i+a+s,width:o+u,height:a+u}}return{x:0,y:0,minX:0,minY:0,maxX:0,maxY:0,width:0,height:0}},n.prototype.isFill=function(){var t=this.attr(),n=t.fill,e=t.fillStyle;return(n||e||this.isClipShape())&&this.canFill},n.prototype.isStroke=function(){var t=this.attr(),n=t.stroke,e=t.strokeStyle;return(n||e)&&this.canStroke},n.prototype.draw=function(t,n){var e=this.get("el");this.get("destroyed")?e&&e.parentNode.removeChild(e):(e||a.createDom(this),o.setClip(this,t),this.createPath(t,n),this.shadow(t,n),this.strokeAndFill(t,n),this.transform(n))},n.prototype.createPath=function(t,n){},n.prototype.strokeAndFill=function(t,n){var e=n||this.attr(),r=e.fill,i=e.fillStyle,o=e.stroke,a=e.strokeStyle,u=e.fillOpacity,c=e.strokeOpacity,f=e.lineWidth,l=this.get("el");this.canFill&&(n?"fill"in e?this._setColor(t,"fill",r):"fillStyle"in e&&this._setColor(t,"fill",i):this._setColor(t,"fill",r||i),u&&l.setAttribute(s.SVG_ATTR_MAP.fillOpacity,u)),this.canStroke&&f>0&&(n?"stroke"in e?this._setColor(t,"stroke",o):"strokeStyle"in e&&this._setColor(t,"stroke",a):this._setColor(t,"stroke",o||a),c&&l.setAttribute(s.SVG_ATTR_MAP.strokeOpacity,c),f&&l.setAttribute(s.SVG_ATTR_MAP.lineWidth,f))},n.prototype._setColor=function(t,n,e){var r=this.get("el");if(e)if(e=e.trim(),/^[r,R,L,l]{1}[\s]*\(/.test(e))(i=t.find("gradient",e))||(i=t.addGradient(e)),r.setAttribute(s.SVG_ATTR_MAP[n],"url(#"+i+")");else if(/^[p,P]{1}[\s]*\(/.test(e)){var i;(i=t.find("pattern",e))||(i=t.addPattern(e)),r.setAttribute(s.SVG_ATTR_MAP[n],"url(#"+i+")")}else r.setAttribute(s.SVG_ATTR_MAP[n],e);else r.setAttribute(s.SVG_ATTR_MAP[n],"none")},n.prototype.shadow=function(t,n){var e=this.attr(),r=n||e,i=r.shadowOffsetX,a=r.shadowOffsetY,u=r.shadowBlur,s=r.shadowColor;(i||a||u||s)&&o.setShadow(this,t)},n.prototype.transform=function(t){var n=this.attr();(t||n).matrix&&o.setTransform(this)},n.prototype.isInShape=function(t,n){return this.isPointInPath(t,n)},n.prototype.isPointInPath=function(t,n){var e=this.get("el"),r=this.get("canvas").get("el").getBoundingClientRect(),i=t+r.left,o=n+r.top,a=document.elementFromPoint(i,o);return!(!a||!a.isEqualNode(e))},n.prototype.getHitLineWidth=function(){var t=this.attrs,n=t.lineWidth,e=t.lineAppendWidth;return this.isStroke()?n+e:0},n}(i.AbstractShape);n.default=h},function(t,n,e){"use strict";e.d(n,"a",(function(){return i})); /*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */ var r=function(t,n){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var e in n)Object.prototype.hasOwnProperty.call(n,e)&&(t[e]=n[e])})(t,n)};function i(t,n){function e(){this.constructor=t}r(t,n),t.prototype=null===n?Object.create(n):(e.prototype=n.prototype,new e)}Object.create;Object.create},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.moveTo=n.sortDom=n.createDom=n.createSVGElement=void 0;var r=e(2),i=e(4);function o(t){return document.createElementNS("http://www.w3.org/2000/svg",t)}n.createSVGElement=o,n.createDom=function(t){var n=i.SHAPE_TO_TAGS[t.type],e=t.getParent();if(!n)throw new Error("the type "+t.type+" is not supported by svg");var r=o(n);if(t.get("id")&&(r.id=t.get("id")),t.set("el",r),t.set("attrs",{}),e){var a=e.get("el");a||(a=e.createDom(),e.set("el",a)),a.appendChild(r)}return r},n.sortDom=function(t,n){var e=t.get("el"),i=r.toArray(e.children).sort(n),o=document.createDocumentFragment();i.forEach((function(t){o.appendChild(t)})),e.appendChild(o)},n.moveTo=function(t,n){var e=t.parentNode,r=Array.from(e.childNodes).filter((function(t){return 1===t.nodeType&&"defs"!==t.nodeName.toLowerCase()})),i=r[n],o=r.indexOf(t);if(i){if(o>n)e.insertBefore(t,i);else if(o(e-t)*(e-t)+(r-n)*(r-n)?a(e,r,i,o):this.pointToLine(t,n,e,r,i,o)},pointToLine:function(t,n,e,r,i,o){var a=[e-t,r-n];if(function(t,n){return t[0]===n[0]&&t[1]===n[1]}(a,[0,0]))return Math.sqrt((i-t)*(i-t)+(o-n)*(o-n));var u=[-a[1],a[0]];!function(t,n){var e=n[0],r=n[1],i=e*e+r*r;i>0&&(i=1/Math.sqrt(i)),t[0]=n[0]*i,t[1]=n[1]*i}(u,u);var s=[i-t,o-n];return Math.abs(function(t,n){return t[0]*n[0]+t[1]*n[1]}(s,u))},tangentAngle:function(t,n,e,r){return Math.atan2(r-n,e-t)}};function v(t,n,e,r,i,o){var u,s=1/0,c=[e,r],f=20;o&&o>200&&(f=o/10);for(var l=1/f,h=l/10,p=0;p<=f;p++){var d=p*l,v=[i.apply(null,t.concat([d])),i.apply(null,n.concat([d]))];(b=a(c[0],c[1],v[0],v[1]))=0&&b=0?[i]:[]}function m(t,n,e,r){return 2*(1-r)*(n-t)+2*r*(e-n)}function b(t,n,e,r,i,o,a){var u=g(t,e,i,a),s=g(n,r,o,a),c=d.pointAt(t,n,e,r,a),f=d.pointAt(e,r,i,o,a);return[[t,n,c.x,c.y,u,s],[u,s,f.x,f.y,i,o]]}var x={box:function(t,n,e,r,i,o){var a=y(t,e,i)[0],u=y(n,r,o)[0],c=[t,i],f=[n,o];return void 0!==a&&c.push(g(t,e,i,a)),void 0!==u&&f.push(g(n,r,o,u)),s(c,f)},length:function(t,n,e,r,i,o){return function t(n,e,r,i,o,u,s){if(0===s)return(a(n,e,r,i)+a(r,i,o,u)+a(n,e,o,u))/2;var c=b(n,e,r,i,o,u,.5),f=c[0],l=c[1];return f.push(s-1),l.push(s-1),t.apply(null,f)+t.apply(null,l)}(t,n,e,r,i,o,3)},nearestPoint:function(t,n,e,r,i,o,a,u){return v([t,e,i],[n,r,o],a,u,g)},pointDistance:function(t,n,e,r,i,o,u,s){var c=this.nearestPoint(t,n,e,r,i,o,u,s);return a(c.x,c.y,u,s)},interpolationAt:g,pointAt:function(t,n,e,r,i,o,a){return{x:g(t,e,i,a),y:g(n,r,o,a)}},divide:function(t,n,e,r,i,o,a){return b(t,n,e,r,i,o,a)},tangentAngle:function(t,n,e,r,i,o,a){var u=m(t,e,i,a),s=m(n,r,o,a);return f(Math.atan2(s,u))}};function M(t,n,e,r,i){var o=1-i;return o*o*o*t+3*n*i*o*o+3*e*i*i*o+r*i*i*i}function w(t,n,e,r,i){var o=1-i;return 3*(o*o*(n-t)+2*o*i*(e-n)+i*i*(r-e))}function _(t,n,e,r){var i,o,a,s=-3*t+9*n-9*e+3*r,c=6*t-12*n+6*e,f=3*n-3*t,l=[];if(u(s,0))u(c,0)||(i=-f/c)>=0&&i<=1&&l.push(i);else{var h=c*c-4*s*f;u(h,0)?l.push(-c/(2*s)):h>0&&(o=(-c-(a=Math.sqrt(h)))/(2*s),(i=(-c+a)/(2*s))>=0&&i<=1&&l.push(i),o>=0&&o<=1&&l.push(o))}return l}function A(t,n,e,r,i,o,a,u,s){var c=M(t,e,i,a,s),f=M(n,r,o,u,s),l=d.pointAt(t,n,e,r,s),h=d.pointAt(e,r,i,o,s),p=d.pointAt(i,o,a,u,s),v=d.pointAt(l.x,l.y,h.x,h.y,s),g=d.pointAt(h.x,h.y,p.x,p.y,s);return[[t,n,l.x,l.y,v.x,v.y,c,f],[c,f,g.x,g.y,p.x,p.y,a,u]]}function O(t,n,e,r,i,o,u,s,c){if(0===c)return function(t,n){for(var e=0,r=t.length,i=0;i0?e:-1*e}var C=function(t,n,e,r,i,o){var a=e,u=r;if(0===a||0===u)return{x:t,y:n};for(var s,c,f=i-t,l=o-n,h=Math.abs(f),p=Math.abs(l),d=a*a,v=u*u,g=Math.PI/4,y=0;y<4;y++){s=a*Math.cos(g),c=u*Math.sin(g);var m=(d-v)*Math.pow(Math.cos(g),3)/a,b=(v-d)*Math.pow(Math.sin(g),3)/u,x=s-m,M=c-b,w=h-m,_=p-b,A=Math.hypot(M,x),O=Math.hypot(_,w);g+=A*Math.asin((x*_-M*w)/(A*O))/Math.sqrt(d+v-s*s-c*c),g=Math.min(Math.PI/2,Math.max(0,g))}return{x:t+P(s,f),y:n+P(c,l)}};function T(t,n,e,r,i,o){return e*Math.cos(i)*Math.cos(o)-r*Math.sin(i)*Math.sin(o)+t}function j(t,n,e,r,i,o){return e*Math.sin(i)*Math.cos(o)+r*Math.cos(i)*Math.sin(o)+n}function k(t,n,e){return{x:t*Math.cos(e),y:n*Math.sin(e)}}function E(t,n,e){var r=Math.cos(e),i=Math.sin(e);return[t*r-n*i,t*i+n*r]}var B={box:function(t,n,e,r,i,o,a){for(var u=function(t,n,e){return Math.atan(-n/t*Math.tan(e))}(e,r,i),s=1/0,c=-1/0,f=[o,a],l=2*-Math.PI;l<=2*Math.PI;l+=Math.PI){var h=u+l;oc&&(c=p)}var d=function(t,n,e){return Math.atan(n/(t*Math.tan(e)))}(e,r,i),v=1/0,g=-1/0,y=[o,a];for(l=2*-Math.PI;l<=2*Math.PI;l+=Math.PI){var m=d+l;og&&(g=b)}return{x:s,y:v,width:c-s,height:g-v}},length:function(t,n,e,r,i,o,a){},nearestPoint:function(t,n,e,r,i,o,a,u,s){var c=E(u-t,s-n,-i),f=c[0],l=c[1],h=C(0,0,e,r,f,l),p=function(t,n,e,r){return(Math.atan2(r*t,e*n)+2*Math.PI)%(2*Math.PI)}(e,r,h.x,h.y);pa&&(h=k(e,r,a));var d=E(h.x,h.y,i);return{x:d[0]+t,y:d[1]+n}},pointDistance:function(t,n,e,r,i,o,u,s,c){var f=this.nearestPoint(t,n,e,r,s,c);return a(f.x,f.y,s,c)},pointAt:function(t,n,e,r,i,o,a,u){var s=(a-o)*u+o;return{x:T(t,0,e,r,i,s),y:j(0,n,e,r,i,s)}},tangentAngle:function(t,n,e,r,i,o,a,u){var s=(a-o)*u+o,c=function(t,n,e,r,i,o,a,u){return-1*e*Math.cos(i)*Math.sin(u)-r*Math.sin(i)*Math.cos(u)}(0,0,e,r,i,0,0,s),l=function(t,n,e,r,i,o,a,u){return-1*e*Math.sin(i)*Math.sin(u)+r*Math.cos(i)*Math.cos(u)}(0,0,e,r,i,0,0,s);return f(Math.atan2(l,c))}};function I(t){for(var n=0,e=[],r=0;r1||n<0||t.length<2)return null;var e=I(t),r=e.segments,i=e.totalLength;if(0===i)return{x:t[0][0],y:t[0][1]};for(var o=0,a=null,u=0;u=o&&n<=o+l){var h=(n-o)/l;a=d.pointAt(c[0],c[1],f[0],f[1],h);break}o+=l}return a}function F(t,n){if(n>1||n<0||t.length<2)return 0;for(var e=I(t),r=e.segments,i=e.totalLength,o=0,a=0,u=0;u=o&&n<=o+l){a=Math.atan2(f[1]-c[1],f[0]-c[0]);break}o+=l}return a}function L(t,n,e){for(var r=1/0,i=0;i2&&(e.push([i].concat(u.splice(0,2))),s="l",i="m"===i?"l":"L"),"o"===s&&1===u.length&&e.push([i,u[0]]),"r"===s)e.push([i].concat(u));else for(;u.length>=n[s]&&(e.push([i].concat(u.splice(0,n[s]))),n[s]););return t})),e},s=function(t,n){for(var e=[],r=0,i=t.length;i-2*!n>r;r+=2){var o=[{x:+t[r-2],y:+t[r-1]},{x:+t[r],y:+t[r+1]},{x:+t[r+2],y:+t[r+3]},{x:+t[r+4],y:+t[r+5]}];n?r?i-4===r?o[3]={x:+t[0],y:+t[1]}:i-2===r&&(o[2]={x:+t[0],y:+t[1]},o[3]={x:+t[2],y:+t[3]}):o[0]={x:+t[i-2],y:+t[i-1]}:i-4===r?o[3]=o[2]:r||(o[0]={x:+t[r],y:+t[r+1]}),e.push(["C",(-o[0].x+6*o[1].x+o[2].x)/6,(-o[0].y+6*o[1].y+o[2].y)/6,(o[1].x+6*o[2].x-o[3].x)/6,(o[1].y+6*o[2].y-o[3].y)/6,o[2].x,o[2].y])}return e},c=function(t,n,e,r,i){var o=[];if(null===i&&null===r&&(r=e),t=+t,n=+n,e=+e,r=+r,null!==i){var a=Math.PI/180,u=t+e*Math.cos(-r*a),s=t+e*Math.cos(-i*a);o=[["M",u,n+e*Math.sin(-r*a)],["A",e,e,0,+(i-r>180),0,s,n+e*Math.sin(-i*a)]]}else o=[["M",t,n],["m",0,-r],["a",e,r,0,1,1,0,2*r],["a",e,r,0,1,1,0,-2*r],["z"]];return o},f=function(t){if(!(t=u(t))||!t.length)return[["M",0,0]];var n,e,r=[],i=0,o=0,a=0,f=0,l=0;"M"===t[0][0]&&(a=i=+t[0][1],f=o=+t[0][2],l++,r[0]=["M",i,o]);for(var h=3===t.length&&"M"===t[0][0]&&"R"===t[1][0].toUpperCase()&&"Z"===t[2][0].toUpperCase(),p=void 0,d=void 0,v=l,g=t.length;v1&&(e*=w=Math.sqrt(w),r*=w);var _=e*e,A=r*r,O=(o===a?-1:1)*Math.sqrt(Math.abs((_*A-_*M*M-A*x*x)/(_*M*M+A*x*x)));d=O*e*M/r+(t+u)/2,v=O*-r*x/e+(n+s)/2,l=Math.asin(((n-v)/r).toFixed(9)),h=Math.asin(((s-v)/r).toFixed(9)),l=th&&(l-=2*Math.PI),!a&&h>l&&(h-=2*Math.PI)}var S=h-l;if(Math.abs(S)>g){var P=h,C=u,T=s;h=l+g*(a&&h>l?1:-1),u=d+e*Math.cos(h),s=v+r*Math.sin(h),m=p(u,s,e,r,i,0,a,C,T,[h,P,d,v])}S=h-l;var j=Math.cos(l),k=Math.sin(l),E=Math.cos(h),B=Math.sin(h),I=Math.tan(S/4),D=4/3*e*I,N=4/3*r*I,F=[t,n],L=[t+D*k,n-N*j],R=[u+D*B,s-N*E],G=[u,s];if(L[0]=2*F[0]-L[0],L[1]=2*F[1]-L[1],c)return[L,R,G].concat(m);for(var V=[],W=0,q=(m=[L,R,G].concat(m).join().split(",")).length;W7){t[n].shift();for(var o=t[n];o.length;)u[n]="A",i&&(s[n]="A"),t.splice(n++,0,["C"].concat(o.splice(0,6)));t.splice(n,1),e=Math.max(r.length,i&&i.length||0)}},y=function(t,n,o,a,u){t&&n&&"M"===t[u][0]&&"M"!==n[u][0]&&(n.splice(u,0,["M",a.x,a.y]),o.bx=0,o.by=0,o.x=t[u][1],o.y=t[u][2],e=Math.max(r.length,i&&i.length||0))};e=Math.max(r.length,i&&i.length||0);for(var m=0;m1?1:s<0?0:s)/2,f=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],l=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],h=0,p=0;p<12;p++){var d=c*f[p]+c,v=y(d,t,e,i,a),g=y(d,n,r,o,u),m=v*v+g*g;h+=l[p]*Math.sqrt(m)}return c*h},b=function(t,n,e,r,i,o,a,u){for(var s,c,f,l,h=[],p=[[],[]],d=0;d<2;++d)if(0===d?(c=6*t-12*e+6*i,s=-3*t+9*e-9*i+3*a,f=3*e-3*t):(c=6*n-12*r+6*o,s=-3*n+9*r-9*o+3*u,f=3*r-3*n),Math.abs(s)<1e-12){if(Math.abs(c)<1e-12)continue;(l=-f/c)>0&&l<1&&h.push(l)}else{var v=c*c-4*f*s,g=Math.sqrt(v);if(!(v<0)){var y=(-c+g)/(2*s);y>0&&y<1&&h.push(y);var m=(-c-g)/(2*s);m>0&&m<1&&h.push(m)}}for(var b,x=h.length,M=x;x--;)b=1-(l=h[x]),p[0][x]=b*b*b*t+3*b*b*l*e+3*b*l*l*i+l*l*l*a,p[1][x]=b*b*b*n+3*b*b*l*r+3*b*l*l*o+l*l*l*u;return p[0][M]=t,p[1][M]=n,p[0][M+1]=a,p[1][M+1]=u,p[0].length=p[1].length=M+2,{min:{x:Math.min.apply(0,p[0]),y:Math.min.apply(0,p[1])},max:{x:Math.max.apply(0,p[0]),y:Math.max.apply(0,p[1])}}},x=function(t,n,e,r,i,o,a,u){if(!(Math.max(t,e)Math.max(i,a)||Math.max(n,r)Math.max(o,u))){var s=(t-e)*(o-u)-(n-r)*(i-a);if(s){var c=((t*r-n*e)*(i-a)-(t-e)*(i*u-o*a))/s,f=((t*r-n*e)*(o-u)-(n-r)*(i*u-o*a))/s,l=+c.toFixed(2),h=+f.toFixed(2);if(!(l<+Math.min(t,e).toFixed(2)||l>+Math.max(t,e).toFixed(2)||l<+Math.min(i,a).toFixed(2)||l>+Math.max(i,a).toFixed(2)||h<+Math.min(n,r).toFixed(2)||h>+Math.max(n,r).toFixed(2)||h<+Math.min(o,u).toFixed(2)||h>+Math.max(o,u).toFixed(2)))return{x:c,y:f}}}},M=function(t,n,e){return n>=t.x&&n<=t.x+t.width&&e>=t.y&&e<=t.y+t.height},w=function(t,n,e,r,i){if(i)return[["M",+t+ +i,n],["l",e-2*i,0],["a",i,i,0,0,1,i,i],["l",0,r-2*i],["a",i,i,0,0,1,-i,i],["l",2*i-e,0],["a",i,i,0,0,1,-i,-i],["l",0,2*i-r],["a",i,i,0,0,1,i,-i],["z"]];var o=[["M",t,n],["l",e,0],["l",0,r],["l",-e,0],["z"]];return o.parsePathArray=g,o},_=function(t,n,e,r){return null===t&&(t=n=e=r=0),null===n&&(n=t.y,e=t.width,r=t.height,t=t.x),{x:t,y:n,width:e,w:e,height:r,h:r,x2:t+e,y2:n+r,cx:t+e/2,cy:n+r/2,r1:Math.min(e,r)/2,r2:Math.max(e,r)/2,r0:Math.sqrt(e*e+r*r)/2,path:w(t,n,e,r),vb:[t,n,e,r].join(" ")}},A=function(t,n,e,i,o,a,u,s){Object(r.b)(t)||(t=[t,n,e,i,o,a,u,s]);var c=b.apply(null,t);return _(c.min.x,c.min.y,c.max.x-c.min.x,c.max.y-c.min.y)},O=function(t,n,e,r,i,o,a,u,s){var c=1-s,f=Math.pow(c,3),l=Math.pow(c,2),h=s*s,p=h*s,d=t+2*s*(e-t)+h*(i-2*e+t),v=n+2*s*(r-n)+h*(o-2*r+n),g=e+2*s*(i-e)+h*(a-2*i+e),y=r+2*s*(o-r)+h*(u-2*o+r);return{x:f*t+3*l*s*e+3*c*s*s*i+p*a,y:f*n+3*l*s*r+3*c*s*s*o+p*u,m:{x:d,y:v},n:{x:g,y:y},start:{x:c*t+s*e,y:c*n+s*r},end:{x:c*i+s*a,y:c*o+s*u},alpha:90-180*Math.atan2(d-g,v-y)/Math.PI}},S=function(t,n,e){if(!function(t,n){return t=_(t),n=_(n),M(n,t.x,t.y)||M(n,t.x2,t.y)||M(n,t.x,t.y2)||M(n,t.x2,t.y2)||M(t,n.x,n.y)||M(t,n.x2,n.y)||M(t,n.x,n.y2)||M(t,n.x2,n.y2)||(t.xn.x||n.xt.x)&&(t.yn.y||n.yt.y)}(A(t),A(n)))return e?0:[];for(var r=~~(m.apply(0,t)/8),i=~~(m.apply(0,n)/8),o=[],a=[],u={},s=e?0:[],c=0;c=0&&w<=1&&S>=0&&S<=1&&(e?s+=1:s.push({x:b.x,y:b.y,t1:w,t2:S}))}}return s},P=function(t,n){return function(t,n,e){var r,i,o,a,u,s,c,f,l,h;t=d(t),n=d(n);for(var p=e?0:[],v=0,g=t.length;v=3&&(3===t.length&&n.push("Q"),n=n.concat(t[1])),2===t.length&&n.push("L"),n=n.concat(t[t.length-1])}))}(t,n,e));else{var i=[].concat(t);"M"===i[0]&&(i[0]="L");for(var o=0;o<=e-1;o++)r.push(i)}return r},j=function(t,n){if(1===t.length)return t;var e=t.length-1,r=n.length-1,i=e/r,o=[];if(1===t.length&&"M"===t[0][0]){for(var a=0;a=0;s--)a=o[s].index,"add"===o[s].type?t.splice(a,0,[].concat(t[a])):t.splice(a,1)}var l=i-(r=t.length);if(r0)){t[r]=n[r];break}e=I(e,t[r-1],1)}t[r]=["Q"].concat(e.reduce((function(t,n){return t.concat(n)}),[]));break;case"T":t[r]=["T"].concat(e[0]);break;case"C":if(e.length<3){if(!(r>0)){t[r]=n[r];break}e=I(e,t[r-1],2)}t[r]=["C"].concat(e.reduce((function(t,n){return t.concat(n)}),[]));break;case"S":if(e.length<2){if(!(r>0)){t[r]=n[r];break}e=I(e,t[r-1],1)}t[r]=["S"].concat(e.reduce((function(t,n){return t.concat(n)}),[]));break;default:t[r]=n[r]}return t}},function(t,n,e){"use strict";e.d(n,"b",(function(){return o})),e.d(n,"c",(function(){return a})),e.d(n,"a",(function(){return u}));var r=e(1),i=e(16);function o(t,n,e){var i=1;return Object(r.h)(t)&&(i=t.split("\n").length),i>1?n*i+function(t,n){return n?n-t:.14*t}(n,e)*(i-1):n}function a(t,n){var e=Object(i.a)(),o=0;if(Object(r.e)(t)||""===t)return o;if(e.save(),e.font=n,Object(r.h)(t)&&t.includes("\n")){var a=t.split("\n");Object(r.a)(a,(function(t){var n=e.measureText(t).width;o0)}));return u.length>0?(Object(o.a)(u,(function(t){var n=t.getBBox();i.push(n.minX,n.maxX),a.push(n.minY,n.maxY)})),t=Math.min.apply(null,i),n=Math.max.apply(null,i),e=Math.min.apply(null,a),r=Math.max.apply(null,a)):(t=0,n=0,e=0,r=0),{x:t,y:e,minX:t,minY:e,maxX:n,maxY:r,width:n-t,height:r-e}},n.prototype.getCanvasBBox=function(){var t=1/0,n=-1/0,e=1/0,r=-1/0,i=[],a=[],u=this.getChildren().filter((function(t){return t.get("visible")&&(!t.isGroup()||t.isGroup()&&t.getChildren().length>0)}));return u.length>0?(Object(o.a)(u,(function(t){var n=t.getCanvasBBox();i.push(n.minX,n.maxX),a.push(n.minY,n.maxY)})),t=Math.min.apply(null,i),n=Math.max.apply(null,i),e=Math.min.apply(null,a),r=Math.max.apply(null,a)):(t=0,n=0,e=0,r=0),{x:t,y:e,minX:t,minY:e,maxX:n,maxY:r,width:n-t,height:r-e}},n.prototype.getDefaultCfg=function(){var n=t.prototype.getDefaultCfg.call(this);return n.children=[],n},n.prototype.onAttrChange=function(n,e,r){if(t.prototype.onAttrChange.call(this,n,e,r),"matrix"===n){var i=this.getTotalMatrix();this._applyChildrenMarix(i)}},n.prototype.applyMatrix=function(n){var e=this.getTotalMatrix();t.prototype.applyMatrix.call(this,n);var r=this.getTotalMatrix();r!==e&&this._applyChildrenMarix(r)},n.prototype._applyChildrenMarix=function(t){var n=this.getChildren();Object(o.a)(n,(function(n){n.applyMatrix(t)}))},n.prototype.addShape=function(){for(var t=[],n=0;n=0;a--){var u=t[a];if(Object(o.b)(u)&&(u.isGroup()?i=u.getShape(n,e,r):u.isHit(n,e)&&(i=u)),i)break}return i},n.prototype.add=function(t){var n=this.getCanvas(),e=this.getChildren(),r=this.get("timeline"),i=t.getParent();i&&function(t,n,e){void 0===e&&(e=!0),e?n.destroy():(n.set("parent",null),n.set("canvas",null)),Object(o.j)(t.getChildren(),n)}(i,t,!1),t.set("parent",this),n&&function t(n,e){if(n.set("canvas",e),n.isGroup()){var r=n.get("children");r.length&&r.forEach((function(n){t(n,e)}))}}(t,n),r&&function t(n,e){if(n.set("timeline",e),n.isGroup()){var r=n.get("children");r.length&&r.forEach((function(n){t(n,e)}))}}(t,r),e.push(t),t.onCanvasChange("add"),this._applyElementMatrix(t)},n.prototype._applyElementMatrix=function(t){var n=this.getTotalMatrix();n&&t.applyMatrix(n)},n.prototype.getChildren=function(){return this.get("children")},n.prototype.sort=function(){var t,n=this.getChildren();Object(o.a)(n,(function(t,n){return t._INDEX=n,t})),n.sort((t=function(t,n){return t.get("zIndex")-n.get("zIndex")},function(n,e){var r=t(n,e);return 0===r?n._INDEX-e._INDEX:r})),this.onCanvasChange("sort")},n.prototype.clear=function(){if(this.set("clearing",!0),!this.destroyed){for(var t=this.getChildren(),n=t.length-1;n>=0;n--)t[n].destroy();this.set("children",[]),this.onCanvasChange("clear"),this.set("clearing",!1)}},n.prototype.destroy=function(){this.get("destroyed")||(this.clear(),t.prototype.destroy.call(this))},n.prototype.getFirst=function(){return this.getChildByIndex(0)},n.prototype.getLast=function(){var t=this.getChildren();return this.getChildByIndex(t.length-1)},n.prototype.getChildByIndex=function(t){return this.getChildren()[t]},n.prototype.getCount=function(){return this.getChildren().length},n.prototype.contain=function(t){return this.getChildren().indexOf(t)>-1},n.prototype.removeChild=function(t,n){void 0===n&&(n=!0),this.contain(t)&&t.remove(n)},n.prototype.findAll=function(t){var n=[],e=this.getChildren();return Object(o.a)(e,(function(e){t(e)&&n.push(e),e.isGroup()&&(n=n.concat(e.findAll(t)))})),n},n.prototype.find=function(t){var n=null,e=this.getChildren();return Object(o.a)(e,(function(e){if(t(e)?n=e:e.isGroup()&&(n=e.find(t)),n)return!1})),n},n.prototype.findById=function(t){return this.find((function(n){return n.get("id")===t}))},n.prototype.findByClassName=function(t){return this.find((function(n){return n.get("className")===t}))},n.prototype.findAllByName=function(t){return this.findAll((function(n){return n.get("name")===t}))},n}(i.a);n.a=u},function(t,n,e){"use strict";var r={};e.r(r),e.d(r,"create",(function(){return f})),e.d(r,"fromMat4",(function(){return l})),e.d(r,"clone",(function(){return h})),e.d(r,"copy",(function(){return p})),e.d(r,"fromValues",(function(){return d})),e.d(r,"set",(function(){return v})),e.d(r,"identity",(function(){return g})),e.d(r,"transpose",(function(){return y})),e.d(r,"invert",(function(){return m})),e.d(r,"adjoint",(function(){return b})),e.d(r,"determinant",(function(){return x})),e.d(r,"multiply",(function(){return M})),e.d(r,"translate",(function(){return w})),e.d(r,"rotate",(function(){return _})),e.d(r,"scale",(function(){return A})),e.d(r,"fromTranslation",(function(){return O})),e.d(r,"fromRotation",(function(){return S})),e.d(r,"fromScaling",(function(){return P})),e.d(r,"fromMat2d",(function(){return C})),e.d(r,"fromQuat",(function(){return T})),e.d(r,"normalFromMat4",(function(){return j})),e.d(r,"projection",(function(){return k})),e.d(r,"str",(function(){return E})),e.d(r,"frob",(function(){return B})),e.d(r,"add",(function(){return I})),e.d(r,"subtract",(function(){return D})),e.d(r,"multiplyScalar",(function(){return N})),e.d(r,"multiplyScalarAndAdd",(function(){return F})),e.d(r,"exactEquals",(function(){return L})),e.d(r,"equals",(function(){return R})),e.d(r,"mul",(function(){return G})),e.d(r,"sub",(function(){return V}));var i={};e.r(i),e.d(i,"create",(function(){return W})),e.d(i,"clone",(function(){return q})),e.d(i,"fromValues",(function(){return X})),e.d(i,"copy",(function(){return Y})),e.d(i,"set",(function(){return H})),e.d(i,"add",(function(){return z})),e.d(i,"subtract",(function(){return Q})),e.d(i,"multiply",(function(){return $})),e.d(i,"divide",(function(){return U})),e.d(i,"ceil",(function(){return Z})),e.d(i,"floor",(function(){return K})),e.d(i,"min",(function(){return J})),e.d(i,"max",(function(){return tt})),e.d(i,"round",(function(){return nt})),e.d(i,"scale",(function(){return et})),e.d(i,"scaleAndAdd",(function(){return rt})),e.d(i,"distance",(function(){return it})),e.d(i,"squaredDistance",(function(){return ot})),e.d(i,"length",(function(){return at})),e.d(i,"squaredLength",(function(){return ut})),e.d(i,"negate",(function(){return st})),e.d(i,"inverse",(function(){return ct})),e.d(i,"normalize",(function(){return ft})),e.d(i,"dot",(function(){return lt})),e.d(i,"cross",(function(){return ht})),e.d(i,"lerp",(function(){return pt})),e.d(i,"random",(function(){return dt})),e.d(i,"transformMat2",(function(){return vt})),e.d(i,"transformMat2d",(function(){return gt})),e.d(i,"transformMat3",(function(){return yt})),e.d(i,"transformMat4",(function(){return mt})),e.d(i,"rotate",(function(){return bt})),e.d(i,"angle",(function(){return xt})),e.d(i,"zero",(function(){return Mt})),e.d(i,"str",(function(){return wt})),e.d(i,"exactEquals",(function(){return _t})),e.d(i,"equals",(function(){return At})),e.d(i,"len",(function(){return St})),e.d(i,"sub",(function(){return Pt})),e.d(i,"mul",(function(){return Ct})),e.d(i,"div",(function(){return Tt})),e.d(i,"dist",(function(){return jt})),e.d(i,"sqrDist",(function(){return kt})),e.d(i,"sqrLen",(function(){return Et})),e.d(i,"forEach",(function(){return Bt}));var o={};e.r(o),e.d(o,"leftTranslate",(function(){return It})),e.d(o,"leftRotate",(function(){return Dt})),e.d(o,"leftScale",(function(){return Nt})),e.d(o,"transform",(function(){return Ft})),e.d(o,"direction",(function(){return Lt})),e.d(o,"angleTo",(function(){return Rt})),e.d(o,"vertical",(function(){return Gt}));var a=e(7),u=e(0),s="undefined"!=typeof Float32Array?Float32Array:Array,c=Math.random;Math.PI;function f(){var t=new s(9);return s!=Float32Array&&(t[1]=0,t[2]=0,t[3]=0,t[5]=0,t[6]=0,t[7]=0),t[0]=1,t[4]=1,t[8]=1,t}function l(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[4],t[4]=n[5],t[5]=n[6],t[6]=n[8],t[7]=n[9],t[8]=n[10],t}function h(t){var n=new s(9);return n[0]=t[0],n[1]=t[1],n[2]=t[2],n[3]=t[3],n[4]=t[4],n[5]=t[5],n[6]=t[6],n[7]=t[7],n[8]=t[8],n}function p(t,n){return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t[6]=n[6],t[7]=n[7],t[8]=n[8],t}function d(t,n,e,r,i,o,a,u,c){var f=new s(9);return f[0]=t,f[1]=n,f[2]=e,f[3]=r,f[4]=i,f[5]=o,f[6]=a,f[7]=u,f[8]=c,f}function v(t,n,e,r,i,o,a,u,s,c){return t[0]=n,t[1]=e,t[2]=r,t[3]=i,t[4]=o,t[5]=a,t[6]=u,t[7]=s,t[8]=c,t}function g(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}function y(t,n){if(t===n){var e=n[1],r=n[2],i=n[5];t[1]=n[3],t[2]=n[6],t[3]=e,t[5]=n[7],t[6]=r,t[7]=i}else t[0]=n[0],t[1]=n[3],t[2]=n[6],t[3]=n[1],t[4]=n[4],t[5]=n[7],t[6]=n[2],t[7]=n[5],t[8]=n[8];return t}function m(t,n){var e=n[0],r=n[1],i=n[2],o=n[3],a=n[4],u=n[5],s=n[6],c=n[7],f=n[8],l=f*a-u*c,h=-f*o+u*s,p=c*o-a*s,d=e*l+r*h+i*p;return d?(d=1/d,t[0]=l*d,t[1]=(-f*r+i*c)*d,t[2]=(u*r-i*a)*d,t[3]=h*d,t[4]=(f*e-i*s)*d,t[5]=(-u*e+i*o)*d,t[6]=p*d,t[7]=(-c*e+r*s)*d,t[8]=(a*e-r*o)*d,t):null}function b(t,n){var e=n[0],r=n[1],i=n[2],o=n[3],a=n[4],u=n[5],s=n[6],c=n[7],f=n[8];return t[0]=a*f-u*c,t[1]=i*c-r*f,t[2]=r*u-i*a,t[3]=u*s-o*f,t[4]=e*f-i*s,t[5]=i*o-e*u,t[6]=o*c-a*s,t[7]=r*s-e*c,t[8]=e*a-r*o,t}function x(t){var n=t[0],e=t[1],r=t[2],i=t[3],o=t[4],a=t[5],u=t[6],s=t[7],c=t[8];return n*(c*o-a*s)+e*(-c*i+a*u)+r*(s*i-o*u)}function M(t,n,e){var r=n[0],i=n[1],o=n[2],a=n[3],u=n[4],s=n[5],c=n[6],f=n[7],l=n[8],h=e[0],p=e[1],d=e[2],v=e[3],g=e[4],y=e[5],m=e[6],b=e[7],x=e[8];return t[0]=h*r+p*a+d*c,t[1]=h*i+p*u+d*f,t[2]=h*o+p*s+d*l,t[3]=v*r+g*a+y*c,t[4]=v*i+g*u+y*f,t[5]=v*o+g*s+y*l,t[6]=m*r+b*a+x*c,t[7]=m*i+b*u+x*f,t[8]=m*o+b*s+x*l,t}function w(t,n,e){var r=n[0],i=n[1],o=n[2],a=n[3],u=n[4],s=n[5],c=n[6],f=n[7],l=n[8],h=e[0],p=e[1];return t[0]=r,t[1]=i,t[2]=o,t[3]=a,t[4]=u,t[5]=s,t[6]=h*r+p*a+c,t[7]=h*i+p*u+f,t[8]=h*o+p*s+l,t}function _(t,n,e){var r=n[0],i=n[1],o=n[2],a=n[3],u=n[4],s=n[5],c=n[6],f=n[7],l=n[8],h=Math.sin(e),p=Math.cos(e);return t[0]=p*r+h*a,t[1]=p*i+h*u,t[2]=p*o+h*s,t[3]=p*a-h*r,t[4]=p*u-h*i,t[5]=p*s-h*o,t[6]=c,t[7]=f,t[8]=l,t}function A(t,n,e){var r=e[0],i=e[1];return t[0]=r*n[0],t[1]=r*n[1],t[2]=r*n[2],t[3]=i*n[3],t[4]=i*n[4],t[5]=i*n[5],t[6]=n[6],t[7]=n[7],t[8]=n[8],t}function O(t,n){return t[0]=1,t[1]=0,t[2]=0,t[3]=0,t[4]=1,t[5]=0,t[6]=n[0],t[7]=n[1],t[8]=1,t}function S(t,n){var e=Math.sin(n),r=Math.cos(n);return t[0]=r,t[1]=e,t[2]=0,t[3]=-e,t[4]=r,t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}function P(t,n){return t[0]=n[0],t[1]=0,t[2]=0,t[3]=0,t[4]=n[1],t[5]=0,t[6]=0,t[7]=0,t[8]=1,t}function C(t,n){return t[0]=n[0],t[1]=n[1],t[2]=0,t[3]=n[2],t[4]=n[3],t[5]=0,t[6]=n[4],t[7]=n[5],t[8]=1,t}function T(t,n){var e=n[0],r=n[1],i=n[2],o=n[3],a=e+e,u=r+r,s=i+i,c=e*a,f=r*a,l=r*u,h=i*a,p=i*u,d=i*s,v=o*a,g=o*u,y=o*s;return t[0]=1-l-d,t[3]=f-y,t[6]=h+g,t[1]=f+y,t[4]=1-c-d,t[7]=p-v,t[2]=h-g,t[5]=p+v,t[8]=1-c-l,t}function j(t,n){var e=n[0],r=n[1],i=n[2],o=n[3],a=n[4],u=n[5],s=n[6],c=n[7],f=n[8],l=n[9],h=n[10],p=n[11],d=n[12],v=n[13],g=n[14],y=n[15],m=e*u-r*a,b=e*s-i*a,x=e*c-o*a,M=r*s-i*u,w=r*c-o*u,_=i*c-o*s,A=f*v-l*d,O=f*g-h*d,S=f*y-p*d,P=l*g-h*v,C=l*y-p*v,T=h*y-p*g,j=m*T-b*C+x*P+M*S-w*O+_*A;return j?(j=1/j,t[0]=(u*T-s*C+c*P)*j,t[1]=(s*S-a*T-c*O)*j,t[2]=(a*C-u*S+c*A)*j,t[3]=(i*C-r*T-o*P)*j,t[4]=(e*T-i*S+o*O)*j,t[5]=(r*S-e*C-o*A)*j,t[6]=(v*_-g*w+y*M)*j,t[7]=(g*x-d*_-y*b)*j,t[8]=(d*w-v*x+y*m)*j,t):null}function k(t,n,e){return t[0]=2/n,t[1]=0,t[2]=0,t[3]=0,t[4]=-2/e,t[5]=0,t[6]=-1,t[7]=1,t[8]=1,t}function E(t){return"mat3("+t[0]+", "+t[1]+", "+t[2]+", "+t[3]+", "+t[4]+", "+t[5]+", "+t[6]+", "+t[7]+", "+t[8]+")"}function B(t){return Math.hypot(t[0],t[1],t[2],t[3],t[4],t[5],t[6],t[7],t[8])}function I(t,n,e){return t[0]=n[0]+e[0],t[1]=n[1]+e[1],t[2]=n[2]+e[2],t[3]=n[3]+e[3],t[4]=n[4]+e[4],t[5]=n[5]+e[5],t[6]=n[6]+e[6],t[7]=n[7]+e[7],t[8]=n[8]+e[8],t}function D(t,n,e){return t[0]=n[0]-e[0],t[1]=n[1]-e[1],t[2]=n[2]-e[2],t[3]=n[3]-e[3],t[4]=n[4]-e[4],t[5]=n[5]-e[5],t[6]=n[6]-e[6],t[7]=n[7]-e[7],t[8]=n[8]-e[8],t}function N(t,n,e){return t[0]=n[0]*e,t[1]=n[1]*e,t[2]=n[2]*e,t[3]=n[3]*e,t[4]=n[4]*e,t[5]=n[5]*e,t[6]=n[6]*e,t[7]=n[7]*e,t[8]=n[8]*e,t}function F(t,n,e,r){return t[0]=n[0]+e[0]*r,t[1]=n[1]+e[1]*r,t[2]=n[2]+e[2]*r,t[3]=n[3]+e[3]*r,t[4]=n[4]+e[4]*r,t[5]=n[5]+e[5]*r,t[6]=n[6]+e[6]*r,t[7]=n[7]+e[7]*r,t[8]=n[8]+e[8]*r,t}function L(t,n){return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]&&t[3]===n[3]&&t[4]===n[4]&&t[5]===n[5]&&t[6]===n[6]&&t[7]===n[7]&&t[8]===n[8]}function R(t,n){var e=t[0],r=t[1],i=t[2],o=t[3],a=t[4],u=t[5],s=t[6],c=t[7],f=t[8],l=n[0],h=n[1],p=n[2],d=n[3],v=n[4],g=n[5],y=n[6],m=n[7],b=n[8];return Math.abs(e-l)<=1e-6*Math.max(1,Math.abs(e),Math.abs(l))&&Math.abs(r-h)<=1e-6*Math.max(1,Math.abs(r),Math.abs(h))&&Math.abs(i-p)<=1e-6*Math.max(1,Math.abs(i),Math.abs(p))&&Math.abs(o-d)<=1e-6*Math.max(1,Math.abs(o),Math.abs(d))&&Math.abs(a-v)<=1e-6*Math.max(1,Math.abs(a),Math.abs(v))&&Math.abs(u-g)<=1e-6*Math.max(1,Math.abs(u),Math.abs(g))&&Math.abs(s-y)<=1e-6*Math.max(1,Math.abs(s),Math.abs(y))&&Math.abs(c-m)<=1e-6*Math.max(1,Math.abs(c),Math.abs(m))&&Math.abs(f-b)<=1e-6*Math.max(1,Math.abs(f),Math.abs(b))}Math.hypot||(Math.hypot=function(){for(var t=0,n=arguments.length;n--;)t+=arguments[n]*arguments[n];return Math.sqrt(t)});var G=M,V=D;function W(){var t=new s(2);return s!=Float32Array&&(t[0]=0,t[1]=0),t}function q(t){var n=new s(2);return n[0]=t[0],n[1]=t[1],n}function X(t,n){var e=new s(2);return e[0]=t,e[1]=n,e}function Y(t,n){return t[0]=n[0],t[1]=n[1],t}function H(t,n,e){return t[0]=n,t[1]=e,t}function z(t,n,e){return t[0]=n[0]+e[0],t[1]=n[1]+e[1],t}function Q(t,n,e){return t[0]=n[0]-e[0],t[1]=n[1]-e[1],t}function $(t,n,e){return t[0]=n[0]*e[0],t[1]=n[1]*e[1],t}function U(t,n,e){return t[0]=n[0]/e[0],t[1]=n[1]/e[1],t}function Z(t,n){return t[0]=Math.ceil(n[0]),t[1]=Math.ceil(n[1]),t}function K(t,n){return t[0]=Math.floor(n[0]),t[1]=Math.floor(n[1]),t}function J(t,n,e){return t[0]=Math.min(n[0],e[0]),t[1]=Math.min(n[1],e[1]),t}function tt(t,n,e){return t[0]=Math.max(n[0],e[0]),t[1]=Math.max(n[1],e[1]),t}function nt(t,n){return t[0]=Math.round(n[0]),t[1]=Math.round(n[1]),t}function et(t,n,e){return t[0]=n[0]*e,t[1]=n[1]*e,t}function rt(t,n,e,r){return t[0]=n[0]+e[0]*r,t[1]=n[1]+e[1]*r,t}function it(t,n){var e=n[0]-t[0],r=n[1]-t[1];return Math.hypot(e,r)}function ot(t,n){var e=n[0]-t[0],r=n[1]-t[1];return e*e+r*r}function at(t){var n=t[0],e=t[1];return Math.hypot(n,e)}function ut(t){var n=t[0],e=t[1];return n*n+e*e}function st(t,n){return t[0]=-n[0],t[1]=-n[1],t}function ct(t,n){return t[0]=1/n[0],t[1]=1/n[1],t}function ft(t,n){var e=n[0],r=n[1],i=e*e+r*r;return i>0&&(i=1/Math.sqrt(i)),t[0]=n[0]*i,t[1]=n[1]*i,t}function lt(t,n){return t[0]*n[0]+t[1]*n[1]}function ht(t,n,e){var r=n[0]*e[1]-n[1]*e[0];return t[0]=t[1]=0,t[2]=r,t}function pt(t,n,e,r){var i=n[0],o=n[1];return t[0]=i+r*(e[0]-i),t[1]=o+r*(e[1]-o),t}function dt(t,n){n=n||1;var e=2*c()*Math.PI;return t[0]=Math.cos(e)*n,t[1]=Math.sin(e)*n,t}function vt(t,n,e){var r=n[0],i=n[1];return t[0]=e[0]*r+e[2]*i,t[1]=e[1]*r+e[3]*i,t}function gt(t,n,e){var r=n[0],i=n[1];return t[0]=e[0]*r+e[2]*i+e[4],t[1]=e[1]*r+e[3]*i+e[5],t}function yt(t,n,e){var r=n[0],i=n[1];return t[0]=e[0]*r+e[3]*i+e[6],t[1]=e[1]*r+e[4]*i+e[7],t}function mt(t,n,e){var r=n[0],i=n[1];return t[0]=e[0]*r+e[4]*i+e[12],t[1]=e[1]*r+e[5]*i+e[13],t}function bt(t,n,e,r){var i=n[0]-e[0],o=n[1]-e[1],a=Math.sin(r),u=Math.cos(r);return t[0]=i*u-o*a+e[0],t[1]=i*a+o*u+e[1],t}function xt(t,n){var e=t[0],r=t[1],i=n[0],o=n[1],a=Math.sqrt(e*e+r*r)*Math.sqrt(i*i+o*o),u=a&&(e*i+r*o)/a;return Math.acos(Math.min(Math.max(u,-1),1))}function Mt(t){return t[0]=0,t[1]=0,t}function wt(t){return"vec2("+t[0]+", "+t[1]+")"}function _t(t,n){return t[0]===n[0]&&t[1]===n[1]}function At(t,n){var e=t[0],r=t[1],i=n[0],o=n[1];return Math.abs(e-i)<=1e-6*Math.max(1,Math.abs(e),Math.abs(i))&&Math.abs(r-o)<=1e-6*Math.max(1,Math.abs(r),Math.abs(o))}var Ot,St=at,Pt=Q,Ct=$,Tt=U,jt=it,kt=ot,Et=ut,Bt=(Ot=W(),function(t,n,e,r,i,o){var a,u;for(n||(n=2),e||(e=0),u=r?Math.min(r*n+e,t.length):t.length,a=e;a=0;return e?o?2*Math.PI-r:r:o?r:2*Math.PI-r}function Gt(t,n,e){return e?(t[0]=n[1],t[1]=-1*n[0]):(t[0]=-1*n[1],t[1]=n[0]),t}var Vt=e(1),Wt=e(5),qt=e(17),Xt=o.transform,Yt=["zIndex","capture","visible","type"],Ht=["repeat"];function zt(t,n){var e={},r=n.attrs;for(var i in t)e[i]=r[i];return e}function Qt(t,n){var e={},r=n.attr();return Object(u.a)(t,(function(t,n){-1!==Ht.indexOf(n)||Object(u.c)(r[n],t)||(e[n]=t)})),e}function $t(t,n){if(n.onFrame)return t;var e=n.startTime,r=n.delay,i=n.duration,o=Object.prototype.hasOwnProperty;return Object(u.a)(t,(function(t){e+rt.delay&&Object(u.a)(n.toAttrs,(function(n,e){o.call(t.toAttrs,e)&&(delete t.toAttrs[e],delete t.fromAttrs[e])}))})),t}var Ut=function(t){function n(n){var e=t.call(this,n)||this;e.attrs={};var r=e.getDefaultAttrs();return Object(u.j)(r,n.attrs),e.attrs=r,e.initAttrs(r),e.initAnimate(),e}return Object(a.a)(n,t),n.prototype.getDefaultCfg=function(){return{visible:!0,capture:!0,zIndex:0}},n.prototype.getDefaultAttrs=function(){return{matrix:this.getDefaultMatrix(),opacity:1}},n.prototype.onCanvasChange=function(t){},n.prototype.initAttrs=function(t){},n.prototype.initAnimate=function(){this.set("animable",!0),this.set("animating",!1)},n.prototype.isGroup=function(){return!1},n.prototype.getParent=function(){return this.get("parent")},n.prototype.getCanvas=function(){return this.get("canvas")},n.prototype.attr=function(){for(var t,n=[],e=0;e0?r=$t(r,b):e.addAnimator(this),r.push(b),this.set("animations",r),this.set("_pause",{isPaused:!1})}},n.prototype.stopAnimate=function(t){var n=this;void 0===t&&(t=!0);var e=this.get("animations");Object(u.a)(e,(function(e){t&&(e.onFrame?n.attr(e.onFrame(1)):n.attr(e.toAttrs)),e.callback&&e.callback()})),this.set("animating",!1),this.set("animations",[])},n.prototype.pauseAnimate=function(){var t=this.get("timeline"),n=this.get("animations"),e=t.getTime();return Object(u.a)(n,(function(t){t._paused=!0,t._pauseTime=e,t.pauseCallback&&t.pauseCallback()})),this.set("_pause",{isPaused:!0,pauseTime:e}),this},n.prototype.resumeAnimate=function(){var t=this.get("timeline").getTime(),n=this.get("animations"),e=this.get("_pause").pauseTime;return Object(u.a)(n,(function(n){n.startTime=n.startTime+(t-e),n._paused=!1,n._pauseTime=null,n.resumeCallback&&n.resumeCallback()})),this.set("_pause",{isPaused:!1}),this.set("animations",n),this},n.prototype.emitDelegation=function(t,n){var e,r=this,i=n.propagationPath;this.getEvents();"mouseenter"===t?e=n.fromShape:"mouseleave"===t&&(e=n.toShape);for(var o=function(t){var o=i[t],s=o.get("name");if(s){if((o.isGroup()||o.isCanvas&&o.isCanvas())&&e&&Object(Vt.g)(o,e))return"break";Object(u.b)(s)?Object(u.a)(s,(function(t){r.emitDelegateEvent(o,t,n)})):a.emitDelegateEvent(o,s,n)}},a=this,s=0;s1)for(var e=1;e=t&&e.minY<=n&&e.maxY>=n},n.prototype.afterAttrsChange=function(n){t.prototype.afterAttrsChange.call(this,n),this.clearCacheBBox()},n.prototype.getBBox=function(){var t=this.cfg.bbox;return t||(t=this.calculateBBox(),this.set("bbox",t)),t},n.prototype.getCanvasBBox=function(){var t=this.cfg.canvasBBox;return t||(t=this.calculateCanvasBBox(),this.set("canvasBBox",t)),t},n.prototype.applyMatrix=function(n){t.prototype.applyMatrix.call(this,n),this.set("canvasBBox",null)},n.prototype.calculateCanvasBBox=function(){var t=this.getBBox(),n=this.getTotalMatrix(),e=t.minX,r=t.minY,i=t.maxX,a=t.maxY;if(n){var u=Object(o.c)(n,[t.minX,t.minY]),s=Object(o.c)(n,[t.maxX,t.minY]),c=Object(o.c)(n,[t.minX,t.maxY]),f=Object(o.c)(n,[t.maxX,t.maxY]);e=Math.min(u[0],s[0],c[0],f[0]),i=Math.max(u[0],s[0],c[0],f[0]),r=Math.min(u[1],s[1],c[1],f[1]),a=Math.max(u[1],s[1],c[1],f[1])}var l=this.attrs;if(l.shadowColor){var h=l.shadowBlur,p=void 0===h?0:h,d=l.shadowOffsetX,v=void 0===d?0:d,g=l.shadowOffsetY,y=void 0===g?0:g,m=e-p+v,b=i+p+v,x=r-p+y,M=a+p+y;e=Math.min(e,m),i=Math.max(i,b),r=Math.min(r,x),a=Math.max(a,M)}return{x:e,y:r,minX:e,minY:r,maxX:i,maxY:a,width:i-e,height:a-r}},n.prototype.clearCacheBBox=function(){this.set("bbox",null),this.set("canvasBBox",null)},n.prototype.isClipShape=function(){return this.get("isClipShape")},n.prototype.isInShape=function(t,n){return!1},n.prototype.isOnlyHitBox=function(){return!1},n.prototype.isHit=function(t,n){var e=this.get("startArrowShape"),r=this.get("endArrowShape"),i=[t,n,1],o=(i=this.invertFromMatrix(i))[0],a=i[1],u=this._isInBBox(o,a);if(this.isOnlyHitBox())return u;if(u&&!this.isClipped(o,a)){if(this.isInShape(o,a))return!0;if(e&&e.isHit(o,a))return!0;if(r&&r.isHit(o,a))return!0}return!1},n}(i.a);n.a=a},function(t,n,e){"use strict";var r={};e.r(r),e.d(r,"easeLinear",(function(){return S})),e.d(r,"easeQuad",(function(){return T})),e.d(r,"easeQuadIn",(function(){return P})),e.d(r,"easeQuadOut",(function(){return C})),e.d(r,"easeQuadInOut",(function(){return T})),e.d(r,"easeCubic",(function(){return E})),e.d(r,"easeCubicIn",(function(){return j})),e.d(r,"easeCubicOut",(function(){return k})),e.d(r,"easeCubicInOut",(function(){return E})),e.d(r,"easePoly",(function(){return D})),e.d(r,"easePolyIn",(function(){return B})),e.d(r,"easePolyOut",(function(){return I})),e.d(r,"easePolyInOut",(function(){return D})),e.d(r,"easeSin",(function(){return G})),e.d(r,"easeSinIn",(function(){return L})),e.d(r,"easeSinOut",(function(){return R})),e.d(r,"easeSinInOut",(function(){return G})),e.d(r,"easeExp",(function(){return X})),e.d(r,"easeExpIn",(function(){return W})),e.d(r,"easeExpOut",(function(){return q})),e.d(r,"easeExpInOut",(function(){return X})),e.d(r,"easeCircle",(function(){return z})),e.d(r,"easeCircleIn",(function(){return Y})),e.d(r,"easeCircleOut",(function(){return H})),e.d(r,"easeCircleInOut",(function(){return z})),e.d(r,"easeBounce",(function(){return U})),e.d(r,"easeBounceIn",(function(){return $})),e.d(r,"easeBounceOut",(function(){return U})),e.d(r,"easeBounceInOut",(function(){return Z})),e.d(r,"easeBack",(function(){return tt})),e.d(r,"easeBackIn",(function(){return K})),e.d(r,"easeBackOut",(function(){return J})),e.d(r,"easeBackInOut",(function(){return tt})),e.d(r,"easeElastic",(function(){return rt})),e.d(r,"easeElasticIn",(function(){return et})),e.d(r,"easeElasticOut",(function(){return rt})),e.d(r,"easeElasticInOut",(function(){return it}));var i,o,a=e(7),u=e(29),s=e(18),c=e(1),f=e(0),l=0,h=0,p=0,d=0,v=0,g=0,y="object"==typeof performance&&performance.now?performance:Date,m="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};function b(){return v||(m(x),v=y.now()+g)}function x(){v=0}function M(){this._call=this._time=this._next=null}function w(t,n,e){var r=new M;return r.restart(t,n,e),r}function _(){v=(d=y.now())+g,l=h=0;try{!function(){b(),++l;for(var t,n=i;n;)(t=v-n._time)>=0&&n._call.call(null,t),n=n._next;--l}()}finally{l=0,function(){var t,n,e=i,r=1/0;for(;e;)e._call?(r>e._time&&(r=e._time),t=e,e=e._next):(n=e._next,e._next=null,e=t?t._next=n:i=n);o=t,O(r)}(),v=0}}function A(){var t=y.now(),n=t-d;n>1e3&&(g-=n,d=t)}function O(t){l||(h&&(h=clearTimeout(h)),t-v>24?(t<1/0&&(h=setTimeout(_,t-y.now()-g)),p&&(p=clearInterval(p))):(p||(d=y.now(),p=setInterval(A,1e3)),l=1,m(_)))}function S(t){return+t}function P(t){return t*t}function C(t){return t*(2-t)}function T(t){return((t*=2)<=1?t*t:--t*(2-t)+1)/2}function j(t){return t*t*t}function k(t){return--t*t*t+1}function E(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}M.prototype=w.prototype={constructor:M,restart:function(t,n,e){if("function"!=typeof t)throw new TypeError("callback is not a function");e=(null==e?b():+e)+(null==n?0:+n),this._next||o===this||(o?o._next=this:i=this,o=this),this._call=t,this._time=e,O()},stop:function(){this._call&&(this._call=null,this._time=1/0,O())}};var B=function t(n){function e(t){return Math.pow(t,n)}return n=+n,e.exponent=t,e}(3),I=function t(n){function e(t){return 1-Math.pow(1-t,n)}return n=+n,e.exponent=t,e}(3),D=function t(n){function e(t){return((t*=2)<=1?Math.pow(t,n):2-Math.pow(2-t,n))/2}return n=+n,e.exponent=t,e}(3),N=Math.PI,F=N/2;function L(t){return 1==+t?1:1-Math.cos(t*F)}function R(t){return Math.sin(t*F)}function G(t){return(1-Math.cos(N*t))/2}function V(t){return 1.0009775171065494*(Math.pow(2,-10*t)-.0009765625)}function W(t){return V(1-+t)}function q(t){return 1-V(t)}function X(t){return((t*=2)<=1?V(1-t):2-V(t-1))/2}function Y(t){return 1-Math.sqrt(1-t*t)}function H(t){return Math.sqrt(1- --t*t)}function z(t){return((t*=2)<=1?1-Math.sqrt(1-t*t):Math.sqrt(1-(t-=2)*t)+1)/2}var Q=7.5625;function $(t){return 1-U(1-t)}function U(t){return(t=+t)<4/11?Q*t*t:t<8/11?Q*(t-=6/11)*t+3/4:t<10/11?Q*(t-=9/11)*t+15/16:Q*(t-=21/22)*t+63/64}function Z(t){return((t*=2)<=1?1-U(1-t):U(t-1)+1)/2}var K=function t(n){function e(t){return(t=+t)*t*(n*(t-1)+t)}return n=+n,e.overshoot=t,e}(1.70158),J=function t(n){function e(t){return--t*t*((t+1)*n+t)+1}return n=+n,e.overshoot=t,e}(1.70158),tt=function t(n){function e(t){return((t*=2)<1?t*t*((n+1)*t-n):(t-=2)*t*((n+1)*t+n)+2)/2}return n=+n,e.overshoot=t,e}(1.70158),nt=2*Math.PI,et=function t(n,e){var r=Math.asin(1/(n=Math.max(1,n)))*(e/=nt);function i(t){return n*V(- --t)*Math.sin((r-t)/e)}return i.amplitude=function(n){return t(n,e*nt)},i.period=function(e){return t(n,e)},i}(1,.3),rt=function t(n,e){var r=Math.asin(1/(n=Math.max(1,n)))*(e/=nt);function i(t){return 1-n*V(t=+t)*Math.sin((t+r)/e)}return i.amplitude=function(n){return t(n,e*nt)},i.period=function(e){return t(n,e)},i}(1,.3),it=function t(n,e){var r=Math.asin(1/(n=Math.max(1,n)))*(e/=nt);function i(t){return((t=2*t-1)<0?n*V(-t)*Math.sin((r-t)/e):2-n*V(t)*Math.sin((r+t)/e))/2}return i.amplitude=function(n){return t(n,e*nt)},i.period=function(e){return t(n,e)},i}(1,.3),ot=function(t,n,e){t.prototype=n.prototype=e,e.constructor=t};function at(t,n){var e=Object.create(t.prototype);for(var r in n)e[r]=n[r];return e}function ut(){}var st="\\s*([+-]?\\d+)\\s*",ct="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",ft="\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",lt=/^#([0-9a-f]{3,8})$/,ht=new RegExp("^rgb\\("+[st,st,st]+"\\)$"),pt=new RegExp("^rgb\\("+[ft,ft,ft]+"\\)$"),dt=new RegExp("^rgba\\("+[st,st,st,ct]+"\\)$"),vt=new RegExp("^rgba\\("+[ft,ft,ft,ct]+"\\)$"),gt=new RegExp("^hsl\\("+[ct,ft,ft]+"\\)$"),yt=new RegExp("^hsla\\("+[ct,ft,ft,ct]+"\\)$"),mt={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function bt(){return this.rgb().formatHex()}function xt(){return this.rgb().formatRgb()}function Mt(t){var n,e;return t=(t+"").trim().toLowerCase(),(n=lt.exec(t))?(e=n[1].length,n=parseInt(n[1],16),6===e?wt(n):3===e?new St(n>>8&15|n>>4&240,n>>4&15|240&n,(15&n)<<4|15&n,1):8===e?_t(n>>24&255,n>>16&255,n>>8&255,(255&n)/255):4===e?_t(n>>12&15|n>>8&240,n>>8&15|n>>4&240,n>>4&15|240&n,((15&n)<<4|15&n)/255):null):(n=ht.exec(t))?new St(n[1],n[2],n[3],1):(n=pt.exec(t))?new St(255*n[1]/100,255*n[2]/100,255*n[3]/100,1):(n=dt.exec(t))?_t(n[1],n[2],n[3],n[4]):(n=vt.exec(t))?_t(255*n[1]/100,255*n[2]/100,255*n[3]/100,n[4]):(n=gt.exec(t))?jt(n[1],n[2]/100,n[3]/100,1):(n=yt.exec(t))?jt(n[1],n[2]/100,n[3]/100,n[4]):mt.hasOwnProperty(t)?wt(mt[t]):"transparent"===t?new St(NaN,NaN,NaN,0):null}function wt(t){return new St(t>>16&255,t>>8&255,255&t,1)}function _t(t,n,e,r){return r<=0&&(t=n=e=NaN),new St(t,n,e,r)}function At(t){return t instanceof ut||(t=Mt(t)),t?new St((t=t.rgb()).r,t.g,t.b,t.opacity):new St}function Ot(t,n,e,r){return 1===arguments.length?At(t):new St(t,n,e,null==r?1:r)}function St(t,n,e,r){this.r=+t,this.g=+n,this.b=+e,this.opacity=+r}function Pt(){return"#"+Tt(this.r)+Tt(this.g)+Tt(this.b)}function Ct(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"rgb(":"rgba(")+Math.max(0,Math.min(255,Math.round(this.r)||0))+", "+Math.max(0,Math.min(255,Math.round(this.g)||0))+", "+Math.max(0,Math.min(255,Math.round(this.b)||0))+(1===t?")":", "+t+")")}function Tt(t){return((t=Math.max(0,Math.min(255,Math.round(t)||0)))<16?"0":"")+t.toString(16)}function jt(t,n,e,r){return r<=0?t=n=e=NaN:e<=0||e>=1?t=n=NaN:n<=0&&(t=NaN),new Et(t,n,e,r)}function kt(t){if(t instanceof Et)return new Et(t.h,t.s,t.l,t.opacity);if(t instanceof ut||(t=Mt(t)),!t)return new Et;if(t instanceof Et)return t;var n=(t=t.rgb()).r/255,e=t.g/255,r=t.b/255,i=Math.min(n,e,r),o=Math.max(n,e,r),a=NaN,u=o-i,s=(o+i)/2;return u?(a=n===o?(e-r)/u+6*(e0&&s<1?0:a,new Et(a,u,s,t.opacity)}function Et(t,n,e,r){this.h=+t,this.s=+n,this.l=+e,this.opacity=+r}function Bt(t,n,e){return 255*(t<60?n+(e-n)*t/60:t<180?e:t<240?n+(e-n)*(240-t)/60:n)}function It(t,n,e,r,i){var o=t*t,a=o*t;return((1-3*t+3*o-a)*n+(4-6*o+3*a)*e+(1+3*t+3*o-3*a)*r+a*i)/6}ot(ut,Mt,{copy:function(t){return Object.assign(new this.constructor,this,t)},displayable:function(){return this.rgb().displayable()},hex:bt,formatHex:bt,formatHsl:function(){return kt(this).formatHsl()},formatRgb:xt,toString:xt}),ot(St,Ot,at(ut,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new St(this.r*t,this.g*t,this.b*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new St(this.r*t,this.g*t,this.b*t,this.opacity)},rgb:function(){return this},displayable:function(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:Pt,formatHex:Pt,formatRgb:Ct,toString:Ct})),ot(Et,(function(t,n,e,r){return 1===arguments.length?kt(t):new Et(t,n,e,null==r?1:r)}),at(ut,{brighter:function(t){return t=null==t?1/.7:Math.pow(1/.7,t),new Et(this.h,this.s,this.l*t,this.opacity)},darker:function(t){return t=null==t?.7:Math.pow(.7,t),new Et(this.h,this.s,this.l*t,this.opacity)},rgb:function(){var t=this.h%360+360*(this.h<0),n=isNaN(t)||isNaN(this.s)?0:this.s,e=this.l,r=e+(e<.5?e:1-e)*n,i=2*e-r;return new St(Bt(t>=240?t-240:t+120,i,r),Bt(t,i,r),Bt(t<120?t+240:t-120,i,r),this.opacity)},displayable:function(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl:function(){var t=this.opacity;return(1===(t=isNaN(t)?1:Math.max(0,Math.min(1,t)))?"hsl(":"hsla(")+(this.h||0)+", "+100*(this.s||0)+"%, "+100*(this.l||0)+"%"+(1===t?")":", "+t+")")}}));var Dt=function(t){return function(){return t}};function Nt(t,n){return function(e){return t+e*n}}function Ft(t){return 1==(t=+t)?Lt:function(n,e){return e-n?function(t,n,e){return t=Math.pow(t,e),n=Math.pow(n,e)-t,e=1/e,function(r){return Math.pow(t+r*n,e)}}(n,e,t):Dt(isNaN(n)?e:n)}}function Lt(t,n){var e=n-t;return e?Nt(t,e):Dt(isNaN(t)?n:t)}var Rt=function t(n){var e=Ft(n);function r(t,n){var r=e((t=Ot(t)).r,(n=Ot(n)).r),i=e(t.g,n.g),o=e(t.b,n.b),a=Lt(t.opacity,n.opacity);return function(n){return t.r=r(n),t.g=i(n),t.b=o(n),t.opacity=a(n),t+""}}return r.gamma=t,r}(1);function Gt(t){return function(n){var e,r,i=n.length,o=new Array(i),a=new Array(i),u=new Array(i);for(e=0;e=1?(e=1,n-1):Math.floor(e*n),i=t[r],o=t[r+1],a=r>0?t[r-1]:2*i-o,u=ro&&(i=n.slice(o,i),u[a]?u[a]+=i:u[++a]=i),(e=e[0])===(r=r[0])?u[a]?u[a]+=r:u[++a]=r:(u[++a]=null,s.push({i:a,x:Yt(e,r)})),o=Qt.lastIndex;return op.length?(h=Zt.parsePathString(o[l]),p=Zt.parsePathString(i[l]),p=Zt.fillPathByDiff(p,h),p=Zt.formatPath(p,h),n.fromAttrs.path=p,n.toAttrs.path=h):n.pathFormatted||(h=Zt.parsePathString(o[l]),p=Zt.parsePathString(i[l]),p=Zt.formatPath(p,h),n.fromAttrs.path=p,n.toAttrs.path=h,n.pathFormatted=!0),r[l]=[];for(var d=0;d0){for(var o=r.animators.length-1;o>=0;o--)if((t=r.animators[o]).destroyed)r.removeAnimator(o);else{if(!t.isAnimatePaused())for(var a=(n=t.get("animations")).length-1;a>=0;a--)e=n[a],Jt(t,e,i)&&(n.splice(a,1),!1,e.callback&&e.callback());0===n.length&&r.removeAnimator(o)}r.canvas.get("autoDraw")||r.canvas.draw()}}))},t.prototype.addAnimator=function(t){this.animators.push(t)},t.prototype.removeAnimator=function(t){this.animators.splice(t,1)},t.prototype.isAnimating=function(){return!!this.animators.length},t.prototype.stop=function(){this.timer&&this.timer.stop()},t.prototype.stopAllAnimations=function(t){void 0===t&&(t=!0),this.animators.forEach((function(n){n.stopAnimate(t)})),this.animators=[],this.canvas.draw()},t.prototype.getTime=function(){return this.current},t}(),nn=e(15),en=["mousedown","mouseup","dblclick","mouseout","mouseover","mousemove","mouseleave","mouseenter","touchstart","touchmove","touchend","dragenter","dragover","dragleave","drop","contextmenu","mousewheel"];function rn(t,n,e){e.name=n,e.target=t,e.currentTarget=t,e.delegateTarget=t,t.emit(n,e)}function on(t,n,e){if(e.bubbles){var r=void 0,i=!1;if("mouseenter"===n?(r=e.fromShape,i=!0):"mouseleave"===n&&(i=!0,r=e.toShape),t.isCanvas()&&i)return;if(r&&Object(c.g)(t,r))return void(e.bubbles=!1);e.name=n,e.currentTarget=t,e.delegateTarget=t,t.emit(n,e)}}var an=function(){function t(t){var n=this;this.draggingShape=null,this.dragging=!1,this.currentShape=null,this.mousedownShape=null,this.mousedownPoint=null,this._eventCallback=function(t){var e=t.type;n._triggerEvent(e,t)},this._onDocumentMove=function(t){if(n.canvas.get("el")!==t.target&&(n.dragging||n.currentShape)){var e=n._getPointInfo(t);n.dragging&&n._emitEvent("drag",t,e,n.draggingShape)}},this._onDocumentMouseUp=function(t){if(n.canvas.get("el")!==t.target&&n.dragging){var e=n._getPointInfo(t);n.draggingShape&&n._emitEvent("drop",t,e,null),n._emitEvent("dragend",t,e,n.draggingShape),n._afterDrag(n.draggingShape,e,t)}},this.canvas=t.canvas}return t.prototype.init=function(){this._bindEvents()},t.prototype._bindEvents=function(){var t=this,n=this.canvas.get("el");Object(c.a)(en,(function(e){n.addEventListener(e,t._eventCallback)})),document&&(document.addEventListener("mousemove",this._onDocumentMove),document.addEventListener("mouseup",this._onDocumentMouseUp))},t.prototype._clearEvents=function(){var t=this,n=this.canvas.get("el");Object(c.a)(en,(function(e){n.removeEventListener(e,t._eventCallback)})),document&&(document.removeEventListener("mousemove",this._onDocumentMove),document.removeEventListener("mouseup",this._onDocumentMouseUp))},t.prototype._getEventObj=function(t,n,e,r,i,o){var a=new nn.a(t,n);return a.fromShape=i,a.toShape=o,a.x=e.x,a.y=e.y,a.clientX=e.clientX,a.clientY=e.clientY,a.propagationPath.push(r),a},t.prototype._getShape=function(t,n){return this.canvas.getShape(t.x,t.y,n)},t.prototype._getPointInfo=function(t){var n=this.canvas,e=n.getClientByEvent(t),r=n.getPointByEvent(t);return{x:r.x,y:r.y,clientX:e.x,clientY:e.y}},t.prototype._triggerEvent=function(t,n){var e=this._getPointInfo(n),r=this._getShape(e,n),i=this["_on"+t],o=!1;if(i)i.call(this,e,r,n);else{var a=this.currentShape;"mouseenter"===t||"dragenter"===t||"mouseover"===t?(this._emitEvent(t,n,e,null,null,r),r&&this._emitEvent(t,n,e,r,null,r),"mouseenter"===t&&this.draggingShape&&this._emitEvent("dragenter",n,e,null)):"mouseleave"===t||"dragleave"===t||"mouseout"===t?(o=!0,a&&this._emitEvent(t,n,e,a,a,null),this._emitEvent(t,n,e,null,a,null),"mouseleave"===t&&this.draggingShape&&this._emitEvent("dragleave",n,e,null)):this._emitEvent(t,n,e,r,null,null)}if(o||(this.currentShape=r),r&&!r.get("destroyed")){var u=this.canvas;u.get("el").style.cursor=r.attr("cursor")||u.get("cursor")}},t.prototype._onmousedown=function(t,n,e){0===e.button&&(this.mousedownShape=n,this.mousedownPoint=t,this.mousedownTimeStamp=e.timeStamp),this._emitEvent("mousedown",e,t,n,null,null)},t.prototype._emitMouseoverEvents=function(t,n,e,r){var i=this.canvas.get("el");e!==r&&(e&&(this._emitEvent("mouseout",t,n,e,e,r),this._emitEvent("mouseleave",t,n,e,e,r),r&&!r.get("destroyed")||(i.style.cursor=this.canvas.get("cursor"))),r&&(this._emitEvent("mouseover",t,n,r,e,r),this._emitEvent("mouseenter",t,n,r,e,r)))},t.prototype._emitDragoverEvents=function(t,n,e,r,i){r?(r!==e&&(e&&this._emitEvent("dragleave",t,n,e,e,r),this._emitEvent("dragenter",t,n,r,e,r)),i||this._emitEvent("dragover",t,n,r)):e&&this._emitEvent("dragleave",t,n,e,e,r),i&&this._emitEvent("dragover",t,n,r)},t.prototype._afterDrag=function(t,n,e){t&&(t.set("capture",!0),this.draggingShape=null),this.dragging=!1;var r=this._getShape(n,e);r!==t&&this._emitMouseoverEvents(e,n,t,r),this.currentShape=r},t.prototype._onmouseup=function(t,n,e){if(0===e.button){var r=this.draggingShape;this.dragging?(r&&this._emitEvent("drop",e,t,n),this._emitEvent("dragend",e,t,r),this._afterDrag(r,t,e)):(this._emitEvent("mouseup",e,t,n),n===this.mousedownShape&&this._emitEvent("click",e,t,n),this.mousedownShape=null,this.mousedownPoint=null)}},t.prototype._ondragover=function(t,n,e){e.preventDefault();var r=this.currentShape;this._emitDragoverEvents(e,t,r,n,!0)},t.prototype._onmousemove=function(t,n,e){var r=this.canvas,i=this.currentShape,o=this.draggingShape;if(this.dragging)o&&this._emitDragoverEvents(e,t,i,n,!1),this._emitEvent("drag",e,t,o);else{var a=this.mousedownPoint;if(a){var u=this.mousedownShape,s=e.timeStamp-this.mousedownTimeStamp,c=a.clientX-t.clientX,f=a.clientY-t.clientY;s>120||c*c+f*f>40?u&&u.get("draggable")?((o=this.mousedownShape).set("capture",!1),this.draggingShape=o,this.dragging=!0,this._emitEvent("dragstart",e,t,o),this.mousedownShape=null,this.mousedownPoint=null):!u&&r.get("draggable")?(this.dragging=!0,this._emitEvent("dragstart",e,t,null),this.mousedownShape=null,this.mousedownPoint=null):(this._emitMouseoverEvents(e,t,i,n),this._emitEvent("mousemove",e,t,n)):(this._emitMouseoverEvents(e,t,i,n),this._emitEvent("mousemove",e,t,n))}else this._emitMouseoverEvents(e,t,i,n),this._emitEvent("mousemove",e,t,n)}},t.prototype._emitEvent=function(t,n,e,r,i,o){var a=this._getEventObj(t,n,e,r,i,o);if(r){a.shape=r,rn(r,t,a);for(var u=r.getParent();u;)u.emitDelegation(t,a),a.propagationStopped||on(u,t,a),a.propagationPath.push(u),u=u.getParent()}else{rn(this.canvas,t,a)}},t.prototype.destroy=function(){this._clearEvents(),this.canvas=null,this.currentShape=null,this.draggingShape=null,this.mousedownPoint=null,this.mousedownShape=null,this.mousedownTimeStamp=null},t}(),un=Object(u.a)(),sn=un&&"firefox"===un.name,cn=function(t){function n(n){var e=t.call(this,n)||this;return e.initContainer(),e.initDom(),e.initEvents(),e.initTimeline(),e}return Object(a.a)(n,t),n.prototype.getDefaultCfg=function(){var n=t.prototype.getDefaultCfg.call(this);return n.cursor="default",n.supportCSSTransform=!1,n},n.prototype.initContainer=function(){var t=this.get("container");Object(c.h)(t)&&(t=document.getElementById(t),this.set("container",t))},n.prototype.initDom=function(){var t=this.createDom();this.set("el",t),this.get("container").appendChild(t),this.setDOMSize(this.get("width"),this.get("height"))},n.prototype.initEvents=function(){var t=new an({canvas:this});t.init(),this.set("eventController",t)},n.prototype.initTimeline=function(){var t=new tn(this);this.set("timeline",t)},n.prototype.setDOMSize=function(t,n){var e=this.get("el");c.c&&(e.style.width=t+"px",e.style.height=n+"px")},n.prototype.changeSize=function(t,n){this.setDOMSize(t,n),this.set("width",t),this.set("height",n),this.onCanvasChange("changeSize")},n.prototype.getRenderer=function(){return this.get("renderer")},n.prototype.getCursor=function(){return this.get("cursor")},n.prototype.setCursor=function(t){this.set("cursor",t);var n=this.get("el");c.c&&n&&(n.style.cursor=t)},n.prototype.getPointByEvent=function(t){if(this.get("supportCSSTransform")){if(sn&&!Object(c.e)(t.layerX)&&t.layerX!==t.offsetX)return{x:t.layerX,y:t.layerY};if(!Object(c.e)(t.offsetX))return{x:t.offsetX,y:t.offsetY}}var n=this.getClientByEvent(t),e=n.x,r=n.y;return this.getPointByClient(e,r)},n.prototype.getClientByEvent=function(t){var n=t;return t.touches&&(n="touchend"===t.type?t.changedTouches[0]:t.touches[0]),{x:n.clientX,y:n.clientY}},n.prototype.getPointByClient=function(t,n){var e=this.get("el").getBoundingClientRect();return{x:t-e.left,y:n-e.top}},n.prototype.getClientByPoint=function(t,n){var e=this.get("el").getBoundingClientRect();return{x:t+e.left,y:n+e.top}},n.prototype.draw=function(){},n.prototype.removeDom=function(){var t=this.get("el");t.parentNode.removeChild(t)},n.prototype.clearEvents=function(){this.get("eventController").destroy()},n.prototype.isCanvas=function(){return!0},n.prototype.getParent=function(){return null},n.prototype.destroy=function(){var n=this.get("timeline");this.get("destroyed")||(this.clear(),n&&n.stop(),this.clearEvents(),this.removeDom(),t.prototype.destroy.call(this))},n}(s.a);n.a=cn},function(t,n,e){"use strict";e.d(n,"a",(function(){return o}));var r=new Map;function i(t,n){r.set(t,n)}function o(t){return r.get(t)}var a=function(t){var n=t.attr();return{x:n.x,y:n.y,width:n.width,height:n.height}},u=function(t){var n=t.attr(),e=n.x,r=n.y,i=n.r;return{x:e-i,y:r-i,width:2*i,height:2*i}},s=e(9);function c(t,n){return t&&n?{minX:Math.min(t.minX,n.minX),minY:Math.min(t.minY,n.minY),maxX:Math.max(t.maxX,n.maxX),maxY:Math.max(t.maxY,n.maxY)}:t||n}function f(t,n){var e=t.get("startArrowShape"),r=t.get("endArrowShape");return e&&(n=c(n,e.getCanvasBBox())),r&&(n=c(n,r.getCanvasBBox())),n}var l=e(11),h=e(0),p=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/gi,d=/[^\s\,]+/gi;var v=function(t){var n=t||[];return Object(h.b)(n)?n:Object(h.i)(n)?(n=n.match(p),Object(h.a)(n,(function(t,e){if((t=t.match(d))[0].length>1){var r=t[0].charAt(0);t.splice(1,0,t[0].substr(1)),t[0]=r}Object(h.a)(t,(function(n,e){isNaN(n)||(t[e]=+n)})),n[e]=t})),n):void 0};var g="\t\n\v\f\r   ᠎              \u2028\u2029";new RegExp("([a-z])["+g+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+g+"]*,?["+g+"]*)+)","ig"),new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+g+"]*,?["+g+"]*","ig");function y(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])}function m(t,n){return y(t)*y(n)?(t[0]*n[0]+t[1]*n[1])/(y(t)*y(n)):1}function b(t,n){return(t[0]*n[1]1&&(e*=Math.sqrt(d),r*=Math.sqrt(d));var v=e*e*(p*p)+r*r*(l*l),g=v?Math.sqrt((e*e*(r*r)-v)/v):1;o===a&&(g*=-1),isNaN(g)&&(g=0);var y=r?g*e*p/r:0,M=e?g*-r*l/e:0,w=(u+c)/2+Math.cos(i)*y-Math.sin(i)*M,_=(s+f)/2+Math.sin(i)*y+Math.cos(i)*M,A=[(l-y)/e,(p-M)/r],O=[(-1*l-y)/e,(-1*p-M)/r],S=b([1,0],A),P=b(A,O);return m(A,O)<=-1&&(P=Math.PI),m(A,O)>=1&&(P=0),0===a&&P>0&&(P-=2*Math.PI),1===a&&P<0&&(P+=2*Math.PI),{cx:w,cy:_,rx:x(t,[c,f])?0:e,ry:x(t,[c,f])?0:r,startAngle:S,endAngle:S+P,xRotation:i,arcFlag:o,sweepFlag:a}}function w(t,n){return[n[0]+(n[0]-t[0]),n[1]+(n[1]-t[1])]}function _(t,n){var e=t.prePoint,r=t.currentPoint,i=t.nextPoint,o=Math.pow(r[0]-e[0],2)+Math.pow(r[1]-e[1],2),a=Math.pow(r[0]-i[0],2)+Math.pow(r[1]-i[1],2),u=Math.pow(e[0]-i[0],2)+Math.pow(e[1]-i[1],2),s=Math.acos((o+a-u)/(2*Math.sqrt(o)*Math.sqrt(a)));if(!s||0===Math.sin(s)||Object(h.g)(s,0))return{xExtra:0,yExtra:0};var c=Math.abs(Math.atan2(i[1]-r[1],i[0]-r[0])),f=Math.abs(Math.atan2(i[0]-r[0],i[1]-r[1]));return c=c>Math.PI/2?Math.PI-c:c,f=f>Math.PI/2?Math.PI-f:f,{xExtra:Math.cos(s/2-c)*(n/2*(1/Math.sin(s/2)))-n/2||0,yExtra:Math.cos(f-s/2)*(n/2*(1/Math.sin(s/2)))-n/2||0}}i("rect",a),i("image",a),i("circle",u),i("marker",u),i("polyline",(function(t){for(var n=t.attr().points,e=[],r=[],i=0;i=0;s--)r.removeChild(u[s]);r.appendChild(a)}else r.innerHTML=a}else r.innerHTML=e.html},n}(e(6).default);n.default=a},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(3),i=e(2),o=e(4),a=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="ellipse",n.canFill=!0,n.canStroke=!0,n}return r.__extends(n,t),n.prototype.getDefaultAttrs=function(){var n=t.prototype.getDefaultAttrs.call(this);return r.__assign(r.__assign({},n),{x:0,y:0,rx:0,ry:0})},n.prototype.createPath=function(t,n){var e=this.attr(),r=this.get("el");i.each(n||e,(function(t,n){"x"===n||"y"===n?r.setAttribute("c"+n,t):o.SVG_ATTR_MAP[n]&&r.setAttribute(o.SVG_ATTR_MAP[n],t)}))},n}(e(6).default);n.default=a},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(3),i=e(2),o=e(4),a=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="image",n.canFill=!1,n.canStroke=!1,n}return r.__extends(n,t),n.prototype.getDefaultAttrs=function(){var n=t.prototype.getDefaultAttrs.call(this);return r.__assign(r.__assign({},n),{x:0,y:0,width:0,height:0})},n.prototype.createPath=function(t,n){var e=this,r=this.attr(),a=this.get("el");i.each(n||r,(function(t,n){"img"===n?e._setImage(r.img):o.SVG_ATTR_MAP[n]&&a.setAttribute(o.SVG_ATTR_MAP[n],t)}))},n.prototype.setAttr=function(t,n){this.attrs[t]=n,"img"===t&&this._setImage(n)},n.prototype._setImage=function(t){var n=this.attr(),e=this.get("el");if(i.isString(t))e.setAttribute("href",t);else if(t instanceof window.Image)n.width||(e.setAttribute("width",t.width),this.attr("width",t.width)),n.height||(e.setAttribute("height",t.height),this.attr("height",t.height)),e.setAttribute("href",t.src);else if(t instanceof HTMLElement&&i.isString(t.nodeName)&&"CANVAS"===t.nodeName.toUpperCase())e.setAttribute("href",t.toDataURL());else if(t instanceof ImageData){var r=document.createElement("canvas");r.setAttribute("width",""+t.width),r.setAttribute("height",""+t.height),r.getContext("2d").putImageData(t,0,0),n.width||(e.setAttribute("width",""+t.width),this.attr("width",t.width)),n.height||(e.setAttribute("height",""+t.height),this.attr("height",t.height)),e.setAttribute("href",r.toDataURL())}},n}(e(6).default);n.default=a},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(3),i=e(9),o=e(2),a=e(4),u=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="line",n.canFill=!1,n.canStroke=!0,n}return r.__extends(n,t),n.prototype.getDefaultAttrs=function(){var n=t.prototype.getDefaultAttrs.call(this);return r.__assign(r.__assign({},n),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},n.prototype.createPath=function(t,n){var e=this.attr(),r=this.get("el");o.each(n||e,(function(n,i){if("startArrow"===i||"endArrow"===i)if(n){var u=o.isObject(n)?t.addArrow(e,a.SVG_ATTR_MAP[i]):t.getDefaultArrow(e,a.SVG_ATTR_MAP[i]);r.setAttribute(a.SVG_ATTR_MAP[i],"url(#"+u+")")}else r.removeAttribute(a.SVG_ATTR_MAP[i]);else a.SVG_ATTR_MAP[i]&&r.setAttribute(a.SVG_ATTR_MAP[i],n)}))},n.prototype.getTotalLength=function(){var t=this.attr(),n=t.x1,e=t.y1,r=t.x2,o=t.y2;return i.Line.length(n,e,r,o)},n.prototype.getPoint=function(t){var n=this.attr(),e=n.x1,r=n.y1,o=n.x2,a=n.y2;return i.Line.pointAt(e,r,o,a,t)},n}(e(6).default);n.default=u},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(3),i=e(2),o=e(6),a=e(45),u=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="marker",n.canFill=!0,n.canStroke=!0,n}return r.__extends(n,t),n.prototype.createPath=function(t){this.get("el").setAttribute("d",this._assembleMarker())},n.prototype._assembleMarker=function(){var t=this._getPath();return i.isArray(t)?t.map((function(t){return t.join(" ")})).join(""):t},n.prototype._getPath=function(){var t,n=this.attr(),e=n.x,r=n.y,o=n.r||n.radius,u=n.symbol||"circle";return(t=i.isFunction(u)?u:a.default.get(u))?t(e,r,o):(console.warn(t+" symbol is not exist."),null)},n.symbolsFactory=a.default,n}(o.default);n.default=u},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r={circle:function(t,n,e){return[["M",t,n],["m",-e,0],["a",e,e,0,1,0,2*e,0],["a",e,e,0,1,0,2*-e,0]]},square:function(t,n,e){return[["M",t-e,n-e],["L",t+e,n-e],["L",t+e,n+e],["L",t-e,n+e],["Z"]]},diamond:function(t,n,e){return[["M",t-e,n],["L",t,n-e],["L",t+e,n],["L",t,n+e],["Z"]]},triangle:function(t,n,e){var r=e*Math.sin(1/3*Math.PI);return[["M",t-e,n+r],["L",t,n-r],["L",t+e,n+r],["z"]]},triangleDown:function(t,n,e){var r=e*Math.sin(1/3*Math.PI);return[["M",t-e,n-r],["L",t+e,n-r],["L",t,n+r],["Z"]]}};n.default={get:function(t){return r[t]},register:function(t,n){r[t]=n},remove:function(t){delete r[t]},getAll:function(){return r}}},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(3),i=e(2),o=e(4),a=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="path",n.canFill=!0,n.canStroke=!0,n}return r.__extends(n,t),n.prototype.getDefaultAttrs=function(){var n=t.prototype.getDefaultAttrs.call(this);return r.__assign(r.__assign({},n),{startArrow:!1,endArrow:!1})},n.prototype.createPath=function(t,n){var e=this,r=this.attr(),a=this.get("el");i.each(n||r,(function(n,u){if("path"===u&&i.isArray(n))a.setAttribute("d",e._formatPath(n));else if("startArrow"===u||"endArrow"===u)if(n){var s=i.isObject(n)?t.addArrow(r,o.SVG_ATTR_MAP[u]):t.getDefaultArrow(r,o.SVG_ATTR_MAP[u]);a.setAttribute(o.SVG_ATTR_MAP[u],"url(#"+s+")")}else a.removeAttribute(o.SVG_ATTR_MAP[u]);else o.SVG_ATTR_MAP[u]&&a.setAttribute(o.SVG_ATTR_MAP[u],n)}))},n.prototype._formatPath=function(t){var n=t.map((function(t){return t.join(" ")})).join("");return~n.indexOf("NaN")?"":n},n.prototype.getTotalLength=function(){var t=this.get("el");return t?t.getTotalLength():null},n.prototype.getPoint=function(t){var n=this.get("el"),e=this.getTotalLength();if(0===e)return null;var r=n?n.getPointAtLength(t*e):null;return r?{x:r.x,y:r.y}:null},n}(e(6).default);n.default=a},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(3),i=e(2),o=e(4),a=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="polygon",n.canFill=!0,n.canStroke=!0,n}return r.__extends(n,t),n.prototype.createPath=function(t,n){var e=this.attr(),r=this.get("el");i.each(n||e,(function(t,n){"points"===n&&i.isArray(t)&&t.length>=2?r.setAttribute("points",t.map((function(t){return t[0]+","+t[1]})).join(" ")):o.SVG_ATTR_MAP[n]&&r.setAttribute(o.SVG_ATTR_MAP[n],t)}))},n}(e(6).default);n.default=a},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(3),i=e(9),o=e(9),a=e(2),u=e(4),s=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="polyline",n.canFill=!0,n.canStroke=!0,n}return r.__extends(n,t),n.prototype.getDefaultAttrs=function(){var n=t.prototype.getDefaultAttrs.call(this);return r.__assign(r.__assign({},n),{startArrow:!1,endArrow:!1})},n.prototype.onAttrChange=function(n,e,r){t.prototype.onAttrChange.call(this,n,e,r),-1!==["points"].indexOf(n)&&this._resetCache()},n.prototype._resetCache=function(){this.set("totalLength",null),this.set("tCache",null)},n.prototype.createPath=function(t,n){var e=this.attr(),r=this.get("el");a.each(n||e,(function(t,n){"points"===n&&a.isArray(t)&&t.length>=2?r.setAttribute("points",t.map((function(t){return t[0]+","+t[1]})).join(" ")):u.SVG_ATTR_MAP[n]&&r.setAttribute(u.SVG_ATTR_MAP[n],t)}))},n.prototype.getTotalLength=function(){var t=this.attr().points,n=this.get("totalLength");return a.isNil(n)?(this.set("totalLength",i.Polyline.length(t)),this.get("totalLength")):n},n.prototype.getPoint=function(t){var n,e,r=this.attr().points,i=this.get("tCache");return i||(this._setTcache(),i=this.get("tCache")),a.each(i,(function(r,i){t>=r[0]&&t<=r[1]&&(n=(t-r[0])/(r[1]-r[0]),e=i)})),o.Line.pointAt(r[e][0],r[e][1],r[e+1][0],r[e+1][1],n)},n.prototype._setTcache=function(){var t=this.attr().points;if(t&&0!==t.length){var n=this.getTotalLength();if(!(n<=0)){var e,r,i=0,u=[];a.each(t,(function(a,s){t[s+1]&&((e=[])[0]=i/n,r=o.Line.length(a[0],a[1],t[s+1][0],t[s+1][1]),i+=r,e[1]=i/n,u.push(e))})),this.set("tCache",u)}}},n.prototype.getStartTangent=function(){var t=this.attr().points,n=[];return n.push([t[1][0],t[1][1]]),n.push([t[0][0],t[0][1]]),n},n.prototype.getEndTangent=function(){var t=this.attr().points,n=t.length-1,e=[];return e.push([t[n-1][0],t[n-1][1]]),e.push([t[n][0],t[n][1]]),e},n}(e(6).default);n.default=s},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(3),i=e(2),o=e(6),a=e(4),u=e(50),s=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="rect",n.canFill=!0,n.canStroke=!0,n}return r.__extends(n,t),n.prototype.getDefaultAttrs=function(){var n=t.prototype.getDefaultAttrs.call(this);return r.__assign(r.__assign({},n),{x:0,y:0,width:0,height:0,radius:0})},n.prototype.createPath=function(t,n){var e=this,r=this.attr(),o=this.get("el"),u=!1,s=["x","y","width","height","radius"];i.each(n||r,(function(t,n){-1===s.indexOf(n)||u?-1===s.indexOf(n)&&a.SVG_ATTR_MAP[n]&&o.setAttribute(a.SVG_ATTR_MAP[n],t):(o.setAttribute("d",e._assembleRect(r)),u=!0)}))},n.prototype._assembleRect=function(t){var n=t.x,e=t.y,r=t.width,o=t.height,a=t.radius;if(!a)return"M "+n+","+e+" l "+r+",0 l 0,"+o+" l"+-r+" 0 z";var s=u.parseRadius(a);return i.isArray(a)?1===a.length?s.r1=s.r2=s.r3=s.r4=a[0]:2===a.length?(s.r1=s.r3=a[0],s.r2=s.r4=a[1]):3===a.length?(s.r1=a[0],s.r2=s.r4=a[1],s.r3=a[2]):(s.r1=a[0],s.r2=a[1],s.r3=a[2],s.r4=a[3]):s.r1=s.r2=s.r3=s.r4=a,[["M "+(n+s.r1)+","+e],["l "+(r-s.r1-s.r2)+",0"],["a "+s.r2+","+s.r2+",0,0,1,"+s.r2+","+s.r2],["l 0,"+(o-s.r2-s.r3)],["a "+s.r3+","+s.r3+",0,0,1,"+-s.r3+","+s.r3],["l "+(s.r3+s.r4-r)+",0"],["a "+s.r4+","+s.r4+",0,0,1,"+-s.r4+","+-s.r4],["l 0,"+(s.r4+s.r1-o)],["a "+s.r1+","+s.r1+",0,0,1,"+s.r1+","+-s.r1],["z"]].join(" ")},n}(o.default);n.default=s},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0}),n.parsePath=n.parseRadius=void 0;var r=e(2),i=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/gi,o=/[^\s,]+/gi;n.parseRadius=function(t){var n=0,e=0,i=0,o=0;return r.isArray(t)?1===t.length?n=e=i=o=t[0]:2===t.length?(n=i=t[0],e=o=t[1]):3===t.length?(n=t[0],e=o=t[1],i=t[2]):(n=t[0],e=t[1],i=t[2],o=t[3]):n=e=i=o=t,{r1:n,r2:e,r3:i,r4:o}},n.parsePath=function(t){return t=t||[],r.isArray(t)?t:r.isString(t)?(t=t.match(i),r.each(t,(function(n,e){if((n=n.match(o))[0].length>1){var i=n[0].charAt(0);n.splice(1,0,n[0].substr(1)),n[0]=i}r.each(n,(function(t,e){isNaN(t)||(n[e]=+t)})),t[e]=n})),t):void 0}},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(3),i=e(2),o=e(52),a=e(13),u=e(4),s=e(6),c={top:"before-edge",middle:"central",bottom:"after-edge",alphabetic:"baseline",hanging:"hanging"},f={top:"text-before-edge",middle:"central",bottom:"text-after-edge",alphabetic:"alphabetic",hanging:"hanging"},l={left:"left",start:"left",center:"middle",right:"end",end:"end"},h=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.type="text",n.canFill=!0,n.canStroke=!0,n}return r.__extends(n,t),n.prototype.getDefaultAttrs=function(){var n=t.prototype.getDefaultAttrs.call(this);return r.__assign(r.__assign({},n),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},n.prototype.createPath=function(t,n){var e=this,r=this.attr(),o=this.get("el");this._setFont(),i.each(n||r,(function(t,n){"text"===n?e._setText(""+t):"matrix"===n&&t?a.setTransform(e):u.SVG_ATTR_MAP[n]&&o.setAttribute(u.SVG_ATTR_MAP[n],t)})),o.setAttribute("paint-order","stroke"),o.setAttribute("style","stroke-linecap:butt; stroke-linejoin:miter;")},n.prototype._setFont=function(){var t=this.get("el"),n=this.attr(),e=n.textBaseline,r=n.textAlign,i=o.detect();i&&"firefox"===i.name?t.setAttribute("dominant-baseline",f[e]||"alphabetic"):t.setAttribute("alignment-baseline",c[e]||"baseline"),t.setAttribute("text-anchor",l[r]||"left")},n.prototype._setText=function(t){var n=this.get("el"),e=this.attr(),r=e.x,o=e.textBaseline,a=void 0===o?"bottom":o;if(t)if(~t.indexOf("\n")){var u=t.split("\n"),s=u.length-1,c="";i.each(u,(function(t,n){0===n?"alphabetic"===a?c+=''+t+"":"top"===a?c+=''+t+"":"middle"===a?c+=''+t+"":"bottom"===a?c+=''+t+"":"hanging"===a&&(c+=''+t+""):c+=''+t+""})),n.innerHTML=c}else n.innerHTML=t;else n.innerHTML=""},n}(s.default);n.default=h},function(t,n,e){"use strict";e.r(n),function(t){e.d(n,"BrowserInfo",(function(){return i})),e.d(n,"NodeInfo",(function(){return o})),e.d(n,"SearchBotDeviceInfo",(function(){return a})),e.d(n,"BotInfo",(function(){return u})),e.d(n,"ReactNativeInfo",(function(){return s})),e.d(n,"detect",(function(){return h})),e.d(n,"browserName",(function(){return d})),e.d(n,"parseUserAgent",(function(){return v})),e.d(n,"detectOS",(function(){return g})),e.d(n,"getNodeVersion",(function(){return y}));var r=function(){for(var t=0,n=0,e=arguments.length;n'})),e}var c=function(){function t(t){this.cfg={};var n,e,u,c,f,l,h,p=null,d=r.uniqueId("gradient_");return"l"===t.toLowerCase()[0]?function(t,n){var e,i,a=o.exec(t),u=r.mod(r.toRadian(parseFloat(a[1])),2*Math.PI),c=a[2];u>=0&&u<.5*Math.PI?(e={x:0,y:0},i={x:1,y:1}):.5*Math.PI<=u&&u';n.innerHTML=e},t}();n.default=u},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(2),i=e(8),o=function(){function t(t,n){this.cfg={};var e=i.createSVGElement("marker"),o=r.uniqueId("marker_");e.setAttribute("id",o);var a=i.createSVGElement("path");a.setAttribute("stroke",t.stroke||"none"),a.setAttribute("fill",t.fill||"none"),e.appendChild(a),e.setAttribute("overflow","visible"),e.setAttribute("orient","auto-start-reverse"),this.el=e,this.child=a,this.id=o;var u=t["marker-start"===n?"startArrow":"endArrow"];return this.stroke=t.stroke||"#000",!0===u?this._setDefaultPath(n,a):(this.cfg=u,this._setMarker(t.lineWidth,a)),this}return t.prototype.match=function(){return!1},t.prototype._setDefaultPath=function(t,n){var e=this.el;n.setAttribute("d","M0,0 L"+10*Math.cos(Math.PI/6)+",5 L0,10"),e.setAttribute("refX",""+10*Math.cos(Math.PI/6)),e.setAttribute("refY","5")},t.prototype._setMarker=function(t,n){var e=this.el,i=this.cfg.path,o=this.cfg.d;r.isArray(i)&&(i=i.map((function(t){return t.join(" ")})).join("")),n.setAttribute("d",i),e.appendChild(n),o&&e.setAttribute("refX",""+o/t)},t.prototype.update=function(t){var n=this.child;n.attr?n.attr("fill",t):n.setAttribute("fill",t)},t}();n.default=o},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(2),i=e(8),o=function(){function t(t){this.type="clip",this.cfg={};var n=i.createSVGElement("clipPath");this.el=n,this.id=r.uniqueId("clip_"),n.id=this.id;var e=t.cfg.el;return n.appendChild(e),this.cfg=t,this}return t.prototype.match=function(){return!1},t.prototype.remove=function(){var t=this.el;t.parentNode.removeChild(t)},t}();n.default=o},function(t,n,e){"use strict";Object.defineProperty(n,"__esModule",{value:!0});var r=e(2),i=e(8),o=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,a=function(){function t(t){this.cfg={};var n=i.createSVGElement("pattern");n.setAttribute("patternUnits","userSpaceOnUse");var e=i.createSVGElement("image");n.appendChild(e);var a=r.uniqueId("pattern_");n.id=a,this.el=n,this.id=a,this.cfg=t;var u=o.exec(t)[2];e.setAttribute("href",u);var s=new Image;function c(){n.setAttribute("width",""+s.width),n.setAttribute("height",""+s.height)}return u.match(/^data:/i)||(s.crossOrigin="Anonymous"),s.src=u,s.complete?c():(s.onload=c,s.src=s.src),this}return t.prototype.match=function(t,n){return this.cfg===n},t}();n.default=a}])})); //# sourceMappingURL=g.min.js.map