1import{a7 as ge,J as Jt,f as Ve,aF as mt,aG as sr,_ as z,G as j,q as ee,E as Ne,O as ss,aH as Mn,a4 as Vn,P as xe,R as Ae,n as Ie,b as le,Z as Me,g as G,aI as us,p as Le,I as He,at as kn,l as Q,aB as vs,h as $,d as Xe,B as Bt,aJ as an,c as Ct,am as xt,a as pa,aK as cs,K as hs,N as fs,j as ke,aL as mo,aq as Na,ar as Fr,H as Nt,i as rn,aM as On,ai as gs,aN as ps,ak as ds,aa as So,an as bo,aO as ys,m as Za,aP as Ma,U as st,a2 as nn,W as ms,aQ as Ss,V as Xt,aR as Gn,aS as Hr,aT as bs,aU as _e,a0 as ws,a6 as wo,aV as _s,aA as Ea,o as Ds,aW as xs,a5 as As,aX as Bn,aY as Is,aZ as Ls,av as zn,a_ as _a,a$ as Cs,C as Ts}from"./graphic-ZmnE5KkR.js";import{c as et}from"./createSeriesData-C5DxIQA0.js";import{aY as Wr,R as zt,aZ as Qt,f as Ke,a_ as Z,ag as se,i as ea,a0 as ue,a$ as Zt,U as je,b0 as Fn,b1 as ce,j as ne,b2 as ie,b3 as Hn,ah as ae,b4 as Va,b5 as Ce,b6 as De,b7 as Ps,b8 as _o,a6 as J,b9 as Es,P as on,ba as Wn,bb as Ur,bc as da,bd as Do,be as ln,bf as sn,bg as Rs,bh as Je,bi as Pt,y as U,bj as St,bk as ta,bl as Un,bm as Ns,bn as xo,bo as qa,bp as ut,bq as Oe,br as Ao,bs as We,aM as Ms,bt as Io,bu as Ft,bv as Vs,bw as un,bx as ks,by as he,bz as Lo,u as Pe,bA as Co,aN as Ka,bB as Os,bC as Ge,Q as vn,bD as ja,bE as To,K as Po,bF as ya,bG as Ja,aT as cn,aL as Mt,M as ht,bH as Gs,bI as ka,J as Bs,bJ as Oa,bK as Ht,k as Wt,bL as aa,bM as zs,bN as Yn,bO as Fs,a as $e,l as $n,bP as Qa,bQ as Eo,bR as Xn,bS as Da,bT as Zn,bU as Hs,aU as Ro,bV as Ws,bW as Us,bX as Ys,O as qn,bY as $s,bZ as Kn,b_ as Xs,w as Zs,b$ as No,c0 as Mo,c1 as Yr,m as Vo,aV as $r,aS as qs,c2 as ko,c3 as Ks,z as ur,c4 as js,c5 as Ra,c6 as vr,c7 as Oo,c8 as jn,c9 as Go,r as Js,aQ as Qs,ca as Bo,t as Jn,cb as Qn,cc as eu,a2 as ei,_ as ti,cd as tu}from"./Axis-DWfTEwfx.js";import{c as ze,S as er,a as tr,i as Ga,g as zo,b as ra,d as au,e as ru,r as nu,m as ar,C as na,f as hn,h as Et,j as ma,k as iu,s as ou,l as lu,n as su,o as Ba,p as ai,M as uu,q as za,t as vu,u as Fo,v as cu,w as hu,R as rr,x as fn,y as Ho,z as Vt,V as kt,A as Wo,B as gn,D as Uo,E as pn,F as fu,G as Yo,H as $o,L as Xo,I as ri,J as gu,K as ni,N as pu,O as du,P as yu,Q as bt,T as Zo,U as qo,W as ii,X as ia,Y as mu,Z as dn,_ as oi,$ as Su,a0 as bu,a1 as wu,a2 as _u,a3 as Du}from"./customGraphicKeyframeAnimation-CVDGM9J6.js";function Ko(r,t,e,a,n,i,o,l){var s=n-r,u=i-t,v=e-r,c=a-t,h=Math.sqrt(v*v+c*c);v/=h,c/=h;var f=s*v+u*c,g=f/h;g*=h;var p=o[0]=r+g*v,d=o[1]=t+g*c;return Math.sqrt((p-n)*(p-n)+(d-i)*(d-i))}var it=new ge,oe=new ge,ye=new ge,ot=new ge,Be=new ge,Fa=[],Se=new ge;function xu(r,t){if(t<=180&&t>0){t=t/180*Math.PI,it.fromArray(r[0]),oe.fromArray(r[1]),ye.fromArray(r[2]),ge.sub(ot,it,oe),ge.sub(Be,ye,oe);var e=ot.len(),a=Be.len();if(!(e<.001||a<.001)){ot.scale(1/e),Be.scale(1/a);var n=ot.dot(Be),i=Math.cos(t);if(i<n){var o=Ko(oe.x,oe.y,ye.x,ye.y,it.x,it.y,Fa);Se.fromArray(Fa),Se.scaleAndAdd(Be,o/Math.tan(Math.PI-t));var l=ye.x!==oe.x?(Se.x-oe.x)/(ye.x-oe.x):(Se.y-oe.y)/(ye.y-oe.y);if(isNaN(l))return;l<0?ge.copy(Se,oe):l>1&&ge.copy(Se,ye),Se.toArray(r[1])}}}}function Au(r,t,e){if(e<=180&&e>0){e=e/180*Math.PI,it.fromArray(r[0]),oe.fromArray(r[1]),ye.fromArray(r[2]),ge.sub(ot,oe,it),ge.sub(Be,ye,oe);var a=ot.len(),n=Be.len();if(!(a<.001||n<.001)){ot.scale(1/a),Be.scale(1/n);var i=ot.dot(t),o=Math.cos(e);if(i<o){var l=Ko(oe.x,oe.y,ye.x,ye.y,it.x,it.y,Fa);Se.fromArray(Fa);var s=Math.PI/2,u=Math.acos(Be.dot(t)),v=s+u-e;if(v>=s)ge.copy(Se,ye);else{Se.scaleAndAdd(Be,l/Math.tan(Math.PI/2-v));var c=ye.x!==oe.x?(Se.x-oe.x)/(ye.x-oe.x):(Se.y-oe.y)/(ye.y-oe.y);if(isNaN(c))return;c<0?ge.copy(Se,oe):c>1&&ge.copy(Se,ye)}Se.toArray(r[1])}}}}function cr(r,t,e,a){var n=e==="normal",i=n?r:r.ensureState(e);i.ignore=t;var o=a.get("smooth");o=o===!0?.3:Math.max(+o,0)||0,i.shape=i.shape||{},i.shape.smooth=o;var l=a.getModel("lineStyle").getLineStyle();n?r.useStyle(l):i.style=l}function Iu(r,t){var e=t.smooth,a=t.points;if(a)if(r.moveTo(a[0][0],a[0][1]),e>0&&a.length>=3){var n=mt(a[0],a[1]),i=mt(a[1],a[2]);if(!n||!i){r.lineTo(a[1][0],a[1][1]),r.lineTo(a[2][0],a[2][1]);return}var o=Math.min(n,i)*e,l=sr([],a[1],a[0],o/n),s=sr([],a[1],a[2],o/i),u=sr([],l,s,.5);r.bezierCurveTo(l[0],l[1],l[0],l[1],u[0],u[1]),r.bezierCurveTo(s[0],s[1],s[0],s[1],a[2][0],a[2][1])}else for(var v=1;v<a.length;v++)r.lineTo(a[v][0],a[v][1])}function jo(r,t,e){var a=r.getTextGuideLine(),n=r.getTextContent();if(!n){a&&r.removeTextGuideLine();return}for(var i=t.normal,o=i.get("show"),l=n.ignore,s=0;s<Wr.length;s++){var u=Wr[s],v=t[u],c=u==="normal";if(v){var h=v.get("show"),f=c?l:Jt(n.states[u]&&n.states[u].ignore,l);if(f||!Jt(h,o)){var g=c?a:a&&a.states[u];g&&(g.ignore=!0),a&&cr(a,!0,u,v);continue}
1a||(a=new zt,r.setTextGuideLine(a),!c&&(l||!o)&&cr(a,!0,"normal",t.normal),r.stateProxy&&(a.stateProxy=r.stateProxy)),cr(a,!1,u,v)}}if(a){Ve(a.style,e),a.style.fill=null;var p=i.get("showAbove"),d=r.textGuideLineConfig=r.textGuideLineConfig||{};d.showAbove=p||!1,a.buildPath=Iu}}function Jo(r,t){t=t||"labelLine";for(var e={normal:r.getModel(t)},a=0;a<Qt.length;a++){var n=Qt[a];e[n]=r.getModel([n,t])}return e}var Lu=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e}return t.prototype.getInitialData=function(e){return et(null,this,{useEncodeDefaulter:!0})},t.prototype.getLegendIcon=function(e){var a=new j,n=Ke("line",0,e.itemHeight/2,e.itemWidth,0,e.lineStyle.stroke,!1);a.add(n),n.setStyle(e.lineStyle);var i=this.getData().getVisual("symbol"),o=this.getData().getVisual("symbolRotate"),l=i==="none"?"circle":i,s=e.itemHeight*.8,u=Ke(l,(e.itemWidth-s)/2,(e.itemHeight-s)/2,s,s,e.itemStyle.fill);a.add(u),u.setStyle(e.itemStyle);var v=e.iconRotate==="inherit"?o:e.iconRotate||0;return u.rotation=v*Math.PI/180,u.setOrigin([e.itemWidth/2,e.itemHeight/2]),l.indexOf("empty")>-1&&(u.style.stroke=u.style.fill,u.style.fill=Z.color.neutral00,u.style.lineWidth=2),a},t.type="series.line",t.dependencies=["grid","polar"],t.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:6,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1,triggerEvent:!1},t}(se);function Qo(r,t,e){var a=r.getBaseAxis(),n=r.getOtherAxis(a),i=Cu(n,e),o=a.dim,l=n.dim,s=t.mapDimension(l),u=t.mapDimension(o),v=l==="x"||l==="radius"?1:0,c=ee(r.dimensions,function(g){return t.mapDimension(g)}),h=!1,f=t.getCalculationInfo("stackResultDimension");return ea(t,c[0])&&(h=!0,c[0]=f),ea(t,c[1])&&(h=!0,c[1]=f),{dataDimsForPoint:c,valueStart:i,valueAxisDim:l,baseAxisDim:o,stacked:!!h,valueDim:s,baseDim:u,baseDataOffset:v,stackedOverDimension:t.getCalculationInfo("stackedOverDimension")}}function Cu(r,t){var e=0,a=r.scale.getExtent();return t==="start"?e=a[0]:t==="end"?e=a[1]:Ne(t)&&!isNaN(t)?e=t:a[0]>0?e=a[0]:a[1]<0&&(e=a[1]),e}function el(r,t,e,a){var n=NaN;r.stacked&&(n=e.get(e.getCalculationInfo("stackedOverDimension"),a)),isNaN(n)&&(n=r.valueStart);var i=r.baseDataOffset,o=[];return o[i]=e.get(r.baseDim,a),o[1-i]=n,t.dataToPoint(o)}function Ee(r,t){return!isFinite(r)||!isFinite(t)}function Tu(r,t){var e=[];return t.diff(r).add(function(a){e.push({cmd:"+",idx:a})}).update(function(a,n){e.push({cmd:"=",idx:n,idx1:a})}).remove(function(a){e.push({cmd:"-",idx:a})}).execute(),e}function Pu(r,t,e,a,n,i,o,l){for(var s=Tu(r,t),u=[],v=[],c=[],h=[],f=[],g=[],p=[],d=Qo(n,t,o),m=r.getLayout("points")||[],y=t.getLayout("points")||[],S=0;S<s.length;S++){var b=s[S],w=!0,_=void 0,D=void 0;switch(b.cmd){case"=":_=b.idx*2,D=b.idx1*2;var A=m[_],P=m[_+1],I=y[D],x=y[D+1];(isNaN(A)||isNaN(P))&&(A=I,P=x),u.push(A,P),v.push(I,x),c.push(e[_],e[_+1]),h.push(a[D],a[D+1]),p.push(t.getRawIndex(b.idx1));break;case"+":var L=b.idx,E=d.dataDimsForPoint,V=n.dataToPoint([t.get(E[0],L),t.get(E[1],L)]);D=L*2,u.push(V[0],V[1]),v.push(y[D],y[D+1]);var T=el(d,n,t,L);c.push(T[0],T[1]),h.push(a[D],a[D+1]),p.push(t.getRawIndex(L));break;case"-":w=!1}w&&(f.push(b),g.push(g.length))}g.sort(function(X,ve){return p[X]-p[ve]});for(var R=u.length,N=ze(R),C=ze(R),M=ze(R),k=ze(R),O=[],S=0;S<g.length;S++){var B=g[S],W=S*2,H=B*2;N[W]=u[H],N[W+1]=u[H+1],C[W]=v[H],C[W+1]=v[H+1],M[W]=c[H],M[W+1]=c[H+1],k[W]=h[H],k[W+1]=h[H+1],O[S]=f[B]}return{current:N,next:C,stackedOnCurrent:M,stackedOnNext:k,status:O}}var at=Math.min,rt=Math.max;function Xr(r,t,e,a,n,i,o,l,s){for(var u,v,c,h,f,g,p=e,d=0;d<a;d++){var m=t[p*2],y=t[p*2+1];if(p>=n||p<0)break;if(Ee(m,y)){if(s){p+=i;continue}break}if(p===e)r[i>0?"moveTo":"lineTo"](m,y),c=m,h=y;else{var S=m-u,b=y-v;if(S*S+b*b<.5){p+=i;continue}if(o>0){for(var w=p+i,_=t[w*2],D=t[w*2+1];_===m&&D===y&&d<a;)d++,w+=i,p+=i,_=t[w*2],D=t[w*2+1],m=t[p*2],y=t[p*2+1],S=m-u,b=y-v;var A=d+1;if(s)for(;Ee(_,D)&&A<a;)A++,w+=i,_=t[w*2],D=t[w*2+1];var P=.5,I=0,x=0,L=void 0,E=void 0;if(A>=a||Ee(_,D))f=m,g=y;else{I=_-u,x=D-v;var V=m-u,T=_-m,R=y-v,N=D-y,C=void 0,M=void 0;if(l==="x"){C=Math.abs(V),M=Math.abs(T);var k=I>0?1:-1;f=m-k*C*o,g=y,L=m+k*M*o,E=y}else if(l==="y"){C=Math.abs(R),M=Math.abs(N);var O=x>0?1:-1;f=m,g=y-O*C*o,L=m,E=y+O*M*o}else C=Math.sqrt(V*V+R*R),M=Math.sqrt(T*T+N*N),P=M/(M+C),f=m-I*o*(1-P),g=y-x*o*(1-P),L=m+I*o*P,
1E=y+x*o*P,L=at(L,rt(_,m)),E=at(E,rt(D,y)),L=rt(L,at(_,m)),E=rt(E,at(D,y)),I=L-m,x=E-y,f=m-I*C/M,g=y-x*C/M,f=at(f,rt(u,m)),g=at(g,rt(v,y)),f=rt(f,at(u,m)),g=rt(g,at(v,y)),I=m-f,x=y-g,L=m+I*M/C,E=y+x*M/C}r.bezierCurveTo(c,h,f,g,m,y),c=L,h=E}else r.lineTo(m,y)}u=m,v=y,p+=i}return d}var tl=function(){function r(){this.smooth=0,this.smoothConstraint=!0}return r}(),Eu=function(r){z(t,r);function t(e){var a=r.call(this,e)||this;return a.type="ec-polyline",a}return t.prototype.getDefaultStyle=function(){return{stroke:Z.color.neutral99,fill:null}},t.prototype.getDefaultShape=function(){return new tl},t.prototype.buildPath=function(e,a){var n=a.points,i=0,o=n.length/2;if(a.connectNulls){for(;o>0&&Ee(n[o*2-2],n[o*2-1]);o--);for(;i<o&&Ee(n[i*2],n[i*2+1]);i++);}for(;i<o;)i+=Xr(e,n,i,o,o,1,a.smooth,a.smoothMonotone,a.connectNulls)+1},t.prototype.getPointOn=function(e,a){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var n=this.path,i=n.data,o=ss.CMD,l,s,u=a==="x",v=[],c=0;c<i.length;){var h=i[c++],f=void 0,g=void 0,p=void 0,d=void 0,m=void 0,y=void 0,S=void 0;switch(h){case o.M:l=i[c++],s=i[c++];break;case o.L:if(f=i[c++],g=i[c++],S=u?(e-l)/(f-l):(e-s)/(g-s),S<=1&&S>=0){var b=u?(g-s)*S+s:(f-l)*S+l;return u?[e,b]:[b,e]}l=f,s=g;break;case o.C:f=i[c++],g=i[c++],p=i[c++],d=i[c++],m=i[c++],y=i[c++];var w=u?Mn(l,f,p,m,e,v):Mn(s,g,d,y,e,v);if(w>0)for(var _=0;_<w;_++){var D=v[_];if(D<=1&&D>=0){var b=u?Vn(s,g,d,y,D):Vn(l,f,p,m,D);return u?[e,b]:[b,e]}}l=m,s=y;break}}},t}(xe),Ru=function(r){z(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t}(tl),al=function(r){z(t,r);function t(e){var a=r.call(this,e)||this;return a.type="ec-polygon",a}return t.prototype.getDefaultShape=function(){return new Ru},t.prototype.buildPath=function(e,a){var n=a.points,i=a.stackedOnPoints,o=0,l=n.length/2,s=a.smoothMonotone;if(a.connectNulls){for(;l>0&&Ee(n[l*2-2],n[l*2-1]);l--);for(;o<l&&Ee(n[o*2],n[o*2+1]);o++);}for(;o<l;){var u=Xr(e,n,o,l,l,1,a.smooth,s,a.connectNulls);Xr(e,i,o+u-1,u,l,-1,a.stackedOnSmooth,s,a.connectNulls),o+=u+1,e.closePath()}},t}(xe);function rl(r,t,e,a,n){var i=r.getArea(),o=i.x,l=i.y,s=i.width,u=i.height,v=e.get(["lineStyle","width"])||0;o-=v/2,l-=v/2,s+=v,u+=v,s=Math.ceil(s),o!==Math.floor(o)&&(o=Math.floor(o),s++);var c=new Ae({shape:{x:o,y:l,width:s,height:u}});if(t){var h=r.getBaseAxis(),f=h.isHorizontal(),g=h.inverse;f?(g&&(c.shape.x+=s),c.shape.width=0):(g||(c.shape.y+=u),c.shape.height=0);var p=Ie(n)?function(d){n(d,c)}:null;ue(c,{shape:{width:s,height:u,x:o,y:l}},e,null,a,p)}return c}function nl(r,t,e){var a=r.getArea(),n=Zt(a.r0,1),i=Zt(a.r,1),o=new je({shape:{cx:Zt(r.cx,1),cy:Zt(r.cy,1),r0:n,r:i,startAngle:a.startAngle,endAngle:a.endAngle,clockwise:a.clockwise}});if(t){var l=r.getBaseAxis().dim==="angle";l?o.shape.endAngle=a.startAngle:o.shape.r=n,ue(o,{shape:{endAngle:a.endAngle,r:i}},e)}return o}function wt(r,t,e,a,n){if(r){if(r.type==="polar")return nl(r,t,e);if(r.type==="cartesian2d")return rl(r,t,e,a,n)}else return null;return null}var oa=0,la=1,sa=2;function Tt(r,t,e){r?t.setClipPath(e):t.removeClipPath()}function il(r){var t=r.coordinateSystem;if(r.get("clip",!0)&&t&&(!t.shouldClip||t.shouldClip()))return t.getArea&&t.getArea(.1)}function li(r,t){if(r.length===t.length){for(var e=0;e<r.length;e++)if(r[e]!==t[e])return;return!0}}function si(r){for(var t=Ur(),e=Ur(),a=0;a<r.length;){var n=r[a++],i=r[a++];Ee(n,i)||(Wn(t,n),Wn(e,i))}return[t,e]}function ui(r,t){var e=si(r),a=e[0],n=e[1],i=si(t),o=i[0],l=i[1];return Math.max(Math.abs(a[0]-o[0]),Math.abs(n[0]-l[0]),Math.abs(a[1]-o[1]),Math.abs(n[1]-l[1]))}function vi(r){return Ne(r)?r:r?.5:0}function Nu(r,t,e){if(e.valueDim==null)return[];for(var a=t.count(),n=ze(a*2),i=0;i<a;i++){var o=el(e,r,t,i);n[i*2]=o[0],n[i*2+1]=o[1]}return n}function nt(r,t,e,a,n){var i=e.getBaseAxis(),o=i.dim==="x"||i.dim==="radius"?0:1,l=[],s=0,u=[],v=[],c=[],h=[];if(n){for(s=0;s<r.length;s+=2){var f=t||r;Ee(f[s],f[s+1])||h.push(r[s],r[s+1])}r=h}for(s=0;s<r.length-2;s+=2)switch(c[0]=r[s+2],c[1]=r[s+3],v[0]=r[s],v[1]=r[s+1],l.push(v[0],v[1]),a){case"end":u[o]=c[o],u[1-o]=v[1-o],l.push(u[0],u[1]);break;case"middle":var g=(v[o]+c[o])/2,p=[];u[o]=p[o]=g,u[1-o]=v[1-o],p[1-o]=c[1-o],l.push(u[0],u[1]),l.push(p[
10],p[1]);break;default:u[o]=v[o],u[1-o]=c[1-o],l.push(u[0],u[1])}return l.push(r[s++],r[s++]),l}function Mu(r,t){var e=[],a=r.length,n,i;function o(v,c,h){var f=v.coord,g=(h-f)/(c.coord-f),p=us(g,[v.color,c.color]);return{coord:h,color:p}}for(var l=0;l<a;l++){var s=r[l],u=s.coord;if(u<0)n=s;else if(u>t){i?e.push(o(i,s,t)):n&&e.push(o(n,s,0),o(n,s,t));break}else n&&(e.push(o(n,s,0)),n=null),e.push(s),i=s}return e}function Vu(r,t,e){var a=r.getVisual("visualMeta");if(!(!a||!a.length||!r.count())&&t.type==="cartesian2d"){for(var n,i,o=a.length-1;o>=0;o--){var l=r.getDimensionInfo(a[o].dimension);if(n=l&&l.coordDim,n==="x"||n==="y"){i=a[o];break}}if(i){var s=t.getAxis(n),u=ee(i.stops,function(S){return{coord:s.toGlobalCoord(s.dataToCoord(S.value)),color:S.color}}),v=u.length,c=i.outerColors.slice();v&&u[0].coord>u[v-1].coord&&(u.reverse(),c.reverse());var h=Mu(u,n==="x"?e.getWidth():e.getHeight()),f=h.length;if(!f&&v)return u[0].coord<0?c[1]?c[1]:u[v-1].color:c[0]?c[0]:u[0].color;var g=10,p=h[0].coord-g,d=h[f-1].coord+g,m=d-p;if(m<.001)return"transparent";G(h,function(S){S.offset=(S.coord-p)/m}),h.push({offset:f?h[f-1].offset:.5,color:c[1]||"transparent"}),h.unshift({offset:f?h[0].offset:.5,color:c[0]||"transparent"});var y=new on(0,0,0,0,h,!0);return y[n]=p,y[n+"2"]=d,y}}}function ku(r,t,e){var a=r.get("showAllSymbol"),n=a==="auto";if(!(a&&!n)){var i=e.getAxesByScale("ordinal")[0];if(i&&!(n&&Ou(i,t))){var o=t.mapDimension(i.dim),l={};return G(i.getViewLabels(),function(s){s.tick.offInterval||(l[Es(i.scale,s.tick)]=1)}),function(s){return!l.hasOwnProperty(t.get(o,s))}}}}function Ou(r,t){var e=r.getExtent(),a=Math.abs(e[1]-e[0])/r.scale.count();isNaN(a)&&(a=0);for(var n=t.count(),i=Math.max(1,Math.round(n/5)),o=0;o<n;o+=i)if(tr.getSymbolSize(t,o)[r.isHorizontal()?1:0]*1.5>a)return!1;return!0}function Gu(r){for(var t=r.length/2;t>0&&Ee(r[t*2-2],r[t*2-1]);t--);return t-1}function ci(r,t){return[r[t*2],r[t*2+1]]}function Bu(r,t,e){for(var a=r.length/2,n=e==="x"?0:1,i,o,l=0,s=-1,u=0;u<a;u++)if(o=r[u*2+n],!Ee(o,r[u*2+1-n])){if(u===0){i=o;continue}if(i<=t&&o>=t||i>=t&&o<=t){s=u;break}l=u,i=o}return{range:[l,s],t:(t-i)/(o-i)}}function ol(r){if(r.get(["endLabel","show"]))return!0;for(var t=0;t<Qt.length;t++)if(r.get([Qt[t],"endLabel","show"]))return!0;return!1}function hr(r,t,e,a){if(Ga(t,"cartesian2d")){var n=a.getModel("endLabel"),i=n.get("valueAnimation"),o=a.getData(),l={lastFrameIndex:0},s=ol(a)?function(f,g){r._endLabelOnDuring(f,g,o,l,i,n,t)}:null,u=t.getBaseAxis().isHorizontal(),v=rl(t,e,a,function(){var f=r._endLabel;f&&e&&l.originalX!=null&&f.attr({x:l.originalX,y:l.originalY})},s);if(!a.get("clip",!0)){var c=v.shape,h=Math.max(c.width,c.height);u?(c.y-=h,c.height+=h*2):(c.x-=h,c.width+=h*2)}return s&&s(1,v),v}else return nl(t,e,a)}function zu(r,t){var e=t.getBaseAxis(),a=e.isHorizontal(),n=e.inverse,i=a?n?"right":"left":"center",o=a?"middle":n?"top":"bottom";return{normal:{align:r.get("align")||i,verticalAlign:r.get("verticalAlign")||o}}}var Fu=function(r){z(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.init=function(){var e=new j,a=new er;this.group.add(a.group),this._symbolDraw=a,this._lineGroup=e,this._changePolyState=le(this._changePolyState,this)},t.prototype.render=function(e,a,n){var i=e.coordinateSystem,o=this.group,l=e.getData(),s=e.getModel("lineStyle"),u=e.getModel("areaStyle"),v=l.getLayout("points")||[],c=i.type==="polar",h=this._coordSys,f=this._symbolDraw,g=this._polyline,p=this._polygon,d=this._lineGroup,m=!a.ssr&&e.get("animation"),y=!u.isEmpty(),S=u.get("origin"),b=Qo(i,l,S),w=y&&Nu(i,l,b),_=e.get("showSymbol"),D=e.get("connectNulls"),A=_&&!c&&ku(e,l,i),P=this._data;P&&P.eachItemGraphicEl(function(F,q){F.__temp&&(o.remove(F),P.setItemGraphicEl(q,null))}),_||f.remove(),o.add(d);var I=c?!1:e.get("step"),x;i&&i.getArea&&e.get("clip",!0)&&(x=i.getArea(),x.width!=null?(x.x-=.1,x.y-=.1,x.width+=.2,x.height+=.2):x.r0&&(x.r0-=.5,x.r+=.5)),this._clipShapeForSymbol=x;var L=Vu(l,i,n)||l.getVisual("style")[l.getVisual("drawType")];if(!(g&&h.type===i.type&&I===this._step))_&&f.updateData(l,{isIgnore:A,clipSh
1ape:x,disableAnimation:!0,getSymbolPoint:function(F){return[v[F*2],v[F*2+1]]}}),m&&this._initSymbolLabelAnimation(l,i,x),I&&(w&&(w=nt(w,v,i,I,D)),v=nt(v,null,i,I,D)),g=this._newPolyline(v),y?p=this._newPolygon(v,w):p&&(d.remove(p),p=this._polygon=null),c||this._initOrUpdateEndLabel(e,i,Fn(L)),d.setClipPath(hr(this,i,!0,e));else{y&&!p?p=this._newPolygon(v,w):p&&!y&&(d.remove(p),p=this._polygon=null),c||this._initOrUpdateEndLabel(e,i,Fn(L));var E=d.getClipPath();if(E){var V=hr(this,i,!1,e);ue(E,{shape:V.shape},e)}else d.setClipPath(hr(this,i,!0,e));_&&f.updateData(l,{isIgnore:A,clipShape:x,disableAnimation:!0,getSymbolPoint:function(F){return[v[F*2],v[F*2+1]]}}),(!li(this._stackedOnPoints,w)||!li(this._points,v))&&(m?this._doUpdateAnimation(l,w,i,n,I,S,D):(I&&(w&&(w=nt(w,v,i,I,D)),v=nt(v,null,i,I,D)),g.setShape({points:v}),p&&p.setShape({points:v,stackedOnPoints:w})))}var T=e.getModel("emphasis"),R=T.get("focus"),N=T.get("blurScope"),C=T.get("disabled");if(g.useStyle(Ve(s.getLineStyle(),{fill:"none",stroke:L,lineJoin:"bevel"})),ce(g,e,"lineStyle"),g.style.lineWidth>
10&&e.get(["emphasis","lineStyle","width"])==="bolder"){var M=g.getState("emphasis").style;M.lineWidth=+g.style.lineWidth+1}ne(g).seriesIndex=e.seriesIndex,ie(g,R,N,C);var k=vi(e.get("smooth")),O=e.get("smoothMonotone");if(g.setShape({smooth:k,smoothMonotone:O,connectNulls:D}),p){var B=l.getCalculationInfo("stackedOnSeries"),W=0;p.useStyle(Ve(u.getAreaStyle(),{fill:L,opacity:.7,lineJoin:"bevel",decal:l.getVisual("style").decal})),B&&(W=vi(B.get("smooth"))),p.setShape({smooth:k,stackedOnSmooth:W,smoothMonotone:O,connectNulls:D}),ce(p,e,"areaStyle"),ne(p).seriesIndex=e.seriesIndex,ie(p,R,N,C)}var H=this._changePolyState;l.eachItemGraphicEl(function(F){F&&(F.onHoverStateChange=H)}),this._polyline.onHoverStateChange=H,this._data=l,this._coordSys=i,this._stackedOnPoints=w,this._points=v,this._step=I,this._valueOrigin=S;var X=e.get("triggerEvent"),ve=e.get("triggerLineEvent"),me=ve===!0||X===!0||X==="line",Y=ve===!0||X===!0||X==="area";this.packEventData(e,g,me),p&&this.packEventData(e,p,Y)},t.prototype.packEventData=function(e,a,n){ne(a).eventData=n?{componentType:"series",componentSubType:"line",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"line",selfType:a===this._polygon?"area":"line"}:null},t.prototype.highlight=function(e,a,n,i){var o=e.getData(),l=Hn(o,i);if(this._changePolyState("emphasis"),!(l instanceof Array)&&l!=null&&l>=0){var s=o.getLayout("points"),u=o.getItemGraphicEl(l);if(!u){var v=s[l*2],c=s[l*2+1];if(Ee(v,c)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(v,c))return;var h=e.get("zlevel")||0,f=e.get("z")||0;u=new tr(o,l),u.x=v,u.y=c,u.setZ(h,f);var g=u.getSymbolPath().getTextContent();g&&(g.zlevel=h,g.z=f,g.z2=this._polyline.z2+1),u.__temp=!0,o.setItemGraphicEl(l,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else ae.prototype.highlight.call(this,e,a,n,i)},t.prototype.downplay=function(e,a,n,i){var o=e.getData(),l=Hn(o,i);if(this._changePolyState("normal"),l!=null&&l>=0){var s=o.getItemGraphicEl(l);s&&(s.__temp?(o.setItemGraphicEl(l,null),this.group.remove(s)):s.downplay())}else ae.prototype.downplay.call(this,e,a,n,i)},t.prototype._changePolyState=function(e){var a=this._polygon;Va(this._polyline,e),a&&Va(a,e)},t.prototype._newPolyline=function(e){var a=this._polyline;return a&&this._lineGroup.remove(a),a=new Eu({shape:{points:e},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(a),this._polyline=a,a},t.prototype._newPolygon=function(e,a){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new al({shape:{points:e,stackedOnPoints:a},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},t.prototype._initSymbolLabelAnimation=function(e,a,n){var i,o,l=a.getBaseAxis(),s=l.inverse;a.type==="cartesian2d"?(i=l.isHorizontal(),o=!1):a.type==="polar"&&(i=l.dim==="angle",o=!0);var u=e.hostModel,v=u.get("animationDuration");Ie(v)&&(v=v(null));var c=u.get("animationDelay")||0,h=Ie(c)?c(null):c;e.eachItemGraphicEl(function(f,g){var p=f;if(p){var d=[f.x,f.y],m=void 0,y=void 0,S=void 0;if(n)if(o){var b=n,w=a.pointToCoord(d);i?(m=b.startAngle,y=b.endAngle,S=-w[1]/180*Math.PI):(m=b.r0,y=b.r,S=w[0])}else{var _=n;i?(m=_.x,y=_.x+_.width,S=f.x):(m=_.y+_.height,y=_.y,S=f.y)}var D=y===m?0:(S-m)/(y-m);s&&(D=1-D);var A=Ie(c)?c(g):v*D+h,P=p.getSymbolPath(),I=P.getTextContent();p.attr({scaleX:0,scaleY:0}),p.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:A}),I&&I.animateFrom({style:{opacity:0}},{duration:300,delay:A}),P.disableLabelAnimation=!0}})},t.prototype._initOrUpdateEndLabel=function(e,a,n){var i=e.getModel("endLabel");if(ol(e)){var o=e.getData(),l=this._polyline,s=o.getLayout("points");if(!s){l.removeTextContent(),this._endLabel=null;return}var u=this._endLabel;u||(u=this._endLabel=new Me({z2:200}),u.ignoreClip=!0,l.setTextContent(this._endLabel),l.disableLabelAnimation=!0);var v=Gu(s);v>=0&&(Ce(l,De(e,"endLabel"),{inheritColor:n,labelFetcher:e,labelDataIndex:v,defaultText:function(c,h,f){return f!=null?zo(o,f):ra(o,c)},enableTextSetter:!0},zu(i,a)),l.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},t.prototype._endLabelOnDuring=function(e,a,n,i,o,l,s){var u=this._endLabel,v=this._polyline;if(u){e<1&&i.originalX==null&&(i.originalX=u.x,i.originalY=u.y);var c=n.getLayout("points"),h=n.hostModel,f=h.get("connectNulls"),g=l.get("precision"),p=l.get("distance")||0,d=s.getBaseAxis(),m=d.isHorizontal(),y=d.inverse,S=a.shape,b=y?m?S.x:S.y+S.height:m?S.x+S.width:S.y,w=(m?p:0)*(y?-1:1),_=(m?0:-p)*(y?-1:1),D=m?"x":"y",A=Bu(c,b,D),P=A.range,I=P[1]-P[0],x=void 0;if(I>=1){if(I>1&&!f){var L=ci(c,P[0]);u.attr({x:L[0]+w,y:L[1]+_}),o&&(x=h.getRawValue(P[0]))}else{var L=v.getPointOn(b,D);L&&u.attr({x:L[0]+w,y:L[1]+_});var E=h.getRawValue(P[0]),V=h.getRawValue(P[1]);o&&(x=Ps(n,g,E,V,A.t))}i.lastFrameIndex=P[0]}else{var T=e===1||i.lastFrameIndex>0?P[0]:0,L=ci(c,T);o&&(x=h.getRawValue(T)),u.attr({x:L[0]+w,y:L[1]+_})}if(o){var R=_o(u);typeof R.setLabelText=="function"&&R.setLabelText(x)}}},t.prototype._doUpdateAnimation=function(e,a,n,i,o,l,s){var u=this._polyline,v=this._polygon,c=e.hostModel,h=Pu(this._data,e,this._stackedOnPoints,a,this._coordSys,n,this._valueOrigin),f=h.current,g=h.stackedOnCurrent,p=h.next,d=h.stackedOnNext;if(o&&(g=nt(h.stackedOnCurrent,h.current,n,o,s),f=nt(h.current,null,n,o,s),d=nt(h.stackedOnNext,h.next,n,o,s),p=nt(h.next,null,n,o,s)),ui(f,p)>3e3||v&&ui(g,d)>3e3){u.stopAnimation(),u.setShape({points:p}),v&&(v.stopAnimation(),v.setShape({points:p,stackedOnPoints:d}));return}u.shape.__points=h.current,u.shape.points=f;var m={shape:{points:p}};h.current!==f&&(m.shape.__points=h.next),u.stopAnimation(),J(u,m,c),v&&(v.setShape({points:f,stackedOnPoints:g}),v.stopAnimation(),J(v,{shape:{stackedOnPoints:d}},c),u.shape.points!==v.shape.points&&(v.shape.points=u.shape.points));for(var y=[],S=h.status,b=0;b<S.length;b++){var w=S[b].cmd;if(w==="="){var _=e.getItemGraphicEl(S[b].idx1);_&&y.push({el:_,ptIdx:b})}}u.animators&&u.animators.length&&u.animators[0].during(function(){v&&v.dirtyShape();for(var D=u.shape.__points,A=0;A<y.length;A++){var P=y[A].el,I=y[A].ptIdx*2;P.x=D[I],P.y=D[I+1],P.markRedraw()}})},t.prototype.remove=function(e){var a=this.group,n=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),n&&n.eachItemGraphicEl(function(i,o){i.__temp&&(a.remove(i),n.setItemGraphicEl(o,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},t.type="line",t}(ae);function Sa(r,t){return{seriesType:r,plan:da(),reset:function(e){var a=e.getData(),n=e.coordinateSystem,i=e.pipelineContext,o=t||i.large;if(n){var l=ee(n.dimensions,function(f){return a.mapDimension(f)}).slice(0,2),s=l.length,u=a.getCalculationInfo("stackResultDimension");ea(a,l[0])&&(l[0]=u),ea(a,l[1])&&(l[1]=u);var v=a.getStore(),c=a.getDimensionIndex(l[0]),h=a.getDimensionIndex(l[1]);return s&&{progress:function(f,g){for(var p=f.end-f.start,d=o&&ze(p*s),m=[],y=[],S=f.start,b=0;S<f.end;S++){var w=void 0;if(s===1){var _=v.get(c,S);w=n.dataToPoint(_,null,y)}else m[0]=v.get(c,S),m[1]=v.get(h,S),w=n.dataToPoint(m,null,y);o?(d[b++]=w[0],d[b++]=w[1]):g.setItemLayout(S,w.slice())}o&&(g.setLayout("points",d),g.setLayout("pointsRange",{start:f.start,end:f.end}))}}}}}}var Hu={average:function(r){for(var t=0,e=0,a=0;a<r.length;a++)isNaN(r[a])||(t+=r[a],e++);return e===0?NaN:t/e},sum:function(r){for(var t=0,e=0;e<r.length;e++)t+=r[e]||0;return t},max:function(r){for(var t=-1/0,e=0;e<r.length;e++)r[e]>t&&(t=r[e]);return isFinite(t)?t:NaN},min:function(r){for(var t=1/0,e=0;e<r.length;e++)r[e]<t&&(t=r[e]);return isFinite(t)?t:NaN},nearest:function(r){return r[0]}},Wu=function(r){return Math.round(r.length/2)};function ll(r){return{seriesType:r,reset:function(t,e,a){var n=t.getData(),i=t.get("sampling"),o=t.coordinateSystem,l=n.count();if(l>10&&o.type==="cartesian2d"&&i){var s=o.getBaseAxis(),u=o.getOtherAxis(s),v=s.getExtent(),c=a.getDevicePixelRatio(),h=Math.abs(v[1]-v[0])*(c||1),f=Math.round(l/h);if(isFinite(f)&&f>1){i==="lttb"?t.setData(n.lttbDownSample(n.mapDimension(u.dim),1/f)):i==="minmax"&&t.setData(n.minmaxDownSample(n.mapDimension(u.dim),1/f));var g=void 0;Le(i)?g=Hu[i]:Ie(i)&&(g=i),g&&t.setData(n.downSample(n.mapDimension(u.dim),1/f,g,Wu))}}}}}function sp(r){r.registerChartView(Fu),r.registerSeriesModel(Lu),r.registerLayout(Sa("line",!0)),r.registerVisual({seriesType:"line",reset:function(t){var e=t.getData(),a=t.getModel("lineStyle").getLineStyle();a&&!a.stroke&&(a.stroke=e.getVisual("style").fill),e.setVisual("legendLineStyle",a)}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,ll("line"))}var Uu=ln(),Zr="__ec_stack_";function sl(r){return r.get("stack")||Zr+r.seriesIndex}function Yu(r){if(Rs(r.axis.scale)){for(var t=Je(r.axis),e=[],a=0;a<r.count;
1a++)e.push(Ve({stackId:Zr+a},r));for(var n=ul({bandWidthResult:t,seriesInfo:e}),i=[],a=0;a<r.count;a++){var o=n[Zr+a];o.offsetCenter=o.offset+o.width/2,i.push(o)}return i}}function $u(r,t){var e=Xu(r,t);return e.columnMap=ul(e),e}function Xu(r,t){var e=ar(t,na),a=[],n=Je(r,{fromStat:{key:e},min:1});return ta(r,e,function(i){a.push({barWidth:U(i.get("barWidth"),n.w),barMaxWidth:U(i.get("barMaxWidth"),n.w),barMinWidth:U(i.get("barMinWidth")||(hl(i)?.5:1),n.w),barGap:i.get("barGap"),barCategoryGap:i.get("barCategoryGap"),defaultBarGap:i.get("defaultBarGap"),stackId:sl(i)})}),{bandWidthResult:n,seriesInfo:a}}function ul(r){var t=r.bandWidthResult.w,e=t,a=0,n,i,o=[],l={};G(r.seriesInfo,function(p,d){d||(i=p.defaultBarGap||0);var m=p.stackId;He(l,m)||a++;var y=l[m];y||(y=l[m]={width:0,maxWidth:0},o.push(m));var S=p.barWidth;S&&!y.width&&(y.width=S,S=Pt(e,S),e-=S);var b=p.barMaxWidth;b&&(y.maxWidth=b);var w=p.barMinWidth;w&&(y.minWidth=w);var _=p.barGap;_!=null&&(i=_);var D=p.barCategoryGap;D!=null&&(n=D)}),n==null&&(n=St(35-o.length*4,15)+"%");var s=U(n,t),u=U(i,1),v=(e-s)/(a+(a-1)*u);v=St(v,0),G(o,function(p){var d=l[p],m=d.maxWidth,y=d.minWidth;if(d.width){var S=d.width;m&&(S=Pt(S,m)),y&&(S=St(S,y)),d.width=S,e-=S+u*S,a--}else{var S=v;m&&m<S&&(S=Pt(m,e)),y&&y>S&&(S=y),S!==v&&(d.width=S,e-=S+u*S,a--)}}),v=(e-s)/(a+(a-1)*u),v=St(v,0);var c=0,h;G(o,function(p){var d=l[p];d.width||(d.width=v),h=d,c+=d.width*(1+u)}),h&&(c-=h.width*u);var f={},g=-c/2;return G(o,function(p){var d=l[p];f[p]=f[p]||{bandWidth:t,offset:g,width:d.width},g+=d.width*(1+u)}),f}function vl(r){return{seriesType:r,overallReset:function(t){var e=ar(r,na);Do(t,e,function(a){var n=$u(a,r);ta(a,e,function(i){var o=n.columnMap[sl(i)];i.getData().setLayout({bandWidth:o.bandWidth,offset:o.offset,size:o.width})})})}}}function cl(r){return{seriesType:r,plan:da(),reset:function(t){if(au(t)){var e=t.getData(),a=t.coordinateSystem,n=a.getBaseAxis(),i=a.getOtherAxis(n),o=e.getDimensionIndex(e.mapDimension(i.dim)),l=e.getDimensionIndex(e.mapDimension(n.dim)),s=t.get("showBackground",!0),u=e.mapDimension(i.dim),v=e.getCalculationInfo("stackResultDimension"),c=ea(e,u)&&!!e.getCalculationInfo("stackedOnSeries"),h=i.isHorizontal(),f=i.toGlobalCoord(i.dataToCoord(ru(i))),g=hl(t),p=t.get("barMinHeight")||0,d=v&&e.getDimensionIndex(v),m=e.getLayout("size"),y=e.getLayout("offset");return{progress:function(S,b){for(var w=S.count,_=g&&ze(w*3),D=g&&s&&ze(w*3),A=g&&ze(w),P=a.master.getRect(),I=h?P.width:P.height,x,L=b.getStore(),E=0;(x=S.next())!=null;){var V=L.get(c?d:o,x),T=L.get(l,x),R=f,N=void 0;c&&(N=+V-L.get(o,x));var C=void 0,M=void 0,k=void 0,O=void 0;if(h){var B=a.dataToPoint([V,T]);c&&(R=a.dataToPoint([N,T])[0]),C=R,M=B[1]+y,k=B[0]-R,O=m,Un(k)<p&&(k=(k<0?-1:1)*p)}else{var B=a.dataToPoint([T,V]);c&&(R=a.dataToPoint([T,N])[1]),C=B[0]+y,M=R,k=m,O=B[1]-R,Un(O)<p&&(O=(O<=0?-1:1)*p)}g?(_[E]=C,_[E+1]=M,_[E+2]=h?k:O,D&&(D[E]=h?P.x:C,D[E+1]=h?M:P.y,D[E+2]=I),A[x]=x):b.setItemLayout(x,{x:C,y:M,width:k,height:O}),E+=3}g&&b.setLayout({largePoints:_,largeDataIndices:A,largeBackgroundPoints:D,valueAxisHorizontal:h})}}}}}}function hl(r){return r.pipelineContext&&r.pipelineContext.large}function Zu(r){return hn(ar(r,na))}function fl(r){Uu(r,function(){function t(e){var a=ar(e,na);nu(r,a,e,na),sn(a,Zu(e))}t("bar"),t("pictorialBar")})}var ua=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.getInitialData=function(e,a){return et(null,this,{useEncodeDefaulter:!0})},t.prototype.getMarkerPosition=function(e,a,n){var i=this.coordinateSystem;if(i&&i.clampData){var o=i.clampData(e),l=i.dataToPoint(o);if(n)G(i.getAxes(),function(h,f){if(h.type==="category"&&a!=null){var g=h.getTicksCoords(),p=h.getTickModel().get("alignWithLabel"),d=o[f],m=a[f]==="x1"||a[f]==="y1";if(m&&!p&&(d+=1),g.length<2)return;if(g.length===2){l[f]=h.toGlobalCoord(h.getExtent()[m?1:0]);return}for(var y=void 0,S=void 0,b=1,w=0;w<g.length;w++){var _=g[w].coord,D=w===g.length-1?g[w-1].tickValue+b:g[w].tickValue;if(D===d){S=_;break}else if(D<d)y=_;else if(y!=null&&D>d){S=(_+y)/2;break}w===1&&(b=D-g[0].tickValue)}S==null&&(y?y&&(S=g[g.length-1].coord):S=g[0].coord),l[f]=h.toGlobalCoord(S)}});else{var s=this.getData(),u=s.getLayout("offset"),v=s.getLayout("size"),c=i.getBaseAxis().isHorizontal()?0:1;l[c]+=u+v/2}return l}return[NaN,NaN]},t.prototype.__requireStartValue=function(e){return this.getBaseAxis()!==e},t.type="series.__base_bar__",t.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod",defaultBarGap:"10%"},t}(se);se.registerClass(ua);var qu=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.getInitialData=function(){return et(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},t.prototype.getProgressive=function(){return this.get("large")?this.get("progressive"):!1},t.prototype.__preparePipelineContext=function(e,a){var n=Ns(this,e,a);
1return n.progressiveRender&&(n.large=!0),n},t.prototype.brushSelector=function(e,a,n){return n.rect(a.getItemLayout(e))},t.type="series."+Et,t.dependencies=["grid","polar"],t.defaultOption=xo(ua.defaultOption,{clip:!0,roundCap:!1,showBackground:!1,backgroundStyle:{color:"rgba(180, 180, 180, 0.2)",borderColor:null,borderWidth:0,borderType:"solid",borderRadius:0,shadowBlur:0,shadowColor:null,shadowOffsetX:0,shadowOffsetY:0,opacity:1},select:{itemStyle:{borderColor:Z.color.primary,borderWidth:2}},realtimeSort:!1}),t}(ua),Ku=function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r}(),Ha=function(r){z(t,r);function t(e){var a=r.call(this,e)||this;return a.type="sausage",a}return t.prototype.getDefaultShape=function(){return new Ku},t.prototype.buildPath=function(e,a){var n=a.cx,i=a.cy,o=Math.max(a.r0||0,0),l=Math.max(a.r,0),s=(l-o)*.5,u=o+s,v=a.startAngle,c=a.endAngle,h=a.clockwise,f=Math.PI*2,g=h?c-v<f:v-c<f;g||(v=c-(h?f:-f));var p=Math.cos(v),d=Math.sin(v),m=Math.cos(c),y=Math.sin(c);g?(e.moveTo(p*o+n,d*o+i),e.arc(p*u+n,d*u+i,s,-Math.PI+v,v,!h)):e.moveTo(p*l+n,d*l+i),e.arc(n,i,l,v,c,!h),e.arc(m*u+n,y*u+i,s,c-Math.PI*2,c-Math.PI,!h),o!==0&&e.arc(n,i,o,c,v,h)},t}(xe);function ju(r,t){t=t||{};var e=t.isRoundCap;return function(a,n,i){var o=n.position;if(!o||o instanceof Array)return kn(a,n,i);var l=r(o),s=n.distance!=null?n.distance:5,u=this.shape,v=u.cx,c=u.cy,h=u.r,f=u.r0,g=(h+f)/2,p=u.startAngle,d=u.endAngle,m=(p+d)/2,y=e?Math.abs(h-f)/2:0,S=Math.cos,b=Math.sin,w=v+h*S(p),_=c+h*b(p),D="left",A="top";switch(l){case"startArc":w=v+(f-s)*S(m),_=c+(f-s)*b(m),D="center",A="top";break;case"insideStartArc":w=v+(f+s)*S(m),_=c+(f+s)*b(m),D="center",A="bottom";break;case"startAngle":w=v+g*S(p)+xa(p,s+y,!1),_=c+g*b(p)+Aa(p,s+y,!1),D="right",A="middle";break;case"insideStartAngle":w=v+g*S(p)+xa(p,-s+y,!1),_=c+g*b(p)+Aa(p,-s+y,!1),D="left",A="middle";break;case"middle":w=v+g*S(m),_=c+g*b(m),D="center",A="middle";break;case"endArc":w=v+(h+s)*S(m),_=c+(h+s)*b(m),D="center",A="bottom";break;case"insideEndArc":w=v+(h-s)*S(m),_=c+(h-s)*b(m),D="center",A="top";break;case"endAngle":w=v+g*S(d)+xa(d,s+y,!0),_=c+g*b(d)+Aa(d,s+y,!0),D="left",A="middle";break;case"insideEndAngle":w=v+g*S(d)+xa(d,-s+y,!0),_=c+g*b(d)+Aa(d,-s+y,!0),D="right",A="middle";break;default:return kn(a,n,i)}return a=a||{},a.x=w,a.y=_,a.align=D,a.verticalAlign=A,a}}function Ju(r,t,e,a){if(Ne(a)){r.setTextConfig({rotation:a});return}else if(Q(t)){r.setTextConfig({rotation:0});return}var n=r.shape,i=n.clockwise?n.startAngle:n.endAngle,o=n.clockwise?n.endAngle:n.startAngle,l=(i+o)/2,s,u=e(t);switch(u){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":s=l;break;case"startAngle":case"insideStartAngle":s=i;break;case"endAngle":case"insideEndAngle":s=o;break;default:r.setTextConfig({rotation:0});return}var v=Math.PI*1.5-s;u==="middle"&&v>Math.PI/2&&v<Math.PI*1.5&&(v-=Math.PI),r.setTextConfig({rotation:v})}function xa(r,t,e){return t*Math.sin(r)*(e?-1:1)}function Aa(r,t,e){return t*Math.cos(r)*(e?1:-1)}function Fe(r,t,e){var a=r.get("borderRadius");if(a==null)return e?{cornerRadius:0}:null;Q(a)||(a=[a,a,a,a]);var n=Math.abs(t.r||0-t.r0||0);return{cornerRadius:ee(a,function(i){return vs(i,n)})}}var fr=Math.max,gr=Math.min,Qu=function(r){z(t,r);function t(){var e=r.call(this)||this;return e.type=Et,e._isFirstFrame=!0,e}return t.prototype.render=function(e,a,n,i){this._model=e,this._removeOnRenderedListener(n),this._updateDrawMode(e);var o=e.get("coordinateSystem");(o==="cartesian2d"||o==="polar")&&(this._progressiveEls=null,this._isLargeDraw?this._renderLarge(e,a,n):this._renderNormal(e,a,n,i))},t.prototype.incrementalPrepareRender=function(e){this._clear(),this._updateDrawMode(e),this._updateLargeClip(e)},t.prototype.incrementalRender=function(e,a){this._progressiveEls=[],this._incrementalRenderLarge(e,a)},t.prototype.eachRendered=function(e){qa(this._progressiveEls||this.group,e)},t.prototype._updateDrawMode=function(e){var a=e.pipelineContext.large;(this._isLargeDraw==null||a!==this._isLargeDraw)&&(this._isLargeDraw=a,this._clear())},t.prototype._renderNormal=function(e,a,n,i){var o=this.group,l=e.getData(),s=this._data,u=e.co
1ordinateSystem,v=u.getBaseAxis(),c;u.type==="cartesian2d"?c=v.isHorizontal():u.type==="polar"&&(c=v.dim==="angle");var h=e.isAnimationEnabled()?e:null,f=ev(e,u);f&&this._enableRealtimeSort(f,l,n);var g=e.get("clip",!0)||f,p=u.getArea();o.removeClipPath();var d=e.get("roundCap",!0),m=e.get("showBackground",!0),y=e.getModel("backgroundStyle"),S=y.get("borderRadius")||0,b=[],w=this._backgroundEls,_=i&&i.isInitSort,D=i&&i.type==="changeAxisOrder";function A(x){var L=Ia[u.type](l,x);if(!L)return null;var E=lv(u,c,L);return E.useStyle(y.getItemStyle()),u.type==="cartesian2d"?E.setShape("r",S):E.setShape("cornerRadius",S),b[x]=E,E}l.diff(s).add(function(x){var L=l.getItemModel(x),E=Ia[u.type](l,x,L);if(E&&(m&&A(x),!(!l.hasValue(x)||!di[u.type](E)))){var V=!1;g&&(V=hi[u.type](p,E));var T=fi[u.type](e,l,x,E,c,h,v.model,!1,d);f&&(T.forceLabelAnimation=!0),yi(T,l,x,L,E,e,c,u.type==="polar"),_?T.attr({shape:E}):f?gi(f,h,T,E,x,c,!1,!1):ue(T,{shape:E},e,x),l.setItemGraphicEl(x,T),o.add(T),T.ignore=V}}).update(function(x,L){var E=l.getItemModel(x),V=Ia[u.type](l,x,E);if(V){if(m){var T=void 0;w.length===0?T=A(L):(T=w[L],T.useStyle(y.getItemStyle()),u.type==="cartesian2d"?T.setShape("r",S):T.setShape("cornerRadius",S),b[x]=T);var R=Ia[u.type](l,x),N=pl(c,R,u);J(T,{shape:N},h,x)}var C=s.getItemGraphicEl(L);if(!l.hasValue(x)||!di[u.type](V)){o.remove(C);return}var M=!1;g&&(M=hi[u.type](p,V),M&&o.remove(C));var k=C&&(C.type==="sector"&&d||C.type==="sausage"&&!d);if(k&&(C&&ut(C,e,L),C=null),C?Oe(C):C=fi[u.type](e,l,x,V,c,h,v.model,!0,d),f&&(C.forceLabelAnimation=!0),D){var O=C.getTextContent();if(O){var B=_o(O);B.prevValue!=null&&(B.prevValue=B.value)}}else yi(C,l,x,E,V,e,c,u.type==="polar");_?C.attr({shape:V}):f?gi(f,h,C,V,x,c,!0,D):J(C,{shape:V},e,x,null),l.setItemGraphicEl(x,C),C.ignore=M,o.add(C)}}).remove(function(x){var L=s.getItemGraphicEl(x);L&&ut(L,e,x)}).execute();var P=this._backgroundGroup||(this._backgroundGroup=new j);P.removeAll();for(var I=0;I<b.length;++I)P.add(b[I]);o.add(P),this._backgroundEls=b,this._data=l},t.prototype._renderLarge=function(e,a,n){this._clear(),Si(e,this.group),this._updateLargeClip(e)},t.prototype._incrementalRenderLarge=function(e,a){this._removeBackground(),Si(a,this.group,this._progressiveEls,!0)},t.prototype._updateLargeClip=function(e){var a=e.get("clip",!0)&&wt(e.coordinateSystem,!1,e),n=this.group;a?n.setClipPath(a):n.removeClipPath()},t.prototype._enableRealtimeSort=function(e,a,n){var i=this;if(a.count()){var o=e.baseAxis;if(this._isFirstFrame)this._dispatchInitSort(a,e,n),this._isFirstFrame=!1;else{var l=function(s){var u=a.getItemGraphicEl(s),v=u&&u.shape;return v&&Math.abs(o.isHorizontal()?v.height:v.width)||0};this._onRendered=function(){i._updateSortWithinSameData(a,l,o,n)},n.getZr().on("rendered",this._onRendered)}}},t.prototype._dataSort=function(e,a,n){var i=[];return e.each(e.mapDimension(a.dim),function(o,l){var s=n(l);s=s??NaN,i.push({dataIndex:l,mappedValue:s,ordinalNumber:o})}),i.sort(function(o,l){return l.mappedValue-o.mappedValue}),{ordinalNumbers:ee(i,function(o){return o.ordinalNumber})}},t.prototype._isOrderChangedWithinSameData=function(e,a,n){for(var i=n.scale,o=e.mapDimension(n.dim),l=Number.MAX_VALUE,s=0,u=i.getOrdinalMeta().categories.length;s<u;++s){var v=e.rawIndexOf(o,i.getRawOrdinalNumber(s)),c=v<0?Number.MIN_VALUE:a(e.indexOfRawIndex(v));if(c>l)return!0;l=c}return!1},t.prototype._isOrderDifferentInView=function(e,a){for(var n=a.scale,i=n.getExtent(),o=Math.max(0,i[0]),l=Math.min(i[1],n.getOrdinalMeta().categories.length-1);o<=l;++o)if(e.ordinalNumbers[o]!==n.getRawOrdinalNumber(o))return!0},t.prototype._updateSortWithinSameData=function(e,a,n,i){if(this._isOrderChangedWithinSameData(e,a,n)){var o=this._dataSort(e,n,a);this._isOrderDifferentInView(o,n)&&(this._removeOnRenderedListener(i),i.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:o}))}},t.prototype._dispatchInitSort=function(e,a,n){var i=a.baseAxis,o=this._dataSort(e,i,function(l){return e.get(e.mapDimension(a.otherAxis.dim),l)});n.dispatchAction({type:"changeAxisOrder",componentType:i.dim+"Axis",isInitSort:!0,axisId:i.index,sortInfo:o})},t.prototype.remove=function(e,a){this._clear(this._model),this._removeOnRenderedListener(a)},t.prototype.dispose=function(e,a){this._removeOnRenderedListener(a)},t.prototype._removeOnRenderedListener=function(e){this._onRendered&&(e.getZr().off("rendered",this._onRendered),this._onRendered=null)},t.prototype._clear=function(e){var a=this.group,n=this._data;
1e&&e.isAnimationEnabled()&&n&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],n.eachItemGraphicEl(function(i){ut(i,e,ne(i).dataIndex)})):a.removeAll(),this._data=null,this._isFirstFrame=!0},t.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},t.type=Et,t}(ae),hi={cartesian2d:function(r,t){var e=t.width<0?-1:1,a=t.height<0?-1:1;e<0&&(t.x+=t.width,t.width=-t.width),a<0&&(t.y+=t.height,t.height=-t.height);var n=r.x+r.width,i=r.y+r.height,o=fr(t.x,r.x),l=gr(t.x+t.width,n),s=fr(t.y,r.y),u=gr(t.y+t.height,i),v=l<o,c=u<s;return t.x=v&&o>n?l:o,t.y=c&&s>i?u:s,t.width=v?0:l-o,t.height=c?0:u-s,e<0&&(t.x+=t.width,t.width=-t.width),a<0&&(t.y+=t.height,t.height=-t.height),v||c},polar:function(r,t){var e=t.r0<=t.r?1:-1;if(e<0){var a=t.r;t.r=t.r0,t.r0=a}var n=gr(t.r,r.r),i=fr(t.r0,r.r0);t.r=n,t.r0=i;var o=n-i<0;if(e<0){var a=t.r;t.r=t.r0,t.r0=a}return o}},fi={cartesian2d:function(r,t,e,a,n,i,o,l,s){var u=new Ae({shape:$({},a),z2:1});if(u.__dataIndex=e,u.name="item",i){var v=u.shape,c=n?"height":"width";v[c]=0}return u},polar:function(r,t,e,a,n,i,o,l,s){var u=!n&&s?Ha:je,v=new u({shape:a,z2:1});v.name="item";var c=gl(n);if(v.calculateTextPosition=ju(c,{isRoundCap:u===Ha}),i){var h=v.shape,f=n?"r":"endAngle",g={};h[f]=n?a.r0:a.startAngle,g[f]=a[f],(l?J:ue)(v,{shape:g},i)}return v}};function ev(r,t){var e=r.get("realtimeSort",!0),a=t.getBaseAxis();if(e&&a.type==="category"&&t.type==="cartesian2d")return{baseAxis:a,otherAxis:t.getOtherAxis(a)}}function gi(r,t,e,a,n,i,o,l){var s,u;i?(u={x:a.x,width:a.width},s={y:a.y,height:a.height}):(u={y:a.y,height:a.height},s={x:a.x,width:a.width}),l||(o?J:ue)(e,{shape:s},t,n,null);var v=t?r.baseAxis.model:null;(o?J:ue)(e,{shape:u},v,n)}function pi(r,t){for(var e=0;e<t.length;e++)if(!isFinite(r[t[e]]))return!0;return!1}var tv=["x","y","width","height"],av=["cx","cy","r","startAngle","endAngle"],di={cartesian2d:function(r){return!pi(r,tv)},polar:function(r){return!pi(r,av)}},Ia={cartesian2d:function(r,t,e){var a=r.getItemLayout(t);if(!a)return null;var n=e?nv(e,a):0,i=a.width>0?1:-1,o=a.height>0?1:-1;return{x:a.x+i*n/2,y:a.y+o*n/2,width:a.width-i*n,height:a.height-o*n}},polar:function(r,t,e){var a=r.getItemLayout(t);return{cx:a.cx,cy:a.cy,r0:a.r0,r:a.r,startAngle:a.startAngle,endAngle:a.endAngle,clockwise:a.clockwise}}};function rv(r){return r.startAngle!=null&&r.endAngle!=null&&r.startAngle===r.endAngle}function gl(r){return function(t){var e=t?"Arc":"Angle";return function(a){switch(a){case"start":case"insideStart":case"end":case"insideEnd":return a+e;default:return a}}}(r)}function yi(r,t,e,a,n,i,o,l){var s=t.getItemVisual(e,"style");if(l){if(!i.get("roundCap")){var v=r.shape,c=Fe(a.getModel("itemStyle"),v,!0);$(v,c),r.setShape(v)}}else{var u=a.get(["itemStyle","borderRadius"])||0;r.setShape("r",u)}r.useStyle(s);var h=a.getShallow("cursor");h&&r.attr("cursor",h);var f=l?o?n.r>=n.r0?"endArc":"startArc":n.endAngle>=n.startAngle?"endAngle":"startAngle":o?sv(n,i.coordinateSystem):uv(n,i.coordinateSystem),g=De(a);Ce(r,g,{labelFetcher:i,labelDataIndex:e,defaultText:ra(i.getData(),e),inheritColor:s.fill,defaultOpacity:s.opacity,defaultOutsidePosition:f});var p=r.getTextContent();if(l&&p){var d=a.get(["label","position"]);r.textConfig.inside=d==="middle"?!0:null,Ju(r,d==="outside"?f:d,gl(o),a.get(["label","rotate"]))}Ao(p,g,i.getRawValue(e),function(y){return zo(t,y)});var m=a.getModel(["emphasis"]);ie(r,m.get("focus"),m.get("blurScope"),m.get("disabled")),ce(r,a),rv(n)&&(r.style.fill="none",r.style.stroke="none",G(r.states,function(y){y.style&&(y.style.fill=y.style.stroke="none")}))}function nv(r,t){var e=r.get(["itemStyle","borderColor"]);if(!e||e==="none")return 0;var a=r.get(["itemStyle","borderWidth"])||0,n=isNaN(t.width)?Number.MAX_VALUE:Math.abs(t.width),i=isNaN(t.height)?Number.MAX_VALUE:Math.abs(t.height);return Math.min(a,n,i)}var iv=function(){function r(){}return r}(),mi=function(r){z(t,r);function t(e){var a=r.call(this,e)||this;return a.type="largeBar",a}return t.prototype.getDefaultShape=function(){return new iv},t.prototype.buildPath=function(e,a){for(var n=a.points,i=this.baseDimIdx,o=1-this.baseDimIdx,l=[],s=[],u=this.barWidth,v=0;v<n.length;v+=3)s[i]=u,s[o]=n[v+2],l[i]=n[v+i],l[o]=n[v+o],e.rect(l[0],l[1],s[0],s[1])},t}(xe);function Si(r,t,e,a){var n=r.getData(),i=n.getLayout("valueAxisHorizontal")?1:0,o=n.getLayout("largeDataIndices"),l=n.getLayout("size"),s=r.getModel("backgroundStyle"),u=n.getLayout("largeBackgroun
1dPoints"),v=a?We(r):0;if(u){var c=new mi({shape:{points:u},incremental:v,silent:!0,z2:0});c.baseDimIdx=i,c.largeDataIndices=o,c.barWidth=l,c.useStyle(s.getItemStyle()),t.add(c),e&&e.push(c)}var h=new mi({shape:{points:n.getLayout("largePoints")},incremental:v,ignoreCoarsePointer:!0,z2:1});h.baseDimIdx=i,h.largeDataIndices=o,h.barWidth=l,t.add(h),h.useStyle(n.getVisual("style")),h.style.stroke=null,ne(h).seriesIndex=r.seriesIndex,r.get("silent")||(h.on("mousedown",bi),h.on("mousemove",bi)),e&&e.push(h)}var bi=Ms(function(r){var t=this,e=ov(t,r.offsetX,r.offsetY);ne(t).dataIndex=e>=0?e:null},30,!1);function ov(r,t,e){for(var a=r.baseDimIdx,n=1-a,i=r.shape.points,o=r.largeDataIndices,l=[],s=[],u=r.barWidth,v=0,c=i.length/3;v<c;v++){var h=v*3;if(s[a]=u,s[n]=i[h+2],l[a]=i[h+a],l[n]=i[h+n],s[n]<0&&(l[n]+=s[n],s[n]=-s[n]),t>=l[0]&&t<=l[0]+s[0]&&e>=l[1]&&e<=l[1]+s[1])return o[v]}return-1}function pl(r,t,e){if(Ga(e,"cartesian2d")){var a=t,n=e.getArea();return{x:r?a.x:n.x,y:r?n.y:a.y,width:r?a.width:n.width,height:r?n.height:a.height}}else{var n=e.getArea(),i=t;return{cx:n.cx,cy:n.cy,r0:r?n.r0:i.r0,r:r?n.r:i.r,startAngle:r?i.startAngle:0,endAngle:r?i.endAngle:Math.PI*2}}}function lv(r,t,e){var a=r.type==="polar"?je:Ae;return new a({shape:pl(t,e,r),silent:!0,z2:0})}function sv(r,t){if(r.height===0){var e=t.getOtherAxis(t.getBaseAxis());return e.inverse?"bottom":"top"}return r.height>0?"bottom":"top"}function uv(r,t){if(r.width===0){var e=t.getOtherAxis(t.getBaseAxis());return e.inverse?"left":"right"}return r.width>=0?"right":"left"}function up(r){r.registerChartView(Qu),r.registerSeriesModel(qu),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,vl(Et)),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,cl(Et)),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,ll(Et)),r.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},function(t,e){var a=t.componentType||"series";e.eachComponent({mainType:a,query:t},function(n){t.sortInfo&&n.axis.setCategorySortInfo(t.sortInfo)})}),fl(r)}function ba(r){return{seriesType:r,reset:function(t,e){var a=e.findComponents({mainType:"legend"});if(!(!a||!a.length)){var n=t.getData();n.filterSelf(function(i){for(var o=n.getName(i),l=0;l<a.length;l++)if(!a[l].isSelected(o))return!1;return!0})}}}}var Ut=function(){function r(t,e){this._getDataWithEncodedVisual=t,this._getRawData=e}return r.prototype.getAllNames=function(){var t=this._getRawData();return t.mapArray(t.getName)},r.prototype.containName=function(t){var e=this._getRawData();return e.indexOfName(t)>=0},r.prototype.indexOfName=function(t){var e=this._getDataWithEncodedVisual();return e.indexOfName(t)},r.prototype.getItemVisual=function(t,e){var a=this._getDataWithEncodedVisual();return a.getItemVisual(t,e)},r}(),vt="pie",vv=Ft(),dl=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(e){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Ut(le(this.getData,this),le(this.getRawData,this)),this._defaultLabelLine(e)},t.prototype.mergeOption=function(){r.prototype.mergeOption.apply(this,arguments)},t.prototype.getInitialData=function(){return ma(this,{coordDimensions:["value"],encodeDefaulter:Xe(Io,this)})},t.prototype.getDataParams=function(e){var a=this.getData(),n=vv(a),i=n.seats;if(!i){var o=[];a.each(a.mapDimension("value"),function(s){o.push(s)}),i=n.seats=Vs(o,a.hostModel.get("percentPrecision"))}var l=r.prototype.getDataParams.call(this,e);return l.percent=i[e]||0,l.$vars.push("percent"),l},t.prototype._defaultLabelLine=function(e){un(e,"labelLine",["show"]);var a=e.labelLine,n=e.emphasis.labelLine;a.show=a.show&&e.label.show,n.show=n.show&&e.emphasis.label.show},t.type="series."+vt,t.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"50%"],clockwise:!0,startAngle:90,endAngle:"auto",padAngle:0,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,coordinateSystemUsage:"box",left:0,top:0,right:0,bottom:0,width:null,height:null,label:{rotate:0,show:!0,overflow:"truncate",position:"outer",alignTo:"none",edgeDistance:"25%",distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:30,smooth:!1,minTurnAngle:90,maxSurfaceAngle:90,lineStyle:{width:1,type:"solid"}},itemStyle:{borderWidth:1,borderJoin:"round"},showEmptyCircle:!0,emptyCircleStyle:{color:"lightgray",opacity:1},labelLayout:{hideOverlap:!0},emphasis:{scale:!0,scaleSize:5}
1,avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},t}(se);ks({fullType:dl.type,getCoord2:function(r){return r.getShallow("center")}});var cv=Math.PI/180;function wi(r,t,e,a,n,i,o,l,s,u){if(r.length<2)return;function v(p){for(var d=p.rB,m=d*d,y=0;y<p.list.length;y++){var S=p.list[y],b=Math.abs(S.label.y-e),w=a+S.len,_=w*w,D=Math.sqrt(Math.abs((1-b*b/m)*_)),A=t+(D+S.len2)*n,P=A-S.label.x,I=S.targetTextWidth-P*n;yl(S,I,!0),S.label.x=A}}function c(p){for(var d={list:[],maxY:0},m={list:[],maxY:0},y=0;y<p.length;y++)if(p[y].labelAlignTo==="none"){var S=p[y],b=S.label.y>e?m:d,w=Math.abs(S.label.y-e);if(w>=b.maxY){var _=S.label.x-t-S.len2*n,D=a+S.len,A=Math.abs(_)<D?Math.sqrt(w*w/(1-_*_/D/D)):D;b.rB=A,b.maxY=w}b.list.push(S)}v(d),v(m)}for(var h=r.length,f=0;f<h;f++)if(r[f].position==="outer"&&r[f].labelAlignTo==="labelLine"){var g=r[f].label.x-u;r[f].linePoints[1][0]+=g,r[f].label.x=u}ou(r,1,s,s+o)&&c(r)}function hv(r,t,e,a,n,i,o,l){for(var s=[],u=[],v=Number.MAX_VALUE,c=-Number.MAX_VALUE,h=0;h<r.length;h++){var f=r[h].label;pr(r[h])||(f.x<t?(v=Math.min(v,f.x),s.push(r[h])):(c=Math.max(c,f.x),u.push(r[h])))}for(var h=0;h<r.length;h++){var g=r[h];if(!pr(g)&&g.linePoints){if(g.labelStyleWidth!=null)continue;var f=g.label,p=g.linePoints,d=void 0;g.labelAlignTo==="edge"?f.x<t?d=p[2][0]-g.labelDistance-o-g.edgeDistance:d=o+n-g.edgeDistance-p[2][0]-g.labelDistance:g.labelAlignTo==="labelLine"?f.x<t?d=v-o-g.bleedMargin:d=o+n-c-g.bleedMargin:f.x<t?d=f.x-o-g.bleedMargin:d=o+n-f.x-g.bleedMargin,g.targetTextWidth=d,yl(g,d,!1)}}wi(u,t,e,a,1,n,i,o,l,c),wi(s,t,e,a,-1,n,i,o,l,v);for(var h=0;h<r.length;h++){var g=r[h];if(!pr(g)&&g.linePoints){var f=g.label,p=g.linePoints,m=g.labelAlignTo==="edge",y=f.style.padding,S=y?y[1]+y[3]:0,b=f.style.backgroundColor?0:S,w=g.rect.width+b,_=p[1][0]-p[2][0];m?f.x<t?p[2][0]=o+g.edgeDistance+w+g.labelDistance:p[2][0]=o+n-g.edgeDistance-w-g.labelDistance:(f.x<t?p[2][0]=f.x+g.labelDistance:p[2][0]=f.x-g.labelDistance,p[1][0]=p[2][0]+_),p[1][1]=p[2][1]=f.y}}}function yl(r,t,e){if(r.labelStyleWidth==null){var a=r.label,n=a.style,i=r.rect,o=n.backgroundColor,l=n.padding,s=l?l[1]+l[3]:0,u=n.overflow,v=i.width+(o?0:s);if(t<v||e){if(u&&u.match("break")){a.setStyle("backgroundColor",null),a.setStyle("width",t-s);var c=a.getBoundingRect();a.setStyle("width",Math.ceil(c.width)),a.setStyle("backgroundColor",o)}else{var h=t-s,f=t<v?h:e?h>r.unconstrainedWidth?null:h:null;a.setStyle("width",f)}ml(i,a)}}}function ml(r,t){_i.rect=r,iu(_i,t,fv)}var fv={minMarginForce:[null,0,null,0],marginDefault:[1,0,1,0]},_i={};function pr(r){return r.position==="center"}function gv(r){var t=r.getData(),e=[],a,n,i=!1,o=(r.get("minShowLabelAngle")||0)*cv,l=t.getLayout("viewRect"),s=t.getLayout("r"),u=l.width,v=l.x,c=l.y,h=l.height;function f(_){_.ignore=!0}function g(_){if(!_.ignore)return!0;for(var D in _.states)if(_.states[D].ignore===!1)return!0;return!1}t.each(function(_){var D=t.getItemGraphicEl(_),A=D.shape,P=D.getTextContent(),I=D.getTextGuideLine(),x=t.getItemModel(_),L=x.getModel("label"),E=L.get("position")||x.get(["emphasis","label","position"]),V=L.get("distanceToLabelLine"),T=L.get("alignTo"),R=U(L.get("edgeDistance"),u),N=L.get("bleedMargin");N==null&&(N=Math.min(u,h)>200?10:2);var C=x.getModel("labelLine"),M=C.get("length");M=U(M,u);var k=C.get("length2");if(k=U(k,u),Math.abs(A.endAngle-A.startAngle)<o){G(P.states,f),P.ignore=!0,I&&(G(I.states,f),I.ignore=!0);return}if(g(P)){var O=(A.startAngle+A.endAngle)/2,B=Math.cos(O),W=Math.sin(O),H,X,ve,me;a=A.cx,n=A.cy;var Y=E==="inside"||E==="inner";if(E==="center")H=A.cx,X=A.cy,me="center";else{var F=(Y?(A.r+A.r0)/2*B:A.r*B)+a,q=(Y?(A.r+A.r0)/2*W:A.r*W)+n;if(H=F+B*3,X=q+W*3,!Y){var K=F+B*(M+s-A.r),te=q+W*(M+s-A.r),pe=K+(B<0?-1:1)*k,we=te;T==="edge"?H=B<0?v+R:v+u-R:H=pe+(B<0?-V:V),X=we,ve=[[F,q],[K,te],[pe,we]]}me=Y?"center":T==="edge"?B>0?"right":"left":B>0?"left":"right"}var re=Math.PI,fe=0,de=L.get("rotate");if(Ne(de))fe=de*(re/180);else if(E==="center")fe=0;else if(de==="radial"||de===!0){var tt=B<0?-O+re:-O;fe=tt}else if(de==="tangential"||de==="tangential-noflip"&&E!=="outside"&&E!=="outer"){var Ye=Math.atan2(B,W);Ye<0&&(Ye=re*2+Ye);var wa=W>0;wa&&de!=="tangential-noflip"&&(Ye=re+Ye),fe=Ye-re}if(i=!!fe,P.x=H,P.y=X,P.rotation=fe,P.setStyle({verticalAlign:"middle"}),Y){P.setStyle({align:me});var lr=P.states.select;lr&&(lr.x+=P.x,lr.y+=P.y)}else{var or=new Bt(0,0,0,0);ml(or,P),e.push({label:P,labelLine:I,position:E,len:M,len2:k,minTurnAngle:C.get("minTurnAngle"),maxSurfaceAngle:C.get("maxSurfaceAngle"),surfaceNormal:new ge(B,W),linePoints:ve,textAlign:me,labelDistance:V,labelAlignTo:T,edgeDistance:R,bleedMargin:N,rect:or,unconstrainedWidth:or.width,labelStyleWidth:P.style.width})}D.setTextConfig({inside:Y})}}),!i&&r.get("avoidLabelOverlap")&&hv(e,a,n,s,u,h,v,c);for(var p=0;p<e.length;p++){var d=e[p],m=d.label,y=d.labelLine,S=isNaN(m.x)||isNaN(m.y);if(m){m.setStyle({align:d.textAlign}),S&&(G(m.states,f),m.ignore=!0);var b=m.states.select;b&&(b.x+=m.x,b.y+=m.y)}if(y){var w=d.linePoints;S||!w?(G(y.states,f),y.ignore=!0):(xu(w,d.minTurnAngle),Au(w,d.surfaceNormal,d.maxSurfaceAngle),y.setShape({points:w}),m.__hostTarget.textGuideLineConfig={anchor:new ge(w[0][0],w[0][1])})}}}var Di=Math.PI*2,La=Math.PI/180,pv=he(vt,dv);function dv(r,t){r.eachSeriesByType(vt,function(e){var a=e.getData(),n=a.mapDimension("value"),i=Lo(e,t),o=i.cx,l=i.cy,s=i.r,u=i.r0,v=i.viewRect,c=-e.get("startAngle")*La,h=e.get("endAngle"),f=e.get("padAngle")*La;h=h==="auto"?c-Di:-h*La;
1var g=e.get("minAngle")*La,p=g+f,d=0;a.each(n,function(R){!isNaN(R)&&d++});var m=a.getSum(n),y=Math.PI/(m||d)*2,S=e.get("clockwise"),b=e.get("roseType"),w=e.get("stillShowZeroSum"),_=a.getDataExtent(n);_[0]=0;var D=S?1:-1,A=[c,h],P=D*f/2;an(A,!S),c=A[0],h=A[1];var I=Sl(e);I.startAngle=c,I.endAngle=h,I.clockwise=S,I.cx=o,I.cy=l,I.r=s,I.r0=u;var x=Math.abs(h-c),L=x,E=0,V=c;if(a.setLayout({viewRect:v,r:s}),a.each(n,function(R,N){var C;if(isNaN(R)){a.setItemLayout(N,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:S,cx:o,cy:l,r0:u,r:b?NaN:s});return}b!=="area"?C=m===0&&w?y:R*y:C=x/d,C<p?(C=p,L-=p):E+=R;var M=V+D*C,k=0,O=0;f>C?(k=V+D*C/2,O=k):(k=V+P,O=M-P),a.setItemLayout(N,{angle:C,startAngle:k,endAngle:O,clockwise:S,cx:o,cy:l,r0:u,r:b?Pe(R,_,[u,s]):s}),V=M}),L<Di&&d)if(L<=.001){var T=x/d;a.each(n,function(R,N){if(!isNaN(R)){var C=a.getItemLayout(N);C.angle=T;var M=0,k=0;T<f?(M=c+D*(N+1/2)*T,k=M):(M=c+D*N*T+P,k=c+D*(N+1)*T-P),C.startAngle=M,C.endAngle=k}})}else y=L/E,V=c,a.each(n,function(R,N){if(!isNaN(R)){var C=a.getItemLayout(N),M=C.angle===p?p:R*y,k=0,O=0;M<f?(k=V+D*M/2,O=k):(k=V+P,O=V+D*M-P),C.startAngle=k,C.endAngle=O,V+=D*M}})})}var Sl=Ft(),yv=function(r){z(t,r);function t(e,a,n){var i=r.call(this)||this;i.z2=2;var o=new Me;return i.setTextContent(o),i.updateData(e,a,n,!0),i}return t.prototype.updateData=function(e,a,n,i){var o=this,l=e.hostModel,s=e.getItemModel(a),u=s.getModel("emphasis"),v=e.getItemLayout(a),c=$(Fe(s.getModel("itemStyle"),v,!0),v);if(isNaN(c.startAngle)){o.setShape(c);return}if(i){o.setShape(c);var h=l.getShallow("animationType");l.ecModel.ssr?(ue(o,{scaleX:0,scaleY:0},l,{dataIndex:a,isFrom:!0}),o.originX=c.cx,o.originY=c.cy):h==="scale"?(o.shape.r=v.r0,ue(o,{shape:{r:v.r}},l,a)):n!=null?(o.setShape({startAngle:n,endAngle:n}),ue(o,{shape:{startAngle:v.startAngle,endAngle:v.endAngle}},l,a)):(o.shape.endAngle=v.startAngle,J(o,{shape:{endAngle:v.endAngle}},l,a))}else Oe(o),J(o,{shape:c},l,a);o.useStyle(e.getItemVisual(a,"style")),ce(o,s);var f=(v.startAngle+v.endAngle)/2,g=l.get("selectedOffset"),p=Math.cos(f)*g,d=Math.sin(f)*g,m=s.getShallow("cursor");m&&o.attr("cursor",m),this._updateLabel(l,e,a),o.ensureState("emphasis").shape=$({r:v.r+(u.get("scale")&&u.get("scaleSize")||0)},Fe(u.getModel("itemStyle"),v)),$(o.ensureState("select"),{x:p,y:d,shape:Fe(s.getModel(["select","itemStyle"]),v)}),$(o.ensureState("blur"),{shape:Fe(s.getModel(["blur","itemStyle"]),v)});var y=o.getTextGuideLine(),S=o.getTextContent();y&&$(y.ensureState("select"),{x:p,y:d}),$(S.ensureState("select"),{x:p,y:d}),ie(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},t.prototype._updateLabel=function(e,a,n){var i=this,o=a.getItemModel(n),l=o.getModel("labelLine"),s=a.getItemVisual(n,"style"),u=s&&s.fill,v=s&&s.opacity;
1Ce(i,De(o),{labelFetcher:a.hostModel,labelDataIndex:n,inheritColor:u,defaultOpacity:v,defaultText:e.getFormattedLabel(n,"normal")||a.getName(n)});var c=i.getTextContent();i.setTextConfig({position:null,rotation:null}),c.attr({z2:10});var h=o.get(["label","position"]);if(h!=="outside"&&h!=="outer")i.removeTextGuideLine();else{var f=this.getTextGuideLine();f||(f=new zt,this.setTextGuideLine(f)),jo(this,Jo(o),{stroke:u,opacity:xt(l.get(["lineStyle","opacity"]),v,1)})}},t}(je),mv=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=vt,e.ignoreLabelLineUpdate=!0,e}return t.prototype.render=function(e,a,n,i){var o=e.getData(),l=this._data,s=this.group,u;if(!l&&o.count()>0){for(var v=o.getItemLayout(0),c=1;isNaN(v&&v.startAngle)&&c<o.count();++c)v=o.getItemLayout(c);v&&(u=v.startAngle)}if(this._emptyCircleSector&&s.remove(this._emptyCircleSector),o.count()===0&&e.get("showEmptyCircle")){var h=Sl(e),f=new je({shape:Ct(h)});f.useStyle(e.getModel("emptyCircleStyle").getItemStyle()),this._emptyCircleSector=f,s.add(f)}o.diff(l).add(function(g){var p=new yv(o,g,u);o.setItemGraphicEl(g,p),s.add(p)}).update(function(g,p){var d=l.getItemGraphicEl(p);d.updateData(o,g,u),d.off("click"),s.add(d),o.setItemGraphicEl(g,d)}).remove(function(g){var p=l.getItemGraphicEl(g);ut(p,e,g)}).execute(),gv(e),e.get("animationTypeUpdate")!=="expansion"&&(this._data=o)},t.prototype.dispose=function(){},t.prototype.containPoint=function(e,a){var n=a.getData(),i=n.getItemLayout(0);if(i){var o=e[0]-i.cx,l=e[1]-i.cy,s=Math.sqrt(o*o+l*l);return s<=i.r&&s>=i.r0}},t.type=vt,t}(ae);function Sv(r){return{seriesType:r,reset:function(t,e){var a=t.getData();a.filterSelf(function(n){var i=a.mapDimension("value"),o=a.get(i,n);return!(Ne(o)&&!isNaN(o)&&o<0)})}}}function vp(r){r.registerChartView(mv),r.registerSeriesModel(dl),Co(vt,r.registerAction),r.registerLayout(pv),r.registerProcessor(ba(vt)),r.registerProcessor(Sv(vt))}var bv=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e}return t.prototype.getInitialData=function(e,a){return et(null,this,{useEncodeDefaulter:!0})},t.prototype.getProgressive=function(){var e=this.option.progressive;return e??(this.option.large?5e3:this.get("progressive"))},t.prototype.getProgressiveThreshold=function(){var e=this.option.progressiveThreshold;return e??(this.option.large?1e4:this.get("progressiveThreshold"))},t.prototype.brushSelector=function(e,a,n){return n.point(a.getItemLayout(e))},t.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:""},t.type="series.scatter",t.dependencies=["grid","polar","geo","singleAxis","calendar","matrix"],t.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:Z.color.primary}},universalTransition:{divideShape:"clone"}},t}(se),bl=4,wv=function(){function r(){}return r}(),_v=function(r){z(t,r);function t(e){var a=r.call(this,e)||this;return a._off=0,a.hoverDataIdx=-1,a}return t.prototype.getDefaultShape=function(){return new wv},t.prototype.reset=function(){this.notClear=!1,this._off=0},t.prototype.beforeBrush=function(e){e&&!e.contentRetained&&this.reset()},t.prototype.buildPath=function(e,a){var n=a.points,i=a.size,o=this.symbolProxy,l=o.shape,s=e.getContext?e.getContext():e,u=s&&i[0]<bl,v=this.softClipShape,c;if(u){this._ctx=s;return}for(this._ctx=null,c=this._off;c<n.length;){var h=n[c++],f=n[c++];isNaN(h)||isNaN(f)||v&&!v.contain(h,f)||(l.x=h-i[0]/2,l.y=f-i[1]/2,l.width=i[0],l.height=i[1],o.buildPath(e,l,!0))}this.incremental&&(this._off=c,this.notClear=!0)},t.prototype.afterBrush=function(){var e=this.shape,a=e.points,n=e.size,i=this._ctx,o=this.softClipShape,l;if(i){for(l=this._off;l<a.length;){var s=a[l++],u=a[l++];isNaN(s)||isNaN(u)||o&&!o.contain(s,u)||i.fillRect(s-n[0]/2,u-n[1]/2,n[0],n[1])}this.incremental&&(this._off=l,this.notClear=!0)}},t.prototype.findDataIndex=function(e,a){for(var n=this.shape,i=n.points,o=n.size,l=Math.max(o[0],4),s=Math.max(o[1],4),u=i.length/2-1;u>=0;u--){var v=u*2,c=i[v]-l/2,h=i[v+1]-s/2;if(e>=c&&a>=h&&e<=c+l&&a<=h+s)return u}return-1},t.prototype.contain=function(e,a){var n=this.transformCoordToLocal(e,a),i=this.getBoundingRect
1();if(e=n[0],a=n[1],i.contain(e,a)){var o=this.hoverDataIdx=this.findDataIndex(e,a);return o>=0}return this.hoverDataIdx=-1,!1},t.prototype.getBoundingRect=function(){var e=this._rect;if(!e){for(var a=this.shape,n=a.points,i=a.size,o=i[0],l=i[1],s=1/0,u=1/0,v=-1/0,c=-1/0,h=0;h<n.length;){var f=n[h++],g=n[h++];s=Math.min(f,s),v=Math.max(f,v),u=Math.min(g,u),c=Math.max(g,c)}e=this._rect=new Bt(s-o/2,u-l/2,v-s+o,c-u+l)}return e},t}(xe),Dv=function(){function r(){this.group=new j}return r.prototype.updateData=function(t,e){this._clear(),this._data=t;var a=this._create();a.setShape({points:t.getLayout("points")}),this._setCommon(a,t,e)},r.prototype.updateLayout=function(t){var e=this._data;if(e){var a=e.getLayout("points");this.group.eachChild(function(n){if(n.startIndex!=null){var i=(n.endIndex-n.startIndex)*2,o=n.startIndex*4*2;a=new Float32Array(a.buffer,o,i)}n.setShape("points",a),n.reset(),n.stopAnimation()})}},r.prototype.incrementalPrepareUpdate=function(t){this._clear()},r.prototype.incrementalUpdate=function(t,e,a,n){var i=this._newAdded[0],o=e.getLayout("points"),l=i&&i.shape.points;if(l&&l.length<2e4){var s=l.length,u=new Float32Array(s+o.length);u.set(l),u.set(o,s),i.endIndex=t.end,i.setShape({points:u})}else{this._newAdded=[];var v=this._create();v.startIndex=t.start,v.endIndex=t.end,v.incremental=a,v.setShape({points:o}),this._setCommon(v,e,n)}},r.prototype.eachRendered=function(t){this._newAdded[0]&&t(this._newAdded[0])},r.prototype._create=function(){var t=new _v({cursor:"default"});return t.ignoreCoarsePointer=!0,this.group.add(t),this._newAdded.push(t),t},r.prototype._setCommon=function(t,e,a){var n=e.hostModel;a=a||{};var i=e.getVisual("symbolSize");t.setShape("size",i instanceof Array?i:[i,i]),t.softClipShape=a.clipShape||null,t.symbolProxy=Ke(e.getVisual("symbol"),0,0,0,0),t.setColor=t.symbolProxy.setColor;var o=t.shape.size[0]<bl;t.useStyle(n.getModel("itemStyle").getItemStyle(o?["color","shadowBlur","shadowColor"]:["color"]));var l=e.getVisual("style"),s=l&&l.fill;s&&t.setColor(s);var u=ne(t);u.seriesIndex=n.seriesIndex,t.on("mousemove",function(v){u.dataIndex=null;var c=t.hoverDataIdx;c>
1=0&&(u.dataIndex=c+(t.startIndex||0))})},r.prototype.remove=function(){this._clear()},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r}(),xv=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,a,n){var i=e.getData(),o=this._updateSymbolDraw(i,e);o.updateData(i,dr(e)),this._finished=!0},t.prototype.incrementalPrepareRender=function(e,a,n){var i=e.getData(),o=this._updateSymbolDraw(i,e);o.incrementalPrepareUpdate(i),this._finished=!1},t.prototype.incrementalRender=function(e,a,n){this._symbolDraw.incrementalUpdate(e,a.getData(),We(a),dr(a)),this._finished=e.end===a.getData().count()},t.prototype.updateTransform=function(e,a,n){var i=e.getData();if(this.group.dirty(),this._finished){var o=Sa("").reset(e,a,n);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(dr(e))}else return{update:!0}},t.prototype.eachRendered=function(e){this._symbolDraw&&this._symbolDraw.eachRendered(e)},t.prototype._updateSymbolDraw=function(e,a){var n=this._symbolDraw,i=a.pipelineContext,o=i.large;return(!n||o!==this._isLargeDraw)&&(n&&n.remove(),n=this._symbolDraw=o?new Dv:new er,this._isLargeDraw=o,this.group.removeAll()),this.group.add(n.group),n},t.prototype.remove=function(e,a){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},t.prototype.dispose=function(){},t.type="scatter",t}(ae);function dr(r){return{clipShape:il(r)}}function cp(r){Ka(lu),r.registerSeriesModel(bv),r.registerChartView(xv),r.registerLayout(Sa("scatter"))}function Av(r){var t=r.polar;if(t){Q(t)||(t=[t]);var e=[];G(t,function(a,n){a.indicator?(a.type&&!a.shape&&(a.shape=a.type),r.radar=r.radar||[],Q(r.radar)||(r.radar=[r.radar]),r.radar.push(a)):e.push(a)}),r.polar=e}G(r.series,function(a){a&&a.type==="radar"&&a.polarIndex&&(a.radarIndex=a.polarIndex)})}var va="radar",Iv=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e}return t.prototype.init=function(e){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Ut(le(this.getData,this),le(this.getRawData,this))},t.prototype.getInitialData=function(e,a){return ma(this,{generateCoord:"indicator_",generateCoordCount:1/0})},t.prototype.formatTooltip=function(e,a,n){var i=this.getData(),o=this.coordinateSystem,l=o.getIndicatorAxes(),s=this.getData().getName(e),u=s===""?this.name:s,v=Os(this,e);return Ge("section",{header:u,sortBlocks:!0,blocks:ee(l,function(c){var h=i.get(i.mapDimension(c.dim),e);return Ge("nameValue",{markerType:"subItem",markerColor:v,name:c.name,value:h,sortParam:h})})})},t.prototype.getTooltipPosition=function(e){if(e!=null){for(var a=this.getData(),n=this.coordinateSystem,i=a.getValues(ee(n.dimensions,function(u){return a.mapDimension(u)}),e),o=0,l=i.length;o<l;o++)if(!isNaN(i[o])){var s=n.getIndicatorAxes();return n.coordToPoint(s[o].dataToCoord(i[o]),o)}}},t.type="series."+va,t.dependencies=["radar"],t.defaultOption={z:2,colorBy:"data",coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid",join:"round"},label:{position:"top"},symbolSize:8},t}(se),Lv=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=va,e}return t.prototype.render=function(e,a,n){var i=e.coordinateSystem,o=this.group,l=e.getData(),s=this._data;function u(h,f){var g=h.getItemVisual(f,"symbol")||"circle";if(g!=="none"){var p=To(h.getItemVisual(f,"symbolSize")),d=Ke(g,-1,-1,2,2),m=h.getItemVisual(f,"symbolRotate")||0;return d.attr({style:{strokeNoScale:!0},z2:100,scaleX:p[0]/2,scaleY:p[1]/2,rotation:m*Math.PI/180||0}),d}}function v(h,f,g,p,d,m){g.removeAll();for(var y=0;y<f.length-1;y++){var S=u(p,d);S&&(S.__dimIdx=y,h[y]?(S.setPosition(h[y]),ja[m?"initProps":"updateProps"](S,{x:f[y][0],y:f[y][1]},e,d)):S.setPosition(f[y]),g.add(S))}}function c(h){return ee(h,function(f){return[i.cx,i.cy]})}l.diff(s).add(function(h){var f=l.getItemLayout(h);if(f){var g=new vn,p=new zt,d={shape:{points:f}};g.shape.points=c(f),p.shape.points=c(f),ue(g,d,e,h),ue(p,d,e,h);var m=new j,y=new j;m.add(p),m.add(g),m.add(y),v(p.shape.points,f,y,l,h,!0),l.setItemGraphicEl(h,m)}}).update(function(h,f){var g=s.getItemGraphicEl(f),p=g.childAt(0),d=g.childAt(1),m=g.childAt(2),y={shape:{points:l.getItemLayout(h)}};y.shape.points&&(v(p.shape.points,y.shape.points,m,l,h,!1),Oe(d),Oe(p),J(p,y,e),J(d,y,e),l.setItemGraphicEl(h,g))}).remove(function(h){o.remove(s.getItemGraphicEl(h))}).execute(),l.eachItemGraphicEl(function(h,f){var g=l.getItemModel(f),p=h.childAt(0),d=h.childAt(1),m=h.childAt(2),y=l.getItemVisual(f,"style"),S=y.fill;o.add(h),p.useStyle(Ve(g.getModel("lineStyle").getLineStyle(),{fill:"none",stroke:S})),ce(p,g,"lineStyle"),ce(d,g,"areaStyle");var b=g.getModel("areaStyle"),w=b.isEmpty()&&b.parentModel.isEmpty();
1d.ignore=w,G(["emphasis","select","blur"],function(D){var A=g.getModel([D,"areaStyle"]),P=A.isEmpty()&&A.parentModel.isEmpty();d.ensureState(D).ignore=P&&w;var I=g.getModel([D,"lineStyle"]).getLineStyle();p.ensureState(D).style=I;var x=A.getAreaStyle();d.ensureState(D).style=x;var L=g.getModel([D,"itemStyle"]).getItemStyle();m.eachChild(function(E){E.ensureState(D).style=Ct(L)})}),d.useStyle(Ve(g.getModel("areaStyle").getAreaStyle(),{fill:S,opacity:.7,decal:y.decal}));var _=g.getModel("emphasis");m.eachChild(function(D){if(D instanceof pa){var A=D.style;D.useStyle($({image:A.image,x:A.x,y:A.y,width:A.width,height:A.height},y))}else D.useStyle(y),D.setColor(S),D.style.strokeNoScale=!0;var P=l.getStore().get(l.getDimensionIndex(D.__dimIdx),f);(P==null||isNaN(P))&&(P=""),Ce(D,De(g),{labelFetcher:l.hostModel,labelDataIndex:f,labelDimIndex:D.__dimIdx,defaultText:P,inheritColor:S,defaultOpacity:y.opacity})}),ie(h,_.get("focus"),_.get("blurScope"),_.get("disabled"))}),this._data=l},t.prototype.remove=function(){this.group.removeAll(),this._data=null},t.type=va,t}(ae),Cv=he(va,Tv);function Tv(r){r.eachSeriesByType(va,function(t){var e=t.getData(),a=[],n=t.coordinateSystem;if(n){var i=n.getIndicatorAxes();G(i,function(o,l){e.each(e.mapDimension(i[l].dim),function(s,u){a[u]=a[u]||[];var v=n.dataToPoint(s,l);a[u][l]=xi(v)?v:Ai(n)})}),e.each(function(o){var l=cs(a[o],function(s){return xi(s)})||Ai(n);a[o].push(l.slice()),e.setItemLayout(o,a[o])})}})}function xi(r){return!isNaN(r[0])&&!isNaN(r[1])}function Ai(r){return[r.cx,r.cy]}function hp(r){Ka(su),r.registerChartView(Lv),r.registerSeriesModel(Iv),r.registerLayout(Cv),r.registerProcessor(ba("radar")),r.registerPreprocessor(Av)}var Pv=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=Ba,e}return t.prototype.render=function(e,a,n,i){if(!(i&&i.type==="mapToggleSelect"&&i.from===this.uid)){var o=this.group;if(o.removeAll(),!e.getHostGeoModel()){var l=this._mapDraw;l&&i&&i.type==="geoRoam"&&l.resetForLabelLayout(),i&&i.type==="geoRoam"&&i.componentType==="series"&&i.seriesId===e.id?l&&o.add(l.group):ai(e)?(l=l||(this._mapDraw=new uu(n)),o.add(l.group),l.draw(e,a,n,this,i)):this._clearMapDraw(),e.get("showLegendSymbol")&&a.getComponent("legend")&&this._renderSymbols(e)}}},t.prototype.__updateOnOwnRoam=function(e,a,n){var i=this._mapDraw;ai(a)&&i&&i.__updateOnOwnRoam(a)},t.prototype.remove=function(){this._clearMapDraw(),this.group.removeAll()},t.prototype.dispose=function(){this._clearMapDraw()},t.prototype._clearMapDraw=function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},t.prototype._renderSymbols=function(e){var a=e.originalData,n=this.group;a.each(a.mapDimension("value"),function(i,o){if(!isNaN(i)){var l=a.getItemLayout(o);if(!(!l||!l.point)){var s=l.point,u=l.offset,v=new Po({style:{fill:e.getData().getVisual("style").fill},shape:{cx:s[0]+u*9,cy:s[1],r:3},silent:!0,z2:8+(u?0:ya+1)});if(!u){var c=za(e.seriesGroup).getData(),h=a.getName(o),f=c.indexOfName(h),g=a.getItemModel(o),p=g.getModel("label"),d=c.getItemGraphicEl(f);Ce(v,De(g),{labelFetcher:{getFormattedLabel:function(m,y){return e.getFormattedLabel(f,y)}},defaultText:h}),v.disableLabelAnimation=!0,p.get("position")||v.setTextConfig({position:"bottom"}),d.onHoverStateChange=function(m){Va(v,m)}}n.add(v)}}})},t.type=Ba,t}(ae),Ev=he(Ba,Rv);function Rv(r){G(Fo(r),function(t,e){if(!(!za(t)||!vu(e))){var a={};G(t.f,function(i){var o=i.coordinateSystem,l=i.originalData;i.get("showLegendSymbol")&&r.getComponent("legend")&&l.each(l.mapDimension("value"),function(s,u){var v=l.getName(u),c=o.getRegion(v);if(!(!c||isNaN(s))){var h=a[v]||0,f=o.dataToPoint(c.getCenter());a[v]=h+1,l.setItemLayout(u,{point:f,offset:h})}})});var n=za(t).getData();n.each(function(i){var o=n.getName(i),l=n.getItemLayout(i)||{};l.showLabel=!a[o],n.setItemLayout(i,l)})}})}function Nv(r,t){var e={};return G(r,function(a){a.each(a.mapDimension("value"),function(n,i){var o="ec-"+a.getName(i);e[o]=e[o]||[],isNaN(n)||e[o].push(n)})}),r[0].map(r[0].mapDimension("value"),function(a,n){for(var i="ec-"+r[0].getName(n),o=0,l=1/0,s=-1/0,u=e[i].length,v=0;v<u;v++)l=Math.min(l,e[i][v]),s=Math.max(s,e[i][v]),o+=e[i][v];var c;return t==="min"?c=l:t==="max"?c=s:t==="average"?c=o/u:c=o,u===0?NaN:c})}var Mv=he(Ba,Vv);function Vv(r){G(Fo(r),function(t){var e=za(t);if(e){var a=Nv(ee(t.f,function(n){return n.getData()}),e.get("mapValueCalculation"));G(t.f,function(n){n.seriesGroup=t,n.originalData=n.getData(),n.setData(a.cloneShallow())})}})}function fp(r){Ka(cu),r.registerChartView(Pv),r.registerSeriesModel(hu),r.registerLayout(Ev),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,Mv),C
1o("map",r.registerAction)}function kv(r){var t=r;t.hierNode={defaultAncestor:null,ancestor:t,prelim:0,modifier:0,change:0,shift:0,i:0,thread:null};for(var e=[t],a,n;a=e.pop();)if(n=a.children,a.isExpand&&n.length)for(var i=n.length,o=i-1;o>=0;o--){var l=n[o];l.hierNode={defaultAncestor:null,ancestor:l,prelim:0,modifier:0,change:0,shift:0,i:o,thread:null},e.push(l)}}function Ov(r,t){var e=r.isExpand?r.children:[],a=r.parentNode.children,n=r.hierNode.i?a[r.hierNode.i-1]:null;if(e.length){Bv(r);var i=(e[0].hierNode.prelim+e[e.length-1].hierNode.prelim)/2;n?(r.hierNode.prelim=n.hierNode.prelim+t(r,n),r.hierNode.modifier=r.hierNode.prelim-i):r.hierNode.prelim=i}else n&&(r.hierNode.prelim=n.hierNode.prelim+t(r,n));r.parentNode.hierNode.defaultAncestor=zv(r,n,r.parentNode.hierNode.defaultAncestor||a[0],t)}function Gv(r){var t=r.hierNode.prelim+r.parentNode.hierNode.modifier;r.setLayout({x:t},!0),r.hierNode.modifier+=r.parentNode.hierNode.modifier}function Ii(r){return arguments.length?r:Wv}function qt(r,t){return r-=Math.PI/2,{x:t*Math.cos(r),y:t*Math.sin(r)}}function Bv(r){for(var t=r.children,e=t.length,a=0,n=0;--e>=0;){var i=t[e];i.hierNode.prelim+=a,i.hierNode.modifier+=a,n+=i.hierNode.change,a+=i.hierNode.shift+n}}function zv(r,t,e,a){if(t){for(var n=r,i=r,o=i.parentNode.children[0],l=t,s=n.hierNode.modifier,u=i.hierNode.modifier,v=o.hierNode.modifier,c=l.hierNode.modifier;l=yr(l),i=mr(i),l&&i;){n=yr(n),o=mr(o),n.hierNode.ancestor=r;var h=l.hierNode.prelim+c-i.hierNode.prelim-u+a(l,i);h>0&&(Hv(Fv(l,r,e),r,h),u+=h,s+=h),c+=l.hierNode.modifier,u+=i.hierNode.modifier,s+=n.hierNode.modifier,v+=o.hierNode.modifier}l&&!yr(n)&&(n.hierNode.thread=l,n.hierNode.modifier+=c-s),i&&!mr(o)&&(o.hierNode.thread=i,o.hierNode.modifier+=u-v,e=r)}return e}function yr(r){var t=r.children;return t.length&&r.isExpand?t[t.length-1]:r.hierNode.thread}function mr(r){var t=r.children;return t.length&&r.isExpand?t[0]:r.hierNode.thread}function Fv(r,t,e){return r.hierNode.ancestor.parentNode===t.parentNode?r.hierNode.ancestor:e}function Hv(r,t,e){var a=e/(t.hierNode.i-r.hierNode.i);t.hierNode.change-=a,t.hierNode.shift+=e,t.hierNode.modifier+=e,t.hierNode.prelim+=e,r.hierNode.change+=a}function Wv(r,t){return r.parentNode===t.parentNode?1:2}var Re=Ft();function wl(r){var t=r.mainData,e=r.datas;e||(e={main:t},r.datasAttr={main:"data"}),r.datas=r.mainData=null,_l(t,e,r),G(e,function(a){G(t.TRANSFERABLE_METHODS,function(n){a.wrapMethod(n,Xe(Uv,r))})}),t.wrapMethod("cloneShallow",Xe($v,r)),G(t.CHANGABLE_METHODS,function(a){t.wrapMethod(a,Xe(Yv,r))}),hs(e[t.dataType]===t)}function Uv(r,t){if(qv(this)){var e=$({},Re(this).datas);e[this.dataType]=t,_l(t,e,r)}else yn(t,this.dataType,Re(this).mainData,r);return t}function Yv(r,t){return r.struct&&r.struct.update(),t}function $v(r,t){return G(Re(t).datas,function(e,a){e!==t&&yn(e.cloneShallow(),a,t,r)}),t}function Xv(r){var t=Re(this).mainData;return r==null||t==null?t:Re(t).datas[r]}function Zv(){var r=Re(this).mainData;return r==null?[{data:r}]:ee(fs(Re(r).datas),function(t){return{type:t,data:Re(r).datas[t]}})}function qv(r){return Re(r).mainData===r}function _l(r,t,e){Re(r).datas={},G(t,function(a,n){yn(a,n,r,e)})}function yn(r,t,e,a){Re(e).datas[t]=r,Re(r).mainData=e,r.dataType=t,a.struct&&(r[a.structAttr]=a.struct,a.struct[a.datasAttr[t]]=r),r.getLinkedData=Xv,r.getLinkedDataAll=Zv}var Kv=function(){function r(t,e){this.depth=0,this.height=0,this.dataIndex=-1,this.children=[],this.viewChildren=[],this.isExpand=!1,this.name=t||"",this.hostTree=e}return r.prototype.isRemoved=function(){return this.dataIndex<0},r.prototype.eachNode=function(t,e,a){Ie(t)&&(a=e,e=t,t=null),t=t||{},Le(t)&&(t={order:t});var n=t.order||"preorder",i=this[t.attr||"children"],o;n==="preorder"&&(o=e.call(a,this));for(var l=0;!o&&l<i.length;l++)i[l].eachNode(t,e,a);n==="postorder"&&e.call(a,this)},r.prototype.updateDepthAndHeight=function(t){var e=0;this.depth=t;for(var a=0;a<this.children.length;a++){var n=this.children[a];n.updateDepthAndHeight(t+1),n.height>e&&(e=n.height)}this.height=e+1},r.prototype.getNodeById=function(t){if(this.getId()===t)return this;for(var e=0,a=this.children,n=a.length;e<n;e++){var i=a[e].getNodeById(t);if(i)return i}},r.prototype.contains=function(t){if(t===this)return!0;for(var e=0,a=this.children,n=a.length;e<n;e++){var i=a[e].contains(t);if(i)return i}},r.prototype.getAncestors=function(t){for(var e=[],a=t?this:this.parentNode;a;)e.push(a),a=a.parentNode;return e.reverse(),e},r.prototype.getAncestorsIndices=function(){for(var t=[],e=this;e;)t.push(e.dataIndex),e=e.parentNode;return t.reverse(),t},r.prototype.getDescendantIndices=function(){var t=[];return this.eachNode(function(e){t.push(e.dataIndex)}),t},r.prototype.getValue=function(t){var e=this.hostTree.data;return e.getStore().get(e.getDimensionIndex(t||"value"),this.dataIndex)},r.prototype.setLayout=function(t,e){this.dataIndex>=0&&this.hostTree.data.setItemLayout(this.dataIndex,t,e)},r.prototype.getLayout=function(){return this.hostTree.data.getItemLayout(this.dataIndex)},r.prototype.getModel=function(t){if(!(this.dataIndex<0)){var e=this.hostTree,a=e.data.getItemModel(this.dataIndex);return a.getModel(t)}},r.prototype.getLevelModel=function(){return(this.hostTree.levelModels||[])[this.depth]},r.prototype.setVisual=function(t,e){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,t,e)},r.prototype.getVisual=function(t){return this.hostTree.data.getItemVisual(this.dataIndex,t)},r.prototype.getRawIndex=function(){return this.hostTree.data.getRawIndex(this.dataIndex)},r.prototype.getId=function(){return this.hostTree.data.getId(this.dataIndex)},r.prototype.getChildIndex=function(){if(this.parentNode){for(var t=this.parentNode.children,e=0;e<t.length;++e)if(t[e]===this)return e;return-1}return-1},r.prototype.isAncestorOf=function(t){for(var e=t.parentNode;e;){if(e===this)return!0;e=e.parentNode}return!1},r.prototype.isDescendantOf=function(t){return t!==this&&t.isAncestorOf(this)},r}(),mn=function(){function r(t){this.type="tree",this._nodes=[],this.hostModel=t}return r.prototype.eachNode=function(t,e,a){this.root.eachNode(t,e,a)},r.prototype.getNodeByDataIndex=function(t){var e=this.data.getRawIndex(t);return this._nodes[e]},r.prototype.getNodeById=function(t){return this.root.getNodeById(t)},r.prototype.update=function(){for(var t=this.data,e=this._nodes,a=0,n=e.length;a<n;a++)e[a].dataIndex=-1;for(var a=0,n=t.count();a<n;a++)e[t.getRawIndex(a)].dataIndex=a},r.prototype.clearLayouts=function(){this.data.clearItemLayouts()},r.createTree=function(t,e,a){var n=new r(e),i=[],o=1;l(t);function l(v,c){var h=v.value;o=Math.max(o,Q(h)?h.length:1),i.push(v);var f=new Kv(Ja(v.name,""),n);c?jv(f,c):n.root=f,n._nodes.push(f);var g=v.children;if(g)for(var p=0;p<g.length;p++)l(g[p],f)}n.root.updateDepthAndHeight(0);var s=cn(i,{coordDimensions:["value"],dimensionsCount:o}).dimensions,u=new Mt(s,e);return u.initData(i),a&&a(u),wl({mainData:u,struct:n,structAttr:"tree"}),n.update(),n},r}();function jv(r,t){var e=t.children;r.parentNode!==t&&(e.push(r),r.parentNode=t)}function ca(r,t,e){if(r&&ke(t,r.type)>=0){var a=e.getData().tree.root,n=r.targetNode;if(Le(n)&&(n=a.getNodeById(n)),n&&a.contains(n))return{node:n};var i=r.targetNodeId;if(i!=null&&(n=a.getNodeById(i)))return{node:n}}}function Dl(r){for(var t=[];r;)r=r.parentNode,r&&t.push(r);return t.reverse()}function Sn(r,t){var e=Dl(r);return ke(e,t)>=0}function nr(r,t){for(var e=[];r;){var a=r.dataIndex;e.push({name:r.name,dataIndex:a,value:t.getRawValue(a)}),r=r.parentNode}return e.reverse(),e}var _t="tree",Jv=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e.ignoreStyleOnData=!0,e}return t.prototype.getInitialData=function(e){var a={name:e.name,children:e.data},n=e.leaves||{},i=new ht(n,this,this.ecModel),o=mn.createTree(a,this,l);function l(c){c.wrapMethod("getItemModel",function(h,f){var g=o.getNodeByDataIndex(f);return g&&g.children.length&&g.isExpand||(h.parentModel=i),h})}var s=0;o.eachNode("preorder",function(c){c.depth>
1s&&(s=c.depth)});var u=e.expandAndCollapse,v=u&&e.initialTreeDepth>=0?e.initialTreeDepth:s;return o.root.eachNode("preorder",function(c){var h=c.hostTree.data.getRawDataItem(c.dataIndex);c.isExpand=h&&h.collapsed!=null?!h.collapsed:c.depth<=v}),o.data},t.prototype.getOrient=function(){var e=this.get("orient");return e==="horizontal"?e="LR":e==="vertical"&&(e="TB"),e},t.prototype.formatTooltip=function(e,a,n){for(var i=this.getData().tree,o=i.root.children[0],l=i.getNodeByDataIndex(e),s=l.getValue(),u=l.name;l&&l!==o;)u=l.parentNode.name+"."+u,l=l.parentNode;return Ge("nameValue",{name:u,value:s,noValue:isNaN(s)||s==null})},t.prototype.getDataParams=function(e){var a=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(e);return a.treeAncestors=nr(n,this),a.collapsed=!n.isExpand,a},t.prototype.__ownRoamView=function(){return this.coordinateSystem},t.type="series."+_t,t.layoutMode="box",t.defaultOption={z:2,coordinateSystemUsage:"box",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",edgeShape:"curve",edgeForkPosition:"50%",roam:!1,roamTrigger:"global",nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:Z.color.borderTint,width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderWidth:1.5},label:{show:!0},animationEasing:"linear",animationDuration:700,animationDurationUpdate:500},t}(se),Qv=function(){function r(){this.parentPoint=[],this.childPoints=[]}return r}(),ec=function(r){z(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultStyle=function(){return{stroke:Z.color.neutral99,fill:null}},t.prototype.getDefaultShape=function(){return new Qv},t.prototype.buildPath=function(e,a){var n=a.childPoints,i=n.length,o=a.parentPoint,l=n[0],s=n[i-1];if(i===1){e.moveTo(o[0],o[1]),e.lineTo(l[0],l[1]);return}var u=a.orient,v=u==="TB"||u==="BT"?0:1,c=1-v,h=U(a.forkPosition,1),f=[];f[v]=o[v],f[c]=o[c]+(s[c]-o[c])*h,e.moveTo(o[0],o[1]),e.lineTo(f[0],f[1]),e.moveTo(l[0],l[1]),f[v]=l[v],e.lineTo(f[0],f[1]),f[v]=s[v],e.lineTo(f[0],f[1]),e.lineTo(s[0],s[1]);for(var g=1;g<i-1;g++){var p=n[g];e.moveTo(p[0],p[1]),f[v]=p[v],e.lineTo(f[0],f[1])}},t}(xe),tc=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=_t,e._mainGroup=new j,e}return t.prototype.init=function(e,a){this._controller=new rr(a.getZr()),this.group.add(this._mainGroup),this._firstRender=!0},t.prototype.render=function(e,a,n){var i=e.getData(),o=e.layoutInfo,l=this._mainGroup,s=e.get("layout");s==="radial"?(l.x=o.x+o.width/2,l.y=o.y+o.height/2):(l.x=o.x,l.y=o.y),this._updateViewCoordSys(e,n),fn(e,n,this._controller,Ho(this.group),null);var u=this._data;i.diff(u).add(function(v){Li(i,v)&&Ci(i,v,null,l,e)}).update(function(v,c){var h=u.getItemGraphicEl(c);if(!Li(i,v)){h&&Pi(u,c,h,l,e);return}Ci(i,v,h,l,e)}).remove(function(v){var c=u.getItemGraphicEl(v);c&&Pi(u,v,c,l,e)}).execute(),this._updateNodeAndLinkScale(e),e.get("expandAndCollapse")===!0&&i.eachItemGraphicEl(function(v,c){v.off("click").on("click",function(){n.dispatchAction({type:"treeExpandAndCollapse",seriesId:e.id,dataIndex:c})})}),this._data=i,this._firstRender=!1},t.prototype.__updateOnOwnRoam=function(e,a,n){Vt(this.group,kt,a.coordinateSystem,null),Wo(e)&&this._updateNodeAndLinkScale(a)},t.prototype._updateViewCoordSys=function(e,a){var n=e.getData(),i=[];n.each(function(c){var h=n.getItemLayout(c);h&&!isNaN(h.x)&&!isNaN(h.y)&&i.push([+h.x,+h.y])});var o=[],l=[];mo(i,o,l);var s=this._min,u=this._max;l[0]-o[0]===0&&(o[0]=s?s[0]:o[0]-1,l[0]=u?u[0]:l[0]+1),l[1]-o[1]===0&&(o[1]=s?s[1]:o[1]-1,l[1]=u?u[1]:l[1]+1);var v=e.coordinateSystem=gn(e,a,o[0],o[1],l[0]-o[0],l[1]-o[1]);Vt(this.group,kt,v,this._firstRender?null:e),this._min=o,this._max=l},t.prototype._updateNodeAndLinkScale=function(e){var a=e.getData(),n=Uo(e.coordinateSystem,e);a.eachItemGraphicEl(function(i,o){i.setSymbolScale(n)})},t.prototype.dispose=function(){this._controller&&this._controller.dispose()},t.prototype.remove=function(){this._mainGroup.removeAll(),this._data=null},t.type=_t,t}(ae);function Li(r,t){var e=r.getItemLayout(t);return e&&!isNaN(e.x)&&!isNaN(e.y)}function Ci(r,t,e,a,n){var i=!e,o=r.tree.getNodeByDataIndex(t),l=o.getModel(),s=o.getVisual("style").fill,u=o.isExpand===!1&&o.children.length!==0?s:Z.color.neutral00,v=r.tree.root,c=o.parentNode===v?o:o.parentNode||o,h=r.getItemGraphicEl(c.dataIndex),f=c.getLayout(),g=h?{x:h.__oldX,y:h.__oldY,rawX:h.__radialOldRawX,rawY:h.__radialOldRawY}:f,p=o.getLayout();i?(e=new tr(r,t,null,{symbolInnerColor:u,useNameLabel:!0}),e.x=g.x,e.y=g.y):e.updateData(r,t,null,{symbolInnerColor:u,useNameLabel:!0}),e.__radialOldRawX=e.__radialRawX,e.__radialOldRawY=e.__radialRawY,e.__radialRawX=p.rawX,e.__radialRawY=p.rawY,a.add(e),r.setItemGraphicEl(t,e),e.__oldX=e.x,e.__oldY=e.y,J(e,{x:p.x,y:p.y},n);var d=e.getSymbolPath();if(n.get("layout")==="radial"){var m=v.children[0],y=m.getLayout(),S=m.children.length,b=void 0,w=void 0;if(p.x===y.x&&o.isExpand===!0&&m.children.length){var _={x:(m.children[0].getLayout().x+m.children[S-1].getLayout().x)/2,y:(m.children[0].getLayout().y+m.children[S-1].getLayout().y)/2};b=Math.atan2(_.y-y.y,_.x-y.x),b<0&&(b=Math.PI*2+b),w=_.x<y.x,w&&(b=b-Math.PI)}else b=Math.atan2(p.y-y.y,p.x-y.x),b<0&&(b=Math.PI*2+b),o.children.length===0||o.children.length!==0&&o.isExpand===!1?(w=p.x<y.x,w&&(b=b-Math.PI)):(w=p.x>y.x,w||(b=b-Math.PI));var D=w?"left":"right",A=l.getModel("label"),P=A.get("rotate"),I=P*(Math.PI/180),x=d.getTextContent();x&&(d.setTextConfig({position:A.get("position")||D,rotation:P==null?-b:I,origin:"center"}),x.setStyle("verticalAlign","middle"))}
1var L=l.get(["emphasis","focus"]),E=L==="relative"?Na(o.getAncestorsIndices(),o.getDescendantIndices()):L==="ancestor"?o.getAncestorsIndices():L==="descendant"?o.getDescendantIndices():null;E&&(ne(e).focus=E),ac(n,o,v,e,g,f,p,a),e.__edge&&(e.onHoverStateChange=function(V){if(V!=="blur"){var T=o.parentNode&&r.getItemGraphicEl(o.parentNode.dataIndex);T&&T.hoverState===Gs||Va(e.__edge,V)}})}function ac(r,t,e,a,n,i,o,l){var s=t.getModel(),u=r.get("edgeShape"),v=r.get("layout"),c=r.getOrient(),h=r.get(["lineStyle","curveness"]),f=r.get("edgeForkPosition"),g=s.getModel("lineStyle").getLineStyle(),p=a.__edge;if(u==="curve")t.parentNode&&t.parentNode!==e&&(p||(p=a.__edge=new Bs({shape:qr(v,c,h,n,n)})),J(p,{shape:qr(v,c,h,i,o)},r));else if(u==="polyline"&&v==="orthogonal"&&t!==e&&t.children&&t.children.length!==0&&t.isExpand===!0){for(var d=t.children,m=[],y=0;y<d.length;y++){var S=d[y].getLayout();m.push([S.x,S.y])}p||(p=a.__edge=new ec({shape:{parentPoint:[o.x,o.y],childPoints:[[o.x,o.y]],orient:c,forkPosition:f}})),J(p,{shape:{parentPoint:[o.x,o.y],childPoints:m}},r)}p&&!(u==="polyline"&&!t.isExpand)&&(p.useStyle(Ve({strokeNoScale:!0,fill:null},g)),ce(p,s,"lineStyle"),Oa(p),l.add(p))}function Ti(r,t,e,a,n){var i=t.tree.root,o=xl(i,r),l=o.source,s=o.sourceLayout,u=t.getItemGraphicEl(r.dataIndex);if(u){var v=t.getItemGraphicEl(l.dataIndex),c=v.__edge,h=u.__edge||(l.isExpand===!1||l.children.length===1?c:void 0),f=a.get("edgeShape"),g=a.get("layout"),p=a.get("orient"),d=a.get(["lineStyle","curveness"]);h&&(f==="curve"?ka(h,{shape:qr(g,p,d,s,s),style:{opacity:0}},a,{cb:function(){e.remove(h)},removeOpt:n}):f==="polyline"&&a.get("layout")==="orthogonal"&&ka(h,{shape:{parentPoint:[s.x,s.y],childPoints:[[s.x,s.y]]},style:{opacity:0}},a,{cb:function(){e.remove(h)},removeOpt:n}))}}function xl(r,t){for(var e=t.parentNode===r?t:t.parentNode||t,a;a=e.getLayout(),a==null;)e=e.parentNode===r?e:e.parentNode||e;return{source:e,sourceLayout:a}}function Pi(r,t,e,a,n){var i=r.tree.getNodeByDataIndex(t),o=r.tree.root,l=xl(o,i).sourceLayout,s={duration:n.get("animationDurationUpdate"),easing:n.get("animationEasingUpdate")};ka(e,{x:l.x+1,y:l.y+1},n,{cb:function(){a.remove(e),r.setItemGraphicEl(t,null)},removeOpt:s}),e.fadeOut(null,r.hostModel,{fadeLabel:!0,animation:s}),G(i.children,function(u){Ti(u,r,a,n,s)}),Ti(i,r,a,n,s)}function qr(r,t,e,a,n){var i,o,l,s,u,v,c,h;if(r==="radial"){u=a.rawX,c=a.rawY,v=n.rawX,h=n.rawY;var f=qt(u,c),g=qt(u,c+(h-c)*e),p=qt(v,h+(c-h)*e),d=qt(v,h);return{x1:f.x||0,y1:f.y||0,x2:d.x||0,y2:d.y||0,cpx1:g.x||0,cpy1:g.y||0,cpx2:p.x||0,cpy2:p.y||0}}else u=a.x,c=a.y,v=n.x,h=n.y,(t==="LR"||t==="RL")&&(i=u+(v-u)*e,o=c,l=v+(u-v)*e,s=h),(t==="TB"||t==="BT")&&(i=u,o=c+(h-c)*e,l=v,s=h+(c-h)*e);return{x1:u,y1:c,x2:v,y2:h,cpx1:i,cpy1:o,cpx2:l,cpy2:s}}function rc(r,t,e){for(var a=[r],n=[],i;i=a.pop();)if(n.push(i),i.isExpand){var o=i.children;if(o.length)for(var l=0;l<o.length;l++)a.push(o[l])}for(;i=n.pop();)t(i,e)}function Yt(r,t){for(var e=[r],a;a=e.pop();)if(t(a),a.isExpand){var n=a.children;if(n.length)for(var i=n.length-1;i>=0;i--)e.push(n[i])}}function nc(r,t){r.eachSeriesByType("tree",function(e){ic(e,t)})}function ic(r,t){var e=Ht(r,t).refContainer,a=Wt(r.getBoxLayoutParams(),e);r.layoutInfo=a;var n=r.get("layout"),i=0,o=0,l=null;n==="radial"?(i=2*Math.PI,o=Math.min(a.height,a.width)/2,l=Ii(function(b,w){return(b.parentNode===w.parentNode?1:2)/b.depth})):(i=a.width,o=a.height,l=Ii());var s=r.getData().tree.root,u=s.children[0];if(u){kv(s),rc(u,Ov,l),s.hierNode.modifier=-u.hierNode.prelim,Yt(u,Gv);var v=u,c=u,h=u;Yt(u,function(b){var w=b.getLayout().x;w<v.getLayout().x&&(v=b),w>c.getLayout().x&&(c=b),b.depth>h.depth&&(h=b)});var f=v===c?1:l(v,c)/2,g=f-v.getLayout().x,p=0,d=0,m=0,y=0;if(n==="radial")p=i/(c.getLayout().x+f+g),d=o/(h.depth-1||1),Yt(u,function(b){m=(b.getLayout().x+g)*p,y=(b.depth-1)*d;var w=qt(m,y);b.setLayout({x:w.x,y:w.y,rawX:m,rawY:y},!0)});else{var S=r.getOrient();S==="RL"||S==="LR"?(d=o/(c.getLayout().x+f+g),p=i/(h.depth-1||1),Yt(u,function(b){y=(b.getLayout().x+g)*d,m=S==="LR"?(b.depth-1)*p:i-(b.depth-1)*p,b.setLayout({x:m,y},!0)})):(S==="TB"||S==="BT")&&(p=i/(c.getLayout().x+f+g),d=o/(h.depth-1||1),Yt(u,function(b){m=(b.getLayout().x+g)*p,y=S==="TB"?(b.depth-1)*d:o-(b.depth-1)*d,b.setLayout({x:m,y},!0)}))}}}function oc(r){r.registerAction({type:"treeExpandAndCollapse",event:"treeExpandAndCollapse",update:"update"},function(t,e){e.eachComponent({mainType:aa,subType:_t,query:t},function(a){var n=t.dataIndex,i=a.getData().tree,o=i.getNodeByDataIndex(n);o.isExpand=!o.isExpand})}),pn(r,aa,_t)}var lc=he(_t,sc);function sc(r){r.eachSeriesByType(_t,function(t){var e=t.getData(),a=e.tree;a.eachNode(function(n){var i=n.getModel(),o=i.getModel("itemStyle").getItemStyle(),l=e.ensureUniqueItemVisual(n.dataIndex,"style");$(l,o)})})}function gp(r){r.registerChartView(tc),r.registerSeriesModel(Jv),r.registerLayout(nc),r.registerVisual(lc),oc(r)}
1var Ei=["treemapZoomToNode","treemapRender","treemapMove"];function uc(r){for(var t=0;t<Ei.length;t++)r.registerAction({type:Ei[t],update:"updateView"},Fr);r.registerAction({type:"treemapRootToNode",update:"updateView"},function(e,a){a.eachComponent({mainType:"series",subType:"treemap",query:e},n);function n(i,o){var l=["treemapZoomToNode","treemapRootToNode"],s=ca(e,l,i);if(s){var u=i.getViewRoot();u&&(e.direction=Sn(u,s.node)?"rollUp":"drillDown"),i.resetViewRoot(s.node)}}})}function Al(r){var t=r.getData(),e=t.tree,a={};e.eachNode(function(n){for(var i=n;i&&i.depth>1;)i=i.parentNode;var o=zs(r.ecModel,i.name||i.dataIndex+"",a);n.setVisual("decal",o)})}var vc=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.preventUsingHoverLayer=!0,e}return t.prototype.getInitialData=function(e,a){var n={name:e.name,children:e.data};Il(n);var i=e.levels||[],o=this.designatedVisualItemStyle={},l=new ht({itemStyle:o},this,a);i=e.levels=cc(i,a);var s=ee(i||[],function(c){return new ht(c,l,a)},this),u=mn.createTree(n,this,v);function v(c){c.wrapMethod("getItemModel",function(h,f){var g=u.getNodeByDataIndex(f),p=g?s[g.depth]:null;return h.parentModel=p||l,h})}return u.data},t.prototype.optionUpdated=function(){this.resetViewRoot()},t.prototype.formatTooltip=function(e,a,n){var i=this.getData(),o=this.getRawValue(e),l=i.getName(e);return Ge("nameValue",{name:l,value:o})},t.prototype.getDataParams=function(e){var a=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(e);return a.treeAncestors=nr(n,this),a.treePathInfo=a.treeAncestors,a},t.prototype.setLayoutInfo=function(e){this.layoutInfo=this.layoutInfo||{},$(this.layoutInfo,e)},t.prototype.mapIdToIndex=function(e){var a=this._idIndexMap;a||(a=this._idIndexMap=Nt(),this._idIndexMapCount=0);var n=a.get(e);return n==null&&a.set(e,n=this._idIndexMapCount++),n},t.prototype.getViewRoot=function(){return this._viewRoot},t.prototype.resetViewRoot=function(e){e?this._viewRoot=e:e=this._viewRoot;var a=this.getRawData().tree.root;(!e||e!==a&&!a.contains(e))&&(this._viewRoot=a)},t.prototype.enableAriaDecal=function(){Al(this)},t.type="series.treemap",t.layoutMode="box",t.defaultOption={progressive:0,coordinateSystemUsage:"box",left:Z.size.l,top:Z.size.xxxl,right:Z.size.l,bottom:Z.size.xxxl,sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"▶",zoomToNodeRatio:.32*.32,scaleLimit:{max:5,min:.2},roam:!0,roamTrigger:"global",nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",bottom:Z.size.m,emptyItemWidth:25,itemStyle:{color:Z.color.backgroundShade,textStyle:{color:Z.color.secondary}},emphasis:{itemStyle:{color:Z.color.background}}},label:{show:!0,distance:0,padding:5,position:"inside",color:Z.color.neutral00,overflow:"truncate"},upperLabel:{show:!1,position:[0,"50%"],height:20,overflow:"truncate",verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:Z.color.neutral00,borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],overflow:"truncate",verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]},t}(se);function Il(r){var t=0;G(r.children,function(a){Il(a);var n=a.value;Q(n)&&(n=n[0]),t+=n});var e=r.value;Q(e)&&(e=e[0]),(e==null||isNaN(e))&&(e=t),e<0&&(e=0),Q(r.value)?r.value[0]=e:r.value=e}function cc(r,t){var e=Yn(t.get("color")),a=Yn(t.get(["aria","decal","decals"]));if(e){r=r||[];var n,i;G(r,function(l){var s=new ht(l),u=s.get("color"),v=s.get("decal");(s.get(["itemStyle","color"])||u&&u!=="none")&&(n=!0),(s.get(["itemStyle","decal"])||v&&v!=="none")&&(i=!0)});var o=r[0]||(r[0]={});return n||(o.color=e.slice()),!i&&a&&(o.decal=a.slice()),r}}var hc=8,Ri=8,Sr=5,fc=function(){function r(t){this.group=new j,t.add(this.group)}return r.prototype.render=function(t,e,a,n){var i=t.getModel("breadcrumb"),o=this.group;if(o.removeAll(),!(!i.get("show")||!a)){var l=i.getModel("itemStyle"),s=i.getModel("emphasis"),u=l.getModel("textStyle"),v=s.getModel(["itemStyle","textStyle"]),c=Ht(t,e).refContainer,h={left:i.get("left"),right:i.get("right"),top:i.get("top"),bottom:i.get("bottom")},f={emptyItemWidth:i.get("emptyItemWidth"),totalWidth:0,renderList:[]},g=Wt(h,c);this._prepare(a,f,u),this._renderContent(t,f,g,l,s,u,v,n),Fs(o,h,c)}},r.prototype._prepare=function(t,e,a){for(var n=t;n;n=n.parentNode){var i=Ja(n.getModel().get("name"),""),o=a.getTextRect
1(i),l=Math.max(o.width+hc*2,e.emptyItemWidth);e.totalWidth+=l+Ri,e.renderList.push({node:n,text:i,width:l})}},r.prototype._renderContent=function(t,e,a,n,i,o,l,s){for(var u=0,v=e.emptyItemWidth,c=t.get(["breadcrumb","height"]),h=e.totalWidth,f=e.renderList,g=i.getModel("itemStyle").getItemStyle(),p=f.length-1;p>=0;p--){var d=f[p],m=d.node,y=d.width,S=d.text;h>a.width&&(h-=y-v,y=v,S=null);var b=new vn({shape:{points:gc(u,0,y,c,p===f.length-1,p===0)},style:Ve(n.getItemStyle(),{lineJoin:"bevel"}),textContent:new Me({style:$e(o,{text:S})}),textConfig:{position:"inside"},z2:ya*1e4,onclick:Xe(s,m)});b.disableLabelAnimation=!0,b.getTextContent().ensureState("emphasis").style=$e(l,{text:S}),b.ensureState("emphasis").style=g,ie(b,i.get("focus"),i.get("blurScope"),i.get("disabled")),this.group.add(b),pc(b,t,m),u+=y+Ri}},r.prototype.remove=function(){this.group.removeAll()},r}();function gc(r,t,e,a,n,i){var o=[[n?r:r-Sr,t],[r+e,t],[r+e,t+a],[n?r:r-Sr,t+a]];return!i&&o.splice(2,0,[r+e+Sr,t+a/2]),!n&&o.push([r,t+a/2]),o}function pc(r,t,e){ne(r).eventData={componentType:"series",componentSubType:"treemap",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:e&&e.dataIndex,name:e&&e.name},treePathInfo:e&&nr(e,t)}}var dc=function(){function r(){this._storage=[],this._elExistsMap={}}return r.prototype.add=function(t,e,a,n,i){return this._elExistsMap[t.id]?!1:(this._elExistsMap[t.id]=!0,this._storage.push({el:t,target:e,duration:a,delay:n,easing:i}),!0)},r.prototype.finished=function(t){return this._finishedCallback=t,this},r.prototype.start=function(){for(var t=this,e=this._storage.length,a=function(){e--,e<=0&&(t._storage.length=0,t._elExistsMap={},t._finishedCallback&&t._finishedCallback())},n=0,i=this._storage.length;n<i;n++){var o=this._storage[n];o.el.animateTo(o.target,{duration:o.duration,delay:o.delay,easing:o.easing,setToFinal:!0,done:a,aborted:a})}return this},r}();function yc(){return new dc}var ha=Math.max,Wa=Math.min,bn=G,Ll=["itemStyle","borderWidth"],mc=["itemStyle","gapWidth"],Sc=["upperLabel","show"],bc=["upperLabel","height"];const wc={seriesType:"treemap",reset:function(r,t,e,a){var n=r.option,i=Ht(r,e).refContainer,o=Wt(r.getBoxLayoutParams(),i),l=a&&a.type,s=["treemapZoomToNode","treemapRootToNode"],u=ca(a,s,r),v=l==="treemapRender"||l==="treemapMove"?a.rootRect:null,c=r.getViewRoot(),h=Dl(c);if(l!=="treemapMove"){var f=!1,g=l==="treemapZoomToNode"?(f=!0,Lc(r,u,c,o)):v?(f=!0,$({},v)):$({},o);if(f){var p=El(o,g);p=Rl(p,r),g.width=o.width*p,g.height=o.height*p}var d=n.sort;d&&d!=="asc"&&d!=="desc"&&(d="desc");var m={squareRatio:n.squareRatio,sort:d,leafDepth:n.leafDepth};c.hostTree.clearLayouts();var y={x:0,y:0,width:g.width,height:g.height,area:g.width*g.height};c.setLayout(y),Cl(c,m,!1,0),y=c.getLayout(),bn(h,function(b,w){var _=(h[w+1]||c).getValue();b.setLayout($({dataExtent:[_,_],borderWidth:0,upperHeight:0},y))})}var S=r.getData().tree.root;S.setLayout(Cc(o,v,u),!0),r.setLayoutInfo(o),Tl(S,new Bt(-o.x,-o.y,e.getWidth(),e.getHeight()),h,c,0)}};function Cl(r,t,e,a){var n,i;if(!r.isRemoved()){var o=r.getLayout();n=o.width,i=o.height;var l=r.getModel(),s=l.get(Ll),u=l.get(mc)/2,v=Pl(l),c=Math.max(s,v),h=s-u,f=c-u;r.setLayout({borderWidth:s,upperHeight:c,upperLabelHeight:v},!0),n=ha(n-2*h,0),i=ha(i-h-f,0);var g=n*i,p=_c(r,l,g,t,e,a);if(p.length){var d={x:h,y:f,width:n,height:i},m=Wa(n,i),y=1/0,S=[];S.area=0;for(var b=0,w=p.length;b<w;){var _=p[b];S.push(_),S.area+=_.getLayout().area;var D=Ic(S,m,t.squareRatio);D<=y?(b++,y=D):(S.area-=S.pop().getLayout().area,Ni(S,m,d,u,!1),m=Wa(d.width,d.height),S.length=S.area=0,y=1/0)}if(S.length&&Ni(S,m,d,u,!0),!e){var A=l.get("childrenVisibleMin");A!=null&&g<A&&(e=!0)}for(var b=0,w=p.length;b<w;b++)Cl(p[b],t,e,a+1)}}}function _c(r,t,e,a,n,i){var o=r.children||[],l=a.sort;l!=="asc"&&l!=="desc"&&(l=null);var s=a.leafDepth!=null&&a.leafDepth<=i;if(n&&!s)return r.viewChildren=[];o=rn(o,function(f){return!f.isRemoved()}),xc(o,l);var u=Ac(t,o,l);if(u.sum===0)return r.viewChildren=[];if(u.sum=Dc(t,e,u.sum,l,o),u.sum===0)return r.viewChildren=[];for(var v=0,c=o.length;v<c;v++){var h=o[v].getValue()/u.sum*e;o[v].setLayout({area:h})}return s&&(o.length&&r.setLayout({isLeafRoot:!0},!0),o.length=0),r.viewChildren=o,r.setLayout({dataExtent:u.dataExtent},!0),o}function Dc(r,t,e,a,n){if(!a)return e;for(var i=r.get("visibleMin"),o=n.length,l=o,s=o-1;s>=0;s--){var u=n[a==="asc"?o-s-1:s].getValue();u/e*t<i&&(l=s,e-=u)}return a==="asc"?n.splice(0,o-l):n.splice(l,o-l),e}function xc(r,t){return t&&r.sort(function(e,a){var n=t==="asc"?e.getValue()-a.getValue():a.getValue()-e.getValue();return n===0?t==="asc"?e.dataIndex-a.dataIndex:a.dataIndex-e.dataIndex:n}),r}function Ac(r,t,e){for(var a=0,n=0,i=t.length;n<i;n++)a+=t[n].getValue();var o=r.get("visualDimension"),l;return!t||!t.length?l=[NaN,NaN]:o==="value"&&e?(l=[t[t.length-1].getValue(),t[0].getValue()],e==="asc"&&l.reverse()):(l=Ur(),bn(t,function(s){var u=s.getValue(o);u<l[0]&&(l[0]=u),u>l[1]&&(l[1]=u)})),{sum:a,dataExtent:l}}function Ic(r,t,e){for(var a=0,n=1/0,i=0,o=void 0,l=r.length;i<l;i++)o=r[i].getLayout().area,o&&(o<n&&(n=o),o>a&&(a=o));var s=r.area*r.area,u=t*t*e;return s?ha(u*a/s,s/(u*n)):1/0}function Ni(r,t,e,a,n){var i=t===e.width?0:1,o=1-i,l=["x","y"],s=["width","height"],u=e[l[i]],v=t?r.area/t:0;(n||v>e[s[o]])&&(v=e[s[o]]);for(var c=0,h=r.length;c<h;c++){var f=r[c],g={},p=v?f.getLayout().area/v:0,d=g[s[o]]=ha(v-2*a,0),m=e[l[i]]+e[s[i]]-u,y=c===h-1||m<p?m:p,S=g[s[i]]=ha(y-2*a,0);g[l[o]]=e[l[o]]+Wa(a,d/2),g[l[i]]=u+Wa(a,S/2),u+=y,f.setLayout(g,!0)}e[l[o]]+=v,e[s[o]]-=v}function Lc(r,t,e,a){var n=(t||{}).node,i=a.width,o=a.height,l=$({},a);if(!n||n===e)return l;for(var s,u=i*o,v=u*r.option.zoomToNodeRatio;s=n.parentNode;){for(var c=0,h=s.children,f=0,g=h.length;f<g;f++)c+=h[f].getValue();var p=n.getValue();if(p===0)return l;v*=c/p;var d=s.getModel(),m=d.get(Ll),y=Math.max(m,Pl(d));v+=4*m*m+(3*m+y)*Math.pow(v,.5),v>$n&&(v=$n),n=s}v<u&&(v=u);var S=Math.pow(v/u,.5);return{width:i*S,height:o*S}}function Cc(r,t,e){if(t)return{x:t.x,y:t.y};var a={x:0,y:0};if(!e)return a;var n=e.node,i=n.getLayout();if(!i)return a;for(var o=[i.width/2,i.height/2],l=n;l;){var s=l.getLayout();o[0]+=s.x,o[1]+=s.y,l=l.parentNode}return{x:r.width/2-o[0],y:r.height/2-o[1]}}function Tl(r,t,e,a,n){var i=r.getLayout(),o=e[n],l=o&&o===r;if(!(o&&!l||n===e.length&&r!==a)){r.setLayout({isInView:!0,invisible:!l&&!t.intersect(i),isAboveViewRoot:l},!0);var s=new Bt(t.x-i.x,t.y-i.y,t.width,t.height);bn(r.viewChildren||[],function(u){Tl(u,s,e,a,n+1)})}}function Pl(r){return r.get(Sc)?r.get(bc):0}function El(r,t){return t.width/r.width||t.height/r.height||1}function Rl(r,t){return fu(r,t.get("scaleLimit",!0))}var Kr=j,Mi=Ae,Vi=3,ki="label",Oi="upperLabel",Tc=ya*10,Pc=ya*2,Ec=ya*3,dt=Hs([["fill","color"],["stroke","strokeColor"],["lineWidth","strokeWidth"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),Gi=function(r){var t=dt(r);return t.stroke=t.fill=t.lineWidth=null,t},Ua=Ft(),Rc=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e._state="ready",e._storage=$t(),e}return t.prototype.render=function(e,a,n,i){var o=a.findComponents({mainType:"series",subType:"treemap",query:i});if(!(ke(o,e)<0)){this.seriesModel=e,this.api=n,this.ecModel=a;var l=["treemapZoomToNode","treemapRootToNode"],s=ca(i,l,e),u=i&&i.type,v=e.layoutInfo,c=!this._oldTree,h=this._storage,f
1=u==="treemapRootToNode"&&s&&h?{rootNodeGroup:h.nodeGroup[s.node.getRawIndex()],direction:i.direction}:null,g=this._giveContainerGroup(v),p=e.get("animation"),d=this._doRender(g,e,f);p&&!c&&(!u||u==="treemapZoomToNode"||u==="treemapRootToNode")?this._doAnimation(g,d,e,f):d.renderFinally(),this._resetController(n),this._renderBreadcrumb(e,n,s)}},t.prototype._giveContainerGroup=function(e){var a=this._containerGroup;return a||(a=this._containerGroup=new Kr,this._initEvents(a),this.group.add(a)),a.x=e.x,a.y=e.y,a},t.prototype._doRender=function(e,a,n){var i=a.getData().tree,o=this._oldTree,l=$t(),s=$t(),u=this._storage,v=[];function c(d,m,y,S){return Nc(a,s,u,n,l,v,d,m,y,S)}f(i.root?[i.root]:[],o&&o.root?[o.root]:[],e,i===o||!o,0);var h=g(u);return this._oldTree=i,this._storage=s,{lastsForAnimation:l,willDeleteEls:h,renderFinally:p};function f(d,m,y,S,b){S?(m=d,G(d,function(D,A){!D.isRemoved()&&_(A,A)})):new Qa(m,d,w,w).add(_).update(_).remove(Xe(_,null)).execute();function w(D){return D.getId()}function _(D,A){var P=D!=null?d[D]:null,I=A!=null?m[A]:null,x=c(P,I,y,b);x&&f(P&&P.viewChildren||[],I&&I.viewChildren||[],x,S,b+1)}}function g(d){var m=$t();return d&&G(d,function(y,S){var b=m[S];G(y,function(w){w&&(b.push(w),Ua(w).willDelete=!0)})}),m}function p(){G(h,function(d){G(d,function(m){m.parent&&m.parent.remove(m)})}),G(v,function(d){d.invisible=!0,d.dirty()})}},t.prototype._doAnimation=function(e,a,n,i){var o=n.get("animationDurationUpdate"),l=n.get("animationEasing"),s=(Ie(o)?0:o)||0,u=(Ie(l)?null:l)||"cubicOut",v=yc();G(a.willDeleteEls,function(c,h){G(c,function(f,g){if(!f.invisible){var p=f.parent,d,m=Ua(p);if(i&&i.direction==="drillDown")d=p===i.rootNodeGroup?{shape:{x:0,y:0,width:m.nodeWidth,height:m.nodeHeight},style:{opacity:0}}:{style:{opacity:0}};else{var y=0,S=0;m.willDelete||(y=m.nodeWidth/2,S=m.nodeHeight/2),d=h==="nodeGroup"?{x:y,y:S,style:{opacity:0}}:{shape:{x:y,y:S,width:0,height:0},style:{opacity:0}}}d&&v.add(f,d,s,0,u)}})}),G(this._storage,function(c,h){G(c,function(f,g){var p=a.lastsForAnimation[h][g],d={};p&&(f instanceof j?p.oldX!=null&&(d.x=f.x,d.y=f.y,f.x=p.oldX,f.y=p.oldY):(p.oldShape&&(d.shape=$({},f.shape),f.setShape(p.oldShape)),p.fadein?(f.setStyle("opacity",0),d.style={opacity:1}):f.style.opacity!==1&&(d.style={opacity:1})),v.add(f,d,s,0,u))})},this),this._state="animating",v.finished(le(function(){this._state="ready",a.renderFinally()},this)).start()},t.prototype._resetController=function(e){var a=this,n=this.seriesModel,i=this._controller;i||(i=this._controller=new rr(e.getZr()),i.on("pan",le(this._onPan,this)),i.on("zoom",le(this._onZoom,this))),i.enable(n.get("roam"),{api:e,zInfo:{component:n},triggerInfo:{roamTrigger:n.get("roamTrigger"),isInSelf:function(o,l,s){var u=a._containerGroup;return u?u.getBoundingRect().contain(l-u.x,s-u.y):!1}}})},t.prototype._clearController=function(){var e=this._controller;e&&(e.dispose(),e=null)},t.prototype._onPan=function(e){if(this._state!=="animating"&&(Math.abs(e.dx)>Vi||Math.abs(e.dy)>Vi)){var a=this.seriesModel.getData().tree.root;if(!a)return;var n=a.getLayout();if(!n)return;this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:n.x+e.dx,y:n.y+e.dy,width:n.width,height:n.height}})}},t.prototype._onZoom=function(e){var a=e.originX,n=e.originY,i=e.scale,o=this.seriesModel;if(this._state!=="animating"){var l=o.getData().tree.root;if(!l)return;var s=l.getLayout();if(!s)return;var u=new Bt(s.x,s.y,s.width,s.height),v=o.layoutInfo,c=El(v,s),h=c*i;h=Rl(h,o);var f=h/c;a-=v.x,n-=v.y;var g=gs();On(g,g,[-a,-n]),ps(g,g,[f,f]),On(g,g,[a,n]),u.applyTransform(g),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:u.x,y:u.y,width:u.width,height:u.height}})}},t.prototype._initEvents=function(e){var a=this;e.on("click",function(n){if(a._state==="ready"){var i=a.seriesModel.get("nodeClick",!0);if(i){var o=a.findTarget(n.offsetX,n.offsetY);if(o){var l=o.node;if(l.getLayout().isLeafRoot)a._rootToNode(o);else if(i==="zoomToNode")a._zoomToNode(o);else if(i==="link"){var s=l.hostTree.data.getItemModel(l.dataIndex),u=s.get("link",!0),v=s.get("target",!0)||"blank";u&&Eo(u,v)}}}}},this)},t.prototype._renderBreadcrumb=function(e,a,n){var i=this;n||(n=e.get("leafDepth",!0)!=null?{node:e.getViewRoot()}:this.findTarget(a.getWidth()/2,a.getHeight()/2),n||(n={node:e.getData().tree.root})),(this._breadcrumb||(this._breadcrumb=new fc(this.group))).render(e,a,n.node,function(o){i._state!=="animating"&&(Sn(e.getViewRoot(),o)?i._rootToNode({node:o}):i._zoomToNode({node:o}))})},t.prototype.remove=function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage=$t(),this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},t.prototype.dispose=function(){this._clearController()},t.prototype._zoomToNode=function(e){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:e.node})},t.prototype._rootToNode=function(e){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:e.node})},t.prototype.findTarget=function(e,a){var n,i=this.seriesModel.getViewRoot();return i.eachNode({attr:"viewChildren",order:"preorder"},function(o){var l=this._storage.background[o.getRawIndex()];if(l){var s=l.transformCoordToLocal(e,a),u=l.shape;if(u.x<=s[0]&&s[0]<=u.x+u.width&&u.y<=s[1]&&s[1]<=u.y+u.height)n={node:o,offsetX:s[0],offsetY:s[1]};else return!1}},this),n},t.type="treemap",t}(ae);function $t(){return{nodeGroup:[],background:[],content:[]}}function Nc(r,t,e,a,n,i,o,l,s,u){if(!o)return;var v=o.getLayout(),c=r.getData(),h=o.getModel();if(c.setItemGraphicEl(o.dataIndex,null),!v||!v.isInView)return;var f=v.width,g=v.height,p=v.borderWidth,d=v.invisible,m=o.getRawIndex(),y=l&&l.getRawIndex(),S=o.viewChildren,b=v.upperHeight,w=S&&S.length,_=h.getModel("itemStyle"),D=h.getModel(["emphasis","itemStyle"]),A=h.getModel(["blur","itemStyle"]),P=h.getModel(["select","itemStyle"]),I=_.get("borderRadius")||0,x=X("nodeGroup",Kr);if(!x)return;
1if(s.add(x),x.x=v.x||0,x.y=v.y||0,x.markRedraw(),Ua(x).nodeWidth=f,Ua(x).nodeHeight=g,v.isAboveViewRoot)return x;var L=X("background",Mi,u,Pc);L&&k(x,L,w&&v.upperLabelHeight);var E=h.getModel("emphasis"),V=E.get("focus"),T=E.get("blurScope"),R=E.get("disabled"),N=V==="ancestor"?o.getAncestorsIndices():V==="descendant"?o.getDescendantIndices():V;if(w)Xn(x)&&Da(x,!1),L&&(Da(L,!R),c.setItemGraphicEl(o.dataIndex,L),Zn(L,N,T));else{var C=X("content",Mi,u,Ec);C&&O(x,C),L.disableMorphing=!0,L&&Xn(L)&&Da(L,!1),Da(x,!R),c.setItemGraphicEl(o.dataIndex,x);var M=h.getShallow("cursor");M&&C.attr("cursor",M),Zn(x,N,T)}return x;function k(Y,F,q){var K=ne(F);if(K.dataIndex=o.dataIndex,K.seriesIndex=r.seriesIndex,F.setShape({x:0,y:0,width:f,height:g,r:I}),d)B(F);else{F.invisible=!1;var te=o.getVisual("style"),pe=te.stroke,we=Gi(_);we.fill=pe;var re=dt(D);re.fill=D.get("borderColor");var fe=dt(A);fe.fill=A.get("borderColor");var de=dt(P);if(de.fill=P.get("borderColor"),q){var tt=f-2*p;W(F,pe,te.opacity,{x:p,y:0,width:tt,height:b})}else F.removeTextContent();F.setStyle(we),F.ensureState("emphasis").style=re,F.ensureState("blur").style=fe,F.ensureState("select").style=de,Oa(F)}Y.add(F)}function O(Y,F){var q=ne(F);q.dataIndex=o.dataIndex,q.seriesIndex=r.seriesIndex;var K=Math.max(f-2*p,0),te=Math.max(g-2*p,0);if(F.culling=!0,F.setShape({x:p,y:p,width:K,height:te,r:I}),d)B(F);else{F.invisible=!1;var pe=o.getVisual("style"),we=pe.fill,re=Gi(_);re.fill=we,re.decal=pe.decal;var fe=dt(D),de=dt(A),tt=dt(P);W(F,we,pe.opacity,null),F.setStyle(re),F.ensureState("emphasis").style=fe,F.ensureState("blur").style=de,F.ensureState("select").style=tt,Oa(F)}Y.add(F)}function B(Y){!Y.invisible&&i.push(Y)}function W(Y,F,q,K){var te=h.getModel(K?Oi:ki),pe=Ja(h.get("name"),null),we=te.getShallow("show");Ce(Y,De(h,K?Oi:ki),{defaultText:we?pe:null,inheritColor:F,defaultOpacity:q,labelFetcher:r,labelDataIndex:o.dataIndex});var re=Y.getTextContent();if(re){var fe=re.style,de=ds(fe.padding||0);K&&(Y.setTextConfig({layoutRect:K}),re.disableLabelLayout=!0),re.beforeUpdate=function(){var Ye=Math.max((K?K.width:Y.shape.width)-de[1]-de[3],0),wa=Math.max((K?K.height:Y.shape.height)-de[0]-de[2],0);(fe.width!==Ye||fe.height!==wa)&&re.setStyle({width:Ye,height:wa})},fe.truncateMinChar=2,fe.lineOverflow="truncate",H(fe,K,v);var tt=re.getState("emphasis");H(tt?tt.style:null,K,v)}}function H(Y,F,q){var K=Y?Y.text:null;if(!F&&q.isLeafRoot&&K!=null){var te=r.get("drillDownIcon",!0);Y.text=te?te+" "+K:K}}function X(Y,F,q,K){var te=y!=null&&e[Y][y],pe=n[Y];return te?(e[Y][y]=null,ve(pe,te)):d||(te=new F,te instanceof So&&(te.z2=Mc(q,K)),me(pe,te)),t[Y][m]=te}function ve(Y,F){var q=Y[m]={};F instanceof Kr?(q.oldX=F.x,q.oldY=F.y):q.oldShape=$({},F.shape)}function me(Y,F){var q=Y[m]={},K=o.parentNode,te=F instanceof j;if(K&&(!a||a.direction==="drillDown")){var pe=0,we=0,re=n.background[K.getRawIndex()];!a&&re&&re.oldShape&&(pe=re.oldShape.width,we=re.oldShape.height),te?(q.oldX=0,q.oldY=we):q.oldShape={x:pe,y:we,width:0,height:0}}q.fadein=!te}}function Mc(r,t){return r*Tc+t}var Vc="itemStyle",Nl=Ft();const kc={seriesType:"treemap",reset:function(r){var t=r.getData().tree,e=t.root;e.isRemoved()||Ml(e,{},r.getViewRoot().getAncestors(),r)}};function Ml(r,t,e,a){var n=r.getModel(),i=r.getLayout(),o=r.hostTree.data;if(!(!i||i.invisible||!i.isInView)){var l=n.getModel(Vc),s=Oc(l,t,a),u=o.ensureUniqueItemVisual(r.dataIndex,"style"),v=l.get("borderColor"),c=l.get("borderColorSaturation"),h;c!=null&&(h=Bi(s),v=Gc(c,h)),u.stroke=v;var f=r.viewChildren;if(!f||!f.length)h=Bi(s),u.fill=h;else{var g=Bc(r,n,i,l,s,f);G(f,function(p,d){if(p.depth>=e.length||p===e[p.depth]){var m=zc(n,s,p,d,g,a);Ml(p,m,e,a)}})}}}function Oc(r,t,e){var a=$({},t),n=e.designatedVisualItemStyle;return G(["color","colorAlpha","colorSaturation"],function(i){n[i]=t[i];var o=r.get(i);n[i]=null,o!=null&&(a[i]=o)}),a}function Bi(r){var t=br(r,"color");if(t){var e=br(r,"colorAlpha"),a=br(r,"colorSaturation");return a&&(t=bo(t,null,null,a)),e&&(t=ys(t,e)),t}}function Gc(r,t){return t!=null?bo(t,null,null,r):null}function br(r,t){var e=r[t];if(e!=null&&e!=="none")return e}function Bc(r,t,e,a,n,i){if(!(!i||!i.length)){var o=wr(t,"color")||n.color!=null&&n.color!=="none"&&(wr(t,"colorAlpha")||wr(t,"colorSaturation"));
1if(o){var l=t.get("visualMin"),s=t.get("visualMax"),u=e.dataExtent.slice();l!=null&&l<u[0]&&(u[0]=l),s!=null&&s>u[1]&&(u[1]=s);var v=t.get("colorMappingBy"),c={type:o.name,dataExtent:u,visual:o.range};c.type==="color"&&(v==="index"||v==="id")?(c.mappingMethod="category",c.loop=!0):c.mappingMethod="linear";var h=new Yo(c);return Nl(h).drColorMappingBy=v,h}}}function wr(r,t){var e=r.get(t);return Q(e)&&e.length?{name:t,range:e}:null}function zc(r,t,e,a,n,i){var o=$({},t);if(n){var l=n.type,s=l==="color"&&Nl(n).drColorMappingBy,u=s==="index"?a:s==="id"?i.mapIdToIndex(e.getId()):e.getValue(r.get("visualDimension"));o[l]=n.mapValueToVisual(u)}return o}function pp(r){r.registerSeriesModel(vc),r.registerChartView(Rc),r.registerVisual(kc),r.registerLayout(wc),uc(r)}function At(r){return"_EC_"+r}var Fc=function(){function r(t){this.type="graph",this.nodes=[],this.edges=[],this._nodesMap={},this._edgesMap={},this._directed=t||!1}return r.prototype.isDirected=function(){return this._directed},r.prototype.addNode=function(t,e){t=t==null?""+e:""+t;var a=this._nodesMap;if(!a[At(t)]){var n=new yt(t,e);return n.hostGraph=this,this.nodes.push(n),a[At(t)]=n,n}},r.prototype.getNodeByIndex=function(t){var e=this.data.getRawIndex(t);return this.nodes[e]},r.prototype.getNodeById=function(t){return this._nodesMap[At(t)]},r.prototype.addEdge=function(t,e,a){var n=this._nodesMap,i=this._edgesMap;if(Ne(t)&&(t=this.nodes[t]),Ne(e)&&(e=this.nodes[e]),t instanceof yt||(t=n[At(t)]),e instanceof yt||(e=n[At(e)]),!(!t||!e)){var o=t.id+"-"+e.id,l=new Vl(t,e,a);return l.hostGraph=this,this._directed&&(t.outEdges.push(l),e.inEdges.push(l)),t.edges.push(l),t!==e&&e.edges.push(l),this.edges.push(l),i[o]=l,l}},r.prototype.getEdgeByIndex=function(t){var e=this.edgeData.getRawIndex(t);return this.edges[e]},r.prototype.getEdge=function(t,e){t instanceof yt&&(t=t.id),e instanceof yt&&(e=e.id);var a=this._edgesMap;return this._directed?a[t+"-"+e]:a[t+"-"+e]||a[e+"-"+t]},r.prototype.eachNode=function(t,e){for(var a=this.nodes,n=a.length,i=0;i<n;i++)a[i].dataIndex>=0&&t.call(e,a[i],i)},r.prototype.eachEdge=function(t,e){for(var a=this.edges,n=a.length,i=0;i<n;i++)a[i].dataIndex>=0&&a[i].node1.dataIndex>=0&&a[i].node2.dataIndex>=0&&t.call(e,a[i],i)},r.prototype.breadthFirstTraverse=function(t,e,a,n){if(e instanceof yt||(e=this._nodesMap[At(e)]),!!e){for(var i=a==="out"?"outEdges":a==="in"?"inEdges":"edges",o=0;o<this.nodes.length;o++)this.nodes[o].__visited=!1;if(!t.call(n,e,null))for(var l=[e];l.length;)for(var s=l.shift(),u=s[i],o=0;o<u.length;o++){var v=u[o],c=v.node1===s?v.node2:v.node1;if(!c.__visited){if(t.call(n,c,s))return;l.push(c),c.__visited=!0}}}},r.prototype.update=function(){for(var t=this.data,e=this.edgeData,a=this.nodes,n=this.edges,i=0,o=a.length;i<o;i++)a[i].dataIndex=-1;for(var i=0,o=t.count();i<o;i++)a[t.getRawIndex(i)].dataIndex=i;e.filterSelf(function(l){var s=n[e.getRawIndex(l)];return s.node1.dataIndex>=0&&s.node2.dataIndex>=0});for(var i=0,o=n.length;i<o;i++)n[i].dataIndex=-1;for(var i=0,o=e.count();i<o;i++)n[e.getRawIndex(i)].dataIndex=i},r.prototype.clone=function(){for(var t=new r(this._directed),e=this.nodes,a=this.edges,n=0;n<e.length;n++)t.addNode(e[n].id,e[n].dataIndex);for(var n=0;n<a.length;n++){var i=a[n];t.addEdge(i.node1.id,i.node2.id,i.dataIndex)}return t},r}(),yt=function(){function r(t,e){this.inEdges=[],this.outEdges=[],this.edges=[],this.dataIndex=-1,this.id=t??"",this.dataIndex=e??-1}return r.prototype.degree=function(){return this.edges.length},r.prototype.inDegree=function(){return this.inEdges.length},r.prototype.outDegree=function(){return this.outEdges.length},r.prototype.getModel=function(t){if(!(this.dataIndex<0)){var e=this.hostGraph,a=e.data.getItemModel(this.dataIndex);return a.getModel(t)}},r.prototype.getAdjacentDataIndices=function(){for(var t={edge:[],node:[]},e=0;e<this.edges.length;e++){var a=this.edges[e];a.dataIndex<0||(t.edge.push(a.dataIndex),t.node.push(a.node1.dataIndex,a.node2.dataIndex))}return t},r.prototype.getTrajectoryDataIndices=function(){for(var t=Nt(),e=Nt(),a=0,n=this.edges.length;a<n;a++){var i=this.edges[a];if(!(i.dataIndex<0)){t.set(i.dataIndex,!0);for(var o=[i.node1],l=[i.node2],s=0;s<o.length;){var u=o[s];s++,e.set(u.dataIndex,!0);for(var v=u.inEdges,c=0,h=v.length,f=void 0,g=void 0;c<h;c++)f=v[c],g=f.dataIndex,g>=0&&!t.hasKey(g)&&(t.set(g,!0),o.push(f.node1))}for(s=0;s<l.length;){var p=l[s];s++,e.set(p.dataIndex,!0);for(var d=p.outEdges,c=0,m=d.length,y=void 0,S=void 0;c<m;c++)y=d[c],S=y.dataIndex,S>=0&&!t.hasKey(S)&&(t.set(S,!0),l.push(y.node2))}}}return{edge:t.keys(),node:e.keys()}},r}(),Vl=function(){function r(t,e,a){this.dataIndex=-1,this.node1=t,this.node2=e,this.dataIndex=a??-1}return r.prototype.getModel=function(t){if(!(this.dataIndex<0)){var e=this.hostGraph,a=e.edgeData.getItemModel(this.dataIndex);return a.getModel(t)}},r.prototype.getAdjacentDataIndices=function(){return{edge:[this.dataIndex],node:[this.node1.dataIndex,this.node2.dataIndex]}},r.prototype.getTrajectoryDataIndices=function(){var t=Nt(),e=Nt();t.set(this.dataIndex,!0);for(var a=[this.node1],n=[this.node2],i=0;i<a.length;){var o=a[i];i++,e.set(o.dataIndex,!0);for(var l=o.inEdges,s=0,u=l.length,v=void 0,c=void 0;s<u;s++)v=o.inEdges[s],c=v.dataIndex,c>=0&&!t.hasKey(c)&&(t.set(c,!0),a.push(v.node1))}for(i=0;i<n.length;){var h=n[i];i++,e.set(h.dataIndex,!0);for(var f=h.outEdges,s=0,u=f.length,g=void 0,p=void 0;s<u;s++)g=h.outEdges[s],p=g.dataIndex,p>=0&&!t.hasKey(p)&&(t.set(p,!0),n.push(g.node2))}return{edge:t.keys(),node:e.keys()}},r}();function kl(r,t){return{getValue:function(e){var a=this[r][t];return a.getStore().get(a.getDimensionIndex(e||"value"),this.dataIndex)},setVisual:function(e,a){this.dataIndex>=0&&this[r][t].setItemVisual(this.dataIndex,e,a)},getVisual:function(e){return this[r][t].getItemVisual(this.dataIndex,e)},setLayout:function(e,a){this.dataIndex>=0&&this[r][t].setItemLayout(this.dataIndex,e,a)},getLayout:function(){return this[r][t].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[r][t].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[r][t].getRawIndex(this.dataIndex)}}}Za(yt,kl("hostGraph","data"));Za(Vl,kl("hostGraph","edgeData"));function wn(r,t,e,a,n){for(var i=new Fc(a),o=0;o<r.length;o++)i.addNode(Ma(r[o].id,r[o].name,o),o);for(var l=[],s=[],u=0,o=0;o<t.length;o++){var v=t[o],c=v.source,h=v.target;i.addEdge(c,h,u)&&(s.push(v),l.push(Ma(Ja(v.id,null),c+" > "+h)),u++)}var f=e.get("coordinateSystem"),g;if(f==="cartesian2d"||f==="polar"||f==="matrix")g=et(r,e);else{var p=Ro.get(f),d=p?p.dimensions||[]:[];ke(d,"value")<0&&d.concat(["value"]);var m=cn(r,{coordDimensions:d,encodeDefine:e.getEncode()}).dimensions;g=new Mt(m,e),g.initData(r)}var y=new Mt(["value"],e);return y.initData(s,l),n&&n(g,y),wl({mainData:g,struct:i,structAttr:"graph",datas:{node:g,edge:y},datasAttr:{node:"data",edge:"edgeData"}}),i.update(),i}var jr="-->",ir=function(r){return r.get("autoCurveness")||null},Ol=function(r,t){var e=ir(r),a=20,n=[];if(Ne(e))a=e;else if(Q(e)){r.__curvenessList=e;return}t>a&&(a=t);var i=a%2?a+2:a+3;n=[];for(var o=0;o<i;o++)n.push((o%2?o+1:o)/10*(o%2?-1:1));r.__curvenessList=n},fa=function(r,t,e){var a=[r.id,r.dataIndex].join("."),n=[t.id,t.dataIndex].join(".");return[e.uid,a,n].join(jr)},Gl=function(r){var t=r.split(jr);return[t[0],t[2],t[1]].join(jr)}
1,Hc=function(r,t){var e=fa(r.node1,r.node2,t);return t.__edgeMap[e]},Wc=function(r,t){var e=Jr(fa(r.node1,r.node2,t),t),a=Jr(fa(r.node2,r.node1,t),t);return e+a},Jr=function(r,t){var e=t.__edgeMap;return e[r]?e[r].length:0};function Uc(r){ir(r)&&(r.__curvenessList=[],r.__edgeMap={},Ol(r))}function Yc(r,t,e,a){if(ir(e)){var n=fa(r,t,e),i=e.__edgeMap,o=i[Gl(n)];i[n]&&!o?i[n].isForward=!0:o&&i[n]&&(o.isForward=!0,i[n].isForward=!1),i[n]=i[n]||[],i[n].push(a)}}function _n(r,t,e,a){var n=ir(t),i=Q(n);if(!n)return null;var o=Hc(r,t);if(!o)return null;for(var l=-1,s=0;s<o.length;s++)if(o[s]===e){l=s;break}var u=Wc(r,t);Ol(t,u),r.lineStyle=r.lineStyle||{};var v=fa(r.node1,r.node2,t),c=t.__curvenessList,h=i||u%2?0:1;if(o.isForward)return c[h+l];var f=Gl(v),g=Jr(f,t),p=c[l+g+h];return a?i?n&&n[0]===0?(g+h)%2?p:-p:((g%2?0:1)+h)%2?p:-p:(g+h)%2?p:-p:c[l+g+h]}var be="graph",$c=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e}return t.prototype.init=function(e){r.prototype.init.apply(this,arguments);var a=this;function n(){return a._categoriesData}this.legendVisualProvider=new Ut(n,n),this.fillDataTextStyle(e.edges||e.links),this._updateCategoriesData()},t.prototype.mergeOption=function(e){r.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(e.edges||e.links),this._updateCategoriesData()},t.prototype.mergeDefaultAndTheme=function(e){r.prototype.mergeDefaultAndTheme.apply(this,arguments),un(e,"edgeLabel",["show"])},t.prototype.getInitialData=function(e,a){var n=e.edges||e.links||[],i=e.data||e.nodes||[],o=this;if(i&&n){Uc(this);var l=wn(i,n,this,!0,s);return G(l.edges,function(u){Yc(u.node1,u.node2,this,u.dataIndex)},this),l.data}function s(u,v){u.wrapMethod("getItemModel",function(g){var p=o._categoriesModels,d=g.getShallow("category"),m=p[d];return m&&(m.parentModel=g.parentModel,g.parentModel=m),g});var c=ht.prototype.getModel;function h(g,p){var d=c.call(this,g,p);return d.resolveParentPath=f,d}v.wrapMethod("getItemModel",function(g){return g.resolveParentPath=f,g.getModel=h,g});function f(g){if(g&&(g[0]==="label"||g[1]==="label")){var p=g.slice();return g[0]==="label"?p[0]="edgeLabel":g[1]==="label"&&(p[1]="edgeLabel"),p}return g}}},t.prototype.getGraph=function(){return this.getData().graph},t.prototype.getEdgeData=function(){return this.getGraph().edgeData},t.prototype.getCategoriesData=function(){return this._categoriesData},t.prototype.formatTooltip=function(e,a,n){if(n==="edge"){var i=this.getData(),o=this.getDataParams(e,n),l=i.graph.getEdgeByIndex(e),s=i.getName(l.node1.dataIndex),u=i.getName(l.node2.dataIndex),v=[];return s!=null&&v.push(s),u!=null&&v.push(u),Ge("nameValue",{name:v.join(" > "),value:o.value,noValue:o.value==null})}var c=Ws({series:this,dataIndex:e,multipleSeries:a});return c},t.prototype._updateCategoriesData=function(){var e=ee(this.option.categories||[],function(n){return n.value!=null?n:$({value:0},n)}),a=new Mt(["value"],this);a.initData(e),this._categoriesData=a,this._categoriesModels=a.mapArray(function(n){return a.getItemModel(n)})},t.prototype.isAnimationEnabled=function(){return r.prototype.isAnimationEnabled.call(this)&&!(this.get("layout")==="force"&&this.get(["force","layoutAnimation"]))},t.prototype.__ownRoamView=function(){var e=this.coordinateSystem;return $o(e)&&e},t.type="series."+be,t.dependencies=["grid","polar","geo","singleAxis","calendar"],t.defaultOption={z:2,coordinateSystem:"view",legendHoverLink:!0,layout:null,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,friction:.6,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle",distance:5},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:Z.color.neutral50,width:1,opacity:.5},emphasis:{scale:!0,label:{show:!0}},select:{itemStyle:{borderColor:Z.color.primary}}},t}(se);function Ca(r){return r instanceof Array||(r=[r,r]),r}var Xc=he(be,Zc);function Zc(r){r.eachSeriesByType(be,function(t){var e=t.getGraph(),a=t.getEdgeData(),n=Ca(t.get("edgeSymbol")),i=Ca(t.get("edgeSymbolSize"));a.setVisual("fromSymbol",n&&n[0]),a.setVisual("toSymbol",n&&n[1]),a.setVisual("fromSymbolSize",i&&i[0]),a.setVisual("toSymbolSize",i&&i[1]),a.setVisual("style",t.getModel("lineStyle").getLineStyle()),a.each(function(o){var l=a.getItemModel(o),s=e.getEdgeByIndex(o),u=Ca(l.getShallow("symbol",!0)),v=Ca(l.getShallow("symbolSize",!0)),c=l.getModel("lineStyle").getLineStyle(),h=a.ensureUniqueItemVisual(o,"style");
1switch($(h,c),h.stroke){case"source":{var f=s.node1.getVisual("style");h.stroke=f&&f.fill;break}case"target":{var f=s.node2.getVisual("style");h.stroke=f&&f.fill;break}}u[0]&&s.setVisual("fromSymbol",u[0]),u[1]&&s.setVisual("toSymbol",u[1]),v[0]&&s.setVisual("fromSymbolSize",v[0]),v[1]&&s.setVisual("toSymbolSize",v[1])})})}function Bl(r){var t=r.coordinateSystem;if(!(t&&t.type!=="view")){var e=r.getGraph();e.eachNode(function(a){var n=a.getModel();a.setLayout([+n.get("x"),+n.get("y")])}),Dn(e,r)}}function Dn(r,t){r.eachEdge(function(e,a){var n=xt(e.getModel().get(["lineStyle","curveness"]),-_n(e,t,a,!0),0),i=st(e.node1.getLayout()),o=st(e.node2.getLayout()),l=[i,o];+n&&l.push([(i[0]+o[0])/2-(i[1]-o[1])*n,(i[1]+o[1])/2-(o[0]-i[0])*n]),e.setLayout(l)})}var qc=he(be,Kc);function Kc(r,t){r.eachSeriesByType(be,function(e){var a=e.get("layout"),n=e.coordinateSystem;if(n&&n.type!=="view"){var i=e.getData(),o=[];G(n.dimensions,function(h){o=o.concat(i.mapDimensionsAll(h))});for(var l=0;l<i.count();l++){for(var s=[],u=!1,v=0;v<o.length;v++){var c=i.get(o[v],l);isNaN(c)||(u=!0),s.push(c)}u?i.setItemLayout(l,n.dataToPoint(s)):i.setItemLayout(l,[NaN,NaN])}Dn(i.graph,e)}else(!a||a==="none")&&Bl(e)})}function Kt(r){var t=r.coordinateSystem;return $o(t)?Uo(t,r):1}function jt(r){var t=r.getVisual("symbolSize");return t instanceof Array&&(t=(t[0]+t[1])/2),+t}var zi=Math.PI,_r=[];function xn(r,t,e,a){var n=r.coordinateSystem;if(!(n&&n.type!=="view")){var i=n.getBoundingRect(),o=r.getData(),l=o.graph,s=i.width/2+i.x,u=i.height/2+i.y,v=Math.min(i.width,i.height)/2,c=o.count();if(o.setLayout({cx:s,cy:u}),!!c){if(e){var h=n.pointToData(a),f=h[0],g=h[1],p=[f-s,g-u];nn(p,p),ms(p,p,v),e.setLayout([s+p[0],u+p[1]],!0);var d=r.get(["circular","rotateLabel"]);zl(e,d,s,u)}jc[t](r,l,o,v,s,u,c),l.eachEdge(function(m,y){var S=xt(m.getModel().get(["lineStyle","curveness"]),_n(m,r,y),0),b=st(m.node1.getLayout()),w=st(m.node2.getLayout()),_,D=(b[0]+w[0])/2,A=(b[1]+w[1])/2;+S&&(S*=3,_=[s*S+D*(1-S),u*S+A*(1-S)]),m.setLayout([b,w,_])})}}}var jc={value:function(r,t,e,a,n,i,o){var l=0,s=e.getSum("value"),u=Math.PI*2/(s||o);t.eachNode(function(v){var c=v.getValue("value"),h=u*(s?c:1)/2;l+=h,v.setLayout([a*Math.cos(l)+n,a*Math.sin(l)+i]),l+=h})},symbolSize:function(r,t,e,a,n,i,o){var l=0;_r.length=o;var s=Kt(r);t.eachNode(function(c){var h=jt(c);isNaN(h)&&(h=2),h<0&&(h=0),h*=s;var f=Math.asin(h/2/a);isNaN(f)&&(f=zi/2),_r[c.dataIndex]=f,l+=f*2});var u=(2*zi-l)/o/2,v=0;t.eachNode(function(c){var h=u+_r[c.dataIndex];v+=h,(!c.getLayout()||!c.getLayout().fixed)&&c.setLayout([a*Math.cos(v)+n,a*Math.sin(v)+i]),v+=h})}};function zl(r,t,e,a){var n=r.getGraphicEl();if(n){var i=r.getModel(),o=i.get(["label","rotate"])||0,l=n.getSymbolPath();if(t){var s=r.getLayout(),u=Math.atan2(s[1]-a,s[0]-e);u<0&&(u=Math.PI*2+u);var v=s[0]<e;v&&(u=u-Math.PI);var c=v?"left":"right";l.setTextConfig({rotation:-u,position:c,origin:"center"});var h=l.ensureState("emphasis");$(h.textConfig||(h.textConfig={}),{position:c})}else l.setTextConfig({rotation:o*=Math.PI/180})}}var Jc=he(be,Qc);function Qc(r){r.eachSeriesByType("graph",function(t){t.get("layout")==="circular"&&xn(t,"symbolSize")})}var It=Hr;function eh(r,t,e){for(var a=r,n=t,i=e.rect,o=i.width,l=i.height,s=[i.x+o/2,i.y+l/2],u=e.gravity==null?.1:e.gravity,v=0;v<a.length;v++){var c=a[v];c.p||(c.p=Ss(o*(Math.random()-.5)+s[0],l*(Math.random()-.5)+s[1])),c.pp=st(c.p),c.edges=null}var h=e.friction==null?.6:e.friction,f=h,g,p;return{warmUp:function(){f=h*.8},setFixed:function(d){a[d].fixed=!0},setUnfixed:function(d){a[d].fixed=!1},beforeStep:function(d){g=d},afterStep:function(d){p=d},step:function(d){g&&g(a,n);for(var m=[],y=a.length,S=0;S<n.length;S++){var b=n[S];if(!b.ignoreForceLayout){var w=b.n1,_=b.n2;Xt(m,_.p,w.p);var D=Gn(m)-b.d,A=_.w/(w.w+_.w);isNaN(A)&&(A=0),nn(m,m),!w.fixed&&It(w.p,w.p,m,A*D*f),!_.fixed&&It(_.p,_.p,m,-(1-A)*D*f)}}for(var S=0;S<y;S++){var P=a[S];P.fixed||(Xt(m,s,P.p),It(P.p,P.p,m,u*f))}for(var S=0;S<y;S++)for(var w=a[S],I=S+1;I<y;I++){var _=a[I];Xt(m,_.p,w.p);var D=Gn(m);D===0&&(bs(m,Math.random()-.5,Math.random()-.5),D=1);var x=(w.rep+_.rep)/D/D;!w.fixed&&It(w.pp,w.pp,m,x),!_.fixed&&It(_.pp,_.pp,m,-x)}for(var L=[],S=0;S<y;S++){var P=a[S];P.fixed||(Xt(L,P.p,P.pp),It(P.p,P.p,L,f),_e(P.pp,P.p))}f=f*.992;var E=f<.01;p&&p(a,n,E),d&&d(E)}}}var th=he(be,ah);function ah(r){r.eachSeriesByType(be,function(t){var e=t.coordinateSystem;if(!(e&&e.type!=="view"))if(t.get("layout")==="force"){var a=t.preservedPoints||{},n=t.getGraph(),i=n.data,o=n.edgeData,l=t.getModel("force"),s=l.get("initLayout");t.preservedPoints?i.each(function(S){var b=i.getId(S);i.setItemLayout(S,a[b]||[NaN,NaN])}):!s||s==="none"?Bl(t):s==="circular"&&xn(t,"value");var u=i.getDataExtent("value"),v=o.getDataExtent("value"),c=l.get("repulsion"),h=l.get("edgeLength"),f=Q(c)?c:[c,c],g=Q(h)?h:[h,h];g=[g[1],g[0]];var p=i.mapArray("value",function(S,b){var w=i.getItemLayout(b),_=Pe(S,u,f);return isNaN(_)&&(_=(f[0]+f[1])/2),{w:_,rep:_,fixed:i.getItemModel(b).get("fixed"),p:!w||isNaN(w[0])||isNaN(w[1])?null:w}}),d=o.mapArray("value",function(S,b){var w=n.getEdgeByIndex(b),_=Pe(S,v,g);isNaN(_)&&(_=(g[0]+g[1])/2);var D=w.getModel(),A=xt(w.getModel().get(["lineStyle","curveness"]),-_n(w,t,b,!0),0);return{n1:p[w.node1.dataIndex],n2:p[w.node2.dataIndex],d:_,curveness:A,ignoreForceLayout:D.get("ignoreForceLayout")}}
1),m=e.getBoundingRect(),y=eh(p,d,{rect:m,gravity:l.get("gravity"),friction:l.get("friction")});y.beforeStep(function(S,b){for(var w=0,_=S.length;w<_;w++)S[w].fixed&&_e(S[w].p,n.getNodeByIndex(w).getLayout())}),y.afterStep(function(S,b,w){for(var _=0,D=S.length;_<D;_++)S[_].fixed||n.getNodeByIndex(_).setLayout(S[_].p),a[i.getId(_)]=S[_].p;for(var _=0,D=b.length;_<D;_++){var A=b[_],P=n.getEdgeByIndex(_),I=A.n1.p,x=A.n2.p,L=P.getLayout();L=L?L.slice():[],L[0]=L[0]||[],L[1]=L[1]||[],_e(L[0],I),_e(L[1],x),+A.curveness&&(L[2]=[(I[0]+x[0])/2-(I[1]-x[1])*A.curveness,(I[1]+x[1])/2-(x[0]-I[0])*A.curveness]),P.setLayout(L)}}),t.forceLayout=y,t.preservedPoints=a,y.step()}else t.forceLayout=null})}function rh(r,t,e){var a=Ht(r,t),n=$(r.getBoxLayoutParams(),{aspect:e}),i=Wt(n,a.refContainer);return Ys(r,i,e)}function nh(r,t){var e=[];return r.eachSeriesByType("graph",function(a){Us({targetModel:a,coordSysType:"view",coordSysProvider:n,isDefaultDataCoordSys:!0});function n(){var i=a.getData(),o=i.mapArray(function(g){var p=i.getItemModel(g);return[+p.get("x"),+p.get("y")]}),l=[],s=[];mo(o,l,s),s[0]-l[0]===0&&(s[0]+=1,l[0]-=1),s[1]-l[1]===0&&(s[1]+=1,l[1]-=1);var u=(s[0]-l[0])/(s[1]-l[1]),v=rh(a,t,u);isNaN(u)&&(l=[v.x,v.y],s=[v.x+v.width,v.y+v.height]);var c=s[0]-l[0],h=s[1]-l[1],f=gn(a,t,l[0],l[1],c,h,v);return e.push(f),f}}),e}var Dr=[],xr=[],Ar=[],Lt=wo,Ir=_s,Fi=Math.abs;function Hi(r,t,e){for(var a=r[0],n=r[1],i=r[2],o=1/0,l,s=e*e,u=.1,v=.1;v<=.9;v+=.1){Dr[0]=Lt(a[0],n[0],i[0],v),Dr[1]=Lt(a[1],n[1],i[1],v);var c=Fi(Ir(Dr,t)-s);c<o&&(o=c,l=v)}for(var h=0;h<32;h++){var f=l+u;xr[0]=Lt(a[0],n[0],i[0],l),xr[1]=Lt(a[1],n[1],i[1],l),Ar[0]=Lt(a[0],n[0],i[0],f),Ar[1]=Lt(a[1],n[1],i[1],f);var c=Ir(xr,t)-s;if(Fi(c)<.01)break;var g=Ir(Ar,t)-s;u/=2,c<0?g>=0?l=l+u:l=l-u:g>=0?l=l-u:l=l+u}return l}function Lr(r,t){var e=[],a=ws,n=[[],[],[]],i=[[],[]],o=[];t/=2,r.eachEdge(function(l,s){var u=l.getLayout(),v=l.getVisual("fromSymbol"),c=l.getVisual("toSymbol");u.__original||(u.__original=[st(u[0]),st(u[1])],u[2]&&u.__original.push(st(u[2])));var h=u.__original;if(u[2]!=null){if(_e(n[0],h[0]),_e(n[1],h[2]),_e(n[2],h[1]),v&&v!=="none"){var f=jt(l.node1),g=Hi(n,h[0],f*t);a(n[0][0],n[1][0],n[2][0],g,e),n[0][0]=e[3],n[1][0]=e[4],a(n[0][1],n[1][1],n[2][1],g,e),n[0][1]=e[3],n[1][1]=e[4]}if(c&&c!=="none"){var f=jt(l.node2),g=Hi(n,h[1],f*t);a(n[0][0],n[1][0],n[2][0],g,e),n[1][0]=e[1],n[2][0]=e[2],a(n[0][1],n[1][1],n[2][1],g,e),n[1][1]=e[1],n[2][1]=e[2]}_e(u[0],n[0]),_e(u[1],n[2]),_e(u[2],n[1])}else{if(_e(i[0],h[0]),_e(i[1],h[1]),Xt(o,i[1],i[0]),nn(o,o),v&&v!=="none"){var f=jt(l.node1);Hr(i[0],i[0],o,f*t)}if(c&&c!=="none"){var f=jt(l.node2);Hr(i[1],i[1],o,-f*t)}_e(u[0],i[0]),_e(u[1],i[1])}})}var ih=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=be,e}return t.prototype.init=function(e,a){var n=new er,i=new Xo,o=this.group,l=new j;this._controller=new rr(a.getZr()),l.add(n.group),l.add(i.group),o.add(l),this._symbolDraw=n,this._lineDraw=i,this._mainGroup=l,this._firstRender=!0},t.prototype.render=function(e,a,n){var i=this,o=ri(e),l=!1;this._model=e,this._api=n,this._active=!0;var s=this._mainGroup,u=this._getThumbnailInfo();u&&u.bridge.reset(n);var v=this._symbolDraw,c=this._lineDraw;o&&Vt(s,kt,o,this._firstRender?null:e),Lr(e.getGraph(),Kt(e));var h=e.getData();v.updateData(h);var f=e.getEdgeData();c.updateData(f),this._updateNodeAndLinkScale(),o&&fn(e,n,this._controller,function(b,w,_){return e.coordinateSystem.containPoint([w,_])},null),clearTimeout(this._layoutTimeout);var g=e.forceLayout,p=e.get(["force","layoutAnimation"]);g&&(l=!0,this._startForceLayoutIteration(g,n,p));var d=e.get("layout");h.graph.eachNode(function(b){var w=b.dataIndex,_=b.getGraphicEl(),D=b.getModel();if(_){_.off("drag").off("dragend");var A=D.get("draggable");A&&_.on("drag",function(I){switch(d){case"force":g.warmUp(),!i._layouting&&i._startForceLayoutIteration(g,n,p),g.setFixed(w),h.setItemLayout(w,[_.x,_.y]);break;case"circular":h.setItemLayout(w,[_.x,_.y]),b.setLayout({fixed:!0},!0),xn(e,"symbolSize",b,[I.offsetX,I.offsetY]),i.updateLayout(e);break;case"none":default:h.setItemLayout(w,[_.x,_.y]),Dn(e.getGraph(),e),i.updateLayout(e);break}}).on("dragend",function(){g&&g.setUnfixed(w)}),_.setDraggable(A,!!D.get("cursor"));
1var P=D.get(["emphasis","focus"]);P==="adjacency"&&(ne(_).focus=b.getAdjacentDataIndices())}}),h.graph.eachEdge(function(b){var w=b.getGraphicEl(),_=b.getModel().get(["emphasis","focus"]);w&&_==="adjacency"&&(ne(w).focus={edge:[b.dataIndex],node:[b.node1.dataIndex,b.node2.dataIndex]})});var m=e.get("layout")==="circular"&&e.get(["circular","rotateLabel"]),y=h.getLayout("cx"),S=h.getLayout("cy");h.graph.eachNode(function(b){zl(b,m,y,S)}),this._firstRender=!1,l||this._renderThumbnail(e,n,this._symbolDraw,this._lineDraw)},t.prototype.dispose=function(){this.remove(),this._controller&&this._controller.dispose()},t.prototype._startForceLayoutIteration=function(e,a,n){var i=this,o=!1;(function l(){e.step(function(s){i.updateLayout(i._model),(s||!o)&&(o=!0,i._renderThumbnail(i._model,a,i._symbolDraw,i._lineDraw)),(i._layouting=!s)&&(n?i._layoutTimeout=setTimeout(l,16):l())})})()},t.prototype.__updateOnOwnRoam=function(e,a,n){var i=ri(a);!this._active||!i||(Vt(this._mainGroup,kt,i,null),Wo(e)&&(this._updateNodeAndLinkScale(),Lr(a.getGraph(),Kt(a)),this._lineDraw.updateLayout(),n.updateLabelLayout()),this._updateThumbnailWindow())},t.prototype._updateNodeAndLinkScale=function(){var e=this._model,a=e.getData(),n=Kt(e);a.eachItemGraphicEl(function(i,o){i&&i.setSymbolScale(n)})},t.prototype.updateLayout=function(e){this._active&&(Lr(e.getGraph(),Kt(e)),this._symbolDraw.updateLayout(),this._lineDraw.updateLayout())},t.prototype.remove=function(){this._active=!1,clearTimeout(this._layoutTimeout),this._layouting=!1,this._layoutTimeout=null,this._symbolDraw&&this._symbolDraw.remove(),this._lineDraw&&this._lineDraw.remove(),this._controller&&this._controller.disable()},t.prototype._getThumbnailInfo=function(){var e=this._model,a=e.coordinateSystem;if(a.type==="view"){var n=gu(e);if(n)return{bridge:n,coordSys:a}}},t.prototype._updateThumbnailWindow=function(){var e=this._getThumbnailInfo();e&&e.bridge.updateWindow(ni(null,e.coordSys),this._api)},t.prototype._renderThumbnail=function(e,a,n,i){var o=this._getThumbnailInfo();if(o){var l=new j,s=n.group.children(),u=i.group.children(),v=new j,c=new j;l.add(c),l.add(v);for(var h=0;h<s.length;h++){var f=s[h],g=f.children()[0],p=f.x,d=f.y,m=Ct(g.shape),y=$(m,{width:g.scaleX,height:g.scaleY,x:p-g.scaleX/2,y:d-g.scaleY/2}),S=Ct(g.style),b=new g.constructor({shape:y,style:S,z2:151});c.add(b)}for(var h=0;h<u.length;h++){var f=u[h],w=f.children()[0],S=Ct(w.style),y=Ct(w.shape),_=new pu({style:S,shape:y,z2:151});v.add(_)}o.bridge.renderContent({api:a,roamType:e.get("roam"),viewportRect:null,group:l,targetTrans:ni(null,o.coordSys)})}},t.type=be,t}(ae),oh=he(be,lh);function lh(r){var t=r.findComponents({mainType:"legend"});!t||!t.length||r.eachSeriesByType(be,function(e){var a=e.getCategoriesData(),n=e.getGraph(),i=n.data,o=a.mapArray(a.getName);i.filterSelf(function(l){var s=i.getItemModel(l),u=s.getShallow("category");if(u!=null){Ne(u)&&(u=o[u]);for(var v=0;v<t.length;v++)if(!t[v].isSelected(u))return!1}return!0})})}var sh=he(be,uh);function uh(r){var t={};r.eachSeriesByType(be,function(e){var a=e.getCategoriesData(),n=e.getData(),i={};a.each(function(o){var l=a.getName(o);i["ec-"+l]=o;var s=a.getItemModel(o),u=s.getModel("itemStyle").getItemStyle();u.fill||(u.fill=e.getColorFromPalette(l,t)),a.setItemVisual(o,"style",u);for(var v=["symbol","symbolSize","symbolKeepAspect"],c=0;c<v.length;c++){var h=s.getShallow(v[c],!0);h!=null&&a.setItemVisual(o,v[c],h)}}),a.count()&&n.each(function(o){var l=n.getItemModel(o),s=l.getShallow("category");if(s!=null){Le(s)&&(s=i["ec-"+s]);var u=a.getItemVisual(s,"style"),v=n.ensureUniqueItemVisual(o,"style");$(v,u);for(var c=["symbol","symbolSize","symbolKeepAspect"],h=0;h<c.length;h++)n.setItemVisual(o,c[h],a.getItemVisual(s,c[h]))}})})}function dp(r){r.registerChartView(ih),r.registerSeriesModel($c),r.registerProcessor(oh),r.registerVisual(sh),r.registerVisual(Xc),r.registerLayout(qc),r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,Jc),r.registerLayout(th),r.registerCoordinateSystem("graphView",{dimensions:du.dimensions,create:nh}),r.registerAction({type:"focusNodeAdjacency",event:"focusNodeAdjacency",update:"series:focusNodeAdjacency"},Fr),r.registerAction({type:"unfocusNodeAdjacency",event:"unfocusNodeAdjacency",update:"series:unfocusNodeAdjacency"},Fr),pn(r,aa,be)}var ga="chord",vh=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}
1return t.prototype.init=function(e){r.prototype.init.apply(this,arguments),this.fillDataTextStyle(e.edges||e.links),this.legendVisualProvider=new Ut(le(this.getData,this),le(this.getRawData,this))},t.prototype.mergeOption=function(e){r.prototype.mergeOption.apply(this,arguments),this.fillDataTextStyle(e.edges||e.links)},t.prototype.getInitialData=function(e,a){var n=e.edges||e.links||[],i=e.data||e.nodes||[];if(i&&n){var o=wn(i,n,this,!0,l);return o.data}function l(s,u){var v=ht.prototype.getModel;function c(f,g){var p=v.call(this,f,g);return p.resolveParentPath=h,p}u.wrapMethod("getItemModel",function(f){return f.resolveParentPath=h,f.getModel=c,f});function h(f){if(f&&(f[0]==="label"||f[1]==="label")){var g=f.slice();return f[0]==="label"?g[0]="edgeLabel":f[1]==="label"&&(g[1]="edgeLabel"),g}return f}}},t.prototype.getGraph=function(){return this.getData().graph},t.prototype.getEdgeData=function(){return this.getGraph().edgeData},t.prototype.formatTooltip=function(e,a,n){var i=this.getDataParams(e,n);if(n==="edge"){var o=this.getData(),l=o.graph.getEdgeByIndex(e),s=o.getName(l.node1.dataIndex),u=o.getName(l.node2.dataIndex),v=[];return s!=null&&v.push(s),u!=null&&v.push(u),Ge("nameValue",{name:v.join(" > "),value:i.value,noValue:i.value==null})}return Ge("nameValue",{name:i.name,value:i.value,noValue:i.value==null})},t.prototype.getDataParams=function(e,a){var n=r.prototype.getDataParams.call(this,e,a);if(a==="node"){var i=this.getData(),o=this.getGraph().getNodeByIndex(e);if(n.name==null&&(n.name=i.getName(e)),n.value==null){var l=o.getLayout().value;n.value=l}}return n},t.type="series."+ga,t.defaultOption={z:2,coordinateSystem:"none",legendHoverLink:!0,colorBy:"data",left:0,top:0,right:0,bottom:0,width:null,height:null,center:["50%","50%"],radius:["70%","80%"],clockwise:!0,startAngle:90,endAngle:"auto",minAngle:0,padAngle:3,itemStyle:{borderRadius:[0,0,5,5]},lineStyle:{width:0,color:"source",opacity:.2},label:{show:!0,position:"outside",distance:5},emphasis:{focus:"adjacency",lineStyle:{opacity:.5}}},t}(se),Wi=function(r){z(t,r);function t(e,a,n){var i=r.call(this)||this;ne(i).dataType="node",i.z2=2;var o=new Me;return i.setTextContent(o),i.updateData(e,a,n,!0),i}return t.prototype.updateData=function(e,a,n,i){var o=this,l=e.graph.getNodeByIndex(a),s=e.hostModel,u=l.getModel(),v=u.getModel("emphasis"),c=e.getItemLayout(a),h=$(Fe(u.getModel("itemStyle"),c,!0),c),f=this;if(isNaN(h.startAngle)){f.setShape(h);return}i?f.setShape(h):J(f,{shape:h},s,a);var g=$(Fe(u.getModel("itemStyle"),c,!0),c);o.setShape(g),o.useStyle(e.getItemVisual(a,"style")),ce(o,u),this._updateLabel(s,u,l),e.setItemGraphicEl(a,f),ce(f,u,"itemStyle");var p=v.get("focus");ie(this,p==="adjacency"?l.getAdjacentDataIndices():p,v.get("blurScope"),v.get("disabled"))},t.prototype._updateLabel=function(e,a,n){var i=this.getTextContent(),o=n.getLayout(),l=(o.startAngle+o.endAngle)/2,s=Math.cos(l),u=Math.sin(l),v=a.getModel("label");i.ignore=!v.get("show");var c=De(a),h=n.getVisual("style");Ce(i,c,{labelFetcher:{getFormattedLabel:function(y,S,b,w,_,D){return e.getFormattedLabel(y,S,"node",w,xt(_,c.normal&&c.normal.get("formatter"),a.get("name")),D)}},labelDataIndex:n.dataIndex,defaultText:n.dataIndex+"",inheritColor:h.fill,defaultOpacity:h.opacity,defaultOutsidePosition:"startArc"});var f=v.get("position")||"outside",g=v.get("distance")||0,p;f==="outside"?p=o.r+g:p=(o.r+o.r0)/2,this.textConfig={inside:f!=="outside"};var d=f!=="outside"?v.get("align")||"center":s>0?"left":"right",m=f!=="outside"?v.get("verticalAlign")||"middle":u>0?"top":"bottom";i.attr({x:s*p+o.cx,y:u*p+o.cy,rotation:0,style:{align:d,verticalAlign:m}})},t}(je),ch=function(r){z(t,r);function t(e,a,n,i){var o=r.call(this)||this;return ne(o).dataType="edge",o.updateData(e,a,n,i,!0),o}return t.prototype.buildPath=function(e,a){e.moveTo(a.s1[0],a.s1[1]);var n=.7,i=a.clockwise;e.arc(a.cx,a.cy,a.r,a.sStartAngle,a.sEndAngle,!i),e.bezierCurveTo((a.cx-a.s2[0])*n+a.s2[0],(a.cy-a.s2[1])*n+a.s2[1],(a.cx-a.t1[0])*n+a.t1[0],(a.cy-a.t1[1])*n+a.t1[1],a.t1[0],a.t1[1]),e.arc(a.cx,a.cy,a.r,a.tStartAngle,a.tEndAngle,!i),e.bezierCurveTo((a.cx-a.t2[0])*n+a.t2[0],(a.cy-a.t2[1])*n+a.t2[1],(a.cx-a.s1[0])*n+a.s1[0],(a.cy-a.s1[1])*n+a.s1[1],a.s1[0],a.s1[1]),e.closePath()},t.prototype.updateData=function(e,a,n,i,o){var l=e.hostModel,s=a.graph.getEdgeByIndex(n),u=s.getLayout(),v=s.node1.getModel(),c=a.getItemModel(s.dataIndex),h=c.getModel("lineStyle"),f=c.getModel("emphasis"),g=f.get("focus"),p=$(Fe(v.getModel("itemStyle"),u,!0),u),d=this;if(isNaN(p.sStartAngle)||isNaN(p.tStartAngle)){d.setShape(p);return}o?(d.setShape(p),Ui(d,s,e,h)):(Oe(d),Ui(d,s,e,h),J(d,{shape:p},l,n)),ie(this,g==="adjacency"?s.getAdjacentDataIndices():g,f.get("blurScope"),f.get("disabled")),ce(d,c,"lineStyle"),a.setItemGraphicEl(s.dataIndex,d)},t}(xe);function Ui(r,t,e,a){var n=t.node1,i=t.node2,o=r.style;r.setStyle(a.getLineStyle());var l=a.get("color");switch(l){case"source":o.fill=e.getItemVisual(n.dataIndex,"style").fill,o.decal=n.getVisual("style").decal;break;case"target":o.fill=e.getItemVisual(i.dataIndex,"style").fill,o.decal=i.getVisual("style").decal;break;case"gradient":var s=e.getItemVisual(n.dataIndex,"style").fill,u=e.getItemVisual(i.dataIndex,"style").fill;if(Le(s)&&Le(u)){var v=r.shape,c=(v.s1[0]+v.s2[0])/2,h=(v.s1[1]+v.s2[1])/2,f=(v.t1[0]+v.t2[0])/2,g=(v.t1[1]+v.t2[1])/2;o.fill=new on(c,h,f,g,[{offset:0,color:s},{offset:1,color:u}],!0)}break}}var hh=Math.PI/180,fh=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=ga,e}return t.prototype.init=function(e,a){},t.prototype.render=function(e,a,n){var i=e.getData(),o=this._data,l=this.group,s=-e.get("startAngle")*hh;if(i.diff(o).add(function(v){var c=i.getItemLayout(v);if(c){var h=new Wi(i,v,s);ne(h).dataIndex=v,l.add(h)}}).update(function(v,c){var h=o.getItemGraphicEl(c),f=i.getItemLayout(v);if(!f){h&&ut(h,e,c);return}h?h.updateData(i,v,s):h=new Wi(i,v,s),l.add(h)}).remove(function(v){var c=o.getItemGraphicEl(v);c&&ut(c,e,v)}).execute(),!o){var u=e.get("center");this.group.scaleX=.01,this.group.scaleY=.01,this.group.originX=U(u[0],n.getWidth()),this.group.originY=U(u[1],n.getHeight()),ue(this.group,{scaleX:1,scaleY:1},e)}this._data=i,this.renderEdges(e,s)},t.prototype.renderEdges=function(e,a){var n=e.getData(),i=e.getEdgeData(),o=this._edgeData,l=this.group;i.diff(o).add(function(s){var u=new ch(n,i,s,a);ne(u).dataIndex=s,l.add(u)}).update(function(s,u){var v=o.getItemGraphicEl(u);v.updateData(n,i,s,a),l.add(v)}).remove(function(s){var u=o.getItemGraphicEl(s);u&&ut(u,e,s)}).execute(),this._edgeData=i},t.prototype.dispose=function(){},t.type=ga,t}(ae),Cr=Math.PI/180,gh=he(ga,ph);function ph(r,t){r.eachSeriesByType(ga,function(e){dh(e,t)})}function dh(r,t){var e=r.getData(),a=e.graph,n=r.getEdgeData(),i=n.count();if(i){var o=Lo(r,t),l=o.cx,s=o.cy,u=o.r,v=o.r0,c=Math.max((r.get("padAngle")||0)*Cr,0),h=Math.max((r.get("minA
1ngle")||0)*Cr,0),f=-r.get("startAngle")*Cr,g=f+Math.PI*2,p=r.get("clockwise"),d=p?1:-1,m=[f,g];an(m,!p);var y=m[0],S=m[1],b=S-y,w=e.getSum("value")===0&&n.getSum("value")===0,_=[],D=0;a.eachEdge(function(C){var M=w?1:C.getValue("value");w&&(M>0||h)&&(D+=2);var k=C.node1.dataIndex,O=C.node2.dataIndex;_[k]=(_[k]||0)+M,_[O]=(_[O]||0)+M});var A=0;if(a.eachNode(function(C){var M=C.getValue("value");isNaN(M)||(_[C.dataIndex]=Math.max(M,_[C.dataIndex]||0)),!w&&(_[C.dataIndex]>0||h)&&D++,A+=_[C.dataIndex]||0}),!(D===0||A===0)){c*D>=Math.abs(b)&&(c=Math.max(0,(Math.abs(b)-h*D)/D)),(c+h)*D>=Math.abs(b)&&(h=(Math.abs(b)-c*D)/D);var P=(b-c*D*d)/A,I=0,x=0,L=0;a.eachNode(function(C){var M=_[C.dataIndex]||0,k=P*(A?M:1)*d;Math.abs(k)<h?I+=h-Math.abs(k):(x+=Math.abs(k)-h,L+=Math.abs(k)),C.setLayout({angle:k,value:M})});var E=!1;if(I>x){var V=I/x;a.eachNode(function(C){var M=C.getLayout().angle;Math.abs(M)>=h?C.setLayout({angle:M*V,ratio:V},!0):C.setLayout({angle:h,ratio:h===0?1:M/h},!0)})}else a.eachNode(function(C){if(!E){var M=C.getLayout().angle,k=Math.min(M/L,1),O=k*I;M-O<h&&(E=!0)}});var T=I;a.eachNode(function(C){if(!(T<=0)){var M=C.getLayout().angle;if(M>h&&h>0){var k=E?1:Math.min(M/L,1),O=M-h,B=Math.min(O,Math.min(T,I*k));T-=B,C.setLayout({angle:M-B,ratio:(M-B)/M},!0)}else h>0&&C.setLayout({angle:h,ratio:M===0?1:h/M},!0)}});var R=y,N=[];a.eachNode(function(C){var M=Math.max(C.getLayout().angle,h);C.setLayout({cx:l,cy:s,r0:v,r:u,startAngle:R,endAngle:R+M*d,clockwise:p},!0),N[C.dataIndex]=R,R+=(M+c)*d}),a.eachEdge(function(C){var M=w?1:C.getValue("value"),k=P*(A?M:1)*d,O=C.node1.dataIndex,B=N[O]||0,W=Math.abs((C.node1.getLayout().ratio||1)*k),H=B+W*d,X=[l+v*Math.cos(B),s+v*Math.sin(B)],ve=[l+v*Math.cos(H),s+v*Math.sin(H)],me=C.node2.dataIndex,Y=N[me]||0,F=Math.abs((C.node2.getLayout().ratio||1)*k),q=Y+F*d,K=[l+v*Math.cos(Y),s+v*Math.sin(Y)],te=[l+v*Math.cos(q),s+v*Math.sin(q)];C.setLayout({s1:X,s2:ve,sStartAngle:B,sEndAngle:H,t1:K,t2:te,tStartAngle:Y,tEndAngle:q,cx:l,cy:s,r:v,value:M,clockwise:p}),N[O]=H,N[me]=q})}}}function yp(r){r.registerChartView(fh),r.registerSeriesModel(vh),r.registerLayout(r.PRIORITY.VISUAL.POST_CHART_LAYOUT,gh),r.registerProcessor(ba("chord"))}var yh=function(){function r(){this.angle=0,this.width=10,this.r=10,this.x=0,this.y=0}return r}(),mh=function(r){z(t,r);function t(e){var a=r.call(this,e)||this;return a.type="pointer",a}return t.prototype.getDefaultShape=function(){return new yh},t.prototype.buildPath=function(e,a){var n=Math.cos,i=Math.sin,o=a.r,l=a.width,s=a.angle,u=a.x-n(s)*l*(l>=o/3?1:2),v=a.y-i(s)*l*(l>=o/3?1:2);s=a.angle-Math.PI/2,e.moveTo(u,v),e.lineTo(a.x+n(s)*l,a.y+i(s)*l),e.lineTo(a.x+n(a.angle)*o,a.y+i(a.angle)*o),e.lineTo(a.x-n(s)*l,a.y-i(s)*l),e.lineTo(u,v)},t}(xe);function Sh(r,t){var e=r.get("center"),a=t.getWidth(),n=t.getHeight(),i=Math.min(a,n),o=U(e[0],t.getWidth()),l=U(e[1],t.getHeight()),s=U(r.get("radius"),i/2);return{cx:o,cy:l,r:s}}function Ta(r,t){var e=r==null?"":r+"";return t&&(Le(t)?e=t.replace("{value}",e):Ie(t)&&(e=t(r))),e}var bh=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,a,n){this.group.removeAll();var i=e.get(["axisLine","lineStyle","color"]),o=Sh(e,n);this._renderMain(e,a,n,i,o),this._data=e.getData()},t.prototype.dispose=function(){},t.prototype._renderMain=function(e,a,n,i,o){var l=this.group,s=e.get("clockwise"),u=-e.get("startAngle")/180*Math.PI,v=-e.get("endAngle")/180*Math.PI,c=e.getModel("axisLine"),h=c.get("roundCap"),f=h?Ha:je,g=c.get("show"),p=c.getModel("lineStyle"),d=p.get("width"),m=[u,v];an(m,!s),u=m[0],v=m[1];for(var y=v-u,S=u,b=[],w=0;g&&w<i.length;w++){var _=Math.min(Math.max(i[w][0],0),1);v=u+y*_;var D=new f({shape:{startAngle:S,endAngle:v,cx:o.cx,cy:o.cy,clockwise:s,r0:o.r-d,r:o.r},silent:!0});D.setStyle({fill:i[w][1]}),D.setStyle(p.getLineStyle(["color","width"])),b.push(D),S=v}b.reverse(),G(b,function(P){return l.add(P)});var A=function(P){if(P<=0)return i[0][1];var I;for(I=0;I<i.length;I++)if(i[I][0]>=P&&(I===0?0:i[I-1][0])<P)return i[I][1];return i[I-1][1]};this._renderTicks(e,a,n,A,o,u,v,s,d),this._renderTitleAndDetail(e,a,n,A,o),this._renderAnchor(e,o),this._renderPointer(e,a,n,A,o,u,v,s,d)},t.prototype._renderTicks=function(e,a,n,i,o,l,s,u,v){for(var c=this.group,h=o.cx,f=o.cy,g=o.r,p=+e.get("min"),d=+e.get("max"),m=e.getModel("splitLine"),y=e.getModel("axisTick"),S=e.getModel("axisLabel"),b=e.get("splitNumber"),w=y.get("splitNumber"),_=U(m.get("length"),g),D=U(y.get("length"),g),A=l,P=(s-l)/b,I=P/w,x=m.getModel("lineStyle").getLineStyle(),L=y.getModel("lineStyle").getLineStyle(),E=m.get("distance"),V,T,R=0;R<=b;R++){if(V=Math.cos(A),T=Math.sin(A),m.get("show")){var N=E?E+v:v,C=new qn({shape:{x1:V*(g-N)+h,y1:T*(g-N)+f,x2:V*(g-_-N)+h,y2:T*(g-_-N)+f},style:x,silent:!0});x.stroke==="auto"&&C.setStyle({stroke:i(R/b)}),c.add(C)}if(S.get("show")){var N=S.get("distance")+E,M=Ta(Zt(R*(d-p)/b+p,$s),S.get("formatter")),k=i(R/b),O=V*(g-_-N)+h,B=T*(g-_-N)+f,W=S.get("rotate"),H=0;W==="radial"?(H=-A+2*Math.PI,H>Math.PI/2&&(H+=Math.PI)):W==="tangential"?H=-A-Math.PI/2:Ne(W)&&(H=W*Math.PI/180),H===0?c.add(new Me({style:$e(S,{text:M,x:O,y:B,verticalAlign:T<-.8?"top":T>
1.8?"bottom":"middle",align:V<-.4?"left":V>.4?"right":"center"},{inheritColor:k}),silent:!0})):c.add(new Me({style:$e(S,{text:M,x:O,y:B,verticalAlign:"middle",align:"center"},{inheritColor:k}),silent:!0,originX:O,originY:B,rotation:H}))}if(y.get("show")&&R!==b){var N=y.get("distance");N=N?N+v:v;for(var X=0;X<=w;X++){V=Math.cos(A),T=Math.sin(A);var ve=new qn({shape:{x1:V*(g-N)+h,y1:T*(g-N)+f,x2:V*(g-D-N)+h,y2:T*(g-D-N)+f},silent:!0,style:L});L.stroke==="auto"&&ve.setStyle({stroke:i((R+X/w)/b)}),c.add(ve),A+=I}A-=I}else A+=P}},t.prototype._renderPointer=function(e,a,n,i,o,l,s,u,v){var c=this.group,h=this._data,f=this._progressEls,g=[],p=e.get(["pointer","show"]),d=e.getModel("progress"),m=d.get("show"),y=e.getData(),S=y.mapDimension("value"),b=+e.get("min"),w=+e.get("max"),_=[b,w],D=[l,s];function A(I,x){var L=y.getItemModel(I),E=L.getModel("pointer"),V=U(E.get("width"),o.r),T=U(E.get("length"),o.r),R=e.get(["pointer","icon"]),N=E.get("offsetCenter"),C=U(N[0],o.r),M=U(N[1],o.r),k=E.get("keepAspect"),O;return R?O=Ke(R,C-V/2,M-T,V,T,null,k):O=new mh({shape:{angle:-Math.PI/2,width:V,r:T,x:C,y:M}}),O.rotation=-(x+Math.PI/2),O.x=o.cx,O.y=o.cy,O}function P(I,x){var L=d.get("roundCap"),E=L?Ha:je,V=d.get("overlap"),T=V?d.get("width"):v/y.count(),R=V?o.r-T:o.r-(I+1)*T,N=V?o.r:o.r-I*T,C=new E({shape:{startAngle:l,endAngle:x,cx:o.cx,cy:o.cy,clockwise:u,r0:R,r:N}});return V&&(C.z2=Pe(y.get(S,I),[b,w],[100,0],!0)),C}(m||p)&&(y.diff(h).add(function(I){var x=y.get(S,I);if(p){var L=A(I,l);ue(L,{rotation:-((isNaN(+x)?D[0]:Pe(x,_,D,!0))+Math.PI/2)},e),c.add(L),y.setItemGraphicEl(I,L)}if(m){var E=P(I,l),V=d.get("clip");ue(E,{shape:{endAngle:Pe(x,_,D,V)}},e),c.add(E),Kn(e.seriesIndex,y.dataType,I,E),g[I]=E}}).update(function(I,x){var L=y.get(S,I);if(p){var E=h.getItemGraphicEl(x),V=E?E.rotation:l,T=A(I,V);T.rotation=V,J(T,{rotation:-((isNaN(+L)?D[0]:Pe(L,_,D,!0))+Math.PI/2)},e),c.add(T),y.setItemGraphicEl(I,T)}if(m){var R=f[x],N=R?R.shape.endAngle:l,C=P(I,N),M=d.get("clip");J(C,{shape:{endAngle:Pe(L,_,D,M)}},e),c.add(C),Kn(e.seriesIndex,y.dataType,I,C),g[I]=C}}).execute(),y.each(function(I){var x=y.getItemModel(I),L=x.getModel("emphasis"),E=L.get("focus"),V=L.get("blurScope"),T=L.get("disabled"),R=i(Pe(y.get(S,I),_,[0,1],!0));if(p){var N=y.getItemGraphicEl(I),C=y.getItemVisual(I,"style"),M=C.fill;if(N instanceof pa){var k=N.style;N.useStyle($({image:k.image,x:k.x,y:k.y,width:k.width,height:k.height},C))}else N.useStyle(C),N.type!=="pointer"&&N.setColor(M);N.setStyle(x.getModel(["pointer","itemStyle"]).getItemStyle()),N.style.fill==="auto"&&N.setStyle("fill",R),N.z2EmphasisLift=0,ce(N,x),ie(N,E,V,T)}if(m){var O=g[I];O.useStyle(y.getItemVisual(I,"style")),O.setStyle(x.getModel(["progress","itemStyle"]).getItemStyle()),O.style.fill==="auto"&&O.setStyle("fill",R),O.z2EmphasisLift=0,ce(O,x),ie(O,E,V,T)}}),this._progressEls=g)},t.prototype._renderAnchor=function(e,a){var n=e.getModel("anchor"),i=n.get("show");if(i){var o=n.get("size"),l=n.get("icon"),s=n.get("offsetCenter"),u=n.get("keepAspect"),v=Ke(l,a.cx-o/2+U(s[0],a.r),a.cy-o/2+U(s[1],a.r),o,o,null,u);v.z2=n.get("showAbove")?1:0,v.setStyle(n.getModel("itemStyle").getItemStyle()),this.group.add(v)}},t.prototype._renderTitleAndDetail=function(e,a,n,i,o){var l=this,s=e.getData(),u=s.mapDimension("value"),v=+e.get("min"),c=+e.get("max"),h=new j,f=[],g=[],p=e.isAnimationEnabled(),d=e.get(["pointer","showAbove"]);s.diff(this._data).add(function(m){f[m]=new Me({silent:!0}),g[m]=new Me({silent:!0})}).update(function(m,y){f[m]=l._titleEls[y],g[m]=l._detailEls[y]}).execute(),s.each(function(m){var y=s.getItemModel(m),S=s.get(u,m),b=new j,w=i(Pe(S,[v,c],[0,1],!0)),_=y.getModel("title");if(_.get("show")){var D=_.get("offsetCenter"),A=o.cx+U(D[0],o.r),P=o.cy+U(D[1],o.r),I=f[m];I.attr({z2:d?0:2,style:$e(_,{x:A,y:P,text:s.getName(m),align:"center",verticalAlign:"middle"},{inheritColor:w})}),b.add(I)}var x=y.getModel("detail");if(x.get("show")){var L=x.get("offsetCenter"),E=o.cx+U(L[0],o.r),V=o.cy+U(L[1],o.r),T=U(x.get("width"),o.r),R=U(x.get("height"),o.r),N=e.get(["progress","show"])?s.getItemVisual(m,"style").fill:w,I=g[m],C=x.get("formatter");I.attr({z2:d?0:2,style:$e(x,{x:E,y:V,text:Ta(S,C),width:isNaN(T)?null:T,height:isNaN(R)?null:R,align:"center",verticalAlign:"middle"},{inheritColor:N})}),Ao(I,{normal:x},S,function(k){return Ta(k,C)}),p&&Xs(I,m,s,e,{getFormattedLabel:function(k,O,B,W,H,X){return Ta(X?X.interpolatedValue:S,C)}}),b.add(I)}h.add(b)}),this.group.add(h),this._titleEls=f,this._detailEls=g},t.type="gauge",t}(ae),wh=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.visualStyleAccessPath="itemStyle",e}return t.prototype.getInitialData=function(e,a){return ma(this,["value"])},t.type="series.gauge",t.defaultOption={z:2,colorBy:"data",center:["50%","50%"],legendHoverLink:!0,radius:"75%",startAngle:225,endAngle:-45,clockwise:!0,min:0,max:100,splitNumber:10,axisLine
1:{show:!0,roundCap:!1,lineStyle:{color:[[1,Z.color.neutral10]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:Z.color.axisTick,width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:Z.color.axisTickMinor,width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:Z.color.axisLabel,fontSize:12,rotate:0},pointer:{icon:null,offsetCenter:[0,0],show:!0,showAbove:!0,length:"60%",width:6,keepAspect:!1},anchor:{show:!1,showAbove:!1,size:6,icon:"circle",offsetCenter:[0,0],keepAspect:!1,itemStyle:{color:Z.color.neutral00,borderWidth:0,borderColor:Z.color.theme[0]}},title:{show:!0,offsetCenter:[0,"20%"],color:Z.color.secondary,fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:Z.color.transparent,borderWidth:0,borderColor:Z.color.neutral40,width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:Z.color.primary,fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},t}(se);function mp(r){r.registerChartView(bh),r.registerSeriesModel(wh)}var Ot="funnel",_h=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(e){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Ut(le(this.getData,this),le(this.getRawData,this)),this._defaultLabelLine(e)},t.prototype.getInitialData=function(e,a){return ma(this,{coordDimensions:["value"],encodeDefaulter:Xe(Io,this)})},t.prototype._defaultLabelLine=function(e){un(e,"labelLine",["show"]);var a=e.labelLine,n=e.emphasis.labelLine;a.show=a.show&&e.label.show,n.show=n.show&&e.emphasis.label.show},t.prototype.getDataParams=function(e){var a=this.getData(),n=r.prototype.getDataParams.call(this,e),i=a.mapDimension("value"),o=a.getSum(i);return n.percent=o?+(a.get(i,e)/o*100).toFixed(2):0,n.$vars.push("percent"),n},t.type="series."+Ot,t.defaultOption={coordinateSystemUsage:"box",z:2,legendHoverLink:!0,colorBy:"data",left:80,top:60,right:80,bottom:65,minSize:"0%",maxSize:"100%",sort:"descending",orient:"vertical",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1}},itemStyle:{borderColor:Z.color.neutral00,borderWidth:1},emphasis:{label:{show:!0}},select:{itemStyle:{borderColor:Z.color.primary}}},t}(se),Dh=["itemStyle","opacity"],xh=function(r){z(t,r);function t(e,a){var n=r.call(this)||this,i=n,o=new zt,l=new Me;return i.setTextContent(l),n.setTextGuideLine(o),n.updateData(e,a,!0),n}return t.prototype.updateData=function(e,a,n){var i=this,o=e.hostModel,l=e.getItemModel(a),s=e.getItemLayout(a),u=l.getModel("emphasis"),v=l.get(Dh);v=v??1,n||Oe(i),i.useStyle(e.getItemVisual(a,"style")),i.style.lineJoin="round",n?(i.setShape({points:s.points}),i.style.opacity=0,ue(i,{style:{opacity:v}},o,a)):J(i,{style:{opacity:v},shape:{points:s.points}},o,a),ce(i,l),this._updateLabel(e,a),ie(this,u.get("focus"),u.get("blurScope"),u.get("disabled"))},t.prototype._updateLabel=function(e,a){var n=this,i=this.getTextGuideLine(),o=n.getTextContent(),l=e.hostModel,s=e.getItemModel(a),u=e.getItemLayout(a),v=u.label,c=e.getItemVisual(a,"style"),h=c.fill;Ce(o,De(s),{labelFetcher:e.hostModel,labelDataIndex:a,defaultOpacity:c.opacity,defaultText:e.getName(a)},{normal:{align:v.textAlign,verticalAlign:v.verticalAlign}});var f=s.getModel("label"),g=f.get("color"),p=g==="inherit"?h:null;n.setTextConfig({local:!0,inside:!!v.inside,insideStroke:p,outsideFill:p});var d=v.linePoints;i.setShape({points:d}),n.textGuideLineConfig={anchor:d?new ge(d[0][0],d[0][1]):null},J(o,{style:{x:v.x,y:v.y}},l,a),o.attr({rotation:v.rotation,originX:v.x,originY:v.y,z2:10}),jo(n,Jo(s),{stroke:h})},t}(vn),Ah=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=Ot,e.ignoreLabelLineUpdate=!0,e}return t.prototype.render=function(e,a,n){var i=e.getData(),o=this._data,l=this.group;i.diff(o).add(function(s){var u=new xh(i,s);i.setItemGraphicEl(s,u),l.add(u)}).update(function(s,u){var v=o.getItemGraphicEl(u);v.updateData(i,s),l.add(v),i.setItemGraphicEl(s,v)}).remove(function(s){var u=o.getItemGraphicEl(s);ut(u,e,s)}).execute(),this._data=i},t.prototype.remove=function(){this.group.removeAll(),this._data=null},t.prototype.dispose=function(){},t.type=Ot,t}(ae);function Ih(r,t){for(var e=r.mapDimension("value"),a=r.mapArray(e,function(s){return s}),n=[],i=t==="ascending",o=0,l=r.count();o<l;o++)n[o]=o;return Ie(t)?n.sort(t):t!=="none"&&n.sort(function(s,u){return i?a[s]-a[u]:a[u]-a[s]}),n}function Lh(r){var t=r.hostModel,e=Fl(t);r.each(function(a){var n=r.getItemModel(a),i=n.getModel("label"),o=i.get("position"),l=n.getModel("labelLine"),s=r.getItemLayout(a),u=s.points,v=o==="inner"||o==="inside"||o==="center"||o==="insideLeft"||o==="insideRight",c,h,f,g;if(v)o==="insideLeft"?(h=(u[0][0]+u[3][0])/2+5,f=(u[0][1]+u[3][1])/2,c="left"):o==="insideRight"?(h=(u[1][0]+u[2][0])/2-5,f=(u[1][1]+u[2][1])/2,c="right"):(h=(u[0][0]+u[1][0]+u[2][0]+u[3][0])/4,f
1=(u[0][1]+u[1][1]+u[2][1]+u[3][1])/4,c="center"),g=[[h,f],[h,f]];else{var p=void 0,d=void 0,m=void 0,y=void 0,S=l.get("length");Le(o)&&(!e&&ke(["top","bottom"],o)>-1&&(o="left"),e&&ke(["left","right"],o)>-1&&(o="bottom")),o==="left"?(p=(u[3][0]+u[0][0])/2,d=(u[3][1]+u[0][1])/2,m=p-S,h=m-5,c="right"):o==="right"?(p=(u[1][0]+u[2][0])/2,d=(u[1][1]+u[2][1])/2,m=p+S,h=m+5,c="left"):o==="top"?(p=(u[3][0]+u[0][0])/2,d=(u[3][1]+u[0][1])/2,y=d-S,f=y-5,c="center"):o==="bottom"?(p=(u[1][0]+u[2][0])/2,d=(u[1][1]+u[2][1])/2,y=d+S,f=y+5,c="center"):o==="rightTop"?(p=e?u[3][0]:u[1][0],d=e?u[3][1]:u[1][1],e?(y=d-S,f=y-5,c="center"):(m=p+S,h=m+5,c="top")):o==="rightBottom"?(p=u[2][0],d=u[2][1],e?(y=d+S,f=y+5,c="center"):(m=p+S,h=m+5,c="bottom")):o==="leftTop"?(p=u[0][0],d=e?u[0][1]:u[1][1],e?(y=d-S,f=y-5,c="center"):(m=p-S,h=m-5,c="right")):o==="leftBottom"?(p=e?u[1][0]:u[3][0],d=e?u[1][1]:u[2][1],e?(y=d+S,f=y+5,c="center"):(m=p-S,h=m-5,c="right")):(p=(u[1][0]+u[2][0])/2,d=(u[1][1]+u[2][1])/2,e?(y=d+S,f=y+5,c="center"):(m=p+S,h=m+5,c="left")),e?(m=p,h=m):(y=d,f=y),g=[[p,d],[m,y]]}s.label={linePoints:g,x:h,y:f,verticalAlign:"middle",textAlign:c,inside:v}})}var Ch=he(Ot,Th);function Th(r,t){r.eachSeriesByType(Ot,function(e){var a=e.getData(),n=a.mapDimension("value"),i=e.get("sort"),o=Ht(e,t),l=Wt(e.getBoxLayoutParams(),o.refContainer),s=Fl(e),u=l.width,v=l.height,c=Ih(a,i),h=l.x,f=l.y,g=s?[U(e.get("minSize"),v),U(e.get("maxSize"),v)]:[U(e.get("minSize"),u),U(e.get("maxSize"),u)],p=a.getDataExtent(n),d=e.get("min"),m=e.get("max");d==null&&(d=Math.min(p[0],0)),m==null&&(m=p[1]);var y=e.get("funnelAlign"),S=e.get("gap"),b=s?u:v,w=(b-S*(a.count()-1))/a.count(),_=function(T,R){if(s){var N=a.get(n,T)||0,C=Pe(N,[d,m],g,!0),M=void 0;switch(y){case"top":M=f;break;case"center":M=f+(v-C)/2;break;case"bottom":M=f+(v-C);break}return[[R,M],[R,M+C]]}var k=a.get(n,T)||0,O=Pe(k,[d,m],g,!0),B;switch(y){case"left":B=h;break;case"center":B=h+(u-O)/2;break;case"right":B=h+u-O;break}return[[B,R],[B+O,R]]};i==="ascending"&&(w=-w,S=-S,s?h+=u:f+=v,c=c.reverse());for(var D=0;D<c.length;D++){var A=c[D],P=c[D+1],I=a.getItemModel(A);if(s){var x=I.get(["itemStyle","width"]);x==null?x=w:(x=U(x,u),i==="ascending"&&(x=-x));var L=_(A,h),E=_(P,h+x);h+=x+S,a.setItemLayout(A,{points:L.concat(E.slice().reverse())})}else{var V=I.get(["itemStyle","height"]);V==null?V=w:(V=U(V,v),i==="ascending"&&(V=-V));var L=_(A,f),E=_(P,f+V);f+=V+S,a.setItemLayout(A,{points:L.concat(E.slice().reverse())})}}Lh(a)})}function Fl(r){return r.get("orient")==="horizontal"}function Sp(r){r.registerChartView(Ah),r.registerSeriesModel(_h),r.registerLayout(Ch),r.registerProcessor(ba(Ot))}var Ph=.3,Eh=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e._dataGroup=new j,e._initialized=!1,e}return t.prototype.init=function(){this.group.add(this._dataGroup)},t.prototype.render=function(e,a,n,i){var o=this._dataGroup;this._progressiveEls=[],o.removeAll();var l=e.getData(),s=this._data,u=e.coordinateSystem,v=u.dimensions,c=$i(e);l.diff(s).add(h).update(f).remove(g).execute();function h(d){var m=Yi(l,o,d,v,u);Tr(m,l,d,c)}function f(d,m){var y=s.getItemGraphicEl(m);o.add(y);var S=Hl(l,d,v,u);l.setItemGraphicEl(d,y),J(y,{shape:{points:S}},e,d),Oe(y),Tr(y,l,d,c)}function g(d){var m=s.getItemGraphicEl(d);o.remove(m)}if(!this._initialized){this._initialized=!0;var p=Rh(u,e,function(){setTimeout(function(){o.removeClipPath()})});o.setClipPath(p)}this._data=l},t.prototype.incrementalPrepareRender=function(e,a,n){this._initialized=!0,this._data=null,this._dataGroup.removeAll()},t.prototype.incrementalRender=function(e,a,n){for(var i=a.getData(),o=a.coordinateSystem,l=this._progressiveEls=[],s=e.start;s<e.end;s++){var u=Yi(i,this._dataGroup,s,o.dimensions,o);u.incremental=We(a),Tr(u,i,s,$i(a)),l.push(u)}},t.prototype.remove=function(){this._dataGroup&&this._dataGroup.removeAll(),this._data=null},t.type="parallel",t}(ae);function Rh(r,t,e){var a=r.model,n=r.getRect(),i=new Ae({shape:{x:n.x,y:n.y,width:n.width,height:n.height}}),o=a.get("layout")==="horizontal"?"width":"height";return i.setShape(o,0),ue(i,{shape:{width:n.width,height:n.height}},t,e),i}function Hl(r,t,e,a){for(var n=[],i=0;i<e.length;i++){var o=e[i],l=r.get(r.mapDimension(o),t);Nh(l,a.getAxis(o).type)||n.push(a.dataToPoint(l,o))}return n}function Yi(r,t,e,a,n){var i=Hl(r,e,a,n),o=new zt({shape:{points:i},z2:10});return t.add(o),r.setItemGraphicEl(e,o),o}function $i(r){var t=r.get("smooth",!0);return t===!0&&(t=Ph),t=Zs(t),Ea(t)&&(t=0),{smooth:t}}function Tr(r,t,e,a){r.useStyle(t.getItemVisual(e,"style")),r.style.fill=null,r.setShape("smooth",a.smooth);var n=t.getItemModel(e),i=n.getModel("emphasis");ce(r,n,"lineStyle"),ie(r,i.get("focus"),i.get("blurScope"),i.get("disabled"))}function Nh(r,t){return t==="category"?r==null:r==null||isNaN(r)}var Mh=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.visualStyleAccessPath="lineStyle",e.visualDrawType="stroke",e}return t.prototype.getInitialData=function(e,a){return et(null,this,{useEncodeDefaulter:le(V
1h,null,this)})},t.prototype.getRawIndicesByActiveState=function(e){var a=this.coordinateSystem,n=this.getData(),i=[];return a.eachActiveState(n,function(o,l){e===o&&i.push(n.getRawIndex(l))}),i},t.type="series.parallel",t.dependencies=["parallel"],t.defaultOption={z:2,coordinateSystem:"parallel",parallelIndex:0,label:{show:!1},inactiveOpacity:.05,activeOpacity:1,lineStyle:{width:1,opacity:.45,type:"solid"},emphasis:{label:{show:!1}},progressive:300,smooth:!1,animationEasing:"linear"},t}(se);function Vh(r){var t=r.ecModel.getComponent("parallel",r.get("parallelIndex"));if(t){var e={};return G(t.dimensions,function(a){var n=kh(a);e[a]=n}),e}}function kh(r){return+r.replace("dim","")}var Oh=["lineStyle","opacity"],Gh={seriesType:"parallel",reset:function(r,t){var e=r.coordinateSystem,a={normal:r.get(["lineStyle","opacity"]),active:r.get("activeOpacity"),inactive:r.get("inactiveOpacity")};return{progress:function(n,i){e.eachActiveState(i,function(o,l){var s=a[o];if(o==="normal"&&i.hasItemOption){var u=i.getItemModel(l).get(Oh,!0);u!=null&&(s=u)}var v=i.ensureUniqueItemVisual(l,"style");v.opacity=s},n.start,n.end)}}}};function bp(r){Ka(yu),r.registerChartView(Eh),r.registerSeriesModel(Mh),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,Gh)}var Qe="sankey",Bh=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.getInitialData=function(e,a){var n=e.edges||e.links||[],i=e.data||e.nodes||[],o=e.levels||[];this.levelModels=[];for(var l=this.levelModels,s=0;s<o.length;s++)o[s].depth!=null&&o[s].depth>=0&&(l[o[s].depth]=new ht(o[s],this,a));var u=wn(i,n,this,!0,v);return u.data;function v(c,h){c.wrapMethod("getItemModel",function(f,g){var p=f.parentModel,d=p.getData().getItemLayout(g);if(d){var m=d.depth,y=p.levelModels[m];y&&(f.parentModel=y)}return f}),h.wrapMethod("getItemModel",function(f,g){var p=f.parentModel,d=p.getGraph().getEdgeByIndex(g),m=d.node1.getLayout();if(m){var y=m.depth,S=p.levelModels[y];S&&(f.parentModel=S)}return f})}},t.prototype.setNodePosition=function(e,a){var n=this.option.data||this.option.nodes,i=n[e];
1i.localX=a[0],i.localY=a[1]},t.prototype.getGraph=function(){return this.getData().graph},t.prototype.getEdgeData=function(){return this.getGraph().edgeData},t.prototype.formatTooltip=function(e,a,n){function i(f){return isNaN(f)||f==null}if(n==="edge"){var o=this.getDataParams(e,n),l=o.data,s=o.value,u=l.source+" -- "+l.target;return Ge("nameValue",{name:u,value:s,noValue:i(s)})}else{var v=this.getGraph().getNodeByIndex(e),c=v.getLayout().value,h=this.getDataParams(e,n).data.name;return Ge("nameValue",{name:h!=null?h+"":null,value:c,noValue:i(c)})}},t.prototype.optionUpdated=function(){},t.prototype.getDataParams=function(e,a){var n=r.prototype.getDataParams.call(this,e,a);if(n.value==null&&a==="node"){var i=this.getGraph().getNodeByIndex(e),o=i.getLayout().value;n.value=o}return n},t.prototype.__ownRoamView=function(){return this.coordinateSystem},t.type="series."+Qe,t.layoutMode="box",t.defaultOption={z:2,coordinateSystemUsage:"box",left:"5%",top:"5%",right:"20%",bottom:"5%",orient:"horizontal",nodeWidth:20,nodeGap:8,draggable:!0,layoutIterations:32,roam:!1,roamTrigger:"global",center:null,zoom:1,label:{show:!0,position:"right",fontSize:12},edgeLabel:{show:!1,fontSize:12},levels:[],nodeAlign:"justify",lineStyle:{color:Z.color.neutral50,opacity:.2,curveness:.5},emphasis:{label:{show:!0},lineStyle:{opacity:.5}},select:{itemStyle:{borderColor:Z.color.primary}},animationEasing:"linear",animationDuration:1e3},t}(se),zh=function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.cpx2=0,this.cpy2=0,this.extent=0}return r}(),Fh=function(r){z(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new zh},t.prototype.buildPath=function(e,a){var n=a.extent;e.moveTo(a.x1,a.y1),e.bezierCurveTo(a.cpx1,a.cpy1,a.cpx2,a.cpy2,a.x2,a.y2),a.orient==="vertical"?(e.lineTo(a.x2+n,a.y2),e.bezierCurveTo(a.cpx2+n,a.cpy2,a.cpx1+n,a.cpy1,a.x1+n,a.y1)):(e.lineTo(a.x2,a.y2+n),e.bezierCurveTo(a.cpx2,a.cpy2+n,a.cpx1,a.cpy1+n,a.x1,a.y1+n)),e.closePath()},t.prototype.highlight=function(){No(this)},t.prototype.downplay=function(){Mo(this)},t}(xe),Hh=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=Qe,e._mainGroup=new j,e}return t.prototype.init=function(e,a){this._controller=new rr(a.getZr()),this.group.add(this._mainGroup),this._firstRender=!0},t.prototype.render=function(e,a,n){var i=e.getGraph(),o=this._mainGroup,l=e.layoutInfo,s=l.width,u=l.height,v=e.getData(),c=e.getData("edge"),h=e.get("orient");o.removeAll(),o.x=l.x,o.y=l.y,this._updateViewCoordSys(e,n),fn(e,n,this._controller,Ho(o),null),i.eachEdge(function(f){var g=new Fh,p=ne(g);p.dataIndex=f.dataIndex,p.seriesIndex=e.seriesIndex,p.dataType="edge";var d=f.getModel(),m=d.getModel("lineStyle"),y=m.get("curveness"),S=f.node1.getLayout(),b=f.node1.getModel(),w=b.get("localX"),_=b.get("localY"),D=f.node2.getLayout(),A=f.node2.getModel(),P=A.get("localX"),I=A.get("localY"),x=f.getLayout(),L,E,V,T,R,N,C,M;g.shape.extent=Math.max(1,x.dy),g.shape.orient=h,h==="vertical"?(L=(w!=null?w*s:S.x)+x.sy,E=(_!=null?_*u:S.y)+S.dy,V=(P!=null?P*s:D.x)+x.ty,T=I!=null?I*u:D.y,R=L,N=E*(1-y)+T*y,C=V,M=E*y+T*(1-y)):(L=(w!=null?w*s:S.x)+S.dx,E=(_!=null?_*u:S.y)+x.sy,V=P!=null?P*s:D.x,T=(I!=null?I*u:D.y)+x.ty,R=L*(1-y)+V*y,N=E,C=L*y+V*(1-y),M=T),g.setShape({x1:L,y1:E,x2:V,y2:T,cpx1:R,cpy1:N,cpx2:C,cpy2:M}),g.useStyle(m.getItemStyle()),Xi(g.style,h,f);var k=""+d.get("value"),O=De(d,"edgeLabel");Ce(g,O,{labelFetcher:{getFormattedLabel:function(H,X,ve,me,Y,F){return e.getFormattedLabel(H,X,"edge",me,xt(Y,O.normal&&O.normal.get("formatter"),k),F)}},labelDataIndex:f.dataIndex,defaultText:k}),g.setTextConfig({position:"inside"});var B=d.getModel("emphasis");ce(g,d,"lineStyle",function(H){var X=H.getItemStyle();return Xi(X,h,f),X}),o.add(g),c.setItemGraphicEl(f.dataIndex,g);var W=B.get("focus");ie(g,W==="adjacency"?f.getAdjacentDataIndices():W==="trajectory"?f.getTrajectoryDataIndices():W,B.get("blurScope"),B.get("disabled"))}),i.eachNode(function(f){var g=f.getLayout(),p=f.getModel(),d=p.get("localX"),m=p.get("localY"),y=p.getModel("emphasis"),S=p.get(["itemStyle","borderRadius"])||0,b=new Ae({shape:{x:d!=null?d*s:g.x,y:m!=null?m*u:g.y,width:g.dx,height:g.dy,r:S},style:p.getModel("itemStyle").getItemStyle(),z2:10});Ce(b,De(p),{labelFetcher:{getFormattedLabel:function(_,D){return e.getFormattedLabel(_,D,"node")}},labelDataIndex:f.dataIndex,defaultText:f.id}),b.disableLabelAnimation=!0,b.setStyle("fill",f.getVisual("color")),b.setStyle("decal",f.getVisual("style").decal),ce(b,p),o.add(b),v.setItemGraphicEl(f.dataIndex,b),ne(b).dataType="node";var w=y.get("focus");ie(b,w==="adjacency"?f.getAdjacentDataIndices():w==="trajectory"?f.getTrajectoryDataIndices():w,y.get("blurScope"),y.get("disabled"))}),v.eachItemGraphicEl(function(f,g){var p=v.getItemModel(g);p.get("draggable")&&(f.drift=function(d,m){this.shape.x+=d,this.shape.y+=m,this.dirty(),n.dispatchAction({type:"dragNode",seriesId:e.id,dataIndex:v.getRawIndex(g),localX:this.shape.x/s,localY:this.shape.y/u})},f.draggable=!0,f.cursor="move")}),!this._data&&e.isAnimationEnabled()&&o.setClipPath(Wh(o.getBoundingRect
1(),e,function(){o.removeClipPath()})),this._data=e.getData(),this._firstRender=!1},t.prototype.__updateOnOwnRoam=function(e,a,n){Vt(this.group,kt,a.coordinateSystem,null)},t.prototype.dispose=function(){this._controller&&this._controller.dispose()},t.prototype._updateViewCoordSys=function(e,a){var n=e.layoutInfo,i=e.coordinateSystem=gn(e,a,n.x,n.y,n.width,n.height);Vt(this.group,kt,i,this._firstRender?null:e)},t.type=Qe,t}(ae);function Xi(r,t,e){switch(r.fill){case"source":r.fill=e.node1.getVisual("color"),r.decal=e.node1.getVisual("style").decal;break;case"target":r.fill=e.node2.getVisual("color"),r.decal=e.node2.getVisual("style").decal;break;case"gradient":var a=e.node1.getVisual("color"),n=e.node2.getVisual("color");Le(a)&&Le(n)&&(r.fill=new on(0,0,+(t==="horizontal"),+(t==="vertical"),[{color:a,offset:0},{color:n,offset:1}]))}}function Wh(r,t,e){var a=new Ae({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return ue(a,{shape:{width:r.width+20}},t,e),a}var Uh=he(Qe,Yh);function Yh(r,t){r.eachSeriesByType(Qe,function(e){var a=e.get("nodeWidth"),n=e.get("nodeGap"),i=Ht(e,t).refContainer,o=Wt(e.getBoxLayoutParams(),i);e.layoutInfo=o;var l=o.width,s=o.height,u=e.getGraph(),v=u.nodes,c=u.edges;Xh(v);var h=rn(v,function(d){return d.getLayout().value===0}),f=h.length!==0?0:e.get("layoutIterations"),g=e.get("orient"),p=e.get("nodeAlign");$h(v,c,a,n,l,s,f,g,p)})}function $h(r,t,e,a,n,i,o,l,s){Zh(r,t,e,n,i,l,s),Jh(r,t,i,n,a,o,l),sf(r,l)}function Xh(r){G(r,function(t){var e=ct(t.outEdges,Ya),a=ct(t.inEdges,Ya),n=t.getValue()||0,i=Math.max(e,a,n);t.setLayout({value:i},!0)})}function Zh(r,t,e,a,n,i,o){for(var l=[],s=[],u=[],v=[],c=0,h=0;h<t.length;h++)l[h]=1;for(var h=0;h<r.length;h++)s[h]=r[h].inEdges.length,s[h]===0&&u.push(r[h]);for(var f=-1;u.length;){for(var g=0;g<u.length;g++){var p=u[g],d=p.hostGraph.data.getRawDataItem(p.dataIndex),m=d.depth!=null&&d.depth>=0;m&&d.depth>f&&(f=d.depth),p.setLayout({depth:m?d.depth:c},!0),i==="vertical"?p.setLayout({dy:e},!0):p.setLayout({dx:e},!0);for(var y=0;y<p.outEdges.length;y++){var S=p.outEdges[y],b=ke(t,S);l[b]=0;var w=S.node2,_=ke(r,w);--s[_]===0&&ke(v,w)<0&&v.push(w)}}++c,u=v,v=[]}for(var h=0;h<l.length;h++)if(l[h]===1)throw new Error("Sankey is a DAG, the original data has cycle!");var D=f>c-1?f:c-1;o&&o!=="left"&&qh(r,o,i,D);var A=i==="vertical"?(n-e)/D:(a-e)/D;jh(r,A,i)}function Wl(r){var t=r.hostGraph.data.getRawDataItem(r.dataIndex);return t.depth!=null&&t.depth>=0}function qh(r,t,e,a){if(t==="right"){for(var n=[],i=r,o=0;i.length;){for(var l=0;l<i.length;l++){var s=i[l];s.setLayout({skNodeHeight:o},!0);for(var u=0;u<s.inEdges.length;u++){var v=s.inEdges[u];ke(n,v.node1)<0&&n.push(v.node1)}}i=n,n=[],++o}G(r,function(c){Wl(c)||c.setLayout({depth:Math.max(0,a-c.getLayout().skNodeHeight)},!0)})}else t==="justify"&&Kh(r,a)}function Kh(r,t){G(r,function(e){!Wl(e)&&!e.outEdges.length&&e.setLayout({depth:t},!0)})}function jh(r,t,e){G(r,function(a){var n=a.getLayout().depth*t;e==="vertical"?a.setLayout({y:n},!0):a.setLayout({x:n},!0)})}function Jh(r,t,e,a,n,i,o){var l=Qh(r,o);ef(l,t,e,a,n,o),Pr(l,n,e,a,o);for(var s=1;i>0;i--)s*=.99,tf(l,s,o),Pr(l,n,e,a,o),lf(l,s,o),Pr(l,n,e,a,o)}function Qh(r,t){var e=[],a=t==="vertical"?"y":"x",n=Yr(r,function(i){return i.getLayout()[a]});return Vo(n.keys),G(n.keys,function(i){e.push(n.buckets.get(i))}),e}function ef(r,t,e,a,n,i){var o=1/0;G(r,function(l){var s=l.length,u=0;G(l,function(c){u+=c.getLayout().value});var v=i==="vertical"?(a-(s-1)*n)/u:(e-(s-1)*n)/u;v<o&&(o=v)}),G(r,function(l){G(l,function(s,u){var v=s.getLayout().value*o;i==="vertical"?(s.setLayout({x:u},!0),s.setLayout({dx:v},!0)):(s.setLayout({y:u},!0),s.setLayout({dy:v},!0))})}),G(t,function(l){var s=+l.getValue()*o;l.setLayout({dy:s},!0)})}function Pr(r,t,e,a,n){var i=n==="vertical"?"x":"y";G(r,function(o){o.sort(function(p,d){return p.getLayout()[i]-d.getLayout()[i]});for(var l,s,u,v=0,c=o.length,h=n==="vertical"?"dx":"dy",f=0;f<c;f++)s=o[f],u=v-s.getLayout()[i],u>0&&(l=s.getLayout()[i]+u,n==="vertical"?s.setLayout({x:l},!0):s.setLayout({y:l},!0)),v=s.getLayout()[i]+s.getLayout()[h]+t;var g=n==="vertical"?a:e;if(u=v-t-g,u>0){l=s.getLayout()[i]-u,n==="vertical"?s.setLayout({x:l},!0):s.setLayout({y:l},!0),v=l;for(var f=c-2;f>=0;--f)s=o[f],u=s.getLayout()[i]+s.getLayout()[h]+t-v,u>0&&(l=s.getLayout()[i]-u,n==="vertical"?s.setLayout({x:l},!0):s.setLayout({y:l},!0)),v=s.getLayout()[i]}})}function tf(r,t,e){G(r.slice().reverse(),function(a){G(a,function(n){if(n.outEdges.length){var i=ct(n.outEdges,af,e)/ct(n.outEdges,Ya);if(isNaN(i)){var o=n.outEdges.length;i=o?ct(n.outEdges,rf,e)/o:0}if(e==="vertical"){var l=n.getLayout().x+(i-ft(n,e))*t;n.setLayout({x:l},!0)}else{var s=n.getLayout().y+(i-ft(n,e))*t;n.setLayout({y:s},!0)}}})})}function af(r,t){return ft(r.node2,t)*r.getValue()}function rf(r,t){return ft(r.node2,t)}function nf(r,t){return ft(r.node1,t)*r.getValue()}function of(r,t){return ft(r.node1,t)}function ft(r,t){return t==="vertical"?r.getLayout().x+r.getLayout().dx/2:r.getLayout().y+r.getLayout().dy/2}function Ya(r){return r.getValue()}function ct(r,t,e){for(var a=0,n=r.length,i=-1;++i<n;){var o=+t(r[i],e);isNaN(o)||(a+=o)}return a}function lf(r,t,e){G(r,function(a){G(a,function(n){if(n.inEdges.length){var i=ct(n.inEdges,nf,e)/ct(n.inEdges,Ya);if(isNaN(i)){var o=n.inEdges.length;i=o?ct(n.inEdges,of,e)/o:0}if(e==="vertical"){var l=n.getLayout().x+(i-ft(n,e))*t;n.setLayout({x:l},!0)}else{var s=n.getLayout().y+(i-ft(n,e))*t;n.setLayout({y:s},!0)}}})})}function sf(r,t){var e=t==="vertical"?"x":"y";G(r,function(a){a.outEdges.sort(function(n,i){return n.node2.getLayout()[e]-i.node2.getLayout()[e]}),a.inEdges.sort(function(n,i){return n.node1.getLayout()[e]-i.node1.getLayout()[e]})}),G(r,function(a){var n=0,i=0;
1G(a.outEdges,function(o){o.setLayout({sy:n},!0),n+=o.getLayout().dy}),G(a.inEdges,function(o){o.setLayout({ty:i},!0),i+=o.getLayout().dy})})}var uf=he(Qe,vf);function vf(r){r.eachSeriesByType(Qe,function(t){var e=t.getGraph(),a=e.nodes,n=e.edges;if(a.length){var i=1/0,o=-1/0;G(a,function(l){var s=l.getLayout().value;s<i&&(i=s),s>o&&(o=s)}),G(a,function(l){var s=new Yo({type:"color",mappingMethod:"linear",dataExtent:[i,o],visual:t.get("color")}),u=s.mapValueToVisual(l.getLayout().value),v=l.getModel().get(["itemStyle","color"]);v!=null?(l.setVisual("color",v),l.setVisual("style",{fill:v})):(l.setVisual("color",u),l.setVisual("style",{fill:u}))})}n.length&&G(n,function(l){var s=l.getModel().get("lineStyle");l.setVisual("style",s)})})}function wp(r){r.registerChartView(Hh),r.registerSeriesModel(Bh),r.registerLayout(Uh),r.registerVisual(uf),r.registerAction({type:"dragNode",event:"dragnode",update:"update"},function(t,e){e.eachComponent({mainType:aa,subType:Qe,query:t},function(a){a.setNodePosition(t.dataIndex,[t.localX,t.localY])})}),pn(r,aa,Qe)}var Ul=function(){function r(){}return r.prototype._hasEncodeRule=function(t){var e=this.getEncode();return e&&e.get(t)!=null},r.prototype.getInitialData=function(t,e){var a,n=e.getComponent("xAxis",this.get("xAxisIndex")),i=e.getComponent("yAxis",this.get("yAxisIndex")),o=n.get("type"),l=i.get("type"),s,u=t.layout;o==="category"?(u="horizontal",a=n.getOrdinalMeta(),s=!this._hasEncodeRule("x")):l==="category"&&(u="vertical",a=i.getOrdinalMeta(),s=!this._hasEncodeRule("y")),u||(u=l==="time"?"vertical":"horizontal"),this._layout=u;var v=["x","y"],c=u==="horizontal"?0:1,h=this._baseAxisDim=v[c],f=v[1-c],g=[n,i],p=g[c].get("type"),d=g[1-c].get("type"),m=t.data;if(m&&s){var y=[];G(m,function(w,_){var D;Q(w)?(D=w.slice(),w.unshift(_)):Q(w.value)?(D=$({},w),D.value=D.value.slice(),w.value.unshift(_)):D=w,y.push(D)}),t.data=y}var S=this.defaultValueDimensions,b=[{name:h,type:$r(p),ordinalMeta:a,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:f,type:$r(d),dimsDef:S.slice()}];return ma(this,{coordDimensions:b,dimensionsCount:S.length+1,encodeDefaulter:Xe(qs,b,this)})},r.prototype.getBaseAxis=function(){var t=this._baseAxisDim;return this.ecModel.getComponent(t+"Axis",this.get(t+"AxisIndex")).axis},r.prototype.getWhiskerBoxesLayout=function(){return this._layout},r}();function $a(r,t){for(var e=t.ends.length,a=0,n=0;n<e;n++)r.contain(t.ends[n][0],t.ends[n][1])&&a++;return a?a<e?la:oa:sa}var Ue="boxplot",Yl=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.defaultValueDimensions=[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],e.visualDrawType="stroke",e}return t.type="series."+Ue,t.dependencies=["xAxis","yAxis","grid"],t.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,boxWidth:[7,50],itemStyle:{color:Z.color.neutral00,borderWidth:1},emphasis:{scale:!0,itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:1,shadowOffsetY:1,shadowColor:Z.color.shadow}},animationDuration:800},t}(se);Za(Yl,Ul,!0);var cf=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=Ue,e}return t.prototype.render=function(e,a,n){var i=e.getData(),o=this.group,l=this._data;this._data||o.removeAll();var s=e.getWhiskerBoxesLayout()==="horizontal"?1:0,u=e.get("clip",!0),v=e.coordinateSystem,c=v.getArea&&v.getArea(),h=u&&wt(v,!1,e);i.diff(l).add(function(f){if(i.hasValue(f)){var g=i.getItemLayout(f),p=u?$a(c,g):oa;if(p===sa)return;var d=Zi(g,i,f,s,!0);Tt(p===la,d,h),i.setItemGraphicEl(f,d),o.add(d)}}).update(function(f,g){var p=l.getItemGraphicEl(g);if(!i.hasValue(f)){o.remove(p);return}var d=i.getItemLayout(f),m=u?$a(c,d):oa;if(m===sa){o.remove(p);return}p?(Oe(p),$l(d,p,i,f)):p=Zi(d,i,f,s),Tt(m===la,p,h),o.add(p),i.setItemGraphicEl(f,p)}).remove(function(f){var g=l.getItemGraphicEl(f);g&&o.remove(g)}).execute(),this._data=i},t.prototype.remove=function(e){var a=this.group,n=this._data;this._data=null,n&&n.eachItemGraphicEl(function(i){i&&a.remove(i)})},t.type=Ue,t}(ae),hf=function(){function r(){}return r}(),ff=function(r){z(t,r);function t(e){var a=r.call(this,e)||this;return a.type="boxplotBoxPath",a}return t.prototype.getDefaultShape=function(){return new hf},t.prototype.buildPath=function(e,a){var n=a.points,i=0;for(e.moveTo(n[i][0],n[i][1]),i++;i<4;i++)e.lineTo(n[i][0],n[i][1]);for(e.closePath();i<n.length;i++)e.moveTo(n[i][0],n[i][1]),i++,e.lineTo(n[i][0],n[i][1])},t}(xe);function Zi(r,t,e,a,n){var i=r.ends,o=new ff({shape:{points:n?gf(i,a,r):i}});
1return $l(r,o,t,e,n),o}function $l(r,t,e,a,n){var i=e.hostModel,o=ja[n?"initProps":"updateProps"];o(t,{shape:{points:r.ends}},i,a),t.useStyle(e.getItemVisual(a,"style")),t.style.strokeNoScale=!0,t.z2=100;var l=e.getItemModel(a),s=l.getModel("emphasis");ce(t,l),ie(t,s.get("focus"),s.get("blurScope"),s.get("disabled"))}function gf(r,t,e){return ee(r,function(a){return a=a.slice(),a[t]=e.initBaseline,a})}var pf=ln(),df=he(Ue,yf);function yf(r){var t=bt(Ue);Do(r,t,function(e){var a=Ks(e,t);if(a){var n=mf(e,a);ta(e,t,function(i){var o=i.seriesIndex;Sf(i,n.boxOffsetList[o],n.boxWidthList[o])})}})}function mf(r,t){var e=[],a=[],n=[],i=Je(r,{fromStat:{key:bt(Ue)},min:1}).w;ta(r,bt(Ue),function(v){var c=v.get("boxWidth");Q(c)||(c=[c,c]),n[v.seriesIndex]=[U(c[0],i)||0,U(c[1],i)||0]});var o=i*.8-2,l=o/t*.3,s=(o-l*(t-1))/t,u=s/2-o/2;return ta(r,bt(Ue),function(v){var c=v.seriesIndex;a[c]=u,u+=l+s,e[c]=Pt(St(s,n[c][0]),n[c][1])}),{boxOffsetList:a,boxWidthList:e}}function Sf(r,t,e){var a=r.coordinateSystem,n=r.getData(),i=e/2,o=r.getWhiskerBoxesLayout()==="horizontal"?0:1,l=1-o,s=["x","y"],u=n.mapDimension(s[o]),v=n.mapDimensionsAll(s[l]);if(u==null||v.length<5)return;for(var c=0;c<n.count();c++){var h=n.get(u,c),f=S(h,v[2],c),g=S(h,v[0],c),p=S(h,v[1],c),d=S(h,v[3],c),m=S(h,v[4],c),y=[];b(y,p,!1),b(y,d,!0),y.push(g,p,m,d),w(y,g),w(y,m),w(y,f),n.setItemLayout(c,{initBaseline:f[l],ends:y})}function S(_,D,A){var P=n.get(D,A),I=[];I[o]=_,I[l]=P;var x;return isNaN(_)||isNaN(P)?x=[NaN,NaN]:(x=a.dataToPoint(I),x[o]+=t),x}function b(_,D,A){var P=D.slice(),I=D.slice();P[o]+=i,I[o]-=i,A?_.push(P,I):_.push(I,P)}function w(_,D){var A=D.slice(),P=D.slice();A[o]-=i,P[o]+=i,_.push(A,P)}}function bf(r){pf(r,function(){var t=bt(Ue);ko(r,{key:t,seriesType:Ue,getMetrics:Zo}),sn(t,hn(t))})}function wf(r,t){t=t||{};for(var e=[],a=[],n=t.boundIQR,i=n==="none"||n===0,o=0;o<r.length;o++){var l=Vo(r[o].slice()),s=ur(l,.25),u=ur(l,.5),v=ur(l,.75),c=l[0],h=l[l.length-1],f=(n??1.5)*(v-s),g=i?c:Math.max(c,s-f),p=i?h:Math.min(h,v+f),d=t.itemNameFormatter,m=Ie(d)?d({value:o}):Le(d)?d.replace("{value}",o+""):o+"";e.push([m,g,s,u,v,p]);for(var y=0;y<l.length;y++){var S=l[y];if(S<g||S>p){var b=[m,S];a.push(b)}}}return{boxData:e,outliers:a}}var _f={type:"echarts:boxplot",transform:function(t){var e=t.upstream;if(e.sourceFormat!==js){var a="";Ra(a)}var n=wf(e.getRawData(),t.config);return[{dimensions:["ItemName","Low","Q1","Q2","Q3","High"],data:n.boxData},{data:n.outliers}]}};function _p(r){r.registerSeriesModel(Yl),r.registerChartView(cf),r.registerLayout(df),r.registerTransform(_f),bf(r)}var gt="candlestick",Xl=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.defaultValueDimensions=[{name:"open",defaultTooltip:!0},{name:"close",defaultTooltip:!0},{name:"lowest",defaultTooltip:!0},{name:"highest",defaultTooltip:!0}],e}return t.prototype.getShadowDim=function(){return"open"},t.prototype.brushSelector=function(e,a,n){var i=a.getItemLayout(e);return i&&n.rect(i.brushRect)},t.type="series."+gt,t.dependencies=["xAxis","yAxis","grid"],t.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,layout:null,clip:!0,itemStyle:{color:"#eb5454",color0:"#47b262",borderColor:"#eb5454",borderColor0:"#47b262",borderColorDoji:null,borderWidth:1},emphasis:{itemStyle:{borderWidth:2}},barMaxWidth:null,barMinWidth:null,barWidth:null,large:!0,largeThreshold:600,progressive:3e3,progressiveThreshold:1e4,progressiveChunkMode:"mod",animationEasing:"linear",animationDuration:300},t}(se);Za(Xl,Ul,!0);var Df=["itemStyle","borderColor"],xf=["itemStyle","borderColor0"],Af=["itemStyle","borderColorDoji"],If=["itemStyle","color"],Lf=["itemStyle","color0"];function An(r,t){return t.get(r>0?If:Lf)}function In(r,t){return t.get(r===0?Af:r>0?Df:xf)}var Cf={seriesType:gt,plan:da(),performRawSeries:!0,reset:function(r,t){if(!t.isSeriesFiltered(r)){var e=r.pipelineContext.large;return!e&&{progress:function(a,n){for(var i;(i=a.next())!=null;){var o=n.getItemModel(i),l=n.getItemLayout(i).sign,s=o.getItemStyle();s.fill=An(l,o),s.stroke=In(l,o)||s.fill;var u=n.ensureUniqueItemVisual(i,"style");$(u,s)}}}}}},Tf=["color","borderColor"],Pf=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,a,n){this.group.removeClipPath(),this._progressiveEls=null,this._updateDrawMode(e),this._isLargeDraw?this._renderLarge(e):this._renderNormal(e)},t.prototype.incrementalPrepareRender=function(e,a,n){this._clear(),this._updateDrawMode(e)},t.prototype.incrementalRender=function(e,a,n,i){this._progressiveEls=[],this._isLargeDraw?this._incrementalRenderLarge(e,a):this._incrementalRenderNormal(e,a)},t.prototype.eachRendered=function(e){qa(this._progressiveEls||this.group,e)},t.prototype._updateDrawMode=function(e){var a=e.pipelineContext.large;(this._isLargeDraw==null||a!==this._isLargeDraw)&&(this._isLargeDraw=a,this._clear())},t.prototype._renderNormal=function(e){var a=e.getData(),n=this._data,i=this.group,o=a.getLayout("isSimpleBox"),l=e.get("clip",!0),s=e.coordinateSystem,u=s.getArea&&s.getArea(),v=l&&wt(s,!1,e);this._data||i.removeAll();var c=qi(e);a.diff(n).add(function(h){if(a.hasValue(h)){var f=a.getItemLayout(h),g=l?$a(u,f):oa;if(g===sa)return;var p=Er(f,h,c,!0);ue(p,{shape:{points:f.ends}},e,h),Tt(g===la,p,v),Rr(p,a,h,o),i.add(p),a.setItemGraphicEl(h,p)}}).update(function(h,f){var g=n.getItemGraphicEl(f);if(!a.hasValue(h)){i.remove(g);return}var p=a.getItemLayout(h),d=l?$a(u,p):oa;if(d===sa){i.remove(g);return}g?(J(g,{shape:{points:p.ends}},e,h),Oe(g)):g=Er(p,h,c),Rr(g,a,h,o),Tt(d===la,g,v),i.add(g),a.setItemGraphicEl(h,g)}).remove(function(h){var f=n.getItemGraphicEl(h);f&&i.remove(f)}).execute(),this._data=a},t.prototype._renderLarge=function(e){this._clear(),Ki(e,this.group);
1var a=e.get("clip",!0)?wt(e.coordinateSystem,!1,e):null;Tt(!!a,this.group,a)},t.prototype._incrementalRenderNormal=function(e,a){for(var n=a.getData(),i=n.getLayout("isSimpleBox"),o=qi(a),l;(l=e.next())!=null;){var s=n.getItemLayout(l),u=Er(s,l,o);Rr(u,n,l,i),u.incremental=We(a),this.group.add(u),this._progressiveEls.push(u)}},t.prototype._incrementalRenderLarge=function(e,a){Ki(a,this.group,this._progressiveEls,!0)},t.prototype.remove=function(e){this._clear()},t.prototype._clear=function(){this.group.removeAll(),Tt(!1,this.group,null),this._data=null},t.type=gt,t}(ae),Ef=function(){function r(){}return r}(),Rf=function(r){z(t,r);function t(e){var a=r.call(this,e)||this;return a.type="normalCandlestickBox",a}return t.prototype.getDefaultShape=function(){return new Ef},t.prototype.buildPath=function(e,a){var n=a.points;this.__simpleBox?(e.moveTo(n[4][0],n[4][1]),e.lineTo(n[6][0],n[6][1])):(e.moveTo(n[0][0],n[0][1]),e.lineTo(n[1][0],n[1][1]),e.lineTo(n[2][0],n[2][1]),e.lineTo(n[3][0],n[3][1]),e.closePath(),e.moveTo(n[4][0],n[4][1]),e.lineTo(n[5][0],n[5][1]),e.moveTo(n[6][0],n[6][1]),e.lineTo(n[7][0],n[7][1]))},t}(xe);function Er(r,t,e,a){var n=r.ends;return new Rf({shape:{points:a?Nf(n,e,r):n},z2:100})}function Rr(r,t,e,a){var n=t.getItemModel(e);r.useStyle(t.getItemVisual(e,"style")),r.style.strokeNoScale=!0;var i=n.getShallow("cursor");i&&r.attr("cursor",i),r.__simpleBox=a,ce(r,n);var o=t.getItemLayout(e).sign;G(r.states,function(s,u){var v=n.getModel(u),c=An(o,v),h=In(o,v)||c,f=s.style||(s.style={});c&&(f.fill=c),h&&(f.stroke=h)});var l=n.getModel("emphasis");ie(r,l.get("focus"),l.get("blurScope"),l.get("disabled"))}function Nf(r,t,e){return ee(r,function(a){return a=a.slice(),a[t]=e.initBaseline,a})}function qi(r){return r.getWhiskerBoxesLayout()==="horizontal"?1:0}var Mf=function(){function r(){}return r}(),Nr=function(r){z(t,r);function t(e){var a=r.call(this,e)||this;return a.type="largeCandlestickBox",a}return t.prototype.getDefaultShape=function(){return new Mf},t.prototype.buildPath=function(e,a){for(var n=a.points,i=0;i<n.length;)if(this.__sign===n[i++]){var o=n[i++];e.moveTo(o,n[i++]),e.lineTo(o,n[i++])}else i+=3},t}(xe);function Ki(r,t,e,a){var n=r.getData(),i=n.getLayout("largePoints"),o=new Nr({shape:{points:i},__sign:1,ignoreCoarsePointer:!0});t.add(o);var l=new Nr({shape:{points:i},__sign:-1,ignoreCoarsePointer:!0});t.add(l);var s=new Nr({shape:{points:i},__sign:0,ignoreCoarsePointer:!0});t.add(s),Mr(1,o,r),Mr(-1,l,r),Mr(0,s,r),a&&(o.incremental=We(r),l.incremental=We(r),s.incremental=We(r)),e&&e.push(o,l,s)}function Mr(r,t,e,a){var n=In(r,e)||An(r,e),i=e.getModel("itemStyle").getItemStyle(Tf);t.useStyle(i),t.style.fill=null,t.style.stroke=n;var o=e.get("cursor");o&&t.attr("cursor",o)}function Vf(r){!r||!Q(r.series)||G(r.series,function(t){Ds(t)&&t.type==="k"&&(t.type=gt)})}var kf=ln(),Of={seriesType:gt,plan:da(),reset:function(r){var t=r.coordinateSystem,e=r.getData(),a=Gf(r),n=r.getWhiskerBoxesLayout()==="horizontal"?0:1,i=1-n,o=["x","y"],l=e.getDimensionIndex(e.mapDimension(o[n])),s=ee(e.mapDimensionsAll(o[i]),e.getDimensionIndex,e),u=s[0],v=s[1],c=s[2],h=s[3];if(e.setLayout({candleWidth:a,isSimpleBox:a<=1.3}),l<0||s.length<4)return;return{progress:r.pipelineContext.large?g:f};function f(p,d){for(var m,y=d.getStore();(m=p.next())!=null;){var S=y.get(l,m),b=y.get(u,m),w=y.get(v,m),_=y.get(c,m),D=y.get(h,m),A=Pt(b,w),P=St(b,w),I=N(A,S),x=N(P,S),L=N(_,S),E=N(D,S),V=[];C(V,x,0),C(V,I,1),V.push(k(E),k(x),k(L),k(I));var T=d.getItemModel(m),R=!!T.get(["itemStyle","borderColorDoji"]);d.setItemLayout(m,{sign:ji(y,m,b,w,v,R),initBaseline:b>w?x[i]:I[i],ends:V,brushRect:M(_,D,S)})}function N(O,B){var W=[];return W[n]=B,W[i]=O,isNaN(B)||isNaN(O)?[NaN,NaN]:t.dataToPoint(W)}function C(O,B,W){var H=B.slice(),X=B.slice();H[n]=vr(H[n]+a/2,1,!1),X[n]=vr(X[n]-a/2,1,!0),W?O.push(H,X):O.push(X,H)}function M(O,B,W){var H=N(O,W),X=N(B,W);return H[n]-=a/2,X[n]-=a/2,{x:H[0],y:H[1],width:i?a:X[0]-H[0],height:i?X[1]-H[1]:a}}function k(O){return O[n]=vr(O[n],1),O}}function g(p,d){for(var m=ze(p.count*4),y=0,S,b=[],w=[],_,D=d.getStore(),A=!!r.get(["itemStyle","borderColorDoji"]);(_=p.next())!=null;){var P=D.get(l,_),I=D.get(u,_),x=D.get(v,_),L=D.get(c,_),E=D.get(h,_);if(isNaN(P)||isNaN(L)||isNaN(E)){m[y++]=NaN,y+=3;continue}m[y++]=ji(D,_,I,x,v,A),b[n]=P,b[i]=L,S=t.dataToPoint(b,null,w),m[y++]=S?S[0]:NaN,m[y++]=S?S[1]:NaN,b[i]=E,S=t.dataToPoint(b,null,w),m[y++]=S?S[1]:NaN}d.setLayout("largePoints",m)}}};function ji(r,t,e,a,n,i){var o;return e>a?o=-1:e<a?o=1:o=i?0:t>0?r.get(n,t-1)<=a?1:-1:1,o}function Gf(r,t){var e=r.getBaseAxis(),a=Je(e,{fromStat:{key:bt(gt)},min:1}).w,n=U(Jt(r.get("barMaxWidth"),a),a),i=U(Jt(r.get("barMinWidth"),
11),a),o=r.get("barWidth");return o!=null?U(o,a):St(Pt(a/2,n),i)}function Bf(r){kf(r,function(){var t=bt(gt);ko(r,{key:t,seriesType:gt,getMetrics:Zo}),sn(t,hn(t))})}function Dp(r){r.registerChartView(Pf),r.registerSeriesModel(Xl),r.registerPreprocessor(Vf),r.registerVisual(Cf),r.registerLayout(Of),Bf(r)}function Ji(r,t){var e=t.rippleEffectColor||t.color;r.eachChild(function(a){a.attr({z:t.z,zlevel:t.zlevel,style:{stroke:t.brushType==="stroke"?e:null,fill:t.brushType==="fill"?e:null}})})}var zf=function(r){z(t,r);function t(e,a){var n=r.call(this)||this,i=new tr(e,a),o=new j;return n.add(i),n.add(o),n.updateData(e,a),n}return t.prototype.stopEffectAnimation=function(){this.childAt(1).removeAll()},t.prototype.startEffectAnimation=function(e){for(var a=e.symbolType,n=e.color,i=e.rippleNumber,o=this.childAt(1),l=0;l<i;l++){var s=Ke(a,-1,-1,2,2,n);s.attr({style:{strokeNoScale:!0},z2:99,silent:!0,scaleX:.5,scaleY:.5});var u=-l/i*e.period+e.effectOffset;s.animate("",!0).when(e.period,{scaleX:e.rippleScale/2,scaleY:e.rippleScale/2}).delay(u).start(),s.animateStyle(!0).when(e.period,{opacity:0}).delay(u).start(),o.add(s)}Ji(o,e)},t.prototype.updateEffectAnimation=function(e){for(var a=this._effectCfg,n=this.childAt(1),i=["symbolType","period","rippleScale","rippleNumber"],o=0;o<i.length;o++){var l=i[o];if(a[l]!==e[l]){this.stopEffectAnimation(),this.startEffectAnimation(e);return}}Ji(n,e)},t.prototype.highlight=function(){No(this)},t.prototype.downplay=function(){Mo(this)},t.prototype.getSymbolType=function(){var e=this.childAt(0);return e&&e.getSymbolType()},t.prototype.updateData=function(e,a){var n=this,i=e.hostModel;this.childAt(0).updateData(e,a);var o=this.childAt(1),l=e.getItemModel(a),s=e.getItemVisual(a,"symbol"),u=To(e.getItemVisual(a,"symbolSize")),v=e.getItemVisual(a,"style"),c=v&&v.fill,h=l.getModel("emphasis");o.setScale(u),o.traverse(function(d){d.setStyle("fill",c)});var f=Oo(e.getItemVisual(a,"symbolOffset"),u);f&&(o.x=f[0],o.y=f[1]);var g=e.getItemVisual(a,"symbolRotate");o.rotation=(g||0)*Math.PI/180||0;var p={};p.showEffectOn=i.get("showEffectOn"),p.rippleScale=l.get(["rippleEffect","scale"]),p.brushType=l.get(["rippleEffect","brushType"]),p.period=l.get(["rippleEffect","period"])*1e3,p.effectOffset=a/e.count(),p.z=i.getShallow("z")||0,p.zlevel=i.getShallow("zlevel")||0,p.symbolType=s,p.color=c,p.rippleEffectColor=l.get(["rippleEffect","color"]),p.rippleNumber=l.get(["rippleEffect","number"]),p.showEffectOn==="render"?(this._effectCfg?this.updateEffectAnimation(p):this.startEffectAnimation(p),this._effectCfg=p):(this._effectCfg=null,this.stopEffectAnimation(),this.onHoverStateChange=function(d){d==="emphasis"?p.showEffectOn!=="render"&&n.startEffectAnimation(p):d==="normal"&&p.showEffectOn!=="render"&&n.stopEffectAnimation()}),this._effectCfg=p,ie(this,h.get("focus"),h.get("blurScope"),h.get("disabled"))},t.prototype.fadeOut=function(e){e&&e()},t}(j),Ff=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(){this._symbolDraw=new er(zf)},t.prototype.render=function(e,a,n){var i=e.getData(),o=this._symbolDraw;o.updateData(i,Qi(e)),this.group.add(o.group)},t.prototype.updateTransform=function(e,a,n){var i=e.getData();this.group.dirty();var o=Sa("").reset(e,a,n);o.progress&&o.progress({start:0,end:i.count(),count:i.count()},i),this._symbolDraw.updateLayout(Qi(e))},t.prototype._updateGroupTransform=function(e){var a=e.coordinateSystem;a&&a.getRoamTransform&&(this.group.transform=xs(a.getRoamTransform()),this.group.decomposeTransform())},t.prototype.remove=function(e,a){this._symbolDraw&&this._symbolDraw.remove(!0)},t.type="effectScatter",t}(ae);function Qi(r){return{clipShape:il(r)}}var Hf=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e}return t.prototype.getInitialData=function(e,a){return et(null,this,{useEncodeDefaulter:!0})},t.prototype.brushSelector=function(e,a,n){return n.point(a.getItemLayout(e))},t.type="series.effectScatter",t.dependencies=["grid","polar"],t.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,effectType:"ripple",progressive:0,showEffectOn:"render",clip:!0,rippleEffect:{period:4,scale:2.5,brushType:"fill",number:3},universalTransition:{divideShape:"clone"},symbolSize:10},t}(se);function xp(r){r.registerChartView(Ff),r.registerSeriesModel(Hf),r.registerLayout(Sa("effectScatter"))}var Zl=function(r){z(t,r);function t(e,a,n){var i=r.call(this)||this;return i.add(i.createLine(e,a,n)),i._updateEffectSymbol(e,a),i}return t.prototype.createLine=function(e,a,n){return new qo(e,a,n)},t.prototype._updateEffectSymbol=function(e,a){var n=e.getItemModel(a),i=n.getModel("effect"),o=i.get("symbolSize"),l=i.get("symbol");
1Q(o)||(o=[o,o]);var s=e.getItemVisual(a,"style"),u=i.get("color")||s&&s.stroke,v=this.childAt(1);this._symbolType!==l&&(this.remove(v),v=Ke(l,-.5,-.5,1,1,u),v.z2=100,v.culling=!0,this.add(v)),v&&(v.setStyle("shadowColor",u),v.setStyle(i.getItemStyle(["color"])),v.scaleX=o[0],v.scaleY=o[1],v.setColor(u),this._symbolType=l,this._symbolScale=o,this._updateEffectAnimation(e,i,a))},t.prototype._updateEffectAnimation=function(e,a,n){var i=this.childAt(1);if(i){var o=e.getItemLayout(n),l=a.get("period")*1e3,s=a.get("loop"),u=a.get("roundTrip"),v=a.get("constantSpeed"),c=Ma(a.get("delay"),function(f){return f/e.count()*l/3});if(i.ignore=!0,this._updateAnimationPoints(i,o),v>0&&(l=this._getLineLength(i)/v*1e3),l!==this._period||s!==this._loop||u!==this._roundTrip){i.stopAnimation();var h=void 0;Ie(c)?h=c(n):h=c,i.__t>0&&(h=-l*i.__t),this._animateSymbol(i,l,h,s,u)}this._period=l,this._loop=s,this._roundTrip=u}},t.prototype._animateSymbol=function(e,a,n,i,o){if(a>0){e.__t=0;var l=this,s=e.animate("",i).when(o?a*2:a,{__t:o?2:1}).delay(n).during(function(){l._updateSymbolPosition(e)});i||s.done(function(){l.remove(e)}),s.start()}},t.prototype._getLineLength=function(e){return mt(e.__p1,e.__cp1)+mt(e.__cp1,e.__p2)},t.prototype._updateAnimationPoints=function(e,a){e.__p1=a[0],e.__p2=a[1],e.__cp1=a[2]||[(a[0][0]+a[1][0])/2,(a[0][1]+a[1][1])/2]},t.prototype.updateData=function(e,a,n){this.childAt(0).updateData(e,a,n),this._updateEffectSymbol(e,a)},t.prototype._updateSymbolPosition=function(e){var a=e.__p1,n=e.__p2,i=e.__cp1,o=e.__t<=1?e.__t:2-e.__t,l=[e.x,e.y],s=l.slice(),u=wo,v=As;l[0]=u(a[0],i[0],n[0],o),l[1]=u(a[1],i[1],n[1],o);var c=e.__t<=1?v(a[0],i[0],n[0],o):v(n[0],i[0],a[0],1-o),h=e.__t<=1?v(a[1],i[1],n[1],o):v(n[1],i[1],a[1],1-o);e.rotation=-Math.atan2(h,c)-Math.PI/2,(this._symbolType==="line"||this._symbolType==="rect"||this._symbolType==="roundRect")&&(e.__lastT!==void 0&&e.__lastT<e.__t?(e.scaleY=mt(s,l)*1.05,o===1&&(l[0]=s[0]+(l[0]-s[0])/2,l[1]=s[1]+(l[1]-s[1])/2)):e.__lastT===1?e.scaleY=2*mt(a,l):e.scaleY=this._symbolScale[1]),e.__lastT=e.__t,e.ignore=!1,e.x=l[0],e.y=l[1]},t.prototype.updateLayout=function(e,a){this.childAt(0).updateLayout(e,a);var n=e.getItemModel(a).getModel("effect");this._updateEffectAnimation(e,n,a)},t}(j),ql=function(r){z(t,r);function t(e,a,n){var i=r.call(this)||this;return i._createPolyline(e,a,n),i}return t.prototype._createPolyline=function(e,a,n){var i=e.getItemLayout(a),o=new zt({shape:{points:i}});this.add(o),this._updateCommonStl(e,a,n)},t.prototype.updateData=function(e,a,n){var i=e.hostModel,o=this.childAt(0),l={shape:{points:e.getItemLayout(a)}};J(o,l,i,a),this._updateCommonStl(e,a,n)},t.prototype._updateCommonStl=function(e,a,n){var i=this.childAt(0),o=e.getItemModel(a),l=n&&n.emphasisLineStyle,s=n&&n.focus,u=n&&n.blurScope,v=n&&n.emphasisDisabled;if(!n||e.hasItemOption){var c=o.getModel("emphasis");l=c.getModel("lineStyle").getLineStyle(),v=c.get("disabled"),s=c.get("focus"),u=c.get("blurScope")}i.useStyle(e.getItemVisual(a,"style")),i.style.fill=null,i.style.strokeNoScale=!0;var h=i.ensureState("emphasis");h.style=l,ie(this,s,u,v)},t.prototype.updateLayout=function(e,a){var n=this.childAt(0);n.stopAnimation(),n.setShape("points",e.getItemLayout(a))},t}(j),Wf=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e._lastFrame=0,e._lastFramePercent=0,e}return t.prototype.createLine=function(e,a,n){return new ql(e,a,n)},t.prototype._updateAnimationPoints=function(e,a){this._points=a;for(var n=[0],i=0,o=1;o<a.length;o++){var l=a[o-1],s=a[o];i+=mt(l,s),n.push(i)}if(i===0){this._length=0;return}for(var o=0;o<n.length;o++)n[o]/=i;this._offsets=n,this._length=i},t.prototype._getLineLength=function(){return this._length},t.prototype._updateSymbolPosition=function(e){var a=e.__t<=1?e.__t:2-e.__t,n=this._points,i=this._offsets,o=n.length;if(i){var l=this._lastFrame,s;if(a<this._lastFramePercent){var u=Math.min(l+1,o-1);for(s=u;s>=0&&!(i[s]<=a);s--);s=Math.min(s,o-2)}else{for(s=l;s<o&&!(i[s]>a);s++);s=Math.min(s-1,o-2)}var v=(a-i[s])/(i[s+1]-i[s]),c=n[s],h=n[s+1];e.x=c[0]*(1-v)+v*h[0],e.y=c[1]*(1-v)+v*h[1];var f=e.__t<=1?h[0]-c[0]:c[0]-h[0],g=e.__t<=1?h[1]-c[1]:c[1]-h[1];e.rotation=-Math.atan2(g,f)-Math.PI/2,this._lastFrame=s,this._lastFramePercent=a,e.ignore=!1}},t}(Zl),Uf=function(){function r(){this.polyline=!1,this.curveness=0,this.segs=[]}return r}(),Yf=function(r){z(t,r);function t(e){var a=r.call(this,e)||this;return a._off=0,a.hoverDataIdx=-1,a}return t.prototype.reset=function(){this.notClear=!1,this._off=0},t.prototype.beforeBrush=function(e){e&&!e.contentRetained&&this.reset()},t.prototype.getDefaultStyle=function(){return{stroke:Z.color.neutral99,fill:null}},t.prototype.getDefaultShape=function(){return new Uf},t.prototype.buildPath=function(e,a){var n=a.segs,i=a.curveness,o;
1if(a.polyline)for(o=this._off;o<n.length;){var l=n[o++];if(l>0){e.moveTo(n[o++],n[o++]);for(var s=1;s<l;s++)e.lineTo(n[o++],n[o++])}}else for(o=this._off;o<n.length;){var u=n[o++],v=n[o++],c=n[o++],h=n[o++];if(e.moveTo(u,v),i>0){var f=(u+c)/2-(v-h)*i,g=(v+h)/2-(c-u)*i;e.quadraticCurveTo(f,g,c,h)}else e.lineTo(c,h)}this.incremental&&(this._off=o,this.notClear=!0)},t.prototype.findDataIndex=function(e,a){var n=this.shape,i=n.segs,o=n.curveness,l=this.style.lineWidth;if(n.polyline)for(var s=0,u=0;u<i.length;){var v=i[u++];if(v>0)for(var c=i[u++],h=i[u++],f=1;f<v;f++){var g=i[u++],p=i[u++];if(Bn(c,h,g,p,l,e,a))return s}s++}else for(var s=0,u=0;u<i.length;){var c=i[u++],h=i[u++],g=i[u++],p=i[u++];if(o>0){var d=(c+g)/2-(h-p)*o,m=(h+p)/2-(g-c)*o;if(Is(c,h,d,m,g,p,l,e,a))return s}else if(Bn(c,h,g,p,l,e,a))return s;s++}return-1},t.prototype.contain=function(e,a){var n=this.transformCoordToLocal(e,a),i=this.getBoundingRect();if(e=n[0],a=n[1],i.contain(e,a)){var o=this.hoverDataIdx=this.findDataIndex(e,a);return o>=0}return this.hoverDataIdx=-1,!1},t.prototype.getBoundingRect=function(){var e=this._rect;if(!e){for(var a=this.shape,n=a.segs,i=1/0,o=1/0,l=-1/0,s=-1/0,u=0;u<n.length;){var v=n[u++],c=n[u++];i=Math.min(v,i),l=Math.max(v,l),o=Math.min(c,o),s=Math.max(c,s)}e=this._rect=new Bt(i,o,l,s)}return e},t}(xe),$f=function(){function r(){this.group=new j}return r.prototype.updateData=function(t){this._clear();var e=this._create();e.setShape({segs:t.getLayout("linesPoints")}),this._setCommon(e,t)},r.prototype.incrementalPrepareUpdate=function(t){this.group.removeAll(),this._clear()},r.prototype.incrementalUpdate=function(t,e,a){var n=this._newAdded[0],i=e.getLayout("linesPoints"),o=n&&n.shape.segs;if(o&&o.length<2e4){var l=o.length,s=new Float32Array(l+i.length);s.set(o),s.set(i,l),n.setShape({segs:s})}else{this._newAdded=[];var u=this._create();u.incremental=a,u.setShape({segs:i}),this._setCommon(u,e),u.__startIndex=t.start}},r.prototype.remove=function(){this._clear()},r.prototype.eachRendered=function(t){this._newAdded[0]&&t(this._newAdded[0])},r.prototype._create=function(){var t=new Yf({cursor:"default",ignoreCoarsePointer:!0});return this._newAdded.push(t),this.group.add(t),t},r.prototype._setCommon=function(t,e,a){var n=e.hostModel;t.setShape({polyline:n.get("polyline"),curveness:n.get(["lineStyle","curveness"])}),t.useStyle(n.getModel("lineStyle").getLineStyle()),t.style.strokeNoScale=!0;var i=e.getVisual("style");i&&i.stroke&&t.setStyle("stroke",i.stroke),t.setStyle("fill",null);var o=ne(t);o.seriesIndex=n.seriesIndex,t.on("mousemove",function(l){o.dataIndex=null;var s=t.hoverDataIdx;s>0&&(o.dataIndex=s+t.__startIndex)})},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r}(),Kl={seriesType:"lines",plan:da(),reset:function(r){var t=r.coordinateSystem;if(t){var e=r.get("polyline"),a=r.pipelineContext.large;return{progress:function(n,i){var o=[];if(a){var l=void 0,s=n.end-n.start;if(e){for(var u=0,v=n.start;v<n.end;v++)u+=r.getLineCoordsCount(v);l=new Float32Array(s+u*2)}else l=new Float32Array(s*4);for(var c=0,h=[],v=n.start;v<n.end;v++){var f=r.getLineCoords(v,o);e&&(l[c++]=f);for(var g=0;g<f;g++)h=t.dataToPoint(o[g],!1,h),l[c++]=h[0],l[c++]=h[1]}i.setLayout("linesPoints",l)}else for(var v=n.start;v<n.end;v++){var p=i.getItemModel(v),f=r.getLineCoords(v,o),d=[];if(e)for(var m=0;m<f;m++)d.push(t.dataToPoint(o[m]));else{d[0]=t.dataToPoint(o[0]),d[1]=t.dataToPoint(o[1]);var y=p.get(["lineStyle","curveness"]);+y&&(d[2]=[(d[0][0]+d[1][0])/2-(d[0][1]-d[1][1])*y,(d[0][1]+d[1][1])/2-(d[1][0]-d[0][0])*y])}i.setItemLayout(v,d)}}}}}},Xf=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,a,n){var i=e.getData(),o=this._updateLineDraw(i,e),l=e.get("zlevel"),s=e.get(["effect","trailLength"]),u=n.getZr(),v=!!jn(n);v&&u.painter.getLayer(l).clear(!0),this._lastZlevel!=null&&v&&u.configLayer(this._lastZlevel,{motionBlur:!1}),this._showEffect(e)&&s>0&&v&&u.configLayer(l,{motionBlur:!0,lastFrameAlpha:Math.max(Math.min(s/10+.9,1),0)}),o.updateData(i);
1var c=e.get("clip",!0)&&wt(e.coordinateSystem,!1,e);c?this.group.setClipPath(c):this.group.removeClipPath(),this._lastZlevel=l,this._finished=!0},t.prototype.incrementalPrepareRender=function(e,a,n){var i=e.getData(),o=this._updateLineDraw(i,e);o.incrementalPrepareUpdate(i),this._clearLayer(n),this._finished=!1},t.prototype.incrementalRender=function(e,a,n){this._lineDraw.incrementalUpdate(e,a.getData(),We(a)),this._finished=e.end===a.getData().count()},t.prototype.eachRendered=function(e){this._lineDraw&&this._lineDraw.eachRendered(e)},t.prototype.updateTransform=function(e,a,n){var i=e.getData(),o=this._lineDraw;if(!this._finished||!o||!o.updateLayout)return{update:!0};var l=Kl.reset(e,a,n);l.progress&&l.progress({start:0,end:i.count(),count:i.count()},i),o.updateLayout(),this._clearLayer(n)},t.prototype._updateLineDraw=function(e,a){var n=this._lineDraw,i=this._showEffect(a),o=!!a.get("polyline"),l=a.pipelineContext,s=l.large;return(!n||i!==this._hasEffet||o!==this._isPolyline||s!==this._isLargeDraw)&&(n&&n.remove(),n=this._lineDraw=s?new $f:new Xo(o?i?Wf:ql:i?Zl:qo),this._hasEffet=i,this._isPolyline=o,this._isLargeDraw=s),this.group.add(n.group),n},t.prototype._showEffect=function(e){return!!e.get(["effect","show"])},t.prototype._clearLayer=function(e){var a=jn(e);a&&this._lastZlevel!=null&&a.getLayer(this._lastZlevel).clear(!0)},t.prototype.remove=function(e,a){this._lineDraw&&this._lineDraw.remove(),this._lineDraw=null,this._clearLayer(a)},t.prototype.dispose=function(e,a){this.remove(e,a)},t.type="lines",t}(ae),Zf=typeof Uint32Array>"u"?Array:Uint32Array,qf=typeof Float64Array>"u"?Array:Float64Array;function eo(r){var t=r.data;t&&t[0]&&t[0][0]&&t[0][0].coord&&(r.data=ee(t,function(e){var a=[e[0].coord,e[1].coord],n={coords:a};return e[0].name&&(n.fromName=e[0].name),e[1].name&&(n.toName=e[1].name),Ls([n,e[0],e[1]])}))}var Kf=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.visualStyleAccessPath="lineStyle",e.visualDrawType="stroke",e}return t.prototype.init=function(e){e.data=e.data||[],eo(e);var a=this._processFlatCoordsArray(e.data);this._flatCoords=a.flatCoords,this._flatCoordsOffset=a.flatCoordsOffset,a.flatCoords&&(e.data=new Float32Array(a.count)),r.prototype.init.apply(this,arguments)},t.prototype.mergeOption=function(e){if(eo(e),e.data){var a=this._processFlatCoordsArray(e.data);this._flatCoords=a.flatCoords,this._flatCoordsOffset=a.flatCoordsOffset,a.flatCoords&&(e.data=new Float32Array(a.count))}r.prototype.mergeOption.apply(this,arguments)},t.prototype.appendData=function(e){var a=this._processFlatCoordsArray(e.data);a.flatCoords&&(this._flatCoords?(this._flatCoords=Na(this._flatCoords,a.flatCoords),this._flatCoordsOffset=Na(this._flatCoordsOffset,a.flatCoordsOffset)):(this._flatCoords=a.flatCoords,this._flatCoordsOffset=a.flatCoordsOffset),e.data=new Float32Array(a.count)),this.getRawData().appendData(e.data)},t.prototype._getCoordsFromItemModel=function(e){var a=this.getData().getItemModel(e),n=a.option instanceof Array?a.option:a.getShallow("coords");return n},t.prototype.getLineCoordsCount=function(e){return this._flatCoordsOffset?this._flatCoordsOffset[e*2+1]:this._getCoordsFromItemModel(e).length},t.prototype.getLineCoords=function(e,a){if(this._flatCoordsOffset){for(var n=this._flatCoordsOffset[e*2],i=this._flatCoordsOffset[e*2+1],o=0;o<i;o++)a[o]=a[o]||[],a[o][0]=this._flatCoords[n+o*2],a[o][1]=this._flatCoords[n+o*2+1];return i}else{for(var l=this._getCoordsFromItemModel(e),o=0;o<l.length;o++)a[o]=a[o]||[],a[o][0]=l[o][0],a[o][1]=l[o][1];return l.length}},t.prototype._processFlatCoordsArray=function(e){var a=0;if(this._flatCoords&&(a=this._flatCoords.length),Ne(e[0])){for(var n=e.length,i=new Zf(n),o=new qf(n),l=0,s=0,u=0,v=0;v<n;){u++;var c=e[v++];i[s++]=l+a,i[s++]=c;for(var h=0;h<c;h++){var f=e[v++],g=e[v++];o[l++]=f,o[l++]=g}}return{flatCoordsOffset:new Uint32Array(i.buffer,0,s),flatCoords:o,count:u}}return{flatCoordsOffset:null,flatCoords:null,count:e.length}},t.prototype.getInitialData=function(e,a){var n=new Mt(["value"],this);return n.hasItemOption=!1,n.initData(e.data,[],function(i,o,l,s){if(i instanceof Array)return NaN;n.hasItemOption=!0;var u=i.value;if(u!=null)return u instanceof Array?u[s]:u}),n},t.prototype.formatTooltip=function(e,a,n){var i=this.getData(),o=this.getRawValue(e),l=i.getItemModel(e),s=l.get("name");
1if(!s){var u=l.get("fromName"),v=l.get("toName"),c=[];u!=null&&c.push(u),v!=null&&c.push(v),s=c.join(" > ")}return Ge("nameValue",{name:s,value:o,noValue:o==null||isNaN(o)})},t.prototype.preventIncremental=function(){return!!this.get(["effect","show"])},t.prototype.getProgressive=function(){var e=this.option.progressive;return e??(this.option.large?1e4:this.get("progressive"))},t.prototype.getProgressiveThreshold=function(){var e=this.option.progressiveThreshold;return e??(this.option.large?2e4:this.get("progressiveThreshold"))},t.prototype.getZLevelKey=function(){var e=this.getModel("effect"),a=e.get("trailLength");return this.getData().count()>this.getProgressiveThreshold()?this.id:e.get("show")&&a>0?a+"":""},t.type="series.lines",t.dependencies=["grid","polar","geo","calendar"],t.defaultOption={coordinateSystem:"geo",z:2,legendHoverLink:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,clip:!0,label:{show:!1,position:"end"},lineStyle:{opacity:.5}},t}(se);function Pa(r){return r instanceof Array||(r=[r,r]),r}var jf={seriesType:"lines",reset:function(r){var t=Pa(r.get("symbol")),e=Pa(r.get("symbolSize")),a=r.getData();a.setVisual("fromSymbol",t&&t[0]),a.setVisual("toSymbol",t&&t[1]),a.setVisual("fromSymbolSize",e&&e[0]),a.setVisual("toSymbolSize",e&&e[1]);function n(i,o){var l=i.getItemModel(o),s=Pa(l.getShallow("symbol",!0)),u=Pa(l.getShallow("symbolSize",!0));s[0]&&i.setItemVisual(o,"fromSymbol",s[0]),s[1]&&i.setItemVisual(o,"toSymbol",s[1]),u[0]&&i.setItemVisual(o,"fromSymbolSize",u[0]),u[1]&&i.setItemVisual(o,"toSymbolSize",u[1])}return{dataEach:a.hasItemOption?n:null}}};function Ap(r){r.registerChartView(Xf),r.registerSeriesModel(Kf),r.registerLayout(Kl),r.registerVisual(jf)}var Jf=256,Qf=function(){function r(){this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={inRange:null,outOfRange:null};var t=zn.createCanvas();this.canvas=t}return r.prototype.update=function(t,e,a,n,i,o){var l=this._getBrush(),s=this._getGradient(i,"inRange"),u=this._getGradient(i,"outOfRange"),v=this.pointSize+this.blurSize,c=this.canvas,h=c.getContext("2d"),f=t.length;c.width=e,c.height=a;for(var g=0;g<f;++g){var p=t[g],d=p[0],m=p[1],y=p[2],S=n(y);h.globalAlpha=S,h.drawImage(l,d-v,m-v)}if(!c.width||!c.height)return c;for(var b=h.getImageData(0,0,c.width,c.height),w=b.data,_=0,D=w.length,A=this.minOpacity,P=this.maxOpacity,I=P-A;_<D;){var S=w[_+3]/256,x=Math.floor(S*(Jf-1))*4;if(S>0){var L=o(S)?s:u;S>0&&(S=S*I+A),w[_++]=L[x],w[_++]=L[x+1],w[_++]=L[x+2],w[_++]=L[x+3]*S*256}else _+=4}return h.putImageData(b,0,0),c},r.prototype._getBrush=function(){var t=this._brushCanvas||(this._brushCanvas=zn.createCanvas()),e=this.pointSize+this.blurSize,a=e*2;t.width=a,t.height=a;var n=t.getContext("2d");return n.clearRect(0,0,a,a),n.shadowOffsetX=a,n.shadowBlur=this.blurSize,n.shadowColor=Z.color.neutral99,n.beginPath(),n.arc(-e,e,this.pointSize,0,Math.PI*2,!0),n.closePath(),n.fill(),t},r.prototype._getGradient=function(t,e){for(var a=this._gradientPixels,n=a[e]||(a[e]=new Uint8ClampedArray(256*4)),i=[0,0,0,0],o=0,l=0;l<256;l++)t[e](l/255,!0,i),n[o++]=i[0],n[o++]=i[1],n[o++]=i[2],n[o++]=i[3];return n},r}();function eg(r,t,e){var a=r[1]-r[0];t=ee(t,function(o){return{interval:[(o.interval[0]-r[0])/a,(o.interval[1]-r[0])/a]}});var n=t.length,i=0;return function(o){var l;for(l=i;l<n;l++){var s=t[l].interval;if(s[0]<=o&&o<=s[1]){i=l;break}}if(l===n)for(l=i-1;l>=0;l--){var s=t[l].interval;if(s[0]<=o&&o<=s[1]){i=l;break}}return l>=0&&l<n&&e[l]}}function tg(r,t){var e=r[1]-r[0];return t=[(t[0]-r[0])/e,(t[1]-r[0])/e],function(a){return a>=t[0]&&a<=t[1]}}var ag=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,a,n){var i;a.eachComponent("visualMap",function(l){l.eachTargetSeries(function(s){s===e&&(i=l)})}),this._progressiveEls=null,this.group.removeAll();var o=e.coordinateSystem;o.type==="cartesian2d"||o.type==="calendar"||o.type==="matrix"?this._renderOnGridLike(e,n,0,e.getData().count()):ii(o)&&this._renderOnGeo(o,e,i,n)},t.prototype.incrementalPrepareRender=function(e,a,n){this.group.removeAll()},t.prototype.incrementalRender=function(e,a,n,i){var o=a.coordinateSystem;o&&(ii(o)?this.render(a,n,i):(this._progressiveEls=[],this._renderOnGridLike(a,i,e.start,e.end,!0)))},t.prototype.eachRendered=function(e){qa(this._progressiveEls||this.group,e)}
1,t.prototype._renderOnGridLike=function(e,a,n,i,o){var l=e.coordinateSystem,s=Ga(l,"cartesian2d"),u=Ga(l,"matrix"),v,c,h,f;if(s){var g=l.getAxis("x"),p=l.getAxis("y");v=Je(g).w+.5,c=Je(p).w+.5,h=g.scale.getExtent(),f=p.scale.getExtent()}for(var d=this.group,m=e.getData(),y=e.getModel(["emphasis","itemStyle"]).getItemStyle(),S=e.getModel(["blur","itemStyle"]).getItemStyle(),b=e.getModel(["select","itemStyle"]).getItemStyle(),w=e.get(["itemStyle","borderRadius"]),_=De(e),D=e.getModel("emphasis"),A=D.get("focus"),P=D.get("blurScope"),I=D.get("disabled"),x=s||u?[m.mapDimension("x"),m.mapDimension("y"),m.mapDimension("value")]:[m.mapDimension("time"),m.mapDimension("value")],L=n;L<i;L++){var E=void 0,V=m.getItemVisual(L,"style");if(s){var T=m.get(x[0],L),R=m.get(x[1],L);if(isNaN(m.get(x[2],L))||isNaN(T)||isNaN(R)||T<h[0]||T>h[1]||R<f[0]||R>f[1])continue;var N=l.dataToPoint([T,R]);E=new Ae({shape:{x:N[0]-v/2,y:N[1]-c/2,width:v,height:c},style:V})}else if(u){var C=l.dataToLayout([m.get(x[0],L),m.get(x[1],L)]).rect;if(Ea(C.x))continue;E=new Ae({z2:1,shape:C,style:V})}else{if(isNaN(m.get(x[1],L)))continue;var M=l.dataToLayout([m.get(x[0],L)]),C=M.contentRect||M.rect;if(Ea(C.x)||Ea(C.y))continue;E=new Ae({z2:1,shape:C,style:V})}if(m.hasItemOption){var k=m.getItemModel(L),O=k.getModel("emphasis");y=O.getModel("itemStyle").getItemStyle(),S=k.getModel(["blur","itemStyle"]).getItemStyle(),b=k.getModel(["select","itemStyle"]).getItemStyle(),w=k.get(["itemStyle","borderRadius"]),A=O.get("focus"),P=O.get("blurScope"),I=O.get("disabled"),_=De(k)}E.shape.r=w;var B=e.getRawValue(L),W="-";B&&B[2]!=null&&(W=B[2]+""),Ce(E,_,{labelFetcher:e,labelDataIndex:L,defaultOpacity:V.opacity,defaultText:W}),E.ensureState("emphasis").style=y,E.ensureState("blur").style=S,E.ensureState("select").style=b,ie(E,A,P,I),E.incremental=We(e,o),o&&(E.states.emphasis.hoverLayer=Go),d.add(E),m.setItemGraphicEl(L,E),this._progressiveEls&&this._progressiveEls.push(E)}},t.prototype._renderOnGeo=function(e,a,n,i){var o=n.targetVisuals.inRange,l=n.targetVisuals.outOfRange,s=a.getData(),u=this._hmLayer||this._hmLayer||new Qf;u.blurSize=a.get("blurSize"),u.pointSize=a.get("pointSize"),u.minOpacity=a.get("minOpacity"),u.maxOpacity=a.get("maxOpacity");var v=e.getViewRect().clone(),c=e.getRoamTransform();v.applyTransform(c);var h=Math.max(v.x,0),f=Math.max(v.y,0),g=Math.min(v.width+v.x,i.getWidth()),p=Math.min(v.height+v.y,i.getHeight()),d=g-h,m=p-f,y=[s.mapDimension("lng"),s.mapDimension("lat"),s.mapDimension("value")],S=s.mapArray(y,function(D,A,P){var I=e.dataToPoint([D,A]);return I[0]-=h,I[1]-=f,I.push(P),I}),b=n.getExtent(),w=n.type==="visualMap.continuous"?tg(b,n.option.range):eg(b,n.getPieceList(),n.option.selected);u.update(S,d,m,o.color.getNormalizer(),{inRange:o.color.getColorMapper(),outOfRange:l.color.getColorMapper()},w);var _=new pa({style:{width:d,height:m,x:h,y:f,image:u.canvas},silent:!0});this.group.add(_)},t.type="heatmap",t}(ae),rg=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.getInitialData=function(e,a){return et(null,this,{generateCoord:"value"})},t.prototype.preventIncremental=function(){var e=Ro.get(this.get("coordinateSystem"));if(e&&e.dimensions)return e.dimensions[0]==="lng"&&e.dimensions[1]==="lat"},t.type="series.heatmap",t.dependencies=["grid","geo","calendar","matrix"],t.defaultOption={coordinateSystem:"cartesian2d",z:2,geoIndex:0,blurSize:30,pointSize:20,maxOpacity:1,minOpacity:0,select:{itemStyle:{borderColor:Z.color.primary}}},t}(se);function Ip(r){r.registerChartView(ag),r.registerSeriesModel(rg)}var ng=["itemStyle","borderWidth"],to=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],Vr=new Po,ig=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=ia,e}return t.prototype.render=function(e,a,n){var i=this.group,o=e.getData(),l=this._data,s=e.coordinateSystem,u=s.getBaseAxis(),v=u.isHorizontal(),c=s.master.getRect(),h={ecSize:{width:n.getWidth(),height:n.getHeight()},seriesModel:e,coordSys:s,coordSysExtent:[[c.x,c.x+c.width],[c.y,c.y+c.height]],isHorizontal:v,valueDim:to[+v],categoryDim:to[1-+v]};o.diff(l).add(function(g){if(o.hasValue(g)){var p=ro(o,g),d=ao(o,g,p,h),m=no(o,h,d);o.setItemGraphicEl(g,m),i.add(m),oo(m,h,d)}}).update(function(g,p){var d=l.getItemGraphicEl(p);if(!o.hasValue(g)){i.remove(d);return}var m=ro(o,g),y=ao(o,g,m,h),S=as(o,y);d&&S!==d.__pictorialShapeStr&&(i.remove(d),o.setItemGraphicEl(g,null),d=null),d?hg(d,h,y):d=no(o,h,y,!0),o.setItemGraphicEl(g,d),d.__pictorialSymbolMeta=y,i.add(d),oo(d,h,y)}).remove(function(g){var p=l.getItemGraphicEl(g);p&&io(l,g,p.__pictorialSymbolMeta.animationModel,p)}).execute();var f=e.get("clip",!0)?wt(e.coordinateSystem,!1,e):null;return f?i.setClipPath(f):i.removeClipPath(),this._data=o,this.group},t.prototype.remove=function(e,a){var n=this.group,i=this._data;e.get("animation")?i&&i.eachItemGraphicEl(function(o){io(i,ne(o).dataIndex,e,o)}):n.removeAll()},t.type=ia,t}(ae);function ao(r,t,e,a){var n=r.getItemLayout(t),i=e.get("symbolRepeat"),o=e.get("symbolClip"),l=e.get("symbolPosition")||"start",s=e.get("symbolRotate"),u=(s||0)*Math.PI/180||0,v=e.get("symbolPatternSize")||2,c=e.isAnimationEnabled(),h={dataIndex:t,layout:n,itemModel:e,symbolType:r.getItemVisual(t,"symbol")||"circle",style:r.getItemVisual(t,"style"),symbolClip:o,symbolRepeat:i,symbolRepeatDirection:e.get("symbolRepeatDirection"),symbolPatternSize:v,rotation:u,animationModel:c?e:null,hoverScale:c&&e.get(["emp
1hasis","scale"]),z2:e.getShallow("z",!0)||0};og(e,i,n,a,h),lg(r,t,n,i,o,h.boundingLength,h.pxSign,v,a,h),sg(e,h.symbolScale,u,a,h);var f=h.symbolSize,g=Oo(e.get("symbolOffset"),f);return ug(e,f,n,i,o,g,l,h.valueLineWidth,h.boundingLength,h.repeatCutLength,a,h),h}function og(r,t,e,a,n){var i=a.valueDim,o=r.get("symbolBoundingData"),l=a.coordSys.getOtherAxis(a.coordSys.getBaseAxis()),s=l.toGlobalCoord(l.dataToCoord(0)),u=1-+(e[i.wh]<=0),v;if(Q(o)){var c=[kr(l,o[0])-s,kr(l,o[1])-s];c[1]<c[0]&&c.reverse(),v=c[u]}else o!=null?v=kr(l,o)-s:t?v=a.coordSysExtent[i.index][u]-s:v=e[i.wh];n.boundingLength=v,t&&(n.repeatCutLength=e[i.wh]);var h=i.xy==="x",f=l.inverse;n.pxSign=h&&!f||!h&&f?v>=0?1:-1:v>0?1:-1}function kr(r,t){return r.toGlobalCoord(r.dataToCoord(r.scale.parse(t)))}function lg(r,t,e,a,n,i,o,l,s,u){var v=s.valueDim,c=s.categoryDim,h=Math.abs(e[c.wh]),f=r.getItemVisual(t,"symbolSize"),g;Q(f)?g=f.slice():f==null?g=["100%","100%"]:g=[f,f],g[c.index]=U(g[c.index],h),g[v.index]=U(g[v.index],a?h:Math.abs(i)),u.symbolSize=g;var p=u.symbolScale=[g[0]/l,g[1]/l];p[v.index]*=(s.isHorizontal?-1:1)*o}function sg(r,t,e,a,n){var i=r.get(ng)||0;i&&(Vr.attr({scaleX:t[0],scaleY:t[1],rotation:e}),Vr.updateTransform(),i/=Vr.getLineScale(),i*=t[a.valueDim.index]),n.valueLineWidth=i||0}function ug(r,t,e,a,n,i,o,l,s,u,v,c){var h=v.categoryDim,f=v.valueDim,g=c.pxSign,p=Math.max(t[f.index]+l,0),d=p;if(a){var m=Math.abs(s),y=Ma(r.get("symbolMargin"),"15%")+"",S=!1;y.lastIndexOf("!")===y.length-1&&(S=!0,y=y.slice(0,y.length-1));var b=U(y,t[f.index]),w=Math.max(p+b*2,0),_=S?0:b*2,D=Js(a),A=D?a:lo((m+_)/w),P=m-A*p;b=P/2/(S?A:Math.max(A-1,1)),w=p+b*2,_=S?0:b*2,!D&&a!=="fixed"&&(A=u?lo((Math.abs(u)+_)/w):0),d=A*w-_,c.repeatTimes=A,c.symbolMargin=b}var I=g*(d/2),x=c.pathPosition=[];x[h.index]=e[h.wh]/2,x[f.index]=o==="start"?I:o==="end"?s-I:s/2,i&&(x[0]+=i[0],x[1]+=i[1]);var L=c.bundlePosition=[];L[h.index]=e[h.xy],L[f.index]=e[f.xy];var E=c.barRectShape=$({},e);E[f.wh]=g*Math.max(Math.abs(e[f.wh]),Math.abs(x[f.index]+I)),E[h.wh]=e[h.wh];var V=c.clipShape={};V[h.xy]=-e[h.xy],V[h.wh]=v.ecSize[h.wh],V[f.xy]=0,V[f.wh]=e[f.wh]}function jl(r){var t=r.symbolPatternSize,e=Ke(r.symbolType,-t/2,-t/2,t,t);return e.attr({culling:!0}),e.type!=="image"&&e.setStyle({strokeNoScale:!0}),e}function Jl(r,t,e,a){var n=r.__pictorialBundle,i=e.symbolSize,o=e.valueLineWidth,l=e.pathPosition,s=t.valueDim,u=e.repeatTimes||0,v=0,c=i[t.valueDim.index]+o+e.symbolMargin*2;for(Ln(r,function(p){p.__pictorialAnimationIndex=v,p.__pictorialRepeatTimes=u,v<u?Rt(p,null,g(v),e,a):Rt(p,null,{scaleX:0,scaleY:0},e,a,function(){n.remove(p)}),v++});v<u;v++){var h=jl(e);h.__pictorialAnimationIndex=v,h.__pictorialRepeatTimes=u,n.add(h);var f=g(v);Rt(h,{x:f.x,y:f.y,scaleX:0,scaleY:0},{scaleX:f.scaleX,scaleY:f.scaleY,rotation:f.rotation},e,a)}function g(p){var d=l.slice(),m=e.pxSign,y=p;return(e.symbolRepeatDirection==="start"?m>0:m<0)&&(y=u-1-p),d[s.index]=c*(y-u/2+.5)+l[s.index],{x:d[0],y:d[1],scaleX:e.symbolScale[0],scaleY:e.symbolScale[1],rotation:e.rotation}}}function Ql(r,t,e,a){var n=r.__pictorialBundle,i=r.__pictorialMainPath;i?Rt(i,null,{x:e.pathPosition[0],y:e.pathPosition[1],scaleX:e.symbolScale[0],scaleY:e.symbolScale[1],rotation:e.rotation},e,a):(i=r.__pictorialMainPath=jl(e),n.add(i),Rt(i,{x:e.pathPosition[0],y:e.pathPosition[1],scaleX:0,scaleY:0,rotation:e.rotation},{scaleX:e.symbolScale[0],scaleY:e.symbolScale[1]},e,a))}function es(r,t,e){var a=$({},t.barRectShape),n=r.__pictorialBarRect;n?Rt(n,null,{shape:a},t,e):(n=r.__pictorialBarRect=new Ae({z2:2,shape:a,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),n.disableMorphing=!0,r.add(n))}function ts(r,t,e,a){if(e.symbolClip){var n=r.__pictorialClipPath,i=$({},e.clipShape),o=t.valueDim,l=e.animationModel,s=e.dataIndex;if(n)J(n,{shape:i},l,s);else{i[o.wh]=0,n=new Ae({shape:i}),r.__pictorialBundle.setClipPath(n),r.__pictorialClipPath=n;var u={};u[o.wh]=e.clipShape[o.wh],ja[a?"updateProps":"initProps"](n,{shape:u},l,s)}}}function ro(r,t){var e=r.getItemModel(t);return e.getAnimationDelayParams=vg,e.isAnimationEnabled=cg,e}function vg(r){return{index:r.__pictorialAnimationIndex,count:r.__pictorialRepeatTimes}}function cg(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function no(r,t,e,a){var n=new j,i=new j;return n.add(i),n.__pictorialBundle=i,i.x=e.bundlePosition[0],i.y=e.bundlePosition[1],e.symbolRepeat?Jl(n,t,e):Ql(n,t,e),es(n,e,a),ts(n,t,e,a),n.__pictorialShapeStr=as(r,e),n.__pictorialSymbolMeta=e,n}function hg(r,t,e){var a=e.animationModel,n=e.dataIndex,i=r.__pictorialBundle;J(i,{x:e.bundlePosition[0],y:e.bundlePosition[1]},a,n),e.symbolRepeat?Jl(r,t,e,!0):Ql(r,t,e,!0),es(r,e,!0),ts(r,t,e,!0)}function io(r,t,e,a){var n=a.__pictorialBarRect;n&&n.removeTextContent();var i=[];Ln(a,function(o){i.push(o)}),a.__pictorialMainPath&&i.push(a.__pictorialMainPath),a.__pictorialClipPath&&(e=null),G(i,function(o){ka(o,{scaleX:0,scaleY:0},e,t,function(){a.parent&&a.parent.remove(a)})}),r.setItemGraphicEl(t,null)}function as(r,t){return[r.getItemVisual(t.dataIndex,"symbol")||"none",!!t.symbolRepeat,!!t.symbolClip].join(":")}function Ln(r,t,e){G(r.__pictorialBundle.children(),function(a){a!==r.__pictorialBarRect&&t.call(e,a)})}function Rt(r,t,e,a,n,i){t&&r.attr(t),a.symbolClip&&!n?e&&r.attr(e):e&&ja[n?"updateProps":"initProps"](r,e,a.animationModel,a.dataIndex,i)}function oo(r,t,e){var a=e.dataIndex,n=e.itemModel,i=n.getModel("emphasis"),o=i.getModel("itemStyle").getItemStyle(),l=n.getModel(["blur","itemStyle"]).getItemStyle(),s=n.getModel(["select","itemStyle"]).getItemStyle(),u=n.getShallow("cursor"),v=i.get("focus"),c=i.get("blurScope"),h=i.get("scale");Ln(r,function(p){if(p instanceof pa){var d=p.style;p.useStyle($({image:d.image,x:d.x,y:d.y,width:d.width,height:d.height},e.style))}else p.useStyle(e.style);var m=p.ensureState("emphasis");m.style=o,h&&(m.scaleX=p.scaleX*1.1,m.scaleY=p.scaleY*1.1),p.ensureState("blur").style=l,p.ensureState("select").style=s,u&&(p.cursor=u),p.z2=e.z2});var f=t.valueDim.posDesc[+(e.boundingLength>0)],g=r.__pictorialBarRect;g.ignoreClip=!0,Ce(g,De(n),{labelFetcher:t.seriesModel,labelDataIndex:a,defaultText:ra(t.seriesModel.getData(),a),inheritColor:e.style.fill,defaultOpacity:e.style.opacity,defaultOutsidePosition:f}),ie(r,v,c,i.get("disabled"))}function lo(r){var t=Math.round(r);return Math.abs(r-t)<1e-4?t:Math.ceil(r)}var fg=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e.defaultSymbol="roundRect",e}return t.prototype.getInitialData=function(e){return e.stack=null,r.prototype.getInitialData.apply(this,arguments)}
1,t.type="series."+ia,t.dependencies=["grid"],t.defaultOption=xo(ua.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%",clip:!1,progressive:0,emphasis:{scale:!1},select:{itemStyle:{borderColor:Z.color.primary}}}),t}(ua);function Lp(r){r.registerChartView(ig),r.registerSeriesModel(fg),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,vl(ia)),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,cl(ia)),fl(r)}var Or=2,Gt="themeRiver",gg=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(e){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new Ut(le(this.getData,this),le(this.getRawData,this))},t.prototype.fixData=function(e){var a=e.length,n={},i=Yr(e,function(h){return n.hasOwnProperty(h[0]+"")||(n[h[0]+""]=-1),h[2]}),o=[];i.buckets.each(function(h,f){o.push({name:f,dataList:h})});for(var l=o.length,s=0;s<l;++s){for(var u=o[s].name,v=0;v<o[s].dataList.length;++v){var c=o[s].dataList[v][0]+"";n[c]=s}for(var c in n)n.hasOwnProperty(c)&&n[c]!==s&&(n[c]=s,e[a]=[c,0,u],a++)}return e},t.prototype.getInitialData=function(e,a){for(var n=this.getReferringComponents("singleAxis",Qs).models[0],i=n.get("type"),o=rn(e.data,function(g){return g[2]!==void 0}),l=this.fixData(o||[]),s=[],u=this.nameMap=Nt(),v=0,c=0;c<l.length;++c)s.push(l[c][Or]),u.get(l[c][Or])||(u.set(l[c][Or],v),v++);var h=cn(l,{coordDimensions:["single"],dimensionsDefine:[{name:"time",type:$r(i)},{name:"value",type:"float"},{name:"name",type:"ordinal"}],encodeDefine:{single:0,value:1,itemName:2}}).dimensions,f=new Mt(h,this);return f.initData(l),f},t.prototype.getLayerSeries=function(){for(var e=this.getData(),a=e.count(),n=[],i=0;i<a;++i)n[i]=i;var o=e.mapDimension("single"),l=Yr(n,function(u){return e.get("name",u)}),s=[];return l.buckets.each(function(u,v){u.sort(function(c,h){return e.get(o,c)-e.get(o,h)}),s.push({name:v,indices:u})}),s},t.prototype.getAxisTooltipData=function(e,a,n){Q(e)||(e=e?[e]:[]);for(var i=this.getData(),o=this.getLayerSeries(),l=[],s=o.length,u,v=0;v<s;++v){for(var c=Number.MAX_VALUE,h=-1,f=o[v].indices.length,g=0;g<f;++g){var p=i.get(e[0],o[v].indices[g]),d=Math.abs(p-a);d<=c&&(u=p,c=d,h=o[v].indices[g])}l.push(h)}return{dataIndices:l,nestestValue:u}},t.prototype.formatTooltip=function(e,a,n){var i=this.getData(),o=i.getName(e),l=i.get(i.mapDimension("value"),e);return Ge("nameValue",{name:o,value:l})},t.type="series."+Gt,t.dependencies=["singleAxis"],t.defaultOption={z:2,colorBy:"data",coordinateSystem:"singleAxis",boundaryGap:["10%","10%"],singleAxisIndex:0,animationEasing:"linear",label:{margin:4,show:!0,position:"left",fontSize:11},emphasis:{label:{show:!0}}},t}(se),pg=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=Gt,e._layers=[],e}return t.prototype.render=function(e,a,n){var i=e.getData(),o=this,l=this.group,s=e.getLayerSeries(),u=i.getLayout("layoutInfo"),v=u.rect,c=u.boundaryGap;l.x=0,l.y=v.y+c[0];function h(d){return d.name}var f=new Qa(this._layersSeries||[],s,h,h),g=[];f.add(le(p,this,"add")).update(le(p,this,"update")).remove(le(p,this,"remove")).execute();function p(d,m,y){var S=o._layers;if(d==="remove"){l.remove(S[m]);return}for(var b=[],w=[],_,D=s[m].indices,A=0;A<D.length;A++){var P=i.getItemLayout(D[A]),I=P.x,x=P.y0,L=P.y;b.push(I,x),w.push(I,x+L),_=i.getItemVisual(D[A],"style")}var E,V=i.getItemLayout(D[0]),T=e.getModel("label"),R=T.get("margin"),N=e.getModel("emphasis");if(d==="add"){var C=g[m]=new j;E=new al({shape:{points:b,stackedOnPoints:w,smooth:.4,stackedOnSmooth:.4,smoothConstraint:!1},z2:0}),C.add(E),l.add(C),e.isAnimationEnabled()&&E.setClipPath(dg(E.getBoundingRect(),e,function(){E.removeClipPath()}))}else{var C=S[y];E=C.childAt(0),l.add(C),g[m]=C,J(E,{shape:{points:b,stackedOnPoints:w}},e),Oe(E)}Ce(E,De(e),{labelDataIndex:D[A-1],defaultText:i.getName(D[A-1]),inheritColor:_.fill},{normal:{verticalAlign:"middle"}}),E.setTextConfig({position:null,local:!0});var M=E.getTextContent();M&&(M.x=V.x-R,M.y=V.y0+V.y/2),E.useStyle(_),i.setItemGraphicEl(m,E),ce(E,e),ie(E,N.get("focus"),N.get("blurScope"),N.get("disabled"))}this._layersSeries=s,this._layers=g},t.type=Gt,t}(ae);function dg(r,t,e){var a=new Ae({shape:{x:r.x-10,y:r.y-10,width:0,height:r.height+20}});return ue(a,{shape:{x:r.x-50,width:r.width+100,height:r.height+20}},t,e),a}var yg=he(Gt,mg);function mg(r,t){r.eachSeriesByType(Gt,function(e){var a=e.getData(),n=e.coordinateSystem,i={},o=n.getRect();i.rect=o;var l=e.get("boundaryGap"),s=n.getAxis();if(i.boundaryGap=l,s.orient==="horizontal"){l[0]=U(l[0],o.height),l[1]=U(l[1],o.height);var u=o.height-l[0]-l[1];so(a,e,u)}else{l[0]=U(l[0],o.width),l[1]=U(l[1],o.width);var v=o.width-l[0]-l[1];so(a,e,v)}a.setLayout("layoutInfo",i)})}function so(r,t,e){if(r.count())for(var a=t.coordinateSystem,n=t.getLayerSeries(),i=r.mapDimension("single"),o=r.mapDimension("value"),l=ee(n,function(d){return ee(d.indices,function(m){var y=a.dataToPoint(r.get(i,m));return y[1]=r.get(o,m),y})}),s=Sg(l),u=s.y0,v=e/s.max,c=n.length,h=n[0].indices.length,f,g=0;g<h;++g){f=u[g]*v,r.setItemLayout(n[0].indices[g],{layerIndex:0,x:l[0][g][0],y0:f,y:l[0][g][1]*v});for(var p=1;p<c;++p)f+=l[p-1][g][1]*v,r.setItemLayout(n[p].indices[g],{layerIndex:p,x:l[p][g][0],y0:f,y:l[p][g][1]*v})}}function Sg(r){for(var t=r.length,e=r[0].length,a=[],n=[],i=0,o=0;o<e;++o){for(var l=0,s=0;s<t;++s)l+=r[s][o][1];l>i&&(i=l),a.push(l)}for(var u=0;u<e;++u)n[u]=(i-a[u])/2;i=0;for(var v=0;v<e;++v){var c=a[v]+n[v];c>i&&(i=c)}return{y0:n,max:i}}function Cp(r){r.registerChartView(pg),r.registerSeriesModel(gg),r.registerLayout(yg),r.registerProcessor(ba(Gt))}var bg=2,wg=4,uo=function(r){z(t,r);function t(e,a,n,i){var o=r.call(this)||this;o.z2=bg,o.textConfig={inside:!0},ne(o).seriesIndex=a.seriesIndex;var l=new Me({z2:wg,silent:e.getModel().get(["label","silent"])});return o.setTextContent(l),o.updateData(!0,e,a,n,i),o}return t.prototype.updateData=function(e,a,n,i,o){this.node=a,a.piece=this,n=n||this._seriesModel,i=i||this._ecModel;var l=this;ne(l).dataIndex=a.dataIndex;var s=a.getModel(),u=s.getModel("emphasis"),v=a.getLayout(),c=$({},v);c.label=null;var h=a.getVisual("style");h.lineJoin="bevel";var f=a.getVisual("decal");f&&(h.decal=Bo(f,o));var g=Fe(s.getModel("itemStyle"),c,!0);$(c,g),G(Qt,function(y){var S=l.ensureState(y),b=s.getModel([y,"itemStyle"]);S.style=b.getItemStyle();var w=Fe(b,c);w&&(S.shape=w)}),e?(l.setShape(c),l.shape.r=v.r0,ue(l,{shape:{r:v.r}},n,a.dataIndex)):(J(l,{shape:c},n),Oe(l)),l.useStyle(h),this._updateLabel(n);var p=s.getShallow("cursor");p&&l.attr("cursor",p),this._seriesModel=n||this._seriesModel,this._ecModel=i||this._ecModel;var d=u.get("focus"),m=d==="relative"?Na(a.getAncestorsIndices(),a.getDescendantIndices()):d==="ancestor"?a.getAncestorsIndices():d==="descendant"?a.getDescendantIndices():d;ie(this,m,u.get("blurScope"),u.get("disabled"))},t.prototype._updateLabel=function(e){var a=this,n=this.node.getModel(),i=n.getModel("label"),o=this.node.getLayout(),l=o.endAngle-o.startAngle,s=(o.startAngle+o.endAngle)/2,u=Math.cos(s),v=Math.sin(s),c=this,h=c.getTextContent(),f=this.node.dataIndex,g=i.get("minA
1ngle")/180*Math.PI,p=i.get("show")&&!(g!=null&&Math.abs(l)<g);h.ignore=!p,G(Wr,function(m){var y=m==="normal"?n.getModel("label"):n.getModel([m,"label"]),S=m==="normal",b=S?h:h.ensureState(m),w=e.getFormattedLabel(f,m);S&&(w=w||a.node.name),b.style=$e(y,{},null,m!=="normal",!0),w&&(b.style.text=w);var _=y.get("show");_!=null&&!S&&(b.ignore=!_);var D=d(y,"position"),A=S?c:c.states[m],P=A.style.fill;A.textConfig={outsideFill:y.get("color")==="inherit"?P:null,inside:D!=="outside"};var I,x=d(y,"distance")||0,L=d(y,"align"),E=d(y,"rotate"),V=Math.PI*.5,T=Math.PI*1.5,R=_a(E==="tangential"?Math.PI/2-s:s),N=R>V&&!Jn(R-V)&&R<T;D==="outside"?(I=o.r+x,L=N?"right":"left"):!L||L==="center"?(o.r0===0&&Jn(l-2*Math.PI)?I=0:I=(o.r+o.r0)/2,L="center"):L==="left"?(I=o.r0+x,L=N?"right":"left"):L==="right"&&(I=o.r-x,L=N?"left":"right"),b.style.align=L,b.style.verticalAlign=d(y,"verticalAlign")||"middle",b.x=I*u+o.cx,b.y=I*v+o.cy;var C=0;E==="radial"?C=_a(-s)+(N?Math.PI:0):E==="tangential"?C=_a(Math.PI/2-s)+(N?Math.PI:0):Ne(E)&&(C=E*Math.PI/180),b.rotation=_a(C)});function d(m,y){var S=m.get(y);return S??i.get(y)}h.dirtyStyle()},t}(je),Dt="sunburst",_g=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.ignoreStyleOnData=!0,e}return t.prototype.getInitialData=function(e,a){var n={name:e.name,children:e.data};rs(n);var i=this._levelModels=ee(e.levels||[],function(s){return new ht(s,this,a)},this),o=mn.createTree(n,this,l);function l(s){s.wrapMethod("getItemModel",function(u,v){var c=o.getNodeByDataIndex(v),h=i[c.depth];return h&&(u.parentModel=h),u})}return o.data},t.prototype.optionUpdated=function(){this.resetViewRoot()},t.prototype.getDataParams=function(e){var a=r.prototype.getDataParams.apply(this,arguments),n=this.getData().tree.getNodeByDataIndex(e);return a.treePathInfo=nr(n,this),a},t.prototype.getLevelModel=function(e){return this._levelModels&&this._levelModels[e.depth]},t.prototype.getViewRoot=function(){return this._viewRoot},t.prototype.resetViewRoot=function(e){e?this._viewRoot=e:e=this._viewRoot;var a=this.getRawData().tree.root;(!e||e!==a&&!a.contains(e))&&(this._viewRoot=a)},t.prototype.enableAriaDecal=function(){Al(this)},t.type="series."+Dt,t.defaultOption={z:2,center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,minAngle:0,stillShowZeroSum:!0,nodeClick:"rootToNode",renderLabelForZeroData:!1,label:{rotate:"radial",show:!0,opacity:1,align:"center",position:"inside",distance:5,silent:!0},itemStyle:{borderWidth:1,borderColor:"white",borderType:"solid",shadowBlur:0,shadowColor:"rgba(0, 0, 0, 0.2)",shadowOffsetX:0,shadowOffsetY:0,opacity:1},emphasis:{focus:"descendant"},blur:{itemStyle:{opacity:.2},label:{opacity:.1}},animationType:"expansion",animationDuration:1e3,animationDurationUpdate:500,data:[],sort:"desc"},t}(se);function rs(r){var t=0;G(r.children,function(a){rs(a);var n=a.value;Q(n)&&(n=n[0]),t+=n});var e=r.value;Q(e)&&(e=e[0]),(e==null||isNaN(e))&&(e=t),e<0&&(e=0),Q(r.value)?r.value[0]=e:r.value=e}var Qr="sunburstRootToNode",vo="sunburstHighlight",Dg="sunburstUnhighlight";function xg(r){r.registerAction({type:Qr,update:"updateView"},function(t,e){e.eachComponent({mainType:"series",subType:"sunburst",query:t},a);function a(n,i){var o=ca(t,[Qr],n);if(o){var l=n.getViewRoot();l&&(t.direction=Sn(l,o.node)?"rollUp":"drillDown"),n.resetViewRoot(o.node)}}}),r.registerAction({type:vo,update:"none"},function(t,e,a){t=$({},t),e.eachComponent({mainType:"series",subType:"sunburst",query:t},n);function n(i){var o=ca(t,[vo],i);o&&(t.dataIndex=o.node.dataIndex)}a.dispatchAction($(t,{type:"highlight"}))}),r.registerAction({type:Dg,update:"updateView"},function(t,e,a){t=$({},t),a.dispatchAction($(t,{type:"downplay"}))})}var Ag=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=Dt,e}return t.prototype.render=function(e,a,n,i){var o=this;this.seriesModel=e,this.api=n,this.ecModel=a;var l=e.getData(),s=l.tree.root,u=e.getViewRoot(),v=this.group,c=e.get("renderLabelForZeroData"),h=[];u.eachNode(function(y){h.push(y)});var f=this._oldChildren||[];g(h,f),m(s,u),this._initEvents(),this._oldChildren=h;function g(y,S){if(y.length===0&&S.length===0)return;new Qa(S,y,b,b).add(w).update(w).remove(Xe(w,null)).execute();function b(_){return _.getId()}function w(_,D){var A=_==null?null:y[_],P=D==null?null:S[D];p(A,P)}}function p(y,S){if(!c&&y&&!y.getValue()&&(y=null),y!==s&&S!==s){if(S&&S.piece)y?(S.piece.updateData(!1,y,e,a,n),l.setItemGraphicEl(y.dataIndex,S.piece)):d(S);else if(y){var b=new uo(y,e,a,n);v.add(b),l.setItemGraphicEl(y.dataIndex,b)}}}function d(y){y&&y.piece&&(v.remove(y.piece),y.piece=null)}function m(y,S){S.depth>0?(o.virtualPiece?o.virtualPiece.updateData(!1,y,e,a,n):(o.virtualPiece=new uo(y,e,a,n),v.add(o.virtualPiece)),S.piece.off("click"),o.virtualPiece.on("click",function(b){o._rootToNode(S.parentNode)})):o.virtualPiece&&(v.remove(o.virtualPiece),o.virtualPiece=null)}},t.prototype._initEvents=function(){var e=this;
1this.group.off("click"),this.group.on("click",function(a){var n=!1,i=e.seriesModel.getViewRoot();i.eachNode(function(o){if(!n&&o.piece&&o.piece===a.target){var l=o.getModel().get("nodeClick");if(l==="rootToNode")e._rootToNode(o);else if(l==="link"){var s=o.getModel(),u=s.get("link");if(u){var v=s.get("target",!0)||"_blank";Eo(u,v)}}n=!0}})})},t.prototype._rootToNode=function(e){e!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:Qr,from:this.uid,seriesId:this.seriesModel.id,targetNode:e})},t.prototype.containPoint=function(e,a){var n=a.getData(),i=n.getItemLayout(0);if(i){var o=e[0]-i.cx,l=e[1]-i.cy,s=Math.sqrt(o*o+l*l);return s<=i.r&&s>=i.r0}},t.type=Dt,t}(ae),Ig=he(Dt,Lg);function Lg(r){var t={};function e(a,n,i){if(a.depth===0)return Z.color.neutral50;for(var o=a;o&&o.depth>1;)o=o.parentNode;var l=n.getColorFromPalette(o.name||o.dataIndex+"",t);return a.depth>1&&Le(l)&&(l=Cs(l,(a.depth-1)/(i-1)*.5)),l}r.eachSeriesByType(Dt,function(a){var n=a.getData(),i=n.tree;i.eachNode(function(o){var l=o.getModel(),s=l.getModel("itemStyle").getItemStyle();s.fill||(s.fill=e(o,a,i.root.height));var u=n.ensureUniqueItemVisual(o.dataIndex,"style");$(u,s)})})}var co=Math.PI/180,Cg=he(Dt,Tg);
1function Tg(r,t){r.eachSeriesByType(Dt,function(e){var a=e.get("center"),n=e.get("radius");Q(n)||(n=[0,n]),Q(a)||(a=[a,a]);var i=t.getWidth(),o=t.getHeight(),l=Math.min(i,o),s=U(a[0],i),u=U(a[1],o),v=U(n[0],l/2),c=U(n[1],l/2),h=-e.get("startAngle")*co,f=e.get("minAngle")*co,g=e.getData().tree.root,p=e.getViewRoot(),d=p.depth,m=e.get("sort");m!=null&&ns(p,m);var y=0;G(p.children,function(T){!isNaN(T.getValue())&&y++});var S=p.getValue(),b=Math.PI/(S||y)*2,w=p.depth>0,_=p.height-(w?-1:1),D=(c-v)/(_||1),A=e.get("clockwise"),P=e.get("stillShowZeroSum"),I=A?1:-1,x=function(T,R){if(T){var N=R;if(T!==g){var C=T.getValue(),M=S===0&&P?b:C*b;M<f&&(M=f),N=R+I*M;var k=T.depth-d-(w?-1:1),O=v+D*k,B=v+D*(k+1),W=e.getLevelModel(T);if(W){var H=W.get("r0",!0),X=W.get("r",!0),ve=W.get("radius",!0);ve!=null&&(H=ve[0],X=ve[1]),H!=null&&(O=U(H,l/2)),X!=null&&(B=U(X,l/2))}T.setLayout({angle:M,startAngle:R,endAngle:N,clockwise:A,cx:s,cy:u,r0:O,r:B})}if(T.children&&T.children.length){var me=0;G(T.children,function(Y){me+=x(Y,R+me)})}return N-R}};if(w){var L=v,E=v+D,V=Math.PI*2;g.setLayout({angle:V,startAngle:h,endAngle:h+V,clockwise:A,cx:s,cy:u,r0:L,r:E})}x(p,h)})}function ns(r,t){var e=r.children||[];r.children=Pg(e,t),e.length&&G(r.children,function(a){ns(a,t)})}function Pg(r,t){if(Ie(t)){var e=ee(r,function(n,i){var o=n.getValue();return{params:{depth:n.depth,height:n.height,dataIndex:n.dataIndex,getValue:function(){return o}},index:i}});return e.sort(function(n,i){return t(n.params,i.params)}),ee(e,function(n){return r[n.index]})}else{var a=t==="asc";return r.sort(function(n,i){var o=(n.getValue()-i.getValue())*(a?1:-1);return o===0?(n.dataIndex-i.dataIndex)*(a?-1:1):o})}}function Tp(r){r.registerChartView(Ag),r.registerSeriesModel(_g),r.registerLayout(Cg),r.registerVisual(Ig),xg(r)}var ho={color:"fill",borderColor:"stroke"},Eg={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},Ze=Ft(),Rg=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},t.prototype.getInitialData=function(e,a){return et(null,this)},t.prototype.getDataParams=function(e,a,n){var i=r.prototype.getDataParams.call(this,e,a);return n&&(i.info=Ze(n).info),i},t.type="series.custom",t.dependencies=["grid","polar","geo","singleAxis","calendar","matrix"],t.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},t}(se);function Ng(r,t){return t=t||[0,0],ee(["x","y"],function(e,a){var n=this.getAxis(e),i=t[a],o=r[a]/2;return n.type==="category"?Je(n).w:Math.abs(n.dataToCoord(i-o)-n.dataToCoord(i+o))},this)}function Mg(r){var t=r.master.getRect();return{coordSys:{type:"cartesian2d",x:t.x,y:t.y,width:t.width,height:t.height},api:{coord:function(e){return r.dataToPoint(e)},size:le(Ng,r)}}}function Vg(r,t){return t=t||[0,0],ee([0,1],function(e){var a=t[e],n=r[e]/2,i=[],o=[];return i[e]=a-n,o[e]=a+n,i[1-e]=o[1-e]=t[1-e],Math.abs(this.dataToPoint(i)[e]-this.dataToPoint(o)[e])},this)}function kg(r){var t=r.view,e=t.getBoundingRect();return{coordSys:{type:"geo",x:e.x,y:e.y,width:e.width,height:e.height,zoom:mu(t)},api:{coord:function(a){return r.dataToPoint(a)},size:le(Vg,r)}}}function Og(r,t){var e=this.getAxis(),a=t instanceof Array?t[0]:t,n=(r instanceof Array?r[0]:r)/2;return e.type==="category"?Je(e).w:Math.abs(e.dataToCoord(a-n)-e.dataToCoord(a+n))}function Gg(r){var t=r.getRect();return{coordSys:{type:"singleAxis",x:t.x,y:t.y,width:t.width,height:t.height},api:{coord:function(e){return r.dataToPoint(e)},size:le(Og,r)}}}function Bg(r,t){return t=t||[0,0],ee(["Radius","Angle"],function(e,a){var n="get"+e+"Axis",i=this[n](),o=t[a],l=r[a]/2,s=i.type==="category"?Je(i).w:Math.abs(i.dataToCoord(o-l)-i.dataToCoord(o+l));return e==="Angle"&&(s=s*Math.PI/180),s},this)}function zg(r){var t=r.getRadiusAxis(),e=r.getAngleAxis(),a=t.getExtent();return a[0]>a[1]&&a.reverse(),{coordSys:{type:"polar",cx:r.cx,cy:r.cy,r:a[1],r0:a[0]},api:{coord:function(n){var i=t.dataToRadius(n[0]),o=e.dataToAngle(n[1]),l=r.coordToPoint([i,o]);return l.push(i,o*Math.PI/180),l},size:le(Bg,r)}}}function Fg(r){var t=r.getRect(),e=r.getRangeInfo();return{coordSys:{type:"calendar",x:t.x,y:t.y,width:t.width,height:t.height,cellWidth:r.getCellWidth(),cellHeight:r.getCellHeight(),rangeInfo:{start:e.start,end:e.end,weeks:e.weeks,dayCount:e.allDay}},api:{coord:function(a,n){return r.dataToPoint(a,n)},layout:function(a,n){return r.dataToLayout(a,n)}}}}function Hg(r){var t=r.getRect();return{coordSys:{type:"matrix",x:t.x,y:t.y,width:t.width,height:t.height},api:{coord:function(e,a){return r.dataToPoint(e,a)},layout:function(e,a){return r.dataToLayout(e,a)}}}}var qe="emphasis",lt="normal",Cn="blur",Tn="select",pt=[lt,qe,Cn,Tn],Gr={normal:["itemStyle"],emphasis:[qe,"itemStyle"],blur:[Cn,"itemStyle"],select:[Tn,"itemStyle"]},Br={normal:["label"],emphasis:[qe,"label"],blur:[Cn,"label"],select:[Tn,"label"]},Wg=["x","y"],Ug="e\0\0",Te={normal:{},emphasis:{},blur:{},select:{}},Yg={cartesian2d:Mg,geo:kg,single:Gg,polar:zg,calendar:Fg,matrix:Hg};function en(r){return r instanceof xe}function tn(r){return r instanceof So}function $g(r,t){t.copyTransform(r),tn(t)&&tn(r)&&(t.setStyle(r.style),t.z=r.z,t.z2=r.z2,t.zlevel=r.zlevel,t.invisible=r.invisible,t.ignore=r.ignore,en(t)&&en(r)&&t.setShape(r.shape))}var Xg=function(r){z(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,a,n,i){this._progressiveEls=null;var o=this._data,l=e.getData(),s=this.group,u=fo(e,l,a,n);o||s.removeAll(),l.diff(o).add(function(c){zr(n,null,c,u(c,i),e,s,l)}).remove(function(c){var h=o.getItemGraphicEl(c);h&&dn(h,Ze(h).option,e)}).update(function(c,h){var f=o.getItemGraphicEl(h);zr(n,f,c,u(c,i),e,s,l)}).execute();var v=e.get("clip",!0)?wt(e.coordinateSystem,!1,e):null;v?s.setClipPath(v):s.removeClipPath(),this._data=l},t.prototype.incrementalPrepareRender=function(e,a,n){this.group.removeAll(),this._data=null},t.prototype.incrementalRender=function(e,a,n,i,o){var l=a.getData(),s=fo(a,l,n,i),u=this._progressiveEls=[];function v(f){f.isGroup||(f.incremental=We(a),f.ensureState("emphasis").hoverLayer=Go)}for(var c=e.start;c<e.end;c++){var h=zr(null,null,c,s(c,o),a,this.group,l);h&&(h.traverse(v),u.push(h))}},t.prototype.eachRendered=function(e){qa(this._progressiveEls||this.group,e)},t.prototype.filterForExposedEvent=function(e,a,n,i){var o=a.element;if(o==null||n.name===o)return!0;for(;(n=n.__hostTarget||n.parent)&&n!==this.group;)if(n.name===o)return!0;return!1},t.type="custom",t}(ae);function Pn(r){var t=r.type,e;if(t==="path"){var a=r.shape,n=a.width!=null&&a.height!=null?{x:a.x||0,y:a.y||0,width:a.width,height:a.height}:null,i=ls(a);e=ei(i,null,n,a.layout||"center"),Ze(e).customPathData=i}else if(t==="image")e=new pa({}),Ze(e).customImagePath=r.style.image;else if(t==="text")e=new Me({});else if(t==="group")e=new j;else if(t==="compoundPath"){var a=r.shape;if(!a||!a.paths){var o="";Ra(o)}var l=ee(a.paths,function(v){if(v.type==="path")return ei(v.shape.pathData,v,null);var c=ti(v.type);if(!c){var h="";Ra(h)}return new c});e=new Ts({shape:{paths:l}})}else{var s=ti(t);if(!s){var o="";Ra(o)}e=new s}return Ze(e).customGraphicType=t,e.name=r.name,e.z2EmphasisLift=1,e.z2SelectLift=1,e}function En(r,t,e,a,n,i,o){Su(t);var l=n&&n.normal.cfg;l&&t.setTextConfig(l),a&&a.transition==null&&(a.transition=Wg);var s=a&&a.style;if(s){if(t.type==="text"){var u=s;He(u,"textFill")&&(u.fill=u.textFill),He(u,"textStroke")&&(u.stroke=u.textStroke)}var v=void 0,c=en(t)?s.decal:null;r&&c&&(c.dirty=!0,v=Bo(c,r)),s.__decalPattern=v}if(tn(t)&&s){var v=s.__decalPattern;v&&(s.decal=v)}bu(t,a,i,{dataIndex:e,isInit:o,clearStyle:!0}),wu(t,a.keyframeAnimation,i)}function is(r,t,e,a,n){var i=t.isGroup?null:t,o=n&&n[r].cfg;if(i){var l=i.ensureState(r);if(a===!1){var s=i.getState(r);
1s&&(s.style=null)}else l.style=a||null;o&&(l.textConfig=o),Oa(i)}}function Zg(r,t,e){if(!r.isGroup){var a=r,n=e.currentZ,i=e.currentZLevel;a.z=n,a.zlevel=i;var o=t.z2;o!=null&&(a.z2=o||0);for(var l=0;l<pt.length;l++)qg(a,t,pt[l])}}function qg(r,t,e){var a=e===lt,n=a?t:Xa(t,e),i=n?n.z2:null,o;i!=null&&(o=a?r:r.ensureState(e),o.z2=i||0)}function fo(r,t,e,a){var n=r.get("renderItem");if(typeof n=="string"){var i=tu(n);i&&(n=i)}var o=r.coordinateSystem,l={};o&&(l=o.prepareCustoms?o.prepareCustoms(o):Yg[o.type](o));for(var s=Ve({getWidth:a.getWidth,getHeight:a.getHeight,getZr:a.getZr,getDevicePixelRatio:a.getDevicePixelRatio,value:w,style:D,ordinalRawValue:_,styleEmphasis:A,visual:x,barLayout:L,currentSeriesIndices:E,font:V},l.api||{}),u={context:{},seriesId:r.id,seriesName:r.name,seriesIndex:r.seriesIndex,coordSys:l.coordSys,dataInsideLength:t.count(),encode:Kg(r.getData()),itemPayload:r.get("itemPayload")||{}},v,c,h={},f={},g={},p={},d=0;d<pt.length;d++){var m=pt[d];g[m]=r.getModel(Gr[m]),p[m]=r.getModel(Br[m])}function y(T){return T===v?c||(c=t.getItemModel(T)):t.getItemModel(T)}function S(T,R){return t.hasItemOption?T===v?h[R]||(h[R]=y(T).getModel(Gr[R])):y(T).getModel(Gr[R]):g[R]}function b(T,R){return t.hasItemOption?T===v?f[R]||(f[R]=y(T).getModel(Br[R])):y(T).getModel(Br[R]):p[R]}return function(T,R){return v=T,c=null,h={},f={},n&&n(Ve({dataIndexInside:T,dataIndex:t.getRawIndex(T),actionType:R?R.type:null},u),s)};function w(T,R){return R==null&&(R=v),t.getStore().get(t.getDimensionIndex(T||0),R)}function _(T,R){R==null&&(R=v),T=T||0;var N=t.getDimensionInfo(T);if(!N){var C=t.getDimensionIndex(T);return C>=0?t.getStore().get(C,R):void 0}var M=t.get(N.name,R),k=N&&N.ordinalMeta;return k?k.categories[M]:M}function D(T,R){R==null&&(R=v);var N=t.getItemVisual(R,"style"),C=N&&N.fill,M=N&&N.opacity,k=S(R,lt).getItemStyle();C!=null&&(k.fill=C),M!=null&&(k.opacity=M);var O={inheritColor:Le(C)?C:Z.color.neutral99},B=b(R,lt),W=$e(B,null,O,!1,!0);W.text=B.getShallow("show")?Jt(r.getFormattedLabel(R,lt),ra(t,R)):null;var H=Qn(B,O,!1);return I(T,k),k=oi(k,W,H),T&&P(k,T),k.legacy=!0,k}function A(T,R){R==null&&(R=v);var N=S(R,qe).getItemStyle(),C=b(R,qe),M=$e(C,null,null,!0,!0);M.text=C.getShallow("show")?xt(r.getFormattedLabel(R,qe),r.getFormattedLabel(R,lt),ra(t,R)):null;var k=Qn(C,null,!0);return I(T,N),N=oi(N,M,k),T&&P(N,T),N.legacy=!0,N}function P(T,R){for(var N in R)He(R,N)&&(T[N]=R[N])}function I(T,R){T&&(T.textFill&&(R.textFill=T.textFill),T.textPosition&&(R.textPosition=T.textPosition))}function x(T,R){if(R==null&&(R=v),He(ho,T)){var N=t.getItemVisual(R,"style");return N?N[ho[T]]:null}if(He(Eg,T))return t.getItemVisual(R,T)}function L(T){if(o.type==="cartesian2d"){var R=o.getBaseAxis();return Yu(Ve({axis:R},T))}}function E(){return e.getCurrentSeriesIndices()}function V(T){return eu(T,e)}}function Kg(r){var t={};return G(r.dimensions,function(e){var a=r.getDimensionInfo(e);if(!a.isExtraCoord){var n=a.coordDim,i=t[n]=t[n]||[];i[a.coordDimIndex]=r.getDimensionIndex(e)}}),t}function zr(r,t,e,a,n,i,o){if(!a){i.remove(t);return}var l=Rn(r,t,e,a,n,i);return l&&o.setItemGraphicEl(e,l),l&&ie(l,a.focus,a.blurScope,a.emphasisDisabled),l}function Rn(r,t,e,a,n,i){var o=-1,l=t;t&&os(t,a,n)&&(o=ke(i.childrenRef(),t),t=null);var s=!t,u=t;u?u.clearStates():(u=Pn(a),l&&$g(l,u)),a.morph===!1?u.disableMorphing=!0:u.disableMorphing&&(u.disableMorphing=!1),a.tooltipDisabled&&(u.tooltipDisabled=!0),Te.normal.cfg=Te.normal.conOpt=Te.emphasis.cfg=Te.emphasis.conOpt=Te.blur.cfg=Te.blur.conOpt=Te.select.cfg=Te.select.conOpt=null,Te.isLegacy=!1,Jg(u,e,a,n,s,Te),jg(u,e,a,n,s),En(r,u,e,a,Te,n,s),He(a,"info")&&(Ze(u).info=a.info);for(var v=0;v<pt.length;v++){var c=pt[v];if(c!==lt){var h=Xa(a,c),f=Nn(a,h,c);is(c,u,h,f,Te)}}return Zg(u,a,n),a.type==="group"&&Qg(r,u,e,a,n),o>=0?i.replaceAt(u,o):i.add(u),u}function os(r,t,e){var a=Ze(r),n=t.type,i=t.shape,o=t.style;return e.isUniversalTransitionEnabled()||n!=null&&n!==a.customGraphicType||n==="path"&&rp(i)&&ls(i)!==a.customPathData||n==="image"&&He(o,"image")&&o.image!==a.customImagePath}function jg(r,t,e,a,n){var i=e.clipPath;if(i===!1)r&&r.getClipPath()&&r.removeClipPath();else if(i){var o=r.getClipPath();o&&os(o,i,a)&&(o=null),o||(o=Pn(i),r.setClipPath(o)),En(null,o,t,i,null,a,n)}}function Jg(r,t,e,a,n,i){if(!(r.isGroup||r.type==="compoundPath")){go(e,null,i),go(e,qe,i);var o=i.normal.conOpt,l=i.emphasis.conOpt,s=i.blur.conOpt,u=i.select.conOpt;if(o!=null||l!=null||u!=null||s!=null){var v=r.getTextContent();if(o===!1)v&&r.removeTextContent();else{o=i.normal.conOpt=o||{type:"text"},v?v.clearStates():(v=Pn(o),r.setTextContent(v)),En(null,v,t,o,null,a,n);for(var c=o&&o.style,h=0;h<pt.length;h++){var f=pt[h];if(f!==lt){var g=i[f].conOpt;is(f,v,g,Nn(o,g,f),null)}}c?v.dirty():v.markRedraw()}}}}
1function go(r,t,e){var a=t?Xa(r,t):r,n=t?Nn(r,a,qe):r.style,i=r.type,o=a?a.textConfig:null,l=r.textContent,s=l?t?Xa(l,t):l:null;if(n&&(e.isLegacy||_u(n,i,!!o,!!s))){e.isLegacy=!0;var u=Du(n,i,!t);!o&&u.textConfig&&(o=u.textConfig),!s&&u.textContent&&(s=u.textContent)}if(!t&&s){var v=s;!v.type&&(v.type="text")}var c=t?e[t]:e.normal;c.cfg=o,c.conOpt=s}function Xa(r,t){return t?r?r[t]:null:r}function Nn(r,t,e){var a=t&&t.style;return a==null&&e===qe&&r&&(a=r.styleEmphasis),a}function Qg(r,t,e,a,n){var i=a.children,o=i?i.length:0,l=a.$mergeChildren,s=l==="byName"||a.diffChildrenByName,u=l===!1;if(!(!o&&!s&&!u)){if(s){tp({api:r,oldChildren:t.children()||[],newChildren:i||[],dataIndex:e,seriesModel:n,group:t});return}u&&t.removeAll();for(var v=0;v<o;v++){var c=i[v],h=t.childAt(v);c?(c.ignore==null&&(c.ignore=!1),Rn(r,h,e,c,n,t)):h.ignore=!0}for(var f=t.childCount()-1;f>=v;f--){var g=t.childAt(f);ep(t,g,n)}}}function ep(r,t,e){t&&dn(t,Ze(r).option,e)}function tp(r){new Qa(r.oldChildren,r.newChildren,po,po,r).add(yo).update(yo).remove(ap).execute()}function po(r,t){var e=r&&r.name;return e??Ug+t}function yo(r,t){var e=this.context,a=r!=null?e.newChildren[r]:null,n=t!=null?e.oldChildren[t]:null;Rn(e.api,n,e.dataIndex,a,e.seriesModel,e.group)}function ap(r){var t=this.context,e=t.oldChildren[r];e&&dn(e,Ze(e).option,t.seriesModel)}function ls(r){return r&&(r.pathData||r.d)}function rp(r){return r&&(He(r,"pathData")||He(r,"d"))}function Pp(r){r.registerChartView(Xg),r.registerSeriesModel(Rg)}export{up as BarChart,_p as BoxplotChart,Dp as CandlestickChart,yp as ChordChart,Pp as CustomChart,xp as EffectScatterChart,Sp as FunnelChart,mp as GaugeChart,dp as GraphChart,Ip as HeatmapChart,sp as LineChart,Ap as LinesChart,fp as MapChart,bp as ParallelChart,Lp as PictorialBarChart,vp as PieChart,hp as RadarChart,wp as SankeyChart,cp as ScatterChart,Tp as SunburstChart,Cp as ThemeRiverChart,gp as TreeChart,pp as TreemapChart};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.