echarts
Version:
A powerful charting and visualization library for browser
11 lines • 202 kB
JavaScript
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.echarts=e():t.echarts=e()}(this,function(){return function(t){function e(i){if(n[i])return n[i].exports;var r=n[i]={exports:{},id:i,loaded:!1};return t[i].call(r.exports,r,r.exports,e),r.loaded=!0,r.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){t.exports=n(2),n(85),n(79),n(90),n(34)},function(t,e,n){function i(t){if("object"==typeof t&&null!==t){var e=t;if(t instanceof Array){e=[];for(var n=0,r=t.length;r>n;n++)e[n]=i(t[n])}else if(!C(t)&&!T(t)){e={};for(var a in t)t.hasOwnProperty(a)&&(e[a]=i(t[a]))}return e}return t}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)||b(s)||b(o)||T(s)||T(o)||C(s)||C(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 h(){return document.createElement("canvas")}function l(){return L||(L=V.createCanvas().getContext("2d")),L}function u(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 c(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 f(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 p(t,e,n){if(t&&e)if(t.forEach&&t.forEach===E)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 g(t,e,n){if(t&&e){if(t.map&&t.map===N)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 v(t,e,n,i){if(t&&e){if(t.reduce&&t.reduce===F)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===B)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 y(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 x(t,e){var n=R.call(arguments,2);return function(){return t.apply(e,n.concat(R.call(arguments)))}}function _(t){var e=R.call(arguments,1);return function(){return t.apply(this,e.concat(R.call(arguments)))}}function b(t){return"[object Array]"===O.call(t)}function w(t){return"function"==typeof t}function M(t){return"[object String]"===O.call(t)}function S(t){var e=typeof t;return"function"===e||!!t&&"object"==e}function C(t){return!!D[O.call(t)]||t instanceof P}function T(t){return t&&1===t.nodeType&&"string"==typeof t.nodeName}function A(t){for(var e=0,n=arguments.length;n>e;e++)if(null!=arguments[e])return arguments[e]}function I(){return Function.call.apply(R,arguments)}function k(t,e){if(!t)throw new Error(e)}var L,P=n(16),D={"[object Function]":1,"[object RegExp]":1,"[object Date]":1,"[object Error]":1,"[object CanvasGradient]":1},O=Object.prototype.toString,z=Array.prototype,E=z.forEach,B=z.filter,R=z.slice,N=z.map,F=z.reduce,V={inherits:c,mixin:f,clone:i,merge:r,mergeAll:a,extend:o,defaults:s,getContext:l,createCanvas:h,indexOf:u,slice:I,find:y,isArrayLike:d,each:p,map:g,reduce:v,filter:m,bind:x,curry:_,isArray:b,isString:M,isObject:S,isFunction:w,isBuildInObject:C,isDom:T,retrieve:A,assert:k,noop:function(){}};t.exports=V},function(t,e,n){function i(t){return function(e,n,i){e=e&&e.toLowerCase(),k.prototype[t].call(this,e,n,i)}}function r(){k.call(this)}function a(t,e,n){n=n||{},"string"==typeof e&&(e=W[e]),e&&L(G,function(t){t(e)}),this.id,this.group,this._dom=t,this._zr=C.init(t,{renderer:n.renderer||"canvas",devicePixelRatio:n.devicePixelRatio}),this._theme=T.clone(e),this._chartsViews=[],this._chartsMap={},this._componentsViews=[],this._componentsMap={},this._api=new m(this),this._coordSysMgr=new y,k.call(this),this._messageCenter=new r,this._initEvents(),this.resize=T.bind(this.resize,this)}function o(t,e){var n=this._model;n&&n.eachComponent({mainType:"series",query:e},function(i,r){var a=this._chartsMap[i.__viewId];a&&a.__alive&&a[t](i,n,this._api,e)},this)}function s(t,e,n){var i=this._api;L(this._componentsViews,function(r){var a=r.__model;r[t](a,e,i,n),p(a,r)},this),e.eachSeries(function(r,a){var o=this._chartsMap[r.__viewId];o[t](r,e,i,n),p(r,o)},this)}function h(t,e){for(var n="component"===t,i=n?this._componentsViews:this._chartsViews,r=n?this._componentsMap:this._chartsMap,a=this._zr,o=0;o<i.length;o++)i[o].__alive=!1;e[n?"eachComponent":"eachSeries"](function(t,o){if(n){if("series"===t)return}else o=t;var s=o.id+"_"+o.type,h=r[s];if(!h){var l=_.parseClassType(o.type),u=n?w.getClass(l.main,l.sub):M.getClass(l.sub);if(!u)return;h=new u,h.init(e,this._api),r[s]=h,i.push(h),a.add(h.group)}o.__viewId=s,h.__alive=!0,h.__id=s,h.__model=o},this);for(var o=0;o<i.length;){var s=i[o];s.__alive?o++:(a.remove(s.group),s.dispose(e,this._api),i.splice(o,1),delete r[s.__id])}}function l(t,e){L(D,function(n){L(V[n]||[],function(n){n(t,e)})})}function u(t){var e={};t.eachSeries(function(t){var n=t.get("stack"),i=t.getData();if(n&&"list"===i.type){var r=e[n];r&&(i.stackedOn=r),e[n]=i}})}function c(t,e){var n=this._api;L(F,function(i){i(t,n,e)})}function f(t,e){L(P,function(n){L(q[n]||[],function(n){n(t,e)})})}function d(t,e){var n=this._api;L(this._componentsViews,function(i){var r=i.__model;i.render(r,t,n,e),p(r,i)},this),L(this._chartsViews,function(t){t.__alive=!1},this),t.eachSeries(function(i,r){var a=this._chartsMap[i.__viewId];a.__alive=!0,a.render(i,t,n,e),p(i,a)},this),L(this._chartsViews,function(e){e.__alive||e.remove(t,n)},this)}function p(t,e){var n=t.get("z"),i=t.get("zlevel");e.group.traverse(function(t){null!=n&&(t.z=n),null!=i&&(t.zlevel=i)})}function g(t){function e(t,e){for(var n=0;n<t.length;n++){var i=t[n];i[a]=e}}var n=0,i=1,r=2,a="__connectUpdateStatus";T.each(N,function(o,s){t._messageCenter.on(s,function(o){if(j[t.group]&&t[a]!==n){var s=t.makeActionFromEvent(o),h=[];for(var l in H){var u=H[l];u!==t&&u.group===t.group&&h.push(u)}e(h,n),L(h,function(t){t[a]!==i&&t.dispatchAction(s)}),e(h,r)}})})}/*!
* ECharts, a javascript interactive chart library.
*
* Copyright (c) 2015, Baidu Inc.
* All rights reserved.
*
* LICENSE
* https://github.com/ecomfe/echarts/blob/master/LICENSE.txt
*/
var v=n(111),m=n(78),y=n(28),x=n(112),_=n(10),b=n(13),w=n(54),M=n(25),S=n(3),C=n(67),T=n(1),A=n(22),I=n(15),k=n(21),L=T.each,P=["echarts","chart","component"],D=["transform","filter","statistic"];r.prototype.on=i("on"),r.prototype.off=i("off"),r.prototype.one=i("one"),T.mixin(r,k);var O=a.prototype;O.getDom=function(){return this._dom},O.getZr=function(){return this._zr},O.setOption=function(t,e,n){this._model&&!e||(this._model=new v(null,null,this._theme,new x(this._api))),this._model.setOption(t,G),z.prepareAndUpdate.call(this),!n&&this._zr.refreshImmediately()},O.setTheme=function(){console.log("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},O.getModel=function(){return this._model},O.getOption=function(){return this._model.getOption()},O.getWidth=function(){return this._zr.getWidth()},O.getHeight=function(){return this._zr.getHeight()},O.getRenderedCanvas=function(t){if(I.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 T.each(n,function(t){t.stopAnimation(!0)}),e.painter.getRenderedCanvas(t)}},O.getDataURL=function(t){t=t||{};var e=t.excludeComponents,n=this._model,i=[],r=this;L(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=this.getRenderedCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return L(i,function(t){t.group.ignore=!1}),a},O.getConnectedDataURL=function(t){if(I.canvasSupported){var e=this.group,n=Math.min,i=Math.max,r=1/0;if(j[e]){var a=r,o=r,s=-r,h=-r,l=[],u=t&&t.pixelRatio||1;for(var c in H){var f=H[c];if(f.group===e){var d=f.getRenderedCanvas(T.clone(t)),p=f.getDom().getBoundingClientRect();a=n(p.left,a),o=n(p.top,o),s=i(p.right,s),h=i(p.bottom,h),l.push({dom:d,left:p.left,top:p.top})}}a*=u,o*=u,s*=u,h*=u;var g=s-a,v=h-o,m=T.createCanvas();m.width=g,m.height=v;var y=C.init(m);return L(l,function(t){var e=new S.Image({style:{x:t.left*u-a,y:t.top*u-o,image:t.dom}});y.add(e)}),y.refreshImmediately(),m.toDataURL("image/"+(t&&t.type||"png"))}return this.getDataURL(t)}};var z={update:function(t){var e=this._model,n=this._api,i=this._coordSysMgr;if(e){e.restoreData(),i.create(this._model,this._api),l.call(this,e,n),u.call(this,e),i.update(e,n),c.call(this,e,t),f.call(this,e,t),d.call(this,e,t);var r=e.get("backgroundColor")||"transparent",a=this._zr.painter;if(a.isSingleCanvas&&a.isSingleCanvas())this._zr.configLayer(0,{clearColor:r});else{if(!I.canvasSupported){var o=A.parse(r);r=A.stringify(o,"rgb"),0===o[3]&&(r="transparent")}r=r,this._dom.style.backgroundColor=r}}},updateView:function(t){var e=this._model;e&&(c.call(this,e,t),f.call(this,e,t),s.call(this,"updateView",e,t))},updateVisual:function(t){var e=this._model;e&&(f.call(this,e,t),s.call(this,"updateVisual",e,t))},updateLayout:function(t){var e=this._model;e&&(c.call(this,e,t),s.call(this,"updateLayout",e,t))},highlight:function(t){o.call(this,"highlight",t)},downplay:function(t){o.call(this,"downplay",t)},prepareAndUpdate:function(t){var e=this._model;h.call(this,"component",e),h.call(this,"chart",e),z.update.call(this,t)}};O.resize=function(){this._zr.resize();var t=this._model&&this._model.resetOption("media");z[t?"prepareAndUpdate":"update"].call(this),this._loadingFX&&this._loadingFX.resize()};var E=n(110);O.showLoading=function(t,e){T.isObject(t)&&(e=t,t="default");var n=E(this._api,e),i=this._zr;this._loadingFX=n,i.add(n)},O.hideLoading=function(){this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},O.makeActionFromEvent=function(t){var e=T.extend({},t);return e.type=N[t.type],e},O.dispatchAction=function(t,e){var n=R[t.type];if(n){var i=n.actionInfo,r=i.update||"update",a=[t],o=!1;t.batch&&(o=!0,a=T.map(t.batch,function(e){return e=T.defaults(T.extend({},e),t),e.batch=null,e}));for(var s,h=[],l="highlight"===t.type||"downplay"===t.type,u=0;u<a.length;u++){var c=a[u];s=n.action(c,this._model),s=s||T.extend({},c),s.type=i.event||s.type,h.push(s),l&&z[r].call(this,c)}"none"!==r&&!l&&z[r].call(this,t),e||(s=o?{type:h[0].type,batch:h}:h[0],this._messageCenter.trigger(s.type,s))}},O.on=i("on"),O.off=i("off"),O.one=i("one");var B=["click","dblclick","mouseover","mouseout","globalout"];O._initEvents=function(){var t=this._zr;L(B,function(e){t.on(e,function(t){var n=this.getModel(),i=t.target;if(i&&null!=i.dataIndex){var r=i.hostModel||n.getSeriesByIndex(i.seriesIndex),a=r&&r.getDataParams(i.dataIndex)||{};a.event=t,a.type=e,this.trigger(e,a)}},this)},this),L(N,function(t,e){this._messageCenter.on(e,function(t){this.trigger(e,t)},this)},this)},O.isDisposed=function(){return this._disposed},O.clear=function(){this.setOption({},!0)},O.dispose=function(){this._disposed=!0;var t=this._api,e=this._model;L(this._componentsViews,function(n){n.dispose(e,t)}),L(this._chartsViews,function(n){n.dispose(e,t)}),this._zr.dispose(),H[this.id]=null},T.mixin(a,k);var R=[],N={},F=[],V={},G=[],q={},W={},H={},j={},Z=new Date-0,X=new Date-0,U="_echarts_instance_",Y={version:"3.1.3",dependencies:{zrender:"3.0.4"}};Y.init=function(t,e,n){if(C.version.replace(".","")-0<Y.dependencies.zrender.replace(".","")-0)throw new Error("ZRender "+C.version+" is too old for ECharts "+Y.version+". Current version need ZRender "+Y.dependencies.zrender+"+");if(!t)throw new Error("Initialize failed: invalid dom.");var i=new a(t,e,n);return i.id="ec_"+Z++,H[i.id]=i,t.setAttribute&&t.setAttribute(U,i.id),g(i),i},Y.connect=function(t){if(T.isArray(t)){var e=t;t=null,T.each(e,function(e){null!=e.group&&(t=e.group)}),t=t||"g_"+X++,T.each(e,function(e){e.group=t})}return j[t]=!0,t},Y.disConnect=function(t){j[t]=!1},Y.dispose=function(t){T.isDom(t)?t=Y.getInstanceByDom(t):"string"==typeof t&&(t=H[t]),t instanceof a&&!t.isDisposed()&&t.dispose()},Y.getInstanceByDom=function(t){var e=t.getAttribute(U);return H[e]},Y.getInstanceById=function(t){return H[t]},Y.registerTheme=function(t,e){W[t]=e},Y.registerPreprocessor=function(t){G.push(t)},Y.registerProcessor=function(t,e){if(T.indexOf(D,t)<0)throw new Error("stage should be one of "+D);var n=V[t]||(V[t]=[]);n.push(e)},Y.registerAction=function(t,e,n){"function"==typeof e&&(n=e,e="");var i=T.isObject(t)?t.type:[t,t={event:e}][0];t.event=(t.event||i).toLowerCase(),e=t.event,R[i]||(R[i]={action:n,actionInfo:t}),N[e]=i},Y.registerCoordinateSystem=function(t,e){y.register(t,e)},Y.registerLayout=function(t){T.indexOf(F,t)<0&&F.push(t)},Y.registerVisualCoding=function(t,e){if(T.indexOf(P,t)<0)throw new Error("stage should be one of "+P);var n=q[t]||(q[t]=[]);n.push(e)},Y.extendChartView=function(t){return M.extend(t)},Y.extendComponentModel=function(t){return _.extend(t)},Y.extendSeriesModel=function(t){return b.extend(t)},Y.extendComponentView=function(t){return w.extend(t)},Y.setCanvasCreator=function(t){T.createCanvas=t},Y.registerVisualCoding("echarts",T.curry(n(74),"","itemStyle")),Y.registerPreprocessor(n(119)),Y.registerAction({type:"highlight",event:"highlight",update:"highlight"},T.noop),Y.registerAction({type:"downplay",event:"downplay",update:"downplay"},T.noop),Y.graphic=n(3),Y.number=n(4),Y.format=n(9),Y.matrix=n(19),Y.vector=n(5),Y.util={},L(["map","each","filter","indexOf","inherits","reduce","filter","bind","curry","isArray","isString","isObject","isFunction","extend"],function(t){Y.util[t]=T[t]}),t.exports=Y},function(t,e,n){"use strict";function i(t){if(!t.__isHover){if(t.__hoverStlDirty){var e=t.style.stroke,n=t.style.fill,i=t.__hoverStl;i.fill=i.fill||(n instanceof _?n:m.lift(n,-.1)),i.stroke=i.stroke||(e instanceof _?e:m.lift(e,-.1));var r={};for(var a in i)i.hasOwnProperty(a)&&(r[a]=t.style[a]);t.__normalStl=r,t.__hoverStlDirty=!1}t.setStyle(t.__hoverStl),t.z2+=1,t.__isHover=!0}}function r(t){if(t.__isHover){var e=t.__normalStl;e&&t.setStyle(e),t.z2-=1,t.__isHover=!1}}function a(t){"group"===t.type?t.traverse(function(t){"group"!==t.type&&i(t)}):i(t)}function o(t){"group"===t.type?t.traverse(function(t){"group"!==t.type&&r(t)}):r(t)}function s(t,e){t.__hoverStl=t.hoverStyle||e,t.__hoverStlDirty=!0}function h(){!this.__isEmphasis&&a(this)}function l(){!this.__isEmphasis&&o(this)}function u(){this.__isEmphasis=!0,a(this)}function c(){this.__isEmphasis=!1,o(this)}function f(t,e,n,i,r){var a=t?"Update":"",o=i&&i.getShallow("animationDuration"+a),s=i&&i.getShallow("animationEasing"+a);i&&i.getShallow("animation")?e.animateTo(n,o,s,r):(e.attr(n),r&&r())}var d=n(1),p=n(155),g=Math.round,v=n(6),m=n(22),y=n(19),x=n(5),_=n(16),b={};b.Group=n(26),b.Image=n(46),b.Text=n(65),b.Circle=n(146),b.Sector=n(152),b.Ring=n(151),b.Polygon=n(148),b.Polyline=n(149),b.Rect=n(150),b.Line=n(147),b.BezierCurve=n(145),b.Arc=n(144),b.LinearGradient=n(76),b.RadialGradient=n(140),b.BoundingRect=n(8),b.extendShape=function(t){return v.extend(t)},b.extendPath=function(t,e){return p.extendFromString(t,e)},b.makePath=function(t,e,n,i){var r=p.createFromString(t,e),a=r.getBoundingRect();if(n){var o=a.width/a.height;if("center"===i){var s,h=n.height*o;h<=n.width?s=n.height:(h=n.width,s=h/o);var l=n.x+n.width/2,u=n.y+n.height/2;n.x=l-h/2,n.y=u-s/2,n.width=h,n.height=s}this.resizePath(r,n)}return r},b.mergePath=p.mergePath,b.resizePath=function(t,e){if(t.applyTransform){var n=t.getBoundingRect(),i=n.calculateTransform(e);t.applyTransform(i)}},b.subPixelOptimizeLine=function(t){var e=b.subPixelOptimize,n=t.shape,i=t.style.lineWidth;return g(2*n.x1)===g(2*n.x2)&&(n.x1=n.x2=e(n.x1,i,!0)),g(2*n.y1)===g(2*n.y2)&&(n.y1=n.y2=e(n.y1,i,!0)),t},b.subPixelOptimizeRect=function(t){var e=b.subPixelOptimize,n=t.shape,i=t.style.lineWidth,r=n.x,a=n.y,o=n.width,s=n.height;return n.x=e(n.x,i,!0),n.y=e(n.y,i,!0),n.width=Math.max(e(r+o,i,!1)-n.x,0===o?0:1),n.height=Math.max(e(a+s,i,!1)-n.y,0===s?0:1),t},b.subPixelOptimize=function(t,e,n){var i=g(2*t);return(i+g(e))%2===0?i/2:(i+(n?1:-1))/2},b.setHoverStyle=function(t,e){e=e||{},"group"===t.type?t.traverse(function(t){"group"!==t.type&&s(t,e)}):s(t,e),t.on("mouseover",h).on("mouseout",l),t.on("emphasis",u).on("normal",c)},b.setText=function(t,e,n){var i=e.getShallow("position")||"inside",r=i.indexOf("inside")>=0?"white":n,a=e.getModel("textStyle");d.extend(t,{textDistance:e.getShallow("distance")||5,textFont:a.getFont(),textPosition:i,textFill:a.getTextColor()||r})},b.updateProps=d.curry(f,!0),b.initProps=d.curry(f,!1),b.getTransform=function(t,e){for(var n=y.identity([]);t&&t!==e;)y.mul(n,t.getLocalTransform(),n),t=t.parent;return n},b.applyTransform=function(t,e,n){return n&&(e=y.invert([],e)),x.applyTransform([],t,e)},b.transformDirection=function(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=b.applyTransform(a,e,n),Math.abs(a[0])>Math.abs(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"},t.exports=b},function(t,e){function n(t){return t.replace(/^\s+/,"").replace(/\s+$/,"")}var i={},r=1e-4;i.linearMap=function(t,e,n,i){var r=e[1]-e[0];if(0===r)return(n[0]+n[1])/2;var a=(t-e[0])/r;return i&&(a=Math.min(Math.max(a,0),1)),a*(n[1]-n[0])+n[0]},i.parsePercent=function(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?n(t).match(/%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?NaN:+t},i.round=function(t){return+(+t).toFixed(12)},i.asc=function(t){return t.sort(function(t,e){return t-e}),t},i.getPrecision=function(t){if(isNaN(t))return 0;for(var e=1,n=0;Math.round(t*e)/e!==t;)e*=10,n++;return n},i.getPixelPrecision=function(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);return Math.max(-r+a,0)},i.MAX_SAFE_INTEGER=9007199254740991,i.remRadian=function(t){var e=2*Math.PI;return(t%e+e)%e},i.isRadianAroundZero=function(t){return t>-r&&r>t},i.parseDate=function(t){return t instanceof Date?t:new Date("string"==typeof t?t.replace(/-/g,"/"):Math.round(t))},i.nice=function(t,e){var n,i=Math.floor(Math.log(t)/Math.LN10),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,n*r},t.exports=i},function(t,e){var n="undefined"==typeof Float32Array?Array:Float32Array,i={create:function(t,e){var i=new n(2);return i[0]=t||0,i[1]=e||0,i},copy:function(t,e){return t[0]=e[0],t[1]=e[1],t},clone:function(t){var e=new n(2);return e[0]=t[0],e[1]=t[1],e},set:function(t,e,n){return t[0]=e,t[1]=n,t},add:function(t,e,n){return t[0]=e[0]+n[0],t[1]=e[1]+n[1],t},scaleAndAdd:function(t,e,n,i){return t[0]=e[0]+n[0]*i,t[1]=e[1]+n[1]*i,t},sub:function(t,e,n){return t[0]=e[0]-n[0],t[1]=e[1]-n[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,n){return t[0]=e[0]*n[0],t[1]=e[1]*n[1],t},div:function(t,e,n){return t[0]=e[0]/n[0],t[1]=e[1]/n[1],t},dot:function(t,e){return t[0]*e[0]+t[1]*e[1]},scale:function(t,e,n){return t[0]=e[0]*n,t[1]=e[1]*n,t},normalize:function(t,e){var n=i.len(e);return 0===n?(t[0]=0,t[1]=0):(t[0]=e[0]/n,t[1]=e[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,n,i){return t[0]=e[0]+i*(n[0]-e[0]),t[1]=e[1]+i*(n[1]-e[1]),t},applyTransform:function(t,e,n){var i=e[0],r=e[1];return t[0]=n[0]*i+n[2]*r+n[4],t[1]=n[1]*i+n[3]*r+n[5],t},min:function(t,e,n){return t[0]=Math.min(e[0],n[0]),t[1]=Math.min(e[1],n[1]),t},max:function(t,e,n){return t[0]=Math.max(e[0],n[0]),t[1]=Math.max(e[1],n[1]),t}};i.length=i.len,i.lengthSquare=i.lenSquare,i.dist=i.distance,i.distSquare=i.distanceSquare,t.exports=i},function(t,e,n){function i(t){var e=t.fill;return null!=e&&"none"!==e}function r(t){var e=t.stroke;return null!=e&&"none"!==e&&t.lineWidth>0}function a(t){o.call(this,t),this.path=new h}var o=n(35),s=n(1),h=n(27),l=n(136),u=n(16),c=Math.abs;a.prototype={constructor:a,type:"path",__dirtyPath:!0,strokeContainThreshold:5,brush:function(t){t.save();var e=this.style,n=this.path,a=r(e),o=i(e);this.__dirtyPath&&(o&&e.fill instanceof u&&e.fill.updateCanvasGradient(this,t),a&&e.stroke instanceof u&&e.stroke.updateCanvasGradient(this,t)),e.bind(t,this),this.setTransform(t);var s=e.lineDash,h=e.lineDashOffset,l=!!t.setLineDash;this.__dirtyPath||s&&!l&&a?(n=this.path.beginPath(t),s&&!l&&(n.setLineDash(s),n.setLineDashOffset(h)),this.buildPath(n,this.shape),this.__dirtyPath=!1):(t.beginPath(),this.path.rebuildPath(t)),o&&n.fill(t),s&&l&&(t.setLineDash(s),t.lineDashOffset=h),a&&n.stroke(t),null!=e.text&&this.drawRectText(t,this.getBoundingRect()),t.restore()},buildPath:function(t,e){},getBoundingRect:function(){var t=this._rect,e=this.style;if(!t){var n=this.path;this.__dirtyPath&&(n.beginPath(),this.buildPath(n,this.shape)),t=n.getBoundingRect()}if(r(e)&&(this.__dirty||!this._rect)){var a=this._rectWithStroke||(this._rectWithStroke=t.clone());a.copy(t);var o=e.lineWidth,s=e.strokeNoScale?this.getLineScale():1;return i(e)||(o=Math.max(o,this.strokeContainThreshold)),s>1e-10&&(a.width+=o/s,a.height+=o/s,a.x-=o/s/2,a.y-=o/s/2),a}return this._rect=t,t},contain:function(t,e){var n=this.transformCoordToLocal(t,e),a=this.getBoundingRect(),o=this.style;if(t=n[0],e=n[1],a.contain(t,e)){var s=this.path.data;if(r(o)){var h=o.lineWidth,u=o.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(i(o)||(h=Math.max(h,this.strokeContainThreshold)),l.containStroke(s,h/u,t,e)))return!0}if(i(o))return l.contain(s,t,e)}return!1},dirty:function(t){0===arguments.length&&(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):o.prototype.attrKV.call(this,t,e)},setShape:function(t,e){var n=this.shape;if(n){if(s.isObject(t))for(var i in t)n[i]=t[i];else n[t]=e;this.dirty(!0)}return this},getLineScale:function(){var t=this.transform;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}},a.extend=function(t){var e=function(e){a.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)};s.inherits(e,a);for(var n in t)"style"!==n&&"shape"!==n&&(e.prototype[n]=t[n]);return e},s.inherits(a,o),t.exports=a},function(t,e,n){var i=n(9),r=n(4),a=n(1),o=n(12),s=["x","y","z","radius","angle"],h={};h.createNameEach=function(t,e){t=t.slice();var n=a.map(t,h.capitalFirst);e=(e||[]).slice();var i=a.map(e,h.capitalFirst);return function(r,o){a.each(t,function(t,a){for(var s={name:t,capital:n[a]},h=0;h<e.length;h++)s[e[h]]=t+i[h];r.call(o,s)})}},h.capitalFirst=function(t){return t?t.charAt(0).toUpperCase()+t.substr(1):t},h.eachAxisDim=h.createNameEach(s,["axisIndex","axis","index"]),h.normalizeToArray=function(t){return a.isArray(t)?t:null==t?[]:[t]},h.createLinkedNodesFinder=function(t,e,n){function i(t,e){return a.indexOf(e.nodes,t)>=0}function r(t,i){var r=!1;return e(function(e){a.each(n(t,e)||[],function(t){i.records[e.name][t]&&(r=!0)})}),r}function o(t,i){i.nodes.push(t),e(function(e){a.each(n(t,e)||[],function(t){i.records[e.name][t]=!0})})}return function(n){function a(t){!i(t,s)&&r(t,s)&&(o(t,s),h=!0)}var s={nodes:[],records:{}};if(e(function(t){s.records[t.name]={}}),!n)return s;o(n,s);var h;do h=!1,t(a);while(h);return s}},h.defaultEmphasis=function(t,e){if(t){var n=t.emphasis=t.emphasis||{},i=t.normal=t.normal||{};a.each(e,function(t){var e=a.retrieve(n[t],i[t]);null!=e&&(n[t]=e)})}},h.createDataFormatModel=function(t,e,n){var i=new o;return a.mixin(i,h.dataFormatMixin),i.seriesIndex=t.seriesIndex,i.name=t.name||"",i.getData=function(){return e},i.getRawDataArray=function(){return n},i},h.getDataItemValue=function(t){return t&&(null==t.value?t:t.value)},h.converDataValue=function(t,e){var n=e&&e.type;return"ordinal"===n?t:("time"!==n||isFinite(t)||null==t||"-"===t||(t=+r.parseDate(t)),null==t||""===t?NaN:+t)},h.dataFormatMixin={getDataParams:function(t){var e=this.getData(),n=this.seriesIndex,i=this.name,r=this.getRawValue(t),a=e.getRawIndex(t),o=e.getName(t,!0),s=this.getRawDataArray(),h=s&&s[a];return{seriesIndex:n,seriesName:i,name:o,dataIndex:a,data:h,value:r,$vars:["seriesName","name","value"]}},getFormattedLabel:function(t,e,n){e=e||"normal";var r=this.getData(),a=r.getItemModel(t),o=this.getDataParams(t);return null==n&&(n=a.get(["label",e,"formatter"])),"function"==typeof n?(o.status=e,n(o)):"string"==typeof n?i.formatTpl(n,o):void 0},getRawValue:function(t){var e=this.getData().getItemModel(t);if(e&&null!=e.option){var n=e.option;return a.isObject(n)&&!a.isArray(n)?n.value:n}}},h.mappingToExists=function(t,e){e=(e||[]).slice();var n=a.map(t||[],function(t,e){return{exist:t}});return a.each(e,function(t,i){if(a.isObject(t))for(var r=0;r<n.length;r++){var o=n[r].exist;if(!n[r].option&&(null!=t.id&&o.id===t.id+""||null!=t.name&&!h.isIdInner(t)&&!h.isIdInner(o)&&o.name===t.name+"")){n[r].option=t,e[i]=null;break}}}),a.each(e,function(t,e){if(a.isObject(t)){for(var i=0;i<n.length;i++){var r=n[i].exist;if(!n[i].option&&!h.isIdInner(r)&&null==t.id){n[i].option=t;break}}i>=n.length&&n.push({option:t})}}),n},h.isIdInner=function(t){return a.isObject(t)&&t.id&&0===(t.id+"").indexOf("\x00_ec_\x00")},t.exports=h},function(t,e,n){"use strict";function i(t,e,n,i){this.x=t,this.y=e,this.width=n,this.height=i}var r=n(5),a=n(19),o=r.applyTransform,s=Math.min,h=Math.abs,l=Math.max;i.prototype={constructor:i,union:function(t){var e=s(t.x,this.x),n=s(t.y,this.y);this.width=l(t.x+t.width,this.x+this.width)-e,this.height=l(t.y+t.height,this.y+this.height)-n,this.x=e,this.y=n},applyTransform:function(){var t=[],e=[];return function(n){n&&(t[0]=this.x,t[1]=this.y,e[0]=this.x+this.width,e[1]=this.y+this.height,o(t,t,n),o(e,e,n),this.x=s(t[0],e[0]),this.y=s(t[1],e[1]),this.width=h(e[0]-t[0]),this.height=h(e[1]-t[1]))}}(),calculateTransform:function(t){var e=this,n=t.width/e.width,i=t.height/e.height,r=a.create();return a.translate(r,r,[-e.x,-e.y]),a.scale(r,r,[n,i]),a.translate(r,r,[t.x,t.y]),r},intersect:function(t){var e=this,n=e.x,i=e.x+e.width,r=e.y,a=e.y+e.height,o=t.x,s=t.x+t.width,h=t.y,l=t.y+t.height;return!(o>i||n>s||h>a||r>l)},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 i(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}},t.exports=i},function(t,e,n){function i(t){return isNaN(t)?"-":(t=(t+"").split("."),t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t.length>1?"."+t[1]:""))}function r(t){return t.toLowerCase().replace(/-(.)/g,function(t,e){return e.toUpperCase()})}function a(t){var e=t.length;return"number"==typeof t?[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 o(t){return String(t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function s(t,e){return"{"+t+(null==e?"":e)+"}"}function h(t,e){c.isArray(e)||(e=[e]);var n=e.length;if(!n)return"";for(var i=e[0].$vars,r=0;r<i.length;r++){var a=d[r];t=t.replace(s(a),s(a,0))}for(var o=0;n>o;o++)for(var h=0;h<i.length;h++)t=t.replace(s(d[h],o),e[o][i[h]]);return t}function l(t,e){"week"!==t&&"month"!==t&&"quarter"!==t&&"half-year"!==t&&"year"!==t||(t="MM-dd\nyyyy");var n=f.parseDate(e),i=n.getFullYear(),r=n.getMonth()+1,a=n.getDate(),o=n.getHours(),s=n.getMinutes(),h=n.getSeconds();return t=t.replace("MM",u(r)).toLowerCase().replace("yyyy",i).replace("yy",i%100).replace("dd",u(a)).replace("d",a).replace("hh",u(o)).replace("h",o).replace("mm",u(s)).replace("m",s).replace("ss",u(h)).replace("s",h)}function u(t){return 10>t?"0"+t:t}var c=n(1),f=n(4),d=["a","b","c","d","e","f","g"];t.exports={normalizeCssArray:a,addCommas:i,toCamelCase:r,encodeHTML:o,formatTpl:h,formatTime:l}},function(t,e,n){function i(t){var e=[];return a.each(u.getClassesByMainType(t),function(t){o.apply(e,t.prototype.dependencies||[])}),a.map(e,function(t){return h.parseClassType(t).main})}var r=n(12),a=n(1),o=Array.prototype.push,s=n(41),h=n(20),l=n(11),u=r.extend({type:"component",id:"",name:"",mainType:"",subType:"",componentIndex:0,defaultOption:null,ecModel:null,dependentModels:[],uid:null,layoutMode:null,init:function(t,e,n,i){this.mergeDefaultAndTheme(this.option,this.ecModel)},mergeDefaultAndTheme:function(t,e){var n=this.layoutMode,i=n?l.getLayoutParams(t):{},r=e.getTheme();a.merge(t,r.get(this.mainType)),a.merge(t,this.getDefaultOption()),n&&l.mergeLayoutParam(t,i,n)},mergeOption:function(t){a.merge(this.option,t,!0);var e=this.layoutMode;e&&l.mergeLayoutParam(this.option,t,e)},optionUpdated:function(t){},getDefaultOption:function(){if(!this.hasOwnProperty("__defaultOption")){for(var t=[],e=this.constructor;e;){var n=e.prototype.defaultOption;n&&t.push(n),e=e.superClass}for(var i={},r=t.length-1;r>=0;r--)i=a.merge(i,t[r],!0);this.__defaultOption=i}return this.__defaultOption}});h.enableClassExtend(u,function(t,e,n,i){a.extend(this,i),this.uid=s.getUID("componentModel"),this.setReadOnly(["type","id","uid","name","mainType","subType","dependentModels","componentIndex"])}),h.enableClassManagement(u,{registerWhenExtend:!0}),s.enableSubTypeDefaulter(u),s.enableTopologicalTravel(u,i),a.mixin(u,n(115)),t.exports=u},function(t,e,n){"use strict";function i(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(h,l){var u,c,f=h.position,d=h.getBoundingRect(),p=e.childAt(l+1),g=p&&p.getBoundingRect();if("horizontal"===t){var v=d.width+(g?-g.x+d.x:0);u=a+v,u>i||h.newline?(a=0,u=v,o+=s+n,s=d.height):s=Math.max(s,d.height)}else{var m=d.height+(g?-g.y+d.y:0);c=o+m,c>r||h.newline?(a+=s+n,o=0,c=m,s=d.width):s=Math.max(s,d.width)}h.newline||(f[0]=a,f[1]=o,"horizontal"===t?a=u+n:o=c+n)})}var r=n(1),a=n(8),o=n(4),s=n(9),h=o.parsePercent,l=r.each,u={},c=["left","right","top","bottom","width","height"];u.box=i,u.vbox=r.curry(i,"vertical"),u.hbox=r.curry(i,"horizontal"),u.getAvailableSize=function(t,e,n){var i=e.width,r=e.height,a=h(t.x,i),o=h(t.y,r),l=h(t.x2,i),u=h(t.y2,r);return(isNaN(a)||isNaN(parseFloat(t.x)))&&(a=0),(isNaN(l)||isNaN(parseFloat(t.x2)))&&(l=i),(isNaN(o)||isNaN(parseFloat(t.y)))&&(o=0),(isNaN(u)||isNaN(parseFloat(t.y2)))&&(u=r),n=s.normalizeCssArray(n||0),{width:Math.max(l-a-n[1]-n[3],0),height:Math.max(u-o-n[0]-n[2],0)}},u.getLayoutRect=function(t,e,n){n=s.normalizeCssArray(n||0);var i=e.width,r=e.height,o=h(t.left,i),l=h(t.top,r),u=h(t.right,i),c=h(t.bottom,r),f=h(t.width,i),d=h(t.height,r),p=n[2]+n[0],g=n[1]+n[3],v=t.aspect;switch(isNaN(f)&&(f=i-u-g-o),isNaN(d)&&(d=r-c-p-l),isNaN(f)&&isNaN(d)&&(v>i/r?f=.8*i:d=.8*r),null!=v&&(isNaN(f)&&(f=v*d),isNaN(d)&&(d=f/v)),isNaN(o)&&(o=i-u-f-g),isNaN(l)&&(l=r-c-d-p),t.left||t.right){case"center":o=i/2-f/2-n[3];break;case"right":o=i-f-g}switch(t.top||t.bottom){case"middle":case"center":l=r/2-d/2-n[0];break;case"bottom":l=r-d-p}o=o||0,l=l||0,isNaN(f)&&(f=i-o-(u||0)),isNaN(d)&&(d=r-l-(c||0));var m=new a(o+n[3],l+n[0],f,d);return m.margin=n,m},u.positionGroup=function(t,e,n,i){var a=t.getBoundingRect();e=r.extend(r.clone(e),{width:a.width,height:a.height}),e=u.getLayoutRect(e,n,i),t.position=[e.x-a.x,e.y-a.y]},u.mergeLayoutParam=function(t,e,n){function i(i){var r={},s=0,h={},u=0,c=n.ignoreSize?1:2;if(l(i,function(e){h[e]=t[e]}),l(i,function(t){a(e,t)&&(r[t]=h[t]=e[t]),o(r,t)&&s++,o(h,t)&&u++}),u!==c&&s){if(s>=c)return r;for(var f=0;f<i.length;f++){var d=i[f];if(!a(r,d)&&a(t,d)){r[d]=t[d];break}}return r}return h}function a(t,e){return t.hasOwnProperty(e)}function o(t,e){return null!=t[e]&&"auto"!==t[e]}function s(t,e,n){l(t,function(t){e[t]=n[t]})}!r.isObject(n)&&(n={});var h=["width","left","right"],u=["height","top","bottom"],c=i(h),f=i(u);s(h,t,c),s(u,t,f)},u.getLayoutParams=function(t){return u.copyLayoutParams({},t)},u.copyLayoutParams=function(t,e){return e&&t&&l(c,function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t},t.exports=u},function(t,e,n){function i(t,e,n,i){this.parentModel=e,this.ecModel=n,this.option=t,this.init&&(arguments.length<=4?this.init(t,e,n,i):this.init.apply(this,arguments))}var r=n(1),a=n(20);i.prototype={constructor:i,init:null,mergeOption:function(t){r.merge(this.option,t,!0)},get:function(t,e){if(!t)return this.option;"string"==typeof t&&(t=t.split("."));for(var n=this.option,i=this.parentModel,r=0;r<t.length&&(n=n&&"object"==typeof n?n[t[r]]:null,null!=n);r++);return null==n&&i&&!e&&(n=i.get(t)),n},getShallow:function(t,e){var n=this.option,i=n&&n[t],r=this.parentModel;return null==i&&r&&!e&&(i=r.getShallow(t)),i},getModel:function(t,e){var n=this.get(t,!0),r=this.parentModel,a=new i(n,e||r&&r.getModel(t),this.ecModel);return a},isEmpty:function(){return null==this.option},restoreData:function(){},clone:function(){var t=this.constructor;return new t(r.clone(this.option))},setReadOnly:function(t){a.setReadOnly(this,t)}},a.enableClassExtend(i);var o=r.mixin;o(i,n(117)),o(i,n(114)),o(i,n(118)),o(i,n(116)),t.exports=i},function(t,e,n){"use strict";var i=n(1),r=n(9),a=n(7),o=n(10),s=r.encodeHTML,h=r.addCommas,l=o.extend({type:"series",seriesIndex:0,coordinateSystem:null,defaultOption:null,legendDataProvider:null,init:function(t,e,n,i){this.seriesIndex=this.componentIndex,this.mergeDefaultAndTheme(t,n),this._dataBeforeProcessed=this.getInitialData(t,n),this._data=this._dataBeforeProcessed.cloneShallow()},mergeDefaultAndTheme:function(t,e){i.merge(t,e.getTheme().get(this.subType)),i.merge(t,this.getDefaultOption()),a.defaultEmphasis(t.label,["position","show","textStyle","distance","formatter"]);for(var n=t.data||[],r=0;r<n.length;r++)n[r]&&n[r].label&&a.defaultEmphasis(n[r].label,["position","show","textStyle","distance","formatter"])},mergeOption:function(t,e){t=i.merge(this.option,t,!0);var n=this.getInitialData(t,e);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.option.data},coordDimToDataDim:function(t){return[t]},dataDimToCoordDim:function(t){return t},getBaseAxis:function(){var t=this.coordinateSystem;return t&&t.getBaseAxis&&t.getBaseAxis()},formatTooltip:function(t,e){var n=this._data,r=this.getRawValue(t),a=i.isArray(r)?i.map(r,h).join(", "):h(r),o=n.getName(t);return e?s(this.name)+" : "+a:s(this.name)+"<br />"+(o?s(o)+" : "+a:a)},restoreData:function(){this._data=this._dataBeforeProcessed.cloneShallow()}});i.mixin(l,a.dataFormatMixin),t.exports=l},function(t,e,n){(function(e){function i(t){return f.isArray(t)||(t=[t]),t}function r(t,e){var n=t.dimensions,i=new m(f.map(n,t.getDimensionInfo,t),t.hostModel);v(i,t,t._wrappedMethods);for(var r=i._storage={},a=t._storage,o=0;o<n.length;o++){var s=n[o],h=a[s];f.indexOf(e,s)>=0?r[s]=new h.constructor(a[s].length):r[s]=a[s]}return i}var a="undefined",o="undefined"==typeof window?e:window,s=typeof o.Float64Array===a?Array:o.Float64Array,h=typeof o.Int32Array===a?Array:o.Int32Array,l={"float":s,"int":h,ordinal:Array,number:Array,time:Array},u=n(12),c=n(52),f=n(1),d=n(7),p=f.isObject,g=["stackedOn","_nameList","_idList","_rawData"],v=function(t,e,n){f.each(g.concat(n||[]),function(n){e.hasOwnProperty(n)&&(t[n]=e[n])})},m=function(t,e){t=t||["x","y"];for(var n={},i=[],r=0;r<t.length;r++){var a,o={};"string"==typeof t[r]?(a=t[r],o={name:a,stackable:!1,type:"number"}):(o=t[r],a=o.name,o.type=o.type||"number"),i.push(a),n[a]=o}this.dimensions=i,this._dimensionInfos=n,this.hostModel=e,this.indices=[],this._storage={},this._nameList=[],this._idList=[],this._optionModels=[],this.stackedOn=null,this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._rawData,this._extent},y=m.prototype;y.type="list",y.getDimension=function(t){return isNaN(t)||(t=this.dimensions[t]||t),t},y.getDimensionInfo=function(t){return f.clone(this._dimensionInfos[this.getDimension(t)])},y.initData=function(t,e,n){t=t||[],this._rawData=t;var i=this._storage={},r=this.indices=[],a=this.dimensions,o=t.length,s=this._dimensionInfos,h=[],u={};e=e||[];for(var c=0;c<a.length;c++){var p=s[a[c]],g=l[p.type];i[a[c]]=new g(o)}n=n||function(t,e,n,i){var r=d.getDataItemValue(t);return d.converDataValue(f.isArray(r)?r[i]:r,s[e])};for(var v=0;v<t.length;v++){for(var m=t[v],y=0;y<a.length;y++){var x=a[y],_=i[x];_[v]=n(m,x,v,y)}r.push(v)}for(var c=0;c<t.length;c++){var b="";e[c]||(e[c]=t[c].name,b=t[c].id);var w=e[c]||"";!b&&w&&(u[w]=u[w]||0,b=w,u[w]>0&&(b+="__ec__"+u[w]),u[w]++),b&&(h[c]=b)}this._nameList=e,this._idList=h},y.count=function(){return this.indices.length},y.get=function(t,e,n){var i=this._storage,r=this.indices[e];if(null==r)return NaN;var a=i[t]&&i[t][r];if(n){var o=this._dimensionInfos[t];if(o&&o.stackable)for(var s=this.stackedOn;s;){var h=s.get(t,e);(a>=0&&h>0||0>=a&&0>h)&&(a+=h),s=s.stackedOn}}return a},y.getValues=function(t,e,n){var i=[];f.isArray(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},y.hasValue=function(t){for(var e=this.dimensions,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},y.getDataExtent=function(t,e){var n=this._storage[t],i=this.getDimensionInfo(t);e=i&&i.stackable&&e;var r,a=(this._extent||(this._extent={}))[t+!!e];if(a)return a;if(n){for(var o=1/0,s=-(1/0),h=0,l=this.count();l>h;h++)r=this.get(t,h,e),o>r&&(o=r),r>s&&(s=r);return this._extent[t+e]=[o,s]}return[1/0,-(1/0)]},y.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},y.indexOf=function(t,e){var n=this._storage,i=n[t],r=this.indices;if(i)for(var a=0,o=r.length;o>a;a++){var s=r[a];if(i[s]===e)return a;
}return-1},y.indexOfName=function(t){for(var e=this.indices,n=this._nameList,i=0,r=e.length;r>i;i++){var a=e[i];if(n[a]===t)return i}return-1},y.indexOfNearest=function(t,e,n){var i=this._storage,r=i[t];if(r){for(var a=Number.MAX_VALUE,o=-1,s=0,h=this.count();h>s;s++){var l=Math.abs(this.get(t,s,n)-e);a>=l&&(a=l,o=s)}return o}return-1},y.getRawIndex=function(t){var e=this.indices[t];return null==e?-1:e},y.getName=function(t){return this._nameList[this.indices[t]]||""},y.getId=function(t){return this._idList[this.indices[t]]||this.getRawIndex(t)+""},y.each=function(t,e,n,r){"function"==typeof t&&(r=n,n=e,e=t,t=[]),t=f.map(i(t),this.getDimension,this);var a=[],o=t.length,s=this.indices;r=r||this;for(var h=0;h<s.length;h++)if(0===o)e.call(r,h);else if(1===o)e.call(r,this.get(t[0],h,n),h);else{for(var l=0;o>l;l++)a[l]=this.get(t[l],h,n);a[l]=h,e.apply(r,a)}},y.filterSelf=function(t,e,n,r){"function"==typeof t&&(r=n,n=e,e=t,t=[]),t=f.map(i(t),this.getDimension,this);var a=[],o=[],s=t.length,h=this.indices;r=r||this;for(var l=0;l<h.length;l++){var u;if(1===s)u=e.call(r,this.get(t[0],l,n),l);else{for(var c=0;s>c;c++)o[c]=this.get(t[c],l,n);o[c]=l,u=e.apply(r,o)}u&&a.push(h[l])}return this.indices=a,this._extent={},this},y.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},y.map=function(t,e,n,a){t=f.map(i(t),this.getDimension,this);var o=r(this,t),s=o.indices=this.indices,h=o._storage,l=[];return this.each(t,function(){var n=arguments[arguments.length-1],i=e&&e.apply(this,arguments);if(null!=i){"number"==typeof i&&(l[0]=i,i=l);for(var r=0;r<i.length;r++){var a=t[r],o=h[a],u=s[n];o&&(o[u]=i[r])}}},n,a),o},y.downSample=function(t,e,n,i){for(var a=r(this,[t]),o=this._storage,s=a._storage,h=this.indices,l=a.indices=[],u=[],c=[],f=Math.floor(1/e),d=s[t],p=this.count(),g=0;g<o[t].length;g++)s[t][g]=o[t][g];for(var g=0;p>g;g+=f){f>p-g&&(f=p-g,u.length=f);for(var v=0;f>v;v++){var m=h[g+v];u[v]=d[m],c[v]=m}var y=n(u),m=c[i(u,y)||0];d[m]=y,l.push(m)}return a},y.getItemModel=function(t){var e=this.hostModel;return t=this.indices[t],new u(this._rawData[t],e,e.ecModel)},y.diff=function(t){var e=this._idList,n=t&&t._idList;return new c(t?t.indices:[],this.indices,function(t){return n[t]||t+""},function(t){return e[t]||t+""})},y.getVisual=function(t){var e=this._visual;return e&&e[t]},y.setVisual=function(t,e){if(p(t))for(var n in t)t.hasOwnProperty(n)&&this.setVisual(n,t[n]);else this._visual=this._visual||{},this._visual[t]=e},y.setLayout=function(t,e){if(p(t))for(var n in t)t.hasOwnProperty(n)&&this.setLayout(n,t[n]);else this._layout[t]=e},y.getLayout=function(t){return this._layout[t]},y.getItemLayout=function(t){return this._itemLayouts[t]},y.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?f.extend(this._itemLayouts[t]||{},e):e},y.getItemVisual=function(t,e,n){var i=this._itemVisuals[t],r=i&&i[e];return null!=r||n?r:this.getVisual(e)},y.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{};if(this._itemVisuals[t]=i,p(e))for(var r in e)e.hasOwnProperty(r)&&(i[r]=e[r]);else i[e]=n};var x=function(t){t.seriesIndex=this.seriesIndex,t.dataIndex=this.dataIndex};y.setItemGraphicEl=function(t,e){var n=this.hostModel;e&&(e.dataIndex=t,e.seriesIndex=n&&n.seriesIndex,"group"===e.type&&e.traverse(x,e)),this._graphicEls[t]=e},y.getItemGraphicEl=function(t){return this._graphicEls[t]},y.eachItemGraphicEl=function(t,e){f.each(this._graphicEls,function(n,i){n&&t&&t.call(e,n,i)})},y.cloneShallow=function(){var t=f.map(this.dimensions,this.getDimensionInfo,this),e=new m(t,this.hostModel);return e._storage=this._storage,v(e,this,this._wrappedMethods),e.indices=this.indices.slice(),e},y.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.call(this,t)})},t.exports=m}).call(e,function(){return this}())},function(t,e){function n(t){var e={},n={},i=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_]+)/),h=t.match(/(webOS|hpwOS)[\s\/]([\d.]+)/),l=h&&t.match(/TouchPad/),u=t.match(/Kindle\/([\d.]+)/),c=t.match(/Silk\/([\d._]+)/),f=t.match(/(BlackBerry).*Version\/([\d.]+)/),d=t.match(/(BB10).*Version\/([\d.]+)/),p=t.match(/(RIM\sTablet\sOS)\s([\d.]+)/),g=t.match(/PlayBook/),v=t.match(/Chrome\/([\d.]+)/)||t.match(/CriOS\/([\d.]+)/),m=t.match(/Firefox\/([\d.]+)/),y=i&&t.match(/Mobile\//)&&!v,x=t.match(/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/)&&!v,_=t.match(/MSIE\s([\d.]+)/)||t.match(/Trident\/.+?rv:(([\d.]+))/),b=t.match(/Edge\/([\d.]+)/);return(n.webkit=!!i)&&(n.version=i[1]),r&&(e.android=!0,e.version=r[2]),s&&!o&&(e.ios=e.iphone=!0,e.version=s[2].replace(/_/g,".")),a&&(e.ios=e.ipad=!0,e.version=a[2].replace(/_/g,".")),o&&(e.ios=e.ipod=!0,e.version=o[3]?o[3].replace(/_/g,"."):null),h&&(e.webos=!0,e.version=h[2]),l&&(e.touchpad=!0),f&&(e.blackberry=!0,e.version=f[2]),d&&(e.bb10=!0,e.version=d[2]),p&&(e.rimtabletos=!0,e.version=p[2]),g&&(n.playbook=!0),u&&(e.kindle=!0,e.version=u[1]),c&&(n.silk=!0,n.version=c[1]),!c&&e.android&&t.match(/Kindle Fire/)&&(n.silk=!0),v&&(n.chrome=!0,n.version=v[1]),m&&(n.firefox=!0,n.version=m[1]),_&&(n.ie=!0,n.version=_[1]),y&&(t.match(/Safari/)||e.ios)&&(n.safari=!0),x&&(n.webview=!0),_&&(n.ie=!0,n.version=_[1]),b&&(n.edge=!0,n.version=b[1]),e.tablet=!!(a||g||r&&!t.match(/Mobile/)||m&&t.match(/Tablet/)||_&&!t.match(/Phone/)&&t.match(/Touch/)),e.phone=!(e.tablet||e.ipod||!(r||s||h||f||d||v&&t.match(/Android/)||v&&t.match(/CriOS\/([\d.]+)/)||m&&t.match(/Mobile/)||_&&t.match(/Touch/))),{browser:n,os:e,node:!1,canvasSupported:!!document.createElement("canvas").getContext,touchEventsSupported:"ontouchstart"in window&&!n.ie&&!n.edge,pointerEventsSupported:"onpointerdown"in window&&(n.edge||n.ie&&n.version>=10)}}var i={};i="undefined"==typeof navigator?{browser:{},os:{},node:!0,canvasSupported:!0}:n(navigator.userAgent),t.exports=i},function(t,e){var n=function(t){this.colorStops=t||[]};n.prototype={constructor:n,addColorStop:function(t,e){this.colorStops.push({offset:t,color:e})}},t.exports=n},function(t,e,n){function i(t,e){var n=t+":"+e;if(l[n])return l[n];for(var i=(t+"").split("\n"),r=0,a=0,o=i.length;o>a;a++)r=Math.max(p.measureText(i[a],e).width,r);return u>c&&(u=0,l={}),u++,l[n]=r,r}function r(t,e,n,r){var a=((t||"")+"").split("\n").length,o=i(t,e),s=i("国",e),h=a*s,l=new d(0,0,o,h);switch(l.lineHeight=s,r){case"bottom":case"alphabetic":l.y-=s;break;case"middle":l.y-=s/2}switch(n){case"end":case"right":l.x-=l.width;break;case"center":l.x-=l.width/2}return l}function a(t,e,n,i){var r=e.x,a=e.y,o=e.height,s=e.width,h=n.height,l=o/2-h/2,u="left";switch(t){case"left":r-=i,a+=l,u="right";break;case"right":r+=i+s,a+=l,u="left";break;case"top":r+=s/2,a-=i+h,u="center";break;case"bottom":r+=s/2,a+=o+i,u="center";break;case"inside":r+=s/2,a+=l,u="center";break;case"insideLeft":r+=i,a+=l,u="left";break;case"insideRight":r+=s-i,a+=l,u="right";break;case"insideTop":r+=s/2,a+=i,u="center";break;case"insideBottom":r+=s/2,a+=o-h-i,u="center";break;case"insideTopLeft":r+=i,a+=i,u="left";break;case"insideTopRight":r+=s-i,a+=i,u="right";break;case"insideBottomLeft":r+=i,a+=o-h-i;break;case"insideBottomRight":r+=s-i,a+=o-h-i,u="right"}return{x:r,y:a,textAlign:u,textBaseline:"top"}}function o(t,e,n,r){if(!n)return"";r=f.defaults({ellipsis:"...",minCharacters:3,maxIterations:3,cnCharWidth:i("国",e),ascCharWidth:i("a",e)},r,!0),n-=i(r.ellipsis);for(var a=(t+"").split("\n"),o=0,h=a.length;h>o;o++)a[o]=s(a[o],e,n,r);return a.join("\n")}function s(t,e,n,r){for(var a=0;;a++){var o=i(t,e);if(n>o||a>=r.maxIterations){t+=r.ellipsis;break}var s=0===a?h(t,n,r):Math.floor(t.length*n/o);if(s<r.minCharacters){t="";break}t=t.substr(0,s)}return t}function h(t,e,n){for(var i=0,r=0,a=t.length;a>r&&e>i;r++){var o=t.charCodeAt(r);i+=o>=0&&127>=o?n.ascCharWidth:n.cnCharWidth}return r}var l={},u=0,c=5e3,f=n(1),d=n(8),p={getWidth:i,getBoundingRect:r,adjustTextPositionOnRect:a,ellipsis:o,measureText:function(t,e){var n=f.getContext();return n.font=e,n.measureText(t)}};t.exports=p},function(t,e,n){"use strict";function i(t){return t>-w&&w>t}function r(t){return t>w||-w>t}function a(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 o(t,e,n,i,r){var a=1-r;return 3*(((e-t)*a+2*(n-e)*r)*a+(i-n)*r*r)}function s(t,e,n,r,a,o){var s=r+3*(e-n)-t,h=3*(n-2*e+t),l=3*(e-t),u=t-a,c=h*h-3*s*l,f=h*l-9*s*u,d=l*l-3*h*u,p=0;if(i(c)&&i(f))if(i(h))o[0]=0;else{var g=-l/h;g>=0&&1>=g&&(o[p++]=g)}else{var v=f*f-4*c*d;if(i(v)){var m=f/c,g=-h/s+m,y=-m/2;g>=0&&1>=g&&(o[p++]=g),y>=0&&1>=y&&(o[p++]=y)}else if(v>0){var x=b(v),w=c*h+1.5*s*(-f+x),C=c*h+1.5*s*(-f-x);w=0>w?-_(-w,S):_(w,S),C=0>C?-_(-C,S):_(C,S);var g=(-h-(w+C))/(3*s);g>=0&&1>=g&&(o[p++]=g)}else{var T=(2*c*h-3*s*f)/(2*b(c*c*c)),A=Math.acos(T)/3,I=b(c),k=Math.cos(A),g=(-h-2*I*k)/(3*s),y=(-h+I*(k+M*Math.sin(A)))/(3*s),L=(-h+I*(k-M*Math.sin(A)))/(3*s);g>=0&&1>=g&&(o[p++]=g),y>=0&&1>=y&&(o[p++]=y),L>=0&&1>=L&&(o[p++]=L)}}return p}function h(t,e,n,a,o){var s=6*n-12*e+6*t,h=9*e+3*a-3*t-9*n,l=3*e-3*t,u=0;if(i(h)){if(r(s)){var c=-l/s;c>=0&&1>=c&&(o[u++]=c)}}else{var f=s*s-4*h*l;if(i(f))o[0]=-s/(2*h);else if(f>0){var d=b(f),c=(-s+d)/(2*h),p=(-s-d)/(2*h);c>=0&&1>=c&&(o[u++]=c),p>=0&&1>=p&&(o[u++]=p)}}return u}function l(t,e,n,i,r,a){var o=(e-t)*r+t,s=(n-e)*r+e,h=(i-n)*r+n,l=(s-o)*r+o,u=(h-s)*r+s,c=(u-l)*r+l;a[0]=t,a[1]=o,a[2]=l,a[3]=c,a[4]=c,a[5]=u,a[6]=h,a[7]=i}function u(t,e,n,i,r,o,s,h,l,u,c){var f,d,p,g,v,m=.005,y=1/0;C[0]=l,C[1]=u;for(var _=0;1>_;_+=.05)T[0]=a(t,n,r,s,_),T[1]=a(e,i,o,h,_),g=x(C,T),y>g&&(f=_,y=g);y=1/0;for(var M=0;32>M&&!(w>m);M++)d=f-m,p=f+m,T[0]=a(t,n,r,s,d),T[1]=a(e,i,o,h,d),g=x(T,C),d>=0&&y>g?(f=d,y=g):(A[0]=a(t,n,r,s,p),A[1]=a(e,i,o,h,p),v=x(A,C),1>=p&&y>v?(f=p,y=v):m*=.5);return c&&(c[0]=a(t,n,r,s,f),c[1]=a(e,i,o,h,f)),b(y)}function c(t,e,n,i){var r=1-i;return r*(r*t+2*i*e)+i*i*n}function f(t,e,n,i){return 2*((1-i)*(e-t)+i*(n-e))}function d(t,e,n,a,o){var s=t-2*e+n,h=2*(e-t),l=t-a,u=0;if(i(s)){if(r(h)){var c=-l/h;c>=0&&1>=c&&(o[u++]=c)}}else{var f=h*h-4*s*l;if(i(f)){var c=-h/(2*s);c>=0&&1>=c&&(o[u++]=c)}else if(f>0){var d=b(f),c=(-h+d)/(2*s),p=(-h-d)/(2*s);c>=0&&1>=c&&(o[u++]=c),p>=0&&1>=p&&(o[u++]=p)}}return u}function p(t,e,n){var i=t+n-2*e;return 0===i?.5:(t-e)/i}function g(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 v(t,e,n,i,r,a,o,s,h){var l,u=.005,f=1/0;C[0]=o,C[1]=s;for(var d=0;1>d;d+=.05){T[0]=c(t,n,r,d),T[1]=c(e,i,a,d);var p=x(C,T);f>p&&(l=d,f=p)}f=1/0;for(var g=0;32>g&&!(w>u);g++){var v=l-u,m=l+u;T[0]=c(t,n,r,v),T[1]=c(e,i,a,v);var p=x(T,C);if(v>=0&&f>p)l=v,f=p;else{A[0]=c(t,n,r,m),A[1]=c(e,i,a,m);var y=x(A,C);1>=m&&f>y?(l=m,f=y):u*=.5}}return h&&(h[0]=c(t,n,r,l),h[1]=c(e,i,a,l)),b(f)}var m=n(5),y=m.create,x=m.distSquare,_=Math.pow,b=Math.sqrt,w=1e-4,M=b(3),S=1/3,C=y(),T=y(),A=y();t.exports={cubicAt:a,cubicDerivativeAt:o,cubicRootAt:s,cubicExtrema:h,cubicSubdivide:l,cubicProjectPoint:u,quadraticAt:c,quadraticDerivativeAt:f,quadraticRootAt:d,quadraticExtremum:p,quadraticSubdivide:g,quadraticProjectPoint:v}},function(t,e){var n="unde