import{d as HP,ai as NS,$ as WP,L as $u,r as zS,M as YP,b as UP,m as XP,a as Cn,ax as jP,ay as ZP,o as qP,c as KP,a0 as JP,au as $P,a2 as QP,az as BS,_ as eO,__tla as tO}from"./index-f90b5c34.js";let VS,Yf,nO=Promise.all([(()=>{try{return tO}catch{}})()]).then(async()=>{var Qu=function(n,e){return Qu=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,i){t.__proto__=i}||function(t,i){for(var r in i)Object.prototype.hasOwnProperty.call(i,r)&&(t[r]=i[r])},Qu(n,e)};function V(n,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function t(){this.constructor=n}Qu(n,e),n.prototype=e===null?Object.create(e):(t.prototype=e.prototype,new t)}var FS=function(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1},Ei=new function(){this.browser=new FS,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<"u"};typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(Ei.wxa=!0,Ei.touchEventsSupported=!0):typeof document>"u"&&typeof self<"u"?Ei.worker=!0:typeof navigator>"u"||navigator.userAgent.indexOf("Node.js")===0?(Ei.node=!0,Ei.svgSupported=!0):function(n,e){var t=e.browser,i=n.match(/Firefox\/([\d.]+)/),r=n.match(/MSIE\s([\d.]+)/)||n.match(/Trident\/.+?rv:(([\d.]+))/),o=n.match(/Edge?\/([\d.]+)/),a=/micromessenger/i.test(n);i&&(t.firefox=!0,t.version=i[1]),r&&(t.ie=!0,t.version=r[1]),o&&(t.edge=!0,t.version=o[1],t.newEdge=+o[1].split(".")[0]>18),a&&(t.weChat=!0),e.svgSupported=typeof SVGRect<"u",e.touchEventsSupported="ontouchstart"in window&&!t.ie&&!t.edge,e.pointerEventsSupported="onpointerdown"in window&&(t.edge||t.ie&&+t.version>=11),e.domSupported=typeof document<"u";var s=document.documentElement.style;e.transform3dSupported=(t.ie&&"transition"in s||t.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in s)&&!("OTransition"in s),e.transformSupported=e.transform3dSupported||t.ie&&+t.version>=9}(navigator.userAgent,Ei);const _e=Ei;var Ni="12px sans-serif",Ro,Uf,GS=function(n){var e={};if(typeof JSON>"u")return e;for(var t=0;t=0)o=r*n.length;else for(var a=0;a>1)%2;f.style.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",c[g]+":0",p[v]+":0",c[1-g]+":auto",p[1-v]+":auto",""].join("!important;"),l.appendChild(f),h.push(f)}return h}(e,o),s=function(l,u,h){for(var c=h?"invTrans":"trans",p=u[c],d=u.srcCoords,f=[],g=[],v=!0,y=0;y<4;y++){var m=l[y].getBoundingClientRect(),x=2*y,_=m.left,w=m.top;f.push(_,w),v=v&&d&&_===d[x]&&w===d[x+1],g.push(l[y].offsetLeft,l[y].offsetTop)}return v&&p?p:(u.srcCoords=f,u[c]=h?hg(g,f):hg(f,g))}(a,o,r);if(s)return s(n,t,i),!0}return!1}function pg(n){return n.nodeName.toUpperCase()==="CANVAS"}var nM=/([&<>"'])/g,iM={"&":"&","<":"<",">":">",'"':""","'":"'"};function Et(n){return n==null?"":(n+"").replace(nM,function(e,t){return iM[t]})}var rM=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,dh=[],oM=_e.browser.firefox&&+_e.browser.version.split(".")[0]<39;function fh(n,e,t,i){return t=t||{},i?dg(n,e,t):oM&&e.layerX!=null&&e.layerX!==e.offsetX?(t.zrX=e.layerX,t.zrY=e.layerY):e.offsetX!=null?(t.zrX=e.offsetX,t.zrY=e.offsetY):dg(n,e,t),t}function dg(n,e,t){if(_e.domSupported&&n.getBoundingClientRect){var i=e.clientX,r=e.clientY;if(pg(n)){var o=n.getBoundingClientRect();return t.zrX=i-o.left,void(t.zrY=r-o.top)}if(ph(dh,n,i,r))return t.zrX=dh[0],void(t.zrY=dh[1])}t.zrX=t.zrY=0}function gh(n){return n||window.event}function Xt(n,e,t){if((e=gh(e)).zrX!=null)return e;var i=e.type;if(i&&i.indexOf("touch")>=0){var r=i!=="touchend"?e.targetTouches[0]:e.changedTouches[0];r&&fh(n,r,e,t)}else{fh(n,e,e,t);var o=function(s){var l=s.wheelDelta;if(l)return l;var u=s.deltaX,h=s.deltaY;return u==null||h==null?l:3*Math.abs(h!==0?h:u)*(h>0?-1:h<0?1:u>0?-1:1)}(e);e.zrDelta=o?o/120:-(e.detail||0)/3}var a=e.button;return e.which==null&&a!==void 0&&rM.test(e.type)&&(e.which=1&a?1:2&a?3:4&a?2:0),e}function vh(n,e,t,i){n.addEventListener(e,t,i)}var Fi=function(n){n.preventDefault(),n.stopPropagation(),n.cancelBubble=!0};function fg(n){return n.which===2||n.which===3}var aM=function(){function n(){this._track=[]}return n.prototype.recognize=function(e,t,i){return this._doTrack(e,t,i),this._recognize(e)},n.prototype.clear=function(){return this._track.length=0,this},n.prototype._doTrack=function(e,t,i){var r=e.touches;if(r){for(var o={points:[],touches:[],target:t,event:e},a=0,s=r.length;a1&&r&&r.length>1){var a=gg(r)/gg(o);!isFinite(a)&&(a=1),e.pinchScale=a;var s=[((i=r)[0][0]+i[1][0])/2,(i[0][1]+i[1][1])/2];return e.pinchX=s[0],e.pinchY=s[1],{type:"pinch",target:n[0].target,event:e}}}}};function sM(){return[1,0,0,1,0,0]}function Vo(n){return n[0]=1,n[1]=0,n[2]=0,n[3]=1,n[4]=0,n[5]=0,n}function ys(n,e){return n[0]=e[0],n[1]=e[1],n[2]=e[2],n[3]=e[3],n[4]=e[4],n[5]=e[5],n}function In(n,e,t){var i=e[0]*t[0]+e[2]*t[1],r=e[1]*t[0]+e[3]*t[1],o=e[0]*t[2]+e[2]*t[3],a=e[1]*t[2]+e[3]*t[3],s=e[0]*t[4]+e[2]*t[5]+e[4],l=e[1]*t[4]+e[3]*t[5]+e[5];return n[0]=i,n[1]=r,n[2]=o,n[3]=a,n[4]=s,n[5]=l,n}function Gi(n,e,t){return n[0]=e[0],n[1]=e[1],n[2]=e[2],n[3]=e[3],n[4]=e[4]+t[0],n[5]=e[5]+t[1],n}function Hi(n,e,t,i){i===void 0&&(i=[0,0]);var r=e[0],o=e[2],a=e[4],s=e[1],l=e[3],u=e[5],h=Math.sin(t),c=Math.cos(t);return n[0]=r*c+s*h,n[1]=-r*h+s*c,n[2]=o*c+l*h,n[3]=-o*h+c*l,n[4]=c*(a-i[0])+h*(u-i[1])+i[0],n[5]=c*(u-i[1])-h*(a-i[0])+i[1],n}function mh(n,e,t){var i=t[0],r=t[1];return n[0]=e[0]*i,n[1]=e[1]*r,n[2]=e[2]*i,n[3]=e[3]*r,n[4]=e[4]*i,n[5]=e[5]*r,n}function Wi(n,e){var t=e[0],i=e[2],r=e[4],o=e[1],a=e[3],s=e[5],l=t*a-o*i;return l?(l=1/l,n[0]=a*l,n[1]=-o*l,n[2]=-i*l,n[3]=t*l,n[4]=(i*s-a*r)*l,n[5]=(o*r-t*s)*l,n):null}const lM=Object.freeze(Object.defineProperty({__proto__:null,clone:function(n){var e=[1,0,0,1,0,0];return ys(e,n),e},copy:ys,create:sM,identity:Vo,invert:Wi,mul:In,rotate:Hi,scale:mh,translate:Gi},Symbol.toStringTag,{value:"Module"}));var uM=function(){function n(e,t){this.x=e||0,this.y=t||0}return n.prototype.copy=function(e){return this.x=e.x,this.y=e.y,this},n.prototype.clone=function(){return new n(this.x,this.y)},n.prototype.set=function(e,t){return this.x=e,this.y=t,this},n.prototype.equal=function(e){return e.x===this.x&&e.y===this.y},n.prototype.add=function(e){return this.x+=e.x,this.y+=e.y,this},n.prototype.scale=function(e){this.x*=e,this.y*=e},n.prototype.scaleAndAdd=function(e,t){this.x+=e.x*t,this.y+=e.y*t},n.prototype.sub=function(e){return this.x-=e.x,this.y-=e.y,this},n.prototype.dot=function(e){return this.x*e.x+this.y*e.y},n.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},n.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},n.prototype.normalize=function(){var e=this.len();return this.x/=e,this.y/=e,this},n.prototype.distance=function(e){var t=this.x-e.x,i=this.y-e.y;return Math.sqrt(t*t+i*i)},n.prototype.distanceSquare=function(e){var t=this.x-e.x,i=this.y-e.y;return t*t+i*i},n.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},n.prototype.transform=function(e){if(e){var t=this.x,i=this.y;return this.x=e[0]*t+e[2]*i+e[4],this.y=e[1]*t+e[3]*i+e[5],this}},n.prototype.toArray=function(e){return e[0]=this.x,e[1]=this.y,e},n.prototype.fromArray=function(e){this.x=e[0],this.y=e[1]},n.set=function(e,t,i){e.x=t,e.y=i},n.copy=function(e,t){e.x=t.x,e.y=t.y},n.len=function(e){return Math.sqrt(e.x*e.x+e.y*e.y)},n.lenSquare=function(e){return e.x*e.x+e.y*e.y},n.dot=function(e,t){return e.x*t.x+e.y*t.y},n.add=function(e,t,i){e.x=t.x+i.x,e.y=t.y+i.y},n.sub=function(e,t,i){e.x=t.x-i.x,e.y=t.y-i.y},n.scale=function(e,t,i){e.x=t.x*i,e.y=t.y*i},n.scaleAndAdd=function(e,t,i,r){e.x=t.x+i.x*r,e.y=t.y+i.y*r},n.lerp=function(e,t,i,r){var o=1-r;e.x=o*t.x+r*i.x,e.y=o*t.y+r*i.y},n}();const fe=uM;var ms=Math.min,xs=Math.max,Yi=new fe,Ui=new fe,Xi=new fe,ji=new fe,Fo=new fe,Go=new fe,hM=function(){function n(e,t,i,r){i<0&&(e+=i,i=-i),r<0&&(t+=r,r=-r),this.x=e,this.y=t,this.width=i,this.height=r}return n.prototype.union=function(e){var t=ms(e.x,this.x),i=ms(e.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=xs(e.x+e.width,this.x+this.width)-t:this.width=e.width,isFinite(this.y)&&isFinite(this.height)?this.height=xs(e.y+e.height,this.y+this.height)-i:this.height=e.height,this.x=t,this.y=i},n.prototype.applyTransform=function(e){n.applyTransform(this,this,e)},n.prototype.calculateTransform=function(e){var t=this,i=e.width/t.width,r=e.height/t.height,o=[1,0,0,1,0,0];return Gi(o,o,[-t.x,-t.y]),mh(o,o,[i,r]),Gi(o,o,[e.x,e.y]),o},n.prototype.intersect=function(e,t){if(!e)return!1;e instanceof n||(e=n.create(e));var i=this,r=i.x,o=i.x+i.width,a=i.y,s=i.y+i.height,l=e.x,u=e.x+e.width,h=e.y,c=e.y+e.height,p=!(of&&(f=x,gf&&(f=_,y=i.x&&e<=i.x+i.width&&t>=i.y&&t<=i.y+i.height},n.prototype.clone=function(){return new n(this.x,this.y,this.width,this.height)},n.prototype.copy=function(e){n.copy(this,e)},n.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},n.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},n.prototype.isZero=function(){return this.width===0||this.height===0},n.create=function(e){return new n(e.x,e.y,e.width,e.height)},n.copy=function(e,t){e.x=t.x,e.y=t.y,e.width=t.width,e.height=t.height},n.applyTransform=function(e,t,i){if(i){if(i[1]<1e-5&&i[1]>-1e-5&&i[2]<1e-5&&i[2]>-1e-5){var r=i[0],o=i[3],a=i[4],s=i[5];return e.x=t.x*r+a,e.y=t.y*o+s,e.width=t.width*r,e.height=t.height*o,e.width<0&&(e.x+=e.width,e.width=-e.width),void(e.height<0&&(e.y+=e.height,e.height=-e.height))}Yi.x=Xi.x=t.x,Yi.y=ji.y=t.y,Ui.x=ji.x=t.x+t.width,Ui.y=Xi.y=t.y+t.height,Yi.transform(i),ji.transform(i),Ui.transform(i),Xi.transform(i),e.x=ms(Yi.x,Ui.x,Xi.x,ji.x),e.y=ms(Yi.y,Ui.y,Xi.y,ji.y);var l=xs(Yi.x,Ui.x,Xi.x,ji.x),u=xs(Yi.y,Ui.y,Xi.y,ji.y);e.width=l-e.x,e.height=u-e.y}else e!==t&&n.copy(e,t)},n}();const ve=hM;var vg="silent";function cM(){Fi(this.event)}var pM=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.handler=null,t}return V(e,n),e.prototype.dispose=function(){},e.prototype.setCursor=function(){},e}(Ut),Ho=function(n,e){this.x=n,this.y=e},dM=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],xh=new ve(0,0,0,0),yg=function(n){function e(t,i,r,o,a){var s=n.call(this)||this;return s._hovered=new Ho(0,0),s.storage=t,s.painter=i,s.painterRoot=o,s._pointerSize=a,r=r||new pM,s.proxy=null,s.setHandlerProxy(r),s._draggingMgr=new QS(s),s}return V(e,n),e.prototype.setHandlerProxy=function(t){this.proxy&&this.proxy.dispose(),t&&(A(dM,function(i){t.on&&t.on(i,this[i],this)},this),t.handler=this),this.proxy=t},e.prototype.mousemove=function(t){var i=t.zrX,r=t.zrY,o=xg(this,i,r),a=this._hovered,s=a.target;s&&!s.__zr&&(s=(a=this.findHover(a.x,a.y)).target);var l=this._hovered=o?new Ho(i,r):this.findHover(i,r),u=l.target,h=this.proxy;h.setCursor&&h.setCursor(u?u.cursor:"default"),s&&u!==s&&this.dispatchToElement(a,"mouseout",t),this.dispatchToElement(l,"mousemove",t),u&&u!==s&&this.dispatchToElement(l,"mouseover",t)},e.prototype.mouseout=function(t){var i=t.zrEventControl;i!=="only_globalout"&&this.dispatchToElement(this._hovered,"mouseout",t),i!=="no_globalout"&&this.trigger("globalout",{type:"globalout",event:t})},e.prototype.resize=function(){this._hovered=new Ho(0,0)},e.prototype.dispatch=function(t,i){var r=this[t];r&&r.call(this,i)},e.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},e.prototype.setCursorStyle=function(t){var i=this.proxy;i.setCursor&&i.setCursor(t)},e.prototype.dispatchToElement=function(t,i,r){var o=(t=t||{}).target;if(!o||!o.silent){for(var a="on"+i,s=function(l,u,h){return{type:l,event:h,target:u.target,topTarget:u.topTarget,cancelBubble:!1,offsetX:h.zrX,offsetY:h.zrY,gestureEvent:h.gestureEvent,pinchX:h.pinchX,pinchY:h.pinchY,pinchScale:h.pinchScale,wheelDelta:h.zrDelta,zrByTouch:h.zrByTouch,which:h.which,stop:cM}}(i,t,r);o&&(o[a]&&(s.cancelBubble=!!o[a].call(o,s)),o.trigger(i,s),o=o.__hostTarget?o.__hostTarget:o.parent,!s.cancelBubble););s.cancelBubble||(this.trigger(i,s),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(l){typeof l[a]=="function"&&l[a].call(l,s),l.trigger&&l.trigger(i,s)}))}},e.prototype.findHover=function(t,i,r){var o=this.storage.getDisplayList(),a=new Ho(t,i);if(mg(o,a,t,i,r),this._pointerSize&&!a.target){for(var s=[],l=this._pointerSize,u=l/2,h=new ve(t-u,i-u,l,l),c=o.length-1;c>=0;c--){var p=o[c];p===r||p.ignore||p.ignoreCoarsePointer||p.parent&&p.parent.ignoreCoarsePointer||(xh.copy(p.getBoundingRect()),p.transform&&xh.applyTransform(p.transform),xh.intersect(h)&&s.push(p))}if(s.length){for(var d=Math.PI/12,f=2*Math.PI,g=0;g=0;o--){var a=n[o],s=void 0;if(a!==r&&!a.ignore&&(s=fM(a,t,i))&&(!e.topTarget&&(e.topTarget=a),s!==vg)){e.target=a;break}}}function xg(n,e,t){var i=n.painter;return e<0||e>i.getWidth()||t<0||t>i.getHeight()}A(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(n){yg.prototype[n]=function(e){var t,i,r=e.zrX,o=e.zrY,a=xg(this,r,o);if(n==="mouseup"&&a||(i=(t=this.findHover(r,o)).target),n==="mousedown")this._downEl=i,this._downPoint=[e.zrX,e.zrY],this._upEl=i;else if(n==="mouseup")this._upEl=i;else if(n==="click"){if(this._downEl!==this._upEl||!this._downPoint||gs(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(t,n,e)}});const gM=yg;var _g=32,Wo=7;function wg(n,e,t,i){var r=e+1;if(r===t)return 1;if(i(n[r++],n[e])<0){for(;r=0;)r++;return r-e}function bg(n,e,t,i,r){for(i===e&&i++;i>>1])<0?l=o:s=o+1;var u=i-s;switch(u){case 3:n[s+3]=n[s+2];case 2:n[s+2]=n[s+1];case 1:n[s+1]=n[s];break;default:for(;u>0;)n[s+u]=n[s+u-1],u--}n[s]=a}}function _h(n,e,t,i,r,o){var a=0,s=0,l=1;if(o(n,e[t+r])>0){for(s=i-r;l0;)a=l,(l=1+(l<<1))<=0&&(l=s);l>s&&(l=s),a+=r,l+=r}else{for(s=r+1;ls&&(l=s);var u=a;a=r-l,l=r-u}for(a++;a>>1);o(n,e[t+h])>0?a=h+1:l=h}return l}function wh(n,e,t,i,r,o){var a=0,s=0,l=1;if(o(n,e[t+r])<0){for(s=r+1;ls&&(l=s);var u=a;a=r-l,l=r-u}else{for(s=i-r;l=0;)a=l,(l=1+(l<<1))<=0&&(l=s);l>s&&(l=s),a+=r,l+=r}for(a++;a>>1);o(n,e[t+h])<0?l=h:a=h+1}return l}function vM(n,e){var t,i,r=Wo,o=0,a=[];function s(l){var u=t[l],h=i[l],c=t[l+1],p=i[l+1];i[l]=h+p,l===o-3&&(t[l+1]=t[l+2],i[l+1]=i[l+2]),o--;var d=wh(n[c],n,u,h,0,e);u+=d,(h-=d)!==0&&(p=_h(n[u+h-1],n,c,p,p-1,e))!==0&&(h<=p?function(f,g,v,y){var m=0;for(m=0;m=Wo||S>=Wo);if(M)break;T<0&&(T=0),T+=2}if((r=T)<1&&(r=1),g===1){for(m=0;m=0;m--)n[S+m]=n[b+m];return void(n[w]=a[_])}for(var M=r;;){var T=0,C=0,I=!1;do if(e(a[_],n[x])<0){if(n[w--]=n[x--],T++,C=0,--g==0){I=!0;break}}else if(n[w--]=a[_--],C++,T=0,--y==1){I=!0;break}while((T|C)=0;m--)n[S+m]=n[b+m];if(g===0){I=!0;break}}if(n[w--]=a[_--],--y==1){I=!0;break}if((C=y-_h(n[x],a,0,y,y-1,e))!==0){for(y-=C,S=(w-=C)+1,b=(_-=C)+1,m=0;m=Wo||C>=Wo);if(I)break;M<0&&(M=0),M+=2}if((r=M)<1&&(r=1),y===1){for(S=(w-=g)+1,b=(x-=g)+1,m=g-1;m>=0;m--)n[S+m]=n[b+m];n[w]=a[_]}else{if(y===0)throw new Error;for(b=w-(y-1),m=0;m1;){var l=o-2;if(l>=1&&i[l-1]<=i[l]+i[l+1]||l>=2&&i[l-2]<=i[l]+i[l-1])i[l-1]i[l+1])break;s(l)}},forceMergeRuns:function(){for(;o>1;){var l=o-2;l>0&&i[l-1]=_g;)h|=1&u,u>>=1;return u+h}(r);do{if((o=wg(n,t,i,e))s&&(l=s),bg(n,t,t+l,t+o,e),o=l}a.pushRun(t,o),a.mergeRuns(),r-=o,t+=o}while(r!==0);a.forceMergeRuns()}}}var Nt=1,Br=4,Sg=!1;function bh(){Sg||(Sg=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function Mg(n,e){return n.zlevel===e.zlevel?n.z===e.z?n.z2-e.z2:n.z-e.z:n.zlevel-e.zlevel}var yM=function(){function n(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=Mg}return n.prototype.traverse=function(e,t){for(var i=0;i0&&(h.__clipPaths=[]),isNaN(h.z)&&(bh(),h.z=0),isNaN(h.z2)&&(bh(),h.z2=0),isNaN(h.zlevel)&&(bh(),h.zlevel=0),this._displayList[this._displayListLen++]=h}var c=e.getDecalElement&&e.getDecalElement();c&&this._updateAndAddDisplayable(c,t,i);var p=e.getTextGuideLine();p&&this._updateAndAddDisplayable(p,t,i);var d=e.getTextContent();d&&this._updateAndAddDisplayable(d,t,i)}},n.prototype.addRoot=function(e){e.__zr&&e.__zr.storage===this||this._roots.push(e)},n.prototype.delRoot=function(e){if(e instanceof Array)for(var t=0,i=e.length;t=0&&this._roots.splice(r,1)}},n.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},n.prototype.getRoots=function(){return this._roots},n.prototype.dispose=function(){this._displayList=null,this._roots=null},n}();const mM=yM,Sh=_e.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(n){return setTimeout(n,16)};var ws={linear:function(n){return n},quadraticIn:function(n){return n*n},quadraticOut:function(n){return n*(2-n)},quadraticInOut:function(n){return(n*=2)<1?.5*n*n:-.5*(--n*(n-2)-1)},cubicIn:function(n){return n*n*n},cubicOut:function(n){return--n*n*n+1},cubicInOut:function(n){return(n*=2)<1?.5*n*n*n:.5*((n-=2)*n*n+2)},quarticIn:function(n){return n*n*n*n},quarticOut:function(n){return 1- --n*n*n*n},quarticInOut:function(n){return(n*=2)<1?.5*n*n*n*n:-.5*((n-=2)*n*n*n-2)},quinticIn:function(n){return n*n*n*n*n},quinticOut:function(n){return--n*n*n*n*n+1},quinticInOut:function(n){return(n*=2)<1?.5*n*n*n*n*n:.5*((n-=2)*n*n*n*n+2)},sinusoidalIn:function(n){return 1-Math.cos(n*Math.PI/2)},sinusoidalOut:function(n){return Math.sin(n*Math.PI/2)},sinusoidalInOut:function(n){return .5*(1-Math.cos(Math.PI*n))},exponentialIn:function(n){return n===0?0:Math.pow(1024,n-1)},exponentialOut:function(n){return n===1?1:1-Math.pow(2,-10*n)},exponentialInOut:function(n){return n===0?0:n===1?1:(n*=2)<1?.5*Math.pow(1024,n-1):.5*(2-Math.pow(2,-10*(n-1)))},circularIn:function(n){return 1-Math.sqrt(1-n*n)},circularOut:function(n){return Math.sqrt(1- --n*n)},circularInOut:function(n){return(n*=2)<1?-.5*(Math.sqrt(1-n*n)-1):.5*(Math.sqrt(1-(n-=2)*n)+1)},elasticIn:function(n){var e,t=.1;return n===0?0:n===1?1:(!t||t<1?(t=1,e=.1):e=.4*Math.asin(1/t)/(2*Math.PI),-t*Math.pow(2,10*(n-=1))*Math.sin((n-e)*(2*Math.PI)/.4))},elasticOut:function(n){var e,t=.1;return n===0?0:n===1?1:(!t||t<1?(t=1,e=.1):e=.4*Math.asin(1/t)/(2*Math.PI),t*Math.pow(2,-10*n)*Math.sin((n-e)*(2*Math.PI)/.4)+1)},elasticInOut:function(n){var e,t=.1,i=.4;return n===0?0:n===1?1:(!t||t<1?(t=1,e=.1):e=i*Math.asin(1/t)/(2*Math.PI),(n*=2)<1?t*Math.pow(2,10*(n-=1))*Math.sin((n-e)*(2*Math.PI)/i)*-.5:t*Math.pow(2,-10*(n-=1))*Math.sin((n-e)*(2*Math.PI)/i)*.5+1)},backIn:function(n){var e=1.70158;return n*n*((e+1)*n-e)},backOut:function(n){var e=1.70158;return--n*n*((e+1)*n+e)+1},backInOut:function(n){var e=2.5949095;return(n*=2)<1?n*n*((e+1)*n-e)*.5:.5*((n-=2)*n*((e+1)*n+e)+2)},bounceIn:function(n){return 1-ws.bounceOut(1-n)},bounceOut:function(n){return n<1/2.75?7.5625*n*n:n<2/2.75?7.5625*(n-=1.5/2.75)*n+.75:n<2.5/2.75?7.5625*(n-=2.25/2.75)*n+.9375:7.5625*(n-=2.625/2.75)*n+.984375},bounceInOut:function(n){return n<.5?.5*ws.bounceIn(2*n):.5*ws.bounceOut(2*n-1)+.5}};const Tg=ws;var bs=Math.pow,fi=Math.sqrt,Ss=1e-8,Cg=1e-4,Ig=fi(3),Ms=1/3,An=Bi(),jt=Bi(),Vr=Bi();function gi(n){return n>-Ss&&nSs||n<-Ss}function tt(n,e,t,i,r){var o=1-r;return o*o*(o*n+3*r*e)+r*r*(r*i+3*o*t)}function Dg(n,e,t,i,r){var o=1-r;return 3*(((e-n)*o+2*(t-e)*r)*o+(i-t)*r*r)}function Ts(n,e,t,i,r,o){var a=i+3*(e-t)-n,s=3*(t-2*e+n),l=3*(e-n),u=n-r,h=s*s-3*a*l,c=s*l-9*a*u,p=l*l-3*s*u,d=0;if(gi(h)&&gi(c))gi(s)?o[0]=0:(M=-l/s)>=0&&M<=1&&(o[d++]=M);else{var f=c*c-4*h*p;if(gi(f)){var g=c/h,v=-g/2;(M=-s/a+g)>=0&&M<=1&&(o[d++]=M),v>=0&&v<=1&&(o[d++]=v)}else if(f>0){var y=fi(f),m=h*s+1.5*a*(-c+y),x=h*s+1.5*a*(-c-y);(M=(-s-((m=m<0?-bs(-m,Ms):bs(m,Ms))+(x=x<0?-bs(-x,Ms):bs(x,Ms))))/(3*a))>=0&&M<=1&&(o[d++]=M)}else{var _=(2*h*s-3*a*c)/(2*fi(h*h*h)),w=Math.acos(_)/3,b=fi(h),S=Math.cos(w),M=(-s-2*b*S)/(3*a),T=(v=(-s+b*(S+Ig*Math.sin(w)))/(3*a),(-s+b*(S-Ig*Math.sin(w)))/(3*a));M>=0&&M<=1&&(o[d++]=M),v>=0&&v<=1&&(o[d++]=v),T>=0&&T<=1&&(o[d++]=T)}}return d}function kg(n,e,t,i,r){var o=6*t-12*e+6*n,a=9*e+3*i-3*n-9*t,s=3*e-3*n,l=0;if(gi(a))Ag(o)&&(h=-s/o)>=0&&h<=1&&(r[l++]=h);else{var u=o*o-4*a*s;if(gi(u))r[0]=-o/(2*a);else if(u>0){var h,c=fi(u),p=(-o-c)/(2*a);(h=(-o+c)/(2*a))>=0&&h<=1&&(r[l++]=h),p>=0&&p<=1&&(r[l++]=p)}}return l}function Cs(n,e,t,i,r,o){var a=(e-n)*r+n,s=(t-e)*r+e,l=(i-t)*r+t,u=(s-a)*r+a,h=(l-s)*r+s,c=(h-u)*r+u;o[0]=n,o[1]=a,o[2]=u,o[3]=c,o[4]=c,o[5]=h,o[6]=l,o[7]=i}function Lg(n,e,t,i,r,o,a,s,l,u,h){var c,p,d,f,g,v=.005,y=1/0;An[0]=l,An[1]=u;for(var m=0;m<1;m+=.05)jt[0]=tt(n,t,r,a,m),jt[1]=tt(e,i,o,s,m),(f=Vi(An,jt))=0&&f=0&&v=1?1:Ts(0,i,o,1,l,s)&&tt(0,r,a,1,s[0])}}}const bM=function(){function n(e){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=e.life||1e3,this._delay=e.delay||0,this.loop=e.loop||!1,this.onframe=e.onframe||ot,this.ondestroy=e.ondestroy||ot,this.onrestart=e.onrestart||ot,e.easing&&this.setEasing(e.easing)}return n.prototype.step=function(e,t){if(this._inited||(this._startTime=e+this._delay,this._inited=!0),!this._paused){var i=this._life,r=e-this._startTime-this._pausedTime,o=r/i;o<0&&(o=0),o=Math.min(o,1);var a=this.easingFunc,s=a?a(o):o;if(this.onframe(s),o===1){if(!this.loop)return!0;var l=r%i;this._startTime=e-l,this._pausedTime=0,this.onrestart()}return!1}this._pausedTime+=t},n.prototype.pause=function(){this._paused=!0},n.prototype.resume=function(){this._paused=!1},n.prototype.setEasing=function(e){this.easing=e,this.easingFunc=re(e)?e:Tg[e]||Eg(e)},n}();var Ng=function(n){this.value=n},SM=function(){function n(){this._len=0}return n.prototype.insert=function(e){var t=new Ng(e);return this.insertEntry(t),t},n.prototype.insertEntry=function(e){this.head?(this.tail.next=e,e.prev=this.tail,e.next=null,this.tail=e):this.head=this.tail=e,this._len++},n.prototype.remove=function(e){var t=e.prev,i=e.next;t?t.next=i:this.head=i,i?i.prev=t:this.tail=t,e.next=e.prev=null,this._len--},n.prototype.len=function(){return this._len},n.prototype.clear=function(){this.head=this.tail=null,this._len=0},n}(),MM=function(){function n(e){this._list=new SM,this._maxSize=10,this._map={},this._maxSize=e}return n.prototype.put=function(e,t){var i=this._list,r=this._map,o=null;if(r[e]==null){var a=i.len(),s=this._lastRemovedEntry;if(a>=this._maxSize&&a>0){var l=i.head;i.remove(l),delete r[l.key],o=l.value,this._lastRemovedEntry=l}s?s.value=t:s=new Ng(t),s.key=e,i.insertEntry(s),r[e]=s}return o},n.prototype.get=function(e){var t=this._map[e],i=this._list;if(t!=null)return t!==i.tail&&(i.remove(t),i.insertEntry(t)),t.value},n.prototype.clear=function(){this._list.clear(),this._map={}},n.prototype.len=function(){return this._list.len()},n}();const Yo=MM;var zg={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function dn(n){return(n=Math.round(n))<0?0:n>255?255:n}function Uo(n){return n<0?0:n>1?1:n}function Mh(n){var e=n;return e.length&&e.charAt(e.length-1)==="%"?dn(parseFloat(e)/100*255):dn(parseInt(e,10))}function Zi(n){var e=n;return e.length&&e.charAt(e.length-1)==="%"?Uo(parseFloat(e)/100):Uo(parseFloat(e))}function Th(n,e,t){return t<0?t+=1:t>1&&(t-=1),6*t<1?n+(e-n)*t*6:2*t<1?e:3*t<2?n+(e-n)*(2/3-t)*6:n}function vi(n,e,t){return n+(e-n)*t}function Zt(n,e,t,i,r){return n[0]=e,n[1]=t,n[2]=i,n[3]=r,n}function Ch(n,e){return n[0]=e[0],n[1]=e[1],n[2]=e[2],n[3]=e[3],n}var Bg=new Yo(20),As=null;function Fr(n,e){As&&Ch(As,e),As=Bg.put(n,As||e.slice())}function Ct(n,e){if(n){e=e||[];var t=Bg.get(n);if(t)return Ch(e,t);var i=(n+="").replace(/ /g,"").toLowerCase();if(i in zg)return Ch(e,zg[i]),Fr(n,e),e;var r,o=i.length;if(i.charAt(0)==="#")return o===4||o===5?(r=parseInt(i.slice(1,4),16))>=0&&r<=4095?(Zt(e,(3840&r)>>4|(3840&r)>>8,240&r|(240&r)>>4,15&r|(15&r)<<4,o===5?parseInt(i.slice(4),16)/15:1),Fr(n,e),e):void Zt(e,0,0,0,1):o===7||o===9?(r=parseInt(i.slice(1,7),16))>=0&&r<=16777215?(Zt(e,(16711680&r)>>16,(65280&r)>>8,255&r,o===9?parseInt(i.slice(7),16)/255:1),Fr(n,e),e):void Zt(e,0,0,0,1):void 0;var a=i.indexOf("("),s=i.indexOf(")");if(a!==-1&&s+1===o){var l=i.substr(0,a),u=i.substr(a+1,s-(a+1)).split(","),h=1;switch(l){case"rgba":if(u.length!==4)return u.length===3?Zt(e,+u[0],+u[1],+u[2],1):Zt(e,0,0,0,1);h=Zi(u.pop());case"rgb":return u.length>=3?(Zt(e,Mh(u[0]),Mh(u[1]),Mh(u[2]),u.length===3?h:Zi(u[3])),Fr(n,e),e):void Zt(e,0,0,0,1);case"hsla":return u.length!==4?void Zt(e,0,0,0,1):(u[3]=Zi(u[3]),Ih(u,e),Fr(n,e),e);case"hsl":return u.length!==3?void Zt(e,0,0,0,1):(Ih(u,e),Fr(n,e),e);default:return}}Zt(e,0,0,0,1)}}function Ih(n,e){var t=(parseFloat(n[0])%360+360)%360/360,i=Zi(n[1]),r=Zi(n[2]),o=r<=.5?r*(i+1):r+i-r*i,a=2*r-o;return Zt(e=e||[],dn(255*Th(a,o,t+1/3)),dn(255*Th(a,o,t)),dn(255*Th(a,o,t-1/3)),1),n.length===4&&(e[3]=n[3]),e}function Ah(n,e){var t=Ct(n);if(t){for(var i=0;i<3;i++)t[i]=e<0?t[i]*(1-e)|0:(255-t[i])*e+t[i]|0,t[i]>255?t[i]=255:t[i]<0&&(t[i]=0);return fn(t,t.length===4?"rgba":"rgb")}}function Xo(n,e,t){if(e&&e.length&&n>=0&&n<=1){t=t||[];var i=n*(e.length-1),r=Math.floor(i),o=Math.ceil(i),a=e[r],s=e[o],l=i-r;return t[0]=dn(vi(a[0],s[0],l)),t[1]=dn(vi(a[1],s[1],l)),t[2]=dn(vi(a[2],s[2],l)),t[3]=Uo(vi(a[3],s[3],l)),t}}var TM=Xo;function Dh(n,e,t){if(e&&e.length&&n>=0&&n<=1){var i=n*(e.length-1),r=Math.floor(i),o=Math.ceil(i),a=Ct(e[r]),s=Ct(e[o]),l=i-r,u=fn([dn(vi(a[0],s[0],l)),dn(vi(a[1],s[1],l)),dn(vi(a[2],s[2],l)),Uo(vi(a[3],s[3],l))],"rgba");return t?{color:u,leftIndex:r,rightIndex:o,value:i}:u}}var CM=Dh;function Ds(n,e,t,i){var r=Ct(n);if(n)return r=function(o){if(o){var a,s,l=o[0]/255,u=o[1]/255,h=o[2]/255,c=Math.min(l,u,h),p=Math.max(l,u,h),d=p-c,f=(p+c)/2;if(d===0)a=0,s=0;else{s=f<.5?d/(p+c):d/(2-p-c);var g=((p-l)/6+d/2)/d,v=((p-u)/6+d/2)/d,y=((p-h)/6+d/2)/d;l===p?a=y-v:u===p?a=1/3+g-y:h===p&&(a=2/3+v-g),a<0&&(a+=1),a>1&&(a-=1)}var m=[360*a,s,f];return o[3]!=null&&m.push(o[3]),m}}(r),e!=null&&(r[0]=function(o){return(o=Math.round(o))<0?0:o>360?360:o}(e)),t!=null&&(r[1]=Zi(t)),i!=null&&(r[2]=Zi(i)),fn(Ih(r),"rgba")}function Vg(n,e){var t=Ct(n);if(t&&e!=null)return t[3]=Uo(e),fn(t,"rgba")}function fn(n,e){if(n&&n.length){var t=n[0]+","+n[1]+","+n[2];return e!=="rgba"&&e!=="hsva"&&e!=="hsla"||(t+=","+n[3]),e+"("+t+")"}}function jo(n,e){var t=Ct(n);return t?(.299*t[0]+.587*t[1]+.114*t[2])*t[3]/255+(1-t[3])*e:0}var Fg=new Yo(100);function kh(n){if(j(n)){var e=Fg.get(n);return e||(e=Ah(n,-.1),Fg.put(n,e)),e}if(No(n)){var t=G({},n);return t.colorStops=U(n.colorStops,function(i){return{offset:i.offset,color:Ah(i.color,-.1)}}),t}return n}const IM=Object.freeze(Object.defineProperty({__proto__:null,fastLerp:Xo,fastMapToColor:TM,lerp:Dh,lift:Ah,liftColor:kh,lum:jo,mapToColor:CM,modifyAlpha:Vg,modifyHSL:Ds,parse:Ct,random:function(){return fn([Math.round(255*Math.random()),Math.round(255*Math.random()),Math.round(255*Math.random())],"rgb")},stringify:fn,toHex:function(n){var e=Ct(n);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)}},Symbol.toStringTag,{value:"Module"}));_e.hasGlobalWindow&&re(window.btoa);var Lh=Array.prototype.slice;function jn(n,e,t){return(e-n)*t+n}function Ph(n,e,t,i){for(var r=e.length,o=0;oi?e:n,o=Math.min(t,i),a=r[o-1]||{color:[0,0,0,0],offset:0},s=o;sa)i.length=a;else for(var s=o;s=1},n.prototype.getAdditiveTrack=function(){return this._additiveTrack},n.prototype.addKeyframe=function(e,t,i){this._needsSort=!0;var r=this.keyframes,o=r.length,a=!1,s=6,l=t;if(yt(t)){var u=function(d){return yt(d&&d[0])?2:1}(t);s=u,(u===1&&!Le(t[0])||u===2&&!Le(t[0][0]))&&(a=!0)}else if(Le(t)&&!Er(t))s=0;else if(j(t))if(isNaN(+t)){var h=Ct(t);h&&(l=h,s=3)}else s=0;else if(No(t)){var c=G({},l);c.colorStops=U(t.colorStops,function(d){return{offset:d.offset,color:Ct(d.color)}}),t.type==="linear"?s=4:function(d){return d.type==="radial"}(t)&&(s=5),l=c}o===0?this.valType=s:s===this.valType&&s!==6||(a=!0),this.discrete=this.discrete||a;var p={time:e,value:l,rawValue:t,percent:0};return i&&(p.easing=i,p.easingFunc=re(i)?i:Tg[i]||Eg(i)),r.push(p),p},n.prototype.prepare=function(e,t){var i=this.keyframes;this._needsSort&&i.sort(function(g,v){return g.time-v.time});for(var r=this.valType,o=i.length,a=i[o-1],s=this.discrete,l=Os(r),u=Hg(r),h=0;h=0&&!(u[i].percent<=t);i--);i=f(i,h-2)}else{for(i=d;it);i++);i=f(i-1,h-2)}o=u[i+1],r=u[i]}if(r&&o){this._lastFr=i,this._lastFrP=t;var g=o.percent-r.percent,v=g===0?1:f((t-r.percent)/g,1);o.easingFunc&&(v=o.easingFunc(v));var y=a?this._additiveValue:p?Zo:e[c];if(!Os(l)&&!p||y||(y=this._additiveValue=[]),this.discrete)e[c]=v<1?r.rawValue:o.rawValue;else if(Os(l))l===1?Ph(y,r[s],o[s],v):function(b,S,M,T){for(var C=S.length,I=C&&S[0].length,D=0;D0&&l.addKeyframe(0,Ls(u),r),this._trackKeys.push(s)}l.addKeyframe(e,Ls(t[s]),r)}return this._maxTime=Math.max(this._maxTime,e),this},n.prototype.pause=function(){this._clip.pause(),this._paused=!0},n.prototype.resume=function(){this._clip.resume(),this._paused=!1},n.prototype.isPaused=function(){return!!this._paused},n.prototype.duration=function(e){return this._maxTime=e,this._force=!0,this},n.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var e=this._doneCbs;if(e)for(var t=e.length,i=0;i0)){this._started=1;for(var t=this,i=[],r=this._maxTime||0,o=0;o1){var s=a.pop();o.addKeyframe(s.time,e[r]),o.prepare(this._maxTime,o.getAdditiveTrack())}}}},n}();const Oh=LM;function Gr(){return new Date().getTime()}var PM=function(n){function e(t){var i=n.call(this)||this;return i._running=!1,i._time=0,i._pausedTime=0,i._pauseStart=0,i._paused=!1,t=t||{},i.stage=t.stage||{},i}return V(e,n),e.prototype.addClip=function(t){t.animation&&this.removeClip(t),this._head?(this._tail.next=t,t.prev=this._tail,t.next=null,this._tail=t):this._head=this._tail=t,t.animation=this},e.prototype.addAnimator=function(t){t.animation=this;var i=t.getClip();i&&this.addClip(i)},e.prototype.removeClip=function(t){if(t.animation){var i=t.prev,r=t.next;i?i.next=r:this._head=r,r?r.prev=i:this._tail=i,t.next=t.prev=t.animation=null}},e.prototype.removeAnimator=function(t){var i=t.getClip();i&&this.removeClip(i),t.animation=null},e.prototype.update=function(t){for(var i=Gr()-this._pausedTime,r=i-this._time,o=this._head;o;){var a=o.next;o.step(i,r)&&(o.ondestroy(),this.removeClip(o)),o=a}this._time=i,t||(this.trigger("frame",r),this.stage.update&&this.stage.update())},e.prototype._startLoop=function(){var t=this;this._running=!0,Sh(function i(){t._running&&(Sh(i),!t._paused&&t.update())})},e.prototype.start=function(){this._running||(this._time=Gr(),this._pausedTime=0,this._startLoop())},e.prototype.stop=function(){this._running=!1},e.prototype.pause=function(){this._paused||(this._pauseStart=Gr(),this._paused=!0)},e.prototype.resume=function(){this._paused&&(this._pausedTime+=Gr()-this._pauseStart,this._paused=!1)},e.prototype.clear=function(){for(var t=this._head;t;){var i=t.next;t.prev=t.next=t.animation=null,t=i}this._head=this._tail=null},e.prototype.isFinished=function(){return this._head==null},e.prototype.animate=function(t,i){i=i||{},this.start();var r=new Oh(t,i.loop);return this.addAnimator(r),r},e}(Ut);const OM=PM;var Wg,Yg,Rh=_e.domSupported,Eh=(Yg={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},{mouse:Wg=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],touch:["touchstart","touchend","touchmove"],pointer:U(Wg,function(n){var e=n.replace("mouse","pointer");return Yg.hasOwnProperty(e)?e:n})}),RM=["mousemove","mouseup"],EM=["pointermove","pointerup"],Ug=!1;function Nh(n){var e=n.pointerType;return e==="pen"||e==="touch"}function zh(n){n&&(n.zrByTouch=!0)}function Xg(n,e){for(var t=e,i=!1;t&&t.nodeType!==9&&!(i=t.domBelongToZr||t!==e&&t===n.painterRoot);)t=t.parentNode;return i}var NM=function(n,e){this.stopPropagation=ot,this.stopImmediatePropagation=ot,this.preventDefault=ot,this.type=e.type,this.target=this.currentTarget=n.dom,this.pointerType=e.pointerType,this.clientX=e.clientX,this.clientY=e.clientY},gn={mousedown:function(n){n=Xt(this.dom,n),this.__mayPointerCapture=[n.zrX,n.zrY],this.trigger("mousedown",n)},mousemove:function(n){n=Xt(this.dom,n);var e=this.__mayPointerCapture;!e||n.zrX===e[0]&&n.zrY===e[1]||this.__togglePointerCapture(!0),this.trigger("mousemove",n)},mouseup:function(n){n=Xt(this.dom,n),this.__togglePointerCapture(!1),this.trigger("mouseup",n)},mouseout:function(n){Xg(this,(n=Xt(this.dom,n)).toElement||n.relatedTarget)||(this.__pointerCapturing&&(n.zrEventControl="no_globalout"),this.trigger("mouseout",n))},wheel:function(n){Ug=!0,n=Xt(this.dom,n),this.trigger("mousewheel",n)},mousewheel:function(n){Ug||(n=Xt(this.dom,n),this.trigger("mousewheel",n))},touchstart:function(n){zh(n=Xt(this.dom,n)),this.__lastTouchMoment=new Date,this.handler.processGesture(n,"start"),gn.mousemove.call(this,n),gn.mousedown.call(this,n)},touchmove:function(n){zh(n=Xt(this.dom,n)),this.handler.processGesture(n,"change"),gn.mousemove.call(this,n)},touchend:function(n){zh(n=Xt(this.dom,n)),this.handler.processGesture(n,"end"),gn.mouseup.call(this,n),+new Date-+this.__lastTouchMoment<300&&gn.click.call(this,n)},pointerdown:function(n){gn.mousedown.call(this,n)},pointermove:function(n){Nh(n)||gn.mousemove.call(this,n)},pointerup:function(n){gn.mouseup.call(this,n)},pointerout:function(n){Nh(n)||gn.mouseout.call(this,n)}};A(["click","dblclick","contextmenu"],function(n){gn[n]=function(e){e=Xt(this.dom,e),this.trigger(n,e)}});var Bh={pointermove:function(n){Nh(n)||Bh.mousemove.call(this,n)},pointerup:function(n){Bh.mouseup.call(this,n)},mousemove:function(n){this.trigger("mousemove",n)},mouseup:function(n){var e=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",n),e&&(n.zrEventControl="only_globalout",this.trigger("mouseout",n))}};function zM(n,e){var t=e.domHandlers;_e.pointerEventsSupported?A(Eh.pointer,function(i){Rs(e,i,function(r){t[i].call(n,r)})}):(_e.touchEventsSupported&&A(Eh.touch,function(i){Rs(e,i,function(r){t[i].call(n,r),function(o){o.touching=!0,o.touchTimer!=null&&(clearTimeout(o.touchTimer),o.touchTimer=null),o.touchTimer=setTimeout(function(){o.touching=!1,o.touchTimer=null},700)}(e)})}),A(Eh.mouse,function(i){Rs(e,i,function(r){r=gh(r),e.touching||t[i].call(n,r)})}))}function BM(n,e){function t(i){Rs(e,i,function(r){r=gh(r),Xg(n,r.target)||(r=function(o,a){return Xt(o.dom,new NM(o,a),!0)}(n,r),e.domHandlers[i].call(n,r))},{capture:!0})}_e.pointerEventsSupported?A(EM,t):_e.touchEventsSupported||A(RM,t)}function Rs(n,e,t,i){n.mounted[e]=t,n.listenerOpts[e]=i,vh(n.domTarget,e,t,i)}function Vh(n){var e,t,i,r,o=n.mounted;for(var a in o)o.hasOwnProperty(a)&&(e=n.domTarget,t=a,i=o[a],r=n.listenerOpts[a],e.removeEventListener(t,i,r));n.mounted={}}var jg=function(n,e){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=n,this.domHandlers=e};const VM=function(n){function e(t,i){var r=n.call(this)||this;return r.__pointerCapturing=!1,r.dom=t,r.painterRoot=i,r._localHandlerScope=new jg(t,gn),Rh&&(r._globalHandlerScope=new jg(document,Bh)),zM(r,r._localHandlerScope),r}return V(e,n),e.prototype.dispose=function(){Vh(this._localHandlerScope),Rh&&Vh(this._globalHandlerScope)},e.prototype.setCursor=function(t){this.dom.style&&(this.dom.style.cursor=t||"default")},e.prototype.__togglePointerCapture=function(t){if(this.__mayPointerCapture=null,Rh&&+this.__pointerCapturing^+t){this.__pointerCapturing=t;var i=this._globalHandlerScope;t?BM(this,i):Vh(i)}},e}(Ut);var Zg=1;_e.hasGlobalWindow&&(Zg=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var Es=Zg,Fh="#333",Gh="#ccc",qg=Vo,FM=5e-5;function qi(n){return n>FM||n<-5e-5}var Ki=[],Hr=[],Hh=[1,0,0,1,0,0],Wh=Math.abs,GM=function(){function n(){}return n.prototype.getLocalTransform=function(e){return n.getLocalTransform(this,e)},n.prototype.setPosition=function(e){this.x=e[0],this.y=e[1]},n.prototype.setScale=function(e){this.scaleX=e[0],this.scaleY=e[1]},n.prototype.setSkew=function(e){this.skewX=e[0],this.skewY=e[1]},n.prototype.setOrigin=function(e){this.originX=e[0],this.originY=e[1]},n.prototype.needLocalTransform=function(){return qi(this.rotation)||qi(this.x)||qi(this.y)||qi(this.scaleX-1)||qi(this.scaleY-1)||qi(this.skewX)||qi(this.skewY)},n.prototype.updateTransform=function(){var e=this.parent&&this.parent.transform,t=this.needLocalTransform(),i=this.transform;t||e?(i=i||[1,0,0,1,0,0],t?this.getLocalTransform(i):qg(i),e&&(t?In(i,e,i):ys(i,e)),this.transform=i,this._resolveGlobalScaleRatio(i)):i&&(qg(i),this.invTransform=null)},n.prototype._resolveGlobalScaleRatio=function(e){var t=this.globalScaleRatio;if(t!=null&&t!==1){this.getGlobalScale(Ki);var i=Ki[0]<0?-1:1,r=Ki[1]<0?-1:1,o=((Ki[0]-i)*t+i)/Ki[0]||0,a=((Ki[1]-r)*t+r)/Ki[1]||0;e[0]*=o,e[1]*=o,e[2]*=a,e[3]*=a}this.invTransform=this.invTransform||[1,0,0,1,0,0],Wi(this.invTransform,e)},n.prototype.getComputedTransform=function(){for(var e=this,t=[];e;)t.push(e),e=e.parent;for(;e=t.pop();)e.updateTransform();return this.transform},n.prototype.setLocalTransform=function(e){if(e){var t=e[0]*e[0]+e[1]*e[1],i=e[2]*e[2]+e[3]*e[3],r=Math.atan2(e[1],e[0]),o=Math.PI/2+r-Math.atan2(e[3],e[2]);i=Math.sqrt(i)*Math.cos(o),t=Math.sqrt(t),this.skewX=o,this.skewY=0,this.rotation=-r,this.x=+e[4],this.y=+e[5],this.scaleX=t,this.scaleY=i,this.originX=0,this.originY=0}},n.prototype.decomposeTransform=function(){if(this.transform){var e=this.parent,t=this.transform;e&&e.transform&&(e.invTransform=e.invTransform||[1,0,0,1,0,0],In(Hr,e.invTransform,t),t=Hr);var i=this.originX,r=this.originY;(i||r)&&(Hh[4]=i,Hh[5]=r,In(Hr,t,Hh),Hr[4]-=i,Hr[5]-=r,t=Hr),this.setLocalTransform(t)}},n.prototype.getGlobalScale=function(e){var t=this.transform;return e=e||[],t?(e[0]=Math.sqrt(t[0]*t[0]+t[1]*t[1]),e[1]=Math.sqrt(t[2]*t[2]+t[3]*t[3]),t[0]<0&&(e[0]=-e[0]),t[3]<0&&(e[1]=-e[1]),e):(e[0]=1,e[1]=1,e)},n.prototype.transformCoordToLocal=function(e,t){var i=[e,t],r=this.invTransform;return r&&it(i,i,r),i},n.prototype.transformCoordToGlobal=function(e,t){var i=[e,t],r=this.transform;return r&&it(i,i,r),i},n.prototype.getLineScale=function(){var e=this.transform;return e&&Wh(e[0]-1)>1e-10&&Wh(e[3]-1)>1e-10?Math.sqrt(Wh(e[0]*e[3]-e[2]*e[1])):1},n.prototype.copyTransform=function(e){(function(t,i){for(var r=0;r=0?parseFloat(n)/100*e:parseFloat(n):n}function Ns(n,e,t){var i=e.position||"inside",r=e.distance!=null?e.distance:5,o=t.height,a=t.width,s=o/2,l=t.x,u=t.y,h="left",c="top";if(i instanceof Array)l+=Dn(i[0],t.width),u+=Dn(i[1],t.height),h=null,c=null;else switch(i){case"left":l-=r,u+=s,h="right",c="middle";break;case"right":l+=r+a,u+=s,c="middle";break;case"top":l+=a/2,u-=r,h="center",c="bottom";break;case"bottom":l+=a/2,u+=o+r,h="center";break;case"inside":l+=a/2,u+=s,h="center",c="middle";break;case"insideLeft":l+=r,u+=s,c="middle";break;case"insideRight":l+=a-r,u+=s,h="right",c="middle";break;case"insideTop":l+=a/2,u+=r,h="center";break;case"insideBottom":l+=a/2,u+=o-r,h="center",c="bottom";break;case"insideTopLeft":l+=r,u+=r;break;case"insideTopRight":l+=a-r,u+=r,h="right";break;case"insideBottomLeft":l+=r,u+=o-r,c="bottom";break;case"insideBottomRight":l+=a-r,u+=o-r,h="right",c="bottom"}return(n=n||{}).x=l,n.y=u,n.align=h,n.verticalAlign=c,n}var Uh="__zr_normal__",Xh=qo.concat(["ignore"]),HM=pn(qo,function(n,e){return n[e]=!0,n},{ignore:!1}),Yr={},WM=new ve(0,0,0,0),jh=function(){function n(e){this.id=nh(),this.animators=[],this.currentStates=[],this.states={},this._init(e)}return n.prototype._init=function(e){this.attr(e)},n.prototype.drift=function(e,t,i){switch(this.draggable){case"horizontal":t=0;break;case"vertical":e=0}var r=this.transform;r||(r=this.transform=[1,0,0,1,0,0]),r[4]+=e,r[5]+=t,this.decomposeTransform(),this.markRedraw()},n.prototype.beforeUpdate=function(){},n.prototype.afterUpdate=function(){},n.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},n.prototype.updateInnerText=function(e){var t=this._textContent;if(t&&(!t.ignore||e)){this.textConfig||(this.textConfig={});var i=this.textConfig,r=i.local,o=t.innerTransformable,a=void 0,s=void 0,l=!1;o.parent=r?this:null;var u=!1;if(o.copyTransform(t),i.position!=null){var h=WM;i.layoutRect?h.copy(i.layoutRect):h.copy(this.getBoundingRect()),r||h.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(Yr,i,h):Ns(Yr,i,h),o.x=Yr.x,o.y=Yr.y,a=Yr.align,s=Yr.verticalAlign;var c=i.origin;if(c&&i.rotation!=null){var p=void 0,d=void 0;c==="center"?(p=.5*h.width,d=.5*h.height):(p=Dn(c[0],h.width),d=Dn(c[1],h.height)),u=!0,o.originX=-o.x+p+(r?0:h.x),o.originY=-o.y+d+(r?0:h.y)}}i.rotation!=null&&(o.rotation=i.rotation);var f=i.offset;f&&(o.x+=f[0],o.y+=f[1],u||(o.originX=-f[0],o.originY=-f[1]));var g=i.inside==null?typeof i.position=="string"&&i.position.indexOf("inside")>=0:i.inside,v=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),y=void 0,m=void 0,x=void 0;g&&this.canBeInsideText()?(y=i.insideFill,m=i.insideStroke,y!=null&&y!=="auto"||(y=this.getInsideTextFill()),m!=null&&m!=="auto"||(m=this.getInsideTextStroke(y),x=!0)):(y=i.outsideFill,m=i.outsideStroke,y!=null&&y!=="auto"||(y=this.getOutsideFill()),m!=null&&m!=="auto"||(m=this.getOutsideStroke(y),x=!0)),(y=y||"#000")===v.fill&&m===v.stroke&&x===v.autoStroke&&a===v.align&&s===v.verticalAlign||(l=!0,v.fill=y,v.stroke=m,v.autoStroke=x,v.align=a,v.verticalAlign=s,t.setDefaultTextStyle(v)),t.__dirty|=Nt,l&&t.dirtyStyle(!0)}},n.prototype.canBeInsideText=function(){return!0},n.prototype.getInsideTextFill=function(){return"#fff"},n.prototype.getInsideTextStroke=function(e){return"#000"},n.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?Gh:Fh},n.prototype.getOutsideStroke=function(e){var t=this.__zr&&this.__zr.getBackgroundColor(),i=typeof t=="string"&&Ct(t);i||(i=[255,255,255,1]);for(var r=i[3],o=this.__zr.isDarkMode(),a=0;a<3;a++)i[a]=i[a]*r+(o?0:255)*(1-r);return i[3]=1,fn(i,"rgba")},n.prototype.traverse=function(e,t){},n.prototype.attrKV=function(e,t){e==="textConfig"?this.setTextConfig(t):e==="textContent"?this.setTextContent(t):e==="clipPath"?this.setClipPath(t):e==="extra"?(this.extra=this.extra||{},G(this.extra,t)):this[e]=t},n.prototype.hide=function(){this.ignore=!0,this.markRedraw()},n.prototype.show=function(){this.ignore=!1,this.markRedraw()},n.prototype.attr=function(e,t){if(typeof e=="string")this.attrKV(e,t);else if(Q(e))for(var i=Oe(e),r=0;r0},n.prototype.getState=function(e){return this.states[e]},n.prototype.ensureState=function(e){var t=this.states;return t[e]||(t[e]={}),t[e]},n.prototype.clearStates=function(e){this.useState(Uh,!1,e)},n.prototype.useState=function(e,t,i,r){var o=e===Uh;if(this.hasState()||!o){var a=this.currentStates,s=this.stateTransition;if(!(Me(a,e)>=0)||!t&&a.length!==1){var l;if(this.stateProxy&&!o&&(l=this.stateProxy(e)),l||(l=this.states&&this.states[e]),l||o){o||this.saveCurrentToNormalState(l);var u=!!(l&&l.hoverLayer||r);u&&this._toggleHoverLayerFlag(!0),this._applyStateObj(e,l,this._normalState,t,!i&&!this.__inHover&&s&&s.duration>0,s);var h=this._textContent,c=this._textGuide;return h&&h.useState(e,t,i,u),c&&c.useState(e,t,i,u),o?(this.currentStates=[],this._normalState={}):t?this.currentStates.push(e):this.currentStates=[e],this._updateAnimationTargets(),this.markRedraw(),!u&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~Nt),l}zi("State "+e+" not exists.")}}},n.prototype.useStates=function(e,t,i){if(e.length){var r=[],o=this.currentStates,a=e.length,s=a===o.length;if(s){for(var l=0;l0,f);var g=this._textContent,v=this._textGuide;g&&g.useStates(e,t,p),v&&v.useStates(e,t,p),this._updateAnimationTargets(),this.currentStates=e.slice(),this.markRedraw(),!p&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~Nt)}else this.clearStates()},n.prototype.isSilent=function(){for(var e=this.silent,t=this.parent;!e&&t;){if(t.silent){e=!0;break}t=t.parent}return e},n.prototype._updateAnimationTargets=function(){for(var e=0;e=0){var i=this.currentStates.slice();i.splice(t,1),this.useStates(i)}},n.prototype.replaceState=function(e,t,i){var r=this.currentStates.slice(),o=Me(r,e),a=Me(r,t)>=0;o>=0?a?r.splice(o,1):r[o]=t:i&&!a&&r.push(t),this.useStates(r)},n.prototype.toggleState=function(e,t){t?this.useState(e,!0):this.removeState(e)},n.prototype._mergeStates=function(e){for(var t,i={},r=0;r=0&&o.splice(a,1)}),this.animators.push(e),i&&i.animation.addAnimator(e),i&&i.wakeUp()},n.prototype.updateDuringAnimation=function(e){this.markRedraw()},n.prototype.stopAnimation=function(e,t){for(var i=this.animators,r=i.length,o=[],a=0;a0&&t.during&&o[0].during(function(f,g){t.during(g)});for(var p=0;p0||r.force&&!a.length){var b,S=void 0,M=void 0,T=void 0;if(s)for(M={},p&&(S={}),_=0;_=0&&(r.splice(o,0,t),this._doAdd(t))}return this},e.prototype.replace=function(t,i){var r=Me(this._children,t);return r>=0&&this.replaceAt(i,r),this},e.prototype.replaceAt=function(t,i){var r=this._children,o=r[i];if(t&&t!==this&&t.parent!==this&&t!==o){r[i]=t,o.parent=null;var a=this.__zr;a&&o.removeSelfFromZr(a),this._doAdd(t)}return this},e.prototype._doAdd=function(t){t.parent&&t.parent.remove(t),t.parent=this;var i=this.__zr;i&&i!==t.__zr&&t.addSelfToZr(i),i&&i.refresh()},e.prototype.remove=function(t){var i=this.__zr,r=this._children,o=Me(r,t);return o<0||(r.splice(o,1),t.parent=null,i&&t.removeSelfFromZr(i),i&&i.refresh()),this},e.prototype.removeAll=function(){for(var t=this._children,i=this.__zr,r=0;r0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},n.prototype.setSleepAfterStill=function(e){this._sleepAfterStill=e},n.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},n.prototype.refreshHover=function(){this._needsRefreshHover=!0},n.prototype.refreshHoverImmediately=function(){this._disposed||(this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.getType()==="canvas"&&this.painter.refreshHover())},n.prototype.resize=function(e){this._disposed||(e=e||{},this.painter.resize(e.width,e.height),this.handler.resize())},n.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},n.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},n.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},n.prototype.setCursorStyle=function(e){this._disposed||this.handler.setCursorStyle(e)},n.prototype.findHover=function(e,t){if(!this._disposed)return this.handler.findHover(e,t)},n.prototype.on=function(e,t,i){return this._disposed||this.handler.on(e,t,i),this},n.prototype.off=function(e,t){this._disposed||this.handler.off(e,t)},n.prototype.trigger=function(e,t){this._disposed||this.handler.trigger(e,t)},n.prototype.clear=function(){if(!this._disposed){for(var e=this.storage.getRoots(),t=0;t0){if(n<=r)return a;if(n>=o)return s}else{if(n>=r)return a;if(n<=o)return s}else{if(n===r)return a;if(n===o)return s}return(n-r)/l*u+a}function te(n,e){switch(n){case"center":case"middle":n="50%";break;case"left":case"top":n="0%";break;case"right":case"bottom":n="100%"}return j(n)?(t=n,t.replace(/^\s+|\s+$/g,"")).match(/%$/)?parseFloat(n)/100*e:parseFloat(n):n==null?NaN:+n;var t}function Ue(n,e,t){return e==null&&(e=10),e=Math.min(Math.max(0,e),rv),n=(+n).toFixed(e),t?n:+n}function Qo(n){return n.sort(function(e,t){return e-t}),n}function kn(n){if(n=+n,isNaN(n))return 0;if(n>1e-14){for(var e=1,t=0;t<15;t++,e*=10)if(Math.round(n*e)/e===n)return t}return zs(n)}function zs(n){var e=n.toString().toLowerCase(),t=e.indexOf("e"),i=t>0?+e.slice(t+1):0,r=t>0?t:e.length,o=e.indexOf("."),a=o<0?0:r-1-o;return Math.max(0,a-i)}function $h(n,e){var t=Math.log,i=Math.LN10,r=Math.floor(t(n[1]-n[0])/i),o=Math.round(t(Math.abs(e[1]-e[0]))/i),a=Math.min(Math.max(-r+o,0),20);return isFinite(a)?a:20}function ov(n,e){var t=pn(n,function(d,f){return d+(isNaN(f)?0:f)},0);if(t===0)return[];for(var i=Math.pow(10,e),r=U(n,function(d){return(isNaN(d)?0:d)/t*i*100}),o=100*i,a=U(r,function(d){return Math.floor(d)}),s=pn(a,function(d,f){return d+f},0),l=U(r,function(d,f){return d-a[f]});su&&(u=l[c],h=c);++a[h],l[h]=0,++s}return U(a,function(d){return d/i})}function jM(n,e){var t=Math.max(kn(n),kn(e)),i=n+e;return t>rv?i:Ue(i,t)}function Qh(n){var e=2*Math.PI;return(n%e+e)%e}function ea(n){return n>-iv&&n=10&&e++,e}function ec(n,e){var t=ta(n),i=Math.pow(10,t),r=n/i;return n=(e?r<1.5?1:r<2.5?2:r<4?3:r<7?5:10:r<1?1:r<2?2:r<3?3:r<5?5:10)*i,t>=-20?+n.toFixed(t<0?-t:0):n}function tc(n){n.sort(function(l,u){return s(l,u,0)?-1:1});for(var e=-1/0,t=1,i=0;i"u"||!JSON.stringify)return"?";try{return JSON.stringify(i,function(o,a){var s=t(a);return s??a})}catch{return"?"}}).join(" ")}function It(n){throw new Error(n)}function cv(n,e,t){return(e-n)*t+n}var pv="series\0",dv="\0_ec_\0";function Qe(n){return n instanceof Array?n:n==null?[]:[n]}function Gs(n,e,t){if(n){n[e]=n[e]||{},n.emphasis=n.emphasis||{},n.emphasis[e]=n.emphasis[e]||{};for(var i=0,r=t.length;i=0||o&&Me(o,l)<0)){var u=i.getShallow(l,e);u!=null&&(a[n[s][0]]=u)}}return a}}var oT=Xr([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),aT=function(){function n(){}return n.prototype.getAreaStyle=function(e,t){return oT(this,e,t)},n}(),oc=new Yo(50);function sT(n){if(typeof n=="string"){var e=oc.get(n);return e&&e.image}return n}function bv(n,e,t,i,r){if(n){if(typeof n=="string"){if(e&&e.__zrImageSrc===n||!t)return e;var o=oc.get(n),a={hostEl:t,cb:i,cbPayload:r};return o?!Ws(e=o.image)&&o.pending.push(a):((e=Yn.loadImage(n,Sv,Sv)).__zrImageSrc=n,oc.put(n,e.__cachedImgObj={image:e,pending:[a]})),e}return n}return e}function Sv(){var n=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;e=a;l++)s-=a;var u=zt(t,e);return u>s&&(t="",u=0),s=n-u,r.ellipsis=t,r.ellipsisWidth=u,r.contentWidth=s,r.containerWidth=n,r}function Cv(n,e){var t=e.containerWidth,i=e.font,r=e.contentWidth;if(!t)return"";var o=zt(n,i);if(o<=t)return n;for(var a=0;;a++){if(o<=r||a>=e.maxIterations){n+=e.ellipsis;break}var s=a===0?lT(n,r,e.ascCharWidth,e.cnCharWidth):o>0?Math.floor(n.length*r/o):0;o=zt(n=n.substr(0,s),i)}return n===""&&(n=e.placeholder),n}function lT(n,e,t,i){for(var r=0,o=0,a=n.length;o0&&f+i.accumWidth>i.width&&(o=e.split(` `),c=!0),i.accumWidth=f}else{var g=Av(e,h,i.width,i.breakAll,i.accumWidth);i.accumWidth=g.accumWidth+d,a=g.linesWidths,o=g.lines}}else o=e.split(` `);for(var v=0;v=32&&t<=591||t>=880&&t<=4351||t>=4608&&t<=5119||t>=7680&&t<=8303}(n)||!!cT[n]}function Av(n,e,t,i,r){for(var o=[],a=[],s="",l="",u=0,h=0,c=0;ct:r+h+d>t)?h?(s||l)&&(f?(s||(s=l,l="",h=u=0),o.push(s),a.push(h-u),l+=p,s="",h=u+=d):(l&&(s+=l,l="",u=0),o.push(s),a.push(h),s=p,h=d)):f?(o.push(l),a.push(u),l=p,u=d):(o.push(p),a.push(d)):(h+=d,f?(l+=p,u+=d):(l&&(s+=l,l="",u=0),s+=p))}else l&&(s+=l,h+=u),o.push(s),a.push(h),s="",l="",u=0,h=0}return o.length||s||(s=n,l="",u=0),l&&(s+=l),s&&(o.push(s),a.push(h)),o.length===1&&(h+=r),{accumWidth:h,lines:o,linesWidths:a}}var lc="__zr_style_"+Math.round(10*Math.random()),er={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},Ys={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};er[lc]=!0;var Dv=["z","z2","invisible"],dT=["invisible"],fT=function(n){function e(i){return n.call(this,i)||this}var t;return V(e,n),e.prototype._init=function(i){for(var r=Oe(i),o=0;o1e-4)return s[0]=n-t,s[1]=e-i,l[0]=n+t,void(l[1]=e+i);if(Us[0]=pc(r)*t+n,Us[1]=cc(r)*i+e,Xs[0]=pc(o)*t+n,Xs[1]=cc(o)*i+e,u(s,Us,Xs),h(l,Us,Xs),(r%=nr)<0&&(r+=nr),(o%=nr)<0&&(o+=nr),r>o&&!a?o+=nr:rr&&(js[0]=pc(d)*t+n,js[1]=cc(d)*i+e,u(s,js,s),h(l,js,l))}var Pe={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},ir=[],rr=[],Pn=[],mi=[],On=[],Rn=[],dc=Math.min,fc=Math.max,or=Math.cos,ar=Math.sin,Zn=Math.abs,gc=Math.PI,xi=2*gc,vc=typeof Float32Array<"u",sa=[];function yc(n){return Math.round(n/gc*1e8)/1e8%2*gc}function mc(n,e){var t=yc(n[0]);t<0&&(t+=xi);var i=t-n[0],r=n[1];r+=i,!e&&r-t>=xi?r=t+xi:e&&t-r>=xi?r=t-xi:!e&&t>r?r=t+(xi-yc(t-r)):e&&t0&&(this._ux=Zn(i/Es/e)||0,this._uy=Zn(i/Es/t)||0)},n.prototype.setDPR=function(e){this.dpr=e},n.prototype.setContext=function(e){this._ctx=e},n.prototype.getContext=function(){return this._ctx},n.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},n.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},n.prototype.moveTo=function(e,t){return this._drawPendingPt(),this.addData(Pe.M,e,t),this._ctx&&this._ctx.moveTo(e,t),this._x0=e,this._y0=t,this._xi=e,this._yi=t,this},n.prototype.lineTo=function(e,t){var i=Zn(e-this._xi),r=Zn(t-this._yi),o=i>this._ux||r>this._uy;if(this.addData(Pe.L,e,t),this._ctx&&o&&this._ctx.lineTo(e,t),o)this._xi=e,this._yi=t,this._pendingPtDist=0;else{var a=i*i+r*r;a>this._pendingPtDist&&(this._pendingPtX=e,this._pendingPtY=t,this._pendingPtDist=a)}return this},n.prototype.bezierCurveTo=function(e,t,i,r,o,a){return this._drawPendingPt(),this.addData(Pe.C,e,t,i,r,o,a),this._ctx&&this._ctx.bezierCurveTo(e,t,i,r,o,a),this._xi=o,this._yi=a,this},n.prototype.quadraticCurveTo=function(e,t,i,r){return this._drawPendingPt(),this.addData(Pe.Q,e,t,i,r),this._ctx&&this._ctx.quadraticCurveTo(e,t,i,r),this._xi=i,this._yi=r,this},n.prototype.arc=function(e,t,i,r,o,a){this._drawPendingPt(),sa[0]=r,sa[1]=o,mc(sa,a),r=sa[0];var s=(o=sa[1])-r;return this.addData(Pe.A,e,t,i,i,r,s,0,a?0:1),this._ctx&&this._ctx.arc(e,t,i,r,o,a),this._xi=or(o)*i+e,this._yi=ar(o)*i+t,this},n.prototype.arcTo=function(e,t,i,r,o){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(e,t,i,r,o),this},n.prototype.rect=function(e,t,i,r){return this._drawPendingPt(),this._ctx&&this._ctx.rect(e,t,i,r),this.addData(Pe.R,e,t,i,r),this},n.prototype.closePath=function(){this._drawPendingPt(),this.addData(Pe.Z);var e=this._ctx,t=this._x0,i=this._y0;return e&&e.closePath(),this._xi=t,this._yi=i,this},n.prototype.fill=function(e){e&&e.fill(),this.toStatic()},n.prototype.stroke=function(e){e&&e.stroke(),this.toStatic()},n.prototype.len=function(){return this._len},n.prototype.setData=function(e){var t=e.length;this.data&&this.data.length===t||!vc||(this.data=new Float32Array(t));for(var i=0;ih.length&&(this._expandData(),h=this.data);for(var c=0;c0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},n.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var e=[],t=0;t11&&(this.data=new Float32Array(e)))}},n.prototype.getBoundingRect=function(){Pn[0]=Pn[1]=On[0]=On[1]=Number.MAX_VALUE,mi[0]=mi[1]=Rn[0]=Rn[1]=-Number.MAX_VALUE;var e,t=this.data,i=0,r=0,o=0,a=0;for(e=0;ei||Zn(y)>r||p===t-1)&&(g=Math.sqrt(R*R+y*y),o=v,a=_);break;case Pe.C:var m=e[p++],x=e[p++],_=(v=e[p++],e[p++]),w=e[p++],b=e[p++];g=xM(o,a,m,x,v,_,w,b,10),o=w,a=b;break;case Pe.Q:g=_M(o,a,m=e[p++],x=e[p++],v=e[p++],_=e[p++],10),o=v,a=_;break;case Pe.A:var S=e[p++],M=e[p++],T=e[p++],C=e[p++],I=e[p++],D=e[p++],L=D+I;p+=1,f&&(s=or(I)*T+S,l=ar(I)*C+M),g=fc(T,C)*dc(xi,Math.abs(D)),o=or(L)*T+S,a=ar(L)*C+M;break;case Pe.R:s=o=e[p++],l=a=e[p++],g=2*e[p++]+2*e[p++];break;case Pe.Z:var R=s-o;y=l-a,g=Math.sqrt(R*R+y*y),o=s,a=l}g>=0&&(u[c++]=g,h+=g)}return this._pathLen=h,h},n.prototype.rebuildPath=function(e,t){var i,r,o,a,s,l,u,h,c,p,d=this.data,f=this._ux,g=this._uy,v=this._len,y=t<1,m=0,x=0,_=0;if(!y||(this._pathSegLen||this._calculateLength(),u=this._pathSegLen,h=t*this._pathLen))e:for(var w=0;w0&&(e.lineTo(c,p),_=0),b){case Pe.M:i=o=d[w++],r=a=d[w++],e.moveTo(o,a);break;case Pe.L:s=d[w++],l=d[w++];var M=Zn(s-o),T=Zn(l-a);if(M>f||T>g){if(y){if(m+($=u[x++])>h){var C=(h-m)/$;e.lineTo(o*(1-C)+s*C,a*(1-C)+l*C);break e}m+=$}e.lineTo(s,l),o=s,a=l,_=0}else{var I=M*M+T*T;I>_&&(c=s,p=l,_=I)}break;case Pe.C:var D=d[w++],L=d[w++],R=d[w++],O=d[w++],E=d[w++],k=d[w++];if(y){if(m+($=u[x++])>h){Cs(o,D,R,E,C=(h-m)/$,ir),Cs(a,L,O,k,C,rr),e.bezierCurveTo(ir[1],rr[1],ir[2],rr[2],ir[3],rr[3]);break e}m+=$}e.bezierCurveTo(D,L,R,O,E,k),o=E,a=k;break;case Pe.Q:if(D=d[w++],L=d[w++],R=d[w++],O=d[w++],y){if(m+($=u[x++])>h){Is(o,D,R,C=(h-m)/$,ir),Is(a,L,O,C,rr),e.quadraticCurveTo(ir[1],rr[1],ir[2],rr[2]);break e}m+=$}e.quadraticCurveTo(D,L,R,O),o=R,a=O;break;case Pe.A:var P=d[w++],N=d[w++],B=d[w++],z=d[w++],X=d[w++],Z=d[w++],F=d[w++],Y=!d[w++],K=B>z?B:z,oe=Zn(B-z)>.001,ce=X+Z,se=!1;if(y&&(m+($=u[x++])>h&&(ce=X+Z*(h-m)/$,se=!0),m+=$),oe&&e.ellipse?e.ellipse(P,N,B,z,F,X,ce,Y):e.arc(P,N,K,X,ce,Y),se)break e;S&&(i=or(X)*B+P,r=ar(X)*z+N),o=or(ce)*B+P,a=ar(ce)*z+N;break;case Pe.R:i=o=d[w],r=a=d[w+1],s=d[w++],l=d[w++];var q=d[w++],J=d[w++];if(y){if(m+($=u[x++])>h){var H=h-m;e.moveTo(s,l),e.lineTo(s+dc(H,q),l),(H-=q)>0&&e.lineTo(s+q,l+dc(H,J)),(H-=J)>0&&e.lineTo(s+fc(q-H,0),l+J),(H-=q)>0&&e.lineTo(s,l+fc(J-H,0));break e}m+=$}e.rect(s,l,q,J);break;case Pe.Z:if(y){var $;if(m+($=u[x++])>h){C=(h-m)/$,e.lineTo(o*(1-C)+i*C,a*(1-C)+r*C);break e}m+=$}e.closePath(),o=i,a=r}}},n.prototype.clone=function(){var e=new n,t=this.data;return e.data=t.slice?t.slice():Array.prototype.slice.call(t),e._len=this._len,e},n.CMD=Pe,n.initDefaultProps=function(){var e=n.prototype;e._saveData=!0,e._ux=0,e._uy=0,e._pendingPtDist=0,e._version=0}(),n}();const _i=mT;function jr(n,e,t,i,r,o,a){if(r===0)return!1;var s=r,l=0;if(a>e+s&&a>i+s||an+s&&o>t+s||oe+c&&h>i+c&&h>o+c&&h>s+c||hn+c&&u>t+c&&u>r+c&&u>a+c||ue+u&&l>i+u&&l>o+u||ln+u&&s>t+u&&s>r+u||st||h+ur&&(r+=la);var p=Math.atan2(l,s);return p<0&&(p+=la),p>=i&&p<=r||p+la>=i&&p+la<=r}function Kn(n,e,t,i,r,o){if(o>e&&o>i||or?s:0}var wi=_i.CMD,sr=2*Math.PI,bT=1e-4,xt=[-1,-1,-1],$t=[-1,-1];function ST(n,e,t,i,r,o,a,s,l,u){if(u>e&&u>i&&u>o&&u>s||u1&&(h=void 0,h=$t[0],$t[0]=$t[1],$t[1]=h),f=tt(e,i,o,s,$t[0]),d>1&&(g=tt(e,i,o,s,$t[1]))),d===2?y<$t[0]?p+=fe&&s>i&&s>o||s=0&&M<=1&&(m[b++]=M);else{var S=_*_-4*x*w;if(gi(S))(M=-_/(2*x))>=0&&M<=1&&(m[b++]=M);else if(S>0){var M,T=fi(S),C=(-_-T)/(2*x);(M=(-_+T)/(2*x))>=0&&M<=1&&(m[b++]=M),C>=0&&C<=1&&(m[b++]=C)}}return b}(e,i,o,s,xt);if(l===0)return 0;var u=Og(e,i,o);if(u>=0&&u<=1){for(var h=0,c=pt(e,i,o,u),p=0;pt||s<-t)return 0;var l=Math.sqrt(t*t-s*s);xt[0]=-l,xt[1]=l;var u=Math.abs(i-r);if(u<1e-4)return 0;if(u>=sr-1e-4){i=0,r=sr;var h=o?1:-1;return a>=xt[0]+n&&a<=xt[1]+n?h:0}if(i>r){var c=i;i=r,r=c}i<0&&(i+=sr,r+=sr);for(var p=0,d=0;d<2;d++){var f=xt[d];if(f+n>a){var g=Math.atan2(s,f);h=o?1:-1,g<0&&(g=sr+g),(g>=i&&g<=r||g+sr>=i&&g+sr<=r)&&(g>Math.PI/2&&g<1.5*Math.PI&&(h=-h),p+=h)}}return p}function Rv(n,e,t,i,r){for(var o,a,s,l,u=n.data,h=n.len(),c=0,p=0,d=0,f=0,g=0,v=0;v1&&(t||(c+=Kn(p,d,f,g,i,r))),m&&(f=p=u[v],g=d=u[v+1]),y){case wi.M:p=f=u[v++],d=g=u[v++];break;case wi.L:if(t){if(jr(p,d,u[v],u[v+1],e,i,r))return!0}else c+=Kn(p,d,u[v],u[v+1],i,r)||0;p=u[v++],d=u[v++];break;case wi.C:if(t){if(xT(p,d,u[v++],u[v++],u[v++],u[v++],u[v],u[v+1],e,i,r))return!0}else c+=ST(p,d,u[v++],u[v++],u[v++],u[v++],u[v],u[v+1],i,r)||0;p=u[v++],d=u[v++];break;case wi.Q:if(t){if(_T(p,d,u[v++],u[v++],u[v],u[v+1],e,i,r))return!0}else c+=MT(p,d,u[v++],u[v++],u[v],u[v+1],i,r)||0;p=u[v++],d=u[v++];break;case wi.A:var x=u[v++],_=u[v++],w=u[v++],b=u[v++],S=u[v++],M=u[v++];v+=1;var T=!!(1-u[v++]);o=Math.cos(S)*w+x,a=Math.sin(S)*b+_,m?(f=o,g=a):c+=Kn(p,d,o,a,i,r);var C=(i-x)*b/w+x;if(t){if(wT(x,_,b,S,S+M,T,e,C,r))return!0}else c+=TT(x,_,b,S,S+M,T,C,r);p=Math.cos(S+M)*w+x,d=Math.sin(S+M)*b+_;break;case wi.R:if(f=p=u[v++],g=d=u[v++],o=f+u[v++],a=g+u[v++],t){if(jr(f,g,o,g,e,i,r)||jr(o,g,o,a,e,i,r)||jr(o,a,f,a,e,i,r)||jr(f,a,f,g,e,i,r))return!0}else c+=Kn(o,g,o,a,i,r),c+=Kn(f,a,f,g,i,r);break;case wi.Z:if(t){if(jr(p,d,f,g,e,i,r))return!0}else c+=Kn(p,d,f,g,i,r);p=f,d=g}}return t||(s=d,l=g,Math.abs(s-l).5?Fh:r>.2?"#eee":Gh}if(i)return Gh}return Fh},e.prototype.getInsideTextStroke=function(i){var r=this.style.fill;if(j(r)){var o=this.__zr;if(!(!o||!o.isDarkMode())==jo(i,0)<.4)return r}},e.prototype.buildPath=function(i,r,o){},e.prototype.pathUpdated=function(){this.__dirty&=~Br},e.prototype.getUpdatedPathProxy=function(i){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,i),this.path},e.prototype.createPathProxy=function(){this.path=new _i(!1)},e.prototype.hasStroke=function(){var i=this.style,r=i.stroke;return!(r==null||r==="none"||!(i.lineWidth>0))},e.prototype.hasFill=function(){var i=this.style.fill;return i!=null&&i!=="none"},e.prototype.getBoundingRect=function(){var i=this._rect,r=this.style,o=!i;if(o){var a=!1;this.path||(a=!0,this.createPathProxy());var s=this.path;(a||this.__dirty&Br)&&(s.beginPath(),this.buildPath(s,this.shape,!1),this.pathUpdated()),i=s.getBoundingRect()}if(this._rect=i,this.hasStroke()&&this.path&&this.path.len()>0){var l=this._rectStroke||(this._rectStroke=i.clone());if(this.__dirty||o){l.copy(i);var u=r.strokeNoScale?this.getLineScale():1,h=r.lineWidth;if(!this.hasFill()){var c=this.strokeContainThreshold;h=Math.max(h,c??4)}u>1e-10&&(l.width+=h/u,l.height+=h/u,l.x-=h/u/2,l.y-=h/u/2)}return l}return i},e.prototype.contain=function(i,r){var o=this.transformCoordToLocal(i,r),a=this.getBoundingRect(),s=this.style;if(i=o[0],r=o[1],a.contain(i,r)){var l=this.path;if(this.hasStroke()){var u=s.lineWidth,h=s.strokeNoScale?this.getLineScale():1;if(h>1e-10&&(this.hasFill()||(u=Math.max(u,this.strokeContainThreshold)),function(c,p,d,f){return Rv(c,p,!0,d,f)}(l,u/h,i,r)))return!0}if(this.hasFill())return function(c,p,d){return Rv(c,0,!1,p,d)}(l,i,r)}return!1},e.prototype.dirtyShape=function(){this.__dirty|=Br,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},e.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},e.prototype.animateShape=function(i){return this.animate("shape",i)},e.prototype.updateDuringAnimation=function(i){i==="style"?this.dirtyStyle():i==="shape"?this.dirtyShape():this.markRedraw()},e.prototype.attrKV=function(i,r){i==="shape"?this.setShape(r):n.prototype.attrKV.call(this,i,r)},e.prototype.setShape=function(i,r){var o=this.shape;return o||(o=this.shape={}),typeof i=="string"?o[i]=r:G(o,i),this.dirtyShape(),this},e.prototype.shapeChanged=function(){return!!(this.__dirty&Br)},e.prototype.createStyle=function(i){return Bo(Ev,i)},e.prototype._innerSaveToNormal=function(i){n.prototype._innerSaveToNormal.call(this,i);var r=this._normalState;i.shape&&!r.shape&&(r.shape=G({},this.shape))},e.prototype._applyStateObj=function(i,r,o,a,s,l){n.prototype._applyStateObj.call(this,i,r,o,a,s,l);var u,h=!(r&&a);if(r&&r.shape?s?a?u=r.shape:(u=G({},o.shape),G(u,r.shape)):(u=G({},a?this.shape:o.shape),G(u,r.shape)):h&&(u=o.shape),u)if(s){this.shape=G({},this.shape);for(var c={},p=Oe(u),d=0;d0},e.prototype.hasFill=function(){var t=this.style.fill;return t!=null&&t!=="none"},e.prototype.createStyle=function(t){return Bo(AT,t)},e.prototype.setBoundingRect=function(t){this._rect=t},e.prototype.getBoundingRect=function(){var t=this.style;if(!this._rect){var i=t.text;i!=null?i+="":i="";var r=Ko(i,t.font,t.textAlign,t.textBaseline);if(r.x+=t.x||0,r.y+=t.y||0,this.hasStroke()){var o=t.lineWidth;r.x-=o/2,r.y-=o/2,r.width+=o,r.height+=o}this._rect=r}return this._rect},e.initDefaultProps=void(e.prototype.dirtyRectTolerance=10),e}(tr);Nv.prototype.type="tspan";const Zs=Nv;var DT=ae({x:0,y:0},er),kT={style:ae({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},Ys.style)},zv=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.createStyle=function(t){return Bo(DT,t)},e.prototype._getSize=function(t){var i=this.style,r=i[t];if(r!=null)return r;var o,a=(o=i.image)&&typeof o!="string"&&o.width&&o.height?i.image:this.__image;if(!a)return 0;var s=t==="width"?"height":"width",l=i[s];return l==null?a[t]:a[t]/a[s]*l},e.prototype.getWidth=function(){return this._getSize("width")},e.prototype.getHeight=function(){return this._getSize("height")},e.prototype.getAnimationStyleProps=function(){return kT},e.prototype.getBoundingRect=function(){var t=this.style;return this._rect||(this._rect=new ve(t.x||0,t.y||0,this.getWidth(),this.getHeight())),this._rect},e}(tr);zv.prototype.type="image";const Bt=zv;var Zr=Math.round;function Bv(n,e,t){if(e){var i=e.x1,r=e.x2,o=e.y1,a=e.y2;n.x1=i,n.x2=r,n.y1=o,n.y2=a;var s=t&&t.lineWidth;return s&&(Zr(2*i)===Zr(2*r)&&(n.x1=n.x2=lr(i,s,!0)),Zr(2*o)===Zr(2*a)&&(n.y1=n.y2=lr(o,s,!0))),n}}function Vv(n,e,t){if(e){var i=e.x,r=e.y,o=e.width,a=e.height;n.x=i,n.y=r,n.width=o,n.height=a;var s=t&&t.lineWidth;return s&&(n.x=lr(i,s,!0),n.y=lr(r,s,!0),n.width=Math.max(lr(i+o,s,!1)-n.x,o===0?0:1),n.height=Math.max(lr(r+a,s,!1)-n.y,a===0?0:1)),n}}function lr(n,e,t){if(!e)return n;var i=Zr(2*n);return(i+Zr(e))%2==0?i/2:(i+(t?1:-1))/2}var LT=function(){this.x=0,this.y=0,this.width=0,this.height=0},PT={},Fv=function(n){function e(t){return n.call(this,t)||this}return V(e,n),e.prototype.getDefaultShape=function(){return new LT},e.prototype.buildPath=function(t,i){var r,o,a,s;if(this.subPixelOptimize){var l=Vv(PT,i,this.style);r=l.x,o=l.y,a=l.width,s=l.height,l.r=i.r,i=l}else r=i.x,o=i.y,a=i.width,s=i.height;i.r?function(u,h){var c,p,d,f,g,v=h.x,y=h.y,m=h.width,x=h.height,_=h.r;m<0&&(v+=m,m=-m),x<0&&(y+=x,x=-x),typeof _=="number"?c=p=d=f=_:_ instanceof Array?_.length===1?c=p=d=f=_[0]:_.length===2?(c=d=_[0],p=f=_[1]):_.length===3?(c=_[0],p=f=_[1],d=_[2]):(c=_[0],p=_[1],d=_[2],f=_[3]):c=p=d=f=0,c+p>m&&(c*=m/(g=c+p),p*=m/g),d+f>m&&(d*=m/(g=d+f),f*=m/g),p+d>x&&(p*=x/(g=p+d),d*=x/g),c+f>x&&(c*=x/(g=c+f),f*=x/g),u.moveTo(v+c,y),u.lineTo(v+m-p,y),p!==0&&u.arc(v+m-p,y+p,p,-Math.PI/2,0),u.lineTo(v+m,y+x-d),d!==0&&u.arc(v+m-d,y+x-d,d,0,Math.PI/2),u.lineTo(v+f,y+x),f!==0&&u.arc(v+f,y+x-f,f,Math.PI/2,Math.PI),u.lineTo(v,y+c),c!==0&&u.arc(v+c,y+c,c,Math.PI,1.5*Math.PI)}(t,i):t.rect(r,o,a,s)},e.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},e}(Ae);Fv.prototype.type="rect";const Re=Fv;var Gv={fill:"#000"},OT={style:ae({fill:!0,stroke:!0,fillOpacity:!0,strokeOpacity:!0,lineWidth:!0,fontSize:!0,lineHeight:!0,width:!0,height:!0,textShadowColor:!0,textShadowBlur:!0,textShadowOffsetX:!0,textShadowOffsetY:!0,backgroundColor:!0,padding:!0,borderColor:!0,borderWidth:!0,borderRadius:!0},Ys.style)},Hv=function(n){function e(t){var i=n.call(this)||this;return i.type="text",i._children=[],i._defaultStyle=Gv,i.attr(t),i}return V(e,n),e.prototype.childrenRef=function(){return this._children},e.prototype.update=function(){n.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var t=0;tse&&K){var q=Math.floor(se/F);P=P.slice(0,q)}if(E&&X&&oe!=null)for(var J=Tv(oe,z,k.ellipsis,{minChar:k.truncateMinChar,placeholder:k.placeholder}),H=0;H0,I=t.width!=null&&(t.overflow==="truncate"||t.overflow==="break"||t.overflow==="breakAll"),D=o.calculatedLineHeight,L=0;LX&&sc(E,R.substring(X,Z),O,z),sc(E,k[2],O,z,k[1]),X=ac.lastIndex}XN){Ce>0?(H.tokens=H.tokens.slice(0,Ce),q(H,ne,$),E.lines=E.lines.slice(0,J+1)):E.lines=E.lines.slice(0,J);break e}var ke=ge.width,Ne=ke==null||ke==="auto";if(typeof ke=="string"&&ke.charAt(ke.length-1)==="%")ue.percentWidth=ke,F.push(ue),ue.contentWidth=zt(ue.text,Ie);else{if(Ne){var qe=ge.backgroundColor,Be=qe&&qe.image;Be&&Ws(Be=sT(Be))&&(ue.width=Math.max(ue.width,Be.width*be/Be.height))}var Ve=ce&&P!=null?P-ne:null;Ve!=null&&Ve=0&&(L=w[D]).align==="right";)this._placeToken(L,t,S,v,I,"right",m),M-=L.width,I-=L.width,D--;for(C+=(r-(C-g)-(y-I)-M)/2;T<=D;)L=w[T],this._placeToken(L,t,S,v,C+L.width/2,"center",m),C+=L.width,T++;v+=S}},e.prototype._placeToken=function(t,i,r,o,a,s,l){var u=i.rich[t.styleName]||{};u.text=t.text;var h=t.verticalAlign,c=o+r/2;h==="top"?c=o+t.height/2:h==="bottom"&&(c=o+r-t.height/2),!t.isLineHolder&&_c(u)&&this._renderBackground(u,i,s==="right"?a-t.width:s==="center"?a-t.width/2:a,c-t.height/2,t.width,t.height);var p=!!u.backgroundColor,d=t.textPadding;d&&(a=Zv(a,s,d),c-=t.height/2-d[0]-t.innerHeight/2);var f=this._getOrCreateChild(Zs),g=f.createStyle();f.useStyle(g);var v=this._defaultStyle,y=!1,m=0,x=jv("fill"in u?u.fill:"fill"in i?i.fill:(y=!0,v.fill)),_=Xv("stroke"in u?u.stroke:"stroke"in i?i.stroke:p||l||v.autoStroke&&!y?null:(m=2,v.stroke)),w=u.textShadowBlur>0||i.textShadowBlur>0;g.text=t.text,g.x=a,g.y=c,w&&(g.shadowBlur=u.textShadowBlur||i.textShadowBlur||0,g.shadowColor=u.textShadowColor||i.textShadowColor||"transparent",g.shadowOffsetX=u.textShadowOffsetX||i.textShadowOffsetX||0,g.shadowOffsetY=u.textShadowOffsetY||i.textShadowOffsetY||0),g.textAlign=s,g.textBaseline="middle",g.font=t.font||Ni,g.opacity=di(u.opacity,i.opacity,1),Yv(g,u),_&&(g.lineWidth=di(u.lineWidth,i.lineWidth,m),g.lineDash=de(u.lineDash,i.lineDash),g.lineDashOffset=i.lineDashOffset||0,g.stroke=_),x&&(g.fill=x);var b=t.contentWidth,S=t.contentHeight;f.setBoundingRect(new ve(Jo(g.x,b,g.textAlign),Wr(g.y,S,g.textBaseline),b,S))},e.prototype._renderBackground=function(t,i,r,o,a,s){var l,u,h,c=t.backgroundColor,p=t.borderWidth,d=t.borderColor,f=c&&c.image,g=c&&!f,v=t.borderRadius,y=this;if(g||t.lineHeight||p&&d){(l=this._getOrCreateChild(Re)).useStyle(l.createStyle()),l.style.fill=null;var m=l.shape;m.x=r,m.y=o,m.width=a,m.height=s,m.r=v,l.dirtyShape()}if(g)(h=l.style).fill=c||null,h.fillOpacity=de(t.fillOpacity,1);else if(f){(u=this._getOrCreateChild(Bt)).onload=function(){y.dirtyStyle()};var x=u.style;x.image=c.image,x.x=r,x.y=o,x.width=a,x.height=s}p&&d&&((h=l.style).lineWidth=p,h.stroke=d,h.strokeOpacity=de(t.strokeOpacity,1),h.lineDash=t.borderDash,h.lineDashOffset=t.borderDashOffset||0,l.strokeContainThreshold=0,l.hasFill()&&l.hasStroke()&&(h.strokeFirst=!0,h.lineWidth*=2));var _=(l||u).style;_.shadowBlur=t.shadowBlur||0,_.shadowColor=t.shadowColor||"transparent",_.shadowOffsetX=t.shadowOffsetX||0,_.shadowOffsetY=t.shadowOffsetY||0,_.opacity=di(t.opacity,i.opacity,1)},e.makeFont=function(t){var i="";return function(r){return r.fontSize!=null||r.fontFamily||r.fontWeight}(t)&&(i=[t.fontStyle,t.fontWeight,NT(t.fontSize),t.fontFamily||"sans-serif"].join(" ")),i&&Wt(i)||t.textFont||t.font},e}(tr),RT={left:!0,right:1,center:1},ET={top:1,bottom:1,middle:1},Wv=["fontStyle","fontWeight","fontSize","fontFamily"];function NT(n){return typeof n!="string"||n.indexOf("px")===-1&&n.indexOf("rem")===-1&&n.indexOf("em")===-1?isNaN(+n)?"12px":n+"px":n}function Yv(n,e){for(var t=0;t=0,l=!1;if(i instanceof Ae){var u=$v(i),h=s&&u.selectFill||u.normalFill,c=s&&u.selectStroke||u.normalStroke;if(qr(h)||qr(c)){var p=(a=a||{}).style||{};p.fill==="inherit"?(l=!0,a=G({},a),(p=G({},p)).fill=h):!qr(p.fill)&&qr(h)?(l=!0,a=G({},a),(p=G({},p)).fill=kh(h)):!qr(p.stroke)&&qr(c)&&(l||(a=G({},a),p=G({},p)),p.stroke=kh(c)),a.style=p}}if(a&&a.z2==null){l||(a=G({},a));var d=i.z2EmphasisLift;a.z2=i.z2+(d??Qv)}return a}(this,0,e,t);if(n==="blur")return function(i,r,o){var a=Me(i.currentStates,r)>=0,s=i.style.opacity,l=a?null:function(h,c,p,d){for(var f=h.style,g={},v=0;v0){var a={dataIndex:o,seriesIndex:t.seriesIndex};r!=null&&(a.dataType=r),e.push(a)}})}),e}function ca(n,e,t){Lc(n,!0),Jn(n,Ic),function(i,r,o){var a=ye(i);r!=null?(a.focus=r,a.blurScope=o):a.focus&&(a.focus=null)}(n,e,t)}function En(n,e,t,i){i?function(r){Lc(r,!1)}(n):ca(n,e,t)}var py=["emphasis","blur","select"],GT={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function bi(n,e,t,i){t=t||"itemStyle";for(var r=0;r1&&(a*=Oc(f),s*=Oc(f));var g=(r===o?-1:1)*Oc((a*a*(s*s)-a*a*(d*d)-s*s*(p*p))/(a*a*(d*d)+s*s*(p*p)))||0,v=g*a*d/s,y=g*-s*p/a,m=(n+t)/2+nl(c)*v-tl(c)*y,x=(e+i)/2+tl(c)*v+nl(c)*y,_=vy([1,0],[(p-v)/a,(d-y)/s]),w=[(p-v)/a,(d-y)/s],b=[(-1*p-v)/a,(-1*d-y)/s],S=vy(w,b);if(Rc(w,b)<=-1&&(S=pa),Rc(w,b)>=1&&(S=0),S<0){var M=Math.round(S/pa*1e6)/1e6;S=2*pa+M%2*pa}h.addData(u,m,x,a,s,_,S,c,o)}var YT=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,UT=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g,my=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.applyTransform=function(t){},e}(Ae);function xy(n){return n.setData!=null}function _y(n,e){var t=function(r){var o=new _i;if(!r)return o;var a,s=0,l=0,u=s,h=l,c=_i.CMD,p=r.match(YT);if(!p)return o;for(var d=0;dR*R+O*O&&(M=C,T=I),{cx:M,cy:T,x0:-h,y0:-c,x1:M*(r/w-1),y1:T*(r/w-1)}}function qT(n,e){var t,i=fa(e.r,0),r=fa(e.r0||0,0),o=i>0;if(o||r>0){if(o||(i=r,r=0),r>i){var a=i;i=r,r=a}var s=e.startAngle,l=e.endAngle;if(!isNaN(s)&&!isNaN(l)){var u=e.cx,h=e.cy,c=!!e.clockwise,p=Ty(l-s),d=p>Ec&&p%Ec;if(d>mn&&(p=d),i>mn)if(p>Ec-mn)n.moveTo(u+i*eo(s),h+i*hr(s)),n.arc(u,h,i,s,l,!c),r>mn&&(n.moveTo(u+r*eo(l),h+r*hr(l)),n.arc(u,h,r,l,s,c));else{var f=void 0,g=void 0,v=void 0,y=void 0,m=void 0,x=void 0,_=void 0,w=void 0,b=void 0,S=void 0,M=void 0,T=void 0,C=void 0,I=void 0,D=void 0,L=void 0,R=i*eo(s),O=i*hr(s),E=r*eo(l),k=r*hr(l),P=p>mn;if(P){var N=e.cornerRadius;N&&(t=function(H){var $;if(W(H)){var ne=H.length;if(!ne)return H;$=ne===1?[H[0],H[0],0,0]:ne===2?[H[0],H[0],H[1],H[1]]:ne===3?H.concat(H[2]):H}else $=[H,H,H,H];return $}(N),f=t[0],g=t[1],v=t[2],y=t[3]);var B=Ty(i-r)/2;if(m=Nn(B,v),x=Nn(B,y),_=Nn(B,f),w=Nn(B,g),M=b=fa(m,x),T=S=fa(_,w),(b>mn||S>mn)&&(C=i*eo(l),I=i*hr(l),D=r*eo(s),L=r*hr(s),pmn){var ce=Nn(v,M),se=Nn(y,M),q=rl(D,L,R,O,i,ce,c),J=rl(C,I,E,k,i,se,c);n.moveTo(u+q.cx+q.x0,h+q.cy+q.y0),M0&&n.arc(u+q.cx,h+q.cy,ce,dt(q.y0,q.x0),dt(q.y1,q.x1),!c),n.arc(u,h,i,dt(q.cy+q.y1,q.cx+q.x1),dt(J.cy+J.y1,J.cx+J.x1),!c),se>0&&n.arc(u+J.cx,h+J.cy,se,dt(J.y1,J.x1),dt(J.y0,J.x0),!c))}else n.moveTo(u+R,h+O),n.arc(u,h,i,s,l,!c);else n.moveTo(u+R,h+O);r>mn&&P?T>mn?(ce=Nn(f,T),q=rl(E,k,C,I,r,-(se=Nn(g,T)),c),J=rl(R,O,D,L,r,-ce,c),n.lineTo(u+q.cx+q.x0,h+q.cy+q.y0),T0&&n.arc(u+q.cx,h+q.cy,se,dt(q.y0,q.x0),dt(q.y1,q.x1),!c),n.arc(u,h,r,dt(q.cy+q.y1,q.cx+q.x1),dt(J.cy+J.y1,J.cx+J.x1),c),ce>0&&n.arc(u+J.cx,h+J.cy,ce,dt(J.y1,J.x1),dt(J.y0,J.x0),!c))):(n.lineTo(u+E,h+k),n.arc(u,h,r,l,s,c)):n.lineTo(u+E,h+k)}else n.moveTo(u,h);n.closePath()}}}var KT=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0,this.cornerRadius=0},Cy=function(n){function e(t){return n.call(this,t)||this}return V(e,n),e.prototype.getDefaultShape=function(){return new KT},e.prototype.buildPath=function(t,i){qT(t,i)},e.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},e}(Ae);Cy.prototype.type="sector";const en=Cy;var JT=function(){this.cx=0,this.cy=0,this.r=0,this.r0=0},Iy=function(n){function e(t){return n.call(this,t)||this}return V(e,n),e.prototype.getDefaultShape=function(){return new JT},e.prototype.buildPath=function(t,i){var r=i.cx,o=i.cy,a=2*Math.PI;t.moveTo(r+i.r,o),t.arc(r,o,i.r,0,a,!1),t.moveTo(r+i.r0,o),t.arc(r,o,i.r0,0,a,!0)},e}(Ae);Iy.prototype.type="ring";const ga=Iy;function Ay(n,e,t){var i=e.smooth,r=e.points;if(r&&r.length>=2){if(i){var o=function(p,d,f,g){var v,y,m,x,_=[],w=[],b=[],S=[];if(g){m=[1/0,1/0],x=[-1/0,-1/0];for(var M=0,T=p.length;Mpr[1]){if(s=!1,o)return s;var h=Math.abs(pr[0]-cr[1]),c=Math.abs(cr[0]-pr[1]);Math.min(h,c)>r.len()&&(h0){var c={duration:h.duration,delay:h.delay||0,easing:h.easing,done:o,force:!!o||!!a,setToFinal:!u,scope:n,during:a};l?e.animateFrom(t,c):e.animateTo(t,c)}else e.stopAnimation(),!l&&e.attr(t),a&&a(1),o&&o()}function Fe(n,e,t,i,r,o){Vc("update",n,e,t,i,r,o)}function et(n,e,t,i,r,o){Vc("enter",n,e,t,i,r,o)}function to(n){if(!n.__zr)return!0;for(var e=0;eMath.abs(o[1])?o[0]>0?"right":"left":o[1]>0?"bottom":"top"}function Hy(n){return!n.isGroup}function dl(n,e,t){if(n&&e){var i,r=(i={},n.traverse(function(a){Hy(a)&&a.anid&&(i[a.anid]=a)}),i);e.traverse(function(a){if(Hy(a)&&a.anid){var s=r[a.anid];if(s){var l=o(a);a.attr(o(s)),Fe(a,l,t,ye(a).dataIndex)}}})}function o(a){var s={x:a.x,y:a.y,rotation:a.rotation};return function(l){return l.shape!=null}(a)&&(s.shape=G({},a.shape)),s}}function Yc(n,e){return U(n,function(t){var i=t[0];i=hl(i,e.x),i=cl(i,e.x+e.width);var r=t[1];return r=hl(r,e.y),[i,r=cl(r,e.y+e.height)]})}function Wy(n,e){var t=hl(n.x,e.x),i=cl(n.x+n.width,e.x+e.width),r=hl(n.y,e.y),o=cl(n.y+n.height,e.y+e.height);if(i>=t&&o>=r)return{x:t,y:r,width:i-t,height:o-r}}function _a(n,e,t){var i=G({rectHover:!0},e),r=i.style={strokeNoScale:!0};if(t=t||{x:-1,y:-1,width:2,height:2},n)return n.indexOf("image://")===0?(r.image=n.slice(8),ae(r,t),new Bt(i)):pl(n.replace("path://",""),i,t,"center")}function Yy(n,e,t,i,r,o,a,s){var l,u=t-n,h=i-e,c=a-r,p=s-o,d=Uc(c,p,u,h);if((l=d)<=1e-6&&l>=-1e-6)return!1;var f=n-r,g=e-o,v=Uc(f,g,u,h)/d;if(v<0||v>1)return!1;var y=Uc(f,g,c,p)/d;return!(y<0||y>1)}function Uc(n,e,t,i){return n*i-t*e}function wa(n){var e=n.itemTooltipOption,t=n.componentModel,i=n.itemName,r=j(e)?{formatter:e}:e,o=t.mainType,a=t.componentIndex,s={componentType:o,name:i,$vars:["name"]};s[o+"Index"]=a;var l=n.formatterParamsExtra;l&&A(Oe(l),function(h){Yt(s,h)||(s[h]=l[h],s.$vars.push(h))});var u=ye(n.el);u.componentMainType=o,u.componentIndex=a,u.tooltipConfig={name:i,option:ae({content:i,formatterParams:s},r)}}function Uy(n,e){var t;n.isGroup&&(t=e(n)),t||n.traverse(e)}function fl(n,e){if(n)if(W(n))for(var t=0;t-1?yl:Sa;function $c(n,e){n=n.toUpperCase(),Jc[n]=new He(e),ml[n]=e}$c(Kc,{time:{month:["January","February","March","April","May","June","July","August","September","October","November","December"],monthAbbr:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayOfWeek:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayOfWeekAbbr:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},legend:{selector:{all:"All",inverse:"Inv"}},toolbox:{brush:{title:{rect:"Box Select",polygon:"Lasso Select",lineX:"Horizontally Select",lineY:"Vertically Select",keep:"Keep Selections",clear:"Clear Selections"}},dataView:{title:"Data View",lang:["Data View","Close","Refresh"]},dataZoom:{title:{zoom:"Zoom",back:"Zoom Reset"}},magicType:{title:{line:"Switch to Line Chart",bar:"Switch to Bar Chart",stack:"Stack",tiled:"Tile"}},restore:{title:"Restore"},saveAsImage:{title:"Save as Image",lang:["Right Click to Save Image"]}},series:{typeNames:{pie:"Pie chart",bar:"Bar chart",line:"Line chart",scatter:"Scatter plot",effectScatter:"Ripple scatter plot",radar:"Radar chart",tree:"Tree",treemap:"Treemap",boxplot:"Boxplot",candlestick:"Candlestick",k:"K line chart",heatmap:"Heat map",map:"Map",parallel:"Parallel coordinate map",lines:"Line graph",graph:"Relationship graph",sankey:"Sankey diagram",funnel:"Funnel chart",gauge:"Gauge",pictorialBar:"Pictorial bar",themeRiver:"Theme River Map",sunburst:"Sunburst",custom:"Custom chart",chart:"Chart"}},aria:{general:{withTitle:'This is a chart about "{title}"',withoutTitle:"This is a chart"},series:{single:{prefix:"",withName:" with type {seriesType} named {seriesName}.",withoutName:" with type {seriesType}."},multiple:{prefix:". It consists of {seriesCount} series count.",withName:" The {seriesId} series is a {seriesType} representing {seriesName}.",withoutName:" The {seriesId} series is a {seriesType}.",separator:{middle:"",end:""}}},data:{allData:"The data is as follows: ",partialData:"The first {displayCnt} items are: ",withName:"the data for {name} is {value}",withoutName:"{value}",separator:{middle:", ",end:". "}}}}),$c(yl,{time:{month:["\u4E00\u6708","\u4E8C\u6708","\u4E09\u6708","\u56DB\u6708","\u4E94\u6708","\u516D\u6708","\u4E03\u6708","\u516B\u6708","\u4E5D\u6708","\u5341\u6708","\u5341\u4E00\u6708","\u5341\u4E8C\u6708"],monthAbbr:["1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708"],dayOfWeek:["\u661F\u671F\u65E5","\u661F\u671F\u4E00","\u661F\u671F\u4E8C","\u661F\u671F\u4E09","\u661F\u671F\u56DB","\u661F\u671F\u4E94","\u661F\u671F\u516D"],dayOfWeekAbbr:["\u65E5","\u4E00","\u4E8C","\u4E09","\u56DB","\u4E94","\u516D"]},legend:{selector:{all:"\u5168\u9009",inverse:"\u53CD\u9009"}},toolbox:{brush:{title:{rect:"\u77E9\u5F62\u9009\u62E9",polygon:"\u5708\u9009",lineX:"\u6A2A\u5411\u9009\u62E9",lineY:"\u7EB5\u5411\u9009\u62E9",keep:"\u4FDD\u6301\u9009\u62E9",clear:"\u6E05\u9664\u9009\u62E9"}},dataView:{title:"\u6570\u636E\u89C6\u56FE",lang:["\u6570\u636E\u89C6\u56FE","\u5173\u95ED","\u5237\u65B0"]},dataZoom:{title:{zoom:"\u533A\u57DF\u7F29\u653E",back:"\u533A\u57DF\u7F29\u653E\u8FD8\u539F"}},magicType:{title:{line:"\u5207\u6362\u4E3A\u6298\u7EBF\u56FE",bar:"\u5207\u6362\u4E3A\u67F1\u72B6\u56FE",stack:"\u5207\u6362\u4E3A\u5806\u53E0",tiled:"\u5207\u6362\u4E3A\u5E73\u94FA"}},restore:{title:"\u8FD8\u539F"},saveAsImage:{title:"\u4FDD\u5B58\u4E3A\u56FE\u7247",lang:["\u53F3\u952E\u53E6\u5B58\u4E3A\u56FE\u7247"]}},series:{typeNames:{pie:"\u997C\u56FE",bar:"\u67F1\u72B6\u56FE",line:"\u6298\u7EBF\u56FE",scatter:"\u6563\u70B9\u56FE",effectScatter:"\u6D9F\u6F2A\u6563\u70B9\u56FE",radar:"\u96F7\u8FBE\u56FE",tree:"\u6811\u56FE",treemap:"\u77E9\u5F62\u6811\u56FE",boxplot:"\u7BB1\u578B\u56FE",candlestick:"K\u7EBF\u56FE",k:"K\u7EBF\u56FE",heatmap:"\u70ED\u529B\u56FE",map:"\u5730\u56FE",parallel:"\u5E73\u884C\u5750\u6807\u56FE",lines:"\u7EBF\u56FE",graph:"\u5173\u7CFB\u56FE",sankey:"\u6851\u57FA\u56FE",funnel:"\u6F0F\u6597\u56FE",gauge:"\u4EEA\u8868\u76D8\u56FE",pictorialBar:"\u8C61\u5F62\u67F1\u56FE",themeRiver:"\u4E3B\u9898\u6CB3\u6D41\u56FE",sunburst:"\u65ED\u65E5\u56FE",custom:"\u81EA\u5B9A\u4E49\u56FE\u8868",chart:"\u56FE\u8868"}},aria:{general:{withTitle:"\u8FD9\u662F\u4E00\u4E2A\u5173\u4E8E\u201C{title}\u201D\u7684\u56FE\u8868\u3002",withoutTitle:"\u8FD9\u662F\u4E00\u4E2A\u56FE\u8868\uFF0C"},series:{single:{prefix:"",withName:"\u56FE\u8868\u7C7B\u578B\u662F{seriesType}\uFF0C\u8868\u793A{seriesName}\u3002",withoutName:"\u56FE\u8868\u7C7B\u578B\u662F{seriesType}\u3002"},multiple:{prefix:"\u5B83\u7531{seriesCount}\u4E2A\u56FE\u8868\u7CFB\u5217\u7EC4\u6210\u3002",withName:"\u7B2C{seriesId}\u4E2A\u7CFB\u5217\u662F\u4E00\u4E2A\u8868\u793A{seriesName}\u7684{seriesType}\uFF0C",withoutName:"\u7B2C{seriesId}\u4E2A\u7CFB\u5217\u662F\u4E00\u4E2A{seriesType}\uFF0C",separator:{middle:"\uFF1B",end:"\u3002"}}},data:{allData:"\u5176\u6570\u636E\u662F\u2014\u2014",partialData:"\u5176\u4E2D\uFF0C\u524D{displayCnt}\u9879\u662F\u2014\u2014",withName:"{name}\u7684\u6570\u636E\u662F{value}",withoutName:"{value}",separator:{middle:"\uFF0C",end:""}}}});var Qc=1e3,ep=60*Qc,Ma=60*ep,rn=24*Ma,rm=365*rn,Ta={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}",none:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},xl="{yyyy}-{MM}-{dd}",om={year:"{yyyy}",month:"{yyyy}-{MM}",day:xl,hour:xl+" "+Ta.hour,minute:xl+" "+Ta.minute,second:xl+" "+Ta.second,millisecond:Ta.none},tp=["year","month","day","hour","minute","second","millisecond"],am=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function wt(n,e){return"0000".substr(0,e-(n+="").length)+n}function oo(n){switch(n){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return n}}function _C(n){return n===oo(n)}function Ca(n,e,t,i){var r=qt(n),o=r[np(t)](),a=r[ao(t)]()+1,s=Math.floor((a-1)/3)+1,l=r[_l(t)](),u=r["get"+(t?"UTC":"")+"Day"](),h=r[Ia(t)](),c=(h-1)%12+1,p=r[wl(t)](),d=r[bl(t)](),f=r[Sl(t)](),g=i instanceof He?i:function(w){return Jc[w]}(i||im)||Jc[Sa],v=g.getModel("time"),y=v.get("month"),m=v.get("monthAbbr"),x=v.get("dayOfWeek"),_=v.get("dayOfWeekAbbr");return(e||"").replace(/{yyyy}/g,o+"").replace(/{yy}/g,wt(o%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,y[a-1]).replace(/{MMM}/g,m[a-1]).replace(/{MM}/g,wt(a,2)).replace(/{M}/g,a+"").replace(/{dd}/g,wt(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,x[u]).replace(/{ee}/g,_[u]).replace(/{e}/g,u+"").replace(/{HH}/g,wt(h,2)).replace(/{H}/g,h+"").replace(/{hh}/g,wt(c+"",2)).replace(/{h}/g,c+"").replace(/{mm}/g,wt(p,2)).replace(/{m}/g,p+"").replace(/{ss}/g,wt(d,2)).replace(/{s}/g,d+"").replace(/{SSS}/g,wt(f,3)).replace(/{S}/g,f+"")}function sm(n,e){var t=qt(n),i=t[ao(e)]()+1,r=t[_l(e)](),o=t[Ia(e)](),a=t[wl(e)](),s=t[bl(e)](),l=t[Sl(e)]()===0,u=l&&s===0,h=u&&a===0,c=h&&o===0,p=c&&r===1;return p&&i===1?"year":p?"month":c?"day":h?"hour":u?"minute":l?"second":"millisecond"}function lm(n,e,t){var i=Le(n)?qt(n):n;switch(e=e||sm(n,t)){case"year":return i[np(t)]();case"half-year":return i[ao(t)]()>=6?1:0;case"quarter":return Math.floor((i[ao(t)]()+1)/4);case"month":return i[ao(t)]();case"day":return i[_l(t)]();case"half-day":return i[Ia(t)]()/24;case"hour":return i[Ia(t)]();case"minute":return i[wl(t)]();case"second":return i[bl(t)]();case"millisecond":return i[Sl(t)]()}}function np(n){return n?"getUTCFullYear":"getFullYear"}function ao(n){return n?"getUTCMonth":"getMonth"}function _l(n){return n?"getUTCDate":"getDate"}function Ia(n){return n?"getUTCHours":"getHours"}function wl(n){return n?"getUTCMinutes":"getMinutes"}function bl(n){return n?"getUTCSeconds":"getSeconds"}function Sl(n){return n?"getUTCMilliseconds":"getMilliseconds"}function wC(n){return n?"setUTCFullYear":"setFullYear"}function um(n){return n?"setUTCMonth":"setMonth"}function hm(n){return n?"setUTCDate":"setDate"}function cm(n){return n?"setUTCHours":"setHours"}function pm(n){return n?"setUTCMinutes":"setMinutes"}function dm(n){return n?"setUTCSeconds":"setSeconds"}function fm(n){return n?"setUTCMilliseconds":"setMilliseconds"}function ip(n){if(!Bs(n))return j(n)?n:"-";var e=(n+"").split(".");return e[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(e.length>1?"."+e[1]:"")}function rp(n,e){return n=(n||"").toLowerCase().replace(/-(.)/g,function(t,i){return i.toUpperCase()}),e&&n&&(n=n.charAt(0).toUpperCase()+n.slice(1)),n}var so=oh;function op(n,e,t){function i(u){return u&&Wt(u)?u:"-"}function r(u){return!(u==null||isNaN(u)||!isFinite(u))}var o=e==="time",a=n instanceof Date;if(o||a){var s=o?qt(n):n;if(!isNaN(+s))return Ca(s,"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}",t);if(a)return"-"}if(e==="ordinal")return Eo(n)?i(n):Le(n)&&r(n)?n+"":"-";var l=na(n);return r(l)?ip(l):Eo(n)?i(n):typeof n=="boolean"?n+"":"-"}var gm=["a","b","c","d","e","f","g"],ap=function(n,e){return"{"+n+(e??"")+"}"};function sp(n,e,t){W(e)||(e=[e]);var i=e.length;if(!i)return"";for(var r=e[0].$vars||[],o=0;o':'':{renderMode:o,content:"{"+(t.markerId||"markerX")+"|} ",style:r==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:i}:{width:10,height:10,borderRadius:5,backgroundColor:i}}:""}function ym(n){return n&&n.charAt(0).toUpperCase()+n.substr(1)}function gr(n,e){return e=e||"transparent",j(n)?n:Q(n)&&n.colorStops&&(n.colorStops[0]||{}).color||e}function mm(n,e){if(e==="_blank"||e==="blank"){var t=window.open();t.opener=null,t.location.href=n}else window.open(n,e)}var Ml=A,bC=["left","right","top","bottom","width","height"],Tl=[["width","left","right"],["height","top","bottom"]];function lp(n,e,t,i,r){var o=0,a=0;i==null&&(i=1/0),r==null&&(r=1/0);var s=0;e.eachChild(function(l,u){var h,c,p=l.getBoundingRect(),d=e.childAt(u+1),f=d&&d.getBoundingRect();if(n==="horizontal"){var g=p.width+(f?-f.x+p.x:0);(h=o+g)>i||l.newline?(o=0,h=g,a+=s+t,s=p.height):s=Math.max(s,p.height)}else{var v=p.height+(f?-f.y+p.y:0);(c=a+v)>r||l.newline?(o+=s+t,a=0,c=v,s=p.width):s=Math.max(s,p.width)}l.newline||(l.x=o,l.y=a,l.markRedraw(),n==="horizontal"?o=h+t:a=c+t)})}var vr=lp;function Vt(n,e,t){t=so(t||0);var i=e.width,r=e.height,o=te(n.left,i),a=te(n.top,r),s=te(n.right,i),l=te(n.bottom,r),u=te(n.width,i),h=te(n.height,r),c=t[2]+t[0],p=t[1]+t[3],d=n.aspect;switch(isNaN(u)&&(u=i-s-p-o),isNaN(h)&&(h=r-l-c-a),d!=null&&(isNaN(u)&&isNaN(h)&&(d>i/r?u=.8*i:h=.8*r),isNaN(u)&&(u=d*h),isNaN(h)&&(h=u/d)),isNaN(o)&&(o=i-s-u-p),isNaN(a)&&(a=r-l-h-c),n.left||n.right){case"center":o=i/2-u/2-t[3];break;case"right":o=i-u-p}switch(n.top||n.bottom){case"middle":case"center":a=r/2-h/2-t[0];break;case"bottom":a=r-h-c}o=o||0,a=a||0,isNaN(u)&&(u=i-p-o-(s||0)),isNaN(h)&&(h=r-c-a-(l||0));var f=new ve(o+t[3],a+t[0],u,h);return f.margin=t,f}function xm(n,e,t,i,r,o){var a,s=!r||!r.hv||r.hv[0],l=!r||!r.hv||r.hv[1],u=r&&r.boundingMode||"all";if((o=o||n).x=n.x,o.y=n.y,!s&&!l)return!1;if(u==="raw")a=n.type==="group"?new ve(0,0,+e.width||0,+e.height||0):n.getBoundingRect();else if(a=n.getBoundingRect(),n.needLocalTransform()){var h=n.getLocalTransform();(a=a.clone()).applyTransform(h)}var c=Vt(ae({width:a.width,height:a.height},e),t,i),p=s?c.x-a.x:0,d=l?c.y-a.y:0;return u==="raw"?(o.x=p,o.y=d):(o.x+=p,o.y+=d),o===n&&n.markRedraw(),!0}function Aa(n){var e=n.layoutMode||n.constructor.layoutMode;return Q(e)?e:e?{type:e}:null}function lo(n,e,t){var i=t&&t.ignoreSize;!W(i)&&(i=[i,i]);var r=a(Tl[0],0),o=a(Tl[1],1);function a(h,c){var p={},d=0,f={},g=0;if(Ml(h,function(m){f[m]=n[m]}),Ml(h,function(m){s(e,m)&&(p[m]=f[m]=e[m]),l(p,m)&&d++,l(f,m)&&g++}),i[c])return l(e,h[1])?f[h[2]]=null:l(e,h[2])&&(f[h[1]]=null),f;if(g!==2&&d){if(d>=2)return p;for(var v=0;v=0;l--)s=pe(s,r[l],!0);i.defaultOption=s}return i.defaultOption},e.prototype.getReferringComponents=function(t,i){var r=t+"Index",o=t+"Id";return aa(this.ecModel,t,{index:this.get(r,!0),id:this.get(o,!0)},i)},e.prototype.getBoxLayoutParams=function(){var t=this;return{left:t.get("left"),top:t.get("top"),right:t.get("right"),bottom:t.get("bottom"),width:t.get("width"),height:t.get("height")}},e.prototype.getZLevelKey=function(){return""},e.prototype.setZLevel=function(t){this.option.zlevel=t},e.protoInitialize=function(){var t=e.prototype;t.type="component",t.id="",t.name="",t.mainType="",t.subType="",t.componentIndex=0}(),e}(He);wv(uo,He),Hs(uo),function(n){var e={};n.registerSubTypeDefaulter=function(t,i){var r=Ln(t);e[r.main]=i},n.determineSubType=function(t,i){var r=i.type;if(!r){var o=Ln(t).main;n.hasSubTypes(t)&&e[o]&&(r=e[o](i))}return r}}(uo),function(n,e){function t(i,r){return i[r]||(i[r]={predecessor:[],successor:[]}),i[r]}n.topologicalTravel=function(i,r,o,a){if(i.length){var s=function(v){var y={},m=[];return A(v,function(x){var _=t(y,x),w=function(b,S){var M=[];return A(b,function(T){Me(S,T)>=0&&M.push(T)}),M}(_.originalDeps=e(x),v);_.entryCount=w.length,_.entryCount===0&&m.push(x),A(w,function(b){Me(_.predecessor,b)<0&&_.predecessor.push(b);var S=t(y,b);Me(S.successor,b)<0&&S.successor.push(x)})}),{graph:y,noEntryList:m}}(r),l=s.graph,u=s.noEntryList,h={};for(A(i,function(v){h[v]=!0});u.length;){var c=u.pop(),p=l[c],d=!!h[c];d&&(o.call(a,c,p.originalDeps.slice()),delete h[c]),A(p.successor,d?g:f)}A(h,function(){var v;throw v=Fs("Circular dependency may exists: ",h,i,r),new Error(v)})}function f(v){l[v].entryCount--,l[v].entryCount===0&&u.push(v)}function g(v){h[v]=!0,f(v)}}}(uo,function(n){var e=[];return A(uo.getClassesByMainType(n),function(t){e=e.concat(t.dependencies||t.prototype.dependencies||[])}),e=U(e,function(t){return Ln(t).main}),n!=="dataset"&&Me(e,"dataset")<=0&&e.unshift("dataset"),e});const Se=uo;var _m="";typeof navigator<"u"&&(_m=navigator.platform||"");var ho="rgba(0, 0, 0, 0.2)";const MC={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:ho,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:ho,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:ho,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:ho,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:ho,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:ho,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:_m.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,stateAnimation:{duration:300,easing:"cubicOut"},animation:"auto",animationDuration:1e3,animationDurationUpdate:500,animationEasing:"cubicInOut",animationEasingUpdate:"cubicInOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1};var up=ee(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),on="original",Dt="arrayRows",xn="objectRows",Bn="keyedColumns",ni="typedArray",wm="unknown",Vn="column",co="row",at={Must:1,Might:2,Not:3},bm=ze();function TC(n,e,t){var i={},r=hp(e);if(!r||!n)return i;var o,a,s=[],l=[],u=e.ecModel,h=bm(u).datasetMap,c=r.uid+"_"+t.seriesLayoutBy;A(n=n.slice(),function(g,v){var y=Q(g)?g:n[v]={name:g};y.type==="ordinal"&&o==null&&(o=v,a=f(y)),i[y.name]=[]});var p=h.get(c)||h.set(c,{categoryWayDim:a,valueWayDim:0});function d(g,v,y){for(var m=0;md)return p[g];return p[f-1]}(i,a):t;if((h=h||t)&&h.length){var c=h[l];return r&&(u[r]=c),s.paletteIdx=(l+1)%h.length,c}}var dp="\0_ec_inner",IC={grid:"GridComponent",polar:"PolarComponent",geo:"GeoComponent",singleAxis:"SingleAxisComponent",parallel:"ParallelComponent",calendar:"CalendarComponent",graphic:"GraphicComponent",toolbox:"ToolboxComponent",tooltip:"TooltipComponent",axisPointer:"AxisPointerComponent",brush:"BrushComponent",title:"TitleComponent",timeline:"TimelineComponent",markPoint:"MarkPointComponent",markLine:"MarkLineComponent",markArea:"MarkAreaComponent",legend:"LegendComponent",dataZoom:"DataZoomComponent",visualMap:"VisualMapComponent",xAxis:"GridComponent",yAxis:"GridComponent",angleAxis:"PolarComponent",radiusAxis:"PolarComponent"},AC={line:"LineChart",bar:"BarChart",pie:"PieChart",scatter:"ScatterChart",radar:"RadarChart",map:"MapChart",tree:"TreeChart",treemap:"TreemapChart",graph:"GraphChart",gauge:"GaugeChart",funnel:"FunnelChart",parallel:"ParallelChart",sankey:"SankeyChart",boxplot:"BoxplotChart",candlestick:"CandlestickChart",effectScatter:"EffectScatterChart",lines:"LinesChart",heatmap:"HeatmapChart",pictorialBar:"PictorialBarChart",themeRiver:"ThemeRiverChart",sunburst:"SunburstChart",custom:"CustomChart"},Al={},km=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.init=function(t,i,r,o,a,s){o=o||{},this.option=null,this._theme=new He(o),this._locale=new He(a),this._optionManager=s},e.prototype.setOption=function(t,i,r){le(t!=null,"option is null/undefined"),le(t[dp]!==1,"please use chart.getOption()");var o=Om(i);this._optionManager.setOption(t,r,o),this._resetOption(null,o)},e.prototype.resetOption=function(t,i){return this._resetOption(t,Om(i))},e.prototype._resetOption=function(t,i){var r=!1,o=this._optionManager;if(!t||t==="recreate"){var a=o.mountOption(t==="recreate");A(a,function(u,h){if(!Se.hasClass(h)){var c=IC[h];c&&!Al[c]&&(mt("Component "+h+` is used but not imported. import { `+c+` } from 'echarts/components'; echarts.use([`+c+"]);"),Al[c]=!0)}}),this.option&&t!=="recreate"?(this.restoreData(),this._mergeOption(a,i)):Cm(this,a),r=!0}if(t!=="timeline"&&t!=="media"||this.restoreData(),!t||t==="recreate"||t==="timeline"){var s=o.getTimelineOption(this);s&&(r=!0,this._mergeOption(s,i))}if(!t||t==="recreate"||t==="media"){var l=o.getMediaOption(this);l.length&&A(l,function(u){r=!0,this._mergeOption(u,i)},this)}return r},e.prototype.mergeOption=function(t){this._mergeOption(t,null)},e.prototype._mergeOption=function(t,i){var r=this.option,o=this._componentsMap,a=this._componentsCount,s=[],l=ee(),u=i&&i.replaceMergeMainTypeMap;bm(this).datasetMap=ee(),A(t,function(h,c){h!=null&&(Se.hasClass(c)?c&&(s.push(c),l.set(c,!0)):r[c]=r[c]==null?ie(h):pe(r[c],h,!0))}),u&&u.each(function(h,c){Se.hasClass(c)&&!l.get(c)&&(s.push(c),l.set(c,!0))}),Se.topologicalTravel(s,Se.getAllClassMainTypes(),function(h){var c=function(_,w,b){var S=cp.get(w);if(!S)return b;var M=S(_);if(!M)return b;for(var T=0;T=0;l--)o[l]&&!Ur(o[l])?s=!0:(o[l]=null,!s&&a--);o.length=a,t[r]=o}}),delete t[dp],t},e.prototype.getTheme=function(){return this._theme},e.prototype.getLocaleModel=function(){return this._locale},e.prototype.setUpdatePayload=function(t){this._payload=t},e.prototype.getUpdatePayload=function(){return this._payload},e.prototype.getComponent=function(t,i){var r=this._componentsMap.get(t);if(r){var o=r[i||0];if(o)return o;if(i==null){for(var a=0;a=c:p==="max"?h<=c:h===c})(i[u],o,l)||(r=!1)}}),r}const RC=PC;var an=A,ka=Q,Nm=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function gp(n){var e=n&&n.itemStyle;if(e)for(var t=0,i=Nm.length;t=0;v--){var y=n[v];if(s||(d=y.data.rawIndexOf(y.stackedByDimension,p)),d>=0){var m=y.data.getByRawIndex(y.stackResultDimension,d);if(l==="all"||l==="positive"&&m>0||l==="negative"&&m<0||l==="samesign"&&f>=0&&m>0||l==="samesign"&&f<=0&&m<0){f=jM(f,m),g=m;break}}}return i[0]=f,i[1]=g,i})})}var po,fo,go,Wm,Ym,kl=function(n){this.data=n.data||(n.sourceFormat===Bn?{}:[]),this.sourceFormat=n.sourceFormat||wm,this.seriesLayoutBy=n.seriesLayoutBy||Vn,this.startIndex=n.startIndex||0,this.dimensionsDetectedCount=n.dimensionsDetectedCount,this.metaRawOption=n.metaRawOption;var e=this.dimensionsDefine=n.dimensionsDefine;if(e)for(var t=0;tg&&(g=x)}d[0]=f,d[1]=g}},r=function(){return this._data?this._data.length/this._dimSize:0};function o(a){for(var s=0;s=0&&(d=a.interpolatedValue[f])}return d!=null?d+"":""}):void 0},n.prototype.getRawValue=function(e,t){return vo(this.getData(t),e)},n.prototype.formatTooltip=function(e,t,i){},n}();function t0(n){var e,t;return Q(n)?n.type?t=n:console.warn("The return type of `formatTooltip` is not supported: "+Fs(n)):e=n,{text:e,frag:t}}function Oa(n){return new YC(n)}var YC=function(){function n(e){e=e||{},this._reset=e.reset,this._plan=e.plan,this._count=e.count,this._onDirty=e.onDirty,this._dirty=!0}return n.prototype.perform=function(e){var t,i=this._upstream,r=e&&e.skip;if(this._dirty&&i){var o=this.context;o.data=o.outputData=i.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this),this._plan&&!r&&(t=this._plan(this.context));var a,s=c(this._modBy),l=this._modDataCount||0,u=c(e&&e.modBy),h=e&&e.modDataCount||0;function c(m){return!(m>=1)&&(m=1),m}s===u&&l===h||(t="reset"),(this._dirty||t==="reset")&&(this._dirty=!1,a=this._doReset(r)),this._modBy=u,this._modDataCount=h;var p=e&&e.step;if(i?(le(i._outputDueEnd!=null),this._dueEnd=i._outputDueEnd):(le(!this._progress||this._count),this._dueEnd=this._count?this._count(this.context):1/0),this._progress){var d=this._dueIndex,f=Math.min(p!=null?this._dueIndex+p:1/0,this._dueEnd);if(!r&&(a||d=this._outputDueEnd),this._outputDueEnd=y}else this._dueIndex=this._outputDueEnd=this._settedOutputEnd!=null?this._settedOutputEnd:this._dueEnd;return this.unfinished()},n.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},n.prototype._doProgress=function(e,t,i,r,o){n0.reset(t,i,r,o),this._callingProgress=e,this._callingProgress({start:t,end:i,count:i-t,next:n0.next},this.context)},n.prototype._doReset=function(e){var t,i;this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null,!e&&this._reset&&((t=this._reset(this.context))&&t.progress&&(i=t.forceFirstProgress,t=t.progress),W(t)&&!t.length&&(t=null)),this._progress=t,this._modBy=this._modDataCount=null;var r=this._downstream;return r&&r.dirty(),i},n.prototype.unfinished=function(){return this._progress&&this._dueIndex1&&i>0?s:a}};return o;function a(){return e=n?null:lr?-this._resultLT:0},n}(),XC=function(){function n(){}return n.prototype.getRawData=function(){throw new Error("not supported")},n.prototype.getRawDataItem=function(e){throw new Error("not supported")},n.prototype.cloneRawData=function(){},n.prototype.getDimensionInfo=function(e){},n.prototype.cloneAllDimensionInfo=function(){},n.prototype.count=function(){},n.prototype.retrieveValue=function(e,t){},n.prototype.retrieveValueFromItem=function(e,t){},n.prototype.convertValue=function(e,t){return Ll(e,t)},n}();function jC(n){var e=n.sourceFormat;return bp(e)||It("`getRawData` is not supported in source format "+e),n.data}function ZC(n){var e=n.sourceFormat,t=n.data;if(bp(e)||It("`cloneRawData` is not supported in source format "+e),e===Dt){for(var i=[],r=0,o=t.length;r65535?$C:QC}function s0(n,e,t,i,r){var o=a0[t||"float"];if(r){var a=n[e],s=a&&a.length;if(s!==i){for(var l=new o(i),u=0;uv[1]&&(v[1]=g)}return this._rawCount=this._count=l,{start:s,end:l}},n.prototype._initDataFromProvider=function(e,t,i){for(var r=this._provider,o=this._chunks,a=this._dimensions,s=a.length,l=this._rawExtent,u=U(a,function(m){return m.property}),h=0;hy[1]&&(y[1]=v)}}!r.persistent&&r.clean&&r.clean(),this._rawCount=this._count=t,this._extent=[]},n.prototype.count=function(){return this._count},n.prototype.get=function(e,t){if(!(t>=0&&t=0&&t=this._rawCount||e<0)return-1;if(!this._indices)return e;var t=this._indices,i=t[e];if(i!=null&&ie))return a;o=a-1}}return-1},n.prototype.indicesOfNearest=function(e,t,i){var r=this._chunks[e],o=[];if(!r)return o;i==null&&(i=1/0);for(var a=1/0,s=-1,l=0,u=0,h=this.count();u=0&&s<0)&&(a=p,s=c,l=0),c===s&&(o[l++]=u))}return o.length=l,o},n.prototype.getIndices=function(){var e,t=this._indices;if(t){var i=t.constructor,r=this._count;if(i===Array){e=new i(r);for(var o=0;o=h&&_<=c||isNaN(_))&&(s[l++]=f),f++;d=!0}else if(o===2){g=p[r[0]];var y=p[r[1]],m=e[r[1]][0],x=e[r[1]][1];for(v=0;v=h&&_<=c||isNaN(_))&&(w>=m&&w<=x||isNaN(w))&&(s[l++]=f),f++}d=!0}}if(!d)if(o===1)for(v=0;v=h&&_<=c||isNaN(_))&&(s[l++]=b)}else for(v=0;ve[T][1])&&(S=!1)}S&&(s[l++]=t.getRawIndex(v))}return ly[1]&&(y[1]=v)}}},n.prototype.lttbDownSample=function(e,t){var i,r,o,a=this.clone([e],!0),s=a._chunks[e],l=this.count(),u=0,h=Math.floor(1/t),c=this.getRawIndex(0),p=new(Ra(this._rawCount))(Math.min(2*(Math.ceil(l/h)+2),l));p[u++]=c;for(var d=1;di&&(i=r,o=C)}T>0&&Th-f&&(l=h-f,s.length=l);for(var g=0;gc[1]&&(c[1]=y),p[d++]=m}return o._count=d,o._indices=p,o._updateGetRawIdx(),o},n.prototype.each=function(e,t){if(this._count)for(var i=e.length,r=this._chunks,o=0,a=this.count();os&&(s=u)}return r=[a,s],this._extent[e]=r,r},n.prototype.getRawDataItem=function(e){var t=this.getRawIndex(e);if(this._provider.persistent)return this._provider.getItem(t);for(var i=[],r=this._chunks,o=0;o=0?this._indices[e]:-1},n.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},n.internalField=function(){function e(t,i,r,o){return Ll(t[o],this._dimensions[o])}Sp={arrayRows:e,objectRows:function(t,i,r,o){return Ll(t[i],this._dimensions[o])},keyedColumns:e,original:function(t,i,r,o){var a=t&&(t.value==null?t:t.value);return Ll(a instanceof Array?a[o]:a,this._dimensions[o])},typedArray:function(t,i,r,o){return t[o]}}}(),n}();const Mp=eI;var l0=function(){function n(e){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=e}return n.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},n.prototype._setLocalSource=function(e,t){this._sourceList=e,this._upstreamSignList=t,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},n.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},n.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},n.prototype._createSource=function(){this._setLocalSource([],[]);var e,t,i=this._sourceHost,r=this._getUpstreamSourceManagers(),o=!!r.length;if(Ea(i)){var a=i,s=void 0,l=void 0,u=void 0;if(o){var h=r[0];h.prepareSource(),s=(u=h.getSource()).data,l=u.sourceFormat,t=[h._getVersionSign()]}else l=ct(s=a.get("data",!0))?ni:on,t=[];var c=this._getSourceMetaRawOption()||{},p=u&&u.metaRawOption||{},d=de(c.seriesLayoutBy,p.seriesLayoutBy)||null,f=de(c.sourceHeader,p.sourceHeader),g=de(c.dimensions,p.dimensions);e=d!==p.seriesLayoutBy||!!f!=!!p.sourceHeader||g?[mp(s,{seriesLayoutBy:d,sourceHeader:f,dimensions:g},l)]:[]}else{var v=i;if(o){var y=this._applyTransform(r);e=y.sourceList,t=y.upstreamSignList}else e=[mp(v.get("source",!0),this._getSourceMetaRawOption(),null)],t=[]}le(e&&t),this._setLocalSource(e,t)},n.prototype._applyTransform=function(e){var t,i=this._sourceHost,r=i.get("transform",!0),o=i.get("fromTransformResult",!0);le(o!=null||r!=null),o!=null&&e.length!==1&&h0("When using `fromTransformResult`, there should be only one upstream dataset");var a,s=[],l=[];return A(e,function(u){u.prepareSource();var h=u.getSource(o||0);o==null||h||h0("Can not retrieve result by `fromTransformResult`: "+o),s.push(h),l.push(u._getVersionSign())}),r?t=function(u,h,c){var p=Qe(u),d=p.length;d||It("If `transform` declared, it should at least contain one transform.");for(var f=0,g=d;f1||t>0&&!n.noHeader;return A(n.blocks,function(r){var o=f0(r);o>=e&&(e=o+ +(i&&(!o||Tp(r)&&!r.noHeader)))}),e}return 0}function iI(n,e,t,i){var r,o=e.noHeader,a=(r=f0(e),{html:tI[r],richText:nI[r]}),s=[],l=e.blocks||[];le(!l||W(l)),l=l||[];var u=n.orderMode;if(e.sortBlocks&&u){l=l.slice();var h={valueAsc:"asc",valueDesc:"desc"};if(Yt(h,u)){var c=new UC(h[u],null);l.sort(function(g,v){return c.evaluate(g.sortParam,v.sortParam)})}else u==="seriesDesc"&&l.reverse()}A(l,function(g,v){var y=e.valueFormatter,m=d0(g)(y?G(G({},n),{valueFormatter:y}):n,g,v>0?a.html:0,i);m!=null&&s.push(m)});var p=n.renderMode==="richText"?s.join(a.richText):Cp(s.join(""),o?t:a.html);if(o)return p;var d=op(e.header,"ordinal",n.useUTC),f=p0(i,n.renderMode).nameStyle;return n.renderMode==="richText"?v0(n,d,f)+a.richText+p:Cp('
'+Et(d)+"
"+p,t)}function rI(n,e,t,i){var r=n.renderMode,o=e.noName,a=e.noValue,s=!e.markerType,l=e.name,u=n.useUTC,h=e.valueFormatter||n.valueFormatter||function(_){return U(_=W(_)?_:[_],function(w,b){return op(w,W(d)?d[b]:d,u)})};if(!o||!a){var c=s?"":n.markupStyleCreator.makeTooltipMarker(e.markerType,e.markerColor||"#333",r),p=o?"":op(l,"ordinal",u),d=e.valueType,f=a?[]:h(e.value,e.dataIndex),g=!s||!o,v=!s&&o,y=p0(i,r),m=y.nameStyle,x=y.valueStyle;return r==="richText"?(s?"":c)+(o?"":v0(n,p,m))+(a?"":function(_,w,b,S,M){var T=[M],C=S?10:20;return b&&T.push({padding:[0,0,0,C],align:"right"}),_.markupStyleCreator.wrapRichTextStyle(W(w)?w.join(" "):w,T)}(n,f,g,v,x)):Cp((s?"":c)+(o?"":function(_,w,b){return''+Et(_)+""}(p,!s,m))+(a?"":function(_,w,b,S){var M=b?"10px":"20px",T=w?"float:right;margin-left:"+M:"";return _=W(_)?_:[_],''+U(_,function(C){return Et(C)}).join("  ")+""}(f,g,v,x)),t)}}function g0(n,e,t,i,r,o){if(n)return d0(n)({useUTC:r,renderMode:t,orderMode:i,markupStyleCreator:e,valueFormatter:n.valueFormatter},n,0,o)}function Cp(n,e){return'
'+n+'
'}function v0(n,e,t){return n.markupStyleCreator.wrapRichTextStyle(e,t)}function y0(n,e){return gr(n.getData().getItemVisual(e,"style")[n.visualDrawType])}function m0(n,e){var t=n.get("padding");return t??(e==="richText"?[8,10]:10)}var Ip=function(){function n(){this.richTextStyles={},this._nextStyleNameId=sv()}return n.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},n.prototype.makeTooltipMarker=function(e,t,i){var r=i==="richText"?this._generateStyleName():null,o=vm({color:t,type:e,renderMode:i,markerId:r});return j(o)?o:(le(r),this.richTextStyles[r]=o.style,o.content)},n.prototype.wrapRichTextStyle=function(e,t){var i={};W(t)?A(t,function(o){return G(i,o)}):G(i,t);var r=this._generateStyleName();return this.richTextStyles[r]=i,"{"+r+"|"+e+"}"},n}();function oI(n){var e,t,i,r,o=n.series,a=n.dataIndex,s=n.multipleSeries,l=o.getData(),u=l.mapDimensionsAll("defaultedTooltip"),h=u.length,c=o.getRawValue(a),p=W(c),d=y0(o,a);if(h>1||p&&!h){var f=function(_,w,b,S,M){var T=w.getData(),C=pn(_,function(O,E,k){var P=T.getDimensionInfo(k);return O||P&&P.tooltip!==!1&&P.displayName!=null},!1),I=[],D=[],L=[];function R(O,E){var k=T.getDimensionInfo(E);k&&k.otherDims.tooltip!==!1&&(C?L.push(ri("nameValue",{markerType:"subItem",markerColor:M,name:k.displayName,value:O,valueType:k.type})):(I.push(O),D.push(k.type)))}return S.length?A(S,function(O){R(vo(T,b,O),O)}):A(_,R),{inlineValues:I,inlineValueTypes:D,blocks:L}}(c,o,a,u,d);e=f.inlineValues,t=f.inlineValueTypes,i=f.blocks,r=f.inlineValues[0]}else if(h){var g=l.getDimensionInfo(u[0]);r=e=vo(l,a,u[0]),t=g.type}else r=e=p?c[0]:c;var v=nc(o),y=v&&o.name||"",m=l.getName(a),x=s?y:m;return ri("section",{header:y,noHeader:s||!v,sortParam:r,blocks:[ri("nameValue",{markerType:"item",markerColor:d,name:x,noName:!Wt(x),value:e,valueType:t,dataIndex:a})].concat(i||[])})}var Mi=ze();function Ol(n,e){return n.getName(e)||n.getId(e)}var Rl=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}return V(e,n),e.prototype.init=function(t,i,r){this.seriesIndex=this.componentIndex,this.dataTask=Oa({count:aI,reset:sI}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(t,r),(Mi(this).sourceManager=new l0(this)).prepareSource();var o=this.getInitialData(t,r);_0(o,this),this.dataTask.context.data=o,le(o,"getInitialData returned invalid data."),Mi(this).dataBeforeProcessed=o,x0(this),this._initSelectedMapFromData(o)},e.prototype.mergeDefaultAndTheme=function(t,i){var r=Aa(this),o=r?Cl(t):{},a=this.subType;Se.hasClass(a)&&(a+="Series"),pe(t,i.getTheme().get(this.subType)),pe(t,this.getDefaultOption()),Gs(t,"label",["show"]),this.fillDataTextStyle(t.data),r&&lo(t,o,r)},e.prototype.mergeOption=function(t,i){t=pe(this.option,t,!0),this.fillDataTextStyle(t.data);var r=Aa(this);r&&lo(this.option,t,r);var o=Mi(this).sourceManager;o.dirty(),o.prepareSource();var a=this.getInitialData(t,i);_0(a,this),this.dataTask.dirty(),this.dataTask.context.data=a,Mi(this).dataBeforeProcessed=a,x0(this),this._initSelectedMapFromData(a)},e.prototype.fillDataTextStyle=function(t){if(t&&!ct(t))for(var i=["show"],r=0;rthis.getShallow("animationThreshold")&&(i=!1),!!i},e.prototype.restoreData=function(){this.dataTask.dirty()},e.prototype.getColorFromPalette=function(t,i,r){var o=this.ecModel,a=pp.prototype.getColorFromPalette.call(this,t,i,r);return a||(a=o.getColorFromPalette(t,i,r)),a},e.prototype.coordDimToDataDim=function(t){return this.getRawData().mapDimensionsAll(t)},e.prototype.getProgressive=function(){return this.get("progressive")},e.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},e.prototype.select=function(t,i){this._innerSelect(this.getData(i),t)},e.prototype.unselect=function(t,i){var r=this.option.selectedMap;if(r){var o=this.option.selectedMode,a=this.getData(i);if(o==="series"||r==="all")return this.option.selectedMap={},void(this._selectedDataIndicesMap={});for(var s=0;s=0&&r.push(a)}return r},e.prototype.isSelected=function(t,i){var r=this.option.selectedMap;if(!r)return!1;var o=this.getData(i);return(r==="all"||r[Ol(o,t)])&&!o.getItemModel(t).get(["select","disabled"])},e.prototype.isUniversalTransitionEnabled=function(){if(this.__universalTransitionEnabled)return!0;var t=this.option.universalTransition;return!!t&&(t===!0||t&&t.enabled)},e.prototype._innerSelect=function(t,i){var r,o,a=this.option,s=a.selectedMode,l=i.length;if(s&&l){if(s==="series")a.selectedMap="all";else if(s==="multiple"){Q(a.selectedMap)||(a.selectedMap={});for(var u=a.selectedMap,h=0;h0&&this._innerSelect(t,i)}},e.registerClass=function(t){return Se.registerClass(t)},e.protoInitialize=function(){var t=e.prototype;t.type="series.__base__",t.seriesIndex=0,t.ignoreStyleOnData=!1,t.hasSymbolVisual=!1,t.defaultSymbol="circle",t.visualStyleAccessPath="itemStyle",t.visualDrawType="fill"}(),e}(Se);function x0(n){var e=n.name;nc(n)||(n.name=function(t){var i=t.getRawData(),r=i.mapDimensionsAll("seriesName"),o=[];return A(r,function(a){var s=i.getDimensionInfo(a);s.displayName&&o.push(s.displayName)}),o.join(" ")}(n)||e)}function aI(n){return n.model.getRawData().count()}function sI(n){var e=n.model;return e.setData(e.getRawData().cloneShallow()),lI}function lI(n,e){e.outputData&&n.end>e.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function _0(n,e){A(ig(n.CHANGABLE_METHODS,n.DOWNSAMPLE_METHODS),function(t){n.wrapMethod(t,Te(uI,e))})}function uI(n,e){var t=Ap(n);return t&&t.setOutputEnd((e||this).count()),e}function Ap(n){var e=(n.ecModel||{}).scheduler,t=e&&e.getPipeline(n.uid);if(t){var i=t.currentTask;if(i){var r=i.agentStubMap;r&&(i=r.get(n.uid))}return i}}ht(Rl,WC),ht(Rl,pp),wv(Rl,Se);const kt=Rl;var Dp=function(){function n(){this.group=new me,this.uid=ro("viewComponent")}return n.prototype.init=function(e,t){},n.prototype.render=function(e,t,i,r){},n.prototype.dispose=function(e,t){},n.prototype.updateView=function(e,t,i,r){},n.prototype.updateLayout=function(e,t,i,r){},n.prototype.updateVisual=function(e,t,i,r){},n.prototype.toggleBlurSeries=function(e,t,i){},n.prototype.eachRendered=function(e){var t=this.group;t&&t.traverse(e)},n}();rc(Dp),Hs(Dp);const Ze=Dp;function kp(){var n=ze();return function(e){var t=n(e),i=e.pipelineContext,r=!!t.large,o=!!t.progressiveRender,a=t.large=!(!i||!i.large),s=t.progressiveRender=!(!i||!i.progressiveRender);return!(r===a&&o===s)&&"reset"}}var w0=ze(),hI=kp(),Lp=function(){function n(){this.group=new me,this.uid=ro("viewChart"),this.renderTask=Oa({plan:cI,reset:pI}),this.renderTask.context={view:this}}return n.prototype.init=function(e,t){},n.prototype.render=function(e,t,i,r){throw new Error("render method must been implemented")},n.prototype.highlight=function(e,t,i,r){var o=e.getData(r&&r.dataType);o?S0(o,r,"emphasis"):mt("Unknown dataType "+r.dataType)},n.prototype.downplay=function(e,t,i,r){var o=e.getData(r&&r.dataType);o?S0(o,r,"normal"):mt("Unknown dataType "+r.dataType)},n.prototype.remove=function(e,t){this.group.removeAll()},n.prototype.dispose=function(e,t){},n.prototype.updateView=function(e,t,i,r){this.render(e,t,i,r)},n.prototype.updateLayout=function(e,t,i,r){this.render(e,t,i,r)},n.prototype.updateVisual=function(e,t,i,r){this.render(e,t,i,r)},n.prototype.eachRendered=function(e){fl(this.group,e)},n.markUpdateMethod=function(e,t){w0(e).updateMethod=t},n.protoInitialize=void(n.prototype.type="chart"),n}();function b0(n,e,t){n&&$r(n)&&(e==="emphasis"?Kr:Jr)(n,t)}function S0(n,e,t){var i=$i(n,e),r=e&&e.highlightKey!=null?function(o){var a=Jv[o];return a==null&&Kv<=32&&(a=Jv[o]=Kv++),a}(e.highlightKey):null;i!=null?A(Qe(i),function(o){b0(n.getItemGraphicEl(o),t,r)}):n.eachItemGraphicEl(function(o){b0(o,t,r)})}function cI(n){return hI(n.model)}function pI(n){var e=n.model,t=n.ecModel,i=n.api,r=n.payload,o=e.pipelineContext.progressiveRender,a=n.view,s=r&&w0(r).updateMethod,l=o?"incrementalPrepareRender":s&&a[s]?s:"render";return l!=="render"&&a[l](e,t,i,r),dI[l]}rc(Lp,["dispose"]),Hs(Lp);var dI={incrementalPrepareRender:{progress:function(n,e){e.view.incrementalRender(n,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(n,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}};const st=Lp;var El="\0__throttleOriginMethod",M0="\0__throttleRate",T0="\0__throttleType";function Nl(n,e,t){var i,r,o,a,s,l=0,u=0,h=null;function c(){u=new Date().getTime(),h=null,n.apply(o,a||[])}e=e||0;var p=function(){for(var d=[],f=0;f=0?c():h=setTimeout(c,-r),l=i};return p.clear=function(){h&&(clearTimeout(h),h=null)},p.debounceNextCall=function(d){s=d},p}function Pp(n,e,t,i){var r=n[e];if(r){var o=r[El]||r,a=r[T0];if(r[M0]!==t||a!==i){if(t==null||!i)return n[e]=o;(r=n[e]=Nl(o,t,i==="debounce"))[El]=o,r[T0]=i,r[M0]=t}return r}}function zl(n,e){var t=n[e];t&&t[El]&&(t.clear&&t.clear(),n[e]=t[El])}var C0=ze(),I0={itemStyle:Xr(nm,!0),lineStyle:Xr(tm,!0)},fI={lineStyle:"stroke",itemStyle:"fill"};function A0(n,e){var t=n.visualStyleMapper||I0[e];return t||(console.warn("Unknown style type '"+e+"'."),I0.itemStyle)}function D0(n,e){var t=n.visualDrawType||fI[e];return t||(console.warn("Unknown style type '"+e+"'."),"fill")}var gI={createOnAllSeries:!0,performRawSeries:!0,reset:function(n,e){var t=n.getData(),i=n.visualStyleAccessPath||"itemStyle",r=n.getModel(i),o=A0(n,i)(r),a=r.getShallow("decal");a&&(t.setVisual("decal",a),a.dirty=!0);var s=D0(n,i),l=o[s],u=re(l)?l:null,h=o.fill==="auto"||o.stroke==="auto";if(!o[s]||u||h){var c=n.getColorFromPalette(n.name,null,e.getSeriesCount());o[s]||(o[s]=c,t.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||re(o.fill)?c:o.fill,o.stroke=o.stroke==="auto"||re(o.stroke)?c:o.stroke}if(t.setVisual("style",o),t.setVisual("drawType",s),!e.isSeriesFiltered(n)&&u)return t.setVisual("colorFromPalette",!1),{dataEach:function(p,d){var f=n.getDataParams(d),g=G({},o);g[s]=u(f),p.setItemVisual(d,"style",g)}}}},Na=new He,vI={createOnAllSeries:!0,performRawSeries:!0,reset:function(n,e){if(!n.ignoreStyleOnData&&!e.isSeriesFiltered(n)){var t=n.getData(),i=n.visualStyleAccessPath||"itemStyle",r=A0(n,i),o=t.getVisual("drawType");return{dataEach:t.hasItemOption?function(a,s){var l=a.getRawDataItem(s);if(l&&l[i]){Na.option=l[i];var u=r(Na);G(a.ensureUniqueItemVisual(s,"style"),u),Na.option.decal&&(a.setItemVisual(s,"decal",Na.option.decal),Na.option.decal.dirty=!0),o in u&&a.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},yI={performRawSeries:!0,overallReset:function(n){var e=ee();n.eachSeries(function(t){var i=t.getColorBy();if(!t.isColorBySeries()){var r=t.type+"-"+i,o=e.get(r);o||(o={},e.set(r,o)),C0(t).scope=o}}),n.eachSeries(function(t){if(!t.isColorBySeries()&&!n.isSeriesFiltered(t)){var i=t.getRawData(),r={},o=t.getData(),a=C0(t).scope,s=t.visualStyleAccessPath||"itemStyle",l=D0(t,s);o.each(function(u){var h=o.getRawIndex(u);r[h]=u}),i.each(function(u){var h=r[u];if(o.getItemVisual(h,"colorFromPalette")){var c=o.ensureUniqueItemVisual(h,"style"),p=i.getName(u)||u+"",d=i.count();c[l]=t.getColorFromPalette(p,a,d)}})}})}},Bl=Math.PI,mI=function(){function n(e,t,i,r){this._stageTaskMap=ee(),this.ecInstance=e,this.api=t,i=this._dataProcessorHandlers=i.slice(),r=this._visualHandlers=r.slice(),this._allHandlers=i.concat(r)}return n.prototype.restoreData=function(e,t){e.restoreData(t),this._stageTaskMap.each(function(i){var r=i.overallTask;r&&r.dirty()})},n.prototype.getPerformArgs=function(e,t){if(e.__pipeline){var i=this._pipelineMap.get(e.__pipeline.id),r=i.context,o=!t&&i.progressiveEnabled&&(!r||r.progressiveRender)&&e.__idxInPipeline>i.blockIndex?i.step:null,a=r&&r.modDataCount;return{step:o,modBy:a!=null?Math.ceil(a/o):null,modDataCount:a}}},n.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},n.prototype.updateStreamModes=function(e,t){var i=this._pipelineMap.get(e.uid),r=e.getData().count(),o=i.progressiveEnabled&&t.incrementalPrepareRender&&r>=i.threshold,a=e.get("large")&&r>=e.get("largeThreshold"),s=e.get("progressiveChunkMode")==="mod"?r:null;e.pipelineContext=i.context={progressiveRender:o,modDataCount:s,large:a}},n.prototype.restorePipelines=function(e){var t=this,i=t._pipelineMap=ee();e.eachSeries(function(r){var o=r.getProgressive(),a=r.uid;i.set(a,{id:a,head:null,tail:null,threshold:r.getProgressiveThreshold(),progressiveEnabled:o&&!(r.preventIncremental&&r.preventIncremental()),blockIndex:-1,step:Math.round(o||700),count:0}),t._pipe(r,r.dataTask)})},n.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,t=this.api.getModel(),i=this.api;A(this._allHandlers,function(r){var o=e.get(r.uid)||e.set(r.uid,{});le(!(r.reset&&r.overallReset),'"reset" and "overallReset" must not be both specified.'),r.reset&&this._createSeriesStageTask(r,o,t,i),r.overallReset&&this._createOverallStageTask(r,o,t,i)},this)},n.prototype.prepareView=function(e,t,i,r){var o=e.renderTask,a=o.context;a.model=t,a.ecModel=i,a.api=r,o.__block=!e.incrementalPrepareRender,this._pipe(t,o)},n.prototype.performDataProcessorTasks=function(e,t){this._performStageTasks(this._dataProcessorHandlers,e,t,{block:!0})},n.prototype.performVisualTasks=function(e,t,i){this._performStageTasks(this._visualHandlers,e,t,i)},n.prototype._performStageTasks=function(e,t,i,r){r=r||{};var o=!1,a=this;function s(l,u){return l.setDirty&&(!l.dirtyMap||l.dirtyMap.get(u.__pipeline.id))}A(e,function(l,u){if(!r.visualType||r.visualType===l.visualType){var h=a._stageTaskMap.get(l.uid),c=h.seriesTaskMap,p=h.overallTask;if(p){var d,f=p.agentStubMap;f.each(function(v){s(r,v)&&(v.dirty(),d=!0)}),d&&p.dirty(),a.updatePayload(p,i);var g=a.getPerformArgs(p,r.block);f.each(function(v){v.perform(g)}),p.perform(g)&&(o=!0)}else c&&c.each(function(v,y){s(r,v)&&v.dirty();var m=a.getPerformArgs(v,r.block);m.skip=!l.performRawSeries&&t.isSeriesFiltered(v.context.model),a.updatePayload(v,i),v.perform(m)&&(o=!0)})}}),this.unfinished=o||this.unfinished},n.prototype.performSeriesTasks=function(e){var t;e.eachSeries(function(i){t=i.dataTask.perform()||t}),this.unfinished=t||this.unfinished},n.prototype.plan=function(){this._pipelineMap.each(function(e){var t=e.tail;do{if(t.__block){e.blockIndex=t.__idxInPipeline;break}t=t.getUpstream()}while(t)})},n.prototype.updatePayload=function(e,t){t!=="remain"&&(e.context.payload=t)},n.prototype._createSeriesStageTask=function(e,t,i,r){var o=this,a=t.seriesTaskMap,s=t.seriesTaskMap=ee(),l=e.seriesType,u=e.getTargetSeries;function h(c){var p=c.uid,d=s.set(p,a&&a.get(p)||Oa({plan:SI,reset:MI,count:CI}));d.context={model:c,ecModel:i,api:r,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:o},o._pipe(c,d)}e.createOnAllSeries?i.eachRawSeries(h):l?i.eachRawSeriesByType(l,h):u&&u(i,r).each(h)},n.prototype._createOverallStageTask=function(e,t,i,r){var o=this,a=t.overallTask=t.overallTask||Oa({reset:xI});a.context={ecModel:i,api:r,overallReset:e.overallReset,scheduler:o};var s=a.agentStubMap,l=a.agentStubMap=ee(),u=e.seriesType,h=e.getTargetSeries,c=!0,p=!1;function d(f){var g=f.uid,v=l.set(g,s&&s.get(g)||(p=!0,Oa({reset:_I,onDirty:bI})));v.context={model:f,overallProgress:c},v.agent=a,v.__block=c,o._pipe(f,v)}le(!e.createOnAllSeries,'"createOnAllSeries" is not supported for "overallReset", because it will block all streams.'),u?i.eachRawSeriesByType(u,d):h?h(i,r).each(d):(c=!1,A(i.getSeries(),d)),p&&a.dirty()},n.prototype._pipe=function(e,t){var i=e.uid,r=this._pipelineMap.get(i);!r.head&&(r.head=t),r.tail&&r.tail.pipe(t),r.tail=t,t.__idxInPipeline=r.count++,t.__pipeline=r},n.wrapStageHandler=function(e,t){return re(e)&&(e={overallReset:e,seriesType:II(e)}),e.uid=ro("stageHandler"),t&&(e.visualType=t),e},n}();function xI(n){n.overallReset(n.ecModel,n.api,n.payload)}function _I(n){return n.overallProgress&&wI}function wI(){this.agent.dirty(),this.getDownstream().dirty()}function bI(){this.agent&&this.agent.dirty()}function SI(n){return n.plan?n.plan(n.model,n.ecModel,n.api,n.payload):null}function MI(n){n.useClearVisual&&n.data.clearAllVisual();var e=n.resetDefines=Qe(n.reset(n.model,n.ecModel,n.api,n.payload));return e.length>1?U(e,function(t,i){return k0(i)}):TI}var TI=k0(0);function k0(n){return function(e,t){var i=t.data,r=t.resetDefines[n];if(r&&r.dataEach)for(var o=e.start;o0&&d===u.length-p.length){var f=u.slice(0,d);f!=="data"&&(t.mainType=f,t[p.toLowerCase()]=l,h=!0)}}s.hasOwnProperty(u)&&(i[u]=l,h=!0),h||(r[u]=l)})}return{cptQuery:t,dataQuery:i,otherQuery:r}},n.prototype.filter=function(e,t){var i=this.eventInfo;if(!i)return!0;var r=i.targetEl,o=i.packedEvent,a=i.model,s=i.view;if(!a||!s)return!0;var l=t.cptQuery,u=t.dataQuery;return h(l,a,"mainType")&&h(l,a,"subType")&&h(l,a,"index","componentIndex")&&h(l,a,"name")&&h(l,a,"id")&&h(u,o,"name")&&h(u,o,"dataIndex")&&h(u,o,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(e,t.otherQuery,r,o));function h(c,p,d,f){return c[d]==null||p[f||d]===c[d]}},n.prototype.afterTrigger=function(){this.eventInfo=null},n}(),Op=["symbol","symbolSize","symbolRotate","symbolOffset"],B0=Op.concat(["symbolKeepAspect"]),LI={createOnAllSeries:!0,performRawSeries:!0,reset:function(n,e){var t=n.getData();if(n.legendIcon&&t.setVisual("legendIcon",n.legendIcon),n.hasSymbolVisual){for(var i={},r={},o=!1,a=0;a=0&&mr(f)?f:.5,a.createRadialGradient(p,d,0,p,d,f)}(n,e,t):function(a,s,l){var u=s.x==null?0:s.x,h=s.x2==null?1:s.x2,c=s.y==null?0:s.y,p=s.y2==null?0:s.y2;return s.global||(u=u*l.width+l.x,h=h*l.width+l.x,c=c*l.height+l.y,p=p*l.height+l.y),u=mr(u)?u:0,h=mr(h)?h:1,c=mr(c)?c:0,p=mr(p)?p:0,a.createLinearGradient(u,c,h,p)}(n,e,t),r=e.colorStops,o=0;o0&&(e=i.lineDash,t=i.lineWidth,e&&e!=="solid"&&t>0?e==="dashed"?[4*t,2*t]:e==="dotted"?[t]:Le(e)?[e]:W(e)?e:null:null),o=i.lineDashOffset;if(r){var a=i.strokeNoScale&&n.getLineScale?n.getLineScale():1;a&&a!==1&&(r=U(r,function(s){return s/a}),o/=a)}return[r,o]}var YI=new _i(!0);function Wl(n){var e=n.stroke;return!(e==null||e==="none"||!(n.lineWidth>0))}function Y0(n){return typeof n=="string"&&n!=="none"}function Yl(n){var e=n.fill;return e!=null&&e!=="none"}function U0(n,e){if(e.fillOpacity!=null&&e.fillOpacity!==1){var t=n.globalAlpha;n.globalAlpha=e.fillOpacity*e.opacity,n.fill(),n.globalAlpha=t}else n.fill()}function X0(n,e){if(e.strokeOpacity!=null&&e.strokeOpacity!==1){var t=n.globalAlpha;n.globalAlpha=e.strokeOpacity*e.opacity,n.stroke(),n.globalAlpha=t}else n.stroke()}function zp(n,e,t){var i=bv(e.image,e.__image,t);if(Ws(i)){var r=n.createPattern(i,e.repeat||"repeat");if(typeof DOMMatrix=="function"&&r&&r.setTransform){var o=new DOMMatrix;o.translateSelf(e.x||0,e.y||0),o.rotateSelf(0,0,(e.rotation||0)*rg),o.scaleSelf(e.scaleX||1,e.scaleY||1),r.setTransform(o)}return r}}var j0=["shadowBlur","shadowOffsetX","shadowOffsetY"],Z0=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function q0(n,e,t,i,r){var o=!1;if(!i&&e===(t=t||{}))return!1;if(i||e.opacity!==t.opacity){Lt(n,r),o=!0;var a=Math.max(Math.min(e.opacity,1),0);n.globalAlpha=isNaN(a)?er.opacity:a}(i||e.blend!==t.blend)&&(o||(Lt(n,r),o=!0),n.globalCompositeOperation=e.blend||er.blend);for(var s=0;sa.maxTileWidth&&R("maxTileWidth"),L>a.maxTileHeight&&R("maxTileHeight"),{width:Math.max(1,Math.min(T,a.maxTileWidth)),height:Math.max(1,Math.min(L,a.maxTileHeight))}}(),M;w&&(w.width=S.width*t,w.height=S.height*t,g=w.getContext("2d")),function(){g&&(g.clearRect(0,0,w.width,w.height),a.backgroundColor&&(g.fillStyle=a.backgroundColor,g.fillRect(0,0,w.width,w.height)));for(var T=0,C=0;C0&&t.unfinished);t.unfinished||this._zr.flush()}}},e.prototype.getDom=function(){return this._dom},e.prototype.getId=function(){return this.id},e.prototype.getZr=function(){return this._zr},e.prototype.isSSR=function(){return this._ssr},e.prototype.setOption=function(t,i,r){if(this[gt])mt("`setOption` should not be called during main process.");else if(this._disposed)Ft(this.id);else{var o,a,s;if(Q(i)&&(r=i.lazyUpdate,o=i.silent,a=i.replaceMerge,s=i.transition,i=i.notMerge),this[gt]=!0,!this._model||i){var l=new RC(this._api),u=this._theme,h=this._model=new Rm;h.scheduler=this._scheduler,h.ssr=this._ssr,h.init(null,null,null,u,this._locale,l)}this._model.setOption(t,{replaceMerge:a},Kp);var c={seriesTransition:s,optionChanged:!0};if(r)this[Pt]={silent:o,updateParams:c},this[gt]=!1,this.getZr().wakeUp();else{try{mo(this),Ti.update.call(this,null,c)}catch(p){throw this[Pt]=null,this[gt]=!1,p}this._ssr||this._zr.flush(),this[Pt]=null,this[gt]=!1,Va.call(this,o),Fa.call(this,o)}}},e.prototype.setTheme=function(){vn("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},e.prototype.getModel=function(){return this._model},e.prototype.getOption=function(){return this._model&&this._model.getOption()},e.prototype.getWidth=function(){return this._zr.getWidth()},e.prototype.getHeight=function(){return this._zr.getHeight()},e.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||_e.hasGlobalWindow&&window.devicePixelRatio||1},e.prototype.getRenderedCanvas=function(t){return $e("getRenderedCanvas","renderToCanvas"),this.renderToCanvas(t)},e.prototype.renderToCanvas=function(t){t=t||{};var i=this._zr.painter;if(i.type!=="canvas")throw new Error("renderToCanvas can only be used in the canvas renderer.");return i.getRenderedCanvas({backgroundColor:t.backgroundColor||this._model.get("backgroundColor"),pixelRatio:t.pixelRatio||this.getDevicePixelRatio()})},e.prototype.renderToSVGString=function(t){t=t||{};var i=this._zr.painter;if(i.type!=="svg")throw new Error("renderToSVGString can only be used in the svg renderer.");return i.renderToString({useViewBox:t.useViewBox})},e.prototype.getSvgDataURL=function(){if(_e.svgSupported){var t=this._zr;return A(t.storage.getDisplayList(),function(i){i.stopAnimation(null,!0)}),t.painter.toDataURL()}},e.prototype.getDataURL=function(t){if(!this._disposed){var i=(t=t||{}).excludeComponents,r=this._model,o=[],a=this;A(i,function(l){r.eachComponent({mainType:l},function(u){var h=a._componentsMap[u.__viewId];h.group.ignore||(o.push(h),h.group.ignore=!0)})});var s=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return A(o,function(l){l.group.ignore=!1}),s}Ft(this.id)},e.prototype.getConnectedDataURL=function(t){if(!this._disposed){var i=t.type==="svg",r=this.group,o=Math.min,a=Math.max,s=1/0;if(Ql[r]){var l=s,u=s,h=-1/0,c=-1/0,p=[],d=t&&t.pixelRatio||this.getDevicePixelRatio();A(_r,function(x,_){if(x.group===r){var w=i?x.getZr().painter.getSvgDom().innerHTML:x.renderToCanvas(ie(t)),b=x.getDom().getBoundingClientRect();l=o(b.left,l),u=o(b.top,u),h=a(b.right,h),c=a(b.bottom,c),p.push({dom:w,left:b.left,top:b.top})}});var f=(h*=d)-(l*=d),g=(c*=d)-(u*=d),v=Yn.createCanvas(),y=Jh(v,{renderer:i?"svg":"canvas"});if(y.resize({width:f,height:g}),i){var m="";return A(p,function(x){var _=x.left-l,w=x.top-u;m+=''+x.dom+""}),y.painter.getSvgRoot().innerHTML=m,t.connectedBackgroundColor&&y.painter.setBackgroundColor(t.connectedBackgroundColor),y.refreshImmediately(),y.painter.toDataURL()}return t.connectedBackgroundColor&&y.add(new Re({shape:{x:0,y:0,width:f,height:g},style:{fill:t.connectedBackgroundColor}})),A(p,function(x){var _=new Bt({style:{x:x.left*d-l,y:x.top*d-u,image:x.dom}});y.add(_)}),y.refreshImmediately(),v.toDataURL("image/"+(t&&t.type||"png"))}return this.getDataURL(t)}Ft(this.id)},e.prototype.convertToPixel=function(t,i){return Yp(this,"convertToPixel",t,i)},e.prototype.convertFromPixel=function(t,i){return Yp(this,"convertFromPixel",t,i)},e.prototype.containPixel=function(t,i){var r;if(!this._disposed)return A(oa(this._model,t),function(o,a){a.indexOf("Models")>=0&&A(o,function(s){var l=s.coordinateSystem;if(l&&l.containPoint)r=r||!!l.containPoint(i);else if(a==="seriesModels"){var u=this._chartsMap[s.__viewId];u&&u.containPoint?r=r||u.containPoint(i,s):Je(a+": "+(u?"The found component do not support containPoint.":"No view mapping to the found component."))}else Je(a+": containPoint is not supported")},this)},this),!!r;Ft(this.id)},e.prototype.getVisual=function(t,i){var r=oa(this._model,t,{defaultMainType:"series"}),o=r.seriesModel;o||Je("There is no specified series model");var a=o.getData(),s=r.hasOwnProperty("dataIndexInside")?r.dataIndexInside:r.hasOwnProperty("dataIndex")?a.indexOfRawIndex(r.dataIndex):null;return s!=null?V0(a,s,i):F0(a,i)},e.prototype.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},e.prototype.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]},e.prototype._initEvents=function(){var t,i,r,o=this;A(UI,function(a){var s=function(l){var u,h=o.getModel(),c=l.target,p=a==="globalout";if(p?u={}:c&&yr(c,function(y){var m=ye(y);if(m&&m.dataIndex!=null){var x=m.dataModel||h.getSeriesByIndex(m.seriesIndex);return u=x&&x.getDataParams(m.dataIndex,m.dataType,c)||{},!0}if(m.eventData)return u=G({},m.eventData),!0},!0),u){var d=u.componentType,f=u.componentIndex;d!=="markLine"&&d!=="markPoint"&&d!=="markArea"||(d="series",f=u.seriesIndex);var g=d&&f!=null&&h.getComponent(d,f),v=g&&o[g.mainType==="series"?"_chartsMap":"_componentsMap"][g.__viewId];p||g&&v||Je("model or view can not be found by params"),u.event=l,u.type=a,o._$eventProcessor.eventInfo={targetEl:c,packedEvent:u,model:g,view:v},o.trigger(a,u)}};s.zrEventfulCallAtLast=!0,o._zr.on(a,s,o)}),A(Ga,function(a,s){o._messageCenter.on(s,function(l){this.trigger(s,l)},o)}),A(["selectchanged"],function(a){o._messageCenter.on(a,function(s){this.trigger(a,s)},o)}),t=this._messageCenter,i=this,r=this._api,t.on("selectchanged",function(a){var s=r.getModel();a.isFromClick?(yo("map","selectchanged",i,s,a),yo("pie","selectchanged",i,s,a)):a.fromAction==="select"?(yo("map","selected",i,s,a),yo("pie","selected",i,s,a)):a.fromAction==="unselect"&&(yo("map","unselected",i,s,a),yo("pie","unselected",i,s,a))})},e.prototype.isDisposed=function(){return this._disposed},e.prototype.clear=function(){this._disposed?Ft(this.id):this.setOption({series:[]},!0)},e.prototype.dispose=function(){if(this._disposed)Ft(this.id);else{this._disposed=!0,this.getDom()&&mv(this.getDom(),$p,"");var t=this,i=t._api,r=t._model;A(t._componentsViews,function(o){o.dispose(r,i)}),A(t._chartsViews,function(o){o.dispose(r,i)}),t._zr.dispose(),t._dom=t._model=t._chartsMap=t._componentsMap=t._chartsViews=t._componentsViews=t._scheduler=t._api=t._zr=t._throttledZrFlush=t._theme=t._coordSysMgr=t._messageCenter=null,delete _r[t.id]}},e.prototype.resize=function(t){if(this[gt])mt("`resize` should not be called during main process.");else if(this._disposed)Ft(this.id);else{this._zr.resize(t);var i=this._model;if(this._loadingFX&&this._loadingFX.resize(),i){var r=i.resetOption("media"),o=t&&t.silent;this[Pt]&&(o==null&&(o=this[Pt].silent),r=!0,this[Pt]=null),this[gt]=!0;try{r&&mo(this),Ti.update.call(this,{type:"resize",animation:G({duration:0},t&&t.animation)})}catch(a){throw this[gt]=!1,a}this[gt]=!1,Va.call(this,o),Fa.call(this,o)}}},e.prototype.showLoading=function(t,i){if(this._disposed)Ft(this.id);else if(Q(t)&&(i=t,t=""),t=t||"default",this.hideLoading(),Jp[t]){var r=Jp[t](this._api,i),o=this._zr;this._loadingFX=r,o.add(r)}else Je("Loading effects "+t+" not exists.")},e.prototype.hideLoading=function(){this._disposed?Ft(this.id):(this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null)},e.prototype.makeActionFromEvent=function(t){var i=G({},t);return i.type=Ga[t.type],i},e.prototype.dispatchAction=function(t,i){if(this._disposed)Ft(this.id);else if(Q(i)||(i={silent:!!i}),Jl[t.type]&&this._model)if(this[gt])this._pendingActions.push(t);else{var r=i.silent;Xp.call(this,t,r);var o=i.flush;o?this._zr.flush():o!==!1&&_e.browser.weChat&&this._throttledZrFlush(),Va.call(this,r),Fa.call(this,r)}},e.prototype.updateLabelLayout=function(){_n.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},e.prototype.appendData=function(t){if(this._disposed)Ft(this.id);else{var i=t.seriesIndex,r=this.getModel().getSeriesByIndex(i);le(t.data&&r),r.appendData(t),this._scheduler.unfinished=!0,this.getZr().wakeUp()}},e.internalField=function(){function t(l){l.clearColorPalette(),l.eachSeries(function(u){u.clearColorPalette()})}function i(l){for(var u=[],h=l.currentStates,c=0;c0?{duration:p,delay:h.get("delay"),easing:h.get("easing")}:null;u.eachRendered(function(f){if(f.states&&f.states.emphasis){if(to(f))return;if(f instanceof Ae&&function(m){var x=$v(m);x.normalFill=m.style.fill,x.normalStroke=m.style.stroke;var _=m.states.select||{};x.selectFill=_.style&&_.style.fill||null,x.selectStroke=_.style&&_.style.stroke||null}(f),f.__dirty){var g=f.prevStates;g&&f.useStates(g)}if(c){f.stateTransition=d;var v=f.getTextContent(),y=f.getTextGuideLine();v&&(v.stateTransition=d),y&&(y.stateTransition=d)}f.__dirty&&i(f)}})}mo=function(l){var u=l._scheduler;u.restorePipelines(l._model),u.prepareStageTasks(),Wp(l,!0),Wp(l,!1),u.plan()},Wp=function(l,u){for(var h=l._model,c=l._scheduler,p=u?l._componentsViews:l._chartsViews,d=u?l._componentsMap:l._chartsMap,f=l._zr,g=l._api,v=0;vy.get("hoverLayerThreshold")&&!_e.node&&!_e.worker&&y.eachSeries(function(w){if(!w.preventUsingHoverLayer){var b=v._chartsMap[w.__viewId];b.__alive&&b.eachRendered(function(S){S.states.emphasis&&(S.states.emphasis.hoverLayer=!0)})}})}(l,u),_n.trigger("series:afterupdate",u,h,p)},ln=function(l){l[Gp]=!0,l.getZr().wakeUp()},mx=function(l){l[Gp]&&(l.getZr().storage.traverse(function(u){to(u)||i(u)}),l[Gp]=!1)},vx=function(l){return new(function(u){function h(){return u!==null&&u.apply(this,arguments)||this}return V(h,u),h.prototype.getCoordinateSystems=function(){return l._coordSysMgr.getCoordinateSystems()},h.prototype.getComponentByElement=function(c){for(;c;){var p=c.__ecComponentInfo;if(p!=null)return l._model.getComponent(p.mainType,p.index);c=c.parent}},h.prototype.enterEmphasis=function(c,p){Kr(c,p),ln(l)},h.prototype.leaveEmphasis=function(c,p){Jr(c,p),ln(l)},h.prototype.enterBlur=function(c){(function(p){Jn(p,Mc)})(c),ln(l)},h.prototype.leaveBlur=function(c){ay(c),ln(l)},h.prototype.enterSelect=function(c){sy(c),ln(l)},h.prototype.leaveSelect=function(c){ly(c),ln(l)},h.prototype.getModel=function(){return l.getModel()},h.prototype.getViewOfComponentModel=function(c){return l.getViewOfComponentModel(c)},h.prototype.getViewOfSeriesModel=function(c){return l.getViewOfSeriesModel(c)},h}(Em))(l)},yx=function(l){function u(h,c){for(var p=0;p=0)){Ix.push(t);var o=O0.wrapStageHandler(t,r);o.__prio=e,o.__raw=t,n.push(o)}}function rd(n,e){Jp[n]=e}function Ax(n,e,t){var i=sx("registerMap");i&&i(n,e,t)}var Dx=function(n){var e=(n=ie(n)).type;e||It("Must have a `type` when `registerTransform`.");var t=e.split(":");t.length!==2&&It('Name must include namespace like "ns:regression".');var i=!1;t[0]==="echarts"&&(e=t[1],i=!0),n.__isBuiltIn=i,i0.set(e,n)};Ci(Fp,gI),Ci(jl,vI),Ci(jl,yI),Ci(Fp,LI),Ci(jl,PI),Ci(7e3,function(n,e){n.eachRawSeries(function(t){if(!n.isSeriesFiltered(t)){var i=t.getData();i.hasItemVisual()&&i.each(function(o){var a=i.getItemVisual(o,"decal");a&&(i.ensureUniqueItemVisual(o,"style").decal=Ul(a,e))});var r=i.getVisual("decal");r&&(i.getVisual("style").decal=Ul(r,e))}})}),eu(Hm),td(900,function(n){var e=ee();n.eachSeries(function(t){var i=t.get("stack");if(i){var r=e.get(i)||e.set(i,[]),o=t.getData(),a={stackResultDimension:o.getCalculationInfo("stackResultDimension"),stackedOverDimension:o.getCalculationInfo("stackedOverDimension"),stackedDimension:o.getCalculationInfo("stackedDimension"),stackedByDimension:o.getCalculationInfo("stackedByDimension"),isStackedByIndex:o.getCalculationInfo("isStackedByIndex"),data:o,seriesModel:t};if(!a.stackedDimension||!a.isStackedByIndex&&!a.stackedByDimension)return;r.length&&o.setCalculationInfo("stackedOnSeries",r[r.length-1].seriesModel),r.push(a)}}),e.each(BC)}),rd("default",function(n,e){ae(e=e||{},{text:"loading",textColor:"#000",fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255, 255, 255, 0.8)",showSpinner:!0,color:"#5470c6",spinnerRadius:10,lineWidth:5,zlevel:0});var t=new me,i=new Re({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4});t.add(i);var r,o=new De({style:{text:e.text,fill:e.textColor,fontSize:e.fontSize,fontWeight:e.fontWeight,fontStyle:e.fontStyle,fontFamily:e.fontFamily},zlevel:e.zlevel,z:10001}),a=new Re({style:{fill:"none"},textContent:o,textConfig:{position:"right",distance:10},zlevel:e.zlevel,z:10001});return t.add(a),e.showSpinner&&((r=new ol({shape:{startAngle:-Bl/2,endAngle:-Bl/2+.1,r:e.spinnerRadius},style:{stroke:e.color,lineCap:"round",lineWidth:e.lineWidth},zlevel:e.zlevel,z:10001})).animateShape(!0).when(1e3,{endAngle:3*Bl/2}).start("circularInOut"),r.animateShape(!0).when(1e3,{startAngle:3*Bl/2}).delay(300).start("circularInOut"),t.add(r)),t.resize=function(){var s=o.getBoundingRect().width,l=e.showSpinner?e.spinnerRadius:0,u=(n.getWidth()-2*l-(e.showSpinner&&s?10:0)-s)/2-(e.showSpinner&&s?0:5+s/2)+(e.showSpinner?0:s/2)+(s?0:l),h=n.getHeight()/2;e.showSpinner&&r.setShape({cx:u,cy:h}),a.setShape({x:u-l,y:h-l,width:2*l,height:2*l}),i.setShape({x:0,y:0,width:n.getWidth(),height:n.getHeight()})},t.resize(),t}),wn({type:ur,event:ur,update:ur},ot),wn({type:$s,event:$s,update:$s},ot),wn({type:ua,event:ua,update:ua},ot),wn({type:Qs,event:Qs,update:Qs},ot),wn({type:ha,event:ha,update:ha},ot),ed("light",AI),ed("dark",DI);function Ha(n){return n==null?0:n.length||1}function kx(n){return n}var qI=function(){function n(e,t,i,r,o,a){this._old=e,this._new=t,this._oldKeyGetter=i||kx,this._newKeyGetter=r||kx,this.context=o,this._diffModeMultiple=a==="multiple"}return n.prototype.add=function(e){return this._add=e,this},n.prototype.update=function(e){return this._update=e,this},n.prototype.updateManyToOne=function(e){return this._updateManyToOne=e,this},n.prototype.updateOneToMany=function(e){return this._updateOneToMany=e,this},n.prototype.updateManyToMany=function(e){return this._updateManyToMany=e,this},n.prototype.remove=function(e){return this._remove=e,this},n.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},n.prototype._executeOneToOne=function(){var e=this._old,t=this._new,i={},r=new Array(e.length),o=new Array(t.length);this._initIndexMap(e,null,r,"_oldKeyGetter"),this._initIndexMap(t,i,o,"_newKeyGetter");for(var a=0;a1){var h=l.shift();l.length===1&&(i[s]=l[0]),this._update&&this._update(h,a)}else u===1?(i[s]=null,this._update&&this._update(l,a)):this._remove&&this._remove(a)}this._performRestAdd(o,i)},n.prototype._executeMultiple=function(){var e=this._old,t=this._new,i={},r={},o=[],a=[];this._initIndexMap(e,i,o,"_oldKeyGetter"),this._initIndexMap(t,r,a,"_newKeyGetter");for(var s=0;s1&&p===1)this._updateManyToOne&&this._updateManyToOne(h,u),r[l]=null;else if(c===1&&p>1)this._updateOneToMany&&this._updateOneToMany(h,u),r[l]=null;else if(c===1&&p===1)this._update&&this._update(h,u),r[l]=null;else if(c>1&&p>1)this._updateManyToMany&&this._updateManyToMany(h,u),r[l]=null;else if(c>1)for(var d=0;d1)for(var s=0;s30}var Nx,iu,Wa,xo,sd,ru,ld,Ya=Q,Ii=U,QI=typeof Int32Array>"u"?Array:Int32Array,e2=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],t2=["_approximateExtent"],n2=function(){function n(e,t){var i;this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","lttbDownSample"];var r=!1;Px(e)?(i=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(r=!0,i=e),i=i||["x","y"];for(var o={},a=[],s={},l=!1,u={},h=0;h=0),r&&(p.storeDimIndex=h)}if(this.dimensions=a,this._dimInfos=o,this._initGetDimensionInfo(l),this.hostModel=t,this._invertedIndicesMap=s,this._dimOmitted){var g=this._dimIdxToName=ee();A(a,function(v){g.set(o[v].storeDimIndex,v)})}}return n.prototype.getDimension=function(e){var t=this._recognizeDimIndex(e);if(t==null)return e;if(t=e,!this._dimOmitted)return this.dimensions[t];var i=this._dimIdxToName.get(t);if(i!=null)return i;var r=this._schema.getSourceDimension(t);return r?r.name:void 0},n.prototype.getDimensionIndex=function(e){var t=this._recognizeDimIndex(e);if(t!=null)return t;if(e==null)return-1;var i=this._getDimInfo(e);return i?i.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(e):-1},n.prototype._recognizeDimIndex=function(e){if(Le(e)||e!=null&&!isNaN(e)&&!this._getDimInfo(e)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(e)<0))return+e},n.prototype._getStoreDimIndex=function(e){var t=this.getDimensionIndex(e);if(t==null)throw new Error("Unknown dimension "+e);return t},n.prototype.getDimensionInfo=function(e){return this._getDimInfo(this.getDimension(e))},n.prototype._initGetDimensionInfo=function(e){var t=this._dimInfos;this._getDimInfo=e?function(i){return t.hasOwnProperty(i)?t[i]:void 0}:function(i){return t[i]}},n.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},n.prototype.mapDimension=function(e,t){var i=this._dimSummary;if(t==null)return i.encodeFirstDimNotExtra[e];var r=i.encode[e];return r?r[t]:null},n.prototype.mapDimensionsAll=function(e){return(this._dimSummary.encode[e]||[]).slice()},n.prototype.getStore=function(){return this._store},n.prototype.initData=function(e,t,i){var r,o=this;if(e instanceof Mp&&(r=e),!r){var a=this.dimensions,s=yp(e)||yt(e)?new qm(e,a.length):e;r=new Mp;var l=Ii(a,function(u){return{type:o._dimInfos[u].type,property:u}});r.initData(s,l,i)}this._store=r,this._nameList=(t||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,r.count()),this._dimSummary=function(u,h){var c={},p=c.encode={},d=ee(),f=[],g=[],v={};A(u.dimensions,function(w){var b,S=u.getDimensionInfo(w),M=S.coordDim;if(M){le(up.get(M)==null);var T=S.coordDimIndex;ad(p,M)[T]=w,S.isExtraCoord||(d.set(M,1),(b=S.type)!=="ordinal"&&b!=="time"&&(f[0]=w),ad(v,M)[T]=u.getDimensionIndex(S.name)),S.defaultTooltip&&g.push(w)}up.each(function(C,I){var D=ad(p,I),L=S.otherDims[I];L!=null&&L!==!1&&(D[L]=S.name)})});var y=[],m={};d.each(function(w,b){var S=p[b];m[b]=S[0],y=y.concat(S)}),c.dataDimsOnCoord=y,c.dataDimIndicesOnCoord=U(y,function(w){return u.getDimensionInfo(w).storeDimIndex}),c.encodeFirstDimNotExtra=m;var x=p.label;x&&x.length&&(f=x.slice());var _=p.tooltip;return _&&_.length?g=_.slice():g.length||(g=f.slice()),p.defaultedLabel=f,p.defaultedTooltip=g,c.userOutput=new KI(v,h),c}(this,this._schema),this.userOutput=this._dimSummary.userOutput},n.prototype.appendData=function(e){var t=this._store.appendData(e);this._doInit(t[0],t[1])},n.prototype.appendValues=function(e,t){var i=this._store.appendValues(e,t.length),r=i.start,o=i.end,a=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),t)for(var s=r;s=t)){var i=this._store.getProvider();this._updateOrdinalMeta();var r=this._nameList,o=this._idList;if(i.getSource().sourceFormat===on&&!i.pure)for(var a=[],s=e;s0},n.prototype.ensureUniqueItemVisual=function(e,t){var i=this._itemVisuals,r=i[e];r||(r=i[e]={});var o=r[t];return o==null&&(W(o=this.getVisual(t))?o=o.slice():Ya(o)&&(o=G({},o)),r[t]=o),o},n.prototype.setItemVisual=function(e,t,i){var r=this._itemVisuals[e]||{};this._itemVisuals[e]=r,Ya(t)?G(r,t):r[t]=i},n.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},n.prototype.setLayout=function(e,t){Ya(e)?G(this._layout,e):this._layout[e]=t},n.prototype.getLayout=function(e){return this._layout[e]},n.prototype.getItemLayout=function(e){return this._itemLayouts[e]},n.prototype.setItemLayout=function(e,t,i){this._itemLayouts[e]=i?G(this._itemLayouts[e]||{},t):t},n.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},n.prototype.setItemGraphicEl=function(e,t){var i=this.hostModel&&this.hostModel.seriesIndex;wc(i,this.dataType,e,t),this._graphicEls[e]=t},n.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},n.prototype.eachItemGraphicEl=function(e,t){A(this._graphicEls,function(i,r){i&&e&&e.call(t,i,r)})},n.prototype.cloneShallow=function(e){return e||(e=new n(this._schema?this._schema:Ii(this.dimensions,this._getDimInfo,this),this.hostModel)),sd(e,this),e._store=this._store,e},n.prototype.wrapMethod=function(e,t){var i=this[e];re(i)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var r=i.apply(this,arguments);return t.apply(this,[r].concat(ps(arguments)))})},n.internalField=(Nx=function(e){var t=e._invertedIndicesMap;A(t,function(i,r){var o=e._dimInfos[r],a=o.ordinalMeta,s=e._store;if(a){i=t[r]=new QI(a.categories.length);for(var l=0;l1&&(l+="__ec__"+h),r[t]=l}})),n}();const ou=n2;function zx(n,e){return ud(n,e).dimensions}function ud(n,e){yp(n)||(n=xp(n));var t=(e=e||{}).coordDimensions||[],i=e.dimensionsDefine||n.dimensionsDefine||[],r=ee(),o=[],a=function(M,T,C,I){var D=Math.max(M.dimensionsDetectedCount||1,T.length,C.length,I||0);return A(T,function(L){var R;Q(L)&&(R=L.dimsDef)&&(D=Math.max(D,R.length))}),D}(n,t,i,e.dimensionsCount),s=e.canOmitUnusedDimensions&&Ex(a),l=i===n.dimensionsDefine,u=l?Rx(n):Ox(i),h=e.encodeDefine;!h&&e.encodeDefaulter&&(h=e.encodeDefaulter(n,a));for(var c=ee(h),p=new r0(a),d=0;d0&&(I.name=D+(L-1)),L++,T.set(D,L)}}(o),new Lx({source:n,dimensions:o,fullDimensionCount:a,dimensionOmitted:s})}function i2(n,e,t){if(t||e.hasKey(n)){for(var i=0;e.hasKey(n+i);)i++;n+=i}return e.set(n,!0),n}var r2=function(n){this.coordSysDims=[],this.axisMap=ee(),this.categoryAxisMap=ee(),this.coordSysName=n},o2={cartesian2d:function(n,e,t,i){var r=n.getReferringComponents("xAxis",nt).models[0],o=n.getReferringComponents("yAxis",nt).models[0];if(!r)throw new Error('xAxis "'+Ht(n.get("xAxisIndex"),n.get("xAxisId"),0)+'" not found');if(!o)throw new Error('yAxis "'+Ht(n.get("xAxisIndex"),n.get("yAxisId"),0)+'" not found');e.coordSysDims=["x","y"],t.set("x",r),t.set("y",o),_o(r)&&(i.set("x",r),e.firstCategoryDimIndex=0),_o(o)&&(i.set("y",o),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},singleAxis:function(n,e,t,i){var r=n.getReferringComponents("singleAxis",nt).models[0];if(!r)throw new Error("singleAxis should be specified.");e.coordSysDims=["single"],t.set("single",r),_o(r)&&(i.set("single",r),e.firstCategoryDimIndex=0)},polar:function(n,e,t,i){var r=n.getReferringComponents("polar",nt).models[0],o=r.findAxisModel("radiusAxis"),a=r.findAxisModel("angleAxis");if(!a)throw new Error("angleAxis option not found");if(!o)throw new Error("radiusAxis option not found");e.coordSysDims=["radius","angle"],t.set("radius",o),t.set("angle",a),_o(o)&&(i.set("radius",o),e.firstCategoryDimIndex=0),_o(a)&&(i.set("angle",a),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=1))},geo:function(n,e,t,i){e.coordSysDims=["lng","lat"]},parallel:function(n,e,t,i){var r=n.ecModel,o=r.getComponent("parallel",n.get("parallelIndex")),a=e.coordSysDims=o.dimensions.slice();A(o.parallelAxisIndex,function(s,l){var u=r.getComponent("parallelAxis",s),h=a[l];t.set(h,u),_o(u)&&(i.set(h,u),e.firstCategoryDimIndex==null&&(e.firstCategoryDimIndex=l))})}};function _o(n){return n.get("type")==="category"}function Bx(n,e,t){var i,r,o,a=(t=t||{}).byIndex,s=t.stackedCoordDimension;(function(m){return!Px(m.schema)})(e)?i=e:(r=e.schema,i=r.dimensions,o=e.store);var l,u,h,c,p=!(!n||!n.get("stack"));if(A(i,function(m,x){j(m)&&(i[x]=m={name:m}),p&&!m.isExtraCoord&&(a||l||!m.ordinalMeta||(l=m),u||m.type==="ordinal"||m.type==="time"||s&&s!==m.coordDim||(u=m))}),!u||a||l||(a=!0),u){h="__\0ecstackresult_"+n.id,c="__\0ecstackedover_"+n.id,l&&(l.createInvertedIndices=!0);var d=u.coordDim,f=u.type,g=0;A(i,function(m){m.coordDim===d&&g++});var v={name:h,coordDim:d,coordDimIndex:g,type:f,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length},y={name:c,coordDim:c,coordDimIndex:g+1,type:f,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:i.length+1};r?(o&&(v.storeDimIndex=o.ensureCalculationDimension(c,f),y.storeDimIndex=o.ensureCalculationDimension(h,f)),r.appendCalculationDimension(v),r.appendCalculationDimension(y)):(i.push(v),i.push(y))}return{stackedDimension:u&&u.name,stackedByDimension:l&&l.name,isStackedByIndex:a,stackedOverDimension:c,stackResultDimension:h}}function Ai(n,e){return!!e&&e===n.getCalculationInfo("stackedDimension")}function Vx(n,e){return Ai(n,e)?n.getCalculationInfo("stackResultDimension"):e}function au(n,e,t){t=t||{};var i,r=e.getSourceManager(),o=!1;n?(o=!0,i=xp(n)):o=(i=r.getSource()).sourceFormat===on;var a=function(v){var y=v.get("coordinateSystem"),m=new r2(y),x=o2[y];if(x)return x(v,m,m.axisMap,m.categoryAxisMap),m}(e),s=function(v,y){var m,x=v.get("coordinateSystem"),_=Dl.get(x);return y&&y.coordSysDims&&(m=U(y.coordSysDims,function(w){var b={name:w},S=y.axisMap.get(w);if(S){var M=S.get("type");b.type=function(T){return T==="category"?"ordinal":T==="time"?"time":"float"}(M)}return b})),m||(m=_&&(_.getDimensionsInfo?_.getDimensionsInfo():_.dimensions.slice())||["x","y"]),m}(e,a),l=t.useEncodeDefaulter,u=re(l)?l:l?Te(TC,s,e):null,h=ud(i,{coordDimensions:s,generateCoord:t.generateCoord,encodeDefine:e.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!o}),c=function(v,y,m){var x,_;return m&&A(v,function(w,b){var S=w.coordDim,M=m.categoryAxisMap.get(S);M&&(x==null&&(x=b),w.ordinalMeta=M.getOrdinalMeta(),y&&(w.createInvertedIndices=!0)),w.otherDims.itemName!=null&&(_=!0)}),_||x==null||(v[x].otherDims.itemName=0),x}(h.dimensions,t.createInvertedIndices,a),p=o?null:r.getSharedDataStore(h),d=Bx(e,{schema:h,store:p}),f=new ou(h,e);f.setCalculationInfo(d);var g=c!=null&&function(v){if(v.sourceFormat===on){var y=function(m){for(var x=0;xt[1]&&(t[1]=e[1])},n.prototype.unionExtentFromData=function(e,t){this.unionExtent(e.getApproximateExtent(t))},n.prototype.getExtent=function(){return this._extent.slice()},n.prototype.setExtent=function(e,t){var i=this._extent;isNaN(e)||(i[0]=e),isNaN(t)||(i[1]=t)},n.prototype.isInExtentRange=function(e){return this._extent[0]<=e&&this._extent[1]>=e},n.prototype.isBlank=function(){return this._isBlank},n.prototype.setBlank=function(e){this._isBlank=e},n}();Hs(Fx);const oi=Fx;var a2=0,s2=function(){function n(e){this.categories=e.categories||[],this._needCollect=e.needCollect,this._deduplication=e.deduplication,this.uid=++a2}return n.createByAxisModel=function(e){var t=e.option,i=t.data,r=i&&U(i,l2);return new n({categories:r,needCollect:!r,deduplication:t.dedplication!==!1})},n.prototype.getOrdinal=function(e){return this._getOrCreateMap().get(e)},n.prototype.parseAndCollect=function(e){var t,i=this._needCollect;if(!j(e)&&!i)return e;if(i&&!this._deduplication)return t=this.categories.length,this.categories[t]=e,t;var r=this._getOrCreateMap();return(t=r.get(e))==null&&(i?(t=this.categories.length,this.categories[t]=e,r.set(e,t)):t=NaN),t},n.prototype._getOrCreateMap=function(){return this._map||(this._map=ee(this.categories))},n}();function l2(n){return Q(n)&&n.value!=null?n.value:n+""}const hd=s2;function cd(n){return n.type==="interval"||n.type==="log"}function u2(n,e,t,i){var r={},o=n[1]-n[0],a=r.interval=ec(o/e,!0);t!=null&&ai&&(a=r.interval=i);var s=r.intervalPrecision=Gx(a);return function(l,u){!isFinite(l[0])&&(l[0]=u[0]),!isFinite(l[1])&&(l[1]=u[1]),Hx(l,0,u),Hx(l,1,u),l[0]>l[1]&&(l[0]=l[1])}(r.niceTickExtent=[Ue(Math.ceil(n[0]/a)*a,s),Ue(Math.floor(n[1]/a)*a,s)],n),r}function pd(n){var e=Math.pow(10,ta(n)),t=n/e;return t?t===2?t=3:t===3?t=5:t*=2:t=1,Ue(t*e)}function Gx(n){return kn(n)+2}function Hx(n,e,t){n[e]=Math.max(Math.min(n[e],t[1]),t[0])}function su(n,e){return n>=e[0]&&n<=e[1]}function lu(n,e){return e[1]===e[0]?.5:(n-e[0])/(e[1]-e[0])}function uu(n,e){return n*(e[1]-e[0])+e[0]}var Wx=function(n){function e(t){var i=n.call(this,t)||this;i.type="ordinal";var r=i.getSetting("ordinalMeta");return r||(r=new hd({})),W(r)&&(r=new hd({categories:U(r,function(o){return Q(o)?o.value:o})})),i._ordinalMeta=r,i._extent=i.getSetting("extent")||[0,r.categories.length-1],i}return V(e,n),e.prototype.parse=function(t){return t==null?NaN:j(t)?this._ordinalMeta.getOrdinal(t):Math.round(t)},e.prototype.contain=function(t){return su(t=this.parse(t),this._extent)&&this._ordinalMeta.categories[t]!=null},e.prototype.normalize=function(t){return lu(t=this._getTickNumber(this.parse(t)),this._extent)},e.prototype.scale=function(t){return t=Math.round(uu(t,this._extent)),this.getRawOrdinalNumber(t)},e.prototype.getTicks=function(){for(var t=[],i=this._extent,r=i[0];r<=i[1];)t.push({value:r}),r++;return t},e.prototype.getMinorTicks=function(t){},e.prototype.setSortInfo=function(t){if(t!=null){for(var i=t.ordinalNumbers,r=this._ordinalNumbersByTick=[],o=this._ticksByOrdinalNumber=[],a=0,s=this._ordinalMeta.categories.length,l=Math.min(s,i.length);a=0&&t=0&&t=t},e.prototype.getOrdinalMeta=function(){return this._ordinalMeta},e.prototype.calcNiceTicks=function(){},e.prototype.calcNiceExtent=function(){},e.type="ordinal",e}(oi);oi.registerClass(Wx);const Yx=Wx;var wr=Ue,Ux=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type="interval",t._interval=0,t._intervalPrecision=2,t}return V(e,n),e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return su(t,this._extent)},e.prototype.normalize=function(t){return lu(t,this._extent)},e.prototype.scale=function(t){return uu(t,this._extent)},e.prototype.setExtent=function(t,i){var r=this._extent;isNaN(t)||(r[0]=parseFloat(t)),isNaN(i)||(r[1]=parseFloat(i))},e.prototype.unionExtent=function(t){var i=this._extent;t[0]i[1]&&(i[1]=t[1]),this.setExtent(i[0],i[1])},e.prototype.getInterval=function(){return this._interval},e.prototype.setInterval=function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=Gx(t)},e.prototype.getTicks=function(t){var i=this._interval,r=this._extent,o=this._niceExtent,a=this._intervalPrecision,s=[];if(!i)return s;r[0]1e4)return[];var u=s.length?s[s.length-1].value:o[1];return r[1]>u&&(t?s.push({value:wr(u+i,a)}):s.push({value:r[1]})),s},e.prototype.getMinorTicks=function(t){for(var i=this.getTicks(!0),r=[],o=this.getExtent(),a=1;ao[0]&&p0&&(l=l===null?h:Math.min(l,h))}o[a]=l}}return o}(n),t=[];return A(n,function(i){var r,o=i.coordinateSystem.getBaseAxis(),a=o.getExtent();if(o.type==="category")r=o.getBandWidth();else if(o.type==="value"||o.type==="time"){var s=o.dim+"_"+o.index,l=e[s],u=Math.abs(a[1]-a[0]),h=o.scale.getExtent(),c=Math.abs(h[1]-h[0]);r=l?u/c*l:u}else{var p=i.getData();r=Math.abs(a[1]-a[0])/p.count()}var d=te(i.get("barWidth"),r),f=te(i.get("barMaxWidth"),r),g=te(i.get("barMinWidth")||($x(i)?.5:1),r),v=i.get("barGap"),y=i.get("barCategoryGap");t.push({bandWidth:r,barWidth:d,barMaxWidth:f,barMinWidth:g,barGap:v,barCategoryGap:y,axisKey:fd(o),stackId:dd(i)})}),function(i){var r={};A(i,function(a,s){var l=a.axisKey,u=a.bandWidth,h=r[l]||{bandWidth:u,remainedWidth:u,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},c=h.stacks;r[l]=h;var p=a.stackId;c[p]||h.autoWidthCount++,c[p]=c[p]||{width:0,maxWidth:0};var d=a.barWidth;d&&!c[p].width&&(c[p].width=d,d=Math.min(h.remainedWidth,d),h.remainedWidth-=d);var f=a.barMaxWidth;f&&(c[p].maxWidth=f);var g=a.barMinWidth;g&&(c[p].minWidth=g);var v=a.barGap;v!=null&&(h.gap=v);var y=a.barCategoryGap;y!=null&&(h.categoryGap=y)});var o={};return A(r,function(a,s){o[s]={};var l=a.stacks,u=a.bandWidth,h=a.categoryGap;if(h==null){var c=Oe(l).length;h=Math.max(35-4*c,15)+"%"}var p=te(h,u),d=te(a.gap,1),f=a.remainedWidth,g=a.autoWidthCount,v=(f-p)/(g+(g-1)*d);v=Math.max(v,0),A(l,function(_){var w=_.maxWidth,b=_.minWidth;if(_.width)S=_.width,w&&(S=Math.min(S,w)),b&&(S=Math.max(S,b)),_.width=S,f-=S+d*S,g--;else{var S=v;w&&wS&&(S=b),S!==v&&(_.width=S,f-=S+d*S,g--)}}),v=(f-p)/(g+(g-1)*d),v=Math.max(v,0);var y,m=0;A(l,function(_,w){_.width||(_.width=v),y=_,m+=_.width*(1+d)}),y&&(m-=y.width*d);var x=-m/2;A(l,function(_,w){o[s][w]=o[s][w]||{bandWidth:u,offset:x,width:_.width},x+=_.width*(1+d)})}),o}(t)}function qx(n,e){var t=jx(n,e),i=Zx(t);A(t,function(r){var o=r.getData(),a=r.coordinateSystem.getBaseAxis(),s=dd(r),l=i[fd(a)][s],u=l.offset,h=l.width;o.setLayout({bandWidth:l.bandWidth,offset:u,size:h})})}function Kx(n){return{seriesType:n,plan:kp(),reset:function(e){if(Jx(e)){var t=e.getData(),i=e.coordinateSystem,r=i.getBaseAxis(),o=i.getOtherAxis(r),a=t.getDimensionIndex(t.mapDimension(o.dim)),s=t.getDimensionIndex(t.mapDimension(r.dim)),l=e.get("showBackground",!0),u=t.mapDimension(o.dim),h=t.getCalculationInfo("stackResultDimension"),c=Ai(t,u)&&!!t.getCalculationInfo("stackedOnSeries"),p=o.isHorizontal(),d=function(x,_){return _.toGlobalCoord(_.dataToCoord(_.type==="log"?1:0))}(0,o),f=$x(e),g=e.get("barMinHeight")||0,v=h&&t.getDimensionIndex(h),y=t.getLayout("size"),m=t.getLayout("offset");return{progress:function(x,_){for(var w,b=x.count,S=f&&ai(3*b),M=f&&l&&ai(3*b),T=f&&ai(b),C=i.master.getRect(),I=p?C.width:C.height,D=_.getStore(),L=0;(w=x.next())!=null;){var R=D.get(c?v:a,w),O=D.get(s,w),E=d,k=void 0;c&&(k=+R-D.get(a,w));var P=void 0,N=void 0,B=void 0,z=void 0;if(p){var X=i.dataToPoint([R,O]);c&&(E=i.dataToPoint([k,O])[0]),P=E,N=X[1]+m,B=X[0]-E,z=y,Math.abs(B)0)for(var d=0;d=0;--d)if(f[g]){c=f[g];break}c=c||p.none}if(W(c)){var v=a.level==null?0:a.level>=0?a.level:c.length+a.level;c=c[v=Math.min(v,c.length-1)]}}return Ca(new Date(a.value),c,h,u)}(t,i,r,this.getSetting("locale"),o)},e.prototype.getTicks=function(){var t=this._interval,i=this._extent,r=[];if(!t)return r;r.push({value:i[0],level:0});var o=this.getSetting("useUTC"),a=function(s,l,u,h){var c=1e4,p=am,d=0;function f(E,k,P,N,B,z,X){for(var Z=new Date(k),F=k,Y=Z[N]();F1&&z===0&&P.unshift({value:P[0].value-F})}}for(z=0;z=h[0]&&M<=h[1]&&m++)}var T=(h[1]-h[0])/l;if(m>1.5*T&&x>T/1.5||(v.push(b),m>T||s===p[_]))break}y=[]}}d>=c&&Je("Exceed safe limit.");var C=Ge(U(v,function(E){return Ge(E,function(k){return k.value>=h[0]&&k.value<=h[1]&&!k.notAdd})}),function(E){return E.length>0}),I=[],D=C.length-1;for(_=0;_r&&(this._approxInterval=r);var s=hu.length,l=Math.min(function(u,h,c,p){for(;c>>1;u[d][1]16?16:n>7.5?7:n>3.5?4:n>1.5?2:1}function d2(n){return(n/=30*rn)>6?6:n>3?3:n>2?2:1}function f2(n){return(n/=Ma)>12?12:n>6?6:n>3.5?4:n>2?2:1}function e_(n,e){return(n/=e?ep:Qc)>30?30:n>20?20:n>15?15:n>10?10:n>5?5:n>2?2:1}function g2(n){return ec(n,!0)}function v2(n,e,t){var i=new Date(n);switch(oo(e)){case"year":case"month":i[um(t)](0);case"day":i[hm(t)](1);case"hour":i[cm(t)](0);case"minute":i[pm(t)](0);case"second":i[dm(t)](0),i[fm(t)](0)}return i.getTime()}oi.registerClass(Qx);const y2=Qx;var t_=oi.prototype,Ua=br.prototype,m2=Ue,x2=Math.floor,_2=Math.ceil,cu=Math.pow,bn=Math.log,gd=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type="log",t.base=10,t._originalScale=new br,t._interval=0,t}return V(e,n),e.prototype.getTicks=function(t){var i=this._originalScale,r=this._extent,o=i.getExtent();return U(Ua.getTicks.call(this,t),function(a){var s=a.value,l=Ue(cu(this.base,s));return l=s===r[0]&&this._fixMin?pu(l,o[0]):l,{value:l=s===r[1]&&this._fixMax?pu(l,o[1]):l}},this)},e.prototype.setExtent=function(t,i){var r=bn(this.base);t=bn(Math.max(0,t))/r,i=bn(Math.max(0,i))/r,Ua.setExtent.call(this,t,i)},e.prototype.getExtent=function(){var t=this.base,i=t_.getExtent.call(this);i[0]=cu(t,i[0]),i[1]=cu(t,i[1]);var r=this._originalScale.getExtent();return this._fixMin&&(i[0]=pu(i[0],r[0])),this._fixMax&&(i[1]=pu(i[1],r[1])),i},e.prototype.unionExtent=function(t){this._originalScale.unionExtent(t);var i=this.base;t[0]=bn(t[0])/bn(i),t[1]=bn(t[1])/bn(i),t_.unionExtent.call(this,t)},e.prototype.unionExtentFromData=function(t,i){this.unionExtent(t.getApproximateExtent(i))},e.prototype.calcNiceTicks=function(t){t=t||10;var i=this._extent,r=i[1]-i[0];if(!(r===1/0||r<=0)){var o=av(r);for(t/r*o<=.5&&(o*=10);!isNaN(o)&&Math.abs(o)<1&&Math.abs(o)>0;)o*=10;var a=[Ue(_2(i[0]/o)*o),Ue(x2(i[1]/o)*o)];this._interval=o,this._niceExtent=a}},e.prototype.calcNiceExtent=function(t){Ua.calcNiceExtent.call(this,t),this._fixMin=t.fixMin,this._fixMax=t.fixMax},e.prototype.parse=function(t){return t},e.prototype.contain=function(t){return su(t=bn(t)/bn(this.base),this._extent)},e.prototype.normalize=function(t){return lu(t=bn(t)/bn(this.base),this._extent)},e.prototype.scale=function(t){return t=uu(t,this._extent),cu(this.base,t)},e.type="log",e}(oi),n_=gd.prototype;function pu(n,e){return m2(n,kn(e))}n_.getMinorTicks=Ua.getMinorTicks,n_.getLabel=Ua.getLabel,oi.registerClass(gd);const w2=gd;var b2=function(){function n(e,t,i){this._prepareParams(e,t,i)}return n.prototype._prepareParams=function(e,t,i){i[1]0&&l>0&&!u&&(s=0),s<0&&l<0&&!h&&(l=0));var p=this._determinedMin,d=this._determinedMax;return p!=null&&(s=p,u=!0),d!=null&&(l=d,h=!0),{min:s,max:l,minFixed:u,maxFixed:h,isBlank:c}},n.prototype.modifyDataMinMax=function(e,t){le(!this.frozen),this[M2[e]]=t},n.prototype.setDeterminedMinMax=function(e,t){var i=S2[e];le(!this.frozen&&this[i]==null),this[i]=t},n.prototype.freeze=function(){this.frozen=!0},n}(),S2={min:"_determinedMin",max:"_determinedMax"},M2={min:"_dataMin",max:"_dataMax"};function i_(n,e,t){var i=n.rawExtentInfo;return i||(i=new b2(n,e,t),n.rawExtentInfo=i,i)}function du(n,e){return e==null?null:Er(e)?NaN:n.parse(e)}function r_(n,e){var t=n.type,i=i_(n,e,n.getExtent()).calculate();n.setBlank(i.isBlank);var r=i.min,o=i.max,a=e.ecModel;if(a&&t==="time"){var s=jx("bar",a),l=!1;if(A(s,function(c){l=l||c.getBaseAxis()===e.axis}),l){var u=Zx(s),h=function(c,p,d,f){var g=d.axis.getExtent(),v=g[1]-g[0],y=function(S,M,T){if(S&&M){var C=S[fd(M)];return C!=null&&T!=null?C[dd(T)]:C}}(f,d.axis);if(y===void 0)return{min:c,max:p};var m=1/0;A(y,function(S){m=Math.min(S.offset,m)});var x=-1/0;A(y,function(S){x=Math.max(S.offset+S.width,x)}),m=Math.abs(m),x=Math.abs(x);var _=m+x,w=p-c,b=w/(1-(m+x)/v)-w;return p+=b*(x/_),c-=b*(m/_),{min:c,max:p}}(r,o,e,u);r=h.min,o=h.max}}return{extent:[r,o],fixMin:i.minFixed,fixMax:i.maxFixed}}function wo(n,e){var t=e,i=r_(n,t),r=i.extent,o=t.get("splitNumber");n instanceof w2&&(n.base=t.get("logBase"));var a=n.type,s=t.get("interval"),l=a==="interval"||a==="time";n.setExtent(r[0],r[1]),n.calcNiceExtent({splitNumber:o,fixMin:i.fixMin,fixMax:i.fixMax,minInterval:l?t.get("minInterval"):null,maxInterval:l?t.get("maxInterval"):null}),s!=null&&n.setInterval&&n.setInterval(s)}function fu(n,e){if(e=e||n.get("type"))switch(e){case"category":return new Yx({ordinalMeta:n.getOrdinalMeta?n.getOrdinalMeta():n.getCategories(),extent:[1/0,-1/0]});case"time":return new y2({locale:n.ecModel.getLocaleModel(),useUTC:n.ecModel.get("useUTC")});default:return new(oi.getClass(e)||br)}}function Xa(n){var e,t,i=n.getLabelModel().get("formatter"),r=n.type==="category"?n.scale.getExtent()[0]:null;return n.scale.type==="time"?(t=i,function(o,a){return n.scale.getFormattedLabel(o,a,t)}):j(i)?function(o){return function(a){var s=n.scale.getLabel(a);return o.replace("{value}",s??"")}}(i):re(i)?(e=i,function(o,a){return r!=null&&(a=o.value-r),e(vd(n,o),a,o.level!=null?{level:o.level}:null)}):function(o){return n.scale.getLabel(o)}}function vd(n,e){return n.type==="category"?n.scale.getLabel(e):e.value}function T2(n,e){var t=e*Math.PI/180,i=n.width,r=n.height,o=i*Math.abs(Math.cos(t))+Math.abs(r*Math.sin(t)),a=i*Math.abs(Math.sin(t))+Math.abs(r*Math.cos(t));return new ve(n.x,n.y,o,a)}function yd(n){var e=n.get("interval");return e??"auto"}function o_(n){return n.type==="category"&&yd(n.getLabelModel())===0}function gu(n,e){var t={};return A(n.mapDimensionsAll(e),function(i){t[Vx(n,i)]=!0}),Oe(t)}var ja=function(){function n(){}return n.prototype.getNeedCrossZero=function(){return!this.option.scale},n.prototype.getCoordSysModel=function(){},n}(),C2={isDimensionStacked:Ai,enableDataStack:Bx,getStackedDimension:Vx};function vu(n,e){return rt(n,null,null,(e=e||{}).state!=="normal")}const I2=Object.freeze(Object.defineProperty({__proto__:null,createDimensions:zx,createList:function(n){return au(null,n)},createScale:function(n,e){var t=e;e instanceof He||(t=new He(e));var i=fu(t);return i.setExtent(n[0],n[1]),wo(i,t),i},createSymbol:St,createTextStyle:vu,dataStack:C2,enableHoverEmphasis:ca,getECData:ye,getLayoutRect:Vt,mixinAxisModelCommonMethods:function(n){ht(n,ja)}},Symbol.toStringTag,{value:"Module"}));var a_=[],A2={registerPreprocessor:eu,registerProcessor:td,registerPostInit:Mx,registerPostUpdate:Tx,registerUpdateLifecycle:tu,registerAction:wn,registerCoordinateSystem:Cx,registerLayout:nd,registerVisual:Ci,registerTransform:Dx,registerLoading:rd,registerMap:Ax,registerImpl:function(n,e){Xl[n]&&mt("Already has an implementation of "+n+"."),Xl[n]=e},PRIORITY:lx,ComponentModel:Se,ComponentView:Ze,SeriesModel:kt,ChartView:st,registerComponentModel:function(n){Se.registerClass(n)},registerComponentView:function(n){Ze.registerClass(n)},registerSeriesModel:function(n){kt.registerClass(n)},registerChartView:function(n){st.registerClass(n)},registerSubTypeDefaulter:function(n,e){Se.registerSubTypeDefaulter(n,e)},registerPainter:function(n,e){tv(n,e)}};function lt(n){W(n)?A(n,function(e){lt(e)}):Me(a_,n)>=0||(a_.push(n),re(n)&&(n={install:n}),n.install(A2))}var D2=1e-8;function s_(n,e){return Math.abs(n-e)r&&(t=a,r=l)}if(t)return function(h){for(var c=0,p=0,d=0,f=h.length,g=h[f-1][0],v=h[f-1][1],y=0;y>1^-(1&s),l=l>>1^-(1&l),r=s+=r,o=l+=o,i.push([s/t,l/t])}return i}function xd(n,e){return U(Ge((n=function(t){if(!t.UTF8Encoding)return t;var i=t,r=i.UTF8Scale;return r==null&&(r=1024),A(i.features,function(o){var a=o.geometry,s=a.encodeOffsets,l=a.coordinates;if(s)switch(a.type){case"LineString":a.coordinates=g_(l,s,r);break;case"Polygon":case"MultiLineString":f_(l,s,r);break;case"MultiPolygon":A(l,function(u,h){return f_(u,s[h],r)})}}),i.UTF8Encoding=!1,i}(n)).features,function(t){return t.geometry&&t.properties&&t.geometry.coordinates.length>0}),function(t){var i=t.properties,r=t.geometry,o=[];switch(r.type){case"Polygon":var a=r.coordinates;o.push(new c_(a[0],a.slice(1)));break;case"MultiPolygon":A(r.coordinates,function(l){l[0]&&o.push(new c_(l[0],l.slice(1)))});break;case"LineString":o.push(new p_([r.coordinates]));break;case"MultiLineString":o.push(new p_(r.coordinates))}var s=new d_(i[e||"name"],o,i.cp);return s.properties=i,s})}const P2=Object.freeze(Object.defineProperty({__proto__:null,MAX_SAFE_INTEGER:9007199254740991,asc:Qo,getPercentWithPrecision:function(n,e,t){return n[e]&&ov(n,t)[e]||0},getPixelPrecision:$h,getPrecision:kn,getPrecisionSafe:zs,isNumeric:Bs,isRadianAroundZero:ea,linearMap:Ye,nice:ec,numericToNumber:na,parseDate:qt,quantile:function(n,e){var t=(n.length-1)*e+1,i=Math.floor(t),r=+n[i-1],o=t-i;return o?r+o*(n[i]-r):r},quantity:av,quantityExponent:ta,reformIntervals:tc,remRadian:Qh,round:Ue},Symbol.toStringTag,{value:"Module"})),O2=Object.freeze(Object.defineProperty({__proto__:null,format:Ca,parse:qt},Symbol.toStringTag,{value:"Module"})),R2=Object.freeze(Object.defineProperty({__proto__:null,Arc:ol,BezierCurve:Nc,BoundingRect:ve,Circle:$n,CompoundPath:zc,Ellipse:il,Group:me,Image:Bt,IncrementalDisplayable:Ny,Line:_t,LinearGradient:va,Polygon:Qn,Polyline:zn,RadialGradient:Bc,Rect:Re,Ring:ga,Sector:en,Text:De,clipPointsByRect:Yc,clipRectByRect:Wy,createIcon:_a,extendPath:Vy,extendShape:By,getShapeClass:Fy,getTransform:dr,initProps:et,makeImage:Gc,makePath:pl,mergePath:nn,registerShape:tn,resizePath:Hc,updateProps:Fe},Symbol.toStringTag,{value:"Module"})),E2=Object.freeze(Object.defineProperty({__proto__:null,addCommas:ip,capitalFirst:ym,encodeHTML:Et,formatTime:function(n,e,t){$e("echarts.format.formatTime","echarts.time.format"),n!=="week"&&n!=="month"&&n!=="quarter"&&n!=="half-year"&&n!=="year"||(n=`MM-dd yyyy`);var i=qt(e),r=t?"getUTC":"get",o=i[r+"FullYear"](),a=i[r+"Month"]()+1,s=i[r+"Date"](),l=i[r+"Hours"](),u=i[r+"Minutes"](),h=i[r+"Seconds"](),c=i[r+"Milliseconds"]();return n=n.replace("MM",wt(a,2)).replace("M",a).replace("yyyy",o).replace("yy",wt(o%100+"",2)).replace("dd",wt(s,2)).replace("d",s).replace("hh",wt(l,2)).replace("h",l).replace("mm",wt(u,2)).replace("m",u).replace("ss",wt(h,2)).replace("s",h).replace("SSS",wt(c,3))},formatTpl:sp,getTextRect:function(n,e,t,i,r,o,a,s){return new De({style:{text:n,font:e,align:t,verticalAlign:i,padding:r,rich:o,overflow:a?"truncate":null,lineHeight:s}}).getBoundingRect()},getTooltipMarker:vm,normalizeCssArray:so,toCamelCase:rp,truncateText:Mv},Symbol.toStringTag,{value:"Module"})),N2=Object.freeze(Object.defineProperty({__proto__:null,bind:he,clone:ie,curry:Te,defaults:ae,each:A,extend:G,filter:Ge,indexOf:Me,inherits:ih,isArray:W,isFunction:re,isObject:Q,isString:j,map:U,merge:pe,reduce:pn},Symbol.toStringTag,{value:"Module"}));var Za=ze();function z2(n){return n.type==="category"?function(e){var t=e.getLabelModel(),i=v_(e,t);return!t.get("show")||e.scale.isBlank()?{labels:[],labelCategoryInterval:i.labelCategoryInterval}:i}(n):function(e){var t=e.scale.getTicks(),i=Xa(e);return{labels:U(t,function(r,o){return{level:r.level,formattedLabel:i(r,o),rawLabel:e.scale.getLabel(r),tickValue:r.value}})}}(n)}function B2(n,e){return n.type==="category"?function(t,i){var r,o,a=y_(t,"ticks"),s=yd(i),l=m_(a,s);if(l)return l;if(i.get("show")&&!t.scale.isBlank()||(r=[]),re(s))r=w_(t,s,!0);else if(s==="auto"){var u=v_(t,t.getLabelModel());o=u.labelCategoryInterval,r=U(u.labels,function(h){return h.tickValue})}else r=__(t,o=s,!0);return x_(a,s,{ticks:r,tickCategoryInterval:o})}(n,e):{ticks:U(n.scale.getTicks(),function(t){return t.value})}}function v_(n,e){var t,i,r=y_(n,"labels"),o=yd(e),a=m_(r,o);return a||(re(o)?t=w_(n,o):(i=o==="auto"?function(s){var l=Za(s).autoInterval;return l??(Za(s).autoInterval=s.calculateCategoryInterval())}(n):o,t=__(n,i)),x_(r,o,{labels:t,labelCategoryInterval:i}))}function y_(n,e){return Za(n)[e]||(Za(n)[e]=[])}function m_(n,e){for(var t=0;t1&&h/l>2&&(u=Math.round(Math.ceil(u/l)*l));var c=o_(n),p=a.get("showMinLabel")||c,d=a.get("showMaxLabel")||c;p&&u!==o[0]&&g(o[0]);for(var f=u;f<=o[1];f+=l)g(f);function g(v){var y={value:v};s.push(t?v:{formattedLabel:i(y),rawLabel:r.getLabel(y),tickValue:v})}return d&&f-l!==o[1]&&g(o[1]),s}function w_(n,e,t){var i=n.scale,r=Xa(n),o=[];return A(i.getTicks(),function(a){var s=i.getLabel(a),l=a.value;e(a.value,s)&&o.push(t?l:{formattedLabel:r(a),rawLabel:s,tickValue:l})}),o}var b_=[0,1],V2=function(){function n(e,t,i){this.onBand=!1,this.inverse=!1,this.dim=e,this.scale=t,this._extent=i||[0,0]}return n.prototype.contain=function(e){var t=this._extent,i=Math.min(t[0],t[1]),r=Math.max(t[0],t[1]);return e>=i&&e<=r},n.prototype.containData=function(e){return this.scale.contain(e)},n.prototype.getExtent=function(){return this._extent.slice()},n.prototype.getPixelPrecision=function(e){return $h(e||this.scale.getExtent(),this._extent)},n.prototype.setExtent=function(e,t){var i=this._extent;i[0]=e,i[1]=t},n.prototype.dataToCoord=function(e,t){var i=this._extent,r=this.scale;return e=r.normalize(e),this.onBand&&r.type==="ordinal"&&S_(i=i.slice(),r.count()),Ye(e,b_,i,t)},n.prototype.coordToData=function(e,t){var i=this._extent,r=this.scale;this.onBand&&r.type==="ordinal"&&S_(i=i.slice(),r.count());var o=Ye(e,i,b_,t);return this.scale.scale(o)},n.prototype.pointToData=function(e,t){},n.prototype.getTicksCoords=function(e){var t=(e=e||{}).tickModel||this.getTickModel(),i=U(B2(this,t).ticks,function(r){return{coord:this.dataToCoord(this.scale.type==="ordinal"?this.scale.getRawOrdinalNumber(r):r),tickValue:r}},this);return function(r,o,a,s){var l=o.length;if(!r.onBand||a||!l)return;var u,h,c=r.getExtent();if(l===1)o[0].coord=c[0],u=o[1]={coord:c[1]};else{var p=o[l-1].tickValue-o[0].tickValue,d=(o[l-1].coord-o[0].coord)/p;A(o,function(v){v.coord-=d/2}),h=1+r.scale.getExtent()[1]-o[l-1].tickValue,u={coord:o[l-1].coord+d*h},o.push(u)}var f=c[0]>c[1];g(o[0].coord,c[0])&&(s?o[0].coord=c[0]:o.shift()),s&&g(c[0],o[0].coord)&&o.unshift({coord:c[0]}),g(c[1],u.coord)&&(s?u.coord=c[1]:o.pop()),s&&g(u.coord,c[1])&&o.push({coord:c[1]});function g(v,y){return v=Ue(v),y=Ue(y),f?v>y:v0&&e<100||(e=5),U(this.scale.getMinorTicks(e),function(t){return U(t,function(i){return{coord:this.dataToCoord(i),tickValue:i}},this)},this)},n.prototype.getViewLabels=function(){return z2(this).labels},n.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},n.prototype.getTickModel=function(){return this.model.getModel("axisTick")},n.prototype.getBandWidth=function(){var e=this._extent,t=this.scale.getExtent(),i=t[1]-t[0]+(this.onBand?1:0);i===0&&(i=1);var r=Math.abs(e[1]-e[0]);return Math.abs(r)/i},n.prototype.calculateCategoryInterval=function(){return function(e){var t=function(T){var C=T.getLabelModel();return{axisRotate:T.getRotate?T.getRotate():T.isHorizontal&&!T.isHorizontal()?90:0,labelRotate:C.get("rotate")||0,font:C.getFont()}}(e),i=Xa(e),r=(t.axisRotate-t.labelRotate)/180*Math.PI,o=e.scale,a=o.getExtent(),s=o.count();if(a[1]-a[0]<1)return 0;var l=1;s>40&&(l=Math.max(1,Math.floor(s/40)));for(var u=a[0],h=e.dataToCoord(u+1)-e.dataToCoord(u),c=Math.abs(h*Math.cos(r)),p=Math.abs(h*Math.sin(r)),d=0,f=0;u<=a[1];u+=l){var g,v,y=Ko(i({value:u}),t.font,"center","top");g=1.3*y.width,v=1.3*y.height,d=Math.max(d,g,7),f=Math.max(f,v,7)}var m=d/c,x=f/p;isNaN(m)&&(m=1/0),isNaN(x)&&(x=1/0);var _=Math.max(0,Math.floor(Math.min(m,x))),w=Za(e.model),b=e.getExtent(),S=w.lastAutoInterval,M=w.lastTickCount;return S!=null&&M!=null&&Math.abs(S-_)<=1&&Math.abs(M-s)<=1&&S>_&&w.axisExtent0===b[0]&&w.axisExtent1===b[1]?_=S:(w.lastTickCount=s,w.lastAutoInterval=_,w.axisExtent0=b[0],w.axisExtent1=b[1]),_}(this)},n}();function S_(n,e){var t=(n[1]-n[0])/e/2;n[0]+=t,n[1]-=t}const Fn=V2;function M_(n){var e=kt.extend(n);return kt.registerClass(e),e}function T_(n){var e=st.extend(n);return st.registerClass(e),e}var qa=2*Math.PI,Sr=_i.CMD,F2=["top","right","bottom","left"];function G2(n,e,t,i,r){var o=t.width,a=t.height;switch(n){case"top":i.set(t.x+o/2,t.y-e),r.set(0,-1);break;case"bottom":i.set(t.x+o/2,t.y+a+e),r.set(0,1);break;case"left":i.set(t.x-e,t.y+a/2),r.set(-1,0);break;case"right":i.set(t.x+o+e,t.y+a/2),r.set(1,0)}}function H2(n,e,t,i,r,o,a,s,l){a-=n,s-=e;var u=Math.sqrt(a*a+s*s),h=(a/=u)*t+n,c=(s/=u)*t+e;if(Math.abs(i-r)%qa<1e-4)return l[0]=h,l[1]=c,u-t;if(o){var p=i;i=qn(r),r=qn(p)}else i=qn(i),r=qn(r);i>r&&(r+=qa);var d=Math.atan2(s,a);if(d<0&&(d+=qa),d>=i&&d<=r||d+qa>=i&&d+qa<=r)return l[0]=h,l[1]=c,u-t;var f=t*Math.cos(i)+n,g=t*Math.sin(i)+e,v=t*Math.cos(r)+n,y=t*Math.sin(r)+e,m=(f-a)*(f-a)+(g-s)*(g-s),x=(v-a)*(v-a)+(y-s)*(y-s);return m0){e=e/180*Math.PI,Mn.fromArray(n[0]),Ee.fromArray(n[1]),Xe.fromArray(n[2]),fe.sub(Gn,Mn,Ee),fe.sub(Hn,Xe,Ee);var t=Gn.len(),i=Hn.len();if(!(t<.001||i<.001)){Gn.scale(1/t),Hn.scale(1/i);var r=Gn.dot(Hn);if(Math.cos(e)1&&fe.copy(Mt,Xe),Mt.toArray(n[1])}}}}function U2(n,e,t){if(t<=180&&t>0){t=t/180*Math.PI,Mn.fromArray(n[0]),Ee.fromArray(n[1]),Xe.fromArray(n[2]),fe.sub(Gn,Ee,Mn),fe.sub(Hn,Xe,Ee);var i=Gn.len(),r=Hn.len();if(!(i<.001||r<.001)&&(Gn.scale(1/i),Hn.scale(1/r),Gn.dot(e)=a)fe.copy(Mt,Xe);else{Mt.scaleAndAdd(Hn,o/Math.tan(Math.PI/2-s));var l=Xe.x!==Ee.x?(Mt.x-Ee.x)/(Xe.x-Ee.x):(Mt.y-Ee.y)/(Xe.y-Ee.y);if(isNaN(l))return;l<0?fe.copy(Mt,Ee):l>1&&fe.copy(Mt,Xe)}Mt.toArray(n[1])}}}function _d(n,e,t,i){var r=t==="normal",o=r?n:n.ensureState(t);o.ignore=e;var a=i.get("smooth");a&&a===!0&&(a=.3),o.shape=o.shape||{},a>0&&(o.shape.smooth=a);var s=i.getModel("lineStyle").getLineStyle();r?n.useStyle(s):o.style=s}function X2(n,e){var t=e.smooth,i=e.points;if(i)if(n.moveTo(i[0][0],i[0][1]),t>0&&i.length>=3){var r=gs(i[0],i[1]),o=gs(i[1],i[2]);if(!r||!o)return n.lineTo(i[1][0],i[1][1]),void n.lineTo(i[2][0],i[2][1]);var a=Math.min(r,o)*t,s=vs([],i[1],i[0],a/r),l=vs([],i[1],i[2],a/o),u=vs([],s,l,.5);n.bezierCurveTo(s[0],s[1],s[0],s[1],u[0],u[1]),n.bezierCurveTo(l[0],l[1],l[0],l[1],i[2][0],i[2][1])}else for(var h=1;h0&&o&&_(-h/a,0,a);var f,g,v=n[0],y=n[a-1];return m(),f<0&&w(-f,.8),g<0&&w(g,.8),m(),x(f,g,1),x(g,f,-1),m(),f<0&&b(-f),g<0&&b(g),u}function m(){f=v.rect[e]-i,g=r-y.rect[e]-y.rect[t]}function x(S,M,T){if(S<0){var C=Math.min(M,-S);if(C>0){_(C*T,0,a);var I=C+S;I<0&&w(-I*T,1)}else w(-S*T,1)}}function _(S,M,T){S!==0&&(u=!0);for(var C=M;C0)for(I=0;I0;I--)_(-(T[I-1]*R),I,a)}}function b(S){var M=S<0?-1:1;S=Math.abs(S);for(var T=Math.ceil(S/(a-1)),C=0;C0?_(T,0,C+1):_(-T,a-C-1,a),(S-=T)<=0)return}}function O_(n,e,t,i){return P_(n,"y","height",e,t,i)}function R_(n){var e=[];n.sort(function(g,v){return v.priority-g.priority});var t=new ve(0,0,0,0);function i(g){if(!g.ignore){var v=g.ensureState("emphasis");v.ignore==null&&(v.ignore=!1)}g.ignore=!0}for(var r=0;r=0&&i.attr(f.oldLayoutSelect),Me(h,"emphasis")>=0&&i.attr(f.oldLayoutEmphasis)),Fe(i,l,t,s)}else if(i.attr(l),!io(i).valueAnimation){var c=de(i.style.opacity,1);i.style.opacity=0,et(i,{style:{opacity:c}},t,s)}if(f.oldLayout=l,i.states.select){var p=f.oldLayoutSelect={};xu(p,l,_u),xu(p,i.states.select,_u)}if(i.states.emphasis){var d=f.oldLayoutEmphasis={};xu(d,l,_u),xu(d,i.states.emphasis,_u)}em(i,s,u,t,t)}if(r&&!r.ignore&&!r.invisible){o=(f=q2(r)).oldLayout;var f,g={points:r.shape.points};o?(r.attr({shape:o}),Fe(r,{shape:g},t)):(r.setShape(g),r.style.strokePercent=0,et(r,{style:{strokePercent:1}},t)),f.oldLayout=g}},n}();const J2=K2;var bd=ze();Yf=Object.freeze(Object.defineProperty({__proto__:null,Axis:Fn,ChartView:st,ComponentModel:Se,ComponentView:Ze,List:ou,Model:He,PRIORITY:lx,SeriesModel:kt,color:IM,connect:function(n){if(W(n)){var e=n;n=null,A(e,function(t){t.group!=null&&(n=t.group)}),n=n||"g_"+jI++,A(e,function(t){t.group=n})}return Ql[n]=!0,n},dataTool:{},dependencies:{zrender:"5.5.0"},disConnect:ZI,disconnect:Sx,dispose:function(n){j(n)?n=_r[n]:n instanceof Kl||(n=Qp(n)),n instanceof Kl&&!n.isDisposed()&&n.dispose()},env:_e,extendChartView:T_,extendComponentModel:function(n){var e=Se.extend(n);return Se.registerClass(e),e},extendComponentView:function(n){var e=Ze.extend(n);return Ze.registerClass(e),e},extendSeriesModel:M_,format:E2,getCoordinateSystemDimensions:function(n){var e=Dl.get(n);if(e)return e.getDimensionsInfo?e.getDimensionsInfo():e.dimensions.slice()},getInstanceByDom:Qp,getInstanceById:function(n){return _r[n]},getMap:function(n){var e=sx("getMap");return e&&e(n)},graphic:R2,helper:I2,init:function(n,e,t){var i=!(t&&t.ssr);if(i){if(!n)throw new Error("Initialize failed: invalid dom.");var r=Qp(n);if(r)return Je("There is a chart instance already initialized on the dom."),r;!pi(n)||n.nodeName.toUpperCase()==="CANVAS"||(n.clientWidth||t&&t.width!=null)&&(n.clientHeight||t&&t.height!=null)||Je("Can't get DOM width or height. Please check dom.clientWidth and dom.clientHeight. They should not be 0.For example, you may need to call this in the callback of window.onload.")}var o=new Kl(n,e,t);return o.id="ec_"+XI++,_r[o.id]=o,i&&mv(n,$p,o.id),yx(o),_n.trigger("afterinit",o),o},innerDrawElementOnCanvas:Bp,matrix:lM,number:P2,parseGeoJSON:xd,parseGeoJson:xd,registerAction:wn,registerCoordinateSystem:Cx,registerLayout:nd,registerLoading:rd,registerLocale:$c,registerMap:Ax,registerPostInit:Mx,registerPostUpdate:Tx,registerPreprocessor:eu,registerProcessor:td,registerTheme:ed,registerTransform:Dx,registerUpdateLifecycle:tu,registerVisual:Ci,setCanvasCreator:function(n){vn("setCanvasCreator is deprecated. Use setPlatformAPI({ createCanvas }) instead."),Xf({createCanvas:n})},setPlatformAPI:Xf,throttle:Nl,time:O2,use:lt,util:N2,vector:JS,version:"5.5.0",zrUtil:ZS,zrender:XM},Symbol.toStringTag,{value:"Module"}));const $2=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t}return V(e,n),e.prototype.getInitialData=function(t){var i=t.coordinateSystem;if(i!=="polar"&&i!=="cartesian2d")throw new Error("Line not support coordinateSystem besides cartesian and polar");return au(null,this,{useEncodeDefaulter:!0})},e.prototype.getLegendIcon=function(t){var i=new me,r=St("line",0,t.itemHeight/2,t.itemWidth,0,t.lineStyle.stroke,!1);i.add(r),r.setStyle(t.lineStyle);var o=this.getData().getVisual("symbol"),a=this.getData().getVisual("symbolRotate"),s=o==="none"?"circle":o,l=.8*t.itemHeight,u=St(s,(t.itemWidth-l)/2,(t.itemHeight-l)/2,l,l,t.itemStyle.fill);i.add(u),u.setStyle(t.itemStyle);var h=t.iconRotate==="inherit"?a:t.iconRotate||0;return u.rotation=h*Math.PI/180,u.setOrigin([t.itemWidth/2,t.itemHeight/2]),s.indexOf("empty")>-1&&(u.style.stroke=u.style.fill,u.style.fill="#fff",u.style.lineWidth=2),i},e.type="series.line",e.dependencies=["grid","polar"],e.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:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},e}(kt);function wu(n,e){var t=n.mapDimensionsAll("defaultedLabel"),i=t.length;if(i===1){var r=vo(n,e,t[0]);return r!=null?r+"":null}if(i){for(var o=[],a=0;a=0&&i.push(e[o])}return i.join(" ")}var Q2=function(n){function e(t,i,r,o){var a=n.call(this)||this;return a.updateData(t,i,r,o),a}return V(e,n),e.prototype._createSymbol=function(t,i,r,o,a){this.removeAll();var s=St(t,-1,-1,2,2,null,a);s.attr({z2:100,culling:!0,scaleX:o[0]/2,scaleY:o[1]/2}),s.drift=eA,this._symbolType=t,this.add(s)},e.prototype.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(null,t)},e.prototype.getSymbolType=function(){return this._symbolType},e.prototype.getSymbolPath=function(){return this.childAt(0)},e.prototype.highlight=function(){Kr(this.childAt(0))},e.prototype.downplay=function(){Jr(this.childAt(0))},e.prototype.setZ=function(t,i){var r=this.childAt(0);r.zlevel=t,r.z=i},e.prototype.setDraggable=function(t,i){var r=this.childAt(0);r.draggable=t,r.cursor=!i&&t?"move":r.cursor},e.prototype.updateData=function(t,i,r,o){this.silent=!1;var a=t.getItemVisual(i,"symbol")||"circle",s=t.hostModel,l=e.getSymbolSize(t,i),u=a!==this._symbolType,h=o&&o.disableAnimation;if(u){var c=t.getItemVisual(i,"symbolKeepAspect");this._createSymbol(a,t,i,l,c)}else{(d=this.childAt(0)).silent=!1;var p={scaleX:l[0]/2,scaleY:l[1]/2};h?d.attr(p):Fe(d,p,s,i),ma(d)}if(this._updateCommon(t,i,l,r,o),u){var d=this.childAt(0);h||(p={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:d.style.opacity}},d.scaleX=d.scaleY=0,d.style.opacity=0,et(d,p,s,i))}h&&this.childAt(0).stopAnimation("leave")},e.prototype._updateCommon=function(t,i,r,o,a){var s,l,u,h,c,p,d,f,g,v=this.childAt(0),y=t.hostModel;if(o&&(s=o.emphasisItemStyle,l=o.blurItemStyle,u=o.selectItemStyle,h=o.focus,c=o.blurScope,d=o.labelStatesModels,f=o.hoverScale,g=o.cursorStyle,p=o.emphasisDisabled),!o||t.hasItemOption){var m=o&&o.itemModel?o.itemModel:t.getItemModel(i),x=m.getModel("emphasis");s=x.getModel("itemStyle").getItemStyle(),u=m.getModel(["select","itemStyle"]).getItemStyle(),l=m.getModel(["blur","itemStyle"]).getItemStyle(),h=x.get("focus"),c=x.get("blurScope"),p=x.get("disabled"),d=ti(m),f=x.getShallow("scale"),g=m.getShallow("cursor")}var _=t.getItemVisual(i,"symbolRotate");v.attr("rotation",(_||0)*Math.PI/180||0);var w=Ep(t.getItemVisual(i,"symbolOffset"),r);w&&(v.x=w[0],v.y=w[1]),g&&v.attr("cursor",g);var b=t.getItemVisual(i,"style"),S=b.fill;if(v instanceof Bt){var M=v.style;v.useStyle(G({image:M.image,x:M.x,y:M.y,width:M.width,height:M.height},b))}else v.__isEmptyBrush?v.useStyle(G({},b)):v.useStyle(b),v.style.decal=null,v.setColor(S,a&&a.symbolInnerColor),v.style.strokeNoScale=!0;var T=t.getItemVisual(i,"liftZ"),C=this._z2;T!=null?C==null&&(this._z2=v.z2,v.z2+=T):C!=null&&(v.z2=C,this._z2=null);var I=a&&a.useNameLabel;ei(v,d,{labelFetcher:y,labelDataIndex:i,defaultText:function(R){return I?t.getName(R):wu(t,R)},inheritColor:S,defaultOpacity:b.opacity}),this._sizeX=r[0]/2,this._sizeY=r[1]/2;var D=v.ensureState("emphasis");D.style=s,v.ensureState("select").style=u,v.ensureState("blur").style=l;var L=f==null||f===!0?Math.max(1.1,3/this._sizeY):isFinite(f)&&f>0?+f:1;D.scaleX=this._sizeX*L,D.scaleY=this._sizeY*L,this.setSymbolScale(1),En(this,h,c,p)},e.prototype.setSymbolScale=function(t){this.scaleX=this.scaleY=t},e.prototype.fadeOut=function(t,i,r){var o=this.childAt(0),a=ye(this).dataIndex,s=r&&r.animation;if(this.silent=o.silent=!0,r&&r.fadeLabel){var l=o.getTextContent();l&&ya(l,{style:{opacity:0}},i,{dataIndex:a,removeOpt:s,cb:function(){o.removeTextContent()}})}else o.removeTextContent();ya(o,{style:{opacity:0},scaleX:0,scaleY:0},i,{dataIndex:a,cb:t,removeOpt:s})},e.getSymbolSize=function(t,i){return H0(t.getItemVisual(i,"symbolSize"))},e}(me);function eA(n,e){this.parent.drift(n,e)}const Sd=Q2;function Md(n,e,t,i){return e&&!isNaN(e[0])&&!isNaN(e[1])&&!(i.isIgnore&&i.isIgnore(t))&&!(i.clipShape&&!i.clipShape.contain(e[0],e[1]))&&n.getItemVisual(t,"symbol")!=="none"}function z_(n){return n==null||Q(n)||(n={isIgnore:n}),n||{}}function B_(n){var e=n.hostModel,t=e.getModel("emphasis");return{emphasisItemStyle:t.getModel("itemStyle").getItemStyle(),blurItemStyle:e.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:e.getModel(["select","itemStyle"]).getItemStyle(),focus:t.get("focus"),blurScope:t.get("blurScope"),emphasisDisabled:t.get("disabled"),hoverScale:t.get("scale"),labelStatesModels:ti(e),cursorStyle:e.get("cursor")}}var tA=function(){function n(e){this.group=new me,this._SymbolCtor=e||Sd}return n.prototype.updateData=function(e,t){this._progressiveEls=null,t=z_(t);var i=this.group,r=e.hostModel,o=this._data,a=this._SymbolCtor,s=t.disableAnimation,l=B_(e),u={disableAnimation:s},h=t.getSymbolPoint||function(c){return e.getItemLayout(c)};o||i.removeAll(),e.diff(o).add(function(c){var p=h(c);if(Md(e,p,c,t)){var d=new a(e,c,l,u);d.setPosition(p),e.setItemGraphicEl(c,d),i.add(d)}}).update(function(c,p){var d=o.getItemGraphicEl(p),f=h(c);if(Md(e,f,c,t)){var g=e.getItemVisual(c,"symbol")||"circle",v=d&&d.getSymbolType&&d.getSymbolType();if(!d||v&&v!==g)i.remove(d),(d=new a(e,c,l,u)).setPosition(f);else{d.updateData(e,c,l,u);var y={x:f[0],y:f[1]};s?d.attr(y):Fe(d,y,r)}i.add(d),e.setItemGraphicEl(c,d)}else i.remove(d)}).remove(function(c){var p=o.getItemGraphicEl(c);p&&p.fadeOut(function(){i.remove(p)},r)}).execute(),this._getSymbolPoint=h,this._data=e},n.prototype.updateLayout=function(){var e=this,t=this._data;t&&t.eachItemGraphicEl(function(i,r){var o=e._getSymbolPoint(r);i.setPosition(o),i.markRedraw()})},n.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=B_(e),this._data=null,this.group.removeAll()},n.prototype.incrementalUpdate=function(e,t,i){function r(l){l.isGroup||(l.incremental=!0,l.ensureState("emphasis").hoverLayer=!0)}this._progressiveEls=[],i=z_(i);for(var o=e.start;o0?v=y[0]:y[1]<0&&(v=y[1]),v}(r,t),a=i.dim,s=r.dim,l=e.mapDimension(s),u=e.mapDimension(a),h=s==="x"||s==="radius"?1:0,c=U(n.dimensions,function(f){return e.mapDimension(f)}),p=!1,d=e.getCalculationInfo("stackResultDimension");return Ai(e,c[0])&&(p=!0,c[0]=d),Ai(e,c[1])&&(p=!0,c[1]=d),{dataDimsForPoint:c,valueStart:o,valueAxisDim:s,baseAxisDim:a,stacked:!!p,valueDim:l,baseDim:u,baseDataOffset:h,stackedOverDimension:e.getCalculationInfo("stackedOverDimension")}}function F_(n,e,t,i){var r=NaN;n.stacked&&(r=t.get(t.getCalculationInfo("stackedOverDimension"),i)),isNaN(r)&&(r=n.valueStart);var o=n.baseDataOffset,a=[];return a[o]=t.get(n.baseDim,i),a[1-o]=r,e.dataToPoint(a)}var Di=Math.min,ki=Math.max;function Mr(n,e){return isNaN(n)||isNaN(e)}function Td(n,e,t,i,r,o,a,s,l){for(var u,h,c,p,d,f,g=t,v=0;v=r||g<0)break;if(Mr(y,m)){if(l){g+=o;continue}break}if(g===t)n[o>0?"moveTo":"lineTo"](y,m),c=y,p=m;else{var x=y-u,_=m-h;if(x*x+_*_<.5){g+=o;continue}if(a>0){for(var w=g+o,b=e[2*w],S=e[2*w+1];b===y&&S===m&&v=i||Mr(b,S))d=y,f=m;else{C=b-u,I=S-h;var R=y-u,O=b-y,E=m-h,k=S-m,P=void 0,N=void 0;if(s==="x"){var B=C>0?1:-1;d=y-B*(P=Math.abs(R))*a,f=m,D=y+B*(N=Math.abs(O))*a,L=m}else if(s==="y"){var z=I>0?1:-1;d=y,f=m-z*(P=Math.abs(E))*a,D=y,L=m+z*(N=Math.abs(k))*a}else P=Math.sqrt(R*R+E*E),d=y-C*a*(1-(T=(N=Math.sqrt(O*O+k*k))/(N+P))),f=m-I*a*(1-T),L=m+I*a*T,D=Di(D=y+C*a*T,ki(b,y)),L=Di(L,ki(S,m)),D=ki(D,Di(b,y)),f=m-(I=(L=ki(L,Di(S,m)))-m)*P/N,d=Di(d=y-(C=D-y)*P/N,ki(u,y)),f=Di(f,ki(h,m)),D=y+(C=y-(d=ki(d,Di(u,y))))*N/P,L=m+(I=m-(f=ki(f,Di(h,m))))*N/P}n.bezierCurveTo(c,p,d,f,y,m),c=D,p=L}else n.lineTo(y,m)}u=y,h=m,g+=o}return v}var G_=function(){this.smooth=0,this.smoothConstraint=!0},iA=function(n){function e(t){var i=n.call(this,t)||this;return i.type="ec-polyline",i}return V(e,n),e.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},e.prototype.getDefaultShape=function(){return new G_},e.prototype.buildPath=function(t,i){var r=i.points,o=0,a=r.length/2;if(i.connectNulls){for(;a>0&&Mr(r[2*a-2],r[2*a-1]);a--);for(;o=0){var m=l?(p-o)*y+o:(c-r)*y+r;return l?[t,m]:[m,t]}r=c,o=p;break;case s.C:c=a[h++],p=a[h++],d=a[h++],f=a[h++],g=a[h++],v=a[h++];var x=l?Ts(r,c,d,g,t,u):Ts(o,p,f,v,t,u);if(x>0)for(var _=0;_=0)return m=l?tt(o,p,f,v,w):tt(r,c,d,g,w),l?[t,m]:[m,t]}r=g,o=v}}},e}(Ae),rA=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e}(G_),oA=function(n){function e(t){var i=n.call(this,t)||this;return i.type="ec-polygon",i}return V(e,n),e.prototype.getDefaultShape=function(){return new rA},e.prototype.buildPath=function(t,i){var r=i.points,o=i.stackedOnPoints,a=0,s=r.length/2,l=i.smoothMonotone;if(i.connectNulls){for(;s>0&&Mr(r[2*s-2],r[2*s-1]);s--);for(;a=0;a--){var s=n.getDimensionInfo(i[a].dimension);if((r=s&&s.coordDim)==="x"||r==="y"){o=i[a];break}}if(o){var l=e.getAxis(r),u=U(o.stops,function(m){return{coord:l.toGlobalCoord(l.dataToCoord(m.value)),color:m.color}}),h=u.length,c=o.outerColors.slice();h&&u[0].coord>u[h-1].coord&&(u.reverse(),c.reverse());var p=function(m,x){var _,w,b=[],S=m.length;function M(D,L,R){var O=D.coord;return{coord:R,color:Dh((R-O)/(L.coord-O),[D.color,L.color])}}for(var T=0;Tx){w?b.push(M(w,C,x)):_&&b.push(M(_,C,0),M(_,C,x));break}_&&(b.push(M(_,C,0)),_=null),b.push(C),w=C}}return b}(u,r==="x"?t.getWidth():t.getHeight()),d=p.length;if(!d&&h)return u[0].coord<0?c[1]?c[1]:u[h-1].color:c[0]?c[0]:u[0].color;var f=p[0].coord-10,g=p[d-1].coord+10,v=g-f;if(v<.001)return"transparent";A(p,function(m){m.offset=(m.coord-f)/v}),p.push({offset:d?p[d-1].offset:.5,color:c[1]||"transparent"}),p.unshift({offset:d?p[0].offset:.5,color:c[0]||"transparent"});var y=new va(0,0,0,0,p,!0);return y[r]=f,y[r+"2"]=g,y}console.warn("Visual map on line style only support x or y dimension.")}else console.warn("Visual map on line style is only supported on cartesian2d.")}function sA(n,e,t){var i=n.get("showAllSymbol"),r=i==="auto";if(!i||r){var o=t.getAxesByScale("ordinal")[0];if(o&&(!r||!function(l,u){var h=l.getExtent(),c=Math.abs(h[1]-h[0])/l.scale.count();isNaN(c)&&(c=0);for(var p=u.count(),d=Math.max(1,Math.round(p/5)),f=0;fc)return!1;return!0}(o,e))){var a=e.mapDimension(o.dim),s={};return A(o.getViewLabels(),function(l){var u=o.scale.getRawOrdinalNumber(l.tickValue);s[u]=1}),function(l){return!s.hasOwnProperty(e.get(a,l))}}}}function q_(n,e){return[n[2*e],n[2*e+1]]}function K_(n){if(n.get(["endLabel","show"]))return!0;for(var e=0;e0&&t.get(["emphasis","lineStyle","width"])==="bolder"&&(g.getState("emphasis").style.lineWidth=+g.style.lineWidth+1),ye(g).seriesIndex=t.seriesIndex,En(g,E,k,P);var N=Z_(t.get("smooth")),B=t.get("smoothMonotone");if(g.setShape({smooth:N,smoothMonotone:B,connectNulls:M}),v){var z=l.getCalculationInfo("stackedOnSeries"),X=0;v.useStyle(ae(h.getAreaStyle(),{fill:L,opacity:.7,lineJoin:"bevel",decal:l.getVisual("style").decal})),z&&(X=Z_(z.get("smooth"))),v.setShape({smooth:N,stackedOnSmooth:X,smoothMonotone:B,connectNulls:M}),bi(v,t,"areaStyle"),ye(v).seriesIndex=t.seriesIndex,En(v,E,k,P)}var Z=function(F){o._changePolyState(F)};l.eachItemGraphicEl(function(F){F&&(F.onHoverStateChange=Z)}),this._polyline.onHoverStateChange=Z,this._data=l,this._coordSys=a,this._stackedOnPoints=b,this._points=c,this._step=D,this._valueOrigin=_,t.get("triggerLineEvent")&&(this.packEventData(t,g),v&&this.packEventData(t,v))},e.prototype.packEventData=function(t,i){ye(i).eventData={componentType:"series",componentSubType:"line",componentIndex:t.componentIndex,seriesIndex:t.seriesIndex,seriesName:t.name,seriesType:"line"}},e.prototype.highlight=function(t,i,r,o){var a=t.getData(),s=$i(a,o);if(this._changePolyState("emphasis"),!(s instanceof Array)&&s!=null&&s>=0){var l=a.getLayout("points"),u=a.getItemGraphicEl(s);if(!u){var h=l[2*s],c=l[2*s+1];if(isNaN(h)||isNaN(c)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(h,c))return;var p=t.get("zlevel")||0,d=t.get("z")||0;(u=new Sd(a,s)).x=h,u.y=c,u.setZ(p,d);var f=u.getSymbolPath().getTextContent();f&&(f.zlevel=p,f.z=d,f.z2=this._polyline.z2+1),u.__temp=!0,a.setItemGraphicEl(s,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else st.prototype.highlight.call(this,t,i,r,o)},e.prototype.downplay=function(t,i,r,o){var a=t.getData(),s=$i(a,o);if(this._changePolyState("normal"),s!=null&&s>=0){var l=a.getItemGraphicEl(s);l&&(l.__temp?(a.setItemGraphicEl(s,null),this.group.remove(l)):l.downplay())}else st.prototype.downplay.call(this,t,i,r,o)},e.prototype._changePolyState=function(t){var i=this._polygon;Tc(this._polyline,t),i&&Tc(i,t)},e.prototype._newPolyline=function(t){var i=this._polyline;return i&&this._lineGroup.remove(i),i=new iA({shape:{points:t},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(i),this._polyline=i,i},e.prototype._newPolygon=function(t,i){var r=this._polygon;return r&&this._lineGroup.remove(r),r=new oA({shape:{points:t,stackedOnPoints:i},segmentIgnoreThreshold:2}),this._lineGroup.add(r),this._polygon=r,r},e.prototype._initSymbolLabelAnimation=function(t,i,r){var o,a,s=i.getBaseAxis(),l=s.inverse;i.type==="cartesian2d"?(o=s.isHorizontal(),a=!1):i.type==="polar"&&(o=s.dim==="angle",a=!0);var u=t.hostModel,h=u.get("animationDuration");re(h)&&(h=h(null));var c=u.get("animationDelay")||0,p=re(c)?c(null):c;t.eachItemGraphicEl(function(d,f){var g=d;if(g){var v=[d.x,d.y],y=void 0,m=void 0,x=void 0;if(r)if(a){var _=r,w=i.pointToCoord(v);o?(y=_.startAngle,m=_.endAngle,x=-w[1]/180*Math.PI):(y=_.r0,m=_.r,x=w[0])}else{var b=r;o?(y=b.x,m=b.x+b.width,x=d.x):(y=b.y+b.height,m=b.y,x=d.y)}var S=m===y?0:(x-y)/(m-y);l&&(S=1-S);var M=re(c)?c(f):h*S+p,T=g.getSymbolPath(),C=T.getTextContent();g.attr({scaleX:0,scaleY:0}),g.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:M}),C&&C.animateFrom({style:{opacity:0}},{duration:300,delay:M}),T.disableLabelAnimation=!0}})},e.prototype._initOrUpdateEndLabel=function(t,i,r){var o=t.getModel("endLabel");if(K_(t)){var a=t.getData(),s=this._polyline,l=a.getLayout("points");if(!l)return s.removeTextContent(),void(this._endLabel=null);var u=this._endLabel;u||((u=this._endLabel=new De({z2:200})).ignoreClip=!0,s.setTextContent(this._endLabel),s.disableLabelAnimation=!0);var h=function(c){for(var p,d,f=c.length/2;f>0&&(p=c[2*f-2],d=c[2*f-1],isNaN(p)||isNaN(d));f--);return f-1}(l);h>=0&&(ei(s,ti(t,"endLabel"),{inheritColor:r,labelFetcher:t,labelDataIndex:h,defaultText:function(c,p,d){return d!=null?N_(a,d):wu(a,c)},enableTextSetter:!0},function(c,p){var d=p.getBaseAxis(),f=d.isHorizontal(),g=d.inverse,v=f?g?"right":"left":"center",y=f?"middle":g?"top":"bottom";return{normal:{align:c.get("align")||v,verticalAlign:c.get("verticalAlign")||y}}}(o,i)),s.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},e.prototype._endLabelOnDuring=function(t,i,r,o,a,s,l){var u=this._endLabel,h=this._polyline;if(u){t<1&&o.originalX==null&&(o.originalX=u.x,o.originalY=u.y);var c=r.getLayout("points"),p=r.hostModel,d=p.get("connectNulls"),f=s.get("precision"),g=s.get("distance")||0,v=l.getBaseAxis(),y=v.isHorizontal(),m=v.inverse,x=i.shape,_=m?y?x.x:x.y+x.height:y?x.x+x.width:x.y,w=(y?g:0)*(m?-1:1),b=(y?0:-g)*(m?-1:1),S=y?"x":"y",M=function(k,P,N){for(var B,z,X=k.length/2,Z=N==="x"?0:1,F=0,Y=-1,K=0;K=P||B>=P&&z<=P){Y=K;break}F=K,B=z}else B=z;return{range:[F,Y],t:(P-B)/(z-B)}}(c,_,S),T=M.range,C=T[1]-T[0],I=void 0;if(C>=1){if(C>1&&!d){var D=q_(c,T[0]);u.attr({x:D[0]+w,y:D[1]+b}),a&&(I=p.getRawValue(T[0]))}else{(D=h.getPointOn(_,S))&&u.attr({x:D[0]+w,y:D[1]+b});var L=p.getRawValue(T[0]),R=p.getRawValue(T[1]);a&&(I=xv(r,f,L,R,M.t))}o.lastFrameIndex=T[0]}else{var O=t===1||o.lastFrameIndex>0?T[0]:0;D=q_(c,O),a&&(I=p.getRawValue(O)),u.attr({x:D[0]+w,y:D[1]+b})}if(a){var E=io(u);typeof E.setLabelText=="function"&&E.setLabelText(I)}}},e.prototype._doUpdateAnimation=function(t,i,r,o,a,s,l){var u=this._polyline,h=this._polygon,c=t.hostModel,p=function(b,S,M,T,C,I,D,L){for(var R=function(vt,Ke){var ut=[];return Ke.diff(vt).add(function(We){ut.push({cmd:"+",idx:We})}).update(function(We,Rt){ut.push({cmd:"=",idx:Rt,idx1:We})}).remove(function(We){ut.push({cmd:"-",idx:We})}).execute(),ut}(b,S),O=[],E=[],k=[],P=[],N=[],B=[],z=[],X=V_(C,S,D),Z=b.getLayout("points")||[],F=S.getLayout("points")||[],Y=0;Y3e3||h&&j_(f,v)>3e3)return u.stopAnimation(),u.setShape({points:g}),void(h&&(h.stopAnimation(),h.setShape({points:g,stackedOnPoints:v})));u.shape.__points=p.current,u.shape.points=d;var y={shape:{points:g}};p.current!==d&&(y.shape.__points=p.next),u.stopAnimation(),Fe(u,y,c),h&&(h.setShape({points:d,stackedOnPoints:f}),h.stopAnimation(),Fe(h,{shape:{stackedOnPoints:v}},c),u.shape.points!==h.shape.points&&(h.shape.points=u.shape.points));for(var m=[],x=p.status,_=0;_e&&(e=n[t]);return isFinite(e)?e:NaN},min:function(n){for(var e=1/0,t=0;te&&(e=o,t=r)}return isFinite(t)?t:NaN},nearest:function(n){return n[0]}},cA=function(n){return Math.round(n.length/2)};function J_(n){return{seriesType:n,reset:function(e,t,i){var r=e.getData(),o=e.get("sampling"),a=e.coordinateSystem,s=r.count();if(s>10&&a.type==="cartesian2d"&&o){var l=a.getBaseAxis(),u=a.getOtherAxis(l),h=l.getExtent(),c=i.getDevicePixelRatio(),p=Math.abs(h[1]-h[0])*(c||1),d=Math.round(s/p);if(isFinite(d)&&d>1){o==="lttb"&&e.setData(r.lttbDownSample(r.mapDimension(u.dim),1/d));var f=void 0;j(o)?f=hA[o]:re(o)&&(f=o),f&&e.setData(r.downSample(r.mapDimension(u.dim),1/d,f,cA))}}}}}var $_=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.getInitialData=function(t,i){return au(null,this,{useEncodeDefaulter:!0})},e.prototype.getMarkerPosition=function(t,i,r){var o=this.coordinateSystem;if(o&&o.clampData){var a=o.clampData(t),s=o.dataToPoint(a);if(r)A(o.getAxes(),function(p,d){if(p.type==="category"&&i!=null){var f=p.getTicksCoords(),g=p.getTickModel().get("alignWithLabel"),v=a[d],y=i[d]==="x1"||i[d]==="y1";if(y&&!g&&(v+=1),f.length<2)return;if(f.length===2)return void(s[d]=p.toGlobalCoord(p.getExtent()[y?1:0]));for(var m=void 0,x=void 0,_=1,w=0;wv){x=(b+m)/2;break}w===1&&(_=S-f[0].tickValue)}x==null&&(m?m&&(x=f[f.length-1].coord):x=f[0].coord),s[d]=p.toGlobalCoord(x)}});else{var l=this.getData(),u=l.getLayout("offset"),h=l.getLayout("size"),c=o.getBaseAxis().isHorizontal()?0:1;s[c]+=u+h/2}return s}return[NaN,NaN]},e.type="series.__base_bar__",e.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod"},e}(kt);kt.registerClass($_);const bu=$_,pA=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.getInitialData=function(){return au(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},e.prototype.getProgressive=function(){return!!this.get("large")&&this.get("progressive")},e.prototype.getProgressiveThreshold=function(){var t=this.get("progressiveThreshold"),i=this.get("largeThreshold");return i>t&&(t=i),t},e.prototype.brushSelector=function(t,i,r){return r.rect(i.getItemLayout(t))},e.type="series.bar",e.dependencies=["grid","polar"],e.defaultOption=ba(bu.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:"#212121"}},realtimeSort:!1}),e}(bu);var dA=function(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=2*Math.PI,this.clockwise=!0},fA=function(n){function e(t){var i=n.call(this,t)||this;return i.type="sausage",i}return V(e,n),e.prototype.getDefaultShape=function(){return new dA},e.prototype.buildPath=function(t,i){var r=i.cx,o=i.cy,a=Math.max(i.r0||0,0),s=Math.max(i.r,0),l=.5*(s-a),u=a+l,h=i.startAngle,c=i.endAngle,p=i.clockwise,d=2*Math.PI,f=p?c-hs)return!0;s=c}return!1},e.prototype._isOrderDifferentInView=function(t,i){for(var r=i.scale,o=r.getExtent(),a=Math.max(0,o[0]),s=Math.min(o[1],r.getOrdinalMeta().categories.length-1);a<=s;++a)if(t.ordinalNumbers[a]!==r.getRawOrdinalNumber(a))return!0},e.prototype._updateSortWithinSameData=function(t,i,r,o){if(this._isOrderChangedWithinSameData(t,i,r)){var a=this._dataSort(t,r,i);this._isOrderDifferentInView(a,r)&&(this._removeOnRenderedListener(o),o.dispatchAction({type:"changeAxisOrder",componentType:r.dim+"Axis",axisId:r.index,sortInfo:a}))}},e.prototype._dispatchInitSort=function(t,i,r){var o=i.baseAxis,a=this._dataSort(t,o,function(s){return t.get(t.mapDimension(i.otherAxis.dim),s)});r.dispatchAction({type:"changeAxisOrder",componentType:o.dim+"Axis",isInitSort:!0,axisId:o.index,sortInfo:a})},e.prototype.remove=function(t,i){this._clear(this._model),this._removeOnRenderedListener(i)},e.prototype.dispose=function(t,i){this._removeOnRenderedListener(i)},e.prototype._removeOnRenderedListener=function(t){this._onRendered&&(t.getZr().off("rendered",this._onRendered),this._onRendered=null)},e.prototype._clear=function(t){var i=this.group,r=this._data;t&&t.isAnimationEnabled()&&r&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],r.eachItemGraphicEl(function(o){ul(o,t,ye(o).dataIndex)})):i.removeAll(),this._data=null,this._isFirstFrame=!0},e.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},e.type="bar",e}(st),Q_={cartesian2d:function(n,e){var t=e.width<0?-1:1,i=e.height<0?-1:1;t<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height);var r=n.x+n.width,o=n.y+n.height,a=Ad(e.x,n.x),s=Dd(e.x+e.width,r),l=Ad(e.y,n.y),u=Dd(e.y+e.height,o),h=sr?s:a,e.y=c&&l>o?u:l,e.width=h?0:s-a,e.height=c?0:u-l,t<0&&(e.x+=e.width,e.width=-e.width),i<0&&(e.y+=e.height,e.height=-e.height),h||c},polar:function(n,e){var t=e.r0<=e.r?1:-1;if(t<0){var i=e.r;e.r=e.r0,e.r0=i}var r=Dd(e.r,n.r),o=Ad(e.r0,n.r0);e.r=r,e.r0=o;var a=r-o<0;return t<0&&(i=e.r,e.r=e.r0,e.r0=i),a}},e1={cartesian2d:function(n,e,t,i,r,o,a,s,l){var u=new Re({shape:G({},i),z2:1});return u.__dataIndex=t,u.name="item",o&&(u.shape[r?"height":"width"]=0),u},polar:function(n,e,t,i,r,o,a,s,l){var u=!r&&l?Su:en,h=new u({shape:i,z2:1});h.name="item";var c,p,d=r1(r);if(h.calculateTextPosition=(c=d,p=u===Su,function(v,y,m){var x=y.position;if(!x||x instanceof Array)return Ns(v,y,m);var _=c(x),w=y.distance!=null?y.distance:5,b=this.shape,S=b.cx,M=b.cy,T=b.r,C=b.r0,I=(T+C)/2,D=b.startAngle,L=b.endAngle,R=(D+L)/2,O=p?Math.abs(T-C)/2:0,E=Math.cos,k=Math.sin,P=S+T*E(D),N=M+T*k(D),B="left",z="top";switch(_){case"startArc":P=S+(C-w)*E(R),N=M+(C-w)*k(R),B="center",z="top";break;case"insideStartArc":P=S+(C+w)*E(R),N=M+(C+w)*k(R),B="center",z="bottom";break;case"startAngle":P=S+I*E(D)+Mu(D,w+O,!1),N=M+I*k(D)+Tu(D,w+O,!1),B="right",z="middle";break;case"insideStartAngle":P=S+I*E(D)+Mu(D,-w+O,!1),N=M+I*k(D)+Tu(D,-w+O,!1),B="left",z="middle";break;case"middle":P=S+I*E(R),N=M+I*k(R),B="center",z="middle";break;case"endArc":P=S+(T+w)*E(R),N=M+(T+w)*k(R),B="center",z="bottom";break;case"insideEndArc":P=S+(T-w)*E(R),N=M+(T-w)*k(R),B="center",z="top";break;case"endAngle":P=S+I*E(L)+Mu(L,w+O,!0),N=M+I*k(L)+Tu(L,w+O,!0),B="left",z="middle";break;case"insideEndAngle":P=S+I*E(L)+Mu(L,-w+O,!0),N=M+I*k(L)+Tu(L,-w+O,!0),B="right",z="middle";break;default:return Ns(v,y,m)}return(v=v||{}).x=P,v.y=N,v.align=B,v.verticalAlign=z,v}),o){var f=r?"r":"endAngle",g={};h.shape[f]=r?i.r0:i.startAngle,g[f]=i[f],(s?Fe:et)(h,{shape:g},o)}return h}};function t1(n,e,t,i,r,o,a,s){var l,u;o?(u={x:i.x,width:i.width},l={y:i.y,height:i.height}):(u={y:i.y,height:i.height},l={x:i.x,width:i.width}),s||(a?Fe:et)(t,{shape:l},e,r,null),(a?Fe:et)(t,{shape:u},e?n.baseAxis.model:null,r)}function n1(n,e){for(var t=0;t0?1:-1,a=i.height>0?1:-1;return{x:i.x+o*r/2,y:i.y+a*r/2,width:i.width-o*r,height:i.height-a*r}},polar:function(n,e,t){var i=n.getItemLayout(e);return{cx:i.cx,cy:i.cy,r0:i.r0,r:i.r,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}}};function r1(n){return function(e){var t=e?"Arc":"Angle";return function(i){switch(i){case"start":case"insideStart":case"end":case"insideEnd":return i+t;default:return i}}}(n)}function o1(n,e,t,i,r,o,a,s){var l=e.getItemVisual(t,"style");if(s){if(!o.get("roundCap")){var u=n.shape;G(u,Ka(i.getModel("itemStyle"),u,!0)),n.setShape(u)}}else{var h=i.get(["itemStyle","borderRadius"])||0;n.setShape("r",h)}n.useStyle(l);var c=i.getShallow("cursor");c&&n.attr("cursor",c);var p=s?a?r.r>=r.r0?"endArc":"startArc":r.endAngle>=r.startAngle?"endAngle":"startAngle":a?r.height>=0?"bottom":"top":r.width>=0?"right":"left",d=ti(i);ei(n,d,{labelFetcher:o,labelDataIndex:t,defaultText:wu(o.getData(),t),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:p});var f=n.getTextContent();if(s&&f){var g=i.get(["label","position"]);n.textConfig.inside=g==="middle"||null,function(y,m,x,_){if(Le(_))y.setTextConfig({rotation:_});else if(W(m))y.setTextConfig({rotation:0});else{var w,b=y.shape,S=b.clockwise?b.startAngle:b.endAngle,M=b.clockwise?b.endAngle:b.startAngle,T=(S+M)/2,C=x(m);switch(C){case"startArc":case"insideStartArc":case"middle":case"insideEndArc":case"endArc":w=T;break;case"startAngle":case"insideStartAngle":w=S;break;case"endAngle":case"insideEndAngle":w=M;break;default:return void y.setTextConfig({rotation:0})}var I=1.5*Math.PI-w;C==="middle"&&I>Math.PI/2&&I<1.5*Math.PI&&(I-=Math.PI),y.setTextConfig({rotation:I})}}(n,g==="outside"?p:g,r1(a),i.get(["label","rotate"]))}Qy(f,d,o.getRawValue(t),function(y){return N_(e,y)});var v=i.getModel(["emphasis"]);En(n,v.get("focus"),v.get("blurScope"),v.get("disabled")),bi(n,i),function(y){return y.startAngle!=null&&y.endAngle!=null&&y.startAngle===y.endAngle}(r)&&(n.style.fill="none",n.style.stroke="none",A(n.states,function(y){y.style&&(y.style.fill=y.style.stroke="none")}))}var mA=function(){},a1=function(n){function e(t){var i=n.call(this,t)||this;return i.type="largeBar",i}return V(e,n),e.prototype.getDefaultShape=function(){return new mA},e.prototype.buildPath=function(t,i){for(var r=i.points,o=this.baseDimIdx,a=1-this.baseDimIdx,s=[],l=[],u=this.barWidth,h=0;h=u[0]&&i<=u[0]+h[0]&&r>=u[1]&&r<=u[1]+h[1])return l[p]}return-1}(this,n.offsetX,n.offsetY);ye(this).dataIndex=e>=0?e:null},30,!1);function u1(n,e,t){if(Cd(t,"cartesian2d")){var i=e,r=t.getArea();return{x:n?i.x:r.x,y:n?r.y:i.y,width:n?i.width:r.width,height:n?r.height:i.height}}var o=e;return{cx:(r=t.getArea()).cx,cy:r.cy,r0:n?r.r0:o.r0,r:n?r.r:o.r,startAngle:n?o.startAngle:0,endAngle:n?o.endAngle:2*Math.PI}}const xA=gA;var h1=2*Math.PI,Iu=Math.PI/180;function c1(n,e){return Vt(n.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function p1(n,e){var t=c1(n,e),i=n.get("center"),r=n.get("radius");W(r)||(r=[0,r]);var o,a,s=te(t.width,e.getWidth()),l=te(t.height,e.getHeight()),u=Math.min(s,l),h=te(r[0],u/2),c=te(r[1],u/2),p=n.coordinateSystem;if(p){var d=p.dataToPoint(i);o=d[0]||0,a=d[1]||0}else W(i)||(i=[i,i]),o=te(i[0],s)+t.x,a=te(i[1],l)+t.y;return{cx:o,cy:a,r0:h,r:c}}function _A(n,e,t){e.eachSeriesByType(n,function(i){var r=i.getData(),o=r.mapDimension("value"),a=c1(i,t),s=p1(i,t),l=s.cx,u=s.cy,h=s.r,c=s.r0,p=-i.get("startAngle")*Iu,d=i.get("endAngle"),f=i.get("padAngle")*Iu;d=d==="auto"?p-h1:-d*Iu;var g=i.get("minAngle")*Iu+f,v=0;r.each(o,function(O){!isNaN(O)&&v++});var y=r.getSum(o),m=Math.PI/(y||v)*2,x=i.get("clockwise"),_=i.get("roseType"),w=i.get("stillShowZeroSum"),b=r.getDataExtent(o);b[0]=0;var S=x?1:-1,M=[p,d],T=S*f/2;mc(M,!x),p=M[0],d=M[1];var C=Math.abs(d-p),I=C,D=0,L=p;if(r.setLayout({viewRect:a,r:h}),r.each(o,function(O,E){var k;if(isNaN(O))r.setItemLayout(E,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:x,cx:l,cy:u,r0:c,r:_?NaN:h});else{(k=_!=="area"?y===0&&w?m:O*m:C/v)k?B=N=L+S*k/2:(N=L+T,B=P-T),r.setItemLayout(E,{angle:k,startAngle:N,endAngle:B,clockwise:x,cx:l,cy:u,r0:c,r:_?Ye(O,b,[c,h]):h}),L=P}}),It?v:g,_=Math.abs(m.label.y-t);if(_>=x.maxY){var w=m.label.x-e-m.len2*r,b=i+m.len,S=Math.abs(w)n.unconstrainedWidth?null:d:null;i.setStyle("width",f)}var g=i.getBoundingRect();o.width=g.width;var v=(i.style.margin||0)+2.1;o.height=g.height+v,o.y-=(o.height-c)/2}}}function kd(n){return n.position==="center"}function bA(n){var e,t,i=n.getData(),r=[],o=!1,a=(n.get("minShowLabelAngle")||0)*wA,s=i.getLayout("viewRect"),l=i.getLayout("r"),u=s.width,h=s.x,c=s.y,p=s.height;function d(w){w.ignore=!0}i.each(function(w){var b=i.getItemGraphicEl(w),S=b.shape,M=b.getTextContent(),T=b.getTextGuideLine(),C=i.getItemModel(w),I=C.getModel("label"),D=I.get("position")||C.get(["emphasis","label","position"]),L=I.get("distanceToLabelLine"),R=I.get("alignTo"),O=te(I.get("edgeDistance"),u),E=I.get("bleedMargin"),k=C.getModel("labelLine"),P=k.get("length");P=te(P,u);var N=k.get("length2");if(N=te(N,u),Math.abs(S.endAngle-S.startAngle)0?"right":"left":Y>0?"left":"right"}var $=Math.PI,ne=0,Ce=I.get("rotate");if(Le(Ce))ne=Ce*($/180);else if(D==="center")ne=0;else if(Ce==="radial"||Ce===!0)ne=Y<0?-F+$:-F;else if(Ce==="tangential"&&D!=="outside"&&D!=="outer"){var ge=Math.atan2(Y,K);ge<0&&(ge=2*$+ge),K>0&&(ge=$+ge),ne=ge-$}if(o=!!ne,M.x=B,M.y=z,M.rotation=ne,M.setStyle({verticalAlign:"middle"}),oe){M.setStyle({align:Z});var xe=M.states.select;xe&&(xe.x+=M.x,xe.y+=M.y)}else{var we=M.getBoundingRect().clone();we.applyTransform(M.getComputedTransform());var Ie=(M.style.margin||0)+2.1;we.y-=Ie/2,we.height+=Ie,r.push({label:M,labelLine:T,position:D,len:P,len2:N,minTurnAngle:k.get("minTurnAngle"),maxSurfaceAngle:k.get("maxSurfaceAngle"),surfaceNormal:new fe(Y,K),linePoints:X,textAlign:Z,labelDistance:L,labelAlignTo:R,edgeDistance:O,bleedMargin:E,rect:we,unconstrainedWidth:we.width,labelStyleWidth:M.style.width})}b.setTextConfig({inside:oe})}}),!o&&n.get("avoidLabelOverlap")&&function(w,b,S,M,T,C,I,D){for(var L=[],R=[],O=Number.MAX_VALUE,E=-Number.MAX_VALUE,k=0;k0){for(var h=s.getItemLayout(0),c=1;isNaN(h&&h.startAngle)&&c=r.r0}},e.type="pie",e}(st);function Au(n,e,t){e=W(e)&&{coordDimensions:e}||G({encodeDefine:n.getEncode()},e);var i=n.getSource(),r=ud(i,e).dimensions,o=new ou(r,n);return o.initData(i,t),o}var TA=function(){function n(e,t){this._getDataWithEncodedVisual=e,this._getRawData=t}return n.prototype.getAllNames=function(){var e=this._getRawData();return e.mapArray(e.getName)},n.prototype.containName=function(e){return this._getRawData().indexOfName(e)>=0},n.prototype.indexOfName=function(e){return this._getDataWithEncodedVisual().indexOfName(e)},n.prototype.getItemVisual=function(e,t){return this._getDataWithEncodedVisual().getItemVisual(e,t)},n}();const v1=TA;var CA=ze();const IA=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.init=function(t){n.prototype.init.apply(this,arguments),this.legendVisualProvider=new v1(he(this.getData,this),he(this.getRawData,this)),this._defaultLabelLine(t)},e.prototype.mergeOption=function(){n.prototype.mergeOption.apply(this,arguments)},e.prototype.getInitialData=function(){return Au(this,{coordDimensions:["value"],encodeDefaulter:Te(Sm,this)})},e.prototype.getDataParams=function(t){var i=this.getData(),r=CA(i),o=r.seats;if(!o){var a=[];i.each(i.mapDimension("value"),function(l){a.push(l)}),o=r.seats=ov(a,i.hostModel.get("percentPrecision"))}var s=n.prototype.getDataParams.call(this,t);return s.percent=o[t]||0,s.$vars.push("percent"),s},e.prototype._defaultLabelLine=function(t){Gs(t,"labelLine",["show"]);var i=t.labelLine,r=t.emphasis.labelLine;i.show=i.show&&t.label.show,r.show=r.show&&t.emphasis.label.show},e.type="series.pie",e.defaultOption={z:2,legendHoverLink:!0,colorBy:"data",center:["50%","50%"],radius:[0,"75%"],clockwise:!0,startAngle:90,endAngle:"auto",padAngle:0,minAngle:0,minShowLabelAngle:0,selectedOffset:10,percentPrecision:2,stillShowZeroSum:!0,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%",bleedMargin:10,distanceToLabelLine:5},labelLine:{show:!0,length:15,length2:15,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},avoidLabelOverlap:!0,animationType:"expansion",animationDuration:1e3,animationTypeUpdate:"transition",animationEasingUpdate:"cubicInOut",animationDurationUpdate:500,animationEasing:"cubicInOut"},e}(kt),AA=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.type="grid",e.dependencies=["xAxis","yAxis"],e.layoutMode="box",e.defaultOption={show:!1,z:0,left:"10%",top:60,right:"10%",bottom:70,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"},e}(Se);var Ld=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",nt).models[0]},e.type="cartesian2dAxis",e}(Se);ht(Ld,ja);var y1={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},DA=pe({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},y1),Pd=pe({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:"#F4F7FD",width:1}}},y1);const m1={category:DA,value:Pd,time:pe({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},Pd),log:ae({logBase:10},Pd)};var kA={value:1,category:1,time:1,log:1};function Ja(n,e,t,i){A(kA,function(r,o){var a=pe(pe({},m1[o],!0),i,!0),s=function(l){function u(){var h=l!==null&&l.apply(this,arguments)||this;return h.type=e+"Axis."+o,h}return V(u,l),u.prototype.mergeDefaultAndTheme=function(h,c){var p=Aa(this),d=p?Cl(h):{};pe(h,c.getTheme().get(o+"Axis")),pe(h,this.getDefaultOption()),h.type=x1(h),p&&lo(h,d,p)},u.prototype.optionUpdated=function(){this.option.type==="category"&&(this.__ordinalMeta=hd.createByAxisModel(this))},u.prototype.getCategories=function(h){var c=this.option;if(c.type==="category")return h?c.data:this.__ordinalMeta.categories},u.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},u.type=e+"Axis."+o,u.defaultOption=a,u}(t);n.registerComponentModel(s)}),n.registerSubTypeDefaulter(e+"Axis",x1)}function x1(n){return n.type||(n.data?"category":"value")}var LA=function(){function n(e){this.type="cartesian",this._dimList=[],this._axes={},this.name=e||""}return n.prototype.getAxis=function(e){return this._axes[e]},n.prototype.getAxes=function(){return U(this._dimList,function(e){return this._axes[e]},this)},n.prototype.getAxesByScale=function(e){return e=e.toLowerCase(),Ge(this.getAxes(),function(t){return t.scale.type===e})},n.prototype.addAxis=function(e){var t=e.dim;this._axes[t]=e,this._dimList.push(t)},n}(),Od=["x","y"];function _1(n){return n.type==="interval"||n.type==="time"}var PA=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type="cartesian2d",t.dimensions=Od,t}return V(e,n),e.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var t=this.getAxis("x").scale,i=this.getAxis("y").scale;if(_1(t)&&_1(i)){var r=t.getExtent(),o=i.getExtent(),a=this.dataToPoint([r[0],o[0]]),s=this.dataToPoint([r[1],o[1]]),l=r[1]-r[0],u=o[1]-o[0];if(l&&u){var h=(s[0]-a[0])/l,c=(s[1]-a[1])/u,p=a[0]-r[0]*h,d=a[1]-o[0]*c,f=this._transform=[h,0,0,c,p,d];this._invTransform=Wi([],f)}}},e.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},e.prototype.containPoint=function(t){var i=this.getAxis("x"),r=this.getAxis("y");return i.contain(i.toLocalCoord(t[0]))&&r.contain(r.toLocalCoord(t[1]))},e.prototype.containData=function(t){return this.getAxis("x").containData(t[0])&&this.getAxis("y").containData(t[1])},e.prototype.containZone=function(t,i){var r=this.dataToPoint(t),o=this.dataToPoint(i),a=this.getArea(),s=new ve(r[0],r[1],o[0]-r[0],o[1]-r[1]);return a.intersect(s)},e.prototype.dataToPoint=function(t,i,r){r=r||[];var o=t[0],a=t[1];if(this._transform&&o!=null&&isFinite(o)&&a!=null&&isFinite(a))return it(r,t,this._transform);var s=this.getAxis("x"),l=this.getAxis("y");return r[0]=s.toGlobalCoord(s.dataToCoord(o,i)),r[1]=l.toGlobalCoord(l.dataToCoord(a,i)),r},e.prototype.clampData=function(t,i){var r=this.getAxis("x").scale,o=this.getAxis("y").scale,a=r.getExtent(),s=o.getExtent(),l=r.parse(t[0]),u=o.parse(t[1]);return(i=i||[])[0]=Math.min(Math.max(Math.min(a[0],a[1]),l),Math.max(a[0],a[1])),i[1]=Math.min(Math.max(Math.min(s[0],s[1]),u),Math.max(s[0],s[1])),i},e.prototype.pointToData=function(t,i){var r=[];if(this._invTransform)return it(r,t,this._invTransform);var o=this.getAxis("x"),a=this.getAxis("y");return r[0]=o.coordToData(o.toLocalCoord(t[0]),i),r[1]=a.coordToData(a.toLocalCoord(t[1]),i),r},e.prototype.getOtherAxis=function(t){return this.getAxis(t.dim==="x"?"y":"x")},e.prototype.getArea=function(t){t=t||0;var i=this.getAxis("x").getGlobalExtent(),r=this.getAxis("y").getGlobalExtent(),o=Math.min(i[0],i[1])-t,a=Math.min(r[0],r[1])-t,s=Math.max(i[0],i[1])-o+t,l=Math.max(r[0],r[1])-a+t;return new ve(o,a,s,l)},e}(LA),OA=function(n){function e(t,i,r,o,a){var s=n.call(this,t,i,r)||this;return s.index=0,s.type=o||"value",s.position=a||"bottom",s}return V(e,n),e.prototype.isHorizontal=function(){var t=this.position;return t==="top"||t==="bottom"},e.prototype.getGlobalExtent=function(t){var i=this.getExtent();return i[0]=this.toGlobalCoord(i[0]),i[1]=this.toGlobalCoord(i[1]),t&&i[0]>i[1]&&i.reverse(),i},e.prototype.pointToData=function(t,i){return this.coordToData(this.toLocalCoord(t[this.dim==="x"?0:1]),i)},e.prototype.setCategorySortInfo=function(t){if(this.type!=="category")return!1;this.model.option.categorySortInfo=t,this.scale.setSortInfo(t)},e}(Fn);const RA=OA;function Rd(n,e,t){t=t||{};var i=n.coordinateSystem,r=e.axis,o={},a=r.getAxesOnZeroOf()[0],s=r.position,l=a?"onZero":s,u=r.dim,h=i.getRect(),c=[h.x,h.x+h.width,h.y,h.y+h.height],p={left:0,right:1,top:0,bottom:1,onZero:2},d=e.get("offset")||0,f=u==="x"?[c[2]-d,c[3]+d]:[c[0]-d,c[1]+d];if(a){var g=a.toGlobalCoord(a.dataToCoord(0));f[p.onZero]=Math.max(Math.min(g,f[1]),f[0])}o.position=[u==="y"?f[p[l]]:c[0],u==="x"?f[p[l]]:c[3]],o.rotation=Math.PI/2*(u==="x"?0:1),o.labelDirection=o.tickDirection=o.nameDirection={top:-1,bottom:1,left:-1,right:1}[s],o.labelOffset=a?f[p[s]]-f[p.onZero]:0,e.get(["axisTick","inside"])&&(o.tickDirection=-o.tickDirection),Ht(t.labelInside,e.get(["axisLabel","inside"]))&&(o.labelDirection=-o.labelDirection);var v=e.get(["axisLabel","rotate"]);return o.labelRotate=l==="top"?-v:v,o.z2=1,o}function w1(n){return n.get("coordinateSystem")==="cartesian2d"}function b1(n){var e={xAxisModel:null,yAxisModel:null};return A(e,function(t,i){var r=i.replace(/Model$/,""),o=n.getReferringComponents(r,nt).models[0];if(!o)throw new Error(r+' "'+di(n.get(r+"Index"),n.get(r+"Id"),0)+'" not found');e[i]=o}),e}var Ed=Math.log;function S1(n,e,t){var i=br.prototype,r=i.getTicks.call(t),o=i.getTicks.call(t,!0),a=r.length-1,s=i.getInterval.call(t),l=r_(n,e),u=l.extent,h=l.fixMin,c=l.fixMax;if(n.type==="log"){var p=Ed(n.base);u=[Ed(u[0])/p,Ed(u[1])/p]}n.setExtent(u[0],u[1]),n.calcNiceExtent({splitNumber:a,fixMin:h,fixMax:c});var d=i.getExtent.call(n);h&&(u[0]=d[0]),c&&(u[1]=d[1]);var f=i.getInterval.call(n),g=u[0],v=u[1];if(h&&c)f=(v-g)/a;else if(h)for(v=u[0]+f*a;vu[0]&&isFinite(g)&&isFinite(u[0]);)f=pd(f),g=u[1]-f*a;else{n.getTicks().length-1>a&&(f=pd(f));var y=f*a;(g=Ue((v=Math.ceil(u[1]/f)*f)-y))<0&&u[0]>=0?(g=0,v=Ue(y)):v>0&&u[1]<=0&&(v=0,g=-Ue(y))}var m=(r[0].value-o[0].value)/s,x=(r[a].value-o[a].value)/s;i.setExtent.call(n,g+f*m,v+f*x),i.setInterval.call(n,f),(m||x)&&i.setNiceExtent.call(n,g+f,v-f);var _,w,b,S=i.getTicks.call(n);S[1]&&(_=f,w=Math.pow(10,ta(Math.abs(_))),(b=Math.abs(_/w))!==0&&b!==1&&b!==2&&b!==3&&b!==5||zs(S[1].value)>zs(f))&&Je("The ticks may be not readable when set min: "+e.get("min")+", max: "+e.get("max")+" and alignTicks: true")}var EA=function(){function n(e,t,i){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=Od,this._initCartesian(e,t,i),this.model=e}return n.prototype.getRect=function(){return this._rect},n.prototype.update=function(e,t){var i=this._axesMap;function r(a){var s,l=Oe(a),u=l.length;if(u){for(var h=[],c=u-1;c>=0;c--){var p=a[+l[c]],d=p.model,f=p.scale;cd(f)&&d.get("alignTicks")&&d.get("interval")==null?h.push(p):(wo(f,d),cd(f)&&(s=p))}h.length&&(s||wo((s=h.pop()).scale,s.model),A(h,function(g){S1(g.scale,g.model,s.scale)}))}}this._updateScale(e,this.model),r(i.x),r(i.y);var o={};A(i.x,function(a){M1(i,"y",a,o)}),A(i.y,function(a){M1(i,"x",a,o)}),this.resize(this.model,t)},n.prototype.resize=function(e,t,i){var r=e.getBoxLayoutParams(),o=!i&&e.get("containLabel"),a=Vt(r,{width:t.getWidth(),height:t.getHeight()});this._rect=a;var s=this._axesList;function l(){A(s,function(u){var h=u.isHorizontal(),c=h?[0,a.width]:[0,a.height],p=u.inverse?1:0;u.setExtent(c[p],c[1-p]),function(d,f){var g=d.getExtent(),v=g[0]+g[1];d.toGlobalCoord=d.dim==="x"?function(y){return y+f}:function(y){return v-y+f},d.toLocalCoord=d.dim==="x"?function(y){return y-f}:function(y){return v-y+f}}(u,h?a.x:a.y)})}l(),o&&(A(s,function(u){if(!u.model.get(["axisLabel","inside"])){var h=function(d){var f=d.model,g=d.scale;if(f.get(["axisLabel","show"])&&!g.isBlank()){var v,y,m=g.getExtent();y=g instanceof Yx?g.count():(v=g.getTicks()).length;var x,_=d.getLabelModel(),w=Xa(d),b=1;y>40&&(b=Math.ceil(y/40));for(var S=0;S0&&r>0||i<0&&r<0)}(n)}const NA=EA;var Pi=Math.PI,Tr=function(){function n(e,t){this.group=new me,this.opt=t,this.axisModel=e,ae(t,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});var i=new me({x:t.position[0],y:t.position[1],rotation:t.rotation});i.updateTransform(),this._transformGroup=i}return n.prototype.hasBuilder=function(e){return!!C1[e]},n.prototype.add=function(e){C1[e](this.opt,this.axisModel,this.group,this._transformGroup)},n.prototype.getGroup=function(){return this.group},n.innerTextLayout=function(e,t,i){var r,o,a=Qh(t-e);return ea(a)?(o=i>0?"top":"bottom",r="center"):ea(a-Pi)?(o=i>0?"bottom":"top",r="center"):(o="middle",r=a>0&&a0?"right":"left":i>0?"left":"right"),{rotation:a,textAlign:r,textVerticalAlign:o}},n.makeAxisEventDataBase=function(e){var t={componentType:e.mainType,componentIndex:e.componentIndex};return t[e.mainType+"Index"]=e.componentIndex,t},n.isLabelSilent=function(e){var t=e.get("tooltip");return e.get("silent")||!(e.get("triggerEvent")||t&&t.show)},n}(),C1={axisLine:function(n,e,t,i){var r=e.get(["axisLine","show"]);if(r==="auto"&&n.handleAutoShown&&(r=n.handleAutoShown("axisLine")),r){var o=e.axis.getExtent(),a=i.transform,s=[o[0],0],l=[o[1],0],u=s[0]>l[0];a&&(it(s,s,a),it(l,l,a));var h=G({lineCap:"round"},e.getModel(["axisLine","lineStyle"]).getLineStyle()),c=new _t({shape:{x1:s[0],y1:s[1],x2:l[0],y2:l[1]},style:h,strokeContainThreshold:n.strokeContainThreshold||5,silent:!0,z2:1});xa(c.shape,c.style.lineWidth),c.anid="line",t.add(c);var p=e.get(["axisLine","symbol"]);if(p!=null){var d=e.get(["axisLine","symbolSize"]);j(p)&&(p=[p,p]),(j(d)||Le(d))&&(d=[d,d]);var f=Ep(e.get(["axisLine","symbolOffset"])||0,d),g=d[0],v=d[1];A([{rotate:n.rotation+Math.PI/2,offset:f[0],r:0},{rotate:n.rotation-Math.PI/2,offset:f[1],r:Math.sqrt((s[0]-l[0])*(s[0]-l[0])+(s[1]-l[1])*(s[1]-l[1]))}],function(y,m){if(p[m]!=="none"&&p[m]!=null){var x=St(p[m],-g/2,-v/2,g,v,h.stroke,!0),_=y.r+y.offset,w=u?l:s;x.attr({rotation:y.rotate,x:w[0]+_*Math.cos(n.rotation),y:w[1]-_*Math.sin(n.rotation),silent:!0,z2:11}),t.add(x)}})}}},axisTickLabel:function(n,e,t,i){var r=function(a,s,l,u){var h=l.axis,c=l.getModel("axisTick"),p=c.get("show");if(p==="auto"&&u.handleAutoShown&&(p=u.handleAutoShown("axisTick")),!(!p||h.scale.isBlank())){for(var d=c.getModel("lineStyle"),f=u.tickDirection*c.get("length"),g=D1(h.getTicksCoords(),s.transform,f,ae(d.getLineStyle(),{stroke:l.get(["axisLine","lineStyle","color"])}),"ticks"),v=0;vc[1]?-1:1,d=[s==="start"?c[0]-p*h:s==="end"?c[1]+p*h:(c[0]+c[1])/2,A1(s)?n.labelOffset+l*h:0],f=e.get("nameRotate");f!=null&&(f=f*Pi/180),A1(s)?o=Tr.innerTextLayout(n.rotation,f??n.rotation,l):(o=function(w,b,S,M){var T,C,I=Qh(S-w),D=M[0]>M[1],L=b==="start"&&!D||b!=="start"&&D;return ea(I-Pi/2)?(C=L?"bottom":"top",T="center"):ea(I-1.5*Pi)?(C=L?"top":"bottom",T="center"):(C="middle",T=I<1.5*Pi&&I>Pi/2?L?"left":"right":L?"right":"left"),{rotation:I,textAlign:T,textVerticalAlign:C}}(n.rotation,s,f||0,c),(a=n.axisNameAvailableWidth)!=null&&(a=Math.abs(a/Math.sin(o.rotation)),!isFinite(a)&&(a=null)));var g=u.getFont(),v=e.get("nameTruncate",!0)||{},y=v.ellipsis,m=Ht(n.nameTruncateMaxWidth,v.maxWidth,a),x=new De({x:d[0],y:d[1],rotation:o.rotation,silent:Tr.isLabelSilent(e),style:rt(u,{text:r,font:g,overflow:"truncate",width:m,ellipsis:y,fill:u.getTextColor()||e.get(["axisLine","lineStyle","color"]),align:u.get("align")||o.textAlign,verticalAlign:u.get("verticalAlign")||o.textVerticalAlign}),z2:1});if(wa({el:x,componentModel:e,itemName:r}),x.__fullText=r,x.anid="name",e.get("triggerEvent")){var _=Tr.makeAxisEventDataBase(e);_.targetType="axisName",_.name=r,ye(x).eventData=_}i.add(x),x.updateTransform(),t.add(x),x.decomposeTransform()}}};function un(n){n&&(n.ignore=!0)}function I1(n,e){var t=n&&n.getBoundingRect().clone(),i=e&&e.getBoundingRect().clone();if(t&&i){var r=Vo([]);return Hi(r,r,-n.rotation),t.applyTransform(In([],r,n.getLocalTransform())),i.applyTransform(In([],r,e.getLocalTransform())),t.intersect(i)}}function A1(n){return n==="middle"||n==="center"}function D1(n,e,t,i,r){for(var o=[],a=[],s=[],l=0;l=0||n===e}function Bd(n){var e=(n.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return e&&e.axesInfo[$a(n)]}function Vd(n){return!!n.get(["handle","show"])}function $a(n){return n.type+"||"+n.id}var Fd={},BA=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.render=function(t,i,r,o){this.axisPointerClass&&function(a){var s=Bd(a);if(s){var l=s.axisPointerModel,u=s.axis.scale,h=l.option,c=l.get("status"),p=l.get("value");p!=null&&(p=u.parse(p));var d=Vd(l);c==null&&(h.status=d?"show":"hide");var f=u.getExtent().slice();f[0]>f[1]&&f.reverse(),(p==null||p>f[1])&&(p=f[1]),p0&&!f.min?f.min=0:f.min!=null&&f.min<0&&!f.max&&(f.max=0);var g=l;f.color!=null&&(g=ae({color:f.color},l));var v=pe(ie(f),{boundaryGap:t,splitNumber:i,scale:r,axisLine:o,axisTick:a,axisLabel:s,name:f.text,showName:u,nameLocation:"end",nameGap:c,nameTextStyle:g,triggerEvent:p},!1);if(j(h)){var y=v.name;v.name=h.replace("{value}",y??"")}else re(h)&&(v.name=h(v.name,v));var m=new He(v,null,this.ecModel);return ht(m,ja.prototype),m.mainType="radar",m.componentIndex=this.componentIndex,m},this);this._indicatorModels=d},e.prototype.getIndicatorModels=function(){return this._indicatorModels},e.type="radar",e.defaultOption={z:0,center:["50%","50%"],radius:"75%",startAngle:90,axisName:{show:!0},boundaryGap:[0,0],splitNumber:5,axisNameGap:15,scale:!1,shape:"polygon",axisLine:pe({lineStyle:{color:"#bbb"}},es.axisLine),axisLabel:Du(es.axisLabel,!1),axisTick:Du(es.axisTick,!1),splitLine:Du(es.splitLine,!0),splitArea:Du(es.splitArea,!0),indicator:[]},e}(Se);const $A=JA;var QA=["axisLine","axisTickLabel","axisName"],eD=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.render=function(t,i,r){this.group.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},e.prototype._buildAxes=function(t){var i=t.coordinateSystem;A(U(i.getIndicatorAxes(),function(r){var o=r.model.get("showName")?r.name:"";return new Oi(r.model,{axisName:o,position:[i.cx,i.cy],rotation:r.angle,labelDirection:-1,tickDirection:-1,nameDirection:1})}),function(r){A(QA,r.add,r),this.group.add(r.getGroup())},this)},e.prototype._buildSplitLineAndArea=function(t){var i=t.coordinateSystem,r=i.getIndicatorAxes();if(r.length){var o=t.get("shape"),a=t.getModel("splitLine"),s=t.getModel("splitArea"),l=a.getModel("lineStyle"),u=s.getModel("areaStyle"),h=a.get("show"),c=s.get("show"),p=l.get("color"),d=u.get("color"),f=W(p)?p:[p],g=W(d)?d:[d],v=[],y=[];if(o==="circle")for(var m=r[0].getTicksCoords(),x=i.cx,_=i.cy,w=0;w3?1.4:a>1?1.2:1.1;Wd(this,"zoom","zoomOnMouseWheel",t,{scale:o>0?u:1/u,originX:s,originY:l,isAvailableBehavior:null})}if(r){var h=Math.abs(o);Wd(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:(o>0?1:-1)*(h>3?.4:h>1?.15:.05),originX:s,originY:l,isAvailableBehavior:null})}}},e.prototype._pinchHandler=function(t){N1(this._zr,"globalPan")||Wd(this,"zoom",null,t,{scale:t.pinchScale>1?1.1:1/1.1,originX:t.pinchX,originY:t.pinchY,isAvailableBehavior:null})},e}(Ut);function Wd(n,e,t,i,r){n.pointerChecker&&n.pointerChecker(i,r.originX,r.originY)&&(Fi(i.event),z1(n,e,t,i,r))}function z1(n,e,t,i,r){r.isAvailableBehavior=he(ku,null,t,i),n.trigger(e,r)}function ku(n,e,t){var i=t[n];return!n||i&&(!j(i)||e.event[i+"Key"])}const lD=sD;var Yd,uD={axisPointer:1,tooltip:1,brush:1};function B1(n,e,t){var i=e.getComponentByElement(n.topTarget),r=i&&i.coordinateSystem;return i&&i!==t&&!uD.hasOwnProperty(i.mainType)&&r&&r.model!==t}function V1(n){j(n)&&(n=new DOMParser().parseFromString(n,"text/xml"));var e=n;for(e.nodeType===9&&(e=e.firstChild);e.nodeName.toLowerCase()!=="svg"||e.nodeType!==1;)e=e.nextSibling;return e}var Lu={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-anchor":"textAlign",visibility:"visibility",display:"display"},F1=Oe(Lu),Pu={"alignment-baseline":"textBaseline","stop-color":"stopColor"},G1=Oe(Pu),hD=function(){function n(){this._defs={},this._root=null}return n.prototype.parse=function(e,t){t=t||{};var i=V1(e);if(!i)throw new Error("Illegal svg");this._defsUsePending=[];var r=new me;this._root=r;var o=[],a=i.getAttribute("viewBox")||"",s=parseFloat(i.getAttribute("width")||t.width),l=parseFloat(i.getAttribute("height")||t.height);isNaN(s)&&(s=null),isNaN(l)&&(l=null),Gt(i,r,null,!0,!1);for(var u,h,c=i.firstChild;c;)this._parseNode(c,r,o,null,!1,!1),c=c.nextSibling;if(function(f,g){for(var v=0;v=4&&(u={x:parseFloat(p[0]||0),y:parseFloat(p[1]||0),width:parseFloat(p[2]),height:parseFloat(p[3])})}if(u&&s!=null&&l!=null&&(h=q1(u,{x:0,y:0,width:s,height:l}),!t.ignoreViewBox)){var d=r;(r=new me).add(d),d.scaleX=d.scaleY=h.scale,d.x=h.x,d.y=h.y}return t.ignoreRootClip||s==null||l==null||r.setClipPath(new Re({shape:{x:0,y:0,width:s,height:l}})),{root:r,width:s,height:l,viewBoxRect:u,viewBoxTransform:h,named:o}},n.prototype._parseNode=function(e,t,i,r,o,a){var s,l=e.nodeName.toLowerCase(),u=r;if(l==="defs"&&(o=!0),l==="text"&&(a=!0),l==="defs"||l==="switch")s=t;else{if(!o){var h=Yd[l];if(h&&Yt(Yd,l)){s=h.call(this,e,t);var c=e.getAttribute("name");if(c){var p={name:c,namedFrom:null,svgNodeTagLower:l,el:s};i.push(p),l==="g"&&(u=p)}else r&&i.push({name:r.name,namedFrom:r,svgNodeTagLower:l,el:s});t.add(s)}}var d=H1[l];if(d&&Yt(H1,l)){var f=d.call(this,e),g=e.getAttribute("id");g&&(this._defs[g]=f)}}if(s&&s.isGroup)for(var v=e.firstChild;v;)v.nodeType===1?this._parseNode(v,s,i,u,o,a):v.nodeType===3&&a&&this._parseText(v,s),v=v.nextSibling},n.prototype._parseText=function(e,t){var i=new Zs({style:{text:e.textContent},silent:!0,x:this._textX||0,y:this._textY||0});hn(t,i),Gt(e,i,this._defsUsePending,!1,!1),function(l,u){var h=u.__selfStyle;if(h){var c=h.textBaseline,p=c;c&&c!=="auto"?c==="baseline"?p="alphabetic":c==="before-edge"||c==="text-before-edge"?p="top":c==="after-edge"||c==="text-after-edge"?p="bottom":c!=="central"&&c!=="mathematical"||(p="middle"):p="alphabetic",l.style.textBaseline=p}var d=u.__inheritedStyle;if(d){var f=d.textAlign,g=f;f&&(f==="middle"&&(g="center"),l.style.textAlign=g)}}(i,t);var r=i.style,o=r.fontSize;o&&o<9&&(r.fontSize=9,i.scaleX*=o/9,i.scaleY*=o/9);var a=(r.fontSize||r.fontFamily)&&[r.fontStyle,r.fontWeight,(r.fontSize||12)+"px",r.fontFamily||"sans-serif"].join(" ");r.font=a;var s=i.getBoundingRect();return this._textX+=s.width,t.add(i),i},n.internalField=void(Yd={g:function(e,t){var i=new me;return hn(t,i),Gt(e,i,this._defsUsePending,!1,!1),i},rect:function(e,t){var i=new Re;return hn(t,i),Gt(e,i,this._defsUsePending,!1,!1),i.setShape({x:parseFloat(e.getAttribute("x")||"0"),y:parseFloat(e.getAttribute("y")||"0"),width:parseFloat(e.getAttribute("width")||"0"),height:parseFloat(e.getAttribute("height")||"0")}),i.silent=!0,i},circle:function(e,t){var i=new $n;return hn(t,i),Gt(e,i,this._defsUsePending,!1,!1),i.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),r:parseFloat(e.getAttribute("r")||"0")}),i.silent=!0,i},line:function(e,t){var i=new _t;return hn(t,i),Gt(e,i,this._defsUsePending,!1,!1),i.setShape({x1:parseFloat(e.getAttribute("x1")||"0"),y1:parseFloat(e.getAttribute("y1")||"0"),x2:parseFloat(e.getAttribute("x2")||"0"),y2:parseFloat(e.getAttribute("y2")||"0")}),i.silent=!0,i},ellipse:function(e,t){var i=new il;return hn(t,i),Gt(e,i,this._defsUsePending,!1,!1),i.setShape({cx:parseFloat(e.getAttribute("cx")||"0"),cy:parseFloat(e.getAttribute("cy")||"0"),rx:parseFloat(e.getAttribute("rx")||"0"),ry:parseFloat(e.getAttribute("ry")||"0")}),i.silent=!0,i},polygon:function(e,t){var i,r=e.getAttribute("points");r&&(i=U1(r));var o=new Qn({shape:{points:i||[]},silent:!0});return hn(t,o),Gt(e,o,this._defsUsePending,!1,!1),o},polyline:function(e,t){var i,r=e.getAttribute("points");r&&(i=U1(r));var o=new zn({shape:{points:i||[]},silent:!0});return hn(t,o),Gt(e,o,this._defsUsePending,!1,!1),o},image:function(e,t){var i=new Bt;return hn(t,i),Gt(e,i,this._defsUsePending,!1,!1),i.setStyle({image:e.getAttribute("xlink:href")||e.getAttribute("href"),x:+e.getAttribute("x"),y:+e.getAttribute("y"),width:+e.getAttribute("width"),height:+e.getAttribute("height")}),i.silent=!0,i},text:function(e,t){var i=e.getAttribute("x")||"0",r=e.getAttribute("y")||"0",o=e.getAttribute("dx")||"0",a=e.getAttribute("dy")||"0";this._textX=parseFloat(i)+parseFloat(o),this._textY=parseFloat(r)+parseFloat(a);var s=new me;return hn(t,s),Gt(e,s,this._defsUsePending,!1,!0),s},tspan:function(e,t){var i=e.getAttribute("x"),r=e.getAttribute("y");i!=null&&(this._textX=parseFloat(i)),r!=null&&(this._textY=parseFloat(r));var o=e.getAttribute("dx")||"0",a=e.getAttribute("dy")||"0",s=new me;return hn(t,s),Gt(e,s,this._defsUsePending,!1,!0),this._textX+=parseFloat(o),this._textY+=parseFloat(a),s},path:function(e,t){var i=wy(e.getAttribute("d")||"");return hn(t,i),Gt(e,i,this._defsUsePending,!1,!1),i.silent=!0,i}}),n}(),H1={lineargradient:function(n){var e=parseInt(n.getAttribute("x1")||"0",10),t=parseInt(n.getAttribute("y1")||"0",10),i=parseInt(n.getAttribute("x2")||"10",10),r=parseInt(n.getAttribute("y2")||"0",10),o=new va(e,t,i,r);return W1(n,o),Y1(n,o),o},radialgradient:function(n){var e=parseInt(n.getAttribute("cx")||"0",10),t=parseInt(n.getAttribute("cy")||"0",10),i=parseInt(n.getAttribute("r")||"0",10),r=new Bc(e,t,i);return W1(n,r),Y1(n,r),r}};function W1(n,e){n.getAttribute("gradientUnits")==="userSpaceOnUse"&&(e.global=!0)}function Y1(n,e){for(var t=n.firstChild;t;){if(t.nodeType===1&&t.nodeName.toLocaleLowerCase()==="stop"){var i=t.getAttribute("offset"),r=void 0;r=i&&i.indexOf("%")>0?parseInt(i,10)/100:i?parseFloat(i):0;var o={};Z1(t,o,o);var a=o.stopColor||t.getAttribute("stop-color")||"#000000";e.colorStops.push({offset:r,color:a})}t=t.nextSibling}}function hn(n,e){n&&n.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),ae(e.__inheritedStyle,n.__inheritedStyle))}function U1(n){for(var e=Ou(n),t=[],i=0;i0;d-=2){var f=c[d],g=c[d-1],v=Ou(f);switch(p=p||[1,0,0,1,0,0],g){case"translate":Gi(p,p,[parseFloat(v[0]),parseFloat(v[1]||"0")]);break;case"scale":mh(p,p,[parseFloat(v[0]),parseFloat(v[1]||v[0])]);break;case"rotate":Hi(p,p,-parseFloat(v[0])*Ud,[parseFloat(v[1]||"0"),parseFloat(v[2]||"0")]);break;case"skewX":In(p,[1,0,Math.tan(parseFloat(v[0])*Ud),1,0,0],p);break;case"skewY":In(p,[1,Math.tan(parseFloat(v[0])*Ud),0,1,0,0],p);break;case"matrix":p[0]=parseFloat(v[0]),p[1]=parseFloat(v[1]),p[2]=parseFloat(v[2]),p[3]=parseFloat(v[3]),p[4]=parseFloat(v[4]),p[5]=parseFloat(v[5])}}u.setLocalTransform(p)}}(n,e),Z1(n,a,s),i||function(l,u,h){for(var c=0;c0,g={api:i,geo:l,mapOrGeoModel:e,data:s,isVisualEncodedByVisualMap:f,isGeo:a,transformInfoRaw:p};l.resourceType==="geoJSON"?this._buildGeoJSON(g):l.resourceType==="geoSVG"&&this._buildSVG(g),this._updateController(e,t,i),this._updateMapSelectHandler(e,u,i,r)},n.prototype._buildGeoJSON=function(e){var t=this._regionsGroupByName=ee(),i=ee(),r=this._regionsGroup,o=e.transformInfoRaw,a=e.mapOrGeoModel,s=e.data,l=e.geo.projection,u=l&&l.stream;function h(d,f){return f&&(d=f(d)),d&&[d[0]*o.scaleX+o.x,d[1]*o.scaleY+o.y]}function c(d){for(var f=[],g=!u&&l&&l.project,v=0;v=0)&&(p=r);var d=a?{normal:{align:"center",verticalAlign:"middle"}}:null;ei(e,ti(i),{labelFetcher:p,labelDataIndex:c,defaultText:t},d);var f=e.getTextContent();if(f&&(J1(f).ignore=f.ignore,e.textConfig&&a)){var g=e.getBoundingRect().clone();e.textConfig.layoutRect=g,e.textConfig.position=[(a[0]-g.x)/g.width*100+"%",(a[1]-g.y)/g.height*100+"%"]}e.disableLabelAnimation=!0}else e.removeTextContent(),e.removeTextConfig(),e.disableLabelAnimation=null}function tw(n,e,t,i,r,o){n.data?n.data.setItemGraphicEl(o,e):ye(e).eventData={componentType:"geo",componentIndex:r.componentIndex,geoIndex:r.componentIndex,name:t,region:i&&i.option||{}}}function nw(n,e,t,i,r){n.data||wa({el:e,componentModel:r,itemName:t,itemTooltipOption:i.get("tooltip")})}function iw(n,e,t,i,r){e.highDownSilentOnTouch=!!r.get("selectedMode");var o=i.getModel("emphasis"),a=o.get("focus");return En(e,a,o.get("blurScope"),o.get("disabled")),n.isGeo&&function(s,l,u){var h=ye(s);h.componentMainType=l.mainType,h.componentIndex=l.componentIndex,h.componentHighDownName=u}(e,r,t),a}function rw(n,e,t){var i,r=[];function o(){i=[]}function a(){i.length&&(r.push(i),i=[])}var s=e({polygonStart:o,polygonEnd:a,lineStart:o,lineEnd:a,point:function(l,u){isFinite(l)&&isFinite(u)&&i.push([l,u])},sphere:function(){}});return!t&&s.polygonStart(),A(n,function(l){s.lineStart();for(var u=0;u-1&&(r.style.stroke=r.style.fill,r.style.fill="#fff",r.style.lineWidth=2),r},e.type="series.map",e.dependencies=["geo"],e.layoutMode="box",e.defaultOption={z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:null,showLegendSymbol:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,selectedMode:!0,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}},select:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{color:"rgba(255,215,0,0.8)"}},nameProperty:"name"},e}(kt);const ID=CD;function AD(n){var e={};n.eachSeriesByType("map",function(t){var i=t.getHostGeoModel(),r=i?"o"+i.id:"i"+t.getMapType();(e[r]=e[r]||[]).push(t)}),A(e,function(t,i){for(var r,o,a,s=(r=U(t,function(u){return u.getData()}),o=t[0].get("mapValueCalculation"),a={},A(r,function(u){u.each(u.mapDimension("value"),function(h,c){var p="ec-"+u.getName(c);a[p]=a[p]||[],isNaN(h)||a[p].push(h)})}),r[0].map(r[0].mapDimension("value"),function(u,h){for(var c="ec-"+r[0].getName(h),p=0,d=1/0,f=-1/0,g=a[c].length,v=0;v1?(d.width=p,d.height=p/x):(d.height=p,d.width=p*x),d.y=c[1]-d.height/2,d.x=c[0]-d.width/2;else{var w=n.getBoxLayoutParams();w.aspect=x,d=Vt(w,{width:y,height:m})}this.setViewRect(d.x,d.y,d.width,d.height),this.setCenter(n.get("center"),e),this.setZoom(n.get("zoom"))}var PD=function(){function n(){this.dimensions=uw}return n.prototype.create=function(e,t){var i=[];function r(a){return{nameProperty:a.get("nameProperty"),aspectScale:a.get("aspectScale"),projection:a.get("projection")}}e.eachComponent("geo",function(a,s){var l=a.get("map"),u=new pw(l+s,l,G({nameMap:a.get("nameMap")},r(a)));u.zoomLimit=a.get("scaleLimit"),i.push(u),a.coordinateSystem=u,u.model=a,u.resize=dw,u.resize(a,t)}),e.eachSeries(function(a){if(a.get("coordinateSystem")==="geo"){var s=a.get("geoIndex")||0;a.coordinateSystem=i[s]}});var o={};return e.eachSeriesByType("map",function(a){if(!a.getHostGeoModel()){var s=a.getMapType();o[s]=o[s]||[],o[s].push(a)}}),A(o,function(a,s){var l=U(a,function(h){return h.get("nameMap")}),u=new pw(s,s,G({nameMap:Kf(l)},r(a[0])));u.zoomLimit=Ht.apply(null,U(a,function(h){return h.get("scaleLimit")})),i.push(u),u.resize=dw,u.resize(a[0],t),A(a,function(h){h.coordinateSystem=u,function(c,p){A(p.get("geoCoord"),function(d,f){c.addGeoCoord(f,d)})}(u,h)})}),i},n.prototype.getFilledRegions=function(e,t,i,r){for(var o=(e||[]).slice(),a=ee(),s=0;s=0;c--)u[c]==null&&(delete l[s[c]],s.pop())}(r):qd(r,!0):(le(t!=="linear"||r.dataExtent),qd(r))}return n.prototype.mapValueToVisual=function(e){var t=this._normalizeData(e);return this._normalizedToVisual(t,e)},n.prototype.getNormalizer=function(){return he(this._normalizeData,this)},n.listVisualTypes=function(){return Oe(n.visualHandlers)},n.isValidType=function(e){return n.visualHandlers.hasOwnProperty(e)},n.eachVisual=function(e,t,i){Q(e)?A(e,t,i):t.call(i,e)},n.mapVisual=function(e,t,i){var r,o=W(e)?[]:Q(e)?{}:(r=!0,null);return n.eachVisual(e,function(a,s){var l=t.call(i,a,s);r?o=l:o[s]=l}),o},n.retrieveVisuals=function(e){var t,i={};return e&&ns(n.visualHandlers,function(r,o){e.hasOwnProperty(o)&&(i[o]=e[o],t=!0)}),t?i:null},n.prepareVisualTypes=function(e){if(W(e))e=e.slice();else{if(!VD(e))return[];var t=[];ns(e,function(i,r){t.push(r)}),e=t}return e.sort(function(i,r){return r==="color"&&i!=="color"&&i.indexOf("color")===0?1:-1}),e},n.dependsOn=function(e,t){return t==="color"?!(!e||e.indexOf(t)!==0):e===t},n.findPieceIndex=function(e,t,i){for(var r,o=1/0,a=0,s=t.length;a=a/3?1:2),h=i.y-o(l)*s*(s>=a/3?1:2);l=i.angle-Math.PI/2,t.moveTo(u,h),t.lineTo(i.x+r(l)*s,i.y+o(l)*s),t.lineTo(i.x+r(i.angle)*a,i.y+o(i.angle)*a),t.lineTo(i.x-r(l)*s,i.y-o(l)*s),t.lineTo(u,h)},e}(Ae);const WD=HD;function Bu(n,e){var t=n==null?"":n+"";return e&&(j(e)?t=e.replace("{value}",t):re(e)&&(t=e(n))),t}var YD=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.render=function(t,i,r){this.group.removeAll();var o=t.get(["axisLine","lineStyle","color"]),a=function(s,l){var u=s.get("center"),h=l.getWidth(),c=l.getHeight(),p=Math.min(h,c);return{cx:te(u[0],l.getWidth()),cy:te(u[1],l.getHeight()),r:te(s.get("radius"),p/2)}}(t,r);this._renderMain(t,i,r,o,a),this._data=t.getData()},e.prototype.dispose=function(){},e.prototype._renderMain=function(t,i,r,o,a){var s=this.group,l=t.get("clockwise"),u=-t.get("startAngle")/180*Math.PI,h=-t.get("endAngle")/180*Math.PI,c=t.getModel("axisLine"),p=c.get("roundCap")?Su:en,d=c.get("show"),f=c.getModel("lineStyle"),g=f.get("width"),v=[u,h];mc(v,!l);for(var y=(h=v[1])-(u=v[0]),m=u,x=[],_=0;d&&_=S&&(M===0?0:o[M-1][0])Math.PI/2&&(F+=Math.PI):Z==="tangential"?F=-C-Math.PI/2:Le(Z)&&(F=Z*Math.PI/180),F===0?d.add(new De({style:rt(w,{text:N,x:z,y:X,verticalAlign:p<-.8?"top":p>.8?"bottom":"middle",align:c<-.4?"left":c>.4?"right":"center"},{inheritColor:B}),silent:!0})):d.add(new De({style:rt(w,{text:N,x:z,y:X,verticalAlign:"middle",align:"center"},{inheritColor:B}),silent:!0,originX:z,originY:X,rotation:F}))}if(_.get("show")&&E!==b){P=(P=_.get("distance"))?P+h:h;for(var Y=0;Y<=S;Y++){c=Math.cos(C),p=Math.sin(C);var K=new _t({shape:{x1:c*(v-P)+f,y1:p*(v-P)+g,x2:c*(v-T-P)+f,y2:p*(v-T-P)+g},silent:!0,style:R});R.stroke==="auto"&&K.setStyle({stroke:o((E+Y/S)/b)}),d.add(K),C+=D}C-=D}else C+=I}},e.prototype._renderPointer=function(t,i,r,o,a,s,l,u,h){var c=this.group,p=this._data,d=this._progressEls,f=[],g=t.get(["pointer","show"]),v=t.getModel("progress"),y=v.get("show"),m=t.getData(),x=m.mapDimension("value"),_=+t.get("min"),w=+t.get("max"),b=[_,w],S=[s,l];function M(C,I){var D,L=m.getItemModel(C).getModel("pointer"),R=te(L.get("width"),a.r),O=te(L.get("length"),a.r),E=t.get(["pointer","icon"]),k=L.get("offsetCenter"),P=te(k[0],a.r),N=te(k[1],a.r),B=L.get("keepAspect");return(D=E?St(E,P-R/2,N-O,R,O,null,B):new WD({shape:{angle:-Math.PI/2,width:R,r:O,x:P,y:N}})).rotation=-(I+Math.PI/2),D.x=a.cx,D.y=a.cy,D}function T(C,I){var D=v.get("roundCap")?Su:en,L=v.get("overlap"),R=L?v.get("width"):h/m.count(),O=L?a.r-R:a.r-(C+1)*R,E=L?a.r:a.r-C*R,k=new D({shape:{startAngle:s,endAngle:I,cx:a.cx,cy:a.cy,clockwise:u,r0:O,r:E}});return L&&(k.z2=w-m.get(x,C)%w),k}(y||g)&&(m.diff(p).add(function(C){var I=m.get(x,C);if(g){var D=M(C,s);et(D,{rotation:-((isNaN(+I)?S[0]:Ye(I,b,S,!0))+Math.PI/2)},t),c.add(D),m.setItemGraphicEl(C,D)}if(y){var L=T(C,s),R=v.get("clip");et(L,{shape:{endAngle:Ye(I,b,S,R)}},t),c.add(L),wc(t.seriesIndex,m.dataType,C,L),f[C]=L}}).update(function(C,I){var D=m.get(x,C);if(g){var L=p.getItemGraphicEl(I),R=L?L.rotation:s,O=M(C,R);O.rotation=R,Fe(O,{rotation:-((isNaN(+D)?S[0]:Ye(D,b,S,!0))+Math.PI/2)},t),c.add(O),m.setItemGraphicEl(C,O)}if(y){var E=d[I],k=T(C,E?E.shape.endAngle:s),P=v.get("clip");Fe(k,{shape:{endAngle:Ye(D,b,S,P)}},t),c.add(k),wc(t.seriesIndex,m.dataType,C,k),f[C]=k}}).execute(),m.each(function(C){var I=m.getItemModel(C),D=I.getModel("emphasis"),L=D.get("focus"),R=D.get("blurScope"),O=D.get("disabled");if(g){var E=m.getItemGraphicEl(C),k=m.getItemVisual(C,"style"),P=k.fill;if(E instanceof Bt){var N=E.style;E.useStyle(G({image:N.image,x:N.x,y:N.y,width:N.width,height:N.height},k))}else E.useStyle(k),E.type!=="pointer"&&E.setColor(P);E.setStyle(I.getModel(["pointer","itemStyle"]).getItemStyle()),E.style.fill==="auto"&&E.setStyle("fill",o(Ye(m.get(x,C),b,[0,1],!0))),E.z2EmphasisLift=0,bi(E,I),En(E,L,R,O)}if(y){var B=f[C];B.useStyle(m.getItemVisual(C,"style")),B.setStyle(I.getModel(["progress","itemStyle"]).getItemStyle()),B.z2EmphasisLift=0,bi(B,I),En(B,L,R,O)}}),this._progressEls=f)},e.prototype._renderAnchor=function(t,i){var r=t.getModel("anchor");if(r.get("show")){var o=r.get("size"),a=r.get("icon"),s=r.get("offsetCenter"),l=r.get("keepAspect"),u=St(a,i.cx-o/2+te(s[0],i.r),i.cy-o/2+te(s[1],i.r),o,o,null,l);u.z2=r.get("showAbove")?1:0,u.setStyle(r.getModel("itemStyle").getItemStyle()),this.group.add(u)}},e.prototype._renderTitleAndDetail=function(t,i,r,o,a){var s=this,l=t.getData(),u=l.mapDimension("value"),h=+t.get("min"),c=+t.get("max"),p=new me,d=[],f=[],g=t.isAnimationEnabled(),v=t.get(["pointer","showAbove"]);l.diff(this._data).add(function(y){d[y]=new De({silent:!0}),f[y]=new De({silent:!0})}).update(function(y,m){d[y]=s._titleEls[m],f[y]=s._detailEls[m]}).execute(),l.each(function(y){var m=l.getItemModel(y),x=l.get(u,y),_=new me,w=o(Ye(x,[h,c],[0,1],!0)),b=m.getModel("title");if(b.get("show")){var S=b.get("offsetCenter"),M=a.cx+te(S[0],a.r),T=a.cy+te(S[1],a.r);(k=d[y]).attr({z2:v?0:2,style:rt(b,{x:M,y:T,text:l.getName(y),align:"center",verticalAlign:"middle"},{inheritColor:w})}),_.add(k)}var C=m.getModel("detail");if(C.get("show")){var I=C.get("offsetCenter"),D=a.cx+te(I[0],a.r),L=a.cy+te(I[1],a.r),R=te(C.get("width"),a.r),O=te(C.get("height"),a.r),E=t.get(["progress","show"])?l.getItemVisual(y,"style").fill:w,k=f[y],P=C.get("formatter");k.attr({z2:v?0:2,style:rt(C,{x:D,y:L,text:Bu(x,P),width:isNaN(R)?null:R,height:isNaN(O)?null:O,align:"center",verticalAlign:"middle"},{inheritColor:E})}),Qy(k,{normal:C},x,function(N){return Bu(N,P)}),g&&em(k,y,l,t,{getFormattedLabel:function(N,B,z,X,Z,F){return Bu(F?F.interpolatedValue:x,P)}}),_.add(k)}p.add(_)}),this.group.add(p),this._titleEls=d,this._detailEls=f},e.type="gauge",e}(st);const UD=YD,XD=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.visualStyleAccessPath="itemStyle",t}return V(e,n),e.prototype.getInitialData=function(t,i){return Au(this,["value"])},e.type="series.gauge",e.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:{show:!0,roundCap:!1,lineStyle:{color:[[1,"#E6EBF8"]],width:10}},progress:{show:!1,overlap:!0,width:10,roundCap:!1,clip:!0},splitLine:{show:!0,length:10,distance:10,lineStyle:{color:"#63677A",width:3,type:"solid"}},axisTick:{show:!0,splitNumber:5,length:6,distance:10,lineStyle:{color:"#63677A",width:1,type:"solid"}},axisLabel:{show:!0,distance:15,color:"#464646",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:"#fff",borderWidth:0,borderColor:"#5470c6"}},title:{show:!0,offsetCenter:[0,"20%"],color:"#464646",fontSize:16,valueAnimation:!1},detail:{show:!0,backgroundColor:"rgba(0,0,0,0)",borderWidth:0,borderColor:"#ccc",width:100,height:null,padding:[5,10],offsetCenter:[0,"40%"],color:"#464646",fontSize:30,fontWeight:"bold",lineHeight:30,valueAnimation:!1}},e}(kt);function jD(n){(function(e){if(!e.parallel){var t=!1;A(e.series,function(i){i&&i.type==="parallel"&&(t=!0)}),t&&(e.parallel=[{}])}})(n),function(e){var t=Qe(e.parallelAxis);A(t,function(i){if(Q(i)){var r=i.parallelIndex||0,o=Qe(e.parallel)[r];o&&o.parallelAxisDefault&&pe(i,o.parallelAxisDefault,!1)}})}(n)}var ZD=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.render=function(t,i,r){this._model=t,this._api=r,this._handlers||(this._handlers={},A(qD,function(o,a){r.getZr().on(a,this._handlers[a]=he(o,this))},this)),Pp(this,"_throttledDispatchExpand",t.get("axisExpandRate"),"fixRate")},e.prototype.dispose=function(t,i){zl(this,"_throttledDispatchExpand"),A(this._handlers,function(r,o){i.getZr().off(o,r)}),this._handlers=null},e.prototype._throttledDispatchExpand=function(t){this._dispatchExpand(t)},e.prototype._dispatchExpand=function(t){t&&this._api.dispatchAction(G({type:"parallelAxisExpand"},t))},e.type="parallel",e}(Ze),qD={mousedown:function(n){$d(this,"click")&&(this._mouseDownPoint=[n.offsetX,n.offsetY])},mouseup:function(n){var e=this._mouseDownPoint;if($d(this,"click")&&e){var t=[n.offsetX,n.offsetY];if(Math.pow(e[0]-t[0],2)+Math.pow(e[1]-t[1],2)>5)return;var i=this._model.coordinateSystem.getSlidedAxisExpandWindow([n.offsetX,n.offsetY]);i.behavior!=="none"&&this._dispatchExpand({axisExpandWindow:i.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(n){if(!this._mouseDownPoint&&$d(this,"mousemove")){var e=this._model,t=e.coordinateSystem.getSlidedAxisExpandWindow([n.offsetX,n.offsetY]),i=t.behavior;i==="jump"&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand(i==="none"?null:{axisExpandWindow:t.axisExpandWindow,animation:i==="jump"?null:{duration:0}})}}};function $d(n,e){var t=n._model;return t.get("axisExpandable")&&t.get("axisExpandTriggerOn")===e}const KD=ZD,JD=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.init=function(){n.prototype.init.apply(this,arguments),this.mergeOption({})},e.prototype.mergeOption=function(t){var i=this.option;t&&pe(i,t,!0),this._initDimensions()},e.prototype.contains=function(t,i){var r=t.get("parallelIndex");return r!=null&&i.getComponent("parallel",r)===this},e.prototype.setAxisExpand=function(t){A(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(i){t.hasOwnProperty(i)&&(this.option[i]=t[i])},this)},e.prototype._initDimensions=function(){var t=this.dimensions=[],i=this.parallelAxisIndex=[];A(Ge(this.ecModel.queryComponents({mainType:"parallelAxis"}),function(r){return(r.get("parallelIndex")||0)===this.componentIndex},this),function(r){t.push("dim"+r.get("dim")),i.push(r.componentIndex)})},e.type="parallel",e.dependencies=["parallelAxis"],e.layoutMode="box",e.defaultOption={z:0,left:80,top:60,right:80,bottom:60,layout:"horizontal",axisExpandable:!1,axisExpandCenter:null,axisExpandCount:0,axisExpandWidth:50,axisExpandRate:17,axisExpandDebounce:50,axisExpandSlideTriggerArea:[-.15,.05,.4],axisExpandTriggerOn:"click",parallelAxisDefault:null},e}(Se);var $D=function(n){function e(t,i,r,o,a){var s=n.call(this,t,i,r)||this;return s.type=o||"value",s.axisIndex=a,s}return V(e,n),e.prototype.isHorizontal=function(){return this.coordinateSystem.getModel().get("layout")!=="horizontal"},e}(Fn);const QD=$D;function Vu(n,e,t,i,r,o){n=n||0;var a=t[1]-t[0];if(r!=null&&(r=So(r,[0,a])),o!=null&&(o=Math.max(o,r??0)),i==="all"){var s=Math.abs(e[1]-e[0]);s=So(s,[0,a]),r=o=So(s,[r,o]),i=0}e[0]=So(e[0],t),e[1]=So(e[1],t);var l=Qd(e,i);e[i]+=n;var u,h=r||0,c=t.slice();return l.sign<0?c[0]+=h:c[1]-=h,e[i]=So(e[i],c),u=Qd(e,i),r!=null&&(u.sign!==l.sign||u.spano&&(e[1-i]=e[i]+u.sign*o),e}function Qd(n,e){var t=n[e]-n[1-e];return{span:Math.abs(t),sign:t>0?-1:t<0?1:e?-1:1}}function So(n,e){return Math.min(e[1]!=null?e[1]:1/0,Math.max(e[0]!=null?e[0]:-1/0,n))}var ef=A,mw=Math.min,xw=Math.max,_w=Math.floor,ek=Math.ceil,ww=Ue,tk=Math.PI,nk=function(){function n(e,t,i){this.type="parallel",this._axesMap=ee(),this._axesLayout={},this.dimensions=e.dimensions,this._model=e,this._init(e,t,i)}return n.prototype._init=function(e,t,i){var r=e.dimensions,o=e.parallelAxisIndex;ef(r,function(a,s){var l=o[s],u=t.getComponent("parallelAxis",l),h=this._axesMap.set(a,new QD(a,fu(u),[0,0],u.get("type"),l)),c=h.type==="category";h.onBand=c&&u.get("boundaryGap"),h.inverse=u.get("inverse"),u.axis=h,h.model=u,h.coordinateSystem=u.coordinateSystem=this},this)},n.prototype.update=function(e,t){this._updateAxesFromSeries(this._model,e)},n.prototype.containPoint=function(e){var t=this._makeLayoutInfo(),i=t.axisBase,r=t.layoutBase,o=t.pixelDimIndex,a=e[1-o],s=e[o];return a>=i&&a<=i+t.axisLength&&s>=r&&s<=r+t.layoutLength},n.prototype.getModel=function(){return this._model},n.prototype._updateAxesFromSeries=function(e,t){t.eachSeries(function(i){if(e.contains(i,t)){var r=i.getData();ef(this.dimensions,function(o){var a=this._axesMap.get(o);a.scale.unionExtentFromData(r,r.mapDimension(o)),wo(a.scale,a.model)},this)}},this)},n.prototype.resize=function(e,t){this._rect=Vt(e.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()}),this._layoutAxes()},n.prototype.getRect=function(){return this._rect},n.prototype._makeLayoutInfo=function(){var e,t=this._model,i=this._rect,r=["x","y"],o=["width","height"],a=t.get("layout"),s=a==="horizontal"?0:1,l=i[o[s]],u=[0,l],h=this.dimensions.length,c=Fu(t.get("axisExpandWidth"),u),p=Fu(t.get("axisExpandCount")||0,[0,h]),d=t.get("axisExpandable")&&h>3&&h>p&&p>1&&c>0&&l>0,f=t.get("axisExpandWindow");f?(e=Fu(f[1]-f[0],u),f[1]=f[0]+e):(e=Fu(c*(p-1),u),(f=[c*(t.get("axisExpandCenter")||_w(h/2))-e/2])[1]=f[0]+e);var g=(l-e)/(h-p);g<3&&(g=0);var v=[_w(ww(f[0]/c,1))+1,ek(ww(f[1]/c,1))-1],y=g/c*f[0];return{layout:a,pixelDimIndex:s,layoutBase:i[r[s]],layoutLength:l,axisBase:i[r[1-s]],axisLength:i[o[1-s]],axisExpandable:d,axisExpandWidth:c,axisCollapseWidth:g,axisExpandWindow:f,axisCount:h,winInnerIndices:v,axisExpandWindow0Pos:y}},n.prototype._layoutAxes=function(){var e=this._rect,t=this._axesMap,i=this.dimensions,r=this._makeLayoutInfo(),o=r.layout;t.each(function(a){var s=[0,r.axisLength],l=a.inverse?1:0;a.setExtent(s[l],s[1-l])}),ef(i,function(a,s){var l=(r.axisExpandable?rk:ik)(s,r),u={horizontal:{x:l.position,y:r.axisLength},vertical:{x:0,y:l.position}},h={horizontal:tk/2,vertical:0},c=[u[o].x+e.x,u[o].y+e.y],p=h[o],d=[1,0,0,1,0,0];Hi(d,d,p),Gi(d,d,c),this._axesLayout[a]={position:c,rotation:p,transform:d,axisNameAvailableWidth:l.axisNameAvailableWidth,axisLabelShow:l.axisLabelShow,nameTruncateMaxWidth:l.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},n.prototype.getAxis=function(e){return this._axesMap.get(e)},n.prototype.dataToPoint=function(e,t){return this.axisCoordToPoint(this._axesMap.get(t).dataToCoord(e),t)},n.prototype.eachActiveState=function(e,t,i,r){i==null&&(i=0),r==null&&(r=e.count());var o=this._axesMap,a=this.dimensions,s=[],l=[];A(a,function(g){s.push(e.mapDimension(g)),l.push(o.get(g).model)});for(var u=this.hasAxisBrushed(),h=i;ho*(1-c[0])?(u="jump",s=l-o*(1-c[2])):(s=l-o*c[1])>=0&&(s=l-o*(1-c[1]))<=0&&(s=0),(s*=t.axisExpandWidth/h)?Vu(s,r,a,"all"):u="none";else{var d=r[1]-r[0];(r=[xw(0,a[1]*l/d-d/2)])[1]=mw(a[1],r[0]+d),r[0]=r[1]-d}return{axisExpandWindow:r,behavior:u}},n}();function Fu(n,e){return mw(xw(n,e[0]),e[1])}function ik(n,e){var t=e.layoutLength/(e.axisCount-1);return{position:t*n,axisNameAvailableWidth:t,axisLabelShow:!0}}function rk(n,e){var t,i,r=e.layoutLength,o=e.axisExpandWidth,a=e.axisCount,s=e.axisCollapseWidth,l=e.winInnerIndices,u=s,h=!1;return n=0;r--)Qo(i[r])},e.prototype.getActiveState=function(t){var i=this.activeIntervals;if(!i.length)return"normal";if(t==null||isNaN(+t))return"inactive";if(i.length===1){var r=i[0];if(r[0]<=t&&t<=r[1])return"active"}else for(var o=0,a=i.length;ouk}(n)||o){if(a&&!o){s.brushMode==="single"&&of(n);var l=ie(s);l.brushType=Bw(l.brushType,a),l.panelId=a===Dr?null:a.panelId,o=n._creatingCover=Cw(n,l),n._covers.push(o)}if(o){var u=Gu[Bw(n._brushType,a)];o.__brushOption.range=u.getCreatingRange(uf(n,o,n._track)),i&&(Iw(n,o),u.updateCommon(n,o)),Aw(n,o),r={isEnd:i}}}else i&&s.brushMode==="single"&&s.removeOnClick&&rf(n,e,t)&&of(n)&&(r={isEnd:i,removeOnClick:!0});return r}function Bw(n,e){return n==="auto"?(le(e&&e.defaultBrushType,'MUST have defaultBrushType when brushType is "atuo"'),e.defaultBrushType):n}var vk={mousedown:function(n){if(this._dragging)Vw(this,n);else if(!n.target||!n.target.draggable){hf(n);var e=this.group.transformCoordToLocal(n.offsetX,n.offsetY);this._creatingCover=null,(this._creatingPanel=rf(this,n,e))&&(this._dragging=!0,this._track=[e.slice()])}},mousemove:function(n){var e=n.offsetX,t=n.offsetY,i=this.group.transformCoordToLocal(e,t);if(function(o,a,s){if(o._brushType&&!function(d,f,g){var v=d._zr;return f<0||f>v.getWidth()||g<0||g>v.getHeight()}(o,a.offsetX,a.offsetY)){var l=o._zr,u=o._covers,h=rf(o,a,s);if(!o._dragging)for(var c=0;c0?1:-1})(t,o,r,i,c),function(f,g,v,y,m,x,_,w,b,S){var M,T=b.valueDim,C=b.categoryDim,I=Math.abs(v[C.wh]),D=f.getItemVisual(g,"symbolSize");M=W(D)?D.slice():D==null?["100%","100%"]:[D,D],M[C.index]=te(M[C.index],I),M[T.index]=te(M[T.index],y?I:Math.abs(x)),S.symbolSize=M;var L=S.symbolScale=[M[0]/w,M[1]/w];L[T.index]*=(b.isHorizontal?-1:1)*_}(n,e,r,o,0,c.boundingLength,c.pxSign,u,i,c),function(f,g,v,y,m){var x=f.get(bk)||0;x&&(df.attr({scaleX:g[0],scaleY:g[1],rotation:v}),df.updateTransform(),x/=df.getLineScale(),x*=g[y.valueDim.index]),m.valueLineWidth=x||0}(t,c.symbolScale,l,i,c);var p=c.symbolSize,d=Ep(t.get("symbolOffset"),p);return function(f,g,v,y,m,x,_,w,b,S,M,T){var C=M.categoryDim,I=M.valueDim,D=T.pxSign,L=Math.max(g[I.index]+w,0),R=L;if(y){var O=Math.abs(b),E=Ht(f.get("symbolMargin"),"15%")+"",k=!1;E.lastIndexOf("!")===E.length-1&&(k=!0,E=E.slice(0,E.length-1));var P=te(E,g[I.index]),N=Math.max(L+2*P,0),B=k?0:2*P,z=Bs(y),X=z?y:ib((O+B)/N);N=L+2*(P=(O-X*L)/2/(k?X:Math.max(X-1,1))),B=k?0:2*P,z||y==="fixed"||(X=S?ib((Math.abs(S)+B)/N):0),R=X*N-B,T.repeatTimes=X,T.symbolMargin=P}var Z=D*(R/2),F=T.pathPosition=[];F[C.index]=v[C.wh]/2,F[I.index]=_==="start"?Z:_==="end"?b-Z:b/2,x&&(F[0]+=x[0],F[1]+=x[1]);var Y=T.bundlePosition=[];Y[C.index]=v[C.xy],Y[I.index]=v[I.xy];var K=T.barRectShape=G({},v);K[I.wh]=D*Math.max(Math.abs(v[I.wh]),Math.abs(F[I.index]+Z)),K[C.wh]=v[C.wh];var oe=T.clipShape={};oe[C.xy]=-v[C.xy],oe[C.wh]=M.ecSize[C.wh],oe[I.xy]=0,oe[I.wh]=v[I.wh]}(t,p,r,o,0,d,s,c.valueLineWidth,c.boundingLength,c.repeatCutLength,i,c),c}function ff(n,e){return n.toGlobalCoord(n.dataToCoord(n.scale.parse(e)))}function jw(n){var e=n.symbolPatternSize,t=St(n.symbolType,-e/2,-e/2,e,e);return t.attr({culling:!0}),t.type!=="image"&&t.setStyle({strokeNoScale:!0}),t}function Zw(n,e,t,i){var r=n.__pictorialBundle,o=t.symbolSize,a=t.valueLineWidth,s=t.pathPosition,l=e.valueDim,u=t.repeatTimes||0,h=0,c=o[e.valueDim.index]+a+2*t.symbolMargin;for(gf(n,function(g){g.__pictorialAnimationIndex=h,g.__pictorialRepeatTimes=u,h0:y<0)&&(m=u-1-g),v[l.index]=c*(m-u/2+.5)+s[l.index],{x:v[0],y:v[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation}}}function qw(n,e,t,i){var r=n.__pictorialBundle,o=n.__pictorialMainPath;o?To(o,null,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:t.symbolScale[0],scaleY:t.symbolScale[1],rotation:t.rotation},t,i):(o=n.__pictorialMainPath=jw(t),r.add(o),To(o,{x:t.pathPosition[0],y:t.pathPosition[1],scaleX:0,scaleY:0,rotation:t.rotation},{scaleX:t.symbolScale[0],scaleY:t.symbolScale[1]},t,i))}function Kw(n,e,t){var i=G({},e.barRectShape),r=n.__pictorialBarRect;r?To(r,null,{shape:i},e,t):((r=n.__pictorialBarRect=new Re({z2:2,shape:i,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}})).disableMorphing=!0,n.add(r))}function Jw(n,e,t,i){if(t.symbolClip){var r=n.__pictorialClipPath,o=G({},t.clipShape),a=e.valueDim,s=t.animationModel,l=t.dataIndex;if(r)Fe(r,{shape:o},s,l);else{o[a.wh]=0,r=new Re({shape:o}),n.__pictorialBundle.setClipPath(r),n.__pictorialClipPath=r;var u={};u[a.wh]=t.clipShape[a.wh],no[i?"updateProps":"initProps"](r,{shape:u},s,l)}}}function $w(n,e){var t=n.getItemModel(e);return t.getAnimationDelayParams=Sk,t.isAnimationEnabled=Mk,t}function Sk(n){return{index:n.__pictorialAnimationIndex,count:n.__pictorialRepeatTimes}}function Mk(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function Qw(n,e,t,i){var r=new me,o=new me;return r.add(o),r.__pictorialBundle=o,o.x=t.bundlePosition[0],o.y=t.bundlePosition[1],t.symbolRepeat?Zw(r,e,t):qw(r,0,t),Kw(r,t,i),Jw(r,e,t,i),r.__pictorialShapeStr=tb(n,t),r.__pictorialSymbolMeta=t,r}function eb(n,e,t,i){var r=i.__pictorialBarRect;r&&r.removeTextContent();var o=[];gf(i,function(a){o.push(a)}),i.__pictorialMainPath&&o.push(i.__pictorialMainPath),i.__pictorialClipPath&&(t=null),A(o,function(a){ya(a,{scaleX:0,scaleY:0},t,e,function(){i.parent&&i.parent.remove(i)})}),n.setItemGraphicEl(e,null)}function tb(n,e){return[n.getItemVisual(e.dataIndex,"symbol")||"none",!!e.symbolRepeat,!!e.symbolClip].join(":")}function gf(n,e,t){A(n.__pictorialBundle.children(),function(i){i!==n.__pictorialBarRect&&e.call(t,i)})}function To(n,e,t,i,r,o){e&&n.attr(e),i.symbolClip&&!r?t&&n.attr(t):t&&no[r?"updateProps":"initProps"](n,t,i.animationModel,i.dataIndex,o)}function nb(n,e,t){var i=t.dataIndex,r=t.itemModel,o=r.getModel("emphasis"),a=o.getModel("itemStyle").getItemStyle(),s=r.getModel(["blur","itemStyle"]).getItemStyle(),l=r.getModel(["select","itemStyle"]).getItemStyle(),u=r.getShallow("cursor"),h=o.get("focus"),c=o.get("blurScope"),p=o.get("scale");gf(n,function(g){if(g instanceof Bt){var v=g.style;g.useStyle(G({image:v.image,x:v.x,y:v.y,width:v.width,height:v.height},t.style))}else g.useStyle(t.style);var y=g.ensureState("emphasis");y.style=a,p&&(y.scaleX=1.1*g.scaleX,y.scaleY=1.1*g.scaleY),g.ensureState("blur").style=s,g.ensureState("select").style=l,u&&(g.cursor=u),g.z2=t.z2});var d=e.valueDim.posDesc[+(t.boundingLength>0)],f=n.__pictorialBarRect;f.ignoreClip=!0,ei(f,ti(r),{labelFetcher:e.seriesModel,labelDataIndex:i,defaultText:wu(e.seriesModel.getData(),i),inheritColor:t.style.fill,defaultOpacity:t.style.opacity,defaultOutsidePosition:d}),En(n,h,c,o.get("disabled"))}function ib(n){var e=Math.round(n);return Math.abs(n-e)<1e-4?e:Math.ceil(n)}const Tk=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.render=function(t,i,r){var o=this.group,a=t.getData(),s=this._data,l=t.coordinateSystem,u=l.getBaseAxis().isHorizontal(),h=l.master.getRect(),c={ecSize:{width:r.getWidth(),height:r.getHeight()},seriesModel:t,coordSys:l,coordSysExtent:[[h.x,h.x+h.width],[h.y,h.y+h.height]],isHorizontal:u,valueDim:Uw[+u],categoryDim:Uw[1-+u]};a.diff(s).add(function(d){if(a.hasValue(d)){var f=$w(a,d),g=Xw(a,d,f,c),v=Qw(a,c,g);a.setItemGraphicEl(d,v),o.add(v),nb(v,c,g)}}).update(function(d,f){var g=s.getItemGraphicEl(f);if(a.hasValue(d)){var v=$w(a,d),y=Xw(a,d,v,c),m=tb(a,y);g&&m!==g.__pictorialShapeStr&&(o.remove(g),a.setItemGraphicEl(d,null),g=null),g?function(x,_,w){var b=w.animationModel,S=w.dataIndex,M=x.__pictorialBundle;Fe(M,{x:w.bundlePosition[0],y:w.bundlePosition[1]},b,S),w.symbolRepeat?Zw(x,_,w,!0):qw(x,_,w,!0),Kw(x,w,!0),Jw(x,_,w,!0)}(g,c,y):g=Qw(a,c,y,!0),a.setItemGraphicEl(d,g),g.__pictorialSymbolMeta=y,o.add(g),nb(g,c,y)}else o.remove(g)}).remove(function(d){var f=s.getItemGraphicEl(d);f&&eb(s,d,f.__pictorialSymbolMeta.animationModel,f)}).execute();var p=t.get("clip",!0)?Y_(t.coordinateSystem,!1,t):null;return p?o.setClipPath(p):o.removeClipPath(),this._data=a,this.group},e.prototype.remove=function(t,i){var r=this.group,o=this._data;t.get("animation")?o&&o.eachItemGraphicEl(function(a){eb(o,ye(a).dataIndex,t,a)}):r.removeAll()},e.type="pictorialBar",e}(st),Ck=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.hasSymbolVisual=!0,t.defaultSymbol="roundRect",t}return V(e,n),e.prototype.getInitialData=function(t){return t.stack=null,n.prototype.getInitialData.apply(this,arguments)},e.type="series.pictorialBar",e.dependencies=["grid"],e.defaultOption=ba(bu.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:"#212121"}}}),e}(bu);var Lr=ze(),rb=ie,vf=he,Ik=function(){function n(){this._dragging=!1,this.animationThreshold=15}return n.prototype.render=function(e,t,i,r){var o=t.get("value"),a=t.get("status");if(this._axisModel=e,this._axisPointerModel=t,this._api=i,r||this._lastValue!==o||this._lastStatus!==a){this._lastValue=o,this._lastStatus=a;var s=this._group,l=this._handle;if(!a||a==="hide")return s&&s.hide(),void(l&&l.hide());s&&s.show(),l&&l.show();var u={};this.makeElOption(u,o,e,t,i);var h=u.graphicKey;h!==this._lastGraphicKey&&this.clear(i),this._lastGraphicKey=h;var c=this._moveAnimation=this.determineAnimation(e,t);if(s){var p=Te(ob,t,c);this.updatePointerEl(s,u,p),this.updateLabelEl(s,u,p,t)}else s=this._group=new me,this.createPointerEl(s,u,e,t),this.createLabelEl(s,u,e,t),i.getZr().add(s);lb(s,t,!0),this._renderHandle(o)}},n.prototype.remove=function(e){this.clear(e)},n.prototype.dispose=function(e){this.clear(e)},n.prototype.determineAnimation=function(e,t){var i=t.get("animation"),r=e.axis,o=r.type==="category",a=t.get("snap");if(!a&&!o)return!1;if(i==="auto"||i==null){var s=this.animationThreshold;if(o&&r.getBandWidth()>s)return!0;if(a){var l=Bd(e).seriesDataCount,u=r.getExtent();return Math.abs(u[0]-u[1])/l>s}return!1}return i===!0},n.prototype.makeElOption=function(e,t,i,r,o){},n.prototype.createPointerEl=function(e,t,i,r){var o=t.pointer;if(o){var a=Lr(e).pointerEl=new no[o.type](rb(t.pointer));e.add(a)}},n.prototype.createLabelEl=function(e,t,i,r){if(t.label){var o=Lr(e).labelEl=new De(rb(t.label));e.add(o),sb(o,r)}},n.prototype.updatePointerEl=function(e,t,i){var r=Lr(e).pointerEl;r&&t.pointer&&(r.setStyle(t.pointer.style),i(r,{shape:t.pointer.shape}))},n.prototype.updateLabelEl=function(e,t,i,r){var o=Lr(e).labelEl;o&&(o.setStyle(t.label.style),i(o,{x:t.label.x,y:t.label.y}),sb(o,r))},n.prototype._renderHandle=function(e){if(!this._dragging&&this.updateHandleTransform){var t,i=this._axisPointerModel,r=this._api.getZr(),o=this._handle,a=i.getModel("handle"),s=i.get("status");if(!a.get("show")||!s||s==="hide")return o&&r.remove(o),void(this._handle=null);this._handle||(t=!0,o=this._handle=_a(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){Fi(u.event)},onmousedown:vf(this._onHandleDragMove,this,0,0),drift:vf(this._onHandleDragMove,this),ondragend:vf(this._onHandleDragEnd,this)}),r.add(o)),lb(o,i,!1),o.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=a.get("size");W(l)||(l=[l,l]),o.scaleX=l[0]/2,o.scaleY=l[1]/2,Pp(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(e,t)}},n.prototype._moveHandleToValue=function(e,t){ob(this._axisPointerModel,!t&&this._moveAnimation,this._handle,yf(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},n.prototype._onHandleDragMove=function(e,t){var i=this._handle;if(i){this._dragging=!0;var r=this.updateHandleTransform(yf(i),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=r,i.stopAnimation(),i.attr(yf(r)),Lr(i).lastProp=null,this._doDispatchAxisPointer()}},n.prototype._doDispatchAxisPointer=function(){if(this._handle){var e=this._payloadInfo,t=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:e.cursorPoint[0],y:e.cursorPoint[1],tooltipOption:e.tooltipOption,axesInfo:[{axisDim:t.axis.dim,axisIndex:t.componentIndex}]})}},n.prototype._onHandleDragEnd=function(){if(this._dragging=!1,this._handle){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},n.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),i=this._group,r=this._handle;t&&i&&(this._lastGraphicKey=null,i&&t.remove(i),r&&t.remove(r),this._group=null,this._handle=null,this._payloadInfo=null),zl(this,"_doDispatchAxisPointer")},n.prototype.doClear=function(){},n.prototype.buildLabel=function(e,t,i){return{x:e[i=i||0],y:e[1-i],width:t[i],height:t[1-i]}},n}();function ob(n,e,t,i){ab(Lr(t).lastProp,i)||(Lr(t).lastProp=i,e?Fe(t,i,n):(t.stopAnimation(),t.attr(i)))}function ab(n,e){if(Q(n)&&Q(e)){var t=!0;return A(e,function(i,r){t=t&&ab(n[r],i)}),!!t}return n===e}function sb(n,e){n[e.get(["label","show"])?"show":"hide"]()}function yf(n){return{x:n.x||0,y:n.y||0,rotation:n.rotation||0}}function lb(n,e,t){var i=e.get("z"),r=e.get("zlevel");n&&n.traverse(function(o){o.type!=="group"&&(i!=null&&(o.z=i),r!=null&&(o.zlevel=r),o.silent=t)})}const ub=Ik;function hb(n){var e,t=n.get("type"),i=n.getModel(t+"Style");return t==="line"?(e=i.getLineStyle()).fill=null:t==="shadow"&&((e=i.getAreaStyle()).stroke=null),e}function cb(n,e,t,i,r){var o=pb(t.get("value"),e.axis,e.ecModel,t.get("seriesDataIndices"),{precision:t.get(["label","precision"]),formatter:t.get(["label","formatter"])}),a=t.getModel("label"),s=so(a.get("padding")||0),l=a.getFont(),u=Ko(o,l),h=r.position,c=u.width+s[1]+s[3],p=u.height+s[0]+s[2],d=r.align;d==="right"&&(h[0]-=c),d==="center"&&(h[0]-=c/2);var f=r.verticalAlign;f==="bottom"&&(h[1]-=p),f==="middle"&&(h[1]-=p/2),function(v,y,m,x){var _=x.getWidth(),w=x.getHeight();v[0]=Math.min(v[0]+y,_)-y,v[1]=Math.min(v[1]+m,w)-m,v[0]=Math.max(v[0],0),v[1]=Math.max(v[1],0)}(h,c,p,i);var g=a.get("backgroundColor");g&&g!=="auto"||(g=e.get(["axisLine","lineStyle","color"])),n.label={x:h[0],y:h[1],style:rt(a,{text:o,font:l,fill:a.getTextColor(),padding:s,backgroundColor:g}),z2:10}}function pb(n,e,t,i,r){n=e.scale.parse(n);var o=e.scale.getLabel({value:n},{precision:r.precision}),a=r.formatter;if(a){var s={value:vd(e,{value:n}),axisDimension:e.dim,axisIndex:e.index,seriesData:[]};A(i,function(l){var u=t.getSeriesByIndex(l.seriesIndex),h=l.dataIndexInside,c=u&&u.getDataParams(h);c&&s.seriesData.push(c)}),j(a)?o=a.replace("{value}",o):re(a)&&(o=a(s))}return o}function db(n,e,t){var i=[1,0,0,1,0,0];return Hi(i,i,t.rotation),Gi(i,i,t.position),Si([n.dataToCoord(e),(t.labelOffset||0)+(t.labelDirection||1)*(t.labelMargin||0)],i)}function fb(n,e,t){return{x1:n[t=t||0],y1:n[1-t],x2:e[t],y2:e[1-t]}}function gb(n,e,t,i,r,o){return{cx:n,cy:e,r0:t,r:i,startAngle:r,endAngle:o,clockwise:!0}}var Ak=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.makeElOption=function(t,i,r,o,a){var s=r.axis,l=s.grid,u=o.get("type"),h=vb(l,s).getOtherAxis(s).getGlobalExtent(),c=s.toGlobalCoord(s.dataToCoord(i,!0));if(u&&u!=="none"){var p=hb(o),d=Dk[u](s,c,h);d.style=p,t.graphicKey=d.type,t.pointer=d}(function(f,g,v,y,m,x){var _=Oi.innerTextLayout(v.rotation,0,v.labelDirection);v.labelMargin=m.get(["label","margin"]),cb(g,y,m,x,{position:db(y.axis,f,v),align:_.textAlign,verticalAlign:_.textVerticalAlign})})(i,t,Rd(l.model,r),r,o,a)},e.prototype.getHandleTransform=function(t,i,r){var o=Rd(i.axis.grid.model,i,{labelInside:!1});o.labelMargin=r.get(["handle","margin"]);var a=db(i.axis,t,o);return{x:a[0],y:a[1],rotation:o.rotation+(o.labelDirection<0?Math.PI:0)}},e.prototype.updateHandleTransform=function(t,i,r,o){var a=r.axis,s=a.grid,l=a.getGlobalExtent(!0),u=vb(s,a).getOtherAxis(a).getGlobalExtent(),h=a.dim==="x"?0:1,c=[t.x,t.y];c[h]+=i[h],c[h]=Math.min(l[1],c[h]),c[h]=Math.max(l[0],c[h]);var p=(u[1]+u[0])/2,d=[p,p];return d[h]=c[h],{x:c[0],y:c[1],rotation:t.rotation,cursorPoint:d,tooltipOption:[{verticalAlign:"middle"},{align:"center"}][h]}},e}(ub);function vb(n,e){var t={};return t[e.dim+"AxisIndex"]=e.index,n.getCartesian(t)}var Dk={line:function(n,e,t){return{type:"Line",subPixelOptimize:!0,shape:fb([e,t[0]],[e,t[1]],yb(n))}},shadow:function(n,e,t){var i,r,o,a=Math.max(1,n.getBandWidth()),s=t[1]-t[0];return{type:"Rect",shape:(i=[e-a/2,t[0]],r=[a,s],o=yb(n),{x:i[o=o||0],y:i[1-o],width:r[o],height:r[1-o]})}}};function yb(n){return n.dim==="x"?0:1}const kk=Ak,Lk=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.type="axisPointer",e.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#B9BEC9",width:1,type:"dashed"},shadowStyle:{color:"rgba(210,219,238,0.2)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}},e}(Se);var ui=ze(),Pk=A;function mb(n,e,t){if(!_e.node){var i=e.getZr();ui(i).records||(ui(i).records={}),function(r,o){if(ui(r).initialized)return;function a(s,l){r.on(s,function(u){var h=function(c){var p={showTip:[],hideTip:[]},d=function(f){var g=p[f.type];g?g.push(f):(f.dispatchAction=d,c.dispatchAction(f))};return{dispatchAction:d,pendings:p}}(o);Pk(ui(r).records,function(c){c&&l(c,u,h.dispatchAction)}),function(c,p){var d,f=c.showTip.length,g=c.hideTip.length;f?d=c.showTip[f-1]:g&&(d=c.hideTip[g-1]),d&&(d.dispatchAction=null,p.dispatchAction(d))}(h.pendings,o)})}ui(r).initialized=!0,a("click",Te(xb,"click")),a("mousemove",Te(xb,"mousemove")),a("globalout",Ok)}(i,e),(ui(i).records[n]||(ui(i).records[n]={})).handler=t}}function Ok(n,e,t){n.handler("leave",null,t)}function xb(n,e,t,i){e.handler(n,t,i)}function mf(n,e){if(!_e.node){var t=e.getZr();(ui(t).records||{})[n]&&(ui(t).records[n]=null)}}var Rk=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.render=function(t,i,r){var o=i.getComponent("tooltip"),a=t.get("triggerOn")||o&&o.get("triggerOn")||"mousemove|click";mb("axisPointer",r,function(s,l,u){a!=="none"&&(s==="leave"||a.indexOf(s)>=0)&&u({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},e.prototype.remove=function(t,i){mf("axisPointer",i)},e.prototype.dispose=function(t,i){mf("axisPointer",i)},e.type="axisPointer",e}(Ze);const Ek=Rk;function _b(n,e){var t,i=[],r=n.seriesIndex;if(r==null||!(t=e.getSeriesByIndex(r)))return{point:[]};var o=t.getData(),a=$i(o,n);if(a==null||a<0||W(a))return{point:[]};var s=o.getItemGraphicEl(a),l=t.coordinateSystem;if(t.getTooltipPosition)i=t.getTooltipPosition(a)||[];else if(l&&l.dataToPoint)if(n.isStacked){var u=l.getBaseAxis(),h=l.getOtherAxis(u).dim,c=u.dim,p=h==="x"||h==="radius"?1:0,d=o.mapDimension(c),f=[];f[p]=o.get(d,a),f[1-p]=o.get(o.getCalculationInfo("stackResultDimension"),a),i=l.dataToPoint(f)||[]}else i=l.dataToPoint(o.getValues(U(l.dimensions,function(v){return o.mapDimension(v)}),a))||[];else if(s){var g=s.getBoundingRect().clone();g.applyTransform(s.transform),i=[g.x+g.width/2,g.y+g.height/2]}return{point:i,el:s}}var wb=ze();function Nk(n,e,t){var i=n.currTrigger,r=[n.x,n.y],o=n,a=n.dispatchAction||he(t.dispatchAction,t),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){Hu(r)&&(r=_b({seriesIndex:o.seriesIndex,dataIndex:o.dataIndex},e).point);var l=Hu(r),u=o.axesInfo,h=s.axesInfo,c=i==="leave"||Hu(r),p={},d={},f={list:[],map:{}},g={showPointer:Te(zk,d),showTooltip:Te(Bk,f)};A(s.coordSysMap,function(y,m){var x=l||y.containPoint(r);A(s.coordSysAxesInfo[m],function(_,w){var b=_.axis,S=function(T,C){for(var I=0;I<(T||[]).length;I++){var D=T[I];if(C.axis.dim===D.axisDim&&C.axis.model.componentIndex===D.axisIndex)return D}}(u,_);if(!c&&x&&(!u||S)){var M=S&&S.value;M!=null||l||(M=b.pointToData(r)),M!=null&&bb(_,M,g,!1,p)}})});var v={};return A(h,function(y,m){var x=y.linkGroup;x&&!d[m]&&A(x.axesInfo,function(_,w){var b=d[w];if(_!==y&&b){var S=b.value;x.mapper&&(S=y.axis.scale.parse(x.mapper(S,Sb(_),Sb(y)))),v[y.key]=S}})}),A(v,function(y,m){bb(h[m],y,g,!0,p)}),function(y,m,x){var _=x.axesInfo=[];A(m,function(w,b){var S=w.axisPointerModel.option,M=y[b];M?(!w.useHandle&&(S.status="show"),S.value=M.value,S.seriesDataIndices=(M.payloadBatch||[]).slice()):!w.useHandle&&(S.status="hide"),S.status==="show"&&_.push({axisDim:w.axis.dim,axisIndex:w.axis.model.componentIndex,value:S.value})})}(d,h,p),function(y,m,x,_){if(Hu(m)||!y.list.length)return void _({type:"hideTip"});var w=((y.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};_({type:"showTip",escapeConnect:!0,x:m[0],y:m[1],tooltipOption:x.tooltipOption,position:x.position,dataIndexInside:w.dataIndexInside,dataIndex:w.dataIndex,seriesIndex:w.seriesIndex,dataByCoordSys:y.list})}(f,r,n,a),function(y,m,x){var _=x.getZr(),w="axisPointerLastHighlights",b=wb(_)[w]||{},S=wb(_)[w]={};A(y,function(C,I){var D=C.axisPointerModel.option;D.status==="show"&&C.triggerEmphasis&&A(D.seriesDataIndices,function(L){var R=L.seriesIndex+" | "+L.dataIndex;S[R]=L})});var M=[],T=[];A(b,function(C,I){!S[I]&&T.push(C)}),A(S,function(C,I){!b[I]&&M.push(C)}),T.length&&x.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:T}),M.length&&x.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:M})}(h,0,t),p}}function bb(n,e,t,i,r){var o=n.axis;if(!o.scale.isBlank()&&o.containData(e))if(n.involveSeries){var a=function(u,h){var c=h.axis,p=c.dim,d=u,f=[],g=Number.MAX_VALUE,v=-1;return A(h.seriesModels,function(y,m){var x,_,w=y.getData().mapDimensionsAll(p);if(y.getAxisTooltipData){var b=y.getAxisTooltipData(w,u,c);_=b.dataIndices,x=b.nestestValue}else{if(!(_=y.getData().indicesOfNearest(w[0],u,c.type==="category"?.5:null)).length)return;x=y.getData().get(w[0],_[0])}if(x!=null&&isFinite(x)){var S=u-x,M=Math.abs(S);M<=g&&((M=0&&v<0)&&(g=M,v=S,d=x,f.length=0),A(_,function(T){f.push({seriesIndex:y.seriesIndex,dataIndexInside:T,dataIndex:y.getData().getRawIndex(T)})}))}}),{payloadBatch:f,snapToValue:d}}(e,n),s=a.payloadBatch,l=a.snapToValue;s[0]&&r.seriesIndex==null&&G(r,s[0]),!i&&n.snap&&o.containData(l)&&l!=null&&(e=l),t.showPointer(n,e,s),t.showTooltip(n,a,l)}else t.showPointer(n,e)}function zk(n,e,t,i){n[e.key]={value:t,payloadBatch:i}}function Bk(n,e,t,i){var r=t.payloadBatch,o=e.axis,a=o.model,s=e.axisPointerModel;if(e.triggerTooltip&&r.length){var l=e.coordSys.model,u=$a(l),h=n.map[u];h||(h=n.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},n.list.push(h)),h.dataByAxis.push({axisDim:o.dim,axisIndex:a.componentIndex,axisType:a.type,axisId:a.id,value:i,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:r.slice()})}}function Sb(n){var e=n.axis.model,t={},i=t.axisDim=n.axis.dim;return t.axisIndex=t[i+"AxisIndex"]=e.componentIndex,t.axisName=t[i+"AxisName"]=e.name,t.axisId=t[i+"AxisId"]=e.id,t}function Hu(n){return!n||n[0]==null||isNaN(n[0])||n[1]==null||isNaN(n[1])}function xf(n){Qa.registerAxisPointerClass("CartesianAxisPointer",kk),n.registerComponentModel(Lk),n.registerComponentView(Ek),n.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var t=e.axisPointer.link;t&&!W(t)&&(e.axisPointer.link=[t])}}),n.registerProcessor(n.PRIORITY.PROCESSOR.STATISTIC,function(e,t){e.getComponent("axisPointer").coordSysAxesInfo=zA(e,t)}),n.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},Nk)}var Vk=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.makeElOption=function(t,i,r,o,a){var s=r.axis;s.dim==="angle"&&(this.animationThreshold=Math.PI/18);var l=s.polar,u=l.getOtherAxis(s).getExtent(),h=s.dataToCoord(i),c=o.get("type");if(c&&c!=="none"){var p=hb(o),d=Fk[c](s,l,h,u);d.style=p,t.graphicKey=d.type,t.pointer=d}var f=function(g,v,y,m,x){var _=v.axis,w=_.dataToCoord(g),b=m.getAngleAxis().getExtent()[0];b=b/180*Math.PI;var S,M,T,C=m.getRadiusAxis().getExtent();if(_.dim==="radius"){var I=[1,0,0,1,0,0];Hi(I,I,b),Gi(I,I,[m.cx,m.cy]),S=Si([w,-x],I);var D=v.getModel("axisLabel").get("rotate")||0,L=Oi.innerTextLayout(b,D*Math.PI/180,-1);M=L.textAlign,T=L.textVerticalAlign}else{var R=C[1];S=m.coordToPoint([R+x,w]);var O=m.cx,E=m.cy;M=Math.abs(S[0]-O)/R<.3?"center":S[0]>O?"left":"right",T=Math.abs(S[1]-E)/R<.3?"middle":S[1]>E?"top":"bottom"}return{position:S,align:M,verticalAlign:T}}(i,r,0,l,o.get(["label","margin"]));cb(t,r,o,a,f)},e}(ub),Fk={line:function(n,e,t,i){return n.dim==="angle"?{type:"Line",shape:fb(e.coordToPoint([i[0],t]),e.coordToPoint([i[1],t]))}:{type:"Circle",shape:{cx:e.cx,cy:e.cy,r:t}}},shadow:function(n,e,t,i){var r=Math.max(1,n.getBandWidth()),o=Math.PI/180;return n.dim==="angle"?{type:"Sector",shape:gb(e.cx,e.cy,i[0],i[1],(-t-r/2)*o,(r/2-t)*o)}:{type:"Sector",shape:gb(e.cx,e.cy,t-r/2,t+r/2,0,2*Math.PI)}}};const Gk=Vk,Hk=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.findAxisModel=function(t){var i;return this.ecModel.eachComponent(t,function(r){r.getCoordSysModel()===this&&(i=r)},this),i},e.type="polar",e.dependencies=["radiusAxis","angleAxis"],e.defaultOption={z:0,center:["50%","50%"],radius:"80%"},e}(Se);var _f=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",nt).models[0]},e.type="polarAxis",e}(Se);ht(_f,ja);var Wk=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.type="angleAxis",e}(_f),Yk=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.type="radiusAxis",e}(_f),wf=function(n){function e(t,i){return n.call(this,"radius",t,i)||this}return V(e,n),e.prototype.pointToData=function(t,i){return this.polar.pointToData(t,i)[this.dim==="radius"?0:1]},e}(Fn);wf.prototype.dataToRadius=Fn.prototype.dataToCoord,wf.prototype.radiusToData=Fn.prototype.coordToData;const Uk=wf;var Xk=ze(),bf=function(n){function e(t,i){return n.call(this,"angle",t,i||[0,360])||this}return V(e,n),e.prototype.pointToData=function(t,i){return this.polar.pointToData(t,i)[this.dim==="radius"?0:1]},e.prototype.calculateCategoryInterval=function(){var t=this,i=t.getLabelModel(),r=t.scale,o=r.getExtent(),a=r.count();if(o[1]-o[0]<1)return 0;var s=o[0],l=t.dataToCoord(s+1)-t.dataToCoord(s),u=Math.abs(l),h=Ko(s==null?"":s+"",i.getFont(),"center","top"),c=Math.max(h.height,7)/u;isNaN(c)&&(c=1/0);var p=Math.max(0,Math.floor(c)),d=Xk(t.model),f=d.lastAutoInterval,g=d.lastTickCount;return f!=null&&g!=null&&Math.abs(f-p)<=1&&Math.abs(g-a)<=1&&f>p?p=f:(d.lastTickCount=a,d.lastAutoInterval=p),p},e}(Fn);bf.prototype.dataToAngle=Fn.prototype.dataToCoord,bf.prototype.angleToData=Fn.prototype.coordToData;const jk=bf;var Mb=["radius","angle"],Zk=function(){function n(e){this.dimensions=Mb,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new Uk,this._angleAxis=new jk,this.axisPointerEnabled=!0,this.name=e||"",this._radiusAxis.polar=this._angleAxis.polar=this}return n.prototype.containPoint=function(e){var t=this.pointToCoord(e);return this._radiusAxis.contain(t[0])&&this._angleAxis.contain(t[1])},n.prototype.containData=function(e){return this._radiusAxis.containData(e[0])&&this._angleAxis.containData(e[1])},n.prototype.getAxis=function(e){return this["_"+e+"Axis"]},n.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},n.prototype.getAxesByScale=function(e){var t=[],i=this._angleAxis,r=this._radiusAxis;return i.scale.type===e&&t.push(i),r.scale.type===e&&t.push(r),t},n.prototype.getAngleAxis=function(){return this._angleAxis},n.prototype.getRadiusAxis=function(){return this._radiusAxis},n.prototype.getOtherAxis=function(e){var t=this._angleAxis;return e===t?this._radiusAxis:t},n.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},n.prototype.getTooltipAxes=function(e){var t=e!=null&&e!=="auto"?this.getAxis(e):this.getBaseAxis();return{baseAxes:[t],otherAxes:[this.getOtherAxis(t)]}},n.prototype.dataToPoint=function(e,t){return this.coordToPoint([this._radiusAxis.dataToRadius(e[0],t),this._angleAxis.dataToAngle(e[1],t)])},n.prototype.pointToData=function(e,t){var i=this.pointToCoord(e);return[this._radiusAxis.radiusToData(i[0],t),this._angleAxis.angleToData(i[1],t)]},n.prototype.pointToCoord=function(e){var t=e[0]-this.cx,i=e[1]-this.cy,r=this.getAngleAxis(),o=r.getExtent(),a=Math.min(o[0],o[1]),s=Math.max(o[0],o[1]);r.inverse?a=s-360:s=a+360;var l=Math.sqrt(t*t+i*i);t/=l,i/=l;for(var u=Math.atan2(-i,t)/Math.PI*180,h=us;)u+=360*h;return[l,u]},n.prototype.coordToPoint=function(e){var t=e[0],i=e[1]/180*Math.PI;return[Math.cos(i)*t+this.cx,-Math.sin(i)*t+this.cy]},n.prototype.getArea=function(){var e=this.getAngleAxis(),t=this.getRadiusAxis().getExtent().slice();t[0]>t[1]&&t.reverse();var i=e.getExtent(),r=Math.PI/180;return{cx:this.cx,cy:this.cy,r0:t[0],r:t[1],startAngle:-i[0]*r,endAngle:-i[1]*r,clockwise:e.inverse,contain:function(o,a){var s=o-this.cx,l=a-this.cy,u=s*s+l*l-1e-4,h=this.r,c=this.r0;return u<=h*h&&u>=c*c}}},n.prototype.convertToPixel=function(e,t,i){return Tb(t)===this?this.dataToPoint(i):null},n.prototype.convertFromPixel=function(e,t,i){return Tb(t)===this?this.pointToData(i):null},n}();function Tb(n){var e=n.seriesModel,t=n.polarModel;return t&&t.coordinateSystem||e&&e.coordinateSystem}const qk=Zk;function Kk(n,e){var t=this,i=t.getAngleAxis(),r=t.getRadiusAxis();if(i.scale.setExtent(1/0,-1/0),r.scale.setExtent(1/0,-1/0),n.eachSeries(function(s){if(s.coordinateSystem===t){var l=s.getData();A(gu(l,"radius"),function(u){r.scale.unionExtentFromData(l,u)}),A(gu(l,"angle"),function(u){i.scale.unionExtentFromData(l,u)})}}),wo(i.scale,i.model),wo(r.scale,r.model),i.type==="category"&&!i.onBand){var o=i.getExtent(),a=360/i.scale.count();i.inverse?o[1]+=a:o[1]-=a,i.setExtent(o[0],o[1])}}function Cb(n,e){var t;if(n.type=e.get("type"),n.scale=fu(e),n.onBand=e.get("boundaryGap")&&n.type==="category",n.inverse=e.get("inverse"),function(o){return o.mainType==="angleAxis"}(e)){n.inverse=n.inverse!==e.get("clockwise");var i=e.get("startAngle"),r=(t=e.get("endAngle"))!==null&&t!==void 0?t:i+(n.inverse?-360:360);n.setExtent(i,r)}e.axis=n,n.model=e}var Jk={dimensions:Mb,create:function(n,e){var t=[];return n.eachComponent("polar",function(i,r){var o=new qk(r+"");o.update=Kk;var a=o.getRadiusAxis(),s=o.getAngleAxis(),l=i.findAxisModel("radiusAxis"),u=i.findAxisModel("angleAxis");Cb(a,l),Cb(s,u),function(h,c,p){var d=c.get("center"),f=p.getWidth(),g=p.getHeight();h.cx=te(d[0],f),h.cy=te(d[1],g);var v=h.getRadiusAxis(),y=Math.min(f,g)/2,m=c.get("radius");m==null?m=[0,"100%"]:W(m)||(m=[0,m]);var x=[te(m[0],y),te(m[1],y)];v.inverse?v.setExtent(x[1],x[0]):v.setExtent(x[0],x[1])}(o,i,e),t.push(o),i.coordinateSystem=o,o.model=i}),n.eachSeries(function(i){if(i.get("coordinateSystem")==="polar"){var r=i.getReferringComponents("polar",nt).models[0];if(!r)throw new Error('Polar "'+Ht(i.get("polarIndex"),i.get("polarId"),0)+'" not found');i.coordinateSystem=r.coordinateSystem}}),t}};const $k=Jk;var Qk=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function Wu(n,e,t){e[1]>e[0]&&(e=e.slice().reverse());var i=n.coordToPoint([e[0],t]),r=n.coordToPoint([e[1],t]);return{x1:i[0],y1:i[1],x2:r[0],y2:r[1]}}function Yu(n){return n.getRadiusAxis().inverse?0:1}function Ib(n){var e=n[0],t=n[n.length-1];e&&t&&Math.abs(Math.abs(e.coord-t.coord)-360)<1e-4&&n.pop()}var eL=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.axisPointerClass="PolarAxisPointer",t}return V(e,n),e.prototype.render=function(t,i){if(this.group.removeAll(),t.get("show")){var r=t.axis,o=r.polar,a=o.getRadiusAxis().getExtent(),s=r.getTicksCoords(),l=r.getMinorTicksCoords(),u=U(r.getViewLabels(),function(h){h=ie(h);var c=r.scale,p=c.type==="ordinal"?c.getRawOrdinalNumber(h.tickValue):h.tickValue;return h.coord=r.dataToCoord(p),h});Ib(u),Ib(s),A(Qk,function(h){!t.get([h,"show"])||r.scale.isBlank()&&h!=="axisLine"||tL[h](this.group,t,o,s,l,a,u)},this)}},e.type="angleAxis",e}(Qa),tL={axisLine:function(n,e,t,i,r,o){var a,s=e.getModel(["axisLine","lineStyle"]),l=t.getAngleAxis(),u=Math.PI/180,h=l.getExtent(),c=Yu(t),p=c?0:1,d=Math.abs(h[1]-h[0])===360?"Circle":"Arc";(a=o[p]===0?new no[d]({shape:{cx:t.cx,cy:t.cy,r:o[c],startAngle:-h[0]*u,endAngle:-h[1]*u,clockwise:l.inverse},style:s.getLineStyle(),z2:1,silent:!0}):new ga({shape:{cx:t.cx,cy:t.cy,r:o[c],r0:o[p]},style:s.getLineStyle(),z2:1,silent:!0})).style.fill=null,n.add(a)},axisTick:function(n,e,t,i,r,o){var a=e.getModel("axisTick"),s=(a.get("inside")?-1:1)*a.get("length"),l=o[Yu(t)],u=U(i,function(h){return new _t({shape:Wu(t,[l,l+s],h.coord)})});n.add(nn(u,{style:ae(a.getModel("lineStyle").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})}))},minorTick:function(n,e,t,i,r,o){if(r.length){for(var a=e.getModel("axisTick"),s=e.getModel("minorTick"),l=(a.get("inside")?-1:1)*s.get("length"),u=o[Yu(t)],h=[],c=0;cy?"left":"right",_=Math.abs(v[1]-m)/g<.3?"middle":v[1]>m?"top":"bottom";if(s&&s[f]){var w=s[f];Q(w)&&w.textStyle&&(d=new He(w.textStyle,l,l.ecModel))}var b=new De({silent:Oi.isLabelSilent(e),style:rt(d,{x:v[0],y:v[1],fill:d.getTextColor()||e.get(["axisLine","lineStyle","color"]),text:c.formattedLabel,align:x,verticalAlign:_})});if(n.add(b),h){var S=Oi.makeAxisEventDataBase(e);S.targetType="axisLabel",S.value=c.rawLabel,ye(b).eventData=S}},this)},splitLine:function(n,e,t,i,r,o){var a=e.getModel("splitLine").getModel("lineStyle"),s=a.get("color"),l=0;s=s instanceof Array?s:[s];for(var u=[],h=0;h=0?"p":"n",L=S;w&&(i[h][I]||(i[h][I]={p:S,n:S}),L=i[h][I][D]);var R=void 0,O=void 0,E=void 0,k=void 0;if(f.dim==="radius"){var P=f.dataToCoord(C)-S,N=l.dataToCoord(I);Math.abs(P)=k})}}})}var uL={startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:0}},hL={splitNumber:5},cL=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.type="polar",e}(Ze),kb=["x","y","radius","angle","single"],pL=["cartesian2d","polar","singleAxis"];function Co(n){return le(n),n+"Axis"}function dL(n,e){var t,i=ee(),r=[],o=ee();n.eachComponent({mainType:"dataZoom",query:e},function(l){o.get(l.uid)||s(l)});do t=!1,n.eachComponent("dataZoom",a);while(t);function a(l){!o.get(l.uid)&&function(u){var h=!1;return u.eachTargetAxis(function(c,p){var d=i.get(c);d&&d[p]&&(h=!0)}),h}(l)&&(s(l),t=!0)}function s(l){o.set(l.uid,!0),r.push(l),l.eachTargetAxis(function(u,h){(i.get(u)||i.set(u,[]))[h]=!0})}return r}var Sf=function(){function n(){this.indexList=[],this.indexMap=[]}return n.prototype.add=function(e){this.indexMap[e]||(this.indexList.push(e),this.indexMap[e]=!0)},n}(),fL=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t._autoThrottle=!0,t._noTarget=!0,t._rangePropMode=["percent","percent"],t}return V(e,n),e.prototype.init=function(t,i,r){var o=Lb(t);this.settledOption=o,this.mergeDefaultAndTheme(t,r),this._doInit(o)},e.prototype.mergeOption=function(t){var i=Lb(t);pe(this.option,t,!0),pe(this.settledOption,i,!0),this._doInit(i)},e.prototype._doInit=function(t){var i=this.option;this._setDefaultThrottle(t),this._updateRangeUse(t);var r=this.settledOption;A([["start","startValue"],["end","endValue"]],function(o,a){this._rangePropMode[a]==="value"&&(i[o[0]]=r[o[0]]=null)},this),this._resetTarget()},e.prototype._resetTarget=function(){var t=this.get("orient",!0),i=this._targetAxisInfoMap=ee();this._fillSpecifiedTargetAxis(i)?this._orient=t||this._makeAutoOrientByTargetAxis():(this._orient=t||"horizontal",this._fillAutoTargetAxisByOrient(i,this._orient)),this._noTarget=!0,i.each(function(r){r.indexList.length&&(this._noTarget=!1)},this)},e.prototype._fillSpecifiedTargetAxis=function(t){var i=!1;return A(kb,function(r){var o=this.getReferringComponents(Co(r),eT);if(o.specified){i=!0;var a=new Sf;A(o.models,function(s){a.add(s.componentIndex)}),t.set(r,a)}},this),i},e.prototype._fillAutoTargetAxisByOrient=function(t,i){var r=this.ecModel,o=!0;if(o){var a=i==="vertical"?"y":"x";s(r.findComponents({mainType:a+"Axis"}),a)}o&&s(r.findComponents({mainType:"singleAxis",filter:function(l){return l.get("orient",!0)===i}}),"single");function s(l,u){var h=l[0];if(h){var c=new Sf;if(c.add(h.componentIndex),t.set(u,c),o=!1,u==="x"||u==="y"){var p=h.getReferringComponents("grid",nt).models[0];p&&A(l,function(d){h.componentIndex!==d.componentIndex&&p===d.getReferringComponents("grid",nt).models[0]&&c.add(d.componentIndex)})}}}o&&A(kb,function(l){if(o){var u=r.findComponents({mainType:Co(l),filter:function(c){return c.get("type",!0)==="category"}});if(u[0]){var h=new Sf;h.add(u[0].componentIndex),t.set(l,h),o=!1}}},this)},e.prototype._makeAutoOrientByTargetAxis=function(){var t;return this.eachTargetAxis(function(i){!t&&(t=i)},this),t==="y"?"vertical":"horizontal"},e.prototype._setDefaultThrottle=function(t){if(t.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var i=this.ecModel.option;this.option.throttle=i.animation&&i.animationDurationUpdate>0?100:20}},e.prototype._updateRangeUse=function(t){var i=this._rangePropMode,r=this.get("rangeMode");A([["start","startValue"],["end","endValue"]],function(o,a){var s=t[o[0]]!=null,l=t[o[1]]!=null;s&&!l?i[a]="percent":!s&&l?i[a]="value":r?i[a]=r[a]:s&&(i[a]="percent")})},e.prototype.noTarget=function(){return this._noTarget},e.prototype.getFirstTargetAxisModel=function(){var t;return this.eachTargetAxis(function(i,r){t==null&&(t=this.ecModel.getComponent(Co(i),r))},this),t},e.prototype.eachTargetAxis=function(t,i){this._targetAxisInfoMap.each(function(r,o){A(r.indexList,function(a){t.call(i,o,a)})})},e.prototype.getAxisProxy=function(t,i){var r=this.getAxisModel(t,i);if(r)return r.__dzAxisProxy},e.prototype.getAxisModel=function(t,i){le(t&&i!=null);var r=this._targetAxisInfoMap.get(t);if(r&&r.indexMap[i])return this.ecModel.getComponent(Co(t),i)},e.prototype.setRawRange=function(t){var i=this.option,r=this.settledOption;A([["start","startValue"],["end","endValue"]],function(o){t[o[0]]==null&&t[o[1]]==null||(i[o[0]]=r[o[0]]=t[o[0]],i[o[1]]=r[o[1]]=t[o[1]])},this),this._updateRangeUse(t)},e.prototype.setCalculatedRange=function(t){var i=this.option;A(["start","startValue","end","endValue"],function(r){i[r]=t[r]})},e.prototype.getPercentRange=function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},e.prototype.getValueRange=function(t,i){if(t!=null||i!=null)return this.getAxisProxy(t,i).getDataValueWindow();var r=this.findRepresentativeAxisProxy();return r?r.getDataValueWindow():void 0},e.prototype.findRepresentativeAxisProxy=function(t){if(t)return t.__dzAxisProxy;for(var i,r=this._targetAxisInfoMap.keys(),o=0;o=0}(t)){var i=Co(this._dimName),r=t.getReferringComponents(i,nt).models[0];r&&this._axisIndex===r.componentIndex&&e.push(t)}},this),e},n.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},n.prototype.getMinMaxSpan=function(){return ie(this._minMaxSpan)},n.prototype.calculateDataWindow=function(e){var t,i=this._dataExtent,r=this.getAxisModel().axis.scale,o=this._dataZoomModel.getRangePropMode(),a=[0,100],s=[],l=[];Io(["start","end"],function(c,p){var d=e[c],f=e[c+"Value"];o[p]==="percent"?(d==null&&(d=a[p]),f=r.parse(Ye(d,a,i))):(t=!0,d=Ye(f=f==null?i[p]:r.parse(f),i,a)),l[p]=f==null||isNaN(f)?i[p]:f,s[p]=d==null||isNaN(d)?a[p]:d}),Pb(l),Pb(s);var u=this._minMaxSpan;function h(c,p,d,f,g){var v=g?"Span":"ValueSpan";Vu(0,c,d,"all",u["min"+v],u["max"+v]);for(var y=0;y<2;y++)p[y]=Ye(c[y],d,f,!0),g&&(p[y]=r.parse(p[y]))}return t?h(l,s,i,a,!1):h(s,l,a,i,!0),{valueWindow:l,percentWindow:s}},n.prototype.reset=function(e){if(e===this._dataZoomModel){var t=this.getTargetSeriesModels();this._dataExtent=function(r,o,a){var s=[1/0,-1/0];Io(a,function(h){(function(c,p,d){p&&A(gu(p,d),function(f){var g=p.getApproximateExtent(f);g[0]c[1]&&(c[1]=g[1])})})(s,h.getData(),o)});var l=r.getAxisModel(),u=i_(l.axis.scale,l,s).calculate();return[u.min,u.max]}(this,this._dimName,t),this._updateMinMaxSpan();var i=this.calculateDataWindow(e.settledOption);this._valueWindow=i.valueWindow,this._percentWindow=i.percentWindow,this._setAxisModel()}},n.prototype.filterData=function(e,t){if(e===this._dataZoomModel){var i=this._dimName,r=this.getTargetSeriesModels(),o=e.get("filterMode"),a=this._valueWindow;o!=="none"&&Io(r,function(s){var l=s.getData(),u=l.mapDimensionsAll(i);if(u.length){if(o==="weakFilter"){var h=l.getStore(),c=U(u,function(p){return l.getDimensionIndex(p)},l);l.filterSelf(function(p){for(var d,f,g,v=0;va[1];if(m&&!x&&!_)return!0;m&&(g=!0),x&&(d=!0),_&&(f=!0)}return g&&d&&f})}else Io(u,function(p){if(o==="empty")s.setData(l=l.map(p,function(f){return function(g){return g>=a[0]&&g<=a[1]}(f)?f:NaN}));else{var d={};d[p]=a,l.selectRange(d)}});Io(u,function(p){l.setApproximateExtent(a,p)})}})}},n.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,i=this._dataExtent;Io(["min","max"],function(r){var o=t.get(r+"Span"),a=t.get(r+"ValueSpan");a!=null&&(a=this.getAxisModel().axis.scale.parse(a)),a!=null?o=Ye(i[0]+a,i,[0,100],!0):o!=null&&(a=Ye(o,[0,100],i,!0)-i[0]),e[r+"Span"]=o,e[r+"ValueSpan"]=a},this)},n.prototype._setAxisModel=function(){var e=this.getAxisModel(),t=this._percentWindow,i=this._valueWindow;if(t){var r=$h(i,[0,500]);r=Math.min(r,20);var o=e.axis.scale.rawExtentInfo;t[0]!==0&&o.setDeterminedMinMax("min",+i[0].toFixed(r)),t[1]!==100&&o.setDeterminedMinMax("max",+i[1].toFixed(r)),o.freeze()}},n}();const mL=yL,xL={getTargetSeries:function(n){function e(r){n.eachComponent("dataZoom",function(o){o.eachTargetAxis(function(a,s){var l=n.getComponent(Co(a),s);r(a,s,l,o)})})}e(function(r,o,a,s){a.__dzAxisProxy=null});var t=[];e(function(r,o,a,s){a.__dzAxisProxy||(a.__dzAxisProxy=new mL(r,o,s,n),t.push(a.__dzAxisProxy))});var i=ee();return A(t,function(r){A(r.getTargetSeriesModels(),function(o){i.set(o.uid,o)})}),i},overallReset:function(n,e){n.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(i,r){t.getAxisProxy(i,r).reset(t)}),t.eachTargetAxis(function(i,r){t.getAxisProxy(i,r).filterData(t,e)})}),n.eachComponent("dataZoom",function(t){var i=t.findRepresentativeAxisProxy();if(i){var r=i.getDataPercentWindow(),o=i.getDataValueWindow();t.setCalculatedRange({start:r[0],end:r[1],startValue:o[0],endValue:o[1]})}})}};var Ob=!1;function _L(n){Ob||(Ob=!0,n.registerProcessor(n.PRIORITY.PROCESSOR.FILTER,xL),function(e){e.registerAction("dataZoom",function(t,i){A(dL(i,t),function(r){r.setRawRange({start:t.start,end:t.end,startValue:t.startValue,endValue:t.endValue})})})}(n),n.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}function wL(n){n.registerComponentModel(gL),n.registerComponentView(vL),_L(n)}var Tn=function(){},Rb={};function as(n,e){Rb[n]=e}function Eb(n){return Rb[n]}const bL=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.optionUpdated=function(){n.prototype.optionUpdated.apply(this,arguments);var t=this.ecModel;A(this.option.feature,function(i,r){var o=Eb(r);o&&(o.getDefaultOption&&(o.defaultOption=o.getDefaultOption(t)),pe(i,o.defaultOption))})},e.type="toolbox",e.layoutMode={type:"box",ignoreSize:!0},e.defaultOption={show:!0,z:6,orient:"horizontal",left:"right",top:"top",backgroundColor:"transparent",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemSize:15,itemGap:8,showTitle:!0,iconStyle:{borderColor:"#666",color:"none"},emphasis:{iconStyle:{borderColor:"#3E98C5"}},tooltip:{show:!1,position:"bottom"}},e}(Se);function Nb(n,e){var t=so(e.get("padding")),i=e.getItemStyle(["color","opacity"]);return i.fill=e.get("backgroundColor"),n=new Re({shape:{x:n.x-t[3],y:n.y-t[0],width:n.width+t[1]+t[3],height:n.height+t[0]+t[2],r:e.get("borderRadius")},style:i,silent:!0,z2:-1})}var SL=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.render=function(t,i,r,o){var a=this.group;if(a.removeAll(),t.get("show")){var s=+t.get("itemSize"),l=t.get("orient")==="vertical",u=t.get("feature")||{},h=this._features||(this._features={}),c=[];A(u,function(d,f){c.push(f)}),new od(this._featureNames||[],c).add(p).update(p).remove(Te(p,null)).execute(),this._featureNames=c,function(d,f,g){var v=f.getBoxLayoutParams(),y=f.get("padding"),m={width:g.getWidth(),height:g.getHeight()},x=Vt(v,m,y);vr(f.get("orient"),d,f.get("itemGap"),x.width,x.height),xm(d,v,m,y)}(a,t,r),a.add(Nb(a.getBoundingRect(),t)),l||a.eachChild(function(d){var f=d.__title,g=d.ensureState("emphasis"),v=g.textConfig||(g.textConfig={}),y=d.getTextContent(),m=y&&y.ensureState("emphasis");if(m&&!re(m)&&f){var x=m.style||(m.style={}),_=Ko(f,De.makeFont(x)),w=d.x+a.x,b=!1;d.y+a.y+s+_.height>r.getHeight()&&(v.position="top",b=!0);var S=b?-5-_.height:s+10;w+_.width/2>r.getWidth()?(v.position=["100%",S],x.align="right"):w-_.width/2<0&&(v.position=[0,S],x.align="left")}})}function p(d,f){var g,v=c[d],y=c[f],m=u[v],x=new He(m,t,t.ecModel);if(o&&o.newTitle!=null&&o.featureName===v&&(m.title=o.newTitle),v&&!y){if(function(b){return b.indexOf("my")===0}(v))g={onclick:x.option.onclick,featureName:v};else{var _=Eb(v);if(!_)return;g=new _}h[v]=g}else if(!(g=h[y]))return;g.uid=ro("toolbox-feature"),g.model=x,g.ecModel=i,g.api=r;var w=g instanceof Tn;v||!y?!x.get("show")||w&&g.unusable?w&&g.remove&&g.remove(i,r):(function(b,S,M){var T,C,I=b.getModel("iconStyle"),D=b.getModel(["emphasis","iconStyle"]),L=S instanceof Tn&&S.getIcons?S.getIcons():b.get("icon"),R=b.get("title")||{};j(L)?(T={})[M]=L:T=L,j(R)?(C={})[M]=R:C=R;var O=b.iconPaths={};A(T,function(E,k){var P=_a(E,{},{x:-s/2,y:-s/2,width:s,height:s});P.setStyle(I.getItemStyle()),P.ensureState("emphasis").style=D.getItemStyle();var N=new De({style:{text:C[k],align:D.get("textAlign"),borderRadius:D.get("textBorderRadius"),padding:D.get("textPadding"),fill:null,font:$y({fontStyle:D.get("textFontStyle"),fontFamily:D.get("textFontFamily"),fontSize:D.get("textFontSize"),fontWeight:D.get("textFontWeight")},i)},ignore:!0});P.setTextContent(N),wa({el:P,componentModel:t,itemName:k,formatterParamsExtra:{title:C[k]}}),P.__title=C[k],P.on("mouseover",function(){var B=D.getItemStyle(),z=l?t.get("right")==null&&t.get("left")!=="right"?"right":"left":t.get("bottom")==null&&t.get("top")!=="bottom"?"bottom":"top";N.setStyle({fill:D.get("textFill")||B.fill||B.stroke||"#000",backgroundColor:D.get("textBackgroundColor")}),P.setTextConfig({position:D.get("textPosition")||z}),N.ignore=!t.get("showTitle"),r.enterEmphasis(this)}).on("mouseout",function(){b.get(["iconStatus",k])!=="emphasis"&&r.leaveEmphasis(this),N.hide()}),(b.get(["iconStatus",k])==="emphasis"?Kr:Jr)(P),a.add(P),P.on("click",he(S.onclick,S,i,r,k)),O[k]=P})}(x,g,v),x.setIconStatus=function(b,S){var M=this.option,T=this.iconPaths;M.iconStatus=M.iconStatus||{},M.iconStatus[b]=S,T[b]&&(S==="emphasis"?Kr:Jr)(T[b])},g instanceof Tn&&g.render&&g.render(x,i,r,o)):w&&g.dispose&&g.dispose(i,r)}},e.prototype.updateView=function(t,i,r,o){A(this._features,function(a){a instanceof Tn&&a.updateView&&a.updateView(a.model,i,r,o)})},e.prototype.remove=function(t,i){A(this._features,function(r){r instanceof Tn&&r.remove&&r.remove(t,i)}),this.group.removeAll()},e.prototype.dispose=function(t,i){A(this._features,function(r){r instanceof Tn&&r.dispose&&r.dispose(t,i)})},e.type="toolbox",e}(Ze);const ML=SL,TL=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.onclick=function(t,i){var r=this.model,o=r.get("name")||t.get("title.0.text")||"echarts",a=i.getZr().painter.getType()==="svg",s=a?"svg":r.get("type",!0)||"png",l=i.getConnectedDataURL({type:s,backgroundColor:r.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",connectedBackgroundColor:r.get("connectedBackgroundColor"),excludeComponents:r.get("excludeComponents"),pixelRatio:r.get("pixelRatio")}),u=_e.browser;if(re(MouseEvent)&&(u.newEdge||!u.ie&&!u.edge)){var h=document.createElement("a");h.download=o+"."+s,h.target="_blank",h.href=l;var c=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});h.dispatchEvent(c)}else if(window.navigator.msSaveOrOpenBlob||a){var p=l.split(","),d=p[0].indexOf("base64")>-1,f=a?decodeURIComponent(p[1]):p[1];d&&(f=window.atob(f));var g=o+"."+s;if(window.navigator.msSaveOrOpenBlob){for(var v=f.length,y=new Uint8Array(v);v--;)y[v]=f.charCodeAt(v);var m=new Blob([y]);window.navigator.msSaveOrOpenBlob(m,g)}else{var x=document.createElement("iframe");document.body.appendChild(x);var _=x.contentWindow,w=_.document;w.open("image/svg+xml","replace"),w.write(f),w.close(),_.focus(),w.execCommand("SaveAs",!0,g),document.body.removeChild(x)}}else{var b=r.get("lang"),S='',M=window.open();M.document.write(S),M.document.title=o}},e.getDefaultOption=function(t){return{show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:t.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:"#fff",name:"",excludeComponents:["toolbox"],lang:t.getLocaleModel().get(["toolbox","saveAsImage","lang"])}},e}(Tn);var zb="__ec_magicType_stack__",CL=[["line","bar"],["stack"]],IL=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.getIcons=function(){var t=this.model,i=t.get("icon"),r={};return A(t.get("type"),function(o){i[o]&&(r[o]=i[o])}),r},e.getDefaultOption=function(t){return{show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z"},title:t.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}}},e.prototype.onclick=function(t,i,r){var o=this.model,a=o.get(["seriesIndex",r]);if(Bb[r]){var s,l={series:[]};A(CL,function(h){Me(h,r)>=0&&A(h,function(c){o.setIconStatus(c,"normal")})}),o.setIconStatus(r,"emphasis"),t.eachComponent({mainType:"series",query:a==null?null:{seriesIndex:a}},function(h){var c=h.subType,p=h.id,d=Bb[r](c,p,h,o);d&&(ae(d,h.option),l.series.push(d));var f=h.coordinateSystem;if(f&&f.type==="cartesian2d"&&(r==="line"||r==="bar")){var g=f.getAxesByScale("ordinal")[0];if(g){var v=g.dim+"Axis",y=h.getReferringComponents(v,nt).models[0].componentIndex;l[v]=l[v]||[];for(var m=0;m<=y;m++)l[v][y]=l[v][y]||{};l[v][y].boundaryGap=r==="bar"}}});var u=r;r==="stack"&&(s=pe({stack:o.option.title.tiled,tiled:o.option.title.stack},o.option.title),o.get(["iconStatus",r])!=="emphasis"&&(u="tiled")),i.dispatchAction({type:"changeMagicType",currentType:u,newOption:l,newTitle:s,featureName:"magicType"})}},e}(Tn),Bb={line:function(n,e,t,i){if(n==="bar")return pe({id:e,type:"line",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},i.get(["option","line"])||{},!0)},bar:function(n,e,t,i){if(n==="line")return pe({id:e,type:"bar",data:t.get("data"),stack:t.get("stack"),markPoint:t.get("markPoint"),markLine:t.get("markLine")},i.get(["option","bar"])||{},!0)},stack:function(n,e,t,i){var r=t.get("stack")===zb;if(n==="line"||n==="bar")return i.setIconStatus("stack",r?"normal":"emphasis"),pe({id:e,stack:r?"":zb},i.get(["option","stack"])||{},!0)}};wn({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(n,e){e.mergeOption(n.newOption)});const AL=IL;var Uu=new Array(60).join("-"),Ao=" ";function Xu(n){return n.replace(/^\s\s*/,"").replace(/\s\s*$/,"")}var Mf=new RegExp("["+Ao+"]+","g");function DL(n,e){var t=n.split(new RegExp(` *`+Uu+` *`,"g")),i={series:[]};return A(t,function(r,o){if(function(u){if(u.slice(0,u.indexOf(` `)).indexOf(Ao)>=0)return!0}(r)){var a=function(u){for(var h=u.split(/\n+/g),c=[],p=U(Xu(h.shift()).split(Mf),function(v){return{name:v,data:[]}}),d=0;d=0)&&a(o,r._targetInfoList)})}return n.prototype.setOutputRanges=function(e,t){return this.matchOutputRanges(e,t,function(i,r,o){if((i.coordRanges||(i.coordRanges=[])).push(r),!i.coordRange){i.coordRange=r;var a=If[i.brushType](0,o,r);i.__rangeOffset={offset:Ub[i.brushType](a.values,i.range,[1,1]),xyMinMax:a.xyMinMax}}}),e},n.prototype.matchOutputRanges=function(e,t,i){A(e,function(r){var o=this.findTargetInfo(r,t);o&&o!==!0&&A(o.coordSyses,function(a){var s=If[r.brushType](1,a,r.range,!0);i(r,s.values,a,t)})},this)},n.prototype.setInputRanges=function(e,t){A(e,function(i){var r,o,a,s,l,u=this.findTargetInfo(i,t);if(le(!u||u===!0||i.coordRange,"coordRange must be specified when coord index specified."),le(!u||u!==!0||i.range,"range must be specified in global brush."),i.range=i.range||[],u&&u!==!0){i.panelId=u.panelId;var h=If[i.brushType](0,u.coordSys,i.coordRange),c=i.__rangeOffset;i.range=c?Ub[i.brushType](h.values,c.offset,(r=h.xyMinMax,o=c.xyMinMax,a=jb(r),s=jb(o),l=[a[0]/s[0],a[1]/s[1]],isNaN(l[0])&&(l[0]=1),isNaN(l[1])&&(l[1]=1),l)):h.values}},this)},n.prototype.makePanelOpts=function(e,t){return U(this._targetInfoList,function(i){var r=i.getPanelRect();return{panelId:i.panelId,defaultBrushType:t?t(i):null,clipPath:Hw(r),isTargetByCursor:Yw(r,e,i.coordSysModel),getLinearBrushOtherExtent:Ww(r)}})},n.prototype.controlSeries=function(e,t,i){var r=this.findTargetInfo(e,i);return r===!0||r&&Me(r.coordSyses,t.coordinateSystem)>=0},n.prototype.findTargetInfo=function(e,t){for(var i=this._targetInfoList,r=Gb(t,e),o=0;on[1]&&n.reverse(),n}function Gb(n,e){return oa(n,e,{includeMainTypes:EL})}var zL={grid:function(n,e){var t=n.xAxisModels,i=n.yAxisModels,r=n.gridModels,o=ee(),a={},s={};(t||i||r)&&(A(t,function(l){var u=l.axis.grid.model;o.set(u.id,u),a[u.id]=!0}),A(i,function(l){var u=l.axis.grid.model;o.set(u.id,u),s[u.id]=!0}),A(r,function(l){o.set(l.id,l),a[l.id]=!0,s[l.id]=!0}),o.each(function(l){var u=l.coordinateSystem,h=[];A(u.getCartesians(),function(c,p){(Me(t,c.getAxis("x").model)>=0||Me(i,c.getAxis("y").model)>=0)&&h.push(c)}),e.push({panelId:"grid--"+l.id,gridModel:l,coordSysModel:l,coordSys:h[0],coordSyses:h,getPanelRect:Wb.grid,xAxisDeclared:a[l.id],yAxisDeclared:s[l.id]})}))},geo:function(n,e){A(n.geoModels,function(t){var i=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:i,coordSyses:[i],getPanelRect:Wb.geo})})}},Hb=[function(n,e){var t=n.xAxisModel,i=n.yAxisModel,r=n.gridModel;return!r&&t&&(r=t.axis.grid.model),!r&&i&&(r=i.axis.grid.model),r&&r===e.gridModel},function(n,e){var t=n.geoModel;return t&&t===e.geoModel}],Wb={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var n=this.coordSys,e=n.getBoundingRect().clone();return e.applyTransform(dr(n)),e}},If={lineX:Te(Yb,0),lineY:Te(Yb,1),rect:function(n,e,t,i){var r=n?e.pointToData([t[0][0],t[1][0]],i):e.dataToPoint([t[0][0],t[1][0]],i),o=n?e.pointToData([t[0][1],t[1][1]],i):e.dataToPoint([t[0][1],t[1][1]],i),a=[Cf([r[0],o[0]]),Cf([r[1],o[1]])];return{values:a,xyMinMax:a}},polygon:function(n,e,t,i){var r=[[1/0,-1/0],[1/0,-1/0]];return{values:U(t,function(o){var a=n?e.pointToData(o,i):e.dataToPoint(o,i);return r[0][0]=Math.min(r[0][0],a[0]),r[1][0]=Math.min(r[1][0],a[1]),r[0][1]=Math.max(r[0][1],a[0]),r[1][1]=Math.max(r[1][1],a[1]),a}),xyMinMax:r}}};function Yb(n,e,t,i){le(t.type==="cartesian2d","lineX/lineY brush is available only in cartesian2d.");var r=t.getAxis(["x","y"][n]),o=Cf(U([0,1],function(s){return e?r.coordToData(r.toLocalCoord(i[s]),!0):r.toGlobalCoord(r.dataToCoord(i[s]))})),a=[];return a[n]=o,a[1-n]=[NaN,NaN],{values:o,xyMinMax:a}}var Ub={lineX:Te(Xb,0),lineY:Te(Xb,1),rect:function(n,e,t){return[[n[0][0]-t[0]*e[0][0],n[0][1]-t[0]*e[0][1]],[n[1][0]-t[1]*e[1][0],n[1][1]-t[1]*e[1][1]]]},polygon:function(n,e,t){return U(n,function(i,r){return[i[0]-t[0]*e[r][0],i[1]-t[1]*e[r][1]]})}};function Xb(n,e,t,i){return[e[0]-i[n]*t[0],e[1]-i[n]*t[1]]}function jb(n){return n?[n[0][1]-n[0][0],n[1][1]-n[1][0]]:[NaN,NaN]}const Zb=NL;var Af,Df,kf=A,BL=dv+"toolbox-dataZoom_",VL=function(n){function e(){return n!==null&&n.apply(this,arguments)||this}return V(e,n),e.prototype.render=function(t,i,r,o){this._brushController||(this._brushController=new Gw(r.getZr()),this._brushController.on("brush",he(this._onBrush,this)).mount()),function(a,s,l,u,h){var c=l._isZoomActive;u&&u.type==="takeGlobalCursor"&&(c=u.key==="dataZoomSelect"&&u.dataZoomSelectActive),l._isZoomActive=c,a.setIconStatus("zoom",c?"emphasis":"normal");var p=new Zb(Lf(a),s,{include:["grid"]}),d=p.makePanelOpts(h,function(f){return f.xAxisDeclared&&!f.yAxisDeclared?"lineX":!f.xAxisDeclared&&f.yAxisDeclared?"lineY":"rect"});l._brushController.setPanels(d).enableBrush(!(!c||!d.length)&&{brushType:"auto",brushStyle:a.getModel("brushStyle").getItemStyle()})}(t,i,this,o,r),function(a,s){a.setIconStatus("back",function(l){return Tf(l).length}(s)>1?"emphasis":"normal")}(t,i)},e.prototype.onclick=function(t,i,r){FL[r].call(this)},e.prototype.remove=function(t,i){this._brushController&&this._brushController.unmount()},e.prototype.dispose=function(t,i){this._brushController&&this._brushController.dispose()},e.prototype._onBrush=function(t){var i=t.areas;if(t.isEnd&&i.length){var r={},o=this.ecModel;this._brushController.updateCovers([]),new Zb(Lf(this.model),o,{include:["grid"]}).matchOutputRanges(i,o,function(s,l,u){if(u.type==="cartesian2d"){var h=s.brushType;h==="rect"?(a("x",u,l[0]),a("y",u,l[1])):a({lineX:"x",lineY:"y"}[h],u,l)}}),function(s,l){var u=Tf(s);Vb(l,function(h,c){for(var p=u.length-1;p>=0&&!u[p][c];p--);if(p<0){var d=s.queryComponents({mainType:"dataZoom",subType:"select",id:c})[0];if(d){var f=d.getPercentRange();u[0][c]={dataZoomId:c,start:f[0],end:f[1]}}}}),u.push(l)}(o,r),this._dispatchZoomAction(r)}function a(s,l,u){var h=l.getAxis(s),c=h.model,p=function(f,g,v){var y;return v.eachComponent({mainType:"dataZoom",subType:"select"},function(m){m.getAxisModel(f,g.componentIndex)&&(y=m)}),y}(s,c,o),d=p.findRepresentativeAxisProxy(c).getMinMaxSpan();d.minValueSpan==null&&d.maxValueSpan==null||(u=Vu(0,u.slice(),h.scale.getExtent(),0,d.minValueSpan,d.maxValueSpan)),p&&(r[p.id]={dataZoomId:p.id,startValue:u[0],endValue:u[1]})}},e.prototype._dispatchZoomAction=function(t){var i=[];kf(t,function(r,o){i.push(ie(r))}),i.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:i})},e.getDefaultOption=function(t){return{show:!0,filterMode:"filter",icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:t.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:"rgba(210,219,238,0.2)"}}},e}(Tn),FL={zoom:function(){var n=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:n})},back:function(){this._dispatchZoomAction(function(n){var e=Tf(n),t=e[e.length-1];e.length>1&&e.pop();var i={};return Vb(t,function(r,o){for(var a=e.length-1;a>=0;a--)if(r=e[a][o]){i[o]=r;break}}),i}(this.ecModel))}};function Lf(n){var e={xAxisIndex:n.get("xAxisIndex",!0),yAxisIndex:n.get("yAxisIndex",!0),xAxisId:n.get("xAxisId",!0),yAxisId:n.get("yAxisId",!0)};return e.xAxisIndex==null&&e.xAxisId==null&&(e.xAxisIndex="all"),e.yAxisIndex==null&&e.yAxisId==null&&(e.yAxisIndex="all"),e}Af="dataZoom",Df=function(n){var e=n.getComponent("toolbox",0),t=["feature","dataZoom"];if(e&&e.get(t)!=null){var i=e.getModel(t),r=[],o=oa(n,Lf(i));return kf(o.xAxisModels,function(s){return a(s,"xAxis","xAxisIndex")}),kf(o.yAxisModels,function(s){return a(s,"yAxis","yAxisIndex")}),r}function a(s,l,u){var h=s.componentIndex,c={type:"select",$fromToolbox:!0,filterMode:i.get("filterMode",!0)||"filter",id:BL+l+h};c[u]=h,r.push(c)}},le(cp.get(Af)==null&&Df),cp.set(Af,Df);const GL=VL,HL=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.type="tooltip",e.dependencies=["axisPointer"],e.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"#fff",shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#666",fontSize:14}},e}(Se);function qb(n){var e=n.get("confine");return e!=null?!!e:n.get("renderMode")==="richText"}function Kb(n){if(_e.domSupported){for(var e=document.documentElement.style,t=0,i=n.length;t-1?(x+="top:50%",_+="translateY(-50%) rotate("+(v=y==="left"?-225:-45)+"deg)"):(x+="left:50%",_+="translateX(-50%) rotate("+(v=y==="top"?225:45)+"deg)");var w=v*Math.PI/180,b=m+f,S=b*Math.abs(Math.cos(w))+b*Math.abs(Math.sin(w)),M=c+" solid "+f+"px;";return'
'}(i,r,o)),j(e))a.innerHTML=e+s;else if(e){a.innerHTML="",W(e)||(e=[e]);for(var l=0;l=0?this._tryShow(r,o):i==="leave"&&this._hide(o))},this))},e.prototype._keepShow=function(){var t=this._tooltipModel,i=this._ecModel,r=this._api,o=t.get("triggerOn");if(this._lastX!=null&&this._lastY!=null&&o!=="none"&&o!=="click"){var a=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!r.isDisposed()&&a.manuallyShowTip(t,i,r,{x:a._lastX,y:a._lastY,dataByCoordSys:a._lastDataByCoordSys})})}},e.prototype.manuallyShowTip=function(t,i,r,o){if(o.from!==this.uid&&!_e.node&&r.getDom()){var a=iS(o,r);this._ticket="";var s=o.dataByCoordSys,l=function(f,g,v){var y=ic(f).queryOptionMap,m=y.keys()[0];if(!(!m||m==="series")){var x=aa(g,m,y.get(m),{useDefault:!1,enableAll:!1,enableNone:!1}),_=x.models[0];if(_){var w,b=v.getViewOfComponentModel(_);if(b.group.traverse(function(S){var M=ye(S).tooltipConfig;if(M&&M.name===f.name)return w=S,!0}),w)return{componentMainType:m,componentIndex:_.componentIndex,el:w}}}}(o,i,r);if(l){var u=l.el.getBoundingRect().clone();u.applyTransform(l.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:l.el,position:o.position,positionDefault:"bottom"},a)}else if(o.tooltip&&o.x!=null&&o.y!=null){var h=KL;h.x=o.x,h.y=o.y,h.update(),ye(h).tooltipConfig={name:null,option:o.tooltip},this._tryShow({offsetX:o.x,offsetY:o.y,target:h},a)}else if(s)this._tryShow({offsetX:o.x,offsetY:o.y,position:o.position,dataByCoordSys:s,tooltipOption:o.tooltipOption},a);else if(o.seriesIndex!=null){if(this._manuallyAxisShowTip(t,i,r,o))return;var c=_b(o,i),p=c.point[0],d=c.point[1];p!=null&&d!=null&&this._tryShow({offsetX:p,offsetY:d,target:c.el,position:o.position,positionDefault:"bottom"},a)}else o.x!=null&&o.y!=null&&(r.dispatchAction({type:"updateAxisPointer",x:o.x,y:o.y}),this._tryShow({offsetX:o.x,offsetY:o.y,position:o.position,target:r.getZr().findHover(o.x,o.y).target},a))}},e.prototype.manuallyHideTip=function(t,i,r,o){var a=this._tooltipContent;this._tooltipModel&&a.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,o.from!==this.uid&&this._hide(iS(o,r))},e.prototype._manuallyAxisShowTip=function(t,i,r,o){var a=o.seriesIndex,s=o.dataIndex,l=i.getComponent("axisPointer").coordSysAxesInfo;if(a!=null&&s!=null&&l!=null){var u=i.getSeriesByIndex(a);if(u&&ss([u.getData().getItemModel(s),u,(u.coordinateSystem||{}).model],this._tooltipModel).get("trigger")==="axis")return r.dispatchAction({type:"updateAxisPointer",seriesIndex:a,dataIndex:s,position:o.position}),!0}},e.prototype._tryShow=function(t,i){var r=t.target;if(this._tooltipModel){this._lastX=t.offsetX,this._lastY=t.offsetY;var o=t.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,t);else if(r){var a,s;if(ye(r).ssrType==="legend")return;this._lastDataByCoordSys=null,yr(r,function(l){return ye(l).dataIndex!=null?(a=l,!0):ye(l).tooltipConfig!=null?(s=l,!0):void 0},!0),a?this._showSeriesItemTooltip(t,a,i):s?this._showComponentItemTooltip(t,s,i):this._hide(i)}else this._lastDataByCoordSys=null,this._hide(i)}},e.prototype._showOrMove=function(t,i){var r=t.get("showDelay");i=he(i,this),clearTimeout(this._showTimout),r>0?this._showTimout=setTimeout(i,r):i()},e.prototype._showAxisTooltip=function(t,i){var r=this._ecModel,o=this._tooltipModel,a=[i.offsetX,i.offsetY],s=ss([i.tooltipOption],o),l=this._renderMode,u=[],h=ri("section",{blocks:[],noHeader:!0}),c=[],p=new Ip;A(t,function(m){A(m.dataByAxis,function(x){var _=r.getComponent(x.axisDim+"Axis",x.axisIndex),w=x.value;if(_&&w!=null){var b=pb(w,_.axis,r,x.seriesDataIndices,x.valueLabelOpt),S=ri("section",{header:b,noHeader:!Wt(b),sortBlocks:!0,blocks:[]});h.blocks.push(S),A(x.seriesDataIndices,function(M){var T=r.getSeriesByIndex(M.seriesIndex),C=M.dataIndexInside,I=T.getDataParams(C);if(!(I.dataIndex<0)){I.axisDim=x.axisDim,I.axisIndex=x.axisIndex,I.axisType=x.axisType,I.axisId=x.axisId,I.axisValue=vd(_.axis,{value:w}),I.axisValueLabel=b,I.marker=p.makeTooltipMarker("item",gr(I.color),l);var D=t0(T.formatTooltip(C,!0,null)),L=D.frag;if(L){var R=ss([T],o).get("valueFormatter");S.blocks.push(R?G({valueFormatter:R},L):L)}D.text&&c.push(D.text),u.push(I)}})}})}),h.blocks.reverse(),c.reverse();var d=i.position,f=s.get("order"),g=g0(h,p,l,f,r.get("useUTC"),s.get("textStyle"));g&&c.unshift(g);var v=l==="richText"?` `:"
",y=c.join(v);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(t,u)?this._updatePosition(s,d,a[0],a[1],this._tooltipContent,u):this._showTooltipContent(s,y,u,Math.random()+"",a[0],a[1],d,null,p)})},e.prototype._showSeriesItemTooltip=function(t,i,r){var o=this._ecModel,a=ye(i),s=a.seriesIndex,l=o.getSeriesByIndex(s),u=a.dataModel||l,h=a.dataIndex,c=a.dataType,p=u.getData(c),d=this._renderMode,f=t.positionDefault,g=ss([p.getItemModel(h),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,f?{position:f}:null),v=g.get("trigger");if(v==null||v==="item"){var y=u.getDataParams(h,c),m=new Ip;y.marker=m.makeTooltipMarker("item",gr(y.color),d);var x=t0(u.formatTooltip(h,!1,c)),_=g.get("order"),w=g.get("valueFormatter"),b=x.frag,S=b?g0(w?G({valueFormatter:w},b):b,m,d,_,o.get("useUTC"),g.get("textStyle")):x.text,M="item_"+u.name+"_"+h;this._showOrMove(g,function(){this._showTooltipContent(g,S,y,M,t.offsetX,t.offsetY,t.position,t.target,m)}),r({type:"showTip",dataIndexInside:h,dataIndex:p.getRawIndex(h),seriesIndex:s,from:this.uid})}},e.prototype._showComponentItemTooltip=function(t,i,r){var o=ye(i),a=o.tooltipConfig.option||{};j(a)&&(a={content:a,formatter:a});var s=[a],l=this._ecModel.getComponent(o.componentMainType,o.componentIndex);l&&s.push(l),s.push({formatter:a.content});var u=t.positionDefault,h=ss(s,this._tooltipModel,u?{position:u}:null),c=h.get("content"),p=Math.random()+"",d=new Ip;this._showOrMove(h,function(){var f=ie(h.get("formatterParams")||{});this._showTooltipContent(h,c,f,p,t.offsetX,t.offsetY,t.position,i,d)}),r({type:"showTip",from:this.uid})},e.prototype._showTooltipContent=function(t,i,r,o,a,s,l,u,h){if(this._ticket="",t.get("showContent")&&t.get("show")){var c=this._tooltipContent;c.setEnterable(t.get("enterable"));var p=t.get("formatter");l=l||t.get("position");var d=i,f=this._getNearestPoint([a,s],r,t.get("trigger"),t.get("borderColor")).color;if(p)if(j(p)){var g=t.ecModel.get("useUTC"),v=W(r)?r[0]:r;d=p,v&&v.axisType&&v.axisType.indexOf("time")>=0&&(d=Ca(v.axisValue,d,g)),d=sp(d,r,!0)}else if(re(p)){var y=he(function(m,x){m===this._ticket&&(c.setContent(x,h,t,f,l),this._updatePosition(t,l,a,s,c,r,u))},this);this._ticket=o,d=p(r,o,y)}else d=p;c.setContent(d,h,t,f,l),c.show(t,f),this._updatePosition(t,l,a,s,c,r,u)}},e.prototype._getNearestPoint=function(t,i,r,o){return r==="axis"||W(i)?{color:o||(this._renderMode==="html"?"#fff":"none")}:W(i)?void 0:{color:o||i.color||i.borderColor}},e.prototype._updatePosition=function(t,i,r,o,a,s,l){var u=this._api.getWidth(),h=this._api.getHeight();i=i||t.get("position");var c=a.getSize(),p=t.get("align"),d=t.get("verticalAlign"),f=l&&l.getBoundingRect().clone();if(l&&f.applyTransform(l.transform),re(i)&&(i=i([r,o],s,a.el,f,{viewSize:[u,h],contentSize:c.slice()})),W(i))r=te(i[0],u),o=te(i[1],h);else if(Q(i)){var g=i;g.width=c[0],g.height=c[1];var v=Vt(g,{width:u,height:h});r=v.x,o=v.y,p=null,d=null}else if(j(i)&&l){var y=function(m,x,_,w){var b=_[0],S=_[1],M=Math.ceil(Math.SQRT2*w)+8,T=0,C=0,I=x.width,D=x.height;switch(m){case"inside":T=x.x+I/2-b/2,C=x.y+D/2-S/2;break;case"top":T=x.x+I/2-b/2,C=x.y-S-M;break;case"bottom":T=x.x+I/2-b/2,C=x.y+D+M;break;case"left":T=x.x-b-M,C=x.y+D/2-S/2;break;case"right":T=x.x+I+M,C=x.y+D/2-S/2}return[T,C]}(i,f,c,t.get("borderWidth"));r=y[0],o=y[1]}else y=function(m,x,_,w,b,S,M){var T=_.getSize(),C=T[0],I=T[1];return S!=null&&(m+C+S+2>w?m-=C+S:m+=S),M!=null&&(x+I+M>b?x-=I+M:x+=M),[m,x]}(r,o,a,u,h,p?null:20,d?null:20),r=y[0],o=y[1];p&&(r-=rS(p)?c[0]/2:p==="right"?c[0]:0),d&&(o-=rS(d)?c[1]/2:d==="bottom"?c[1]:0),qb(t)&&(y=function(m,x,_,w,b){var S=_.getSize(),M=S[0],T=S[1];return m=Math.min(m+M,w)-M,x=Math.min(x+T,b)-T,m=Math.max(m,0),x=Math.max(x,0),[m,x]}(r,o,a,u,h),r=y[0],o=y[1]),a.moveTo(r,o)},e.prototype._updateContentNotChangedOnAxis=function(t,i){var r=this._lastDataByCoordSys,o=this._cbParamsList,a=!!r&&r.length===t.length;return a&&A(r,function(s,l){var u=s.dataByAxis||[],h=(t[l]||{}).dataByAxis||[];(a=a&&u.length===h.length)&&A(u,function(c,p){var d=h[p]||{},f=c.seriesDataIndices||[],g=d.seriesDataIndices||[];(a=a&&c.value===d.value&&c.axisType===d.axisType&&c.axisId===d.axisId&&f.length===g.length)&&A(f,function(v,y){var m=g[y];a=a&&v.seriesIndex===m.seriesIndex&&v.dataIndex===m.dataIndex}),o&&A(c.seriesDataIndices,function(v){var y=v.seriesIndex,m=i[y],x=o[y];m&&x&&x.data!==m.data&&(a=!1)})})}),this._lastDataByCoordSys=t,this._cbParamsList=i,!!a},e.prototype._hide=function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},e.prototype.dispose=function(t,i){!_e.node&&i.getDom()&&(zl(this,"_updatePosition"),this._tooltipContent.dispose(),mf("itemTooltip",i))},e.type="tooltip",e}(Ze);function ss(n,e,t){var i,r=e.ecModel;t?(i=new He(t,r,r),i=new He(e.option,i,r)):i=e;for(var o=n.length-1;o>=0;o--){var a=n[o];a&&(a instanceof He&&(a=a.get("tooltip",!0)),j(a)&&(a={formatter:a}),a&&(i=new He(a,i,r)))}return i}function iS(n,e){return n.dispatchAction||he(e.dispatchAction,e)}function rS(n){return n==="center"||n==="middle"}const $L=JL;var oS=A;function aS(n){if(n){for(var e in n)if(n.hasOwnProperty(e))return!0}}function sS(n,e,t){var i={};return oS(e,function(r){var o,a=i[r]=((o=function(){}).prototype.__hidden=o.prototype,new o);oS(n[r],function(s,l){if(Ot.isValidType(l)){var u={type:l,visual:s};t&&t(u,r),a[l]=new Ot(u),l==="opacity"&&((u=ie(u)).type="colorAlpha",a.__hidden.__alphaForOpacity=new Ot(u))}})}),i}function QL(n,e,t,i){var r={};return A(n,function(o){var a=Ot.prepareVisualTypes(e[o]);r[o]=a}),{progress:function(o,a){var s,l;function u(_){return V0(a,l,_)}function h(_,w){(function(b,S,M,T){switch(M){case"color":b.ensureUniqueItemVisual(S,"style")[b.getVisual("drawType")]=T,b.setItemVisual(S,"colorFromPalette",!1);break;case"opacity":b.ensureUniqueItemVisual(S,"style").opacity=T;break;case"symbol":case"symbolSize":case"liftZ":b.setItemVisual(S,M,T);break;default:console.warn("Unknown visual type "+M)}})(a,l,_,w)}i!=null&&(s=a.getDimensionIndex(i));for(var c=a.getStore();(l=o.next())!=null;){var p=a.getRawDataItem(l);if(!p||p.visualMap!==!1)for(var d=i!=null?c.get(s,l):l,f=t(d),g=e[f],v=r[f],y=0,m=v.length;y=0},e.prototype.getOrient=function(){return this.get("orient")==="vertical"?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},e.type="legend.plain",e.dependencies=["series"],e.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:"#ccc",inactiveBorderColor:"#ccc",inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:"#ccc",inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:"#333"},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:"#666",borderWidth:1,borderColor:"#666"},emphasis:{selectorLabel:{show:!0,color:"#eee",backgroundColor:"#666"}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1}},e}(Se);const Of=nP;var Do=Te,Rf=A,ju=me,iP=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.newlineDisabled=!1,t}return V(e,n),e.prototype.init=function(){this.group.add(this._contentGroup=new ju),this.group.add(this._selectorGroup=new ju),this._isFirstRender=!0},e.prototype.getContentGroup=function(){return this._contentGroup},e.prototype.getSelectorGroup=function(){return this._selectorGroup},e.prototype.render=function(t,i,r){var o=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),t.get("show",!0)){var a=t.get("align"),s=t.get("orient");a&&a!=="auto"||(a=t.get("left")==="right"&&s==="vertical"?"right":"left");var l=t.get("selector",!0),u=t.get("selectorPosition",!0);!l||u&&u!=="auto"||(u=s==="horizontal"?"end":"start"),this.renderInner(a,t,i,r,l,s,u);var h=t.getBoxLayoutParams(),c={width:r.getWidth(),height:r.getHeight()},p=t.get("padding"),d=Vt(h,c,p),f=this.layoutInner(t,a,d,o,l,u),g=Vt(ae({width:f.width,height:f.height},h),c,p);this.group.x=g.x-f.x,this.group.y=g.y-f.y,this.group.markRedraw(),this.group.add(this._backgroundEl=Nb(f,t))}},e.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},e.prototype.renderInner=function(t,i,r,o,a,s,l){var u=this.getContentGroup(),h=ee(),c=i.get("selectedMode"),p=[];r.eachRawSeries(function(d){!d.get("legendHoverLink")&&p.push(d.id)}),Rf(i.getData(),function(d,f){var g=d.get("name");if(!this.newlineDisabled&&(g===""||g===` `)){var v=new ju;return v.newline=!0,void u.add(v)}var y=r.getSeriesByName(g)[0];if(!h.get(g)){if(y){var m=y.getData(),x=m.getVisual("legendLineStyle")||{},_=m.getVisual("legendIcon"),w=m.getVisual("style"),b=this._createItem(y,g,f,d,i,t,x,w,_,c,o);b.on("click",Do(lS,g,null,o,p)).on("mouseover",Do(Ef,y.name,null,o,p)).on("mouseout",Do(Nf,y.name,null,o,p)),r.ssr&&b.eachChild(function(S){var M=ye(S);M.seriesIndex=y.seriesIndex,M.dataIndex=f,M.ssrType="legend"}),h.set(g,!0)}else r.eachRawSeries(function(S){if(!h.get(g)&&S.legendVisualProvider){var M=S.legendVisualProvider;if(!M.containName(g))return;var T=M.indexOfName(g),C=M.getItemVisual(T,"style"),I=M.getItemVisual(T,"legendIcon"),D=Ct(C.fill);D&&D[3]===0&&(D[3]=.2,C=G(G({},C),{fill:fn(D,"rgba")}));var L=this._createItem(S,g,f,d,i,t,{},C,I,c,o);L.on("click",Do(lS,null,g,o,p)).on("mouseover",Do(Ef,null,g,o,p)).on("mouseout",Do(Nf,null,g,o,p)),r.ssr&&L.eachChild(function(R){var O=ye(R);O.seriesIndex=S.seriesIndex,O.dataIndex=f,O.ssrType="legend"}),h.set(g,!0)}},this);h.get(g)||console.warn(g+" series not exists. Legend data should be same with series name or data name.")}},this),a&&this._createSelector(a,i,o,s,l)},e.prototype._createSelector=function(t,i,r,o,a){var s=this.getSelectorGroup();Rf(t,function(l){var u=l.type,h=new De({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){r.dispatchAction({type:u==="all"?"legendAllSelect":"legendInverseSelect"})}});s.add(h),ei(h,{normal:i.getModel("selectorLabel"),emphasis:i.getModel(["emphasis","selectorLabel"])},{defaultText:l.title}),ca(h)})},e.prototype._createItem=function(t,i,r,o,a,s,l,u,h,c,p){var d=t.visualDrawType,f=a.get("itemWidth"),g=a.get("itemHeight"),v=a.isSelected(i),y=o.get("symbolRotate"),m=o.get("symbolKeepAspect"),x=o.get("icon"),_=function(O,E,k,P,N,B,z){function X(J,H){J.lineWidth==="auto"&&(J.lineWidth=H.lineWidth>0?2:0),Rf(J,function($,ne){J[ne]==="inherit"&&(J[ne]=H[ne])})}var Z=E.getModel("itemStyle"),F=Z.getItemStyle(),Y=O.lastIndexOf("empty",0)===0?"fill":"stroke",K=Z.getShallow("decal");F.decal=K&&K!=="inherit"?Ul(K,z):P.decal,F.fill==="inherit"&&(F.fill=P[N]),F.stroke==="inherit"&&(F.stroke=P[Y]),F.opacity==="inherit"&&(F.opacity=(N==="fill"?P:k).opacity),X(F,P);var oe=E.getModel("lineStyle"),ce=oe.getLineStyle();if(X(ce,k),F.fill==="auto"&&(F.fill=P.fill),F.stroke==="auto"&&(F.stroke=P.fill),ce.stroke==="auto"&&(ce.stroke=P.fill),!B){var se=E.get("inactiveBorderWidth"),q=F[Y];F.lineWidth=se==="auto"?P.lineWidth>0&&q?2:0:F.lineWidth,F.fill=E.get("inactiveColor"),F.stroke=E.get("inactiveBorderColor"),ce.stroke=oe.get("inactiveColor"),ce.lineWidth=oe.get("inactiveWidth")}return{itemStyle:F,lineStyle:ce}}(h=x||h||"roundRect",o,l,u,d,v,p),w=new ju,b=o.getModel("textStyle");if(!re(t.getLegendIcon)||x&&x!=="inherit"){var S=x==="inherit"&&t.getData().getVisual("symbol")?y==="inherit"?t.getData().getVisual("symbolRotate"):y:0;w.add(function(O){var E=O.icon||"roundRect",k=St(E,0,0,O.itemWidth,O.itemHeight,O.itemStyle.fill,O.symbolKeepAspect);return k.setStyle(O.itemStyle),k.rotation=(O.iconRotate||0)*Math.PI/180,k.setOrigin([O.itemWidth/2,O.itemHeight/2]),E.indexOf("empty")>-1&&(k.style.stroke=k.style.fill,k.style.fill="#fff",k.style.lineWidth=2),k}({itemWidth:f,itemHeight:g,icon:h,iconRotate:S,itemStyle:_.itemStyle,lineStyle:_.lineStyle,symbolKeepAspect:m}))}else w.add(t.getLegendIcon({itemWidth:f,itemHeight:g,icon:h,iconRotate:y,itemStyle:_.itemStyle,lineStyle:_.lineStyle,symbolKeepAspect:m}));var M=s==="left"?f+5:-5,T=s,C=a.get("formatter"),I=i;j(C)&&C?I=C.replace("{name}",i??""):re(C)&&(I=C(i));var D=v?b.getTextColor():o.get("inactiveColor");w.add(new De({style:rt(b,{text:I,x:M,y:g/2,fill:D,align:T,verticalAlign:"middle"},{inheritColor:D})}));var L=new Re({shape:w.getBoundingRect(),style:{fill:"transparent"}}),R=o.getModel("tooltip");return R.get("show")&&wa({el:L,componentModel:a,itemName:i,itemTooltipOption:R.option}),w.add(L),w.eachChild(function(O){O.silent=!0}),L.silent=!c,this.getContentGroup().add(w),ca(w),w.__legendDataIndex=r,w},e.prototype.layoutInner=function(t,i,r,o,a,s){var l=this.getContentGroup(),u=this.getSelectorGroup();vr(t.get("orient"),l,t.get("itemGap"),r.width,r.height);var h=l.getBoundingRect(),c=[-h.x,-h.y];if(u.markRedraw(),l.markRedraw(),a){vr("horizontal",u,t.get("selectorItemGap",!0));var p=u.getBoundingRect(),d=[-p.x,-p.y],f=t.get("selectorButtonGap",!0),g=t.getOrient().index,v=g===0?"width":"height",y=g===0?"height":"width",m=g===0?"y":"x";s==="end"?d[g]+=h[v]+f:c[g]+=p[v]+f,d[1-g]+=h[y]/2-p[y]/2,u.x=d[0],u.y=d[1],l.x=c[0],l.y=c[1];var x={x:0,y:0};return x[v]=h[v]+f+p[v],x[y]=Math.max(h[y],p[y]),x[m]=Math.min(0,p[m]+d[1-g]),x}return l.x=c[0],l.y=c[1],this.group.getBoundingRect()},e.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},e.type="legend.plain",e}(Ze);function lS(n,e,t,i){Nf(n,e,t,i),t.dispatchAction({type:"legendToggleSelect",name:n??e}),Ef(n,e,t,i)}function uS(n){for(var e,t=n.getZr().storage.getDisplayList(),i=0,r=t.length;ir[a],v=[-d.x,-d.y];i||(v[o]=h[u]);var y=[0,0],m=[-f.x,-f.y],x=de(t.get("pageButtonGap",!0),t.get("itemGap",!0));g&&(t.get("pageButtonPosition",!0)==="end"?m[o]+=r[a]-f[a]:y[o]+=f[a]+x),m[1-o]+=d[s]/2-f[s]/2,h.setPosition(v),c.setPosition(y),p.setPosition(m);var _={x:0,y:0};if(_[a]=g?r[a]:d[a],_[s]=Math.max(d[s],f[s]),_[l]=Math.min(0,f[l]+m[1-o]),c.__rectSize=r[a],g){var w={x:0,y:0};w[a]=Math.max(r[a]-f[a]-x,0),w[s]=_[s],c.setClipPath(new Re({shape:w})),c.__rectSize=w[a]}else p.eachChild(function(S){S.attr({invisible:!0,silent:!0})});var b=this._getPageInfo(t);return b.pageIndex!=null&&Fe(h,{x:b.contentPosition[0],y:b.contentPosition[1]},g?t:null),this._updatePageInfoView(t,b),_},e.prototype._pageGo=function(t,i,r){var o=this._getPageInfo(i)[t];o!=null&&r.dispatchAction({type:"legendScroll",scrollDataIndex:o,legendId:i.id})},e.prototype._updatePageInfoView=function(t,i){var r=this._controllerGroup;A(["pagePrev","pageNext"],function(h){var c=i[h+"DataIndex"]!=null,p=r.childOfName(h);p&&(p.setStyle("fill",c?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),p.cursor=c?"pointer":"default")});var o=r.childOfName("pageText"),a=t.get("pageFormatter"),s=i.pageIndex,l=s!=null?s+1:0,u=i.pageCount;o&&a&&o.setStyle("text",j(a)?a.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):a({current:l,total:u}))},e.prototype._getPageInfo=function(t){var i=t.get("scrollDataIndex",!0),r=this.getContentGroup(),o=this._containerGroup.__rectSize,a=t.getOrient().index,s=zf[a],l=Bf[a],u=this._findTargetItemIndex(i),h=r.children(),c=h[u],p=h.length,d=p?1:0,f={contentPosition:[r.x,r.y],pageCount:d,pageIndex:d-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!c)return f;var g=_(c);f.contentPosition[a]=-g.s;for(var v=u+1,y=g,m=g,x=null;v<=p;++v)(!(x=_(h[v]))&&m.e>y.s+o||x&&!w(x,y.s))&&(y=m.i>y.i?m:x)&&(f.pageNextDataIndex==null&&(f.pageNextDataIndex=y.i),++f.pageCount),m=x;for(v=u-1,y=g,m=g,x=null;v>=-1;--v)(x=_(h[v]))&&w(m,x.s)||!(y.i=S&&b.s<=S+o}},e.prototype._findTargetItemIndex=function(t){return this._showController?(this.getContentGroup().eachChild(function(o,a){var s=o.__legendDataIndex;r==null&&s!=null&&(r=a),s===t&&(i=a)}),i??r):0;var i,r},e.type="legend.scroll",e}(hS);const sP=aP;function lP(n){lt(cS),n.registerComponentModel(oP),n.registerComponentView(sP),function(e){e.registerAction("legendScroll","legendscroll",function(t,i){var r=t.scrollDataIndex;r!=null&&i.eachComponent({mainType:"legend",subType:"scroll",query:t},function(o){o.setScrollDataIndex(r)})})}(n)}var uP={get:function(n,e,t){var i=ie((hP[n]||{})[e]);return t&&W(i)?i[i.length-1]:i}},hP={color:{active:["#006edd","#e0ffff"],inactive:["rgba(0,0,0,0)"]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}};const fS=uP;var gS=Ot.mapVisual,cP=Ot.eachVisual,pP=W,vS=A,dP=Qo,fP=Ye,gP=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t.stateList=["inRange","outOfRange"],t.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],t.layoutMode={type:"box",ignoreSize:!0},t.dataBound=[-1/0,1/0],t.targetVisuals={},t.controllerVisuals={},t}return V(e,n),e.prototype.init=function(t,i,r){this.mergeDefaultAndTheme(t,r)},e.prototype.optionUpdated=function(t,i){var r=this.option;!i&&function(o,a,s){var l;A(s,function(u){a.hasOwnProperty(u)&&aS(a[u])&&(l=!0)}),l&&A(s,function(u){a.hasOwnProperty(u)&&aS(a[u])?o[u]=ie(a[u]):delete o[u]})}(r,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},e.prototype.resetVisual=function(t){var i=this.stateList;t=he(t,this),this.controllerVisuals=sS(this.option.controller,i,t),this.targetVisuals=sS(this.option.target,i,t)},e.prototype.getItemSymbol=function(){return null},e.prototype.getTargetSeriesIndices=function(){var t=this.option.seriesIndex,i=[];return t==null||t==="all"?this.ecModel.eachSeries(function(r,o){i.push(o)}):i=Qe(t),i},e.prototype.eachTargetSeries=function(t,i){A(this.getTargetSeriesIndices(),function(r){var o=this.ecModel.getSeriesByIndex(r);o&&t.call(i,o)},this)},e.prototype.isTargetSeries=function(t){var i=!1;return this.eachTargetSeries(function(r){r===t&&(i=!0)}),i},e.prototype.formatValueText=function(t,i,r){var o,a=this.option,s=a.precision,l=this.dataBound,u=a.formatter;r=r||["<",">"],W(t)&&(t=t.slice(),o=!0);var h=i?t:o?[c(t[0]),c(t[1])]:c(t);return j(u)?u.replace("{value}",o?h[0]:h).replace("{value2}",o?h[1]:h):re(u)?o?u(t[0],t[1]):u(t):o?t[0]===l[0]?r[0]+" "+h[1]:t[1]===l[1]?r[1]+" "+h[0]:h[0]+" - "+h[1]:h;function c(p){return p===l[0]?"min":p===l[1]?"max":(+p).toFixed(Math.min(s,20))}},e.prototype.resetExtent=function(){var t=this.option,i=dP([t.min,t.max]);this._dataExtent=i},e.prototype.getDataDimensionIndex=function(t){var i=this.option.dimension;if(i!=null)return t.getDimensionIndex(i);for(var r=t.dimensions,o=r.length-1;o>=0;o--){var a=r[o],s=t.getDimensionInfo(a);if(!s.isCalculationCoord)return s.storeDimIndex}},e.prototype.getExtent=function(){return this._dataExtent.slice()},e.prototype.completeVisualOption=function(){var t=this.ecModel,i=this.option,r={inRange:i.inRange,outOfRange:i.outOfRange},o=i.target||(i.target={}),a=i.controller||(i.controller={});pe(o,r),pe(a,r);var s=this.isCategory();function l(u){pP(i.color)&&!u.inRange&&(u.inRange={color:i.color.slice().reverse()}),u.inRange=u.inRange||{color:t.get("gradientColor")}}l.call(this,o),l.call(this,a),(function(u,h,c){var p=u[h],d=u[c];p&&!d&&(d=u[c]={},vS(p,function(f,g){if(Ot.isValidType(g)){var v=fS.get(g,"inactive",s);v!=null&&(d[g]=v,g!=="color"||d.hasOwnProperty("opacity")||d.hasOwnProperty("colorAlpha")||(d.opacity=[0,0]))}}))}).call(this,o,"inRange","outOfRange"),(function(u){var h=(u.inRange||{}).symbol||(u.outOfRange||{}).symbol,c=(u.inRange||{}).symbolSize||(u.outOfRange||{}).symbolSize,p=this.get("inactiveColor"),d=this.getItemSymbol()||"roundRect";vS(this.stateList,function(f){var g=this.itemSize,v=u[f];v||(v=u[f]={color:s?p:[p]}),v.symbol==null&&(v.symbol=h&&ie(h)||(s?d:[d])),v.symbolSize==null&&(v.symbolSize=c&&ie(c)||(s?g[0]:[g[0],g[0]])),v.symbol=gS(v.symbol,function(x){return x==="none"?d:x});var y=v.symbolSize;if(y!=null){var m=-1/0;cP(y,function(x){x>m&&(m=x)}),v.symbolSize=gS(y,function(x){return fP(x,[0,m],[0,g[0]],!0)})}},this)}).call(this,a)},e.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},e.prototype.isCategory=function(){return!!this.option.categories},e.prototype.setSelected=function(t){},e.prototype.getSelected=function(){return null},e.prototype.getValueState=function(t){return null},e.prototype.getVisualMeta=function(t){return null},e.type="visualMap",e.dependencies=["series"],e.defaultOption={show:!0,z:4,seriesIndex:"all",min:0,max:200,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",contentColor:"#5793f3",inactiveColor:"#aaa",borderWidth:0,padding:5,textGap:10,precision:0,textStyle:{color:"#333"}},e}(Se);const Zu=gP;var yS=[20,140],vP=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.optionUpdated=function(t,i){n.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(r){r.mappingMethod="linear",r.dataExtent=this.getExtent()}),this._resetRange()},e.prototype.resetItemSize=function(){n.prototype.resetItemSize.apply(this,arguments);var t=this.itemSize;(t[0]==null||isNaN(t[0]))&&(t[0]=yS[0]),(t[1]==null||isNaN(t[1]))&&(t[1]=yS[1])},e.prototype._resetRange=function(){var t=this.getExtent(),i=this.option.range;!i||i.auto?(t.auto=1,this.option.range=t):W(i)&&(i[0]>i[1]&&i.reverse(),i[0]=Math.max(i[0],t[0]),i[1]=Math.min(i[1],t[1]))},e.prototype.completeVisualOption=function(){n.prototype.completeVisualOption.apply(this,arguments),A(this.stateList,function(t){var i=this.option.controller[t].symbolSize;i&&i[0]!==i[1]&&(i[0]=i[1]/3)},this)},e.prototype.setSelected=function(t){this.option.range=t.slice(),this._resetRange()},e.prototype.getSelected=function(){var t=this.getExtent(),i=Qo((this.get("range")||[]).slice());return i[0]>t[1]&&(i[0]=t[1]),i[1]>t[1]&&(i[1]=t[1]),i[0]=r[1]||t<=i[1])?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var i=[];return this.eachTargetSeries(function(r){var o=[],a=r.getData();a.each(this.getDataDimensionIndex(a),function(s,l){t[0]<=s&&s<=t[1]&&o.push(l)},this),i.push({seriesId:r.id,dataIndex:o})},this),i},e.prototype.getVisualMeta=function(t){var i=mS(this,"outOfRange",this.getExtent()),r=mS(this,"inRange",this.option.range.slice()),o=[];function a(d,f){o.push({value:d,color:t(d,f)})}for(var s=0,l=0,u=r.length,h=i.length;lt[1])break;r.push({color:this.getControllerVisual(s,"color",i),offset:a/100})}return r.push({color:this.getControllerVisual(t[1],"color",i),offset:1}),r},e.prototype._createBarPoints=function(t,i){var r=this.visualMapModel.itemSize;return[[r[0]-i[0],t[0]],[r[0],t[0]],[r[0],t[1]],[r[0]-i[1],t[1]]]},e.prototype._createBarGroup=function(t){var i=this._orient,r=this.visualMapModel.get("inverse");return new me(i!=="horizontal"||r?i==="horizontal"&&r?{scaleX:t==="bottom"?-1:1,rotation:-Math.PI/2}:i!=="vertical"||r?{scaleX:t==="left"?1:-1}:{scaleX:t==="left"?1:-1,scaleY:-1}:{scaleX:t==="bottom"?1:-1,rotation:Math.PI/2})},e.prototype._updateHandle=function(t,i){if(this._useHandle){var r=this._shapes,o=this.visualMapModel,a=r.handleThumbs,s=r.handleLabels,l=o.itemSize,u=o.getExtent();mP([0,1],function(h){var c=a[h];c.setStyle("fill",i.handlesColor[h]),c.y=t[h];var p=Wn(t[h],[0,l[1]],u,!0),d=this.getControllerVisual(p,"symbolSize");c.scaleX=c.scaleY=d/l[0],c.x=l[0]-d/2;var f=Si(r.handleLabelPoints[h],dr(c,this.group));s[h].setStyle({x:f[0],y:f[1],text:o.formatValueText(this._dataInterval[h]),verticalAlign:"middle",align:this._orient==="vertical"?this._applyTransform("left",r.mainGroup):"center"})},this)}},e.prototype._showIndicator=function(t,i,r,o){var a=this.visualMapModel,s=a.getExtent(),l=a.itemSize,u=[0,l[1]],h=this._shapes,c=h.indicator;if(c){c.attr("invisible",!1);var p=this.getControllerVisual(t,"color",{convertOpacityToAlpha:!0}),d=this.getControllerVisual(t,"symbolSize"),f=Wn(t,s,u,!0),g=l[0]-d/2,v={x:c.x,y:c.y};c.y=f,c.x=g;var y=Si(h.indicatorLabelPoint,dr(c,this.group)),m=h.indicatorLabel;m.attr("invisible",!1);var x=this._applyTransform("left",h.mainGroup),_=this._orient==="horizontal";m.setStyle({text:(r||"")+a.formatValueText(i),verticalAlign:_?x:"middle",align:_?"center":x});var w={x:g,y:f,style:{fill:p}},b={style:{x:y[0],y:y[1]}};if(a.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var S={duration:100,easing:"cubicInOut",additive:!0};c.x=v.x,c.y=v.y,c.animateTo(w,S),m.animateTo(b,S)}else c.attr(w),m.attr(b);this._firstShowIndicator=!1;var M=this._shapes.handleLabels;if(M)for(var T=0;Ta[1]&&(c[1]=1/0),i&&(c[0]===-1/0?this._showIndicator(h,c[1],"< ",l):c[1]===1/0?this._showIndicator(h,c[0],"> ",l):this._showIndicator(h,h,"\u2248 ",l));var p=this._hoverLinkDataIndices,d=[];(i||MS(r))&&(d=this._hoverLinkDataIndices=r.findTargetDataIndices(c));var f=function(g,v){var y={},m={};return x(g||[],y),x(v||[],m,y),[_(y),_(m)];function x(w,b,S){for(var M=0,T=w.length;M=0&&(o.dimension=a,i.push(o))}}),n.getData().setVisual("visualMeta",i)}}];function MP(n,e,t,i){for(var r=e.targetVisuals[i],o=Ot.prepareVisualTypes(r),a={color:F0(n.getData(),"color")},s=0,l=o.length;s0:e.splitNumber>0)&&!e.calculable?"piecewise":"continuous"}),n.registerAction(wP,bP),A(SP,function(e){n.registerVisual(n.PRIORITY.VISUAL.COMPONENT,e)}),n.registerPreprocessor(TP))}function CP(n){n.registerComponentModel(yP),n.registerComponentView(_P),AS(n)}var IP=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t._pieceList=[],t}return V(e,n),e.prototype.optionUpdated=function(t,i){n.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var r=this._mode=this._determineMode();this._pieceList=[],AP[this._mode].call(this,this._pieceList),this._resetSelected(t,i);var o=this.option.categories;this.resetVisual(function(a,s){r==="categories"?(a.mappingMethod="category",a.categories=ie(o)):(a.dataExtent=this.getExtent(),a.mappingMethod="piecewise",a.pieceList=U(this._pieceList,function(l){return l=ie(l),s!=="inRange"&&(l.visual=null),l}))})},e.prototype.completeVisualOption=function(){var t=this.option,i={},r=Ot.listVisualTypes(),o=this.isCategory();function a(s,l,u){return s&&s[l]&&s[l].hasOwnProperty(u)}A(t.pieces,function(s){A(r,function(l){s.hasOwnProperty(l)&&(i[l]=1)})}),A(i,function(s,l){var u=!1;A(this.stateList,function(h){u=u||a(t,h,l)||a(t.target,h,l)},this),!u&&A(this.stateList,function(h){(t[h]||(t[h]={}))[l]=fS.get(l,h==="inRange"?"active":"inactive",o)})},this),n.prototype.completeVisualOption.apply(this,arguments)},e.prototype._resetSelected=function(t,i){var r=this.option,o=this._pieceList,a=(i?r:t).selected||{};if(r.selected=a,A(o,function(l,u){var h=this.getSelectedMapKey(l);a.hasOwnProperty(h)||(a[h]=!0)},this),r.selectedMode==="single"){var s=!1;A(o,function(l,u){var h=this.getSelectedMapKey(l);a[h]&&(s?a[h]=!1:s=!0)},this)}},e.prototype.getItemSymbol=function(){return this.get("itemSymbol")},e.prototype.getSelectedMapKey=function(t){return this._mode==="categories"?t.value+"":t.index+""},e.prototype.getPieceList=function(){return this._pieceList},e.prototype._determineMode=function(){var t=this.option;return t.pieces&&t.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},e.prototype.setSelected=function(t){this.option.selected=ie(t)},e.prototype.getValueState=function(t){var i=Ot.findPieceIndex(t,this._pieceList);return i!=null&&this.option.selected[this.getSelectedMapKey(this._pieceList[i])]?"inRange":"outOfRange"},e.prototype.findTargetDataIndices=function(t){var i=[],r=this._pieceList;return this.eachTargetSeries(function(o){var a=[],s=o.getData();s.each(this.getDataDimensionIndex(s),function(l,u){Ot.findPieceIndex(l,r)===t&&a.push(u)},this),i.push({seriesId:o.id,dataIndex:a})},this),i},e.prototype.getRepresentValue=function(t){var i;if(this.isCategory())i=t.value;else if(t.value!=null)i=t.value;else{var r=t.interval||[];i=r[0]===-1/0&&r[1]===1/0?0:(r[0]+r[1])/2}return i},e.prototype.getVisualMeta=function(t){if(!this.isCategory()){var i=[],r=["",""],o=this,a=this._pieceList.slice();if(a.length){var s=a[0].interval[0];s!==-1/0&&a.unshift({interval:[-1/0,s]}),(s=a[a.length-1].interval[1])!==1/0&&a.push({interval:[s,1/0]})}else a.push({interval:[-1/0,1/0]});var l=-1/0;return A(a,function(h){var c=h.interval;c&&(c[0]>l&&u([l,c[0]],"outOfRange"),u(c.slice()),l=c[1])},this),{stops:i,outerColors:r}}function u(h,c){var p=o.getRepresentValue({interval:h});c||(c=o.getValueState(p));var d=t(p,c);h[0]===-1/0?r[0]=d:h[1]===1/0?r[1]=d:i.push({value:h[0],color:d},{value:h[1],color:d})}},e.type="visualMap.piecewise",e.defaultOption=ba(Zu.defaultOption,{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieces:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0}),e}(Zu),AP={splitNumber:function(n){var e=this.option,t=Math.min(e.precision,20),i=this.getExtent(),r=e.splitNumber;r=Math.max(parseInt(r,10),1),e.splitNumber=r;for(var o=(i[1]-i[0])/r;+o.toFixed(t)!==o&&t<5;)t++;e.precision=t,o=+o.toFixed(t),e.minOpen&&n.push({interval:[-1/0,i[0]],close:[0,0]});for(var a=0,s=i[0];aa[1]&&console.warn("Piece "+i+"is illegal: "+a+" lower bound should not greater then uppper bound."),a[0]===a[1]&&s[0]&&s[1]&&(r.value=a[0])}r.visual=Ot.retrieveVisuals(t),n.push(r)},this),DS(e,n),tc(n),A(n,function(t){var i=t.close,r=[["<","\u2264"][i[1]],[">","\u2265"][i[0]]];t.text=t.text||this.formatValueText(t.value!=null?t.value:t.interval,!1,r)},this)}};function DS(n,e){var t=n.inverse;(n.orient==="vertical"?!t:t)&&e.reverse()}const DP=IP,kP=function(n){function e(){var t=n!==null&&n.apply(this,arguments)||this;return t.type=e.type,t}return V(e,n),e.prototype.doRender=function(){var t=this.group;t.removeAll();var i=this.visualMapModel,r=i.get("textGap"),o=i.textStyleModel,a=o.getFont(),s=o.getTextColor(),l=this._getItemAlign(),u=i.itemSize,h=this._getViewData(),c=h.endsText,p=Ht(i.get("showLabel",!0),!c);c&&this._renderEndsText(t,c[0],u,p,l),A(h.viewPieceList,function(d){var f=d.piece,g=new me;g.onclick=he(this._onItemClick,this,f),this._enableHoverLink(g,d.indexInModelPieceList);var v=i.getRepresentValue(f);if(this._createItemSymbol(g,v,[0,0,u[0],u[1]]),p){var y=this.visualMapModel.getValueState(v);g.add(new De({style:{x:l==="right"?-r:u[0]+r,y:u[1]/2,text:f.text,verticalAlign:"middle",align:l,font:a,fill:s,opacity:y==="outOfRange"?.5:1}}))}t.add(g)},this),c&&this._renderEndsText(t,c[1],u,p,l),vr(i.get("orient"),t,i.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},e.prototype._enableHoverLink=function(t,i){var r=this;t.on("mouseover",function(){return o("highlight")}).on("mouseout",function(){return o("downplay")});var o=function(a){var s=r.visualMapModel;s.option.hoverLink&&r.api.dispatchAction({type:a,batch:qu(s.findTargetDataIndices(i),s)})}},e.prototype._getItemAlign=function(){var t=this.visualMapModel,i=t.option;if(i.orient==="vertical")return wS(t,this.api,t.itemSize);var r=i.align;return r&&r!=="auto"||(r="left"),r},e.prototype._renderEndsText=function(t,i,r,o,a){if(i){var s=new me,l=this.visualMapModel.textStyleModel;s.add(new De({style:rt(l,{x:o?a==="right"?r[0]:0:r[0]/2,y:r[1]/2,verticalAlign:"middle",align:o?a:"center",text:i})})),t.add(s)}},e.prototype._getViewData=function(){var t=this.visualMapModel,i=U(t.getPieceList(),function(s,l){return{piece:s,indexInModelPieceList:l}}),r=t.get("text"),o=t.get("orient"),a=t.get("inverse");return(o==="horizontal"?a:!a)?i.reverse():r&&(r=r.slice().reverse()),{viewPieceList:i,endsText:r}},e.prototype._createItemSymbol=function(t,i,r){t.add(St(this.getControllerVisual(i,"symbol"),r[0],r[1],r[2],r[3],this.getControllerVisual(i,"color")))},e.prototype._onItemClick=function(t){var i=this.visualMapModel,r=i.option,o=r.selectedMode;if(o){var a=ie(r.selected),s=i.getSelectedMapKey(t);o==="single"||o===!0?(a[s]=!0,A(a,function(l,u){a[u]=u===s})):a[s]=!a[s],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:a})}},e.type="visualMap.piecewise",e}(xS);function LP(n){n.registerComponentModel(DP),n.registerComponentView(kP),AS(n)}var PP={label:{enabled:!0},decal:{show:!1}},kS=ze(),OP={};function RP(n,e){var t=n.getModel("aria");if(t.get("enabled")){var i=ie(PP);pe(i.label,n.getLocaleModel().get("aria"),!1),pe(t.option,i,!1),function(){if(t.getModel("decal").get("show")){var o=ee();n.eachSeries(function(a){if(!a.isColorBySeries()){var s=o.get(a.type);s||(s={},o.set(a.type,s)),kS(a).scope=s}}),n.eachRawSeries(function(a){if(!n.isSeriesFiltered(a))if(re(a.enableAriaDecal))a.enableAriaDecal();else{var s=a.getData();if(a.isColorBySeries()){var l=Am(a.ecModel,a.name,OP,n.getSeriesCount()),u=s.getVisual("decal");s.setVisual("decal",f(u,l))}else{var h=a.getRawData(),c={},p=kS(a).scope;s.each(function(g){var v=s.getRawIndex(g);c[v]=g});var d=h.count();h.each(function(g){var v=c[g],y=h.getName(g)||g+"",m=Am(a.ecModel,y,p,d),x=s.getItemVisual(v,"decal");s.setItemVisual(v,"decal",f(x,m))})}}function f(g,v){var y=g?G(G({},v),g):v;return y.dirty=!0,y}})}}(),function(){var o=n.getLocaleModel().get("aria"),a=t.getModel("label");if(a.option=ae(a.option,o),!!a.get("enabled")){var s=e.getZr().dom;if(a.get("description"))return void s.setAttribute("aria-label",a.get("description"));var l,u=n.getSeriesCount(),h=a.get(["data","maxCount"])||10,c=a.get(["series","maxCount"])||10,p=Math.min(u,c);if(!(u<1)){var d=function(){var m=n.get("title");return m&&m.length&&(m=m[0]),m&&m.text}();l=d?r(a.get(["general","withTitle"]),{title:d}):a.get(["general","withoutTitle"]);var f=[];l+=r(u>1?a.get(["series","multiple","prefix"]):a.get(["series","single","prefix"]),{seriesCount:u}),n.eachSeries(function(m,x){if(x1?a.get(["series","multiple",w]):a.get(["series","single",w]),{seriesId:m.seriesIndex,seriesName:m.get("name"),seriesType:(R=m.subType,O=n.getLocaleModel().get(["series","typeNames"]),O[R]||O.chart)});var b=m.getData();b.count()>h?_+=r(a.get(["data","partialData"]),{displayCnt:h}):_+=a.get(["data","allData"]);for(var S=a.get(["data","separator","middle"]),M=a.get(["data","separator","end"]),T=[],C=0;C=l)}}for(var p=this.__startIndex;p15)break}R.prevElClipPaths&&m.restore()};if(x)if(x.length===0)v=y.__endIndex;else for(var C=d.dpr,I=0;I0&&e>r[0]){for(l=0;le);l++);s=i[r[l]]}if(r.splice(l+1,0,e),i[e]=t,!t.virtual)if(s){var u=s.dom;u.nextSibling?a.insertBefore(t.dom,u.nextSibling):a.appendChild(t.dom)}else a.firstChild?a.insertBefore(t.dom,a.firstChild):a.appendChild(t.dom);t.painter||(t.painter=this)}else zi("Layer of zlevel "+e+" is not valid")},n.prototype.eachLayer=function(e,t){for(var i=this._zlevelList,r=0;r0?Ku:0),this._needsManuallyCompositing),h.__builtin__||zi("ZLevel "+u+" has been used by unkown layer "+h.id),h!==a&&(h.__used=!0,h.__startIndex!==o&&(h.__dirty=!0),h.__startIndex=o,h.incremental?h.__drawIndex=-1:h.__drawIndex=o,t(o),a=h),l.__dirty&Nt&&!l.__inHover&&(h.__dirty=!0,h.incremental&&h.__drawIndex<0&&(h.__drawIndex=o))}t(o),this.eachBuiltinLayer(function(c,p){!c.__used&&c.getElementCount()>0&&(c.__dirty=!0,c.__startIndex=c.__endIndex=c.__drawIndex=0),c.__dirty&&c.__drawIndex<0&&(c.__drawIndex=c.__startIndex)})},n.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},n.prototype._clearLayer=function(e){e.clear()},n.prototype.setBackgroundColor=function(e){this._backgroundColor=e,A(this._layers,function(t){t.setUnpainted()})},n.prototype.configLayer=function(e,t){if(t){var i=this._layerConfig;i[e]?pe(i[e],t,!0):i[e]=t;for(var r=0;r=0?1/(Math.cos(2*Math.PI/10-P)+3.07768*Math.sin(2*Math.PI/10-P)):1/(Math.cos(P)+3.07768*Math.sin(P))}}i.gridSize=Math.max(Math.floor(i.gridSize),4);var a,s,l,u,h,c,p,d,f=i.gridSize,g=f-i.maskGapWidth,v=Math.abs(i.maxRotation-i.minRotation),y=Math.min(i.maxRotation,i.minRotation),m=i.rotationStep;switch(i.color){case"random-dark":p=function(){return E(10,50)};break;case"random-light":p=function(){return E(50,90)};break;default:typeof i.color=="function"&&(p=i.color)}typeof i.fontWeight=="function"&&(d=i.fontWeight);var x=null;typeof i.classes=="function"&&(x=i.classes);var _,w=!1,b=[],S=function(k){var P,N,B=k.currentTarget,z=B.getBoundingClientRect();k.touches?(P=k.touches[0].clientX,N=k.touches[0].clientY):(P=k.clientX,N=k.clientY);var X=P-z.left,Z=N-z.top,F=Math.floor(X*(B.width/z.width||1)/f),Y=Math.floor(Z*(B.height/z.height||1)/f);return b[F]?b[F][Y]:null},M=function(k){var P=S(k);_!==P&&(_=P,P?i.hover(P.item,P.dimension,k):i.hover(void 0,void 0,k))},T=function(k){var P=S(k);P&&(i.click(P.item,P.dimension,k),k.preventDefault())},C=[],I=function(k){if(C[k])return C[k];var P=8*k,N=P,B=[];for(k===0&&B.push([u[0],u[1],0]);N--;){var z=1;i.shape!=="circle"&&(z=i.shape(N/P*2*Math.PI)),B.push([u[0]+k*z*Math.cos(-N/P*2*Math.PI),u[1]+k*z*Math.sin(-N/P*2*Math.PI)*i.ellipticity,N/P*2*Math.PI])}return C[k]=B,B},D=function(){return i.abortThreshold>0&&new Date().getTime()-c>i.abortThreshold},L=function(k,P,N,B,z){k>=s||P>=l||k<0||P<0||(a[k][P]=!1,N&&n[0].getContext("2d").fillRect(k*f,P*f,g,g),w&&(b[k][P]={item:z,dimension:B}))},R=function k(P,N){if(N>20)return null;var B,z,X;Array.isArray(P)?(B=P[0],z=P[1]):(B=P.word,z=P.weight,X=P.attributes);var Z=i.rotateRatio===0||Math.random()>i.rotateRatio?0:v===0?y:y+Math.round(Math.random()*v/m)*m,F=function(H){if(Array.isArray(H)){var $=H.slice();return $.splice(0,2),$}return[]}(P),Y=function(H,$,ne,Ce){var ge=i.weightFactor($);if(ge<=i.minSize)return!1;var xe,we=1;geci[1]&&(ci[1]=Or),cnci[2]&&(ci[2]=cn);break e}}return{mu:we,occupied:ES,bounds:ci,gw:We,gh:ut,fillTextOffsetX:vt,fillTextOffsetY:Ke,fillTextWidth:ke,fillTextHeight:Ne,fontSize:ge}}(B,z,Z,F);if(!Y||D())return!1;if(!i.drawOutOfBound&&!i.shrinkToFit){var K=Y.bounds;if(K[1]-K[3]+1>s||K[2]-K[0]+1>l)return!1}for(var oe=h+1,ce=function(H){var $=Math.floor(H[0]-Y.gw/2),ne=Math.floor(H[1]-Y.gh/2);return Y.gw,Y.gh,!!function(Ce,ge,xe,we,Ie){for(var be=Ie.length;be--;){var ke=Ce+Ie[be][0],Ne=ge+Ie[be][1];if(ke>=s||Ne>=l||ke<0||Ne<0){if(!i.drawOutOfBound)return!1}else if(!a[ke][Ne])return!1}return!0}($,ne,0,0,Y.occupied)&&(function(Ce,ge,xe,we,Ie,be,ke,Ne,qe,Be){var Ve,ue,vt,Ke=xe.fontSize;Ve=p?p(we,Ie,Ke,be,ke,Be):i.color,ue=d?d(we,Ie,Ke,Be):i.fontWeight,vt=x?x(we,Ie,Ke,Be):i.classes,n.forEach(function(ut){if(ut.getContext){var We=ut.getContext("2d"),Rt=xe.mu;We.save(),We.scale(1/Rt,1/Rt),We.font=ue+" "+(Ke*Rt).toString(10)+"px "+i.fontFamily,We.fillStyle=Ve,We.translate((Ce+xe.gw/2)*f*Rt,(ge+xe.gh/2)*f*Rt),Ne!==0&&We.rotate(-Ne),We.textBaseline="middle",We.fillText(we,xe.fillTextOffsetX*Rt,(xe.fillTextOffsetY+.5*Ke)*Rt),We.restore()}else{var hi=document.createElement("span"),Pr="";Pr="rotate("+-Ne/Math.PI*180+"deg) ",xe.mu!==1&&(Pr+="translateX(-"+xe.fillTextWidth/4+"px) scale("+1/xe.mu+")");var cn={position:"absolute",display:"block",font:ue+" "+Ke*xe.mu+"px "+i.fontFamily,left:(Ce+xe.gw/2)*f+xe.fillTextOffsetX+"px",top:(ge+xe.gh/2)*f+xe.fillTextOffsetY+"px",width:xe.fillTextWidth+"px",height:xe.fillTextHeight+"px",lineHeight:Ke+"px",whiteSpace:"nowrap",transform:Pr,webkitTransform:Pr,msTransform:Pr,transformOrigin:"50% 40%",webkitTransformOrigin:"50% 40%",msTransformOrigin:"50% 40%"};for(var Po in Ve&&(cn.color=Ve),hi.textContent=we,cn)hi.style[Po]=cn[Po];if(qe)for(var Oo in qe)hi.setAttribute(Oo,qe[Oo]);vt&&(hi.className+=vt),ut.appendChild(hi)}})}($,ne,Y,B,z,h-oe,H[2],Z,X,F),function(Ce,ge,xe,we,Ie,be){var ke,Ne,qe=Ie.occupied,Be=i.drawMask;if(Be&&((ke=n[0].getContext("2d")).save(),ke.fillStyle=i.maskColor),w){var Ve=Ie.bounds;Ne={x:(Ce+Ve[3])*f,y:(ge+Ve[0])*f,w:(Ve[1]-Ve[3]+1)*f,h:(Ve[2]-Ve[0]+1)*f}}for(var ue=qe.length;ue--;){var vt=Ce+qe[ue][0],Ke=ge+qe[ue][1];vt>=s||Ke>=l||vt<0||Ke<0||L(vt,Ke,Be,Ne,be)}Be&&ke.restore()}($,ne,0,0,Y,P),{gx:$,gy:ne,rot:Z,info:Y})};oe--;){var se=I(h-oe);i.shuffle&&(se=[].concat(se),GP(se));for(var q=0;q=i.list.length)return Z(Lo[t]),O("wordcloudstop",!1),q("wordcloudstart",J),void delete Lo[t];c=new Date().getTime();var $=R(i.list[z],0),ne=!O("wordclouddrawn",!0,{item:i.list[z],drawn:$});if(D()||ne)return Z(Lo[t]),i.abort(),O("wordcloudabort",!1),O("wordcloudstop",!1),void q("wordcloudstart",J);z++,Lo[t]=X(H,i.wait)}},i.wait)}})()}function E(k,P){return"hsl("+(360*Math.random()).toFixed()+","+(30*Math.random()+70).toFixed()+"%,"+(Math.random()*(P-k)+k).toFixed()+"%)"}};if(Ju.isSupported=Gf,Ju.minFontSize=Hf,!Ju.isSupported)throw new Error("Sorry your browser not support wordCloud");nd(function(n,e){n.eachSeriesByType("wordCloud",function(t){var i=Vt(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()}),r=t.get("keepAspect"),o=t.get("maskImage"),a=o?o.width/o.height:1;r&&function(v,y){var m=v.width,x=v.height;m>x*y?(v.x+=(m-x*y)/2,v.width=x*y):(v.y+=(x-m/y)/2,v.height=m/y)}(i,a);var s=t.getData(),l=document.createElement("canvas");l.width=i.width,l.height=i.height;var u=l.getContext("2d");if(o)try{u.drawImage(o,0,0,l.width,l.height),function(v){for(var y=v.getContext("2d"),m=y.getImageData(0,0,v.width,v.height),x=y.createImageData(m),_=0,w=0,b=0;b128&&(_+=M=m.data[b]+m.data[b+1]+m.data[b+2],++w);var S=_/w;for(b=0;bS?(x.data[b]=0,x.data[b+1]=0,x.data[b+2]=0,x.data[b+3]=0):(x.data[b]=255,x.data[b+1]=255,x.data[b+2]=255,x.data[b+3]=255)}y.putImageData(x,0,0)}(l)}catch(v){console.error("Invalid mask image"),console.error(v.toString())}var h=t.get("sizeRange"),c=t.get("rotationRange"),p=s.getDataExtent("value"),d=Math.PI/180,f=t.get("gridSize");function g(v){var y=v.detail.item;v.detail.drawn&&t.layoutInstance.ondraw&&(v.detail.drawn.gx+=i.x/f,v.detail.drawn.gy+=i.y/f,t.layoutInstance.ondraw(y[0],y[1],y[2],v.detail.drawn))}Ju(l,{list:s.mapArray("value",function(v,y){var m=s.getItemModel(y);return[s.getName(y),m.get("textStyle.fontSize",!0)||Ye(v,p,h),y]}).sort(function(v,y){return y[1]-v[1]}),fontFamily:t.get("textStyle.fontFamily")||t.get("emphasis.textStyle.fontFamily")||n.get("textStyle.fontFamily"),fontWeight:t.get("textStyle.fontWeight")||t.get("emphasis.textStyle.fontWeight")||n.get("textStyle.fontWeight"),gridSize:f,ellipticity:i.height/i.width,minRotation:c[0]*d,maxRotation:c[1]*d,clearCanvas:!o,rotateRatio:1,rotationStep:t.get("rotationStep")*d,drawOutOfBound:t.get("drawOutOfBound"),shrinkToFit:t.get("shrinkToFit"),layoutAnimation:t.get("layoutAnimation"),shuffle:!1,shape:t.get("shape")}),l.addEventListener("wordclouddrawn",g),t.layoutInstance&&t.layoutInstance.dispose(),t.layoutInstance={ondraw:null,dispose:function(){l.removeEventListener("wordclouddrawn",g),l.addEventListener("wordclouddrawn",function(v){v.preventDefault()})}}})}),eu(function(n){var e=(n||{}).series;!W(e)&&(e=e?[e]:[]);var t=["shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function i(r){r&&A(t,function(o){r.hasOwnProperty(o)&&(r["text"+ym(o)]=r[o])})}A(e,function(r){if(r&&r.type==="wordCloud"){var o=r.textStyle||{};i(o.normal),i(o.emphasis)}})});let RS;RS=HP({name:"EChart",__name:"Echart",props:{options:{type:Object,required:!0},width:NS.oneOfType([Number,String]).def(""),height:NS.oneOfType([Number,String]).def("500px")},setup(n){const{getPrefixCls:e,variables:t}=QP(),i=e("echart"),r=WP(),o=n,a=$u(()=>r.getIsDark),s=$u(()=>!!Cn(a)||"auto"),l=$u(()=>Object.assign(o.options,{darkMode:Cn(s)})),u=zS();let h=null;const c=zS(),p=$u(()=>({width:BS(o.width)?o.width:`${o.width}px`,height:BS(o.height)?o.height:`${o.height}px`}));YP(()=>l.value,g=>{h&&(h==null||h.setOption(g))},{deep:!0});const d=UP(()=>{h&&h.resize()},100),f=async g=>{g.propertyName==="width"&&d()};return XP(()=>{Cn(u)&&o.options&&(h=Yf.init(Cn(u)),h==null||h.setOption(Cn(l))),window.addEventListener("resize",d),c.value=document.getElementsByClassName(`${t.namespace}-layout-content`)[0],Cn(c)&&Cn(c).addEventListener("transitionend",f)}),jP(()=>{window.removeEventListener("resize",d),Cn(c)&&Cn(c).removeEventListener("transitionend",f)}),ZP(()=>{h&&h.resize()}),(g,v)=>(qP(),KP("div",{ref_key:"elRef",ref:u,class:JP([g.$attrs.class,Cn(i)]),style:$P(Cn(p))},null,6))}}),VS=eO(RS,[["__file","D:/zx/mall-newfeifan-zx-business/src/components/Echart/src/Echart.vue"]])});export{VS as _,nO as __tla,Yf as e};