@kubex/zinc 1.1.32 → 1.1.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/dist/chunks/zn.4YKYUIHS.js +3 -0
  2. package/dist/chunks/zn.6RARZYEJ.js +22 -0
  3. package/dist/chunks/zn.7VCR5ZZL.js +1 -0
  4. package/dist/chunks/zn.AI3T35DX.js +1 -0
  5. package/dist/chunks/zn.CU5HCKLN.js +1 -0
  6. package/dist/chunks/zn.EHO4QQOL.js +1 -0
  7. package/dist/chunks/zn.GBBMMHHG.js +8 -0
  8. package/dist/chunks/zn.GRJSS6IO.js +1 -0
  9. package/dist/chunks/zn.HPUEBV7K.js +1 -0
  10. package/dist/chunks/zn.J2JOUV3V.js +8 -0
  11. package/dist/chunks/zn.NKUIXDNI.js +1 -0
  12. package/dist/chunks/zn.S4ZVBYAS.js +3 -0
  13. package/dist/chunks/zn.UBLZO6CI.js +1 -0
  14. package/dist/chunks/zn.XO7QERPZ.js +716 -0
  15. package/dist/chunks/zn.ZGI3WHSG.js +4 -0
  16. package/dist/custom-elements.json +134 -75
  17. package/dist/vscode.html-custom-data.json +11 -11
  18. package/dist/web-types.json +23 -23
  19. package/dist/zn.d.ts +21 -0
  20. package/dist/zn.min.js +1309 -2041
  21. package/index.html +1 -1
  22. package/package.json +3 -3
  23. package/scripts/build.js +10 -5
  24. package/src/components/chart/chart.component.ts +20 -27
  25. package/src/components/chart/echarts-loader.ts +30 -0
  26. package/src/components/editor/modules/emoji/emoji-mart-loader.ts +28 -0
  27. package/src/components/editor/modules/emoji/emoji.ts +3 -9
  28. package/src/components/editor/modules/emoji/headless/headless-emoji.ts +2 -9
  29. package/src/components/icon/icon.component.ts +34 -2
  30. package/src/components/icon-picker/icon-picker.component.ts +35 -35
  31. package/src/components/settings-container/settings-container.scss +2 -2
  32. package/src/components/simple-chart/simple-chart.component.ts +15 -6
  33. package/src/zinc-autoloader.ts +0 -2
  34. package/tsconfig.json +2 -1
