34;#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],ix]},ox=["#dd6b66","#759aa0","#e69d87","#8dc1a9","#ea7e53","#eedd78","#73a373","#73b9bc","#7289ab","#91ca8c","#f49f42"],ax={color:ox,backgroundColor:"#333",tooltip:{axisPointer:{lineStyle:{color:"#eee"},crossStyle:{color:"#eee"}}},legend:{textStyle:{color:"#eee"}},textStyle:{color:"#eee"},title:{textStyle:{color:"#eee"}},toolbox:{iconStyle:{normal:{borderColor:"#eee"}}},dataZoom:{textStyle:{color:"#eee"}},visualMap:{textStyle:{color:"#eee"}},timeline:{lineStyle:{color:"#eee"},itemStyle:{normal:{color:ox[1]}},label:{normal:{textStyle:{color:"#eee"}}},controlStyle:{normal:{color:"#eee",borderColor:"#eee"}}},timeAxis:{axisLine:{lineStyle:{color:"#eee"}},axisTick:{lineStyle:{color:"#eee"}},axisLabel:{textStyle:{color:"#eee"}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:"#eee"}}},logAxis:{axisLine:{lineStyle:{color:"#eee"}},axisTick:{lineStyle:{color:"#eee"}},axisLabel:{textStyle:{color:"#eee"}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:"#eee"}}},valueAxis:{axisLine:{lineStyle:{color:"#eee"}},axisTick:{lineStyle:{color:"#eee"}},axisLabel:{textStyle:{color:"#eee"}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:"#eee"}}},categoryAxis:{axisLine:{lineStyle:{color:"#eee"}},axisTick:{lineStyle:{color:"#eee"}},axisLabel:{textStyle:{color:"#eee"}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:"#eee"}}},line:{symbol:"circle"},graph:{color:ox},gauge:{title:{textStyle:{color:"#eee"}}},candlestick:{itemStyle:{normal:{color:"#FD1050",color0:"#0CF49B",borderColor:"#FD1050",borderColor0:"#0CF49B"}}}};ax.categoryAxis.splitLine.show=!1;var sx=P,lx=d,hx=x,ux=w,cx=Qv.parseClassType,dx={zrender:"4.0.3"},fx=1e3,px=1e3,gx=3e3,mx={PROCESSOR:{FILTER:fx,STATISTIC:5e3},VISUAL:{LAYOUT:px,GLOBAL:2e3,CHART:gx,COMPONENT:4e3,BRUSH:5e3}},vx="__flagInMainProcess",yx="__optionUpdated",xx=/^[a-zA-Z0-9_]+$/;Ca.prototype.on=Ta("on"),Ca.prototype.off=Ta("off"),Ca.prototype.one=Ta("one"),u(Ca,xp);var _x=Da.prototype;_x._onframe=function(){if(!this._disposed){var t=this._scheduler;if(this[yx]){var e=this[yx].silent;this[vx]=!0,ka(this),bx.update.call(this),this[vx]=!1,this[yx]=!1,za.call(this,e),Ea.call(this,e)}else if(t.unfinished){var n=1,i=this._model;this._api;t.unfinished=!1;do{var r=+new Date;t.performSeriesTasks(i),t.performDataProcessorTasks(i),La(this,i),t.performVisualTasks(i),Ha(this,this._model,0,"remain"),n-=+new Date-r}while(n>0&&t.unfinished);t.unfinished||this._zr.flush()}}},_x.getDom=function(){return this._dom},_x.getZr=function(){return this._zr},_x.setOption=function(t,e,n){var i;if(ux(e)&&(n=e.lazyUpdate,i=e.silent,e=e.notMerge),this[vx]=!0,!this._model||e){var r=new xo(this._api),o=this._theme,a=this._model=new py(null,null,o,r);a.scheduler=this._scheduler,a.init(null,null,o,r)}this._model.setOption(t,Cx),n?(this[yx]={silent:i},this[vx]=!1):(ka(this),bx.update.call(this),this._zr.flush(),this[yx]=!1,this[vx]=!1,za.call(this,i),Ea.call(this,i))},_x.setTheme=function(){console.log("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},_x.getModel=function(){return this._model},_x.getOption=function(){return this._model&&this._model.getOption()},_x.getWidth=function(){return this._zr.getWidth()},_x.getHeight=function(){return this._zr.getHeight()},_x.getDevicePixelRatio=function(){return this._zr.painter.dpr||window.devicePixelRatio||1},_x.getRenderedCanvas=function(t){if(Kf.canvasSupported)return(t=t||{}).pixelRatio=t.pixelRatio||1,t.backgroundColor=t.backgroundColor||this._model.get("backgroundColor"),this._zr.painter.getRenderedCanvas(t)},_x.getSvgDataUrl=function(){if(Kf.svgSupported){var t=this._zr;return d(t.storage.getDisplayList(),function(t){t.stopAnimation(!0)}),t.painter.pathToDataUrl()}},_x.getDataURL=function(t){var e=(t=t||{}).excludeComponents,n=this._model,i=[],r=this;lx(e,function(t){n.eachComponent({mainType:t},function(t){var e=r._componentsMap[t.__viewId];e.group.ignore||(i.push(e),e.group.ignore=!0)})});var o="svg"===this._zr.painter.getType()?this.getSvgDataUrl():this.getRenderedCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return lx(i,function(t){t.group.ignore=!1}),o},_x.getConnectedDataURL=function(t){if(Kf.canvasSupported){var e=this.group,i=Math.min,r=Math.max;if(Ox[e]){var o=1/0,a=1/0,s=-1/0,l=-1/0,h=[],u=t&&t.pixelRatio||1;d(Lx,function(u,c){if(u.group===e){var d=u.getRenderedCanvas(n(t)),f=u.getDom().getBoundingClientRect();o=i(f.left,o),a=i(f.top,a),s=r(f.right,s),l=r(f.bottom,l),h.push({dom:d,left:f.left,top:f.top})}});var c=(s*=u)-(o*=u),f=(l*=u)-(a*=u),p=lp();p.width=c,p.height=f;var g=mn(p);return lx(h,function(t){var e=new je({style:{x:t.left*u-o,y:t.top*u-a,image:t.dom}});g.add(e)}),g.refreshImmediately(),p.toDataURL("image/"+(t&&t.type||"png"))}return this.getDataURL(t)}},_x.convertToPixel=v(Aa,"convertToPixel"),_x.convertFromPixel=v(Aa,"convertFromPixel"),_x.containPixel=function(t,e){var n;return t=An(this._model,t),d(t,function(t,i){i.indexOf("Models")>=0&&d(t,function(t){var r=t.coordinateSystem;if(r&&r.containPoint)n|=!!r.containPoint(e);else if("seriesModels"===i){var o=this._chartsMap[t.__viewId];o&&o.containPoint&&(n|=o.containPoint(e,t))}},this)},this),!!n},_x.getVisual=function(t,e){var n=(t=An(this._model,t,{defaultMainType:"series"})).seriesModel.getData(),i=t.hasOwnProperty("dataIndexInside")?t.dataIndexInside:t.hasOwnProperty("dataIndex")?n.indexOfRawIndex(t.dataIndex):null;return null!=i?n.getItemVisual(i,e):n.getVisual(e)},_x.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},_x.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]};var bx={prepareAndUpdate:function(t){ka(this),bx.update.call(this,t)},update:function(t){var e=this._model,n=this._api,i=this._zr,r=this._coordSysMgr,o=this._scheduler;if(e){e.restoreData(t),o.performSeriesTasks(e),r.create(e,n),o.performDataProcessorTasks(e,t),La(this,e),r.update(e,n),Ba(e),o.performVisualTasks(e,t),Va(this,e,n,t);var a=e.get("backgroundColor")||"transparent";if(Kf.canvasSupported)i.setBackgroundColor(a);else{var s=Mt(a);a=Lt(s,"rgb"),0===s[3]&&(a="transparent")}Ga(e,n)}},updateTransform:function(t){var e=this._model,n=this,i=this._api;if(e){var r=[];e.eachComponent(function(o,a){var s=n.getViewOfComponentModel(a);if(s&&s.__alive)if(s.updateTransform){var l=s.updateTransform(a,e,i,t);l&&l.update&&r.push(s)}else r.push(s)});var o=N();e.eachSeries(function(r){var a=n._chartsMap[r.__viewId];if(a.updateTransform){var s=a.updateTransform(r,e,i,t);s&&s.update&&o.set(r.uid,1)}else o.set(r.uid,1)}),Ba(e),this._scheduler.performVisualTasks(e,t,{setDirty:!0,dirtyMap:o}),Ha(n,e,0,t,o),Ga(e,this._api)}},updateView:function(t){var e=this._model;e&&(ia.markUpdateMethod(t,"updateView"),Ba(e),this._scheduler.performVisualTasks(e,t,{setDirty:!0}),Va(this,this._model,this._api,t),Ga(e,this._api))},updateVisual:function(t){bx.update.call(this,t)},updateLayout:function(t){bx.update.call(this,t)}};_x.resize=function(t){this._zr.resize(t);var e=this._model;if(this._loadingFX&&this._loadingFX.resize(),e){var n=e.resetOption("media"),i=t&&t.silent;this[vx]=!0,n&&ka(this),bx.update.call(this),this[vx]=!1,za.call(this,i),Ea.call(this,i)}},_x.showLoading=function(t,e){if(ux(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),Px[t]){var n=Px[t](this._api,e),i=this._zr;this._loadingFX=n,i.add(n)}},_x.hideLoading=function(){this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},_x.makeActionFromEvent=function(t){var e=o({},t);return e.type=Ix[t.type],e},_x.dispatchAction=function(t,e){ux(e)||(e={silent:!!e}),Mx[t.type]&&this._model&&(this[vx]?this._pendingActions.push(t):(Oa.call(this,t,e.silent),e.flush?this._zr.flush(!0):!1!==e.flush&&Kf.browser.weChat&&this._throttledZrFlush(),za.call(this,e.silent),Ea.call(this,e.silent)))},_x.appendData=function(t){var e=t.seriesIndex;this.getModel().getSeriesByIndex(e).appendData(t),this._scheduler.unfinished=!0},_x.on=Ta("on"),_x.off=Ta("off"),_x.one=Ta("one");var Sx=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];_x._initEvents=function(){lx(Sx,function(t){this._zr.on(t,function(e){var n,i=this.getModel(),r=e.target;if("globalout"===t)n={};else if(r&&null!=r.dataIndex){var a=r.dataModel||i.getSeriesByIndex(r.seriesIndex);n=a&&a.getDataParams(r.dataIndex,r.dataType)||{}}else r&&r.eventData&&(n=o({},r.eventData));n&&(n.event=e,n.type=t,this.trigger(t,n))},this)},this),lx(Ix,function(t,e){this._messageCenter.on(e,function(t){this.trigger(e,t)},this)},this)},_x.isDisposed=function(){return this._disposed},_x.clear=function(){this.setOption({series:[]},!0)},_x.dispose=function(){if(!this._disposed){this._disposed=!0,Pn(this.getDom(),Nx,"");var t=this._api,e=this._model;lx(this._componentsViews,function(n){n.dispose(e,t)}),lx(this._chartsViews,function(n){n.dispose(e,t)}),this._zr.dispose(),delete Lx[this.id]}},u(Da,xp);var Mx={},Ix={},Tx=[],Cx=[],Dx=[],Ax=[],kx={},Px={},Lx={},Ox={},zx=new Date-0,Ex=new Date-0,Nx="_echarts_instance_",Rx={},Bx=Ya;es(2e3,Yy),Ka(Dy),Qa(5e3,function(t){var e=N();t.eachSeries(function(t){var n=t.get("stack");if(n){var i=e.get(n)||e.set(n,[]),r=t.getData(),o={stackResultDimension:r.getCalculationInfo("stackResultDimension"),stackedOverDimension:r.getCalculationInfo("stackedOverDimension"),stackedDimension:r.getCalculationInfo("stackedDimension"),stackedByDimension:r.getCalculationInfo("stackedByDimension"),isStackedByIndex:r.getCalculationInfo("isStackedByIndex"),data:r,seriesModel:t};if(!o.stackedDimension||!o.isStackedByIndex&&!o.stackedByDimension)return;i.length&&r.setCalculationInfo("stackedOnSeries",i[i.length-1].seriesModel),i.push(o)}}),e.each(No)}),is("default",function(t,e){a(e=e||{},{text:"loading",color:"#c23531",textColor:"#000",maskColor:"rgba(255, 255, 255, 0.8)",zlevel:0});var n=new gv({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4}),i=new xv({shape:{startAngle:-Ky/2,endAngle:-Ky/2+.1,r:10},style:{stroke:e.color,lineCap:"round",lineWidth:5},zlevel:e.zlevel,z:10001}),r=new gv({style:{fill:"none",text:e.text,textPosition:"right",textDistance:10,textFill:e.textColor},zlevel:e.zlevel,z:10001});i.animateShape(!0).when(1e3,{endAngle:3*Ky/2}).start("circularInOut"),i.animateShape(!0).when(1e3,{startAngle:3*Ky/2}).delay(300).start("circularInOut");var o=new Jp;return o.add(i),o.add(r),o.add(n),o.resize=function(){var e=t.getWidth()/2,o=t.getHeight()/2;i.setShape({cx:e,cy:o});var a=i.shape.r;r.setShape({x:e-a,y:o-a,width:2*a,height:2*a}),n.setShape({x:0,y:0,width:t.getWidth(),height:t.getHeight()})},o.resize(),o}),Ja({type:"highlight",event:"highlight",update:"highlight"},R),Ja({type:"downplay",event:"downplay",update:"downplay"},R),$a("light",rx),$a("dark",ax);var Vx={};hs.prototype={constructor:hs,add:function(t){return this._add=t,this},update:function(t){return this._update=t,this},remove:function(t){return this._remove=t,this},execute:function(){var t=this._old,e=this._new,n={},i=[],r=[];for(us(t,{},i,"_oldKeyGetter",this),us(e,n,r,"_newKeyGetter",this),o=0;o<t.length;o++)null!=(s=n[a=i[o]])?((h=s.length)?(1===h&&(n[a]=null),s=s.unshift()):n[a]=null,this._update&&this._update(s,o)):this._remove&&this._remove(o);for(var o=0;o<r.length;o++){var a=r[o];if(n.hasOwnProperty(a)){var s=n[a];if(null==s)continue;if(s.length)for(var l=0,h=s.length;l<h;l++)this._add&&this._add(s[l]);else this._add&&this._add(s)}}}};var Fx=N(["tooltip","label","itemName","itemId","seriesName"]),Hx=w,Gx="undefined"==typeof window?global:window,Wx="e\0\0",Zx={float:void 0===Gx.Float64Array?Array:Gx.Float64Array,int:void 0===Gx.Int32Array?Array:Gx.Int32Array,ordinal:Array,number:Array,time:Array},Ux=void 0===Gx.Uint32Array?Array:Gx.Uint32Array,Xx=void 0===Gx.Uint16Array?Array:Gx.Uint16Array,jx=["hasItemOption","_nameList","_idList","_calculationInfo","_invertedIndicesMap","_rawData","_rawExtent","_chunkSize","_chunkCount","_dimValueGetter","_count","_rawCount","_nameDimIdx","_idDimIdx"],Yx=function(t,e){t=t||["x","y"];for(var n={},i=[],r={},o=0;o<t.length;o++){var a=t[o];_(a)&&(a={name:a});var s=a.name;a.type=a.type||"float",a.coordDim||(a.coordDim=s,a.coordDimIndex=0),a.otherDims=a.otherDims||{},i.push(s),n[s]=a,a.index=o,a.createInvertedIndices&&(r[s]=[])}this.dimensions=i,this._dimensionInfos=n,this.hostModel=e,this.dataType,this._indices=null,this._count=0,this._rawCount=0,this._storage={},this._nameList=[],this._idList=[],this._optionModels=[],this._visual={},this._layout={},this._itemVisuals=[],this.hasItemVisual={},this._itemLayouts=[],this._graphicEls=[],this._chunkSize=1e5,this._chunkCount=0,this._rawData,this._rawExtent={},this._extent={},this._approximateExtent={},this._dimensionsSummary=cs(this),this._invertedIndicesMap=r,this._calculationInfo={}},qx=Yx.prototype;qx.type="list",qx.hasItemOption=!0,qx.getDimension=function(t){return isNaN(t)||(t=this.dimensions[t]||t),t},qx.getDimensionInfo=function(t){return this._dimensionInfos[this.getDimension(t)]},qx.getDimensionsOnCoord=function(){return this._dimensionsSummary.dataDimsOnCoord.slice()},qx.mapDimension=function(t,e){var n=this._dimensionsSummary;if(null==e)return n.encodeFirstDimNotExtra[t];var i=n.encode[t];return!0===e?(i||[]).slice():i&&i[e]},qx.initData=function(t,e,n){($r.isInstance(t)||c(t))&&(t=new Ro(t,this.dimensions.length)),this._rawData=t,this._storage={},this._indices=null,this._nameList=e||[],this._idList=[],this._nameRepeatCount={},n||(this.hasItemOption=!1),this.defaultDimValueGetter=Ly[this._rawData.getSource().sourceFormat],this._dimValueGetter=n=n||this.defaultDimValueGetter,this._rawExtent={},this._initDataFromProvider(0,t.count()),t.pure&&(this.hasItemOption=!1)},qx.getProvider=function(){return this._rawData},qx.appendData=function(t){var e=this._rawData,n=this.count();e.appendData(t);var i=e.count();e.persistent||(i+=n),this._initDataFromProvider(n,i)},qx._initDataFromProvider=function(t,e){if(!(t>=e)){for(var n,i=this._chunkSize,r=this._rawData,o=this._storage,a=this.dimensions,s=this._dimensionInfos,l=this._nameList,h=this._idList,u=this._rawExtent,c=this._nameRepeatCount={},d=this._chunkCount,f=d-1,p=0;p<a.length;p++){u[I=a[p]]||(u[I]=[1/0,-1/0]);var g=s[I];0===g.otherDims.itemName&&(n=this._nameDimIdx=p),0===g.otherDims.itemId&&(this._idDimIdx=p);var m=Zx[g.type];o[I]||(o[I]=[]);var v=o[I][f];if(v&&v.length<i){for(var y=new m(Math.min(e-f*i,i)),x=0;x<v.length;x++)y[x]=v[x];o[I][f]=y}for(M=d*i;M<e;M+=i)o[I].push(new m(Math.min(e-M,i)));this._chunkCount=o[I].length}for(var _=t;_<e;_++){for(var w=r.getItem(_),b=Math.floor(_/i),S=_%i,M=0;M<a.length;M++){var I=a[M],T=o[I][b],C=this._dimValueGetter(w,I,_,M);T[S]=C,C<u[I][0]&&(u[I][0]=C),C>u[I][1]&&(u[I][1]=C)}if(!r.pure){var D=l[_];w&&!D&&(null!=n?D=this._getNameFromStore(_):null!=w.name&&(l[_]=D=w.name));var A=null==w?null:w.id;null==A&&null!=D&&(c[D]=c[D]||0,A=D,c[D]>0&&(A+="__ec__"+c[D]),c[D]++),null!=A&&(h[_]=A)}}!r.persistent&&r.clean&&r.clean(),this._rawCount=this._count=e,this._extent={},vs(this)}},qx._getNameFromStore=function(t){var e=this._nameDimIdx;if(null!=e){var n=this._chunkSize,i=Math.floor(t/n),r=t%n,o=this.dimensions[e],a=this._dimensionInfos[o].ordinalMeta;if(a)return a.categories[t];var s=this._storage[o][i];return s&&s[r]}},qx._getIdFromStore=function(t){var e=this._idDimIdx;if(null!=e){var n=this._chunkSize,i=Math.floor(t/n),r=t%n,o=this.dimensions[e],a=this._dimensionInfos[o].ordinalMeta;if(a)return a.categories[t];var s=this._storage[o][i];return s&&s[r]}},qx.count=function(){return this._count},qx.getIndices=function(){if(this._indices)return new(t=this._indices.constructor)(this._indices.buffer,0,this._count);for(var t=ps(this),e=new t(this.count()),n=0;n<e.length;n++)e[n]=n;return e},qx.get=function(t,e){if(!(e>=0&&e<this._count))return NaN;var n=this._storage;if(!n[t])return NaN;e=this.getRawIndex(e);var i=Math.floor(e/this._chunkSize),r=e%this._chunkSize;return n[t][i][r]},qx.getByRawIndex=function(t,e){if(!(e>=0&&e<this._rawCount))return NaN;var n=this._storage[t];if(!n)return NaN;var i=Math.floor(e/this._chunkSize),r=e%this._chunkSize;return n[i][r]},qx._getFast=function(t,e){var n=Math.floor(e/this._chunkSize),i=e%this._chunkSize;return this._storage[t][n][i]},qx.getValues=function(t,e){var n=[];y(t)||(e=t,t=this.dimensions);for(var i=0,r=t.length;i<r;i++)n.push(this.get(t[i],e));return n},qx.hasValue=function(t){for(var e=this._dimensionsSummary.dataDimsOnCoord,n=this._dimensionInfos,i=0,r=e.length;i<r;i++)if("ordinal"!==n[e[i]].type&&isNaN(this.get(e[i],t)))return!1;return!0},qx.getDataExtent=function(t){t=this.getDimension(t);var e=[1/0,-1/0];if(!this._storage[t])return e;var n,i=this.count();if(!this._indices)return this._rawExtent[t].slice();if(n=this._extent[t])return n.slice();for(var r=(n=e)[0],o=n[1],a=0;a<i;a++){var s=this._getFast(t,this.getRawIndex(a));s<r&&(r=s),s>o&&(o=s)}return n=[r,o],this._extent[t]=n,n},qx.getApproximateExtent=function(t){return t=this.getDimension(t),this._approximateExtent[t]||this.getDataExtent(t)},qx.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},qx.getCalculationInfo=function(t){return this._calculationInfo[t]},qx.setCalculationInfo=function(t,e){Hx(t)?o(this._calculationInfo,t):this._calculationInfo[t]=e},qx.getSum=function(t){var e=0;if(this._storage[t])for(var n=0,i=this.count();n<i;n++){var r=this.get(t,n);isNaN(r)||(e+=r)}return e},qx.rawIndexOf=function(t,e){var n=(t&&this._invertedIndicesMap[t])[e];return null==n||isNaN(n)?-1:n},qx.indexOfName=function(t){for(var e=0,n=this.count();e<n;e++)if(this.getName(e)===t)return e;return-1},qx.indexOfRawIndex=function(t){if(!this._indices)return t;if(t>=this._rawCount||t<0)return-1;var e=this._indices,n=e[t];if(null!=n&&n<this._count&&n===t)return t;for(var i=0,r=this._count-1;i<=r;){var o=(i+r)/2|0;if(e[o]<t)i=o+1;else{if(!(e[o]>t))return o;r=o-1}}return-1},qx.indicesOfNearest=function(t,e,n){var i=[];if(!this._storage[t])return i;null==n&&(n=1/0);for(var r=Number.MAX_VALUE,o=-1,a=0,s=this.count();a<s;a++){var l=e-this.get(t,a),h=Math.abs(l);l<=n&&h<=r&&((h<r||l>=0&&o<0)&&(r=h,o=l,i.length=0),i.push(a))}return i},qx.getRawIndex=ys,qx.getRawDataItem=function(t){if(this._rawData.persistent)return this._rawData.getItem(this.getRawIndex(t));for(var e=[],n=0;n<this.dimensions.length;n++){var i=this.dimensions[n];e.push(this.get(i,t))}return e},qx.getName=function(t){var e=this.getRawIndex(t);return this._nameList[e]||this._getNameFromStore(e)||""},qx.getId=function(t){return _s(this,this.getRawIndex(t))},qx.each=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this;for(var r=(t=f(ws(t),this.getDimension,this)).length,o=0;o<this.count();o++)switch(r){case 0:e.call(n,o);break;case 1:e.call(n,this.get(t[0],o),o);break;case 2:e.call(n,this.get(t[0],o),this.get(t[1],o),o);break;default:for(var a=0,s=[];a<r;a++)s[a]=this.get(t[a],o);s[a]=o,e.apply(n,s)}}},qx.filterSelf=function(t,e,n,i){if(this._count){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this,t=f(ws(t),this.getDimension,this);for(var r=this.count(),o=new(ps(this))(r),a=[],s=t.length,l=0,h=t[0],u=0;u<r;u++){var c,d=this.getRawIndex(u);if(0===s)c=e.call(n,u);else if(1===s){var p=this._getFast(h,d);c=e.call(n,p,u)}else{for(var g=0;g<s;g++)a[g]=this._getFast(h,d);a[g]=u,c=e.apply(n,a)}c&&(o[l++]=d)}return l<r&&(this._indices=o),this._count=l,this._extent={},this.getRawIndex=this._indices?xs:ys,this}},qx.selectRange=function(t){if(this._count){var e=[];for(var n in t)t.hasOwnProperty(n)&&e.push(n);var i=e.length;if(i){var r=this.count(),o=new(ps(this))(r),a=0,s=e[0],l=t[s][0],h=t[s][1],u=!1;if(!this._indices){var c=0;if(1===i){for(var d=this._storage[e[0]],f=0;f<this._chunkCount;f++)for(var p=d[f],g=Math.min(this._count-f*this._chunkSize,this._chunkSize),m=0;m<g;m++)(w=p[m])>=l&&w<=h&&(o[a++]=c),c++;u=!0}else if(2===i){for(var d=this._storage[s],v=this._storage[e[1]],y=t[e[1]][0],x=t[e[1]][1],f=0;f<this._chunkCount;f++)for(var p=d[f],_=v[f],g=Math.min(this._count-f*this._chunkSize,this._chunkSize),m=0;m<g;m++){var w=p[m],b=_[m];w>=l&&w<=h&&b>=y&&b<=x&&(o[a++]=c),c++}u=!0}}if(!u)if(1===i)for(m=0;m<r;m++){M=this.getRawIndex(m);(w=this._getFast(s,M))>=l&&w<=h&&(o[a++]=M)}else for(m=0;m<r;m++){for(var S=!0,M=this.getRawIndex(m),f=0;f<i;f++){var I=e[f];((w=this._getFast(n,M))<t[I][0]||w>t[I][1])&&(S=!1)}S&&(o[a++]=this.getRawIndex(m))}return a<r&&(this._indices=o),this._count=a,this._extent={},this.getRawIndex=this._indices?xs:ys,this}}},qx.mapArray=function(t,e,n,i){"function"==typeof t&&(i=n,n=e,e=t,t=[]),n=n||i||this;var r=[];return this.each(t,function(){r.push(e&&e.apply(this,arguments))},n),r},qx.map=function(t,e,n,i){n=n||i||this;var r=bs(this,t=f(ws(t),this.getDimension,this));r._indices=this._indices,r.getRawIndex=r._indices?xs:ys;for(var o=r._storage,a=[],s=this._chunkSize,l=t.length,h=this.count(),u=[],c=r._rawExtent,d=0;d<h;d++){for(var p=0;p<l;p++)u[p]=this.get(t[p],d);u[l]=d;var g=e&&e.apply(n,u);if(null!=g){"object"!=typeof g&&(a[0]=g,g=a);for(var m=this.getRawIndex(d),v=Math.floor(m/s),y=m%s,x=0;x<g.length;x++){var _=t[x],w=g[x],b=c[_],S=o[_];S&&(S[v][y]=w),w<b[0]&&(b[0]=w),w>b[1]&&(b[1]=w)}}}return r},qx.downSample=function(t,e,n,i){for(var r=bs(this,[t]),o=r._storage,a=[],s=Math.floor(1/e),l=o[t],h=this.count(),u=this._chunkSize,c=r._rawExtent[t],d=new(ps(this))(h),f=0,p=0;p<h;p+=s){s>h-p&&(s=h-p,a.length=s);for(var g=0;g<s;g++){var m=this.getRawIndex(p+g),v=Math.floor(m/u),y=m%u;a[g]=l[v][y]}var x=n(a),_=this.getRawIndex(Math.min(p+i(a,x)||0,h-1)),w=_%u;l[Math.floor(_/u)][w]=x,x<c[0]&&(c[0]=x),x>c[1]&&(c[1]=x),d[f++]=_}return r._count=f,r._indices=d,r.getRawIndex=xs,r},qx.getItemModel=function(t){var e=this.hostModel;return new pr(this.getRawDataItem(t),e,e&&e.ecModel)},qx.diff=function(t){var e=this;return new hs(t?t.getIndices():[],this.getIndices(),function(e){return _s(t,e)},function(t){return _s(e,t)})},qx.getVisual=function(t){var e=this._visual;return e&&e[t]},qx.setVisual=function(t,e){if(Hx(t))for(var n in t)t.hasOwnProperty(n)&&this.setVisual(n,t[n]);else this._visual=this._visual||{},this._visual[t]=e},qx.setLayout=function(t,e){if(Hx(t))for(var n in t)t.hasOwnProperty(n)&&this.setLayout(n,t[n]);else this._layout[t]=e},qx.getLayout=function(t){return this._layout[t]},qx.getItemLayout=function(t){return this._itemLayouts[t]},qx.setItemLayout=function(t,e,n){this._itemLayouts[t]=n?o(this._itemLayouts[t]||{},e):e},qx.clearItemLayouts=function(){this._itemLayouts.length=0},qx.getItemVisual=function(t,e,n){var i=this._itemVisuals[t],r=i&&i[e];return null!=r||n?r:this.getVisual(e)},qx.setItemVisual=function(t,e,n){var i=this._itemVisuals[t]||{},r=this.hasItemVisual;if(this._itemVisuals[t]=i,Hx(e))for(var o in e)e.hasOwnProperty(o)&&(i[o]=e[o],r[o]=!0);else i[e]=n,r[e]=!0},qx.clearAllVisual=function(){this._visual={},this._itemVisuals=[],this.hasItemVisual={}};var $x=function(t){t.seriesIndex=this.seriesIndex,t.dataIndex=this.dataIndex,t.dataType=this.dataType};qx.setItemGraphicEl=function(t,e){var n=this.hostModel;e&&(e.dataIndex=t,e.dataType=this.dataType,e.seriesIndex=n&&n.seriesIndex,"group"===e.type&&e.traverse($x,e)),this._graphicEls[t]=e},qx.getItemGraphicEl=function(t){return this._graphicEls[t]},qx.eachItemGraphicEl=function(t,e){d(this._graphicEls,function(n,i){n&&t&&t.call(e,n,i)})},qx.cloneShallow=function(t){if(!t){var e=f(this.dimensions,this.getDimensionInfo,this);t=new Yx(e,this.hostModel)}if(t._storage=this._storage,ms(t,this),this._indices){var i=this._indices.constructor;t._indices=new i(this._indices)}else t._indices=null;return t.getRawIndex=t._indices?xs:ys,t._extent=n(this._extent),t._approximateExtent=n(this._approximateExtent),t},qx.wrapMethod=function(t,e){var n=this[t];"function"==typeof n&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var t=n.apply(this,arguments);return e.apply(this,[t].concat(A(arguments)))})},qx.TRANSFERABLE_METHODS=["cloneShallow","downSample","map"],qx.CHANGABLE_METHODS=["filterSelf","selectRange"];var Kx=function(t,e){return e=e||{},Is(e.coordDimensions||[],t,{dimsDef:e.dimensionsDefine||t.dimensionsDefine,encodeDef:e.encodeDefine||t.encodeDefine,dimCount:e.dimensionsCount,generateCoord:e.generateCoord,generateCoordCount:e.generateCoordCount})};Os.prototype.parse=function(t){return t},Os.prototype.getSetting=function(t){return this._setting[t]},Os.prototype.contain=function(t){var e=this._extent;return t>=e[0]&&t<=e[1]},Os.prototype.normalize=function(t){var e=this._extent;return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])},Os.prototype.scale=function(t){var e=this._extent;return t*(e[1]-e[0])+e[0]},Os.prototype.unionExtent=function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1])},Os.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},Os.prototype.getExtent=function(){return this._extent.slice()},Os.prototype.setExtent=function(t,e){var n=this._extent;isNaN(t)||(n[0]=t),isNaN(e)||(n[1]=e)},Os.prototype.getTicksLabels=function(){for(var t=[],e=this.getTicks(),n=0;n<e.length;n++)t.push(this.getLabel(e[n]));return t},Os.prototype.isBlank=function(){return this._isBlank},Os.prototype.setBlank=function(t){this._isBlank=t},En(Os),Vn(Os,{registerWhenExtend:!0}),zs.createByAxisModel=function(t){var e=t.option,n=e.data,i=n&&f(n,Ns);return new zs({categories:i,needCollect:!i,deduplication:!1!==e.dedplication})};var Qx=zs.prototype;Qx.getOrdinal=function(t){return Es(this).get(t)},Qx.parseAndCollect=function(t){var e,n=this._needCollect;if("string"!=typeof t&&!n)return t;if(n&&!this._deduplication)return e=this.categories.length,this.categories[e]=t,e;var i=Es(this);return null==(e=i.get(t))&&(n?(e=this.categories.length,this.categories[e]=t,i.set(t,e)):e=NaN),e};var Jx=Os.prototype,t_=Os.extend({type:"ordinal",init:function(t,e){t&&!y(t)||(t=new zs({categories:t})),this._ordinalMeta=t,this._extent=e||[0,t.categories.length-1]},parse:function(t){return"string"==typeof t?this._ordinalMeta.getOrdinal(t):Math.round(t)},contain:function(t){return t=this.parse(t),Jx.contain.call(this,t)&&null!=this._ordinalMeta.categories[t]},normalize:function(t){return Jx.normalize.call(this,this.parse(t))},scale:function(t){return Math.round(Jx.scale.call(this,t))},getTicks:function(){for(var t=[],e=this._extent,n=e[0];n<=e[1];)t.push(n),n++;return t},getLabel:function(t){return this._ordinalMeta.categories[t]},count:function(){return this._extent[1]-this._extent[0]+1},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},niceTicks:R,niceExtent:R});t_.create=function(){return new t_};var e_=wr,n_=wr,i_=Os.extend({type:"interval",_interval:0,_intervalPrecision:2,setExtent:function(t,e){var n=this._extent;isNaN(t)||(n[0]=parseFloat(t)),isNaN(e)||(n[1]=parseFloat(e))},unionExtent:function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1]),i_.prototype.setExtent.call(this,e[0],e[1])},getInterval:function(){return this._interval},setInterval:function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=Bs(t)},getTicks:function(){return Hs(this._interval,this._extent,this._niceExtent,this._intervalPrecision)},getTicksLabels:function(){for(var t=[],e=this.getTicks(),n=0;n<e.length;n++)t.push(this.getLabel(e[n]));return t},getLabel:function(t,e){if(null==t)return"";var n=e&&e.precision;return null==n?n=Mr(t)||0:"auto"===n&&(n=this._intervalPrecision),t=n_(t,n,!0),Or(t)},niceTicks:function(t,e,n){t=t||5;var i=this._extent,r=i[1]-i[0];if(isFinite(r)){r<0&&(r=-r,i.reverse());var o=Rs(i,t,e,n);this._intervalPrecision=o.intervalPrecision,this._interval=o.interval,this._niceExtent=o.niceTickExtent}},niceExtent:function(t){var e=this._extent;if(e[0]===e[1])if(0!==e[0]){var n=e[0];t.fixMax?e[0]-=n/2:(e[1]+=n/2,e[0]-=n/2)}else e[1]=1;var i=e[1]-e[0];isFinite(i)||(e[0]=0,e[1]=1),this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var r=this._interval;t.fixMin||(e[0]=n_(Math.floor(e[0]/r)*r)),t.fixMax||(e[1]=n_(Math.ceil(e[1]/r)*r))}});i_.create=function(){return new i_};var r_="__ec_stack_",o_=i_.prototype,a_=Math.ceil,s_=Math.floor,l_=function(t,e,n,i){for(;n<i;){var r=n+i>>>1;t[r][1]<e?n=r+1:i=r}return n},h_=i_.extend({type:"time",getLabel:function(t){var e=this._stepLvl,n=new Date(t);return Vr(e[0],n,this.getSetting("useUTC"))},niceExtent:function(t){var e=this._extent;if(e[0]===e[1]&&(e[0]-=864e5,e[1]+=864e5),e[1]===-1/0&&e[0]===1/0){var n=new Date;e[1]=+new Date(n.getFullYear(),n.getMonth(),n.getDate()),e[0]=e[1]-864e5}this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var i=this._interval;t.fixMin||(e[0]=wr(s_(e[0]/i)*i)),t.fixMax||(e[1]=wr(a_(e[1]/i)*i))},niceTicks:function(t,e,n){t=t||10;var i=this._extent,r=i[1]-i[0],o=r/t;null!=e&&o<e&&(o=e),null!=n&&o>n&&(o=n);var a=u_.length,s=l_(u_,o,0,a),l=u_[Math.min(s,a-1)],h=l[1];"year"===l[0]&&(h*=Lr(r/h/t,!0));var u=this.getSetting("useUTC")?0:60*new Date(+i[0]||+i[1]).getTimezoneOffset()*1e3,c=[Math.round(a_((i[0]-u)/h)*h+u),Math.round(s_((i[1]-u)/h)*h+u)];Fs(c,i),this._stepLvl=l,this._interval=h,this._niceExtent=c},parse:function(t){return+Ar(t)}});d(["contain","normalize"],function(t){h_.prototype[t]=function(e){return o_[t].call(this,this.parse(e))}});var u_=[["hh:mm:ss",1e3],["hh:mm:ss",5e3],["hh:mm:ss",1e4],["hh:mm:ss",15e3],["hh:mm:ss",3e4],["hh:mm\nMM-dd",6e4],["hh:mm\nMM-dd",3e5],["hh:mm\nMM-dd",6e5],["hh:mm\nMM-dd",9e5],["hh:mm\nMM-dd",18e5],["hh:mm\nMM-dd",36e5],["hh:mm\nMM-dd",72e5],["hh:mm\nMM-dd",216e5],["hh:mm\nMM-dd",432e5],["MM-dd\nyyyy",864e5],["MM-dd\nyyyy",1728e5],["MM-dd\nyyyy",2592e5],["MM-dd\nyyyy",3456e5],["MM-dd\nyyyy",432e6],["MM-dd\nyyyy",5184e5],["week",6048e5],["MM-dd\nyyyy",864e6],["week",12096e5],["week",18144e5],["month",26784e5],["week",36288e5],["month",53568e5],["week",36288e5],["quarter",8208e6],["month",107136e5],["month",13392e6],["half-year",16416e6],["month",214272e5],["month",26784e6],["year",32832e6]];h_.create=function(t){return new h_({useUTC:t.ecModel.get("useUTC")})};var c_=Os.prototype,d_=i_.prototype,f_=Mr,p_=wr,g_=Math.floor,m_=Math.ceil,v_=Math.pow,y_=Math.log,x_=Os.extend({type:"log",base:10,$constructor:function(){Os.apply(this,arguments),this._originalScale=new i_},getTicks:function(){var t=this._originalScale,e=this._extent,n=t.getExtent();return f(d_.getTicks.call(this),function(i){var r=wr(v_(this.base,i));return r=i===e[0]&&t.__fixMin?Xs(r,n[0]):r,r=i===e[1]&&t.__fixMax?Xs(r,n[1]):r},this)},getLabel:d_.getLabel,scale:function(t){return t=c_.scale.call(this,t),v_(this.base,t)},setExtent:function(t,e){var n=this.base;t=y_(t)/y_(n),e=y_(e)/y_(n),d_.setExtent.call(this,t,e)},getExtent:function(){var t=this.base,e=c_.getExtent.call(this);e[0]=v_(t,e[0]),e[1]=v_(t,e[1]);var n=this._originalScale,i=n.getExtent();return n.__fixMin&&(e[0]=Xs(e[0],i[0])),n.__fixMax&&(e[1]=Xs(e[1],i[1])),e},unionExtent:function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=y_(t[0])/y_(e),t[1]=y_(t[1])/y_(e),c_.unionExtent.call(this,t)},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},niceTicks:function(t){t=t||10;var e=this._extent,n=e[1]-e[0];if(!(n===1/0||n<=0)){var i=kr(n);for(t/n*i<=.5&&(i*=10);!isNaN(i)&&Math.abs(i)<1&&Math.abs(i)>0;)i*=10;var r=[wr(m_(e[0]/i)*i),wr(g_(e[1]/i)*i)];this._interval=i,this._niceExtent=r}},niceExtent:function(t){d_.niceExtent.call(this,t);var e=this._originalScale;e.__fixMin=t.fixMin,e.__fixMax=t.fixMax}});d(["contain","normalize"],function(t){x_.prototype[t]=function(e){return e=y_(e)/y_(this.base),c_[t].call(this,e)}}),x_.create=function(){return new x_};var __={getFormattedLabels:function(){return Qs(this.axis,this.get("axisLabel.formatter"))},getMin:function(t){var e=this.option,n=t||null==e.rangeStart?e.min:e.rangeStart;return this.axis&&null!=n&&"dataMin"!==n&&"function"!=typeof n&&!I(n)&&(n=this.axis.scale.parse(n)),n},getMax:function(t){var e=this.option,n=t||null==e.rangeEnd?e.max:e.rangeEnd;return this.axis&&null!=n&&"dataMax"!==n&&"function"!=typeof n&&!I(n)&&(n=this.axis.scale.parse(n)),n},getNeedCrossZero:function(){var t=this.option;return null==t.rangeStart&&null==t.rangeEnd&&!t.scale},getCoordSysModel:R,setRange:function(t,e){this.option.rangeStart=t,this.option.rangeEnd=e},resetRange:function(){this.option.rangeStart=this.option.rangeEnd=null}},w_=Ai({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,o=e.height/2;t.moveTo(n,i-o),t.lineTo(n+r,i+o),t.lineTo(n-r,i+o),t.closePath()}}),b_=Ai({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var n=e.cx,i=e.cy,r=e.width/2,o=e.height/2;t.moveTo(n,i-o),t.lineTo(n+r,i),t.lineTo(n,i+o),t.lineTo(n-r,i),t.closePath()}}),S_=Ai({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.x,i=e.y,r=e.width/5*3,o=Math.max(r,e.height),a=r/2,s=a*a/(o-a),l=i-o+a+s,h=Math.asin(s/a),u=Math.cos(h)*a,c=Math.sin(h),d=Math.cos(h),f=.6*a,p=.7*a;t.moveTo(n-u,l+s),t.arc(n,l,a,Math.PI-h,2*Math.PI+h),t.bezierCurveTo(n+u-c*f,l+s+d*f,n,i-p,n,i),t.bezierCurveTo(n,i-p,n-u+c*f,l+s+d*f,n-u,l+s),t.closePath()}}),M_=Ai({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var n=e.height,i=e.width,r=e.x,o=e.y,a=i/3*2;t.moveTo(r,o),t.lineTo(r+a,o+n),t.lineTo(r,o+n/4*3),t.lineTo(r-a,o+n),t.lineTo(r,o),t.closePath()}}),I_={line:function(t,e,n,i,r){r.x1=t,r.y1=e+i/2,r.x2=t+n,r.y2=e+i/2},rect:function(t,e,n,i,r){r.x=t,r.y=e,r.width=n,r.height=i},roundRect:function(t,e,n,i,r){r.x=t,r.y=e,r.width=n,r.height=i,r.r=Math.min(n,i)/4},square:function(t,e,n,i,r){var o=Math.min(n,i);r.x=t,r.y=e,r.width=o,r.height=o},circle:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.r=Math.min(n,i)/2},diamond:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.width=n,r.height=i},pin:function(t,e,n,i,r){r.x=t+n/2,r.y=e+i/2,r.width=n,r.height=i},arrow:function(t,e,n,i,r){r.x=t+n/2,r.y=e+i/2,r.width=n,r.height=i},triangle:function(t,e,n,i,r){r.cx=t+n/2,r.cy=e+i/2,r.width=n,r.height=i}},T_={};d({line:mv,rect:gv,roundRect:gv,square:gv,circle:av,diamond:b_,pin:S_,arrow:M_,triangle:w_},function(t,e){T_[e]=new t});var C_=Ai({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},beforeBrush:function(){var t=this.style;"pin"===this.shape.symbolType&&"inside"===t.textPosition&&(t.textPosition=["50%","40%"],t.textAlign="center",t.textVerticalAlign="middle")},buildPath:function(t,e,n){var i=e.symbolType,r=T_[i];"none"!==e.symbolType&&(r||(r=T_[i="rect"]),I_[i](e.x,e.y,e.width,e.height,r.shape),r.buildPath(t,r.shape,n))}}),D_={isDimensionStacked:As,enableDataStack:Ds},A_=(Object.freeze||Object)({createList:function(t){return ks(t.getSource(),t)},getLayoutRect:Gr,dataStack:D_,createScale:function(t,e){var n=e;pr.isInstance(e)||u(n=new pr(e),__);var i=$s(n);return i.setExtent(t[0],t[1]),qs(i,n),i},mixinAxisModelCommonMethods:function(t){u(t,__)},completeDimensions:Is,createDimensions:Kx,createSymbol:el}),k_=1e-8;rl.prototype={constructor:rl,properties:null,getBoundingRect:function(){var t=this._rect;if(t)return t;for(var e=Number.MAX_VALUE,n=[e,e],i=[-e,-e],r=[],o=[],a=this.geometries,s=0;s<a.length;s++)"polygon"===a[s].type&&(ti(a[s].exterior,r,o),K(n,n,r),Q(i,i,o));return 0===s&&(n[0]=n[1]=i[0]=i[1]=0),this._rect=new Xt(n[0],n[1],i[0]-n[0],i[1]-n[1])},contain:function(t){var e=this.getBoundingRect(),n=this.geometries;if(!e.contain(t[0],t[1]))return!1;t:for(var i=0,r=n.length;i<r;i++)if("polygon"===n[i].type){var o=n[i].exterior,a=n[i].interiors;if(il(o,t[0],t[1])){for(var s=0;s<(a?a.length:0);s++)if(il(a[s]))continue t;return!0}}return!1},transformTo:function(t,e,n,i){var r=this.getBoundingRect(),o=r.width/r.height;n?i||(i=n/o):n=o*i;for(var a=new Xt(t,e,n,i),s=r.calculateTransform(a),l=this.geometries,h=0;h<l.length;h++)if("polygon"===l[h].type){for(var u=l[h].exterior,c=l[h].interiors,d=0;d<u.length;d++)$(u[d],u[d],s);for(var f=0;f<(c?c.length:0);f++)for(d=0;d<c[f].length;d++)$(c[f][d],c[f][d],s)}(r=this._rect).copy(a),this.center=[r.x+r.width/2,r.y+r.height/2]}};var P_=function(t){return ol(t),f(g(t.features,function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0}),function(t){var e=t.properties,n=t.geometry,i=n.coordinates,r=[];"Polygon"===n.type&&r.push({type:"polygon",exterior:i[0],interiors:i.slice(1)}),"MultiPolygon"===n.type&&d(i,function(t){t[0]&&r.push({type:"polygon",exterior:t[0],interiors:t.slice(1)})});var o=new rl(e.name,r,e.cp);return o.properties=e,o})},L_=xr,O_=[0,1],z_=function(t,e,n){this.dim=t,this.scale=e,this._extent=n||[0,0],this.inverse=!1,this.onBand=!1,this._labelInterval};z_.prototype={constructor:z_,contain:function(t){var e=this._extent,n=Math.min(e[0],e[1]),i=Math.max(e[0],e[1]);return t>=n&&t<=i},containData:function(t){return this.contain(this.dataToCoord(t))},getExtent:function(){return this._extent.slice()},getPixelPrecision:function(t){return Ir(t||this.scale.getExtent(),this._extent)},setExtent:function(t,e){var n=this._extent;n[0]=t,n[1]=e},dataToCoord:function(t,e){var n=this._extent,i=this.scale;return t=i.normalize(t),this.onBand&&"ordinal"===i.type&&sl(n=n.slice(),i.count()),L_(t,O_,n,e)},coordToData:function(t,e){var n=this._extent,i=this.scale;this.onBand&&"ordinal"===i.type&&sl(n=n.slice(),i.count());var r=L_(t,n,O_,e);return this.scale.scale(r)},pointToData:function(t,e){},getTicksCoords:function(t){if(this.onBand&&!t){for(var e=this.getBands(),n=[],i=0;i<e.length;i++)n.push(e[i][0]);return e[i-1]&&n.push(e[i-1][1]),n}return f(this.scale.getTicks(),this.dataToCoord,this)},getLabelsCoords:function(){return f(this.scale.getTicks(),this.dataToCoord,this)},getBands:function(){for(var t=this.getExtent(),e=[],n=this.scale.count(),i=t[0],r=t[1]-i,o=0;o<n;o++)e.push([r*o/n+i,r*(o+1)/n+i]);return e},getBandWidth:function(){var t=this._extent,e=this.scale.getExtent(),n=e[1]-e[0]+(this.onBand?1:0);0===n&&(n=1);var i=Math.abs(t[1]-t[0]);return Math.abs(i)/n},isHorizontal:null,getRotate:null,getLabelInterval:function(){var t=this._labelInterval;if(!t){var e=this.model,n=e.getModel("axisLabel");t=n.get("interval"),"category"!==this.type||null!=t&&"auto"!==t||(t=Ks(f(this.scale.getTicks(),this.dataToCoord,this),e.getFormattedLabels(),n.getFont(),this.getRotate?this.getRotate():this.isHorizontal&&!this.isHorizontal()?90:0,n.get("rotate"))),this._labelInterval=t}return t}};var E_=P_,N_={};d(["map","each","filter","indexOf","inherits","reduce","filter","bind","curry","isArray","isString","isObject","isFunction","extend","defaults","clone","merge"],function(t){N_[t]=cp[t]});rs({type:"dataset",defaultOption:{seriesLayoutBy:uy,sourceHeader:null,dimensions:null,source:null},optionUpdated:function(){Kr(this)}});os({type:"dataset"}),Ry.extend({type:"series.line",dependencies:["grid","polar"],getInitialData:function(t,e){return ks(this.getSource(),this)},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,hoverAnimation:!0,clipOverflow:!0,label:{position:"top"},lineStyle:{width:2,type:"solid"},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:!1,connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0}});var R_=cl.prototype;R_._createSymbol=function(t,e,n,i){this.removeAll();var r=el(t,-1,-1,2,2,e.getItemVisual(n,"color"));r.attr({z2:100,culling:!0,scale:ul(i)}),r.drift=dl,this._symbolType=t,this.add(r)},R_.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(t)},R_.getSymbolPath=function(){return this.childAt(0)},R_.getScale=function(){return this.childAt(0).scale},R_.highlight=function(){this.childAt(0).trigger("emphasis")},R_.downplay=function(){this.childAt(0).trigger("normal")},R_.setZ=function(t,e){var n=this.childAt(0);n.zlevel=t,n.z=e},R_.setDraggable=function(t){var e=this.childAt(0);e.draggable=t,e.cursor=t?"move":"pointer"},R_.updateData=function(t,e,n){this.silent=!1;var i=t.getItemVisual(e,"symbol")||"circle",r=t.hostModel,o=hl(t,e),a=i!==this._symbolType;if(a?this._createSymbol(i,t,e,o):((s=this.childAt(0)).silent=!1,ar(s,{scale:ul(o)},r,e)),this._updateCommon(t,e,o,n),a){var s=this.childAt(0),l=n&&n.fadeIn,h={scale:s.scale.slice()};l&&(h.style={opacity:s.style.opacity}),s.scale=[0,0],l&&(s.style.opacity=0),sr(s,h,r,e)}this._seriesModel=r};var B_=["itemStyle"],V_=["emphasis","itemStyle"],F_=["label"],H_=["emphasis","label"];R_._updateCommon=function(t,e,n,i){var r=this.childAt(0),a=t.hostModel,s=t.getItemVisual(e,"color");"image"!==r.type&&r.useStyle({strokeNoScale:!0});var l=i&&i.itemStyle,h=i&&i.hoverItemStyle,u=i&&i.symbolRotate,c=i&&i.symbolOffset,d=i&&i.labelModel,f=i&&i.hoverLabelModel,p=i&&i.hoverAnimation,g=i&&i.cursorStyle;if(!i||t.hasItemOption){var m=i&&i.itemModel?i.itemModel:t.getItemModel(e);l=m.getModel(B_).getItemStyle(["color"]),h=m.getModel(V_).getItemStyle(),u=m.getShallow("symbolRotate"),c=m.getShallow("symbolOffset"),d=m.getModel(F_),f=m.getModel(H_),p=m.getShallow("hoverAnimation"),g=m.getShallow("cursor")}else h=o({},h);var v=r.style;r.attr("rotation",(u||0)*Math.PI/180||0),c&&r.attr("position",[_r(c[0],n[0]),_r(c[1],n[1])]),g&&r.attr("cursor",g),r.setColor(s,i&&i.symbolInnerColor),r.setStyle(l);var y=t.getItemVisual(e,"opacity");null!=y&&(v.opacity=y);var x=i&&i.useNameLabel;$i(v,h,d,f,{labelFetcher:a,labelDataIndex:e,defaultText:function(e,n){return x?t.getName(e):ll(t,e)},isRectText:!0,autoColor:s}),r.off("mouseover").off("mouseout").off("emphasis").off("normal"),r.hoverStyle=h,qi(r);var _=ul(n);if(p&&a.isAnimationEnabled()){var w=function(){if(!this.incremental){var t=_[1]/_[0];this.animateTo({scale:[Math.max(1.1*_[0],_[0]+3),Math.max(1.1*_[1],_[1]+3*t)]},400,"elasticOut")}},b=function(){this.incremental||this.animateTo({scale:_},400,"elasticOut")};r.on("mouseover",w).on("mouseout",b).on("emphasis",w).on("normal",b)}},R_.fadeOut=function(t,e){var n=this.childAt(0);this.silent=n.silent=!0,!(e&&e.keepLabel)&&(n.style.text=null),ar(n,{style:{opacity:0},scale:[0,0]},this._seriesModel,this.dataIndex,t)},h(cl,Jp);var G_=fl.prototype;G_.updateData=function(t,e){e=gl(e);var n=this.group,i=t.hostModel,r=this._data,o=this._symbolCtor,a=ml(t);r||n.removeAll(),t.diff(r).add(function(i){var r=t.getItemLayout(i);if(pl(t,r,i,e)){var s=new o(t,i,a);s.attr("position",r),t.setItemGraphicEl(i,s),n.add(s)}}).update(function(s,l){var h=r.getItemGraphicEl(l),u=t.getItemLayout(s);pl(t,u,s,e)?(h?(h.updateData(t,s,a),ar(h,{position:u},i)):(h=new o(t,s)).attr("position",u),n.add(h),t.setItemGraphicEl(s,h)):n.remove(h)}).remove(function(t){var e=r.getItemGraphicEl(t);e&&e.fadeOut(function(){n.remove(e)})}).execute(),this._data=t},G_.isPersistent=function(){return!0},G_.updateLayout=function(){var t=this._data;t&&t.eachItemGraphicEl(function(e,n){var i=t.getItemLayout(n);e.attr("position",i)})},G_.incrementalPrepareUpdate=function(t){this._seriesScope=ml(t),this._data=null,this.group.removeAll()},G_.incrementalUpdate=function(t,e,n){n=gl(n);for(var i=t.start;i<t.end;i++){var r=e.getItemLayout(i);if(pl(e,r,i,n)){var o=new this._symbolCtor(e,i,this._seriesScope);o.traverse(function(t){t.isGroup||(t.incremental=t.useHoverLayer=!0)}),o.attr("position",r),this.group.add(o),e.setItemGraphicEl(i,o)}}},G_.remove=function(t){var e=this.group,n=this._data;n&&t?n.eachItemGraphicEl(function(t){t.fadeOut(function(){e.remove(t)})}):e.removeAll()};var W_=function(t,e,n,i,r,o,a,s){for(var l=_l(t,e),h=[],u=[],c=[],d=[],f=[],p=[],g=[],m=vl(r,e,a),v=vl(o,t,s),y=0;y<l.length;y++){var x=l[y],_=!0;switch(x.cmd){case"=":var w=t.getItemLayout(x.idx),b=e.getItemLayout(x.idx1);(isNaN(w[0])||isNaN(w[1]))&&(w=b.slice()),h.push(w),u.push(b),c.push(n[x.idx]),d.push(i[x.idx1]),g.push(e.getRawIndex(x.idx1));break;case"+":S=x.idx;h.push(r.dataToPoint([e.get(m.dataDimsForPoint[0],S),e.get(m.dataDimsForPoint[1],S)])),u.push(e.getItemLayout(S).slice()),c.push(xl(m,r,e,S)),d.push(i[S]),g.push(e.getRawIndex(S));break;case"-":var S=x.idx,M=t.getRawIndex(S);M!==S?(h.push(t.getItemLayout(S)),u.push(o.dataToPoint([t.get(v.dataDimsForPoint[0],S),t.get(v.dataDimsForPoint[1],S)])),c.push(n[S]),d.push(xl(v,o,t,S)),g.push(M)):_=!1}_&&(f.push(x),p.push(p.length))}p.sort(function(t,e){return g[t]-g[e]});for(var I=[],T=[],C=[],D=[],A=[],y=0;y<p.length;y++){S=p[y];I[y]=h[S],T[y]=u[S],C[y]=c[S],D[y]=d[S],A[y]=f[S]}return{current:I,next:T,stackedOnCurrent:C,stackedOnNext:D,status:A}},Z_=K,U_=Q,X_=G,j_=V,Y_=[],q_=[],$_=[],K_=xi.extend({type:"ec-polyline",shape:{points:[],smooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},style:{fill:null,stroke:"#000"},brush:lv(xi.prototype.brush),buildPath:function(t,e){var n=e.points,i=0,r=n.length,o=Tl(n,e.smoothConstraint);if(e.connectNulls){for(;r>0&&wl(n[r-1]);r--);for(;i<r&&wl(n[i]);i++);}for(;i<r;)i+=bl(t,n,i,r,r,1,o.min,o.max,e.smooth,e.smoothMonotone,e.connectNulls)+1}}),Q_=xi.extend({type:"ec-polygon",shape:{points:[],stackedOnPoints:[],smooth:0,stackedOnSmooth:0,smoothConstraint:!0,smoothMonotone:null,connectNulls:!1},brush:lv(xi.prototype.brush),buildPath:function(t,e){var n=e.points,i=e.stackedOnPoints,r=0,o=n.length,a=e.smoothMonotone,s=Tl(n,e.smoothConstraint),l=Tl(i,e.smoothConstraint);if(e.connectNulls){for(;o>0&&wl(n[o-1]);o--);for(;r<o&&wl(n[r]);r++);}for(;r<o;){var h=bl(t,n,r,o,o,1,s.min,s.max,e.smooth,a,e.connectNulls);bl(t,i,r+h-1,h,o,-1,l.min,l.max,e.stackedOnSmooth,a,e.connectNulls),r+=h+1,t.closePath()}}});ia.extend({type:"line",init:function(){var t=new Jp,e=new fl;this.group.add(e.group),this._symbolDraw=e,this._lineGroup=t},render:function(t,e,n){var i=t.coordinateSystem,r=this.group,o=t.getData(),s=t.getModel("lineStyle"),l=t.getModel("areaStyle"),h=o.mapArray(o.getItemLayout),u="polar"===i.type,c=this._coordSys,d=this._symbolDraw,f=this._polyline,p=this._polygon,g=this._lineGroup,m=t.get("animation"),v=!l.isEmpty(),y=l.get("origin"),x=kl(i,o,vl(i,o,y)),_=t.get("showSymbol"),w=_&&!u&&!t.get("showAllSymbol")&&this._getSymbolIgnoreFunc(o,i),b=this._data;b&&b.eachItemGraphicEl(function(t,e){t.__temp&&(r.remove(t),b.setItemGraphicEl(e,null))}),_||d.remove(),r.add(g);var S=!u&&t.get("step");if(f&&c.type===i.type&&S===this._step){v&&!p?p=this._newPolygon(h,x,i,m):p&&!v&&(g.remove(p),p=this._polygon=null);var M=Ol(i,!1,t);g.setClipPath(M),_&&d.updateData(o,{isIgnore:w,clipShape:M}),o.eachItemGraphicEl(function(t){t.stopAnimation(!0)}),Cl(this._stackedOnPoints,x)&&Cl(this._points,h)||(m?this._updateAnimation(o,x,i,n,S,y):(S&&(h=zl(h,i,S),x=zl(x,i,S)),f.setShape({points:h}),p&&p.setShape({points:h,stackedOnPoints:x})))}else _&&d.updateData(o,{isIgnore:w,clipShape:Ol(i,!1,t)}),S&&(h=zl(h,i,S),x=zl(x,i,S)),f=this._newPolyline(h,i,m),v&&(p=this._newPolygon(h,x,i,m)),g.setClipPath(Ol(i,!0,t));var I=El(o,i)||o.getVisual("color");f.useStyle(a(s.getLineStyle(),{fill:"none",stroke:I,lineJoin:"bevel"}));var T=t.get("smooth");if(T=Dl(t.get("smooth")),f.setShape({smooth:T,smoothMonotone:t.get("smoothMonotone"),connectNulls:t.get("connectNulls")}),p){var C=o.getCalculationInfo("stackedOnSeries"),D=0;p.useStyle(a(l.getAreaStyle(),{fill:I,opacity:.7,lineJoin:"bevel"})),C&&(D=Dl(C.get("smooth"))),p.setShape({smooth:T,stackedOnSmooth:D,smoothMonotone:t.get("smoothMonotone"),connectNulls:t.get("connectNulls")})}this._data=o,this._coordSys=i,this._stackedOnPoints=x,this._points=h,this._step=S,this._valueOrigin=y},dispose:function(){},highlight:function(t,e,n,i){var r=t.getData(),o=Cn(r,i);if(!(o instanceof Array)&&null!=o&&o>=0){var a=r.getItemGraphicEl(o);if(!a){var s=r.getItemLayout(o);if(!s)return;(a=new cl(r,o)).position=s,a.setZ(t.get("zlevel"),t.get("z")),a.ignore=isNaN(s[0])||isNaN(s[1]),a.__temp=!0,r.setItemGraphicEl(o,a),a.stopSymbolAnimation(!0),this.group.add(a)}a.highlight()}else ia.prototype.highlight.call(this,t,e,n,i)},downplay:function(t,e,n,i){var r=t.getData(),o=Cn(r,i);if(null!=o&&o>=0){var a=r.getItemGraphicEl(o);a&&(a.__temp?(r.setItemGraphicEl(o,null),this.group.remove(a)):a.downplay())}else ia.prototype.downplay.call(this,t,e,n,i)},_newPolyline:function(t){var e=this._polyline;return e&&this._lineGroup.remove(e),e=new K_({shape:{points:t},silent:!0,z2:10}),this._lineGroup.add(e),this._polyline=e,e},_newPolygon:function(t,e){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new Q_({shape:{points:t,stackedOnPoints:e},silent:!0}),this._lineGroup.add(n),this._polygon=n,n},_getSymbolIgnoreFunc:function(t,e){var n=e.getAxesByScale("ordinal")[0];if(n&&n.isLabelIgnored)return m(n.isLabelIgnored,n)},_updateAnimation:function(t,e,n,i,r,o){var a=this._polyline,s=this._polygon,l=t.hostModel,h=W_(this._data,t,this._stackedOnPoints,e,this._coordSys,n,this._valueOrigin,o),u=h.current,c=h.stackedOnCurrent,d=h.next,f=h.stackedOnNext;r&&(u=zl(h.current,n,r),c=zl(h.stackedOnCurrent,n,r),d=zl(h.next,n,r),f=zl(h.stackedOnNext,n,r)),a.shape.__points=h.current,a.shape.points=u,ar(a,{shape:{points:d}},l),s&&(s.setShape({points:u,stackedOnPoints:c}),ar(s,{shape:{points:d,stackedOnPoints:f}},l));for(var p=[],g=h.status,m=0;m<g.length;m++)if("="===g[m].cmd){var v=t.getItemGraphicEl(g[m].idx1);v&&p.push({el:v,ptIdx:m})}a.animators&&a.animators.length&&a.animators[0].during(function(){for(var t=0;t<p.length;t++)p[t].el.attr("position",a.shape.__points[p[t].ptIdx])})},remove:function(t){var e=this.group,n=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),n&&n.eachItemGraphicEl(function(t,i){t.__temp&&(e.remove(t),n.setItemGraphicEl(i,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._data=null}});var J_=function(t,e,n){return{seriesType:t,performRawSeries:!0,reset:function(t,i,r){var o=t.getData(),a=t.get("symbol")||e,s=t.get("symbolSize");if(o.setVisual({legendSymbol:n||a,symbol:a,symbolSize:s}),!i.isSeriesFiltered(t)){var l="function"==typeof s;return{dataEach:o.hasItemOption||l?function(e,n){if("function"==typeof s){var i=t.getRawValue(n),r=t.getDataParams(n);e.setItemVisual(n,"symbolSize",s(i,r))}if(e.hasItemOption){var o=e.getItemModel(n),a=o.getShallow("symbol",!0),l=o.getShallow("symbolSize",!0);null!=a&&e.setItemVisual(n,"symbol",a),null!=l&&e.setItemVisual(n,"symbolSize",l)}}:null}}}}},tw=function(t){return{seriesType:t,plan:Fy(),reset:function(t){var e=t.getData(),n=t.coordinateSystem,i=t.pipelineContext.large;if(n){var r=f(n.dimensions,function(t){return e.mapDimension(t)}).slice(0,2),o=r.length;return As(e,r[0],r[1])&&(r[0]=e.getCalculationInfo("stackResultDimension")),As(e,r[1],r[0])&&(r[1]=e.getCalculationInfo("stackResultDimension")),o&&{progress:function(t,e){for(var a=t.end-t.start,s=i&&new Float32Array(a*o),l=t.start,h=0,u=[],c=[];l<t.end;l++){var d;if(1===o)f=e.get(r[0],l,!0),d=!isNaN(f)&&n.dataToPoint(f,null,c);else{var f=u[0]=e.get(r[0],l,!0),p=u[1]=e.get(r[1],l,!0);d=!isNaN(f)&&!isNaN(p)&&n.dataToPoint(u,null,c)}i?(s[h++]=d?d[0]:NaN,s[h++]=d?d[1]:NaN):e.setItemLayout(l,d&&d.slice()||[NaN,NaN])}i&&e.setLayout("symbolPoints",s)}}}}}},ew={average:function(t){for(var e=0,n=0,i=0;i<t.length;i++)isNaN(t[i])||(e+=t[i],n++);return 0===n?NaN:e/n},sum:function(t){for(var e=0,n=0;n<t.length;n++)e+=t[n]||0;return e},max:function(t){for(var e=-1/0,n=0;n<t.length;n++)t[n]>e&&(e=t[n]);return e},min:function(t){for(var e=1/0,n=0;n<t.length;n++)t[n]<e&&(e=t[n]);return e},nearest:function(t){return t[0]}},nw=function(t,e){return Math.round(t.length/2)},iw=function(t){this._axes={},this._dimList=[],this.name=t||""};iw.prototype={constructor:iw,type:"cartesian",getAxis:function(t){return this._axes[t]},getAxes:function(){return f(this._dimList,Nl,this)},getAxesByScale:function(t){return t=t.toLowerCase(),g(this.getAxes(),function(e){return e.scale.type===t})},addAxis:function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)},dataToCoord:function(t){return this._dataCoordConvert(t,"dataToCoord")},coordToData:function(t){return this._dataCoordConvert(t,"coordToData")},_dataCoordConvert:function(t,e){for(var n=this._dimList,i=t instanceof Array?[]:{},r=0;r<n.length;r++){var o=n[r],a=this._axes[o];i[o]=a[e](t[o])}return i}},Rl.prototype={constructor:Rl,type:"cartesian2d",dimensions:["x","y"],getBaseAxis:function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},containPoint:function(t){var e=this.getAxis("x"),n=this.getAxis("y");return e.contain(e.toLocalCoord(t[0]))&&n.contain(n.toLocalCoord(t[1]))},containData:function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},dataToPoint:function(t,e,n){var i=this.getAxis("x"),r=this.getAxis("y");return n=n||[],n[0]=i.toGlobalCoord(i.dataToCoord(t[0])),n[1]=r.toGlobalCoord(r.dataToCoord(t[1])),n},clampData:function(t,e){var n=this.getAxis("x").scale.getExtent(),i=this.getAxis("y").scale.getExtent();return e=e||[],e[0]=Math.min(Math.max(Math.min(n[0],n[1]),t[0]),Math.max(n[0],n[1])),e[1]=Math.min(Math.max(Math.min(i[0],i[1]),t[1]),Math.max(i[0],i[1])),e},pointToData:function(t,e){var n=this.getAxis("x"),i=this.getAxis("y");return e=e||[],e[0]=n.coordToData(n.toLocalCoord(t[0])),e[1]=i.coordToData(i.toLocalCoord(t[1])),e},getOtherAxis:function(t){return this.getAxis("x"===t.dim?"y":"x")}},h(Rl,iw);var rw=function(t,e,n,i,r){z_.call(this,t,e,n),this.type=i||"value",this.position=r||"bottom"};rw.prototype={constructor:rw,index:0,onZero:!1,model:null,isHorizontal:function(){var t=this.position;return"top"===t||"bottom"===t},getGlobalExtent:function(t){var e=this.getExtent();return e[0]=this.toGlobalCoord(e[0]),e[1]=this.toGlobalCoord(e[1]),t&&e[0]>e[1]&&e.reverse(),e},getOtherAxis:function(){this.grid.getOtherAxis()},isLabelIgnored:function(t){if("category"===this.type){var e=this.getLabelInterval();return"function"==typeof e&&!e(t,this.scale.getLabel(t))||t%(e+1)}},pointToData:function(t,e){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),e)},toLocalCoord:null,toGlobalCoord:null},h(rw,z_);var ow={show:!0,zlevel:0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#333",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#ccc"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.3)","rgba(200,200,200,0.3)"]}}},aw={};aw.categoryAxis=i({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},ow),aw.valueAxis=i({boundaryGap:[0,0],splitNumber:5},ow),aw.timeAxis=a({scale:!0,min:"dataMin",max:"dataMax"},aw.valueAxis),aw.logAxis=a({scale:!0,logBase:10},aw.valueAxis);var sw=["value","category","time","log"],lw=function(t,e,n,o){d(sw,function(a){e.extend({type:t+"Axis."+a,mergeDefaultAndTheme:function(e,r){var o=this.layoutMode,s=o?Ur(e):{};i(e,r.getTheme().get(a+"Axis")),i(e,this.getDefaultOption()),e.type=n(t,e),o&&Zr(e,s,o)},optionUpdated:function(){"category"===this.option.type&&(this.__ordinalMeta=zs.createByAxisModel(this))},getCategories:function(){if("category"===this.option.type)return this.__ordinalMeta.categories},getOrdinalMeta:function(){return this.__ordinalMeta},defaultOption:r([{},aw[a+"Axis"],o],!0)})}),Qv.registerSubTypeDefaulter(t+"Axis",v(n,t))},hw=Qv.extend({type:"cartesian2dAxis",axis:null,init:function(){hw.superApply(this,"init",arguments),this.resetRange()},mergeOption:function(){hw.superApply(this,"mergeOption",arguments),this.resetRange()},restoreData:function(){hw.superApply(this,"restoreData",arguments),this.resetRange()},getCoordSysModel:function(){return this.ecModel.queryComponents({mainType:"grid",index:this.option.gridIndex,id:this.option.gridId})[0]}});i(hw.prototype,__);var uw={offset:0};lw("x",hw,Bl,uw),lw("y",hw,Bl,uw),Qv.extend({type:"grid",dependencies:["xAxis","yAxis"],layoutMode:"box",coordinateSystem:null,defaultOption:{show:!1,zlevel:0,z:0,left:"10%",top:60,right:"10%",bottom:60,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"}});var cw=d,dw=function(t){var e=t.scale.getExtent(),n=e[0],i=e[1];return!(n>0&&i>0||n<0&&i<0)},fw=qs,pw=Gl.prototype;pw.type="grid",pw.axisPointerEnabled=!0,pw.getRect=function(){return this._rect},pw.update=function(t,e){var n=this._axesMap;this._updateScale(t,this.model),cw(n.x,function(t){fw(t.scale,t.model)}),cw(n.y,function(t){fw(t.scale,t.model)}),cw(n.x,function(t){Wl(n,"y",t)}),cw(n.y,function(t){Wl(n,"x",t)}),this.resize(this.model,e)},pw.resize=function(t,e,n){function i(){cw(o,function(t){var e=t.isHorizontal(),n=e?[0,r.width]:[0,r.height],i=t.inverse?1:0;t.setExtent(n[i],n[1-i]),Ul(t,e?r.x:r.y)})}var r=Gr(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()});this._rect=r;var o=this._axesList;i(),!n&&t.get("containLabel")&&(cw(o,function(t){if(!t.model.get("axisLabel.inside")){var e=Hl(t);if(e){var n=t.isHorizontal()?"height":"width",i=t.model.get("axisLabel.margin");r[n]-=e[n]+i,"top"===t.position?r.y+=e.height+i:"left"===t.position&&(r.x+=e.width+i)}}}),i())},pw.getAxis=function(t,e){var n=this._axesMap[t];if(null!=n){if(null==e)for(var i in n)if(n.hasOwnProperty(i))return n[i];return n[e]}},pw.getAxes=function(){return this._axesList.slice()},pw.getCartesian=function(t,e){if(null!=t&&null!=e){var n="x"+t+"y"+e;return this._coordsMap[n]}w(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var i=0,r=this._coordsList;i<r.length;i++)if(r[i].getAxis("x").index===t||r[i].getAxis("y").index===e)return r[i]},pw.getCartesians=function(){return this._coordsList.slice()},pw.convertToPixel=function(t,e,n){var i=this._findConvertTarget(t,e);return i.cartesian?i.cartesian.dataToPoint(n):i.axis?i.axis.toGlobalCoord(i.axis.dataToCoord(n)):null},pw.convertFromPixel=function(t,e,n){var i=this._findConvertTarget(t,e);return i.cartesian?i.cartesian.pointToData(n):i.axis?i.axis.coordToData(i.axis.toLocalCoord(n)):null},pw._findConvertTarget=function(t,e){var n,i,r=e.seriesModel,o=e.xAxisModel||r&&r.getReferringComponents("xAxis")[0],a=e.yAxisModel||r&&r.getReferringComponents("yAxis")[0],s=e.gridModel,h=this._coordsList;return r?l(h,n=r.coordinateSystem)<0&&(n=null):o&&a?n=this.getCartesian(o.componentIndex,a.componentIndex):o?i=this.getAxis("x",o.componentIndex):a?i=this.getAxis("y",a.componentIndex):s&&s.coordinateSystem===this&&(n=this._coordsList[0]),{cartesian:n,axis:i}},pw.containPoint=function(t){var e=this._coordsList[0];if(e)return e.containPoint(t)},pw._initCartesian=function(t,e,n){function i(n){return function(i,s){if(Vl(i,t,e)){var l=i.get("position");"x"===n?"top"!==l&&"bottom"!==l&&r[l="bottom"]&&(l="top"===l?"bottom":"top"):"left"!==l&&"right"!==l&&r[l="left"]&&(l="left"===l?"right":"left"),r[l]=!0;var h=new rw(n,$s(i),[0,0],i.get("type"),l),u="category"===h.type;h.onBand=u&&i.get("boundaryGap"),h.inverse=i.get("inverse"),h.onZero=i.get("axisLine.onZero"),h.onZeroAxisIndex=i.get("axisLine.onZeroAxisIndex"),i.axis=h,h.model=i,h.grid=this,h.index=s,this._axesList.push(h),o[n][s]=h,a[n]++}}}var r={left:!1,right:!1,top:!1,bottom:!1},o={x:{},y:{}},a={x:0,y:0};if(e.eachComponent("xAxis",i("x"),this),e.eachComponent("yAxis",i("y"),this),!a.x||!a.y)return this._axesMap={},void(this._axesList=[]);this._axesMap=o,cw(o.x,function(e,n){cw(o.y,function(i,r){var o="x"+n+"y"+r,a=new Rl(o);a.grid=this,a.model=t,this._coordsMap[o]=a,this._coordsList.push(a),a.addAxis(e),a.addAxis(i)},this)},this)},pw._updateScale=function(t,e){function n(t,e,n){cw(t.mapDimension(e.dim,!0),function(n){e.scale.unionExtentFromData(t,n)})}d(this._axesList,function(t){t.scale.setExtent(1/0,-1/0)}),t.eachSeries(function(i){if(jl(i)){var r=Xl(i),o=r[0],a=r[1];if(!Vl(o,e,t)||!Vl(a,e,t))return;var s=this.getCartesian(o.componentIndex,a.componentIndex),l=i.getData(),h=s.getAxis("x"),u=s.getAxis("y");"list"===l.type&&(n(l,h),n(l,u))}},this)},pw.getTooltipAxes=function(t){var e=[],n=[];return cw(this.getCartesians(),function(i){var r=null!=t&&"auto"!==t?i.getAxis(t):i.getBaseAxis(),o=i.getOtherAxis(r);l(e,r)<0&&e.push(r),l(n,o)<0&&n.push(o)}),{baseAxes:e,otherAxes:n}};var gw=["xAxis","yAxis"];Gl.create=function(t,e){var n=[];return t.eachComponent("grid",function(i,r){var o=new Gl(i,t,e);o.name="grid_"+r,o.resize(i,e,!0),i.coordinateSystem=o,n.push(o)}),t.eachSeries(function(t){if(jl(t)){var e=Xl(t),n=e[0],i=e[1],r=n.getCoordSysModel().coordinateSystem;t.coordinateSystem=r.getCartesian(n.componentIndex,i.componentIndex)}}),n},Gl.dimensions=Gl.prototype.dimensions=Rl.prototype.dimensions,yo.register("cartesian2d",Gl);var mw=Math.PI,vw=function(t,e){this.opt=e,this.axisModel=t,a(e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0}),this.group=new Jp;var n=new Jp({position:e.position.slice(),rotation:e.rotation});n.updateTransform(),this._transform=n.transform,this._dumbGroup=n};vw.prototype={constructor:vw,hasBuilder:function(t){return!!yw[t]},add:function(t){yw[t].call(this)},getGroup:function(){return this.group}};var yw={axisLine:function(){var t=this.opt,e=this.axisModel;if(e.get("axisLine.show")){var n=this.axisModel.axis.getExtent(),i=this._transform,r=[n[0],0],a=[n[1],0];i&&($(r,r,i),$(a,a,i));var s=o({lineCap:"round"},e.getModel("axisLine.lineStyle").getLineStyle());this.group.add(new mv(zi({anid:"line",shape:{x1:r[0],y1:r[1],x2:a[0],y2:a[1]},style:s,strokeContainThreshold:t.strokeContainThreshold||5,silent:!0,z2:1})));var l=e.get("axisLine.symbol"),h=e.get("axisLine.symbolSize"),u=e.get("axisLine.symbolOffset")||0;if("number"==typeof u&&(u=[u,u]),null!=l){"string"==typeof l&&(l=[l,l]),"string"!=typeof h&&"number"!=typeof h||(h=[h,h]);var c=h[0],f=h[1];d([{rotate:t.rotation+Math.PI/2,offset:u[0],r:0},{rotate:t.rotation-Math.PI/2,offset:u[1],r:Math.sqrt((r[0]-a[0])*(r[0]-a[0])+(r[1]-a[1])*(r[1]-a[1]))}],function(e,n){if("none"!==l[n]&&null!=l[n]){var i=el(l[n],-c/2,-f/2,c,f,s.stroke,!0),o=e.r+e.offset,a=[r[0]+o*Math.cos(t.rotation),r[1]-o*Math.sin(t.rotation)];i.attr({rotation:e.rotate,position:a,silent:!0}),this.group.add(i)}},this)}}},axisTickLabel:function(){var t=this.axisModel,e=this.opt,n=eh(this,t,e);Kl(t,nh(this,t,e),n)},axisName:function(){var t=this.opt,e=this.axisModel,n=T(t.axisName,e.get("name"));if(n){var i,r=e.get("nameLocation"),a=t.nameDirection,s=e.getModel("nameTextStyle"),l=e.get("nameGap")||0,h=this.axisModel.axis.getExtent(),u=h[0]>h[1]?-1:1,c=["start"===r?h[0]-u*l:"end"===r?h[1]+u*l:(h[0]+h[1])/2,th(r)?t.labelOffset+a*l:0],d=e.get("nameRotate");null!=d&&(d=d*mw/180);var f;th(r)?i=xw(t.rotation,null!=d?d:t.rotation,a):(i=ql(t,r,d||0,h),null!=(f=t.axisNameAvailableWidth)&&(f=Math.abs(f/Math.sin(i.rotation)),!isFinite(f)&&(f=null)));var p=s.getFont(),g=e.get("nameTruncate",!0)||{},m=g.ellipsis,v=T(t.nameTruncateMaxWidth,g.maxWidth,f),y=null!=m&&null!=v?Wv(n,v,p,m,{minChar:2,placeholder:g.placeholder}):n,x=e.get("tooltip",!0),_=e.mainType,w={componentType:_,name:n,$vars:["name"]};w[_+"Index"]=e.componentIndex;var b=new ov({anid:"name",__fullText:n,__truncatedText:y,position:c,rotation:i.rotation,silent:$l(e),z2:1,tooltip:x&&x.show?o({content:n,formatter:function(){return n},formatterParams:w},x):null});Ki(b.style,s,{text:y,textFont:p,textFill:s.getTextColor()||e.get("axisLine.lineStyle.color"),textAlign:i.textAlign,textVerticalAlign:i.textVerticalAlign}),e.get("triggerEvent")&&(b.eventData=Yl(e),b.eventData.targetType="axisName",b.eventData.name=n),this._dumbGroup.add(b),b.updateTransform(),this.group.add(b),b.decomposeTransform()}}},xw=vw.innerTextLayout=function(t,e,n){var i,r,o=Cr(e-t);return Dr(o)?(r=n>0?"top":"bottom",i="center"):Dr(o-mw)?(r=n>0?"bottom":"top",i="center"):(r="middle",i=o>0&&o<mw?n>0?"right":"left":n>0?"left":"right"),{rotation:o,textAlign:i,textVerticalAlign:r}},_w=vw.ifIgnoreOnTick=function(t,e,n,i,r,o){if(0===e&&r||e===i-1&&o)return!1;var a,s=t.scale;return"ordinal"===s.type&&("function"==typeof n?(a=s.getTicks()[e],!n(a,s.getLabel(a))):e%(n+1))},ww=vw.getInterval=function(t,e){var n=t.get("interval");return null!=n&&"auto"!=n||(n=e),n},bw=d,Sw=v,Mw=os({type:"axis",_axisPointer:null,axisPointerClass:null,render:function(t,e,n,i){this.axisPointerClass&&hh(t),Mw.superApply(this,"render",arguments),ph(this,t,0,n,0,!0)},updateAxisPointer:function(t,e,n,i,r){ph(this,t,0,n,0,!1)},remove:function(t,e){var n=this._axisPointer;n&&n.remove(e),Mw.superApply(this,"remove",arguments)},dispose:function(t,e){gh(this,e),Mw.superApply(this,"dispose",arguments)}}),Iw=[];Mw.registerAxisPointerClass=function(t,e){Iw[t]=e},Mw.getAxisPointerClass=function(t){return t&&Iw[t]};var Tw=vw.ifIgnoreOnTick,Cw=vw.getInterval,Dw=["axisLine","axisTickLabel","axisName"],Aw=["splitArea","splitLine"],kw=Mw.extend({type:"cartesianAxis",axisPointerClass:"CartesianAxisPointer",render:function(t,e,n,i){this.group.removeAll();var r=this._axisGroup;if(this._axisGroup=new Jp,this.group.add(this._axisGroup),t.get("show")){var o=t.getCoordSysModel(),a=mh(o,t),s=new vw(t,a);d(Dw,s.add,s),this._axisGroup.add(s.getGroup()),d(Aw,function(e){t.get(e+".show")&&this["_"+e](t,o,a.labelInterval)},this),cr(r,this._axisGroup,t),kw.superCall(this,"render",t,e,n,i)}},_splitLine:function(t,e,n){var i=t.axis;if(!i.scale.isBlank()){var r=t.getModel("splitLine"),o=r.getModel("lineStyle"),s=o.get("color"),l=Cw(r,n);s=y(s)?s:[s];for(var h=e.coordinateSystem.getRect(),u=i.isHorizontal(),c=0,d=i.getTicksCoords(),f=i.scale.getTicks(),p=t.get("axisLabel.showMinLabel"),g=t.get("axisLabel.showMaxLabel"),m=[],v=[],x=o.getLineStyle(),_=0;_<d.length;_++)if(!Tw(i,_,l,d.length,p,g)){var w=i.toGlobalCoord(d[_]);u?(m[0]=w,m[1]=h.y,v[0]=w,v[1]=h.y+h.height):(m[0]=h.x,m[1]=w,v[0]=h.x+h.width,v[1]=w);var b=c++%s.length;this._axisGroup.add(new mv(zi({anid:"line_"+f[_],shape:{x1:m[0],y1:m[1],x2:v[0],y2:v[1]},style:a({stroke:s[b]},x),silent:!0})))}}},_splitArea:function(t,e,n){var i=t.axis;if(!i.scale.isBlank()){var r=t.getModel("splitArea"),o=r.getModel("areaStyle"),s=o.get("color"),l=e.coordinateSystem.getRect(),h=i.getTicksCoords(),u=i.scale.getTicks(),c=i.toGlobalCoord(h[0]),d=i.toGlobalCoord(h[0]),f=0,p=Cw(r,n),g=o.getAreaStyle();s=y(s)?s:[s];for(var m=t.get("axisLabel.showMinLabel"),v=t.get("axisLabel.showMaxLabel"),x=1;x<h.length;x++)if(!(Tw(i,x,p,h.length,m,v)&&x<h.length-1)){var _,w,b,S,M=i.toGlobalCoord(h[x]);i.isHorizontal()?(_=c,w=l.y,b=M-_,S=l.height):(_=l.x,w=d,b=l.width,S=M-w);var I=f++%s.length;this._axisGroup.add(new gv({anid:"area_"+u[x],shape:{x:_,y:w,width:b,height:S},style:a({fill:s[I]},g),silent:!0})),c=_+b,d=w+S}}}});kw.extend({type:"xAxis"}),kw.extend({type:"yAxis"}),os({type:"grid",render:function(t,e){this.group.removeAll(),t.get("show")&&this.group.add(new gv({shape:t.coordinateSystem.getRect(),style:a({fill:t.get("backgroundColor")},t.getItemStyle()),silent:!0,z2:-1}))}}),Ka(function(t){t.xAxis&&t.yAxis&&!t.grid&&(t.grid={})}),es(J_("line","circle","line")),ts(tw("line")),Qa(mx.PROCESSOR.STATISTIC,function(t){return{seriesType:t,reset:function(t,e,n){var i=t.getData(),r=t.get("sampling"),o=t.coordinateSystem;if("cartesian2d"===o.type&&r){var a=o.getBaseAxis(),s=o.getOtherAxis(a),l=a.getExtent(),h=l[1]-l[0],u=Math.round(i.count()/h);if(u>1){var c;"string"==typeof r?c=ew[r]:"function"==typeof r&&(c=r),c&&t.setData(i.downSample(s.dim,1/u,c,nw))}}}}}("line")),Ry.extend({type:"series.__base_bar__",getInitialData:function(t,e){return ks(this.getSource(),this)},getMarkerPosition:function(t){var e=this.coordinateSystem;if(e){var n=e.dataToPoint(e.clampData(t)),i=this.getData(),r=i.getLayout("offset"),o=i.getLayout("size");return n[e.getBaseAxis().isHorizontal()?0:1]+=r+o/2,n}return[NaN,NaN]},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,itemStyle:{},emphasis:{}}}).extend({type:"series.bar",dependencies:["grid","polar"],brushSelector:"rect"});var Pw=Jg([["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["stroke","barBorderColor"],["lineWidth","barBorderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Lw={getBarItemStyle:function(t){var e=Pw(this,t);if(this.getBorderLineDash){var n=this.getBorderLineDash();n&&(e.lineDash=n)}return e}},Ow=["itemStyle","barBorderWidth"];o(pr.prototype,Lw),ss({type:"bar",render:function(t,e,n){var i=t.get("coordinateSystem");return"cartesian2d"!==i&&"polar"!==i||this._render(t,e,n),this.group},dispose:R,_render:function(t,e,n){var i,r=this.group,o=t.getData(),a=this._data,s=t.coordinateSystem,l=s.getBaseAxis();"cartesian2d"===s.type?i=l.isHorizontal():"polar"===s.type&&(i="angle"===l.dim);var h=t.isAnimationEnabled()?t:null;o.diff(a).add(function(e){if(o.hasValue(e)){var n=o.getItemModel(e),a=Ew[s.type](o,e,n),l=zw[s.type](o,e,n,a,i,h);o.setItemGraphicEl(e,l),r.add(l),wh(l,o,e,n,a,t,i,"polar"===s.type)}}).update(function(e,n){var l=a.getItemGraphicEl(n);if(o.hasValue(e)){var u=o.getItemModel(e),c=Ew[s.type](o,e,u);l?ar(l,{shape:c},h,e):l=zw[s.type](o,e,u,c,i,h,!0),o.setItemGraphicEl(e,l),r.add(l),wh(l,o,e,u,c,t,i,"polar"===s.type)}else r.remove(l)}).remove(function(t){var e=a.getItemGraphicEl(t);"cartesian2d"===s.type?e&&xh(t,h,e):e&&_h(t,h,e)}).execute(),this._data=o},remove:function(t,e){var n=this.group,i=this._data;t.get("animation")?i&&i.eachItemGraphicEl(function(e){"sector"===e.type?_h(e.dataIndex,t,e):xh(e.dataIndex,t,e)}):n.removeAll()}});var zw={cartesian2d:function(t,e,n,i,r,a,s){var l=new gv({shape:o({},i)});if(a){var h=l.shape,u=r?"height":"width",c={};h[u]=0,c[u]=i[u],Av[s?"updateProps":"initProps"](l,{shape:c},a,e)}return l},polar:function(t,e,n,i,r,o,s){var l=i.startAngle<i.endAngle,h=new hv({shape:a({clockwise:l},i)});if(o){var u=h.shape,c=r?"r":"endAngle",d={};u[c]=r?0:i.startAngle,d[c]=i[c],Av[s?"updateProps":"initProps"](h,{shape:d},o,e)}return h}},Ew={cartesian2d:function(t,e,n){var i=t.getItemLayout(e),r=bh(n,i),o=i.width>0?1:-1,a=i.height>0?1:-1;return{x:i.x+o*r/2,y:i.y+a*r/2,width:i.width-o*r,height:i.height-a*r}},polar:function(t,e,n){var i=t.getItemLayout(e);return{cx:i.cx,cy:i.cy,r0:i.r0,r:i.r,startAngle:i.startAngle,endAngle:i.endAngle}}};ts(v(function(t,e,n){var i=[];e.eachSeriesByType(t,function(t){t.coordinateSystem&&"cartesian2d"===t.coordinateSystem.type&&i.push(t)});var r=Zs(i),o={};d(i,function(t){var e=t.getData(),n=t.coordinateSystem,i=n.getBaseAxis(),a=Gs(t),s=r[Ws(i)][a],l=s.offset,h=s.width,u=n.getOtherAxis(i),c=t.get("barMinHeight")||0;o[a]=o[a]||[],e.setLayout({offset:l,size:h});for(var d=e.mapDimension(u.dim),f=e.mapDimension(i.dim),p=As(e,d,f),g=u.isHorizontal(),m=i.onZero||p?u.toGlobalCoord(u.dataToCoord(0)):u.getGlobalExtent()[0],v=0,y=e.count();v<y;v++){var x=e.get(d,v),_=e.get(f,v);if(!isNaN(x)){var w=x>=0?"p":"n",b=m;p&&(o[a][_]||(o[a][_]={p:m,n:m}),b=o[a][_][w]);var S,M,I,T;if(g)S=b,M=(C=n.dataToPoint([x,_]))[1]+l,I=C[0]-m,T=h,Math.abs(I)<c&&(I=(I<0?-1:1)*c),p&&(o[a][_][w]+=I);else{var C=n.dataToPoint([_,x]);S=C[0]+l,M=b,I=h,T=C[1]-m,Math.abs(T)<c&&(T=(T<=0?-1:1)*c),p&&(o[a][_][w]+=T)}e.setItemLayout(v,{x:S,y:M,width:I,height:T})}}},this)},"bar")),es(function(t){t.eachSeriesByType("bar",function(t){t.getData().setVisual("legendSymbol","roundRect")})});var Nw=function(t,e,n){e=y(e)&&{coordDimensions:e}||o({},e);var i=t.getSource(),r=Kx(i,e),a=new Yx(r,t);return a.initData(i,n),a},Rw={updateSelectedMap:function(t){this._targetList=y(t)?t.slice():[],this._selectTargetMap=p(t||[],function(t,e){return t.set(e.name,e),t},N())},select:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);"single"===this.get("selectedMode")&&this._selectTargetMap.each(function(t){t.selected=!1}),n&&(n.selected=!0)},unSelect:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);n&&(n.selected=!1)},toggleSelected:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);if(null!=n)return this[n.selected?"unSelect":"select"](t,e),n.selected},isSelected:function(t,e){var n=null!=e?this._targetList[e]:this._selectTargetMap.get(t);return n&&n.selected}},Bw=as({type:"series.pie",init:function(t){Bw.superApply(this,"init",arguments),this.legendDataProvider=function(){return this.getRawData()},this.updateSelectedMap(this._createSelectableList()),this._defaultLabelLine(t)},mergeOption:function(t){Bw.superCall(this,"mergeOption",t),this.updateSelectedMap(this._createSelectableList())},getInitialData:function(t,e){return Nw(this,["value"])},_createSelectableList:function(){for(var t=this.getRawData(),e=t.mapDimension("value"),n=[],i=0,r=t.count();i<r;i++)n.push({name:t.getName(i),value:t.get(e,i),selected:Uo(t,i,"selected")});return n},getDataParams:function(t){var e=this.getData(),n=Bw.superCall(this,"getDataParams",t),i=[];return e.each(e.mapDimension("value"),function(t){i.push(t)}),n.percent=Tr(i,t,e.hostModel.get("percentPrecision")),n.$vars.push("percent"),n},_defaultLabelLine:function(t){_n(t,"labelLine",["show"]);var e=t.labelLine,n=t.emphasis.labelLine;e.show=e.show&&t.label.show,n.show=n.show&&t.emphasis.label.show},defaultOption:{zlevel:0,z:2,legendHoverLink:!0,hoverAnimation:!0,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,selectedOffset:10,hoverOffset:10,avoidLabelOverlap:!0,percentPrecision:2,stillShowZeroSum:!0,label:{rotate:!1,show:!0,position:"outer"},labelLine:{show:!0,length:15,length2:15,smooth:!1,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1},animationType:"expansion",animationEasing:"cubicOut"}});u(Bw,Rw);var Vw=Ih.prototype;Vw.updateData=function(t,e,n){function i(){s.stopAnimation(!0),s.animateTo({shape:{r:u.r+l.get("hoverOffset")}},300,"elasticOut")}function r(){s.stopAnimation(!0),s.animateTo({shape:{r:u.r}},300,"elasticOut")}var s=this.childAt(0),l=t.hostModel,h=t.getItemModel(e),u=t.getItemLayout(e),c=o({},u);c.label=null,n?(s.setShape(c),"scale"===l.getShallow("animationType")?(s.shape.r=u.r0,sr(s,{shape:{r:u.r}},l,e)):(s.shape.endAngle=u.startAngle,ar(s,{shape:{endAngle:u.endAngle}},l,e))):ar(s,{shape:c},l,e);var d=t.getItemVisual(e,"color");s.useStyle(a({lineJoin:"bevel",fill:d},h.getModel("itemStyle").getItemStyle())),s.hoverStyle=h.getModel("emphasis.itemStyle").getItemStyle();var f=h.getShallow("cursor");f&&s.attr("cursor",f),Mh(this,t.getItemLayout(e),l.isSelected(null,e),l.get("selectedOffset"),l.get("animation")),s.off("mouseover").off("mouseout").off("emphasis").off("normal"),h.get("hoverAnimation")&&l.isAnimationEnabled()&&s.on("mouseover",i).on("mouseout",r).on("emphasis",i).on("normal",r),this._updateLabel(t,e),qi(this)},Vw._updateLabel=function(t,e){var n=this.childAt(1),i=this.childAt(2),r=t.hostModel,o=t.getItemModel(e),a=t.getItemLayout(e).label,s=t.getItemVisual(e,"color");ar(n,{shape:{points:a.linePoints||[[a.x,a.y],[a.x,a.y],[a.x,a.y]]}},r,e),ar(i,{style:{x:a.x,y:a.y}},r,e),i.attr({rotation:a.rotation,origin:[a.x,a.y],z2:10});var l=o.getModel("label"),h=o.getModel("emphasis.label"),u=o.getModel("labelLine"),c=o.getModel("emphasis.labelLine"),s=t.getItemVisual(e,"color");$i(i.style,i.hoverStyle={},l,h,{labelFetcher:t.hostModel,labelDataIndex:e,defaultText:t.getName(e),autoColor:s,useInsideStyle:!!a.inside},{textAlign:a.textAlign,textVerticalAlign:a.verticalAlign,opacity:t.getItemVisual(e,"opacity")}),i.ignore=i.normalIgnore=!l.get("show"),i.hoverIgnore=!h.get("show"),n.ignore=n.normalIgnore=!u.get("show"),n.hoverIgnore=!c.get("show"),n.setStyle({stroke:s,opacity:t.getItemVisual(e,"opacity")}),n.setStyle(u.getModel("lineStyle").getLineStyle()),n.hoverStyle=c.getModel("lineStyle").getLineStyle();var d=u.get("smooth");d&&!0===d&&(d=.4),n.setShape({smooth:d})},h(Ih,Jp);ia.extend({type:"pie",init:function(){var t=new Jp;this._sectorGroup=t},render:function(t,e,n,i){if(!i||i.from!==this.uid){var r=t.getData(),o=this._data,a=this.group,s=e.get("animation"),l=!o,h=t.get("animationType"),u=v(Sh,this.uid,t,s,n),c=t.get("selectedMode");if(r.diff(o).add(function(t){var e=new Ih(r,t);l&&"scale"!==h&&e.eachChild(function(t){t.stopAnimation(!0)}),c&&e.on("click",u),r.setItemGraphicEl(t,e),a.add(e)}).update(function(t,e){var n=o.getItemGraphicEl(e);n.updateData(r,t),n.off("click"),c&&n.on("click",u),a.add(n),r.setItemGraphicEl(t,n)}).remove(function(t){var e=o.getItemGraphicEl(t);a.remove(e)}).execute(),s&&l&&r.count()>0&&"scale"!==h){var d=r.getItemLayout(0),f=Math.max(n.getWidth(),n.getHeight())/2,p=m(a.removeClipPath,a);a.setClipPath(this._createClipPath(d.cx,d.cy,f,d.startAngle,d.clockwise,p,t))}this._data=r}},dispose:function(){},_createClipPath:function(t,e,n,i,r,o,a){var s=new hv({shape:{cx:t,cy:e,r0:0,r:n,startAngle:i,endAngle:i,clockwise:r}});return sr(s,{shape:{endAngle:i+(r?1:-1)*Math.PI*2}},a,o),s},containPoint:function(t,e){var n=e.getData().getItemLayout(0);if(n){var i=t[0]-n.cx,r=t[1]-n.cy,o=Math.sqrt(i*i+r*r);return o<=n.r&&o>=n.r0}}});var Fw=function(t,e,n,i){var r,o,a=t.getData(),s=[],l=!1;a.each(function(n){var i,h,u,c,d=a.getItemLayout(n),f=a.getItemModel(n),p=f.getModel("label"),g=p.get("position")||f.get("emphasis.label.position"),m=f.getModel("labelLine"),v=m.get("length"),y=m.get("length2"),x=(d.startAngle+d.endAngle)/2,_=Math.cos(x),w=Math.sin(x);r=d.cx,o=d.cy;var b="inside"===g||"inner"===g;if("center"===g)i=d.cx,h=d.cy,c="center";else{var S=(b?(d.r+d.r0)/2*_:d.r*_)+r,M=(b?(d.r+d.r0)/2*w:d.r*w)+o;if(i=S+3*_,h=M+3*w,!b){var I=S+_*(v+e-d.r),T=M+w*(v+e-d.r),C=I+(_<0?-1:1)*y,D=T;i=C+(_<0?-5:5),h=D,u=[[S,M],[I,T],[C,D]]}c=b?"center":_>0?"left":"right"}var A=p.getFont(),k=p.get("rotate")?_<0?-x+Math.PI:-x:0,P=ce(t.getFormattedLabel(n,"normal")||a.getName(n),A,c,"top");l=!!k,d.label={x:i,y:h,position:g,height:P.height,len:v,len2:y,linePoints:u,textAlign:c,verticalAlign:"middle",rotation:k,inside:b},b||s.push(d.label)}),!l&&t.get("avoidLabelOverlap")&&Ch(s,r,o,e,n,i)},Hw=2*Math.PI,Gw=Math.PI/180;!function(t,e){d(e,function(e){e.update="updateView",Ja(e,function(n,i){var r={};return i.eachComponent({mainType:"series",subType:t,query:n},function(t){t[e.method]&&t[e.method](n.name,n.dataIndex);var i=t.getData();i.each(function(e){var n=i.getName(e);r[n]=t.isSelected(n)||!1})}),{name:n.name,selected:r}})})}("pie",[{type:"pieToggleSelect",event:"pieselectchanged",method:"toggleSelected"},{type:"pieSelect",event:"pieselected",method:"select"},{type:"pieUnSelect",event:"pieunselected",method:"unSelect"}]),es(function(t){return{getTargetSeries:function(e){var n={},i=N();return e.eachSeriesByType(t,function(t){t.__paletteScope=n,i.set(t.uid,t)}),i},reset:function(t,e){var n=t.getRawData(),i={},r=t.getData();r.each(function(t){var e=r.getRawIndex(t);i[e]=t}),n.each(function(e){var o=i[e],a=null!=o&&r.getItemVisual(o,"color",!0);if(a)n.setItemVisual(e,"color",a);else{var s=n.getItemModel(e).get("itemStyle.color")||t.getColorFromPalette(n.getName(e)||e+"",t.__paletteScope,n.count());n.setItemVisual(e,"color",s),null!=o&&r.setItemVisual(o,"color",s)}})}}}("pie")),ts(v(function(t,e,n,i){e.eachSeriesByType(t,function(t){var e=t.getData(),i=e.mapDimension("value"),r=t.get("center"),o=t.get("radius");y(o)||(o=[0,o]),y(r)||(r=[r,r]);var a=n.getWidth(),s=n.getHeight(),l=Math.min(a,s),h=_r(r[0],a),u=_r(r[1],s),c=_r(o[0],l/2),d=_r(o[1],l/2),f=-t.get("startAngle")*Gw,p=t.get("minAngle")*Gw,g=0;e.each(i,function(t){!isNaN(t)&&g++});var m=e.getSum(i),v=Math.PI/(m||g)*2,x=t.get("clockwise"),_=t.get("roseType"),w=t.get("stillShowZeroSum"),b=e.getDataExtent(i);b[0]=0;var S=Hw,M=0,I=f,T=x?1:-1;if(e.each(i,function(t,n){var i;if(isNaN(t))e.setItemLayout(n,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:x,cx:h,cy:u,r0:c,r:_?NaN:d});else{(i="area"!==_?0===m&&w?v:t*v:Hw/g)<p?(i=p,S-=p):M+=t;var r=I+T*i;e.setItemLayout(n,{angle:i,startAngle:I,endAngle:r,clockwise:x,cx:h,cy:u,r0:c,r:_?xr(t,b,[c,d]):d}),I=r}}),S<Hw&&g)if(S<=.001){var C=Hw/g;e.each(i,function(t,n){if(!isNaN(t)){var i=e.getItemLayout(n);i.angle=C,i.startAngle=f+T*n*C,i.endAngle=f+T*(n+1)*C}})}else v=S/M,I=f,e.each(i,function(t,n){if(!isNaN(t)){var i=e.getItemLayout(n),r=i.angle===p?p:t*v;i.startAngle=I,i.endAngle=I+T*r,I+=T*r}});Fw(t,d,a,s)})},"pie")),Qa(function(t){return{seriesType:t,reset:function(t,e){var n=e.findComponents({mainType:"legend"});if(n&&n.length){var i=t.getData();i.filterSelf(function(t){for(var e=i.getName(t),r=0;r<n.length;r++)if(!n[r].isSelected(e))return!1;return!0})}}}}("pie")),Ry.extend({type:"series.scatter",dependencies:["grid","polar","geo","singleAxis","calendar"],getInitialData:function(t,e){return ks(this.getSource(),this)},brushSelector:"point",getProgressive:function(){var t=this.option.progressive;return null==t?this.option.large?5e3:this.get("progressive"):t},getProgressiveThreshold:function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?1e4:this.get("progressiveThreshold"):t},defaultOption:{coordinateSystem:"cartesian2d",zlevel:0,z:2,legendHoverLink:!0,hoverAnimation:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},progressive:null}});var Ww=Ai({shape:{points:null},symbolProxy:null,buildPath:function(t,e){var n=e.points,i=e.size,r=this.symbolProxy,o=r.shape;if(!((t.getContext?t.getContext():t)&&i[0]<4))for(var a=0;a<n.length;){var s=n[a++],l=n[a++];isNaN(s)||isNaN(l)||(o.x=s-i[0]/2,o.y=l-i[1]/2,o.width=i[0],o.height=i[1],r.buildPath(t,o,!0))}},afterBrush:function(t){var e=this.shape,n=e.points,i=e.size;if(i[0]<4){this.setTransform(t);for(var r=0;r<n.length;){var o=n[r++],a=n[r++];isNaN(o)||isNaN(a)||t.fillRect(o-i[0]/2,a-i[1]/2,i[0],i[1])}this.restoreTransform(t)}},findDataIndex:function(t,e){for(var n=this.shape,i=n.points,r=n.size,o=Math.max(r[0],4),a=Math.max(r[1],4),s=i.length/2-1;s>=0;s--){var l=2*s,h=i[l]-o/2,u=i[l+1]-a/2;if(t>=h&&e>=u&&t<=h+o&&e<=u+a)return s}return-1}}),Zw=Dh.prototype;Zw.isPersistent=function(){return!this._incremental},Zw.updateData=function(t){this.group.removeAll();var e=new Ww({rectHover:!0,cursor:"default"});e.setShape({points:t.getLayout("symbolPoints")}),this._setCommon(e,t),this.group.add(e),this._incremental=null},Zw.updateLayout=function(t){if(!this._incremental){var e=t.getLayout("symbolPoints");this.group.eachChild(function(t){if(null!=t.startIndex){var n=2*(t.endIndex-t.startIndex),i=4*t.startIndex*2;e=new Float32Array(e.buffer,i,n)}t.setShape("points",e)})}},Zw.incrementalPrepareUpdate=function(t){this.group.removeAll(),this._clearIncremental(),t.count()>2e6?(this._incremental||(this._incremental=new Di({silent:!0})),this.group.add(this._incremental)):this._incremental=null},Zw.incrementalUpdate=function(t,e){var n;this._incremental?(n=new Ww,this._incremental.addDisplayable(n,!0)):((n=new Ww({rectHover:!0,cursor:"default",startIndex:t.start,endIndex:t.end})).incremental=!0,this.group.add(n)),n.setShape({points:e.getLayout("symbolPoints")}),this._setCommon(n,e,!!this._incremental)},Zw._setCommon=function(t,e,n){var i=e.hostModel,r=e.getVisual("symbolSize");t.setShape("size",r instanceof Array?r:[r,r]),t.symbolProxy=el(e.getVisual("symbol"),0,0,0,0),t.setColor=t.symbolProxy.setColor;var o=t.shape.size[0]<4;t.useStyle(i.getModel("itemStyle").getItemStyle(o?["color","shadowBlur","shadowColor"]:["color"]));var a=e.getVisual("color");a&&t.setColor(a),n||(t.seriesIndex=i.seriesIndex,t.on("mousemove",function(e){t.dataIndex=null;var n=t.findDataIndex(e.offsetX,e.offsetY);n>=0&&(t.dataIndex=n+(t.startIndex||0))}))},Zw.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},Zw._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()},ss({type:"scatter",render:function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).updateData(i),this._finished=!0},incrementalPrepareRender:function(t,e,n){var i=t.getData();this._updateSymbolDraw(i,t).incrementalPrepareUpdate(i),this._finished=!1},incrementalRender:function(t,e,n){this._symbolDraw.incrementalUpdate(t,e.getData()),this._finished=t.end===e.getData().count()},updateTransform:function(t,e,n){var i=t.getData();if(this.group.dirty(),!this._finished||i.count()>1e4||!this._symbolDraw.isPersistent())return{update:!0};var r=tw().reset(t);r.progress&&r.progress({start:0,end:i.count()},i),this._symbolDraw.updateLayout(i)},_updateSymbolDraw:function(t,e){var n=this._symbolDraw,i=e.pipelineContext.large;return n&&i===this._isLargeDraw||(n&&n.remove(),n=this._symbolDraw=i?new Dh:new fl,this._isLargeDraw=i,this.group.removeAll()),this.group.add(n.group),n},remove:function(t,e){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},dispose:function(){}}),es(J_("scatter","circle")),ts(tw("scatter")),Ka(function(t){var e=t.graphic;y(e)?e[0]&&e[0].elements?t.graphic=[t.graphic[0]]:t.graphic=[{elements:e}]:e&&!e.elements&&(t.graphic=[{elements:[e]}])});var Uw=rs({type:"graphic",defaultOption:{elements:[],parentId:null},_elOptionsToUpdate:null,mergeOption:function(t){var e=this.option.elements;this.option.elements=null,Uw.superApply(this,"mergeOption",arguments),this.option.elements=e},optionUpdated:function(t,e){var n=this.option,i=(e?n:t).elements,r=n.elements=e?[]:n.elements,o=[];this._flatten(i,o);var a=Sn(r,o);Mn(a);var s=this._elOptionsToUpdate=[];d(a,function(t,e){var n=t.option;n&&(s.push(n),Oh(t,n),zh(r,e,n),Eh(r[e],n))},this);for(var l=r.length-1;l>=0;l--)null==r[l]?r.splice(l,1):delete r[l].$action},_flatten:function(t,e,n){d(t,function(t){if(t){n&&(t.parentOption=n),e.push(t);var i=t.children;"group"===t.type&&i&&this._flatten(i,e,t),delete t.children}},this)},useElOptionsToUpdate:function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t}});os({type:"graphic",init:function(t,e){this._elMap=N(),this._lastGraphicModel},render:function(t,e,n){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t,n),this._relocate(t,n)},_updateElements:function(t,e){var n=t.useElOptionsToUpdate();if(n){var i=this._elMap,r=this.group;d(n,function(t){var e=t.$action,n=t.id,o=i.get(n),a=t.parentId,s=null!=a?i.get(a):r;if("text"===t.type){var l=t.style;t.hv&&t.hv[1]&&(l.textVerticalAlign=l.textBaseline=null),!l.hasOwnProperty("textFill")&&l.fill&&(l.textFill=l.fill),!l.hasOwnProperty("textStroke")&&l.stroke&&(l.textStroke=l.stroke)}var h=Ph(t);e&&"merge"!==e?"replace"===e?(kh(o,i),Ah(n,s,h,i)):"remove"===e&&kh(o,i):o?o.attr(h):Ah(n,s,h,i);var u=i.get(n);u&&(u.__ecGraphicWidth=t.width,u.__ecGraphicHeight=t.height)})}},_relocate:function(t,e){for(var n=t.option.elements,i=this.group,r=this._elMap,o=n.length-1;o>=0;o--){var a=n[o],s=r.get(a.id);if(s){var l=s.parent;Wr(s,a,l===i?{width:e.getWidth(),height:e.getHeight()}:{width:l.__ecGraphicWidth||0,height:l.__ecGraphicHeight||0},null,{hv:a.hv,boundingMode:a.bounding})}}},_clear:function(){var t=this._elMap;t.each(function(e){kh(e,t)}),this._elMap=N()},dispose:function(){this._clear()}});var Xw=function(t,e){var n,i=[],r=t.seriesIndex;if(null==r||!(n=e.getSeriesByIndex(r)))return{point:[]};var o=n.getData(),a=Cn(o,t);if(null==a||a<0||y(a))return{point:[]};var s=o.getItemGraphicEl(a),l=n.coordinateSystem;if(n.getTooltipPosition)i=n.getTooltipPosition(a)||[];else if(l&&l.dataToPoint)i=l.dataToPoint(o.getValues(f(l.dimensions,function(t){return o.mapDimension(t)}),a,!0))||[];else if(s){var h=s.getBoundingRect().clone();h.applyTransform(s.transform),i=[h.x+h.width/2,h.y+h.height/2]}return{point:i,el:s}},jw=d,Yw=v,qw=Dn(),$w=(rs({type:"axisPointer",coordSysAxesInfo:null,defaultOption:{show:"auto",triggerOn:null,zlevel:0,z:50,type:"line",snap:!1,triggerTooltip:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#aaa",width:1,type:"solid"},shadowStyle:{color:"rgba(150,150,150,0.3)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,shadowBlur:3,shadowColor:"#aaa"},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}}}),Dn()),Kw=d,Qw=os({type:"axisPointer",render:function(t,e,n){var i=e.getComponent("tooltip"),r=t.get("triggerOn")||i&&i.get("triggerOn")||"mousemove|click";Xh("axisPointer",n,function(t,e,n){"none"!==r&&("leave"===t||r.indexOf(t)>=0)&&n({type:"updateAxisPointer",currTrigger:t,x:e&&e.offsetX,y:e&&e.offsetY})})},remove:function(t,e){Qh(e.getZr(),"axisPointer"),Qw.superApply(this._model,"remove",arguments)},dispose:function(t,e){Qh("axisPointer",e),Qw.superApply(this._model,"dispose",arguments)}}),Jw=Dn(),tb=n,eb=m;(Jh.prototype={_group:null,_lastGraphicKey:null,_handle:null,_dragging:!1,_lastValue:null,_lastStatus:null,_payloadInfo:null,animationThreshold:15,render:function(t,e,n,i){var r=e.get("value"),o=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=n,i||this._lastValue!==r||this._lastStatus!==o){this._lastValue=r,this._lastStatus=o;var a=this._group,s=this._handle;if(!o||"hide"===o)return a&&a.hide(),void(s&&s.hide());a&&a.show(),s&&s.show();var l={};this.makeElOption(l,r,t,e,n);var h=l.graphicKey;h!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=h;var u=this._moveAnimation=this.determineAnimation(t,e);if(a){var c=v(tu,e,u);this.updatePointerEl(a,l,c,e),this.updateLabelEl(a,l,c,e)}else a=this._group=new Jp,this.createPointerEl(a,l,t,e),this.createLabelEl(a,l,t,e),n.getZr().add(a);ru(a,e,!0),this._renderHandle(r)}},remove:function(t){this.clear(t)},dispose:function(t){this.clear(t)},determineAnimation:function(t,e){var n=e.get("animation"),i=t.axis,r="category"===i.type,o=e.get("snap");if(!o&&!r)return!1;if("auto"===n||null==n){var a=this.animationThreshold;if(r&&i.getBandWidth()>a)return!0;if(o){var s=uh(t).seriesDataCount,l=i.getExtent();return Math.abs(l[0]-l[1])/s>a}return!1}return!0===n},makeElOption:function(t,e,n,i,r){},createPointerEl:function(t,e,n,i){var r=e.pointer;if(r){var o=Jw(t).pointerEl=new Av[r.type](tb(e.pointer));t.add(o)}},createLabelEl:function(t,e,n,i){if(e.label){var r=Jw(t).labelEl=new gv(tb(e.label));t.add(r),nu(r,i)}},updatePointerEl:function(t,e,n){var i=Jw(t).pointerEl;i&&(i.setStyle(e.pointer.style),n(i,{shape:e.pointer.shape}))},updateLabelEl:function(t,e,n,i){var r=Jw(t).labelEl;r&&(r.setStyle(e.label.style),n(r,{shape:e.label.shape,position:e.label.position}),nu(r,i))},_renderHandle:function(t){if(!this._dragging&&this.updateHandleTransform){var e=this._axisPointerModel,n=this._api.getZr(),i=this._handle,r=e.getModel("handle"),o=e.get("status");if(!r.get("show")||!o||"hide"===o)return i&&n.remove(i),void(this._handle=null);var a;this._handle||(a=!0,i=this._handle=fr(r.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){Ag(t.event)},onmousedown:eb(this._onHandleDragMove,this,0,0),drift:eb(this._onHandleDragMove,this),ondragend:eb(this._onHandleDragEnd,this)}),n.add(i)),ru(i,e,!1);var s=["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];i.setStyle(r.getItemStyle(null,s));var l=r.get("size");y(l)||(l=[l,l]),i.attr("scale",[l[0]/2,l[1]/2]),ha(this,"_doDispatchAxisPointer",r.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,a)}},_moveHandleToValue:function(t,e){tu(this._axisPointerModel,!e&&this._moveAnimation,this._handle,iu(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},_onHandleDragMove:function(t,e){var n=this._handle;if(n){this._dragging=!0;var i=this.updateHandleTransform(iu(n),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(iu(i)),Jw(n).lastProp=null,this._doDispatchAxisPointer()}},_doDispatchAxisPointer:function(){if(this._handle){var t=this._payloadInfo,e=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:e.axis.dim,axisIndex:e.componentIndex}]})}},_onHandleDragEnd:function(t){if(this._dragging=!1,this._handle){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},getHandleTransform:null,updateHandleTransform:null,clear:function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),n=this._group,i=this._handle;e&&n&&(this._lastGraphicKey=null,n&&e.remove(n),i&&e.remove(i),this._group=null,this._handle=null,this._payloadInfo=null)},doClear:function(){},buildLabel:function(t,e,n){return n=n||0,{x:t[n],y:t[1-n],width:e[n],height:e[1-n]}}}).constructor=Jh,En(Jh);var nb=Jh.extend({makeElOption:function(t,e,n,i,r){var o=n.axis,a=o.grid,s=i.get("type"),l=fu(a,o).getOtherAxis(o).getGlobalExtent(),h=o.toGlobalCoord(o.dataToCoord(e,!0));if(s&&"none"!==s){var u=ou(i),c=ib[s](o,h,l,u);c.style=u,t.graphicKey=c.type,t.pointer=c}uu(e,t,mh(a.model,n),n,i,r)},getHandleTransform:function(t,e,n){var i=mh(e.axis.grid.model,e,{labelInside:!1});return i.labelMargin=n.get("handle.margin"),{position:hu(e.axis,t,i),rotation:i.rotation+(i.labelDirection<0?Math.PI:0)}},updateHandleTransform:function(t,e,n,i){var r=n.axis,o=r.grid,a=r.getGlobalExtent(!0),s=fu(o,r).getOtherAxis(r).getGlobalExtent(),l="x"===r.dim?0:1,h=t.position;h[l]+=e[l],h[l]=Math.min(a[1],h[l]),h[l]=Math.max(a[0],h[l]);var u=(s[1]+s[0])/2,c=[u,u];c[l]=h[l];var d=[{verticalAlign:"middle"},{align:"center"}];return{position:h,rotation:t.rotation,cursorPoint:c,tooltipOption:d[l]}}}),ib={line:function(t,e,n,i){var r=cu([e,n[0]],[e,n[1]],pu(t));return zi({shape:r,style:i}),{type:"Line",shape:r}},shadow:function(t,e,n,i){var r=t.getBandWidth(),o=n[1]-n[0];return{type:"Rect",shape:du([e-r/2,n[0]],[r,o],pu(t))}}};Mw.registerAxisPointerClass("CartesianAxisPointer",nb),Ka(function(t){if(t){(!t.axisPointer||0===t.axisPointer.length)&&(t.axisPointer={});var e=t.axisPointer.link;e&&!y(e)&&(t.axisPointer.link=[e])}}),Qa(mx.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=ih(t,e)}),Ja({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},function(t,e,n){var i=t.currTrigger,r=[t.x,t.y],o=t,a=t.dispatchAction||m(n.dispatchAction,n),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){Uh(r)&&(r=Xw({seriesIndex:o.seriesIndex,dataIndex:o.dataIndex},e).point);var l=Uh(r),h=o.axesInfo,u=s.axesInfo,c="leave"===i||Uh(r),d={},f={},p={list:[],map:{}},g={showPointer:Yw(Bh,f),showTooltip:Yw(Vh,p)};jw(s.coordSysMap,function(t,e){var n=l||t.containPoint(r);jw(s.coordSysAxesInfo[e],function(t,e){var i=t.axis,o=Wh(h,t);if(!c&&n&&(!h||o)){var a=o&&o.value;null!=a||l||(a=i.pointToData(r)),null!=a&&Nh(t,a,g,!1,d)}})});var v={};return jw(u,function(t,e){var n=t.linkGroup;n&&!f[e]&&jw(n.axesInfo,function(e,i){var r=f[i];if(e!==t&&r){var o=r.value;n.mapper&&(o=t.axis.scale.parse(n.mapper(o,Zh(e),Zh(t)))),v[t.key]=o}})}),jw(v,function(t,e){Nh(u[e],t,g,!0,d)}),Fh(f,u,d),Hh(p,r,t,a),Gh(u,0,n),d}}),rs({type:"tooltip",dependencies:["axisPointer"],defaultOption:{zlevel:0,z:8,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",confine:!1,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"rgba(50,50,50,0.7)",borderColor:"#333",borderRadius:4,borderWidth:0,padding:5,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#fff",fontSize:14}}});var rb=d,ob=zr,ab=["","-webkit-","-moz-","-o-"];yu.prototype={constructor:yu,_enterable:!0,update:function(){var t=this._container,e=t.currentStyle||document.defaultView.getComputedStyle(t),n=t.style;"absolute"!==n.position&&"absolute"!==e.position&&(n.position="relative")},show:function(t){clearTimeout(this._hideTimeout);var e=this.el;e.style.cssText="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+vu(t)+";left:"+this._x+"px;top:"+this._y+"px;"+(t.get("extraCssText")||""),e.style.display=e.innerHTML?"block":"none",this._show=!0},setContent:function(t){this.el.innerHTML=null==t?"":t},setEnterable:function(t){this._enterable=t},getSize:function(){var t=this.el;return[t.clientWidth,t.clientHeight]},moveTo:function(t,e){var n,i=this._zr;i&&i.painter&&(n=i.painter.getViewportRootOffset())&&(t+=n.offsetLeft,e+=n.offsetTop);var r=this.el.style;r.left=t+"px",r.top=e+"px",this._x=t,this._y=e},hide:function(){this.el.style.display="none",this._show=!1},hideLater:function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(m(this.hide,this),t)):this.hide())},isShow:function(){return this._show}};var sb=m,lb=d,hb=_r,ub=new gv({shape:{x:-1,y:-1,width:2,height:2}});os({type:"tooltip",init:function(t,e){if(!Kf.node){var n=new yu(e.getDom(),e);this._tooltipContent=n}},render:function(t,e,n){if(!Kf.node&&!Kf.wxa){this.group.removeAll(),this._tooltipModel=t,this._ecModel=e,this._api=n,this._lastDataByCoordSys=null,this._alwaysShowContent=t.get("alwaysShowContent");var i=this._tooltipContent;i.update(),i.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow()}},_initGlobalListener:function(){var t=this._tooltipModel.get("triggerOn");Xh("itemTooltip",this._api,sb(function(e,n,i){"none"!==t&&(t.indexOf(e)>=0?this._tryShow(n,i):"leave"===e&&this._hide(i))},this))},_keepShow:function(){var t=this._tooltipModel,e=this._ecModel,n=this._api;if(null!=this._lastX&&null!=this._lastY&&"none"!==t.get("triggerOn")){var i=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){i.manuallyShowTip(t,e,n,{x:i._lastX,y:i._lastY})})}},manuallyShowTip:function(t,e,n,i){if(i.from!==this.uid&&!Kf.node){var r=_u(i,n);this._ticket="";var o=i.dataByCoordSys;if(i.tooltip&&null!=i.x&&null!=i.y){var a=ub;a.position=[i.x,i.y],a.update(),a.tooltip=i.tooltip,this._tryShow({offsetX:i.x,offsetY:i.y,target:a},r)}else if(o)this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,event:{},dataByCoordSys:i.dataByCoordSys,tooltipOption:i.tooltipOption},r);else if(null!=i.seriesIndex){if(this._manuallyAxisShowTip(t,e,n,i))return;var s=Xw(i,e),l=s.point[0],h=s.point[1];null!=l&&null!=h&&this._tryShow({offsetX:l,offsetY:h,position:i.position,target:s.el,event:{}},r)}else null!=i.x&&null!=i.y&&(n.dispatchAction({type:"updateAxisPointer",x:i.x,y:i.y}),this._tryShow({offsetX:i.x,offsetY:i.y,position:i.position,target:n.getZr().findHover(i.x,i.y).target,event:{}},r))}},manuallyHideTip:function(t,e,n,i){var r=this._tooltipContent;!this._alwaysShowContent&&this._tooltipModel&&r.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=null,i.from!==this.uid&&this._hide(_u(i,n))},_manuallyAxisShowTip:function(t,e,n,i){var r=i.seriesIndex,o=i.dataIndex,a=e.getComponent("axisPointer").coordSysAxesInfo;if(null!=r&&null!=o&&null!=a){var s=e.getSeriesByIndex(r);if(s&&"axis"===(t=xu([s.getData().getItemModel(o),s,(s.coordinateSystem||{}).model,t])).get("trigger"))return n.dispatchAction({type:"updateAxisPointer",seriesIndex:r,dataIndex:o,position:i.position}),!0}},_tryShow:function(t,e){var n=t.target;if(this._tooltipModel){this._lastX=t.offsetX,this._lastY=t.offsetY;var i=t.dataByCoordSys;i&&i.length?this._showAxisTooltip(i,t):n&&null!=n.dataIndex?(this._lastDataByCoordSys=null,this._showSeriesItemTooltip(t,n,e)):n&&n.tooltip?(this._lastDataByCoordSys=null,this._showComponentItemTooltip(t,n,e)):(this._lastDataByCoordSys=null,this._hide(e))}},_showOrMove:function(t,e){var n=t.get("showDelay");e=m(e,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(e,n):e()},_showAxisTooltip:function(t,e){var n=this._ecModel,i=this._tooltipModel,r=[e.offsetX,e.offsetY],o=[],a=[],s=xu([e.tooltipOption,i]);lb(t,function(t){lb(t.dataByAxis,function(t){var e=n.getComponent(t.axisDim+"Axis",t.axisIndex),i=t.value,r=[];if(e&&null!=i){var s=lu(i,e.axis,n,t.seriesDataIndices,t.valueLabelOpt);d(t.seriesDataIndices,function(o){var l=n.getSeriesByIndex(o.seriesIndex),h=o.dataIndexInside,u=l&&l.getDataParams(h);u.axisDim=t.axisDim,u.axisIndex=t.axisIndex,u.axisType=t.axisType,u.axisId=t.axisId,u.axisValue=Js(e.axis,i),u.axisValueLabel=s,u&&(a.push(u),r.push(l.formatTooltip(h,!0)))});var l=s;o.push((l?Er(l)+"<br />":"")+r.join("<br />"))}})},this),o.reverse(),o=o.join("<br /><br />");var l=e.position;this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(t)?this._updatePosition(s,l,r[0],r[1],this._tooltipContent,a):this._showTooltipContent(s,o,a,Math.random(),r[0],r[1],l)})},_showSeriesItemTooltip:function(t,e,n){var i=this._ecModel,r=e.seriesIndex,o=i.getSeriesByIndex(r),a=e.dataModel||o,s=e.dataIndex,l=e.dataType,h=a.getData(),u=xu([h.getItemModel(s),a,o&&(o.coordinateSystem||{}).model,this._tooltipModel]),c=u.get("trigger");if(null==c||"item"===c){var d=a.getDataParams(s,l),f=a.formatTooltip(s,!1,l),p="item_"+a.name+"_"+s;this._showOrMove(u,function(){this._showTooltipContent(u,f,d,p,t.offsetX,t.offsetY,t.position,t.target)}),n({type:"showTip",dataIndexInside:s,dataIndex:h.getRawIndex(s),seriesIndex:r,from:this.uid})}},_showComponentItemTooltip:function(t,e,n){var i=e.tooltip;if("string"==typeof i){var r=i;i={content:r,formatter:r}}var o=new pr(i,this._tooltipModel,this._ecModel),a=o.get("content"),s=Math.random();this._showOrMove(o,function(){this._showTooltipContent(o,a,o.get("formatterParams")||{},s,t.offsetX,t.offsetY,t.position,e)}),n({type:"showTip",from:this.uid})},_showTooltipContent:function(t,e,n,i,r,o,a,s){if(this._ticket="",t.get("showContent")&&t.get("show")){var l=this._tooltipContent,h=t.get("formatter");a=a||t.get("position");var u=e;if(h&&"string"==typeof h)u=Nr(h,n,!0);else if("function"==typeof h){var c=sb(function(e,i){e===this._ticket&&(l.setContent(i),this._updatePosition(t,a,r,o,l,n,s))},this);this._ticket=i,u=h(n,i,c)}l.setContent(u),l.show(t),this._updatePosition(t,a,r,o,l,n,s)}},_updatePosition:function(t,e,n,i,r,o,a){var s=this._api.getWidth(),l=this._api.getHeight();e=e||t.get("position");var h=r.getSize(),u=t.get("align"),c=t.get("verticalAlign"),d=a&&a.getBoundingRect().clone();if(a&&d.applyTransform(a.transform),"function"==typeof e&&(e=e([n,i],o,r.el,d,{viewSize:[s,l],contentSize:h.slice()})),y(e))n=hb(e[0],s),i=hb(e[1],l);else if(w(e)){e.width=h[0],e.height=h[1];var f=Gr(e,{width:s,height:l});n=f.x,i=f.y,u=null,c=null}else"string"==typeof e&&a?(n=(p=Mu(e,d,h))[0],i=p[1]):(n=(p=wu(n,i,r.el,s,l,u?null:20,c?null:20))[0],i=p[1]);if(u&&(n-=Iu(u)?h[0]/2:"right"===u?h[0]:0),c&&(i-=Iu(c)?h[1]/2:"bottom"===c?h[1]:0),t.get("confine")){var p=bu(n,i,r.el,s,l);n=p[0],i=p[1]}r.moveTo(n,i)},_updateContentNotChangedOnAxis:function(t){var e=this._lastDataByCoordSys,n=!!e&&e.length===t.length;return n&&lb(e,function(e,i){var r=e.dataByAxis||{},o=(t[i]||{}).dataByAxis||[];(n&=r.length===o.length)&&lb(r,function(t,e){var i=o[e]||{},r=t.seriesDataIndices||[],a=i.seriesDataIndices||[];(n&=t.value===i.value&&t.axisType===i.axisType&&t.axisId===i.axisId&&r.length===a.length)&&lb(r,function(t,e){var i=a[e];n&=t.seriesIndex===i.seriesIndex&&t.dataIndex===i.dataIndex})})}),this._lastDataByCoordSys=t,!!n},_hide:function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},dispose:function(t,e){Kf.node||(this._tooltipContent.hide(),Qh("itemTooltip",e))}}),Ja({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},function(){}),Ja({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},function(){});var cb=rs({type:"legend.plain",dependencies:["series"],layoutMode:{type:"box",ignoreSize:!0},init:function(t,e,n){this.mergeDefaultAndTheme(t,n),t.selected=t.selected||{}},mergeOption:function(t){cb.superCall(this,"mergeOption",t)},optionUpdated:function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&"single"===this.get("selectedMode")){for(var e=!1,n=0;n<t.length;n++){var i=t[n].get("name");if(this.isSelected(i)){this.select(i),e=!0;break}}!e&&this.select(t[0].get("name"))}},_updateData:function(t){var e=[],n=[];t.eachRawSeries(function(i){var r=i.name;n.push(r);var o;if(i.legendDataProvider){var a=i.legendDataProvider(),s=a.mapArray(a.getName);t.isSeriesFiltered(i)||(n=n.concat(s)),s.length?e=e.concat(s):o=!0}else o=!0;o&&In(i)&&e.push(i.name)}),this._availableNames=n;var i=f(this.get("data")||e,function(t){return"string"!=typeof t&&"number"!=typeof t||(t={name:t}),new pr(t,this,this.ecModel)},this);this._data=i},getData:function(){return this._data},select:function(t){var e=this.option.selected;"single"===this.get("selectedMode")&&d(this._data,function(t){e[t.get("name")]=!1}),e[t]=!0},unSelect:function(t){"single"!==this.get("selectedMode")&&(this.option.selected[t]=!1)},toggleSelected:function(t){var e=this.option.selected;e.hasOwnProperty(t)||(e[t]=!0),this[e[t]?"unSelect":"select"](t)},isSelected:function(t){var e=this.option.selected;return!(e.hasOwnProperty(t)&&!e[t])&&l(this._availableNames,t)>=0},defaultOption:{zlevel:0,z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,inactiveColor:"#ccc",textStyle:{color:"#333"},selectedMode:!0,tooltip:{show:!1}}});Ja("legendToggleSelect","legendselectchanged",v(Tu,"toggleSelected")),Ja("legendSelect","legendselected",v(Tu,"select")),Ja("legendUnSelect","legendunselected",v(Tu,"unSelect"));var db=v,fb=d,pb=Jp,gb=os({type:"legend.plain",newlineDisabled:!1,init:function(){this.group.add(this._contentGroup=new pb),this._backgroundEl},getContentGroup:function(){return this._contentGroup},render:function(t,e,n){if(this.resetInner(),t.get("show",!0)){var i=t.get("align");i&&"auto"!==i||(i="right"===t.get("left")&&"vertical"===t.get("orient")?"right":"left"),this.renderInner(i,t,e,n);var r=t.getBoxLayoutParams(),o={width:n.getWidth(),height:n.getHeight()},s=t.get("padding"),l=Gr(r,o,s),h=this.layoutInner(t,i,l),u=Gr(a({width:h.width,height:h.height},r),o,s);this.group.attr("position",[u.x-h.x,u.y-h.y]),this.group.add(this._backgroundEl=Du(h,t))}},resetInner:function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl)},renderInner:function(t,e,n,i){var r=this.getContentGroup(),o=N(),a=e.get("selectedMode");fb(e.getData(),function(s,l){var h=s.get("name");if(this.newlineDisabled||""!==h&&"\n"!==h){var u=n.getSeriesByName(h)[0];if(!o.get(h))if(u){var c=u.getData(),d=c.getVisual("color");"function"==typeof d&&(d=d(u.getDataParams(0)));var f=c.getVisual("legendSymbol")||"roundRect",p=c.getVisual("symbol");this._createItem(h,l,s,e,f,p,t,d,a).on("click",db(Au,h,i)).on("mouseover",db(ku,u,null,i)).on("mouseout",db(Pu,u,null,i)),o.set(h,!0)}else n.eachRawSeries(function(n){if(!o.get(h)&&n.legendDataProvider){var r=n.legendDataProvider(),u=r.indexOfName(h);if(u<0)return;var c=r.getItemVisual(u,"color");this._createItem(h,l,s,e,"roundRect",null,t,c,a).on("click",db(Au,h,i)).on("mouseover",db(ku,n,h,i)).on("mouseout",db(Pu,n,h,i)),o.set(h,!0)}},this)}else r.add(new pb({newline:!0}))},this)},_createItem:function(t,e,n,i,r,a,s,l,h){var u=i.get("itemWidth"),c=i.get("itemHeight"),d=i.get("inactiveColor"),f=i.isSelected(t),p=new pb,g=n.getModel("textStyle"),m=n.get("icon"),v=n.getModel("tooltip"),y=v.parentModel;if(r=m||r,p.add(el(r,0,0,u,c,f?l:d,!0)),!m&&a&&(a!==r||"none"==a)){var x=.8*c;"none"===a&&(a="circle"),p.add(el(a,(u-x)/2,(c-x)/2,x,x,f?l:d))}var _="left"===s?u+5:-5,w=s,b=i.get("formatter"),S=t;"string"==typeof b&&b?S=b.replace("{name}",null!=t?t:""):"function"==typeof b&&(S=b(t)),p.add(new ov({style:Ki({},g,{text:S,x:_,y:c/2,textFill:f?g.getTextColor():d,textAlign:w,textVerticalAlign:"middle"})}));var M=new gv({shape:p.getBoundingRect(),invisible:!0,tooltip:v.get("show")?o({content:t,formatter:y.get("formatter",!0)||function(){return t},formatterParams:{componentType:"legend",legendIndex:i.componentIndex,name:t,$vars:["name"]}},v.option):null});return p.add(M),p.eachChild(function(t){t.silent=!0}),M.silent=!h,this.getContentGroup().add(p),qi(p),p.__legendDataIndex=e,p},layoutInner:function(t,e,n){var i=this.getContentGroup();qv(t.get("orient"),i,t.get("itemGap"),n.width,n.height);var r=i.getBoundingRect();return i.attr("position",[-r.x,-r.y]),this.group.getBoundingRect()}});Qa(function(t){var e=t.findComponents({mainType:"legend"});e&&e.length&&t.filterSeries(function(t){for(var n=0;n<e.length;n++)if(!e[n].isSelected(t.name))return!1;return!0})}),Qv.registerSubTypeDefaulter("legend",function(){return"plain"});var mb=cb.extend({type:"legend.scroll",setScrollDataIndex:function(t){this.option.scrollDataIndex=t},defaultOption:{scrollDataIndex:0,pageButtonItemGap:5,pageButtonGap:null,pageButtonPosition:"end",pageFormatter:"{current}/{total}",pageIcons:{horizontal:["M0,0L12,-10L12,10z","M0,0L-12,-10L-12,10z"],vertical:["M0,0L20,0L10,-20z","M0,0L20,0L10,20z"]},pageIconColor:"#2f4554",pageIconInactiveColor:"#aaa",pageIconSize:15,pageTextStyle:{color:"#333"},animationDurationUpdate:800},init:function(t,e,n,i){var r=Ur(t);mb.superCall(this,"init",t,e,n,i),Lu(this,t,r)},mergeOption:function(t,e){mb.superCall(this,"mergeOption",t,e),Lu(this,this.option,t)},getOrient:function(){return"vertical"===this.get("orient")?{index:1,name:"vertical"}:{index:0,name:"horizontal"}}}),vb=Jp,yb=["width","height"],xb=["x","y"],_b=gb.extend({type:"legend.scroll",newlineDisabled:!0,init:function(){_b.superCall(this,"init"),this._currentIndex=0,this.group.add(this._containerGroup=new vb),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new vb),this._showController},resetInner:function(){_b.superCall(this,"resetInner"),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},renderInner:function(t,e,n,i){function r(t,n){var r=t+"DataIndex",l=fr(e.get("pageIcons",!0)[e.getOrient().name][n],{onclick:m(o._pageGo,o,r,e,i)},{x:-s[0]/2,y:-s[1]/2,width:s[0],height:s[1]});l.name=t,a.add(l)}var o=this;_b.superCall(this,"renderInner",t,e,n,i);var a=this._controllerGroup,s=e.get("pageIconSize",!0);y(s)||(s=[s,s]),r("pagePrev",0);var l=e.getModel("pageTextStyle");a.add(new ov({name:"pageText",style:{textFill:l.getTextColor(),font:l.getFont(),textVerticalAlign:"middle",textAlign:"center"},silent:!0})),r("pageNext",1)},layoutInner:function(t,e,n){var i=this.getContentGroup(),r=this._containerGroup,o=this._controllerGroup,a=t.getOrient().index,s=yb[a],l=yb[1-a],h=xb[1-a];qv(t.get("orient"),i,t.get("itemGap"),a?n.width:null,a?null:n.height),qv("horizontal",o,t.get("pageButtonItemGap",!0));var u=i.getBoundingRect(),c=o.getBoundingRect(),d=this._showController=u[s]>n[s],f=[-u.x,-u.y];f[a]=i.position[a];var p=[0,0],g=[-c.x,-c.y],m=C(t.get("pageButtonGap",!0),t.get("itemGap",!0));d&&("end"===t.get("pageButtonPosition",!0)?g[a]+=n[s]-c[s]:p[a]+=c[s]+m),g[1-a]+=u[l]/2-c[l]/2,i.attr("position",f),r.attr("position",p),o.attr("position",g);var v=this.group.getBoundingRect();if((v={x:0,y:0})[s]=d?n[s]:u[s],v[l]=Math.max(u[l],c[l]),v[h]=Math.min(0,c[h]+g[1-a]),r.__rectSize=n[s],d){var y={x:0,y:0};y[s]=Math.max(n[s]-c[s]-m,0),y[l]=v[l],r.setClipPath(new gv({shape:y})),r.__rectSize=y[s]}else o.eachChild(function(t){t.attr({invisible:!0,silent:!0})});var x=this._getPageInfo(t);return null!=x.pageIndex&&ar(i,{position:x.contentPosition},!!d&&t),this._updatePageInfoView(t,x),v},_pageGo:function(t,e,n){var i=this._getPageInfo(e)[t];null!=i&&n.dispatchAction({type:"legendScroll",scrollDataIndex:i,legendId:e.id})},_updatePageInfoView:function(t,e){var n=this._controllerGroup;d(["pagePrev","pageNext"],function(i){var r=null!=e[i+"DataIndex"],o=n.childOfName(i);o&&(o.setStyle("fill",r?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),o.cursor=r?"pointer":"default")});var i=n.childOfName("pageText"),r=t.get("pageFormatter"),o=e.pageIndex,a=null!=o?o+1:0,s=e.pageCount;i&&r&&i.setStyle("text",_(r)?r.replace("{current}",a).replace("{total}",s):r({current:a,total:s}))},_getPageInfo:function(t){function e(t){var e=t.getBoundingRect().clone();return e[f]+=t.position[u],e}var n,i,r,o,a=t.get("scrollDataIndex",!0),s=this.getContentGroup(),l=s.getBoundingRect(),h=this._containerGroup.__rectSize,u=t.getOrient().index,c=yb[u],d=yb[1-u],f=xb[u],p=s.position.slice();this._showController?s.eachChild(function(t){t.__legendDataIndex===a&&(o=t)}):o=s.childAt(0);var g=h?Math.ceil(l[c]/h):0;if(o){var m=o.getBoundingRect(),v=o.position[u]+m[f];p[u]=-v-l[f],n=Math.floor(g*(v+m[f]+h/2)/l[c]),n=l[c]&&g?Math.max(0,Math.min(g-1,n)):-1;var y={x:0,y:0};y[c]=h,y[d]=l[d],y[f]=-p[u]-l[f];var x,_=s.children();if(s.eachChild(function(t,n){var i=e(t);i.intersect(y)&&(null==x&&(x=n),r=t.__legendDataIndex),n===_.length-1&&i[f]+i[c]<=y[f]+y[c]&&(r=null)}),null!=x){var w=e(_[x]);if(y[f]=w[f]+w[c]-y[c],x<=0&&w[f]>=y[f])i=null;else{for(;x>0&&e(_[x-1]).intersect(y);)x--;i=_[x].__legendDataIndex}}}return{contentPosition:p,pageIndex:n,pageCount:g,pagePrevDataIndex:i,pageNextDataIndex:r}}});Ja("legendScroll","legendscroll",function(t,e){var n=t.scrollDataIndex;null!=n&&e.eachComponent({mainType:"legend",subType:"scroll",query:t},function(t){t.setScrollDataIndex(n)})}),rs({type:"title",layoutMode:{type:"box",ignoreSize:!0},defaultOption:{zlevel:0,z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:0,top:0,backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bolder",color:"#333"},subtextStyle:{color:"#aaa"}}}),os({type:"title",render:function(t,e,n){if(this.group.removeAll(),t.get("show")){var i=this.group,r=t.getModel("textStyle"),o=t.getModel("subtextStyle"),a=t.get("textAlign"),s=t.get("textBaseline"),l=new ov({style:Ki({},r,{text:t.get("text"),textFill:r.getTextColor()},{disableBox:!0}),z2:10}),h=l.getBoundingRect(),u=t.get("subtext"),c=new ov({style:Ki({},o,{text:u,textFill:o.getTextColor(),y:h.height+t.get("itemGap"),textVerticalAlign:"top"},{disableBox:!0}),z2:10}),d=t.get("link"),f=t.get("sublink");l.silent=!d,c.silent=!f,d&&l.on("click",function(){window.open(d,"_"+t.get("target"))}),f&&c.on("click",function(){window.open(f,"_"+t.get("subtarget"))}),i.add(l),u&&i.add(c);var p=i.getBoundingRect(),g=t.getBoxLayoutParams();g.width=p.width,g.height=p.height;var m=Gr(g,{width:n.getWidth(),height:n.getHeight()},t.get("padding"));a||("middle"===(a=t.get("left")||t.get("right"))&&(a="center"),"right"===a?m.x+=m.width:"center"===a&&(m.x+=m.width/2)),s||("center"===(s=t.get("top")||t.get("bottom"))&&(s="middle"),"bottom"===s?m.y+=m.height:"middle"===s&&(m.y+=m.height/2),s=s||"top"),i.attr("position",[m.x,m.y]);var v={textAlign:a,textVerticalAlign:s};l.setStyle(v),c.setStyle(v),p=i.getBoundingRect();var y=m.margin,x=t.getItemStyle(["color","opacity"]);x.fill=t.get("backgroundColor");var _=new gv({shape:{x:p.x-y[3],y:p.y-y[0],width:p.width+y[1]+y[3],height:p.height+y[0]+y[2],r:t.get("borderRadius")},style:x,silent:!0});Ei(_),i.add(_)}}});var wb=Or,bb=Er,Sb=rs({type:"marker",dependencies:["series","grid","polar","geo"],init:function(t,e,n,i){this.mergeDefaultAndTheme(t,n),this.mergeOption(t,n,i.createdBySelf,!0)},isAnimationEnabled:function(){if(Kf.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnabled()},mergeOption:function(t,e,n,i){var r=this.constructor,a=this.mainType+"Model";n||e.eachSeries(function(t){var n=t.get(this.mainType),s=t[a];n&&n.data?(s?s.mergeOption(n,e,!0):(i&&Ou(n),d(n.data,function(t){t instanceof Array?(Ou(t[0]),Ou(t[1])):Ou(t)}),o(s=new r(n,this,e),{mainType:this.mainType,seriesIndex:t.seriesIndex,name:t.name,createdBySelf:!0}),s.__hostSeries=t),t[a]=s):t[a]=null},this)},formatTooltip:function(t){var e=this.getData(),n=this.getRawValue(t),i=y(n)?f(n,wb).join(", "):wb(n),r=e.getName(t),o=bb(this.name);return(null!=n||r)&&(o+="<br />"),r&&(o+=bb(r),null!=n&&(o+=" : ")),null!=n&&(o+=bb(i)),o},getData:function(){return this._data},setData:function(t){this._data=t}});u(Sb,zy),Sb.extend({type:"markPoint",defaultOption:{zlevel:0,z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}}});var Mb=l,Ib=v,Tb={min:Ib(Nu,"min"),max:Ib(Nu,"max"),average:Ib(Nu,"average")},Cb=os({type:"marker",init:function(){this.markerGroupMap=N()},render:function(t,e,n){var i=this.markerGroupMap;i.each(function(t){t.__keep=!1});var r=this.type+"Model";e.eachSeries(function(t){var i=t[r];i&&this.renderSeries(t,i,e,n)},this),i.each(function(t){!t.__keep&&this.group.remove(t.group)},this)},renderSeries:function(){}});Cb.extend({type:"markPoint",updateTransform:function(t,e,n){e.eachSeries(function(t){var e=t.markPointModel;e&&(Wu(e.getData(),t,n),this.markerGroupMap.get(t.id).updateLayout(e))},this)},renderSeries:function(t,e,n,i){var r=t.coordinateSystem,o=t.id,a=t.getData(),s=this.markerGroupMap,l=s.get(o)||s.set(o,new fl),h=Zu(r,t,e);e.setData(h),Wu(e.getData(),t,i),h.each(function(t){var n=h.getItemModel(t),i=n.getShallow("symbolSize");"function"==typeof i&&(i=i(e.getRawValue(t),e.getDataParams(t))),h.setItemVisual(t,{symbolSize:i,color:n.get("itemStyle.color")||a.getVisual("color"),symbol:n.getShallow("symbol")})}),l.updateData(h),this.group.add(l.group),h.eachItemGraphicEl(function(t){t.traverse(function(t){t.dataModel=e})}),l.__keep=!0,l.group.silent=e.get("silent")||t.get("silent")}}),Ka(function(t){t.markPoint=t.markPoint||{}}),Sb.extend({type:"markLine",defaultOption:{zlevel:0,z:5,symbol:["circle","arrow"],symbolSize:[8,16],precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end"},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"}});var Db=mv.prototype,Ab=yv.prototype,kb=Ai({type:"ec-line",style:{stroke:"#000",fill:null},shape:{x1:0,y1:0,x2:0,y2:0,percent:1,cpx1:null,cpy1:null},buildPath:function(t,e){(Uu(e)?Db:Ab).buildPath(t,e)},pointAt:function(t){return Uu(this.shape)?Db.pointAt.call(this,t):Ab.pointAt.call(this,t)},tangentAt:function(t){var e=this.shape,n=Uu(e)?[e.x2-e.x1,e.y2-e.y1]:Ab.tangentAt.call(this,t);return j(n,n)}}),Pb=["fromSymbol","toSymbol"],Lb=$u.prototype;Lb.beforeUpdate=function(){var t=this,e=t.childOfName("fromSymbol"),n=t.childOfName("toSymbol"),i=t.childOfName("label");if(e||n||!i.ignore){for(var r=1,o=this.parent;o;)o.scale&&(r/=o.scale[0]),o=o.parent;var a=t.childOfName("line");if(this.__dirty||a.__dirty){var s=a.shape.percent,l=a.pointAt(0),h=a.pointAt(s),u=W([],h,l);if(j(u,u),e&&(e.attr("position",l),c=a.tangentAt(0),e.attr("rotation",Math.PI/2-Math.atan2(c[1],c[0])),e.attr("scale",[r*s,r*s])),n){n.attr("position",h);var c=a.tangentAt(1);n.attr("rotation",-Math.PI/2-Math.atan2(c[1],c[0])),n.attr("scale",[r*s,r*s])}if(!i.ignore){i.attr("position",h);var d,f,p,g=5*r;if("end"===i.__position)d=[u[0]*g+h[0],u[1]*g+h[1]],f=u[0]>.8?"left":u[0]<-.8?"right":"center",p=u[1]>.8?"top":u[1]<-.8?"bottom":"middle";else if("middle"===i.__position){var m=s/2,v=[(c=a.tangentAt(m))[1],-c[0]],y=a.pointAt(m);v[1]>0&&(v[0]=-v[0],v[1]=-v[1]),d=[y[0]+v[0]*g,y[1]+v[1]*g],f="center",p="bottom";var x=-Math.atan2(c[1],c[0]);h[0]<l[0]&&(x=Math.PI+x),i.attr("rotation",x)}else d=[-u[0]*g+l[0],-u[1]*g+l[1]],f=u[0]>.8?"right":u[0]<-.8?"left":"center",p=u[1]>.8?"bottom":u[1]<-.8?"top":"middle";i.attr({style:{textVerticalAlign:i.__verticalAlign||p,textAlign:i.__textAlign||f},position:d,scale:[r,r]})}}}},Lb._createLine=function(t,e,n){var i=t.hostModel,r=Yu(t.getItemLayout(e));r.shape.percent=0,sr(r,{shape:{percent:1}},i,e),this.add(r);var o=new ov({name:"label"});this.add(o),d(Pb,function(n){var i=ju(n,t,e);this.add(i),this[Xu(n)]=t.getItemVisual(e,n)},this),this._updateCommonStl(t,e,n)},Lb.updateData=function(t,e,n){var i=t.hostModel,r=this.childOfName("line"),o=t.getItemLayout(e),a={shape:{}};qu(a.shape,o),ar(r,a,i,e),d(Pb,function(n){var i=t.getItemVisual(e,n),r=Xu(n);if(this[r]!==i){this.remove(this.childOfName(n));var o=ju(n,t,e);this.add(o)}this[r]=i},this),this._updateCommonStl(t,e,n)},Lb._updateCommonStl=function(t,e,n){var i=t.hostModel,r=this.childOfName("line"),o=n&&n.lineStyle,s=n&&n.hoverLineStyle,l=n&&n.labelModel,h=n&&n.hoverLabelModel;if(!n||t.hasItemOption){var u=t.getItemModel(e);o=u.getModel("lineStyle").getLineStyle(),s=u.getModel("emphasis.lineStyle").getLineStyle(),l=u.getModel("label"),h=u.getModel("emphasis.label")}var c=t.getItemVisual(e,"color"),f=D(t.getItemVisual(e,"opacity"),o.opacity,1);r.useStyle(a({strokeNoScale:!0,fill:"none",stroke:c,opacity:f},o)),r.hoverStyle=s,d(Pb,function(t){var e=this.childOfName(t);e&&(e.setColor(c),e.setStyle({opacity:f}))},this);var p,g,m,v=l.getShallow("show"),y=h.getShallow("show"),x=this.childOfName("label");if(v||y){if(p=c||"#000",null==(g=i.getFormattedLabel(e,"normal",t.dataType))){var _=i.getRawValue(e);g=null==_?t.getName(e):isFinite(_)?wr(_):_}m=C(i.getFormattedLabel(e,"emphasis",t.dataType),g)}if(v){var w=Ki(x.style,l,{text:g},{autoColor:p});x.__textAlign=w.textAlign,x.__verticalAlign=w.textVerticalAlign,x.__position=l.get("position")||"middle"}else x.setStyle("text",null);x.hoverStyle=y?{text:m,textFill:h.getTextColor(!0),fontStyle:h.getShallow("fontStyle"),fontWeight:h.getShallow("fontWeight"),fontSize:h.getShallow("fontSize"),fontFamily:h.getShallow("fontFamily")}:{text:null},x.ignore=!v&&!y,qi(this)},Lb.highlight=function(){this.trigger("emphasis")},Lb.downplay=function(){this.trigger("normal")},Lb.updateLayout=function(t,e){this.setLinePoints(t.getItemLayout(e))},Lb.setLinePoints=function(t){var e=this.childOfName("line");qu(e.shape,t),e.dirty()},h($u,Jp);var Ob=Ku.prototype;Ob.isPersistent=function(){return!0},Ob.updateData=function(t){var e=this,n=e.group,i=e._lineData;e._lineData=t,i||n.removeAll();var r=tc(t);t.diff(i).add(function(n){Qu(e,t,n,r)}).update(function(n,o){Ju(e,i,t,o,n,r)}).remove(function(t){n.remove(i.getItemGraphicEl(t))}).execute()},Ob.updateLayout=function(){var t=this._lineData;t.eachItemGraphicEl(function(e,n){e.updateLayout(t,n)},this)},Ob.incrementalPrepareUpdate=function(t){this._seriesScope=tc(t),this._lineData=null,this.group.removeAll()},Ob.incrementalUpdate=function(t,e){for(var n=t.start;n<t.end;n++)if(nc(e.getItemLayout(n))){var i=new this._ctor(e,n,this._seriesScope);i.traverse(function(t){t.isGroup||(t.incremental=t.useHoverLayer=!0)}),this.group.add(i)}},Ob.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},Ob._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()};var zb=function(t,e,r,a){var s=t.getData(),l=a.type;if(!y(a)&&("min"===l||"max"===l||"average"===l||null!=a.xAxis||null!=a.yAxis)){var h,u;if(null!=a.yAxis||null!=a.xAxis)h=null!=a.yAxis?"y":"x",e.getAxis(h),u=T(a.yAxis,a.xAxis);else{var c=Bu(a,s,e,t);h=c.valueDataDim,c.valueAxis,u=Gu(s,h,l)}var d="x"===h?0:1,f=1-d,p=n(a),g={};p.type=null,p.coord=[],g.coord=[],p.coord[f]=-1/0,g.coord[f]=1/0;var m=r.get("precision");m>=0&&"number"==typeof u&&(u=+u.toFixed(Math.min(m,20))),p.coord[d]=g.coord[d]=u,a=[p,g,{type:l,valueIndex:a.valueIndex,value:u}]}return a=[Ru(t,a[0]),Ru(t,a[1]),o({},a[2])],a[2].type=a[2].type||"",i(a[2],a[0]),i(a[2],a[1]),a};Cb.extend({type:"markLine",updateTransform:function(t,e,n){e.eachSeries(function(t){var e=t.markLineModel;if(e){var i=e.getData(),r=e.__from,o=e.__to;r.each(function(e){ac(r,e,!0,t,n),ac(o,e,!1,t,n)}),i.each(function(t){i.setItemLayout(t,[r.getItemLayout(t),o.getItemLayout(t)])}),this.markerGroupMap.get(t.id).updateLayout()}},this)},renderSeries:function(t,e,n,i){function r(e,n,r){var o=e.getItemModel(n);ac(e,n,r,t,i),e.setItemVisual(n,{symbolSize:o.get("symbolSize")||g[r?0:1],symbol:o.get("symbol",!0)||p[r?0:1],color:o.get("itemStyle.color")||s.getVisual("color")})}var o=t.coordinateSystem,a=t.id,s=t.getData(),l=this.markerGroupMap,h=l.get(a)||l.set(a,new Ku);this.group.add(h.group);var u=sc(o,t,e),c=u.from,d=u.to,f=u.line;e.__from=c,e.__to=d,e.setData(f);var p=e.get("symbol"),g=e.get("symbolSize");y(p)||(p=[p,p]),"number"==typeof g&&(g=[g,g]),u.from.each(function(t){r(c,t,!0),r(d,t,!1)}),f.each(function(t){var e=f.getItemModel(t).get("lineStyle.color");f.setItemVisual(t,{color:e||c.getItemVisual(t,"color")}),f.setItemLayout(t,[c.getItemLayout(t),d.getItemLayout(t)]),f.setItemVisual(t,{fromSymbolSize:c.getItemVisual(t,"symbolSize"),fromSymbol:c.getItemVisual(t,"symbol"),toSymbolSize:d.getItemVisual(t,"symbolSize"),toSymbol:d.getItemVisual(t,"symbol")})}),h.updateData(f),u.line.eachItemGraphicEl(function(t,n){t.traverse(function(t){t.dataModel=e})}),h.__keep=!0,h.group.silent=e.get("silent")||t.get("silent")}}),Ka(function(t){t.markLine=t.markLine||{}}),Sb.extend({type:"markArea",defaultOption:{zlevel:0,z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}}});var Eb=function(t,e,n,i){var o=Ru(t,i[0]),a=Ru(t,i[1]),s=T,l=o.coord,h=a.coord;l[0]=s(l[0],-1/0),l[1]=s(l[1],-1/0),h[0]=s(h[0],1/0),h[1]=s(h[1],1/0);var u=r([{},o,a]);return u.coord=[o.coord,a.coord],u.x0=o.x,u.y0=o.y,u.x1=a.x,u.y1=a.y,u},Nb=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]];Cb.extend({type:"markArea",updateTransform:function(t,e,n){e.eachSeries(function(t){var e=t.markAreaModel;if(e){var i=e.getData();i.each(function(e){var r=f(Nb,function(r){return cc(i,e,r,t,n)});i.setItemLayout(e,r),i.getItemGraphicEl(e).setShape("points",r)})}},this)},renderSeries:function(t,e,n,i){var r=t.coordinateSystem,o=t.name,s=t.getData(),l=this.markerGroupMap,h=l.get(o)||l.set(o,{group:new Jp});this.group.add(h.group),h.__keep=!0;var u=dc(r,t,e);e.setData(u),u.each(function(e){u.setItemLayout(e,f(Nb,function(n){return cc(u,e,n,t,i)})),u.setItemVisual(e,{color:s.getVisual("color")})}),u.diff(h.__data).add(function(t){var e=new fv({shape:{points:u.getItemLayout(t)}});u.setItemGraphicEl(t,e),h.group.add(e)}).update(function(t,n){var i=h.__data.getItemGraphicEl(n);ar(i,{shape:{points:u.getItemLayout(t)}},e,t),h.group.add(i),u.setItemGraphicEl(t,i)}).remove(function(t){var e=h.__data.getItemGraphicEl(t);h.group.remove(e)}).execute(),u.eachItemGraphicEl(function(t,n){var i=u.getItemModel(n),r=i.getModel("label"),o=i.getModel("emphasis.label"),s=u.getItemVisual(n,"color");t.useStyle(a(i.getModel("itemStyle").getItemStyle(),{fill:Pt(s,.4),stroke:s})),t.hoverStyle=i.getModel("emphasis.itemStyle").getItemStyle(),$i(t.style,t.hoverStyle,r,o,{labelFetcher:e,labelDataIndex:n,defaultText:u.getName(n)||"",isRectText:!0,autoColor:s}),qi(t,{}),t.dataModel=e}),h.__data=u,h.group.silent=e.get("silent")||t.get("silent")}}),Ka(function(t){t.markArea=t.markArea||{}}),Qv.registerSubTypeDefaulter("dataZoom",function(){return"slider"});var Rb=["cartesian2d","polar","singleAxis"],Bb=function(t,e){var n=f(t=t.slice(),Fr),i=f(e=(e||[]).slice(),Fr);return function(r,o){d(t,function(t,a){for(var s={name:t,capital:n[a]},l=0;l<e.length;l++)s[e[l]]=t+i[l];r.call(o,s)})}}(["x","y","z","radius","angle","single"],["axisIndex","axis","index","id"]),Vb=d,Fb=br,Hb=function(t,e,n,i){this._dimName=t,this._axisIndex=e,this._valueWindow,this._percentWindow,this._dataExtent,this._minMaxSpan,this.ecModel=i,this._dataZoomModel=n};Hb.prototype={constructor:Hb,hostedBy:function(t){return this._dataZoomModel===t},getDataValueWindow:function(){return this._valueWindow.slice()},getDataPercentWindow:function(){return this._percentWindow.slice()},getTargetSeriesModels:function(){var t=[],e=this.ecModel;return e.eachSeries(function(n){if(fc(n.get("coordinateSystem"))){var i=this._dimName,r=e.queryComponents({mainType:i+"Axis",index:n.get(i+"AxisIndex"),id:n.get(i+"AxisId")})[0];this._axisIndex===(r&&r.componentIndex)&&t.push(n)}},this),t},getAxisModel:function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},getOtherAxisModel:function(){var t,e,n=this._dimName,i=this.ecModel,r=this.getAxisModel();"x"===n||"y"===n?(e="gridIndex",t="x"===n?"y":"x"):(e="polarIndex",t="angle"===n?"radius":"angle");var o;return i.eachComponent(t+"Axis",function(t){(t.get(e)||0)===(r.get(e)||0)&&(o=t)}),o},getMinMaxSpan:function(){return n(this._minMaxSpan)},calculateDataWindow:function(t){var e=this._dataExtent,n=this.getAxisModel().axis.scale,i=this._dataZoomModel.getRangePropMode(),r=[0,100],o=[t.start,t.end],a=[];return Vb(["startValue","endValue"],function(e){a.push(null!=t[e]?n.parse(t[e]):null)}),Vb([0,1],function(t){var s=a[t],l=o[t];"percent"===i[t]?(null==l&&(l=r[t]),s=n.parse(xr(l,r,e,!0))):l=xr(s,e,r,!0),a[t]=s,o[t]=l}),{valueWindow:Fb(a),percentWindow:Fb(o)}},reset:function(t){if(t===this._dataZoomModel){var e=this.getTargetSeriesModels();this._dataExtent=gc(this,this._dimName,e);var n=this.calculateDataWindow(t.option);this._valueWindow=n.valueWindow,this._percentWindow=n.percentWindow,yc(this),vc(this)}},restore:function(t){t===this._dataZoomModel&&(this._valueWindow=this._percentWindow=null,vc(this,!0))},filterData:function(t,e){function n(t){return t>=a[0]&&t<=a[1]}if(t===this._dataZoomModel){var i=this._dimName,r=this.getTargetSeriesModels(),o=t.get("filterMode"),a=this._valueWindow;"none"!==o&&Vb(r,function(t){var e=t.getData(),r=e.mapDimension(i,!0);"weakFilter"===o?e.filterSelf(function(t){for(var n,i,o,s=0;s<r.length;s++){var l=e.get(r[s],t),h=!isNaN(l),u=l<a[0],c=l>a[1];if(h&&!u&&!c)return!0;h&&(o=!0),u&&(n=!0),c&&(i=!0)}return o&&n&&i}):Vb(r,function(i){if("empty"===o)t.setData(e.map(i,function(t){return n(t)?t:NaN}));else{var r={};r[i]=a,e.selectRange(r)}}),Vb(r,function(t){e.setApproximateExtent(a,t)})})}}};var Gb=d,Wb=Bb,Zb=rs({type:"dataZoom",dependencies:["xAxis","yAxis","zAxis","radiusAxis","angleAxis","singleAxis","series"],defaultOption:{zlevel:0,z:4,orient:null,xAxisIndex:null,yAxisIndex:null,filterMode:"filter",throttle:null,start:0,end:100,startValue:null,endValue:null,minSpan:null,maxSpan:null,minValueSpan:null,maxValueSpan:null,rangeMode:null},init:function(t,e,n){this._dataIntervalByAxis={},this._dataInfo={},this._axisProxies={},this.textStyleModel,this._autoThrottle=!0,this._rangePropMode=["percent","percent"];var i=xc(t);this.mergeDefaultAndTheme(t,n),this.doInit(i)},mergeOption:function(t){var e=xc(t);i(this.option,t,!0),this.doInit(e)},doInit:function(t){var e=this.option;Kf.canvasSupported||(e.realtime=!1),this._setDefaultThrottle(t),_c(this,t),Gb([["start","startValue"],["end","endValue"]],function(t,n){"value"===this._rangePropMode[n]&&(e[t[0]]=null)},this),this.textStyleModel=this.getModel("textStyle"),this._resetTarget(),this._giveAxisProxies()},_giveAxisProxies:function(){var t=this._axisProxies;this.eachTargetAxis(function(e,n,i,r){var o=this.dependentModels[e.axis][n],a=o.__dzAxisProxy||(o.__dzAxisProxy=new Hb(e.name,n,this,r));t[e.name+"_"+n]=a},this)},_resetTarget:function(){var t=this.option,e=this._judgeAutoMode();Wb(function(e){var n=e.axisIndex;t[n]=xn(t[n])},this),"axisIndex"===e?this._autoSetAxisIndex():"orient"===e&&this._autoSetOrient()},_judgeAutoMode:function(){var t=this.option,e=!1;Wb(function(n){null!=t[n.axisIndex]&&(e=!0)},this);var n=t.orient;return null==n&&e?"orient":e?void 0:(null==n&&(t.orient="horizontal"),"axisIndex")},_autoSetAxisIndex:function(){var t=!0,e=this.get("orient",!0),n=this.option,i=this.dependentModels;if(t){var r="vertical"===e?"y":"x";i[r+"Axis"].length?(n[r+"AxisIndex"]=[0],t=!1):Gb(i.singleAxis,function(i){t&&i.get("orient",!0)===e&&(n.singleAxisIndex=[i.componentIndex],t=!1)})}t&&Wb(function(e){if(t){var i=[],r=this.dependentModels[e.axis];if(r.length&&!i.length)for(var o=0,a=r.length;o<a;o++)"category"===r[o].get("type")&&i.push(o);n[e.axisIndex]=i,i.length&&(t=!1)}},this),t&&this.ecModel.eachSeries(function(t){this._isSeriesHasAllAxesTypeOf(t,"value")&&Wb(function(e){var i=n[e.axisIndex],r=t.get(e.axisIndex),o=t.get(e.axisId);l(i,r=t.ecModel.queryComponents({mainType:e.axis,index:r,id:o})[0].componentIndex)<0&&i.push(r)})},this)},_autoSetOrient:function(){var t;this.eachTargetAxis(function(e){!t&&(t=e.name)},this),this.option.orient="y"===t?"vertical":"horizontal"},_isSeriesHasAllAxesTypeOf:function(t,e){var n=!0;return Wb(function(i){var r=t.get(i.axisIndex),o=this.dependentModels[i.axis][r];o&&o.get("type")===e||(n=!1)},this),n},_setDefaultThrottle:function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var e=this.ecModel.option;this.option.throttle=e.animation&&e.animationDurationUpdate>0?100:20}},getFirstTargetAxisModel:function(){var t;return Wb(function(e){if(null==t){var n=this.get(e.axisIndex);n.length&&(t=this.dependentModels[e.axis][n[0]])}},this),t},eachTargetAxis:function(t,e){var n=this.ecModel;Wb(function(i){Gb(this.get(i.axisIndex),function(r){t.call(e,i,r,this,n)},this)},this)},getAxisProxy:function(t,e){return this._axisProxies[t+"_"+e]},getAxisModel:function(t,e){var n=this.getAxisProxy(t,e);return n&&n.getAxisModel()},setRawRange:function(t,e){var n=this.option;Gb([["start","startValue"],["end","endValue"]],function(e){null==t[e[0]]&&null==t[e[1]]||(n[e[0]]=t[e[0]],n[e[1]]=t[e[1]])},this),!e&&_c(this,t)},getPercentRange:function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},getValueRange:function(t,e){if(null!=t||null!=e)return this.getAxisProxy(t,e).getDataValueWindow();var n=this.findRepresentativeAxisProxy();return n?n.getDataValueWindow():void 0},findRepresentativeAxisProxy:function(t){if(t)return t.__dzAxisProxy;var e=this._axisProxies;for(var n in e)if(e.hasOwnProperty(n)&&e[n].hostedBy(this))return e[n];for(var n in e)if(e.hasOwnProperty(n)&&!e[n].hostedBy(this))return e[n]},getRangePropMode:function(){return this._rangePropMode.slice()}}),Ub=By.extend({type:"dataZoom",render:function(t,e,n,i){this.dataZoomModel=t,this.ecModel=e,this.api=n},getTargetCoordInfo:function(){function t(t,e,n,i){for(var r,o=0;o<n.length;o++)if(n[o].model===t){r=n[o];break}r||n.push(r={model:t,axisModels:[],coordIndex:i}),r.axisModels.push(e)}var e=this.dataZoomModel,n=this.ecModel,i={};return e.eachTargetAxis(function(e,r){var o=n.getComponent(e.axis,r);if(o){var a=o.getCoordSysModel();a&&t(a,o,i[a.mainType]||(i[a.mainType]=[]),a.componentIndex)}},this),i}}),Xb=(Zb.extend({type:"dataZoom.slider",layoutMode:"box",defaultOption:{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#2f4554",width:.5,opacity:.3},areaStyle:{color:"rgba(47,69,84,0.3)",opacity:.3}},borderColor:"#ddd",fillerColor:"rgba(167,183,204,0.4)",handleIcon:"M8.2,13.6V3.9H6.3v9.7H3.1v14.9h3.3v9.7h1.8v-9.7h3.3V13.6H8.2z M9.7,24.4H4.8v-1.4h4.9V24.4z M9.7,19.1H4.8v-1.4h4.9V19.1z",handleSize:"100%",handleStyle:{color:"#a7b7cc"},labelPrecision:null,labelFormatter:null,showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#333"}}}),function(t,e,n,i,r,o){e[0]=bc(e[0],n),e[1]=bc(e[1],n),t=t||0;var a=n[1]-n[0];null!=r&&(r=bc(r,[0,a])),null!=o&&(o=Math.max(o,null!=r?r:0)),"all"===i&&(r=o=Math.abs(e[1]-e[0]),i=0);var s=wc(e,i);e[i]+=t;var l=r||0,h=n.slice();s.sign<0?h[0]+=l:h[1]-=l,e[i]=bc(e[i],h);u=wc(e,i);null!=r&&(u.sign!==s.sign||u.span<r)&&(e[1-i]=e[i]+s.sign*r);var u=wc(e,i);return null!=o&&u.span>o&&(e[1-i]=e[i]+u.sign*o),e}),jb=gv,Yb=xr,qb=br,$b=m,Kb=d,Qb="horizontal",Jb=5,tS=["line","bar","candlestick","scatter"],eS=Ub.extend({type:"dataZoom.slider",init:function(t,e){this._displayables={},this._orient,this._range,this._handleEnds,this._size,this._handleWidth,this._handleHeight,this._location,this._dragging,this._dataShadowInfo,this.api=e},render:function(t,e,n,i){eS.superApply(this,"render",arguments),ha(this,"_dispatchZoomAction",this.dataZoomModel.get("throttle"),"fixRate"),this._orient=t.get("orient"),!1!==this.dataZoomModel.get("show")?(i&&"dataZoom"===i.type&&i.from===this.uid||this._buildView(),this._updateView()):this.group.removeAll()},remove:function(){eS.superApply(this,"remove",arguments),ua(this,"_dispatchZoomAction")},dispose:function(){eS.superApply(this,"dispose",arguments),ua(this,"_dispatchZoomAction")},_buildView:function(){var t=this.group;t.removeAll(),this._resetLocation(),this._resetInterval();var e=this._displayables.barGroup=new Jp;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(e),this._positionGroup()},_resetLocation:function(){var t=this.dataZoomModel,e=this.api,n=this._findCoordRect(),i={width:e.getWidth(),height:e.getHeight()},r=this._orient===Qb?{right:i.width-n.x-n.width,top:i.height-30-7,width:n.width,height:30}:{right:7,top:n.y,width:30,height:n.height},o=Ur(t.option);d(["right","top","width","height"],function(t){"ph"===o[t]&&(o[t]=r[t])});var a=Gr(o,i,t.padding);this._location={x:a.x,y:a.y},this._size=[a.width,a.height],"vertical"===this._orient&&this._size.reverse()},_positionGroup:function(){var t=this.group,e=this._location,n=this._orient,i=this.dataZoomModel.getFirstTargetAxisModel(),r=i&&i.get("inverse"),o=this._displayables.barGroup,a=(this._dataShadowInfo||{}).otherAxisInverse;o.attr(n!==Qb||r?n===Qb&&r?{scale:a?[-1,1]:[-1,-1]}:"vertical"!==n||r?{scale:a?[-1,-1]:[-1,1],rotation:Math.PI/2}:{scale:a?[1,-1]:[1,1],rotation:Math.PI/2}:{scale:a?[1,1]:[1,-1]});var s=t.getBoundingRect([o]);t.attr("position",[e.x-s.x,e.y-s.y])},_getViewExtent:function(){return[0,this._size[0]]},_renderBackground:function(){var t=this.dataZoomModel,e=this._size,n=this._displayables.barGroup;n.add(new jb({silent:!0,shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:t.get("backgroundColor")},z2:-40})),n.add(new jb({shape:{x:0,y:0,width:e[0],height:e[1]},style:{fill:"transparent"},z2:0,onclick:m(this._onClickPanelClick,this)}))},_renderDataShadow:function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(t){var e=this._size,n=t.series,i=n.getRawData(),r=n.getShadowDim?n.getShadowDim():t.otherDim;if(null!=r){var o=i.getDataExtent(r),s=.3*(o[1]-o[0]);o=[o[0]-s,o[1]+s];var l,h=[0,e[1]],u=[0,e[0]],c=[[e[0],0],[0,0]],d=[],f=u[1]/(i.count()-1),p=0,g=Math.round(i.count()/e[0]);i.each([r],function(t,e){if(g>0&&e%g)p+=f;else{var n=null==t||isNaN(t)||""===t,i=n?0:Yb(t,o,h,!0);n&&!l&&e?(c.push([c[c.length-1][0],0]),d.push([d[d.length-1][0],0])):!n&&l&&(c.push([p,0]),d.push([p,0])),c.push([p,i]),d.push([p,i]),p+=f,l=n}});var m=this.dataZoomModel;this._displayables.barGroup.add(new fv({shape:{points:c},style:a({fill:m.get("dataBackgroundColor")},m.getModel("dataBackground.areaStyle").getAreaStyle()),silent:!0,z2:-20})),this._displayables.barGroup.add(new pv({shape:{points:d},style:m.getModel("dataBackground.lineStyle").getLineStyle(),silent:!0,z2:-19}))}}},_prepareDataShadowInfo:function(){var t=this.dataZoomModel,e=t.get("showDataShadow");if(!1!==e){var n,i=this.ecModel;return t.eachTargetAxis(function(r,o){d(t.getAxisProxy(r.name,o).getTargetSeriesModels(),function(t){if(!(n||!0!==e&&l(tS,t.get("type"))<0)){var a,s=i.getComponent(r.axis,o).axis,h=Sc(r.name),u=t.coordinateSystem;null!=h&&u.getOtherAxis&&(a=u.getOtherAxis(s).inverse),h=t.getData().mapDimension(h),n={thisAxis:s,series:t,thisDim:r.name,otherDim:h,otherAxisInverse:a}}},this)},this),n}},_renderHandle:function(){var t=this._displayables,e=t.handles=[],n=t.handleLabels=[],i=this._displayables.barGroup,r=this._size,o=this.dataZoomModel;i.add(t.filler=new jb({draggable:!0,cursor:Mc(this._orient),drift:$b(this._onDragMove,this,"all"),onmousemove:function(t){Ag(t.event)},ondragstart:$b(this._showDataInfo,this,!0),ondragend:$b(this._onDragEnd,this),onmouseover:$b(this._showDataInfo,this,!0),onmouseout:$b(this._showDataInfo,this,!1),style:{fill:o.get("fillerColor"),textPosition:"inside"}})),i.add(new jb(Ei({silent:!0,shape:{x:0,y:0,width:r[0],height:r[1]},style:{stroke:o.get("dataBackgroundColor")||o.get("borderColor"),lineWidth:1,fill:"rgba(0,0,0,0)"}}))),Kb([0,1],function(t){var r=fr(o.get("handleIcon"),{cursor:Mc(this._orient),draggable:!0,drift:$b(this._onDragMove,this,t),onmousemove:function(t){Ag(t.event)},ondragend:$b(this._onDragEnd,this),onmouseover:$b(this._showDataInfo,this,!0),onmouseout:$b(this._showDataInfo,this,!1)},{x:-1,y:0,width:2,height:2}),a=r.getBoundingRect();this._handleHeight=_r(o.get("handleSize"),this._size[1]),this._handleWidth=a.width/a.height*this._handleHeight,r.setStyle(o.getModel("handleStyle").getItemStyle());var s=o.get("handleColor");null!=s&&(r.style.fill=s),i.add(e[t]=r);var l=o.textStyleModel;this.group.add(n[t]=new ov({silent:!0,invisible:!0,style:{x:0,y:0,text:"",textVerticalAlign:"middle",textAlign:"center",textFill:l.getTextColor(),textFont:l.getFont()},z2:10}))},this)},_resetInterval:function(){var t=this._range=this.dataZoomModel.getPercentRange(),e=this._getViewExtent();this._handleEnds=[Yb(t[0],[0,100],e,!0),Yb(t[1],[0,100],e,!0)]},_updateInterval:function(t,e){var n=this.dataZoomModel,i=this._handleEnds,r=this._getViewExtent(),o=n.findRepresentativeAxisProxy().getMinMaxSpan(),a=[0,100];Xb(e,i,r,n.get("zoomLock")?"all":t,null!=o.minSpan?Yb(o.minSpan,a,r,!0):null,null!=o.maxSpan?Yb(o.maxSpan,a,r,!0):null),this._range=qb([Yb(i[0],r,a,!0),Yb(i[1],r,a,!0)])},_updateView:function(t){var e=this._displayables,n=this._handleEnds,i=qb(n.slice()),r=this._size;Kb([0,1],function(t){var i=e.handles[t],o=this._handleHeight;i.attr({scale:[o/2,o/2],position:[n[t],r[1]/2-o/2]})},this),e.filler.setShape({x:i[0],y:0,width:i[1]-i[0],height:r[1]}),this._updateDataInfo(t)},_updateDataInfo:function(t){function e(t){var e=lr(i.handles[t].parent,this.group),n=ur(0===t?"right":"left",e),s=this._handleWidth/2+Jb,l=hr([c[t]+(0===t?-s:s),this._size[1]/2],e);r[t].setStyle({x:l[0],y:l[1],textVerticalAlign:o===Qb?"middle":n,textAlign:o===Qb?n:"center",text:a[t]})}var n=this.dataZoomModel,i=this._displayables,r=i.handleLabels,o=this._orient,a=["",""];if(n.get("showDetail")){var s=n.findRepresentativeAxisProxy();if(s){var l=s.getAxisModel().axis,h=this._range,u=t?s.calculateDataWindow({start:h[0],end:h[1]}).valueWindow:s.getDataValueWindow();a=[this._formatLabel(u[0],l),this._formatLabel(u[1],l)]}}var c=qb(this._handleEnds.slice());e.call(this,0),e.call(this,1)},_formatLabel:function(t,e){var n=this.dataZoomModel,i=n.get("labelFormatter"),r=n.get("labelPrecision");null!=r&&"auto"!==r||(r=e.getPixelPrecision());var o=null==t||isNaN(t)?"":"category"===e.type||"time"===e.type?e.scale.getLabel(Math.round(t)):t.toFixed(Math.min(r,20));return x(i)?i(t,o):_(i)?i.replace("{value}",o):o},_showDataInfo:function(t){t=this._dragging||t;var e=this._displayables.handleLabels;e[0].attr("invisible",!t),e[1].attr("invisible",!t)},_onDragMove:function(t,e,n){this._dragging=!0;var i=hr([e,n],this._displayables.barGroup.getLocalTransform(),!0);this._updateInterval(t,i[0]);var r=this.dataZoomModel.get("realtime");this._updateView(!r),r&&this._dispatchZoomAction()},_onDragEnd:function(){this._dragging=!1,this._showDataInfo(!1),!this.dataZoomModel.get("realtime")&&this._dispatchZoomAction()},_onClickPanelClick:function(t){var e=this._size,n=this._displayables.barGroup.transformCoordToLocal(t.offsetX,t.offsetY);if(!(n[0]<0||n[0]>e[0]||n[1]<0||n[1]>e[1])){var i=this._handleEnds,r=(i[0]+i[1])/2;this._updateInterval("all",n[0]-r),this._updateView(),this._dispatchZoomAction()}},_dispatchZoomAction:function(){var t=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,start:t[0],end:t[1]})},_findCoordRect:function(){var t;if(Kb(this.getTargetCoordInfo(),function(e){if(!t&&e.length){var n=e[0].model.coordinateSystem;t=n.getRect&&n.getRect()}}),!t){var e=this.api.getWidth(),n=this.api.getHeight();t={x:.2*e,y:.2*n,width:.6*e,height:.6*n}}return t}});Zb.extend({type:"dataZoom.inside",defaultOption:{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,preventDefaultMouseMove:!0}});var nS="\0_ec_interaction_mutex";Ja({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},function(){}),u(Ac,xp);var iS=v,rS="\0_ec_dataZoom_roams",oS=m,aS=Ub.extend({type:"dataZoom.inside",init:function(t,e){this._range},render:function(t,e,n,i){aS.superApply(this,"render",arguments),Vc(i,t.id)&&(this._range=t.getPercentRange()),d(this.getTargetCoordInfo(),function(e,i){var r=f(e,function(t){return Fc(t.model)});d(e,function(e){var o=e.model,a=t.option;Rc(n,{coordId:Fc(o),allCoordIds:r,containsPoint:function(t,e,n){return o.coordinateSystem.containPoint([e,n])},dataZoomId:t.id,throttleRate:t.get("throttle",!0),panGetRange:oS(this._onPan,this,e,i),zoomGetRange:oS(this._onZoom,this,e,i),zoomLock:a.zoomLock,disabled:a.disabled,roamControllerOpt:{zoomOnMouseWheel:a.zoomOnMouseWheel,moveOnMouseMove:a.moveOnMouseMove,preventDefaultMouseMove:a.preventDefaultMouseMove}})},this)},this)},dispose:function(){Bc(this.api,this.dataZoomModel.id),aS.superApply(this,"dispose",arguments),this._range=null},_onPan:function(t,e,n,i,r,o,a,s,l){var h=this._range.slice(),u=t.axisModels[0];if(u){var c=sS[e]([o,a],[s,l],u,n,t),d=c.signal*(h[1]-h[0])*c.pixel/c.pixelLength;return Xb(d,h,[0,100],"all"),this._range=h}},_onZoom:function(t,e,n,i,r,o){var a=this._range.slice(),s=t.axisModels[0];if(s){var l=sS[e](null,[r,o],s,n,t),h=(l.signal>0?l.pixelStart+l.pixelLength-l.pixel:l.pixel-l.pixelStart)/l.pixelLength*(a[1]-a[0])+a[0];i=Math.max(1/i,0),a[0]=(a[0]-h)*i+h,a[1]=(a[1]-h)*i+h;var u=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();return Xb(0,a,[0,100],0,u.minSpan,u.maxSpan),this._range=a}}}),sS={grid:function(t,e,n,i,r){var o=n.axis,a={},s=r.model.coordinateSystem.getRect();return t=t||[0,0],"x"===o.dim?(a.pixel=e[0]-t[0],a.pixelLength=s.width,a.pixelStart=s.x,a.signal=o.inverse?1:-1):(a.pixel=e[1]-t[1],a.pixelLength=s.height,a.pixelStart=s.y,a.signal=o.inverse?-1:1),a},polar:function(t,e,n,i,r){var o=n.axis,a={},s=r.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),h=s.getAngleAxis().getExtent();return t=t?s.pointToCoord(t):[0,0],e=s.pointToCoord(e),"radiusAxis"===n.mainType?(a.pixel=e[0]-t[0],a.pixelLength=l[1]-l[0],a.pixelStart=l[0],a.signal=o.inverse?1:-1):(a.pixel=e[1]-t[1],a.pixelLength=h[1]-h[0],a.pixelStart=h[0],a.signal=o.inverse?-1:1),a},singleAxis:function(t,e,n,i,r){var o=n.axis,a=r.model.coordinateSystem.getRect(),s={};return t=t||[0,0],"horizontal"===o.orient?(s.pixel=e[0]-t[0],s.pixelLength=a.width,s.pixelStart=a.x,s.signal=o.inverse?1:-1):(s.pixel=e[1]-t[1],s.pixelLength=a.height,s.pixelStart=a.y,s.signal=o.inverse?-1:1),s}};Qa({getTargetSeries:function(t){var e=N();return t.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(t,n,i){d(i.getAxisProxy(t.name,n).getTargetSeriesModels(),function(t){e.set(t.uid,t)})})}),e},isOverallFilter:!0,overallReset:function(t,e){t.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(t,n,i){i.getAxisProxy(t.name,n).reset(i,e)}),t.eachTargetAxis(function(t,n,i){i.getAxisProxy(t.name,n).filterData(i,e)})}),t.eachComponent("dataZoom",function(t){var e=t.findRepresentativeAxisProxy(),n=e.getDataPercentWindow(),i=e.getDataValueWindow();t.setRawRange({start:n[0],end:n[1],startValue:i[0],endValue:i[1]},!0)})}}),Ja("dataZoom",function(t,e){var n=pc(m(e.eachComponent,e,"dataZoom"),Bb,function(t,e){return t.get(e.axisIndex)}),i=[];e.eachComponent({mainType:"dataZoom",query:t},function(t,e){i.push.apply(i,n(t).nodes)}),d(i,function(e,n){e.setRawRange({start:t.start,end:t.end,startValue:t.startValue,endValue:t.endValue})})});var lS={},hS=rs({type:"toolbox",layoutMode:{type:"box",ignoreSize:!0},mergeDefaultAndTheme:function(t){hS.superApply(this,"mergeDefaultAndTheme",arguments),d(this.option.feature,function(t,e){var n=$c(e);n&&i(t,n.defaultOption)})},defaultOption:{show:!0,z:6,zlevel:0,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{borderColor:"#666",color:"none"},emphasis:{iconStyle:{borderColor:"#3E98C5"}}}});os({type:"toolbox",render:function(t,e,n,i){function r(r,a){var s,c=u[r],d=u[a],f=new pr(l[c],t,t.ecModel);if(c&&!d){if(Kc(c))s={model:f,onclick:f.option.onclick,featureName:c};else{var p=$c(c);if(!p)return;s=new p(f,e,n)}h[c]=s}else{if(!(s=h[d]))return;s.model=f,s.ecModel=e,s.api=n}c||!d?f.get("show")&&!s.unusable?(o(f,s,c),f.setIconStatus=function(t,e){var n=this.option,i=this.iconPaths;n.iconStatus=n.iconStatus||{},n.iconStatus[t]=e,i[t]&&i[t].trigger(e)},s.render&&s.render(f,e,n,i)):s.remove&&s.remove(e,n):s.dispose&&s.dispose(e,n)}function o(i,r,o){var l=i.getModel("iconStyle"),h=i.getModel("emphasis.iconStyle"),u=r.getIcons?r.getIcons():i.get("icon"),c=i.get("title")||{};if("string"==typeof u){var f=u,p=c;c={},(u={})[o]=f,c[o]=p}var g=i.iconPaths={};d(u,function(o,u){var d=fr(o,{},{x:-s/2,y:-s/2,width:s,height:s});d.setStyle(l.getItemStyle()),d.hoverStyle=h.getItemStyle(),qi(d),t.get("showTitle")&&(d.__title=c[u],d.on("mouseover",function(){var t=h.getItemStyle();d.setStyle({text:c[u],textPosition:t.textPosition||"bottom",textFill:t.fill||t.stroke||"#000",textAlign:t.textAlign||"center"})}).on("mouseout",function(){d.setStyle({textFill:null})})),d.trigger(i.get("iconStatus."+u)||"normal"),a.add(d),d.on("click",m(r.onclick,r,e,n,u)),g[u]=d})}var a=this.group;if(a.removeAll(),t.get("show")){var s=+t.get("itemSize"),l=t.get("feature")||{},h=this._features||(this._features={}),u=[];d(l,function(t,e){u.push(e)}),new hs(this._featureNames||[],u).add(r).update(r).remove(v(r,null)).execute(),this._featureNames=u,Cu(a,t,n),a.add(Du(a.getBoundingRect(),t)),a.eachChild(function(t){var e=t.__title,i=t.hoverStyle;if(i&&e){var r=ce(e,Te(i)),o=t.position[0]+a.position[0],l=!1;t.position[1]+a.position[1]+s+r.height>n.getHeight()&&(i.textPosition="top",l=!0);var h=l?-5-r.height:s+8;o+r.width/2>n.getWidth()?(i.textPosition=["100%",h],i.textAlign="right"):o-r.width/2<0&&(i.textPosition=[0,h],i.textAlign="left")}})}},updateView:function(t,e,n,i){d(this._features,function(t){t.updateView&&t.updateView(t.model,e,n,i)})},remove:function(t,e){d(this._features,function(n){n.remove&&n.remove(t,e)}),this.group.removeAll()},dispose:function(t,e){d(this._features,function(n){n.dispose&&n.dispose(t,e)})}});var uS=qy.toolbox.saveAsImage;Qc.defaultOption={show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:uS.title,type:"png",name:"",excludeComponents:["toolbox"],pixelRatio:1,lang:uS.lang.slice()},Qc.prototype.unusable=!Kf.canvasSupported,Qc.prototype.onclick=function(t,e){var n=this.model,i=n.get("name")||t.get("title.0.text")||"echarts",r=document.createElement("a"),o=n.get("type",!0)||"png";r.download=i+"."+o,r.target="_blank";var a=e.getConnectedDataURL({type:o,backgroundColor:n.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")});if(r.href=a,"function"!=typeof MouseEvent||Kf.browser.ie||Kf.browser.edge)if(window.navigator.msSaveOrOpenBlob){for(var s=atob(a.split(",")[1]),l=s.length,h=new Uint8Array(l);l--;)h[l]=s.charCodeAt(l);var u=new Blob([h]);window.navigator.msSaveOrOpenBlob(u,i+"."+o)}else{var c=n.get("lang"),d='<body style="margin:0;"><img src="'+a+'" style="max-width:100%;" title="'+(c&&c[0]||"")+'" /></body>';window.open().document.write(d)}else{var f=new MouseEvent("click",{view:window,bubbles:!0,cancelable:!1});r.dispatchEvent(f)}},qc("saveAsImage",Qc);var cS=qy.toolbox.magicType;Jc.defaultOption={show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z",tiled:"M2.3,2.2h22.8V25H2.3V2.2z M35,2.2h22.8V25H35V2.2zM2.3,35h22.8v22.8H2.3V35z M35,35h22.8v22.8H35V35z"},title:n(cS.title),option:{},seriesIndex:{}};var dS=Jc.prototype;dS.getIcons=function(){var t=this.model,e=t.get("icon"),n={};return d(t.get("type"),function(t){e[t]&&(n[t]=e[t])}),n};var fS={line:function(t,e,n,r){if("bar"===t)return i({id:e,type:"line",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},r.get("option.line")||{},!0)},bar:function(t,e,n,r){if("line"===t)return i({id:e,type:"bar",data:n.get("data"),stack:n.get("stack"),markPoint:n.get("markPoint"),markLine:n.get("markLine")},r.get("option.bar")||{},!0)},stack:function(t,e,n,r){if("line"===t||"bar"===t)return i({id:e,stack:"__ec_magicType_stack__"},r.get("option.stack")||{},!0)},tiled:function(t,e,n,r){if("line"===t||"bar"===t)return i({id:e,stack:""},r.get("option.tiled")||{},!0)}},pS=[["line","bar"],["stack","tiled"]];dS.onclick=function(t,e,n){var i=this.model,r=i.get("seriesIndex."+n);if(fS[n]){var o={series:[]};d(pS,function(t){l(t,n)>=0&&d(t,function(t){i.setIconStatus(t,"normal")})}),i.setIconStatus(n,"emphasis"),t.eachComponent({mainType:"series",query:null==r?null:{seriesIndex:r}},function(e){var r=e.subType,s=e.id,l=fS[n](r,s,e,i);l&&(a(l,e.option),o.series.push(l));var h=e.coordinateSystem;if(h&&"cartesian2d"===h.type&&("line"===n||"bar"===n)){var u=h.getAxesByScale("ordinal")[0];if(u){var c=u.dim+"Axis",d=t.queryComponents({mainType:c,index:e.get(name+"Index"),id:e.get(name+"Id")})[0].componentIndex;o[c]=o[c]||[];for(var f=0;f<=d;f++)o[c][d]=o[c][d]||{};o[c][d].boundaryGap="bar"===n}}}),e.dispatchAction({type:"changeMagicType",currentType:n,newOption:o})}},Ja({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(t,e){e.mergeOption(t.newOption)}),qc("magicType",Jc);var gS=qy.toolbox.dataView,mS=new Array(60).join("-"),vS="\t",yS=new RegExp("["+vS+"]+","g");hd.defaultOption={show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:"M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28",title:n(gS.title),lang:n(gS.lang),backgroundColor:"#fff",textColor:"#000",textareaColor:"#fff",textareaBorderColor:"#333",buttonColor:"#c23531",buttonTextColor:"#fff"},hd.prototype.onclick=function(t,e){function n(){i.removeChild(o),x._dom=null}var i=e.getDom(),r=this.model;this._dom&&i.removeChild(this._dom);var o=document.createElement("div");o.style.cssText="position:absolute;left:5px;top:5px;bottom:5px;right:5px;",o.style.backgroundColor=r.get("backgroundColor")||"#fff";var a=document.createElement("h4"),s=r.get("lang")||[];a.innerHTML=s[0]||r.get("title"),a.style.cssText="margin: 10px 20px;",a.style.color=r.get("textColor");var l=document.createElement("div"),h=document.createElement("textarea");l.style.cssText="display:block;width:100%;overflow:auto;";var u=r.get("optionToContent"),c=r.get("contentToOption"),d=id(t);if("function"==typeof u){var f=u(e.getOption());"string"==typeof f?l.innerHTML=f:M(f)&&l.appendChild(f)}else l.appendChild(h),h.readOnly=r.get("readOnly"),h.style.cssText="width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;",h.style.color=r.get("textColor"),h.style.borderColor=r.get("textareaBorderColor"),h.style.backgroundColor=r.get("textareaColor"),h.value=d.value;var p=d.meta,g=document.createElement("div");g.style.cssText="position:absolute;bottom:0;left:0;right:0;";var m="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",v=document.createElement("div"),y=document.createElement("div");m+=";background-color:"+r.get("buttonColor"),m+=";color:"+r.get("buttonTextColor");var x=this;on(v,"click",n),on(y,"click",function(){var t;try{t="function"==typeof c?c(l,e.getOption()):ld(h.value,p)}catch(t){throw n(),new Error("Data view format error "+t)}t&&e.dispatchAction({type:"changeDataView",newOption:t}),n()}),v.innerHTML=s[1],y.innerHTML=s[2],y.style.cssText=m,v.style.cssText=m,!r.get("readOnly")&&g.appendChild(y),g.appendChild(v),on(h,"keydown",function(t){if(9===(t.keyCode||t.which)){var e=this.value,n=this.selectionStart,i=this.selectionEnd;this.value=e.substring(0,n)+vS+e.substring(i),this.selectionStart=this.selectionEnd=n+1,Ag(t)}}),o.appendChild(a),o.appendChild(l),o.appendChild(g),l.style.height=i.clientHeight-80+"px",i.appendChild(o),this._dom=o},hd.prototype.remove=function(t,e){this._dom&&e.getDom().removeChild(this._dom)},hd.prototype.dispose=function(t,e){this.remove(t,e)},qc("dataView",hd),Ja({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(t,e){var n=[];d(t.newOption.series,function(t){var i=e.getSeriesByName(t.name)[0];if(i){var r=i.get("data");n.push({name:t.name,data:ud(t.data,r)})}else n.push(o({type:"scatter"},t))}),e.mergeOption(a({series:n},t.newOption))});var xS=v,_S=d,wS=f,bS=Math.min,SS=Math.max,MS=Math.pow,IS=1e4,TS=6,CS=6,DS="globalPan",AS={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},kS={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},PS={brushStyle:{lineWidth:2,stroke:"rgba(0,0,0,0.3)",fill:"rgba(0,0,0,0.1)"},transformable:!0,brushMode:"single",removeOnClick:!1},LS=0;cd.prototype={constructor:cd,enableBrush:function(t){return this._brushType&&fd(this),t.brushType&&dd(this,t),this},setPanels:function(t){if(t&&t.length){var e=this._panels={};d(t,function(t){e[t.panelId]=n(t)})}else this._panels=null;return this},mount:function(t){t=t||{},this._enableGlobalPan=t.enableGlobalPan;var e=this.group;return this._zr.add(e),e.attr({position:t.position||[0,0],rotation:t.rotation||0,scale:t.scale||[1,1]}),this._transform=e.getLocalTransform(),this},eachCover:function(t,e){_S(this._covers,t,e)},updateCovers:function(t){function e(t,e){return(null!=t.id?t.id:o+e)+"-"+t.brushType}function r(e,n){var i=t[e];if(null!=n&&a[n]===h)s[e]=a[n];else{var r=s[e]=null!=n?(a[n].__brushOption=i,a[n]):gd(l,pd(l,i));yd(l,r)}}t=f(t,function(t){return i(n(PS),t,!0)});var o="\0-brush-index-",a=this._covers,s=this._covers=[],l=this,h=this._creatingCover;return new hs(a,t,function(t,n){return e(t.__brushOption,n)},e).add(r).update(r).remove(function(t){a[t]!==h&&l.group.remove(a[t])}).execute(),this},unmount:function(){return this.enableBrush(!1),bd(this),this._zr.remove(this.group),this},dispose:function(){this.unmount(),this.off()}},u(cd,xp);var OS={mousedown:function(t){if(this._dragging)Zd.call(this,t);else if(!t.target||!t.target.draggable){Fd(t);var e=this.group.transformCoordToLocal(t.offsetX,t.offsetY);this._creatingCover=null,(this._creatingPanel=_d(this,t,e))&&(this._dragging=!0,this._track=[e.slice()])}},mousemove:function(t){var e=this.group.transformCoordToLocal(t.offsetX,t.offsetY);if(Vd(this,t,e),this._dragging){Fd(t);var n=Gd(this,t,e,!1);n&&Sd(this,n)}},mouseup:Zd},zS={lineX:Ud(0),lineY:Ud(1),rect:{createCover:function(t,e){return Td(xS(zd,function(t){return t},function(t){return t}),t,e,["w","e","n","s","se","sw","ne","nw"])},getCreatingRange:function(t){var e=Id(t);return Pd(e[1][0],e[1][1],e[0][0],e[0][1])},updateCoverShape:function(t,e,n,i){Cd(t,e,n,i)},updateCommon:Dd,contain:Hd},polygon:{createCover:function(t,e){var n=new Jp;return n.add(new pv({name:"main",style:kd(e),silent:!0})),n},getCreatingRange:function(t){return t},endCreating:function(t,e){e.remove(e.childAt(0)),e.add(new fv({name:"main",draggable:!0,drift:xS(Ed,t,e),ondragend:xS(Sd,t,{isEnd:!0})}))},updateCoverShape:function(t,e,n,i){e.childAt(0).setShape({points:Rd(t,e,n)})},updateCommon:Dd,contain:Hd}},ES={axisPointer:1,tooltip:1,brush:1},NS=d,RS=l,BS=v,VS=["dataToPoint","pointToData"],FS=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],HS=Kd.prototype;HS.setOutputRanges=function(t,e){this.matchOutputRanges(t,e,function(t,e,n){if((t.coordRanges||(t.coordRanges=[])).push(e),!t.coordRange){t.coordRange=e;var i=US[t.brushType](0,n,e);t.__rangeOffset={offset:XS[t.brushType](i.values,t.range,[1,1]),xyMinMax:i.xyMinMax}}})},HS.matchOutputRanges=function(t,e,n){NS(t,function(t){var i=this.findTargetInfo(t,e);i&&!0!==i&&d(i.coordSyses,function(i){var r=US[t.brushType](1,i,t.range);n(t,r.values,i,e)})},this)},HS.setInputRanges=function(t,e){NS(t,function(t){var n=this.findTargetInfo(t,e);if(t.range=t.range||[],n&&!0!==n){t.panelId=n.panelId;var i=US[t.brushType](0,n.coordSys,t.coordRange),r=t.__rangeOffset;t.range=r?XS[t.brushType](i.values,r.offset,nf(i.xyMinMax,r.xyMinMax)):i.values}},this)},HS.makePanelOpts=function(t,e){return f(this._targetInfoList,function(n){var i=n.getPanelRect();return{panelId:n.panelId,defaultBrushType:e&&e(n),clipPath:jd(i),isTargetByCursor:qd(i,t,n.coordSysModel),getLinearBrushOtherExtent:Yd(i)}})},HS.controlSeries=function(t,e,n){var i=this.findTargetInfo(t,n);return!0===i||i&&RS(i.coordSyses,e.coordinateSystem)>=0},HS.findTargetInfo=function(t,e){for(var n=this._targetInfoList,i=Jd(e,t),r=0;r<n.length;r++){var o=n[r],a=t.panelId;if(a){if(o.panelId===a)return o}else for(r=0;r<WS.length;r++)if(WS[r](i,o))return o}return!0};var GS={grid:function(t,e){var n=t.xAxisModels,i=t.yAxisModels,r=t.gridModels,o=N(),a={},s={};(n||i||r)&&(NS(n,function(t){var e=t.axis.grid.model;o.set(e.id,e),a[e.id]=!0}),NS(i,function(t){var e=t.axis.grid.model;o.set(e.id,e),s[e.id]=!0}),NS(r,function(t){o.set(t.id,t),a[t.id]=!0,s[t.id]=!0}),o.each(function(t){var r=t.coordinateSystem,o=[];NS(r.getCartesians(),function(t,e){(RS(n,t.getAxis("x").model)>=0||RS(i,t.getAxis("y").model)>=0)&&o.push(t)}),e.push({panelId:"grid--"+t.id,gridModel:t,coordSysModel:t,coordSys:o[0],coordSyses:o,getPanelRect:ZS.grid,xAxisDeclared:a[t.id],yAxisDeclared:s[t.id]})}))},geo:function(t,e){NS(t.geoModels,function(t){var n=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:n,coordSyses:[n],getPanelRect:ZS.geo})})}},WS=[function(t,e){var n=t.xAxisModel,i=t.yAxisModel,r=t.gridModel;return!r&&n&&(r=n.axis.grid.model),!r&&i&&(r=i.axis.grid.model),r&&r===e.gridModel},function(t,e){var n=t.geoModel;return n&&n===e.geoModel}],ZS={grid:function(){return this.coordSys.grid.getRect().clone()},geo:function(){var t=this.coordSys,e=t.getBoundingRect().clone();return e.applyTransform(lr(t)),e}},US={lineX:BS(tf,0),lineY:BS(tf,1),rect:function(t,e,n){var i=e[VS[t]]([n[0][0],n[1][0]]),r=e[VS[t]]([n[0][1],n[1][1]]),o=[Qd([i[0],r[0]]),Qd([i[1],r[1]])];return{values:o,xyMinMax:o}},polygon:function(t,e,n){var i=[[1/0,-1/0],[1/0,-1/0]];return{values:f(n,function(n){var r=e[VS[t]](n);return i[0][0]=Math.min(i[0][0],r[0]),i[1][0]=Math.min(i[1][0],r[1]),i[0][1]=Math.max(i[0][1],r[0]),i[1][1]=Math.max(i[1][1],r[1]),r}),xyMinMax:i}}},XS={lineX:BS(ef,0),lineY:BS(ef,1),rect:function(t,e,n){return[[t[0][0]-n[0]*e[0][0],t[0][1]-n[0]*e[0][1]],[t[1][0]-n[1]*e[1][0],t[1][1]-n[1]*e[1][1]]]},polygon:function(t,e,n){return f(t,function(t,i){return[t[0]-n[0]*e[i][0],t[1]-n[1]*e[i][1]]})}},jS=d,YS="\0_ec_hist_store";Zb.extend({type:"dataZoom.select"}),Ub.extend({type:"dataZoom.select"});var qS=qy.toolbox.dataZoom,$S=d,KS="\0_ec_\0toolbox-dataZoom_";uf.defaultOption={show:!0,icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:n(qS.title)};var QS=uf.prototype;QS.render=function(t,e,n,i){this.model=t,this.ecModel=e,this.api=n,ff(t,e,this,i,n),df(t,e)},QS.onclick=function(t,e,n){JS[n].call(this)},QS.remove=function(t,e){this._brushController.unmount()},QS.dispose=function(t,e){this._brushController.dispose()};var JS={zoom:function(){var t=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:t})},back:function(){this._dispatchZoomAction(af(this.ecModel))}};QS._onBrush=function(t,e){function n(t,e,n){var a=e.getAxis(t),s=a.model,l=i(t,s,o),h=l.findRepresentativeAxisProxy(s).getMinMaxSpan();null==h.minValueSpan&&null==h.maxValueSpan||(n=Xb(0,n.slice(),a.scale.getExtent(),0,h.minValueSpan,h.maxValueSpan)),l&&(r[l.id]={dataZoomId:l.id,startValue:n[0],endValue:n[1]})}function i(t,e,n){var i;return n.eachComponent({mainType:"dataZoom",subType:"select"},function(n){n.getAxisModel(t,e.componentIndex)&&(i=n)}),i}if(e.isEnd&&t.length){var r={},o=this.ecModel;this._brushController.updateCovers([]),new Kd(cf(this.model.option),o,{include:["grid"]}).matchOutputRanges(t,o,function(t,e,i){if("cartesian2d"===i.type){var r=t.brushType;"rect"===r?(n("x",i,e[0]),n("y",i,e[1])):n({lineX:"x",lineY:"y"}[r],i,e)}}),of(o,r),this._dispatchZoomAction(r)}},QS._dispatchZoomAction=function(t){var e=[];$S(t,function(t,i){e.push(n(t))}),e.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:e})},qc("dataZoom",uf),Ka(function(t){function e(t,e){if(e){var r=t+"Index",o=e[r];null==o||"all"==o||y(o)||(o=!1===o||"none"===o?[]:[o]),n(t,function(e,n){if(null==o||"all"==o||-1!==l(o,n)){var a={type:"select",$fromToolbox:!0,id:KS+t+n};a[r]=n,i.push(a)}})}}function n(e,n){var i=t[e];y(i)||(i=i?[i]:[]),$S(i,n)}if(t){var i=t.dataZoom||(t.dataZoom=[]);y(i)||(t.dataZoom=i=[i]);var r=t.toolbox;if(r&&(y(r)&&(r=r[0]),r&&r.feature)){var o=r.feature.dataZoom;e("xAxis",o),e("yAxis",o)}}});var tM=qy.toolbox.restore;pf.defaultOption={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:tM.title},pf.prototype.onclick=function(t,e,n){sf(t),e.dispatchAction({type:"restore",from:this.uid})},qc("restore",pf),Ja({type:"restore",event:"restore",update:"prepareAndUpdate"},function(t,e){e.resetOption("recreate")});var eM,nM="urn:schemas-microsoft-com:vml",iM="undefined"==typeof window?null:window,rM=!1,oM=iM&&iM.document;if(oM&&!Kf.canvasSupported)try{!oM.namespaces.zrvml&&oM.namespaces.add("zrvml",nM),eM=function(t){return oM.createElement("<zrvml:"+t+' class="zrvml">')}}catch(t){eM=function(t){return oM.createElement("<"+t+' xmlns="'+nM+'" class="zrvml">')}}var aM=Em.CMD,sM=Math.round,lM=Math.sqrt,hM=Math.abs,uM=Math.cos,cM=Math.sin,dM=Math.max;if(!Kf.canvasSupported){var fM=21600,pM=fM/2,gM=function(t){t.style.cssText="position:absolute;left:0;top:0;width:1px;height:1px;",t.coordsize=fM+","+fM,t.coordorigin="0,0"},mM=function(t){return String(t).replace(/&/g,"&amp;").replace(/"/g,"&quot;")},vM=function(t,e,n){return"rgb("+[t,e,n].join(",")+")"},yM=function(t,e){e&&t&&e.parentNode!==t&&t.appendChild(e)},xM=function(t,e){e&&t&&e.parentNode===t&&t.removeChild(e)},_M=function(t,e,n){return 1e5*(parseFloat(t)||0)+1e3*(parseFloat(e)||0)+n},wM=function(t,e){return"string"==typeof t?t.lastIndexOf("%")>=0?parseFloat(t)/100*e:parseFloat(t):t},bM=function(t,e,n){var i=Mt(e);n=+n,isNaN(n)&&(n=1),i&&(t.color=vM(i[0],i[1],i[2]),t.opacity=n*i[3])},SM=function(t){var e=Mt(t);return[vM(e[0],e[1],e[2]),e[3]]},MM=function(t,e,n){var i=e.fill;if(null!=i)if(i instanceof wv){var r,o=0,a=[0,0],s=0,l=1,h=n.getBoundingRect(),u=h.width,c=h.height;if("linear"===i.type){r="gradient";var d=n.transform,f=[i.x*u,i.y*c],p=[i.x2*u,i.y2*c];d&&($(f,f,d),$(p,p,d));var g=p[0]-f[0],m=p[1]-f[1];(o=180*Math.atan2(g,m)/Math.PI)<0&&(o+=360),o<1e-6&&(o=0)}else{r="gradientradial";var f=[i.x*u,i.y*c],d=n.transform,v=n.scale,y=u,x=c;a=[(f[0]-h.x)/y,(f[1]-h.y)/x],d&&$(f,f,d),y/=v[0]*fM,x/=v[1]*fM;var _=dM(y,x);s=0/_,l=2*i.r/_-s}var w=i.colorStops.slice();w.sort(function(t,e){return t.offset-e.offset});for(var b=w.length,S=[],M=[],I=0;I<b;I++){var T=w[I],C=SM(T.color);M.push(T.offset*l+s+" "+C[0]),0!==I&&I!==b-1||S.push(C)}if(b>=2){var D=S[0][0],A=S[1][0],k=S[0][1]*e.opacity,P=S[1][1]*e.opacity;t.type=r,t.method="none",t.focus="100%",t.angle=o,t.color=D,t.color2=A,t.colors=M.join(","),t.opacity=P,t.opacity2=k}"radial"===r&&(t.focusposition=a.join(","))}else bM(t,i,e.opacity)},IM=function(t,e){null!=e.lineDash&&(t.dashstyle=e.lineDash.join(" ")),null==e.stroke||e.stroke instanceof wv||bM(t,e.stroke,e.opacity)},TM=function(t,e,n,i){var r="fill"==e,o=t.getElementsByTagName(e)[0];null!=n[e]&&"none"!==n[e]&&(r||!r&&n.lineWidth)?(t[r?"filled":"stroked"]="true",n[e]instanceof wv&&xM(t,o),o||(o=gf(e)),r?MM(o,n,i):IM(o,n),yM(t,o)):(t[r?"filled":"stroked"]="false",xM(t,o))},CM=[[],[],[]],DM=function(t,e){var n,i,r,o,a,s,l=aM.M,h=aM.C,u=aM.L,c=aM.A,d=aM.Q,f=[],p=t.data,g=t.len();for(o=0;o<g;){switch(r=p[o++],i="",n=0,r){case l:i=" m ",n=1,a=p[o++],s=p[o++],CM[0][0]=a,CM[0][1]=s;break;case u:i=" l ",n=1,a=p[o++],s=p[o++],CM[0][0]=a,CM[0][1]=s;break;case d:case h:i=" c ",n=3;var m,v,y=p[o++],x=p[o++],_=p[o++],w=p[o++];r===d?(m=_,v=w,_=(_+2*y)/3,w=(w+2*x)/3,y=(a+2*y)/3,x=(s+2*x)/3):(m=p[o++],v=p[o++]),CM[0][0]=y,CM[0][1]=x,CM[1][0]=_,CM[1][1]=w,CM[2][0]=m,CM[2][1]=v,a=m,s=v;break;case c:var b=0,S=0,M=1,I=1,T=0;e&&(b=e[4],S=e[5],M=lM(e[0]*e[0]+e[1]*e[1]),I=lM(e[2]*e[2]+e[3]*e[3]),T=Math.atan2(-e[1]/I,e[0]/M));var C=p[o++],D=p[o++],A=p[o++],k=p[o++],P=p[o++]+T,L=p[o++]+P+T;o++;var O=p[o++],z=C+uM(P)*A,E=D+cM(P)*k,y=C+uM(L)*A,x=D+cM(L)*k,N=O?" wa ":" at ";Math.abs(z-y)<1e-4&&(Math.abs(L-P)>.01?O&&(z+=.0125):Math.abs(E-D)<1e-4?O&&z<C||!O&&z>C?x-=.0125:x+=.0125:O&&E<D||!O&&E>D?y+=.0125:y-=.0125),f.push(N,sM(((C-A)*M+b)*fM-pM),",",sM(((D-k)*I+S)*fM-pM),",",sM(((C+A)*M+b)*fM-pM),",",sM(((D+k)*I+S)*fM-pM),",",sM((z*M+b)*fM-pM),",",sM((E*I+S)*fM-pM),",",sM((y*M+b)*fM-pM),",",sM((x*I+S)*fM-pM)),a=y,s=x;break;case aM.R:var R=CM[0],B=CM[1];R[0]=p[o++],R[1]=p[o++],B[0]=R[0]+p[o++],B[1]=R[1]+p[o++],e&&($(R,R,e),$(B,B,e)),R[0]=sM(R[0]*fM-pM),B[0]=sM(B[0]*fM-pM),R[1]=sM(R[1]*fM-pM),B[1]=sM(B[1]*fM-pM),f.push(" m ",R[0],",",R[1]," l ",B[0],",",R[1]," l ",B[0],",",B[1]," l ",R[0],",",B[1]);break;case aM.Z:f.push(" x ")}if(n>0){f.push(i);for(var V=0;V<n;V++){var F=CM[V];e&&$(F,F,e),f.push(sM(F[0]*fM-pM),",",sM(F[1]*fM-pM),V<n-1?",":"")}}}return f.join("")};xi.prototype.brushVML=function(t){var e=this.style,n=this._vmlEl;n||(n=gf("shape"),gM(n),this._vmlEl=n),TM(n,"fill",e,this),TM(n,"stroke",e,this);var i=this.transform,r=null!=i,o=n.getElementsByTagName("stroke")[0];if(o){var a=e.lineWidth;if(r&&!e.strokeNoScale){var s=i[0]*i[3]-i[1]*i[2];a*=lM(hM(s))}o.weight=a+"px"}var l=this.path||(this.path=new Em);this.__dirtyPath&&(l.beginPath(),this.buildPath(l,this.shape),l.toStatic(),this.__dirtyPath=!1),n.path=DM(l,this.transform),n.style.zIndex=_M(this.zlevel,this.z,this.z2),yM(t,n),null!=e.text?this.drawRectText(t,this.getBoundingRect()):this.removeRectText(t)},xi.prototype.onRemove=function(t){xM(t,this._vmlEl),this.removeRectText(t)},xi.prototype.onAdd=function(t){yM(t,this._vmlEl),this.appendRectText(t)};var AM=function(t){return"object"==typeof t&&t.tagName&&"IMG"===t.tagName.toUpperCase()};je.prototype.brushVML=function(t){var e,n,i=this.style,r=i.image;if(AM(r)){var o=r.src;if(o===this._imageSrc)e=this._imageWidth,n=this._imageHeight;else{var a=r.runtimeStyle,s=a.width,l=a.height;a.width="auto",a.height="auto",e=r.width,n=r.height,a.width=s,a.height=l,this._imageSrc=o,this._imageWidth=e,this._imageHeight=n}r=o}else r===this._imageSrc&&(e=this._imageWidth,n=this._imageHeight);if(r){var h=i.x||0,u=i.y||0,c=i.width,d=i.height,f=i.sWidth,p=i.sHeight,g=i.sx||0,m=i.sy||0,v=f&&p,y=this._vmlEl;y||(y=oM.createElement("div"),gM(y),this._vmlEl=y);var x,_=y.style,w=!1,b=1,S=1;if(this.transform&&(x=this.transform,b=lM(x[0]*x[0]+x[1]*x[1]),S=lM(x[2]*x[2]+x[3]*x[3]),w=x[1]||x[2]),w){var M=[h,u],I=[h+c,u],T=[h,u+d],C=[h+c,u+d];$(M,M,x),$(I,I,x),$(T,T,x),$(C,C,x);var D=dM(M[0],I[0],T[0],C[0]),A=dM(M[1],I[1],T[1],C[1]),k=[];k.push("M11=",x[0]/b,",","M12=",x[2]/S,",","M21=",x[1]/b,",","M22=",x[3]/S,",","Dx=",sM(h*b+x[4]),",","Dy=",sM(u*S+x[5])),_.padding="0 "+sM(D)+"px "+sM(A)+"px 0",_.filter="progid:DXImageTransform.Microsoft.Matrix("+k.join("")+", SizingMethod=clip)"}else x&&(h=h*b+x[4],u=u*S+x[5]),_.filter="",_.left=sM(h)+"px",_.top=sM(u)+"px";var P=this._imageEl,L=this._cropEl;P||(P=oM.createElement("div"),this._imageEl=P);var O=P.style;if(v){if(e&&n)O.width=sM(b*e*c/f)+"px",O.height=sM(S*n*d/p)+"px";else{var z=new Image,E=this;z.onload=function(){z.onload=null,e=z.width,n=z.height,O.width=sM(b*e*c/f)+"px",O.height=sM(S*n*d/p)+"px",E._imageWidth=e,E._imageHeight=n,E._imageSrc=r},z.src=r}L||((L=oM.createElement("div")).style.overflow="hidden",this._cropEl=L);var N=L.style;N.width=sM((c+g*c/f)*b),N.height=sM((d+m*d/p)*S),N.filter="progid:DXImageTransform.Microsoft.Matrix(Dx="+-g*c/f*b+",Dy="+-m*d/p*S+")",L.parentNode||y.appendChild(L),P.parentNode!=L&&L.appendChild(P)}else O.width=sM(b*c)+"px",O.height=sM(S*d)+"px",y.appendChild(P),L&&L.parentNode&&(y.removeChild(L),this._cropEl=null);var R="",B=i.opacity;B<1&&(R+=".Alpha(opacity="+sM(100*B)+") "),R+="progid:DXImageTransform.Microsoft.AlphaImageLoader(src="+r+", SizingMethod=scale)",O.filter=R,y.style.zIndex=_M(this.zlevel,this.z,this.z2),yM(t,y),null!=i.text&&this.drawRectText(t,this.getBoundingRect())}},je.prototype.onRemove=function(t){xM(t,this._vmlEl),this._vmlEl=null,this._cropEl=null,this._imageEl=null,this.removeRectText(t)},je.prototype.onAdd=function(t){yM(t,this._vmlEl),this.appendRectText(t)};var kM,PM={},LM=0,OM=document.createElement("div"),zM=function(t){var e=PM[t];if(!e){LM>100&&(LM=0,PM={});var n,i=OM.style;try{i.font=t,n=i.fontFamily.split(",")[0]}catch(t){}e={style:i.fontStyle||"normal",variant:i.fontVariant||"normal",weight:i.fontWeight||"normal",size:0|parseFloat(i.fontSize||12),family:n||"Microsoft YaHei"},PM[t]=e,LM++}return e};!function(t,e){xg[t]=e}("measureText",function(t,e){var n=oM;kM||((kM=n.createElement("div")).style.cssText="position:absolute;top:-20000px;left:0;padding:0;margin:0;border:none;white-space:pre;",oM.body.appendChild(kM));try{kM.style.font=e}catch(t){}return kM.innerHTML="",kM.appendChild(n.createTextNode(t)),{width:kM.offsetWidth}});for(var EM=new Xt,NM=[Sg,Xe,je,xi,ov],RM=0;RM<NM.length;RM++){var BM=NM[RM].prototype;BM.drawRectText=function(t,e,n,i){var r=this.style;this.__dirty&&De(r);var o=r.text;if(null!=o&&(o+=""),o){if(r.rich){var a=Me(o,r);o=[];for(var s=0;s<a.lines.length;s++){for(var l=a.lines[s].tokens,h=[],u=0;u<l.length;u++)h.push(l[u].text);o.push(h.join(""))}o=o.join("\n")}var c,d,f=r.textAlign,p=r.textVerticalAlign,g=zM(r.font),m=g.style+" "+g.variant+" "+g.weight+" "+g.size+'px "'+g.family+'"';n=n||ce(o,m,f,p);var v=this.transform;if(v&&!i&&(EM.copy(e),EM.applyTransform(v),e=EM),i)c=e.x,d=e.y;else{var y=r.textPosition,x=r.textDistance;if(y instanceof Array)c=e.x+wM(y[0],e.width),d=e.y+wM(y[1],e.height),f=f||"left";else{var _=me(y,e,x);c=_.x,d=_.y,f=f||_.textAlign,p=p||_.textVerticalAlign}}c=pe(c,n.width,f),d=ge(d,n.height,p),d+=n.height/2;var w,b,S,M=gf,I=this._textVmlEl;I?b=(w=(S=I.firstChild).nextSibling).nextSibling:(I=M("line"),w=M("path"),b=M("textpath"),S=M("skew"),b.style["v-text-align"]="left",gM(I),w.textpathok=!0,b.on=!0,I.from="0 0",I.to="1000 0.05",yM(I,S),yM(I,w),yM(I,b),this._textVmlEl=I);var T=[c,d],C=I.style;v&&i?($(T,T,v),S.on=!0,S.matrix=v[0].toFixed(3)+","+v[2].toFixed(3)+","+v[1].toFixed(3)+","+v[3].toFixed(3)+",0,0",S.offset=(sM(T[0])||0)+","+(sM(T[1])||0),S.origin="0 0",C.left="0px",C.top="0px"):(S.on=!1,C.left=sM(c)+"px",C.top=sM(d)+"px"),b.string=mM(o);try{b.style.font=m}catch(t){}TM(I,"fill",{fill:r.textFill,opacity:r.opacity},this),TM(I,"stroke",{stroke:r.textStroke,opacity:r.opacity,lineDash:r.lineDash},this),I.style.zIndex=_M(this.zlevel,this.z,this.z2),yM(t,I)}},BM.removeRectText=function(t){xM(t,this._textVmlEl),this._textVmlEl=null},BM.appendRectText=function(t){yM(t,this._textVmlEl)}}ov.prototype.brushVML=function(t){var e=this.style;null!=e.text?this.drawRectText(t,{x:e.x||0,y:e.y||0,width:0,height:0},this.getBoundingRect(),!0):this.removeRectText(t)},ov.prototype.onRemove=function(t){this.removeRectText(t)},ov.prototype.onAdd=function(t){this.appendRectText(t)}}yf.prototype={constructor:yf,getType:function(){return"vml"},getViewportRoot:function(){return this._vmlViewport},getViewportRootOffset:function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},refresh:function(){var t=this.storage.getDisplayList(!0,!0);this._paintList(t)},_paintList:function(t){for(var e=this._vmlRoot,n=0;n<t.length;n++){var i=t[n];i.invisible||i.ignore?(i.__alreadyNotVisible||i.onRemove(e),i.__alreadyNotVisible=!0):(i.__alreadyNotVisible&&i.onAdd(e),i.__alreadyNotVisible=!1,i.__dirty&&(i.beforeBrush&&i.beforeBrush(),(i.brushVML||i.brush).call(i,e),i.afterBrush&&i.afterBrush())),i.__dirty=!1}this._firstPaint&&(this._vmlViewport.appendChild(e),this._firstPaint=!1)},resize:function(t,e){var t=null==t?this._getWidth():t,e=null==e?this._getHeight():e;if(this._width!=t||this._height!=e){this._width=t,this._height=e;var n=this._vmlViewport.style;n.width=t+"px",n.height=e+"px"}},dispose:function(){this.root.innerHTML="",this._vmlRoot=this._vmlViewport=this.storage=null},getWidth:function(){return this._width},getHeight:function(){return this._height},clear:function(){this._vmlViewport&&this.root.removeChild(this._vmlViewport)},_getWidth:function(){var t=this.root,e=t.currentStyle;return(t.clientWidth||vf(e.width))-vf(e.paddingLeft)-vf(e.paddingRight)|0},_getHeight:function(){var t=this.root,e=t.currentStyle;return(t.clientHeight||vf(e.height))-vf(e.paddingTop)-vf(e.paddingBottom)|0}},d(["getLayer","insertLayer","eachLayer","eachBuiltinLayer","eachOtherLayer","getLayers","modLayer","delLayer","clearLayer","toDataURL","pathToImage"],function(t){yf.prototype[t]=xf(t)}),vn("vml",yf);var VM="http://www.w3.org/2000/svg",FM=Em.CMD,HM=Array.prototype.join,GM="none",WM=Math.round,ZM=Math.sin,UM=Math.cos,XM=Math.PI,jM=2*Math.PI,YM=180/XM,qM=1e-4,$M={};$M.brush=function(t){var e=t.style,n=t.__svgEl;n||(n=_f("path"),t.__svgEl=n),t.path||t.createPathProxy();var i=t.path;if(t.__dirtyPath){i.beginPath(),t.buildPath(i,t.shape),t.__dirtyPath=!1;var r=Af(i);r.indexOf("NaN")<0&&Tf(n,"d",r)}Df(n,e),If(n,t.transform),null!=e.text&&tI(t,t.getBoundingRect())};var KM={};KM.brush=function(t){var e=t.style,n=e.image;if(n instanceof HTMLImageElement&&(n=n.src),n){var i=e.x||0,r=e.y||0,o=e.width,a=e.height,s=t.__svgEl;s||(s=_f("image"),t.__svgEl=s),n!==t.__imageSrc&&(Cf(s,"href",n),t.__imageSrc=n),Tf(s,"width",o),Tf(s,"height",a),Tf(s,"x",i),Tf(s,"y",r),If(s,t.transform),null!=e.text&&tI(t,t.getBoundingRect())}};var QM={},JM=new Xt,tI=function(t,e,n){var i=t.style;t.__dirty&&De(i);var r=i.text;if(null!=r){r+="";var o=t.__textSvgEl;o||(o=_f("text"),t.__textSvgEl=o);var a,s,l=i.textPosition,h=i.textDistance,u=i.textAlign||"left";"number"==typeof i.fontSize&&(i.fontSize+="px");var c=i.font||[i.fontStyle||"",i.fontWeight||"",i.fontSize||"",i.fontFamily||""].join(" ")||yg,d=kf(i.textVerticalAlign),f=(n=ce(r,c,u,d)).lineHeight;if(l instanceof Array)a=e.x+l[0],s=e.y+l[1];else{var p=me(l,e,h);a=p.x,s=p.y,d=kf(p.textVerticalAlign),u=p.textAlign}Tf(o,"alignment-baseline",d),c&&(o.style.font=c);var g=i.textPadding;if(Tf(o,"x",a),Tf(o,"y",s),Df(o,i,!0),t instanceof ov||t.style.transformText)If(o,t.transform);else{if(t.transform)JM.copy(e),JM.applyTransform(t.transform),e=JM;else{var m=t.transformCoordToGlobal(e.x,e.y);e.x=m[0],e.y=m[1]}var v=i.textOrigin;"center"===v?(a=n.width/2+a,s=n.height/2+s):v&&(a=v[0]+a,s=v[1]+s),Tf(o,"transform","rotate("+180*-i.textRotation/Math.PI+","+a+","+s+")")}var y=r.split("\n"),x=y.length,_=u;"left"===_?(_="start",g&&(a+=g[3])):"right"===_?(_="end",g&&(a-=g[1])):"center"===_&&(_="middle",g&&(a+=(g[3]-g[1])/2));var w=0;if("baseline"===d?(w=-n.height+f,g&&(w-=g[2])):"middle"===d?(w=(-n.height+f)/2,g&&(s+=(g[0]-g[2])/2)):g&&(w+=g[0]),t.__text!==r||t.__textFont!==c){var b=t.__tspanList||[];t.__tspanList=b;for(M=0;M<x;M++)(I=b[M])?I.innerHTML="":(I=b[M]=_f("tspan"),o.appendChild(I),Tf(I,"alignment-baseline",d),Tf(I,"text-anchor",_)),Tf(I,"x",a),Tf(I,"y",s+M*f+w),I.appendChild(document.createTextNode(y[M]));for(;M<b.length;M++)o.removeChild(b[M]);b.length=x,t.__text=r,t.__textFont=c}else if(t.__tspanList.length)for(var S=t.__tspanList.length,M=0;M<S;++M){var I=t.__tspanList[M];I&&(Tf(I,"x",a),Tf(I,"y",s+M*f+w))}}};QM.drawRectText=tI,QM.brush=function(t){var e=t.style;null!=e.text&&(e.textPosition=[0,0],tI(t,{x:e.x||0,y:e.y||0,width:0,height:0},t.getBoundingRect()))},Pf.prototype={diff:function(t,e,n){n||(n=function(t,e){return t===e}),this.equals=n;var i=this;t=t.slice();var r=(e=e.slice()).length,o=t.length,a=1,s=r+o,l=[{newPos:-1,components:[]}],h=this.extractCommon(l[0],e,t,0);if(l[0].newPos+1>=r&&h+1>=o){for(var u=[],c=0;c<e.length;c++)u.push(c);return[{indices:u,count:e.length}]}for(;a<=s;){var d=function(){for(var n=-1*a;n<=a;n+=2){var s,h=l[n-1],u=l[n+1],c=(u?u.newPos:0)-n;h&&(l[n-1]=void 0);var d=h&&h.newPos+1<r,f=u&&0<=c&&c<o;if(d||f){if(!d||f&&h.newPos<u.newPos?(s=Of(u),i.pushComponent(s.components,void 0,!0)):((s=h).newPos++,i.pushComponent(s.components,!0,void 0)),c=i.extractCommon(s,e,t,n),s.newPos+1>=r&&c+1>=o)return Lf(0,s.components);l[n]=s}else l[n]=void 0}a++}();if(d)return d}},pushComponent:function(t,e,n){var i=t[t.length-1];i&&i.added===e&&i.removed===n?t[t.length-1]={count:i.count+1,added:e,removed:n}:t.push({count:1,added:e,removed:n})},extractCommon:function(t,e,n,i){for(var r=e.length,o=n.length,a=t.newPos,s=a-i,l=0;a+1<r&&s+1<o&&this.equals(e[a+1],n[s+1]);)a++,s++,l++;return l&&t.components.push({count:l}),t.newPos=a,s},tokenize:function(t){return t.slice()},join:function(t){return t.slice()}};var eI=new Pf,nI=function(t,e,n){return eI.diff(t,e,n)};zf.prototype.createElement=_f,zf.prototype.getDefs=function(t){var e=this._svgRoot,n=this._svgRoot.getElementsByTagName("defs");return 0===n.length?t?((n=e.insertBefore(this.createElement("defs"),e.firstChild)).contains||(n.contains=function(t){var e=n.children;if(!e)return!1;for(var i=e.length-1;i>=0;--i)if(e[i]===t)return!0;return!1}),n):null:n[0]},zf.prototype.update=function(t,e){if(t){var n=this.getDefs(!1);if(t[this._domName]&&n.contains(t[this._domName]))"function"==typeof e&&e(t);else{var i=this.add(t);i&&(t[this._domName]=i)}}},zf.prototype.addDom=function(t){this.getDefs(!0).appendChild(t)},zf.prototype.removeDom=function(t){var e=this.getDefs(!1);e&&t[this._domName]&&(e.removeChild(t[this._domName]),t[this._domName]=null)},zf.prototype.getDoms=function(){var t=this.getDefs(!1);if(!t)return[];var e=[];return d(this._tagNames,function(n){var i=t.getElementsByTagName(n);e=e.concat([].slice.call(i))}),e},zf.prototype.markAllUnused=function(){var t=this;d(this.getDoms(),function(e){e[t._markLabel]="0"})},zf.prototype.markUsed=function(t){t&&(t[this._markLabel]="1")},zf.prototype.removeUnused=function(){var t=this.getDefs(!1);if(t){var e=this;d(this.getDoms(),function(n){"1"!==n[e._markLabel]&&t.removeChild(n)})}},zf.prototype.getSvgProxy=function(t){return t instanceof xi?$M:t instanceof je?KM:t instanceof ov?QM:$M},zf.prototype.getTextSvgElement=function(t){return t.__textSvgEl},zf.prototype.getSvgElement=function(t){return t.__svgEl},h(Ef,zf),Ef.prototype.addWithoutUpdate=function(t,e){if(e&&e.style){var n=this;d(["fill","stroke"],function(i){if(e.style[i]&&("linear"===e.style[i].type||"radial"===e.style[i].type)){var r,o=e.style[i],a=n.getDefs(!0);o._dom?(r=o._dom,a.contains(o._dom)||n.addDom(r)):r=n.add(o),n.markUsed(e);var s=r.getAttribute("id");t.setAttribute(i,"url(#"+s+")")}})}},Ef.prototype.add=function(t){var e;if("linear"===t.type)e=this.createElement("linearGradient");else{if("radial"!==t.type)return jp("Illegal gradient type."),null;e=this.createElement("radialGradient")}return t.id=t.id||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-gradient-"+t.id),this.updateDom(t,e),this.addDom(e),e},Ef.prototype.update=function(t){var e=this;zf.prototype.update.call(this,t,function(){var n=t.type,i=t._dom.tagName;"linear"===n&&"linearGradient"===i||"radial"===n&&"radialGradient"===i?e.updateDom(t,t._dom):(e.removeDom(t),e.add(t))})},Ef.prototype.updateDom=function(t,e){if("linear"===t.type)e.setAttribute("x1",t.x),e.setAttribute("y1",t.y),e.setAttribute("x2",t.x2),e.setAttribute("y2",t.y2);else{if("radial"!==t.type)return void jp("Illegal gradient type.");e.setAttribute("cx",t.x),e.setAttribute("cy",t.y),e.setAttribute("r",t.r)}t.global?e.setAttribute("gradientUnits","userSpaceOnUse"):e.setAttribute("gradientUnits","objectBoundingBox"),e.innerHTML="";for(var n=t.colorStops,i=0,r=n.length;i<r;++i){var o=this.createElement("stop");o.setAttribute("offset",100*n[i].offset+"%"),o.setAttribute("stop-color",n[i].color),e.appendChild(o)}t._dom=e},Ef.prototype.markUsed=function(t){if(t.style){var e=t.style.fill;e&&e._dom&&zf.prototype.markUsed.call(this,e._dom),(e=t.style.stroke)&&e._dom&&zf.prototype.markUsed.call(this,e._dom)}},h(Nf,zf),Nf.prototype.update=function(t){var e=this.getSvgElement(t);e&&this.updateDom(e,t.__clipPaths,!1);var n=this.getTextSvgElement(t);n&&this.updateDom(n,t.__clipPaths,!0),this.markUsed(t)},Nf.prototype.updateDom=function(t,e,n){if(e&&e.length>0){var i,r,o=this.getDefs(!0),a=e[0],s=n?"_textDom":"_dom";a[s]?(r=a[s].getAttribute("id"),i=a[s],o.contains(i)||o.appendChild(i)):(r="zr"+this._zrId+"-clip-"+this.nextId,++this.nextId,(i=this.createElement("clipPath")).setAttribute("id",r),o.appendChild(i),a[s]=i);var l=this.getSvgProxy(a);if(a.transform&&a.parent.invTransform&&!n){var h=Array.prototype.slice.call(a.transform);st(a.transform,a.parent.invTransform,a.transform),l.brush(a),a.transform=h}else l.brush(a);var u=this.getSvgElement(a);i.innerHTML="",i.appendChild(u.cloneNode()),t.setAttribute("clip-path","url(#"+r+")"),e.length>1&&this.updateDom(i,e.slice(1),n)}else t&&t.setAttribute("clip-path","none")},Nf.prototype.markUsed=function(t){var e=this;t.__clipPaths&&t.__clipPaths.length>0&&d(t.__clipPaths,function(t){t._dom&&zf.prototype.markUsed.call(e,t._dom),t._textDom&&zf.prototype.markUsed.call(e,t._textDom)})},h(Rf,zf),Rf.prototype.addWithoutUpdate=function(t,e){if(e&&Bf(e.style)){var n,i=e.style;i._shadowDom?(n=i._shadowDom,this.getDefs(!0).contains(i._shadowDom)||this.addDom(n)):n=this.add(e),this.markUsed(e);var r=n.getAttribute("id");t.style.filter="url(#"+r+")"}},Rf.prototype.add=function(t){var e=this.createElement("filter"),n=t.style;return n._shadowDomId=n._shadowDomId||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-shadow-"+n._shadowDomId),this.updateDom(t,e),this.addDom(e),e},Rf.prototype.update=function(t,e){var n=e.style;if(Bf(n)){var i=this;zf.prototype.update.call(this,e,function(t){i.updateDom(e,t._shadowDom)})}else this.remove(t,n)},Rf.prototype.remove=function(t,e){null!=e._shadowDomId&&(this.removeDom(e),t.style.filter="")},Rf.prototype.updateDom=function(t,e){var n=e.getElementsByTagName("feDropShadow");n=0===n.length?this.createElement("feDropShadow"):n[0];var i,r,o,a,s=t.style,l=t.scale?t.scale[0]||1:1,h=t.scale?t.scale[1]||1:1;if(s.shadowBlur||s.shadowOffsetX||s.shadowOffsetY)i=s.shadowOffsetX||0,r=s.shadowOffsetY||0,o=s.shadowBlur,a=s.shadowColor;else{if(!s.textShadowBlur)return void this.removeDom(e,s);i=s.textShadowOffsetX||0,r=s.textShadowOffsetY||0,o=s.textShadowBlur,a=s.textShadowColor}n.setAttribute("dx",i/l),n.setAttribute("dy",r/h),n.setAttribute("flood-color",a);var u=o/2/l+" "+o/2/h;n.setAttribute("stdDeviation",u),e.setAttribute("x","-100%"),e.setAttribute("y","-100%"),e.setAttribute("width",Math.ceil(o/2*200)+"%"),e.setAttribute("height",Math.ceil(o/2*200)+"%"),e.appendChild(n),s._shadowDom=e},Rf.prototype.markUsed=function(t){var e=t.style;e&&e._shadowDom&&zf.prototype.markUsed.call(this,e._shadowDom)};var iI=function(t,e,n,i){this.root=t,this.storage=e,this._opts=n=o({},n||{});var r=_f("svg");r.setAttribute("xmlns","http://www.w3.org/2000/svg"),r.setAttribute("version","1.1"),r.setAttribute("baseProfile","full"),r.style.cssText="user-select:none;position:absolute;left:0;top:0;",this.gradientManager=new Ef(i,r),this.clipPathManager=new Nf(i,r),this.shadowManager=new Rf(i,r);var a=document.createElement("div");a.style.cssText="overflow:hidden;position:relative",this._svgRoot=r,this._viewport=a,t.appendChild(a),a.appendChild(r),this.resize(n.width,n.height),this._visibleList=[]};iI.prototype={constructor:iI,getType:function(){return"svg"},getViewportRoot:function(){return this._viewport},getViewportRootOffset:function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},refresh:function(){var t=this.storage.getDisplayList(!0);this._paintList(t)},setBackgroundColor:function(t){this._viewport.style.background=t},_paintList:function(t){this.gradientManager.markAllUnused(),this.clipPathManager.markAllUnused(),this.shadowManager.markAllUnused();var e,n=this._svgRoot,i=this._visibleList,r=t.length,o=[];for(e=0;e<r;e++){var a=Ff(f=t[e]),s=Xf(f)||Uf(f);f.invisible||(f.__dirty&&(a&&a.brush(f),this.clipPathManager.update(f),f.style&&(this.gradientManager.update(f.style.fill),this.gradientManager.update(f.style.stroke),this.shadowManager.update(s,f)),f.__dirty=!1),o.push(f))}var l,h=nI(i,o);for(e=0;e<h.length;e++)if((c=h[e]).removed)for(d=0;d<c.count;d++){var s=Xf(f=i[c.indices[d]]),u=Uf(f);Zf(n,s),Zf(n,u)}for(e=0;e<h.length;e++){var c=h[e];if(c.added)for(d=0;d<c.count;d++){var s=Xf(f=o[c.indices[d]]),u=Uf(f);l?Gf(n,s,l):Wf(n,s),s?Gf(n,u,s):l?Gf(n,u,l):Wf(n,u),Gf(n,u,s),l=u||s||l,this.gradientManager.addWithoutUpdate(s,f),this.shadowManager.addWithoutUpdate(l,f),this.clipPathManager.markUsed(f)}else if(!c.removed)for(var d=0;d<c.count;d++){var f=o[c.indices[d]];l=s=Uf(f)||Xf(f)||l,this.gradientManager.markUsed(f),this.gradientManager.addWithoutUpdate(s,f),this.shadowManager.markUsed(f),this.shadowManager.addWithoutUpdate(s,f),this.clipPathManager.markUsed(f)}}this.gradientManager.removeUnused(),this.clipPathManager.removeUnused(),this.shadowManager.removeUnused(),this._visibleList=o},_getDefs:function(t){var e=this._svgRoot,n=this._svgRoot.getElementsByTagName("defs");return 0===n.length?t?((n=e.insertBefore(_f("defs"),e.firstChild)).contains||(n.contains=function(t){var e=n.children;if(!e)return!1;for(var i=e.length-1;i>=0;--i)if(e[i]===t)return!0;return!1}),n):null:n[0]},resize:function(t,e){var n=this._viewport;n.style.display="none";var i=this._opts;if(null!=t&&(i.width=t),null!=e&&(i.height=e),t=this._getSize(0),e=this._getSize(1),n.style.display="",this._width!==t||this._height!==e){this._width=t,this._height=e;var r=n.style;r.width=t+"px",r.height=e+"px";var o=this._svgRoot;o.setAttribute("width",t),o.setAttribute("height",e)}},getWidth:function(){return this._width},getHeight:function(){return this._height},_getSize:function(t){var e=this._opts,n=["width","height"][t],i=["clientWidth","clientHeight"][t],r=["paddingLeft","paddingTop"][t],o=["paddingRight","paddingBottom"][t];if(null!=e[n]&&"auto"!==e[n])return parseFloat(e[n]);var a=this.root,s=document.defaultView.getComputedStyle(a);return(a[i]||Vf(s[n])||Vf(a.style[n]))-(Vf(s[r])||0)-(Vf(s[o])||0)|0},dispose:function(){this.root.innerHTML="",this._svgRoot=this._viewport=this.storage=null},clear:function(){this._viewport&&this.root.removeChild(this._viewport)},pathToDataUrl:function(){return this.refresh(),"data:image/svg+xml;charset=UTF-8,"+this._svgRoot.outerHTML}},d(["getLayer","insertLayer","eachLayer","eachBuiltinLayer","eachOtherLayer","getLayers","modLayer","delLayer","clearLayer","toDataURL","pathToImage"],function(t){iI.prototype[t]=jf(t)}),vn("svg",iI),t.version="4.0.4",t.dependencies=dx,t.PRIORITY=mx,t.init=function(t,e,n){var i=qa(t);if(i)return i;var r=new Da(t,e,n);return r.id="ec_"+zx++,Lx[r.id]=r,Pn(t,Nx,r.id),ja(r),r},t.connect=function(t){if(y(t)){var e=t;t=null,lx(e,function(e){null!=e.group&&(t=e.group)}),t=t||"g_"+Ex++,lx(e,function(e){e.group=t})}return Ox[t]=!0,t},t.disConnect=Ya,t.disconnect=Bx,t.dispose=function(t){"string"==typeof t?t=Lx[t]:t instanceof Da||(t=qa(t)),t instanceof Da&&!t.isDisposed()&&t.dispose()},t.getInstanceByDom=qa,t.getInstanceById=function(t){return Lx[t]},t.registerTheme=$a,t.registerPreprocessor=Ka,t.registerProcessor=Qa,t.registerPostUpdate=function(t){Dx.push(t)},t.registerAction=Ja,t.registerCoordinateSystem=function(t,e){yo.register(t,e)},t.getCoordinateSystemDimensions=function(t){var e=yo.get(t);if(e)return e.getDimensionsInfo?e.getDimensionsInfo():e.dimensions.slice()},t.registerLayout=ts,t.registerVisual=es,t.registerLoading=is,t.extendComponentModel=rs,t.extendComponentView=os,t.extendSeriesModel=as,t.extendChartView=ss,t.setCanvasCreator=function(t){e("createCanvas",t)},t.registerMap=function(t,e,n){e.geoJson&&!e.features&&(n=e.specialAreas,e=e.geoJson),"string"==typeof e&&(e="undefined"!=typeof JSON&&JSON.parse?JSON.parse(e):new Function("return ("+e+");")()),Rx[t]={geoJson:e,specialAreas:n}},t.getMap=function(t){return Rx[t]},t.dataTool=Vx,t.zrender=Wg,t.graphic=Av,t.number=Vv,t.format=Uv,t.throttle=la,t.helper=A_,t.matrix=Mp,t.vector=vp,t.color=Hp,t.parseGeoJSON=P_,t.parseGeoJson=E_,t.util=N_,t.List=Yx,t.Model=pr,t.Axis=z_,t.env=Kf}); adminSystem - Gogs: Go Git Service

No Description

union.js 749B

    var baseFlatten = require('./_baseFlatten'), baseRest = require('./_baseRest'), baseUniq = require('./_baseUniq'), isArrayLikeObject = require('./isArrayLikeObject'); /** * Creates an array of unique values, in order, from all given arrays using * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) * for equality comparisons. * * @static * @memberOf _ * @since 0.1.0 * @category Array * @param {...Array} [arrays] The arrays to inspect. * @returns {Array} Returns the new array of combined values. * @example * * _.union([2], [1, 2]); * // => [2, 1] */ var union = baseRest(function(arrays) { return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true)); }); module.exports = union;