0&&e.arc(c+Z.cx,h+Z.cy,j,yy(Z.y0,Z.x0),yy(Z.y1,Z.x1),!d),e.arc(c,h,r,yy(Z.cy+Z.y1,Z.cx+Z.x1),yy(Y.cy+Y.y1,Y.cx+Y.x1),d),U>0&&e.arc(c+Y.cx,h+Y.cy,U,yy(Y.y1,Y.x1),yy(Y.y0,Y.x0),!d))}else e.lineTo(c+O,h+R),e.arc(c,h,r,u,l,d);else e.lineTo(c+O,h+R)}else e.moveTo(c,h);e.closePath()}}}var Ty=function(){function e(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0,this.cornerRadius=0}return e}(),ky=function(e){function t(t){return e.call(this,t)||this}return De(t,e),t.prototype.getDefaultShape=function(){return new Ty},t.prototype.buildPath=function(e,t){Iy(e,t)},t.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},t}($l);ky.prototype.type="sector";const Ay=ky;var Dy=function(){function e(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return e}(),Ly=function(e){function t(t){return e.call(this,t)||this}return De(t,e),t.prototype.getDefaultShape=function(){return new Dy},t.prototype.buildPath=function(e,t){var n=t.cx,i=t.cy,r=2*Math.PI;e.moveTo(n+t.r,i),e.arc(n,i,t.r,0,r,!1),e.moveTo(n+t.r0,i),e.arc(n,i,t.r0,0,r,!0)},t}($l);Ly.prototype.type="ring";const Py=Ly;function Oy(e,t,n,i){var r,o,a,s,l=[],u=[],c=[],h=[];if(i){a=[1/0,1/0],s=[-1/0,-1/0];for(var d=0,p=e.length;d=2){if(i){var o=Oy(r,i,n,t.smoothConstraint);e.moveTo(r[0][0],r[0][1]);for(var a=r.length,s=0;s<(n?a:a-1);s++){var l=o[2*s],u=o[2*s+1],c=r[(s+1)%a];e.bezierCurveTo(l[0],l[1],u[0],u[1],c[0],c[1])}}else{e.moveTo(r[0][0],r[0][1]);s=1;for(var h=r.length;slm[1]){if(a=!1,r)return a;var u=Math.abs(lm[0]-sm[1]),c=Math.abs(sm[0]-lm[1]);Math.min(u,c)>i.len()&&(uMath.abs(o[1])?o[0]>0?"right":"left":o[1]>0?"bottom":"top"}function Em(e){return!e.isGroup}function Nm(e){return null!=e.shape}function Bm(e,t,n){if(e&&t){var i=r(e);t.traverse((function(e){if(Em(e)&&e.anid){var t=i[e.anid];if(t){var r=o(e);e.attr(o(t)),Xc(e,r,n,Lu(e).dataIndex)}}}))}function r(e){var t={};return e.traverse((function(e){Em(e)&&e.anid&&(t[e.anid]=e)})),t}function o(e){var t={x:e.x,y:e.y,rotation:e.rotation};return Nm(e)&&(t.shape=B({},e.shape)),t}}function Fm(e,t){return W(e,(function(e){var n=e[0];n=vm(n,t.x),n=ym(n,t.x+t.width);var i=e[1];return i=vm(i,t.y),i=ym(i,t.y+t.height),[n,i]}))}function zm(e,t){var n=vm(e.x,t.x),i=ym(e.x+e.width,t.x+t.width),r=vm(e.y,t.y),o=ym(e.y+e.height,t.y+t.height);if(i>=n&&o>=r)return{x:n,y:r,width:i-n,height:o-r}}function Vm(e,t,n){var i=B({rectHover:!0},t),r=i.style={strokeNoScale:!0};if(n=n||{x:-1,y:-1,width:2,height:2},e)return 0===e.indexOf("image://")?(r.image=e.slice(8),F(r,n),new iu(i)):Mm(e.replace("path://",""),i,n,"center")}function Hm(e,t,n,i,r){for(var o=0,a=r[r.length-1];o1)return!1;var v=Gm(p,f,c,h)/d;return!(v<0||v>1)}function Gm(e,t,n,i){return e*i-n*t}function Wm(e){return e<=1e-6&&e>=-1e-6}function Um(e){var t=e.itemTooltipOption,n=e.componentModel,i=e.itemName,r=ee(t)?{formatter:t}:t,o=n.mainType,a=n.componentIndex,s={componentType:o,name:i,$vars:["name"]};s[o+"Index"]=a;var l=e.formatterParamsExtra;l&&G(Y(l),(function(e){Ie(s,e)||(s[e]=l[e],s.$vars.push(e))}));var u=Lu(e.el);u.componentMainType=o,u.componentIndex=a,u.tooltipConfig={name:i,option:F({content:i,formatterParams:s},r)}}function jm(e,t){var n;e.isGroup&&(n=t(e)),n||e.traverse(t)}function Zm(e,t){if(e)if(J(e))for(var n=0;n=0?h():c=setTimeout(h,-r),l=i};return d.clear=function(){c&&(clearTimeout(c),c=null)},d.debounceNextCall=function(e){s=e},d}function sx(e,t,n,i){var r=e[t];if(r){var o=r[ix]||r,a=r[ox],s=r[rx];if(s!==n||a!==i){if(null==n||!i)return e[t]=o;r=e[t]=ax(o,n,"debounce"===i),r[ix]=o,r[ox]=i,r[rx]=n}return r}}function lx(e,t){var n=e[t];n&&n[ix]&&(n.clear&&n.clear(),e[t]=n[ix])}var ux=Ba(),cx={itemStyle:us(Ah,!0),lineStyle:us(Ih,!0)},hx={lineStyle:"stroke",itemStyle:"fill"};function dx(e,t){var n=e.visualStyleMapper||cx[t];return n||(console.warn("Unkown style type '"+t+"'."),cx.itemStyle)}function px(e,t){var n=e.visualDrawType||hx[t];return n||(console.warn("Unkown style type '"+t+"'."),"fill")}var fx={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var n=e.getData(),i=e.visualStyleAccessPath||"itemStyle",r=e.getModel(i),o=dx(e,i),a=o(r),s=r.getShallow("decal");s&&(n.setVisual("decal",s),s.dirty=!0);var l=px(e,i),u=a[l],c=Q(u)?u:null,h="auto"===a.fill||"auto"===a.stroke;if(!a[l]||c||h){var d=e.getColorFromPalette(e.name,null,t.getSeriesCount());a[l]||(a[l]=d,n.setVisual("colorFromPalette",!0)),a.fill="auto"===a.fill||Q(a.fill)?d:a.fill,a.stroke="auto"===a.stroke||Q(a.stroke)?d:a.stroke}if(n.setVisual("style",a),n.setVisual("drawType",l),!t.isSeriesFiltered(e)&&c)return n.setVisual("colorFromPalette",!1),{dataEach:function(t,n){var i=e.getDataParams(n),r=B({},a);r[l]=c(i),t.setItemVisual(n,"style",r)}}}},gx=new Oh,vx={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){if(!e.ignoreStyleOnData&&!t.isSeriesFiltered(e)){var n=e.getData(),i=e.visualStyleAccessPath||"itemStyle",r=dx(e,i),o=n.getVisual("drawType");return{dataEach:n.hasItemOption?function(e,t){var n=e.getRawDataItem(t);if(n&&n[i]){gx.option=n[i];var a=r(gx),s=e.ensureUniqueItemVisual(t,"style");B(s,a),gx.option.decal&&(e.setItemVisual(t,"decal",gx.option.decal),gx.option.decal.dirty=!0),o in a&&e.setItemVisual(t,"colorFromPalette",!1)}}:null}}}},yx={performRawSeries:!0,overallReset:function(e){var t=we();e.eachSeries((function(e){var n=e.getColorBy();if(!e.isColorBySeries()){var i=e.type+"-"+n,r=t.get(i);r||(r={},t.set(i,r)),ux(e).scope=r}})),e.eachSeries((function(t){if(!t.isColorBySeries()&&!e.isSeriesFiltered(t)){var n=t.getRawData(),i={},r=t.getData(),o=ux(t).scope,a=t.visualStyleAccessPath||"itemStyle",s=px(t,a);r.each((function(e){var t=r.getRawIndex(e);i[t]=e})),n.each((function(e){var a=i[e],l=r.getItemVisual(a,"colorFromPalette");if(l){var u=r.ensureUniqueItemVisual(a,"style"),c=n.getName(e)||e+"",h=n.count();u[s]=t.getColorFromPalette(c,o,h)}}))}}))}},mx=Math.PI;function xx(e,t){t=t||{},F(t,{text:"loading",textColor:"#000",fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255, 255, 255, 0.8)",showSpinner:!0,color:"#5470c6",spinnerRadius:10,lineWidth:5,zlevel:0});var n=new Lo,i=new du({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4});n.add(i);var r,o=new Du({style:{text:t.text,fill:t.textColor,fontSize:t.fontSize,fontWeight:t.fontWeight,fontStyle:t.fontStyle,fontFamily:t.fontFamily},zlevel:t.zlevel,z:10001}),a=new du({style:{fill:"none"},textContent:o,textConfig:{position:"right",distance:10},zlevel:t.zlevel,z:10001});return n.add(a),t.showSpinner&&(r=new Jy({shape:{startAngle:-mx/2,endAngle:-mx/2+.1,r:t.spinnerRadius},style:{stroke:t.color,lineCap:"round",lineWidth:t.lineWidth},zlevel:t.zlevel,z:10001}),r.animateShape(!0).when(1e3,{endAngle:3*mx/2}).start("circularInOut"),r.animateShape(!0).when(1e3,{startAngle:3*mx/2}).delay(300).start("circularInOut"),n.add(r)),n.resize=function(){var n=o.getBoundingRect().width,s=t.showSpinner?t.spinnerRadius:0,l=(e.getWidth()-2*s-(t.showSpinner&&n?10:0)-n)/2-(t.showSpinner&&n?0:5+n/2)+(t.showSpinner?0:n/2)+(n?0:s),u=e.getHeight()/2;t.showSpinner&&r.setShape({cx:l,cy:u}),a.setShape({x:l-s,y:u-s,width:2*s,height:2*s}),i.setShape({x:0,y:0,width:e.getWidth(),height:e.getHeight()})},n.resize(),n}var _x=function(){function e(e,t,n,i){this._stageTaskMap=we(),this.ecInstance=e,this.api=t,n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice(),this._allHandlers=n.concat(i)}return e.prototype.restoreData=function(e,t){e.restoreData(t),this._stageTaskMap.each((function(e){var t=e.overallTask;t&&t.dirty()}))},e.prototype.getPerformArgs=function(e,t){if(e.__pipeline){var n=this._pipelineMap.get(e.__pipeline.id),i=n.context,r=!t&&n.progressiveEnabled&&(!i||i.progressiveRender)&&e.__idxInPipeline>n.blockIndex,o=r?n.step:null,a=i&&i.modDataCount,s=null!=a?Math.ceil(a/o):null;return{step:o,modBy:s,modDataCount:a}}},e.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},e.prototype.updateStreamModes=function(e,t){var n=this._pipelineMap.get(e.uid),i=e.getData(),r=i.count(),o=n.progressiveEnabled&&t.incrementalPrepareRender&&r>=n.threshold,a=e.get("large")&&r>=e.get("largeThreshold"),s="mod"===e.get("progressiveChunkMode")?r:null;e.pipelineContext=n.context={progressiveRender:o,modDataCount:s,large:a}},e.prototype.restorePipelines=function(e){var t=this,n=t._pipelineMap=we();e.eachSeries((function(e){var i=e.getProgressive(),r=e.uid;n.set(r,{id:r,head:null,tail:null,threshold:e.getProgressiveThreshold(),progressiveEnabled:i&&!(e.preventIncremental&&e.preventIncremental()),blockIndex:-1,step:Math.round(i||700),count:0}),t._pipe(e,e.dataTask)}))},e.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,t=this.api.getModel(),n=this.api;G(this._allHandlers,(function(i){var r=e.get(i.uid)||e.set(i.uid,{}),o="";ve(!(i.reset&&i.overallReset),o),i.reset&&this._createSeriesStageTask(i,r,t,n),i.overallReset&&this._createOverallStageTask(i,r,t,n)}),this)},e.prototype.prepareView=function(e,t,n,i){var r=e.renderTask,o=r.context;o.model=t,o.ecModel=n,o.api=i,r.__block=!e.incrementalPrepareRender,this._pipe(t,r)},e.prototype.performDataProcessorTasks=function(e,t){this._performStageTasks(this._dataProcessorHandlers,e,t,{block:!0})},e.prototype.performVisualTasks=function(e,t,n){this._performStageTasks(this._visualHandlers,e,t,n)},e.prototype._performStageTasks=function(e,t,n,i){i=i||{};var r=!1,o=this;function a(e,t){return e.setDirty&&(!e.dirtyMap||e.dirtyMap.get(t.__pipeline.id))}G(e,(function(e,s){if(!i.visualType||i.visualType===e.visualType){var l=o._stageTaskMap.get(e.uid),u=l.seriesTaskMap,c=l.overallTask;if(c){var h,d=c.agentStubMap;d.each((function(e){a(i,e)&&(e.dirty(),h=!0)})),h&&c.dirty(),o.updatePayload(c,n);var p=o.getPerformArgs(c,i.block);d.each((function(e){e.perform(p)})),c.perform(p)&&(r=!0)}else u&&u.each((function(s,l){a(i,s)&&s.dirty();var u=o.getPerformArgs(s,i.block);u.skip=!e.performRawSeries&&t.isSeriesFiltered(s.context.model),o.updatePayload(s,n),s.perform(u)&&(r=!0)}))}})),this.unfinished=r||this.unfinished},e.prototype.performSeriesTasks=function(e){var t;e.eachSeries((function(e){t=e.dataTask.perform()||t})),this.unfinished=t||this.unfinished},e.prototype.plan=function(){this._pipelineMap.each((function(e){var t=e.tail;do{if(t.__block){e.blockIndex=t.__idxInPipeline;break}t=t.getUpstream()}while(t)}))},e.prototype.updatePayload=function(e,t){"remain"!==t&&(e.context.payload=t)},e.prototype._createSeriesStageTask=function(e,t,n,i){var r=this,o=t.seriesTaskMap,a=t.seriesTaskMap=we(),s=e.seriesType,l=e.getTargetSeries;function u(t){var s=t.uid,l=a.set(s,o&&o.get(s)||dg({plan:Ix,reset:Tx,count:Dx}));l.context={model:t,ecModel:n,api:i,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:r},r._pipe(t,l)}e.createOnAllSeries?n.eachRawSeries(u):s?n.eachRawSeriesByType(s,u):l&&l(n,i).each(u)},e.prototype._createOverallStageTask=function(e,t,n,i){var r=this,o=t.overallTask=t.overallTask||dg({reset:bx});o.context={ecModel:n,api:i,overallReset:e.overallReset,scheduler:r};var a=o.agentStubMap,s=o.agentStubMap=we(),l=e.seriesType,u=e.getTargetSeries,c=!0,h=!1,d="";function p(e){var t=e.uid,n=s.set(t,a&&a.get(t)||(h=!0,dg({reset:Sx,onDirty:Cx})));n.context={model:e,overallProgress:c},n.agent=o,n.__block=c,r._pipe(e,n)}ve(!e.createOnAllSeries,d),l?n.eachRawSeriesByType(l,p):u?u(n,i).each(p):(c=!1,G(n.getSeries(),p)),h&&o.dirty()},e.prototype._pipe=function(e,t){var n=e.uid,i=this._pipelineMap.get(n);!i.head&&(i.head=t),i.tail&&i.tail.pipe(t),i.tail=t,t.__idxInPipeline=i.count++,t.__pipeline=i},e.wrapStageHandler=function(e,t){return Q(e)&&(e={overallReset:e,seriesType:Lx(e)}),e.uid=Eh("stageHandler"),t&&(e.visualType=t),e},e}();function bx(e){e.overallReset(e.ecModel,e.api,e.payload)}function Sx(e){return e.overallProgress&&Mx}function Mx(){this.agent.dirty(),this.getDownstream().dirty()}function Cx(){this.agent&&this.agent.dirty()}function Ix(e){return e.plan?e.plan(e.model,e.ecModel,e.api,e.payload):null}function Tx(e){e.useClearVisual&&e.data.clearAllVisual();var t=e.resetDefines=ga(e.reset(e.model,e.ecModel,e.api,e.payload));return t.length>1?W(t,(function(e,t){return Ax(t)})):kx}var kx=Ax(0);function Ax(e){return function(t,n){var i=n.data,r=n.resetDefines[e];if(r&&r.dataEach)for(var o=t.start;o0&&c===r.length-u.length){var h=r.slice(0,c);"data"!==h&&(t.mainType=h,t[u.toLowerCase()]=e,s=!0)}}a.hasOwnProperty(r)&&(n[r]=e,s=!0),s||(i[r]=e)}))}return{cptQuery:t,dataQuery:n,otherQuery:i}},e.prototype.filter=function(e,t){var n=this.eventInfo;if(!n)return!0;var i=n.targetEl,r=n.packedEvent,o=n.model,a=n.view;if(!o||!a)return!0;var s=t.cptQuery,l=t.dataQuery;return u(s,o,"mainType")&&u(s,o,"subType")&&u(s,o,"index","componentIndex")&&u(s,o,"name")&&u(s,o,"id")&&u(l,r,"name")&&u(l,r,"dataIndex")&&u(l,r,"dataType")&&(!a.filterForExposedEvent||a.filterForExposedEvent(e,t.otherQuery,i,r));function u(e,t,n,i){return null==e[n]||t[i||n]===e[n]}},e.prototype.afterTrigger=function(){this.eventInfo=null},e}(),jx=["symbol","symbolSize","symbolRotate","symbolOffset"],Zx=jx.concat(["symbolKeepAspect"]),Yx={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var n=e.getData();if(e.legendIcon&&n.setVisual("legendIcon",e.legendIcon),e.hasSymbolVisual){for(var i={},r={},o=!1,a=0;a=0&&x_(l)?l:.5;var u=e.createRadialGradient(a,s,0,a,s,l);return u}function w_(e,t,n){for(var i="radial"===t.type?b_(e,t,n):__(e,t,n),r=t.colorStops,o=0;o0?"dashed"===e?[4*t,2*t]:"dotted"===e?[t]:ne(e)?[e]:J(e)?e:null:null}function T_(e){var t=e.style,n=t.lineDash&&t.lineWidth>0&&I_(t.lineDash,t.lineWidth),i=t.lineDashOffset;if(n){var r=t.strokeNoScale&&e.getLineScale?e.getLineScale():1;r&&1!==r&&(n=W(n,(function(e){return e/r})),i/=r)}return[n,i]}var k_=new Sl(!0);function A_(e){var t=e.stroke;return!(null==t||"none"===t||!(e.lineWidth>0))}function D_(e){return"string"===typeof e&&"none"!==e}function L_(e){var t=e.fill;return null!=t&&"none"!==t}function P_(e,t){if(null!=t.fillOpacity&&1!==t.fillOpacity){var n=e.globalAlpha;e.globalAlpha=t.fillOpacity*t.opacity,e.fill(),e.globalAlpha=n}else e.fill()}function O_(e,t){if(null!=t.strokeOpacity&&1!==t.strokeOpacity){var n=e.globalAlpha;e.globalAlpha=t.strokeOpacity*t.opacity,e.stroke(),e.globalAlpha=n}else e.stroke()}function R_(e,t,n){var i=gs(t.image,t.__image,n);if(ys(i)){var r=e.createPattern(i,t.repeat||"repeat");if("function"===typeof DOMMatrix&&r&&r.setTransform){var o=new DOMMatrix;o.translateSelf(t.x||0,t.y||0),o.rotateSelf(0,0,(t.rotation||0)*ke),o.scaleSelf(t.scaleX||1,t.scaleY||1),r.setTransform(o)}return r}}function E_(e,t,n,i){var r,o=A_(n),a=L_(n),s=n.strokePercent,l=s<1,u=!t.path;t.silent&&!l||!u||t.createPathProxy();var c=t.path||k_,h=t.__dirty;if(!i){var d=n.fill,p=n.stroke,f=a&&!!d.colorStops,g=o&&!!p.colorStops,v=a&&!!d.image,y=o&&!!p.image,m=void 0,x=void 0,_=void 0,b=void 0,w=void 0;(f||g)&&(w=t.getBoundingRect()),f&&(m=h?w_(e,d,w):t.__canvasFillGradient,t.__canvasFillGradient=m),g&&(x=h?w_(e,p,w):t.__canvasStrokeGradient,t.__canvasStrokeGradient=x),v&&(_=h||!t.__canvasFillPattern?R_(e,d,t):t.__canvasFillPattern,t.__canvasFillPattern=_),y&&(b=h||!t.__canvasStrokePattern?R_(e,p,t):t.__canvasStrokePattern,t.__canvasStrokePattern=_),f?e.fillStyle=m:v&&(_?e.fillStyle=_:a=!1),g?e.strokeStyle=x:y&&(b?e.strokeStyle=b:o=!1)}var S,M,C=t.getGlobalScale();c.setScale(C[0],C[1],t.segmentIgnoreThreshold),e.setLineDash&&n.lineDash&&(r=T_(t),S=r[0],M=r[1]);var I=!0;(u||h&$t)&&(c.setDPR(e.dpr),l?c.setContext(null):(c.setContext(e),I=!1),c.reset(),t.buildPath(c,t.shape,i),c.toStatic(),t.pathUpdated()),I&&c.rebuildPath(e,l?s:1),S&&(e.setLineDash(S),e.lineDashOffset=M),i||(n.strokeFirst?(o&&O_(e,n),a&&P_(e,n)):(a&&P_(e,n),o&&O_(e,n))),S&&e.setLineDash([])}function N_(e,t,n){var i=t.__image=gs(n.image,t.__image,t,t.onload);if(i&&ys(i)){var r=n.x||0,o=n.y||0,a=t.getWidth(),s=t.getHeight(),l=i.width/i.height;if(null==a&&null!=s?a=s*l:null==s&&null!=a?s=a/l:null==a&&null==s&&(a=i.width,s=i.height),n.sWidth&&n.sHeight){var u=n.sx||0,c=n.sy||0;e.drawImage(i,u,c,n.sWidth,n.sHeight,r,o,a,s)}else if(n.sx&&n.sy){u=n.sx,c=n.sy;var h=a-u,d=s-c;e.drawImage(i,u,c,h,d,r,o,a,s)}else e.drawImage(i,r,o,a,s)}}function B_(e,t,n){var i,r=n.text;if(null!=r&&(r+=""),r){e.font=n.font||p,e.textAlign=n.textAlign,e.textBaseline=n.textBaseline;var o=void 0,a=void 0;e.setLineDash&&n.lineDash&&(i=T_(t),o=i[0],a=i[1]),o&&(e.setLineDash(o),e.lineDashOffset=a),n.strokeFirst?(A_(n)&&e.strokeText(r,n.x,n.y),L_(n)&&e.fillText(r,n.x,n.y)):(L_(n)&&e.fillText(r,n.x,n.y),A_(n)&&e.strokeText(r,n.x,n.y)),o&&e.setLineDash([])}}var F_=["shadowBlur","shadowOffsetX","shadowOffsetY"],z_=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function V_(e,t,n,i,r){var o=!1;if(!i&&(n=n||{},t===n))return!1;if(i||t.opacity!==n.opacity){K_(e,r),o=!0;var a=Math.max(Math.min(t.opacity,1),0);e.globalAlpha=isNaN(a)?Rs.opacity:a}(i||t.blend!==n.blend)&&(o||(K_(e,r),o=!0),e.globalCompositeOperation=t.blend||Rs.blend);for(var s=0;s0&&e.unfinished);e.unfinished||this._zr.flush()}}},t.prototype.getDom=function(){return this._dom},t.prototype.getId=function(){return this.id},t.prototype.getZr=function(){return this._zr},t.prototype.isSSR=function(){return this._ssr},t.prototype.setOption=function(e,t,n){if(!this[Eb])if(this._disposed)gw(this.id);else{var i,r,o;if(ie(t)&&(n=t.lazyUpdate,i=t.silent,r=t.replaceMerge,o=t.transition,t=t.notMerge),this[Eb]=!0,!this._model||t){var a=new lf(this._api),s=this._theme,l=this._model=new Yp;l.scheduler=this._scheduler,l.ssr=this._ssr,l.init(null,null,null,s,this._locale,a)}this._model.setOption(e,{replaceMerge:r},xw);var u={seriesTransition:o,optionChanged:!0};if(n)this[Nb]={silent:i,updateParams:u},this[Eb]=!1,this.getZr().wakeUp();else{try{jb(this),$b.update.call(this,null,u)}catch(wy){throw this[Nb]=null,this[Eb]=!1,wy}this._ssr||this._zr.flush(),this[Nb]=null,this[Eb]=!1,Qb.call(this,i),ew.call(this,i)}}},t.prototype.setTheme=function(){gg("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},t.prototype.getModel=function(){return this._model},t.prototype.getOption=function(){return this._model&&this._model.getOption()},t.prototype.getWidth=function(){return this._zr.getWidth()},t.prototype.getHeight=function(){return this._zr.getHeight()},t.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||yb&&window.devicePixelRatio||1},t.prototype.getRenderedCanvas=function(e){return this.renderToCanvas(e)},t.prototype.renderToCanvas=function(e){e=e||{};var t=this._zr.painter;return t.getRenderedCanvas({backgroundColor:e.backgroundColor||this._model.get("backgroundColor"),pixelRatio:e.pixelRatio||this.getDevicePixelRatio()})},t.prototype.renderToSVGString=function(e){e=e||{};var t=this._zr.painter;return t.renderToString({useViewBox:e.useViewBox})},t.prototype.getSvgDataURL=function(){if(c.svgSupported){var e=this._zr,t=e.storage.getDisplayList();return G(t,(function(e){e.stopAnimation(null,!0)})),e.painter.toDataURL()}},t.prototype.getDataURL=function(e){if(!this._disposed){e=e||{};var t=e.excludeComponents,n=this._model,i=[],r=this;G(t,(function(e){n.eachComponent({mainType:e},(function(e){var t=r._componentsMap[e.__viewId];t.group.ignore||(i.push(t),t.group.ignore=!0)}))}));var o="svg"===this._zr.painter.getType()?this.getSvgDataURL():this.renderToCanvas(e).toDataURL("image/"+(e&&e.type||"png"));return G(i,(function(e){e.group.ignore=!1})),o}gw(this.id)},t.prototype.getConnectedDataURL=function(e){if(!this._disposed){var t="svg"===e.type,n=this.group,i=Math.min,r=Math.max,o=1/0;if(Mw[n]){var a=o,s=o,l=-o,u=-o,c=[],h=e&&e.pixelRatio||this.getDevicePixelRatio();G(Sw,(function(o,h){if(o.group===n){var d=t?o.getZr().painter.getSvgDom().innerHTML:o.renderToCanvas(R(e)),p=o.getDom().getBoundingClientRect();a=i(p.left,a),s=i(p.top,s),l=r(p.right,l),u=r(p.bottom,u),c.push({dom:d,left:p.left,top:p.top})}})),a*=h,s*=h,l*=h,u*=h;var d=l-a,p=u-s,f=x.createCanvas(),g=Bo(f,{renderer:t?"svg":"canvas"});if(g.resize({width:d,height:p}),t){var v="";return G(c,(function(e){var t=e.left-a,n=e.top-s;v+=''+e.dom+""})),g.painter.getSvgRoot().innerHTML=v,e.connectedBackgroundColor&&g.painter.setBackgroundColor(e.connectedBackgroundColor),g.refreshImmediately(),g.painter.toDataURL()}return e.connectedBackgroundColor&&g.add(new du({shape:{x:0,y:0,width:d,height:p},style:{fill:e.connectedBackgroundColor}})),G(c,(function(e){var t=new iu({style:{x:e.left*h-a,y:e.top*h-s,image:e.dom}});g.add(t)})),g.refreshImmediately(),f.toDataURL("image/"+(e&&e.type||"png"))}return this.getDataURL(e)}gw(this.id)},t.prototype.convertToPixel=function(e,t){return Xb(this,"convertToPixel",e,t)},t.prototype.convertFromPixel=function(e,t){return Xb(this,"convertFromPixel",e,t)},t.prototype.containPixel=function(e,t){if(!this._disposed){var n,i=this._model,r=za(i,e);return G(r,(function(e,i){i.indexOf("Models")>=0&&G(e,(function(e){var r=e.coordinateSystem;if(r&&r.containPoint)n=n||!!r.containPoint(t);else if("seriesModels"===i){var o=this._chartsMap[e.__viewId];o&&o.containPoint&&(n=n||o.containPoint(t,e))}else 0}),this)}),this),!!n}gw(this.id)},t.prototype.getVisual=function(e,t){var n=this._model,i=za(n,e,{defaultMainType:"series"}),r=i.seriesModel;var o=r.getData(),a=i.hasOwnProperty("dataIndexInside")?i.dataIndexInside:i.hasOwnProperty("dataIndex")?o.indexOfRawIndex(i.dataIndex):null;return null!=a?Xx(o,a,t):Kx(o,t)},t.prototype.getViewOfComponentModel=function(e){return this._componentsMap[e.__viewId]},t.prototype.getViewOfSeriesModel=function(e){return this._chartsMap[e.__viewId]},t.prototype._initEvents=function(){var e=this;G(fw,(function(t){var n=function(n){var i,r=e.getModel(),o=n.target,a="globalout"===t;if(a?i={}:o&&n_(o,(function(e){var t=Lu(e);if(t&&null!=t.dataIndex){var n=t.dataModel||r.getSeriesByIndex(t.seriesIndex);return i=n&&n.getDataParams(t.dataIndex,t.dataType)||{},!0}if(t.eventData)return i=B({},t.eventData),!0}),!0),i){var s=i.componentType,l=i.componentIndex;"markLine"!==s&&"markPoint"!==s&&"markArea"!==s||(s="series",l=i.seriesIndex);var u=s&&null!=l&&r.getComponent(s,l),c=u&&e["series"===u.mainType?"_chartsMap":"_componentsMap"][u.__viewId];0,i.event=n,i.type=t,e._$eventProcessor.eventInfo={targetEl:o,packedEvent:i,model:u,view:c},e.trigger(t,i)}};n.zrEventfulCallAtLast=!0,e._zr.on(t,n,e)})),G(yw,(function(t,n){e._messageCenter.on(n,(function(e){this.trigger(n,e)}),e)})),G(["selectchanged"],(function(t){e._messageCenter.on(t,(function(e){this.trigger(t,e)}),e)})),t_(this._messageCenter,this,this._api)},t.prototype.isDisposed=function(){return this._disposed},t.prototype.clear=function(){this._disposed?gw(this.id):this.setOption({series:[]},!0)},t.prototype.dispose=function(){if(this._disposed)gw(this.id);else{this._disposed=!0;var e=this.getDom();e&&Wa(this.getDom(),Iw,"");var t=this,n=t._api,i=t._model;G(t._componentsViews,(function(e){e.dispose(i,n)})),G(t._chartsViews,(function(e){e.dispose(i,n)})),t._zr.dispose(),t._dom=t._model=t._chartsMap=t._componentsMap=t._chartsViews=t._componentsViews=t._scheduler=t._api=t._zr=t._throttledZrFlush=t._theme=t._coordSysMgr=t._messageCenter=null,delete Sw[t.id]}},t.prototype.resize=function(e){if(!this[Eb])if(this._disposed)gw(this.id);else{this._zr.resize(e);var t=this._model;if(this._loadingFX&&this._loadingFX.resize(),t){var n=t.resetOption("media"),i=e&&e.silent;this[Nb]&&(null==i&&(i=this[Nb].silent),n=!0,this[Nb]=null),this[Eb]=!0;try{n&&jb(this),$b.update.call(this,{type:"resize",animation:B({duration:0},e&&e.animation)})}catch(wy){throw this[Eb]=!1,wy}this[Eb]=!1,Qb.call(this,i),ew.call(this,i)}}},t.prototype.showLoading=function(e,t){if(this._disposed)gw(this.id);else if(ie(e)&&(t=e,e=""),e=e||"default",this.hideLoading(),ww[e]){var n=ww[e](this._api,t),i=this._zr;this._loadingFX=n,i.add(n)}},t.prototype.hideLoading=function(){this._disposed?gw(this.id):(this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null)},t.prototype.makeActionFromEvent=function(e){var t=B({},e);return t.type=yw[e.type],t},t.prototype.dispatchAction=function(e,t){if(this._disposed)gw(this.id);else if(ie(t)||(t={silent:!!t}),vw[e.type]&&this._model)if(this[Eb])this._pendingActions.push(e);else{var n=t.silent;Jb.call(this,e,n);var i=t.flush;i?this._zr.flush():!1!==i&&c.browser.weChat&&this._throttledZrFlush(),Qb.call(this,n),ew.call(this,n)}},t.prototype.updateLabelLayout=function(){pb.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},t.prototype.appendData=function(e){if(this._disposed)gw(this.id);else{var t=e.seriesIndex,n=this.getModel(),i=n.getSeriesByIndex(t);0,i.appendData(e),this._scheduler.unfinished=!0,this.getZr().wakeUp()}},t.internalField=function(){function e(e){e.clearColorPalette(),e.eachSeries((function(e){e.clearColorPalette()}))}function t(e){var t=[],n=[],i=!1;if(e.eachComponent((function(e,r){var o=r.get("zlevel")||0,a=r.get("z")||0,s=r.getZLevelKey();i=i||!!s,("series"===e?n:t).push({zlevel:o,z:a,idx:r.componentIndex,type:e,key:s})})),i){var r,o,a=t.concat(n);jt(a,(function(e,t){return e.zlevel===t.zlevel?e.z-t.z:e.zlevel-t.zlevel})),G(a,(function(t){var n=e.getComponent(t.type,t.idx),i=t.zlevel,a=t.key;null!=r&&(i=Math.max(r,i)),a?(i===r&&a!==o&&i++,o=a):o&&(i===r&&i++,o=""),r=i,n.setZLevel(i)}))}}function n(e){for(var t=[],n=e.currentStates,i=0;it.get("hoverLayerThreshold")&&!c.node&&!c.worker&&t.eachSeries((function(t){if(!t.preventUsingHoverLayer){var n=e._chartsMap[t.__viewId];n.__alive&&n.eachRendered((function(e){e.states.emphasis&&(e.states.emphasis.hoverLayer=!0)}))}}))}function r(e,t){var n=e.get("blendMode")||null;t.eachRendered((function(e){e.isGroup||(e.style.blend=n)}))}function a(e,t){if(!e.preventAutoZ){var n=e.get("z")||0,i=e.get("zlevel")||0;t.eachRendered((function(e){return s(e,n,i,-1/0),!0}))}}function s(e,t,n,i){var r=e.getTextContent(),o=e.getTextGuideLine(),a=e.isGroup;if(a)for(var l=e.childrenRef(),u=0;u0?{duration:o,delay:i.get("delay"),easing:i.get("easing")}:null;t.eachRendered((function(e){if(e.states&&e.states.emphasis){if(Jc(e))return;if(e instanceof $l&&jc(e),e.__dirty){var t=e.prevStates;t&&e.useStates(t)}if(r){e.stateTransition=a;var i=e.getTextContent(),o=e.getTextGuideLine();i&&(i.stateTransition=a),o&&(o.stateTransition=a)}e.__dirty&&n(e)}}))}jb=function(e){var t=e._scheduler;t.restorePipelines(e._model),t.prepareStageTasks(),Zb(e,!0),Zb(e,!1),t.plan()},Zb=function(e,t){for(var n=e._model,i=e._scheduler,r=t?e._componentsViews:e._chartsViews,o=t?e._componentsMap:e._chartsMap,a=e._zr,s=e._api,l=0;l