import{_ as I,m as hr,G as ot,d as G,Z as $,av as ne,l as R,c as W,b as O,o as vt,g as C,aw as yn,a2 as Ye,ax as mn,p as E,n as F,q as B,a6 as xn,v as st,h as Z,f as j,a9 as Zt,R as nt,B as Lt,am as Yt,I as vr,a1 as J,P as yt,ag as ho,ay as ee,E as U,az as $r,i as Et,r as Q,j as pt,O as ie,a5 as zs,X as vo,a as po,aA as Yr,aB as ri,aC as Vs,aD as Bs,aE as Es,aF as Ns,aG as Gs,e as Hs,a0 as Ue,S as Ur,a8 as ni,ar as Ws,aH as Zs,aI as Fs,V as $s,aJ as Ys,aK as xr,aL as Us,aM as Xs}from"./graphic-DeMuFa6Q.js";import{af as tt,A as fo,b9 as Sn,bv as _n,X as pr,ce as be,cf as Xe,a6 as fr,bo as ht,cg as Vt,ac as dr,a as it,ch as go,bb as lt,ba as ut,aS as A,ag as at,aX as Ks,ci as qs,aO as ft,c6 as Ut,ai as Nt,cj as Xr,ck as Ke,cl as Kr,d as yo,c as bn,cm as mo,bD as Pt,y as X,cn as qr,b1 as js,U as xo,a3 as At,O as Rt,M as rt,co as we,j as Y,T as Js,cp as So,K as Qs,bq as tl,b7 as el,b6 as _o,b5 as rl,bc as bo,i as wo,cq as ii,bd as jr,cr as nl,k as dt,cs as wn,ct as il,cu as Cn,R as Co,cv as To,cw as ai,x as al,cx as Tn,bQ as Ao,cy as Mo,cz as k,cA as mt,cB as oi,cC as si,cD as Bt,aZ as An,cE as Sr,cF as ol,cG as sl,cH as ll,by as ye,bH as Mn,cI as ul,_ as cl,cJ as hl,cK as vl,u as K,m as xt,cL as _r,b8 as Io,cM as Do,cN as Lo,aT as qe,cO as pl,cP as fl,cQ as dl,bI as gl,cR as yl,bV as li,bW as ui,c9 as ml,cS as Ft,ax as In,cT as Po,b3 as je,cU as xl,cV as Sl,ad as ko,aU as Je,cW as Oo,c1 as q,cX as _l,cY as Ro,bu as me,cZ as br,c_ as ci,c$ as hi,G as bl,aa as wl,d0 as Cl,d1 as zo,bG as Vo,d2 as Tl,d3 as Bo,d4 as Eo,d5 as ue,d6 as Ce,d7 as Dn,bJ as vi,cc as Al,aj as $t,bf as se,d8 as Ln,d9 as Ml,h as re,f as Xt,bw as Il,c3 as Dl,bn as Ll,da as Qe,p as Pl,db as kl,dc as Ol,dd as No,de as Go,df as gr,g as Rl,Q as tr,a_ as zl,aV as Vl,aW as Bl,dg as El,c7 as Nl,dh as Gl,$ as He,di as Ho,bL as Hl,P as Wl,dj as Zl,D as pi,dk as Fl,dl as $l,bF as fi,dm as Wo,dn as Yl,dp as Ul,c0 as Xl,dq as Kl,dr as ql,ds as di,dt as jl}from"./Axis-D3q4j9rs.js";import{a4 as Jl,a5 as ae,a6 as gi,a7 as Ql,a8 as le,a9 as tu,l as eu,r as ru,h as er,e as nu,f as iu,m as Pn,aa as Jr,ab as au,ac as ou,a2 as su,a3 as lu,$ as uu,a0 as wr,ad as cu,a1 as yi,ae as hu,Z as vu,af as Kt,ag as pu,ah as fu,K as Zo,ai as du,aj as gu,ak as yu,al as Fo,G as ct,S as mu,L as xu,i as kn,R as $o,am as mi,O as Su,an as _u,ao as bu,ap as wu,aq as Cu}from"./customGraphicKeyframeAnimation-C08fYDZH.js";import{v as $f,P as Yf,n as Uf}from"./customGraphicKeyframeAnimation-C08fYDZH.js";var Yo="single",Tu="singleAxis",Qr="singleAxis",We=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getCoordSysModel=function(){return this},e.type=Qr,e.layoutMode="box",e.defaultOption={left:"5%",top:"5%",right:"5%",bottom:"5%",type:"value",position:"bottom",orient:"horizontal",axisLine:{show:!0,lineStyle:{width:1,type:"solid"}},tooltip:{show:!0},axisTick:{show:!0,length:6,lineStyle:{width:1}},axisLabel:{show:!0,interval:"auto"},splitLine:{show:!0,lineStyle:{type:"dashed",opacity:.2}},jitter:0,jitterOverlap:!0,jitterMargin:2},e})(tt);hr(We,fo.prototype);var Ht=ht(),xi=W,Cr=O,On=(function(){function n(){this._dragging=!1,this.animationThreshold=15}return n.prototype.render=function(e,t,r,i){var a=t.get("value"),o=t.get("status");if(this._axisModel=e,this._axisPointerModel=t,this._api=r,!(!i&&this._lastValue===a&&this._lastStatus===o)){this._lastValue=a,this._lastStatus=o;var s=this._group,l=this._handle;if(!o||o==="hide"){s&&s.hide(),l&&l.hide();return}s&&s.show(),l&&l.show();var u={};this.makeElOption(u,a,e,t,r);var c=u.graphicKey;c!==this._lastGraphicKey&&this.clear(r),this._lastGraphicKey=c;var h=this._moveAnimation=this.determineAnimation(e,t);if(!s)s=this._group=new ot,this.createPointerEl(s,u,e,t),this.createLabelEl(s,u,e,t),r.getZr().add(s);else{var v=G(Si,t,h);this.updatePointerEl(s,u,v),this.updateLabelEl(s,u,v,t)}bi(s,t,!0),this._renderHandle(a)}},n.prototype.remove=function(e){this.clear(e)},n.prototype.dispose=function(e){this.clear(e)},n.prototype.determineAnimation=function(e,t){var r=t.get("animation"),i=e.axis,a=i.type==="category",o=t.get("snap");if(!o&&!a)return!1;if(r==="auto"||r==null){var s=this.animationThreshold;if(a&&Sn(i).w>s)return!0;if(o){var l=Jl(e).seriesDataCount,u=i.getExtent();return Math.abs(u[0]-u[1])/l>s}return!1}return r===!0},n.prototype.makeElOption=function(e,t,r,i,a){},n.prototype.createPointerEl=function(e,t,r,i){var a=t.pointer;if(a){var o=Ht(e).pointerEl=new _n[a.type](xi(t.pointer));e.add(o)}},n.prototype.createLabelEl=function(e,t,r,i){if(t.label){var a=Ht(e).labelEl=new $(xi(t.label));e.add(a),_i(a,i)}},n.prototype.updatePointerEl=function(e,t,r){var i=Ht(e).pointerEl;i&&t.pointer&&(i.setStyle(t.pointer.style),r(i,{shape:t.pointer.shape}))},n.prototype.updateLabelEl=function(e,t,r,i){var a=Ht(e).labelEl;a&&(a.setStyle(t.label.style),r(a,{x:t.label.x,y:t.label.y}),_i(a,i))},n.prototype._renderHandle=function(e){if(!(this._dragging||!this.updateHandleTransform)){var t=this._axisPointerModel,r=this._api.getZr(),i=this._handle,a=t.getModel("handle"),o=t.get("status");if(!a.get("show")||!o||o==="hide"){i&&r.remove(i),this._handle=null;return}var s;this._handle||(s=!0,i=this._handle=pr(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){ne(u.event)},onmousedown:Cr(this._onHandleDragMove,this,0,0),drift:Cr(this._onHandleDragMove,this),ondragend:Cr(this._onHandleDragEnd,this)}),r.add(i)),bi(i,t,!1),i.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=a.get("size");R(l)||(l=[l,l]),i.scaleX=l[0]/2,i.scaleY=l[1]/2,be(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,s)}},n.prototype._moveHandleToValue=function(e,t){Si(this._axisPointerModel,!t&&this._moveAnimation,this._handle,Tr(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},n.prototype._onHandleDragMove=function(e,t){var r=this._handle;if(r){this._dragging=!0;var i=this.updateHandleTransform(Tr(r),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=i,r.stopAnimation(),r.attr(Tr(i)),Ht(r).lastProp=null,this._doDispatchAxisPointer()}},n.prototype._doDispatchAxisPointer=function(){var e=this._handle;if(e){var t=this._payloadInfo,r=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:r.axis.dim,axisIndex:r.componentIndex}]})}},n.prototype._onHandleDragEnd=function(){this._dragging=!1;var e=this._handle;if(e){var t=this._axisPointerModel.get("value");this._moveHandleToValue(t),this._api.dispatchAction({type:"hideTip"})}},n.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),r=this._group,i=this._handle;t&&r&&(this._lastGraphicKey=null,r&&t.remove(r),i&&t.remove(i),this._group=null,this._handle=null,this._payloadInfo=null),Xe(this,"_doDispatchAxisPointer")},n.prototype.doClear=function(){},n.prototype.buildLabel=function(e,t,r){return r=r||0,{x:e[r],y:e[1-r],width:t[r],height:t[1-r]}},n})();function Si(n,e,t,r){Uo(Ht(t).lastProp,r)||(Ht(t).lastProp=r,e?fr(t,r,n):(t.stopAnimation(),t.attr(r)))}function Uo(n,e){if(vt(n)&&vt(e)){var t=!0;return C(e,function(r,i){t=t&&Uo(n[i],r)}),!!t}else return n===e}function _i(n,e){n[e.get(["label","show"])?"show":"hide"]()}function Tr(n){return{x:n.x||0,y:n.y||0,rotation:n.rotation||0}}function bi(n,e,t){var r=e.get("z"),i=e.get("zlevel");n&&n.traverse(function(a){a.type!=="group"&&(r!=null&&(a.z=r),i!=null&&(a.zlevel=i),a.silent=t)})}function Rn(n){var e=n.get("type"),t=n.getModel(e+"Style"),r;return e==="line"?(r=t.getLineStyle(),r.fill=null):e==="shadow"&&(r=t.getAreaStyle(),r.stroke=null),r}function Xo(n,e,t,r,i){var a=t.get("value"),o=Ko(a,e.axis,e.ecModel,t.get("seriesDataIndices"),{precision:t.get(["label","precision"]),formatter:t.get(["label","formatter"])}),s=t.getModel("label"),l=dr(s.get("padding")||0),u=s.getFont(),c=mn(o,u),h=i.position,v=c.width+l[1]+l[3],p=c.height+l[0]+l[2],f=i.align;f==="right"&&(h[0]-=v),f==="center"&&(h[0]-=v/2);var d=i.verticalAlign;d==="bottom"&&(h[1]-=p),d==="middle"&&(h[1]-=p/2),Au(h,v,p,r);var g=s.get("backgroundColor");(!g||g==="auto")&&(g=e.get(["axisLine","lineStyle","color"])),n.label={x:h[0],y:h[1],style:it(s,{text:o,font:u,fill:s.getTextColor(),padding:l,backgroundColor:g}),z2:10}}function Au(n,e,t,r){var i=r.getWidth(),a=r.getHeight();n[0]=Math.min(n[0]+e,i)-e,n[1]=Math.min(n[1]+t,a)-t,n[0]=Math.max(n[0],0),n[1]=Math.max(n[1],0)}function Ko(n,e,t,r,i){n=e.scale.parse(n);var a=e.scale.getLabel({value:n},{precision:i.precision}),o=i.formatter;if(o){var s={value:go(e,{value:n}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};C(r,function(l){var u=t.getSeriesByIndex(l.seriesIndex),c=l.dataIndexInside,h=u&&u.getDataParams(c);h&&s.seriesData.push(h)}),E(o)?a=o.replace("{value}",a):F(o)&&(a=o(s))}return a}function zn(n,e,t){var r=xn();return yn(r,r,t.rotation),Ye(r,r,t.position),Vt([n.dataToCoord(e),(t.labelOffset||0)+(t.labelDirection||1)*(t.labelMargin||0)],r)}function qo(n,e,t,r,i,a){var o=ae.innerTextLayout(t.rotation,0,t.labelDirection);t.labelMargin=i.get(["label","margin"]),Xo(e,r,i,a,{position:zn(r.axis,n,t),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function Vn(n,e,t){return t=t||0,{x1:n[t],y1:n[1-t],x2:e[t],y2:e[1-t]}}function jo(n,e,t){return t=t||0,{x:n[t],y:n[1-t],width:e[t],height:e[1-t]}}function wi(n,e,t,r,i,a){return{cx:n,cy:e,r0:t,r,startAngle:i,endAngle:a,clockwise:!0}}function Bn(n,e,t){return Sn(n,{fromStat:{sers:B(e,function(r){return t.getSeriesByIndex(r.seriesIndex)})},min:1}).w}function En(n,e,t){return[lt(ut(e[0],e[1]),n-t/2),ut(n+t/2,lt(e[0],e[1]))]}var Mu=(function(n){I(e,n);function e(){return n!==null&&n.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,r,i,a,o){var s=i.axis,l=s.grid,u=a.get("type"),c=s.getGlobalExtent(),h=Ci(l,s).getOtherAxis(s).getGlobalExtent(),v=s.toGlobalCoord(s.dataToCoord(r,!0));if(u&&u!=="none"){var p=Rn(a),f=Iu[u](s,v,c,h,a.get("seriesDataIndices"),a.ecModel);f.style=p,t.graphicKey=f.type,t.pointer=f}var d=gi(l.getRect(),i);qo(r,t,d,i,a,o)},e.prototype.getHandleTransform=function(t,r,i){var a=gi(r.axis.grid.getRect(),r,{labelInside:!1});a.labelMargin=i.get(["handle","margin"]);var o=zn(r.axis,t,a);return{x:o[0],y:o[1],rotation:a.rotation+(a.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,r,i,a){var o=i.axis,s=o.grid,l=o.getGlobalExtent(!0),u=Ci(s,o).getOtherAxis(o).getGlobalExtent(),c=o.dim==="x"?0:1,h=[t.x,t.y];h[c]+=r[c],h[c]=ut(l[1],h[c]),h[c]=lt(l[0],h[c]);var v=(u[1]+u[0])/2,p=[v,v];p[c]=h[c];var f=[{verticalAlign:"middle"},{align:"center"}];return{x:h[0],y:h[1],rotation:t.rotation,cursorPoint:p,tooltipOption:f[c]}},e})(On);function Ci(n,e){var t={};return t[e.dim+"AxisIndex"]=e.index,n.getCartesian(t)}var Iu={line:function(n,e,t,r){var i=Vn([e,r[0]],[e,r[1]],Ti(n));return{type:"Line",subPixelOptimize:!0,shape:i}},shadow:function(n,e,t,r,i,a){var o=Bn(n,i,a),s=r[1]-r[0],l=En(e,t,o),u=l[0],c=l[1];return{type:"Rect",shape:jo([u,r[0]],[c-u,s],Ti(n))}}};function Ti(n){return n.dim==="x"?0:1}var Du=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.type="axisPointer",e.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:A.color.border,width:1,type:"dashed"},shadowStyle:{color:A.color.shadowTint},label:{show:!0,formatter:null,precision:"auto",margin:3,color:A.color.neutral00,padding:[5,7,5,7],backgroundColor:A.color.accent60,borderColor:null,borderWidth:0,borderRadius:3},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:A.color.accent40,throttle:40}},e})(tt),It=ht(),Lu=C;function Jo(n,e,t){if(!st.node){var r=e.getZr();It(r).records||(It(r).records={}),Pu(r,e);var i=It(r).records[n]||(It(r).records[n]={});i.handler=t}}function Pu(n,e){if(It(n).initialized)return;It(n).initialized=!0,t("click",G(Ar,"click")),t("mousemove",G(Ar,"mousemove")),t("mousewheel",G(Ar,"mousewheel")),t("globalout",Ou);function t(r,i){n.on(r,function(a){var o=Ru(e);Lu(It(n).records,function(s){s&&i(s,a,o.dispatchAction)}),ku(o.pendings,e)})}}function ku(n,e){var t=n.showTip.length,r=n.hideTip.length,i;t?i=n.showTip[t-1]:r&&(i=n.hideTip[r-1]),i&&(i.dispatchAction=null,e.dispatchAction(i))}function Ou(n,e,t){n.handler("leave",null,t)}function Ar(n,e,t,r){e.handler(n,t,r)}function Ru(n){var e={showTip:[],hideTip:[]},t=function(r){var i=e[r.type];i?i.push(r):(r.dispatchAction=t,n.dispatchAction(r))};return{dispatchAction:t,pendings:e}}function tn(n,e){if(!st.node){var t=e.getZr(),r=(It(t).records||{})[n];r&&(It(t).records[n]=null)}}var zu=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,i){var a=r.getComponent("tooltip"),o=t.get("triggerOn")||a&&a.get("triggerOn")||"mousemove|click|mousewheel";Jo("axisPointer",i,function(s,l,u){o!=="none"&&(s==="leave"||o.indexOf(s)>=0)&&u({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},e.prototype.remove=function(t,r){tn("axisPointer",r)},e.prototype.dispose=function(t,r){tn("axisPointer",r)},e.type="axisPointer",e})(at);function Qo(n,e){var t=[],r=n.seriesIndex,i;if(r==null||!(i=e.getSeriesByIndex(r)))return{point:[]};var a=i.getData(),o=Ks(a,n);if(o==null||o<0||R(o))return{point:[]};var s=a.getItemGraphicEl(o),l=i.coordinateSystem;if(i.getTooltipPosition)t=i.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)if(n.isStacked){var u=l.getBaseAxis(),c=l.getOtherAxis(u),h=c.dim,v=u.dim,p=h==="x"||h==="radius"?1:0,f=a.mapDimension(v),d=[];d[p]=a.get(f,o),d[1-p]=a.get(a.getCalculationInfo("stackResultDimension"),o),t=l.dataToPoint(d)||[]}else t=l.dataToPoint(a.getValues(B(l.dimensions,function(y){return a.mapDimension(y)}),o))||[];else if(s){var g=s.getBoundingRect().clone();g.applyTransform(s.transform),t=[g.x+g.width/2,g.y+g.height/2]}return{point:t,el:s}}var Ai=ht();function Vu(n,e,t){var r=n.currTrigger,i=[n.x,n.y],a=n,o=n.dispatchAction||O(t.dispatchAction,t),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){Ze(i)&&(i=Qo({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},e).point);var l=Ze(i),u=a.axesInfo,c=s.axesInfo,h=r==="leave"||Ze(i),v={},p={},f={list:[],map:{}},d={showPointer:G(Eu,p),showTooltip:G(Nu,f)};C(s.coordSysMap,function(y,m){var x=l||y.containPoint(i);C(s.coordSysAxesInfo[m],function(S,_){var b=S.axis,w=Zu(u,S);if(!h&&x&&(!u||w)){var M=w&&w.value;M==null&&!l&&(M=b.pointToData(i)),M!=null&&Mi(S,M,d,!1,v)}})});var g={};return C(c,function(y,m){var x=y.linkGroup;x&&!p[m]&&C(x.axesInfo,function(S,_){var b=p[_];if(S!==y&&b){var w=b.value;x.mapper&&(w=y.axis.scale.parse(x.mapper(w,Ii(S),Ii(y)))),g[y.key]=w}})}),C(g,function(y,m){Mi(c[m],y,d,!0,v)}),Gu(p,c,v),Hu(f,i,n,o),Wu(c,o,t),v}}function Mi(n,e,t,r,i){var a=n.axis;if(!(a.scale.isBlank()||!a.containData(e))){if(!n.involveSeries){t.showPointer(n,e);return}var o=Bu(e,n),s=o.payloadBatch,l=o.snapToValue;s[0]&&i.seriesIndex==null&&Z(i,s[0]),!r&&n.snap&&a.containData(l)&&l!=null&&(e=l),t.showPointer(n,e,s),t.showTooltip(n,o,l)}}function Bu(n,e){var t=e.axis,r=t.dim,i=n,a=[],o=Number.MAX_VALUE,s=-1;return C(e.seriesModels,function(l,u){var c=l.getData().mapDimensionsAll(r),h,v;if(l.getAxisTooltipData){var p=l.getAxisTooltipData(c,n,t);v=p.dataIndices,h=p.nestestValue}else{if(v=l.indicesOfNearest(r,c[0],n,t.type==="category"?.5:null),!v.length)return;h=l.getData().get(c[0],v[0])}if(qs(h)){var f=n-h,d=Math.abs(f);d<=o&&((d=0&&s<0)&&(o=d,s=f,i=h,a.length=0),C(v,function(g){a.push({seriesIndex:l.seriesIndex,dataIndexInside:g,dataIndex:l.getData().getRawIndex(g)})}))}}),{payloadBatch:a,snapToValue:i}}function Eu(n,e,t,r){n[e.key]={value:t,payloadBatch:r}}function Nu(n,e,t,r){var i=t.payloadBatch,a=e.axis,o=a.model,s=e.axisPointerModel;if(!(!e.triggerTooltip||!i.length)){var l=e.coordSys.model,u=Ql(l),c=n.map[u];c||(c=n.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},n.list.push(c)),c.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:r,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:i.slice()})}}function Gu(n,e,t){var r=t.axesInfo=[];C(e,function(i,a){var o=i.axisPointerModel.option,s=n[a];s?(!i.useHandle&&(o.status="show"),o.value=s.value,o.seriesDataIndices=(s.payloadBatch||[]).slice()):!i.useHandle&&(o.status="hide"),o.status==="show"&&r.push({axisDim:i.axis.dim,axisIndex:i.axis.model.componentIndex,value:o.value})})}function Hu(n,e,t,r){if(Ze(e)||!n.list.length){r({type:"hideTip"});return}var i=((n.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};r({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:t.tooltipOption,position:t.position,dataIndexInside:i.dataIndexInside,dataIndex:i.dataIndex,seriesIndex:i.seriesIndex,dataByCoordSys:n.list})}function Wu(n,e,t){var r=t.getZr(),i="axisPointerLastHighlights",a=Ai(r)[i]||{},o=Ai(r)[i]={};C(n,function(c,h){var v=c.axisPointerModel.option;v.status==="show"&&c.triggerEmphasis&&C(v.seriesDataIndices,function(p){o[p.seriesIndex+"|"+p.dataIndex]=p})});var s=[],l=[];function u(c){return{seriesIndex:c.seriesIndex,dataIndex:c.dataIndex}}C(a,function(c,h){!o[h]&&l.push(u(c))}),C(o,function(c,h){!a[h]&&s.push(u(c))}),l.length&&t.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&t.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function Zu(n,e){for(var t=0;t<(n||[]).length;t++){var r=n[t];if(e.axis.dim===r.axisDim&&e.axis.model.componentIndex===r.axisIndex)return r}}function Ii(n){var e=n.axis.model,t={},r=t.axisDim=n.axis.dim;return t.axisIndex=t[r+"AxisIndex"]=e.componentIndex,t.axisName=t[r+"AxisName"]=e.name,t.axisId=t[r+"AxisId"]=e.id,t}function Ze(n){return!n||n[0]==null||isNaN(n[0])||n[1]==null||isNaN(n[1])}function yr(n){le.registerAxisPointerClass("CartesianAxisPointer",Mu),n.registerComponentModel(Du),n.registerComponentView(zu),n.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var t=e.axisPointer.link;t&&!R(t)&&(e.axisPointer.link=[t])}}),n.registerProcessor(n.PRIORITY.PROCESSOR.STATISTIC,{overallReset:function(e,t){e.getComponent("axisPointer").coordSysAxesInfo=tu(e,t)}}),n.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},Vu)}function bf(n){ft(eu),ft(yr)}var Fu=(function(n){I(e,n);function e(){return n!==null&&n.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,r,i,a,o){var s=i.axis;s.dim==="angle"&&(this.animationThreshold=Math.PI/18);var l=s.polar,u=s.getExtent(),c=l.getOtherAxis(s).getExtent(),h=s.dataToCoord(r),v=a.get("type");if(v&&v!=="none"){var p=Rn(a),f=Yu[v](s,l,h,u,c,a.get("seriesDataIndices"),a.ecModel);f.style=p,t.graphicKey=f.type,t.pointer=f}var d=a.get(["label","margin"]),g=$u(r,i,a,l,d);Xo(t,i,a,o,g)},e})(On);function $u(n,e,t,r,i){var a=e.axis,o=a.dataToCoord(n),s=r.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l=r.getRadiusAxis().getExtent(),u,c,h;if(a.dim==="radius"){var v=xn();yn(v,v,s),Ye(v,v,[r.cx,r.cy]),u=Vt([o,-i],v);var p=e.getModel("axisLabel").get("rotate")||0,f=ae.innerTextLayout(s,p*Math.PI/180,-1);c=f.textAlign,h=f.textVerticalAlign}else{var d=l[1];u=r.coordToPoint([d+i,o]);var g=r.cx,y=r.cy;c=Math.abs(u[0]-g)/d<.3?"center":u[0]>g?"left":"right",h=Math.abs(u[1]-y)/d<.3?"middle":u[1]>y?"top":"bottom"}return{position:u,align:c,verticalAlign:h}}var Yu={line:function(n,e,t,r,i){return n.dim==="angle"?{type:"Line",shape:Vn(e.coordToPoint([i[0],t]),e.coordToPoint([i[1],t]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:t}}},shadow:function(n,e,t,r,i,a,o){var s=Math.PI/180,l=Bn(n,a,o),u;if(n.dim==="angle")u=wi(e.cx,e.cy,i[0],i[1],(-t-l/2)*s,(-t+l/2)*s);else{var c=En(t,r,l),h=c[0],v=c[1];u=wi(e.cx,e.cy,h,v,0,Math.PI*2)}return{type:"Sector",shape:u}}},wt="polar",Di=wt,Uu=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.findAxisModel=function(t){var r,i=this.ecModel;return i.eachComponent(t,function(a){a.getCoordSysModel()===this&&(r=a)},this),r},e.type=wt,e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e})(tt),Nn=(function(n){I(e,n);function e(){return n!==null&&n.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",Ut).models[0]},e.type="polarAxis",e})(tt);hr(Nn,fo);var Xu=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.type="angleAxis",e})(Nn),Ku=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.type="radiusAxis",e})(Nn),Gn=(function(n){I(e,n);function e(t,r){return n.call(this,"radius",t,r)||this}return e.prototype.pointToData=function(t,r){return this.polar.pointToData(t,r)[this.dim==="radius"?0:1]},e})(Nt);Gn.prototype.dataToRadius=Nt.prototype.dataToCoord;Gn.prototype.radiusToData=Nt.prototype.coordToData;var qu=ht(),Hn=(function(n){I(e,n);function e(t,r){return n.call(this,"angle",t,r||[0,360])||this}return e.prototype.pointToData=function(t,r){return this.polar.pointToData(t,r)[this.dim==="radius"?0:1]},e.prototype.calculateCategoryInterval=function(){var t=this,r=t.getLabelModel(),i=t.scale,a=i.getExtent(),o=i.count();if(a[1]-a[0]<1)return 0;var s=a[0],l=t.dataToCoord(s+1)-t.dataToCoord(s),u=Math.abs(l),c=mn(s==null?"":s+"",r.getFont(),"center","top"),h=Math.max(c.height,7),v=h/u;isNaN(v)&&(v=1/0);var p=Math.max(0,Math.floor(v)),f=qu(t.model),d=f.lastAutoInterval,g=f.lastTickCount;return d!=null&&g!=null&&Math.abs(d-p)<=1&&Math.abs(g-o)<=1&&d>p?p=d:(f.lastTickCount=o,f.lastAutoInterval=p),p},e})(Nt);Hn.prototype.dataToAngle=Nt.prototype.dataToCoord;Hn.prototype.angleToData=Nt.prototype.coordToData;var ts=["radius","angle"],ju=(function(){function n(e){this.dimensions=ts,this.type=wt,this.cx=0,this.cy=0,this._radiusAxis=new Gn,this._angleAxis=new Hn,this.axisPointerEnabled=!0,this.name=e||"",this._radiusAxis.polar=this._angleAxis.polar=this}return n.prototype.containPoint=function(e){var t=this.pointToCoord(e);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},n.prototype.containData=function(e){return this._radiusAxis.containData(e[0])&&this._angleAxis.containData(e[1])},n.prototype.getAxis=function(e){var t="_"+e+"Axis";return this[t]},n.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},n.prototype.getAxesByScale=function(e){var t=[],r=this._angleAxis,i=this._radiusAxis;return r.scale.type===e&&t.push(r),i.scale.type===e&&t.push(i),t},n.prototype.getAngleAxis=function(){return this._angleAxis},n.prototype.getRadiusAxis=function(){return this._radiusAxis},n.prototype.getOtherAxis=function(e){var t=this._angleAxis;return e===t?this._radiusAxis:t},n.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},n.prototype.getTooltipAxes=function(e){var t=e!=null&&e!=="auto"?this.getAxis(e):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},n.prototype.dataToPoint=function(e,t,r){return this.coordToPoint([this._radiusAxis.dataToRadius(e[0],t),this._angleAxis.dataToAngle(e[1],t)],r)},n.prototype.pointToData=function(e,t,r){r=r||[];var i=this.pointToCoord(e);return r[0]=this._radiusAxis.radiusToData(i[0],t),r[1]=this._angleAxis.angleToData(i[1],t),r},n.prototype.pointToCoord=function(e){var t=e[0]-this.cx,r=e[1]-this.cy,i=this.getAngleAxis(),a=i.getExtent(),o=Math.min(a[0],a[1]),s=Math.max(a[0],a[1]);i.inverse?o=s-360:s=o+360;var l=Math.sqrt(t*t+r*r);t/=l,r/=l;for(var u=Math.atan2(-r,t)/Math.PI*180,c=us;)u+=c*360;return[l,u]},n.prototype.coordToPoint=function(e,t){t=t||[];var r=e[0],i=e[1]/180*Math.PI;return t[0]=Math.cos(i)*r+this.cx,t[1]=-Math.sin(i)*r+this.cy,t},n.prototype.getArea=function(){var e=this.getAngleAxis(),t=this.getRadiusAxis(),r=t.getExtent().slice();r[0]>r[1]&&r.reverse();var i=e.getExtent(),a=Math.PI/180,o=1e-4;return{cx:this.cx,cy:this.cy,r0:r[0],r:r[1],startAngle:-i[0]*a,endAngle:-i[1]*a,clockwise:e.inverse,contain:function(s,l){var u=s-this.cx,c=l-this.cy,h=u*u+c*c,v=this.r,p=this.r0;return v!==p&&h-o<=v*v&&h+o>=p*p},x:this.cx-r[1],y:this.cy-r[1],width:r[1]*2,height:r[1]*2}},n.prototype.convertToPixel=function(e,t,r){var i=Li(t);return i===this?this.dataToPoint(r):null},n.prototype.convertFromPixel=function(e,t,r){var i=Li(t);return i===this?this.pointToData(r):null},n})();function Li(n){var e=n.seriesModel,t=n.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function Ju(n,e,t){var r=e.get("center"),i=Pt(e,t).refContainer;n.cx=X(r[0],i.width)+i.x,n.cy=X(r[1],i.height)+i.y;var a=n.getRadiusAxis(),o=Math.min(i.width,i.height)/2,s=e.get("radius");s==null?s=[0,"100%"]:R(s)||(s=[0,s]);var l=[X(s[0],o),X(s[1],o)];a.inverse?a.setExtent(l[1],l[0]):a.setExtent(l[0],l[1])}function Qu(n,e){var t=this,r=t.getAngleAxis(),i=t.getRadiusAxis();if(Ke(r,qr),Ke(i,qr),Kr(r),Kr(i),r.type==="category"&&!r.onBand){var a=r.getExtent(),o=360/r.scale.count();r.inverse?a[1]+=o:a[1]-=o,r.setExtent(a[0],a[1])}}function tc(n){return n.mainType==="angleAxis"}function Pi(n,e){var t;if(n.type=yo(e),n.scale=bn(e,n.type),n.onBand=mo(n.scale,e),n.inverse=e.get("inverse"),tc(e)){n.inverse=n.inverse!==e.get("clockwise");var r=e.get("startAngle"),i=(t=e.get("endAngle"))!==null&&t!==void 0?t:r+(n.inverse?-360:360);n.setExtent(r,i)}e.axis=n,n.model=e}var ec={dimensions:ts,create:function(n,e){var t=[];return n.eachComponent(Di,function(r,i){var a=new ju(i+"");a.update=Qu;var o=a.getRadiusAxis(),s=a.getAngleAxis(),l=r.findAxisModel("radiusAxis"),u=r.findAxisModel("angleAxis");Pi(o,l),Pi(s,u),Ju(a,r,e),t.push(a),r.coordinateSystem=a,a.model=r}),n.eachSeries(function(r){if(r.get("coordinateSystem")===wt){var i=r.getReferringComponents(Di,Ut).models[0],a=r.coordinateSystem=i.coordinateSystem;a&&(Xr(a.getRadiusAxis(),r,wt),Xr(a.getAngleAxis(),r,wt))}}),t}},rc=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function Te(n,e,t){e[1]>e[0]&&(e=e.slice().reverse());var r=n.coordToPoint([e[0],t]),i=n.coordToPoint([e[1],t]);return{x1:r[0],y1:r[1],x2:i[0],y2:i[1]}}function Ae(n){var e=n.getRadiusAxis();return e.inverse?0:1}function ki(n){var e=n[0],t=n[n.length-1];e&&t&&Math.abs(Math.abs(e.coord-t.coord)-360)<1e-4&&n.pop()}var nc=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,r){if(this.group.removeAll(),!!t.get("show")){var i=t.axis,a=i.polar,o=a.getRadiusAxis().getExtent(),s=i.getTicksCoords({breakTicks:"none"}),l=i.getMinorTicksCoords(),u=[];C(i.getViewLabels(),function(c){if(!c.tick.offInterval){c=W(c);var h=i.scale;c.coord=i.dataToCoord(js(h,c.tick)),u.push(c)}}),ki(u),ki(s),C(rc,function(c){t.get([c,"show"])&&(!i.scale.isBlank()||c==="axisLine")&&ic[c](this.group,t,a,s,l,o,u)},this)}},e.type="angleAxis",e})(le),ic={axisLine:function(n,e,t,r,i,a){var o=e.getModel(["axisLine","lineStyle"]),s=t.getAngleAxis(),l=Math.PI/180,u=s.getExtent(),c=Ae(t),h=c?0:1,v,p=Math.abs(u[1]-u[0])===360?"Circle":"Arc";a[h]===0?v=new _n[p]({shape:{cx:t.cx,cy:t.cy,r:a[c],startAngle:-u[0]*l,endAngle:-u[1]*l,clockwise:s.inverse},style:o.getLineStyle(),z2:1,silent:!0}):v=new Js({shape:{cx:t.cx,cy:t.cy,r:a[c],r0:a[h]},style:o.getLineStyle(),z2:1,silent:!0}),v.style.fill=null,n.add(v)},axisTick:function(n,e,t,r,i,a){var o=e.getModel("axisTick"),s=(o.get("inside")?-1:1)*o.get("length"),l=a[Ae(t)],u=B(r,function(c){return new Rt({shape:Te(t,[l,l+s],c.coord)})});n.add(At(u,{style:j(o.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(n,e,t,r,i,a){if(i.length){for(var o=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(o.get("inside")?-1:1)*s.get("length"),u=a[Ae(t)],c=[],h=0;hy?"left":"right",S=Math.abs(g[1]-m)/d<.3?"middle":g[1]>m?"top":"bottom";if(s&&s[f]){var _=s[f];vt(_)&&_.textStyle&&(p=new rt(_.textStyle,l,l.ecModel))}var b=new $({silent:ae.isLabelSilent(e),style:it(p,{x:g[0],y:g[1],fill:p.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:h.formattedLabel,align:x,verticalAlign:S})});if(n.add(b),we({el:b,componentModel:e,itemName:h.formattedLabel,formatterParamsExtra:{isTruncated:function(){return b.isTruncated},value:h.rawLabel,tickIndex:v}}),c){var w=ae.makeAxisEventDataBase(e);w.targetType="axisLabel",w.value=h.rawLabel,Y(b).eventData=w}},this)},splitLine:function(n,e,t,r,i,a){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],h=0;h=0?"p":"n",T=x;y&&(r[a][w]||(r[a][w]={p:x,n:x}),T=r[a][w][M]);var L=void 0,D=void 0,V=void 0,P=void 0;if(c.dim==="radius"){var z=c.dataToCoord(b)-x,N=n.dataToCoord(w);jr(z)=P})}}function pc(n,e){var t=Pn(e,wt),r=Sn(n,{fromStat:{key:t},min:1}).w,i=r,a=0,o="20%",s="30%",l={};bo(n,t,function(g){var y=es(g);l[y]||a++,l[y]=l[y]||{width:0,maxWidth:0};var m=X(g.get("barWidth"),r),x=X(g.get("barMaxWidth"),r),S=g.get("barGap"),_=g.get("barCategoryGap");m&&!l[y].width&&(m=ut(i,m),l[y].width=m,i-=m),x&&(l[y].maxWidth=x),S!=null&&(s=S),_!=null&&(o=_)});var u={},c=X(o,r),h=X(s,1),v=(i-c)/(a+(a-1)*h);v=lt(v,0),C(l,function(g,y){var m=g.maxWidth;m&&m=t.y&&e[1]<=t.y+t.height:r.contain(r.toLocalCoord(e[1]))&&e[0]>=t.y&&e[0]<=t.y+t.height},n.prototype.pointToData=function(e,t,r){r=r||[];var i=this.getAxis();return r[0]=i.coordToData(i.toLocalCoord(e[i.orient==="horizontal"?0:1])),r},n.prototype.dataToPoint=function(e,t,r){var i=this.getAxis(),a=this.getRect();r=r||[];var o=i.orient==="horizontal"?0:1;return e instanceof Array&&(e=e[0]),r[o]=i.toGlobalCoord(i.dataToCoord(+e)),r[1-o]=o===0?a.y+a.height/2:a.x+a.width/2,r},n.prototype.convertToPixel=function(e,t,r){var i=Oi(t);return i===this?this.dataToPoint(r):null},n.prototype.convertFromPixel=function(e,t,r){var i=Oi(t);return i===this?this.pointToData(r):null},n})();function Oi(n){var e=n.seriesModel,t=n.singleAxisModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}function wc(n,e){var t=[];return n.eachComponent(Qr,function(r,i){var a=new bc(r,n,e);a.name="single_"+i,a.resize(r,e),r.coordinateSystem=a,t.push(a)}),n.eachSeries(function(r){if(r.get("coordinateSystem")===Tu){var i=r.getReferringComponents(Qr,Ut).models[0],a=r.coordinateSystem=i&&i.coordinateSystem;a&&Xr(a.getAxis(),r,Yo)}}),t}var Cc={create:wc,dimensions:rs},Ri=["x","y"],Tc=["width","height"],Ac=(function(n){I(e,n);function e(){return n!==null&&n.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,r,i,a,o){var s=i.axis,l=s.coordinateSystem,u=rr(s),c=Me(l,u),h=Me(l,1-u),v=l.dataToPoint(r)[0],p=a.get("type");if(p&&p!=="none"){var f=Rn(a),d=Mc[p](s,v,c,h,a.get("seriesDataIndices"),a.ecModel);d.style=f,t.graphicKey=d.type,t.pointer=d}var g=en(i);qo(r,t,g,i,a,o)},e.prototype.getHandleTransform=function(t,r,i){var a=en(r,{labelInside:!1});a.labelMargin=i.get(["handle","margin"]);var o=zn(r.axis,t,a);return{x:o[0],y:o[1],rotation:a.rotation+(a.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,r,i,a){var o=i.axis,s=o.coordinateSystem,l=rr(o),u=Me(s,l),c=[t.x,t.y];c[l]+=r[l],c[l]=Math.min(u[1],c[l]),c[l]=Math.max(u[0],c[l]);var h=Me(s,1-l),v=(h[1]+h[0])/2,p=[v,v];return p[l]=c[l],{x:c[0],y:c[1],rotation:t.rotation,cursorPoint:p,tooltipOption:{verticalAlign:"middle"}}},e})(On),Mc={line:function(n,e,t,r){var i=Vn([e,r[0]],[e,r[1]],rr(n));return{type:"Line",subPixelOptimize:!0,shape:i}},shadow:function(n,e,t,r,i,a){var o=Bn(n,i,a),s=r[1]-r[0],l=En(e,t,o),u=l[0],c=l[1];return{type:"Rect",shape:jo([u,r[0]],[c-u,s],rr(n))}}};function rr(n){return n.isHorizontal()?0:1}function Me(n,e){var t=n.getRect();return[t[Ri[e]],t[Ri[e]]+t[Tc[e]]]}var Ic=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.type="single",e})(at);function Cf(n){ft(yr),le.registerAxisPointerClass("SingleAxisPointer",Ac),n.registerComponentView(Ic),n.registerComponentView(xc),n.registerComponentModel(We),Jr(n,"single",We,We.defaultOption),n.registerCoordinateSystem("single",Cc)}var Dc=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r,i){var a=wn(t);n.prototype.init.apply(this,arguments),zi(t,a)},e.prototype.mergeOption=function(t){n.prototype.mergeOption.apply(this,arguments),zi(this.option,t)},e.prototype.getCellSize=function(){return this.option.cellSize},e.type="calendar",e.layoutMode="box",e.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:A.color.axisLine,width:1,type:"solid"}},itemStyle:{color:A.color.neutral00,borderWidth:1,borderColor:A.color.neutral10},dayLabel:{show:!0,firstDay:0,position:"start",margin:A.size.s,color:A.color.secondary},monthLabel:{show:!0,position:"start",margin:A.size.s,align:"center",formatter:null,color:A.color.secondary},yearLabel:{show:!0,position:null,margin:A.size.xl,formatter:null,color:A.color.quaternary,fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},e})(tt);function zi(n,e){var t=n.cellSize,r;R(t)?r=t:r=n.cellSize=[t,t],r.length===1&&(r[1]=r[0]);var i=B([0,1],function(a){return il(e,a)&&(r[a]="auto"),r[a]!=null&&r[a]!=="auto"});Cn(n,e,{type:"box",ignoreSize:i})}var Lc=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,i){var a=this.group;a.removeAll();var o=t.coordinateSystem,s=o.getRangeInfo(),l=o.getOrient(),u=r.getLocaleModel();this._renderDayRect(t,s,a),this._renderLines(t,s,l,a),this._renderYearText(t,s,l,a),this._renderMonthText(t,u,l,a),this._renderWeekText(t,u,s,l,a)},e.prototype._renderDayRect=function(t,r,i){for(var a=t.coordinateSystem,o=t.getModel("itemStyle").getItemStyle(),s=a.getCellWidth(),l=a.getCellHeight(),u=r.start.time;u<=r.end.time;u=a.getNextNDay(u,1).time){var c=a.dataToCalendarLayout([u],!1).tl,h=new nt({shape:{x:c[0],y:c[1],width:s,height:l},cursor:"default",style:o});i.add(h)}},e.prototype._renderLines=function(t,r,i,a){var o=this,s=t.coordinateSystem,l=t.getModel(["splitLine","lineStyle"]).getLineStyle(),u=t.get(["splitLine","show"]),c=l.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var h=r.start,v=0;h.time<=r.end.time;v++){f(h.formatedDate),v===0&&(h=s.getDateInfo(r.start.y+"-"+r.start.m));var p=h.date;p.setMonth(p.getMonth()+1),h=s.getDateInfo(p)}f(s.getNextNDay(r.end.time,1).formatedDate);function f(d){o._firstDayOfMonth.push(s.getDateInfo(d)),o._firstDayPoints.push(s.dataToCalendarLayout([d],!1).tl);var g=o._getLinePointsOfOneWeek(t,d,i);o._tlpoints.push(g[0]),o._blpoints.push(g[g.length-1]),u&&o._drawSplitline(g,l,a)}u&&this._drawSplitline(o._getEdgesPoints(o._tlpoints,c,i),l,a),u&&this._drawSplitline(o._getEdgesPoints(o._blpoints,c,i),l,a)},e.prototype._getEdgesPoints=function(t,r,i){var a=[t[0].slice(),t[t.length-1].slice()],o=i==="horizontal"?0:1;return a[0][o]=a[0][o]-r/2,a[1][o]=a[1][o]+r/2,a},e.prototype._drawSplitline=function(t,r,i){var a=new Co({z2:20,shape:{points:t},style:r});i.add(a)},e.prototype._getLinePointsOfOneWeek=function(t,r,i){for(var a=t.coordinateSystem,o=a.getDateInfo(r),s=[],l=0;l<7;l++){var u=a.getNextNDay(o.time,l),c=a.dataToCalendarLayout([u.time],!1);s[2*u.day]=c.tl,s[2*u.day+1]=c[i==="horizontal"?"bl":"tr"]}return s},e.prototype._formatterLabel=function(t,r){return E(t)&&t?To(t,r):F(t)?t(r):r.nameMap},e.prototype._yearTextPositionControl=function(t,r,i,a,o){var s=r[0],l=r[1],u=["center","bottom"];a==="bottom"?(l+=o,u=["center","top"]):a==="left"?s-=o:a==="right"?(s+=o,u=["center","top"]):l-=o;var c=0;return(a==="left"||a==="right")&&(c=Math.PI/2),{rotation:c,x:s,y:l,style:{align:u[0],verticalAlign:u[1]}}},e.prototype._renderYearText=function(t,r,i,a){var o=t.getModel("yearLabel");if(o.get("show")){var s=o.get("margin"),l=o.get("position");l||(l=i!=="horizontal"?"top":"left");var u=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],c=(u[0][0]+u[1][0])/2,h=(u[0][1]+u[1][1])/2,v=i==="horizontal"?0:1,p={top:[c,u[v][1]],bottom:[c,u[1-v][1]],left:[u[1-v][0],h],right:[u[v][0],h]},f=r.start.y;+r.end.y>+r.start.y&&(f=f+"-"+r.end.y);var d=o.get("formatter"),g={start:r.start.y,end:r.end.y,nameMap:f},y=this._formatterLabel(d,g),m=new $({z2:30,style:it(o,{text:y}),silent:o.get("silent")});m.attr(this._yearTextPositionControl(m,p[l],i,l,s)),a.add(m)}},e.prototype._monthTextPositionControl=function(t,r,i,a,o){var s="left",l="top",u=t[0],c=t[1];return i==="horizontal"?(c=c+o,r&&(s="center"),a==="start"&&(l="bottom")):(u=u+o,r&&(l="middle"),a==="start"&&(s="right")),{x:u,y:c,align:s,verticalAlign:l}},e.prototype._renderMonthText=function(t,r,i,a){var o=t.getModel("monthLabel");if(o.get("show")){var s=o.get("nameMap"),l=o.get("margin"),u=o.get("position"),c=o.get("align"),h=[this._tlpoints,this._blpoints];(!s||E(s))&&(s&&(r=ai(s)||r),s=r.get(["time","monthAbbr"])||[]);var v=u==="start"?0:1,p=i==="horizontal"?0:1;l=u==="start"?-l:l;for(var f=c==="center",d=o.get("silent"),g=0;g=a.start.time&&i.times.end.time&&t.reverse(),t},n.prototype._getRangeInfo=function(e){var t=[this.getDateInfo(e[0]),this.getDateInfo(e[1])],r;t[0].time>t[1].time&&(r=!0,t.reverse());var i=Math.floor(t[1].time/Mr)-Math.floor(t[0].time/Mr)+1,a=new Date(t[0].time),o=a.getDate(),s=t[1].date.getDate();a.setDate(o+i-1);var l=a.getDate();if(l!==s)for(var u=a.getTime()-t[1].time>0?1:-1;(l=a.getDate())!==s&&(a.getTime()-t[1].time)*u>0;)i-=u,a.setDate(l-u);var c=Math.floor((i+t[0].day+6)/7),h=r?-c+1:c-1;return r&&t.reverse(),{range:[t[0].formatedDate,t[1].formatedDate],start:t[0],end:t[1],allDay:i,weeks:c,nthWeek:h,fweek:t[0].day,lweek:t[1].day}},n.prototype._getDateByWeeksAndDay=function(e,t,r){var i=this._getRangeInfo(r);if(e>i.weeks||e===0&&ti.lweek)return null;var a=(e-1)*7-i.fweek+t,o=new Date(i.start.time);return o.setDate(+i.start.d+a),this.getDateInfo(o)},n.create=function(e,t){var r=[];return e.eachComponent("calendar",function(i){var a=new n(i,e,t);r.push(a),i.coordinateSystem=a}),e.eachComponent(function(i,a){Ao({targetModel:a,coordSysType:"calendar",coordSysProvider:Mo})}),r},n.dimensions=["time","value"],n})();function Ir(n){var e=n.calendarModel,t=n.seriesModel,r=e?e.coordinateSystem:t?t.coordinateSystem:null;return r}function Tf(n){n.registerComponentModel(Dc),n.registerComponentView(Lc),n.registerCoordinateSystem("calendar",Pc)}var Mt={level:1,leaf:2,nonLeaf:3},Dt={none:0,all:1,body:2,corner:3};function rn(n,e,t){var r=e[k[t]].getCell(n);return!r&&vr(n)&&n<0&&(r=e[k[1-t]].getUnitLayoutInfo(t,Math.round(n))),r}function ns(n){var e=n||[];return e[0]=e[0]||[],e[1]=e[1]||[],e[0][0]=e[0][1]=e[1][0]=e[1][1]=NaN,e}function is(n,e,t,r,i){Vi(n[0],e,i,t,r,0),Vi(n[1],e,i,t,r,1)}function Vi(n,e,t,r,i,a){n[0]=1/0,n[1]=-1/0;var o=r[a],s=R(o)?o:[o],l=s.length,u=!!t;if(l>=1?(Bi(n,e,s,u,i,a,0),l>1&&Bi(n,e,s,u,i,a,l-1)):n[0]=n[1]=NaN,u){var c=-i[k[1-a]].getLocatorCount(a),h=i[k[a]].getLocatorCount(a)-1;t===Dt.body?c=lt(0,c):t===Dt.corner&&(h=ut(-1,h)),h=e[0]&&n[0]<=e[1]}function Gi(n,e){n.id.set(e[0][0],e[1][0]),n.span.set(e[0][1]-n.id.x+1,e[1][1]-n.id.y+1)}function Rc(n,e){n[0][0]=e[0][0],n[0][1]=e[0][1],n[1][0]=e[1][0],n[1][1]=e[1][1]}function Hi(n,e,t,r){var i=rn(e[r][0],t,r),a=rn(e[r][1],t,r);n[k[r]]=n[mt[r]]=NaN,i&&a&&(n[k[r]]=i.xy,n[mt[r]]=a.xy+a.wh-i.xy)}function ce(n,e,t,r){return n[k[e]]=t,n[k[1-e]]=r,n}function zc(n){return n&&(n.type===Mt.leaf||n.type===Mt.nonLeaf)?n:null}function nr(){return{x:NaN,y:NaN,width:NaN,height:NaN}}var Wi=(function(){function n(e,t){this._cells=[],this._levels=[],this.dim=e,this.dimIdx=e==="x"?0:1,this._model=t,this._uniqueValueGen=Vc(e);var r=t.get("data",!0),i=t.get("length",!0);if(r!=null&&!R(r)&&(r=[]),r)this._initByDimModelData(r);else if(i!=null){r=Array(i);for(var a=0;a=1,x=t[k[r]],S=a.getLocatorCount(r)-1,_=new Bt;for(o.resetLayoutIterator(_,r);_.next();)b(_.item);for(a.resetLayoutIterator(_,r);_.next();)b(_.item);function b(w){Yt(w.wh)&&(w.wh=y),w.xy=x,w.id[k[r]]===S&&!m&&(w.wh=t[k[r]]+t[mt[r]]-w.xy),x+=w.wh}}function Ki(n,e){for(var t=e[k[n]].resetCellIterator();t.next();){var r=t.item;ir(r.rect,n,r.id,r.span,e),ir(r.rect,1-n,r.id,r.span,e),r.type===Mt.nonLeaf&&(r.xy=r.rect[k[n]],r.wh=r.rect[mt[n]])}}function qi(n,e){n.travelExistingCells(function(t){var r=t.span;if(r){var i=t.spanRect,a=t.id;ir(i,0,a,r,e),ir(i,1,a,r,e)}})}function ir(n,e,t,r,i){n[mt[e]]=0;var a=t[k[e]],o=a<0?i[k[1-e]]:i[k[e]],s=o.getUnitLayoutInfo(e,t[k[e]]);if(n[k[e]]=s.xy,n[mt[e]]=s.wh,r[k[e]]>1){var l=o.getUnitLayoutInfo(e,t[k[e]]+r[k[e]]-1);n[mt[e]]=l.xy+l.wh-s.xy}}function Kc(n,e,t){var r=ol(n,t[mt[e]]);return an(r,t[mt[e]])}function an(n,e){return Math.max(Math.min(n,U(e,1/0)),0)}function Pr(n){var e=n.matrixModel,t=n.seriesModel,r=e?e.coordinateSystem:t?t.coordinateSystem:null;return r}var et={inBody:1,inCorner:2,outside:3},_t={x:null,y:null,point:[]};function ji(n,e,t,r,i){var a=t[k[e]],o=t[k[1-e]],s=a.getUnitLayoutInfo(e,a.getLocatorCount(e)-1),l=a.getUnitLayoutInfo(e,0),u=o.getUnitLayoutInfo(e,-o.getLocatorCount(e)),c=o.shouldShow()?o.getUnitLayoutInfo(e,-1):null,h=n.point[e]=r[e];if(!l&&!c){n[k[e]]=et.outside;return}if(i===Dt.body){l?(n[k[e]]=et.inBody,h=ut(s.xy+s.wh,lt(l.xy,h)),n.point[e]=h):n[k[e]]=et.outside;return}else if(i===Dt.corner){c?(n[k[e]]=et.inCorner,h=ut(c.xy+c.wh,lt(u.xy,h)),n.point[e]=h):n[k[e]]=et.outside;return}var v=l?l.xy:c?c.xy+c.wh:NaN,p=u?u.xy:v,f=s?s.xy+s.wh:v;if(hf){if(!i){n[k[e]]=et.outside;return}h=f}n.point[e]=h,n[k[e]]=v<=h&&h<=f?et.inBody:p<=h&&h<=v?et.inCorner:et.outside}function Ji(n,e,t,r){var i=1-t;if(n[k[t]]!==et.outside)for(r[k[t]].resetCellIterator(Lr);Lr.next();){var a=Lr.item;if(ta(n.point[t],a.rect,t)&&ta(n.point[i],a.rect,i)){e[t]=a.ordinal,e[i]=a.id[k[i]];return}}}function Qi(n,e,t,r){if(n[k[t]]!==et.outside){var i=n[k[t]]===et.inCorner?r[k[1-t]]:r[k[t]];for(i.resetLayoutIterator(ke,t);ke.next();)if(qc(n.point[t],ke.item)){e[t]=ke.item.id[k[t]];return}}}function qc(n,e){return e.xy<=n&&n<=e.xy+e.wh}function ta(n,e,t){return e[k[t]]<=n&&n<=e[k[t]]+e[mt[t]]}function Af(n){n.registerComponentModel(Gc),n.registerComponentView($c),n.registerCoordinateSystem("matrix",Xc)}function jc(n,e){var t=n.existing;if(e.id=n.keyInfo.id,!e.type&&t&&(e.type=t.type),e.parentId==null){var r=e.parentOption;r?e.parentId=r.id:t&&(e.parentId=t.parentId)}e.parentOption=null}function ea(n,e){var t;return C(e,function(r){n[r]!=null&&n[r]!=="auto"&&(t=!0)}),t}function Jc(n,e,t){var r=Z({},t),i=n[e],a=t.$action||"merge";a==="merge"?i?(Q(i,r,!0),Cn(i,r,{ignoreSize:!0}),ll(t,i),Oe(t,i),Oe(t,i,"shape"),Oe(t,i,"style"),Oe(t,i,"extra"),t.clipPath=i.clipPath):n[e]=r:a==="replace"?n[e]=r:a==="remove"&&i&&(n[e]=null)}var os=["transition","enterFrom","leaveTo"],Qc=os.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function Oe(n,e,t){if(t&&(!n[t]&&e[t]&&(n[t]={}),n=n[t],e=e[t]),!(!n||!e))for(var r=t?os:Qc,i=0;i=0;c--){var h=i[c],v=ye(h.id,null),p=v!=null?o.get(v):null;if(p){var f=p.parent,y=gt(f),m=f===a?{width:s,height:l}:{width:y.width,height:y.height},x={},S=Mn(p,h,m,null,{hv:h.hv,boundingMode:h.bounding},x);if(!gt(p).isNew&&S){for(var _=h.transition,b={},w=0;w=0)?b[M]=T:p[M]=T}fr(p,b,t,0)}else p.attr(x)}}},e.prototype._clear=function(){var t=this,r=this._elMap;r.each(function(i){Fe(i,gt(i).option,r,t._lastGraphicModel)}),this._elMap=J()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e})(at);function on(n){var e=ie(ra,n)?ra[n]:cl(n),t=new e({});return gt(t).type=n,t}function na(n,e,t,r){var i=on(t);return e.add(i),r.set(n,i),gt(i).id=n,gt(i).isNew=!0,i}function Fe(n,e,t,r){var i=n&&n.parent;i&&(n.type==="group"&&n.traverse(function(a){Fe(a,e,t,r)}),vu(n,e,r),t.removeKey(gt(n).id))}function ia(n,e,t,r){n.isGroup||C([["cursor",zs.prototype.cursor],["zlevel",r||0],["z",t||0],["z2",0]],function(i){var a=i[0];ie(e,a)?n[a]=U(e[a],i[1]):n[a]==null&&(n[a]=i[1])}),C(vo(e),function(i){if(i.indexOf("on")===0){var a=e[i];n[i]=F(a)?a:null}}),ie(e,"draggable")&&(n.draggable=e.draggable),e.name!=null&&(n.name=e.name),e.id!=null&&(n.id=e.id)}function nh(n){return n=Z({},n),C(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(ul),function(e){delete n[e]}),n}function ih(n,e,t){var r=Y(n).eventData;!n.silent&&!n.ignore&&!r&&(r=Y(n).eventData={componentType:"graphic",componentIndex:e.componentIndex,name:n.name}),r&&(r.info=t.info)}function Mf(n){n.registerComponentModel(eh),n.registerComponentView(rh),n.registerPreprocessor(function(e){var t=e.graphic;R(t)?!t[0]||!t[0].elements?e.graphic=[{elements:t}]:e.graphic=[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}var aa=["x","y","radius","angle","single"],ah=ht(),oh=["cartesian2d","polar","singleAxis"];function sh(n){var e=n.get("coordinateSystem");return pt(oh,e)>=0}function zt(n){return n+"Axis"}function lh(n,e){var t=J(),r=[],i=J();n.eachComponent({mainType:"dataZoom",query:e},function(c){i.get(c.uid)||s(c)});var a;do a=!1,n.eachComponent("dataZoom",o);while(a);function o(c){!i.get(c.uid)&&l(c)&&(s(c),a=!0)}function s(c){i.set(c.uid,!0),r.push(c),u(c)}function l(c){var h=!1;return c.eachTargetAxis(function(v,p){var f=t.get(v);f&&f[p]&&(h=!0)}),h}function u(c){c.eachTargetAxis(function(h,v){(t.get(h)||t.set(h,[]))[v]=!0})}return r}function ss(n){var e=n.ecModel,t={infoList:[],infoMap:J()};return n.eachTargetAxis(function(r,i){var a=e.getComponent(zt(r),i);if(a){var o=a.getCoordSysModel();if(o){var s=o.uid,l=t.infoMap.get(s);l||(l={model:o,axisModels:[]},t.infoList.push(l),t.infoMap.set(s,l)),l.axisModels.push(a)}}}),t}function ls(n){var e=ah(hl(n));return e.axisProxyMap||(e.axisProxyMap=J())}function ar(n){if(n)return ls(n.ecModel).get(n.uid)}function uh(n,e){ls(n.ecModel).set(n.uid,e)}function us(n,e){var t=e.getAxisModel().axis.__alignTo;return t&&n.getAxisProxy(t.dim,t.model.componentIndex)?ar(t.model):null}var kr=(function(){function n(){this.indexList=[],this.indexMap=[]}return n.prototype.add=function(e){this.indexMap[e]||(this.indexList.push(e),this.indexMap[e]=!0)},n})(),xe=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t._autoThrottle=!0,t._noTarget=!0,t._rangePropMode=["percent","percent"],t}return e.prototype.init=function(t,r,i){var a=oa(t);this.settledOption=a,this.mergeDefaultAndTheme(t,i),this._doInit(a)},e.prototype.mergeOption=function(t){var r=oa(t);Q(this.option,t,!0),Q(this.settledOption,r,!0),this._doInit(r)},e.prototype._doInit=function(t){var r=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var i=this.settledOption;C([["start","startValue"],["end","endValue"]],function(a,o){this._rangePropMode[o]==="value"&&(r[a[0]]=i[a[0]]=null)},this),this._resetTarget()},e.prototype._resetTarget=function(){var t=this.get("orient",!0),r=this._targetAxisInfoMap=J(),i=this._fillSpecifiedTargetAxis(r);i?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(r,this._orient)),this._noTarget=!0,r.each(function(a){a.indexList.length&&(this._noTarget=!1)},this)},e.prototype._fillSpecifiedTargetAxis=function(t){var r=!1;return C(aa,function(i){var a=this.getReferringComponents(zt(i),vl);if(a.specified){r=!0;var o=new kr;C(a.models,function(s){o.add(s.componentIndex)}),t.set(i,o)}},this),r},e.prototype._fillAutoTargetAxisByOrient=function(t,r){var i=this.ecModel,a=!0;if(a){var o=r==="vertical"?"y":"x",s=i.findComponents({mainType:o+"Axis"});l(s,o)}if(a){var s=i.findComponents({mainType:"singleAxis",filter:function(c){return c.get("orient",!0)===r}});l(s,"single")}function l(u,c){var h=u[0];if(h){var v=new kr;if(v.add(h.componentIndex),t.set(c,v),a=!1,c==="x"||c==="y"){var p=h.getReferringComponents("grid",Ut).models[0];p&&C(u,function(f){h.componentIndex!==f.componentIndex&&p===f.getReferringComponents("grid",Ut).models[0]&&v.add(f.componentIndex)})}}}a&&C(aa,function(u){if(a){var c=i.findComponents({mainType:zt(u),filter:function(v){return v.get("type",!0)==="category"}});if(c[0]){var h=new kr;h.add(c[0].componentIndex),t.set(u,h),a=!1}}},this)},e.prototype._makeAutoOrientByTargetAxis=function(){var t;return this.eachTargetAxis(function(r){!t&&(t=r)},this),t==="y"?"vertical":"horizontal"},e.prototype._setDefaultThrottle=function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var r=this.ecModel.option;this.option.throttle=r.animation&&r.animationDurationUpdate>0?100:20}},e.prototype._updateRangeUse=function(t){var r=this._rangePropMode,i=this.get("rangeMode");C([["start","startValue"],["end","endValue"]],function(a,o){var s=t[a[0]]!=null,l=t[a[1]]!=null;s&&!l?r[o]="percent":!s&&l?r[o]="value":i?r[o]=i[o]:s&&(r[o]="percent")})},e.prototype.noTarget=function(){return this._noTarget},e.prototype.getFirstTargetAxisModel=function(){var t;return this.eachTargetAxis(function(r,i){t==null&&(t=this.ecModel.getComponent(zt(r),i))},this),t},e.prototype.eachTargetAxis=function(t,r){this._targetAxisInfoMap.each(function(i,a){C(i.indexList,function(o){t.call(r,a,o)})})},e.prototype.getAxisProxy=function(t,r){return ar(this.getAxisModel(t,r))},e.prototype.getAxisModel=function(t,r){var i=this._targetAxisInfoMap.get(t);if(i&&i.indexMap[r])return this.ecModel.getComponent(zt(t),r)},e.prototype.setRawRange=function(t){var r=this.option,i=this.settledOption;C([["start","startValue"],["end","endValue"]],function(a){(t[a[0]]!=null||t[a[1]]!=null)&&(r[a[0]]=i[a[0]]=t[a[0]],r[a[1]]=i[a[1]]=t[a[1]])},this),this._updateRangeUse(t)},e.prototype.setCalculatedRange=function(t){var r=this.option;C(["start","startValue","end","endValue"],function(i){r[i]=t[i]})},e.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getWindow().percent},e.prototype.getValueRange=function(t,r){if(t==null&&r==null){var i=this.findRepresentativeAxisProxy();if(i)return i.getWindow().value}else return this.getAxisProxy(t,r).getWindow().value},e.prototype.findRepresentativeAxisProxy=function(t){if(t)return ar(t);for(var r,i=this._targetAxisInfoMap.keys(),a=0;ao[1];if(x&&!S&&!_)return!0;x&&(g=!0),S&&(f=!0),_&&(d=!0)}return g&&f&&d})}else C(c,function(p){if(a==="empty")l.setData(u=u.map(p,function(d){return s(d)?d:NaN}));else{var f={};f[p]=o,u.selectRange(f)}});C(c,function(p){u.setApproximateExtent(o,p)})}});function s(l){return l>=o[0]&&l<=o[1]}},n.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,r=this._extent;C(["min","max"],function(i){var a=t.get(i+"Span"),o=t.get(i+"ValueSpan");o!=null&&(o=this.getAxisModel().axis.scale.parse(o)),o!=null?a=K(r[0]+o,r,[0,100],!0):a!=null&&(o=K(a,[0,100],r,!0)-r[0]),e[i+"Span"]=a,e[i+"ValueSpan"]=o},this)},n})(),ph={dirtyOnOverallProgress:!0,getTargetSeries:function(n){function e(i){n.eachComponent("dataZoom",function(a){a.eachTargetAxis(function(o,s){var l=n.getComponent(zt(o),s);i(o,s,l,a)})})}var t=[];e(function(i,a,o,s){if(!ar(o)){var l=new vh(i,a,s,n);t.push(l),uh(o,l)}});var r=J();return C(t,function(i){C(i.getTargetSeriesModels(),function(a){r.set(a.uid,a)})}),r},overallReset:function(n,e){n.eachComponent("dataZoom",function(t){var r=[];t.eachTargetAxis(function(i,a){var o=t.getAxisProxy(i,a),s=us(t,o);s?r.push([o,s]):o.reset(t,null)}),C(r,function(i){i[0].reset(t,i[1].getWindow().percentInverted)}),t.eachTargetAxis(function(i,a){t.getAxisProxy(i,a).filterData(t,e)})}),n.eachComponent("dataZoom",function(t){var r=t.findRepresentativeAxisProxy();if(r){var i=r.getWindow(),a=i.percent,o=i.value;t.setCalculatedRange({start:a[0],end:a[1],startValue:o[0],endValue:o[1]})}})}};function fh(n){n.registerAction("dataZoom",function(e,t){var r=lh(t,e);C(r,function(i){i.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}var dh=_o();function $n(n){dh(n,function(){n.registerProcessor(n.PRIORITY.PROCESSOR.FILTER,ph),fh(n),n.registerSubTypeDefaulter("dataZoom",function(){return"slider"})})}function gh(n){n.registerComponentModel(ch),n.registerComponentView(hh),$n(n)}var Ct=(function(){function n(){}return n})(),cs={};function te(n,e){cs[n]=e}function hs(n){return cs[n]}var yh=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r,i){var a=i.getTheme().get("toolbox"),o=a?a.feature:null;o&&(this._themeFeatureOption=Z({},o),a.feature={}),n.prototype.init.call(this,t,r,i),o&&(a.feature=o)},e.prototype.optionUpdated=function(){C(this.option.feature,function(t,r){var i=this._themeFeatureOption,a=hs(r);a&&(a.getDefaultOption&&(a.defaultOption=a.getDefaultOption(this.ecModel)),i&&i[r]&&(Q(t,i[r]),i[r]=null),Q(t,a.defaultOption))},this)},e.type="toolbox",e.layoutMode={type:"box",ignoreSize:!0},e.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:A.color.border,borderRadius:0,borderWidth:0,padding:A.size.m,itemSize:15,itemGap:A.size.s,showTitle:!0,iconStyle:{borderColor:A.color.accent50,color:"none"},emphasis:{iconStyle:{borderColor:A.color.accent70}},tooltip:{show:!1,position:"bottom"}},e})(tt);function vs(n,e){var t=dr(e.get("padding")),r=e.getItemStyle(["color","opacity"]);r.fill=e.get("backgroundColor");var i=new nt({shape:{x:n.x-t[3],y:n.y-t[0],width:n.width+t[1]+t[3],height:n.height+t[0]+t[2],r:e.get("borderRadius")},style:r,silent:!0,z2:-1});return i}var mh=(function(n){I(e,n);function e(){return n!==null&&n.apply(this,arguments)||this}return e.prototype.render=function(t,r,i,a){var o=this.group;if(o.removeAll(),!t.get("show"))return;var s=+t.get("itemSize"),l=t.get("orient")==="vertical",u=t.get("feature")||{},c=this._features||(this._features=J()),h=[];C(u,function(m,x){h.push(x)}),new gl(this._featureNames||[],h).add(v).update(v).remove(G(v,null)).execute(),this._featureNames=Et(h,function(m){return c.hasKey(m)});function v(m,x){var S=m!=null&&x==null,_=m!=null&&x!=null,b=m==null,w=S||_?h[m]:h[x],M=u[w],T=S||_?new rt(M,t,r):null,L=T&&T.get("show"),D;if(S){if(!L)return;if(xh(w))D={onclick:T.option.onclick,featureName:w};else{var V=hs(w);if(!V)return;D=new V}c.set(w,D)}else D=c.get(w);if(b||!L){sa(D)&&D.dispose&&D.dispose(r,i),c.removeKey(w);return}a&&a.newTitle!=null&&a.featureName===w&&(M.title=a.newTitle),S&&(D.uid=yl("toolbox-feature")),D.model=T,D.ecModel=r,D.api=i,p(T,D,w),T.setIconStatus=function(P,z){var N=this.option,H=this.iconPaths;N.iconStatus=N.iconStatus||{},N.iconStatus[P]=z,H[P]&&(z==="emphasis"?li:ui)(H[P])},sa(D)&&D.render&&D.render(T,r,i,a)}function p(m,x,S){var _=m.getModel("iconStyle"),b=m.getModel(["emphasis","iconStyle"]),w=x instanceof Ct&&x.getIcons?x.getIcons():m.get("icon"),M=m.get("title")||{},T,L;E(w)?(T={},T[S]=w):T=w,E(M)?(L={},L[S]=M):L=M;var D=m.iconPaths={};C(T,function(V,P){var z=pr(V,{},{x:-s/2,y:-s/2,width:s,height:s});z.setStyle(_.getItemStyle());var N=z.ensureState("emphasis");N.style=b.getItemStyle();var H=new $({style:{text:L[P],align:b.get("textAlign"),borderRadius:b.get("textBorderRadius"),padding:b.get("textPadding"),fill:null,font:ml({fontStyle:b.get("textFontStyle"),fontFamily:b.get("textFontFamily"),fontSize:b.get("textFontSize"),fontWeight:b.get("textFontWeight")},r)},ignore:!0});z.setTextContent(H),we({el:z,componentModel:t,itemName:P,formatterParamsExtra:{title:L[P]}}),z.__title=L[P],z.on("mouseover",function(){var St=b.getItemStyle(),kt=l?t.get("right")==null&&t.get("left")!=="right"?"right":"left":t.get("bottom")==null&&t.get("top")!=="bottom"?"bottom":"top";H.setStyle({fill:b.get("textFill")||St.fill||St.stroke||A.color.neutral99,backgroundColor:b.get("textBackgroundColor")}),z.setTextConfig({position:b.get("textPosition")||kt}),H.ignore=!t.get("showTitle"),i.enterEmphasis(this)}).on("mouseout",function(){m.get(["iconStatus",P])!=="emphasis"&&i.leaveEmphasis(this),H.hide()}),(m.get(["iconStatus",P])==="emphasis"?li:ui)(z),o.add(z),z.on("click",O(x.onclick,x,r,i,P)),D[P]=z})}var f=Pt(t,i).refContainer,d=t.getBoxLayoutParams(),g=t.get("padding"),y=dt(d,f,g);Ft(t.get("orient"),o,t.get("itemGap"),y.width,y.height),Mn(o,d,f,g),o.add(vs(o.getBoundingRect(),t)),l||o.eachChild(function(m){var x=m.__title,S=m.ensureState("emphasis"),_=S.textConfig||(S.textConfig={}),b=m.getTextContent(),w=b&&b.ensureState("emphasis");if(w&&!F(w)&&x){var M=w.style||(w.style={}),T=mn(x,$.makeFont(M)),L=m.x+o.x,D=m.y+o.y+s,V=!1;D+T.height>i.getHeight()&&(_.position="top",V=!0);var P=V?-5-T.height:s+10;L+T.width/2>i.getWidth()?(_.position=["100%",P],M.align="right"):L-T.width/2<0&&(_.position=[0,P],M.align="left")}})},e.prototype.updateView=function(t,r,i,a){C(this._features,function(o){o&&o instanceof Ct&&o.updateView&&o.updateView(o.model,r,i,a)})},e.prototype.dispose=function(t,r){C(this._features,function(i){i&&i instanceof Ct&&i.dispose&&i.dispose(t,r)})},e.type="toolbox",e})(at);function xh(n){return n.indexOf("my")===0}function sa(n){return n instanceof Ct}var Sh=(function(n){I(e,n);function e(){return n!==null&&n.apply(this,arguments)||this}return e.prototype.onclick=function(t,r){var i=this.model,a=i.get("name")||t.get("title.0.text")||"echarts",o=r.getZr().painter.getType()==="svg",s=o?"svg":i.get("type",!0)||"png",l=r.getConnectedDataURL({type:s,backgroundColor:i.get("backgroundColor",!0)||t.get("backgroundColor")||A.color.neutral00,connectedBackgroundColor:i.get("connectedBackgroundColor"),excludeComponents:i.get("excludeComponents"),pixelRatio:i.get("pixelRatio")}),u=st.browser;if(typeof MouseEvent=="function"&&(u.newEdge||!u.ie&&!u.edge)){var c=document.createElement("a");c.download=a+"."+s,c.target="_blank",c.href=l;var h=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});c.dispatchEvent(h)}else if(window.navigator.msSaveOrOpenBlob||o){var v=l.split(","),p=v[0].indexOf("base64")>-1,f=o?decodeURIComponent(v[1]):v[1];p&&(f=window.atob(f));var d=a+"."+s;if(window.navigator.msSaveOrOpenBlob){for(var g=f.length,y=new Uint8Array(g);g--;)y[g]=f.charCodeAt(g);var m=new Blob([y]);window.navigator.msSaveOrOpenBlob(m,d)}else{var x=document.createElement("iframe");document.body.appendChild(x);var S=x.contentWindow,_=S.document;_.open("image/svg+xml","replace"),_.write(f),_.close(),S.focus(),_.execCommand("SaveAs",!0,d),document.body.removeChild(x)}}else{var b=i.get("lang"),w='',M=window.open();M.document.write(w),M.document.title=a}},e.getDefaultOption=function(t){var r={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:t.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:A.color.neutral00,name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])};return r},e})(Ct),la="__ec_magicType_stack__",_h=[["line","bar"],["stack"]],bh=(function(n){I(e,n);function e(){return n!==null&&n.apply(this,arguments)||this}return e.prototype.getIcons=function(){var t=this.model,r=t.get("icon"),i={};return C(t.get("type"),function(a){r[a]&&(i[a]=r[a])}),i},e.getDefaultOption=function(t){var r={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"},title:t.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}};return r},e.prototype.onclick=function(t,r,i){var a=this.model,o=a.get(["seriesIndex",i]);if(ua[i]){var s={series:[]},l=function(h){var v=h.subType,p=h.id,f=ua[i](v,p,h,a);f&&(j(f,h.option),s.series.push(f));var d=h.coordinateSystem;if(d&&d.type==="cartesian2d"&&(i==="line"||i==="bar")){var g=d.getAxesByScale("ordinal")[0];if(g){var y=g.dim,m=y+"Axis",x=h.getReferringComponents(m,Ut).models[0],S=x.componentIndex;s[m]=s[m]||[];for(var _=0;_<=S;_++)s[m][S]=s[m][S]||{};s[m][S].boundaryGap=i==="bar"}}};C(_h,function(h){pt(h,i)>=0&&C(h,function(v){a.setIconStatus(v,"normal")})}),a.setIconStatus(i,"emphasis"),t.eachComponent({mainType:"series",query:o==null?null:{seriesIndex:o}},l);var u,c=i;i==="stack"&&(u=Q({stack:a.option.title.tiled,tiled:a.option.title.stack},a.option.title),a.get(["iconStatus",i])!=="emphasis"&&(c="tiled")),r.dispatchAction({type:"changeMagicType",currentType:c,newOption:s,newTitle:u,featureName:"magicType"})}},e})(Ct),ua={line:function(n,e,t,r){if(n==="bar")return Q({id:e,type:"line",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},r.get(["option","line"])||{},!0)},bar:function(n,e,t,r){if(n==="line")return Q({id:e,type:"bar",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},r.get(["option","bar"])||{},!0)},stack:function(n,e,t,r){var i=t.get("stack")===la;if(n==="line"||n==="bar")return r.setIconStatus("stack",i?"normal":"emphasis"),Q({id:e,stack:i?"":la},r.get(["option","stack"])||{},!0)}};In({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(n,e){e.mergeOption(n.newOption)});var mr=new Array(60).join("-"),oe=" ";function wh(n){var e={},t=[],r=[];return n.eachRawSeries(function(i){var a=i.coordinateSystem;if(a&&(a.type==="cartesian2d"||a.type==="polar")){var o=a.getBaseAxis();if(o.type==="category"){var s=pu(o);e[s]||(e[s]={categoryAxis:o,valueAxis:a.getOtherAxis(o),series:[]},r.push({axisDim:o.dim,axisIndex:o.index})),e[s].series.push(i)}else t.push(i)}else t.push(i)}),{seriesGroupByCategoryAxis:e,other:t,meta:r}}function Ch(n){var e=[];return C(n,function(t,r){var i=t.categoryAxis,a=t.valueAxis,o=a.dim,s=[" "].concat(B(t.series,function(p){return p.name})),l=[i.model.getCategories()];C(t.series,function(p){var f=p.getRawData();l.push(p.getRawData().mapArray(f.mapDimension(o),function(d){return d}))});for(var u=[s.join(oe)],c=0;c=0)return!0}var sn=new RegExp("["+oe+"]+","g");function Ih(n){for(var e=n.split(/\n+/g),t=or(e.shift()).split(sn),r=[],i=B(t,function(l){return{name:l,data:[]}}),a=0;a=0;a--){var o=t[a];if(o[i])break}if(a<0){var s=n.queryComponents({mainType:"dataZoom",subType:"select",id:i})[0];if(s){var l=s.getPercentRange();t[0][i]={dataZoomId:i,start:l[0],end:l[1]}}}}),t.push(e)}function Rh(n){var e=Yn(n),t=e[e.length-1];e.length>1&&e.pop();var r={};return ps(t,function(i,a){for(var o=e.length-1;o>=0;o--)if(i=e[o][a],i){r[a]=i;break}}),r}function zh(n){fs(n).snapshots=null}function Vh(n){return Yn(n).length}function Yn(n){var e=fs(n);return e.snapshots||(e.snapshots=[{}]),e.snapshots}var Bh=(function(n){I(e,n);function e(){return n!==null&&n.apply(this,arguments)||this}return e.prototype.onclick=function(t,r){zh(t),r.dispatchAction({type:"restore",from:this.uid})},e.getDefaultOption=function(t){var r={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:t.getLocaleModel().get(["toolbox","restore","title"])};return r},e})(Ct);In({type:"restore",event:"restore",update:"prepareAndUpdate"},function(n,e){e.resetOption("recreate")});var Eh=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],Un=(function(){function n(e,t,r){var i=this;this._targetInfoList=[];var a=ca(t,e);C(Nh,function(o,s){(!r||!r.include||pt(r.include,s)>=0)&&o(a,i._targetInfoList)})}return n.prototype.setOutputRanges=function(e,t){return this.matchOutputRanges(e,t,function(r,i,a){if((r.coordRanges||(r.coordRanges=[])).push(i),!r.coordRange){r.coordRange=i;var o=Or[r.brushType](0,a,i);r.__rangeOffset={offset:fa[r.brushType](o.values,r.range,[1,1]),xyMinMax:o.xyMinMax}}}),e},n.prototype.matchOutputRanges=function(e,t,r){C(e,function(i){var a=this.findTargetInfo(i,t);a&&a!==!0&&C(a.coordSyses,function(o){var s=Or[i.brushType](1,o,i.range,!0);r(i,s.values,o,t)})},this)},n.prototype.setInputRanges=function(e,t){C(e,function(r){var i=this.findTargetInfo(r,t);if(r.range=r.range||[],i&&i!==!0){r.panelId=i.panelId;var a=Or[r.brushType](0,i.coordSys,r.coordRange),o=r.__rangeOffset;r.range=o?fa[r.brushType](a.values,o.offset,Gh(a.xyMinMax,o.xyMinMax)):a.values}},this)},n.prototype.makePanelOpts=function(e,t){return B(this._targetInfoList,function(r){var i=r.getPanelRect();return{panelId:r.panelId,defaultBrushType:t?t(r):null,clipPath:yu(i),isTargetByCursor:gu(i,e,r.coordSysModel),getLinearBrushOtherExtent:du(i)}})},n.prototype.controlSeries=function(e,t,r){var i=this.findTargetInfo(e,r);return i===!0||i&&pt(i.coordSyses,t.coordinateSystem)>=0},n.prototype.findTargetInfo=function(e,t){for(var r=this._targetInfoList,i=ca(t,e),a=0;an[1]&&n.reverse(),n}function ca(n,e){return Po(n,e,{includeMainTypes:Eh})}var Nh={grid:function(n,e){var t=n.xAxisModels,r=n.yAxisModels,i=n.gridModels,a=J(),o={},s={};!t&&!r&&!i||(C(t,function(l){var u=l.axis.grid.model;a.set(u.id,u),o[u.id]=!0}),C(r,function(l){var u=l.axis.grid.model;a.set(u.id,u),s[u.id]=!0}),C(i,function(l){a.set(l.id,l),o[l.id]=!0,s[l.id]=!0}),a.each(function(l){var u=l.coordinateSystem,c=[];C(u.getCartesians(),function(h,v){(pt(t,h.getAxis("x").model)>=0||pt(r,h.getAxis("y").model)>=0)&&c.push(h)}),e.push({panelId:"grid--"+l.id,gridModel:l,coordSysModel:l,coordSys:c[0],coordSyses:c,getPanelRect:va.grid,xAxisDeclared:o[l.id],yAxisDeclared:s[l.id]})}))},geo:function(n,e){C(n.geoModels,function(t){var r=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:r,coordSyses:[r],getPanelRect:va.geo})})}},ha=[function(n,e){var t=n.xAxisModel,r=n.yAxisModel,i=n.gridModel;return!i&&t&&(i=t.axis.grid.model),!i&&r&&(i=r.axis.grid.model),i&&i===e.gridModel},function(n,e){var t=n.geoModel;return t&&t===e.geoModel}],va={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var n=this.coordSys.view,e=fu(null,n);return Vs(e,e,Zo(null,n)),e}},Or={lineX:G(pa,0),lineY:G(pa,1),rect:function(n,e,t,r){var i=n?e.pointToData([t[0][0],t[1][0]],r):e.dataToPoint([t[0][0],t[1][0]],r),a=n?e.pointToData([t[0][1],t[1][1]],r):e.dataToPoint([t[0][1],t[1][1]],r),o=[ln([i[0],a[0]]),ln([i[1],a[1]])];return{values:o,xyMinMax:o}},polygon:function(n,e,t,r){var i=[je(),je()],a=B(t,function(o){var s=n?e.pointToData(o,r):e.dataToPoint(o,r);return i[0][0]=Math.min(i[0][0],s[0]),i[1][0]=Math.min(i[1][0],s[1]),i[0][1]=Math.max(i[0][1],s[0]),i[1][1]=Math.max(i[1][1],s[1]),s});return{values:a,xyMinMax:i}}};function pa(n,e,t,r){var i=t.getAxis(["x","y"][n]),a=ln(B([0,1],function(s){return e?i.coordToData(i.toLocalCoord(r[s]),!0):i.toGlobalCoord(i.dataToCoord(r[s]))})),o=[];return o[n]=a,o[1-n]=[NaN,NaN],{values:a,xyMinMax:o}}var fa={lineX:G(da,0),lineY:G(da,1),rect:function(n,e,t){return[[n[0][0]-t[0]*e[0][0],n[0][1]-t[0]*e[0][1]],[n[1][0]-t[1]*e[1][0],n[1][1]-t[1]*e[1][1]]]},polygon:function(n,e,t){return B(n,function(r,i){return[r[0]-t[0]*e[i][0],r[1]-t[1]*e[i][1]]})}};function da(n,e,t,r){return[e[0]-r[n]*t[0],e[1]-r[n]*t[1]]}function Gh(n,e){var t=ga(n),r=ga(e),i=[t[0]/r[0],t[1]/r[1]];return isNaN(i[0])&&(i[0]=1),isNaN(i[1])&&(i[1]=1),i}function ga(n){return n?[n[0][1]-n[0][0],n[1][1]-n[1][0]]:[NaN,NaN]}var un=C,Hh=Sl("toolbox-dataZoom_"),Wh={x:"width",y:"height"},Zh=(function(n){I(e,n);function e(){return n!==null&&n.apply(this,arguments)||this}return e.prototype.render=function(t,r,i,a){this._brushController||(this._brushController=new Fo(i.getZr()),this._brushController.on("brush",O(this._onBrush,this)).mount()),Yh(t,r,this,a,i),$h(t,r)},e.prototype.onclick=function(t,r,i){Fh[i].call(this)},e.prototype.dispose=function(t,r){this._brushController&&this._brushController.dispose()},e.prototype._onBrush=function(t){var r=t.areas;if(!t.isEnd||!r.length)return;var i={},a=this.ecModel;this._brushController.updateCovers([]);var o=new Un(Xn(this.model),a,{include:["grid"]});o.matchOutputRanges(r,a,function(u,c,h){if(h.type==="cartesian2d"){var v=h.master.getRect().clone(),p=u.brushType;p==="rect"?(s("x",h,v,c[0]),s("y",h,v,c[1])):s({lineX:"x",lineY:"y"}[p],h,v,c)}}),Oh(a,i),this._dispatchZoomAction(i);function s(u,c,h,v){var p=c.getAxis(u),f=p.model,d=l(u,f,a),g=d.findRepresentativeAxisProxy(f).getMinMaxSpan(),y=p.scale.getExtent();(g.minValueSpan!=null||g.maxValueSpan!=null)&&(v=Kt(0,v.slice(),y,0,g.minValueSpan,g.maxValueSpan));var m=Lo(y,h[Wh[u]],.5);d&&(i[d.id]={dataZoomId:d.id,startValue:isFinite(m)?qe(v[0],m):v[0],endValue:isFinite(m)?qe(v[1],m):v[1]})}function l(u,c,h){var v;return h.eachComponent({mainType:"dataZoom",subType:"select"},function(p){var f=p.getAxisModel(u,c.componentIndex);f&&(v=p)}),v}},e.prototype._dispatchZoomAction=function(t){var r=[];un(t,function(i,a){r.push(W(i))}),r.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:r})},e.getDefaultOption=function(t){var r={show:!0,filterMode:"filter",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:t.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:A.color.backgroundTint}};return r},e})(Ct),Fh={zoom:function(){var n=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:n})},back:function(){this._dispatchZoomAction(Rh(this.ecModel))}};function Xn(n){var e={xAxisIndex:n.get("xAxisIndex",!0),yAxisIndex:n.get("yAxisIndex",!0),xAxisId:n.get("xAxisId",!0),yAxisId:n.get("yAxisId",!0)};return e.xAxisIndex==null&&e.xAxisId==null&&(e.xAxisIndex="all"),e.yAxisIndex==null&&e.yAxisId==null&&(e.yAxisIndex="all"),e}function $h(n,e){n.setIconStatus("back",Vh(e)>1?"emphasis":"normal")}function Yh(n,e,t,r,i){var a=t._isZoomActive;r&&r.type==="takeGlobalCursor"&&(a=r.key==="dataZoomSelect"?r.dataZoomSelectActive:!1),t._isZoomActive=a,n.setIconStatus("zoom",a?"emphasis":"normal");var o=new Un(Xn(n),e,{include:["grid"]}),s=o.makePanelOpts(i,function(l){return l.xAxisDeclared&&!l.yAxisDeclared?"lineX":!l.xAxisDeclared&&l.yAxisDeclared?"lineY":"rect"});t._brushController.setPanels(s).enableBrush(a&&s.length?{brushType:"auto",brushStyle:n.getModel("brushStyle").getItemStyle()}:!1)}xl("dataZoom",function(n){var e=n.getComponent("toolbox",0),t=["feature","dataZoom"];if(!e||e.get(t)==null)return;var r=e.getModel(t),i=[],a=Xn(r),o=Po(n,a);un(o.xAxisModels,function(l){return s(l,"xAxis","xAxisIndex")}),un(o.yAxisModels,function(l){return s(l,"yAxis","yAxisIndex")});function s(l,u,c){var h=l.componentIndex,v={type:"select",$fromToolbox:!0,filterMode:r.get("filterMode",!0)||"filter",id:Hh+u+h};v[c]=h,i.push(v)}return i});function If(n){n.registerComponentModel(yh),n.registerComponentView(mh),te("saveAsImage",Sh),te("magicType",bh),te("dataView",Ph),te("dataZoom",Zh),te("restore",Bh),ft(gh)}var Uh=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.type="tooltip",e.dependencies=["axisPointer"],e.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click|mousewheel",alwaysShowContent:!1,renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,displayTransition:!0,enterable:!1,backgroundColor:A.color.neutral00,shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,defaultBorderColor:A.color.border,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:A.color.borderShade,width:1,type:"dashed",textStyle:{}}},textStyle:{color:A.color.tertiary,fontSize:14}},e})(tt);function ds(n){var e=n.get("confine");return e!=null?!!e:n.get("renderMode")==="richText"}function gs(n){if(st.domSupported){for(var e=document.documentElement.style,t=0,r=n.length;t-1?(s+="top:50%",l+="translateY(-50%) rotate("+(u=a==="left"?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(u=a==="top"?225:45)+"deg)");var c=u*Math.PI/180,h=o+i,v=h*Math.abs(Math.cos(c))+h*Math.abs(Math.sin(c)),p=Math.round(((v-Math.SQRT2*i)/2+Math.SQRT2*i-(v-h)/2)*100)/100;s+=";"+a+":-"+p+"px";var f=e+" solid "+i+"px;",d=["position:absolute;width:"+o+"px;height:"+o+"px;z-index:-1;",s+";"+l+";","border-bottom:"+f,"border-right:"+f,"background-color:"+r+";"];return'
'}function tv(n,e,t){var r="cubic-bezier(0.23,1,0.32,1)",i="",a="";return t&&(i=" "+n/2+"s "+r,a="opacity"+i+",visibility"+i),e||(i=" "+n+"s "+r,a+=(a.length?",":"")+(st.transformSupported?""+Kn+i:",left"+i+",top"+i)),qh+":"+a}function ya(n,e,t){var r=n.toFixed(0)+"px",i=e.toFixed(0)+"px";if(!st.transformSupported)return t?"top:"+i+";left:"+r+";":[["top",i],["left",r]];var a=st.transform3dSupported,o="translate"+(a?"3d":"")+"("+r+","+i+(a?",0":"")+")";return t?"top:0;left:0;"+Kn+":"+o+";":[["top",0],["left",0],[ys,o]]}function ev(n){var e=[],t=n.get("fontSize"),r=n.getTextColor();r&&e.push("color:"+r),e.push("font:"+n.getFont());var i=U(n.get("lineHeight"),Math.round(t*3/2));t&&e.push("line-height:"+i+"px");var a=n.get("textShadowColor"),o=n.get("textShadowBlur")||0,s=n.get("textShadowOffsetX")||0,l=n.get("textShadowOffsetY")||0;return a&&o&&e.push("text-shadow:"+s+"px "+l+"px "+o+"px "+a),C(["decoration","align"],function(u){var c=n.get(u);c&&e.push("text-"+u+":"+c)}),e.join(";")}function rv(n,e,t,r){var i=[],a=n.get("transitionDuration"),o=n.get("backgroundColor"),s=n.get("shadowBlur"),l=n.get("shadowColor"),u=n.get("shadowOffsetX"),c=n.get("shadowOffsetY"),h=n.getModel("textStyle"),v=Oo(n,"html"),p=u+"px "+c+"px "+s+"px "+l;return i.push("box-shadow:"+p),e&&a>0&&i.push(tv(a,t,r)),o&&i.push("background-color:"+o),C(["width","color","radius"],function(f){var d="border-"+f,g=ko(d),y=n.get(g);y!=null&&i.push(d+":"+y+(f==="color"?"":"px"))}),i.push(ev(h)),v!=null&&i.push("padding:"+dr(v).join("px ")+"px"),i.join(";")+";"}function ma(n,e,t,r,i){var a=e&&e.painter;if(t){var o=a&&a.getViewportRoot();o&&Es(n,o,t,r,i)}else{n[0]=r,n[1]=i;var s=a&&a.getViewportRootOffset();s&&(n[0]+=s.offsetLeft,n[1]+=s.offsetTop)}n[2]=n[0]/e.getWidth(),n[3]=n[1]/e.getHeight()}var nv=(function(){function n(e,t){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,st.wxa)return null;var r=document.createElement("div");r.domBelongToZr=!0,this.el=r;var i=this._zr=e.getZr(),a=t.appendTo,o=a&&(E(a)?document.querySelector(a):Yr(a)?a:F(a)&&a(e.getDom()));ma(this._styleCoord,i,o,e.getWidth()/2,e.getHeight()/2),(o||e.getDom()).appendChild(r),this._api=e,this._container=o;var s=this;r.onmouseenter=function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0},r.onmousemove=function(l){if(l=l||window.event,!s._enterable){var u=i.handler,c=i.painter.getViewportRoot();Bs(c,l,!0),u.dispatch("mousemove",l)}},r.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return n.prototype.update=function(e){if(!this._container){var t=this._api.getDom(),r=Kh(t,"position"),i=t.style;i.position!=="absolute"&&r!=="absolute"&&(i.position="relative")}var a=e.get("alwaysShowContent");a&&this._moveIfResized(),this._alwaysShowContent=a,this._enableDisplayTransition=e.get("displayTransition")&&e.get("transitionDuration")>0,this.el.className=e.get("className")||""},n.prototype.show=function(e,t){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var r=this.el,i=r.style,a=this._styleCoord;r.innerHTML?i.cssText=jh+rv(e,!this._firstShow,this._longHide,this._enableDisplayTransition)+ya(a[0],a[1],!0)+("border-color:"+Je(t)+";")+(e.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):i.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},n.prototype.setContent=function(e,t,r,i,a){var o=this.el;if(e==null){o.innerHTML="";return}var s="";if(E(a)&&r.get("trigger")==="item"&&!ds(r)&&(s=Qh(r,i,a)),E(e))o.innerHTML=e+s;else if(e){o.innerHTML="",R(e)||(e=[e]);for(var l=0;l=0?this._tryShow(a,o):i==="leave"&&this._hide(o))},this))},e.prototype._keepShow=function(){var t=this._tooltipModel,r=this._ecModel,i=this._api,a=t.get("triggerOn");if(t.get("trigger")!=="axis"&&(this._lastDataByCoordSys=null,this._cbParamsList=null),this._lastX!=null&&this._lastY!=null&&a!=="none"&&a!=="click"){var o=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!i.isDisposed()&&o.manuallyShowTip(t,r,i,{x:o._lastX,y:o._lastY,dataByCoordSys:o._lastDataByCoordSys})})}},e.prototype.manuallyShowTip=function(t,r,i,a){if(!(a.from===this.uid||st.node||!i.getDom())){var o=_a(a,i);this._ticket="";var s=a.dataByCoordSys,l=cv(a,r,i);if(l){var u=l.el.getBoundingRect().clone();u.applyTransform(l.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:l.el,position:a.position,positionDefault:"bottom"},o)}else if(a.tooltip&&a.x!=null&&a.y!=null){var c=av;c.x=a.x,c.y=a.y,c.update(),Y(c).tooltipConfig={name:null,option:a.tooltip},this._tryShow({offsetX:a.x,offsetY:a.y,target:c},o)}else if(s)this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,dataByCoordSys:s,tooltipOption:a.tooltipOption},o);else if(a.seriesIndex!=null){if(this._manuallyAxisShowTip(t,r,i,a))return;var h=Qo(a,r),v=h.point[0],p=h.point[1];v!=null&&p!=null&&this._tryShow({offsetX:v,offsetY:p,target:h.el,position:a.position,positionDefault:"bottom"},o)}else a.x!=null&&a.y!=null&&(i.dispatchAction({type:"updateAxisPointer",x:a.x,y:a.y}),this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,target:i.getZr().findHover(a.x,a.y).target},o))}},e.prototype.manuallyHideTip=function(t,r,i,a){var o=this._tooltipContent;this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,this._cbParamsList=null,a.from!==this.uid&&this._hide(_a(a,i))},e.prototype._manuallyAxisShowTip=function(t,r,i,a){var o=a.seriesIndex,s=a.dataIndex,l=r.getComponent("axisPointer").coordSysAxesInfo;if(!(o==null||s==null||l==null)){var u=r.getSeriesByIndex(o);if(u){var c=u.getData(),h=ve([c.getItemModel(s),u,(u.coordinateSystem||{}).model],this._tooltipModel);if(h.get("trigger")==="axis")return i.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:s,position:a.position}),!0}}},e.prototype._tryShow=function(t,r){var i=t.target,a=this._tooltipModel;if(a){this._lastX=t.offsetX,this._lastY=t.offsetY;var o=t.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,t);else if(i){var s=Y(i);if(s.ssrType==="legend")return;this._lastDataByCoordSys=null,this._cbParamsList=null;var l,u;Ro(i,function(c){if(c.tooltipDisabled)return l=u=null,!0;l||u||(Y(c).dataIndex!=null?l=c:Y(c).tooltipConfig!=null&&(u=c))},!0),l?this._showSeriesItemTooltip(t,l,r):u?this._showComponentItemTooltip(t,u,r):this._hide(r)}else this._lastDataByCoordSys=null,this._cbParamsList=null,this._hide(r)}},e.prototype._showOrMove=function(t,r){var i=t.get("showDelay");r=O(r,this),clearTimeout(this._showTimout),i>0?this._showTimout=setTimeout(r,i):r()},e.prototype._showAxisTooltip=function(t,r){var i=this._ecModel,a=this._tooltipModel,o=[r.offsetX,r.offsetY],s=ve([r.tooltipOption],a),l=this._renderMode,u=[],c=me("section",{blocks:[],noHeader:!0}),h=[],v=new br;C(t,function(m){C(m.dataByAxis,function(x){var S=i.getComponent(x.axisDim+"Axis",x.axisIndex),_=x.value,b=S.axis,w=b.scale.parse(_);if(!(!S||_==null)){var M=Ko(_,b,i,x.seriesDataIndices,x.valueLabelOpt),T=me("section",{header:M,noHeader:!Gs(M),sortBlocks:!0,blocks:[]});c.blocks.push(T),C(x.seriesDataIndices,function(L){var D=i.getSeriesByIndex(L.seriesIndex),V=L.dataIndexInside,P=D.getDataParams(V);if(!(P.dataIndex<0)){P.axisDim=x.axisDim,P.axisIndex=x.axisIndex,P.axisType=x.axisType,P.axisId=x.axisId,P.axisValue=go(S.axis,{value:w}),P.axisValueLabel=M,P.marker=v.makeTooltipMarker("item",Je(P.color),l);var z=ci(D.formatTooltip(V,!0,null)),N=z.frag;if(N){var H=ve([D],a).get("valueFormatter");T.blocks.push(H?Z({valueFormatter:H},N):N)}z.text&&h.push(z.text),u.push(P)}})}})}),c.blocks.reverse(),h.reverse();var p=r.position,f=s.get("order"),d=hi(c,v,l,f,i.get("useUTC"),s.get("textStyle"));d&&h.unshift(d);var g=l==="richText"?` `:"
",y=h.join(g);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(t,u)?this._updatePosition(s,p,o[0],o[1],this._tooltipContent,u):this._showTooltipContent(s,y,u,Math.random()+"",o[0],o[1],p,null,v)})},e.prototype._showSeriesItemTooltip=function(t,r,i){var a=this._ecModel,o=Y(r),s=o.seriesIndex,l=a.getSeriesByIndex(s),u=o.dataModel||l,c=o.dataIndex,h=o.dataType,v=u.getData(h),p=this._renderMode,f=t.positionDefault,d=ve([v.getItemModel(c),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,f?{position:f}:null),g=d.get("trigger");if(!(g!=null&&g!=="item")){var y=u.getDataParams(c,h),m=new br;y.marker=m.makeTooltipMarker("item",Je(y.color),p);var x=ci(u.formatTooltip(c,!1,h)),S=d.get("order"),_=d.get("valueFormatter"),b=x.frag,w=b?hi(_?Z({valueFormatter:_},b):b,m,p,S,a.get("useUTC"),d.get("textStyle")):x.text,M="item_"+u.name+"_"+c;this._showOrMove(d,function(){this._showTooltipContent(d,w,y,M,t.offsetX,t.offsetY,t.position,t.target,m)}),i({type:"showTip",dataIndexInside:c,dataIndex:v.getRawIndex(c),seriesIndex:s,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,r,i){var a=this._renderMode==="html",o=Y(r),s=o.tooltipConfig,l=s.option||{},u=l.encodeHTMLContent;if(E(l)){var c=l;l={content:c,formatter:c},u=!0}u&&a&&l.content&&(l=W(l),l.content=Hs(l.content));var h=[l],v=this._ecModel.getComponent(o.componentMainType,o.componentIndex);v&&h.push(v),h.push({formatter:l.content});var p=t.positionDefault,f=ve(h,this._tooltipModel,p?{position:p}:null),d=f.get("content"),g=Math.random()+"",y=new br;this._showOrMove(f,function(){var m=W(f.get("formatterParams")||{});this._showTooltipContent(f,d,m,g,t.offsetX,t.offsetY,t.position,r,y)}),i({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(t,r,i,a,o,s,l,u,c){if(this._ticket="",!(!t.get("showContent")||!t.get("show"))){var h=this._tooltipContent;h.setEnterable(t.get("enterable"));var v=t.get("formatter");l=l||t.get("position");var p=r,f=this._getNearestPoint([o,s],i,t.get("trigger"),t.get("borderColor"),t.get("defaultBorderColor",!0)),d=f.color;if(v)if(E(v)){var g=t.ecModel.get("useUTC"),y=R(i)?i[0]:i,m=y&&y.axisType&&y.axisType.indexOf("time")>=0;p=v,m&&(p=bl(y.axisValue,p,g)),p=wl(p,i,!0)}else if(F(v)){var x=O(function(S,_){S===this._ticket&&(h.setContent(_,c,t,d,l),this._updatePosition(t,l,o,s,h,i,u))},this);this._ticket=a,p=v(i,a,x)}else p=v;h.setContent(p,c,t,d,l),h.show(t,d),this._updatePosition(t,l,o,s,h,i,u)}},e.prototype._getNearestPoint=function(t,r,i,a,o){if(i==="axis"||R(r))return{color:a||o};if(!R(r))return{color:a||r.color||r.borderColor}},e.prototype._updatePosition=function(t,r,i,a,o,s,l){var u=this._api.getWidth(),c=this._api.getHeight();r=r||t.get("position");var h=o.getSize(),v=t.get("align"),p=t.get("verticalAlign"),f=l&&l.getBoundingRect().clone();if(l&&f.applyTransform(l.transform),F(r)&&(r=r([i,a],s,o.el,f,{viewSize:[u,c],contentSize:h.slice()})),R(r))i=X(r[0],u),a=X(r[1],c);else if(vt(r)){var d=r;d.width=h[0],d.height=h[1];var g=dt(d,{width:u,height:c});i=g.x,a=g.y,v=null,p=null}else if(E(r)&&l){var y=uv(r,f,h,t.get("borderWidth"));i=y[0],a=y[1]}else{var y=sv(i,a,o,u,c,v?null:20,p?null:20);i=y[0],a=y[1]}if(v&&(i-=ba(v)?h[0]/2:v==="right"?h[0]:0),p&&(a-=ba(p)?h[1]/2:p==="bottom"?h[1]:0),ds(t)){var y=lv(i,a,o,u,c);i=y[0],a=y[1]}o.moveTo(i,a)},e.prototype._updateContentNotChangedOnAxis=function(t,r){var i=this._lastDataByCoordSys,a=this._cbParamsList,o=!!i&&i.length===t.length;return o&&C(i,function(s,l){var u=s.dataByAxis||[],c=t[l]||{},h=c.dataByAxis||[];o=o&&u.length===h.length,o&&C(u,function(v,p){var f=h[p]||{},d=v.seriesDataIndices||[],g=f.seriesDataIndices||[];o=o&&v.value===f.value&&v.axisType===f.axisType&&v.axisId===f.axisId&&d.length===g.length,o&&C(d,function(y,m){var x=g[m];o=o&&y.seriesIndex===x.seriesIndex&&y.dataIndex===x.dataIndex}),a&&C(v.seriesDataIndices,function(y){var m=y.seriesIndex,x=r[m],S=a[m];x&&S&&S.data!==x.data&&(o=!1)})})}),this._lastDataByCoordSys=t,this._cbParamsList=r,!!o},e.prototype._hide=function(t){this._lastDataByCoordSys=null,this._cbParamsList=null,t({type:"hideTip",from:this.uid})},e.prototype.dispose=function(t,r){st.node||!r.getDom()||(Xe(this,"_updatePosition"),this._tooltipContent.dispose(),tn("itemTooltip",r),this._tooltipContent=null,this._tooltipModel=null,this._lastDataByCoordSys=null,this._cbParamsList=null)},e.type="tooltip",e})(at);function ve(n,e,t){var r=e.ecModel,i;t?(i=new rt(t,r,r),i=new rt(e.option,i,r)):i=e;for(var a=n.length-1;a>=0;a--){var o=n[a];o&&(o instanceof rt&&(o=o.get("tooltip",!0)),E(o)&&(o={formatter:o}),o&&(i=new rt(o,i,r)))}return i}function _a(n,e){return n.dispatchAction||O(e.dispatchAction,e)}function sv(n,e,t,r,i,a,o){var s=t.getSize(),l=s[0],u=s[1];return a!=null&&(n+l+a+2>r?n-=l+a:n+=a),o!=null&&(e+u+o>i?e-=u+o:e+=o),[n,e]}function lv(n,e,t,r,i){var a=t.getSize(),o=a[0],s=a[1];return n=Math.min(n+o,r)-o,e=Math.min(e+s,i)-s,n=Math.max(n,0),e=Math.max(e,0),[n,e]}function uv(n,e,t,r){var i=t[0],a=t[1],o=Math.ceil(Math.SQRT2*r)+8,s=0,l=0,u=e.width,c=e.height;switch(n){case"inside":s=e.x+u/2-i/2,l=e.y+c/2-a/2;break;case"top":s=e.x+u/2-i/2,l=e.y-a-o;break;case"bottom":s=e.x+u/2-i/2,l=e.y+c+o;break;case"left":s=e.x-i-o,l=e.y+c/2-a/2;break;case"right":s=e.x+u+o,l=e.y+c/2-a/2}return[s,l]}function ba(n){return n==="center"||n==="middle"}function cv(n,e,t){var r=Cl(n).queryOptionMap,i=r.keys()[0];if(!(!i||i==="series")){var a=zo(e,i,r.get(i),{useDefault:!1,enableAll:!1,enableNone:!1}),o=a.models[0];if(o){var s=t.getViewOfComponentModel(o),l;if(s.group.traverse(function(u){var c=Y(u).tooltipConfig;if(c&&c.name===n.name)return l=u,!0}),l)return{componentMainType:i,componentIndex:o.componentIndex,el:l}}}}function Df(n){ft(yr),n.registerComponentModel(Uh),n.registerComponentView(ov),n.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},Ue),n.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},Ue)}var hv=["rect","polygon","keep","clear"];function vv(n,e){var t=Vo(n?n.brush:[]);if(t.length){var r=[];C(t,function(l){var u=l.hasOwnProperty("toolbox")?l.toolbox:[];u instanceof Array&&(r=r.concat(u))});var i=n&&n.toolbox;R(i)&&(i=i[0]),i||(i={feature:{}},n.toolbox=[i]);var a=i.feature||(i.feature={}),o=a.brush||(a.brush={}),s=o.type||(o.type=[]);s.push.apply(s,r),Tl(s,function(l){return l+""},null),e&&!s.length&&s.push.apply(s,hv)}}var wa=C;function Ca(n){if(n){for(var e in n)if(n.hasOwnProperty(e))return!0}}function cn(n,e,t){var r={};return wa(e,function(a){var o=r[a]=i();wa(n[a],function(s,l){if(ct.isValidType(l)){var u={type:l,visual:s};t&&t(u,a),o[l]=new ct(u),l==="opacity"&&(u=W(u),u.type="colorAlpha",o.__hidden.__alphaForOpacity=new ct(u))}})}),r;function i(){var a=function(){};a.prototype.__hidden=a.prototype;var o=new a;return o}}function xs(n,e,t){var r;C(t,function(i){e.hasOwnProperty(i)&&Ca(e[i])&&(r=!0)}),r&&C(t,function(i){e.hasOwnProperty(i)&&Ca(e[i])?n[i]=W(e[i]):delete n[i]})}function pv(n,e,t,r,i,a){var o={};C(n,function(h){var v=ct.prepareVisualTypes(e[h]);o[h]=v});var s;function l(h){return Bo(t,s,h)}function u(h,v){Eo(t,s,h,v)}t.each(c);function c(h,v){s=h;var p=t.getRawDataItem(s);if(!(p&&p.visualMap===!1))for(var f=r.call(i,h),d=e[f],g=o[f],y=0,m=g.length;ye[0][1]&&(e[0][1]=a[0]),a[1]e[1][1]&&(e[1][1]=a[1])}return e&&Da(e)}};function Da(n){return new Lt(n[0][0],n[1][0],n[0][1]-n[0][0],n[1][1]-n[1][0])}var bv=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r){this.ecModel=t,this.api=r,this.model,(this._brushController=new Fo(r.getZr())).on("brush",O(this._onBrush,this)).mount()},e.prototype.render=function(t,r,i,a){this.model=t,this._updateController(t,r,i,a)},e.prototype.updateTransform=function(t,r,i,a){Ss(r),this._updateController(t,r,i,a)},e.prototype.updateVisual=function(t,r,i,a){this.updateTransform(t,r,i,a)},e.prototype.updateView=function(t,r,i,a){this._updateController(t,r,i,a)},e.prototype._updateController=function(t,r,i,a){(!a||a.$from!==t.id)&&this._brushController.setPanels(t.brushTargetManager.makePanelOpts(i)).enableBrush(t.brushOption).updateCovers(t.areas.slice())},e.prototype.dispose=function(){this._brushController.dispose()},e.prototype._onBrush=function(t){var r=this.model.id,i=this.model.brushTargetManager.setOutputRanges(t.areas,this.ecModel);(!t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:r,areas:W(i),$from:r}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:r,areas:W(i),$from:r})},e.type="brush",e})(at),wv=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.areas=[],t.brushOption={},t}return e.prototype.optionUpdated=function(t,r){var i=this.option;!r&&xs(i,t,["inBrush","outOfBrush"]);var a=i.inBrush=i.inBrush||{};i.outOfBrush=i.outOfBrush||{color:this.option.defaultOutOfBrushColor},a.hasOwnProperty("liftZ")||(a.liftZ=5)},e.prototype.setAreas=function(t){t&&(this.areas=B(t,function(r){return La(this.option,r)},this))},e.prototype.setBrushOption=function(t){this.brushOption=La(this.option,t),this.brushType=this.brushOption.brushType},e.type="brush",e.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],e.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:A.color.backgroundTint,borderColor:A.color.borderTint},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4,defaultOutOfBrushColor:A.color.disabled},e})(tt);function La(n,e){return Q({brushType:n.brushType,brushMode:n.brushMode,transformable:n.transformable,brushStyle:new rt(n.brushStyle).getItemStyle(),removeOnClick:n.removeOnClick,z:n.z},e,!0)}var Cv=["rect","polygon","lineX","lineY","keep","clear"],Tv=(function(n){I(e,n);function e(){return n!==null&&n.apply(this,arguments)||this}return e.prototype.render=function(t,r,i){var a,o,s;r.eachComponent({mainType:"brush"},function(l){a=l.brushType,o=l.brushOption.brushMode||"single",s=s||!!l.areas.length}),this._brushType=a,this._brushMode=o,C(t.get("type",!0),function(l){t.setIconStatus(l,(l==="keep"?o==="multiple":l==="clear"?s:l===a)?"emphasis":"normal")})},e.prototype.updateView=function(t,r,i){this.render(t,r,i)},e.prototype.getIcons=function(){var t=this.model,r=t.get("icon",!0),i={};return C(t.get("type",!0),function(a){r[a]&&(i[a]=r[a])}),i},e.prototype.onclick=function(t,r,i){var a=this._brushType,o=this._brushMode;i==="clear"?(r.dispatchAction({type:"axisAreaSelect",intervals:[]}),r.dispatchAction({type:"brush",command:"clear",areas:[]})):r.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:i==="keep"?a:a===i?!1:i,brushMode:i==="keep"?o==="multiple"?"single":"multiple":o}})},e.getDefaultOption=function(t){var r={show:!0,type:Cv.slice(),icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:t.getLocaleModel().get(["toolbox","brush","title"])};return r},e})(Ct);function Lf(n){n.registerComponentView(bv),n.registerComponentModel(wv),n.registerPreprocessor(vv),n.registerVisual(n.PRIORITY.VISUAL.BRUSH,gv),n.registerAction({type:"brush",event:"brush",update:"updateVisual"},function(e,t){t.eachComponent({mainType:"brush",query:e},function(r){r.setAreas(e.areas)})}),n.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},Ue),n.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},Ue),te("brush",Tv)}var Av=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.type="title",e.defaultOption={z:6,show:!0,text:"",target:"blank",subtext:"",subtarget:"blank",left:"center",top:A.size.m,backgroundColor:A.color.transparent,borderColor:A.color.primary,borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:A.color.primary},subtextStyle:{fontSize:12,color:A.color.quaternary}},e})(tt),Mv=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,i){if(this.group.removeAll(),!!t.get("show")){var a=this.group,o=t.getModel("textStyle"),s=t.getModel("subtextStyle"),l=t.get("textAlign"),u=U(t.get("textBaseline"),t.get("textVerticalAlign")),c=new $({style:it(o,{text:t.get("text"),fill:o.getTextColor()},{disableBox:!0}),z2:10}),h=c.getBoundingRect(),v=t.get("subtext"),p=new $({style:it(s,{text:v,fill:s.getTextColor(),y:h.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),f=t.get("link"),d=t.get("sublink"),g=t.get("triggerEvent",!0);c.silent=!f&&!g,p.silent=!d&&!g,f&&c.on("click",function(){vi(f,"_"+t.get("target"))}),d&&p.on("click",function(){vi(d,"_"+t.get("subtarget"))}),Y(c).eventData=Y(p).eventData=g?{componentType:"title",componentIndex:t.componentIndex}:null,a.add(c),v&&a.add(p);var y=a.getBoundingRect(),m=t.getBoxLayoutParams();m.width=y.width,m.height=y.height;var x=Pt(t,i),S=dt(m,x.refContainer,t.get("padding"));l||(l=t.get("left")||t.get("right"),l==="middle"&&(l="center"),l==="right"?S.x+=S.width:l==="center"&&(S.x+=S.width/2)),u||(u=t.get("top")||t.get("bottom"),u==="center"&&(u="middle"),u==="bottom"?S.y+=S.height:u==="middle"&&(S.y+=S.height/2),u=u||"top"),a.x=S.x,a.y=S.y,a.markRedraw();var _={align:l,verticalAlign:u};c.setStyle(_),p.setStyle(_),y=a.getBoundingRect();var b=S.margin,w=t.getItemStyle(["color","opacity"]);w.fill=t.get("backgroundColor");var M=new nt({shape:{x:y.x-b[3],y:y.y-b[0],width:y.width+b[1]+b[3],height:y.height+b[0]+b[2],r:t.get("borderRadius")},style:w,subPixelOptimize:!0,silent:!0});a.add(M)}},e.type="title",e})(at);function Pf(n){n.registerComponentModel(Av),n.registerComponentView(Mv)}var Pa=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.layoutMode="box",t}return e.prototype.init=function(t,r,i){this.mergeDefaultAndTheme(t,i),this._initData()},e.prototype.mergeOption=function(t){n.prototype.mergeOption.apply(this,arguments),this._initData()},e.prototype.setCurrentIndex=function(t){t==null&&(t=this.option.currentIndex);var r=this._data.count();this.option.loop?t=(t%r+r)%r:(t>=r&&(t=r-1),t<0&&(t=0)),this.option.currentIndex=t},e.prototype.getCurrentIndex=function(){return this.option.currentIndex},e.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},e.prototype.setPlayState=function(t){this.option.autoPlay=!!t},e.prototype.getPlayState=function(){return!!this.option.autoPlay},e.prototype._initData=function(){var t=this.option,r=t.data||[],i=t.axisType,a=this._names=[],o;i==="category"?(o=[],C(r,function(u,c){var h=ye(Al(u),""),v;vt(u)?(v=W(u),v.value=c):v=c,o.push(v),a.push(h)})):o=r;var s={category:"ordinal",time:"time",value:"number"}[i]||"number",l=this._data=new $t([{name:"value",type:s}],this);l.initData(o,a)},e.prototype.getData=function(){return this._data},e.prototype.getCategories=function(){if(this.get("axisType")==="category")return this._names.slice()},e.type="timeline",e.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:A.size.m,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:A.color.secondary},data:[]},e})(tt),_s=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline.slider",e.defaultOption=se(Pa.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:A.color.border,borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:A.color.accent10},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:A.color.tertiary},itemStyle:{color:A.color.accent20,borderWidth:0},checkpointStyle:{symbol:"circle",symbolSize:15,color:A.color.accent50,borderColor:A.color.accent50,borderWidth:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"rgba(0, 0, 0, 0)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M15 0C23.2843 0 30 6.71573 30 15C30 23.2843 23.2843 30 15 30C6.71573 30 0 23.2843 0 15C0 6.71573 6.71573 0 15 0ZM15 3C8.37258 3 3 8.37258 3 15C3 21.6274 8.37258 27 15 27C21.6274 27 27 21.6274 27 15C27 8.37258 21.6274 3 15 3ZM11.5 10.6699C11.5 9.90014 12.3333 9.41887 13 9.80371L20.5 14.1338C21.1667 14.5187 21.1667 15.4813 20.5 15.8662L13 20.1963C12.3333 20.5811 11.5 20.0999 11.5 19.3301V10.6699Z",stopIcon:"path://M15 0C23.2843 0 30 6.71573 30 15C30 23.2843 23.2843 30 15 30C6.71573 30 0 23.2843 0 15C0 6.71573 6.71573 0 15 0ZM15 3C8.37258 3 3 8.37258 3 15C3 21.6274 8.37258 27 15 27C21.6274 27 27 21.6274 27 15C27 8.37258 21.6274 3 15 3ZM11.5 10C12.3284 10 13 10.6716 13 11.5V18.5C13 19.3284 12.3284 20 11.5 20C10.6716 20 10 19.3284 10 18.5V11.5C10 10.6716 10.6716 10 11.5 10ZM18.5 10C19.3284 10 20 10.6716 20 11.5V18.5C20 19.3284 19.3284 20 18.5 20C17.6716 20 17 19.3284 17 18.5V11.5C17 10.6716 17.6716 10 18.5 10Z",nextIcon:"path://M0.838834 18.7383C0.253048 18.1525 0.253048 17.2028 0.838834 16.617L7.55635 9.89949L0.838834 3.18198C0.253048 2.59619 0.253048 1.64645 0.838834 1.06066C1.42462 0.474874 2.37437 0.474874 2.96015 1.06066L10.7383 8.83883L10.8412 8.95277C11.2897 9.50267 11.2897 10.2963 10.8412 10.8462L10.7383 10.9602L2.96015 18.7383C2.37437 19.3241 1.42462 19.3241 0.838834 18.7383Z",prevIcon:"path://M10.9602 1.06066C11.5459 1.64645 11.5459 2.59619 10.9602 3.18198L4.24264 9.89949L10.9602 16.617C11.5459 17.2028 11.5459 18.1525 10.9602 18.7383C10.3744 19.3241 9.42462 19.3241 8.83883 18.7383L1.06066 10.9602L0.957771 10.8462C0.509245 10.2963 0.509245 9.50267 0.957771 8.95277L1.06066 8.83883L8.83883 1.06066C9.42462 0.474874 10.3744 0.474874 10.9602 1.06066Z",prevBtnSize:18,nextBtnSize:18,color:A.color.accent50,borderColor:A.color.accent50,borderWidth:0},emphasis:{label:{show:!0,color:A.color.accent60},itemStyle:{color:A.color.accent60,borderColor:A.color.accent60},controlStyle:{color:A.color.accent70,borderColor:A.color.accent70}},progress:{lineStyle:{color:A.color.accent30},itemStyle:{color:A.color.accent40}},data:[]}),e})(Pa);hr(_s,Ln.prototype);var Iv=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline",e})(at),Dv=(function(n){I(e,n);function e(t,r,i,a){var o=n.call(this,t,r,i)||this;return o.type=a||"value",o}return e.prototype.getLabelModel=function(){return this.model.getModel("label")},e.prototype.isHorizontal=function(){return this.model.get("orient")==="horizontal"},e})(Nt),zr=Math.PI,ka=ht(),Lv=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r){this.api=r},e.prototype.render=function(t,r,i){if(this.model=t,this.api=i,this.ecModel=r,this.group.removeAll(),t.get("show",!0)){var a=this._layout(t,i),o=this._createGroup("_mainGroup"),s=this._createGroup("_labelGroup"),l=this._axis=this._createAxis(a,t);t.formatTooltip=function(u){var c=l.scale.getLabel({value:u});return me("nameValue",{noName:!0,value:c})},C(["AxisLine","AxisTick","Control","CurrentPointer"],function(u){this["_render"+u](a,o,l,t)},this),this._renderAxisLabel(a,s,l,t),this._position(a,t)}this._doPlayStop(),this._updateTicksStatus()},e.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},e.prototype.dispose=function(){this._clearTimer()},e.prototype._layout=function(t,r){var i=t.get(["label","position"]),a=t.get("orient"),o=Pv(t,r),s;i==null||i==="auto"?s=a==="horizontal"?o.y+o.height/2=0||s==="+"?"left":"right"},u={horizontal:s>=0||s==="+"?"top":"bottom",vertical:"middle"},c={horizontal:0,vertical:zr/2},h=a==="vertical"?o.height:o.width,v=t.getModel("controlStyle"),p=v.get("show",!0),f=p?v.get("itemSize"):0,d=p?v.get("itemGap"):0,g=f+d,y=t.get(["label","rotate"])||0;y=y*zr/180;var m,x,S,_=v.get("position",!0),b=p&&v.get("showPlayBtn",!0),w=p&&v.get("showPrevBtn",!0),M=p&&v.get("showNextBtn",!0),T=0,L=h;_==="left"||_==="bottom"?(b&&(m=[0,0],T+=g),w&&(x=[T,0],T+=g),M&&(S=[L-f,0],L-=g)):(b&&(m=[L-f,0],L-=g),w&&(x=[0,0],T+=g),M&&(S=[L-f,0],L-=g));var D=[T,L];return t.get("inverse")&&D.reverse(),{viewRect:o,mainLength:h,orient:a,rotation:c[a],labelRotation:y,labelPosOpt:s,labelAlign:t.get(["label","align"])||l[a],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||u[a],playPosition:m,prevBtnPosition:x,nextBtnPosition:S,axisExtent:D,controlSize:f,controlGap:d}},e.prototype._position=function(t,r){var i=this._mainGroup,a=this._labelGroup,o=t.viewRect;if(t.orient==="vertical"){var s=xn(),l=o.x,u=o.y+o.height;Ye(s,s,[-l,-u]),yn(s,s,-zr/2),Ye(s,s,[l,u]),o=o.clone(),o.applyTransform(s)}var c=m(o),h=m(i.getBoundingRect()),v=m(a.getBoundingRect()),p=[i.x,i.y],f=[a.x,a.y];f[0]=p[0]=c[0][0];var d=t.labelPosOpt;if(d==null||E(d)){var g=d==="+"?0:1;x(p,h,c,1,g),x(f,v,c,1,1-g)}else{var g=d>=0?0:1;x(p,h,c,1,g),f[1]=p[1]+d}i.setPosition(p),a.setPosition(f),i.rotation=a.rotation=t.rotation,y(i),y(a);function y(S){S.originX=c[0][0]-S.x,S.originY=c[1][0]-S.y}function m(S){return[[S.x,S.x+S.width],[S.y,S.y+S.height]]}function x(S,_,b,w,M){S[w]+=b[w][M]-_[w][M]}},e.prototype._createAxis=function(t,r){var i=r.getData(),a=r.get("axisType")||r.get("type");a!=="category"&&a!=="time"&&(a="value");var o=bn(r,a);o.getTicks=function(){return i.mapArray(["value"],function(u){return{value:u}})};var s=i.getDataExtent("value");o.setExtent(s[0],s[1]),Ml(o,{fixMinMax:[!0,!0]});var l=new Dv("value",o,t.axisExtent,a);return l.model=r,l},e.prototype._createGroup=function(t){var r=this[t]=new ot;return this.group.add(r),r},e.prototype._renderAxisLine=function(t,r,i,a){var o=i.getExtent();if(a.get(["lineStyle","show"])){var s=new Rt({shape:{x1:o[0],y1:0,x2:o[1],y2:0},style:Z({lineCap:"round"},a.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});r.add(s);var l=this._progressLine=new Rt({shape:{x1:o[0],x2:this._currentPointer?this._currentPointer.x:o[0],y1:0,y2:0},style:j({lineCap:"round",lineWidth:s.style.lineWidth},a.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});r.add(l)}},e.prototype._renderAxisTick=function(t,r,i,a){var o=this,s=a.getData(),l=i.scale.getTicks();this._tickSymbols=[],C(l,function(u){var c=i.dataToCoord(u.value),h=s.getItemModel(u.value),v=h.getModel("itemStyle"),p=h.getModel(["emphasis","itemStyle"]),f=h.getModel(["progress","itemStyle"]),d={x:c,y:0,onclick:O(o._changeTimeline,o,u.value)},g=Oa(h,v,r,d);g.ensureState("emphasis").style=p.getItemStyle(),g.ensureState("progress").style=f.getItemStyle(),re(g);var y=Y(g);h.get("tooltip")?(y.dataIndex=u.value,y.dataModel=a):y.dataIndex=y.dataModel=null,o._tickSymbols.push(g)})},e.prototype._renderAxisLabel=function(t,r,i,a){var o=this,s=i.getLabelModel();if(s.get("show")){var l=a.getData(),u=i.getViewLabels();this._tickLabels=[],C(u,function(c){if(!c.tick.offInterval){var h=c.tick.value,v=l.getItemModel(h),p=v.getModel("label"),f=v.getModel(["emphasis","label"]),d=v.getModel(["progress","label"]),g=i.dataToCoord(h),y=new $({x:g,y:0,rotation:t.labelRotation-t.rotation,onclick:O(o._changeTimeline,o,h),silent:!1,style:it(p,{text:c.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});y.ensureState("emphasis").style=it(f),y.ensureState("progress").style=it(d),r.add(y),re(y),ka(y).dataIndex=h,o._tickLabels.push(y)}})}},e.prototype._renderControl=function(t,r,i,a){var o=t.controlSize,s=t.rotation,l=a.getModel("controlStyle").getItemStyle(),u=a.getModel(["emphasis","controlStyle"]).getItemStyle(),c=a.getPlayState(),h=a.get("inverse",!0);v(t.nextBtnPosition,"next",O(this._changeTimeline,this,h?"-":"+")),v(t.prevBtnPosition,"prev",O(this._changeTimeline,this,h?"+":"-")),v(t.playPosition,c?"stop":"play",O(this._handlePlayClick,this,!c),!0);function v(p,f,d,g){if(p){var y=Ur(U(a.get(["controlStyle",f+"BtnSize"]),o),o),m=[0,-y/2,y,y],x=kv(a,f+"Icon",m,{x:p[0],y:p[1],originX:o/2,originY:0,rotation:g?-s:0,rectHover:!0,style:l,onclick:d});x.ensureState("emphasis").style=u,r.add(x),re(x)}}},e.prototype._renderCurrentPointer=function(t,r,i,a){var o=a.getData(),s=a.getCurrentIndex(),l=o.getItemModel(s).getModel("checkpointStyle"),u=this,c={onCreate:function(h){h.draggable=!0,h.drift=O(u._handlePointerDrag,u),h.ondragend=O(u._handlePointerDragend,u),Ra(h,u._progressLine,s,i,a,!0)},onUpdate:function(h){Ra(h,u._progressLine,s,i,a)}};this._currentPointer=Oa(l,l,this._mainGroup,{},this._currentPointer,c)},e.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},e.prototype._handlePointerDrag=function(t,r,i){this._clearTimer(),this._pointerChangeTimeline([i.offsetX,i.offsetY])},e.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},e.prototype._pointerChangeTimeline=function(t,r){var i=this._toAxisCoord(t)[0],a=this._axis,o=xt(a.getExtent().slice());i>o[1]&&(i=o[1]),i=0&&(s[o]=+s[o].toFixed(f)),[s,p]}var Be={min:G(Ve,"min"),max:G(Ve,"max"),average:G(Ve,"average"),median:G(Ve,"median")};function Se(n,e){if(e){var t=n.getData(),r=n.coordinateSystem,i=r&&r.dimensions;if(!Bv(e)&&!R(e.coord)&&R(i)){var a=bs(e,t,r,n);if(e=W(e),e.type&&Be[e.type]&&a.baseAxis&&a.valueAxis){var o=pt(i,a.baseAxis.dim),s=pt(i,a.valueAxis.dim),l=Be[e.type](t,a.valueAxis.dim,a.baseDataDim,a.valueDataDim,o,s);e.coord=l[0],e.value=l[1]}else e.coord=[e.xAxis!=null?e.xAxis:e.radiusAxis,e.yAxis!=null?e.yAxis:e.angleAxis]}if(e.coord==null||!R(i)){e.coord=[];var u=n.getBaseAxis();if(u&&e.type&&Be[e.type]){var c=r.getOtherAxis(u);c&&(e.value=sr(t,t.mapDimension(c.dim),e.type))}}else for(var h=e.coord,v=0;v<2;v++)Be[h[v]]&&(h[v]=sr(t,t.mapDimension(i[v]),h[v]));return e}}function bs(n,e,t,r){var i={};return n.valueIndex!=null||n.valueDim!=null?(i.valueDataDim=n.valueIndex!=null?e.getDimension(n.valueIndex):n.valueDim,i.valueAxis=t.getAxis(Ev(r,i.valueDataDim)),i.baseAxis=t.getOtherAxis(i.valueAxis),i.baseDataDim=e.mapDimension(i.baseAxis.dim)):(i.baseAxis=r.getBaseAxis(),i.valueAxis=t.getOtherAxis(i.baseAxis),i.baseDataDim=e.mapDimension(i.baseAxis.dim),i.valueDataDim=e.mapDimension(i.valueAxis.dim)),i}function Ev(n,e){var t=n.getData().getDimensionInfo(e);return t&&t.coordDim}function _e(n,e){return n&&n.containData&&e.coord&&!vn(e)?n.containData(e.coord):!0}function Nv(n,e,t){return n&&n.containZone&&e.coord&&t.coord&&!vn(e)&&!vn(t)?n.containZone(e.coord,t.coord):!0}function ws(n,e){return n?function(t,r,i,a){var o=a<2?t.coord&&t.coord[a]:t.value;return Qe(o,e[a])}:function(t,r,i,a){return Qe(t.value,e[a])}}function sr(n,e,t){if(t==="average"){var r=0,i=0;return n.each(e,function(a,o){isNaN(a)||(r+=a,i++)}),r/i}else return t==="median"?n.getMedian(e):n.getDataExtent(e)[t==="max"?1:0]}var Vr=ht(),jn=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this.markerGroupMap=J()},e.prototype.render=function(t,r,i){var a=this,o=this.markerGroupMap;o.each(function(s){Vr(s).keep=!1}),r.eachSeries(function(s){var l=Tt.getMarkerModelFromSeries(s,a.type);l&&a.renderSeries(s,l,r,i)}),o.each(function(s){!Vr(s).keep&&a.group.remove(s.group)}),Gv(r,o,this.type)},e.prototype.markKeep=function(t){Vr(t).keep=!0},e.prototype.toggleBlurSeries=function(t,r){var i=this;C(t,function(a){var o=Tt.getMarkerModelFromSeries(a,i.type);if(o){var s=o.getData();s.eachItemGraphicEl(function(l){l&&(r?kl(l):Ol(l))})}})},e.type="marker",e})(at);function Gv(n,e,t){n.eachSeries(function(r){var i=Tt.getMarkerModelFromSeries(r,t),a=e.get(r.id);if(i&&a&&a.group){var o=No(i),s=o.z,l=o.zlevel;Go(a.group,s,l)}})}function Va(n,e,t){var r=e.coordinateSystem,i=t.getWidth(),a=t.getHeight(),o=r&&r.getArea&&r.getArea();n.each(function(s){var l=n.getItemModel(s),u=l.get("relativeTo")==="coordinate",c=u?o?o.width:0:i,h=u?o?o.height:0:a,v=u&&o?o.x:0,p=u&&o?o.y:0,f,d=X(l.get("x"),c)+v,g=X(l.get("y"),h)+p;if(!isNaN(d)&&!isNaN(g))f=[d,g];else if(e.getMarkerPosition)f=e.getMarkerPosition(n.getValues(n.dimensions,s));else if(r){var y=n.get(r.dimensions[0],s),m=n.get(r.dimensions[1],s);f=r.dataToPoint([y,m])}isNaN(d)||(f[0]=d),isNaN(g)||(f[1]=g),n.setItemLayout(s,f)})}var Hv=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,r,i){r.eachSeries(function(a){var o=Tt.getMarkerModelFromSeries(a,"markPoint");o&&(Va(o.getData(),a,i),this.markerGroupMap.get(a.id).updateLayout())},this)},e.prototype.renderSeries=function(t,r,i,a){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,new mu),h=Wv(o,t,r);r.setData(h),Va(r.getData(),t,a),h.each(function(v){var p=h.getItemModel(v),f=p.getShallow("symbol"),d=p.getShallow("symbolSize"),g=p.getShallow("symbolRotate"),y=p.getShallow("symbolOffset"),m=p.getShallow("symbolKeepAspect");if(F(f)||F(d)||F(g)||F(y)){var x=r.getRawValue(v),S=r.getDataParams(v);F(f)&&(f=f(x,S)),F(d)&&(d=d(x,S)),F(g)&&(g=g(x,S)),F(y)&&(y=y(x,S))}var _=p.getModel("itemStyle").getItemStyle(),b=p.get("z2"),w=gr(l,"color");_.fill||(_.fill=w),h.setItemVisual(v,{z2:U(b,0),symbol:f,symbolSize:d,symbolRotate:g,symbolOffset:y,symbolKeepAspect:m,style:_})}),c.updateData(h),this.group.add(c.group),h.eachItemGraphicEl(function(v){v.traverse(function(p){Y(p).dataModel=r})}),this.markKeep(c),c.group.silent=r.get("silent")||t.get("silent")},e.type="markPoint",e})(jn);function Wv(n,e,t){var r;n?r=B(n&&n.dimensions,function(s){var l=e.getData(),u=l.getDimensionInfo(l.mapDimension(s))||{};return Z(Z({},u),{name:s,ordinalMeta:null})}):r=[{name:"value",type:"float"}];var i=new $t(r,t),a=B(t.get("data"),G(Se,e));n&&(a=Et(a,G(_e,n)));var o=ws(!!n,r);return i.initData(a,null,o),i}function Of(n){n.registerComponentModel(Vv),n.registerComponentView(Hv),n.registerPreprocessor(function(e){qn(e.series,"markPoint")&&(e.markPoint=e.markPoint||{})})}var Zv=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,r,i){return new e(t,r,i)},e.type="markLine",e.defaultOption={z:5,symbol:["circle","arrow"],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end",distance:5},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"},e})(Tt),Ee=ht(),Fv=function(n,e,t,r){var i=n.getData(),a;if(R(r))a=r;else{var o=r.type;if(o==="min"||o==="max"||o==="average"||o==="median"||r.xAxis!=null||r.yAxis!=null){var s=void 0,l=void 0;if(r.yAxis!=null||r.xAxis!=null)s=e.getAxis(r.yAxis!=null?"y":"x"),l=Zt(r.yAxis,r.xAxis);else{var u=bs(r,i,e,n);s=u.valueAxis;var c=Rl(i,u.valueDataDim);l=sr(i,c,o)}var h=s.dim==="x"?0:1,v=1-h,p=W(r),f={coord:[]};p.type=null,p.coord=[],p.coord[v]=-1/0,f.coord[v]=1/0;var d=t.get("precision");d>=0&&vr(l)&&(l=+l.toFixed(Math.min(d,20))),p.coord[h]=f.coord[h]=l,a=[p,f,{type:o,valueIndex:r.valueIndex,value:l}]}else a=[]}var g=[Se(n,a[0]),Se(n,a[1]),Z({},a[2])];return g[2].type=g[2].type||null,Q(g[2],g[0]),Q(g[2],g[1]),g};function lr(n){return!isNaN(n)&&!isFinite(n)}function Ba(n,e,t,r){var i=1-n,a=r.dimensions[n];return lr(e[i])&&lr(t[i])&&e[n]===t[n]&&r.getAxis(a).containData(e[n])}function $v(n,e){if(n.type==="cartesian2d"){var t=e[0].coord,r=e[1].coord;if(t&&r&&(Ba(1,t,r,n)||Ba(0,t,r,n)))return!0}return _e(n,e[0])&&_e(n,e[1])}function Br(n,e,t,r,i){var a=r.coordinateSystem,o=n.getItemModel(e),s,l=X(o.get("x"),i.getWidth()),u=X(o.get("y"),i.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(r.getMarkerPosition)s=r.getMarkerPosition(n.getValues(n.dimensions,e));else{var c=a.dimensions,h=n.get(c[0],e),v=n.get(c[1],e);s=a.dataToPoint([h,v])}if(kn(a,"cartesian2d")){var p=a.getAxis("x"),f=a.getAxis("y"),c=a.dimensions;lr(n.get(c[0],e))?s[0]=p.toGlobalCoord(p.getExtent()[t?0:1]):lr(n.get(c[1],e))&&(s[1]=f.toGlobalCoord(f.getExtent()[t?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}n.setItemLayout(e,s)}var Yv=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,r,i){r.eachSeries(function(a){var o=Tt.getMarkerModelFromSeries(a,"markLine");if(o){var s=o.getData(),l=Ee(o).from,u=Ee(o).to;l.each(function(c){Br(l,c,!0,a,i),Br(u,c,!1,a,i)}),s.each(function(c){s.setItemLayout(c,[l.getItemLayout(c),u.getItemLayout(c)])}),this.markerGroupMap.get(a.id).updateLayout()}},this)},e.prototype.renderSeries=function(t,r,i,a){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,new xu);this.group.add(c.group);var h=Uv(o,t,r),v=h.from,p=h.to,f=h.line;Ee(r).from=v,Ee(r).to=p,r.setData(f);var d=r.get("symbol"),g=r.get("symbolSize"),y=r.get("symbolRotate"),m=r.get("symbolOffset");R(d)||(d=[d,d]),R(g)||(g=[g,g]),R(y)||(y=[y,y]),R(m)||(m=[m,m]),h.from.each(function(S){x(v,S,!0),x(p,S,!1)}),f.each(function(S){var _=f.getItemModel(S),b=_.getModel("lineStyle").getLineStyle();f.setItemLayout(S,[v.getItemLayout(S),p.getItemLayout(S)]);var w=_.get("z2");b.stroke==null&&(b.stroke=v.getItemVisual(S,"style").fill),f.setItemVisual(S,{z2:U(w,0),fromSymbolKeepAspect:v.getItemVisual(S,"symbolKeepAspect"),fromSymbolOffset:v.getItemVisual(S,"symbolOffset"),fromSymbolRotate:v.getItemVisual(S,"symbolRotate"),fromSymbolSize:v.getItemVisual(S,"symbolSize"),fromSymbol:v.getItemVisual(S,"symbol"),toSymbolKeepAspect:p.getItemVisual(S,"symbolKeepAspect"),toSymbolOffset:p.getItemVisual(S,"symbolOffset"),toSymbolRotate:p.getItemVisual(S,"symbolRotate"),toSymbolSize:p.getItemVisual(S,"symbolSize"),toSymbol:p.getItemVisual(S,"symbol"),style:b})}),c.updateData(f),h.line.eachItemGraphicEl(function(S){Y(S).dataModel=r,S.traverse(function(_){Y(_).dataModel=r})});function x(S,_,b){var w=S.getItemModel(_);Br(S,_,b,t,a);var M=w.getModel("itemStyle").getItemStyle();M.fill==null&&(M.fill=gr(l,"color")),S.setItemVisual(_,{symbolKeepAspect:w.get("symbolKeepAspect"),symbolOffset:U(w.get("symbolOffset",!0),m[b?0:1]),symbolRotate:U(w.get("symbolRotate",!0),y[b?0:1]),symbolSize:U(w.get("symbolSize"),g[b?0:1]),symbol:U(w.get("symbol",!0),d[b?0:1]),style:M})}this.markKeep(c),c.group.silent=r.get("silent")||t.get("silent")},e.type="markLine",e})(jn);function Uv(n,e,t){var r;n?r=B(n&&n.dimensions,function(u){var c=e.getData(),h=c.getDimensionInfo(c.mapDimension(u))||{};return Z(Z({},h),{name:u,ordinalMeta:null})}):r=[{name:"value",type:"float"}];var i=new $t(r,t),a=new $t(r,t),o=new $t([],t),s=B(t.get("data"),G(Fv,e,n,t));n&&(s=Et(s,G($v,n)));var l=ws(!!n,r);return i.initData(B(s,function(u){return u[0]}),null,l),a.initData(B(s,function(u){return u[1]}),null,l),o.initData(B(s,function(u){return u[2]})),o.hasItemOption=!0,{from:i,to:a,line:o}}function Rf(n){n.registerComponentModel(Zv),n.registerComponentView(Yv),n.registerPreprocessor(function(e){qn(e.series,"markLine")&&(e.markLine=e.markLine||{})})}var Xv=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,r,i){return new e(t,r,i)},e.type="markArea",e.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},e})(Tt),Ne=ht(),Kv=function(n,e,t,r){var i=r[0],a=r[1];if(!(!i||!a)){var o=Se(n,i),s=Se(n,a),l=o.coord,u=s.coord;l[0]=Zt(l[0],-1/0),l[1]=Zt(l[1],-1/0),u[0]=Zt(u[0],1/0),u[1]=Zt(u[1],1/0);var c=Ws([{},o,s]);return c.coord=[o.coord,s.coord],c.x0=o.x,c.y0=o.y,c.x1=s.x,c.y1=s.y,c}};function ur(n){return!isNaN(n)&&!isFinite(n)}function Ea(n,e,t,r){var i=1-n;return ur(e[i])&&ur(t[i])}function qv(n,e){var t=e.coord[0],r=e.coord[1],i={coord:t,x:e.x0,y:e.y0},a={coord:r,x:e.x1,y:e.y1};return kn(n,"cartesian2d")?t&&r&&(Ea(1,t,r)||Ea(0,t,r))?!0:Nv(n,i,a):_e(n,i)||_e(n,a)}function Na(n,e,t,r,i){var a=r.coordinateSystem,o=n.getItemModel(e),s,l=X(o.get(t[0]),i.getWidth()),u=X(o.get(t[1]),i.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(r.getMarkerPosition){var c=n.getValues(["x0","y0"],e),h=n.getValues(["x1","y1"],e),v=a.clampData(c),p=a.clampData(h),f=[];t[0]==="x0"?f[0]=v[0]>p[0]?h[0]:c[0]:f[0]=v[0]>p[0]?c[0]:h[0],t[1]==="y0"?f[1]=v[1]>p[1]?h[1]:c[1]:f[1]=v[1]>p[1]?c[1]:h[1],s=r.getMarkerPosition(f,t,!0)}else{var d=n.get(t[0],e),g=n.get(t[1],e),y=[d,g];a.clampData&&a.clampData(y,y),s=a.dataToPoint(y,!0)}if(kn(a,"cartesian2d")){var m=a.getAxis("x"),x=a.getAxis("y"),d=n.get(t[0],e),g=n.get(t[1],e);ur(d)?s[0]=m.toGlobalCoord(m.getExtent()[t[0]==="x0"?0:1]):ur(g)&&(s[1]=x.toGlobalCoord(x.getExtent()[t[1]==="y0"?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}return s}var Ga=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],jv=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,r,i){r.eachSeries(function(a){var o=Tt.getMarkerModelFromSeries(a,"markArea");if(o){var s=o.getData();s.each(function(l){var u=B(Ga,function(h){return Na(s,l,h,a,i)});s.setItemLayout(l,u);var c=s.getItemGraphicEl(l);c.setShape("points",u)})}},this)},e.prototype.renderSeries=function(t,r,i,a){var o=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,c=u.get(s)||u.set(s,{group:new ot});this.group.add(c.group),this.markKeep(c);var h=Jv(o,t,r);r.setData(h),h.each(function(v){var p=B(Ga,function(L){return Na(h,v,L,t,a)}),f=o.getAxis("x").scale,d=o.getAxis("y").scale,g=f.getExtent(),y=d.getExtent(),m=[f.parse(h.get("x0",v)),f.parse(h.get("x1",v))],x=[d.parse(h.get("y0",v)),d.parse(h.get("y1",v))];xt(m),xt(x);var S=!(g[0]>m[1]||g[1]x[1]||y[1]=0},e.prototype.getOrient=function(){return this.get("orient")==="vertical"?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},e.type="legend.plain",e.dependencies=["series"],e.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",bottom:A.size.m,align:"auto",backgroundColor:A.color.transparent,borderColor:A.color.border,borderRadius:0,borderWidth:0,padding:5,itemGap:8,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:A.color.disabled,inactiveBorderColor:A.color.disabled,inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:A.color.disabled,inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:A.color.secondary},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:A.color.tertiary,borderWidth:1,borderColor:A.color.border},emphasis:{selectorLabel:{show:!0,color:A.color.quaternary}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1},triggerEvent:!1},e})(tt),Jt=G,fn=C,Ge=ot,Cs=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!1,t}return e.prototype.init=function(){this.group.add(this._contentGroup=new Ge),this.group.add(this._selectorGroup=new Ge),this._isFirstRender=!0},e.prototype.getContentGroup=function(){return this._contentGroup},e.prototype.getSelectorGroup=function(){return this._selectorGroup},e.prototype.render=function(t,r,i){var a=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),!!t.get("show",!0)){var o=t.get("align"),s=t.get("orient");(!o||o==="auto")&&(o=t.get("left")==="right"&&s==="vertical"?"right":"left");var l=t.get("selector",!0),u=t.get("selectorPosition",!0);l&&(!u||u==="auto")&&(u=s==="horizontal"?"end":"start"),this.renderInner(o,t,r,i,l,s,u);var c=Pt(t,i).refContainer,h=t.getBoxLayoutParams(),v=t.get("padding"),p=dt(h,c,v),f=this.layoutInner(t,o,p,a,l,u),d=dt(j({width:f.width,height:f.height},h),c,v);this.group.x=d.x-f.x,this.group.y=d.y-f.y,this.group.markRedraw(),this.group.add(this._backgroundEl=vs(f,t))}},e.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},e.prototype.renderInner=function(t,r,i,a,o,s,l){var u=this.getContentGroup(),c=J(),h=r.get("selectedMode"),v=r.get("triggerEvent"),p=[];i.eachRawSeries(function(f){!f.get("legendHoverLink")&&p.push(f.id)}),fn(r.getData(),function(f,d){var g=this,y=f.get("name");if(!this.newlineDisabled&&(y===""||y===` `)){var m=new Ge;m.newline=!0,u.add(m);return}var x=i.getSeriesByName(y)[0];if(!c.get(y))if(x){var S=x.getData(),_=S.getVisual("legendLineStyle")||{},b=S.getVisual("legendIcon"),w=S.getVisual("style"),M=this._createItem(x,y,d,f,r,t,_,w,b,h,a);M.on("click",Jt(Ha,y,null,a,p)).on("mouseover",Jt(dn,x.name,null,a,p)).on("mouseout",Jt(gn,x.name,null,a,p)),i.ssr&&M.eachChild(function(T){var L=Y(T);L.seriesIndex=x.seriesIndex,L.dataIndex=d,L.ssrType="legend"}),v&&M.eachChild(function(T){g.packEventData(T,r,x,d,y)}),c.set(y,!0)}else i.eachRawSeries(function(T){var L=this;if(!c.get(y)&&T.legendVisualProvider){var D=T.legendVisualProvider;if(!D.containName(y))return;var V=D.indexOfName(y),P=D.getItemVisual(V,"style"),z=D.getItemVisual(V,"legendIcon"),N=Zs(P.fill);N&&N[3]===0&&(N[3]=.2,P=Z(Z({},P),{fill:Fs(N,"rgba")}));var H=this._createItem(T,y,d,f,r,t,{},P,z,h,a);H.on("click",Jt(Ha,null,y,a,p)).on("mouseover",Jt(dn,null,y,a,p)).on("mouseout",Jt(gn,null,y,a,p)),i.ssr&&H.eachChild(function(St){var kt=Y(St);kt.seriesIndex=T.seriesIndex,kt.dataIndex=d,kt.ssrType="legend"}),v&&H.eachChild(function(St){L.packEventData(St,r,T,d,y)}),c.set(y,!0)}},this)},this),o&&this._createSelector(o,r,a,s,l)},e.prototype.packEventData=function(t,r,i,a,o){var s={componentType:"legend",componentIndex:r.componentIndex,dataIndex:a,value:o,seriesIndex:i.seriesIndex};Y(t).eventData=s},e.prototype._createSelector=function(t,r,i,a,o){var s=this.getSelectorGroup();fn(t,function(u){var c=u.type,h=new $({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){i.dispatchAction({type:c==="all"?"legendAllSelect":"legendInverseSelect",legendId:r.id})}});s.add(h);var v=r.getModel("selectorLabel"),p=r.getModel(["emphasis","selectorLabel"]);An(h,{normal:v,emphasis:p},{defaultText:u.title}),re(h)})},e.prototype._createItem=function(t,r,i,a,o,s,l,u,c,h,v){var p=t.visualDrawType,f=o.get("itemWidth"),d=o.get("itemHeight"),g=o.isSelected(r),y=a.get("symbolRotate"),m=a.get("symbolKeepAspect"),x=a.get("icon");c=x||c||"roundRect";var S=tp(c,a,l,u,p,g,v),_=new Ge,b=a.getModel("textStyle");if(F(t.getLegendIcon)&&(!x||x==="inherit"))_.add(t.getLegendIcon({itemWidth:f,itemHeight:d,icon:c,iconRotate:y,itemStyle:S.itemStyle,lineStyle:S.lineStyle,symbolKeepAspect:m}));else{var w=x==="inherit"&&t.getData().getVisual("symbol")?y==="inherit"?t.getData().getVisual("symbolRotate"):y:0;_.add(ep({itemWidth:f,itemHeight:d,icon:c,iconRotate:w,itemStyle:S.itemStyle,symbolKeepAspect:m}))}var M=s==="left"?f+5:-5,T=s,L=o.get("formatter"),D=r;E(L)&&L?D=L.replace("{name}",r??""):F(L)&&(D=L(r));var V=g?b.getTextColor():a.get("inactiveColor");_.add(new $({style:it(b,{text:D,x:M,y:d/2,fill:V,align:T,verticalAlign:"middle"},{inheritColor:V})}));var P=new nt({shape:_.getBoundingRect(),style:{fill:"transparent"}}),z=a.getModel("tooltip");return z.get("show")&&we({el:P,componentModel:o,itemName:r,itemTooltipOption:z.option}),_.add(P),_.eachChild(function(N){N.silent=!0}),P.silent=!h,this.getContentGroup().add(_),re(_),_.__legendDataIndex=i,_},e.prototype.layoutInner=function(t,r,i,a,o,s){var l=this.getContentGroup(),u=this.getSelectorGroup();Ft(t.get("orient"),l,t.get("itemGap"),i.width,i.height);var c=l.getBoundingRect(),h=[-c.x,-c.y];if(u.markRedraw(),l.markRedraw(),o){Ft("horizontal",u,t.get("selectorItemGap",!0));var v=u.getBoundingRect(),p=[-v.x,-v.y],f=t.get("selectorButtonGap",!0),d=t.getOrient().index,g=d===0?"width":"height",y=d===0?"height":"width",m=d===0?"y":"x";s==="end"?p[d]+=c[g]+f:h[d]+=v[g]+f,p[1-d]+=c[y]/2-v[y]/2,u.x=p[0],u.y=p[1],l.x=h[0],l.y=h[1];var x={x:0,y:0};return x[g]=c[g]+f+v[g],x[y]=Math.max(c[y],v[y]),x[m]=Math.min(0,v[m]+p[1-d]),x}else return l.x=h[0],l.y=h[1],this.group.getBoundingRect()},e.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},e.type="legend.plain",e})(at);function tp(n,e,t,r,i,a,o){function s(g,y){g.lineWidth==="auto"&&(g.lineWidth=y.lineWidth>0?2:0),fn(g,function(m,x){g[x]==="inherit"&&(g[x]=y[x])})}var l=e.getModel("itemStyle"),u=l.getItemStyle(),c=n.lastIndexOf("empty",0)===0?"fill":"stroke",h=l.getShallow("decal");u.decal=!h||h==="inherit"?r.decal:Nl(h,o),u.fill==="inherit"&&(u.fill=r[i]),u.stroke==="inherit"&&(u.stroke=r[c]),u.opacity==="inherit"&&(u.opacity=(i==="fill"?r:t).opacity),s(u,r);var v=e.getModel("lineStyle"),p=v.getLineStyle();if(s(p,t),u.fill==="auto"&&(u.fill=r.fill),u.stroke==="auto"&&(u.stroke=r.fill),p.stroke==="auto"&&(p.stroke=r.fill),!a){var f=e.get("inactiveBorderWidth"),d=u[c];u.lineWidth=f==="auto"?r.lineWidth>0&&d?2:0:u.lineWidth,u.fill=e.get("inactiveColor"),u.stroke=e.get("inactiveBorderColor"),p.stroke=v.get("inactiveColor"),p.lineWidth=v.get("inactiveWidth")}return{itemStyle:u,lineStyle:p}}function ep(n){var e=n.icon||"roundRect",t=Xt(e,0,0,n.itemWidth,n.itemHeight,n.itemStyle.fill,n.symbolKeepAspect);return t.setStyle(n.itemStyle),t.rotation=(n.iconRotate||0)*Math.PI/180,t.setOrigin([n.itemWidth/2,n.itemHeight/2]),e.indexOf("empty")>-1&&(t.style.stroke=t.style.fill,t.style.fill=A.color.neutral00,t.style.lineWidth=2),t}function Ha(n,e,t,r){gn(n,e,t,r),t.dispatchAction({type:"legendToggleSelect",name:n??e}),dn(n,e,t,r)}function dn(n,e,t,r){t.usingTHL()||t.dispatchAction({type:"highlight",seriesName:n,name:e,excludeSeriesId:r})}function gn(n,e,t,r){t.usingTHL()||t.dispatchAction({type:"downplay",seriesName:n,name:e,excludeSeriesId:r})}function fe(n,e,t){var r=n==="allSelect"||n==="inverseSelect",i={},a=[];t.eachComponent({mainType:"legend",query:e},function(s){r?s[n]():s[n](e.name),Wa(s,i),a.push(s.componentIndex)});var o={};return t.eachComponent("legend",function(s){C(i,function(l,u){s[l?"select":"unSelect"](u)}),Wa(s,o)}),r?{selected:o,legendIndex:a}:{name:e.name,selected:o}}function Wa(n,e){var t=e||{};return C(n.getData(),function(r){var i=r.get("name");if(!(i===` `||i==="")){var a=n.isSelected(i);ie(t,i)?t[i]=t[i]&&a:t[i]=a}}),t}function rp(n){n.registerAction("legendToggleSelect","legendselectchanged",G(fe,"toggleSelected")),n.registerAction("legendAllSelect","legendselectall",G(fe,"allSelect")),n.registerAction("legendInverseSelect","legendinverseselect",G(fe,"inverseSelect")),n.registerAction("legendSelect","legendselected",G(fe,"select")),n.registerAction("legendUnSelect","legendunselected",G(fe,"unSelect"))}var np=Dn(ip);function ip(n){var e=n.findComponents({mainType:"legend"});e&&e.length&&n.filterSeries(function(t){for(var r=0;ri[o],g=[-p.x,-p.y];r||(g[a]=c[u]);var y=[0,0],m=[-f.x,-f.y],x=U(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(d){var S=t.get("pageButtonPosition",!0);S==="end"?m[a]+=i[o]-f[o]:y[a]+=f[o]+x}m[1-a]+=p[s]/2-f[s]/2,c.setPosition(g),h.setPosition(y),v.setPosition(m);var _={x:0,y:0};if(_[o]=d?i[o]:p[o],_[s]=Math.max(p[s],f[s]),_[l]=Math.min(0,f[l]+m[1-a]),h.__rectSize=i[o],d){var b={x:0,y:0};b[o]=Math.max(i[o]-f[o]-x,0),b[s]=_[s],h.setClipPath(new nt({shape:b})),h.__rectSize=b[o]}else v.eachChild(function(M){M.attr({invisible:!0,silent:!0})});var w=this._getPageInfo(t);return w.pageIndex!=null&&fr(c,{x:w.contentPosition[0],y:w.contentPosition[1]},d?t:null),this._updatePageInfoView(t,w),_},e.prototype._pageGo=function(t,r,i){var a=this._getPageInfo(r)[t];a!=null&&i.dispatchAction({type:"legendScroll",scrollDataIndex:a,legendId:r.id})},e.prototype._updatePageInfoView=function(t,r){var i=this._controllerGroup;C(["pagePrev","pageNext"],function(c){var h=c+"DataIndex",v=r[h]!=null,p=i.childOfName(c);p&&(p.setStyle("fill",v?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),p.cursor=v?"pointer":"default")});var a=i.childOfName("pageText"),o=t.get("pageFormatter"),s=r.pageIndex,l=s!=null?s+1:0,u=r.pageCount;a&&o&&a.setStyle("text",E(o)?o.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):o({current:l,total:u}))},e.prototype._getPageInfo=function(t){var r=t.get("scrollDataIndex",!0),i=this.getContentGroup(),a=this._containerGroup.__rectSize,o=t.getOrient().index,s=Er[o],l=Nr[o],u=this._findTargetItemIndex(r),c=i.children(),h=c[u],v=c.length,p=v?1:0,f={contentPosition:[i.x,i.y],pageCount:p,pageIndex:p-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!h)return f;var d=S(h);f.contentPosition[o]=-d.s;for(var g=u+1,y=d,m=d,x=null;g<=v;++g)x=S(c[g]),(!x&&m.e>y.s+a||x&&!_(x,y.s))&&(m.i>y.i?y=m:y=x,y&&(f.pageNextDataIndex==null&&(f.pageNextDataIndex=y.i),++f.pageCount)),m=x;for(var g=u-1,y=d,m=d,x=null;g>=-1;--g)x=S(c[g]),(!x||!_(m,x.s))&&y.i=w&&b.s<=w+a}},e.prototype._findTargetItemIndex=function(t){if(!this._showController)return 0;var r,i=this.getContentGroup(),a;return i.eachChild(function(o,s){var l=o.__legendDataIndex;a==null&&l!=null&&(a=s),l===t&&(r=s)}),r??a},e.type="legend.scroll",e})(Cs);function sp(n){n.registerAction("legendScroll","legendscroll",function(e,t){var r=e.scrollDataIndex;r!=null&&t.eachComponent({mainType:"legend",subType:"scroll",query:e},function(i){i.setScrollDataIndex(r)})})}function lp(n){ft(Ts),n.registerComponentModel(ap),n.registerComponentView(op),sp(n)}function Vf(n){ft(Ts),ft(lp)}var up=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.inside",e.defaultOption=se(xe.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e})(xe),Jn=ht();function cp(n,e,t){Jn(n).coordSysRecordMap.each(function(r){var i=r.dataZoomInfoMap.get(e.uid);i&&(i.getRange=t)})}function hp(n,e){for(var t=Jn(n).coordSysRecordMap,r=t.keys(),i=0;ia[i+r]&&(r=h),o=o&&c.get("preventDefaultMouseMove",!0),s=U(c.get("cursorGrab",!0),s),l=U(c.get("cursorGrabbing",!0),l)}),{controlType:r,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!o,api:t,zInfo:{component:e.model},triggerInfo:{roamTrigger:null,isInSelf:e.containsPoint},cursorGrab:s,cursorGrabbing:l}}}function gp(n){n.registerUpdateLifecycle("coordsys:aftercreate",function(e,t){var r=Jn(t),i=r.coordSysRecordMap||(r.coordSysRecordMap=J());i.each(function(a){a.dataZoomInfoMap=null}),e.eachComponent({mainType:"dataZoom",subType:"inside"},function(a){var o=ss(a);C(o.infoList,function(s){var l=s.model.uid,u=i.get(l)||i.set(l,vp(t,s.model)),c=u.dataZoomInfoMap||(u.dataZoomInfoMap=J());c.set(a.uid,{dzReferCoordSysInfo:s,model:a,getRange:null})})}),i.each(function(a){var o=a.controller,s,l=a.dataZoomInfoMap;if(l){var u=l.keys()[0];u!=null&&(s=l.get(u))}if(!s){As(i,a);return}var c=dp(l,a,t);o.enable(c.controlType,c.opt),be(a,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var yp=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type="dataZoom.inside",t}return e.prototype.render=function(t,r,i){if(n.prototype.render.apply(this,arguments),t.noTarget()){this._clear();return}this.range=t.getPercentRange(),cp(i,t,{pan:O(Gr.pan,this),zoom:O(Gr.zoom,this),scrollMove:O(Gr.scrollMove,this)})},e.prototype.dispose=function(){this._clear(),n.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){hp(this.api,this.dataZoomModel),this.range=null},e.type="dataZoom.inside",e})(Fn),Gr={zoom:function(n,e,t,r){var i=this.range,a=i.slice(),o=n.axisModels[0];if(o){var s=Hr[e](null,[r.originX,r.originY],o,t,n),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(a[1]-a[0])+a[0],u=Math.max(1/r.scale,0);a[0]=(a[0]-l)*u+l,a[1]=(a[1]-l)*u+l;var c=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(Kt(0,a,[0,100],0,c.minSpan,c.maxSpan),this.range=a,i[0]!==a[0]||i[1]!==a[1])return a}},pan:$a(function(n,e,t,r,i,a){var o=Hr[r]([a.oldX,a.oldY],[a.newX,a.newY],e,i,t);return o.signal*(n[1]-n[0])*o.pixel/o.pixelLength}),scrollMove:$a(function(n,e,t,r,i,a){var o=Hr[r]([0,0],[a.scrollDelta,a.scrollDelta],e,i,t);return o.signal*(n[1]-n[0])*a.scrollDelta})};function $a(n){return function(e,t,r,i){var a=this.range,o=a.slice(),s=e.axisModels[0];if(s){var l=n(o,s,e,t,r,i);if(Kt(l,o,[0,100],"all"),this.range=o,a[0]!==o[0]||a[1]!==o[1])return o}}}var Hr={grid:function(n,e,t,r,i){var a=t.axis,o={},s=i.model.coordinateSystem.getRect();return n=n||[0,0],a.dim==="x"?(o.pixel=e[0]-n[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=a.inverse?1:-1):(o.pixel=e[1]-n[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=a.inverse?-1:1),o},polar:function(n,e,t,r,i){var a=t.axis,o={},s=i.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return n=n?s.pointToCoord(n):[0,0],e=s.pointToCoord(e),t.mainType==="radiusAxis"?(o.pixel=e[0]-n[0],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=a.inverse?1:-1):(o.pixel=e[1]-n[1],o.pixelLength=u[1]-u[0],o.pixelStart=u[0],o.signal=a.inverse?-1:1),o},singleAxis:function(n,e,t,r,i){var a=t.axis,o=i.model.coordinateSystem.getRect(),s={};return n=n||[0,0],a.orient==="horizontal"?(s.pixel=e[0]-n[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=a.inverse?1:-1):(s.pixel=e[1]-n[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=a.inverse?-1:1),s}};function mp(n){$n(n),n.registerComponentModel(up),n.registerComponentView(yp),gp(n)}var xp=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.slider",e.layoutMode="box",e.defaultOption=se(xe.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:A.color.accent10,borderRadius:0,backgroundColor:A.color.transparent,dataBackground:{lineStyle:{color:A.color.accent30,width:.5},areaStyle:{color:A.color.accent20,opacity:.2}},selectedDataBackground:{lineStyle:{color:A.color.accent40,width:.5},areaStyle:{color:A.color.accent20,opacity:.3}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:A.color.neutral00,borderColor:A.color.accent20},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:A.color.accent40,opacity:.5},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:A.color.tertiary},brushSelect:!0,brushStyle:{color:A.color.accent30,opacity:.3},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:A.color.accent40},moveHandleStyle:{opacity:.8}},defaultLocationEdgeGap:15}),e})(xe),de=nt,Sp=1,Wr=30,_p=7,ge="horizontal",Ya="vertical",bp=5,wp=["line","bar","candlestick","scatter"],Cp={easing:"cubicOut",duration:100,delay:0},Tp=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t._displayables={},t}return e.prototype.init=function(t,r){this.api=r,this._onBrush=O(this._onBrush,this),this._onBrushEnd=O(this._onBrushEnd,this)},e.prototype.render=function(t,r,i,a){if(n.prototype.render.apply(this,arguments),be(this,"_dispatchZoomAction",t.get("throttle"),"fixRate"),this._orient=t.getOrient(),t.get("show")===!1){this.group.removeAll();return}if(t.noTarget()){this._clear(),this.group.removeAll();return}(!a||a.type!=="dataZoom"||a.from!==this.uid)&&this._buildView(),this._updateView()},e.prototype.dispose=function(){this._clear(),n.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){Xe(this,"_dispatchZoomAction");var t=this.api.getZr();t.off("mousemove",this._onBrush),t.off("mouseup",this._onBrushEnd)},e.prototype._buildView=function(){var t=this.group;t.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var r=this._displayables.sliderGroup=new ot;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(r),this._positionGroup()},e.prototype._resetLocation=function(){var t=this.dataZoomModel,r=this.api,i=t.get("brushSelect"),a=i?_p:0,o=Pt(t,r).refContainer,s=this._findCoordRect(),l=t.get("defaultLocationEdgeGap",!0)||0,u=this._orient===ge?{right:o.width-s.x-s.width,top:o.height-Wr-l-a,width:s.width,height:Wr}:{right:l,top:s.y,width:Wr,height:s.height},c=wn(t.option);C(["right","top","width","height"],function(v){c[v]==="ph"&&(c[v]=u[v])});var h=dt(c,o);this._location={x:h.x,y:h.y},this._size=[h.width,h.height],this._orient===Ya&&this._size.reverse()},e.prototype._positionGroup=function(){var t=this.group,r=this._location,i=this._orient,a=this.dataZoomModel.getFirstTargetAxisModel(),o=a&&a.get("inverse"),s=this._displayables.sliderGroup,l=(this._dataShadowInfo||{}).otherAxisInverse;s.attr(i===ge&&!o?{scaleY:l?1:-1,scaleX:1}:i===ge&&o?{scaleY:l?1:-1,scaleX:-1}:i===Ya&&!o?{scaleY:l?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:l?-1:1,scaleX:-1,rotation:Math.PI/2});var u=t.getBoundingRect([s]),c=isNaN(u.x)?0:u.x,h=isNaN(u.y)?0:u.y;t.x=r.x-c,t.y=r.y-h,t.markRedraw()},e.prototype._getViewExtent=function(){return[0,this._size[0]]},e.prototype._renderBackground=function(){var t=this.dataZoomModel,r=this._size,i=this._displayables.sliderGroup,a=t.get("brushSelect");i.add(new de({silent:!0,shape:{x:0,y:0,width:r[0],height:r[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var o=new de({shape:{x:0,y:0,width:r[0],height:r[1]},style:{fill:"transparent"},z2:0,onclick:O(this._onClickPanel,this)}),s=this.api.getZr();a?(o.on("mousedown",this._onBrushStart,this),o.cursor="crosshair",s.on("mousemove",this._onBrush),s.on("mouseup",this._onBrushEnd)):(s.off("mousemove",this._onBrush),s.off("mouseup",this._onBrushEnd)),i.add(o)},e.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!t)return;var r=this._size,i=this._shadowSize||[],a=t.series,o=a.getRawData(),s=a.getShadowDim&&a.getShadowDim(),l=s&&o.getDimensionInfo(s)?a.getShadowDim():t.otherDim;if(l==null)return;var u=this._shadowPolygonPts,c=this._shadowPolylinePts;if(o!==this._shadowData||l!==this._shadowDim||r[0]!==i[0]||r[1]!==i[1]){var h=o.getDataExtent(t.thisDim),v=o.getDataExtent(l),p=(v[1]-v[0])*.3;v=[v[0]-p,v[1]+p];var f=[0,r[1]],d=[0,r[0]],g=[[r[0],0],[0,0]],y=[],m=d[1]/Math.max(1,o.count()-1),x=r[0]/(h[1]-h[0]),S=t.thisAxis.type==="time",_=-m,b=Math.round(o.count()/r[0]),w;o.each([t.thisDim,l],function(V,P,z){if(b>0&&z%b){S||(_+=m);return}_=S?(+V-h[0])*x:_+m;var N=P==null||isNaN(P)||P==="",H=N?0:K(P,v,f,!0);N&&!w&&z?(g.push([g[g.length-1][0],0]),y.push([y[y.length-1][0],0])):!N&&w&&(g.push([_,0]),y.push([_,0])),N||(g.push([_,H]),y.push([_,H])),w=N}),u=this._shadowPolygonPts=g,c=this._shadowPolylinePts=y}this._shadowData=o,this._shadowDim=l,this._shadowSize=[r[0],r[1]];var M=this.dataZoomModel;function T(V){var P=M.getModel(V?"selectedDataBackground":"dataBackground"),z=new ot,N=new tr({shape:{points:u},segmentIgnoreThreshold:1,style:P.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),H=new Co({shape:{points:c},segmentIgnoreThreshold:1,style:P.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return z.add(N),z.add(H),z}for(var L=0;L<3;L++){var D=T(L===1);this._displayables.sliderGroup.add(D),this._displayables.dataShadowSegs.push(D)}},e.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,r=t.get("showDataShadow");if(r!==!1){var i,a=this.ecModel;return t.eachTargetAxis(function(o,s){var l=t.getAxisProxy(o,s).getTargetSeriesModels();C(l,function(u){if(!i&&!(r!==!0&&pt(wp,u.get("type"))<0)){var c=a.getComponent(zt(o),s).axis,h=Ap(o),v,p=u.coordinateSystem;h!=null&&p.getOtherAxis&&(v=p.getOtherAxis(c).inverse),h=u.getData().mapDimension(h);var f=u.getData().mapDimension(o);i={thisAxis:c,series:u,thisDim:f,otherDim:h,otherAxisInverse:v}}},this)},this),i}},e.prototype._renderHandle=function(){var t=this.group,r=this._displayables,i=r.handles=[null,null],a=r.handleLabels=[null,null],o=this._displayables.sliderGroup,s=this._size,l=this.dataZoomModel,u=this.api,c=l.get("borderRadius")||0,h=l.get("brushSelect"),v=r.filler=new de({silent:h,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});o.add(v),o.add(new de({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:s[0],height:s[1],r:c},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:Sp,fill:A.color.transparent}})),C([0,1],function(x){var S=l.get("handleIcon");!Gl[S]&&S.indexOf("path://")<0&&S.indexOf("image://")<0&&(S="path://"+S);var _=Xt(S,-1,0,2,2,null,!0);_.attr({cursor:Mp(this._orient),draggable:!0,drift:O(this._onDragMove,this,x),ondragend:O(this._onDragEnd,this),onmouseover:O(this._onOverDataInfoTriggerArea,this,!0),onmouseout:O(this._onOverDataInfoTriggerArea,this,!1),z2:5});var b=_.getBoundingRect(),w=l.get("handleSize");this._handleHeight=X(w,this._size[1]),this._handleWidth=b.width/b.height*this._handleHeight,_.setStyle(l.getModel("handleStyle").getItemStyle()),_.style.strokeNoScale=!0,_.rectHover=!0,_.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),re(_);var M=l.get("handleColor");M!=null&&(_.style.fill=M),o.add(i[x]=_);var T=l.getModel("textStyle"),L=l.get("handleLabel")||{},D=L.show||!1;t.add(a[x]=new $({silent:!0,invisible:!D,style:it(T,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:T.getTextColor(),font:T.getFont()}),z2:10}))},this);var p=v;if(h){var f=X(l.get("moveHandleSize"),s[1]),d=r.moveHandle=new nt({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:s[1]-.5,height:f}}),g=f*.8,y=r.moveHandleIcon=Xt(l.get("moveHandleIcon"),-g/2,-g/2,g,g,A.color.neutral00,!0);y.silent=!0,y.y=s[1]+f/2-.5,d.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var m=Math.min(s[1]/2,Math.max(f,10));p=r.moveZone=new nt({invisible:!0,shape:{y:s[1]-m,height:f+m}}),p.on("mouseover",function(){u.enterEmphasis(d)}).on("mouseout",function(){u.leaveEmphasis(d)}),o.add(d),o.add(y),o.add(p)}p.attr({draggable:!0,cursor:"grab",drift:O(this._onActualMoveZoneDrift,this),ondragstart:O(this._onActualMoveZoneDragStart,this),ondragend:O(this._onActualMoveZoneDragEnd,this),onmouseover:O(this._onOverDataInfoTriggerArea,this,!0),onmouseout:O(this._onOverDataInfoTriggerArea,this,!1)})},e.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),r=this._getViewExtent();this._handleEnds=[K(t[0],[0,100],r,!0),K(t[1],[0,100],r,!0)]},e.prototype._updateInterval=function(t,r){var i=this.dataZoomModel,a=this._handleEnds,o=this._getViewExtent(),s=i.findRepresentativeAxisProxy().getMinMaxSpan(),l=[0,100];Kt(r,a,o,i.get("zoomLock")?"all":t,s.minSpan!=null?K(s.minSpan,l,o,!0):null,s.maxSpan!=null?K(s.maxSpan,l,o,!0):null);var u=this._range,c=this._range=xt([K(a[0],o,l,!0),K(a[1],o,l,!0)]);return!u||u[0]!==c[0]||u[1]!==c[1]},e.prototype._updateView=function(t){var r=this._displayables,i=this._handleEnds,a=xt(i.slice()),o=this._size;C([0,1],function(p){var f=r.handles[p],d=this._handleHeight;f.attr({scaleX:d/2,scaleY:d/2,x:i[p]+(p?-1:1),y:o[1]/2-d/2})},this),r.filler.setShape({x:a[0],y:0,width:a[1]-a[0],height:o[1]});var s={x:a[0],width:a[1]-a[0]};r.moveHandle&&(r.moveHandle.setShape(s),r.moveZone.setShape(s),r.moveZone.getBoundingRect(),r.moveHandleIcon&&r.moveHandleIcon.attr("x",s.x+s.width/2));for(var l=r.dataShadowSegs,u=[0,a[0],a[1],o[0]],c=0;cr[0]||i[1]<0||i[1]>r[1])){var a=this._handleEnds,o=(a[0]+a[1])/2,s=this._updateInterval("all",i[0]-o);this._updateView(),s&&this._dispatchZoomAction(!1)}},e.prototype._onBrushStart=function(t){var r=t.offsetX,i=t.offsetY;this._brushStart=new yt(r,i),this._brushing=!0,this._brushStartTime=+new Date},e.prototype._onBrushEnd=function(t){if(this._brushing){var r=this._displayables.brushRect;if(this._brushing=!1,!!r){r.attr("ignore",!0);var i=r.shape,a=+new Date;if(!(a-this._brushStartTime<200&&Math.abs(i.width)<5)){var o=this._getViewExtent(),s=[0,100],l=this._handleEnds=[i.x,i.x+i.width],u=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();Kt(0,l,o,0,u.minSpan!=null?K(u.minSpan,s,o,!0):null,u.maxSpan!=null?K(u.maxSpan,s,o,!0):null),this._range=xt([K(l[0],o,s,!0),K(l[1],o,s,!0)]),this._updateView(),this._dispatchZoomAction(!1)}}}},e.prototype._onBrush=function(t){this._brushing&&(ne(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},e.prototype._updateBrushRect=function(t,r){var i=this._displayables,a=this.dataZoomModel,o=i.brushRect;o||(o=i.brushRect=new de({silent:!0,style:a.getModel("brushStyle").getItemStyle()}),i.sliderGroup.add(o)),o.attr("ignore",!1);var s=this._brushStart,l=this._displayables.sliderGroup,u=l.transformCoordToLocal(t,r),c=l.transformCoordToLocal(s.x,s.y),h=this._size;u[0]=Math.max(Math.min(h[0],u[0]),0),o.setShape({x:c[0],y:0,width:u[0]-c[0],height:h[1]})},e.prototype._dispatchZoomAction=function(t){var r=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?Cp:null,start:r[0],end:r[1]})},e.prototype._findCoordRect=function(){var t,r=ss(this.dataZoomModel).infoList;if(!t&&r.length){var i=r[0].model.coordinateSystem;t=i.getRect&&i.getRect()}if(!t){var a=this.api.getWidth(),o=this.api.getHeight();t={x:a*.2,y:o*.2,width:a*.6,height:o*.6}}return t},e.type="dataZoom.slider",e})(Fn);function Ua(n,e,t,r){var i=n.get("labelFormatter"),a=n.get("labelPrecision");(a==null||a==="auto")&&(a=t.valuePrecision);var o=t.value[e],s=o==null||isNaN(o)?"":Io(r)||Do(r)?r.getLabel({value:Math.round(o)}):isFinite(a)?qe(o,a,!0):o+"";return F(i)?i(o,s):E(i)?i.replace("{value}",s):s}function Ap(n){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[n]}function Mp(n){return n==="vertical"?"ns-resize":"ew-resize"}function Ip(n){n.registerComponentModel(xp),n.registerComponentView(Tp),$n(n)}function Bf(n){ft(mp),ft(Ip)}var Ms={get:function(n,e,t){var r=W((Dp[n]||{})[e]);return t&&R(r)?r[r.length-1]:r}},Dp={color:{active:["#006edd","#e0ffff"],inactive:[A.color.transparent]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}},Xa=ct.mapVisual,Lp=ct.eachVisual,Pp=R,Zr=C,kp=xt,Op=K,cr=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.stateList=["inRange","outOfRange"],t.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],t.layoutMode={type:"box",ignoreSize:!0},t.dataBound=[-1/0,1/0],t.targetVisuals={},t.controllerVisuals={},t}return e.prototype.init=function(t,r,i){this.mergeDefaultAndTheme(t,i)},e.prototype.optionUpdated=function(t,r){var i=this.option;!r&&xs(i,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},e.prototype.resetVisual=function(t){var r=this.stateList;t=O(t,this),this.controllerVisuals=cn(this.option.controller,r,t),this.targetVisuals=cn(this.option.target,r,t)},e.prototype.getItemSymbol=function(){return null},e.prototype.getTargetSeriesIndices=function(){var t=this,r=this.option.seriesTargets;if(r){var i=[];return Zr(r,function(l){if(l.seriesIndex!=null)i.push(l.seriesIndex);else if(l.seriesId!=null){var u;t.ecModel.eachSeries(function(c){c.id===l.seriesId&&(u=c)}),u&&i.push(u.componentIndex)}}),i}var a=this.option.seriesId,o=this.option.seriesIndex;o==null&&a==null&&(o="all");var s=zo(this.ecModel,"series",{index:o,id:a},{useDefault:!1,enableAll:!0,enableNone:!1}).models;return B(s,function(l){return l.componentIndex})},e.prototype.eachTargetSeries=function(t,r){C(this.getTargetSeriesIndices(),function(i){var a=this.ecModel.getSeriesByIndex(i);a&&t.call(r,a)},this)},e.prototype.isTargetSeries=function(t){var r=!1;return this.eachTargetSeries(function(i){i===t&&(r=!0)}),r},e.prototype.formatValueText=function(t,r,i){var a=this.option,o=a.precision,s=this.dataBound,l=a.formatter,u;i=i||["<",">"],R(t)&&(t=t.slice(),u=!0);var c=r?t:u?[h(t[0]),h(t[1])]:h(t);if(E(l))return l.replace("{value}",u?c[0]:c).replace("{value2}",u?c[1]:c);if(F(l))return u?l(t[0],t[1]):l(t);if(u)return t[0]===s[0]?i[0]+" "+c[1]:t[1]===s[1]?i[1]+" "+c[0]:c[0]+" - "+c[1];return c;function h(v){return v===s[0]?"min":v===s[1]?"max":(+v).toFixed(Math.min(o,20))}},e.prototype.resetExtent=function(){var t=this.option,r=kp([t.min,t.max]);this._dataExtent=r},e.prototype.getDimension=function(t){var r=this,i=this.option.seriesTargets;if(i){var a=$s(i,function(o){return o.seriesIndex!=null&&o.seriesIndex===t||o.seriesId!=null&&o.seriesId===r.ecModel.getSeriesByIndex(t).id});if(a)return a.dimension}return this.option.dimension},e.prototype.getDataDimensionIndex=function(t){var r=t.hostModel.seriesIndex,i=this.getDimension(r);if(i!=null)return t.getDimensionIndex(i);for(var a=t.dimensions,o=a.length-1;o>=0;o--){var s=a[o],l=t.getDimensionInfo(s);if(!l.isCalculationCoord)return l.storeDimIndex}},e.prototype.getExtent=function(){return this._dataExtent.slice()},e.prototype.completeVisualOption=function(){var t=this.ecModel,r=this.option,i={inRange:r.inRange,outOfRange:r.outOfRange},a=r.target||(r.target={}),o=r.controller||(r.controller={});Q(a,i),Q(o,i);var s=this.isCategory();l.call(this,a),l.call(this,o),u.call(this,a,"inRange","outOfRange"),c.call(this,o);function l(h){Pp(r.color)&&!h.inRange&&(h.inRange={color:r.color.slice().reverse()}),h.inRange=h.inRange||{color:t.get("gradientColor")}}function u(h,v,p){var f=h[v],d=h[p];f&&!d&&(d=h[p]={},Zr(f,function(g,y){if(ct.isValidType(y)){var m=Ms.get(y,"inactive",s);m!=null&&(d[y]=m,y==="color"&&!d.hasOwnProperty("opacity")&&!d.hasOwnProperty("colorAlpha")&&(d.opacity=[0,0]))}}))}function c(h){var v=(h.inRange||{}).symbol||(h.outOfRange||{}).symbol,p=(h.inRange||{}).symbolSize||(h.outOfRange||{}).symbolSize,f=this.get("inactiveColor"),d=this.getItemSymbol(),g=d||"roundRect";Zr(this.stateList,function(y){var m=this.itemSize,x=h[y];x||(x=h[y]={color:s?f:[f]}),x.symbol==null&&(x.symbol=v&&W(v)||(s?g:[g])),x.symbolSize==null&&(x.symbolSize=p&&W(p)||(s?m[0]:[m[0],m[0]])),x.symbol=Xa(x.symbol,function(b){return b==="none"?g:b});var S=x.symbolSize;if(S!=null){var _=-1/0;Lp(S,function(b){b>_&&(_=b)}),x.symbolSize=Xa(S,function(b){return Op(b,[0,_],[0,m[0]],!0)})}},this)}},e.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},e.prototype.isCategory=function(){return!!this.option.categories},e.prototype.setSelected=function(t){},e.prototype.getSelected=function(){return null},e.prototype.getValueState=function(t){return null},e.prototype.getVisualMeta=function(t){return null},e.type="visualMap",e.dependencies=["series"],e.defaultOption={show:!0,z:4,min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:A.color.transparent,borderColor:A.color.borderTint,contentColor:A.color.theme[0],inactiveColor:A.color.disabled,borderWidth:0,padding:A.size.m,textGap:10,precision:0,textStyle:{color:A.color.secondary}},e})(tt),Ka=[20,140],Rp=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(t,r){n.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(i){i.mappingMethod="linear",i.dataExtent=this.getExtent()}),this._resetRange()},e.prototype.resetItemSize=function(){n.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;(t[0]==null||isNaN(t[0]))&&(t[0]=Ka[0]),(t[1]==null||isNaN(t[1]))&&(t[1]=Ka[1])},e.prototype._resetRange=function(){var t=this.getExtent(),r=this.option.range;!r||r.auto?(t.auto=1,this.option.range=t):R(r)&&(r[0]>r[1]&&r.reverse(),r[0]=Math.max(r[0],t[0]),r[1]=Math.min(r[1],t[1]))},e.prototype.completeVisualOption=function(){n.prototype.completeVisualOption.apply(this,arguments),C(this.stateList,function(t){var r=this.option.controller[t].symbolSize;r&&r[0]!==r[1]&&(r[0]=r[1]/3)},this)},e.prototype.setSelected=function(t){this.option.range=t.slice(),this._resetRange()},e.prototype.getSelected=function(){var t=this.getExtent(),r=xt((this.get("range")||[]).slice());return r[0]>t[1]&&(r[0]=t[1]),r[1]>t[1]&&(r[1]=t[1]),r[0]=i[1]||t<=r[1])?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var r=[];return this.eachTargetSeries(function(i){var a=[],o=i.getData();o.each(this.getDataDimensionIndex(o),function(s,l){t[0]<=s&&s<=t[1]&&a.push(l)},this),r.push({seriesId:i.id,dataIndex:a})},this),r},e.prototype.getVisualMeta=function(t){var r=qa(this,"outOfRange",this.getExtent()),i=qa(this,"inRange",this.option.range.slice()),a=[];function o(p,f){a.push({value:p,color:t(p,f)})}for(var s=0,l=0,u=i.length,c=r.length;lt[1])break;a.push({color:this.getControllerVisual(l,"color",r),offset:s/i})}return a.push({color:this.getControllerVisual(t[1],"color",r),offset:1}),a},e.prototype._createBarPoints=function(t,r){var i=this.visualMapModel.itemSize;return[[i[0]-r[0],t[0]],[i[0],t[0]],[i[0],t[1]],[i[0]-r[1],t[1]]]},e.prototype._createBarGroup=function(t){var r=this._orient,i=this.visualMapModel.get("inverse");return new ot(r==="horizontal"&&!i?{scaleX:t==="bottom"?1:-1,rotation:Math.PI/2}:r==="horizontal"&&i?{scaleX:t==="bottom"?-1:1,rotation:-Math.PI/2}:r==="vertical"&&!i?{scaleX:t==="left"?1:-1,scaleY:-1}:{scaleX:t==="left"?1:-1})},e.prototype._updateHandle=function(t,r){if(this._useHandle){var i=this._shapes,a=this.visualMapModel,o=i.handleThumbs,s=i.handleLabels,l=a.itemSize,u=a.getExtent(),c=this._applyTransform("left",i.mainGroup);zp([0,1],function(h){var v=o[h];v.setStyle("fill",r.handlesColor[h]),v.y=t[h];var p=bt(t[h],[0,l[1]],u,!0),f=this.getControllerVisual(p,"symbolSize");v.scaleX=v.scaleY=f/l[0],v.x=l[0]-f/2;var d=Vt(i.handleLabelPoints[h],He(v,this.group));if(this._orient==="horizontal"){var g=c==="left"||c==="top"?(l[0]-f)/2:(l[0]-f)/-2;d[1]+=g}s[h].setStyle({x:d[0],y:d[1],text:a.formatValueText(this._dataInterval[h]),verticalAlign:"middle",align:this._orient==="vertical"?this._applyTransform("left",i.mainGroup):"center"})},this)}},e.prototype._showIndicator=function(t,r,i,a){var o=this.visualMapModel,s=o.getExtent(),l=o.itemSize,u=[0,l[1]],c=this._shapes,h=c.indicator;if(h){h.attr("invisible",!1);var v={convertOpacityToAlpha:!0},p=this.getControllerVisual(t,"color",v),f=this.getControllerVisual(t,"symbolSize"),d=bt(t,s,u,!0),g=l[0]-f/2,y={x:h.x,y:h.y};h.y=d,h.x=g;var m=Vt(c.indicatorLabelPoint,He(h,this.group)),x=c.indicatorLabel;x.attr("invisible",!1);var S=this._applyTransform("left",c.mainGroup),_=this._orient,b=_==="horizontal";x.setStyle({text:(i||"")+o.formatValueText(r),verticalAlign:b?S:"middle",align:b?"center":S});var w={x:g,y:d,style:{fill:p}},M={style:{x:m[0],y:m[1]}};if(o.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var T={duration:100,easing:"cubicInOut",additive:!0};h.x=y.x,h.y=y.y,h.animateTo(w,T),x.animateTo(M,T)}else h.attr(w),x.attr(M);this._firstShowIndicator=!1;var L=this._shapes.handleLabels;if(L)for(var D=0;Do[1]&&(h[1]=1/0),r&&(h[0]===-1/0?this._showIndicator(c,h[1],"< ",l):h[1]===1/0?this._showIndicator(c,h[0],"> ",l):this._showIndicator(c,c,"≈ ",l));var v=this._hoverLinkDataIndices,p=[];(r||to(i))&&(p=this._hoverLinkDataIndices=i.findTargetDataIndices(h));var f=Zl(v,p);this._dispatchHighDown("downplay",$e(f[0],i)),this._dispatchHighDown("highlight",$e(f[1],i))}},e.prototype._hoverLinkFromSeriesMouseOver=function(t){var r;if(Ro(t.target,function(l){var u=Y(l);if(u.dataIndex!=null)return r=u,!0},!0),!!r){var i=this.ecModel.getSeriesByIndex(r.seriesIndex),a=this.visualMapModel;if(a.isTargetSeries(i)){var o=i.getData(r.dataType),s=o.getStore().get(a.getDataDimensionIndex(o),r.dataIndex);isNaN(s)||this._showIndicator(s,s)}}},e.prototype._hideIndicator=function(){var t=this._shapes;t.indicator&&t.indicator.attr("invisible",!0),t.indicatorLabel&&t.indicatorLabel.attr("invisible",!0);var r=this._shapes.handleLabels;if(r)for(var i=0;i=0&&(a.dimension=o,r.push(a))}}),n.getData().setVisual("visualMeta",r)}}];function Zp(n,e,t,r){for(var i=e.targetVisuals[r],a=ct.prepareVisualTypes(i),o={color:gr(n.getData(),"color")},s=0,l=a.length;s0:e.splitNumber>0)||e.calculable)?"continuous":"piecewise"}),n.registerAction(Gp,Hp),C(Wp,function(e){n.registerVisual(n.PRIORITY.VISUAL.COMPONENT,e)}),n.registerPreprocessor(Fp))}function $p(n){n.registerComponentModel(Rp),n.registerComponentView(Ep),Ls(n)}var Yp=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t._pieceList=[],t}return e.prototype.optionUpdated=function(t,r){n.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var i=this._mode=this._determineMode();this._pieceList=[],Up[this._mode].call(this,this._pieceList),this._resetSelected(t,r);var a=this.option.categories;this.resetVisual(function(o,s){i==="categories"?(o.mappingMethod="category",o.categories=W(a)):(o.dataExtent=this.getExtent(),o.mappingMethod="piecewise",o.pieceList=B(this._pieceList,function(l){return l=W(l),s!=="inRange"&&(l.visual=null),l}))})},e.prototype.completeVisualOption=function(){var t=this.option,r={},i=ct.listVisualTypes(),a=this.isCategory();C(t.pieces,function(s){C(i,function(l){s.hasOwnProperty(l)&&(r[l]=1)})}),C(r,function(s,l){var u=!1;C(this.stateList,function(c){u=u||o(t,c,l)||o(t.target,c,l)},this),!u&&C(this.stateList,function(c){(t[c]||(t[c]={}))[l]=Ms.get(l,c==="inRange"?"active":"inactive",a)})},this);function o(s,l,u){return s&&s[l]&&s[l].hasOwnProperty(u)}n.prototype.completeVisualOption.apply(this,arguments)},e.prototype._resetSelected=function(t,r){var i=this.option,a=this._pieceList,o=(r?i:t).selected||{};if(i.selected=o,C(a,function(l,u){var c=this.getSelectedMapKey(l);o.hasOwnProperty(c)||(o[c]=!0)},this),i.selectedMode==="single"){var s=!1;C(a,function(l,u){var c=this.getSelectedMapKey(l);o[c]&&(s?o[c]=!1:s=!0)},this)}},e.prototype.getItemSymbol=function(){return this.get("itemSymbol")},e.prototype.getSelectedMapKey=function(t){return this._mode==="categories"?t.value+"":t.index+""},e.prototype.getPieceList=function(){return this._pieceList},e.prototype._determineMode=function(){var t=this.option;return t.pieces&&t.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},e.prototype.setSelected=function(t){this.option.selected=W(t)},e.prototype.getValueState=function(t){var r=ct.findPieceIndex(t,this._pieceList);return r!=null&&this.option.selected[this.getSelectedMapKey(this._pieceList[r])]?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var r=[],i=this._pieceList;return this.eachTargetSeries(function(a){var o=[],s=a.getData();s.each(this.getDataDimensionIndex(s),function(l,u){var c=ct.findPieceIndex(l,i);c===t&&o.push(u)},this),r.push({seriesId:a.id,dataIndex:o})},this),r},e.prototype.getRepresentValue=function(t){var r;if(this.isCategory())r=t.value;else if(t.value!=null)r=t.value;else{var i=t.interval||[];r=i[0]===-1/0&&i[1]===1/0?0:(i[0]+i[1])/2}return r},e.prototype.getVisualMeta=function(t){if(this.isCategory())return;var r=[],i=["",""],a=this;function o(c,h){var v=a.getRepresentValue({interval:c});h||(h=a.getValueState(v));var p=t(v,h);c[0]===-1/0?i[0]=p:c[1]===1/0?i[1]=p:r.push({value:c[0],color:p},{value:c[1],color:p})}var s=this._pieceList.slice();if(!s.length)s.push({interval:[-1/0,1/0]});else{var l=s[0].interval[0];l!==-1/0&&s.unshift({interval:[-1/0,l]}),l=s[s.length-1].interval[1],l!==1/0&&s.push({interval:[l,1/0]})}var u=-1/0;return C(s,function(c){var h=c.interval;h&&(h[0]>u&&o([u,h[0]],"outOfRange"),o(h.slice()),u=h[1])},this),{stops:r,outerColors:i}},e.type="visualMap.piecewise",e.defaultOption=se(cr.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieces:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0}),e})(cr),Up={splitNumber:function(n){var e=this.option,t=Math.min(e.precision,20),r=this.getExtent(),i=e.splitNumber;i=Math.max(parseInt(i,10),1),e.splitNumber=i;for(var a=(r[1]-r[0])/i;+a.toFixed(t)!==a&&t<5;)t++;e.precision=t,a=+a.toFixed(t),e.minOpen&&n.push({interval:[-1/0,r[0]],close:[0,0]});for(var o=0,s=r[0];o","≥"][r[0]]];t.text=t.text||this.formatValueText(t.value!=null?t.value:t.interval,!1,i)},this)}};function io(n,e){var t=n.inverse;(n.orient==="vertical"?!t:t)&&e.reverse()}var Xp=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.doRender=function(){var t=this.group;t.removeAll();var r=this.visualMapModel,i=r.get("textGap"),a=r.textStyleModel,o=this._getItemAlign(),s=r.itemSize,l=this._getViewData(),u=l.endsText,c=Zt(r.get("showLabel",!0),!u),h=!r.get("selectedMode");u&&this._renderEndsText(t,u[0],s,c,o),C(l.viewPieceList,function(v){var p=v.piece,f=new ot;f.onclick=O(this._onItemClick,this,p),this._enableHoverLink(f,v.indexInModelPieceList);var d=r.getRepresentValue(p);if(this._createItemSymbol(f,d,[0,0,s[0],s[1]],h),c){var g=this.visualMapModel.getValueState(d),y=a.get("align")||o;f.add(new $({style:it(a,{x:y==="right"?-i:s[0]+i,y:s[1]/2,text:p.text,verticalAlign:a.get("verticalAlign")||"middle",align:y,opacity:U(a.get("opacity"),g==="outOfRange"?.5:1)}),silent:h}))}t.add(f)},this),u&&this._renderEndsText(t,u[1],s,c,o),Ft(r.get("orient"),t,r.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},e.prototype._enableHoverLink=function(t,r){var i=this;t.on("mouseover",function(){return a("highlight")}).on("mouseout",function(){return a("downplay")});var a=function(o){var s=i.visualMapModel;s.option.hoverLink&&i.api.dispatchAction({type:o,batch:$e(s.findTargetDataIndices(r),s)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,r=t.option;if(r.orient==="vertical")return Ds(t,this.api,t.itemSize);var i=r.align;return(!i||i==="auto")&&(i="left"),i},e.prototype._renderEndsText=function(t,r,i,a,o){if(r){var s=new ot,l=this.visualMapModel.textStyleModel;s.add(new $({style:it(l,{x:a?o==="right"?i[0]:0:i[0]/2,y:i[1]/2,verticalAlign:"middle",align:a?o:"center",text:r})})),t.add(s)}},e.prototype._getViewData=function(){var t=this.visualMapModel,r=B(t.getPieceList(),function(s,l){return{piece:s,indexInModelPieceList:l}}),i=t.get("text"),a=t.get("orient"),o=t.get("inverse");return(a==="horizontal"?o:!o)?r.reverse():i&&(i=i.slice().reverse()),{viewPieceList:r,endsText:i}},e.prototype._createItemSymbol=function(t,r,i,a){var o=Xt(this.getControllerVisual(r,"symbol"),i[0],i[1],i[2],i[3],this.getControllerVisual(r,"color"));o.silent=a,t.add(o)},e.prototype._onItemClick=function(t){var r=this.visualMapModel,i=r.option,a=i.selectedMode;if(a){var o=W(i.selected),s=r.getSelectedMapKey(t);a==="single"||a===!0?(o[s]=!0,C(o,function(l,u){o[u]=u===s})):o[s]=!o[s],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:o})}},e.type="visualMap.piecewise",e})(Is);function Kp(n){n.registerComponentModel(Yp),n.registerComponentView(Xp),Ls(n)}function Ef(n){ft($p),ft(Kp)}var qp=(function(){function n(e){this._thumbnailModel=e}return n.prototype.reset=function(e){this._renderVersion=e.getECUpdateCycleVersion()},n.prototype.renderContent=function(e){var t=e.api.getViewOfComponentModel(this._thumbnailModel);t&&(e.group.silent=!0,t.renderContent({group:e.group,targetTrans:e.targetTrans,z2Range:Fl(e.group),roamType:e.roamType,viewportRect:e.viewportRect,renderVersion:this._renderVersion}))},n.prototype.updateWindow=function(e,t){var r=t.getViewOfComponentModel(this._thumbnailModel);r&&r.updateWindow({targetTrans:e,renderVersion:this._renderVersion})},n})(),jp=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.preventAutoZ=!0,t}return e.prototype.optionUpdated=function(t,r){this._updateBridge()},e.prototype._updateBridge=function(){var t=this._birdge=this._birdge||new qp(this);if(this._target=null,this.ecModel.eachSeries(function(i){mi(i,null)}),this.shouldShow()){var r=this.getTarget();mi(r.baseMapProvider,t)}},e.prototype.shouldShow=function(){return this.getShallow("show",!0)},e.prototype.getBridge=function(){return this._birdge},e.prototype.getTarget=function(){if(this._target)return this._target;var t=this.getReferringComponents("series",{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];return t?t.subType!=="graph"&&(t=null):t=this.ecModel.queryComponents({mainType:"series",subType:"graph"})[0],this._target={baseMapProvider:t},this._target},e.type="thumbnail",e.layoutMode="box",e.dependencies=["series","geo"],e.defaultOption={show:!0,right:1,bottom:1,height:"25%",width:"25%",itemStyle:{borderColor:A.color.border,borderWidth:2},windowStyle:{borderWidth:1,color:A.color.neutral30,borderColor:A.color.neutral40,opacity:.3},z:10},e})(tt),Jp=(function(n){I(e,n);function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,i){if(this._api=i,this._model=t,this._coordSys||(this._coordSys=new Su),!this._isEnabled()){this._clear();return}this._renderVersion=i.getECUpdateCycleVersion();var a=this.group;a.removeAll();var o=t.getModel("itemStyle"),s=o.getItemStyle();s.fill==null&&(s.fill=r.get("backgroundColor")||A.color.neutral00);var l=Pt(t,i).refContainer,u=dt($l(t,!0),l),c=s.lineWidth||0,h=this._contentRect=Tn(u.clone(),c/2,!0,!0),v=new ot;a.add(v),v.setClipPath(new nt({shape:h.plain()}));var p=this._targetGroup=new ot;v.add(p);var f=u.plain();f.r=o.getShallow("borderRadius",!0),a.add(this._bgRect=new nt({style:s,shape:f,silent:!1,cursor:"grab"}));var d=t.getModel("windowStyle"),g=d.getShallow("borderRadius",!0);v.add(this._windowRect=new nt({shape:{x:0,y:0,width:0,height:0,r:g},style:d.getItemStyle(),silent:!1,cursor:"grab"})),this._dealRenderContent(),this._dealUpdateWindow(),oo(t,this)},e.prototype.renderContent=function(t){this._bridgeRendered=t,this._isEnabled()&&(this._dealRenderContent(),this._dealUpdateWindow(),oo(this._model,this))},e.prototype._dealRenderContent=function(){var t=this._bridgeRendered;if(!(!t||t.renderVersion!==this._renderVersion)){var r=this._targetGroup,i=this._coordSys,a=this._contentRect;if(r.removeAll(),!!t){var o=t.group,s=o.getBoundingRect();r.add(o),this._bgRect.z2=t.z2Range.min-10,_u(i,s.x,s.y,s.width,s.height);var l=dt({left:"center",top:"center",aspect:s.width/s.height},a);bu(i,l.x,l.y,l.width,l.height),wu(o,i,Cu),o.dirty(),this._windowRect.z2=t.z2Range.max+10,this._resetRoamController(t.roamType)}}},e.prototype.updateWindow=function(t){var r=this._bridgeRendered;r&&r.renderVersion===t.renderVersion&&(r.targetTrans=t.targetTrans),this._isEnabled()&&this._dealUpdateWindow()},e.prototype._dealUpdateWindow=function(){var t=this._bridgeRendered;if(!(!t||t.renderVersion!==this._renderVersion)){var r=$r([],t.targetTrans),i=Ys([],Zo(null,this._coordSys),r);this._transThisToTarget=$r([],i);var a=t.viewportRect;a?a=a.clone():a=new Lt(0,0,this._api.getWidth(),this._api.getHeight()),a.applyTransform(i);var o=this._windowRect,s=o.shape.r;o.setShape(j({r:s},a))}},e.prototype._resetRoamController=function(t){var r=this,i=this._api,a=this._roamController;if(a||(a=this._roamController=new $o(i.getZr())),!t||!this._isEnabled()){a.disable();return}a.enable(t,{api:i,zInfo:{component:this._model},triggerInfo:{roamTrigger:null,isInSelf:function(o,s,l){return r._contentRect.contain(s,l)}}}),a.off("pan").off("zoom").on("pan",O(this._onPan,this)).on("zoom",O(this._onZoom,this))},e.prototype._onPan=function(t){var r=this._transThisToTarget;if(!(!this._isEnabled()||!r)){var i=xr([],[t.oldX,t.oldY],r),a=xr([],[t.oldX-t.dx,t.oldY-t.dy],r);this._api.dispatchAction(ao(this._model.getTarget().baseMapProvider,{dx:a[0]-i[0],dy:a[1]-i[1]}))}},e.prototype._onZoom=function(t){var r=this._transThisToTarget;if(!(!this._isEnabled()||!r)){var i=xr([],[t.originX,t.originY],r);this._api.dispatchAction(ao(this._model.getTarget().baseMapProvider,{zoom:1/t.scale,originX:i[0],originY:i[1]}))}},e.prototype._isEnabled=function(){var t=this._model;if(!t||!t.shouldShow())return!1;var r=t.getTarget().baseMapProvider;return!!r},e.prototype._clear=function(){this.group.removeAll(),this._bridgeRendered=null,this._roamController&&this._roamController.disable()},e.prototype.remove=function(){this._clear()},e.prototype.dispose=function(){this._clear()},e.type="thumbnail",e})(at);function ao(n,e){var t=n.mainType==="series"?n.subType+"Roam":n.mainType+"Roam",r={type:t};return r[n.mainType+"Id"]=n.id,Z(r,e),r}function oo(n,e){var t=No(n);Go(e.group,t.z,t.zlevel)}function Nf(n){n.registerComponentModel(jp),n.registerComponentView(Jp)}var Qp={label:{enabled:!0},decal:{show:!1}},so=ht(),lo=ht(),tf=Dn(ef);function ef(n,e){var t=n.getModel("aria");if(!t.get("enabled"))return;var r=lo(n).scope||(lo(n).scope={}),i=W(Qp);Q(i.label,n.getLocaleModel().get("aria"),!1),Q(t.option,i,!1),a(),o();function a(){var c=t.getModel("decal"),h=c.get("show");if(h){var v=J();n.eachSeries(function(p){p.isColorBySeries()||(so(p).scope=v.get(p.type)||v.set(p.type,{}))}),n.eachSeries(function(p){if(F(p.enableAriaDecal)){p.enableAriaDecal();return}var f=p.getData();if(p.isColorBySeries()){var x=fi(p.ecModel,p.name,r,n.getSeriesCount()),S=f.getVisual("decal");f.setVisual("decal",_(S,x))}else{var d=p.getRawData(),g={},y=so(p).scope;f.each(function(b){var w=f.getRawIndex(b);g[w]=b});var m=d.count();d.each(function(b){var w=g[b],M=d.getName(b)||b+"",T=fi(p.ecModel,M,y,m),L=f.getItemVisual(w,"decal");f.setItemVisual(w,"decal",_(L,T))})}function _(b,w){var M=b?Z(Z({},w),b):w;return M.dirty=!0,M}})}}function o(){var c=e.getZr().dom;if(c){var h=n.getLocaleModel().get("aria"),v=t.getModel("label");if(v.option=j(v.option,h),!!v.get("enabled")){if(c.setAttribute("role","img"),v.get("description")){c.setAttribute("aria-label",v.get("description"));return}var p=n.getSeriesCount(),f=v.get(["data","maxCount"])||10,d=v.get(["series","maxCount"])||10,g=Math.min(p,d),y;if(!(p<1)){var m=l();if(m){var x=v.get(["general","withTitle"]);y=s(x,{title:m})}else y=v.get(["general","withoutTitle"]);var S=[],_=p>1?v.get(["series","multiple","prefix"]):v.get(["series","single","prefix"]);y+=s(_,{seriesCount:p}),n.eachSeries(function(T,L){if(L1?v.get(["series","multiple",P]):v.get(["series","single",P]),D=s(D,{seriesId:T.seriesIndex,seriesName:T.get("name"),seriesType:u(T.subType)});var z=T.getData();if(z.count()>f){var N=v.get(["data","partialData"]);D+=s(N,{displayCnt:f})}else D+=v.get(["data","allData"]);for(var H=v.get(["data","separator","middle"]),St=v.get(["data","separator","end"]),kt=v.get(["data","excludeDimensionId"]),ti=[],qt=0;qt":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},nf=(function(){function n(e){var t=this._condVal=E(e)?new RegExp(e):Xs(e)?e:null;if(t==null){var r="";q(r)}}return n.prototype.evaluate=function(e){var t=typeof e;return E(t)?this._condVal.test(e):vr(t)?this._condVal.test(e+""):!1},n})(),af=(function(){function n(){}return n.prototype.evaluate=function(){return this.value},n})(),of=(function(){function n(){}return n.prototype.evaluate=function(){for(var e=this.children,t=0;t