fastlion-amis
Version:
一种MIS页面生成工具
16 lines (14 loc) • 1.29 MB
JavaScript
;/*!node_modules/zrender/dist/zrender.js*/
amis.define("8785ed3",(function(t,e,r,i){var n,o;n=this,o=function(t){"use strict";var e=function(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1},r=new function(){this.browser=new e,this.node=!1,this.wxa=!1,this.worker=!1,this.canvasSupported=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1};"object"==typeof wx&&"function"==typeof wx.getSystemInfoSync?(r.wxa=!0,r.canvasSupported=!0,r.touchEventsSupported=!0):"undefined"==typeof document&&"undefined"!=typeof self?(r.worker=!0,r.canvasSupported=!0):"undefined"==typeof navigator?(r.node=!0,r.canvasSupported=!0,r.svgSupported=!0):function(t,e){var r=e.browser,i=t.match(/Firefox\/([\d.]+)/),n=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),o=t.match(/Edge?\/([\d.]+)/),a=/micromessenger/i.test(t);i&&(r.firefox=!0,r.version=i[1]),n&&(r.ie=!0,r.version=n[1]),o&&(r.edge=!0,r.version=o[1],r.newEdge=+o[1].split(".")[0]>18),a&&(r.weChat=!0),e.canvasSupported=!!document.createElement("canvas").getContext,e.svgSupported="undefined"!=typeof SVGRect,e.touchEventsSupported="ontouchstart"in window&&!r.ie&&!r.edge,e.pointerEventsSupported="onpointerdown"in window&&(r.edge||r.ie&&+r.version>=11),e.domSupported="undefined"!=typeof document;var s=document.documentElement.style;e.transform3dSupported=(r.ie&&"transition"in s||r.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in s)&&!("OTransition"in s),e.transformSupported=e.transform3dSupported||r.ie&&+r.version>=9}(navigator.userAgent,r);var i={"[object Function]":!0,"[object RegExp]":!0,"[object Date]":!0,"[object Error]":!0,"[object CanvasGradient]":!0,"[object CanvasPattern]":!0,"[object Image]":!0,"[object Canvas]":!0},n={"[object Int8Array]":!0,"[object Uint8Array]":!0,"[object Uint8ClampedArray]":!0,"[object Int16Array]":!0,"[object Uint16Array]":!0,"[object Int32Array]":!0,"[object Uint32Array]":!0,"[object Float32Array]":!0,"[object Float64Array]":!0},o=Object.prototype.toString,a=Array.prototype,s=a.forEach,h=a.filter,l=a.slice,u=a.map,c=function(){}.constructor,p=c?c.prototype:null,f="__proto__",d={},v=2311;function y(){return v++}function g(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];"undefined"!=typeof console&&console.error.apply(console,t)}function _(t){if(null==t||"object"!=typeof t)return t;var e=t,r=o.call(t);if("[object Array]"===r){if(!G(t)){e=[];for(var a=0,s=t.length;a<s;a++)e[a]=_(t[a])}}else if(n[r]){if(!G(t)){var h=t.constructor;if(h.from)e=h.from(t);else for(e=new h(t.length),a=0,s=t.length;a<s;a++)e[a]=_(t[a])}}else if(!i[r]&&!G(t)&&!E(t))for(var l in e={},t)t.hasOwnProperty(l)&&l!==f&&(e[l]=_(t[l]));return e}function m(t,e,r){if(!I(e)||!I(t))return r?_(e):t;for(var i in e)if(e.hasOwnProperty(i)&&i!==f){var n=t[i],o=e[i];!I(o)||!I(n)||z(o)||z(n)||E(o)||E(n)||F(o)||F(n)||G(o)||G(n)?!r&&i in t||(t[i]=_(e[i])):m(n,o,r)}return t}function x(t,e){if(Object.assign)Object.assign(t,e);else for(var r in e)e.hasOwnProperty(r)&&r!==f&&(t[r]=e[r]);return t}function w(t,e,r){for(var i=A(e),n=0;n<i.length;n++){var o=i[n];(r?null!=e[o]:null==t[o])&&(t[o]=e[o])}return t}var b=function(){return d.createCanvas()};function k(t,e){if(t){if(t.indexOf)return t.indexOf(e);for(var r=0,i=t.length;r<i;r++)if(t[r]===e)return r}return-1}function S(t,e,r){if(t="prototype"in t?t.prototype:t,e="prototype"in e?e.prototype:e,Object.getOwnPropertyNames)for(var i=Object.getOwnPropertyNames(e),n=0;n<i.length;n++){var o=i[n];"constructor"!==o&&(r?null!=e[o]:null==t[o])&&(t[o]=e[o])}else w(t,e,r)}function T(t){return!!t&&"string"!=typeof t&&"number"==typeof t.length}function C(t,e,r){if(t&&e)if(t.forEach&&t.forEach===s)t.forEach(e,r);else if(t.length===+t.length)for(var i=0,n=t.length;i<n;i++)e.call(r,t[i],i,t);else for(var o in t)t.hasOwnProperty(o)&&e.call(r,t[o],o,t)}function P(t,e,r){if(!t)return[];if(!e)return X(t);if(t.map&&t.map===u)return t.map(e,r);for(var i=[],n=0,o=t.length;n<o;n++)i.push(e.call(r,t[n],n,t));return i}function M(t,e,r,i){if(t&&e){for(var n=0,o=t.length;n<o;n++)r=e.call(i,r,t[n],n,t);return r}}function A(t){if(!t)return[];if(Object.keys)return Object.keys(t);var e=[];for(var r in t)t.hasOwnProperty(r)&&e.push(r);return e}d.createCanvas=function(){return document.createElement("canvas")};var D=p&&L(p.bind)?p.call.bind(p.bind):function(t,e){for(var r=[],i=2;i<arguments.length;i++)r[i-2]=arguments[i];return function(){return t.apply(e,r.concat(l.call(arguments)))}};function z(t){return Array.isArray?Array.isArray(t):"[object Array]"===o.call(t)}function L(t){return"function"==typeof t}function R(t){return"string"==typeof t}function O(t){return"number"==typeof t}function I(t){var e=typeof t;return"function"===e||!!t&&"object"===e}function F(t){return!!i[o.call(t)]}function B(t){return!!n[o.call(t)]}function E(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}function H(t){return null!=t.colorStops}function N(t){return null!=t.image}function W(t,e){return null!=t?t:e}function U(t,e,r){return null!=t?t:null!=e?e:r}function X(t){for(var e=[],r=1;r<arguments.length;r++)e[r-1]=arguments[r];return l.apply(t,e)}function j(t){if("number"==typeof t)return[t,t,t,t];var e=t.length;return 2===e?[t[0],t[1],t[0],t[1]]:3===e?[t[0],t[1],t[2],t[1]]:t}function Y(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var q="__ec_primitive__";function G(t){return t[q]}var V=function(){function t(e){this.data={};var r=z(e);this.data={};var i=this;function n(t,e){r?i.set(t,e):i.set(e,t)}e instanceof t?e.each(n):e&&C(e,n)}return t.prototype.get=function(t){return this.data.hasOwnProperty(t)?this.data[t]:null},t.prototype.set=function(t,e){return this.data[t]=e},t.prototype.each=function(t,e){for(var r in this.data)this.data.hasOwnProperty(r)&&t.call(e,this.data[r],r)},t.prototype.keys=function(){return A(this.data)},t.prototype.removeKey=function(t){delete this.data[t]},t}();function Z(t,e){var r;if(Object.create)r=Object.create(t);else{var i=function(){};i.prototype=t,r=new i}return e&&x(r,e),r}function K(t,e){return t.hasOwnProperty(e)}function Q(){}var $=Object.freeze({__proto__:null,$override:function(t,e){d[t]=e},guid:y,logError:g,clone:_,merge:m,mergeAll:function(t,e){for(var r=t[0],i=1,n=t.length;i<n;i++)r=m(r,t[i],e);return r},extend:x,defaults:w,createCanvas:b,indexOf:k,inherits:function(t,e){var r=t.prototype;function i(){}for(var n in i.prototype=e.prototype,t.prototype=new i,r)r.hasOwnProperty(n)&&(t.prototype[n]=r[n]);t.prototype.constructor=t,t.superClass=e},mixin:S,isArrayLike:T,each:C,map:P,reduce:M,filter:function(t,e,r){if(!t)return[];if(!e)return X(t);if(t.filter&&t.filter===h)return t.filter(e,r);for(var i=[],n=0,o=t.length;n<o;n++)e.call(r,t[n],n,t)&&i.push(t[n]);return i},find:function(t,e,r){if(t&&e)for(var i=0,n=t.length;i<n;i++)if(e.call(r,t[i],i,t))return t[i]},keys:A,bind:D,curry:function(t){for(var e=[],r=1;r<arguments.length;r++)e[r-1]=arguments[r];return function(){return t.apply(this,e.concat(l.call(arguments)))}},isArray:z,isFunction:L,isString:R,isStringSafe:function(t){return"[object String]"===o.call(t)},isNumber:O,isObject:I,isBuiltInObject:F,isTypedArray:B,isDom:E,isGradientObject:H,isImagePatternObject:N,isRegExp:function(t){return"[object RegExp]"===o.call(t)},eqNaN:function(t){return t!=t},retrieve:function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];for(var r=0,i=t.length;r<i;r++)if(null!=t[r])return t[r]},retrieve2:W,retrieve3:U,slice:X,normalizeCssArray:j,assert:function(t,e){if(!t)throw new Error(e)},trim:Y,setAsPrimitive:function(t){t[q]=!0},isPrimitive:G,HashMap:V,createHashMap:function(t){return new V(t)},concatArray:function(t,e){for(var r=new t.constructor(t.length+e.length),i=0;i<t.length;i++)r[i]=t[i];var n=t.length;for(i=0;i<e.length;i++)r[i+n]=e[i];return r},createObject:Z,hasOwn:K,noop:Q}),J=function(t,e){return J=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},J(t,e)};
/*! *****************************************************************************
Copyright (c) Microsoft Corporation. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
this file except in compliance with the License. You may obtain a copy of the
License at http://www.apache.org/licenses/LICENSE-2.0
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
MERCHANTABLITY OR NON-INFRINGEMENT.
See the Apache Version 2.0 License for specific language governing permissions
and limitations under the License.
***************************************************************************** */function tt(t,e){function r(){this.constructor=t}J(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)}function et(t,e){return null==t&&(t=0),null==e&&(e=0),[t,e]}function rt(t){return[t[0],t[1]]}function it(t,e,r){return t[0]=e[0]+r[0],t[1]=e[1]+r[1],t}function nt(t,e,r){return t[0]=e[0]-r[0],t[1]=e[1]-r[1],t}function ot(t){return Math.sqrt(st(t))}var at=ot;function st(t){return t[0]*t[0]+t[1]*t[1]}var ht=st;function lt(t,e,r){return t[0]=e[0]*r,t[1]=e[1]*r,t}function ut(t,e){var r=ot(e);return 0===r?(t[0]=0,t[1]=0):(t[0]=e[0]/r,t[1]=e[1]/r),t}function ct(t,e){return Math.sqrt((t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1]))}var pt=ct;function ft(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])}var dt=ft;function vt(t,e,r,i){return t[0]=e[0]+i*(r[0]-e[0]),t[1]=e[1]+i*(r[1]-e[1]),t}function yt(t,e,r){var i=e[0],n=e[1];return t[0]=r[0]*i+r[2]*n+r[4],t[1]=r[1]*i+r[3]*n+r[5],t}function gt(t,e,r){return t[0]=Math.min(e[0],r[0]),t[1]=Math.min(e[1],r[1]),t}function _t(t,e,r){return t[0]=Math.max(e[0],r[0]),t[1]=Math.max(e[1],r[1]),t}var mt=Object.freeze({__proto__:null,create:et,copy:function(t,e){return t[0]=e[0],t[1]=e[1],t},clone:rt,set:function(t,e,r){return t[0]=e,t[1]=r,t},add:it,scaleAndAdd:function(t,e,r,i){return t[0]=e[0]+r[0]*i,t[1]=e[1]+r[1]*i,t},sub:nt,len:ot,length:at,lenSquare:st,lengthSquare:ht,mul:function(t,e,r){return t[0]=e[0]*r[0],t[1]=e[1]*r[1],t},div:function(t,e,r){return t[0]=e[0]/r[0],t[1]=e[1]/r[1],t},dot:function(t,e){return t[0]*e[0]+t[1]*e[1]},scale:lt,normalize:ut,distance:ct,dist:pt,distanceSquare:ft,distSquare:dt,negate:function(t,e){return t[0]=-e[0],t[1]=-e[1],t},lerp:vt,applyTransform:yt,min:gt,max:_t}),xt=function(t,e){this.target=t,this.topTarget=e&&e.topTarget},wt=function(){function t(t){this.handler=t,t.on("mousedown",this._dragStart,this),t.on("mousemove",this._drag,this),t.on("mouseup",this._dragEnd,this)}return t.prototype._dragStart=function(t){for(var e=t.target;e&&!e.draggable;)e=e.parent;e&&(this._draggingTarget=e,e.dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.handler.dispatchToElement(new xt(e,t),"dragstart",t.event))},t.prototype._drag=function(t){var e=this._draggingTarget;if(e){var r=t.offsetX,i=t.offsetY,n=r-this._x,o=i-this._y;this._x=r,this._y=i,e.drift(n,o,t),this.handler.dispatchToElement(new xt(e,t),"drag",t.event);var a=this.handler.findHover(r,i,e).target,s=this._dropTarget;this._dropTarget=a,e!==a&&(s&&a!==s&&this.handler.dispatchToElement(new xt(s,t),"dragleave",t.event),a&&a!==s&&this.handler.dispatchToElement(new xt(a,t),"dragenter",t.event))}},t.prototype._dragEnd=function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.handler.dispatchToElement(new xt(e,t),"dragend",t.event),this._dropTarget&&this.handler.dispatchToElement(new xt(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null},t}(),bt=function(){function t(t){t&&(this._$eventProcessor=t)}return t.prototype.on=function(t,e,r,i){this._$handlers||(this._$handlers={});var n=this._$handlers;if("function"==typeof e&&(i=r,r=e,e=null),!r||!t)return this;var o=this._$eventProcessor;null!=e&&o&&o.normalizeQuery&&(e=o.normalizeQuery(e)),n[t]||(n[t]=[]);for(var a=0;a<n[t].length;a++)if(n[t][a].h===r)return this;var s={h:r,query:e,ctx:i||this,callAtLast:r.zrEventfulCallAtLast},h=n[t].length-1,l=n[t][h];return l&&l.callAtLast?n[t].splice(h,0,s):n[t].push(s),this},t.prototype.isSilent=function(t){var e=this._$handlers;return!e||!e[t]||!e[t].length},t.prototype.off=function(t,e){var r=this._$handlers;if(!r)return this;if(!t)return this._$handlers={},this;if(e){if(r[t]){for(var i=[],n=0,o=r[t].length;n<o;n++)r[t][n].h!==e&&i.push(r[t][n]);r[t]=i}r[t]&&0===r[t].length&&delete r[t]}else delete r[t];return this},t.prototype.trigger=function(t){for(var e=[],r=1;r<arguments.length;r++)e[r-1]=arguments[r];if(!this._$handlers)return this;var i=this._$handlers[t],n=this._$eventProcessor;if(i)for(var o=e.length,a=i.length,s=0;s<a;s++){var h=i[s];if(!n||!n.filter||null==h.query||n.filter(t,h.query))switch(o){case 0:h.h.call(h.ctx);break;case 1:h.h.call(h.ctx,e[0]);break;case 2:h.h.call(h.ctx,e[0],e[1]);break;default:h.h.apply(h.ctx,e)}}return n&&n.afterTrigger&&n.afterTrigger(t),this},t.prototype.triggerWithContext=function(t){for(var e=[],r=1;r<arguments.length;r++)e[r-1]=arguments[r];if(!this._$handlers)return this;var i=this._$handlers[t],n=this._$eventProcessor;if(i)for(var o=e.length,a=e[o-1],s=i.length,h=0;h<s;h++){var l=i[h];if(!n||!n.filter||null==l.query||n.filter(t,l.query))switch(o){case 0:l.h.call(a);break;case 1:l.h.call(a,e[0]);break;case 2:l.h.call(a,e[0],e[1]);break;default:l.h.apply(a,e.slice(1,o-1))}}return n&&n.afterTrigger&&n.afterTrigger(t),this},t}(),kt=Math.log(2);function St(t,e,r,i,n,o){var a=i+"-"+n,s=t.length;if(o.hasOwnProperty(a))return o[a];if(1===e){var h=Math.round(Math.log((1<<s)-1&~n)/kt);return t[r][h]}for(var l=i|1<<r,u=r+1;i&1<<u;)u++;for(var c=0,p=0,f=0;p<s;p++){var d=1<<p;d&n||(c+=(f%2?-1:1)*t[r][p]*St(t,e-1,u,l,n|d,o),f++)}return o[a]=c,c}function Tt(t,e){var r=[[t[0],t[1],1,0,0,0,-e[0]*t[0],-e[0]*t[1]],[0,0,0,t[0],t[1],1,-e[1]*t[0],-e[1]*t[1]],[t[2],t[3],1,0,0,0,-e[2]*t[2],-e[2]*t[3]],[0,0,0,t[2],t[3],1,-e[3]*t[2],-e[3]*t[3]],[t[4],t[5],1,0,0,0,-e[4]*t[4],-e[4]*t[5]],[0,0,0,t[4],t[5],1,-e[5]*t[4],-e[5]*t[5]],[t[6],t[7],1,0,0,0,-e[6]*t[6],-e[6]*t[7]],[0,0,0,t[6],t[7],1,-e[7]*t[6],-e[7]*t[7]]],i={},n=St(r,8,0,0,0,i);if(0!==n){for(var o=[],a=0;a<8;a++)for(var s=0;s<8;s++)null==o[s]&&(o[s]=0),o[s]+=((a+s)%2?-1:1)*St(r,7,0===a?1:0,1<<a,1<<s,i)/n*e[a];return function(t,e,r){var i=e*o[6]+r*o[7]+1;t[0]=(e*o[0]+r*o[1]+o[2])/i,t[1]=(e*o[3]+r*o[4]+o[5])/i}}}function Ct(t,e,i,n,o){if(e.getBoundingClientRect&&r.domSupported&&!Pt(e)){var a=e.___zrEVENTSAVED||(e.___zrEVENTSAVED={}),s=function(t,e){var r=e.markers;if(r)return r;r=e.markers=[];for(var i=["left","right"],n=["top","bottom"],o=0;o<4;o++){var a=document.createElement("div"),s=o%2,h=(o>>1)%2;a.style.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",i[s]+":0",n[h]+":0",i[1-s]+":auto",n[1-h]+":auto",""].join("!important;"),t.appendChild(a),r.push(a)}return r}(e,a),h=function(t,e,r){for(var i=r?"invTrans":"trans",n=e[i],o=e.srcCoords,a=[],s=[],h=!0,l=0;l<4;l++){var u=t[l].getBoundingClientRect(),c=2*l,p=u.left,f=u.top;a.push(p,f),h=h&&o&&p===o[c]&&f===o[c+1],s.push(t[l].offsetLeft,t[l].offsetTop)}return h&&n?n:(e.srcCoords=a,e[i]=r?Tt(s,a):Tt(a,s))}(s,a,o);if(h)return h(t,i,n),!0}return!1}function Pt(t){return"CANVAS"===t.nodeName.toUpperCase()}var Mt="undefined"!=typeof window&&!!window.addEventListener,At=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Dt=[];function zt(t,e,i,n){return i=i||{},n||!r.canvasSupported?Lt(t,e,i):r.browser.firefox&&r.browser.version<"39"&&null!=e.layerX&&e.layerX!==e.offsetX?(i.zrX=e.layerX,i.zrY=e.layerY):null!=e.offsetX?(i.zrX=e.offsetX,i.zrY=e.offsetY):Lt(t,e,i),i}function Lt(t,e,i){if(r.domSupported&&t.getBoundingClientRect){var n=e.clientX,o=e.clientY;if(Pt(t)){var a=t.getBoundingClientRect();return i.zrX=n-a.left,void(i.zrY=o-a.top)}if(Ct(Dt,t,n,o))return i.zrX=Dt[0],void(i.zrY=Dt[1])}i.zrX=i.zrY=0}function Rt(t){return t||window.event}function Ot(t,e,r){if(null!=(e=Rt(e)).zrX)return e;var i=e.type;if(i&&i.indexOf("touch")>=0){var n="touchend"!==i?e.targetTouches[0]:e.changedTouches[0];n&&zt(t,n,e,r)}else{zt(t,e,e,r);var o=function(t){var e=t.wheelDelta;if(e)return e;var r=t.deltaX,i=t.deltaY;return null==r||null==i?e:3*(0!==i?Math.abs(i):Math.abs(r))*(i>0?-1:i<0?1:r>0?-1:1)}(e);e.zrDelta=o?o/120:-(e.detail||0)/3}var a=e.button;return null==e.which&&void 0!==a&&At.test(e.type)&&(e.which=1&a?1:2&a?3:4&a?2:0),e}var It=Mt?function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0}:function(t){t.returnValue=!1,t.cancelBubble=!0},Ft=function(){function t(){this._track=[]}return t.prototype.recognize=function(t,e,r){return this._doTrack(t,e,r),this._recognize(t)},t.prototype.clear=function(){return this._track.length=0,this},t.prototype._doTrack=function(t,e,r){var i=t.touches;if(i){for(var n={points:[],touches:[],target:e,event:t},o=0,a=i.length;o<a;o++){var s=i[o],h=zt(r,s,{});n.points.push([h.zrX,h.zrY]),n.touches.push(s)}this._track.push(n)}},t.prototype._recognize=function(t){for(var e in Et)if(Et.hasOwnProperty(e)){var r=Et[e](this._track,t);if(r)return r}},t}();function Bt(t){var e=t[1][0]-t[0][0],r=t[1][1]-t[0][1];return Math.sqrt(e*e+r*r)}var Et={pinch:function(t,e){var r=t.length;if(r){var i,n=(t[r-1]||{}).points,o=(t[r-2]||{}).points||n;if(o&&o.length>1&&n&&n.length>1){var a=Bt(n)/Bt(o);!isFinite(a)&&(a=1),e.pinchScale=a;var s=[((i=n)[0][0]+i[1][0])/2,(i[0][1]+i[1][1])/2];return e.pinchX=s[0],e.pinchY=s[1],{type:"pinch",target:t[0].target,event:e}}}}},Ht="silent";function Nt(){It(this.event)}var Wt=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.handler=null,e}return tt(e,t),e.prototype.dispose=function(){},e.prototype.setCursor=function(){},e}(bt),Ut=function(t,e){this.x=t,this.y=e},Xt=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],jt=function(t){function e(e,r,i,n){var o=t.call(this)||this;return o._hovered=new Ut(0,0),o.storage=e,o.painter=r,o.painterRoot=n,i=i||new Wt,o.proxy=null,o.setHandlerProxy(i),o._draggingMgr=new wt(o),o}return tt(e,t),e.prototype.setHandlerProxy=function(t){this.proxy&&this.proxy.dispose(),t&&(C(Xt,(function(e){t.on&&t.on(e,this[e],this)}),this),t.handler=this),this.proxy=t},e.prototype.mousemove=function(t){var e=t.zrX,r=t.zrY,i=qt(this,e,r),n=this._hovered,o=n.target;o&&!o.__zr&&(o=(n=this.findHover(n.x,n.y)).target);var a=this._hovered=i?new Ut(e,r):this.findHover(e,r),s=a.target,h=this.proxy;h.setCursor&&h.setCursor(s?s.cursor:"default"),o&&s!==o&&this.dispatchToElement(n,"mouseout",t),this.dispatchToElement(a,"mousemove",t),s&&s!==o&&this.dispatchToElement(a,"mouseover",t)},e.prototype.mouseout=function(t){var e=t.zrEventControl;"only_globalout"!==e&&this.dispatchToElement(this._hovered,"mouseout",t),"no_globalout"!==e&&this.trigger("globalout",{type:"globalout",event:t})},e.prototype.resize=function(){this._hovered=new Ut(0,0)},e.prototype.dispatch=function(t,e){var r=this[t];r&&r.call(this,e)},e.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},e.prototype.setCursorStyle=function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},e.prototype.dispatchToElement=function(t,e,r){var i=(t=t||{}).target;if(!i||!i.silent){for(var n="on"+e,o=function(t,e,r){return{type:t,event:r,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:r.zrX,offsetY:r.zrY,gestureEvent:r.gestureEvent,pinchX:r.pinchX,pinchY:r.pinchY,pinchScale:r.pinchScale,wheelDelta:r.zrDelta,zrByTouch:r.zrByTouch,which:r.which,stop:Nt}}(e,t,r);i&&(i[n]&&(o.cancelBubble=!!i[n].call(i,o)),i.trigger(e,o),i=i.__hostTarget?i.__hostTarget:i.parent,!o.cancelBubble););o.cancelBubble||(this.trigger(e,o),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer((function(t){"function"==typeof t[n]&&t[n].call(t,o),t.trigger&&t.trigger(e,o)})))}},e.prototype.findHover=function(t,e,r){for(var i=this.storage.getDisplayList(),n=new Ut(t,e),o=i.length-1;o>=0;o--){var a=void 0;if(i[o]!==r&&!i[o].ignore&&(a=Yt(i[o],t,e))&&(!n.topTarget&&(n.topTarget=i[o]),a!==Ht)){n.target=i[o];break}}return n},e.prototype.processGesture=function(t,e){this._gestureMgr||(this._gestureMgr=new Ft);var r=this._gestureMgr;"start"===e&&r.clear();var i=r.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if("end"===e&&r.clear(),i){var n=i.type;t.gestureEvent=n;var o=new Ut;o.target=i.target,this.dispatchToElement(o,n,i.event)}},e}(bt);function Yt(t,e,r){if(t[t.rectHover?"rectContain":"contain"](e,r)){for(var i=t,n=void 0,o=!1;i;){if(i.ignoreClip&&(o=!0),!o){var a=i.getClipPath();if(a&&!a.contain(e,r))return!1;i.silent&&(n=!0)}var s=i.__hostTarget;i=s||i.parent}return!n||Ht}return!1}function qt(t,e,r){var i=t.painter;return e<0||e>i.getWidth()||r<0||r>i.getHeight()}function Gt(t,e,r,i){var n=e+1;if(n===r)return 1;if(i(t[n++],t[e])<0){for(;n<r&&i(t[n],t[n-1])<0;)n++;!function(t,e,r){for(r--;e<r;){var i=t[e];t[e++]=t[r],t[r--]=i}}(t,e,n)}else for(;n<r&&i(t[n],t[n-1])>=0;)n++;return n-e}function Vt(t,e,r,i,n){for(i===e&&i++;i<r;i++){for(var o,a=t[i],s=e,h=i;s<h;)n(a,t[o=s+h>>>1])<0?h=o:s=o+1;var l=i-s;switch(l){case 3:t[s+3]=t[s+2];case 2:t[s+2]=t[s+1];case 1:t[s+1]=t[s];break;default:for(;l>0;)t[s+l]=t[s+l-1],l--}t[s]=a}}function Zt(t,e,r,i,n,o){var a=0,s=0,h=1;if(o(t,e[r+n])>0){for(s=i-n;h<s&&o(t,e[r+n+h])>0;)a=h,(h=1+(h<<1))<=0&&(h=s);h>s&&(h=s),a+=n,h+=n}else{for(s=n+1;h<s&&o(t,e[r+n-h])<=0;)a=h,(h=1+(h<<1))<=0&&(h=s);h>s&&(h=s);var l=a;a=n-h,h=n-l}for(a++;a<h;){var u=a+(h-a>>>1);o(t,e[r+u])>0?a=u+1:h=u}return h}function Kt(t,e,r,i,n,o){var a=0,s=0,h=1;if(o(t,e[r+n])<0){for(s=n+1;h<s&&o(t,e[r+n-h])<0;)a=h,(h=1+(h<<1))<=0&&(h=s);h>s&&(h=s);var l=a;a=n-h,h=n-l}else{for(s=i-n;h<s&&o(t,e[r+n+h])>=0;)a=h,(h=1+(h<<1))<=0&&(h=s);h>s&&(h=s),a+=n,h+=n}for(a++;a<h;){var u=a+(h-a>>>1);o(t,e[r+u])<0?h=u:a=u+1}return h}function Qt(t,e){var r,i,n=7,o=0;t.length;var a=[];function s(s){var h=r[s],l=i[s],u=r[s+1],c=i[s+1];i[s]=l+c,s===o-3&&(r[s+1]=r[s+2],i[s+1]=i[s+2]),o--;var p=Kt(t[u],t,h,l,0,e);h+=p,0!=(l-=p)&&0!==(c=Zt(t[h+l-1],t,u,c,c-1,e))&&(l<=c?function(r,i,o,s){var h=0;for(h=0;h<i;h++)a[h]=t[r+h];var l=0,u=o,c=r;if(t[c++]=t[u++],0!=--s)if(1!==i){for(var p,f,d,v=n;;){p=0,f=0,d=!1;do{if(e(t[u],a[l])<0){if(t[c++]=t[u++],f++,p=0,0==--s){d=!0;break}}else if(t[c++]=a[l++],p++,f=0,1==--i){d=!0;break}}while((p|f)<v);if(d)break;do{if(0!==(p=Kt(t[u],a,l,i,0,e))){for(h=0;h<p;h++)t[c+h]=a[l+h];if(c+=p,l+=p,(i-=p)<=1){d=!0;break}}if(t[c++]=t[u++],0==--s){d=!0;break}if(0!==(f=Zt(a[l],t,u,s,0,e))){for(h=0;h<f;h++)t[c+h]=t[u+h];if(c+=f,u+=f,0==(s-=f)){d=!0;break}}if(t[c++]=a[l++],1==--i){d=!0;break}v--}while(p>=7||f>=7);if(d)break;v<0&&(v=0),v+=2}if((n=v)<1&&(n=1),1===i){for(h=0;h<s;h++)t[c+h]=t[u+h];t[c+s]=a[l]}else{if(0===i)throw new Error;for(h=0;h<i;h++)t[c+h]=a[l+h]}}else{for(h=0;h<s;h++)t[c+h]=t[u+h];t[c+s]=a[l]}else for(h=0;h<i;h++)t[c+h]=a[l+h]}(h,l,u,c):function(r,i,o,s){var h=0;for(h=0;h<s;h++)a[h]=t[o+h];var l=r+i-1,u=s-1,c=o+s-1,p=0,f=0;if(t[c--]=t[l--],0!=--i)if(1!==s){for(var d=n;;){var v=0,y=0,g=!1;do{if(e(a[u],t[l])<0){if(t[c--]=t[l--],v++,y=0,0==--i){g=!0;break}}else if(t[c--]=a[u--],y++,v=0,1==--s){g=!0;break}}while((v|y)<d);if(g)break;do{if(0!=(v=i-Kt(a[u],t,r,i,i-1,e))){for(i-=v,f=1+(c-=v),p=1+(l-=v),h=v-1;h>=0;h--)t[f+h]=t[p+h];if(0===i){g=!0;break}}if(t[c--]=a[u--],1==--s){g=!0;break}if(0!=(y=s-Zt(t[l],a,0,s,s-1,e))){for(s-=y,f=1+(c-=y),p=1+(u-=y),h=0;h<y;h++)t[f+h]=a[p+h];if(s<=1){g=!0;break}}if(t[c--]=t[l--],0==--i){g=!0;break}d--}while(v>=7||y>=7);if(g)break;d<0&&(d=0),d+=2}if((n=d)<1&&(n=1),1===s){for(f=1+(c-=i),p=1+(l-=i),h=i-1;h>=0;h--)t[f+h]=t[p+h];t[c]=a[u]}else{if(0===s)throw new Error;for(p=c-(s-1),h=0;h<s;h++)t[p+h]=a[h]}}else{for(f=1+(c-=i),p=1+(l-=i),h=i-1;h>=0;h--)t[f+h]=t[p+h];t[c]=a[u]}else for(p=c-(s-1),h=0;h<s;h++)t[p+h]=a[h]}(h,l,u,c))}return r=[],i=[],{mergeRuns:function(){for(;o>1;){var t=o-2;if(t>=1&&i[t-1]<=i[t]+i[t+1]||t>=2&&i[t-2]<=i[t]+i[t-1])i[t-1]<i[t+1]&&t--;else if(i[t]>i[t+1])break;s(t)}},forceMergeRuns:function(){for(;o>1;){var t=o-2;t>0&&i[t-1]<i[t+1]&&t--,s(t)}},pushRun:function(t,e){r[o]=t,i[o]=e,o+=1}}}C(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],(function(t){jt.prototype[t]=function(e){var r,i,n=e.zrX,o=e.zrY,a=qt(this,n,o);if("mouseup"===t&&a||(i=(r=this.findHover(n,o)).target),"mousedown"===t)this._downEl=i,this._downPoint=[e.zrX,e.zrY],this._upEl=i;else if("mouseup"===t)this._upEl=i;else if("click"===t){if(this._downEl!==this._upEl||!this._downPoint||pt(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(r,t,e)}}));var $t=!1;function Jt(){$t||($t=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function te(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}var ee=function(){function t(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=te}return t.prototype.traverse=function(t,e){for(var r=0;r<this._roots.length;r++)this._roots[r].traverse(t,e)},t.prototype.getDisplayList=function(t,e){e=e||!1;var r=this._displayList;return!t&&r.length||this.updateDisplayList(e),r},t.prototype.updateDisplayList=function(t){this._displayListLen=0;for(var e=this._roots,i=this._displayList,n=0,o=e.length;n<o;n++)this._updateAndAddDisplayable(e[n],null,t);i.length=this._displayListLen,r.canvasSupported&&function(t,e,r,i){r||(r=0),i||(i=t.length);var n=i-r;if(!(n<2)){var o=0;if(n<32)Vt(t,r,i,r+(o=Gt(t,r,i,e)),e);else{var a=Qt(t,e),s=function(t){for(var e=0;t>=32;)e|=1&t,t>>=1;return t+e}(n);do{if((o=Gt(t,r,i,e))<s){var h=n;h>s&&(h=s),Vt(t,r,r+h,r+o,e),o=h}a.pushRun(r,o),a.mergeRuns(),n-=o,r+=o}while(0!==n);a.forceMergeRuns()}}}(i,te)},t.prototype._updateAndAddDisplayable=function(t,e,r){if(!t.ignore||r){t.beforeUpdate(),t.update(),t.afterUpdate();var i=t.getClipPath();if(t.ignoreClip)e=null;else if(i){e=e?e.slice():[];for(var n=i,o=t;n;)n.parent=o,n.updateTransform(),e.push(n),o=n,n=n.getClipPath()}if(t.childrenRef){for(var a=t.childrenRef(),s=0;s<a.length;s++){var h=a[s];t.__dirty&&(h.__dirty|=1),this._updateAndAddDisplayable(h,e,r)}t.__dirty=0}else{var l=t;e&&e.length?l.__clipPaths=e:l.__clipPaths&&l.__clipPaths.length>0&&(l.__clipPaths=[]),isNaN(l.z)&&(Jt(),l.z=0),isNaN(l.z2)&&(Jt(),l.z2=0),isNaN(l.zlevel)&&(Jt(),l.zlevel=0),this._displayList[this._displayListLen++]=l}var u=t.getDecalElement&&t.getDecalElement();u&&this._updateAndAddDisplayable(u,e,r);var c=t.getTextGuideLine();c&&this._updateAndAddDisplayable(c,e,r);var p=t.getTextContent();p&&this._updateAndAddDisplayable(p,e,r)}},t.prototype.addRoot=function(t){t.__zr&&t.__zr.storage===this||this._roots.push(t)},t.prototype.delRoot=function(t){if(t instanceof Array)for(var e=0,r=t.length;e<r;e++)this.delRoot(t[e]);else{var i=k(this._roots,t);i>=0&&this._roots.splice(i,1)}},t.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},t.prototype.getRoots=function(){return this._roots},t.prototype.dispose=function(){this._displayList=null,this._roots=null},t}(),re="undefined"!=typeof window&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){return setTimeout(t,16)},ie={linear:function(t){return t},quadraticIn:function(t){return t*t},quadraticOut:function(t){return t*(2-t)},quadraticInOut:function(t){return(t*=2)<1?.5*t*t:-.5*(--t*(t-2)-1)},cubicIn:function(t){return t*t*t},cubicOut:function(t){return--t*t*t+1},cubicInOut:function(t){return(t*=2)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},quarticIn:function(t){return t*t*t*t},quarticOut:function(t){return 1- --t*t*t*t},quarticInOut:function(t){return(t*=2)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},quinticIn:function(t){return t*t*t*t*t},quinticOut:function(t){return--t*t*t*t*t+1},quinticInOut:function(t){return(t*=2)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},sinusoidalIn:function(t){return 1-Math.cos(t*Math.PI/2)},sinusoidalOut:function(t){return Math.sin(t*Math.PI/2)},sinusoidalInOut:function(t){return.5*(1-Math.cos(Math.PI*t))},exponentialIn:function(t){return 0===t?0:Math.pow(1024,t-1)},exponentialOut:function(t){return 1===t?1:1-Math.pow(2,-10*t)},exponentialInOut:function(t){return 0===t?0:1===t?1:(t*=2)<1?.5*Math.pow(1024,t-1):.5*(2-Math.pow(2,-10*(t-1)))},circularIn:function(t){return 1-Math.sqrt(1-t*t)},circularOut:function(t){return Math.sqrt(1- --t*t)},circularInOut:function(t){return(t*=2)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},elasticIn:function(t){var e,r=.1;return 0===t?0:1===t?1:(!r||r<1?(r=1,e=.1):e=.4*Math.asin(1/r)/(2*Math.PI),-r*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4))},elasticOut:function(t){var e,r=.1;return 0===t?0:1===t?1:(!r||r<1?(r=1,e=.1):e=.4*Math.asin(1/r)/(2*Math.PI),r*Math.pow(2,-10*t)*Math.sin((t-e)*(2*Math.PI)/.4)+1)},elasticInOut:function(t){var e,r=.1,i=.4;return 0===t?0:1===t?1:(!r||r<1?(r=1,e=.1):e=i*Math.asin(1/r)/(2*Math.PI),(t*=2)<1?r*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/i)*-.5:r*Math.pow(2,-10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/i)*.5+1)},backIn:function(t){var e=1.70158;return t*t*((e+1)*t-e)},backOut:function(t){var e=1.70158;return--t*t*((e+1)*t+e)+1},backInOut:function(t){var e=2.5949095;return(t*=2)<1?t*t*((e+1)*t-e)*.5:.5*((t-=2)*t*((e+1)*t+e)+2)},bounceIn:function(t){return 1-ie.bounceOut(1-t)},bounceOut:function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return t<.5?.5*ie.bounceIn(2*t):.5*ie.bounceOut(2*t-1)+.5}},ne=function(){function t(t){this._initialized=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=t.life||1e3,this._delay=t.delay||0,this.loop=null!=t.loop&&t.loop,this.gap=t.gap||0,this.easing=t.easing||"linear",this.onframe=t.onframe,this.ondestroy=t.ondestroy,this.onrestart=t.onrestart}return t.prototype.step=function(t,e){if(this._initialized||(this._startTime=t+this._delay,this._initialized=!0),!this._paused){var r=(t-this._startTime-this._pausedTime)/this._life;r<0&&(r=0),r=Math.min(r,1);var i=this.easing,n="string"==typeof i?ie[i]:i,o="function"==typeof n?n(r):r;if(this.onframe&&this.onframe(o),1===r){if(!this.loop)return!0;this._restart(t),this.onrestart&&this.onrestart()}return!1}this._pausedTime+=e},t.prototype._restart=function(t){var e=(t-this._startTime-this._pausedTime)%this._life;this._startTime=t-e+this.gap,this._pausedTime=0},t.prototype.pause=function(){this._paused=!0},t.prototype.resume=function(){this._paused=!1},t}(),oe=function(t){this.value=t},ae=function(){function t(){this._len=0}return t.prototype.insert=function(t){var e=new oe(t);return this.insertEntry(e),e},t.prototype.insertEntry=function(t){this.head?(this.tail.next=t,t.prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},t.prototype.remove=function(t){var e=t.prev,r=t.next;e?e.next=r:this.head=r,r?r.prev=e:this.tail=e,t.next=t.prev=null,this._len--},t.prototype.len=function(){return this._len},t.prototype.clear=function(){this.head=this.tail=null,this._len=0},t}(),se=function(){function t(t){this._list=new ae,this._maxSize=10,this._map={},this._maxSize=t}return t.prototype.put=function(t,e){var r=this._list,i=this._map,n=null;if(null==i[t]){var o=r.len(),a=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var s=r.head;r.remove(s),delete i[s.key],n=s.value,this._lastRemovedEntry=s}a?a.value=e:a=new oe(e),a.key=t,r.insertEntry(a),i[t]=a}return n},t.prototype.get=function(t){var e=this._map[t],r=this._list;if(null!=e)return e!==r.tail&&(r.remove(e),r.insertEntry(e)),e.value},t.prototype.clear=function(){this._list.clear(),this._map={}},t.prototype.len=function(){return this._list.len()},t}(),he={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function le(t){return(t=Math.round(t))<0?0:t>255?255:t}function ue(t){return t<0?0:t>1?1:t}function ce(t){var e=t;return e.length&&"%"===e.charAt(e.length-1)?le(parseFloat(e)/100*255):le(parseInt(e,10))}function pe(t){var e=t;return e.length&&"%"===e.charAt(e.length-1)?ue(parseFloat(e)/100):ue(parseFloat(e))}function fe(t,e,r){return r<0?r+=1:r>1&&(r-=1),6*r<1?t+(e-t)*r*6:2*r<1?e:3*r<2?t+(e-t)*(2/3-r)*6:t}function de(t,e,r){return t+(e-t)*r}function ve(t,e,r,i,n){return t[0]=e,t[1]=r,t[2]=i,t[3]=n,t}function ye(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}var ge=new se(20),_e=null;function me(t,e){_e&&ye(_e,e),_e=ge.put(t,_e||e.slice())}function xe(t,e){if(t){e=e||[];var r=ge.get(t);if(r)return ye(e,r);var i=(t+="").replace(/ /g,"").toLowerCase();if(i in he)return ye(e,he[i]),me(t,e),e;var n,o=i.length;if("#"===i.charAt(0))return 4===o||5===o?(n=parseInt(i.slice(1,4),16))>=0&&n<=4095?(ve(e,(3840&n)>>4|(3840&n)>>8,240&n|(240&n)>>4,15&n|(15&n)<<4,5===o?parseInt(i.slice(4),16)/15:1),me(t,e),e):void ve(e,0,0,0,1):7===o||9===o?(n=parseInt(i.slice(1,7),16))>=0&&n<=16777215?(ve(e,(16711680&n)>>16,(65280&n)>>8,255&n,9===o?parseInt(i.slice(7),16)/255:1),me(t,e),e):void ve(e,0,0,0,1):void 0;var a=i.indexOf("("),s=i.indexOf(")");if(-1!==a&&s+1===o){var h=i.substr(0,a),l=i.substr(a+1,s-(a+1)).split(","),u=1;switch(h){case"rgba":if(4!==l.length)return 3===l.length?ve(e,+l[0],+l[1],+l[2],1):ve(e,0,0,0,1);u=pe(l.pop());case"rgb":return 3!==l.length?void ve(e,0,0,0,1):(ve(e,ce(l[0]),ce(l[1]),ce(l[2]),u),me(t,e),e);case"hsla":return 4!==l.length?void ve(e,0,0,0,1):(l[3]=pe(l[3]),we(l,e),me(t,e),e);case"hsl":return 3!==l.length?void ve(e,0,0,0,1):(we(l,e),me(t,e),e);default:return}}ve(e,0,0,0,1)}}function we(t,e){var r=(parseFloat(t[0])%360+360)%360/360,i=pe(t[1]),n=pe(t[2]),o=n<=.5?n*(i+1):n+i-n*i,a=2*n-o;return ve(e=e||[],le(255*fe(a,o,r+1/3)),le(255*fe(a,o,r)),le(255*fe(a,o,r-1/3)),1),4===t.length&&(e[3]=t[3]),e}function be(t){var e=xe(t);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)}function ke(t,e,r){if(e&&e.length&&t>=0&&t<=1){r=r||[];var i=t*(e.length-1),n=Math.floor(i),o=Math.ceil(i),a=e[n],s=e[o],h=i-n;return r[0]=le(de(a[0],s[0],h)),r[1]=le(de(a[1],s[1],h)),r[2]=le(de(a[2],s[2],h)),r[3]=ue(de(a[3],s[3],h)),r}}var Se=ke;function Te(t,e,r){if(e&&e.length&&t>=0&&t<=1){var i=t*(e.length-1),n=Math.floor(i),o=Math.ceil(i),a=xe(e[n]),s=xe(e[o]),h=i-n,l=Pe([le(de(a[0],s[0],h)),le(de(a[1],s[1],h)),le(de(a[2],s[2],h)),ue(de(a[3],s[3],h))],"rgba");return r?{color:l,leftIndex:n,rightIndex:o,value:i}:l}}var Ce=Te;function Pe(t,e){if(t&&t.length){var r=t[0]+","+t[1]+","+t[2];return"rgba"!==e&&"hsva"!==e&&"hsla"!==e||(r+=","+t[3]),e+"("+r+")"}}function Me(t,e){var r=xe(t);return r?(.299*r[0]+.587*r[1]+.114*r[2])*r[3]/255+(1-r[3])*e:0}var Ae=Object.freeze({__proto__:null,parse:xe,lift:function(t,e){var r=xe(t);if(r){for(var i=0;i<3;i++)r[i]=e<0?r[i]*(1-e)|0:(255-r[i])*e+r[i]|0,r[i]>255?r[i]=255:r[i]<0&&(r[i]=0);return Pe(r,4===r.length?"rgba":"rgb")}},toHex:be,fastLerp:ke,fastMapToColor:Se,lerp:Te,mapToColor:Ce,modifyHSL:function(t,e,r,i){var n,o=xe(t);if(t)return o=function(t){if(t){var e,r,i=t[0]/255,n=t[1]/255,o=t[2]/255,a=Math.min(i,n,o),s=Math.max(i,n,o),h=s-a,l=(s+a)/2;if(0===h)e=0,r=0;else{r=l<.5?h/(s+a):h/(2-s-a);var u=((s-i)/6+h/2)/h,c=((s-n)/6+h/2)/h,p=((s-o)/6+h/2)/h;i===s?e=p-c:n===s?e=1/3+u-p:o===s&&(e=2/3+c-u),e<0&&(e+=1),e>1&&(e-=1)}var f=[360*e,r,l];return null!=t[3]&&f.push(t[3]),f}}(o),null!=e&&(o[0]=(n=e,(n=Math.round(n))<0?0:n>360?360:n)),null!=r&&(o[1]=pe(r)),null!=i&&(o[2]=pe(i)),Pe(we(o),"rgba")},modifyAlpha:function(t,e){var r=xe(t);if(r&&null!=e)return r[3]=ue(e),Pe(r,"rgba")},stringify:Pe,lum:Me,random:function(){return"rgb("+Math.round(255*Math.random())+","+Math.round(255*Math.random())+","+Math.round(255*Math.random())+")"}}),De=Array.prototype.slice;function ze(t,e,r){return(e-t)*r+t}function Le(t,e,r,i){for(var n=e.length,o=0;o<n;o++)t[o]=ze(e[o],r[o],i)}function Re(t,e,r,i){for(var n=e.length,o=0;o<n;o++)t[o]=e[o]+r[o]*i;return t}function Oe(t,e,r,i){for(var n=e.length,o=n&&e[0].length,a=0;a<n;a++){t[a]||(t[a]=[]);for(var s=0;s<o;s++)t[a][s]=e[a][s]+r[a][s]*i}return t}function Ie(t,e,r){var i=t,n=e;if(i.push&&n.push){var o=i.length,a=n.length;if(o!==a)if(o>a)i.length=a;else for(var s=o;s<a;s++)i.push(1===r?n[s]:De.call(n[s]));var h=i[0]&&i[0].length;for(s=0;s<i.length;s++)if(1===r)isNaN(i[s])&&(i[s]=n[s]);else for(var l=0;l<h;l++)isNaN(i[s][l])&&(i[s][l]=n[s][l])}}function Fe(t,e){var r=t.length;if(r!==e.length)return!1;for(var i=0;i<r;i++)if(t[i]!==e[i])return!1;return!0}function Be(t,e,r,i,n,o,a){var s=.5*(r-t),h=.5*(i-e);return(2*(e-r)+s+h)*a+(-3*(e-r)-2*s-h)*o+s*n+e}function Ee(t,e,r,i,n,o,a,s){for(var h=e.length,l=0;l<h;l++)t[l]=Be(e[l],r[l],i[l],n[l],o,a,s)}function He(t){if(T(t)){var e=t.length;if(T(t[0])){for(var r=[],i=0;i<e;i++)r.push(De.call(t[i]));return r}return De.call(t)}return t}function Ne(t){return t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.floor(t[2]),"rgba("+t.join(",")+")"}var We,Ue,Xe=[0,0,0,0],je=function(){function t(t){this.keyframes=[],this.maxTime=0,this.arrDim=0,this.interpolable=!0,this._needsSort=!1,this._isAllValueEqual=!0,this._lastFrame=0,this._lastFramePercent=0,this.propName=t}return t.prototype.isFinished=function(){return this._finished},t.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},t.prototype.needsAnimate=function(){return!this._isAllValueEqual&&this.keyframes.length>=2&&this.interpolable&&this.maxTime>0},t.prototype.getAdditiveTrack=function(){return this._additiveTrack},t.prototype.addKeyframe=function(t,e){t>=this.maxTime?this.maxTime=t:this._needsSort=!0;var r=this.keyframes,i=r.length;if(this.interpolable)if(T(e)){var n=function(t){return T(t&&t[0])?2:1}(e);if(i>0&&this.arrDim!==n)return void(this.interpolable=!1);if(1===n&&"number"!=typeof e[0]||2===n&&"number"!=typeof e[0][0])return void(this.interpolable=!1);if(i>0){var o=r[i-1];this._isAllValueEqual&&(1===n&&Fe(e,o.value)||(this._isAllValueEqual=!1))}this.arrDim=n}else{if(this.arrDim>0)return void(this.interpolable=!1);if("string"==typeof e){var a=xe(e);a?(e=a,this.isValueColor=!0):this.interpolable=!1}else if("number"!=typeof e||isNaN(e))return void(this.interpolable=!1);this._isAllValueEqual&&i>0&&(o=r[i-1],(this.isValueColor&&!Fe(o.value,e)||o.value!==e)&&(this._isAllValueEqual=!1))}var s={time:t,value:e,percent:0};return this.keyframes.push(s),s},t.prototype.prepare=function(t){var e=this.keyframes;this._needsSort&&e.sort((function(t,e){return t.time-e.time}));for(var r=this.arrDim,i=e.length,n=e[i-1],o=0;o<i;o++)e[o].percent=e[o].time/this.maxTime,r>0&&o!==i-1&&Ie(e[o].value,n.value,r);if(t&&this.needsAnimate()&&t.needsAnimate()&&r===t.arrDim&&this.isValueColor===t.isValueColor&&!t._finished){this._additiveTrack=t;var a=e[0].value;for(o=0;o<i;o++)0===r?this.isValueColor?e[o].additiveValue=Re([],e[o].value,a,-1):e[o].additiveValue=e[o].value-a:1===r?e[o].additiveValue=Re([],e[o].value,a,-1):2===r&&(e[o].additiveValue=Oe([],e[o].value,a,-1))}},t.prototype.step=function(t,e){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var r,i=null!=this._additiveTrack,n=i?"additiveValue":"value",o=this.keyframes,a=this.keyframes.length,s=this.propName,h=this.arrDim,l=this.isValueColor;if(e<0)r=0;else if(e<this._lastFramePercent){for(r=Math.min(this._lastFrame+1,a-1);r>=0&&!(o[r].percent<=e);r--);r=Math.min(r,a-2)}else{for(r=this._lastFrame;r<a&&!(o[r].percent>e);r++);r=Math.min(r-1,a-2)}var u=o[r+1],c=o[r];if(c&&u){this._lastFrame=r,this._lastFramePercent=e;var p=u.percent-c.percent;if(0!==p){var f=(e-c.percent)/p,d=i?this._additiveValue:l?Xe:t[s];if((h>0||l)&&!d&&(d=this._additiveValue=[]),this.useSpline){var v=o[r][n],y=o[0===r?r:r-1][n],g=o[r>a-2?a-1:r+1][n],_=o[r>a-3?a-1:r+2][n];if(h>0)1===h?Ee(d,y,v,g,_,f,f*f,f*f*f):function(t,e,r,i,n,o,a,s){for(var h=e.length,l=e[0].length,u=0;u<h;u++){t[u]||(t[1]=[]);for(var c=0;c<l;c++)t[u][c]=Be(e[u][c],r[u][c],i[u][c],n[u][c],o,a,s)}}(d,y,v,g,_,f,f*f,f*f*f);else if(l)Ee(d,y,v,g,_,f,f*f,f*f*f),i||(t[s]=Ne(d));else{var m=void 0;m=this.interpolable?Be(y,v,g,_,f,f*f,f*f*f):g,i?this._additiveValue=m:t[s]=m}}else h>0?1===h?Le(d,c[n],u[n],f):function(t,e,r,i){for(var n=e.length,o=n&&e[0].length,a=0;a<n;a++){t[a]||(t[a]=[]);for(var s=0;s<o;s++)t[a][s]=ze(e[a][s],r[a][s],i)}}(d,c[n],u[n],f):l?(Le(d,c[n],u[n],f),i||(t[s]=Ne(d))):(m=void 0,m=this.interpolable?ze(c[n],u[n],f):function(t,e,r){return r>.5?e:t}(c[n],u[n],f),i?this._additiveValue=m:t[s]=m);i&&this._addToTarget(t)}}}},t.prototype._addToTarget=function(t){var e=this.arrDim,r=this.propName,i=this._additiveValue;0===e?this.isValueColor?(xe(t[r],Xe),Re(Xe,Xe,i,1),t[r]=Ne(Xe)):t[r]=t[r]+i:1===e?Re(t[r],t[r],i,1):2===e&&Oe(t[r],t[r],i,1)},t}(),Ye=function(){function t(t,e,r){this._tracks={},this._trackKeys=[],this._delay=0,this._maxTime=0,this._paused=!1,this._started=0,this._clip=null,this._target=t,this._loop=e,e&&r?g("Can' use additive animation on looped animation."):this._additiveAnimators=r}return t.prototype.getTarget=function(){return this._target},t.prototype.changeTarget=function(t){this._target=t},t.prototype.when=function(t,e){return this.whenWithKeys(t,e,A(e))},t.prototype.whenWithKeys=function(t,e,r){for(var i=this._tracks,n=0;n<r.length;n++){var o=r[n],a=i[o];if(!a){a=i[o]=new je(o);var s=void 0,h=this._getAdditiveTrack(o);if(h){var l=h.keyframes[h.keyframes.length-1];s=l&&l.value,h.isValueColor&&s&&(s=Ne(s))}else s=this._target[o];if(null==s)continue;0!==t&&a.addKeyframe(0,He(s)),this._trackKeys.push(o)}a.addKeyframe(t,He(e[o]))}return this._maxTime=Math.max(this._maxTime,t),this},t.prototype.pause=function(){this._clip.pause(),this._paused=!0},t.prototype.resume=function(){this._clip.resume(),this._paused=!1},t.prototype.isPaused=function(){return!!this._paused},t.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var t=this._doneCbs;if(t)for(var e=t.length,r=0;r<e;r++)t[r].call(this)},t.prototype._abortedCallback=function(){this._setTracksFinished();var t=this.animation,e=this._abortedCbs;if(t&&t.removeClip(this._clip),this._clip=null,e)for(var r=0;r<e.length;r++)e[r].call(this)},t.prototype._setTracksFinished=function(){for(var t=this._tracks,e=this._trackKeys,r=0;r<e.length;r++)t[e[r]].setFinished()},t.prototype._getAdditiveTrack=function(t){var e,r=this._additiveAnimators;if(r)for(var i=0;i<r.length;i++){var n=r[i].getTrack(t);n&&(e=n)}return e},t.prototype.start=function(t,e){if(!(this._started>0)){this._started=1;for(var r=this,i=[],n=0;n<this._trackKeys.length;n++){var o=this._trackKeys[n],a=this._tracks[o],s=this._getAdditiveTrack(o),h=a.keyframes;if(a.prepare(s),a.needsAnimate())i.push(a);else if(!a.interpolable){var l=h[h.length-1];l&&(r._target[a.propName]=l.value)}}if(i.length||e){var u=new ne({life:this._maxTime,loop:this._loop,delay:this._delay,onframe:function(t){r._started=2;var e=r._additiveAnimators;if(e){for(var n=!1,o=0;o<e.length;o++)if(e[o]._clip){n=!0;break}n||(r._additiveAnimators=null)}for(o=0;o<i.length;o++)i[o].step(r._target,t);var a=r._onframeCbs;if(a)for(o=0;o<a.length;o++)a[o](r._target,t)},ondestroy:function(){r._doneCallback()}});this._clip=u,this.animation&&this.animation.addClip(u),t&&"spline"!==t&&(u.easing=t)}else this._doneCallback();return this}},t.prototype.stop=function(t){if(this._clip){var e=this._clip;t&&e.onframe(1),this._abortedCallback()}},t.prototype.delay=function(t){return this._delay=t,this},t.prototype.during=function(t){return t&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(t)),this},t.prototype.done=function(t){return t&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(t)),this},t.prototype.aborted=function(t){return t&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(t)),this},t.prototype.getClip=function(){return this._clip},t.prototype.getTrack=function(t){return this._tracks[t]},t.prototype.stopTracks=function(t,e){if(!t.length||!this._clip)return!0;for(var r=this._tracks,i=this._trackKeys,n=0;n<t.length;n++){var o=r[t[n]];o&&(e?o.step(this._target,1):1===this._started&&o.step(this._target,0),o.setFinished())}var a=!0;for(n=0;n<i.length;n++)if(!r[i[n]].isFinished()){a=!1;break}return a&&this._abortedCallback(),a},t.prototype.saveFinalToTarget=function(t,e){if(t){e=e||this._trackKeys;for(var r=0;r<e.length;r++){var i=e[r],n=this._tracks[i];if(n&&!n.isFinished()){var o=n.keyframes,a=o[o.length-1];if(a){var s=He(a.value);n.isValueColor&&(s=Ne(s)),t[i]=s}}}}},t.prototype.__changeFinalValue=function(t,e){e=e||A(t);for(var r=0;r<e.length;r++){var i=e[r],n=this._tracks[i];if(n){var o=n.keyframes;if(o.length>1){var a=o.pop();n.addKeyframe(a.time,t[i]),n.prepare(n.getAdditiveTrack())}}}},t}(),qe=function(t){function e(e){var r=t.call(this)||this;return r._running=!1,r._time=0,r._pausedTime=0,r._pauseStart=0,r._paused=!1,e=e||{},r.stage=e.stage||{},r.onframe=e.onframe||function(){},r}return tt(e,t),e.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._clipsHead?(this._clipsTail.next=t,t.prev=this._clipsTail,t.next=null,this._clipsTail=t):this._clipsHead=this._clipsTail=t,t.animation=this},e.prototype.addAnimator=function(t){t.animation=this;var e=t.getClip();e&&this.addClip(e)},e.prototype.removeClip=function(t){if(t.animation){var e=t.prev,r=t.next;e?e.next=r:this._clipsHead=r,r?r.prev=e:this._clipsTail=e,t.next=t.prev=t.animation=null}},e.prototype.removeAnimator=function(t){var e=t.getClip();e&&this.removeClip(e),t.animation=null},e.prototype.update=function(t){for(var e=(new Date).getTime()-this._pausedTime,r=e-this._time,i=this._clipsHead;i;){var n=i.next;i.step(e,r)?(i.ondestroy&&i.ondestroy(),this.removeClip(i),i=n):i=n}this._time=e,t||(this.onframe(r),this.trigger("frame",r),this.stage.update&&this.stage.update())},e.prototype._startLoop=function(){var t=this;this._running=!0,re((function e(){t._running&&(re(e),!t._paused&&t.update())}))},e.prototype.start=function(){this._running||(this._time=(new Date).getTime(),this._pausedTime=0,this._star