You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
6 lines
177 KiB
6 lines
177 KiB
import{ak as tt,w as _,al as ho,W as U,a2 as L,N as Yt,am as Et,E as gr,an as W,ao as ra,G as Pt,O as Y,ap as aa,aq as kt,a1 as z,ar as st,as as Be,at as Ne,au as Mr,av as Nt,aw as Pr,J as G,ax as ki,ay as Lt,az as vo,aA as E,aB as Gi,aC as fo,aD as ae,aE as ie,ah as ct,aF as Z,k as mt,aG as It,aH as Zt,aI as Fe,aJ as K,aK as po,aL as Ft,aM as yt,aN as Lr,aO as Q,aP as at,aQ as lt,p as V,aR as yr,aS as go,aT as zi,u as Rt,aU as yo,aV as ia,aW as na,aX as Le,a6 as mo,l as X,R as et,aY as I,aZ as Vi,a_ as dt,a$ as Bi,b0 as xo,b1 as Ni,b2 as Fi,b3 as So,b4 as mr,b5 as Oe,b6 as _o,b7 as ne,b8 as fe,b9 as oa,B as rt,ba as bo,bb as Oi,bc as oe,bd as Wi,be as Yi,_ as B,bf as xr,r as Gt,m as xt,bg as wo,$ as Ie,bh as Zi,bi as Ao,bj as To,o as ht,bk as $i,bl as Co,bm as Ir,bn as Do,bo as Mo,bp as Ot,bq as Po,T as _e,br as Lo,bs as Io,D as gt,bt as We,bu as Ro,bv as Hi,bw as $t,bx as Eo,by as Rr,bz as ko,bA as Go,X as se,a3 as Ht,bB as Er,bC as Xi,bD as kr,bE as Re,bF as le,bG as Ye,bH as Ui,bI as zo,bJ as Dt,bK as Vo,bL as ji,bM as Bo,bN as No,bO as Fo,bP as Sr,bQ as Ji,bR as qi,bS as Oo,bT as Wo,bU as Ze,bV as sa,bW as Yo,bX as Zo,bY as ue,U as Ki,F as Xt,bZ as $o,b_ as Ho,V as Qi,b$ as Xo,c0 as tn,c1 as Uo,c2 as jo,c3 as ut,c4 as Jo,c5 as ee,c6 as qo,c7 as Ko,c8 as Qo,c9 as ts,ca as es,cb as rs,cc as it,cd as as,ce as is,cf as Gr,cg as ns,ch as os,ci as ss,cj as ls,ck as us,cl as cs,cm as hs,cn as vs,co as fs,S as zr,cp as ds,cq as ps,cr as en,cs as gs,ct as ys,cu as rn,cv as an,cw as ms,cx as xs,cy as Ss,cz as _s,cA as bs,cB as ws,cC as nn,cD as As,cE as Ts,cF as Cs,cG as Ds,cH as Ms,cI as Ps,cJ as Ls,cK as on,cL as Is,cM as Rs,cN as Es,cO as ks,cP as Gs,cQ as zs,cR as Vs,cS as Bs,ag as Ns,cT as Fs,cU as Os,cV as Ws,cW as Ys,j as Zs,ae as $s,cX as Hs,cY as Xs,cZ as Us,c_ as js,c$ as Js,d0 as qs,d1 as Ks,d2 as Qs,d3 as tl,d4 as el,d5 as rl,d6 as al,d7 as il,d8 as nl,d9 as ol,da as sl,db as ll,dc as ul,dd as cl,de as hl,df as vl,dg as fl,dh as dl,di as pl,dj as gl,dk as yl,dl as la,dm as ml,dn as ua,dp as Vr,dq as xl,dr as sn,ds as Sl,dt as ln,du as _l,dv as ca,dw as bl,dx as wl,dy as Qt,dz as Al,dA as Tl,dB as Cl,dC as Dl,dD as Ml,dE as Pl,dF as Ll,dG as Ee,dH as un,dI as cn,dJ as hn,dK as Il,dL as Rl,dM as El,L as kl,dN as ha,dO as pt,dP as ce,dQ as Gl,dR as va,dS as zl,dT as Vl,dU as vn,P as Bl,dV as fn,dW as Nl,dX as Fl,dY as Ol,dZ as $e,d_ as Wl,d$ as Yl,e0 as Zl,e1 as $l,e2 as Hl,e3 as Xl,e4 as Ul,e5 as jl,e6 as Jl,e7 as dn,e8 as Br,e9 as ql,ea as Kl,eb as Ql,aj as fa,ec as tu,ed as eu,g as ru,d as au,e as iu,i as nu,c as ou,a as su,b as lu,h as uu,f as cu}from"./install-2bcffee5.js";function hu(a,e,t,r,i,n,o,s){var l=new tt({style:{text:a,font:e,align:t,verticalAlign:r,padding:i,rich:n,overflow:o?"truncate":null,lineHeight:s}});return l.getBoundingRect()}function vu(a){a.eachSeriesByType("radar",function(e){var t=e.getData(),r=[],i=e.coordinateSystem;if(i){var n=i.getIndicatorAxes();_(n,function(o,s){t.each(t.mapDimension(n[s].dim),function(l,u){r[u]=r[u]||[];var c=i.dataToPoint(l,s);r[u][s]=da(c)?c:pa(i)})}),t.each(function(o){var s=ho(r[o],function(l){return da(l)})||pa(i);r[o].push(s.slice()),t.setItemLayout(o,r[o])})}})}function da(a){return!isNaN(a[0])&&!isNaN(a[1])}function pa(a){return[a.cx,a.cy]}function fu(a){var e=a.polar;if(e){U(e)||(e=[e]);var t=[];_(e,function(r,i){r.indicator?(r.type&&!r.shape&&(r.shape=r.type),a.radar=a.radar||[],U(a.radar)||(a.radar=[a.radar]),a.radar.push(r)):t.push(r)}),a.polar=t}_(a.series,function(r){r&&r.type==="radar"&&r.polarIndex&&(r.radarIndex=r.polarIndex)})}var du=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,i){var n=t.coordinateSystem,o=this.group,s=t.getData(),l=this._data;function u(v,f){var d=v.getItemVisual(f,"symbol")||"circle";if(d!=="none"){var p=ki(v.getItemVisual(f,"symbolSize")),g=Lt(d,-1,-1,2,2),y=v.getItemVisual(f,"symbolRotate")||0;return g.attr({style:{strokeNoScale:!0},z2:100,scaleX:p[0]/2,scaleY:p[1]/2,rotation:y*Math.PI/180||0}),g}}function c(v,f,d,p,g,y){d.removeAll();for(var m=0;m<f.length-1;m++){var S=u(p,g);S&&(S.__dimIdx=m,v[m]?(S.setPosition(v[m]),Pr[y?"initProps":"updateProps"](S,{x:f[m][0],y:f[m][1]},t,g)):S.setPosition(f[m]),d.add(S))}}function h(v){return G(v,function(f){return[n.cx,n.cy]})}s.diff(l).add(function(v){var f=s.getItemLayout(v);if(f){var d=new Yt,p=new Et,g={shape:{points:f}};d.shape.points=h(f),p.shape.points=h(f),gr(d,g,t,v),gr(p,g,t,v);var y=new W,m=new W;y.add(p),y.add(d),y.add(m),c(p.shape.points,f,m,s,v,!0),s.setItemGraphicEl(v,y)}}).update(function(v,f){var d=l.getItemGraphicEl(f),p=d.childAt(0),g=d.childAt(1),y=d.childAt(2),m={shape:{points:s.getItemLayout(v)}};m.shape.points&&(c(p.shape.points,m.shape.points,y,s,v,!1),ra(g),ra(p),Pt(p,m,t),Pt(g,m,t),s.setItemGraphicEl(v,d))}).remove(function(v){o.remove(l.getItemGraphicEl(v))}).execute(),s.eachItemGraphicEl(function(v,f){var d=s.getItemModel(f),p=v.childAt(0),g=v.childAt(1),y=v.childAt(2),m=s.getItemVisual(f,"style"),S=m.fill;o.add(v),p.useStyle(Y(d.getModel("lineStyle").getLineStyle(),{fill:"none",stroke:S})),aa(p,d,"lineStyle"),aa(g,d,"areaStyle");var x=d.getModel("areaStyle"),C=x.isEmpty()&&x.parentModel.isEmpty();g.ignore=C,_(["emphasis","select","blur"],function(A){var T=d.getModel([A,"areaStyle"]),D=T.isEmpty()&&T.parentModel.isEmpty();g.ensureState(A).ignore=D&&C}),g.useStyle(Y(x.getAreaStyle(),{fill:S,opacity:.7,decal:m.decal}));var w=d.getModel("emphasis"),b=w.getModel("itemStyle").getItemStyle();y.eachChild(function(A){if(A instanceof kt){var T=A.style;A.useStyle(z({image:T.image,x:T.x,y:T.y,width:T.width,height:T.height},m))}else A.useStyle(m),A.setColor(S),A.style.strokeNoScale=!0;var D=A.ensureState("emphasis");D.style=st(b);var M=s.getStore().get(s.getDimensionIndex(A.__dimIdx),f);(M==null||isNaN(M))&&(M=""),Be(A,Ne(d),{labelFetcher:s.hostModel,labelDataIndex:f,labelDimIndex:A.__dimIdx,defaultText:M,inheritColor:S,defaultOpacity:m.opacity})}),Mr(v,w.get("focus"),w.get("blurScope"),w.get("disabled"))}),this._data=s},e.prototype.remove=function(){this.group.removeAll(),this._data=null},e.type="radar",e}(Nt);const pu=du;var gu=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return e.prototype.init=function(t){a.prototype.init.apply(this,arguments),this.legendVisualProvider=new vo(E(this.getData,this),E(this.getRawData,this))},e.prototype.getInitialData=function(t,r){return Gi(this,{generateCoord:"indicator_",generateCoordCount:1/0})},e.prototype.formatTooltip=function(t,r,i){var n=this.getData(),o=this.coordinateSystem,s=o.getIndicatorAxes(),l=this.getData().getName(t),u=l===""?this.name:l,c=fo(this,t);return ae("section",{header:u,sortBlocks:!0,blocks:G(s,function(h){var v=n.get(n.mapDimension(h.dim),t);return ae("nameValue",{markerType:"subItem",markerColor:c,name:h.name,value:v,sortParam:v})})})},e.prototype.getTooltipPosition=function(t){if(t!=null){for(var r=this.getData(),i=this.coordinateSystem,n=r.getValues(G(i.dimensions,function(u){return r.mapDimension(u)}),t),o=0,s=n.length;o<s;o++)if(!isNaN(n[o])){var l=i.getIndicatorAxes();return i.coordToPoint(l[o].dataToCoord(n[o]),o)}}},e.type="series.radar",e.dependencies=["radar"],e.defaultOption={z:2,colorBy:"data",coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid",join:"round"},label:{position:"top"},symbolSize:8},e}(ie);const yu=gu;var jt=po.value;function be(a,e){return Y({show:e},a)}var mu=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.optionUpdated=function(){var t=this.get("boundaryGap"),r=this.get("splitNumber"),i=this.get("scale"),n=this.get("axisLine"),o=this.get("axisTick"),s=this.get("axisLabel"),l=this.get("axisName"),u=this.get(["axisName","show"]),c=this.get(["axisName","formatter"]),h=this.get("axisNameGap"),v=this.get("triggerEvent"),f=G(this.get("indicator")||[],function(d){d.max!=null&&d.max>0&&!d.min?d.min=0:d.min!=null&&d.min<0&&!d.max&&(d.max=0);var p=l;d.color!=null&&(p=Y({color:d.color},l));var g=ct(st(d),{boundaryGap:t,splitNumber:r,scale:i,axisLine:n,axisTick:o,axisLabel:s,name:d.text,showName:u,nameLocation:"end",nameGap:h,nameTextStyle:p,triggerEvent:v},!1);if(Z(c)){var y=g.name;g.name=c.replace("{value}",y!=null?y:"")}else mt(c)&&(g.name=c(g.name,g));var m=new It(g,null,this.ecModel);return Zt(m,Fe.prototype),m.mainType="radar",m.componentIndex=this.componentIndex,m},this);this._indicatorModels=f},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type="radar",e.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:ct({lineStyle:{color:"#bbb"}},jt.axisLine),axisLabel:be(jt.axisLabel,!1),axisTick:be(jt.axisTick,!1),splitLine:be(jt.splitLine,!0),splitArea:be(jt.splitArea,!0),indicator:[]},e}(K);const xu=mu;var Su=["axisLine","axisTickLabel","axisName"],_u=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,i){var n=this.group;n.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t){var r=t.coordinateSystem,i=r.getIndicatorAxes(),n=G(i,function(o){var s=o.model.get("showName")?o.name:"",l=new Ft(o.model,{axisName:s,position:[r.cx,r.cy],rotation:o.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return l});_(n,function(o){_(Su,o.add,o),this.group.add(o.getGroup())},this)},e.prototype._buildSplitLineAndArea=function(t){var r=t.coordinateSystem,i=r.getIndicatorAxes();if(!i.length)return;var n=t.get("shape"),o=t.getModel("splitLine"),s=t.getModel("splitArea"),l=o.getModel("lineStyle"),u=s.getModel("areaStyle"),c=o.get("show"),h=s.get("show"),v=l.get("color"),f=u.get("color"),d=U(v)?v:[v],p=U(f)?f:[f],g=[],y=[];function m(N,F,O){var $=O%F.length;return N[$]=N[$]||[],$}if(n==="circle")for(var S=i[0].getTicksCoords(),x=r.cx,C=r.cy,w=0;w<S.length;w++){if(c){var b=m(g,d,w);g[b].push(new yt({shape:{cx:x,cy:C,r:S[w].coord}}))}if(h&&w<S.length-1){var b=m(y,p,w);y[b].push(new Lr({shape:{cx:x,cy:C,r0:S[w].coord,r:S[w+1].coord}}))}}else for(var A,T=G(i,function(N,F){var O=N.getTicksCoords();return A=A==null?O.length-1:Math.min(O.length-1,A),G(O,function($){return r.coordToPoint($.coord,F)})}),D=[],w=0;w<=A;w++){for(var M=[],R=0;R<i.length;R++)M.push(T[R][w]);if(M[0]&&M.push(M[0].slice()),c){var b=m(g,d,w);g[b].push(new Et({shape:{points:M}}))}if(h&&D){var b=m(y,p,w-1);y[b].push(new Yt({shape:{points:M.concat(D)}}))}D=M.slice().reverse()}var P=l.getLineStyle(),k=u.getAreaStyle();_(y,function(N,F){this.group.add(Q(N,{style:Y({stroke:"none",fill:p[F%p.length]},k),silent:!0}))},this),_(g,function(N,F){this.group.add(Q(N,{style:Y({fill:"none",stroke:d[F%d.length]},P),silent:!0}))},this)},e.type="radar",e}(at);const bu=_u;var wu=function(a){L(e,a);function e(t,r,i){var n=a.call(this,t,r,i)||this;return n.type="value",n.angle=0,n.name="",n}return e}(lt);const Au=wu;var Tu=function(){function a(e,t,r){this.dimensions=[],this._model=e,this._indicatorAxes=G(e.getIndicatorModels(),function(i,n){var o="indicator_"+n,s=new Au(o,new yr);return s.name=i.get("name"),s.model=i,i.axis=s,this.dimensions.push(o),s},this),this.resize(e,r)}return a.prototype.getIndicatorAxes=function(){return this._indicatorAxes},a.prototype.dataToPoint=function(e,t){var r=this._indicatorAxes[t];return this.coordToPoint(r.dataToCoord(e),t)},a.prototype.coordToPoint=function(e,t){var r=this._indicatorAxes[t],i=r.angle,n=this.cx+e*Math.cos(i),o=this.cy-e*Math.sin(i);return[n,o]},a.prototype.pointToData=function(e){var t=e[0]-this.cx,r=e[1]-this.cy,i=Math.sqrt(t*t+r*r);t/=i,r/=i;for(var n=Math.atan2(-r,t),o=1/0,s,l=-1,u=0;u<this._indicatorAxes.length;u++){var c=this._indicatorAxes[u],h=Math.abs(n-c.angle);h<o&&(s=c,l=u,o=h)}return[l,+(s&&s.coordToData(i))]},a.prototype.resize=function(e,t){var r=e.get("center"),i=t.getWidth(),n=t.getHeight(),o=Math.min(i,n)/2;this.cx=V(r[0],i),this.cy=V(r[1],n),this.startAngle=e.get("startAngle")*Math.PI/180;var s=e.get("radius");(Z(s)||zi(s))&&(s=[0,s]),this.r0=V(s[0],o),this.r=V(s[1],o),_(this._indicatorAxes,function(l,u){l.setExtent(this.r0,this.r);var c=this.startAngle+u*Math.PI*2/this._indicatorAxes.length;c=Math.atan2(Math.sin(c),Math.cos(c)),l.angle=c},this)},a.prototype.update=function(e,t){var r=this._indicatorAxes,i=this._model;_(r,function(s){s.scale.setExtent(1/0,-1/0)}),e.eachSeriesByType("radar",function(s,l){if(!(s.get("coordinateSystem")!=="radar"||e.getComponent("radar",s.get("radarIndex"))!==i)){var u=s.getData();_(r,function(c){c.scale.unionExtentFromData(u,u.mapDimension(c.dim))})}},this);var n=i.get("splitNumber"),o=new yr;o.setExtent(0,n),o.setInterval(1),_(r,function(s,l){go(s.scale,s.model,o)})},a.prototype.convertToPixel=function(e,t,r){return null},a.prototype.convertFromPixel=function(e,t,r){return null},a.prototype.containPoint=function(e){return!1},a.create=function(e,t){var r=[];return e.eachComponent("radar",function(i){var n=new a(i,e,t);r.push(n),i.coordinateSystem=n}),e.eachSeriesByType("radar",function(i){i.get("coordinateSystem")==="radar"&&(i.coordinateSystem=r[i.get("radarIndex")||0])}),r},a.dimensions=[],a}();const Cu=Tu;function pn(a){a.registerCoordinateSystem("radar",Cu),a.registerComponentModel(xu),a.registerComponentView(bu),a.registerVisual({seriesType:"radar",reset:function(e){var t=e.getData();t.each(function(r){t.setItemVisual(r,"legendIcon","roundRect")}),t.setVisual("legendIcon","roundRect")}})}function Du(a){Rt(pn),a.registerChartView(pu),a.registerSeriesModel(yu),a.registerLayout(vu),a.registerProcessor(yo("radar")),a.registerPreprocessor(fu)}var Mu=function(a){L(e,a);function e(t){var r=a.call(this)||this;r._zr=t;var i=E(r._mousedownHandler,r),n=E(r._mousemoveHandler,r),o=E(r._mouseupHandler,r),s=E(r._mousewheelHandler,r),l=E(r._pinchHandler,r);return r.enable=function(u,c){this.disable(),this._opt=Y(st(c)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),u==null&&(u=!0),(u===!0||u==="move"||u==="pan")&&(t.on("mousedown",i),t.on("mousemove",n),t.on("mouseup",o)),(u===!0||u==="scale"||u==="zoom")&&(t.on("mousewheel",s),t.on("pinch",l))},r.disable=function(){t.off("mousedown",i),t.off("mousemove",n),t.off("mouseup",o),t.off("mousewheel",s),t.off("pinch",l)},r}return e.prototype.isDragging=function(){return this._dragging},e.prototype.isPinching=function(){return this._pinching},e.prototype.setPointerChecker=function(t){this.pointerChecker=t},e.prototype.dispose=function(){this.disable()},e.prototype._mousedownHandler=function(t){if(!ia(t)){for(var r=t.target;r;){if(r.draggable)return;r=r.__hostTarget||r.parent}var i=t.offsetX,n=t.offsetY;this.pointerChecker&&this.pointerChecker(t,i,n)&&(this._x=i,this._y=n,this._dragging=!0)}},e.prototype._mousemoveHandler=function(t){if(!(!this._dragging||!Me("moveOnMouseMove",t,this._opt)||t.gestureEvent==="pinch"||na(this._zr,"globalPan"))){var r=t.offsetX,i=t.offsetY,n=this._x,o=this._y,s=r-n,l=i-o;this._x=r,this._y=i,this._opt.preventDefaultMouseMove&&Le(t.event),gn(this,"pan","moveOnMouseMove",t,{dx:s,dy:l,oldX:n,oldY:o,newX:r,newY:i,isAvailableBehavior:null})}},e.prototype._mouseupHandler=function(t){ia(t)||(this._dragging=!1)},e.prototype._mousewheelHandler=function(t){var r=Me("zoomOnMouseWheel",t,this._opt),i=Me("moveOnMouseWheel",t,this._opt),n=t.wheelDelta,o=Math.abs(n),s=t.offsetX,l=t.offsetY;if(!(n===0||!r&&!i)){if(r){var u=o>3?1.4:o>1?1.2:1.1,c=n>0?u:1/u;Ke(this,"zoom","zoomOnMouseWheel",t,{scale:c,originX:s,originY:l,isAvailableBehavior:null})}if(i){var h=Math.abs(n),v=(n>0?1:-1)*(h>3?.4:h>1?.15:.05);Ke(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:v,originX:s,originY:l,isAvailableBehavior:null})}}},e.prototype._pinchHandler=function(t){if(!na(this._zr,"globalPan")){var r=t.pinchScale>1?1.1:1/1.1;Ke(this,"zoom",null,t,{scale:r,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})}},e}(mo);function Ke(a,e,t,r,i){a.pointerChecker&&a.pointerChecker(r,i.originX,i.originY)&&(Le(r.event),gn(a,e,t,r,i))}function gn(a,e,t,r,i){i.isAvailableBehavior=E(Me,null,t,r),a.trigger(e,i)}function Me(a,e,t){var r=t[a];return!a||r&&(!Z(r)||e.event[r+"Key"])}const yn=Mu;function Pu(a,e,t){var r=a.target;r.x+=e,r.y+=t,r.dirty()}function Lu(a,e,t,r){var i=a.target,n=a.zoomLimit,o=a.zoom=a.zoom||1;if(o*=e,n){var s=n.min||0,l=n.max||1/0;o=Math.max(Math.min(l,o),s)}var u=o/a.zoom;a.zoom=o,i.x-=(t-i.x)*(u-1),i.y-=(r-i.y)*(u-1),i.scaleX*=u,i.scaleY*=u,i.dirty()}function mn(a){if(Z(a)){var e=new DOMParser;a=e.parseFromString(a,"text/xml")}var t=a;for(t.nodeType===9&&(t=t.firstChild);t.nodeName.toLowerCase()!=="svg"||t.nodeType!==1;)t=t.nextSibling;return t}var Qe,ke={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-anchor":"textAlign",visibility:"visibility",display:"display"},ga=X(ke),Ge={"alignment-baseline":"textBaseline","stop-color":"stopColor"},ya=X(Ge),Iu=function(){function a(){this._defs={},this._root=null}return a.prototype.parse=function(e,t){t=t||{};var r=mn(e);this._defsUsePending=[];var i=new W;this._root=i;var n=[],o=r.getAttribute("viewBox")||"",s=parseFloat(r.getAttribute("width")||t.width),l=parseFloat(r.getAttribute("height")||t.height);isNaN(s)&&(s=null),isNaN(l)&&(l=null),j(r,i,null,!0,!1);for(var u=r.firstChild;u;)this._parseNode(u,i,n,null,!1,!1),u=u.nextSibling;ku(this._defs,this._defsUsePending),this._defsUsePending=[];var c,h;if(o){var v=He(o);v.length>=4&&(c={x:parseFloat(v[0]||0),y:parseFloat(v[1]||0),width:parseFloat(v[2]),height:parseFloat(v[3])})}if(c&&s!=null&&l!=null&&(h=Sn(c,{x:0,y:0,width:s,height:l}),!t.ignoreViewBox)){var f=i;i=new W,i.add(f),f.scaleX=f.scaleY=h.scale,f.x=h.x,f.y=h.y}return!t.ignoreRootClip&&s!=null&&l!=null&&i.setClipPath(new et({shape:{x:0,y:0,width:s,height:l}})),{root:i,width:s,height:l,viewBoxRect:c,viewBoxTransform:h,named:n}},a.prototype._parseNode=function(e,t,r,i,n,o){var s=e.nodeName.toLowerCase(),l,u=i;if(s==="defs"&&(n=!0),s==="text"&&(o=!0),s==="defs"||s==="switch")l=t;else{if(!n){var c=Qe[s];if(c&&I(Qe,s)){l=c.call(this,e,t);var h=e.getAttribute("name");if(h){var v={name:h,namedFrom:null,svgNodeTagLower:s,el:l};r.push(v),s==="g"&&(u=v)}else i&&r.push({name:i.name,namedFrom:i,svgNodeTagLower:s,el:l});t.add(l)}}var f=ma[s];if(f&&I(ma,s)){var d=f.call(this,e),p=e.getAttribute("id");p&&(this._defs[p]=d)}}if(l&&l.isGroup)for(var g=e.firstChild;g;)g.nodeType===1?this._parseNode(g,l,r,u,n,o):g.nodeType===3&&o&&this._parseText(g,l),g=g.nextSibling},a.prototype._parseText=function(e,t){var r=new Vi({style:{text:e.textContent},silent:!0,x:this._textX||0,y:this._textY||0});J(t,r),j(e,r,this._defsUsePending,!1,!1),Ru(r,t);var i=r.style,n=i.fontSize;n&&n<9&&(i.fontSize=9,r.scaleX*=n/9,r.scaleY*=n/9);var o=(i.fontSize||i.fontFamily)&&[i.fontStyle,i.fontWeight,(i.fontSize||12)+"px",i.fontFamily||"sans-serif"].join(" ");i.font=o;var s=r.getBoundingRect();return this._textX+=s.width,t.add(r),r},a.internalField=function(){Qe={g:function(e,t){var r=new W;return J(t,r),j(e,r,this._defsUsePending,!1,!1),r},rect:function(e,t){var r=new et;return J(t,r),j(e,r,this._defsUsePending,!1,!1),r.setShape({x:parseFloat(e.getAttribute("x")||"0"),y:parseFloat(e.getAttribute("y")||"0"),width:parseFloat(e.getAttribute("width")||"0"),height:parseFloat(e.getAttribute("height")||"0")}),r.silent=!0,r},circle:function(e,t){var r=new yt;return J(t,r),j(e,r,this._defsUsePending,!1,!1),r.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),r:parseFloat(e.getAttribute("r")||"0")}),r.silent=!0,r},line:function(e,t){var r=new dt;return J(t,r),j(e,r,this._defsUsePending,!1,!1),r.setShape({x1:parseFloat(e.getAttribute("x1")||"0"),y1:parseFloat(e.getAttribute("y1")||"0"),x2:parseFloat(e.getAttribute("x2")||"0"),y2:parseFloat(e.getAttribute("y2")||"0")}),r.silent=!0,r},ellipse:function(e,t){var r=new Bi;return J(t,r),j(e,r,this._defsUsePending,!1,!1),r.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),rx:parseFloat(e.getAttribute("rx")||"0"),ry:parseFloat(e.getAttribute("ry")||"0")}),r.silent=!0,r},polygon:function(e,t){var r=e.getAttribute("points"),i;r&&(i=_a(r));var n=new Yt({shape:{points:i||[]},silent:!0});return J(t,n),j(e,n,this._defsUsePending,!1,!1),n},polyline:function(e,t){var r=e.getAttribute("points"),i;r&&(i=_a(r));var n=new Et({shape:{points:i||[]},silent:!0});return J(t,n),j(e,n,this._defsUsePending,!1,!1),n},image:function(e,t){var r=new kt;return J(t,r),j(e,r,this._defsUsePending,!1,!1),r.setStyle({image:e.getAttribute("xlink:href")||e.getAttribute("href"),x:+e.getAttribute("x"),y:+e.getAttribute("y"),width:+e.getAttribute("width"),height:+e.getAttribute("height")}),r.silent=!0,r},text:function(e,t){var r=e.getAttribute("x")||"0",i=e.getAttribute("y")||"0",n=e.getAttribute("dx")||"0",o=e.getAttribute("dy")||"0";this._textX=parseFloat(r)+parseFloat(n),this._textY=parseFloat(i)+parseFloat(o);var s=new W;return J(t,s),j(e,s,this._defsUsePending,!1,!0),s},tspan:function(e,t){var r=e.getAttribute("x"),i=e.getAttribute("y");r!=null&&(this._textX=parseFloat(r)),i!=null&&(this._textY=parseFloat(i));var n=e.getAttribute("dx")||"0",o=e.getAttribute("dy")||"0",s=new W;return J(t,s),j(e,s,this._defsUsePending,!1,!0),this._textX+=parseFloat(n),this._textY+=parseFloat(o),s},path:function(e,t){var r=e.getAttribute("d")||"",i=xo(r);return J(t,i),j(e,i,this._defsUsePending,!1,!1),i.silent=!0,i}}}(),a}(),ma={lineargradient:function(a){var e=parseInt(a.getAttribute("x1")||"0",10),t=parseInt(a.getAttribute("y1")||"0",10),r=parseInt(a.getAttribute("x2")||"10",10),i=parseInt(a.getAttribute("y2")||"0",10),n=new Ni(e,t,r,i);return xa(a,n),Sa(a,n),n},radialgradient:function(a){var e=parseInt(a.getAttribute("cx")||"0",10),t=parseInt(a.getAttribute("cy")||"0",10),r=parseInt(a.getAttribute("r")||"0",10),i=new Fi(e,t,r);return xa(a,i),Sa(a,i),i}};function xa(a,e){var t=a.getAttribute("gradientUnits");t==="userSpaceOnUse"&&(e.global=!0)}function Sa(a,e){for(var t=a.firstChild;t;){if(t.nodeType===1&&t.nodeName.toLocaleLowerCase()==="stop"){var r=t.getAttribute("offset"),i=void 0;r&&r.indexOf("%")>0?i=parseInt(r,10)/100:r?i=parseFloat(r):i=0;var n={};xn(t,n,n);var o=n.stopColor||t.getAttribute("stop-color")||"#000000";e.colorStops.push({offset:i,color:o})}t=t.nextSibling}}function J(a,e){a&&a.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),Y(e.__inheritedStyle,a.__inheritedStyle))}function _a(a){for(var e=He(a),t=[],r=0;r<e.length;r+=2){var i=parseFloat(e[r]),n=parseFloat(e[r+1]);t.push([i,n])}return t}function j(a,e,t,r,i){var n=e,o=n.__inheritedStyle=n.__inheritedStyle||{},s={};a.nodeType===1&&(Vu(a,e),xn(a,o,s),r||Bu(a,o,s)),n.style=n.style||{},o.fill!=null&&(n.style.fill=ba(n,"fill",o.fill,t)),o.stroke!=null&&(n.style.stroke=ba(n,"stroke",o.stroke,t)),_(["lineWidth","opacity","fillOpacity","strokeOpacity","miterLimit","fontSize"],function(l){o[l]!=null&&(n.style[l]=parseFloat(o[l]))}),_(["lineDashOffset","lineCap","lineJoin","fontWeight","fontFamily","fontStyle","textAlign"],function(l){o[l]!=null&&(n.style[l]=o[l])}),i&&(n.__selfStyle=s),o.lineDash&&(n.style.lineDash=G(He(o.lineDash),function(l){return parseFloat(l)})),(o.visibility==="hidden"||o.visibility==="collapse")&&(n.invisible=!0),o.display==="none"&&(n.ignore=!0)}function Ru(a,e){var t=e.__selfStyle;if(t){var r=t.textBaseline,i=r;!r||r==="auto"||r==="baseline"?i="alphabetic":r==="before-edge"||r==="text-before-edge"?i="top":r==="after-edge"||r==="text-after-edge"?i="bottom":(r==="central"||r==="mathematical")&&(i="middle"),a.style.textBaseline=i}var n=e.__inheritedStyle;if(n){var o=n.textAlign,s=o;o&&(o==="middle"&&(s="center"),a.style.textAlign=s)}}var Eu=/^url\(\s*#(.*?)\)/;function ba(a,e,t,r){var i=t&&t.match(Eu);if(i){var n=So(i[1]);r.push([a,e,n]);return}return t==="none"&&(t=null),t}function ku(a,e){for(var t=0;t<e.length;t++){var r=e[t];r[0].style[r[1]]=a[r[2]]}}var Gu=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function He(a){return a.match(Gu)||[]}var zu=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.eE,]*)\)/g,tr=Math.PI/180;function Vu(a,e){var t=a.getAttribute("transform");if(t){t=t.replace(/,/g," ");var r=[],i=null;t.replace(zu,function(h,v,f){return r.push(v,f),""});for(var n=r.length-1;n>0;n-=2){var o=r[n],s=r[n-1],l=He(o);switch(i=i||fe(),s){case"translate":ne(i,i,[parseFloat(l[0]),parseFloat(l[1]||"0")]);break;case"scale":_o(i,i,[parseFloat(l[0]),parseFloat(l[1]||l[0])]);break;case"rotate":Oe(i,i,-parseFloat(l[0])*tr);break;case"skewX":var u=Math.tan(parseFloat(l[0])*tr);mr(i,[1,0,u,1,0,0],i);break;case"skewY":var c=Math.tan(parseFloat(l[0])*tr);mr(i,[1,c,0,1,0,0],i);break;case"matrix":i[0]=parseFloat(l[0]),i[1]=parseFloat(l[1]),i[2]=parseFloat(l[2]),i[3]=parseFloat(l[3]),i[4]=parseFloat(l[4]),i[5]=parseFloat(l[5]);break}}e.setLocalTransform(i)}}var wa=/([^\s:;]+)\s*:\s*([^:;]+)/g;function xn(a,e,t){var r=a.getAttribute("style");if(r){wa.lastIndex=0;for(var i;(i=wa.exec(r))!=null;){var n=i[1],o=I(ke,n)?ke[n]:null;o&&(e[o]=i[2]);var s=I(Ge,n)?Ge[n]:null;s&&(t[s]=i[2])}}}function Bu(a,e,t){for(var r=0;r<ga.length;r++){var i=ga[r],n=a.getAttribute(i);n!=null&&(e[ke[i]]=n)}for(var r=0;r<ya.length;r++){var i=ya[r],n=a.getAttribute(i);n!=null&&(t[Ge[i]]=n)}}function Sn(a,e){var t=e.width/a.width,r=e.height/a.height,i=Math.min(t,r);return{scale:i,x:-(a.x+a.width/2)*i+(e.x+e.width/2),y:-(a.y+a.height/2)*i+(e.y+e.height/2)}}function Nu(a,e){var t=new Iu;return t.parse(a,e)}var Fu=1e-8;function Aa(a,e){return Math.abs(a-e)<Fu}function Ta(a,e,t){var r=0,i=a[0];if(!i)return!1;for(var n=1;n<a.length;n++){var o=a[n];r+=oa(i[0],i[1],o[0],o[1],e,t),i=o}var s=a[0];return(!Aa(i[0],s[0])||!Aa(i[1],s[1]))&&(r+=oa(i[0],i[1],s[0],s[1],e,t)),r!==0}var Ou=[];function er(a,e){for(var t=0;t<a.length;t++)oe(a[t],a[t],e)}function Ca(a,e,t,r){for(var i=0;i<a.length;i++){var n=a[i];r&&(n=r.project(n)),n&&isFinite(n[0])&&isFinite(n[1])&&(Wi(e,e,n),Yi(t,t,n))}}function Wu(a){for(var e=0,t=0,r=0,i=a.length,n=a[i-1][0],o=a[i-1][1],s=0;s<i;s++){var l=a[s][0],u=a[s][1],c=n*u-l*o;e+=c,t+=(n+l)*c,r+=(o+u)*c,n=l,o=u}return e?[t/e/3,r/e/3,e]:[a[0][0]||0,a[0][1]||0]}var _n=function(){function a(e){this.name=e}return a.prototype.setCenter=function(e){this._center=e},a.prototype.getCenter=function(){var e=this._center;return e||(e=this._center=this.calcCenter()),e},a}(),Da=function(){function a(e,t){this.type="polygon",this.exterior=e,this.interiors=t}return a}(),Ma=function(){function a(e){this.type="linestring",this.points=e}return a}(),bn=function(a){L(e,a);function e(t,r,i){var n=a.call(this,t)||this;return n.type="geoJSON",n.geometries=r,n._center=i&&[i[0],i[1]],n}return e.prototype.calcCenter=function(){for(var t=this.geometries,r,i=0,n=0;n<t.length;n++){var o=t[n],s=o.exterior,l=s&&s.length;l>i&&(r=o,i=l)}if(r)return Wu(r.exterior);var u=this.getBoundingRect();return[u.x+u.width/2,u.y+u.height/2]},e.prototype.getBoundingRect=function(t){var r=this._rect;if(r&&!t)return r;var i=[1/0,1/0],n=[-1/0,-1/0],o=this.geometries;return _(o,function(s){s.type==="polygon"?Ca(s.exterior,i,n,t):_(s.points,function(l){Ca(l,i,n,t)})}),isFinite(i[0])&&isFinite(i[1])&&isFinite(n[0])&&isFinite(n[1])||(i[0]=i[1]=n[0]=n[1]=0),r=new rt(i[0],i[1],n[0]-i[0],n[1]-i[1]),t||(this._rect=r),r},e.prototype.contain=function(t){var r=this.getBoundingRect(),i=this.geometries;if(!r.contain(t[0],t[1]))return!1;t:for(var n=0,o=i.length;n<o;n++){var s=i[n];if(s.type==="polygon"){var l=s.exterior,u=s.interiors;if(Ta(l,t[0],t[1])){for(var c=0;c<(u?u.length:0);c++)if(Ta(u[c],t[0],t[1]))continue t;return!0}}}return!1},e.prototype.transformTo=function(t,r,i,n){var o=this.getBoundingRect(),s=o.width/o.height;i?n||(n=i/s):i=s*n;for(var l=new rt(t,r,i,n),u=o.calculateTransform(l),c=this.geometries,h=0;h<c.length;h++){var v=c[h];v.type==="polygon"?(er(v.exterior,u),_(v.interiors,function(f){er(f,u)})):_(v.points,function(f){er(f,u)})}o=this._rect,o.copy(l),this._center=[o.x+o.width/2,o.y+o.height/2]},e.prototype.cloneShallow=function(t){t==null&&(t=this.name);var r=new e(t,this.geometries,this._center);return r._rect=this._rect,r.transformTo=null,r},e}(_n),Yu=function(a){L(e,a);function e(t,r){var i=a.call(this,t)||this;return i.type="geoSVG",i._elOnlyForCalculate=r,i}return e.prototype.calcCenter=function(){for(var t=this._elOnlyForCalculate,r=t.getBoundingRect(),i=[r.x+r.width/2,r.y+r.height/2],n=bo(Ou),o=t;o&&!o.isGeoSVGGraphicRoot;)mr(n,o.getLocalTransform(),n),o=o.parent;return Oi(n,n),oe(i,i,n),i},e}(_n),Zu=B(["rect","circle","line","ellipse","polygon","polyline","path","text","tspan","g"]),$u=function(){function a(e,t){this.type="geoSVG",this._usedGraphicMap=B(),this._freedGraphics=[],this._mapName=e,this._parsedXML=mn(t)}return a.prototype.load=function(){var e=this._firstGraphic;if(!e){e=this._firstGraphic=this._buildGraphic(this._parsedXML),this._freedGraphics.push(e),this._boundingRect=this._firstGraphic.boundingRect.clone();var t=Xu(e.named),r=t.regions,i=t.regionsMap;this._regions=r,this._regionsMap=i}return{boundingRect:this._boundingRect,regions:this._regions,regionsMap:this._regionsMap}},a.prototype._buildGraphic=function(e){var t,r;try{t=e&&Nu(e,{ignoreViewBox:!0,ignoreRootClip:!0})||{},r=t.root,xr(r!=null)}catch(g){throw new Error(`Invalid svg format
|
|
`+g.message)}var i=new W;i.add(r),i.isGeoSVGGraphicRoot=!0;var n=t.width,o=t.height,s=t.viewBoxRect,l=this._boundingRect;if(!l){var u=void 0,c=void 0,h=void 0,v=void 0;if(n!=null?(u=0,h=n):s&&(u=s.x,h=s.width),o!=null?(c=0,v=o):s&&(c=s.y,v=s.height),u==null||c==null){var f=r.getBoundingRect();u==null&&(u=f.x,h=f.width),c==null&&(c=f.y,v=f.height)}l=this._boundingRect=new rt(u,c,h,v)}if(s){var d=Sn(s,l);r.scaleX=r.scaleY=d.scale,r.x=d.x,r.y=d.y}i.setClipPath(new et({shape:l.plain()}));var p=[];return _(t.named,function(g){Zu.get(g.svgNodeTagLower)!=null&&(p.push(g),Hu(g.el))}),{root:i,boundingRect:l,named:p}},a.prototype.useGraphic=function(e){var t=this._usedGraphicMap,r=t.get(e);return r||(r=this._freedGraphics.pop()||this._buildGraphic(this._parsedXML),t.set(e,r),r)},a.prototype.freeGraphic=function(e){var t=this._usedGraphicMap,r=t.get(e);r&&(t.removeKey(e),this._freedGraphics.push(r))},a}();function Hu(a){a.silent=!1,a.isGroup&&a.traverse(function(e){e.silent=!1})}function Xu(a){var e=[],t=B();return _(a,function(r){if(r.namedFrom==null){var i=new Yu(r.name,r.el);e.push(i),t.set(r.name,i)}}),{regions:e,regionsMap:t}}function Uu(a){if(!a.UTF8Encoding)return a;var e=a,t=e.UTF8Scale;t==null&&(t=1024);var r=e.features;return _(r,function(i){var n=i.geometry,o=n.encodeOffsets,s=n.coordinates;if(o)switch(n.type){case"LineString":n.coordinates=wn(s,o,t);break;case"Polygon":rr(s,o,t);break;case"MultiLineString":rr(s,o,t);break;case"MultiPolygon":_(s,function(l,u){return rr(l,o[u],t)})}}),e.UTF8Encoding=!1,e}function rr(a,e,t){for(var r=0;r<a.length;r++)a[r]=wn(a[r],e[r],t)}function wn(a,e,t){for(var r=[],i=e[0],n=e[1],o=0;o<a.length;o+=2){var s=a.charCodeAt(o)-64,l=a.charCodeAt(o+1)-64;s=s>>1^-(s&1),l=l>>1^-(l&1),s+=i,l+=n,i=s,n=l,r.push([s/t,l/t])}return r}function _r(a,e){return a=Uu(a),G(Gt(a.features,function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0}),function(t){var r=t.properties,i=t.geometry,n=[];switch(i.type){case"Polygon":var o=i.coordinates;n.push(new Da(o[0],o.slice(1)));break;case"MultiPolygon":_(i.coordinates,function(l){l[0]&&n.push(new Da(l[0],l.slice(1)))});break;case"LineString":n.push(new Ma([i.coordinates]));break;case"MultiLineString":n.push(new Ma(i.coordinates))}var s=new bn(r[e||"name"],n,r.cp);return s.properties=r,s})}var br=[126,25],Pa="\u5357\u6D77\u8BF8\u5C9B",wt=[[[0,3.5],[7,11.2],[15,11.9],[30,7],[42,.7],[52,.7],[56,7.7],[59,.7],[64,.7],[64,0],[5,0],[0,3.5]],[[13,16.1],[19,14.7],[16,21.7],[11,23.1],[13,16.1]],[[12,32.2],[14,38.5],[15,38.5],[13,32.2],[12,32.2]],[[16,47.6],[12,53.2],[13,53.2],[18,47.6],[16,47.6]],[[6,64.4],[8,70],[9,70],[8,64.4],[6,64.4]],[[23,82.6],[29,79.8],[30,79.8],[25,82.6],[23,82.6]],[[37,70.7],[43,62.3],[44,62.3],[39,70.7],[37,70.7]],[[48,51.1],[51,45.5],[53,45.5],[50,51.1],[48,51.1]],[[51,35],[51,28.7],[53,28.7],[53,35],[51,35]],[[52,22.4],[55,17.5],[56,17.5],[53,22.4],[52,22.4]],[[58,12.6],[62,7],[63,7],[60,12.6],[58,12.6]],[[0,3.5],[0,93.1],[64,93.1],[64,0],[63,0],[63,92.4],[1,92.4],[1,3.5],[0,3.5]]];for(var _t=0;_t<wt.length;_t++)for(var zt=0;zt<wt[_t].length;zt++)wt[_t][zt][0]/=10.5,wt[_t][zt][1]/=-10.5/.75,wt[_t][zt][0]+=br[0],wt[_t][zt][1]+=br[1];function ju(a,e){if(a==="china"){for(var t=0;t<e.length;t++)if(e[t].name===Pa)return;e.push(new bn(Pa,G(wt,function(r){return{type:"polygon",exterior:r}}),br))}}var Ju={\u5357\u6D77\u8BF8\u5C9B:[32,80],\u5E7F\u4E1C:[0,-10],\u9999\u6E2F:[10,5],\u6FB3\u95E8:[-10,10],\u5929\u6D25:[5,5]};function qu(a,e){if(a==="china"){var t=Ju[e.name];if(t){var r=e.getCenter();r[0]+=t[0]/10.5,r[1]+=-t[1]/(10.5/.75),e.setCenter(r)}}}var Ku=[[[123.45165252685547,25.73527164402261],[123.49731445312499,25.73527164402261],[123.49731445312499,25.750734064600884],[123.45165252685547,25.750734064600884],[123.45165252685547,25.73527164402261]]];function Qu(a,e){a==="china"&&e.name==="\u53F0\u6E7E"&&e.geometries.push({type:"polygon",exterior:Ku[0]})}var tc="name",ec=function(){function a(e,t,r){this.type="geoJSON",this._parsedMap=B(),this._mapName=e,this._specialAreas=r,this._geoJSON=ac(t)}return a.prototype.load=function(e,t){t=t||tc;var r=this._parsedMap.get(t);if(!r){var i=this._parseToRegions(t);r=this._parsedMap.set(t,{regions:i,boundingRect:rc(i)})}var n=B(),o=[];return _(r.regions,function(s){var l=s.name;e&&I(e,l)&&(s=s.cloneShallow(l=e[l])),o.push(s),n.set(l,s)}),{regions:o,boundingRect:r.boundingRect||new rt(0,0,0,0),regionsMap:n}},a.prototype._parseToRegions=function(e){var t=this._mapName,r=this._geoJSON,i;try{i=r?_r(r,e):[]}catch(n){throw new Error(`Invalid geoJson format
|
|
`+n.message)}return ju(t,i),_(i,function(n){var o=n.name;qu(t,n),Qu(t,n);var s=this._specialAreas&&this._specialAreas[o];s&&n.transformTo(s.left,s.top,s.width,s.height)},this),i},a.prototype.getMapForUser=function(){return{geoJson:this._geoJSON,geoJSON:this._geoJSON,specialAreas:this._specialAreas}},a}();function rc(a){for(var e,t=0;t<a.length;t++){var r=a[t].getBoundingRect();e=e||r.clone(),e.union(r)}return e}function ac(a){return Z(a)?typeof JSON!="undefined"&&JSON.parse?JSON.parse(a):new Function("return ("+a+");")():a}var Jt=B();const vt={registerMap:function(a,e,t){if(e.svg){var r=new $u(a,e.svg);Jt.set(a,r)}else{var i=e.geoJson||e.geoJSON;i&&!e.features?t=e.specialAreas:i=e;var r=new ec(a,i,t);Jt.set(a,r)}},getGeoResource:function(a){return Jt.get(a)},getMapForUser:function(a){var e=Jt.get(a);return e&&e.type==="geoJSON"&&e.getMapForUser()},load:function(a,e,t){var r=Jt.get(a);if(r)return r.load(e,t)}};var Nr=["rect","circle","line","ellipse","polygon","polyline","path"],ic=B(Nr),nc=B(Nr.concat(["g"])),oc=B(Nr.concat(["g"])),An=xt();function we(a){var e=a.getItemStyle(),t=a.get("areaColor");return t!=null&&(e.fill=t),e}function La(a){var e=a.style;e&&(e.stroke=e.stroke||e.fill,e.fill=null)}var sc=function(){function a(e){var t=new W;this.uid=wo("ec_map_draw"),this._controller=new yn(e.getZr()),this._controllerHost={target:t},this.group=t,t.add(this._regionsGroup=new W),t.add(this._svgGroup=new W)}return a.prototype.draw=function(e,t,r,i,n){var o=e.mainType==="geo",s=e.getData&&e.getData();o&&t.eachComponent({mainType:"series",subType:"map"},function(y){!s&&y.getHostGeoModel()===e&&(s=y.getData())});var l=e.coordinateSystem,u=this._regionsGroup,c=this.group,h=l.getTransformInfo(),v=h.raw,f=h.roam,d=!u.childAt(0)||n;d?(c.x=f.x,c.y=f.y,c.scaleX=f.scaleX,c.scaleY=f.scaleY,c.dirty()):Pt(c,f,e);var p=s&&s.getVisual("visualMeta")&&s.getVisual("visualMeta").length>0,g={api:r,geo:l,mapOrGeoModel:e,data:s,isVisualEncodedByVisualMap:p,isGeo:o,transformInfoRaw:v};l.resourceType==="geoJSON"?this._buildGeoJSON(g):l.resourceType==="geoSVG"&&this._buildSVG(g),this._updateController(e,t,r),this._updateMapSelectHandler(e,u,r,i)},a.prototype._buildGeoJSON=function(e){var t=this._regionsGroupByName=B(),r=B(),i=this._regionsGroup,n=e.transformInfoRaw,o=e.mapOrGeoModel,s=e.data,l=e.geo.projection,u=l&&l.stream;function c(f,d){return d&&(f=d(f)),f&&[f[0]*n.scaleX+n.x,f[1]*n.scaleY+n.y]}function h(f){for(var d=[],p=!u&&l&&l.project,g=0;g<f.length;++g){var y=c(f[g],p);y&&d.push(y)}return d}function v(f){return{shape:{points:h(f)}}}i.removeAll(),_(e.geo.regions,function(f){var d=f.name,p=t.get(d),g=r.get(d)||{},y=g.dataIdx,m=g.regionModel;p||(p=t.set(d,new W),i.add(p),y=s?s.indexOfName(d):null,m=e.isGeo?o.getRegionModel(d):s?s.getItemModel(y):null,r.set(d,{dataIdx:y,regionModel:m}));var S=[],x=[];_(f.geometries,function(b){if(b.type==="polygon"){var A=[b.exterior].concat(b.interiors||[]);u&&(A=za(A,u)),_(A,function(D){S.push(new Yt(v(D)))})}else{var T=b.points;u&&(T=za(T,u,!0)),_(T,function(D){x.push(new Et(v(D)))})}});var C=c(f.getCenter(),l&&l.project);function w(b,A){if(b.length){var T=new Ir({culling:!0,segmentIgnoreThreshold:1,shape:{paths:b}});p.add(T),Ia(e,T,y,m),Ra(e,T,d,m,o,y,C),A&&(La(T),_(T.states,La))}}w(S),w(x,!0)}),t.each(function(f,d){var p=r.get(d),g=p.dataIdx,y=p.regionModel;Ea(e,f,d,y,o,g),ka(e,f,d,y,o),Ga(e,f,d,y,o)},this)},a.prototype._buildSVG=function(e){var t=e.geo.map,r=e.transformInfoRaw;this._svgGroup.x=r.x,this._svgGroup.y=r.y,this._svgGroup.scaleX=r.scaleX,this._svgGroup.scaleY=r.scaleY,this._svgResourceChanged(t)&&(this._freeSVG(),this._useSVG(t));var i=this._svgDispatcherMap=B(),n=!1;_(this._svgGraphicRecord.named,function(o){var s=o.name,l=e.mapOrGeoModel,u=e.data,c=o.svgNodeTagLower,h=o.el,v=u?u.indexOfName(s):null,f=l.getRegionModel(s);if(ic.get(c)!=null&&h instanceof Ie&&Ia(e,h,v,f),h instanceof Ie&&(h.culling=!0),h.z2EmphasisLift=0,!o.namedFrom&&(oc.get(c)!=null&&Ra(e,h,s,f,l,v,null),Ea(e,h,s,f,l,v),ka(e,h,s,f,l),nc.get(c)!=null)){var d=Ga(e,h,s,f,l);d==="self"&&(n=!0);var p=i.get(s)||i.set(s,[]);p.push(h)}},this),this._enableBlurEntireSVG(n,e)},a.prototype._enableBlurEntireSVG=function(e,t){if(e&&t.isGeo){var r=t.mapOrGeoModel.getModel(["blur","itemStyle"]).getItemStyle(),i=r.opacity;this._svgGraphicRecord.root.traverse(function(n){if(!n.isGroup){Zi(n);var o=n.ensureState("blur").style||{};o.opacity==null&&i!=null&&(o.opacity=i),n.ensureState("emphasis")}})}},a.prototype.remove=function(){this._regionsGroup.removeAll(),this._regionsGroupByName=null,this._svgGroup.removeAll(),this._freeSVG(),this._controller.dispose(),this._controllerHost=null},a.prototype.findHighDownDispatchers=function(e,t){if(e==null)return[];var r=t.coordinateSystem;if(r.resourceType==="geoJSON"){var i=this._regionsGroupByName;if(i){var n=i.get(e);return n?[n]:[]}}else if(r.resourceType==="geoSVG")return this._svgDispatcherMap&&this._svgDispatcherMap.get(e)||[]},a.prototype._svgResourceChanged=function(e){return this._svgMapName!==e},a.prototype._useSVG=function(e){var t=vt.getGeoResource(e);if(t&&t.type==="geoSVG"){var r=t.useGraphic(this.uid);this._svgGroup.add(r.root),this._svgGraphicRecord=r,this._svgMapName=e}},a.prototype._freeSVG=function(){var e=this._svgMapName;if(e!=null){var t=vt.getGeoResource(e);t&&t.type==="geoSVG"&&t.freeGraphic(this.uid),this._svgGraphicRecord=null,this._svgDispatcherMap=null,this._svgGroup.removeAll(),this._svgMapName=null}},a.prototype._updateController=function(e,t,r){var i=e.coordinateSystem,n=this._controller,o=this._controllerHost;o.zoomLimit=e.get("scaleLimit"),o.zoom=i.getZoom(),n.enable(e.get("roam")||!1);var s=e.mainType;function l(){var u={type:"geoRoam",componentType:s};return u[s+"Id"]=e.id,u}n.off("pan").on("pan",function(u){this._mouseDownFlag=!1,Pu(o,u.dx,u.dy),r.dispatchAction(z(l(),{dx:u.dx,dy:u.dy,animation:{duration:0}}))},this),n.off("zoom").on("zoom",function(u){this._mouseDownFlag=!1,Lu(o,u.scale,u.originX,u.originY),r.dispatchAction(z(l(),{zoom:u.scale,originX:u.originX,originY:u.originY,animation:{duration:0}}))},this),n.setPointerChecker(function(u,c,h){return i.containPoint([c,h])&&!Ao(u,r,e)})},a.prototype.resetForLabelLayout=function(){this.group.traverse(function(e){var t=e.getTextContent();t&&(t.ignore=An(t).ignore)})},a.prototype._updateMapSelectHandler=function(e,t,r,i){var n=this;t.off("mousedown"),t.off("click"),e.get("selectedMode")&&(t.on("mousedown",function(){n._mouseDownFlag=!0}),t.on("click",function(o){n._mouseDownFlag&&(n._mouseDownFlag=!1)}))},a}();function Ia(a,e,t,r){var i=r.getModel("itemStyle"),n=r.getModel(["emphasis","itemStyle"]),o=r.getModel(["blur","itemStyle"]),s=r.getModel(["select","itemStyle"]),l=we(i),u=we(n),c=we(s),h=we(o),v=a.data;if(v){var f=v.getItemVisual(t,"style"),d=v.getItemVisual(t,"decal");a.isVisualEncodedByVisualMap&&f.fill&&(l.fill=f.fill),d&&(l.decal=To(d,a.api))}e.setStyle(l),e.style.strokeNoScale=!0,e.ensureState("emphasis").style=u,e.ensureState("select").style=c,e.ensureState("blur").style=h,Zi(e)}function Ra(a,e,t,r,i,n,o){var s=a.data,l=a.isGeo,u=s&&isNaN(s.get(s.mapDimension("value"),n)),c=s&&s.getItemLayout(n);if(l||u||c&&c.showLabel){var h=l?t:n,v=void 0;(!s||n>=0)&&(v=i);var f=o?{normal:{align:"center",verticalAlign:"middle"}}:null;Be(e,Ne(r),{labelFetcher:v,labelDataIndex:h,defaultText:t},f);var d=e.getTextContent();if(d&&(An(d).ignore=d.ignore,e.textConfig&&o)){var p=e.getBoundingRect().clone();e.textConfig.layoutRect=p,e.textConfig.position=[(o[0]-p.x)/p.width*100+"%",(o[1]-p.y)/p.height*100+"%"]}e.disableLabelAnimation=!0}else e.removeTextContent(),e.removeTextConfig(),e.disableLabelAnimation=null}function Ea(a,e,t,r,i,n){a.data?a.data.setItemGraphicEl(n,e):ht(e).eventData={componentType:"geo",componentIndex:i.componentIndex,geoIndex:i.componentIndex,name:t,region:r&&r.option||{}}}function ka(a,e,t,r,i){a.data||$i({el:e,componentModel:i,itemName:t,itemTooltipOption:r.get("tooltip")})}function Ga(a,e,t,r,i){e.highDownSilentOnTouch=!!i.get("selectedMode");var n=r.getModel("emphasis"),o=n.get("focus");return Mr(e,o,n.get("blurScope"),n.get("disabled")),a.isGeo&&Co(e,i,t),o}function za(a,e,t){var r=[],i;function n(){i=[]}function o(){i.length&&(r.push(i),i=[])}var s=e({polygonStart:n,polygonEnd:o,lineStart:n,lineEnd:o,point:function(l,u){isFinite(l)&&isFinite(u)&&i.push([l,u])},sphere:function(){}});return!t&&s.polygonStart(),_(a,function(l){s.lineStart();for(var u=0;u<l.length;u++)s.point(l[u][0],l[u][1]);s.lineEnd()}),!t&&s.polygonEnd(),r}const Tn=sc;var lc=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,i,n){if(!(n&&n.type==="mapToggleSelect"&&n.from===this.uid)){var o=this.group;if(o.removeAll(),!t.getHostGeoModel()){if(this._mapDraw&&n&&n.type==="geoRoam"&&this._mapDraw.resetForLabelLayout(),n&&n.type==="geoRoam"&&n.componentType==="series"&&n.seriesId===t.id){var s=this._mapDraw;s&&o.add(s.group)}else if(t.needsDrawMap){var s=this._mapDraw||new Tn(i);o.add(s.group),s.draw(t,r,i,this,n),this._mapDraw=s}else this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;t.get("showLegendSymbol")&&r.getComponent("legend")&&this._renderSymbols(t,r,i)}}},e.prototype.remove=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null,this.group.removeAll()},e.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},e.prototype._renderSymbols=function(t,r,i){var n=t.originalData,o=this.group;n.each(n.mapDimension("value"),function(s,l){if(!isNaN(s)){var u=n.getItemLayout(l);if(!(!u||!u.point)){var c=u.point,h=u.offset,v=new yt({style:{fill:t.getData().getVisual("style").fill},shape:{cx:c[0]+h*9,cy:c[1],r:3},silent:!0,z2:8+(h?0:Do+1)});if(!h){var f=t.mainSeries.getData(),d=n.getName(l),p=f.indexOfName(d),g=n.getItemModel(l),y=g.getModel("label"),m=f.getItemGraphicEl(p);Be(v,Ne(g),{labelFetcher:{getFormattedLabel:function(S,x){return t.getFormattedLabel(p,x)}},defaultText:d}),v.disableLabelAnimation=!0,y.get("position")||v.setTextConfig({position:"bottom"}),m.onHoverStateChange=function(S){Mo(v,S)}}o.add(v)}}})},e.type="map",e}(Nt);const uc=lc;var cc=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t.needsDrawMap=!1,t.seriesGroup=[],t.getTooltipPosition=function(r){if(r!=null){var i=this.getData().getName(r),n=this.coordinateSystem,o=n.getRegion(i);return o&&n.dataToPoint(o.getCenter())}},t}return e.prototype.getInitialData=function(t){for(var r=Gi(this,{coordDimensions:["value"],encodeDefaulter:Ot(Po,this)}),i=B(),n=[],o=0,s=r.count();o<s;o++){var l=r.getName(o);i.set(l,!0)}var u=vt.load(this.getMapType(),this.option.nameMap,this.option.nameProperty);return _(u.regions,function(c){var h=c.name;i.get(h)||n.push(h)}),r.appendValues([],n),r},e.prototype.getHostGeoModel=function(){var t=this.option.geoIndex;return t!=null?this.ecModel.getComponent("geo",t):null},e.prototype.getMapType=function(){return(this.getHostGeoModel()||this).option.map},e.prototype.getRawValue=function(t){var r=this.getData();return r.get(r.mapDimension("value"),t)},e.prototype.getRegionModel=function(t){var r=this.getData();return r.getItemModel(r.indexOfName(t))},e.prototype.formatTooltip=function(t,r,i){for(var n=this.getData(),o=this.getRawValue(t),s=n.getName(t),l=this.seriesGroup,u=[],c=0;c<l.length;c++){var h=l[c].originalData.indexOfName(s),v=n.mapDimension("value");isNaN(l[c].originalData.get(v,h))||u.push(l[c].name)}return ae("section",{header:u.join(", "),noHeader:!u.length,blocks:[ae("nameValue",{name:s,value:o})]})},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.getLegendIcon=function(t){var r=t.icon||"roundRect",i=Lt(r,0,0,t.itemWidth,t.itemHeight,t.itemStyle.fill);return i.setStyle(t.itemStyle),i.style.stroke="none",r.indexOf("empty")>-1&&(i.style.stroke=i.style.fill,i.style.fill="#fff",i.style.lineWidth=2),i},e.type="series.map",e.dependencies=["geo"],e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},nameProperty:"name"},e}(ie);const hc=cc;function vc(a,e){var t={};return _(a,function(r){r.each(r.mapDimension("value"),function(i,n){var o="ec-"+r.getName(n);t[o]=t[o]||[],isNaN(i)||t[o].push(i)})}),a[0].map(a[0].mapDimension("value"),function(r,i){for(var n="ec-"+a[0].getName(i),o=0,s=1/0,l=-1/0,u=t[n].length,c=0;c<u;c++)s=Math.min(s,t[n][c]),l=Math.max(l,t[n][c]),o+=t[n][c];var h;return e==="min"?h=s:e==="max"?h=l:e==="average"?h=o/u:h=o,u===0?NaN:h})}function fc(a){var e={};a.eachSeriesByType("map",function(t){var r=t.getHostGeoModel(),i=r?"o"+r.id:"i"+t.getMapType();(e[i]=e[i]||[]).push(t)}),_(e,function(t,r){for(var i=vc(G(t,function(o){return o.getData()}),t[0].get("mapValueCalculation")),n=0;n<t.length;n++)t[n].originalData=t[n].getData();for(var n=0;n<t.length;n++)t[n].seriesGroup=t,t[n].needsDrawMap=n===0&&!t[n].getHostGeoModel(),t[n].setData(i.cloneShallow()),t[n].mainSeries=t[0]})}function dc(a){var e={};a.eachSeriesByType("map",function(t){var r=t.getMapType();if(!(t.getHostGeoModel()||e[r])){var i={};_(t.seriesGroup,function(o){var s=o.coordinateSystem,l=o.originalData;o.get("showLegendSymbol")&&a.getComponent("legend")&&l.each(l.mapDimension("value"),function(u,c){var h=l.getName(c),v=s.getRegion(h);if(!(!v||isNaN(u))){var f=i[h]||0,d=s.dataToPoint(v.getCenter());i[h]=f+1,l.setItemLayout(c,{point:d,offset:f})}})});var n=t.getData();n.each(function(o){var s=n.getName(o),l=n.getItemLayout(o)||{};l.showLabel=!i[s],n.setItemLayout(o,l)}),e[r]=!0}})}var Va=oe,pc=function(a){L(e,a);function e(t){var r=a.call(this)||this;return r.type="view",r.dimensions=["x","y"],r._roamTransformable=new _e,r._rawTransformable=new _e,r.name=t,r}return e.prototype.setBoundingRect=function(t,r,i,n){return this._rect=new rt(t,r,i,n),this._rect},e.prototype.getBoundingRect=function(){return this._rect},e.prototype.setViewRect=function(t,r,i,n){this._transformTo(t,r,i,n),this._viewRect=new rt(t,r,i,n)},e.prototype._transformTo=function(t,r,i,n){var o=this.getBoundingRect(),s=this._rawTransformable;s.transform=o.calculateTransform(new rt(t,r,i,n));var l=s.parent;s.parent=null,s.decomposeTransform(),s.parent=l,this._updateTransform()},e.prototype.setCenter=function(t,r){t&&(this._center=[V(t[0],r.getWidth()),V(t[1],r.getHeight())],this._updateCenterAndZoom())},e.prototype.setZoom=function(t){t=t||1;var r=this.zoomLimit;r&&(r.max!=null&&(t=Math.min(r.max,t)),r.min!=null&&(t=Math.max(r.min,t))),this._zoom=t,this._updateCenterAndZoom()},e.prototype.getDefaultCenter=function(){var t=this.getBoundingRect(),r=t.x+t.width/2,i=t.y+t.height/2;return[r,i]},e.prototype.getCenter=function(){return this._center||this.getDefaultCenter()},e.prototype.getZoom=function(){return this._zoom||1},e.prototype.getRoamTransform=function(){return this._roamTransformable.getLocalTransform()},e.prototype._updateCenterAndZoom=function(){var t=this._rawTransformable.getLocalTransform(),r=this._roamTransformable,i=this.getDefaultCenter(),n=this.getCenter(),o=this.getZoom();n=oe([],n,t),i=oe([],i,t),r.originX=n[0],r.originY=n[1],r.x=i[0]-n[0],r.y=i[1]-n[1],r.scaleX=r.scaleY=o,this._updateTransform()},e.prototype._updateTransform=function(){var t=this._roamTransformable,r=this._rawTransformable;r.parent=t,t.updateTransform(),r.updateTransform(),Lo(this.transform||(this.transform=[]),r.transform||fe()),this._rawTransform=r.getLocalTransform(),this.invTransform=this.invTransform||[],Oi(this.invTransform,this.transform),this.decomposeTransform()},e.prototype.getTransformInfo=function(){var t=this._rawTransformable,r=this._roamTransformable,i=new _e;return i.transform=r.transform,i.decomposeTransform(),{roam:{x:i.x,y:i.y,scaleX:i.scaleX,scaleY:i.scaleY},raw:{x:t.x,y:t.y,scaleX:t.scaleX,scaleY:t.scaleY}}},e.prototype.getViewRect=function(){return this._viewRect},e.prototype.getViewRectAfterRoam=function(){var t=this.getBoundingRect().clone();return t.applyTransform(this.transform),t},e.prototype.dataToPoint=function(t,r,i){var n=r?this._rawTransform:this.transform;return i=i||[],n?Va(i,t,n):Io(i,t)},e.prototype.pointToData=function(t){var r=this.invTransform;return r?Va([],t,r):[t[0],t[1]]},e.prototype.convertToPixel=function(t,r,i){var n=Ba(r);return n===this?n.dataToPoint(i):null},e.prototype.convertFromPixel=function(t,r,i){var n=Ba(r);return n===this?n.pointToData(i):null},e.prototype.containPoint=function(t){return this.getViewRectAfterRoam().contain(t[0],t[1])},e.dimensions=["x","y"],e}(_e);function Ba(a){var e=a.seriesModel;return e?e.coordinateSystem:null}const Cn=pc;var gc={geoJSON:{aspectScale:.75,invertLongitute:!0},geoSVG:{aspectScale:1,invertLongitute:!1}},Dn=["lng","lat"],Mn=function(a){L(e,a);function e(t,r,i){var n=a.call(this,t)||this;n.dimensions=Dn,n.type="geo",n._nameCoordMap=B(),n.map=r;var o=i.projection,s=vt.load(r,i.nameMap,i.nameProperty),l=vt.getGeoResource(r);n.resourceType=l?l.type:null;var u=n.regions=s.regions,c=gc[l.type];n._regionsMap=s.regionsMap,n.regions=s.regions,n.projection=o;var h;if(o)for(var v=0;v<u.length;v++){var f=u[v].getBoundingRect(o);h=h||f.clone(),h.union(f)}else h=s.boundingRect;return n.setBoundingRect(h.x,h.y,h.width,h.height),n.aspectScale=o?1:gt(i.aspectScale,c.aspectScale),n._invertLongitute=o?!1:c.invertLongitute,n}return e.prototype._transformTo=function(t,r,i,n){var o=this.getBoundingRect(),s=this._invertLongitute;o=o.clone(),s&&(o.y=-o.y-o.height);var l=this._rawTransformable;l.transform=o.calculateTransform(new rt(t,r,i,n));var u=l.parent;l.parent=null,l.decomposeTransform(),l.parent=u,s&&(l.scaleY=-l.scaleY),this._updateTransform()},e.prototype.getRegion=function(t){return this._regionsMap.get(t)},e.prototype.getRegionByCoord=function(t){for(var r=this.regions,i=0;i<r.length;i++){var n=r[i];if(n.type==="geoJSON"&&n.contain(t))return r[i]}},e.prototype.addGeoCoord=function(t,r){this._nameCoordMap.set(t,r)},e.prototype.getGeoCoord=function(t){var r=this._regionsMap.get(t);return this._nameCoordMap.get(t)||r&&r.getCenter()},e.prototype.dataToPoint=function(t,r,i){if(Z(t)&&(t=this.getGeoCoord(t)),t){var n=this.projection;return n&&(t=n.project(t)),t&&this.projectedToPoint(t,r,i)}},e.prototype.pointToData=function(t){var r=this.projection;return r&&(t=r.unproject(t)),t&&this.pointToProjected(t)},e.prototype.pointToProjected=function(t){return a.prototype.pointToData.call(this,t)},e.prototype.projectedToPoint=function(t,r,i){return a.prototype.dataToPoint.call(this,t,r,i)},e.prototype.convertToPixel=function(t,r,i){var n=Na(r);return n===this?n.dataToPoint(i):null},e.prototype.convertFromPixel=function(t,r,i){var n=Na(r);return n===this?n.pointToData(i):null},e}(Cn);Zt(Mn,Cn);function Na(a){var e=a.geoModel,t=a.seriesModel;return e?e.coordinateSystem:t?t.coordinateSystem||(t.getReferringComponents("geo",We).models[0]||{}).coordinateSystem:null}const Fa=Mn;function Oa(a,e){var t=a.get("boundingCoords");if(t!=null){var r=t[0],i=t[1];if(isFinite(r[0])&&isFinite(r[1])&&isFinite(i[0])&&isFinite(i[1])){var n=this.projection;if(n){var o=r[0],s=r[1],l=i[0],u=i[1];r=[1/0,1/0],i=[-1/0,-1/0];var c=function(w,b,A,T){for(var D=A-w,M=T-b,R=0;R<=100;R++){var P=R/100,k=n.project([w+D*P,b+M*P]);Wi(r,r,k),Yi(i,i,k)}};c(o,s,l,s),c(l,s,l,u),c(l,u,o,u),c(o,u,l,s)}this.setBoundingRect(r[0],r[1],i[0]-r[0],i[1]-r[1])}}var h=this.getBoundingRect(),v=a.get("layoutCenter"),f=a.get("layoutSize"),d=e.getWidth(),p=e.getHeight(),g=h.width/h.height*this.aspectScale,y=!1,m,S;v&&f&&(m=[V(v[0],d),V(v[1],p)],S=V(f,Math.min(d,p)),!isNaN(m[0])&&!isNaN(m[1])&&!isNaN(S)&&(y=!0));var x;if(y)x={},g>1?(x.width=S,x.height=S/g):(x.height=S,x.width=S*g),x.y=m[1]-x.height/2,x.x=m[0]-x.width/2;else{var C=a.getBoxLayoutParams();C.aspect=g,x=$t(C,{width:d,height:p})}this.setViewRect(x.x,x.y,x.width,x.height),this.setCenter(a.get("center"),e),this.setZoom(a.get("zoom"))}function yc(a,e){_(e.get("geoCoord"),function(t,r){a.addGeoCoord(r,t)})}var mc=function(){function a(){this.dimensions=Dn}return a.prototype.create=function(e,t){var r=[];function i(o){return{nameProperty:o.get("nameProperty"),aspectScale:o.get("aspectScale"),projection:o.get("projection")}}e.eachComponent("geo",function(o,s){var l=o.get("map"),u=new Fa(l+s,l,z({nameMap:o.get("nameMap")},i(o)));u.zoomLimit=o.get("scaleLimit"),r.push(u),o.coordinateSystem=u,u.model=o,u.resize=Oa,u.resize(o,t)}),e.eachSeries(function(o){var s=o.get("coordinateSystem");if(s==="geo"){var l=o.get("geoIndex")||0;o.coordinateSystem=r[l]}});var n={};return e.eachSeriesByType("map",function(o){if(!o.getHostGeoModel()){var s=o.getMapType();n[s]=n[s]||[],n[s].push(o)}}),_(n,function(o,s){var l=G(o,function(c){return c.get("nameMap")}),u=new Fa(s,s,z({nameMap:Ro(l)},i(o[0])));u.zoomLimit=Hi.apply(null,G(o,function(c){return c.get("scaleLimit")})),r.push(u),u.resize=Oa,u.resize(o[0],t),_(o,function(c){c.coordinateSystem=u,yc(u,c)})}),r},a.prototype.getFilledRegions=function(e,t,r,i){for(var n=(e||[]).slice(),o=B(),s=0;s<n.length;s++)o.set(n[s].name,n[s]);var l=vt.load(t,r,i);return _(l.regions,function(u){var c=u.name;!o.get(c)&&n.push({name:c})}),n},a}(),xc=new mc;const Pn=xc;var Sc=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r,i){var n=vt.getGeoResource(t.map);if(n&&n.type==="geoJSON"){var o=t.itemStyle=t.itemStyle||{};"color"in o||(o.color="#eee")}this.mergeDefaultAndTheme(t,i),Eo(t,"label",["show"])},e.prototype.optionUpdated=function(){var t=this,r=this.option;r.regions=Pn.getFilledRegions(r.regions,r.map,r.nameMap,r.nameProperty);var i={};this._optionModelMap=Rr(r.regions||[],function(n,o){var s=o.name;return s&&(n.set(s,new It(o,t,t.ecModel)),o.selected&&(i[s]=!0)),n},B()),r.selectedMap||(r.selectedMap=i)},e.prototype.getRegionModel=function(t){return this._optionModelMap.get(t)||new It(null,this,this.ecModel)},e.prototype.getFormattedLabel=function(t,r){var i=this.getRegionModel(t),n=r==="normal"?i.get(["label","formatter"]):i.get(["emphasis","label","formatter"]),o={name:t};if(mt(n))return o.status=r,n(o);if(Z(n))return n.replace("{a}",t!=null?t:"")},e.prototype.setZoom=function(t){this.option.zoom=t},e.prototype.setCenter=function(t){this.option.center=t},e.prototype.select=function(t){var r=this.option,i=r.selectedMode;if(i){i!=="multiple"&&(r.selectedMap=null);var n=r.selectedMap||(r.selectedMap={});n[t]=!0}},e.prototype.unSelect=function(t){var r=this.option.selectedMap;r&&(r[t]=!1)},e.prototype.toggleSelected=function(t){this[this.isSelected(t)?"unSelect":"select"](t)},e.prototype.isSelected=function(t){var r=this.option.selectedMap;return!!(r&&r[t])},e.type="geo",e.layoutMode="box",e.defaultOption={z:0,show:!0,left:"center",top:"center",aspectScale:null,silent:!1,map:"",boundingCoords:null,center:null,zoom:1,scaleLimit:null,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},regions:[]},e}(K);const _c=Sc;function Wa(a,e){return a.pointToProjected?a.pointToProjected(e):a.pointToData(e)}function bc(a,e,t,r){var i=a.getZoom(),n=a.getCenter(),o=e.zoom,s=a.projectedToPoint?a.projectedToPoint(n):a.dataToPoint(n);if(e.dx!=null&&e.dy!=null&&(s[0]-=e.dx,s[1]-=e.dy,a.setCenter(Wa(a,s),r)),o!=null){if(t){var l=t.min||0,u=t.max||1/0;o=Math.max(Math.min(i*o,u),l)/i}a.scaleX*=o,a.scaleY*=o;var c=(e.originX-a.x)*(o-1),h=(e.originY-a.y)*(o-1);a.x-=c,a.y-=h,a.updateTransform(),a.setCenter(Wa(a,s),r),a.setZoom(o*i)}return{center:a.getCenter(),zoom:a.getZoom()}}var wc=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t.focusBlurEnabled=!0,t}return e.prototype.init=function(t,r){this._api=r},e.prototype.render=function(t,r,i,n){if(this._model=t,!t.get("show")){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;return}this._mapDraw||(this._mapDraw=new Tn(i));var o=this._mapDraw;o.draw(t,r,i,this,n),o.group.on("click",this._handleRegionClick,this),o.group.silent=t.get("silent"),this.group.add(o.group),this.updateSelectStatus(t,r,i)},e.prototype._handleRegionClick=function(t){var r;ko(t.target,function(i){return(r=ht(i).eventData)!=null},!0),r&&this._api.dispatchAction({type:"geoToggleSelect",geoId:this._model.id,name:r.name})},e.prototype.updateSelectStatus=function(t,r,i){var n=this;this._mapDraw.group.traverse(function(o){var s=ht(o).eventData;if(s)return n._model.isSelected(s.name)?i.enterSelect(o):i.leaveSelect(o),!0})},e.prototype.findHighDownDispatchers=function(t){return this._mapDraw&&this._mapDraw.findHighDownDispatchers(t,this._model)},e.prototype.dispose=function(){this._mapDraw&&this._mapDraw.remove()},e.type="geo",e}(at);const Ac=wc;function Tc(a,e,t){vt.registerMap(a,e,t)}function Cc(a){a.registerCoordinateSystem("geo",Pn),a.registerComponentModel(_c),a.registerComponentView(Ac),a.registerImpl("registerMap",Tc),a.registerImpl("getMap",function(t){return vt.getMapForUser(t)});function e(t,r){r.update="geo:updateSelectStatus",a.registerAction(r,function(i,n){var o={},s=[];return n.eachComponent({mainType:"geo",query:i},function(l){l[t](i.name);var u=l.coordinateSystem;_(u.regions,function(h){o[h.name]=l.isSelected(h.name)||!1});var c=[];_(o,function(h,v){o[v]&&c.push(v)}),s.push({geoIndex:l.componentIndex,name:c})}),{selected:o,allSelected:s,name:i.name}})}e("toggleSelected",{type:"geoToggleSelect",event:"geoselectchanged"}),e("select",{type:"geoSelect",event:"geoselected"}),e("unSelect",{type:"geoUnSelect",event:"geounselected"}),a.registerAction({type:"geoRoam",event:"geoRoam",update:"updateTransform"},function(t,r,i){var n=t.componentType||"series";r.eachComponent({mainType:n,query:t},function(o){var s=o.coordinateSystem;if(s.type==="geo"){var l=bc(s,t,o.get("scaleLimit"),i);o.setCenter&&o.setCenter(l.center),o.setZoom&&o.setZoom(l.zoom),n==="series"&&_(o.seriesGroup,function(u){u.setCenter(l.center),u.setZoom(l.zoom)})}})})}function Dc(a){Rt(Cc),a.registerChartView(uc),a.registerSeriesModel(hc),a.registerLayout(dc),a.registerProcessor(a.PRIORITY.PROCESSOR.STATISTIC,fc),Go("map",a.registerAction)}function Mc(a){Pc(a),Lc(a)}function Pc(a){if(!a.parallel){var e=!1;_(a.series,function(t){t&&t.type==="parallel"&&(e=!0)}),e&&(a.parallel=[{}])}}function Lc(a){var e=se(a.parallelAxis);_(e,function(t){if(Ht(t)){var r=t.parallelIndex||0,i=se(a.parallel)[r];i&&i.parallelAxisDefault&&ct(t,i.parallelAxisDefault,!1)}})}var Ic=5,Rc=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,i){this._model=t,this._api=i,this._handlers||(this._handlers={},_(Ec,function(n,o){i.getZr().on(o,this._handlers[o]=E(n,this))},this)),Er(this,"_throttledDispatchExpand",t.get("axisExpandRate"),"fixRate")},e.prototype.dispose=function(t,r){Xi(this,"_throttledDispatchExpand"),_(this._handlers,function(i,n){r.getZr().off(n,i)}),this._handlers=null},e.prototype._throttledDispatchExpand=function(t){this._dispatchExpand(t)},e.prototype._dispatchExpand=function(t){t&&this._api.dispatchAction(z({type:"parallelAxisExpand"},t))},e.type="parallel",e}(at),Ec={mousedown:function(a){ar(this,"click")&&(this._mouseDownPoint=[a.offsetX,a.offsetY])},mouseup:function(a){var e=this._mouseDownPoint;if(ar(this,"click")&&e){var t=[a.offsetX,a.offsetY],r=Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2);if(r>Ic)return;var i=this._model.coordinateSystem.getSlidedAxisExpandWindow([a.offsetX,a.offsetY]);i.behavior!=="none"&&this._dispatchExpand({axisExpandWindow:i.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(a){if(!(this._mouseDownPoint||!ar(this,"mousemove"))){var e=this._model,t=e.coordinateSystem.getSlidedAxisExpandWindow([a.offsetX,a.offsetY]),r=t.behavior;r==="jump"&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand(r==="none"?null:{axisExpandWindow:t.axisExpandWindow,animation:r==="jump"?null:{duration:0}})}}};function ar(a,e){var t=a._model;return t.get("axisExpandable")&&t.get("axisExpandTriggerOn")===e}const kc=Rc;var Gc=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){a.prototype.init.apply(this,arguments),this.mergeOption({})},e.prototype.mergeOption=function(t){var r=this.option;t&&ct(r,t,!0),this._initDimensions()},e.prototype.contains=function(t,r){var i=t.get("parallelIndex");return i!=null&&r.getComponent("parallel",i)===this},e.prototype.setAxisExpand=function(t){_(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(r){t.hasOwnProperty(r)&&(this.option[r]=t[r])},this)},e.prototype._initDimensions=function(){var t=this.dimensions=[],r=this.parallelAxisIndex=[],i=Gt(this.ecModel.queryComponents({mainType:"parallelAxis"}),function(n){return(n.get("parallelIndex")||0)===this.componentIndex},this);_(i,function(n){t.push("dim"+n.get("dim")),r.push(n.componentIndex)})},e.type="parallel",e.dependencies=["parallelAxis"],e.layoutMode="box",e.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},e}(K);const zc=Gc;var Vc=function(a){L(e,a);function e(t,r,i,n,o){var s=a.call(this,t,r,i)||this;return s.type=n||"value",s.axisIndex=o,s}return e.prototype.isHorizontal=function(){return this.coordinateSystem.getModel().get("layout")!=="horizontal"},e}(lt);const Bc=Vc;var ir=_,Ln=Math.min,In=Math.max,Ya=Math.floor,Nc=Math.ceil,Za=Ui,Fc=Math.PI,Oc=function(){function a(e,t,r){this.type="parallel",this._axesMap=B(),this._axesLayout={},this.dimensions=e.dimensions,this._model=e,this._init(e,t,r)}return a.prototype._init=function(e,t,r){var i=e.dimensions,n=e.parallelAxisIndex;ir(i,function(o,s){var l=n[s],u=t.getComponent("parallelAxis",l),c=this._axesMap.set(o,new Bc(o,kr(u),[0,0],u.get("type"),l)),h=c.type==="category";c.onBand=h&&u.get("boundaryGap"),c.inverse=u.get("inverse"),u.axis=c,c.model=u,c.coordinateSystem=u.coordinateSystem=this},this)},a.prototype.update=function(e,t){this._updateAxesFromSeries(this._model,e)},a.prototype.containPoint=function(e){var t=this._makeLayoutInfo(),r=t.axisBase,i=t.layoutBase,n=t.pixelDimIndex,o=e[1-n],s=e[n];return o>=r&&o<=r+t.axisLength&&s>=i&&s<=i+t.layoutLength},a.prototype.getModel=function(){return this._model},a.prototype._updateAxesFromSeries=function(e,t){t.eachSeries(function(r){if(e.contains(r,t)){var i=r.getData();ir(this.dimensions,function(n){var o=this._axesMap.get(n);o.scale.unionExtentFromData(i,i.mapDimension(n)),Re(o.scale,o.model)},this)}},this)},a.prototype.resize=function(e,t){this._rect=$t(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),this._layoutAxes()},a.prototype.getRect=function(){return this._rect},a.prototype._makeLayoutInfo=function(){var e=this._model,t=this._rect,r=["x","y"],i=["width","height"],n=e.get("layout"),o=n==="horizontal"?0:1,s=t[i[o]],l=[0,s],u=this.dimensions.length,c=Ae(e.get("axisExpandWidth"),l),h=Ae(e.get("axisExpandCount")||0,[0,u]),v=e.get("axisExpandable")&&u>3&&u>h&&h>1&&c>0&&s>0,f=e.get("axisExpandWindow"),d;if(f)d=Ae(f[1]-f[0],l),f[1]=f[0]+d;else{d=Ae(c*(h-1),l);var p=e.get("axisExpandCenter")||Ya(u/2);f=[c*p-d/2],f[1]=f[0]+d}var g=(s-d)/(u-h);g<3&&(g=0);var y=[Ya(Za(f[0]/c,1))+1,Nc(Za(f[1]/c,1))-1],m=g/c*f[0];return{layout:n,pixelDimIndex:o,layoutBase:t[r[o]],layoutLength:s,axisBase:t[r[1-o]],axisLength:t[i[1-o]],axisExpandable:v,axisExpandWidth:c,axisCollapseWidth:g,axisExpandWindow:f,axisCount:u,winInnerIndices:y,axisExpandWindow0Pos:m}},a.prototype._layoutAxes=function(){var e=this._rect,t=this._axesMap,r=this.dimensions,i=this._makeLayoutInfo(),n=i.layout;t.each(function(o){var s=[0,i.axisLength],l=o.inverse?1:0;o.setExtent(s[l],s[1-l])}),ir(r,function(o,s){var l=(i.axisExpandable?Yc:Wc)(s,i),u={horizontal:{x:l.position,y:i.axisLength},vertical:{x:0,y:l.position}},c={horizontal:Fc/2,vertical:0},h=[u[n].x+e.x,u[n].y+e.y],v=c[n],f=fe();Oe(f,f,v),ne(f,f,h),this._axesLayout[o]={position:h,rotation:v,transform:f,axisNameAvailableWidth:l.axisNameAvailableWidth,axisLabelShow:l.axisLabelShow,nameTruncateMaxWidth:l.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},a.prototype.getAxis=function(e){return this._axesMap.get(e)},a.prototype.dataToPoint=function(e,t){return this.axisCoordToPoint(this._axesMap.get(t).dataToCoord(e),t)},a.prototype.eachActiveState=function(e,t,r,i){r==null&&(r=0),i==null&&(i=e.count());var n=this._axesMap,o=this.dimensions,s=[],l=[];_(o,function(g){s.push(e.mapDimension(g)),l.push(n.get(g).model)});for(var u=this.hasAxisBrushed(),c=r;c<i;c++){var h=void 0;if(!u)h="normal";else{h="active";for(var v=e.getValues(s,c),f=0,d=o.length;f<d;f++){var p=l[f].getActiveState(v[f]);if(p==="inactive"){h="inactive";break}}}t(h,c)}},a.prototype.hasAxisBrushed=function(){for(var e=this.dimensions,t=this._axesMap,r=!1,i=0,n=e.length;i<n;i++)t.get(e[i]).model.getActiveState()!=="normal"&&(r=!0);return r},a.prototype.axisCoordToPoint=function(e,t){var r=this._axesLayout[t];return le([e,0],r.transform)},a.prototype.getAxisLayout=function(e){return st(this._axesLayout[e])},a.prototype.getSlidedAxisExpandWindow=function(e){var t=this._makeLayoutInfo(),r=t.pixelDimIndex,i=t.axisExpandWindow.slice(),n=i[1]-i[0],o=[0,t.axisExpandWidth*(t.axisCount-1)];if(!this.containPoint(e))return{behavior:"none",axisExpandWindow:i};var s=e[r]-t.layoutBase-t.axisExpandWindow0Pos,l,u="slide",c=t.axisCollapseWidth,h=this._model.get("axisExpandSlideTriggerArea"),v=h[0]!=null;if(c)v&&c&&s<n*h[0]?(u="jump",l=s-n*h[2]):v&&c&&s>n*(1-h[0])?(u="jump",l=s-n*(1-h[2])):(l=s-n*h[1])>=0&&(l=s-n*(1-h[1]))<=0&&(l=0),l*=t.axisExpandWidth/c,l?Ye(l,i,o,"all"):u="none";else{var f=i[1]-i[0],d=o[1]*s/f;i=[In(0,d-f/2)],i[1]=Ln(o[1],i[0]+f),i[0]=i[1]-f}return{axisExpandWindow:i,behavior:u}},a}();function Ae(a,e){return Ln(In(a,e[0]),e[1])}function Wc(a,e){var t=e.layoutLength/(e.axisCount-1);return{position:t*a,axisNameAvailableWidth:t,axisLabelShow:!0}}function Yc(a,e){var t=e.layoutLength,r=e.axisExpandWidth,i=e.axisCount,n=e.axisCollapseWidth,o=e.winInnerIndices,s,l=n,u=!1,c;return a<o[0]?(s=a*n,c=n):a<=o[1]?(s=e.axisExpandWindow0Pos+a*r-e.axisExpandWindow[0],l=r,u=!0):(s=t-(i-1-a)*n,c=n),{position:s,axisNameAvailableWidth:l,axisLabelShow:u,nameTruncateMaxWidth:c}}const Zc=Oc;function $c(a,e){var t=[];return a.eachComponent("parallel",function(r,i){var n=new Zc(r,a,e);n.name="parallel_"+i,n.resize(r,e),r.coordinateSystem=n,n.model=r,t.push(n)}),a.eachSeries(function(r){if(r.get("coordinateSystem")==="parallel"){var i=r.getReferringComponents("parallel",We).models[0];r.coordinateSystem=i.coordinateSystem}}),t}var Hc={create:$c};const Xc=Hc;var Rn=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t.activeIntervals=[],t}return e.prototype.getAreaSelectStyle=function(){return zo([["fill","color"],["lineWidth","borderWidth"],["stroke","borderColor"],["width","width"],["opacity","opacity"]])(this.getModel("areaSelectStyle"))},e.prototype.setActiveIntervals=function(t){var r=this.activeIntervals=st(t);if(r)for(var i=r.length-1;i>=0;i--)Dt(r[i])},e.prototype.getActiveState=function(t){var r=this.activeIntervals;if(!r.length)return"normal";if(t==null||isNaN(+t))return"inactive";if(r.length===1){var i=r[0];if(i[0]<=t&&t<=i[1])return"active"}else for(var n=0,o=r.length;n<o;n++)if(r[n][0]<=t&&t<=r[n][1])return"active";return"inactive"},e}(K);Zt(Rn,Fe);const $a=Rn;var Uc=["axisLine","axisTickLabel","axisName"],jc=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r){a.prototype.init.apply(this,arguments),(this._brushController=new Vo(r.getZr())).on("brush",E(this._onBrush,this))},e.prototype.render=function(t,r,i,n){if(!Jc(t,r,n)){this.axisModel=t,this.api=i,this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new W,this.group.add(this._axisGroup),!!t.get("show")){var s=Kc(t,r),l=s.coordinateSystem,u=t.getAreaSelectStyle(),c=u.width,h=t.axis.dim,v=l.getAxisLayout(h),f=z({strokeContainThreshold:c},v),d=new Ft(t,f);_(Uc,d.add,d),this._axisGroup.add(d.getGroup()),this._refreshBrushController(f,u,t,s,c,i),ji(o,this._axisGroup,t)}}},e.prototype._refreshBrushController=function(t,r,i,n,o,s){var l=i.axis.getExtent(),u=l[1]-l[0],c=Math.min(30,Math.abs(u)*.1),h=rt.create({x:l[0],y:-o/2,width:u,height:o});h.x-=c,h.width+=2*c,this._brushController.mount({enableGlobalPan:!0,rotation:t.rotation,x:t.position[0],y:t.position[1]}).setPanels([{panelId:"pl",clipPath:Bo(h),isTargetByCursor:No(h,s,n),getLinearBrushOtherExtent:Fo(h,0)}]).enableBrush({brushType:"lineX",brushStyle:r,removeOnClick:!0}).updateCovers(qc(i))},e.prototype._onBrush=function(t){var r=t.areas,i=this.axisModel,n=i.axis,o=G(r,function(s){return[n.coordToData(s.range[0],!0),n.coordToData(s.range[1],!0)]});(!i.option.realtime===t.isEnd||t.removeOnClick)&&this.api.dispatchAction({type:"axisAreaSelect",parallelAxisId:i.id,intervals:o})},e.prototype.dispose=function(){this._brushController.dispose()},e.type="parallelAxis",e}(at);function Jc(a,e,t){return t&&t.type==="axisAreaSelect"&&e.findComponents({mainType:"parallelAxis",query:t})[0]===a}function qc(a){var e=a.axis;return G(a.activeIntervals,function(t){return{brushType:"lineX",panelId:"pl",range:[e.dataToCoord(t[0],!0),e.dataToCoord(t[1],!0)]}})}function Kc(a,e){return e.getComponent("parallel",a.get("parallelIndex"))}const Qc=jc;var th={type:"axisAreaSelect",event:"axisAreaSelected"};function eh(a){a.registerAction(th,function(e,t){t.eachComponent({mainType:"parallelAxis",query:e},function(r){r.axis.model.setActiveIntervals(e.intervals)})}),a.registerAction("parallelAxisExpand",function(e,t){t.eachComponent({mainType:"parallel",query:e},function(r){r.setAxisExpand(e)})})}var rh={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function ah(a){a.registerComponentView(kc),a.registerComponentModel(zc),a.registerCoordinateSystem("parallel",Xc),a.registerPreprocessor(Mc),a.registerComponentModel($a),a.registerComponentView(Qc),Sr(a,"parallel",$a,rh),eh(a)}var ih=["itemStyle","borderWidth"],Ha=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],nr=new yt,nh=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,i){var n=this.group,o=t.getData(),s=this._data,l=t.coordinateSystem,u=l.getBaseAxis(),c=u.isHorizontal(),h=l.master.getRect(),v={ecSize:{width:i.getWidth(),height:i.getHeight()},seriesModel:t,coordSys:l,coordSysExtent:[[h.x,h.x+h.width],[h.y,h.y+h.height]],isHorizontal:c,valueDim:Ha[+c],categoryDim:Ha[1-+c]};return o.diff(s).add(function(f){if(o.hasValue(f)){var d=Ua(o,f),p=Xa(o,f,d,v),g=ja(o,v,p);o.setItemGraphicEl(f,g),n.add(g),qa(g,v,p)}}).update(function(f,d){var p=s.getItemGraphicEl(d);if(!o.hasValue(f)){n.remove(p);return}var g=Ua(o,f),y=Xa(o,f,g,v),m=Bn(o,y);p&&m!==p.__pictorialShapeStr&&(n.remove(p),o.setItemGraphicEl(f,null),p=null),p?vh(p,v,y):p=ja(o,v,y,!0),o.setItemGraphicEl(f,p),p.__pictorialSymbolMeta=y,n.add(p),qa(p,v,y)}).remove(function(f){var d=s.getItemGraphicEl(f);d&&Ja(s,f,d.__pictorialSymbolMeta.animationModel,d)}).execute(),this._data=o,this.group},e.prototype.remove=function(t,r){var i=this.group,n=this._data;t.get("animation")?n&&n.eachItemGraphicEl(function(o){Ja(n,ht(o).dataIndex,t,o)}):i.removeAll()},e.type="pictorialBar",e}(Nt);function Xa(a,e,t,r){var i=a.getItemLayout(e),n=t.get("symbolRepeat"),o=t.get("symbolClip"),s=t.get("symbolPosition")||"start",l=t.get("symbolRotate"),u=(l||0)*Math.PI/180||0,c=t.get("symbolPatternSize")||2,h=t.isAnimationEnabled(),v={dataIndex:e,layout:i,itemModel:t,symbolType:a.getItemVisual(e,"symbol")||"circle",style:a.getItemVisual(e,"style"),symbolClip:o,symbolRepeat:n,symbolRepeatDirection:t.get("symbolRepeatDirection"),symbolPatternSize:c,rotation:u,animationModel:h?t:null,hoverScale:h&&t.get(["emphasis","scale"]),z2:t.getShallow("z",!0)||0};oh(t,n,i,r,v),sh(a,e,i,n,o,v.boundingLength,v.pxSign,c,r,v),lh(t,v.symbolScale,u,r,v);var f=v.symbolSize,d=Ji(t.get("symbolOffset"),f);return uh(t,f,i,n,o,d,s,v.valueLineWidth,v.boundingLength,v.repeatCutLength,r,v),v}function oh(a,e,t,r,i){var n=r.valueDim,o=a.get("symbolBoundingData"),s=r.coordSys.getOtherAxis(r.coordSys.getBaseAxis()),l=s.toGlobalCoord(s.dataToCoord(0)),u=1-+(t[n.wh]<=0),c;if(U(o)){var h=[or(s,o[0])-l,or(s,o[1])-l];h[1]<h[0]&&h.reverse(),c=h[u]}else o!=null?c=or(s,o)-l:e?c=r.coordSysExtent[n.index][u]-l:c=t[n.wh];i.boundingLength=c,e&&(i.repeatCutLength=t[n.wh]),i.pxSign=c>0?1:-1}function or(a,e){return a.toGlobalCoord(a.dataToCoord(a.scale.parse(e)))}function sh(a,e,t,r,i,n,o,s,l,u){var c=l.valueDim,h=l.categoryDim,v=Math.abs(t[h.wh]),f=a.getItemVisual(e,"symbolSize"),d;U(f)?d=f.slice():f==null?d=["100%","100%"]:d=[f,f],d[h.index]=V(d[h.index],v),d[c.index]=V(d[c.index],r?v:Math.abs(n)),u.symbolSize=d;var p=u.symbolScale=[d[0]/s,d[1]/s];p[c.index]*=(l.isHorizontal?-1:1)*o}function lh(a,e,t,r,i){var n=a.get(ih)||0;n&&(nr.attr({scaleX:e[0],scaleY:e[1],rotation:t}),nr.updateTransform(),n/=nr.getLineScale(),n*=e[r.valueDim.index]),i.valueLineWidth=n||0}function uh(a,e,t,r,i,n,o,s,l,u,c,h){var v=c.categoryDim,f=c.valueDim,d=h.pxSign,p=Math.max(e[f.index]+s,0),g=p;if(r){var y=Math.abs(l),m=Hi(a.get("symbolMargin"),"15%")+"",S=!1;m.lastIndexOf("!")===m.length-1&&(S=!0,m=m.slice(0,m.length-1));var x=V(m,e[f.index]),C=Math.max(p+x*2,0),w=S?0:x*2,b=qi(r),A=b?r:Ka((y+w)/C),T=y-A*p;x=T/2/(S?A:Math.max(A-1,1)),C=p+x*2,w=S?0:x*2,!b&&r!=="fixed"&&(A=u?Ka((Math.abs(u)+w)/C):0),g=A*C-w,h.repeatTimes=A,h.symbolMargin=x}var D=d*(g/2),M=h.pathPosition=[];M[v.index]=t[v.wh]/2,M[f.index]=o==="start"?D:o==="end"?l-D:l/2,n&&(M[0]+=n[0],M[1]+=n[1]);var R=h.bundlePosition=[];R[v.index]=t[v.xy],R[f.index]=t[f.xy];var P=h.barRectShape=z({},t);P[f.wh]=d*Math.max(Math.abs(t[f.wh]),Math.abs(M[f.index]+D)),P[v.wh]=t[v.wh];var k=h.clipShape={};k[v.xy]=-t[v.xy],k[v.wh]=c.ecSize[v.wh],k[f.xy]=0,k[f.wh]=t[f.wh]}function En(a){var e=a.symbolPatternSize,t=Lt(a.symbolType,-e/2,-e/2,e,e);return t.attr({culling:!0}),t.type!=="image"&&t.setStyle({strokeNoScale:!0}),t}function kn(a,e,t,r){var i=a.__pictorialBundle,n=t.symbolSize,o=t.valueLineWidth,s=t.pathPosition,l=e.valueDim,u=t.repeatTimes||0,c=0,h=n[e.valueDim.index]+o+t.symbolMargin*2;for(Fr(a,function(p){p.__pictorialAnimationIndex=c,p.__pictorialRepeatTimes=u,c<u?Bt(p,null,d(c),t,r):Bt(p,null,{scaleX:0,scaleY:0},t,r,function(){i.remove(p)}),c++});c<u;c++){var v=En(t);v.__pictorialAnimationIndex=c,v.__pictorialRepeatTimes=u,i.add(v);var f=d(c);Bt(v,{x:f.x,y:f.y,scaleX:0,scaleY:0},{scaleX:f.scaleX,scaleY:f.scaleY,rotation:f.rotation},t,r)}function d(p){var g=s.slice(),y=t.pxSign,m=p;return(t.symbolRepeatDirection==="start"?y>0:y<0)&&(m=u-1-p),g[l.index]=h*(m-u/2+.5)+s[l.index],{x:g[0],y:g[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation}}}function Gn(a,e,t,r){var i=a.__pictorialBundle,n=a.__pictorialMainPath;n?Bt(n,null,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation},t,r):(n=a.__pictorialMainPath=En(t),i.add(n),Bt(n,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:0,scaleY:0,rotation:t.rotation},{scaleX:t.symbolScale[0],scaleY:t.symbolScale[1]},t,r))}function zn(a,e,t){var r=z({},e.barRectShape),i=a.__pictorialBarRect;i?Bt(i,null,{shape:r},e,t):(i=a.__pictorialBarRect=new et({z2:2,shape:r,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),i.disableMorphing=!0,a.add(i))}function Vn(a,e,t,r){if(t.symbolClip){var i=a.__pictorialClipPath,n=z({},t.clipShape),o=e.valueDim,s=t.animationModel,l=t.dataIndex;if(i)Pt(i,{shape:n},s,l);else{n[o.wh]=0,i=new et({shape:n}),a.__pictorialBundle.setClipPath(i),a.__pictorialClipPath=i;var u={};u[o.wh]=t.clipShape[o.wh],Pr[r?"updateProps":"initProps"](i,{shape:u},s,l)}}}function Ua(a,e){var t=a.getItemModel(e);return t.getAnimationDelayParams=ch,t.isAnimationEnabled=hh,t}function ch(a){return{index:a.__pictorialAnimationIndex,count:a.__pictorialRepeatTimes}}function hh(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function ja(a,e,t,r){var i=new W,n=new W;return i.add(n),i.__pictorialBundle=n,n.x=t.bundlePosition[0],n.y=t.bundlePosition[1],t.symbolRepeat?kn(i,e,t):Gn(i,e,t),zn(i,t,r),Vn(i,e,t,r),i.__pictorialShapeStr=Bn(a,t),i.__pictorialSymbolMeta=t,i}function vh(a,e,t){var r=t.animationModel,i=t.dataIndex,n=a.__pictorialBundle;Pt(n,{x:t.bundlePosition[0],y:t.bundlePosition[1]},r,i),t.symbolRepeat?kn(a,e,t,!0):Gn(a,e,t,!0),zn(a,t,!0),Vn(a,e,t,!0)}function Ja(a,e,t,r){var i=r.__pictorialBarRect;i&&i.removeTextContent();var n=[];Fr(r,function(o){n.push(o)}),r.__pictorialMainPath&&n.push(r.__pictorialMainPath),r.__pictorialClipPath&&(t=null),_(n,function(o){Oo(o,{scaleX:0,scaleY:0},t,e,function(){r.parent&&r.parent.remove(r)})}),a.setItemGraphicEl(e,null)}function Bn(a,e){return[a.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function Fr(a,e,t){_(a.__pictorialBundle.children(),function(r){r!==a.__pictorialBarRect&&e.call(t,r)})}function Bt(a,e,t,r,i,n){e&&a.attr(e),r.symbolClip&&!i?t&&a.attr(t):t&&Pr[i?"updateProps":"initProps"](a,t,r.animationModel,r.dataIndex,n)}function qa(a,e,t){var r=t.dataIndex,i=t.itemModel,n=i.getModel("emphasis"),o=n.getModel("itemStyle").getItemStyle(),s=i.getModel(["blur","itemStyle"]).getItemStyle(),l=i.getModel(["select","itemStyle"]).getItemStyle(),u=i.getShallow("cursor"),c=n.get("focus"),h=n.get("blurScope"),v=n.get("scale");Fr(a,function(p){if(p instanceof kt){var g=p.style;p.useStyle(z({image:g.image,x:g.x,y:g.y,width:g.width,height:g.height},t.style))}else p.useStyle(t.style);var y=p.ensureState("emphasis");y.style=o,v&&(y.scaleX=p.scaleX*1.1,y.scaleY=p.scaleY*1.1),p.ensureState("blur").style=s,p.ensureState("select").style=l,u&&(p.cursor=u),p.z2=t.z2});var f=e.valueDim.posDesc[+(t.boundingLength>0)],d=a.__pictorialBarRect;Be(d,Ne(i),{labelFetcher:e.seriesModel,labelDataIndex:r,defaultText:Wo(e.seriesModel.getData(),r),inheritColor:t.style.fill,defaultOpacity:t.style.opacity,defaultOutsidePosition:f}),Mr(a,c,h,n.get("disabled"))}function Ka(a){var e=Math.round(a);return Math.abs(a-e)<1e-4?e:Math.ceil(a)}const fh=nh;var dh=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t.defaultSymbol="roundRect",t}return e.prototype.getInitialData=function(t){return t.stack=null,a.prototype.getInitialData.apply(this,arguments)},e.type="series.pictorialBar",e.dependencies=["grid"],e.defaultOption=Ze(sa.defaultOption,{symbol:"circle",symbolSize:null,symbolRotate:null,symbolPosition:null,symbolOffset:null,symbolMargin:null,symbolRepeat:!1,symbolRepeatDirection:"end",symbolClip:!1,symbolBoundingData:null,symbolPatternSize:400,barGap:"-100%",progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:"#212121"}}}),e}(sa);const ph=dh;function gh(a){a.registerChartView(fh),a.registerSeriesModel(ph),a.registerLayout(a.PRIORITY.VISUAL.LAYOUT,Ot(Yo,"pictorialBar")),a.registerLayout(a.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,Zo("pictorialBar"))}function yh(a,e,t,r){return a&&(a.legacy||a.legacy!==!1&&!t&&!r&&e!=="tspan"&&(e==="text"||I(a,"text")))}function mh(a,e,t){var r=a,i,n,o;if(e==="text")o=r;else{o={},I(r,"text")&&(o.text=r.text),I(r,"rich")&&(o.rich=r.rich),I(r,"textFill")&&(o.fill=r.textFill),I(r,"textStroke")&&(o.stroke=r.textStroke),I(r,"fontFamily")&&(o.fontFamily=r.fontFamily),I(r,"fontSize")&&(o.fontSize=r.fontSize),I(r,"fontStyle")&&(o.fontStyle=r.fontStyle),I(r,"fontWeight")&&(o.fontWeight=r.fontWeight),n={type:"text",style:o,silent:!0},i={};var s=I(r,"textPosition");t?i.position=s?r.textPosition:"inside":s&&(i.position=r.textPosition),I(r,"textPosition")&&(i.position=r.textPosition),I(r,"textOffset")&&(i.offset=r.textOffset),I(r,"textRotation")&&(i.rotation=r.textRotation),I(r,"textDistance")&&(i.distance=r.textDistance)}return Qa(o,a),_(o.rich,function(l){Qa(l,l)}),{textConfig:i,textContent:n}}function Qa(a,e){e&&(e.font=e.textFont||e.font,I(e,"textStrokeWidth")&&(a.lineWidth=e.textStrokeWidth),I(e,"textAlign")&&(a.align=e.textAlign),I(e,"textVerticalAlign")&&(a.verticalAlign=e.textVerticalAlign),I(e,"textLineHeight")&&(a.lineHeight=e.textLineHeight),I(e,"textWidth")&&(a.width=e.textWidth),I(e,"textHeight")&&(a.height=e.textHeight),I(e,"textBackgroundColor")&&(a.backgroundColor=e.textBackgroundColor),I(e,"textPadding")&&(a.padding=e.textPadding),I(e,"textBorderColor")&&(a.borderColor=e.textBorderColor),I(e,"textBorderWidth")&&(a.borderWidth=e.textBorderWidth),I(e,"textBorderRadius")&&(a.borderRadius=e.textBorderRadius),I(e,"textBoxShadowColor")&&(a.shadowColor=e.textBoxShadowColor),I(e,"textBoxShadowBlur")&&(a.shadowBlur=e.textBoxShadowBlur),I(e,"textBoxShadowOffsetX")&&(a.shadowOffsetX=e.textBoxShadowOffsetX),I(e,"textBoxShadowOffsetY")&&(a.shadowOffsetY=e.textBoxShadowOffsetY))}var Nn={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},ti=X(Nn);Rr(ue,function(a,e){return a[e]=1,a},{});ue.join(", ");var ze=["","style","shape","extra"],Wt=xt();function Or(a,e,t,r,i){var n=a+"Animation",o=Qi(a,r,i)||{},s=Wt(e).userDuring;return o.duration>0&&(o.during=s?E(Ah,{el:e,userDuring:s}):null,o.setToFinal=!0,o.scope=a),z(o,t[n]),o}function sr(a,e,t,r){r=r||{};var i=r.dataIndex,n=r.isInit,o=r.clearStyle,s=t.isAnimationEnabled(),l=Wt(a),u=e.style;l.userDuring=e.during;var c={},h={};if(Ch(a,e,h),ri("shape",e,h),ri("extra",e,h),!n&&s&&(Th(a,e,c),ei("shape",a,e,c),ei("extra",a,e,c),Dh(a,e,u,c)),h.style=u,Sh(a,h,o),bh(a,e),s)if(n){var v={};_(ze,function(d){var p=d?e[d]:e;p&&p.enterFrom&&(d&&(v[d]=v[d]||{}),z(d?v[d]:v,p.enterFrom))});var f=Or("enter",a,e,t,i);f.duration>0&&a.animateFrom(v,f)}else _h(a,e,i||0,t,c);Fn(a,e),u?a.dirty():a.markRedraw()}function Fn(a,e){for(var t=Wt(a).leaveToProps,r=0;r<ze.length;r++){var i=ze[r],n=i?e[i]:e;n&&n.leaveTo&&(t||(t=Wt(a).leaveToProps={}),i&&(t[i]=t[i]||{}),z(i?t[i]:t,n.leaveTo))}}function xh(a,e,t,r){if(a){var i=a.parent,n=Wt(a).leaveToProps;if(n){var o=Or("update",a,e,t,0);o.done=function(){i.remove(a),r&&r()},a.animateTo(n,o)}else i.remove(a),r&&r()}}function Mt(a){return a==="all"}function Sh(a,e,t){var r=e.style;if(!a.isGroup&&r){if(t){a.useStyle({});for(var i=a.animators,n=0;n<i.length;n++){var o=i[n];o.targetName==="style"&&o.changeTarget(a.style)}}a.setStyle(r)}e&&(e.style=null,e&&a.attr(e),e.style=r)}function _h(a,e,t,r,i){if(i){var n=Or("update",a,e,r,t);n.duration>0&&a.animateFrom(i,n)}}function bh(a,e){I(e,"silent")&&(a.silent=e.silent),I(e,"ignore")&&(a.ignore=e.ignore),a instanceof Ie&&I(e,"invisible")&&(a.invisible=e.invisible),a instanceof Ki&&I(e,"autoBatch")&&(a.autoBatch=e.autoBatch)}var nt={},wh={setTransform:function(a,e){return nt.el[a]=e,this},getTransform:function(a){return nt.el[a]},setShape:function(a,e){var t=nt.el,r=t.shape||(t.shape={});return r[a]=e,t.dirtyShape&&t.dirtyShape(),this},getShape:function(a){var e=nt.el.shape;if(e)return e[a]},setStyle:function(a,e){var t=nt.el,r=t.style;return r&&(r[a]=e,t.dirtyStyle&&t.dirtyStyle()),this},getStyle:function(a){var e=nt.el.style;if(e)return e[a]},setExtra:function(a,e){var t=nt.el.extra||(nt.el.extra={});return t[a]=e,this},getExtra:function(a){var e=nt.el.extra;if(e)return e[a]}};function Ah(){var a=this,e=a.el;if(e){var t=Wt(e).userDuring,r=a.userDuring;if(t!==r){a.el=a.userDuring=null;return}nt.el=e,r(wh)}}function ei(a,e,t,r){var i=t[a];if(i){var n=e[a],o;if(n){var s=t.transition,l=i.transition;if(l)if(!o&&(o=r[a]={}),Mt(l))z(o,n);else for(var u=se(l),c=0;c<u.length;c++){var h=u[c],v=n[h];o[h]=v}else if(Mt(s)||Xt(s,a)>=0){!o&&(o=r[a]={});for(var f=X(n),c=0;c<f.length;c++){var h=f[c],v=n[h];Mh(i[h],v)&&(o[h]=v)}}}}}function ri(a,e,t){var r=e[a];if(r)for(var i=t[a]={},n=X(r),o=0;o<n.length;o++){var s=n[o];i[s]=$o(r[s])}}function Th(a,e,t){for(var r=e.transition,i=Mt(r)?ue:se(r||[]),n=0;n<i.length;n++){var o=i[n];if(!(o==="style"||o==="shape"||o==="extra")){var s=a[o];t[o]=s}}}function Ch(a,e,t){for(var r=0;r<ti.length;r++){var i=ti[r],n=Nn[i],o=e[i];o&&(t[n[0]]=o[0],t[n[1]]=o[1])}for(var r=0;r<ue.length;r++){var s=ue[r];e[s]!=null&&(t[s]=e[s])}}function Dh(a,e,t,r){if(t){var i=a.style,n;if(i){var o=t.transition,s=e.transition;if(o&&!Mt(o)){var l=se(o);!n&&(n=r.style={});for(var u=0;u<l.length;u++){var c=l[u],h=i[c];n[c]=h}}else if(a.getAnimationStyleProps&&(Mt(s)||Mt(o)||Xt(s,"style")>=0)){var v=a.getAnimationStyleProps(),f=v?v.style:null;if(f){!n&&(n=r.style={});for(var d=X(t),u=0;u<d.length;u++){var c=d[u];if(f[c]){var h=i[c];n[c]=h}}}}}}}function Mh(a,e){return Ho(a)?a!==e:a!=null&&isFinite(a)}var On=xt(),Ph=["percent","easing","shape","style","extra"];function Lh(a){a.stopAnimation("keyframe"),a.attr(On(a))}function wr(a,e,t){if(!(!t.isAnimationEnabled()||!e)){if(U(e)){_(e,function(s){wr(a,s,t)});return}var r=e.keyframes,i=e.duration;if(t&&i==null){var n=Qi("enter",t,0);i=n&&n.duration}if(!(!r||!i)){var o=On(a);_(ze,function(s){if(!(s&&!a[s])){var l;r.sort(function(u,c){return u.percent-c.percent}),_(r,function(u){var c=a.animators,h=s?u[s]:u;if(h){var v=X(h);if(s||(v=Gt(v,function(p){return Xt(Ph,p)<0})),!!v.length){l||(l=a.animate(s,e.loop,!0),l.scope="keyframe");for(var f=0;f<c.length;f++)c[f]!==l&&c[f].targetName===l.targetName&&c[f].stopTracks(v);s&&(o[s]=o[s]||{});var d=s?o[s]:o;_(v,function(p){d[p]=((s?a[s]:a)||{})[p]}),l.whenWithKeys(i*u.percent,h,v,u.easing)}}}),l&&l.delay(e.delay||0).duration(i).start(e.easing)}})}}}function Ih(a){return Xo(null,a)}var Rh={isDimensionStacked:tn,enableDataStack:Uo,getStackedDimension:jo};function Eh(a,e){var t=e;e instanceof It||(t=new It(e));var r=kr(t);return r.setExtent(a[0],a[1]),Re(r,t),r}function kh(a){Zt(a,Fe)}function Gh(a,e){return e=e||{},ut(a,null,null,e.state!=="normal")}const zh=Object.freeze(Object.defineProperty({__proto__:null,createDimensions:Jo,createList:Ih,createScale:Eh,createSymbol:Lt,createTextStyle:Gh,dataStack:Rh,enableHoverEmphasis:ee,getECData:ht,getLayoutRect:$t,mixinAxisModelCommonMethods:kh},Symbol.toStringTag,{value:"Module"})),Vh=Object.freeze(Object.defineProperty({__proto__:null,MAX_SAFE_INTEGER:qo,asc:Dt,getPercentWithPrecision:Ko,getPixelPrecision:Qo,getPrecision:ts,getPrecisionSafe:es,isNumeric:qi,isRadianAroundZero:rs,linearMap:it,nice:as,numericToNumber:is,parseDate:Gr,quantile:ns,quantity:os,quantityExponent:ss,reformIntervals:ls,remRadian:us,round:Ui},Symbol.toStringTag,{value:"Module"})),Bh=Object.freeze(Object.defineProperty({__proto__:null,format:cs,parse:Gr},Symbol.toStringTag,{value:"Module"})),Nh=Object.freeze(Object.defineProperty({__proto__:null,Arc:hs,BezierCurve:vs,BoundingRect:rt,Circle:yt,CompoundPath:Ir,Ellipse:Bi,Group:W,Image:kt,IncrementalDisplayable:fs,Line:dt,LinearGradient:Ni,Polygon:Yt,Polyline:Et,RadialGradient:Fi,Rect:et,Ring:Lr,Sector:zr,Text:tt,clipPointsByRect:ds,clipRectByRect:ps,createIcon:en,extendPath:gs,extendShape:ys,getShapeClass:rn,getTransform:an,initProps:gr,makeImage:ms,makePath:xs,mergePath:Q,registerShape:Ss,resizePath:_s,updateProps:Pt},Symbol.toStringTag,{value:"Module"})),Fh=Object.freeze(Object.defineProperty({__proto__:null,addCommas:bs,capitalFirst:ws,encodeHTML:nn,formatTime:As,formatTpl:Ts,getTextRect:hu,getTooltipMarker:Cs,normalizeCssArray:Ds,toCamelCase:Ms,truncateText:Ps},Symbol.toStringTag,{value:"Module"})),Oh=Object.freeze(Object.defineProperty({__proto__:null,bind:E,clone:st,curry:Ot,defaults:Y,each:_,extend:z,filter:Gt,indexOf:Xt,inherits:Ls,isArray:U,isFunction:mt,isObject:Ht,isString:Z,map:G,merge:ct,reduce:Rr},Symbol.toStringTag,{value:"Module"}));function Wh(a){var e=K.extend(a);return K.registerClass(e),e}function Yh(a){var e=at.extend(a);return at.registerClass(e),e}function Zh(a){var e=ie.extend(a);return ie.registerClass(e),e}function $h(a){var e=Nt.extend(a);return Nt.registerClass(e),e}const dd=Object.freeze(Object.defineProperty({__proto__:null,Axis:lt,ChartView:Nt,ComponentModel:K,ComponentView:at,List:on,Model:It,PRIORITY:Is,SeriesModel:ie,color:Rs,connect:Es,dataTool:ks,dependencies:Gs,disConnect:zs,disconnect:Vs,dispose:Bs,env:Ns,extendChartView:$h,extendComponentModel:Wh,extendComponentView:Yh,extendSeriesModel:Zh,format:Fh,getCoordinateSystemDimensions:Fs,getInstanceByDom:Os,getInstanceById:Ws,getMap:Ys,graphic:Nh,helper:zh,init:Zs,innerDrawElementOnCanvas:$s,matrix:Hs,number:Vh,parseGeoJSON:_r,parseGeoJson:_r,registerAction:Xs,registerCoordinateSystem:Us,registerLayout:js,registerLoading:Js,registerLocale:qs,registerMap:Ks,registerPostInit:Qs,registerPostUpdate:tl,registerPreprocessor:el,registerProcessor:rl,registerTheme:al,registerTransform:il,registerUpdateLifecycle:nl,registerVisual:ol,setCanvasCreator:sl,setPlatformAPI:ll,throttle:ul,time:Bh,use:Rt,util:Oh,vector:cl,version:hl,zrUtil:vl,zrender:fl},Symbol.toStringTag,{value:"Module"}));var Hh=function(a){L(e,a);function e(){return a!==null&&a.apply(this,arguments)||this}return e.prototype.makeElOption=function(t,r,i,n,o){var s=i.axis;s.dim==="angle"&&(this.animationThreshold=Math.PI/18);var l=s.polar,u=l.getOtherAxis(s),c=u.getExtent(),h=s.dataToCoord(r),v=n.get("type");if(v&&v!=="none"){var f=dl(n),d=Uh[v](s,l,h,c);d.style=f,t.graphicKey=d.type,t.pointer=d}var p=n.get(["label","margin"]),g=Xh(r,i,n,l,p);pl(t,i,n,o,g)},e}(gl);function Xh(a,e,t,r,i){var n=e.axis,o=n.dataToCoord(a),s=r.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l=r.getRadiusAxis().getExtent(),u,c,h;if(n.dim==="radius"){var v=fe();Oe(v,v,s),ne(v,v,[r.cx,r.cy]),u=le([o,-i],v);var f=e.getModel("axisLabel").get("rotate")||0,d=Ft.innerTextLayout(s,f*Math.PI/180,-1);c=d.textAlign,h=d.textVerticalAlign}else{var p=l[1];u=r.coordToPoint([p+i,o]);var g=r.cx,y=r.cy;c=Math.abs(u[0]-g)/p<.3?"center":u[0]>g?"left":"right",h=Math.abs(u[1]-y)/p<.3?"middle":u[1]>y?"top":"bottom"}return{position:u,align:c,verticalAlign:h}}var Uh={line:function(a,e,t,r){return a.dim==="angle"?{type:"Line",shape:yl(e.coordToPoint([r[0],t]),e.coordToPoint([r[1],t]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:t}}},shadow:function(a,e,t,r){var i=Math.max(1,a.getBandWidth()),n=Math.PI/180;return a.dim==="angle"?{type:"Sector",shape:la(e.cx,e.cy,r[0],r[1],(-t-i/2)*n,(-t+i/2)*n)}:{type:"Sector",shape:la(e.cx,e.cy,t-i/2,t+i/2,0,Math.PI*2)}}};const jh=Hh;var Jh=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.findAxisModel=function(t){var r,i=this.ecModel;return i.eachComponent(t,function(n){n.getCoordSysModel()===this&&(r=n)},this),r},e.type="polar",e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e}(K);const qh=Jh;var Wr=function(a){L(e,a);function e(){return a!==null&&a.apply(this,arguments)||this}return e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",We).models[0]},e.type="polarAxis",e}(K);Zt(Wr,Fe);var Kh=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.type="angleAxis",e}(Wr),Qh=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.type="radiusAxis",e}(Wr),Yr=function(a){L(e,a);function e(t,r){return a.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}(lt);Yr.prototype.dataToRadius=lt.prototype.dataToCoord;Yr.prototype.radiusToData=lt.prototype.coordToData;const tv=Yr;var ev=xt(),Zr=function(a){L(e,a);function e(t,r){return a.call(this,"angle",t,r||[0,360])||this}return e.prototype.pointToData=function(t,r){return this.polar.pointToData(t,r)[this.dim==="radius"?0:1]},e.prototype.calculateCategoryInterval=function(){var t=this,r=t.getLabelModel(),i=t.scale,n=i.getExtent(),o=i.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),c=ml(s==null?"":s+"",r.getFont(),"center","top"),h=Math.max(c.height,7),v=h/u;isNaN(v)&&(v=1/0);var f=Math.max(0,Math.floor(v)),d=ev(t.model),p=d.lastAutoInterval,g=d.lastTickCount;return p!=null&&g!=null&&Math.abs(p-f)<=1&&Math.abs(g-o)<=1&&p>f?f=p:(d.lastTickCount=o,d.lastAutoInterval=f),f},e}(lt);Zr.prototype.dataToAngle=lt.prototype.dataToCoord;Zr.prototype.angleToData=lt.prototype.coordToData;const rv=Zr;var Wn=["radius","angle"],av=function(){function a(e){this.dimensions=Wn,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new tv,this._angleAxis=new rv,this.axisPointerEnabled=!0,this.name=e||"",this._radiusAxis.polar=this._angleAxis.polar=this}return a.prototype.containPoint=function(e){var t=this.pointToCoord(e);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},a.prototype.containData=function(e){return this._radiusAxis.containData(e[0])&&this._angleAxis.containData(e[1])},a.prototype.getAxis=function(e){var t="_"+e+"Axis";return this[t]},a.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},a.prototype.getAxesByScale=function(e){var t=[],r=this._angleAxis,i=this._radiusAxis;return r.scale.type===e&&t.push(r),i.scale.type===e&&t.push(i),t},a.prototype.getAngleAxis=function(){return this._angleAxis},a.prototype.getRadiusAxis=function(){return this._radiusAxis},a.prototype.getOtherAxis=function(e){var t=this._angleAxis;return e===t?this._radiusAxis:t},a.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},a.prototype.getTooltipAxes=function(e){var t=e!=null&&e!=="auto"?this.getAxis(e):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},a.prototype.dataToPoint=function(e,t){return this.coordToPoint([this._radiusAxis.dataToRadius(e[0],t),this._angleAxis.dataToAngle(e[1],t)])},a.prototype.pointToData=function(e,t){var r=this.pointToCoord(e);return[this._radiusAxis.radiusToData(r[0],t),this._angleAxis.angleToData(r[1],t)]},a.prototype.pointToCoord=function(e){var t=e[0]-this.cx,r=e[1]-this.cy,i=this.getAngleAxis(),n=i.getExtent(),o=Math.min(n[0],n[1]),s=Math.max(n[0],n[1]);i.inverse?o=s-360:s=o+360;var l=Math.sqrt(t*t+r*r);t/=l,r/=l;for(var u=Math.atan2(-r,t)/Math.PI*180,c=u<o?1:-1;u<o||u>s;)u+=c*360;return[l,u]},a.prototype.coordToPoint=function(e){var t=e[0],r=e[1]/180*Math.PI,i=Math.cos(r)*t+this.cx,n=-Math.sin(r)*t+this.cy;return[i,n]},a.prototype.getArea=function(){var e=this.getAngleAxis(),t=this.getRadiusAxis(),r=t.getExtent().slice();r[0]>r[1]&&r.reverse();var i=e.getExtent(),n=Math.PI/180;return{cx:this.cx,cy:this.cy,r0:r[0],r:r[1],startAngle:-i[0]*n,endAngle:-i[1]*n,clockwise:e.inverse,contain:function(o,s){var l=o-this.cx,u=s-this.cy,c=l*l+u*u-1e-4,h=this.r,v=this.r0;return c<=h*h&&c>=v*v}}},a.prototype.convertToPixel=function(e,t,r){var i=ai(t);return i===this?this.dataToPoint(r):null},a.prototype.convertFromPixel=function(e,t,r){var i=ai(t);return i===this?this.pointToData(r):null},a}();function ai(a){var e=a.seriesModel,t=a.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}const iv=av;function nv(a,e,t){var r=e.get("center"),i=t.getWidth(),n=t.getHeight();a.cx=V(r[0],i),a.cy=V(r[1],n);var o=a.getRadiusAxis(),s=Math.min(i,n)/2,l=e.get("radius");l==null?l=[0,"100%"]:U(l)||(l=[0,l]);var u=[V(l[0],s),V(l[1],s)];o.inverse?o.setExtent(u[1],u[0]):o.setExtent(u[0],u[1])}function ov(a,e){var t=this,r=t.getAngleAxis(),i=t.getRadiusAxis();if(r.scale.setExtent(1/0,-1/0),i.scale.setExtent(1/0,-1/0),a.eachSeries(function(s){if(s.coordinateSystem===t){var l=s.getData();_(ua(l,"radius"),function(u){i.scale.unionExtentFromData(l,u)}),_(ua(l,"angle"),function(u){r.scale.unionExtentFromData(l,u)})}}),Re(r.scale,r.model),Re(i.scale,i.model),r.type==="category"&&!r.onBand){var n=r.getExtent(),o=360/r.scale.count();r.inverse?n[1]+=o:n[1]-=o,r.setExtent(n[0],n[1])}}function sv(a){return a.mainType==="angleAxis"}function ii(a,e){if(a.type=e.get("type"),a.scale=kr(e),a.onBand=e.get("boundaryGap")&&a.type==="category",a.inverse=e.get("inverse"),sv(e)){a.inverse=a.inverse!==e.get("clockwise");var t=e.get("startAngle");a.setExtent(t,t+(a.inverse?-360:360))}e.axis=a,a.model=e}var lv={dimensions:Wn,create:function(a,e){var t=[];return a.eachComponent("polar",function(r,i){var n=new iv(i+"");n.update=ov;var o=n.getRadiusAxis(),s=n.getAngleAxis(),l=r.findAxisModel("radiusAxis"),u=r.findAxisModel("angleAxis");ii(o,l),ii(s,u),nv(n,r,e),t.push(n),r.coordinateSystem=n,n.model=r}),a.eachSeries(function(r){if(r.get("coordinateSystem")==="polar"){var i=r.getReferringComponents("polar",We).models[0];r.coordinateSystem=i.coordinateSystem}}),t}};const uv=lv;var cv=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function Te(a,e,t){e[1]>e[0]&&(e=e.slice().reverse());var r=a.coordToPoint([e[0],t]),i=a.coordToPoint([e[1],t]);return{x1:r[0],y1:r[1],x2:i[0],y2:i[1]}}function Ce(a){var e=a.getRadiusAxis();return e.inverse?0:1}function ni(a){var e=a[0],t=a[a.length-1];e&&t&&Math.abs(Math.abs(e.coord-t.coord)-360)<1e-4&&a.pop()}var hv=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,r){if(this.group.removeAll(),!!t.get("show")){var i=t.axis,n=i.polar,o=n.getRadiusAxis().getExtent(),s=i.getTicksCoords(),l=i.getMinorTicksCoords(),u=G(i.getViewLabels(),function(c){c=st(c);var h=i.scale,v=h.type==="ordinal"?h.getRawOrdinalNumber(c.tickValue):c.tickValue;return c.coord=i.dataToCoord(v),c});ni(u),ni(s),_(cv,function(c){t.get([c,"show"])&&(!i.scale.isBlank()||c==="axisLine")&&vv[c](this.group,t,n,s,l,o,u)},this)}},e.type="angleAxis",e}(Vr),vv={axisLine:function(a,e,t,r,i,n){var o=e.getModel(["axisLine","lineStyle"]),s=Ce(t),l=s?0:1,u;n[l]===0?u=new yt({shape:{cx:t.cx,cy:t.cy,r:n[s]},style:o.getLineStyle(),z2:1,silent:!0}):u=new Lr({shape:{cx:t.cx,cy:t.cy,r:n[s],r0:n[l]},style:o.getLineStyle(),z2:1,silent:!0}),u.style.fill=null,a.add(u)},axisTick:function(a,e,t,r,i,n){var o=e.getModel("axisTick"),s=(o.get("inside")?-1:1)*o.get("length"),l=n[Ce(t)],u=G(r,function(c){return new dt({shape:Te(t,[l,l+s],c.coord)})});a.add(Q(u,{style:Y(o.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(a,e,t,r,i,n){if(i.length){for(var o=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(o.get("inside")?-1:1)*s.get("length"),u=n[Ce(t)],c=[],h=0;h<i.length;h++)for(var v=0;v<i[h].length;v++)c.push(new dt({shape:Te(t,[u,u+l],i[h][v].coord)}));a.add(Q(c,{style:Y(s.getModel("lineStyle").getLineStyle(),Y(o.getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])}))}))}},axisLabel:function(a,e,t,r,i,n,o){var s=e.getCategories(!0),l=e.getModel("axisLabel"),u=l.get("margin"),c=e.get("triggerEvent");_(o,function(h,v){var f=l,d=h.tickValue,p=n[Ce(t)],g=t.coordToPoint([p+u,h.coord]),y=t.cx,m=t.cy,S=Math.abs(g[0]-y)/p<.3?"center":g[0]>y?"left":"right",x=Math.abs(g[1]-m)/p<.3?"middle":g[1]>m?"top":"bottom";if(s&&s[d]){var C=s[d];Ht(C)&&C.textStyle&&(f=new It(C.textStyle,l,l.ecModel))}var w=new tt({silent:Ft.isLabelSilent(e),style:ut(f,{x:g[0],y:g[1],fill:f.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:h.formattedLabel,align:S,verticalAlign:x})});if(a.add(w),c){var b=Ft.makeAxisEventDataBase(e);b.targetType="axisLabel",b.value=h.rawLabel,ht(w).eventData=b}},this)},splitLine:function(a,e,t,r,i,n){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],h=0;h<r.length;h++){var v=u++%l.length;c[v]=c[v]||[],c[v].push(new dt({shape:Te(t,n,r[h].coord)}))}for(var h=0;h<c.length;h++)a.add(Q(c[h],{style:Y({stroke:l[h%l.length]},s.getLineStyle()),silent:!0,z:e.get("z")}))},minorSplitLine:function(a,e,t,r,i,n){if(i.length){for(var o=e.getModel("minorSplitLine"),s=o.getModel("lineStyle"),l=[],u=0;u<i.length;u++)for(var c=0;c<i[u].length;c++)l.push(new dt({shape:Te(t,n,i[u][c].coord)}));a.add(Q(l,{style:s.getLineStyle(),silent:!0,z:e.get("z")}))}},splitArea:function(a,e,t,r,i,n){if(r.length){var o=e.getModel("splitArea"),s=o.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],h=Math.PI/180,v=-r[0].coord*h,f=Math.min(n[0],n[1]),d=Math.max(n[0],n[1]),p=e.get("clockwise"),g=1,y=r.length;g<=y;g++){var m=g===y?r[0].coord:r[g].coord,S=u++%l.length;c[S]=c[S]||[],c[S].push(new zr({shape:{cx:t.cx,cy:t.cy,r0:f,r:d,startAngle:v,endAngle:-m*h,clockwise:p},silent:!0})),v=-m*h}for(var g=0;g<c.length;g++)a.add(Q(c[g],{style:Y({fill:l[g%l.length]},s.getAreaStyle()),silent:!0}))}}};const fv=hv;var dv=["axisLine","axisTickLabel","axisName"],pv=["splitLine","splitArea","minorSplitLine"],gv=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return e.prototype.render=function(t,r){if(this.group.removeAll(),!!t.get("show")){var i=this._axisGroup,n=this._axisGroup=new W;this.group.add(n);var o=t.axis,s=o.polar,l=s.getAngleAxis(),u=o.getTicksCoords(),c=o.getMinorTicksCoords(),h=l.getExtent()[0],v=o.getExtent(),f=mv(s,t,h),d=new Ft(t,f);_(dv,d.add,d),n.add(d.getGroup()),ji(i,n,t),_(pv,function(p){t.get([p,"show"])&&!o.scale.isBlank()&&yv[p](this.group,t,s,h,v,u,c)},this)}},e.type="radiusAxis",e}(Vr),yv={splitLine:function(a,e,t,r,i,n){var o=e.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],h=0;h<n.length;h++){var v=u++%l.length;c[v]=c[v]||[],c[v].push(new yt({shape:{cx:t.cx,cy:t.cy,r:Math.max(n[h].coord,0)}}))}for(var h=0;h<c.length;h++)a.add(Q(c[h],{style:Y({stroke:l[h%l.length],fill:null},s.getLineStyle()),silent:!0}))},minorSplitLine:function(a,e,t,r,i,n,o){if(o.length){for(var s=e.getModel("minorSplitLine"),l=s.getModel("lineStyle"),u=[],c=0;c<o.length;c++)for(var h=0;h<o[c].length;h++)u.push(new yt({shape:{cx:t.cx,cy:t.cy,r:o[c][h].coord}}));a.add(Q(u,{style:Y({fill:null},l.getLineStyle()),silent:!0}))}},splitArea:function(a,e,t,r,i,n){if(n.length){var o=e.getModel("splitArea"),s=o.getModel("areaStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var c=[],h=n[0].coord,v=1;v<n.length;v++){var f=u++%l.length;c[f]=c[f]||[],c[f].push(new zr({shape:{cx:t.cx,cy:t.cy,r0:h,r:n[v].coord,startAngle:0,endAngle:Math.PI*2},silent:!0})),h=n[v].coord}for(var v=0;v<c.length;v++)a.add(Q(c[v],{style:Y({fill:l[v%l.length]},s.getAreaStyle()),silent:!0}))}}};function mv(a,e,t){return{position:[a.cx,a.cy],rotation:t/180*Math.PI,labelDirection:-1,tickDirection:-1,nameDirection:1,labelRotate:e.getModel("axisLabel").get("rotate"),z2:1}}const xv=gv;function Yn(a){return a.get("stack")||"__ec_stack_"+a.seriesIndex}function Zn(a,e){return e.dim+a.model.componentIndex}function Sv(a,e,t){var r={},i=_v(Gt(e.getSeriesByType(a),function(n){return!e.isSeriesFiltered(n)&&n.coordinateSystem&&n.coordinateSystem.type==="polar"}));e.eachSeriesByType(a,function(n){if(n.coordinateSystem.type==="polar"){var o=n.getData(),s=n.coordinateSystem,l=s.getBaseAxis(),u=Zn(s,l),c=Yn(n),h=i[u][c],v=h.offset,f=h.width,d=s.getOtherAxis(l),p=n.coordinateSystem.cx,g=n.coordinateSystem.cy,y=n.get("barMinHeight")||0,m=n.get("barMinAngle")||0;r[c]=r[c]||[];for(var S=o.mapDimension(d.dim),x=o.mapDimension(l.dim),C=tn(o,S),w=l.dim!=="radius"||!n.get("roundCap",!0),b=d.dataToCoord(0),A=0,T=o.count();A<T;A++){var D=o.get(S,A),M=o.get(x,A),R=D>=0?"p":"n",P=b;C&&(r[c][M]||(r[c][M]={p:b,n:b}),P=r[c][M][R]);var k=void 0,N=void 0,F=void 0,O=void 0;if(d.dim==="radius"){var $=d.dataToCoord(D)-b,St=l.dataToCoord(M);Math.abs($)<y&&($=($<0?-1:1)*y),k=P,N=P+$,F=St-v,O=F-f,C&&(r[c][M][R]=N)}else{var ft=d.dataToCoord(D,w)-b,Ut=l.dataToCoord(M);Math.abs(ft)<m&&(ft=(ft<0?-1:1)*m),k=Ut+v,N=k+f,F=P,O=P+ft,C&&(r[c][M][R]=O)}o.setItemLayout(A,{cx:p,cy:g,r0:k,r:N,startAngle:-F*Math.PI/180,endAngle:-O*Math.PI/180,clockwise:F>=O})}}})}function _v(a){var e={};_(a,function(r,i){var n=r.getData(),o=r.coordinateSystem,s=o.getBaseAxis(),l=Zn(o,s),u=s.getExtent(),c=s.type==="category"?s.getBandWidth():Math.abs(u[1]-u[0])/n.count(),h=e[l]||{bandWidth:c,remainedWidth:c,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},v=h.stacks;e[l]=h;var f=Yn(r);v[f]||h.autoWidthCount++,v[f]=v[f]||{width:0,maxWidth:0};var d=V(r.get("barWidth"),c),p=V(r.get("barMaxWidth"),c),g=r.get("barGap"),y=r.get("barCategoryGap");d&&!v[f].width&&(d=Math.min(h.remainedWidth,d),v[f].width=d,h.remainedWidth-=d),p&&(v[f].maxWidth=p),g!=null&&(h.gap=g),y!=null&&(h.categoryGap=y)});var t={};return _(e,function(r,i){t[i]={};var n=r.stacks,o=r.bandWidth,s=V(r.categoryGap,o),l=V(r.gap,1),u=r.remainedWidth,c=r.autoWidthCount,h=(u-s)/(c+(c-1)*l);h=Math.max(h,0),_(n,function(p,g){var y=p.maxWidth;y&&y<h&&(y=Math.min(y,u),p.width&&(y=Math.min(y,p.width)),u-=y,p.width=y,c--)}),h=(u-s)/(c+(c-1)*l),h=Math.max(h,0);var v=0,f;_(n,function(p,g){p.width||(p.width=h),f=p,v+=p.width*(1+l)}),f&&(v-=f.width*l);var d=-v/2;_(n,function(p,g){t[i][g]=t[i][g]||{offset:d,width:p.width},d+=p.width*(1+l)})}),t}var bv={startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:0}},wv={splitNumber:5},Av=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.type="polar",e}(at);function Tv(a){Rt(xl),Vr.registerAxisPointerClass("PolarAxisPointer",jh),a.registerCoordinateSystem("polar",uv),a.registerComponentModel(qh),a.registerComponentView(Av),Sr(a,"angle",Kh,bv),Sr(a,"radius",Qh,wv),a.registerComponentView(fv),a.registerComponentView(xv),a.registerLayout(Ot(Sv,"bar"))}var Cv=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r,i){var n=sn(t);a.prototype.init.apply(this,arguments),oi(t,n)},e.prototype.mergeOption=function(t){a.prototype.mergeOption.apply(this,arguments),oi(this.option,t)},e.prototype.getCellSize=function(){return this.option.cellSize},e.type="calendar",e.defaultOption={z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:"#000",width:1,type:"solid"}},itemStyle:{color:"#fff",borderWidth:1,borderColor:"#ccc"},dayLabel:{show:!0,firstDay:0,position:"start",margin:"50%",color:"#000"},monthLabel:{show:!0,position:"start",margin:5,align:"center",formatter:null,color:"#000"},yearLabel:{show:!0,position:null,margin:30,formatter:null,color:"#ccc",fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},e}(K);function oi(a,e){var t=a.cellSize,r;U(t)?r=t:r=a.cellSize=[t,t],r.length===1&&(r[1]=r[0]);var i=G([0,1],function(n){return Sl(e,n)&&(r[n]="auto"),r[n]!=null&&r[n]!=="auto"});ln(a,e,{type:"box",ignoreSize:i})}const Dv=Cv;var Mv=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.render=function(t,r,i){var n=this.group;n.removeAll();var o=t.coordinateSystem,s=o.getRangeInfo(),l=o.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,i){for(var n=t.coordinateSystem,o=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 c=n.dataToRect([u],!1).tl,h=new et({shape:{x:c[0],y:c[1],width:s,height:l},cursor:"default",style:o});i.add(h)}},e.prototype._renderLines=function(t,r,i,n){var o=this,s=t.coordinateSystem,l=t.getModel(["splitLine","lineStyle"]).getLineStyle(),u=t.get(["splitLine","show"]),c=l.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var h=r.start,v=0;h.time<=r.end.time;v++){d(h.formatedDate),v===0&&(h=s.getDateInfo(r.start.y+"-"+r.start.m));var f=h.date;f.setMonth(f.getMonth()+1),h=s.getDateInfo(f)}d(s.getNextNDay(r.end.time,1).formatedDate);function d(p){o._firstDayOfMonth.push(s.getDateInfo(p)),o._firstDayPoints.push(s.dataToRect([p],!1).tl);var g=o._getLinePointsOfOneWeek(t,p,i);o._tlpoints.push(g[0]),o._blpoints.push(g[g.length-1]),u&&o._drawSplitline(g,l,n)}u&&this._drawSplitline(o._getEdgesPoints(o._tlpoints,c,i),l,n),u&&this._drawSplitline(o._getEdgesPoints(o._blpoints,c,i),l,n)},e.prototype._getEdgesPoints=function(t,r,i){var n=[t[0].slice(),t[t.length-1].slice()],o=i==="horizontal"?0:1;return n[0][o]=n[0][o]-r/2,n[1][o]=n[1][o]+r/2,n},e.prototype._drawSplitline=function(t,r,i){var n=new Et({z2:20,shape:{points:t},style:r});i.add(n)},e.prototype._getLinePointsOfOneWeek=function(t,r,i){for(var n=t.coordinateSystem,o=n.getDateInfo(r),s=[],l=0;l<7;l++){var u=n.getNextNDay(o.time,l),c=n.dataToRect([u.time],!1);s[2*u.day]=c.tl,s[2*u.day+1]=c[i==="horizontal"?"bl":"tr"]}return s},e.prototype._formatterLabel=function(t,r){return Z(t)&&t?_l(t,r):mt(t)?t(r):r.nameMap},e.prototype._yearTextPositionControl=function(t,r,i,n,o){var s=r[0],l=r[1],u=["center","bottom"];n==="bottom"?(l+=o,u=["center","top"]):n==="left"?s-=o:n==="right"?(s+=o,u=["center","top"]):l-=o;var c=0;return(n==="left"||n==="right")&&(c=Math.PI/2),{rotation:c,x:s,y:l,style:{align:u[0],verticalAlign:u[1]}}},e.prototype._renderYearText=function(t,r,i,n){var o=t.getModel("yearLabel");if(o.get("show")){var s=o.get("margin"),l=o.get("position");l||(l=i!=="horizontal"?"top":"left");var u=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],c=(u[0][0]+u[1][0])/2,h=(u[0][1]+u[1][1])/2,v=i==="horizontal"?0:1,f={top:[c,u[v][1]],bottom:[c,u[1-v][1]],left:[u[1-v][0],h],right:[u[v][0],h]},d=r.start.y;+r.end.y>+r.start.y&&(d=d+"-"+r.end.y);var p=o.get("formatter"),g={start:r.start.y,end:r.end.y,nameMap:d},y=this._formatterLabel(p,g),m=new tt({z2:30,style:ut(o,{text:y})});m.attr(this._yearTextPositionControl(m,f[l],i,l,s)),n.add(m)}},e.prototype._monthTextPositionControl=function(t,r,i,n,o){var s="left",l="top",u=t[0],c=t[1];return i==="horizontal"?(c=c+o,r&&(s="center"),n==="start"&&(l="bottom")):(u=u+o,r&&(l="middle"),n==="start"&&(s="right")),{x:u,y:c,align:s,verticalAlign:l}},e.prototype._renderMonthText=function(t,r,i,n){var o=t.getModel("monthLabel");if(o.get("show")){var s=o.get("nameMap"),l=o.get("margin"),u=o.get("position"),c=o.get("align"),h=[this._tlpoints,this._blpoints];(!s||Z(s))&&(s&&(r=ca(s)||r),s=r.get(["time","monthAbbr"])||[]);var v=u==="start"?0:1,f=i==="horizontal"?0:1;l=u==="start"?-l:l;for(var d=c==="center",p=0;p<h[v].length-1;p++){var g=h[v][p].slice(),y=this._firstDayOfMonth[p];if(d){var m=this._firstDayPoints[p];g[f]=(m[f]+h[0][p+1][f])/2}var S=o.get("formatter"),x=s[+y.m-1],C={yyyy:y.y,yy:(y.y+"").slice(2),MM:y.m,M:+y.m,nameMap:x},w=this._formatterLabel(S,C),b=new tt({z2:30,style:z(ut(o,{text:w}),this._monthTextPositionControl(g,d,i,u,l))});n.add(b)}}},e.prototype._weekTextPositionControl=function(t,r,i,n,o){var s="center",l="middle",u=t[0],c=t[1],h=i==="start";return r==="horizontal"?(u=u+n+(h?1:-1)*o[0]/2,s=h?"right":"left"):(c=c+n+(h?1:-1)*o[1]/2,l=h?"bottom":"top"),{x:u,y:c,align:s,verticalAlign:l}},e.prototype._renderWeekText=function(t,r,i,n,o){var s=t.getModel("dayLabel");if(s.get("show")){var l=t.coordinateSystem,u=s.get("position"),c=s.get("nameMap"),h=s.get("margin"),v=l.getFirstDayOfWeek();if(!c||Z(c)){c&&(r=ca(c)||r);var f=r.get(["time","dayOfWeekShort"]);c=f||G(r.get(["time","dayOfWeekAbbr"]),function(C){return C[0]})}var d=l.getNextNDay(i.end.time,7-i.lweek).time,p=[l.getCellWidth(),l.getCellHeight()];h=V(h,Math.min(p[1],p[0])),u==="start"&&(d=l.getNextNDay(i.start.time,-(7+i.fweek)).time,h=-h);for(var g=0;g<7;g++){var y=l.getNextNDay(d,g),m=l.dataToRect([y.time],!1).center,S=g;S=Math.abs((g+v)%7);var x=new tt({z2:30,style:z(ut(s,{text:c[S]}),this._weekTextPositionControl(m,n,u,h,p))});o.add(x)}}},e.type="calendar",e}(at);const Pv=Mv;var lr=864e5,Lv=function(){function a(e,t,r){this.type="calendar",this.dimensions=a.dimensions,this.getDimensionsInfo=a.getDimensionsInfo,this._model=e}return a.getDimensionsInfo=function(){return[{name:"time",type:"time"},"value"]},a.prototype.getRangeInfo=function(){return this._rangeInfo},a.prototype.getModel=function(){return this._model},a.prototype.getRect=function(){return this._rect},a.prototype.getCellWidth=function(){return this._sw},a.prototype.getCellHeight=function(){return this._sh},a.prototype.getOrient=function(){return this._orient},a.prototype.getFirstDayOfWeek=function(){return this._firstDayOfWeek},a.prototype.getDateInfo=function(e){e=Gr(e);var t=e.getFullYear(),r=e.getMonth()+1,i=r<10?"0"+r:""+r,n=e.getDate(),o=n<10?"0"+n:""+n,s=e.getDay();return s=Math.abs((s+7-this.getFirstDayOfWeek())%7),{y:t+"",m:i,d:o,day:s,time:e.getTime(),formatedDate:t+"-"+i+"-"+o,date:e}},a.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))},a.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,i=["width","height"],n=this._model.getCellSize().slice(),o=this._model.getBoxLayoutParams(),s=this._orient==="horizontal"?[r,7]:[7,r];_([0,1],function(h){c(n,h)&&(o[i[h]]=n[h]*s[h])});var l={width:t.getWidth(),height:t.getHeight()},u=this._rect=$t(o,l);_([0,1],function(h){c(n,h)||(n[h]=u[i[h]]/s[h])});function c(h,v){return h[v]!=null&&h[v]!=="auto"}this._sw=n[0],this._sh=n[1]},a.prototype.dataToPoint=function(e,t){U(e)&&(e=e[0]),t==null&&(t=!0);var r=this.getDateInfo(e),i=this._rangeInfo,n=r.formatedDate;if(t&&!(r.time>=i.start.time&&r.time<i.end.time+lr))return[NaN,NaN];var o=r.day,s=this._getRangeInfo([i.start.time,n]).nthWeek;return this._orient==="vertical"?[this._rect.x+o*this._sw+this._sw/2,this._rect.y+s*this._sh+this._sh/2]:[this._rect.x+s*this._sw+this._sw/2,this._rect.y+o*this._sh+this._sh/2]},a.prototype.pointToData=function(e){var t=this.pointToDate(e);return t&&t.time},a.prototype.dataToRect=function(e,t){var r=this.dataToPoint(e,t);return{contentShape:{x:r[0]-(this._sw-this._lineWidth)/2,y:r[1]-(this._sh-this._lineWidth)/2,width:this._sw-this._lineWidth,height:this._sh-this._lineWidth},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]}},a.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,i=this._rangeInfo.range;return this._orient==="vertical"?this._getDateByWeeksAndDay(r,t-1,i):this._getDateByWeeksAndDay(t,r-1,i)},a.prototype.convertToPixel=function(e,t,r){var i=si(t);return i===this?i.dataToPoint(r):null},a.prototype.convertFromPixel=function(e,t,r){var i=si(t);return i===this?i.pointToData(r):null},a.prototype.containPoint=function(e){return!1},a.prototype._initRangeOption=function(){var e=this._model.get("range"),t;if(U(e)&&e.length===1&&(e=e[0]),U(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 i=this.getDateInfo(r),n=i.date;n.setMonth(n.getMonth()+1);var o=this.getNextNDay(n,-1);t=[i.formatedDate,o.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},a.prototype._getRangeInfo=function(e){var t=[this.getDateInfo(e[0]),this.getDateInfo(e[1])],r;t[0].time>t[1].time&&(r=!0,t.reverse());var i=Math.floor(t[1].time/lr)-Math.floor(t[0].time/lr)+1,n=new Date(t[0].time),o=n.getDate(),s=t[1].date.getDate();n.setDate(o+i-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;)i-=u,n.setDate(l-u);var c=Math.floor((i+t[0].day+6)/7),h=r?-c+1:c-1;return r&&t.reverse(),{range:[t[0].formatedDate,t[1].formatedDate],start:t[0],end:t[1],allDay:i,weeks:c,nthWeek:h,fweek:t[0].day,lweek:t[1].day}},a.prototype._getDateByWeeksAndDay=function(e,t,r){var i=this._getRangeInfo(r);if(e>i.weeks||e===0&&t<i.fweek||e===i.weeks&&t>i.lweek)return null;var n=(e-1)*7-i.fweek+t,o=new Date(i.start.time);return o.setDate(+i.start.d+n),this.getDateInfo(o)},a.create=function(e,t){var r=[];return e.eachComponent("calendar",function(i){var n=new a(i);r.push(n),i.coordinateSystem=n}),e.eachSeries(function(i){i.get("coordinateSystem")==="calendar"&&(i.coordinateSystem=r[i.get("calendarIndex")||0])}),r},a.dimensions=["time","value"],a}();function si(a){var e=a.calendarModel,t=a.seriesModel,r=e?e.coordinateSystem:t?t.coordinateSystem:null;return r}const Iv=Lv;function Rv(a){a.registerComponentModel(Dv),a.registerComponentView(Pv),a.registerCoordinateSystem("calendar",Iv)}function Ev(a,e){var t=a.existing;if(e.id=a.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 li(a,e){var t;return _(e,function(r){a[r]!=null&&a[r]!=="auto"&&(t=!0)}),t}function kv(a,e,t){var r=z({},t),i=a[e],n=t.$action||"merge";n==="merge"?i?(ct(i,r,!0),ln(i,r,{ignoreSize:!0}),wl(t,i),De(t,i),De(t,i,"shape"),De(t,i,"style"),De(t,i,"extra"),t.clipPath=i.clipPath):a[e]=r:n==="replace"?a[e]=r:n==="remove"&&i&&(a[e]=null)}var $n=["transition","enterFrom","leaveTo"],Gv=$n.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function De(a,e,t){if(t&&(!a[t]&&e[t]&&(a[t]={}),a=a[t],e=e[t]),!(!a||!e))for(var r=t?$n:Gv,i=0;i<r.length;i++){var n=r[i];a[n]==null&&e[n]!=null&&(a[n]=e[n])}}function zv(a,e){if(a&&(a.hv=e.hv=[li(e,["left","right"]),li(e,["top","bottom"])],a.type==="group")){var t=a,r=e;t.width==null&&(t.width=r.width=0),t.height==null&&(t.height=r.height=0)}}var Vv=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t.preventAutoZ=!0,t}return e.prototype.mergeOption=function(t,r){var i=this.option.elements;this.option.elements=null,a.prototype.mergeOption.call(this,t,r),this.option.elements=i},e.prototype.optionUpdated=function(t,r){var i=this.option,n=(r?i:t).elements,o=i.elements=r?[]:i.elements,s=[];this._flatten(n,s,null);var l=bl(o,s,"normalMerge"),u=this._elOptionsToUpdate=[];_(l,function(c,h){var v=c.newOption;v&&(u.push(v),Ev(c,v),kv(o,h,v),zv(o[h],v))},this),i.elements=Gt(o,function(c){return c&&delete c.$action,c!=null})},e.prototype._flatten=function(t,r,i){_(t,function(n){if(n){i&&(n.parentOption=i),r.push(n);var o=n.children;o&&o.length&&this._flatten(o,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}(K),ui={path:null,compoundPath:null,group:W,image:kt,text:tt},q=xt(),Bv=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(){this._elMap=B()},e.prototype.render=function(t,r,i){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,i)},e.prototype._updateElements=function(t){var r=t.useElOptionsToUpdate();if(r){var i=this._elMap,n=this.group,o=t.get("z"),s=t.get("zlevel");_(r,function(l){var u=Qt(l.id,null),c=u!=null?i.get(u):null,h=Qt(l.parentId,null),v=h!=null?i.get(h):n,f=l.type,d=l.style;f==="text"&&d&&l.hv&&l.hv[1]&&(d.textVerticalAlign=d.textBaseline=d.verticalAlign=d.align=null);var p=l.textContent,g=l.textConfig;if(d&&yh(d,f,!!g,!!p)){var y=mh(d,f,!0);!g&&y.textConfig&&(g=l.textConfig=y.textConfig),!p&&y.textContent&&(p=y.textContent)}var m=Nv(l),S=l.$action||"merge",x=S==="merge",C=S==="replace";if(x){var w=!c,b=c;w?b=ci(u,v,l.type,i):(b&&(q(b).isNew=!1),Lh(b)),b&&(sr(b,m,t,{isInit:w}),hi(b,l,o,s))}else if(C){Pe(c,l,i,t);var A=ci(u,v,l.type,i);A&&(sr(A,m,t,{isInit:!0}),hi(A,l,o,s))}else S==="remove"&&(Fn(c,l),Pe(c,l,i,t));var T=i.get(u);if(T&&p)if(x){var D=T.getTextContent();D?D.attr(p):T.setTextContent(new tt(p))}else C&&T.setTextContent(new tt(p));if(T){var M=l.clipPath;if(M){var R=M.type,P=void 0,w=!1;if(x){var k=T.getClipPath();w=!k||q(k).type!==R,P=w?Ar(R):k}else C&&(w=!0,P=Ar(R));T.setClipPath(P),sr(P,M,t,{isInit:w}),wr(P,M.keyframeAnimation,t)}var N=q(T);T.setTextConfig(g),N.option=l,Fv(T,t,l),$i({el:T,componentModel:t,itemName:T.name,itemTooltipOption:l.tooltip}),wr(T,l.keyframeAnimation,t)}})}},e.prototype._relocate=function(t,r){for(var i=t.option.elements,n=this.group,o=this._elMap,s=r.getWidth(),l=r.getHeight(),u=["x","y"],c=0;c<i.length;c++){var h=i[c],v=Qt(h.id,null),f=v!=null?o.get(v):null;if(!(!f||!f.isGroup)){var d=f.parent,p=d===n,g=q(f),y=q(d);g.width=V(g.option.width,p?s:y.width)||0,g.height=V(g.option.height,p?l:y.height)||0}}for(var c=i.length-1;c>=0;c--){var h=i[c],v=Qt(h.id,null),f=v!=null?o.get(v):null;if(f){var d=f.parent,y=q(d),m=d===n?{width:s,height:l}:{width:y.width,height:y.height},S={},x=Al(f,h,m,null,{hv:h.hv,boundingMode:h.bounding},S);if(!q(f).isNew&&x){for(var C=h.transition,w={},b=0;b<u.length;b++){var A=u[b],T=S[A];C&&(Mt(C)||Xt(C,A)>=0)?w[A]=T:f[A]=T}Pt(f,w,t,0)}else f.attr(S)}}},e.prototype._clear=function(){var t=this,r=this._elMap;r.each(function(i){Pe(i,q(i).option,r,t._lastGraphicModel)}),this._elMap=B()},e.prototype.dispose=function(){this._clear()},e.type="graphic",e}(at);function Ar(a){var e=I(ui,a)?ui[a]:rn(a),t=new e({});return q(t).type=a,t}function ci(a,e,t,r){var i=Ar(t);return e.add(i),r.set(a,i),q(i).id=a,q(i).isNew=!0,i}function Pe(a,e,t,r){var i=a&&a.parent;i&&(a.type==="group"&&a.traverse(function(n){Pe(n,e,t,r)}),xh(a,e,r),t.removeKey(q(a).id))}function hi(a,e,t,r){a.isGroup||_([["cursor",Ie.prototype.cursor],["zlevel",r||0],["z",t||0],["z2",0]],function(i){var n=i[0];I(e,n)?a[n]=gt(e[n],i[1]):a[n]==null&&(a[n]=i[1])}),_(X(e),function(i){if(i.indexOf("on")===0){var n=e[i];a[i]=mt(n)?n:null}}),I(e,"draggable")&&(a.draggable=e.draggable),e.name!=null&&(a.name=e.name),e.id!=null&&(a.id=e.id)}function Nv(a){return a=z({},a),_(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(Tl),function(e){delete a[e]}),a}function Fv(a,e,t){var r=ht(a).eventData;!a.silent&&!a.ignore&&!r&&(r=ht(a).eventData={componentType:"graphic",componentIndex:e.componentIndex,name:a.name}),r&&(r.info=t.info)}function Ov(a){a.registerComponentModel(Vv),a.registerComponentView(Bv),a.registerPreprocessor(function(e){var t=e.graphic;U(t)?!t[0]||!t[0].elements?e.graphic=[{elements:t}]:e.graphic=[e.graphic[0]]:t&&!t.elements&&(e.graphic=[{elements:[t]}])})}var Wv=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t.layoutMode="box",t}return e.prototype.init=function(t,r,i){this.mergeDefaultAndTheme(t,i),this._initData()},e.prototype.mergeOption=function(t){a.prototype.mergeOption.apply(this,arguments),this._initData()},e.prototype.setCurrentIndex=function(t){t==null&&(t=this.option.currentIndex);var r=this._data.count();this.option.loop?t=(t%r+r)%r:(t>=r&&(t=r-1),t<0&&(t=0)),this.option.currentIndex=t},e.prototype.getCurrentIndex=function(){return this.option.currentIndex},e.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},e.prototype.setPlayState=function(t){this.option.autoPlay=!!t},e.prototype.getPlayState=function(){return!!this.option.autoPlay},e.prototype._initData=function(){var t=this.option,r=t.data||[],i=t.axisType,n=this._names=[],o;i==="category"?(o=[],_(r,function(u,c){var h=Qt(Cl(u),""),v;Ht(u)?(v=st(u),v.value=c):v=c,o.push(v),n.push(h)})):o=r;var s={category:"ordinal",time:"time",value:"number"}[i]||"number",l=this._data=new on([{name:"value",type:s}],this);l.initData(o,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:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]},e}(K);const vi=Wv;var Hn=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline.slider",e.defaultOption=Ze(vi.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:"#DAE1F5"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#A4B1D7"},itemStyle:{color:"#A4B1D7",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:15,color:"#316bf3",borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0, 0, 0, 0.3)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"M2,18.5A1.52,1.52,0,0,1,.92,18a1.49,1.49,0,0,1,0-2.12L7.81,9.36,1,3.11A1.5,1.5,0,1,1,3,.89l8,7.34a1.48,1.48,0,0,1,.49,1.09,1.51,1.51,0,0,1-.46,1.1L3,18.08A1.5,1.5,0,0,1,2,18.5Z",prevIcon:"M10,.5A1.52,1.52,0,0,1,11.08,1a1.49,1.49,0,0,1,0,2.12L4.19,9.64,11,15.89a1.5,1.5,0,1,1-2,2.22L1,10.77A1.48,1.48,0,0,1,.5,9.68,1.51,1.51,0,0,1,1,8.58L9,.92A1.5,1.5,0,0,1,10,.5Z",prevBtnSize:18,nextBtnSize:18,color:"#A4B1D7",borderColor:"#A4B1D7",borderWidth:1},emphasis:{label:{show:!0,color:"#6f778d"},itemStyle:{color:"#316BF3"},controlStyle:{color:"#316BF3",borderColor:"#316BF3",borderWidth:2}},progress:{lineStyle:{color:"#316BF3"},itemStyle:{color:"#316BF3"},label:{color:"#6f778d"}},data:[]}),e}(vi);Zt(Hn,Dl.prototype);const Yv=Hn;var Zv=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.type="timeline",e}(at);const $v=Zv;var Hv=function(a){L(e,a);function e(t,r,i,n){var o=a.call(this,t,r,i)||this;return o.type=n||"value",o}return e.prototype.getLabelModel=function(){return this.model.getModel("label")},e.prototype.isHorizontal=function(){return this.model.get("orient")==="horizontal"},e}(lt);const Xv=Hv;var ur=Math.PI,fi=xt(),Uv=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.prototype.init=function(t,r){this.api=r},e.prototype.render=function(t,r,i){if(this.model=t,this.api=i,this.ecModel=r,this.group.removeAll(),t.get("show",!0)){var n=this._layout(t,i),o=this._createGroup("_mainGroup"),s=this._createGroup("_labelGroup"),l=this._axis=this._createAxis(n,t);t.formatTooltip=function(u){var c=l.scale.getLabel({value:u});return ae("nameValue",{noName:!0,value:c})},_(["AxisLine","AxisTick","Control","CurrentPointer"],function(u){this["_render"+u](n,o,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 i=t.get(["label","position"]),n=t.get("orient"),o=Jv(t,r),s;i==null||i==="auto"?s=n==="horizontal"?o.y+o.height/2<r.getHeight()/2?"-":"+":o.x+o.width/2<r.getWidth()/2?"+":"-":Z(i)?s={horizontal:{top:"-",bottom:"+"},vertical:{left:"-",right:"+"}}[n][i]:s=i;var l={horizontal:"center",vertical:s>=0||s==="+"?"left":"right"},u={horizontal:s>=0||s==="+"?"top":"bottom",vertical:"middle"},c={horizontal:0,vertical:ur/2},h=n==="vertical"?o.height:o.width,v=t.getModel("controlStyle"),f=v.get("show",!0),d=f?v.get("itemSize"):0,p=f?v.get("itemGap"):0,g=d+p,y=t.get(["label","rotate"])||0;y=y*ur/180;var m,S,x,C=v.get("position",!0),w=f&&v.get("showPlayBtn",!0),b=f&&v.get("showPrevBtn",!0),A=f&&v.get("showNextBtn",!0),T=0,D=h;C==="left"||C==="bottom"?(w&&(m=[0,0],T+=g),b&&(S=[T,0],T+=g),A&&(x=[D-d,0],D-=g)):(w&&(m=[D-d,0],D-=g),b&&(S=[0,0],T+=g),A&&(x=[D-d,0],D-=g));var M=[T,D];return t.get("inverse")&&M.reverse(),{viewRect:o,mainLength:h,orient:n,rotation:c[n],labelRotation:y,labelPosOpt:s,labelAlign:t.get(["label","align"])||l[n],labelBaseline:t.get(["label","verticalAlign"])||t.get(["label","baseline"])||u[n],playPosition:m,prevBtnPosition:S,nextBtnPosition:x,axisExtent:M,controlSize:d,controlGap:p}},e.prototype._position=function(t,r){var i=this._mainGroup,n=this._labelGroup,o=t.viewRect;if(t.orient==="vertical"){var s=fe(),l=o.x,u=o.y+o.height;ne(s,s,[-l,-u]),Oe(s,s,-ur/2),ne(s,s,[l,u]),o=o.clone(),o.applyTransform(s)}var c=m(o),h=m(i.getBoundingRect()),v=m(n.getBoundingRect()),f=[i.x,i.y],d=[n.x,n.y];d[0]=f[0]=c[0][0];var p=t.labelPosOpt;if(p==null||Z(p)){var g=p==="+"?0:1;S(f,h,c,1,g),S(d,v,c,1,1-g)}else{var g=p>=0?0:1;S(f,h,c,1,g),d[1]=f[1]+p}i.setPosition(f),n.setPosition(d),i.rotation=n.rotation=t.rotation,y(i),y(n);function y(x){x.originX=c[0][0]-x.x,x.originY=c[1][0]-x.y}function m(x){return[[x.x,x.x+x.width],[x.y,x.y+x.height]]}function S(x,C,w,b,A){x[b]+=w[b][A]-C[b][A]}},e.prototype._createAxis=function(t,r){var i=r.getData(),n=r.get("axisType"),o=jv(r,n);o.getTicks=function(){return i.mapArray(["value"],function(u){return{value:u}})};var s=i.getDataExtent("value");o.setExtent(s[0],s[1]),o.calcNiceTicks();var l=new Xv("value",o,t.axisExtent,n);return l.model=r,l},e.prototype._createGroup=function(t){var r=this[t]=new W;return this.group.add(r),r},e.prototype._renderAxisLine=function(t,r,i,n){var o=i.getExtent();if(n.get(["lineStyle","show"])){var s=new dt({shape:{x1:o[0],y1:0,x2:o[1],y2:0},style:z({lineCap:"round"},n.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});r.add(s);var l=this._progressLine=new dt({shape:{x1:o[0],x2:this._currentPointer?this._currentPointer.x:o[0],y1:0,y2:0},style:Y({lineCap:"round",lineWidth:s.style.lineWidth},n.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});r.add(l)}},e.prototype._renderAxisTick=function(t,r,i,n){var o=this,s=n.getData(),l=i.scale.getTicks();this._tickSymbols=[],_(l,function(u){var c=i.dataToCoord(u.value),h=s.getItemModel(u.value),v=h.getModel("itemStyle"),f=h.getModel(["emphasis","itemStyle"]),d=h.getModel(["progress","itemStyle"]),p={x:c,y:0,onclick:E(o._changeTimeline,o,u.value)},g=di(h,v,r,p);g.ensureState("emphasis").style=f.getItemStyle(),g.ensureState("progress").style=d.getItemStyle(),ee(g);var y=ht(g);h.get("tooltip")?(y.dataIndex=u.value,y.dataModel=n):y.dataIndex=y.dataModel=null,o._tickSymbols.push(g)})},e.prototype._renderAxisLabel=function(t,r,i,n){var o=this,s=i.getLabelModel();if(s.get("show")){var l=n.getData(),u=i.getViewLabels();this._tickLabels=[],_(u,function(c){var h=c.tickValue,v=l.getItemModel(h),f=v.getModel("label"),d=v.getModel(["emphasis","label"]),p=v.getModel(["progress","label"]),g=i.dataToCoord(c.tickValue),y=new tt({x:g,y:0,rotation:t.labelRotation-t.rotation,onclick:E(o._changeTimeline,o,h),silent:!1,style:ut(f,{text:c.formattedLabel,align:t.labelAlign,verticalAlign:t.labelBaseline})});y.ensureState("emphasis").style=ut(d),y.ensureState("progress").style=ut(p),r.add(y),ee(y),fi(y).dataIndex=h,o._tickLabels.push(y)})}},e.prototype._renderControl=function(t,r,i,n){var o=t.controlSize,s=t.rotation,l=n.getModel("controlStyle").getItemStyle(),u=n.getModel(["emphasis","controlStyle"]).getItemStyle(),c=n.getPlayState(),h=n.get("inverse",!0);v(t.nextBtnPosition,"next",E(this._changeTimeline,this,h?"-":"+")),v(t.prevBtnPosition,"prev",E(this._changeTimeline,this,h?"+":"-")),v(t.playPosition,c?"stop":"play",E(this._handlePlayClick,this,!c),!0);function v(f,d,p,g){if(f){var y=Ml(gt(n.get(["controlStyle",d+"BtnSize"]),o),o),m=[0,-y/2,y,y],S=qv(n,d+"Icon",m,{x:f[0],y:f[1],originX:o/2,originY:0,rotation:g?-s:0,rectHover:!0,style:l,onclick:p});S.ensureState("emphasis").style=u,r.add(S),ee(S)}}},e.prototype._renderCurrentPointer=function(t,r,i,n){var o=n.getData(),s=n.getCurrentIndex(),l=o.getItemModel(s).getModel("checkpointStyle"),u=this,c={onCreate:function(h){h.draggable=!0,h.drift=E(u._handlePointerDrag,u),h.ondragend=E(u._handlePointerDragend,u),pi(h,u._progressLine,s,i,n,!0)},onUpdate:function(h){pi(h,u._progressLine,s,i,n)}};this._currentPointer=di(l,l,this._mainGroup,{},this._currentPointer,c)},e.prototype._handlePlayClick=function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},e.prototype._handlePointerDrag=function(t,r,i){this._clearTimer(),this._pointerChangeTimeline([i.offsetX,i.offsetY])},e.prototype._handlePointerDragend=function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},e.prototype._pointerChangeTimeline=function(t,r){var i=this._toAxisCoord(t)[0],n=this._axis,o=Dt(n.getExtent().slice());i>o[1]&&(i=o[1]),i<o[0]&&(i=o[0]),this._currentPointer.x=i,this._currentPointer.markRedraw();var s=this._progressLine;s&&(s.shape.x2=i,s.dirty());var l=this._findNearestTick(i),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 le(t,r,!0)},e.prototype._findNearestTick=function(t){var r=this.model.getData(),i=1/0,n,o=this._axis;return r.each(["value"],function(s,l){var u=o.dataToCoord(s),c=Math.abs(u-t);c<i&&(i=c,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,i=this._tickLabels;if(r)for(var n=0;n<r.length;n++)r&&r[n]&&r[n].toggleState("progress",n<t);if(i)for(var n=0;n<i.length;n++)i&&i[n]&&i[n].toggleState("progress",fi(i[n]).dataIndex<=t)},e.type="timeline.slider",e}($v);function jv(a,e){if(e=e||a.get("type"),e)switch(e){case"category":return new Ll({ordinalMeta:a.getCategories(),extent:[1/0,-1/0]});case"time":return new Pl({locale:a.ecModel.getLocaleModel(),useUTC:a.ecModel.get("useUTC")});default:return new yr}}function Jv(a,e){return $t(a.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()},a.get("padding"))}function qv(a,e,t,r){var i=r.style,n=en(a.get(["controlStyle",e]),r||{},new rt(t[0],t[1],t[2],t[3]));return i&&n.setStyle(i),n}function di(a,e,t,r,i,n){var o=e.get("color");if(i)i.setColor(o),t.add(i),n&&n.onUpdate(i);else{var s=a.get("symbol");i=Lt(s,-1,-1,2,2,o),i.setStyle("strokeNoScale",!0),t.add(i),n&&n.onCreate(i)}var l=e.getItemStyle(["color"]);i.setStyle(l),r=ct({rectHover:!0,z2:100},r,!0);var u=ki(a.get("symbolSize"));r.scaleX=u[0]/2,r.scaleY=u[1]/2;var c=Ji(a.get("symbolOffset"),u);c&&(r.x=(r.x||0)+c[0],r.y=(r.y||0)+c[1]);var h=a.get("symbolRotate");return r.rotation=(h||0)*Math.PI/180||0,i.attr(r),i.updateTransform(),i}function pi(a,e,t,r,i,n){if(!a.dragging){var o=i.getModel("checkpointStyle"),s=r.dataToCoord(i.getData().get("value",t));if(n||!o.get("animation",!0))a.attr({x:s,y:0}),e&&e.attr({shape:{x2:s}});else{var l={duration:o.get("animationDuration",!0),easing:o.get("animationEasing",!0)};a.stopAnimation(null,!0),a.animateTo({x:s,y:0},l),e&&e.animateTo({shape:{x2:s}},l)}}}const Kv=Uv;function Qv(a){a.registerAction({type:"timelineChange",event:"timelineChanged",update:"prepareAndUpdate"},function(e,t,r){var i=t.getComponent("timeline");return i&&e.currentIndex!=null&&(i.setCurrentIndex(e.currentIndex),!i.get("loop",!0)&&i.isIndexMax()&&i.getPlayState()&&(i.setPlayState(!1),r.dispatchAction({type:"timelinePlayChange",playState:!1,from:e.from}))),t.resetOption("timeline",{replaceMerge:i.get("replaceMerge",!0)}),Y({currentIndex:i.option.currentIndex},e)}),a.registerAction({type:"timelinePlayChange",event:"timelinePlayChanged",update:"update"},function(e,t){var r=t.getComponent("timeline");r&&e.playState!=null&&r.setPlayState(e.playState)})}function tf(a){var e=a&&a.timeline;U(e)||(e=e?[e]:[]),_(e,function(t){t&&ef(t)})}function ef(a){var e=a.type,t={number:"value",time:"time"};if(t[e]&&(a.axisType=t[e],delete a.type),gi(a),Tt(a,"controlPosition")){var r=a.controlStyle||(a.controlStyle={});Tt(r,"position")||(r.position=a.controlPosition),r.position==="none"&&!Tt(r,"show")&&(r.show=!1,delete r.position),delete a.controlPosition}_(a.data||[],function(i){Ht(i)&&!U(i)&&(!Tt(i,"value")&&Tt(i,"name")&&(i.value=i.name),gi(i))})}function gi(a){var e=a.itemStyle||(a.itemStyle={}),t=e.emphasis||(e.emphasis={}),r=a.label||a.label||{},i=r.normal||(r.normal={}),n={normal:1,emphasis:1};_(r,function(o,s){!n[s]&&!Tt(i,s)&&(i[s]=o)}),t.label&&!Tt(r,"emphasis")&&(r.emphasis=t.label,delete t.label)}function Tt(a,e){return a.hasOwnProperty(e)}function rf(a){a.registerComponentModel(Yv),a.registerComponentView(Kv),a.registerSubTypeDefaulter("timeline",function(){return"slider"}),Qv(a),a.registerPreprocessor(tf)}var af=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.inside",e.defaultOption=Ze(Ee.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),e}(Ee);const nf=af;var $r=xt();function of(a,e,t){$r(a).coordSysRecordMap.each(function(r){var i=r.dataZoomInfoMap.get(e.uid);i&&(i.getRange=t)})}function sf(a,e){for(var t=$r(a).coordSysRecordMap,r=t.keys(),i=0;i<r.length;i++){var n=r[i],o=t.get(n),s=o.dataZoomInfoMap;if(s){var l=e.uid,u=s.get(l);u&&(s.removeKey(l),s.keys().length||Xn(t,o))}}}function Xn(a,e){if(e){a.removeKey(e.model.uid);var t=e.controller;t&&t.dispose()}}function lf(a,e){var t={model:e,containsPoint:Ot(cf,e),dispatchAction:Ot(uf,a),dataZoomInfoMap:null,controller:null},r=t.controller=new yn(a.getZr());return _(["pan","zoom","scrollMove"],function(i){r.on(i,function(n){var o=[];t.dataZoomInfoMap.each(function(s){if(n.isAvailableBehavior(s.model.option)){var l=(s.getRange||{})[i],u=l&&l(s.dzReferCoordSysInfo,t.model.mainType,t.controller,n);!s.model.get("disabled",!0)&&u&&o.push({dataZoomId:s.model.id,start:u[0],end:u[1]})}}),o.length&&t.dispatchAction(o)})}),t}function uf(a,e){a.isDisposed()||a.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:e})}function cf(a,e,t,r){return a.coordinateSystem.containPoint([t,r])}function hf(a){var e,t="type_",r={type_true:2,type_move:1,type_false:0,type_undefined:-1},i=!0;return a.each(function(n){var o=n.model,s=o.get("disabled",!0)?!1:o.get("zoomLock",!0)?"move":!0;r[t+s]>r[t+e]&&(e=s),i=i&&o.get("preventDefaultMouseMove",!0)}),{controlType:e,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!i}}}function vf(a){a.registerProcessor(a.PRIORITY.PROCESSOR.FILTER,function(e,t){var r=$r(t),i=r.coordSysRecordMap||(r.coordSysRecordMap=B());i.each(function(n){n.dataZoomInfoMap=null}),e.eachComponent({mainType:"dataZoom",subType:"inside"},function(n){var o=un(n);_(o.infoList,function(s){var l=s.model.uid,u=i.get(l)||i.set(l,lf(t,s.model)),c=u.dataZoomInfoMap||(u.dataZoomInfoMap=B());c.set(n.uid,{dzReferCoordSysInfo:s,model:n,getRange:null})})}),i.each(function(n){var o=n.controller,s,l=n.dataZoomInfoMap;if(l){var u=l.keys()[0];u!=null&&(s=l.get(u))}if(!s){Xn(i,n);return}var c=hf(l);o.enable(c.controlType,c.opt),o.setPointerChecker(n.containsPoint),Er(n,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var ff=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type="dataZoom.inside",t}return e.prototype.render=function(t,r,i){if(a.prototype.render.apply(this,arguments),t.noTarget()){this._clear();return}this.range=t.getPercentRange(),of(i,t,{pan:E(cr.pan,this),zoom:E(cr.zoom,this),scrollMove:E(cr.scrollMove,this)})},e.prototype.dispose=function(){this._clear(),a.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){sf(this.api,this.dataZoomModel),this.range=null},e.type="dataZoom.inside",e}(cn),cr={zoom:function(a,e,t,r){var i=this.range,n=i.slice(),o=a.axisModels[0];if(o){var s=hr[e](null,[r.originX,r.originY],o,t,a),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 c=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(Ye(0,n,[0,100],0,c.minSpan,c.maxSpan),this.range=n,i[0]!==n[0]||i[1]!==n[1])return n}},pan:yi(function(a,e,t,r,i,n){var o=hr[r]([n.oldX,n.oldY],[n.newX,n.newY],e,i,t);return o.signal*(a[1]-a[0])*o.pixel/o.pixelLength}),scrollMove:yi(function(a,e,t,r,i,n){var o=hr[r]([0,0],[n.scrollDelta,n.scrollDelta],e,i,t);return o.signal*(a[1]-a[0])*n.scrollDelta})};function yi(a){return function(e,t,r,i){var n=this.range,o=n.slice(),s=e.axisModels[0];if(s){var l=a(o,s,e,t,r,i);if(Ye(l,o,[0,100],"all"),this.range=o,n[0]!==o[0]||n[1]!==o[1])return o}}}var hr={grid:function(a,e,t,r,i){var n=t.axis,o={},s=i.model.coordinateSystem.getRect();return a=a||[0,0],n.dim==="x"?(o.pixel=e[0]-a[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=n.inverse?1:-1):(o.pixel=e[1]-a[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=n.inverse?-1:1),o},polar:function(a,e,t,r,i){var n=t.axis,o={},s=i.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return a=a?s.pointToCoord(a):[0,0],e=s.pointToCoord(e),t.mainType==="radiusAxis"?(o.pixel=e[0]-a[0],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=n.inverse?1:-1):(o.pixel=e[1]-a[1],o.pixelLength=u[1]-u[0],o.pixelStart=u[0],o.signal=n.inverse?-1:1),o},singleAxis:function(a,e,t,r,i){var n=t.axis,o=i.model.coordinateSystem.getRect(),s={};return a=a||[0,0],n.orient==="horizontal"?(s.pixel=e[0]-a[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=n.inverse?1:-1):(s.pixel=e[1]-a[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=n.inverse?-1:1),s}};const df=ff;function pf(a){hn(a),a.registerComponentModel(nf),a.registerComponentView(df),vf(a)}var gf=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t}return e.type="dataZoom.slider",e.layoutMode="box",e.defaultOption=Ze(Ee.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},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:"#fff",borderColor:"#ACB8D1"},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:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),e}(Ee);const yf=gf;var qt=et,mi=7,mf=1,vr=30,xf=7,Kt="horizontal",xi="vertical",Sf=5,_f=["line","bar","candlestick","scatter"],bf={easing:"cubicOut",duration:100,delay:0},wf=function(a){L(e,a);function e(){var t=a!==null&&a.apply(this,arguments)||this;return t.type=e.type,t._displayables={},t}return e.prototype.init=function(t,r){this.api=r,this._onBrush=E(this._onBrush,this),this._onBrushEnd=E(this._onBrushEnd,this)},e.prototype.render=function(t,r,i,n){if(a.prototype.render.apply(this,arguments),Er(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(),a.prototype.dispose.apply(this,arguments)},e.prototype._clear=function(){Xi(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 W;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),t.add(r),this._positionGroup()},e.prototype._resetLocation=function(){var t=this.dataZoomModel,r=this.api,i=t.get("brushSelect"),n=i?xf:0,o=this._findCoordRect(),s={width:r.getWidth(),height:r.getHeight()},l=this._orient===Kt?{right:s.width-o.x-o.width,top:s.height-vr-mi-n,width:o.width,height:vr}:{right:mi,top:o.y,width:vr,height:o.height},u=sn(t.option);_(["right","top","width","height"],function(h){u[h]==="ph"&&(u[h]=l[h])});var c=$t(u,s);this._location={x:c.x,y:c.y},this._size=[c.width,c.height],this._orient===xi&&this._size.reverse()},e.prototype._positionGroup=function(){var t=this.group,r=this._location,i=this._orient,n=this.dataZoomModel.getFirstTargetAxisModel(),o=n&&n.get("inverse"),s=this._displayables.sliderGroup,l=(this._dataShadowInfo||{}).otherAxisInverse;s.attr(i===Kt&&!o?{scaleY:l?1:-1,scaleX:1}:i===Kt&&o?{scaleY:l?1:-1,scaleX:-1}:i===xi&&!o?{scaleY:l?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:l?-1:1,scaleX:-1,rotation:Math.PI/2});var u=t.getBoundingRect([s]);t.x=r.x-u.x,t.y=r.y-u.y,t.markRedraw()},e.prototype._getViewExtent=function(){return[0,this._size[0]]},e.prototype._renderBackground=function(){var t=this.dataZoomModel,r=this._size,i=this._displayables.sliderGroup,n=t.get("brushSelect");i.add(new qt({silent:!0,shape:{x:0,y:0,width:r[0],height:r[1]},style:{fill:t.get("backgroundColor")},z2:-40}));var o=new qt({shape:{x:0,y:0,width:r[0],height:r[1]},style:{fill:"transparent"},z2:0,onclick:E(this._onClickPanel,this)}),s=this.api.getZr();n?(o.on("mousedown",this._onBrushStart,this),o.cursor="crosshair",s.on("mousemove",this._onBrush),s.on("mouseup",this._onBrushEnd)):(s.off("mousemove",this._onBrush),s.off("mouseup",this._onBrushEnd)),i.add(o)},e.prototype._renderDataShadow=function(){var t=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!t)return;var r=this._size,i=this._shadowSize||[],n=t.series,o=n.getRawData(),s=n.getShadowDim&&n.getShadowDim(),l=s&&o.getDimensionInfo(s)?n.getShadowDim():t.otherDim;if(l==null)return;var u=this._shadowPolygonPts,c=this._shadowPolylinePts;if(o!==this._shadowData||l!==this._shadowDim||r[0]!==i[0]||r[1]!==i[1]){var h=o.getDataExtent(l),v=(h[1]-h[0])*.3;h=[h[0]-v,h[1]+v];var f=[0,r[1]],d=[0,r[0]],p=[[r[0],0],[0,0]],g=[],y=d[1]/(o.count()-1),m=0,S=Math.round(o.count()/r[0]),x;o.each([l],function(T,D){if(S>0&&D%S){m+=y;return}var M=T==null||isNaN(T)||T==="",R=M?0:it(T,h,f,!0);M&&!x&&D?(p.push([p[p.length-1][0],0]),g.push([g[g.length-1][0],0])):!M&&x&&(p.push([m,0]),g.push([m,0])),p.push([m,R]),g.push([m,R]),m+=y,x=M}),u=this._shadowPolygonPts=p,c=this._shadowPolylinePts=g}this._shadowData=o,this._shadowDim=l,this._shadowSize=[r[0],r[1]];var C=this.dataZoomModel;function w(T){var D=C.getModel(T?"selectedDataBackground":"dataBackground"),M=new W,R=new Yt({shape:{points:u},segmentIgnoreThreshold:1,style:D.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),P=new Et({shape:{points:c},segmentIgnoreThreshold:1,style:D.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return M.add(R),M.add(P),M}for(var b=0;b<3;b++){var A=w(b===1);this._displayables.sliderGroup.add(A),this._displayables.dataShadowSegs.push(A)}},e.prototype._prepareDataShadowInfo=function(){var t=this.dataZoomModel,r=t.get("showDataShadow");if(r!==!1){var i,n=this.ecModel;return t.eachTargetAxis(function(o,s){var l=t.getAxisProxy(o,s).getTargetSeriesModels();_(l,function(u){if(!i&&!(r!==!0&&Xt(_f,u.get("type"))<0)){var c=n.getComponent(Il(o),s).axis,h=Af(o),v,f=u.coordinateSystem;h!=null&&f.getOtherAxis&&(v=f.getOtherAxis(c).inverse),h=u.getData().mapDimension(h),i={thisAxis:c,series:u,thisDim:o,otherDim:h,otherAxisInverse:v}}},this)},this),i}},e.prototype._renderHandle=function(){var t=this.group,r=this._displayables,i=r.handles=[null,null],n=r.handleLabels=[null,null],o=this._displayables.sliderGroup,s=this._size,l=this.dataZoomModel,u=this.api,c=l.get("borderRadius")||0,h=l.get("brushSelect"),v=r.filler=new qt({silent:h,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});o.add(v),o.add(new qt({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:s[0],height:s[1],r:c},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:mf,fill:"rgba(0,0,0,0)"}})),_([0,1],function(S){var x=l.get("handleIcon");!Rl[x]&&x.indexOf("path://")<0&&x.indexOf("image://")<0&&(x="path://"+x);var C=Lt(x,-1,0,2,2,null,!0);C.attr({cursor:Si(this._orient),draggable:!0,drift:E(this._onDragMove,this,S),ondragend:E(this._onDragEnd,this),onmouseover:E(this._showDataInfo,this,!0),onmouseout:E(this._showDataInfo,this,!1),z2:5});var w=C.getBoundingRect(),b=l.get("handleSize");this._handleHeight=V(b,this._size[1]),this._handleWidth=w.width/w.height*this._handleHeight,C.setStyle(l.getModel("handleStyle").getItemStyle()),C.style.strokeNoScale=!0,C.rectHover=!0,C.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),ee(C);var A=l.get("handleColor");A!=null&&(C.style.fill=A),o.add(i[S]=C);var T=l.getModel("textStyle");t.add(n[S]=new tt({silent:!0,invisible:!0,style:ut(T,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:T.getTextColor(),font:T.getFont()}),z2:10}))},this);var f=v;if(h){var d=V(l.get("moveHandleSize"),s[1]),p=r.moveHandle=new et({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:s[1]-.5,height:d}}),g=d*.8,y=r.moveHandleIcon=Lt(l.get("moveHandleIcon"),-g/2,-g/2,g,g,"#fff",!0);y.silent=!0,y.y=s[1]+d/2-.5,p.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var m=Math.min(s[1]/2,Math.max(d,10));f=r.moveZone=new et({invisible:!0,shape:{y:s[1]-m,height:d+m}}),f.on("mouseover",function(){u.enterEmphasis(p)}).on("mouseout",function(){u.leaveEmphasis(p)}),o.add(p),o.add(y),o.add(f)}f.attr({draggable:!0,cursor:Si(this._orient),drift:E(this._onDragMove,this,"all"),ondragstart:E(this._showDataInfo,this,!0),ondragend:E(this._onDragEnd,this),onmouseover:E(this._showDataInfo,this,!0),onmouseout:E(this._showDataInfo,this,!1)})},e.prototype._resetInterval=function(){var t=this._range=this.dataZoomModel.getPercentRange(),r=this._getViewExtent();this._handleEnds=[it(t[0],[0,100],r,!0),it(t[1],[0,100],r,!0)]},e.prototype._updateInterval=function(t,r){var i=this.dataZoomModel,n=this._handleEnds,o=this._getViewExtent(),s=i.findRepresentativeAxisProxy().getMinMaxSpan(),l=[0,100];Ye(r,n,o,i.get("zoomLock")?"all":t,s.minSpan!=null?it(s.minSpan,l,o,!0):null,s.maxSpan!=null?it(s.maxSpan,l,o,!0):null);var u=this._range,c=this._range=Dt([it(n[0],o,l,!0),it(n[1],o,l,!0)]);return!u||u[0]!==c[0]||u[1]!==c[1]},e.prototype._updateView=function(t){var r=this._displayables,i=this._handleEnds,n=Dt(i.slice()),o=this._size;_([0,1],function(f){var d=r.handles[f],p=this._handleHeight;d.attr({scaleX:p/2,scaleY:p/2,x:i[f]+(f?-1:1),y:o[1]/2-p/2})},this),r.filler.setShape({x:n[0],y:0,width:n[1]-n[0],height:o[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],o[0]],c=0;c<l.length;c++){var h=l[c],v=h.getClipPath();v||(v=new et,h.setClipPath(v)),v.setShape({x:u[c],y:0,width:u[c+1]-u[c],height:o[1]})}this._updateDataInfo(t)},e.prototype._updateDataInfo=function(t){var r=this.dataZoomModel,i=this._displayables,n=i.handleLabels,o=this._orient,s=["",""];if(r.get("showDetail")){var l=r.findRepresentativeAxisProxy();if(l){var u=l.getAxisModel().axis,c=this._range,h=t?l.calculateDataWindow({start:c[0],end:c[1]}).valueWindow:l.getDataValueWindow();s=[this._formatLabel(h[0],u),this._formatLabel(h[1],u)]}}var v=Dt(this._handleEnds.slice());f.call(this,0),f.call(this,1);function f(d){var p=an(i.handles[d].parent,this.group),g=El(d===0?"right":"left",p),y=this._handleWidth/2+Sf,m=le([v[d]+(d===0?-y:y),this._size[1]/2],p);n[d].setStyle({x:m[0],y:m[1],verticalAlign:o===Kt?"middle":g,align:o===Kt?g:"center",text:s[d]})}},e.prototype._formatLabel=function(t,r){var i=this.dataZoomModel,n=i.get("labelFormatter"),o=i.get("labelPrecision");(o==null||o==="auto")&&(o=r.getPixelPrecision());var s=t==null||isNaN(t)?"":r.type==="category"||r.type==="time"?r.scale.getLabel({value:Math.round(t)}):t.toFixed(Math.min(o,20));return mt(n)?n(t,s):Z(n)?n.replace("{value}",s):s},e.prototype._showDataInfo=function(t){t=this._dragging||t;var r=this._displayables,i=r.handleLabels;i[0].attr("invisible",!t),i[1].attr("invisible",!t),r.moveHandle&&this.api[t?"enterEmphasis":"leaveEmphasis"](r.moveHandle,1)},e.prototype._onDragMove=function(t,r,i,n){this._dragging=!0,Le(n.event);var o=this._displayables.sliderGroup.getLocalTransform(),s=le([r,i],o,!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._showDataInfo(!1);var t=this.dataZoomModel.get("realtime");!t&&this._dispatchZoomAction(!1)},e.prototype._onClickPanel=function(t){var r=this._size,i=this._displayables.sliderGroup.transformCoordToLocal(t.offsetX,t.offsetY);if(!(i[0]<0||i[0]>r[0]||i[1]<0||i[1]>r[1])){var n=this._handleEnds,o=(n[0]+n[1])/2,s=this._updateInterval("all",i[0]-o);this._updateView(),s&&this._dispatchZoomAction(!1)}},e.prototype._onBrushStart=function(t){var r=t.offsetX,i=t.offsetY;this._brushStart=new kl(r,i),this._brushing=!0,this._brushStartTime=+new Date},e.prototype._onBrushEnd=function(t){if(this._brushing){var r=this._displayables.brushRect;if(this._brushing=!1,!!r){r.attr("ignore",!0);var i=r.shape,n=+new Date;if(!(n-this._brushStartTime<200&&Math.abs(i.width)<5)){var o=this._getViewExtent(),s=[0,100];this._range=Dt([it(i.x,o,s,!0),it(i.x+i.width,o,s,!0)]),this._handleEnds=[i.x,i.x+i.width],this._updateView(),this._dispatchZoomAction(!1)}}}},e.prototype._onBrush=function(t){this._brushing&&(Le(t.event),this._updateBrushRect(t.offsetX,t.offsetY))},e.prototype._updateBrushRect=function(t,r){var i=this._displayables,n=this.dataZoomModel,o=i.brushRect;o||(o=i.brushRect=new qt({silent:!0,style:n.getModel("brushStyle").getItemStyle()}),i.sliderGroup.add(o)),o.attr("ignore",!1);var s=this._brushStart,l=this._displayables.sliderGroup,u=l.transformCoordToLocal(t,r),c=l.transformCoordToLocal(s.x,s.y),h=this._size;u[0]=Math.max(Math.min(h[0],u[0]),0),o.setShape({x:c[0],y:0,width:u[0]-c[0],height:h[1]})},e.prototype._dispatchZoomAction=function(t){var r=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:t?bf:null,start:r[0],end:r[1]})},e.prototype._findCoordRect=function(){var t,r=un(this.dataZoomModel).infoList;if(!t&&r.length){var i=r[0].model.coordinateSystem;t=i.getRect&&i.getRect()}if(!t){var n=this.api.getWidth(),o=this.api.getHeight();t={x:n*.2,y:o*.2,width:n*.6,height:o*.6}}return t},e.type="dataZoom.slider",e}(cn);function Af(a){var e={x:"y",y:"x",radius:"angle",angle:"radius"};return e[a]}function Si(a){return a==="vertical"?"ns-resize":"ew-resize"}const Tf=wf;function Cf(a){a.registerComponentModel(yf),a.registerComponentView(Tf),hn(a)}function Df(a){Rt(pf),Rt(Cf)}var Mf={label:{enabled:!0},decal:{show:!1}},_i=xt(),Pf={};function Lf(a,e){var t=a.getModel("aria");if(!t.get("enabled"))return;var r=st(Mf);ct(r.label,a.getLocaleModel().get("aria"),!1),ct(t.option,r,!1),i(),n();function i(){var u=t.getModel("decal"),c=u.get("show");if(c){var h=B();a.eachSeries(function(v){if(!v.isColorBySeries()){var f=h.get(v.type);f||(f={},h.set(v.type,f)),_i(v).scope=f}}),a.eachRawSeries(function(v){if(a.isSeriesFiltered(v))return;if(mt(v.enableAriaDecal)){v.enableAriaDecal();return}var f=v.getData();if(v.isColorBySeries()){var m=ha(v.ecModel,v.name,Pf,a.getSeriesCount()),S=f.getVisual("decal");f.setVisual("decal",x(S,m))}else{var d=v.getRawData(),p={},g=_i(v).scope;f.each(function(C){var w=f.getRawIndex(C);p[w]=C});var y=d.count();d.each(function(C){var w=p[C],b=d.getName(C)||C+"",A=ha(v.ecModel,b,g,y),T=f.getItemVisual(w,"decal");f.setItemVisual(w,"decal",x(T,A))})}function x(C,w){var b=C?z(z({},w),C):w;return b.dirty=!0,b}})}}function n(){var u=a.getLocaleModel().get("aria"),c=t.getModel("label");if(c.option=Y(c.option,u),!!c.get("enabled")){var h=e.getZr().dom;if(c.get("description")){h.setAttribute("aria-label",c.get("description"));return}var v=a.getSeriesCount(),f=c.get(["data","maxCount"])||10,d=c.get(["series","maxCount"])||10,p=Math.min(v,d),g;if(!(v<1)){var y=s();if(y){var m=c.get(["general","withTitle"]);g=o(m,{title:y})}else g=c.get(["general","withoutTitle"]);var S=[],x=v>1?c.get(["series","multiple","prefix"]):c.get(["series","single","prefix"]);g+=o(x,{seriesCount:v}),a.eachSeries(function(A,T){if(T<p){var D=void 0,M=A.get("name"),R=M?"withName":"withoutName";D=v>1?c.get(["series","multiple",R]):c.get(["series","single",R]),D=o(D,{seriesId:A.seriesIndex,seriesName:A.get("name"),seriesType:l(A.subType)});var P=A.getData();if(P.count()>f){var k=c.get(["data","partialData"]);D+=o(k,{displayCnt:f})}else D+=c.get(["data","allData"]);for(var N=c.get(["data","separator","middle"]),F=c.get(["data","separator","end"]),O=[],$=0;$<P.count();$++)if($<f){var St=P.getName($),ft=P.getValues($),Ut=c.get(["data",St?"withName":"withoutName"]);O.push(o(Ut,{name:St,value:ft.join(N)}))}D+=O.join(N)+F,S.push(D)}});var C=c.getModel(["series","multiple","separator"]),w=C.get("middle"),b=C.get("end");g+=S.join(w)+b,h.setAttribute("aria-label",g)}}}function o(u,c){if(!Z(u))return u;var h=u;return _(c,function(v,f){h=h.replace(new RegExp("\\{\\s*"+f+"\\s*\\}","g"),v)}),h}function s(){var u=a.get("title");return u&&u.length&&(u=u[0]),u&&u.text}function l(u){return a.getLocaleModel().get(["series","typeNames"])[u]||"\u81EA\u5B9A\u4E49\u56FE"}}function If(a){if(!(!a||!a.aria)){var e=a.aria;e.show!=null&&(e.enabled=e.show),e.label=e.label||{},_(["description","general","series","data"],function(t){e[t]!=null&&(e.label[t]=e[t])})}}function Rf(a){a.registerPreprocessor(If),a.registerVisual(a.PRIORITY.VISUAL.ARIA,Lf)}var fr=Math.sin,dr=Math.cos,Un=Math.PI,bt=Math.PI*2,Ef=180/Un,kf=function(){function a(){}return a.prototype.reset=function(e){this._start=!0,this._d=[],this._str="",this._p=Math.pow(10,e||4)},a.prototype.moveTo=function(e,t){this._add("M",e,t)},a.prototype.lineTo=function(e,t){this._add("L",e,t)},a.prototype.bezierCurveTo=function(e,t,r,i,n,o){this._add("C",e,t,r,i,n,o)},a.prototype.quadraticCurveTo=function(e,t,r,i){this._add("Q",e,t,r,i)},a.prototype.arc=function(e,t,r,i,n,o){this.ellipse(e,t,r,r,0,i,n,o)},a.prototype.ellipse=function(e,t,r,i,n,o,s,l){var u=s-o,c=!l,h=Math.abs(u),v=pt(h-bt)||(c?u>=bt:-u>=bt),f=u>0?u%bt:u%bt+bt,d=!1;v?d=!0:pt(h)?d=!1:d=f>=Un==!!c;var p=e+r*dr(o),g=t+i*fr(o);this._start&&this._add("M",p,g);var y=Math.round(n*Ef);if(v){var m=1/this._p,S=(c?1:-1)*(bt-m);this._add("A",r,i,y,1,+c,e+r*dr(o+S),t+i*fr(o+S)),m>.01&&this._add("A",r,i,y,0,+c,p,g)}else{var x=e+r*dr(s),C=t+i*fr(s);this._add("A",r,i,y,+d,+c,x,C)}},a.prototype.rect=function(e,t,r,i){this._add("M",e,t),this._add("l",r,0),this._add("l",0,i),this._add("l",-r,0),this._add("Z")},a.prototype.closePath=function(){this._d.length>0&&this._add("Z")},a.prototype._add=function(e,t,r,i,n,o,s,l,u){for(var c=[],h=this._p,v=1;v<arguments.length;v++){var f=arguments[v];if(isNaN(f)){this._invalid=!0;return}c.push(Math.round(f*h)/h)}this._d.push(e+c.join(" ")),this._start=e==="Z"},a.prototype.generateStr=function(){this._str=this._invalid?"":this._d.join(""),this._d=[]},a.prototype.getStr=function(){return this._str},a}();const jn=kf;var re="none",Gf=Math.round;function zf(a){var e=a.fill;return e!=null&&e!==re}function Vf(a){var e=a.stroke;return e!=null&&e!==re}var Tr=["lineCap","miterLimit","lineJoin"],Bf=G(Tr,function(a){return"stroke-"+a.toLowerCase()});function Nf(a,e,t,r){var i=e.opacity==null?1:e.opacity;if(t instanceof kt){a("opacity",i);return}if(zf(e)){var n=ce(e.fill);a("fill",n.color);var o=e.fillOpacity!=null?e.fillOpacity*n.opacity*i:n.opacity*i;(r||o<1)&&a("fill-opacity",o)}else a("fill",re);if(Vf(e)){var s=ce(e.stroke);a("stroke",s.color);var l=e.strokeNoScale?t.getLineScale():1,u=l?(e.lineWidth||0)/l:0,c=e.strokeOpacity!=null?e.strokeOpacity*s.opacity*i:s.opacity*i,h=e.strokeFirst;if((r||u!==1)&&a("stroke-width",u),(r||h)&&a("paint-order",h?"stroke":"fill"),(r||c<1)&&a("stroke-opacity",c),e.lineDash){var v=Gl(t),f=v[0],d=v[1];f&&(d=Gf(d||0),a("stroke-dasharray",f.join(",")),(d||r)&&a("stroke-dashoffset",d))}else r&&a("stroke-dasharray",re);for(var p=0;p<Tr.length;p++){var g=Tr[p];if(r||e[g]!==va[g]){var y=e[g]||va[g];y&&a(Bf[p],y)}}}else r&&a("stroke",re)}var Jn="http://www.w3.org/2000/svg",qn="http://www.w3.org/1999/xlink",Ff="http://www.w3.org/2000/xmlns/",Of="http://www.w3.org/XML/1998/namespace";function Kn(a){return document.createElementNS(Jn,a)}function H(a,e,t,r,i){return{tag:a,attrs:t||{},children:r,text:i,key:e}}function Wf(a,e){var t=[];if(e)for(var r in e){var i=e[r],n=r;i!==!1&&(i!==!0&&i!=null&&(n+='="'+i+'"'),t.push(n))}return"<"+a+" "+t.join(" ")+">"}function Yf(a){return"</"+a+">"}function Hr(a,e){e=e||{};var t=e.newline?`
|
|
`:"";function r(i){var n=i.children,o=i.tag,s=i.attrs,l=i.text;return Wf(o,s)+(o!=="style"?nn(l):l||"")+(n?""+t+G(n,function(u){return r(u)}).join(t)+t:"")+Yf(o)}return r(a)}function Zf(a,e,t){t=t||{};var r=t.newline?`
|
|
`:"",i=" {"+r,n=r+"}",o=G(X(a),function(l){return l+i+G(X(a[l]),function(u){return u+":"+a[l][u]+";"}).join(r)+n}).join(r),s=G(X(e),function(l){return"@keyframes "+l+i+G(X(e[l]),function(u){return u+i+G(X(e[l][u]),function(c){var h=e[l][u][c];return c==="d"&&(h='path("'+h+'")'),c+":"+h+";"}).join(r)+n}).join(r)+n}).join(r);return!o&&!s?"":["<![CDATA[",o,s,"]]>"].join(r)}function Cr(a){return{zrId:a,shadowCache:{},patternCache:{},gradientCache:{},clipPathCache:{},defs:{},cssNodes:{},cssAnims:{},cssClassIdx:0,cssAnimIdx:0,shadowIdx:0,gradientIdx:0,patternIdx:0,clipPathIdx:0}}function bi(a,e,t,r){return H("svg","root",{width:a,height:e,xmlns:Jn,"xmlns:xlink":qn,version:"1.1",baseProfile:"full",viewBox:r?"0 0 "+a+" "+e:!1},t)}var wi={cubicIn:"0.32,0,0.67,0",cubicOut:"0.33,1,0.68,1",cubicInOut:"0.65,0,0.35,1",quadraticIn:"0.11,0,0.5,0",quadraticOut:"0.5,1,0.89,1",quadraticInOut:"0.45,0,0.55,1",quarticIn:"0.5,0,0.75,0",quarticOut:"0.25,1,0.5,1",quarticInOut:"0.76,0,0.24,1",quinticIn:"0.64,0,0.78,0",quinticOut:"0.22,1,0.36,1",quinticInOut:"0.83,0,0.17,1",sinusoidalIn:"0.12,0,0.39,0",sinusoidalOut:"0.61,1,0.88,1",sinusoidalInOut:"0.37,0,0.63,1",exponentialIn:"0.7,0,0.84,0",exponentialOut:"0.16,1,0.3,1",exponentialInOut:"0.87,0,0.13,1",circularIn:"0.55,0,1,0.45",circularOut:"0,0.55,0.45,1",circularInOut:"0.85,0,0.15,1"},At="transform-origin";function $f(a,e,t){var r=z({},a.shape);z(r,e),a.buildPath(t,r);var i=new jn;return i.reset(fn(a)),t.rebuildPath(i,1),i.generateStr(),i.getStr()}function Hf(a,e){var t=e.originX,r=e.originY;(t||r)&&(a[At]=t+"px "+r+"px")}var Xf={fill:"fill",opacity:"opacity",lineWidth:"stroke-width",lineDashOffset:"stroke-dashoffset"};function Qn(a,e){var t=e.zrId+"-ani-"+e.cssAnimIdx++;return e.cssAnims[t]=a,t}function Uf(a,e,t){var r=a.shape.paths,i={},n,o;if(_(r,function(l){var u=Cr(t.zrId);u.animation=!0,Xe(l,{},u,!0);var c=u.cssAnims,h=u.cssNodes,v=X(c),f=v.length;if(f){o=v[f-1];var d=c[o];for(var p in d){var g=d[p];i[p]=i[p]||{d:""},i[p].d+=g.d||""}for(var y in h){var m=h[y].animation;m.indexOf(o)>=0&&(n=m)}}}),!!n){e.d=!1;var s=Qn(i,t);return n.replace(o,s)}}function Ai(a){return Z(a)?wi[a]?"cubic-bezier("+wi[a]+")":zl(a)?a:"":""}function Xe(a,e,t,r){var i=a.animators,n=i.length,o=[];if(a instanceof Ir){var s=Uf(a,e,t);if(s)o.push(s);else if(!n)return}else if(!n)return;for(var l={},u=0;u<n;u++){var c=i[u],h=[c.getMaxTime()/1e3+"s"],v=Ai(c.getClip().easing),f=c.getDelay();v?h.push(v):h.push("linear"),f&&h.push(f/1e3+"s"),c.getLoop()&&h.push("infinite");var d=h.join(" ");l[d]=l[d]||[d,[]],l[d][1].push(c)}function p(m){var S=m[1],x=S.length,C={},w={},b={},A="animation-timing-function";function T(pe,ge,Kr){for(var ye=pe.getTracks(),co=pe.getMaxTime(),je=0;je<ye.length;je++){var Je=ye[je];if(Je.needsAnimate()){var Qr=Je.keyframes,me=Je.propName;if(Kr&&(me=Kr(me)),me)for(var qe=0;qe<Qr.length;qe++){var xe=Qr[qe],Se=Math.round(xe.time/co*100)+"%",ta=Ai(xe.easing),ea=xe.rawValue;(Z(ea)||zi(ea))&&(ge[Se]=ge[Se]||{},ge[Se][me]=xe.rawValue,ta&&(ge[Se][A]=ta))}}}}for(var D=0;D<x;D++){var M=S[D],R=M.targetName;R?R==="shape"&&T(M,w):!r&&T(M,C)}for(var P in C){var k={};Vl(k,a),z(k,C[P]);var N=vn(k),F=C[P][A];b[P]=N?{transform:N}:{},Hf(b[P],k),F&&(b[P][A]=F)}var O,$=!0;for(var P in w){b[P]=b[P]||{};var St=!O,F=w[P][A];St&&(O=new Bl);var ft=O.len();O.reset(),b[P].d=$f(a,w[P],O);var Ut=O.len();if(!St&&ft!==Ut){$=!1;break}F&&(b[P][A]=F)}if(!$)for(var P in b)delete b[P].d;if(!r)for(var D=0;D<x;D++){var M=S[D],R=M.targetName;R==="style"&&T(M,b,function(ye){return Xf[ye]})}for(var de=X(b),Jr=!0,Ue,D=1;D<de.length;D++){var qr=de[D-1],lo=de[D];if(b[qr][At]!==b[lo][At]){Jr=!1;break}Ue=b[qr][At]}if(Jr&&Ue){for(var P in b)b[P][At]&&delete b[P][At];e[At]=Ue}if(Gt(de,function(pe){return X(b[pe]).length>0}).length){var uo=Qn(b,t);return uo+" "+m[0]+" both"}}for(var g in l){var s=p(l[g]);s&&o.push(s)}if(o.length){var y=t.zrId+"-cls-"+t.cssClassIdx++;t.cssNodes["."+y]={animation:o.join(",")},e.class=y}}var he=Math.round;function to(a){return a&&Z(a.src)}function eo(a){return a&&mt(a.toDataURL)}function Xr(a,e,t,r){Nf(function(i,n){var o=i==="fill"||i==="stroke";o&&dn(n)?ao(e,a,i,r):o&&Br(n)?io(t,a,i,r):a[i]=n},e,t,!1),ed(t,a,r)}function Ti(a){return pt(a[0]-1)&&pt(a[1])&&pt(a[2])&&pt(a[3]-1)}function jf(a){return pt(a[4])&&pt(a[5])}function Ur(a,e,t){if(e&&!(jf(e)&&Ti(e))){var r=t?10:1e4;a.transform=Ti(e)?"translate("+he(e[4]*r)/r+" "+he(e[5]*r)/r+")":ql(e)}}function Ci(a,e,t){for(var r=a.points,i=[],n=0;n<r.length;n++)i.push(he(r[n][0]*t)/t),i.push(he(r[n][1]*t)/t);e.points=i.join(" ")}function Di(a){return!a.smooth}function Jf(a){var e=G(a,function(t){return typeof t=="string"?[t,t]:t});return function(t,r,i){for(var n=0;n<e.length;n++){var o=e[n],s=t[o[0]];s!=null&&(r[o[1]]=he(s*i)/i)}}}var qf={circle:[Jf(["cx","cy","r"])],polyline:[Ci,Di],polygon:[Ci,Di]};function Kf(a){for(var e=a.animators,t=0;t<e.length;t++)if(e[t].targetName==="shape")return!0;return!1}function ro(a,e){var t=a.style,r=a.shape,i=qf[a.type],n={},o=e.animation,s="path",l=a.style.strokePercent,u=e.compress&&fn(a)||4;if(i&&!e.willUpdate&&!(i[1]&&!i[1](r))&&!(o&&Kf(a))&&!(l<1)){s=a.type;var c=Math.pow(10,u);i[0](r,n,c)}else{var h=!a.path||a.shapeChanged();a.path||a.createPathProxy();var v=a.path;h&&(v.beginPath(),a.buildPath(v,a.shape),a.pathUpdated());var f=v.getVersion(),d=a,p=d.__svgPathBuilder;(d.__svgPathVersion!==f||!p||l!==d.__svgPathStrokePercent)&&(p||(p=d.__svgPathBuilder=new jn),p.reset(u),v.rebuildPath(p,l),p.generateStr(),d.__svgPathVersion=f,d.__svgPathStrokePercent=l),n.d=p.getStr()}return Ur(n,a.transform),Xr(n,t,a,e),e.animation&&Xe(a,n,e),H(s,a.id+"",n)}function Qf(a,e){var t=a.style,r=t.image;if(r&&!Z(r)&&(to(r)?r=r.src:eo(r)&&(r=r.toDataURL())),!!r){var i=t.x||0,n=t.y||0,o=t.width,s=t.height,l={href:r,width:o,height:s};return i&&(l.x=i),n&&(l.y=n),Ur(l,a.transform),Xr(l,t,a,e),e.animation&&Xe(a,l,e),H("image",a.id+"",l)}}function td(a,e){var t=a.style,r=t.text;if(r!=null&&(r+=""),!(!r||isNaN(t.x)||isNaN(t.y))){var i=t.font||Zl,n=t.x||0,o=$l(t.y||0,Hl(i),t.textBaseline),s=Xl[t.textAlign]||t.textAlign,l={"dominant-baseline":"central","text-anchor":s};if(Ul(t)){var u="",c=t.fontStyle,h=jl(t.fontSize);if(!parseFloat(h))return;var v=t.fontFamily||Jl,f=t.fontWeight;u+="font-size:"+h+";font-family:"+v+";",c&&c!=="normal"&&(u+="font-style:"+c+";"),f&&f!=="normal"&&(u+="font-weight:"+f+";"),l.style=u}else l.style="font: "+i;return r.match(/\s/)&&(l["xml:space"]="preserve"),n&&(l.x=n),o&&(l.y=o),Ur(l,a.transform),Xr(l,t,a,e),e.animation&&Xe(a,l,e),H("text",a.id+"",l,void 0,r)}}function Mi(a,e){if(a instanceof Ki)return ro(a,e);if(a instanceof kt)return Qf(a,e);if(a instanceof Vi)return td(a,e)}function ed(a,e,t){var r=a.style;if(Kl(r)){var i=Ql(a),n=t.shadowCache,o=n[i];if(!o){var s=a.getGlobalScale(),l=s[0],u=s[1];if(!l||!u)return;var c=r.shadowOffsetX||0,h=r.shadowOffsetY||0,v=r.shadowBlur,f=ce(r.shadowColor),d=f.opacity,p=f.color,g=v/2/l,y=v/2/u,m=g+" "+y;o=t.zrId+"-s"+t.shadowIdx++,t.defs[o]=H("filter",o,{id:o,x:"-100%",y:"-100%",width:"300%",height:"300%"},[H("feDropShadow","",{dx:c/l,dy:h/u,stdDeviation:m,"flood-color":p,"flood-opacity":d})]),n[i]=o}e.filter=$e(o)}}function ao(a,e,t,r){var i=a[t],n,o={gradientUnits:i.global?"userSpaceOnUse":"objectBoundingBox"};if(Nl(i))n="linearGradient",o.x1=i.x,o.y1=i.y,o.x2=i.x2,o.y2=i.y2;else if(Fl(i))n="radialGradient",o.cx=gt(i.x,.5),o.cy=gt(i.y,.5),o.r=gt(i.r,.5);else return;for(var s=i.colorStops,l=[],u=0,c=s.length;u<c;++u){var h=Ol(s[u].offset)*100+"%",v=s[u].color,f=ce(v),d=f.color,p=f.opacity,g={offset:h};g["stop-color"]=d,p<1&&(g["stop-opacity"]=p),l.push(H("stop",u+"",g))}var y=H(n,"",o,l),m=Hr(y),S=r.gradientCache,x=S[m];x||(x=r.zrId+"-g"+r.gradientIdx++,S[m]=x,o.id=x,r.defs[x]=H(n,x,o,l)),e[t]=$e(x)}function io(a,e,t,r){var i=a.style[t],n=a.getBoundingRect(),o={},s=i.repeat,l=s==="no-repeat",u=s==="repeat-x",c=s==="repeat-y",h;if(Wl(i)){var v=i.imageWidth,f=i.imageHeight,d=void 0,p=i.image;if(Z(p)?d=p:to(p)?d=p.src:eo(p)&&(d=p.toDataURL()),typeof Image=="undefined"){var g="Image width/height must been given explictly in svg-ssr renderer.";xr(v,g),xr(f,g)}else if(v==null||f==null){var y=function(D,M){if(D){var R=D.elm,P=v||M.width,k=f||M.height;D.tag==="pattern"&&(u?(k=1,P/=n.width):c&&(P=1,k/=n.height)),D.attrs.width=P,D.attrs.height=k,R&&(R.setAttribute("width",P),R.setAttribute("height",k))}},m=Yl(d,null,a,function(D){l||y(w,D),y(h,D)});m&&m.width&&m.height&&(v=v||m.width,f=f||m.height)}h=H("image","img",{href:d,width:v,height:f}),o.width=v,o.height=f}else i.svgElement&&(h=st(i.svgElement),o.width=i.svgWidth,o.height=i.svgHeight);if(h){var S,x;l?S=x=1:u?(x=1,S=o.width/n.width):c?(S=1,x=o.height/n.height):o.patternUnits="userSpaceOnUse",S!=null&&!isNaN(S)&&(o.width=S),x!=null&&!isNaN(x)&&(o.height=x);var C=vn(i);C&&(o.patternTransform=C);var w=H("pattern","",o,[h]),b=Hr(w),A=r.patternCache,T=A[b];T||(T=r.zrId+"-p"+r.patternIdx++,A[b]=T,o.id=T,w=r.defs[T]=H("pattern",T,o,[h])),e[t]=$e(T)}}function rd(a,e,t){var r=t.clipPathCache,i=t.defs,n=r[a.id];if(!n){n=t.zrId+"-c"+t.clipPathIdx++;var o={id:n};r[a.id]=n,i[n]=H("clipPath",n,o,[ro(a,t)])}e["clip-path"]=$e(n)}function Pi(a){return document.createTextNode(a)}function Ct(a,e,t){a.insertBefore(e,t)}function Li(a,e){a.removeChild(e)}function Ii(a,e){a.appendChild(e)}function no(a){return a.parentNode}function oo(a){return a.nextSibling}function pr(a,e){a.textContent=e}var Ri=58,ad=120,id=H("","");function Dr(a){return a===void 0}function ot(a){return a!==void 0}function nd(a,e,t){for(var r={},i=e;i<=t;++i){var n=a[i].key;n!==void 0&&(r[n]=i)}return r}function te(a,e){var t=a.key===e.key,r=a.tag===e.tag;return r&&t}function ve(a){var e,t=a.children,r=a.tag;if(ot(r)){var i=a.elm=Kn(r);if(jr(id,a),U(t))for(e=0;e<t.length;++e){var n=t[e];n!=null&&Ii(i,ve(n))}else ot(a.text)&&!Ht(a.text)&&Ii(i,Pi(a.text))}else a.elm=Pi(a.text);return a.elm}function so(a,e,t,r,i){for(;r<=i;++r){var n=t[r];n!=null&&Ct(a,ve(n),e)}}function Ve(a,e,t,r){for(;t<=r;++t){var i=e[t];if(i!=null)if(ot(i.tag)){var n=no(i.elm);Li(n,i.elm)}else Li(a,i.elm)}}function jr(a,e){var t,r=e.elm,i=a&&a.attrs||{},n=e.attrs||{};if(i!==n){for(t in n){var o=n[t],s=i[t];s!==o&&(o===!0?r.setAttribute(t,""):o===!1?r.removeAttribute(t):t.charCodeAt(0)!==ad?r.setAttribute(t,o):t==="xmlns:xlink"||t==="xmlns"?r.setAttributeNS(Ff,t,o):t.charCodeAt(3)===Ri?r.setAttributeNS(Of,t,o):t.charCodeAt(5)===Ri?r.setAttributeNS(qn,t,o):r.setAttribute(t,o))}for(t in i)t in n||r.removeAttribute(t)}}function od(a,e,t){for(var r=0,i=0,n=e.length-1,o=e[0],s=e[n],l=t.length-1,u=t[0],c=t[l],h,v,f,d;r<=n&&i<=l;)o==null?o=e[++r]:s==null?s=e[--n]:u==null?u=t[++i]:c==null?c=t[--l]:te(o,u)?(Vt(o,u),o=e[++r],u=t[++i]):te(s,c)?(Vt(s,c),s=e[--n],c=t[--l]):te(o,c)?(Vt(o,c),Ct(a,o.elm,oo(s.elm)),o=e[++r],c=t[--l]):te(s,u)?(Vt(s,u),Ct(a,s.elm,o.elm),s=e[--n],u=t[++i]):(Dr(h)&&(h=nd(e,r,n)),v=h[u.key],Dr(v)?Ct(a,ve(u),o.elm):(f=e[v],f.tag!==u.tag?Ct(a,ve(u),o.elm):(Vt(f,u),e[v]=void 0,Ct(a,f.elm,o.elm))),u=t[++i]);(r<=n||i<=l)&&(r>n?(d=t[l+1]==null?null:t[l+1].elm,so(a,d,t,i,l)):Ve(a,e,r,n))}function Vt(a,e){var t=e.elm=a.elm,r=a.children,i=e.children;a!==e&&(jr(a,e),Dr(e.text)?ot(r)&&ot(i)?r!==i&&od(t,r,i):ot(i)?(ot(a.text)&&pr(t,""),so(t,null,i,0,i.length-1)):ot(r)?Ve(t,r,0,r.length-1):ot(a.text)&&pr(t,""):a.text!==e.text&&(ot(r)&&Ve(t,r,0,r.length-1),pr(t,e.text)))}function sd(a,e){if(te(a,e))Vt(a,e);else{var t=a.elm,r=no(t);ve(e),r!==null&&(Ct(r,e.elm,oo(t)),Ve(r,[a],0,0))}return e}var ld=0,ud=function(){function a(e,t,r){if(this.type="svg",this.refreshHover=Ei(),this.configLayer=Ei(),this.storage=t,this._opts=r=z({},r),this.root=e,this._id="zr"+ld++,this._oldVNode=bi(r.width,r.height),e&&!r.ssr){var i=this._viewport=document.createElement("div");i.style.cssText="position:relative;overflow:hidden";var n=this._svgDom=this._oldVNode.elm=Kn("svg");jr(null,this._oldVNode),i.appendChild(n),e.appendChild(i)}this.resize(r.width,r.height)}return a.prototype.getType=function(){return this.type},a.prototype.getViewportRoot=function(){return this._viewport},a.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},a.prototype.getSvgDom=function(){return this._svgDom},a.prototype.refresh=function(){if(this.root){var e=this.renderToVNode({willUpdate:!0});e.attrs.style="position:absolute;left:0;top:0;user-select:none",sd(this._oldVNode,e),this._oldVNode=e}},a.prototype.renderOneToVNode=function(e){return Mi(e,Cr(this._id))},a.prototype.renderToVNode=function(e){e=e||{};var t=this.storage.getDisplayList(!0),r=this._width,i=this._height,n=Cr(this._id);n.animation=e.animation,n.willUpdate=e.willUpdate,n.compress=e.compress;var o=[],s=this._bgVNode=cd(r,i,this._backgroundColor,n);s&&o.push(s);var l=e.compress?null:this._mainVNode=H("g","main",{},[]);this._paintList(t,n,l?l.children:o),l&&o.push(l);var u=G(X(n.defs),function(v){return n.defs[v]});if(u.length&&o.push(H("defs","defs",{},u)),e.animation){var c=Zf(n.cssNodes,n.cssAnims,{newline:!0});if(c){var h=H("style","stl",{},[],c);o.push(h)}}return bi(r,i,o,e.useViewBox)},a.prototype.renderToString=function(e){return e=e||{},Hr(this.renderToVNode({animation:gt(e.cssAnimation,!0),willUpdate:!1,compress:!0,useViewBox:gt(e.useViewBox,!0)}),{newline:!0})},a.prototype.setBackgroundColor=function(e){this._backgroundColor=e},a.prototype.getSvgRoot=function(){return this._mainVNode&&this._mainVNode.elm},a.prototype._paintList=function(e,t,r){for(var i=e.length,n=[],o=0,s,l,u=0,c=0;c<i;c++){var h=e[c];if(!h.invisible){var v=h.__clipPaths,f=v&&v.length||0,d=l&&l.length||0,p=void 0;for(p=Math.max(f-1,d-1);p>=0&&!(v&&l&&v[p]===l[p]);p--);for(var g=d-1;g>p;g--)o--,s=n[o-1];for(var y=p+1;y<f;y++){var m={};rd(v[y],m,t);var S=H("g","clip-g-"+u++,m,[]);(s?s.children:r).push(S),n[o++]=S,s=S}l=v;var x=Mi(h,t);x&&(s?s.children:r).push(x)}}},a.prototype.resize=function(e,t){var r=this._opts,i=this.root,n=this._viewport;if(e!=null&&(r.width=e),t!=null&&(r.height=t),i&&n&&(n.style.display="none",e=fa(i,0,r),t=fa(i,1,r),n.style.display=""),this._width!==e||this._height!==t){if(this._width=e,this._height=t,n){var o=n.style;o.width=e+"px",o.height=t+"px"}if(Br(this._backgroundColor))this.refresh();else{var s=this._svgDom;s&&(s.setAttribute("width",e),s.setAttribute("height",t));var l=this._bgVNode&&this._bgVNode.elm;l&&(l.setAttribute("width",e),l.setAttribute("height",t))}}},a.prototype.getWidth=function(){return this._width},a.prototype.getHeight=function(){return this._height},a.prototype.dispose=function(){this.root&&(this.root.innerHTML=""),this._svgDom=this._viewport=this.storage=this._oldVNode=this._bgVNode=this._mainVNode=null},a.prototype.clear=function(){this._svgDom&&(this._svgDom.innerHTML=null),this._oldVNode=null},a.prototype.toDataURL=function(e){var t=this.renderToString(),r="data:image/svg+xml;";return e?(t=tu(t),t&&r+"base64,"+t):r+"charset=UTF-8,"+encodeURIComponent(t)},a}();function Ei(a){return function(){}}function cd(a,e,t,r){var i;if(t&&t!=="none")if(i=H("rect","bg",{width:a,height:e,x:"0",y:"0",id:"0"}),dn(t))ao({fill:t},i.attrs,"fill",r);else if(Br(t))io({style:{fill:t},dirty:eu,getBoundingRect:function(){return{width:a,height:e}}},i.attrs,"fill",r);else{var n=ce(t),o=n.color,s=n.opacity;i.attrs.fill=o,s<1&&(i.attrs["fill-opacity"]=s)}return i}const hd=ud;function vd(a){a.registerPainter("svg",hd)}Rt([ru,au,iu,nu,Tv,Rf,ah,ou,su,lu,Dc,Du,vd,gh,pn,uu,Df,cu,rf,Rv,Ov]);export{dd as default};
|