diff --git a/sdk/modules/echarts.js b/sdk/modules/echarts.js index ec94972..7e0e673 100644 --- a/sdk/modules/echarts.js +++ b/sdk/modules/echarts.js @@ -1,17 +1,22 @@ /** * name: echarts - * version: v0.0.2 - * update: echart 3.0 - * date: 2016-01-15 + * version: v0.2.0 + * update: echart 4.0 + * date: 2018-01-16 */ define('echarts', function(require, exports, module) { -!function(t,e){"function"==typeof define&&define.amd?define([],e):"object"==typeof module&&module.exports?module.exports=e():t.echarts=e()}(this,function(){var t,e;!function(){function i(t,e){if(!e)return t;if(0===t.indexOf(".")){var i=e.split("/"),n=t.split("/"),r=i.length-1,a=n.length,o=0,s=0;t:for(var l=0;a>l;l++)switch(n[l]){case"..":if(!(r>o))break t;o++,s++;break;case".":s++;break;default:break t}return i.length=r-o,n=n.slice(s),i.concat(n).join("/")}return t}function n(t){function e(e,o){if("string"==typeof e){var s=n[e];return s||(s=a(i(e,t)),n[e]=s),s}e instanceof Array&&(o=o||function(){},o.apply(this,r(e,o,t)))}var n={};return e}function r(e,n,r){for(var s=[],l=o[r],c=0,h=Math.min(e.length,n.length);h>c;c++){var u,d=i(e[c],r);switch(d){case"require":u=l&&l.require||t;break;case"exports":u=l.exports;break;case"module":u=l;break;default:u=a(d)}s.push(u)}return s}function a(t){var e=o[t];if(!e)throw new Error("No "+t);if(!e.defined){var i=e.factory,n=i.apply(this,r(e.deps||[],i,t));"undefined"!=typeof n&&(e.exports=n),e.defined=1}return e.exports}var o={};e=function(t,e,i){if(2===arguments.length&&(i=e,e=[],"function"!=typeof i)){var r=i;i=function(){return r}}o[t]={id:t,deps:e,factory:i,defined:0,exports:{},require:n(t)}},t=n("")}();var i="padding",n="../../echarts",r="getRect",a="dataToCoord",o="getLabel",s="../echarts",l="getLineStyle",c="isHorizontal",h="getAxis",u="dataToPoint",d="getExtent",f="getOtherAxis",p="getBaseAxis",v="execute",m="getFormattedLabel",g="getItemStyle",y="circle",_="symbol",x="symbolSize",b="createSymbol",w="updateData",M="../../util/number",S="../../util/graphic",k="../../util/symbol",A="category",C="coordinateSystem",T="../../util/model",D="setItemGraphicEl",L="getItemVisual",z="setItemLayout",P="getItemLayout",I="getVisual",O="mapArray",R="getDataExtent",B="dimensions",Z="extendComponentView",E="extendComponentModel",N="registerVisualCoding",V="registerLayout",F="registerAction",G="registerProcessor",H="hostModel",W="eachComponent",q="dataZoom",j="itemStyle",U="eachSeries",X="eachSeriesByType",$="setItemVisual",Y="setVisual",Q="dispose",K="canvasSupported",J="clientHeight",tt="backgroundColor",et="appendChild",it="innerHTML",nt="intersect",rt="resize",at="update",ot="zlevel",st="getDisplayList",lt="storage",ct="parentNode",ht="offsetY",ut="offsetX",dt="mousemove",ft="zrender/core/event",pt="initProps",vt="updateProps",mt="getTextColor",gt="mouseout",yt="mouseover",_t="setHoverStyle",xt="hoverStyle",bt="setStyle",wt="subPixelOptimizeRect",Mt="extendShape",St="Polyline",kt="Sector",At="points",Ct="setShape",Tt="restore",Dt="buildPath",Lt="closePath",zt="bezierCurveTo",Pt="lineTo",It="moveTo",Ot="beginPath",Rt="contain",Bt="textBaseline",Zt="textAlign",Et="textPosition",Nt="eachItemGraphicEl",Vt="indexOfName",Ft="getItemGraphicEl",Gt="dataIndex",Ht="trigger",Wt="render",qt="removeAll",jt="updateLayout",Ut="invisible",Xt="traverse",$t="delFromMap",Yt="addToMap",Qt="remove",Kt="__dirty",Jt="refresh",te="ignore",ee="draggable",ie="animate",ne="stopAnimation",re="animation",ae="zrender/tool/color",oe="target",se="transformCoordToLocal",le="rotate",ce="getLocalTransform",he="parent",ue="transform",de="rotation",fe="zrender/mixin/Eventful",pe="addCommas",ve="getDataParams",me="getItemModel",ge="getName",ye="getRawIndex",_e="getRawValue",xe="ordinal",be="getData",we="seriesIndex",Me="normal",Se="emphasis",ke="axisIndex",Ae="radius",Ce="getComponent",Te="register",De="dispatchAction",Le="getHeight",ze="getWidth",Pe="getDom",Ie="splice",Oe="findComponents",Re="isString",Be="series",Ze="mergeOption",Ee="isObject",Ne="mergeDefaultAndTheme",Ve="getLayoutRect",Fe="vertical",Ge="childAt",He="position",We="eachChild",qe="toUpperCase",je="toLowerCase",Ue="getPixelPrecision",Xe="toFixed",$e="parsePercent",Ye="linearMap",Qe="replace",Ke="option",Je="../util/clazz",ti="getFont",ei="getBoundingRect",ii="textStyle",ni="getModel",ri="ecModel",ai="substr",oi="defaults",si="inside",li="center",ci="middle",hi="bottom",ui="../core/BoundingRect",di="../core/util",fi="zrender/contain/text",pi="create",vi="height",mi="applyTransform",gi="zrender/core/BoundingRect",yi="distance",_i="undefined",xi="zrender/core/vector",bi="opacity",wi="stroke",Mi="lineWidth",Si="getShallow",ki="isArray",Ai="getClass",Ci="enableClassManagement",Ti="inherits",Di="extend",Li="enableClassExtend",zi="parseClassType",Pi="function",Ii="concat",Oi="number",Ri="string",Bi="indexOf",Zi="getContext",Ei="canvas",Ni="createElement",Vi="length",Fi="object",Gi="filter",Hi="zrender/core/util",Wi="prototype",qi="require";e("zrender/graphic/Gradient",[qi],function(t){var e=function(t){this.colorStops=t||[]};return e[Wi]={constructor:e,addColorStop:function(t,e){this.colorStops.push({offset:t,color:e})}},e}),e(Hi,[qi,"../graphic/Gradient"],function(t){function e(t){if(typeof t==Fi&&null!==t){var i=t;if(t instanceof Array){i=[];for(var n=0,r=t[Vi];r>n;n++)i[n]=e(t[n])}else if(!M(t)&&!S(t)){i={};for(var a in t)t.hasOwnProperty(a)&&(i[a]=e(t[a]))}return i}return t}function i(t,n,r){if(t){if(!n)return t;for(var a in n)if(n.hasOwnProperty(a)){var o=t[a],s=n[a];!w(s)||!w(o)||_(s)||_(o)||S(s)||S(o)||M(s)||M(o)?!r&&a in t||(t[a]=e(n[a],!0)):i(o,s,r)}return t}}function n(t,e){for(var n=t[0],r=1,a=t[Vi];a>r;r++)n=i(n,t[r],e);return n}function r(t,e){for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i]);return t}function a(t,e,i){for(var n in e)e.hasOwnProperty(n)&&(i?null!=e[n]:null==t[n])&&(t[n]=e[n]);return t}function o(){return document[Ni](Ei)}function s(){return T||(T=E.createCanvas()[Zi]("2d")),T}function l(t,e){if(t){if(t[Bi])return t[Bi](e);for(var i=0,n=t[Vi];n>i;i++)if(t[i]===e)return i}return-1}function c(t,e){function i(){}var n=t[Wi];i[Wi]=e[Wi],t[Wi]=new i;for(var r in n)t[Wi][r]=n[r];t[Wi].constructor=t,t.superClass=e}function h(t,e,i){t=Wi in t?t[Wi]:t,e=Wi in e?e[Wi]:e,a(t,e,i)}function u(t){return t?typeof t==Ri?!1:typeof t[Vi]==Oi:void 0}function d(t,e,i){if(t&&e)if(t.forEach&&t.forEach===I)t.forEach(e,i);else if(t[Vi]===+t[Vi])for(var n=0,r=t[Vi];r>n;n++)e.call(i,t[n],n,t);else for(var a in t)t.hasOwnProperty(a)&&e.call(i,t[a],a,t)}function f(t,e,i){if(t&&e){if(t.map&&t.map===B)return t.map(e,i);for(var n=[],r=0,a=t[Vi];a>r;r++)n.push(e.call(i,t[r],r,t));return n}}function p(t,e,i,n){if(t&&e){if(t.reduce&&t.reduce===Z)return t.reduce(e,i,n);for(var r=0,a=t[Vi];a>r;r++)i=e.call(n,i,t[r],r,t);return i}}function v(t,e,i){if(t&&e){if(t[Gi]&&t[Gi]===O)return t[Gi](e,i);for(var n=[],r=0,a=t[Vi];a>r;r++)e.call(i,t[r],r,t)&&n.push(t[r]);return n}}function m(t,e,i){if(t&&e)for(var n=0,r=t[Vi];r>n;n++)if(e.call(i,t[n],n,t))return t[n]}function g(t,e){var i=R.call(arguments,2);return function(){return t.apply(e,i[Ii](R.call(arguments)))}}function y(t){var e=R.call(arguments,1);return function(){return t.apply(this,e[Ii](R.call(arguments)))}}function _(t){return"[object Array]"===z.call(t)}function x(t){return typeof t===Pi}function b(t){return"[object String]"===z.call(t)}function w(t){var e=typeof t;return e===Pi||!!t&&e==Fi}function M(t){return!!L[z.call(t)]||t instanceof D}function S(t){return t&&1===t.nodeType&&typeof t.nodeName==Ri}function k(t){for(var e=0,i=arguments[Vi];i>e;e++)if(null!=arguments[e])return arguments[e]}function A(){return Function.call.apply(R,arguments)}function C(t,e){if(!t)throw new Error(e)}var T,D=t("../graphic/Gradient"),L={"[object Function]":1,"[object RegExp]":1,"[object Date]":1,"[object Error]":1,"[object CanvasGradient]":1},z=Object[Wi].toString,P=Array[Wi],I=P.forEach,O=P[Gi],R=P.slice,B=P.map,Z=P.reduce,E={inherits:c,mixin:h,clone:e,merge:i,mergeAll:n,extend:r,defaults:a,getContext:s,createCanvas:o,indexOf:l,slice:A,find:m,isArrayLike:u,each:d,map:f,reduce:p,filter:v,bind:g,curry:y,isArray:_,isString:b,isObject:w,isFunction:x,isBuildInObject:M,isDom:S,retrieve:k,assert:C,noop:function(){}};return E}),e("echarts/util/clazz",[qi,Hi],function(t){function e(t,e){for(var i,n=t.constructor,r=t[e];(n=n.$superClass)&&(i=n[Wi][e])&&i===r;);return i}var i=t(Hi),n={},r=".",a="___EC__COMPONENT__CONTAINER___",o=n[zi]=function(t){var e={main:"",sub:""};return t&&(t=t.split(r),e.main=t[0]||"",e.sub=t[1]||""),e};return n[Li]=function(t,n){t[Di]=function(r){var a=function(){n&&n.apply(this,arguments),t.apply(this,arguments)};return i[Di](a[Wi],i[Di]({$superCall:function(t){var n=i.slice(arguments,1);return e(this,t).apply(this,n)},$superApply:function(t,i){return e(this,t).apply(this,i)}},r)),a[Di]=this[Di],i[Ti](a,this),a.$superClass=this,a}},n[Ci]=function(t,e){function n(t){var e=r[t.main];return e&&e[a]||(e=r[t.main]={},e[a]=!0),e}e=e||{};var r={};if(t.registerClass=function(t,e){if(e)if(e=o(e),e.sub){if(e.sub!==a){var i=n(e);i[e.sub]=t}}else{if(r[e.main])throw new Error(e.main+"exists");r[e.main]=t}return t},t[Ai]=function(t,e,i){var n=r[t];if(n&&n[a]&&(n=e?n[e]:null),i&&!n)throw new Error("Component "+t+"."+(e||"")+" not exists");return n},t.getClassesByMainType=function(t){t=o(t);var e=[],n=r[t.main];return n&&n[a]?i.each(n,function(t,i){i!==a&&e.push(t)}):e.push(n),e},t.hasClass=function(t){return t=o(t),!!r[t.main]},t.getAllClassMainTypes=function(){var t=[];return i.each(r,function(e,i){t.push(i)}),t},t.hasSubTypes=function(t){t=o(t);var e=r[t.main];return e&&e[a]},t[zi]=o,e.registerWhenExtend){var s=t[Di];s&&(t[Di]=function(e){var i=s.call(this,e);return t.registerClass(i,e.type)})}return t},n.setReadOnly=function(t,e){i[ki](e)||(e=null!=e?[e]:[]),i.each(e,function(e){var n=t[e];Object.defineProperty&&Object.defineProperty(t,e,{value:n,writable:!1}),i[ki](t[e])&&Object.freeze&&Object.freeze(t[e])})},n}),e("echarts/model/mixin/makeStyleMapper",[qi,Hi],function(t){var e=t(Hi);return function(t){for(var i=0;i=0)){var o=this[Si](a);null!=o&&(n[t[r][0]]=o)}}return n}}}),e("echarts/model/mixin/lineStyle",[qi,"./makeStyleMapper"],function(t){var e=t("./makeStyleMapper")([[Mi,"width"],[wi,"color"],[bi],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]);return{getLineStyle:function(t){var i=e.call(this,t),n=this.getLineDash();return n&&(i.lineDash=n),i},getLineDash:function(){var t=this.get("type");return"solid"===t||null==t?null:"dashed"===t?[5,5]:[1,1]}}}),e("echarts/model/mixin/areaStyle",[qi,"./makeStyleMapper"],function(t){return{getAreaStyle:t("./makeStyleMapper")([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],[bi],["shadowColor"]])}}),e(xi,[],function(){var t=typeof Float32Array===_i?Array:Float32Array,e={create:function(e,i){var n=new t(2);return n[0]=e||0,n[1]=i||0,n},copy:function(t,e){return t[0]=e[0],t[1]=e[1],t},clone:function(e){var i=new t(2);return i[0]=e[0],i[1]=e[1],i},set:function(t,e,i){return t[0]=e,t[1]=i,t},add:function(t,e,i){return t[0]=e[0]+i[0],t[1]=e[1]+i[1],t},scaleAndAdd:function(t,e,i,n){return t[0]=e[0]+i[0]*n,t[1]=e[1]+i[1]*n,t},sub:function(t,e,i){return t[0]=e[0]-i[0],t[1]=e[1]-i[1],t},len:function(t){return Math.sqrt(this.lenSquare(t))},lenSquare:function(t){return t[0]*t[0]+t[1]*t[1]},mul:function(t,e,i){return t[0]=e[0]*i[0],t[1]=e[1]*i[1],t},div:function(t,e,i){return t[0]=e[0]/i[0],t[1]=e[1]/i[1],t},dot:function(t,e){return t[0]*e[0]+t[1]*e[1]},scale:function(t,e,i){return t[0]=e[0]*i,t[1]=e[1]*i,t},normalize:function(t,i){var n=e.len(i);return 0===n?(t[0]=0,t[1]=0):(t[0]=i[0]/n,t[1]=i[1]/n),t},distance:function(t,e){return Math.sqrt((t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1]))},distanceSquare:function(t,e){return(t[0]-e[0])*(t[0]-e[0])+(t[1]-e[1])*(t[1]-e[1])},negate:function(t,e){return t[0]=-e[0],t[1]=-e[1],t},lerp:function(t,e,i,n){return t[0]=e[0]+n*(i[0]-e[0]),t[1]=e[1]+n*(i[1]-e[1]),t},applyTransform:function(t,e,i){var n=e[0],r=e[1];return t[0]=i[0]*n+i[2]*r+i[4],t[1]=i[1]*n+i[3]*r+i[5],t},min:function(t,e,i){return t[0]=Math.min(e[0],i[0]),t[1]=Math.min(e[1],i[1]),t},max:function(t,e,i){return t[0]=Math.max(e[0],i[0]),t[1]=Math.max(e[1],i[1]),t}};return e[Vi]=e.len,e.lengthSquare=e.lenSquare,e.dist=e[yi],e.distSquare=e.distanceSquare,e}),e("zrender/core/matrix",[],function(){var t=typeof Float32Array===_i?Array:Float32Array,e={create:function(){var i=new t(6);return e.identity(i),i},identity:function(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t},copy:function(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t},mul:function(t,e,i){var n=e[0]*i[0]+e[2]*i[1],r=e[1]*i[0]+e[3]*i[1],a=e[0]*i[2]+e[2]*i[3],o=e[1]*i[2]+e[3]*i[3],s=e[0]*i[4]+e[2]*i[5]+e[4],l=e[1]*i[4]+e[3]*i[5]+e[5];return t[0]=n,t[1]=r,t[2]=a,t[3]=o,t[4]=s,t[5]=l,t},translate:function(t,e,i){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4]+i[0],t[5]=e[5]+i[1],t},rotate:function(t,e,i){var n=e[0],r=e[2],a=e[4],o=e[1],s=e[3],l=e[5],c=Math.sin(i),h=Math.cos(i);return t[0]=n*h+o*c,t[1]=-n*c+o*h,t[2]=r*h+s*c,t[3]=-r*c+h*s,t[4]=h*a+c*l,t[5]=h*l-c*a,t},scale:function(t,e,i){var n=i[0],r=i[1];return t[0]=e[0]*n,t[1]=e[1]*r,t[2]=e[2]*n,t[3]=e[3]*r,t[4]=e[4]*n,t[5]=e[5]*r,t},invert:function(t,e){var i=e[0],n=e[2],r=e[4],a=e[1],o=e[3],s=e[5],l=i*o-a*n;return l?(l=1/l,t[0]=o*l,t[1]=-a*l,t[2]=-n*l,t[3]=i*l,t[4]=(n*s-o*r)*l,t[5]=(a*r-i*s)*l,t):null}};return e}),e(gi,[qi,"./vector","./matrix"],function(t){function e(t,e,i,n){this.x=t,this.y=e,this.width=i,this[vi]=n}var i=t("./vector"),n=t("./matrix"),r=i[mi],a=Math.min,o=Math.abs,s=Math.max;return e[Wi]={constructor:e,union:function(t){var e=a(t.x,this.x),i=a(t.y,this.y);this.width=s(t.x+t.width,this.x+this.width)-e,this[vi]=s(t.y+t[vi],this.y+this[vi])-i,this.x=e,this.y=i},applyTransform:function(){var t=[],e=[];return function(i){i&&(t[0]=this.x,t[1]=this.y,e[0]=this.x+this.width,e[1]=this.y+this[vi],r(t,t,i),r(e,e,i),this.x=a(t[0],e[0]),this.y=a(t[1],e[1]),this.width=o(e[0]-t[0]),this[vi]=o(e[1]-t[1]))}}(),calculateTransform:function(t){var e=this,i=t.width/e.width,r=t[vi]/e[vi],a=n[pi]();return n.translate(a,a,[-e.x,-e.y]),n.scale(a,a,[i,r]),n.translate(a,a,[t.x,t.y]),a},intersect:function(t){var e=this,i=e.x,n=e.x+e.width,r=e.y,a=e.y+e[vi],o=t.x,s=t.x+t.width,l=t.y,c=t.y+t[vi];return!(o>n||i>s||l>a||r>c)},contain:function(t,e){var i=this;return t>=i.x&&t<=i.x+i.width&&e>=i.y&&e<=i.y+i[vi]},clone:function(){return new e(this.x,this.y,this.width,this[vi])},copy:function(t){this.x=t.x,this.y=t.y,this.width=t.width,this[vi]=t[vi]}},e}),e(fi,[qi,di,ui],function(t){function e(t,e){var i=t+":"+e;if(s[i])return s[i];for(var n=(t+"").split("\n"),r=0,a=0,o=n[Vi];o>a;a++)r=Math.max(d.measureText(n[a],e).width,r);return l>c&&(l=0,s={}),l++,s[i]=r,r}function i(t,i,n,r){var a=((t||"")+"").split("\n")[Vi],o=e(t,i),s=e("国",i),l=a*s,c=new u(0,0,o,l);switch(c.lineHeight=s,r){case hi:case"alphabetic":c.y-=s;break;case ci:c.y-=s/2}switch(n){case"end":case"right":c.x-=c.width;break;case li:c.x-=c.width/2}return c}function n(t,e,i,n){var r=e.x,a=e.y,o=e[vi],s=e.width,l=i[vi],c=o/2-l/2,h="left";switch(t){case"left":r-=n,a+=c,h="right";break;case"right":r+=n+s,a+=c,h="left";break;case"top":r+=s/2,a-=n+l,h=li;break;case hi:r+=s/2,a+=o+n,h=li;break;case si:r+=s/2,a+=c,h=li;break;case"insideLeft":r+=n,a+=c,h="left";break;case"insideRight":r+=s-n,a+=c,h="right";break;case"insideTop":r+=s/2,a+=n,h=li;break;case"insideBottom":r+=s/2,a+=o-l-n,h=li;break;case"insideTopLeft":r+=n,a+=n,h="left";break;case"insideTopRight":r+=s-n,a+=n,h="right";break;case"insideBottomLeft":r+=n,a+=o-l-n;break;case"insideBottomRight":r+=s-n,a+=o-l-n,h="right"}return{x:r,y:a,textAlign:h,textBaseline:"top"}}function r(t,i,n,r){if(!n)return"";r=h[oi]({ellipsis:"...",minCharacters:3,maxIterations:3,cnCharWidth:e("国",i),ascCharWidth:e("a",i)},r,!0),n-=e(r.ellipsis);for(var o=(t+"").split("\n"),s=0,l=o[Vi];l>s;s++)o[s]=a(o[s],i,n,r);return o.join("\n")}function a(t,i,n,r){for(var a=0;;a++){var s=e(t,i);if(n>s||a>=r.maxIterations){t+=r.ellipsis;break}var l=0===a?o(t,n,r):Math.floor(t[Vi]*n/s);if(lr&&e>n;r++){var o=t.charCodeAt(r);n+=o>=0&&127>=o?i.ascCharWidth:i.cnCharWidth}return r}var s={},l=0,c=5e3,h=t(di),u=t(ui),d={getWidth:e,getBoundingRect:i,adjustTextPositionOnRect:n,ellipsis:r,measureText:function(t,e){var i=h[Zi]();return i.font=e,i.measureText(t)}};return d}),e("echarts/model/mixin/textStyle",[qi,fi],function(t){function e(t,e){return t&&t[Si](e)}var i=t(fi);return{getTextColor:function(){var t=this[ri];return this[Si]("color")||t&&t.get("textStyle.color")},getFont:function(){var t=this[ri],i=t&&t[ni](ii);return[this[Si]("fontStyle")||e(i,"fontStyle"),this[Si]("fontWeight")||e(i,"fontWeight"),(this[Si]("fontSize")||e(i,"fontSize")||12)+"px",this[Si]("fontFamily")||e(i,"fontFamily")||"sans-serif"].join(" ")},getTextRect:function(t){var e=this.get(ii)||{};return i[ei](t,this[ti](),e.align,e.baseline)},ellipsis:function(t,e,n){return i.ellipsis(t,this[ti](),e,n)}}}),e("echarts/model/mixin/itemStyle",[qi,"./makeStyleMapper"],function(t){return{getItemStyle:t("./makeStyleMapper")([["fill","color"],[wi,"borderColor"],[Mi,"borderWidth"],[bi],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]])}}),e("echarts/model/Model",[qi,Hi,Je,"./mixin/lineStyle","./mixin/areaStyle","./mixin/textStyle","./mixin/itemStyle"],function(t){function e(t,e,i){this.parentModel=e||null,this[ri]=i||null,this[Ke]=t,this.init.apply(this,arguments)}var i=t(Hi),n=t(Je);e[Wi]={constructor:e,init:function(t){},mergeOption:function(t){i.merge(this[Ke],t,!0)},get:function(t,e){if(!t)return this[Ke];typeof t===Ri&&(t=t.split("."));for(var i=this[Ke],n=this.parentModel,r=0;r=0&&n.push(t)}),n}t.topologicalTravel=function(t,i,r,a){function o(t){c[t].entryCount--,0===c[t].entryCount&&h.push(t)}function s(t){u[t]=!0,o(t)}if(t[Vi]){var l=n(i),c=l.graph,h=l.noEntryList,u={};for(e.each(t,function(t){u[t]=!0});h[Vi];){var d=h.pop(),f=c[d],p=!!u[d];p&&(r.call(a,d,f.originalDeps.slice()),delete u[d]),e.each(f.successor,p?s:o)}e.each(u,function(){throw new Error("Circle dependency may exists")})}}},a}),e("echarts/util/number",[qi,Hi],function(t){function e(t){return t[Qe](/^\s+/,"")[Qe](/\s+$/,"")}var i=t(Hi),n={},r=1e-4;return n[Ye]=function(t,e,r,a){if(i[ki](t))return i.map(t,function(t){return n[Ye](t,e,r,a)});var o=e[1]-e[0];if(0===o)return(r[0]+r[1])/2;var s=(t-e[0])/o;return a&&(s=Math.min(Math.max(s,0),1)),s*(r[1]-r[0])+r[0]},n[$e]=function(t,i){switch(t){case li:case ci:t="50%";break;case"left":case"top":t="0%";break;case"right":case hi:t="100%"}return typeof t===Ri?e(t).match(/%$/)?parseFloat(t)/100*i:parseFloat(t):null==t?NaN:+t},n.round=function(t){return+(+t)[Xe](12)},n.asc=function(t){return t.sort(function(t,e){return t-e}),t},n.getPrecision=function(t){for(var e=1,i=0;Math.round(t*e)/e!==t;)e*=10,i++;return i},n[Ue]=function(t,e){var i=Math.log,n=Math.LN10,r=Math.floor(i(t[1]-t[0])/n),a=Math.round(i(Math.abs(e[1]-e[0]))/n);return Math.max(-r+a,0)},n.MAX_SAFE_INTEGER=9007199254740991,n.remRadian=function(t){var e=2*Math.PI;return(t%e+e)%e},n.isRadianAroundZero=function(t){return t>-r&&r>t},n.parseDate=function(t){return t instanceof Date?t:new Date(typeof t===Ri?t[Qe](/-/g,"/"):t)},n}),e("echarts/util/format",[qi,Hi],function(t){function e(t){return isNaN(t)?"-":(t=(t+"").split("."),t[0][Qe](/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t[Vi]>1?"."+t[1]:""))}function i(t){return t[je]()[Qe](/-(.)/g,function(t,e){return e[qe]()})}function n(t){var e=t[Vi];return typeof t===Oi?[t,t,t,t]:2===e?[t[0],t[1],t[0],t[1]]:3===e?[t[0],t[1],t[2],t[1]]:t}function r(t){return String(t)[Qe](/&/g,"&")[Qe](//g,">")[Qe](/"/g,""")[Qe](/'/g,"'")}function a(t,e){return"{"+t+(null==e?"":e)+"}"}function o(t,e){s[ki](e)||(e=[e]);var i=e[Vi];if(!i)return"";for(var n=e[0].$vars,r=0;rc;c++)for(var h=0;hn||l.newline?(a=0,h=m,o+=s+i,s=0):s=Math.max(s,f[vi])}else{var g=f[vi]+(v?-v.y+f.y:0);u=o+g,u>r||l.newline?(a+=s+i,o=0,u=g,s=0):s=Math.max(s,f.width)}l.newline||(d[0]=a,d[1]=o,"horizontal"===t?a=h+i:o=u+i)})}var i=t(Hi),n=t(gi),r=t("./number"),a=t("./format"),o=r[$e],s=i.each,l={};return l.box=e,l.vbox=i.curry(e,Fe),l.hbox=i.curry(e,"horizontal"),l.getAvailableSize=function(t,e,i){var n=e.width,r=e[vi],s=o(t.x,n),l=o(t.y,r),c=o(t.x2,n),h=o(t.y2,r);return(isNaN(s)||isNaN(parseFloat(t.x)))&&(s=0),(isNaN(c)||isNaN(parseFloat(t.x2)))&&(c=n),(isNaN(l)||isNaN(parseFloat(t.y)))&&(l=0),(isNaN(h)||isNaN(parseFloat(t.y2)))&&(h=r),i=a.normalizeCssArray(i||0),{width:Math.max(c-s-i[1]-i[3],0),height:Math.max(h-l-i[0]-i[2],0)}},l[Ve]=function(t,e,i){i=a.normalizeCssArray(i||0);var r=e.width,s=e[vi],l=o(t.left,r),c=o(t.top,s),h=o(t.right,r),u=o(t[hi],s),d=o(t.width,r),f=o(t[vi],s),p=i[2]+i[0],v=i[1]+i[3],m=t.aspect;switch(isNaN(d)&&(d=r-h-v-l),isNaN(f)&&(f=s-u-p-c),isNaN(d)&&isNaN(f)&&(m>r/s?d=.8*r:f=.8*s),null!=m&&(isNaN(d)&&(d=m*f),isNaN(f)&&(f=d/m)),isNaN(l)&&(l=r-h-d-v),isNaN(c)&&(c=s-u-f-p),t.left||t.right){case li:l=r/2-d/2-i[3];break;case"right":l=r-d-v}switch(t.top||t[hi]){case ci:case li:c=s/2-f/2-i[0];break;case hi:c=s-f-p}var g=new n(l+i[3],c+i[0],d,f);return g.margin=i,g},l.positionGroup=function(t,e,n,r){var a=t[ei]();e=i[Di](i.clone(e),{width:a.width,height:a[vi]}),e=l[Ve](e,n,r),t[He]=[e.x-a.x,e.y-a.y]},l.mergeLayoutParam=function(t,e,i){function n(n){var o={},l=0,c={},h=0,u=i.ignoreSize?1:2;if(s(n,function(e){c[e]=t[e]}),s(n,function(t){r(e,t)&&(o[t]=c[t]=e[t]),a(o,t)&&l++,a(c,t)&&h++}),h!==u&&l){if(u>h){var d=0;return s(n,function(t){"auto"===c[t]&&(u-h>d?d++:c[t]=null)}),c}if(l>=u)return o;for(var f=0;f=0;a--)r=n.merge(r,t[a],!0);this.__defaultOption=r}return this.__defaultOption}});return o[Li](l,function(t,e,i,r){n[Di](this,r),this.uid=a.getUID("componentModel"),this.setReadOnly(["type","id","uid","name","mainType","subType","dependentModels","componentIndex"])}),o[Ci](l,{registerWhenExtend:!0}),a.enableSubTypeDefaulter(l),a.enableTopologicalTravel(l,e),n.mixin(l,t("./mixin/boxLayout")),l}),e("echarts/model/globalDefault",[],function(){var t="";return typeof navigator!==_i&&(t=navigator.platform||""),{color:["#c23531","#314656","#61a0a8","#dd8668","#91c7ae","#6e7074","#61a0a8","#bda29a","#44525d","#c4ccd3"],grid:{},textStyle:{fontFamily:t.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},animation:!0,animationThreshold:2e3,animationDuration:1e3,animationDurationUpdate:300,animationEasing:"exponentialOut",animationEasingUpdate:"cubicOut"}}),e("echarts/model/Global",[qi,Hi,"./Model","./Component","./globalDefault"],function(t){function e(t,e){for(var i in e)_.hasClass(i)||(typeof e[i]===Fi?t[i]=t[i]?u.merge(t[i],e[i],!1):u.clone(e[i]):t[i]=e[i])}function i(t){t=t,this[Ke]={},this._componentsMap={},this._seriesIndices=null,e(t,this._theme[Ke]),u.merge(t,x,!1),this[Ze](t)}function n(t,e){u[ki](e)||(e=e?[e]:[]);var i={};return f(e,function(e){i[e]=(t[e]||[]).slice()}),i}function r(t,e){t=(t||[]).slice();var i=[];return f(e,function(e,n){if(y(e)&&e.id)for(var r=0,a=t[Vi];a>r;r++)if(t[r].id===e.id)return void(i[n]=t[Ie](r,1)[0])}),f(e,function(e,n){if(y(e)&&e.name&&!c(e))for(var r=0,a=t[Vi];a>r;r++)if(t[r].name===e.name)return void(i[n]=t[Ie](r,1)[0])}),f(e,function(e,n){i[n]||!t[n]||c(e)||(i[n]=t[n])}),i}function a(t,e,i){function n(n){f(e,function(e,a){if(y(e)){var o=i[a],s=r[a],l=t+"."+s.subType;n(s,e,o,l)}})}var r=[],a="\x00",s={},l={};return f(e,function(e,n){if(y(e)){var a=i[n],s=o(t,e,a),l={mainType:t,subType:s};r[n]=l}}),n(function(t,e,i,n){t.name=i?i.name:null!=e.name?e.name:a+"-",l[t.name]=0}),n(function(t,e,i,n){var r=t.name;if(t.id=i?i.id:null!=e.id?e.id:a+[n,r,l[r]++].join("|"),s[t.id])throw new Error("id duplicates: "+t.id);s[t.id]=1}),r}function o(t,e,i){var n=e.type?e.type:i?i.subType:_.determineSubType(t,e);return n}function s(t){return v(t,function(t){return t.componentIndex})||[]}function l(t,e){return e.hasOwnProperty("subType")?p(t,function(t){return t.subType===e.subType}):t}function c(t){return t.id&&0===(t.id+"")[Bi]("\x00_ec_\x00")}function h(t){if(!t._seriesIndices)throw new Error("Series is not initialized. Please depends sereis.")}var u=t(Hi),d=t("./Model"),f=u.each,p=u[Gi],v=u.map,m=u[ki],g=u[Bi],y=u[Ee],_=t("./Component"),x=t("./globalDefault"),b=d[Di]({constructor:b,init:function(t,e,i,n){i=i||{},this[Ke]=null,this._theme=new d(i),this._optionManager=n},setOption:function(t,e){this._optionManager.setOption(t,e),this.resetOption()},resetOption:function(t){var e=!1,n=this._optionManager;if(!t||"recreate"===t){var r=n.mountOption();this[Ke]&&"recreate"!==t?(this.restoreData(),this[Ze](r)):i.call(this,r),e=!0}if(("timeline"===t||"media"===t)&&this.restoreData(),!t||"recreate"===t||"timeline"===t){var a=n.getTimelineOption(this);a&&(this[Ze](a),e=!0)}if(!t||"recreate"===t||"media"===t){var o=n.getMediaOption(this,this._api);o[Vi]&&f(o,function(t){this[Ze](t,e=!0)},this)}return e},mergeOption:function(t){function e(e,n){var r=t[e];r?o.call(this,e,r,n):i.call(this,e),e===Be&&(this._seriesIndices=s(c[Be]))}function i(t){f(c[t],function(t){t[Ze]({},this)},this)}function o(t,e,i){u[ki](e)||(e=[e]),c[t]||(c[t]=[]);var o=r(c[t],e),s=a(t,e,o),h=n(c,i);l[t]=[],f(e,function(e,i){if(y(e)){var n=o[i],r=_[Ai](t,s[i].subType,!0);n&&n instanceof r?n[Ze](e,this):(n=new r(e,this,this,u[Di]({dependentModels:h,componentIndex:i},s[i])),c[t][i]=n),l[t][i]=n[Ke]}},this)}var l=this[Ke],c=this._componentsMap,h=[];f(t,function(t,e){null!=t&&(_.hasClass(e)?h.push(e):l[e]=null==l[e]?u.clone(t):u.merge(l[e],t,!0))}),_.topologicalTravel(h,_.getAllClassMainTypes(),e,this)},getTheme:function(){return this._theme},getComponent:function(t,e){var i=this._componentsMap[t];return i?i[e||0]:void 0},queryComponents:function(t){var e=t.mainType;if(!e)return[];var i=t.index,n=t.id,r=t.name,a=this._componentsMap[e];if(!a||!a[Vi])return[];var o;if(null!=i)m(i)||(i=[i]),o=p(v(i,function(t){return a[t]}),function(t){return!!t});else if(null!=n){var s=m(n);o=p(a,function(t){return s&&g(n,t.id)>=0||!s&&t.id===n})}else if(null!=r){var c=m(r);o=p(a,function(t){return c&&g(r,t.name)>=0||!c&&t.name===r})}return l(o,t)},findComponents:function(t){function e(t){var e=r+"Index",i=r+"Id",n=r+"Name";return t&&(t.hasOwnProperty(e)||t.hasOwnProperty(i)||t.hasOwnProperty(n))?{mainType:r,index:t[e],id:t[i],name:t[n]}:null}function i(e){return t[Gi]?p(e,t[Gi]):e}var n=t.query,r=t.mainType,a=e(n),o=a?this.queryComponents(a):this._componentsMap[r];return i(l(o,t))},eachComponent:function(t,e,i){var n=this._componentsMap;if(typeof t===Pi)i=e,e=t,f(n,function(t,n){f(t,function(t,r){e.call(i,n,t,r)})});else if(u[Re](t))f(n[t],e,i);else if(y(t)){var r=this[Oe](t);f(r,e,i)}},getSeriesByName:function(t){var e=this._componentsMap[Be];return p(e,function(e){return e.name===t})},getSeriesByIndex:function(t){return this._componentsMap[Be][t]},getSeriesByType:function(t){var e=this._componentsMap[Be];return p(e,function(e){return e.subType===t})},getSeries:function(){return this._componentsMap[Be].slice()},eachSeries:function(t,e){h(this),f(this._seriesIndices,function(i){var n=this._componentsMap[Be][i];t.call(e,n,i)},this)},eachRawSeries:function(t,e){f(this._componentsMap[Be],t,e)},eachSeriesByType:function(t,e,i){h(this),f(this._seriesIndices,function(n){var r=this._componentsMap[Be][n];r.subType===t&&e.call(i,r,n)},this)},eachRawSeriesByType:function(t,e,i){return f(this.getSeriesByType(t),e,i)},isSeriesFiltered:function(t){return h(this),u[Bi](this._seriesIndices,t.componentIndex)<0},filterSeries:function(t,e){h(this);var i=p(this._componentsMap[Be],t,e);this._seriesIndices=s(i)},restoreData:function(){var t=this._componentsMap;this._seriesIndices=s(t[Be]);var e=[];f(t,function(t,i){e.push(i)}),_.topologicalTravel(e,_.getAllClassMainTypes(),function(e,i){f(t[e],function(t){t.restoreData()})})}});return b}),e("echarts/ExtensionAPI",[qi,Hi],function(t){function e(t){i.each(n,function(e){this[e]=i.bind(t[e],t)},this)}var i=t(Hi),n=[Pe,"getZr",ze,Le,De,"on","off","getDataURL","getConnectedDataURL"];return e}),e("echarts/CoordinateSystem",[qi],function(t){function e(){this._coordinateSystems={},this._coordinateSystemsList=[]}var i={};return e[Wi]={constructor:e,update:function(t,e){var n={};for(var r in i)n[r]=i[r][pi](t,e);this._coordinateSystems=n},get:function(t,e){var i=this._coordinateSystems[t];return i?i[e||0]:void 0; -}},e[Te]=function(t,e){i[t]=e},e}),e("echarts/model/OptionManager",[qi,Hi],function(t){function e(t){this._api=t,this._timelineOptions,this._mediaList,this._mediaDefault,this._currentMediaIndices=[],this._optionBackup}function i(t,e){var i,n,r=[],a=[],l=t.timeline;if((l||t.options)&&(n=t.baseOption||{},r=(t.options||[]).slice()),t.media){n=t.baseOption||{};var c=t.media;s(c,function(t){t&&t[Ke]&&(t.query?a.push(t):i||(i=t))})}return n||(n=t),n.timeline||(n.timeline=l),s([n][Ii](r)[Ii](o.map(a,function(t){return t[Ke]})),function(t){s(e,function(e){e(t)})}),{baseOption:n,timelineOptions:r,mediaDefault:i,mediaList:a}}function n(t,e,i){var n={width:e,height:i,aspectratio:e/i},a=!0;return o.each(t,function(t,e){var i=e.match(h);if(i&&i[1]&&i[2]){var o=i[1],s=i[2][je]();r(n[s],t,o)||(a=!1)}}),a}function r(t,e,i){return"min"===i?t>=e:"max"===i?e>=t:t===e}function a(t,e){return t.join(",")===e.join(",")}var o=t(Hi),s=o.each,l=o.clone,c=o.map,h=/^(min|max)?(.+)$/;return e[Wi]={constructor:e,setOption:function(t,e){t=l(t,!0),this._optionBackup=i.call(this,t,e)},mountOption:function(){var t=this._optionBackup;return this._timelineOptions=c(t.timelineOptions,l),this._mediaList=c(t.mediaList,l),this._mediaDefault=l(t.mediaDefault),this._currentMediaIndices=[],l(t.baseOption)},getTimelineOption:function(t){var e,i=this._timelineOptions;if(i[Vi]){var n=t[Ce]("timeline");n&&(e=l(i[n.getCurrentIndex()],!0))}return e},getMediaOption:function(t){var e=this._api[ze](),i=this._api[Le](),r=this._mediaList,o=this._mediaDefault,s=[],h=[];if(!r[Vi]&&!o)return h;for(var u=0,d=r[Vi];d>u;u++)n(r[u].query,e,i)&&s.push(u);return!s[Vi]&&o&&(s=[-1]),s[Vi]&&!a(s,this._currentMediaIndices)&&(h=c(s,function(t){return l(-1===t?o[Ke]:r[t][Ke])})),this._currentMediaIndices=s,h}},e}),e("echarts/util/model",[qi,"./format","./number",Hi,"../model/Model"],function(t){var e=t("./format"),i=t("./number"),n=t(Hi),r=t("../model/Model"),a=["x","y","z",Ae,"angle"],o={};return o.createNameEach=function(t,e){t=t.slice();var i=n.map(t,o.capitalFirst);e=(e||[]).slice();var r=n.map(e,o.capitalFirst);return function(a,o){n.each(t,function(t,n){for(var s={name:t,capital:i[n]},l=0;l=0}function a(t,r){var a=!1;return e(function(e){n.each(i(t,e)||[],function(t){r.records[e.name][t]&&(a=!0)})}),a}function o(t,r){r.nodes.push(t),e(function(e){n.each(i(t,e)||[],function(t){r.records[e.name][t]=!0})})}return function(i){function n(t){!r(t,s)&&a(t,s)&&(o(t,s),l=!0)}var s={nodes:[],records:{}};if(e(function(t){s.records[t.name]={}}),!i)return s;o(i,s);var l;do l=!1,t(n);while(l);return s}},o.defaultEmphasis=function(t,e){if(t){var i=t[Se]=t[Se]||{},r=t[Me]=t[Me]||{};n.each(e,function(t){var e=n.retrieve(i[t],r[t]);null!=e&&(i[t]=e)})}},o.createDataFormatModel=function(t,e,i){var a=new r;return n.mixin(a,o.dataFormatMixin),a[we]=t[we],a.name=t.name||"",a[be]=function(){return e},a.getRawDataArray=function(){return i},a},o.getDataItemValue=function(t){return t&&(null==t.value?t:t.value)},o.converDataValue=function(t,e){var n=e&&e.type;return n===xe?t:("time"!==n||isFinite(t)||null==t||"-"===t||(t=+i.parseDate(t)),null==t||""===t?NaN:+t)},o.dataFormatMixin={getDataParams:function(t){var e=this[be](),i=this[we],n=this.name,r=this[_e](t),a=e[ye](t),o=e[ge](t,!0),s=this.getRawDataArray(),l=s&&s[a];return{seriesIndex:i,seriesName:n,name:o,dataIndex:a,data:l,value:r,$vars:["seriesName","name","value"]}},getFormattedLabel:function(t,i,n){i=i||Me;var r=this[be](),a=r[me](t),o=this[ve](t);return n||(n=a.get(["label",i,"formatter"])),typeof n===Pi?(o.status=i,n(o)):typeof n===Ri?e.formatTpl(n,o):void 0},getRawValue:function(t){var e=this[be]()[me](t);if(e&&e[Ke]){var i=e[Ke];return n[Ee](i)&&!n[ki](i)?i.value:i}}},o}),e("echarts/model/Series",[qi,Hi,"../util/format","../util/model","./Component"],function(t){var e=t(Hi),i=t("../util/format"),n=t("../util/model"),r=t("./Component"),a=i.encodeHTML,o=i[pe],s=r[Di]({type:"series",seriesIndex:0,coordinateSystem:null,defaultOption:null,legendDataProvider:null,init:function(t,e,i,n){this[we]=this.componentIndex,this[Ne](t,i),this._dataBeforeProcessed=this.getInitialData(t,i),this._data=this._dataBeforeProcessed.cloneShallow()},mergeDefaultAndTheme:function(t,i){e.merge(t,i.getTheme().get(this.subType)),e.merge(t,this.getDefaultOption()),n.defaultEmphasis(t.label,[He,"show",ii,yi,"formatter"])},mergeOption:function(t,i){t=e.merge(this[Ke],t,!0);var n=this.getInitialData(t,i);n&&(this._data=n,this._dataBeforeProcessed=n.cloneShallow())},getInitialData:function(){},getData:function(){return this._data},setData:function(t){this._data=t},getRawData:function(){return this._dataBeforeProcessed},getRawDataArray:function(){return this[Ke].data},getDimensionsOnAxis:function(t){return[t]},formatTooltip:function(t,i){var n=this._data,r=this[_e](t),s=e[ki](r)?e.map(r,o).join(", "):o(r),l=n[ge](t);return i?a(this.name)+" : "+s:a(this.name)+"
"+(l?a(l)+" : "+s:s)},restoreData:function(){this._data=this._dataBeforeProcessed.cloneShallow()}});return e.mixin(s,n.dataFormatMixin),s}),e("zrender/core/guid",[],function(){var t=2311;return function(){return"zr_"+t++}}),e(fe,[qi,di],function(t){var e=Array[Wi].slice,i=t(di),n=i[Bi],r=function(){this._$handlers={}};return r[Wi]={constructor:r,one:function(t,e,i){var r=this._$handlers;return e&&t?(r[t]||(r[t]=[]),n(r[t],t)>=0?this:(r[t].push({h:e,one:!0,ctx:i||this}),this)):this},on:function(t,e,i){var n=this._$handlers;return e&&t?(n[t]||(n[t]=[]),n[t].push({h:e,one:!1,ctx:i||this}),this):this},isSilent:function(t){var e=this._$handlers;return e[t]&&e[t][Vi]},off:function(t,e){var i=this._$handlers;if(!t)return this._$handlers={},this;if(e){if(i[t]){for(var n=[],r=0,a=i[t][Vi];a>r;r++)i[t][r].h!=e&&n.push(i[t][r]);i[t]=n}i[t]&&0===i[t][Vi]&&delete i[t]}else delete i[t];return this},trigger:function(t){if(this._$handlers[t]){var i=arguments,n=i[Vi];n>3&&(i=e.call(i,1));for(var r=this._$handlers[t],a=r[Vi],o=0;a>o;){switch(n){case 1:r[o].h.call(r[o].ctx);break;case 2:r[o].h.call(r[o].ctx,i[1]);break;case 3:r[o].h.call(r[o].ctx,i[1],i[2]);break;default:r[o].h.apply(r[o].ctx,i)}r[o].one?(r[Ie](o,1),a--):o++}}return this},triggerWithContext:function(t){if(this._$handlers[t]){var i=arguments,n=i[Vi];n>4&&(i=e.call(i,1,i[Vi]-1));for(var r=i[i[Vi]-1],a=this._$handlers[t],o=a[Vi],s=0;o>s;){switch(n){case 1:a[s].h.call(r);break;case 2:a[s].h.call(r,i[1]);break;case 3:a[s].h.call(r,i[1],i[2]);break;default:a[s].h.apply(r,i)}a[s].one?(a[Ie](s,1),o--):s++}}return this}},r}),e("zrender/mixin/Transformable",[qi,"../core/matrix","../core/vector"],function(t){function e(t){return t>a||-a>t}var i=t("../core/matrix"),n=t("../core/vector"),r=i.identity,a=5e-5,o=function(t){t=t||{},t[He]||(this[He]=[0,0]),null==t[de]&&(this[de]=0),t.scale||(this.scale=[1,1]),this.origin=this.origin||null},s=o[Wi];s[ue]=null,s.needLocalTransform=function(){return e(this[de])||e(this[He][0])||e(this[He][1])||e(this.scale[0]-1)||e(this.scale[1]-1)},s.updateTransform=function(){var t=this[he],e=t&&t[ue],n=this.needLocalTransform(),a=this[ue];return n||e?(a=a||i[pi](),n?this[ce](a):r(a),e&&(n?i.mul(a,t[ue],a):i.copy(a,t[ue])),this[ue]=a,this.invTransform=this.invTransform||i[pi](),void i.invert(this.invTransform,a)):void(a&&r(a))},s[ce]=function(t){t=t||[],r(t);var e=this.origin,n=this.scale,a=this[de],o=this[He];return e&&(t[4]-=e[0],t[5]-=e[1]),i.scale(t,t,n),a&&i[le](t,t,a),e&&(t[4]+=e[0],t[5]+=e[1]),t[4]+=o[0],t[5]+=o[1],t},s.setTransform=function(t){var e=this[ue];e&&t[ue](e[0],e[1],e[2],e[3],e[4],e[5])};var l=[];return s.decomposeTransform=function(){if(this[ue]){var t=this[he],n=this[ue];t&&t[ue]&&(i.mul(l,t.invTransform,n),n=l);var r=n[0]*n[0]+n[1]*n[1],a=n[2]*n[2]+n[3]*n[3],o=this[He],s=this.scale;e(r-1)&&(r=Math.sqrt(r)),e(a-1)&&(a=Math.sqrt(a)),n[0]<0&&(r=-r),n[3]<0&&(a=-a),o[0]=n[4],o[1]=n[5],s[0]=r,s[1]=a,this[de]=Math.atan2(-n[1]/a,n[0]/r)}},s[se]=function(t,e){var i=[t,e],r=this.invTransform;return r&&n[mi](i,i,r),i},s.transformCoordToGlobal=function(t,e){var i=[t,e],r=this[ue];return r&&n[mi](i,i,r),i},o}),e("zrender/animation/easing",[],function(){var t={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*(-Math.pow(2,-10*(t-1))+2)},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,i=.1,n=.4;return 0===t?0:1===t?1:(!i||1>i?(i=1,e=n/4):e=n*Math.asin(1/i)/(2*Math.PI),-(i*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/n)))},elasticOut:function(t){var e,i=.1,n=.4;return 0===t?0:1===t?1:(!i||1>i?(i=1,e=n/4):e=n*Math.asin(1/i)/(2*Math.PI),i*Math.pow(2,-10*t)*Math.sin((t-e)*(2*Math.PI)/n)+1)},elasticInOut:function(t){var e,i=.1,n=.4;return 0===t?0:1===t?1:(!i||1>i?(i=1,e=n/4):e=n*Math.asin(1/i)/(2*Math.PI),(t*=2)<1?-.5*(i*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/n)):i*Math.pow(2,-10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/n)*.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?.5*(t*t*((e+1)*t-e)):.5*((t-=2)*t*((e+1)*t+e)+2)},bounceIn:function(e){return 1-t.bounceOut(1-e)},bounceOut:function(t){return 1/2.75>t?7.5625*t*t:2/2.75>t?7.5625*(t-=1.5/2.75)*t+.75:2.5/2.75>t?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(e){return.5>e?.5*t.bounceIn(2*e):.5*t.bounceOut(2*e-1)+.5}};return t}),e("zrender/animation/Clip",[qi,"./easing"],function(t){function e(t){this._target=t[oe],this._life=t.life||1e3,this._delay=t.delay||0,this._initialized=!1,this.loop=null==t.loop?!1:t.loop,this.gap=t.gap||0,this.easing=t.easing||"Linear",this.onframe=t.onframe,this.ondestroy=t.ondestroy,this.onrestart=t.onrestart}var i=t("./easing");return e[Wi]={constructor:e,step:function(t){this._initialized||(this._startTime=(new Date).getTime()+this._delay,this._initialized=!0);var e=(t-this._startTime)/this._life;if(!(0>e)){e=Math.min(e,1);var n=this.easing,r=typeof n==Ri?i[n]:n,a=typeof r===Pi?r(e):e;return this.fire("frame",a),1==e?this.loop?(this.restart(),"restart"):(this._needsRemove=!0,"destroy"):null}},restart:function(){var t=(new Date).getTime(),e=(t-this._startTime)%this._life;this._startTime=(new Date).getTime()-e+this.gap,this._needsRemove=!1},fire:function(t,e){t="on"+t,this[t]&&this[t](this._target,e)}},e}),e(ae,[qi],function(t){function e(t){return t=Math.round(t),0>t?0:t>255?255:t}function i(t){return t=Math.round(t),0>t?0:t>360?360:t}function n(t){return 0>t?0:t>1?1:t}function r(t){return e(t[Vi]&&"%"===t.charAt(t[Vi]-1)?parseFloat(t)/100*255:parseInt(t,10))}function a(t){return n(t[Vi]&&"%"===t.charAt(t[Vi]-1)?parseFloat(t)/100:parseFloat(t))}function o(t,e,i){return 0>i?i+=1:i>1&&(i-=1),1>6*i?t+(e-t)*i*6:1>2*i?e:2>3*i?t+(e-t)*(2/3-i)*6:t}function s(t,e,i){return t+(e-t)*i}function l(t){if(t){t+="";var e=t[Qe](/ /g,"")[je]();if(e in _)return _[e].slice();if("#"!==e.charAt(0)){var i=e[Bi]("("),n=e[Bi](")");if(-1!==i&&n+1===e[Vi]){var o=e[ai](0,i),s=e[ai](i+1,n-(i+1)).split(","),l=1;switch(o){case"rgba":if(4!==s[Vi])return;l=a(s.pop());case"rgb":if(3!==s[Vi])return;return[r(s[0]),r(s[1]),r(s[2]),l];case"hsla":if(4!==s[Vi])return;return s[3]=a(s[3]),c(s);case"hsl":if(3!==s[Vi])return;return c(s);default:return}}}else{if(4===e[Vi]){var h=parseInt(e[ai](1),16);if(!(h>=0&&4095>=h))return;return[(3840&h)>>4|(3840&h)>>8,240&h|(240&h)>>4,15&h|(15&h)<<4,1]}if(7===e[Vi]){var h=parseInt(e[ai](1),16);if(!(h>=0&&16777215>=h))return;return[(16711680&h)>>16,(65280&h)>>8,255&h,1]}}}}function c(t){var i=(parseFloat(t[0])%360+360)%360/360,n=a(t[1]),r=a(t[2]),s=.5>=r?r*(n+1):r+n-r*n,l=2*r-s,c=[e(255*o(l,s,i+1/3)),e(255*o(l,s,i)),e(255*o(l,s,i-1/3))];return 4===t[Vi]&&(c[3]=t[3]),c}function h(t){if(t){var e,i,n=t[0]/255,r=t[1]/255,a=t[2]/255,o=Math.min(n,r,a),s=Math.max(n,r,a),l=s-o,c=(s+o)/2;if(0===l)e=0,i=0;else{i=.5>c?l/(s+o):l/(2-s-o);var h=((s-n)/6+l/2)/l,u=((s-r)/6+l/2)/l,d=((s-a)/6+l/2)/l;n===s?e=d-u:r===s?e=1/3+h-d:a===s&&(e=2/3+u-h),0>e&&(e+=1),e>1&&(e-=1)}var f=[360*e,i,c];return null!=t[3]&&f.push(t[3]),f}}function u(t,e){var i=l(t);if(i){for(var n=0;3>n;n++)0>e?i[n]=i[n]*(1-e)|0:i[n]=(255-i[n])*e+i[n]|0;return y(i,4===i[Vi]?"rgba":"rgb")}}function d(t,e){var i=l(t);return i?((1<<24)+(i[0]<<16)+(i[1]<<8)+ +i[2]).toString(16).slice(1):void 0}function f(t,i,n){if(i&&i[Vi]&&t>=0&&1>=t){n=n||[0,0,0,0];var r=t*(i[Vi]-1),a=Math.floor(r),o=Math.ceil(r),l=i[a],c=i[o],h=r-a;return n[0]=e(s(l[0],c[0],h)),n[1]=e(s(l[1],c[1],h)),n[2]=e(s(l[2],c[2],h)),n[3]=e(s(l[3],c[3],h)),n}}function p(t,i,r){if(i&&i[Vi]&&t>=0&&1>=t){var a=t*(i[Vi]-1),o=Math.floor(a),c=Math.ceil(a),h=l(i[o]),u=l(i[c]),d=a-o,f=y([e(s(h[0],u[0],d)),e(s(h[1],u[1],d)),e(s(h[2],u[2],d)),n(s(h[3],u[3],d))],"rgba");return r?{color:f,leftIndex:o,rightIndex:c,value:a}:f}}function v(t,e){if(!(2!==t[Vi]||t[1]0&&s>=l;l++)r.push({color:e[l],offset:(l-i.value)/a});return r.push({color:n.color,offset:1}),r}}function m(t,e,n,r){return t=l(t),t?(t=h(t),null!=e&&(t[0]=i(e)),null!=n&&(t[1]=a(n)),null!=r&&(t[2]=a(r)),y(c(t),"rgba")):void 0}function g(t,e){return t=l(t),t&&null!=e?(t[3]=n(e),y(t,"rgba")):void 0}function y(t,e){return("rgb"===e||"hsv"===e||"hsl"===e)&&(t=t.slice(0,3)),e+"("+t.join(",")+")"}var _={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]};return{parse:l,lift:u,toHex:d,fastMapToColor:f,mapToColor:p,mapIntervalToColor:v,modifyHSL:m,modifyAlpha:g,stringify:y}}),e("zrender/animation/Animator",[qi,"./Clip","../tool/color",di],function(t){function e(t,e){return t[e]}function i(t,e,i){t[e]=i}function n(t,e,i){return(e-t)*i+t}function r(t,e,i){return i>.5?e:t}function a(t,e,i,r,a){var o=t[Vi];if(1==a)for(var s=0;o>s;s++)r[s]=n(t[s],e[s],i);else for(var l=t[0][Vi],s=0;o>s;s++)for(var c=0;l>c;c++)r[s][c]=n(t[s][c],e[s][c],i)}function o(t,e,i){var n=t[Vi],r=e[Vi];if(n!==r){var a=n>r;if(a)t[Vi]=r;else for(var o=n;r>o;o++)t.push(1===i?e[o]:g.call(e[o]))}}function s(t,e,i){if(t===e)return!0;var n=t[Vi];if(n!==e[Vi])return!1;if(1===i){for(var r=0;n>r;r++)if(t[r]!==e[r])return!1}else for(var a=t[0][Vi],r=0;n>r;r++)for(var o=0;a>o;o++)if(t[r][o]!==e[r][o])return!1;return!0}function l(t,e,i,n,r,a,o,s,l){var h=t[Vi];if(1==l)for(var u=0;h>u;u++)s[u]=c(t[u],e[u],i[u],n[u],r,a,o);else for(var d=t[0][Vi],u=0;h>u;u++)for(var f=0;d>f;f++)s[u][f]=c(t[u][f],e[u][f],i[u][f],n[u][f],r,a,o)}function c(t,e,i,n,r,a,o){var s=.5*(i-t),l=.5*(n-e);return(2*(e-i)+s+l)*o+(-3*(e-i)-2*s-l)*a+s*r+e}function h(t){if(m(t)){var e=t[Vi];if(m(t[0])){for(var i=[],n=0;e>n;n++)i.push(g.call(t[n]));return i}return g.call(t)}return t}function u(t){return t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.floor(t[2]),"rgba("+t.join(",")+")"}function d(t,e,i,h,d){var v=t._getter,g=t._setter,y="spline"===e,_=h[Vi];if(_){var x,b=h[0].value,w=m(b),M=!1,S=!1,k=w&&m(b[0])?2:1;h.sort(function(t,e){return t.time-e.time}),x=h[_-1].time;for(var A=[],C=[],T=h[0].value,D=!0,L=0;_>L;L++){A.push(h[L].time/x);var z=h[L].value;if(w&&s(z,T,k)||!w&&z===T||(D=!1),T=z,typeof z==Ri){var P=p.parse(z);P?(z=P,M=!0):S=!0}C.push(z)}if(!D){if(w){for(var I=C[_-1],L=0;_-1>L;L++)o(C[L],I,k);o(v(t._target,d),I,k)}var O,R,B,Z,E,N,V=0,F=0;if(M)var G=[0,0,0,0];var H=function(t,e){var i;if(F>e){for(O=Math.min(V+1,_-1),i=O;i>=0&&!(A[i]<=e);i--);i=Math.min(i,_-2)}else{for(i=V;_>i&&!(A[i]>e);i++);i=Math.min(i-1,_-2)}V=i,F=e;var o=A[i+1]-A[i];if(0!==o)if(R=(e-A[i])/o,y)if(Z=C[i],B=C[0===i?i:i-1],E=C[i>_-2?_-1:i+1],N=C[i>_-3?_-1:i+2],w)l(B,Z,E,N,R,R*R,R*R*R,v(t,d),k);else{var s;if(M)s=l(B,Z,E,N,R,R*R,R*R*R,G,1),s=u(G);else{if(S)return r(Z,E,R);s=c(B,Z,E,N,R,R*R,R*R*R)}g(t,d,s)}else if(w)a(C[i],C[i+1],R,v(t,d),k);else{var s;if(M)a(C[i],C[i+1],R,G,1),s=u(G);else{if(S)return r(C[i],C[i+1],R);s=n(C[i],C[i+1],R)}g(t,d,s)}},W=new f({target:t._target,life:x,loop:t._loop,delay:t._delay,onframe:H,ondestroy:i});return e&&"spline"!==e&&(W.easing=e),W}}}var f=t("./Clip"),p=t("../tool/color"),v=t(di),m=v.isArrayLike,g=Array[Wi].slice,y=function(t,n,r,a){this._tracks={},this._target=t,this._loop=n||!1,this._getter=r||e,this._setter=a||i,this._clipCount=0,this._delay=0,this._doneList=[],this._onframeList=[],this._clipList=[]};return y[Wi]={when:function(t,e){var i=this._tracks;for(var n in e){if(!i[n]){i[n]=[];var r=this._getter(this._target,n);if(null==r)continue;0!==t&&i[n].push({time:0,value:h(r)})}i[n].push({time:t,value:e[n]})}return this},during:function(t){return this._onframeList.push(t),this},_doneCallback:function(){this._tracks={},this._clipList[Vi]=0;for(var t=this._doneList,e=t[Vi],i=0;e>i;i++)t[i].call(this)},start:function(t){var e,i=this,n=0,r=function(){n--,n||i._doneCallback()};for(var a in this._tracks){var o=d(this,t,r,this._tracks[a],a);o&&(this._clipList.push(o),n++,this[re]&&this[re].addClip(o),e=o)}if(e){var s=e.onframe;e.onframe=function(t,e){s(t,e);for(var n=0;n1)for(var t in arguments)console.log(arguments[t])}}),e("zrender/mixin/Animatable",[qi,"../animation/Animator",di,"../core/log"],function(t){var e=t("../animation/Animator"),i=t(di),n=i[Re],r=i.isFunction,a=i[Ee],o=t("../core/log"),s=function(){this.animators=[]};return s[Wi]={constructor:s,animate:function(t,n){var r,a=!1,s=this,l=this.__zr;if(t){var c=t.split("."),h=s;a="shape"===c[0];for(var u=0,d=c[Vi];d>u;u++)h&&(h=h[c[u]]);h&&(r=h)}else r=s;if(!r)return void o('Property "'+t+'" is not existed in element '+s.id);var f=s.animators,p=new e(r,n);return p.during(function(t){s.dirty(a)}).done(function(){f[Ie](i[Bi](f,p),1)}),f.push(p),l&&l[re].addAnimator(p),p},stopAnimation:function(t){for(var e=this.animators,i=e[Vi],n=0;i>n;n++)e[n].stop(t);return e[Vi]=0,this},animateTo:function(t,e,i,a,o){function s(){c--,c||o&&o()}n(i)?(o=a,a=i,i=0):r(a)?(o=a,a="linear",i=0):r(i)?(o=i,i=0):r(e)?(o=e,e=500):e||(e=500),this[ne](),this._animateToShallow("",this,t,e,i,a,o);var l=this.animators.slice(),c=l[Vi];c||o&&o();for(var h=0;h0&&this[ie](t,!1).when(null==r?500:r,s).delay(o||0),this}},s}),e("zrender/Element",[qi,"./core/guid","./mixin/Eventful","./mixin/Transformable","./mixin/Animatable","./core/util"],function(t){var e=t("./core/guid"),i=t("./mixin/Eventful"),n=t("./mixin/Transformable"),r=t("./mixin/Animatable"),a=t("./core/util"),o=function(t){n.call(this,t),i.call(this,t),r.call(this,t),this.id=t.id||e()};return o[Wi]={type:"element",name:"",__zr:null,ignore:!1,clipPath:null,drift:function(t,e){switch(this[ee]){case"horizontal":e=0;break;case Fe:t=0}var i=this[ue];i||(i=this[ue]=[1,0,0,1,0,0]),i[4]+=t,i[5]+=e,this.decomposeTransform(),this.dirty()},beforeUpdate:function(){},afterUpdate:function(){},update:function(){this.updateTransform()},traverse:function(t,e){},attrKV:function(t,e){if(t===He||"scale"===t||"origin"===t){if(e){var i=this[t];i||(i=this[t]=[]),i[0]=e[0],i[1]=e[1]}}else this[t]=e},hide:function(){this[te]=!0,this.__zr&&this.__zr[Jt]()},show:function(){this[te]=!1,this.__zr&&this.__zr[Jt]()},attr:function(t,e){if(typeof t===Ri)this.attrKV(t,e);else if(a[Ee](t))for(var i in t)t.hasOwnProperty(i)&&this.attrKV(i,t[i]);return this.dirty(),this},setClipPath:function(t){var e=this.__zr;e&&t.addSelfToZr(e),this.clipPath&&this.clipPath!==t&&this.removeClipPath(),this.clipPath=t,t.__zr=e,t.__clipTarget=this,this.dirty()},removeClipPath:function(){var t=this.clipPath;t&&(t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__clipTarget=null,this.clipPath=null,this.dirty())},addSelfToZr:function(t){this.__zr=t;var e=this.animators;if(e)for(var i=0;i=0&&(i[Ie](n,0,t),this._doAdd(t))}return this},_doAdd:function(t){t[he]&&t[he][Qt](t),t[he]=this;var e=this.__storage,i=this.__zr;e&&e!==t.__storage&&(e[Yt](t),t instanceof r&&t.addChildrenToStorage(e)),i&&i[Jt]()},remove:function(t){var i=this.__zr,n=this.__storage,a=this._children,o=e[Bi](a,t);return 0>o?this:(a[Ie](o,1),t[he]=null,n&&(n[$t](t.id),t instanceof r&&t.delChildrenFromStorage(n)),i&&i[Jt](),this)},removeAll:function(){var t,e,i=this._children,n=this.__storage;for(e=0;e=0?parseFloat(t)/100*e:parseFloat(t):t}function i(t,e){t[ue](e[0],e[1],e[2],e[3],e[4],e[5])}var n=t("../../contain/text"),r=t("../../core/BoundingRect"),a=new r,o=function(){};return o[Wi]={constructor:o,drawRectText:function(t,r,o){var s=this.style,l=s.text;if(null!=l&&(l+=""),l){var c,h,u=s[Et],d=s.textDistance,f=s[Zt],p=s.textFont||s.font,v=s[Bt];o=o||n[ei](l,p,f,v);var m=this[ue],g=this.invTransform;if(m&&(a.copy(r),a[mi](m),r=a,i(t,g)),u instanceof Array)c=r.x+e(u[0],r.width),h=r.y+e(u[1],r[vi]),f=f||"left",v=v||"top";else{var y=n.adjustTextPositionOnRect(u,r,o,d);c=y.x,h=y.y,f=f||y[Zt],v=v||y[Bt]}t[Zt]=f,t[Bt]=v;var _=s.textFill,x=s.textStroke;_&&(t.fillStyle=_),x&&(t.strokeStyle=x),t.font=p,t.shadowColor=s.textShadowColor,t.shadowBlur=s.textShadowBlur,t.shadowOffsetX=s.textShadowOffsetX,t.shadowOffsetY=s.textShadowOffsetY;for(var b=l.split("\n"),w=0;w-x&&x>t}function i(t){return t>x||-x>t}function n(t,e,i,n,r){var a=1-r;return a*a*(a*t+3*r*e)+r*r*(r*n+3*a*i)}function r(t,e,i,n,r){var a=1-r;return 3*(((e-t)*a+2*(i-e)*r)*a+(n-i)*r*r)}function a(t,i,n,r,a,o){var s=r+3*(i-n)-t,l=3*(n-2*i+t),c=3*(i-t),h=t-a,u=l*l-3*s*c,d=l*c-9*s*h,f=c*c-3*l*h,p=0;if(e(u)&&e(d))if(e(l))o[0]=0;else{var v=-c/l;v>=0&&1>=v&&(o[p++]=v)}else{var m=d*d-4*u*f;if(e(m)){var g=d/u,v=-l/s+g,x=-g/2;v>=0&&1>=v&&(o[p++]=v),x>=0&&1>=x&&(o[p++]=x)}else if(m>0){var M=_(m),S=u*l+1.5*s*(-d+M),k=u*l+1.5*s*(-d-M);S=0>S?-y(-S,w):y(S,w),k=0>k?-y(-k,w):y(k,w);var v=(-l-(S+k))/(3*s);v>=0&&1>=v&&(o[p++]=v)}else{var A=(2*u*l-3*s*d)/(2*_(u*u*u)),C=Math.acos(A)/3,T=_(u),D=Math.cos(C),v=(-l-2*T*D)/(3*s),x=(-l+T*(D+b*Math.sin(C)))/(3*s),L=(-l+T*(D-b*Math.sin(C)))/(3*s);v>=0&&1>=v&&(o[p++]=v),x>=0&&1>=x&&(o[p++]=x),L>=0&&1>=L&&(o[p++]=L)}}return p}function o(t,n,r,a,o){var s=6*r-12*n+6*t,l=9*n+3*a-3*t-9*r,c=3*n-3*t,h=0;if(e(l)){if(i(s)){var u=-c/s;u>=0&&1>=u&&(o[h++]=u)}}else{var d=s*s-4*l*c;if(e(d))o[0]=-s/(2*l);else if(d>0){var f=_(d),u=(-s+f)/(2*l),p=(-s-f)/(2*l);u>=0&&1>=u&&(o[h++]=u),p>=0&&1>=p&&(o[h++]=p)}}return h}function s(t,e,i,n,r,a){var o=(e-t)*r+t,s=(i-e)*r+e,l=(n-i)*r+i,c=(s-o)*r+o,h=(l-s)*r+s,u=(h-c)*r+c;a[0]=t,a[1]=o,a[2]=c,a[3]=u,a[4]=u,a[5]=h,a[6]=l,a[7]=n}function l(t,e,i,r,a,o,s,l,c,h,u){var d,f,p,v,m,y=.005,b=1/0;M[0]=c,M[1]=h;for(var w=0;1>w;w+=.05)S[0]=n(t,i,a,s,w),S[1]=n(e,r,o,l,w),v=g(M,S),b>v&&(d=w,b=v);b=1/0;for(var A=0;32>A&&!(x>y);A++)f=d-y,p=d+y,S[0]=n(t,i,a,s,f),S[1]=n(e,r,o,l,f),v=g(S,M),f>=0&&b>v?(d=f,b=v):(k[0]=n(t,i,a,s,p),k[1]=n(e,r,o,l,p),m=g(k,M),1>=p&&b>m?(d=p,b=m):y*=.5);return u&&(u[0]=n(t,i,a,s,d),u[1]=n(e,r,o,l,d)),_(b)}function c(t,e,i,n){var r=1-n;return r*(r*t+2*n*e)+n*n*i}function h(t,e,i,n){return 2*((1-n)*(e-t)+n*(i-e))}function u(t,n,r,a,o){var s=t-2*n+r,l=2*(n-t),c=t-a,h=0;if(e(s)){if(i(l)){var u=-c/l;u>=0&&1>=u&&(o[h++]=u)}}else{var d=l*l-4*s*c;if(e(d)){var u=-l/(2*s);u>=0&&1>=u&&(o[h++]=u)}else if(d>0){var f=_(d),u=(-l+f)/(2*s),p=(-l-f)/(2*s);u>=0&&1>=u&&(o[h++]=u),p>=0&&1>=p&&(o[h++]=p)}}return h}function d(t,e,i){var n=t+i-2*e;return 0===n?.5:(t-e)/n}function f(t,e,i,n,r){var a=(e-t)*n+t,o=(i-e)*n+e,s=(o-a)*n+a;r[0]=t,r[1]=a,r[2]=s,r[3]=s,r[4]=o,r[5]=i}function p(t,e,i,n,r,a,o,s,l){var h,u=.005,d=1/0;M[0]=o,M[1]=s;for(var f=0;1>f;f+=.05){S[0]=c(t,i,r,f),S[1]=c(e,n,a,f);var p=g(M,S);d>p&&(h=f,d=p)}d=1/0;for(var v=0;32>v&&!(x>u);v++){var m=h-u,y=h+u;S[0]=c(t,i,r,m),S[1]=c(e,n,a,m);var p=g(S,M);if(m>=0&&d>p)h=m,d=p;else{k[0]=c(t,i,r,y),k[1]=c(e,n,a,y);var b=g(k,M);1>=y&&d>b?(h=y,d=b):u*=.5}}return l&&(l[0]=c(t,i,r,h),l[1]=c(e,n,a,h)),_(d)}var v=t("./vector"),m=v[pi],g=v.distSquare,y=Math.pow,_=Math.sqrt,x=1e-4,b=_(3),w=1/3,M=m(),S=m(),k=m();return{cubicAt:n,cubicDerivativeAt:r,cubicRootAt:a,cubicExtrema:o,cubicSubdivide:s,cubicProjectPoint:l,quadraticAt:c,quadraticDerivativeAt:h,quadraticRootAt:u,quadraticExtremum:d,quadraticSubdivide:f,quadraticProjectPoint:p}}),e("zrender/core/bbox",[qi,"./vector","./curve"],function(t){var e=t("./vector"),i=t("./curve"),n={},r=Math.min,a=Math.max,o=Math.sin,s=Math.cos,l=e[pi](),c=e[pi](),h=e[pi](),u=2*Math.PI;return n.fromPoints=function(t,e,i){if(0!==t[Vi]){var n,o=t[0],s=o[0],l=o[0],c=o[1],h=o[1];for(n=1;ng;g++)y[g]=b(t,n,s,c,y[g]);for(w=x(e,o,l,h,_),g=0;w>g;g++)_[g]=b(e,o,l,h,_[g]);y.push(t,c),_.push(e,h),f=r.apply(null,y),p=a.apply(null,y),v=r.apply(null,_),m=a.apply(null,_),u[0]=f,u[1]=v,d[0]=p,d[1]=m},n.fromQuadratic=function(t,e,n,o,s,l,c,h){var u=i.quadraticExtremum,d=i.quadraticAt,f=a(r(u(t,n,s),1),0),p=a(r(u(e,o,l),1),0),v=d(t,n,s,f),m=d(e,o,l,p);c[0]=r(t,s,v),c[1]=r(e,l,m),h[0]=a(t,s,v),h[1]=a(e,l,m)},n.fromArc=function(t,i,n,r,a,d,f,p,v){var m=e.min,g=e.max;if(Math.abs(a-d)%u<1e-4)return p[0]=t-n,p[1]=i-r,v[0]=t+n,void(v[1]=i+r);if(l[0]=s(a)*n+t,l[1]=o(a)*r+i,c[0]=s(d)*n+t,c[1]=o(d)*r+i,m(p,l,c),g(v,l,c),a%=u,0>a&&(a+=u),d%=u,0>d&&(d+=u),a>d&&!f?d+=u:d>a&&f&&(a+=u),f){var y=d;d=a,a=y}for(var _=0;d>_;_+=Math.PI/2)_>a&&(h[0]=s(_)*n+t,h[1]=o(_)*r+i,m(p,h,p),g(v,h,v))},n}),e("zrender/core/PathProxy",[qi,"./curve","./vector","./bbox","./BoundingRect"],function(t){var e=t("./curve"),i=t("./vector"),n=t("./bbox"),r=t("./BoundingRect"),a={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},o=[],s=[],l=[],c=[],h=Math.min,u=Math.max,d=Math.cos,f=Math.sin,p=Math.sqrt,v=typeof Float32Array!=_i,m=function(){this.data=[],this._len=0,this._ctx=null,this._xi=0,this._yi=0,this._x0=0,this._y0=0};return m[Wi]={constructor:m,_lineDash:null,_dashOffset:0,_dashIdx:0,_dashSum:0,getContext:function(){return this._ctx},beginPath:function(t){return this._ctx=t,t&&t[Ot](),this._len=0,this._lineDash&&(this._lineDash=null,this._dashOffset=0),this},moveTo:function(t,e){return this.addData(a.M,t,e),this._ctx&&this._ctx[It](t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},lineTo:function(t,e){return this.addData(a.L,t,e),this._ctx&&(this._needsDash()?this._dashedLineTo(t,e):this._ctx[Pt](t,e)),this._xi=t,this._yi=e,this},bezierCurveTo:function(t,e,i,n,r,o){return this.addData(a.C,t,e,i,n,r,o),this._ctx&&(this._needsDash()?this._dashedBezierTo(t,e,i,n,r,o):this._ctx[zt](t,e,i,n,r,o)),this._xi=r,this._yi=o,this},quadraticCurveTo:function(t,e,i,n){return this.addData(a.Q,t,e,i,n),this._ctx&&(this._needsDash()?this._dashedQuadraticTo(t,e,i,n):this._ctx.quadraticCurveTo(t,e,i,n)),this._xi=i,this._yi=n,this},arc:function(t,e,i,n,r,o){return this.addData(a.A,t,e,i,i,n,r-n,0,o?0:1),this._ctx&&this._ctx.arc(t,e,i,n,r,o),this._xi=d(r)*i+t,this._xi=f(r)*i+t,this},arcTo:function(t,e,i,n,r){return this._ctx&&this._ctx.arcTo(t,e,i,n,r),this},rect:function(t,e,i,n){return this._ctx&&this._ctx.rect(t,e,i,n),this.addData(a.R,t,e,i,n),this},closePath:function(){this.addData(a.Z);var t=this._ctx,e=this._x0,i=this._y0;return t&&(this._needsDash()&&this._dashedLineTo(e,i),t[Lt]()),this._xi=e,this._yi=i,this},fill:function(t){t&&t.fill(),this.toStatic()},stroke:function(t){t&&t[wi](),this.toStatic()},setLineDash:function(t){if(t instanceof Array){this._lineDash=t,this._dashIdx=0;for(var e=0,i=0;ii;i++)this.data[i]=t[i];this._len=e},appendPath:function(t){t instanceof Array||(t=[t]);for(var e=t[Vi],i=0,n=this._len,r=0;e>r;r++)i+=t[r].len();v&&this.data instanceof Float32Array&&(this.data=new Float32Array(n+i));for(var r=0;e>r;r++)for(var a=t[r].data,o=0;oe[Vi]&&(this._expandData(),e=this.data);for(var i=0;ia&&(a=r+a),a%=r,m-=a*d,g-=a*f;d>=0&&t>=m||0>d&&m>t;)n=this._dashIdx,i=o[n],m+=d*i,g+=f*i,this._dashIdx=(n+1)%y,d>0&&l>m||0>d&&m>l||s[n%2?It:Pt](d>=0?h(m,t):u(m,t),f>=0?h(g,e):u(g,e));d=m-t,f=g-e,this._dashOffset=-p(d*d+f*f)},_dashedBezierTo:function(t,i,n,r,a,o){var s,l,c,h,u,d=this._dashSum,f=this._dashOffset,v=this._lineDash,m=this._ctx,g=this._xi,y=this._yi,_=e.cubicAt,x=0,b=this._dashIdx,w=v[Vi],M=0;for(0>f&&(f=d+f),f%=d,s=0;1>s;s+=.1)l=_(g,t,n,a,s+.1)-_(g,t,n,a,s),c=_(y,i,r,o,s+.1)-_(y,i,r,o,s),x+=p(l*l+c*c);for(;w>b&&(M+=v[b],!(M>f));b++);for(s=(M-f)/x;1>=s;)h=_(g,t,n,a,s),u=_(y,i,r,o,s),b%2?m[It](h,u):m[Pt](h,u),s+=v[b]/x,b=(b+1)%w;b%2!==0&&m[Pt](a,o),l=a-h,c=o-u,this._dashOffset=-p(l*l+c*c)},_dashedQuadraticTo:function(t,e,i,n){var r=i,a=n;i=(i+2*t)/3,n=(n+2*e)/3,t=(this._xi+2*t)/3,e=(this._yi+2*e)/3,this._dashedBezierTo(t,e,i,n,r,a)},toStatic:function(){this.data[Vi]=this._len,v&&this.data instanceof Array&&(this.data=new Float32Array(this.data))},getBoundingRect:function(){o[0]=o[1]=l[0]=l[1]=Number.MAX_VALUE,s[0]=s[1]=c[0]=c[1]=-Number.MAX_VALUE;for(var t=this.data,e=0,h=0,u=0,p=0,v=0;vl?s:l,p=s>l?1:s/l,v=s>l?l/s:1,m=Math.abs(s-l)>.001;m?(t.translate(r,o),t[le](u),t.scale(p,v),t.arc(0,0,f,c,c+h,1-d),t.scale(1/p,1/v),t[le](-u),t.translate(-r,-o)):t.arc(r,o,f,c,c+h,1-d);break;case a.R:t.rect(e[i++],e[i++],e[i++],e[i++]);break;case a.Z:t[Lt]()}}}},m.CMD=a,m}),e("zrender/contain/line",[],function(){return{containStroke:function(t,e,i,n,r,a,o){if(0===r)return!1;var s=r,l=0,c=t;if(o>e+s&&o>n+s||e-s>o&&n-s>o||a>t+s&&a>i+s||t-s>a&&i-s>a)return!1;if(t===i)return Math.abs(a-t)<=s/2;l=(e-n)/(t-i),c=(t*n-i*e)/(t-i);var h=l*a-o+c,u=h*h/(l*l+1);return s/2*s/2>=u}}}),e("zrender/contain/cubic",[qi,"../core/curve"],function(t){var e=t("../core/curve");return{containStroke:function(t,i,n,r,a,o,s,l,c,h,u){if(0===c)return!1;var d=c;if(u>i+d&&u>r+d&&u>o+d&&u>l+d||i-d>u&&r-d>u&&o-d>u&&l-d>u||h>t+d&&h>n+d&&h>a+d&&h>s+d||t-d>h&&n-d>h&&a-d>h&&s-d>h)return!1;var f=e.cubicProjectPoint(t,i,n,r,a,o,s,l,h,u,null);return d/2>=f}}}),e("zrender/contain/quadratic",[qi,"../core/curve"],function(t){var e=t("../core/curve");return{containStroke:function(t,i,n,r,a,o,s,l,c){if(0===s)return!1;var h=s;if(c>i+h&&c>r+h&&c>o+h||i-h>c&&r-h>c&&o-h>c||l>t+h&&l>n+h&&l>a+h||t-h>l&&n-h>l&&a-h>l)return!1;var u=e.quadraticProjectPoint(t,i,n,r,a,o,l,c,null);return h/2>=u}}}),e("zrender/contain/util",[qi],function(t){var e=2*Math.PI;return{normalizeRadian:function(t){return t%=e,0>t&&(t+=e),t}}}),e("zrender/contain/arc",[qi,"./util"],function(t){var e=t("./util").normalizeRadian,i=2*Math.PI;return{containStroke:function(t,n,r,a,o,s,l,c,h){if(0===l)return!1;var u=l;c-=t,h-=n;var d=Math.sqrt(c*c+h*h);if(d-u>r||r>d+u)return!1;if(Math.abs(a-o)%i<1e-4)return!0;if(s){var f=a;a=e(o),o=e(f)}else a=e(a),o=e(o);a>o&&(o+=i);var p=Math.atan2(h,c);return 0>p&&(p+=i),p>=a&&o>=p||p+i>=a&&o>=p+i}}}),e("zrender/contain/windingLine",[],function(){return function(t,e,i,n,r,a){if(a>e&&a>n||e>a&&n>a)return 0;if(n===e)return 0;var o=e>n?1:-1,s=(a-e)/(n-e),l=s*(i-t)+t;return l>r?o:0}}),e("zrender/contain/path",[qi,"../core/PathProxy","./line","./cubic","./quadratic","./arc","./util","../core/curve","./windingLine"],function(t){function e(t,e){return Math.abs(t-e)e&&h>r&&h>o&&h>l||e>h&&r>h&&o>h&&l>h)return 0;var u=f.cubicRootAt(e,r,o,l,h,y);if(0===u)return 0;for(var d,p,v=0,m=-1,g=0;u>g;g++){var x=y[g],b=f.cubicAt(t,n,a,s,x);c>b||(0>m&&(m=f.cubicExtrema(e,r,o,l,_),_[1]<_[0]&&m>1&&i(),d=f.cubicAt(e,r,o,l,_[0]),m>1&&(p=f.cubicAt(e,r,o,l,_[1]))),v+=2==m?x<_[0]?e>d?1:-1:x<_[1]?d>p?1:-1:p>l?1:-1:x<_[0]?e>d?1:-1:d>l?1:-1)}return v}function r(t,e,i,n,r,a,o,s){if(s>e&&s>n&&s>a||e>s&&n>s&&a>s)return 0;var l=f.quadraticRootAt(e,n,a,s,y);if(0===l)return 0;var c=f.quadraticExtremum(e,n,a);if(c>=0&&1>=c){for(var h=0,u=f.quadraticAt(e,n,a,c),d=0;l>d;d++){var p=f.quadraticAt(t,i,r,y[d]);p>o||(h+=y[d]u?1:-1:u>a?1:-1)}return h}var p=f.quadraticAt(t,i,r,y[0]);return p>o?0:e>a?1:-1}function a(t,e,i,n,r,a,o,s){if(s-=e,s>i||-i>s)return 0;var l=Math.sqrt(i*i-s*s);if(y[0]=-l,y[1]=l,Math.abs(n-r)%m<1e-4){n=0,r=m;var c=a?1:-1;return o>=y[0]+t&&o<=y[1]+t?c:0}if(a){var l=n;n=d(r),r=d(l)}else n=d(n),r=d(r);n>r&&(r+=m);for(var h=0,u=0;2>u;u++){var f=y[u];if(f+t>o){var p=Math.atan2(s,f),c=a?1:-1;0>p&&(p=m+p),(p>=n&&r>=p||p+m>=n&&r>=p+m)&&(p>Math.PI/2&&p<1.5*Math.PI&&(c=-c),h+=c)}}return h}function o(t,i,o,l,d){for(var f=0,m=0,g=0,y=0,_=0,x=0;x1&&(o||(f+=p(m,g,y,_,l,d)),0!==f))return!0;switch(1==x&&(m=t[x],g=t[x+1],y=m,_=g),b){case s.M:y=t[x++],_=t[x++],m=y,g=_;break;case s.L:if(o){if(v(m,g,t[x],t[x+1],i,l,d))return!0}else f+=p(m,g,t[x],t[x+1],l,d)||0;m=t[x++],g=t[x++];break;case s.C:if(o){if(c.containStroke(m,g,t[x++],t[x++],t[x++],t[x++],t[x],t[x+1],i,l,d))return!0}else f+=n(m,g,t[x++],t[x++],t[x++],t[x++],t[x],t[x+1],l,d)||0;m=t[x++],g=t[x++];break;case s.Q:if(o){if(h.containStroke(m,g,t[x++],t[x++],t[x],t[x+1],i,l,d))return!0}else f+=r(m,g,t[x++],t[x++],t[x],t[x+1],l,d)||0;m=t[x++],g=t[x++];break;case s.A:var w=t[x++],M=t[x++],S=t[x++],k=t[x++],A=t[x++],C=t[x++],T=(t[x++],1-t[x++]),D=Math.cos(A)*S+w,L=Math.sin(A)*k+M;x>1?f+=p(m,g,D,L,l,d):(y=D,_=L);var z=(l-w)*k/S+w;if(o){if(u.containStroke(w,M,k,A,A+C,T,i,z,d))return!0}else f+=a(w,M,k,A,A+C,T,z,d);m=Math.cos(A+C)*S+w,g=Math.sin(A+C)*k+M;break;case s.R:y=m=t[x++],_=g=t[x++];var P=t[x++],I=t[x++],D=y+P,L=_+I;if(o){if(v(y,_,D,_,i,l,d)||v(D,_,D,L,i,l,d)||v(D,L,y,L,i,l,d)||v(y,L,D,L,i,l,d))return!0}else f+=p(D,_,D,L,l,d),f+=p(y,L,y,_,l,d);break;case s.Z:if(o){if(v(m,g,y,_,i,l,d))return!0}else if(f+=p(m,g,y,_,l,d),0!==f)return!0;m=y,g=_}}return o||e(g,_)||(f+=p(m,g,y,_,l,d)||0),0!==f}var s=t("../core/PathProxy").CMD,l=t("./line"),c=t("./cubic"),h=t("./quadratic"),u=t("./arc"),d=t("./util").normalizeRadian,f=t("../core/curve"),p=t("./windingLine"),v=l.containStroke,m=2*Math.PI,g=1e-4,y=[-1,-1,-1],_=[-1,-1];return{contain:function(t,e,i){return o(t,0,!1,e,i)},containStroke:function(t,e,i,n){return o(t,e,!0,i,n)}}}),e("zrender/graphic/Path",[qi,"./Displayable",di,"../core/PathProxy","../contain/path","./Gradient"],function(t){function e(t){var e=t.fill;return null!=e&&"none"!==e}function i(t){var e=t[wi];return null!=e&&"none"!==e&&t[Mi]>0}function n(t){r.call(this,t),this.path=new o}var r=t("./Displayable"),a=t(di),o=t("../core/PathProxy"),s=t("../contain/path"),l=t("./Gradient"),c=Math.abs;return n[Wi]={constructor:n,type:"path",__dirtyPath:!0,strokeContainThreshold:5,brush:function(t){t.save();var n=this.style,r=this.path,a=i(n),o=e(n);this.__dirtyPath&&(o&&n.fill instanceof l&&n.fill.updateCanvasGradient(this,t),a&&n[wi]instanceof l&&n[wi].updateCanvasGradient(this,t)),n.bind(t,this),this.setTransform(t);var s=n.lineDash,c=n.lineDashOffset,h=!!t.setLineDash;this.__dirtyPath||s&&!h&&a?(r=this.path[Ot](t),s&&!h&&(r.setLineDash(s),r.setLineDashOffset(c)),this[Dt](r,this.shape),this.__dirtyPath=!1):(t[Ot](),this.path.rebuildPath(t)),o&&r.fill(t),s&&h&&(t.setLineDash(s),t.lineDashOffset=c),a&&r[wi](t),null!=n.text&&this.drawRectText(t,this[ei]()),t[Tt]()},buildPath:function(t,e){},getBoundingRect:function(){var t=this._rect,e=this.style;if(!t){var n=this.path;this.__dirtyPath&&(n[Ot](),this[Dt](n,this.shape)),t=n[ei]()}if(i(e)&&(this[Kt]||!this._rect)){var r=this._rectWithStroke||(this._rectWithStroke=t.clone());r.copy(t);var a=e[Mi],o=e.strokeNoScale?this.getLineScale():1;return a=Math.max(a,this.strokeContainThreshold),o>1e-10&&(r.width+=a/o,r[vi]+=a/o,r.x-=a/o/2,r.y-=a/o/2),r}return this._rect=t,t},contain:function(t,n){var r=this[se](t,n),a=this[ei](),o=this.style;if(t=r[0],n=r[1],a[Rt](t,n)){var l=this.path.data;if(i(o)){var c=o[Mi],h=o.strokeNoScale?this.getLineScale():1;if(1e-10>h)return!1;if(c=Math.max(c,this.strokeContainThreshold),s.containStroke(l,c/h,t,n))return!0}if(e(o))return s[Rt](l,t,n)}return!1},dirty:function(t){0===arguments[Vi]&&(t=!0),t&&(this.__dirtyPath=t,this._rect=null),this[Kt]=!0,this.__zr&&this.__zr[Jt](),this.__clipTarget&&this.__clipTarget.dirty()},animateShape:function(t){return this[ie]("shape",t)},attrKV:function(t,e){"shape"===t?this[Ct](e):r[Wi].attrKV.call(this,t,e)},setShape:function(t,e){var i=this.shape;if(i){if(a[Ee](t))for(var n in t)i[n]=t[n];else i[t]=e;this.dirty(!0)}return this},getLineScale:function(){var t=this[ue];return t&&c(t[0]-1)>1e-10&&c(t[3]-1)>1e-10?Math.sqrt(c(t[0]*t[3]-t[2]*t[1])):1}},n[Di]=function(t){var e=function(e){n.call(this,e),t.style&&this.style.extendFrom(t.style,!1);var i=t.shape;if(i){this.shape=this.shape||{};var r=this.shape;for(var a in i)!r.hasOwnProperty(a)&&i.hasOwnProperty(a)&&(r[a]=i[a])}t.init&&t.init.call(this,e)};a[Ti](e,n);for(var i in t)"style"!==i&&"shape"!==i&&(e[Wi][i]=t[i]);return e},a[Ti](n,r),n}),e("zrender/tool/transformPath",[qi,"../core/PathProxy","../core/vector"],function(t){function e(t,e){var n,l,c,h,u,d=t.data,f=i.M,p=i.C,v=i.L,m=i.R,g=i.A,y=i.Q;for(c=0,h=0;cu;u++){var S=a[u];S[0]=d[c++],S[1]=d[c++],r(S,S,e),d[h++]=S[0],d[h++]=S[1]}}}var i=t("../core/PathProxy").CMD,n=t("../core/vector"),r=n[mi],a=[[],[],[]],o=Math.sqrt,s=Math.atan2;return e}),e("zrender/tool/path",[qi,"../graphic/Path","../core/PathProxy","./transformPath","../core/matrix"],function(t){function e(t,e,i,n,r,a,o,s,l,f,m){var g=l*(d/180),y=u(g)*(t-i)/2+h(g)*(e-n)/2,_=-1*h(g)*(t-i)/2+u(g)*(e-n)/2,x=y*y/(o*o)+_*_/(s*s);x>1&&(o*=c(x),s*=c(x));var b=(r===a?-1:1)*c((o*o*(s*s)-o*o*(_*_)-s*s*(y*y))/(o*o*(_*_)+s*s*(y*y)))||0,w=b*o*_/s,M=b*-s*y/o,S=(t+i)/2+u(g)*w-h(g)*M,k=(e+n)/2+h(g)*w+u(g)*M,A=v([1,0],[(y-w)/o,(_-M)/s]),C=[(y-w)/o,(_-M)/s],T=[(-1*y-w)/o,(-1*_-M)/s],D=v(C,T);p(C,T)<=-1&&(D=d),p(C,T)>=1&&(D=0),0===a&&D>0&&(D-=2*d),1===a&&0>D&&(D+=2*d),m.addData(f,S,k,o,s,A,D,g,a)}function i(t){if(!t)return[];var i,n=t[Qe](/-/g," -")[Qe](/ /g," ")[Qe](/ /g,",")[Qe](/,,/g,",");for(i=0;i0&&""===m[0]&&m.shift();for(var g=0;gn;n++)i=t[n],i[Kt]&&i[Dt](i.path,i.shape),a.push(i.path);var s=new r(e);return s[Dt]=function(t){t.appendPath(a);var e=t[Zi]();e&&t.rebuildPath(e)},s}}}),e("zrender/graphic/helper/roundRect",[qi],function(t){return{buildPath:function(t,e){var i,n,r,a,o=e.x,s=e.y,l=e.width,c=e[vi],h=e.r;typeof h===Oi?i=n=r=a=h:h instanceof Array?1===h[Vi]?i=n=r=a=h[0]:2===h[Vi]?(i=r=h[0],n=a=h[1]):3===h[Vi]?(i=h[0],n=a=h[1],r=h[2]):(i=h[0],n=h[1],r=h[2],a=h[3]):i=n=r=a=0;var u;i+n>l&&(u=i+n,i*=l/u,n*=l/u),r+a>l&&(u=r+a,r*=l/u,a*=l/u),n+r>c&&(u=n+r,n*=c/u,r*=c/u),i+a>c&&(u=i+a,i*=c/u,a*=c/u),t[It](o+i,s),t[Pt](o+l-n,s),0!==n&&t.quadraticCurveTo(o+l,s,o+l,s+n),t[Pt](o+l,s+c-r),0!==r&&t.quadraticCurveTo(o+l,s+c,o+l-r,s+c),t[Pt](o+a,s+c),0!==a&&t.quadraticCurveTo(o,s+c,o,s+c-a),t[Pt](o,s+i),0!==i&&t.quadraticCurveTo(o,s,o+i,s)}}}),e("zrender/core/LRU",[qi],function(t){var e=function(){this.head=null,this.tail=null,this._len=0},i=e[Wi];i.insert=function(t){var e=new n(t);return this.insertEntry(e),e},i.insertEntry=function(t){this.head?(this.tail.next=t,t.prev=this.tail,this.tail=t):this.head=this.tail=t,this._len++},i[Qt]=function(t){var e=t.prev,i=t.next;e?e.next=i:this.head=i,i?i.prev=e:this.tail=e,t.next=t.prev=null,this._len--},i.len=function(){return this._len};var n=function(t){this.value=t,this.next,this.prev},r=function(t){this._list=new e,this._map={},this._maxSize=t||10},a=r[Wi];return a.put=function(t,e){var i=this._list,n=this._map;if(null==n[t]){var r=i.len();if(r>=this._maxSize&&r>0){var a=i.head;i[Qt](a),delete n[a.key]}var o=i.insert(e);o.key=t,n[t]=o}},a.get=function(t){var e=this._map[t],i=this._list;return null!=e?(e!==i.tail&&(i[Qt](e),i.insertEntry(e)),e.value):void 0},a.clear=function(){this._list.clear(),this._map={}},r}),e("zrender/graphic/Image",[qi,"./Displayable",ui,di,"./helper/roundRect","../core/LRU"],function(t){var e=t("./Displayable"),i=t(ui),n=t(di),r=t("./helper/roundRect"),a=t("../core/LRU"),o=new a(50),s=function(t){e.call(this,t)};return s[Wi]={constructor:s,type:"image",brush:function(t){var e,i=this.style,n=i.image;if(e=typeof n===Ri?this._image:n,!e&&n){var a=o.get(n);if(!a)return e=new Image,e.onload=function(){e.onload=null;for(var t=0;ts;s++)o+=i[yi](t[s-1],t[s]);var l=o/2;l=r>l?r:l;for(var s=0;l>s;s++){var c,h,u,d=s/(l-1)*(n?r:r-1),f=Math.floor(d),p=d-f,v=t[f%r];n?(c=t[(f-1+r)%r],h=t[(f+1)%r],u=t[(f+2)%r]):(c=t[0===f?f:f-1],h=t[f>r-2?r-1:f+1],u=t[f>r-3?r-1:f+2]);var m=p*p,g=p*m;a.push([e(c[0],v[0],h[0],u[0],p,m,g),e(c[1],v[1],h[1],u[1],p,m,g)])}return a}}),e("zrender/graphic/helper/smoothBezier",[qi,"../../core/vector"],function(t){var e=t("../../core/vector"),i=e.min,n=e.max,r=e.scale,a=e[yi],o=e.add;return function(t,s,l,c){var h,u,d,f,p=[],v=[],m=[],g=[];if(c){d=[1/0,1/0],f=[-(1/0),-(1/0)];for(var y=0,_=t[Vi];_>y;y++)i(d,d,t[y]),n(f,f,t[y]);i(d,d,c[0]),n(f,f,c[1])}for(var y=0,_=t[Vi];_>y;y++){var x=t[y];if(l)h=t[y?y-1:_-1],u=t[(y+1)%_];else{if(0===y||y===_-1){p.push(e.clone(t[y]));continue}h=t[y-1],u=t[y+1]}e.sub(v,u,h),r(v,v,s);var b=a(x,h),w=a(x,u),M=b+w;0!==M&&(b/=M,w/=M),r(m,v,-b),r(g,v,w);var S=o([],x,m),k=o([],x,g);c&&(n(S,S,d),i(S,S,f),n(k,k,d),i(k,k,f)),p.push(S),p.push(k)}return l&&p.push(p.shift()),p}}),e("zrender/graphic/helper/poly",[qi,"./smoothSpline","./smoothBezier"],function(t){var e=t("./smoothSpline"),i=t("./smoothBezier");return{buildPath:function(t,n,r){var a=n[At],o=n.smooth;if(a&&a[Vi]>=2){if(o&&"spline"!==o){var s=i(a,o,r,n.smoothConstraint);t[It](a[0][0],a[0][1]);for(var l=a[Vi],c=0;(r?l:l-1)>c;c++){var h=s[2*c],u=s[2*c+1],d=a[(c+1)%l];t[zt](h[0],h[1],u[0],u[1],d[0],d[1])}}else{"spline"===o&&(a=e(a,r)),t[It](a[0][0],a[0][1]);for(var c=1,f=a[Vi];f>c;c++)t[Pt](a[c][0],a[c][1])}r&&t[Lt]()}}}}),e("zrender/graphic/shape/Polygon",[qi,"../helper/poly","../Path"],function(t){var e=t("../helper/poly");return t("../Path")[Di]({type:"polygon",shape:{points:null,smooth:!1,smoothConstraint:null},buildPath:function(t,i){e[Dt](t,i,!0)}})}),e("zrender/graphic/shape/Polyline",[qi,"../helper/poly","../Path"],function(t){var e=t("../helper/poly");return t("../Path")[Di]({type:"polyline",shape:{points:null,smooth:!1,smoothConstraint:null},style:{stroke:"#000",fill:null},buildPath:function(t,i){e[Dt](t,i,!1)}})}),e("zrender/graphic/shape/Rect",[qi,"../helper/roundRect","../Path"],function(t){var e=t("../helper/roundRect");return t("../Path")[Di]({type:"rect",shape:{r:0,x:0,y:0,width:0,height:0},buildPath:function(t,i){var n=i.x,r=i.y,a=i.width,o=i[vi];i.r?e[Dt](t,i):t.rect(n,r,a,o),t[Lt]()}})}),e("zrender/graphic/shape/Line",[qi,"../Path"],function(t){return t("../Path")[Di]({type:"line",shape:{x1:0,y1:0,x2:0,y2:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var i=e.x1,n=e.y1,r=e.x2,a=e.y2,o=e.percent;0!==o&&(t[It](i,n),1>o&&(r=i*(1-o)+r*o,a=n*(1-o)+a*o),t[Pt](r,a))},pointAt:function(t){var e=this.shape;return[e.x1*(1-t)+e.x2*t,e.y1*(1-t)+e.y2*t]}})}),e("zrender/graphic/shape/BezierCurve",[qi,"../../core/curve","../Path"],function(t){var e=t("../../core/curve"),i=e.quadraticSubdivide,n=e.cubicSubdivide,r=e.quadraticAt,a=e.cubicAt,o=[];return t("../Path")[Di]({type:"bezier-curve",shape:{x1:0,y1:0,x2:0,y2:0,cpx1:0,cpy1:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var r=e.x1,a=e.y1,s=e.x2,l=e.y2,c=e.cpx1,h=e.cpy1,u=e.cpx2,d=e.cpy2,f=e.percent;0!==f&&(t[It](r,a),null==u||null==d?(1>f&&(i(r,c,s,f,o),c=o[1],s=o[2],i(a,h,l,f,o),h=o[1],l=o[2]),t.quadraticCurveTo(c,h,s,l)):(1>f&&(n(r,c,u,s,f,o),c=o[1],u=o[2],s=o[3],n(a,h,d,l,f,o),h=o[1],d=o[2],l=o[3]),t[zt](c,h,u,d,s,l)))},pointAt:function(t){var e=this.shape,i=e.cpx2,n=e.cpy2;return null===i||null===n?[r(e.x1,e.cpx1,e.x2,t),r(e.y1,e.cpy1,e.y2,t)]:[a(e.x1,e.cpx1,e.cpx1,e.x2,t),a(e.y1,e.cpy1,e.cpy1,e.y2,t)]}})}),e("zrender/graphic/shape/Arc",[qi,"../Path"],function(t){return t("../Path")[Di]({type:"arc",shape:{cx:0,cy:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},style:{stroke:"#000",fill:null},buildPath:function(t,e){var i=e.cx,n=e.cy,r=e.r,a=e.startAngle,o=e.endAngle,s=e.clockwise,l=Math.cos(a),c=Math.sin(a);t[It](l*r+i,c*r+n),t.arc(i,n,r,a,o,!s)}})}),e("zrender/graphic/LinearGradient",[qi,di,"./Gradient"],function(t){var e=t(di),i=t("./Gradient"),n=function(t,e,n,r,a){this.x=null==t?0:t,this.y=null==e?0:e,this.x2=null==n?1:n,this.y2=null==r?0:r,i.call(this,a)};return n[Wi]={constructor:n,type:"linear",updateCanvasGradient:function(t,e){for(var i=t[ei](),n=this.x*i.width+i.x,r=this.x2*i.width+i.x,a=this.y*i[vi]+i.y,o=this.y2*i[vi]+i.y,s=e.createLinearGradient(n,a,r,o),l=this.colorStops,c=0;c=0?"white":i,a=e[ni](ii);u[Di](t,{textDistance:e[Si](yi)||5,textFont:a[ti](),textPosition:n,textFill:a[mt]()||r})},_[vt]=u.curry(h,!0),_[pt]=u.curry(h,!1),_.getTransform=function(t,e){for(var i=m.identity([]);t&&t!==e;)m.mul(i,t[ce](),i),t=t[he];return i},_[mi]=function(t,e,i){return i&&(e=m.invert([],e)),g[mi]([],t,e)},_.transformDirection=function(t,e,i){var n=0===e[4]||0===e[5]||0===e[0]?1:Math.abs(2*e[4]/e[0]),r=0===e[4]||0===e[5]||0===e[2]?1:Math.abs(2*e[4]/e[2]),a=["left"===t?-n:"right"===t?n:0,"top"===t?-r:t===hi?r:0];return a=_[mi](a,e,i),Math.abs(a[0])>Math.abs(a[1])?a[0]>0?"right":"left":a[1]>0?hi:"top"},_}),e("zrender/core/env",[],function(){function t(t){var e=this.os={},i=this.browser={},n=t.match(/Web[kK]it[\/]{0,1}([\d.]+)/),r=t.match(/(Android);?[\s\/]+([\d.]+)?/),a=t.match(/(iPad).*OS\s([\d_]+)/),o=t.match(/(iPod)(.*OS\s([\d_]+))?/),s=!a&&t.match(/(iPhone\sOS)\s([\d_]+)/),l=t.match(/(webOS|hpwOS)[\s\/]([\d.]+)/),c=l&&t.match(/TouchPad/),h=t.match(/Kindle\/([\d.]+)/),u=t.match(/Silk\/([\d._]+)/),d=t.match(/(BlackBerry).*Version\/([\d.]+)/),f=t.match(/(BB10).*Version\/([\d.]+)/),p=t.match(/(RIM\sTablet\sOS)\s([\d.]+)/),v=t.match(/PlayBook/),m=t.match(/Chrome\/([\d.]+)/)||t.match(/CriOS\/([\d.]+)/),g=t.match(/Firefox\/([\d.]+)/),y=t.match(/MSIE ([\d.]+)/),_=n&&t.match(/Mobile\//)&&!m,x=t.match(/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/)&&!m,y=t.match(/MSIE\s([\d.]+)/);return(i.webkit=!!n)&&(i.version=n[1]),r&&(e.android=!0,e.version=r[2]),s&&!o&&(e.ios=e.iphone=!0,e.version=s[2][Qe](/_/g,".")),a&&(e.ios=e.ipad=!0,e.version=a[2][Qe](/_/g,".")),o&&(e.ios=e.ipod=!0,e.version=o[3]?o[3][Qe](/_/g,"."):null),l&&(e.webos=!0,e.version=l[2]),c&&(e.touchpad=!0),d&&(e.blackberry=!0,e.version=d[2]),f&&(e.bb10=!0,e.version=f[2]),p&&(e.rimtabletos=!0,e.version=p[2]),v&&(i.playbook=!0),h&&(e.kindle=!0,e.version=h[1]),u&&(i.silk=!0,i.version=u[1]),!u&&e.android&&t.match(/Kindle Fire/)&&(i.silk=!0),m&&(i.chrome=!0,i.version=m[1]),g&&(i.firefox=!0,i.version=g[1]),y&&(i.ie=!0,i.version=y[1]),_&&(t.match(/Safari/)||e.ios)&&(i.safari=!0),x&&(i.webview=!0),y&&(i.ie=!0,i.version=y[1]),e.tablet=!!(a||v||r&&!t.match(/Mobile/)||g&&t.match(/Tablet/)||y&&!t.match(/Phone/)&&t.match(/Touch/)),e.phone=!(e.tablet||e.ipod||!(r||s||l||d||f||m&&t.match(/Android/)||m&&t.match(/CriOS\/([\d.]+)/)||g&&t.match(/Mobile/)||y&&t.match(/Touch/))),{browser:i,os:e,node:!1,canvasSupported:document[Ni](Ei)[Zi]?!0:!1}}return typeof navigator===_i?{browser:{},os:{},node:!0,canvasSupported:!0}:t(navigator.userAgent)}),e(ft,[qi,"../mixin/Eventful"],function(t){function e(t){return t.getBoundingClientRect?t.getBoundingClientRect():{left:0,top:0}}function i(t,i){if(i=i||window.event,null!=i.zrX)return i;var n=i.type,r=n&&n[Bi]("touch")>=0;if(r){var a="touchend"!=n?i.targetTouches[0]:i.changedTouches[0];if(a){var o=e(t);i.zrX=a.clientX-o.left,i.zrY=a.clientY-o.top}}else{var s=0,l=0;i.pageX||i.pageY?(s=i.pageX,l=i.pageY):(s=i.clientX+document.body.scrollLeft+document.documentElement.scrollLeft,l=i.clientY+document.body.scrollTop+document.documentElement.scrollTop);var c=e(t),h=c.top+(window.pageYOffset||t.scrollTop)-(t.clientTop||0),u=c.left+(window.pageXOffset||t.scrollLeft)-(t.clientLeft||0);i.zrX=s-u,i.zrY=l-h,i.zrDelta=i.wheelDelta?i.wheelDelta/120:-(i.detail||0)/3}return i}function n(t,e,i){o?t.addEventListener(e,i):t.attachEvent("on"+e,i)}function r(t,e,i){o?t.removeEventListener(e,i):t.detachEvent("on"+e,i)}var a=t("../mixin/Eventful"),o=typeof window!==_i&&!!window.addEventListener,s=o?function(t){t.preventDefault(),t.stopPropagation(),t.cancelBubble=!0}:function(t){t.returnValue=!1,t.cancelBubble=!0};return{normalizeEvent:i,addEventListener:n,removeEventListener:r,stop:s,Dispatcher:a}}),e("zrender/mixin/Draggable",[qi],function(t){function e(){this.on("mousedown",this._dragStart,this),this.on(dt,this._drag,this),this.on("mouseup",this._dragEnd,this),this.on("globalout",this._dragEnd,this)}return e[Wi]={constructor:e,_dragStart:function(t){var e=t[oe];e&&e[ee]&&(this._draggingTarget=e,e.dragging=!0,this._x=t[ut],this._y=t[ht],this._dispatchProxy(e,"dragstart",t.event))},_drag:function(t){var e=this._draggingTarget;if(e){var i=t[ut],n=t[ht],r=i-this._x,a=n-this._y;this._x=i,this._y=n,e.drift(r,a,t),this._dispatchProxy(e,"drag",t.event);var o=this._findHover(i,n,e),s=this._dropTarget;this._dropTarget=o,e!==o&&(s&&o!==s&&this._dispatchProxy(s,"dragleave",t.event),o&&o!==s&&this._dispatchProxy(o,"dragenter",t.event))}},_dragEnd:function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this._dispatchProxy(e,"dragend",t.event),this._dropTarget&&this._dispatchProxy(this._dropTarget,"drop",t.event),this._draggingTarget=null,this._dropTarget=null}},e}),e("zrender/core/GestureMgr",[qi],function(t){function e(t){var e=t[1][0]-t[0][0],i=t[1][1]-t[0][1];return Math.sqrt(e*e+i*i)}function i(t){return[(t[0][0]+t[1][0])/2,(t[0][1]+t[1][1])/2]}var n=function(){this._track=[]};n[Wi]={constructor:n,recognize:function(t,e){return this._doTrack(t,e),this._recognize(t)},clear:function(){return this._track[Vi]=0,this},_doTrack:function(t,e){var i=t.touches;if(i){for(var n={points:[],touches:[],target:e,event:t},r=0,a=i[Vi];a>r;r++){var o=i[r];n[At].push([o.clientX,o.clientY]),n.touches.push(o)}this._track.push(n)}},_recognize:function(t){for(var e in r)if(r.hasOwnProperty(e)){var i=r[e](this._track,t);if(i)return i}}};var r={pinch:function(t,n){var r=t[Vi];if(r){var a=(t[r-1]||{})[At],o=(t[r-2]||{})[At]||a;if(o&&o[Vi]>1&&a&&a[Vi]>1){var s=e(a)/e(o);!isFinite(s)&&(s=1),n.pinchScale=s;var l=i(a);return n.pinchX=l[0],n.pinchY=l[1],{type:"pinch",target:t[0][oe],event:n}}}}};return n}),e("zrender/Handler",[qi,"./core/env","./core/event","./core/util","./mixin/Draggable","./core/GestureMgr","./mixin/Eventful"],function(t){function e(t){return"_"+t+"Handler"}function i(t,e,i){return{type:t,event:i,target:e,cancelBubble:!1,offsetX:i.zrX,offsetY:i.zrY,gestureEvent:i.gestureEvent,pinchX:i.pinchX,pinchY:i.pinchY,pinchScale:i.pinchScale,wheelDelta:i.zrDelta}}function n(t,e,i){var n=t._gestureMgr;"start"===i&&n.clear();var r=n.recognize(e,t._findHover(e.zrX,e.zrY,null));if("end"===i&&n.clear(),r){var a=r.type;e.gestureEvent=a,t._dispatchProxy(r[oe],a,r.event)}}function r(t){for(var i=d[Ii](f),n=i[Vi];n--;){var r=i[n];t[e(r)]=l.bind(y[r],t)}}function a(t,e,i){if(t[t.rectHover?"rectContain":Rt](e,i)){for(var n=t[he];n;){if(n.clipPath&&!n.clipPath[Rt](e,i))return!1;n=n[he]}return!0}return!1}var o=t("./core/env"),s=t("./core/event"),l=t("./core/util"),c=t("./mixin/Draggable"),h=t("./core/GestureMgr"),u=t("./mixin/Eventful"),d=["click","dblclick","mousewheel",dt,gt,"mouseup","mousedown"],f=["touchstart","touchend","touchmove"],p=300,v=s.addEventListener,m=s.removeEventListener,g=s.normalizeEvent,y={mousemove:function(t){t=g(this.root,t);var e=t.zrX,i=t.zrY,n=this._findHover(e,i,null),r=this._hovered;this._hovered=n,this.root.style.cursor=n?n.cursor:this._defaultCursorStyle,r&&n!==r&&r.__zr&&this._dispatchProxy(r,gt,t),this._dispatchProxy(n,dt,t),n&&n!==r&&this._dispatchProxy(n,yt,t)},mouseout:function(t){t=g(this.root,t);var e=t.toElement||t.relatedTarget;if(e!=this.root)for(;e&&9!=e.nodeType;){if(e===this.root)return;e=e[ct]}this._dispatchProxy(this._hovered,gt,t),this[Ht]("globalout",{event:t})},touchstart:function(t){t=g(this.root,t),this._lastTouchMoment=new Date,n(this,t,"start"),this._mousemoveHandler(t),this._mousedownHandler(t)},touchmove:function(t){t=g(this.root,t),n(this,t,"change"),this._mousemoveHandler(t)},touchend:function(t){t=g(this.root,t),n(this,t,"end"),this._mouseupHandler(t),+new Date-this._lastTouchMoment=0;r--)if(!n[r].silent&&n[r]!==i&&a(n[r],t,e))return n[r]}},l.mixin(_,u),l.mixin(_,c),_}),e("zrender/Storage",[qi,"./core/util","./container/Group"],function(t){function e(t,e){return t[ot]===e[ot]?t.z===e.z?t.z2===e.z2?t.__renderidx-e.__renderidx:t.z2-e.z2:t.z-e.z:t[ot]-e[ot]}var i=t("./core/util"),n=t("./container/Group"),r=function(){this._elements={},this._roots=[],this._displayList=[],this._displayListLen=0};return r[Wi]={constructor:r,getDisplayList:function(t){return t&&this.updateDisplayList(),this._displayList},updateDisplayList:function(){this._displayListLen=0;for(var t=this._roots,i=this._displayList,n=0,r=t[Vi];r>n;n++){var a=t[n];this._updateAndAddDisplayable(a)}i[Vi]=this._displayListLen;for(var n=0,r=i[Vi];r>n;n++)i[n].__renderidx=n;i.sort(e)},_updateAndAddDisplayable:function(t,e){if(!t[te]){t.beforeUpdate(),t[at](),t.afterUpdate();var i=t.clipPath;if(i&&(i[he]=t,i.updateTransform(),e?(e=e.slice(),e.push(i)):e=[i]),"group"==t.type){for(var n=t._children,r=0;re;e++)this.delRoot(t[e]);else{var o;o=typeof t==Ri?this._elements[t]:t;var s=i[Bi](this._roots,o);s>=0&&(this[$t](o.id),this._roots[Ie](s,1),o instanceof n&&o.delChildrenFromStorage(this))}},addToMap:function(t){return t instanceof n&&(t.__storage=this),t.dirty(),this._elements[t.id]=t,this},get:function(t){return this._elements[t]},delFromMap:function(t){var e=this._elements,i=e[t];return i&&(delete e[t],i instanceof n&&(i.__storage=null)),this},dispose:function(){this._elements=this._renderList=this._roots=null}},r}),e("zrender/animation/Animation",[qi,di,"../core/event","./Animator"],function(t){var e=t(di),i=t("../core/event").Dispatcher,n=typeof window!==_i&&(window.requestAnimationFrame||window.msRequestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(t){setTimeout(t,16)},r=t("./Animator"),a=function(t){t=t||{},this.stage=t.stage||{},this.onframe=t.onframe||function(){},this._clips=[],this._running=!1,this._time=0,i.call(this)};return a[Wi]={constructor:a,addClip:function(t){this._clips.push(t)},addAnimator:function(t){t[re]=this;for(var e=t.getClips(),i=0;i=0&&this._clips[Ie](i,1)},removeAnimator:function(t){for(var e=t.getClips(),i=0;io;o++){var s=i[o],l=s.step(t);l&&(r.push(l),a.push(s))}for(var o=0;n>o;)i[o]._needsRemove?(i[o]=i[n-1],i.pop(),n--):o++;n=r[Vi];for(var o=0;n>o;o++)a[o].fire(r[o]);this._time=t,this.onframe(e),this[Ht]("frame",e),this.stage[at]&&this.stage[at]()},start:function(){function t(){e._running&&(n(t),e._update())}var e=this;this._running=!0,this._time=(new Date).getTime(),n(t)},stop:function(){this._running=!1},clear:function(){this._clips=[]},animate:function(t,e){e=e||{};var i=new r(t,e.loop,e.getter,e.setter);return i}},e.mixin(a,i),a}),e("zrender/Layer",[qi,"./core/util","./config"],function(t){function e(){return!1}function i(t,e,i,n){var r=document[Ni](e),a=i[ze](),o=i[Le](),s=r.style;return s[He]="absolute",s.left=0,s.top=0,s.width=a+"px",s[vi]=o+"px",r.width=a*n,r[vi]=o*n,r.setAttribute("data-zr-dom-id",t),r}var n=t("./core/util"),r=t("./config"),a=function(t,a,o){var s;o=o||r.devicePixelRatio,typeof t===Ri?s=i(t,Ei,a,o):n[Ee](t)&&(s=t,t=s.id),this.id=t,this.dom=s;var l=s.style;l&&(s.onselectstart=e,l["-webkit-user-select"]="none",l["user-select"]="none",l["-webkit-touch-callout"]="none",l["-webkit-tap-highlight-color"]="rgba(0,0,0,0)"),this.domBack=null,this.ctxBack=null,this.painter=a,this.config=null,this.clearColor=0,this.motionBlur=!1,this.lastFrameAlpha=.7,this.dpr=o};return a[Wi]={constructor:a,elCount:0,__dirty:!0,initContext:function(){this.ctx=this.dom[Zi]("2d");var t=this.dpr;1!=t&&this.ctx.scale(t,t)},createBackBuffer:function(){var t=this.dpr;this.domBack=i("back-"+this.id,Ei,this.painter,t),this.ctxBack=this.domBack[Zi]("2d"),1!=t&&this.ctxBack.scale(t,t)},resize:function(t,e){var i=this.dpr,n=this.dom,r=n.style,a=this.domBack;r.width=t+"px",r[vi]=e+"px",n.width=t*i,n[vi]=e*i,1!=i&&this.ctx.scale(i,i),a&&(a.width=t*i,a[vi]=e*i,1!=i&&this.ctxBack.scale(i,i))},clear:function(t){var e=this.dom,i=this.ctx,n=e.width,r=e[vi],a=this.clearColor,o=this.motionBlur&&!t,s=this.lastFrameAlpha,l=this.dpr;if(o&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(e,0,0,n/l,r/l)),i.clearRect(0,0,n/l,r/l),a&&(i.save(),i.fillStyle=this.clearColor,i.fillRect(0,0,n/l,r/l),i[Tt]()),o){var c=this.domBack;i.save(),i.globalAlpha=s,i.drawImage(c,0,0,n/l,r/l),i[Tt]()}}},a}),e("zrender/Painter",[qi,"./config","./core/util","./core/log","./core/BoundingRect","./Layer","./graphic/Image"],function(t){function e(t){return parseInt(t,10)}function i(t){return t?t.isBuildin?!0:typeof t[rt]!==Pi||typeof t[Jt]!==Pi?!1:!0:!1}function n(t){t.__unusedCount++}function r(t){t[Kt]=!1,1==t.__unusedCount&&t.clear()}function a(t,e,i){return f.copy(t[ei]()),t[ue]&&f[mi](t[ue]),p.width=e,p[vi]=i,!f[nt](p)}function o(t,e){if(!t||!e||t[Vi]!==e[Vi])return!0;for(var i=0;ip;p++){var m=t[p],g=this._singleCanvas?0:m[ot];if(l!==g&&(l=g,i=this.getLayer(l),i.isBuildin||h("ZLevel "+l+" has been used by unkown layer "+i.id),c=i.ctx,i.__unusedCount=0,(i[Kt]||e)&&i.clear()),(i[Kt]||e)&&!m[Ut]&&0!==m.style[bi]&&m.scale[0]&&m.scale[1]&&(!m.culling||!a(m,u,d))){var y=m.__clipPaths;o(y,f)&&(f&&c[Tt](),y&&(c.save(),s(y,c)),f=y),m.beforeBrush&&m.beforeBrush(c),m.brush(c,!1),m.afterBrush&&m.afterBrush(c)}m[Kt]=!1}f&&c[Tt](),this.eachBuildinLayer(r)},getLayer:function(t){if(this._singleCanvas)return this._layers[0];var e=this._layers[t];return e||(e=new d("zr_"+t,this,this.dpr),e.isBuildin=!0,this._layerConfig[t]&&c.merge(e,this._layerConfig[t],!0),this.insertLayer(t,e),e.initContext()),e},insertLayer:function(t,e){var n=this._layers,r=this._zlevelList,a=r[Vi],o=null,s=-1,l=this._domRoot;if(n[t])return void h("ZLevel "+t+" has been used already");if(!i(e))return void h("Layer of zlevel "+t+" is not valid");if(a>0&&t>r[0]){for(s=0;a-1>s&&!(r[s]t);s++);o=n[r[s]]}if(r[Ie](s+1,0,t),o){var c=o.dom;c.nextSibling?l.insertBefore(e.dom,c.nextSibling):l[et](e.dom)}else l.firstChild?l.insertBefore(e.dom,l.firstChild):l[et](e.dom);n[t]=e},eachLayer:function(t,e){var i,n,r=this._zlevelList;for(n=0;nn;n++){var a=t[n],o=this._singleCanvas?0:a[ot],s=e[o];if(s){if(s.elCount++,s[Kt])continue;s[Kt]=a[Kt]}}this.eachBuildinLayer(function(t,e){i[e]!==t.elCount&&(t[Kt]=!0)})},clear:function(){return this.eachBuildinLayer(this._clearLayer),this},_clearLayer:function(t){t.clear()},configLayer:function(t,e){if(e){var i=this._layerConfig;i[t]?c.merge(i[t],e,!0):i[t]=e;var n=this._layers[t];n&&c.merge(n,i[t],!0)}},delLayer:function(t){var e=this._layers,i=this._zlevelList,n=e[t];n&&(n.dom[ct].removeChild(n.dom),delete e[t],i[Ie](c[Bi](i,t),1))},resize:function(t,e){var i=this._domRoot;if(i.style.display="none",t=t||this._getWidth(),e=e||this._getHeight(),i.style.display="",this._width!=t||e!=this._height){i.style.width=t+"px",i.style[vi]=e+"px";for(var n in this._layers)this._layers[n][rt](t,e);this[Jt](!0)}return this._width=t,this._height=e,this},clearLayer:function(t){var e=this._layers[t];e&&e.clear()},dispose:function(){this.root[it]="",this.root=this[lt]=this._domRoot=this._layers=null},getRenderedCanvas:function(t){if(t=t||{},this._singleCanvas)return this._layers[0].dom;var e=new d("image",this,t.pixelRatio||this.dpr);e.initContext();var i=e.ctx;e.clearColor=t[tt],e.clear();for(var n=this[lt][st](!0),r=0;rt;t++)this._add&&this._add(c[t]);else this._add&&this._add(c)}}},i}),e("echarts/data/List",[qi,"../model/Model","./DataDiffer",Hi,"../util/model"],function(t){function e(t){return c[ki](t)||(t=[t]),t}var i=_i,n=typeof window===_i?global:window,r=typeof n.Float64Array===i?Array:n.Float64Array,a=typeof n.Int32Array===i?Array:n.Int32Array,o={"float":r,"int":a,ordinal:Array,number:Array,time:Array},s=t("../model/Model"),l=t("./DataDiffer"),c=t(Hi),h=t("../util/model"),u=c[Ee],d=["stackedOn","_nameList","_idList","_rawData"],f=function(t,e,i){c.each(d[Ii](i||[]),function(i){e.hasOwnProperty(i)&&(t[i]=e[i])})},p=function(t,e){t=t||["x","y"];for(var i={},n=[],r=0;r0&&(b+="__ec__"+d[w]),d[w]++),b&&(u[f]=b)}this._nameList=e,this._idList=u},v.count=function(){return this.indices[Vi]},v.get=function(t,e,i){var n=this._storage,r=this.indices[e],a=n[t]&&n[t][r],o=this._dimensionInfos[t];if(i&&o&&o.stackable)for(var s=this.stackedOn;s;){var l=s.get(t,e);(a>=0&&l>0||0>=a&&0>l)&&(a+=l),s=s.stackedOn}return a},v.getValues=function(t,e,i){var n=[];c[ki](t)||(i=e,e=t,t=this[B]);for(var r=0,a=t[Vi];a>r;r++)n.push(this.get(t[r],e,i));return n},v.hasValue=function(t){for(var e=this[B],i=this._dimensionInfos,n=0,r=e[Vi];r>n;n++)if(i[e[n]].type!==xe&&isNaN(this.get(e[n],t)))return!1;return!0},v[R]=function(t,e){var i=this._storage[t],n=this.getDimensionInfo(t);e=n&&n.stackable&&e;var r,a=(this._extent||(this._extent={}))[t+!!e];if(a)return a;if(i){for(var o=1/0,s=-(1/0),l=0,c=this.count();c>l;l++)r=this.get(t,l,e),o>r&&(o=r),r>s&&(s=r);return this._extent[t+e]=[o,s]}return[1/0,-(1/0)]},v.getSum=function(t,e){var i=this._storage[t],n=0;if(i)for(var r=0,a=this.count();a>r;r++){var o=this.get(t,r,e);isNaN(o)||(n+=o)}return n},v[Bi]=function(t,e){var i=this._storage,n=i[t],r=this.indices;if(n)for(var a=0,o=r[Vi];o>a;a++){var s=r[a];if(n[s]===e)return a}return-1},v[Vt]=function(t){for(var e=this.indices,i=this._nameList,n=0,r=e[Vi];r>n;n++){var a=e[n];if(i[a]===t)return n}return-1},v.indexOfNearest=function(t,e,i){c[ki](t)||(t=t?[t]:[]);var n=this._storage,r=n[t];if(r){for(var a=Number.MAX_VALUE,o=-1,s=0,l=t[Vi];l>s;s++)for(var h=0,u=this.count();u>h;h++){var d=Math.abs(this.get(t[s],h,i)-e);a>=d&&(a=d,o=h)}return o}return-1},v[ye]=function(t){var e=this.indices[t];return null==e?-1:e},v[ge]=function(t){return this._nameList[this.indices[t]]||""},v.getId=function(t){return this._idList[this.indices[t]]||this[ye](t)+""},v.each=function(t,i,n,r){typeof t===Pi&&(r=n,n=i,i=t,t=[]),t=c.map(e(t),this.getDimension,this);var a=[],o=t[Vi],s=this.indices;r=r||this;for(var l=0;lh;h++)a[h]=this.get(t[h],l,n);a[h]=l,i.apply(r,a)}},v.filterSelf=function(t,i,n,r){typeof t===Pi&&(r=n,n=i,i=t,t=[]),t=c.map(e(t),this.getDimension,this);var a=[],o=[],s=t[Vi],l=this.indices;r=r||this;for(var h=0;hd;d++)o[d]=this.get(t[d],h,n);o[d]=h,u=i.apply(r,o)}u&&a.push(l[h])}return this.indices=a,this._extent={},this},v[O]=function(t,e,i,n){typeof t===Pi&&(n=i,i=e,e=t,t=[]);var r=[];return this.each(t,function(){r.push(e&&e.apply(this,arguments))},i,n),r},v.map=function(t,i,n,r){t=c.map(e(t),this.getDimension,this);var a=this[B],o=new p(c.map(a,this.getDimensionInfo,this),this[H]),s=o.indices=this.indices;f(o,this,this._wrappedMethods);for(var l=o._storage={},h=this._storage,u=0;u=0?l[d]=new v.constructor(h[d][Vi]):l[d]=h[d]}var m=[];return this.each(t,function(){var e=arguments[arguments[Vi]-1],n=i&&i.apply(this,arguments);if(null!=n){typeof n===Oi&&(m[0]=n,n=m);for(var r=0;rl;l++)if(!t[l]){var c=a[l]||"extra"+(l-a[Vi]);t[l]=i(e,l)?{type:"ordinal",name:c}:c}return t}function i(t,e){for(var i=0,a=t[Vi];a>i;i++){var o=n(t[i]);if(!r[ki](o))return!1;var o=o[e];if(null!=o&&isFinite(o))return!1;if(r[Re](o)&&"-"!==o)return!0}return!1}function n(t){return r[ki](t)?t:r[Ee](t)?t.value:t}var r=t(Hi);return e}),e("echarts/chart/helper/createListFromArray",[qi,"../../data/List","../../data/helper/completeDimensions",Hi,T],function(t){function e(t){for(var e=0;e1){i=[];for(var a=0;r>a;a++)i[a]=n[e[a][0]]}else i=n.slice(0)}}return i}var o=t("../../data/List"),s=t("../../data/helper/completeDimensions"),l=t(Hi),c=t(T),h=c.getDataItemValue,u=c.converDataValue,d={cartesian2d:function(t,e,i){var n=i[Ce]("xAxis",e.get("xAxisIndex")),a=i[Ce]("yAxis",e.get("yAxisIndex")),o=n.get("type"),l=a.get("type"),c=l===A,h=o===A,u=[{name:"x",type:h?xe:"float",stackable:r(o)},{name:"y",type:c?xe:"float",stackable:r(l)}];return s(u,t,["x","y","z"]),{dimensions:u,categoryAxisModel:h?n:c?a:null}},polar:function(t,e,i){var n=e.get("polarIndex")||0,a=function(t){return t.get("polarIndex")===n},o=i[Oe]({mainType:"angleAxis",filter:a})[0],l=i[Oe]({mainType:"radiusAxis",filter:a})[0],c=l.get("type")===A,h=o.get("type")===A,u=[{name:"radius",type:c?xe:"float",stackable:r(l.get("type"))},{name:"angle",type:h?xe:"float",stackable:r(o.get("type"))}];return s(u,t,[Ae,"angle","value"]),{dimensions:u,categoryAxisModel:h?o:c?l:null}},geo:function(t,e,i){return{dimensions:s([{name:"lng"},{name:"lat"}],t,["lng","lat","value"])}}};return n}),e("echarts/chart/line/LineSeries",[qi,"../helper/createListFromArray","../../model/Series"],function(t){var e=t("../helper/createListFromArray"),i=t("../../model/Series");return i[Di]({type:"series.line",dependencies:["grid","polar"],getInitialData:function(t,i){return e(t.data,this,i)},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,hoverAnimation:!0,xAxisIndex:0,yAxisIndex:0,polarIndex:0,clipOverflow:!0,label:{normal:{position:"top"},emphasis:{position:"top"}},lineStyle:{normal:{width:2,type:"solid"}},symbol:"emptyCircle",symbolSize:4,showSymbol:!0,animationEasing:"linear"}})}),e("echarts/util/symbol",[qi,"./graphic",gi],function(t){var e=t("./graphic"),i=t(gi),n=e[Mt]({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var i=e.cx,n=e.cy,r=e.width/2,a=e[vi]/2;t[It](i,n-a),t[Pt](i+r,n+a),t[Pt](i-r,n+a),t[Lt]()}}),r=e[Mt]({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var i=e.cx,n=e.cy,r=e.width/2,a=e[vi]/2;t[It](i,n-a),t[Pt](i+r,n),t[Pt](i,n+a),t[Pt](i-r,n),t[Lt]()}}),a=e[Mt]({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var i=e.x,n=e.y,r=e.width/5*3,a=Math.max(r,e[vi]),o=r/2,s=o*o/(a-o),l=n-a+o+s,c=Math.asin(s/o),h=Math.cos(c)*o,u=Math.sin(c),d=Math.cos(c);t.arc(i,l,o,Math.PI-c,2*Math.PI+c);var f=.6*o,p=.7*o;t[zt](i+h-u*f,l+s+d*f,i,n-p,i,n),t[zt](i,n-p,i-h+u*f,l+s+d*f,i-h,l+s),t[Lt]()}}),o=e[Mt]({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var i=e[vi],n=e.width,r=e.x,a=e.y,o=n/3*2;t[It](r,a),t[Pt](r+o,a+i),t[Pt](r,a+i/4*3),t[Pt](r-o,a+i),t[Pt](r,a),t[Lt]()}}),s={line:e.Line,rect:e.Rect,roundRect:e.Rect,square:e.Rect,circle:e.Circle,diamond:r,pin:a,arrow:o,triangle:n},l={line:function(t,e,i,n,r){r.x1=t,r.y1=e+n/2,r.x2=t+i,r.y2=e+n/2},rect:function(t,e,i,n,r){r.x=t,r.y=e,r.width=i,r[vi]=n},roundRect:function(t,e,i,n,r){r.x=t,r.y=e,r.width=i,r[vi]=n,r.r=Math.min(i,n)/4},square:function(t,e,i,n,r){var a=Math.min(i,n);r.x=t,r.y=e,r.width=a,r[vi]=a},circle:function(t,e,i,n,r){r.cx=t+i/2,r.cy=e+n/2,r.r=Math.min(i,n)/2},diamond:function(t,e,i,n,r){r.cx=t+i/2,r.cy=e+n/2,r.width=i,r[vi]=n},pin:function(t,e,i,n,r){r.x=t+i/2,r.y=e+n/2,r.width=i,r[vi]=n},arrow:function(t,e,i,n,r){r.x=t+i/2,r.y=e+n/2,r.width=i,r[vi]=n},triangle:function(t,e,i,n,r){r.cx=t+i/2,r.cy=e+n/2,r.width=i,r[vi]=n}},c={};for(var h in s)c[h]=new s[h];var u=e[Mt]({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},beforeBrush:function(){var t=this.style,e=this.shape;"pin"===e.symbolType&&t[Et]===si&&(t[Et]=["50%","40%"],t[Zt]=li,t[Bt]=ci)},buildPath:function(t,e){var i=e.symbolType,n=c[i];"none"!==e.symbolType&&(n||(i="rect",n=c[i]),l[i](e.x,e.y,e.width,e[vi],n.shape),n[Dt](t,n.shape))}}),d=function(t){if("image"!==this.type){var e=this.style,i=this.shape;i&&"line"===i.symbolType?e[wi]=t:this.__isEmptyBrush?(e[wi]=t,e.fill="#fff"):(e.fill&&(e.fill=t),e[wi]&&(e[wi]=t)),this.dirty()}},f={createSymbol:function(t,n,r,a,o,s){var l=0===t[Bi]("empty");l&&(t=t[ai](5,1)[je]()+t[ai](6));var c;return c=0===t[Bi]("image://")?new e.Image({style:{image:t.slice(8),x:n,y:r,width:a,height:o}}):0===t[Bi]("path://")?e.makePath(t.slice(7),{},new i(n,r,a,o)):new u({shape:{symbolType:t,x:n,y:r,width:a,height:o}}),c.__isEmptyBrush=l,c.setColor=d,c.setColor(s),c}};return f}),e("echarts/chart/helper/Symbol",[qi,Hi,k,S,M],function(t){function e(t){return r[ki](t)||(t=[+t,+t]),t}function i(t,e){o.Group.call(this),this[w](t,e)}function n(t,e){this[he].drift(t,e)}var r=t(Hi),a=t(k),o=t(S),s=t(M),l=i[Wi];l._createSymbol=function(t,i,r){this[qt]();var s=i[H],l=i[L](r,"color"),c=a[b](t,-.5,-.5,1,1,l);c.attr({style:{strokeNoScale:!0},z2:100,scale:[0,0]}),c.drift=n;var h=e(i[L](r,x));o[pt](c,{scale:h},s),this._symbolType=t,this.add(c)},l.stopSymbolAnimation=function(t){this[Ge](0)[ne](t)},l.getScale=function(){return this[Ge](0).scale},l.highlight=function(){this[Ge](0)[Ht](Se)},l.downplay=function(){this[Ge](0)[Ht](Me)},l.setZ=function(t,e){var i=this[Ge](0);i[ot]=t,i.z=e},l.setDraggable=function(t){var e=this[Ge](0);e[ee]=t,e.cursor=t?"move":"pointer"},l[w]=function(t,i){var n=t[L](i,_)||y,r=t[H],a=e(t[L](i,x));if(n!==this._symbolType)this._createSymbol(n,t,i);else{var s=this[Ge](0);o[vt](s,{scale:a},r)}this._updateCommon(t,i,a),this._seriesModel=r};var c=[j,Me],h=[j,Se],u=["label",Me],d=["label",Se];return l._updateCommon=function(t,i,n){var a=this[Ge](0),l=t[H],f=t[me](i),p=f[ni](c),v=t[L](i,"color"),y=f[ni](h)[g]();a[de]=f[Si]("symbolRotate")*Math.PI/180||0;var _=f[Si]("symbolOffset");if(_){var b=a[He];b[0]=s[$e](_[0],n[0]),b[1]=s[$e](_[1],n[1])}a.setColor(v),r[Di](a.style,p[g](["color"]));var w=f[ni](u),M=f[ni](d),S=t[B][t[B][Vi]-1],k=l[m](i,Me)||t.get(S,i),A=a.style;w.get("show")?(o.setText(A,w,v),A.text=k):A.text="",M[Si]("show")?(o.setText(y,M,v),y.text=k):y.text="",o[_t](a,y);var C=e(t[L](i,x));if(a.off(yt).off(gt).off(Se).off(Me),f[Si]("hoverAnimation")){var T=function(){var t=C[1]/C[0];this.animateTo({scale:[Math.max(1.1*C[0],C[0]+3),Math.max(1.1*C[1],C[1]+3*t)]},400,"elasticOut")},D=function(){this.animateTo({scale:C},400,"elasticOut")};a.on(yt,T).on(gt,D).on(Se,T).on(Me,D)}},l.fadeOut=function(t){var e=this[Ge](0);e.style.text="",o[vt](e,{scale:[0,0]},this._seriesModel,t)},r[Ti](i,o.Group),i}),e("echarts/chart/helper/SymbolDraw",[qi,S,"./Symbol"],function(t){function e(t){this.group=new n.Group,this._symbolCtor=t||r}function i(t,e,i){var n=t[P](e);return n&&!isNaN(n[0])&&!isNaN(n[1])&&!(i&&i(e))&&"none"!==t[L](e,_)}var n=t(S),r=t("./Symbol"),a=e[Wi];return a[w]=function(t,e){var r=this.group,a=t[H],o=this._data,s=this._symbolCtor;t.diff(o).add(function(n){var a=t[P](n);if(i(t,n,e)){var o=new s(t,n);o.attr(He,a),t[D](n,o),r.add(o)}})[at](function(l,c){var h=o[Ft](c),u=t[P](l);return i(t,l,e)?(h?(h[w](t,l),n[vt](h,{position:u},a)):(h=new s(t,l),h.attr(He,u)),r.add(h),void t[D](l,h)):void r[Qt](h)})[Qt](function(t){var e=o[Ft](t);e&&e.fadeOut(function(){r[Qt](e)})})[v](),this._data=t},a[jt]=function(){var t=this._data;t&&t[Nt](function(e,i){e.attr(He,t[P](i))})},a[Qt]=function(t){var e=this.group,i=this._data;i&&(t?i[Nt](function(t){t.fadeOut(function(){e[Qt](t)})}):e[qt]())},e}),e("zrender/core/arrayDiff",[qi],function(t){function e(t,e){return t===e}function i(t,e,i){var n={cmd:t,idx:e};return"="===t&&(n.idx1=i),n}function n(t,e,n,r){t.push(i(e,n,r))}function r(t,e,i,n,r,a,o,l){var c,h,u,d=i>n,f=r>a,p=s(n-i),v=s(a-r);for(h=0;p>=h;h++)for(u=0;v>=u;u++)if(0===h)l[u]=u;else if(0===u)c=l[u],l[u]=h;else{var m=t[d?i-h:h-1+i],g=e[f?r-u:u-1+r],y=c+(o(m,g)?0:2),_=l[u]+1,x=l[u-1]+1;c=l[u],l[u]=_>y?y:_,xf;f++)c(g,e[f+s])&&!y?(y=!0,n(p,"=",i,f+s)):n(p,"+",f+s);y||n(p,"-",i)}else if(1===m){var _=e[s],y=!1;for(d=0;v>d;d++)c(_,t[d+i])&&!y?(y=!0,n(p,"=",d+i,s)):n(p,"-",d+i);y||n(p,"+",s)}else{var x=(v/2|0)+i;r(t,e,i,x,s,l,c,h),r(t,e,o,x+1,l,s,c,u);var b,w=1/0,M=0;for(f=0;m>=f;f++)b=h[f]+u[m-f],w>b&&(w=b,M=f);M+=s,p=a(t,e,i,x,s,M,c,h,u);var S=a(t,e,x,o,M,l,c,h,u);for(d=0;dd;d++)n(p,"-",d+i);else for(f=0;m>f;f++)n(p,"+",f+s);return p}function o(t,i,r){r=r||e;var o,s,l=t[Vi],c=i[Vi],h=Math.min(l,c),u=[];for(o=0;h>o&&r(t[o],i[o]);o++)n(u,"=",o,o);for(s=0;h>s&&r(t[l-s-1],i[c-s-1]);s++);if(l-s>=o||c-s>=o){var d=a(t,i,o,l-s,o,c-s,r,[],[]);for(o=0;oo;o++)n(u,"=",l-s+o,c-s+o)}return u}var s=Math.abs;return o}),e("echarts/chart/line/lineAnimationDiff",[qi,"zrender/core/arrayDiff"],function(t){function e(t){return t>=0?1:-1}function i(t,i,n){for(var r,a=t[p](),o=t[f](a),s=a.onZero?0:o.scale[d]()[0],l=o.dim,c="x"===l||l===Ae?1:0,h=i.stackedOn,v=i.get(l,n);h&&e(h.get(l,n))===e(v);){r=h;break}var m=[];return m[c]=i.get(a.dim,n),m[1-c]=r?r.get(l,n,!0):s,t[u](m)}var n=t("zrender/core/arrayDiff");return function(t,e,r,a,o,s){for(var l=e[O](e.getId),c=t[O](t.getId),h=[],d=[],f=[],p=[],v=[],m=[],g=[],y=n(c,l),_=s[B],x=0;xx;x++){var b=e[_];if(_>=n||0>_||isNaN(b[0])||isNaN(b[1]))break;if(_===i)t[v>0?It:Pt](b[0],b[1]),h(d,b);else if(y>0){var w=_-v,M=_+v;v>0?(w=o(w,i),M=a(M,n-1)):(M=o(M,0),w=a(w,i));var S=e[w],k=e[M];(isNaN(k[0])||isNaN(k[1]))&&(k=b),r.sub(u,k,S),c(f,b,u,-y/2),s(d,d,g),l(d,d,m),s(f,f,g),l(f,f,m),t[zt](d[0],d[1],f[0],f[1],b[0],b[1]),c(d,b,u,y/2)}else t[Pt](b[0],b[1]);_+=v}return x}function i(t){for(var e=[1/0,1/0],i=[-(1/0),-(1/0)],n=0;ni[0]&&(i[0]=r[0]),r[1]>i[1]&&(i[1]=r[1])}return{min:e,max:i}}var n=t("zrender/graphic/Path"),r=t(xi),a=Math.min,o=Math.max,s=r.min,l=r.max,c=r.scaleAndAdd,h=r.copy,u=[],d=[],f=[];return{Polyline:n[Di]({type:"ec-polyline",shape:{points:[],smooth:0},style:{fill:null,stroke:"#000",smooth:0},buildPath:function(t,n){for(var r=n[At],a=0,o=r[Vi],s=i(r);o>a;)a+=e(t,r,a,o,o,1,s.min,s.max,n.smooth)+1}}),Polygon:n[Di]({type:"ec-polygon",shape:{points:[],stackedOnPoints:[],smooth:0,stackedOnSmooth:0},buildPath:function(t,n){for(var r=n[At],a=n.stackedOnPoints,o=0,s=r[Vi],l=i(r),c=i(a);s>o;){var h=e(t,r,o,s,s,1,l.min,l.max,n.smooth);e(t,a,o+h-1,s,h,-1,c.min,c.max,n.stackedOnSmooth),o+=h+1,t[Lt]()}}})}}),e("echarts/chart/line/LineView",[qi,Hi,"../helper/SymbolDraw","../helper/Symbol","./lineAnimationDiff",S,"./poly","../../view/Chart"],function(t){function e(t,e){if(t[Vi]===e[Vi]){for(var i=0;ie[0]?1:-1;e[0]+=n*i,e[1]-=n*i}return e}function r(t){return t>=0?1:-1}function a(t,e){var i=t[p](),n=t[f](i),a=i.onZero?0:n.scale[d]()[0],o=n.dim,s="x"===o||o===Ae?1:0;return e[O]([o],function(n,l){for(var c,h=e.stackedOn;h&&r(h.get(o,l))===r(n);){c=h;break}var d=[];return d[s]=e.get(i.dim,l),d[1-s]=c?c.get(o,l,!0):a,t[u](d)},!0)}function o(t,e){return null!=e[Gt]?e[Gt]:null!=e.name?t[Vt](e.name):void 0}function s(t,e,i){var r=n(t[h]("x")),a=n(t[h]("y")),o=t[p]()[c](),s=r[0],l=a[0],u=r[1]-s,d=a[1]-l;i.get("clipOverflow")||(o?(l-=d,d*=3):(s-=u,u*=3));var f=new b.Rect({shape:{x:s,y:l,width:u,height:d}});return e&&(f.shape[o?"width":vi]=0,b[pt](f,{shape:{width:u,height:d}},i)),f}function v(t,e,i){var n=t.getAngleAxis(),r=t.getRadiusAxis(),a=r[d](),o=n[d](),s=Math.PI/180,l=new b[kt]({shape:{cx:t.cx,cy:t.cy,r0:a[0],r:a[1],startAngle:-o[0]*s,endAngle:-o[1]*s,clockwise:n.inverse}});return e&&(l.shape.endAngle=-o[0]*s,b[pt](l,{shape:{endAngle:-o[1]*s}},i)),l}function m(t,e,i){return"polar"===t.type?v(t,e,i):s(t,e,i)}var g=t(Hi),y=t("../helper/SymbolDraw"),_=t("../helper/Symbol"),x=t("./lineAnimationDiff"),b=t(S),M=t("./poly"),k=t("../../view/Chart");return k[Di]({type:"line",init:function(){var t=new b.Group,e=new y;this.group.add(e.group),this.group.add(t),this._symbolDraw=e,this._lineGroup=t},render:function(t,n,r){var o=t[C],s=this.group,c=t[be](),h=t[ni]("lineStyle.normal"),u=t[ni]("areaStyle.normal"),d=c[O](c[P],!0),f="polar"===o.type,p=this._coordSys,v=this._symbolDraw,y=this._polyline,_=this._polygon,x=this._lineGroup,b=t.get(re),M=!u.isEmpty(),S=a(o,c),k=t.get("showSymbol"),A=k&&!f&&!t.get("showAllSymbol")&&this._getSymbolIgnoreFunc(c,o),T=this._data;T&&T[Nt](function(t,e){t.__temp&&(s[Qt](t),T[D](e,null))}),k||v[Qt](),y&&p.type===o.type?(b&&x.setClipPath(m(o,!1,t)),k&&v[w](c,A),c[Nt](function(t){t[ne](!0)}),e(this._stackedOnPoints,S)&&e(this._points,d)||(b?this._updateAnimation(c,S,o,r):(y[Ct]({points:d}),_&&_[Ct]({points:d,stackedOnPoints:S}))),s.add(x)):(k&&v[w](c,A),y=this._newPolyline(s,d,o,b),M&&(_=this._newPolygon(s,d,S,o,b)),x.setClipPath(m(o,!0,t))),y[bt](g[oi](h[l](),{stroke:c[I]("color"),lineJoin:"bevel"}));var L=t.get("smooth");if(L=i(t.get("smooth")),y.shape.smooth=L,_){var z=_.shape,R=c.stackedOn,B=0;if(_.style[bi]=.7,_[bt](g[oi](u.getAreaStyle(),{fill:c[I]("color"),lineJoin:"bevel"})),z.smooth=L,R){var Z=R[H];B=i(Z.get("smooth"))}z.stackedOnSmooth=B}this._data=c,this._coordSys=o,this._stackedOnPoints=S,this._points=d},highlight:function(t,e,i,n){var r=t[be](),a=o(r,n);if(null!=a&&a>=0){var s=r[Ft](a);if(!s){var l=r[P](a);s=new _(r,a,i),s[He]=l,s.setZ(t.get(ot),t.get("z")),s[te]=isNaN(l[0])||isNaN(l[1]),s.__temp=!0,r[D](a,s),s.stopSymbolAnimation(!0),this.group.add(s)}s.highlight()}else k[Wi].highlight.call(this,t,e,i,n)},downplay:function(t,e,i,n){var r=t[be](),a=o(r,n);if(null!=a&&a>=0){var s=r[Ft](a);s&&(s.__temp?(r[D](a,null),this.group[Qt](s)):s.downplay())}else k[Wi].downplay.call(this,t,e,i,n)},_newPolyline:function(t,e){var i=this._polyline;return i&&t[Qt](i),i=new M[St]({shape:{points:e},silent:!0,z2:10}),this._lineGroup.add(i),this._polyline=i,i},_newPolygon:function(t,e,i){var n=this._polygon;return n&&t[Qt](n),n=new M.Polygon({shape:{points:e,stackedOnPoints:i},silent:!0}),this._lineGroup.add(n),this._polygon=n,n},_getSymbolIgnoreFunc:function(t,e){var i=e.getAxesByScale(xe)[0];return i&&i.isLabelIgnored?g.bind(i.isLabelIgnored,i):void 0},_updateAnimation:function(t,e,i,n){var r=this._polyline,a=this._polygon,o=t[H],s=x(this._data,t,this._stackedOnPoints,e,this._coordSys,i);r.shape[At]=s.current,b[vt](r,{shape:{points:s.next}},o),a&&(a[Ct]({points:s.current,stackedOnPoints:s.stackedOnCurrent}),b[vt](a,{shape:{points:s.next,stackedOnPoints:s.stackedOnNext}},o));for(var l=[],c=s.status,h=0;h=e[0]&&t<=e[1]},n.normalize=function(t){var e=this._extent;return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])},n.scale=function(t){var e=this._extent;return t*(e[1]-e[0])+e[0]},n.unionExtent=function(t){var e=this._extent;t[0]e[1]&&(e[1]=t[1])},n[d]=function(){return this._extent.slice()},n.setExtent=function(t,e){var i=this._extent;isNaN(t)||(i[0]=t),isNaN(e)||(i[1]=e)},n.getTicksLabels=function(){for(var t=[],e=this.getTicks(),i=0;ie[1]&&(e[1]=t[1]),s[Wi].setExtent.call(this,e[0],e[1])},getInterval:function(){return this._interval||this.niceTicks(),this._interval},setInterval:function(t){this._interval=t,this._niceExtent=this._extent.slice()},getTicks:function(){this._interval||this.niceTicks();var t=this._interval,i=this._extent,n=[],r=1e4;if(t){var a=this._niceExtent;i[0]r)return[];i[1]>a[1]&&n.push(i[1])}return n},getTicksLabels:function(){for(var t=[],e=this.getTicks(),i=0;i=n)){var o=Math.pow(10,Math.floor(Math.log(n/t)/Math.LN10)),s=t/n*o;.15>=s?o*=10:.3>=s?o*=5:.5>=s?o*=3:.75>=s&&(o*=2);var l=[e.round(a(i[0]/o)*o),e.round(r(i[1]/o)*o)];this._interval=o,this._niceExtent=l}},niceExtent:function(t,i,n){var o=this._extent;if(o[0]===o[1]){var s=o[0]/2||1;o[0]-=s,o[1]+=s}if(o[1]===-(1/0)&&o[0]===1/0)return o[1]=1,o[0]=-1,this._niceExtent=[-1,1],void(this._interval=.5);this.niceTicks(t,i,n);var l=this._interval;i||(o[0]=e.round(r(o[0]/l)*l)),n||(o[1]=e.round(a(o[1]/l)*l))}});return s[pi]=function(){return new s},s}),e("echarts/scale/Time",[qi,Hi,"../util/number","./Interval"],function(t){var e=t(Hi),i=t("../util/number"),n=t("./Interval"),r=n[Wi],a=Math.ceil,o=Math.floor,s=function(t,e,i,n){for(;n>i;){var r=i+n>>>1;t[r][2]t?"0"+t:t},c=function(t,e){("week"===t||"month"===t||"quarter"===t||"half-year"===t||"year"===t)&&(t="MM-dd\nyyyy");var n=i.parseDate(e),r=n.getFullYear(),a=n.getMonth()+1,o=n.getDate(),s=n.getHours(),c=n.getMinutes(),h=n.getSeconds();return t=t[Qe]("MM",l(a))[je]()[Qe]("yyyy",r)[Qe]("yy",r%100)[Qe]("dd",l(o))[Qe]("d",o)[Qe]("hh",l(s))[Qe]("h",s)[Qe]("mm",l(c))[Qe]("m",c)[Qe]("ss",l(h))[Qe]("s",h)},h=n[Di]({type:"time",getLabel:function(t){var e=this._stepLvl,i=new Date(t);return c(e[0],i)},niceTicks:function(t){t=t||10;var e=this._extent,i=e[1]-e[0],n=i/t,r=u[Vi],l=s(u,n,0,r),c=u[Math.min(l,r-1)],h=c[2],d=[a(e[0]/h)*h,o(e[1]/h)*h];this._stepLvl=c,this._interval=h,this._niceExtent=d}});e.each([Rt,"normalize"],function(t){h[Wi][t]=function(e){return e=+i.parseDate(e),r[t].call(this,e)}});var u=[["hh:mm:ss",1,1e3],["hh:mm:ss",5,5e3],["hh:mm:ss",10,1e4],["hh:mm:ss",15,15e3],["hh:mm:ss",30,3e4],["hh:mm\nMM-dd",1,6e4],["hh:mm\nMM-dd",5,3e5],["hh:mm\nMM-dd",10,6e5],["hh:mm\nMM-dd",15,9e5],["hh:mm\nMM-dd",30,18e5],["hh:mm\nMM-dd",1,36e5],["hh:mm\nMM-dd",2,72e5],["hh:mm\nMM-dd",6,216e5],["hh:mm\nMM-dd",12,432e5],["MM-dd\nyyyy",1,864e5],["week",7,6048e5],["month",1,26784e5],["quarter",3,8208e6],["half-year",6,16416e6],["year",1,32832e6]];return h[pi]=function(){return new h},h}),e("echarts/scale/Log",[qi,Hi,"./Scale","../util/number","./Interval"],function(t){var e=t(Hi),i=t("./Scale"),n=t("../util/number"),r=t("./Interval"),a=i[Wi],s=r[Wi],l=Math.floor,c=Math.ceil,h=Math.pow,u=10,f=Math.log,p=i[Di]({type:"log",getTicks:function(){return e.map(s.getTicks.call(this),function(t){return n.round(h(u,t))})},getLabel:s[o],scale:function(t){return t=a.scale.call(this,t),h(u,t)},setExtent:function(t,e){t=f(t)/f(u),e=f(e)/f(u),s.setExtent.call(this,t,e)},getExtent:function(){var t=a[d].call(this);return t[0]=h(u,t[0]),t[1]=h(u,t[1]),t},unionExtent:function(t){t[0]=f(t[0])/f(u),t[1]=f(t[1])/f(u),a.unionExtent.call(this,t)},niceTicks:function(t){t=t||10;var e=this._extent,i=e[1]-e[0];if(!(i===1/0||0>=i)){var r=h(10,l(f(i/t)/Math.LN10)),a=t/i*r;.5>=a&&(r*=10);var o=[n.round(c(e[0]/r)*r),n.round(l(e[1]/r)*r)];this._interval=r,this._niceExtent=o}},niceExtent:s.niceExtent});return e.each([Rt,"normalize"],function(t){p[Wi][t]=function(e){return e=f(e)/f(u),a[t].call(this,e)}}),p[pi]=function(){return new p},p}),e("echarts/coord/axisHelper",[qi,"../scale/Ordinal","../scale/Interval","../scale/Time","../scale/Log","../scale/Scale","../util/number",Hi,fi],function(t){var e=t("../scale/Ordinal"),i=t("../scale/Interval");t("../scale/Time"),t("../scale/Log");var n=t("../scale/Scale"),r=t("../util/number"),a=t(Hi),s=t(fi),l={};return l.niceScaleExtent=function(t,e){var i=t.scale;if(i.type!==xe){var n=e.get("min"),o=e.get("max"),s=e.get("boundaryGap");a[ki](s)||(s=[s||0,s||0]),s[0]=r[$e](s[0],1),s[1]=r[$e](s[1],1);var l=i[d](),c=l[1]-l[0],h=!0,u=!0;null==n&&(n=l[0]-s[0]*c,h=!1),null==o&&(o=l[1]+s[1]*c,u=!1),"dataMin"===n&&(n=l[0]),"dataMax"===o&&(o=l[1]),i.setExtent(n,o),i.niceExtent(e.get("splitNumber"),h,u);var f=e.get("interval");null!=f&&i.setInterval&&i.setInterval(f)}},l.createScaleByModel=function(t,r){if(r=r||t.get("type"))switch(r){case A:return new e(t.getCategories(),[1/0,-(1/0)]);case"value":return new i;default:return(n[Ai](r)||i)[pi](t)}},l.ifAxisCrossZero=function(t){var e=t.scale[d](),i=e[0],n=e[1],r=t.model.get("min"),a=t.model.get("max");return isNaN(r)||(i=Math.min(r,i)),isNaN(a)||(n=Math.max(a,n)),!(i>0&&n>0||0>i&&0>n)||l.ifAxisNeedsCrossZero(t)},l.ifAxisNeedsCrossZero=function(t){return!t.model.get("scale")},l.getAxisLabelInterval=function(t,e,i,n){for(var r,a=0,o=0,l=0;l=i&&n>=t},containData:function(t){return this[Rt](this[a](t))},getExtent:function(){var t=this._extent.slice();return t},getPixelPrecision:function(t){return i[Ue](t||this.scale[d](),this._extent)},setExtent:function(t,e){var i=this._extent;i[0]=t,i[1]=e},dataToCoord:function(t,i){t=this.scale.normalize(t);var r=this[d](),a=this.scale;return this.onBand&&a.type===xe&&e(r,a.count()),n(t,[0,1],r,i)},coordToData:function(t,i){var r=this[d]();this.onBand&&e(r,this.scale.count());var a=n(t,r,[0,1],i);return this.scale.scale(a)},getTicksCoords:function(){if(this.onBand){for(var t=this.getBands(),e=[],i=0;io;o++)e.push([a*o/i+n,a*(o+1)/i+n]);return e},getBandWidth:function(){var t=this._extent,e=this.scale[d](),i=e[1]-e[0]+(this.onBand?1:0),n=Math.abs(t[1]-t[0]);return Math.abs(n)/i}},o}),e("echarts/coord/cartesian/axisLabelInterval",[qi,Hi,"../axisHelper"],function(t){var e=t(Hi),i=t("../axisHelper");return function(t){var n=t.model,r=n[ni]("axisLabel"),o=r.get("interval");return t.type!==A||"auto"!==o?"auto"===o?0:o:i.getAxisLabelInterval(e.map(t.scale.getTicks(),t[a],t),n.getFormattedLabels(),r[ni](ii)[ti](),t[c]())}}),e("echarts/coord/cartesian/Axis2D",[qi,Hi,"../Axis","./axisLabelInterval"],function(t){var e=t(Hi),i=t("../Axis"),n=t("./axisLabelInterval"),r=function(t,e,n,r,a){i.call(this,t,e,n),this.type=r||"value",this[He]=a||hi};return r[Wi]={constructor:r,index:0,onZero:!1,model:null,isHorizontal:function(){var t=this[He];return"top"===t||t===hi},getGlobalExtent:function(){var t=this[d]();return t[0]=this.toGlobalCoord(t[0]),t[1]=this.toGlobalCoord(t[1]),t},getLabelInterval:function(){var t=this._labelInterval;return t||(t=this._labelInterval=n(this)),t},isLabelIgnored:function(t){if(this.type===A){var e=this.getLabelInterval();return typeof e===Pi&&!e(t,this.scale[o](t))||t%(e+1)}},toLocalCoord:null,toGlobalCoord:null},e[Ti](r,i),r}),e("echarts/coord/axisDefault",[qi,Hi],function(t){var e=t(Hi),i={show:!0,zlevel:0,z:0,inverse:!1,name:"",nameLocation:"end",nameTextStyle:{},nameGap:15,axisLine:{show:!0,onZero:!0,lineStyle:{color:"#333",width:1,type:"solid"}},axisTick:{show:!0,inside:!1,length:5,lineStyle:{color:"#333",width:1}},axisLabel:{show:!0,inside:!1,rotate:0,margin:8,textStyle:{color:"#333",fontSize:12}},splitLine:{show:!0,lineStyle:{color:["#ccc"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.3)","rgba(200,200,200,0.3)"]}}},n=e.merge({boundaryGap:!0,axisTick:{interval:"auto"},axisLabel:{interval:"auto"}},i),r=e[oi]({boundaryGap:[0,0],splitNumber:5},i),a=e[oi]({scale:!0,min:"dataMin",max:"dataMax"},r),o=e[oi]({},r);return o.scale=!0,{categoryAxis:n,valueAxis:r,timeAxis:a,logAxis:o}}),e("echarts/coord/axisModelCreator",[qi,"./axisDefault",Hi,"../model/Component"],function(t){var e=t("./axisDefault"),i=t(Hi),n=t("../model/Component"),r=["value",A,"time","log"];return function(t,a,o,s){i.each(r,function(n){a[Di]({type:t+"Axis."+n,mergeDefaultAndTheme:function(e,r){var a=r.getTheme();i.merge(e,a.get(n+"Axis")),i.merge(e,this.getDefaultOption()),e.type=o(t,e)},defaultOption:i.mergeAll([{},e[n+"Axis"],s],!0)})}),n.registerSubTypeDefaulter(t+"Axis",i.curry(o,t))}}),e("echarts/coord/axisModelCommonMixin",[qi,Hi,"./axisHelper"],function(t){function e(t){return r[Ee](t)&&null!=t.value?t.value:t}function i(){return this.get("type")===A&&r.map(this.get("data"),e)}function n(){return a.getFormattedLabels(this.axis,this.get("axisLabel.formatter"))}var r=t(Hi),a=t("./axisHelper");return{getFormattedLabels:n,getCategories:i}}),e("echarts/coord/cartesian/AxisModel",[qi,"../../model/Component",Hi,"../axisModelCreator","../axisModelCommonMixin"],function(t){function e(t,e){return e.type||(e.data?A:"value")}var i=t("../../model/Component"),n=t(Hi),r=t("../axisModelCreator"),a=i[Di]({type:"cartesian2dAxis",axis:null,setNeedsCrossZero:function(t){this[Ke].scale=!t},setMin:function(t){this[Ke].min=t},setMax:function(t){this[Ke].max=t}});n.merge(a[Wi],t("../axisModelCommonMixin"));var o={gridIndex:0};return r("x",a,e,o),r("y",a,e,o),a}),e("echarts/coord/cartesian/GridModel",[qi,"./AxisModel","../../model/Component"],function(t){t("./AxisModel");var e=t("../../model/Component");return e[Di]({type:"grid",dependencies:["xAxis","yAxis"],layoutMode:"box",coordinateSystem:null,defaultOption:{show:!1,zlevel:0,z:0,left:"10%",top:60,right:"10%",bottom:60,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"}})}),e("echarts/coord/cartesian/Grid",[qi,"exports","module","../../util/layout","../../coord/axisHelper",Hi,"./Cartesian2D","./Axis2D","./GridModel","../../CoordinateSystem"],function(t,e){function i(t,e,i){return i[Ce]("grid",t.get("gridIndex"))===e}function n(t){for(var e,i=t.model,n=i.getFormattedLabels(),r=0;r0?1:-1,n=t[vi]>0?1:-1;t.x+=i*e/2,t.y+=n*e/2,t.width-=i*e,t[vi]-=n*e}var i=t(Hi),r=t(S);return i[Di](t("../../model/Model")[Wi],t("./barItemStyle")),t(n).extendChartView({type:"bar",render:function(t,e,i){var n=t.get(C);return"cartesian2d"===n&&this._renderOnCartesian(t,e,i),this.group},_renderOnCartesian:function(t,n,a){function o(n,a){var o=l[P](n),s=l[me](n).get(g)||0;e(o,s);var c=new r.Rect({shape:i[Di]({},o)});if(m){var h=c.shape,u=f?vi:"width",d={};h[u]=0,d[u]=o[u],r[a?vt:pt](c,{shape:d},t)}return c}var s=this.group,l=t[be](),h=this._data,u=t[C],d=u[p](),f=d[c](),m=t.get(re),g=[j,Me,"barBorderWidth"];l.diff(h).add(function(t){if(l.hasValue(t)){var e=o(t);l[D](t,e),s.add(e)}})[at](function(i,n){var a=h[Ft](n);if(!l.hasValue(i))return void s[Qt](a);a||(a=o(i,!0));var c=l[P](i),u=l[me](i).get(g)||0;e(c,u),r[vt](a,{shape:c},t),l[D](i,a),s.add(a)})[Qt](function(e){var i=h[Ft](e);i&&(i.style.text="",r[vt](i,{shape:{width:0}},t,function(){s[Qt](i)}))})[v](),this._updateStyle(t,l,f),this._data=l},_updateStyle:function(t,e,n){function a(t,e,i,n,a){r.setText(t,e,i),t.text=n,"outside"===t[Et]&&(t[Et]=a)}e[Nt](function(o,s){var l=e[me](s),c=l[ni]("label.normal"),h=e[L](s,"color"),u=e[P](s),d=l[ni]("itemStyle.emphasis")[g]();o[bt](i[oi]({fill:h},l[ni]("itemStyle.normal").getBarItemStyle()));var f=n?u[vi]>0?hi:"top":u.width>0?"left":"right",c=l[ni]("label.normal"),p=l[ni]("label.emphasis"),v=o.style;c.get("show")?a(v,c,h,t[m](s,Me)||t[_e](s),f):v.text="",p.get("show")?a(d,p,h,t[m](s,Se)||t[_e](s),f):d.text="",r[_t](o,d)})},remove:function(t,e){var i=this.group;t.get(re)?this._data&&this._data[Nt](function(e){e.style.text="",r[vt](e,{shape:{width:0}},t,function(){i[Qt](e)})}):i[qt]()}})}),e("echarts/layout/barGrid",[qi,Hi,"../util/number"],function(t){function e(t){return t.get("stack")||"__ec_stack_"+t[we]}function i(t,i){var n={};r.each(t,function(t,i){var r=t[C],a=r[p](),o=n[a.index]||{remainedWidth:a.getBandWidth(),autoWidthCount:0,categoryGap:"20%",gap:"30%",axis:a,stacks:{}},s=o.stacks;n[a.index]=o;var l=e(t);s[l]||o.autoWidthCount++,s[l]=s[l]||{width:0,maxWidth:0};var c=t.get("barWidth"),h=t.get("barMaxWidth"),u=t.get("barGap"),d=t.get("barCategoryGap");c&&!s[l].width&&(c=Math.min(o.remainedWidth,c),s[l].width=c,o.remainedWidth-=c),h&&(s[l].maxWidth=h),null!=u&&(o.gap=u),null!=d&&(o.categoryGap=d)});var a={};return r.each(n,function(t,e){a[e]={};var i=t.stacks,n=t.axis,o=n.getBandWidth(),l=s(t.categoryGap,o),c=s(t.gap,1),h=t.remainedWidth,u=t.autoWidthCount,d=(h-l)/(u+(u-1)*c);d=Math.max(d,0),r.each(i,function(t,e){var i=t.maxWidth;!t.width&&i&&d>i&&(i=Math.min(i,h),h-=i,t.width=i,u--)}),d=(h-l)/(u+(u-1)*c),d=Math.max(d,0);var f,p=0;r.each(i,function(t,e){t.width||(t.width=d),f=t,p+=t.width*(1+c)}),f&&(p-=f.width*c);var v=-p/2;r.each(i,function(t,i){a[e][i]=a[e][i]||{offset:v,width:t.width},v+=t.width*(1+c)})}),a}function n(t,n,o){var s=i(r[Gi](n.getSeriesByType(t),function(t){return!n.isSeriesFiltered(t)&&t[C]&&"cartesian2d"===t[C].type})),l={};n[X](t,function(t){var i=t[be](),n=t[C],r=n[p](),o=e(t),h=s[r.index][o],u=h.offset,d=h.width,v=n[f](r),m=t.get("barMinHeight")||0,g=r.onZero?v.toGlobalCoord(v[a](0)):v.getGlobalExtent()[0],y=n.dataToPoints(i,!0);l[o]=l[o]||[],i.each(v.dim,function(t,e){if(!isNaN(t)){l[o][e]||(l[o][e]={p:g,n:g});var n,r,a,s,h=t>=0?"p":"n",f=y[e],p=l[o][e][h];v[c]()?(n=p,r=f[1]+u,a=f[0]-p,s=d,Math.abs(a)a?-1:1)*m),l[o][e][h]+=a):(n=f[0]+u,r=p,a=d,s=f[1]-p,Math.abs(s)=s?-1:1)*m),l[o][e][h]+=s),i[z](e,{x:n,y:r,width:a,height:s})}},!0)},this)}var r=t(Hi),o=t("../util/number"),s=o[$e];return n}),e("echarts/chart/bar",[qi,Hi,"../coord/cartesian/Grid","./bar/BarSeries","./bar/BarView","../layout/barGrid",s],function(t){var e=t(Hi);t("../coord/cartesian/Grid"),t("./bar/BarSeries"),t("./bar/BarView");var i=t("../layout/barGrid"),n=t(s);n[V](e.curry(i,"bar")),n[N]("chart",function(t){t[X]("bar",function(t){var e=t[be]();e[Y]("legendSymbol","roundRect")})})}),e("echarts/chart/helper/dataSelectableMixin",[qi,Hi],function(t){var e=t(Hi);return{updateSelectedMap:function(){var t=this[Ke];this._dataOptMap=e.reduce(t.data,function(t,e){return t[e.name]=e,t},{})},select:function(t){var i=this._dataOptMap,n=i[t],r=this.get("selectedMode");"single"===r&&e.each(i,function(t){t.selected=!1}),n&&(n.selected=!0)},unSelect:function(t){var e=this._dataOptMap[t];e&&(e.selected=!1)},toggleSelected:function(t){var e=this._dataOptMap[t];return null!=e?(this[e.selected?"unSelect":"select"](t),e.selected):void 0},isSelected:function(t){var e=this._dataOptMap[t];return e&&e.selected}}}),e("echarts/chart/pie/PieSeries",[qi,"../../data/List",Hi,T,"../../data/helper/completeDimensions","../helper/dataSelectableMixin",n],function(t){var e=t("../../data/List"),i=t(Hi),r=t(T),a=t("../../data/helper/completeDimensions"),o=t("../helper/dataSelectableMixin"),s=t(n).extendSeriesModel({type:"series.pie",init:function(t){this.$superApply("init",arguments),this.legendDataProvider=function(){return this._dataBeforeProcessed},this.updateSelectedMap(),this._defaultLabelLine(t)},mergeOption:function(t){this.$superCall(Ze,t),this.updateSelectedMap()},getInitialData:function(t,i){var n=a(["value"],t.data),r=new e(n,this);return r.initData(t.data),r},getDataParams:function(t){var e=this._data,i=this.$superCall(ve,t);return i.percent=+(e.get("value",t)/e.getSum("value")*100)[Xe](2),i.$vars.push("percent"),i},_defaultLabelLine:function(t){r.defaultEmphasis(t.labelLine,["show"]);var e=t.labelLine[Me],i=t.labelLine[Se];e.show=e.show&&t.label[Me].show,i.show=i.show&&t.label[Se].show},defaultOption:{zlevel:0,z:2,legendHoverLink:!0,hoverAnimation:!0,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,selectedOffset:10,avoidLabelOverlap:!0,label:{normal:{rotate:!1,show:!0,position:"outer"},emphasis:{}},labelLine:{normal:{show:!0,length:20,length2:5,smooth:!1,lineStyle:{width:1,type:"solid"}}},itemStyle:{normal:{borderColor:"rgba(0,0,0,0)",borderWidth:1},emphasis:{borderColor:"rgba(0,0,0,0)",borderWidth:1}},animationEasing:"cubicOut",data:[]}});return i.mixin(s,o),s}),e("echarts/chart/pie/PieView",[qi,S,Hi,"../../view/Chart"],function(t){function e(t,e,n,r){var a=e[be](),o=this[Gt],s=a[ge](o),l=e.get("selectedOffset");r[De]({type:"pieToggleSelect",from:t,name:s,seriesId:e.id}),a.each(function(t){i(a[Ft](t),a[P](t),e.isSelected(a[ge](t)),l,n)})}function i(t,e,i,n,r){var a=(e.startAngle+e.endAngle)/2,o=Math.cos(a),s=Math.sin(a),l=i?n:0,c=[o*l,s*l];r?t[ie]().when(200,{position:c}).start("bounceOut"):t.attr(He,c)}function n(t,e){function i(){o[te]=o.hoverIgnore,s[te]=s.hoverIgnore}function n(){o[te]=o.normalIgnore,s[te]=s.normalIgnore}a.Group.call(this);var r=new a[kt]({z2:2}),o=new a[St],s=new a.Text;this.add(r),this.add(o),this.add(s),this[w](t,e,!0),this.on(Se,i).on(Me,n).on(yt,i).on(gt,n)}function r(t,e,i,n){var r=n[ni](ii),a=n.get(He),o=a===si||"inner"===a;return{fill:r[mt]()||(o?"#fff":t[L](e,"color")),textFont:r[ti](),text:t[H][m](e,i)||t[ge](e)}}var a=t(S),o=t(Hi),s=n[Wi];s[w]=function(t,e,n){function r(){l[ne](!0),l.animateTo({shape:{r:u.r+10}},300,"elasticOut")}function s(){l[ne](!0),l.animateTo({shape:{r:u.r}},300,"elasticOut")}var l=this[Ge](0),c=t[H],h=t[me](e),u=t[P](e),d=o[Di]({},u);d.label=null,n?(l[Ct](d),l.shape.endAngle=u.startAngle,a[vt](l,{shape:{endAngle:u.endAngle}},c)):a[vt](l,{shape:d},c);var f=h[ni](j),p=t[L](e,"color");l[bt](o[oi]({fill:p},f[ni](Me)[g]())),l[xt]=f[ni](Se)[g](),i(this,t[P](e),h.get("selected"),c.get("selectedOffset"),c.get(re)),l.off(yt).off(gt).off(Se).off(Me),h.get("hoverAnimation")&&l.on(yt,r).on(gt,s).on(Se,r).on(Me,s),this._updateLabel(t,e),a[_t](this)},s._updateLabel=function(t,e){var i=this[Ge](1),n=this[Ge](2),o=t[H],s=t[me](e),c=t[P](e),h=c.label,u=t[L](e,"color");a[vt](i,{shape:{points:h.linePoints||[[h.x,h.y],[h.x,h.y],[h.x,h.y]]}},o),a[vt](n,{style:{x:h.x,y:h.y}},o),n.attr({style:{textAlign:h[Zt],textBaseline:h[Bt],textFont:h.font},rotation:h[de],origin:[h.x,h.y],z2:10});var d=s[ni]("label.normal"),f=s[ni]("label.emphasis"),p=s[ni]("labelLine.normal"),v=s[ni]("labelLine.emphasis");n[bt](r(t,e,Me,d)),n[te]=n.normalIgnore=!d.get("show"),n.hoverIgnore=!f.get("show"),i[te]=i.normalIgnore=!p.get("show"),i.hoverIgnore=!v.get("show"),i[bt]({stroke:u}),i[bt](p[ni]("lineStyle")[l]()),n[xt]=r(t,e,Se,f),i[xt]=v[ni]("lineStyle")[l]();var m=p.get("smooth");m&&m===!0&&(m=.4),i[Ct]({smooth:m})},o[Ti](n,a.Group);var c=t("../../view/Chart")[Di]({type:"pie",init:function(){var t=new a.Group;this._sectorGroup=t},render:function(t,i,r,a){if(!a||a.from!==this.uid){var s=t[be](),l=this._data,c=this.group,h=i.get(re),u=!l,d=o.curry(e,this.uid,t,h,r),f=t.get("selectedMode");if(s.diff(l).add(function(t){var e=new n(s,t);u&&e[We](function(t){t[ne](!0)}),f&&e.on("click",d),s[D](t,e),c.add(e)})[at](function(t,e){var i=l[Ft](e);i[w](s,t),i.off("click"),f&&i.on("click",d),c.add(i),s[D](t,i)})[Qt](function(t){var e=l[Ft](t);c[Qt](e)})[v](),h&&u&&s.count()>0){var p=s[P](0),m=Math.max(r[ze](),r[Le]())/2,g=o.bind(c.removeClipPath,c);c.setClipPath(this._createClipPath(p.cx,p.cy,m,p.startAngle,p.clockwise,g,t))}this._data=s}},_createClipPath:function(t,e,i,n,r,o,s){var l=new a[kt]({shape:{cx:t,cy:e,r0:0,r:i,startAngle:n,endAngle:n,clockwise:r}});return a[pt](l,{shape:{endAngle:n+(r?1:-1)*Math.PI*2}},s,o),l}});return c}),e("echarts/action/createDataSelectAction",[qi,s,Hi],function(t){var e=t(s),i=t(Hi);return function(t,n){i.each(n,function(i){i[at]="updateView",e[F](i,function(e,n){var r={};return n[W]({mainType:"series",subType:t,query:e},function(t){t[i.method]&&t[i.method](e.name);var n=t[be]();n.each(function(e){var i=n[ge](e);r[i]=t.isSelected(i)||!1})}),{name:e.name,selected:r}})})}}),e("echarts/visual/dataColor",[qi],function(t){return function(t,e){e[X](t,function(t){var i=t.get("color"),n=t.getRawData();if(!e.isSeriesFiltered(t)){var r=t[be]();r.each(function(t){var e=r[me](t),a=r[ye](t);if(!r[L](t,"color",!0)){var o=e.get("itemStyle.normal.color")||i[a%i[Vi]];n[$](a,"color",o),r[$](t,"color",o)}})}})}}),e("echarts/chart/pie/labelLayout",[qi,fi],function(t){function e(t,e,i,n,r,a,o){function s(e,i,n,r){for(var a=e;i>a;a++)if(t[a].y+=n,a>e&&i>a+1&&t[a+1].y>t[a].y+t[a][vi])return void l(a,n/2);l(i-1,n/2)}function l(e,i){for(var n=e;n>=0&&(t[n].y-=i,!(n>0&&t[n].y>t[n-1].y+t[n-1][vi]));n--);}t.sort(function(t,e){return t.y-e.y});for(var c,h=0,u=t[Vi],d=[],f=[],p=0;u>p;p++)c=t[p].y-h,0>c&&s(p,u,-c,r),h=t[p].y+t[p][vi];0>o-h&&l(u-1,h-o);for(var p=0;u>p;p++)t[p].y>=i?f.push(t[p]):d.push(t[p])}function i(t,i,n,r,a,o){for(var s=[],l=[],c=0;cw?-1:1)*x,L=T;r=D+(0>w?-5:5),a=L,u=[[k,A],[C,T],[D,L]]}d=S?li:w>0?"left":"right"}var z=ci,I=v[ni](ii)[ti](),O=v.get(le)?0>w?-b+Math.PI:-b:0,R=t[m](i,Me)||l[ge](i),B=n[ei](R,I,d,z);h=!!O,f.label={x:r,y:a,height:B[vi],length:_,length2:x,linePoints:u,textAlign:d,textBaseline:z,font:I,rotation:O},c.push(f.label)}),!h&&t.get("avoidLabelOverlap")&&i(c,o,s,e,r,a)}}),e("echarts/chart/pie/pieLayout",[qi,M,"./labelLayout",Hi],function(t){var e=t(M),i=e[$e],n=t("./labelLayout"),r=t(Hi),a=2*Math.PI,o=Math.PI/180;return function(t,s,l){s[X](t,function(t){var s=t.get(li),c=t.get(Ae);r[ki](c)||(c=[0,c]),r[ki](s)||(s=[s,s]);var h=l[ze](),u=l[Le](),d=Math.min(h,u),f=i(s[0],h),p=i(s[1],u),v=i(c[0],d/2),m=i(c[1],d/2),g=t[be](),y=-t.get("startAngle")*o,_=t.get("minAngle")*o,x=g.getSum("value");0===x&&(x=g.count());var b=Math.PI/x*2,w=t.get("clockwise"),M=t.get("roseType"),S=g[R]("value");S[0]=0;var k=a,A=0,C=y,T=w?1:-1;if(g.each("value",function(t,i){var n;n="area"!==M?0===x?b:t*b:a/(g.count()||1),_>n?(n=_,k-=_):A+=t;var r=C+T*n;g[z](i,{angle:n,startAngle:C,endAngle:r,clockwise:w,cx:f,cy:p,r0:v,r:M?e[Ye](t,S,[v,m]):m}),C=r},!0),a>k)if(.001>=k){var D=a/g.count();g.each(function(t){var e=g[P](t);e.startAngle=y+T*t*D,e.endAngle=y+T*(t+1)*D})}else b=k/A,C=y,g.each("value",function(t,e){var i=g[P](e),n=i.angle===_?_:t*b;i.startAngle=C,i.endAngle=C+T*n,C+=n});n(t,m,h,u)})}}),e("echarts/processor/dataFilter",[],function(){return function(t,e){var i=e[Oe]({mainType:"legend"});i&&i[Vi]&&e[X](t,function(t){var e=t[be]();e.filterSelf(function(t){for(var n=e[ge](t),r=0;rt.get("largeThreshold")?r:a;this._symbolDraw=s,s[w](n),o.add(s.group),o[Qt](s===r?a.group:r.group)},updateLayout:function(){this._symbolDraw[jt]()},remove:function(t,e){this._symbolDraw&&this._symbolDraw[Qt](e,!0)}})}),e("echarts/chart/scatter",[qi,Hi,s,"./scatter/ScatterSeries","./scatter/ScatterView","../visual/symbol","../layout/points"],function(t){var e=t(Hi),i=t(s);t("./scatter/ScatterSeries"),t("./scatter/ScatterView"),i[N]("chart",e.curry(t("../visual/symbol"),"scatter",y,null)),i[V](e.curry(t("../layout/points"),"scatter"))}),e("echarts/component/tooltip/TooltipModel",[qi,n],function(t){t(n)[E]({type:"tooltip",defaultOption:{zlevel:0,z:8,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove",alwaysShowContent:!1,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"rgba(50,50,50,0.7)",borderColor:"#333",borderRadius:4,borderWidth:0,padding:5,axisPointer:{type:"line",axis:"auto",animation:!0,animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",lineStyle:{color:"#555",width:1,type:"solid"},crossStyle:{color:"#555",width:1,type:"dashed",textStyle:{}},shadowStyle:{color:"rgba(150,150,150,0.3)"}},textStyle:{color:"#fff",fontSize:14}}})}),e("echarts/component/tooltip/TooltipContent",[qi,Hi,ae,ft,"../../util/format"],function(t){function e(t){var e="cubic-bezier(0.23, 1, 0.32, 1)",i="left "+t+"s "+e+",top "+t+"s "+e;return s.map(f,function(t){return t+"transition:"+i}).join(";")}function n(t){var e=[],i=t.get("fontSize"),n=t[mt]();return n&&e.push("color:"+n),e.push("font:"+t[ti]()),i&&e.push("line-height:"+Math.round(3*i/2)+"px"),u(["decoration","align"],function(i){var n=t.get(i);n&&e.push("text-"+i+":"+n)}),e.join(";")}function r(t){t=t;var r=[],a=t.get("transitionDuration"),o=t.get(tt),s=t[ni](ii),c=t.get(i);return a&&r.push(e(a)),o&&(r.push("background-Color:"+l.toHex(o)),r.push("filter:alpha(opacity=70)"),r.push("background-Color:"+o)),u(["width","color",Ae],function(e){var i="border-"+e,n=d(i),a=t.get(n);null!=a&&r.push(i+":"+a+("color"===e?"":"px"))}),r.push(n(s)),null!=c&&r.push("padding:"+h.normalizeCssArray(c).join("px ")+"px"),r.join(";")+";"}function a(t,e){var i=document[Ni]("div"),n=e.getZr();this.el=i,this._x=e[ze]()/2,this._y=e[Le]()/2,t[et](i),this._container=t,this._show=!1,this._hideTimeout;var r=this;i.onmouseenter=function(){r.enterable&&(clearTimeout(r._hideTimeout),r._show=!0),r._inContent=!0},i.onmousemove=function(e){if(!r.enterable){var i=n.handler;c.normalizeEvent(t,e),i.dispatch(dt,e)}},i.onmouseleave=function(){r.enterable&&r._show&&r.hideLater(r._hideDelay),r._inContent=!1},o(i,t)}function o(t,e){function i(t){n(t[oe])&&t.preventDefault()}function n(i){for(;i&&i!==e;){if(i===t)return!0;i=i[ct]}}c.addEventListener(e,"touchstart",i),c.addEventListener(e,"touchmove",i),c.addEventListener(e,"touchend",i)}var s=t(Hi),l=t(ae),c=t(ft),h=t("../../util/format"),u=s.each,d=h.toCamelCase,f=["","-webkit-","-moz-","-o-"],p="position:absolute;display:block;border-style:solid;white-space:nowrap;";return a[Wi]={constructor:a,enterable:!0,update:function(){var t=this._container,e=t.currentStyle||document.defaultView.getComputedStyle(t),i=t.style;"absolute"!==i[He]&&"absolute"!==e[He]&&(i[He]="relative"),this.hide()},show:function(t){clearTimeout(this._hideTimeout),this.el.style.cssText=p+r(t)+";left:"+this._x+"px;top:"+this._y+"px;",this._show=!0},setContent:function(t){var e=this.el;e[it]=t,e.style.display=t?"block":"none"},moveTo:function(t,e){var i=this.el.style;i.left=t+"px",i.top=e+"px",this._x=t,this._y=e},hide:function(){this.el.style.display="none",this._show=!1},hideLater:function(t){!this._show||this._inContent&&this.enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(s.bind(this.hide,this),t)):this.hide())},isShow:function(){return this._show}},a}),e("echarts/component/tooltip/TooltipView",[qi,"./TooltipContent",S,Hi,"../../util/format",M,n],function(t){function e(t,e){if(!t||!e)return!1;var i=x.round;return i(t[0])===i(e[0])&&i(t[1])===i(e[1])}function i(t,e,i,n){return{x1:t,y1:e,x2:i,y2:n}}function r(t,e,i,n){return{x:t,y:e,width:i,height:n}}function a(t,e,i,n,r,a){return{cx:t,cy:e,r0:i,r:n,startAngle:r,endAngle:a,clockwise:!0}}function s(t,e,i,n,r){var a=i.clientWidth,o=i[J],s=20;return t+a+s>n?t-=a+s:t+=s,e+o+s>r?e-=o+s:e+=s,[t,e]}function c(t,e,i){var n=i.clientWidth,r=i[J],a=5,o=0,s=0,l=e.width,c=e[vi];switch(t){case si:o=e.x+l/2-n/2,s=e.y+c/2-r/2;break;case"top":o=e.x+l/2-n/2,s=e.y-r-a;break;case hi:o=e.x+l/2-n/2,s=e.y+c+a;break;case"left":o=e.x-n-a,s=e.y+c/2-r/2;break;case"right":o=e.x+l+a,s=e.y+c/2-r/2}return[o,s]}function f(t,e,i,n,r,a,o){var l=o[ze](),h=o[Le](),u=a&&a[ei]().clone();if(a&&u[mi](a[ue]),typeof t===Pi&&(t=t([e,i],r,u)),y[ki](t))e=b(t[0],l),i=b(t[1],h);else if(typeof t===Ri&&a){var d=c(t,u,n.el);e=d[0],i=d[1]}else{var d=s(e,i,n.el,l,h);e=d[0],i=d[1]}n[It](e,i)}function v(t){var e=t[C],i=t.get("tooltip.trigger",!0);return!(!e||"cartesian2d"!==e.type&&"polar"!==e.type||"item"===i)}var m=t("./TooltipContent"),g=t(S),y=t(Hi),_=t("../../util/format"),x=t(M),b=x[$e];t(n)[Z]({type:"tooltip",_axisPointers:{},init:function(t,e){var i=new m(e[Pe](),e);this._tooltipContent=i,e.on("showTip",this._manuallyShowTip,this),e.on("hideTip",this._hide,this)},render:function(t,e,i){this.group[qt](),this._axisPointers={},this._tooltipModel=t,this._ecModel=e,this._api=i,this._lastHover={};var n=this._tooltipContent;n[at](),n.enterable=t.get("enterable"),this._alwaysShowContent=t.get("alwaysShowContent"),this._seriesGroupByAxis=this._prepareAxisTriggerData(t,e);var r=this._crossText;r&&this.group.add(r);var a=this._api.getZr(),o=this._tryShow;a.off("click",o),a.off(dt,o),a.off(gt,this._hide),"click"===t.get("triggerOn")?a.on("click",o,this):(a.on(dt,o,this),a.on(gt,this._hide,this))},_manuallyShowTip:function(t){if(t.from!==this.uid){var e=this._ecModel,i=t[we],n=t[Gt],r=e.getSeriesByIndex(i),a=this._api;if(null==t.x||null==t.y){if(r||e[U](function(t){v(t)&&!r&&(r=t)}),r){var o=r[be]();null==n&&(n=o[Vt](t.name));var s=o[Ft](n);if(s){var l=s[ei]().clone();l[mi](s[ue]);var c=l.x+l.width/2,h=l.y+l[vi]/2;this._tryShow({offsetX:c,offsetY:h,target:s,event:{}})}}}else a.getZr().handler.dispatch(dt,{zrX:t.x,zrY:t.y})}},_prepareAxisTriggerData:function(t,e){var i={};return e[U](function(t){if(v(t)){var e,n,r=t[C];"cartesian2d"===r.type?(e=r[p](),n=e.dim+e.index):(e=r[p](),n=e.dim+r.name),i[n]=i[n]||{coordSys:[],series:[]},i[n].coordSys.push(r),i[n][Be].push(t)}},this),i},_tryShow:function(t){var e=t[oe],i=this._tooltipModel,n=i.get(Ht),r=this._ecModel,a=this._api;if(i)if(e&&null!=e[Gt]){var o=e[H]||r.getSeriesByIndex(e[we]),s=e[Gt],l=o[be]()[me](s);"axis"===(l.get("tooltip.trigger")||n)?this._showAxisTooltip(i,r,t):(this._ticket="",this._hideAxisPointer(),this._resetLastHover(),this._showItemTooltipContent(o,s,t)),a[De]({type:"showTip",from:this.uid,dataIndex:e[Gt],seriesIndex:e[we]})}else"item"===n?this._hide():this._showAxisTooltip(i,r,t),a[De]({type:"showTip",from:this.uid,x:t[ut],y:t[ht]})},_showAxisTooltip:function(t,i,n){var r=t[ni]("axisPointer"),a=r.get("type");if("cross"===a){var o=n[oe];if(o&&null!=o[Gt]){var s=i.getSeriesByIndex(o[we]),l=o[Gt];this._showItemTooltipContent(s,l,n)}}this._showAxisPointer();var c=!0;y.each(this._seriesGroupByAxis,function(t){var i=t.coordSys,o=i[0],s=[n[ut],n[ht]];if(!o.containPoint(s))return void this._hideAxisPointer(o.name);c=!1;var l=o[B],h=o.pointToData(s,!0);s=o[u](h);var d=o[p](),f=r.get("axis");"auto"===f&&(f=d.dim);var v=!1,m=this._lastHover;if("cross"===a)e(m.data,h)&&(v=!0),m.data=h;else{var g=y[Bi](l,f);m.data===h[g]&&(v=!0),m.data=h[g]}"cartesian2d"!==o.type||v?"polar"!==o.type||v||this._showPolarPointer(r,o,f,s):this._showCartesianPointer(r,o,f,s),"cross"!==a&&this._showSeriesTooltipContent(o,t[Be],s,h,v)},this),c&&this._hide()},_showCartesianPointer:function(t,e,n,a){function o(n,r,a){var o="x"===n?i(r[0],a[0],r[0],a[1]):i(a[0],r[1],a[1],r[1]),s=l._getPointerElement(e,t,n,o);u?g[vt](s,{shape:o},t):s.attr({shape:o})}function s(i,n,a){var o=e[h](i),s=o.getBandWidth(),c=a[1]-a[0],d="x"===i?r(n[0]-s/2,a[0],s,c):r(a[0],n[1]-s/2,c,s),f=l._getPointerElement(e,t,i,d);u?g[vt](f,{shape:d},t):f.attr({shape:d})}var l=this,c=t.get("type"),u="cross"!==c;if("cross"===c)o("x",a,e[h]("y").getGlobalExtent()),o("y",a,e[h]("x").getGlobalExtent()),this._updateCrossText(e,a,t);else{var d=e[h]("x"===n?"y":"x"),f=d.getGlobalExtent();"cartesian2d"===e.type&&("line"===c?o:s)(n,a,f)}},_showPolarPointer:function(t,e,n,r){function o(n,r,a){var o,s=e.pointToCoord(r);if("angle"===n){var c=e.coordToPoint([a[0],s[1]]),h=e.coordToPoint([a[1],s[1]]);o=i(c[0],c[1],h[0],h[1])}else o={cx:e.cx,cy:e.cy,r:s[0]};var u=l._getPointerElement(e,t,n,o);p?g[vt](u,{shape:o},t):u.attr({shape:o})}function s(i,n,r){var o,s=e[h](i),c=s.getBandWidth(),u=e.pointToCoord(n),d=Math.PI/180;o="angle"===i?a(e.cx,e.cy,r[0],r[1],(-u[1]-c/2)*d,(-u[1]+c/2)*d):a(e.cx,e.cy,u[0]-c/2,u[0]+c/2,0,2*Math.PI);var f=l._getPointerElement(e,t,i,o);p?g[vt](f,{shape:o},t):f.attr({shape:o})}var l=this,c=t.get("type"),u=e.getAngleAxis(),f=e.getRadiusAxis(),p="cross"!==c;if("cross"===c)o("angle",r,f[d]()),o(Ae,r,u[d]()),this._updateCrossText(e,r,t);else{var v=e[h](n===Ae?"angle":Ae),m=v[d]();("line"===c?o:s)(n,r,m)}},_updateCrossText:function(t,e,i){var n=i[ni]("crossStyle"),r=n[ni](ii),a=this._tooltipModel,s=this._crossText;s||(s=this._crossText=new g.Text({style:{textAlign:"left",textBaseline:"bottom"}}),this.group.add(s));var l=t.pointToData(e),c=t[B];l=y.map(l,function(e,i){var n=t[h](c[i]);return e=n.type===A||"time"===n.type?n.scale[o](e):_[pe](e[Xe](n[Ue]()))}),s[bt]({fill:r[mt]()||n.get("color"),textFont:r[ti](),text:l.join(", "),x:e[0]+5,y:e[1]-5}),s.z=a.get("z"),s[ot]=a.get(ot)},_getPointerElement:function(t,e,i,n){var r=this._tooltipModel,a=r.get("z"),o=r.get(ot),s=this._axisPointers,c=t.name;if(s[c]=s[c]||{},s[c][i])return s[c][i];var h=e.get("type"),u=e[ni](h+"Style"),d="shadow"===h,f=u[d?"getAreaStyle":l](),p="polar"===t.type?d?kt:i===Ae?"Circle":"Line":d?"Rect":"Line";d?f[wi]=null:f.fill=null;var v=s[c][i]=new g[p]({style:f,z:a,zlevel:o,silent:!0,shape:n});return this.group.add(v),v},_showSeriesTooltipContent:function(t,e,i,n,r){var a=this._tooltipModel,o=this._tooltipContent,s=t[p](),l=n["x"===s.dim||s.dim===Ae?0:1],c=y.map(e,function(t){return{seriesIndex:t[we],dataIndex:t[be]().indexOfNearest(t.getDimensionsOnAxis(s.dim),l)}}),h=this._api,u=this._lastHover;if(u.payloadBatch&&!r&&this._api[De]({type:"downplay",batch:y.clone(u.payloadBatch)}),r||(this._api[De]({type:"highlight",batch:y.clone(c)}),u.payloadBatch=c),s&&a.get("showContent")){var d,v=a.get("formatter"),m=a.get(He),g=y.map(e,function(t,e){return t[ve](c[e][Gt])});o.show(a);var x=c[0][Gt];if(!r){if(this._ticket="",v){if(typeof v===Ri)d=_.formatTpl(v,g);else if(typeof v===Pi){var b=this,w="axis_"+t.name+"_"+x,M=function(t,e){t===b._ticket&&(o.setContent(e),f(m,i[0],i[1],o,g,null,h))};b._ticket=w,d=v(g,w,M)}}else d=e[0][be]()[ge](x)+"
"+y.map(e,function(t,e){return t.formatTooltip(c[e][Gt],!0)}).join("
");o.setContent(d)}f(m,i[0],i[1],o,g,null,h)}},_showItemTooltipContent:function(t,e,i){var n=this._api,r=t[be](),a=r[me](e),o=this._tooltipModel,s=this._tooltipContent,l=a[ni]("tooltip");if(l.parentModel?l.parentModel.parentModel=o:l.parentModel=this._tooltipModel,l.get("showContent")){var c,h=l.get("formatter"),u=l.get(He),d=t[ve](e);if(h){if(typeof h===Ri)c=_.formatTpl(h,d);else if(typeof h===Pi){var p=this,v="item_"+t.name+"_"+e,m=function(t,e){t===p._ticket&&(s.setContent(e),f(u,i[ut],i[ht],s,d,i[oe],n))};p._ticket=v,c=h(d,v,m)}}else c=t.formatTooltip(e);s.show(l),s.setContent(c),f(u,i[ut],i[ht],s,d,i[oe],n)}},_showAxisPointer:function(t){if(t){var e=this._axisPointers[t];e&&y.each(e,function(t){t.show()})}else this.group[We](function(t){t.show()}),this.group.show()},_resetLastHover:function(){var t=this._lastHover;t.payloadBatch&&this._api[De]({type:"downplay",batch:t.payloadBatch}),this._lastHover={}},_hideAxisPointer:function(t){if(t){var e=this._axisPointers[t];e&&y.each(e,function(t){t.hide()})}else this.group.hide()},_hide:function(){this._hideAxisPointer(),this._resetLastHover(),this._alwaysShowContent||this._tooltipContent.hideLater(this._tooltipModel.get("hideDelay"))},dispose:function(t,e){var i=e.getZr();i.off("click",this._tryShow),i.off(dt,this._tryShow),i.off(gt,this._hide),e.off("showTip")}})}),e("echarts/component/tooltip",[qi,"./tooltip/TooltipModel","./tooltip/TooltipView",s,s],function(t){t("./tooltip/TooltipModel"),t("./tooltip/TooltipView"),t(s)[F]({type:"showTip",event:"showTip",update:"none"},function(){}),t(s)[F]({type:"hideTip",event:"hideTip",update:"none"},function(){})}),e("echarts/component/legend/LegendModel",[qi,Hi,"../../model/Model",n],function(t){var e=t(Hi),i=t("../../model/Model");return t(n)[E]({type:"legend",dependencies:[Be],layoutMode:{type:"box",ignoreSize:!0},init:function(t,n,r){this[Ne](t,r),t.selected=t.selected||{};var a=e.map(t.data||[],function(t){return typeof t===Ri&&(t={name:t}),new i(t,this,this[ri])},this);this._data=a,this._updateAvailableNames(r);var o=this[Ke].selected;if(a[0]&&"single"===this.get("selectedMode")){var s=!1;for(var l in o)o[l]&&(this.select(l),s=!0);!s&&this.select(a[0].get("name"))}},mergeOption:function(t){this.$superCall(Ze,t),this._updateAvailableNames(this[ri])},_updateAvailableNames:function(t){var i=e.map(t.getSeries(),function(t){return t.name});t[U](function(t){if(t.legendDataProvider){var e=t.legendDataProvider();i=i[Ii](e[O](e[ge]))}}),this._availableNames=i},getData:function(){return this._data},select:function(t){var i=this[Ke].selected,n=this.get("selectedMode");if("single"===n){var r=this._data;e.each(r,function(t){i[t.get("name")]=!1})}i[t]=!0},unSelect:function(t){"single"!==this.get("selectedMode")&&(this[Ke].selected[t]=!1)},toggleSelected:function(t){var e=this[Ke].selected;t in e||(e[t]=!0),this[e[t]?"unSelect":"select"](t)},isSelected:function(t){var i=this[Ke].selected;return!(t in i&&!i[t])&&e[Bi](this._availableNames,t)>=0},defaultOption:{zlevel:0,z:4,show:!0,orient:"horizontal",left:"center",top:"top",align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,textStyle:{color:"#333"},selectedMode:!0}})}),e("echarts/component/legend/legendAction",[qi,n,Hi],function(t){function e(t,e,i){var n,a={},o="toggleSelected"===t;return i[W]("legend",function(i){o&&null!=n?i[n?"select":"unSelect"](e.name):(i[t](e.name),n=i.isSelected(e.name));var s=i[be]();r.each(s,function(t){var e=t.get("name");if("\n"!==e&&""!==e){var n=i.isSelected(e);e in a?a[e]=a[e]&&n:a[e]=n}})}),{name:e.name,selected:a}}var i=t(n),r=t(Hi);i[F]("legendToggleSelect","legendselectchanged",r.curry(e,"toggleSelected")),i[F]("legendSelect","legendselected",r.curry(e,"select")),i[F]("legendUnSelect","legendunselected",r.curry(e,"unSelect"))}),e("echarts/component/helper/listComponent",[qi,"../../util/layout","../../util/format",S],function(t){function e(t,e,r){n.positionGroup(t,e.getBoxLayoutParams(),{width:r[ze](),height:r[Le]()},e.get(i))}var n=t("../../util/layout"),r=t("../../util/format"),a=t(S);return{layout:function(t,i,r){n.box(i.get("orient"),t,i.get("itemGap"),r[ze](),r[Le]()),e(t,i,r)},addBackground:function(t,e){var n=r.normalizeCssArray(e.get(i)),o=t[ei](),s=e[g](["color",bi]);s.fill=e.get(tt);var l=new a.Rect({shape:{x:o.x-n[3],y:o.y-n[0],width:o.width+n[1]+n[3],height:o[vi]+n[0]+n[2]},style:s,silent:!0});a[wt](l),t.add(l)}}}),e("echarts/component/legend/LegendView",[qi,Hi,k,S,"../helper/listComponent",n],function(t){function e(t,e){e[De]({type:"legendToggleSelect",name:t})}function i(t,e,i){t.get("legendHoverLink")&&i[De]({type:"highlight",seriesName:t.name,name:e})}function r(t,e,i){t.get("legendHoverLink")&&i[De]({type:"downplay",seriesName:t.name,name:e})}var a=t(Hi),o=t(k),s=t(S),l=t("../helper/listComponent"),c=a.curry,h="#ccc";return t(n)[Z]({type:"legend",init:function(){this._symbolTypeStore={}},render:function(t,n,o){var u=t.get("selectedMode"),d=t.get("itemWidth"),f=t.get("itemHeight"),p=t.get("align"),v=this.group;v[qt](),"auto"===p&&(p="right"===t.get("left")&&t.get("orient")===Fe?"right":"left");var m={},g={};a.each(t[be](),function(a){var l=a.get("name");(""===l||"\n"===l)&&v.add(new s.Group({newline:!0}));var y=n.getSeriesByName(l)[0];if(m[l]=a,y&&!g[l]){var x=y[be](),b=x[I]("color");t.isSelected(l)||(b=h),typeof b===Pi&&(b=b(y[ve](0)));var w=x[I]("legendSymbol")||"roundRect",M=x[I](_),S=this._createItem(l,a,t,w,M,d,f,p,b,u);S.on("click",c(e,l,o)).on(yt,c(i,y,"",o)).on(gt,c(r,y,"",o)),g[l]=!0}},this),n.eachRawSeries(function(n){if(n.legendDataProvider){var a=n.legendDataProvider();a.each(function(s){var l=a[ge](s);if(m[l]&&!g[l]){var v=a[L](s,"color");t.isSelected(l)||(v=h);var y="roundRect",_=this._createItem(l,m[l],t,y,null,d,f,p,v,u);_.on("click",c(e,l,o)).on(yt,c(i,n,l,o)).on(gt,c(r,n,l,o)),g[l]=!0}},!1,this)}},this),l.layout(v,t,o),l.addBackground(v,t)},_createItem:function(t,e,i,n,r,a,l,c,h,u){var d=new s.Group,f=e[ni](ii),p=e.get("icon");if(n=p||n,d.add(o[b](n,0,0,a,l,h)),!p&&r&&r!==n&&"none"!=r){var v=.8*l;d.add(o[b](r,(a-v)/2,(l-v)/2,v,v,h))}var m="left"===c?a+5:-5,g=c,y=i.get("formatter");typeof y===Ri&&y?t=y[Qe]("{name}",t):typeof y===Pi&&(t=y(t));var _=new s.Text({style:{text:t,x:m,y:l/2,fill:f[mt](),textFont:f[ti](),textAlign:g,textBaseline:"middle"}});return d.add(_),d.add(new s.Rect({shape:d[ei](),invisible:!0})),d[We](function(t){t.silent=!u}),this.group.add(d),d}})}),e("echarts/component/legend/legendFilter",[],function(){return function(t){var e=t[Oe]({mainType:"legend"});e&&e[Vi]&&t.filterSeries(function(t){for(var i=0;i0?"top":hi,n=li):u(a-f)?(r=i>0?hi:"top",n=li):(r=ci,n=a>0&&f>a?i>0?"right":"left":i>0?"left":"right"),{rotation:a,textAlign:n,textBaseline:r}}function i(t,e,i){var n,r,a=h(-t[de]),o=i[0]>i[1],s="start"===e&&!o||"start"!==e&&o;return u(a-f/2)?(r=s?hi:"top",n=li):u(a-1.5*f)?(r=s?"top":hi,n=li):(r=ci,n=1.5*f>a&&a>f/2?s?"left":"right":s?"right":"left"),{rotation:a,textAlign:n,textBaseline:r}}var n=t(Hi),r=t(S),s=t("../../model/Model"),c=t(M),h=c.remRadian,u=c.isRadianAroundZero,f=Math.PI,p=function(t,e){this.opt=e,this.axisModel=t,n[oi](e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0}),this.group=new r.Group({position:e[He].slice(),rotation:e[de]})};p[Wi]={constructor:p,hasBuilder:function(t){return!!v[t]},add:function(t){v[t].call(this)},getGroup:function(){return this.group}};var v={axisLine:function(){var t=this.opt,e=this.axisModel;if(e.get("axisLine.show")){var i=this.axisModel.axis[d]();this.group.add(new r.Line({shape:{x1:i[0],y1:0,x2:i[1],y2:0},style:n[Di]({lineCap:"round"},e[ni]("axisLine.lineStyle")[l]()),strokeContainThreshold:t.strokeContainThreshold,silent:!!t.silent,z2:1}))}},axisTick:function(){var t=this.axisModel;if(t.get("axisTick.show")){for(var e=t.axis,i=t[ni]("axisTick"),n=this.opt,a=i[ni]("lineStyle"),o=i.get(Vi),s=g(i,n.labelInterval),c=e.getTicksCoords(),h=[],u=0;uu[1]?-1:1,p=["start"===s?u[0]-f*h:"end"===s?u[1]+f*h:(u[0]+u[1])/2,s===ci?t.labelOffset+l*h:0];o=s===ci?e(t,t[de],l):i(t,s,u),this.group.add(new r.Text({style:{text:a,textFont:c[ti](),fill:c[mt]()||n.get("axisLine.lineStyle.color"),textAlign:o[Zt],textBaseline:o[Bt]},position:p,rotation:o[de],silent:!0,z2:1}))}}},m=p.ifIgnoreOnTick=function(t,e,i){return t.scale.type===xe&&typeof i===Pi&&!i(e,t.scale[o](e))||e%(i+1)},g=p.getInterval=function(t,e){var i=t.get("interval");return(null==i||"auto"==i)&&(i=e),i};return p}),e("echarts/component/axis/AxisView",[qi,Hi,S,"./AxisBuilder",n],function(t){function e(t,e){function i(t,e){var i=n[h](t);return i.toGlobalCoord(i[a](0))}var n=t[C],o=e.axis,s={},l=o[He],c=o.onZero?"onZero":l,u=o.dim,d=n[r](),f=[d.x,d.x+d.width,d.y,d.y+d[vi]],p={x:{top:f[2],bottom:f[3]},y:{left:f[0],right:f[1]}};p.x.onZero=Math.max(Math.min(i("y"),p.x[hi]),p.x.top),p.y.onZero=Math.max(Math.min(i("x"),p.y.right),p.y.left),s[He]=["y"===u?p.y[c]:f[0],"x"===u?p.x[c]:f[3]];var v={x:0,y:1};s[de]=Math.PI/2*v[u];var m={top:-1,bottom:1,left:-1,right:1};s.labelDirection=s.tickDirection=s.nameDirection=m[l],o.onZero&&(s.labelOffset=p[u][l]-p[u].onZero),e[ni]("axisTick").get(si)&&(s.tickDirection=-s.tickDirection),e[ni]("axisLabel").get(si)&&(s.labelDirection=-s.labelDirection);var g=e[ni]("axisLabel").get(le);return s.labelRotation="top"===c?-g:g,s.labelInterval=o.getLabelInterval(),s.z2=1,s}var i=t(Hi),o=t(S),s=t("./AxisBuilder"),l=s.ifIgnoreOnTick,u=s.getInterval,d=["axisLine","axisLabel","axisTick","axisName"],f=["splitLine","splitArea"],p=t(n)[Z]({type:"axis",render:function(t,n){if(this.group[qt](),t.get("show")){var r=n[Ce]("grid",t.get("gridIndex")),a=e(r,t),o=new s(t,a);i.each(d,o.add,o),this.group.add(o.getGroup()),i.each(f,function(e){t.get(e+".show")&&this["_"+e](t,r,a.labelInterval)},this)}},_splitLine:function(t,e,i){var n=t.axis,a=t[ni]("splitLine"),s=a[ni]("lineStyle"),h=s.get("width"),d=s.get("color"),f=u(a,i);d=d instanceof Array?d:[d];for(var p=e[C][r](),v=n[c](),m=[],g=0,y=n.getTicksCoords(),_=[],x=[],b=0;bx?c="left":b>.8?(_.x+=_.width,c="right"):(_.x+=_.width/2,c=li)}o[He]=[_.x,_.y],h[bt](Zt,c),f[bt](Zt,c),m=o[ei]();var w=_.margin,M=t[g](["color",bi]);M.fill=t.get(tt);var S=new n.Rect({shape:{x:m.x-w[3],y:m.y-w[0],width:m.width+w[1]+w[3],height:m[vi]+w[0]+w[2]},style:M,silent:!0});n[wt](S),o.add(S)}}})}),e("echarts/component/marker/MarkPointModel",[qi,"../../model/globalDefault",T,n],function(t){var e=t("../../model/globalDefault"),i=t(T);e.markPoint={};var r=t(n)[E]({type:"markPoint",dependencies:[Be,"grid","polar"],init:function(t,e,i,n,r){this[Ne](t,i),this[Ze](t,r,!0)},mergeOption:function(t,e,n){if(!e){var a=this[ri];a[U](function(t){var e=t.get("markPoint"),o=t.markPointModel;if(!e||!e.data)return void(t.markPointModel=null);if(o)o[Ze](e,!0);else{n&&i.defaultEmphasis(e.label,[He,"show",ii,yi,"formatter"]);var s={seriesIndex:t[we],name:t.name};o=new r(e,this,a,s,!0)}t.markPointModel=o},this)}},defaultOption:{zlevel:0,z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{normal:{show:!0,position:"inside"},emphasis:{show:!0}},itemStyle:{normal:{borderWidth:2},emphasis:{}}}});return r}),e("echarts/component/marker/markerHelper",[qi,Hi,M],function(t){function e(t,e,i){var n=-1;do n=Math.max(r.getPrecision(t.get(e,i)),n),t=t.stackedOn;while(t);return n}function i(t,i,n,r,a){var o=i[R](r),s=[],l=o[0],c=o[1],h=(c-l)*t+l,u=i.indexOfNearest(r,h);s[1-a]=i.get(n,u),s[a]=i.get(r,u,!0);var d=e(i,r,u);return d>=0&&(s[a]=+s[a][Xe](d)),s}var n=t(Hi),r=t(M),a=n.curry,o={min:a(i,0),max:a(i,1),average:a(i,.5)},s=function(t,e,i){if((isNaN(i.x)||isNaN(i.y))&&!n[ki](i.coord)&&e){var r,a,s,l;null!=i.valueIndex?(r=e[B][i.valueIndex],a=e[B][1-i.valueIndex],s=e[h](r),l=e[h](a)):(l=e[p](),s=e[f](l),a=l.dim,r=s.dim);var c=null!=i.valueIndex?i.valueIndex:"angle"===r||"x"===r?0:1;i=n[Di]({},i),i.type&&o[i.type]&&l&&s?i.coord=o[i.type](t,l.dim,r,c):i.coord=[null!=i.xAxis?i.xAxis:i.radiusAxis,null!=i.yAxis?i.yAxis:i.angleAxis]}return i},l=function(t,e){return t&&e.coord&&(null==e.x||null==e.y)?t.containData(e.coord):!0},c=function(t,e,i,n){return 2>n?t.coord&&t.coord[n]:void t.value};return{dataTransform:s,dataFilter:l,dimValueGetter:c}}),e("echarts/component/marker/MarkPointView",[qi,"../../chart/helper/SymbolDraw",Hi,"../../util/format",T,M,"../../data/List","./markerHelper",n],function(t){function e(t,e,i){var n=e[B],a=new h(r.map(n,e.getDimensionInfo,e),i);return t&&a.initData(r[Gi](r.map(i.get("data"),r.curry(d.dataTransform,e,t)),r.curry(d.dataFilter,t)),null,d.dimValueGetter),a}var i=t("../../chart/helper/SymbolDraw"),r=t(Hi),a=t("../../util/format"),o=t(T),s=t(M),l=a[pe],c=a.encodeHTML,h=t("../../data/List"),d=t("./markerHelper"),f={getRawDataArray:function(){return this[Ke].data},formatTooltip:function(t){var e=this[be](),i=this[_e](t),n=r[ki](i)?r.map(i,l).join(", "):l(i),a=e[ge](t);return this.name+"
"+((a?c(a)+" : ":"")+n)},getData:function(){return this._data},setData:function(t){this._data=t}};r[oi](f,o.dataFormatMixin),t(n)[Z]({type:"markPoint",init:function(){this._symbolDrawMap={}},render:function(t,e,i){var n=this._symbolDrawMap;for(var r in n)n[r].__keep=!1;e[U](function(t){var e=t.markPointModel;e&&this._renderSeriesMP(t,e,i)},this);for(var r in n)n[r].__keep||(n[r][Qt](),this.group[Qt](n[r].group))},_renderSeriesMP:function(t,n,a){var o=t[C],l=t.name,c=t[be](),h=this._symbolDrawMap,d=h[l];d||(d=h[l]=new i);var p=e(o,c,n),v=o&&o[B];r.mixin(n,f),n.setData(p),p.each(function(t){var e,i=p[me](t),r=i[Si]("x"),l=i[Si]("y");if(null!=r&&null!=l)e=[s[$e](r,a[ze]()),s[$e](l,a[Le]())];else if(o){var h=p.get(v[0],t),d=p.get(v[1],t);e=o[u]([h,d])}p[z](t,e);var f=i[Si](x);typeof f===Pi&&(f=f(n[_e](t),n[ve](t))),p[$](t,{symbolSize:f,color:i.get("itemStyle.normal.color")||c[I]("color"),symbol:i[Si](_)})}),d[w](p),this.group.add(d.group),p[Nt](function(t){t[Xt](function(t){t[H]=n})}),d.__keep=!0}})}),e("echarts/component/markPoint",[qi,"./marker/MarkPointModel","./marker/MarkPointView"],function(t){t("./marker/MarkPointModel"),t("./marker/MarkPointView")}),e("echarts/component/marker/MarkLineModel",[qi,"../../model/globalDefault",T,n],function(t){var e=t("../../model/globalDefault"),i=t(T);e.markLine={};var r=t(n)[E]({type:"markLine",dependencies:[Be,"grid","polar"],init:function(t,e,i,n,r){this[Ne](t,i),this[Ze](t,r,!0)},mergeOption:function(t,e,n){if(!e){var a=this[ri];a[U](function(t){var e=t.get("markLine"),o=t.markLineModel;if(!e||!e.data)return void(t.markLineModel=null);if(o)o[Ze](e,!0);else{n&&i.defaultEmphasis(e.label,[He,"show",ii,yi,"formatter"]);var s={seriesIndex:t[we],name:t.name};o=new r(e,this,a,s,!0)}t.markLineModel=o},this)}},defaultOption:{zlevel:0,z:5,symbol:[y,"arrow"],symbolSize:[8,16],precision:2,tooltip:{trigger:"item"},label:{normal:{show:!0,position:"end"},emphasis:{show:!0}},lineStyle:{normal:{type:"dashed"},emphasis:{width:3}},animationEasing:"linear"}});return r}),e("echarts/chart/helper/LinePath",[qi,S],function(t){var e=t(S),i=e.Line[Wi],n=e.BezierCurve[Wi]; -return e[Mt]({type:"ec-line",style:{stroke:"#000",fill:null},shape:{x1:0,y1:0,x2:0,y2:0,percent:1,cpx1:null,cpy1:null},buildPath:function(t,e){(null==e.cpx1||null==e.cpy1?i:n)[Dt](t,e)},pointAt:function(t){var e=this.shape;return null==e.cpx1||null==e.cpy1?i.pointAt.call(this,t):n.pointAt.call(this,t)}})}),e("echarts/chart/helper/Line",[qi,k,xi,"./LinePath",S,Hi,M],function(t){function e(t,e,i){var n=e[L](i,"color"),r=e[L](i,_),a=e[L](i,x);if("none"!==r){f[ki](a)||(a=[a,a]);var o=c[b](r,-a[0]/2,-a[1]/2,a[0],a[1],n);return o.name=t,o}}function i(t){var e=new u({name:"line",style:{strokeNoScale:!0}});return n(e.shape,t),e}function n(t,e){var i=e[0],n=e[1],r=e[2];t.x1=i[0],t.y1=i[1],t.x2=n[0],t.y2=n[1],t.percent=1,r&&(t.cpx1=r[0],t.cpy1=r[1])}function r(t){return t.type===_&&"arrow"===t.shape.symbolType}function a(){var t=this,e=t.childOfName("line");if(this[Kt]||e[Kt]){var i=t.childOfName("fromSymbol"),n=t.childOfName("toSymbol"),a=t.childOfName("label"),s=e.pointAt(0),l=e.pointAt(e.shape.percent),c=h.sub([],l,s);h.normalize(c,c),i&&(i.attr(He,s),r(n)&&n.attr(de,o(s,l))),n&&(n.attr(He,l),r(i)&&i.attr(de,o(l,s))),a.attr(He,l);var u,d,f;"end"===a.__position?(u=[5*c[0]+l[0],5*c[1]+l[1]],d=c[0]>.8?"left":c[0]<-.8?"right":li,f=c[1]>.8?"top":c[1]<-.8?hi:ci):(u=[5*-c[0]+s[0],5*-c[1]+s[1]],d=c[0]>.8?"right":c[0]<-.8?"left":li,f=c[1]>.8?hi:c[1]<-.8?"top":ci),a.attr({style:{textBaseline:a.__textBaseline||f,textAlign:a.__textAlign||d},position:u})}}function o(t,e){return-Math.PI/2-Math.atan2(e[1]-t[1],e[0]-t[0])}function s(t,e,i,n){d.Group.call(this),this._createLine(t,e,i,n)}var c=t(k),h=t(xi),u=t("./LinePath"),d=t(S),f=t(Hi),p=t(M),v=s[Wi];return v.beforeUpdate=a,v._createLine=function(t,n,r,a){var o=t[H],s=t[P](a),l=i(s);l.shape.percent=0,d[pt](l,{shape:{percent:1}},o),this.add(l);var c=new d.Text({name:"label"});if(this.add(c),n){var h=e("fromSymbol",n,a);this.add(h),this._fromSymbolType=n[L](a,_)}if(r){var u=e("toSymbol",r,a);this.add(u),this._toSymbolType=r[L](a,_)}this._updateCommonStl(t,n,r,a)},v[w]=function(t,i,r,a){var o=t[H],s=this.childOfName("line"),l=t[P](a),c={shape:{}};if(n(c.shape,l),d[vt](s,c,o),i){var h=i[L](a,_);if(this._fromSymbolType!==h){var u=e("fromSymbol",i,a);this[Qt](s.childOfName("fromSymbol")),this.add(u)}this._fromSymbolType=h}if(r){var f=r[L](a,_);if(f!==this._toSymbolType){var p=e("toSymbol",r,a);this[Qt](s.childOfName("toSymbol")),this.add(p)}this._toSymbolType=f}this._updateCommonStl(t,i,r,a)},v._updateCommonStl=function(t,e,i,n){var r=t[H],a=this.childOfName("line"),o=t[me](n),s=o[ni]("label.normal"),c=s[ni](ii),h=o[ni]("label.emphasis"),u=h[ni](ii),v=p.round(r[_e](n));isNaN(v)&&(v=t[ge](n)),a[bt](f[Di]({stroke:t[L](n,"color")},o[ni]("lineStyle.normal")[l]()));var g=this.childOfName("label");g[bt]({text:s.get("show")?r[m](n,Me)||v:"",textFont:c[ti](),fill:c[mt]()||t[L](n,"color")}),g[xt]={text:h.get("show")?r[m](n,Se)||v:"",textFont:c[ti](),fill:u[mt]()},g.__textAlign=c.get("align"),g.__textBaseline=c.get("baseline"),g.__position=s.get(He),d[_t](this,o[ni]("lineStyle.emphasis")[l]())},v[jt]=function(t,e,i,r){var a=t[P](r),o=this.childOfName("line");n(o.shape,a),o.dirty(!0),e&&e[Ft](r).attr(He,a[0]),i&&i[Ft](r).attr(He,a[1])},f[Ti](s,d.Group),s}),e("echarts/chart/helper/LineDraw",[qi,S,"./Line"],function(t){function e(t){this._ctor=t||n,this.group=new i.Group}var i=t(S),n=t("./Line"),r=e[Wi];return r[w]=function(t,e,i){var n=this._lineData,r=this.group,a=this._ctor;t.diff(n).add(function(n){var o=new a(t,e,i,n);t[D](n,o),r.add(o)})[at](function(a,o){var s=n[Ft](o);s[w](t,e,i,a),t[D](a,s),r.add(s)})[Qt](function(t){r[Qt](n[Ft](t))})[v](),this._lineData=t,this._fromData=e,this._toData=i},r[jt]=function(){var t=this._lineData;t[Nt](function(e,i){e[jt](t,this._fromData,this._toData,i)},this)},r[Qt]=function(){this.group[qt]()},e}),e("echarts/component/marker/MarkLineView",[qi,Hi,"../../data/List","../../util/format",T,M,"./markerHelper","../../chart/helper/LineDraw",n],function(t){function e(t,e){return g.dataFilter(t,e[0])&&g.dataFilter(t,e[1])}function i(t,i,n){var a=t[B],s=new o(a,n),l=new o(a,n),c=new o([],n);if(t){var h=t[p](),u=t[f](h),d=r[Gi](r.map(n.get("data"),r.curry(b,i,t,h,u)),r.curry(e,t));s.initData(r.map(d,function(t){return t[0]}),null,g.dimValueGetter),l.initData(r.map(d,function(t){return t[1]}),null,g.dimValueGetter),c.initData(r.map(d,function(t){return t[2]}))}return{from:s,to:l,line:c}}var r=t(Hi),o=t("../../data/List"),s=t("../../util/format"),l=t(T),c=t(M),v=s[pe],m=s.encodeHTML,g=t("./markerHelper"),y=t("../../chart/helper/LineDraw"),b=function(t,e,i,n,o){var s=o.type;if(!r[ki](o)&&"min"===s||"max"===s||"average"===s){null!=o.valueIndex&&(i=e[h](e[B][1-o.valueIndex]),n=e[h](e[B][o.valueIndex]));var l=i.dim+"Axis",c=n.dim+"Axis",u=i.scale[d](),f=r[Di]({},o),p={},v=t[R](n.dim,!0);f.type=null,f[l]=u[0],p[l]=u[1];var m="average"===s?.5:"max"===s?1:0,y=(v[1]-v[0])*m+v[0];y=n.coordToData(n[a](y)),f[c]=p[c]=y,o=[f,p,{type:s}]}return o=[g.dataTransform(t,e,o[0]),g.dataTransform(t,e,o[1]),{}],r.merge(o[2],o[0]),r.merge(o[2],o[1]),o},S={formatTooltip:function(t){var e=this._data,i=this[_e](t),n=r[ki](i)?r.map(i,v).join(", "):v(i),a=e[ge](t);return this.name+"
"+((a?m(a)+" : ":"")+n)},getRawDataArray:function(){return this[Ke].data},getData:function(){return this._data},setData:function(t){this._data=t}};r[oi](S,l.dataFormatMixin),t(n)[Z]({type:"markLine",init:function(){this._markLineMap={}},render:function(t,e,i){var n=this._markLineMap;for(var r in n)n[r].__keep=!1;e[U](function(t){var n=t.markLineModel;n&&this._renderSeriesML(t,n,e,i)},this);for(var r in n)n[r].__keep||this.group[Qt](n[r].group)},_renderSeriesML:function(t,e,n,a){function o(t,e,i){var n,r=t[me](e),o=r.get("x"),l=r.get("y");if(null!=o&&null!=l)n=[c[$e](o,a[ze]()),c[$e](l,a[Le]())];else{var d=t.get(v[0],e),f=t.get(v[1],e);n=s[u]([d,f])}t[z](e,n),t[$](e,{symbolSize:r.get(x)||k[i?0:1],symbol:r.get(_,!0)||M[i?0:1],color:r.get("itemStyle.normal.color")||h[I]("color")})}var s=t[C],l=t.name,h=t[be](),d=this._markLineMap,f=d[l];f||(f=d[l]=new y),this.group.add(f.group);var p=i(s,h,e),v=s[B],m=p.from,g=p.to,b=p.line;r[Di](e,S),e.setData(b);var M=e.get(_),k=e.get(x);r[ki](M)||(M=[M,M]),typeof k===Oi&&(k=[k,k]),p.from.each(function(t){o(m,t,!0),o(g,t)}),b.each(function(t){var e=b[me](t).get("lineStyle.normal.color");b[$](t,{color:e||m[L](t,"color")}),b[z](t,[m[P](t),g[P](t)])}),f[w](b,m,g),p.line[Nt](function(t,i){t[Xt](function(t){t[H]=e})}),f.__keep=!0}})}),e("echarts/component/markLine",[qi,"./marker/MarkLineModel","./marker/MarkLineView"],function(t){t("./marker/MarkLineModel"),t("./marker/MarkLineView")}),e("echarts/component/dataZoom/typeDefaulter",[qi,"../../model/Component"],function(t){t("../../model/Component").registerSubTypeDefaulter(q,function(t){return"slider"})}),e("echarts/component/dataZoom/AxisProxy",[qi,Hi,M],function(t){function e(t,e){var i=[Number.MAX_VALUE,Number.MIN_VALUE];return o(e,function(e){var n=e[be]();n&&o(e.getDimensionsOnAxis(t),function(t){var e=n[R](t);e[0]i[1]&&(i[1]=e[1])})},this),i}function i(t,e,i){var r=[0,100],l=t[Ke],c=[l.start,l.end],h=[l.startValue,l.endValue],u=["floor","ceil"];return o([0,1],function(t){var o,s=h[t],l=!0;n(s)&&(o=c[t],n(o)&&(o=r[t]),s=a[Ye](o,r,e,!0),l=!1),i&&(s=Math[u[t]](s)),l&&(o=a[Ye](s,e,r,!0)),h[t]=s,c[t]=o}),{valueWindow:s(h),percentWindow:s(c)}}function n(t){return isNaN(t)||null==t}var r=t(Hi),a=t(M),o=r.each,s=a.asc,l=function(t,e,i,n){this._dimName=t,this._axisIndex=e,this._backup,this._valueWindow,this._percentWindow,this._dataExtent,this[ri]=n,this._model=i};return l[Wi]={constructor:l,hostedBy:function(t){return this._model===t},backup:function(t,e){t===this._model&&(this._backup=e)},getBackup:function(){return r.clone(this._backup)},getDataExtent:function(){return this._dataExtent.slice()},getDataValueWindow:function(){return this._valueWindow.slice()},getDataPercentWindow:function(){return this._percentWindow.slice()},getTargetSeriesModels:function(){var t=[];return this[ri][U](function(e){this._axisIndex===e.get(this._dimName+"AxisIndex")&&t.push(e)},this),t},getAxisModel:function(){return this[ri][Ce](this._dimName+"Axis",this._axisIndex)},getOtherAxisModel:function(){var t,e,i=this._dimName,n=this[ri],r=this.getAxisModel(),a="x"===i||"y"===i;a?(e="gridIndex",t="x"===i?"y":"x"):(e="polarIndex",t="angle"===i?Ae:"angle");var o;return n[W](t+"Axis",function(t){(t.get(e)||0)===(r.get(e)||0)&&(o=t)}),o},reset:function(t){if(t===this._model){var n=this._dimName,r=this.getAxisModel(),a=r.get("type")===A,o=this.getTargetSeriesModels(),s=e(n,o),l=i(t,s,a);this._dataExtent=s.slice(),this._valueWindow=l.valueWindow.slice(),this._percentWindow=l.percentWindow.slice()}},filterData:function(t){function e(t){return t>=a[0]&&t<=a[1]}if(t===this._model){var i=this._dimName,n=this.getTargetSeriesModels(),r=t.get("filterMode"),a=this._valueWindow,s=this.getOtherAxisModel();t.get("$fromToolbox")&&s&&s.get("type")===A&&(r="empty"),o(n,function(t){var n=t[be]();n&&o(t.getDimensionsOnAxis(i),function(i){"empty"===r?t.setData(n.map(i,function(t){return e(t)?t:NaN})):n.filterSelf(i,e)})})}}},l}),e("echarts/component/dataZoom/DataZoomModel",[qi,Hi,"zrender/core/env",n,T,"./AxisProxy"],function(t){var e=t(Hi),i=t("zrender/core/env"),r=t(n),a=t(T),o=t("./AxisProxy"),s=e.each,l=a.eachAxisDim;return r[E]({type:"dataZoom",dependencies:["xAxis","yAxis","zAxis","radiusAxis","angleAxis",Be],defaultOption:{zlevel:0,z:4,orient:null,xAxisIndex:null,yAxisIndex:null,filterMode:"filter",throttle:100,start:0,end:100,startValue:null,endValue:null},init:function(t,e,i){this._autoMode,this._dataIntervalByAxis={},this._dataInfo={},this._axisProxies={},this.textStyleModel,this[Ne](t,i),this[Ze]({},!0)},mergeOption:function(t,n){var r=this[Ke];t&&e.merge(r,t),i[K]||(r.realtime=!1),this.textStyleModel=this[ni](ii),this._resetTarget(t,n),this._giveAxisProxies(),this._backup()},_giveAxisProxies:function(){var t=this._axisProxies;this.eachTargetAxis(function(e,i,n,r){var a=this.dependentModels[e.axis][i],s=a.__dzAxisProxy||(a.__dzAxisProxy=new o(e.name,i,this,r));t[e.name+"_"+i]=s},this)},_resetTarget:function(t,e){this._resetAutoMode(t,e);var i=this[Ke];l(function(t){var e=t[ke];i[e]=n===ke?[]:a.normalizeToArray(i[e])},this);var n=this._autoMode;n===ke?this._autoSetAxisIndex():"orient"===n&&this._autoSetOrient()},_resetAutoMode:function(t,e){var i=e?this[Ke]:t,n=!1;l(function(t){null!=i[t[ke]]&&(n=!0)},this);var r=i.orient;null==r&&n?this._autoMode="orient":(null==r&&(this[Ke].orient="horizontal"),n||(this._autoMode=ke))},_autoSetAxisIndex:function(){var t=this._autoMode===ke,i=this.get("orient"),n=this[Ke];if(t){var r=i===Fe?{dim:"y",axisIndex:"yAxisIndex",axis:"yAxis"}:{dim:"x",axisIndex:"xAxisIndex",axis:"xAxis"};this.dependentModels[r.axis][Vi]&&(n[r[ke]]=[0],t=!1)}t&&l(function(e){if(t){var i=[],r=this.dependentModels[e.axis];if(r[Vi]&&!i[Vi])for(var a=0,o=r[Vi];o>a;a++)r[a].get("type")===A&&i.push(a);n[e[ke]]=i,i[Vi]&&(t=!1)}},this),t&&this[ri][U](function(t){this._isSeriesHasAllAxesTypeOf(t,"value")&&l(function(i){var r=n[i[ke]],a=t.get(i[ke]);e[Bi](r,a)<0&&r.push(a)})},this)},_autoSetOrient:function(){var t;this.eachTargetAxis(function(e){!t&&(t=e.name)},this),this[Ke].orient="y"===t?Fe:"horizontal"},_isSeriesHasAllAxesTypeOf:function(t,e){var i=!0;return l(function(n){var r=t.get(n[ke]),a=this.dependentModels[n.axis][r];a&&a.get("type")===e||(i=!1)},this),i},_backup:function(){this.eachTargetAxis(function(t,e,i,n){var r=n[Ce](t.axis,e);this.getAxisProxy(t.name,e).backup(this,{scale:r.get("scale",!0),min:r.get("min",!0),max:r.get("max",!0)})},this)},getFirstTargetAxisModel:function(){var t;return l(function(e){if(null==t){var i=this.get(e[ke]);i[Vi]&&(t=this.dependentModels[e.axis][i[0]])}},this),t},eachTargetAxis:function(t,e){var i=this[ri];l(function(n){s(this.get(n[ke]),function(r){t.call(e,n,r,this,i)},this)},this)},getAxisProxy:function(t,e){return this._axisProxies[t+"_"+e]},setRawRange:function(t){s(["start","end","startValue","endValue"],function(e){this[Ke][e]=t[e]},this)},getPercentRange:function(){var t=this._axisProxies;for(var e in t)if(t.hasOwnProperty(e)&&t[e].hostedBy(this))return t[e].getDataPercentWindow();for(var e in t)if(t.hasOwnProperty(e)&&!t[e].hostedBy(this))return t[e].getDataPercentWindow()}})}),e("echarts/component/dataZoom/DataZoomView",[qi,"../../view/Component"],function(t){var e=t("../../view/Component");return e[Di]({type:"dataZoom",render:function(t,e,i,n){this.dataZoomModel=t,this[ri]=e,this.api=i},getTargetInfo:function(){function t(t,e,i,n){for(var r,a=0;a=0&&f():a>=0?f():i&&(u=setTimeout(f,-a)),c=l};return p.clear=function(){u&&(clearTimeout(u),u=null)},p}var a,o,s,l=(new Date).getTime(),c=0,h=0,u=null,d=typeof t===Pi;if(e=e||0,d)return r();for(var f=[],p=0;pe[1]&&n.reverse(),0>t&&n[0]+t0&&n[1]+t>i[1]&&(t=i[1]-n[1]),t}return t?("rigid"===n?(t=a(t,e,i),e[0]+=t,e[1]+=t):(t=a(t,e[r],i),e[r]+=t,"push"===n&&e[0]>e[1]&&(e[1-r]=e[r])),e):e}}),e("echarts/component/dataZoom/SliderZoomView",[qi,Hi,S,"../../util/throttle","./DataZoomView",M,"../../util/layout","../helper/sliderMove"],function(t){function e(t){return"x"===t?"y":"x"}var n=t(Hi),a=t(S),s=t("../../util/throttle"),l=t("./DataZoomView"),c=a.Rect,h=t(M),u=h[Ye],d=t("../../util/layout"),p=t("../helper/sliderMove"),v=h.asc,m=n.bind,g=Math.round,y=Math.max,_=n.each,x=7,b=1,w=30,k="horizontal",T=Fe,D=5,L=["line","bar","candlestick","scatter"];return l[Di]({type:"dataZoom.slider",init:function(t,e){this._displayables={},this._orient,this._range,this._handleEnds,this._size,this._halfHandleSize,this._location,this._dragging,this._dataShadowInfo,this.api=e},render:function(t,e,i,n){return this.$superApply(Wt,arguments),s.createOrUpdate(this,"_dispatchZoomAction",this.dataZoomModel.get("throttle"),"fixRate"),this._orient=t.get("orient"),this._halfHandleSize=g(t.get("handleSize")/2),this.dataZoomModel.get("show")===!1?void this.group[qt]():(n&&n.type===q&&n.from===this.uid||this._buildView(),void this._updateView())},remove:function(){this.$superApply(Qt,arguments),s.clear(this,"_dispatchZoomAction")},dispose:function(){this.$superApply(Q,arguments),s.clear(this,"_dispatchZoomAction")},_buildView:function(){var t=this.group;t[qt](),this._resetLocation(),this._resetInterval();var e=this._displayables.barGroup=new a.Group;this._renderBackground(),this._renderDataShadow(),this._renderHandle(),t.add(e),this._positionGroup()},_resetLocation:function(){var t=this.dataZoomModel,e=this.api,r=this._findCoordRect(),a={width:e[ze](),height:e[Le]()},o=this._orient===k?{left:r.x,top:a[vi]-w-x,width:r.width,height:w}:{right:x,top:r.y,width:w,height:r[vi]};n.each(d.getLayoutParams(t[Ke]),function(t,e){"auto"!==t&&(o[e]=t)});var s=d[Ve](o,a,t[i]);this._location={x:s.x,y:s.y},this._size=[s.width,s[vi]],this._orient===T&&this._size.reverse()},_positionGroup:function(){var t=this.group,e=this._location,i=this._orient,n=this.dataZoomModel.getFirstTargetAxisModel(),r=n&&n.get("inverse"),a=this._displayables.barGroup,o=(this._dataShadowInfo||{}).otherAxisInverse;a.attr(i!==k||r?i===k&&r?{scale:o?[-1,1]:[-1,-1]}:i!==T||r?{scale:o?[-1,-1]:[-1,1],rotation:Math.PI/2}:{scale:o?[1,-1]:[1,1],rotation:Math.PI/2}:{scale:o?[1,1]:[1,-1]});var s=t[ei]([a]);t[He][0]=e.x-s.x,t[He][1]=e.y-s.y},_getViewExtent:function(){var t=this._halfHandleSize,e=y(this._size[0],4*t),i=[t,e-t];return i},_renderBackground:function(){var t=this.dataZoomModel,e=this._size;this._displayables.barGroup.add(new c({silent:!0,shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:t.get(tt)}}))},_renderDataShadow:function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(t){var e=this._size,i=t[Be],n=i.getRawData(),r=i.getShadowDim?i.getShadowDim():t.otherDim,o=n[R](r),s=.3*(o[1]-o[0]);o=[o[0]-s,o[1]+s];var l=[0,e[1]],c=[0,e[0]],h=[[e[0],0],[0,0]],d=c[1]/n.count(),f=0,p=Math.round(n.count()/e[0]);n.each([r],function(t,e){if(p>0&&e%p)return void(f+=d);var i=null==t||isNaN(t)||""===t?null:u(t,o,l,!0);null!=i&&h.push([f,i]),f+=d}),this._displayables.barGroup.add(new a[St]({shape:{points:h},style:{fill:this.dataZoomModel.get("dataBackgroundColor"),lineWidth:0},silent:!0,z2:-20}))}},_prepareDataShadowInfo:function(){var t=this.dataZoomModel,i=t.get("showDataShadow");if(i!==!1){var r,a=this[ri];return t.eachTargetAxis(function(o,s){var l=t.getAxisProxy(o.name,s).getTargetSeriesModels();n.each(l,function(t){if(!(r||i!==!0&&n[Bi](L,t.get("type"))<0)){var l=e(o.name),c=a[Ce](o.axis,s).axis;r={thisAxis:c,series:t,thisDim:o.name,otherDim:l,otherAxisInverse:t[C][f](c).inverse}}},this)},this),r}},_renderHandle:function(){var t=this._displayables,e=t.handles=[],i=t.handleLabels=[],n=this._displayables.barGroup,r=this._size;n.add(t.filler=new c({draggable:!0,cursor:"move",drift:m(this._onDragMove,this,"all"),ondragend:m(this._onDragEnd,this),onmouseover:m(this._showDataInfo,this,!0),onmouseout:m(this._showDataInfo,this,!1),style:{fill:this.dataZoomModel.get("fillerColor"),textPosition:"inside"}})),n.add(new c(a[wt]({silent:!0,shape:{x:0,y:0,width:r[0],height:r[1]},style:{stroke:this.dataZoomModel.get("dataBackgroundColor"),lineWidth:b,fill:"rgba(0,0,0,0)"}}))),_([0,1],function(t){n.add(e[t]=new c({style:{fill:this.dataZoomModel.get("handleColor")},cursor:"move",draggable:!0,drift:m(this._onDragMove,this,t),ondragend:m(this._onDragEnd,this),onmouseover:m(this._showDataInfo,this,!0),onmouseout:m(this._showDataInfo,this,!1)}));var r=this.dataZoomModel.textStyleModel;this.group.add(i[t]=new a.Text({silent:!0,invisible:!0,style:{x:0,y:0,text:"",textBaseline:"middle",textAlign:"center",fill:r[mt](),textFont:r[ti]()}}))},this)},_resetInterval:function(){var t=this._range=this.dataZoomModel.getPercentRange();this._handleEnds=u(t,[0,100],this._getViewExtent(),!0)},_updateInterval:function(t,e){var i=this._handleEnds,n=this._getViewExtent();p(e,i,n,"all"===t||this.dataZoomModel.get("zoomLock")?"rigid":"cross",t),this._range=v(u(i,n,[0,100],!0))},_updateView:function(){var t=this._displayables,e=this._handleEnds,i=v(e.slice()),n=this._size,r=this._halfHandleSize;_([0,1],function(i){var a=t.handles[i];a[Ct]({x:e[i]-r,y:-1,width:2*r,height:n[1]+2,r:1})},this),t.filler[Ct]({x:i[0],y:0,width:i[1]-i[0],height:this._size[1]}),this._updateDataInfo()},_updateDataInfo:function(){function t(t){var e=a.getTransform(i.handles[t],this.group),s=a.transformDirection(0===t?"right":"left",e),l=this._halfHandleSize+D,h=a[mi]([c[t]+(0===t?-l:l),this._size[1]/2],e);n[t][bt]({x:h[0],y:h[1],textBaseline:r===k?ci:s,textAlign:r===k?s:li,text:o[t]})}var e=this.dataZoomModel,i=this._displayables,n=i.handleLabels,r=this._orient,o=["",""];if(e.get("showDetail")){var s,l;e.eachTargetAxis(function(t,i){s||(s=e.getAxisProxy(t.name,i).getDataValueWindow(),l=this[ri][Ce](t.axis,i).axis)},this),s&&(o=[this._formatLabel(s[0],l),this._formatLabel(s[1],l)])}var c=v(this._handleEnds.slice());t.call(this,0),t.call(this,1)},_formatLabel:function(t,e){var i=this.dataZoomModel,r=i.get("labelFormatter");if(n.isFunction(r))return r(t);var a=i.get("labelPrecision");return(null==a||"auto"===a)&&(a=e[Ue]()),t=null==t&&isNaN(t)?"":e.type===A||"time"===e.type?e.scale[o](Math.round(t)):t[Xe](Math.min(a,20)),n[Re](r)&&(t=r[Qe]("{value}",t)),t},_showDataInfo:function(t){t=this._dragging||t;var e=this._displayables.handleLabels;e[0].attr(Ut,!t),e[1].attr(Ut,!t)},_onDragMove:function(t,e,i){this._dragging=!0;var n=this._applyBarTransform([e,i],!0);this._updateInterval(t,n[0]),this._updateView(),this.dataZoomModel.get("realtime")&&this._dispatchZoomAction()},_onDragEnd:function(){this._dragging=!1,this._showDataInfo(!1),this._dispatchZoomAction()},_dispatchZoomAction:function(){var t=this._range;this.api[De]({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,start:t[0],end:t[1]})},_applyBarTransform:function(t,e){var i=this._displayables.barGroup[ce]();return a[mi](t,i,e)},_findCoordRect:function(){var t,e=this.getTargetInfo();if(e.cartesians[Vi])t=e.cartesians[0].model[C][r]();else{var i=this.api[ze](),n=this.api[Le]();t={x:.2*i,y:.2*n,width:.6*i,height:.6*n}}return t}})}),e("echarts/component/dataZoom/InsideZoomModel",[qi,"./DataZoomModel"],function(t){var e=t("./DataZoomModel");return e[Di]({type:"dataZoom.inside"})}),e("echarts/component/helper/interactionMutex",[qi],function(t){function e(t){return t[i]||(t[i]={})}var i="\x00_ec_interaction_mutex",n={take:function(t,i){e(i)[t]=!0},release:function(t,i){e(i)[t]=!1},isTaken:function(t,i){return!!e(i)[t]}};return n}),e("echarts/component/helper/RoamController",[qi,fe,Hi,ft,"./interactionMutex"],function(t){function e(t){if(!t[oe]||!t[oe][ee]){var e=t[ut],i=t[ht],n=this.rect;n&&n[Rt](e,i)&&(this._x=e,this._y=i,this._dragging=!0)}}function i(t){if(this._dragging&&(h.stop(t.event),"pinch"!==t.gestureEvent)){if(u.isTaken("globalPan",this._zr))return;var e=t[ut],i=t[ht],n=e-this._x,r=i-this._y;this._x=e,this._y=i;var a=this[oe];if(a){var o=a[He];o[0]+=n,o[1]+=r,a.dirty()}h.stop(t.event),this[Ht]("pan",n,r)}}function n(t){this._dragging=!1}function r(t){h.stop(t.event);var e=t.wheelDelta<0?1.1:1/1.1;o.call(this,t,e,t[ut],t[ht])}function a(t){if(!u.isTaken("globalPan",this._zr)){h.stop(t.event);var e=t.pinchScale>1?1.1:1/1.1;o.call(this,t,e,t.pinchX,t.pinchY)}}function o(t,e,i,n){var r=this.rect;if(r&&r[Rt](i,n)){var a=this[oe];if(a){var o=a[He],s=a.scale,l=this._zoom=this._zoom||1;l*=e;var c=l/this._zoom;this._zoom=l,o[0]-=(i-o[0])*(c-1),o[1]-=(n-o[1])*(c-1),s[0]*=c,s[1]*=c,a.dirty()}this[Ht]("zoom",e,i,n)}}function s(t,o,s){this[oe]=o,this.rect=s,this._zr=t;var h=c.bind,u=h(e,this),d=h(i,this),f=h(n,this),p=h(r,this),v=h(a,this);l.call(this),this.enable=function(e){this.disable(),null==e&&(e=!0),e&&"scale"!==e&&(t.on("mousedown",u),t.on(dt,d),t.on("mouseup",f)),e&&"move"!==e&&(t.on("mousewheel",p),t.on("pinch",v))},this.disable=function(){t.off("mousedown",u),t.off(dt,d),t.off("mouseup",f),t.off("mousewheel",p),t.off("pinch",v)},this[Q]=this.disable,this.isDragging=function(){return this._dragging},this.isPinching=function(){return this._pinching}}var l=t(fe),c=t(Hi),h=t(ft),u=t("./interactionMutex");return c.mixin(s,l),s}),e("echarts/component/dataZoom/InsideZoomView",[qi,"./DataZoomView","../../util/throttle",Hi,"../helper/sliderMove","../../component/helper/RoamController"],function(t){function e(t,e,i,r){e=e.slice();var a=r.axisModels[0];if(a){var o=n(t,a,i),s=o.signal*(e[1]-e[0])*o.pixel/o.pixelLength;return c(s,e,[0,100],"rigid"),e}}function i(t,e,i,r,o,s){i=i.slice();var l=o.axisModels[0];if(l){var c=n(e,l,r),h=c.pixel-c.pixelStart,u=h/c.pixelLength*(i[1]-i[0])+i[0];return t=Math.max(t,0),i[0]=(i[0]-u)*t+u,i[1]=(i[1]-u)*t+u,a(i)}}function n(t,e,i){var n=e.axis,r=i.rect,a={};return"x"===n.dim?(a.pixel=t[0],a.pixelLength=r.width,a.pixelStart=r.x,a.signal=n.inverse?1:-1):(a.pixel=t[1],a.pixelLength=r[vi],a.pixelStart=r.y,a.signal=n.inverse?-1:1),a}function a(t){var e=[0,100];return!(t[0]<=e[1])&&(t[0]=e[1]),!(t[1]<=e[1])&&(t[1]=e[1]),!(t[0]>=e[0])&&(t[0]=e[0]),!(t[1]>=e[0])&&(t[1]=e[0]),t}var o=t("./DataZoomView"),s=t("../../util/throttle"),l=t(Hi),c=t("../helper/sliderMove"),h=t("../../component/helper/RoamController"),u=l.bind;return o[Di]({type:"dataZoom.inside",init:function(t,e){this._controllers={},this._range},render:function(t,e,i,n){this.$superApply(Wt,arguments),s.createOrUpdate(this,"_dispatchZoomAction",this.dataZoomModel.get("throttle"),"fixRate"),n&&n.type===q&&n.from===this.uid||(this._range=t.getPercentRange()),this._resetController(i)},remove:function(){this.$superApply(Qt,arguments);var t=this._controllers;l.each(t,function(t){t.off("pan").off("zoom")}),t[Vi]=0,s.clear(this,"_dispatchZoomAction")},dispose:function(){this.$superApply(Q,arguments),s.clear(this,"_dispatchZoomAction")},_resetController:function(t){var e=this._controllers,i=this.getTargetInfo();l.each(i.cartesians,function(i){var n="cartesian"+i.coordIndex,a=e[n];a||(a=e[n]=new h(t.getZr()),a.enable(),a.on("pan",u(this._onPan,this,a,i)),a.on("zoom",u(this._onZoom,this,a,i))),a.rect=i.model[C][r]().clone()},this)},_onPan:function(t,i,n,r){var a=this._range=e([n,r],this._range,t,i);a&&this._dispatchZoomAction(a)},_onZoom:function(t,e,n,r,a){var o=this.dataZoomModel;n=1/n;var s=this._range=i(n,[r,a],this._range,t,e,o);this._dispatchZoomAction(s)},_dispatchZoomAction:function(t){this.api[De]({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,start:t[0],end:t[1]})}})}),e("echarts/component/dataZoom/dataZoomProcessor",[qi,n,M],function(t){function e(t,e,i,n){var r=t.name,o=i.getAxisProxy(r,e);o.reset(i);var s=o.getDataPercentWindow(),l=o.getDataValueWindow(),c=n[Ce](t.axis,e),h=0===s[0]&&100===s[1],u=o.getBackup(),d=a[Ue](l,[0,500]),f=!(20>d&&d>=0);c.setNeedsCrossZero&&c.setNeedsCrossZero(h?!u.scale:!1),c.setMin&&c.setMin(h||f?u.min:+l[0][Xe](d)),c.setMax&&c.setMax(h||f?u.max:+l[1][Xe](d))}function i(t,e,i,n){i.getAxisProxy(t.name,e).filterData(i)}var r=t(n),a=t(M);r[G](Gi,function(t,n){t[W](q,function(t){t.eachTargetAxis(e)}),t[W](q,function(t){t.eachTargetAxis(i)})})}),e("echarts/component/dataZoom/dataZoomAction",[qi,Hi,T,n],function(t){var e=t(Hi),i=t(T),r=t(n);r[F](q,function(t,n){var r=i.createLinkedNodesFinder(e.bind(n[W],n,q),i.eachAxisDim,function(t,e){return t.get(e[ke])}),a=[];n[W]({mainType:"dataZoom",query:t},function(t,e){a.push.apply(a,r(t).nodes)}),e.each(a,function(e,i){e.setRawRange({start:t.start,end:t.end,startValue:t.startValue,endValue:t.endValue})})})}),e("echarts/component/dataZoom",[qi,"./dataZoom/typeDefaulter","./dataZoom/DataZoomModel","./dataZoom/DataZoomView","./dataZoom/SliderZoomModel","./dataZoom/SliderZoomView","./dataZoom/InsideZoomModel","./dataZoom/InsideZoomView","./dataZoom/dataZoomProcessor","./dataZoom/dataZoomAction"],function(t){t("./dataZoom/typeDefaulter"),t("./dataZoom/DataZoomModel"),t("./dataZoom/DataZoomView"),t("./dataZoom/SliderZoomModel"),t("./dataZoom/SliderZoomView"),t("./dataZoom/InsideZoomModel"),t("./dataZoom/InsideZoomView"),t("./dataZoom/dataZoomProcessor"),t("./dataZoom/dataZoomAction")}),e("echarts/component/toolbox/featureManager",[qi],function(t){var e={};return{register:function(t,i){e[t]=i},get:function(t){return e[t]}}}),e("echarts/component/toolbox/ToolboxModel",[qi,"./featureManager",Hi,n],function(t){var e=t("./featureManager"),i=t(Hi);t(n)[E]({type:"toolbox",mergeDefaultAndTheme:function(t){this.$superApply(Ne,arguments),i.each(this[Ke].feature,function(t,n){var r=e.get(n);r&&i.merge(t,r.defaultOption)})},defaultOption:{show:!0,z:6,zlevel:0,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{normal:{borderColor:"#666",color:"none"},emphasis:{borderColor:"#3E98C5"}}}})}),e("echarts/component/toolbox/ToolboxView",[qi,"./featureManager",Hi,S,"../../model/Model","../../data/DataDiffer","../helper/listComponent",fi,n],function(t){var e=t("./featureManager"),i=t(Hi),r=t(S),a=t("../../model/Model"),o=t("../../data/DataDiffer"),s=t("../helper/listComponent"),l=t(fi);return t(n)[Z]({type:"toolbox",render:function(t,n,c){function h(i,r){var o,s=y[i],l=y[r],h=p[s],d=new a(h,t,t[ri]);if(s&&!l){var f=e.get(s);if(!f)return;m[s]=o=new f(d)}else{if(o=m[l],!o)return;o.model=d}return!s&&l?void(o[Q]&&o[Q](n,c)):d.get("show")?(u(d,o,s),d.setIconStatus=function(t,e){var i=this[Ke],n=this.iconPaths;i.iconStatus=i.iconStatus||{},i.iconStatus[t]=e,n[t]&&n[t][Ht](e)},void(o[Wt]&&o[Wt](d,n,c))):void(o[Qt]&&o[Qt](n,c))}function u(e,a,o){var s=e[ni]("iconStyle"),l=a.getIcons?a.getIcons():e.get("icon"),h=e.get("title")||{};if(typeof l===Ri){var u=l,p=h;l={},h={},l[o]=u,h[o]=p}var v=e.iconPaths={};i.each(l,function(o,l){var u=s[ni](Me)[g](),p=s[ni](Se)[g](),m=r.makePath(o,{style:u,hoverStyle:p,rectHover:!0},{x:-f/2,y:-f/2,width:f,height:f},li);r[_t](m),t.get("showTitle")&&(m.__title=h[l],m.on(yt,function(){m[bt]({text:h[l],textPosition:p[Et]||hi,textFill:p.fill||p[wi]||"#000",textAlign:p[Zt]||li})}).on(gt,function(){m[bt]({textFill:null})})),m[Ht](e.get("iconStatus."+l)||Me),d.add(m),m.on("click",i.bind(a.onclick,a,n,c,l)),v[l]=m})}var d=this.group;if(d[qt](),t.get("show")){var f=+t.get("itemSize"),p=t.get("feature")||{},m=this._features||(this._features={}),y=[];i.each(p,function(t,e){y.push(e)}),new o(this._featureNames||[],y).add(h)[at](h)[Qt](i.curry(h,null))[v](),this._featureNames=y,s.layout(d,t,c),s.addBackground(d,t),d[We](function(t){var e=t.__title,i=t[xt];if(i&&e){var n=l[ei](e,i.font),r=t[He][0]+d[He][0],a=t[He][1]+d[He][1]+f,o=!1;a+n[vi]>c[Le]()&&(i[Et]="top",o=!0);var s=o?-5-n[vi]:f+8;r+n.width/2>c[ze]()?(i[Et]=["100%",s],i[Zt]="right"):r-n.width/2<0&&(i[Et]=[0,s],i[Zt]="left")}})}},remove:function(t,e){i.each(this._features,function(i){i[Qt]&&i[Qt](t,e)}),this.group[qt]()},dispose:function(t,e){i.each(this._features,function(i){i[Q]&&i[Q](t,e)})}})}),e("echarts/component/toolbox/feature/SaveAsImage",[qi,"../featureManager"],function(t){function e(t){this.model=t}e.defaultOption={show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6 M29.2,45.1L29.2,0",title:"保存为图片",type:"png",name:"",excludeComponents:["toolbox"],pixelRatio:1};var i=e[Wi];return i.onclick=function(t,e){var i=this.model,n=t.get("title.0.text")||"echarts",r=document[Ni]("a"),a=i.get("type",!0)||"png";r.download=n+"."+a,r[oe]="_blank",r.href=e.getConnectedDataURL({type:a,backgroundColor:i.get(tt,!0)||t.get(tt)||"#fff",excludeComponents:i.get("excludeComponents"),pixelRatio:i.get("pixelRatio")}),r.click()},t("../featureManager")[Te]("saveAsImage",e),e}),e("echarts/component/toolbox/feature/MagicType",[qi,Hi,"../../../echarts","../featureManager"],function(t){function e(t){this.model=t}var i=t(Hi);e.defaultOption={show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z", -tiled:"M2.3,2.2h22.8V25H2.3V2.2z M35,2.2h22.8V25H35V2.2zM2.3,35h22.8v22.8H2.3V35z M35,35h22.8v22.8H35V35z"},title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"},option:{},seriesIndex:{}};var n=e[Wi];n.getIcons=function(){var t=this.model,e=t.get("icon"),n={};return i.each(t.get("type"),function(t){e[t]&&(n[t]=e[t])}),n};var r={line:function(t,e,n,r){return"bar"===t?i.merge({id:e,type:"line",data:n.get("data"),stack:n.get("stack")},r.get("option.line")):void 0},bar:function(t,e,n,r){return"line"===t?i.merge({id:e,type:"bar",data:n.get("data"),stack:n.get("stack")},r.get("option.bar")):void 0},stack:function(t,e,i,n){return"line"===t||"bar"===t?{id:e,stack:"__ec_magicType_stack__"}:void 0},tiled:function(t,e,i,n){return"line"===t||"bar"===t?{id:e,stack:""}:void 0}},a=[["line","bar"],["stack","tiled"]];n.onclick=function(t,e,n){var o=this.model,s=o.get("seriesIndex."+n);if(r[n]){var l={series:[]},c=function(t){var e=t.subType,a=t.id,s=r[n](e,a,t,o);s&&(i[oi](s,t[Ke]),l[Be].push(s))};i.each(a,function(t){i[Bi](t,n)>=0&&i.each(t,function(t){o.setIconStatus(t,Me)})}),o.setIconStatus(n,Se),t[W]({mainType:"series",seriesIndex:s},c),e[De]({type:"changeMagicType",currentType:n,newOption:l})}};var o=t("../../../echarts");return o[F]({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(t,e){e[Ze](t.newOption)}),t("../featureManager")[Te]("magicType",e),e}),e("echarts/component/toolbox/feature/DataView",[qi,Hi,ft,"../featureManager","../../../echarts"],function(t){function e(t){var e={},i=[],n=[];return t.eachRawSeries(function(t){var r=t[C];if(!r||"cartesian2d"!==r.type&&"polar"!==r.type)i.push(t);else{var a=r[p]();if(a.type===A){var o=a.dim+"_"+a.index;e[o]||(e[o]={categoryAxis:a,valueAxis:r[f](a),series:[]},n.push({axisDim:a.dim,axisIndex:a.index})),e[o][Be].push(t)}else i.push(t)}}),{seriesGroupByCategoryAxis:e,other:i,meta:n}}function i(t){var e=[];return d.each(t,function(t,i){var n=t.categoryAxis,r=t.valueAxis,a=r.dim,o=[" "][Ii](d.map(t[Be],function(t){return t.name})),s=[n.model.getCategories()];d.each(t[Be],function(t){s.push(t.getRawData()[O](a,function(t){return t}))});for(var l=[o.join(g)],c=0;co;o++)n[o]=arguments[o];i.push((a?a+g:"")+n.join(g))}),i.join("\n")}).join("\n\n"+m+"\n\n")}function r(t){var r=e(t);return{value:d[Gi]([i(r.seriesGroupByCategoryAxis),n(r.other)],function(t){return t[Qe](/[\n\t\s]/g,"")}).join("\n\n"+m+"\n\n"),meta:r.meta}}function a(t){return t[Qe](/^\s\s*/,"")[Qe](/\s\s*$/,"")}function o(t){var e=t.slice(0,t[Bi]("\n"));return e[Bi](g)>=0?!0:void 0}function s(t){for(var e=t.split(/\n+/g),i=a(e.shift()).split(y),n=[],r=d.map(i,function(t){return{name:t,data:[]}}),o=0;ow}function c(t){var e=k[this.type];t&&t[Vi]?(this._cover||(this._cover=e[pi].call(this),this.group.add(this._cover)),e[at].call(this,t)):(this.group[Qt](this._cover),this._cover=null)}function h(){var t=this.group,e=t[he];e&&e[Qt](t)}function u(){var t=this.opt;return new m.Rect({style:{stroke:t[wi],fill:t.fill,lineWidth:t[Mi],opacity:t[bi]}})}function d(){return v.map(this._track,function(t){return this.group[se](t[0],t[1])},this)}function f(){var t=d.call(this),e=t[Vi]-1;return 0>e&&(e=0),[t[0],t[e]]}var p=t(fe),v=t(Hi),m=t(S),g=v.bind,y=v.each,_=Math.min,x=Math.max,b=Math.pow,w=2,M=["mousedown",dt,"mouseup"];e[Wi]={constructor:e,enable:function(t,e){this._disabled=!1,h.call(this),this._containerRect=e!==!1?e||t[ei]():null,t.add(this.group)},update:function(t){c.call(this,t&&v.clone(t))},disable:function(){this._disabled=!0,h.call(this)},dispose:function(){this.disable(),y(M,function(t){this.zr.off(t,this._handlers[t])},this)}},v.mixin(e,p);var k={line:{create:u,getRanges:function(){var t=f.call(this),e=_(t[0][0],t[1][0]),i=x(t[0][0],t[1][0]);return[[e,i]]},update:function(t){var e=t[0],i=this.opt.width;this._cover[Ct]({x:e[0],y:-i/2,width:e[1]-e[0],height:i})}},rect:{create:u,getRanges:function(){var t=f.call(this),e=[_(t[1][0],t[0][0]),_(t[1][1],t[0][1])],i=[x(t[1][0],t[0][0]),x(t[1][1],t[0][1])];return[[[e[0],i[0]],[e[1],i[1]]]]},update:function(t){var e=t[0];this._cover[Ct]({x:e[0][0],y:e[1][0],width:e[0][1]-e[0][0],height:e[1][1]-e[1][0]})}}};return e}),e("echarts/component/dataZoom/history",[qi,Hi],function(t){function e(t){var e=t[r];return e||(e=t[r]=[{}]),e}var i=t(Hi),n=i.each,r="\x00_ec_hist_store",a={push:function(t,i){var r=e(t);n(i,function(e,i){for(var n=r[Vi]-1;n>=0;n--){var a=r[n];if(a[i])break}if(0>n){var o=t.queryComponents({mainType:"dataZoom",subType:"select",id:i})[0];if(o){var s=o.getPercentRange();r[0][i]={dataZoomId:i,start:s[0],end:s[1]}}}}),r.push(i)},pop:function(t){var i=e(t),r=i[i[Vi]-1];i[Vi]>1&&i.pop();var a={};return n(r,function(t,e){for(var n=i[Vi]-1;n>=0;n--){var t=i[n][e];if(t){a[e]=t;break}}}),a},clear:function(t){t[r]=null},count:function(t){return e(t)[Vi]}};return a}),e("echarts/component/dataZoom/SelectZoomModel",[qi,"./DataZoomModel"],function(t){var e=t("./DataZoomModel");return e[Di]({type:"dataZoom.select"})}),e("echarts/component/dataZoom/SelectZoomView",[qi,"./DataZoomView"],function(t){return t("./DataZoomView")[Di]({type:"dataZoom.select"})}),e("echarts/component/dataZoomSelect",[qi,"./dataZoom/typeDefaulter","./dataZoom/DataZoomModel","./dataZoom/DataZoomView","./dataZoom/SelectZoomModel","./dataZoom/SelectZoomView","./dataZoom/dataZoomProcessor","./dataZoom/dataZoomAction"],function(t){t("./dataZoom/typeDefaulter"),t("./dataZoom/DataZoomModel"),t("./dataZoom/DataZoomView"),t("./dataZoom/SelectZoomModel"),t("./dataZoom/SelectZoomView"),t("./dataZoom/dataZoomProcessor"),t("./dataZoom/dataZoomAction")}),e("echarts/component/toolbox/feature/DataZoom",[qi,Hi,"../../../util/number","../../helper/SelectController",gi,"zrender/container/Group","../../dataZoom/history","../../helper/interactionMutex","../../dataZoomSelect","../featureManager","../../../echarts"],function(t){function e(t){this.model=t,this._controllerGroup,this._controller,this._isZoomActive}function i(t,e){var i=[{axisModel:t[h]("x").model,axisIndex:0},{axisModel:t[h]("y").model,axisIndex:0}];return i.grid=t,e[W]({mainType:"dataZoom",subType:"select"},function(t,r){n("xAxis",i[0].axisModel,t,e)&&(i[0].dataZoomModel=t),n("yAxis",i[1].axisModel,t,e)&&(i[1].dataZoomModel=t)}),i}function n(t,e,i,n){var r=i.get(t+"Index");return null!=r&&n[Ce](t,r)===e}function a(t,e){var i=e.grid,n=new d(t[0][0],t[1][0],t[0][1]-t[0][0],t[1][1]-t[1][0]);if(n[nt](i[r]())){var a=i.getCartesian(e[0][ke],e[1][ke]),o=a.pointToData([t[0][0],t[1][0]],!0),s=a.pointToData([t[0][1],t[1][1]],!0);return[g([o[0],s[0]]),g([o[1],s[1]])]}}function o(t,e,i,n){var r=e[i],a=r.dataZoomModel;return{dataZoomId:a.id,startValue:t[i][0],endValue:t[i][1]}}function s(t,e){t.setIconStatus("back",p.count(e)>1?Se:Me)}var l=t(Hi),c=t("../../../util/number"),u=t("../../helper/SelectController"),d=t(gi),f=t("zrender/container/Group"),p=t("../../dataZoom/history"),v=t("../../helper/interactionMutex"),m=l.each,g=c.asc;t("../../dataZoomSelect");var y="\x00_ec_\x00toolbox-dataZoom_";e.defaultOption={show:!0,icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:{zoom:"区域缩放",back:"区域缩放还原"}};var _=e[Wi];_[Wt]=function(t,e,i){s(t,e)},_.onclick=function(t,e,i){var n=this._controllerGroup;this._controllerGroup||(n=this._controllerGroup=new f,e.getZr().add(n)),x[i].call(this,n,this.model,t,e)},_[Qt]=function(t,e){this._disposeController(),v.release("globalPan",e.getZr())},_[Q]=function(t,e){var i=e.getZr();v.release("globalPan",i),this._disposeController(),this._controllerGroup&&i[Qt](this._controllerGroup)};var x={zoom:function(t,e,i,n){var r=this._isZoomActive=!this._isZoomActive,a=n.getZr();v[r?"take":"release"]("globalPan",a),e.setIconStatus("zoom",r?Se:Me),r?(a.setDefaultCursorStyle("crosshair"),this._createController(t,e,i,n)):(a.setDefaultCursorStyle("default"),this._disposeController())},back:function(t,e,i,n){this._dispatchAction(p.pop(i),n)}};return _._createController=function(t,e,i,n){var r=this._controller=new u("rect",n.getZr(),{lineWidth:3,stroke:"#333",fill:"rgba(0,0,0,0.2)"});r.on("selectEnd",l.bind(this._onSelected,this,r,e,i,n)),r.enable(t,!1)},_._disposeController=function(){var t=this._controller;t&&(t.off("selected"),t[Q]())},_._onSelected=function(t,e,n,r,s){if(s[Vi]){var l=s[0];t[at]();var c={};n[W]("grid",function(t,e){var r=t[C],s=i(r,n),h=a(l,s);if(h){var u=o(h,s,0,"x"),d=o(h,s,1,"y");u&&(c[u.dataZoomId]=u),d&&(c[d.dataZoomId]=d)}},this),p.push(n,c),this._dispatchAction(c,r)}},_._dispatchAction=function(t,e){var i=[];m(t,function(t){i.push(t)}),i[Vi]&&e[De]({type:"dataZoom",from:this.uid,batch:l.clone(i,!0)})},t("../featureManager")[Te](q,e),t("../../../echarts").registerPreprocessor(function(t){function e(t){i(t,function(e,i){var r={type:"select",$fromToolbox:!0,id:y+t+i};r[t+"Index"]=i,n.push(r)})}function i(e,i){var n=t[e];l[ki](n)||(n=n?[n]:[]),m(n,i)}if(t){var n=t[q]||(t[q]=[]);l[ki](n)||(n=[n]);var r=t.toolbox;r&&(l[ki](r)&&(r=r[0]),r&&r.feature&&r.feature[q]&&(e("xAxis"),e("yAxis")))}}),e}),e("echarts/component/toolbox/feature/Restore",[qi,"../../dataZoom/history","../featureManager","../../../echarts"],function(t){function e(t){this.model=t}var i=t("../../dataZoom/history");e.defaultOption={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:"还原"};var n=e[Wi];return n.onclick=function(t,e,n){i.clear(t),e[De]({type:"restore",from:this.uid})},t("../featureManager")[Te](Tt,e),t("../../../echarts")[F]({type:"restore",event:"restore",update:"prepareAndUpdate"},function(t,e){e.resetOption("recreate")}),e}),e("echarts/component/toolbox",[qi,"./toolbox/ToolboxModel","./toolbox/ToolboxView","./toolbox/feature/SaveAsImage","./toolbox/feature/MagicType","./toolbox/feature/DataView","./toolbox/feature/DataZoom","./toolbox/feature/Restore"],function(t){t("./toolbox/ToolboxModel"),t("./toolbox/ToolboxView"),t("./toolbox/feature/SaveAsImage"),t("./toolbox/feature/MagicType"),t("./toolbox/feature/DataView"),t("./toolbox/feature/DataZoom"),t("./toolbox/feature/Restore")}),e("zrender/vml/core",[qi,"../core/env"],function(t){function e(){if(!o){o=!0;var t=a.styleSheets;t[Vi]<31?a.createStyleSheet().addRule(".zrvml","behavior:url(#default#VML)"):t[0].addRule(".zrvml","behavior:url(#default#VML)")}}if(!t("../core/env")[K]){var i,n="urn:schemas-microsoft-com:vml",r=window,a=r.document,o=!1;try{!a.namespaces.zrvml&&a.namespaces.add("zrvml",n),i=function(t){return a[Ni]("')}}catch(s){i=function(t){return a[Ni]("<"+t+' xmlns="'+n+'" class="zrvml">')}}return{doc:a,initVML:e,createNode:i}}}),e("zrender/vml/graphic",[qi,"../core/env","../core/vector",ui,"../core/PathProxy","../tool/color","../contain/text","../graphic/mixin/RectText","../graphic/Displayable","../graphic/Image","../graphic/Text","../graphic/Path","../graphic/Gradient","./core"],function(t){function e(t){t.style.cssText="position:absolute;left:0;top:0;width:1px;height:1px;",t.coordsize=V+","+V,t.coordorigin="0,0"}function n(t){return String(t)[Qe](/&/g,"&")[Qe](/"/g,""")}function r(t,e,i){return"rgb("+[t,e,i].join(",")+")"}function a(t,e){e&&t&&e[ct]!==t&&t[et](e)}function o(t,e){e&&t&&e[ct]===t&&t.removeChild(e)}function s(t,e,i){return(parseFloat(t)||0)*G+(parseFloat(e)||0)*H+i}function l(t,e,i){var n=w.parse(e);i=+i,isNaN(i)&&(i=1),n&&(t.color=r(n[0],n[1],n[2]),t[bi]=i*n[3])}function c(t){var e=w.parse(t);return[r(e[0],e[1],e[2]),e[3]]}function h(t,e,i){var n=e.fill;if(null!=n)if(n instanceof D){var r,a=0,o=[0,0],s=0,h=1,u=i[ei](),d=u.width,f=u[vi];if("linear"===n.type){r="gradient";var p=i[ue],v=[n.x*d,n.y*f],m=[n.x2*d,n.y2*f];p&&(Z(v,v,p),Z(m,m,p));var g=m[0]-v[0],y=m[1]-v[1];a=180*Math.atan2(g,y)/Math.PI,0>a&&(a+=360),1e-6>a&&(a=0)}else{r="gradientradial";var v=[n.x*d,n.y*f],p=i[ue],_=i.scale,x=d,b=f;o=[(v[0]-u.x)/x,(v[1]-u.y)/b],p&&Z(v,v,p),x/=_[0]*V,b/=_[1]*V;var w=B(x,b);s=0/w,h=2*n.r/w-s}var M=n.colorStops.slice();M.sort(function(t,e){return t.offset-e.offset});for(var S=M[Vi],k=[],A=[],C=0;S>C;C++){var T=M[C],L=c(T.color);A.push(T.offset*h+s+" "+L[0]),(0===C||C===S-1)&&k.push(L)}if(S>=2){var z=k[0][0],P=k[1][0],I=k[0][1]*e[bi],O=k[1][1]*e[bi];t.type=r,t.method="none",t.focus="100%",t.angle=a,t.color=z,t.color2=P,t.colors=A.join(","),t[bi]=O,t.opacity2=I}"radial"===r&&(t.focusposition=o.join(","))}else l(t,n,e[bi])}function u(t,e){null!=e.lineJoin&&(t.joinstyle=e.lineJoin),null!=e.miterLimit&&(t.miterlimit=e.miterLimit*V),null!=e.lineCap&&(t.endcap=e.lineCap),null!=e.lineDash&&(t.dashstyle=e.lineDash.join(" ")),null==e[wi]||e[wi]instanceof D||l(t,e[wi],e[bi])}function d(t,e,i,n){var r="fill"==e,s=t.getElementsByTagName(e)[0];null!=i[e]&&"none"!==i[e]&&(r||!r&&i[Mi])?(t[r?"filled":"stroked"]="true",i[e]instanceof D&&o(t,s),s||(s=L.createNode(e)),r?h(s,i,n):u(s,i),a(t,s)):(t[r?"filled":"stroked"]="false",o(t,s))}function f(t,e){var i,n,r,a,o,s,l=b.M,c=b.C,h=b.L,u=b.A,d=b.Q,f=[];for(a=0;a0){f.push(n);for(var U=0;i>U;U++){var X=W[U];e&&Z(X,X,e),f.push(z(X[0]*V-F),E,z(X[1]*V-F),i-1>U?E:"")}}}return f.join("")}function p(t){return typeof t===Fi&&t.tagName&&"IMG"===t.tagName[qe]()}function v(t){var e=U[t];if(!e){X>$&&(X=0,U={});var i,n=Y.style;try{n.font=t,i=n.fontFamily.split(",")[0]}catch(r){}e={style:n.fontStyle||j,variant:n.fontVariant||j,weight:n.fontWeight||j,size:0|parseFloat(n.fontSize||12),family:i||"Microsoft YaHei"},U[t]=e,X++}return e}function m(t,i,r,o){var l=this.style,c=l.text;if(c){var h,u,f=l[Zt],p=v(l.textFont),m=p.style+" "+p.variant+" "+p.weight+" "+p.size+'px "'+p.family+'"',g=l[Bt];r=r||M[ei](c,m,f,g);var y=this[ue];if(y&&!o&&(Q.copy(i),Q[mi](y),i=Q),o)h=i.x,u=i.y;else{var _=l[Et],x=l.textDistance;if(_ instanceof Array)h=i.x+_[0],u=i.y+_[1],f=f||"left",g=g||"top";else{var b=M.adjustTextPositionOnRect(_,i,r,x);h=b.x,u=b.y,f=f||b[Zt],g=g||b[Bt]}}var w=p.size;switch(g){case"hanging":case"top":u+=w/1.75;break;case ci:break;default:u-=w/2.25}switch(f){case"left":break;case li:h-=r.width/2;break;case"right":h-=r.width}var S,k,A,C=L.createNode,T=this._textVmlEl;T?(A=T.firstChild,S=A.nextSibling,k=S.nextSibling):(T=C("line"),S=C("path"),k=C("textpath"),A=C("skew"),k.style["v-text-align"]="left",e(T),S.textpathok=!0,k.on=!0,T.from="0 0",T.to="1000 0.05",a(T,A),a(T,S),a(T,k),this._textVmlEl=T);var D=[h,u],P=T.style;y&&o?(Z(D,D,y),A.on=!0,A.matrix=y[0][Xe](3)+E+y[2][Xe](3)+E+y[1][Xe](3)+E+y[3][Xe](3)+",0,0",A.offset=(z(D[0])||0)+","+(z(D[1])||0),A.origin="0 0",P.left="0px",P.top="0px"):(A.on=!1,P.left=z(h)+"px",P.top=z(u)+"px"),k[Ri]=n(c);try{k.style.font=m}catch(I){}d(T,"fill",{fill:o?l.fill:l.textFill,opacity:l[bi]},this),d(T,wi,{stroke:o?l[wi]:l.textStroke,opacity:l[bi],lineDash:l.lineDash},this),T.style.zIndex=s(this[ot],this.z,this.z2),a(t,T)}}function g(t){o(t,this._textVmlEl),this._textVmlEl=null}function y(t){a(t,this._textVmlEl)}if(!t("../core/env")[K]){var _=t("../core/vector"),x=t(ui),b=t("../core/PathProxy").CMD,w=t("../tool/color"),M=t("../contain/text"),S=t("../graphic/mixin/RectText"),k=t("../graphic/Displayable"),A=t("../graphic/Image"),C=t("../graphic/Text"),T=t("../graphic/Path"),D=t("../graphic/Gradient"),L=t("./core"),z=Math.round,P=Math.sqrt,I=Math.abs,O=Math.cos,R=Math.sin,B=Math.max,Z=_[mi],E=",",N="progid:DXImageTransform.Microsoft",V=21600,F=V/2,G=1e5,H=1e3,W=[[],[],[]];T[Wi].brush=function(t){var i=this.style,n=this._vmlEl;n||(n=L.createNode("shape"),e(n),this._vmlEl=n),d(n,"fill",i,this),d(n,wi,i,this);var r=this[ue],o=null!=r,l=n.getElementsByTagName(wi)[0];if(l){var c=i[Mi];if(o&&!i.strokeNoScale){var h=r[0]*r[3]-r[1]*r[2];c*=P(I(h))}l.weight=c+"px"}var u=this.path;this.__dirtyPath&&(u[Ot](),this[Dt](u,this.shape),this.__dirtyPath=!1),n.path=f(u.data,this[ue]),n.style.zIndex=s(this[ot],this.z,this.z2),a(t,n),i.text&&this.drawRectText(t,this[ei]())},T[Wi].onRemoveFromStorage=function(t){o(t,this._vmlEl),this.removeRectText(t)},T[Wi].onAddToStorage=function(t){a(t,this._vmlEl),this.appendRectText(t)},A[Wi].brush=function(t){var n,r,o=this.style,l=o.image;if(p(l)){var c=l.src;if(c===this._imageSrc)n=this._imageWidth,r=this._imageHeight;else{var h=l.runtimeStyle,u=h.width,d=h[vi];h.width="auto",h[vi]="auto",n=l.width,r=l[vi],h.width=u,h[vi]=d,this._imageSrc=c,this._imageWidth=n,this._imageHeight=r}l=c}else l===this._imageSrc&&(n=this._imageWidth,r=this._imageHeight);if(l){var f=o.x||0,v=o.y||0,m=o.width,g=o[vi],y=o.sWidth,_=o.sHeight,x=o.sx||0,b=o.sy||0,w=y&&_,M=this._vmlEl;M||(M=L.doc[Ni]("div"),e(M),this._vmlEl=M);var S,k=M.style,A=!1,C=1,T=1;if(this[ue]&&(S=this[ue],C=P(S[0]*S[0]+S[1]*S[1]),T=P(S[2]*S[2]+S[3]*S[3]),A=S[1]||S[2]),A){var D=[f,v],I=[f+m,v],O=[f,v+g],R=[f+m,v+g];Z(D,D,S),Z(I,I,S),Z(O,O,S),Z(R,R,S);var V=B(D[0],I[0],O[0],R[0]),F=B(D[1],I[1],O[1],R[1]),G=[];G.push("M11=",S[0]/C,E,"M12=",S[2]/T,E,"M21=",S[1]/C,E,"M22=",S[3]/T,E,"Dx=",z(f*C+S[4]),E,"Dy=",z(v*T+S[5])),k[i]="0 "+z(V)+"px "+z(F)+"px 0",k[Gi]=N+".Matrix("+G.join("")+", SizingMethod=clip)"}else S&&(f=f*C+S[4],v=v*T+S[5]),k[Gi]="",k.left=z(f)+"px",k.top=z(v)+"px";var H=this._imageEl,W=this._cropEl;H||(H=L.doc[Ni]("div"),this._imageEl=H);var q=H.style;if(w){if(n&&r)q.width=z(C*n*m/y)+"px",q[vi]=z(T*r*g/_)+"px";else{var j=new Image,U=this;j.onload=function(){j.onload=null,n=j.width,r=j[vi],q.width=z(C*n*m/y)+"px",q[vi]=z(T*r*g/_)+"px",U._imageWidth=n,U._imageHeight=r,U._imageSrc=l},j.src=l}W||(W=L.doc[Ni]("div"),W.style.overflow="hidden",this._cropEl=W);var X=W.style;X.width=z((m+x*m/y)*C),X[vi]=z((g+b*g/_)*T),X[Gi]=N+".Matrix(Dx="+-x*m/y*C+",Dy="+-b*g/_*T+")",W[ct]||M[et](W),H[ct]!=W&&W[et](H)}else q.width=z(C*m)+"px",q[vi]=z(T*g)+"px",M[et](H),W&&W[ct]&&(M.removeChild(W),this._cropEl=null);var $="",Y=o[bi];1>Y&&($+=".Alpha(opacity="+z(100*Y)+") "),$+=N+".AlphaImageLoader(src="+l+", SizingMethod=scale)",q[Gi]=$,M.style.zIndex=s(this[ot],this.z,this.z2),a(t,M),o.text&&this.drawRectText(t,this[ei]())}},A[Wi].onRemoveFromStorage=function(t){o(t,this._vmlEl),this._vmlEl=null,this._cropEl=null,this._imageEl=null,this.removeRectText(t)},A[Wi].onAddToStorage=function(t){a(t,this._vmlEl),this.appendRectText(t)};var q,j=Me,U={},X=0,$=100,Y=document[Ni]("div");M.measureText=function(t,e){var i=L.doc;q||(q=i[Ni]("div"),q.style.cssText="position:absolute;top:-20000px;left:0; padding:0;margin:0;border:none;white-space:pre;",L.doc.body[et](q));try{q.style.font=e}catch(n){}return q[it]="",q[et](i.createTextNode(t)),{width:q.offsetWidth}};for(var Q=new x,J=[S,k,A,T,C],tt=0;tt=11)}}function n(t,e){"createCanvas"===t&&(yf=null),mf[t]=e}function i(t){if(null==t||"object"!=typeof t)return t;var e=t,n=hf.call(t);if("[object Array]"===n){if(!B(t)){e=[];for(var r=0,a=t.length;a>r;r++)e[r]=i(t[r])}}else if(lf[n]){if(!B(t)){var o=t.constructor;if(t.constructor.from)e=o.from(t);else{e=new o(t.length);for(var r=0,a=t.length;a>r;r++)e[r]=i(t[r])}}}else if(!sf[n]&&!B(t)&&!T(t)){e={};for(var s in t)t.hasOwnProperty(s)&&(e[s]=i(t[s]))}return e}function r(t,e,n){if(!S(e)||!S(t))return n?i(e):t;for(var a in e)if(e.hasOwnProperty(a)){var o=t[a],s=e[a];!S(s)||!S(o)||_(s)||_(o)||T(s)||T(o)||M(s)||M(o)||B(s)||B(o)?!n&&a in t||(t[a]=i(e[a],!0)):r(o,s,n)}return t}function a(t,e){for(var n=t[0],i=1,a=t.length;a>i;i++)n=r(n,t[i],e);return n}function o(t,e){for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t}function s(t,e,n){for(var i in e)e.hasOwnProperty(i)&&(n?null!=e[i]:null==t[i])&&(t[i]=e[i]);return t}function l(){return yf||(yf=vf().getContext("2d")),yf}function h(t,e){if(t){if(t.indexOf)return t.indexOf(e);for(var n=0,i=t.length;i>n;n++)if(t[n]===e)return n}return-1}function u(t,e){function n(){}var i=t.prototype;n.prototype=e.prototype,t.prototype=new n;for(var r in i)t.prototype[r]=i[r];t.prototype.constructor=t,t.superClass=e}function c(t,e,n){t="prototype"in t?t.prototype:t,e="prototype"in e?e.prototype:e,s(t,e,n)}function d(t){return t?"string"==typeof t?!1:"number"==typeof t.length:void 0}function f(t,e,n){if(t&&e)if(t.forEach&&t.forEach===cf)t.forEach(e,n);else if(t.length===+t.length)for(var i=0,r=t.length;r>i;i++)e.call(n,t[i],i,t);else for(var a in t)t.hasOwnProperty(a)&&e.call(n,t[a],a,t)}function p(t,e,n){if(t&&e){if(t.map&&t.map===pf)return t.map(e,n);for(var i=[],r=0,a=t.length;a>r;r++)i.push(e.call(n,t[r],r,t));return i}}function g(t,e,n,i){if(t&&e){if(t.reduce&&t.reduce===gf)return t.reduce(e,n,i);for(var r=0,a=t.length;a>r;r++)n=e.call(i,n,t[r],r,t);return n}}function m(t,e,n){if(t&&e){if(t.filter&&t.filter===df)return t.filter(e,n);for(var i=[],r=0,a=t.length;a>r;r++)e.call(n,t[r],r,t)&&i.push(t[r]);return i}}function v(t,e,n){if(t&&e)for(var i=0,r=t.length;r>i;i++)if(e.call(n,t[i],i,t))return t[i]}function y(t,e){var n=ff.call(arguments,2);return function(){return t.apply(e,n.concat(ff.call(arguments)))}}function x(t){var e=ff.call(arguments,1);return function(){return t.apply(this,e.concat(ff.call(arguments)))}}function _(t){return"[object Array]"===hf.call(t)}function w(t){return"function"==typeof t}function b(t){return"[object String]"===hf.call(t)}function S(t){var e=typeof t;return"function"===e||!!t&&"object"==e}function M(t){return!!sf[hf.call(t)]}function I(t){return!!lf[hf.call(t)]}function T(t){return"object"==typeof t&&"number"==typeof t.nodeType&&"object"==typeof t.ownerDocument}function C(t){return t!==t}function D(){for(var t=0,e=arguments.length;e>t;t++)if(null!=arguments[t])return arguments[t]}function A(t,e){return null!=t?t:e}function k(t,e,n){return null!=t?t:null!=e?e:n}function P(){return Function.call.apply(ff,arguments)}function L(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 O(t,e){if(!t)throw new Error(e)}function z(t){return null==t?null:"function"==typeof t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}function R(t){t[xf]=!0}function B(t){return t[xf]}function E(t){function e(t,e){n?i.set(t,e):i.set(e,t)}var n=_(t),i=this;t instanceof E?t.each(e):t&&f(t,e)}function N(t){return new E(t)}function F(t,e){for(var n=new t.constructor(t.length+e.length),i=0;iRf||-Rf>t}function Se(t){this._target=t.target,this._life=t.life||1e3,this._delay=t.delay||0,this._initialized=!1,this.loop=null==t.loop?!1:t.loop,this.gap=t.gap||0,this.easing=t.easing||"Linear",this.onframe=t.onframe,this.ondestroy=t.ondestroy,this.onrestart=t.onrestart,this._pausedTime=0,this._paused=!1}function Me(t){return t=Math.round(t),0>t?0:t>255?255:t}function Ie(t){return t=Math.round(t),0>t?0:t>360?360:t}function Te(t){return 0>t?0:t>1?1:t}function Ce(t){return Me(t.length&&"%"===t.charAt(t.length-1)?parseFloat(t)/100*255:parseInt(t,10))}function De(t){return Te(t.length&&"%"===t.charAt(t.length-1)?parseFloat(t)/100:parseFloat(t))}function Ae(t,e,n){return 0>n?n+=1:n>1&&(n-=1),1>6*n?t+(e-t)*n*6:1>2*n?e:2>3*n?t+(e-t)*(2/3-n)*6:t}function ke(t,e,n){return t+(e-t)*n}function Pe(t,e,n,i,r){return t[0]=e,t[1]=n,t[2]=i,t[3]=r,t}function Le(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}function Oe(t,e){Yf&&Le(Yf,e),Yf=Uf.put(t,Yf||e.slice())}function ze(t,e){if(t){e=e||[];var n=Uf.get(t);if(n)return Le(e,n);t+="";var i=t.replace(/ /g,"").toLowerCase();if(i in Zf)return Le(e,Zf[i]),Oe(t,e),e;if("#"!==i.charAt(0)){var r=i.indexOf("("),a=i.indexOf(")");if(-1!==r&&a+1===i.length){var o=i.substr(0,r),s=i.substr(r+1,a-(r+1)).split(","),l=1;switch(o){case"rgba":if(4!==s.length)return void Pe(e,0,0,0,1);l=De(s.pop());case"rgb":return 3!==s.length?void Pe(e,0,0,0,1):(Pe(e,Ce(s[0]),Ce(s[1]),Ce(s[2]),l),Oe(t,e),e);case"hsla":return 4!==s.length?void Pe(e,0,0,0,1):(s[3]=De(s[3]),Re(s,e),Oe(t,e),e);case"hsl":return 3!==s.length?void Pe(e,0,0,0,1):(Re(s,e),Oe(t,e),e);default:return}}Pe(e,0,0,0,1)}else{if(4===i.length){var h=parseInt(i.substr(1),16);return h>=0&&4095>=h?(Pe(e,(3840&h)>>4|(3840&h)>>8,240&h|(240&h)>>4,15&h|(15&h)<<4,1),Oe(t,e),e):void Pe(e,0,0,0,1)}if(7===i.length){var h=parseInt(i.substr(1),16);return h>=0&&16777215>=h?(Pe(e,(16711680&h)>>16,(65280&h)>>8,255&h,1),Oe(t,e),e):void Pe(e,0,0,0,1)}}}}function Re(t,e){var n=(parseFloat(t[0])%360+360)%360/360,i=De(t[1]),r=De(t[2]),a=.5>=r?r*(i+1):r+i-r*i,o=2*r-a;return e=e||[],Pe(e,Me(255*Ae(o,a,n+1/3)),Me(255*Ae(o,a,n)),Me(255*Ae(o,a,n-1/3)),1),4===t.length&&(e[3]=t[3]),e}function Be(t){if(t){var e,n,i=t[0]/255,r=t[1]/255,a=t[2]/255,o=Math.min(i,r,a),s=Math.max(i,r,a),l=s-o,h=(s+o)/2;if(0===l)e=0,n=0;else{n=.5>h?l/(s+o):l/(2-s-o);var u=((s-i)/6+l/2)/l,c=((s-r)/6+l/2)/l,d=((s-a)/6+l/2)/l;i===s?e=d-c:r===s?e=1/3+u-d:a===s&&(e=2/3+c-u),0>e&&(e+=1),e>1&&(e-=1)}var f=[360*e,n,h];return null!=t[3]&&f.push(t[3]),f}}function Ee(t,e){var n=ze(t);if(n){for(var i=0;3>i;i++)n[i]=0>e?n[i]*(1-e)|0:(255-n[i])*e+n[i]|0;return We(n,4===n.length?"rgba":"rgb")}}function Ne(t){var e=ze(t);return e?((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1):void 0}function Fe(t,e,n){if(e&&e.length&&t>=0&&1>=t){n=n||[];var i=t*(e.length-1),r=Math.floor(i),a=Math.ceil(i),o=e[r],s=e[a],l=i-r;return n[0]=Me(ke(o[0],s[0],l)),n[1]=Me(ke(o[1],s[1],l)),n[2]=Me(ke(o[2],s[2],l)),n[3]=Te(ke(o[3],s[3],l)),n}}function Ge(t,e,n){if(e&&e.length&&t>=0&&1>=t){var i=t*(e.length-1),r=Math.floor(i),a=Math.ceil(i),o=ze(e[r]),s=ze(e[a]),l=i-r,h=We([Me(ke(o[0],s[0],l)),Me(ke(o[1],s[1],l)),Me(ke(o[2],s[2],l)),Te(ke(o[3],s[3],l))],"rgba");return n?{color:h,leftIndex:r,rightIndex:a,value:i}:h}}function Ve(t,e,n,i){return t=ze(t),t?(t=Be(t),null!=e&&(t[0]=Ie(e)),null!=n&&(t[1]=De(n)),null!=i&&(t[2]=De(i)),We(Re(t),"rgba")):void 0}function He(t,e){return t=ze(t),t&&null!=e?(t[3]=Te(e),We(t,"rgba")):void 0}function We(t,e){if(t&&t.length){var n=t[0]+","+t[1]+","+t[2];return("rgba"===e||"hsva"===e||"hsla"===e)&&(n+=","+t[3]),e+"("+n+")"}}function Xe(t,e){return t[e]}function Ze(t,e,n){t[e]=n}function Ue(t,e,n){return(e-t)*n+t}function Ye(t,e,n){return n>.5?e:t}function je(t,e,n,i,r){var a=t.length;if(1==r)for(var o=0;a>o;o++)i[o]=Ue(t[o],e[o],n);else for(var s=a&&t[0].length,o=0;a>o;o++)for(var l=0;s>l;l++)i[o][l]=Ue(t[o][l],e[o][l],n)}function qe(t,e,n){var i=t.length,r=e.length;if(i!==r){var a=i>r;if(a)t.length=r;else for(var o=i;r>o;o++)t.push(1===n?e[o]:Kf.call(e[o]))}for(var s=t[0]&&t[0].length,o=0;ol;l++)isNaN(t[o][l])&&(t[o][l]=e[o][l])}function $e(t,e,n){if(t===e)return!0;var i=t.length;if(i!==e.length)return!1;if(1===n){for(var r=0;i>r;r++)if(t[r]!==e[r])return!1}else for(var a=t[0].length,r=0;i>r;r++)for(var o=0;a>o;o++)if(t[r][o]!==e[r][o])return!1;return!0}function Ke(t,e,n,i,r,a,o,s,l){var h=t.length;if(1==l)for(var u=0;h>u;u++)s[u]=Je(t[u],e[u],n[u],i[u],r,a,o);else for(var c=t[0].length,u=0;h>u;u++)for(var d=0;c>d;d++)s[u][d]=Je(t[u][d],e[u][d],n[u][d],i[u][d],r,a,o)}function Je(t,e,n,i,r,a,o){var s=.5*(n-t),l=.5*(i-e);return(2*(e-n)+s+l)*o+(-3*(e-n)-2*s-l)*a+s*r+e}function Qe(t){if(d(t)){var e=t.length;if(d(t[0])){for(var n=[],i=0;e>i;i++)n.push(Kf.call(t[i]));return n}return Kf.call(t)}return t}function tn(t){return t[0]=Math.floor(t[0]),t[1]=Math.floor(t[1]),t[2]=Math.floor(t[2]),"rgba("+t.join(",")+")"}function en(t){var e=t[t.length-1].value;return d(e&&e[0])?2:1}function nn(t,e,n,i,r,a){var o=t._getter,s=t._setter,l="spline"===e,h=i.length;if(h){var u,c=i[0].value,f=d(c),p=!1,g=!1,m=f?en(i):0;i.sort(function(t,e){return t.time-e.time}),u=i[h-1].time;for(var v=[],y=[],x=i[0].value,_=!0,w=0;h>w;w++){v.push(i[w].time/u);var b=i[w].value;if(f&&$e(b,x,m)||!f&&b===x||(_=!1),x=b,"string"==typeof b){var S=ze(b);S?(b=S,p=!0):g=!0}y.push(b)}if(a||!_){for(var M=y[h-1],w=0;h-1>w;w++)f?qe(y[w],M,m):!isNaN(y[w])||isNaN(M)||g||p||(y[w]=M);f&&qe(o(t._target,r),M,m);var I,T,C,D,A,k,P=0,L=0;if(p)var O=[0,0,0,0];var z=function(t,e){var n;if(0>e)n=0;else if(L>e){for(I=Math.min(P+1,h-1),n=I;n>=0&&!(v[n]<=e);n--);n=Math.min(n,h-2)}else{for(n=P;h>n&&!(v[n]>e);n++);n=Math.min(n-1,h-2)}P=n,L=e;var i=v[n+1]-v[n];if(0!==i)if(T=(e-v[n])/i,l)if(D=y[n],C=y[0===n?n:n-1],A=y[n>h-2?h-1:n+1],k=y[n>h-3?h-1:n+2],f)Ke(C,D,A,k,T,T*T,T*T*T,o(t,r),m);else{var a;if(p)a=Ke(C,D,A,k,T,T*T,T*T*T,O,1),a=tn(O);else{if(g)return Ye(D,A,T);a=Je(C,D,A,k,T,T*T,T*T*T)}s(t,r,a)}else if(f)je(y[n],y[n+1],T,o(t,r),m);else{var a;if(p)je(y[n],y[n+1],T,O,1),a=tn(O);else{if(g)return Ye(y[n],y[n+1],T);a=Ue(y[n],y[n+1],T)}s(t,r,a)}},R=new Se({target:t._target,life:u,loop:t._loop,delay:t._delay,onframe:z,ondestroy:n});return e&&"spline"!==e&&(R.easing=e),R}}}function rn(t,e,n,i){0>n&&(t+=n,n=-n),0>i&&(e+=i,i=-i),this.x=t,this.y=e,this.width=n,this.height=i}function an(t){for(var e=0;t>=up;)e|=1&t,t>>=1;return t+e}function on(t,e,n,i){var r=e+1;if(r===n)return 1;if(i(t[r++],t[e])<0){for(;n>r&&i(t[r],t[r-1])<0;)r++;sn(t,e,r)}else for(;n>r&&i(t[r],t[r-1])>=0;)r++;return r-e}function sn(t,e,n){for(n--;n>e;){var i=t[e];t[e++]=t[n],t[n--]=i}}function ln(t,e,n,i,r){for(i===e&&i++;n>i;i++){for(var a,o=t[i],s=e,l=i;l>s;)a=s+l>>>1,r(o,t[a])<0?l=a:s=a+1;var h=i-s;switch(h){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(;h>0;)t[s+h]=t[s+h-1],h--}t[s]=o}}function hn(t,e,n,i,r,a){var o=0,s=0,l=1;if(a(t,e[n+r])>0){for(s=i-r;s>l&&a(t,e[n+r+l])>0;)o=l,l=(l<<1)+1,0>=l&&(l=s);l>s&&(l=s),o+=r,l+=r}else{for(s=r+1;s>l&&a(t,e[n+r-l])<=0;)o=l,l=(l<<1)+1,0>=l&&(l=s);l>s&&(l=s);var h=o;o=r-l,l=r-h}for(o++;l>o;){var u=o+(l-o>>>1);a(t,e[n+u])>0?o=u+1:l=u}return l}function un(t,e,n,i,r,a){var o=0,s=0,l=1;if(a(t,e[n+r])<0){for(s=r+1;s>l&&a(t,e[n+r-l])<0;)o=l,l=(l<<1)+1,0>=l&&(l=s);l>s&&(l=s);var h=o;o=r-l,l=r-h}else{for(s=i-r;s>l&&a(t,e[n+r+l])>=0;)o=l,l=(l<<1)+1,0>=l&&(l=s);l>s&&(l=s),o+=r,l+=r}for(o++;l>o;){var u=o+(l-o>>>1);a(t,e[n+u])<0?l=u:o=u+1}return l}function cn(t,e){function n(t,e){l[c]=t,h[c]=e,c+=1}function i(){for(;c>1;){var t=c-2;if(t>=1&&h[t-1]<=h[t]+h[t+1]||t>=2&&h[t-2]<=h[t]+h[t-1])h[t-1]h[t+1])break;a(t)}}function r(){for(;c>1;){var t=c-2;t>0&&h[t-1]=r?o(i,r,a,u):s(i,r,a,u)))}function o(n,i,r,a){var o=0;for(o=0;i>o;o++)d[o]=t[n+o];var s=0,l=r,h=n;if(t[h++]=t[l++],0!==--a){if(1===i){for(o=0;a>o;o++)t[h+o]=t[l+o];return void(t[h+a]=d[s])}for(var c,f,p,g=u;;){c=0,f=0,p=!1;do if(e(t[l],d[s])<0){if(t[h++]=t[l++],f++,c=0,0===--a){p=!0;break}}else if(t[h++]=d[s++],c++,f=0,1===--i){p=!0;break}while(g>(c|f));if(p)break;do{if(c=un(t[l],d,s,i,0,e),0!==c){for(o=0;c>o;o++)t[h+o]=d[s+o];if(h+=c,s+=c,i-=c,1>=i){p=!0;break}}if(t[h++]=t[l++],0===--a){p=!0;break}if(f=hn(d[s],t,l,a,0,e),0!==f){for(o=0;f>o;o++)t[h+o]=t[l+o];if(h+=f,l+=f,a-=f,0===a){p=!0;break}}if(t[h++]=d[s++],1===--i){p=!0;break}g--}while(c>=cp||f>=cp);if(p)break;0>g&&(g=0),g+=2}if(u=g,1>u&&(u=1),1===i){for(o=0;a>o;o++)t[h+o]=t[l+o];t[h+a]=d[s]}else{if(0===i)throw new Error;for(o=0;i>o;o++)t[h+o]=d[s+o]}}else for(o=0;i>o;o++)t[h+o]=d[s+o]}function s(n,i,r,a){var o=0;for(o=0;a>o;o++)d[o]=t[r+o];var s=n+i-1,l=a-1,h=r+a-1,c=0,f=0;if(t[h--]=t[s--],0!==--i){if(1===a){for(h-=i,s-=i,f=h+1,c=s+1,o=i-1;o>=0;o--)t[f+o]=t[c+o];return void(t[h]=d[l])}for(var p=u;;){var g=0,m=0,v=!1;do if(e(d[l],t[s])<0){if(t[h--]=t[s--],g++,m=0,0===--i){v=!0;break}}else if(t[h--]=d[l--],m++,g=0,1===--a){v=!0;break}while(p>(g|m));if(v)break;do{if(g=i-un(d[l],t,n,i,i-1,e),0!==g){for(h-=g,s-=g,i-=g,f=h+1,c=s+1,o=g-1;o>=0;o--)t[f+o]=t[c+o];if(0===i){v=!0;break}}if(t[h--]=d[l--],1===--a){v=!0;break}if(m=a-hn(t[s],d,0,a,a-1,e),0!==m){for(h-=m,l-=m,a-=m,f=h+1,c=l+1,o=0;m>o;o++)t[f+o]=d[c+o];if(1>=a){v=!0;break}}if(t[h--]=t[s--],0===--i){v=!0;break}p--}while(g>=cp||m>=cp);if(v)break;0>p&&(p=0),p+=2}if(u=p,1>u&&(u=1),1===a){for(h-=i,s-=i,f=h+1,c=s+1,o=i-1;o>=0;o--)t[f+o]=t[c+o];t[h]=d[l]}else{if(0===a)throw new Error;for(c=h-(a-1),o=0;a>o;o++)t[c+o]=d[o]}}else for(c=h-(a-1),o=0;a>o;o++)t[c+o]=d[o]}var l,h,u=cp,c=0,d=[];l=[],h=[],this.mergeRuns=i,this.forceMergeRuns=r,this.pushRun=n}function dn(t,e,n,i){n||(n=0),i||(i=t.length);var r=i-n;if(!(2>r)){var a=0;if(up>r)return a=on(t,n,i,e),void ln(t,n,i,n+a,e);var o=new cn(t,e),s=an(r);do{if(a=on(t,n,i,e),s>a){var l=r;l>s&&(l=s),ln(t,n,n+l,n+a,e),a=l}o.pushRun(n,a),o.mergeRuns(),r-=a,n+=a}while(0!==r);o.forceMergeRuns()}}function fn(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}function pn(t,e,n){var i=null==e.x?0:e.x,r=null==e.x2?1:e.x2,a=null==e.y?0:e.y,o=null==e.y2?0:e.y2;e.global||(i=i*n.width+n.x,r=r*n.width+n.x,a=a*n.height+n.y,o=o*n.height+n.y);var s=t.createLinearGradient(i,a,r,o);return s}function gn(t,e,n){var i=n.width,r=n.height,a=Math.min(i,r),o=null==e.x?.5:e.x,s=null==e.y?.5:e.y,l=null==e.r?.5:e.r;e.global||(o=o*i+n.x,s=s*r+n.y,l*=a);var h=t.createRadialGradient(o,s,0,o,s,l);return h}function mn(){return!1}function vn(t,e,n){var i=vf(),r=e.getWidth(),a=e.getHeight(),o=i.style;return o&&(o.position="absolute",o.left=0,o.top=0,o.width=r+"px",o.height=a+"px",i.setAttribute("data-zr-dom-id",t)),i.width=r*n,i.height=a*n,i}function yn(t){if("string"==typeof t){var e=Sp.get(t);return e&&e.image}return t}function xn(t,e,n,i,r){if(t){if("string"==typeof t){if(e&&e.__zrImageSrc===t||!n)return e;var a=Sp.get(t),o={hostEl:n,cb:i,cbPayload:r};return a?(e=a.image,!wn(e)&&a.pending.push(o)):(!e&&(e=new Image),e.onload=_n,Sp.put(t,e.__cachedImgObj={image:e,pending:[o]}),e.src=e.__zrImageSrc=t),e}return t}return e}function _n(){var t=this.__cachedImgObj;this.onload=this.__cachedImgObj=null;for(var e=0;ea;a++)r=Math.max(zn(i[a],e).width,r);return Ip>Tp&&(Ip=0,Mp={}),Ip++,Mp[n]=r,r}function Sn(t,e,n,i,r,a,o){return a?In(t,e,n,i,r,a,o):Mn(t,e,n,i,r,o)}function Mn(t,e,n,i,r,a){var o=Rn(t,e,r,a),s=bn(t,e);r&&(s+=r[1]+r[3]);var l=o.outerHeight,h=Tn(0,s,n),u=Cn(0,l,i),c=new rn(h,u,s,l);return c.lineHeight=o.lineHeight,c}function In(t,e,n,i,r,a,o){var s=Bn(t,{rich:a,truncate:o,font:e,textAlign:n,textPadding:r}),l=s.outerWidth,h=s.outerHeight,u=Tn(0,l,n),c=Cn(0,h,i);return new rn(u,c,l,h)}function Tn(t,e,n){return"right"===n?t-=e:"center"===n&&(t-=e/2),t}function Cn(t,e,n){return"middle"===n?t-=e/2:"bottom"===n&&(t-=e),t}function Dn(t,e,n){var i=e.x,r=e.y,a=e.height,o=e.width,s=a/2,l="left",h="top";switch(t){case"left":i-=n,r+=s,l="right",h="middle";break;case"right":i+=n+o,r+=s,h="middle";break;case"top":i+=o/2,r-=n,l="center",h="bottom";break;case"bottom":i+=o/2,r+=a+n,l="center";break;case"inside":i+=o/2,r+=s,l="center",h="middle";break;case"insideLeft":i+=n,r+=s,h="middle";break;case"insideRight":i+=o-n,r+=s,l="right",h="middle";break;case"insideTop":i+=o/2,r+=n,l="center";break;case"insideBottom":i+=o/2,r+=a-n,l="center",h="bottom";break;case"insideTopLeft":i+=n,r+=n;break;case"insideTopRight":i+=o-n,r+=n,l="right";break;case"insideBottomLeft":i+=n,r+=a-n,h="bottom";break;case"insideBottomRight":i+=o-n,r+=a-n,l="right",h="bottom"}return{x:i,y:r,textAlign:l,textVerticalAlign:h}}function An(t,e,n,i,r){if(!e)return"";var a=(t+"").split("\n");r=kn(e,n,i,r);for(var o=0,s=a.length;s>o;o++)a[o]=Pn(a[o],r);return a.join("\n")}function kn(t,e,n,i){i=o({},i),i.font=e;var n=A(n,"...");i.maxIterations=A(i.maxIterations,2);var r=i.minChar=A(i.minChar,0);i.cnCharWidth=bn("国",e);var a=i.ascCharWidth=bn("a",e);i.placeholder=A(i.placeholder,"");for(var s=t=Math.max(0,t-1),l=0;r>l&&s>=a;l++)s-=a;var h=bn(n);return h>s&&(n="",h=0),s=t-h,i.ellipsis=n,i.ellipsisWidth=h,i.contentWidth=s,i.containerWidth=t,i}function Pn(t,e){var n=e.containerWidth,i=e.font,r=e.contentWidth;if(!n)return"";var a=bn(t,i);if(n>=a)return t;for(var o=0;;o++){if(r>=a||o>=e.maxIterations){t+=e.ellipsis;break}var s=0===o?Ln(t,r,e.ascCharWidth,e.cnCharWidth):a>0?Math.floor(t.length*r/a):0;t=t.substr(0,s),a=bn(t,i)}return""===t&&(t=e.placeholder),t}function Ln(t,e,n,i){for(var r=0,a=0,o=t.length;o>a&&e>r;a++){var s=t.charCodeAt(a);r+=s>=0&&127>=s?n:i}return a}function On(t){return bn("国",t)}function zn(t,e){return Ap.measureText(t,e)}function Rn(t,e,n,i){null!=t&&(t+="");var r=On(e),a=t?t.split("\n"):[],o=a.length*r,s=o;if(n&&(s+=n[0]+n[2]),t&&i){var l=i.outerHeight,h=i.outerWidth;if(null!=l&&s>l)t="",a=[];else if(null!=h)for(var u=kn(h-(n?n[1]+n[3]:0),e,i.ellipsis,{minChar:i.minChar,placeholder:i.placeholder}),c=0,d=a.length;d>c;c++)a[c]=Pn(a[c],u)}return{lines:a,height:o,outerHeight:s,lineHeight:r}}function Bn(t,e){var n={lines:[],width:0,height:0};if(null!=t&&(t+=""),!t)return n;for(var i,r=Cp.lastIndex=0;null!=(i=Cp.exec(t));){var a=i.index;a>r&&En(n,t.substring(r,a)),En(n,i[2],i[1]),r=Cp.lastIndex}rf)return{lines:[],width:0,height:0};x.textWidth=bn(x.text,b);var M=_.textWidth,I=null==M||"auto"===M;if("string"==typeof M&&"%"===M.charAt(M.length-1))x.percentWidth=M,h.push(x),M=0;else{if(I){M=x.textWidth;var T=_.textBackgroundColor,C=T&&T.image;C&&(C=yn(C),wn(C)&&(M=Math.max(M,C.width*S/C.height)))}var D=w?w[1]+w[3]:0;M+=D;var P=null!=d?d-v:null;null!=P&&M>P&&(!I||D>P?(x.text="",x.textWidth=M=0):(x.text=An(x.text,P-D,b,c.ellipsis,{minChar:c.minChar}),x.textWidth=bn(x.text,b),M=x.textWidth+D))}v+=x.width=M,_&&(m=Math.max(m,x.lineHeight))}g.width=v,g.lineHeight=m,s+=m,l=Math.max(l,v)}n.outerWidth=n.width=A(e.textWidth,l),n.outerHeight=n.height=A(e.textHeight,s),u&&(n.outerWidth+=u[1]+u[3],n.outerHeight+=u[0]+u[2]);for(var p=0;pl&&(o+=l,l=-l),0>h&&(s+=h,h=-h),"number"==typeof u?n=i=r=a=u:u instanceof Array?1===u.length?n=i=r=a=u[0]:2===u.length?(n=r=u[0],i=a=u[1]):3===u.length?(n=u[0],i=a=u[1],r=u[2]):(n=u[0],i=u[1],r=u[2],a=u[3]):n=i=r=a=0;var c;n+i>l&&(c=n+i,n*=l/c,i*=l/c),r+a>l&&(c=r+a,r*=l/c,a*=l/c),i+r>h&&(c=i+r,i*=h/c,r*=h/c),n+a>h&&(c=n+a,n*=h/c,a*=h/c),t.moveTo(o+n,s),t.lineTo(o+l-i,s),0!==i&&t.quadraticCurveTo(o+l,s,o+l,s+i),t.lineTo(o+l,s+h-r),0!==r&&t.quadraticCurveTo(o+l,s+h,o+l-r,s+h),t.lineTo(o+a,s+h),0!==a&&t.quadraticCurveTo(o,s+h,o,s+h-a),t.lineTo(o,s+n),0!==n&&t.quadraticCurveTo(o,s,o+n,s)}function Gn(t){return Vn(t),f(t.rich,Vn),t}function Vn(t){if(t){t.font=Nn(t);var e=t.textAlign;"middle"===e&&(e="center"),t.textAlign=null==e||kp[e]?e:"left";var n=t.textVerticalAlign||t.textBaseline;"center"===n&&(n="middle"),t.textVerticalAlign=null==n||Pp[n]?n:"top";var i=t.textPadding;i&&(t.textPadding=L(t.textPadding))}}function Hn(t,e,n,i,r){i.rich?Xn(t,e,n,i,r):Wn(t,e,n,i,r)}function Wn(t,e,n,i,r){var a=Jn(e,"font",i.font||Dp),o=i.textPadding,s=t.__textCotentBlock;(!s||t.__dirty)&&(s=t.__textCotentBlock=Rn(n,a,o,i.truncate));var l=s.outerHeight,h=s.lines,u=s.lineHeight,c=Kn(l,i,r),d=c.baseX,f=c.baseY,p=c.textAlign,g=c.textVerticalAlign;Un(e,i,r,d,f);var m=Cn(f,l,g),v=d,y=m,x=jn(i);if(x||o){var _=bn(n,a),w=_;o&&(w+=o[1]+o[3]);var b=Tn(d,w,p);x&&qn(t,e,i,b,m,w,l),o&&(v=ni(d,p,o),y+=o[0])}Jn(e,"textAlign",p||"left"),Jn(e,"textBaseline","middle"),Jn(e,"shadowBlur",i.textShadowBlur||0),Jn(e,"shadowColor",i.textShadowColor||"transparent"),Jn(e,"shadowOffsetX",i.textShadowOffsetX||0),Jn(e,"shadowOffsetY",i.textShadowOffsetY||0),y+=u/2;var S=i.textStrokeWidth,M=Qn(i.textStroke,S),I=ti(i.textFill);M&&(Jn(e,"lineWidth",S),Jn(e,"strokeStyle",M)),I&&Jn(e,"fillStyle",I);for(var T=0;TT&&(_=b[T],!_.textAlign||"left"===_.textAlign);)Yn(t,e,_,i,M,v,C,"left"),I-=_.width,C+=_.width,T++;for(;A>=0&&(_=b[A],"right"===_.textAlign);)Yn(t,e,_,i,M,v,D,"right"),I-=_.width,D-=_.width,A--;for(C+=(a-(C-m)-(y-D)-I)/2;A>=T;)_=b[T],Yn(t,e,_,i,M,v,C+_.width/2,"center"),C+=_.width,T++;v+=M}}function Un(t,e,n,i,r){if(n&&e.textRotation){var a=e.textOrigin;"center"===a?(i=n.width/2+n.x,r=n.height/2+n.y):a&&(i=a[0]+n.x,r=a[1]+n.y),t.translate(i,r),t.rotate(-e.textRotation),t.translate(-i,-r)}}function Yn(t,e,n,i,r,a,o,s){var l=i.rich[n.styleName]||{},h=n.textVerticalAlign,u=a+r/2;"top"===h?u=a+n.height/2:"bottom"===h&&(u=a+r-n.height/2),!n.isLineHolder&&jn(l)&&qn(t,e,l,"right"===s?o-n.width:"center"===s?o-n.width/2:o,u-n.height/2,n.width,n.height);var c=n.textPadding;c&&(o=ni(o,s,c),u-=n.height/2-c[2]-n.textHeight/2),Jn(e,"shadowBlur",k(l.textShadowBlur,i.textShadowBlur,0)),Jn(e,"shadowColor",l.textShadowColor||i.textShadowColor||"transparent"),Jn(e,"shadowOffsetX",k(l.textShadowOffsetX,i.textShadowOffsetX,0)),Jn(e,"shadowOffsetY",k(l.textShadowOffsetY,i.textShadowOffsetY,0)),Jn(e,"textAlign",s),Jn(e,"textBaseline","middle"),Jn(e,"font",n.font||Dp);var d=Qn(l.textStroke||i.textStroke,p),f=ti(l.textFill||i.textFill),p=A(l.textStrokeWidth,i.textStrokeWidth);d&&(Jn(e,"lineWidth",p),Jn(e,"strokeStyle",d),e.strokeText(n.text,o,u)),f&&(Jn(e,"fillStyle",f),e.fillText(n.text,o,u))}function jn(t){return t.textBackgroundColor||t.textBorderWidth&&t.textBorderColor}function qn(t,e,n,i,r,a,o){var s=n.textBackgroundColor,l=n.textBorderWidth,h=n.textBorderColor,u=b(s);if(Jn(e,"shadowBlur",n.textBoxShadowBlur||0),Jn(e,"shadowColor",n.textBoxShadowColor||"transparent"),Jn(e,"shadowOffsetX",n.textBoxShadowOffsetX||0),Jn(e,"shadowOffsetY",n.textBoxShadowOffsetY||0),u||l&&h){e.beginPath();var c=n.textBorderRadius;c?Fn(e,{x:i,y:r,width:a,height:o,r:c}):e.rect(i,r,a,o),e.closePath()}if(u)Jn(e,"fillStyle",s),e.fill();else if(S(s)){var d=s.image;d=xn(d,null,t,$n,s),d&&wn(d)&&e.drawImage(d,i,r,a,o)}l&&h&&(Jn(e,"lineWidth",l),Jn(e,"strokeStyle",h),e.stroke())}function $n(t,e){e.image=t}function Kn(t,e,n){var i=e.x||0,r=e.y||0,a=e.textAlign,o=e.textVerticalAlign;if(n){var s=e.textPosition;if(s instanceof Array)i=n.x+ei(s[0],n.width),r=n.y+ei(s[1],n.height);else{var l=Dn(s,n,e.textDistance);i=l.x,r=l.y,a=a||l.textAlign,o=o||l.textVerticalAlign}var h=e.textOffset;h&&(i+=h[0],r+=h[1])}return{baseX:i,baseY:r,textAlign:a,textVerticalAlign:o}}function Jn(t,e,n){return t[e]=pp(t,e,n),t[e]}function Qn(t,e){return null==t||0>=e||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function ti(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function ei(t,e){return"string"==typeof t?t.lastIndexOf("%")>=0?parseFloat(t)/100*e:parseFloat(t):t}function ni(t,e,n){return"right"===e?t-n[1]:"center"===e?t+n[3]/2-n[1]/2:t+n[3]}function ii(t,e){return null!=t&&(t||e.textBackgroundColor||e.textBorderWidth&&e.textBorderColor||e.textPadding)}function ri(t){t=t||{},ap.call(this,t);for(var e in t)t.hasOwnProperty(e)&&"style"!==e&&(this[e]=t[e]);this.style=new mp(t.style,this),this._rect=null,this.__clipPaths=[]}function ai(t){ri.call(this,t)}function oi(t){return parseInt(t,10)}function si(t){return t?t.__builtin__?!0:"function"!=typeof t.resize||"function"!=typeof t.refresh?!1:!0:!1}function li(t,e,n){return Np.copy(t.getBoundingRect()),t.transform&&Np.applyTransform(t.transform),Fp.width=e,Fp.height=n,!Np.intersect(Fp)}function hi(t,e){if(t==e)return!1;if(!t||!e||t.length!==e.length)return!0;for(var n=0;n=0;if(r){var a="touchend"!=i?e.targetTouches[0]:e.changedTouches[0];a&&fi(t,a,e,n)}else fi(t,e,e,n),e.zrDelta=e.wheelDelta?e.wheelDelta/120:-(e.detail||0)/3;var o=e.button;return null==e.which&&void 0!==o&&Hp.test(e.type)&&(e.which=1&o?1:2&o?3:4&o?2:0),e}function mi(t,e,n){Vp?t.addEventListener(e,n):t.attachEvent("on"+e,n)}function vi(t,e,n){Vp?t.removeEventListener(e,n):t.detachEvent("on"+e,n)}function yi(t){return t.which>1}function xi(t){var e=t[1][0]-t[0][0],n=t[1][1]-t[0][1];return Math.sqrt(e*e+n*n)}function _i(t){return[(t[0][0]+t[1][0])/2,(t[0][1]+t[1][1])/2]}function wi(t){return"mousewheel"===t&&of.browser.firefox?"DOMMouseScroll":t}function bi(t,e,n){var i=t._gestureMgr;"start"===n&&i.clear();var r=i.recognize(e,t.handler.findHover(e.zrX,e.zrY,null).target,t.dom);if("end"===n&&i.clear(),r){var a=r.type;e.gestureEvent=a,t.handler.dispatchToElement({target:r.target},a,r.event)}}function Si(t){t._touching=!0,clearTimeout(t._touchTimer),t._touchTimer=setTimeout(function(){t._touching=!1},700)}function Mi(t){var e=t.pointerType;return"pen"===e||"touch"===e}function Ii(t){function e(t,e){return function(){return e._touching?void 0:t.apply(e,arguments) +}}f(qp,function(e){t._handlers[e]=y(Jp[e],t)}),f(Kp,function(e){t._handlers[e]=y(Jp[e],t)}),f(jp,function(n){t._handlers[n]=e(Jp[n],t)})}function Ti(t){function e(e,n){f(e,function(e){mi(t,wi(e),n._handlers[e])},n)}Df.call(this),this.dom=t,this._touching=!1,this._touchTimer,this._gestureMgr=new Zp,this._handlers={},Ii(this),of.pointerEventsSupported?e(Kp,this):(of.touchEventsSupported&&e(qp,this),e(jp,this))}function Ci(t,e){var n=new rg(rf(),t,e);return ng[n.id]=n,n}function Di(t){if(t)t.dispose();else{for(var e in ng)ng.hasOwnProperty(e)&&ng[e].dispose();ng={}}return this}function Ai(t){return ng[t]}function ki(t,e){eg[t]=e}function Pi(t){delete ng[t]}function Li(t){return t instanceof Array?t:null==t?[]:[t]}function Oi(t,e,n){if(t){t[e]=t[e]||{},t.emphasis=t.emphasis||{},t.emphasis[e]=t.emphasis[e]||{};for(var i=0,r=n.length;r>i;i++){var a=n[i];!t.emphasis[e].hasOwnProperty(a)&&t[e].hasOwnProperty(a)&&(t.emphasis[e][a]=t[e][a])}}}function zi(t){return!sg(t)||lg(t)||t instanceof Date?t:t.value}function Ri(t){return sg(t)&&!(t instanceof Array)}function Bi(t,e){e=(e||[]).slice();var n=p(t||[],function(t){return{exist:t}});return og(e,function(t,i){if(sg(t)){for(var r=0;r=n.length&&n.push({option:t})}}),n}function Ei(t){var e=N();og(t,function(t){var n=t.exist;n&&e.set(n.id,t)}),og(t,function(t){var n=t.option;O(!n||null==n.id||!e.get(n.id)||e.get(n.id)===t,"id duplicates: "+(n&&n.id)),n&&null!=n.id&&e.set(n.id,t),!t.keyInfo&&(t.keyInfo={})}),og(t,function(t){var n=t.exist,i=t.option,r=t.keyInfo;if(sg(i)){if(r.name=null!=i.name?i.name+"":n?n.name:hg,n)r.id=n.id;else if(null!=i.id)r.id=i.id+"";else{var a=0;do r.id="\x00"+r.name+"\x00"+a++;while(e.get(r.id))}e.set(r.id,t)}})}function Ni(t){return sg(t)&&t.id&&0===(t.id+"").indexOf("\x00_ec_\x00")}function Fi(t,e){return null!=e.dataIndexInside?e.dataIndexInside:null!=e.dataIndex?_(e.dataIndex)?p(e.dataIndex,function(e){return t.indexOfRawIndex(e)}):t.indexOfRawIndex(e.dataIndex):null!=e.name?_(e.name)?p(e.name,function(e){return t.indexOfName(e)}):t.indexOfName(e.name):void 0}function Gi(){var t="__\x00ec_inner_"+cg++ +"_"+Math.random().toFixed(5);return function(e){return e[t]||(e[t]={})}}function Vi(t,e,n){if(b(e)){var i={};i[e+"Index"]=0,e=i}var r=n&&n.defaultMainType;!r||Hi(e,r+"Index")||Hi(e,r+"Id")||Hi(e,r+"Name")||(e[r+"Index"]=0);var a={};return og(e,function(i,r){var i=e[r];if("dataIndex"===r||"dataIndexInside"===r)return void(a[r]=i);var o=r.match(/^(\w+)(Index|Id|Name)$/)||[],s=o[1],l=(o[2]||"").toLowerCase();if(!(!s||!l||null==i||"index"===l&&"none"===i||n&&n.includeMainTypes&&h(n.includeMainTypes,s)<0)){var u={mainType:s};("index"!==l||"all"!==i)&&(u[l]=i);var c=t.queryComponents(u);a[s+"Models"]=c,a[s+"Model"]=c[0]}}),a}function Hi(t,e){return t&&t.hasOwnProperty(e)}function Wi(t,e,n){t.setAttribute?t.setAttribute(e,n):t[e]=n}function Xi(t,e){return t.getAttribute?t.getAttribute(e):t[e]}function Zi(t){var e={main:"",sub:""};return t&&(t=t.split(dg),e.main=t[0]||"",e.sub=t[1]||""),e}function Ui(t){O(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(t),'componentType "'+t+'" illegal')}function Yi(t){t.$constructor=t,t.extend=function(t){var e=this,n=function(){t.$constructor?t.$constructor.apply(this,arguments):e.apply(this,arguments)};return o(n.prototype,t),n.extend=this.extend,n.superCall=qi,n.superApply=$i,u(n,this),n.superClass=e,n}}function ji(t){var e=["__\x00is_clz",pg++,Math.random().toFixed(3)].join("_");t.prototype[e]=!0,t.isInstance=function(t){return!(!t||!t[e])}}function qi(t,e){var n=P(arguments,2);return this.superClass.prototype[e].apply(t,n)}function $i(t,e,n){return this.superClass.prototype[e].apply(t,n)}function Ki(t,e){function n(t){var e=i[t.main];return e&&e[fg]||(e=i[t.main]={},e[fg]=!0),e}e=e||{};var i={};if(t.registerClass=function(t,e){if(e)if(Ui(e),e=Zi(e),e.sub){if(e.sub!==fg){var r=n(e);r[e.sub]=t}}else i[e.main]=t;return t},t.getClass=function(t,e,n){var r=i[t];if(r&&r[fg]&&(r=e?r[e]:null),n&&!r)throw new Error(e?"Component "+t+"."+(e||"")+" not exists. Load it first.":t+".type should be specified.");return r},t.getClassesByMainType=function(t){t=Zi(t);var e=[],n=i[t.main];return n&&n[fg]?f(n,function(t,n){n!==fg&&e.push(t)}):e.push(n),e},t.hasClass=function(t){return t=Zi(t),!!i[t.main]},t.getAllClassMainTypes=function(){var t=[];return f(i,function(e,n){t.push(n)}),t},t.hasSubTypes=function(t){t=Zi(t);var e=i[t.main];return e&&e[fg]},t.parseClassType=Zi,e.registerWhenExtend){var r=t.extend;r&&(t.extend=function(e){var n=r.call(this,e);return t.registerClass(n,e.type)})}return t}function Ji(t){return t>-bg&&bg>t}function Qi(t){return t>bg||-bg>t}function tr(t,e,n,i,r){var a=1-r;return a*a*(a*t+3*r*e)+r*r*(r*i+3*a*n)}function er(t,e,n,i,r){var a=1-r;return 3*(((e-t)*a+2*(n-e)*r)*a+(i-n)*r*r)}function nr(t,e,n,i,r,a){var o=i+3*(e-n)-t,s=3*(n-2*e+t),l=3*(e-t),h=t-r,u=s*s-3*o*l,c=s*l-9*o*h,d=l*l-3*s*h,f=0;if(Ji(u)&&Ji(c))if(Ji(s))a[0]=0;else{var p=-l/s;p>=0&&1>=p&&(a[f++]=p)}else{var g=c*c-4*u*d;if(Ji(g)){var m=c/u,p=-s/o+m,v=-m/2;p>=0&&1>=p&&(a[f++]=p),v>=0&&1>=v&&(a[f++]=v)}else if(g>0){var y=wg(g),x=u*s+1.5*o*(-c+y),_=u*s+1.5*o*(-c-y);x=0>x?-_g(-x,Ig):_g(x,Ig),_=0>_?-_g(-_,Ig):_g(_,Ig);var p=(-s-(x+_))/(3*o);p>=0&&1>=p&&(a[f++]=p)}else{var w=(2*u*s-3*o*c)/(2*wg(u*u*u)),b=Math.acos(w)/3,S=wg(u),M=Math.cos(b),p=(-s-2*S*M)/(3*o),v=(-s+S*(M+Mg*Math.sin(b)))/(3*o),I=(-s+S*(M-Mg*Math.sin(b)))/(3*o);p>=0&&1>=p&&(a[f++]=p),v>=0&&1>=v&&(a[f++]=v),I>=0&&1>=I&&(a[f++]=I)}}return f}function ir(t,e,n,i,r){var a=6*n-12*e+6*t,o=9*e+3*i-3*t-9*n,s=3*e-3*t,l=0;if(Ji(o)){if(Qi(a)){var h=-s/a;h>=0&&1>=h&&(r[l++]=h)}}else{var u=a*a-4*o*s;if(Ji(u))r[0]=-a/(2*o);else if(u>0){var c=wg(u),h=(-a+c)/(2*o),d=(-a-c)/(2*o);h>=0&&1>=h&&(r[l++]=h),d>=0&&1>=d&&(r[l++]=d)}}return l}function rr(t,e,n,i,r,a){var o=(e-t)*r+t,s=(n-e)*r+e,l=(i-n)*r+n,h=(s-o)*r+o,u=(l-s)*r+s,c=(u-h)*r+h;a[0]=t,a[1]=o,a[2]=h,a[3]=c,a[4]=c,a[5]=u,a[6]=l,a[7]=i}function ar(t,e,n,i,r,a,o,s,l,h,u){var c,d,f,p,g,m=.005,v=1/0;Tg[0]=l,Tg[1]=h;for(var y=0;1>y;y+=.05)Cg[0]=tr(t,n,r,o,y),Cg[1]=tr(e,i,a,s,y),p=If(Tg,Cg),v>p&&(c=y,v=p);v=1/0;for(var x=0;32>x&&!(Sg>m);x++)d=c-m,f=c+m,Cg[0]=tr(t,n,r,o,d),Cg[1]=tr(e,i,a,s,d),p=If(Cg,Tg),d>=0&&v>p?(c=d,v=p):(Dg[0]=tr(t,n,r,o,f),Dg[1]=tr(e,i,a,s,f),g=If(Dg,Tg),1>=f&&v>g?(c=f,v=g):m*=.5);return u&&(u[0]=tr(t,n,r,o,c),u[1]=tr(e,i,a,s,c)),wg(v)}function or(t,e,n,i){var r=1-i;return r*(r*t+2*i*e)+i*i*n}function sr(t,e,n,i){return 2*((1-i)*(e-t)+i*(n-e))}function lr(t,e,n,i,r){var a=t-2*e+n,o=2*(e-t),s=t-i,l=0;if(Ji(a)){if(Qi(o)){var h=-s/o;h>=0&&1>=h&&(r[l++]=h)}}else{var u=o*o-4*a*s;if(Ji(u)){var h=-o/(2*a);h>=0&&1>=h&&(r[l++]=h)}else if(u>0){var c=wg(u),h=(-o+c)/(2*a),d=(-o-c)/(2*a);h>=0&&1>=h&&(r[l++]=h),d>=0&&1>=d&&(r[l++]=d)}}return l}function hr(t,e,n){var i=t+n-2*e;return 0===i?.5:(t-e)/i}function ur(t,e,n,i,r){var a=(e-t)*i+t,o=(n-e)*i+e,s=(o-a)*i+a;r[0]=t,r[1]=a,r[2]=s,r[3]=s,r[4]=o,r[5]=n}function cr(t,e,n,i,r,a,o,s,l){var h,u=.005,c=1/0;Tg[0]=o,Tg[1]=s;for(var d=0;1>d;d+=.05){Cg[0]=or(t,n,r,d),Cg[1]=or(e,i,a,d);var f=If(Tg,Cg);c>f&&(h=d,c=f)}c=1/0;for(var p=0;32>p&&!(Sg>u);p++){var g=h-u,m=h+u;Cg[0]=or(t,n,r,g),Cg[1]=or(e,i,a,g);var f=If(Cg,Tg);if(g>=0&&c>f)h=g,c=f;else{Dg[0]=or(t,n,r,m),Dg[1]=or(e,i,a,m);var v=If(Dg,Tg);1>=m&&c>v?(h=m,c=v):u*=.5}}return l&&(l[0]=or(t,n,r,h),l[1]=or(e,i,a,h)),wg(c)}function dr(t,e,n){if(0!==t.length){var i,r=t[0],a=r[0],o=r[0],s=r[1],l=r[1];for(i=1;iu;u++){var p=d(t,n,r,o,Eg[u]);l[0]=Ag(p,l[0]),h[0]=kg(p,h[0])}for(f=c(e,i,a,s,Ng),u=0;f>u;u++){var g=d(e,i,a,s,Ng[u]);l[1]=Ag(g,l[1]),h[1]=kg(g,h[1])}l[0]=Ag(t,l[0]),h[0]=kg(t,h[0]),l[0]=Ag(o,l[0]),h[0]=kg(o,h[0]),l[1]=Ag(e,l[1]),h[1]=kg(e,h[1]),l[1]=Ag(s,l[1]),h[1]=kg(s,h[1])}function gr(t,e,n,i,r,a,o,s){var l=hr,h=or,u=kg(Ag(l(t,n,r),1),0),c=kg(Ag(l(e,i,a),1),0),d=h(t,n,r,u),f=h(e,i,a,c);o[0]=Ag(t,r,d),o[1]=Ag(e,a,f),s[0]=kg(t,r,d),s[1]=kg(e,a,f)}function mr(t,e,n,i,r,a,o,s,l){var h=oe,u=se,c=Math.abs(r-a);if(1e-4>c%Og&&c>1e-4)return s[0]=t-n,s[1]=e-i,l[0]=t+n,void(l[1]=e+i);if(zg[0]=Lg(r)*n+t,zg[1]=Pg(r)*i+e,Rg[0]=Lg(a)*n+t,Rg[1]=Pg(a)*i+e,h(s,zg,Rg),u(l,zg,Rg),r%=Og,0>r&&(r+=Og),a%=Og,0>a&&(a+=Og),r>a&&!o?a+=Og:a>r&&o&&(r+=Og),o){var d=a;a=r,r=d}for(var f=0;a>f;f+=Math.PI/2)f>r&&(Bg[0]=Lg(f)*n+t,Bg[1]=Pg(f)*i+e,h(s,Bg,s),u(l,Bg,l))}function vr(t,e,n,i,r,a,o){if(0===r)return!1;var s=r,l=0,h=t;if(o>e+s&&o>i+s||e-s>o&&i-s>o||a>t+s&&a>n+s||t-s>a&&n-s>a)return!1;if(t===n)return Math.abs(a-t)<=s/2;l=(e-i)/(t-n),h=(t*i-n*e)/(t-n);var u=l*a-o+h,c=u*u/(l*l+1);return s/2*s/2>=c}function yr(t,e,n,i,r,a,o,s,l,h,u){if(0===l)return!1;var c=l;if(u>e+c&&u>i+c&&u>a+c&&u>s+c||e-c>u&&i-c>u&&a-c>u&&s-c>u||h>t+c&&h>n+c&&h>r+c&&h>o+c||t-c>h&&n-c>h&&r-c>h&&o-c>h)return!1;var d=ar(t,e,n,i,r,a,o,s,h,u,null);return c/2>=d}function xr(t,e,n,i,r,a,o,s,l){if(0===o)return!1;var h=o;if(l>e+h&&l>i+h&&l>a+h||e-h>l&&i-h>l&&a-h>l||s>t+h&&s>n+h&&s>r+h||t-h>s&&n-h>s&&r-h>s)return!1;var u=cr(t,e,n,i,r,a,s,l,null);return h/2>=u}function _r(t){return t%=Jg,0>t&&(t+=Jg),t}function wr(t,e,n,i,r,a,o,s,l){if(0===o)return!1;var h=o;s-=t,l-=e;var u=Math.sqrt(s*s+l*l);if(u-h>n||n>u+h)return!1;if(Math.abs(i-r)%Qg<1e-4)return!0;if(a){var c=i;i=_r(r),r=_r(c)}else i=_r(i),r=_r(r);i>r&&(r+=Qg);var d=Math.atan2(l,s);return 0>d&&(d+=Qg),d>=i&&r>=d||d+Qg>=i&&r>=d+Qg}function br(t,e,n,i,r,a){if(a>e&&a>i||e>a&&i>a)return 0;if(i===e)return 0;var o=e>i?1:-1,s=(a-e)/(i-e);(1===s||0===s)&&(o=e>i?.5:-.5);var l=s*(n-t)+t;return l>r?o:0}function Sr(t,e){return Math.abs(t-e)e&&h>i&&h>a&&h>s||e>h&&i>h&&a>h&&s>h)return 0;var u=nr(e,i,a,s,h,im);if(0===u)return 0;for(var c,d,f=0,p=-1,g=0;u>g;g++){var m=im[g],v=0===m||1===m?.5:1,y=tr(t,n,r,o,m);l>y||(0>p&&(p=ir(e,i,a,s,rm),rm[1]1&&Mr(),c=tr(e,i,a,s,rm[0]),p>1&&(d=tr(e,i,a,s,rm[1]))),f+=2==p?mc?v:-v:md?v:-v:d>s?v:-v:mc?v:-v:c>s?v:-v)}return f}function Tr(t,e,n,i,r,a,o,s){if(s>e&&s>i&&s>a||e>s&&i>s&&a>s)return 0;var l=lr(e,i,a,s,im);if(0===l)return 0;var h=hr(e,i,a);if(h>=0&&1>=h){for(var u=0,c=or(e,i,a,h),d=0;l>d;d++){var f=0===im[d]||1===im[d]?.5:1,p=or(t,n,r,im[d]);o>p||(u+=im[d]c?f:-f:c>a?f:-f)}return u}var f=0===im[0]||1===im[0]?.5:1,p=or(t,n,r,im[0]);return o>p?0:e>a?f:-f}function Cr(t,e,n,i,r,a,o,s){if(s-=e,s>n||-n>s)return 0;var l=Math.sqrt(n*n-s*s);im[0]=-l,im[1]=l;var h=Math.abs(i-r);if(1e-4>h)return 0;if(1e-4>h%em){i=0,r=em;var u=a?1:-1;return o>=im[0]+t&&o<=im[1]+t?u:0}if(a){var l=i;i=_r(r),r=_r(l)}else i=_r(i),r=_r(r);i>r&&(r+=em);for(var c=0,d=0;2>d;d++){var f=im[d];if(f+t>o){var p=Math.atan2(s,f),u=a?1:-1;0>p&&(p=em+p),(p>=i&&r>=p||p+em>=i&&r>=p+em)&&(p>Math.PI/2&&p<1.5*Math.PI&&(u=-u),c+=u)}}return c}function Dr(t,e,n,i,r){for(var a=0,o=0,s=0,l=0,h=0,u=0;u1&&(n||(a+=br(o,s,l,h,i,r))),1==u&&(o=t[u],s=t[u+1],l=o,h=s),c){case tm.M:l=t[u++],h=t[u++],o=l,s=h;break;case tm.L:if(n){if(vr(o,s,t[u],t[u+1],e,i,r))return!0}else a+=br(o,s,t[u],t[u+1],i,r)||0;o=t[u++],s=t[u++];break;case tm.C:if(n){if(yr(o,s,t[u++],t[u++],t[u++],t[u++],t[u],t[u+1],e,i,r))return!0}else a+=Ir(o,s,t[u++],t[u++],t[u++],t[u++],t[u],t[u+1],i,r)||0;o=t[u++],s=t[u++];break;case tm.Q:if(n){if(xr(o,s,t[u++],t[u++],t[u],t[u+1],e,i,r))return!0}else a+=Tr(o,s,t[u++],t[u++],t[u],t[u+1],i,r)||0;o=t[u++],s=t[u++];break;case tm.A:var d=t[u++],f=t[u++],p=t[u++],g=t[u++],m=t[u++],v=t[u++],y=(t[u++],1-t[u++]),x=Math.cos(m)*p+d,_=Math.sin(m)*g+f;u>1?a+=br(o,s,x,_,i,r):(l=x,h=_);var w=(i-d)*g/p+d;if(n){if(wr(d,f,g,m,m+v,y,e,w,r))return!0}else a+=Cr(d,f,g,m,m+v,y,w,r);o=Math.cos(m+v)*p+d,s=Math.sin(m+v)*g+f;break;case tm.R:l=o=t[u++],h=s=t[u++];var b=t[u++],S=t[u++],x=l+b,_=h+S;if(n){if(vr(l,h,x,h,e,i,r)||vr(x,h,x,_,e,i,r)||vr(x,_,l,_,e,i,r)||vr(l,_,l,h,e,i,r))return!0}else a+=br(x,h,x,_,i,r),a+=br(l,_,l,h,i,r);break;case tm.Z:if(n){if(vr(o,s,l,h,e,i,r))return!0}else a+=br(o,s,l,h,i,r);o=l,s=h}}return n||Sr(s,h)||(a+=br(o,s,l,h,i,r)||0),0!==a}function Ar(t,e,n){return Dr(t,0,!1,e,n)}function kr(t,e,n,i){return Dr(t,e,!0,n,i)}function Pr(t){ri.call(this,t),this.path=null}function Lr(t,e,n,i,r,a,o,s,l,h,u){var c=l*(vm/180),d=mm(c)*(t-n)/2+gm(c)*(e-i)/2,f=-1*gm(c)*(t-n)/2+mm(c)*(e-i)/2,p=d*d/(o*o)+f*f/(s*s);p>1&&(o*=pm(p),s*=pm(p));var g=(r===a?-1:1)*pm((o*o*s*s-o*o*f*f-s*s*d*d)/(o*o*f*f+s*s*d*d))||0,m=g*o*f/s,v=g*-s*d/o,y=(t+n)/2+mm(c)*m-gm(c)*v,x=(e+i)/2+gm(c)*m+mm(c)*v,_=_m([1,0],[(d-m)/o,(f-v)/s]),w=[(d-m)/o,(f-v)/s],b=[(-1*d-m)/o,(-1*f-v)/s],S=_m(w,b);xm(w,b)<=-1&&(S=vm),xm(w,b)>=1&&(S=0),0===a&&S>0&&(S-=2*vm),1===a&&0>S&&(S+=2*vm),u.addData(h,y,x,o,s,_,S,c,a)}function Or(t){if(!t)return[];var e,n=t.replace(/-/g," -").replace(/ /g," ").replace(/ /g,",").replace(/,,/g,",");for(e=0;e0&&""===f[0]&&f.shift();for(var p=0;pr;r++){var a=t[r];a.path||a.createPathProxy(),a.__dirtyPath&&a.buildPath(a.path,a.shape,!0),n.push(a.path)}var o=new Pr(e);return o.createPathProxy(),o.buildPath=function(t){t.appendPath(n);var e=t.getContext();e&&t.rebuildPath(e)},o}function Nr(t,e,n,i,r,a,o){var s=.5*(n-t),l=.5*(i-e);return(2*(e-n)+s+l)*o+(-3*(e-n)-2*s-l)*a+s*r+e}function Fr(t,e,n){var i=e.points,r=e.smooth;if(i&&i.length>=2){if(r&&"spline"!==r){var a=Dm(i,r,n,e.smoothConstraint);t.moveTo(i[0][0],i[0][1]);for(var o=i.length,s=0;(n?o:o-1)>s;s++){var l=a[2*s],h=a[2*s+1],u=i[(s+1)%o];t.bezierCurveTo(l[0],l[1],h[0],h[1],u[0],u[1])}}else{"spline"===r&&(i=Cm(i,n)),t.moveTo(i[0][0],i[0][1]);for(var s=1,c=i.length;c>s;s++)t.lineTo(i[s][0],i[s][1])}n&&t.closePath()}}function Gr(t,e,n){var i=t.cpx2,r=t.cpy2;return null===i||null===r?[(n?er:tr)(t.x1,t.cpx1,t.cpx2,t.x2,e),(n?er:tr)(t.y1,t.cpy1,t.cpy2,t.y2,e)]:[(n?sr:or)(t.x1,t.cpx1,t.x2,e),(n?sr:or)(t.y1,t.cpy1,t.y2,e)]}function Vr(t){ri.call(this,t),this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.notClear=!0}function Hr(t){return Pr.extend(t)}function Wr(t,e){return Br(t,e)}function Xr(t,e,n,i){var r=Rr(t,e),a=r.getBoundingRect();return n&&("center"===i&&(n=Ur(n,a)),Yr(r,n)),r}function Zr(t,e,n){var i=new ai({style:{image:t,x:e.x,y:e.y,width:e.width,height:e.height},onload:function(t){if("center"===n){var r={width:t.width,height:t.height};i.setStyle(Ur(e,r))}}});return i}function Ur(t,e){var n,i=e.width/e.height,r=t.height*i;r<=t.width?n=t.height:(r=t.width,n=r/i);var a=t.x+t.width/2,o=t.y+t.height/2;return{x:a-r/2,y:o-n/2,width:r,height:n}}function Yr(t,e){if(t.applyTransform){var n=t.getBoundingRect(),i=n.calculateTransform(e);t.applyTransform(i)}}function jr(t){var e=t.shape,n=t.style.lineWidth;return Vm(2*e.x1)===Vm(2*e.x2)&&(e.x1=e.x2=$r(e.x1,n,!0)),Vm(2*e.y1)===Vm(2*e.y2)&&(e.y1=e.y2=$r(e.y1,n,!0)),t}function qr(t){var e=t.shape,n=t.style.lineWidth,i=e.x,r=e.y,a=e.width,o=e.height;return e.x=$r(e.x,n,!0),e.y=$r(e.y,n,!0),e.width=Math.max($r(i+a,n,!1)-e.x,0===a?0:1),e.height=Math.max($r(r+o,n,!1)-e.y,0===o?0:1),t}function $r(t,e,n){var i=Vm(2*t);return(i+Vm(e))%2===0?i/2:(i+(n?1:-1))/2}function Kr(t){return null!=t&&"none"!=t}function Jr(t){return"string"==typeof t?Ee(t,-.1):t}function Qr(t){if(t.__hoverStlDirty){var e=t.style.stroke,n=t.style.fill,i=t.__hoverStl;i.fill=i.fill||(Kr(n)?Jr(n):null),i.stroke=i.stroke||(Kr(e)?Jr(e):null);var r={};for(var a in i)null!=i[a]&&(r[a]=t.style[a]);t.__normalStl=r,t.__hoverStlDirty=!1}}function ta(t){if(!t.__isHover){if(Qr(t),t.useHoverLayer)t.__zr&&t.__zr.addHover(t,t.__hoverStl);else{var e=t.style,n=e.insideRollbackOpt;n&&ya(e),e.extendFrom(t.__hoverStl),n&&(va(e,e.insideOriginalTextPosition,n),null==e.textFill&&(e.textFill=n.autoColor)),t.dirty(!1),t.z2+=1}t.__isHover=!0}}function ea(t){if(t.__isHover){var e=t.__normalStl;t.useHoverLayer?t.__zr&&t.__zr.removeHover(t):(e&&t.setStyle(e),t.z2-=1),t.__isHover=!1}}function na(t){"group"===t.type?t.traverse(function(t){"group"!==t.type&&ta(t)}):ta(t)}function ia(t){"group"===t.type?t.traverse(function(t){"group"!==t.type&&ea(t)}):ea(t)}function ra(t,e){t.__hoverStl=t.hoverStyle||e||{},t.__hoverStlDirty=!0,t.__isHover&&Qr(t)}function aa(t){this.__hoverSilentOnTouch&&t.zrByTouch||!this.__isEmphasis&&na(this)}function oa(t){this.__hoverSilentOnTouch&&t.zrByTouch||!this.__isEmphasis&&ia(this)}function sa(){this.__isEmphasis=!0,na(this)}function la(){this.__isEmphasis=!1,ia(this)}function ha(t,e,n){t.__hoverSilentOnTouch=n&&n.hoverSilentOnTouch,"group"===t.type?t.traverse(function(t){"group"!==t.type&&ra(t,e)}):ra(t,e),t.on("mouseover",aa).on("mouseout",oa),t.on("emphasis",sa).on("normal",la)}function ua(t,e,n,i,r,a,o){r=r||Xm;var s,l=r.labelFetcher,h=r.labelDataIndex,u=r.labelDimIndex,c=n.getShallow("show"),d=i.getShallow("show");(c||d)&&(l&&(s=l.getFormattedLabel(h,"normal",null,u)),null==s&&(s=w(r.defaultText)?r.defaultText(h,r):r.defaultText));var f=c?s:null,p=d?A(l?l.getFormattedLabel(h,"emphasis",null,u):null,s):null;(null!=f||null!=p)&&(ca(t,n,a,r),ca(e,i,o,r,!0)),t.text=f,e.text=p}function ca(t,e,n,i,r){return fa(t,e,i,r),n&&o(t,n),t.host&&t.host.dirty&&t.host.dirty(!1),t}function da(t,e,n){var i,r={isRectText:!0};n===!1?i=!0:r.autoColor=n,fa(t,e,r,i),t.host&&t.host.dirty&&t.host.dirty(!1)}function fa(t,e,n,i){if(n=n||Xm,n.isRectText){var r=e.getShallow("position")||(i?null:"inside");"outside"===r&&(r="top"),t.textPosition=r,t.textOffset=e.getShallow("offset");var a=e.getShallow("rotate");null!=a&&(a*=Math.PI/180),t.textRotation=a,t.textDistance=A(e.getShallow("distance"),i?null:5)}var o,s=e.ecModel,l=s&&s.option.textStyle,h=pa(e);if(h){o={};for(var u in h)if(h.hasOwnProperty(u)){var c=e.getModel(["rich",u]);ga(o[u]={},c,l,n,i)}}return t.rich=o,ga(t,e,l,n,i,!0),n.forceRich&&!n.textStyle&&(n.textStyle={}),t}function pa(t){for(var e;t&&t!==t.ecModel;){var n=(t.option||Xm).rich;if(n){e=e||{};for(var i in n)n.hasOwnProperty(i)&&(e[i]=1)}t=t.parentModel}return e}function ga(t,e,n,i,r,a){if(n=!r&&n||Xm,t.textFill=ma(e.getShallow("color"),i)||n.color,t.textStroke=ma(e.getShallow("textBorderColor"),i)||n.textBorderColor,t.textStrokeWidth=A(e.getShallow("textBorderWidth"),n.textBorderWidth),!r){if(a){var o=t.textPosition;t.insideRollback=va(t,o,i),t.insideOriginalTextPosition=o,t.insideRollbackOpt=i}null==t.textFill&&(t.textFill=i.autoColor)}t.fontStyle=e.getShallow("fontStyle")||n.fontStyle,t.fontWeight=e.getShallow("fontWeight")||n.fontWeight,t.fontSize=e.getShallow("fontSize")||n.fontSize,t.fontFamily=e.getShallow("fontFamily")||n.fontFamily,t.textAlign=e.getShallow("align"),t.textVerticalAlign=e.getShallow("verticalAlign")||e.getShallow("baseline"),t.textLineHeight=e.getShallow("lineHeight"),t.textWidth=e.getShallow("width"),t.textHeight=e.getShallow("height"),t.textTag=e.getShallow("tag"),a&&i.disableBox||(t.textBackgroundColor=ma(e.getShallow("backgroundColor"),i),t.textPadding=e.getShallow("padding"),t.textBorderColor=ma(e.getShallow("borderColor"),i),t.textBorderWidth=e.getShallow("borderWidth"),t.textBorderRadius=e.getShallow("borderRadius"),t.textBoxShadowColor=e.getShallow("shadowColor"),t.textBoxShadowBlur=e.getShallow("shadowBlur"),t.textBoxShadowOffsetX=e.getShallow("shadowOffsetX"),t.textBoxShadowOffsetY=e.getShallow("shadowOffsetY")),t.textShadowColor=e.getShallow("textShadowColor")||n.textShadowColor,t.textShadowBlur=e.getShallow("textShadowBlur")||n.textShadowBlur,t.textShadowOffsetX=e.getShallow("textShadowOffsetX")||n.textShadowOffsetX,t.textShadowOffsetY=e.getShallow("textShadowOffsetY")||n.textShadowOffsetY}function ma(t,e){return"auto"!==t?t:e&&e.autoColor?e.autoColor:null}function va(t,e,n){var i,r=n.useInsideStyle;return null==t.textFill&&r!==!1&&(r===!0||n.isRectText&&e&&"string"==typeof e&&e.indexOf("inside")>=0)&&(i={textFill:null,textStroke:t.textStroke,textStrokeWidth:t.textStrokeWidth},t.textFill="#fff",null==t.textStroke&&(t.textStroke=n.autoColor,null==t.textStrokeWidth&&(t.textStrokeWidth=2))),i}function ya(t){var e=t.insideRollback;e&&(t.textFill=e.textFill,t.textStroke=e.textStroke,t.textStrokeWidth=e.textStrokeWidth)}function xa(t,e){var n=e||e.getModel("textStyle");return z([t.fontStyle||n&&n.getShallow("fontStyle")||"",t.fontWeight||n&&n.getShallow("fontWeight")||"",(t.fontSize||n&&n.getShallow("fontSize")||12)+"px",t.fontFamily||n&&n.getShallow("fontFamily")||"sans-serif"].join(" "))}function _a(t,e,n,i,r,a){"function"==typeof r&&(a=r,r=null);var o=i&&i.isAnimationEnabled();if(o){var s=t?"Update":"",l=i.getShallow("animationDuration"+s),h=i.getShallow("animationEasing"+s),u=i.getShallow("animationDelay"+s);"function"==typeof u&&(u=u(r,i.getAnimationDelayParams?i.getAnimationDelayParams(e,r):null)),"function"==typeof l&&(l=l(r)),l>0?e.animateTo(n,l,u||0,h,a,!!a):(e.stopAnimation(),e.attr(n),a&&a())}else e.stopAnimation(),e.attr(n),a&&a()}function wa(t,e,n,i,r){_a(!0,t,e,n,i,r)}function ba(t,e,n,i,r){_a(!1,t,e,n,i,r)}function Sa(t,e){for(var n=pe([]);t&&t!==e;)me(n,t.getLocalTransform(),n),t=t.parent;return n}function Ma(t,e,n){return e&&!d(e)&&(e=Bf.getLocalTransform(e)),n&&(e=_e([],e)),ae([],t,e)}function Ia(t,e,n){var i=0===e[4]||0===e[5]||0===e[0]?1:Math.abs(2*e[4]/e[0]),r=0===e[4]||0===e[5]||0===e[2]?1:Math.abs(2*e[4]/e[2]),a=["left"===t?-i:"right"===t?i:0,"top"===t?-r:"bottom"===t?r:0];return a=Ma(a,e,n),Math.abs(a[0])>Math.abs(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"}function Ta(t,e,n){function i(t){var e={};return t.traverse(function(t){!t.isGroup&&t.anid&&(e[t.anid]=t)}),e}function r(t){var e={position:W(t.position),rotation:t.rotation};return t.shape&&(e.shape=o({},t.shape)),e}if(t&&e){var a=i(t);e.traverse(function(t){if(!t.isGroup&&t.anid){var e=a[t.anid];if(e){var i=r(t);t.attr(r(e)),wa(t,i,n,t.dataIndex)}}})}}function Ca(t,e){return p(t,function(t){var n=t[0];n=Hm(n,e.x),n=Wm(n,e.x+e.width);var i=t[1];return i=Hm(i,e.y),i=Wm(i,e.y+e.height),[n,i]})}function Da(t,e){var n=Hm(t.x,e.x),i=Wm(t.x+t.width,e.x+e.width),r=Hm(t.y,e.y),a=Wm(t.y+t.height,e.y+e.height);return i>=n&&a>=r?{x:n,y:r,width:i-n,height:a-r}:void 0}function Aa(t,e,n){e=o({rectHover:!0},e);var i=e.style={strokeNoScale:!0};return n=n||{x:-1,y:-1,width:2,height:2},t?0===t.indexOf("image://")?(i.image=t.slice(8),s(i,n),new ai(e)):Xr(t.replace("path://",""),e,n,"center"):void 0}function ka(t,e,n){this.parentModel=e,this.ecModel=n,this.option=t}function Pa(t,e,n){for(var i=0;i=0&&n.push(t)}),n}t.topologicalTravel=function(t,e,i,r){function a(t){l[t].entryCount--,0===l[t].entryCount&&h.push(t)}function o(t){u[t]=!0,a(t)}if(t.length){var s=n(e),l=s.graph,h=s.noEntryList,u={};for(f(t,function(t){u[t]=!0});h.length;){var c=h.pop(),d=l[c],p=!!u[c];p&&(i.call(r,c,d.originalDeps.slice()),delete u[c]),f(d.successor,p?o:a)}f(u,function(){throw new Error("Circle dependency may exists")})}}}function Ba(t){return t.replace(/^\s+/,"").replace(/\s+$/,"")}function Ea(t,e,n,i){var r=e[1]-e[0],a=n[1]-n[0];if(0===r)return 0===a?n[0]:(n[0]+n[1])/2;if(i)if(r>0){if(t<=e[0])return n[0];if(t>=e[1])return n[1]}else{if(t>=e[0])return n[0];if(t<=e[1])return n[1]}else{if(t===e[0])return n[0];if(t===e[1])return n[1]}return(t-e[0])/r*a+n[0]}function Na(t,e){switch(t){case"center":case"middle":t="50%";break;case"left":case"top":t="0%";break;case"right":case"bottom":t="100%"}return"string"==typeof t?Ba(t).match(/%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?0/0:+t}function Fa(t,e,n){return null==e&&(e=10),e=Math.min(Math.max(0,e),20),t=(+t).toFixed(e),n?t:+t}function Ga(t){return t.sort(function(t,e){return t-e}),t}function Va(t){if(t=+t,isNaN(t))return 0;for(var e=1,n=0;Math.round(t*e)/e!==t;)e*=10,n++;return n}function Ha(t){var e=t.toString(),n=e.indexOf("e");if(n>0){var i=+e.slice(n+1);return 0>i?-i:0}var r=e.indexOf(".");return 0>r?0:e.length-1-r}function Wa(t,e){var n=Math.log,i=Math.LN10,r=Math.floor(n(t[1]-t[0])/i),a=Math.round(n(Math.abs(e[1]-e[0]))/i),o=Math.min(Math.max(-r+a,0),20);return isFinite(o)?o:20}function Xa(t,e,n){if(!t[e])return 0;var i=g(t,function(t,e){return t+(isNaN(e)?0:e)},0);if(0===i)return 0;for(var r=Math.pow(10,n),a=p(t,function(t){return(isNaN(t)?0:t)/i*r*100}),o=100*r,s=p(a,function(t){return Math.floor(t)}),l=g(s,function(t,e){return t+e},0),h=p(a,function(t,e){return t-s[e]});o>l;){for(var u=Number.NEGATIVE_INFINITY,c=null,d=0,f=h.length;f>d;++d)h[d]>u&&(u=h[d],c=d);++s[c],h[c]=0,++l}return s[e]/r}function Za(t){var e=2*Math.PI;return(t%e+e)%e}function Ua(t){return t>-tv&&tv>t}function Ya(t){if(t instanceof Date)return t;if("string"==typeof t){var e=nv.exec(t);if(!e)return new Date(0/0);if(e[8]){var n=+e[4]||0;return"Z"!==e[8].toUpperCase()&&(n-=e[8].slice(0,3)),new Date(Date.UTC(+e[1],+(e[2]||1)-1,+e[3]||1,n,+(e[5]||0),+e[6]||0,+e[7]||0))}return new Date(+e[1],+(e[2]||1)-1,+e[3]||1,+e[4]||0,+(e[5]||0),+e[6]||0,+e[7]||0)}return new Date(null==t?0/0:Math.round(t))}function ja(t){return Math.pow(10,qa(t))}function qa(t){return Math.floor(Math.log(t)/Math.LN10)}function $a(t,e){var n,i=qa(t),r=Math.pow(10,i),a=t/r;return n=e?1.5>a?1:2.5>a?2:4>a?3:7>a?5:10:1>a?1:2>a?2:3>a?3:5>a?5:10,t=n*r,i>=-20?+t.toFixed(0>i?-i:0):t}function Ka(t){function e(t,n,i){return t.interval[i]s;s++)a[s]<=n&&(a[s]=n,o[s]=s?1:1-i),n=a[s],i=o[s];a[0]===a[1]&&o[0]*o[1]!==1?t.splice(r,1):r++}return t}function Ja(t){return t-parseFloat(t)>=0}function Qa(t){return isNaN(t)?"-":(t=(t+"").split("."),t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t.length>1?"."+t[1]:""))}function to(t,e){return t=(t||"").toLowerCase().replace(/-(.)/g,function(t,e){return e.toUpperCase()}),e&&t&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}function eo(t){return String(t).replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")}function no(t,e,n){_(e)||(e=[e]);var i=e.length;if(!i)return"";for(var r=e[0].$vars||[],a=0;as;s++)for(var l=0;l':'':""}function ao(t,e,n){("week"===t||"month"===t||"quarter"===t||"half-year"===t||"year"===t)&&(t="MM-dd\nyyyy");var i=Ya(e),r=n?"UTC":"",a=i["get"+r+"FullYear"](),o=i["get"+r+"Month"]()+1,s=i["get"+r+"Date"](),l=i["get"+r+"Hours"](),h=i["get"+r+"Minutes"](),u=i["get"+r+"Seconds"]();return t=t.replace("MM",sv(o)).replace("M",o).replace("yyyy",a).replace("yy",a%100).replace("dd",sv(s)).replace("d",s).replace("hh",sv(l)).replace("h",l).replace("mm",sv(h)).replace("m",h).replace("ss",sv(u)).replace("s",u)}function oo(t){return t?t.charAt(0).toUpperCase()+t.substr(1):t}function so(t,e,n,i,r){var a=0,o=0;null==i&&(i=1/0),null==r&&(r=1/0);var s=0;e.eachChild(function(l,h){var u,c,d=l.position,f=l.getBoundingRect(),p=e.childAt(h+1),g=p&&p.getBoundingRect();if("horizontal"===t){var m=f.width+(g?-g.x+f.x:0);u=a+m,u>i||l.newline?(a=0,u=m,o+=s+n,s=f.height):s=Math.max(s,f.height)}else{var v=f.height+(g?-g.y+f.y:0);c=o+v,c>r||l.newline?(a+=s+n,o=0,c=v,s=f.width):s=Math.max(s,f.width)}l.newline||(d[0]=a,d[1]=o,"horizontal"===t?a=u+n:o=c+n)})}function lo(t,e,n){n=rv(n||0);var i=e.width,r=e.height,a=Na(t.left,i),o=Na(t.top,r),s=Na(t.right,i),l=Na(t.bottom,r),h=Na(t.width,i),u=Na(t.height,r),c=n[2]+n[0],d=n[1]+n[3],f=t.aspect;switch(isNaN(h)&&(h=i-s-d-a),isNaN(u)&&(u=r-l-c-o),null!=f&&(isNaN(h)&&isNaN(u)&&(f>i/r?h=.8*i:u=.8*r),isNaN(h)&&(h=f*u),isNaN(u)&&(u=h/f)),isNaN(a)&&(a=i-s-h-d),isNaN(o)&&(o=r-l-u-c),t.left||t.right){case"center":a=i/2-h/2-n[3];break;case"right":a=i-h-d}switch(t.top||t.bottom){case"middle":case"center":o=r/2-u/2-n[0];break;case"bottom":o=r-u-c}a=a||0,o=o||0,isNaN(h)&&(h=i-d-a-(s||0)),isNaN(u)&&(u=r-c-o-(l||0));var p=new rn(a+n[3],o+n[0],h,u); +return p.margin=n,p}function ho(t,e,n){function i(n,i){var o={},l=0,h={},u=0,c=2;if(cv(n,function(e){h[e]=t[e]}),cv(n,function(t){r(e,t)&&(o[t]=h[t]=e[t]),a(o,t)&&l++,a(h,t)&&u++}),s[i])return a(e,n[1])?h[n[2]]=null:a(e,n[2])&&(h[n[1]]=null),h;if(u!==c&&l){if(l>=c)return o;for(var d=0;di;i++)if(t[i].length>e)return t[i];return t[n-1]}function go(t){var e=t.get("coordinateSystem"),n={coordSysName:e,coordSysDims:[],axisMap:N(),categoryAxisMap:N()},i=bv[e];return i?(i(t,n,n.axisMap,n.categoryAxisMap),n):void 0}function mo(t){return"category"===t.get("type")}function vo(t){this.fromDataset=t.fromDataset,this.data=t.data||(t.sourceFormat===Tv?{}:[]),this.sourceFormat=t.sourceFormat||Cv,this.seriesLayoutBy=t.seriesLayoutBy||Av,this.dimensionsDefine=t.dimensionsDefine,this.encodeDefine=t.encodeDefine&&N(t.encodeDefine),this.startIndex=t.startIndex||0,this.dimensionsDetectCount=t.dimensionsDetectCount}function yo(t){return Pv(t).source}function xo(t){Pv(t).datasetMap=N()}function _o(t){var e=t.option,n=e.data,i=I(n)?Dv:Sv,r=!1,a=e.seriesLayoutBy,o=e.sourceHeader,s=e.dimensions,l=To(t);if(l){var h=l.option;n=h.source,i=Pv(l).sourceFormat,r=!0,a=a||h.seriesLayoutBy,null==o&&(o=h.sourceHeader),s=s||h.dimensions}var u=wo(n,i,a,o,s),c=e.encode;!c&&l&&(c=Io(t,l,n,i,a,u)),Pv(t).source=new vo({data:n,fromDataset:r,seriesLayoutBy:a,sourceFormat:i,dimensionsDefine:u.dimensionsDefine,startIndex:u.startIndex,dimensionsDetectCount:u.dimensionsDetectCount,encodeDefine:c})}function wo(t,e,n,i,r){if(!t)return{dimensionsDefine:bo(r)};var a,o,s;if(e===Mv)"auto"===i||null==i?So(function(t){null!=t&&"-"!==t&&(b(t)?null==o&&(o=1):o=0)},n,t,10):o=i?1:0,r||1!==o||(r=[],So(function(t,e){r[e]=null!=t?t:""},n,t)),a=r?r.length:n===kv?t.length:t[0]?t[0].length:null;else if(e===Iv)r||(r=Mo(t),s=!0);else if(e===Tv)r||(r=[],s=!0,f(t,function(t,e){r.push(e)}));else if(e===Sv){var l=zi(t[0]);a=_(l)&&l.length||1}var h;return s&&f(r,function(t,e){"name"===(S(t)?t.name:t)&&(h=e)}),{startIndex:o,dimensionsDefine:bo(r),dimensionsDetectCount:a,potentialNameDimIndex:h}}function bo(t){if(t){var e=N();return p(t,function(t){if(t=o({},S(t)?t:{name:t}),null==t.name)return t;t.name+="",null==t.displayName&&(t.displayName=t.name);var n=e.get(t.name);return n?t.name+="-"+n.count++:e.set(t.name,{count:1}),t})}}function So(t,e,n,i){if(null==i&&(i=1/0),e===kv)for(var r=0;rr;r++)t(n[r]?n[r][0]:null,r);else for(var a=n[0]||[],r=0;rr;r++)t(a[r],r)}function Mo(t){for(var e,n=0;nx&&null==y;x++)Do(n,i,r,a.dimensionsDefine,a.startIndex,x)||(y=x);if(null!=y){s.value=y;var _=a.potentialNameDimIndex||Math.max(y-1,0);h.push(_),l.push(_)}}return l.length&&(s.itemName=l),h.length&&(s.seriesName=h),s}function To(t){var e=t.option,n=e.data;return n?void 0:t.ecModel.getComponent("dataset",e.datasetIndex||0)}function Co(t,e){return Do(t.data,t.sourceFormat,t.seriesLayoutBy,t.dimensionsDefine,t.startIndex,e)}function Do(t,e,n,i,r,a){function o(t){return null!=t&&isFinite(t)&&""!==t?!1:b(t)&&"-"!==t?!0:void 0}var s,l=5;if(I(t))return!1;var h;if(i&&(h=i[a],h=S(h)?h.name:h),e===Mv)if(n===kv){for(var u=t[a],c=0;c<(u||[]).length&&l>c;c++)if(null!=(s=o(u[r+c])))return s}else for(var c=0;cc;c++){var d=t[r+c];if(d&&null!=(s=o(d[a])))return s}else if(e===Iv){if(!h)return;for(var c=0;cc;c++){var f=t[c];if(f&&null!=(s=o(f[h])))return s}}else if(e===Tv){if(!h)return;var u=t[h];if(!u||I(u))return!1;for(var c=0;cc;c++)if(null!=(s=o(u[c])))return s}else if(e===Sv)for(var c=0;cc;c++){var f=t[c],p=zi(f);if(!_(p))return!1;if(null!=(s=o(p[a])))return s}return!1}function Ao(t,e){if(e){var n=e.seiresIndex,i=e.seriesId,r=e.seriesName;return null!=n&&t.componentIndex!==n||null!=i&&t.id!==i||null!=r&&t.name!==r}}function ko(t,e){f(e,function(e,n){vv.hasClass(n)||("object"==typeof e?t[n]=t[n]?r(t[n],e,!1):i(e):null==t[n]&&(t[n]=e))})}function Po(t){t=t,this.option={},this.option[Lv]=1,this._componentsMap=N({series:[]}),this._seriesIndices,this._seriesIndicesMap,ko(t,this._theme.option),r(t,xv,!1),this.mergeOption(t)}function Lo(t,e){_(e)||(e=e?[e]:[]);var n={};return f(e,function(e){n[e]=(t.get(e)||[]).slice()}),n}function Oo(t,e,n){var i=e.type?e.type:n?n.subType:vv.determineSubType(t,e);return i}function zo(t,e){t._seriesIndicesMap=N(t._seriesIndices=p(e,function(t){return t.componentIndex})||[])}function Ro(t,e){return e.hasOwnProperty("subType")?m(t,function(t){return t.subType===e.subType}):t}function Bo(t){f(zv,function(e){this[e]=y(t[e],t)},this)}function Eo(){this._coordinateSystems=[]}function No(t){this._api=t,this._timelineOptions=[],this._mediaList=[],this._mediaDefault,this._currentMediaIndices=[],this._optionBackup,this._newBaseOption}function Fo(t,e,n){var i,r,a=[],o=[],s=t.timeline;if(t.baseOption&&(r=t.baseOption),(s||t.options)&&(r=r||{},a=(t.options||[]).slice()),t.media){r=r||{};var l=t.media;Bv(l,function(t){t&&t.option&&(t.query?o.push(t):i||(i=t))})}return r||(r=t),r.timeline||(r.timeline=s),Bv([r].concat(a).concat(p(o,function(t){return t.option})),function(t){Bv(e,function(e){e(t,n)})}),{baseOption:r,timelineOptions:a,mediaDefault:i,mediaList:o}}function Go(t,e,n){var i={width:e,height:n,aspectratio:e/n},r=!0;return f(t,function(t,e){var n=e.match(Gv);if(n&&n[1]&&n[2]){var a=n[1],o=n[2].toLowerCase();Vo(i[o],t,a)||(r=!1)}}),r}function Vo(t,e,n){return"min"===n?t>=e:"max"===n?e>=t:t===e}function Ho(t,e){return t.join(",")===e.join(",")}function Wo(t,e){e=e||{},Bv(e,function(e,n){if(null!=e){var i=t[n];if(vv.hasClass(n)){e=Li(e),i=Li(i);var r=Bi(i,e);t[n]=Nv(r,function(t){return t.option&&t.exist?Fv(t.exist,t.option,!0):t.exist||t.option})}else t[n]=Fv(i,e,!0)}})}function Xo(t){var e=t&&t.itemStyle;if(e)for(var n=0,i=Wv.length;i>n;n++){var a=Wv[n],o=e.normal,s=e.emphasis;o&&o[a]&&(t[a]=t[a]||{},t[a].normal?r(t[a].normal,o[a]):t[a].normal=o[a],o[a]=null),s&&s[a]&&(t[a]=t[a]||{},t[a].emphasis?r(t[a].emphasis,s[a]):t[a].emphasis=s[a],s[a]=null)}}function Zo(t,e){if(t&&t[e]&&(t[e].normal||t[e].emphasis)){var n=t[e].normal,i=t[e].emphasis;n&&(t[e]=n),i&&(t.emphasis=t.emphasis||{},t.emphasis[e]=i)}}function Uo(t){Zo(t,"itemStyle"),Zo(t,"lineStyle"),Zo(t,"areaStyle"),Zo(t,"label"),Zo(t,"labelLine"),Zo(t,"upperLabel"),Zo(t,"edgeLabel")}function Yo(t){var e=Hv(t)&&t.textStyle;if(e)for(var n=0,i=ug.length;i>n;n++){var r=ug[n];e.hasOwnProperty(r)&&(t[r]=e[r])}}function jo(t){t&&(Uo(t),Yo(t.label),t.emphasis&&Yo(t.emphasis.label))}function qo(t){if(Hv(t)){Xo(t),Uo(t),Yo(t.label),Yo(t.upperLabel),Yo(t.edgeLabel),t.emphasis&&(Yo(t.emphasis.label),Yo(t.emphasis.upperLabel),Yo(t.emphasis.edgeLabel));var e=t.markPoint;e&&(Xo(e),jo(e));var n=t.markLine;n&&(Xo(n),jo(n));var i=t.markArea;i&&jo(i);var r=t.data;if("graph"===t.type){r=r||t.nodes;var a=t.links||t.edges;if(a&&!I(a))for(var o=0;oe.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function vs(t,e){f(t.CHANGABLE_METHODS,function(n){t.wrapMethod(n,x(ys,e))})}function ys(t){var e=xs(t);e&&e.setOutputEnd(this.count())}function xs(t){var e=(t.ecModel||{}).scheduler,n=e&&e.getPipeline(t.uid);if(n){var i=n.currentTask;if(i){var r=i.agentStubMap;r&&(i=r.get(t.uid))}return i}}function _s(){this.group=new hp,this.uid=Oa("viewChart"),this.renderTask=hs({plan:Ss,reset:Ms}),this.renderTask.context={view:this}}function ws(t,e){if(t&&(t.trigger(e),"group"===t.type))for(var n=0;n=0?i():c=setTimeout(i,-a),h=r};return d.clear=function(){c&&(clearTimeout(c),c=null)},d.debounceNextCall=function(t){l=t},d}function Cs(t,e,n,i){var r=t[e];if(r){var a=r[hy]||r,o=r[cy],s=r[uy];if(s!==n||o!==i){if(null==n||!i)return t[e]=a;r=t[e]=Ts(a,n,"debounce"===i),r[hy]=a,r[cy]=i,r[uy]=n}return r}}function Ds(t,e){this.ecInstance=t,this.api=e,this.unfinished,this._stageTaskMap=N()}function As(t,e,n,i,r){function a(t,e){return t.setDirty&&(!t.dirtyMap||t.dirtyMap.get(e.__pipeline.id))}r=r||{};var o;f(e,function(e){if(!r.visualType||r.visualType===e.visualType){var s=t._stageTaskMap.get(e.uid),l=s.seriesTaskMap,h=s.overallTask;if(h){var u,c=h.agentStubMap;c.each(function(t){a(r,t)&&(t.dirty(),u=!0)}),u&&h.dirty(),yy(h,i);var d=t.getPerformArgs(h,r.block);c.each(function(t){t.perform(d)}),o|=h.perform(d)}else l&&l.each(function(s){a(r,s)&&s.dirty();var l=t.getPerformArgs(s,r.block);l.skip=!e.performRawSeries&&n.isSeriesFiltered(s.context.model),yy(s,i),o|=s.perform(l)})}}),t.unfinished|=o}function ks(t,e,n,i,r){function a(n){var a=n.uid,s=o.get(a)||o.set(a,hs({plan:Bs,reset:Es,count:Fs}));s.context={model:n,ecModel:i,api:r,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:t},Gs(t,n,s)}var o=n.seriesTaskMap||(n.seriesTaskMap=N()),s=e.seriesType,l=e.getTargetSeries;e.createOnAllSeries?i.eachRawSeries(a):s?i.eachRawSeriesByType(s,a):l&&l(i,r).each(a);var h=t._pipelineMap;o.each(function(t,e){h.get(e)||(t.dispose(),o.removeKey(e))})}function Ps(t,e,n,i,r){function a(e){var n=e.uid,i=s.get(n)||s.set(n,hs({reset:Os,onDirty:Rs}));i.context={model:e,overallProgress:u,isOverallFilter:c},i.agent=o,i.__block=u,Gs(t,e,i)}var o=n.overallTask=n.overallTask||hs({reset:Ls});o.context={ecModel:i,api:r,overallReset:e.overallReset,scheduler:t};var s=o.agentStubMap=o.agentStubMap||N(),l=e.seriesType,h=e.getTargetSeries,u=!0,c=e.isOverallFilter;l?i.eachRawSeriesByType(l,a):h?h(i,r).each(a):(u=!1,f(i.getSeries(),a));var d=t._pipelineMap;s.each(function(t,e){d.get(e)||(t.dispose(),s.removeKey(e))})}function Ls(t){t.overallReset(t.ecModel,t.api,t.payload)}function Os(t){return t.overallProgress&&zs}function zs(){this.agent.dirty(),this.getDownstream().dirty()}function Rs(){this.agent&&this.agent.dirty()}function Bs(t){return t.plan&&t.plan(t.model,t.ecModel,t.api,t.payload)}function Es(t){t.useClearVisual&&t.data.clearAllVisual();var e=t.resetDefines=Li(t.reset(t.model,t.ecModel,t.api,t.payload));return e.length?Ns:void 0}function Ns(t,e){for(var n=e.data,i=e.resetDefines,r=0;re.get("hoverLayerThreshold")&&!of.node&&n.traverse(function(t){t.isGroup||(t.useHoverLayer=!0)})}function ll(t,e){var n=t.get("blendMode")||null;e.group.traverse(function(t){t.isGroup||t.style.blend!==n&&t.setStyle("blend",n),t.eachPendingDisplayable&&t.eachPendingDisplayable(function(t){t.setStyle("blend",n)})})}function hl(t,e){var n=t.get("z"),i=t.get("zlevel");e.group.traverse(function(t){"group"!==t.type&&(null!=n&&(t.z=n),null!=i&&(t.zlevel=i))})}function ul(t){var e=t._coordSysMgr;return o(new Bo(t),{getCoordinateSystems:y(e.getCoordinateSystems,e),getComponentByElement:function(e){for(;e;){var n=e.__ecComponentInfo;if(null!=n)return t._model.getComponent(n.mainType,n.index);e=e.parent}}})}function cl(t){function e(t,e){for(var n=0;n65535?e:n}function Wl(t){var e=t.constructor;return e===Array?t.slice():new e(t)}function Xl(t,e){f(xx.concat(e.__wrappedMethods||[]),function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t.__wrappedMethods=e.__wrappedMethods}function Zl(t){return t}function Ul(t){return t=0?this._indices[t]:-1}function Yl(t,e){var n=t._idList[e];return null==n&&(n=t._getIdFromStore(e)),null==n&&(n=vx+e),n}function jl(t){return _(t)||(t=[t]),t}function ql(t,e){var n=t.dimensions,i=new _x(p(n,t.getDimensionInfo,t),t.hostModel);Xl(i,t);for(var r=i._storage={},a=t._storage,o=0;o=0?$l(a[s]):a[s])}return i}function $l(t){for(var e=new Array(t.length),n=0;np;p++){var g=a[p]=o({},S(a[p])?a[p]:{name:a[p]}),m=g.name,v=c[p]={otherDims:{}};null!=m&&null==h.get(m)&&(v.name=v.displayName=m,h.set(m,p)),null!=g.type&&(v.type=g.type),null!=g.displayName&&(v.displayName=g.displayName)}l.each(function(t,e){t=Li(t).slice();var n=l.set(e,[]);f(t,function(t,i){b(t)&&(t=h.get(t)),null!=t&&d>t&&(n[i]=t,r(c[t],e,i))})});var y=0;f(t,function(t){var e,t,n,a;if(b(t))e=t,t={};else{e=t.name;var o=t.ordinalMeta;t.ordinalMeta=null,t=i(t),t.ordinalMeta=o,n=t.dimsDef,a=t.otherDims,t.name=t.coordDim=t.coordDimIndex=t.dimsDef=t.otherDims=null}var h=Li(l.get(e));if(!h.length)for(var u=0;u<(n&&n.length||1);u++){for(;y_;_++){var v=c[_]=c[_]||{},w=v.coordDim;null==w&&(v.coordDim=Ql(x,u,n.extraFromZero),v.coordDimIndex=0,v.isExtraCoord=!0),null==v.name&&(v.name=Ql(v.coordDim,h)),null==v.type&&Co(e,_,v.name)&&(v.type="ordinal")}return c}function Jl(t,e,n,i){return null==i&&(i=Math.max(t.dimensionsDetectCount||1,e.length,n.length),f(e,function(t){var e=t.dimsDef;e&&(i=Math.max(i,e.length))})),i}function Ql(t,e,n){if(n||null!=e.get(t)){for(var i=0;null!=e.get(t+i);)i++;t+=i}return e.set(t,!0),t}function th(t,e){vo.isInstance(t)||(t=vo.seriesDataToSource(t));var n,i=e.get("coordinateSystem"),r=Eo.get(i),a=go(e);a&&(n=p(a.coordSysDims,function(t){var e={name:t},n=a.axisMap.get(t);if(n){var i=n.get("type");e.type=Gl(i),e.stackable=eh(i)}return e})),n||(n=r&&(r.getDimensionsInfo?r.getDimensionsInfo():r.dimensions.slice())||["x","y"]);var o,s,l=Mx(t,{coordDimensions:n});a&&f(l,function(t,e){var n=t.coordDim,i=a.categoryAxisMap.get(n);i&&(null==o&&(o=e),t.ordinalMeta=i.getOrdinalMeta()),null!=t.otherDims.itemName&&(s=!0)}),s||null==o||(l[o].otherDims.itemName=0);var h=new _x(l,e),u=null!=o&&nh(t)?function(t,e,n,i){return i===o?n:this.defaultDimValueGetter(t,e,n,i)}:null;return h.hasItemOption=!1,h.initData(t,null,u),h}function eh(t){return"category"!==t&&"time"!==t}function nh(t){if(t.sourceFormat===Sv){var e=ih(t.data||[]);return null!=e&&!_(zi(e))}}function ih(t){for(var e=0;eo&&(o=r.interval=n),null!=i&&o>i&&(o=r.interval=i);var s=r.intervalPrecision=hh(o),l=r.niceTickExtent=[Dx(Math.ceil(t[0]/o)*o,s),Dx(Math.floor(t[1]/o)*o,s)];return ch(l,t),r}function hh(t){return Ha(t)+2}function uh(t,e,n){t[e]=Math.max(Math.min(t[e],n[1]),n[0])}function ch(t,e){!isFinite(t[0])&&(t[0]=e[0]),!isFinite(t[1])&&(t[1]=e[1]),uh(t,0,e),uh(t,1,e),t[0]>t[1]&&(t[0]=t[1])}function dh(t,e,n,i){var r=[];if(!t)return r;var a=1e4;e[0]a)return[];return e[1]>(r.length?r[r.length-1]:n[1])&&r.push(e[1]),r}function fh(t){return t.get("stack")||Px+t.seriesIndex}function ph(t){return t.dim+t.index}function gh(t,e){var n=p(t,function(t){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),r=i.getExtent(),a="category"===i.type?i.getBandWidth():Math.abs(r[1]-r[0])/e.count(),o=Na(t.get("barWidth"),a),s=Na(t.get("barMaxWidth"),a),l=t.get("barGap"),h=t.get("barCategoryGap");return{bandWidth:a,barWidth:o,barMaxWidth:s,barGap:l,barCategoryGap:h,axisKey:ph(i),stackId:fh(t)}});return mh(n,e)}function mh(t){var e={};f(t,function(t){var n=t.axisKey,i=t.bandWidth,r=e[n]||{bandWidth:i,remainedWidth:i,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},a=r.stacks;e[n]=r;var o=t.stackId;a[o]||r.autoWidthCount++,a[o]=a[o]||{width:0,maxWidth:0};var s=t.barWidth;s&&!a[o].width&&(a[o].width=s,s=Math.min(r.remainedWidth,s),r.remainedWidth-=s);var l=t.barMaxWidth;l&&(a[o].maxWidth=l);var h=t.barGap;null!=h&&(r.gap=h);var u=t.barCategoryGap;null!=u&&(r.categoryGap=u)});var n={};return f(e,function(t,e){n[e]={};var i=t.stacks,r=t.bandWidth,a=Na(t.categoryGap,r),o=Na(t.gap,1),s=t.remainedWidth,l=t.autoWidthCount,h=(s-a)/(l+(l-1)*o);h=Math.max(h,0),f(i,function(t){var e=t.maxWidth;e&&h>e&&(e=Math.min(e,s),t.width&&(e=Math.min(e,t.width)),s-=e,t.width=e,l--)}),h=(s-a)/(l+(l-1)*o),h=Math.max(h,0);var u,c=0;f(i,function(t){t.width||(t.width=h),u=t,c+=t.width*(1+o)}),u&&(c-=u.width*o);var d=-c/2;f(i,function(t,i){n[e][i]=n[e][i]||{offset:d,width:t.width},d+=t.width*(1+o)})}),n}function vh(t,e){var n=gh(m(e.getSeriesByType(t),function(t){return!e.isSeriesFiltered(t)&&t.coordinateSystem&&"cartesian2d"===t.coordinateSystem.type})),i={},r={};e.eachSeriesByType(t,function(t){if("cartesian2d"===t.coordinateSystem.type){var e=t.getData(),a=t.coordinateSystem,o=a.getBaseAxis(),s=fh(t),l=n[ph(o)][s],h=l.offset,u=l.width,c=a.getOtherAxis(o),d=t.get("barMinHeight")||0,f=o.onZero?c.toGlobalCoord(c.dataToCoord(0)):c.getGlobalExtent()[0],p=[e.mapDimension("x"),e.mapDimension("y")],g=e.mapArray(p,function(t,e){return a.dataToPoint([t,e])},!0);i[s]=i[s]||[],r[s]=r[s]||[],e.setLayout({offset:h,size:u}),e.each(e.mapDimension(c.dim),function(t,n){if(!isNaN(t)){i[s][n]||(i[s][n]={p:f,n:f},r[s][n]={p:f,n:f});var a,o,l,p,m=t>=0?"p":"n",v=g[n],y=i[s][n][m],x=r[s][n][m];c.isHorizontal()?(a=y,o=v[1]+h,l=v[0]-x,p=u,r[s][n][m]+=l,Math.abs(l)l?-1:1)*d),i[s][n][m]+=l):(a=v[0]+h,o=y,l=u,p=v[1]-x,r[s][n][m]+=p,Math.abs(p)=p?-1:1)*d),i[s][n][m]+=p),e.setItemLayout(n,{x:a,y:o,width:l,height:p})}},!0)}},this)}function yh(t,e){return Zx(t,Xx(e))}function xh(t,e){var n,i,r,a=t.type,o=e.getMin(),s=e.getMax(),l=null!=o,h=null!=s,u=t.getExtent();"ordinal"===a?n=e.getCategories().length:(i=e.get("boundaryGap"),_(i)||(i=[i||0,i||0]),"boolean"==typeof i[0]&&(i=[0,0]),i[0]=Na(i[0],1),i[1]=Na(i[1],1),r=u[1]-u[0]||Math.abs(u[0])),null==o&&(o="ordinal"===a?n?0:0/0:u[0]-i[0]*r),null==s&&(s="ordinal"===a?n?n-1:0/0:u[1]+i[1]*r),"dataMin"===o?o=u[0]:"function"==typeof o&&(o=o({min:u[0],max:u[1]})),"dataMax"===s?s=u[1]:"function"==typeof s&&(s=s({min:u[0],max:u[1]})),(null==o||!isFinite(o))&&(o=0/0),(null==s||!isFinite(s))&&(s=0/0),t.setBlank(C(o)||C(s)),e.getNeedCrossZero()&&(o>0&&s>0&&!l&&(o=0),0>o&&0>s&&!h&&(s=0));var c=e.ecModel;if(c){var d=m(c.getSeriesByType("bar"),function(t){return t.getBaseAxis()===e.axis}).length>0;if(("time"===a||"interval"===a)&&d){var f=_h(o,s,e);o=f.min,s=f.max}}return[o,s]}function _h(t,e,n){var i=n.ecModel,r=n.axis.getExtent(),a=r[1]-r[0],o=gh(m(i.getSeriesByType("bar"),function(t){return!i.isSeriesFiltered(t)&&t.coordinateSystem&&"cartesian2d"===t.coordinateSystem.type})),s=n.axis.dim+n.axis.index,l=o[s];if(void 0===l)return{min:t,max:e};var h=1/0;f(l,function(t){h=Math.min(t.offset,h)});var u=-1/0;f(l,function(t){u=Math.max(t.offset+t.width,u)});var c=Math.abs(h)+u,d=e-t,p=1-(h+u)/a,g=d/p-d;return e+=g*(u/c),t-=g*(h/c),{min:t,max:e}}function wh(t,e){var n=xh(t,e),i=null!=e.getMin(),r=null!=e.getMax(),a=e.get("splitNumber");"log"===t.type&&(t.base=e.get("logBase"));var o=t.type;t.setExtent(n[0],n[1]),t.niceExtent({splitNumber:a,fixMin:i,fixMax:r,minInterval:"interval"===o||"time"===o?e.get("minInterval"):null,maxInterval:"interval"===o||"time"===o?e.get("maxInterval"):null});var s=e.get("interval");null!=s&&t.setInterval&&t.setInterval(s)}function bh(t,e){if(e=e||t.get("type"))switch(e){case"category":return new Cx(t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),[1/0,-1/0]);case"value":return new kx;default:return(rh.getClass(e)||kx).create(t)}}function Sh(t){var e=t.scale.getExtent(),n=e[0],i=e[1];return!(n>0&&i>0||0>n&&0>i)}function Mh(t,e,n,i,r){var a,o=0,s=0,l=(i-r)/180*Math.PI,h=1;e.length>40&&(h=Math.floor(e.length/40));for(var u=0;u1?h:(o+1)*h-1}function Ih(t,e){var n=t.scale,i=n.getTicksLabels(),r=n.getTicks();return"string"==typeof e?(e=function(t){return function(e){return t.replace("{value}",null!=e?e:"")}}(e),p(i,e)):"function"==typeof e?p(r,function(n,i){return e(Th(t,n),i)},this):i}function Th(t,e){return"category"===t.type?t.scale.getLabel(e):e}function Ch(t,e){if("image"!==this.type){var n=this.style,i=this.shape;i&&"line"===i.symbolType?n.stroke=t:this.__isEmptyBrush?(n.stroke=t,n.fill=e||"#fff"):(n.fill&&(n.fill=t),n.stroke&&(n.stroke=t)),this.dirty(!1)}}function Dh(t,e,n,i,r,a,o){var s=0===t.indexOf("empty");s&&(t=t.substr(5,1).toLowerCase()+t.substr(6));var l;return l=0===t.indexOf("image://")?Zr(t.slice(8),new rn(e,n,i,r),o?"center":"cover"):0===t.indexOf("path://")?Xr(t.slice(7),{},new rn(e,n,i,r),o?"center":"cover"):new a_({shape:{symbolType:t,x:e,y:n,width:i,height:r}}),l.__isEmptyBrush=s,l.setColor=Ch,l.setColor(a),l}function Ah(t){return th(t.getSource(),t)}function kh(t,e){var n=e;ka.isInstance(e)||(n=new ka(e),c(n,Kx));var i=bh(n);return i.setExtent(t[0],t[1]),wh(i,n),i}function Ph(t){c(t,Kx)}function Lh(t,e){return Math.abs(t-e)>1^-(1&s),l=l>>1^-(1&l),s+=r,l+=a,r=s,a=l,i.push([s/n,l/n])}return i}function Eh(t,e){var n=t[1]-t[0],i=e,r=n/i/2;t[0]+=r,t[1]-=r}function Nh(t){return this._axes[t]}function Fh(t){p_.call(this,t)}function Gh(t,e){return e.type||(e.data?"category":"value")}function Vh(t,e){return t.getCoordSysModel()===e}function Hh(t,e){var n=e*Math.PI/180,i=t.plain(),r=i.width,a=i.height,o=r*Math.cos(n)+a*Math.sin(n),s=r*Math.sin(n)+a*Math.cos(n),l=new rn(i.x,i.y,o,s);return l}function Wh(t){var e,n=t.model,i=n.get("axisLabel.show")?n.getFormattedLabels():[],r=n.getModel("axisLabel"),a=1,o=i.length;o>40&&(a=Math.ceil(o/40));for(var s=0;o>s;s+=a)if(!t.isLabelIgnored(s)){var l=r.getTextRect(i[s]),h=Hh(l,r.get("rotate")||0);e?e.union(h):e=h}return e}function Xh(t,e,n){this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this._initCartesian(t,e,n),this.model=t}function Zh(t,e,n){var i=t[e];if(n.onZero){var r=n.onZeroAxisIndex;if(null!=r){var a=i[r];return void(a&&Uh(a)&&(n.onZero=!1))}for(var o in i)if(i.hasOwnProperty(o)){var a=i[o];if(a&&!Uh(a)){r=+o;break}}null==r&&(n.onZero=!1),n.onZeroAxisIndex=r}}function Uh(t){return"category"===t.type||"time"===t.type||!S_(t)}function Yh(t,e){var n=t.getExtent(),i=n[0]+n[1];t.toGlobalCoord="x"===t.dim?function(t){return t+e}:function(t){return i-t+e},t.toLocalCoord="x"===t.dim?function(t){return t-e}:function(t){return i-t+e}}function jh(t){return p(T_,function(e){var n=t.getReferringComponents(e)[0];return n})}function qh(t){return"cartesian2d"===t.get("coordinateSystem")}function $h(t,e){var n=t.mapDimension("defaultedLabel",!0),i=n.length;if(1===i)return ls(t,e,n[0]);if(i){for(var r=[],a=0;a0?"bottom":"top":r.width>0?"left":"right";l||Kh(t.style,d,i,h,a,n,p),ha(t,d)}function nu(t,e){var n=t.get(k_)||0;return Math.min(n,Math.abs(e.width),Math.abs(e.height))}function iu(t){var e={componentType:t.mainType};return e[t.mainType+"Index"]=t.componentIndex,e}function ru(t,e,n,i){var r,a,o=Za(n-t.rotation),s=i[0]>i[1],l="start"===e&&!s||"start"!==e&&s;return Ua(o-O_/2)?(a=l?"bottom":"top",r="center"):Ua(o-1.5*O_)?(a=l?"top":"bottom",r="center"):(a="middle",r=1.5*O_>o&&o>O_/2?l?"left":"right":l?"right":"left"),{rotation:o,textAlign:r,textVerticalAlign:a}}function au(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)}function ou(t,e,n){var i=t.get("axisLabel.showMinLabel"),r=t.get("axisLabel.showMaxLabel");e=e||[],n=n||[];var a=e[0],o=e[1],s=e[e.length-1],l=e[e.length-2],h=n[0],u=n[1],c=n[n.length-1],d=n[n.length-2];i===!1?(su(a),su(h)):lu(a,o)&&(i?(su(o),su(u)):(su(a),su(h))),r===!1?(su(s),su(c)):lu(l,s)&&(r?(su(l),su(d)):(su(s),su(c)))}function su(t){t&&(t.ignore=!0)}function lu(t,e){var n=t&&t.getBoundingRect().clone(),i=e&&e.getBoundingRect().clone();if(n&&i){var r=pe([]);return ye(r,r,-t.rotation),n.applyTransform(me([],r,t.getLocalTransform())),i.applyTransform(me([],r,e.getLocalTransform())),n.intersect(i)}}function hu(t){return"middle"===t||"center"===t}function uu(t,e,n){var i=e.axis;if(e.get("axisTick.show")&&!i.scale.isBlank()){for(var r=e.getModel("axisTick"),a=r.getModel("lineStyle"),o=r.get("length"),l=N_(r,n.labelInterval),h=i.getTicksCoords(r.get("alignWithLabel")),u=i.scale.getTicks(),c=e.get("axisLabel.showMinLabel"),d=e.get("axisLabel.showMaxLabel"),f=[],p=[],g=t._transform,m=[],v=h.length,y=0;v>y;y++)if(!E_(i,y,l,v,c,d)){var x=h[y];f[0]=x,f[1]=0,p[0]=x,p[1]=n.tickDirection*o,g&&(ae(f,f,g),ae(p,p,g));var _=new Lm(jr({anid:"tick_"+u[y],shape:{x1:f[0],y1:f[1],x2:p[0],y2:p[1]},style:s(a.getLineStyle(),{stroke:e.get("axisLine.lineStyle.color")}),z2:2,silent:!0}));t.group.add(_),m.push(_)}return m}}function cu(t,e,n){var i=e.axis,r=D(n.axisLabelShow,e.get("axisLabel.show"));if(r&&!i.scale.isBlank()){var a=e.getModel("axisLabel"),o=a.get("margin"),s=i.scale.getTicks(),l=e.getFormattedLabels(),h=(D(n.labelRotate,a.get("rotate"))||0)*O_/180,u=B_(n.rotation,h,n.labelDirection),c=e.getCategories(),d=[],p=au(e),g=e.get("triggerEvent"),m=e.get("axisLabel.showMinLabel"),v=e.get("axisLabel.showMaxLabel");return f(s,function(r,h){if(!E_(i,h,n.labelInterval,s.length,m,v)){var f=a;c&&c[r]&&c[r].textStyle&&(f=new ka(c[r].textStyle,a,e.ecModel));var y=f.getTextColor()||e.get("axisLine.lineStyle.color"),x=i.dataToCoord(r),_=[x,n.labelOffset+n.labelDirection*o],w=i.scale.getLabel(r),b=new wm({anid:"label_"+r,position:_,rotation:u.rotation,silent:p,z2:10});ca(b.style,f,{text:l[h],textAlign:f.getShallow("align",!0)||u.textAlign,textVerticalAlign:f.getShallow("verticalAlign",!0)||f.getShallow("baseline",!0)||u.textVerticalAlign,textFill:"function"==typeof y?y("category"===i.type?w:"value"===i.type?r+"":r,h):y}),g&&(b.eventData=iu(e),b.eventData.targetType="axisLabel",b.eventData.value=w),t._dumbGroup.add(b),b.updateTransform(),d.push(b),t.group.add(b),b.decomposeTransform()}}),d}}function du(t,e){var n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return fu(n,t,e),n.seriesInvolved&&gu(n,t),n}function fu(t,e,n){var i=e.getComponent("tooltip"),r=e.getComponent("axisPointer"),a=r.get("link",!0)||[],o=[];F_(n.getCoordinateSystems(),function(n){function s(i,s,l){var u=l.model.getModel("axisPointer",r),d=u.get("show");if(d&&("auto"!==d||i||wu(u))){null==s&&(s=u.get("triggerTooltip")),u=i?pu(l,c,r,e,i,s):u;var f=u.get("snap"),p=bu(l.model),g=s||f||"category"===l.type,m=t.axesInfo[p]={key:p,axis:l,coordSys:n,axisPointerModel:u,triggerTooltip:s,involveSeries:g,snap:f,useHandle:wu(u),seriesModels:[]};h[p]=m,t.seriesInvolved|=g;var v=mu(a,l);if(null!=v){var y=o[v]||(o[v]={axesInfo:{}});y.axesInfo[p]=m,y.mapper=a[v].mapper,m.linkGroup=y}}}if(n.axisPointerEnabled){var l=bu(n.model),h=t.coordSysAxesInfo[l]={};t.coordSysMap[l]=n;var u=n.model,c=u.getModel("tooltip",i);if(F_(n.getAxes(),G_(s,!1,null)),n.getTooltipAxes&&i&&c.get("show")){var d="axis"===c.get("trigger"),f="cross"===c.get("axisPointer.type"),p=n.getTooltipAxes(c.get("axisPointer.axis"));(d||f)&&F_(p.baseAxes,G_(s,f?"cross":!0,d)),f&&F_(p.otherAxes,G_(s,"cross",!1))}}})}function pu(t,e,n,r,a,o){var l=e.getModel("axisPointer"),h={};F_(["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],function(t){h[t]=i(l.get(t))}),h.snap="category"!==t.type&&!!o,"cross"===l.get("type")&&(h.type="line");var u=h.label||(h.label={});if(null==u.show&&(u.show=!1),"cross"===a&&(u.show=!0,!o)){var c=h.lineStyle=l.get("crossStyle");c&&s(u,c.textStyle)}return t.model.getModel("axisPointer",new ka(h,n,r))}function gu(t,e){e.eachSeries(function(e){var n=e.coordinateSystem,i=e.get("tooltip.trigger",!0),r=e.get("tooltip.show",!0);n&&"none"!==i&&i!==!1&&"item"!==i&&r!==!1&&e.get("axisPointer.show",!0)!==!1&&F_(t.coordSysAxesInfo[bu(n.model)],function(t){var i=t.axis;n.getAxis(i.dim)===i&&(t.seriesModels.push(e),null==t.seriesDataCount&&(t.seriesDataCount=0),t.seriesDataCount+=e.getData().count())})},this)}function mu(t,e){for(var n=e.model,i=e.dim,r=0;r=0||t===e}function yu(t){var e=xu(t);if(e){var n=e.axisPointerModel,i=e.axis.scale,r=n.option,a=n.get("status"),o=n.get("value");null!=o&&(o=i.parse(o));var s=wu(n);null==a&&(r.status=s?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(null==o||o>l[1])&&(o=l[1]),o=0?1:-1}function zu(t,e,n){for(var i,r=t.getBaseAxis(),a=t.getOtherAxis(r),o=r.onZero?0:a.scale.getExtent()[0],s=a.dim,l="x"===s||"radius"===s?1:0,h=e.stackedOn,u=e.get(s,n);h&&Ou(h.get(s,n))===Ou(u);){i=h;break}var c=[];return c[l]=e.get(r.dim,n),c[1-l]=i?i.get(s,n,!0):o,t.dataToPoint(c)}function Ru(t,e){var n=[];return e.diff(t).add(function(t){n.push({cmd:"+",idx:t})}).update(function(t,e){n.push({cmd:"=",idx:e,idx1:t})}).remove(function(t){n.push({cmd:"-",idx:t})}).execute(),n}function Bu(t){return isNaN(t[0])||isNaN(t[1])}function Eu(t,e,n,i,r,a,o,s,l,h,u){for(var c=0,d=n,f=0;i>f;f++){var p=e[d];if(d>=r||0>d)break;if(Bu(p)){if(u){d+=a;continue}break}if(d===n)t[a>0?"moveTo":"lineTo"](p[0],p[1]),rw(ow,p);else if(l>0){var g=d+a,m=e[g];if(u)for(;m&&Bu(e[g]);)g+=a,m=e[g];var v=.5,y=e[c],m=e[g];if(!m||Bu(m))rw(sw,p);else{Bu(m)&&!u&&(m=p),Y(aw,m,y);var x,_;if("x"===h||"y"===h){var w="x"===h?0:1;x=Math.abs(p[w]-y[w]),_=Math.abs(p[w]-m[w])}else x=Mf(p,y),_=Mf(p,m);v=_/(_+x),iw(sw,p,aw,-l*(1-v))}ew(ow,ow,s),nw(ow,ow,o),ew(sw,sw,s),nw(sw,sw,o),t.bezierCurveTo(ow[0],ow[1],sw[0],sw[1],p[0],p[1]),iw(ow,p,aw,l*v)}else t.lineTo(p[0],p[1]);c=d,d+=a}return f}function Nu(t,e){var n=[1/0,1/0],i=[-1/0,-1/0];if(e)for(var r=0;ri[0]&&(i[0]=a[0]),a[1]>i[1]&&(i[1]=a[1])}return{min:e?n:i,max:e?i:n}}function Fu(t,e){if(t.length===e.length){for(var n=0;ne[0]?1:-1;e[0]+=i*n,e[1]-=i*n}return e}function Hu(t){return t>=0?1:-1}function Wu(t,e,n,i){var r=e.getBaseAxis(),a=e.getOtherAxis(r),o=0,s=a.scale.getExtent();if("start"===i)o=s[0];else if("end"===i)o=s[1];else{var s=a.scale.getExtent();s[0]>0?o=s[0]:s[1]<0&&(o=s[1])}var l=a.dim,h="x"===l||"radius"===l?1:0,u=n.mapDimension(l);return n.mapArray(u?[u]:[],function(t,i){for(var a,s=n.stackedOn;s&&Hu(s.get(u,i))===Hu(t);){a=s;break}var l=[];return l[h]=n.get(r.dim,i),l[1-h]=a?a.get(u,i,!0):o,e.dataToPoint(l)},!0)}function Xu(t,e,n){var i=Vu(t.getAxis("x")),r=Vu(t.getAxis("y")),a=t.getBaseAxis().isHorizontal(),o=Math.min(i[0],i[1]),s=Math.min(r[0],r[1]),l=Math.max(i[0],i[1])-o,h=Math.max(r[0],r[1])-s,u=n.get("lineStyle.width")||2,c=n.get("clipOverflow")?u/2:Math.max(l,h);a?(s-=c,h+=2*c):(o-=c,l+=2*c);var d=new Pm({shape:{x:o,y:s,width:l,height:h}});return e&&(d.shape[a?"width":"height"]=0,ba(d,{shape:{width:l,height:h}},n)),d}function Zu(t,e,n){var i=t.getAngleAxis(),r=t.getRadiusAxis(),a=r.getExtent(),o=i.getExtent(),s=Math.PI/180,l=new Im({shape:{cx:t.cx,cy:t.cy,r0:a[0],r:a[1],startAngle:-o[0]*s,endAngle:-o[1]*s,clockwise:i.inverse}});return e&&(l.shape.endAngle=-o[0]*s,ba(l,{shape:{endAngle:-o[1]*s}},n)),l}function Uu(t,e,n){return"polar"===t.type?Zu(t,e,n):Xu(t,e,n)}function Yu(t,e,n){for(var i=e.getBaseAxis(),r="x"===i.dim||"radius"===i.dim?0:1,a=[],o=0;o=0;r--)if(n[r].dimension<2){i=n[r];break}if(i&&"cartesian2d"===e.type){var a=i.dimension,o=t.dimensions[a],s=e.getAxis(o),l=p(i.stops,function(t){return{coord:s.toGlobalCoord(s.dataToCoord(t.value)),color:t.color}}),h=l.length,u=i.outerColors.slice();h&&l[0].coord>l[h-1].coord&&(l.reverse(),u.reverse());var c=10,d=l[0].coord-c,g=l[h-1].coord+c,m=g-d;if(.001>m)return"transparent";f(l,function(t){t.offset=(t.coord-d)/m}),l.push({offset:h?l[h-1].offset:.5,color:u[1]||"transparent"}),l.unshift({offset:h?l[0].offset:.5,color:u[0]||"transparent"});var v=new Nm(0,0,0,0,l,!0);return v[o]=d,v[o+"2"]=g,v}}}function qu(t,e,n,i){var r=e.getData(),a=this.dataIndex,o=r.getName(a),s=e.get("selectedOffset");i.dispatchAction({type:"pieToggleSelect",from:t,name:o,seriesId:e.id}),r.each(function(t){$u(r.getItemGraphicEl(t),r.getItemLayout(t),e.isSelected(r.getName(t)),s,n)})}function $u(t,e,n,i,r){var a=(e.startAngle+e.endAngle)/2,o=Math.cos(a),s=Math.sin(a),l=n?i:0,h=[o*l,s*l];r?t.animate().when(200,{position:h}).start("bounceOut"):t.attr("position",h)}function Ku(t,e){function n(){a.ignore=a.hoverIgnore,o.ignore=o.hoverIgnore}function i(){a.ignore=a.normalIgnore,o.ignore=o.normalIgnore}hp.call(this);var r=new Im({z2:2}),a=new km,o=new wm;this.add(r),this.add(a),this.add(o),this.updateData(t,e,!0),this.on("emphasis",n).on("normal",i).on("mouseover",n).on("mouseout",i)}function Ju(t,e,n,i,r,a,o){function s(e,n,i){for(var r=e;n>r;r++)if(t[r].y+=i,r>e&&n>r+1&&t[r+1].y>t[r].y+t[r].height)return void l(r,i/2);l(n-1,i/2)}function l(e,n){for(var i=e;i>=0&&(t[i].y-=n,!(i>0&&t[i].y>t[i-1].y+t[i-1].height));i--);}function h(t,e,n,i,r,a){for(var o=a>0?e?Number.MAX_VALUE:0:e?Number.MAX_VALUE:0,s=0,l=t.length;l>s;s++)if("center"!==t[s].position){var h=Math.abs(t[s].y-i),u=t[s].len,c=t[s].len2,d=r+u>h?Math.sqrt((r+u+c)*(r+u+c)-h*h):Math.abs(t[s].x-n);e&&d>=o&&(d=o-10),!e&&o>=d&&(d=o+10),t[s].x=n+d*a,o=d}}t.sort(function(t,e){return t.y-e.y});for(var u,c=0,d=t.length,f=[],p=[],g=0;d>g;g++)u=t[g].y-c,0>u&&s(g,d,-u,r),c=t[g].y+t[g].height;0>o-c&&l(d-1,c-o);for(var g=0;d>g;g++)t[g].y>=n?p.push(t[g]):f.push(t[g]);h(f,!1,e,n,i,r),h(p,!0,e,n,i,r)}function Qu(t,e,n,i,r,a){for(var o=[],s=[],l=0;li;i++){var o=e[i].interval;if(o[0]<=t&&t<=o[1]){a=i;break}}if(i===r)for(var i=a-1;i>=0;i--){var o=e[i].interval;if(o[0]<=t&&t<=o[1]){a=i;break}}return i>=0&&r>i&&n[i]}}function sc(t,e){var n=t[1]-t[0];return e=[(e[0]-t[0])/n,(e[1]-t[0])/n],function(t){return t>=e[0]&&t<=e[1]}}function lc(t){var e=t.dimensions;return"lng"===e[0]&&"lat"===e[1]}function hc(t,e){return!!uc(t)[e]}function uc(t){return t[Bw]||(t[Bw]={})}function cc(t){this.pointerChecker,this._zr=t,this._opt={};var e=y,n=e(dc,this),r=e(fc,this),a=e(pc,this),o=e(gc,this),l=e(mc,this);Df.call(this),this.setPointerChecker=function(t){this.pointerChecker=t},this.enable=function(e,h){this.disable(),this._opt=s(i(h)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,preventDefaultMouseMove:!0}),null==e&&(e=!0),(e===!0||"move"===e||"pan"===e)&&(t.on("mousedown",n),t.on("mousemove",r),t.on("mouseup",a)),(e===!0||"scale"===e||"zoom"===e)&&(t.on("mousewheel",o),t.on("pinch",l))},this.disable=function(){t.off("mousedown",n),t.off("mousemove",r),t.off("mouseup",a),t.off("mousewheel",o),t.off("pinch",l)},this.dispose=this.disable,this.isDragging=function(){return this._dragging},this.isPinching=function(){return this._pinching}}function dc(t){if(!(yi(t)||t.target&&t.target.draggable)){var e=t.offsetX,n=t.offsetY;this.pointerChecker&&this.pointerChecker(t,e,n)&&(this._x=e,this._y=n,this._dragging=!0)}}function fc(t){if(!yi(t)&&yc(this,"moveOnMouseMove",t)&&this._dragging&&"pinch"!==t.gestureEvent&&!hc(this._zr,"globalPan")){var e=t.offsetX,n=t.offsetY,i=this._x,r=this._y,a=e-i,o=n-r;this._x=e,this._y=n,this._opt.preventDefaultMouseMove&&Wp(t.event),this.trigger("pan",a,o,i,r,e,n)}}function pc(t){yi(t)||(this._dragging=!1)}function gc(t){if(yc(this,"zoomOnMouseWheel",t)&&0!==t.wheelDelta){var e=t.wheelDelta>0?1.1:1/1.1;vc.call(this,t,e,t.offsetX,t.offsetY)}}function mc(t){if(!hc(this._zr,"globalPan")){var e=t.pinchScale>1?1.1:1/1.1;vc.call(this,t,e,t.pinchX,t.pinchY)}}function vc(t,e,n,i){this.pointerChecker&&this.pointerChecker(t,n,i)&&(Wp(t.event),this.trigger("zoom",e,n,i))}function yc(t,e,n){var i=t._opt[e];return i&&(!b(i)||n.event[i+"Key"])}function xc(t,e,n){var i=t.target,r=i.position;r[0]+=e,r[1]+=n,i.dirty()}function _c(t,e,n,i){var r=t.target,a=t.zoomLimit,o=r.position,s=r.scale,l=t.zoom=t.zoom||1;if(l*=e,a){var h=a.min||0,u=a.max||1/0;l=Math.max(Math.min(u,l),h)}var c=l/t.zoom;t.zoom=l,o[0]-=(n-o[0])*(c-1),o[1]-=(i-o[1])*(c-1),s[0]*=c,s[1]*=c,r.dirty()}function wc(t,e,n){var i=e.getComponentByElement(t.topTarget),r=i&&i.coordinateSystem;return i&&i!==n&&!Ew[i.mainType]&&r&&r.model!==n}function bc(t){var e=t.getItemStyle(),n=t.get("areaColor");return null!=n&&(e.fill=n),e}function Sc(t,e,n,i,r){n.off("click"),n.off("mousedown"),e.get("selectedMode")&&(n.on("mousedown",function(){t._mouseDownFlag=!0}),n.on("click",function(a){if(t._mouseDownFlag){t._mouseDownFlag=!1;for(var o=a.target;!o.__regions;)o=o.parent;if(o){var s={type:("geo"===e.mainType?"geo":"map")+"ToggleSelect",batch:p(o.__regions,function(t){return{name:t.name,from:r.uid}})};s[e.mainType+"Id"]=e.id,i.dispatchAction(s),Mc(e,n)}}}))}function Mc(t,e){e.eachChild(function(e){f(e.__regions,function(n){e.trigger(t.isSelected(n.name)?"emphasis":"normal")})})}function Ic(t,e){var n=new hp;this._controller=new cc(t.getZr()),this._controllerHost={target:e?n:null},this.group=n,this._updateGroup=e,this._mouseDownFlag}function Tc(t,e,n){var i=t.getZoom(),r=t.getCenter(),a=e.zoom,o=t.dataToPoint(r);if(null!=e.dx&&null!=e.dy){o[0]-=e.dx,o[1]-=e.dy;var r=t.pointToData(o);t.setCenter(r)}if(null!=a){if(n){var s=n.min||0,l=n.max||1/0;a=Math.max(Math.min(i*a,l),s)/i}t.scale[0]*=a,t.scale[1]*=a;var h=t.position,u=(e.originX-h[0])*(a-1),c=(e.originY-h[1])*(a-1);h[0]-=u,h[1]-=c,t.updateTransform();var r=t.pointToData(o);t.setCenter(r),t.setZoom(a*i)}return{center:t.getCenter(),zoom:t.getZoom()}}function Cc(){Bf.call(this)}function Dc(t){this.name=t,this.zoomLimit,Bf.call(this),this._roamTransformable=new Cc,this._rawTransformable=new Cc,this._center,this._zoom}function Ac(t,e,n,i){var r=n.seriesModel,a=r?r.coordinateSystem:null;return a===this?a[t](i):null}function kc(t,e,n,i,r){Dc.call(this,t),this.map=e,this._nameCoordMap=N(),this.loadGeoJson(n,i,r)}function Pc(t,e,n,i){var r=n.geoModel,a=n.seriesModel,o=r?r.coordinateSystem:a?a.coordinateSystem||(a.getReferringComponents("geo")[0]||{}).coordinateSystem:null;return o===this?o[t](i):null}function Lc(t,e){var n=t.get("boundingCoords");if(null!=n){var i=n[0],r=n[1];isNaN(i[0])||isNaN(i[1])||isNaN(r[0])||isNaN(r[1])||this.setBoundingRect(i[0],i[1],r[0]-i[0],r[1]-i[1])}var a,o=this.getBoundingRect(),s=t.get("layoutCenter"),l=t.get("layoutSize"),h=e.getWidth(),u=e.getHeight(),c=t.get("aspectScale")||.75,d=o.width/o.height*c,f=!1;s&&l&&(s=[Na(s[0],h),Na(s[1],u)],l=Na(l,Math.min(h,u)),isNaN(s[0])||isNaN(s[1])||isNaN(l)||(f=!0));var p;if(f){var p={};d>1?(p.width=l,p.height=l/d):(p.height=l,p.width=l*d),p.y=s[1]-p.height/2,p.x=s[0]-p.width/2}else a=t.getBoxLayoutParams(),a.aspect=d,p=lo(a,{width:h,height:u});this.setViewRect(p.x,p.y,p.width,p.height),this.setCenter(t.get("center")),this.setZoom(t.get("zoom"))}function Oc(t,e){f(e.get("geoCoord"),function(e,n){t.addGeoCoord(n,e)})}function zc(t,e){var n={};return f(t,function(t){t.each(t.mapDimension("value"),function(e,i){var r="ec-"+t.getName(i);n[r]=n[r]||[],isNaN(e)||n[r].push(e)})}),t[0].map(t[0].mapDimension("value"),function(i,r){for(var a="ec-"+t[0].getName(r),o=0,s=1/0,l=-1/0,h=n[a].length,u=0;h>u;u++)s=Math.min(s,n[a][u]),l=Math.max(l,n[a][u]),o+=n[a][u];var c;return c="min"===e?s:"max"===e?l:"average"===e?o/h:o,0===h?0/0:c})}function Rc(t,e){var n=t.get("center"),i=e.getWidth(),r=e.getHeight(),a=Math.min(i,r),o=Na(n[0],e.getWidth()),s=Na(n[1],e.getHeight()),l=Na(t.get("radius"),a/2);return{cx:o,cy:s,r:l}}function Bc(t,e){return e&&("string"==typeof e?t=e.replace("{value}",null!=t?t:""):"function"==typeof e&&(t=e(t))),t}function Ec(t,e,n,i){var r=t.getItemLayout(e),a=n.get("symbolRepeat"),o=n.get("symbolClip"),s=n.get("symbolPosition")||"start",l=n.get("symbolRotate"),h=(l||0)*Math.PI/180||0,u=n.get("symbolPatternSize")||2,c=n.isAnimationEnabled(),d={dataIndex:e,layout:r,itemModel:n,symbolType:t.getItemVisual(e,"symbol")||"circle",color:t.getItemVisual(e,"color"),symbolClip:o,symbolRepeat:a,symbolRepeatDirection:n.get("symbolRepeatDirection"),symbolPatternSize:u,rotation:h,animationModel:c?n:null,hoverAnimation:c&&n.get("hoverAnimation"),z2:n.getShallow("z",!0)||0};Nc(n,a,r,i,d),Gc(t,e,r,a,o,d.boundingLength,d.pxSign,u,i,d),Vc(n,d.symbolScale,h,i,d);var f=d.symbolSize,p=n.get("symbolOffset");return _(p)&&(p=[Na(p[0],f[0]),Na(p[1],f[1])]),Hc(n,f,r,a,o,p,s,d.valueLineWidth,d.boundingLength,d.repeatCutLength,i,d),d}function Nc(t,e,n,i,r){var a,o=i.valueDim,s=t.get("symbolBoundingData"),l=i.coordSys.getOtherAxis(i.coordSys.getBaseAxis()),h=l.toGlobalCoord(l.dataToCoord(0)),u=1-+(n[o.wh]<=0);if(_(s)){var c=[Fc(l,s[0])-h,Fc(l,s[1])-h];c[1]0?1:0>a?-1:0}function Fc(t,e){return t.toGlobalCoord(t.dataToCoord(t.scale.parse(e)))}function Gc(t,e,n,i,r,a,o,s,l,h){var u=l.valueDim,c=l.categoryDim,d=Math.abs(n[c.wh]),f=t.getItemVisual(e,"symbolSize");_(f)?f=f.slice():(null==f&&(f="100%"),f=[f,f]),f[c.index]=Na(f[c.index],d),f[u.index]=Na(f[u.index],i?d:Math.abs(a)),h.symbolSize=f;var p=h.symbolScale=[f[0]/s,f[1]/s];p[u.index]*=(l.isHorizontal?-1:1)*o}function Vc(t,e,n,i,r){var a=t.get(ab)||0;a&&(sb.attr({scale:e.slice(),rotation:n}),sb.updateTransform(),a/=sb.getLineScale(),a*=e[i.valueDim.index]),r.valueLineWidth=a}function Hc(t,e,n,i,r,a,s,l,h,u,c,d){var f=c.categoryDim,p=c.valueDim,g=d.pxSign,m=Math.max(e[p.index]+l,0),v=m;if(i){var y=Math.abs(h),x=D(t.get("symbolMargin"),"15%")+"",_=!1;x.lastIndexOf("!")===x.length-1&&(_=!0,x=x.slice(0,x.length-1)),x=Na(x,e[p.index]);var w=Math.max(m+2*x,0),b=_?0:2*x,S=Ja(i),M=S?i:ad((y+b)/w),I=y-M*m;x=I/2/(_?M:M-1),w=m+2*x,b=_?0:2*x,S||"fixed"===i||(M=u?ad((Math.abs(u)+b)/w):0),v=M*w-b,d.repeatTimes=M,d.symbolMargin=x}var T=g*(v/2),C=d.pathPosition=[];C[f.index]=n[f.wh]/2,C[p.index]="start"===s?T:"end"===s?h-T:h/2,a&&(C[0]+=a[0],C[1]+=a[1]);var A=d.bundlePosition=[];A[f.index]=n[f.xy],A[p.index]=n[p.xy];var k=d.barRectShape=o({},n);k[p.wh]=g*Math.max(Math.abs(n[p.wh]),Math.abs(C[p.index]+T)),k[f.wh]=n[f.wh];var P=d.clipShape={};P[f.xy]=-n[f.xy],P[f.wh]=c.ecSize[f.wh],P[p.xy]=0,P[p.wh]=n[p.wh]}function Wc(t){var e=t.symbolPatternSize,n=Dh(t.symbolType,-e/2,-e/2,e,e,t.color);return n.attr({culling:!0}),"image"!==n.type&&n.setStyle({strokeNoScale:!0}),n}function Xc(t,e,n,i){function r(t){var e=u.slice(),i=n.pxSign,r=t;return("start"===n.symbolRepeatDirection?i>0:0>i)&&(r=d-1-t),e[c.index]=p*(r-d/2+.5)+u[c.index],{position:e,scale:n.symbolScale.slice(),rotation:n.rotation}}function a(){nd(t,function(t){t.trigger("emphasis")})}function o(){nd(t,function(t){t.trigger("normal")})}var s=t.__pictorialBundle,l=n.symbolSize,h=n.valueLineWidth,u=n.pathPosition,c=e.valueDim,d=n.repeatTimes||0,f=0,p=l[e.valueDim.index]+h+2*n.symbolMargin;for(nd(t,function(t){t.__pictorialAnimationIndex=f,t.__pictorialRepeatTimes=d,d>f?id(t,null,r(f),n,i):id(t,null,{scale:[0,0]},n,i,function(){s.remove(t)}),Kc(t,n),f++});d>f;f++){var g=Wc(n);g.__pictorialAnimationIndex=f,g.__pictorialRepeatTimes=d,s.add(g);var m=r(f);id(g,{position:m.position,scale:[0,0]},{scale:m.scale,rotation:m.rotation},n,i),g.on("mouseover",a).on("mouseout",o),Kc(g,n)}}function Zc(t,e,n,i){function r(){this.trigger("emphasis")}function a(){this.trigger("normal")}var o=t.__pictorialBundle,s=t.__pictorialMainPath;s?id(s,null,{position:n.pathPosition.slice(),scale:n.symbolScale.slice(),rotation:n.rotation},n,i):(s=t.__pictorialMainPath=Wc(n),o.add(s),id(s,{position:n.pathPosition.slice(),scale:[0,0],rotation:n.rotation},{scale:n.symbolScale.slice()},n,i),s.on("mouseover",r).on("mouseout",a)),Kc(s,n)}function Uc(t,e,n){var i=o({},e.barRectShape),r=t.__pictorialBarRect;r?id(r,null,{shape:i},e,n):(r=t.__pictorialBarRect=new Pm({z2:2,shape:i,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),t.add(r))}function Yc(t,e,n,i){if(n.symbolClip){var r=t.__pictorialClipPath,a=o({},n.clipShape),s=e.valueDim,l=n.animationModel,h=n.dataIndex;if(r)wa(r,{shape:a},l,h);else{a[s.wh]=0,r=new Pm({shape:a}),t.__pictorialBundle.setClipPath(r),t.__pictorialClipPath=r;var u={};u[s.wh]=n.clipShape[s.wh],Um[i?"updateProps":"initProps"](r,{shape:u},l,h)}}}function jc(t,e){var n=t.getItemModel(e);return n.getAnimationDelayParams=qc,n.isAnimationEnabled=$c,n}function qc(t){return{index:t.__pictorialAnimationIndex,count:t.__pictorialRepeatTimes}}function $c(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function Kc(t,e){t.off("emphasis").off("normal");var n=e.symbolScale.slice();e.hoverAnimation&&t.on("emphasis",function(){this.animateTo({scale:[1.1*n[0],1.1*n[1]]},400,"elasticOut")}).on("normal",function(){this.animateTo({scale:n.slice()},400,"elasticOut")})}function Jc(t,e,n,i){var r=new hp,a=new hp;return r.add(a),r.__pictorialBundle=a,a.attr("position",n.bundlePosition.slice()),n.symbolRepeat?Xc(r,e,n):Zc(r,e,n),Uc(r,n,i),Yc(r,e,n,i),r.__pictorialShapeStr=ed(t,n),r.__pictorialSymbolMeta=n,r}function Qc(t,e,n){var i=n.animationModel,r=n.dataIndex,a=t.__pictorialBundle;wa(a,{position:n.bundlePosition.slice()},i,r),n.symbolRepeat?Xc(t,e,n,!0):Zc(t,e,n,!0),Uc(t,n,!0),Yc(t,e,n,!0)}function td(t,e,n,i){var r=i.__pictorialBarRect;r&&(r.style.text=null);var a=[];nd(i,function(t){a.push(t)}),i.__pictorialMainPath&&a.push(i.__pictorialMainPath),i.__pictorialClipPath&&(n=null),f(a,function(t){wa(t,{scale:[0,0]},n,e,function(){i.parent&&i.parent.remove(i)})}),t.setItemGraphicEl(e,null)}function ed(t,e){return[t.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function nd(t,e,n){f(t.__pictorialBundle.children(),function(i){i!==t.__pictorialBarRect&&e.call(n,i)})}function id(t,e,n,i,r,a){e&&t.attr(e),i.symbolClip&&!r?n&&t.attr(n):n&&Um[r?"updateProps":"initProps"](t,n,i.animationModel,i.dataIndex,a)}function rd(t,e,n){var i=n.color,r=n.dataIndex,a=n.itemModel,o=a.getModel("itemStyle").getItemStyle(["color"]),l=a.getModel("emphasis.itemStyle").getItemStyle(),h=a.getShallow("cursor");nd(t,function(t){t.setColor(i),t.setStyle(s({fill:i,opacity:n.opacity},o)),ha(t,l),h&&(t.cursor=h),t.z2=n.z2});var u={},c=e.valueDim.posDesc[+(n.boundingLength>0)],d=t.__pictorialBarRect;Kh(d.style,u,a,i,e.seriesModel,r,c),ha(d,u)}function ad(t){var e=Math.round(t);return Math.abs(t-e)<1e-4?e:Math.ceil(t)}function od(t,e,n){var i,r={},a="toggleSelected"===t;return n.eachComponent("legend",function(n){a&&null!=i?n[i?"select":"unSelect"](e.name):(n[t](e.name),i=n.isSelected(e.name)); +var o=n.getData();f(o,function(t){var e=t.get("name");if("\n"!==e&&""!==e){var i=n.isSelected(e);r[e]=r.hasOwnProperty(e)?r[e]&&i:i}})}),{name:e.name,selected:r}}function sd(t,e){var n=rv(e.get("padding")),i=e.getItemStyle(["color","opacity"]);i.fill=e.get("backgroundColor");var t=new Pm({shape:{x:t.x-n[3],y:t.y-n[0],width:t.width+n[1]+n[3],height:t.height+n[0]+n[2],r:e.get("borderRadius")},style:i,silent:!0,z2:-1});return t}function ld(t,e){e.dispatchAction({type:"legendToggleSelect",name:t})}function hd(t,e,n){var i=n.getZr().storage.getDisplayList()[0];i&&i.useHoverLayer||t.get("legendHoverLink")&&n.dispatchAction({type:"highlight",seriesName:t.name,name:e})}function ud(t,e,n){var i=n.getZr().storage.getDisplayList()[0];i&&i.useHoverLayer||t.get("legendHoverLink")&&n.dispatchAction({type:"downplay",seriesName:t.name,name:e})}function cd(t,e,n){var i=t.getOrient(),r=[1,1];r[i.index]=0,ho(e,n,{type:"box",ignoreSize:r})}function dd(t,e,n,i,r){var a=t.axis;if(!a.scale.isBlank()&&a.containData(e)){if(!t.involveSeries)return void n.showPointer(t,e);var s=fd(e,t),l=s.payloadBatch,h=s.snapToValue;l[0]&&null==r.seriesIndex&&o(r,l[0]),!i&&t.snap&&a.containData(h)&&null!=h&&(e=h),n.showPointer(t,e,l,r),n.showTooltip(t,s,h)}}function fd(t,e){var n=e.axis,i=n.dim,r=t,a=[],o=Number.MAX_VALUE,s=-1;return _b(e.seriesModels,function(e){var l,h,u=e.getData().mapDimension(i,!0);if(e.getAxisTooltipData){var c=e.getAxisTooltipData(u,t,n);h=c.dataIndices,l=c.nestestValue}else{if(h=e.getData().indicesOfNearest(u[0],t,!1,"category"===n.type?.5:null),!h.length)return;l=e.getData().get(u[0],h[0])}if(null!=l&&isFinite(l)){var d=t-l,f=Math.abs(d);o>=f&&((o>f||d>=0&&0>s)&&(o=f,s=d,r=l,a.length=0),_b(h,function(t){a.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})}))}}),{payloadBatch:a,snapToValue:r}}function pd(t,e,n,i){t[e.key]={value:n,payloadBatch:i}}function gd(t,e,n,i){var r=n.payloadBatch,a=e.axis,o=a.model,s=e.axisPointerModel;if(e.triggerTooltip&&r.length){var l=e.coordSys.model,h=bu(l),u=t.map[h];u||(u=t.map[h]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},t.list.push(u)),u.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:i,valueLabelOpt:{precision:s.get("label.precision"),formatter:s.get("label.formatter")},seriesDataIndices:r.slice()})}}function md(t,e,n){var i=n.axesInfo=[];_b(e,function(e,n){var r=e.axisPointerModel.option,a=t[n];a?(!e.useHandle&&(r.status="show"),r.value=a.value,r.seriesDataIndices=(a.payloadBatch||[]).slice()):!e.useHandle&&(r.status="hide"),"show"===r.status&&i.push({axisDim:e.axis.dim,axisIndex:e.axis.model.componentIndex,value:r.value})})}function vd(t,e,n,i){if(wd(e)||!t.list.length)return void i({type:"hideTip"});var r=((t.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:r.dataIndexInside,dataIndex:r.dataIndex,seriesIndex:r.seriesIndex,dataByCoordSys:t.list})}function yd(t,e,n){var i=n.getZr(),r="axisPointerLastHighlights",a=bb(i)[r]||{},o=bb(i)[r]={};_b(t,function(t){var e=t.axisPointerModel.option;"show"===e.status&&_b(e.seriesDataIndices,function(t){var e=t.seriesIndex+" | "+t.dataIndex;o[e]=t})});var s=[],l=[];f(a,function(t,e){!o[e]&&l.push(t)}),f(o,function(t,e){!a[e]&&s.push(t)}),l.length&&n.dispatchAction({type:"downplay",escapeConnect:!0,batch:l}),s.length&&n.dispatchAction({type:"highlight",escapeConnect:!0,batch:s})}function xd(t,e){for(var n=0;n<(t||[]).length;n++){var i=t[n];if(e.axis.dim===i.axisDim&&e.axis.model.componentIndex===i.axisIndex)return i}}function _d(t){var e=t.axis.model,n={},i=n.axisDim=t.axis.dim;return n.axisIndex=n[i+"AxisIndex"]=e.componentIndex,n.axisName=n[i+"AxisName"]=e.name,n.axisId=n[i+"AxisId"]=e.id,n}function wd(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}function bd(t,e,n){if(!of.node){var i=e.getZr();Mb(i).records||(Mb(i).records={}),Sd(i,e);var r=Mb(i).records[t]||(Mb(i).records[t]={});r.handler=n}}function Sd(t,e){function n(n,i){t.on(n,function(n){var r=Cd(e);Ib(Mb(t).records,function(t){t&&i(t,n,r.dispatchAction)}),Md(r.pendings,e)})}Mb(t).initialized||(Mb(t).initialized=!0,n("click",x(Td,"click")),n("mousemove",x(Td,"mousemove")),n("globalout",Id))}function Md(t,e){var n,i=t.showTip.length,r=t.hideTip.length;i?n=t.showTip[i-1]:r&&(n=t.hideTip[r-1]),n&&(n.dispatchAction=null,e.dispatchAction(n))}function Id(t,e,n){t.handler("leave",null,n)}function Td(t,e,n,i){e.handler(t,n,i)}function Cd(t){var e={showTip:[],hideTip:[]},n=function(i){var r=e[i.type];r?r.push(i):(i.dispatchAction=n,t.dispatchAction(i))};return{dispatchAction:n,pendings:e}}function Dd(t,e){if(!of.node){var n=e.getZr(),i=(Mb(n).records||{})[t];i&&(Mb(n).records[t]=null)}}function Ad(){}function kd(t,e,n,i){Pd(Cb(n).lastProp,i)||(Cb(n).lastProp=i,e?wa(n,i,t):(n.stopAnimation(),n.attr(i)))}function Pd(t,e){if(S(t)&&S(e)){var n=!0;return f(e,function(e,i){n=n&&Pd(t[i],e)}),!!n}return t===e}function Ld(t,e){t[e.get("label.show")?"show":"hide"]()}function Od(t){return{position:t.position.slice(),rotation:t.rotation||0}}function zd(t,e,n){var i=e.get("z"),r=e.get("zlevel");t&&t.traverse(function(t){"group"!==t.type&&(null!=i&&(t.z=i),null!=r&&(t.zlevel=r),t.silent=n)})}function Rd(t){var e,n=t.get("type"),i=t.getModel(n+"Style");return"line"===n?(e=i.getLineStyle(),e.fill=null):"shadow"===n&&(e=i.getAreaStyle(),e.stroke=null),e}function Bd(t,e,n,i,r){var a=n.get("value"),o=Nd(a,e.axis,e.ecModel,n.get("seriesDataIndices"),{precision:n.get("label.precision"),formatter:n.get("label.formatter")}),s=n.getModel("label"),l=rv(s.get("padding")||0),h=s.getFont(),u=Sn(o,h),c=r.position,d=u.width+l[1]+l[3],f=u.height+l[0]+l[2],p=r.align;"right"===p&&(c[0]-=d),"center"===p&&(c[0]-=d/2);var g=r.verticalAlign;"bottom"===g&&(c[1]-=f),"middle"===g&&(c[1]-=f/2),Ed(c,d,f,i);var m=s.get("backgroundColor");m&&"auto"!==m||(m=e.get("axisLine.lineStyle.color")),t.label={shape:{x:0,y:0,width:d,height:f,r:s.get("borderRadius")},position:c.slice(),style:{text:o,textFont:h,textFill:s.getTextColor(),textPosition:"inside",fill:m,stroke:s.get("borderColor")||"transparent",lineWidth:s.get("borderWidth")||0,shadowBlur:s.get("shadowBlur"),shadowColor:s.get("shadowColor"),shadowOffsetX:s.get("shadowOffsetX"),shadowOffsetY:s.get("shadowOffsetY")},z2:10}}function Ed(t,e,n,i){var r=i.getWidth(),a=i.getHeight();t[0]=Math.min(t[0]+e,r)-e,t[1]=Math.min(t[1]+n,a)-n,t[0]=Math.max(t[0],0),t[1]=Math.max(t[1],0)}function Nd(t,e,n,i,r){var a=e.scale.getLabel(t,{precision:r.precision}),o=r.formatter;if(o){var s={value:Th(e,t),seriesData:[]};f(i,function(t){var e=n.getSeriesByIndex(t.seriesIndex),i=t.dataIndexInside,r=e&&e.getDataParams(i);r&&s.seriesData.push(r)}),b(o)?a=o.replace("{value}",a):w(o)&&(a=o(s))}return a}function Fd(t,e,n){var i=fe();return ye(i,i,n.rotation),ve(i,i,n.position),Ma([t.dataToCoord(e),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],i)}function Gd(t,e,n,i,r,a){var o=z_.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=r.get("label.margin"),Bd(e,i,r,a,{position:Fd(i.axis,t,n),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function Vd(t,e,n){return n=n||0,{x1:t[n],y1:t[1-n],x2:e[n],y2:e[1-n]}}function Hd(t,e,n){return n=n||0,{x:t[n],y:t[1-n],width:e[n],height:e[1-n]}}function Wd(t,e){var n={};return n[e.dim+"AxisIndex"]=e.index,t.getCartesian(n)}function Xd(t){return"x"===t.dim?0:1}function Zd(t){var e="cubic-bezier(0.23, 1, 0.32, 1)",n="left "+t+"s "+e+",top "+t+"s "+e;return p(zb,function(t){return t+"transition:"+n}).join(";")}function Ud(t){var e=[],n=t.get("fontSize"),i=t.getTextColor();return i&&e.push("color:"+i),e.push("font:"+t.getFont()),n&&e.push("line-height:"+Math.round(3*n/2)+"px"),Lb(["decoration","align"],function(n){var i=t.get(n);i&&e.push("text-"+n+":"+i)}),e.join(";")}function Yd(t){var e=[],n=t.get("transitionDuration"),i=t.get("backgroundColor"),r=t.getModel("textStyle"),a=t.get("padding");return n&&e.push(Zd(n)),i&&(of.canvasSupported?e.push("background-Color:"+i):(e.push("background-Color:#"+Ne(i)),e.push("filter:alpha(opacity=70)"))),Lb(["width","color","radius"],function(n){var i="border-"+n,r=Ob(i),a=t.get(r);null!=a&&e.push(i+":"+a+("color"===n?"":"px"))}),e.push(Ud(r)),null!=a&&e.push("padding:"+rv(a).join("px ")+"px"),e.join(";")+";"}function jd(t,e){if(of.wxa)return null;var n=document.createElement("div"),i=this._zr=e.getZr();this.el=n,this._x=e.getWidth()/2,this._y=e.getHeight()/2,t.appendChild(n),this._container=t,this._show=!1,this._hideTimeout;var r=this;n.onmouseenter=function(){r._enterable&&(clearTimeout(r._hideTimeout),r._show=!0),r._inContent=!0},n.onmousemove=function(e){if(e=e||window.event,!r._enterable){var n=i.handler;gi(t,e,!0),n.dispatch("mousemove",e)}},n.onmouseleave=function(){r._enterable&&r._show&&r.hideLater(r._hideDelay),r._inContent=!1}}function qd(t){for(var e=t.pop();t.length;){var n=t.pop();n&&(ka.isInstance(n)&&(n=n.get("tooltip",!0)),"string"==typeof n&&(n={formatter:n}),e=new ka(n,e,e.ecModel))}return e}function $d(t,e){return t.dispatchAction||y(e.dispatchAction,e)}function Kd(t,e,n,i,r,a,o){var s=Qd(n),l=s.width,h=s.height;return null!=a&&(t+l+a>i?t-=l+a:t+=a),null!=o&&(e+h+o>r?e-=h+o:e+=o),[t,e]}function Jd(t,e,n,i,r){var a=Qd(n),o=a.width,s=a.height;return t=Math.min(t+o,i)-o,e=Math.min(e+s,r)-s,t=Math.max(t,0),e=Math.max(e,0),[t,e]}function Qd(t){var e=t.clientWidth,n=t.clientHeight;if(document.defaultView&&document.defaultView.getComputedStyle){var i=document.defaultView.getComputedStyle(t);i&&(e+=parseInt(i.paddingLeft,10)+parseInt(i.paddingRight,10)+parseInt(i.borderLeftWidth,10)+parseInt(i.borderRightWidth,10),n+=parseInt(i.paddingTop,10)+parseInt(i.paddingBottom,10)+parseInt(i.borderTopWidth,10)+parseInt(i.borderBottomWidth,10))}return{width:e,height:n}}function tf(t,e,n){var i=n[0],r=n[1],a=5,o=0,s=0,l=e.width,h=e.height;switch(t){case"inside":o=e.x+l/2-i/2,s=e.y+h/2-r/2;break;case"top":o=e.x+l/2-i/2,s=e.y-r-a;break;case"bottom":o=e.x+l/2-i/2,s=e.y+h+a;break;case"left":o=e.x-i-a,s=e.y+h/2-r/2;break;case"right":o=e.x+l+a,s=e.y+h/2-r/2}return[o,s]}function ef(t){return"center"===t||"middle"===t}var nf=2311,rf=function(){return nf++},af={};af="undefined"!=typeof wx?{browser:{},os:{},node:!1,wxa:!0,canvasSupported:!0,svgSupported:!1,touchEventsSupported:!0}:"undefined"==typeof document&&"undefined"!=typeof self?{browser:{},os:{},node:!1,worker:!0,canvasSupported:!0}:"undefined"==typeof navigator?{browser:{},os:{},node:!0,worker:!1,canvasSupported:!0,svgSupported:!0}:e(navigator.userAgent);var of=af,sf={"[object Function]":1,"[object RegExp]":1,"[object Date]":1,"[object Error]":1,"[object CanvasGradient]":1,"[object CanvasPattern]":1,"[object Image]":1,"[object Canvas]":1},lf={"[object Int8Array]":1,"[object Uint8Array]":1,"[object Uint8ClampedArray]":1,"[object Int16Array]":1,"[object Uint16Array]":1,"[object Int32Array]":1,"[object Uint32Array]":1,"[object Float32Array]":1,"[object Float64Array]":1},hf=Object.prototype.toString,uf=Array.prototype,cf=uf.forEach,df=uf.filter,ff=uf.slice,pf=uf.map,gf=uf.reduce,mf={},vf=function(){return mf.createCanvas()};mf.createCanvas=function(){return document.createElement("canvas")};var yf,xf="__ec_primitive__";E.prototype={constructor:E,get:function(t){return this.hasOwnProperty(t)?this[t]:null},set:function(t,e){return this[t]=e},each:function(t,e){void 0!==e&&(t=y(t,e));for(var n in this)this.hasOwnProperty(n)&&t(this[n],n)},removeKey:function(t){delete this[t]}};var _f=(Object.freeze||Object)({$override:n,clone:i,merge:r,mergeAll:a,extend:o,defaults:s,createCanvas:vf,getContext:l,indexOf:h,inherits:u,mixin:c,isArrayLike:d,each:f,map:p,reduce:g,filter:m,find:v,bind:y,curry:x,isArray:_,isFunction:w,isString:b,isObject:S,isBuiltInObject:M,isTypedArray:I,isDom:T,eqNaN:C,retrieve:D,retrieve2:A,retrieve3:k,slice:P,normalizeCssArray:L,assert:O,trim:z,setAsPrimitive:R,isPrimitive:B,createHashMap:N,concatArray:F,noop:G}),wf="undefined"==typeof Float32Array?Array:Float32Array,bf=j,Sf=q,Mf=ee,If=ne,Tf=(Object.freeze||Object)({create:V,copy:H,clone:W,set:X,add:Z,scaleAndAdd:U,sub:Y,len:j,length:bf,lenSquare:q,lengthSquare:Sf,mul:$,div:K,dot:J,scale:Q,normalize:te,distance:ee,dist:Mf,distanceSquare:ne,distSquare:If,negate:ie,lerp:re,applyTransform:ae,min:oe,max:se});le.prototype={constructor:le,_dragStart:function(t){var e=t.target;e&&e.draggable&&(this._draggingTarget=e,e.dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.dispatchToElement(he(e,t),"dragstart",t.event))},_drag:function(t){var e=this._draggingTarget;if(e){var n=t.offsetX,i=t.offsetY,r=n-this._x,a=i-this._y;this._x=n,this._y=i,e.drift(r,a,t),this.dispatchToElement(he(e,t),"drag",t.event);var o=this.findHover(n,i,e).target,s=this._dropTarget;this._dropTarget=o,e!==o&&(s&&o!==s&&this.dispatchToElement(he(s,t),"dragleave",t.event),o&&o!==s&&this.dispatchToElement(he(o,t),"dragenter",t.event))}},_dragEnd:function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.dispatchToElement(he(e,t),"dragend",t.event),this._dropTarget&&this.dispatchToElement(he(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null}};var Cf=Array.prototype.slice,Df=function(){this._$handlers={}};Df.prototype={constructor:Df,one:function(t,e,n){var i=this._$handlers;if(!e||!t)return this;i[t]||(i[t]=[]);for(var r=0;rr;r++)n[t][r].h!=e&&i.push(n[t][r]);n[t]=i}n[t]&&0===n[t].length&&delete n[t]}else delete n[t];return this},trigger:function(t){if(this._$handlers[t]){var e=arguments,n=e.length;n>3&&(e=Cf.call(e,1));for(var i=this._$handlers[t],r=i.length,a=0;r>a;){switch(n){case 1:i[a].h.call(i[a].ctx);break;case 2:i[a].h.call(i[a].ctx,e[1]);break;case 3:i[a].h.call(i[a].ctx,e[1],e[2]);break;default:i[a].h.apply(i[a].ctx,e)}i[a].one?(i.splice(a,1),r--):a++}}return this},triggerWithContext:function(t){if(this._$handlers[t]){var e=arguments,n=e.length;n>4&&(e=Cf.call(e,1,e.length-1));for(var i=e[e.length-1],r=this._$handlers[t],a=r.length,o=0;a>o;){switch(n){case 1:r[o].h.call(i);break;case 2:r[o].h.call(i,e[1]);break;case 3:r[o].h.call(i,e[1],e[2]);break;default:r[o].h.apply(i,e)}r[o].one?(r.splice(o,1),a--):o++}}return this}};var Af="silent";ce.prototype.dispose=function(){};var kf=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],Pf=function(t,e,n,i){Df.call(this),this.storage=t,this.painter=e,this.painterRoot=i,n=n||new ce,this.proxy=null,this._hovered={},this._lastTouchMoment,this._lastX,this._lastY,le.call(this),this.setHandlerProxy(n)};Pf.prototype={constructor:Pf,setHandlerProxy:function(t){this.proxy&&this.proxy.dispose(),t&&(f(kf,function(e){t.on&&t.on(e,this[e],this)},this),t.handler=this),this.proxy=t},mousemove:function(t){var e=t.zrX,n=t.zrY,i=this._hovered,r=i.target;r&&!r.__zr&&(i=this.findHover(i.x,i.y),r=i.target);var a=this._hovered=this.findHover(e,n),o=a.target,s=this.proxy;s.setCursor&&s.setCursor(o?o.cursor:"default"),r&&o!==r&&this.dispatchToElement(i,"mouseout",t),this.dispatchToElement(a,"mousemove",t),o&&o!==r&&this.dispatchToElement(a,"mouseover",t)},mouseout:function(t){this.dispatchToElement(this._hovered,"mouseout",t);var e,n=t.toElement||t.relatedTarget;do n=n&&n.parentNode;while(n&&9!=n.nodeType&&!(e=n===this.painterRoot));!e&&this.trigger("globalout",{event:t})},resize:function(){this._hovered={}},dispatch:function(t,e){var n=this[t];n&&n.call(this,e)},dispose:function(){this.proxy.dispose(),this.storage=this.proxy=this.painter=null},setCursorStyle:function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},dispatchToElement:function(t,e,n){t=t||{};var i=t.target;if(!i||!i.silent){for(var r="on"+e,a=ue(e,t,n);i&&(i[r]&&(a.cancelBubble=i[r].call(i,a)),i.trigger(e,a),i=i.parent,!a.cancelBubble););a.cancelBubble||(this.trigger(e,a),this.painter&&this.painter.eachOtherLayer(function(t){"function"==typeof t[r]&&t[r].call(t,a),t.trigger&&t.trigger(e,a)}))}},findHover:function(t,e,n){for(var i=this.storage.getDisplayList(),r={x:t,y:e},a=i.length-1;a>=0;a--){var o;if(i[a]!==n&&!i[a].ignore&&(o=de(i[a],t,e))&&(!r.topTarget&&(r.topTarget=i[a]),o!==Af)){r.target=i[a];break}}return r}},f(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(t){Pf.prototype[t]=function(e){var n=this.findHover(e.zrX,e.zrY),i=n.target;if("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||Mf(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(n,t,e)}}),c(Pf,Df),c(Pf,le);var Lf="undefined"==typeof Float32Array?Array:Float32Array,Of=(Object.freeze||Object)({create:fe,identity:pe,copy:ge,mul:me,translate:ve,rotate:ye,scale:xe,invert:_e,clone:we}),zf=pe,Rf=5e-5,Bf=function(t){t=t||{},t.position||(this.position=[0,0]),null==t.rotation&&(this.rotation=0),t.scale||(this.scale=[1,1]),this.origin=this.origin||null},Ef=Bf.prototype;Ef.transform=null,Ef.needLocalTransform=function(){return be(this.rotation)||be(this.position[0])||be(this.position[1])||be(this.scale[0]-1)||be(this.scale[1]-1)},Ef.updateTransform=function(){var t=this.parent,e=t&&t.transform,n=this.needLocalTransform(),i=this.transform;return n||e?(i=i||fe(),n?this.getLocalTransform(i):zf(i),e&&(n?me(i,t.transform,i):ge(i,t.transform)),this.transform=i,this.invTransform=this.invTransform||fe(),void _e(this.invTransform,i)):void(i&&zf(i))},Ef.getLocalTransform=function(t){return Bf.getLocalTransform(this,t)},Ef.setTransform=function(t){var e=this.transform,n=t.dpr||1;e?t.setTransform(n*e[0],n*e[1],n*e[2],n*e[3],n*e[4],n*e[5]):t.setTransform(n,0,0,n,0,0)},Ef.restoreTransform=function(t){var e=t.dpr||1;t.setTransform(e,0,0,e,0,0)};var Nf=[];Ef.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(me(Nf,t.invTransform,e),e=Nf);var n=e[0]*e[0]+e[1]*e[1],i=e[2]*e[2]+e[3]*e[3],r=this.position,a=this.scale;be(n-1)&&(n=Math.sqrt(n)),be(i-1)&&(i=Math.sqrt(i)),e[0]<0&&(n=-n),e[3]<0&&(i=-i),r[0]=e[4],r[1]=e[5],a[0]=n,a[1]=i,this.rotation=Math.atan2(-e[1]/i,e[0]/n)}},Ef.getGlobalScale=function(){var t=this.transform;if(!t)return[1,1];var e=Math.sqrt(t[0]*t[0]+t[1]*t[1]),n=Math.sqrt(t[2]*t[2]+t[3]*t[3]);return t[0]<0&&(e=-e),t[3]<0&&(n=-n),[e,n]},Ef.transformCoordToLocal=function(t,e){var n=[t,e],i=this.invTransform;return i&&ae(n,n,i),n},Ef.transformCoordToGlobal=function(t,e){var n=[t,e],i=this.transform;return i&&ae(n,n,i),n},Bf.getLocalTransform=function(t,e){e=e||[],zf(e);var n=t.origin,i=t.scale||[1,1],r=t.rotation||0,a=t.position||[0,0];return n&&(e[4]-=n[0],e[5]-=n[1]),xe(e,e,i),r&&ye(e,e,r),n&&(e[4]+=n[0],e[5]+=n[1]),e[4]+=a[0],e[5]+=a[1],e};var Ff={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*(-Math.pow(2,-10*(t-1))+2)},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,n=.1,i=.4;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=i/4):e=i*Math.asin(1/n)/(2*Math.PI),-(n*Math.pow(2,10*(t-=1))*Math.sin(2*(t-e)*Math.PI/i)))},elasticOut:function(t){var e,n=.1,i=.4;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=i/4):e=i*Math.asin(1/n)/(2*Math.PI),n*Math.pow(2,-10*t)*Math.sin(2*(t-e)*Math.PI/i)+1)},elasticInOut:function(t){var e,n=.1,i=.4;return 0===t?0:1===t?1:(!n||1>n?(n=1,e=i/4):e=i*Math.asin(1/n)/(2*Math.PI),(t*=2)<1?-.5*n*Math.pow(2,10*(t-=1))*Math.sin(2*(t-e)*Math.PI/i):n*Math.pow(2,-10*(t-=1))*Math.sin(2*(t-e)*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?.5*t*t*((e+1)*t-e):.5*((t-=2)*t*((e+1)*t+e)+2)},bounceIn:function(t){return 1-Ff.bounceOut(1-t)},bounceOut:function(t){return 1/2.75>t?7.5625*t*t:2/2.75>t?7.5625*(t-=1.5/2.75)*t+.75:2.5/2.75>t?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return.5>t?.5*Ff.bounceIn(2*t):.5*Ff.bounceOut(2*t-1)+.5}};Se.prototype={constructor:Se,step:function(t,e){if(this._initialized||(this._startTime=t+this._delay,this._initialized=!0),this._paused)return void(this._pausedTime+=e);var n=(t-this._startTime-this._pausedTime)/this._life;if(!(0>n)){n=Math.min(n,1);var i=this.easing,r="string"==typeof i?Ff[i]:i,a="function"==typeof r?r(n):n;return this.fire("frame",a),1==n?this.loop?(this.restart(t),"restart"):(this._needsRemove=!0,"destroy"):null}},restart:function(t){var e=(t-this._startTime-this._pausedTime)%this._life;this._startTime=t-e+this.gap,this._pausedTime=0,this._needsRemove=!1},fire:function(t,e){t="on"+t,this[t]&&this[t](this._target,e)},pause:function(){this._paused=!0},resume:function(){this._paused=!1}};var Gf=function(){this.head=null,this.tail=null,this._len=0},Vf=Gf.prototype;Vf.insert=function(t){var e=new Hf(t);return this.insertEntry(e),e},Vf.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++},Vf.remove=function(t){var e=t.prev,n=t.next;e?e.next=n:this.head=n,n?n.prev=e:this.tail=e,t.next=t.prev=null,this._len--},Vf.len=function(){return this._len},Vf.clear=function(){this.head=this.tail=null,this._len=0};var Hf=function(t){this.value=t,this.next,this.prev},Wf=function(t){this._list=new Gf,this._map={},this._maxSize=t||10,this._lastRemovedEntry=null},Xf=Wf.prototype;Xf.put=function(t,e){var n=this._list,i=this._map,r=null;if(null==i[t]){var a=n.len(),o=this._lastRemovedEntry;if(a>=this._maxSize&&a>0){var s=n.head;n.remove(s),delete i[s.key],r=s.value,this._lastRemovedEntry=s}o?o.value=e:o=new Hf(e),o.key=t,n.insertEntry(o),i[t]=o}return r},Xf.get=function(t){var e=this._map[t],n=this._list;return null!=e?(e!==n.tail&&(n.remove(e),n.insertEntry(e)),e.value):void 0},Xf.clear=function(){this._list.clear(),this._map={}};var Zf={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]},Uf=new Wf(20),Yf=null,jf=Fe,qf=Ge,$f=(Object.freeze||Object)({parse:ze,lift:Ee,toHex:Ne,fastLerp:Fe,fastMapToColor:jf,lerp:Ge,mapToColor:qf,modifyHSL:Ve,modifyAlpha:He,stringify:We}),Kf=Array.prototype.slice,Jf=function(t,e,n,i){this._tracks={},this._target=t,this._loop=e||!1,this._getter=n||Xe,this._setter=i||Ze,this._clipCount=0,this._delay=0,this._doneList=[],this._onframeList=[],this._clipList=[]};Jf.prototype={when:function(t,e){var n=this._tracks;for(var i in e)if(e.hasOwnProperty(i)){if(!n[i]){n[i]=[];var r=this._getter(this._target,i);if(null==r)continue;0!==t&&n[i].push({time:0,value:Qe(r)})}n[i].push({time:t,value:e[i]})}return this},during:function(t){return this._onframeList.push(t),this},pause:function(){for(var t=0;tn;n++)t[n].call(this)},start:function(t,e){var n,i=this,r=0,a=function(){r--,r||i._doneCallback()};for(var o in this._tracks)if(this._tracks.hasOwnProperty(o)){var s=nn(this,t,a,this._tracks[o],o,e);s&&(this._clipList.push(s),r++,this.animation&&this.animation.addClip(s),n=s)}if(n){var l=n.onframe;n.onframe=function(t,e){l(t,e);for(var n=0;n1&&(np=function(){for(var t in arguments)console.log(arguments[t])});var ip=np,rp=function(){this.animators=[]};rp.prototype={constructor:rp,animate:function(t,e){var n,i=!1,r=this,a=this.__zr;if(t){var o=t.split("."),s=r;i="shape"===o[0];for(var l=0,u=o.length;u>l;l++)s&&(s=s[o[l]]);s&&(n=s)}else n=r;if(!n)return void ip('Property "'+t+'" is not existed in element '+r.id);var c=r.animators,d=new Jf(n,e);return d.during(function(){r.dirty(i)}).done(function(){c.splice(h(c,d),1)}),c.push(d),a&&a.animation.addAnimator(d),d},stopAnimation:function(t){for(var e=this.animators,n=e.length,i=0;n>i;i++)e[i].stop(t);return e.length=0,this},animateTo:function(t,e,n,i,r,a){function o(){l--,l||r&&r()}b(n)?(r=i,i=n,n=0):w(i)?(r=i,i="linear",n=0):w(n)?(r=n,n=0):w(e)?(r=e,e=500):e||(e=500),this.stopAnimation(),this._animateToShallow("",this,t,e,n);var s=this.animators.slice(),l=s.length;l||r&&r();for(var h=0;h0&&this.animate(t,!1).when(null==i?500:i,a).delay(r||0),this}};var ap=function(t){Bf.call(this,t),Df.call(this,t),rp.call(this,t),this.id=t.id||rf()};ap.prototype={type:"element",name:"",__zr:null,ignore:!1,clipPath:null,isGroup:!1,drift:function(t,e){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0}var n=this.transform;n||(n=this.transform=[1,0,0,1,0,0]),n[4]+=t,n[5]+=e,this.decomposeTransform(),this.dirty(!1)},beforeUpdate:function(){},afterUpdate:function(){},update:function(){this.updateTransform()},traverse:function(){},attrKV:function(t,e){if("position"===t||"scale"===t||"origin"===t){if(e){var n=this[t];n||(n=this[t]=[]),n[0]=e[0],n[1]=e[1]}}else this[t]=e},hide:function(){this.ignore=!0,this.__zr&&this.__zr.refresh()},show:function(){this.ignore=!1,this.__zr&&this.__zr.refresh()},attr:function(t,e){if("string"==typeof t)this.attrKV(t,e);else if(S(t))for(var n in t)t.hasOwnProperty(n)&&this.attrKV(n,t[n]);return this.dirty(!1),this},setClipPath:function(t){var e=this.__zr;e&&t.addSelfToZr(e),this.clipPath&&this.clipPath!==t&&this.removeClipPath(),this.clipPath=t,t.__zr=e,t.__clipTarget=this,this.dirty(!1)},removeClipPath:function(){var t=this.clipPath;t&&(t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__clipTarget=null,this.clipPath=null,this.dirty(!1))},addSelfToZr:function(t){this.__zr=t;var e=this.animators;if(e)for(var n=0;ni||n>s||l>a||r>h)},contain:function(t,e){var n=this;return t>=n.x&&t<=n.x+n.width&&e>=n.y&&e<=n.y+n.height},clone:function(){return new rn(this.x,this.y,this.width,this.height)},copy:function(t){this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height},plain:function(){return{x:this.x,y:this.y,width:this.width,height:this.height}}},rn.create=function(t){return new rn(t.x,t.y,t.width,t.height)};var hp=function(t){t=t||{},ap.call(this,t);for(var e in t)t.hasOwnProperty(e)&&(this[e]=t[e]);this._children=[],this.__storage=null,this.__dirty=!0};hp.prototype={constructor:hp,isGroup:!0,type:"group",silent:!1,children:function(){return this._children.slice()},childAt:function(t){return this._children[t]},childOfName:function(t){for(var e=this._children,n=0;n=0&&(n.splice(i,0,t),this._doAdd(t))}return this},_doAdd:function(t){t.parent&&t.parent.remove(t),t.parent=this;var e=this.__storage,n=this.__zr;e&&e!==t.__storage&&(e.addToStorage(t),t instanceof hp&&t.addChildrenToStorage(e)),n&&n.refresh()},remove:function(t){var e=this.__zr,n=this.__storage,i=this._children,r=h(i,t);return 0>r?this:(i.splice(r,1),t.parent=null,n&&(n.delFromStorage(t),t instanceof hp&&t.delChildrenFromStorage(n)),e&&e.refresh(),this)},removeAll:function(){var t,e,n=this._children,i=this.__storage;for(e=0;ei;i++)this._updateAndAddDisplayable(e[i],null,t);n.length=this._displayListLen,of.canvasSupported&&dn(n,fn)},_updateAndAddDisplayable:function(t,e,n){if(!t.ignore||n){t.beforeUpdate(),t.__dirty&&t.update(),t.afterUpdate();var i=t.clipPath;if(i){e=e?e.slice():[];for(var r=i,a=t;r;)r.parent=a,r.updateTransform(),e.push(r),a=r,r=r.clipPath}if(t.isGroup){for(var o=t._children,s=0;se;e++)this.delRoot(t[e]);else{var r=h(this._roots,t);r>=0&&(this.delFromStorage(t),this._roots.splice(r,1),t instanceof hp&&t.delChildrenFromStorage(this))}},addToStorage:function(t){return t&&(t.__storage=this,t.dirty(!1)),this},delFromStorage:function(t){return t&&(t.__storage=null),this},dispose:function(){this._renderList=this._roots=null},displayableSortFunc:fn};var fp={shadowBlur:1,shadowOffsetX:1,shadowOffsetY:1,textShadowBlur:1,textShadowOffsetX:1,textShadowOffsetY:1,textBoxShadowBlur:1,textBoxShadowOffsetX:1,textBoxShadowOffsetY:1},pp=function(t,e,n){return fp.hasOwnProperty(e)?n*=t.dpr:n},gp=[["shadowBlur",0],["shadowOffsetX",0],["shadowOffsetY",0],["shadowColor","#000"],["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]],mp=function(t,e){this.extendFrom(t,!1),this.host=e};mp.prototype={constructor:mp,host:null,fill:"#000",stroke:null,opacity:1,lineDash:null,lineDashOffset:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,lineWidth:1,strokeNoScale:!1,text:null,font:null,textFont:null,fontStyle:null,fontWeight:null,fontSize:null,fontFamily:null,textTag:null,textFill:"#000",textStroke:null,textWidth:null,textHeight:null,textStrokeWidth:0,textLineHeight:null,textPosition:"inside",textRect:null,textOffset:null,textAlign:null,textVerticalAlign:null,textDistance:5,textShadowColor:"transparent",textShadowBlur:0,textShadowOffsetX:0,textShadowOffsetY:0,textBoxShadowColor:"transparent",textBoxShadowBlur:0,textBoxShadowOffsetX:0,textBoxShadowOffsetY:0,transformText:!1,textRotation:0,textOrigin:null,textBackgroundColor:null,textBorderColor:null,textBorderWidth:0,textBorderRadius:0,textPadding:null,rich:null,truncate:null,blend:null,bind:function(t,e,n){for(var i=this,r=n&&n.style,a=!r,o=0;o0},extendFrom:function(t,e){if(t)for(var n in t)!t.hasOwnProperty(n)||e!==!0&&(e===!1?this.hasOwnProperty(n):null==t[n])||(this[n]=t[n])},set:function(t,e){"string"==typeof t?this[t]=e:this.extendFrom(t,!0)},clone:function(){var t=new this.constructor;return t.extendFrom(this,!0),t},getGradient:function(t,e,n){for(var i="radial"===e.type?gn:pn,r=i(t,e,n),a=e.colorStops,o=0;o=0&&n.splice(i,1),t.__hoverMir=null},clearHover:function(){for(var t=this._hoverElements,e=0;er;){var a=t[r],o=a.__from;o&&o.__zr?(r++,o.invisible||(a.transform=o.transform,a.invTransform=o.invTransform,a.__clipPaths=o.__clipPaths,this._doPaintEl(a,n,!0,i))):(t.splice(r,1),o.__hoverMir=null,e--)}n.ctx.restore()}},getHoverLayer:function(){return this.getLayer(zp)},_paintList:function(t,e,n){if(this._redrawId===n){e=e||!1,this._updateLayerStatus(t);var i=this._doPaintList(t,e);if(this._needsManuallyCompositing&&this._compositeManually(),!i){var r=this;bp(function(){r._paintList(t,e,n)})}}},_compositeManually:function(){var t=this.getLayer(Rp).ctx,e=this._domRoot.width,n=this._domRoot.height;t.clearRect(0,0,e,n),this.eachBuiltinLayer(function(i){i.virtual&&t.drawImage(i.dom,0,0,e,n)})},_doPaintList:function(t,e){for(var n=[],i=0;i15)break}}a.__drawIndex=g,a.__drawIndex0&&t>i[0]){for(o=0;r-1>o&&!(i[o]t);o++);a=n[i[o]]}if(i.splice(o+1,0,t),n[t]=e,!e.virtual)if(a){var l=a.dom;l.nextSibling?s.insertBefore(e.dom,l.nextSibling):s.appendChild(e.dom)}else s.firstChild?s.insertBefore(e.dom,s.firstChild):s.appendChild(e.dom)},eachLayer:function(t,e){var n,i,r=this._zlevelList;for(i=0;i0?Bp:0),this._needsManuallyCompositing),o.__builtin__||ip("ZLevel "+s+" has been used by unkown layer "+o.id),o!==r&&(o.__used=!0,o.__startIndex!==n&&(o.__dirty=!0),o.__startIndex=n,o.__drawIndex=o.incremental?-1:n,e(n),r=o),i.__dirty&&(o.__dirty=!0,o.incremental&&o.__drawIndex<0&&(o.__drawIndex=n))}e(n),this.eachBuiltinLayer(function(t){!t.__used&&t.getElementCount()>0&&(t.__dirty=!0,t.__startIndex=t.__endIndex=t.__drawIndex=0),t.__dirty&&t.__drawIndex<0&&(t.__drawIndex=t.__startIndex)})},clear:function(){return this.eachBuiltinLayer(this._clearLayer),this},_clearLayer:function(t){t.clear()},configLayer:function(t,e){if(e){var n=this._layerConfig;n[t]?r(n[t],e,!0):n[t]=e;for(var i=0;i=0&&this._clips.splice(e,1)},removeAnimator:function(t){for(var e=t.getClips(),n=0;no;o++){var s=n[o],l=s.step(t,e);l&&(r.push(l),a.push(s))}for(var o=0;i>o;)n[o]._needsRemove?(n[o]=n[i-1],n.pop(),i--):o++;i=r.length;for(var o=0;i>o;o++)a[o].fire(r[o]);this._time=t,this.onframe(e),this.trigger("frame",e),this.stage.update&&this.stage.update()},_startLoop:function(){function t(){e._running&&(bp(t),!e._paused&&e._update())}var e=this;this._running=!0,bp(t)},start:function(){this._time=(new Date).getTime(),this._pausedTime=0,this._startLoop()},stop:function(){this._running=!1},pause:function(){this._paused||(this._pauseStart=(new Date).getTime(),this._paused=!0)},resume:function(){this._paused&&(this._pausedTime+=(new Date).getTime()-this._pauseStart,this._paused=!1)},clear:function(){this._clips=[]},animate:function(t,e){e=e||{};var n=new Jf(t,e.loop,e.getter,e.setter);return this.addAnimator(n),n}},c(Xp,Df);var Zp=function(){this._track=[]};Zp.prototype={constructor:Zp,recognize:function(t,e,n){return this._doTrack(t,e,n),this._recognize(t)},clear:function(){return this._track.length=0,this},_doTrack:function(t,e,n){var i=t.touches;if(i){for(var r={points:[],touches:[],target:e,event:t},a=0,o=i.length;o>a;a++){var s=i[a],l=fi(n,s,{});r.points.push([l.zrX,l.zrY]),r.touches.push(s)}this._track.push(r)}},_recognize:function(t){for(var e in Up)if(Up.hasOwnProperty(e)){var n=Up[e](this._track,t);if(n)return n}}};var Up={pinch:function(t,e){var n=t.length;if(n){var i=(t[n-1]||{}).points,r=(t[n-2]||{}).points||i;if(r&&r.length>1&&i&&i.length>1){var a=xi(i)/xi(r);!isFinite(a)&&(a=1),e.pinchScale=a;var o=_i(i);return e.pinchX=o[0],e.pinchY=o[1],{type:"pinch",target:t[0].target,event:e}}}}},Yp=300,jp=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],qp=["touchstart","touchend","touchmove"],$p={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},Kp=p(jp,function(t){var e=t.replace("mouse","pointer");return $p[e]?e:t}),Jp={mousemove:function(t){t=gi(this.dom,t),this.trigger("mousemove",t)},mouseout:function(t){t=gi(this.dom,t);var e=t.toElement||t.relatedTarget;if(e!=this.dom)for(;e&&9!=e.nodeType;){if(e===this.dom)return;e=e.parentNode}this.trigger("mouseout",t)},touchstart:function(t){t=gi(this.dom,t),t.zrByTouch=!0,this._lastTouchMoment=new Date,bi(this,t,"start"),Jp.mousemove.call(this,t),Jp.mousedown.call(this,t),Si(this)},touchmove:function(t){t=gi(this.dom,t),t.zrByTouch=!0,bi(this,t,"change"),Jp.mousemove.call(this,t),Si(this)},touchend:function(t){t=gi(this.dom,t),t.zrByTouch=!0,bi(this,t,"end"),Jp.mouseup.call(this,t),+new Date-this._lastTouchMoment=0||i&&h(i,o)<0)){var s=e.getShallow(o);null!=s&&(r[t[a][0]]=s)}}return r}},mg=gg([["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),vg={getLineStyle:function(t){var e=mg(this,t),n=this.getLineDash(e.lineWidth);return n&&(e.lineDash=n),e},getLineDash:function(t){null==t&&(t=1);var e=this.get("type"),n=Math.max(t,2),i=4*t;return"solid"===e||null==e?null:"dashed"===e?[i,i]:[n,n]}},yg=gg([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),xg={getAreaStyle:function(t,e){return yg(this,t,e)}},_g=Math.pow,wg=Math.sqrt,bg=1e-8,Sg=1e-4,Mg=wg(3),Ig=1/3,Tg=V(),Cg=V(),Dg=V(),Ag=Math.min,kg=Math.max,Pg=Math.sin,Lg=Math.cos,Og=2*Math.PI,zg=V(),Rg=V(),Bg=V(),Eg=[],Ng=[],Fg={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Gg=[],Vg=[],Hg=[],Wg=[],Xg=Math.min,Zg=Math.max,Ug=Math.cos,Yg=Math.sin,jg=Math.sqrt,qg=Math.abs,$g="undefined"!=typeof Float32Array,Kg=function(t){this._saveData=!t,this._saveData&&(this.data=[]),this._ctx=null};Kg.prototype={constructor:Kg,_xi:0,_yi:0,_x0:0,_y0:0,_ux:0,_uy:0,_len:0,_lineDash:null,_dashOffset:0,_dashIdx:0,_dashSum:0,setScale:function(t,e){this._ux=qg(1/ep/t)||0,this._uy=qg(1/ep/e)||0},getContext:function(){return this._ctx},beginPath:function(t){return this._ctx=t,t&&t.beginPath(),t&&(this.dpr=t.dpr),this._saveData&&(this._len=0),this._lineDash&&(this._lineDash=null,this._dashOffset=0),this},moveTo:function(t,e){return this.addData(Fg.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},lineTo:function(t,e){var n=qg(t-this._xi)>this._ux||qg(e-this._yi)>this._uy||this._len<5;return this.addData(Fg.L,t,e),this._ctx&&n&&(this._needsDash()?this._dashedLineTo(t,e):this._ctx.lineTo(t,e)),n&&(this._xi=t,this._yi=e),this},bezierCurveTo:function(t,e,n,i,r,a){return this.addData(Fg.C,t,e,n,i,r,a),this._ctx&&(this._needsDash()?this._dashedBezierTo(t,e,n,i,r,a):this._ctx.bezierCurveTo(t,e,n,i,r,a)),this._xi=r,this._yi=a,this},quadraticCurveTo:function(t,e,n,i){return this.addData(Fg.Q,t,e,n,i),this._ctx&&(this._needsDash()?this._dashedQuadraticTo(t,e,n,i):this._ctx.quadraticCurveTo(t,e,n,i)),this._xi=n,this._yi=i,this},arc:function(t,e,n,i,r,a){return this.addData(Fg.A,t,e,n,n,i,r-i,0,a?0:1),this._ctx&&this._ctx.arc(t,e,n,i,r,a),this._xi=Ug(r)*n+t,this._yi=Yg(r)*n+t,this},arcTo:function(t,e,n,i,r){return this._ctx&&this._ctx.arcTo(t,e,n,i,r),this},rect:function(t,e,n,i){return this._ctx&&this._ctx.rect(t,e,n,i),this.addData(Fg.R,t,e,n,i),this},closePath:function(){this.addData(Fg.Z);var t=this._ctx,e=this._x0,n=this._y0;return t&&(this._needsDash()&&this._dashedLineTo(e,n),t.closePath()),this._xi=e,this._yi=n,this},fill:function(t){t&&t.fill(),this.toStatic()},stroke:function(t){t&&t.stroke(),this.toStatic()},setLineDash:function(t){if(t instanceof Array){this._lineDash=t,this._dashIdx=0;for(var e=0,n=0;nn;n++)this.data[n]=t[n];this._len=e},appendPath:function(t){t instanceof Array||(t=[t]);for(var e=t.length,n=0,i=this._len,r=0;e>r;r++)n+=t[r].len(); +$g&&this.data instanceof Float32Array&&(this.data=new Float32Array(i+n));for(var r=0;e>r;r++)for(var a=t[r].data,o=0;oe.length&&(this._expandData(),e=this.data);for(var n=0;na&&(a=r+a),a%=r,f-=a*u,p-=a*c;u>0&&t>=f||0>u&&f>=t||0==u&&(c>0&&e>=p||0>c&&p>=e);)i=this._dashIdx,n=o[i],f+=u*n,p+=c*n,this._dashIdx=(i+1)%g,u>0&&l>f||0>u&&f>l||c>0&&h>p||0>c&&p>h||s[i%2?"moveTo":"lineTo"](u>=0?Xg(f,t):Zg(f,t),c>=0?Xg(p,e):Zg(p,e));u=f-t,c=p-e,this._dashOffset=-jg(u*u+c*c)},_dashedBezierTo:function(t,e,n,i,r,a){var o,s,l,h,u,c=this._dashSum,d=this._dashOffset,f=this._lineDash,p=this._ctx,g=this._xi,m=this._yi,v=tr,y=0,x=this._dashIdx,_=f.length,w=0;for(0>d&&(d=c+d),d%=c,o=0;1>o;o+=.1)s=v(g,t,n,r,o+.1)-v(g,t,n,r,o),l=v(m,e,i,a,o+.1)-v(m,e,i,a,o),y+=jg(s*s+l*l);for(;_>x&&(w+=f[x],!(w>d));x++);for(o=(w-d)/y;1>=o;)h=v(g,t,n,r,o),u=v(m,e,i,a,o),x%2?p.moveTo(h,u):p.lineTo(h,u),o+=f[x]/y,x=(x+1)%_;x%2!==0&&p.lineTo(r,a),s=r-h,l=a-u,this._dashOffset=-jg(s*s+l*l)},_dashedQuadraticTo:function(t,e,n,i){var r=n,a=i;n=(n+2*t)/3,i=(i+2*e)/3,t=(this._xi+2*t)/3,e=(this._yi+2*e)/3,this._dashedBezierTo(t,e,n,i,r,a)},toStatic:function(){var t=this.data;t instanceof Array&&(t.length=this._len,$g&&(this.data=new Float32Array(t)))},getBoundingRect:function(){Gg[0]=Gg[1]=Hg[0]=Hg[1]=Number.MAX_VALUE,Vg[0]=Vg[1]=Wg[0]=Wg[1]=-Number.MAX_VALUE;for(var t=this.data,e=0,n=0,i=0,r=0,a=0;ac;){var d=s[c++];switch(1==c&&(i=s[c],r=s[c+1],e=i,n=r),d){case Fg.M:e=i=s[c++],n=r=s[c++],t.moveTo(i,r);break;case Fg.L:a=s[c++],o=s[c++],(qg(a-i)>l||qg(o-r)>h||c===u-1)&&(t.lineTo(a,o),i=a,r=o);break;case Fg.C:t.bezierCurveTo(s[c++],s[c++],s[c++],s[c++],s[c++],s[c++]),i=s[c-2],r=s[c-1];break;case Fg.Q:t.quadraticCurveTo(s[c++],s[c++],s[c++],s[c++]),i=s[c-2],r=s[c-1];break;case Fg.A:var f=s[c++],p=s[c++],g=s[c++],m=s[c++],v=s[c++],y=s[c++],x=s[c++],_=s[c++],w=g>m?g:m,b=g>m?1:g/m,S=g>m?m/g:1,M=Math.abs(g-m)>.001,I=v+y;M?(t.translate(f,p),t.rotate(x),t.scale(b,S),t.arc(0,0,w,v,I,1-_),t.scale(1/b,1/S),t.rotate(-x),t.translate(-f,-p)):t.arc(f,p,w,v,I,1-_),1==c&&(e=Ug(v)*g+f,n=Yg(v)*m+p),i=Ug(I)*g+f,r=Yg(I)*m+p;break;case Fg.R:e=i=s[c],n=r=s[c+1],t.rect(s[c++],s[c++],s[c++],s[c++]);break;case Fg.Z:t.closePath(),i=e,r=n}}}},Kg.CMD=Fg;var Jg=2*Math.PI,Qg=2*Math.PI,tm=Kg.CMD,em=2*Math.PI,nm=1e-4,im=[-1,-1,-1],rm=[-1,-1],am=_p.prototype.getCanvasPattern,om=Math.abs,sm=new Kg(!0);Pr.prototype={constructor:Pr,type:"path",__dirtyPath:!0,strokeContainThreshold:5,brush:function(t,e){var n=this.style,i=this.path||sm,r=n.hasStroke(),a=n.hasFill(),o=n.fill,s=n.stroke,l=a&&!!o.colorStops,h=r&&!!s.colorStops,u=a&&!!o.image,c=r&&!!s.image;if(n.bind(t,this,e),this.setTransform(t),this.__dirty){var d;l&&(d=d||this.getBoundingRect(),this._fillGradient=n.getGradient(t,o,d)),h&&(d=d||this.getBoundingRect(),this._strokeGradient=n.getGradient(t,s,d))}l?t.fillStyle=this._fillGradient:u&&(t.fillStyle=am.call(o,t)),h?t.strokeStyle=this._strokeGradient:c&&(t.strokeStyle=am.call(s,t));var f=n.lineDash,p=n.lineDashOffset,g=!!t.setLineDash,m=this.getGlobalScale();i.setScale(m[0],m[1]),this.__dirtyPath||f&&!g&&r?(i.beginPath(t),f&&!g&&(i.setLineDash(f),i.setLineDashOffset(p)),this.buildPath(i,this.shape,!1),this.path&&(this.__dirtyPath=!1)):(t.beginPath(),this.path.rebuildPath(t)),a&&i.fill(t),f&&g&&(t.setLineDash(f),t.lineDashOffset=p),r&&i.stroke(t),f&&g&&t.setLineDash([]),null!=n.text&&(this.restoreTransform(t),this.drawRectText(t,this.getBoundingRect()))},buildPath:function(){},createPathProxy:function(){this.path=new Kg},getBoundingRect:function(){var t=this._rect,e=this.style,n=!t;if(n){var i=this.path;i||(i=this.path=new Kg),this.__dirtyPath&&(i.beginPath(),this.buildPath(i,this.shape,!1)),t=i.getBoundingRect()}if(this._rect=t,e.hasStroke()){var r=this._rectWithStroke||(this._rectWithStroke=t.clone());if(this.__dirty||n){r.copy(t);var a=e.lineWidth,o=e.strokeNoScale?this.getLineScale():1;e.hasFill()||(a=Math.max(a,this.strokeContainThreshold||4)),o>1e-10&&(r.width+=a/o,r.height+=a/o,r.x-=a/o/2,r.y-=a/o/2)}return r}return t},contain:function(t,e){var n=this.transformCoordToLocal(t,e),i=this.getBoundingRect(),r=this.style;if(t=n[0],e=n[1],i.contain(t,e)){var a=this.path.data;if(r.hasStroke()){var o=r.lineWidth,s=r.strokeNoScale?this.getLineScale():1;if(s>1e-10&&(r.hasFill()||(o=Math.max(o,this.strokeContainThreshold)),kr(a,o/s,t,e)))return!0}if(r.hasFill())return Ar(a,t,e)}return!1},dirty:function(t){null==t&&(t=!0),t&&(this.__dirtyPath=t,this._rect=null),this.__dirty=!0,this.__zr&&this.__zr.refresh(),this.__clipTarget&&this.__clipTarget.dirty()},animateShape:function(t){return this.animate("shape",t)},attrKV:function(t,e){"shape"===t?(this.setShape(e),this.__dirtyPath=!0,this._rect=null):ri.prototype.attrKV.call(this,t,e)},setShape:function(t,e){var n=this.shape;if(n){if(S(t))for(var i in t)t.hasOwnProperty(i)&&(n[i]=t[i]);else n[t]=e;this.dirty(!0)}return this},getLineScale:function(){var t=this.transform;return t&&om(t[0]-1)>1e-10&&om(t[3]-1)>1e-10?Math.sqrt(om(t[0]*t[3]-t[2]*t[1])):1}},Pr.extend=function(t){var e=function(e){Pr.call(this,e),t.style&&this.style.extendFrom(t.style,!1);var n=t.shape;if(n){this.shape=this.shape||{};var i=this.shape;for(var r in n)!i.hasOwnProperty(r)&&n.hasOwnProperty(r)&&(i[r]=n[r])}t.init&&t.init.call(this,e)};u(e,Pr);for(var n in t)"style"!==n&&"shape"!==n&&(e.prototype[n]=t[n]);return e},u(Pr,ri);var lm=Kg.CMD,hm=[[],[],[]],um=Math.sqrt,cm=Math.atan2,dm=function(t,e){var n,i,r,a,o,s,l=t.data,h=lm.M,u=lm.C,c=lm.L,d=lm.R,f=lm.A,p=lm.Q;for(r=0,a=0;ro;o++){var s=hm[o];s[0]=l[r++],s[1]=l[r++],ae(s,s,e),l[a++]=s[0],l[a++]=s[1]}}},fm=["m","M","l","L","v","V","h","H","z","Z","c","C","q","Q","t","T","s","S","a","A"],pm=Math.sqrt,gm=Math.sin,mm=Math.cos,vm=Math.PI,ym=function(t){return Math.sqrt(t[0]*t[0]+t[1]*t[1])},xm=function(t,e){return(t[0]*e[0]+t[1]*e[1])/(ym(t)*ym(e))},_m=function(t,e){return(t[0]*e[1]=11?function(){var e,n=this.__clipPaths,i=this.style;if(n)for(var r=0;ra;a++)r+=ee(t[a-1],t[a]);var o=r/2;o=n>o?n:o;for(var a=0;o>a;a++){var s,l,h,u=a/(o-1)*(e?n:n-1),c=Math.floor(u),d=u-c,f=t[c%n];e?(s=t[(c-1+n)%n],l=t[(c+1)%n],h=t[(c+2)%n]):(s=t[0===c?c:c-1],l=t[c>n-2?n-1:c+1],h=t[c>n-3?n-1:c+2]);var p=d*d,g=d*p;i.push([Nr(s[0],f[0],l[0],h[0],d,p,g),Nr(s[1],f[1],l[1],h[1],d,p,g)])}return i},Dm=function(t,e,n,i){var r,a,o,s,l=[],h=[],u=[],c=[];if(i){o=[1/0,1/0],s=[-1/0,-1/0];for(var d=0,f=t.length;f>d;d++)oe(o,o,t[d]),se(s,s,t[d]);oe(o,o,i[0]),se(s,s,i[1])}for(var d=0,f=t.length;f>d;d++){var p=t[d];if(n)r=t[d?d-1:f-1],a=t[(d+1)%f];else{if(0===d||d===f-1){l.push(W(t[d]));continue}r=t[d-1],a=t[d+1]}Y(h,a,r),Q(h,h,e);var g=ee(p,r),m=ee(p,a),v=g+m;0!==v&&(g/=v,m/=v),Q(u,h,-g),Q(c,h,m);var y=Z([],p,u),x=Z([],p,c);i&&(se(y,y,o),oe(y,y,s),se(x,x,o),oe(x,x,s)),l.push(y),l.push(x)}return n&&l.push(l.shift()),l},Am=Pr.extend({type:"polygon",shape:{points:null,smooth:!1,smoothConstraint:null},buildPath:function(t,e){Fr(t,e,!0)}}),km=Pr.extend({type:"polyline",shape:{points:null,smooth:!1,smoothConstraint:null},style:{stroke:"#000",fill:null},buildPath:function(t,e){Fr(t,e,!1)}}),Pm=Pr.extend({type:"rect",shape:{r:0,x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.x,i=e.y,r=e.width,a=e.height;e.r?Fn(t,e):t.rect(n,i,r,a),t.closePath()}}),Lm=Pr.extend({type:"line",shape:{x1:0,y1:0,x2:0,y2:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n=e.x1,i=e.y1,r=e.x2,a=e.y2,o=e.percent;0!==o&&(t.moveTo(n,i),1>o&&(r=n*(1-o)+r*o,a=i*(1-o)+a*o),t.lineTo(r,a))},pointAt:function(t){var e=this.shape;return[e.x1*(1-t)+e.x2*t,e.y1*(1-t)+e.y2*t]}}),Om=[],zm=Pr.extend({type:"bezier-curve",shape:{x1:0,y1:0,x2:0,y2:0,cpx1:0,cpy1:0,percent:1},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n=e.x1,i=e.y1,r=e.x2,a=e.y2,o=e.cpx1,s=e.cpy1,l=e.cpx2,h=e.cpy2,u=e.percent;0!==u&&(t.moveTo(n,i),null==l||null==h?(1>u&&(ur(n,o,r,u,Om),o=Om[1],r=Om[2],ur(i,s,a,u,Om),s=Om[1],a=Om[2]),t.quadraticCurveTo(o,s,r,a)):(1>u&&(rr(n,o,l,r,u,Om),o=Om[1],l=Om[2],r=Om[3],rr(i,s,h,a,u,Om),s=Om[1],h=Om[2],a=Om[3]),t.bezierCurveTo(o,s,l,h,r,a)))},pointAt:function(t){return Gr(this.shape,t,!1)},tangentAt:function(t){var e=Gr(this.shape,t,!0);return te(e,e)}}),Rm=Pr.extend({type:"arc",shape:{cx:0,cy:0,r:0,startAngle:0,endAngle:2*Math.PI,clockwise:!0},style:{stroke:"#000",fill:null},buildPath:function(t,e){var n=e.cx,i=e.cy,r=Math.max(e.r,0),a=e.startAngle,o=e.endAngle,s=e.clockwise,l=Math.cos(a),h=Math.sin(a);t.moveTo(l*r+n,h*r+i),t.arc(n,i,r,a,o,!s)}}),Bm=Pr.extend({type:"compound",shape:{paths:null},_updatePathDirty:function(){for(var t=this.__dirtyPath,e=this.shape.paths,n=0;nt?"0"+t:t},lv=An,hv=Sn,uv=(Object.freeze||Object)({addCommas:Qa,toCamelCase:to,normalizeCssArray:rv,encodeHTML:eo,formatTpl:no,formatTplSimple:io,getTooltipMarker:ro,formatTime:ao,capitalFirst:oo,truncateText:lv,getTextRect:hv}),cv=f,dv=["left","right","top","bottom","width","height"],fv=[["width","left","right"],["height","top","bottom"]],pv=so,gv=(x(so,"vertical"),x(so,"horizontal"),{getBoxLayoutParams:function(){return{left:this.get("left"),top:this.get("top"),right:this.get("right"),bottom:this.get("bottom"),width:this.get("width"),height:this.get("height")}}}),mv=Gi(),vv=ka.extend({type:"component",id:"",name:"",mainType:"",subType:"",componentIndex:0,defaultOption:null,ecModel:null,dependentModels:[],uid:null,layoutMode:null,$constructor:function(t,e,n,i){ka.call(this,t,e,n,i),this.uid=Oa("ec_cpt_model")},init:function(t,e,n){this.mergeDefaultAndTheme(t,n)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?uo(t):{},a=e.getTheme();r(t,a.get(this.mainType)),r(t,this.getDefaultOption()),n&&ho(t,i,n)},mergeOption:function(t){r(this.option,t,!0);var e=this.layoutMode;e&&ho(this.option,t,e)},optionUpdated:function(){},getDefaultOption:function(){var t=mv(this);if(!t.defaultOption){for(var e=[],n=this.constructor;n;){var i=n.prototype.defaultOption;i&&e.push(i),n=n.superClass}for(var a={},o=e.length-1;o>=0;o--)a=r(a,e[o],!0);t.defaultOption=a}return t.defaultOption},getReferringComponents:function(t){return this.ecModel.queryComponents({mainType:t,index:this.get(t+"Index",!0),id:this.get(t+"Id",!0)})}});Ki(vv,{registerWhenExtend:!0}),za(vv),Ra(vv,fo),c(vv,gv);var yv="";"undefined"!=typeof navigator&&(yv=navigator.platform||"");var xv={color:["#c23531","#2f4554","#61a0a8","#d48265","#91c7ae","#749f83","#ca8622","#bda29a","#6e7074","#546570","#c4ccd3"],gradientColor:["#f6efa6","#d88273","#bf444c"],textStyle:{fontFamily:yv.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,animation:"auto",animationDuration:1e3,animationDurationUpdate:300,animationEasing:"exponentialOut",animationEasingUpdate:"cubicOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},_v=Gi(),wv={clearColorPalette:function(){_v(this).colorIdx=0,_v(this).colorNameMap={}},getColorFromPalette:function(t,e,n){e=e||this;var i=_v(e),r=i.colorIdx||0,a=i.colorNameMap=i.colorNameMap||{};if(a.hasOwnProperty(t))return a[t];var o=Li(this.get("color",!0)),s=this.get("colorLayer",!0),l=null!=n&&s?po(s,n):o;if(l=l||o,l&&l.length){var h=l[r];return t&&(a[t]=h),i.colorIdx=(r+1)%l.length,h}}},bv={cartesian2d:function(t,e,n,i){var r=t.getReferringComponents("xAxis")[0],a=t.getReferringComponents("yAxis")[0];e.coordSysDims=["x","y"],n.set("x",r),n.set("y",a),mo(r)&&(i.set("x",r),e.firstCategoryDimIndex=0),mo(a)&&(i.set("y",a),e.firstCategoryDimIndex=1)},singleAxis:function(t,e,n,i){var r=t.getReferringComponents("singleAxis")[0];e.coordSysDims=["single"],n.set("single",r),mo(r)&&(i.set("single",r),e.firstCategoryDimIndex=0)},polar:function(t,e,n,i){var r=t.getReferringComponents("polar")[0],a=r.findAxisModel("radiusAxis"),o=r.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],n.set("radius",a),n.set("angle",o),mo(a)&&(i.set("radius",a),e.firstCategoryDimIndex=0),mo(o)&&(i.set("angle",o),e.firstCategoryDimIndex=1)},geo:function(t,e){e.coordSysDims=["lng","lat"]},parallel:function(t,e,n,i){var r=t.ecModel,a=r.getComponent("parallel",t.get("parallelIndex")),o=e.coordSysDims=a.dimensions.slice();f(a.parallelAxisIndex,function(t,a){var s=r.getComponent("parallelAxis",t),l=o[a];n.set(l,s),mo(s)&&null==e.firstCategoryDimIndex&&(i.set(l,s),e.firstCategoryDimIndex=a)})}},Sv="original",Mv="arrayRows",Iv="objectRows",Tv="keyedColumns",Cv="unknown",Dv="typedArray",Av="column",kv="row";vo.seriesDataToSource=function(t){return new vo({data:t,sourceFormat:I(t)?Dv:Sv,fromDataset:!1})},ji(vo);var Pv=Gi(),Lv="\x00_ec_inner",Ov=ka.extend({constructor:Ov,init:function(t,e,n,i){n=n||{},this.option=null,this._theme=new ka(n),this._optionManager=i},setOption:function(t,e){O(!(Lv in t),"please use chart.getOption()"),this._optionManager.setOption(t,e),this.resetOption(null)},resetOption:function(t){var e=!1,n=this._optionManager;if(!t||"recreate"===t){var i=n.mountOption("recreate"===t);this.option&&"recreate"!==t?(this.restoreData(),this.mergeOption(i)):Po.call(this,i),e=!0}if(("timeline"===t||"media"===t)&&this.restoreData(),!t||"recreate"===t||"timeline"===t){var r=n.getTimelineOption(this);r&&(this.mergeOption(r),e=!0)}if(!t||"recreate"===t||"media"===t){var a=n.getMediaOption(this,this._api);a.length&&f(a,function(t){this.mergeOption(t,e=!0)},this)}return e},mergeOption:function(t){function e(e,i){var r=Li(t[e]),s=Bi(a.get(e),r);Ei(s),f(s,function(t){var n=t.option;S(n)&&(t.keyInfo.mainType=e,t.keyInfo.subType=Oo(e,n,t.exist))});var l=Lo(a,i);n[e]=[],a.set(e,[]),f(s,function(t,i){var r=t.exist,s=t.option;if(O(S(s)||r,"Empty component definition"),s){var h=vv.getClass(e,t.keyInfo.subType,!0);if(r&&r instanceof h)r.name=t.keyInfo.name,r.mergeOption(s,this),r.optionUpdated(s,!1);else{var u=o({dependentModels:l,componentIndex:i},t.keyInfo);r=new h(s,this,this,u),o(r,u),r.init(s,this,this,u),r.optionUpdated(null,!0)}}else r.mergeOption({},this),r.optionUpdated({},!1);a.get(e)[i]=r,n[e][i]=r.option},this),"series"===e&&zo(this,a.get("series"))}var n=this.option,a=this._componentsMap,s=[];xo(this),f(t,function(t,e){null!=t&&(vv.hasClass(e)?e&&s.push(e):n[e]=null==n[e]?i(t):r(n[e],t,!0))}),vv.topologicalTravel(s,vv.getAllClassMainTypes(),e,this),this._seriesIndicesMap=N(this._seriesIndices=this._seriesIndices||[])},getOption:function(){var t=i(this.option);return f(t,function(e,n){if(vv.hasClass(n)){for(var e=Li(e),i=e.length-1;i>=0;i--)Ni(e[i])&&e.splice(i,1);t[n]=e}}),delete t[Lv],t},getTheme:function(){return this._theme},getComponent:function(t,e){var n=this._componentsMap.get(t);return n?n[e||0]:void 0},queryComponents:function(t){var e=t.mainType;if(!e)return[];var n=t.index,i=t.id,r=t.name,a=this._componentsMap.get(e);if(!a||!a.length)return[];var o;if(null!=n)_(n)||(n=[n]),o=m(p(n,function(t){return a[t]}),function(t){return!!t});else if(null!=i){var s=_(i);o=m(a,function(t){return s&&h(i,t.id)>=0||!s&&t.id===i})}else if(null!=r){var l=_(r);o=m(a,function(t){return l&&h(r,t.name)>=0||!l&&t.name===r})}else o=a.slice();return Ro(o,t)},findComponents:function(t){function e(t){var e=r+"Index",n=r+"Id",i=r+"Name";return!t||null==t[e]&&null==t[n]&&null==t[i]?null:{mainType:r,index:t[e],id:t[n],name:t[i]}}function n(e){return t.filter?m(e,t.filter):e}var i=t.query,r=t.mainType,a=e(i),o=a?this.queryComponents(a):this._componentsMap.get(r);return n(Ro(o,t))},eachComponent:function(t,e,n){var i=this._componentsMap;if("function"==typeof t)n=e,e=t,i.each(function(t,i){f(t,function(t,r){e.call(n,i,t,r)})});else if(b(t))f(i.get(t),e,n);else if(S(t)){var r=this.findComponents(t);f(r,e,n)}},getSeriesByName:function(t){var e=this._componentsMap.get("series");return m(e,function(e){return e.name===t})},getSeriesByIndex:function(t){return this._componentsMap.get("series")[t]},getSeriesByType:function(t){var e=this._componentsMap.get("series");return m(e,function(e){return e.subType===t})},getSeries:function(){return this._componentsMap.get("series").slice()},getSeriesCount:function(){return this._componentsMap.get("series").length},eachSeries:function(t,e){f(this._seriesIndices,function(n){var i=this._componentsMap.get("series")[n];t.call(e,i,n)},this)},eachRawSeries:function(t,e){f(this._componentsMap.get("series"),t,e)},eachSeriesByType:function(t,e,n){f(this._seriesIndices,function(i){var r=this._componentsMap.get("series")[i];r.subType===t&&e.call(n,r,i)},this)},eachRawSeriesByType:function(t,e,n){return f(this.getSeriesByType(t),e,n)},isSeriesFiltered:function(t){return null==this._seriesIndicesMap.get(t.componentIndex)},getCurrentSeriesIndices:function(){return(this._seriesIndices||[]).slice()},filterSeries:function(t,e){var n=m(this._componentsMap.get("series"),t,e);zo(this,n)},restoreData:function(t){var e=this._componentsMap;zo(this,e.get("series"));var n=[];e.each(function(t,e){n.push(e)}),vv.topologicalTravel(n,vv.getAllClassMainTypes(),function(n){f(e.get(n),function(e){("series"!==n||!Ao(e,t))&&e.restoreData()})})}});c(Ov,wv);var zv=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isDisposed","on","off","getDataURL","getConnectedDataURL","getModel","getOption","getViewOfComponentModel","getViewOfSeriesModel"],Rv={};Eo.prototype={constructor:Eo,create:function(t,e){var n=[];f(Rv,function(i){var r=i.create(t,e);n=n.concat(r||[])}),this._coordinateSystems=n},update:function(t,e){f(this._coordinateSystems,function(n){n.update&&n.update(t,e)})},getCoordinateSystems:function(){return this._coordinateSystems.slice()}},Eo.register=function(t,e){Rv[t]=e},Eo.get=function(t){return Rv[t]};var Bv=f,Ev=i,Nv=p,Fv=r,Gv=/^(min|max)?(.+)$/;No.prototype={constructor:No,setOption:function(t,e){t&&f(Li(t.series),function(t){t&&t.data&&I(t.data)&&R(t.data)}),t=Ev(t,!0);var n=this._optionBackup,i=Fo.call(this,t,e,!n);this._newBaseOption=i.baseOption,n?(Wo(n.baseOption,i.baseOption),i.timelineOptions.length&&(n.timelineOptions=i.timelineOptions),i.mediaList.length&&(n.mediaList=i.mediaList),i.mediaDefault&&(n.mediaDefault=i.mediaDefault)):this._optionBackup=i},mountOption:function(t){var e=this._optionBackup;return this._timelineOptions=Nv(e.timelineOptions,Ev),this._mediaList=Nv(e.mediaList,Ev),this._mediaDefault=Ev(e.mediaDefault),this._currentMediaIndices=[],Ev(t?e.baseOption:this._newBaseOption)},getTimelineOption:function(t){var e,n=this._timelineOptions;if(n.length){var i=t.getComponent("timeline");i&&(e=Ev(n[i.getCurrentIndex()],!0))}return e},getMediaOption:function(){var t=this._api.getWidth(),e=this._api.getHeight(),n=this._mediaList,i=this._mediaDefault,r=[],a=[];if(!n.length&&!i)return a;for(var o=0,s=n.length;s>o;o++)Go(n[o].query,t,e)&&r.push(o);return!r.length&&i&&(r=[-1]),r.length&&!Ho(r,this._currentMediaIndices)&&(a=Nv(r,function(t){return Ev(-1===t?i.option:n[t].option)})),this._currentMediaIndices=r,a}};var Vv=f,Hv=S,Wv=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"],Xv=function(t,e){Vv($o(t.series),function(t){Hv(t)&&qo(t)});var n=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];e&&n.push("valueAxis","categoryAxis","logAxis","timeAxis"),Vv(n,function(e){Vv($o(t[e]),function(t){t&&(Yo(t,"axisLabel"),Yo(t.axisPointer,"label"))})}),Vv($o(t.parallel),function(t){var e=t&&t.parallelAxisDefault;Yo(e,"axisLabel"),Yo(e&&e.axisPointer,"label")}),Vv($o(t.calendar),function(t){Zo(t,"itemStyle"),Yo(t,"dayLabel"),Yo(t,"monthLabel"),Yo(t,"yearLabel")}),Vv($o(t.radar),function(t){Yo(t,"name")}),Vv($o(t.geo),function(t){Hv(t)&&(jo(t),Vv($o(t.regions),function(t){jo(t)}))}),Vv($o(t.timeline),function(t){jo(t),Zo(t,"label"),Zo(t,"itemStyle"),Zo(t,"controlStyle"),Zo(t,"checkpointStyle");var e=t.data;_(e)&&f(e,function(t){S(t)&&(Zo(t,"label"),Zo(t,"itemStyle"))})}),Vv($o(t.toolbox),function(t){Zo(t,"iconStyle"),Vv(t.feature,function(t){Zo(t,"iconStyle")})}),Yo(Ko(t.axisPointer),"label"),Yo(Ko(t.tooltip).axisPointer,"label")},Zv=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],Uv=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],Yv=function(t,e){Xv(t,e),t.series=Li(t.series),f(t.series,function(t){if(S(t)){var e=t.type;if(("pie"===e||"gauge"===e)&&null!=t.clockWise&&(t.clockwise=t.clockWise),"gauge"===e){var n=Jo(t,"pointer.color");null!=n&&Qo(t,"itemStyle.normal.color",n)}ts(t)}}),t.dataRange&&(t.visualMap=t.dataRange),f(Uv,function(e){var n=t[e];n&&(_(n)||(n=[n]),f(n,function(t){ts(t)}))})},jv=es.prototype;jv.pure=!1,jv.persistent=!0,jv.getSource=function(){return this._source};var qv={arrayRows_column:{pure:!0,count:function(){return Math.max(0,this._data.length-this._source.startIndex)},getItem:function(t){return this._data[t+this._source.startIndex]},appendData:rs},arrayRows_row:{pure:!0,count:function(){var t=this._data[0];return t?Math.max(0,t.length-this._source.startIndex):0},getItem:function(t){t+=this._source.startIndex;for(var e=[],n=this._data,i=0;io&&this._progress({start:o,end:s},this.context),this._dueIndex=s;var l=null!=this._settedOutputEnd?this._settedOutputEnd:s;this._outputDueEnd=l}else this._dueIndex=this._outputDueEnd=null!=this._settedOutputEnd?this._settedOutputEnd:this._dueEnd;return this.unfinished()},ty.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},ty.unfinished=function(){return this._progress&&this._dueIndex":"")+s.join(o?"
":", ")}function i(t){return eo(Qa(t))}var r=this.getData(),a=r.mapDimension("defaultedTooltip",!0),o=a.length,s=this.getRawValue(t),l=_(s),h=r.getItemVisual(t,"color");S(h)&&h.colorStops&&(h=(h.colorStops[0]||{}).color),h=h||"transparent";var u=o>1||l&&!o?n(s):i(o?ls(r,t,a[0]):l?s[0]:s),c=ro(h),d=r.getName(t),p=this.name;return p===hg&&(p=""),p=p?eo(p)+(e?": ":"
"):"",e?c+p+u:p+c+(d?eo(d)+": "+u:u)},isAnimationEnabled:function(){if(of.node)return!1;var t=this.getShallow("animation");return t&&this.getData().count()>this.getShallow("animationThreshold")&&(t=!1),t},restoreData:function(){this.dataTask.dirty()},getColorFromPalette:function(t,e,n){var i=this.ecModel,r=wv.getColorFromPalette.call(this,t,e,n);return r||(r=i.getColorFromPalette(t,e,n)),r},coordDimToDataDim:function(t){return this.getRawData().mapDimension(t,!0)},getProgressive:function(){return this.get("progressive")},getProgressiveThreshold:function(){return this.get("progressiveThreshold")},getAxisTooltipData:null,getTooltipPosition:null,pipeTask:null,preventIncremental:null,pipelineContext:null});c(ny,Qv),c(ny,wv);var iy=function(){this.group=new hp,this.uid=Oa("viewComponent")};iy.prototype={constructor:iy,init:function(){},render:function(){},dispose:function(){}};var ry=iy.prototype;ry.updateView=ry.updateLayout=ry.updateVisual=function(){},Yi(iy),Ki(iy,{registerWhenExtend:!0});var ay=function(){var t=Gi();return function(e){var n=t(e),i=e.pipelineContext,r=n.large,a=n.incrementalRender,o=n.large=i.large,s=n.incrementalRender=i.incrementalRender;return(r^o||a^s)&&"reset"}},oy=Gi(),sy=ay();_s.prototype={type:"chart",init:function(){},render:function(){},highlight:function(t,e,n,i){bs(t.getData(),i,"emphasis")},downplay:function(t,e,n,i){bs(t.getData(),i,"normal")},remove:function(){this.group.removeAll()},dispose:function(){},incrementalPrepareRender:null,incrementalRender:null,updateTransform:null};var ly=_s.prototype;ly.updateView=ly.updateLayout=ly.updateVisual=function(t,e,n,i){this.render(t,e,n,i)},Yi(_s,["dispose"]),Ki(_s,{registerWhenExtend:!0}),_s.markUpdateMethod=function(t,e){oy(t).updateMethod=e};var hy="\x00__throttleOriginMethod",uy="\x00__throttleRate",cy="\x00__throttleType",dy={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){var n=t.getData(),i=(t.visualColorAccessPath||"itemStyle.color").split("."),r=t.get(i)||t.getColorFromPalette(t.get("name"),null,e.getSeriesCount());if(n.setVisual("color",r),!e.isSeriesFiltered(t)){"function"!=typeof r||r instanceof Em||n.each(function(e){n.setItemVisual(e,"color",r(t.getDataParams(e)))});var a=function(t,e){var n=t.getItemModel(e),r=n.get(i,!0);null!=r&&t.setItemVisual(e,"color",r)};return{dataEach:n.hasItemOption?a:null}}}},fy={toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}},py=function(t,e){function n(t,e){if("string"!=typeof t)return t;var n=t;return f(e,function(t,e){n=n.replace(new RegExp("\\{\\s*"+e+"\\s*\\}","g"),t)}),n}function i(t){var e=o.get(t);if(null==e){for(var n=t.split("."),i=fy.aria,r=0;rs)){var d=r();l=d?n(i("general.withTitle"),{title:d}):i("general.withoutTitle");var p=[],g=s>1?"series.multiple.prefix":"series.single.prefix";l+=n(i(g),{seriesCount:s}),e.eachSeries(function(t,e){if(c>e){var r,o=t.get("name"),l="series."+(s>1?"multiple":"single")+".";r=i(o?l+"withName":l+"withoutName"),r=n(r,{seriesId:t.seriesIndex,seriesName:t.get("name"),seriesType:a(t.subType)});var u=t.getData();window.data=u,r+=u.count()>h?n(i("data.partialData"),{displayCnt:h}):i("data.allData");for(var d=[],f=0;ff){var g=u.getName(f),m=ls(u,f);d.push(n(i(g?"data.withName":"data.withoutName"),{name:g,value:m}))}r+=d.join(i("data.separator.middle"))+i("data.separator.end"),p.push(r)}}),l+=p.join(i("series.multiple.separator.middle"))+i("series.multiple.separator.end"),t.setAttribute("aria-label",l)}}},gy=Math.PI,my=function(t,e){e=e||{},s(e,{text:"loading",color:"#c23531",textColor:"#000",maskColor:"rgba(255, 255, 255, 0.8)",zlevel:0});var n=new Pm({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4}),i=new Rm({shape:{startAngle:-gy/2,endAngle:-gy/2+.1,r:10},style:{stroke:e.color,lineCap:"round",lineWidth:5},zlevel:e.zlevel,z:10001}),r=new Pm({style:{fill:"none",text:e.text,textPosition:"right",textDistance:10,textFill:e.textColor},zlevel:e.zlevel,z:10001});i.animateShape(!0).when(1e3,{endAngle:3*gy/2}).start("circularInOut"),i.animateShape(!0).when(1e3,{startAngle:3*gy/2}).delay(300).start("circularInOut");var a=new hp;return a.add(i),a.add(r),a.add(n),a.resize=function(){var e=t.getWidth()/2,a=t.getHeight()/2;i.setShape({cx:e,cy:a});var o=i.shape.r;r.setShape({x:e-o,y:a-o,width:2*o,height:2*o}),n.setShape({x:0,y:0,width:t.getWidth(),height:t.getHeight()})},a.resize(),a},vy=Ds.prototype;vy.getPerformArgs=function(t,e){if(t.__pipeline){var n=this._pipelineMap.get(t.__pipeline.id),i=n.context,r=!e&&n.progressiveEnabled&&(!i||i.incrementalRender)&&t.__idxInPipeline>n.bockIndex;return{step:r?n.step:null}}},vy.getPipeline=function(t){return this._pipelineMap.get(t)},vy.updateStreamModes=function(t,e){var n=this._pipelineMap.get(t.uid),i=t.getData(),r=i.count(),a=n.progressiveEnabled&&e.incrementalPrepareRender&&r>=n.threshold,o=t.get("large")&&r>=t.get("largeThreshold");t.pipelineContext=n.context={incrementalRender:a,large:o}},vy.restorePipelines=function(t){var e=this,n=e._pipelineMap=N();t.eachSeries(function(t){var i=t.getProgressive(),r=t.uid;n.set(r,{id:r,head:null,tail:null,threshold:t.getProgressiveThreshold(),progressiveEnabled:i&&!(t.preventIncremental&&t.preventIncremental()),bockIndex:-1,step:i||700,count:0}),Gs(e,t,t.dataTask)})},vy.prepareStageTasks=function(t){var e=this._stageTaskMap,n=this.ecInstance.getModel(),i=this.api;f(t,function(t){var r=e.get(t.uid)||e.set(t.uid,[]);t.reset&&ks(this,t,r,n,i),t.overallReset&&Ps(this,t,r,n,i)},this)},vy.prepareView=function(t,e,n,i){var r=t.renderTask,a=r.context;a.model=e,a.ecModel=n,a.api=i,r.__block=!t.incrementalPrepareRender,Gs(this,e,r)},vy.performDataProcessorTasks=function(t,e,n){As(this,t,e,n,{block:!0})},vy.performVisualTasks=function(t,e,n,i){As(this,t,e,n,i)},vy.performSeriesTasks=function(t){var e;t.eachSeries(function(t){e|=t.dataTask.perform()}),this.unfinished|=e},vy.plan=function(){this._pipelineMap.each(function(t){var e=t.tail;do{if(e.__block){t.bockIndex=e.__idxInPipeline;break}e=e.getUpstream()}while(e)})};var yy=vy.updatePayload=function(t,e){"remain"!==e&&(t.context.payload=e)};Ds.wrapStageHandler=function(t,e){return w(t)&&(t={overallReset:t,seriesType:Vs(t)}),t.uid=Oa("stageHandler"),e&&(t.visualType=e),t};var xy,_y={},wy={};Hs(_y,Ov),Hs(wy,Bo),_y.eachSeriesByType=_y.eachRawSeriesByType=function(t){xy=t},_y.eachComponent=function(t){"series"===t.mainType&&t.subType&&(xy=t.subType)};var by=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"],Sy={color:by,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],by]},My="#eee",Iy=function(){return{axisLine:{lineStyle:{color:My}},axisTick:{lineStyle:{color:My}},axisLabel:{textStyle:{color:My}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:My}}}},Ty=["#dd6b66","#759aa0","#e69d87","#8dc1a9","#ea7e53","#eedd78","#73a373","#73b9bc","#7289ab","#91ca8c","#f49f42"],Cy={color:Ty,backgroundColor:"#333",tooltip:{axisPointer:{lineStyle:{color:My},crossStyle:{color:My}}},legend:{textStyle:{color:My}},textStyle:{color:My},title:{textStyle:{color:My}},toolbox:{iconStyle:{normal:{borderColor:My}}},dataZoom:{textStyle:{color:My}},visualMap:{textStyle:{color:My}},timeline:{lineStyle:{color:My},itemStyle:{normal:{color:Ty[1]}},label:{normal:{textStyle:{color:My}}},controlStyle:{normal:{color:My,borderColor:My}}},timeAxis:Iy(),logAxis:Iy(),valueAxis:Iy(),categoryAxis:Iy(),line:{symbol:"circle"},graph:{color:Ty},gauge:{title:{textStyle:{color:My}}},candlestick:{itemStyle:{normal:{color:"#FD1050",color0:"#0CF49B",borderColor:"#FD1050",borderColor0:"#0CF49B"}}}};Cy.categoryAxis.splitLine.show=!1;var Dy=O,Ay=f,ky=w,Py=S,Ly=vv.parseClassType,Oy="4.0.0",zy={zrender:"4.0.0"},Ry=1,By=1e3,Ey=5e3,Ny=1e3,Fy=2e3,Gy=3e3,Vy=4e3,Hy=5e3,Wy={PROCESSOR:{FILTER:By,STATISTIC:Ey},VISUAL:{LAYOUT:Ny,GLOBAL:Fy,CHART:Gy,COMPONENT:Vy,BRUSH:Hy}},Xy="__flagInMainProcess",Zy="__hasGradientOrPatternBg",Uy="__optionUpdated",Yy=/^[a-zA-Z0-9_]+$/;Xs.prototype.on=Ws("on"),Xs.prototype.off=Ws("off"),Xs.prototype.one=Ws("one"),c(Xs,Df);var jy=Zs.prototype;jy._onframe=function(){if(!this._disposed){var t=this._scheduler;if(this[Uy]){var e=this[Uy].silent;this[Xy]=!0,Ys(this),qy.update.call(this),this[Xy]=!1,this[Uy]=!1,Js.call(this,e),Qs.call(this,e)}else if(t.unfinished){var n=Ry,i=this._model,r=this._api;t.unfinished=!1;do{var a=+new Date;t.performSeriesTasks(i),t.performDataProcessorTasks(Qy,i),$s(this,i),t.performVisualTasks(nx,i),al(this,this._model,r,"remain"),n-=+new Date-a}while(n>0&&t.unfinished);t.unfinished||(this._zr&&this._zr.flush(),this.trigger("finished"))}}},jy.getDom=function(){return this._dom},jy.getZr=function(){return this._zr},jy.setOption=function(t,e,n){var i;if(Py(e)&&(n=e.lazyUpdate,i=e.silent,e=e.notMerge),this[Xy]=!0,!this._model||e){var r=new No(this._api),a=this._theme,o=this._model=new Ov(null,null,a,r);o.scheduler=this._scheduler,o.init(null,null,a,r)}this._model.setOption(t,tx),n?(this[Uy]={silent:i},this[Xy]=!1):(Ys(this),qy.update.call(this),this._zr.flush(),this[Uy]=!1,this[Xy]=!1,Js.call(this,i),Qs.call(this,i))},jy.setTheme=function(){console.log("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},jy.getModel=function(){return this._model},jy.getOption=function(){return this._model&&this._model.getOption()},jy.getWidth=function(){return this._zr.getWidth()},jy.getHeight=function(){return this._zr.getHeight()},jy.getDevicePixelRatio=function(){return this._zr.painter.dpr||window.devicePixelRatio||1},jy.getRenderedCanvas=function(t){if(of.canvasSupported){t=t||{},t.pixelRatio=t.pixelRatio||1,t.backgroundColor=t.backgroundColor||this._model.get("backgroundColor");var e=this._zr,n=e.storage.getDisplayList();return f(n,function(t){t.stopAnimation(!0)}),e.painter.getRenderedCanvas(t)}},jy.getSvgDataUrl=function(){if(of.svgSupported){var t=this._zr,e=t.storage.getDisplayList();return f(e,function(t){t.stopAnimation(!0)}),t.painter.pathToSvg()}},jy.getDataURL=function(t){t=t||{};var e=t.excludeComponents,n=this._model,i=[],r=this;Ay(e,function(t){n.eachComponent({mainType:t},function(t){var e=r._componentsMap[t.__viewId];e.group.ignore||(i.push(e),e.group.ignore=!0)})});var a="svg"===this._zr.painter.getType()?this.getSvgDataUrl():this.getRenderedCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return Ay(i,function(t){t.group.ignore=!1}),a},jy.getConnectedDataURL=function(t){if(of.canvasSupported){var e=this.group,n=Math.min,r=Math.max,a=1/0;if(ox[e]){var o=a,s=a,l=-a,h=-a,u=[],c=t&&t.pixelRatio||1;f(ax,function(a){if(a.group===e){var c=a.getRenderedCanvas(i(t)),d=a.getDom().getBoundingClientRect();o=n(d.left,o),s=n(d.top,s),l=r(d.right,l),h=r(d.bottom,h),u.push({dom:c,left:d.left,top:d.top})}}),o*=c,s*=c,l*=c,h*=c;var d=l-o,p=h-s,g=vf();g.width=d,g.height=p;var m=Ci(g);return Ay(u,function(t){var e=new ai({style:{x:t.left*c-o,y:t.top*c-s,image:t.dom}});m.add(e)}),m.refreshImmediately(),g.toDataURL("image/"+(t&&t.type||"png"))}return this.getDataURL(t)}},jy.convertToPixel=x(Us,"convertToPixel"),jy.convertFromPixel=x(Us,"convertFromPixel"),jy.containPixel=function(t,e){var n,i=this._model;return t=Vi(i,t),f(t,function(t,i){i.indexOf("Models")>=0&&f(t,function(t){var r=t.coordinateSystem;if(r&&r.containPoint)n|=!!r.containPoint(e);else if("seriesModels"===i){var a=this._chartsMap[t.__viewId];a&&a.containPoint&&(n|=a.containPoint(e,t))}},this)},this),!!n},jy.getVisual=function(t,e){var n=this._model;t=Vi(n,t,{defaultMainType:"series"});var i=t.seriesModel,r=i.getData(),a=t.hasOwnProperty("dataIndexInside")?t.dataIndexInside:t.hasOwnProperty("dataIndex")?r.indexOfRawIndex(t.dataIndex):null;return null!=a?r.getItemVisual(a,e):r.getVisual(e)},jy.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},jy.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]};var qy={prepareAndUpdate:function(t){Ys(this),qy.update.call(this,t)},update:function(t){var e=this._model,n=this._api,i=this._zr,r=this._coordSysMgr,a=this._scheduler;if(e){e.restoreData(t),a.performSeriesTasks(e),r.create(e,n),a.performDataProcessorTasks(Qy,e,t),$s(this,e),el(e),r.update(e,n),nl(e),a.performVisualTasks(nx,e,t),il(this,e,n,t);var o=e.get("backgroundColor")||"transparent",s=i.painter;if(s.isSingleCanvas&&s.isSingleCanvas())i.configLayer(0,{clearColor:o});else{if(!of.canvasSupported){var l=ze(o);o=We(l,"rgb"),0===l[3]&&(o="transparent")}o.colorStops||o.image?(i.configLayer(0,{clearColor:o}),this[Zy]=!0,this._dom.style.background="transparent"):(this[Zy]&&i.configLayer(0,{clearColor:null}),this[Zy]=!1,this._dom.style.background=o)}ol(e,n)}},updateTransform:function(t){var e=this._model,n=this,i=this._api;if(e){var r=[];e.eachComponent(function(a,o){var s=n.getViewOfComponentModel(o);if(s&&s.__alive)if(s.updateTransform){var l=s.updateTransform(o,e,i,t);l&&l.update&&r.push(s)}else r.push(s)});var a=N();e.eachSeries(function(r){var o=n._chartsMap[r.__viewId];if(o.updateTransform){var s=o.updateTransform(r,e,i,t);s&&s.update&&a.set(r.uid,1)}else a.set(r.uid,1)}),nl(e),this._scheduler.performVisualTasks(nx,e,t,{setDirty:!0,dirtyMap:a}),al(n,e,i,t,a),ol(e,this._api)}},updateView:function(t){var e=this._model;e&&(_s.markUpdateMethod(t,"updateView"),nl(e),this._scheduler.performVisualTasks(nx,e,t,{setDirty:!0}),il(this,this._model,this._api,t),ol(e,this._api))},updateVisual:function(t){qy.update.call(this,t)},updateLayout:function(t){qy.update.call(this,t)}};jy.resize=function(t){this._zr.resize(t);var e=this._model;if(this._loadingFX&&this._loadingFX.resize(),e){var n=e.resetOption("media");qs(this,n,t&&t.silent)}},jy.showLoading=function(t,e){if(Py(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),rx[t]){var n=rx[t](this._api,e),i=this._zr;this._loadingFX=n,i.add(n)}},jy.hideLoading=function(){this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},jy.makeActionFromEvent=function(t){var e=o({},t);return e.type=Jy[t.type],e},jy.dispatchAction=function(t,e){if(Py(e)||(e={silent:!!e}),Ky[t.type]&&this._model){if(this[Xy])return void this._pendingActions.push(t);Ks.call(this,t,e.silent),e.flush?this._zr.flush(!0):e.flush!==!1&&of.browser.weChat&&this._throttledZrFlush(),Js.call(this,e.silent),Qs.call(this,e.silent)}},jy.appendData=function(t){var e=t.seriesIndex,n=this.getModel(),i=n.getSeriesByIndex(e);i.appendData(t),this._scheduler.unfinished=!0},jy.on=Ws("on"),jy.off=Ws("off"),jy.one=Ws("one");var $y=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];jy._initEvents=function(){Ay($y,function(t){this._zr.on(t,function(e){var n,i=this.getModel(),r=e.target;if("globalout"===t)n={};else if(r&&null!=r.dataIndex){var a=r.dataModel||i.getSeriesByIndex(r.seriesIndex);n=a&&a.getDataParams(r.dataIndex,r.dataType)||{}}else r&&r.eventData&&(n=o({},r.eventData));n&&(n.event=e,n.type=t,this.trigger(t,n))},this)},this),Ay(Jy,function(t,e){this._messageCenter.on(e,function(t){this.trigger(e,t)},this)},this)},jy.isDisposed=function(){return this._disposed},jy.clear=function(){this.setOption({series:[]},!0)},jy.dispose=function(){if(!this._disposed){this._disposed=!0,Wi(this.getDom(),hx,"");var t=this._api,e=this._model;Ay(this._componentsViews,function(n){n.dispose(e,t)}),Ay(this._chartsViews,function(n){n.dispose(e,t)}),this._zr.dispose(),delete ax[this.id]}},c(Zs,Df);var Ky={},Jy={},Qy=[],tx=[],ex=[],nx=[],ix={},rx={},ax={},ox={},sx=new Date-0,lx=new Date-0,hx="_echarts_instance_",ux={},cx=pl;Tl(Fy,dy),xl(Yv),Dl("default",my),bl({type:"highlight",event:"highlight",update:"highlight"},G),bl({type:"downplay",event:"downplay",update:"downplay"},G),yl("light",Sy),yl("dark",Cy);var dx={};El.prototype={constructor:El,add:function(t){return this._add=t,this},update:function(t){return this._update=t,this},remove:function(t){return this._remove=t,this},execute:function(){var t,e=this._old,n=this._new,i={},r={},a=[],o=[];for(Nl(e,i,a,"_oldKeyGetter",this),Nl(n,r,o,"_newKeyGetter",this),t=0;tu;u++)this._add&&this._add(l[u]);else this._add&&this._add(l)}}}};var fx=N(["tooltip","label","itemName","itemId","seriesName"]),px=S,gx="undefined",mx=typeof window===gx?global:window,vx="e\x00\x00",yx={"float":typeof mx.Float64Array===gx?Array:mx.Float64Array,"int":typeof mx.Int32Array===gx?Array:mx.Int32Array,ordinal:Array,number:Array,time:Array},xx=["stackedOn","hasItemOption","_nameList","_idList","_rawData","_rawExtent","_chunkSize","_chunkCount","_dimValueGetter","_count","_rawCount","_nameDimIdx","_idDimIdx"],_x=function(t,e){t=t||["x","y"];for(var n={},i=[],r=0;r=e)){for(var n,i=this._chunkSize,r=this._rawData,a=this._storage,o=this.dimensions,s=this._dimensionInfos,l=this._nameList,h=this._idList,u=this._rawExtent,c=this._nameRepeatCount={},d=this._chunkCount,f=d-1,p=0;pw;w+=i)a[g].push(new v(Math.min(e-w,i)));this._chunkCount=a[g].length}for(var b=t;e>b;b++){for(var S=r.getItem(b),M=Math.floor(b/i),I=b%i,w=0;wu[g][1]&&(u[g][1]=C)}if(!r.pure){var D=l[b];S&&!D&&(null!=n?D=this._getNameFromStore(b):null!=S.name&&(l[b]=D=S.name));var A=null==S?null:S.id;null==A&&null!=D&&(c[D]=c[D]||0,A=D,c[D]>0&&(A+="__ec__"+c[D]),c[D]++),null!=A&&(h[b]=A)}}!r.persistent&&r.clean&&r.clean(),this._rawCount=this._count=e,this._extent={}}},bx._getNameFromStore=function(t){var e=this._nameDimIdx;if(null!=e){var n=this._chunkSize,i=Math.floor(t/n),r=t%n,a=this.dimensions[e],o=this._dimensionInfos[a].ordinalMeta;if(o)return o.categories[t];var s=this._storage[a][i];return s&&s[r]}},bx._getIdFromStore=function(t){var e=this._idDimIdx;if(null!=e){var n=this._chunkSize,i=Math.floor(t/n),r=t%n,a=this.dimensions[e],o=this._dimensionInfos[a].ordinalMeta;if(o)return o.categories[t];var s=this._storage[a][i];return s&&s[r]}},bx.count=function(){return this._count},bx.getIndices=function(){if(this._indices){var t=this._indices.constructor;return new t(this._indices.buffer,0,this._count)}for(var t=Hl(this),e=new t(this.count()),n=0;n=0&&e=0&&u>0||0>=s&&0>u)&&(s+=u),h=h.stackedOn}}return s},bx._getFast=function(t,e){var n=Math.floor(e/this._chunkSize),i=e%this._chunkSize,r=this._storage[t][n];return r[i]},bx.getValues=function(t,e,n){var i=[];_(t)||(n=e,e=t,t=this.dimensions);for(var r=0,a=t.length;a>r;r++)i.push(this.get(t[r],e,n));return i},bx.hasValue=function(t){for(var e=this._dimensionsSummary.dataDimsOnCoord,n=this._dimensionInfos,i=0,r=e.length;r>i;i++)if("ordinal"!==n[e[i]].type&&isNaN(this.get(e[i],t)))return!1;return!0},bx.getDataExtent=function(t,e){t=this.getDimension(t);var n=this._storage[t],i=[1/0,-1/0];if(e=(e||!1)&&this.isStacked(t),!n)return i;var r,a=this.count(),o=[t,!!e].join("_"),s=!this._indices&&!e;if(s)return this._rawExtent[t].slice();if(r=this._extent[o])return r.slice();r=i;for(var l=r[0],h=r[1],u=0;a>u;u++){var c=e?this.get(t,u,!0):this._getFast(t,this.getRawIndex(u));l>c&&(l=c),c>h&&(h=c)}return r=[l,h],this._extent[o]=r,r},bx.getApproximateExtent=function(t,e){return t=this.getDimension(t),this._approximateExtent[t]||this.getDataExtent(t,e)},bx.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},bx.isStacked=function(t){var e=this._dimensionInfos[t];return e&&e.stackable&&this.stackedOn},bx.getSum=function(t,e){var n=this._storage[t],i=0;if(n)for(var r=0,a=this.count();a>r;r++){var o=this.get(t,r,e);isNaN(o)||(i+=o)}return i},bx.indexOf=function(t,e){var n=this._storage,i=n[t],r=this._chunkSize;if(i)for(var a=0,o=this.count();o>a;a++){var s=Math.floor(a/r),l=a%r;if(i[s][l]===e)return a}return-1},bx.indexOfName=function(t){for(var e=0,n=this.count();n>e;e++)if(this.getName(e)===t)return e;return-1},bx.indexOfRawIndex=function(t){if(!this._indices)return t;if(t>=this._rawCount||0>t)return-1;var e=this._indices,n=e[t];if(null!=n&&n=i;){var a=(i+r)/2|0;if(e[a]t))return a;r=a-1}}return-1},bx.indicesOfNearest=function(t,e,n,i){var r=this._storage,a=r[t],o=[];if(!a)return o;null==i&&(i=1/0);for(var s=Number.MAX_VALUE,l=-1,h=0,u=this.count();u>h;h++){var c=e-this.get(t,h,n),d=Math.abs(c);i>=c&&s>=d&&((s>d||c>=0&&0>l)&&(s=d,l=c,o.length=0),o.push(h))}return o},bx.getRawIndex=Zl,bx.getRawDataItem=function(t){if(this._rawData.persistent)return this._rawData.getItem(this.getRawIndex(t));for(var e=[],n=0;no;o++)s[o]=this.get(t[o],a,n);s[o]=a,e.apply(i,s)}}},bx.filterSelf=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||!1,i=i||this,t=p(jl(t),this.getDimension,this);for(var r=this.count(),a=Hl(this),o=new a(r),s=[],l=t.length,h=0,u=t[0],c=0;r>c;c++){var d,f=this.getRawIndex(c);if(0===l)d=e.call(i,c);else if(1===l){var g=n?this.get(u,c,!0):this._getFast(u,f);d=e.call(i,g,c)}else{for(var m=0;l>m;m++)s[m]=n?this.get(t[m],c,!0):this._getFast(u,f);s[m]=c,d=e.apply(i,s)}d&&(o[h++]=f)}return r>h&&(this._indices=o),this._count=h,this._extent={},this.getRawIndex=this._indices?Ul:Zl,this}},bx.selectRange=function(t,e){if(this._count){e=e||!1;var n=[];for(var i in t)t.hasOwnProperty(i)&&n.push(i);var r=n.length;if(r){var a=this.count(),o=Hl(this),s=new o(a),l=0,h=n[0],u=t[h][0],c=t[h][1],d=!1;if(!this._indices&&!e){var f=0;if(1===r){for(var p=this._storage[n[0]],g=0;gy;y++){var x=m[y];x>=u&&c>=x&&(s[l++]=f),f++}d=!0}else if(2===r){for(var p=this._storage[h],_=this._storage[n[1]],w=t[n[1]][0],b=t[n[1]][1],g=0;gy;y++){var x=m[y],M=S[y];x>=u&&c>=x&&M>=w&&b>=M&&(s[l++]=f),f++}d=!0}}if(!d)if(1===r){e=e||this.isStacked(h); +for(var y=0;a>y;y++){var I=this.getRawIndex(y),x=e?this.get(h,y,!0):this._getFast(h,I);x>=u&&c>=x&&(s[l++]=I)}}else for(var y=0;a>y;y++){for(var T=!0,I=this.getRawIndex(y),g=0;r>g;g++){var C=n[g],x=e?this.get(C,y,!0):this._getFast(i,I);(xt[C][1])&&(T=!1)}T&&(s[l++]=this.getRawIndex(y))}return a>l&&(this._indices=s),this._count=l,this._extent={},this.getRawIndex=this._indices?Ul:Zl,this}}},bx.mapArray=function(t,e,n,i){"function"==typeof t&&(i=n,n=e,e=t,t=[]);var r=[];return this.each(t,function(){r.push(e&&e.apply(this,arguments))},n,i),r},bx.map=function(t,e,n,i){t=p(jl(t),this.getDimension,this);var r=ql(this,t);r._indices=this._indices,r.getRawIndex=r._indices?Ul:Zl;for(var a=r._storage,o=[],s=this._chunkSize,l=t.length,h=this.count(),u=[],c=0;h>c;c++){for(var d=0;l>d;d++)u[d]=this.get(t[d],c,n);u[l]=c;var f=e&&e.apply(i,u);if(null!=f){"object"!=typeof f&&(o[0]=f,f=o);for(var g=this.getRawIndex(c),m=Math.floor(g/s),v=g%s,y=0;yf;f+=s){s>h-f&&(s=h-f,o.length=s);for(var p=0;s>p;p++){var g=this.getRawIndex(f+p),m=Math.floor(g/u),v=g%u;o[p]=l[m][v]}var y=n(o),x=this.getRawIndex(Math.min(f+i(o,y)||0,h-1)),_=Math.floor(x/u),w=x%u;l[_][w]=y,c[d++]=x}return r._count=d,r._indices=c,r.getRawIndex=Ul,r},bx.getItemModel=function(t){var e=this.hostModel;return new ka(this.getRawDataItem(t),e,e&&e.ecModel)},bx.diff=function(t){var e=this;return new El(t?t.getIndices():[],this.getIndices(),function(e){return Yl(t,e)},function(t){return Yl(e,t)})},bx.getVisual=function(t){var e=this._visual;return e&&e[t]},bx.setVisual=function(t,e){if(px(t))for(var n in t)t.hasOwnProperty(n)&&this.setVisual(n,t[n]);else this._visual=this._visual||{},this._visual[t]=e},bx.setLayout=function(t,e){if(px(t))for(var n in t)t.hasOwnProperty(n)&&this.setLayout(n,t[n]);else this._layout[t]=e},bx.getLayout=function(t){return this._layout[t]},bx.getItemLayout=function(t){return this._itemLayouts[t]},bx.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?o(this._itemLayouts[t]||{},e):e},bx.clearItemLayouts=function(){this._itemLayouts.length=0},bx.getItemVisual=function(t,e,n){var i=this._itemVisuals[t],r=i&&i[e];return null!=r||n?r:this.getVisual(e)},bx.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{},r=this.hasItemVisual;if(this._itemVisuals[t]=i,px(e))for(var a in e)e.hasOwnProperty(a)&&(i[a]=e[a],r[a]=!0);else i[e]=n,r[e]=!0},bx.clearAllVisual=function(){this._visual={},this._itemVisuals=[],this.hasItemVisual={}};var Sx=function(t){t.seriesIndex=this.seriesIndex,t.dataIndex=this.dataIndex,t.dataType=this.dataType};bx.setItemGraphicEl=function(t,e){var n=this.hostModel;e&&(e.dataIndex=t,e.dataType=this.dataType,e.seriesIndex=n&&n.seriesIndex,"group"===e.type&&e.traverse(Sx,e)),this._graphicEls[t]=e},bx.getItemGraphicEl=function(t){return this._graphicEls[t]},bx.eachItemGraphicEl=function(t,e){f(this._graphicEls,function(n,i){n&&t&&t.call(e,n,i)})},bx.cloneShallow=function(t){if(!t){var e=p(this.dimensions,this.getDimensionInfo,this);t=new _x(e,this.hostModel)}if(t._storage=this._storage,Xl(t,this),this._indices){var n=this._indices.constructor;t._indices=new n(this._indices)}else t._indices=null;return t.getRawIndex=t._indices?Ul:Zl,t._extent=i(this._extent),t._approximateExtent=i(this._approximateExtent),t},bx.wrapMethod=function(t,e){var n=this[t];"function"==typeof n&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var t=n.apply(this,arguments);return e.apply(this,[t].concat(P(arguments)))})},bx.TRANSFERABLE_METHODS=["cloneShallow","downSample","map"],bx.CHANGABLE_METHODS=["filterSelf","selectRange"];var Mx=function(t,e){return e=e||{},Kl(e.coordDimensions||[],t,{dimsDef:e.dimensionsDefine||t.dimensionsDefine,encodeDef:e.encodeDefine||t.encodeDefine,dimCount:e.dimensionsCount,extraPrefix:e.extraPrefix,extraFromZero:e.extraFromZero})};rh.prototype.parse=function(t){return t},rh.prototype.getSetting=function(t){return this._setting[t]},rh.prototype.contain=function(t){var e=this._extent;return t>=e[0]&&t<=e[1]},rh.prototype.normalize=function(t){var e=this._extent;return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])},rh.prototype.scale=function(t){var e=this._extent;return t*(e[1]-e[0])+e[0]},rh.prototype.unionExtent=function(t){var e=this._extent;t[0]e[1]&&(e[1]=t[1])},rh.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e,!0))},rh.prototype.getExtent=function(){return this._extent.slice()},rh.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=t),isNaN(e)||(n[1]=e)},rh.prototype.getTicksLabels=function(){for(var t=[],e=this.getTicks(),n=0;ne[1]&&(e[1]=t[1]),kx.prototype.setExtent.call(this,e[0],e[1])},getInterval:function(){return this._interval},setInterval:function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=hh(t)},getTicks:function(){return dh(this._interval,this._extent,this._niceExtent,this._intervalPrecision)},getTicksLabels:function(){for(var t=[],e=this.getTicks(),n=0;nr&&(r=-r,i.reverse());var a=lh(i,t,e,n);this._intervalPrecision=a.intervalPrecision,this._interval=a.interval,this._niceExtent=a.niceTickExtent}},niceExtent:function(t){var e=this._extent;if(e[0]===e[1])if(0!==e[0]){var n=e[0];t.fixMax?e[0]-=n/2:(e[1]+=n/2,e[0]-=n/2)}else e[1]=1;var i=e[1]-e[0];isFinite(i)||(e[0]=0,e[1]=1),this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var r=this._interval;t.fixMin||(e[0]=Ax(Math.floor(e[0]/r)*r)),t.fixMax||(e[1]=Ax(Math.ceil(e[1]/r)*r))}});kx.create=function(){return new kx};var Px="__ec_stack_",Lx=kx.prototype,Ox=Math.ceil,zx=Math.floor,Rx=1e3,Bx=60*Rx,Ex=60*Bx,Nx=24*Ex,Fx=function(t,e,n,i){for(;i>n;){var r=n+i>>>1;t[r][1]a&&(a=e),null!=n&&a>n&&(a=n);var o=Vx.length,s=Fx(Vx,a,0,o),l=Vx[Math.min(s,o-1)],h=l[1];if("year"===l[0]){var u=r/h,c=$a(u/t,!0);h*=c}var d=this.getSetting("useUTC")?0:60*new Date(+i[0]||+i[1]).getTimezoneOffset()*1e3,f=[Math.round(Ox((i[0]-d)/h)*h+d),Math.round(zx((i[1]-d)/h)*h+d)];ch(f,i),this._stepLvl=l,this._interval=h,this._niceExtent=f},parse:function(t){return+Ya(t)}});f(["contain","normalize"],function(t){Gx.prototype[t]=function(e){return Lx[t].call(this,this.parse(e))}});var Vx=[["hh:mm:ss",Rx],["hh:mm:ss",5*Rx],["hh:mm:ss",10*Rx],["hh:mm:ss",15*Rx],["hh:mm:ss",30*Rx],["hh:mm\nMM-dd",Bx],["hh:mm\nMM-dd",5*Bx],["hh:mm\nMM-dd",10*Bx],["hh:mm\nMM-dd",15*Bx],["hh:mm\nMM-dd",30*Bx],["hh:mm\nMM-dd",Ex],["hh:mm\nMM-dd",2*Ex],["hh:mm\nMM-dd",6*Ex],["hh:mm\nMM-dd",12*Ex],["MM-dd\nyyyy",Nx],["MM-dd\nyyyy",2*Nx],["MM-dd\nyyyy",3*Nx],["MM-dd\nyyyy",4*Nx],["MM-dd\nyyyy",5*Nx],["MM-dd\nyyyy",6*Nx],["week",7*Nx],["MM-dd\nyyyy",10*Nx],["week",14*Nx],["week",21*Nx],["month",31*Nx],["week",42*Nx],["month",62*Nx],["week",42*Nx],["quarter",380*Nx/4],["month",31*Nx*4],["month",31*Nx*5],["half-year",380*Nx/2],["month",31*Nx*8],["month",31*Nx*10],["year",380*Nx]];Gx.create=function(t){return new Gx({useUTC:t.ecModel.get("useUTC")})};var Hx=rh.prototype,Wx=kx.prototype,Xx=Ha,Zx=Fa,Ux=Math.floor,Yx=Math.ceil,jx=Math.pow,qx=Math.log,$x=rh.extend({type:"log",base:10,$constructor:function(){rh.apply(this,arguments),this._originalScale=new kx},getTicks:function(){var t=this._originalScale,e=this._extent,n=t.getExtent();return p(Wx.getTicks.call(this),function(i){var r=Fa(jx(this.base,i));return r=i===e[0]&&t.__fixMin?yh(r,n[0]):r,r=i===e[1]&&t.__fixMax?yh(r,n[1]):r},this)},getLabel:Wx.getLabel,scale:function(t){return t=Hx.scale.call(this,t),jx(this.base,t)},setExtent:function(t,e){var n=this.base;t=qx(t)/qx(n),e=qx(e)/qx(n),Wx.setExtent.call(this,t,e)},getExtent:function(){var t=this.base,e=Hx.getExtent.call(this);e[0]=jx(t,e[0]),e[1]=jx(t,e[1]);var n=this._originalScale,i=n.getExtent();return n.__fixMin&&(e[0]=yh(e[0],i[0])),n.__fixMax&&(e[1]=yh(e[1],i[1])),e},unionExtent:function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=qx(t[0])/qx(e),t[1]=qx(t[1])/qx(e),Hx.unionExtent.call(this,t)},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e,!0,function(t){return t>0}))},niceTicks:function(t){t=t||10;var e=this._extent,n=e[1]-e[0];if(!(1/0===n||0>=n)){var i=ja(n),r=t/n*i;for(.5>=r&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&Math.abs(i)>0;)i*=10;var a=[Fa(Yx(e[0]/i)*i),Fa(Ux(e[1]/i)*i)];this._interval=i,this._niceExtent=a}},niceExtent:function(t){Wx.niceExtent.call(this,t);var e=this._originalScale;e.__fixMin=t.fixMin,e.__fixMax=t.fixMax}});f(["contain","normalize"],function(t){$x.prototype[t]=function(e){return e=qx(e)/qx(this.base),Hx[t].call(this,e)}}),$x.create=function(){return new $x};var Kx={getFormattedLabels:function(){return Ih(this.axis,this.get("axisLabel.formatter"))},getMin:function(t){var e=this.option,n=t||null==e.rangeStart?e.min:e.rangeStart;return this.axis&&null!=n&&"dataMin"!==n&&"function"!=typeof n&&!C(n)&&(n=this.axis.scale.parse(n)),n},getMax:function(t){var e=this.option,n=t||null==e.rangeEnd?e.max:e.rangeEnd;return this.axis&&null!=n&&"dataMax"!==n&&"function"!=typeof n&&!C(n)&&(n=this.axis.scale.parse(n)),n},getNeedCrossZero:function(){var t=this.option;return null!=t.rangeStart||null!=t.rangeEnd?!1:!t.scale},getCoordSysModel:G,setRange:function(t,e){this.option.rangeStart=t,this.option.rangeEnd=e},resetRange:function(){this.option.rangeStart=this.option.rangeEnd=null}},Jx=Hr({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,a=e.height/2;t.moveTo(n,i-a),t.lineTo(n+r,i+a),t.lineTo(n-r,i+a),t.closePath()}}),Qx=Hr({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,a=e.height/2;t.moveTo(n,i-a),t.lineTo(n+r,i),t.lineTo(n,i+a),t.lineTo(n-r,i),t.closePath()}}),t_=Hr({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.x,i=e.y,r=e.width/5*3,a=Math.max(r,e.height),o=r/2,s=o*o/(a-o),l=i-a+o+s,h=Math.asin(s/o),u=Math.cos(h)*o,c=Math.sin(h),d=Math.cos(h),f=.6*o,p=.7*o;t.moveTo(n-u,l+s),t.arc(n,l,o,Math.PI-h,2*Math.PI+h),t.bezierCurveTo(n+u-c*f,l+s+d*f,n,i-p,n,i),t.bezierCurveTo(n,i-p,n-u+c*f,l+s+d*f,n-u,l+s),t.closePath()}}),e_=Hr({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.height,i=e.width,r=e.x,a=e.y,o=i/3*2;t.moveTo(r,a),t.lineTo(r+o,a+n),t.lineTo(r,a+n/4*3),t.lineTo(r-o,a+n),t.lineTo(r,a),t.closePath()}}),n_={line:Lm,rect:Pm,roundRect:Pm,square:Pm,circle:bm,diamond:Qx,pin:t_,arrow:e_,triangle:Jx},i_={line:function(t,e,n,i,r){r.x1=t,r.y1=e+i/2,r.x2=t+n,r.y2=e+i/2},rect:function(t,e,n,i,r){r.x=t,r.y=e,r.width=n,r.height=i},roundRect:function(t,e,n,i,r){r.x=t,r.y=e,r.width=n,r.height=i,r.r=Math.min(n,i)/4},square:function(t,e,n,i,r){var a=Math.min(n,i);r.x=t,r.y=e,r.width=a,r.height=a},circle:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.r=Math.min(n,i)/2},diamond:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.width=n,r.height=i},pin:function(t,e,n,i,r){r.x=t+n/2,r.y=e+i/2,r.width=n,r.height=i},arrow:function(t,e,n,i,r){r.x=t+n/2,r.y=e+i/2,r.width=n,r.height=i},triangle:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.width=n,r.height=i}},r_={};f(n_,function(t,e){r_[e]=new t});var a_=Hr({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},beforeBrush:function(){var t=this.style,e=this.shape;"pin"===e.symbolType&&"inside"===t.textPosition&&(t.textPosition=["50%","40%"],t.textAlign="center",t.textVerticalAlign="middle")},buildPath:function(t,e,n){var i=e.symbolType,r=r_[i];"none"!==e.symbolType&&(r||(i="rect",r=r_[i]),i_[i](e.x,e.y,e.width,e.height,r.shape),r.buildPath(t,r.shape,n))}}),o_=(Object.freeze||Object)({createList:Ah,getLayoutRect:lo,createScale:kh,mixinAxisModelCommonMethods:Ph,completeDimensions:Kl,createDimensions:Mx,createSymbol:Dh}),s_=1e-8;zh.prototype={constructor:zh,properties:null,getBoundingRect:function(){var t=this._rect;if(t)return t;for(var e=Number.MAX_VALUE,n=[e,e],i=[-e,-e],r=[],a=[],o=this.geometries,s=0;si;i++)if("polygon"===n[i].type){var a=n[i].exterior,o=n[i].interiors;if(Oh(a,t[0],t[1])){for(var s=0;s<(o?o.length:0);s++)if(Oh(o[s]))continue t;return!0}}return!1},transformTo:function(t,e,n,i){var r=this.getBoundingRect(),a=r.width/r.height;n?i||(i=n/a):n=a*i;for(var o=new rn(t,e,n,i),s=r.calculateTransform(o),l=this.geometries,h=0;h0}),function(t){var e=t.properties,n=t.geometry,i=n.coordinates,r=[];"Polygon"===n.type&&r.push({type:"polygon",exterior:i[0],interiors:i.slice(1)}),"MultiPolygon"===n.type&&f(i,function(t){t[0]&&r.push({type:"polygon",exterior:t[0],interiors:t.slice(1)})});var a=new zh(e.name,r,e.cp);return a.properties=e,a})},h_=Ea,u_=[0,1],c_=function(t,e,n){this.dim=t,this.scale=e,this._extent=n||[0,0],this.inverse=!1,this.onBand=!1,this._labelInterval};c_.prototype={constructor:c_,contain:function(t){var e=this._extent,n=Math.min(e[0],e[1]),i=Math.max(e[0],e[1]);return t>=n&&i>=t},containData:function(t){return this.contain(this.dataToCoord(t))},getExtent:function(){return this._extent.slice()},getPixelPrecision:function(t){return Wa(t||this.scale.getExtent(),this._extent)},setExtent:function(t,e){var n=this._extent;n[0]=t,n[1]=e},dataToCoord:function(t,e){var n=this._extent,i=this.scale;return t=i.normalize(t),this.onBand&&"ordinal"===i.type&&(n=n.slice(),Eh(n,i.count())),h_(t,u_,n,e)},coordToData:function(t,e){var n=this._extent,i=this.scale;this.onBand&&"ordinal"===i.type&&(n=n.slice(),Eh(n,i.count()));var r=h_(t,n,u_,e);return this.scale.scale(r)},pointToData:function(){},getTicksCoords:function(t){if(this.onBand&&!t){for(var e=this.getBands(),n=[],i=0;io;o++)e.push([a*o/n+i,a*(o+1)/n+i]);return e},getBandWidth:function(){var t=this._extent,e=this.scale.getExtent(),n=e[1]-e[0]+(this.onBand?1:0);0===n&&(n=1);var i=Math.abs(t[1]-t[0]);return Math.abs(i)/n},isHorizontal:null,getRotate:null,getLabelInterval:function(){var t=this._labelInterval;if(!t){var e=this.model,n=e.getModel("axisLabel");t=n.get("interval"),"category"!==this.type||null!=t&&"auto"!==t||(t=Mh(p(this.scale.getTicks(),this.dataToCoord,this),e.getFormattedLabels(),n.getFont(),this.getRotate?this.getRotate():this.isHorizontal&&!this.isHorizontal()?90:0,n.get("rotate"))),this._labelInterval=t}return t}};var d_=l_,f_={};f(["map","each","filter","indexOf","inherits","reduce","filter","bind","curry","isArray","isString","isObject","isFunction","extend","defaults","clone","merge"],function(t){f_[t]=_f[t]});var p_=function(t){this._axes={},this._dimList=[],this.name=t||""};p_.prototype={constructor:p_,type:"cartesian",getAxis:function(t){return this._axes[t]},getAxes:function(){return p(this._dimList,Nh,this)},getAxesByScale:function(t){return t=t.toLowerCase(),m(this.getAxes(),function(e){return e.scale.type===t})},addAxis:function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)},dataToCoord:function(t){return this._dataCoordConvert(t,"dataToCoord")},coordToData:function(t){return this._dataCoordConvert(t,"coordToData")},_dataCoordConvert:function(t,e){for(var n=this._dimList,i=t instanceof Array?[]:{},r=0;re[1]&&e.reverse(),e},getOtherAxis:function(){this.grid.getOtherAxis()},isLabelIgnored:function(t){if("category"===this.type){var e=this.getLabelInterval();return"function"==typeof e&&!e(t,this.scale.getLabel(t))||t%(e+1)}},pointToData:function(t,e){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),e)},toLocalCoord:null,toGlobalCoord:null},u(g_,c_);var m_={show:!0,zlevel:0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#333",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#ccc"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.3)","rgba(200,200,200,0.3)"]}}},v_={};v_.categoryAxis=r({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},m_),v_.valueAxis=r({boundaryGap:[0,0],splitNumber:5},m_),v_.timeAxis=s({scale:!0,min:"dataMin",max:"dataMax"},v_.valueAxis),v_.logAxis=s({scale:!0,logBase:10},v_.valueAxis);var y_=["value","category","time","log"],x_=function(t,e,n,i){f(y_,function(o){e.extend({type:t+"Axis."+o,mergeDefaultAndTheme:function(e,i){var a=this.layoutMode,s=a?uo(e):{},l=i.getTheme();r(e,l.get(o+"Axis")),r(e,this.getDefaultOption()),e.type=n(t,e),a&&ho(e,s,a)},optionUpdated:function(){var t=this.option;"category"===t.type&&(this.__ordinalMeta=ah.createByAxisModel(this))},getCategories:function(){return"category"===this.option.type?this.__ordinalMeta.categories:void 0},getOrdinalMeta:function(){return this.__ordinalMeta},defaultOption:a([{},v_[o+"Axis"],i],!0)})}),vv.registerSubTypeDefaulter(t+"Axis",x(n,t))},__=vv.extend({type:"cartesian2dAxis",axis:null,init:function(){__.superApply(this,"init",arguments),this.resetRange()},mergeOption:function(){__.superApply(this,"mergeOption",arguments),this.resetRange()},restoreData:function(){__.superApply(this,"restoreData",arguments),this.resetRange()},getCoordSysModel:function(){return this.ecModel.queryComponents({mainType:"grid",index:this.option.gridIndex,id:this.option.gridId})[0]}});r(__.prototype,Kx);var w_={offset:0};x_("x",__,Gh,w_),x_("y",__,Gh,w_),vv.extend({type:"grid",dependencies:["xAxis","yAxis"],layoutMode:"box",coordinateSystem:null,defaultOption:{show:!1,zlevel:0,z:0,left:"10%",top:60,right:"10%",bottom:60,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"}});var b_=f,S_=Sh,M_=wh,I_=Xh.prototype;I_.type="grid",I_.axisPointerEnabled=!0,I_.getRect=function(){return this._rect},I_.update=function(t,e){var n=this._axesMap;this._updateScale(t,this.model),b_(n.x,function(t){M_(t.scale,t.model)}),b_(n.y,function(t){M_(t.scale,t.model)}),b_(n.x,function(t){Zh(n,"y",t)}),b_(n.y,function(t){Zh(n,"x",t)}),this.resize(this.model,e)},I_.resize=function(t,e,n){function i(){b_(a,function(t){var e=t.isHorizontal(),n=e?[0,r.width]:[0,r.height],i=t.inverse?1:0;t.setExtent(n[i],n[1-i]),Yh(t,e?r.x:r.y)})}var r=lo(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()});this._rect=r;var a=this._axesList;i(),!n&&t.get("containLabel")&&(b_(a,function(t){if(!t.model.get("axisLabel.inside")){var e=Wh(t);if(e){var n=t.isHorizontal()?"height":"width",i=t.model.get("axisLabel.margin");r[n]-=e[n]+i,"top"===t.position?r.y+=e.height+i:"left"===t.position&&(r.x+=e.width+i)}}}),i())},I_.getAxis=function(t,e){var n=this._axesMap[t];if(null!=n){if(null==e)for(var i in n)if(n.hasOwnProperty(i))return n[i];return n[e]}},I_.getAxes=function(){return this._axesList.slice()},I_.getCartesian=function(t,e){if(null!=t&&null!=e){var n="x"+t+"y"+e;return this._coordsMap[n]}S(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var i=0,r=this._coordsList;i0?1:-1,o=i.height>0?1:-1;return{x:i.x+a*r/2,y:i.y+o*r/2,width:i.width-a*r,height:i.height-o*r}},polar:function(t,e){var n=t.getItemLayout(e);return{cx:n.cx,cy:n.cy,r0:n.r0,r:n.r,startAngle:n.startAngle,endAngle:n.endAngle}}},O_=Math.PI,z_=function(t,e){this.opt=e,this.axisModel=t,s(e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0}),this.group=new hp;var n=new hp({position:e.position.slice(),rotation:e.rotation});n.updateTransform(),this._transform=n.transform,this._dumbGroup=n};z_.prototype={constructor:z_,hasBuilder:function(t){return!!R_[t]},add:function(t){R_[t].call(this)},getGroup:function(){return this.group}};var R_={axisLine:function(){var t=this.opt,e=this.axisModel;if(e.get("axisLine.show")){var n=this.axisModel.axis.getExtent(),i=this._transform,r=[n[0],0],a=[n[1],0];i&&(ae(r,r,i),ae(a,a,i));var s=o({lineCap:"round"},e.getModel("axisLine.lineStyle").getLineStyle());this.group.add(new Lm(jr({anid:"line",shape:{x1:r[0],y1:r[1],x2:a[0],y2:a[1]},style:s,strokeContainThreshold:t.strokeContainThreshold||5,silent:!0,z2:1})));var l=e.get("axisLine.symbol"),h=e.get("axisLine.symbolSize");if(null!=l){"string"==typeof l&&(l=[l,l]),("string"==typeof h||"number"==typeof h)&&(h=[h,h]);var u=h[0],c=h[1];f([[t.rotation+Math.PI/2,r],[t.rotation-Math.PI/2,a]],function(t,e){if("none"!==l[e]&&null!=l[e]){var n=Dh(l[e],-u/2,-c/2,u,c,s.stroke,!0);n.attr({rotation:t[0],position:t[1],silent:!0}),this.group.add(n)}},this)}}},axisTickLabel:function(){var t=this.axisModel,e=this.opt,n=uu(this,t,e),i=cu(this,t,e);ou(t,i,n)},axisName:function(){var t=this.opt,e=this.axisModel,n=D(t.axisName,e.get("name"));if(n){var i,r=e.get("nameLocation"),a=t.nameDirection,s=e.getModel("nameTextStyle"),l=e.get("nameGap")||0,h=this.axisModel.axis.getExtent(),u=h[0]>h[1]?-1:1,c=["start"===r?h[0]-u*l:"end"===r?h[1]+u*l:(h[0]+h[1])/2,hu(r)?t.labelOffset+a*l:0],d=e.get("nameRotate");null!=d&&(d=d*O_/180);var f;hu(r)?i=B_(t.rotation,null!=d?d:t.rotation,a):(i=ru(t,r,d||0,h),f=t.axisNameAvailableWidth,null!=f&&(f=Math.abs(f/Math.sin(i.rotation)),!isFinite(f)&&(f=null))); +var p=s.getFont(),g=e.get("nameTruncate",!0)||{},m=g.ellipsis,v=D(t.nameTruncateMaxWidth,g.maxWidth,f),y=null!=m&&null!=v?lv(n,v,p,m,{minChar:2,placeholder:g.placeholder}):n,x=e.get("tooltip",!0),_=e.mainType,w={componentType:_,name:n,$vars:["name"]};w[_+"Index"]=e.componentIndex;var b=new wm({anid:"name",__fullText:n,__truncatedText:y,position:c,rotation:i.rotation,silent:au(e),z2:1,tooltip:x&&x.show?o({content:n,formatter:function(){return n},formatterParams:w},x):null});ca(b.style,s,{text:y,textFont:p,textFill:s.getTextColor()||e.get("axisLine.lineStyle.color"),textAlign:i.textAlign,textVerticalAlign:i.textVerticalAlign}),e.get("triggerEvent")&&(b.eventData=iu(e),b.eventData.targetType="axisName",b.eventData.name=n),this._dumbGroup.add(b),b.updateTransform(),this.group.add(b),b.decomposeTransform()}}},B_=z_.innerTextLayout=function(t,e,n){var i,r,a=Za(e-t);return Ua(a)?(r=n>0?"top":"bottom",i="center"):Ua(a-O_)?(r=n>0?"bottom":"top",i="center"):(r="middle",i=a>0&&O_>a?n>0?"right":"left":n>0?"left":"right"),{rotation:a,textAlign:i,textVerticalAlign:r}},E_=z_.ifIgnoreOnTick=function(t,e,n,i,r,a){if(0===e&&r||e===i-1&&a)return!1;var o,s=t.scale;return"ordinal"===s.type&&("function"==typeof n?(o=s.getTicks()[e],!n(o,s.getLabel(o))):e%(n+1))},N_=z_.getInterval=function(t,e){var n=t.get("interval");return(null==n||"auto"==n)&&(n=e),n},F_=f,G_=x,V_=kl({type:"axis",_axisPointer:null,axisPointerClass:null,render:function(t,e,n,i){this.axisPointerClass&&yu(t),V_.superApply(this,"render",arguments),Su(this,t,e,n,i,!0)},updateAxisPointer:function(t,e,n,i){Su(this,t,e,n,i,!1)},remove:function(t,e){var n=this._axisPointer;n&&n.remove(e),V_.superApply(this,"remove",arguments)},dispose:function(t,e){Mu(this,e),V_.superApply(this,"dispose",arguments)}}),H_=[];V_.registerAxisPointerClass=function(t,e){H_[t]=e},V_.getAxisPointerClass=function(t){return t&&H_[t]};var W_=z_.ifIgnoreOnTick,X_=z_.getInterval,Z_=["axisLine","axisTickLabel","axisName"],U_=["splitArea","splitLine"],Y_=V_.extend({type:"cartesianAxis",axisPointerClass:"CartesianAxisPointer",render:function(t,e,n,i){this.group.removeAll();var r=this._axisGroup;if(this._axisGroup=new hp,this.group.add(this._axisGroup),t.get("show")){var a=t.getCoordSysModel(),o=Iu(a,t),s=new z_(t,o);f(Z_,s.add,s),this._axisGroup.add(s.getGroup()),f(U_,function(e){t.get(e+".show")&&this["_"+e](t,a,o.labelInterval)},this),Ta(r,this._axisGroup,t),Y_.superCall(this,"render",t,e,n,i)}},_splitLine:function(t,e,n){var i=t.axis;if(!i.scale.isBlank()){var r=t.getModel("splitLine"),a=r.getModel("lineStyle"),o=a.get("color"),l=X_(r,n);o=_(o)?o:[o];for(var h=e.coordinateSystem.getRect(),u=i.isHorizontal(),c=0,d=i.getTicksCoords(),f=i.scale.getTicks(),p=t.get("axisLabel.showMinLabel"),g=t.get("axisLabel.showMaxLabel"),m=[],v=[],y=a.getLineStyle(),x=0;x0&&Bu(n[r-1]);r--);for(;r>i&&Bu(n[i]);i++);}for(;r>i;)i+=Eu(t,n,i,r,r,1,a.min,a.max,e.smooth,e.smoothMonotone,e.connectNulls)+1}}),hw=Pr.extend({type:"ec-polygon",shape:{points:[],stackedOnPoints:[],smooth:0,stackedOnSmooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},brush:Mm(Pr.prototype.brush),buildPath:function(t,e){var n=e.points,i=e.stackedOnPoints,r=0,a=n.length,o=e.smoothMonotone,s=Nu(n,e.smoothConstraint),l=Nu(i,e.smoothConstraint);if(e.connectNulls){for(;a>0&&Bu(n[a-1]);a--);for(;a>r&&Bu(n[r]);r++);}for(;a>r;){var h=Eu(t,n,r,a,a,1,s.min,s.max,e.smooth,o,e.connectNulls);Eu(t,i,r+h-1,h,a,-1,l.min,l.max,e.stackedOnSmooth,o,e.connectNulls),r+=h+1,t.closePath()}}});_s.extend({type:"line",init:function(){var t=new hp,e=new ku;this.group.add(e.group),this._symbolDraw=e,this._lineGroup=t},render:function(t,e,n){var i=t.coordinateSystem,r=this.group,a=t.getData(),o=t.getModel("lineStyle"),l=t.getModel("areaStyle"),h=a.mapArray(a.getItemLayout,!0),u="polar"===i.type,c=this._coordSys,d=this._symbolDraw,f=this._polyline,p=this._polygon,g=this._lineGroup,m=t.get("animation"),v=!l.isEmpty(),y=l.get("origin"),x=Wu(t,i,a,y),_=t.get("showSymbol"),w=_&&!u&&!t.get("showAllSymbol")&&this._getSymbolIgnoreFunc(a,i),b=this._data;b&&b.eachItemGraphicEl(function(t,e){t.__temp&&(r.remove(t),b.setItemGraphicEl(e,null))}),_||d.remove(),r.add(g);var S=!u&&t.get("step");f&&c.type===i.type&&S===this._step?(v&&!p?p=this._newPolygon(h,x,i,m):p&&!v&&(g.remove(p),p=this._polygon=null),g.setClipPath(Uu(i,!1,t)),_&&d.updateData(a,w),a.eachItemGraphicEl(function(t){t.stopAnimation(!0)}),Fu(this._stackedOnPoints,x)&&Fu(this._points,h)||(m?this._updateAnimation(a,x,i,n,S):(S&&(h=Yu(h,i,S),x=Yu(x,i,S)),f.setShape({points:h}),p&&p.setShape({points:h,stackedOnPoints:x})))):(_&&d.updateData(a,w),S&&(h=Yu(h,i,S),x=Yu(x,i,S)),f=this._newPolyline(h,i,m),v&&(p=this._newPolygon(h,x,i,m)),g.setClipPath(Uu(i,!0,t)));var M=ju(a,i)||a.getVisual("color");f.useStyle(s(o.getLineStyle(),{fill:"none",stroke:M,lineJoin:"bevel"}));var I=t.get("smooth");if(I=Gu(t.get("smooth")),f.setShape({smooth:I,smoothMonotone:t.get("smoothMonotone"),connectNulls:t.get("connectNulls")}),p){var T=a.stackedOn,C=0;if(p.useStyle(s(l.getAreaStyle(),{fill:M,opacity:.7,lineJoin:"bevel"})),T){var D=T.hostModel;C=Gu(D.get("smooth"))}p.setShape({smooth:I,stackedOnSmooth:C,smoothMonotone:t.get("smoothMonotone"),connectNulls:t.get("connectNulls")})}this._data=a,this._coordSys=i,this._stackedOnPoints=x,this._points=h,this._step=S},dispose:function(){},highlight:function(t,e,n,i){var r=t.getData(),a=Fi(r,i);if(!(a instanceof Array)&&null!=a&&a>=0){var o=r.getItemGraphicEl(a);if(!o){var s=r.getItemLayout(a);if(!s)return;o=new Du(r,a),o.position=s,o.setZ(t.get("zlevel"),t.get("z")),o.ignore=isNaN(s[0])||isNaN(s[1]),o.__temp=!0,r.setItemGraphicEl(a,o),o.stopSymbolAnimation(!0),this.group.add(o)}o.highlight()}else _s.prototype.highlight.call(this,t,e,n,i)},downplay:function(t,e,n,i){var r=t.getData(),a=Fi(r,i);if(null!=a&&a>=0){var o=r.getItemGraphicEl(a);o&&(o.__temp?(r.setItemGraphicEl(a,null),this.group.remove(o)):o.downplay())}else _s.prototype.downplay.call(this,t,e,n,i)},_newPolyline:function(t){var e=this._polyline;return e&&this._lineGroup.remove(e),e=new lw({shape:{points:t},silent:!0,z2:10}),this._lineGroup.add(e),this._polyline=e,e},_newPolygon:function(t,e){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new hw({shape:{points:t,stackedOnPoints:e},silent:!0}),this._lineGroup.add(n),this._polygon=n,n},_getSymbolIgnoreFunc:function(t,e){var n=e.getAxesByScale("ordinal")[0];return n&&n.isLabelIgnored?y(n.isLabelIgnored,n):void 0},_updateAnimation:function(t,e,n,i,r){var a=this._polyline,o=this._polygon,s=t.hostModel,l=tw(this._data,t,this._stackedOnPoints,e,this._coordSys,n),h=l.current,u=l.stackedOnCurrent,c=l.next,d=l.stackedOnNext;r&&(h=Yu(l.current,n,r),u=Yu(l.stackedOnCurrent,n,r),c=Yu(l.next,n,r),d=Yu(l.stackedOnNext,n,r)),a.shape.__points=l.current,a.shape.points=h,wa(a,{shape:{points:c}},s),o&&(o.setShape({points:h,stackedOnPoints:u}),wa(o,{shape:{points:c,stackedOnPoints:d}},s));for(var f=[],p=l.status,g=0;ge&&(e=t[n]);return e},min:function(t){for(var e=1/0,n=0;n1){var h;"string"==typeof n?h=dw[n]:"function"==typeof n&&(h=n),h&&t.setData(e.downSample(a.dim,1/l,h,fw))}}}}};Tl(uw("line","circle","line")),Il(cw("line")),_l(Wy.PROCESSOR.STATISTIC,pw("line"));var gw=function(t,e,n){e=_(e)&&{coordDimensions:e}||o({},e);var i=t.getSource(),r=Mx(i,e),a=new _x(r,t);return a.initData(i,n),a},mw={updateSelectedMap:function(t){if(_(t))this._targetList=t.slice();else for(var e=t,n=e.mapDimension("value"),t=this._targetList=[],i=0,r=e.count();r>i;i++)t.push({name:e.getName(i),value:e.get(n,i)});this._selectTargetMap=g(t||[],function(t,e){return t.set(e.name,e),t},N())},select:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t),i=this.get("selectedMode");"single"===i&&this._selectTargetMap.each(function(t){t.selected=!1}),n&&(n.selected=!0)},unSelect:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);n&&(n.selected=!1)},toggleSelected:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);return null!=n?(this[n.selected?"unSelect":"select"](t,e),n.selected):void 0},isSelected:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);return n&&n.selected}},vw=Pl({type:"series.pie",init:function(t){vw.superApply(this,"init",arguments),this.legendDataProvider=function(){return this.getRawData()},this.updateSelectedMap(this.getRawData()),this._defaultLabelLine(t)},mergeOption:function(t){vw.superCall(this,"mergeOption",t),this.updateSelectedMap(this.getRawData())},getInitialData:function(){return gw(this,["value"])},getDataParams:function(t){var e=this.getData(),n=vw.superCall(this,"getDataParams",t),i=[];return e.each(e.mapDimension("value"),function(t){i.push(t)}),n.percent=Xa(i,t,e.hostModel.get("percentPrecision")),n.$vars.push("percent"),n},_defaultLabelLine:function(t){Oi(t,"labelLine",["show"]);var e=t.labelLine,n=t.emphasis.labelLine;e.show=e.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},defaultOption:{zlevel:0,z:2,legendHoverLink:!0,hoverAnimation:!0,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,selectedOffset:10,hoverOffset:10,avoidLabelOverlap:!0,percentPrecision:2,stillShowZeroSum:!0,label:{rotate:!1,show:!0,position:"outer"},labelLine:{show:!0,length:15,length2:15,smooth:!1,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1},animationType:"expansion",animationEasing:"cubicOut"}});c(vw,mw);var yw=Ku.prototype;yw.updateData=function(t,e,n){function i(){a.stopAnimation(!0),a.animateTo({shape:{r:u.r+l.get("hoverOffset")}},300,"elasticOut")}function r(){a.stopAnimation(!0),a.animateTo({shape:{r:u.r}},300,"elasticOut")}var a=this.childAt(0),l=t.hostModel,h=t.getItemModel(e),u=t.getItemLayout(e),c=o({},u);if(c.label=null,n){a.setShape(c);var d=l.getShallow("animationType");"scale"===d?(a.shape.r=u.r0,ba(a,{shape:{r:u.r}},l,e)):(a.shape.endAngle=u.startAngle,wa(a,{shape:{endAngle:u.endAngle}},l,e))}else wa(a,{shape:c},l,e);var f=t.getItemVisual(e,"color");a.useStyle(s({lineJoin:"bevel",fill:f},h.getModel("itemStyle").getItemStyle())),a.hoverStyle=h.getModel("emphasis.itemStyle").getItemStyle();var p=h.getShallow("cursor");p&&a.attr("cursor",p),$u(this,t.getItemLayout(e),l.isSelected(null,e),l.get("selectedOffset"),l.get("animation")),a.off("mouseover").off("mouseout").off("emphasis").off("normal"),h.get("hoverAnimation")&&l.isAnimationEnabled()&&a.on("mouseover",i).on("mouseout",r).on("emphasis",i).on("normal",r),this._updateLabel(t,e),ha(this)},yw._updateLabel=function(t,e){var n=this.childAt(1),i=this.childAt(2),r=t.hostModel,a=t.getItemModel(e),o=t.getItemLayout(e),s=o.label,l=t.getItemVisual(e,"color");wa(n,{shape:{points:s.linePoints||[[s.x,s.y],[s.x,s.y],[s.x,s.y]]}},r,e),wa(i,{style:{x:s.x,y:s.y}},r,e),i.attr({rotation:s.rotation,origin:[s.x,s.y],z2:10});var h=a.getModel("label"),u=a.getModel("emphasis.label"),c=a.getModel("labelLine"),d=a.getModel("emphasis.labelLine"),l=t.getItemVisual(e,"color");ua(i.style,i.hoverStyle={},h,u,{labelFetcher:t.hostModel,labelDataIndex:e,defaultText:t.getName(e),autoColor:l,useInsideStyle:!!s.inside},{textAlign:s.textAlign,textVerticalAlign:s.verticalAlign,opacity:t.getItemVisual(e,"opacity")}),i.ignore=i.normalIgnore=!h.get("show"),i.hoverIgnore=!u.get("show"),n.ignore=n.normalIgnore=!c.get("show"),n.hoverIgnore=!d.get("show"),n.setStyle({stroke:l,opacity:t.getItemVisual(e,"opacity")}),n.setStyle(c.getModel("lineStyle").getLineStyle()),n.hoverStyle=d.getModel("lineStyle").getLineStyle();var f=c.get("smooth");f&&f===!0&&(f=.4),n.setShape({smooth:f})},u(Ku,hp);var xw=(_s.extend({type:"pie",init:function(){var t=new hp;this._sectorGroup=t},render:function(t,e,n,i){if(!i||i.from!==this.uid){var r=t.getData(),a=this._data,o=this.group,s=e.get("animation"),l=!a,h=t.get("animationType"),u=x(qu,this.uid,t,s,n),c=t.get("selectedMode");if(r.diff(a).add(function(t){var e=new Ku(r,t);l&&"scale"!==h&&e.eachChild(function(t){t.stopAnimation(!0)}),c&&e.on("click",u),r.setItemGraphicEl(t,e),o.add(e)}).update(function(t,e){var n=a.getItemGraphicEl(e);n.updateData(r,t),n.off("click"),c&&n.on("click",u),o.add(n),r.setItemGraphicEl(t,n)}).remove(function(t){var e=a.getItemGraphicEl(t);o.remove(e)}).execute(),s&&l&&r.count()>0&&"scale"!==h){var d=r.getItemLayout(0),f=Math.max(n.getWidth(),n.getHeight())/2,p=y(o.removeClipPath,o);o.setClipPath(this._createClipPath(d.cx,d.cy,f,d.startAngle,d.clockwise,p,t))}this._data=r}},dispose:function(){},_createClipPath:function(t,e,n,i,r,a,o){var s=new Im({shape:{cx:t,cy:e,r0:0,r:n,startAngle:i,endAngle:i,clockwise:r}});return ba(s,{shape:{endAngle:i+(r?1:-1)*Math.PI*2}},o,a),s},containPoint:function(t,e){var n=e.getData(),i=n.getItemLayout(0);if(i){var r=t[0]-i.cx,a=t[1]-i.cy,o=Math.sqrt(r*r+a*a);return o<=i.r&&o>=i.r0}}}),function(t,e){f(e,function(e){e.update="updateView",bl(e,function(n,i){var r={};return i.eachComponent({mainType:"series",subType:t,query:n},function(t){t[e.method]&&t[e.method](n.name,n.dataIndex);var i=t.getData();i.each(function(e){var n=i.getName(e);r[n]=t.isSelected(n)||!1})}),{name:n.name,selected:r}})})}),_w=function(t){return{getTargetSeries:function(e){var n={},i=N();return e.eachSeriesByType(t,function(t){t.__paletteScope=n,i.set(t.uid,t)}),i},reset:function(t){var e=t.getRawData(),n={},i=t.getData();i.each(function(t){var e=i.getRawIndex(t);n[e]=t}),e.each(function(r){var a=n[r],o=null!=a&&i.getItemVisual(a,"color",!0);if(o)e.setItemVisual(r,"color",o);else{var s=e.getItemModel(r),l=s.get("itemStyle.color")||t.getColorFromPalette(e.getName(r),t.__paletteScope,e.count());e.setItemVisual(r,"color",l),null!=a&&i.setItemVisual(a,"color",l)}})}}},ww=function(t,e,n,i){var r,a,o=t.getData(),s=[],l=!1;o.each(function(n){var i,h,u,c,d=o.getItemLayout(n),f=o.getItemModel(n),p=f.getModel("label"),g=p.get("position")||f.get("emphasis.label.position"),m=f.getModel("labelLine"),v=m.get("length"),y=m.get("length2"),x=(d.startAngle+d.endAngle)/2,_=Math.cos(x),w=Math.sin(x);r=d.cx,a=d.cy;var b="inside"===g||"inner"===g;if("center"===g)i=d.cx,h=d.cy,c="center";else{var S=(b?(d.r+d.r0)/2*_:d.r*_)+r,M=(b?(d.r+d.r0)/2*w:d.r*w)+a;if(i=S+3*_,h=M+3*w,!b){var I=S+_*(v+e-d.r),T=M+w*(v+e-d.r),C=I+(0>_?-1:1)*y,D=T;i=C+(0>_?-5:5),h=D,u=[[S,M],[I,T],[C,D]]}c=b?"center":_>0?"left":"right"}var A=p.getFont(),k=p.get("rotate")?0>_?-x+Math.PI:-x:0,P=t.getFormattedLabel(n,"normal")||o.getName(n),L=Sn(P,A,c,"top");l=!!k,d.label={x:i,y:h,position:g,height:L.height,len:v,len2:y,linePoints:u,textAlign:c,verticalAlign:"middle",rotation:k,inside:b},b||s.push(d.label)}),!l&&t.get("avoidLabelOverlap")&&Qu(s,r,a,e,n,i)},bw=2*Math.PI,Sw=Math.PI/180,Mw=function(t,e,n){e.eachSeriesByType(t,function(t){var e=t.getData(),i=e.mapDimension("value"),r=t.get("center"),a=t.get("radius");_(a)||(a=[0,a]),_(r)||(r=[r,r]);var o=n.getWidth(),s=n.getHeight(),l=Math.min(o,s),h=Na(r[0],o),u=Na(r[1],s),c=Na(a[0],l/2),d=Na(a[1],l/2),f=-t.get("startAngle")*Sw,p=t.get("minAngle")*Sw,g=0;e.each(i,function(t){!isNaN(t)&&g++});var m=e.getSum(i),v=Math.PI/(m||g)*2,y=t.get("clockwise"),x=t.get("roseType"),w=t.get("stillShowZeroSum"),b=e.getDataExtent(i);b[0]=0;var S=bw,M=0,I=f,T=y?1:-1;if(e.each(i,function(t,n){var i;if(isNaN(t))return void e.setItemLayout(n,{angle:0/0,startAngle:0/0,endAngle:0/0,clockwise:y,cx:h,cy:u,r0:c,r:x?0/0:d});i="area"!==x?0===m&&w?v:t*v:bw/g,p>i?(i=p,S-=p):M+=t;var r=I+T*i;e.setItemLayout(n,{angle:i,startAngle:I,endAngle:r,clockwise:y,cx:h,cy:u,r0:c,r:x?Ea(t,b,[c,d]):d}),I=r},!0),bw>S&&g)if(.001>=S){var C=bw/g;e.each(i,function(t,n){if(!isNaN(t)){var i=e.getItemLayout(n);i.angle=C,i.startAngle=f+T*n*C,i.endAngle=f+T*(n+1)*C}})}else v=S/M,I=f,e.each(i,function(t,n){if(!isNaN(t)){var i=e.getItemLayout(n),r=i.angle===p?p:t*v;i.startAngle=I,i.endAngle=I+T*r,I+=T*r}});ww(t,d,o,s)})},Iw=function(t){return{seriesType:t,reset:function(t,e){var n=e.findComponents({mainType:"legend"});if(n&&n.length){var i=t.getData();i.filterSelf(function(t){for(var e=i.getName(t),r=0;r=0;s--){var l=2*s,h=i[l]-a/2,u=i[l+1]-o/2;if(t>=h&&e>=u&&h+a>=t&&u+o>=e)return s}return-1}}),Dw=tc.prototype;Dw.isPersistent=function(){return!this._incremental},Dw.updateData=function(t){this.group.removeAll();var e=new Cw({rectHover:!0,cursor:"default"});e.setShape({points:t.getLayout("symbolPoints")}),this._setCommon(e,t),this.group.add(e),this._incremental=null},Dw.updateLayout=function(t){if(!this._incremental){var e=t.getLayout("symbolPoints");this.group.eachChild(function(t){if(null!=t.startIndex){var n=2*(t.endIndex-t.startIndex),i=4*t.startIndex*2;e=new Float32Array(e.buffer,i,n)}t.setShape("points",e)})}},Dw.incrementalPrepareUpdate=function(t){this.group.removeAll(),this._clearIncremental(),t.count()>2e6?(this._incremental||(this._incremental=new Vr({silent:!0})),this.group.add(this._incremental)):this._incremental=null},Dw.incrementalUpdate=function(t,e){var n;this._incremental?(n=new Cw,this._incremental.addDisplayable(n,!0)):(n=new Cw({rectHover:!0,cursor:"default",startIndex:t.start,endIndex:t.end}),n.incremental=!0,this.group.add(n)),n.setShape({points:e.getLayout("symbolPoints")}),this._setCommon(n,e,!!this._incremental)},Dw._setCommon=function(t,e,n){var i=e.hostModel,r=e.getVisual("symbolSize");t.setShape("size",r instanceof Array?r:[r,r]),t.symbolProxy=Dh(e.getVisual("symbol"),0,0,0,0),t.setColor=t.symbolProxy.setColor;var a=t.shape.size[0]=0&&(t.dataIndex=n+(t.startIndex||0))}))},Dw.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},Dw._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()},Ll({type:"scatter",render:function(t){var e=t.getData(),n=this._updateSymbolDraw(e,t);n.updateData(e),this._finished=!0},incrementalPrepareRender:function(t){var e=t.getData(),n=this._updateSymbolDraw(e,t);n.incrementalPrepareUpdate(e),this._finished=!1},incrementalRender:function(t,e){this._symbolDraw.incrementalUpdate(t,e.getData()),this._finished=t.end===e.getData().count()},updateTransform:function(t){var e=t.getData();if(this.group.dirty(),!this._finished||e.count()>1e4||!this._symbolDraw.isPersistent())return{update:!0};var n=cw().reset(t);n.progress&&n.progress({start:0,end:e.count()},e),this._symbolDraw.updateLayout(e)},_updateSymbolDraw:function(t,e){var n=this._symbolDraw,i=e.pipelineContext,r=i.large;return n&&r===this._isLargeDraw||(n&&n.remove(),n=this._symbolDraw=r?new tc:new ku,this._isLargeDraw=r,this.group.removeAll()),this.group.add(n.group),n},remove:function(){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},dispose:function(){}}),Tl(uw("scatter","circle")),Il(cw("scatter")),u(ec,c_),nc.prototype.getIndicatorAxes=function(){return this._indicatorAxes},nc.prototype.dataToPoint=function(t,e){var n=this._indicatorAxes[e];return this.coordToPoint(n.dataToCoord(t),e)},nc.prototype.coordToPoint=function(t,e){var n=this._indicatorAxes[e],i=n.angle,r=this.cx+t*Math.cos(i),a=this.cy-t*Math.sin(i);return[r,a]},nc.prototype.pointToData=function(t){var e=t[0]-this.cx,n=t[1]-this.cy,i=Math.sqrt(e*e+n*n);e/=i,n/=i;for(var r,a=Math.atan2(-n,e),o=1/0,s=-1,l=0;lu&&(r=h,s=l,o=u)}return[s,+(r&&r.coodToData(i))]},nc.prototype.resize=function(t,e){var n=t.get("center"),i=e.getWidth(),r=e.getHeight(),a=Math.min(i,r)/2;this.cx=Na(n[0],i),this.cy=Na(n[1],r),this.startAngle=t.get("startAngle")*Math.PI/180,this.r=Na(t.get("radius"),a),f(this._indicatorAxes,function(t,e){t.setExtent(0,this.r);var n=this.startAngle+e*Math.PI*2/this._indicatorAxes.length;n=Math.atan2(Math.sin(n),Math.cos(n)),t.angle=n},this)},nc.prototype.update=function(t){function e(t){var e=Math.pow(10,Math.floor(Math.log(t)/Math.LN10)),n=t/e;return 2===n?n=5:n*=2,n*e}var n=this._indicatorAxes,i=this._model;f(n,function(t){t.scale.setExtent(1/0,-1/0)}),t.eachSeriesByType("radar",function(e){if("radar"===e.get("coordinateSystem")&&t.getComponent("radar",e.get("radarIndex"))===i){var r=e.getData();f(n,function(t){t.scale.unionExtentFromData(r,r.mapDimension(t.dim))})}},this);var r=i.get("splitNumber");f(n,function(t){var n=xh(t.scale,t.model);wh(t.scale,t.model);var i=t.model,a=t.scale,o=i.getMin(),s=i.getMax(),l=a.getInterval();if(null!=o&&null!=s)a.setExtent(+o,+s),a.setInterval((s-o)/r);else if(null!=o){var h;do h=o+l*r,a.setExtent(+o,h),a.setInterval(l),l=e(l);while(hn[0]&&isFinite(u)&&isFinite(n[0]))}else{var c=a.getTicks().length-1;c>r&&(l=e(l));var d=Math.round((n[0]+n[1])/2/l)*l,f=Math.round(r/2);a.setExtent(Fa(d-f*l),Fa(d+(r-f)*l)),a.setInterval(l)}})},nc.dimensions=[],nc.create=function(t,e){var n=[];return t.eachComponent("radar",function(i){var r=new nc(i,t,e);n.push(r),i.coordinateSystem=r}),t.eachSeriesByType("radar",function(t){"radar"===t.get("coordinateSystem")&&(t.coordinateSystem=n[t.get("radarIndex")||0])}),n},Eo.register("radar",nc);var Aw=v_.valueAxis,kw=(Al({type:"radar",optionUpdated:function(){var t=this.get("boundaryGap"),e=this.get("splitNumber"),n=this.get("scale"),a=this.get("axisLine"),l=this.get("axisTick"),h=this.get("axisLabel"),u=this.get("name"),c=this.get("name.show"),d=this.get("name.formatter"),f=this.get("nameGap"),g=this.get("triggerEvent"),m=p(this.get("indicator")||[],function(p){null!=p.max&&p.max>0&&!p.min?p.min=0:null!=p.min&&p.min<0&&!p.max&&(p.max=0);var m=u;if(null!=p.color&&(m=s({color:p.color},u)),p=r(i(p),{boundaryGap:t,splitNumber:e,scale:n,axisLine:a,axisTick:l,axisLabel:h,name:p.text,nameLocation:"end",nameGap:f,nameTextStyle:m,triggerEvent:g},!1),c||(p.name=""),"string"==typeof d){var v=p.name;p.name=d.replace("{value}",null!=v?v:"")}else"function"==typeof d&&(p.name=d(p.name,p));var y=o(new ka(p,null,this.ecModel),Kx);return y.mainType="radar",y.componentIndex=this.componentIndex,y},this);this.getIndicatorModels=function(){return m}},defaultOption:{zlevel:0,z:0,center:["50%","50%"],radius:"75%",startAngle:90,name:{show:!0},boundaryGap:[0,0],splitNumber:5,nameGap:15,scale:!1,shape:"polygon",axisLine:r({lineStyle:{color:"#bbb"}},Aw.axisLine),axisLabel:ic(Aw.axisLabel,!1),axisTick:ic(Aw.axisTick,!1),splitLine:ic(Aw.splitLine,!0),splitArea:ic(Aw.splitArea,!0),indicator:[]}}),["axisLine","axisTickLabel","axisName"]);kl({type:"radar",render:function(t){var e=this.group;e.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},_buildAxes:function(t){var e=t.coordinateSystem,n=e.getIndicatorAxes(),i=p(n,function(t){var n=new z_(t.model,{position:[e.cx,e.cy],rotation:t.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return n});f(i,function(t){f(kw,t.add,t),this.group.add(t.getGroup())},this)},_buildSplitLineAndArea:function(t){function e(t,e,n){var i=n%e.length;return t[i]=t[i]||[],i}var n=t.coordinateSystem,i=n.getIndicatorAxes();if(i.length){var r=t.get("shape"),a=t.getModel("splitLine"),o=t.getModel("splitArea"),l=a.getModel("lineStyle"),h=o.getModel("areaStyle"),u=a.get("show"),c=o.get("show"),d=l.get("color"),g=h.get("color");d=_(d)?d:[d],g=_(g)?g:[g];var m=[],v=[];if("circle"===r)for(var y=i[0].getTicksCoords(),x=n.cx,w=n.cy,b=0;b=b;b++){for(var C=[],D=0;D"+p(i,function(n){var i=e.get(e.mapDimension(n.dim),t);return eo(n.name+" : "+i)}).join("
")},defaultOption:{zlevel:0,z:2,coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid"},label:{position:"top"},symbol:"emptyCircle",symbolSize:4}});Ll({type:"radar",render:function(t){function e(t,e){var n=t.getItemVisual(e,"symbol")||"circle",i=t.getItemVisual(e,"color");if("none"!==n){var r=rc(t.getItemVisual(e,"symbolSize")),a=Dh(n,-1,-1,2,2,i);return a.attr({style:{strokeNoScale:!0},z2:100,scale:[r[0]/2,r[1]/2]}),a}}function n(n,i,r,a,o,s){r.removeAll();for(var l=0;lf;++f){var p=t[f],g=p[0],m=p[1],v=p[2],y=i(v);c.globalAlpha=y,c.drawImage(o,g-h,m-h)}if(!u.width||!u.height)return u;for(var x=c.getImageData(0,0,u.width,u.height),_=x.data,w=0,b=_.length,S=this.minOpacity,M=this.maxOpacity,I=M-S;b>w;){var y=_[w+3]/256,T=4*Math.floor(y*(zw-1));if(y>0){var C=a(y)?s:l;y>0&&(y=y*I+S),_[w++]=C[T],_[w++]=C[T+1],_[w++]=C[T+2],_[w++]=C[T+3]*y*256}else w+=4}return c.putImageData(x,0,0),u},_getBrush:function(){var t=this._brushCanvas||(this._brushCanvas=vf()),e=this.pointSize+this.blurSize,n=2*e;t.width=n,t.height=n;var i=t.getContext("2d");return i.clearRect(0,0,n,n),i.shadowOffsetX=n,i.shadowBlur=this.blurSize,i.shadowColor="#000",i.beginPath(),i.arc(-e,e,this.pointSize,0,2*Math.PI,!0),i.closePath(),i.fill(),t},_getGradient:function(t,e,n){for(var i=this._gradientPixels,r=i[n]||(i[n]=new Uint8ClampedArray(1024)),a=[0,0,0,0],o=0,s=0;256>s;s++)e[n](s/255,!0,a),r[o++]=a[0],r[o++]=a[1],r[o++]=a[2],r[o++]=a[3];return r}},Ll({type:"heatmap",render:function(t,e,n){var i;e.eachComponent("visualMap",function(e){e.eachTargetSeries(function(n){n===t&&(i=e)})}),this.group.removeAll(),this._incrementalDisplayable=null;var r=t.coordinateSystem;"cartesian2d"===r.type||"calendar"===r.type?this._renderOnCartesianAndCalendar(t,n,0,t.getData().count()):lc(r)&&this._renderOnGeo(r,t,i,n)},incrementalPrepareRender:function(){this.group.removeAll()},incrementalRender:function(t,e,n,i){var r=e.coordinateSystem;r&&this._renderOnCartesianAndCalendar(e,i,t.start,t.end,!0)},_renderOnCartesianAndCalendar:function(t,e,n,i,r){var a,s,l=t.coordinateSystem;if("cartesian2d"===l.type){var h=l.getAxis("x"),u=l.getAxis("y");a=h.getBandWidth(),s=u.getBandWidth()}for(var c=this.group,d=t.getData(),f="itemStyle",p="emphasis.itemStyle",g="label",m="emphasis.label",v=t.getModel(f).getItemStyle(["color"]),y=t.getModel(p).getItemStyle(),x=t.getModel(g),_=t.getModel(m),w=l.type,b="cartesian2d"===w?[d.mapDimension("x"),d.mapDimension("y"),d.mapDimension("value")]:[d.mapDimension("time"),d.mapDimension("value")],S=n;i>S;S++){var M;if("cartesian2d"===w){if(isNaN(d.get(b[2],S)))continue;var I=l.dataToPoint([d.get(b[0],S),d.get(b[1],S)]);M=new Pm({shape:{x:I[0]-a/2,y:I[1]-s/2,width:a,height:s},style:{fill:d.getItemVisual(S,"color"),opacity:d.getItemVisual(S,"opacity")}})}else{if(isNaN(d.get(b[1],S)))continue;M=new Pm({z2:1,shape:l.dataToRect([d.get(b[0],S)]).contentShape,style:{fill:d.getItemVisual(S,"color"),opacity:d.getItemVisual(S,"opacity")}})}var T=d.getItemModel(S);d.hasItemOption&&(v=T.getModel(f).getItemStyle(["color"]),y=T.getModel(p).getItemStyle(),x=T.getModel(g),_=T.getModel(m));var C=t.getRawValue(S),D="-";C&&null!=C[2]&&(D=C[2]),ua(v,y,x,_,{labelFetcher:t,labelDataIndex:S,defaultText:D,isRectText:!0}),M.setStyle(v),ha(M,d.hasItemOption?y:o({},y)),M.incremental=r,r&&(M.useHoverLayer=!0),c.add(M),d.setItemGraphicEl(S,M)}},_renderOnGeo:function(t,e,n,i){var r=n.targetVisuals.inRange,a=n.targetVisuals.outOfRange,o=e.getData(),s=this._hmLayer||this._hmLayer||new ac;s.blurSize=e.get("blurSize"),s.pointSize=e.get("pointSize"),s.minOpacity=e.get("minOpacity"),s.maxOpacity=e.get("maxOpacity");var l=t.getViewRect().clone(),h=t.getRoamTransform();l.applyTransform(h);var u=Math.max(l.x,0),c=Math.max(l.y,0),d=Math.min(l.width+l.x,i.getWidth()),f=Math.min(l.height+l.y,i.getHeight()),p=d-u,g=f-c,m=[o.mapDimension("lng"),o.mapDimension("lat"),o.mapDimension("value")],v=o.mapArray(m,function(e,n,i){var r=t.dataToPoint([e,n]);return r[0]-=u,r[1]-=c,r.push(i),r}),y=n.getExtent(),x="visualMap.continuous"===n.type?sc(y,n.option.range):oc(y,n.getPieceList(),n.option.selected);s.update(v,p,g,r.color.getNormalizer(),{inRange:r.color.getColorMapper(),outOfRange:a.color.getColorMapper()},x);var _=new ai({style:{width:p,height:g,x:u,y:c,image:s.canvas},silent:!0});this.group.add(_)},dispose:function(){}});var Rw=ny.extend({type:"series.map",dependencies:["geo"],layoutMode:"box",needsDrawMap:!1,seriesGroup:[],init:function(t){this._fillOption(t,this.getMapType()),Rw.superApply(this,"init",arguments),this.updateSelectedMap(this.getRawData())},getInitialData:function(){return gw(this,["value"])},mergeOption:function(t){this._fillOption(t,this.getMapType()),Rw.superApply(this,"mergeOption",arguments),this.updateSelectedMap(this.getRawData())},getHostGeoModel:function(){var t=this.option.geoIndex;return null!=t?this.dependentModels.geo[t]:null},getMapType:function(){return(this.getHostGeoModel()||this).option.map},_fillOption:function(){},getRawValue:function(t){var e=this.getData();return e.get(e.mapDimension("value"),t)},getRegionModel:function(t){var e=this.getData();return e.getItemModel(e.indexOfName(t))},formatTooltip:function(t){for(var e=this.getData(),n=Qa(this.getRawValue(t)),i=e.getName(t),r=this.seriesGroup,a=[],o=0;o"+eo(i+" : "+n)},getTooltipPosition:function(t){if(null!=t){var e=this.getData().getName(t),n=this.coordinateSystem,i=n.getRegion(e);return i&&n.dataToPoint(i.center)}},setZoom:function(t){this.option.zoom=t},setCenter:function(t){this.option.center=t},defaultOption:{zlevel:0,z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:.75,showLegendSymbol:!0,dataRangeHoverLink:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}}}});c(Rw,mw);var Bw="\x00_ec_interaction_mutex";bl({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},function(){}),c(cc,Df);var Ew={axisPointer:1,tooltip:1,brush:1};Ic.prototype={constructor:Ic,draw:function(t,e,n,i,r){var a="geo"===t.mainType,o=t.getData&&t.getData();a&&e.eachComponent({mainType:"series",subType:"map"},function(e){o||e.getHostGeoModel()!==t||(o=e.getData())});var s=t.coordinateSystem,l=this.group,h=s.scale,u={position:s.position,scale:h};!l.childAt(0)||r?l.attr(u):wa(l,u,t),l.removeAll();var c=["itemStyle"],d=["emphasis","itemStyle"],p=["label"],g=["emphasis","label"],m=N();f(s.regions,function(e){var n=m.get(e.name)||m.set(e.name,new hp),i=new Bm({shape:{paths:[]}});n.add(i);var r,s=t.getRegionModel(e.name)||t,u=s.getModel(c),v=s.getModel(d),y=bc(u,h),x=bc(v,h),_=s.getModel(p),w=s.getModel(g);if(o){r=o.indexOfName(e.name);var b=o.getItemVisual(r,"color",!0);b&&(y.fill=b)}f(e.geometries,function(t){if("polygon"===t.type){i.shape.paths.push(new Am({shape:{points:t.exterior}}));for(var e=0;e<(t.interiors?t.interiors.length:0);e++)i.shape.paths.push(new Am({shape:{points:t.interiors[e]}}))}}),i.setStyle(y),i.style.strokeNoScale=!0,i.culling=!0;var S=_.get("show"),M=w.get("show"),I=o&&isNaN(o.get(o.mapDimension("value"),r)),T=o&&o.getItemLayout(r);if(a||I&&(S||M)||T&&T.showLabel){var C,D=a?e.name:r;(!o||r>=0)&&(C=t);var A=new wm({position:e.center.slice(),scale:[1/h[0],1/h[1]],z2:10,silent:!0});ua(A.style,A.hoverStyle={},_,w,{labelFetcher:C,labelDataIndex:D,defaultText:e.name,useInsideStyle:!1},{textAlign:"center",textVerticalAlign:"middle"}),n.add(A)}if(o)o.setItemGraphicEl(r,n);else{var s=t.getRegionModel(e.name);i.eventData={componentType:"geo",geoIndex:t.componentIndex,name:e.name,region:s&&s.option||{}}}var k=n.__regions||(n.__regions=[]);k.push(e),ha(n,x,{hoverSilentOnTouch:!!t.get("selectedMode")}),l.add(n)}),this._updateController(t,e,n),Sc(this,t,l,n,i),Mc(t,l)},remove:function(){this.group.removeAll(),this._controller.dispose(),this._controllerHost={}},_updateController:function(t,e,n){function i(){var e={type:"geoRoam",componentType:l};return e[l+"Id"]=t.id,e}var r=t.coordinateSystem,a=this._controller,s=this._controllerHost;s.zoomLimit=t.get("scaleLimit"),s.zoom=r.getZoom(),a.enable(t.get("roam")||!1);var l=t.mainType;a.off("pan").on("pan",function(t,e){this._mouseDownFlag=!1,xc(s,t,e),n.dispatchAction(o(i(),{dx:t,dy:e}))},this),a.off("zoom").on("zoom",function(t,e,r){if(this._mouseDownFlag=!1,_c(s,t,e,r),n.dispatchAction(o(i(),{zoom:t,originX:e,originY:r})),this._updateGroup){var a=this.group,l=a.scale;a.traverse(function(t){"text"===t.type&&t.attr("scale",[1/l[0],1/l[1]])})}},this),a.setPointerChecker(function(e,i,a){return r.getViewRectAfterRoam().contain(i,a)&&!wc(e,n,t)})}},Ll({type:"map",render:function(t,e,n,i){if(!i||"mapToggleSelect"!==i.type||i.from!==this.uid){var r=this.group;if(r.removeAll(),!t.getHostGeoModel()){if(i&&"geoRoam"===i.type&&"series"===i.componentType&&i.seriesId===t.id){var a=this._mapDraw;a&&r.add(a.group)}else if(t.needsDrawMap){var a=this._mapDraw||new Ic(n,!0);r.add(a.group),a.draw(t,e,n,this,i),this._mapDraw=a}else this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;t.get("showLegendSymbol")&&e.getComponent("legend")&&this._renderSymbols(t,e,n)}}},remove:function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null,this.group.removeAll()},dispose:function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},_renderSymbols:function(t){var e=t.originalData,n=this.group;e.each(e.mapDimension("value"),function(i,r){if(!isNaN(i)){var a=e.getItemLayout(r);if(a&&a.point){var o=a.point,s=a.offset,l=new bm({style:{fill:t.getData().getVisual("color")},shape:{cx:o[0]+9*s,cy:o[1],r:3},silent:!0,z2:s?8:10});if(!s){var h=t.mainSeries.getData(),u=e.getName(r),c=h.indexOfName(u),d=e.getItemModel(r),f=d.getModel("label"),p=d.getModel("emphasis.label"),g=h.getItemGraphicEl(c),m=A(t.getFormattedLabel(r,"normal"),u),v=A(t.getFormattedLabel(r,"emphasis"),m),y=function(){var t=ca({},p,{text:p.get("show")?v:null},{isRectText:!0,useInsideStyle:!1},!0);l.style.extendFrom(t),l.__mapOriginalZ2=l.z2,l.z2+=1},x=function(){ca(l.style,f,{text:f.get("show")?m:null,textPosition:f.getShallow("position")||"bottom"},{isRectText:!0,useInsideStyle:!1}),null!=l.__mapOriginalZ2&&(l.z2=l.__mapOriginalZ2,l.__mapOriginalZ2=null)};g.on("mouseover",y).on("mouseout",x).on("emphasis",y).on("normal",x),x()}n.add(l)}}})}}),bl({type:"geoRoam",event:"geoRoam",update:"updateTransform"},function(t,e){var n=t.componentType||"series";e.eachComponent({mainType:n,query:t},function(e){var i=e.coordinateSystem;if("geo"===i.type){var r=Tc(i,t,e.get("scaleLimit"));e.setCenter&&e.setCenter(r.center),e.setZoom&&e.setZoom(r.zoom),"series"===n&&f(e.seriesGroup,function(t){t.setCenter(r.center),t.setZoom(r.zoom)})}})});var Nw=ae;c(Cc,Bf),Dc.prototype={constructor:Dc,type:"view",dimensions:["x","y"],setBoundingRect:function(t,e,n,i){return this._rect=new rn(t,e,n,i),this._rect},getBoundingRect:function(){return this._rect},setViewRect:function(t,e,n,i){this.transformTo(t,e,n,i),this._viewRect=new rn(t,e,n,i)},transformTo:function(t,e,n,i){var r=this.getBoundingRect(),a=this._rawTransformable;a.transform=r.calculateTransform(new rn(t,e,n,i)),a.decomposeTransform(),this._updateTransform()},setCenter:function(t){t&&(this._center=t,this._updateCenterAndZoom())},setZoom:function(t){t=t||1;var e=this.zoomLimit;e&&(null!=e.max&&(t=Math.min(e.max,t)),null!=e.min&&(t=Math.max(e.min,t))),this._zoom=t,this._updateCenterAndZoom()},getDefaultCenter:function(){var t=this.getBoundingRect(),e=t.x+t.width/2,n=t.y+t.height/2;return[e,n]},getCenter:function(){return this._center||this.getDefaultCenter()},getZoom:function(){return this._zoom||1},getRoamTransform:function(){return this._roamTransformable.getLocalTransform()},_updateCenterAndZoom:function(){var t=this._rawTransformable.getLocalTransform(),e=this._roamTransformable,n=this.getDefaultCenter(),i=this.getCenter(),r=this.getZoom();i=ae([],i,t),n=ae([],n,t),e.origin=i,e.position=[n[0]-i[0],n[1]-i[1]],e.scale=[r,r],this._updateTransform()},_updateTransform:function(){var t=this._roamTransformable,e=this._rawTransformable;e.parent=t,t.updateTransform(),e.updateTransform(),ge(this.transform||(this.transform=[]),e.transform||fe()),this._rawTransform=e.getLocalTransform(),this.invTransform=this.invTransform||[],_e(this.invTransform,this.transform),this.decomposeTransform()},getViewRect:function(){return this._viewRect},getViewRectAfterRoam:function(){var t=this.getBoundingRect().clone();return t.applyTransform(this.transform),t},dataToPoint:function(t,e,n){var i=e?this._rawTransform:this.transform;return n=n||[],i?Nw(n,t,i):H(n,t)},pointToData:function(t){var e=this.invTransform;return e?Nw([],t,e):[t[0],t[1]]},convertToPixel:x(Ac,"dataToPoint"),convertFromPixel:x(Ac,"pointToData"),containPoint:function(t){return this.getViewRectAfterRoam().contain(t[0],t[1])}},c(Dc,Bf);for(var Fw=[126,25],Gw=[[[0,3.5],[7,11.2],[15,11.9],[30,7],[42,.7],[52,.7],[56,7.7],[59,.7],[64,.7],[64,0],[5,0],[0,3.5]],[[13,16.1],[19,14.7],[16,21.7],[11,23.1],[13,16.1]],[[12,32.2],[14,38.5],[15,38.5],[13,32.2],[12,32.2]],[[16,47.6],[12,53.2],[13,53.2],[18,47.6],[16,47.6]],[[6,64.4],[8,70],[9,70],[8,64.4],[6,64.4]],[[23,82.6],[29,79.8],[30,79.8],[25,82.6],[23,82.6]],[[37,70.7],[43,62.3],[44,62.3],[39,70.7],[37,70.7]],[[48,51.1],[51,45.5],[53,45.5],[50,51.1],[48,51.1]],[[51,35],[51,28.7],[53,28.7],[53,35],[51,35]],[[52,22.4],[55,17.5],[56,17.5],[53,22.4],[52,22.4]],[[58,12.6],[62,7],[63,7],[60,12.6],[58,12.6]],[[0,3.5],[0,93.1],[64,93.1],[64,0],[63,0],[63,92.4],[1,92.4],[1,3.5],[0,3.5]]],Vw=0;Vwe;++e)"台湾"===t.regions[e].name&&t.regions[e].geometries.push({type:"polygon",exterior:jw[0]})},$w=[Ww,Zw,Yw,qw];kc.prototype={constructor:kc,type:"geo",dimensions:["lng","lat"],containCoord:function(t){for(var e=this.regions,n=0;n=r/3?1:2),l=e.y-i(o)*a*(a>=r/3?1:2);o=e.angle-Math.PI/2,t.moveTo(s,l),t.lineTo(e.x+n(o)*a,e.y+i(o)*a),t.lineTo(e.x+n(e.angle)*r,e.y+i(e.angle)*r),t.lineTo(e.x-n(o)*a,e.y-i(o)*a),t.lineTo(s,l)}})),ib=2*Math.PI,rb=(_s.extend({type:"gauge",render:function(t,e,n){this.group.removeAll();var i=t.get("axisLine.lineStyle.color"),r=Rc(t,n);this._renderMain(t,e,n,i,r)},dispose:function(){},_renderMain:function(t,e,n,i,r){for(var a=this.group,o=t.getModel("axisLine"),s=o.getModel("lineStyle"),l=t.get("clockwise"),h=-t.get("startAngle")/180*Math.PI,u=-t.get("endAngle")/180*Math.PI,c=(u-h)%ib,d=h,f=s.get("width"),p=0;p=t)return i[0][1];for(var e=0;e=t&&(0===e?0:i[e-1][0])=I;I++){var T=Math.cos(_),C=Math.sin(_);if(f.get("show")){var D=new Lm({shape:{x1:T*u+l,y1:C*u+h,x2:T*(u-y)+l,y2:C*(u-y)+h},style:S,silent:!0});"auto"===S.stroke&&D.setStyle({stroke:i(I/m)}),s.add(D)}if(g.get("show")){var A=Bc(Fa(I/m*(d-c)+c),g.get("formatter")),k=g.get("distance"),P=i(I/m);s.add(new wm({style:ca({},g,{text:A,x:T*(u-y-k)+l,y:C*(u-y-k)+h,textVerticalAlign:-.4>C?"top":C>.4?"bottom":"middle",textAlign:-.4>T?"left":T>.4?"right":"center"},{autoColor:P}),silent:!0}))}if(p.get("show")&&I!==m){for(var L=0;v>=L;L++){var T=Math.cos(_),C=Math.sin(_),O=new Lm({shape:{x1:T*u+l,y1:C*u+h,x2:T*(u-x)+l,y2:C*(u-x)+h},silent:!0,style:M});"auto"===M.stroke&&O.setStyle({stroke:i((I+L/v)/m)}),s.add(O),_+=b}_-=b}else _+=w}},_renderPointer:function(t,e,n,i,r,a,o){var s=this.group,l=this._data;if(!t.get("pointer.show"))return void(l&&l.eachItemGraphicEl(function(t){s.remove(t)}));var h=[+t.get("min"),+t.get("max")],u=[a,o],c=t.getData(),d=c.mapDimension("value");c.diff(l).add(function(e){var n=new nb({shape:{angle:a}});ba(n,{shape:{angle:Ea(c.get(d,e),h,u,!0)}},t),s.add(n),c.setItemGraphicEl(e,n)}).update(function(e,n){var i=l.getItemGraphicEl(n);wa(i,{shape:{angle:Ea(c.get(d,e),h,u,!0)}},t),s.add(i),c.setItemGraphicEl(e,i)}).remove(function(t){var e=l.getItemGraphicEl(t);s.remove(e)}).execute(),c.eachItemGraphicEl(function(t,e){var n=c.getItemModel(e),a=n.getModel("pointer");t.setShape({x:r.cx,y:r.cy,width:Na(a.get("width"),r.r),r:Na(a.get("length"),r.r)}),t.useStyle(n.getModel("itemStyle").getItemStyle()),"auto"===t.style.fill&&t.setStyle("fill",i(Ea(c.get(d,e),h,[0,1],!0))),ha(t,n.getModel("emphasis.itemStyle").getItemStyle())}),this._data=c},_renderTitle:function(t,e,n,i,r){var a=t.getData(),o=a.mapDimension("value"),s=t.getModel("title");if(s.get("show")){var l=s.get("offsetCenter"),h=r.cx+Na(l[0],r.r),u=r.cy+Na(l[1],r.r),c=+t.get("min"),d=+t.get("max"),f=t.getData().get(o,0),p=i(Ea(f,[c,d],[0,1],!0));this.group.add(new wm({silent:!0,style:ca({},s,{x:h,y:u,text:a.getName(0),textAlign:"center",textVerticalAlign:"middle"},{autoColor:p,forceRich:!0})}))}},_renderDetail:function(t,e,n,i,r){var a=t.getModel("detail"),o=+t.get("min"),s=+t.get("max");if(a.get("show")){var l=a.get("offsetCenter"),h=r.cx+Na(l[0],r.r),u=r.cy+Na(l[1],r.r),c=Na(a.get("width"),r.r),d=Na(a.get("height"),r.r),f=t.getData(),p=f.get(f.mapDimension("value"),0),g=i(Ea(p,[o,s],[0,1],!0));this.group.add(new wm({silent:!0,style:ca({},a,{x:h,y:u,text:Bc(p,a.get("formatter")),textWidth:isNaN(c)?null:c,textHeight:isNaN(d)?null:d,textAlign:"center",textVerticalAlign:"middle"},{autoColor:g,forceRich:!0})}))}}}),C_.extend({type:"series.pictorialBar",dependencies:["grid"],defaultOption:{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",progressive:0,hoverAnimation:!1},getInitialData:function(t){return t.stack=null,rb.superApply(this,"getInitialData",arguments) +}})),ab=["itemStyle","borderWidth"],ob=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],sb=new bm;Ll({type:"pictorialBar",render:function(t,e,n){var i=this.group,r=t.getData(),a=this._data,o=t.coordinateSystem,s=o.getBaseAxis(),l=!!s.isHorizontal(),h=o.grid.getRect(),u={ecSize:{width:n.getWidth(),height:n.getHeight()},seriesModel:t,coordSys:o,coordSysExtent:[[h.x,h.x+h.width],[h.y,h.y+h.height]],isHorizontal:l,valueDim:ob[+l],categoryDim:ob[1-l]};return r.diff(a).add(function(t){if(r.hasValue(t)){var e=jc(r,t),n=Ec(r,t,e,u),a=Jc(r,u,n);r.setItemGraphicEl(t,a),i.add(a),rd(a,u,n)}}).update(function(t,e){var n=a.getItemGraphicEl(e);if(!r.hasValue(t))return void i.remove(n);var o=jc(r,t),s=Ec(r,t,o,u),l=ed(r,s);n&&l!==n.__pictorialShapeStr&&(i.remove(n),r.setItemGraphicEl(t,null),n=null),n?Qc(n,u,s):n=Jc(r,u,s,!0),r.setItemGraphicEl(t,n),n.__pictorialSymbolMeta=s,i.add(n),rd(n,u,s)}).remove(function(t){var e=a.getItemGraphicEl(t);e&&td(a,t,e.__pictorialSymbolMeta.animationModel,e)}).execute(),this._data=r,this.group},dispose:G,remove:function(t){var e=this.group,n=this._data;t.get("animation")?n&&n.eachItemGraphicEl(function(e){td(n,e.dataIndex,t,e)}):e.removeAll()}})}Il(x(vh,"pictorialBar")),Tl(uw("pictorialBar","roundRect")),Al({type:"title",layoutMode:{type:"box",ignoreSize:!0},defaultOption:{zlevel:0,z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bolder",color:"#333"},subtextStyle:{color:"#aaa"}}}),kl({type:"title",render:function(t,e,n){if(this.group.removeAll(),t.get("show")){var i=this.group,r=t.getModel("textStyle"),a=t.getModel("subtextStyle"),o=t.get("textAlign"),s=t.get("textBaseline"),l=new wm({style:ca({},r,{text:t.get("text"),textFill:r.getTextColor()},{disableBox:!0}),z2:10}),h=l.getBoundingRect(),u=t.get("subtext"),c=new wm({style:ca({},a,{text:u,textFill:a.getTextColor(),y:h.height+t.get("itemGap"),textVerticalAlign:"top"},{disableBox:!0}),z2:10}),d=t.get("link"),f=t.get("sublink");l.silent=!d,c.silent=!f,d&&l.on("click",function(){window.open(d,"_"+t.get("target"))}),f&&c.on("click",function(){window.open(f,"_"+t.get("subtarget"))}),i.add(l),u&&i.add(c);var p=i.getBoundingRect(),g=t.getBoxLayoutParams();g.width=p.width,g.height=p.height;var m=lo(g,{width:n.getWidth(),height:n.getHeight()},t.get("padding"));o||(o=t.get("left")||t.get("right"),"middle"===o&&(o="center"),"right"===o?m.x+=m.width:"center"===o&&(m.x+=m.width/2)),s||(s=t.get("top")||t.get("bottom"),"center"===s&&(s="middle"),"bottom"===s?m.y+=m.height:"middle"===s&&(m.y+=m.height/2),s=s||"top"),i.attr("position",[m.x,m.y]);var v={textAlign:o,textVerticalAlign:s};l.setStyle(v),c.setStyle(v),p=i.getBoundingRect();var y=m.margin,x=t.getItemStyle(["color","opacity"]);x.fill=t.get("backgroundColor");var _=new Pm({shape:{x:p.x-y[3],y:p.y-y[0],width:p.width+y[1]+y[3],height:p.height+y[0]+y[2],r:t.get("borderRadius")},style:x,silent:!0});qr(_),i.add(_)}}});var lb=Al({type:"legend.plain",dependencies:["series"],layoutMode:{type:"box",ignoreSize:!0},init:function(t,e,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{}},mergeOption:function(t){lb.superCall(this,"mergeOption",t)},optionUpdated:function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&"single"===this.get("selectedMode")){for(var e=!1,n=0;n=0},defaultOption:{zlevel:0,z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,inactiveColor:"#ccc",textStyle:{color:"#333"},selectedMode:!0,tooltip:{show:!1}}});bl("legendToggleSelect","legendselectchanged",x(od,"toggleSelected")),bl("legendSelect","legendselected",x(od,"select")),bl("legendUnSelect","legendunselected",x(od,"unSelect"));var hb=x,ub=f,cb=hp,db=kl({type:"legend.plain",newlineDisabled:!1,init:function(){this.group.add(this._contentGroup=new cb),this._backgroundEl},getContentGroup:function(){return this._contentGroup},render:function(t,e,n){if(this.resetInner(),t.get("show",!0)){var i=t.get("align");i&&"auto"!==i||(i="right"===t.get("left")&&"vertical"===t.get("orient")?"right":"left"),this.renderInner(i,t,e,n);var r=t.getBoxLayoutParams(),a={width:n.getWidth(),height:n.getHeight()},o=t.get("padding"),l=lo(r,a,o),h=this.layoutInner(t,i,l),u=lo(s({width:h.width,height:h.height},r),a,o);this.group.attr("position",[u.x-h.x,u.y-h.y]),this.group.add(this._backgroundEl=sd(h,t))}},resetInner:function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl)},renderInner:function(t,e,n,i){var r=this.getContentGroup(),a=N(),o=e.get("selectedMode");ub(e.getData(),function(s,l){var h=s.get("name");if(!this.newlineDisabled&&(""===h||"\n"===h))return void r.add(new cb({newline:!0}));var u=n.getSeriesByName(h)[0];if(!a.get(h))if(u){var c=u.getData(),d=c.getVisual("color");"function"==typeof d&&(d=d(u.getDataParams(0)));var f=c.getVisual("legendSymbol")||"roundRect",p=c.getVisual("symbol"),g=this._createItem(h,l,s,e,f,p,t,d,o);g.on("click",hb(ld,h,i)).on("mouseover",hb(hd,u,null,i)).on("mouseout",hb(ud,u,null,i)),a.set(h,!0)}else n.eachRawSeries(function(n){if(!a.get(h)&&n.legendDataProvider){var r=n.legendDataProvider(),u=r.indexOfName(h);if(0>u)return;var c=r.getItemVisual(u,"color"),d="roundRect",f=this._createItem(h,l,s,e,d,null,t,c,o);f.on("click",hb(ld,h,i)).on("mouseover",hb(hd,n,h,i)).on("mouseout",hb(ud,n,h,i)),a.set(h,!0)}},this)},this)},_createItem:function(t,e,n,i,r,a,s,l,h){var u=i.get("itemWidth"),c=i.get("itemHeight"),d=i.get("inactiveColor"),f=i.isSelected(t),p=new cb,g=n.getModel("textStyle"),m=n.get("icon"),v=n.getModel("tooltip"),y=v.parentModel;if(r=m||r,p.add(Dh(r,0,0,u,c,f?l:d,!0)),!m&&a&&(a!==r||"none"==a)){var x=.8*c;"none"===a&&(a="circle"),p.add(Dh(a,(u-x)/2,(c-x)/2,x,x,f?l:d))}var _="left"===s?u+5:-5,w=s,b=i.get("formatter"),S=t;"string"==typeof b&&b?S=b.replace("{name}",null!=t?t:""):"function"==typeof b&&(S=b(t)),p.add(new wm({style:ca({},g,{text:S,x:_,y:c/2,textFill:f?g.getTextColor():d,textAlign:w,textVerticalAlign:"middle"})}));var M=new Pm({shape:p.getBoundingRect(),invisible:!0,tooltip:v.get("show")?o({content:t,formatter:y.get("formatter",!0)||function(){return t},formatterParams:{componentType:"legend",legendIndex:i.componentIndex,name:t,$vars:["name"]}},v.option):null});return p.add(M),p.eachChild(function(t){t.silent=!0}),M.silent=!h,this.getContentGroup().add(p),ha(p),p.__legendDataIndex=e,p},layoutInner:function(t,e,n){var i=this.getContentGroup();pv(t.get("orient"),i,t.get("itemGap"),n.width,n.height);var r=i.getBoundingRect();return i.attr("position",[-r.x,-r.y]),this.group.getBoundingRect()}}),fb=function(t){var e=t.findComponents({mainType:"legend"});e&&e.length&&t.filterSeries(function(t){for(var n=0;nn[s],f=[-u.x,-u.y];f[o]=i.position[o];var p=[0,0],g=[-c.x,-c.y],m=A(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(d){var v=t.get("pageButtonPosition",!0);"end"===v?g[o]+=n[s]-c[s]:p[o]+=c[s]+m}g[1-o]+=u[l]/2-c[l]/2,i.attr("position",f),r.attr("position",p),a.attr("position",g);var y=this.group.getBoundingRect(),y={x:0,y:0};if(y[s]=d?n[s]:u[s],y[l]=Math.max(u[l],c[l]),y[h]=Math.min(0,c[h]+g[1-o]),r.__rectSize=n[s],d){var x={x:0,y:0};x[s]=Math.max(n[s]-c[s]-m,0),x[l]=y[l],r.setClipPath(new Pm({shape:x})),r.__rectSize=x[s]}else a.eachChild(function(t){t.attr({invisible:!0,silent:!0})});var _=this._getPageInfo(t);return null!=_.pageIndex&&wa(i,{position:_.contentPosition},d?t:!1),this._updatePageInfoView(t,_),y},_pageGo:function(t,e,n){var i=this._getPageInfo(e)[t];null!=i&&n.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:e.id})},_updatePageInfoView:function(t,e){var n=this._controllerGroup;f(["pagePrev","pageNext"],function(i){var r=null!=e[i+"DataIndex"],a=n.childOfName(i);a&&(a.setStyle("fill",r?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),a.cursor=r?"pointer":"default")});var i=n.childOfName("pageText"),r=t.get("pageFormatter"),a=e.pageIndex,o=null!=a?a+1:0,s=e.pageCount;i&&r&&i.setStyle("text",b(r)?r.replace("{current}",o).replace("{total}",s):r({current:o,total:s}))},_getPageInfo:function(t){function e(t){var e=t.getBoundingRect().clone();return e[f]+=t.position[u],e}var n,i,r,a,o=t.get("scrollDataIndex",!0),s=this.getContentGroup(),l=s.getBoundingRect(),h=this._containerGroup.__rectSize,u=t.getOrient().index,c=mb[u],d=mb[1-u],f=vb[u],p=s.position.slice();this._showController?s.eachChild(function(t){t.__legendDataIndex===o&&(a=t)}):a=s.childAt(0);var g=h?Math.ceil(l[c]/h):0;if(a){var m=a.getBoundingRect(),v=a.position[u]+m[f];p[u]=-v-l[f],n=Math.floor(g*(v+m[f]+h/2)/l[c]),n=l[c]&&g?Math.max(0,Math.min(g-1,n)):-1;var y={x:0,y:0};y[c]=h,y[d]=l[d],y[f]=-p[u]-l[f];var x,_=s.children();if(s.eachChild(function(t,n){var i=e(t);i.intersect(y)&&(null==x&&(x=n),r=t.__legendDataIndex),n===_.length-1&&i[f]+i[c]<=y[f]+y[c]&&(r=null)}),null!=x){var w=_[x],b=e(w);if(y[f]=b[f]+b[c]-y[c],0>=x&&b[f]>=y[f])i=null;else{for(;x>0&&e(_[x-1]).intersect(y);)x--;i=_[x].__legendDataIndex}}}return{contentPosition:p,pageIndex:n,pageCount:g,pagePrevDataIndex:i,pageNextDataIndex:r}}});bl("legendScroll","legendscroll",function(t,e){var n=t.scrollDataIndex;null!=n&&e.eachComponent({mainType:"legend",subType:"scroll",query:t},function(t){t.setScrollDataIndex(n)})});var xb=function(t,e){var n,i=[],r=t.seriesIndex;if(null==r||!(n=e.getSeriesByIndex(r)))return{point:[]};var a=n.getData(),o=Fi(a,t);if(null==o||0>o||_(o))return{point:[]};var s=a.getItemGraphicEl(o),l=n.coordinateSystem;if(n.getTooltipPosition)i=n.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)i=l.dataToPoint(a.getValues(p(l.dimensions,function(t){return a.mapDimension(t)}),o,!0))||[];else if(s){var h=s.getBoundingRect().clone();h.applyTransform(s.transform),i=[h.x+h.width/2,h.y+h.height/2]}return{point:i,el:s}},_b=f,wb=x,bb=Gi(),Sb=function(t,e,n){var i=t.currTrigger,r=[t.x,t.y],a=t,o=t.dispatchAction||y(n.dispatchAction,n),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){wd(r)&&(r=xb({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},e).point);var l=wd(r),h=a.axesInfo,u=s.axesInfo,c="leave"===i||wd(r),d={},f={},p={list:[],map:{}},g={showPointer:wb(pd,f),showTooltip:wb(gd,p)};_b(s.coordSysMap,function(t,e){var n=l||t.containPoint(r);_b(s.coordSysAxesInfo[e],function(t){var e=t.axis,i=xd(h,t);if(!c&&n&&(!h||i)){var a=i&&i.value;null!=a||l||(a=e.pointToData(r)),null!=a&&dd(t,a,g,!1,d)}})});var m={};return _b(u,function(t,e){var n=t.linkGroup;n&&!f[e]&&_b(n.axesInfo,function(e,i){var r=f[i];if(e!==t&&r){var a=r.value;n.mapper&&(a=t.axis.scale.parse(n.mapper(a,_d(e),_d(t)))),m[t.key]=a}})}),_b(m,function(t,e){dd(u[e],t,g,!0,d)}),md(f,u,d),vd(p,r,t,o),yd(u,o,n),d}},Mb=(Al({type:"axisPointer",coordSysAxesInfo:null,defaultOption:{show:"auto",triggerOn:null,zlevel:0,z:50,type:"line",snap:!1,triggerTooltip:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#aaa",width:1,type:"solid"},shadowStyle:{color:"rgba(150,150,150,0.3)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,shadowBlur:3,shadowColor:"#aaa"},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}}}),Gi()),Ib=f,Tb=kl({type:"axisPointer",render:function(t,e,n){var i=e.getComponent("tooltip"),r=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";bd("axisPointer",n,function(t,e,n){"none"!==r&&("leave"===t||r.indexOf(t)>=0)&&n({type:"updateAxisPointer",currTrigger:t,x:e&&e.offsetX,y:e&&e.offsetY})})},remove:function(t,e){Dd(e.getZr(),"axisPointer"),Tb.superApply(this._model,"remove",arguments)},dispose:function(t,e){Dd("axisPointer",e),Tb.superApply(this._model,"dispose",arguments)}}),Cb=Gi(),Db=i,Ab=y;Ad.prototype={_group:null,_lastGraphicKey:null,_handle:null,_dragging:!1,_lastValue:null,_lastStatus:null,_payloadInfo:null,animationThreshold:15,render:function(t,e,n,i){var r=e.get("value"),a=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=n,i||this._lastValue!==r||this._lastStatus!==a){this._lastValue=r,this._lastStatus=a;var o=this._group,s=this._handle;if(!a||"hide"===a)return o&&o.hide(),void(s&&s.hide());o&&o.show(),s&&s.show();var l={};this.makeElOption(l,r,t,e,n);var h=l.graphicKey;h!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=h;var u=this._moveAnimation=this.determineAnimation(t,e);if(o){var c=x(kd,e,u);this.updatePointerEl(o,l,c,e),this.updateLabelEl(o,l,c,e)}else o=this._group=new hp,this.createPointerEl(o,l,t,e),this.createLabelEl(o,l,t,e),n.getZr().add(o);zd(o,e,!0),this._renderHandle(r)}},remove:function(t){this.clear(t)},dispose:function(t){this.clear(t)},determineAnimation:function(t,e){var n=e.get("animation"),i=t.axis,r="category"===i.type,a=e.get("snap");if(!a&&!r)return!1;if("auto"===n||null==n){var o=this.animationThreshold;if(r&&i.getBandWidth()>o)return!0;if(a){var s=xu(t).seriesDataCount,l=i.getExtent();return Math.abs(l[0]-l[1])/s>o}return!1}return n===!0},makeElOption:function(){},createPointerEl:function(t,e){var n=e.pointer;if(n){var i=Cb(t).pointerEl=new Um[n.type](Db(e.pointer));t.add(i)}},createLabelEl:function(t,e,n,i){if(e.label){var r=Cb(t).labelEl=new Pm(Db(e.label));t.add(r),Ld(r,i)}},updatePointerEl:function(t,e,n){var i=Cb(t).pointerEl;i&&(i.setStyle(e.pointer.style),n(i,{shape:e.pointer.shape}))},updateLabelEl:function(t,e,n,i){var r=Cb(t).labelEl;r&&(r.setStyle(e.label.style),n(r,{shape:e.label.shape,position:e.label.position}),Ld(r,i))},_renderHandle:function(t){if(!this._dragging&&this.updateHandleTransform){var e=this._axisPointerModel,n=this._api.getZr(),i=this._handle,r=e.getModel("handle"),a=e.get("status");if(!r.get("show")||!a||"hide"===a)return i&&n.remove(i),void(this._handle=null);var o;this._handle||(o=!0,i=this._handle=Aa(r.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){Wp(t.event)},onmousedown:Ab(this._onHandleDragMove,this,0,0),drift:Ab(this._onHandleDragMove,this),ondragend:Ab(this._onHandleDragEnd,this)}),n.add(i)),zd(i,e,!1);var s=["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];i.setStyle(r.getItemStyle(null,s));var l=r.get("size");_(l)||(l=[l,l]),i.attr("scale",[l[0]/2,l[1]/2]),Cs(this,"_doDispatchAxisPointer",r.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,o)}},_moveHandleToValue:function(t,e){kd(this._axisPointerModel,!e&&this._moveAnimation,this._handle,Od(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},_onHandleDragMove:function(t,e){var n=this._handle;if(n){this._dragging=!0;var i=this.updateHandleTransform(Od(n),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(Od(i)),Cb(n).lastProp=null,this._doDispatchAxisPointer()}},_doDispatchAxisPointer:function(){var t=this._handle;if(t){var e=this._payloadInfo,n=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:e.cursorPoint[0],y:e.cursorPoint[1],tooltipOption:e.tooltipOption,axesInfo:[{axisDim:n.axis.dim,axisIndex:n.componentIndex}]})}},_onHandleDragEnd:function(){this._dragging=!1;var t=this._handle;if(t){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},getHandleTransform:null,updateHandleTransform:null,clear:function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),n=this._group,i=this._handle;e&&n&&(this._lastGraphicKey=null,n&&e.remove(n),i&&e.remove(i),this._group=null,this._handle=null,this._payloadInfo=null)},doClear:function(){},buildLabel:function(t,e,n){return n=n||0,{x:t[n],y:t[1-n],width:e[n],height:e[1-n]}}},Ad.prototype.constructor=Ad,Yi(Ad);var kb=Ad.extend({makeElOption:function(t,e,n,i,r){var a=n.axis,o=a.grid,s=i.get("type"),l=Wd(o,a).getOtherAxis(a).getGlobalExtent(),h=a.toGlobalCoord(a.dataToCoord(e,!0));if(s&&"none"!==s){var u=Rd(i),c=Pb[s](a,h,l,u);c.style=u,t.graphicKey=c.type,t.pointer=c}var d=Iu(o.model,n);Gd(e,t,d,n,i,r)},getHandleTransform:function(t,e,n){var i=Iu(e.axis.grid.model,e,{labelInside:!1});return i.labelMargin=n.get("handle.margin"),{position:Fd(e.axis,t,i),rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},updateHandleTransform:function(t,e,n){var i=n.axis,r=i.grid,a=i.getGlobalExtent(!0),o=Wd(r,i).getOtherAxis(i).getGlobalExtent(),s="x"===i.dim?0:1,l=t.position;l[s]+=e[s],l[s]=Math.min(a[1],l[s]),l[s]=Math.max(a[0],l[s]);var h=(o[1]+o[0])/2,u=[h,h];u[s]=l[s];var c=[{verticalAlign:"middle"},{align:"center"}];return{position:l,rotation:t.rotation,cursorPoint:u,tooltipOption:c[s]}}}),Pb={line:function(t,e,n,i){var r=Vd([e,n[0]],[e,n[1]],Xd(t));return jr({shape:r,style:i}),{type:"Line",shape:r}},shadow:function(t,e,n){var i=t.getBandWidth(),r=n[1]-n[0];return{type:"Rect",shape:Hd([e-i/2,n[0]],[i,r],Xd(t))}}};V_.registerAxisPointerClass("CartesianAxisPointer",kb),xl(function(t){if(t){(!t.axisPointer||0===t.axisPointer.length)&&(t.axisPointer={});var e=t.axisPointer.link;e&&!_(e)&&(t.axisPointer.link=[e])}}),_l(Wy.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=du(t,e)}),bl({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},Sb),Al({type:"tooltip",dependencies:["axisPointer"],defaultOption:{zlevel:0,z:8,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",confine:!1,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"rgba(50,50,50,0.7)",borderColor:"#333",borderRadius:4,borderWidth:0,padding:5,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#fff",fontSize:14}}});var Lb=f,Ob=to,zb=["","-webkit-","-moz-","-o-"],Rb="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;";jd.prototype={constructor:jd,_enterable:!0,update:function(){var t=this._container,e=t.currentStyle||document.defaultView.getComputedStyle(t),n=t.style;"absolute"!==n.position&&"absolute"!==e.position&&(n.position="relative")},show:function(t){clearTimeout(this._hideTimeout);var e=this.el;e.style.cssText=Rb+Yd(t)+";left:"+this._x+"px;top:"+this._y+"px;"+(t.get("extraCssText")||""),e.style.display=e.innerHTML?"block":"none",this._show=!0},setContent:function(t){this.el.innerHTML=null==t?"":t},setEnterable:function(t){this._enterable=t},getSize:function(){var t=this.el;return[t.clientWidth,t.clientHeight]},moveTo:function(t,e){var n,i=this._zr;i&&i.painter&&(n=i.painter.getViewportRootOffset())&&(t+=n.offsetLeft,e+=n.offsetTop);var r=this.el.style;r.left=t+"px",r.top=e+"px",this._x=t,this._y=e},hide:function(){this.el.style.display="none",this._show=!1},hideLater:function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(y(this.hide,this),t)):this.hide())},isShow:function(){return this._show}};var Bb=y,Eb=f,Nb=Na,Fb=new Pm({shape:{x:-1,y:-1,width:2,height:2}});kl({type:"tooltip",init:function(t,e){if(!of.node){var n=new jd(e.getDom(),e);this._tooltipContent=n}},render:function(t,e,n){if(!of.node&&!of.wxa){this.group.removeAll(),this._tooltipModel=t,this._ecModel=e,this._api=n,this._lastDataByCoordSys=null,this._alwaysShowContent=t.get("alwaysShowContent");var i=this._tooltipContent;i.update(),i.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow()}},_initGlobalListener:function(){var t=this._tooltipModel,e=t.get("triggerOn");bd("itemTooltip",this._api,Bb(function(t,n,i){"none"!==e&&(e.indexOf(t)>=0?this._tryShow(n,i):"leave"===t&&this._hide(i))},this))},_keepShow:function(){var t=this._tooltipModel,e=this._ecModel,n=this._api;if(null!=this._lastX&&null!=this._lastY&&"none"!==t.get("triggerOn")){var i=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){i.manuallyShowTip(t,e,n,{x:i._lastX,y:i._lastY})})}},manuallyShowTip:function(t,e,n,i){if(i.from!==this.uid&&!of.node){var r=$d(i,n);this._ticket="";var a=i.dataByCoordSys;if(i.tooltip&&null!=i.x&&null!=i.y){var o=Fb;o.position=[i.x,i.y],o.update(),o.tooltip=i.tooltip,this._tryShow({offsetX:i.x,offsetY:i.y,target:o},r)}else if(a)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,event:{},dataByCoordSys:i.dataByCoordSys,tooltipOption:i.tooltipOption},r);else if(null!=i.seriesIndex){if(this._manuallyAxisShowTip(t,e,n,i))return;var s=xb(i,e),l=s.point[0],h=s.point[1];null!=l&&null!=h&&this._tryShow({offsetX:l,offsetY:h,position:i.position,target:s.el,event:{}},r)}else null!=i.x&&null!=i.y&&(n.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:n.getZr().findHover(i.x,i.y).target,event:{}},r))}},manuallyHideTip:function(t,e,n,i){var r=this._tooltipContent;!this._alwaysShowContent&&this._tooltipModel&&r.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=null,i.from!==this.uid&&this._hide($d(i,n))},_manuallyAxisShowTip:function(t,e,n,i){var r=i.seriesIndex,a=i.dataIndex,o=e.getComponent("axisPointer").coordSysAxesInfo;if(null!=r&&null!=a&&null!=o){var s=e.getSeriesByIndex(r);if(s){var l=s.getData(),t=qd([l.getItemModel(a),s,(s.coordinateSystem||{}).model,t]);if("axis"===t.get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:r,dataIndex:a,position:i.position}),!0}}},_tryShow:function(t,e){var n=t.target,i=this._tooltipModel;if(i){this._lastX=t.offsetX,this._lastY=t.offsetY;var r=t.dataByCoordSys;r&&r.length?this._showAxisTooltip(r,t):n&&null!=n.dataIndex?(this._lastDataByCoordSys=null,this._showSeriesItemTooltip(t,n,e)):n&&n.tooltip?(this._lastDataByCoordSys=null,this._showComponentItemTooltip(t,n,e)):(this._lastDataByCoordSys=null,this._hide(e))}},_showOrMove:function(t,e){var n=t.get("showDelay");e=y(e,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(e,n):e()},_showAxisTooltip:function(t,e){var n=this._ecModel,i=this._tooltipModel,r=[e.offsetX,e.offsetY],a=[],o=[],s=qd([e.tooltipOption,i]);Eb(t,function(t){Eb(t.dataByAxis,function(t){var e=n.getComponent(t.axisDim+"Axis",t.axisIndex),i=t.value,r=[];if(e&&null!=i){var s=Nd(i,e.axis,n,t.seriesDataIndices,t.valueLabelOpt);f(t.seriesDataIndices,function(a){var l=n.getSeriesByIndex(a.seriesIndex),h=a.dataIndexInside,u=l&&l.getDataParams(h);u.axisDim=t.axisDim,u.axisIndex=t.axisIndex,u.axisType=t.axisType,u.axisId=t.axisId,u.axisValue=Th(e.axis,i),u.axisValueLabel=s,u&&(o.push(u),r.push(l.formatTooltip(h,!0)))});var l=s;a.push((l?eo(l)+"
":"")+r.join("
"))}})},this),a.reverse(),a=a.join("

");var l=e.position;this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(t)?this._updatePosition(s,l,r[0],r[1],this._tooltipContent,o):this._showTooltipContent(s,a,o,Math.random(),r[0],r[1],l)})},_showSeriesItemTooltip:function(t,e,n){var i=this._ecModel,r=e.seriesIndex,a=i.getSeriesByIndex(r),o=e.dataModel||a,s=e.dataIndex,l=e.dataType,h=o.getData(),u=qd([h.getItemModel(s),o,a&&(a.coordinateSystem||{}).model,this._tooltipModel]),c=u.get("trigger");if(null==c||"item"===c){var d=o.getDataParams(s,l),f=o.formatTooltip(s,!1,l),p="item_"+o.name+"_"+s;this._showOrMove(u,function(){this._showTooltipContent(u,f,d,p,t.offsetX,t.offsetY,t.position,t.target)}),n({type:"showTip",dataIndexInside:s,dataIndex:h.getRawIndex(s),seriesIndex:r,from:this.uid})}},_showComponentItemTooltip:function(t,e,n){var i=e.tooltip;if("string"==typeof i){var r=i;i={content:r,formatter:r}}var a=new ka(i,this._tooltipModel,this._ecModel),o=a.get("content"),s=Math.random();this._showOrMove(a,function(){this._showTooltipContent(a,o,a.get("formatterParams")||{},s,t.offsetX,t.offsetY,t.position,e)}),n({type:"showTip",from:this.uid})},_showTooltipContent:function(t,e,n,i,r,a,o,s){if(this._ticket="",t.get("showContent")&&t.get("show")){var l=this._tooltipContent,h=t.get("formatter");o=o||t.get("position");var u=e;if(h&&"string"==typeof h)u=no(h,n,!0);else if("function"==typeof h){var c=Bb(function(e,i){e===this._ticket&&(l.setContent(i),this._updatePosition(t,o,r,a,l,n,s))},this);this._ticket=i,u=h(n,i,c)}l.setContent(u),l.show(t),this._updatePosition(t,o,r,a,l,n,s)}},_updatePosition:function(t,e,n,i,r,a,o){var s=this._api.getWidth(),l=this._api.getHeight();e=e||t.get("position");var h=r.getSize(),u=t.get("align"),c=t.get("verticalAlign"),d=o&&o.getBoundingRect().clone();if(o&&d.applyTransform(o.transform),"function"==typeof e&&(e=e([n,i],a,r.el,d,{viewSize:[s,l],contentSize:h.slice()})),_(e))n=Nb(e[0],s),i=Nb(e[1],l);else if(S(e)){e.width=h[0],e.height=h[1];var f=lo(e,{width:s,height:l});n=f.x,i=f.y,u=null,c=null}else if("string"==typeof e&&o){var p=tf(e,d,h);n=p[0],i=p[1]}else{var p=Kd(n,i,r.el,s,l,u?null:20,c?null:20);n=p[0],i=p[1]}if(u&&(n-=ef(u)?h[0]/2:"right"===u?h[0]:0),c&&(i-=ef(c)?h[1]/2:"bottom"===c?h[1]:0),t.get("confine")){var p=Jd(n,i,r.el,s,l);n=p[0],i=p[1]}r.moveTo(n,i)},_updateContentNotChangedOnAxis:function(t){var e=this._lastDataByCoordSys,n=!!e&&e.length===t.length;return n&&Eb(e,function(e,i){var r=e.dataByAxis||{},a=t[i]||{},o=a.dataByAxis||[];n&=r.length===o.length,n&&Eb(r,function(t,e){var i=o[e]||{},r=t.seriesDataIndices||[],a=i.seriesDataIndices||[];n&=t.value===i.value&&t.axisType===i.axisType&&t.axisId===i.axisId&&r.length===a.length,n&&Eb(r,function(t,e){var i=a[e];n&=t.seriesIndex===i.seriesIndex&&t.dataIndex===i.dataIndex})})}),this._lastDataByCoordSys=t,!!n},_hide:function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},dispose:function(t,e){of.node||(this._tooltipContent.hide(),Dd("itemTooltip",e))}}),bl({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},function(){}),bl({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},function(){}),t.version=Oy,t.dependencies=zy,t.PRIORITY=Wy,t.init=dl,t.connect=fl,t.disConnect=pl,t.disconnect=cx,t.dispose=gl,t.getInstanceByDom=ml,t.getInstanceById=vl,t.registerTheme=yl,t.registerPreprocessor=xl,t.registerProcessor=_l,t.registerPostUpdate=wl,t.registerAction=bl,t.registerCoordinateSystem=Sl,t.getCoordinateSystemDimensions=Ml,t.registerLayout=Il,t.registerVisual=Tl,t.registerLoading=Dl,t.extendComponentModel=Al,t.extendComponentView=kl,t.extendSeriesModel=Pl,t.extendChartView=Ll,t.setCanvasCreator=Ol,t.registerMap=zl,t.getMap=Rl,t.dataTool=dx,t.zrender=ag,t.graphic=Um,t.number=iv,t.format=uv,t.throttle=Ts,t.helper=o_,t.matrix=Of,t.vector=Tf,t.color=$f,t.parseGeoJSON=l_,t.parseGeoJson=d_,t.util=f_,t.List=_x,t.Model=ka,t.Axis=c_,t.env=of}); + +}); \ No newline at end of file