@@ -0,0 +1,22 @@
1
+ import{Aa as Ks,B as Sr,Ba as ko,C as Ls,D as zs,E as Os,F as Rt,G as Ps,H as ks,I as Oo,J as jc,K as gi,L as Rs,N as yi,P as Es,Q as Vs,R as Us,S as Ns,Y as Bs,f as bs,h as _r,j as ws,ja as $c,k as Cs,ka as mt,m as Ts,n as Gt,na as Hs,o as zo,pa as Po,q as Ms,qa as Et,r as As,ra as xi,sa as Gs,t as mi,ta as Fs,ua as Zs,v as qe,va as Jc,wa as _i,x as Ds,xa as Ws,y as Is,ya as Ys,za as Xs}from"./zn.4YKYUIHS.js";import{$ as Pa,$c as le,$e as ft,A as ba,Ab as ae,Ac as pt,Bb as vr,Cb as Ue,Cc as gt,Db as Kt,Dc as He,Ea as yo,Ec as os,Fa as xo,Fe as gs,G as go,Ga as Ba,Gc as Ge,Ge as di,Ha,Hc as Fe,He as vi,Ia as Qt,Ib as Qr,Ic as ns,J as wa,Ja as Ga,Jb as ja,Jc as Z,K as ut,Kb as ti,Kc as M,L as Gr,La as Fa,Le as Lo,M as Ca,Ma as Za,N as Ta,Nc as as,O as Ma,Ob as vt,Oc as bo,Od as We,Oe as ys,P as ye,Pb as Ne,Q as Aa,Qa as Wa,Qb as $a,Qe as gr,R as Da,Rb as nt,Rc as mr,S as Ia,Sa as qr,Sc as wo,Se as yr,T as La,Ta as Ya,Tb as Ja,Tc as Ze,Te as xs,U as Q,Ua as _e,Uc as ni,V as Fr,Va as jr,Vc as ss,Ve as be,W as za,Wa as Lt,Wc as ls,We as _s,X as Mt,Y as Oa,Yb as at,Ye as xr,Z as Zr,Za as Xa,Zb as Qa,Zc as us,_b as Ot,_c as Co,_d as vs,_e as Ss,a as T,ac as _o,ad as To,af as Xe,be as Ht,c as dt,ca as Nt,cb as ne,cd as ai,d as ct,da as Wr,dc as ts,dd as si,e as dr,ea as Re,fe as ui,g as ya,ga as Yr,gd as X,ge as ms,gf as Ke,h as xa,ha as Xr,hb as k,hc as ei,he as Do,hf as kt,i as mo,ia as ka,ib as Tt,ic as se,j as lt,jc as es,k as J,kc as ri,kd as qt,ke as pi,l as _a,la as Ra,ld as Se,ma as Ee,md as Mo,me as ci,n as ge,nb as Ka,nd as ue,oa as j,oc as Be,od as Ao,p as yt,pc as So,q as Sa,qb as zt,qd as li,re as Io,sb as qa,sd as ps,t as Hr,ta as Va,tc as ii,td as cs,ua as Ua,ub as Ve,uc as oi,ud as Pt,ue as fi,va as Na,vb as At,vd as fs,ve as Ye,wb as $r,wc as rs,wd as hs,xb as Jr,xc as Bt,xd as ds,yc as is,ze as hi}from"./zn.GBBMMHHG.js";import{$ as fo,$a as ma,Aa as me,B as oe,Ba as Pe,C as ot,Da as fr,E as cr,Ga as wt,Gb as ke,H as la,I as Yt,Ib as hr,J as It,K as W,Ka as va,Kb as et,Na as Ct,P as ua,R as q,Sb as Ea,U as Xt,V as ze,a as ht,bc as Kr,eb as vo,ec as xe,fb as ga,fc as rt,g as U,h as tt,i as na,ic as F,j as N,k as K,ka as Br,l as st,n as ie,o as aa,p as S,pa,q as R,qa as ca,ra as fa,s as St,sa as ha,t as sa,ta as ho,u as Nr,ua as Jt,v as O,w as H,wa as Oe,x as I,y as G,z as E,za as da}from"./zn.J2JOUV3V.js";import"./zn.UBLZO6CI.js";var we=Q(),qs=U,Ro=O,tf=(function(){function i(){this._dragging=!1,this.animationThreshold=15}return i.prototype.render=function(e,t,r,o){var n=t.get("value"),a=t.get("status");if(this._axisModel=e,this._axisPointerModel=t,this._api=r,!(!o&&this._lastValue===n&&this._lastStatus===a)){this._lastValue=n,this._lastStatus=a;var s=this._group,l=this._handle;if(!a||a==="hide"){s&&s.hide(),l&&l.hide();return}s&&s.show(),l&&l.show();var u={};this.makeElOption(u,n,e,t,r);var p=u.graphicKey;p!==this._lastGraphicKey&&this.clear(r),this._lastGraphicKey=p;var c=this._moveAnimation=this.determineAnimation(e,t);if(!s)s=this._group=new et,this.createPointerEl(s,u,e,t),this.createLabelEl(s,u,e,t),r.getZr().add(s);else{var f=H(js,t,c);this.updatePointerEl(s,u,f),this.updateLabelEl(s,u,f,t)}Js(s,t,!0),this._renderHandle(n)}},i.prototype.remove=function(e){this.clear(e)},i.prototype.dispose=function(e){this.clear(e)},i.prototype.determineAnimation=function(e,t){var r=t.get("animation"),o=e.axis,n=o.type==="category",a=t.get("snap");if(!a&&!n)return!1;if(r==="auto"||r==null){var s=this.animationThreshold;if(n&&Ke(o).w>s)return!0;if(a){var l=zs(e).seriesDataCount,u=o.getExtent();return Math.abs(u[0]-u[1])/l>s}return!1}return r===!0},i.prototype.makeElOption=function(e,t,r,o,n){},i.prototype.createPointerEl=function(e,t,r,o){var n=t.pointer;if(n){var a=we(e).pointerEl=new vt[n.type](qs(t.pointer));e.add(a)}},i.prototype.createLabelEl=function(e,t,r,o){if(t.label){var n=we(e).labelEl=new F(qs(t.label));e.add(n),$s(n,o)}},i.prototype.updatePointerEl=function(e,t,r){var o=we(e).pointerEl;o&&t.pointer&&(o.setStyle(t.pointer.style),r(o,{shape:t.pointer.shape}))},i.prototype.updateLabelEl=function(e,t,r,o){var n=we(e).labelEl;n&&(n.setStyle(t.label.style),r(n,{x:t.label.x,y:t.label.y}),$s(n,o))},i.prototype._renderHandle=function(e){if(!(this._dragging||!this.updateHandleTransform)){var t=this._axisPointerModel,r=this._api.getZr(),o=this._handle,n=t.getModel("handle"),a=t.get("status");if(!n.get("show")||!a||a==="hide"){o&&r.remove(o),this._handle=null;return}var s;this._handle||(s=!0,o=this._handle=ae(n.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){Jt(u.event)},onmousedown:Ro(this._onHandleDragMove,this,0,0),drift:Ro(this._onHandleDragMove,this),ondragend:Ro(this._onHandleDragEnd,this)}),r.add(o)),Js(o,t,!1),o.setStyle(n.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=n.get("size");I(l)||(l=[l,l]),o.scaleX=l[0]/2,o.scaleY=l[1]/2,qt(this,"_doDispatchAxisPointer",n.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,s)}},i.prototype._moveHandleToValue=function(e,t){js(this._axisPointerModel,!t&&this._moveAnimation,this._handle,Eo(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},i.prototype._onHandleDragMove=function(e,t){var r=this._handle;if(r){this._dragging=!0;var o=this.updateHandleTransform(Eo(r),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=o,r.stopAnimation(),r.attr(Eo(o)),we(r).lastProp=null,this._doDispatchAxisPointer()}},i.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}]})}},i.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"})}},i.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),r=this._group,o=this._handle;t&&r&&(this._lastGraphicKey=null,r&&t.remove(r),o&&t.remove(o),this._group=null,this._handle=null,this._payloadInfo=null),Se(this,"_doDispatchAxisPointer")},i.prototype.doClear=function(){},i.prototype.buildLabel=function(e,t,r){return r=r||0,{x:e[r],y:e[1-r],width:t[r],height:t[1-r]}},i})();function js(i,e,t,r){tl(we(t).lastProp,r)||(we(t).lastProp=r,e?ne(t,r,i):(t.stopAnimation(),t.attr(r)))}function tl(i,e){if(ot(i)&&ot(e)){var t=!0;return S(e,function(r,o){t=t&&tl(i[o],r)}),!!t}else return i===e}function $s(i,e){i[e.get(["label","show"])?"show":"hide"]()}function Eo(i){return{x:i.x||0,y:i.y||0,rotation:i.rotation||0}}function Js(i,e,t){var r=e.get("z"),o=e.get("zlevel");i&&i.traverse(function(n){n.type!=="group"&&(r!=null&&(n.z=r),o!=null&&(n.zlevel=o),n.silent=t)})}var je=tf;function $e(i){var e=i.get("type"),t=i.getModel(e+"Style"),r;return e==="line"?(r=t.getLineStyle(),r.fill=null):e==="shadow"&&(r=t.getAreaStyle(),r.stroke=null),r}function No(i,e,t,r,o){var n=t.get("value"),a=Bo(n,e.axis,e.ecModel,t.get("seriesDataIndices"),{precision:t.get(["label","precision"]),formatter:t.get(["label","formatter"])}),s=t.getModel("label"),l=se(s.get("padding")||0),u=s.getFont(),p=ke(a,u),c=o.position,f=p.width+l[1]+l[3],h=p.height+l[0]+l[2],d=o.align;d==="right"&&(c[0]-=f),d==="center"&&(c[0]-=f/2);var v=o.verticalAlign;v==="bottom"&&(c[1]-=h),v==="middle"&&(c[1]-=h/2),ef(c,f,h,r);var m=s.get("backgroundColor");(!m||m==="auto")&&(m=e.get(["axisLine","lineStyle","color"])),i.label={x:c[0],y:c[1],style:nt(s,{text:a,font:u,fill:s.getTextColor(),padding:l,backgroundColor:m}),z2:10}}function ef(i,e,t,r){var o=r.getWidth(),n=r.getHeight();i[0]=Math.min(i[0]+e,o)-e,i[1]=Math.min(i[1]+t,n)-t,i[0]=Math.max(i[0],0),i[1]=Math.max(i[1],0)}function Bo(i,e,t,r,o){i=e.scale.parse(i);var n=e.scale.getLabel({value:i},{precision:o.precision}),a=o.formatter;if(a){var s={value:hi(e,{value:i}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};S(r,function(l){var u=t.getSeriesByIndex(l.seriesIndex),p=l.dataIndexInside,c=u&&u.getDataParams(p);c&&s.seriesData.push(c)}),E(a)?n=a.replace("{value}",n):G(a)&&(n=a(s))}return n}function br(i,e,t){var r=Oe();return Pe(r,r,t.rotation),me(r,r,t.position),At([i.dataToCoord(e),(t.labelOffset||0)+(t.labelDirection||1)*(t.labelMargin||0)],r)}function Si(i,e,t,r,o,n){var a=Gt.innerTextLayout(t.rotation,0,t.labelDirection);t.labelMargin=o.get(["label","margin"]),No(e,r,o,n,{position:br(r.axis,i,t),align:a.textAlign,verticalAlign:a.textVerticalAlign})}function Je(i,e,t){return t=t||0,{x1:i[t],y1:i[1-t],x2:e[t],y2:e[1-t]}}function bi(i,e,t){return t=t||0,{x:i[t],y:i[1-t],width:e[t],height:e[1-t]}}function Ho(i,e,t,r,o,n){return{cx:i,cy:e,r0:t,r,startAngle:o,endAngle:n,clockwise:!0}}function Qe(i,e,t){return Ke(i,{fromStat:{sers:R(e,function(r){return t.getSeriesByIndex(r.seriesIndex)})},min:1}).w}function tr(i,e,t){return[ct(dt(e[0],e[1]),i-t/2),dt(i+t/2,ct(e[0],e[1]))]}var rf=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,r,o,n,a){var s=o.axis,l=s.grid,u=n.get("type"),p=s.getGlobalExtent(),c=ol(l,s).getOtherAxis(s).getGlobalExtent(),f=s.toGlobalCoord(s.dataToCoord(r,!0));if(u&&u!=="none"){var h=$e(n),d=of[u](s,f,p,c,n.get("seriesDataIndices"),n.ecModel);d.style=h,t.graphicKey=d.type,t.pointer=d}var v=zo(l.getRect(),o);Si(r,t,v,o,n,a)},e.prototype.getHandleTransform=function(t,r,o){var n=zo(r.axis.grid.getRect(),r,{labelInside:!1});n.labelMargin=o.get(["handle","margin"]);var a=br(r.axis,t,n);return{x:a[0],y:a[1],rotation:n.rotation+(n.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,r,o,n){var a=o.axis,s=a.grid,l=a.getGlobalExtent(!0),u=ol(s,a).getOtherAxis(a).getGlobalExtent(),p=a.dim==="x"?0:1,c=[t.x,t.y];c[p]+=r[p],c[p]=dt(l[1],c[p]),c[p]=ct(l[0],c[p]);var f=(u[1]+u[0])/2,h=[f,f];h[p]=c[p];var d=[{verticalAlign:"middle"},{align:"center"}];return{x:c[0],y:c[1],rotation:t.rotation,cursorPoint:h,tooltipOption:d[p]}},e})(je);function ol(i,e){var t={};return t[e.dim+"AxisIndex"]=e.index,i.getCartesian(t)}var of={line:function(i,e,t,r){var o=Je([e,r[0]],[e,r[1]],nl(i));return{type:"Line",subPixelOptimize:!0,shape:o}},shadow:function(i,e,t,r,o,n){var a=Qe(i,o,n),s=r[1]-r[0],l=tr(e,t,a),u=l[0],p=l[1];return{type:"Rect",shape:bi([u,r[0]],[p-u,s],nl(i))}}};function nl(i){return i.dim==="x"?0:1}var al=rf;var nf=(function(i){T(e,i);function e(){var t=i!==null&&i.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:M.color.border,width:1,type:"dashed"},shadowStyle:{color:M.color.shadowTint},label:{show:!0,formatter:null,precision:"auto",margin:3,color:M.color.neutral00,padding:[5,7,5,7],backgroundColor:M.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:M.color.accent40,throttle:40}},e})(Z),sl=nf;var te=Q(),af=S;function Ci(i,e,t){if(!ht.node){var r=e.getZr();te(r).records||(te(r).records={}),sf(r,e);var o=te(r).records[i]||(te(r).records[i]={});o.handler=t}}function sf(i,e){if(te(i).initialized)return;te(i).initialized=!0,t("click",H(Go,"click")),t("mousemove",H(Go,"mousemove")),t("mousewheel",H(Go,"mousewheel")),t("globalout",uf);function t(r,o){i.on(r,function(n){var a=pf(e);af(te(i).records,function(s){s&&o(s,n,a.dispatchAction)}),lf(a.pendings,e)})}}function lf(i,e){var t=i.showTip.length,r=i.hideTip.length,o;t?o=i.showTip[t-1]:r&&(o=i.hideTip[r-1]),o&&(o.dispatchAction=null,e.dispatchAction(o))}function uf(i,e,t){i.handler("leave",null,t)}function Go(i,e,t,r){e.handler(i,t,r)}function pf(i){var e={showTip:[],hideTip:[]},t=function(r){var o=e[r.type];o?o.push(r):(r.dispatchAction=t,i.dispatchAction(r))};return{dispatchAction:t,pendings:e}}function wr(i,e){if(!ht.node){var t=e.getZr(),r=(te(t).records||{})[i];r&&(te(t).records[i]=null)}}var cf=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,o){var n=r.getComponent("tooltip"),a=t.get("triggerOn")||n&&n.get("triggerOn")||"mousemove|click|mousewheel";Ci("axisPointer",o,function(s,l,u){a!=="none"&&(s==="leave"||a.indexOf(s)>=0)&&u({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},e.prototype.remove=function(t,r){wr("axisPointer",r)},e.prototype.dispose=function(t,r){wr("axisPointer",r)},e.type="axisPointer",e})(X),ul=cf;function Cr(i,e){var t=[],r=i.seriesIndex,o;if(r==null||!(o=e.getSeriesByIndex(r)))return{point:[]};var n=o.getData(),a=La(n,i);if(a==null||a<0||I(a))return{point:[]};var s=n.getItemGraphicEl(a),l=o.coordinateSystem;if(o.getTooltipPosition)t=o.getTooltipPosition(a)||[];else if(l&&l.dataToPoint)if(i.isStacked){var u=l.getBaseAxis(),p=l.getOtherAxis(u),c=p.dim,f=u.dim,h=c==="x"||c==="radius"?1:0,d=n.mapDimension(f),v=[];v[h]=n.get(d,a),v[1-h]=n.get(n.getCalculationInfo("stackResultDimension"),a),t=l.dataToPoint(v)||[]}else t=l.dataToPoint(n.getValues(R(l.dimensions,function(g){return n.mapDimension(g)}),a))||[];else if(s){var m=s.getBoundingRect().clone();m.applyTransform(s.transform),t=[m.x+m.width/2,m.y+m.height/2]}return{point:t,el:s}}var pl=Q();function Fo(i,e,t){var r=i.currTrigger,o=[i.x,i.y],n=i,a=i.dispatchAction||O(t.dispatchAction,t),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){Mi(o)&&(o=Cr({seriesIndex:n.seriesIndex,dataIndex:n.dataIndex},e).point);var l=Mi(o),u=n.axesInfo,p=s.axesInfo,c=r==="leave"||Mi(o),f={},h={},d={list:[],map:{}},v={showPointer:H(hf,h),showTooltip:H(df,d)};S(s.coordSysMap,function(g,y){var x=l||g.containPoint(o);S(s.coordSysAxesInfo[y],function(_,b){var w=_.axis,C=yf(u,_);if(!c&&x&&(!u||C)){var D=C&&C.value;D==null&&!l&&(D=w.pointToData(o)),D!=null&&cl(_,D,v,!1,f)}})});var m={};return S(p,function(g,y){var x=g.linkGroup;x&&!h[y]&&S(x.axesInfo,function(_,b){var w=h[b];if(_!==g&&w){var C=w.value;x.mapper&&(C=g.axis.scale.parse(x.mapper(C,fl(_),fl(g)))),m[g.key]=C}})}),S(m,function(g,y){cl(p[y],g,v,!0,f)}),vf(h,p,f),mf(d,o,i,a),gf(p,a,t),f}}function cl(i,e,t,r,o){var n=i.axis;if(!(n.scale.isBlank()||!n.containData(e))){if(!i.involveSeries){t.showPointer(i,e);return}var a=ff(e,i),s=a.payloadBatch,l=a.snapToValue;s[0]&&o.seriesIndex==null&&N(o,s[0]),!r&&i.snap&&n.containData(l)&&l!=null&&(e=l),t.showPointer(i,e,s),t.showTooltip(i,a,l)}}function ff(i,e){var t=e.axis,r=t.dim,o=i,n=[],a=Number.MAX_VALUE,s=-1;return S(e.seriesModels,function(l,u){var p=l.getData().mapDimensionsAll(r),c,f;if(l.getAxisTooltipData){var h=l.getAxisTooltipData(p,i,t);f=h.dataIndices,c=h.nestestValue}else{if(f=l.indicesOfNearest(r,p[0],i,t.type==="category"?.5:null),!f.length)return;c=l.getData().get(p[0],f[0])}if(wa(c)){var d=i-c,v=Math.abs(d);v<=a&&((v<a||d>=0&&s<0)&&(a=v,s=d,o=c,n.length=0),S(f,function(m){n.push({seriesIndex:l.seriesIndex,dataIndexInside:m,dataIndex:l.getData().getRawIndex(m)})}))}}),{payloadBatch:n,snapToValue:o}}function hf(i,e,t,r){i[e.key]={value:t,payloadBatch:r}}function df(i,e,t,r){var o=t.payloadBatch,n=e.axis,a=n.model,s=e.axisPointerModel;if(!(!e.triggerTooltip||!o.length)){var l=e.coordSys.model,u=Os(l),p=i.map[u];p||(p=i.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},i.list.push(p)),p.dataByAxis.push({axisDim:n.dim,axisIndex:a.componentIndex,axisType:a.type,axisId:a.id,value:r,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:o.slice()})}}function vf(i,e,t){var r=t.axesInfo=[];S(e,function(o,n){var a=o.axisPointerModel.option,s=i[n];s?(!o.useHandle&&(a.status="show"),a.value=s.value,a.seriesDataIndices=(s.payloadBatch||[]).slice()):!o.useHandle&&(a.status="hide"),a.status==="show"&&r.push({axisDim:o.axis.dim,axisIndex:o.axis.model.componentIndex,value:a.value})})}function mf(i,e,t,r){if(Mi(e)||!i.list.length){r({type:"hideTip"});return}var o=((i.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};r({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:t.tooltipOption,position:t.position,dataIndexInside:o.dataIndexInside,dataIndex:o.dataIndex,seriesIndex:o.seriesIndex,dataByCoordSys:i.list})}function gf(i,e,t){var r=t.getZr(),o="axisPointerLastHighlights",n=pl(r)[o]||{},a=pl(r)[o]={};S(i,function(p,c){var f=p.axisPointerModel.option;f.status==="show"&&p.triggerEmphasis&&S(f.seriesDataIndices,function(h){a[h.seriesIndex+"|"+h.dataIndex]=h})});var s=[],l=[];function u(p){return{seriesIndex:p.seriesIndex,dataIndex:p.dataIndex}}S(n,function(p,c){!a[c]&&l.push(u(p))}),S(a,function(p,c){!n[c]&&s.push(u(p))}),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 yf(i,e){for(var t=0;t<(i||[]).length;t++){var r=i[t];if(e.axis.dim===r.axisDim&&e.axis.model.componentIndex===r.axisIndex)return r}}function fl(i){var e=i.axis.model,t={},r=t.axisDim=i.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 Mi(i){return!i||i[0]==null||isNaN(i[0])||i[1]==null||isNaN(i[1])}function ee(i){Rt.registerAxisPointerClass("CartesianAxisPointer",al),i.registerComponentModel(sl),i.registerComponentView(ul),i.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var t=e.axisPointer.link;t&&!I(t)&&(e.axisPointer.link=[t])}}),i.registerProcessor(i.PRIORITY.PROCESSOR.STATISTIC,{overallReset:function(e,t){e.getComponent("axisPointer").coordSysAxesInfo=Ls(e,t)}}),i.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},Fo)}function xf(i){ft(Oo),ft(ee)}var _f=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,r,o,n,a){var s=o.axis;s.dim==="angle"&&(this.animationThreshold=Math.PI/18);var l=s.polar,u=s.getExtent(),p=l.getOtherAxis(s).getExtent(),c=s.dataToCoord(r),f=n.get("type");if(f&&f!=="none"){var h=$e(n),d=bf[f](s,l,c,u,p,n.get("seriesDataIndices"),n.ecModel);d.style=h,t.graphicKey=d.type,t.pointer=d}var v=n.get(["label","margin"]),m=Sf(r,o,n,l,v);No(t,o,n,a,m)},e})(je);function Sf(i,e,t,r,o){var n=e.axis,a=n.dataToCoord(i),s=r.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l=r.getRadiusAxis().getExtent(),u,p,c;if(n.dim==="radius"){var f=Oe();Pe(f,f,s),me(f,f,[r.cx,r.cy]),u=At([a,-o],f);var h=e.getModel("axisLabel").get("rotate")||0,d=Gt.innerTextLayout(s,h*Math.PI/180,-1);p=d.textAlign,c=d.textVerticalAlign}else{var v=l[1];u=r.coordToPoint([v+o,a]);var m=r.cx,g=r.cy;p=Math.abs(u[0]-m)/v<.3?"center":u[0]>m?"left":"right",c=Math.abs(u[1]-g)/v<.3?"middle":u[1]>g?"top":"bottom"}return{position:u,align:p,verticalAlign:c}}var bf={line:function(i,e,t,r,o){return i.dim==="angle"?{type:"Line",shape:Je(e.coordToPoint([o[0],t]),e.coordToPoint([o[1],t]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:t}}},shadow:function(i,e,t,r,o,n,a){var s=Math.PI/180,l=Qe(i,n,a),u;if(i.dim==="angle")u=Ho(e.cx,e.cy,o[0],o[1],(-t-l/2)*s,(-t+l/2)*s);else{var p=tr(t,r,l),c=p[0],f=p[1];u=Ho(e.cx,e.cy,c,f,0,Math.PI*2)}return{type:"Sector",shape:u}}},hl=_f;var Dt="polar",Zo=Dt,wf=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.findAxisModel=function(t){var r,o=this.ecModel;return o.eachComponent(t,function(n){n.getCoordSysModel()===this&&(r=n)},this),r},e.type=Dt,e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e})(Z),dl=wf;var Wo=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",Mt).models[0]},e.type="polarAxis",e})(Z);ie(Wo,vi);var vl=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.type="angleAxis",e})(Wo);var ml=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.type="radiusAxis",e})(Wo);var Yo=(function(i){T(e,i);function e(t,r){return i.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})(kt);Yo.prototype.dataToRadius=kt.prototype.dataToCoord;Yo.prototype.radiusToData=kt.prototype.coordToData;var gl=Yo;var Cf=Q(),Xo=(function(i){T(e,i);function e(t,r){return i.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(),o=t.scale,n=o.getExtent(),a=o.count();if(n[1]-n[0]<1)return 0;var s=n[0],l=t.dataToCoord(s+1)-t.dataToCoord(s),u=Math.abs(l),p=ke(s==null?"":s+"",r.getFont(),"center","top"),c=Math.max(p.height,7),f=c/u;isNaN(f)&&(f=1/0);var h=Math.max(0,Math.floor(f)),d=Cf(t.model),v=d.lastAutoInterval,m=d.lastTickCount;return v!=null&&m!=null&&Math.abs(v-h)<=1&&Math.abs(m-a)<=1&&v>h?h=v:(d.lastTickCount=a,d.lastAutoInterval=h),h},e})(kt);Xo.prototype.dataToAngle=kt.prototype.dataToCoord;Xo.prototype.angleToData=kt.prototype.coordToData;var yl=Xo;var Ko=["radius","angle"],Tf=(function(){function i(e){this.dimensions=Ko,this.type=Dt,this.cx=0,this.cy=0,this._radiusAxis=new gl,this._angleAxis=new yl,this.axisPointerEnabled=!0,this.name=e||"",this._radiusAxis.polar=this._angleAxis.polar=this}return i.prototype.containPoint=function(e){var t=this.pointToCoord(e);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},i.prototype.containData=function(e){return this._radiusAxis.containData(e[0])&&this._angleAxis.containData(e[1])},i.prototype.getAxis=function(e){var t="_"+e+"Axis";return this[t]},i.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},i.prototype.getAxesByScale=function(e){var t=[],r=this._angleAxis,o=this._radiusAxis;return r.scale.type===e&&t.push(r),o.scale.type===e&&t.push(o),t},i.prototype.getAngleAxis=function(){return this._angleAxis},i.prototype.getRadiusAxis=function(){return this._radiusAxis},i.prototype.getOtherAxis=function(e){var t=this._angleAxis;return e===t?this._radiusAxis:t},i.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},i.prototype.getTooltipAxes=function(e){var t=e!=null&&e!=="auto"?this.getAxis(e):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},i.prototype.dataToPoint=function(e,t,r){return this.coordToPoint([this._radiusAxis.dataToRadius(e[0],t),this._angleAxis.dataToAngle(e[1],t)],r)},i.prototype.pointToData=function(e,t,r){r=r||[];var o=this.pointToCoord(e);return r[0]=this._radiusAxis.radiusToData(o[0],t),r[1]=this._angleAxis.angleToData(o[1],t),r},i.prototype.pointToCoord=function(e){var t=e[0]-this.cx,r=e[1]-this.cy,o=this.getAngleAxis(),n=o.getExtent(),a=Math.min(n[0],n[1]),s=Math.max(n[0],n[1]);o.inverse?a=s-360:s=a+360;var l=Math.sqrt(t*t+r*r);t/=l,r/=l;for(var u=Math.atan2(-r,t)/Math.PI*180,p=u<a?1:-1;u<a||u>s;)u+=p*360;return[l,u]},i.prototype.coordToPoint=function(e,t){t=t||[];var r=e[0],o=e[1]/180*Math.PI;return t[0]=Math.cos(o)*r+this.cx,t[1]=-Math.sin(o)*r+this.cy,t},i.prototype.getArea=function(){var e=this.getAngleAxis(),t=this.getRadiusAxis(),r=t.getExtent().slice();r[0]>r[1]&&r.reverse();var o=e.getExtent(),n=Math.PI/180,a=1e-4;return{cx:this.cx,cy:this.cy,r0:r[0],r:r[1],startAngle:-o[0]*n,endAngle:-o[1]*n,clockwise:e.inverse,contain:function(s,l){var u=s-this.cx,p=l-this.cy,c=u*u+p*p,f=this.r,h=this.r0;return f!==h&&c-a<=f*f&&c+a>=h*h},x:this.cx-r[1],y:this.cy-r[1],width:r[1]*2,height:r[1]*2}},i.prototype.convertToPixel=function(e,t,r){var o=xl(t);return o===this?this.dataToPoint(r):null},i.prototype.convertFromPixel=function(e,t,r){var o=xl(t);return o===this?this.pointToData(r):null},i})();function xl(i){var e=i.seriesModel,t=i.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}var _l=Tf;function Mf(i,e,t){var r=e.get("center"),o=gt(e,t).refContainer;i.cx=J(r[0],o.width)+o.x,i.cy=J(r[1],o.height)+o.y;var n=i.getRadiusAxis(),a=Math.min(o.width,o.height)/2,s=e.get("radius");s==null?s=[0,"100%"]:I(s)||(s=[0,s]);var l=[J(s[0],a),J(s[1],a)];n.inverse?n.setExtent(l[1],l[0]):n.setExtent(l[0],l[1])}function Af(i,e){var t=this,r=t.getAngleAxis(),o=t.getRadiusAxis();if(be(r,yr),be(o,yr),xr(r),xr(o),r.type==="category"&&!r.onBand){var n=r.getExtent(),a=360/r.scale.count();r.inverse?n[1]+=a:n[1]-=a,r.setExtent(n[0],n[1])}}function Df(i){return i.mainType==="angleAxis"}function Sl(i,e){var t;if(i.type=fi(e),i.scale=Ye(e,i.type,!1),i.onBand=di(i.scale,e),i.inverse=e.get("inverse"),Df(e)){i.inverse=i.inverse!==e.get("clockwise");var r=e.get("startAngle"),o=(t=e.get("endAngle"))!==null&&t!==void 0?t:r+(i.inverse?-360:360);i.setExtent(r,o)}e.axis=i,i.model=e}var If={dimensions:Ko,create:function(i,e){var t=[];return i.eachComponent(Zo,function(r,o){var n=new _l(o+"");n.update=Af;var a=n.getRadiusAxis(),s=n.getAngleAxis(),l=r.findAxisModel("radiusAxis"),u=r.findAxisModel("angleAxis");Sl(a,l),Sl(s,u),Mf(n,r,e),t.push(n),r.coordinateSystem=n,n.model=r}),i.eachSeries(function(r){if(r.get("coordinateSystem")===Dt){var o=r.getReferringComponents(Zo,Mt).models[0],n=r.coordinateSystem=o.coordinateSystem;n&&(gr(n.getRadiusAxis(),r,Dt),gr(n.getAngleAxis(),r,Dt))}}),t}},bl=If;var Lf=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function Ai(i,e,t){e[1]>e[0]&&(e=e.slice().reverse());var r=i.coordToPoint([e[0],t]),o=i.coordToPoint([e[1],t]);return{x1:r[0],y1:r[1],x2:o[0],y2:o[1]}}function Di(i){var e=i.getRadiusAxis();return e.inverse?0:1}function wl(i){var e=i[0],t=i[i.length-1];e&&t&&Math.abs(Math.abs(e.coord-t.coord)-360)<1e-4&&i.pop()}var zf=(function(i){T(e,i);function e(){var t=i!==null&&i.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 o=t.axis,n=o.polar,a=n.getRadiusAxis().getExtent(),s=o.getTicksCoords({breakTicks:"none"}),l=o.getMinorTicksCoords(),u=[];S(o.getViewLabels(),function(p){if(!p.tick.offInterval){p=U(p);var c=o.scale;p.coord=o.dataToCoord(gs(c,p.tick)),u.push(p)}}),wl(u),wl(s),S(Lf,function(p){t.get([p,"show"])&&(!o.scale.isBlank()||p==="axisLine")&&Of[p](this.group,t,n,s,l,a,u)},this)}},e.type="angleAxis",e})(Rt),Of={axisLine:function(i,e,t,r,o,n){var a=e.getModel(["axisLine","lineStyle"]),s=t.getAngleAxis(),l=Math.PI/180,u=s.getExtent(),p=Di(t),c=p?0:1,f,h=Math.abs(u[1]-u[0])===360?"Circle":"Arc";n[c]===0?f=new vt[h]({shape:{cx:t.cx,cy:t.cy,r:n[p],startAngle:-u[0]*l,endAngle:-u[1]*l,clockwise:s.inverse},style:a.getLineStyle(),z2:1,silent:!0}):f=new Ya({shape:{cx:t.cx,cy:t.cy,r:n[p],r0:n[c]},style:a.getLineStyle(),z2:1,silent:!0}),f.style.fill=null,i.add(f)},axisTick:function(i,e,t,r,o,n){var a=e.getModel("axisTick"),s=(a.get("inside")?-1:1)*a.get("length"),l=n[Di(t)],u=R(r,function(p){return new Lt({shape:Ai(t,[l,l+s],p.coord)})});i.add(zt(u,{style:K(a.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(i,e,t,r,o,n){if(o.length){for(var a=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(a.get("inside")?-1:1)*s.get("length"),u=n[Di(t)],p=[],c=0;c<o.length;c++)for(var f=0;f<o[c].length;f++)p.push(new Lt({shape:Ai(t,[u,u+l],o[c][f].coord)}));i.add(zt(p,{style:K(s.getModel("lineStyle").getLineStyle(),K(a.getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])}))}))}},axisLabel:function(i,e,t,r,o,n,a){var s=e.getCategories(!0),l=e.getModel("axisLabel"),u=l.get("margin"),p=e.get("triggerEvent");S(a,function(c,f){var h=l,d=c.tick.value,v=n[Di(t)],m=t.coordToPoint([v+u,c.coord]),g=t.cx,y=t.cy,x=Math.abs(m[0]-g)/v<.3?"center":m[0]>g?"left":"right",_=Math.abs(m[1]-y)/v<.3?"middle":m[1]>y?"top":"bottom";if(s&&s[d]){var b=s[d];ot(b)&&b.textStyle&&(h=new at(b.textStyle,l,l.ecModel))}var w=new F({silent:Gt.isLabelSilent(e),style:nt(h,{x:m[0],y:m[1],fill:h.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:c.formattedLabel,align:x,verticalAlign:_})});if(i.add(w),Kt({el:w,componentModel:e,itemName:c.formattedLabel,formatterParamsExtra:{isTruncated:function(){return w.isTruncated},value:c.rawLabel,tickIndex:f}}),p){var C=Gt.makeAxisEventDataBase(e);C.targetType="axisLabel",C.value=c.rawLabel,j(w).eventData=C}},this)},splitLine:function(i,e,t,r,o,n){var a=e.getModel("splitLine"),s=a.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var p=[],c=0;c<r.length;c++){var f=u++%l.length;p[f]=p[f]||[],p[f].push(new Lt({shape:Ai(t,n,r[c].coord)}))}for(var c=0;c<p.length;c++)i.add(zt(p[c],{style:K({stroke:l[c%l.length]},s.getLineStyle()),silent:!0,z:e.get("z")}))},minorSplitLine:function(i,e,t,r,o,n){if(o.length){for(var a=e.getModel("minorSplitLine"),s=a.getModel("lineStyle"),l=[],u=0;u<o.length;u++)for(var p=0;p<o[u].length;p++)l.push(new Lt({shape:Ai(t,n,o[u][p].coord)}));i.add(zt(l,{style:s.getLineStyle(),silent:!0,z:e.get("z")}))}},splitArea:function(i,e,t,r,o,n){if(r.length){var a=e.getModel("splitArea"),s=a.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var p=[],c=Math.PI/180,f=-r[0].coord*c,h=Math.min(n[0],n[1]),d=Math.max(n[0],n[1]),v=e.get("clockwise"),m=1,g=r.length;m<=g;m++){var y=m===g?r[0].coord:r[m].coord,x=u++%l.length;p[x]=p[x]||[],p[x].push(new qr({shape:{cx:t.cx,cy:t.cy,r0:h,r:d,startAngle:f,endAngle:-y*c,clockwise:v},silent:!0})),f=-y*c}for(var m=0;m<p.length;m++)i.add(zt(p[m],{style:K({fill:l[m%l.length]},s.getAreaStyle()),silent:!0}))}}},Cl=zf;var Pf=["splitLine","splitArea","minorSplitLine"],kf=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,r,o){if(this.group.removeAll(),!!t.get("show")){var n=this._axisGroup,a=this._axisGroup=new et;this.group.add(a);var s=t.axis,l=s.polar,u=l.getAngleAxis(),p=s.getTicksCoords(),c=s.getMinorTicksCoords(),f=u.getExtent()[0],h=s.getExtent(),d=Ef(l,t,f),v=new Gt(t,o,d);v.build(),a.add(v.group),Jr(n,a,t),S(Pf,function(m){t.get([m,"show"])&&!s.scale.isBlank()&&Rf[m](this.group,t,l,f,h,p,c)},this)}},e.type="radiusAxis",e})(Rt),Rf={splitLine:function(i,e,t,r,o,n){var a=e.getModel("splitLine"),s=a.getModel("lineStyle"),l=s.get("color"),u=0,p=t.getAngleAxis(),c=Math.PI/180,f=p.getExtent(),h=Math.abs(f[1]-f[0])===360?"Circle":"Arc";l=l instanceof Array?l:[l];for(var d=[],v=0;v<n.length;v++){var m=u++%l.length;d[m]=d[m]||[],d[m].push(new vt[h]({shape:{cx:t.cx,cy:t.cy,r:Math.max(n[v].coord,0),startAngle:-f[0]*c,endAngle:-f[1]*c,clockwise:p.inverse}}))}for(var v=0;v<d.length;v++)i.add(zt(d[v],{style:K({stroke:l[v%l.length],fill:null},s.getLineStyle()),silent:!0}))},minorSplitLine:function(i,e,t,r,o,n,a){if(a.length){for(var s=e.getModel("minorSplitLine"),l=s.getModel("lineStyle"),u=[],p=0;p<a.length;p++)for(var c=0;c<a[p].length;c++)u.push(new Wa({shape:{cx:t.cx,cy:t.cy,r:a[p][c].coord}}));i.add(zt(u,{style:K({fill:null},l.getLineStyle()),silent:!0}))}},splitArea:function(i,e,t,r,o,n){if(n.length){var a=e.getModel("splitArea"),s=a.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var p=[],c=n[0].coord,f=1;f<n.length;f++){var h=u++%l.length;p[h]=p[h]||[],p[h].push(new qr({shape:{cx:t.cx,cy:t.cy,r0:c,r:n[f].coord,startAngle:0,endAngle:Math.PI*2},silent:!0})),c=n[f].coord}for(var f=0;f<p.length;f++)i.add(zt(p[f],{style:K({fill:l[f%l.length]},s.getAreaStyle()),silent:!0}))}}};function Ef(i,e,t){return{position:[i.cx,i.cy],rotation:t/180*Math.PI,labelDirection:-1,tickDirection:-1,nameDirection:1,labelRotate:e.getModel("axisLabel").get("rotate"),z2:1}}var Tl=kf;var Vf=Xr();function Ml(i){return i.get("stack")||"__ec_stack_"+i.seriesIndex}var Al=Ra(qe,Uf);function Uf(i){var e=mi(qe,Dt);ys(i,e,function(t){var r=Bf(t,qe),o={};Lo(t,e,function(n){Nf(t,n,r,o)})})}function Nf(i,e,t,r){var o=e.getData(),n=Ml(e),a=t[n],s=a.offset,l=a.width,u=e.coordinateSystem,p=u.getOtherAxis(i),c=u.cx,f=u.cy,h=e.get("barMinHeight")||0,d=e.get("barMinAngle")||0;r[n]=r[n]||[];for(var v=o.mapDimension(p.dim),m=o.mapDimension(i.dim),g=ui(o,v),y=i.dim!=="radius"||!e.get("roundCap",!0),x=p.dataToCoord(Is(p)),_=0,b=o.count();_<b;_++){var w=o.get(v,_),C=o.get(m,_),D=w>=0?"p":"n",A=x;g&&(r[n][C]||(r[n][C]={p:x,n:x}),A=r[n][C][D]);var z=void 0,L=void 0,Y=void 0,P=void 0;if(p.dim==="radius"){var V=p.dataToCoord(w)-x,$=i.dataToCoord(C);dr(V)<h&&(V=(V<0?-1:1)*h),z=A,L=A+V,Y=$-s,P=Y-l,g&&(r[n][C][D]=L)}else{var it=p.dataToCoord(w,y)-x,Wt=i.dataToCoord(C);dr(it)<d&&(it=(it<0?-1:1)*d),z=Wt+s,L=z+l,Y=A,P=A+it,g&&(r[n][C][D]=P)}o.setItemLayout(_,{cx:c,cy:f,r0:z,r:L,startAngle:-Y*mo/180,endAngle:-P*mo/180,clockwise:Y>=P})}}function Bf(i,e){var t=mi(e,Dt),r=Ke(i,{fromStat:{key:t},min:1}).w,o=r,n=0,a="20%",s="30%",l={};Lo(i,t,function(m){var g=Ml(m);l[g]||n++,l[g]=l[g]||{width:0,maxWidth:0};var y=J(m.get("barWidth"),r),x=J(m.get("barMaxWidth"),r),_=m.get("barGap"),b=m.get("barCategoryGap");y&&!l[g].width&&(y=dt(o,y),l[g].width=y,o-=y),x&&(l[g].maxWidth=x),_!=null&&(s=_),b!=null&&(a=b)});var u={},p=J(a,r),c=J(s,1),f=(o-p)/(n+(n-1)*c);f=ct(f,0),S(l,function(m,g){var y=m.maxWidth;y&&y<f&&(y=dt(y,o),m.width&&(y=dt(y,m.width)),o-=y,m.width=y,n--)}),f=(o-p)/(n+(n-1)*c),f=ct(f,0);var h=0,d;S(l,function(m,g){m.width||(m.width=f),d=m,h+=m.width*(1+c)}),d&&(h-=d.width*c);var v=-h/2;return S(l,function(m,g){u[g]=u[g]||{offset:v,width:m.width},v+=m.width*(1+c)}),u}function Dl(i,e){Vf(i,function(){var t=mi(e,Dt);Ds(i,t,e,Dt),_s(t,As(t))})}var Hf={startAngle:90,clockwise:!0,splitNumber:12,containShape:!1,axisLabel:{rotate:0}},Gf={splitNumber:5},Ff=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.type="polar",e})(X);function Zf(i){ft(ee),Rt.registerAxisPointerClass("PolarAxisPointer",hl),i.registerCoordinateSystem("polar",bl),i.registerComponentModel(dl),i.registerComponentView(Ff),Sr(i,"angle",vl,Hf),Sr(i,"radius",ml,Gf),i.registerComponentView(Cl),i.registerComponentView(Tl),i.registerLayout(Al),Dl(i,qe)}function Tr(i,e){e=e||{};var t=i.coordinateSystem,r=i.axis,o={},n=r.position,a=r.orient,s=t.getRect(),l=[s.x,s.x+s.width,s.y,s.y+s.height],u={horizontal:{top:l[2],bottom:l[3]},vertical:{left:l[0],right:l[1]}};o.position=[a==="vertical"?u.vertical[n]:l[0],a==="horizontal"?u.horizontal[n]:l[3]];var p={horizontal:0,vertical:1};o.rotation=Math.PI/2*p[a];var c={top:-1,bottom:1,right:1,left:-1};o.labelDirection=o.tickDirection=o.nameDirection=c[n],i.get(["axisTick","inside"])&&(o.tickDirection=-o.tickDirection),It(e.labelInside,i.get(["axisLabel","inside"]))&&(o.labelDirection=-o.labelDirection);var f=i.get(["axisLabel","rotate"]);return o.labelRotate=n==="top"?-f:f,o.z2=1,o}var Wf=["splitArea","splitLine","breakArea"],Yf=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="SingleAxisPointer",t}return e.prototype.render=function(t,r,o,n){var a=this.group;a.removeAll();var s=this._axisGroup;this._axisGroup=new et;var l=Tr(t),u=new Gt(t,o,l);u.build(),a.add(this._axisGroup),a.add(u.group),S(Wf,function(p){t.get([p,"show"])&&Xf[p](this,this.group,this._axisGroup,t,o)},this),Jr(s,this._axisGroup,t),i.prototype.render.call(this,t,r,o,n)},e.prototype.remove=function(){ks(this)},e.type="singleAxis",e})(Rt),Xf={splitLine:function(i,e,t,r,o){var n=r.axis;if(!n.scale.isBlank()){var a=r.getModel("splitLine"),s=a.getModel("lineStyle"),l=s.get("color");l=l instanceof Array?l:[l];for(var u=s.get("width"),p=r.coordinateSystem.getRect(),c=n.isHorizontal(),f=[],h=0,d=n.getTicksCoords({tickModel:a,breakTicks:"none",pruneByBreak:"preserve_extent_bound"}),v=[],m=[],g=0;g<d.length;++g){var y=n.toGlobalCoord(d[g].coord);c?(v[0]=y,v[1]=p.y,m[0]=y,m[1]=p.y+p.height):(v[0]=p.x,v[1]=y,m[0]=p.x+p.width,m[1]=y);var x=new Lt({shape:{x1:v[0],y1:v[1],x2:m[0],y2:m[1]},silent:!0});qa(x.shape,u);var _=h++%l.length;f[_]=f[_]||[],f[_].push(x)}for(var b=s.getLineStyle(["color"]),g=0;g<f.length;++g)e.add(zt(f[g],{style:K({stroke:l[g%l.length]},b),silent:!0}))}},splitArea:function(i,e,t,r,o){Ps(i,t,r,r)},breakArea:function(i,e,t,r,o){var n=Ts(),a=r.axis.scale;n&&a.type!=="ordinal"&&n.rectCoordBuildBreakAxis(e,i,r,r.coordinateSystem.getRect(),o)}},Ll=Yf;var Ii="single",zl="singleAxis",Li="singleAxis",Ol=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.getCoordSysModel=function(){return this},e.type=Li,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})(Z);ie(Ol,vi.prototype);var zi=Ol;var Kf=(function(i){T(e,i);function e(t,r,o,n,a){var s=i.call(this,t,r,o)||this;return s.type=n||"value",s.position=a||"bottom",s}return e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.pointToData=function(t,r){return this.coordinateSystem.pointToData(t)[0]},e})(kt),Pl=Kf;var qo=["single"],qf=(function(){function i(e,t,r){this.type=Ii,this.dimension="single",this.dimensions=qo,this.axisPointerEnabled=!0,this.model=e,this._init(e,t,r)}return i.prototype._init=function(e,t,r){var o=this.dimension,n=fi(e),a=new Pl(o,Ye(e,n,!0),[0,0],n,e.get("position"));a.onBand=di(a.scale,e),a.inverse=e.get("inverse"),a.orient=e.get("orient"),e.axis=a,a.model=e,a.coordinateSystem=this,this._axis=a},i.prototype.update=function(e,t){var r=this._axis;be(r,yr),xr(r)},i.prototype.resize=function(e,t){var r=gt(e,t).refContainer;this._rect=pt(e.getBoxLayoutParams(),r),this._adjustAxis()},i.prototype.getRect=function(){return this._rect},i.prototype._adjustAxis=function(){var e=this._rect,t=this._axis,r=t.isHorizontal(),o=r?[0,e.width]:[0,e.height],n=t.inverse?1:0;t.setExtent(o[n],o[1-n]),this._updateAxisTransform(t,r?e.x:e.y)},i.prototype._updateAxisTransform=function(e,t){var r=e.getExtent(),o=r[0]+r[1],n=e.isHorizontal();e.toGlobalCoord=n?function(a){return a+t}:function(a){return o-a+t},e.toLocalCoord=n?function(a){return a-t}:function(a){return o-a+t}},i.prototype.getAxis=function(){return this._axis},i.prototype.getBaseAxis=function(){return this._axis},i.prototype.getAxes=function(){return[this._axis]},i.prototype.getTooltipAxes=function(){return{baseAxes:[this.getAxis()],otherAxes:[]}},i.prototype.containPoint=function(e){var t=this.getRect(),r=this.getAxis(),o=r.orient;return o==="horizontal"?r.contain(r.toLocalCoord(e[0]))&&e[1]>=t.y&&e[1]<=t.y+t.height:r.contain(r.toLocalCoord(e[1]))&&e[0]>=t.y&&e[0]<=t.y+t.height},i.prototype.pointToData=function(e,t,r){r=r||[];var o=this.getAxis();return r[0]=o.coordToData(o.toLocalCoord(e[o.orient==="horizontal"?0:1])),r},i.prototype.dataToPoint=function(e,t,r){var o=this.getAxis(),n=this.getRect();r=r||[];var a=o.orient==="horizontal"?0:1;return e instanceof Array&&(e=e[0]),r[a]=o.toGlobalCoord(o.dataToCoord(+e)),r[1-a]=a===0?n.y+n.height/2:n.x+n.width/2,r},i.prototype.convertToPixel=function(e,t,r){var o=kl(t);return o===this?this.dataToPoint(r):null},i.prototype.convertFromPixel=function(e,t,r){var o=kl(t);return o===this?this.pointToData(r):null},i})();function kl(i){var e=i.seriesModel,t=i.singleAxisModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}var Rl=qf;function jf(i,e){var t=[];return i.eachComponent(Li,function(r,o){var n=new Rl(r,i,e);n.name="single_"+o,n.resize(r,e),r.coordinateSystem=n,t.push(n)}),i.eachSeries(function(r){if(r.get("coordinateSystem")===zl){var o=r.getReferringComponents(Li,Mt).models[0],n=r.coordinateSystem=o&&o.coordinateSystem;n&&gr(n.getAxis(),r,Ii)}}),t}var $f={create:jf,dimensions:qo},El=$f;var Vl=["x","y"],Jf=["width","height"],Qf=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,r,o,n,a){var s=o.axis,l=s.coordinateSystem,u=Pi(s),p=Oi(l,u),c=Oi(l,1-u),f=l.dataToPoint(r)[0],h=n.get("type");if(h&&h!=="none"){var d=$e(n),v=th[h](s,f,p,c,n.get("seriesDataIndices"),n.ecModel);v.style=d,t.graphicKey=v.type,t.pointer=v}var m=Tr(o);Si(r,t,m,o,n,a)},e.prototype.getHandleTransform=function(t,r,o){var n=Tr(r,{labelInside:!1});n.labelMargin=o.get(["handle","margin"]);var a=br(r.axis,t,n);return{x:a[0],y:a[1],rotation:n.rotation+(n.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,r,o,n){var a=o.axis,s=a.coordinateSystem,l=Pi(a),u=Oi(s,l),p=[t.x,t.y];p[l]+=r[l],p[l]=Math.min(u[1],p[l]),p[l]=Math.max(u[0],p[l]);var c=Oi(s,1-l),f=(c[1]+c[0])/2,h=[f,f];return h[l]=p[l],{x:p[0],y:p[1],rotation:t.rotation,cursorPoint:h,tooltipOption:{verticalAlign:"middle"}}},e})(je),th={line:function(i,e,t,r){var o=Je([e,r[0]],[e,r[1]],Pi(i));return{type:"Line",subPixelOptimize:!0,shape:o}},shadow:function(i,e,t,r,o,n){var a=Qe(i,o,n),s=r[1]-r[0],l=tr(e,t,a),u=l[0],p=l[1];return{type:"Rect",shape:bi([u,r[0]],[p-u,s],Pi(i))}}};function Pi(i){return i.isHorizontal()?0:1}function Oi(i,e){var t=i.getRect();return[t[Vl[e]],t[Vl[e]]+t[Jf[e]]]}var Ul=Qf;var eh=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.type="single",e})(X);function rh(i){ft(ee),Rt.registerAxisPointerClass("SingleAxisPointer",Ul),i.registerComponentView(eh),i.registerComponentView(Ll),i.registerComponentModel(zi),Sr(i,"single",zi,zi.defaultOption),i.registerCoordinateSystem("single",El)}var ih=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r,o){var n=Fe(t);i.prototype.init.apply(this,arguments),Nl(t,n)},e.prototype.mergeOption=function(t){i.prototype.mergeOption.apply(this,arguments),Nl(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:M.color.axisLine,width:1,type:"solid"}},itemStyle:{color:M.color.neutral00,borderWidth:1,borderColor:M.color.neutral10},dayLabel:{show:!0,firstDay:0,position:"start",margin:M.size.s,color:M.color.secondary},monthLabel:{show:!0,position:"start",margin:M.size.s,align:"center",formatter:null,color:M.color.secondary},yearLabel:{show:!0,position:null,margin:M.size.xl,formatter:null,color:M.color.quaternary,fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},e})(Z);function Nl(i,e){var t=i.cellSize,r;I(t)?r=t:r=i.cellSize=[t,t],r.length===1&&(r[1]=r[0]);var o=R([0,1],function(n){return os(e,n)&&(r[n]="auto"),r[n]!=null&&r[n]!=="auto"});Ge(i,e,{type:"box",ignoreSize:o})}var Bl=ih;var oh=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,o){var n=this.group;n.removeAll();var a=t.coordinateSystem,s=a.getRangeInfo(),l=a.getOrient(),u=r.getLocaleModel();this._renderDayRect(t,s,n),this._renderLines(t,s,l,n),this._renderYearText(t,s,l,n),this._renderMonthText(t,u,l,n),this._renderWeekText(t,u,s,l,n)},e.prototype._renderDayRect=function(t,r,o){for(var n=t.coordinateSystem,a=t.getModel("itemStyle").getItemStyle(),s=n.getCellWidth(),l=n.getCellHeight(),u=r.start.time;u<=r.end.time;u=n.getNextNDay(u,1).time){var p=n.dataToCalendarLayout([u],!1).tl,c=new rt({shape:{x:p[0],y:p[1],width:s,height:l},cursor:"default",style:a});o.add(c)}},e.prototype._renderLines=function(t,r,o,n){var a=this,s=t.coordinateSystem,l=t.getModel(["splitLine","lineStyle"]).getLineStyle(),u=t.get(["splitLine","show"]),p=l.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var c=r.start,f=0;c.time<=r.end.time;f++){d(c.formatedDate),f===0&&(c=s.getDateInfo(r.start.y+"-"+r.start.m));var h=c.date;h.setMonth(h.getMonth()+1),c=s.getDateInfo(h)}d(s.getNextNDay(r.end.time,1).formatedDate);function d(v){a._firstDayOfMonth.push(s.getDateInfo(v)),a._firstDayPoints.push(s.dataToCalendarLayout([v],!1).tl);var m=a._getLinePointsOfOneWeek(t,v,o);a._tlpoints.push(m[0]),a._blpoints.push(m[m.length-1]),u&&a._drawSplitline(m,l,n)}u&&this._drawSplitline(a._getEdgesPoints(a._tlpoints,p,o),l,n),u&&this._drawSplitline(a._getEdgesPoints(a._blpoints,p,o),l,n)},e.prototype._getEdgesPoints=function(t,r,o){var n=[t[0].slice(),t[t.length-1].slice()],a=o==="horizontal"?0:1;return n[0][a]=n[0][a]-r/2,n[1][a]=n[1][a]+r/2,n},e.prototype._drawSplitline=function(t,r,o){var n=new jr({z2:20,shape:{points:t},style:r});o.add(n)},e.prototype._getLinePointsOfOneWeek=function(t,r,o){for(var n=t.coordinateSystem,a=n.getDateInfo(r),s=[],l=0;l<7;l++){var u=n.getNextNDay(a.time,l),p=n.dataToCalendarLayout([u.time],!1);s[2*u.day]=p.tl,s[2*u.day+1]=p[o==="horizontal"?"bl":"tr"]}return s},e.prototype._formatterLabel=function(t,r){return E(t)&&t?ri(t,r):G(t)?t(r):r.nameMap},e.prototype._yearTextPositionControl=function(t,r,o,n,a){var s=r[0],l=r[1],u=["center","bottom"];n==="bottom"?(l+=a,u=["center","top"]):n==="left"?s-=a:n==="right"?(s+=a,u=["center","top"]):l-=a;var p=0;return(n==="left"||n==="right")&&(p=Math.PI/2),{rotation:p,x:s,y:l,style:{align:u[0],verticalAlign:u[1]}}},e.prototype._renderYearText=function(t,r,o,n){var a=t.getModel("yearLabel");if(a.get("show")){var s=a.get("margin"),l=a.get("position");l||(l=o!=="horizontal"?"top":"left");var u=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],p=(u[0][0]+u[1][0])/2,c=(u[0][1]+u[1][1])/2,f=o==="horizontal"?0:1,h={top:[p,u[f][1]],bottom:[p,u[1-f][1]],left:[u[1-f][0],c],right:[u[f][0],c]},d=r.start.y;+r.end.y>+r.start.y&&(d=d+"-"+r.end.y);var v=a.get("formatter"),m={start:r.start.y,end:r.end.y,nameMap:d},g=this._formatterLabel(v,m),y=new F({z2:30,style:nt(a,{text:g}),silent:a.get("silent")});y.attr(this._yearTextPositionControl(y,h[l],o,l,s)),n.add(y)}},e.prototype._monthTextPositionControl=function(t,r,o,n,a){var s="left",l="top",u=t[0],p=t[1];return o==="horizontal"?(p=p+a,r&&(s="center"),n==="start"&&(l="bottom")):(u=u+a,r&&(l="middle"),n==="start"&&(s="right")),{x:u,y:p,align:s,verticalAlign:l}},e.prototype._renderMonthText=function(t,r,o,n){var a=t.getModel("monthLabel");if(a.get("show")){var s=a.get("nameMap"),l=a.get("margin"),u=a.get("position"),p=a.get("align"),c=[this._tlpoints,this._blpoints];(!s||E(s))&&(s&&(r=_o(s)||r),s=r.get(["time","monthAbbr"])||[]);var f=u==="start"?0:1,h=o==="horizontal"?0:1;l=u==="start"?-l:l;for(var d=p==="center",v=a.get("silent"),m=0;m<c[f].length-1;m++){var g=c[f][m].slice(),y=this._firstDayOfMonth[m];if(d){var x=this._firstDayPoints[m];g[h]=(x[h]+c[0][m+1][h])/2}var _=a.get("formatter"),b=s[+y.m-1],w={yyyy:y.y,yy:(y.y+"").slice(2),MM:y.m,M:+y.m,nameMap:b},C=this._formatterLabel(_,w),D=new F({z2:30,style:N(nt(a,{text:C}),this._monthTextPositionControl(g,d,o,u,l)),silent:v});n.add(D)}}},e.prototype._weekTextPositionControl=function(t,r,o,n,a){var s="center",l="middle",u=t[0],p=t[1],c=o==="start";return r==="horizontal"?(u=u+n+(c?1:-1)*a[0]/2,s=c?"right":"left"):(p=p+n+(c?1:-1)*a[1]/2,l=c?"bottom":"top"),{x:u,y:p,align:s,verticalAlign:l}},e.prototype._renderWeekText=function(t,r,o,n,a){var s=t.getModel("dayLabel");if(s.get("show")){var l=t.coordinateSystem,u=s.get("position"),p=s.get("nameMap"),c=s.get("margin"),f=l.getFirstDayOfWeek();if(!p||E(p)){p&&(r=_o(p)||r);var h=r.get(["time","dayOfWeekShort"]);p=h||R(r.get(["time","dayOfWeekAbbr"]),function(w){return w[0]})}var d=l.getNextNDay(o.end.time,7-o.lweek).time,v=[l.getCellWidth(),l.getCellHeight()];c=J(c,Math.min(v[1],v[0])),u==="start"&&(d=l.getNextNDay(o.start.time,-(7+o.fweek)).time,c=-c);for(var m=s.get("silent"),g=0;g<7;g++){var y=l.getNextNDay(d,g),x=l.dataToCalendarLayout([y.time],!1).center,_=g;_=Math.abs((g+f)%7);var b=new F({z2:30,style:N(nt(s,{text:p[_]}),this._weekTextPositionControl(x,n,u,c,v)),silent:m});a.add(b)}}},e.type="calendar",e})(X),Hl=oh;var jo=864e5,nh=(function(){function i(e,t,r){this.type="calendar",this.dimensions=i.dimensions,this.getDimensionsInfo=i.getDimensionsInfo,this._model=e,this._update(t,r)}return i.getDimensionsInfo=function(){return[{name:"time",type:"time"},"value"]},i.prototype.getRangeInfo=function(){return this._rangeInfo},i.prototype.getModel=function(){return this._model},i.prototype.getRect=function(){return this._rect},i.prototype.getCellWidth=function(){return this._sw},i.prototype.getCellHeight=function(){return this._sh},i.prototype.getOrient=function(){return this._orient},i.prototype.getFirstDayOfWeek=function(){return this._firstDayOfWeek},i.prototype.getDateInfo=function(e){e=ba(e);var t=e.getFullYear(),r=e.getMonth()+1,o=r<10?"0"+r:""+r,n=e.getDate(),a=n<10?"0"+n:""+n,s=e.getDay();return s=Math.abs((s+7-this.getFirstDayOfWeek())%7),{y:t+"",m:o,d:a,day:s,time:e.getTime(),formatedDate:t+"-"+o+"-"+a,date:e}},i.prototype.getNextNDay=function(e,t){return t=t||0,t===0?this.getDateInfo(e):(e=new Date(this.getDateInfo(e).time),e.setDate(e.getDate()+t),this.getDateInfo(e))},i.prototype._update=function(e,t){this._firstDayOfWeek=+this._model.getModel("dayLabel").get("firstDay"),this._orient=this._model.get("orient"),this._lineWidth=this._model.getModel("itemStyle").getItemStyle().lineWidth||0,this._rangeInfo=this._getRangeInfo(this._initRangeOption());var r=this._rangeInfo.weeks||1,o=["width","height"],n=this._model.getCellSize().slice(),a=this._model.getBoxLayoutParams(),s=this._orient==="horizontal"?[r,7]:[7,r];S([0,1],function(c){p(n,c)&&(a[o[c]]=n[c]*s[c])});var l={width:t.getWidth(),height:t.getHeight()},u=this._rect=pt(a,l);S([0,1],function(c){p(n,c)||(n[c]=u[o[c]]/s[c])});function p(c,f){return c[f]!=null&&c[f]!=="auto"}this._sw=n[0],this._sh=n[1]},i.prototype.dataToPoint=function(e,t,r){r=r||[],I(e)&&(e=e[0]),t==null&&(t=!0);var o=this.getDateInfo(e),n=this._rangeInfo,a=o.formatedDate;if(t&&!(o.time>=n.start.time&&o.time<n.end.time+jo))return r[0]=r[1]=NaN,r;var s=o.day,l=this._getRangeInfo([n.start.time,a]).nthWeek;return this._orient==="vertical"?(r[0]=this._rect.x+s*this._sw+this._sw/2,r[1]=this._rect.y+l*this._sh+this._sh/2):(r[0]=this._rect.x+l*this._sw+this._sw/2,r[1]=this._rect.y+s*this._sh+this._sh/2),r},i.prototype.pointToData=function(e){var t=this.pointToDate(e);return t&&t.time},i.prototype.dataToLayout=function(e,t,r){r=r||{};var o=r.rect=r.rect||{},n=r.contentRect=r.contentRect||{},a=this.dataToPoint(e,t);return o.x=a[0]-this._sw/2,o.y=a[1]-this._sh/2,o.width=this._sw,o.height=this._sh,Ct.copy(n,o),Ue(n,this._lineWidth/2,!0,!0),r},i.prototype.dataToCalendarLayout=function(e,t){var r=this.dataToPoint(e,t);return{center:r,tl:[r[0]-this._sw/2,r[1]-this._sh/2],tr:[r[0]+this._sw/2,r[1]-this._sh/2],br:[r[0]+this._sw/2,r[1]+this._sh/2],bl:[r[0]-this._sw/2,r[1]+this._sh/2]}},i.prototype.pointToDate=function(e){var t=Math.floor((e[0]-this._rect.x)/this._sw)+1,r=Math.floor((e[1]-this._rect.y)/this._sh)+1,o=this._rangeInfo.range;return this._orient==="vertical"?this._getDateByWeeksAndDay(r,t-1,o):this._getDateByWeeksAndDay(t,r-1,o)},i.prototype.convertToPixel=function(e,t,r){var o=$o(t);return o===this?o.dataToPoint(r):null},i.prototype.convertToLayout=function(e,t,r){var o=$o(t);return o===this?o.dataToLayout(r):null},i.prototype.convertFromPixel=function(e,t,r){var o=$o(t);return o===this?o.pointToData(r):null},i.prototype.containPoint=function(e){return console.warn("Not implemented."),!1},i.prototype._initRangeOption=function(){var e=this._model.get("range"),t;if(I(e)&&e.length===1&&(e=e[0]),I(e))t=e;else{var r=e.toString();if(/^\d{4}$/.test(r)&&(t=[r+"-01-01",r+"-12-31"]),/^\d{4}[\/|-]\d{1,2}$/.test(r)){var o=this.getDateInfo(r),n=o.date;n.setMonth(n.getMonth()+1);var a=this.getNextNDay(n,-1);t=[o.formatedDate,a.formatedDate]}/^\d{4}[\/|-]\d{1,2}[\/|-]\d{1,2}$/.test(r)&&(t=[r,r])}if(!t)return e;var s=this._getRangeInfo(t);return s.start.time>s.end.time&&t.reverse(),t},i.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 o=Math.floor(t[1].time/jo)-Math.floor(t[0].time/jo)+1,n=new Date(t[0].time),a=n.getDate(),s=t[1].date.getDate();n.setDate(a+o-1);var l=n.getDate();if(l!==s)for(var u=n.getTime()-t[1].time>0?1:-1;(l=n.getDate())!==s&&(n.getTime()-t[1].time)*u>0;)o-=u,n.setDate(l-u);var p=Math.floor((o+t[0].day+6)/7),c=r?-p+1:p-1;return r&&t.reverse(),{range:[t[0].formatedDate,t[1].formatedDate],start:t[0],end:t[1],allDay:o,weeks:p,nthWeek:c,fweek:t[0].day,lweek:t[1].day}},i.prototype._getDateByWeeksAndDay=function(e,t,r){var o=this._getRangeInfo(r);if(e>o.weeks||e===0&&t<o.fweek||e===o.weeks&&t>o.lweek)return null;var n=(e-1)*7-o.fweek+t,a=new Date(o.start.time);return a.setDate(+o.start.d+n),this.getDateInfo(a)},i.create=function(e,t){var r=[];return e.eachComponent("calendar",function(o){var n=new i(o,e,t);r.push(n),o.coordinateSystem=n}),e.eachComponent(function(o,n){ii({targetModel:n,coordSysType:"calendar",coordSysProvider:oi})}),r},i.dimensions=["time","value"],i})();function $o(i){var e=i.calendarModel,t=i.seriesModel,r=e?e.coordinateSystem:t?t.coordinateSystem:null;return r}var Gl=nh;function ah(i){i.registerComponentModel(Bl),i.registerComponentView(Hl),i.registerCoordinateSystem("calendar",Gl)}var Ft={level:1,leaf:2,nonLeaf:3},Zt={none:0,all:1,body:2,corner:3};function Jo(i,e,t){var r=e[k[t]].getCell(i);return!r&&oe(i)&&i<0&&(r=e[k[1-t]].getUnitLayoutInfo(t,Math.round(i))),r}function ki(i){var e=i||[];return e[0]=e[0]||[],e[1]=e[1]||[],e[0][0]=e[0][1]=e[1][0]=e[1][1]=NaN,e}function Ri(i,e,t,r,o){Fl(i[0],e,o,t,r,0),Fl(i[1],e,o,t,r,1)}function Fl(i,e,t,r,o,n){i[0]=1/0,i[1]=-1/0;var a=r[n],s=I(a)?a:[a],l=s.length,u=!!t;if(l>=1?(Zl(i,e,s,u,o,n,0),l>1&&Zl(i,e,s,u,o,n,l-1)):i[0]=i[1]=NaN,u){var p=-o[k[1-n]].getLocatorCount(n),c=o[k[n]].getLocatorCount(n)-1;t===Zt.body?p=ct(0,p):t===Zt.corner&&(c=dt(-1,c)),c<p&&(p=c=NaN),Yt(i[0])&&(i[0]=p),Yt(i[1])&&(i[1]=c),i[0]=ct(dt(i[0],c),p),i[1]=ct(dt(i[1],c),p)}}function Zl(i,e,t,r,o,n,a){var s=Jo(t[a],o,n);if(!s){i[0]=i[1]=NaN;return}var l=s.id[k[n]],u=l,p=uh(s);p&&(u+=p.span[k[n]]-1),i[0]=dt(i[0],l,u),i[1]=ct(i[1],l,u)}function Mr(i,e){return Yt(i[e][0])||Yt(i[e][1])}function Qo(i,e,t,r){e=e||sh;for(var o=0;o<r;o++)e[o]=!1;for(;;){for(var n=!1,o=0;o<r;o++){var a=t[o];!e[o]&&a.cellMergeOwner&&lh(i,a.locatorRange)&&(e[o]=!0,n=!0)}if(!n)break}}var sh=[];function lh(i,e){return!Wl(i[0],e[0])||!Wl(i[1],e[1])?!1:(i[0][0]=dt(i[0][0],e[0][0]),i[0][1]=ct(i[0][1],e[0][1]),i[1][0]=dt(i[1][0],e[1][0]),i[1][1]=ct(i[1][1],e[1][1]),!0)}function Wl(i,e){return i[1]>=e[0]&&i[0]<=e[1]}function tn(i,e){i.id.set(e[0][0],e[1][0]),i.span.set(e[0][1]-i.id.x+1,e[1][1]-i.id.y+1)}function Yl(i,e){i[0][0]=e[0][0],i[0][1]=e[0][1],i[1][0]=e[1][0],i[1][1]=e[1][1]}function en(i,e,t,r){var o=Jo(e[r][0],t,r),n=Jo(e[r][1],t,r);i[k[r]]=i[Tt[r]]=NaN,o&&n&&(i[k[r]]=o.xy,i[Tt[r]]=n.xy+n.wh-o.xy)}function er(i,e,t,r){return i[k[e]]=t,i[k[1-e]]=r,i}function uh(i){return i&&(i.type===Ft.leaf||i.type===Ft.nonLeaf)?i:null}function Te(){return{x:NaN,y:NaN,width:NaN,height:NaN}}var rn=(function(){function i(e,t){this._cells=[],this._levels=[],this.dim=e,this.dimIdx=e==="x"?0:1,this._model=t,this._uniqueValueGen=ph(e);var r=t.get("data",!0),o=t.get("length",!0);if(r!=null&&!I(r)&&(r=[]),r)this._initByDimModelData(r);else if(o!=null){r=Array(o);for(var n=0;n<o;n++)r[n]=null;this._initByDimModelData(r)}else this._initBySeriesData()}return i.prototype._initByDimModelData=function(e){var t=this,r=t._cells,o=t._levels,n=[],a=0;t._leavesCount=s(e,0,0),l();return;function s(u,p,c){var f=0;return u&&S(u,function(h,d){var v=!1,m;E(h)?m={value:h}:ot(h)?(m=h,h.value!=null&&!E(h.value)&&(v=!0,m={value:null})):(m={value:null},h!=null&&(v=!0));var g={type:Ft.nonLeaf,ordinal:NaN,level:c,firstLeafLocator:p,id:new wt,span:er(new wt,t.dimIdx,1,1),option:m,xy:NaN,wh:NaN,dim:t,rect:Te()};a++,(n[p]||(n[p]=[])).push(g),o[c]||(o[c]={type:Ft.level,xy:NaN,wh:NaN,option:null,id:new wt,dim:t});var y=s(m.children,p,c+1),x=Math.max(1,y);g.span[k[t.dimIdx]]=x,f+=x,p+=x}),f}function l(){for(var u=[];r.length<a;)for(var p=0;p<n.length;p++){var c=n[p].pop();if(c){c.ordinal=u.length;var f=c.option.value;u.push(f),r.push(c),t._uniqueValueGen.calcDupBase(f)}}t._uniqueValueGen.ensureValueUnique(u,r);var h=t._ordinalMeta=new Do({categories:u,needCollect:!1,deduplication:!1});t._scale=new Io({ordinalMeta:h});for(var d=0;d<t._leavesCount;d++){var v=t._cells[d];v.type=Ft.leaf,v.span[k[1-t.dimIdx]]=t._levels.length-v.level}t._initCellsId(),t._initLevelIdOptions()}},i.prototype._initBySeriesData=function(){var e=this;e._leavesCount=0,e._levels=[{type:Ft.level,xy:NaN,wh:NaN,option:null,id:new wt,dim:e}],e._initLevelIdOptions();var t=e._ordinalMeta=new Do({needCollect:!0,deduplication:!0,onCollect:function(r,o){var n=e._cells[o]={type:Ft.leaf,ordinal:o,level:0,firstLeafLocator:o,id:new wt,span:er(new wt,e.dimIdx,1,1),option:{value:r+""},xy:NaN,wh:NaN,dim:e,rect:Te()};e._leavesCount++,e._setCellId(n)}});e._scale=new Io({ordinalMeta:t})},i.prototype._setCellId=function(e){var t=this._levels.length,r=this.dimIdx;er(e.id,r,e.firstLeafLocator,e.level-t)},i.prototype._initCellsId=function(){var e=this._levels.length,t=this.dimIdx;S(this._cells,function(r){er(r.id,t,r.firstLeafLocator,r.level-e)})},i.prototype._initLevelIdOptions=function(){var e=this._levels.length,t=this.dimIdx,r=this._model.get("levels",!0);r=I(r)?r:[],S(this._levels,function(o,n){er(o.id,t,0,n-e),o.option=r[n]})},i.prototype.shouldShow=function(){return!!this._model.getShallow("show",!0)},i.prototype.resetLayoutIterator=function(e,t,r,o){if(e=e||new Nt,t===this.dimIdx){var n=this._leavesCount,a=r!=null?Math.max(0,r):0;o=o!=null?Math.min(o,n):n,e.reset(this._cells,a,a+o)}else{var n=this._levels.length,a=r!=null?Math.max(0,r+n):0;o=o!=null?Math.min(o,n):n,e.reset(this._levels,a,a+o)}return e},i.prototype.resetCellIterator=function(e){return(e||new Nt).reset(this._cells,0)},i.prototype.resetLevelIterator=function(e){return(e||new Nt).reset(this._levels,0)},i.prototype.getLayout=function(e,t,r){var o=this.getUnitLayoutInfo(t,r);e[k[t]]=o?o.xy:NaN,e[Tt[t]]=o?o.wh:NaN},i.prototype.getUnitLayoutInfo=function(e,t){return e===this.dimIdx?t<this._leavesCount?this._cells[t]:void 0:this._levels[t+this._levels.length]},i.prototype.getCell=function(e){var t=this._scale.parse(e);return Yt(t)?void 0:this._cells[t]},i.prototype.getLocatorCount=function(e){return e===this.dimIdx?this._leavesCount:this._levels.length},i.prototype.getOrdinalMeta=function(){return this._ordinalMeta},i})();function ph(i){var e=i.toUpperCase(),t=new RegExp("^"+e+"([0-9]+)$"),r=0;function o(s){var l;s!=null&&(l=s.match(t))&&(r=ct(r,+l[1]+1))}function n(){return""+e+r++}function a(s,l){for(var u=q(),p=0;p<s.length;p++){var c=s[p];(c==null||u.get(c)!=null)&&(s[p]=c=n(),l[p].option=K({value:c},l[p].option)),u.set(c,!0)}}return{calcDupBase:o,ensureValueUnique:a}}var nn=(function(){function i(e,t,r){this._model=t,this._dims=r,this._kind=e,this._cellMergeOwnerList=[]}return i.prototype._ensureCellMap=function(){var e=this,t=e._cellMap;return t||(t=e._cellMap=q(),r()),t;function r(){var n=[],a=e._model.getShallow("data");a&&!I(a)&&(a=null),S(a,function(d,v){if(!(!ot(d)||!I(d.coord))){var m=ki([]),g=null;if(Ri(m,g,d.coord,e._dims,d.coordClamp?Zt[e._kind]:Zt.none),!(Mr(m,0)||Mr(m,1))){var y=d&&d.mergeCells,x={id:new wt,span:new wt,locatorRange:m,option:d,cellMergeOwner:y};tn(x,m),n.push(x)}}});for(var s=[],l=0;l<n.length;l++){var u=n[l];if(u.cellMergeOwner){var p=u.locatorRange;Qo(p,s,n,l);for(var c=0;c<l;c++)s[c]&&(n[c].cellMergeOwner=!1);if(p[0][0]!==u.id.x||p[1][0]!==u.id.y){u.cellMergeOwner=!1;var f=N({},u.option);f.coord=null;var h={id:new wt,span:new wt,locatorRange:p,option:f,cellMergeOwner:!0};tn(h,p),n.push(h)}}}S(n,function(d){var v=o(d.id.x,d.id.y);if(d.cellMergeOwner&&(v.cellMergeOwner=!0,v.span=d.span,v.locatorRange=d.locatorRange,v.spanRect=Te(),e._cellMergeOwnerList.push(v)),!(!d.cellMergeOwner&&!d.option))for(var m=0;m<d.span.y;m++)for(var g=0;g<d.span.x;g++){var y=o(d.id.x+g,d.id.y+m);y.option=d.option,d.cellMergeOwner&&(y.inSpanOf=v)}})}function o(n,a){var s=Xl(n,a),l=t.get(s);return l||(l=t.set(s,{id:new wt(n,a),option:null,inSpanOf:null,span:null,spanRect:null,locatorRange:null,cellMergeOwner:!1})),l}},i.prototype.getCell=function(e){return this._ensureCellMap().get(Xl(e[0],e[1]))},i.prototype.travelExistingCells=function(e){this._ensureCellMap().each(e)},i.prototype.expandRangeByCellMerge=function(e){if(!Mr(e,0)&&!Mr(e,1)&&e[0][0]===e[0][1]&&e[1][0]===e[1][1]){on[0]=e[0][0],on[1]=e[1][0];var t=this.getCell(on),r=t&&t.inSpanOf;if(r){Yl(e,r.locatorRange);return}}var o=this._cellMergeOwnerList;Qo(e,null,o,o.length)},i})();var on=[];function Xl(i,e){return i+"|"+e}var an={show:!0,color:M.color.secondary,overflow:"break",lineOverflow:"truncate",padding:[2,3,2,3],distance:0};function sn(i){return{color:"none",borderWidth:1,borderColor:i?"none":M.color.borderTint}}var Kl={show:!0,label:an,itemStyle:sn(!1),silent:void 0,dividerLineStyle:{width:1,color:M.color.border}},ch={label:an,itemStyle:sn(!1),silent:void 0},fh={label:an,itemStyle:sn(!0),silent:void 0},hh={z:-50,left:"10%",top:"10%",right:"10%",bottom:"10%",x:Kl,y:Kl,body:ch,corner:fh,backgroundStyle:{color:"none",borderColor:M.color.axisLine,borderWidth:1},triggerEvent:!1},dh=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){var t=this._dimModels={x:new ql(this.get("x",!0)||{}),y:new ql(this.get("y",!0)||{})};t.x.option.type=t.y.option.type="category";var r=t.x.dim=new rn("x",t.x),o=t.y.dim=new rn("y",t.y),n={x:r,y:o};this._body=new nn("body",new at(this.getShallow("body")),n),this._corner=new nn("corner",new at(this.getShallow("corner")),n)},e.prototype.getDimensionModel=function(t){return this._dimModels[t]},e.prototype.getBody=function(){return this._body},e.prototype.getCorner=function(){return this._corner},e.type="matrix",e.layoutMode="box",e.defaultOption=hh,e})(Z),ql=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.getOrdinalMeta=function(){return this.dim.getOrdinalMeta()},e})(at);var jl=dh;var Ei=Math.round,vh=0,mh=99,gh={normal:25,special:100},yh={normal:50,special:125},xh=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r){this.group.removeAll();var o=this.group,n=t.coordinateSystem,a=n.getRect(),s=t.getDimensionModel("x"),l=t.getDimensionModel("y"),u=s.dim,p=l.dim;_h(o,t,r),Sh(o,t,u,p,r);var c=t.getShallow("borderZ2",!0),f=W(c,mh),h=f-1,d=t.getModel("backgroundStyle").getItemStyle(["borderWidth"]);d.lineWidth=0;var v=t.getModel("backgroundStyle").getItemStyle(["color","decal","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]);v.fill="none";var m=ln(a.clone(),d,vh),g=ln(a.clone(),v,f);m.silent=!0,g.silent=!0,o.add(m),o.add(g);var y=u.getUnitLayoutInfo(0,0),x=p.getUnitLayoutInfo(1,0);y&&x&&(u.shouldShow()&&o.add($l({x1:a.x,y1:x.xy,x2:a.x+a.width,y2:x.xy},s.getModel("dividerLineStyle").getLineStyle(),h)),p.shouldShow()&&o.add($l({x1:y.xy,y1:a.y,x2:y.xy,y2:a.y+a.height},l.getModel("dividerLineStyle").getLineStyle(),h)))},e.type="matrix",e})(X);function _h(i,e,t){r(0),r(1);function r(o){var n=e.getDimensionModel(k[o]),a=n.dim;if(a.shouldShow())for(var s=n.getModel("itemStyle"),l=n.getModel("label"),u=e.getShallow("tooltip",!0),p=[],c=a.resetCellIterator();c.next();){var f=c.item,h={};Ct.copy(h,f.rect),fo(p,f.id.x,f.id.y),Jl(p,e,i,t,f.option,s,l,n,h,f.option.value,yh,u,o===0?"x":"y")}}}function Sh(i,e,t,r,o){n("body",e.getBody(),t,r),t.shouldShow()&&r.shouldShow()&&n("corner",e.getCorner(),r,t);function n(a,s,l,u){var p=new at(e.getShallow(a,!0)),c=p.getModel("itemStyle"),f=p.getModel("label"),h=new Nt,d=new Nt,v=[],m=e.getShallow("tooltip",!0);for(u.resetLayoutIterator(d,1);d.next();)for(l.resetLayoutIterator(h,0);h.next();){var g=h.item,y=d.item;fo(v,g.id.x,y.id.y);var x=s.getCell(v);if(!(x&&x.inSpanOf&&x.inSpanOf!==x)){var _={};x&&x.span?Ct.copy(_,x.spanRect):(g.dim.getLayout(_,0,v[0]),y.dim.getLayout(_,1,v[1]));var b=x?x.option:null;Jl(v,e,i,o,b,c,f,p,_,b?b.value:null,gh,m,a)}}}}function Jl(i,e,t,r,o,n,a,s,l,u,p,c,f){var h;Vi.option=o?o.itemStyle:null,Vi.parentModel=n,rr.option=o,rr.parentModel=s;var d=W(rr.getShallow("z2"),o&&o.itemStyle?p.special:p.normal),v=c&&c.show,m=ln(l,Vi.getItemStyle(),d);t.add(m);var g=rr.get("cursor");g!=null&&m.attr("cursor",g);var y;if(u!=null){var x=u+"";Me.option=o?o.label:null,Me.parentModel=a,Me.ecModel=r;var _=Me.getShallow("formatter");if(_){var b={componentType:"matrix",componentIndex:e.componentIndex,name:x,value:u,coord:i.slice(),$vars:["name","value","coord"]};if(E(_))x=ri(_,b);else if(G(_)){var w=_(b);w!=null&&(x=w+"")}}if(Ne(m,{normal:Me},{defaultText:x,autoOverflowArea:!0,layoutRect:U(m.shape)}),y=m.getTextContent(),y){y.z2=d+1;var C=y.style;if(C&&C.overflow&&C.overflow!=="none"&&C.lineOverflow){var D={};Ct.copy(D,l),Ue(D,(((h=m.style)===null||h===void 0?void 0:h.lineWidth)||0)/2,!0,!0),m.updateInnerText(),y.getLocalTransform(Ui),fr(Ui,Ui),Ct.applyTransform(D,D,Ui),y.setClipPath(new rt({shape:D}))}}Kt({el:m,componentModel:e,itemName:x,itemTooltipOption:c,formatterParamsExtra:{xyLocator:i.slice()}})}var A=e.get("triggerEvent",!0);if(y){var z=Me.get("silent");z==null&&(z=!(A||v)),y.silent=z,y.ignoreHostSilent=!0}var L=rr.get("silent");if(L==null&&(L=!m.style||m.style.fill==="none"||!m.style.fill),m.silent=L,A&&m){var Y={componentType:"matrix",componentIndex:e.componentIndex,matrixIndex:e.componentIndex,targetType:f,name:y&&y.style?y.style.text:void 0,value:u,coord:i.slice()};j(m).eventData=Y}Wr(rr),Wr(Vi),Wr(Me)}var rr=new at,Vi=new at,Me=new at,Ui=[];function ln(i,e,t){var r=e.lineWidth;if(r){var o=i.x+i.width,n=i.y+i.height;i.x=xe(i.x,r,!0),i.y=xe(i.y,r,!0),i.width=xe(o,r,!0)-i.x,i.height=xe(n,r,!0)-i.y}return new rt({shape:i,style:e,z2:t})}function $l(i,e,t){var r=e.lineWidth;return r&&(Ei(i.x1*2)===Ei(i.x2*2)&&(i.x1=i.x2=xe(i.x1,r,!0)),Ei(i.y1*2)===Ei(i.y2*2)&&(i.y1=i.y2=xe(i.y1,r,!0))),new Lt({shape:i,style:e,silent:!0,z2:t})}var Ql=xh;var bh=(function(){function i(e,t,r){this.dimensions=i.dimensions,this.type="matrix",this._model=e;var o=this._dimModels={x:e.getDimensionModel("x"),y:e.getDimensionModel("y")};this._dims={x:o.x.dim,y:o.y.dim},this._resize(e,r)}return i.getDimensionsInfo=function(){return[{name:"x",type:"ordinal"},{name:"y",type:"ordinal"},{name:"value"}]},i.create=function(e,t){var r=[];return e.eachComponent("matrix",function(o){var n=new i(o,e,t);r.push(n),o.coordinateSystem=n}),e.eachComponent(function(o,n){ii({targetModel:n,coordSysType:"matrix",coordSysProvider:oi})}),r},i.prototype.getRect=function(){return this._rect},i.prototype._resize=function(e,t){var r=this._dims,o=this._dimModels,n=this._rect=pt(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()});tu(o,r,n,0),tu(o,r,n,1),eu(0,r),eu(1,r),ru(this._model.getBody(),r),ru(this._model.getCorner(),r)},i.prototype.dataToPoint=function(e,t,r){return r=r||[],this.dataToLayout(e,t,Ar),r[0]=Ar.rect.x+Ar.rect.width/2,r[1]=Ar.rect.y+Ar.rect.height/2,r},i.prototype.dataToLayout=function(e,t,r){var o=this._dims;r=r||{};var n=r.rect=r.rect||{};n.x=n.y=n.width=n.height=NaN;var a=r.matrixXYLocatorRange=ki(r.matrixXYLocatorRange);return I(e)&&(Ri(a,null,e,o,W(t&&t.clamp,Zt.none)),(!t||!t.ignoreMergeCells)&&((!t||t.clamp!==Zt.corner)&&this._model.getBody().expandRangeByCellMerge(a),(!t||t.clamp!==Zt.body)&&this._model.getCorner().expandRangeByCellMerge(a)),en(n,a,o,0),en(n,a,o,1)),r},i.prototype.pointToData=function(e,t,r){var o=this._dims;return iu(jt,0,o,e,t&&t.clamp),iu(jt,1,o,e,t&&t.clamp),r=r||[],r[0]=r[1]=NaN,jt.y===xt.inCorner&&jt.x===xt.inBody?ou(jt,r,0,o):jt.x===xt.inCorner&&jt.y===xt.inBody?ou(jt,r,1,o):(nu(jt,r,0,o),nu(jt,r,1,o)),r},i.prototype.convertToPixel=function(e,t,r,o){var n=pn(t);return n===this?n.dataToPoint(r,o):void 0},i.prototype.convertToLayout=function(e,t,r,o){var n=pn(t);return n===this?n.dataToLayout(r,o):void 0},i.prototype.convertFromPixel=function(e,t,r,o){var n=pn(t);return n===this?n.pointToData(r,o):void 0},i.prototype.containPoint=function(e){return this._rect.contain(e[0],e[1])},i.dimensions=["x","y","value"],i})(),Ar={rect:Te()},Ni=new Nt,un=new Nt;function tu(i,e,t,r){for(var o=1-r,n=e[k[r]],a=e[k[o]],s=a.shouldShow(),l=n.resetCellIterator();l.next();)l.item.wh=l.item.xy=NaN;for(var u=a.resetLayoutIterator(null,r);u.next();)u.item.wh=u.item.xy=NaN;for(var p=t[Tt[r]],c=n.getLocatorCount(r)+a.getLocatorCount(r),f=new at,h=a.resetLevelIterator();h.next();)f.option=h.item.option,f.parentModel=i[k[o]],m(h.item,s?f.get("levelSize"):0);for(var d=new at,v=n.resetCellIterator();v.next();)v.item.type===Ft.leaf&&(d.option=v.item.option,d.parentModel=void 0,m(v.item,d.get("size")));function m(C,D){var A=wh(D,r,t);Yt(A)||(C.wh=cn(A,p),p=cn(p-C.wh),c--)}var g=c?p/c:0,y=!c&&p>=1,x=t[k[r]],_=n.getLocatorCount(r)-1,b=new Nt;for(a.resetLayoutIterator(b,r);b.next();)w(b.item);for(n.resetLayoutIterator(b,r);b.next();)w(b.item);function w(C){Yt(C.wh)&&(C.wh=g),C.xy=x,C.id[k[r]]===_&&!y&&(C.wh=t[k[r]]+t[Tt[r]]-C.xy),x+=C.wh}}function eu(i,e){for(var t=e[k[i]].resetCellIterator();t.next();){var r=t.item;Bi(r.rect,i,r.id,r.span,e),Bi(r.rect,1-i,r.id,r.span,e),r.type===Ft.nonLeaf&&(r.xy=r.rect[k[i]],r.wh=r.rect[Tt[i]])}}function ru(i,e){i.travelExistingCells(function(t){var r=t.span;if(r){var o=t.spanRect,n=t.id;Bi(o,0,n,r,e),Bi(o,1,n,r,e)}})}function Bi(i,e,t,r,o){i[Tt[e]]=0;var n=t[k[e]],a=n<0?o[k[1-e]]:o[k[e]],s=a.getUnitLayoutInfo(e,t[k[e]]);if(i[k[e]]=s.xy,i[Tt[e]]=s.wh,r[k[e]]>1){var l=a.getUnitLayoutInfo(e,t[k[e]]+r[k[e]]-1);i[Tt[e]]=l.xy+l.wh-s.xy}}function wh(i,e,t){var r=_a(i,t[Tt[e]]);return cn(r,t[Tt[e]])}function cn(i,e){return Math.max(Math.min(i,W(e,1/0)),0)}function pn(i){var e=i.matrixModel,t=i.seriesModel,r=e?e.coordinateSystem:t?t.coordinateSystem:null;return r}var xt={inBody:1,inCorner:2,outside:3},jt={x:null,y:null,point:[]};function iu(i,e,t,r,o){var n=t[k[e]],a=t[k[1-e]],s=n.getUnitLayoutInfo(e,n.getLocatorCount(e)-1),l=n.getUnitLayoutInfo(e,0),u=a.getUnitLayoutInfo(e,-a.getLocatorCount(e)),p=a.shouldShow()?a.getUnitLayoutInfo(e,-1):null,c=i.point[e]=r[e];if(!l&&!p){i[k[e]]=xt.outside;return}if(o===Zt.body){l?(i[k[e]]=xt.inBody,c=dt(s.xy+s.wh,ct(l.xy,c)),i.point[e]=c):i[k[e]]=xt.outside;return}else if(o===Zt.corner){p?(i[k[e]]=xt.inCorner,c=dt(p.xy+p.wh,ct(u.xy,c)),i.point[e]=c):i[k[e]]=xt.outside;return}var f=l?l.xy:p?p.xy+p.wh:NaN,h=u?u.xy:f,d=s?s.xy+s.wh:f;if(c<h){if(!o){i[k[e]]=xt.outside;return}c=h}else if(c>d){if(!o){i[k[e]]=xt.outside;return}c=d}i.point[e]=c,i[k[e]]=f<=c&&c<=d?xt.inBody:h<=c&&c<=f?xt.inCorner:xt.outside}function ou(i,e,t,r){var o=1-t;if(i[k[t]]!==xt.outside)for(r[k[t]].resetCellIterator(un);un.next();){var n=un.item;if(au(i.point[t],n.rect,t)&&au(i.point[o],n.rect,o)){e[t]=n.ordinal,e[o]=n.id[k[o]];return}}}function nu(i,e,t,r){if(i[k[t]]!==xt.outside){var o=i[k[t]]===xt.inCorner?r[k[1-t]]:r[k[t]];for(o.resetLayoutIterator(Ni,t);Ni.next();)if(Ch(i.point[t],Ni.item)){e[t]=Ni.item.id[k[t]];return}}}function Ch(i,e){return e.xy<=i&&i<=e.xy+e.wh}function au(i,e,t){return e[k[t]]<=i&&i<=e[k[t]]+e[Tt[t]]}var su=bh;function Th(i){i.registerComponentModel(jl),i.registerComponentView(Ql),i.registerCoordinateSystem("matrix",su)}function Mh(i,e){var t=i.existing;if(e.id=i.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 lu(i,e){var t;return S(e,function(r){i[r]!=null&&i[r]!=="auto"&&(t=!0)}),t}function Ah(i,e,t){var r=N({},t),o=i[e],n=t.$action||"merge";if(n==="merge")if(o){if(0)var a;tt(o,r,!0),Ge(o,r,{ignoreSize:!0}),ns(t,o),Hi(t,o),Hi(t,o,"shape"),Hi(t,o,"style"),Hi(t,o,"extra"),t.clipPath=o.clipPath}else i[e]=r;else n==="replace"?i[e]=r:n==="remove"&&o&&(i[e]=null)}var pu=["transition","enterFrom","leaveTo"],Dh=pu.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function Hi(i,e,t){if(t&&(!i[t]&&e[t]&&(i[t]={}),i=i[t],e=e[t]),!(!i||!e))for(var r=t?pu:Dh,o=0;o<r.length;o++){var n=r[o];i[n]==null&&e[n]!=null&&(i[n]=e[n])}}function Ih(i,e){if(i&&(i.hv=e.hv=[lu(e,["left","right"]),lu(e,["top","bottom"])],i.type==="group")){var t=i,r=e;t.width==null&&(t.width=r.width=0),t.height==null&&(t.height=r.height=0)}}var cu=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t.preventAutoZ=!0,t}return e.prototype.mergeOption=function(t,r){var o=this.option.elements;this.option.elements=null,i.prototype.mergeOption.call(this,t,r),this.option.elements=o},e.prototype.optionUpdated=function(t,r){var o=this.option,n=(r?o:t).elements,a=o.elements=r?[]:o.elements,s=[];this._flatten(n,s,null);var l=Ma(a,s,"normalMerge"),u=this._elOptionsToUpdate=[];S(l,function(p,c){var f=p.newOption;f&&(u.push(f),Mh(p,f),Ah(a,c,f),Ih(a[c],f))},this),o.elements=St(a,function(p){return p&&delete p.$action,p!=null})},e.prototype._flatten=function(t,r,o){S(t,function(n){if(n){o&&(n.parentOption=o),r.push(n);var a=n.children;a&&a.length&&this._flatten(a,r,n),delete n.children}},this)},e.prototype.useElOptionsToUpdate=function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t},e.type="graphic",e.defaultOption={elements:[]},e})(Z);var fu={path:null,compoundPath:null,group:et,image:Kr,text:F},Vt=Q(),vu=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this._elMap=q()},e.prototype.render=function(t,r,o){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,o)},e.prototype._updateElements=function(t){var r=t.useElOptionsToUpdate();if(r){var o=this._elMap,n=this.group,a=t.get("z"),s=t.get("zlevel");S(r,function(l){var u=ye(l.id,null),p=u!=null?o.get(u):null,c=ye(l.parentId,null),f=c!=null?o.get(c):n,h=l.type,d=l.style;h==="text"&&d&&l.hv&&l.hv[1]&&(d.textVerticalAlign=d.textBaseline=d.verticalAlign=d.align=null);var v=l.textContent,m=l.textConfig;if(d&&ws(d,h,!!m,!!v)){var g=Cs(d,h,!0);!m&&g.textConfig&&(m=l.textConfig=g.textConfig),!v&&g.textContent&&(v=g.textContent)}var y=Lh(l),x=l.$action||"merge",_=x==="merge",b=x==="replace";if(_){var w=!p,C=p;w?C=hu(u,f,l.type,o):(C&&(Vt(C).isNew=!1),Ks(C)),C&&(_i(C,y,t,{isInit:w}),du(C,l,a,s))}else if(b){Gi(p,l,o,t);var D=hu(u,f,l.type,o);D&&(_i(D,y,t,{isInit:!0}),du(D,l,a,s))}else x==="remove"&&(Ws(p,l),Gi(p,l,o,t));var A=o.get(u);if(A&&v)if(_){var z=A.getTextContent();z?z.attr(v):A.setTextContent(new F(v))}else b&&A.setTextContent(new F(v));if(A){var L=l.clipPath;if(L){var Y=L.type,P=void 0,w=!1;if(_){var V=A.getClipPath();w=!V||Vt(V).type!==Y,P=w?fn(Y):V}else b&&(w=!0,P=fn(Y));A.setClipPath(P),_i(P,L,t,{isInit:w}),ko(P,L.keyframeAnimation,t)}var $=Vt(A);A.setTextConfig(m),$.option=l,zh(A,t,l),Kt({el:A,componentModel:t,itemName:A.name,itemTooltipOption:l.tooltip}),ko(A,l.keyframeAnimation,t)}})}},e.prototype._relocate=function(t,r){for(var o=t.option.elements,n=this.group,a=this._elMap,s=r.getWidth(),l=r.getHeight(),u=["x","y"],p=0;p<o.length;p++){var c=o[p],f=ye(c.id,null),h=f!=null?a.get(f):null;if(!(!h||!h.isGroup)){var d=h.parent,v=d===n,m=Vt(h),g=Vt(d);m.width=J(m.option.width,v?s:g.width)||0,m.height=J(m.option.height,v?l:g.height)||0}}for(var p=o.length-1;p>=0;p--){var c=o[p],f=ye(c.id,null),h=f!=null?a.get(f):null;if(h){var d=h.parent,g=Vt(d),y=d===n?{width:s,height:l}:{width:g.width,height:g.height},x={},_=He(h,c,y,null,{hv:c.hv,boundingMode:c.bounding},x);if(!Vt(h).isNew&&_){for(var b=c.transition,w={},C=0;C<u.length;C++){var D=u[C],A=x[D];b&&(Xs(b)||st(b,D)>=0)?w[D]=A:h[D]=A}ne(h,w,t,0)}else h.attr(x)}}},e.prototype._clear=function(){var t=this,r=this._elMap;r.each(function(o){Gi(o,Vt(o).option,r,t._lastGraphicModel)}),this._elMap=q()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e})(X);function fn(i){var e=Xt(fu,i)?fu[i]:Ka(i),t=new e({});return Vt(t).type=i,t}function hu(i,e,t,r){var o=fn(t);return e.add(o),r.set(i,o),Vt(o).id=i,Vt(o).isNew=!0,o}function Gi(i,e,t,r){var o=i&&i.parent;o&&(i.type==="group"&&i.traverse(function(n){Gi(n,e,t,r)}),Ys(i,e,r),t.removeKey(Vt(i).id))}function du(i,e,t,r){i.isGroup||S([["cursor",Ea.prototype.cursor],["zlevel",r||0],["z",t||0],["z2",0]],function(o){var n=o[0];Xt(e,n)?i[n]=W(e[n],o[1]):i[n]==null&&(i[n]=o[1])}),S(Nr(e),function(o){if(o.indexOf("on")===0){var n=e[o];i[o]=G(n)?n:null}}),Xt(e,"draggable")&&(i.draggable=e.draggable),e.name!=null&&(i.name=e.name),e.id!=null&&(i.id=e.id)}function Lh(i){return i=N({},i),S(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(rs),function(e){delete i[e]}),i}function zh(i,e,t){var r=j(i).eventData;!i.silent&&!i.ignore&&!r&&(r=j(i).eventData={componentType:"graphic",componentIndex:e.componentIndex,name:i.name}),r&&(r.info=t.info)}function Oh(i){i.registerComponentModel(cu),i.registerComponentView(vu),i.registerPreprocessor(function(e){var t=e.graphic;I(t)?!t[0]||!t[0].elements?e.graphic=[{elements:t}]:e.graphic=[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}var hn=["x","y","radius","angle","single"],Ph=Q(),kh=["cartesian2d","polar","singleAxis"];function mu(i){var e=i.get("coordinateSystem");return st(kh,e)>=0}function Ut(i){return i+"Axis"}function gu(i,e){var t=q(),r=[],o=q();i.eachComponent({mainType:"dataZoom",query:e},function(p){o.get(p.uid)||s(p)});var n;do n=!1,i.eachComponent("dataZoom",a);while(n);function a(p){!o.get(p.uid)&&l(p)&&(s(p),n=!0)}function s(p){o.set(p.uid,!0),r.push(p),u(p)}function l(p){var c=!1;return p.eachTargetAxis(function(f,h){var d=t.get(f);d&&d[h]&&(c=!0)}),c}function u(p){p.eachTargetAxis(function(c,f){(t.get(c)||t.set(c,[]))[f]=!0})}return r}function Fi(i){var e=i.ecModel,t={infoList:[],infoMap:q()};return i.eachTargetAxis(function(r,o){var n=e.getComponent(Ut(r),o);if(n){var a=n.getCoordSysModel();if(a){var s=a.uid,l=t.infoMap.get(s);l||(l={model:a,axisModels:[]},t.infoList.push(l),t.infoMap.set(s,l)),l.axisModels.push(n)}}}),t}function yu(i){var e=Ph(ps(i));return e.axisProxyMap||(e.axisProxyMap=q())}function ir(i){if(i)return yu(i.ecModel).get(i.uid)}function xu(i,e){yu(i.ecModel).set(i.uid,e)}function Zi(i,e){var t=e.getAxisModel().axis.__alignTo;return t&&i.getAxisProxy(t.dim,t.model.componentIndex)?ir(t.model):null}var dn=(function(){function i(){this.indexList=[],this.indexMap=[]}return i.prototype.add=function(e){this.indexMap[e]||(this.indexList.push(e),this.indexMap[e]=!0)},i})(),Rh=(function(i){T(e,i);function e(){var t=i!==null&&i.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,o){var n=_u(t);this.settledOption=n,this.mergeDefaultAndTheme(t,o),this._doInit(n)},e.prototype.mergeOption=function(t){var r=_u(t);tt(this.option,t,!0),tt(this.settledOption,r,!0),this._doInit(r)},e.prototype._doInit=function(t){var r=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var o=this.settledOption;S([["start","startValue"],["end","endValue"]],function(n,a){this._rangePropMode[a]==="value"&&(r[n[0]]=o[n[0]]=null)},this),this._resetTarget()},e.prototype._resetTarget=function(){var t=this.get("orient",!0),r=this._targetAxisInfoMap=q(),o=this._fillSpecifiedTargetAxis(r);o?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(r,this._orient)),this._noTarget=!0,r.each(function(n){n.indexList.length&&(this._noTarget=!1)},this)},e.prototype._fillSpecifiedTargetAxis=function(t){var r=!1;return S(hn,function(o){var n=this.getReferringComponents(Ut(o),Oa);if(n.specified){r=!0;var a=new dn;S(n.models,function(s){a.add(s.componentIndex)}),t.set(o,a)}},this),r},e.prototype._fillAutoTargetAxisByOrient=function(t,r){var o=this.ecModel,n=!0;if(n){var a=r==="vertical"?"y":"x",s=o.findComponents({mainType:a+"Axis"});l(s,a)}if(n){var s=o.findComponents({mainType:"singleAxis",filter:function(p){return p.get("orient",!0)===r}});l(s,"single")}function l(u,p){var c=u[0];if(c){var f=new dn;if(f.add(c.componentIndex),t.set(p,f),n=!1,p==="x"||p==="y"){var h=c.getReferringComponents("grid",Mt).models[0];h&&S(u,function(d){c.componentIndex!==d.componentIndex&&h===d.getReferringComponents("grid",Mt).models[0]&&f.add(d.componentIndex)})}}}n&&S(hn,function(u){if(n){var p=o.findComponents({mainType:Ut(u),filter:function(f){return f.get("type",!0)==="category"}});if(p[0]){var c=new dn;c.add(p[0].componentIndex),t.set(u,c),n=!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,o=this.get("rangeMode");S([["start","startValue"],["end","endValue"]],function(n,a){var s=t[n[0]]!=null,l=t[n[1]]!=null;s&&!l?r[a]="percent":!s&&l?r[a]="value":o?r[a]=o[a]:s&&(r[a]="percent")})},e.prototype.noTarget=function(){return this._noTarget},e.prototype.getFirstTargetAxisModel=function(){var t;return this.eachTargetAxis(function(r,o){t==null&&(t=this.ecModel.getComponent(Ut(r),o))},this),t},e.prototype.eachTargetAxis=function(t,r){this._targetAxisInfoMap.each(function(o,n){S(o.indexList,function(a){t.call(r,n,a)})})},e.prototype.getAxisProxy=function(t,r){return ir(this.getAxisModel(t,r))},e.prototype.getAxisModel=function(t,r){var o=this._targetAxisInfoMap.get(t);if(o&&o.indexMap[r])return this.ecModel.getComponent(Ut(t),r)},e.prototype.setRawRange=function(t){var r=this.option,o=this.settledOption;S([["start","startValue"],["end","endValue"]],function(n){(t[n[0]]!=null||t[n[1]]!=null)&&(r[n[0]]=o[n[0]]=t[n[0]],r[n[1]]=o[n[1]]=t[n[1]])},this),this._updateRangeUse(t)},e.prototype.setCalculatedRange=function(t){var r=this.option;S(["start","startValue","end","endValue"],function(o){r[o]=t[o]})},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 o=this.findRepresentativeAxisProxy();if(o)return o.getWindow().value}else return this.getAxisProxy(t,r).getWindow().value},e.prototype.findRepresentativeAxisProxy=function(t){if(t)return ir(t);for(var r,o=this._targetAxisInfoMap.keys(),n=0;n<o.length;n++)for(var a=o[n],s=this._targetAxisInfoMap.get(a),l=0;l<s.indexList.length;l++){var u=this.getAxisProxy(a,s.indexList[l]);if(u.hostedBy(this))return u;r||(r=u)}return r},e.prototype.getRangePropMode=function(){return this._rangePropMode.slice()},e.prototype.getOrient=function(){return this._orient},e.type="dataZoom",e.dependencies=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","series","toolbox"],e.defaultOption={z:4,filterMode:"filter",start:0,end:100},e})(Z);function _u(i){var e={};return S(["start","end","startValue","endValue","throttle"],function(t){i.hasOwnProperty(t)&&(e[t]=i[t])}),e}var ce=Rh;var Eh=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.select",e})(ce),Su=Eh;var Vh=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,o,n){this.dataZoomModel=t,this.ecModel=r,this.api=o},e.type="dataZoom",e})(X),or=Vh;var Uh=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.select",e})(or),bu=Uh;var Nh=(function(){function i(e,t,r,o){this._dimName=e,this._axisIndex=t,this.ecModel=o,this._dataZoomModel=r}return i.prototype.hostedBy=function(e){return this._dataZoomModel===e},i.prototype.getWindow=function(){return U(this._window)},i.prototype.getTargetSeriesModels=function(){var e=[];return this.ecModel.eachSeries(function(t){if(mu(t)){var r=Ut(this._dimName),o=t.getReferringComponents(r,Mt).models[0];o&&this._axisIndex===o.componentIndex&&e.push(t)}},this),e},i.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},i.prototype.getMinMaxSpan=function(){return U(this._minMaxSpan)},i.prototype.calculateDataWindow=function(e){var t=this._extent,r=this.getAxisModel().axis,o=r.scale,n=this._dataZoomModel,a=n.getRangePropMode(),s=[0,100],l=[],u=[],p,c=[!1,!1];S(["start","end"],function(x,_){var b=e[x],w=e[x+"Value"];a[_]==="percent"?(b==null&&(b=s[_]),w=lt(b,s,t),c[_]=!0):(p=!0,w==null?w=t[_]:(w=o.parse(w),o.sanitize&&(w=o.sanitize(w,t))),b=lt(w,t,s)),u[_]=w==null||isNaN(w)?t[_]:w,l[_]=b==null||isNaN(b)?s[_]:b}),yt(u),yt(l);var f=this._minMaxSpan;p?h(u,l,t,s,!1):h(l,u,s,t,!0);function h(x,_,b,w,C){var D=C?"Span":"ValueSpan";Et(0,x,b,"all",f["min"+D],f["max"+D]);for(var A=0;A<2;A++)_[A]=lt(x[A],b,w,!0),C&&(_[A]=_[A],c[A]=!0);Yr(_)}var d=ci(o)||pi(o),v=r.getExtent(),m=dr(v[1]-v[0]),g=d?0:Hr(u,m,.5);S([[0,xa],[1,ya]],function(x){var _=x[0],b=x[1];!c[_]||!isFinite(g)||(u[_]=ge(u[_],g),u[_]=dt(t[1],ct(t[0],u[_])),l[_]===s[_]&&(u[_]=t[_],d&&(u[_]=b(u[_]))))}),Yr(u);var y=[lt(u[0],t,s,!0),lt(u[1],t,s,!0)];return Yr(y),{value:u,percent:l,percentInverted:y,valuePrecision:g}},i.prototype.reset=function(e,t){if(this.hostedBy(e)){var r=this.getAxisModel().axis;be(r,xs);var o=r.scale.rawExtentInfo;this._extent=o.makeNoZoom(),this._updateMinMaxSpan();var n=e.settledOption;t&&(n=K({start:t[0],end:t[1]},n));var a=this._window=this.calculateDataWindow(n),s=a.percent,l=a.value;s[0]!==0&&o.setZoomMM(0,l[0]),s[1]!==100&&o.setZoomMM(1,l[1])}},i.prototype.filterData=function(e,t){if(!this.hostedBy(e))return;var r=this._dimName,o=this.getTargetSeriesModels(),n=e.get("filterMode"),a=this._window.value;if(n==="none")return;S(o,function(l){var u=l.getData(),p=u.mapDimensionsAll(r);if(p.length){if(n==="weakFilter"){var c=u.getStore(),f=R(p,function(h){return u.getDimensionIndex(h)},u);u.filterSelf(function(h){for(var d,v,m,g=0;g<p.length;g++){var y=c.get(f[g],h),x=!isNaN(y),_=y<a[0],b=y>a[1];if(x&&!_&&!b)return!0;x&&(m=!0),_&&(d=!0),b&&(v=!0)}return m&&d&&v})}else S(p,function(h){if(n==="empty")l.setData(u=u.map(h,function(v){return s(v)?v:NaN}));else{var d={};d[h]=a,u.selectRange(d)}});S(p,function(h){u.setApproximateExtent(a,h)})}});function s(l){return l>=a[0]&&l<=a[1]}},i.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,r=this._extent;S(["min","max"],function(o){var n=t.get(o+"Span"),a=t.get(o+"ValueSpan");a!=null&&(a=this.getAxisModel().axis.scale.parse(a)),a!=null?n=lt(r[0]+a,r,[0,100],!0):n!=null&&(a=lt(n,[0,100],r,!0)-r[0]),e[o+"Span"]=n,e[o+"ValueSpan"]=a},this)},i})(),wu=Nh;var Bh={dirtyOnOverallProgress:!0,getTargetSeries:function(i){function e(o){i.eachComponent("dataZoom",function(n){n.eachTargetAxis(function(a,s){var l=i.getComponent(Ut(a),s);o(a,s,l,n)})})}var t=[];e(function(o,n,a,s){if(!ir(a)){var l=new wu(o,n,s,i);t.push(l),xu(a,l)}});var r=q();return S(t,function(o){S(o.getTargetSeriesModels(),function(n){r.set(n.uid,n)})}),r},overallReset:function(i,e){i.eachComponent("dataZoom",function(t){var r=[];t.eachTargetAxis(function(o,n){var a=t.getAxisProxy(o,n),s=Zi(t,a);s?r.push([a,s]):a.reset(t,null)}),S(r,function(o){o[0].reset(t,o[1].getWindow().percentInverted)}),t.eachTargetAxis(function(o,n){t.getAxisProxy(o,n).filterData(t,e)})}),i.eachComponent("dataZoom",function(t){var r=t.findRepresentativeAxisProxy();if(r){var o=r.getWindow(),n=o.percent,a=o.value;t.setCalculatedRange({start:n[0],end:n[1],startValue:a[0],endValue:a[1]})}})}},Cu=Bh;function vn(i){i.registerAction("dataZoom",function(e,t){var r=gu(t,e);S(r,function(o){o.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}var Hh=Xr();function Ae(i){Hh(i,function(){i.registerProcessor(i.PRIORITY.PROCESSOR.FILTER,Cu),vn(i),i.registerSubTypeDefaulter("dataZoom",function(){return"slider"})})}function Tu(i){i.registerComponentModel(Su),i.registerComponentView(bu),Ae(i)}var _t=(function(){function i(){}return i})();var Mu={};function fe(i,e){Mu[i]=e}function Wi(i){return Mu[i]}var Fh=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r,o){var n=o.getTheme().get("toolbox"),a=n?n.feature:null;a&&(this._themeFeatureOption=N({},a),n.feature={}),i.prototype.init.call(this,t,r,o),a&&(n.feature=a)},e.prototype.optionUpdated=function(){S(this.option.feature,function(t,r){var o=this._themeFeatureOption,n=Wi(r);n&&(n.getDefaultOption&&(n.defaultOption=n.getDefaultOption(this.ecModel)),o&&o[r]&&(tt(t,o[r]),o[r]=null),tt(t,n.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:M.color.border,borderRadius:0,borderWidth:0,padding:M.size.m,itemSize:15,itemGap:M.size.s,showTitle:!0,iconStyle:{borderColor:M.color.accent50,color:"none"},emphasis:{iconStyle:{borderColor:M.color.accent70}},tooltip:{show:!1,position:"bottom"}},e})(Z),Au=Fh;function Yi(i,e){var t=se(e.get("padding")),r=e.getItemStyle(["color","opacity"]);r.fill=e.get("backgroundColor");var o=new rt({shape:{x:i.x-t[3],y:i.y-t[0],width:i.width+t[1]+t[3],height:i.height+t[0]+t[2],r:e.get("borderRadius")},style:r,silent:!0,z2:-1});return o}var Wh=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.render=function(t,r,o,n){var a=this.group;if(a.removeAll(),!t.get("show"))return;var s=+t.get("itemSize"),l=t.get("orient")==="vertical",u=t.get("feature")||{},p=this._features||(this._features=q()),c=[];S(u,function(y,x){c.push(x)}),new vs(this._featureNames||[],c).add(f).update(f).remove(H(f,null)).execute(),this._featureNames=St(c,function(y){return p.hasKey(y)});function f(y,x){var _=y!=null&&x==null,b=y!=null&&x!=null,w=y==null,C=_||b?c[y]:c[x],D=u[C],A=_||b?new at(D,t,r):null,z=A&&A.get("show"),L;if(_){if(!z)return;if(Yh(C))L={onclick:A.option.onclick,featureName:C};else{var Y=Wi(C);if(!Y)return;L=new Y}p.set(C,L)}else L=p.get(C);if(w||!z){Du(L)&&L.dispose&&L.dispose(r,o),p.removeKey(C);return}n&&n.newTitle!=null&&n.featureName===C&&(D.title=n.newTitle),_&&(L.uid=Qa("toolbox-feature")),L.model=A,L.ecModel=r,L.api=o,h(A,L,C),A.setIconStatus=function(P,V){var $=this.option,it=this.iconPaths;$.iconStatus=$.iconStatus||{},$.iconStatus[P]=V,it[P]&&(V==="emphasis"?yo:xo)(it[P])},Du(L)&&L.render&&L.render(A,r,o,n)}function h(y,x,_){var b=y.getModel("iconStyle"),w=y.getModel(["emphasis","iconStyle"]),C=x instanceof _t&&x.getIcons?x.getIcons():y.get("icon"),D=y.get("title")||{},A,z;E(C)?(A={},A[_]=C):A=C,E(D)?(z={},z[_]=D):z=D;var L=y.iconPaths={};S(A,function(Y,P){var V=ae(Y,{},{x:-s/2,y:-s/2,width:s,height:s});V.setStyle(b.getItemStyle());var $=V.ensureState("emphasis");$.style=w.getItemStyle();var it=new F({style:{text:z[P],align:w.get("textAlign"),borderRadius:w.get("textBorderRadius"),padding:w.get("textPadding"),fill:null,font:Ja({fontStyle:w.get("textFontStyle"),fontFamily:w.get("textFontFamily"),fontSize:w.get("textFontSize"),fontWeight:w.get("textFontWeight")},r)},ignore:!0});V.setTextContent(it),Kt({el:V,componentModel:t,itemName:P,formatterParamsExtra:{title:z[P]}}),V.__title=z[P],V.on("mouseover",function(){var Wt=w.getItemStyle(),re=l?t.get("right")==null&&t.get("left")!=="right"?"right":"left":t.get("bottom")==null&&t.get("top")!=="bottom"?"bottom":"top";it.setStyle({fill:w.get("textFill")||Wt.fill||Wt.stroke||M.color.neutral99,backgroundColor:w.get("textBackgroundColor")}),V.setTextConfig({position:w.get("textPosition")||re}),it.ignore=!t.get("showTitle"),o.enterEmphasis(this)}).on("mouseout",function(){y.get(["iconStatus",P])!=="emphasis"&&o.leaveEmphasis(this),it.hide()}),(y.get(["iconStatus",P])==="emphasis"?yo:xo)(V),a.add(V),V.on("click",O(x.onclick,x,r,o,P)),L[P]=V})}var d=gt(t,o).refContainer,v=t.getBoxLayoutParams(),m=t.get("padding"),g=pt(v,d,m);Bt(t.get("orient"),a,t.get("itemGap"),g.width,g.height),He(a,v,d,m),a.add(Yi(a.getBoundingRect(),t)),l||a.eachChild(function(y){var x=y.__title,_=y.ensureState("emphasis"),b=_.textConfig||(_.textConfig={}),w=y.getTextContent(),C=w&&w.ensureState("emphasis");if(C&&!G(C)&&x){var D=C.style||(C.style={}),A=ke(x,F.makeFont(D)),z=y.x+a.x,L=y.y+a.y+s,Y=!1;L+A.height>o.getHeight()&&(b.position="top",Y=!0);var P=Y?-5-A.height:s+10;z+A.width/2>o.getWidth()?(b.position=["100%",P],D.align="right"):z-A.width/2<0&&(b.position=[0,P],D.align="left")}})},e.prototype.updateView=function(t,r,o,n){S(this._features,function(a){a&&a instanceof _t&&a.updateView&&a.updateView(a.model,r,o,n)})},e.prototype.dispose=function(t,r){S(this._features,function(o){o&&o instanceof _t&&o.dispose&&o.dispose(t,r)})},e.type="toolbox",e})(X);function Yh(i){return i.indexOf("my")===0}function Du(i){return i instanceof _t}var Iu=Wh;var Xh=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.onclick=function(t,r){var o=this.model,n=o.get("name")||t.get("title.0.text")||"echarts",a=r.getZr().painter.getType()==="svg",s=a?"svg":o.get("type",!0)||"png",l=r.getConnectedDataURL({type:s,backgroundColor:o.get("backgroundColor",!0)||t.get("backgroundColor")||M.color.neutral00,connectedBackgroundColor:o.get("connectedBackgroundColor"),excludeComponents:o.get("excludeComponents"),pixelRatio:o.get("pixelRatio")}),u=ht.browser;if(typeof MouseEvent=="function"&&(u.newEdge||!u.ie&&!u.edge)){var p=document.createElement("a");p.download=n+"."+s,p.target="_blank",p.href=l;var c=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});p.dispatchEvent(c)}else if(window.navigator.msSaveOrOpenBlob||a){var f=l.split(","),h=f[0].indexOf("base64")>-1,d=a?decodeURIComponent(f[1]):f[1];h&&(d=window.atob(d));var v=n+"."+s;if(window.navigator.msSaveOrOpenBlob){for(var m=d.length,g=new Uint8Array(m);m--;)g[m]=d.charCodeAt(m);var y=new Blob([g]);window.navigator.msSaveOrOpenBlob(y,v)}else{var x=document.createElement("iframe");document.body.appendChild(x);var _=x.contentWindow,b=_.document;b.open("image/svg+xml","replace"),b.write(d),b.close(),_.focus(),b.execCommand("SaveAs",!0,v),document.body.removeChild(x)}}else{var w=o.get("lang"),C='<body style="margin:0;"><img src="'+l+'" style="max-width:100%;" title="'+(w&&w[0]||"")+'" /></body>',D=window.open();D.document.write(C),D.document.title=n}},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:M.color.neutral00,name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])};return r},e})(_t),Lu=Xh;var zu="__ec_magicType_stack__";var Kh=[["line","bar"],["stack"]],qh=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.getIcons=function(){var t=this.model,r=t.get("icon"),o={};return S(t.get("type"),function(n){r[n]&&(o[n]=r[n])}),o},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,o){var n=this.model,a=n.get(["seriesIndex",o]);if(Ou[o]){var s={series:[]},l=function(c){var f=c.subType,h=c.id,d=Ou[o](f,h,c,n);d&&(K(d,c.option),s.series.push(d));var v=c.coordinateSystem;if(v&&v.type==="cartesian2d"&&(o==="line"||o==="bar")){var m=v.getAxesByScale("ordinal")[0];if(m){var g=m.dim,y=g+"Axis",x=c.getReferringComponents(y,Mt).models[0],_=x.componentIndex;s[y]=s[y]||[];for(var b=0;b<=_;b++)s[y][_]=s[y][_]||{};s[y][_].boundaryGap=o==="bar"}}};S(Kh,function(c){st(c,o)>=0&&S(c,function(f){n.setIconStatus(f,"normal")})}),n.setIconStatus(o,"emphasis"),t.eachComponent({mainType:"series",query:a==null?null:{seriesIndex:a}},l);var u,p=o;o==="stack"&&(u=tt({stack:n.option.title.tiled,tiled:n.option.title.stack},n.option.title),n.get(["iconStatus",o])!=="emphasis"&&(p="tiled")),r.dispatchAction({type:"changeMagicType",currentType:p,newOption:s,newTitle:u,featureName:"magicType"})}},e})(_t),Ou={line:function(i,e,t,r){if(i==="bar")return tt({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(i,e,t,r){if(i==="line")return tt({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(i,e,t,r){var o=t.get("stack")===zu;if(i==="line"||i==="bar")return r.setIconStatus("stack",o?"normal":"emphasis"),tt({id:e,stack:o?"":zu},r.get(["option","stack"])||{},!0)}};We({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(i,e){e.mergeOption(i.newOption)});var ku=qh;var Ki=new Array(60).join("-"),nr=" ";function jh(i){var e={},t=[],r=[];return i.eachRawSeries(function(o){var n=o.coordinateSystem;if(n&&(n.type==="cartesian2d"||n.type==="polar")){var a=n.getBaseAxis();if(a.type==="category"){var s=Ms(a);e[s]||(e[s]={categoryAxis:a,valueAxis:n.getOtherAxis(a),series:[]},r.push({axisDim:a.dim,axisIndex:a.index})),e[s].series.push(o)}else t.push(o)}else t.push(o)}),{seriesGroupByCategoryAxis:e,other:t,meta:r}}function $h(i){var e=[];return S(i,function(t,r){var o=t.categoryAxis,n=t.valueAxis,a=n.dim,s=[" "].concat(R(t.series,function(h){return h.name})),l=[o.model.getCategories()];S(t.series,function(h){var d=h.getRawData();l.push(h.getRawData().mapArray(d.mapDimension(a),function(v){return v}))});for(var u=[s.join(nr)],p=0;p<l[0].length;p++){for(var c=[],f=0;f<l.length;f++)c.push(l[f][p]);u.push(c.join(nr))}e.push(u.join(`
2
+ `))}),e.join(`
3
+
4
+ `+Ki+`
5
+
6
+ `)}function Jh(i){return R(i,function(e){var t=e.getRawData(),r=[e.name],o=[];return t.each(t.dimensions,function(){for(var n=arguments.length,a=arguments[n-1],s=t.getName(a),l=0;l<n-1;l++)o[l]=arguments[l];r.push((s?s+nr:"")+o.join(nr))}),r.join(`
7
+ `)}).join(`
8
+
9
+ `+Ki+`
10
+
11
+ `)}function Qh(i){var e=jh(i);return{value:St([$h(e.seriesGroupByCategoryAxis),Jh(e.other)],function(t){return!!t.replace(/[\n\t\s]/g,"")}).join(`
12
+
13
+ `+Ki+`
14
+
15
+ `),meta:e.meta}}function Xi(i){return i.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}function td(i){var e=i.slice(0,i.indexOf(`
16
+ `));if(e.indexOf(nr)>=0)return!0}var mn=new RegExp("["+nr+"]+","g");function ed(i){for(var e=i.split(/\n+/g),t=Xi(e.shift()).split(mn),r=[],o=R(t,function(l){return{name:l,data:[]}}),n=0;n<e.length;n++){var a=Xi(e[n]).split(mn);r.push(a.shift());for(var s=0;s<a.length;s++)o[s]&&(o[s].data[n]=a[s])}return{series:o,categories:r}}function rd(i){for(var e=i.split(/\n+/g),t=Xi(e.shift()),r=[],o=0;o<e.length;o++){var n=Xi(e[o]);if(n){var a=n.split(mn),s="",l=void 0,u=!1;isNaN(a[0])?(u=!0,s=a[0],a=a.slice(1),r[o]={name:s,value:[]},l=r[o].value):l=r[o]=[];for(var p=0;p<a.length;p++)l.push(+a[p]);l.length===1&&(u?r[o].value=l[0]:r[o]=l[0])}}return{name:t,data:r}}function id(i,e){var t=i.split(new RegExp(`
17
+ *`+Ki+`
18
+ *`,"g")),r={series:[]};return S(t,function(o,n){if(td(o)){var a=ed(o),s=e[n],l=s.axisDim+"Axis";s&&(r[l]=r[l]||[],r[l][s.axisIndex]={data:a.categories},r.series=r.series.concat(a.series))}else{var a=rd(o);r.series.push(a)}}),r}var od=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.onclick=function(t,r){setTimeout(function(){r.dispatchAction({type:"hideTip"})});var o=r.getDom(),n=this.model;this._dom&&o.removeChild(this._dom);var a=document.createElement("div");a.style.cssText="position:absolute;top:0;bottom:0;left:0;right:0;padding:5px",a.style.backgroundColor=n.get("backgroundColor")||M.color.neutral00;var s=document.createElement("h4"),l=n.get("lang")||[];s.innerHTML=l[0]||n.get("title"),s.style.cssText="margin:10px 20px",s.style.color=n.get("textColor");var u=document.createElement("div"),p=document.createElement("textarea");u.style.cssText="overflow:auto";var c=n.get("optionToContent"),f=n.get("contentToOption"),h=Qh(t);if(G(c)){var d=c(r.getOption());E(d)?u.innerHTML=d:cr(d)&&u.appendChild(d)}else{p.readOnly=n.get("readOnly");var v=p.style;v.cssText="display:block;width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;resize:none;box-sizing:border-box;outline:none",v.color=n.get("textColor"),v.borderColor=n.get("textareaBorderColor"),v.backgroundColor=n.get("textareaColor"),p.value=h.value,u.appendChild(p)}var m=h.meta,g=document.createElement("div");g.style.cssText="position:absolute;bottom:5px;left:0;right:0";var y="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",x=document.createElement("div"),_=document.createElement("div");y+=";background-color:"+n.get("buttonColor"),y+=";color:"+n.get("buttonTextColor");var b=this;function w(){o.removeChild(a),b._dom=null}ho(x,"click",w),ho(_,"click",function(){if(f==null&&c!=null||f!=null&&c==null){w();return}var C;try{G(f)?C=f(u,r.getOption()):C=id(p.value,m)}catch(D){throw w(),new Error("Data view format error "+D)}C&&r.dispatchAction({type:"changeDataView",newOption:C}),w()}),x.innerHTML=l[1],_.innerHTML=l[2],_.style.cssText=x.style.cssText=y,!n.get("readOnly")&&g.appendChild(_),g.appendChild(x),a.appendChild(s),a.appendChild(u),a.appendChild(g),u.style.height=o.clientHeight-80+"px",o.appendChild(a),this._dom=a},e.prototype.dispose=function(t,r){this._dom&&r.getDom().removeChild(this._dom)},e.getDefaultOption=function(t){var r={show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:"M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28",title:t.getLocaleModel().get(["toolbox","dataView","title"]),lang:t.getLocaleModel().get(["toolbox","dataView","lang"]),backgroundColor:M.color.background,textColor:M.color.primary,textareaColor:M.color.background,textareaBorderColor:M.color.border,buttonColor:M.color.accent50,buttonTextColor:M.color.neutral00};return r},e})(_t);function nd(i,e){return R(i,function(t,r){var o=e&&e[r];if(ot(o)&&!I(o)){var n=ot(t)&&!I(t);n||(t={value:t});var a=o.name!=null&&t.name==null;return t=K(t,o),a&&delete t.name,t}else return t})}We({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(i,e){var t=[];S(i.newOption.series,function(r){var o=e.getSeriesByName(r.name)[0];if(!o)t.push(N({type:"scatter"},r));else{var n=o.get("data");t.push({name:r.name,data:nd(r.data,n)})}}),e.mergeOption(K({series:t},i.newOption))});var Ru=od;var Eu=S,Vu=Q();function Uu(i,e){var t=gn(i);Eu(e,function(r,o){for(var n=t.length-1;n>=0;n--){var a=t[n];if(a[o])break}if(n<0){var s=i.queryComponents({mainType:"dataZoom",subType:"select",id:o})[0];if(s){var l=s.getPercentRange();t[0][o]={dataZoomId:o,start:l[0],end:l[1]}}}}),t.push(e)}function Nu(i){var e=gn(i),t=e[e.length-1];e.length>1&&e.pop();var r={};return Eu(t,function(o,n){for(var a=e.length-1;a>=0;a--)if(o=e[a][n],o){r[n]=o;break}}),r}function Bu(i){Vu(i).snapshots=null}function Hu(i){return gn(i).length}function gn(i){var e=Vu(i);return e.snapshots||(e.snapshots=[{}]),e.snapshots}var ad=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.onclick=function(t,r){Bu(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})(_t);We({type:"restore",event:"restore",update:"prepareAndUpdate"},function(i,e){e.resetOption("recreate")});var Fu=ad;var sd=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],ld=(function(){function i(e,t,r){var o=this;this._targetInfoList=[];var n=Zu(t,e);S(ud,function(a,s){(!r||!r.include||st(r.include,s)>=0)&&a(n,o._targetInfoList)})}return i.prototype.setOutputRanges=function(e,t){return this.matchOutputRanges(e,t,function(r,o,n){if((r.coordRanges||(r.coordRanges=[])).push(o),!r.coordRange){r.coordRange=o;var a=yn[r.brushType](0,n,o);r.__rangeOffset={offset:Ku[r.brushType](a.values,r.range,[1,1]),xyMinMax:a.xyMinMax}}}),e},i.prototype.matchOutputRanges=function(e,t,r){S(e,function(o){var n=this.findTargetInfo(o,t);n&&n!==!0&&S(n.coordSyses,function(a){var s=yn[o.brushType](1,a,o.range,!0);r(o,s.values,a,t)})},this)},i.prototype.setInputRanges=function(e,t){S(e,function(r){var o=this.findTargetInfo(r,t);if(r.range=r.range||[],o&&o!==!0){r.panelId=o.panelId;var n=yn[r.brushType](0,o.coordSys,r.coordRange),a=r.__rangeOffset;r.range=a?Ku[r.brushType](n.values,a.offset,pd(n.xyMinMax,a.xyMinMax)):n.values}},this)},i.prototype.makePanelOpts=function(e,t){return R(this._targetInfoList,function(r){var o=r.getPanelRect();return{panelId:r.panelId,defaultBrushType:t?t(r):null,clipPath:Gs(o),isTargetByCursor:Zs(o,e,r.coordSysModel),getLinearBrushOtherExtent:Fs(o)}})},i.prototype.controlSeries=function(e,t,r){var o=this.findTargetInfo(e,r);return o===!0||o&&st(o.coordSyses,t.coordinateSystem)>=0},i.prototype.findTargetInfo=function(e,t){for(var r=this._targetInfoList,o=Zu(t,e),n=0;n<r.length;n++){var a=r[n],s=e.panelId;if(s){if(a.panelId===s)return a}else for(var l=0;l<Wu.length;l++)if(Wu[l](o,a))return a}return!0},i})();function xn(i){return i[0]>i[1]&&i.reverse(),i}function Zu(i,e){return Fr(i,e,{includeMainTypes:sd})}var ud={grid:function(i,e){var t=i.xAxisModels,r=i.yAxisModels,o=i.gridModels,n=q(),a={},s={};!t&&!r&&!o||(S(t,function(l){var u=l.axis.grid.model;n.set(u.id,u),a[u.id]=!0}),S(r,function(l){var u=l.axis.grid.model;n.set(u.id,u),s[u.id]=!0}),S(o,function(l){n.set(l.id,l),a[l.id]=!0,s[l.id]=!0}),n.each(function(l){var u=l.coordinateSystem,p=[];S(u.getCartesians(),function(c,f){(st(t,c.getAxis("x").model)>=0||st(r,c.getAxis("y").model)>=0)&&p.push(c)}),e.push({panelId:"grid--"+l.id,gridModel:l,coordSysModel:l,coordSys:p[0],coordSyses:p,getPanelRect:Yu.grid,xAxisDeclared:a[l.id],yAxisDeclared:s[l.id]})}))},geo:function(i,e){S(i.geoModels,function(t){var r=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:r,coordSyses:[r],getPanelRect:Yu.geo})})}},Wu=[function(i,e){var t=i.xAxisModel,r=i.yAxisModel,o=i.gridModel;return!o&&t&&(o=t.axis.grid.model),!o&&r&&(o=r.axis.grid.model),o&&o===e.gridModel},function(i,e){var t=i.geoModel;return t&&t===e.geoModel}],Yu={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var i=this.coordSys.view,e=Es(null,i);return va(e,e,yi(null,i)),e}},yn={lineX:H(Xu,0),lineY:H(Xu,1),rect:function(i,e,t,r){var o=i?e.pointToData([t[0][0],t[1][0]],r):e.dataToPoint([t[0][0],t[1][0]],r),n=i?e.pointToData([t[0][1],t[1][1]],r):e.dataToPoint([t[0][1],t[1][1]],r),a=[xn([o[0],n[0]]),xn([o[1],n[1]])];return{values:a,xyMinMax:a}},polygon:function(i,e,t,r){var o=[Re(),Re()],n=R(t,function(a){var s=i?e.pointToData(a,r):e.dataToPoint(a,r);return o[0][0]=Math.min(o[0][0],s[0]),o[1][0]=Math.min(o[1][0],s[1]),o[0][1]=Math.max(o[0][1],s[0]),o[1][1]=Math.max(o[1][1],s[1]),s});return{values:n,xyMinMax:o}}};function Xu(i,e,t,r){var o=t.getAxis(["x","y"][i]),n=xn(R([0,1],function(s){return e?o.coordToData(o.toLocalCoord(r[s]),!0):o.toGlobalCoord(o.dataToCoord(r[s]))})),a=[];return a[i]=n,a[1-i]=[NaN,NaN],{values:n,xyMinMax:a}}var Ku={lineX:H(qu,0),lineY:H(qu,1),rect:function(i,e,t){return[[i[0][0]-t[0]*e[0][0],i[0][1]-t[0]*e[0][1]],[i[1][0]-t[1]*e[1][0],i[1][1]-t[1]*e[1][1]]]},polygon:function(i,e,t){return R(i,function(r,o){return[r[0]-t[0]*e[o][0],r[1]-t[1]*e[o][1]]})}};function qu(i,e,t,r){return[e[0]-r[i]*t[0],e[1]-r[i]*t[1]]}function pd(i,e){var t=ju(i),r=ju(e),o=[t[0]/r[0],t[1]/r[1]];return isNaN(o[0])&&(o[0]=1),isNaN(o[1])&&(o[1]=1),o}function ju(i){return i?[i[0][1]-i[0][0],i[1][1]-i[1][0]]:[NaN,NaN]}var Dr=ld;var _n=S,cd=Da("toolbox-dataZoom_");var fd={x:"width",y:"height"},hd=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.render=function(t,r,o,n){this._brushController||(this._brushController=new xi(o.getZr()),this._brushController.on("brush",O(this._onBrush,this)).mount()),md(t,r,this,n,o),vd(t,r)},e.prototype.onclick=function(t,r,o){dd[o].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 o={},n=this.ecModel;this._brushController.updateCovers([]);var a=new Dr(Sn(this.model),n,{include:["grid"]});a.matchOutputRanges(r,n,function(u,p,c){if(c.type==="cartesian2d"){var f=c.master.getRect().clone(),h=u.brushType;h==="rect"?(s("x",c,f,p[0]),s("y",c,f,p[1])):s({lineX:"x",lineY:"y"}[h],c,f,p)}}),Uu(n,o),this._dispatchZoomAction(o);function s(u,p,c,f){var h=p.getAxis(u),d=h.model,v=l(u,d,n),m=v.findRepresentativeAxisProxy(d).getMinMaxSpan(),g=h.scale.getExtent();(m.minValueSpan!=null||m.maxValueSpan!=null)&&(f=Et(0,f.slice(),g,0,m.minValueSpan,m.maxValueSpan));var y=Hr(g,c[fd[u]],.5);v&&(o[v.id]={dataZoomId:v.id,startValue:isFinite(y)?ge(f[0],y):f[0],endValue:isFinite(y)?ge(f[1],y):f[1]})}function l(u,p,c){var f;return c.eachComponent({mainType:"dataZoom",subType:"select"},function(h){var d=h.getAxisModel(u,p.componentIndex);d&&(f=h)}),f}},e.prototype._dispatchZoomAction=function(t){var r=[];_n(t,function(o,n){r.push(U(o))}),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:M.color.backgroundTint}};return r},e})(_t),dd={zoom:function(){var i=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:i})},back:function(){this._dispatchZoomAction(Nu(this.ecModel))}};function Sn(i){var e={xAxisIndex:i.get("xAxisIndex",!0),yAxisIndex:i.get("yAxisIndex",!0),xAxisId:i.get("xAxisId",!0),yAxisId:i.get("yAxisId",!0)};return e.xAxisIndex==null&&e.xAxisId==null&&(e.xAxisIndex="all"),e.yAxisIndex==null&&e.yAxisId==null&&(e.yAxisIndex="all"),e}function vd(i,e){i.setIconStatus("back",Hu(e)>1?"emphasis":"normal")}function md(i,e,t,r,o){var n=t._isZoomActive;r&&r.type==="takeGlobalCursor"&&(n=r.key==="dataZoomSelect"?r.dataZoomSelectActive:!1),t._isZoomActive=n,i.setIconStatus("zoom",n?"emphasis":"normal");var a=new Dr(Sn(i),e,{include:["grid"]}),s=a.makePanelOpts(o,function(l){return l.xAxisDeclared&&!l.yAxisDeclared?"lineX":!l.xAxisDeclared&&l.yAxisDeclared?"lineY":"rect"});t._brushController.setPanels(s).enableBrush(n&&s.length?{brushType:"auto",brushStyle:i.getModel("brushStyle").getItemStyle()}:!1)}as("dataZoom",function(i){var e=i.getComponent("toolbox",0),t=["feature","dataZoom"];if(!e||e.get(t)==null)return;var r=e.getModel(t),o=[],n=Sn(r),a=Fr(i,n);_n(a.xAxisModels,function(l){return s(l,"xAxis","xAxisIndex")}),_n(a.yAxisModels,function(l){return s(l,"yAxis","yAxisIndex")});function s(l,u,p){var c=l.componentIndex,f={type:"select",$fromToolbox:!0,filterMode:r.get("filterMode",!0)||"filter",id:cd+u+c};f[p]=c,o.push(f)}return o});var $u=hd;function gd(i){i.registerComponentModel(Au),i.registerComponentView(Iu),fe("saveAsImage",Lu),fe("magicType",ku),fe("dataView",Ru),fe("dataZoom",$u),fe("restore",Fu),ft(Tu)}var yd=(function(i){T(e,i);function e(){var t=i!==null&&i.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:M.color.neutral00,shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,defaultBorderColor:M.color.border,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:M.color.borderShade,width:1,type:"dashed",textStyle:{}}},textStyle:{color:M.color.tertiary,fontSize:14}},e})(Z),Ju=yd;function qi(i){var e=i.get("confine");return e!=null?!!e:i.get("renderMode")==="richText"}function Qu(i){if(ht.domSupported){for(var e=document.documentElement.style,t=0,r=i.length;t<r;t++)if(i[t]in e)return i[t]}}var bn=Qu(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),tp=Qu(["webkitTransition","transition","OTransition","MozTransition","msTransition"]);function wn(i,e){if(!i)return e;e=ei(e,!0);var t=i.indexOf(e);return i=t===-1?e:"-"+i.slice(0,t)+"-"+e,i.toLowerCase()}function ep(i,e){var t=i.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(i);return t?e?t[e]:t:null}var xd=wn(tp,"transition"),Cn=wn(bn,"transform"),_d="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(ht.transform3dSupported?"will-change:transform;":"");function Sd(i){return i=i==="left"?"right":i==="right"?"left":i==="top"?"bottom":"top",i}function bd(i,e,t){if(!E(t)||t==="inside")return"";var r=i.get("backgroundColor"),o=i.get("borderWidth");e=Be(e);var n=Sd(t),a=Math.max(Math.round(o)*1.5,6),s="",l=Cn+":",u;st(["left","right"],n)>-1?(s+="top:50%",l+="translateY(-50%) rotate("+(u=n==="left"?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(u=n==="top"?225:45)+"deg)");var p=u*Math.PI/180,c=a+o,f=c*Math.abs(Math.cos(p))+c*Math.abs(Math.sin(p)),h=Math.round(((f-Math.SQRT2*o)/2+Math.SQRT2*o-(f-c)/2)*100)/100;s+=";"+n+":-"+h+"px";var d=e+" solid "+o+"px;",v=["position:absolute;width:"+a+"px;height:"+a+"px;z-index:-1;",s+";"+l+";","border-bottom:"+d,"border-right:"+d,"background-color:"+r+";"];return'<div style="'+v.join("")+'"></div>'}function wd(i,e,t){var r="cubic-bezier(0.23,1,0.32,1)",o="",n="";return t&&(o=" "+i/2+"s "+r,n="opacity"+o+",visibility"+o),e||(o=" "+i+"s "+r,n+=(n.length?",":"")+(ht.transformSupported?""+Cn+o:",left"+o+",top"+o)),xd+":"+n}function rp(i,e,t){var r=i.toFixed(0)+"px",o=e.toFixed(0)+"px";if(!ht.transformSupported)return t?"top:"+o+";left:"+r+";":[["top",o],["left",r]];var n=ht.transform3dSupported,a="translate"+(n?"3d":"")+"("+r+","+o+(n?",0":"")+")";return t?"top:0;left:0;"+Cn+":"+a+";":[["top",0],["left",0],[bn,a]]}function Cd(i){var e=[],t=i.get("fontSize"),r=i.getTextColor();r&&e.push("color:"+r),e.push("font:"+i.getFont());var o=W(i.get("lineHeight"),Math.round(t*3/2));t&&e.push("line-height:"+o+"px");var n=i.get("textShadowColor"),a=i.get("textShadowBlur")||0,s=i.get("textShadowOffsetX")||0,l=i.get("textShadowOffsetY")||0;return n&&a&&e.push("text-shadow:"+s+"px "+l+"px "+a+"px "+n),S(["decoration","align"],function(u){var p=i.get(u);p&&e.push("text-"+u+":"+p)}),e.join(";")}function Td(i,e,t,r){var o=[],n=i.get("transitionDuration"),a=i.get("backgroundColor"),s=i.get("shadowBlur"),l=i.get("shadowColor"),u=i.get("shadowOffsetX"),p=i.get("shadowOffsetY"),c=i.getModel("textStyle"),f=ai(i,"html"),h=u+"px "+p+"px "+s+"px "+l;return o.push("box-shadow:"+h),e&&n>0&&o.push(wd(n,t,r)),a&&o.push("background-color:"+a),S(["width","color","radius"],function(d){var v="border-"+d,m=ei(v),g=i.get(m);g!=null&&o.push(v+":"+g+(d==="color"?"":"px"))}),o.push(Cd(c)),f!=null&&o.push("padding:"+se(f).join("px ")+"px"),o.join(";")+";"}function ip(i,e,t,r,o){var n=e&&e.painter;if(t){var a=n&&n.getViewportRoot();a&&pa(i,a,t,r,o)}else{i[0]=r,i[1]=o;var s=n&&n.getViewportRootOffset();s&&(i[0]+=s.offsetLeft,i[1]+=s.offsetTop)}i[2]=i[0]/e.getWidth(),i[3]=i[1]/e.getHeight()}var Md=(function(){function i(e,t){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,ht.wxa)return null;var r=document.createElement("div");r.domBelongToZr=!0,this.el=r;var o=this._zr=e.getZr(),n=t.appendTo,a=n&&(E(n)?document.querySelector(n):cr(n)?n:G(n)&&n(e.getDom()));ip(this._styleCoord,o,a,e.getWidth()/2,e.getHeight()/2),(a||e.getDom()).appendChild(r),this._api=e,this._container=a;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=o.handler,p=o.painter.getViewportRoot();ha(p,l,!0),u.dispatch("mousemove",l)}},r.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return i.prototype.update=function(e){if(!this._container){var t=this._api.getDom(),r=ep(t,"position"),o=t.style;o.position!=="absolute"&&r!=="absolute"&&(o.position="relative")}var n=e.get("alwaysShowContent");n&&this._moveIfResized(),this._alwaysShowContent=n,this._enableDisplayTransition=e.get("displayTransition")&&e.get("transitionDuration")>0,this.el.className=e.get("className")||""},i.prototype.show=function(e,t){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var r=this.el,o=r.style,n=this._styleCoord;r.innerHTML?o.cssText=_d+Td(e,!this._firstShow,this._longHide,this._enableDisplayTransition)+rp(n[0],n[1],!0)+("border-color:"+Be(t)+";")+(e.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):o.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},i.prototype.setContent=function(e,t,r,o,n){var a=this.el;if(e==null){a.innerHTML="";return}var s="";if(E(n)&&r.get("trigger")==="item"&&!qi(r)&&(s=bd(r,o,n)),E(e))a.innerHTML=e+s;else if(e){a.innerHTML="",I(e)||(e=[e]);for(var l=0;l<e.length;l++)cr(e[l])&&e[l].parentNode!==a&&a.appendChild(e[l]);if(s&&a.childNodes.length){var u=document.createElement("div");u.innerHTML=s,a.appendChild(u)}}},i.prototype.setEnterable=function(e){this._enterable=e},i.prototype.getSize=function(){var e=this.el;return e?[e.offsetWidth,e.offsetHeight]:[0,0]},i.prototype.moveTo=function(e,t){if(this.el){var r=this._styleCoord;if(ip(r,this._zr,this._container,e,t),r[0]!=null&&r[1]!=null){var o=this.el.style,n=rp(r[0],r[1]);S(n,function(a){o[a[0]]=a[1]})}}},i.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},i.prototype.hide=function(){var e=this,t=this.el.style;this._enableDisplayTransition?(t.visibility="hidden",t.opacity="0"):t.display="none",ht.transform3dSupported&&(t.willChange=""),this._show=!1,this._longHideTimeout=setTimeout(function(){return e._longHide=!0},500)},i.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(O(this.hide,this),e)):this.hide())},i.prototype.isShow=function(){return this._show},i.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var e=this._zr;ca(e&&e.painter&&e.painter.getViewportRoot(),this._container);var t=this.el;if(t){t.onmouseenter=t.onmousemove=t.onmouseleave=null;var r=t.parentNode;r&&r.removeChild(t)}this.el=this._container=null},i})(),op=Md;var Ad=(function(){function i(e){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=e.getZr(),ap(this._styleCoord,this._zr,e.getWidth()/2,e.getHeight()/2)}return i.prototype.update=function(e){var t=e.get("alwaysShowContent");t&&this._moveIfResized(),this._alwaysShowContent=t},i.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},i.prototype.setContent=function(e,t,r,o,n){var a=this;ot(e)&&ut(""),this.el&&this._zr.remove(this.el);var s=r.getModel("textStyle");this.el=new F({style:{rich:t.richTextStyles,text:e,lineHeight:22,borderWidth:1,borderColor:o,textShadowColor:s.get("textShadowColor"),fill:r.get(["textStyle","color"]),padding:ai(r,"richText"),verticalAlign:"top",align:"left"},z:r.get("z")}),S(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],function(u){a.el.style[u]=r.get(u)}),S(["textShadowBlur","textShadowOffsetX","textShadowOffsetY"],function(u){a.el.style[u]=s.get(u)||0}),this._zr.add(this.el);var l=this;this.el.on("mouseover",function(){l._enterable&&(clearTimeout(l._hideTimeout),l._show=!0),l._inContent=!0}),this.el.on("mouseout",function(){l._enterable&&l._show&&l.hideLater(l._hideDelay),l._inContent=!1})},i.prototype.setEnterable=function(e){this._enterable=e},i.prototype.getSize=function(){var e=this.el,t=this.el.getBoundingRect(),r=np(e.style);return[t.width+r.left+r.right,t.height+r.top+r.bottom]},i.prototype.moveTo=function(e,t){var r=this.el;if(r){var o=this._styleCoord;ap(o,this._zr,e,t),e=o[0],t=o[1];var n=r.style,a=he(n.borderWidth||0),s=np(n);r.x=e+a+s.left,r.y=t+a+s.top,r.markRedraw()}},i.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},i.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},i.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(O(this.hide,this),e)):this.hide())},i.prototype.isShow=function(){return this._show},i.prototype.dispose=function(){this._zr.remove(this.el)},i})();function he(i){return Math.max(0,i)}function np(i){var e=he(i.shadowBlur||0),t=he(i.shadowOffsetX||0),r=he(i.shadowOffsetY||0);return{left:he(e-t),right:he(e+t),top:he(e-r),bottom:he(e+r)}}function ap(i,e,t,r){i[0]=t,i[1]=r,i[2]=i[0]/e.getWidth(),i[3]=i[1]/e.getHeight()}var sp=Ad;var Dd=new rt({shape:{x:-1,y:-1,width:2,height:2}}),Id=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r){if(!(ht.node||!r.getDom())){var o=t.getComponent("tooltip"),n=this._renderMode=Pa(o.get("renderMode"));this._tooltipContent=n==="richText"?new sp(r):new op(r,{appendTo:o.get("appendToBody",!0)?"body":o.get("appendTo",!0)})}},e.prototype.render=function(t,r,o){if(!(ht.node||!o.getDom())){this.group.removeAll(),this._tooltipModel=t,this._ecModel=r,this._api=o;var n=this._tooltipContent;n.update(t),n.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow(),this._renderMode!=="richText"&&t.get("transitionDuration")?qt(this,"_updatePosition",50,"fixRate"):Se(this,"_updatePosition")}},e.prototype._initGlobalListener=function(){var t=this._tooltipModel,r=t.get("triggerOn");Ci("itemTooltip",this._api,O(function(o,n,a){r!=="none"&&(r.indexOf(o)>=0?this._tryShow(n,a):o==="leave"&&this._hide(a))},this))},e.prototype._keepShow=function(){var t=this._tooltipModel,r=this._ecModel,o=this._api,n=t.get("triggerOn");if(t.get("trigger")!=="axis"&&(this._lastDataByCoordSys=null,this._cbParamsList=null),this._lastX!=null&&this._lastY!=null&&n!=="none"&&n!=="click"){var a=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!o.isDisposed()&&a.manuallyShowTip(t,r,o,{x:a._lastX,y:a._lastY,dataByCoordSys:a._lastDataByCoordSys})})}},e.prototype.manuallyShowTip=function(t,r,o,n){if(!(n.from===this.uid||ht.node||!o.getDom())){var a=lp(n,o);this._ticket="";var s=n.dataByCoordSys,l=Pd(n,r,o);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:n.position,positionDefault:"bottom"},a)}else if(n.tooltip&&n.x!=null&&n.y!=null){var p=Dd;p.x=n.x,p.y=n.y,p.update(),j(p).tooltipConfig={name:null,option:n.tooltip},this._tryShow({offsetX:n.x,offsetY:n.y,target:p},a)}else if(s)this._tryShow({offsetX:n.x,offsetY:n.y,position:n.position,dataByCoordSys:s,tooltipOption:n.tooltipOption},a);else if(n.seriesIndex!=null){if(this._manuallyAxisShowTip(t,r,o,n))return;var c=Cr(n,r),f=c.point[0],h=c.point[1];f!=null&&h!=null&&this._tryShow({offsetX:f,offsetY:h,target:c.el,position:n.position,positionDefault:"bottom"},a)}else n.x!=null&&n.y!=null&&(o.dispatchAction({type:"updateAxisPointer",x:n.x,y:n.y}),this._tryShow({offsetX:n.x,offsetY:n.y,position:n.position,target:o.getZr().findHover(n.x,n.y).target},a))}},e.prototype.manuallyHideTip=function(t,r,o,n){var a=this._tooltipContent;this._tooltipModel&&a.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,this._cbParamsList=null,n.from!==this.uid&&this._hide(lp(n,o))},e.prototype._manuallyAxisShowTip=function(t,r,o,n){var a=n.seriesIndex,s=n.dataIndex,l=r.getComponent("axisPointer").coordSysAxesInfo;if(!(a==null||s==null||l==null)){var u=r.getSeriesByIndex(a);if(u){var p=u.getData(),c=Ir([p.getItemModel(s),u,(u.coordinateSystem||{}).model],this._tooltipModel);if(c.get("trigger")==="axis")return o.dispatchAction({type:"updateAxisPointer",seriesIndex:a,dataIndex:s,position:n.position}),!0}}},e.prototype._tryShow=function(t,r){var o=t.target,n=this._tooltipModel;if(n){this._lastX=t.offsetX,this._lastY=t.offsetY;var a=t.dataByCoordSys;if(a&&a.length)this._showAxisTooltip(a,t);else if(o){var s=j(o);if(s.ssrType==="legend")return;this._lastDataByCoordSys=null,this._cbParamsList=null;var l,u;li(o,function(p){if(p.tooltipDisabled)return l=u=null,!0;l||u||(j(p).dataIndex!=null?l=p:j(p).tooltipConfig!=null&&(u=p))},!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 o=t.get("showDelay");r=O(r,this),clearTimeout(this._showTimout),o>0?this._showTimout=setTimeout(r,o):r()},e.prototype._showAxisTooltip=function(t,r){var o=this._ecModel,n=this._tooltipModel,a=[r.offsetX,r.offsetY],s=Ir([r.tooltipOption],n),l=this._renderMode,u=[],p=le("section",{blocks:[],noHeader:!0}),c=[],f=new si;S(t,function(y){S(y.dataByAxis,function(x){var _=o.getComponent(x.axisDim+"Axis",x.axisIndex),b=x.value,w=_.axis,C=w.scale.parse(b);if(!(!_||b==null)){var D=Bo(b,w,o,x.seriesDataIndices,x.valueLabelOpt),A=le("section",{header:D,noHeader:!ua(D),sortBlocks:!0,blocks:[]});p.blocks.push(A),S(x.seriesDataIndices,function(z){var L=o.getSeriesByIndex(z.seriesIndex),Y=z.dataIndexInside,P=L.getDataParams(Y);if(!(P.dataIndex<0)){P.axisDim=x.axisDim,P.axisIndex=x.axisIndex,P.axisType=x.axisType,P.axisId=x.axisId,P.axisValue=hi(_.axis,{value:C}),P.axisValueLabel=D,P.marker=f.makeTooltipMarker("item",Be(P.color),l);var V=wo(L.formatTooltip(Y,!0,null)),$=V.frag;if($){var it=Ir([L],n).get("valueFormatter");A.blocks.push(it?N({valueFormatter:it},$):$)}V.text&&c.push(V.text),u.push(P)}})}})}),p.blocks.reverse(),c.reverse();var h=r.position,d=s.get("order"),v=To(p,f,l,d,o.get("useUTC"),s.get("textStyle"));v&&c.unshift(v);var m=l==="richText"?`
19
+
20
+ `:"<br/>",g=c.join(m);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(t,u)?this._updatePosition(s,h,a[0],a[1],this._tooltipContent,u):this._showTooltipContent(s,g,u,Math.random()+"",a[0],a[1],h,null,f)})},e.prototype._showSeriesItemTooltip=function(t,r,o){var n=this._ecModel,a=j(r),s=a.seriesIndex,l=n.getSeriesByIndex(s),u=a.dataModel||l,p=a.dataIndex,c=a.dataType,f=u.getData(c),h=this._renderMode,d=t.positionDefault,v=Ir([f.getItemModel(p),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,d?{position:d}:null),m=v.get("trigger");if(!(m!=null&&m!=="item")){var g=u.getDataParams(p,c),y=new si;g.marker=y.makeTooltipMarker("item",Be(g.color),h);var x=wo(u.formatTooltip(p,!1,c)),_=v.get("order"),b=v.get("valueFormatter"),w=x.frag,C=w?To(b?N({valueFormatter:b},w):w,y,h,_,n.get("useUTC"),v.get("textStyle")):x.text,D="item_"+u.name+"_"+p;this._showOrMove(v,function(){this._showTooltipContent(v,C,g,D,t.offsetX,t.offsetY,t.position,t.target,y)}),o({type:"showTip",dataIndexInside:p,dataIndex:f.getRawIndex(p),seriesIndex:s,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,r,o){var n=this._renderMode==="html",a=j(r),s=a.tooltipConfig,l=s.option||{},u=l.encodeHTMLContent;if(E(l)){var p=l;l={content:p,formatter:p},u=!0}u&&n&&l.content&&(l=U(l),l.content=fa(l.content));var c=[l],f=this._ecModel.getComponent(a.componentMainType,a.componentIndex);f&&c.push(f),c.push({formatter:l.content});var h=t.positionDefault,d=Ir(c,this._tooltipModel,h?{position:h}:null),v=d.get("content"),m=Math.random()+"",g=new si;this._showOrMove(d,function(){var y=U(d.get("formatterParams")||{});this._showTooltipContent(d,v,y,m,t.offsetX,t.offsetY,t.position,r,g)}),o({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(t,r,o,n,a,s,l,u,p){if(this._ticket="",!(!t.get("showContent")||!t.get("show"))){var c=this._tooltipContent;c.setEnterable(t.get("enterable"));var f=t.get("formatter");l=l||t.get("position");var h=r,d=this._getNearestPoint([a,s],o,t.get("trigger"),t.get("borderColor"),t.get("defaultBorderColor",!0)),v=d.color;if(f)if(E(f)){var m=t.ecModel.get("useUTC"),g=I(o)?o[0]:o,y=g&&g.axisType&&g.axisType.indexOf("time")>=0;h=f,y&&(h=ts(g.axisValue,h,m)),h=es(h,o,!0)}else if(G(f)){var x=O(function(_,b){_===this._ticket&&(c.setContent(b,p,t,v,l),this._updatePosition(t,l,a,s,c,o,u))},this);this._ticket=n,h=f(o,n,x)}else h=f;c.setContent(h,p,t,v,l),c.show(t,v),this._updatePosition(t,l,a,s,c,o,u)}},e.prototype._getNearestPoint=function(t,r,o,n,a){if(o==="axis"||I(r))return{color:n||a};if(!I(r))return{color:n||r.color||r.borderColor}},e.prototype._updatePosition=function(t,r,o,n,a,s,l){var u=this._api.getWidth(),p=this._api.getHeight();r=r||t.get("position");var c=a.getSize(),f=t.get("align"),h=t.get("verticalAlign"),d=l&&l.getBoundingRect().clone();if(l&&d.applyTransform(l.transform),G(r)&&(r=r([o,n],s,a.el,d,{viewSize:[u,p],contentSize:c.slice()})),I(r))o=J(r[0],u),n=J(r[1],p);else if(ot(r)){var v=r;v.width=c[0],v.height=c[1];var m=pt(v,{width:u,height:p});o=m.x,n=m.y,f=null,h=null}else if(E(r)&&l){var g=Od(r,d,c,t.get("borderWidth"));o=g[0],n=g[1]}else{var g=Ld(o,n,a,u,p,f?null:20,h?null:20);o=g[0],n=g[1]}if(f&&(o-=up(f)?c[0]/2:f==="right"?c[0]:0),h&&(n-=up(h)?c[1]/2:h==="bottom"?c[1]:0),qi(t)){var g=zd(o,n,a,u,p);o=g[0],n=g[1]}a.moveTo(o,n)},e.prototype._updateContentNotChangedOnAxis=function(t,r){var o=this._lastDataByCoordSys,n=this._cbParamsList,a=!!o&&o.length===t.length;return a&&S(o,function(s,l){var u=s.dataByAxis||[],p=t[l]||{},c=p.dataByAxis||[];a=a&&u.length===c.length,a&&S(u,function(f,h){var d=c[h]||{},v=f.seriesDataIndices||[],m=d.seriesDataIndices||[];a=a&&f.value===d.value&&f.axisType===d.axisType&&f.axisId===d.axisId&&v.length===m.length,a&&S(v,function(g,y){var x=m[y];a=a&&g.seriesIndex===x.seriesIndex&&g.dataIndex===x.dataIndex}),n&&S(f.seriesDataIndices,function(g){var y=g.seriesIndex,x=r[y],_=n[y];x&&_&&_.data!==x.data&&(a=!1)})})}),this._lastDataByCoordSys=t,this._cbParamsList=r,!!a},e.prototype._hide=function(t){this._lastDataByCoordSys=null,this._cbParamsList=null,t({type:"hideTip",from:this.uid})},e.prototype.dispose=function(t,r){ht.node||!r.getDom()||(Se(this,"_updatePosition"),this._tooltipContent.dispose(),wr("itemTooltip",r),this._tooltipContent=null,this._tooltipModel=null,this._lastDataByCoordSys=null,this._cbParamsList=null)},e.type="tooltip",e})(X);function Ir(i,e,t){var r=e.ecModel,o;t?(o=new at(t,r,r),o=new at(e.option,o,r)):o=e;for(var n=i.length-1;n>=0;n--){var a=i[n];a&&(a instanceof at&&(a=a.get("tooltip",!0)),E(a)&&(a={formatter:a}),a&&(o=new at(a,o,r)))}return o}function lp(i,e){return i.dispatchAction||O(e.dispatchAction,e)}function Ld(i,e,t,r,o,n,a){var s=t.getSize(),l=s[0],u=s[1];return n!=null&&(i+l+n+2>r?i-=l+n:i+=n),a!=null&&(e+u+a>o?e-=u+a:e+=a),[i,e]}function zd(i,e,t,r,o){var n=t.getSize(),a=n[0],s=n[1];return i=Math.min(i+a,r)-a,e=Math.min(e+s,o)-s,i=Math.max(i,0),e=Math.max(e,0),[i,e]}function Od(i,e,t,r){var o=t[0],n=t[1],a=Math.ceil(Math.SQRT2*r)+8,s=0,l=0,u=e.width,p=e.height;switch(i){case"inside":s=e.x+u/2-o/2,l=e.y+p/2-n/2;break;case"top":s=e.x+u/2-o/2,l=e.y-n-a;break;case"bottom":s=e.x+u/2-o/2,l=e.y+p+a;break;case"left":s=e.x-o-a,l=e.y+p/2-n/2;break;case"right":s=e.x+u+a,l=e.y+p/2-n/2}return[s,l]}function up(i){return i==="center"||i==="middle"}function Pd(i,e,t){var r=za(i).queryOptionMap,o=r.keys()[0];if(!(!o||o==="series")){var n=Zr(e,o,r.get(o),{useDefault:!1,enableAll:!1,enableNone:!1}),a=n.models[0];if(a){var s=t.getViewOfComponentModel(a),l;if(s.group.traverse(function(u){var p=j(u).tooltipConfig;if(p&&p.name===i.name)return l=u,!0}),l)return{componentMainType:o,componentIndex:a.componentIndex,el:l}}}}var pp=Id;function kd(i){ft(ee),i.registerComponentModel(Ju),i.registerComponentView(pp),i.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},ze),i.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},ze)}var Rd=["rect","polygon","keep","clear"];function Tn(i,e){var t=Gr(i?i.brush:[]);if(t.length){var r=[];S(t,function(l){var u=l.hasOwnProperty("toolbox")?l.toolbox:[];u instanceof Array&&(r=r.concat(u))});var o=i&&i.toolbox;I(o)&&(o=o[0]),o||(o={feature:{}},i.toolbox=[o]);var n=o.feature||(o.feature={}),a=n.brush||(n.brush={}),s=a.type||(a.type=[]);s.push.apply(s,r),ka(s,function(l){return l+""},null),e&&!s.length&&s.push.apply(s,Rd)}}var cp=S;function fp(i){if(i){for(var e in i)if(i.hasOwnProperty(e))return!0}}function Lr(i,e,t){var r={};return cp(e,function(n){var a=r[n]=o();cp(i[n],function(s,l){if(mt.isValidType(l)){var u={type:l,visual:s};t&&t(u,n),a[l]=new mt(u),l==="opacity"&&(u=U(u),u.type="colorAlpha",a.__hidden.__alphaForOpacity=new mt(u))}})}),r;function o(){var n=function(){};n.prototype.__hidden=n.prototype;var a=new n;return a}}function ji(i,e,t){var r;S(t,function(o){e.hasOwnProperty(o)&&fp(e[o])&&(r=!0)}),r&&S(t,function(o){e.hasOwnProperty(o)&&fp(e[o])?i[o]=U(e[o]):delete i[o]})}function hp(i,e,t,r,o,n){var a={};S(i,function(c){var f=mt.prepareVisualTypes(e[c]);a[c]=f});var s;function l(c){return Mo(t,s,c)}function u(c,f){Ao(t,s,c,f)}n==null?t.each(p):t.each([n],p);function p(c,f){s=n==null?c:f;var h=t.getRawDataItem(s);if(!(h&&h.visualMap===!1))for(var d=r.call(o,c),v=e[d],m=a[d],g=0,y=m.length;g<y;g++){var x=m[g];v[x]&&v[x].applyVisual(c,l,u)}}}function dp(i,e,t,r){var o={};return S(i,function(n){var a=mt.prepareVisualTypes(e[n]);o[n]=a}),{progress:function(a,s){var l;r!=null&&(l=s.getDimensionIndex(r));function u(b){return Mo(s,c,b)}function p(b,w){Ao(s,c,b,w)}for(var c,f=s.getStore();(c=a.next())!=null;){var h=s.getRawDataItem(c);if(!(h&&h.visualMap===!1))for(var d=r!=null?f.get(l,c):c,v=t(d),m=e[v],g=o[v],y=0,x=g.length;y<x;y++){var _=g[y];m[_]&&m[_].applyVisual(d,u,p)}}}}}function gp(i){var e=i.brushType,t={point:function(r){return vp[e].point(r,t,i)},rect:function(r){return vp[e].rect(r,t,i)}};return t}var vp={lineX:mp(0),lineY:mp(1),rect:{point:function(i,e,t){return i&&t.boundingRect.contain(i[0],i[1])},rect:function(i,e,t){return i&&t.boundingRect.intersect(i)}},polygon:{point:function(i,e,t){return i&&t.boundingRect.contain(i[0],i[1])&&Xe(t.range,i[0],i[1])},rect:function(i,e,t){var r=t.range;if(!i||r.length<=1)return!1;var o=i.x,n=i.y,a=i.width,s=i.height,l=r[0];if(Xe(r,o,n)||Xe(r,o+a,n)||Xe(r,o,n+s)||Xe(r,o+a,n+s)||Ct.create(i).contain(l[0],l[1])||vr(o,n,o+a,n,r)||vr(o,n,o,n+s,r)||vr(o+a,n,o+a,n+s,r)||vr(o,n+s,o+a,n+s,r))return!0}}};function mp(i){var e=["x","y"],t=["width","height"];return{point:function(r,o,n){if(r){var a=n.range,s=r[i];return zr(s,a)}},rect:function(r,o,n){if(r){var a=n.range,s=[r[e[i]],r[e[i]]+r[t[i]]];return s[1]<s[0]&&s.reverse(),zr(s[0],a)||zr(s[1],a)||zr(a[0],s)||zr(a[1],s)}}}}function zr(i,e){return e[0]<=i&&i<=e[1]}var yp=["inBrush","outOfBrush"],Mn="__ecBrushSelect",An="__ecInBrushSelectEvent";function Dn(i){i.eachComponent({mainType:"brush"},function(e){var t=e.brushTargetManager=new Dr(e.option,i);t.setInputRanges(e.areas,i)})}var Sp=Ee(Ed);function Ed(i,e,t){var r=[],o,n;i.eachComponent({mainType:"brush"},function(a){t&&t.type==="takeGlobalCursor"&&a.setBrushOption(t.key==="brush"?t.brushOption:{brushType:!1})}),Dn(i),i.eachComponent({mainType:"brush"},function(a,s){var l={brushId:a.id,brushIndex:s,brushName:a.name,areas:U(a.areas),selected:[]};r.push(l);var u=a.option,p=u.brushLink,c=[],f=[],h=[],d=!1;s||(o=u.throttleType,n=u.throttleDelay);var v=R(a.areas,function(b){var w=Bd[b.brushType],C=K({boundingRect:w?w(b):void 0},b);return C.selectors=gp(C),C}),m=Lr(a.option,yp,function(b){b.mappingMethod="fixed"});I(p)&&S(p,function(b){c[b]=1});function g(b){return p==="all"||!!c[b]}function y(b){return!!b.length}i.eachSeries(function(b,w){var C=h[w]=[];b.subType==="parallel"?x(b,w):_(b,w,C)});function x(b,w){var C=b.coordinateSystem;d=d||C.hasAxisBrushed(),g(w)&&C.eachActiveState(b.getData(),function(D,A){D==="active"&&(f[A]=1)})}function _(b,w,C){if(!(!b.brushSelector||Nd(a,w))&&(S(v,function(A){a.brushTargetManager.controlSeries(A,b,i)&&C.push(A),d=d||y(C)}),g(w)&&y(C))){var D=b.getData();D.each(function(A){xp(b,C,D,A)&&(f[A]=1)})}}i.eachSeries(function(b,w){var C={seriesId:b.id,seriesIndex:w,seriesName:b.name,dataIndex:[]};l.selected.push(C);var D=h[w],A=b.getData(),z=g(w)?function(L){return f[L]?(C.dataIndex.push(A.getRawIndex(L)),"inBrush"):"outOfBrush"}:function(L){return xp(b,D,A,L)?(C.dataIndex.push(A.getRawIndex(L)),"inBrush"):"outOfBrush"};(g(w)?d:y(D))&&hp(yp,m,A,z)})}),Vd(e,o,n,r,t)}function Vd(i,e,t,r,o){if(o){var n=i.getZr();if(!n[An]){n[Mn]||(n[Mn]=Ud);var a=qt(n,Mn,t,e);a(i,r)}}}function Ud(i,e){if(!i.isDisposed()){var t=i.getZr();t[An]=!0,i.dispatchAction({type:"brushSelect",batch:e}),t[An]=!1}}function xp(i,e,t,r){for(var o=0,n=e.length;o<n;o++){var a=e[o];if(i.brushSelector(r,t,a.selectors,a))return!0}}function Nd(i,e){var t=i.option.seriesIndex;return t!=null&&t!=="all"&&(I(t)?st(t,e)<0:e!==t)}var Bd={rect:function(i){return _p(i.range)},polygon:function(i){for(var e,t=i.range,r=0,o=t.length;r<o;r++){e=e||[Re(),Re()];var n=t[r];n[0]<e[0][0]&&(e[0][0]=n[0]),n[0]>e[0][1]&&(e[0][1]=n[0]),n[1]<e[1][0]&&(e[1][0]=n[1]),n[1]>e[1][1]&&(e[1][1]=n[1])}return e&&_p(e)}};function _p(i){return new Ct(i[0][0],i[1][0],i[0][1]-i[0][0],i[1][1]-i[1][0])}var Hd=(function(i){T(e,i);function e(){var t=i!==null&&i.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 xi(r.getZr())).on("brush",O(this._onBrush,this)).mount()},e.prototype.render=function(t,r,o,n){this.model=t,this._updateController(t,r,o,n)},e.prototype.updateTransform=function(t,r,o,n){Dn(r),this._updateController(t,r,o,n)},e.prototype.updateVisual=function(t,r,o,n){this.updateTransform(t,r,o,n)},e.prototype.updateView=function(t,r,o,n){this._updateController(t,r,o,n)},e.prototype._updateController=function(t,r,o,n){(!n||n.$from!==t.id)&&this._brushController.setPanels(t.brushTargetManager.makePanelOpts(o)).enableBrush(t.brushOption).updateCovers(t.areas.slice())},e.prototype.dispose=function(){this._brushController.dispose()},e.prototype._onBrush=function(t){var r=this.model.id,o=this.model.brushTargetManager.setOutputRanges(t.areas,this.ecModel);(!t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:r,areas:U(o),$from:r}),t.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:r,areas:U(o),$from:r})},e.type="brush",e})(X),bp=Hd;var Gd=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t.areas=[],t.brushOption={},t}return e.prototype.optionUpdated=function(t,r){var o=this.option;!r&&ji(o,t,["inBrush","outOfBrush"]);var n=o.inBrush=o.inBrush||{};o.outOfBrush=o.outOfBrush||{color:this.option.defaultOutOfBrushColor},n.hasOwnProperty("liftZ")||(n.liftZ=5)},e.prototype.setAreas=function(t){t&&(this.areas=R(t,function(r){return wp(this.option,r)},this))},e.prototype.setBrushOption=function(t){this.brushOption=wp(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:M.color.backgroundTint,borderColor:M.color.borderTint},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4,defaultOutOfBrushColor:M.color.disabled},e})(Z);function wp(i,e){return tt({brushType:i.brushType,brushMode:i.brushMode,transformable:i.transformable,brushStyle:new at(i.brushStyle).getItemStyle(),removeOnClick:i.removeOnClick,z:i.z},e,!0)}var Cp=Gd;var Fd=["rect","polygon","lineX","lineY","keep","clear"],Zd=(function(i){T(e,i);function e(){return i!==null&&i.apply(this,arguments)||this}return e.prototype.render=function(t,r,o){var n,a,s;r.eachComponent({mainType:"brush"},function(l){n=l.brushType,a=l.brushOption.brushMode||"single",s=s||!!l.areas.length}),this._brushType=n,this._brushMode=a,S(t.get("type",!0),function(l){t.setIconStatus(l,(l==="keep"?a==="multiple":l==="clear"?s:l===n)?"emphasis":"normal")})},e.prototype.updateView=function(t,r,o){this.render(t,r,o)},e.prototype.getIcons=function(){var t=this.model,r=t.get("icon",!0),o={};return S(t.get("type",!0),function(n){r[n]&&(o[n]=r[n])}),o},e.prototype.onclick=function(t,r,o){var n=this._brushType,a=this._brushMode;o==="clear"?(r.dispatchAction({type:"axisAreaSelect",intervals:[]}),r.dispatchAction({type:"brush",command:"clear",areas:[]})):r.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:o==="keep"?n:n===o?!1:o,brushMode:o==="keep"?a==="multiple"?"single":"multiple":a}})},e.getDefaultOption=function(t){var r={show:!0,type:Fd.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})(_t),Tp=Zd;function Wd(i){i.registerComponentView(bp),i.registerComponentModel(Cp),i.registerPreprocessor(Tn),i.registerVisual(i.PRIORITY.VISUAL.BRUSH,Sp),i.registerAction({type:"brush",event:"brush",update:"updateVisual"},function(e,t){t.eachComponent({mainType:"brush",query:e},function(r){r.setAreas(e.areas)})}),i.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},ze),i.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},ze),fe("brush",Tp)}var Yd=(function(i){T(e,i);function e(){var t=i!==null&&i.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:M.size.m,backgroundColor:M.color.transparent,borderColor:M.color.primary,borderWidth:0,padding:5,itemGap:10,textStyle:{fontSize:18,fontWeight:"bold",color:M.color.primary},subtextStyle:{fontSize:12,color:M.color.quaternary}},e})(Z),Xd=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,o){if(this.group.removeAll(),!!t.get("show")){var n=this.group,a=t.getModel("textStyle"),s=t.getModel("subtextStyle"),l=t.get("textAlign"),u=W(t.get("textBaseline"),t.get("textVerticalAlign")),p=new F({style:nt(a,{text:t.get("text"),fill:a.getTextColor()},{disableBox:!0}),z2:10}),c=p.getBoundingRect(),f=t.get("subtext"),h=new F({style:nt(s,{text:f,fill:s.getTextColor(),y:c.height+t.get("itemGap"),verticalAlign:"top"},{disableBox:!0}),z2:10}),d=t.get("link"),v=t.get("sublink"),m=t.get("triggerEvent",!0);p.silent=!d&&!m,h.silent=!v&&!m,d&&p.on("click",function(){So(d,"_"+t.get("target"))}),v&&h.on("click",function(){So(v,"_"+t.get("subtarget"))}),j(p).eventData=j(h).eventData=m?{componentType:"title",componentIndex:t.componentIndex}:null,n.add(p),f&&n.add(h);var g=n.getBoundingRect(),y=t.getBoxLayoutParams();y.width=g.width,y.height=g.height;var x=gt(t,o),_=pt(y,x.refContainer,t.get("padding"));l||(l=t.get("left")||t.get("right"),l==="middle"&&(l="center"),l==="right"?_.x+=_.width:l==="center"&&(_.x+=_.width/2)),u||(u=t.get("top")||t.get("bottom"),u==="center"&&(u="middle"),u==="bottom"?_.y+=_.height:u==="middle"&&(_.y+=_.height/2),u=u||"top"),n.x=_.x,n.y=_.y,n.markRedraw();var b={align:l,verticalAlign:u};p.setStyle(b),h.setStyle(b),g=n.getBoundingRect();var w=_.margin,C=t.getItemStyle(["color","opacity"]);C.fill=t.get("backgroundColor");var D=new rt({shape:{x:g.x-w[3],y:g.y-w[0],width:g.width+w[1]+w[3],height:g.height+w[0]+w[2],r:t.get("borderRadius")},style:C,subPixelOptimize:!0,silent:!0});n.add(D)}},e.type="title",e})(X);function Kd(i){i.registerComponentModel(Yd),i.registerComponentView(Xd)}var qd=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t.layoutMode="box",t}return e.prototype.init=function(t,r,o){this.mergeDefaultAndTheme(t,o),this._initData()},e.prototype.mergeOption=function(t){i.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||[],o=t.axisType,n=this._names=[],a;o==="category"?(a=[],S(r,function(u,p){var c=ye(Ta(u),""),f;ot(u)?(f=U(u),f.value=p):f=p,a.push(f),n.push(c)})):a=r;var s={category:"ordinal",time:"time",value:"number"}[o]||"number",l=this._data=new Ht([{name:"value",type:s}],this);l.initData(a,n)},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:M.size.m,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:M.color.secondary},data:[]},e})(Z),In=qd;var Mp=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline.slider",e.defaultOption=Ot(In.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:M.color.border,borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:M.color.accent10},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:M.color.tertiary},itemStyle:{color:M.color.accent20,borderWidth:0},checkpointStyle:{symbol:"circle",symbolSize:15,color:M.color.accent50,borderColor:M.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:M.color.accent50,borderColor:M.color.accent50,borderWidth:0},emphasis:{label:{show:!0,color:M.color.accent60},itemStyle:{color:M.color.accent60,borderColor:M.color.accent60},controlStyle:{color:M.color.accent70,borderColor:M.color.accent70}},progress:{lineStyle:{color:M.color.accent30},itemStyle:{color:M.color.accent40}},data:[]}),e})(In);ie(Mp,mr.prototype);var Ap=Mp;var jd=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline",e})(X),Dp=jd;var $d=(function(i){T(e,i);function e(t,r,o,n){var a=i.call(this,t,r,o)||this;return a.type=n||"value",a}return e.prototype.getLabelModel=function(){return this.model.getModel("label")},e.prototype.isHorizontal=function(){return this.model.get("orient")==="horizontal"},e})(kt),Ip=$d;var Ln=Math.PI,Lp=Q(),Jd=(function(i){T(e,i);function e(){var t=i!==null&&i.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,o){if(this.model=t,this.api=o,this.ecModel=r,this.group.removeAll(),t.get("show",!0)){var n=this._layout(t,o),a=this._createGroup("_mainGroup"),s=this._createGroup("_labelGroup"),l=this._axis=this._createAxis(n,t);t.formatTooltip=function(u){var p=l.scale.getLabel({value:u});return le("nameValue",{noName:!0,value:p})},S(["AxisLine","AxisTick","Control","CurrentPointer"],function(u){this["_render"+u](n,a,l,t)},this),this._renderAxisLabel(n,s,l,t),this._position(n,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 o=t.get(["label","position"]),n=t.get("orient"),a=Qd(t,r),s;o==null||o==="auto"?s=n==="horizontal"?a.y+a.height/2<r.getHeight()/2?"-":"+":a.x+a.width/2<r.getWidth()/2?"+":"-":E(o)?s={horizontal:{top:"-",bottom:"+"},vertical:{left:"-",right:"+"}}[n][o]:s=o;var l={horizontal:"center",vertical:s>=0||s==="+"?"left":"right"},u={horizontal:s>=0||s==="+"?"top":"bottom",vertical:"middle"},p={horizontal:0,vertical:Ln/2},c=n==="vertical"?a.height:a.width,f=t.getModel("controlStyle"),h=f.get("show",!0),d=h?f.get("itemSize"):0,v=h?f.get("itemGap"):0,m=d+v,g=t.get(["label","rotate"])||0;g=g*Ln/180;var y,x,_,b=f.get("position",!0),w=h&&f.get("showPlayBtn",!0),C=h&&f.get("showPrevBtn",!0),D=h&&f.get("showNextBtn",!0),A=0,z=c;b==="left"||b==="bottom"?(w&&(y=[0,0],A+=m),C&&(x=[A,0],A+=m),D&&(_=[z-d,0],z-=m)):(w&&(y=[z-d,0],z-=m),C&&(x=[0,0],A+=m),D&&(_=[z-d,0],z-=m));var L=[A,z];return t.get("inverse")&&L.reverse(),{viewRect:a,mainLength:c,orient:n,rotation:p[n],labelRotation:g,labelPosOpt:s,labelAlign:t.get(["label","align"])||l[n],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||u[n],playPosition:y,prevBtnPosition:x,nextBtnPosition:_,axisExtent:L,controlSize:d,controlGap:v}},e.prototype._position=function(t,r){var o=this._mainGroup,n=this._labelGroup,a=t.viewRect;if(t.orient==="vertical"){var s=Oe(),l=a.x,u=a.y+a.height;me(s,s,[-l,-u]),Pe(s,s,-Ln/2),me(s,s,[l,u]),a=a.clone(),a.applyTransform(s)}var p=y(a),c=y(o.getBoundingRect()),f=y(n.getBoundingRect()),h=[o.x,o.y],d=[n.x,n.y];d[0]=h[0]=p[0][0];var v=t.labelPosOpt;if(v==null||E(v)){var m=v==="+"?0:1;x(h,c,p,1,m),x(d,f,p,1,1-m)}else{var m=v>=0?0:1;x(h,c,p,1,m),d[1]=h[1]+v}o.setPosition(h),n.setPosition(d),o.rotation=n.rotation=t.rotation,g(o),g(n);function g(_){_.originX=p[0][0]-_.x,_.originY=p[1][0]-_.y}function y(_){return[[_.x,_.x+_.width],[_.y,_.y+_.height]]}function x(_,b,w,C,D){_[C]+=w[C][D]-b[C][D]}},e.prototype._createAxis=function(t,r){var o=r.getData(),n=r.get("axisType")||r.get("type");n!=="category"&&n!=="time"&&(n="value");var a=Ye(r,n,!1);a.getTicks=function(){return o.mapArray(["value"],function(u){return{value:u}})};var s=o.getDataExtent("value");a.setExtent(s[0],s[1]),Ss(a,{fixMinMax:[!0,!0]});var l=new Ip("value",a,t.axisExtent,n);return l.model=r,l},e.prototype._createGroup=function(t){var r=this[t]=new et;return this.group.add(r),r},e.prototype._renderAxisLine=function(t,r,o,n){var a=o.getExtent();if(n.get(["lineStyle","show"])){var s=new Lt({shape:{x1:a[0],y1:0,x2:a[1],y2:0},style:N({lineCap:"round"},n.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});r.add(s);var l=this._progressLine=new Lt({shape:{x1:a[0],x2:this._currentPointer?this._currentPointer.x:a[0],y1:0,y2:0},style:K({lineCap:"round",lineWidth:s.style.lineWidth},n.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});r.add(l)}},e.prototype._renderAxisTick=function(t,r,o,n){var a=this,s=n.getData(),l=o.scale.getTicks();this._tickSymbols=[],S(l,function(u){var p=o.dataToCoord(u.value),c=s.getItemModel(u.value),f=c.getModel("itemStyle"),h=c.getModel(["emphasis","itemStyle"]),d=c.getModel(["progress","itemStyle"]),v={x:p,y:0,onclick:O(a._changeTimeline,a,u.value)},m=zp(c,f,r,v);m.ensureState("emphasis").style=h.getItemStyle(),m.ensureState("progress").style=d.getItemStyle(),Qt(m);var g=j(m);c.get("tooltip")?(g.dataIndex=u.value,g.dataModel=n):g.dataIndex=g.dataModel=null,a._tickSymbols.push(m)})},e.prototype._renderAxisLabel=function(t,r,o,n){var a=this,s=o.getLabelModel();if(s.get("show")){var l=n.getData(),u=o.getViewLabels();this._tickLabels=[],S(u,function(p){if(!p.tick.offInterval){var c=p.tick.value,f=l.getItemModel(c),h=f.getModel("label"),d=f.getModel(["emphasis","label"]),v=f.getModel(["progress","label"]),m=o.dataToCoord(c),g=new F({x:m,y:0,rotation:t.labelRotation-t.rotation,onclick:O(a._changeTimeline,a,c),silent:!1,style:nt(h,{text:p.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});g.ensureState("emphasis").style=nt(d),g.ensureState("progress").style=nt(v),r.add(g),Qt(g),Lp(g).dataIndex=c,a._tickLabels.push(g)}})}},e.prototype._renderControl=function(t,r,o,n){var a=t.controlSize,s=t.rotation,l=n.getModel("controlStyle").getItemStyle(),u=n.getModel(["emphasis","controlStyle"]).getItemStyle(),p=n.getPlayState(),c=n.get("inverse",!0);f(t.nextBtnPosition,"next",O(this._changeTimeline,this,c?"-":"+")),f(t.prevBtnPosition,"prev",O(this._changeTimeline,this,c?"+":"-")),f(t.playPosition,p?"stop":"play",O(this._handlePlayClick,this,!p),!0);function f(h,d,v,m){if(h){var g=hr(W(n.get(["controlStyle",d+"BtnSize"]),a),a),y=[0,-g/2,g,g],x=tv(n,d+"Icon",y,{x:h[0],y:h[1],originX:a/2,originY:0,rotation:m?-s:0,rectHover:!0,style:l,onclick:v});x.ensureState("emphasis").style=u,r.add(x),Qt(x)}}},e.prototype._renderCurrentPointer=function(t,r,o,n){var a=n.getData(),s=n.getCurrentIndex(),l=a.getItemModel(s).getModel("checkpointStyle"),u=this,p={onCreate:function(c){c.draggable=!0,c.drift=O(u._handlePointerDrag,u),c.ondragend=O(u._handlePointerDragend,u),Op(c,u._progressLine,s,o,n,!0)},onUpdate:function(c){Op(c,u._progressLine,s,o,n)}};this._currentPointer=zp(l,l,this._mainGroup,{},this._currentPointer,p)},e.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},e.prototype._handlePointerDrag=function(t,r,o){this._clearTimer(),this._pointerChangeTimeline([o.offsetX,o.offsetY])},e.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},e.prototype._pointerChangeTimeline=function(t,r){var o=this._toAxisCoord(t)[0],n=this._axis,a=yt(n.getExtent().slice());o>a[1]&&(o=a[1]),o<a[0]&&(o=a[0]),this._currentPointer.x=o,this._currentPointer.markRedraw();var s=this._progressLine;s&&(s.shape.x2=o,s.dirty());var l=this._findNearestTick(o),u=this.model;(r||l!==u.getCurrentIndex()&&u.get("realtime"))&&this._changeTimeline(l)},e.prototype._doPlayStop=function(){var t=this;this._clearTimer(),this.model.getPlayState()&&(this._timer=setTimeout(function(){var r=t.model;t._changeTimeline(r.getCurrentIndex()+(r.get("rewind",!0)?-1:1))},this.model.get("playInterval")))},e.prototype._toAxisCoord=function(t){var r=this._mainGroup.getLocalTransform();return At(t,r,!0)},e.prototype._findNearestTick=function(t){var r=this.model.getData(),o=1/0,n,a=this._axis;return r.each(["value"],function(s,l){var u=a.dataToCoord(s),p=Math.abs(u-t);p<o&&(o=p,n=l)}),n},e.prototype._clearTimer=function(){this._timer&&(clearTimeout(this._timer),this._timer=null)},e.prototype._changeTimeline=function(t){var r=this.model.getCurrentIndex();t==="+"?t=r+1:t==="-"&&(t=r-1),this.api.dispatchAction({type:"timelineChange",currentIndex:t,from:this.uid})},e.prototype._updateTicksStatus=function(){var t=this.model.getCurrentIndex(),r=this._tickSymbols,o=this._tickLabels;if(r)for(var n=0;n<r.length;n++)r&&r[n]&&r[n].toggleState("progress",n<t);if(o)for(var n=0;n<o.length;n++)o&&o[n]&&o[n].toggleState("progress",Lp(o[n]).dataIndex<=t)},e.type="timeline.slider",e})(Dp);function Qd(i,e){return pt(i.getBoxLayoutParams(),gt(i,e).refContainer,i.get("padding"))}function tv(i,e,t,r){var o=r.style,n=ae(i.get(["controlStyle",e]),r||{},new Ct(t[0],t[1],t[2],t[3]));return o&&n.setStyle(o),n}function zp(i,e,t,r,o,n){var a=e.get("color");if(o)o.setColor(a),t.add(o),n&&n.onUpdate(o);else{var s=i.get("symbol");o=Pt(s,-1,-1,2,2,a),o.setStyle("strokeNoScale",!0),t.add(o),n&&n.onCreate(o)}var l=e.getItemStyle(["color"]);o.setStyle(l),r=tt({rectHover:!0,z2:100},r,!0);var u=fs(i.get("symbolSize"));r.scaleX=u[0]/2,r.scaleY=u[1]/2;var p=hs(i.get("symbolOffset"),u);p&&(r.x=(r.x||0)+p[0],r.y=(r.y||0)+p[1]);var c=i.get("symbolRotate");return r.rotation=(c||0)*Math.PI/180||0,o.attr(r),o.updateTransform(),o}function Op(i,e,t,r,o,n){if(!i.dragging){var a=o.getModel("checkpointStyle"),s=r.dataToCoord(o.getData().get("value",t));if(n||!a.get("animation",!0))i.attr({x:s,y:0}),e&&e.attr({shape:{x2:s}});else{var l={duration:a.get("animationDuration",!0),easing:a.get("animationEasing",!0)};i.stopAnimation(null,!0),i.animateTo({x:s,y:0},l),e&&e.animateTo({shape:{x2:s}},l)}}}var Pp=Jd;function kp(i){i.registerAction({type:"timelineChange",event:"timelineChanged",update:"prepareAndUpdate"},function(e,t,r){var o=t.getComponent("timeline");return o&&e.currentIndex!=null&&(o.setCurrentIndex(e.currentIndex),!o.get("loop",!0)&&o.isIndexMax()&&o.getPlayState()&&(o.setPlayState(!1),r.dispatchAction({type:"timelinePlayChange",playState:!1,from:e.from}))),t.resetOption("timeline",{replaceMerge:o.get("replaceMerge",!0)}),K({currentIndex:o.option.currentIndex},e)}),i.registerAction({type:"timelinePlayChange",event:"timelinePlayChanged",update:"update"},function(e,t){var r=t.getComponent("timeline");r&&e.playState!=null&&r.setPlayState(e.playState)})}function zn(i){var e=i&&i.timeline;I(e)||(e=e?[e]:[]),S(e,function(t){t&&ev(t)})}function ev(i){var e=i.type,t={number:"value",time:"time"};if(t[e]&&(i.axisType=t[e],delete i.type),Rp(i),De(i,"controlPosition")){var r=i.controlStyle||(i.controlStyle={});De(r,"position")||(r.position=i.controlPosition),r.position==="none"&&!De(r,"show")&&(r.show=!1,delete r.position),delete i.controlPosition}S(i.data||[],function(o){ot(o)&&!I(o)&&(!De(o,"value")&&De(o,"name")&&(o.value=o.name),Rp(o))})}function Rp(i){var e=i.itemStyle||(i.itemStyle={}),t=e.emphasis||(e.emphasis={}),r=i.label||i.label||{},o=r.normal||(r.normal={}),n={normal:1,emphasis:1};S(r,function(a,s){!n[s]&&!De(o,s)&&(o[s]=a)}),t.label&&!De(r,"emphasis")&&(r.emphasis=t.label,delete t.label)}function De(i,e){return i.hasOwnProperty(e)}function rv(i){i.registerComponentModel(Ap),i.registerComponentView(Pp),i.registerSubTypeDefaulter("timeline",function(){return"slider"}),kp(i),i.registerPreprocessor(zn)}function Ie(i,e){if(!i)return!1;for(var t=I(i)?i:[i],r=0;r<t.length;r++)if(t[r]&&t[r][e])return!0;return!1}function Ji(i){Ca(i,"label",["show"])}var Qi=Q(),Ep=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t.createdBySelf=!1,t.preventAutoZ=!0,t}return e.prototype.init=function(t,r,o){this.mergeDefaultAndTheme(t,o),this._mergeOption(t,o,!1,!0)},e.prototype.isAnimationEnabled=function(){if(ht.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnabled()},e.prototype.mergeOption=function(t,r){this._mergeOption(t,r,!1,!1)},e.prototype._mergeOption=function(t,r,o,n){var a=this.mainType;o||r.eachSeries(function(s){var l=s.get(this.mainType,!0),u=Qi(s)[a];if(!l||!l.data){Qi(s)[a]=null;return}u?u._mergeOption(l,r,!0):(n&&Ji(l),S(l.data,function(p){p instanceof Array?(Ji(p[0]),Ji(p[1])):Ji(p)}),u=this.createMarkerModelFromSeries(l,this,r),N(u,{mainType:this.mainType,seriesIndex:s.seriesIndex,name:s.name,createdBySelf:!0}),u.__hostSeries=s),Qi(s)[a]=u},this)},e.prototype.formatTooltip=function(t,r,o){var n=this.getData(),a=this.getRawValue(t),s=n.getName(t);return le("section",{header:this.name,blocks:[le("nameValue",{name:s,value:a,noName:!s,noValue:a==null})]})},e.prototype.getData=function(){return this._data},e.prototype.setData=function(t){this._data=t},e.prototype.getDataParams=function(t,r){var o=mr.prototype.getDataParams.call(this,t,r),n=this.__hostSeries;return n&&(o.seriesId=n.id,o.seriesName=n.name,o.seriesType=n.subType),o},e.getMarkerModelFromSeries=function(t,r){return Qi(t)[r]},e.type="marker",e.dependencies=["series","grid","polar","geo"],e})(Z);ie(Ep,mr.prototype);var bt=Ep;var iv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,r,o){return new e(t,r,o)},e.type="markPoint",e.defaultOption={z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}},e})(bt),Vp=iv;function On(i){return!(isNaN(parseFloat(i.x))&&isNaN(parseFloat(i.y)))}function ov(i){return!isNaN(parseFloat(i.x))&&!isNaN(parseFloat(i.y))}function to(i,e,t,r,o,n,a){var s=[],l=ui(e,o),u=l?e.getCalculationInfo("stackResultDimension"):o,p=Or(e,u,i),c=e.hostModel,f=c.indicesOfNearest(t,u,p)[0];s[n]=e.get(r,f),s[a]=e.get(u,f);var h=e.get(o,f),d=Sa(e.get(o,f));return d=Math.min(d,20),d>=0&&(s[a]=+s[a].toFixed(d)),[s,h]}var eo={min:H(to,"min"),max:H(to,"max"),average:H(to,"average"),median:H(to,"median")};function de(i,e){if(e){var t=i.getData(),r=i.coordinateSystem,o=r&&r.dimensions;if(!ov(e)&&!I(e.coord)&&I(o)){var n=Pn(e,t,r,i);if(e=U(e),e.type&&eo[e.type]&&n.baseAxis&&n.valueAxis){var a=st(o,n.baseAxis.dim),s=st(o,n.valueAxis.dim),l=eo[e.type](t,n.valueAxis.dim,n.baseDataDim,n.valueDataDim,a,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||!I(o)){e.coord=[];var u=i.getBaseAxis();if(u&&e.type&&eo[e.type]){var p=r.getOtherAxis(u);p&&(e.value=Or(t,t.mapDimension(p.dim),e.type))}}else for(var c=e.coord,f=0;f<2;f++)eo[c[f]]&&(c[f]=Or(t,t.mapDimension(o[f]),c[f]));return e}}function Pn(i,e,t,r){var o={};return i.valueIndex!=null||i.valueDim!=null?(o.valueDataDim=i.valueIndex!=null?e.getDimension(i.valueIndex):i.valueDim,o.valueAxis=t.getAxis(nv(r,o.valueDataDim)),o.baseAxis=t.getOtherAxis(o.valueAxis),o.baseDataDim=e.mapDimension(o.baseAxis.dim)):(o.baseAxis=r.getBaseAxis(),o.valueAxis=t.getOtherAxis(o.baseAxis),o.baseDataDim=e.mapDimension(o.baseAxis.dim),o.valueDataDim=e.mapDimension(o.valueAxis.dim)),o}function nv(i,e){var t=i.getData().getDimensionInfo(e);return t&&t.coordDim}function ve(i,e){return i&&i.containData&&e.coord&&!On(e)?i.containData(e.coord):!0}function Up(i,e,t){return i&&i.containZone&&e.coord&&t.coord&&!On(e)&&!On(t)?i.containZone(e.coord,t.coord):!0}function ro(i,e){return i?function(t,r,o,n){var a=n<2?t.coord&&t.coord[n]:t.value;return Ze(a,e[n])}:function(t,r,o,n){return Ze(t.value,e[n])}}function Or(i,e,t){if(t==="average"){var r=0,o=0;return i.each(e,function(n,a){isNaN(n)||(r+=n,o++)}),r/o}else return t==="median"?i.getMedian(e):i.getDataExtent(e)[t==="max"?1:0]}var Rn=Q(),av=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this.markerGroupMap=q()},e.prototype.render=function(t,r,o){var n=this,a=this.markerGroupMap;a.each(function(s){Rn(s).keep=!1}),r.eachSeries(function(s){var l=bt.getMarkerModelFromSeries(s,n.type);l&&n.renderSeries(s,l,r,o)}),a.each(function(s){!Rn(s).keep&&n.group.remove(s.group)}),sv(r,a,this.type)},e.prototype.markKeep=function(t){Rn(t).keep=!0},e.prototype.toggleBlurSeries=function(t,r){var o=this;S(t,function(n){var a=bt.getMarkerModelFromSeries(n,o.type);if(a){var s=a.getData();s.eachItemGraphicEl(function(l){l&&(r?Ba(l):Ha(l))})}})},e.type="marker",e})(X);function sv(i,e,t){i.eachSeries(function(r){var o=bt.getMarkerModelFromSeries(r,t),n=e.get(r.id);if(o&&n&&n.group){var a=Qr(o),s=a.z,l=a.zlevel;ti(n.group,s,l)}})}var ar=av;function Np(i,e,t){var r=e.coordinateSystem,o=t.getWidth(),n=t.getHeight(),a=r&&r.getArea&&r.getArea();i.each(function(s){var l=i.getItemModel(s),u=l.get("relativeTo")==="coordinate",p=u?a?a.width:0:o,c=u?a?a.height:0:n,f=u&&a?a.x:0,h=u&&a?a.y:0,d,v=J(l.get("x"),p)+f,m=J(l.get("y"),c)+h;if(!isNaN(v)&&!isNaN(m))d=[v,m];else if(e.getMarkerPosition)d=e.getMarkerPosition(i.getValues(i.dimensions,s));else if(r){var g=i.get(r.dimensions[0],s),y=i.get(r.dimensions[1],s);d=r.dataToPoint([g,y])}isNaN(v)||(d[0]=v),isNaN(m)||(d[1]=m),i.setItemLayout(s,d)})}var lv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,r,o){r.eachSeries(function(n){var a=bt.getMarkerModelFromSeries(n,"markPoint");a&&(Np(a.getData(),n,o),this.markerGroupMap.get(n.id).updateLayout())},this)},e.prototype.renderSeries=function(t,r,o,n){var a=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,p=u.get(s)||u.set(s,new bs),c=uv(a,t,r);r.setData(c),Np(r.getData(),t,n),c.each(function(f){var h=c.getItemModel(f),d=h.getShallow("symbol"),v=h.getShallow("symbolSize"),m=h.getShallow("symbolRotate"),g=h.getShallow("symbolOffset"),y=h.getShallow("symbolKeepAspect");if(G(d)||G(v)||G(m)||G(g)){var x=r.getRawValue(f),_=r.getDataParams(f);G(d)&&(d=d(x,_)),G(v)&&(v=v(x,_)),G(m)&&(m=m(x,_)),G(g)&&(g=g(x,_))}var b=h.getModel("itemStyle").getItemStyle(),w=h.get("z2"),C=ue(l,"color");b.fill||(b.fill=C),c.setItemVisual(f,{z2:W(w,0),symbol:d,symbolSize:v,symbolRotate:m,symbolOffset:g,symbolKeepAspect:y,style:b})}),p.updateData(c),this.group.add(p.group),c.eachItemGraphicEl(function(f){f.traverse(function(h){j(h).dataModel=r})}),this.markKeep(p),p.group.silent=r.get("silent")||t.get("silent")},e.type="markPoint",e})(ar);function uv(i,e,t){var r;i?r=R(i&&i.dimensions,function(s){var l=e.getData(),u=l.getDimensionInfo(l.mapDimension(s))||{};return N(N({},u),{name:s,ordinalMeta:null})}):r=[{name:"value",type:"float"}];var o=new Ht(r,t),n=R(t.get("data"),H(de,e));i&&(n=St(n,H(ve,i)));var a=ro(!!i,r);return o.initData(n,null,a),o}var Bp=lv;function pv(i){i.registerComponentModel(Vp),i.registerComponentView(Bp),i.registerPreprocessor(function(e){Ie(e.series,"markPoint")&&(e.markPoint=e.markPoint||{})})}var cv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,r,o){return new e(t,r,o)},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})(bt),Hp=cv;var io=Q(),fv=function(i,e,t,r){var o=i.getData(),n;if(I(r))n=r;else{var a=r.type;if(a==="min"||a==="max"||a==="average"||a==="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=It(r.yAxis,r.xAxis);else{var u=Pn(r,o,e,i);s=u.valueAxis;var p=ms(o,u.valueDataDim);l=Or(o,p,a)}var c=s.dim==="x"?0:1,f=1-c,h=U(r),d={coord:[]};h.type=null,h.coord=[],h.coord[f]=-1/0,d.coord[f]=1/0;var v=t.get("precision");v>=0&&oe(l)&&(l=+l.toFixed(Math.min(v,20))),h.coord[c]=d.coord[c]=l,n=[h,d,{type:a,valueIndex:r.valueIndex,value:l}]}else n=[]}var m=[de(i,n[0]),de(i,n[1]),N({},n[2])];return m[2].type=m[2].type||null,tt(m[2],m[0]),tt(m[2],m[1]),m};function oo(i){return!isNaN(i)&&!isFinite(i)}function Gp(i,e,t,r){var o=1-i,n=r.dimensions[i];return oo(e[o])&&oo(t[o])&&e[i]===t[i]&&r.getAxis(n).containData(e[i])}function hv(i,e){if(i.type==="cartesian2d"){var t=e[0].coord,r=e[1].coord;if(t&&r&&(Gp(1,t,r,i)||Gp(0,t,r,i)))return!0}return ve(i,e[0])&&ve(i,e[1])}function En(i,e,t,r,o){var n=r.coordinateSystem,a=i.getItemModel(e),s,l=J(a.get("x"),o.getWidth()),u=J(a.get("y"),o.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(r.getMarkerPosition)s=r.getMarkerPosition(i.getValues(i.dimensions,e));else{var p=n.dimensions,c=i.get(p[0],e),f=i.get(p[1],e);s=n.dataToPoint([c,f])}if(_r(n,"cartesian2d")){var h=n.getAxis("x"),d=n.getAxis("y"),p=n.dimensions;oo(i.get(p[0],e))?s[0]=h.toGlobalCoord(h.getExtent()[t?0:1]):oo(i.get(p[1],e))&&(s[1]=d.toGlobalCoord(d.getExtent()[t?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}i.setItemLayout(e,s)}var dv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,r,o){r.eachSeries(function(n){var a=bt.getMarkerModelFromSeries(n,"markLine");if(a){var s=a.getData(),l=io(a).from,u=io(a).to;l.each(function(p){En(l,p,!0,n,o),En(u,p,!1,n,o)}),s.each(function(p){s.setItemLayout(p,[l.getItemLayout(p),u.getItemLayout(p)])}),this.markerGroupMap.get(n.id).updateLayout()}},this)},e.prototype.renderSeries=function(t,r,o,n){var a=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,p=u.get(s)||u.set(s,new Hs);this.group.add(p.group);var c=vv(a,t,r),f=c.from,h=c.to,d=c.line;io(r).from=f,io(r).to=h,r.setData(d);var v=r.get("symbol"),m=r.get("symbolSize"),g=r.get("symbolRotate"),y=r.get("symbolOffset");I(v)||(v=[v,v]),I(m)||(m=[m,m]),I(g)||(g=[g,g]),I(y)||(y=[y,y]),c.from.each(function(_){x(f,_,!0),x(h,_,!1)}),d.each(function(_){var b=d.getItemModel(_),w=b.getModel("lineStyle").getLineStyle();d.setItemLayout(_,[f.getItemLayout(_),h.getItemLayout(_)]);var C=b.get("z2");w.stroke==null&&(w.stroke=f.getItemVisual(_,"style").fill),d.setItemVisual(_,{z2:W(C,0),fromSymbolKeepAspect:f.getItemVisual(_,"symbolKeepAspect"),fromSymbolOffset:f.getItemVisual(_,"symbolOffset"),fromSymbolRotate:f.getItemVisual(_,"symbolRotate"),fromSymbolSize:f.getItemVisual(_,"symbolSize"),fromSymbol:f.getItemVisual(_,"symbol"),toSymbolKeepAspect:h.getItemVisual(_,"symbolKeepAspect"),toSymbolOffset:h.getItemVisual(_,"symbolOffset"),toSymbolRotate:h.getItemVisual(_,"symbolRotate"),toSymbolSize:h.getItemVisual(_,"symbolSize"),toSymbol:h.getItemVisual(_,"symbol"),style:w})}),p.updateData(d),c.line.eachItemGraphicEl(function(_){j(_).dataModel=r,_.traverse(function(b){j(b).dataModel=r})});function x(_,b,w){var C=_.getItemModel(b);En(_,b,w,t,n);var D=C.getModel("itemStyle").getItemStyle();D.fill==null&&(D.fill=ue(l,"color")),_.setItemVisual(b,{symbolKeepAspect:C.get("symbolKeepAspect"),symbolOffset:W(C.get("symbolOffset",!0),y[w?0:1]),symbolRotate:W(C.get("symbolRotate",!0),g[w?0:1]),symbolSize:W(C.get("symbolSize"),m[w?0:1]),symbol:W(C.get("symbol",!0),v[w?0:1]),style:D})}this.markKeep(p),p.group.silent=r.get("silent")||t.get("silent")},e.type="markLine",e})(ar);function vv(i,e,t){var r;i?r=R(i&&i.dimensions,function(u){var p=e.getData(),c=p.getDimensionInfo(p.mapDimension(u))||{};return N(N({},c),{name:u,ordinalMeta:null})}):r=[{name:"value",type:"float"}];var o=new Ht(r,t),n=new Ht(r,t),a=new Ht([],t),s=R(t.get("data"),H(fv,e,i,t));i&&(s=St(s,H(hv,i)));var l=ro(!!i,r);return o.initData(R(s,function(u){return u[0]}),null,l),n.initData(R(s,function(u){return u[1]}),null,l),a.initData(R(s,function(u){return u[2]})),a.hasItemOption=!0,{from:o,to:n,line:a}}var Fp=dv;function mv(i){i.registerComponentModel(Hp),i.registerComponentView(Fp),i.registerPreprocessor(function(e){Ie(e.series,"markLine")&&(e.markLine=e.markLine||{})})}var gv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.createMarkerModelFromSeries=function(t,r,o){return new e(t,r,o)},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})(bt),Zp=gv;var no=Q(),yv=function(i,e,t,r){var o=r[0],n=r[1];if(!(!o||!n)){var a=de(i,o),s=de(i,n),l=a.coord,u=s.coord;l[0]=It(l[0],-1/0),l[1]=It(l[1],-1/0),u[0]=It(u[0],1/0),u[1]=It(u[1],1/0);var p=na([{},a,s]);return p.coord=[a.coord,s.coord],p.x0=a.x,p.y0=a.y,p.x1=s.x,p.y1=s.y,p}};function ao(i){return!isNaN(i)&&!isFinite(i)}function Wp(i,e,t,r){var o=1-i;return ao(e[o])&&ao(t[o])}function xv(i,e){var t=e.coord[0],r=e.coord[1],o={coord:t,x:e.x0,y:e.y0},n={coord:r,x:e.x1,y:e.y1};return _r(i,"cartesian2d")?t&&r&&(Wp(1,t,r,i)||Wp(0,t,r,i))?!0:Up(i,o,n):ve(i,o)||ve(i,n)}function Yp(i,e,t,r,o){var n=r.coordinateSystem,a=i.getItemModel(e),s,l=J(a.get(t[0]),o.getWidth()),u=J(a.get(t[1]),o.getHeight());if(!isNaN(l)&&!isNaN(u))s=[l,u];else{if(r.getMarkerPosition){var p=i.getValues(["x0","y0"],e),c=i.getValues(["x1","y1"],e),f=n.clampData(p),h=n.clampData(c),d=[];t[0]==="x0"?d[0]=f[0]>h[0]?c[0]:p[0]:d[0]=f[0]>h[0]?p[0]:c[0],t[1]==="y0"?d[1]=f[1]>h[1]?c[1]:p[1]:d[1]=f[1]>h[1]?p[1]:c[1],s=r.getMarkerPosition(d,t,!0)}else{var v=i.get(t[0],e),m=i.get(t[1],e),g=[v,m];n.clampData&&n.clampData(g,g),s=n.dataToPoint(g,!0)}if(_r(n,"cartesian2d")){var y=n.getAxis("x"),x=n.getAxis("y"),v=i.get(t[0],e),m=i.get(t[1],e);ao(v)?s[0]=y.toGlobalCoord(y.getExtent()[t[0]==="x0"?0:1]):ao(m)&&(s[1]=x.toGlobalCoord(x.getExtent()[t[1]==="y0"?0:1]))}isNaN(l)||(s[0]=l),isNaN(u)||(s[1]=u)}return s}var Xp=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],_v=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.updateTransform=function(t,r,o){r.eachSeries(function(n){var a=bt.getMarkerModelFromSeries(n,"markArea");if(a){var s=a.getData();s.each(function(l){var u=R(Xp,function(c){return Yp(s,l,c,n,o)});s.setItemLayout(l,u);var p=s.getItemGraphicEl(l);p.setShape("points",u)})}},this)},e.prototype.renderSeries=function(t,r,o,n){var a=t.coordinateSystem,s=t.id,l=t.getData(),u=this.markerGroupMap,p=u.get(s)||u.set(s,{group:new et});this.group.add(p.group),this.markKeep(p);var c=Sv(a,t,r);r.setData(c),c.each(function(f){var h=R(Xp,function(z){return Yp(c,f,z,t,n)}),d=a.getAxis("x").scale,v=a.getAxis("y").scale,m=d.getExtent(),g=v.getExtent(),y=[d.parse(c.get("x0",f)),d.parse(c.get("x1",f))],x=[v.parse(c.get("y0",f)),v.parse(c.get("y1",f))];yt(y),yt(x);var _=!(m[0]>y[1]||m[1]<y[0]||g[0]>x[1]||g[1]<x[0]),b=!_;c.setItemLayout(f,{points:h,allClipped:b});var w=c.getItemModel(f),C=w.getModel("itemStyle").getItemStyle(),D=w.get("z2"),A=ue(l,"color");C.fill||(C.fill=A,E(C.fill)&&(C.fill=vo(C.fill,.4))),C.stroke||(C.stroke=A),c.setItemVisual(f,"style",C),c.setItemVisual(f,"z2",W(D,0))}),c.diff(no(p).data).add(function(f){var h=c.getItemLayout(f),d=c.getItemVisual(f,"z2");if(!h.allClipped){var v=new _e({z2:W(d,0),shape:{points:h.points}});c.setItemGraphicEl(f,v),p.group.add(v)}}).update(function(f,h){var d=no(p).data.getItemGraphicEl(h),v=c.getItemLayout(f),m=c.getItemVisual(f,"z2");v.allClipped?d&&p.group.remove(d):(d?ne(d,{z2:W(m,0),shape:{points:v.points}},r,f):d=new _e({shape:{points:v.points}}),c.setItemGraphicEl(f,d),p.group.add(d))}).remove(function(f){var h=no(p).data.getItemGraphicEl(f);p.group.remove(h)}).execute(),c.eachItemGraphicEl(function(f,h){var d=c.getItemModel(h),v=c.getItemVisual(h,"style");f.useStyle(c.getItemVisual(h,"style")),Ne(f,$a(d),{labelFetcher:r,labelDataIndex:h,defaultText:c.getName(h)||"",inheritColor:E(v.fill)?vo(v.fill,1):M.color.neutral99}),Fa(f,d),Ga(f,null,null,d.get(["emphasis","disabled"])),j(f).dataModel=r}),no(p).data=c,p.group.silent=r.get("silent")||t.get("silent")},e.type="markArea",e})(ar);function Sv(i,e,t){var r,o,n=["x0","y0","x1","y1"];if(i){var a=R(i&&i.dimensions,function(u){var p=e.getData(),c=p.getDimensionInfo(p.mapDimension(u))||{};return N(N({},c),{name:u,ordinalMeta:null})});o=R(n,function(u,p){return{name:u,type:a[p%2].type}}),r=new Ht(o,t)}else o=[{name:"value",type:"float"}],r=new Ht(o,t);var s=R(t.get("data"),H(yv,e,i,t));i&&(s=St(s,H(xv,i)));var l=i?function(u,p,c,f){var h=u.coord[Math.floor(f/2)][f%2];return Ze(h,o[f])}:function(u,p,c,f){return Ze(u.value,o[f])};return r.initData(s,null,l),r.hasItemOption=!0,r}var Kp=_v;function bv(i){i.registerComponentModel(Zp),i.registerComponentView(Kp),i.registerPreprocessor(function(e){Ie(e.series,"markArea")&&(e.markArea=e.markArea||{})})}var wv=function(i,e){if(e==="all")return{type:"all",title:i.getLocaleModel().get(["legend","selector","all"])};if(e==="inverse")return{type:"inverse",title:i.getLocaleModel().get(["legend","selector","inverse"])}},Cv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t.layoutMode={type:"box",ignoreSize:!0},t}return e.prototype.init=function(t,r,o){this.mergeDefaultAndTheme(t,o),t.selected=t.selected||{},this._updateSelector(t)},e.prototype.mergeOption=function(t,r){i.prototype.mergeOption.call(this,t,r),this._updateSelector(t)},e.prototype._updateSelector=function(t){var r=t.selector,o=this.ecModel;r===!0&&(r=t.selector=["all","inverse"]),I(r)&&S(r,function(n,a){E(n)&&(n={type:n}),r[a]=tt(n,wv(o,n.type))})},e.prototype.optionUpdated=function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&this.get("selectedMode")==="single"){for(var r=!1,o=0;o<t.length;o++){var n=t[o].get("name");if(this.isSelected(n)){this.select(n),r=!0;break}}!r&&this.select(t[0].get("name"))}},e.prototype._updateData=function(t){var r=[],o=[];t.eachRawSeries(function(l){var u=l.name;o.push(u);var p;if(l.legendVisualProvider){var c=l.legendVisualProvider,f=c.getAllNames();t.isSeriesFiltered(l)||(o=o.concat(f)),f.length?r=r.concat(f):p=!0}else p=!0;p&&Aa(l)&&r.push(l.name)}),this._availableNames=o;var n=this.get("data")||r,a=q(),s=R(n,function(l){return(E(l)||oe(l))&&(l={name:l}),a.get(l.name)?null:(a.set(l.name,!0),new at(l,this,this.ecModel))},this);this._data=St(s,function(l){return!!l})},e.prototype.getData=function(){return this._data},e.prototype.select=function(t){var r=this.option.selected,o=this.get("selectedMode");if(o==="single"){var n=this._data;S(n,function(a){r[a.get("name")]=!1})}r[t]=!0},e.prototype.unSelect=function(t){this.get("selectedMode")!=="single"&&(this.option.selected[t]=!1)},e.prototype.toggleSelected=function(t){var r=this.option.selected;r.hasOwnProperty(t)||(r[t]=!0),this[r[t]?"unSelect":"select"](t)},e.prototype.allSelect=function(){var t=this._data,r=this.option.selected;S(t,function(o){r[o.get("name",!0)]=!0})},e.prototype.inverseSelect=function(){var t=this._data,r=this.option.selected;S(t,function(o){var n=o.get("name",!0);r.hasOwnProperty(n)||(r[n]=!0),r[n]=!r[n]})},e.prototype.isSelected=function(t){var r=this.option.selected;return!(r.hasOwnProperty(t)&&!r[t])&&st(this._availableNames,t)>=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:M.size.m,align:"auto",backgroundColor:M.color.transparent,borderColor:M.color.border,borderRadius:0,borderWidth:0,padding:5,itemGap:8,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:M.color.disabled,inactiveBorderColor:M.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:M.color.disabled,inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:M.color.secondary},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:M.color.tertiary,borderWidth:1,borderColor:M.color.border},emphasis:{selectorLabel:{show:!0,color:M.color.quaternary}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1},triggerEvent:!1},e})(Z),Pr=Cv;var sr=H,Vn=S,so=et,Tv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!1,t}return e.prototype.init=function(){this.group.add(this._contentGroup=new so),this.group.add(this._selectorGroup=new so),this._isFirstRender=!0},e.prototype.getContentGroup=function(){return this._contentGroup},e.prototype.getSelectorGroup=function(){return this._selectorGroup},e.prototype.render=function(t,r,o){var n=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),!!t.get("show",!0)){var a=t.get("align"),s=t.get("orient");(!a||a==="auto")&&(a=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(a,t,r,o,l,s,u);var p=gt(t,o).refContainer,c=t.getBoxLayoutParams(),f=t.get("padding"),h=pt(c,p,f),d=this.layoutInner(t,a,h,n,l,u),v=pt(K({width:d.width,height:d.height},c),p,f);this.group.x=v.x-d.x,this.group.y=v.y-d.y,this.group.markRedraw(),this.group.add(this._backgroundEl=Yi(d,t))}},e.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},e.prototype.renderInner=function(t,r,o,n,a,s,l){var u=this.getContentGroup(),p=q(),c=r.get("selectedMode"),f=r.get("triggerEvent"),h=[];o.eachRawSeries(function(d){!d.get("legendHoverLink")&&h.push(d.id)}),Vn(r.getData(),function(d,v){var m=this,g=d.get("name");if(!this.newlineDisabled&&(g===""||g===`
21
+ `)){var y=new so;y.newline=!0,u.add(y);return}var x=o.getSeriesByName(g)[0];if(!p.get(g))if(x){var _=x.getData(),b=_.getVisual("legendLineStyle")||{},w=_.getVisual("legendIcon"),C=_.getVisual("style"),D=this._createItem(x,g,v,d,r,t,b,C,w,c,n);D.on("click",sr(qp,g,null,n,h)).on("mouseover",sr(Un,x.name,null,n,h)).on("mouseout",sr(Nn,x.name,null,n,h)),o.ssr&&D.eachChild(function(A){var z=j(A);z.seriesIndex=x.seriesIndex,z.dataIndex=v,z.ssrType="legend"}),f&&D.eachChild(function(A){m.packEventData(A,r,x,v,g)}),p.set(g,!0)}else o.eachRawSeries(function(A){var z=this;if(!p.get(g)&&A.legendVisualProvider){var L=A.legendVisualProvider;if(!L.containName(g))return;var Y=L.indexOfName(g),P=L.getItemVisual(Y,"style"),V=L.getItemVisual(Y,"legendIcon"),$=ma(P.fill);$&&$[3]===0&&($[3]=.2,P=N(N({},P),{fill:ga($,"rgba")}));var it=this._createItem(A,g,v,d,r,t,{},P,V,c,n);it.on("click",sr(qp,null,g,n,h)).on("mouseover",sr(Un,null,g,n,h)).on("mouseout",sr(Nn,null,g,n,h)),o.ssr&&it.eachChild(function(Wt){var re=j(Wt);re.seriesIndex=A.seriesIndex,re.dataIndex=v,re.ssrType="legend"}),f&&it.eachChild(function(Wt){z.packEventData(Wt,r,A,v,g)}),p.set(g,!0)}},this)},this),a&&this._createSelector(a,r,n,s,l)},e.prototype.packEventData=function(t,r,o,n,a){var s={componentType:"legend",componentIndex:r.componentIndex,dataIndex:n,value:a,seriesIndex:o.seriesIndex};j(t).eventData=s},e.prototype._createSelector=function(t,r,o,n,a){var s=this.getSelectorGroup();Vn(t,function(u){var p=u.type,c=new F({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){o.dispatchAction({type:p==="all"?"legendAllSelect":"legendInverseSelect",legendId:r.id})}});s.add(c);var f=r.getModel("selectorLabel"),h=r.getModel(["emphasis","selectorLabel"]);Ne(c,{normal:f,emphasis:h},{defaultText:u.title}),Qt(c)})},e.prototype._createItem=function(t,r,o,n,a,s,l,u,p,c,f){var h=t.visualDrawType,d=a.get("itemWidth"),v=a.get("itemHeight"),m=a.isSelected(r),g=n.get("symbolRotate"),y=n.get("symbolKeepAspect"),x=n.get("icon");p=x||p||"roundRect";var _=Mv(p,n,l,u,h,m,f),b=new so,w=n.getModel("textStyle");if(G(t.getLegendIcon)&&(!x||x==="inherit"))b.add(t.getLegendIcon({itemWidth:d,itemHeight:v,icon:p,iconRotate:g,itemStyle:_.itemStyle,lineStyle:_.lineStyle,symbolKeepAspect:y}));else{var C=x==="inherit"&&t.getData().getVisual("symbol")?g==="inherit"?t.getData().getVisual("symbolRotate"):g:0;b.add(Av({itemWidth:d,itemHeight:v,icon:p,iconRotate:C,itemStyle:_.itemStyle,lineStyle:_.lineStyle,symbolKeepAspect:y}))}var D=s==="left"?d+5:-5,A=s,z=a.get("formatter"),L=r;E(z)&&z?L=z.replace("{name}",r??""):G(z)&&(L=z(r));var Y=m?w.getTextColor():n.get("inactiveColor");b.add(new F({style:nt(w,{text:L,x:D,y:v/2,fill:Y,align:A,verticalAlign:"middle"},{inheritColor:Y})}));var P=new rt({shape:b.getBoundingRect(),style:{fill:"transparent"}}),V=n.getModel("tooltip");return V.get("show")&&Kt({el:P,componentModel:a,itemName:r,itemTooltipOption:V.option}),b.add(P),b.eachChild(function($){$.silent=!0}),P.silent=!c,this.getContentGroup().add(b),Qt(b),b.__legendDataIndex=o,b},e.prototype.layoutInner=function(t,r,o,n,a,s){var l=this.getContentGroup(),u=this.getSelectorGroup();Bt(t.get("orient"),l,t.get("itemGap"),o.width,o.height);var p=l.getBoundingRect(),c=[-p.x,-p.y];if(u.markRedraw(),l.markRedraw(),a){Bt("horizontal",u,t.get("selectorItemGap",!0));var f=u.getBoundingRect(),h=[-f.x,-f.y],d=t.get("selectorButtonGap",!0),v=t.getOrient().index,m=v===0?"width":"height",g=v===0?"height":"width",y=v===0?"y":"x";s==="end"?h[v]+=p[m]+d:c[v]+=f[m]+d,h[1-v]+=p[g]/2-f[g]/2,u.x=h[0],u.y=h[1],l.x=c[0],l.y=c[1];var x={x:0,y:0};return x[m]=p[m]+d+f[m],x[g]=Math.max(p[g],f[g]),x[y]=Math.min(0,f[y]+h[1-v]),x}else return l.x=c[0],l.y=c[1],this.group.getBoundingRect()},e.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},e.type="legend.plain",e})(X);function Mv(i,e,t,r,o,n,a){function s(m,g){m.lineWidth==="auto"&&(m.lineWidth=g.lineWidth>0?2:0),Vn(m,function(y,x){m[x]==="inherit"&&(m[x]=g[x])})}var l=e.getModel("itemStyle"),u=l.getItemStyle(),p=i.lastIndexOf("empty",0)===0?"fill":"stroke",c=l.getShallow("decal");u.decal=!c||c==="inherit"?r.decal:ds(c,a),u.fill==="inherit"&&(u.fill=r[o]),u.stroke==="inherit"&&(u.stroke=r[p]),u.opacity==="inherit"&&(u.opacity=(o==="fill"?r:t).opacity),s(u,r);var f=e.getModel("lineStyle"),h=f.getLineStyle();if(s(h,t),u.fill==="auto"&&(u.fill=r.fill),u.stroke==="auto"&&(u.stroke=r.fill),h.stroke==="auto"&&(h.stroke=r.fill),!n){var d=e.get("inactiveBorderWidth"),v=u[p];u.lineWidth=d==="auto"?r.lineWidth>0&&v?2:0:u.lineWidth,u.fill=e.get("inactiveColor"),u.stroke=e.get("inactiveBorderColor"),h.stroke=f.get("inactiveColor"),h.lineWidth=f.get("inactiveWidth")}return{itemStyle:u,lineStyle:h}}function Av(i){var e=i.icon||"roundRect",t=Pt(e,0,0,i.itemWidth,i.itemHeight,i.itemStyle.fill,i.symbolKeepAspect);return t.setStyle(i.itemStyle),t.rotation=(i.iconRotate||0)*Math.PI/180,t.setOrigin([i.itemWidth/2,i.itemHeight/2]),e.indexOf("empty")>-1&&(t.style.stroke=t.style.fill,t.style.fill=M.color.neutral00,t.style.lineWidth=2),t}function qp(i,e,t,r){Nn(i,e,t,r),t.dispatchAction({type:"legendToggleSelect",name:i??e}),Un(i,e,t,r)}function Un(i,e,t,r){t.usingTHL()||t.dispatchAction({type:"highlight",seriesName:i,name:e,excludeSeriesId:r})}function Nn(i,e,t,r){t.usingTHL()||t.dispatchAction({type:"downplay",seriesName:i,name:e,excludeSeriesId:r})}var lo=Tv;function kr(i,e,t){var r=i==="allSelect"||i==="inverseSelect",o={},n=[];t.eachComponent({mainType:"legend",query:e},function(s){r?s[i]():s[i](e.name),jp(s,o),n.push(s.componentIndex)});var a={};return t.eachComponent("legend",function(s){S(o,function(l,u){s[l?"select":"unSelect"](u)}),jp(s,a)}),r?{selected:a,legendIndex:n}:{name:e.name,selected:a}}function jp(i,e){var t=e||{};return S(i.getData(),function(r){var o=r.get("name");if(!(o===`
22
+ `||o==="")){var n=i.isSelected(o);Xt(t,o)?t[o]=t[o]&&n:t[o]=n}}),t}function $p(i){i.registerAction("legendToggleSelect","legendselectchanged",H(kr,"toggleSelected")),i.registerAction("legendAllSelect","legendselectall",H(kr,"allSelect")),i.registerAction("legendInverseSelect","legendinverseselect",H(kr,"inverseSelect")),i.registerAction("legendSelect","legendselected",H(kr,"select")),i.registerAction("legendUnSelect","legendunselected",H(kr,"unSelect"))}var Jp=Ee(Dv);function Dv(i){var e=i.findComponents({mainType:"legend"});e&&e.length&&i.filterSeries(function(t){for(var r=0;r<e.length;r++)if(!e[r].isSelected(t.name))return!1;return!0})}function Rr(i){i.registerComponentModel(Pr),i.registerComponentView(lo),i.registerProcessor(i.PRIORITY.PROCESSOR.SERIES_FILTER,Jp),i.registerSubTypeDefaulter("legend",function(){return"plain"}),$p(i)}var Iv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.setScrollDataIndex=function(t){this.option.scrollDataIndex=t},e.prototype.init=function(t,r,o){var n=Fe(t);i.prototype.init.call(this,t,r,o),Qp(this,t,n)},e.prototype.mergeOption=function(t,r){i.prototype.mergeOption.call(this,t,r),Qp(this,this.option,t)},e.type="legend.scroll",e.defaultOption=Ot(Pr.defaultOption,{scrollDataIndex:0,pageButtonItemGap:5,pageButtonGap:null,pageButtonPosition:"end",pageFormatter:"{current}/{total}",pageIcons:{horizontal:["M0,0L12,-10L12,10z","M0,0L-12,-10L-12,10z"],vertical:["M0,0L20,0L10,-20z","M0,0L20,0L10,20z"]},pageIconColor:M.color.accent50,pageIconInactiveColor:M.color.accent10,pageIconSize:15,pageTextStyle:{color:M.color.tertiary},animationDurationUpdate:800}),e})(Pr);function Qp(i,e,t){var r=i.getOrient(),o=[1,1];o[r.index]=0,Ge(e,t,{type:"box",ignoreSize:!!o})}var tc=Iv;var ec=et,Bn=["width","height"],Hn=["x","y"],Lv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!0,t._currentIndex=0,t}return e.prototype.init=function(){i.prototype.init.call(this),this.group.add(this._containerGroup=new ec),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new ec)},e.prototype.resetInner=function(){i.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},e.prototype.renderInner=function(t,r,o,n,a,s,l){var u=this;i.prototype.renderInner.call(this,t,r,o,n,a,s,l);var p=this._controllerGroup,c=r.get("pageIconSize",!0),f=I(c)?c:[c,c];d("pagePrev",0);var h=r.getModel("pageTextStyle");p.add(new F({name:"pageText",style:{text:"xx/xx",fill:h.getTextColor(),font:h.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),d("pageNext",1);function d(v,m){var g=v+"DataIndex",y=ae(r.get("pageIcons",!0)[r.getOrient().name][m],{onclick:O(u._pageGo,u,g,r,n)},{x:-f[0]/2,y:-f[1]/2,width:f[0],height:f[1]});y.name=v,p.add(y)}},e.prototype.layoutInner=function(t,r,o,n,a,s){var l=this.getSelectorGroup(),u=t.getOrient().index,p=Bn[u],c=Hn[u],f=Bn[1-u],h=Hn[1-u];a&&Bt("horizontal",l,t.get("selectorItemGap",!0));var d=t.get("selectorButtonGap",!0),v=l.getBoundingRect(),m=[-v.x,-v.y],g=U(o);a&&(g[p]=o[p]-v[p]-d);var y=this._layoutContentAndController(t,n,g,u,p,f,h,c);if(a){if(s==="end")m[u]+=y[p]+d;else{var x=v[p]+d;m[u]-=x,y[c]-=x}y[p]+=v[p]+d,m[1-u]+=y[h]+y[f]/2-v[f]/2,y[f]=Math.max(y[f],v[f]),y[h]=Math.min(y[h],v[h]+m[1-u]),l.x=m[0],l.y=m[1],l.markRedraw()}return y},e.prototype._layoutContentAndController=function(t,r,o,n,a,s,l,u){var p=this.getContentGroup(),c=this._containerGroup,f=this._controllerGroup;Bt(t.get("orient"),p,t.get("itemGap"),n?o.width:null,n?null:o.height),Bt("horizontal",f,t.get("pageButtonItemGap",!0));var h=p.getBoundingRect(),d=f.getBoundingRect(),v=this._showController=h[a]>o[a],m=[-h.x,-h.y];r||(m[n]=p[u]);var g=[0,0],y=[-d.x,-d.y],x=W(t.get("pageButtonGap",!0),t.get("itemGap",!0));if(v){var _=t.get("pageButtonPosition",!0);_==="end"?y[n]+=o[a]-d[a]:g[n]+=d[a]+x}y[1-n]+=h[s]/2-d[s]/2,p.setPosition(m),c.setPosition(g),f.setPosition(y);var b={x:0,y:0};if(b[a]=v?o[a]:h[a],b[s]=Math.max(h[s],d[s]),b[l]=Math.min(0,d[l]+y[1-n]),c.__rectSize=o[a],v){var w={x:0,y:0};w[a]=Math.max(o[a]-d[a]-x,0),w[s]=b[s],c.setClipPath(new rt({shape:w})),c.__rectSize=w[a]}else f.eachChild(function(D){D.attr({invisible:!0,silent:!0})});var C=this._getPageInfo(t);return C.pageIndex!=null&&ne(p,{x:C.contentPosition[0],y:C.contentPosition[1]},v?t:null),this._updatePageInfoView(t,C),b},e.prototype._pageGo=function(t,r,o){var n=this._getPageInfo(r)[t];n!=null&&o.dispatchAction({type:"legendScroll",scrollDataIndex:n,legendId:r.id})},e.prototype._updatePageInfoView=function(t,r){var o=this._controllerGroup;S(["pagePrev","pageNext"],function(p){var c=p+"DataIndex",f=r[c]!=null,h=o.childOfName(p);h&&(h.setStyle("fill",f?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),h.cursor=f?"pointer":"default")});var n=o.childOfName("pageText"),a=t.get("pageFormatter"),s=r.pageIndex,l=s!=null?s+1:0,u=r.pageCount;n&&a&&n.setStyle("text",E(a)?a.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):a({current:l,total:u}))},e.prototype._getPageInfo=function(t){var r=t.get("scrollDataIndex",!0),o=this.getContentGroup(),n=this._containerGroup.__rectSize,a=t.getOrient().index,s=Bn[a],l=Hn[a],u=this._findTargetItemIndex(r),p=o.children(),c=p[u],f=p.length,h=f?1:0,d={contentPosition:[o.x,o.y],pageCount:h,pageIndex:h-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!c)return d;var v=_(c);d.contentPosition[a]=-v.s;for(var m=u+1,g=v,y=v,x=null;m<=f;++m)x=_(p[m]),(!x&&y.e>g.s+n||x&&!b(x,g.s))&&(y.i>g.i?g=y:g=x,g&&(d.pageNextDataIndex==null&&(d.pageNextDataIndex=g.i),++d.pageCount)),y=x;for(var m=u-1,g=v,y=v,x=null;m>=-1;--m)x=_(p[m]),(!x||!b(y,x.s))&&g.i<y.i&&(y=g,d.pagePrevDataIndex==null&&(d.pagePrevDataIndex=g.i),++d.pageCount,++d.pageIndex),g=x;return d;function _(w){if(w){var C=w.getBoundingRect(),D=C[l]+w[l];return{s:D,e:D+C[s],i:w.__legendDataIndex}}}function b(w,C){return w.e>=C&&w.s<=C+n}},e.prototype._findTargetItemIndex=function(t){if(!this._showController)return 0;var r,o=this.getContentGroup(),n;return o.eachChild(function(a,s){var l=a.__legendDataIndex;n==null&&l!=null&&(n=s),l===t&&(r=s)}),r??n},e.type="legend.scroll",e})(lo),rc=Lv;function Gn(i){i.registerAction("legendScroll","legendscroll",function(e,t){var r=e.scrollDataIndex;r!=null&&t.eachComponent({mainType:"legend",subType:"scroll",query:e},function(o){o.setScrollDataIndex(r)})})}function Fn(i){ft(Rr),i.registerComponentModel(tc),i.registerComponentView(rc),Gn(i)}function zv(i){ft(Rr),ft(Fn)}var Ov=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.inside",e.defaultOption=Ot(ce.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e})(ce),ic=Ov;var Zn=Q();function oc(i,e,t){Zn(i).coordSysRecordMap.each(function(r){var o=r.dataZoomInfoMap.get(e.uid);o&&(o.getRange=t)})}function nc(i,e){for(var t=Zn(i).coordSysRecordMap,r=t.keys(),o=0;o<r.length;o++){var n=r[o],a=t.get(n),s=a.dataZoomInfoMap;if(s){var l=e.uid,u=s.get(l);u&&(s.removeKey(l),s.keys().length||ac(t,a))}}}function ac(i,e){if(e){i.removeKey(e.model.uid);var t=e.controller;t&&t.dispose()}}function Pv(i,e){var t={model:e,containsPoint:H(Rv,e),dispatchAction:H(kv,i),dataZoomInfoMap:null,controller:null},r=t.controller=new gi(i.getZr());return S(["pan","zoom","scrollMove"],function(o){r.on(o,function(n){var a=[];t.dataZoomInfoMap.each(function(s){if(n.isAvailableBehavior(s.model.option)){var l=(s.getRange||{})[o],u=l&&l(s.dzReferCoordSysInfo,t.model.mainType,t.controller,n);!s.model.get("disabled",!0)&&u&&a.push({dataZoomId:s.model.id,start:u[0],end:u[1]})}}),a.length&&t.dispatchAction(a)})}),t}function kv(i,e){i.isDisposed()||i.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:e})}function Rv(i,e,t,r){return i.coordinateSystem.containPoint([t,r])}function Ev(i,e,t){var r,o="type_",n={type_true:2,type_move:1,type_false:0,type_undefined:-1},a=!0,s,l;return i.each(function(u){var p=u.model,c=p.get("disabled",!0)?!1:p.get("zoomLock",!0)?"move":!0;n[o+c]>n[o+r]&&(r=c),a=a&&p.get("preventDefaultMouseMove",!0),s=W(p.get("cursorGrab",!0),s),l=W(p.get("cursorGrabbing",!0),l)}),{controlType:r,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!a,api:t,zInfo:{component:e.model},triggerInfo:{roamTrigger:null,isInSelf:e.containsPoint},cursorGrab:s,cursorGrabbing:l}}}function sc(i){i.registerUpdateLifecycle("coordsys:aftercreate",function(e,t){var r=Zn(t),o=r.coordSysRecordMap||(r.coordSysRecordMap=q());o.each(function(n){n.dataZoomInfoMap=null}),e.eachComponent({mainType:"dataZoom",subType:"inside"},function(n){var a=Fi(n);S(a.infoList,function(s){var l=s.model.uid,u=o.get(l)||o.set(l,Pv(t,s.model)),p=u.dataZoomInfoMap||(u.dataZoomInfoMap=q());p.set(n.uid,{dzReferCoordSysInfo:s,model:n,getRange:null})})}),o.each(function(n){var a=n.controller,s,l=n.dataZoomInfoMap;if(l){var u=l.keys()[0];u!=null&&(s=l.get(u))}if(!s){ac(o,n);return}var p=Ev(l,n,t);a.enable(p.controlType,p.opt),qt(n,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var Uv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type="dataZoom.inside",t}return e.prototype.render=function(t,r,o){if(i.prototype.render.apply(this,arguments),t.noTarget()){this._clear();return}this.range=t.getPercentRange(),oc(o,t,{pan:O(Wn.pan,this),zoom:O(Wn.zoom,this),scrollMove:O(Wn.scrollMove,this)})},e.prototype.dispose=function(){this._clear(),i.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){nc(this.api,this.dataZoomModel),this.range=null},e.type="dataZoom.inside",e})(or),Wn={zoom:function(i,e,t,r){var o=this.range,n=o.slice(),a=i.axisModels[0];if(a){var s=Yn[e](null,[r.originX,r.originY],a,t,i),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(n[1]-n[0])+n[0],u=Math.max(1/r.scale,0);n[0]=(n[0]-l)*u+l,n[1]=(n[1]-l)*u+l;var p=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(Et(0,n,[0,100],0,p.minSpan,p.maxSpan),this.range=n,o[0]!==n[0]||o[1]!==n[1])return n}},pan:lc(function(i,e,t,r,o,n){var a=Yn[r]([n.oldX,n.oldY],[n.newX,n.newY],e,o,t);return a.signal*(i[1]-i[0])*a.pixel/a.pixelLength}),scrollMove:lc(function(i,e,t,r,o,n){var a=Yn[r]([0,0],[n.scrollDelta,n.scrollDelta],e,o,t);return a.signal*(i[1]-i[0])*n.scrollDelta})};function lc(i){return function(e,t,r,o){var n=this.range,a=n.slice(),s=e.axisModels[0];if(s){var l=i(a,s,e,t,r,o);if(Et(l,a,[0,100],"all"),this.range=a,n[0]!==a[0]||n[1]!==a[1])return a}}}var Yn={grid:function(i,e,t,r,o){var n=t.axis,a={},s=o.model.coordinateSystem.getRect();return i=i||[0,0],n.dim==="x"?(a.pixel=e[0]-i[0],a.pixelLength=s.width,a.pixelStart=s.x,a.signal=n.inverse?1:-1):(a.pixel=e[1]-i[1],a.pixelLength=s.height,a.pixelStart=s.y,a.signal=n.inverse?-1:1),a},polar:function(i,e,t,r,o){var n=t.axis,a={},s=o.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return i=i?s.pointToCoord(i):[0,0],e=s.pointToCoord(e),t.mainType==="radiusAxis"?(a.pixel=e[0]-i[0],a.pixelLength=l[1]-l[0],a.pixelStart=l[0],a.signal=n.inverse?1:-1):(a.pixel=e[1]-i[1],a.pixelLength=u[1]-u[0],a.pixelStart=u[0],a.signal=n.inverse?-1:1),a},singleAxis:function(i,e,t,r,o){var n=t.axis,a=o.model.coordinateSystem.getRect(),s={};return i=i||[0,0],n.orient==="horizontal"?(s.pixel=e[0]-i[0],s.pixelLength=a.width,s.pixelStart=a.x,s.signal=n.inverse?1:-1):(s.pixel=e[1]-i[1],s.pixelLength=a.height,s.pixelStart=a.y,s.signal=n.inverse?-1:1),s}},uc=Uv;function Xn(i){Ae(i),i.registerComponentModel(ic),i.registerComponentView(uc),sc(i)}var Nv=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.slider",e.layoutMode="box",e.defaultOption=Ot(ce.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:M.color.accent10,borderRadius:0,backgroundColor:M.color.transparent,dataBackground:{lineStyle:{color:M.color.accent30,width:.5},areaStyle:{color:M.color.accent20,opacity:.2}},selectedDataBackground:{lineStyle:{color:M.color.accent40,width:.5},areaStyle:{color:M.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:M.color.neutral00,borderColor:M.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:M.color.accent40,opacity:.5},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:M.color.tertiary},brushSelect:!0,brushStyle:{color:M.color.accent30,opacity:.3},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:M.color.accent40},moveHandleStyle:{opacity:.8}},defaultLocationEdgeGap:15}),e})(ce),pc=Nv;var Er=rt,Bv=1,Kn=30,Hv=7,Vr="horizontal",cc="vertical",Gv=5,Fv=["line","bar","candlestick","scatter"],Zv={easing:"cubicOut",duration:100,delay:0},Wv=(function(i){T(e,i);function e(){var t=i!==null&&i.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,o,n){if(i.prototype.render.apply(this,arguments),qt(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}(!n||n.type!=="dataZoom"||n.from!==this.uid)&&this._buildView(),this._updateView()},e.prototype.dispose=function(){this._clear(),i.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){Se(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 et;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(r),this._positionGroup()},e.prototype._resetLocation=function(){var t=this.dataZoomModel,r=this.api,o=t.get("brushSelect"),n=o?Hv:0,a=gt(t,r).refContainer,s=this._findCoordRect(),l=t.get("defaultLocationEdgeGap",!0)||0,u=this._orient===Vr?{right:a.width-s.x-s.width,top:a.height-Kn-l-n,width:s.width,height:Kn}:{right:l,top:s.y,width:Kn,height:s.height},p=Fe(t.option);S(["right","top","width","height"],function(f){p[f]==="ph"&&(p[f]=u[f])});var c=pt(p,a);this._location={x:c.x,y:c.y},this._size=[c.width,c.height],this._orient===cc&&this._size.reverse()},e.prototype._positionGroup=function(){var t=this.group,r=this._location,o=this._orient,n=this.dataZoomModel.getFirstTargetAxisModel(),a=n&&n.get("inverse"),s=this._displayables.sliderGroup,l=(this._dataShadowInfo||{}).otherAxisInverse;s.attr(o===Vr&&!a?{scaleY:l?1:-1,scaleX:1}:o===Vr&&a?{scaleY:l?1:-1,scaleX:-1}:o===cc&&!a?{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]),p=isNaN(u.x)?0:u.x,c=isNaN(u.y)?0:u.y;t.x=r.x-p,t.y=r.y-c,t.markRedraw()},e.prototype._getViewExtent=function(){return[0,this._size[0]]},e.prototype._renderBackground=function(){var t=this.dataZoomModel,r=this._size,o=this._displayables.sliderGroup,n=t.get("brushSelect");o.add(new Er({silent:!0,shape:{x:0,y:0,width:r[0],height:r[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var a=new Er({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();n?(a.on("mousedown",this._onBrushStart,this),a.cursor="crosshair",s.on("mousemove",this._onBrush),s.on("mouseup",this._onBrushEnd)):(s.off("mousemove",this._onBrush),s.off("mouseup",this._onBrushEnd)),o.add(a)},e.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!t)return;var r=this._size,o=this._shadowSize||[],n=t.series,a=n.getRawData(),s=n.getShadowDim&&n.getShadowDim(),l=s&&a.getDimensionInfo(s)?n.getShadowDim():t.otherDim;if(l==null)return;var u=this._shadowPolygonPts,p=this._shadowPolylinePts;if(a!==this._shadowData||l!==this._shadowDim||r[0]!==o[0]||r[1]!==o[1]){var c=a.getDataExtent(t.thisDim),f=a.getDataExtent(l),h=(f[1]-f[0])*.3;f=[f[0]-h,f[1]+h];var d=[0,r[1]],v=[0,r[0]],m=[[r[0],0],[0,0]],g=[],y=v[1]/Math.max(1,a.count()-1),x=r[0]/(c[1]-c[0]),_=t.thisAxis.type==="time",b=-y,w=Math.round(a.count()/r[0]),C;a.each([t.thisDim,l],function(Y,P,V){if(w>0&&V%w){_||(b+=y);return}b=_?(+Y-c[0])*x:b+y;var $=P==null||isNaN(P)||P==="",it=$?0:lt(P,f,d,!0);$&&!C&&V?(m.push([m[m.length-1][0],0]),g.push([g[g.length-1][0],0])):!$&&C&&(m.push([b,0]),g.push([b,0])),$||(m.push([b,it]),g.push([b,it])),C=$}),u=this._shadowPolygonPts=m,p=this._shadowPolylinePts=g}this._shadowData=a,this._shadowDim=l,this._shadowSize=[r[0],r[1]];var D=this.dataZoomModel;function A(Y){var P=D.getModel(Y?"selectedDataBackground":"dataBackground"),V=new et,$=new _e({shape:{points:u},segmentIgnoreThreshold:1,style:P.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),it=new jr({shape:{points:p},segmentIgnoreThreshold:1,style:P.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return V.add($),V.add(it),V}for(var z=0;z<3;z++){var L=A(z===1);this._displayables.sliderGroup.add(L),this._displayables.dataShadowSegs.push(L)}},e.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,r=t.get("showDataShadow");if(r!==!1){var o,n=this.ecModel;return t.eachTargetAxis(function(a,s){var l=t.getAxisProxy(a,s).getTargetSeriesModels();S(l,function(u){if(!o&&!(r!==!0&&st(Fv,u.get("type"))<0)){var p=n.getComponent(Ut(a),s).axis,c=Yv(a),f,h=u.coordinateSystem;c!=null&&h.getOtherAxis&&(f=h.getOtherAxis(p).inverse),c=u.getData().mapDimension(c);var d=u.getData().mapDimension(a);o={thisAxis:p,series:u,thisDim:d,otherDim:c,otherAxisInverse:f}}},this)},this),o}},e.prototype._renderHandle=function(){var t=this.group,r=this._displayables,o=r.handles=[null,null],n=r.handleLabels=[null,null],a=this._displayables.sliderGroup,s=this._size,l=this.dataZoomModel,u=this.api,p=l.get("borderRadius")||0,c=l.get("brushSelect"),f=r.filler=new Er({silent:c,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});a.add(f),a.add(new Er({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:s[0],height:s[1],r:p},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:Bv,fill:M.color.transparent}})),S([0,1],function(x){var _=l.get("handleIcon");!cs[_]&&_.indexOf("path://")<0&&_.indexOf("image://")<0&&(_="path://"+_);var b=Pt(_,-1,0,2,2,null,!0);b.attr({cursor:Xv(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 w=b.getBoundingRect(),C=l.get("handleSize");this._handleHeight=J(C,this._size[1]),this._handleWidth=w.width/w.height*this._handleHeight,b.setStyle(l.getModel("handleStyle").getItemStyle()),b.style.strokeNoScale=!0,b.rectHover=!0,b.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),Qt(b);var D=l.get("handleColor");D!=null&&(b.style.fill=D),a.add(o[x]=b);var A=l.getModel("textStyle"),z=l.get("handleLabel")||{},L=z.show||!1;t.add(n[x]=new F({silent:!0,invisible:!L,style:nt(A,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:A.getTextColor(),font:A.getFont()}),z2:10}))},this);var h=f;if(c){var d=J(l.get("moveHandleSize"),s[1]),v=r.moveHandle=new rt({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:s[1]-.5,height:d}}),m=d*.8,g=r.moveHandleIcon=Pt(l.get("moveHandleIcon"),-m/2,-m/2,m,m,M.color.neutral00,!0);g.silent=!0,g.y=s[1]+d/2-.5,v.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var y=Math.min(s[1]/2,Math.max(d,10));h=r.moveZone=new rt({invisible:!0,shape:{y:s[1]-y,height:d+y}}),h.on("mouseover",function(){u.enterEmphasis(v)}).on("mouseout",function(){u.leaveEmphasis(v)}),a.add(v),a.add(g),a.add(h)}h.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=[lt(t[0],[0,100],r,!0),lt(t[1],[0,100],r,!0)]},e.prototype._updateInterval=function(t,r){var o=this.dataZoomModel,n=this._handleEnds,a=this._getViewExtent(),s=o.findRepresentativeAxisProxy().getMinMaxSpan(),l=[0,100];Et(r,n,a,o.get("zoomLock")?"all":t,s.minSpan!=null?lt(s.minSpan,l,a,!0):null,s.maxSpan!=null?lt(s.maxSpan,l,a,!0):null);var u=this._range,p=this._range=yt([lt(n[0],a,l,!0),lt(n[1],a,l,!0)]);return!u||u[0]!==p[0]||u[1]!==p[1]},e.prototype._updateView=function(t){var r=this._displayables,o=this._handleEnds,n=yt(o.slice()),a=this._size;S([0,1],function(h){var d=r.handles[h],v=this._handleHeight;d.attr({scaleX:v/2,scaleY:v/2,x:o[h]+(h?-1:1),y:a[1]/2-v/2})},this),r.filler.setShape({x:n[0],y:0,width:n[1]-n[0],height:a[1]});var s={x:n[0],width:n[1]-n[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,n[0],n[1],a[0]],p=0;p<l.length;p++){var c=l[p],f=c.getClipPath();f||(f=new rt,c.setClipPath(f)),f.setShape({x:u[p],y:0,width:u[p+1]-u[p],height:a[1]})}this._updateDataInfo(t)},e.prototype._updateDataInfo=function(t){var r=this.dataZoomModel,o=this._displayables,n=o.handleLabels,a=this._orient,s=["",""];if(r.get("showDetail")){var l=r.findRepresentativeAxisProxy(),u=l.getAxisModel().axis.scale;if(l){var p=this._range,c;if(t){var f={start:p[0],end:p[1]},h=Zi(r,l);if(h){var d=h.calculateDataWindow(f).percentInverted;f={start:d[0],end:d[1]}}c=l.calculateDataWindow(f)}else c=l.getWindow();s=[fc(r,0,c,u),fc(r,1,c,u)]}}var v=yt(this._handleEnds.slice());m.call(this,0),m.call(this,1);function m(g){var y=Ve(o.handles[g].parent,this.group),x=$r(g===0?"right":"left",y),_=this._handleWidth/2+Gv,b=At([v[g]+(g===0?-_:_),this._size[1]/2],y);n[g].setStyle({x:b[0],y:b[1],verticalAlign:a===Vr?"middle":x,align:a===Vr?x:"center",text:s[g]})}},e.prototype._onOverDataInfoTriggerArea=function(t){this._isOverDataInfoTriggerArea=t,this._showDataInfo(t)},e.prototype._showDataInfo=function(t){var r=this.dataZoomModel.get("handleLabel")||{},o=r.show||!1,n=this.dataZoomModel.getModel(["emphasis","handleLabel"]),a=n.get("show")||!1,s=t||this._dragging?a:o,l=this._displayables,u=l.handleLabels;u[0].attr("invisible",!s),u[1].attr("invisible",!s),l.moveHandle&&this.api[s?"enterEmphasis":"leaveEmphasis"](l.moveHandle,1)},e.prototype._onActualMoveZoneDrift=function(t,r,o){this.api.getZr().setCursorStyle("grabbing"),this._onDragMove("all",t,r,o)},e.prototype._onActualMoveZoneDragStart=function(t){t.target.attr("cursor","grabbing"),this._showDataInfo(!0)},e.prototype._onActualMoveZoneDragEnd=function(t){t.target.attr("cursor","grab"),this._onDragEnd()},e.prototype._onDragMove=function(t,r,o,n){this._dragging=!0,Jt(n.event);var a=this._displayables.sliderGroup.getLocalTransform(),s=At([r,o],a,!0),l=this._updateInterval(t,s[0]),u=this.dataZoomModel.get("realtime");this._updateView(!u),l&&u&&this._dispatchZoomAction(!0)},e.prototype._onDragEnd=function(){this._dragging=!1,this._isOverDataInfoTriggerArea||this._showDataInfo(!1);var t=this.dataZoomModel.get("realtime");!t&&this._dispatchZoomAction(!1)},e.prototype._onClickPanel=function(t){var r=this._size,o=this._displayables.sliderGroup.transformCoordToLocal(t.offsetX,t.offsetY);if(!(o[0]<0||o[0]>r[0]||o[1]<0||o[1]>r[1])){var n=this._handleEnds,a=(n[0]+n[1])/2,s=this._updateInterval("all",o[0]-a);this._updateView(),s&&this._dispatchZoomAction(!1)}},e.prototype._onBrushStart=function(t){var r=t.offsetX,o=t.offsetY;this._brushStart=new wt(r,o),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 o=r.shape,n=+new Date;if(!(n-this._brushStartTime<200&&Math.abs(o.width)<5)){var a=this._getViewExtent(),s=[0,100],l=this._handleEnds=[o.x,o.x+o.width],u=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();Et(0,l,a,0,u.minSpan!=null?lt(u.minSpan,s,a,!0):null,u.maxSpan!=null?lt(u.maxSpan,s,a,!0):null),this._range=yt([lt(l[0],a,s,!0),lt(l[1],a,s,!0)]),this._updateView(),this._dispatchZoomAction(!1)}}}},e.prototype._onBrush=function(t){this._brushing&&(Jt(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},e.prototype._updateBrushRect=function(t,r){var o=this._displayables,n=this.dataZoomModel,a=o.brushRect;a||(a=o.brushRect=new Er({silent:!0,style:n.getModel("brushStyle").getItemStyle()}),o.sliderGroup.add(a)),a.attr("ignore",!1);var s=this._brushStart,l=this._displayables.sliderGroup,u=l.transformCoordToLocal(t,r),p=l.transformCoordToLocal(s.x,s.y),c=this._size;u[0]=Math.max(Math.min(c[0],u[0]),0),a.setShape({x:p[0],y:0,width:u[0]-p[0],height:c[1]})},e.prototype._dispatchZoomAction=function(t){var r=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?Zv:null,start:r[0],end:r[1]})},e.prototype._findCoordRect=function(){var t,r=Fi(this.dataZoomModel).infoList;if(!t&&r.length){var o=r[0].model.coordinateSystem;t=o.getRect&&o.getRect()}if(!t){var n=this.api.getWidth(),a=this.api.getHeight();t={x:n*.2,y:a*.2,width:n*.6,height:a*.6}}return t},e.type="dataZoom.slider",e})(or);function fc(i,e,t,r){var o=i.get("labelFormatter"),n=i.get("labelPrecision");(n==null||n==="auto")&&(n=t.valuePrecision);var a=t.value[e],s=a==null||isNaN(a)?"":ci(r)||pi(r)?r.getLabel({value:Math.round(a)}):isFinite(n)?ge(a,n,!0):a+"";return G(o)?o(a,s):E(o)?o.replace("{value}",s):s}function Yv(i){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[i]}function Xv(i){return i==="vertical"?"ns-resize":"ew-resize"}var hc=Wv;function qn(i){i.registerComponentModel(pc),i.registerComponentView(hc),Ae(i)}function Kv(i){ft(Xn),ft(qn)}var qv={get:function(i,e,t){var r=U((jv[i]||{})[e]);return t&&I(r)?r[r.length-1]:r}},jv={color:{active:["#006edd","#e0ffff"],inactive:[M.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]}},uo=qv;var dc=mt.mapVisual,$v=mt.eachVisual,Jv=I,jn=S,Qv=yt,tm=lt,em=(function(i){T(e,i);function e(){var t=i!==null&&i.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,o){this.mergeDefaultAndTheme(t,o)},e.prototype.optionUpdated=function(t,r){var o=this.option;!r&&ji(o,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=Lr(this.option.controller,r,t),this.targetVisuals=Lr(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 o=[];return jn(r,function(l){if(l.seriesIndex!=null)o.push(l.seriesIndex);else if(l.seriesId!=null){var u;t.ecModel.eachSeries(function(p){p.id===l.seriesId&&(u=p)}),u&&o.push(u.componentIndex)}}),o}var n=this.option.seriesId,a=this.option.seriesIndex;a==null&&n==null&&(a="all");var s=Zr(this.ecModel,"series",{index:a,id:n},{useDefault:!1,enableAll:!0,enableNone:!1}).models;return R(s,function(l){return l.componentIndex})},e.prototype.eachTargetSeries=function(t,r){S(this.getTargetSeriesIndices(),function(o){var n=this.ecModel.getSeriesByIndex(o);n&&t.call(r,n)},this)},e.prototype.isTargetSeries=function(t){var r=!1;return this.eachTargetSeries(function(o){o===t&&(r=!0)}),r},e.prototype.formatValueText=function(t,r,o){var n=this.option,a=n.precision,s=this.dataBound,l=n.formatter,u;o=o||["<",">"],I(t)&&(t=t.slice(),u=!0);var p=r?t:u?[c(t[0]),c(t[1])]:c(t);if(E(l))return l.replace("{value}",u?p[0]:p).replace("{value2}",u?p[1]:p);if(G(l))return u?l(t[0],t[1]):l(t);if(u)return t[0]===s[0]?o[0]+" "+p[1]:t[1]===s[1]?o[1]+" "+p[0]:p[0]+" - "+p[1];return p;function c(f){return f===s[0]?"min":f===s[1]?"max":(+f).toFixed(Math.min(a,20))}},e.prototype.resetExtent=function(){var t=this.option,r=Qv([t.min,t.max]);this._dataExtent=r},e.prototype.getDimension=function(t){var r=this,o=this.option.seriesTargets;if(o){var n=sa(o,function(a){return a.seriesIndex!=null&&a.seriesIndex===t||a.seriesId!=null&&a.seriesId===r.ecModel.getSeriesByIndex(t).id});if(n)return n.dimension}return this.option.dimension},e.prototype.getDataDimensionIndex=function(t){var r=t.hostModel.seriesIndex,o=this.getDimension(r);if(o!=null)return t.getDimensionIndex(o);for(var n=t.dimensions,a=n.length-1;a>=0;a--){var s=n[a],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,o={inRange:r.inRange,outOfRange:r.outOfRange},n=r.target||(r.target={}),a=r.controller||(r.controller={});tt(n,o),tt(a,o);var s=this.isCategory();l.call(this,n),l.call(this,a),u.call(this,n,"inRange","outOfRange"),p.call(this,a);function l(c){Jv(r.color)&&!c.inRange&&(c.inRange={color:r.color.slice().reverse()}),c.inRange=c.inRange||{color:t.get("gradientColor")}}function u(c,f,h){var d=c[f],v=c[h];d&&!v&&(v=c[h]={},jn(d,function(m,g){if(mt.isValidType(g)){var y=uo.get(g,"inactive",s);y!=null&&(v[g]=y,g==="color"&&!v.hasOwnProperty("opacity")&&!v.hasOwnProperty("colorAlpha")&&(v.opacity=[0,0]))}}))}function p(c){var f=(c.inRange||{}).symbol||(c.outOfRange||{}).symbol,h=(c.inRange||{}).symbolSize||(c.outOfRange||{}).symbolSize,d=this.get("inactiveColor"),v=this.getItemSymbol(),m=v||"roundRect";jn(this.stateList,function(g){var y=this.itemSize,x=c[g];x||(x=c[g]={color:s?d:[d]}),x.symbol==null&&(x.symbol=f&&U(f)||(s?m:[m])),x.symbolSize==null&&(x.symbolSize=h&&U(h)||(s?y[0]:[y[0],y[0]])),x.symbol=dc(x.symbol,function(w){return w==="none"?m:w});var _=x.symbolSize;if(_!=null){var b=-1/0;$v(_,function(w){w>b&&(b=w)}),x.symbolSize=dc(_,function(w){return tm(w,[0,b],[0,y[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:M.color.transparent,borderColor:M.color.borderTint,contentColor:M.color.theme[0],inactiveColor:M.color.disabled,borderWidth:0,padding:M.size.m,textGap:10,precision:0,textStyle:{color:M.color.secondary}},e})(Z),lr=em;var vc=[20,140],rm=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(t,r){i.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(o){o.mappingMethod="linear",o.dataExtent=this.getExtent()}),this._resetRange()},e.prototype.resetItemSize=function(){i.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;(t[0]==null||isNaN(t[0]))&&(t[0]=vc[0]),(t[1]==null||isNaN(t[1]))&&(t[1]=vc[1])},e.prototype._resetRange=function(){var t=this.getExtent(),r=this.option.range;!r||r.auto?(t.auto=1,this.option.range=t):I(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(){i.prototype.completeVisualOption.apply(this,arguments),S(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=yt((this.get("range")||[]).slice());return r[0]>t[1]&&(r[0]=t[1]),r[1]>t[1]&&(r[1]=t[1]),r[0]<t[0]&&(r[0]=t[0]),r[1]<t[0]&&(r[1]=t[0]),r},e.prototype.getValueState=function(t){var r=this.option.range,o=this.getExtent(),n=W(this.option.unboundedRange,!0);return(n&&r[0]<=o[0]||r[0]<=t)&&(n&&r[1]>=o[1]||t<=r[1])?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var r=[];return this.eachTargetSeries(function(o){var n=[],a=o.getData();a.each(this.getDataDimensionIndex(a),function(s,l){t[0]<=s&&s<=t[1]&&n.push(l)},this),r.push({seriesId:o.id,dataIndex:n})},this),r},e.prototype.getVisualMeta=function(t){var r=mc(this,"outOfRange",this.getExtent()),o=mc(this,"inRange",this.option.range.slice()),n=[];function a(h,d){n.push({value:h,color:t(h,d)})}for(var s=0,l=0,u=o.length,p=r.length;l<p&&(!o.length||r[l]<=o[0]);l++)r[l]<o[s]&&a(r[l],"outOfRange");for(var c=1;s<u;s++,c=0)c&&n.length&&a(o[s],"outOfRange"),a(o[s],"inRange");for(var c=1;l<p;l++)(!o.length||o[o.length-1]<r[l])&&(c&&(n.length&&a(n[n.length-1].value,"outOfRange"),c=0),a(r[l],"outOfRange"));var f=n.length;return{stops:n,outerColors:[f?n[0].color:"transparent",f?n[f-1].color:"transparent"]}},e.type="visualMap.continuous",e.defaultOption=Ot(lr.defaultOption,{align:"auto",calculable:!1,hoverLink:!0,realtime:!0,handleIcon:"path://M-11.39,9.77h0a3.5,3.5,0,0,1-3.5,3.5h-22a3.5,3.5,0,0,1-3.5-3.5h0a3.5,3.5,0,0,1,3.5-3.5h22A3.5,3.5,0,0,1-11.39,9.77Z",handleSize:"120%",handleStyle:{borderColor:M.color.neutral00,borderWidth:1},indicatorIcon:"circle",indicatorSize:"50%",indicatorStyle:{borderColor:M.color.neutral00,borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:M.color.shadow}}),e})(lr);function mc(i,e,t){if(t[0]===t[1])return t.slice();for(var r=200,o=(t[1]-t[0])/r,n=t[0],a=[],s=0;s<=r&&n<t[1];s++)a.push(n),n+=o;return a.push(t[1]),a}var gc=rm;var im=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t.autoPositionValues={left:1,right:1,top:1,bottom:1},t}return e.prototype.init=function(t,r){this.ecModel=t,this.api=r},e.prototype.render=function(t,r,o,n){if(this.visualMapModel=t,t.get("show")===!1){this.group.removeAll();return}this.doRender(t,r,o,n)},e.prototype.renderBackground=function(t){var r=this.visualMapModel,o=se(r.get("padding")||0),n=t.getBoundingRect();t.add(new rt({z2:-1,silent:!0,shape:{x:n.x-o[3],y:n.y-o[0],width:n.width+o[3]+o[1],height:n.height+o[0]+o[2]},style:{fill:r.get("backgroundColor"),stroke:r.get("borderColor"),lineWidth:r.get("borderWidth")}}))},e.prototype.getControllerVisual=function(t,r,o){o=o||{};var n=o.forceState,a=this.visualMapModel,s={};if(r==="color"){var l=a.get("contentColor");s.color=l}function u(h){return s[h]}function p(h,d){s[h]=d}var c=a.controllerVisuals[n||a.getValueState(t)],f=mt.prepareVisualTypes(c);return S(f,function(h){var d=c[h];o.convertOpacityToAlpha&&h==="opacity"&&(h="colorAlpha",d=c.__alphaForOpacity),mt.dependsOn(h,r)&&d&&d.applyVisual(t,u,p)}),s[r]},e.prototype.positionGroup=function(t){var r=this.visualMapModel,o=this.api,n=gt(r,o).refContainer;He(t,r.getBoxLayoutParams(),n)},e.prototype.doRender=function(t,r,o,n){},e.type="visualMap",e})(X),po=im;var yc=[["left","right","width"],["top","bottom","height"]];function co(i,e,t){var r=i.option,o=r.align;if(o!=null&&o!=="auto")return o;for(var n={width:e.getWidth(),height:e.getHeight()},a=r.orient==="horizontal"?1:0,s=yc[a],l=[0,null,10],u={},p=0;p<3;p++)u[yc[1-a][p]]=l[p],u[s[p]]=p===2?t[0]:r[s[p]];var c=[["x","width",3],["y","height",0]][a],f=pt(u,n,r.padding);return s[(f.margin[c[2]]||0)+f[c[0]]+f[c[1]]*.5<n[c[1]]*.5?0:1]}function ur(i,e){return S(i||[],function(t){t.dataIndex!=null&&(t.dataIndexInside=t.dataIndex,t.dataIndex=null),t.highlightKey="visualMap"+(e?e.componentIndex:"")}),i}var $t=lt,om=S,_c=Math.min,$n=Math.max,nm=12,am=6,sm=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t._shapes={},t._dataInterval=[],t._handleEnds=[],t._hoverLinkDataIndices=[],t}return e.prototype.init=function(t,r){i.prototype.init.call(this,t,r),this._hoverLinkFromSeriesMouseOver=O(this._hoverLinkFromSeriesMouseOver,this),this._hideIndicator=O(this._hideIndicator,this)},e.prototype.doRender=function(t,r,o,n){(!n||n.type!=="selectDataRange"||n.from!==this.uid)&&this._buildView()},e.prototype._buildView=function(){this.group.removeAll();var t=this.visualMapModel,r=this.group;this._orient=t.get("orient"),this._useHandle=t.get("calculable"),this._resetInterval(),this._renderBar(r);var o=t.get("text");this._renderEndsText(r,o,0),this._renderEndsText(r,o,1),this._updateView(!0),this.renderBackground(r),this._updateView(),this._enableHoverLinkToSeries(),this._enableHoverLinkFromSeries(),this.positionGroup(r)},e.prototype._renderEndsText=function(t,r,o){if(r){var n=r[1-o];n=n!=null?n+"":"";var a=this.visualMapModel,s=a.get("textGap"),l=a.itemSize,u=this._shapes.mainGroup,p=this._applyTransform([l[0]/2,o===0?-s:l[1]+s],u),c=this._applyTransform(o===0?"bottom":"top",u),f=this._orient,h=this.visualMapModel.textStyleModel;this.group.add(new F({style:nt(h,{x:p[0],y:p[1],verticalAlign:h.get("verticalAlign")||(f==="horizontal"?"middle":c),align:h.get("align")||(f==="horizontal"?c:"center"),text:n})}))}},e.prototype._renderBar=function(t){var r=this.visualMapModel,o=this._shapes,n=r.itemSize,a=this._orient,s=this._useHandle,l=co(r,this.api,n),u=o.mainGroup=this._createBarGroup(l),p=new et;u.add(p),p.add(o.outOfRange=Sc()),p.add(o.inRange=Sc(null,s?wc(this._orient):null,O(this._dragHandle,this,"all",!1),O(this._dragHandle,this,"all",!0))),p.setClipPath(new rt({shape:{x:0,y:0,width:n[0],height:n[1],r:3}}));var c=r.textStyleModel.getTextRect("\u56FD"),f=$n(c.width,c.height);s&&(o.handleThumbs=[],o.handleLabels=[],o.handleLabelPoints=[],this._createHandle(r,u,0,n,f,a),this._createHandle(r,u,1,n,f,a)),this._createIndicator(r,u,n,f,a),t.add(u)},e.prototype._createHandle=function(t,r,o,n,a,s){var l=O(this._dragHandle,this,o,!1),u=O(this._dragHandle,this,o,!0),p=hr(t.get("handleSize"),n[0]),c=Pt(t.get("handleIcon"),-p/2,-p/2,p,p,null,!0),f=wc(this._orient);c.attr({cursor:f,draggable:!0,drift:l,ondragend:u,onmousemove:function(g){Jt(g.event)}}),c.x=n[0]/2,c.useStyle(t.getModel("handleStyle").getItemStyle()),c.setStyle({strokeNoScale:!0,strokeFirst:!0}),c.style.lineWidth*=2,c.ensureState("emphasis").style=t.getModel(["emphasis","handleStyle"]).getItemStyle(),Za(c,!0),r.add(c);var h=this.visualMapModel.textStyleModel,d=new F({cursor:f,draggable:!0,drift:l,onmousemove:function(g){Jt(g.event)},ondragend:u,style:nt(h,{x:0,y:0,text:""})});d.ensureState("blur").style={opacity:.1},d.stateTransition={duration:200},this.group.add(d);var v=[p,0],m=this._shapes;m.handleThumbs[o]=c,m.handleLabelPoints[o]=v,m.handleLabels[o]=d},e.prototype._createIndicator=function(t,r,o,n,a){var s=hr(t.get("indicatorSize"),o[0]),l=Pt(t.get("indicatorIcon"),-s/2,-s/2,s,s,null,!0);l.attr({cursor:"move",invisible:!0,silent:!0,x:o[0]/2});var u=t.getModel("indicatorStyle").getItemStyle();if(l instanceof Kr){var p=l.style;l.useStyle(N({image:p.image,x:p.x,y:p.y,width:p.width,height:p.height},u))}else l.useStyle(u);r.add(l);var c=this.visualMapModel.textStyleModel,f=new F({silent:!0,invisible:!0,style:nt(c,{x:0,y:0,text:""})});this.group.add(f);var h=[(a==="horizontal"?n/2:am)+o[0]/2,0],d=this._shapes;d.indicator=l,d.indicatorLabel=f,d.indicatorLabelPoint=h,this._firstShowIndicator=!0},e.prototype._dragHandle=function(t,r,o,n){if(this._useHandle){if(this._dragging=!r,!r){var a=this._applyTransform([o,n],this._shapes.mainGroup,!0);this._updateInterval(t,a[1]),this._hideIndicator(),this._updateView()}r===!this.visualMapModel.get("realtime")&&this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:this._dataInterval.slice()}),r?!this._hovering&&this._clearHoverLinkToSeries():bc(this.visualMapModel)&&this._doHoverLinkToSeries(this._handleEnds[t],!1)}},e.prototype._resetInterval=function(){var t=this.visualMapModel,r=this._dataInterval=t.getSelected(),o=t.getExtent(),n=[0,t.itemSize[1]];this._handleEnds=[$t(r[0],o,n,!0),$t(r[1],o,n,!0)]},e.prototype._updateInterval=function(t,r){r=r||0;var o=this.visualMapModel,n=this._handleEnds,a=[0,o.itemSize[1]];Et(r,n,a,t,0);var s=o.getExtent();this._dataInterval=[$t(n[0],a,s,!0),$t(n[1],a,s,!0)]},e.prototype._updateView=function(t){var r=this.visualMapModel,o=r.getExtent(),n=this._shapes,a=[0,r.itemSize[1]],s=t?a:this._handleEnds,l=this._createBarVisual(this._dataInterval,o,s,"inRange"),u=this._createBarVisual(o,o,a,"outOfRange");n.inRange.setStyle({fill:l.barColor}).setShape("points",l.barPoints),n.outOfRange.setStyle({fill:u.barColor}).setShape("points",u.barPoints),this._updateHandle(s,l)},e.prototype._createBarVisual=function(t,r,o,n){var a={forceState:n,convertOpacityToAlpha:!0},s=this._makeColorGradient(t,a),l=[this.getControllerVisual(t[0],"symbolSize",a),this.getControllerVisual(t[1],"symbolSize",a)],u=this._createBarPoints(o,l);return{barColor:new Xa(0,0,0,1,s),barPoints:u,handlesColor:[s[0].color,s[s.length-1].color]}},e.prototype._makeColorGradient=function(t,r){var o=100,n=[],a=(t[1]-t[0])/o;n.push({color:this.getControllerVisual(t[0],"color",r),offset:0});for(var s=1;s<o;s++){var l=t[0]+a*s;if(l>t[1])break;n.push({color:this.getControllerVisual(l,"color",r),offset:s/o})}return n.push({color:this.getControllerVisual(t[1],"color",r),offset:1}),n},e.prototype._createBarPoints=function(t,r){var o=this.visualMapModel.itemSize;return[[o[0]-r[0],t[0]],[o[0],t[0]],[o[0],t[1]],[o[0]-r[1],t[1]]]},e.prototype._createBarGroup=function(t){var r=this._orient,o=this.visualMapModel.get("inverse");return new et(r==="horizontal"&&!o?{scaleX:t==="bottom"?1:-1,rotation:Math.PI/2}:r==="horizontal"&&o?{scaleX:t==="bottom"?-1:1,rotation:-Math.PI/2}:r==="vertical"&&!o?{scaleX:t==="left"?1:-1,scaleY:-1}:{scaleX:t==="left"?1:-1})},e.prototype._updateHandle=function(t,r){if(this._useHandle){var o=this._shapes,n=this.visualMapModel,a=o.handleThumbs,s=o.handleLabels,l=n.itemSize,u=n.getExtent(),p=this._applyTransform("left",o.mainGroup);om([0,1],function(c){var f=a[c];f.setStyle("fill",r.handlesColor[c]),f.y=t[c];var h=$t(t[c],[0,l[1]],u,!0),d=this.getControllerVisual(h,"symbolSize");f.scaleX=f.scaleY=d/l[0],f.x=l[0]-d/2;var v=At(o.handleLabelPoints[c],Ve(f,this.group));if(this._orient==="horizontal"){var m=p==="left"||p==="top"?(l[0]-d)/2:(l[0]-d)/-2;v[1]+=m}s[c].setStyle({x:v[0],y:v[1],text:n.formatValueText(this._dataInterval[c]),verticalAlign:"middle",align:this._orient==="vertical"?this._applyTransform("left",o.mainGroup):"center"})},this)}},e.prototype._showIndicator=function(t,r,o,n){var a=this.visualMapModel,s=a.getExtent(),l=a.itemSize,u=[0,l[1]],p=this._shapes,c=p.indicator;if(c){c.attr("invisible",!1);var f={convertOpacityToAlpha:!0},h=this.getControllerVisual(t,"color",f),d=this.getControllerVisual(t,"symbolSize"),v=$t(t,s,u,!0),m=l[0]-d/2,g={x:c.x,y:c.y};c.y=v,c.x=m;var y=At(p.indicatorLabelPoint,Ve(c,this.group)),x=p.indicatorLabel;x.attr("invisible",!1);var _=this._applyTransform("left",p.mainGroup),b=this._orient,w=b==="horizontal";x.setStyle({text:(o||"")+a.formatValueText(r),verticalAlign:w?_:"middle",align:w?"center":_});var C={x:m,y:v,style:{fill:h}},D={style:{x:y[0],y:y[1]}};if(a.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var A={duration:100,easing:"cubicInOut",additive:!0};c.x=g.x,c.y=g.y,c.animateTo(C,A),x.animateTo(D,A)}else c.attr(C),x.attr(D);this._firstShowIndicator=!1;var z=this._shapes.handleLabels;if(z)for(var L=0;L<z.length;L++)this.api.enterBlur(z[L])}},e.prototype._enableHoverLinkToSeries=function(){var t=this;this._shapes.mainGroup.on("mousemove",function(r){if(t._hovering=!0,!t._dragging){var o=t.visualMapModel.itemSize,n=t._applyTransform([r.offsetX,r.offsetY],t._shapes.mainGroup,!0,!0);n[1]=_c($n(0,n[1]),o[1]),t._doHoverLinkToSeries(n[1],0<=n[0]&&n[0]<=o[0])}}).on("mouseout",function(){t._hovering=!1,!t._dragging&&t._clearHoverLinkToSeries()})},e.prototype._enableHoverLinkFromSeries=function(){var t=this.api.getZr();this.visualMapModel.option.hoverLink?(t.on("mouseover",this._hoverLinkFromSeriesMouseOver,this),t.on("mouseout",this._hideIndicator,this)):this._clearHoverLinkFromSeries()},e.prototype._doHoverLinkToSeries=function(t,r){var o=this.visualMapModel,n=o.itemSize;if(o.option.hoverLink){var a=[0,n[1]],s=o.getExtent();t=_c($n(a[0],t),a[1]);var l=lm(o,s,a),u=[t-l,t+l],p=$t(t,a,s,!0),c=[$t(u[0],a,s,!0),$t(u[1],a,s,!0)];u[0]<a[0]&&(c[0]=-1/0),u[1]>a[1]&&(c[1]=1/0),r&&(c[0]===-1/0?this._showIndicator(p,c[1],"< ",l):c[1]===1/0?this._showIndicator(p,c[0],"> ",l):this._showIndicator(p,p,"\u2248 ",l));var f=this._hoverLinkDataIndices,h=[];(r||bc(o))&&(h=this._hoverLinkDataIndices=o.findTargetDataIndices(c));var d=Ia(f,h);this._dispatchHighDown("downplay",ur(d[0],o)),this._dispatchHighDown("highlight",ur(d[1],o))}},e.prototype._hoverLinkFromSeriesMouseOver=function(t){var r;if(li(t.target,function(l){var u=j(l);if(u.dataIndex!=null)return r=u,!0},!0),!!r){var o=this.ecModel.getSeriesByIndex(r.seriesIndex),n=this.visualMapModel;if(n.isTargetSeries(o)){var a=o.getData(r.dataType),s=a.getStore().get(n.getDataDimensionIndex(a),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 o=0;o<r.length;o++)this.api.leaveBlur(r[o])},e.prototype._clearHoverLinkToSeries=function(){this._hideIndicator();var t=this._hoverLinkDataIndices;this._dispatchHighDown("downplay",ur(t,this.visualMapModel)),t.length=0},e.prototype._clearHoverLinkFromSeries=function(){this._hideIndicator();var t=this.api.getZr();t.off("mouseover",this._hoverLinkFromSeriesMouseOver),t.off("mouseout",this._hideIndicator)},e.prototype._applyTransform=function(t,r,o,n){var a=Ve(r,n?null:this.group);return I(t)?At(t,a,o):$r(t,a,o)},e.prototype._dispatchHighDown=function(t,r){r&&r.length&&this.api.dispatchAction({type:t,batch:r})},e.prototype.dispose=function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},e.type="visualMap.continuous",e})(po);function Sc(i,e,t,r){return new _e({shape:{points:i},draggable:!!t,cursor:e,drift:t,onmousemove:function(o){Jt(o.event)},ondragend:r})}function lm(i,e,t){var r=nm/2,o=i.get("hoverLinkDataSize");return o&&(r=$t(o,e,t,!0)/2),r}function bc(i){var e=i.get("hoverLinkOnHandle");return!!(e??i.get("realtime"))}function wc(i){return i==="vertical"?"ns-resize":"ew-resize"}var Cc=sm;var Tc={type:"selectDataRange",event:"dataRangeSelected",update:"update"},Mc=function(i,e){e.eachComponent({mainType:"visualMap",query:i},function(t){t.setSelected(i.selected)})};var Ac=[{createOnAllSeries:!0,reset:function(i,e){var t=[];return e.eachComponent("visualMap",function(r){var o=i.pipelineContext;!r.isTargetSeries(i)||o&&o.large||t.push(dp(r.stateList,r.targetVisuals,O(r.getValueState,r),r.getDataDimensionIndex(i.getData())))}),t}},{createOnAllSeries:!0,reset:function(i,e){var t=i.getData(),r=[];e.eachComponent("visualMap",function(o){if(o.isTargetSeries(i)){var n=o.getVisualMeta(O(um,null,i,o))||{stops:[],outerColors:[]},a=o.getDataDimensionIndex(t);a>=0&&(n.dimension=a,r.push(n))}}),i.getData().setVisual("visualMeta",r)}}];function um(i,e,t,r){for(var o=e.targetVisuals[r],n=mt.prepareVisualTypes(o),a={color:ue(i.getData(),"color")},s=0,l=n.length;s<l;s++){var u=n[s],p=o[u==="opacity"?"__alphaForOpacity":u];p&&p.applyVisual(t,c,f)}return a.color;function c(h){return a[h]}function f(h,d){a[h]=d}}var Dc=S;function Jn(i){var e=i&&i.visualMap;I(e)||(e=e?[e]:[]),Dc(e,function(t){if(t){pr(t,"splitList")&&!pr(t,"pieces")&&(t.pieces=t.splitList,delete t.splitList);var r=t.pieces;if(r&&I(r)&&Dc(r,function(n){ot(n)&&(pr(n,"start")&&!pr(n,"min")&&(n.min=n.start),pr(n,"end")&&!pr(n,"max")&&(n.max=n.end))}),0)var o}})}function pr(i,e){return i&&i.hasOwnProperty&&i.hasOwnProperty(e)}var Ic=!1;function Ur(i){Ic||(Ic=!0,i.registerSubTypeDefaulter("visualMap",function(e){return!e.categories&&(!(e.pieces?e.pieces.length>0:e.splitNumber>0)||e.calculable)?"continuous":"piecewise"}),i.registerAction(Tc,Mc),S(Ac,function(e){i.registerVisual(i.PRIORITY.VISUAL.COMPONENT,e)}),i.registerPreprocessor(Jn))}function Qn(i){i.registerComponentModel(gc),i.registerComponentView(Cc),Ur(i)}var pm=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t._pieceList=[],t}return e.prototype.optionUpdated=function(t,r){i.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var o=this._mode=this._determineMode();this._pieceList=[],cm[this._mode].call(this,this._pieceList),this._resetSelected(t,r);var n=this.option.categories;this.resetVisual(function(a,s){o==="categories"?(a.mappingMethod="category",a.categories=U(n)):(a.dataExtent=this.getExtent(),a.mappingMethod="piecewise",a.pieceList=R(this._pieceList,function(l){return l=U(l),s!=="inRange"&&(l.visual=null),l}))})},e.prototype.completeVisualOption=function(){var t=this.option,r={},o=mt.listVisualTypes(),n=this.isCategory();S(t.pieces,function(s){S(o,function(l){s.hasOwnProperty(l)&&(r[l]=1)})}),S(r,function(s,l){var u=!1;S(this.stateList,function(p){u=u||a(t,p,l)||a(t.target,p,l)},this),!u&&S(this.stateList,function(p){(t[p]||(t[p]={}))[l]=uo.get(l,p==="inRange"?"active":"inactive",n)})},this);function a(s,l,u){return s&&s[l]&&s[l].hasOwnProperty(u)}i.prototype.completeVisualOption.apply(this,arguments)},e.prototype._resetSelected=function(t,r){var o=this.option,n=this._pieceList,a=(r?o:t).selected||{};if(o.selected=a,S(n,function(l,u){var p=this.getSelectedMapKey(l);a.hasOwnProperty(p)||(a[p]=!0)},this),o.selectedMode==="single"){var s=!1;S(n,function(l,u){var p=this.getSelectedMapKey(l);a[p]&&(s?a[p]=!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=U(t)},e.prototype.getValueState=function(t){var r=mt.findPieceIndex(t,this._pieceList);return r!=null&&this.option.selected[this.getSelectedMapKey(this._pieceList[r])]?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var r=[],o=this._pieceList;return this.eachTargetSeries(function(n){var a=[],s=n.getData();s.each(this.getDataDimensionIndex(s),function(l,u){var p=mt.findPieceIndex(l,o);p===t&&a.push(u)},this),r.push({seriesId:n.id,dataIndex:a})},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 o=t.interval||[];r=o[0]===-1/0&&o[1]===1/0?0:(o[0]+o[1])/2}return r},e.prototype.getVisualMeta=function(t){if(this.isCategory())return;var r=[],o=["",""],n=this;function a(p,c){var f=n.getRepresentValue({interval:p});c||(c=n.getValueState(f));var h=t(f,c);p[0]===-1/0?o[0]=h:p[1]===1/0?o[1]=h:r.push({value:p[0],color:h},{value:p[1],color:h})}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 S(s,function(p){var c=p.interval;c&&(c[0]>u&&a([u,c[0]],"outOfRange"),a(c.slice()),u=c[1])},this),{stops:r,outerColors:o}},e.type="visualMap.piecewise",e.defaultOption=Ot(lr.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})(lr),cm={splitNumber:function(i){var e=this.option,t=Math.min(e.precision,20),r=this.getExtent(),o=e.splitNumber;o=Math.max(parseInt(o,10),1),e.splitNumber=o;for(var n=(r[1]-r[0])/o;+n.toFixed(t)!==n&&t<5;)t++;e.precision=t,n=+n.toFixed(t),e.minOpen&&i.push({interval:[-1/0,r[0]],close:[0,0]});for(var a=0,s=r[0];a<o;s+=n,a++){var l=a===o-1?r[1]:s+n;i.push({interval:[s,l],close:[1,1]})}e.maxOpen&&i.push({interval:[r[1],1/0],close:[0,0]}),go(i),S(i,function(u,p){u.index=p,u.text=this.formatValueText(u.interval)},this)},categories:function(i){var e=this.option;S(e.categories,function(t){i.push({text:this.formatValueText(t,!0),value:t})},this),Lc(e,i)},pieces:function(i){var e=this.option;S(e.pieces,function(t,r){ot(t)||(t={value:t});var o={text:"",index:r};if(t.label!=null&&(o.text=t.label),t.hasOwnProperty("value")){var n=o.value=t.value;o.interval=[n,n],o.close=[1,1]}else{for(var a=o.interval=[],s=o.close=[0,0],l=[1,0,1],u=[-1/0,1/0],p=[],c=0;c<2;c++){for(var f=[["gte","gt","min"],["lte","lt","max"]][c],h=0;h<3&&a[c]==null;h++)a[c]=t[f[h]],s[c]=l[h],p[c]=h===2;a[c]==null&&(a[c]=u[c])}p[0]&&a[1]===1/0&&(s[0]=0),p[1]&&a[0]===-1/0&&(s[1]=0),a[0]===a[1]&&s[0]&&s[1]&&(o.value=a[0])}o.visual=mt.retrieveVisuals(t),i.push(o)},this),Lc(e,i),go(i),S(i,function(t){var r=t.close,o=[["<","\u2264"][r[1]],[">","\u2265"][r[0]]];t.text=t.text||this.formatValueText(t.value!=null?t.value:t.interval,!1,o)},this)}};function Lc(i,e){var t=i.inverse;(i.orient==="vertical"?!t:t)&&e.reverse()}var zc=pm;var fm=(function(i){T(e,i);function e(){var t=i!==null&&i.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,o=r.get("textGap"),n=r.textStyleModel,a=this._getItemAlign(),s=r.itemSize,l=this._getViewData(),u=l.endsText,p=It(r.get("showLabel",!0),!u),c=!r.get("selectedMode");u&&this._renderEndsText(t,u[0],s,p,a),S(l.viewPieceList,function(f){var h=f.piece,d=new et;d.onclick=O(this._onItemClick,this,h),this._enableHoverLink(d,f.indexInModelPieceList);var v=r.getRepresentValue(h);if(this._createItemSymbol(d,v,[0,0,s[0],s[1]],c),p){var m=this.visualMapModel.getValueState(v),g=n.get("align")||a;d.add(new F({style:nt(n,{x:g==="right"?-o:s[0]+o,y:s[1]/2,text:h.text,verticalAlign:n.get("verticalAlign")||"middle",align:g,opacity:W(n.get("opacity"),m==="outOfRange"?.5:1)}),silent:c}))}t.add(d)},this),u&&this._renderEndsText(t,u[1],s,p,a),Bt(r.get("orient"),t,r.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},e.prototype._enableHoverLink=function(t,r){var o=this;t.on("mouseover",function(){return n("highlight")}).on("mouseout",function(){return n("downplay")});var n=function(a){var s=o.visualMapModel;s.option.hoverLink&&o.api.dispatchAction({type:a,batch:ur(s.findTargetDataIndices(r),s)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,r=t.option;if(r.orient==="vertical")return co(t,this.api,t.itemSize);var o=r.align;return(!o||o==="auto")&&(o="left"),o},e.prototype._renderEndsText=function(t,r,o,n,a){if(r){var s=new et,l=this.visualMapModel.textStyleModel;s.add(new F({style:nt(l,{x:n?a==="right"?o[0]:0:o[0]/2,y:o[1]/2,verticalAlign:"middle",align:n?a:"center",text:r})})),t.add(s)}},e.prototype._getViewData=function(){var t=this.visualMapModel,r=R(t.getPieceList(),function(s,l){return{piece:s,indexInModelPieceList:l}}),o=t.get("text"),n=t.get("orient"),a=t.get("inverse");return(n==="horizontal"?a:!a)?r.reverse():o&&(o=o.slice().reverse()),{viewPieceList:r,endsText:o}},e.prototype._createItemSymbol=function(t,r,o,n){var a=Pt(this.getControllerVisual(r,"symbol"),o[0],o[1],o[2],o[3],this.getControllerVisual(r,"color"));a.silent=n,t.add(a)},e.prototype._onItemClick=function(t){var r=this.visualMapModel,o=r.option,n=o.selectedMode;if(n){var a=U(o.selected),s=r.getSelectedMapKey(t);n==="single"||n===!0?(a[s]=!0,S(a,function(l,u){a[u]=u===s})):a[s]=!a[s],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:a})}},e.type="visualMap.piecewise",e})(po),Oc=fm;function ta(i){i.registerComponentModel(zc),i.registerComponentView(Oc),Ur(i)}function hm(i){ft(Qn),ft(ta)}var Pc=(function(){function i(e){this._thumbnailModel=e}return i.prototype.reset=function(e){this._renderVersion=e.getECUpdateCycleVersion()},i.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:ja(e.group),roamType:e.roamType,viewportRect:e.viewportRect,renderVersion:this._renderVersion}))},i.prototype.updateWindow=function(e,t){var r=t.getViewOfComponentModel(this._thumbnailModel);r&&r.updateWindow({targetTrans:e,renderVersion:this._renderVersion})},i})();var kc=(function(i){T(e,i);function e(){var t=i!==null&&i.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 Pc(this);if(this._target=null,this.ecModel.eachSeries(function(o){Po(o,null)}),this.shouldShow()){var r=this.getTarget();Po(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:M.color.border,borderWidth:2},windowStyle:{borderWidth:1,color:M.color.neutral30,borderColor:M.color.neutral40,opacity:.3},z:10},e})(Z);var Vc=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,o){if(this._api=o,this._model=t,this._coordSys||(this._coordSys=new Bs),!this._isEnabled()){this._clear();return}this._renderVersion=o.getECUpdateCycleVersion();var n=this.group;n.removeAll();var a=t.getModel("itemStyle"),s=a.getItemStyle();s.fill==null&&(s.fill=r.get("backgroundColor")||M.color.neutral00);var l=gt(t,o).refContainer,u=pt(is(t,!0),l),p=s.lineWidth||0,c=this._contentRect=Ue(u.clone(),p/2,!0,!0),f=new et;n.add(f),f.setClipPath(new rt({shape:c.plain()}));var h=this._targetGroup=new et;f.add(h);var d=u.plain();d.r=a.getShallow("borderRadius",!0),n.add(this._bgRect=new rt({style:s,shape:d,silent:!1,cursor:"grab"}));var v=t.getModel("windowStyle"),m=v.getShallow("borderRadius",!0);f.add(this._windowRect=new rt({shape:{x:0,y:0,width:0,height:0,r:m},style:v.getItemStyle(),silent:!1,cursor:"grab"})),this._dealRenderContent(),this._dealUpdateWindow(),Ec(t,this)},e.prototype.renderContent=function(t){this._bridgeRendered=t,this._isEnabled()&&(this._dealRenderContent(),this._dealUpdateWindow(),Ec(this._model,this))},e.prototype._dealRenderContent=function(){var t=this._bridgeRendered;if(!(!t||t.renderVersion!==this._renderVersion)){var r=this._targetGroup,o=this._coordSys,n=this._contentRect;if(r.removeAll(),!!t){var a=t.group,s=a.getBoundingRect();r.add(a),this._bgRect.z2=t.z2Range.min-10,Us(o,s.x,s.y,s.width,s.height);var l=pt({left:"center",top:"center",aspect:s.width/s.height},n);Ns(o,l.x,l.y,l.width,l.height),Vs(a,o,Rs),a.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=fr([],t.targetTrans),o=da([],yi(null,this._coordSys),r);this._transThisToTarget=fr([],o);var n=t.viewportRect;n?n=n.clone():n=new Ct(0,0,this._api.getWidth(),this._api.getHeight()),n.applyTransform(o);var a=this._windowRect,s=a.shape.r;a.setShape(K({r:s},n))}},e.prototype._resetRoamController=function(t){var r=this,o=this._api,n=this._roamController;if(n||(n=this._roamController=new gi(o.getZr())),!t||!this._isEnabled()){n.disable();return}n.enable(t,{api:o,zInfo:{component:this._model},triggerInfo:{roamTrigger:null,isInSelf:function(a,s,l){return r._contentRect.contain(s,l)}}}),n.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 o=Br([],[t.oldX,t.oldY],r),n=Br([],[t.oldX-t.dx,t.oldY-t.dy],r);this._api.dispatchAction(Rc(this._model.getTarget().baseMapProvider,{dx:n[0]-o[0],dy:n[1]-o[1]}))}},e.prototype._onZoom=function(t){var r=this._transThisToTarget;if(!(!this._isEnabled()||!r)){var o=Br([],[t.originX,t.originY],r);this._api.dispatchAction(Rc(this._model.getTarget().baseMapProvider,{zoom:1/t.scale,originX:o[0],originY:o[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})(X);function Rc(i,e){var t=i.mainType==="series"?i.subType+"Roam":i.mainType+"Roam",r={type:t};return r[i.mainType+"Id"]=i.id,N(r,e),r}function Ec(i,e){var t=Qr(i);ti(e.group,t.z,t.zlevel)}function dm(i){i.registerComponentModel(kc),i.registerComponentView(Vc)}var vm={label:{enabled:!0},decal:{show:!1}},Uc=Q(),Nc=Q(),Bc=Ee(mm);function mm(i,e){var t=i.getModel("aria");if(!t.get("enabled"))return;var r=Nc(i).scope||(Nc(i).scope={}),o=U(vm);tt(o.label,i.getLocaleModel().get("aria"),!1),tt(t.option,o,!1),n(),a();function n(){var p=t.getModel("decal"),c=p.get("show");if(c){var f=q();i.eachSeries(function(h){h.isColorBySeries()||(Uc(h).scope=f.get(h.type)||f.set(h.type,{}))}),i.eachSeries(function(h){if(G(h.enableAriaDecal)){h.enableAriaDecal();return}var d=h.getData();if(h.isColorBySeries()){var x=bo(h.ecModel,h.name,r,i.getSeriesCount()),_=d.getVisual("decal");d.setVisual("decal",b(_,x))}else{var v=h.getRawData(),m={},g=Uc(h).scope;d.each(function(w){var C=d.getRawIndex(w);m[C]=w});var y=v.count();v.each(function(w){var C=m[w],D=v.getName(w)||w+"",A=bo(h.ecModel,D,g,y),z=d.getItemVisual(C,"decal");d.setItemVisual(C,"decal",b(z,A))})}function b(w,C){var D=w?N(N({},C),w):C;return D.dirty=!0,D}})}}function a(){var p=e.getZr().dom;if(p){var c=i.getLocaleModel().get("aria"),f=t.getModel("label");if(f.option=K(f.option,c),!!f.get("enabled")){if(p.setAttribute("role","img"),f.get("description")){p.setAttribute("aria-label",f.get("description"));return}var h=i.getSeriesCount(),d=f.get(["data","maxCount"])||10,v=f.get(["series","maxCount"])||10,m=Math.min(h,v),g;if(!(h<1)){var y=l();if(y){var x=f.get(["general","withTitle"]);g=s(x,{title:y})}else g=f.get(["general","withoutTitle"]);var _=[],b=h>1?f.get(["series","multiple","prefix"]):f.get(["series","single","prefix"]);g+=s(b,{seriesCount:h}),i.eachSeries(function(A,z){if(z<m){var L=void 0,Y=A.get("name"),P=Y?"withName":"withoutName";L=h>1?f.get(["series","multiple",P]):f.get(["series","single",P]),L=s(L,{seriesId:A.seriesIndex,seriesName:A.get("name"),seriesType:u(A.subType)});var V=A.getData();if(V.count()>d){var $=f.get(["data","partialData"]);L+=s($,{displayCnt:d})}else L+=f.get(["data","allData"]);for(var it=f.get(["data","separator","middle"]),Wt=f.get(["data","separator","end"]),re=f.get(["data","excludeDimensionId"]),ia=[],Le=0;Le<V.count();Le++)if(Le<d){var oa=V.getName(Le),Xc=re?St(V.getValues(Le),function(zm,qc){return st(re,qc)===-1}):V.getValues(Le),Kc=f.get(["data",oa?"withName":"withoutName"]);ia.push(s(Kc,{name:oa,value:Xc.join(it)}))}L+=ia.join(it)+Wt,_.push(L)}});var w=f.getModel(["series","multiple","separator"]),C=w.get("middle"),D=w.get("end");g+=_.join(C)+D,p.setAttribute("aria-label",g)}}}}function s(p,c){if(!E(p))return p;var f=p;return S(c,function(h,d){f=f.replace(new RegExp("\\{\\s*"+d+"\\s*\\}","g"),h)}),f}function l(){var p=i.get("title");return p&&p.length&&(p=p[0]),p&&p.text}function u(p){var c=i.getLocaleModel().get(["series","typeNames"]);return c[p]||c.chart}}function ea(i){if(!(!i||!i.aria)){var e=i.aria;e.show!=null&&(e.enabled=e.show),e.label=e.label||{},S(["description","general","series","data"],function(t){e[t]!=null&&(e.label[t]=e[t])})}}function gm(i){i.registerPreprocessor(ea),i.registerVisual(i.PRIORITY.VISUAL.ARIA,Bc)}var Hc={value:"eq","<":"lt","<=":"lte",">":"gt",">=":"gte","=":"eq","!=":"ne","<>":"ne"},ym=(function(){function i(e){var t=this._condVal=E(e)?new RegExp(e):la(e)?e:null;if(t==null){var r="";ut(r)}}return i.prototype.evaluate=function(e){var t=typeof e;return E(t)?this._condVal.test(e):oe(t)?this._condVal.test(e+""):!1},i})(),xm=(function(){function i(){}return i.prototype.evaluate=function(){return this.value},i})(),_m=(function(){function i(){}return i.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(!e[t].evaluate())return!1;return!0},i})(),Sm=(function(){function i(){}return i.prototype.evaluate=function(){for(var e=this.children,t=0;t<e.length;t++)if(e[t].evaluate())return!0;return!1},i})(),bm=(function(){function i(){}return i.prototype.evaluate=function(){return!this.child.evaluate()},i})(),wm=(function(){function i(){}return i.prototype.evaluate=function(){for(var e=!!this.valueParser,t=this.getValue,r=t(this.valueGetterParam),o=e?this.valueParser(r):null,n=0;n<this.subCondList.length;n++)if(!this.subCondList[n].evaluate(e?o:r))return!1;return!0},i})();function ra(i,e){if(i===!0||i===!1){var t=new xm;return t.value=i,t}var r="";return Fc(i)||ut(r),i.and?Gc("and",i,e):i.or?Gc("or",i,e):i.not?Cm(i,e):Tm(i,e)}function Gc(i,e,t){var r=e[i],o="";I(r)||ut(o),r.length||ut(o);var n=i==="and"?new _m:new Sm;return n.children=R(r,function(a){return ra(a,t)}),n.children.length||ut(o),n}function Cm(i,e){var t=i.not,r="";Fc(t)||ut(r);var o=new bm;return o.child=ra(t,e),o.child||ut(r),o}function Tm(i,e){for(var t="",r=e.prepareGetValue(i),o=[],n=Nr(i),a=i.parser,s=a?ni(a):null,l=0;l<n.length;l++){var u=n[l];if(!(u==="parser"||e.valueGetterAttrMap.get(u))){var p=Xt(Hc,u)?Hc[u]:u,c=i[u],f=s?s(c):c,h=ls(p,f)||p==="reg"&&new ym(f);h||ut(t),o.push(h)}}o.length||ut(t);var d=new wm;return d.valueGetterParam=r,d.valueParser=s,d.getValue=e.getValue,d.subCondList=o,d}function Fc(i){return ot(i)&&!aa(i)}var Mm=(function(){function i(e,t){this._cond=ra(e,t)}return i.prototype.evaluate=function(){return this._cond.evaluate()},i})();function Zc(i,e){return new Mm(i,e)}var Wc={type:"echarts:filter",transform:function(i){for(var e=i.upstream,t,r=Zc(i.config,{valueGetterAttrMap:q({dimension:!0}),prepareGetValue:function(s){var l="",u=s.dimension;Xt(s,"dimension")||ut(l);var p=e.getDimensionInfo(u);return p||ut(l),{dimIdx:p.index}},getValue:function(s){return e.retrieveValueFromItem(t,s.dimIdx)}}),o=[],n=0,a=e.count();n<a;n++)t=e.getRawDataItem(n),r.evaluate()&&o.push(t);return{data:o}}};var Yc={type:"echarts:sort",transform:function(i){var e=i.upstream,t=i.config,r="",o=Gr(t);o.length||ut(r);var n=[];S(o,function(p){var c=p.dimension,f=p.order,h=p.parser,d=p.incomparable;if(c==null&&ut(r),f!=="asc"&&f!=="desc"&&ut(r),d&&d!=="min"&&d!=="max"){var v="";ut(v)}if(f!=="asc"&&f!=="desc"){var m="";ut(m)}var g=e.getDimensionInfo(c);g||ut(r);var y=h?ni(h):null;h&&!y&&ut(r),n.push({dimIdx:g.index,parser:y,comparator:new ss(f,d)})});var a=e.sourceFormat;a!==Va&&a!==Ua&&ut(r);for(var s=[],l=0,u=e.count();l<u;l++)s.push(e.getRawDataItem(l));return s.sort(function(p,c){for(var f=0;f<n.length;f++){var h=n[f],d=e.retrieveValueFromItem(p,h.dimIdx),v=e.retrieveValueFromItem(c,h.dimIdx);h.parser&&(d=h.parser(d),v=h.parser(v));var m=h.comparator.evaluate(d,v);if(m!==0)return m}return 0}),{data:s}}};function Am(i){i.registerTransform(Wc),i.registerTransform(Yc)}var Dm=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type="dataset",t}return e.prototype.init=function(t,r,o){i.prototype.init.call(this,t,r,o),this._sourceManager=new us(this),Co(this)},e.prototype.mergeOption=function(t,r){i.prototype.mergeOption.call(this,t,r),Co(this)},e.prototype.optionUpdated=function(){this._sourceManager.dirty()},e.prototype.getSourceManager=function(){return this._sourceManager},e.type="dataset",e.defaultOption={seriesLayoutBy:Na},e})(Z);var Im=(function(i){T(e,i);function e(){var t=i!==null&&i.apply(this,arguments)||this;return t.type="dataset",t}return e.type="dataset",e})(X);function Lm(i){i.registerComponentModel(Dm),i.registerComponentView(Im)}export{gm as AriaComponent,ee as AxisPointerComponent,Wd as BrushComponent,ah as CalendarComponent,Kv as DataZoomComponent,Xn as DataZoomInsideComponent,qn as DataZoomSliderComponent,Lm as DatasetComponent,$c as GeoComponent,Oh as GraphicComponent,xf as GridComponent,Oo as GridSimpleComponent,zv as LegendComponent,Rr as LegendPlainComponent,Fn as LegendScrollComponent,bv as MarkAreaComponent,mv as MarkLineComponent,pv as MarkPointComponent,Th as MatrixComponent,Jc as ParallelComponent,Zf as PolarComponent,jc as RadarComponent,rh as SingleAxisComponent,dm as ThumbnailComponent,rv as TimelineComponent,Kd as TitleComponent,gd as ToolboxComponent,kd as TooltipComponent,Am as TransformComponent,hm as VisualMapComponent,Qn as VisualMapContinuousComponent,ta as VisualMapPiecewiseComponent};