echarts.js 240 KB

1
  1. var define,require,esl;!function(g){function f(h,c){function n(h){0===h.indexOf(".")&&a.push(h)}var a=[];if("string"==typeof h?n(h):w(h,function(h){n(h)}),0<a.length)throw Error("[REQUIRE_FATAL]Relative ID is not allowed in global require: "+a.join(", "));var t=L.waitSeconds;return t&&h instanceof Array&&(A&&clearTimeout(A),A=setTimeout(q,1E3*t)),Q(h,c)}function q(){function h(k,b){if(!u[k]&&!p(k,P)){u[k]=1;p(k,O)||a[k]||(a[k]=1,c.push(k));var e=F[k];e?b&&(a[k]||(a[k]=1,c.push(k)),w(e.depMs,function(c){h(c.absId,c.hard)})):t[k]||(t[k]=1,n.push(k))}}var c=[],n=[],a={},t={},u={},k;for(k in J)h(k,1);if(c.length||n.length)throw Error("[MODULE_TIMEOUT]Hang( "+(c.join(", ")||"none")+" ) Miss( "+(n.join(", ")||"none")+" )");}function l(h){w(S,function(c){a(h,c.deps,c.factory)});S.length=0}function d(h,c,n){if(null==n&&(null==c?(n=h,h=null):(n=c,c=null,h instanceof Array&&(c=h,h=null))),null!=n){var t=window.opera;h||!document.attachEvent||t&&"[object Opera]"===t.toString()||(h=(h=y())&&h.getAttribute("data-require-id"));h?a(h,c,n):S[0]={deps:c,factory:n}}}function b(){var h=L.config[this.id];return h&&"object"==typeof h?h:{}}function a(h,c,n){F[h]||(F[h]={id:h,depsDec:c,deps:c||["require","exports","module"],factoryDeps:[],factory:n,exports:{},config:b,state:N,require:D(h),depMs:[],depMkv:{},depRs:[]})}function e(c){var n=F[c];if(n&&!p(c,x)){var a=n.deps,t=n.factory,u=0;"function"==typeof t&&(u=Math.min(t.length,a.length),!n.depsDec&&t.toString().replace(/(\/\*([\s\S]*?)\*\/|([^:]|^)\/\/(.*)$)/gm,"").replace(/require\(\s*(['"'])([^'"]+)\1\s*\)/g,function(h,c,n){a.push(n)}));var e=[],b=[];w(a,function(h,a){var t,k,d=C(h),p=G(d.mod,c);p&&!R[p]?(d.res&&(k={id:h,mod:p,res:d.res},b.push(h),n.depRs.push(k)),t=n.depMkv[p],t||(t={id:d.mod,absId:p,hard:u>a},n.depMs.push(t),n.depMkv[p]=t,e.push(p))):t={absId:p};u>a&&n.factoryDeps.push(k||t)});n.state=x;k(c);h(e);b.length&&n.require(b,function(){w(n.depRs,function(h){h.absId||(h.absId=G(h.id,c))});m()})}}function m(){for(var h in J)e(h),r(h),c(h)}function r(h){function c(h){if(e(h),!p(h,x))return!1;if(p(h,O)||n[h])return!0;n[h]=1;h=F[h];var a=!0;return w(h.depMs,function(h){return a=c(h.absId)}),a&&w(h.depRs,function(h){return a=!!h.absId}),a&&(h.state=O),a}var n={};c(h)}function k(h){var a,u=F[h];u.invokeFactory=function(){if(!a&&u.state===O){var k=a=1;if(w(u.factoryDeps,function(h){h=h.absId;return R[h]?void 0:(c(h),k=p(h,P))}),k){try{var b=u.factory,e="function"==typeof b?b.apply(g,t(u.factoryDeps,{require:u.require,exports:u.exports,module:u})):b;null!=e&&(u.exports=e);u.invokeFactory=null}catch(d){if(/^\[MODULE_MISS\]"([^"]+)/.test(d.message))return b=u.depMkv[RegExp.$1],b&&(b.hard=1),void(a=0);throw d;}n(h)}}}}function p(h,c){return F[h]&&F[h].state>=c}function c(h){(h=F[h])&&h.invokeFactory&&h.invokeFactory()}function t(h,c){var n=[];return w(h,function(h,a){"object"==typeof h&&(h=h.absId);n[a]=c[h]||F[h].exports}),n}function n(h){F[h].state=P;delete J[h];for(var c=T[h]||[],n=c.length;n--;)c[n]();c.length=0;T[h]=null}function h(h,c,n){function a(){if("function"==typeof c&&!k){var n=1;w(h,function(h){return R[h]?void 0:n=!!p(h,P)});n&&(k=1,c.apply(g,t(h,R)))}}var k=0;w(h,function(h){if(!R[h]&&!p(h,P)){if(p(h,P))a();else{var c=T[h];c||(c=T[h]=[]);c.push(a)}(0<h.indexOf("!")?B:u)(h,n)}});a()}function u(h){function c(){v(V[h]||h,n)}function n(){if(a){var c;"function"==typeof a.init&&(c=a.init.apply(g,t(u,R)));null==c&&a.exports&&(c=g,w(a.exports.split("."),function(h){return c=c[h],!!c}));d(h,u,c||{})}else l(h);m()}if(!W[h]&&!F[h]){W[h]=1;var a=L.shim[h];a instanceof Array&&(L.shim[h]=a={deps:a});var u=a&&(a.deps||[]);u?(w(u,function(h){L.shim[h]||(L.shim[h]={})}),Q(u,c)):c()}}function B(h,c){function a(c){d.exports=c||!0;n(h)}function t(n){n.load(e.res,c?F[c].require:Q,a,b.call({id:h}))}if(!F[h]){var k=V[h];if(k)return void u(k);var e=C(h),d={id:h,state:x};F[h]=d;a.fromText=function(h,c){(new Function(c))();l(h)};t(Q(e.mod))}}function z(h,c){var n=[],a;for(a in h)if(h.hasOwnProperty(a)){var t={k:a,v:h[a]};n.push(t);t.reg="*"===a&&c?/^/:new RegExp("^"+a+"(/|$)")}return n.sort(E),n}function I(){function h(n){V[n]=c}L.baseUrl=L.baseUrl.replace(/\/$/,"")+"/";U=z(L.paths);ba=z(L.map,1);w(ba,function(h){h.v=z(h.v)});X=[];w(L.packages,function(h){var c=h;"string"==typeof h&&(c={name:h.split("/")[0],location:h,main:"main"});c.location=c.location||c.name;c.main=(c.main||"main").replace(/\.js$/i,"");c.reg=new RegExp("^"+c.name+"(/|$)");X.push(c)});X.sort(E);da=z(L.urlArgs,1);V={};for(var c in L.bundles)w(L.bundles[c],h)}function H(h,c,n){w(c,function(c){return c.reg.test(h)?(n(c.v,c.k,c),!1):void 0})}function M(h){var c=/(\.[a-z0-9]+)$/i,n=/(\?[^#]*)$/,a="",t=h,u="";n.test(h)&&(u=RegExp.$1,h=h.replace(n,""));c.test(h)&&(a=RegExp.$1,t=h.replace(c,""));var k,b=t;return H(t,U,function(h,c){b=b.replace(c,h);k=1}),k||H(t,X,function(h,c,n){b=b.replace(n.name,n.location)}),/^([a-z]{2,10}:\/)?\//i.test(b)||(b=L.baseUrl+b),b+=a+u,H(t,da,function(h){b+=(0<b.indexOf("?")?"\x26":"?")+h}),b}function D(n){function a(u,k){if("string"==typeof u){if(!t[u]){var b=G(u,n);if(c(b),!p(b,P))throw Error('[MODULE_MISS]"'+b+'" is not exists!');t[u]=F[b].exports}return t[u]}if(u instanceof Array){var e=[],d=[];w(u,function(h,c){var a=C(h),t=G(a.mod,n),a=a.res,u=t;if(a){var k=t+"!"+a;0!==a.indexOf(".")&&V[k]?t=u=k:u=null}d[c]=u;a=t;p(a,P)||(J[a]=1);e.push(t)});h(e,function(){w(d,function(h,c){if(null==h){var a=h=d[c]=G(u[c],n);p(a,P)||(J[a]=1)}});h(d,k,n);m()},n);m()}}var t={};return a.toUrl=function(h){return M(G(h,n))},a}function G(h,c){if(!h)return"";c=c||"";var n=C(h);if(!n)return h;var a=n.res,t=K(n.mod,c);if(w(X,function(h){var c=h.name;return c===t?(t=c+"/"+h.main,!1):void 0}),H(c,ba,function(h){H(t,h,function(h,c){t=t.replace(c,h)})}),a)a=(n=p(t,P)&&Q(t))&&n.normalize?n.normalize(a,function(h){return G(h,c)}):G(a,c),t+="!"+a;return t}function K(h,c){if(0===h.indexOf(".")){var n=c.split("/"),a=h.split("/"),t=n.length-1,u=a.length,k=0,b=0,e=0;a:for(;u>e;e++)switch(a[e]){case "..":if(!(t>k))break a;k++;b++;break;case ".":b++;break;default:break a}return n.length=t-k,a=a.slice(b),n.concat(a).join("/")}return h}function C(h){h=h.split("!");return h[0]?{mod:h[0],res:h[1]}:void 0}function y(){if(Y)return Y;if(Z&&"interactive"===Z.readyState)return Z;for(var h=document.getElementsByTagName("script"),c=h.length;c--;){var n=h[c];if("interactive"===n.readyState)return Z=n,n}}function v(h,c){function n(){var h=a.readyState;("undefined"==typeof h||/^(loaded|complete)$/.test(h))&&(a.onload=a.onreadystatechange=null,a=null,c())}var a=document.createElement("script");a.setAttribute("data-require-id",h);a.src=M(h+".js");a.async=!0;a.readyState?a.onreadystatechange=n:a.onload=n;Y=a;aa?ca.insertBefore(a,aa):ca.appendChild(a);Y=null}function w(h,c){if(h instanceof Array)for(var n=0,a=h.length;a>n&&!1!==c(h[n],n);n++);}function E(h,c){var n=h.k||h.name,a=c.k||c.name;return"*"===a?-1:"*"===n?1:a.length-n.length}var A,F={},N=1,x=2,O=3,P=4,J={},R={require:f,exports:1,module:1},Q=D(),L={baseUrl:"./",paths:{},config:{},map:{},packages:[],shim:{},waitSeconds:0,bundles:{},urlArgs:{}};f.version="2.0.2";f.loader="esl";f.toUrl=Q.toUrl;var S=[];d.amd={};var T={},W={};f.config=function(h){if(h){for(var c in L){var n=h[c],a=L[c];if(n)if("urlArgs"===c&&"string"==typeof n)L.urlArgs["*"]=n;else if(a instanceof Array)a.push.apply(a,n);else if("object"==typeof a)for(var t in n)a[t]=n[t];else L[c]=n}I()}};I();var U,X,ba,V,da,Y,Z,ca=document.getElementsByTagName("head")[0],aa=document.getElementsByTagName("base")[0];aa&&(ca=aa.parentNode);define||(define=d,require||(require=f),esl=f)}(this);define("echarts",["echarts/echarts"],function(g){return g});define("echarts/echarts","require ./config zrender/tool/util zrender/tool/event zrender zrender/config ./chart/island ./component/toolbox ./component ./component/title ./component/tooltip ./component/legend ./util/ecData ./chart zrender/tool/color ./component/timeline zrender/shape/Image zrender/loadingEffect/Bubble zrender/loadingEffect/Spin ./theme/macarons ./theme/infographic".split(" "),function(g){function f(){a.Dispatcher.call(this)}function q(c){c.innerHTML="";this._themeConfig={};this.dom=c;this._connected=!1;this._status={dragIn:!1,dragOut:!1,needRefresh:!1};this._curEventType=!1;this._chartList=[];this._messageCenter=new f;this._messageCenterOutSide=new f;this.resize=this.resize();this._init()}function l(c,a,n,h,u){c=c._chartList;for(var k=c.length;k--;){var b=c[k];"function"==typeof b[a]&&b[a](n,h,u)}}var d=g("./config"),b=g("zrender/tool/util"),a=g("zrender/tool/event"),e={},m=new Date-0,r={};e.version="1.0.0";e.mobile=!0;e.dependencies={zrender:"1.0.0"};e.init=function(c,a){var n=g("zrender");n.version.replace(".","")-0<e.dependencies.zrender.replace(".","")-0&&console.error("ZRender "+n.version+" is too old for ECharts "+e.version+". Current version need ZRender "+e.dependencies.zrender+"+");c=c instanceof Array?c[0]:c;n=c.getAttribute("_echarts_instance_");return n||(n=m++,c.setAttribute("_echarts_instance_",n)),r[n]&&r[n].dispose(),r[n]=new q(c),r[n].id=n,r[n].setTheme(a),r[n]};e.getInstanceById=function(c){return r[c]};b.merge(f.prototype,a.Dispatcher.prototype,!0);var k=g("zrender/config").EVENT,p="CLICK DBLCLICK MOUSEOVER MOUSEOUT DRAGSTART DRAGEND DRAGENTER DRAGOVER DRAGLEAVE DROP".split(" ");return q.prototype={_init:function(){var c=this,a=g("zrender").init(this.dom);this._zr=a;this._messageCenter.dispatch=function(h,n,a,t){a=a||{};a.type=h;a.event=n;c._messageCenter.dispatchWithContext(h,a,t);"HOVER"!=h&&"MOUSEOUT"!=h?setTimeout(function(){c._messageCenterOutSide.dispatchWithContext(h,a,t)},50):c._messageCenterOutSide.dispatchWithContext(h,a,t)};this._onevent=function(h){return c.__onevent(h)};for(var n in d.EVENT)"CLICK"!=n&&"DBLCLICK"!=n&&"HOVER"!=n&&"MOUSEOUT"!=n&&"MAP_ROAM"!=n&&this._messageCenter.bind(d.EVENT[n],this._onevent,this);var h={};this._onzrevent=function(n){return c[h[n.type]](n)};n=0;for(var u=p.length;u>n;n++){var b=p[n],e=k[b];h[e]="_on"+b.toLowerCase();a.on(e,this._onzrevent)}this.chart={};this.component={};this._island=new (g("./chart/island"))(this._themeConfig,this._messageCenter,a,{},this);this.chart.island=this._island;this._toolbox=new (g("./component/toolbox"))(this._themeConfig,this._messageCenter,a,{},this);this.component.toolbox=this._toolbox;n=g("./component");n.define("title",g("./component/title"));n.define("tooltip",g("./component/tooltip"));n.define("legend",g("./component/legend"));0!==a.getWidth()&&0!==a.getHeight()||console.error("Dom\u2019s width \x26 height should be ready before init.")},__onevent:function(c){c.__echartsId=c.__echartsId||this.id;var a=c.__echartsId===this.id;switch(this._curEventType||(this._curEventType=c.type),c.type){case d.EVENT.LEGEND_SELECTED:this._onlegendSelected(c);break;case d.EVENT.DATA_ZOOM:if(!a){var n=this.component.dataZoom;n&&(n.silence(!0),n.absoluteZoom(c.zoom),n.silence(!1))}this._ondataZoom(c);break;case d.EVENT.DATA_RANGE:a&&this._ondataRange(c);break;case d.EVENT.MAGIC_TYPE_CHANGED:a||(n=this.component.toolbox)&&(n.silence(!0),n.setMagicType(c.magicType),n.silence(!1));this._onmagicTypeChanged(c);break;case d.EVENT.DATA_VIEW_CHANGED:a&&this._ondataViewChanged(c);break;case d.EVENT.TOOLTIP_HOVER:a&&this._tooltipHover(c);break;case d.EVENT.RESTORE:this._onrestore();break;case d.EVENT.REFRESH:a&&this._onrefresh(c);break;case d.EVENT.TOOLTIP_IN_GRID:case d.EVENT.TOOLTIP_OUT_GRID:a?this._connected&&(n=this.component.grid)&&(c.x=(c.event.zrenderX-n.getX())/n.getWidth(),c.y=(c.event.zrenderY-n.getY())/n.getHeight()):(n=this.component.grid)&&this._zr.trigger("mousemove",{connectTrigger:!0,zrenderX:n.getX()+c.x*n.getWidth(),zrenderY:n.getY()+c.y*n.getHeight()})}if(this._connected&&a&&this._curEventType===c.type){for(var h in this._connected)this._connected[h].connectedEventHandler(c);this._curEventType=null}(!a||!this._connected&&a)&&(this._curEventType=null)},_onclick:function(c){if(l(this,"onclick",c),c.target){var a=this._eventPackage(c.target);a&&null!=a.seriesIndex&&this._messageCenter.dispatch(d.EVENT.CLICK,c.event,a,this)}},_ondblclick:function(c){if(l(this,"ondblclick",c),c.target){var a=this._eventPackage(c.target);a&&null!=a.seriesIndex&&this._messageCenter.dispatch(d.EVENT.DBLCLICK,c.event,a,this)}},_onmouseover:function(c){if(c.target){var a=this._eventPackage(c.target);a&&null!=a.seriesIndex&&this._messageCenter.dispatch(d.EVENT.HOVER,c.event,a,this)}},_onmouseout:function(c){if(c.target){var a=this._eventPackage(c.target);a&&null!=a.seriesIndex&&this._messageCenter.dispatch(d.EVENT.MOUSEOUT,c.event,a,this)}},_ondragstart:function(c){this._status={dragIn:!1,dragOut:!1,needRefresh:!1};l(this,"ondragstart",c)},_ondragenter:function(c){l(this,"ondragenter",c)},_ondragover:function(c){l(this,"ondragover",c)},_ondragleave:function(c){l(this,"ondragleave",c)},_ondrop:function(c){l(this,"ondrop",c,this._status);this._island.ondrop(c,this._status)},_ondragend:function(c){if(l(this,"ondragend",c,this._status),this._timeline&&this._timeline.ondragend(c,this._status),this._island.ondragend(c,this._status),this._status.needRefresh){this._syncBackupData(this._option);var a=this._messageCenter;a.dispatch(d.EVENT.DATA_CHANGED,c.event,this._eventPackage(c.target),this);a.dispatch(d.EVENT.REFRESH,null,null,this)}},_onlegendSelected:function(c){this._status.needRefresh=!1;l(this,"onlegendSelected",c,this._status);this._status.needRefresh&&this._messageCenter.dispatch(d.EVENT.REFRESH,null,null,this)},_ondataZoom:function(c){this._status.needRefresh=!1;l(this,"ondataZoom",c,this._status);this._status.needRefresh&&this._messageCenter.dispatch(d.EVENT.REFRESH,null,null,this)},_ondataRange:function(c){this._clearEffect();this._status.needRefresh=!1;l(this,"ondataRange",c,this._status);this._status.needRefresh&&this._zr.refreshNextFrame()},_onmagicTypeChanged:function(){this._clearEffect();this._render(this._toolbox.getMagicOption())},_ondataViewChanged:function(c){this._syncBackupData(c.option);this._messageCenter.dispatch(d.EVENT.DATA_CHANGED,null,c,this);this._messageCenter.dispatch(d.EVENT.REFRESH,null,null,this)},_tooltipHover:function(c){l(this,"ontooltipHover",c,[])},_onrestore:function(){this.restore()},_onrefresh:function(c){this._refreshInside=!0;this.refresh(c);this._refreshInside=!1},_syncBackupData:function(c){this.component.dataZoom&&this.component.dataZoom.syncBackupData(c)},_eventPackage:function(c){if(c){var a=g("./util/ecData"),n=a.get(c,"seriesIndex"),h=a.get(c,"dataIndex");return h=-1!=n&&this.component.dataZoom?this.component.dataZoom.getRealDataIndex(n,h):h,{seriesIndex:n,seriesName:(a.get(c,"series")||{}).name,dataIndex:h,data:a.get(c,"data"),name:a.get(c,"name"),value:a.get(c,"value"),special:a.get(c,"special")}}},_noDataCheck:function(c){c=c.series;for(var a=0,n=c.length;n>a;a++)if(c[a].type==d.CHART_TYPE_MAP||c[a].data&&0<c[a].data.length||c[a].markPoint&&c[a].markPoint.data&&0<c[a].markPoint.data.length||c[a].markLine&&c[a].markLine.data&&0<c[a].markLine.data.length||c[a].nodes&&0<c[a].nodes.length||c[a].links&&0<c[a].links.length||c[a].matrix&&0<c[a].matrix.length||c[a].eventList&&0<c[a].eventList.length)return!1;this.clear();return this.showLoading(this._option&&this._option.noDataLoadingOption||this._themeConfig.noDataLoadingOption||d.noDataLoadingOption||{text:this._option&&this._option.noDataText||this._themeConfig.noDataText||d.noDataText,effect:this._option&&this._option.noDataEffect||this._themeConfig.noDataEffect||d.noDataEffect}),!0},_render:function(c){if(this._mergeGlobalConifg(c),!this._noDataCheck(c)){var a=c.backgroundColor;a&&(this.dom.style.backgroundColor=a);this._zr.clearAnimation();this._chartList=[];var a=g("./chart"),n=g("./component");(c.xAxis||c.yAxis)&&(c.grid=c.grid||{},c.dataZoom=c.dataZoom||{});for(var h,u,k,b="title legend tooltip dataRange roamController grid dataZoom xAxis yAxis polar".split(" "),e=0,p=b.length;p>e;e++)u=b[e],k=this.component[u],c[u]?(k?k.refresh&&k.refresh(c):(h=n.get(/^[xy]Axis$/.test(u)?"axis":u),k=new h(this._themeConfig,this._messageCenter,this._zr,c,this,u),this.component[u]=k),this._chartList.push(k)):k&&(k.dispose(),this.component[u]=null,delete this.component[u]);var m,r,l;h={};e=0;for(p=c.series.length;p>e;e++)(r=c.series[e].type)?h[r]||(h[r]=!0,m=a.get(r),m?(this.chart[r]?(l=this.chart[r],l.refresh(c)):l=new m(this._themeConfig,this._messageCenter,this._zr,c,this),this._chartList.push(l),this.chart[r]=l):console.error(r+" has not been required.")):console.error("series["+e+"] chart type has not been defined.");for(r in this.chart)r==d.CHART_TYPE_ISLAND||h[r]||(this.chart[r].dispose(),this.chart[r]=null,delete this.chart[r]);this.component.grid&&this.component.grid.refixAxisShape(this.component);this._island.refresh(c);this._toolbox.refresh(c);c.animation&&!c.renderAsImage?this._zr.refresh():this._zr.render();m="IMG"+this.id;r=document.getElementById(m);c.renderAsImage?(r?r.src=this.getDataURL(c.renderAsImage):(r=this.getImage(c.renderAsImage),r.id=m,r.style.position="absolute",r.style.left=0,r.style.top=0,this.dom.firstChild.appendChild(r)),this.un(),this._zr.un(),this._disposeChartList(),this._zr.clear()):r&&r.parentNode.removeChild(r);this._option=c}},restore:function(){this._clearEffect();this._option=b.clone(this._optionRestore);this._disposeChartList();this._island.clear();this._toolbox.reset(this._option,!0);this._render(this._option)},refresh:function(c){this._clearEffect();c=c||{};var a=c.option;!this._refreshInside&&a&&(a=this.getOption(),b.merge(a,c.option,!0),b.merge(this._optionRestore,c.option,!0),this._toolbox.reset(a));this._island.refresh(a);this._toolbox.refresh(a);this._zr.clearAnimation();c=0;for(var n=this._chartList.length;n>c;c++)this._chartList[c].refresh&&this._chartList[c].refresh(a);this.component.grid&&this.component.grid.refixAxisShape(this.component);this._zr.refresh()},_disposeChartList:function(){this._clearEffect();this._zr.clearAnimation();for(var c=this._chartList.length;c--;){var a=this._chartList[c];if(a){var n=a.type;this.chart[n]&&delete this.chart[n];this.component[n]&&delete this.component[n];a.dispose&&a.dispose()}}this._chartList=[]},_mergeGlobalConifg:function(c){for(var a="backgroundColor calculable calculableColor calculableHolderColor nameConnector valueConnector animation animationThreshold animationDuration animationDurationUpdate animationEasing addDataAnimation symbolList DRAG_ENABLE_TIME".split(" "),n=a.length;n--;){var h=a[n];null==c[h]&&(c[h]=null!=this._themeConfig[h]?this._themeConfig[h]:d[h])}var u=c.color;u&&u.length||(u=this._themeConfig.color||d.color);this._zr.getColor=function(h){return g("zrender/tool/color").getColor(h,u)}},setOption:function(c,a){return c.timeline?this._setTimelineOption(c):this._setOption(c,a)},_setOption:function(c,a){return this._option=!a&&this._option?b.merge(this.getOption(),b.clone(c),!0):b.clone(c),this._optionRestore=b.clone(this._option),this._option.series&&0!==this._option.series.length?(this.component.dataZoom&&(this._option.dataZoom||this._option.toolbox&&this._option.toolbox.feature&&this._option.toolbox.feature.dataZoom&&this._option.toolbox.feature.dataZoom.show)&&this.component.dataZoom.syncOption(this._option),this._toolbox.reset(this._option),this._render(this._option),this):void this._zr.clear()},getOption:function(){function c(h){var c=n._optionRestore[h];if(c)if(c instanceof Array)for(var k=c.length;k--;)a[h][k].data=b.clone(c[k].data);else a[h].data=b.clone(c.data)}var a=b.clone(this._option),n=this;return c("xAxis"),c("yAxis"),c("series"),a},setSeries:function(c,a){return a?(this._option.series=c,this.setOption(this._option,a)):this.setOption({series:c}),this},getSeries:function(){return this.getOption().series},_setTimelineOption:function(c){this._timeline&&this._timeline.dispose();return this._timeline=new (g("./component/timeline"))(this._themeConfig,this._messageCenter,this._zr,c,this),this.component.timeline=this._timeline,this},addData:function(c,a,n,h,k){for(var e=c instanceof Array?c:[[c,a,n,h,k]],p=this.getOption(),m=this._optionRestore,r=0,l=e.length;l>r;r++){c=e[r][0];a=e[r][1];n=e[r][2];h=e[r][3];k=e[r][4];var f=m.series[c],g=n?"unshift":"push";n=n?"pop":"shift";if(f){var q=f.data,C=p.series[c].data;if(q[g](a),C[g](a),h||(q[n](),a=C[n]()),null!=k){var y,v;if(f.type===d.CHART_TYPE_PIE&&(y=m.legend)&&(v=y.data))f=p.legend.data,(v[g](k),f[g](k),h)||(h=b.indexOf(v,a.name),-1!=h&&v.splice(h,1),h=b.indexOf(f,a.name),-1!=h&&f.splice(h,1));else if(null!=m.xAxis&&null!=m.yAxis){var w,E;a=f.xAxisIndex||0;(null==m.xAxis[a].type||"category"===m.xAxis[a].type)&&(w=m.xAxis[a].data,E=p.xAxis[a].data,w[g](k),E[g](k),h||(w[n](),E[n]()));a=f.yAxisIndex||0;"category"===m.yAxis[a].type&&(w=m.yAxis[a].data,E=p.yAxis[a].data,w[g](k),E[g](k),h||(w[n](),E[n]()))}}this._option.series[c].data=p.series[c].data}}this._zr.clearAnimation();for(var A=this._chartList,r=0,l=A.length;l>r;r++)p.addDataAnimation&&A[r].addDataAnimation&&A[r].addDataAnimation(e);this.component.dataZoom&&this.component.dataZoom.syncOption(p);this._option=p;var F=this;return setTimeout(function(){if(F._zr){F._zr.clearAnimation();for(var h=0,c=A.length;c>h;h++)A[h].motionlessOnce=p.addDataAnimation&&A[h].addDataAnimation;F._messageCenter.dispatch(d.EVENT.REFRESH,null,{option:p},F)}},p.addDataAnimation?p.animationDurationUpdate:0),this},addMarkPoint:function(c,a){return this._addMark(c,a,"markPoint")},addMarkLine:function(c,a){return this._addMark(c,a,"markLine")},_addMark:function(c,a,n){var h,k=this._option.series;if(k&&(h=k[c])){var k=this._optionRestore.series[c],e=h[n],d=k[n],e=h[n]=e||{data:[]},d=k[n]=d||{data:[]},p;for(p in a)"data"===p?(e.data=e.data.concat(a.data),d.data=d.data.concat(a.data)):"object"!=typeof a[p]||null==e[p]?e[p]=d[p]=a[p]:(b.merge(e[p],a[p],!0),b.merge(d[p],a[p],!0));(h=this.chart[h.type])&&h.addMark(c,a,n)}return this},delMarkPoint:function(c,a){return this._delMark(c,a,"markPoint")},delMarkLine:function(c,a){return this._delMark(c,a,"markLine")},_delMark:function(c,a,n){var h,k,e,b=this._option.series;if(!(b&&(h=b[c])&&(k=h[n])&&(e=k.data)))return this;a=a.split(" \x3e ");k=-1;for(var b=0,d=e.length;d>b;b++){var p=e[b];if(p instanceof Array){if(p[0].name===a[0]&&p[1].name===a[1]){k=b;break}}else if(p.name===a[0]){k=b;break}}-1<k&&(e.splice(k,1),this._optionRestore.series[c][n].data.splice(k,1),(h=this.chart[h.type])&&h.delMark(c,a.join(" \x3e "),n));return this},getDom:function(){return this.dom},getZrender:function(){return this._zr},getDataURL:function(c){if(0===this._chartList.length){var a=document.getElementById("IMG"+this.id);if(a)return a.src}a=this.component.tooltip;switch(a&&a.hideTip(),c){case "jpeg":break;default:c="png"}a=this._option.backgroundColor;return a&&"rgba(0,0,0,0)"===a.replace(" ","")&&(a="#fff"),this._zr.toDataURL("image/"+c,a)},getImage:function(a){var k=this._optionRestore.title,n=document.createElement("img");return n.src=this.getDataURL(a),n.title=k&&k.text||"ECharts",n},getConnectedDataURL:function(a){if(!this.isConnected())return this.getDataURL(a);var k=this.dom,n={self:{img:this.getDataURL(a),left:k.offsetLeft,top:k.offsetTop,right:k.offsetLeft+k.offsetWidth,bottom:k.offsetTop+k.offsetHeight}},h=n.self.left,u=n.self.top,b=n.self.right,e=n.self.bottom,d;for(d in this._connected)k=this._connected[d].getDom(),n[d]={img:this._connected[d].getDataURL(a),left:k.offsetLeft,top:k.offsetTop,right:k.offsetLeft+k.offsetWidth,bottom:k.offsetTop+k.offsetHeight},h=Math.min(h,n[d].left),u=Math.min(u,n[d].top),b=Math.max(b,n[d].right),e=Math.max(e,n[d].bottom);var p=document.createElement("div");p.style.position="absolute";p.style.left="-4000px";p.style.width=b-h+"px";p.style.height=e-u+"px";document.body.appendChild(p);var m=g("zrender").init(p);a=g("zrender/shape/Image");for(d in n)m.addShape(new a({style:{x:n[d].left-h,y:n[d].top-u,image:n[d].img}}));m.render();(n=this._option.backgroundColor)&&"rgba(0,0,0,0)"===n.replace(/ /g,"")&&(n="#fff");n=m.toDataURL("image/png",n);return setTimeout(function(){m.dispose();p.parentNode.removeChild(p);p=null},100),n},getConnectedImage:function(a){var k=this._optionRestore.title,n=document.createElement("img");return n.src=this.getConnectedDataURL(a),n.title=k&&k.text||"ECharts",n},on:function(a,k){return this._messageCenterOutSide.bind(a,k,this),this},un:function(a,k){return this._messageCenterOutSide.unbind(a,k),this},connect:function(a){if(!a)return this;if(this._connected||(this._connected={}),a instanceof Array)for(var k=0,n=a.length;n>k;k++)this._connected[a[k].id]=a[k];else this._connected[a.id]=a;return this},disConnect:function(a){if(!a||!this._connected)return this;if(a instanceof Array)for(var k=0,n=a.length;n>k;k++)delete this._connected[a[k].id];else delete this._connected[a.id];for(var h in this._connected)return this;return this._connected=!1,this},connectedEventHandler:function(a){a.__echartsId!=this.id&&this._onevent(a)},isConnected:function(){return!!this._connected},showLoading:function(a){var k={bubble:g("zrender/loadingEffect/Bubble"),spin:g("zrender/loadingEffect/Spin")};a=a||{};var n=a.textStyle||{};a.textStyle=n;var h=b.merge(b.merge(b.clone(n),this._themeConfig.textStyle),d.textStyle);n.textFont=h.fontStyle+" "+h.fontWeight+" "+h.fontSize+"px "+h.fontFamily;n.text=a.text||this._option&&this._option.loadingText||this._themeConfig.loadingText||d.loadingText;null!=a.x&&(n.x=a.x);null!=a.y&&(n.y=a.y);a.effectOption=a.effectOption||{};a.effectOption.textStyle=n;n=a.effect;return("string"==typeof n||null==n)&&(n=k[a.effect||this._option&&this._option.loadingEffect||this._themeConfig.loadingEffect||d.loadingEffect]||k.spin),this._zr.showLoading(new n(a.effectOption)),this},hideLoading:function(){return this._zr.hideLoading(),this},setTheme:function(a){if(a){if("string"==typeof a)switch(a){case "macarons":a=g("./theme/macarons");break;case "infographic":a=g("./theme/infographic");break;default:a={}}else a=a||{};this._themeConfig=a}this._timeline&&this._timeline.setTheme(!0);this._optionRestore&&this.restore()},resize:function(){var a=this;return function(){if(a._clearEffect(),a._zr.resize(),a._option&&a._option.renderAsImage)return a._render(a._option),a;a._zr.clearAnimation();a._island.resize();a._toolbox.resize();a._timeline&&a._timeline.resize();for(var k=0,n=a._chartList.length;n>k;k++)a._chartList[k].resize&&a._chartList[k].resize();return a.component.grid&&a.component.grid.refixAxisShape(a.component),a._zr.refresh(),a._messageCenter.dispatch(d.EVENT.RESIZE,null,null,a),a}},_clearEffect:function(){this._zr.modLayer(d.EFFECT_ZLEVEL,{motionBlur:!1});this._zr.painter.clearLayer(d.EFFECT_ZLEVEL)},clear:function(){return this._disposeChartList(),this._zr.clear(),this._option={},this._optionRestore={},this.dom.style.backgroundColor=null,this},dispose:function(){var a=this.dom.getAttribute("_echarts_instance_");a&&delete r[a];this._island.dispose();this._toolbox.dispose();this._timeline&&this._timeline.dispose();this._messageCenter.unbind();this.clear();this._zr.dispose();this._zr=null}},e});define("echarts/config",[],function(){return{CHART_TYPE_LINE:"line",CHART_TYPE_BAR:"bar",CHART_TYPE_SCATTER:"scatter",CHART_TYPE_PIE:"pie",CHART_TYPE_RADAR:"radar",CHART_TYPE_MAP:"map",CHART_TYPE_K:"k",CHART_TYPE_ISLAND:"island",CHART_TYPE_FORCE:"force",CHART_TYPE_CHORD:"chord",CHART_TYPE_GAUGE:"gauge",CHART_TYPE_FUNNEL:"funnel",CHART_TYPE_EVENTRIVER:"eventRiver",COMPONENT_TYPE_TITLE:"title",COMPONENT_TYPE_LEGEND:"legend",COMPONENT_TYPE_DATARANGE:"dataRange",COMPONENT_TYPE_DATAVIEW:"dataView",COMPONENT_TYPE_DATAZOOM:"dataZoom",COMPONENT_TYPE_TOOLBOX:"toolbox",COMPONENT_TYPE_TOOLTIP:"tooltip",COMPONENT_TYPE_GRID:"grid",COMPONENT_TYPE_AXIS:"axis",COMPONENT_TYPE_POLAR:"polar",COMPONENT_TYPE_X_AXIS:"xAxis",COMPONENT_TYPE_Y_AXIS:"yAxis",COMPONENT_TYPE_AXIS_CATEGORY:"categoryAxis",COMPONENT_TYPE_AXIS_VALUE:"valueAxis",COMPONENT_TYPE_TIMELINE:"timeline",COMPONENT_TYPE_ROAMCONTROLLER:"roamController",backgroundColor:"rgba(0,0,0,0)",color:"#ff7f50 #87cefa #da70d6 #32cd32 #6495ed #ff69b4 #ba55d3 #cd5c5c #ffa500 #40e0d0".split(" "),markPoint:{clickable:!0,symbol:"pin",symbolSize:10,large:!1,effect:{show:!1,loop:!0,period:15,type:"scale",scaleSize:2,bounceDistance:10},itemStyle:{normal:{borderWidth:2,label:{show:!0,position:"inside"}},emphasis:{label:{show:!0}}}},markLine:{clickable:!0,symbol:["circle","arrow"],symbolSize:[2,2],smoothRadian:.2,precision:2,effect:{show:!1,loop:!0,period:15,scaleSize:2},itemStyle:{normal:{borderWidth:1.5,label:{show:!0,position:"end",textStyle:{align:"right",baseline:"bottom"}},lineStyle:{type:"dashed"}},emphasis:{label:{show:!1,textStyle:{align:"right",baseline:"bottom"}},lineStyle:{}}}},textStyle:{decoration:"none",fontFamily:"Arial, Verdana, sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},EVENT:{REFRESH:"refresh",RESTORE:"restore",RESIZE:"resize",CLICK:"click",DBLCLICK:"dblclick",HOVER:"hover",MOUSEOUT:"mouseout",DATA_CHANGED:"dataChanged",DATA_ZOOM:"dataZoom",DATA_RANGE:"dataRange",DATA_RANGE_SELECTED:"dataRangeSelected",DATA_RANGE_HOVERLINK:"dataRangeHoverLink",LEGEND_SELECTED:"legendSelected",LEGEND_HOVERLINK:"legendHoverLink",MAP_SELECTED:"mapSelected",PIE_SELECTED:"pieSelected",MAGIC_TYPE_CHANGED:"magicTypeChanged",DATA_VIEW_CHANGED:"dataViewChanged",TIMELINE_CHANGED:"timelineChanged",MAP_ROAM:"mapRoam",FORCE_LAYOUT_END:"forceLayoutEnd",TOOLTIP_HOVER:"tooltipHover",TOOLTIP_IN_GRID:"tooltipInGrid",TOOLTIP_OUT_GRID:"tooltipOutGrid",ROAMCONTROLLER:"roamController"},DRAG_ENABLE_TIME:120,EFFECT_ZLEVEL:10,symbolList:"emptyCircle emptyRectangle emptyTriangle emptyDiamond circle rectangle triangle diamond".split(" "),loadingEffect:"spin",loadingText:"\u6570\u636e\u8bfb\u53d6\u4e2d...",noDataEffect:"bubble",noDataText:"\u6682\u65e0\u6570\u636e",calculable:!1,calculableColor:"rgba(255,165,0,0.6)",calculableHolderColor:"#ccc",nameConnector:" \x26 ",valueConnector:": ",animation:!0,addDataAnimation:!0,animationThreshold:2E3,animationDuration:2E3,animationDurationUpdate:500,animationEasing:"ExponentialOut"}});define("zrender/tool/util",["require"],function(){function g(a){return a&&1===a.nodeType&&"string"==typeof a.nodeName}function f(a){if("object"==typeof a&&null!==a){var k=a;if(a instanceof Array)for(var k=[],n=0,h=a.length;h>n;n++)k[n]=f(a[n]);else if(!m[r.call(a)]&&!g(a))for(n in k={},a)a.hasOwnProperty(n)&&(k[n]=f(a[n]));return k}return a}function q(a,k,n){for(var h in k){var u=a,b=k,e=h,d=n;if(b.hasOwnProperty(e)){var p=u[e];"object"!=typeof p||m[r.call(p)]||g(p)?!d&&e in u||(u[e]=b[e]):q(u[e],b[e],d)}}return a}var l,d,b,a,e,m={"[object Function]":1,"[object RegExp]":1,"[object Date]":1,"[object Error]":1,"[object CanvasGradient]":1},r=Object.prototype.toString,k=0,p=0;return{inherits:function(a,k){function n(){}var h=a.prototype;n.prototype=k.prototype;a.prototype=new n;for(var u in h)a.prototype[u]=h[u];a.constructor=a},clone:f,merge:q,getContext:function(){return l||(l=document.createElement("canvas").getContext("2d")),l},getPixelContext:function(){return b||(d=document.createElement("canvas"),a=d.width,e=d.height,b=d.getContext("2d")),b},getPixelOffset:function(){return{x:k,y:p}},adjustCanvasSize:function(c,t){var n;c+k>a&&(a=c+k+100,d.width=a,n=!0);t+p>e&&(e=t+p+100,d.height=e,n=!0);-k>c&&(k=100*Math.ceil(-c/100),a+=k,d.width=a,n=!0);-p>t&&(p=100*Math.ceil(-t/100),e+=p,d.height=e,n=!0);n&&b.translate(k,p)},indexOf:function(a,k){if(a.indexOf)return a.indexOf(k);for(var n=0,h=a.length;h>n;n++)if(a[n]===k)return n;return-1}}});define("zrender/tool/event",["require","../mixin/Eventful"],function(g){g=g("../mixin/Eventful");return{getX:function(f){return"undefined"!=typeof f.zrenderX&&f.zrenderX||"undefined"!=typeof f.offsetX&&f.offsetX||"undefined"!=typeof f.layerX&&f.layerX||"undefined"!=typeof f.clientX&&f.clientX},getY:function(f){return"undefined"!=typeof f.zrenderY&&f.zrenderY||"undefined"!=typeof f.offsetY&&f.offsetY||"undefined"!=typeof f.layerY&&f.layerY||"undefined"!=typeof f.clientY&&f.clientY},getDelta:function(f){return"undefined"!=typeof f.zrenderDelta&&f.zrenderDelta||"undefined"!=typeof f.wheelDelta&&f.wheelDelta||"undefined"!=typeof f.detail&&-f.detail},stop:"function"==typeof window.addEventListener?function(f){f.preventDefault();f.stopPropagation();f.cancelBubble=!0}:function(f){f.returnValue=!1;f.cancelBubble=!0},Dispatcher:g}});define("zrender",["zrender/zrender"],function(g){return g});define("zrender/zrender","require ./tool/util ./tool/log ./tool/guid ./Handler ./Painter ./Storage ./animation/Animation ./tool/env".split(" "),function(g){function f(a){return function(){for(var k=a.animatingElements,n=0,h=k.length;h>n;n++)a.storage.mod(k[n].id);(k.length||a._needsRefreshNextFrame)&&a.refresh()}}var q=g("./tool/util"),l=g("./tool/log"),d=g("./tool/guid"),b=g("./Handler"),a=g("./Painter"),e=g("./Storage"),m=g("./animation/Animation"),r={},k={version:"1.0.0",init:function(a){a=new p(d(),a);return r[a.id]=a,a},dispose:function(a){if(a)a.dispose();else{for(var e in r)r[e].dispose();r={}}return k},getInstance:function(a){return r[a]},delInstance:function(a){return delete r[a],k}},p=function(c,k){this.id=c;this.env=g("./tool/env");this.storage=new e;this.painter=new a(k,this.storage);this.handler=new b(k,this.storage,this.painter);this.animatingElements=[];this.animation=new m({stage:{update:f(this)}});this.animation.start();var n=this;this.painter.refreshNextFrame=function(){n.refreshNextFrame()};this._needsRefreshNextFrame=!1};return p.prototype.getId=function(){return this.id},p.prototype.addShape=function(a){return this.storage.addRoot(a),this},p.prototype.addGroup=function(a){return this.storage.addRoot(a),this},p.prototype.delShape=function(a){return this.storage.delRoot(a),this},p.prototype.delGroup=function(a){return this.storage.delRoot(a),this},p.prototype.modShape=function(a,k){return this.storage.mod(a,k),this},p.prototype.modGroup=function(a,k){return this.storage.mod(a,k),this},p.prototype.modLayer=function(a,k){return this.painter.modLayer(a,k),this},p.prototype.addHoverShape=function(a){return this.storage.addHover(a),this},p.prototype.render=function(a){return this.painter.render(a),this._needsRefreshNextFrame=!1,this},p.prototype.refresh=function(a){return this.painter.refresh(a),this._needsRefreshNextFrame=!1,this},p.prototype.refreshNextFrame=function(){return this._needsRefreshNextFrame=!0,this},p.prototype.refreshHover=function(a){return this.painter.refreshHover(a),this},p.prototype.refreshShapes=function(a,k){return this.painter.refreshShapes(a,k),this},p.prototype.resize=function(){return this.painter.resize(),this},p.prototype.animate=function(a,k,n){if("string"==typeof a&&(a=this.storage.get(a)),a){var h;if(k){for(var u=k.split("."),e=a,b=0,d=u.length;d>b;b++)e&&(e=e[u[b]]);e&&(h=e)}else h=a;if(!h)return void l('Property "'+k+'" is not existed in element '+a.id);var p=this.animatingElements;return"undefined"==typeof a.__aniCount&&(a.__aniCount=0),0===a.__aniCount&&p.push(a),a.__aniCount++,this.animation.animate(h,{loop:n}).done(function(){if(a.__aniCount--,0===a.__aniCount){var h=q.indexOf(p,a);p.splice(h,1)}})}l("Element not existed")},p.prototype.clearAnimation=function(){this.animation.clear()},p.prototype.showLoading=function(a){return this.painter.showLoading(a),this},p.prototype.hideLoading=function(){return this.painter.hideLoading(),this},p.prototype.getWidth=function(){return this.painter.getWidth()},p.prototype.getHeight=function(){return this.painter.getHeight()},p.prototype.toDataURL=function(a,k,n){return this.painter.toDataURL(a,k,n)},p.prototype.shapeToImage=function(a,k,n){var h=d();return this.painter.shapeToImage(h,a,k,n)},p.prototype.on=function(a,k,n){return this.handler.on(a,k,n),this},p.prototype.un=function(a,k){return this.handler.un(a,k),this},p.prototype.trigger=function(a,k){return this.handler.trigger(a,k),this},p.prototype.clear=function(){return this.storage.delRoot(),this.painter.clear(),this},p.prototype.dispose=function(){this.animation.stop();this.clear();this.storage.dispose();this.painter.dispose();this.handler.dispose();this.animation=this.animatingElements=this.storage=this.painter=this.handler=null;k.delInstance(this.id)},k});define("zrender/config",[],function(){return{EVENT:{RESIZE:"resize",CLICK:"click",DBLCLICK:"dblclick",MOUSEWHEEL:"mousewheel",MOUSEMOVE:"mousemove",MOUSEOVER:"mouseover",MOUSEOUT:"mouseout",MOUSEDOWN:"mousedown",MOUSEUP:"mouseup",GLOBALOUT:"globalout",DRAGSTART:"dragstart",DRAGEND:"dragend",DRAGENTER:"dragenter",DRAGOVER:"dragover",DRAGLEAVE:"dragleave",DROP:"drop",touchClickDelay:300},catchBrushException:!1,debugMode:0,devicePixelRatio:Math.max(window.devicePixelRatio||1,1)}});define("echarts/chart/island","require ./base zrender/shape/Circle ../config ../util/ecData zrender/tool/util zrender/tool/event zrender/tool/color ../util/accMath ../chart".split(" "),function(g){function f(a,d,k,p,c){q.call(this,a,d,k,p,c);this._nameConnector;this._valueConnector;this._zrHeight=this.zr.getHeight();this._zrWidth=this.zr.getWidth();var t=this;t.shapeHandler.onmousewheel=function(a){var h=a.target;a=a.event;var k=e.getDelta(a),k=0<k?-1:1;h.style.r-=k;h.style.r=5>h.style.r?5:h.style.r;var c=b.get(h,"value"),d=c*t.option.island.calculateStep,c=1<d?Math.round(c-d*k):+(c-d*k).toFixed(2),k=b.get(h,"name");h.style.text=k+":"+c;b.set(h,"value",c);b.set(h,"name",k);t.zr.modShape(h.id);t.zr.refreshNextFrame();e.stop(a)}}var q=g("./base"),l=g("zrender/shape/Circle"),d=g("../config");d.island={zlevel:0,z:5,r:15,calculateStep:.1};var b=g("../util/ecData"),a=g("zrender/tool/util"),e=g("zrender/tool/event");return f.prototype={type:d.CHART_TYPE_ISLAND,_combine:function(a,e){var k=g("zrender/tool/color"),d=g("../util/accMath").accAdd(b.get(a,"value"),b.get(e,"value")),c=b.get(a,"name")+this._nameConnector+b.get(e,"name");a.style.text=c+this._valueConnector+d;b.set(a,"value",d);b.set(a,"name",c);a.style.r=this.option.island.r;a.style.color=k.mix(a.style.color,e.style.color)},refresh:function(a){a&&(a.island=this.reformOption(a.island),this.option=a,this._nameConnector=this.option.nameConnector,this._valueConnector=this.option.valueConnector)},getOption:function(){return this.option},resize:function(){var a=this.zr.getWidth(),e=this.zr.getHeight(),k=a/(this._zrWidth||a),b=e/(this._zrHeight||e);if(1!==k||1!==b)for(this._zrWidth=a,this._zrHeight=e,a=0,e=this.shapeList.length;e>a;a++)this.zr.modShape(this.shapeList[a].id,{style:{x:Math.round(this.shapeList[a].style.x*k),y:Math.round(this.shapeList[a].style.y*b)}})},add:function(a){var e=b.get(a,"name"),k=b.get(a,"value"),d=null!=b.get(a,"series")?b.get(a,"series").name:"",c=this.getFont(this.option.island.textStyle),c={zlevel:this.getZlevelBase(),z:this.getZBase(),style:{x:a.style.x,y:a.style.y,r:this.option.island.r,color:a.style.color||a.style.strokeColor,text:e+this._valueConnector+k,textFont:c},draggable:!0,hoverable:!0,onmousewheel:this.shapeHandler.onmousewheel,_type:"island"};"#fff"===c.style.color&&(c.style.color=a.style.strokeColor);this.setCalculable(c);c.dragEnableTime=0;b.pack(c,{name:d},-1,k,-1,e);c=new l(c);this.shapeList.push(c);this.zr.addShape(c)},del:function(a){this.zr.delShape(a.id);for(var e=[],k=0,b=this.shapeList.length;b>k;k++)this.shapeList[k].id!=a.id&&e.push(this.shapeList[k]);this.shapeList=e},ondrop:function(a,e){if(this.isDrop&&a.target){var k=a.target;this._combine(k,a.dragged);this.zr.modShape(k.id);e.dragIn=!0;this.isDrop=!1}},ondragend:function(a,b){var k=a.target;this.isDragend?b.dragIn&&(this.del(k),b.needRefresh=!0):b.dragIn||(k.style.x=e.getX(a.event),k.style.y=e.getY(a.event),this.add(k),b.needRefresh=!0);this.isDragend=!1}},a.inherits(f,q),g("../chart").define("island",f),f});define("echarts/component/toolbox","require ./base zrender/shape/Image zrender/shape/Rectangle ../util/shape/Icon ../config zrender/tool/util zrender/config zrender/tool/event ../component".split(" "),function(g){function f(a,e,c,b,n){q.call(this,a,e,c,b,n);this.dom=n.dom;this._magicType={};this._magicMap={};this._isSilence=!1;this._iconList;this._iconShapeMap={};this._featureTitle={};this._featureIcon={};this._featureColor={};this._featureOption={};this._enableColor="red";this._disableColor="#ccc";this._markShapeList=[];var h=this;h._onDataZoom=function(a){h.__onDataZoom(a)};h._onDataZoomReset=function(a){h.__onDataZoomReset(a)};h._onRestore=function(a){h.__onRestore(a)};h._onMagicType=function(a){h.__onMagicType(a)};h._onCustomHandler=function(a){h.__onCustomHandler(a)};h._onmousemove=function(a){return h.__onmousemove(a)};h._onmousedown=function(a){return h.__onmousedown(a)};h._onmouseup=function(a){return h.__onmouseup(a)}}var q=g("./base"),l=g("zrender/shape/Image"),d=g("zrender/shape/Rectangle"),b=g("../util/shape/Icon"),a=g("../config");a.toolbox={zlevel:0,z:6,show:!1,orient:"horizontal",x:"right",y:"bottom",color:["#1e90ff","#22bb22","#4b0082","#d2691e"],disableColor:"#ddd",effectiveColor:"red",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:1,itemGap:18,itemSize:24,showTitle:!0,feature:{dataZoom:{show:!1,title:{dataZoom:"\u533a\u57df\u7f29\u653e",dataZoomReset:"\u533a\u57df\u7f29\u653e\u540e\u9000"}},magicType:{show:!1,title:{line:"\u6298\u7ebf\u56fe\u5207\u6362",bar:"\u67f1\u5f62\u56fe\u5207\u6362",stack:"\u5806\u79ef",tiled:"\u5e73\u94fa",force:"\u529b\u5bfc\u5411\u5e03\u5c40\u56fe\u5207\u6362",chord:"\u548c\u5f26\u56fe\u5207\u6362",pie:"\u997c\u56fe\u5207\u6362",funnel:"\u6f0f\u6597\u56fe\u5207\u6362"},type:[]},restore:{show:!1,title:"\u8fd8\u539f"}}};var e=g("zrender/tool/util"),m=g("zrender/config"),r=g("zrender/tool/event");return f.prototype={type:a.COMPONENT_TYPE_TOOLBOX,_buildShape:function(){this._iconList=[];var a=this.option.toolbox;this._enableColor=a.effectiveColor;this._disableColor=a.disableColor;var a=a.feature,e=[],c;for(c in a)if(a[c].show)switch(c){case "mark":break;case "magicType":for(var b=0,n=a[c].type.length;n>b;b++)a[c].title[a[c].type[b]+"Chart"]=a[c].title[a[c].type[b]],a[c].option&&(a[c].option[a[c].type[b]+"Chart"]=a[c].option[a[c].type[b]]),e.push({key:c,name:a[c].type[b]+"Chart"});break;case "dataZoom":e.push({key:c,name:"dataZoom"});e.push({key:c,name:"dataZoomReset"});break;case "saveAsImage":case "dataView":break;default:e.push({key:c,name:c})}if(0<e.length){for(var h,b=0,n=e.length;n>b;b++)h=e[b].name,c=e[b].key,this._iconList.push(h),this._featureTitle[h]=a[c].title[h]||a[c].title,a[c].icon&&(this._featureIcon[h]=a[c].icon[h]||a[c].icon),a[c].color&&(this._featureColor[h]=a[c].color[h]||a[c].color),a[c].option&&(this._featureOption[h]=a[c].option[h]||a[c].option);this._itemGroupLocation=this._getItemGroupLocation();this._buildBackground();this._buildItem();b=0;for(n=this.shapeList.length;n>b;b++)this.zr.addShape(this.shapeList[b]);this._iconShapeMap.dataZoomReset&&0===this._zoomQueue.length&&this._iconDisable(this._iconShapeMap.dataZoomReset)}},_buildItem:function(){var a,e,c,d,n=this.option.toolbox,h=this._iconList.length,u=this._itemGroupLocation.x,m=this._itemGroupLocation.y,r=n.itemSize,f=n.itemGap,g=n.color instanceof Array?n.color:[n.color],q=this.getFont(n.textStyle);"horizontal"===n.orient?(e=.5>this._itemGroupLocation.y/this.zr.getHeight()?"bottom":"top",c=.5>this._itemGroupLocation.x/this.zr.getWidth()?"left":"right",d=.5>this._itemGroupLocation.y/this.zr.getHeight()?"top":"bottom"):e=.5>this._itemGroupLocation.x/this.zr.getWidth()?"right":"left";this._iconShapeMap={};for(var D=0;h>D;D++){switch(a={type:"icon",zlevel:this.getZlevelBase(),z:this.getZBase(),style:{x:u,y:m,width:r,height:r,iconType:this._iconList[D],lineWidth:1,strokeColor:this._featureColor[this._iconList[D]]||g[D%g.length],brushType:"stroke"},highlightStyle:{lineWidth:1,text:n.showTitle?this._featureTitle[this._iconList[D]]:void 0,textFont:q,textPosition:e,strokeColor:this._featureColor[this._iconList[D]]||g[D%g.length]},hoverable:!0,clickable:!0},this._featureIcon[this._iconList[D]]&&(a.style.image=this._featureIcon[this._iconList[D]].replace(/^image:\/\//,""),a.style.opacity=.8,a.highlightStyle.opacity=1,a.type="image"),"horizontal"===n.orient&&(0===D&&"left"===c&&(a.highlightStyle.textPosition="specific",a.highlightStyle.textAlign=c,a.highlightStyle.textBaseline=d,a.highlightStyle.textX=u,a.highlightStyle.textY="top"===d?m+r+10:m-10),D===h-1&&"right"===c&&(a.highlightStyle.textPosition="specific",a.highlightStyle.textAlign=c,a.highlightStyle.textBaseline=d,a.highlightStyle.textX=u+r,a.highlightStyle.textY="top"===d?m+r+10:m-10)),this._iconList[D]){case "dataZoom":a.onclick=this._onDataZoom;break;case "dataZoomReset":a.onclick=this._onDataZoomReset;break;case "restore":a.onclick=this._onRestore;break;default:this._iconList[D].match("Chart")?(a._name=this._iconList[D].replace("Chart",""),a.onclick=this._onMagicType):a.onclick=this._onCustomHandler}"icon"===a.type?a=new b(a):"image"===a.type&&(a=new l(a));this.shapeList.push(a);this._iconShapeMap[this._iconList[D]]=a;"horizontal"===n.orient?u+=r+f:m+=r+f}},_buildBackground:function(){var a=this.option.toolbox,e=this.reformCssArray(this.option.toolbox.padding);this.shapeList.push(new d({zlevel:this.getZlevelBase(),z:this.getZBase(),hoverable:!1,style:{x:this._itemGroupLocation.x-e[3],y:this._itemGroupLocation.y-e[0],width:this._itemGroupLocation.width+e[3]+e[1],height:this._itemGroupLocation.height+e[0]+e[2],brushType:0===a.borderWidth?"fill":"both",color:a.backgroundColor,strokeColor:a.borderColor,lineWidth:a.borderWidth}}))},_getItemGroupLocation:function(){var a=this.option.toolbox,e=this.reformCssArray(this.option.toolbox.padding),c=this._iconList.length,b=a.itemGap,n=a.itemSize,h=0,u=0;"horizontal"===a.orient?(h=(n+b)*c-b,u=n):(u=(n+b)*c-b,h=n);c=this.zr.getWidth();switch(a.x){case "center":c=Math.floor((c-h)/2);break;case "left":c=e[3]+a.borderWidth;break;case "right":c=c-h-e[1]-a.borderWidth;break;default:c=a.x-0,c=isNaN(c)?0:c}b=this.zr.getHeight();switch(a.y){case "top":a=e[0]+a.borderWidth;break;case "bottom":a=b-u-e[2]-a.borderWidth;break;case "center":a=Math.floor((b-u)/2);break;default:a=a.y-0,a=isNaN(a)?0:a}return{x:c,y:a,width:h,height:u}},__onmousemove:function(a){this._zooming&&(this._zoomShape.style.width=r.getX(a.event)-this._zoomShape.style.x,this._zoomShape.style.height=r.getY(a.event)-this._zoomShape.style.y,this.zr.addHoverShape(this._zoomShape),this.dom.style.cursor="crosshair",r.stop(a.event));this._zoomStart&&"pointer"!=this.dom.style.cursor&&"move"!=this.dom.style.cursor&&(this.dom.style.cursor="crosshair")},__onmousedown:function(k){if(!k.target){this._zooming=!0;var e=r.getX(k.event);k=r.getY(k.event);var c=this.option.dataZoom||{};return this._zoomShape=new d({zlevel:this.getZlevelBase(),z:this.getZBase(),style:{x:e,y:k,width:1,height:1,brushType:"both"},highlightStyle:{lineWidth:2,color:c.fillerColor||a.dataZoom.fillerColor,strokeColor:c.handleColor||a.dataZoom.handleColor,brushType:"both"}}),this.zr.addHoverShape(this._zoomShape),!0}},__onmouseup:function(){if(!this._zoomShape||10>Math.abs(this._zoomShape.style.width)||10>Math.abs(this._zoomShape.style.height))return this._zooming=!1,!0;if(this._zooming&&this.component.dataZoom){this._zooming=!1;var a=this.component.dataZoom.rectZoom(this._zoomShape.style);a&&(this._zoomQueue.push({start:a.start,end:a.end,start2:a.start2,end2:a.end2}),this._iconEnable(this._iconShapeMap.dataZoomReset),this.zr.refreshNextFrame())}return!0},__onDataZoom:function(a){a=a.target;if(this._zooming||this._zoomStart)this._resetZoom(),this.zr.refreshNextFrame(),this.dom.style.cursor="default";else{this.zr.modShape(a.id,{style:{strokeColor:this._enableColor}});this.zr.refreshNextFrame();this._zoomStart=!0;var e=this;setTimeout(function(){e.zr&&e.zr.on(m.EVENT.MOUSEDOWN,e._onmousedown)&&e.zr.on(m.EVENT.MOUSEUP,e._onmouseup)&&e.zr.on(m.EVENT.MOUSEMOVE,e._onmousemove)},10);this.dom.style.cursor="crosshair"}return!0},__onDataZoomReset:function(){return this._zooming&&(this._zooming=!1),this._zoomQueue.pop(),0<this._zoomQueue.length?this.component.dataZoom.absoluteZoom(this._zoomQueue[this._zoomQueue.length-1]):(this.component.dataZoom.rectZoom(),this._iconDisable(this._iconShapeMap.dataZoomReset),this.zr.refreshNextFrame()),!0},_resetZoom:function(){this._zooming=!1;this._zoomStart&&(this._zoomStart=!1,this._iconShapeMap.dataZoom&&this.zr.modShape(this._iconShapeMap.dataZoom.id,{style:{strokeColor:this._iconShapeMap.dataZoom.highlightStyle.strokeColor}}),this.zr.un(m.EVENT.MOUSEDOWN,this._onmousedown),this.zr.un(m.EVENT.MOUSEUP,this._onmouseup),this.zr.un(m.EVENT.MOUSEMOVE,this._onmousemove))},_iconDisable:function(a){"image"!=a.type?this.zr.modShape(a.id,{hoverable:!1,clickable:!1,style:{strokeColor:this._disableColor}}):this.zr.modShape(a.id,{hoverable:!1,clickable:!1,style:{opacity:.3}})},_iconEnable:function(a){"image"!=a.type?this.zr.modShape(a.id,{hoverable:!0,clickable:!0,style:{strokeColor:a.highlightStyle.strokeColor}}):this.zr.modShape(a.id,{hoverable:!0,clickable:!0,style:{opacity:.8}})},__onRestore:function(){return this._resetZoom(),this.messageCenter.dispatch(a.EVENT.RESTORE,null,null,this.myChart),!0},__onMagicType:function(k){var e=k.target._name;return this._magicType[e]||(this._magicType[e]=!0,e===a.CHART_TYPE_LINE?this._magicType[a.CHART_TYPE_BAR]=!1:e===a.CHART_TYPE_BAR&&(this._magicType[a.CHART_TYPE_LINE]=!1),e===a.CHART_TYPE_PIE?this._magicType[a.CHART_TYPE_FUNNEL]=!1:e===a.CHART_TYPE_FUNNEL&&(this._magicType[a.CHART_TYPE_PIE]=!1),e===a.CHART_TYPE_FORCE?this._magicType[a.CHART_TYPE_CHORD]=!1:e===a.CHART_TYPE_CHORD&&(this._magicType[a.CHART_TYPE_FORCE]=!1),"stack"===e?this._magicType.tiled=!1:"tiled"===e&&(this._magicType.stack=!1),this.messageCenter.dispatch(a.EVENT.MAGIC_TYPE_CHANGED,k.event,{magicType:this._magicType},this.myChart)),!0},setMagicType:function(k){this._magicType=k;!this._isSilence&&this.messageCenter.dispatch(a.EVENT.MAGIC_TYPE_CHANGED,null,{magicType:this._magicType},this.myChart)},__onCustomHandler:function(a){a=this.option.toolbox.feature[a.target.style.iconType].onclick;"function"==typeof a&&a.call(this,this.option)},reset:function(a,b){if(b&&this.clear(),this.query(a,"toolbox.show")&&this.query(a,"toolbox.feature.magicType.show")){var c=a.toolbox.feature.magicType.type,d=c.length;for(this._magicMap={};d--;)this._magicMap[c[d]]=!0;for(var d=a.series.length,n;d--;)c=a.series[d].type,this._magicMap[c]&&(n=a.xAxis instanceof Array?a.xAxis[a.series[d].xAxisIndex||0]:a.xAxis,n&&"category"===(n.type||"category")&&(n.__boundaryGap=null!=n.boundaryGap?n.boundaryGap:!0),n=a.yAxis instanceof Array?a.yAxis[a.series[d].yAxisIndex||0]:a.yAxis,n&&"category"===n.type&&(n.__boundaryGap=null!=n.boundaryGap?n.boundaryGap:!0),a.series[d].__type=c,a.series[d].__itemStyle=e.clone(a.series[d].itemStyle||{})),(this._magicMap.stack||this._magicMap.tiled)&&(a.series[d].__stack=a.series[d].stack)}this._magicType=b?{}:this._magicType||{};for(var h in this._magicType)if(this._magicType[h]){this.option=a;this.getMagicOption();break}(n=a.dataZoom)&&n.show?(d=null!=n.start&&0<=n.start&&100>=n.start?n.start:0,n=null!=n.end&&0<=n.end&&100>=n.end?n.end:100,d>n&&(d+=n,n=d-n,d-=n),this._zoomQueue=[{start:d,end:n,start2:0,end2:100}]):this._zoomQueue=[]},getMagicOption:function(){var k,b;if(this._magicType[a.CHART_TYPE_LINE]||this._magicType[a.CHART_TYPE_BAR]){for(var c=this._magicType[a.CHART_TYPE_LINE]?!1:!0,d=0,n=this.option.series.length;n>d;d++)b=this.option.series[d].type,(b==a.CHART_TYPE_LINE||b==a.CHART_TYPE_BAR)&&(k=this.option.xAxis instanceof Array?this.option.xAxis[this.option.series[d].xAxisIndex||0]:this.option.xAxis,k&&"category"===(k.type||"category")&&(k.boundaryGap=c?!0:k.__boundaryGap),k=this.option.yAxis instanceof Array?this.option.yAxis[this.option.series[d].yAxisIndex||0]:this.option.yAxis,k&&"category"===k.type&&(k.boundaryGap=c?!0:k.__boundaryGap));this._defaultMagic(a.CHART_TYPE_LINE,a.CHART_TYPE_BAR)}if(this._defaultMagic(a.CHART_TYPE_CHORD,a.CHART_TYPE_FORCE),this._defaultMagic(a.CHART_TYPE_PIE,a.CHART_TYPE_FUNNEL),this._magicType.stack||this._magicType.tiled)for(d=0,n=this.option.series.length;n>d;d++)this._magicType.stack?(this.option.series[d].stack="_ECHARTS_STACK_KENER_2014_",b="stack"):this._magicType.tiled&&(this.option.series[d].stack=null,b="tiled"),this._featureOption[b+"Chart"]&&e.merge(this.option.series[d],this._featureOption[b+"Chart"]||{},!0);return this.option},_defaultMagic:function(a,b){if(this._magicType[a]||this._magicType[b])for(var c=0,d=this.option.series.length;d>c;c++){var n=this.option.series[c].type;(n==a||n==b)&&(this.option.series[c].type=this._magicType[a]?a:b,this.option.series[c].itemStyle=e.clone(this.option.series[c].__itemStyle),n=this.option.series[c].type,this._featureOption[n+"Chart"]&&e.merge(this.option.series[c],this._featureOption[n+"Chart"]||{},!0))}},silence:function(a){this._isSilence=a},resize:function(){this.clear();this.option&&this.option.toolbox&&this.option.toolbox.show&&this._buildShape()},clear:function(a){this.zr&&(this.zr.delShape(this.shapeList),this.shapeList=[],a||(this.zr.delShape(this._markShapeList),this._markShapeList=[]))},onbeforDispose:function(){this._markShapeList=null},refresh:function(a){a&&(this._resetZoom(),a.toolbox=this.reformOption(a.toolbox),this.option=a,this.clear(!0),a.toolbox.show&&this._buildShape())}},e.inherits(f,q),g("../component").define("toolbox",f),f});define("echarts/component",[],function(){var g={},f={};return g.define=function(q,l){return f[q]=l,g},g.get=function(g){return f[g]},g});define("echarts/component/title","require ./base zrender/shape/Text zrender/shape/Rectangle ../config zrender/tool/util zrender/tool/area zrender/tool/color ../component".split(" "),function(g){function f(a,e,b,c,d){q.call(this,a,e,b,c,d);this.refresh(c)}var q=g("./base"),l=g("zrender/shape/Text"),d=g("zrender/shape/Rectangle"),b=g("../config");b.title={zlevel:0,z:6,show:!0,text:"",subtext:"",x:"center",y:"top",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:1,itemGap:5,textStyle:{fontSize:20,fontWeight:"bolder",color:"#333"},subtextStyle:{color:"#aaa"}};var a=g("zrender/tool/util"),e=g("zrender/tool/area"),m=g("zrender/tool/color");return f.prototype={type:b.COMPONENT_TYPE_TITLE,_buildShape:function(){if(this.titleOption.show){this._itemGroupLocation=this._getItemGroupLocation();this._buildBackground();this._buildItem();for(var a=0,e=this.shapeList.length;e>a;a++)this.zr.addShape(this.shapeList[a])}},_buildItem:function(){var a=this.titleOption.text,e=this.titleOption.link,b=this.titleOption.target,c=this.titleOption.subtext,d=this.titleOption.sublink,n=this.titleOption.subtarget,h=this.getFont(this.titleOption.textStyle),u=this.getFont(this.titleOption.subtextStyle),B=this._itemGroupLocation.x,f=this._itemGroupLocation.y,g=this._itemGroupLocation.width,q=this._itemGroupLocation.height,a={zlevel:this.getZlevelBase(),z:this.getZBase(),style:{y:f,color:this.titleOption.textStyle.color,text:a,textFont:h,textBaseline:"top"},highlightStyle:{color:m.lift(this.titleOption.textStyle.color,1),brushType:"fill"},hoverable:!1};e&&(a.hoverable=!0,a.clickable=!0,a.onclick=function(){b&&"self"==b?window.location=e:window.open(e)});u={zlevel:this.getZlevelBase(),z:this.getZBase(),style:{y:f+q,color:this.titleOption.subtextStyle.color,text:c,textFont:u,textBaseline:"bottom"},highlightStyle:{color:m.lift(this.titleOption.subtextStyle.color,1),brushType:"fill"},hoverable:!1};switch(d&&(u.hoverable=!0,u.clickable=!0,u.onclick=function(){n&&"self"==n?window.location=d:window.open(d)}),this.titleOption.x){case "center":a.style.x=u.style.x=B+g/2;a.style.textAlign=u.style.textAlign="center";break;case "left":a.style.x=u.style.x=B;a.style.textAlign=u.style.textAlign="left";break;case "right":a.style.x=u.style.x=B+g;a.style.textAlign=u.style.textAlign="right";break;default:B=this.titleOption.x-0,B=isNaN(B)?0:B,a.style.x=u.style.x=B}this.titleOption.textAlign&&(a.style.textAlign=u.style.textAlign=this.titleOption.textAlign);this.shapeList.push(new l(a));""!==c&&this.shapeList.push(new l(u))},_buildBackground:function(){var a=this.reformCssArray(this.titleOption.padding);this.shapeList.push(new d({zlevel:this.getZlevelBase(),z:this.getZBase(),hoverable:!1,style:{x:this._itemGroupLocation.x-a[3],y:this._itemGroupLocation.y-a[0],width:this._itemGroupLocation.width+a[3]+a[1],height:this._itemGroupLocation.height+a[0]+a[2],brushType:0===this.titleOption.borderWidth?"fill":"both",color:this.titleOption.backgroundColor,strokeColor:this.titleOption.borderColor,lineWidth:this.titleOption.borderWidth}}))},_getItemGroupLocation:function(){var a,b=this.reformCssArray(this.titleOption.padding),d=this.titleOption.text;a=this.titleOption.subtext;var c=this.getFont(this.titleOption.textStyle),m=this.getFont(this.titleOption.subtextStyle),n=Math.max(e.getTextWidth(d,c),e.getTextWidth(a,m)),d=e.getTextHeight(d,c)+(""===a?0:this.titleOption.itemGap+e.getTextHeight(a,m));a=this.zr.getWidth();switch(this.titleOption.x){case "center":a=Math.floor((a-n)/2);break;case "left":a=b[3]+this.titleOption.borderWidth;break;case "right":a=a-n-b[1]-this.titleOption.borderWidth;break;default:a=this.titleOption.x-0,a=isNaN(a)?0:a}c=this.zr.getHeight();switch(this.titleOption.y){case "top":b=b[0]+this.titleOption.borderWidth;break;case "bottom":b=c-d-b[2]-this.titleOption.borderWidth;break;case "center":b=Math.floor((c-d)/2);break;default:b=this.titleOption.y-0,b=isNaN(b)?0:b}return{x:a,y:b,width:n,height:d}},refresh:function(a){a&&(this.option=a,this.option.title=this.reformOption(this.option.title),this.titleOption=this.option.title,this.titleOption.textStyle=this.getTextStyle(this.titleOption.textStyle),this.titleOption.subtextStyle=this.getTextStyle(this.titleOption.subtextStyle));this.clear();this._buildShape()}},a.inherits(f,q),g("../component").define("title",f),f});define("echarts/component/tooltip","require ./base ../util/shape/Cross zrender/shape/Line zrender/shape/Rectangle ../config ../util/ecData zrender/config zrender/tool/event zrender/tool/area zrender/tool/color zrender/tool/util zrender/shape/Base ../component".split(" "),function(g){function f(a,h,c,e,b){q.call(this,a,h,c,e,b);this.dom=b.dom;var k=this;k._onmousemove=function(a){return k.__onmousemove(a)};k._onglobalout=function(a){return k.__onglobalout(a)};this.zr.on(m.EVENT.CLICK,k._onmousemove);this.zr.on(m.EVENT.MOUSEMOVE,k._onmousemove);this.zr.on(m.EVENT.GLOBALOUT,k._onglobalout);k._hide=function(a){return k.__hide(a)};k._tryShow=function(a){return k.__tryShow(a)};k._refixed=function(a){return k.__refixed(a)};k._setContent=function(a,h){return k.__setContent(a,h)};this._tDom=this._tDom||document.createElement("div");this._tDom.onselectstart=function(){return!1};this._tDom.onmouseover=function(){k._mousein=!0};this._tDom.onmouseout=function(){k._mousein=!1};this._tDom.className="echarts-tooltip";this._tDom.style.position="absolute";this.hasAppend=!1;this._axisLineShape&&this.zr.delShape(this._axisLineShape.id);this._axisLineShape=new d({zlevel:this.getZlevelBase(),z:this.getZBase(),invisible:!0,hoverable:!1});this.shapeList.push(this._axisLineShape);this.zr.addShape(this._axisLineShape);this._axisShadowShape&&this.zr.delShape(this._axisShadowShape.id);this._axisShadowShape=new d({zlevel:this.getZlevelBase(),z:1,invisible:!0,hoverable:!1});this.shapeList.push(this._axisShadowShape);this.zr.addShape(this._axisShadowShape);this._axisCrossShape&&this.zr.delShape(this._axisCrossShape.id);this._axisCrossShape=new l({zlevel:this.getZlevelBase(),z:this.getZBase(),invisible:!0,hoverable:!1});this.shapeList.push(this._axisCrossShape);this.zr.addShape(this._axisCrossShape);this.showing=!1;this.refresh(e)}var q=g("./base"),l=g("../util/shape/Cross"),d=g("zrender/shape/Line"),b=new (g("zrender/shape/Rectangle"))({}),a=g("../config");a.tooltip={zlevel:0,z:8,show:!0,showContent:!0,trigger:"item",islandFormatter:"{a} \x3cbr/\x3e{b} : {c}",showDelay:0,hideDelay:200,transitionDuration:.4,enterable:!1,backgroundColor:"rgba(0,0,0,0.7)",borderColor:"#333",borderRadius:4,borderWidth:0,padding:5,axisPointer:{type:"line",lineStyle:{color:"#48b",width:2,type:"solid"},crossStyle:{color:"#1e90ff",width:1,type:"dashed"},shadowStyle:{color:"rgba(150,150,150,0.3)",width:"auto",type:"default"}},textStyle:{color:"#fff"}};var e=g("../util/ecData"),m=g("zrender/config"),r=g("zrender/tool/event"),k=g("zrender/tool/area"),p=g("zrender/tool/color"),c=g("zrender/tool/util"),t=g("zrender/shape/Base");return f.prototype={type:a.COMPONENT_TYPE_TOOLTIP,_gCssText:"position:absolute;display:block;border-style:solid;white-space:nowrap;",_style:function(a){if(!a)return"";var h=[];if(a.transitionDuration){var c="left "+a.transitionDuration+"s,top "+a.transitionDuration+"s";h.push("transition:"+c);h.push("-moz-transition:"+c);h.push("-webkit-transition:"+c);h.push("-o-transition:"+c)}a.backgroundColor&&(h.push("background-Color:"+p.toHex(a.backgroundColor)),h.push("filter:alpha(opacity\x3d70)"),h.push("background-Color:"+a.backgroundColor));null!=a.borderWidth&&h.push("border-width:"+a.borderWidth+"px");null!=a.borderColor&&h.push("border-color:"+a.borderColor);null!=a.borderRadius&&(h.push("border-radius:"+a.borderRadius+"px"),h.push("-moz-border-radius:"+a.borderRadius+"px"),h.push("-webkit-border-radius:"+a.borderRadius+"px"),h.push("-o-border-radius:"+a.borderRadius+"px"));(c=a.textStyle)&&(c.color&&h.push("color:"+c.color),c.decoration&&h.push("text-decoration:"+c.decoration),c.align&&h.push("text-align:"+c.align),c.fontFamily&&h.push("font-family:"+c.fontFamily),c.fontSize&&h.push("font-size:"+c.fontSize+"px"),c.fontSize&&h.push("line-height:"+Math.round(3*c.fontSize/2)+"px"),c.fontStyle&&h.push("font-style:"+c.fontStyle),c.fontWeight&&h.push("font-weight:"+c.fontWeight));a=a.padding;return null!=a&&(a=this.reformCssArray(a),h.push("padding:"+a[0]+"px "+a[1]+"px "+a[2]+"px "+a[3]+"px")),h.join(";")+";"},__hide:function(){this._lastItemTriggerId=this._lastSeriesIndex=this._lastDataIndex=-1;this._tDom&&(this._tDom.style.display="none");var a=!1;this._axisLineShape.invisible||(this._axisLineShape.invisible=!0,this.zr.modShape(this._axisLineShape.id),a=!0);this._axisShadowShape.invisible||(this._axisShadowShape.invisible=!0,this.zr.modShape(this._axisShadowShape.id),a=!0);this._axisCrossShape.invisible||(this._axisCrossShape.invisible=!0,this.zr.modShape(this._axisCrossShape.id),a=!0);this._lastTipShape&&0<this._lastTipShape.tipShape.length&&(this.zr.delShape(this._lastTipShape.tipShape),this._lastTipShape=!1,this.shapeList.length=2);a&&this.zr.refreshNextFrame();this.showing=!1},_show:function(a,h,c,e){var b=this._tDom.offsetHeight,k=this._tDom.offsetWidth;a&&("function"==typeof a&&(a=a([h,c])),a instanceof Array&&(h=a[0],c=a[1]));h+k>this._zrWidth&&(h-=k+40);c+b>this._zrHeight&&(c-=b-20);20>c&&(c=0);this._tDom.style.cssText=this._gCssText+this._defaultCssText+(e?e:"")+"left:"+h+"px;top:"+c+"px;";(10>b||10>k)&&setTimeout(this._refixed,20);this.showing=!0},__refixed:function(){if(this._tDom){var a="",h=this._tDom.offsetHeight,c=this._tDom.offsetWidth;this._tDom.offsetLeft+c>this._zrWidth&&(a+="left:"+(this._zrWidth-c-20)+"px;");this._tDom.offsetTop+h>this._zrHeight&&(a+="top:"+(this._zrHeight-h-10)+"px;");""!==a&&(this._tDom.style.cssText+=a)}},__tryShow:function(){var a,h;if(this._curTarget){if("island"===this._curTarget._type&&this.option.tooltip.show)return void this._showItemTrigger();var c=e.get(this._curTarget,"series"),b=e.get(this._curTarget,"data");a=this.deepQuery([b,c,this.option],"tooltip.show");null!=c&&null!=b&&a?(h=this.deepQuery([b,c,this.option],"tooltip.trigger"),"axis"===h?this._showAxisTrigger(c.xAxisIndex,c.yAxisIndex,e.get(this._curTarget,"dataIndex")):this._showItemTrigger()):(clearTimeout(this._hidingTicket),clearTimeout(this._showingTicket),this._hidingTicket=setTimeout(this._hide,this._hideDelay))}else this._findPolarTrigger()||this._findAxisTrigger()},_findAxisTrigger:function(){if(!this.component.xAxis||!this.component.yAxis)return void(this._hidingTicket=setTimeout(this._hide,this._hideDelay));for(var n,h,c=this.option.series,e=0,b=c.length;b>e;e++)if("axis"===this.deepQuery([c[e],this.option],"tooltip.trigger"))return n=c[e].xAxisIndex||0,h=c[e].yAxisIndex||0,this.component.xAxis.getAxis(n)&&this.component.xAxis.getAxis(n).type===a.COMPONENT_TYPE_AXIS_CATEGORY?void this._showAxisTrigger(n,h,this._getNearestDataIndex("x",this.component.xAxis.getAxis(n))):this.component.yAxis.getAxis(h)&&this.component.yAxis.getAxis(h).type===a.COMPONENT_TYPE_AXIS_CATEGORY?void this._showAxisTrigger(n,h,this._getNearestDataIndex("y",this.component.yAxis.getAxis(h))):void this._showAxisTrigger(n,h,-1);"cross"===this.option.tooltip.axisPointer.type&&this._showAxisTrigger(-1,-1,-1)},_findPolarTrigger:function(){if(!this.component.polar)return!1;var a,h=r.getX(this._event),c=r.getY(this._event),h=this.component.polar.getNearestIndex([h,c]);return h?(a=h.valueIndex,h=h.polarIndex):h=-1,-1!=h?this._showPolarTrigger(h,a):!1},_getNearestDataIndex:function(a,h){var c=-1,e=r.getX(this._event),b=r.getY(this._event);if("x"===a){for(var k,d,b=this.component.grid.getXend(),m=h.getCoordByIndex(c);b>m&&(d=m,e>=m);)k=m,m=h.getCoordByIndex(++c);return 0>=c?c=0:d-e>=e-k?--c:null==h.getNameByIndex(c)&&--c,c}for(var p,t,e=this.component.grid.getY(),m=h.getCoordByIndex(c);m>e&&(p=m,m>=b);)t=m,m=h.getCoordByIndex(++c);return 0>=c?c=0:b-p>=t-b?--c:null==h.getNameByIndex(c)&&--c,c},_showAxisTrigger:function(c,h,e){if(!this._event.connectTrigger&&this.messageCenter.dispatch(a.EVENT.TOOLTIP_IN_GRID,this._event,null,this.myChart),null==this.component.xAxis||null==this.component.yAxis||null==c||null==h)return clearTimeout(this._hidingTicket),clearTimeout(this._showingTicket),void(this._hidingTicket=setTimeout(this._hide,this._hideDelay));var b,k,d,m,p=this.option.series,t=[],l=[],f="";if("axis"===this.option.tooltip.trigger){if(!this.option.tooltip.show)return;k=this.option.tooltip.formatter;d=this.option.tooltip.position}var g,q,v=-1!=c&&this.component.xAxis.getAxis(c).type===a.COMPONENT_TYPE_AXIS_CATEGORY?"xAxis":-1!=h&&this.component.yAxis.getAxis(h).type===a.COMPONENT_TYPE_AXIS_CATEGORY?"yAxis":!1;if(v){var w="xAxis"==v?c:h;b=this.component[v].getAxis(w);c=0;for(h=p.length;h>c;c++)this._isSelected(p[c].name)&&p[c][v+"Index"]===w&&"axis"===this.deepQuery([p[c],this.option],"tooltip.trigger")&&(m=this.query(p[c],"tooltip.showContent")||m,k=this.query(p[c],"tooltip.formatter")||k,d=this.query(p[c],"tooltip.position")||d,f+=this._style(this.query(p[c],"tooltip")),null!=p[c].stack&&"xAxis"==v?(t.unshift(p[c]),l.unshift(c)):(t.push(p[c]),l.push(c)));this.messageCenter.dispatch(a.EVENT.TOOLTIP_HOVER,this._event,{seriesIndex:l,dataIndex:e},this.myChart);var E;"xAxis"==v?(g=this.subPixelOptimize(b.getCoordByIndex(e),this._axisLineWidth),q=r.getY(this._event),E=[g,this.component.grid.getY(),g,this.component.grid.getYend()]):(g=r.getX(this._event),q=this.subPixelOptimize(b.getCoordByIndex(e),this._axisLineWidth),E=[this.component.grid.getX(),q,this.component.grid.getXend(),q]);this._styleAxisPointer(t,E[0],E[1],E[2],E[3],b.getGap(),g,q)}else g=r.getX(this._event),q=r.getY(this._event),this._styleAxisPointer(p,this.component.grid.getX(),q,this.component.grid.getXend(),q,0,g,q),0<=e?this._showItemTrigger(!0):(clearTimeout(this._hidingTicket),clearTimeout(this._showingTicket),this._tDom.style.display="none");if(0<t.length){if(this._lastItemTriggerId=-1,this._lastDataIndex!=e||this._lastSeriesIndex!=l[0])if(this._lastDataIndex=e,this._lastSeriesIndex=l[0],"function"==typeof k){E=[];c=0;for(h=t.length;h>c;c++)p=t[c].data[e],v=this.getDataFromOption(p,"-"),E.push({seriesIndex:l[c],seriesName:t[c].name||"",series:t[c],dataIndex:e,data:p,name:b.getNameByIndex(e),value:v,0:t[c].name||"",1:b.getNameByIndex(e),2:v,3:p});this._curTicket="axis:"+e;this._tDom.innerHTML=k.call(this.myChart,E,this._curTicket,this._setContent)}else{if("string"==typeof k)for(this._curTicket=0/0,k=k.replace("{a}","{a0}").replace("{b}","{b0}").replace("{c}","{c0}"),c=0,h=t.length;h>c;c++)k=k.replace("{a"+c+"}",this._encodeHTML(t[c].name||"")),k=k.replace("{b"+c+"}",this._encodeHTML(b.getNameByIndex(e))),p=t[c].data[e],p=this.getDataFromOption(p,"-"),k=k.replace("{c"+c+"}",p instanceof Array?p:this.numAddCommas(p));else for(this._curTicket=0/0,k=this._encodeHTML(b.getNameByIndex(e)),c=0,h=t.length;h>c;c++)k+="\x3cbr/\x3e"+this._encodeHTML(t[c].name||"")+" : ",p=t[c].data[e],p=this.getDataFromOption(p,"-"),k+=p instanceof Array?p:this.numAddCommas(p);this._tDom.innerHTML=k}!1!==m&&this.option.tooltip.showContent&&(this.hasAppend||(this._tDom.style.left=this._zrWidth/2+"px",this._tDom.style.top=this._zrHeight/2+"px",this.dom.firstChild.appendChild(this._tDom),this.hasAppend=!0),this._show(d,g+10,q+10,f))}},_showPolarTrigger:function(a,h){if(null==this.component.polar||null==a||null==h||0>h)return!1;var c,e,b,k=this.option.series,d=[],p=[],m="";if("axis"===this.option.tooltip.trigger){if(!this.option.tooltip.show)return!1;c=this.option.tooltip.formatter;e=this.option.tooltip.position}for(var t=this.option.polar[a].indicator[h].text,l=0,f=k.length;f>l;l++)this._isSelected(k[l].name)&&k[l].polarIndex===a&&"axis"===this.deepQuery([k[l],this.option],"tooltip.trigger")&&(b=this.query(k[l],"tooltip.showContent")||b,c=this.query(k[l],"tooltip.formatter")||c,e=this.query(k[l],"tooltip.position")||e,m+=this._style(this.query(k[l],"tooltip")),d.push(k[l]),p.push(l));if(0<d.length){for(var g,q,w=[],l=0,f=d.length;f>l;l++)for(var k=d[l].data,E=0,A=k.length;A>E;E++)g=k[E],this._isSelected(g.name)&&(g=null!=g?g:{name:"",value:{dataIndex:"-"}},q=this.getDataFromOption(g.value[h]),w.push({seriesIndex:p[l],seriesName:d[l].name||"",series:d[l],dataIndex:h,data:g,name:g.name,indicator:t,value:q,0:d[l].name||"",1:g.name,2:q,3:t}));if(!(0>=w.length)){if(this._lastItemTriggerId=-1,this._lastDataIndex!=h||this._lastSeriesIndex!=p[0])if(this._lastDataIndex=h,this._lastSeriesIndex=p[0],"function"==typeof c)this._curTicket="axis:"+h,this._tDom.innerHTML=c.call(this.myChart,w,this._curTicket,this._setContent);else{if("string"==typeof c)for(c=c.replace("{a}","{a0}").replace("{b}","{b0}").replace("{c}","{c0}").replace("{d}","{d0}"),l=0,f=w.length;f>l;l++)c=c.replace("{a"+l+"}",this._encodeHTML(w[l].seriesName)),c=c.replace("{b"+l+"}",this._encodeHTML(w[l].name)),c=c.replace("{c"+l+"}",this.numAddCommas(w[l].value)),c=c.replace("{d"+l+"}",this._encodeHTML(w[l].indicator));else for(c=this._encodeHTML(w[0].name)+"\x3cbr/\x3e"+this._encodeHTML(w[0].indicator)+" : "+this.numAddCommas(w[0].value),l=1,f=w.length;f>l;l++)c+="\x3cbr/\x3e"+this._encodeHTML(w[l].name)+"\x3cbr/\x3e",c+=this._encodeHTML(w[l].indicator)+" : "+this.numAddCommas(w[l].value);this._tDom.innerHTML=c}if(!1!==b&&this.option.tooltip.showContent)return this.hasAppend||(this._tDom.style.left=this._zrWidth/2+"px",this._tDom.style.top=this._zrHeight/2+"px",this.dom.firstChild.appendChild(this._tDom),this.hasAppend=!0),this._show(e,r.getX(this._event),r.getY(this._event),m),!0}}},_showItemTrigger:function(c){if(this._curTarget){var h,b,k,d=e.get(this._curTarget,"series"),p=e.get(this._curTarget,"seriesIndex"),m=e.get(this._curTarget,"data"),t=e.get(this._curTarget,"dataIndex"),l=e.get(this._curTarget,"name"),f=e.get(this._curTarget,"value"),g=e.get(this._curTarget,"special"),q=e.get(this._curTarget,"special2"),y=[m,d,this.option],v="";"island"!=this._curTarget._type?(c=c?"axis":"item",this.option.tooltip.trigger===c&&(h=this.option.tooltip.formatter,b=this.option.tooltip.position),this.query(d,"tooltip.trigger")===c&&(k=this.query(d,"tooltip.showContent")||k,h=this.query(d,"tooltip.formatter")||h,b=this.query(d,"tooltip.position")||b,v+=this._style(this.query(d,"tooltip"))),k=this.query(m,"tooltip.showContent")||k,h=this.query(m,"tooltip.formatter")||h,b=this.query(m,"tooltip.position")||b,v+=this._style(this.query(m,"tooltip"))):(this._lastItemTriggerId=0/0,k=this.deepQuery(y,"tooltip.showContent"),h=this.deepQuery(y,"tooltip.islandFormatter"),b=this.deepQuery(y,"tooltip.islandPosition"));this._lastSeriesIndex=this._lastDataIndex=-1;this._lastItemTriggerId!==this._curTarget.id&&(this._lastItemTriggerId=this._curTarget.id,"function"==typeof h?(this._curTicket=(d.name||"")+":"+t,this._tDom.innerHTML=h.call(this.myChart,{seriesIndex:p,seriesName:d.name||"",series:d,dataIndex:t,data:m,name:l,value:f,percent:g,indicator:g,value2:q,indicator2:q,0:d.name||"",1:l,2:f,3:g,4:q,5:m,6:p,7:t},this._curTicket,this._setContent)):"string"==typeof h?(this._curTicket=0/0,h=h.replace("{a}","{a0}").replace("{b}","{b0}").replace("{c}","{c0}"),h=h.replace("{a0}",this._encodeHTML(d.name||"")).replace("{b0}",this._encodeHTML(l)).replace("{c0}",f instanceof Array?f:this.numAddCommas(f)),h=h.replace("{d}","{d0}").replace("{d0}",g||""),h=h.replace("{e}","{e0}").replace("{e0}",e.get(this._curTarget,"special2")||""),this._tDom.innerHTML=h):(this._curTicket=0/0,this._tDom.innerHTML=d.type===a.CHART_TYPE_RADAR&&g?this._itemFormatter.radar.call(this,d,l,f,g):d.type===a.CHART_TYPE_EVENTRIVER?this._itemFormatter.eventRiver.call(this,d,l,f,m):""+(null!=d.name?this._encodeHTML(d.name)+"\x3cbr/\x3e":"")+(""===l?"":this._encodeHTML(l)+" : ")+(f instanceof Array?f:this.numAddCommas(f))));h=r.getX(this._event);p=r.getY(this._event);this.deepQuery(y,"tooltip.axisPointer.show")&&this.component.grid&&this._styleAxisPointer([d],this.component.grid.getX(),p,this.component.grid.getXend(),p,0,h,p);!1!==k&&this.option.tooltip.showContent&&(this.hasAppend||(this._tDom.style.left=this._zrWidth/2+"px",this._tDom.style.top=this._zrHeight/2+"px",this.dom.firstChild.appendChild(this._tDom),this.hasAppend=!0),this._show(b,h+20,p-20,v))}},_itemFormatter:{radar:function(a,h,c,e){a=""+this._encodeHTML(""===h?a.name||"":h);a+=""===a?"":"\x3cbr /\x3e";for(h=0;h<e.length;h++)a+=this._encodeHTML(e[h].text)+" : "+this.numAddCommas(c[h])+"\x3cbr /\x3e";return a},chord:function(a,h,c,e,b){if(null==b)return this._encodeHTML(h)+" ("+this.numAddCommas(c)+")";h=this._encodeHTML(h);e=this._encodeHTML(e);return""+(null!=a.name?this._encodeHTML(a.name)+"\x3cbr/\x3e":"")+h+" -\x3e "+e+" ("+this.numAddCommas(c)+")\x3cbr /\x3e"+e+" -\x3e "+h+" ("+this.numAddCommas(b)+")"},eventRiver:function(a,h,c,e){a=""+this._encodeHTML(""===a.name?"":a.name+" : ");a+=this._encodeHTML(h);a+=""===a?"":"\x3cbr /\x3e";e=e.evolution;h=0;for(c=e.length;c>h;h++)a+='\x3cdiv style\x3d"padding-top:5px;"\x3e',e[h].detail&&(e[h].detail.img&&(a+='\x3cimg src\x3d"'+e[h].detail.img+'" style\x3d"float:left;width:40px;height:40px;"\x3e'),a+='\x3cdiv style\x3d"margin-left:45px;"\x3e'+e[h].time+"\x3cbr/\x3e",a+='\x3ca href\x3d"'+e[h].detail.link+'" target\x3d"_blank"\x3e',a+=e[h].detail.text+"\x3c/a\x3e\x3c/div\x3e",a+="\x3c/div\x3e");return a}},_styleAxisPointer:function(a,h,c,e,b,k,d,p){if(0<a.length){var m,t;m=this.option.tooltip.axisPointer;var r=m.type,l={line:{},cross:{},shadow:{}};for(t in l)l[t].color=m[t+"Style"].color,l[t].width=m[t+"Style"].width,l[t].type=m[t+"Style"].type;for(var f=0,g=a.length;g>f;f++)m=a[f],r=(t=this.query(m,"tooltip.axisPointer.type"))||r,t&&(l[t].color=this.query(m,"tooltip.axisPointer."+t+"Style.color")||l[t].color,l[t].width=this.query(m,"tooltip.axisPointer."+t+"Style.width")||l[t].width,l[t].type=this.query(m,"tooltip.axisPointer."+t+"Style.type")||l[t].type);"line"===r?(d=l.line.width,p=h==e,this._axisLineShape.style={xStart:p?this.subPixelOptimize(h,d):h,yStart:p?c:this.subPixelOptimize(c,d),xEnd:p?this.subPixelOptimize(e,d):e,yEnd:p?b:this.subPixelOptimize(b,d),strokeColor:l.line.color,lineWidth:d,lineType:l.line.type},this._axisLineShape.invisible=!1,this.zr.modShape(this._axisLineShape.id)):"cross"===r?(h=l.cross.width,this._axisCrossShape.style={brushType:"stroke",rect:this.component.grid.getArea(),x:this.subPixelOptimize(d,h),y:this.subPixelOptimize(p,h),text:("( "+this.component.xAxis.getAxis(0).getValueFromCoord(d)+" , "+this.component.yAxis.getAxis(0).getValueFromCoord(p)+" )").replace(" , "," ").replace(" , "," "),textPosition:"specific",strokeColor:l.cross.color,lineWidth:h,lineType:l.cross.type},100<this.component.grid.getXend()-d?(this._axisCrossShape.style.textAlign="left",this._axisCrossShape.style.textX=d+10):(this._axisCrossShape.style.textAlign="right",this._axisCrossShape.style.textX=d-10),50<p-this.component.grid.getY()?(this._axisCrossShape.style.textBaseline="bottom",this._axisCrossShape.style.textY=p-10):(this._axisCrossShape.style.textBaseline="top",this._axisCrossShape.style.textY=p+10),this._axisCrossShape.invisible=!1,this.zr.modShape(this._axisCrossShape.id)):"shadow"===r&&((null==l.shadow.width||"auto"===l.shadow.width||isNaN(l.shadow.width))&&(l.shadow.width=k),h===e?2>Math.abs(this.component.grid.getX()-h)?(l.shadow.width/=2,h=e+=l.shadow.width/2):2>Math.abs(this.component.grid.getXend()-h)&&(l.shadow.width/=2,h=e-=l.shadow.width/2):c===b&&(2>Math.abs(this.component.grid.getY()-c)?(l.shadow.width/=2,c=b+=l.shadow.width/2):2>Math.abs(this.component.grid.getYend()-c)&&(l.shadow.width/=2,c=b-=l.shadow.width/2)),this._axisShadowShape.style={xStart:h,yStart:c,xEnd:e,yEnd:b,strokeColor:l.shadow.color,lineWidth:l.shadow.width},this._axisShadowShape.invisible=!1,this.zr.modShape(this._axisShadowShape.id));this.zr.refreshNextFrame()}},__onmousemove:function(c){if(clearTimeout(this._hidingTicket),clearTimeout(this._showingTicket),!this._mousein||!this._enterable){var h=c.target,e=r.getX(c.event),d=r.getY(c.event);if(h){this._curTarget=h;this._event=c.event;this._event.zrenderX=e;this._event.zrenderY=d;var p;if(this._needAxisTrigger&&this.component.polar&&-1!=(p=this.component.polar.isInside([e,d])))for(c=this.option.series,h=0,e=c.length;e>h;h++)if(c[h].polarIndex===p&&"axis"===this.deepQuery([c[h],this.option],"tooltip.trigger")){this._curTarget=null;break}this._showingTicket=setTimeout(this._tryShow,this._showDelay)}else this._curTarget=!1,this._event=c.event,this._event.zrenderX=e,this._event.zrenderY=d,this._needAxisTrigger&&this.component.grid&&k.isInside(b,this.component.grid.getArea(),e,d)?this._showingTicket=setTimeout(this._tryShow,this._showDelay):this._needAxisTrigger&&this.component.polar&&-1!=this.component.polar.isInside([e,d])?this._showingTicket=setTimeout(this._tryShow,this._showDelay):(!this._event.connectTrigger&&this.messageCenter.dispatch(a.EVENT.TOOLTIP_OUT_GRID,this._event,null,this.myChart),this._hidingTicket=setTimeout(this._hide,this._hideDelay))}},__onglobalout:function(){clearTimeout(this._hidingTicket);clearTimeout(this._showingTicket);this._hidingTicket=setTimeout(this._hide,this._hideDelay)},__setContent:function(a,h){this._tDom&&(a===this._curTicket&&(this._tDom.innerHTML=h),setTimeout(this._refixed,20))},ontooltipHover:function(a,h){if(!this._lastTipShape||this._lastTipShape&&this._lastTipShape.dataIndex!=a.dataIndex){this._lastTipShape&&0<this._lastTipShape.tipShape.length&&(this.zr.delShape(this._lastTipShape.tipShape),this.shapeList.length=2);for(var c=0,e=h.length;e>c;c++)h[c].zlevel=this.getZlevelBase(),h[c].z=this.getZBase(),h[c].style=t.prototype.getHighlightStyle(h[c].style,h[c].highlightStyle),h[c].draggable=!1,h[c].hoverable=!1,h[c].clickable=!1,h[c].ondragend=null,h[c].ondragover=null,h[c].ondrop=null,this.shapeList.push(h[c]),this.zr.addShape(h[c]);this._lastTipShape={dataIndex:a.dataIndex,tipShape:h}}},ondragend:function(){this._hide()},onlegendSelected:function(a){this._selectedMap=a.selected},_setSelectedMap:function(){this._selectedMap=this.component.legend?c.clone(this.component.legend.getSelectedMap()):{}},_isSelected:function(a){return null!=this._selectedMap[a]?this._selectedMap[a]:!0},showTip:function(c){if(c){var h,b=this.option.series;if(null!=c.seriesIndex)h=c.seriesIndex;else for(var k=c.seriesName,d=0,p=b.length;p>d;d++)if(b[d].name===k){h=d;break}b=b[h];if(null!=b){var t=this.myChart.chart[b.type],d="axis"===this.deepQuery([b,this.option],"tooltip.trigger");if(t)if(d)switch(c=c.dataIndex,t.type){case a.CHART_TYPE_LINE:case a.CHART_TYPE_BAR:case a.CHART_TYPE_K:if(null==this.component.xAxis||null==this.component.yAxis||b.data.length<=c)break;var r=b.xAxisIndex||0,l=b.yAxisIndex||0;this._event=this.component.xAxis.getAxis(r).type===a.COMPONENT_TYPE_AXIS_CATEGORY?{zrenderX:this.component.xAxis.getAxis(r).getCoordByIndex(c),zrenderY:this.component.grid.getY()+(this.component.grid.getYend()-this.component.grid.getY())/4}:{zrenderX:this.component.grid.getX()+(this.component.grid.getXend()-this.component.grid.getX())/4,zrenderY:this.component.yAxis.getAxis(l).getCoordByIndex(c)};this._showAxisTrigger(r,l,c);break;case a.CHART_TYPE_RADAR:null==this.component.polar||b.data[0].value.length<=c||(r=b.polarIndex||0,l=this.component.polar.getVector(r,c,"max"),this._event={zrenderX:l[0],zrenderY:l[1]},this._showPolarTrigger(r,c))}else{k=t.shapeList;switch(t.type){case a.CHART_TYPE_LINE:case a.CHART_TYPE_BAR:case a.CHART_TYPE_K:case a.CHART_TYPE_SCATTER:c=c.dataIndex;d=0;for(p=k.length;p>d;d++)if(null==k[d]._mark&&e.get(k[d],"seriesIndex")==h&&e.get(k[d],"dataIndex")==c){this._curTarget=k[d];r=k[d].style.x;l=t.type!=a.CHART_TYPE_K?k[d].style.y:k[d].style.y[0];break}break;case a.CHART_TYPE_RADAR:c=c.dataIndex;d=0;for(p=k.length;p>d;d++)if("polygon"===k[d].type&&e.get(k[d],"seriesIndex")==h&&e.get(k[d],"dataIndex")==c){this._curTarget=k[d];l=this.component.polar.getCenter(b.polarIndex||0);r=l[0];l=l[1];break}break;case a.CHART_TYPE_PIE:c=c.name;d=0;for(p=k.length;p>d;d++)if("sector"===k[d].type&&e.get(k[d],"seriesIndex")==h&&e.get(k[d],"name")==c){this._curTarget=k[d];h=this._curTarget.style;d=(h.startAngle+h.endAngle)/2*Math.PI/180;r=this._curTarget.style.x+Math.cos(d)*h.r/1.5;l=this._curTarget.style.y-Math.sin(d)*h.r/1.5;break}break;case a.CHART_TYPE_MAP:c=c.name;h=b.mapType;d=0;for(p=k.length;p>d;d++)if("text"===k[d].type&&k[d]._mapType===h&&k[d].style._name===c){this._curTarget=k[d];r=this._curTarget.style.x+this._curTarget.position[0];l=this._curTarget.style.y+this._curTarget.position[1];break}break;case a.CHART_TYPE_CHORD:c=c.name;d=0;for(p=k.length;p>d;d++)if("sector"===k[d].type&&e.get(k[d],"name")==c)return this._curTarget=k[d],h=this._curTarget.style,d=(h.startAngle+h.endAngle)/2*Math.PI/180,r=this._curTarget.style.x+Math.cos(d)*(h.r-2),l=this._curTarget.style.y-Math.sin(d)*(h.r-2),void this.zr.trigger(m.EVENT.MOUSEMOVE,{zrenderX:r,zrenderY:l});break;case a.CHART_TYPE_FORCE:for(c=c.name,d=0,p=k.length;p>d;d++)if("circle"===k[d].type&&e.get(k[d],"name")==c){this._curTarget=k[d];r=this._curTarget.position[0];l=this._curTarget.position[1];break}}null!=r&&null!=l&&(this._event={zrenderX:r,zrenderY:l},this.zr.addHoverShape(this._curTarget),this.zr.refreshHover(),this._showItemTrigger())}}}},hideTip:function(){this._hide()},refresh:function(a){if(this._zrHeight=this.zr.getHeight(),this._zrWidth=this.zr.getWidth(),this._lastTipShape&&0<this._lastTipShape.tipShape.length&&this.zr.delShape(this._lastTipShape.tipShape),this._lastTipShape=!1,this.shapeList.length=2,this._lastDataIndex=-1,this._lastSeriesIndex=-1,this._lastItemTriggerId=-1,a){this.option=a;this.option.tooltip=this.reformOption(this.option.tooltip);this.option.tooltip.textStyle=c.merge(this.option.tooltip.textStyle,this.ecTheme.textStyle);this._needAxisTrigger=!1;"axis"===this.option.tooltip.trigger&&(this._needAxisTrigger=!0);a=this.option.series;for(var h=0,e=a.length;e>h;h++)if("axis"===this.query(a[h],"tooltip.trigger")){this._needAxisTrigger=!0;break}this._showDelay=this.option.tooltip.showDelay;this._hideDelay=this.option.tooltip.hideDelay;this._defaultCssText=this._style(this.option.tooltip);this._setSelectedMap();this._axisLineWidth=this.option.tooltip.axisPointer.lineStyle.width;this._enterable=this.option.tooltip.enterable}if(this.showing){var b=this;setTimeout(function(){b.zr.trigger(m.EVENT.MOUSEMOVE,b.zr.handler._event)},50)}},onbeforDispose:function(){this._lastTipShape&&0<this._lastTipShape.tipShape.length&&this.zr.delShape(this._lastTipShape.tipShape);clearTimeout(this._hidingTicket);clearTimeout(this._showingTicket);this.zr.un(m.EVENT.CLICK,this._onmousemove);this.zr.un(m.EVENT.MOUSEMOVE,this._onmousemove);this.zr.un(m.EVENT.GLOBALOUT,this._onglobalout);this.hasAppend&&this.dom.firstChild&&this.dom.firstChild.removeChild(this._tDom);this._tDom=null},_encodeHTML:function(a){return String(a).replace(/&/g,"\x26amp;").replace(/</g,"\x26lt;").replace(/>/g,"\x26gt;").replace(/"/g,"\x26quot;").replace(/'/g,"\x26#39;")}},c.inherits(f,q),g("../component").define("tooltip",f),f});define("echarts/component/legend","require ./base zrender/shape/Text zrender/shape/Rectangle zrender/shape/Sector ../util/shape/Icon ../util/shape/Candle ../config zrender/tool/util zrender/tool/area ../component".split(" "),function(g){function f(a,c,h,e,b){if(!this.query(e,"legend.data"))return void console.error("option.legend.data has not been defined.");q.call(this,a,c,h,e,b);var k=this;k._legendSelected=function(a){k.__legendSelected(a)};this._colorIndex=0;this._colorMap={};this._selectedMap={};this._hasDataMap={};this.refresh(e)}var q=g("./base"),l=g("zrender/shape/Text"),d=g("zrender/shape/Rectangle"),b=g("zrender/shape/Sector"),a=g("../util/shape/Icon"),e=g("../util/shape/Candle"),m=g("../config");m.legend={zlevel:0,z:4,show:!0,orient:"horizontal",x:"center",y:"top",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:1,itemGap:10,itemWidth:18,itemHeight:18,textStyle:{fontSize:18,color:"#333"},selectedMode:!0};var r=g("zrender/tool/util"),k=g("zrender/tool/area");f.prototype={type:m.COMPONENT_TYPE_LEGEND,_buildShape:function(){if(this.legendOption.show){this._itemGroupLocation=this._getItemGroupLocation();this._buildBackground();this._buildItem();for(var a=0,c=this.shapeList.length;c>a;a++)this.zr.addShape(this.shapeList[a])}},_buildItem:function(){var c,e,h,b,d,p,m,f,g=this.legendOption.data,q=g.length,G=this.legendOption.textStyle,K=this.zr.getWidth(),C=this.zr.getHeight(),y=this._itemGroupLocation.x,v=this._itemGroupLocation.y,w=this.legendOption.itemWidth,E=this.legendOption.itemHeight,A=this.legendOption.itemGap;"vertical"===this.legendOption.orient&&"right"===this.legendOption.x&&(y=this._itemGroupLocation.x+this._itemGroupLocation.width-w);for(var F=0;q>F;F++)d=r.merge(g[F].textStyle||{},G),p=this.getFont(d),c=this._getName(g[F]),m=this._getFormatterName(c),""!==c?(e=g[F].icon||this._getSomethingByName(c).type,f=this.getColor(c),"horizontal"===this.legendOption.orient?200>K-y&&w+5+k.getTextWidth(m,p)+(F===q-1||""===g[F+1]?0:A)>=K-y&&(y=this._itemGroupLocation.x,v+=E+A):200>C-v&&E+(F===q-1||""===g[F+1]?0:A)>=C-v&&("right"===this.legendOption.x?y-=this._itemGroupLocation.maxWidth+A:y+=this._itemGroupLocation.maxWidth+A,v=this._itemGroupLocation.y),h=this._getItemShapeByType(y,v,w,E,this._selectedMap[c]&&this._hasDataMap[c]?f:"#ccc",e,f),h._name=c,h=new a(h),b={zlevel:this.getZlevelBase(),z:this.getZBase(),style:{x:y+w+5,y:v+E/2,color:this._selectedMap[c]?"auto"===d.color?f:d.color:"#ccc",text:m,textFont:p,textBaseline:"middle"},highlightStyle:{color:f,brushType:"fill"},hoverable:!!this.legendOption.selectedMode,clickable:!!this.legendOption.selectedMode},"vertical"===this.legendOption.orient&&"right"===this.legendOption.x&&(b.style.x-=w+10,b.style.textAlign="right"),b._name=c,b=new l(b),this.legendOption.selectedMode&&(h.onclick=b.onclick=this._legendSelected,h.onmouseover=b.onmouseover=this._dispatchHoverLink,h.hoverConnect=b.id,b.hoverConnect=h.id),this.shapeList.push(h),this.shapeList.push(b),"horizontal"===this.legendOption.orient?y+=w+5+k.getTextWidth(m,p)+A:v+=E+A):"horizontal"===this.legendOption.orient?(y=this._itemGroupLocation.x,v+=E+A):("right"===this.legendOption.x?y-=this._itemGroupLocation.maxWidth+A:y+=this._itemGroupLocation.maxWidth+A,v=this._itemGroupLocation.y);"horizontal"===this.legendOption.orient&&"center"===this.legendOption.x&&v!=this._itemGroupLocation.y&&this._mLineOptimize()},_getName:function(a){return"undefined"!=typeof a.name?a.name:a},_getFormatterName:function(a){var c=this.legendOption.formatter;return"function"==typeof c?c.call(this.myChart,a):"string"==typeof c?c.replace("{name}",a):a},_getFormatterNameFromData:function(a){a=this._getName(a);return this._getFormatterName(a)},_mLineOptimize:function(){for(var a=[],c=this._itemGroupLocation.x,h=2,e=this.shapeList.length;e>h;h++)this.shapeList[h].style.x===c?a.push((this._itemGroupLocation.width-(this.shapeList[h-1].style.x+k.getTextWidth(this.shapeList[h-1].style.text,this.shapeList[h-1].style.textFont)-c))/2):h===e-1&&a.push((this._itemGroupLocation.width-(this.shapeList[h].style.x+k.getTextWidth(this.shapeList[h].style.text,this.shapeList[h].style.textFont)-c))/2);for(var b=-1,h=1,e=this.shapeList.length;e>h;h++)this.shapeList[h].style.x===c&&b++,0!==a[b]&&(this.shapeList[h].style.x+=a[b])},_buildBackground:function(){var a=this.reformCssArray(this.legendOption.padding);this.shapeList.push(new d({zlevel:this.getZlevelBase(),z:this.getZBase(),hoverable:!1,style:{x:this._itemGroupLocation.x-a[3],y:this._itemGroupLocation.y-a[0],width:this._itemGroupLocation.width+a[3]+a[1],height:this._itemGroupLocation.height+a[0]+a[2],brushType:0===this.legendOption.borderWidth?"fill":"both",color:this.legendOption.backgroundColor,strokeColor:this.legendOption.borderColor,lineWidth:this.legendOption.borderWidth}}))},_getItemGroupLocation:function(){var a=this.legendOption.data,c=a.length,h=this.legendOption.itemGap,e=this.legendOption.itemWidth+5,b=this.legendOption.itemHeight,d=this.legendOption.textStyle,p=this.getFont(d),m=0,l=0,f=this.reformCssArray(this.legendOption.padding),g=this.zr.getWidth()-f[1]-f[3],q=this.zr.getHeight()-f[0]-f[2],C=0,y=0;if("horizontal"===this.legendOption.orient)for(var l=b,v=0;c>v;v++)""!==this._getName(a[v])?(q=k.getTextWidth(this._getFormatterNameFromData(a[v]),a[v].textStyle?this.getFont(r.merge(a[v].textStyle||{},d)):p),C+e+q+h>g?(C-=h,m=Math.max(m,C),l+=b+h,C=0):(C+=e+q+h,m=Math.max(m,C-h))):(C-=h,m=Math.max(m,C),l+=b+h,C=0);else{for(v=0;c>v;v++)y=Math.max(y,k.getTextWidth(this._getFormatterNameFromData(a[v]),a[v].textStyle?this.getFont(r.merge(a[v].textStyle||{},d)):p));m=y+=e;for(v=0;c>v;v++)""!==this._getName(a[v])?C+b+h>q?(m+=y+h,C-=h,l=Math.max(l,C),C=0):(C+=b+h,l=Math.max(l,C-h)):(m+=y+h,C-=h,l=Math.max(l,C),C=0)}g=this.zr.getWidth();q=this.zr.getHeight();switch(this.legendOption.x){case "center":a=Math.floor((g-m)/2);break;case "left":a=f[3]+this.legendOption.borderWidth;break;case "right":a=g-m-f[1]-f[3]-2*this.legendOption.borderWidth;break;default:a=this.parsePercent(this.legendOption.x,g)}switch(this.legendOption.y){case "top":f=f[0]+this.legendOption.borderWidth;break;case "bottom":f=q-l-f[0]-f[2]-2*this.legendOption.borderWidth;break;case "center":f=Math.floor((q-l)/2);break;default:f=this.parsePercent(this.legendOption.y,q)}return{x:a,y:f,width:m,height:l,maxWidth:y}},_getSomethingByName:function(a){for(var c,h=this.option.series,e=0,b=h.length;b>e;e++){if(h[e].name===a)return{type:h[e].type,series:h[e],seriesIndex:e,data:null,dataIndex:-1};if(h[e].type===m.CHART_TYPE_PIE||h[e].type===m.CHART_TYPE_RADAR||h[e].type===m.CHART_TYPE_CHORD||h[e].type===m.CHART_TYPE_FORCE||h[e].type===m.CHART_TYPE_FUNNEL){c=h[e].categories||h[e].data||h[e].nodes;for(var d=0,k=c.length;k>d;d++)if(c[d].name===a)return{type:h[e].type,series:h[e],seriesIndex:e,data:c[d],dataIndex:d}}}return{type:"bar",series:null,seriesIndex:-1,data:null,dataIndex:-1}},_getItemShapeByType:function(a,c,h,e,b,d,k){var p;k="#ccc"===b?k:b;a={zlevel:this.getZlevelBase(),z:this.getZBase(),style:{iconType:"legendicon"+d,x:a,y:c,width:h,height:e,color:b,strokeColor:b,lineWidth:2},highlightStyle:{color:k,strokeColor:k,lineWidth:1},hoverable:this.legendOption.selectedMode,clickable:this.legendOption.selectedMode};d.match("image")&&(p=d.replace(/^image:\/\//,""),d="image");switch(d){case "line":a.style.brushType="stroke";a.highlightStyle.lineWidth=3;break;case "radar":case "scatter":a.highlightStyle.lineWidth=3;break;case "k":a.style.brushType="both";a.highlightStyle.lineWidth=3;a.highlightStyle.color=a.style.color=this.deepQuery([this.ecTheme,m],"k.itemStyle.normal.color")||"#fff";a.style.strokeColor="#ccc"!=b?this.deepQuery([this.ecTheme,m],"k.itemStyle.normal.lineStyle.color")||"#ff3200":b;break;case "image":a.style.iconType="image",a.style.image=p,"#ccc"===b&&(a.style.opacity=.5)}return a},__legendSelected:function(a){var c=a.target._name;if("single"===this.legendOption.selectedMode)for(var h in this._selectedMap)this._selectedMap[h]=!1;this._selectedMap[c]=!this._selectedMap[c];this.messageCenter.dispatch(m.EVENT.LEGEND_SELECTED,a.event,{selected:this._selectedMap,target:c},this.myChart)},refresh:function(a){if(a){this.option=a||this.option;this.option.legend=this.reformOption(this.option.legend);this.legendOption=this.option.legend;var c,h,e,b;a=this.legendOption.data||[];if(this.legendOption.selected)for(c in this.legendOption.selected)this._selectedMap[c]="undefined"!=typeof this._selectedMap[c]?this._selectedMap[c]:this.legendOption.selected[c];for(var d=0,k=a.length;k>d;d++)c=this._getName(a[d]),""!==c&&(h=this._getSomethingByName(c),h.series?(this._hasDataMap[c]=!0,b=!h.data||h.type!==m.CHART_TYPE_PIE&&h.type!==m.CHART_TYPE_FORCE&&h.type!==m.CHART_TYPE_FUNNEL?[h.series]:[h.data,h.series],e=this.getItemStyleColor(this.deepQuery(b,"itemStyle.normal.color"),h.seriesIndex,h.dataIndex,h.data),e&&h.type!=m.CHART_TYPE_K&&this.setColor(c,e),this._selectedMap[c]=null!=this._selectedMap[c]?this._selectedMap[c]:!0):this._hasDataMap[c]=!1)}this.clear();this._buildShape()},getRelatedAmount:function(a){for(var c,h=0,e=this.option.series,b=0,d=e.length;d>b;b++)if(e[b].name===a&&h++,e[b].type===m.CHART_TYPE_PIE||e[b].type===m.CHART_TYPE_RADAR||e[b].type===m.CHART_TYPE_CHORD||e[b].type===m.CHART_TYPE_FORCE||e[b].type===m.CHART_TYPE_FUNNEL){c=e[b].type!=m.CHART_TYPE_FORCE?e[b].data:e[b].categories;for(var k=0,p=c.length;p>k;k++)c[k].name===a&&"-"!=c[k].value&&h++}return h},setColor:function(a,c){this._colorMap[a]=c},getColor:function(a){return this._colorMap[a]||(this._colorMap[a]=this.zr.getColor(this._colorIndex++)),this._colorMap[a]},hasColor:function(a){return this._colorMap[a]?this._colorMap[a]:!1},add:function(a,c){for(var h=this.legendOption.data,e=0,b=h.length;b>e;e++)if(this._getName(h[e])===a)return;this.legendOption.data.push(a);this.setColor(a,c);this._selectedMap[a]=!0;this._hasDataMap[a]=!0},del:function(a){for(var c=this.legendOption.data,h=0,e=c.length;e>h;h++)if(this._getName(c[h])===a)return this.legendOption.data.splice(h,1)},getItemShape:function(a){if(null!=a)for(var c,h=0,e=this.shapeList.length;e>h;h++)if(c=this.shapeList[h],c._name===a&&"text"!=c.type)return c},setItemShape:function(a,c){for(var h,e=0,b=this.shapeList.length;b>e;e++)h=this.shapeList[e],h._name===a&&"text"!=h.type&&(this._selectedMap[a]||(c.style.color="#ccc",c.style.strokeColor="#ccc"),this.zr.modShape(h.id,c))},isSelected:function(a){return"undefined"!=typeof this._selectedMap[a]?this._selectedMap[a]:!0},getSelectedMap:function(){return this._selectedMap},setSelected:function(a,c){if("single"===this.legendOption.selectedMode)for(var h in this._selectedMap)this._selectedMap[h]=!1;this._selectedMap[a]=c;this.messageCenter.dispatch(m.EVENT.LEGEND_SELECTED,null,{selected:this._selectedMap,target:a},this.myChart)},onlegendSelected:function(a,c){var h=a.selected,e;for(e in h)this._selectedMap[e]!=h[e]&&(c.needRefresh=!0),this._selectedMap[e]=h[e]}};var p={line:function(a,c){var h=c.height/2;a.moveTo(c.x,c.y+h);a.lineTo(c.x+c.width,c.y+h)},pie:function(a,c){var h=c.height;b.prototype.buildPath(a,{x:c.x+c.width,y:c.y+h,r:h,r0:6,startAngle:90,endAngle:180})},eventRiver:function(a,c){var h=c.x,e=c.y,b=c.width,d=c.height;a.moveTo(h,e+d);a.bezierCurveTo(h+b,e+d,h,e+4,h+b,e+4);a.lineTo(h+b,e);a.bezierCurveTo(h,e,h+b,e+d-4,h,e+d-4);a.lineTo(h,e+d)},k:function(a,c){var h=c.y,b=c.width,d=c.height;e.prototype.buildPath(a,{x:c.x+b/2,y:[h+1,h+1,h+d-6,h+d],width:b-6})},bar:function(a,c){var h=c.x,e=c.y+1,b=c.width,d=c.height-2;a.moveTo(h+3,e);a.lineTo(h+b-3,e);a.quadraticCurveTo(h+b,e,h+b,e+3);a.lineTo(h+b,e+d-3);a.quadraticCurveTo(h+b,e+d,h+b-3,e+d);a.lineTo(h+3,e+d);a.quadraticCurveTo(h,e+d,h,e+d-3);a.lineTo(h,e+3);a.quadraticCurveTo(h,e,h+3,e)},force:function(c,e){a.prototype.iconLibrary.circle(c,e)},radar:function(a,c){var h=c.x+c.width/2,e=c.y+c.height/2,b=c.height/2,d=2*Math.PI/6,k=-Math.PI/2,p=h+b*Math.cos(k),m=e+b*Math.sin(k);a.moveTo(p,m);for(var k=k+d,r=0;5>r;r++)a.lineTo(h+b*Math.cos(k),e+b*Math.sin(k)),k+=d;a.lineTo(p,m)}};p.chord=p.pie;p.map=p.bar;for(var c in p)a.prototype.iconLibrary["legendicon"+c]=p[c];return r.inherits(f,q),g("../component").define("legend",f),f});define("echarts/util/ecData",[],function(){return{pack:function(g,f,q,l,d,b,a,e){var m;return"undefined"!=typeof l&&(m=null==l.value?l:l.value),g._echartsData={_series:f,_seriesIndex:q,_data:l,_dataIndex:d,_name:b,_value:m,_special:a,_special2:e},g._echartsData},set:function(g,f,q){switch(g._echartsData=g._echartsData||{},f){case "series":case "seriesIndex":case "data":case "dataIndex":case "name":case "value":case "special":case "special2":g._echartsData["_"+f]=q}},get:function(g,f){var q=g._echartsData;if(!f)return q;switch(f){case "series":case "seriesIndex":case "data":case "dataIndex":case "name":case "value":case "special":case "special2":return q&&q["_"+f]}return null},clone:function(g,f){f._echartsData={_series:g._echartsData._series,_seriesIndex:g._echartsData._seriesIndex,_data:g._echartsData._data,_dataIndex:g._echartsData._dataIndex,_name:g._echartsData._name,_value:g._echartsData._value,_special:g._echartsData._special,_special2:g._echartsData._special2}}}});define("echarts/chart",[],function(){var g={},f={};return g.define=function(q,l){return f[q]=l,g},g.get=function(g){return f[g]},g});define("zrender/tool/color",["require","../tool/util"],function(g){function f(a){if(a instanceof Array||-1!=a.indexOf("rgb")||-1!=a.indexOf("hs"))return a;if(!M[a]){var c=u.getPixelContext();c.fillStyle=a;c.rect(0,0,10,10);c.fill();c=c.getImageData(5,5,1,1).data;M[a]=l([c[0],c[1],c[2],c[3]],"rgba")}return M[a]}function q(a,h,e){a=b(a);h=b(h);a=k(a);h=k(h);var d=[],n=(h[0]-a[0])/e,p=(h[1]-a[1])/e,m=(h[2]-a[2])/e,r=(h[3]-a[3])/e,u=0,t=a[0],f=a[1],g=a[2];for(a=a[3];e>u;u++)d[u]=l([c(Math.floor(t),[0,255]),c(Math.floor(f),[0,255]),c(Math.floor(g),[0,255]),a.toFixed(4)-0],"rgba"),t+=n,f+=p,g+=m,a+=r;return t=h[0],f=h[1],g=h[2],a=h[3],d[u]=l([t,f,g,a],"rgba"),d}function l(a,h){if(h=h||"rgb",a&&(3===a.length||4===a.length)){if(a=p(a,function(a){return 1<a?Math.ceil(a):a}),-1<h.indexOf("hex"))return"#"+(16777216+(a[0]<<16)+(a[1]<<8)+ +a[2]).toString(16).slice(1);if(-1<h.indexOf("hs")){var e=p(a.slice(1,3),function(a){return a+"%"});a[1]=e[0];a[2]=e[1]}return-1<h.indexOf("a")?(3===a.length&&a.push(1),a[3]=c(a[3],[0,1]),h+"("+a.slice(0,4).join(",")+")"):h+"("+a.slice(0,3).join(",")+")"}}function d(a,c){if(!t(a))return a;var h=k(a),e=h[3];"undefined"==typeof e&&(e=1);if(-1<a.indexOf("hsb")){var b,d;b=h[0];var p=h[1],h=h[2];if(0===p)b=255*h,d=255*h,h*=255;else{var m=6*b;6===m&&(m=0);b=0|m;d=h*(1-p);var r=h*(1-p*(m-b)),u=h*(1-p*(1-(m-b))),f=0,p=m=0;0===b?(f=h,m=u,p=d):1===b?(f=r,m=h,p=d):2===b?(f=d,m=h,p=u):3===b?(f=d,m=r,p=h):4===b?(f=u,m=d,p=h):(f=h,m=d,p=r);b=255*f;d=255*m;h=255*p}h=[b,d,h]}else-1<a.indexOf("hsl")&&(b=h[0],d=h[1],r=h[2],0===d?(h=255*r,d=255*r,b=255*r):(p=.5>r?r*(1+d):r+d-d*r,r=2*r-p,h=255*n(r,p,b+1/3),d=255*n(r,p,b),b=255*n(r,p,b-1/3)),h=[h,d,b]);if(-1<c.indexOf("hsb")||-1<c.indexOf("hsv")){var g,q;b=h[0]/255;d=h[1]/255;h=h[2]/255;p=Math.max(b,d,h);f=p-Math.min(b,d,h);r=p;0===f?q=g=0:(q=f/p,m=((p-b)/6+f/2)/f,u=((p-d)/6+f/2)/f,f=((p-h)/6+f/2)/f,b===p?g=f-u:d===p?g=1/3+m-f:h===p&&(g=2/3+u-m),0>g&&(g+=1),1<g&&--g);h=(g*=360,q*=100,r*=100,[g,q,r])}else-1<c.indexOf("hsl")&&(g=h[0]/255,b=h[1]/255,h=h[2]/255,r=Math.min(g,b,h),p=Math.max(g,b,h),m=p-r,d=(p+r)/2,0===m?r=q=0:(r=.5>d?m/(p+r):m/(2-p-r),u=((p-g)/6+m/2)/m,f=((p-b)/6+m/2)/m,m=((p-h)/6+m/2)/m,g===p?q=m-f:b===p?q=1/3+u-m:h===p&&(q=2/3+f-u),0>q&&(q+=1),1<q&&--q),h=(q*=360,r*=100,d*=100,[q,r,d]));return h[3]=e,l(h,c)}function b(a){return d(a,"rgba")}function a(a){return d(a,"rgb")}function e(a){return d(a,"hex")}function m(a){return String(a).replace(/\s+/g,"")}function r(a){if(a=f(a),a=m(a),a=a.replace(/hsv/i,"hsb"),/^#[\da-f]{3}$/i.test(a)){a=parseInt(a.slice(1),16);var h=(3840&a)<<8,c=(240&a)<<4;a&=15;a="#"+(16777216+(h<<4)+h+(c<<4)+c+(a<<4)+a).toString(16).slice(1)}return a}function k(a){a=r(a);a=a.match(H);if(null===a)throw Error("The color format error");var h,e=[];if(a[2])a=a[2].replace("#","").split(""),h=[a[0]+a[1],a[2]+a[3],a[4]+a[5]],e=p(h,function(a){return c(parseInt(a,16),[0,255])});else if(a[4])h=a[4].split(","),a=h[3],h=h.slice(0,3),e=p(h,function(a){return a=Math.floor(0<a.indexOf("%")?2.55*parseInt(a,0):a),c(a,[0,255])}),"undefined"!=typeof a&&e.push(c(parseFloat(a),[0,1]));else if(a[5]||a[6]){a=(a[5]||a[6]).split(",");h=parseInt(a[0],0)/360;var e=a[1],b=a[2];a=a[3];e=p([e,b],function(a){return c(parseFloat(a)/100,[0,1])});e.unshift(h);"undefined"!=typeof a&&e.push(c(parseFloat(a),[0,1]))}return e}function p(a,h){if("function"!=typeof h)throw new TypeError;for(var c=a?a.length:0,e=0;c>e;e++)a[e]=h(a[e]);return a}function c(a,h){return a<=h[0]?a=h[0]:a>=h[1]&&(a=h[1]),a}function t(a){return a instanceof Array||"string"==typeof a}function n(a,h,c){return 0>c&&(c+=1),1<c&&--c,1>6*c?a+6*(h-a)*c:1>2*c?h:2>3*c?a+(h-a)*(2/3-c)*6:a}var h,u=g("../tool/util"),B=["#ff9277"," #dddd00"," #ffc877"," #bbe3ff"," #d5ffbb"],z=B,I="rgba(255,255,0,0.5)",H=/^\s*((#[a-f\d]{6})|(#[a-f\d]{3})|rgba?\(\s*([\d\.]+%?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+%?(?:\s*,\s*[\d\.]+%?)?)\s*\)|hsba?\(\s*([\d\.]+(?:deg|\xb0|%)?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+%?(?:\s*,\s*[\d\.]+)?)%?\s*\)|hsla?\(\s*([\d\.]+(?:deg|\xb0|%)?\s*,\s*[\d\.]+%?\s*,\s*[\d\.]+%?(?:\s*,\s*[\d\.]+)?)%?\s*\))\s*$/i,M={};return{customPalette:function(a){B=a},resetPalette:function(){B=z},getColor:function(a,h){return a|=0,h=h||B,h[a%h.length]},getNameColor:f,getHighlightColor:function(){return I},customHighlight:function(a){I=a},resetHighlight:function(){},getRadialGradient:function(a,c,e,b,d,k,n){h=h||u.getContext();a=h.createRadialGradient(a,c,e,b,d,k);c=0;for(e=n.length;e>c;c++)a.addColorStop(n[c][0],n[c][1]);return a.__nonRecursion=!0,a},getLinearGradient:function(a,c,e,b,d){h=h||u.getContext();a=h.createLinearGradient(a,c,e,b);c=0;for(e=d.length;e>c;c++)a.addColorStop(d[c][0],d[c][1]);return a.__nonRecursion=!0,a},getGradientColors:function(a,h){var c=[],e=a.length;if(void 0===h&&(h=20),1===e)c=q(a[0],a[0],h);else if(1<e)for(var b=0,e=e-1;e>b;b++){var d=q(a[b],a[b+1],h);e-1>b&&d.pop();c=c.concat(d)}return c},getStepColors:q,reverse:function(a){if(!t(a))return a;a=k(b(a));return a=p(a,function(a){return 255-a}),l(a,"rgb")},mix:function(a,h,e){if(!t(a)||!t(h))return a;"undefined"==typeof e&&(e=.5);e=1-c(e,[0,1]);var d=2*e-1;a=k(b(a));h=k(b(h));for(var n=a[3]-h[3],n=((-1===d*n?d:(d+n)/(1+d*n))+1)/2,p=1-n,d=[],m=0;3>m;m++)d[m]=a[m]*n+h[m]*p;e=a[3]*e+h[3]*(1-e);return e=Math.max(0,Math.min(1,e)),1===a[3]&&1===h[3]?l(d,"rgb"):(d[3]=e,l(d,"rgba"))},lift:function(h,c){if(!t(h))return h;var e=0<c?1:-1;"undefined"==typeof c&&(c=0);c=1<Math.abs(c)?1:Math.abs(c);h=a(h);for(var b=k(h),d=0;3>d;d++)b[d]=1===e?b[d]*(1-c)|0:(255-b[d])*c+b[d]|0;return"rgb("+b.join(",")+")"},trim:m,random:function(){return"#"+(Math.random().toString(16)+"0000").slice(2,8)},toRGB:a,toRGBA:b,toHex:e,toHSL:function(a){return d(a,"hsl")},toHSLA:function(a){return d(a,"hsla")},toHSB:function(a){return d(a,"hsb")},toHSBA:function(a){return d(a,"hsba")},toHSV:function(a){return d(a,"hsv")},toHSVA:function(a){return d(a,"hsva")},toName:function(a){for(var h in M)if(e(M[h])===e(a))return h;return null},toColor:l,toArray:function(a){a=m(a);0>a.indexOf("rgba")&&(a=b(a));var h=[],c=0;return a.replace(/[\d.]+/g,function(a){a=3>c?0|a:+a;h[c++]=a}),h},alpha:function(a,h){if(!t(a))return a;null===h&&(h=1);var e=k(b(a));return e[3]=c(Number(h).toFixed(4),[0,1]),l(e,"rgba")},getData:k}});define("echarts/component/timeline","require ./base zrender/shape/Rectangle ../util/shape/Icon ../util/shape/Chain ../config zrender/tool/util zrender/tool/area zrender/tool/event ../component".split(" "),function(g){function f(b,d,c,m,n){q.call(this,b,d,c,m,n);var h=this;if(h._onclick=function(a){return h.__onclick(a)},h._ondrift=function(a,c){return h.__ondrift(this,a,c)},h._ondragend=function(){return h.__ondragend()},h._setCurrentOption=function(){var c=h.timelineOption;h.currentIndex%=c.data.length;h.myChart.setOption(h.options[h.currentIndex]||{},c.notMerge);h.messageCenter.dispatch(a.EVENT.TIMELINE_CHANGED,null,{currentIndex:h.currentIndex,data:null!=c.data[h.currentIndex].name?c.data[h.currentIndex].name:c.data[h.currentIndex]},h.myChart)},h._onFrame=function(){h._setCurrentOption();h._syncHandleShape();h.timelineOption.autoPlay&&(h.playTicket=setTimeout(function(){return h.currentIndex+=1,!h.timelineOption.loop&&h.currentIndex>=h.timelineOption.data.length?(h.currentIndex=h.timelineOption.data.length-1,void h.stop()):void h._onFrame()},h.timelineOption.playInterval))},this.setTheme(!1),this.options=this.option.options,this.currentIndex=this.timelineOption.currentIndex%this.timelineOption.data.length,this.timelineOption.notMerge||0===this.currentIndex||(this.options[this.currentIndex]=e.merge(this.options[this.currentIndex],this.options[0])),this.timelineOption.show&&(this._buildShape(),this._syncHandleShape()),this._setCurrentOption(),this.timelineOption.autoPlay)h=this,this.playTicket=setTimeout(function(){h.play()},null!=this.ecTheme.animationDuration?this.ecTheme.animationDuration:a.animationDuration)}var q=g("./base"),l=g("zrender/shape/Rectangle"),d=g("../util/shape/Icon"),b=g("../util/shape/Chain"),a=g("../config");a.timeline={zlevel:0,z:4,show:!0,type:"time",notMerge:!1,realtime:!1,x:1,x2:2,y2:0,height:50,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:1,controlPosition:"left",autoPlay:!1,loop:!0,playInterval:2E3,lineStyle:{width:1,color:"#666",type:"dashed"},label:{show:!0,interval:"auto",rotate:0,textStyle:{color:"#333"}},checkpointStyle:{symbol:"auto",symbolSize:"auto",color:"auto",borderColor:"auto",borderWidth:"auto",label:{show:!0,textStyle:{color:"auto"}}},controlStyle:{itemSize:22,itemGap:8,normal:{color:"#333"},emphasis:{color:"#1e90ff"}},symbol:"emptyDiamond",symbolSize:4,currentIndex:0};var e=g("zrender/tool/util"),m=g("zrender/tool/area"),r=g("zrender/tool/event");return f.prototype={type:a.COMPONENT_TYPE_TIMELINE,_buildShape:function(){if(this._location=this._getLocation(),this._buildBackground(),this._buildControl(),this._chainPoint=this._getChainPoint(),this.timelineOption.label.show)for(var a=this._getInterval(),e=0,c=this._chainPoint.length;c>e;e+=a)this._chainPoint[e].showLabel=!0;this._buildChain();this._buildHandle();e=0;for(a=this.shapeList.length;a>e;e++)this.zr.addShape(this.shapeList[e])},_getLocation:function(){var a,e=this.timelineOption,c=this.reformCssArray(this.timelineOption.padding),b=this.zr.getWidth(),d=this.parsePercent(e.x,b),h=this.parsePercent(e.x2,b);null==e.width?(a=b-d-h,h=b-h):(a=this.parsePercent(e.width,b),h=d+a);var m,r,b=this.zr.getHeight(),l=this.parsePercent(e.height,b);return null!=e.y?(m=this.parsePercent(e.y,b),r=m+l):(r=b-this.parsePercent(e.y2,b),m=r-l),{x:d+c[3],y:m+c[0],x2:h-c[1],y2:r-c[2],width:a-c[1]-c[3],height:l-c[0]-c[2]}},_getReformedLabel:function(a){var e=this.timelineOption,c=null!=e.data[a].name?e.data[a].name:e.data[a];a=e.data[a].formatter||e.label.formatter;return a&&("function"==typeof a?c=a.call(this.myChart,c):"string"==typeof a&&(c=a.replace("{value}",c))),c},_getInterval:function(){var a=this._chainPoint,e=this.timelineOption,c=e.label.interval;if("auto"===c){var b=e.label.textStyle.fontSize,d=e.data,h=e.data.length;if(3<h)for(var r,l,f=!1,c=0;!f&&h>c;){c++;for(var f=!0,g=c;h>g;g+=c){if(r=a[g].x-a[g-c].x,0!==e.label.rotate)l=b;else if(d[g].textStyle)l=m.getTextWidth(a[g].name,a[g].textFont);else{l=a[g].name+"";var q=(l.match(/\w/g)||"").length;l=q*b*2/3+(l.length-q)*b}if(l>r){f=!1;break}}}else c=1}else c=c-0+1;return c},_getChainPoint:function(){function a(h){return null!=l[h].name?l[h].name:l[h]+""}var b,c=this.timelineOption,d=c.symbol.toLowerCase(),n=c.symbolSize,h=c.label.rotate,m=c.label.textStyle,r=this.getFont(m),l=c.data,f=this._location.x,g=this._location.y+this._location.height/4*3;b=this._location.x2-this._location.x;var q=l.length,D=[];if(1<q){var G=b/q;if(G=50<G?50:20>G?5:G,b-=2*G,"number"===c.type)for(c=0;q>c;c++)D.push(f+G+b/(q-1)*c);else{D[0]=new Date(a(0).replace(/-/g,"/"));D[q-1]=new Date(a(q-1).replace(/-/g,"/"))-D[0];for(c=1;q>c;c++)D[c]=f+G+b*(new Date(a(c).replace(/-/g,"/"))-D[0])/D[q-1];D[0]=f+G}}else D.push(f+b/2);for(var K,C,y,v,w=[],c=0;q>c;c++)f=D[c],G=l[c].symbol&&l[c].symbol.toLowerCase()||d,G.match("empty")?(G=G.replace("empty",""),C=!0):C=!1,G.match("star")&&(K=G.replace("star","")-0||5,G="star"),b=l[c].textStyle?e.merge(l[c].textStyle||{},m):m,y=b.align||"center",h?(y=0<h?"right":"left",v=[h*Math.PI/180,f,g-5]):v=!1,w.push({x:f,n:K,isEmpty:C,symbol:G,symbolSize:l[c].symbolSize||n,color:l[c].color,borderColor:l[c].borderColor,borderWidth:l[c].borderWidth,name:this._getReformedLabel(c),textColor:b.color,textAlign:y,textBaseline:b.baseline||"middle",textX:f,textY:g-(h?5:0),textFont:l[c].textStyle?this.getFont(b):r,rotation:v,showLabel:!1});return w},_buildBackground:function(){var a=this.timelineOption,e=this.reformCssArray(this.timelineOption.padding),c=this._location.width,b=this._location.height;0===a.borderWidth&&"rgba(0,0,0,0)"==a.backgroundColor.replace(/\s/g,"")||this.shapeList.push(new l({zlevel:this.getZlevelBase(),z:this.getZBase(),hoverable:!1,style:{x:this._location.x-e[3],y:this._location.y-e[0],width:c+e[1]+e[3],height:b+e[0]+e[2],brushType:0===a.borderWidth?"fill":"both",color:a.backgroundColor,strokeColor:a.borderColor,lineWidth:a.borderWidth}}))},_buildControl:function(){var a=this,b=this.timelineOption,c=b.lineStyle,m=b.controlStyle;if("none"!==b.controlPosition){var n,h=m.itemSize,r=m.itemGap;"left"===b.controlPosition?(n=this._location.x,this._location.x+=3*(h+r)):(n=this._location.x2-(3*(h+r)-r),this._location.x2-=3*(h+r));b=this._location.y;c={zlevel:this.getZlevelBase(),z:this.getZBase()+1,style:{iconType:"timelineControl",symbol:"last",x:n,y:b,width:h,height:h,brushType:"stroke",color:m.normal.color,strokeColor:m.normal.color,lineWidth:c.width},highlightStyle:{color:m.emphasis.color,strokeColor:m.emphasis.color,lineWidth:c.width+1},clickable:!0};this._ctrLastShape=new d(c);this._ctrLastShape.onclick=function(){a.last()};this.shapeList.push(this._ctrLastShape);n+=h+r;this._ctrPlayShape=new d(e.clone(c));this._ctrPlayShape.style.brushType="fill";this._ctrPlayShape.style.symbol="play";this._ctrPlayShape.style.status=this.timelineOption.autoPlay?"playing":"stop";this._ctrPlayShape.style.x=n;this._ctrPlayShape.onclick=function(){"stop"===a._ctrPlayShape.style.status?a.play():a.stop()};this.shapeList.push(this._ctrPlayShape);n+=h+r;this._ctrNextShape=new d(e.clone(c));this._ctrNextShape.style.symbol="next";this._ctrNextShape.style.x=n;this._ctrNextShape.onclick=function(){a.next()};this.shapeList.push(this._ctrNextShape)}},_buildChain:function(){var a=this.timelineOption.lineStyle;this._timelineShae={zlevel:this.getZlevelBase(),z:this.getZBase(),style:{x:this._location.x,y:this.subPixelOptimize(this._location.y,a.width),width:this._location.x2-this._location.x,height:this._location.height,chainPoint:this._chainPoint,brushType:"both",strokeColor:a.color,lineWidth:a.width,lineType:a.type},hoverable:!1,clickable:!0,onclick:this._onclick};this._timelineShae=new b(this._timelineShae);this.shapeList.push(this._timelineShae)},_buildHandle:function(){var a=this._chainPoint[this.currentIndex],e=a.symbolSize+1,e=5>e?5:e;this._handleShape={zlevel:this.getZlevelBase(),z:this.getZBase()+1,hoverable:!1,draggable:!0,style:{iconType:"diamond",n:a.n,x:a.x-e,y:this._location.y+this._location.height/4-e,width:2*e,height:2*e,brushType:"both",textPosition:"specific",textX:a.x,textY:this._location.y-this._location.height/4,textAlign:"center",textBaseline:"middle"},highlightStyle:{},ondrift:this._ondrift,ondragend:this._ondragend};this._handleShape=new d(this._handleShape);this.shapeList.push(this._handleShape)},_syncHandleShape:function(){if(this.timelineOption.show){var a=this.timelineOption,e=a.checkpointStyle,c=this._chainPoint[this.currentIndex];this._handleShape.style.text=e.label.show?c.name:"";this._handleShape.style.textFont=c.textFont;this._handleShape.style.n=c.n;"auto"===e.symbol?this._handleShape.style.iconType="none"!=c.symbol?c.symbol:"diamond":(this._handleShape.style.iconType=e.symbol,e.symbol.match("star")&&(this._handleShape.style.n=e.symbol.replace("star","")-0||5,this._handleShape.style.iconType="star"));var b;"auto"===e.symbolSize?(b=c.symbolSize+2,b=5>b?5:b):b=e.symbolSize-0;this._handleShape.style.color="auto"===e.color?c.color?c.color:a.controlStyle.emphasis.color:e.color;this._handleShape.style.textColor="auto"===e.label.textStyle.color?this._handleShape.style.color:e.label.textStyle.color;this._handleShape.highlightStyle.strokeColor=this._handleShape.style.strokeColor="auto"===e.borderColor?c.borderColor?c.borderColor:"#fff":e.borderColor;this._handleShape.style.lineWidth="auto"===e.borderWidth?c.borderWidth?c.borderWidth:0:e.borderWidth-0;this._handleShape.highlightStyle.lineWidth=this._handleShape.style.lineWidth+1;this.zr.animate(this._handleShape.id,"style").when(500,{x:c.x-b,textX:c.x,y:this._location.y+this._location.height/4-b,width:2*b,height:2*b}).start("ExponentialOut")}},_findChainIndex:function(a){var e=this._chainPoint,c=e.length;if(a<=e[0].x)return 0;if(a>=e[c-1].x)return c-1;for(var b=0;c-1>b;b++)if(a>=e[b].x&&a<=e[b+1].x)return Math.abs(a-e[b].x)<Math.abs(a-e[b+1].x)?b:b+1},__onclick:function(a){a=r.getX(a.event);a=this._findChainIndex(a);return a===this.currentIndex?!0:(this.currentIndex=a,this.timelineOption.autoPlay&&this.stop(),clearTimeout(this.playTicket),void this._onFrame())},__ondrift:function(a,e){this.timelineOption.autoPlay&&this.stop();var c,b=this._chainPoint,d=b.length;a.style.x+e<=b[0].x-b[0].symbolSize?(a.style.x=b[0].x-b[0].symbolSize,c=0):a.style.x+e>=b[d-1].x-b[d-1].symbolSize?(a.style.x=b[d-1].x-b[d-1].symbolSize,c=d-1):(a.style.x+=e,c=this._findChainIndex(a.style.x));b=b[c];d=b.symbolSize+2;if(a.style.iconType=b.symbol,a.style.n=b.n,a.style.textX=a.style.x+d/2,a.style.y=this._location.y+this._location.height/4-d,a.style.width=2*d,a.style.height=2*d,a.style.text=b.name,c===this.currentIndex)return!0;if(this.currentIndex=c,this.timelineOption.realtime){clearTimeout(this.playTicket);var h=this;this.playTicket=setTimeout(function(){h._setCurrentOption()},200)}return!0},__ondragend:function(){this.isDragend=!0},ondragend:function(a,e){this.isDragend&&a.target&&(!this.timelineOption.realtime&&this._setCurrentOption(),e.dragOut=!0,e.dragIn=!0,e.needRefresh=!1,this.isDragend=!1,this._syncHandleShape())},last:function(){return this.timelineOption.autoPlay&&this.stop(),--this.currentIndex,0>this.currentIndex&&(this.currentIndex=this.timelineOption.data.length-1),this._onFrame(),this.currentIndex},next:function(){return this.timelineOption.autoPlay&&this.stop(),this.currentIndex+=1,this.currentIndex>=this.timelineOption.data.length&&(this.currentIndex=0),this._onFrame(),this.currentIndex},play:function(a,e){return this._ctrPlayShape&&"playing"!=this._ctrPlayShape.style.status&&(this._ctrPlayShape.style.status="playing",this.zr.modShape(this._ctrPlayShape.id),this.zr.refreshNextFrame()),this.timelineOption.autoPlay=null!=e?e:!0,this.timelineOption.autoPlay||clearTimeout(this.playTicket),this.currentIndex=null!=a?a:this.currentIndex+1,this.currentIndex>=this.timelineOption.data.length&&(this.currentIndex=0),this._onFrame(),this.currentIndex},stop:function(){return this._ctrPlayShape&&"stop"!=this._ctrPlayShape.style.status&&(this._ctrPlayShape.style.status="stop",this.zr.modShape(this._ctrPlayShape.id),this.zr.refreshNextFrame()),this.timelineOption.autoPlay=!1,clearTimeout(this.playTicket),this.currentIndex},resize:function(){this.timelineOption.show&&(this.clear(),this._buildShape(),this._syncHandleShape())},setTheme:function(a){this.timelineOption=this.reformOption(e.clone(this.option.timeline));this.timelineOption.label.textStyle=this.getTextStyle(this.timelineOption.label.textStyle);this.timelineOption.checkpointStyle.label.textStyle=this.getTextStyle(this.timelineOption.checkpointStyle.label.textStyle);this.timelineOption.show&&a&&(this.clear(),this._buildShape(),this._syncHandleShape())},onbeforDispose:function(){clearTimeout(this.playTicket)}},d.prototype.iconLibrary.timelineControl=function(a,e){var c=e.x+2,b=e.y+2+2,n=e.width-2,h=e.height-2,m=e.symbol;if("last"===m)a.moveTo(c+n-2,b+h/3),a.lineTo(c+n-2,b),a.lineTo(c+2,b+h/2),a.lineTo(c+n-2,b+h),a.lineTo(c+n-2,b+h/3*2),a.moveTo(c,b),a.lineTo(c,b);else if("next"===m)a.moveTo(c+2,b+h/3),a.lineTo(c+2,b),a.lineTo(c+n-2,b+h/2),a.lineTo(c+2,b+h),a.lineTo(c+2,b+h/3*2),a.moveTo(c,b),a.lineTo(c,b);else if("play"===m)"stop"===e.status?(a.moveTo(c+2,b),a.lineTo(c+n-2,b+h/2),a.lineTo(c+2,b+h),a.lineTo(c+2,b)):(m="both"===e.brushType?2:3,a.rect(c+2,b,m,h),a.rect(c+n-m-2,b,m,h));else if(m.match("image")){var r;r=m.replace(/^image:\/\//,"");m=d.prototype.iconLibrary.image;m(a,{x:c,y:b,width:n,height:h,image:r})}},e.inherits(f,q),g("../component").define("timeline",f),f});define("zrender/shape/Image",["require","./Base","../tool/util"],function(g){var f=g("./Base"),q=function(l){f.call(this,l)};return q.prototype={type:"image",brush:function(l,d,b){var a=this.style||{};d&&(a=this.getHighlightStyle(a,this.highlightStyle||{}));var e=a.image,m=this;if(this._imageCache||(this._imageCache={}),"string"==typeof e)d=e,this._imageCache[d]?e=this._imageCache[d]:(e=new Image,e.onload=function(){e.onload=null;m.modSelf();b()},e.src=d,this._imageCache[d]=e);if(e){if("IMG"==e.nodeName.toUpperCase())if(window.ActiveXObject){if("complete"!=e.readyState)return}else if(!e.complete)return;d=a.width||e.width;var r=a.height||e.height,k=a.x,p=a.y;if(e.width&&e.height){if(l.save(),this.doClip(l),this.setContext(l,a),this.setTransform(l),a.sWidth&&a.sHeight){var c=a.sx||0,f=a.sy||0;l.drawImage(e,c,f,a.sWidth,a.sHeight,k,p,d,r)}else a.sx&&a.sy?(c=a.sx,f=a.sy,l.drawImage(e,c,f,d-c,r-f,k,p,d,r)):l.drawImage(e,k,p,d,r);a.width||(a.width=d);a.height||(a.height=r);this.style.width||(this.style.width=d);this.style.height||(this.style.height=r);this.drawText(l,a,this.style);l.restore()}}},getRect:function(l){return{x:l.x,y:l.y,width:l.width,height:l.height}},clearCache:function(){this._imageCache={}}},g("../tool/util").inherits(q,f),q});define("zrender/loadingEffect/Bubble",["require","./Base","../tool/util","../tool/color","../shape/Circle"],function(g){function f(a){q.call(this,a)}var q=g("./Base"),l=g("../tool/util"),d=g("../tool/color"),b=g("../shape/Circle");return l.inherits(f,q),f.prototype._start=function(a,e){for(var m=l.merge(this.options,{textStyle:{color:"#888"},backgroundColor:"rgba(250, 250, 250, 0.8)",effect:{n:50,lineWidth:2,brushType:"stroke",color:"random",timeInterval:100}}),r=this.createTextShape(m.textStyle),k=this.createBackgroundShape(m.backgroundColor),m=m.effect,p=m.n,c=m.brushType,f=m.lineWidth,n=[],h=this.canvasWidth,u=this.canvasHeight,g=0;p>g;g++){var q="random"==m.color?d.alpha(d.random(),.3):m.color;n[g]=new b({highlightStyle:{x:Math.ceil(Math.random()*h),y:Math.ceil(Math.random()*u),r:Math.ceil(40*Math.random()),brushType:c,color:q,strokeColor:q,lineWidth:f},animationY:Math.ceil(20*Math.random())})}return setInterval(function(){a(k);for(var c=0;p>c;c++){var b=n[c].highlightStyle;0>=b.y-n[c].animationY+b.r&&(n[c].highlightStyle.y=u+b.r,n[c].highlightStyle.x=Math.ceil(Math.random()*h));n[c].highlightStyle.y-=n[c].animationY;a(n[c])}a(r);e()},m.timeInterval)},f});define("zrender/loadingEffect/Spin","require ./Base ../tool/util ../tool/color ../tool/area ../shape/Sector".split(" "),function(g){function f(a){q.call(this,a)}var q=g("./Base"),l=g("../tool/util"),d=g("../tool/color"),b=g("../tool/area"),a=g("../shape/Sector");return l.inherits(f,q),f.prototype._start=function(e,m){var r=l.merge(this.options,{textStyle:{color:"#fff",textAlign:"start"},backgroundColor:"rgba(0, 0, 0, 0.8)"}),k=this.createTextShape(r.textStyle),p=b.getTextWidth(k.highlightStyle.text,k.highlightStyle.textFont),c=b.getTextHeight(k.highlightStyle.text,k.highlightStyle.textFont),f=l.merge(this.options.effect||{},{r0:9,r:15,n:18,color:"#fff",timeInterval:100}),p=this.getLocation(this.options.textStyle,p+10+2*f.r,Math.max(2*f.r,c));f.x=p.x+f.r;f.y=k.highlightStyle.y=p.y+p.height/2;k.highlightStyle.x=f.x+f.r+10;for(var n=this.createBackgroundShape(r.backgroundColor),h=f.n,r=f.x,p=f.y,c=f.r0,u=f.r,g=f.color,q=[],I=Math.round(180/h),H=0;h>H;H++)q[H]=new a({highlightStyle:{x:r,y:p,r0:c,r:u,startAngle:I*H*2,endAngle:I*H*2+I,color:d.alpha(g,(H+1)/h),brushType:"fill"}});var M=[0,r,p];return setInterval(function(){e(n);M[0]-=.3;for(var a=0;h>a;a++)q[a].rotation=M,e(q[a]);e(k);m()},f.timeInterval)},f});define("echarts/theme/macarons",[],function(){return{color:"#2ec7c9 #b6a2de #5ab1ef #ffb980 #d87a80 #8d98b3 #e5cf0d #97b552 #95706d #dc69aa #07a2a4 #9a7fd1 #588dd5 #f5994e #c05050 #59678c #c9ab00 #7eb00a #6f5553 #c14089".split(" "),title:{textStyle:{fontWeight:"normal",color:"#008acd"}},dataRange:{itemWidth:15,color:["#5ab1ef","#e0ffff"]},toolbox:{color:["#1e90ff","#1e90ff","#1e90ff","#1e90ff"],effectiveColor:"#ff4500"},tooltip:{backgroundColor:"rgba(50,50,50,0.5)",axisPointer:{type:"line",lineStyle:{color:"#008acd"},crossStyle:{color:"#008acd"},shadowStyle:{color:"rgba(200,200,200,0.2)"}}},dataZoom:{dataBackgroundColor:"#efefff",fillerColor:"rgba(182,162,222,0.2)",handleColor:"#008acd"},grid:{borderColor:"#eee"},categoryAxis:{axisLine:{lineStyle:{color:"#008acd"}},splitLine:{lineStyle:{color:["#eee"]}}},valueAxis:{axisLine:{lineStyle:{color:"#008acd"}},splitArea:{show:!0,areaStyle:{color:["rgba(250,250,250,0.1)","rgba(200,200,200,0.1)"]}},splitLine:{lineStyle:{color:["#eee"]}}},polar:{axisLine:{lineStyle:{color:"#ddd"}},splitArea:{show:!0,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(200,200,200,0.2)"]}},splitLine:{lineStyle:{color:"#ddd"}}},timeline:{lineStyle:{color:"#008acd"},controlStyle:{normal:{color:"#008acd"},emphasis:{color:"#008acd"}},symbol:"emptyCircle",symbolSize:3},bar:{itemStyle:{normal:{barBorderRadius:5},emphasis:{barBorderRadius:5}}},line:{smooth:!0,symbol:"emptyCircle",symbolSize:3},k:{itemStyle:{normal:{color:"#d87a80",color0:"#2ec7c9",lineStyle:{color:"#d87a80",color0:"#2ec7c9"}}}},scatter:{symbol:"circle",symbolSize:4},radar:{symbol:"emptyCircle",symbolSize:3},map:{itemStyle:{normal:{areaStyle:{color:"#ddd"},label:{textStyle:{color:"#d87a80"}}},emphasis:{areaStyle:{color:"#fe994e"}}}},force:{itemStyle:{normal:{linkStyle:{color:"#1e90ff"}}}},chord:{itemStyle:{normal:{borderWidth:1,borderColor:"rgba(128, 128, 128, 0.5)",chordStyle:{lineStyle:{color:"rgba(128, 128, 128, 0.5)"}}},emphasis:{borderWidth:1,borderColor:"rgba(128, 128, 128, 0.5)",chordStyle:{lineStyle:{color:"rgba(128, 128, 128, 0.5)"}}}}},gauge:{axisLine:{lineStyle:{color:[[.2,"#2ec7c9"],[.8,"#5ab1ef"],[1,"#d87a80"]],width:10}},axisTick:{splitNumber:10,length:15,lineStyle:{color:"auto"}},splitLine:{length:22,lineStyle:{color:"auto"}},pointer:{width:5}},textStyle:{fontFamily:"\u5fae\u8f6f\u96c5\u9ed1, Arial, Verdana, sans-serif"}}});define("echarts/theme/infographic",[],function(){return{color:"#C1232B #B5C334 #FCCE10 #E87C25 #27727B #FE8463 #9BCA63 #FAD860 #F3A43B #60C0DD #D7504B #C6E579 #F4E001 #F0805A #26C0C0".split(" "),title:{textStyle:{fontWeight:"normal",color:"#27727B"}},dataRange:{x:"right",y:"center",itemWidth:5,itemHeight:25,color:["#C1232B","#FCCE10"]},toolbox:{color:"#C1232B #B5C334 #FCCE10 #E87C25 #27727B #FE8463 #9BCA63 #FAD860 #F3A43B #60C0DD".split(" "),effectiveColor:"#ff4500"},tooltip:{backgroundColor:"rgba(50,50,50,0.5)",axisPointer:{type:"line",lineStyle:{color:"#27727B",type:"dashed"},crossStyle:{color:"#27727B"},shadowStyle:{color:"rgba(200,200,200,0.3)"}}},dataZoom:{dataBackgroundColor:"rgba(181,195,52,0.3)",fillerColor:"rgba(181,195,52,0.2)",handleColor:"#27727B"},grid:{borderWidth:0},categoryAxis:{axisLine:{lineStyle:{color:"#27727B"}},splitLine:{show:!1}},valueAxis:{axisLine:{show:!1},splitArea:{show:!1},splitLine:{lineStyle:{color:["#ccc"],type:"dashed"}}},polar:{axisLine:{lineStyle:{color:"#ddd"}},splitArea:{show:!0,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(200,200,200,0.2)"]}},splitLine:{lineStyle:{color:"#ddd"}}},timeline:{lineStyle:{color:"#27727B"},controlStyle:{normal:{color:"#27727B"},emphasis:{color:"#27727B"}},symbol:"emptyCircle",symbolSize:3},line:{itemStyle:{normal:{borderWidth:2,borderColor:"#fff",lineStyle:{width:3}},emphasis:{borderWidth:0}},symbol:"circle",symbolSize:3.5},k:{itemStyle:{normal:{color:"#C1232B",color0:"#B5C334",lineStyle:{width:1,color:"#C1232B",color0:"#B5C334"}}}},scatter:{itemdStyle:{normal:{borderWidth:1,borderColor:"rgba(200,200,200,0.5)"},emphasis:{borderWidth:0}},symbol:"star4",symbolSize:4},radar:{symbol:"emptyCircle",symbolSize:3},map:{itemStyle:{normal:{areaStyle:{color:"#ddd"},label:{textStyle:{color:"#C1232B"}}},emphasis:{areaStyle:{color:"#fe994e"},label:{textStyle:{color:"rgb(100,0,0)"}}}}},force:{itemStyle:{normal:{linkStyle:{color:"#27727B"}}}},chord:{itemStyle:{normal:{borderWidth:1,borderColor:"rgba(128, 128, 128, 0.5)",chordStyle:{lineStyle:{color:"rgba(128, 128, 128, 0.5)"}}},emphasis:{borderWidth:1,borderColor:"rgba(128, 128, 128, 0.5)",chordStyle:{lineStyle:{color:"rgba(128, 128, 128, 0.5)"}}}}},gauge:{center:["50%","80%"],radius:"100%",startAngle:180,endAngle:0,axisLine:{show:!0,lineStyle:{color:[[.2,"#B5C334"],[.8,"#27727B"],[1,"#C1232B"]],width:"40%"}},axisTick:{splitNumber:2,length:5,lineStyle:{color:"#fff"}},axisLabel:{textStyle:{color:"#fff",fontWeight:"bolder"}},splitLine:{length:"5%",lineStyle:{color:"#fff"}},pointer:{width:"40%",length:"80%",color:"#fff"},title:{offsetCenter:[0,-20],textStyle:{color:"auto",fontSize:20}},detail:{offsetCenter:[0,0],textStyle:{color:"auto",fontSize:40}}},textStyle:{fontFamily:"\u5fae\u8f6f\u96c5\u9ed1, Arial, Verdana, sans-serif"}}});define("zrender/mixin/Eventful",["require"],function(){var g=function(){this._handlers={}};return g.prototype.one=function(f,g,l){var d=this._handlers;return g&&f?(d[f]||(d[f]=[]),d[f].push({h:g,one:!0,ctx:l||this}),this):this},g.prototype.bind=function(f,g,l){var d=this._handlers;return g&&f?(d[f]||(d[f]=[]),d[f].push({h:g,one:!1,ctx:l||this}),this):this},g.prototype.unbind=function(f,g){var l=this._handlers;if(!f)return this._handlers={},this;if(g){if(l[f]){for(var d=[],b=0,a=l[f].length;a>b;b++)l[f][b].h!=g&&d.push(l[f][b]);l[f]=d}l[f]&&0===l[f].length&&delete l[f]}else delete l[f];return this},g.prototype.dispatch=function(f){if(this._handlers[f]){var g=arguments,l=g.length;3<l&&(g=Array.prototype.slice.call(g,1));for(var d=this._handlers[f],b=d.length,a=0;b>a;){switch(l){case 1:d[a].h.call(d[a].ctx);break;case 2:d[a].h.call(d[a].ctx,g[1]);break;case 3:d[a].h.call(d[a].ctx,g[1],g[2]);break;default:d[a].h.apply(d[a].ctx,g)}d[a].one?(d.splice(a,1),b--):a++}}return this},g.prototype.dispatchWithContext=function(f){if(this._handlers[f]){var g=arguments,l=g.length;4<l&&(g=Array.prototype.slice.call(g,1,g.length-1));for(var d=g[g.length-1],b=this._handlers[f],a=b.length,e=0;a>e;){switch(l){case 1:b[e].h.call(d);break;case 2:b[e].h.call(d,g[1]);break;case 3:b[e].h.call(d,g[1],g[2]);break;default:b[e].h.apply(d,g)}b[e].one?(b.splice(e,1),a--):e++}}return this},g});define("zrender/tool/log",["require","../config"],function(g){var f=g("../config");return function(){if(0!==f.debugMode)if(1==f.debugMode)for(var g in arguments)throw Error(arguments[g]);else if(1<f.debugMode)for(g in arguments)console.log(arguments[g])}});define("zrender/tool/guid",[],function(){var g=2311;return function(){return"zrender__"+g++}});define("zrender/Handler","require ./config ./tool/env ./tool/event ./tool/util ./tool/vector ./tool/matrix ./mixin/Eventful".split(" "),function(g){function f(a,c){return function(e){return a.call(c,e)}}function q(a,c){return function(e,b,d){return a.call(c,e,b,d)}}function l(a,c,e){if(this._draggingTarget&&this._draggingTarget.id==a.id||a.isSilent())return!1;var b=this._event;if(a.isCover(c,e)){a.hoverable&&this.storage.addHover(a);for(c=a.parent;c;){if(c.clipShape&&!c.clipShape.isCover(this._mouseX,this._mouseY))return!1;c=c.parent}return this._lastHover!=a&&(this._processOutShape(b),this._processDragLeave(b),this._lastHover=a,this._processDragEnter(b)),this._processOverShape(b),this._processDragOver(b),this._hasfound=1,!0}return!1}var d=g("./config"),b=g("./tool/env"),a=g("./tool/event"),e=g("./tool/util"),m=g("./tool/vector"),r=g("./tool/matrix"),k=d.EVENT,p=g("./mixin/Eventful"),c="resize click dblclick mousewheel mousemove mouseout mouseup mousedown touchstart touchend touchmove".split(" "),t={resize:function(a){a=a||window.event;this._lastHover=null;this._isMouseDown=0;this.dispatch(k.RESIZE,a)},click:function(a){a=this._zrenderEventFixed(a);var c=this._lastHover;(c&&c.clickable||!c)&&5>this._clickThreshold&&this._dispatchAgency(c,k.CLICK,a);this._mousemoveHandler(a)},dblclick:function(a){a=a||window.event;a=this._zrenderEventFixed(a);var c=this._lastHover;(c&&c.clickable||!c)&&5>this._clickThreshold&&this._dispatchAgency(c,k.DBLCLICK,a);this._mousemoveHandler(a)},mousewheel:function(c){c=this._zrenderEventFixed(c);var e=0<(c.wheelDelta||-c.detail)?1.1:1/1.1,b=!1,d=this._mouseX,m=this._mouseY;this.painter.eachBuildinLayer(function(k){var n=k.position;if(k.zoomable){k.__zoom=k.__zoom||1;var p=k.__zoom,p=p*e,p=Math.max(Math.min(k.maxZoom,p),k.minZoom);e=p/k.__zoom;k.__zoom=p;n[0]-=(d-n[0])*(e-1);n[1]-=(m-n[1])*(e-1);k.scale[0]*=e;k.scale[1]*=e;b=k.dirty=!0;a.stop(c)}});b&&this.painter.refresh();this._dispatchAgency(this._lastHover,k.MOUSEWHEEL,c);this._mousemoveHandler(c)},mousemove:function(c){if(!this.painter.isLoading()){c=this._zrenderEventFixed(c);this._lastX=this._mouseX;this._lastY=this._mouseY;this._mouseX=a.getX(c);this._mouseY=a.getY(c);var e=this._mouseX-this._lastX,b=this._mouseY-this._lastY;this._processDragStart(c);this._hasfound=0;this._event=c;this._iterateAndFindHover();this._hasfound||((!this._draggingTarget||this._lastHover&&this._lastHover!=this._draggingTarget)&&(this._processOutShape(c),this._processDragLeave(c)),this._lastHover=null,this.storage.delHover(),this.painter.clearHover());var d="default";if(this._draggingTarget)this.storage.drift(this._draggingTarget.id,e,b),this._draggingTarget.modSelf(),this.storage.addHover(this._draggingTarget),this._clickThreshold++;else if(this._isMouseDown){var n=!1;this.painter.eachBuildinLayer(function(a){a.panable&&(d="move",a.position[0]+=e,a.position[1]+=b,n=!0,a.dirty=!0)});n&&this.painter.refresh()}this._draggingTarget||this._hasfound&&this._lastHover.draggable?d="move":this._hasfound&&this._lastHover.clickable&&(d="pointer");this.root.style.cursor=d;this._dispatchAgency(this._lastHover,k.MOUSEMOVE,c);(this._draggingTarget||this._hasfound||this.storage.hasHoverShape())&&this.painter.refreshHover()}},mouseout:function(a){a=this._zrenderEventFixed(a);var c=a.toElement||a.relatedTarget;if(c!=this.root)for(;c&&9!=c.nodeType;){if(c==this.root)return void this._mousemoveHandler(a);c=c.parentNode}a.zrenderX=this._lastX;a.zrenderY=this._lastY;this.root.style.cursor="default";this._isMouseDown=0;this._processOutShape(a);this._processDrop(a);this._processDragEnd(a);this.painter.isLoading()||this.painter.refreshHover();this.dispatch(k.GLOBALOUT,a)},mousedown:function(a){return this._clickThreshold=0,2==this._lastDownButton?(this._lastDownButton=a.button,void(this._mouseDownTarget=null)):(this._lastMouseDownMoment=new Date,a=this._zrenderEventFixed(a),this._isMouseDown=1,this._mouseDownTarget=this._lastHover,this._dispatchAgency(this._lastHover,k.MOUSEDOWN,a),void(this._lastDownButton=a.button))},mouseup:function(a){a=this._zrenderEventFixed(a);this.root.style.cursor="default";this._isMouseDown=0;this._mouseDownTarget=null;this._dispatchAgency(this._lastHover,k.MOUSEUP,a);this._processDrop(a);this._processDragEnd(a)},touchstart:function(a){a=this._zrenderEventFixed(a,!0);this._lastTouchMoment=new Date;this._mobileFindFixed(a);this._mousedownHandler(a)},touchmove:function(c){c=this._zrenderEventFixed(c,!0);this._mousemoveHandler(c);this._isDragging&&a.stop(c)},touchend:function(c){c=this._zrenderEventFixed(c,!0);this._mouseupHandler(c);var e=new Date;e-this._lastTouchMoment<k.touchClickDelay&&(this._mobileFindFixed(c),this._clickHandler(c),e-this._lastClickMoment<k.touchClickDelay/2&&(this._dblclickHandler(c),this._lastHover&&this._lastHover.clickable&&a.stop(c)),this._lastClickMoment=e);this.painter.clearHover()}};g=function(a,e,d){p.call(this);this.root=a;this.storage=e;this.painter=d;this._lastX=this._lastY=this._mouseX=this._mouseY=0;this._findHover=q(l,this);this._domHover=d.getDomHover();for(e=c.length;e--;)d=c[e],this["_"+d+"Handler"]=f(t[d],this);window.addEventListener?(window.addEventListener("resize",this._resizeHandler),b.os.tablet||b.os.phone?(a.addEventListener("touchstart",this._touchstartHandler),a.addEventListener("touchmove",this._touchmoveHandler),a.addEventListener("touchend",this._touchendHandler)):(a.addEventListener("click",this._clickHandler),a.addEventListener("dblclick",this._dblclickHandler),a.addEventListener("mousewheel",this._mousewheelHandler),a.addEventListener("mousemove",this._mousemoveHandler),a.addEventListener("mousedown",this._mousedownHandler),a.addEventListener("mouseup",this._mouseupHandler)),a.addEventListener("DOMMouseScroll",this._mousewheelHandler),a.addEventListener("mouseout",this._mouseoutHandler)):(window.attachEvent("onresize",this._resizeHandler),a.attachEvent("onclick",this._clickHandler),a.ondblclick=this._dblclickHandler,a.attachEvent("onmousewheel",this._mousewheelHandler),a.attachEvent("onmousemove",this._mousemoveHandler),a.attachEvent("onmouseout",this._mouseoutHandler),a.attachEvent("onmousedown",this._mousedownHandler),a.attachEvent("onmouseup",this._mouseupHandler))};g.prototype.on=function(a,c,e){return this.bind(a,c,e),this};g.prototype.un=function(a,c){return this.unbind(a,c),this};g.prototype.trigger=function(a,c){switch(a){case k.RESIZE:case k.CLICK:case k.DBLCLICK:case k.MOUSEWHEEL:case k.MOUSEMOVE:case k.MOUSEDOWN:case k.MOUSEUP:case k.MOUSEOUT:this["_"+a+"Handler"](c)}};g.prototype.dispose=function(){var a=this.root;window.removeEventListener?(window.removeEventListener("resize",this._resizeHandler),b.os.tablet||b.os.phone?(a.removeEventListener("touchstart",this._touchstartHandler),a.removeEventListener("touchmove",this._touchmoveHandler),a.removeEventListener("touchend",this._touchendHandler)):(a.removeEventListener("click",this._clickHandler),a.removeEventListener("dblclick",this._dblclickHandler),a.removeEventListener("mousewheel",this._mousewheelHandler),a.removeEventListener("mousemove",this._mousemoveHandler),a.removeEventListener("mousedown",this._mousedownHandler),a.removeEventListener("mouseup",this._mouseupHandler)),a.removeEventListener("DOMMouseScroll",this._mousewheelHandler),a.removeEventListener("mouseout",this._mouseoutHandler)):(window.detachEvent("onresize",this._resizeHandler),a.detachEvent("onclick",this._clickHandler),a.detachEvent("dblclick",this._dblclickHandler),a.detachEvent("onmousewheel",this._mousewheelHandler),a.detachEvent("onmousemove",this._mousemoveHandler),a.detachEvent("onmouseout",this._mouseoutHandler),a.detachEvent("onmousedown",this._mousedownHandler),a.detachEvent("onmouseup",this._mouseupHandler));this.root=this._domHover=this.storage=this.painter=null;this.un()};g.prototype._processDragStart=function(a){var c=this._lastHover;!(this._isMouseDown&&c&&c.draggable)||this._draggingTarget||this._mouseDownTarget!=c||c.dragEnableTime&&new Date-this._lastMouseDownMoment<c.dragEnableTime||(this._draggingTarget=c,this._isDragging=1,c.invisible=!0,this.storage.mod(c.id),this._dispatchAgency(c,k.DRAGSTART,a),this.painter.refresh())};g.prototype._processDragEnter=function(a){this._draggingTarget&&this._dispatchAgency(this._lastHover,k.DRAGENTER,a,this._draggingTarget)};g.prototype._processDragOver=function(a){this._draggingTarget&&this._dispatchAgency(this._lastHover,k.DRAGOVER,a,this._draggingTarget)};g.prototype._processDragLeave=function(a){this._draggingTarget&&this._dispatchAgency(this._lastHover,k.DRAGLEAVE,a,this._draggingTarget)};g.prototype._processDrop=function(a){this._draggingTarget&&(this._draggingTarget.invisible=!1,this.storage.mod(this._draggingTarget.id),this.painter.refresh(),this._dispatchAgency(this._lastHover,k.DROP,a,this._draggingTarget))};g.prototype._processDragEnd=function(a){this._draggingTarget&&(this._dispatchAgency(this._draggingTarget,k.DRAGEND,a),this._lastHover=null);this._isDragging=0;this._draggingTarget=null};g.prototype._processOverShape=function(a){this._dispatchAgency(this._lastHover,k.MOUSEOVER,a)};g.prototype._processOutShape=function(a){this._dispatchAgency(this._lastHover,k.MOUSEOUT,a)};g.prototype._dispatchAgency=function(a,c,e,b){var d="on"+c,k={type:c,event:e,target:a,cancelBubble:!1},n=a;for(b&&(k.dragged=b);n&&(n[d]&&(k.cancelBubble=n[d](k)),n.dispatch(c,k),n=n.parent,!k.cancelBubble););if(a)k.cancelBubble||this.dispatch(c,k);else if(!b){var m={type:c,event:e};this.dispatch(c,m);this.painter.eachOtherLayer(function(a){"function"==typeof a[d]&&a[d](m);a.dispatch&&a.dispatch(c,m)})}};g.prototype._iterateAndFindHover=function(){var a=r.create();return function(){for(var c,e=this.storage.getShapeList(),b=[0,0],d=e.length-1;0<=d;d--){var k=e[d];if(void 0!==k.zlevel&&(c=this.painter.getLayer(k.zlevel,c),b[0]=this._mouseX,b[1]=this._mouseY,c.needTransform&&(r.invert(a,c.transform),m.applyTransform(b,b,a))),this._findHover(k,b[0],b[1]))break}}}();var n=[{x:10},{x:-20},{x:10,y:10},{y:-20}];return g.prototype._mobileFindFixed=function(a){this._lastHover=null;this._mouseX=a.zrenderX;this._mouseY=a.zrenderY;this._event=a;this._iterateAndFindHover();for(var c=0;!this._lastHover&&c<n.length;c++){var e=n[c];e.x&&(this._mouseX+=e.x);e.y&&(this._mouseY+=e.y);this._iterateAndFindHover()}this._lastHover&&(a.zrenderX=this._mouseX,a.zrenderY=this._mouseY)},g.prototype._zrenderEventFixed=function(a,c){if(a.zrenderFixed)return a;if(c){var e="touchend"!=a.type?a.targetTouches[0]:a.changedTouches[0];if(e){var b=this.painter._domRoot.getBoundingClientRect();a.zrenderX=e.clientX-b.left;a.zrenderY=e.clientY-b.top}}else a=a||window.event,(e=a.toElement||a.relatedTarget||a.srcElement||a.target)&&e!=this._domHover&&(a.zrenderX=("undefined"!=typeof a.offsetX?a.offsetX:a.layerX)+e.offsetLeft,a.zrenderY=("undefined"!=typeof a.offsetY?a.offsetY:a.layerY)+e.offsetTop);return a.zrenderFixed=1,a},e.merge(g.prototype,p.prototype,!0),g});define("zrender/Painter","require ./config ./tool/util ./tool/log ./loadingEffect/Base ./Layer ./shape/Image".split(" "),function(g){function f(){return!1}function q(){}var l=g("./config"),d=g("./tool/util"),b=g("./tool/log"),a=g("./loadingEffect/Base"),e=g("./Layer"),m=function(b,d){this.root=b;b.style["-webkit-tap-highlight-color"]="transparent";b.style["-webkit-user-select"]="none";b.style["user-select"]="none";b.style["-webkit-touch-callout"]="none";this.storage=d;b.innerHTML="";this._width=this._getWidth();this._height=this._getHeight();var m=document.createElement("div");this._domRoot=m;m.style.position="relative";m.style.overflow="hidden";m.style.width=this._width+"px";m.style.height=this._height+"px";b.appendChild(m);this._layers={};this._zlevelList=[];this._layerConfig={};this._loadingEffect=new a({});this.shapeToImage=this._createShapeToImageProcessor();this._bgDom=document.createElement("div");this._bgDom.style.cssText=["position:absolute;left:0px;top:0px;width:",this._width,"px;height:",this._height+"px;","-webkit-user-select:none;user-select;none;-webkit-touch-callout:none;"].join("");this._bgDom.setAttribute("data-zr-dom-id","bg");m.appendChild(this._bgDom);this._bgDom.onselectstart=f;var c=new e("_zrender_hover_",this);this._layers.hover=c;m.appendChild(c.dom);c.initContext();c.dom.onselectstart=f;c.dom.style["-webkit-user-select"]="none";c.dom.style["user-select"]="none";c.dom.style["-webkit-touch-callout"]="none";this.refreshNextFrame=null};return m.prototype.render=function(a){return this.isLoading()&&this.hideLoading(),this.refresh(a,!0),this},m.prototype.refresh=function(a,e){var b=this.storage.getShapeList(!0);this._paintList(b,e);for(b=0;b<this._zlevelList.length;b++){var c=this._layers[this._zlevelList[b]];!c.isBuildin&&c.refresh&&c.refresh()}return"function"==typeof a&&a(),this},m.prototype._preProcessLayer=function(a){a.unusedCount++;a.updateTransform()},m.prototype._postProcessLayer=function(a){a.dirty=!1;1==a.unusedCount&&a.clear()},m.prototype._paintList=function(a,e){"undefined"==typeof e&&(e=!1);this._updateLayerStatus(a);var d,c,m;this.eachBuildinLayer(this._preProcessLayer);for(var n=0,h=a.length;h>n;n++){var f=a[n];if(c!==f.zlevel&&(d&&(d.needTransform&&m.restore(),m.flush&&m.flush()),c=f.zlevel,d=this.getLayer(c),d.isBuildin||b("ZLevel "+c+" has been used by unkown layer "+d.id),m=d.ctx,d.unusedCount=0,(d.dirty||e)&&d.clear(),d.needTransform&&(m.save(),d.setTransform(m))),(d.dirty||e)&&!f.invisible&&(!f.onbrush||f.onbrush&&!f.onbrush(m,!1)))if(l.catchBrushException)try{f.brush(m,!1,this.refreshNextFrame)}catch(g){b(g,"brush error of "+f.type,f)}else f.brush(m,!1,this.refreshNextFrame);f.__dirty=!1}d&&(d.needTransform&&m.restore(),m.flush&&m.flush());this.eachBuildinLayer(this._postProcessLayer)},m.prototype.getLayer=function(a){var b=this._layers[a];return b||(b=new e(a,this),b.isBuildin=!0,this._layerConfig[a]&&d.merge(b,this._layerConfig[a],!0),b.updateTransform(),this.insertLayer(a,b),b.initContext()),b},m.prototype.insertLayer=function(a,e){if(this._layers[a])return void b("ZLevel "+a+" has been used already");if(!e||!(e.isBuildin||"function"==typeof e.resize&&"function"==typeof e.refresh))return void b("Layer of zlevel "+a+" is not valid");var d=this._zlevelList.length,c=null,m=-1;if(0<d&&a>this._zlevelList[0]){for(m=0;d-1>m&&!(this._zlevelList[m]<a&&this._zlevelList[m+1]>a);m++);c=this._layers[this._zlevelList[m]]}this._zlevelList.splice(m+1,0,a);d=c?c.dom:this._bgDom;d.nextSibling?d.parentNode.insertBefore(e.dom,d.nextSibling):d.parentNode.appendChild(e.dom);this._layers[a]=e},m.prototype.eachLayer=function(a,e){for(var b=0;b<this._zlevelList.length;b++){var c=this._zlevelList[b];a.call(e,this._layers[c],c)}},m.prototype.eachBuildinLayer=function(a,e){for(var b=0;b<this._zlevelList.length;b++){var c=this._zlevelList[b],d=this._layers[c];d.isBuildin&&a.call(e,d,c)}},m.prototype.eachOtherLayer=function(a,e){for(var b=0;b<this._zlevelList.length;b++){var c=this._zlevelList[b],d=this._layers[c];d.isBuildin||a.call(e,d,c)}},m.prototype.getLayers=function(){return this._layers},m.prototype._updateLayerStatus=function(a){var e=this._layers,b={};this.eachBuildinLayer(function(a,c){b[c]=a.elCount;a.elCount=0});for(var c=0,d=a.length;d>c;c++){var m=a[c],h=e[m.zlevel];h&&(h.elCount++,!h.dirty)&&(h.dirty=m.__dirty)}this.eachBuildinLayer(function(a,c){b[c]!==a.elCount&&(a.dirty=!0)})},m.prototype.refreshShapes=function(a,e){for(var b=0,c=a.length;c>b;b++)a[b].modSelf();return this.refresh(e),this},m.prototype.setLoadingEffect=function(a){return this._loadingEffect=a,this},m.prototype.clear=function(){return this.eachBuildinLayer(this._clearLayer),this},m.prototype._clearLayer=function(a){a.clear()},m.prototype.modLayer=function(a,e){if(e){this._layerConfig[a]?d.merge(this._layerConfig[a],e,!0):this._layerConfig[a]=e;var b=this._layers[a];b&&d.merge(b,this._layerConfig[a],!0)}},m.prototype.delLayer=function(a){var e=this._layers[a];e&&(this.modLayer(a,{position:e.position,rotation:e.rotation,scale:e.scale}),e.dom.parentNode.removeChild(e.dom),delete this._layers[a],this._zlevelList.splice(d.indexOf(this._zlevelList,a),1))},m.prototype.refreshHover=function(){this.clearHover();for(var a=this.storage.getHoverShapes(!0),e=0,b=a.length;b>e;e++)this._brushHover(a[e]);a=this._layers.hover.ctx;return a.flush&&a.flush(),this.storage.delHover(),this},m.prototype.clearHover=function(){var a=this._layers.hover;return a&&a.clear(),this},m.prototype.showLoading=function(a){return this._loadingEffect&&this._loadingEffect.stop(),a&&this.setLoadingEffect(a),this._loadingEffect.start(this),this.loading=!0,this},m.prototype.hideLoading=function(){return this._loadingEffect.stop(),this.clearHover(),this.loading=!1,this},m.prototype.isLoading=function(){return this.loading},m.prototype.resize=function(){var a=this._domRoot;a.style.display="none";var e=this._getWidth(),b=this._getHeight();if(a.style.display="",this._width!=e||b!=this._height){this._width=e;this._height=b;a.style.width=e+"px";a.style.height=b+"px";for(var c in this._layers)this._layers[c].resize(e,b);this.refresh(null,!0)}return this},m.prototype.clearLayer=function(a){(a=this._layers[a])&&a.clear()},m.prototype.dispose=function(){this.isLoading()&&this.hideLoading();this.root.innerHTML="";this.root=this.storage=this._domRoot=this._layers=null},m.prototype.getDomHover=function(){return this._layers.hover.dom},m.prototype.toDataURL=function(a,d,m){if(window.G_vmlCanvasManager)return null;var c=new e("image",this);this._bgDom.appendChild(c.dom);c.initContext();var f=c.ctx;c.clearColor=d||"#fff";c.clear();var n=this;this.storage.iterShape(function(a){if(!a.invisible&&(!a.onbrush||a.onbrush&&!a.onbrush(f,!1)))if(l.catchBrushException)try{a.brush(f,!1,n.refreshNextFrame)}catch(c){b(c,"brush error of "+a.type,a)}else a.brush(f,!1,n.refreshNextFrame)},{normal:"up",update:!0});a=c.dom.toDataURL(a,m);return f=null,this._bgDom.removeChild(c.dom),a},m.prototype.getWidth=function(){return this._width},m.prototype.getHeight=function(){return this._height},m.prototype._getWidth=function(){var a=this.root,e=a.currentStyle||document.defaultView.getComputedStyle(a);return((a.clientWidth||parseInt(e.width,10))-parseInt(e.paddingLeft,10)-parseInt(e.paddingRight,10)).toFixed(0)-0},m.prototype._getHeight=function(){var a=this.root,e=a.currentStyle||document.defaultView.getComputedStyle(a);return((a.clientHeight||parseInt(e.height,10))-parseInt(e.paddingTop,10)-parseInt(e.paddingBottom,10)).toFixed(0)-0},m.prototype._brushHover=function(a){var e=this._layers.hover.ctx;if(!a.onbrush||a.onbrush&&!a.onbrush(e,!0)){var d=this.getLayer(a.zlevel);if(d.needTransform&&(e.save(),d.setTransform(e)),l.catchBrushException)try{a.brush(e,!0,this.refreshNextFrame)}catch(c){b(c,"hoverBrush error of "+a.type,a)}else a.brush(e,!0,this.refreshNextFrame);d.needTransform&&e.restore()}},m.prototype._shapeToImage=function(a,e,b,c,d){var m=document.createElement("canvas"),h=m.getContext("2d");m.style.width=b+"px";m.style.height=c+"px";m.setAttribute("width",b*d);m.setAttribute("height",c*d);h.clearRect(0,0,b*d,c*d);b=e.position;c=e.rotation;d=e.scale;e.position=[0,0,0];e.rotation=0;e.scale=[1,1];e&&e.brush(h,!1);a=new (g("./shape/Image"))({id:a,style:{x:0,y:0,image:m}});return null!=b&&(a.position=e.position=b),null!=c&&(a.rotation=e.rotation=c),null!=d&&(a.scale=e.scale=d),a},m.prototype._createShapeToImageProcessor=function(){if(window.G_vmlCanvasManager)return q;var a=this;return function(e,b,c,d){return a._shapeToImage(e,b,c,d,l.devicePixelRatio)}},m});define("zrender/Storage",["require","./tool/util","./Group"],function(g){function f(b,a){return b.zlevel==a.zlevel?b.z==a.z?b.__renderidx-a.__renderidx:b.z-a.z:b.zlevel-a.zlevel}var q=g("./tool/util"),l=g("./Group"),d={hover:!1,normal:"down",update:!1};g=function(){this._elements={};this._hoverElements=[];this._roots=[];this._shapeList=[];this._shapeListOffset=0};return g.prototype.iterShape=function(b,a){if(a||(a=d),a.hover)for(var e=0,m=this._hoverElements.length;m>e;e++){var l=this._hoverElements[e];if(l.updateTransform(),b(l))return this}switch(a.update&&this.updateShapeList(),a.normal){case "down":for(m=this._shapeList.length;m--;)if(b(this._shapeList[m]))return this;break;default:for(e=0,m=this._shapeList.length;m>e&&!b(this._shapeList[e]);e++);}return this},g.prototype.getHoverShapes=function(b){for(var a=[],e=0,d=this._hoverElements.length;d>e;e++){a.push(this._hoverElements[e]);var l=this._hoverElements[e].hoverConnect;if(l)for(var k,l=l instanceof Array?l:[l],p=0,c=l.length;c>p;p++)(k=l[p].id?l[p]:this.get(l[p]))&&a.push(k)}if(a.sort(f),b)for(e=0,d=a.length;d>e;e++)a[e].updateTransform();return a},g.prototype.getShapeList=function(b){return b&&this.updateShapeList(),this._shapeList},g.prototype.updateShapeList=function(){for(var b=this._shapeListOffset=0,a=this._roots.length;a>b;b++)this._updateAndAddShape(this._roots[b]);this._shapeList.length=this._shapeListOffset;b=0;for(a=this._shapeList.length;a>b;b++)this._shapeList[b].__renderidx=b;this._shapeList.sort(f)},g.prototype._updateAndAddShape=function(b,a){if(!b.ignore)if(b.updateTransform(),"group"==b.type){b.clipShape&&(b.clipShape.parent=b,b.clipShape.updateTransform(),a?(a=a.slice(),a.push(b.clipShape)):a=[b.clipShape]);for(var e=0;e<b._children.length;e++){var d=b._children[e];d.__dirty=b.__dirty||d.__dirty;this._updateAndAddShape(d,a)}b.__dirty=!1}else b.__clipShapes=a,this._shapeList[this._shapeListOffset++]=b},g.prototype.mod=function(b,a){var e=this._elements[b];if(e&&(e.modSelf(),a))if(a.parent||a._storage||a.__clipShapes){var d={},l;for(l in a)"parent"!==l&&"_storage"!==l&&"__clipShapes"!==l&&a.hasOwnProperty(l)&&(d[l]=a[l]);q.merge(e,d,!0)}else q.merge(e,a,!0);return this},g.prototype.drift=function(b,a,e){b=this._elements[b];return b&&(b.needTransform=!0,"horizontal"===b.draggable?e=0:"vertical"===b.draggable&&(a=0),(!b.ondrift||b.ondrift&&!b.ondrift(a,e))&&b.drift(a,e)),this},g.prototype.addHover=function(b){return b.updateNeedTransform(),this._hoverElements.push(b),this},g.prototype.delHover=function(){return this._hoverElements=[],this},g.prototype.hasHoverShape=function(){return 0<this._hoverElements.length},g.prototype.addRoot=function(b){b instanceof l&&b.addChildrenToStorage(this);this.addToMap(b);this._roots.push(b)},g.prototype.delRoot=function(b){if("undefined"==typeof b){for(var a=0;a<this._roots.length;a++)b=this._roots[a],b instanceof l&&b.delChildrenFromStorage(this);return this._elements={},this._hoverElements=[],this._roots=[],this._shapeList=[],void(this._shapeListOffset=0)}if(b instanceof Array)for(var a=0,e=b.length;e>a;a++)this.delRoot(b[a]);else a="string"==typeof b?this._elements[b]:b,b=q.indexOf(this._roots,a),0<=b&&(this.delFromMap(a.id),this._roots.splice(b,1),a instanceof l&&a.delChildrenFromStorage(this))},g.prototype.addToMap=function(b){return b instanceof l&&(b._storage=this),b.modSelf(),this._elements[b.id]=b,this},g.prototype.get=function(b){return this._elements[b]},g.prototype.delFromMap=function(b){var a=this._elements[b];return a&&(delete this._elements[b],a instanceof l&&(a._storage=null)),this},g.prototype.dispose=function(){this._elements=this._renderList=this._roots=this._hoverElements=null},g});define("zrender/animation/Animation",["require","./Clip","../tool/color","../tool/util","../tool/event"],function(g){function f(a,c){return a[c]}function q(a,c,e){a[c]=e}function l(a,c,e,b,h){var d=a.length;if(1==h)for(h=0;d>h;h++){var m=a[h];b[h]=(c[h]-m)*e+m}else for(m=a[0].length,h=0;d>h;h++)for(var n=0;m>n;n++){var k=a[h][n];b[h][n]=(c[h][n]-k)*e+k}}function d(a){switch(typeof a){case "undefined":case "string":return!1}return"undefined"!=typeof a.length}function b(c,e,b,h,d,m,n,k,p){var l=c.length;if(1==p)for(p=0;l>p;p++)k[p]=a(c[p],e[p],b[p],h[p],d,m,n);else{var f=c[0].length;for(p=0;l>p;p++)for(var r=0;f>r;r++)k[p][r]=a(c[p][r],e[p][r],b[p][r],h[p][r],d,m,n)}}function a(a,c,e,b,h,d,m){a=.5*(e-a);b=.5*(b-c);return(2*(c-e)+a+b)*m+(-3*(c-e)-2*a-b)*d+a*h+c}function e(a){if(d(a)){var c=a.length;if(d(a[0])){for(var e=[],b=0;c>b;b++)e.push(n.call(a[b]));return e}return n.call(a)}return a}function m(a){return a[0]=Math.floor(a[0]),a[1]=Math.floor(a[1]),a[2]=Math.floor(a[2]),"rgba("+a.join(",")+")"}var r=g("./Clip"),k=g("../tool/color"),p=g("../tool/util"),c=g("../tool/event").Dispatcher,t=window.requestAnimationFrame||window.msRequestAnimationFrame||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame||function(a){setTimeout(a,16)},n=Array.prototype.slice;g=function(a){a=a||{};this.stage=a.stage||{};this.onframe=a.onframe||function(){};this._clips=[];this._running=!1;this._time=0;c.call(this)};g.prototype={add:function(a){this._clips.push(a)},remove:function(a){a=p.indexOf(this._clips,a);0<=a&&this._clips.splice(a,1)},_update:function(){for(var a=(new Date).getTime(),c=a-this._time,e=this._clips,b=e.length,h=[],d=[],m=0;b>m;m++){var n=e[m],k=n.step(a);k&&(h.push(k),d.push(n))}for(m=0;b>m;)e[m]._needsRemove?(e[m]=e[b-1],e.pop(),b--):m++;b=h.length;for(m=0;b>m;m++)d[m].fire(h[m]);this._time=a;this.onframe(c);this.dispatch("frame",c);this.stage.update&&this.stage.update()},start:function(){function a(){c._running&&(c._update(),t(a))}var c=this;this._running=!0;this._time=(new Date).getTime();t(a)},stop:function(){this._running=!1},clear:function(){this._clips=[]},animate:function(a,c){c=c||{};var e=new h(a,c.loop,c.getter,c.setter);return e.animation=this,e},constructor:g};p.merge(g.prototype,c.prototype,!0);var h=function(a,c,e,b){this._tracks={};this._target=a;this._loop=c||!1;this._getter=e||f;this._setter=b||q;this._delay=this._clipCount=0;this._doneList=[];this._onframeList=[];this._clipList=[]};return h.prototype={when:function(a,c){for(var b in c)this._tracks[b]||(this._tracks[b]=[],0!==a&&this._tracks[b].push({time:0,value:e(this._getter(this._target,b))})),this._tracks[b].push({time:parseInt(a,10),value:c[b]});return this},during:function(a){return this._onframeList.push(a),this},start:function(c){var e=this,h=this._setter,n=this._getter,p="spline"===c,f=function(){if(e._clipCount--,0===e._clipCount){e._tracks={};for(var a=e._doneList.length,c=0;a>c;c++)e._doneList[c].call(e)}},g=function(g,q){var t=g.length;if(t){var D=g[0].value,G=d(D),E=!1,A=G&&d(D[0])?2:1;g.sort(function(a,c){return a.time-c.time});if(t){for(var D=g[t-1].time,F=[],N=[],x=0;t>x;x++){F.push(g[x].time/D);var O=g[x].value;"string"==typeof O&&(O=k.toArray(O),0===O.length&&(O[0]=O[1]=O[2]=0,O[3]=1),E=!0);N.push(O)}var P,J,R,Q,L,S,T=0,W=0;if(E)var U=[0,0,0,0];D=new r({target:e._target,life:D,loop:e._loop,delay:e._delay,onframe:function(c,d){if(W>d){for(x=P=Math.min(T+1,t-1);0<=x&&!(F[x]<=d);x--);x=Math.min(x,t-2)}else{for(x=T;t>x&&!(F[x]>d);x++);x=Math.min(x-1,t-2)}T=x;W=d;var k=F[x+1]-F[x];if(0!==k){if(J=(d-F[x])/k,p)if(Q=N[x],R=N[0===x?x:x-1],L=N[x>t-2?t-1:x+1],S=N[x>t-3?t-1:x+2],G)b(R,Q,L,S,J,J*J,J*J*J,n(c,q),A);else{var f;E?(b(R,Q,L,S,J,J*J,J*J*J,U,1),f=m(U)):f=a(R,Q,L,S,J,J*J,J*J*J);h(c,q,f)}else G?l(N[x],N[x+1],J,n(c,q),A):(E?(l(N[x],N[x+1],J,U,1),f=m(U)):(k=N[x],f=(N[x+1]-k)*J+k),h(c,q,f));for(x=0;x<e._onframeList.length;x++)e._onframeList[x](c,d)}},ondestroy:f});c&&"spline"!==c&&(D.easing=c);e._clipList.push(D);e._clipCount++;e.animation.add(D)}}},q;for(q in this._tracks)g(this._tracks[q],q);return this},stop:function(){for(var a=0;a<this._clipList.length;a++)this.animation.remove(this._clipList[a]);this._clipList=[]},delay:function(a){return this._delay=a,this},done:function(a){return a&&this._doneList.push(a),this}},g});define("zrender/tool/env",[],function(){return function(g){var f=this.os={},q=this.browser={},l=g.match(/Web[kK]it[\/]{0,1}([\d.]+)/),d=g.match(/(Android);?[\s\/]+([\d.]+)?/),b=g.match(/(iPad).*OS\s([\d_]+)/),a=g.match(/(iPod)(.*OS\s([\d_]+))?/),e=!b&&g.match(/(iPhone\sOS)\s([\d_]+)/),m=g.match(/(webOS|hpwOS)[\s\/]([\d.]+)/),r=m&&g.match(/TouchPad/),k=g.match(/Kindle\/([\d.]+)/),p=g.match(/Silk\/([\d._]+)/),c=g.match(/(BlackBerry).*Version\/([\d.]+)/),t=g.match(/(BB10).*Version\/([\d.]+)/),n=g.match(/(RIM\sTablet\sOS)\s([\d.]+)/),h=g.match(/PlayBook/),u=g.match(/Chrome\/([\d.]+)/)||g.match(/CriOS\/([\d.]+)/),B=g.match(/Firefox\/([\d.]+)/),z;g.match(/MSIE ([\d.]+)/);var I=l&&g.match(/Mobile\//)&&!u,H=g.match(/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/)&&!u;z=g.match(/MSIE\s([\d.]+)/);return(q.webkit=!!l)&&(q.version=l[1]),d&&(f.android=!0,f.version=d[2]),e&&!a&&(f.ios=f.iphone=!0,f.version=e[2].replace(/_/g,".")),b&&(f.ios=f.ipad=!0,f.version=b[2].replace(/_/g,".")),a&&(f.ios=f.ipod=!0,f.version=a[3]?a[3].replace(/_/g,"."):null),m&&(f.webos=!0,f.version=m[2]),r&&(f.touchpad=!0),c&&(f.blackberry=!0,f.version=c[2]),t&&(f.bb10=!0,f.version=t[2]),n&&(f.rimtabletos=!0,f.version=n[2]),h&&(q.playbook=!0),k&&(f.kindle=!0,f.version=k[1]),p&&(q.silk=!0,q.version=p[1]),!p&&f.android&&g.match(/Kindle Fire/)&&(q.silk=!0),u&&(q.chrome=!0,q.version=u[1]),B&&(q.firefox=!0,q.version=B[1]),z&&(q.ie=!0,q.version=z[1]),I&&(g.match(/Safari/)||f.ios)&&(q.safari=!0),H&&(q.webview=!0),z&&(q.ie=!0,q.version=z[1]),f.tablet=!!(b||h||d&&!g.match(/Mobile/)||B&&g.match(/Tablet/)||z&&!g.match(/Phone/)&&g.match(/Touch/)),f.phone=!(f.tablet||f.ipod||!(d||e||m||c||t||u&&g.match(/Android/)||u&&g.match(/CriOS\/([\d.]+)/)||B&&g.match(/Mobile/)||z&&g.match(/Touch/))),{browser:q,os:f,canvasSupported:document.createElement("canvas").getContext?!0:!1}}(navigator.userAgent)});define("zrender/tool/vector",[],function(){var g="undefined"==typeof Float32Array?Array:Float32Array,f={create:function(f,l){var d=new g(2);return d[0]=f||0,d[1]=l||0,d},copy:function(f,l){return f[0]=l[0],f[1]=l[1],f},set:function(f,l,d){return f[0]=l,f[1]=d,f},add:function(f,l,d){return f[0]=l[0]+d[0],f[1]=l[1]+d[1],f},scaleAndAdd:function(f,l,d,b){return f[0]=l[0]+d[0]*b,f[1]=l[1]+d[1]*b,f},sub:function(f,l,d){return f[0]=l[0]-d[0],f[1]=l[1]-d[1],f},len:function(f){return Math.sqrt(this.lenSquare(f))},lenSquare:function(f){return f[0]*f[0]+f[1]*f[1]},mul:function(f,l,d){return f[0]=l[0]*d[0],f[1]=l[1]*d[1],f},div:function(f,l,d){return f[0]=l[0]/d[0],f[1]=l[1]/d[1],f},dot:function(f,l){return f[0]*l[0]+f[1]*l[1]},scale:function(f,l,d){return f[0]=l[0]*d,f[1]=l[1]*d,f},normalize:function(g,l){var d=f.len(l);return 0===d?(g[0]=0,g[1]=0):(g[0]=l[0]/d,g[1]=l[1]/d),g},distance:function(f,l){return Math.sqrt((f[0]-l[0])*(f[0]-l[0])+(f[1]-l[1])*(f[1]-l[1]))},distanceSquare:function(f,l){return(f[0]-l[0])*(f[0]-l[0])+(f[1]-l[1])*(f[1]-l[1])},negate:function(f,l){return f[0]=-l[0],f[1]=-l[1],f},lerp:function(f,l,d,b){return f[0]=l[0]+b*(d[0]-l[0]),f[1]=l[1]+b*(d[1]-l[1]),f},applyTransform:function(f,l,d){var b=l[0];l=l[1];return f[0]=d[0]*b+d[2]*l+d[4],f[1]=d[1]*b+d[3]*l+d[5],f},min:function(f,l,d){return f[0]=Math.min(l[0],d[0]),f[1]=Math.min(l[1],d[1]),f},max:function(f,l,d){return f[0]=Math.max(l[0],d[0]),f[1]=Math.max(l[1],d[1]),f}};return f.length=f.len,f.lengthSquare=f.lenSquare,f.dist=f.distance,f.distSquare=f.distanceSquare,f});define("zrender/tool/matrix",[],function(){var g="undefined"==typeof Float32Array?Array:Float32Array,f={create:function(){var q=new g(6);return f.identity(q),q},identity:function(f){return f[0]=1,f[1]=0,f[2]=0,f[3]=1,f[4]=0,f[5]=0,f},copy:function(f,l){return f[0]=l[0],f[1]=l[1],f[2]=l[2],f[3]=l[3],f[4]=l[4],f[5]=l[5],f},mul:function(f,l,d){return f[0]=l[0]*d[0]+l[2]*d[1],f[1]=l[1]*d[0]+l[3]*d[1],f[2]=l[0]*d[2]+l[2]*d[3],f[3]=l[1]*d[2]+l[3]*d[3],f[4]=l[0]*d[4]+l[2]*d[5]+l[4],f[5]=l[1]*d[4]+l[3]*d[5]+l[5],f},translate:function(f,l,d){return f[0]=l[0],f[1]=l[1],f[2]=l[2],f[3]=l[3],f[4]=l[4]+d[0],f[5]=l[5]+d[1],f},rotate:function(f,l,d){var b=l[0],a=l[2],e=l[4],m=l[1],r=l[3];l=l[5];var k=Math.sin(d);d=Math.cos(d);return f[0]=b*d+m*k,f[1]=-b*k+m*d,f[2]=a*d+r*k,f[3]=-a*k+d*r,f[4]=d*e+k*l,f[5]=d*l-k*e,f},scale:function(f,l,d){var b=d[0];d=d[1];return f[0]=l[0]*b,f[1]=l[1]*d,f[2]=l[2]*b,f[3]=l[3]*d,f[4]=l[4]*b,f[5]=l[5]*d,f},invert:function(f,l){var d=l[0],b=l[2],a=l[4],e=l[1],m=l[3],r=l[5],k=d*m-e*b;return k?(k=1/k,f[0]=m*k,f[1]=-e*k,f[2]=-b*k,f[3]=d*k,f[4]=(b*r-m*a)*k,f[5]=(e*a-d*r)*k,f):null},mulVector:function(f,l,d){var b=l[1],a=l[3],e=l[5];return f[0]=d[0]*l[0]+d[1]*l[2]+l[4],f[1]=d[0]*b+d[1]*a+e,f}};return f});define("zrender/loadingEffect/Base",["require","../tool/util","../shape/Text","../shape/Rectangle"],function(g){function f(b){this.setOptions(b)}var q=g("../tool/util"),l=g("../shape/Text"),d=g("../shape/Rectangle");return f.prototype.createTextShape=function(b){return new l({highlightStyle:q.merge({x:this.canvasWidth/2,y:this.canvasHeight/2,text:"Loading...",textAlign:"center",textBaseline:"middle",textFont:"normal 16px Arial",color:"#333",brushType:"fill"},b,!0)})},f.prototype.createBackgroundShape=function(b){return new d({highlightStyle:{x:0,y:0,width:this.canvasWidth,height:this.canvasHeight,brushType:"fill",color:b}})},f.prototype.start=function(b){this.canvasWidth=b._width;this.canvasHeight=b._height;this.loadingTimer=this._start(function(a){b.storage.addHover(a)},function(){b.refreshHover()})},f.prototype._start=function(){return setInterval(function(){},1E4)},f.prototype.stop=function(){clearInterval(this.loadingTimer)},f.prototype.setOptions=function(b){this.options=b||{}},f.prototype.adjust=function(b,a){return b<=a[0]?b=a[0]:b>=a[1]&&(b=a[1]),b},f.prototype.getLocation=function(b,a,e){var d=null!=b.x?b.x:"center";switch(d){case "center":d=Math.floor((this.canvasWidth-a)/2);break;case "left":d=0;break;case "right":d=this.canvasWidth-a}b=null!=b.y?b.y:"center";switch(b){case "center":b=Math.floor((this.canvasHeight-e)/2);break;case "top":b=0;break;case "bottom":b=this.canvasHeight-e}return{x:d,y:b,width:a,height:e}},f});define("zrender/Layer",["require","./mixin/Transformable","./tool/util","./config"],function(g){function f(){return!1}function q(e,b,d){b=document.createElement(b);var k=d.getWidth();d=d.getHeight();return b.style.position="absolute",b.style.left=0,b.style.top=0,b.style.width=k+"px",b.style.height=d+"px",b.width=k*a.devicePixelRatio,b.height=d*a.devicePixelRatio,b.setAttribute("data-zr-dom-id",e),b}var l=g("./mixin/Transformable"),d=g("./tool/util"),b=window.G_vmlCanvasManager,a=g("./config");g=function(a,d){this.id=a;this.dom=q(a,"canvas",d);this.dom.onselectstart=f;this.dom.style["-webkit-user-select"]="none";this.dom.style["user-select"]="none";this.dom.style["-webkit-touch-callout"]="none";this.dom.style["-webkit-tap-highlight-color"]="rgba(0,0,0,0)";b&&b.initElement(this.dom);this.ctxBack=this.domBack=null;this.painter=d;this.unusedCount=0;this.config=null;this.dirty=!0;this.clearColor=this.elCount=0;this.motionBlur=!1;this.lastFrameAlpha=.7;this.panable=this.zoomable=!1;this.maxZoom=1/0;this.minZoom=0;l.call(this)};return g.prototype.initContext=function(){this.ctx=this.dom.getContext("2d");var e=a.devicePixelRatio;1!=e&&this.ctx.scale(e,e)},g.prototype.createBackBuffer=function(){if(!b){this.domBack=q("back-"+this.id,"canvas",this.painter);this.ctxBack=this.domBack.getContext("2d");var e=a.devicePixelRatio;1!=e&&this.ctxBack.scale(e,e)}},g.prototype.resize=function(e,b){var d=a.devicePixelRatio;this.dom.style.width=e+"px";this.dom.style.height=b+"px";this.dom.setAttribute("width",e*d);this.dom.setAttribute("height",b*d);1!=d&&this.ctx.scale(d,d);this.domBack&&(this.domBack.setAttribute("width",e*d),this.domBack.setAttribute("height",b*d),1!=d&&this.ctxBack.scale(d,d))},g.prototype.clear=function(){var e=this.dom,d=this.ctx,f=e.width,k=e.height,p=this.clearColor&&!b,c=this.motionBlur&&!b,l=this.lastFrameAlpha,n=a.devicePixelRatio;if(c&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(e,0,0,f/n,k/n)),d.clearRect(0,0,f/n,k/n),p&&(d.save(),d.fillStyle=this.clearColor,d.fillRect(0,0,f/n,k/n),d.restore()),c)e=this.domBack,d.save(),d.globalAlpha=l,d.drawImage(e,0,0,f/n,k/n),d.restore()},d.merge(g.prototype,l.prototype),g});define("zrender/shape/Text",["require","../tool/area","./Base","../tool/util"],function(g){var f=g("../tool/area"),q=g("./Base"),l=function(d){q.call(this,d)};return l.prototype={type:"text",brush:function(d,b){var a=this.style;if(b&&(a=this.getHighlightStyle(a,this.highlightStyle||{})),"undefined"!=typeof a.text&&!1!==a.text){d.save();this.doClip(d);this.setContext(d,a);this.setTransform(d);a.textFont&&(d.font=a.textFont);d.textAlign=a.textAlign||"start";d.textBaseline=a.textBaseline||"middle";var e,m=(a.text+"").split("\n"),l=f.getTextHeight("\u56fd",a.textFont);e=this.getRect(a);var k=a.x;e="top"==a.textBaseline?e.y:"bottom"==a.textBaseline?e.y+l:e.y+l/2;for(var p=0,c=m.length;c>p;p++){if(a.maxWidth)switch(a.brushType){case "fill":d.fillText(m[p],k,e,a.maxWidth);break;case "stroke":d.strokeText(m[p],k,e,a.maxWidth);break;case "both":d.fillText(m[p],k,e,a.maxWidth);d.strokeText(m[p],k,e,a.maxWidth);break;default:d.fillText(m[p],k,e,a.maxWidth)}else switch(a.brushType){case "fill":d.fillText(m[p],k,e);break;case "stroke":d.strokeText(m[p],k,e);break;case "both":d.fillText(m[p],k,e);d.strokeText(m[p],k,e);break;default:d.fillText(m[p],k,e)}e+=l}d.restore()}},getRect:function(d){if(d.__rect)return d.__rect;var b=f.getTextWidth(d.text,d.textFont),a=f.getTextHeight(d.text,d.textFont),e=d.x;"end"==d.textAlign||"right"==d.textAlign?e-=b:"center"==d.textAlign&&(e-=b/2);var m;return m="top"==d.textBaseline?d.y:"bottom"==d.textBaseline?d.y-a:d.y-a/2,d.__rect={x:e,y:m,width:b,height:a},d.__rect}},g("../tool/util").inherits(l,q),l});define("zrender/shape/Rectangle",["require","./Base","../tool/util"],function(g){var f=g("./Base"),q=function(l){f.call(this,l)};return q.prototype={type:"rectangle",_buildRadiusPath:function(f,d){var b,a,e,m,r=d.x,k=d.y,p=d.width,c=d.height,g=d.radius;"number"==typeof g?b=a=e=m=g:g instanceof Array?1===g.length?b=a=e=m=g[0]:2===g.length?(b=e=g[0],a=m=g[1]):3===g.length?(b=g[0],a=m=g[1],e=g[2]):(b=g[0],a=g[1],e=g[2],m=g[3]):b=a=e=m=0;var n;b+a>p&&(n=b+a,b*=p/n,a*=p/n);e+m>p&&(n=e+m,e*=p/n,m*=p/n);a+e>c&&(n=a+e,a*=c/n,e*=c/n);b+m>c&&(n=b+m,b*=c/n,m*=c/n);f.moveTo(r+b,k);f.lineTo(r+p-a,k);0!==a&&f.quadraticCurveTo(r+p,k,r+p,k+a);f.lineTo(r+p,k+c-e);0!==e&&f.quadraticCurveTo(r+p,k+c,r+p-e,k+c);f.lineTo(r+m,k+c);0!==m&&f.quadraticCurveTo(r,k+c,r,k+c-m);f.lineTo(r,k+b);0!==b&&f.quadraticCurveTo(r,k,r+b,k)},buildPath:function(f,d){d.radius?this._buildRadiusPath(f,d):(f.moveTo(d.x,d.y),f.lineTo(d.x+d.width,d.y),f.lineTo(d.x+d.width,d.y+d.height),f.lineTo(d.x,d.y+d.height),f.lineTo(d.x,d.y));f.closePath()},getRect:function(f){if(f.__rect)return f.__rect;var d;return d="stroke"==f.brushType||"fill"==f.brushType?f.lineWidth||1:0,f.__rect={x:Math.round(f.x-d/2),y:Math.round(f.y-d/2),width:f.width+d,height:f.height+d},f.__rect}},g("../tool/util").inherits(q,f),q});define("zrender/tool/area",["require","./util"],function(g){function f(a,e,b,c){if(!e||!a)return!1;l=l||d.getContext();var m;a:{switch(a.type){case "line":m=e.xStart;var n=e.yStart,h=e.xEnd,f=e.yEnd,g=e.lineWidth;if(0===g)m=!1;else{var g=Math.max(g,5),z;c>n+g&&c>f+g||n-g>c&&f-g>c||b>m+g&&b>h+g||m-g>b&&h-g>b?m=!1:m===h?m=Math.abs(b-m)<=g/2:(z=(n-f)/(m-h),m=z*b-c+(m*f-h*n)/(m-h),m=g/2*g/2>=m*m/(z*z+1))}break a;case "text":m=e.__rect||a.getRect(e);m=q(m.x,m.y,m.width,m.height,b,c);break a;case "rectangle":case "image":m=q(e.x,e.y,e.width,e.height,b,c);break a}m=void 0}"undefined"!=typeof m?a=m:(m=l,a=(m.beginPath(),a.buildPath(m,e),m.closePath(),m.isPointInPath(b,c)));return a}function q(a,e,b,c,d,m){return d>=a&&a+b>=d&&m>=e&&e+c>=m}var l,d=g("./util"),b={},a={},e=0,m=0;return{isInside:f,isOutside:function(a,e,b,c){return!f(a,e,b,c)},getTextWidth:function(a,m){var f=a+":"+m;if(b[f])return b[f];l=l||d.getContext();l.save();m&&(l.font=m);a=(a+"").split("\n");for(var c=0,g=0,n=a.length;n>g;g++)c=Math.max(l.measureText(a[g]).width,c);return l.restore(),b[f]=c,5E3<++e&&(e=0,b={}),c},getTextHeight:function(e,b){var f=e+":"+b;if(a[f])return a[f];l=l||d.getContext();l.save();b&&(l.font=b);e=(e+"").split("\n");var c=(l.measureText("\u56fd").width+2)*e.length;return l.restore(),a[f]=c,5E3<++m&&(m=0,a={}),c},isInsideRect:q}});define("zrender/shape/Base","require ../tool/matrix ../tool/guid ../tool/util ../tool/log ../mixin/Transformable ../mixin/Eventful ../tool/area ../tool/color".split(" "),function(g){var f=window.G_vmlCanvasManager,q=g("../tool/matrix"),l=g("../tool/guid"),d=g("../tool/util"),b=g("../tool/log"),a=g("../mixin/Transformable"),e=g("../mixin/Eventful"),m=function(b){b=b||{};this.id=b.id||l();for(var c in b)this[c]=b[c];this.style=this.style||{};this.highlightStyle=this.highlightStyle||null;this.parent=null;this.__dirty=!0;this.__clipShapes=[];a.call(this);e.call(this)};m.prototype.invisible=!1;m.prototype.ignore=!1;m.prototype.zlevel=0;m.prototype.draggable=!1;m.prototype.clickable=!1;m.prototype.hoverable=!0;m.prototype.z=0;m.prototype.brush=function(a,c){var e=this.beforeBrush(a,c);switch(a.beginPath(),this.buildPath(a,e),e.brushType){case "both":a.fill();case "stroke":0<e.lineWidth&&a.stroke();break;default:a.fill()}this.drawText(a,e,this.style);this.afterBrush(a)};m.prototype.beforeBrush=function(a,c){var e=this.style;return this.brushTypeOnly&&(e.brushType=this.brushTypeOnly),c&&(e=this.getHighlightStyle(e,this.highlightStyle||{},this.brushTypeOnly)),"stroke"==this.brushTypeOnly&&(e.strokeColor=e.strokeColor||e.color),a.save(),this.doClip(a),this.setContext(a,e),this.setTransform(a),e};m.prototype.afterBrush=function(a){a.restore()};var r=[["color","fillStyle"],["strokeColor","strokeStyle"],["opacity","globalAlpha"],["lineCap","lineCap"],["lineJoin","lineJoin"],["miterLimit","miterLimit"],["lineWidth","lineWidth"],["shadowBlur","shadowBlur"],["shadowColor","shadowColor"],["shadowOffsetX","shadowOffsetX"],["shadowOffsetY","shadowOffsetY"]];m.prototype.setContext=function(a,c){for(var e=0,b=r.length;b>e;e++){var h=c[r[e][0]],d=r[e][1];"undefined"!=typeof h&&(a[d]=h)}};var k=q.create();return m.prototype.doClip=function(a){if(this.__clipShapes&&!f)for(var c=0;c<this.__clipShapes.length;c++){var e=this.__clipShapes[c];if(e.needTransform){var b=e.transform;q.invert(k,b);a.transform(b[0],b[1],b[2],b[3],b[4],b[5])}if(a.beginPath(),e.buildPath(a,e.style),a.clip(),e.needTransform)b=k,a.transform(b[0],b[1],b[2],b[3],b[4],b[5])}},m.prototype.getHighlightStyle=function(a,c,e){var b={},h;for(h in a)b[h]=a[h];var d=g("../tool/color"),m=d.getHighlightColor();"stroke"!=a.brushType?(b.strokeColor=m,b.lineWidth=(a.lineWidth||1)+this.getHighlightZoom(),b.brushType="both"):"stroke"!=e?(b.strokeColor=m,b.lineWidth=(a.lineWidth||1)+this.getHighlightZoom()):b.strokeColor=c.strokeColor||d.mix(a.strokeColor,d.toRGB(m));for(h in c)"undefined"!=typeof c[h]&&(b[h]=c[h]);return b},m.prototype.getHighlightZoom=function(){return"text"!=this.type?6:2},m.prototype.drift=function(a,c){this.position[0]+=a;this.position[1]+=c},m.prototype.getTansform=function(){var a=[];return function(c,e){var b=[c,e];return this.needTransform&&this.transform&&(q.invert(a,this.transform),q.mulVector(b,a,[c,e,1]),c==b[0]&&e==b[1]&&this.updateNeedTransform()),b}}(),m.prototype.buildPath=function(){b("buildPath not implemented in "+this.type)},m.prototype.getRect=function(){b("getRect not implemented in "+this.type)},m.prototype.isCover=function(a,c){var e=this.getTansform(a,c);a=e[0];c=e[1];e=this.style.__rect;return e||(e=this.style.__rect=this.getRect(this.style)),a>=e.x&&a<=e.x+e.width&&c>=e.y&&c<=e.y+e.height?g("../tool/area").isInside(this,this.style,a,c):!1},m.prototype.drawText=function(a,c,e){var b;if("undefined"!=typeof c.text&&!1!==c.text){var h=c.textColor||c.color||c.strokeColor;a.fillStyle=h;var d,m,f,k=10,l=c.textPosition||this.textPosition||"top";switch(l){case "inside":case "top":case "bottom":case "left":case "right":if(this.getRect){var r=(e||c).__rect||this.getRect(e||c);switch(l){case "inside":f=r.x+r.width/2;b=r.y+r.height/2;d="center";m="middle";"stroke"!=c.brushType&&h==c.color&&(a.fillStyle="#fff");break;case "left":f=r.x-k;b=r.y+r.height/2;d="end";m="middle";break;case "right":f=r.x+r.width+k;b=r.y+r.height/2;d="start";m="middle";break;case "top":f=r.x+r.width/2;b=r.y-k;d="center";m="bottom";break;case "bottom":f=r.x+r.width/2,b=r.y+r.height+k,d="center",m="top"}}break;case "start":case "end":b=c.pointList||[[c.xStart||0,c.yStart||0],[c.xEnd||0,c.yEnd||0]];f=b.length;if(2>f)return;var q,G,K;switch(l){case "start":r=b[1][0];q=b[0][0];G=b[1][1];K=b[0][1];break;case "end":r=b[f-2][0],q=b[f-1][0],G=b[f-2][1],K=b[f-1][1]}f=q;b=K;l=Math.atan((G-K)/(q-r))/Math.PI*180;0>q-r?l+=180:0>G-K&&(l+=360);k=5;30<=l&&150>=l?(d="center",m="bottom",b-=k):150<l&&210>l?(d="right",m="middle",f-=k):210<=l&&330>=l?(d="center",m="top",b+=k):(d="left",m="middle",f+=k);break;case "specific":f=c.textX||0,b=c.textY||0,d="start",m="middle"}if(null!=f&&null!=b){l=c.text;r=c.textFont;d=c.textAlign||d;c=c.textBaseline||m;r&&(a.font=r);a.textAlign=d;a.textBaseline=c;m=l;d=g("../tool/area");d.getTextWidth(m,r);d=d.getTextHeight("\u56fd",r);m=(m+"").split("\n");switch(c){case "top":break;case "bottom":b-=d*m.length;break;default:b-=d*m.length/2}l=(l+"").split("\n");m=g("../tool/area").getTextHeight("\u56fd",r);switch(c){case "top":c=b;break;case "bottom":c=b+m;break;default:c=b+m/2}b=0;for(d=l.length;d>b;b++)a.fillText(l[b],f,c),c+=m}}},m.prototype.modSelf=function(){this.__dirty=!0;this.style&&(this.style.__rect=null);this.highlightStyle&&(this.highlightStyle.__rect=null)},m.prototype.isSilent=function(){return!(this.hoverable||this.draggable||this.clickable||this.onmousemove||this.onmouseover||this.onmouseout||this.onmousedown||this.onmouseup||this.onclick||this.ondragenter||this.ondragover||this.ondragleave||this.ondrop)},d.merge(m.prototype,a.prototype,!0),d.merge(m.prototype,e.prototype,!0),m});define("zrender/mixin/Transformable",["require","../tool/matrix","../tool/vector"],function(g){function f(e){return e>-a&&a>e}function q(e){return e>a||-a>e}var l=g("../tool/matrix"),d=g("../tool/vector"),b=[0,0],a=5E-5;g=function(){this.position||(this.position=[0,0]);"undefined"==typeof this.rotation&&(this.rotation=[0,0,0]);this.scale||(this.scale=[1,1,0,0]);this.needTransform=this.needLocalTransform=!1};return g.prototype={constructor:g,updateNeedTransform:function(){this.needLocalTransform=q(this.rotation[0])||q(this.position[0])||q(this.position[1])||q(this.scale[0]-1)||q(this.scale[1]-1)},updateTransform:function(){if(this.updateNeedTransform(),this.needTransform=this.parent?this.needLocalTransform||this.parent.needTransform:this.needLocalTransform,this.needTransform){var a=this.transform||l.create();if(l.identity(a),this.needLocalTransform){if(q(this.scale[0])||q(this.scale[1])){b[0]=-this.scale[2]||0;b[1]=-this.scale[3]||0;var d=q(b[0])||q(b[1]);d&&l.translate(a,a,b);l.scale(a,a,this.scale);d&&(b[0]=-b[0],b[1]=-b[1],l.translate(a,a,b))}this.rotation instanceof Array?0!==this.rotation[0]&&(b[0]=-this.rotation[1]||0,b[1]=-this.rotation[2]||0,(d=q(b[0])||q(b[1]))&&l.translate(a,a,b),l.rotate(a,a,this.rotation[0]),d&&(b[0]=-b[0],b[1]=-b[1],l.translate(a,a,b))):0!==this.rotation&&l.rotate(a,a,this.rotation);(q(this.position[0])||q(this.position[1]))&&l.translate(a,a,this.position)}this.transform=a;this.parent&&this.parent.needTransform&&(this.needLocalTransform?l.mul(this.transform,this.parent.transform,this.transform):l.copy(this.transform,this.parent.transform))}},setTransform:function(a){if(this.needTransform){var b=this.transform;a.transform(b[0],b[1],b[2],b[3],b[4],b[5])}},lookAt:function(){var a=d.create();return function(b){this.transform||(this.transform=l.create());var g=this.transform;d.sub(a,b,this.position);f(a[0])&&f(a[1])||(d.normalize(a,a),g[2]=a[0]*this.scale[1],g[3]=a[1]*this.scale[1],g[0]=a[1]*this.scale[0],g[1]=-a[0]*this.scale[0],g[4]=this.position[0],g[5]=this.position[1],this.decomposeTransform())}}(),decomposeTransform:function(){if(this.transform){var a=this.transform,b=a[0]*a[0]+a[1]*a[1],d=this.position,f=this.scale,l=this.rotation;q(b-1)&&(b=Math.sqrt(b));var c=a[2]*a[2]+a[3]*a[3];q(c-1)&&(c=Math.sqrt(c));d[0]=a[4];d[1]=a[5];f[0]=b;f[1]=c;f[2]=f[3]=0;l[0]=Math.atan2(-a[1]/c,a[0]/b);l[1]=l[2]=0}}},g});define("zrender/Group",["require","./tool/guid","./tool/util","./mixin/Transformable","./mixin/Eventful"],function(g){var f=g("./tool/guid"),q=g("./tool/util"),l=g("./mixin/Transformable"),d=g("./mixin/Eventful"),b=function(a){a=a||{};this.id=a.id||f();for(var b in a)this[b]=a[b];this.type="group";this.clipShape=null;this._children=[];this._storage=null;this.__dirty=!0;l.call(this);d.call(this)};return b.prototype.ignore=!1,b.prototype.children=function(){return this._children.slice()},b.prototype.childAt=function(a){return this._children[a]},b.prototype.addChild=function(a){a!=this&&a.parent!=this&&(a.parent&&a.parent.removeChild(a),this._children.push(a),a.parent=this,this._storage&&this._storage!==a._storage&&(this._storage.addToMap(a),a instanceof b&&a.addChildrenToStorage(this._storage)))},b.prototype.removeChild=function(a){var e=q.indexOf(this._children,a);this._children.splice(e,1);a.parent=null;this._storage&&(this._storage.delFromMap(a.id),a instanceof b&&a.delChildrenFromStorage(this._storage))},b.prototype.clearChildren=function(){for(var a=0;a<this._children.length;a++){var e=this._children[a];this._storage&&(this._storage.delFromMap(e.id),e instanceof b&&e.delChildrenFromStorage(this._storage))}this._children.length=0},b.prototype.eachChild=function(a,b){for(var d=!!b,f=0;f<this._children.length;f++){var k=this._children[f];d?a.call(b,k):a(k)}},b.prototype.traverse=function(a,b){for(var d=!!b,f=0;f<this._children.length;f++){var k=this._children[f];d?a.call(b,k):a(k);"group"===k.type&&k.traverse(a,b)}},b.prototype.addChildrenToStorage=function(a){for(var e=0;e<this._children.length;e++){var d=this._children[e];a.addToMap(d);d instanceof b&&d.addChildrenToStorage(a)}},b.prototype.delChildrenFromStorage=function(a){for(var e=0;e<this._children.length;e++){var d=this._children[e];a.delFromMap(d.id);d instanceof b&&d.delChildrenFromStorage(a)}},b.prototype.modSelf=function(){this.__dirty=!0},q.merge(b.prototype,l.prototype,!0),q.merge(b.prototype,d.prototype,!0),b});define("zrender/animation/Clip",["require","./easing"],function(g){function f(f){this._targetPool=f.target||{};this._targetPool instanceof Array||(this._targetPool=[this._targetPool]);this._life=f.life||1E3;this._delay=f.delay||0;this._startTime=(new Date).getTime()+this._delay;this._endTime=this._startTime+1E3*this._life;this.loop="undefined"==typeof f.loop?!1:f.loop;this.gap=f.gap||0;this.easing=f.easing||"Linear";this.onframe=f.onframe;this.ondestroy=f.ondestroy;this.onrestart=f.onrestart}var q=g("./easing");return f.prototype={step:function(f){f=(f-this._startTime)/this._life;if(!(0>f)){f=Math.min(f,1);var d="string"==typeof this.easing?q[this.easing]:this.easing,d="function"==typeof d?d(f):f;return this.fire("frame",d),1==f?this.loop?(this.restart(),"restart"):(this._needsRemove=!0,"destroy"):null}},restart:function(){var f=((new Date).getTime()-this._startTime)%this._life;this._startTime=(new Date).getTime()-f+this.gap;this._needsRemove=!1},fire:function(f,d){for(var b=0,a=this._targetPool.length;a>b;b++)this["on"+f]&&this["on"+f](this._targetPool[b],d)},constructor:f},f});define("zrender/animation/easing",[],function(){var g={Linear:function(f){return f},QuadraticIn:function(f){return f*f},QuadraticOut:function(f){return f*(2-f)},QuadraticInOut:function(f){return 1>(f*=2)?.5*f*f:-.5*(--f*(f-2)-1)},CubicIn:function(f){return f*f*f},CubicOut:function(f){return--f*f*f+1},CubicInOut:function(f){return 1>(f*=2)?.5*f*f*f:.5*((f-=2)*f*f+2)},QuarticIn:function(f){return f*f*f*f},QuarticOut:function(f){return 1- --f*f*f*f},QuarticInOut:function(f){return 1>(f*=2)?.5*f*f*f*f:-.5*((f-=2)*f*f*f-2)},QuinticIn:function(f){return f*f*f*f*f},QuinticOut:function(f){return--f*f*f*f*f+1},QuinticInOut:function(f){return 1>(f*=2)?.5*f*f*f*f*f:.5*((f-=2)*f*f*f*f+2)},SinusoidalIn:function(f){return 1-Math.cos(f*Math.PI/2)},SinusoidalOut:function(f){return Math.sin(f*Math.PI/2)},SinusoidalInOut:function(f){return.5*(1-Math.cos(Math.PI*f))},ExponentialIn:function(f){return 0===f?0:Math.pow(1024,f-1)},ExponentialOut:function(f){return 1===f?1:1-Math.pow(2,-10*f)},ExponentialInOut:function(f){return 0===f?0:1===f?1:1>(f*=2)?.5*Math.pow(1024,f-1):.5*(-Math.pow(2,-10*(f-1))+2)},CircularIn:function(f){return 1-Math.sqrt(1-f*f)},CircularOut:function(f){return Math.sqrt(1- --f*f)},CircularInOut:function(f){return 1>(f*=2)?-.5*(Math.sqrt(1-f*f)-1):.5*(Math.sqrt(1-(f-=2)*f)+1)},ElasticIn:function(f){var g,l=.1;return 0===f?0:1===f?1:(!l||1>l?(l=1,g=.1):g=.4*Math.asin(1/l)/(2*Math.PI),-(l*Math.pow(2,10*--f)*Math.sin(2*(f-g)*Math.PI/.4)))},ElasticOut:function(f){var g,l=.1;return 0===f?0:1===f?1:(!l||1>l?(l=1,g=.1):g=.4*Math.asin(1/l)/(2*Math.PI),l*Math.pow(2,-10*f)*Math.sin(2*(f-g)*Math.PI/.4)+1)},ElasticInOut:function(f){var g,l=.1;return 0===f?0:1===f?1:(!l||1>l?(l=1,g=.1):g=.4*Math.asin(1/l)/(2*Math.PI),1>(f*=2)?-.5*l*Math.pow(2,10*--f)*Math.sin(2*(f-g)*Math.PI/.4):l*Math.pow(2,-10*--f)*Math.sin(2*(f-g)*Math.PI/.4)*.5+1)},BackIn:function(f){return f*f*(2.70158*f-1.70158)},BackOut:function(f){return--f*f*(2.70158*f+1.70158)+1},BackInOut:function(f){return 1>(f*=2)?.5*f*f*(3.5949095*f-2.5949095):.5*((f-=2)*f*(3.5949095*f+2.5949095)+2)},BounceIn:function(f){return 1-g.BounceOut(1-f)},BounceOut:function(f){return 1/2.75>f?7.5625*f*f:2/2.75>f?7.5625*(f-=1.5/2.75)*f+.75:2.5/2.75>f?7.5625*(f-=2.25/2.75)*f+.9375:7.5625*(f-=2.625/2.75)*f+.984375},BounceInOut:function(f){return.5>f?.5*g.BounceIn(2*f):.5*g.BounceOut(2*f-1)+.5}};return g});define("echarts/chart/base","require zrender/shape/Image ../util/shape/Icon ../util/shape/MarkLine ../util/shape/Symbol ../config ../util/ecData ../util/ecAnimation ../util/ecEffect ../util/accMath ../component/base zrender/tool/util zrender/tool/area".split(" "),function(g){function f(c,b,d,m,f){p.call(this,c,b,d,m,f);var k=this;this.selectedMap={};this.lastShapeList=[];this.shapeHandler={onclick:function(){k.isClick=!0},ondragover:function(c){c=c.target;c.highlightStyle=c.highlightStyle||{};var b=c.highlightStyle,e=b.brushTyep,h=b.strokeColor,d=b.lineWidth;b.brushType="stroke";b.strokeColor=k.ecTheme.calculableColor||a.calculableColor;b.lineWidth="icon"===c.type?30:10;k.zr.addHoverShape(c);setTimeout(function(){b&&(b.brushType=e,b.strokeColor=h,b.lineWidth=d)},20)},ondrop:function(a){null!=e.get(a.dragged,"data")&&(k.isDrop=!0)},ondragend:function(){k.isDragend=!0}}}var q=g("zrender/shape/Image"),l=g("../util/shape/Icon"),d=g("../util/shape/MarkLine"),b=g("../util/shape/Symbol"),a=g("../config"),e=g("../util/ecData"),m=g("../util/ecAnimation"),r=g("../util/ecEffect"),k=g("../util/accMath"),p=g("../component/base"),c=g("zrender/tool/util"),t=g("zrender/tool/area");return f.prototype={setCalculable:function(c){return c.dragEnableTime=this.ecTheme.DRAG_ENABLE_TIME||a.DRAG_ENABLE_TIME,c.ondragover=this.shapeHandler.ondragover,c.ondragend=this.shapeHandler.ondragend,c.ondrop=this.shapeHandler.ondrop,c},ondrop:function(c,b){if(this.isDrop&&c.target&&!b.dragIn){var d;d=c.target;var m=c.dragged,f=e.get(d,"seriesIndex"),l=e.get(d,"dataIndex"),g=this.series,p=this.component.legend;if(-1===l){if(e.get(m,"seriesIndex")==f)return b.dragOut=b.dragIn=b.needRefresh=!0,void(this.isDrop=!1);d={value:e.get(m,"value"),name:e.get(m,"name")};this.type===a.CHART_TYPE_PIE&&0>d.value&&(d.value=0);for(var l=!1,r=g[f].data,t=0,q=r.length;q>t;t++)r[t].name===d.name&&"-"===r[t].value&&(g[f].data[t].value=d.value,l=!0);!l&&g[f].data.push(d);p&&p.add(d.name,m.style.color||m.style.strokeColor)}else d=g[f].data[l]||"-",null!=d.value?(g[f].data[l].value="-"!=d.value?k.accAdd(g[f].data[l].value,e.get(m,"value")):e.get(m,"value"),(this.type===a.CHART_TYPE_FUNNEL||this.type===a.CHART_TYPE_PIE)&&(p&&1===p.getRelatedAmount(d.name)&&this.component.legend.del(d.name),d.name+=this.option.nameConnector+e.get(m,"name"),p&&p.add(d.name,m.style.color||m.style.strokeColor))):g[f].data[l]="-"!=d?k.accAdd(g[f].data[l],e.get(m,"value")):e.get(m,"value");b.dragIn=b.dragIn||!0;this.isDrop=!1;var C=this;setTimeout(function(){C.zr.trigger("mousemove",c.event)},300)}},ondragend:function(a,c){if(this.isDragend&&a.target&&!c.dragOut){var b=a.target,d=e.get(b,"seriesIndex"),b=e.get(b,"dataIndex"),m=this.series;null!=m[d].data[b].value?(m[d].data[b].value="-",d=m[d].data[b].name,(b=this.component.legend)&&0===b.getRelatedAmount(d)&&b.del(d)):m[d].data[b]="-";c.dragOut=!0;c.needRefresh=!0;this.isDragend=!1}},onlegendSelected:function(a,c){var b=a.selected,e;for(e in this.selectedMap)this.selectedMap[e]!=b[e]&&(c.needRefresh=!0),this.selectedMap[e]=b[e]},_buildPosition:function(){this._symbol=this.option.symbolList;this._sIndex2ShapeMap={};this._sIndex2ColorMap={};this.selectedMap={};this.xMarkMap={};for(var c,b,e,d,m=this.series,f={top:[],bottom:[],left:[],right:[],other:[]},k=0,l=m.length;l>k;k++)m[k].type===this.type&&(m[k]=this.reformOption(m[k]),this.legendHoverLink=m[k].legendHoverLink||this.legendHoverLink,c=m[k].xAxisIndex,b=m[k].yAxisIndex,e=this.component.xAxis.getAxis(c),d=this.component.yAxis.getAxis(b),e.type===a.COMPONENT_TYPE_AXIS_CATEGORY?f[e.getPosition()].push(k):d.type===a.COMPONENT_TYPE_AXIS_CATEGORY?f[d.getPosition()].push(k):f.other.push(k));for(var g in f)0<f[g].length&&this._buildSinglePosition(g,f[g]);this.addShapeList()},_buildSinglePosition:function(a,c){var b=this._mapData(c),e=b.locationMap,b=b.maxDataLength;if(0!==b&&0!==e.length){switch(a){case "bottom":case "top":this._buildHorizontal(c,b,e,this.xMarkMap);break;case "left":case "right":this._buildVertical(c,b,e,this.xMarkMap);break;case "other":this._buildOther(c,b,e,this.xMarkMap)}e=0;for(b=c.length;b>e;e++)this.buildMark(c[e])}},_mapData:function(c){for(var b,e,d,m,f=this.series,k=0,l={},g=this.component.legend,p=[],r=0,t=0,q=c.length;q>t;t++){if(b=f[c[t]],d=b.name,this._sIndex2ShapeMap[c[t]]=this._sIndex2ShapeMap[c[t]]||this.query(b,"symbol")||this._symbol[t%this._symbol.length],g){if(this.selectedMap[d]=g.isSelected(d),this._sIndex2ColorMap[c[t]]=g.getColor(d),m=g.getItemShape(d)){var v=m.style;if(this.type==a.CHART_TYPE_LINE)v.iconType="legendLineIcon",v.symbol=this._sIndex2ShapeMap[c[t]];else if(0<b.itemStyle.normal.barBorderWidth){var w=m.highlightStyle;v.brushType="both";v.x+=1;v.y+=1;v.width-=2;v.height-=2;v.strokeColor=w.strokeColor=b.itemStyle.normal.barBorderColor;w.lineWidth=3}g.setItemShape(d,m)}}else this.selectedMap[d]=!0,this._sIndex2ColorMap[c[t]]=this.zr.getColor(c[t]);this.selectedMap[d]&&(e=b.stack||"__kener__stack__"+c[t],null==l[e]?(l[e]=k,p[k]=[c[t]],k++):p[l[e]].push(c[t]));r=Math.max(r,b.data.length)}return{locationMap:p,maxDataLength:r}},_calculMarkMapXY:function(a,c,b){for(var e=this.series,d=0,m=c.length;m>d;d++)for(var f=0,k=c[d].length;k>f;f++){var l=c[d][f],g="xy"==b?0:"",p=this.component.grid,r=a[l];if("-1"!=b.indexOf("x")){0<r["counter"+g]&&(r["average"+g]=r["sum"+g]/r["counter"+g]);var t=this.component.xAxis.getAxis(e[l].xAxisIndex||0).getCoord(r["average"+g]);r["averageLine"+g]=[[t,p.getYend()],[t,p.getY()]];r["minLine"+g]=[[r["minX"+g],p.getYend()],[r["minX"+g],p.getY()]];r["maxLine"+g]=[[r["maxX"+g],p.getYend()],[r["maxX"+g],p.getY()]];r.isHorizontal=!1}if(g="xy"==b?1:"","-1"!=b.indexOf("y"))0<r["counter"+g]&&(r["average"+g]=r["sum"+g]/r["counter"+g]),l=this.component.yAxis.getAxis(e[l].yAxisIndex||0).getCoord(r["average"+g]),r["averageLine"+g]=[[p.getX(),l],[p.getXend(),l]],r["minLine"+g]=[[p.getX(),r["minY"+g]],[p.getXend(),r["minY"+g]]],r["maxLine"+g]=[[p.getX(),r["maxY"+g]],[p.getXend(),r["maxY"+g]]],r.isHorizontal=!0}},addLabel:function(a,c,b,e,d){var m=[b,c],f=this.deepMerge(m,"itemStyle.normal.label"),m=this.deepMerge(m,"itemStyle.emphasis.label"),k=f.textStyle||{},l=m.textStyle||{};if(f.show){var g=a.style;g.text=this._getLabelText(c,b,e,"normal");g.textPosition=null==f.position?"horizontal"===d?"right":"top":f.position;g.textColor=k.color;g.textFont=this.getFont(k);g.textAlign=k.align;g.textBaseline=k.baseline}m.show&&(k=a.highlightStyle,k.text=this._getLabelText(c,b,e,"emphasis"),k.textPosition=f.show?a.style.textPosition:null==m.position?"horizontal"===d?"right":"top":m.position,k.textColor=l.color,k.textFont=this.getFont(l),k.textAlign=l.align,k.textBaseline=l.baseline);return a},_getLabelText:function(a,c,b,e){var d=this.deepQuery([c,a],"itemStyle."+e+".label.formatter");d||"emphasis"!==e||(d=this.deepQuery([c,a],"itemStyle.normal.label.formatter"));var m=this.getDataFromOption(c,"-");return d?"function"==typeof d?d.call(this.myChart,{seriesName:a.name,series:a,name:b,value:m,data:c,status:e}):"string"==typeof d?d.replace("{a}","{a0}").replace("{b}","{b0}").replace("{c}","{c0}").replace("{a0}",a.name).replace("{b0}",b).replace("{c0}",this.numAddCommas(m)):void 0:m instanceof Array?null!=m[2]?this.numAddCommas(m[2]):m[0]+" , "+m[1]:this.numAddCommas(m)},buildMark:function(a){var c=this.series[a];this.selectedMap[c.name]&&(c.markLine&&this._buildMarkLine(a),c.markPoint&&this._buildMarkPoint(a))},_buildMarkPoint:function(b){for(var e,d,m=(this.markAttachStyle||{})[b],f=c.clone(this.series[b].markPoint),k=0,l=f.data.length;l>k;k++)e=f.data[k],d=this.getMarkCoord(b,e),e.x=null!=e.x?e.x:d[0],e.y=null!=e.y?e.y:d[1],!e.type||"max"!==e.type&&"min"!==e.type||(e.value=d[3],e.name=e.name||e.type,e.symbolSize=e.symbolSize||t.getTextWidth(d[3],this.getFont())/2+5);b=this._markPoint(b,f);k=0;for(l=b.length;l>k;k++){e=b[k];e.zlevel=this.getZlevelBase();e.z=this.getZBase()+1;for(var g in m)e[g]=c.clone(m[g]);this.shapeList.push(e)}if(this.type===a.CHART_TYPE_FORCE||this.type===a.CHART_TYPE_CHORD)for(k=0,l=b.length;l>k;k++)this.zr.addShape(b[k])},_buildMarkLine:function(b){for(var e,d=(this.markAttachStyle||{})[b],m=c.clone(this.series[b].markLine),f=0,k=m.data.length;k>f;f++){var l=m.data[f];!l.type||"max"!==l.type&&"min"!==l.type&&"average"!==l.type?e=[this.getMarkCoord(b,l[0]),this.getMarkCoord(b,l[1])]:(e=this.getMarkCoord(b,l),m.data[f]=[c.clone(l),{}],m.data[f][0].name=l.name||l.type,m.data[f][0].value="average"!==l.type?e[3]:+e[3].toFixed(null!=m.precision?m.precision:this.deepQuery([this.ecTheme,a],"markLine.precision")),e=e[2],l=[{},{}]);null!=e&&null!=e[0]&&null!=e[1]&&(m.data[f][0].x=null!=l[0].x?l[0].x:e[0][0],m.data[f][0].y=null!=l[0].y?l[0].y:e[0][1],m.data[f][1].x=null!=l[1].x?l[1].x:e[1][0],m.data[f][1].y=null!=l[1].y?l[1].y:e[1][1])}b=this._markLine(b,m);f=0;for(k=b.length;k>f;f++){e=b[f];e.zlevel=this.getZlevelBase();e.z=this.getZBase()+1;for(var g in d)e[g]=c.clone(d[g]);this.shapeList.push(e)}if(this.type===a.CHART_TYPE_FORCE||this.type===a.CHART_TYPE_CHORD)for(f=0,k=b.length;k>f;f++)this.zr.addShape(b[f])},_markPoint:function(b,d){var m=this.series[b],f=this.component;c.merge(c.merge(d,c.clone(this.ecTheme.markPoint||{})),c.clone(a.markPoint));d.name=m.name;var k,l,g,p,r,t,q,C=[],y=d.data,v=f.dataRange,f=f.legend,w=this.zr.getWidth(),E=this.zr.getHeight();if(d.large)k=this.getLargeMarkPoingShape(b,d),k._mark="largePoint",k&&C.push(k);else for(var A=0,F=y.length;F>A;A++)null!=y[A].x&&null!=y[A].y&&(g=null!=y[A].value?y[A].value:"",f&&(l=f.getColor(m.name)),v&&(l=isNaN(g)?l:v.getColor(g),p=[y[A],d],r=this.deepQuery(p,"itemStyle.normal.color")||l,t=this.deepQuery(p,"itemStyle.emphasis.color")||r,null==r&&null==t)||(l=null==l?this.zr.getColor(b):l,y[A].tooltip=y[A].tooltip||d.tooltip||{trigger:"item"},y[A].name=null!=y[A].name?y[A].name:"",y[A].value=g,k=this.getSymbolShape(d,b,y[A],A,y[A].name,this.parsePercent(y[A].x,w),this.parsePercent(y[A].y,E),"pin",l,"rgba(0,0,0,0)","horizontal"),k._mark="point",q=this.deepMerge([y[A],d],"effect"),q.show&&(k.effect=q),m.type===a.CHART_TYPE_MAP&&(k._geo=this.getMarkGeo(y[A])),e.pack(k,m,b,y[A],A,y[A].name,g),C.push(k)));return C},_markLine:function(b,d){var m=this.series[b],f=this.component;c.merge(c.merge(d,c.clone(this.ecTheme.markLine||{})),c.clone(a.markLine));d.symbol=d.symbol instanceof Array?1<d.symbol.length?d.symbol:[d.symbol[0],d.symbol[0]]:[d.symbol,d.symbol];d.symbolSize=d.symbolSize instanceof Array?1<d.symbolSize.length?d.symbolSize:[d.symbolSize[0],d.symbolSize[0]]:[d.symbolSize,d.symbolSize];d.symbolRotate=d.symbolRotate instanceof Array?1<d.symbolRotate.length?d.symbolRotate:[d.symbolRotate[0],d.symbolRotate[0]]:[d.symbolRotate,d.symbolRotate];d.name=m.name;for(var k,l,g,p,r,t,q,C,y=[],v=d.data,w=f.dataRange,f=f.legend,E=this.zr.getWidth(),A=this.zr.getHeight(),F=0,N=v.length;N>F;F++){var x=v[F];null!=x[0].x&&null!=x[0].y&&null!=x[1].x&&null!=x[1].y&&(l=f?f.getColor(m.name):this.zr.getColor(b),C=this.deepMerge(x),g=null!=C.value?C.value:"",w&&(l=isNaN(g)?l:w.getColor(g),p=[C,d],r=this.deepQuery(p,"itemStyle.normal.color")||l,t=this.deepQuery(p,"itemStyle.emphasis.color")||r,null==r&&null==t)||(x[0].tooltip=C.tooltip||d.tooltip||{trigger:"item"},x[0].name=null!=x[0].name?x[0].name:"",x[1].name=null!=x[1].name?x[1].name:"",x[0].value=g,k=this.getLineMarkShape(d,b,x,F,this.parsePercent(x[0].x,E),this.parsePercent(x[0].y,A),this.parsePercent(x[1].x,E),this.parsePercent(x[1].y,A),l),k._mark="line",q=this.deepMerge([C,d],"effect"),q.show&&(k.effect=q),m.type===a.CHART_TYPE_MAP&&(k._geo=[this.getMarkGeo(x[0]),this.getMarkGeo(x[1])]),e.pack(k,m,b,x[0],F,x[0].name+(""!==x[1].name?" \x3e "+x[1].name:""),g),y.push(k)))}return y},getMarkCoord:function(){return[0,0]},getSymbolShape:function(a,c,b,d,m,f,k,g,p,r,t){var C=[b,a],y=this.getDataFromOption(b,"-");g=this.deepQuery(C,"symbol")||g;var v=this.deepQuery(C,"symbolSize"),v="function"==typeof v?v(y):v,y=this.deepQuery(C,"symbolRotate"),w=this.deepMerge(C,"itemStyle.normal"),E=this.deepMerge(C,"itemStyle.emphasis"),A=null!=w.borderWidth?w.borderWidth:w.lineStyle&&w.lineStyle.width;null==A&&(A=g.match("empty")?2:0);var F=null!=E.borderWidth?E.borderWidth:E.lineStyle&&E.lineStyle.width;null==F&&(F=A+2);p=new l({style:{iconType:g.replace("empty","").toLowerCase(),x:f-v,y:k-v,width:2*v,height:2*v,brushType:"both",color:g.match("empty")?r:this.getItemStyleColor(w.color,c,d,b)||p,strokeColor:w.borderColor||this.getItemStyleColor(w.color,c,d,b)||p,lineWidth:A},highlightStyle:{color:g.match("empty")?r:this.getItemStyleColor(E.color,c,d,b),strokeColor:E.borderColor||w.borderColor||this.getItemStyleColor(w.color,c,d,b)||p,lineWidth:F},clickable:this.deepQuery(C,"clickable")});return g.match("image")&&(p.style.image=g.replace(/^image:\/\//,""),p=new q({style:p.style,highlightStyle:p.highlightStyle,clickable:this.deepQuery(C,"clickable")})),null!=y&&(p.rotation=[y*Math.PI/180,f,k]),g.match("star")&&(p.style.iconType="star",p.style.n=g.replace("empty","").replace("star","")-0||5),"none"===g&&(p.invisible=!0,p.hoverable=!1),p=this.addLabel(p,a,b,m,t),g.match("empty")&&(null==p.style.textColor&&(p.style.textColor=p.style.strokeColor),null==p.highlightStyle.textColor&&(p.highlightStyle.textColor=p.highlightStyle.strokeColor)),e.pack(p,a,c,b,d,m),p._x=f,p._y=k,p._dataIndex=d,p._seriesIndex=c,p},getLineMarkShape:function(a,c,b,e,m,f,k,l,g){var p=null!=b[0].value?b[0].value:"-",r=null!=b[1].value?b[1].value:"-",t=[this.query(b[0],"symbol")||a.symbol[0],this.query(b[1],"symbol")||a.symbol[1]],q=[this.query(b[0],"symbolSize")||a.symbolSize[0],this.query(b[1],"symbolSize")||a.symbolSize[1]];q[0]="function"==typeof q[0]?q[0](p):q[0];q[1]="function"==typeof q[1]?q[1](r):q[1];var p=[this.query(b[0],"symbolRotate")||a.symbolRotate[0],this.query(b[1],"symbolRotate")||a.symbolRotate[1]],r=[b[0],b[1],a],v=this.deepMerge(r,"itemStyle.normal");v.color=this.getItemStyleColor(v.color,c,e,b);var w=this.deepMerge(r,"itemStyle.emphasis");w.color=this.getItemStyleColor(w.color,c,e,b);c=v.lineStyle;e=w.lineStyle;var E=c.width;null==E&&(E=v.borderWidth);var A=e.width;null==A&&(A=null!=w.borderWidth?w.borderWidth:E+2);m=new d({style:{smooth:this.deepQuery([b[0],b[1],a],"smooth")?"spline":!1,smoothRadian:this.deepQuery([b[0],b[1],a],"smoothRadian"),symbol:t,symbolSize:q,symbolRotate:p,xStart:m,yStart:f,xEnd:k,yEnd:l,brushType:"both",lineType:c.type,shadowColor:c.shadowColor||c.color||v.borderColor||v.color||g,shadowBlur:c.shadowBlur,shadowOffsetX:c.shadowOffsetX,shadowOffsetY:c.shadowOffsetY,color:v.color||g,strokeColor:c.color||v.borderColor||v.color||g,lineWidth:E,symbolBorderColor:v.borderColor||v.color||g,symbolBorder:v.borderWidth},highlightStyle:{shadowColor:e.shadowColor,shadowBlur:e.shadowBlur,shadowOffsetX:e.shadowOffsetX,shadowOffsetY:e.shadowOffsetY,color:w.color||v.color||g,strokeColor:e.color||c.color||w.borderColor||v.borderColor||w.color||v.color||g,lineWidth:A,symbolBorderColor:w.borderColor||v.borderColor||w.color||v.color||g,symbolBorder:null==w.borderWidth?v.borderWidth+2:w.borderWidth},clickable:this.deepQuery(r,"clickable")});return m=this.addLabel(m,a,b[0],b[0].name+" : "+b[1].name),m._x=k,m._y=l,m},getLargeMarkPoingShape:function(a,c){var e,d,m,f,k,l=this.series[a],g=this.component,p=c.data,r=g.dataRange,t=g.legend,g=[p[0],c];if(t&&(d=t.getColor(l.name)),!r||(m=null!=p[0].value?p[0].value:"",d=isNaN(m)?d:r.getColor(m),f=this.deepQuery(g,"itemStyle.normal.color")||d,k=this.deepQuery(g,"itemStyle.emphasis.color")||f,null!=f||null!=k))return d=this.deepMerge(g,"itemStyle.normal").color||d,f=this.deepQuery(g,"symbol")||"circle",f=f.replace("empty","").replace(/\d/g,""),m=this.deepMerge([p[0],c],"effect"),e=new b({style:{pointList:p,color:d,strokeColor:d,shadowColor:m.shadowColor||d,shadowBlur:(null!=m.shadowBlur?m.shadowBlur:8)*(window.devicePixelRatio||1),size:this.deepQuery(g,"symbolSize"),iconType:f,brushType:"fill",lineWidth:1},draggable:!1,hoverable:!1}),m.show&&(e.effect=m),e},backupShapeList:function(){this.shapeList&&0<this.shapeList.length?(this.lastShapeList=this.shapeList,this.shapeList=[]):this.lastShapeList=[]},addShapeList:function(){var c,b,e=this.option.animationThreshold/2,d=this.lastShapeList,m=this.shapeList,f=0<d.length,k=f?this.query(this.option,"animationDurationUpdate"):this.query(this.option,"animationDuration"),l=this.query(this.option,"animationEasing"),g={},p={};if(this.option.animation&&!this.option.renderAsImage&&m.length<e&&!this.motionlessOnce){for(var e=0,r=d.length;r>e;e++)b=this._getAnimationKey(d[e]),b.match("undefined")?this.zr.delShape(d[e].id):(b+=d[e].type,g[b]?this.zr.delShape(d[e].id):g[b]=d[e]);e=0;for(r=m.length;r>e;e++)b=this._getAnimationKey(m[e]),b.match("undefined")?this.zr.addShape(m[e]):(b+=m[e].type,p[b]=m[e]);for(b in g)p[b]||this.zr.delShape(g[b].id);for(b in p)g[b]?(this.zr.delShape(g[b].id),this._animateMod(g[b],p[b],k,l,0,f)):(c=this.type!=a.CHART_TYPE_LINE&&this.type!=a.CHART_TYPE_RADAR||0===b.indexOf("icon")?0:k/2,this._animateMod(!1,p[b],k,l,c,f));this.zr.refresh();this.animationEffect()}else for(this.motionlessOnce=!1,this.zr.delShape(d),e=0,r=m.length;r>e;e++)this.zr.addShape(m[e])},_getAnimationKey:function(c){return this.type!=a.CHART_TYPE_MAP?e.get(c,"seriesIndex")+"_"+e.get(c,"dataIndex")+(c._mark?c._mark:"")+(this.type===a.CHART_TYPE_RADAR?e.get(c,"special"):""):e.get(c,"seriesIndex")+"_"+e.get(c,"dataIndex")+(c._mark?c._mark:"undefined")},_animateMod:function(a,c,b,d,f,k){switch(c.type){case "polyline":case "half-smooth-polygon":m.pointList(this.zr,a,c,b,d);break;case "rectangle":m.rectangle(this.zr,a,c,b,d);break;case "image":case "icon":m.icon(this.zr,a,c,b,d,f);break;case "candle":k?this.zr.addShape(c):m.candle(this.zr,a,c,b,d);break;case "ring":case "sector":case "circle":k?"sector"===c.type?m.sector(this.zr,a,c,b,d):this.zr.addShape(c):m.ring(this.zr,a,c,b+(e.get(c,"dataIndex")||0)%20*100,d);break;case "text":m.text(this.zr,a,c,b,d);break;case "polygon":k?m.pointList(this.zr,a,c,b,d):m.polygon(this.zr,a,c,b,d);break;case "ribbon":m.ribbon(this.zr,a,c,b,d);break;case "gauge-pointer":m.gaugePointer(this.zr,a,c,b,d);break;case "mark-line":m.markline(this.zr,a,c,b,d);break;case "bezier-curve":case "line":m.line(this.zr,a,c,b,d);break;default:this.zr.addShape(c)}},animationMark:function(a,c,b){for(var e=b||this.shapeList,d=0,m=e.length;m>d;d++)e[d]._mark&&this._animateMod(!1,e[d],a,c,0,!0);this.animationEffect(b)},animationEffect:function(c){!c&&this.clearEffectShape();c=c||this.shapeList;if(null!=c){var b=a.EFFECT_ZLEVEL;this.zr.modLayer(b,{motionBlur:!0,lastFrameAlpha:.95});for(var e,d=0,m=c.length;m>d;d++)e=c[d],e._mark&&e.effect&&e.effect.show&&r[e._mark]&&(r[e._mark](this.zr,this.effectList,e,b),this.effectList[this.effectList.length-1]._mark=e._mark)}},clearEffectShape:function(c){this.zr&&this.effectList&&0<this.effectList.length&&(c&&this.zr.modLayer(a.EFFECT_ZLEVEL,{motionBlur:!1}),this.zr.delShape(this.effectList));this.effectList=[]},addMark:function(a,c,b){var e=this.series[a];if(this.selectedMap[e.name]){var d=this.query(this.option,"animationDurationUpdate"),m=this.query(this.option,"animationEasing"),f=e[b].data,k=this.shapeList.length;if(e[b].data=c.data,this["_build"+b.replace("m","M")](a),this.option.animation&&!this.option.renderAsImage)this.animationMark(d,m,this.shapeList.slice(k));else{a=k;for(c=this.shapeList.length;c>a;a++)this.zr.addShape(this.shapeList[a]);this.zr.refreshNextFrame()}e[b].data=f}},delMark:function(a,c,b){b=b.replace("mark","").replace("large","").toLowerCase();if(this.selectedMap[this.series[a].name]){for(var d=!1,m=[this.shapeList,this.effectList],f=2;f--;)for(var k=0,g=m[f].length;g>k;k++)if(m[f][k]._mark==b&&e.get(m[f][k],"seriesIndex")==a&&e.get(m[f][k],"name")==c){this.zr.delShape(m[f][k].id);m[f].splice(k,1);d=!0;break}d&&this.zr.refreshNextFrame()}}},c.inherits(f,p),f});define("zrender/shape/Circle",["require","./Base","../tool/util"],function(g){var f=g("./Base"),q=function(g){f.call(this,g)};return q.prototype={type:"circle",buildPath:function(f,d){f.arc(d.x,d.y,d.r,0,2*Math.PI,!0)},getRect:function(f){if(f.__rect)return f.__rect;var d;return d="stroke"==f.brushType||"fill"==f.brushType?f.lineWidth||1:0,f.__rect={x:Math.round(f.x-f.r-d/2),y:Math.round(f.y-f.r-d/2),width:2*f.r+d,height:2*f.r+d},f.__rect}},g("../tool/util").inherits(q,f),q});define("echarts/util/accMath",[],function(){function g(f,g){var l=0,d=0;try{l=f.toString().split(".")[1].length}catch(b){}try{d=g.toString().split(".")[1].length}catch(b){}l=Math.pow(10,Math.max(l,d));return(Math.round(f*l)+Math.round(g*l))/l}return{accDiv:function(f,g){var l=f.toString(),d=g.toString(),b=0;try{b=d.split(".")[1].length}catch(a){}try{b-=l.split(".")[1].length}catch(a){}return(l.replace(".","")-0)/(d.replace(".","")-0)*Math.pow(10,b)},accMul:function(f,g){var l=f.toString(),d=g.toString(),b=0;try{b+=l.split(".")[1].length}catch(a){}try{b+=d.split(".")[1].length}catch(a){}return(l.replace(".","")-0)*(d.replace(".","")-0)/Math.pow(10,b)},accAdd:g,accSub:function(f,q){return g(f,-q)}}});define("echarts/util/shape/Icon","require zrender/tool/util zrender/shape/Star zrender/shape/Heart zrender/shape/Droplet zrender/shape/Image zrender/shape/Base".split(" "),function(g){function f(d){l.call(this,d)}var q=g("zrender/tool/util"),l=g("zrender/shape/Base");return f.prototype={type:"icon",iconLibrary:{mark:function(d,b){var a=b.x,e=b.y,m=b.width/16,f=b.height/16;d.moveTo(a,e+b.height);d.lineTo(a+5*m,e+14*f);d.lineTo(a+b.width,e+3*f);d.lineTo(a+13*m,e);d.lineTo(a+2*m,e+11*f);d.lineTo(a,e+b.height);d.moveTo(a+6*m,e+10*f);d.lineTo(a+14*m,e+2*f);d.moveTo(a+10*m,e+13*f);d.lineTo(a+b.width,e+13*f);d.moveTo(a+13*m,e+10*f);d.lineTo(a+13*m,e+b.height)},markUndo:function(d,b){var a=b.x,e=b.y,m=b.width/16,f=b.height/16;d.moveTo(a,e+b.height);d.lineTo(a+5*m,e+14*f);d.lineTo(a+b.width,e+3*f);d.lineTo(a+13*m,e);d.lineTo(a+2*m,e+11*f);d.lineTo(a,e+b.height);d.moveTo(a+6*m,e+10*f);d.lineTo(a+14*m,e+2*f);d.moveTo(a+10*m,e+13*f);d.lineTo(a+b.width,e+13*f)},markClear:function(d,b){var a=b.x,e=b.y,m=b.width/16,f=b.height/16;d.moveTo(a+4*m,e+15*f);d.lineTo(a+9*m,e+13*f);d.lineTo(a+14*m,e+8*f);d.lineTo(a+11*m,e+5*f);d.lineTo(a+6*m,e+10*f);d.lineTo(a+4*m,e+15*f);d.moveTo(a+5*m,e);d.lineTo(a+11*m,e);d.moveTo(a+5*m,e+f);d.lineTo(a+11*m,e+f);d.moveTo(a,e+2*f);d.lineTo(a+b.width,e+2*f);d.moveTo(a,e+5*f);d.lineTo(a+3*m,e+b.height);d.lineTo(a+13*m,e+b.height);d.lineTo(a+b.width,e+5*f)},dataZoom:function(d,b){var a=b.x,e=b.y,m=b.width/16,f=b.height/16;d.moveTo(a,e+3*f);d.lineTo(a+6*m,e+3*f);d.moveTo(a+3*m,e);d.lineTo(a+3*m,e+6*f);d.moveTo(a+3*m,e+8*f);d.lineTo(a+3*m,e+b.height);d.lineTo(a+b.width,e+b.height);d.lineTo(a+b.width,e+3*f);d.lineTo(a+8*m,e+3*f)},dataZoomReset:function(d,b){var a=b.x,e=b.y,m=b.width/16,f=b.height/16;d.moveTo(a+6*m,e);d.lineTo(a+2*m,e+3*f);d.lineTo(a+6*m,e+6*f);d.moveTo(a+2*m,e+3*f);d.lineTo(a+14*m,e+3*f);d.lineTo(a+14*m,e+11*f);d.moveTo(a+2*m,e+5*f);d.lineTo(a+2*m,e+13*f);d.lineTo(a+14*m,e+13*f);d.moveTo(a+10*m,e+10*f);d.lineTo(a+14*m,e+13*f);d.lineTo(a+10*m,e+b.height)},restore:function(d,b){var a=b.x,e=b.y,f=b.width/16,g=b.height/16,k=b.width/2;d.lineWidth=1.5;d.arc(a+k,e+k,k-f,0,2*Math.PI/3);d.moveTo(a+3*f,e+b.height);d.lineTo(a+0*f,e+12*g);d.lineTo(a+5*f,e+11*g);d.moveTo(a,e+8*g);d.arc(a+k,e+k,k-f,Math.PI,5*Math.PI/3);d.moveTo(a+13*f,e);d.lineTo(a+b.width,e+4*g);d.lineTo(a+11*f,e+5*g)},lineChart:function(d,b){var a=b.x,e=b.y,f=b.width/16,g=b.height/16;d.moveTo(a,e);d.lineTo(a,e+b.height);d.lineTo(a+b.width,e+b.height);d.moveTo(a+2*f,e+14*g);d.lineTo(a+7*f,e+6*g);d.lineTo(a+11*f,e+11*g);d.lineTo(a+15*f,e+2*g)},barChart:function(d,b){var a=b.x,e=b.y,f=b.width/16,g=b.height/16;d.moveTo(a,e);d.lineTo(a,e+b.height);d.lineTo(a+b.width,e+b.height);d.moveTo(a+3*f,e+14*g);d.lineTo(a+3*f,e+6*g);d.lineTo(a+4*f,e+6*g);d.lineTo(a+4*f,e+14*g);d.moveTo(a+7*f,e+14*g);d.lineTo(a+7*f,e+2*g);d.lineTo(a+8*f,e+2*g);d.lineTo(a+8*f,e+14*g);d.moveTo(a+11*f,e+14*g);d.lineTo(a+11*f,e+9*g);d.lineTo(a+12*f,e+9*g);d.lineTo(a+12*f,e+14*g)},pieChart:function(d,b){var a=b.x,e=b.y,f=Math.min(b.width-2,b.height-2)/2,e=e+2;d.moveTo(a+f+3,e+f-3);d.arc(a+f+3,e+f-3,f-1,0,-Math.PI/2,!0);d.lineTo(a+f+3,e+f-3);d.moveTo(a+f,e);d.lineTo(a+f,e+f);d.arc(a+f,e+f,f,-Math.PI/2,2*Math.PI,!0);d.lineTo(a+f,e+f);d.lineWidth=1.5},funnelChart:function(d,b){var a=b.x,e=b.y,f=b.width/16,g=b.height/16,e=e-g;d.moveTo(a+1*f,e+2*g);d.lineTo(a+15*f,e+2*g);d.lineTo(a+14*f,e+3*g);d.lineTo(a+2*f,e+3*g);d.moveTo(a+3*f,e+6*g);d.lineTo(a+13*f,e+6*g);d.lineTo(a+12*f,e+7*g);d.lineTo(a+4*f,e+7*g);d.moveTo(a+5*f,e+10*g);d.lineTo(a+11*f,e+10*g);d.lineTo(a+10*f,e+11*g);d.lineTo(a+6*f,e+11*g);d.moveTo(a+7*f,e+14*g);d.lineTo(a+9*f,e+14*g);d.lineTo(a+8*f,e+15*g);d.lineTo(a+7*f,e+15*g)},forceChart:function(d,b){var a=b.x,e=b.y,f=b.width/16,g=b.height/16,k=2*Math.min(f,g);d.moveTo(a+f+k,e+g+k);d.arc(a+f,e+g,k,Math.PI/4,3*Math.PI);d.lineTo(a+7*f-k,e+6*g-k);d.arc(a+7*f,e+6*g,k,Math.PI/4*5,4*Math.PI);d.arc(a+7*f,e+6*g,k/2,Math.PI/4*5,4*Math.PI);d.moveTo(a+7*f-k/2,e+6*g+k);d.lineTo(a+f+k,e+14*g-k);d.arc(a+f,e+14*g,k,-Math.PI/4,2*Math.PI);d.moveTo(a+7*f+k/2,e+6*g);d.lineTo(a+14*f-k,e+10*g-k/2);d.moveTo(a+16*f,e+10*g);d.arc(a+14*f,e+10*g,k,0,3*Math.PI);d.lineWidth=1.5},chordChart:function(d,b){var a=b.x,e=b.y,f=b.width,g=b.height,k=Math.min(f,g)/2;d.moveTo(a+f,e+g/2);d.arc(a+k,e+k,k,0,2*Math.PI);d.arc(a+k,e,k,Math.PI/4,Math.PI/5*4);d.arc(a,e+k,k,-Math.PI/3,Math.PI/3);d.arc(a+f,e+g,k,Math.PI,Math.PI/2*3);d.lineWidth=1.5},stackChart:function(d,b){for(var a=b.x,e=b.y,f=b.width,g=Math.round(b.height/3),k=Math.round((g-2)/2),l=3;l--;)d.rect(a,e+g*l+k,f,2)},tiledChart:function(d,b){for(var a=b.x,e=b.y,f=b.height,g=Math.round(b.width/3),k=Math.round((g-2)/2),l=3;l--;)d.rect(a+g*l+k,e,2,f)},dataView:function(d,b){var a=b.x,e=b.y,f=b.width/16;d.moveTo(a+f,e);d.lineTo(a+f,e+b.height);d.lineTo(a+15*f,e+b.height);d.lineTo(a+15*f,e);d.lineTo(a+f,e);d.moveTo(a+3*f,e+3*f);d.lineTo(a+13*f,e+3*f);d.moveTo(a+3*f,e+6*f);d.lineTo(a+13*f,e+6*f);d.moveTo(a+3*f,e+9*f);d.lineTo(a+13*f,e+9*f);d.moveTo(a+3*f,e+12*f);d.lineTo(a+9*f,e+12*f)},saveAsImage:function(d,b){var a=b.x,e=b.y,f=b.width/16,g=b.height/16;d.moveTo(a,e);d.lineTo(a,e+b.height);d.lineTo(a+b.width,e+b.height);d.lineTo(a+b.width,e);d.lineTo(a,e);d.moveTo(a+4*f,e);d.lineTo(a+4*f,e+8*g);d.lineTo(a+12*f,e+8*g);d.lineTo(a+12*f,e);d.moveTo(a+6*f,e+11*g);d.lineTo(a+6*f,e+13*g);d.lineTo(a+10*f,e+13*g);d.lineTo(a+10*f,e+11*g);d.lineTo(a+6*f,e+11*g)},cross:function(d,b){var a=b.x,e=b.y,f=b.width,g=b.height;d.moveTo(a,e+g/2);d.lineTo(a+f,e+g/2);d.moveTo(a+f/2,e);d.lineTo(a+f/2,e+g)},circle:function(d,b){var a=b.width/2,e=b.height/2,f=Math.min(a,e);d.moveTo(b.x+a+f,b.y+e);d.arc(b.x+a,b.y+e,f,0,2*Math.PI);d.closePath()},rectangle:function(d,b){d.rect(b.x,b.y,b.width,b.height);d.closePath()},triangle:function(d,b){var a=b.width/2,e=b.height/2,f=b.x+a,g=b.y+e,a=Math.min(a,e);d.moveTo(f,g-a);d.lineTo(f+a,g+a);d.lineTo(f-a,g+a);d.lineTo(f,g-a);d.closePath()},diamond:function(d,b){var a=b.width/2,e=b.height/2,f=b.x+a,g=b.y+e,a=Math.min(a,e);d.moveTo(f,g-a);d.lineTo(f+a,g);d.lineTo(f,g+a);d.lineTo(f-a,g);d.lineTo(f,g-a);d.closePath()},arrow:function(d,b){var a=b.x,e=b.y,f=b.width/16;d.moveTo(a+8*f,e);d.lineTo(a+f,e+b.height);d.lineTo(a+8*f,e+b.height/4*3);d.lineTo(a+15*f,e+b.height);d.lineTo(a+8*f,e);d.closePath()},star:function(d,b){var a=g("zrender/shape/Star"),e=b.width/2,f=b.height/2;a.prototype.buildPath(d,{x:b.x+e,y:b.y+f,r:Math.min(e,f),n:b.n||5})},heart:function(d,b){g("zrender/shape/Heart").prototype.buildPath(d,{x:b.x+b.width/2,y:b.y+.2*b.height,a:b.width/2,b:.8*b.height})},droplet:function(d,b){g("zrender/shape/Droplet").prototype.buildPath(d,{x:b.x+.5*b.width,y:b.y+.5*b.height,a:.5*b.width,b:.8*b.height})},pin:function(d,b){var a=b.x,e=b.y-b.height/2*1.5,f=b.width/2,g=b.height/2,k=Math.min(f,g);d.arc(a+f,e+g,k,Math.PI/5*4,Math.PI/5);d.lineTo(a+f,e+g+1.5*k);d.closePath()},image:function(d,b,a){var e=g("zrender/shape/Image");this._imageShape=this._imageShape||new e({style:{}});for(var f in b)this._imageShape.style[f]=b[f];this._imageShape.brush(d,!1,a)}},brush:function(d,b,a){var e=b?this.highlightStyle:this.style,e=e||{};if("image"===(e.iconType||this.style.iconType))g("zrender/shape/Image").prototype.brush.call(this,d,b,a);else{e=this.beforeBrush(d,b);switch(d.beginPath(),this.buildPath(d,e,a),e.brushType){case "both":d.fill();case "stroke":0<e.lineWidth&&d.stroke();break;default:d.fill()}this.drawText(d,e,this.style);this.afterBrush(d)}},buildPath:function(d,b,a){this.iconLibrary[b.iconType]?this.iconLibrary[b.iconType].call(this,d,b,a):(d.moveTo(b.x,b.y),d.lineTo(b.x+b.width,b.y),d.lineTo(b.x+b.width,b.y+b.height),d.lineTo(b.x,b.y+b.height),d.lineTo(b.x,b.y),d.closePath())},getRect:function(d){return d.__rect?d.__rect:(d.__rect={x:Math.round(d.x),y:Math.round(d.y-("pin"==d.iconType?d.height/2*1.5:0)),width:d.width,height:d.height*("pin"===d.iconType?1.25:1)},d.__rect)},isCover:function(d,b){var a=this.getTansform(d,b);d=a[0];b=a[1];(a=this.style.__rect)||(a=this.style.__rect=this.getRect(this.style));var e=8>a.height||8>a.width?4:0;return d>=a.x-e&&d<=a.x+a.width+e&&b>=a.y-e&&b<=a.y+a.height+e?!0:!1}},q.inherits(f,l),f});define("echarts/util/shape/MarkLine","require zrender/shape/Base ./Icon zrender/shape/Line zrender/shape/Polyline zrender/tool/matrix zrender/tool/area zrender/shape/util/dashedLineTo zrender/shape/util/smoothSpline zrender/tool/util".split(" "),function(g){function f(a){q.call(this,a)}var q=g("zrender/shape/Base"),l=g("./Icon"),d=new (g("zrender/shape/Line"))({}),b=new (g("zrender/shape/Polyline"))({}),a=g("zrender/tool/matrix"),e=g("zrender/tool/area"),m=g("zrender/shape/util/dashedLineTo"),r=g("zrender/shape/util/smoothSpline");g=g("zrender/tool/util");return f.prototype={type:"mark-line",brush:function(a,b){var c=this.style;b&&(c=this.getHighlightStyle(c,this.highlightStyle||{}));a.save();this.setContext(a,c);this.setTransform(a);a.save();a.beginPath();this.buildLinePath(a,c,this.style.lineWidth||1);a.stroke();a.restore();this.brushSymbol(a,c,0);this.brushSymbol(a,c,1);this.drawText(a,c,this.style);a.restore()},buildLinePath:function(a,b,c){var e=b.pointList||this.getPointList(b);b.pointList=e;var d=Math.min(b.pointList.length,Math.round(b.pointListLength||b.pointList.length));if(b.lineType&&"solid"!=b.lineType){if("dashed"==b.lineType||"dotted"==b.lineType)if("spline"!==b.smooth)for(b=c*("dashed"==b.lineType?5:1),a.moveTo(e[0][0],e[0][1]),c=1;d>c;c++)m(a,e[c-1][0],e[c-1][1],e[c][0],e[c][1],b);else for(c=1;d>c;c+=2)a.moveTo(e[c-1][0],e[c-1][1]),a.lineTo(e[c][0],e[c][1])}else for(a.moveTo(e[0][0],e[0][1]),c=1;d>c;c++)a.lineTo(e[c][0],e[c][1])},brushSymbol:function(b,e,c){if("none"!=e.symbol[c]){b.save();b.beginPath();b.lineWidth=e.symbolBorder;b.strokeStyle=e.symbolBorderColor;e.iconType=e.symbol[c].replace("empty","").toLowerCase();e.symbol[c].match("empty")&&(b.fillStyle="#fff");var d,f=Math.min(e.pointList.length,Math.round(e.pointListLength||e.pointList.length)),h=0===c?e.pointList[0][0]:e.pointList[f-1][0],f=0===c?e.pointList[0][1]:e.pointList[f-1][1],m="undefined"!=typeof e.symbolRotate[c]?e.symbolRotate[c]-0:0;(0!==m&&(d=a.create(),a.identity(d),(h||f)&&a.translate(d,d,[-h,-f]),a.rotate(d,d,m*Math.PI/180),(h||f)&&a.translate(d,d,[h,f]),b.transform.apply(b,d)),"arrow"==e.iconType&&0===m)?this.buildArrawPath(b,e,c):(c=e.symbolSize[c],e.x=h-c,e.y=f-c,e.width=2*c,e.height=2*c,l.prototype.buildPath(b,e));b.closePath();b.fill();b.stroke();b.restore()}},buildArrawPath:function(a,b,c){var e=Math.min(b.pointList.length,Math.round(b.pointListLength||b.pointList.length)),d=2*b.symbolSize[c],f=b.pointList[0][0],m=b.pointList[e-1][0],g=b.pointList[0][1],e=b.pointList[e-1][1],l=0;"spline"===b.smooth&&(l=b.smoothRadian*(m>=f?1:-1));b=Math.atan(Math.abs((e-g)/(f-m)));0===c?m>f?e>g?b=2*Math.PI-b+l:b+=l:e>g?b+=Math.PI-l:b=Math.PI-b-l:f>m?g>e?b=2*Math.PI-b+l:b+=l:g>e?b+=Math.PI-l:b=Math.PI-b-l;l=Math.PI/8;f=0===c?f:m;c=0===c?g:e;d=[[f+d*Math.cos(b-l),c-d*Math.sin(b-l)],[f+.6*d*Math.cos(b),c-.6*d*Math.sin(b)],[f+d*Math.cos(b+l),c-d*Math.sin(b+l)]];a.moveTo(f,c);g=0;for(m=d.length;m>g;g++)a.lineTo(d[g][0],d[g][1]);a.lineTo(f,c)},getPointList:function(a){var b=[[a.xStart,a.yStart],[a.xEnd,a.yEnd]];if("spline"===a.smooth){var c=b[1][0],e=b[1][1];if(.8>=a.smoothRadian){b[3]=[c,e];var d=b[0][0]<=b[3][0];b[1]=this.getOffetPoint(b[0],b[3],d,a.smoothRadian);b[2]=this.getOffetPoint(b[3],b[0],d,a.smoothRadian)}else b[2]=[c,e],b[1]=this.getOffetPoint(b[0],b[2],b[0][0]<=b[2][0],a.smoothRadian);b=r(b,!1);b[b.length-1]=[c,e]}return b},getOffetPoint:function(a,b,c,e){var d,f=Math.sqrt(Math.round((a[0]-b[0])*(a[0]-b[0])+(a[1]-b[1])*(a[1]-b[1])))/((2-Math.abs(e))/.6),m=[a[0],a[1]];d=a[0]!=b[0]&&a[1]!=b[1]?Math.atan((b[1]-a[1])/(b[0]-a[0])):a[0]==b[0]?(a[1]<=b[1]?1:-1)*Math.PI/2:0;var g,l;return a[0]<=b[0]?(d-=e*(c?1:-1),g=Math.round(Math.cos(d)*f),l=Math.round(Math.sin(d)*f),m[0]+=g,m[1]+=l):(d+=e*(c?1:-1),g=Math.round(Math.cos(d)*f),l=Math.round(Math.sin(d)*f),m[0]-=g,m[1]-=l),m},getRect:function(a){if(a.__rect)return a.__rect;var b=a.lineWidth||1;return a.__rect={x:Math.min(a.xStart,a.xEnd)-b,y:Math.min(a.yStart,a.yEnd)-b,width:Math.abs(a.xStart-a.xEnd)+b,height:Math.abs(a.yStart-a.yEnd)+b},a.__rect},isCover:function(a,f){var c=this.getTansform(a,f);a=c[0];f=c[1];c=this.style.__rect;return c||(c=this.style.__rect=this.getRect(this.style)),a>=c.x&&a<=c.x+c.width&&f>=c.y&&f<=c.y+c.height?"spline"!==this.style.smooth?e.isInside(d,this.style,a,f):e.isInside(b,this.style,a,f):!1}},g.inherits(f,q),f});define("echarts/util/shape/Symbol",["require","zrender/shape/Base","zrender/shape/Polygon","zrender/tool/util","./normalIsCover"],function(g){function f(b){q.call(this,b)}var q=g("zrender/shape/Base"),l=new (g("zrender/shape/Polygon"))({}),d=g("zrender/tool/util");return f.prototype={type:"symbol",buildPath:function(b,a){var e=a.pointList,d=e.length;if(0!==d)for(var f,g,l,c,t,n=Math.ceil(d/1E4),h=e[0]instanceof Array,q=a.size?a.size:2,B=q,z=q/2,I=2*Math.PI,H=0;n>H;H++){b.beginPath();f=1E4*H;g=f+1E4;for(g=g>d?d:g;g>f;f++)if(a.random&&(l=a["randomMap"+f%20]/100,B=q*l*l,z=B/2),h?(c=e[f][0],t=e[f][1]):(c=e[f].x,t=e[f].y),3>B)b.rect(c-z,t-z,B,B);else switch(a.iconType){case "circle":b.moveTo(c,t);b.arc(c,t,z,0,I,!0);break;case "diamond":b.moveTo(c,t-z);b.lineTo(c+z/3,t-z/3);b.lineTo(c+z,t);b.lineTo(c+z/3,t+z/3);b.lineTo(c,t+z);b.lineTo(c-z/3,t+z/3);b.lineTo(c-z,t);b.lineTo(c-z/3,t-z/3);b.lineTo(c,t-z);break;default:b.rect(c-z,t-z,B,B)}if(b.closePath(),n-1>H)switch(a.brushType){case "both":b.fill();0<a.lineWidth&&b.stroke();break;case "stroke":0<a.lineWidth&&b.stroke();break;default:b.fill()}}},getRect:function(b){return b.__rect||l.getRect(b)},isCover:g("./normalIsCover")},d.inherits(f,q),f});define("echarts/util/ecAnimation",["require","zrender/tool/util","zrender/shape/Polygon"],function(g){function f(d,b){for(var a=arguments.length,e=2;a>e;e++){var f=arguments[e];d.style[f]=b.style[f]}}function q(d,b,a,e,m){var g=a.style;b||(b={position:a.position,style:{x:g.x,y:"vertical"==a._orient?g.y+g.height:g.y,width:"vertical"==a._orient?g.width:0,height:"vertical"!=a._orient?g.height:0}});var k=g.x,l=g.y,c=g.width,g=g.height,t=[a.position[0],a.position[1]];f(a,b,"x","y","width","height");a.position=b.position;d.addShape(a);t[0]==b.position[0]&&t[1]==b.position[1]||d.animate(a.id,"").when(e,{position:t}).start(m);d.animate(a.id,"style").when(e,{x:k,y:l,width:c,height:g}).start(m)}var l=g("zrender/tool/util");return{pointList:function(d,b,a,e,f){var g=a.style.pointList,k=g.length;if(!b){if(b=[],"vertical"!=a._orient)for(var p=g[0][1],c=0;k>c;c++)b[c]=[g[c][0],p];else for(p=g[0][0],c=0;k>c;c++)b[c]=[p,g[c][1]];"half-smooth-polygon"==a.type&&(b[k-1]=l.clone(g[k-1]),b[k-2]=l.clone(g[k-2]));b={style:{pointList:b}}}b=b.style.pointList;c=b.length;a.style.pointList=c==k?b:k>c?b.concat(g.slice(c)):b.slice(0,k);d.addShape(a);d.animate(a.id,"style").when(e,{pointList:g}).start(f)},rectangle:q,candle:function(d,b,a,e,f){b||(b=a.style.y,b={style:{y:[b[0],b[0],b[0],b[0]]}});var g=a.style.y;a.style.y=b.style.y;d.addShape(a);d.animate(a.id,"style").when(e,{y:g}).start(f)},ring:function(d,b,a,e,f){b=a.style.x;var g=a.style.y,k=a.style.r0,l=a.style.r;"r"!=a._animationAdd?(a.style.r0=0,a.style.r=0,a.rotation=[2*Math.PI,b,g],d.addShape(a),d.animate(a.id,"style").when(e,{r0:k,r:l}).start(f),d.animate(a.id,"").when(Math.round(e/3*2),{rotation:[0,b,g]}).start(f)):(a.style.r0=a.style.r,d.addShape(a),d.animate(a.id,"style").when(e,{r0:k}).start(f))},sector:function(d,b,a,e,m){b||(b="r"!=a._animationAdd?{style:{startAngle:a.style.startAngle,endAngle:a.style.startAngle}}:{style:{r0:a.style.r}});var g=a.style.startAngle,k=a.style.endAngle;f(a,b,"startAngle","endAngle");d.addShape(a);d.animate(a.id,"style").when(e,{startAngle:g,endAngle:k}).start(m)},text:function(d,b,a,e,m){b||(b={style:{x:"left"==a.style.textAlign?a.style.x+100:a.style.x-100,y:a.style.y}});var g=a.style.x,k=a.style.y;f(a,b,"x","y");d.addShape(a);d.animate(a.id,"style").when(e,{x:g,y:k}).start(m)},polygon:function(d,b,a,e,f){var l=g("zrender/shape/Polygon").prototype.getRect(a.style);b=l.x+l.width/2;l=l.y+l.height/2;a.scale=[.1,.1,b,l];d.addShape(a);d.animate(a.id,"").when(e,{scale:[1,1,b,l]}).start(f)},ribbon:function(d,b,a,e,m){b||(b={style:{source0:0,source1:0<a.style.source1?360:-360,target0:0,target1:0<a.style.target1?360:-360}});var g=a.style.source0,k=a.style.source1,l=a.style.target0,c=a.style.target1;b.style&&f(a,b,"source0","source1","target0","target1");d.addShape(a);d.animate(a.id,"style").when(e,{source0:g,source1:k,target0:l,target1:c}).start(m)},gaugePointer:function(d,b,a,e,f){b||(b={style:{angle:a.style.startAngle}});var g=a.style.angle;a.style.angle=b.style.angle;d.addShape(a);d.animate(a.id,"style").when(e,{angle:g}).start(f)},icon:function(d,b,a,e,f,g){if(a.style._x=a.style.x,a.style._y=a.style.y,a.style._width=a.style.width,a.style._height=a.style.height,b)q(d,b,a,e,f);else{b=a._x||0;var k=a._y||0;a.scale=[.01,.01,b,k];d.addShape(a);d.animate(a.id,"").delay(g).when(e,{scale:[1,1,b,k]}).start(f||"QuinticOut")}},line:function(d,b,a,e,g){b||(b={style:{xStart:a.style.xStart,yStart:a.style.yStart,xEnd:a.style.xStart,yEnd:a.style.yStart}});var l=a.style.xStart,k=a.style.xEnd,p=a.style.yStart,c=a.style.yEnd;f(a,b,"xStart","xEnd","yStart","yEnd");d.addShape(a);d.animate(a.id,"style").when(e,{xStart:l,xEnd:k,yStart:p,yEnd:c}).start(g)},markline:function(d,b,a,e,f){a.style.smooth?b?d.addShape(a):(a.style.pointListLength=1,d.addShape(a),a.style.pointList=a.style.pointList||a.getPointList(a.style),d.animate(a.id,"style").when(e,{pointListLength:a.style.pointList.length}).start(f||"QuinticOut")):(a.style.pointList=b?b.style.pointList:[[a.style.xStart,a.style.yStart],[a.style.xStart,a.style.yStart]],d.addShape(a),d.animate(a.id,"style").when(e,{pointList:[[a.style.xStart,a.style.yStart],[a._x||0,a._y||0]]}).start(f||"QuinticOut"))}}});define("echarts/util/ecEffect","require ../util/ecData zrender/shape/Circle zrender/shape/Image ../util/shape/Icon ../util/shape/Symbol".split(" "),function(g){var f=g("../util/ecData"),q=g("zrender/shape/Circle"),l=g("zrender/shape/Image"),d=g("../util/shape/Icon"),b=g("../util/shape/Symbol");return{point:function(a,b,g,r){var k,p=g.effect,c=p.color||g.style.strokeColor||g.style.color,t=p.shadowColor||c,n=p.scaleSize,h=p.bounceDistance,q="undefined"!=typeof p.shadowBlur?p.shadowBlur:n;"image"!==g.type?(k=new d({zlevel:r,style:{brushType:"stroke",iconType:"droplet"!=g.style.iconType?g.style.iconType:"circle",x:q+1,y:q+1,n:g.style.n,width:g.style._width*n,height:g.style._height*n,lineWidth:1,strokeColor:c,shadowColor:t,shadowBlur:q},draggable:!1,hoverable:!1}),"pin"==g.style.iconType&&(k.style.y+=k.style.height/2*1.5),k.style.image=a.shapeToImage(k,k.style.width+2*q+2,k.style.height+2*q+2).style.image,k=new l({zlevel:k.zlevel,style:k.style,draggable:!1,hoverable:!1})):k=new l({zlevel:r,style:g.style,draggable:!1,hoverable:!1});f.clone(g,k);k.position=g.position;b.push(k);a.addShape(k);b="image"!==g.type?window.devicePixelRatio||1:1;r=(k.style.width/b-g.style._width)/2;k.style.x=g.style._x-r;k.style.y=g.style._y-r;"pin"==g.style.iconType&&(k.style.y-=g.style.height/2*1.5);r=100*(p.period+10*Math.random());a.modShape(g.id,{invisible:!0});c=k.style.x+k.style.width/2/b;b=k.style.y+k.style.height/2/b;"scale"===p.type?(a.modShape(k.id,{scale:[.1,.1,c,b]}),a.animate(k.id,"",p.loop).when(r,{scale:[1,1,c,b]}).done(function(){g.effect.show=!1;a.delShape(k.id)}).start()):a.animate(k.id,"style",p.loop).when(r,{y:k.style.y-h}).when(2*r,{y:k.style.y}).done(function(){g.effect.show=!1;a.delShape(k.id)}).start()},largePoint:function(a,e,d,f){var g=d.effect,l=g.color||d.style.strokeColor||d.style.color,c=g.scaleSize;f=new b({zlevel:f,position:d.position,scale:d.scale,style:{pointList:d.style.pointList,iconType:d.style.iconType,color:l,strokeColor:l,shadowColor:g.shadowColor||l,shadowBlur:("undefined"!=typeof g.shadowBlur?g.shadowBlur:2*c)*(window.devicePixelRatio||1),random:!0,brushType:"fill",lineWidth:1,size:d.style.size},draggable:!1,hoverable:!1});e.push(f);a.addShape(f);a.modShape(d.id,{invisible:!0});e=Math.round(100*g.period);for(l=0;20>l;l++)f.style["randomMap"+l]=0,d={},d["randomMap"+l]=100,g={},g["randomMap"+l]=0,f.style["randomMap"+l]=100*Math.random(),a.animate(f.id,"style",!0).when(e,d).when(2*e,g).when(3*e,d).when(4*e,d).delay(Math.random()*e*l).start()},line:function(a,b,d,g){var k=d.effect,p=k.color||d.style.strokeColor||d.style.color,c=d.style.lineWidth*k.scaleSize,t="undefined"!=typeof k.shadowBlur?k.shadowBlur:c,n=new q({zlevel:g,style:{x:t,y:t,r:c,color:p,shadowColor:k.shadowColor||d.style.strokeColor||p,shadowBlur:t},draggable:!1,hoverable:!1});n.style.image=a.shapeToImage(n,2*(c+t),2*(c+t)).style.image;n=new l({zlevel:n.zlevel,style:n.style,draggable:!1,hoverable:!1});f.clone(d,n);n.position=d.position;b.push(n);a.addShape(n);n.style.x=d.style.xStart-t;n.style.y=d.style.yStart-t;b=Math.round(Math.sqrt(Math.round(((d.style.xStart-d.style.xEnd)*(d.style.xStart-d.style.xEnd)+(d.style.yStart-d.style.yEnd)*(d.style.yStart-d.style.yEnd))*k.period*k.period)));if(d.style.smooth){g=d.style.pointList||d.getPointList(d.style);p=g.length;b=Math.round(b/p);for(var k=a.animate(n.id,"style",k.loop),c=Math.ceil(p/8),h=0;p-c>h;h+=c)k.when(b*(h+1),{x:g[h][0]-t,y:g[h][1]-t});k.when(b*p,{x:g[p-1][0]-t,y:g[p-1][1]-t});k.done(function(){d.effect.show=!1;a.delShape(n.id)});k.start("spline")}else a.animate(n.id,"style",k.loop).when(b,{x:d._x-t,y:d._y-t}).done(function(){d.effect.show=!1;a.delShape(n.id)}).start()}}});define("echarts/component/base",["require","../config","../util/ecQuery","../util/number","zrender/tool/util"],function(g){function f(a,b,d,f,g){this.ecTheme=a;this.messageCenter=b;this.zr=d;this.option=f;this.series=f.series;this.myChart=g;this.component=g.component;this.shapeList=[];this.effectList=[]}var q=g("../config"),l=g("../util/ecQuery"),d=g("../util/number"),b=g("zrender/tool/util");return f.prototype={canvasSupported:!0,_getZ:function(a){var b=this.ecTheme[this.type];return b&&null!=b[a]?b[a]:(b=q[this.type],b&&null!=b[a]?b[a]:0)},getZlevelBase:function(){return this._getZ("zlevel")},getZBase:function(){return this._getZ("z")},reformOption:function(a){return b.merge(b.merge(a||{},b.clone(this.ecTheme[this.type]||{})),b.clone(q[this.type]||{}))},reformCssArray:function(a){if(!(a instanceof Array))return[a,a,a,a];switch(a.length+""){case "4":return a;case "3":return[a[0],a[1],a[2],a[1]];case "2":return[a[0],a[1],a[0],a[1]];case "1":return[a[0],a[0],a[0],a[0]];case "0":return[0,0,0,0]}},getShapeById:function(a){for(var b=0,d=this.shapeList.length;d>b;b++)if(this.shapeList[b].id===a)return this.shapeList[b];return null},getFont:function(a){a=this.getTextStyle(b.clone(a));return a.fontStyle+" "+a.fontWeight+" "+a.fontSize+"px "+a.fontFamily},getTextStyle:function(a){return b.merge(b.merge(a||{},this.ecTheme.textStyle),q.textStyle)},getItemStyleColor:function(a,b,d,f){return"function"==typeof a?a.call(this.myChart,{seriesIndex:b,series:this.series[b],dataIndex:d,data:f}):a},getDataFromOption:function(a,b){return null!=a?null!=a.value?a.value:a:b},subPixelOptimize:function(a,b){return 1===b%2?Math.floor(a)+.5:Math.round(a)},resize:function(){this.refresh&&this.refresh();this.clearEffectShape&&this.clearEffectShape(!0);var a=this;setTimeout(function(){a.animationEffect&&a.animationEffect()},200)},clear:function(){this.clearEffectShape&&this.clearEffectShape();this.zr&&this.zr.delShape(this.shapeList);this.shapeList=[]},dispose:function(){this.onbeforDispose&&this.onbeforDispose();this.clear();this.effectList=this.shapeList=null;this.onafterDispose&&this.onafterDispose()},query:l.query,deepQuery:l.deepQuery,deepMerge:l.deepMerge,parsePercent:d.parsePercent,parseCenter:d.parseCenter,parseRadius:d.parseRadius,numAddCommas:d.addCommas},f});define("zrender/shape/Star",["require","../tool/math","./Base","../tool/util"],function(g){var f=g("../tool/math"),q=f.sin,l=f.cos,d=Math.PI,b=g("./Base"),f=function(a){b.call(this,a)};return f.prototype={type:"star",buildPath:function(a,b){var f=b.n;if(f&&!(2>f)){var g=b.x,k=b.y,p=b.r,c=b.r0;null==c&&(c=4<f?p*l(2*d/f)/l(d/f):p/3);var t=d/f,n=-d/2,h=g+p*l(n),u=k+p*q(n),n=n+t,B=b.pointList=[];B.push([h,u]);for(var z=0,I=2*f-1;I>z;z++)f=0===z%2?c:p,B.push([g+f*l(n),k+f*q(n)]),n+=t;B.push([h,u]);a.moveTo(B[0][0],B[0][1]);for(z=0;z<B.length;z++)a.lineTo(B[z][0],B[z][1]);a.closePath()}},getRect:function(a){if(a.__rect)return a.__rect;var b;return b="stroke"==a.brushType||"fill"==a.brushType?a.lineWidth||1:0,a.__rect={x:Math.round(a.x-a.r-b/2),y:Math.round(a.y-a.r-b/2),width:2*a.r+b,height:2*a.r+b},a.__rect}},g("../tool/util").inherits(f,b),f});define("zrender/shape/Heart",["require","./Base","./util/PathProxy","../tool/util"],function(g){var f=g("./Base"),q=g("./util/PathProxy"),l=function(d){f.call(this,d);this._pathProxy=new q};return l.prototype={type:"heart",buildPath:function(d,b){var a=this._pathProxy||new q;a.begin(d);a.moveTo(b.x,b.y);a.bezierCurveTo(b.x+b.a/2,b.y-2*b.b/3,b.x+2*b.a,b.y+b.b/3,b.x,b.y+b.b);a.bezierCurveTo(b.x-2*b.a,b.y+b.b/3,b.x-b.a/2,b.y-2*b.b/3,b.x,b.y);a.closePath()},getRect:function(d){return d.__rect?d.__rect:(this._pathProxy.isEmpty()||this.buildPath(null,d),this._pathProxy.fastBoundingRect())}},g("../tool/util").inherits(l,f),l});define("zrender/shape/Droplet",["require","./Base","./util/PathProxy","../tool/util"],function(g){var f=g("./Base"),q=g("./util/PathProxy"),l=function(d){f.call(this,d);this._pathProxy=new q};return l.prototype={type:"droplet",buildPath:function(d,b){var a=this._pathProxy||new q;a.begin(d);a.moveTo(b.x,b.y+b.a);a.bezierCurveTo(b.x+b.a,b.y+b.a,b.x+3*b.a/2,b.y-b.a/3,b.x,b.y-b.b);a.bezierCurveTo(b.x-3*b.a/2,b.y-b.a/3,b.x-b.a,b.y+b.a,b.x,b.y+b.a);a.closePath()},getRect:function(d){return d.__rect?d.__rect:(this._pathProxy.isEmpty()||this.buildPath(null,d),this._pathProxy.fastBoundingRect())}},g("../tool/util").inherits(l,f),l});define("zrender/tool/math",[],function(){var g=Math.PI/180;return{sin:function(f,q){return Math.sin(q?f*g:f)},cos:function(f,q){return Math.cos(q?f*g:f)},degreeToRadian:function(f){return f*g},radianToDegree:function(f){return f/g}}});define("zrender/shape/util/PathProxy",["require","../../tool/vector"],function(g){var f=g("../../tool/vector"),q=function(f,d){this.command=f;this.points=d||null};g=function(){this.pathCommands=[];this._ctx=null;this._min=[];this._max=[]};return g.prototype.fastBoundingRect=function(){var g=this._min,d=this._max;g[0]=g[1]=1/0;d[0]=d[1]=-1/0;for(var b=0;b<this.pathCommands.length;b++){var a=this.pathCommands[b],e=a.points;switch(a.command){case "M":f.min(g,g,e);f.max(d,d,e);break;case "L":f.min(g,g,e);f.max(d,d,e);break;case "C":for(a=0;6>a;a+=2)g[0]=Math.min(g[0],g[0],e[a]),g[1]=Math.min(g[1],g[1],e[a+1]),d[0]=Math.max(d[0],d[0],e[a]),d[1]=Math.max(d[1],d[1],e[a+1]);break;case "Q":for(a=0;4>a;a+=2)g[0]=Math.min(g[0],g[0],e[a]),g[1]=Math.min(g[1],g[1],e[a+1]),d[0]=Math.max(d[0],d[0],e[a]),d[1]=Math.max(d[1],d[1],e[a+1]);break;case "A":var a=e[0],m=e[1],r=e[2],e=e[3];g[0]=Math.min(g[0],g[0],a-r);g[1]=Math.min(g[1],g[1],m-e);d[0]=Math.max(d[0],d[0],a+r);d[1]=Math.max(d[1],d[1],m+e)}}return{x:g[0],y:g[1],width:d[0]-g[0],height:d[1]-g[1]}},g.prototype.begin=function(f){return this._ctx=f||null,this.pathCommands.length=0,this},g.prototype.moveTo=function(f,d){return this.pathCommands.push(new q("M",[f,d])),this._ctx&&this._ctx.moveTo(f,d),this},g.prototype.lineTo=function(f,d){return this.pathCommands.push(new q("L",[f,d])),this._ctx&&this._ctx.lineTo(f,d),this},g.prototype.bezierCurveTo=function(f,d,b,a,e,g){return this.pathCommands.push(new q("C",[f,d,b,a,e,g])),this._ctx&&this._ctx.bezierCurveTo(f,d,b,a,e,g),this},g.prototype.quadraticCurveTo=function(f,d,b,a){return this.pathCommands.push(new q("Q",[f,d,b,a])),this._ctx&&this._ctx.quadraticCurveTo(f,d,b,a),this},g.prototype.arc=function(f,d,b,a,e,g){return this.pathCommands.push(new q("A",[f,d,b,b,a,e-a,0,g?0:1])),this._ctx&&this._ctx.arc(f,d,b,a,e,g),this},g.prototype.arcTo=function(f,d,b,a,e){return this._ctx&&this._ctx.arcTo(f,d,b,a,e),this},g.prototype.rect=function(f,d,b,a){return this._ctx&&this._ctx.rect(f,d,b,a),this},g.prototype.closePath=function(){return this.pathCommands.push(new q("z")),this._ctx&&this._ctx.closePath(),this},g.prototype.isEmpty=function(){return 0===this.pathCommands.length},g.PathSegment=q,g});define("zrender/shape/Line",["require","./Base","./util/dashedLineTo","../tool/util"],function(g){var f=g("./Base"),q=g("./util/dashedLineTo"),l=function(d){this.brushTypeOnly="stroke";this.textPosition="end";f.call(this,d)};return l.prototype={type:"line",buildPath:function(d,b){b.lineType&&"solid"!=b.lineType?"dashed"!=b.lineType&&"dotted"!=b.lineType||q(d,b.xStart,b.yStart,b.xEnd,b.yEnd,(b.lineWidth||1)*("dashed"==b.lineType?5:1)):(d.moveTo(b.xStart,b.yStart),d.lineTo(b.xEnd,b.yEnd))},getRect:function(d){if(d.__rect)return d.__rect;var b=d.lineWidth||1;return d.__rect={x:Math.min(d.xStart,d.xEnd)-b,y:Math.min(d.yStart,d.yEnd)-b,width:Math.abs(d.xStart-d.xEnd)+b,height:Math.abs(d.yStart-d.yEnd)+b},d.__rect}},g("../tool/util").inherits(l,f),l});define("zrender/shape/Polyline","require ./Base ./util/smoothSpline ./util/smoothBezier ./util/dashedLineTo ./Polygon ../tool/util".split(" "),function(g){var f=g("./Base"),q=g("./util/smoothSpline"),l=g("./util/smoothBezier"),d=g("./util/dashedLineTo"),b=function(a){this.brushTypeOnly="stroke";this.textPosition="end";f.call(this,a)};return b.prototype={type:"polyline",buildPath:function(a,b){var f=b.pointList;if(!(2>f.length)){var g=Math.min(b.pointList.length,Math.round(b.pointListLength||b.pointList.length));if(b.smooth&&"spline"!==b.smooth){var k=l(f,b.smooth,!1,b.smoothConstraint);a.moveTo(f[0][0],f[0][1]);for(var p,c,t,n=0;g-1>n;n++)p=k[2*n],c=k[2*n+1],t=f[n+1],a.bezierCurveTo(p[0],p[1],c[0],c[1],t[0],t[1])}else if("spline"===b.smooth&&(f=q(f),g=f.length),b.lineType&&"solid"!=b.lineType){if("dashed"==b.lineType||"dotted"==b.lineType)for(k=(b.lineWidth||1)*("dashed"==b.lineType?5:1),a.moveTo(f[0][0],f[0][1]),n=1;g>n;n++)d(a,f[n-1][0],f[n-1][1],f[n][0],f[n][1],k)}else for(a.moveTo(f[0][0],f[0][1]),n=1;g>n;n++)a.lineTo(f[n][0],f[n][1])}},getRect:function(a){return g("./Polygon").prototype.getRect(a)}},g("../tool/util").inherits(b,f),b});define("zrender/shape/util/dashedLineTo",[],function(){var g=[5,5];return function(f,q,l,d,b,a){if(f.setLineDash)return g[0]=g[1]=a,f.setLineDash(g),f.moveTo(q,l),void f.lineTo(d,b);var e=d-q,m=b-l;a=Math.floor(Math.sqrt(e*e+m*m)/("number"!=typeof a?5:a));for(var e=e/a,m=m/a,r=!0,k=0;a>k;++k)r?f.moveTo(q,l):f.lineTo(q,l),r=!r,q+=e,l+=m;f.lineTo(d,b)}});define("zrender/shape/util/smoothSpline",["require","../../tool/vector"],function(g){function f(f,d,b,a,e,g,r){f=.5*(b-f);a=.5*(a-d);return(2*(d-b)+f+a)*r+(-3*(d-b)-2*f-a)*g+f*e+d}var q=g("../../tool/vector");return function(g,d){for(var b=g.length,a=[],e=0,m=1;b>m;m++)e+=q.distance(g[m-1],g[m]);e/=5;e=b>e?b:e;for(m=0;e>m;m++){var r,k,p,c=m/(e-1)*(d?b:b-1),t=Math.floor(c),c=c-t,n=g[t%b];d?(r=g[(t-1+b)%b],k=g[(t+1)%b],p=g[(t+2)%b]):(r=g[0===t?t:t-1],k=g[t>b-2?b-1:t+1],p=g[t>b-3?b-1:t+2]);var t=c*c,h=c*t;a.push([f(r[0],n[0],k[0],p[0],c,t,h),f(r[1],n[1],k[1],p[1],c,t,h)])}return a}});define("zrender/shape/util/smoothBezier",["require","../../tool/vector"],function(g){var f=g("../../tool/vector");return function(g,l,d,b){var a,e,m,r,k=[],p=[],c=[],t=[],n=!!b;if(n){m=[1/0,1/0];r=[-1/0,-1/0];for(var h=0,u=g.length;u>h;h++)f.min(m,m,g[h]),f.max(r,r,g[h]);f.min(m,m,b[0]);f.max(r,r,b[1])}h=0;for(u=g.length;u>h;h++){b=g[h];if(d)a=g[h?h-1:u-1],e=g[(h+1)%u];else{if(0===h||h===u-1){k.push(g[h]);continue}a=g[h-1];e=g[h+1]}f.sub(p,e,a);f.scale(p,p,l);a=f.distance(b,a);e=f.distance(b,e);var B=a+e;0!==B&&(a/=B,e/=B);f.scale(c,p,-a);f.scale(t,p,e);a=f.add([],b,c);b=f.add([],b,t);n&&(f.max(a,a,m),f.min(a,a,r),f.max(b,b,m),f.min(b,b,r));k.push(a);k.push(b)}return d&&k.push(k.shift()),k}});define("zrender/shape/Polygon","require ./Base ./util/smoothSpline ./util/smoothBezier ./util/dashedLineTo ../tool/util".split(" "),function(g){var f=g("./Base"),q=g("./util/smoothSpline"),l=g("./util/smoothBezier"),d=g("./util/dashedLineTo"),b=function(a){f.call(this,a)};return b.prototype={type:"polygon",buildPath:function(a,b){var f=b.pointList;if(!(2>f.length)){if(b.smooth&&"spline"!==b.smooth){var g=l(f,b.smooth,!0,b.smoothConstraint);a.moveTo(f[0][0],f[0][1]);for(var k,p,c,t=f.length,n=0;t>n;n++)k=g[2*n],p=g[2*n+1],c=f[(n+1)%t],a.bezierCurveTo(k[0],k[1],p[0],p[1],c[0],c[1])}else if("spline"===b.smooth&&(f=q(f,!0)),b.lineType&&"solid"!=b.lineType){if("dashed"==b.lineType||"dotted"==b.lineType){g=b._dashLength||(b.lineWidth||1)*("dashed"==b.lineType?5:1);b._dashLength=g;a.moveTo(f[0][0],f[0][1]);n=1;for(k=f.length;k>n;n++)d(a,f[n-1][0],f[n-1][1],f[n][0],f[n][1],g);d(a,f[f.length-1][0],f[f.length-1][1],f[0][0],f[0][1],g)}}else{a.moveTo(f[0][0],f[0][1]);n=1;for(k=f.length;k>n;n++)a.lineTo(f[n][0],f[n][1]);a.lineTo(f[0][0],f[0][1])}a.closePath()}},getRect:function(a){if(a.__rect)return a.__rect;for(var b=Number.MAX_VALUE,d=Number.MIN_VALUE,f=Number.MAX_VALUE,g=Number.MIN_VALUE,l=a.pointList,c=0,t=l.length;t>c;c++)l[c][0]<b&&(b=l[c][0]),l[c][0]>d&&(d=l[c][0]),l[c][1]<f&&(f=l[c][1]),l[c][1]>g&&(g=l[c][1]);var n;return n="stroke"==a.brushType||"fill"==a.brushType?a.lineWidth||1:0,a.__rect={x:Math.round(b-n/2),y:Math.round(f-n/2),width:d-b+n,height:g-f+n},a.__rect}},g("../tool/util").inherits(b,f),b});define("echarts/util/shape/normalIsCover",[],function(){return function(g,f){var q=this.getTansform(g,f);g=q[0];f=q[1];q=this.style.__rect;return q||(q=this.style.__rect=this.getRect(this.style)),g>=q.x&&g<=q.x+q.width&&f>=q.y&&f<=q.y+q.height}});define("echarts/util/ecQuery",["require","zrender/tool/util"],function(g){function f(f,d){if("undefined"!=typeof f){if(!d)return f;d=d.split(".");for(var b=d.length,a=0;b>a;){if(f=f[d[a]],"undefined"==typeof f)return;a++}return f}}var q=g("zrender/tool/util");return{query:f,deepQuery:function(g,d){for(var b,a=0,e=g.length;e>a;a++)if(b=f(g[a],d),"undefined"!=typeof b)return b},deepMerge:function(g,d){for(var b,a=g.length;a--;){var e=f(g[a],d);"undefined"!=typeof e&&("undefined"==typeof b?b=q.clone(e):q.merge(b,e,!0))}return b}}});define("echarts/util/number",[],function(){function g(f,g){return"string"==typeof f?f.replace(/^\s+/,"").replace(/\s+$/,"").match(/%$/)?parseFloat(f)/100*g:parseFloat(f):f}return{parsePercent:g,parseCenter:function(f,q){return[g(q[0],f.getWidth()),g(q[1],f.getHeight())]},parseRadius:function(f,q){q instanceof Array||(q=[0,q]);var l=Math.min(f.getWidth(),f.getHeight())/2;return[g(q[0],l),g(q[1],l)]},addCommas:function(f){return isNaN(f)?"-":(f=(f+"").split("."),f[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(1<f.length?"."+f[1]:""))}}});define("echarts/util/shape/Cross",["require","zrender/shape/Base","zrender/shape/Line","zrender/tool/util","./normalIsCover"],function(g){function f(b){q.call(this,b)}var q=g("zrender/shape/Base"),l=g("zrender/shape/Line"),d=g("zrender/tool/util");return f.prototype={type:"cross",buildPath:function(b,a){var d=a.rect;a.xStart=d.x;a.xEnd=d.x+d.width;a.yStart=a.yEnd=a.y;l.prototype.buildPath(b,a);a.xStart=a.xEnd=a.x;a.yStart=d.y;a.yEnd=d.y+d.height;l.prototype.buildPath(b,a)},getRect:function(b){return b.rect},isCover:g("./normalIsCover")},d.inherits(f,q),f});define("zrender/shape/Sector","require ../tool/math ../tool/computeBoundingBox ../tool/vector ./Base ../tool/util".split(" "),function(g){var f=g("../tool/math"),q=g("../tool/computeBoundingBox"),l=g("../tool/vector"),d=g("./Base"),b=l.create(),a=l.create(),e=l.create(),m=l.create(),r=function(a){d.call(this,a)};return r.prototype={type:"sector",buildPath:function(a,b){var c=b.x,d=b.y,e=b.r0||0,h=b.r,g=b.startAngle,m=b.endAngle,l=b.clockWise||!1,g=f.degreeToRadian(g),m=f.degreeToRadian(m);l||(g=-g,m=-m);var r=f.cos(g),q=f.sin(g);a.moveTo(r*e+c,q*e+d);a.lineTo(r*h+c,q*h+d);a.arc(c,d,h,g,m,!l);a.lineTo(f.cos(m)*e+c,f.sin(m)*e+d);0!==e&&a.arc(c,d,e,m,g,l);a.closePath()},getRect:function(d){if(d.__rect)return d.__rect;var g=d.x,c=d.y,r=d.r0||0,n=d.r,h=f.degreeToRadian(d.startAngle),u=f.degreeToRadian(d.endAngle),B=d.clockWise;return B||(h=-h,u=-u),1<r?q.arc(g,c,r,h,u,!B,b,e):(b[0]=e[0]=g,b[1]=e[1]=c),q.arc(g,c,n,h,u,!B,a,m),l.min(b,b,a),l.max(e,e,m),d.__rect={x:b[0],y:b[1],width:e[0]-b[0],height:e[1]-b[1]},d.__rect}},g("../tool/util").inherits(r,d),r});define("echarts/util/shape/Candle",["require","zrender/shape/Base","zrender/tool/util","./normalIsCover"],function(g){function f(d){q.call(this,d)}var q=g("zrender/shape/Base"),l=g("zrender/tool/util");return f.prototype={type:"candle",_numberOrder:function(d,b){return b-d},buildPath:function(d,b){var a=l.clone(b.y).sort(this._numberOrder);d.moveTo(b.x,a[3]);d.lineTo(b.x,a[2]);d.moveTo(b.x-b.width/2,a[2]);d.rect(b.x-b.width/2,a[2],b.width,a[1]-a[2]);d.moveTo(b.x,a[1]);d.lineTo(b.x,a[0])},getRect:function(d){if(!d.__rect){var b=0;"stroke"!=d.brushType&&"fill"!=d.brushType||(b=d.lineWidth||1);var a=l.clone(d.y).sort(this._numberOrder);d.__rect={x:Math.round(d.x-d.width/2-b/2),y:Math.round(a[3]-b/2),width:d.width+b,height:a[0]-a[3]+b}}return d.__rect},isCover:g("./normalIsCover")},l.inherits(f,q),f});define("zrender/tool/computeBoundingBox",["require","./vector","./curve"],function(g){function f(a,b,d){if(0!==a.length){for(var f=a[0][0],g=a[0][0],c=a[0][1],l=a[0][1],n=1;n<a.length;n++){var h=a[n];h[0]<f&&(f=h[0]);h[0]>g&&(g=h[0]);h[1]<c&&(c=h[1]);h[1]>l&&(l=h[1])}b[0]=f;b[1]=c;d[0]=g;d[1]=l}}var q=g("./vector"),l=g("./curve"),d=q.create(),b=q.create(),a=q.create();return f.cubeBezier=function(a,b,d,f,g,c){var q=[];l.cubicExtrema(a[0],b[0],d[0],f[0],q);for(var n=0;n<q.length;n++)q[n]=l.cubicAt(a[0],b[0],d[0],f[0],q[n]);var h=[];l.cubicExtrema(a[1],b[1],d[1],f[1],h);for(n=0;n<h.length;n++)h[n]=l.cubicAt(a[1],b[1],d[1],f[1],h[n]);q.push(a[0],f[0]);h.push(a[1],f[1]);a=Math.min.apply(null,q);q=Math.max.apply(null,q);b=Math.min.apply(null,h);h=Math.max.apply(null,h);g[0]=a;g[1]=b;c[0]=q;c[1]=h},f.quadraticBezier=function(a,b,d,f,g){var c=l.quadraticExtremum(a[0],b[0],d[0]),q=l.quadraticExtremum(a[1],b[1],d[1]),c=Math.max(Math.min(c,1),0),q=Math.max(Math.min(q,1),0),n=1-c,h=1-q,u=n*n*a[0]+2*n*c*b[0]+c*c*d[0],c=n*n*a[1]+2*n*c*b[1]+c*c*d[1],n=h*h*a[0]+2*h*q*b[0]+q*q*d[0];b=h*h*a[1]+2*h*q*b[1]+q*q*d[1];f[0]=Math.min(a[0],d[0],u,n);f[1]=Math.min(a[1],d[1],c,b);g[0]=Math.max(a[0],d[0],u,n);g[1]=Math.max(a[1],d[1],c,b)},f.arc=function(e,f,g,k,l,c,t,n){if(Math.abs(k-l)>=2*Math.PI)return t[0]=e-g,t[1]=f-g,n[0]=e+g,void(n[1]=f+g);if(d[0]=Math.cos(k)*g+e,d[1]=Math.sin(k)*g+f,b[0]=Math.cos(l)*g+e,b[1]=Math.sin(l)*g+f,q.min(t,d,b),q.max(n,d,b),k%=2*Math.PI,0>k&&(k+=2*Math.PI),l%=2*Math.PI,0>l&&(l+=2*Math.PI),k>l&&!c?l+=2*Math.PI:l>k&&c&&(k+=2*Math.PI),c)k=l=k;for(c=0;l>c;c+=Math.PI/2)c>k&&(a[0]=Math.cos(c)*g+e,a[1]=Math.sin(c)*g+f,q.min(t,a,t),q.max(n,a,n))},f});define("zrender/tool/curve",["require","./vector"],function(g){function f(a){return a>-b&&b>a}function q(a,b,d,e,f){var g=1-f;return g*g*(g*a+3*f*b)+f*f*(f*e+3*g*d)}function l(a,b,d,e){var f=1-e;return f*(f*a+2*e*b)+e*e*d}var d=g("./vector"),b=1E-4,a=Math.sqrt(3),e=1/3,m=d.create(),r=d.create(),k=d.create();return{cubicAt:q,cubicDerivativeAt:function(a,b,d,e,f){var g=1-f;return 3*(((b-a)*g+2*(d-b)*f)*g+(e-d)*f*f)},cubicRootAt:function(b,c,d,g,h,k){g=g+3*(c-d)-b;d=3*(d-2*c+b);var m=3*(c-b);b-=h;h=d*d-3*g*m;c=d*m-9*g*b;var l=m*m-3*d*b;b=0;if(f(h)&&f(c))f(d)?k[0]=0:(h=-m/d,0<=h&&1>=h&&(k[b++]=h));else if(m=c*c-4*h*l,f(m))c/=h,h=-d/g+c,c=-c/2,0<=h&&1>=h&&(k[b++]=h),0<=c&&1>=c&&(k[b++]=c);else if(0<m)l=Math.sqrt(m),m=h*d+1.5*g*(-c+l),h=h*d+1.5*g*(-c-l),m=0>m?-Math.pow(-m,e):Math.pow(m,e),h=0>h?-Math.pow(-h,e):Math.pow(h,e),h=(-d-(m+h))/(3*g),0<=h&&1>=h&&(k[b++]=h);else{var m=Math.acos((2*h*d-3*g*c)/(2*Math.sqrt(h*h*h)))/3,l=Math.sqrt(h),r=Math.cos(m);h=(-d-2*l*r)/(3*g);c=(-d+l*(r+a*Math.sin(m)))/(3*g);g=(-d+l*(r-a*Math.sin(m)))/(3*g);0<=h&&1>=h&&(k[b++]=h);0<=c&&1>=c&&(k[b++]=c);0<=g&&1>=g&&(k[b++]=g)}return b},cubicExtrema:function(a,c,d,e,g){var k=6*d-12*c+6*a;d=9*c+3*e-3*a-9*d;c=3*c-3*a;a=0;if(f(d)){if(k>b||-b>k)c=-c/k,0<=c&&1>=c&&(g[a++]=c)}else c=k*k-4*d*c,f(c)?g[0]=-k/(2*d):0<c&&(e=Math.sqrt(c),c=(-k+e)/(2*d),k=(-k-e)/(2*d),0<=c&&1>=c&&(g[a++]=c),0<=k&&1>=k&&(g[a++]=k));return a},cubicSubdivide:function(a,b,d,e,f,g){var k=(b-a)*f+a,m=(d-b)*f+b;d=(e-d)*f+d;b=(m-k)*f+k;m=(d-m)*f+m;f=(m-b)*f+b;g[0]=a;g[1]=k;g[2]=b;g[3]=f;g[4]=f;g[5]=m;g[6]=d;g[7]=e},cubicProjectPoint:function(a,c,e,f,g,l,B,z,I,H,M){var D,G=.005,K=1/0;m[0]=I;m[1]=H;for(H=0;1>H;H+=.05)r[0]=q(a,e,g,B,H),r[1]=q(c,f,l,z,H),I=d.distSquare(m,r),K>I&&(D=H,K=I);K=1/0;for(H=0;32>H&&!(b>G);H++){var C=D-G,y=D+G;r[0]=q(a,e,g,B,C);r[1]=q(c,f,l,z,C);I=d.distSquare(r,m);0<=C&&K>I?(D=C,K=I):(k[0]=q(a,e,g,B,y),k[1]=q(c,f,l,z,y),I=d.distSquare(k,m),1>=y&&K>I?(D=y,K=I):G*=.5)}return M&&(M[0]=q(a,e,g,B,D),M[1]=q(c,f,l,z,D)),Math.sqrt(K)},quadraticAt:l,quadraticDerivativeAt:function(a,b,d,e){return 2*((1-e)*(b-a)+e*(d-b))},quadraticRootAt:function(a,c,d,e,g){d=a-2*c+d;c=2*(c-a);e=a-e;a=0;if(f(d)){if(c>b||-b>c)e=-e/c,0<=e&&1>=e&&(g[a++]=e)}else if(e=c*c-4*d*e,f(e))e=-c/(2*d),0<=e&&1>=e&&(g[a++]=e);else if(0<e){var k=Math.sqrt(e);e=(-c+k)/(2*d);d=(-c-k)/(2*d);0<=e&&1>=e&&(g[a++]=e);0<=d&&1>=d&&(g[a++]=d)}return a},quadraticExtremum:function(a,b,d){d=a+d-2*b;return 0===d?.5:(a-b)/d},quadraticProjectPoint:function(a,c,e,f,g,q,B,z,I){var H,M=.005,D=1/0;m[0]=B;m[1]=z;for(z=0;1>z;z+=.05)r[0]=l(a,e,g,z),r[1]=l(c,f,q,z),B=d.distSquare(m,r),D>B&&(H=z,D=B);D=1/0;for(z=0;32>z&&!(b>M);z++){var G=H-M,K=H+M;r[0]=l(a,e,g,G);r[1]=l(c,f,q,G);B=d.distSquare(r,m);0<=G&&D>B?(H=G,D=B):(k[0]=l(a,e,g,K),k[1]=l(c,f,q,K),B=d.distSquare(k,m),1>=K&&D>B?(H=K,D=B):M*=.5)}return I&&(I[0]=l(a,e,g,H),I[1]=l(c,f,q,H)),Math.sqrt(D)}}});define("echarts/util/shape/Chain","require zrender/shape/Base ./Icon zrender/shape/util/dashedLineTo zrender/tool/util zrender/tool/matrix".split(" "),function(g){function f(a){q.call(this,a)}var q=g("zrender/shape/Base"),l=g("./Icon"),d=g("zrender/shape/util/dashedLineTo"),b=g("zrender/tool/util"),a=g("zrender/tool/matrix");return f.prototype={type:"chain",brush:function(a,b){var d=this.style;b&&(d=this.getHighlightStyle(d,this.highlightStyle||{}));a.save();this.setContext(a,d);this.setTransform(a);a.save();a.beginPath();this.buildLinePath(a,d);a.stroke();a.restore();this.brushSymbol(a,d);a.restore()},buildLinePath:function(a,b){var f=b.x,g=b.y+5,l=b.width,c=b.height/2-10;(a.moveTo(f,g),a.lineTo(f,g+c),a.moveTo(f+l,g),a.lineTo(f+l,g+c),a.moveTo(f,g+c/2),b.lineType&&"solid"!=b.lineType)?"dashed"!=b.lineType&&"dotted"!=b.lineType||d(a,f,g+c/2,f+l,g+c/2,(b.lineWidth||1)*("dashed"==b.lineType?5:1)):a.lineTo(f+l,g+c/2)},brushSymbol:function(a,b){var d=b.y+b.height/4;a.save();for(var f,g=b.chainPoint,c=0,q=g.length;q>c;c++){if(f=g[c],"none"!=f.symbol){a.beginPath();var n=f.symbolSize;l.prototype.buildPath(a,{iconType:f.symbol,x:f.x-n,y:d-n,width:2*n,height:2*n,n:f.n});a.fillStyle=f.isEmpty?"#fff":b.strokeColor;a.closePath();a.fill();a.stroke()}f.showLabel&&(a.font=f.textFont,a.fillStyle=f.textColor,a.textAlign=f.textAlign,a.textBaseline=f.textBaseline,f.rotation?(a.save(),this._updateTextTransform(a,f.rotation),a.fillText(f.name,f.textX,f.textY),a.restore()):a.fillText(f.name,f.textX,f.textY))}a.restore()},_updateTextTransform:function(b,d){var f=a.create();if(a.identity(f),0!==d[0]){var g=d[1]||0,l=d[2]||0;(g||l)&&a.translate(f,f,[-g,-l]);a.rotate(f,f,d[0]);(g||l)&&a.translate(f,f,[g,l])}b.transform.apply(b,f)},isCover:function(a,b){var d=this.style;return a>=d.x&&a<=d.x+d.width&&b>=d.y&&b<=d.y+d.height?!0:!1}},b.inherits(f,q),f});