/*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */var yh=function(r,t){return yh=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,i){e.__proto__=i}||function(e,i){for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])},yh(r,t)};function E(r,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");yh(r,t);function e(){this.constructor=r}r.prototype=t===null?Object.create(t):(e.prototype=t.prototype,new e)}var Mw=(function(){function r(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return r})(),Dw=(function(){function r(){this.browser=new Mw,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!="undefined"}return r})(),tt=new Dw;typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(tt.wxa=!0,tt.touchEventsSupported=!0):typeof document=="undefined"&&typeof self!="undefined"?tt.worker=!0:!tt.hasGlobalWindow||"Deno"in window?(tt.node=!0,tt.svgSupported=!0):Lw(navigator.userAgent,tt);function Lw(r,t){var e=t.browser,i=r.match(/Firefox\/([\d.]+)/),n=r.match(/MSIE\s([\d.]+)/)||r.match(/Trident\/.+?rv:(([\d.]+))/),a=r.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(r);i&&(e.firefox=!0,e.version=i[1]),n&&(e.ie=!0,e.version=n[1]),a&&(e.edge=!0,e.version=a[1],e.newEdge=+a[1].split(".")[0]>18),o&&(e.weChat=!0),t.svgSupported=typeof SVGRect!="undefined",t.touchEventsSupported="ontouchstart"in window&&!e.ie&&!e.edge,t.pointerEventsSupported="onpointerdown"in window&&(e.edge||e.ie&&+e.version>=11),t.domSupported=typeof document!="undefined";var s=document.documentElement.style;t.transform3dSupported=(e.ie&&"transition"in s||e.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in s)&&!("OTransition"in s),t.transformSupported=t.transform3dSupported||e.ie&&+e.version>=9}var Vv=12,Pw="sans-serif",fn=Vv+"px "+Pw,Iw=20,Rw=100,Ew="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function kw(r){var t={};if(typeof JSON=="undefined")return t;for(var e=0;e=0)s=o*e.length;else for(var l=0;l>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",i[l]+":0",n[u]+":0",i[1-l]+":auto",n[1-u]+":auto",""].join("!important;"),r.appendChild(o),e.push(o)}return e}function aT(r,t,e){for(var i=e?"invTrans":"trans",n=t[i],a=t.srcCoords,o=[],s=[],l=!0,u=0;u<4;u++){var f=r[u].getBoundingClientRect(),h=2*u,c=f.left,v=f.top;o.push(c,v),l=l&&a&&c===a[h]&&v===a[h+1],s.push(r[u].offsetLeft,r[u].offsetTop)}return l&&n?n:(t.srcCoords=o,t[i]=e?Rp(s,o):Rp(o,s))}function c_(r){return r.nodeName.toUpperCase()==="CANVAS"}var oT=/([&<>"'])/g,sT={"&":"&","<":"<",">":">",'"':""","'":"'"};function ne(r){return r==null?"":(r+"").replace(oT,function(t,e){return sT[e]})}var lT=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Eu=[],uT=tt.browser.firefox&&+tt.browser.version.split(".")[0]<39;function bh(r,t,e,i){return e=e||{},i?kp(r,t,e):uT&&t.layerX!=null&&t.layerX!==t.offsetX?(e.zrX=t.layerX,e.zrY=t.layerY):t.offsetX!=null?(e.zrX=t.offsetX,e.zrY=t.offsetY):kp(r,t,e),e}function kp(r,t,e){if(tt.domSupported&&r.getBoundingClientRect){var i=t.clientX,n=t.clientY;if(c_(r)){var a=r.getBoundingClientRect();e.zrX=i-a.left,e.zrY=n-a.top;return}else if(xh(Eu,r,i,n)){e.zrX=Eu[0],e.zrY=Eu[1];return}}e.zrX=e.zrY=0}function qv(r){return r||window.event}function Ie(r,t,e){if(t=qv(t),t.zrX!=null)return t;var i=t.type,n=i&&i.indexOf("touch")>=0;if(n){var o=i!=="touchend"?t.targetTouches[0]:t.changedTouches[0];o&&bh(r,o,t,e)}else{bh(r,t,t,e);var a=fT(t);t.zrDelta=a?a/120:-(t.detail||0)/3}var s=t.button;return t.which==null&&s!==void 0&&lT.test(t.type)&&(t.which=s&1?1:s&2?3:s&4?2:0),t}function fT(r){var t=r.wheelDelta;if(t)return t;var e=r.deltaX,i=r.deltaY;if(e==null||i==null)return t;var n=Math.abs(i!==0?i:e),a=i>0?-1:i<0?1:e>0?-1:1;return 3*n*a}function wh(r,t,e,i){r.addEventListener(t,e,i)}function hT(r,t,e,i){r.removeEventListener(t,e,i)}var Fr=function(r){r.preventDefault(),r.stopPropagation(),r.cancelBubble=!0};function Op(r){return r.which===2||r.which===3}var vT=(function(){function r(){this._track=[]}return r.prototype.recognize=function(t,e,i){return this._doTrack(t,e,i),this._recognize(t)},r.prototype.clear=function(){return this._track.length=0,this},r.prototype._doTrack=function(t,e,i){var n=t.touches;if(n){for(var a={points:[],touches:[],target:e,event:t},o=0,s=n.length;o1&&i&&i.length>1){var a=Bp(i)/Bp(n);!isFinite(a)&&(a=1),t.pinchScale=a;var o=cT(i);return t.pinchX=o[0],t.pinchY=o[1],{type:"pinch",target:r[0].target,event:t}}}}};function xe(){return[1,0,0,1,0,0]}function Fo(r){return r[0]=1,r[1]=0,r[2]=0,r[3]=1,r[4]=0,r[5]=0,r}function $l(r,t){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r[3]=t[3],r[4]=t[4],r[5]=t[5],r}function Sr(r,t,e){var i=t[0]*e[0]+t[2]*e[1],n=t[1]*e[0]+t[3]*e[1],a=t[0]*e[2]+t[2]*e[3],o=t[1]*e[2]+t[3]*e[3],s=t[0]*e[4]+t[2]*e[5]+t[4],l=t[1]*e[4]+t[3]*e[5]+t[5];return r[0]=i,r[1]=n,r[2]=a,r[3]=o,r[4]=s,r[5]=l,r}function Vr(r,t,e){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r[3]=t[3],r[4]=t[4]+e[0],r[5]=t[5]+e[1],r}function mi(r,t,e,i){i===void 0&&(i=[0,0]);var n=t[0],a=t[2],o=t[4],s=t[1],l=t[3],u=t[5],f=Math.sin(e),h=Math.cos(e);return r[0]=n*h+s*f,r[1]=-n*f+s*h,r[2]=a*h+l*f,r[3]=-a*f+h*l,r[4]=h*(o-i[0])+f*(u-i[1])+i[0],r[5]=h*(u-i[1])-f*(o-i[0])+i[1],r}function Kv(r,t,e){var i=e[0],n=e[1];return r[0]=t[0]*i,r[1]=t[1]*n,r[2]=t[2]*i,r[3]=t[3]*n,r[4]=t[4]*i,r[5]=t[5]*n,r}function yn(r,t){var e=t[0],i=t[2],n=t[4],a=t[1],o=t[3],s=t[5],l=e*o-a*i;return l?(l=1/l,r[0]=o*l,r[1]=-a*l,r[2]=-i*l,r[3]=e*l,r[4]=(i*s-o*n)*l,r[5]=(a*n-e*s)*l,r):null}function pT(r){var t=xe();return $l(t,r),t}const dT=Object.freeze(Object.defineProperty({__proto__:null,clone:pT,copy:$l,create:xe,identity:Fo,invert:yn,mul:Sr,rotate:mi,scale:Kv,translate:Vr},Symbol.toStringTag,{value:"Module"}));var et=(function(){function r(t,e){this.x=t||0,this.y=e||0}return r.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this},r.prototype.clone=function(){return new r(this.x,this.y)},r.prototype.set=function(t,e){return this.x=t,this.y=e,this},r.prototype.equal=function(t){return t.x===this.x&&t.y===this.y},r.prototype.add=function(t){return this.x+=t.x,this.y+=t.y,this},r.prototype.scale=function(t){this.x*=t,this.y*=t},r.prototype.scaleAndAdd=function(t,e){this.x+=t.x*e,this.y+=t.y*e},r.prototype.sub=function(t){return this.x-=t.x,this.y-=t.y,this},r.prototype.dot=function(t){return this.x*t.x+this.y*t.y},r.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},r.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},r.prototype.normalize=function(){var t=this.len();return this.x/=t,this.y/=t,this},r.prototype.distance=function(t){var e=this.x-t.x,i=this.y-t.y;return Math.sqrt(e*e+i*i)},r.prototype.distanceSquare=function(t){var e=this.x-t.x,i=this.y-t.y;return e*e+i*i},r.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},r.prototype.transform=function(t){if(t){var e=this.x,i=this.y;return this.x=t[0]*e+t[2]*i+t[4],this.y=t[1]*e+t[3]*i+t[5],this}},r.prototype.toArray=function(t){return t[0]=this.x,t[1]=this.y,t},r.prototype.fromArray=function(t){this.x=t[0],this.y=t[1]},r.set=function(t,e,i){t.x=e,t.y=i},r.copy=function(t,e){t.x=e.x,t.y=e.y},r.len=function(t){return Math.sqrt(t.x*t.x+t.y*t.y)},r.lenSquare=function(t){return t.x*t.x+t.y*t.y},r.dot=function(t,e){return t.x*e.x+t.y*e.y},r.add=function(t,e,i){t.x=e.x+i.x,t.y=e.y+i.y},r.sub=function(t,e,i){t.x=e.x-i.x,t.y=e.y-i.y},r.scale=function(t,e,i){t.x=e.x*i,t.y=e.y*i},r.scaleAndAdd=function(t,e,i,n){t.x=e.x+i.x*n,t.y=e.y+i.y*n},r.lerp=function(t,e,i,n){var a=1-n;t.x=a*e.x+n*i.x,t.y=a*e.y+n*i.y},r})(),jo=Math.min,Qo=Math.max,xi=new et,bi=new et,wi=new et,Ti=new et,ma=new et,_a=new et,st=(function(){function r(t,e,i,n){i<0&&(t=t+i,i=-i),n<0&&(e=e+n,n=-n),this.x=t,this.y=e,this.width=i,this.height=n}return r.prototype.union=function(t){var e=jo(t.x,this.x),i=jo(t.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=Qo(t.x+t.width,this.x+this.width)-e:this.width=t.width,isFinite(this.y)&&isFinite(this.height)?this.height=Qo(t.y+t.height,this.y+this.height)-i:this.height=t.height,this.x=e,this.y=i},r.prototype.applyTransform=function(t){r.applyTransform(this,this,t)},r.prototype.calculateTransform=function(t){var e=this,i=t.width/e.width,n=t.height/e.height,a=xe();return Vr(a,a,[-e.x,-e.y]),Kv(a,a,[i,n]),Vr(a,a,[t.x,t.y]),a},r.prototype.intersect=function(t,e){if(!t)return!1;t instanceof r||(t=r.create(t));var i=this,n=i.x,a=i.x+i.width,o=i.y,s=i.y+i.height,l=t.x,u=t.x+t.width,f=t.y,h=t.y+t.height,c=!(ap&&(p=_,dp&&(p=S,y=i.x&&t<=i.x+i.width&&e>=i.y&&e<=i.y+i.height},r.prototype.clone=function(){return new r(this.x,this.y,this.width,this.height)},r.prototype.copy=function(t){r.copy(this,t)},r.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},r.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},r.prototype.isZero=function(){return this.width===0||this.height===0},r.create=function(t){return new r(t.x,t.y,t.width,t.height)},r.copy=function(t,e){t.x=e.x,t.y=e.y,t.width=e.width,t.height=e.height},r.applyTransform=function(t,e,i){if(!i){t!==e&&r.copy(t,e);return}if(i[1]<1e-5&&i[1]>-1e-5&&i[2]<1e-5&&i[2]>-1e-5){var n=i[0],a=i[3],o=i[4],s=i[5];t.x=e.x*n+o,t.y=e.y*a+s,t.width=e.width*n,t.height=e.height*a,t.width<0&&(t.x+=t.width,t.width=-t.width),t.height<0&&(t.y+=t.height,t.height=-t.height);return}xi.x=wi.x=e.x,xi.y=Ti.y=e.y,bi.x=Ti.x=e.x+e.width,bi.y=wi.y=e.y+e.height,xi.transform(i),Ti.transform(i),bi.transform(i),wi.transform(i),t.x=jo(xi.x,bi.x,wi.x,Ti.x),t.y=jo(xi.y,bi.y,wi.y,Ti.y);var l=Qo(xi.x,bi.x,wi.x,Ti.x),u=Qo(xi.y,bi.y,wi.y,Ti.y);t.width=l-t.x,t.height=u-t.y},r})(),p_="silent";function gT(r,t,e){return{type:r,event:e,target:t.target,topTarget:t.topTarget,cancelBubble:!1,offsetX:e.zrX,offsetY:e.zrY,gestureEvent:e.gestureEvent,pinchX:e.pinchX,pinchY:e.pinchY,pinchScale:e.pinchScale,wheelDelta:e.zrDelta,zrByTouch:e.zrByTouch,which:e.which,stop:yT}}function yT(){Fr(this.event)}var mT=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.handler=null,e}return t.prototype.dispose=function(){},t.prototype.setCursor=function(){},t})(Ge),Sa=(function(){function r(t,e){this.x=t,this.y=e}return r})(),_T=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],Ou=new st(0,0,0,0),d_=(function(r){E(t,r);function t(e,i,n,a,o){var s=r.call(this)||this;return s._hovered=new Sa(0,0),s.storage=e,s.painter=i,s.painterRoot=a,s._pointerSize=o,n=n||new mT,s.proxy=null,s.setHandlerProxy(n),s._draggingMgr=new eT(s),s}return t.prototype.setHandlerProxy=function(e){this.proxy&&this.proxy.dispose(),e&&(w(_T,function(i){e.on&&e.on(i,this[i],this)},this),e.handler=this),this.proxy=e},t.prototype.mousemove=function(e){var i=e.zrX,n=e.zrY,a=g_(this,i,n),o=this._hovered,s=o.target;s&&!s.__zr&&(o=this.findHover(o.x,o.y),s=o.target);var l=this._hovered=a?new Sa(i,n):this.findHover(i,n),u=l.target,f=this.proxy;f.setCursor&&f.setCursor(u?u.cursor:"default"),s&&u!==s&&this.dispatchToElement(o,"mouseout",e),this.dispatchToElement(l,"mousemove",e),u&&u!==s&&this.dispatchToElement(l,"mouseover",e)},t.prototype.mouseout=function(e){var i=e.zrEventControl;i!=="only_globalout"&&this.dispatchToElement(this._hovered,"mouseout",e),i!=="no_globalout"&&this.trigger("globalout",{type:"globalout",event:e})},t.prototype.resize=function(){this._hovered=new Sa(0,0)},t.prototype.dispatch=function(e,i){var n=this[e];n&&n.call(this,i)},t.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},t.prototype.setCursorStyle=function(e){var i=this.proxy;i.setCursor&&i.setCursor(e)},t.prototype.dispatchToElement=function(e,i,n){e=e||{};var a=e.target;if(!(a&&a.silent)){for(var o="on"+i,s=gT(i,e,n);a&&(a[o]&&(s.cancelBubble=!!a[o].call(a,s)),a.trigger(i,s),a=a.__hostTarget?a.__hostTarget:a.parent,!s.cancelBubble););s.cancelBubble||(this.trigger(i,s),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(l){typeof l[o]=="function"&&l[o].call(l,s),l.trigger&&l.trigger(i,s)}))}},t.prototype.findHover=function(e,i,n){var a=this.storage.getDisplayList(),o=new Sa(e,i);if(Np(a,o,e,i,n),this._pointerSize&&!o.target){for(var s=[],l=this._pointerSize,u=l/2,f=new st(e-u,i-u,l,l),h=a.length-1;h>=0;h--){var c=a[h];c!==n&&!c.ignore&&!c.ignoreCoarsePointer&&(!c.parent||!c.parent.ignoreCoarsePointer)&&(Ou.copy(c.getBoundingRect()),c.transform&&Ou.applyTransform(c.transform),Ou.intersect(f)&&s.push(c))}if(s.length)for(var v=4,p=Math.PI/12,d=Math.PI*2,g=0;g4)return;this._downPoint=null}this.dispatchToElement(a,r,t)}});function ST(r,t,e){if(r[r.rectHover?"rectContain":"contain"](t,e)){for(var i=r,n=void 0,a=!1;i;){if(i.ignoreClip&&(a=!0),!a){var o=i.getClipPath();if(o&&!o.contain(t,e))return!1}i.silent&&(n=!0);var s=i.__hostTarget;i=s||i.parent}return n?p_:!0}return!1}function Np(r,t,e,i,n){for(var a=r.length-1;a>=0;a--){var o=r[a],s=void 0;if(o!==n&&!o.ignore&&(s=ST(o,e,i))&&(!t.topTarget&&(t.topTarget=o),s!==p_)){t.target=o;break}}}function g_(r,t,e){var i=r.painter;return t<0||t>i.getWidth()||e<0||e>i.getHeight()}var y_=32,xa=7;function xT(r){for(var t=0;r>=y_;)t|=r&1,r>>=1;return r+t}function zp(r,t,e,i){var n=t+1;if(n===e)return 1;if(i(r[n++],r[t])<0){for(;n=0;)n++;return n-t}function bT(r,t,e){for(e--;t>>1,n(a,r[l])<0?s=l:o=l+1;var u=i-o;switch(u){case 3:r[o+3]=r[o+2];case 2:r[o+2]=r[o+1];case 1:r[o+1]=r[o];break;default:for(;u>0;)r[o+u]=r[o+u-1],u--}r[o]=a}}function Bu(r,t,e,i,n,a){var o=0,s=0,l=1;if(a(r,t[e+n])>0){for(s=i-n;l0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=n,l+=n}else{for(s=n+1;ls&&(l=s);var u=o;o=n-l,l=n-u}for(o++;o>>1);a(r,t[e+f])>0?o=f+1:l=f}return l}function Nu(r,t,e,i,n,a){var o=0,s=0,l=1;if(a(r,t[e+n])<0){for(s=n+1;ls&&(l=s);var u=o;o=n-l,l=n-u}else{for(s=i-n;l=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=n,l+=n}for(o++;o>>1);a(r,t[e+f])<0?l=f:o=f+1}return l}function wT(r,t){var e=xa,i,n,a=0,o=[];i=[],n=[];function s(v,p){i[a]=v,n[a]=p,a+=1}function l(){for(;a>1;){var v=a-2;if(v>=1&&n[v-1]<=n[v]+n[v+1]||v>=2&&n[v-2]<=n[v]+n[v-1])n[v-1]n[v+1])break;f(v)}}function u(){for(;a>1;){var v=a-2;v>0&&n[v-1]=xa||T>=xa);if(C)break;b<0&&(b=0),b+=2}if(e=b,e<1&&(e=1),p===1){for(y=0;y=0;y--)r[x+y]=r[b+y];r[S]=o[_];return}for(var T=e;;){var C=0,A=0,M=!1;do if(t(o[_],r[m])<0){if(r[S--]=r[m--],C++,A=0,--p===0){M=!0;break}}else if(r[S--]=o[_--],A++,C=0,--g===1){M=!0;break}while((C|A)=0;y--)r[x+y]=r[b+y];if(p===0){M=!0;break}}if(r[S--]=o[_--],--g===1){M=!0;break}if(A=g-Bu(r[m],o,0,g,g-1,t),A!==0){for(S-=A,_-=A,g-=A,x=S+1,b=_+1,y=0;y=xa||A>=xa);if(M)break;T<0&&(T=0),T+=2}if(e=T,e<1&&(e=1),g===1){for(S-=p,m-=p,x=S+1,b=m+1,y=p-1;y>=0;y--)r[x+y]=r[b+y];r[S]=o[_]}else{if(g===0)throw new Error;for(b=S-(g-1),y=0;ys&&(l=s),Fp(r,e,e+l,e+a,t),a=l}o.pushRun(e,a),o.mergeRuns(),n-=a,e+=a}while(n!==0);o.forceMergeRuns()}}var Se=1,Ua=2,Vn=4,Vp=!1;function zu(){Vp||(Vp=!0)}function Gp(r,t){return r.zlevel===t.zlevel?r.z===t.z?r.z2-t.z2:r.z-t.z:r.zlevel-t.zlevel}var TT=(function(){function r(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=Gp}return r.prototype.traverse=function(t,e){for(var i=0;i0&&(f.__clipPaths=[]),isNaN(f.z)&&(zu(),f.z=0),isNaN(f.z2)&&(zu(),f.z2=0),isNaN(f.zlevel)&&(zu(),f.zlevel=0),this._displayList[this._displayListLen++]=f}var h=t.getDecalElement&&t.getDecalElement();h&&this._updateAndAddDisplayable(h,e,i);var c=t.getTextGuideLine();c&&this._updateAndAddDisplayable(c,e,i);var v=t.getTextContent();v&&this._updateAndAddDisplayable(v,e,i)}},r.prototype.addRoot=function(t){t.__zr&&t.__zr.storage===this||this._roots.push(t)},r.prototype.delRoot=function(t){if(t instanceof Array){for(var e=0,i=t.length;e=0&&this._roots.splice(n,1)},r.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},r.prototype.getRoots=function(){return this._roots},r.prototype.dispose=function(){this._displayList=null,this._roots=null},r})(),hl;hl=tt.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(r){return setTimeout(r,16)};var to={linear:function(r){return r},quadraticIn:function(r){return r*r},quadraticOut:function(r){return r*(2-r)},quadraticInOut:function(r){return(r*=2)<1?.5*r*r:-.5*(--r*(r-2)-1)},cubicIn:function(r){return r*r*r},cubicOut:function(r){return--r*r*r+1},cubicInOut:function(r){return(r*=2)<1?.5*r*r*r:.5*((r-=2)*r*r+2)},quarticIn:function(r){return r*r*r*r},quarticOut:function(r){return 1- --r*r*r*r},quarticInOut:function(r){return(r*=2)<1?.5*r*r*r*r:-.5*((r-=2)*r*r*r-2)},quinticIn:function(r){return r*r*r*r*r},quinticOut:function(r){return--r*r*r*r*r+1},quinticInOut:function(r){return(r*=2)<1?.5*r*r*r*r*r:.5*((r-=2)*r*r*r*r+2)},sinusoidalIn:function(r){return 1-Math.cos(r*Math.PI/2)},sinusoidalOut:function(r){return Math.sin(r*Math.PI/2)},sinusoidalInOut:function(r){return .5*(1-Math.cos(Math.PI*r))},exponentialIn:function(r){return r===0?0:Math.pow(1024,r-1)},exponentialOut:function(r){return r===1?1:1-Math.pow(2,-10*r)},exponentialInOut:function(r){return r===0?0:r===1?1:(r*=2)<1?.5*Math.pow(1024,r-1):.5*(-Math.pow(2,-10*(r-1))+2)},circularIn:function(r){return 1-Math.sqrt(1-r*r)},circularOut:function(r){return Math.sqrt(1- --r*r)},circularInOut:function(r){return(r*=2)<1?-.5*(Math.sqrt(1-r*r)-1):.5*(Math.sqrt(1-(r-=2)*r)+1)},elasticIn:function(r){var t,e=.1,i=.4;return r===0?0:r===1?1:(!e||e<1?(e=1,t=i/4):t=i*Math.asin(1/e)/(2*Math.PI),-(e*Math.pow(2,10*(r-=1))*Math.sin((r-t)*(2*Math.PI)/i)))},elasticOut:function(r){var t,e=.1,i=.4;return r===0?0:r===1?1:(!e||e<1?(e=1,t=i/4):t=i*Math.asin(1/e)/(2*Math.PI),e*Math.pow(2,-10*r)*Math.sin((r-t)*(2*Math.PI)/i)+1)},elasticInOut:function(r){var t,e=.1,i=.4;return r===0?0:r===1?1:(!e||e<1?(e=1,t=i/4):t=i*Math.asin(1/e)/(2*Math.PI),(r*=2)<1?-.5*(e*Math.pow(2,10*(r-=1))*Math.sin((r-t)*(2*Math.PI)/i)):e*Math.pow(2,-10*(r-=1))*Math.sin((r-t)*(2*Math.PI)/i)*.5+1)},backIn:function(r){var t=1.70158;return r*r*((t+1)*r-t)},backOut:function(r){var t=1.70158;return--r*r*((t+1)*r+t)+1},backInOut:function(r){var t=2.5949095;return(r*=2)<1?.5*(r*r*((t+1)*r-t)):.5*((r-=2)*r*((t+1)*r+t)+2)},bounceIn:function(r){return 1-to.bounceOut(1-r)},bounceOut:function(r){return r<1/2.75?7.5625*r*r:r<2/2.75?7.5625*(r-=1.5/2.75)*r+.75:r<2.5/2.75?7.5625*(r-=2.25/2.75)*r+.9375:7.5625*(r-=2.625/2.75)*r+.984375},bounceInOut:function(r){return r<.5?to.bounceIn(r*2)*.5:to.bounceOut(r*2-1)*.5+.5}},ts=Math.pow,fi=Math.sqrt,vl=1e-8,m_=1e-4,Hp=fi(3),es=1/3,pr=gn(),Oe=gn(),Zn=gn();function ai(r){return r>-vl&&rvl||r<-vl}function Et(r,t,e,i,n){var a=1-n;return a*a*(a*r+3*n*t)+n*n*(n*i+3*a*e)}function Wp(r,t,e,i,n){var a=1-n;return 3*(((t-r)*a+2*(e-t)*n)*a+(i-e)*n*n)}function cl(r,t,e,i,n,a){var o=i+3*(t-e)-r,s=3*(e-t*2+r),l=3*(t-r),u=r-n,f=s*s-3*o*l,h=s*l-9*o*u,c=l*l-3*s*u,v=0;if(ai(f)&&ai(h))if(ai(s))a[0]=0;else{var p=-l/s;p>=0&&p<=1&&(a[v++]=p)}else{var d=h*h-4*f*c;if(ai(d)){var g=h/f,p=-s/o+g,y=-g/2;p>=0&&p<=1&&(a[v++]=p),y>=0&&y<=1&&(a[v++]=y)}else if(d>0){var m=fi(d),_=f*s+1.5*o*(-h+m),S=f*s+1.5*o*(-h-m);_<0?_=-ts(-_,es):_=ts(_,es),S<0?S=-ts(-S,es):S=ts(S,es);var p=(-s-(_+S))/(3*o);p>=0&&p<=1&&(a[v++]=p)}else{var b=(2*f*s-3*o*h)/(2*fi(f*f*f)),x=Math.acos(b)/3,T=fi(f),C=Math.cos(x),p=(-s-2*T*C)/(3*o),y=(-s+T*(C+Hp*Math.sin(x)))/(3*o),A=(-s+T*(C-Hp*Math.sin(x)))/(3*o);p>=0&&p<=1&&(a[v++]=p),y>=0&&y<=1&&(a[v++]=y),A>=0&&A<=1&&(a[v++]=A)}}return v}function S_(r,t,e,i,n){var a=6*e-12*t+6*r,o=9*t+3*i-3*r-9*e,s=3*t-3*r,l=0;if(ai(o)){if(__(a)){var u=-s/a;u>=0&&u<=1&&(n[l++]=u)}}else{var f=a*a-4*o*s;if(ai(f))n[0]=-a/(2*o);else if(f>0){var h=fi(f),u=(-a+h)/(2*o),c=(-a-h)/(2*o);u>=0&&u<=1&&(n[l++]=u),c>=0&&c<=1&&(n[l++]=c)}}return l}function pl(r,t,e,i,n,a){var o=(t-r)*n+r,s=(e-t)*n+t,l=(i-e)*n+e,u=(s-o)*n+o,f=(l-s)*n+s,h=(f-u)*n+u;a[0]=r,a[1]=o,a[2]=u,a[3]=h,a[4]=h,a[5]=f,a[6]=l,a[7]=i}function x_(r,t,e,i,n,a,o,s,l,u,f){var h,c=.005,v=1/0,p,d,g,y;pr[0]=l,pr[1]=u;for(var m=0;m<1;m+=.05)Oe[0]=Et(r,e,n,o,m),Oe[1]=Et(t,i,a,s,m),g=en(pr,Oe),g=0&&g=0&&u<=1&&(n[l++]=u)}}else{var f=o*o-4*a*s;if(ai(f)){var u=-o/(2*a);u>=0&&u<=1&&(n[l++]=u)}else if(f>0){var h=fi(f),u=(-o+h)/(2*a),c=(-o-h)/(2*a);u>=0&&u<=1&&(n[l++]=u),c>=0&&c<=1&&(n[l++]=c)}}return l}function b_(r,t,e){var i=r+e-2*t;return i===0?.5:(r-t)/i}function dl(r,t,e,i,n){var a=(t-r)*i+r,o=(e-t)*i+t,s=(o-a)*i+a;n[0]=r,n[1]=a,n[2]=s,n[3]=s,n[4]=o,n[5]=e}function w_(r,t,e,i,n,a,o,s,l){var u,f=.005,h=1/0;pr[0]=o,pr[1]=s;for(var c=0;c<1;c+=.05){Oe[0]=Zt(r,e,n,c),Oe[1]=Zt(t,i,a,c);var v=en(pr,Oe);v=0&&v=1?1:cl(0,i,a,1,l,s)&&Et(0,n,o,1,s[0])}}}var LT=(function(){function r(t){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=t.life||1e3,this._delay=t.delay||0,this.loop=t.loop||!1,this.onframe=t.onframe||Vt,this.ondestroy=t.ondestroy||Vt,this.onrestart=t.onrestart||Vt,t.easing&&this.setEasing(t.easing)}return r.prototype.step=function(t,e){if(this._inited||(this._startTime=t+this._delay,this._inited=!0),this._paused){this._pausedTime+=e;return}var i=this._life,n=t-this._startTime-this._pausedTime,a=n/i;a<0&&(a=0),a=Math.min(a,1);var o=this.easingFunc,s=o?o(a):a;if(this.onframe(s),a===1)if(this.loop){var l=n%i;this._startTime=t-l,this._pausedTime=0,this.onrestart()}else return!0;return!1},r.prototype.pause=function(){this._paused=!0},r.prototype.resume=function(){this._paused=!1},r.prototype.setEasing=function(t){this.easing=t,this.easingFunc=j(t)?t:to[t]||T_(t)},r})(),C_=(function(){function r(t){this.value=t}return r})(),PT=(function(){function r(){this._len=0}return r.prototype.insert=function(t){var e=new C_(t);return this.insertEntry(e),e},r.prototype.insertEntry=function(t){this.head?(this.tail.next=t,t.prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},r.prototype.remove=function(t){var e=t.prev,i=t.next;e?e.next=i:this.head=i,i?i.prev=e:this.tail=e,t.next=t.prev=null,this._len--},r.prototype.len=function(){return this._len},r.prototype.clear=function(){this.head=this.tail=null,this._len=0},r})(),Vo=(function(){function r(t){this._list=new PT,this._maxSize=10,this._map={},this._maxSize=t}return r.prototype.put=function(t,e){var i=this._list,n=this._map,a=null;if(n[t]==null){var o=i.len(),s=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var l=i.head;i.remove(l),delete n[l.key],a=l.value,this._lastRemovedEntry=l}s?s.value=e:s=new C_(e),s.key=t,i.insertEntry(s),n[t]=s}return a},r.prototype.get=function(t){var e=this._map[t],i=this._list;if(e!=null)return e!==i.tail&&(i.remove(e),i.insertEntry(e)),e.value},r.prototype.clear=function(){this._list.clear(),this._map={}},r.prototype.len=function(){return this._list.len()},r})(),Up={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 je(r){return r=Math.round(r),r<0?0:r>255?255:r}function IT(r){return r=Math.round(r),r<0?0:r>360?360:r}function go(r){return r<0?0:r>1?1:r}function Fu(r){var t=r;return t.length&&t.charAt(t.length-1)==="%"?je(parseFloat(t)/100*255):je(parseInt(t,10))}function rn(r){var t=r;return t.length&&t.charAt(t.length-1)==="%"?go(parseFloat(t)/100):go(parseFloat(t))}function Vu(r,t,e){return e<0?e+=1:e>1&&(e-=1),e*6<1?r+(t-r)*e*6:e*2<1?t:e*3<2?r+(t-r)*(2/3-e)*6:r}function oi(r,t,e){return r+(t-r)*e}function Pe(r,t,e,i,n){return r[0]=t,r[1]=e,r[2]=i,r[3]=n,r}function Th(r,t){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r[3]=t[3],r}var A_=new Vo(20),rs=null;function wn(r,t){rs&&Th(rs,t),rs=A_.put(r,rs||t.slice())}function oe(r,t){if(r){t=t||[];var e=A_.get(r);if(e)return Th(t,e);r=r+"";var i=r.replace(/ /g,"").toLowerCase();if(i in Up)return Th(t,Up[i]),wn(r,t),t;var n=i.length;if(i.charAt(0)==="#"){if(n===4||n===5){var a=parseInt(i.slice(1,4),16);if(!(a>=0&&a<=4095)){Pe(t,0,0,0,1);return}return Pe(t,(a&3840)>>4|(a&3840)>>8,a&240|(a&240)>>4,a&15|(a&15)<<4,n===5?parseInt(i.slice(4),16)/15:1),wn(r,t),t}else if(n===7||n===9){var a=parseInt(i.slice(1,7),16);if(!(a>=0&&a<=16777215)){Pe(t,0,0,0,1);return}return Pe(t,(a&16711680)>>16,(a&65280)>>8,a&255,n===9?parseInt(i.slice(7),16)/255:1),wn(r,t),t}return}var o=i.indexOf("("),s=i.indexOf(")");if(o!==-1&&s+1===n){var l=i.substr(0,o),u=i.substr(o+1,s-(o+1)).split(","),f=1;switch(l){case"rgba":if(u.length!==4)return u.length===3?Pe(t,+u[0],+u[1],+u[2],1):Pe(t,0,0,0,1);f=rn(u.pop());case"rgb":if(u.length>=3)return Pe(t,Fu(u[0]),Fu(u[1]),Fu(u[2]),u.length===3?f:rn(u[3])),wn(r,t),t;Pe(t,0,0,0,1);return;case"hsla":if(u.length!==4){Pe(t,0,0,0,1);return}return u[3]=rn(u[3]),Ch(u,t),wn(r,t),t;case"hsl":if(u.length!==3){Pe(t,0,0,0,1);return}return Ch(u,t),wn(r,t),t;default:return}}Pe(t,0,0,0,1)}}function Ch(r,t){var e=(parseFloat(r[0])%360+360)%360/360,i=rn(r[1]),n=rn(r[2]),a=n<=.5?n*(i+1):n+i-n*i,o=n*2-a;return t=t||[],Pe(t,je(Vu(o,a,e+1/3)*255),je(Vu(o,a,e)*255),je(Vu(o,a,e-1/3)*255),1),r.length===4&&(t[3]=r[3]),t}function RT(r){if(r){var t=r[0]/255,e=r[1]/255,i=r[2]/255,n=Math.min(t,e,i),a=Math.max(t,e,i),o=a-n,s=(a+n)/2,l,u;if(o===0)l=0,u=0;else{s<.5?u=o/(a+n):u=o/(2-a-n);var f=((a-t)/6+o/2)/o,h=((a-e)/6+o/2)/o,c=((a-i)/6+o/2)/o;t===a?l=c-h:e===a?l=1/3+f-c:i===a&&(l=2/3+h-f),l<0&&(l+=1),l>1&&(l-=1)}var v=[l*360,u,s];return r[3]!=null&&v.push(r[3]),v}}function Ah(r,t){var e=oe(r);if(e){for(var i=0;i<3;i++)t<0?e[i]=e[i]*(1-t)|0:e[i]=(255-e[i])*t+e[i]|0,e[i]>255?e[i]=255:e[i]<0&&(e[i]=0);return Qe(e,e.length===4?"rgba":"rgb")}}function ET(r){var t=oe(r);if(t)return((1<<24)+(t[0]<<16)+(t[1]<<8)+ +t[2]).toString(16).slice(1)}function eo(r,t,e){if(!(!(t&&t.length)||!(r>=0&&r<=1))){e=e||[];var i=r*(t.length-1),n=Math.floor(i),a=Math.ceil(i),o=t[n],s=t[a],l=i-n;return e[0]=je(oi(o[0],s[0],l)),e[1]=je(oi(o[1],s[1],l)),e[2]=je(oi(o[2],s[2],l)),e[3]=go(oi(o[3],s[3],l)),e}}var kT=eo;function Jv(r,t,e){if(!(!(t&&t.length)||!(r>=0&&r<=1))){var i=r*(t.length-1),n=Math.floor(i),a=Math.ceil(i),o=oe(t[n]),s=oe(t[a]),l=i-n,u=Qe([je(oi(o[0],s[0],l)),je(oi(o[1],s[1],l)),je(oi(o[2],s[2],l)),go(oi(o[3],s[3],l))],"rgba");return e?{color:u,leftIndex:n,rightIndex:a,value:i}:u}}var OT=Jv;function Zs(r,t,e,i){var n=oe(r);if(r)return n=RT(n),t!=null&&(n[0]=IT(t)),e!=null&&(n[1]=rn(e)),i!=null&&(n[2]=rn(i)),Qe(Ch(n),"rgba")}function M_(r,t){var e=oe(r);if(e&&t!=null)return e[3]=go(t),Qe(e,"rgba")}function Qe(r,t){if(!(!r||!r.length)){var e=r[0]+","+r[1]+","+r[2];return(t==="rgba"||t==="hsva"||t==="hsla")&&(e+=","+r[3]),t+"("+e+")"}}function yo(r,t){var e=oe(r);return e?(.299*e[0]+.587*e[1]+.114*e[2])*e[3]/255+(1-e[3])*t:0}function BT(){return Qe([Math.round(Math.random()*255),Math.round(Math.random()*255),Math.round(Math.random()*255)],"rgb")}var Xp=new Vo(100);function Mh(r){if(G(r)){var t=Xp.get(r);return t||(t=Ah(r,-.1),Xp.put(r,t)),t}else if(No(r)){var e=O({},r);return e.colorStops=F(r.colorStops,function(i){return{offset:i.offset,color:Ah(i.color,-.1)}}),e}return r}const NT=Object.freeze(Object.defineProperty({__proto__:null,fastLerp:eo,fastMapToColor:kT,lerp:Jv,lift:Ah,liftColor:Mh,lum:yo,mapToColor:OT,modifyAlpha:M_,modifyHSL:Zs,parse:oe,random:BT,stringify:Qe,toHex:ET},Symbol.toStringTag,{value:"Module"}));var gl=Math.round;function ZN(r){var t;if(!r||r==="transparent")r="none";else if(typeof r=="string"&&r.indexOf("rgba")>-1){var e=oe(r);e&&(r="rgb("+e[0]+","+e[1]+","+e[2]+")",t=e[3])}return{color:r,opacity:t==null?1:t}}var Zp=1e-4;function $N(r){return r-Zp}function is(r){return gl(r*1e3)/1e3}function $p(r){return gl(r*1e4)/1e4}function qN(r){return"matrix("+is(r[0])+","+is(r[1])+","+is(r[2])+","+is(r[3])+","+$p(r[4])+","+$p(r[5])+")"}var KN={left:"start",right:"end",center:"middle",middle:"middle"};function JN(r,t,e){return e==="top"?r+=t/2:e==="bottom"&&(r-=t/2),r}function jN(r){return r&&(r.shadowBlur||r.shadowOffsetX||r.shadowOffsetY)}function QN(r){var t=r.style,e=r.getGlobalScale();return[t.shadowColor,(t.shadowBlur||0).toFixed(2),(t.shadowOffsetX||0).toFixed(2),(t.shadowOffsetY||0).toFixed(2),e[0],e[1]].join(",")}function zT(r){return r&&!!r.image}function FT(r){return r&&!!r.svgElement}function tz(r){return zT(r)||FT(r)}function VT(r){return r.type==="linear"}function GT(r){return r.type==="radial"}function ez(r){return r&&(r.type==="linear"||r.type==="radial")}function rz(r){return"url(#"+r+")"}function iz(r){var t=r.getGlobalScale(),e=Math.max(t[0],t[1]);return Math.max(Math.ceil(Math.log(e)/Math.log(10)),1)}function nz(r){var t=r.x||0,e=r.y||0,i=(r.rotation||0)*Qa,n=rt(r.scaleX,1),a=rt(r.scaleY,1),o=r.skewX||0,s=r.skewY||0,l=[];return(t||e)&&l.push("translate("+t+"px,"+e+"px)"),i&&l.push("rotate("+i+")"),(n!==1||a!==1)&&l.push("scale("+n+","+a+")"),(o||s)&&l.push("skew("+gl(o*Qa)+"deg, "+gl(s*Qa)+"deg)"),l.join(" ")}var az=(function(){return tt.hasGlobalWindow&&j(window.btoa)?function(r){return window.btoa(unescape(encodeURIComponent(r)))}:typeof Buffer!="undefined"?function(r){return Buffer.from(r).toString("base64")}:function(r){return null}})(),Dh=Array.prototype.slice;function Pr(r,t,e){return(t-r)*e+r}function Gu(r,t,e,i){for(var n=t.length,a=0;ai?t:r,a=Math.min(e,i),o=n[a-1]||{color:[0,0,0,0],offset:0},s=a;so;if(s)i.length=o;else for(var l=a;l=1},r.prototype.getAdditiveTrack=function(){return this._additiveTrack},r.prototype.addKeyframe=function(t,e,i){this._needsSort=!0;var n=this.keyframes,a=n.length,o=!1,s=Kp,l=e;if(jt(e)){var u=UT(e);s=u,(u===1&&!yt(e[0])||u===2&&!yt(e[0][0]))&&(o=!0)}else if(yt(e)&&!co(e))s=as;else if(G(e))if(!isNaN(+e))s=as;else{var f=oe(e);f&&(l=f,s=Xa)}else if(No(e)){var h=O({},l);h.colorStops=F(e.colorStops,function(v){return{offset:v.offset,color:oe(v.color)}}),VT(e)?s=Lh:GT(e)&&(s=Ph),l=h}a===0?this.valType=s:(s!==this.valType||s===Kp)&&(o=!0),this.discrete=this.discrete||o;var c={time:t,value:l,rawValue:e,percent:0};return i&&(c.easing=i,c.easingFunc=j(i)?i:to[i]||T_(i)),n.push(c),c},r.prototype.prepare=function(t,e){var i=this.keyframes;this._needsSort&&i.sort(function(d,g){return d.time-g.time});for(var n=this.valType,a=i.length,o=i[a-1],s=this.discrete,l=os(n),u=Jp(n),f=0;f=0&&!(o[f].percent<=e);f--);f=c(f,s-2)}else{for(f=h;fe);f++);f=c(f-1,s-2)}p=o[f+1],v=o[f]}if(v&&p){this._lastFr=f,this._lastFrP=e;var g=p.percent-v.percent,y=g===0?1:c((e-v.percent)/g,1);p.easingFunc&&(y=p.easingFunc(y));var m=i?this._additiveValue:u?ba:t[l];if((os(a)||u)&&!m&&(m=this._additiveValue=[]),this.discrete)t[l]=y<1?v.rawValue:p.rawValue;else if(os(a))a===qs?Gu(m,v[n],p[n],y):HT(m,v[n],p[n],y);else if(Jp(a)){var _=v[n],S=p[n],b=a===Lh;t[l]={type:b?"linear":"radial",x:Pr(_.x,S.x,y),y:Pr(_.y,S.y,y),colorStops:F(_.colorStops,function(T,C){var A=S.colorStops[C];return{offset:Pr(T.offset,A.offset,y),color:$s(Gu([],T.color,A.color,y))}}),global:S.global},b?(t[l].x2=Pr(_.x2,S.x2,y),t[l].y2=Pr(_.y2,S.y2,y)):t[l].r=Pr(_.r,S.r,y)}else if(u)Gu(m,v[n],p[n],y),i||(t[l]=$s(m));else{var x=Pr(v[n],p[n],y);i?this._additiveValue=x:t[l]=x}i&&this._addToTarget(t)}}},r.prototype._addToTarget=function(t){var e=this.valType,i=this.propName,n=this._additiveValue;e===as?t[i]=t[i]+n:e===Xa?(oe(t[i],ba),ns(ba,ba,n,1),t[i]=$s(ba)):e===qs?ns(t[i],t[i],n,1):e===D_&&qp(t[i],t[i],n,1)},r})(),jv=(function(){function r(t,e,i,n){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=t,this._loop=e,e&&n){Xl("Can' use additive animation on looped animation.");return}this._additiveAnimators=n,this._allowDiscrete=i}return r.prototype.getMaxTime=function(){return this._maxTime},r.prototype.getDelay=function(){return this._delay},r.prototype.getLoop=function(){return this._loop},r.prototype.getTarget=function(){return this._target},r.prototype.changeTarget=function(t){this._target=t},r.prototype.when=function(t,e,i){return this.whenWithKeys(t,e,pt(e),i)},r.prototype.whenWithKeys=function(t,e,i,n){for(var a=this._tracks,o=0;o0&&l.addKeyframe(0,ro(u),n),this._trackKeys.push(s)}l.addKeyframe(t,ro(e[s]),n)}return this._maxTime=Math.max(this._maxTime,t),this},r.prototype.pause=function(){this._clip.pause(),this._paused=!0},r.prototype.resume=function(){this._clip.resume(),this._paused=!1},r.prototype.isPaused=function(){return!!this._paused},r.prototype.duration=function(t){return this._maxTime=t,this._force=!0,this},r.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var t=this._doneCbs;if(t)for(var e=t.length,i=0;i0)){this._started=1;for(var e=this,i=[],n=this._maxTime||0,a=0;a1){var s=o.pop();a.addKeyframe(s.time,t[n]),a.prepare(this._maxTime,a.getAdditiveTrack())}}}},r})();function Wn(){return new Date().getTime()}var ZT=(function(r){E(t,r);function t(e){var i=r.call(this)||this;return i._running=!1,i._time=0,i._pausedTime=0,i._pauseStart=0,i._paused=!1,e=e||{},i.stage=e.stage||{},i}return t.prototype.addClip=function(e){e.animation&&this.removeClip(e),this._head?(this._tail.next=e,e.prev=this._tail,e.next=null,this._tail=e):this._head=this._tail=e,e.animation=this},t.prototype.addAnimator=function(e){e.animation=this;var i=e.getClip();i&&this.addClip(i)},t.prototype.removeClip=function(e){if(e.animation){var i=e.prev,n=e.next;i?i.next=n:this._head=n,n?n.prev=i:this._tail=i,e.next=e.prev=e.animation=null}},t.prototype.removeAnimator=function(e){var i=e.getClip();i&&this.removeClip(i),e.animation=null},t.prototype.update=function(e){for(var i=Wn()-this._pausedTime,n=i-this._time,a=this._head;a;){var o=a.next,s=a.step(i,n);s&&(a.ondestroy(),this.removeClip(a)),a=o}this._time=i,e||(this.trigger("frame",n),this.stage.update&&this.stage.update())},t.prototype._startLoop=function(){var e=this;this._running=!0;function i(){e._running&&(hl(i),!e._paused&&e.update())}hl(i)},t.prototype.start=function(){this._running||(this._time=Wn(),this._pausedTime=0,this._startLoop())},t.prototype.stop=function(){this._running=!1},t.prototype.pause=function(){this._paused||(this._pauseStart=Wn(),this._paused=!0)},t.prototype.resume=function(){this._paused&&(this._pausedTime+=Wn()-this._pauseStart,this._paused=!1)},t.prototype.clear=function(){for(var e=this._head;e;){var i=e.next;e.prev=e.next=e.animation=null,e=i}this._head=this._tail=null},t.prototype.isFinished=function(){return this._head==null},t.prototype.animate=function(e,i){i=i||{},this.start();var n=new jv(e,i.loop);return this.addAnimator(n),n},t})(Ge),$T=300,Hu=tt.domSupported,Wu=(function(){var r=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],t=["touchstart","touchend","touchmove"],e={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},i=F(r,function(n){var a=n.replace("mouse","pointer");return e.hasOwnProperty(a)?a:n});return{mouse:r,touch:t,pointer:i}})(),jp={mouse:["mousemove","mouseup"],pointer:["pointermove","pointerup"]},Qp=!1;function Ih(r){var t=r.pointerType;return t==="pen"||t==="touch"}function qT(r){r.touching=!0,r.touchTimer!=null&&(clearTimeout(r.touchTimer),r.touchTimer=null),r.touchTimer=setTimeout(function(){r.touching=!1,r.touchTimer=null},700)}function Yu(r){r&&(r.zrByTouch=!0)}function KT(r,t){return Ie(r.dom,new JT(r,t),!0)}function L_(r,t){for(var e=t,i=!1;e&&e.nodeType!==9&&!(i=e.domBelongToZr||e!==t&&e===r.painterRoot);)e=e.parentNode;return i}var JT=(function(){function r(t,e){this.stopPropagation=Vt,this.stopImmediatePropagation=Vt,this.preventDefault=Vt,this.type=e.type,this.target=this.currentTarget=t.dom,this.pointerType=e.pointerType,this.clientX=e.clientX,this.clientY=e.clientY}return r})(),Ze={mousedown:function(r){r=Ie(this.dom,r),this.__mayPointerCapture=[r.zrX,r.zrY],this.trigger("mousedown",r)},mousemove:function(r){r=Ie(this.dom,r);var t=this.__mayPointerCapture;t&&(r.zrX!==t[0]||r.zrY!==t[1])&&this.__togglePointerCapture(!0),this.trigger("mousemove",r)},mouseup:function(r){r=Ie(this.dom,r),this.__togglePointerCapture(!1),this.trigger("mouseup",r)},mouseout:function(r){r=Ie(this.dom,r);var t=r.toElement||r.relatedTarget;L_(this,t)||(this.__pointerCapturing&&(r.zrEventControl="no_globalout"),this.trigger("mouseout",r))},wheel:function(r){Qp=!0,r=Ie(this.dom,r),this.trigger("mousewheel",r)},mousewheel:function(r){Qp||(r=Ie(this.dom,r),this.trigger("mousewheel",r))},touchstart:function(r){r=Ie(this.dom,r),Yu(r),this.__lastTouchMoment=new Date,this.handler.processGesture(r,"start"),Ze.mousemove.call(this,r),Ze.mousedown.call(this,r)},touchmove:function(r){r=Ie(this.dom,r),Yu(r),this.handler.processGesture(r,"change"),Ze.mousemove.call(this,r)},touchend:function(r){r=Ie(this.dom,r),Yu(r),this.handler.processGesture(r,"end"),Ze.mouseup.call(this,r),+new Date-+this.__lastTouchMoment<$T&&Ze.click.call(this,r)},pointerdown:function(r){Ze.mousedown.call(this,r)},pointermove:function(r){Ih(r)||Ze.mousemove.call(this,r)},pointerup:function(r){Ze.mouseup.call(this,r)},pointerout:function(r){Ih(r)||Ze.mouseout.call(this,r)}};w(["click","dblclick","contextmenu"],function(r){Ze[r]=function(t){t=Ie(this.dom,t),this.trigger(r,t)}});var Rh={pointermove:function(r){Ih(r)||Rh.mousemove.call(this,r)},pointerup:function(r){Rh.mouseup.call(this,r)},mousemove:function(r){this.trigger("mousemove",r)},mouseup:function(r){var t=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",r),t&&(r.zrEventControl="only_globalout",this.trigger("mouseout",r))}};function jT(r,t){var e=t.domHandlers;tt.pointerEventsSupported?w(Wu.pointer,function(i){Ks(t,i,function(n){e[i].call(r,n)})}):(tt.touchEventsSupported&&w(Wu.touch,function(i){Ks(t,i,function(n){e[i].call(r,n),qT(t)})}),w(Wu.mouse,function(i){Ks(t,i,function(n){n=qv(n),t.touching||e[i].call(r,n)})}))}function QT(r,t){tt.pointerEventsSupported?w(jp.pointer,e):tt.touchEventsSupported||w(jp.mouse,e);function e(i){function n(a){a=qv(a),L_(r,a.target)||(a=KT(r,a),t.domHandlers[i].call(r,a))}Ks(t,i,n,{capture:!0})}}function Ks(r,t,e,i){r.mounted[t]=e,r.listenerOpts[t]=i,wh(r.domTarget,t,e,i)}function Uu(r){var t=r.mounted;for(var e in t)t.hasOwnProperty(e)&&hT(r.domTarget,e,t[e],r.listenerOpts[e]);r.mounted={}}var td=(function(){function r(t,e){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=t,this.domHandlers=e}return r})(),tC=(function(r){E(t,r);function t(e,i){var n=r.call(this)||this;return n.__pointerCapturing=!1,n.dom=e,n.painterRoot=i,n._localHandlerScope=new td(e,Ze),Hu&&(n._globalHandlerScope=new td(document,Rh)),jT(n,n._localHandlerScope),n}return t.prototype.dispose=function(){Uu(this._localHandlerScope),Hu&&Uu(this._globalHandlerScope)},t.prototype.setCursor=function(e){this.dom.style&&(this.dom.style.cursor=e||"default")},t.prototype.__togglePointerCapture=function(e){if(this.__mayPointerCapture=null,Hu&&+this.__pointerCapturing^+e){this.__pointerCapturing=e;var i=this._globalHandlerScope;e?QT(this,i):Uu(i)}},t})(Ge),P_=1;tt.hasGlobalWindow&&(P_=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var yl=P_,Eh=.4,kh="#333",Oh="#ccc",eC="#eee",ed=Fo,rd=5e-5;function Ci(r){return r>rd||r<-rd}var Ai=[],Tn=[],Xu=xe(),Zu=Math.abs,$i=(function(){function r(){}return r.prototype.getLocalTransform=function(t){return r.getLocalTransform(this,t)},r.prototype.setPosition=function(t){this.x=t[0],this.y=t[1]},r.prototype.setScale=function(t){this.scaleX=t[0],this.scaleY=t[1]},r.prototype.setSkew=function(t){this.skewX=t[0],this.skewY=t[1]},r.prototype.setOrigin=function(t){this.originX=t[0],this.originY=t[1]},r.prototype.needLocalTransform=function(){return Ci(this.rotation)||Ci(this.x)||Ci(this.y)||Ci(this.scaleX-1)||Ci(this.scaleY-1)||Ci(this.skewX)||Ci(this.skewY)},r.prototype.updateTransform=function(){var t=this.parent&&this.parent.transform,e=this.needLocalTransform(),i=this.transform;if(!(e||t)){i&&(ed(i),this.invTransform=null);return}i=i||xe(),e?this.getLocalTransform(i):ed(i),t&&(e?Sr(i,t,i):$l(i,t)),this.transform=i,this._resolveGlobalScaleRatio(i)},r.prototype._resolveGlobalScaleRatio=function(t){var e=this.globalScaleRatio;if(e!=null&&e!==1){this.getGlobalScale(Ai);var i=Ai[0]<0?-1:1,n=Ai[1]<0?-1:1,a=((Ai[0]-i)*e+i)/Ai[0]||0,o=((Ai[1]-n)*e+n)/Ai[1]||0;t[0]*=a,t[1]*=a,t[2]*=o,t[3]*=o}this.invTransform=this.invTransform||xe(),yn(this.invTransform,t)},r.prototype.getComputedTransform=function(){for(var t=this,e=[];t;)e.push(t),t=t.parent;for(;t=e.pop();)t.updateTransform();return this.transform},r.prototype.setLocalTransform=function(t){if(t){var e=t[0]*t[0]+t[1]*t[1],i=t[2]*t[2]+t[3]*t[3],n=Math.atan2(t[1],t[0]),a=Math.PI/2+n-Math.atan2(t[3],t[2]);i=Math.sqrt(i)*Math.cos(a),e=Math.sqrt(e),this.skewX=a,this.skewY=0,this.rotation=-n,this.x=+t[4],this.y=+t[5],this.scaleX=e,this.scaleY=i,this.originX=0,this.originY=0}},r.prototype.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(t.invTransform=t.invTransform||xe(),Sr(Tn,t.invTransform,e),e=Tn);var i=this.originX,n=this.originY;(i||n)&&(Xu[4]=i,Xu[5]=n,Sr(Tn,e,Xu),Tn[4]-=i,Tn[5]-=n,e=Tn),this.setLocalTransform(e)}},r.prototype.getGlobalScale=function(t){var e=this.transform;return t=t||[],e?(t[0]=Math.sqrt(e[0]*e[0]+e[1]*e[1]),t[1]=Math.sqrt(e[2]*e[2]+e[3]*e[3]),e[0]<0&&(t[0]=-t[0]),e[3]<0&&(t[1]=-t[1]),t):(t[0]=1,t[1]=1,t)},r.prototype.transformCoordToLocal=function(t,e){var i=[t,e],n=this.invTransform;return n&&Bt(i,i,n),i},r.prototype.transformCoordToGlobal=function(t,e){var i=[t,e],n=this.transform;return n&&Bt(i,i,n),i},r.prototype.getLineScale=function(){var t=this.transform;return t&&Zu(t[0]-1)>1e-10&&Zu(t[3]-1)>1e-10?Math.sqrt(Zu(t[0]*t[3]-t[2]*t[1])):1},r.prototype.copyTransform=function(t){rC(this,t)},r.getLocalTransform=function(t,e){e=e||[];var i=t.originX||0,n=t.originY||0,a=t.scaleX,o=t.scaleY,s=t.anchorX,l=t.anchorY,u=t.rotation||0,f=t.x,h=t.y,c=t.skewX?Math.tan(t.skewX):0,v=t.skewY?Math.tan(-t.skewY):0;if(i||n||s||l){var p=i+s,d=n+l;e[4]=-p*a-c*d*o,e[5]=-d*o-v*p*a}else e[4]=e[5]=0;return e[0]=a,e[3]=o,e[1]=v*a,e[2]=c*o,u&&mi(e,e,u),e[4]+=i+f,e[5]+=n+h,e},r.initDefaultProps=(function(){var t=r.prototype;t.scaleX=t.scaleY=t.globalScaleRatio=1,t.x=t.y=t.originX=t.originY=t.skewX=t.skewY=t.rotation=t.anchorX=t.anchorY=0})(),r})(),xr=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function rC(r,t){for(var e=0;e=0?parseFloat(r)/100*t:parseFloat(r):r}function ml(r,t,e){var i=t.position||"inside",n=t.distance!=null?t.distance:5,a=e.height,o=e.width,s=a/2,l=e.x,u=e.y,f="left",h="top";if(i instanceof Array)l+=er(i[0],e.width),u+=er(i[1],e.height),f=null,h=null;else switch(i){case"left":l-=n,u+=s,f="right",h="middle";break;case"right":l+=n+o,u+=s,h="middle";break;case"top":l+=o/2,u-=n,f="center",h="bottom";break;case"bottom":l+=o/2,u+=a+n,f="center";break;case"inside":l+=o/2,u+=s,f="center",h="middle";break;case"insideLeft":l+=n,u+=s,h="middle";break;case"insideRight":l+=o-n,u+=s,f="right",h="middle";break;case"insideTop":l+=o/2,u+=n,f="center";break;case"insideBottom":l+=o/2,u+=a-n,f="center",h="bottom";break;case"insideTopLeft":l+=n,u+=n;break;case"insideTopRight":l+=o-n,u+=n,f="right";break;case"insideBottomLeft":l+=n,u+=a-n,h="bottom";break;case"insideBottomRight":l+=o-n,u+=a-n,f="right",h="bottom";break}return r=r||{},r.x=l,r.y=u,r.align=f,r.verticalAlign=h,r}var $u="__zr_normal__",qu=xr.concat(["ignore"]),iC=Fe(xr,function(r,t){return r[t]=!0,r},{ignore:!1}),Cn={},nC=new st(0,0,0,0),ql=(function(){function r(t){this.id=Wv(),this.animators=[],this.currentStates=[],this.states={},this._init(t)}return r.prototype._init=function(t){this.attr(t)},r.prototype.drift=function(t,e,i){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0;break}var n=this.transform;n||(n=this.transform=[1,0,0,1,0,0]),n[4]+=t,n[5]+=e,this.decomposeTransform(),this.markRedraw()},r.prototype.beforeUpdate=function(){},r.prototype.afterUpdate=function(){},r.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},r.prototype.updateInnerText=function(t){var e=this._textContent;if(e&&(!e.ignore||t)){this.textConfig||(this.textConfig={});var i=this.textConfig,n=i.local,a=e.innerTransformable,o=void 0,s=void 0,l=!1;a.parent=n?this:null;var u=!1;if(a.copyTransform(e),i.position!=null){var f=nC;i.layoutRect?f.copy(i.layoutRect):f.copy(this.getBoundingRect()),n||f.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(Cn,i,f):ml(Cn,i,f),a.x=Cn.x,a.y=Cn.y,o=Cn.align,s=Cn.verticalAlign;var h=i.origin;if(h&&i.rotation!=null){var c=void 0,v=void 0;h==="center"?(c=f.width*.5,v=f.height*.5):(c=er(h[0],f.width),v=er(h[1],f.height)),u=!0,a.originX=-a.x+c+(n?0:f.x),a.originY=-a.y+v+(n?0:f.y)}}i.rotation!=null&&(a.rotation=i.rotation);var p=i.offset;p&&(a.x+=p[0],a.y+=p[1],u||(a.originX=-p[0],a.originY=-p[1]));var d=i.inside==null?typeof i.position=="string"&&i.position.indexOf("inside")>=0:i.inside,g=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),y=void 0,m=void 0,_=void 0;d&&this.canBeInsideText()?(y=i.insideFill,m=i.insideStroke,(y==null||y==="auto")&&(y=this.getInsideTextFill()),(m==null||m==="auto")&&(m=this.getInsideTextStroke(y),_=!0)):(y=i.outsideFill,m=i.outsideStroke,(y==null||y==="auto")&&(y=this.getOutsideFill()),(m==null||m==="auto")&&(m=this.getOutsideStroke(y),_=!0)),y=y||"#000",(y!==g.fill||m!==g.stroke||_!==g.autoStroke||o!==g.align||s!==g.verticalAlign)&&(l=!0,g.fill=y,g.stroke=m,g.autoStroke=_,g.align=o,g.verticalAlign=s,e.setDefaultTextStyle(g)),e.__dirty|=Se,l&&e.dirtyStyle(!0)}},r.prototype.canBeInsideText=function(){return!0},r.prototype.getInsideTextFill=function(){return"#fff"},r.prototype.getInsideTextStroke=function(t){return"#000"},r.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?Oh:kh},r.prototype.getOutsideStroke=function(t){var e=this.__zr&&this.__zr.getBackgroundColor(),i=typeof e=="string"&&oe(e);i||(i=[255,255,255,1]);for(var n=i[3],a=this.__zr.isDarkMode(),o=0;o<3;o++)i[o]=i[o]*n+(a?0:255)*(1-n);return i[3]=1,Qe(i,"rgba")},r.prototype.traverse=function(t,e){},r.prototype.attrKV=function(t,e){t==="textConfig"?this.setTextConfig(e):t==="textContent"?this.setTextContent(e):t==="clipPath"?this.setClipPath(e):t==="extra"?(this.extra=this.extra||{},O(this.extra,e)):this[t]=e},r.prototype.hide=function(){this.ignore=!0,this.markRedraw()},r.prototype.show=function(){this.ignore=!1,this.markRedraw()},r.prototype.attr=function(t,e){if(typeof t=="string")this.attrKV(t,e);else if(X(t))for(var i=t,n=pt(i),a=0;a0},r.prototype.getState=function(t){return this.states[t]},r.prototype.ensureState=function(t){var e=this.states;return e[t]||(e[t]={}),e[t]},r.prototype.clearStates=function(t){this.useState($u,!1,t)},r.prototype.useState=function(t,e,i,n){var a=t===$u,o=this.hasState();if(!(!o&&a)){var s=this.currentStates,l=this.stateTransition;if(!(lt(s,t)>=0&&(e||s.length===1))){var u;if(this.stateProxy&&!a&&(u=this.stateProxy(t)),u||(u=this.states&&this.states[t]),!u&&!a){Xl("State "+t+" not exists.");return}a||this.saveCurrentToNormalState(u);var f=!!(u&&u.hoverLayer||n);f&&this._toggleHoverLayerFlag(!0),this._applyStateObj(t,u,this._normalState,e,!i&&!this.__inHover&&l&&l.duration>0,l);var h=this._textContent,c=this._textGuide;return h&&h.useState(t,e,i,f),c&&c.useState(t,e,i,f),a?(this.currentStates=[],this._normalState={}):e?this.currentStates.push(t):this.currentStates=[t],this._updateAnimationTargets(),this.markRedraw(),!f&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~Se),u}}},r.prototype.useStates=function(t,e,i){if(!t.length)this.clearStates();else{var n=[],a=this.currentStates,o=t.length,s=o===a.length;if(s){for(var l=0;l0,p);var d=this._textContent,g=this._textGuide;d&&d.useStates(t,e,c),g&&g.useStates(t,e,c),this._updateAnimationTargets(),this.currentStates=t.slice(),this.markRedraw(),!c&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~Se)}},r.prototype.isSilent=function(){for(var t=this.silent,e=this.parent;!t&&e;){if(e.silent){t=!0;break}e=e.parent}return t},r.prototype._updateAnimationTargets=function(){for(var t=0;t=0){var i=this.currentStates.slice();i.splice(e,1),this.useStates(i)}},r.prototype.replaceState=function(t,e,i){var n=this.currentStates.slice(),a=lt(n,t),o=lt(n,e)>=0;a>=0?o?n.splice(a,1):n[a]=e:i&&!o&&n.push(e),this.useStates(n)},r.prototype.toggleState=function(t,e){e?this.useState(t,!0):this.removeState(t)},r.prototype._mergeStates=function(t){for(var e={},i,n=0;n=0&&a.splice(o,1)}),this.animators.push(t),i&&i.animation.addAnimator(t),i&&i.wakeUp()},r.prototype.updateDuringAnimation=function(t){this.markRedraw()},r.prototype.stopAnimation=function(t,e){for(var i=this.animators,n=i.length,a=[],o=0;o0&&e.during&&a[0].during(function(p,d){e.during(d)});for(var c=0;c0||n.force&&!o.length){var C=void 0,A=void 0,M=void 0;if(s){A={},c&&(C={});for(var S=0;S<_;S++){var y=d[S];A[y]=e[y],c?C[y]=i[y]:e[y]=i[y]}}else if(c){M={};for(var S=0;S<_;S++){var y=d[S];M[y]=ro(e[y]),oC(e,i,y)}}var b=new jv(e,!1,!1,h?wt(p,function(L){return L.targetName===t}):null);b.targetName=t,n.scope&&(b.scope=n.scope),c&&C&&b.whenWithKeys(0,C,d),M&&b.whenWithKeys(0,M,d),b.whenWithKeys(u==null?500:u,s?A:i,d).delay(f||0),r.addAnimator(b,t),o.push(b)}}var nt=(function(r){E(t,r);function t(e){var i=r.call(this)||this;return i.isGroup=!0,i._children=[],i.attr(e),i}return t.prototype.childrenRef=function(){return this._children},t.prototype.children=function(){return this._children.slice()},t.prototype.childAt=function(e){return this._children[e]},t.prototype.childOfName=function(e){for(var i=this._children,n=0;n=0&&(n.splice(a,0,e),this._doAdd(e))}return this},t.prototype.replace=function(e,i){var n=lt(this._children,e);return n>=0&&this.replaceAt(i,n),this},t.prototype.replaceAt=function(e,i){var n=this._children,a=n[i];if(e&&e!==this&&e.parent!==this&&e!==a){n[i]=e,a.parent=null;var o=this.__zr;o&&a.removeSelfFromZr(o),this._doAdd(e)}return this},t.prototype._doAdd=function(e){e.parent&&e.parent.remove(e),e.parent=this;var i=this.__zr;i&&i!==e.__zr&&e.addSelfToZr(i),i&&i.refresh()},t.prototype.remove=function(e){var i=this.__zr,n=this._children,a=lt(n,e);return a<0?this:(n.splice(a,1),e.parent=null,i&&e.removeSelfFromZr(i),i&&i.refresh(),this)},t.prototype.removeAll=function(){for(var e=this._children,i=this.__zr,n=0;n0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},r.prototype.setSleepAfterStill=function(t){this._sleepAfterStill=t},r.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},r.prototype.refreshHover=function(){this._needsRefreshHover=!0},r.prototype.refreshHoverImmediately=function(){this._disposed||(this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.getType()==="canvas"&&this.painter.refreshHover())},r.prototype.resize=function(t){this._disposed||(t=t||{},this.painter.resize(t.width,t.height),this.handler.resize())},r.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},r.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},r.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},r.prototype.setCursorStyle=function(t){this._disposed||this.handler.setCursorStyle(t)},r.prototype.findHover=function(t,e){if(!this._disposed)return this.handler.findHover(t,e)},r.prototype.on=function(t,e,i){return this._disposed||this.handler.on(t,e,i),this},r.prototype.off=function(t,e){this._disposed||this.handler.off(t,e)},r.prototype.trigger=function(t,e){this._disposed||this.handler.trigger(t,e)},r.prototype.clear=function(){if(!this._disposed){for(var t=this.storage.getRoots(),e=0;e0){if(r<=n)return o;if(r>=a)return s}else{if(r>=n)return o;if(r<=a)return s}else{if(r===n)return o;if(r===a)return s}return(r-n)/l*u+o}function Q(r,t){switch(r){case"center":case"middle":r="50%";break;case"left":case"top":r="0%";break;case"right":case"bottom":r="100%";break}return G(r)?mC(r).match(/%$/)?parseFloat(r)/100*t:parseFloat(r):r==null?NaN:+r}function Lt(r,t,e){return t==null&&(t=10),t=Math.min(Math.max(0,t),k_),r=(+r).toFixed(t),e?r:+r}function gr(r){return r.sort(function(t,e){return t-e}),r}function yr(r){if(r=+r,isNaN(r))return 0;if(r>1e-14){for(var t=1,e=0;e<15;e++,t*=10)if(Math.round(r*t)/t===r)return e}return O_(r)}function O_(r){var t=r.toString().toLowerCase(),e=t.indexOf("e"),i=e>0?+t.slice(e+1):0,n=e>0?e:t.length,a=t.indexOf("."),o=a<0?0:n-1-a;return Math.max(0,o-i)}function tc(r,t){var e=Math.log,i=Math.LN10,n=Math.floor(e(r[1]-r[0])/i),a=Math.round(e(Math.abs(t[1]-t[0]))/i),o=Math.min(Math.max(-n+a,0),20);return isFinite(o)?o:20}function _C(r,t,e){if(!r[t])return 0;var i=B_(r,e);return i[t]||0}function B_(r,t){var e=Fe(r,function(v,p){return v+(isNaN(p)?0:p)},0);if(e===0)return[];for(var i=Math.pow(10,t),n=F(r,function(v){return(isNaN(v)?0:v)/e*i*100}),a=i*100,o=F(n,function(v){return Math.floor(v)}),s=Fe(o,function(v,p){return v+p},0),l=F(n,function(v,p){return v-o[p]});su&&(u=l[h],f=h);++o[f],l[f]=0,++s}return F(o,function(v){return v/i})}function SC(r,t){var e=Math.max(yr(r),yr(t)),i=r+t;return e>k_?i:Lt(i,e)}var xC=9007199254740991;function ec(r){var t=Math.PI*2;return(r%t+t)%t}function mo(r){return r>-ad&&r=10&&t++,t}function rc(r,t){var e=Kl(r),i=Math.pow(10,e),n=r/i,a;return t?n<1.5?a=1:n<2.5?a=2:n<4?a=3:n<7?a=5:a=10:n<1?a=1:n<2?a=2:n<3?a=3:n<5?a=5:a=10,r=a*i,e>=-20?+r.toFixed(e<0?-e:0):r}function wC(r,t){var e=(r.length-1)*t+1,i=Math.floor(e),n=+r[i-1],a=e-i;return a?n+a*(r[i]-n):n}function zh(r){r.sort(function(l,u){return s(l,u,0)?-1:1});for(var t=-1/0,e=1,i=0;i=0||a&<(a,l)<0)){var u=i.getShallow(l,t);u!=null&&(o[r[s][0]]=u)}}return o}}var ZC=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],$C=jn(ZC),qC=(function(){function r(){}return r.prototype.getAreaStyle=function(t,e){return $C(this,t,e)},r})(),Fh=new Vo(50);function KC(r){if(typeof r=="string"){var t=Fh.get(r);return t&&t.image}else return r}function $_(r,t,e,i,n){if(r)if(typeof r=="string"){if(t&&t.__zrImageSrc===r||!e)return t;var a=Fh.get(r),o={hostEl:e,cb:i,cbPayload:n};return a?(t=a.image,!jl(t)&&a.pending.push(o)):(t=Nr.loadImage(r,ud,ud),t.__zrImageSrc=r,Fh.put(r,t.__cachedImgObj={image:t,pending:[o]})),t}else return r;else return t}function ud(){var r=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t=o;l++)s-=o;var u=be(e,t);return u>s&&(e="",u=0),s=r-u,n.ellipsis=e,n.ellipsisWidth=u,n.contentWidth=s,n.containerWidth=r,n}function J_(r,t,e){var i=e.containerWidth,n=e.font,a=e.contentWidth;if(!i){r.textLine="",r.isTruncated=!1;return}var o=be(t,n);if(o<=i){r.textLine=t,r.isTruncated=!1;return}for(var s=0;;s++){if(o<=a||s>=e.maxIterations){t+=e.ellipsis;break}var l=s===0?jC(t,a,e.ascCharWidth,e.cnCharWidth):o>0?Math.floor(t.length*a/o):0;t=t.substr(0,l),o=be(t,n)}t===""&&(t=e.placeholder),r.textLine=t,r.isTruncated=!0}function jC(r,t,e,i){for(var n=0,a=0,o=r.length;ap&&u){var d=Math.floor(p/s);f=f||c.length>d,c=c.slice(0,d)}if(r&&a&&h!=null)for(var g=K_(h,n,t.ellipsis,{minChar:t.truncateMinChar,placeholder:t.placeholder}),y={},m=0;ms&&Qu(e,r.substring(s,u),t,o),Qu(e,l[2],t,o,l[1]),s=ju.lastIndex}sn){var P=e.lines.length;x>0?(_.tokens=_.tokens.slice(0,x),y(_,b,S),e.lines=e.lines.slice(0,m+1)):e.lines=e.lines.slice(0,m),e.isTruncated=e.isTruncated||e.lines.length0&&p+i.accumWidth>i.width&&(f=t.split(` `),u=!0),i.accumWidth=p}else{var d=j_(t,l,i.width,i.breakAll,i.accumWidth);i.accumWidth=d.accumWidth+v,h=d.linesWidths,f=d.lines}}else f=t.split(` `);for(var g=0;g=32&&t<=591||t>=880&&t<=4351||t>=4608&&t<=5119||t>=7680&&t<=8303}var nA=Fe(",&?/;] ".split(""),function(r,t){return r[t]=!0,r},{});function aA(r){return iA(r)?!!nA[r]:!0}function j_(r,t,e,i,n){for(var a=[],o=[],s="",l="",u=0,f=0,h=0;he:n+f+v>e){f?(s||l)&&(p?(s||(s=l,l="",u=0,f=u),a.push(s),o.push(f-u),l+=c,u+=v,s="",f=u):(l&&(s+=l,l="",u=0),a.push(s),o.push(f),s=c,f=v)):p?(a.push(l),o.push(u),l=c,u=v):(a.push(c),o.push(v));continue}f+=v,p?(l+=c,u+=v):(l&&(s+=l,l="",u=0),s+=c)}return!a.length&&!s&&(s=r,l="",u=0),l&&(s+=l),s&&(a.push(s),o.push(f)),a.length===1&&(f+=n),{accumWidth:f,lines:a,linesWidths:o}}var Vh="__zr_style_"+Math.round(Math.random()*10),nn={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},Ql={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};nn[Vh]=!0;var hd=["z","z2","invisible"],oA=["invisible"],Hr=(function(r){E(t,r);function t(e){return r.call(this,e)||this}return t.prototype._init=function(e){for(var i=pt(e),n=0;n1e-4){s[0]=r-e,s[1]=t-i,l[0]=r+e,l[1]=t+i;return}if(ss[0]=nf(n)*e+r,ss[1]=rf(n)*i+t,ls[0]=nf(a)*e+r,ls[1]=rf(a)*i+t,u(s,ss,ls),f(l,ss,ls),n=n%Di,n<0&&(n=n+Di),a=a%Di,a<0&&(a=a+Di),n>a&&!o?a+=Di:nn&&(us[0]=nf(v)*e+r,us[1]=rf(v)*i+t,u(s,us,s),f(l,us,l))}var mt={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Li=[],Pi=[],lr=[],qr=[],ur=[],fr=[],af=Math.min,of=Math.max,Ii=Math.cos,Ri=Math.sin,Mr=Math.abs,Gh=Math.PI,ii=Gh*2,sf=typeof Float32Array!="undefined",wa=[];function lf(r){var t=Math.round(r/Gh*1e8)/1e8;return t%2*Gh}function Q_(r,t){var e=lf(r[0]);e<0&&(e+=ii);var i=e-r[0],n=r[1];n+=i,!t&&n-e>=ii?n=e+ii:t&&e-n>=ii?n=e-ii:!t&&e>n?n=e+(ii-lf(e-n)):t&&e0&&(this._ux=Mr(i/yl/t)||0,this._uy=Mr(i/yl/e)||0)},r.prototype.setDPR=function(t){this.dpr=t},r.prototype.setContext=function(t){this._ctx=t},r.prototype.getContext=function(){return this._ctx},r.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},r.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},r.prototype.moveTo=function(t,e){return this._drawPendingPt(),this.addData(mt.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},r.prototype.lineTo=function(t,e){var i=Mr(t-this._xi),n=Mr(e-this._yi),a=i>this._ux||n>this._uy;if(this.addData(mt.L,t,e),this._ctx&&a&&this._ctx.lineTo(t,e),a)this._xi=t,this._yi=e,this._pendingPtDist=0;else{var o=i*i+n*n;o>this._pendingPtDist&&(this._pendingPtX=t,this._pendingPtY=e,this._pendingPtDist=o)}return this},r.prototype.bezierCurveTo=function(t,e,i,n,a,o){return this._drawPendingPt(),this.addData(mt.C,t,e,i,n,a,o),this._ctx&&this._ctx.bezierCurveTo(t,e,i,n,a,o),this._xi=a,this._yi=o,this},r.prototype.quadraticCurveTo=function(t,e,i,n){return this._drawPendingPt(),this.addData(mt.Q,t,e,i,n),this._ctx&&this._ctx.quadraticCurveTo(t,e,i,n),this._xi=i,this._yi=n,this},r.prototype.arc=function(t,e,i,n,a,o){this._drawPendingPt(),wa[0]=n,wa[1]=a,Q_(wa,o),n=wa[0],a=wa[1];var s=a-n;return this.addData(mt.A,t,e,i,i,n,s,0,o?0:1),this._ctx&&this._ctx.arc(t,e,i,n,a,o),this._xi=Ii(a)*i+t,this._yi=Ri(a)*i+e,this},r.prototype.arcTo=function(t,e,i,n,a){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(t,e,i,n,a),this},r.prototype.rect=function(t,e,i,n){return this._drawPendingPt(),this._ctx&&this._ctx.rect(t,e,i,n),this.addData(mt.R,t,e,i,n),this},r.prototype.closePath=function(){this._drawPendingPt(),this.addData(mt.Z);var t=this._ctx,e=this._x0,i=this._y0;return t&&t.closePath(),this._xi=e,this._yi=i,this},r.prototype.fill=function(t){t&&t.fill(),this.toStatic()},r.prototype.stroke=function(t){t&&t.stroke(),this.toStatic()},r.prototype.len=function(){return this._len},r.prototype.setData=function(t){var e=t.length;!(this.data&&this.data.length===e)&&sf&&(this.data=new Float32Array(e));for(var i=0;if.length&&(this._expandData(),f=this.data);for(var h=0;h0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},r.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var t=[],e=0;e11&&(this.data=new Float32Array(t)))}},r.prototype.getBoundingRect=function(){lr[0]=lr[1]=ur[0]=ur[1]=Number.MAX_VALUE,qr[0]=qr[1]=fr[0]=fr[1]=-Number.MAX_VALUE;var t=this.data,e=0,i=0,n=0,a=0,o;for(o=0;oi||Mr(_)>n||c===e-1)&&(d=Math.sqrt(m*m+_*_),a=g,o=y);break}case mt.C:{var S=t[c++],b=t[c++],g=t[c++],y=t[c++],x=t[c++],T=t[c++];d=CT(a,o,S,b,g,y,x,T,10),a=x,o=T;break}case mt.Q:{var S=t[c++],b=t[c++],g=t[c++],y=t[c++];d=MT(a,o,S,b,g,y,10),a=g,o=y;break}case mt.A:var C=t[c++],A=t[c++],M=t[c++],D=t[c++],L=t[c++],P=t[c++],I=P+L;c+=1,p&&(s=Ii(L)*M+C,l=Ri(L)*D+A),d=of(M,D)*af(ii,Math.abs(P)),a=Ii(I)*M+C,o=Ri(I)*D+A;break;case mt.R:{s=a=t[c++],l=o=t[c++];var R=t[c++],k=t[c++];d=R*2+k*2;break}case mt.Z:{var m=s-a,_=l-o;d=Math.sqrt(m*m+_*_),a=s,o=l;break}}d>=0&&(u[h++]=d,f+=d)}return this._pathLen=f,f},r.prototype.rebuildPath=function(t,e){var i=this.data,n=this._ux,a=this._uy,o=this._len,s,l,u,f,h,c,v=e<1,p,d,g=0,y=0,m,_=0,S,b;if(!(v&&(this._pathSegLen||this._calculateLength(),p=this._pathSegLen,d=this._pathLen,m=e*d,!m)))t:for(var x=0;x0&&(t.lineTo(S,b),_=0),T){case mt.M:s=u=i[x++],l=f=i[x++],t.moveTo(u,f);break;case mt.L:{h=i[x++],c=i[x++];var A=Mr(h-u),M=Mr(c-f);if(A>n||M>a){if(v){var D=p[y++];if(g+D>m){var L=(m-g)/D;t.lineTo(u*(1-L)+h*L,f*(1-L)+c*L);break t}g+=D}t.lineTo(h,c),u=h,f=c,_=0}else{var P=A*A+M*M;P>_&&(S=h,b=c,_=P)}break}case mt.C:{var I=i[x++],R=i[x++],k=i[x++],V=i[x++],B=i[x++],N=i[x++];if(v){var D=p[y++];if(g+D>m){var L=(m-g)/D;pl(u,I,k,B,L,Li),pl(f,R,V,N,L,Pi),t.bezierCurveTo(Li[1],Pi[1],Li[2],Pi[2],Li[3],Pi[3]);break t}g+=D}t.bezierCurveTo(I,R,k,V,B,N),u=B,f=N;break}case mt.Q:{var I=i[x++],R=i[x++],k=i[x++],V=i[x++];if(v){var D=p[y++];if(g+D>m){var L=(m-g)/D;dl(u,I,k,L,Li),dl(f,R,V,L,Pi),t.quadraticCurveTo(Li[1],Pi[1],Li[2],Pi[2]);break t}g+=D}t.quadraticCurveTo(I,R,k,V),u=k,f=V;break}case mt.A:var Y=i[x++],Z=i[x++],$=i[x++],ut=i[x++],dt=i[x++],bt=i[x++],ue=i[x++],Ae=!i[x++],me=$>ut?$:ut,zt=Mr($-ut)>.001,Pt=dt+bt,it=!1;if(v){var D=p[y++];g+D>m&&(Pt=dt+bt*(m-g)/D,it=!0),g+=D}if(zt&&t.ellipse?t.ellipse(Y,Z,$,ut,ue,dt,Pt,Ae):t.arc(Y,Z,me,dt,Pt,Ae),it)break t;C&&(s=Ii(dt)*$+Y,l=Ri(dt)*ut+Z),u=Ii(Pt)*$+Y,f=Ri(Pt)*ut+Z;break;case mt.R:s=u=i[x],l=f=i[x+1],h=i[x++],c=i[x++];var ht=i[x++],sr=i[x++];if(v){var D=p[y++];if(g+D>m){var Ot=m-g;t.moveTo(h,c),t.lineTo(h+af(Ot,ht),c),Ot-=ht,Ot>0&&t.lineTo(h+ht,c+af(Ot,sr)),Ot-=sr,Ot>0&&t.lineTo(h+of(ht-Ot,0),c+sr),Ot-=ht,Ot>0&&t.lineTo(h,c+of(sr-Ot,0));break t}g+=D}t.rect(h,c,ht,sr);break;case mt.Z:if(v){var D=p[y++];if(g+D>m){var L=(m-g)/D;t.lineTo(u*(1-L)+s*L,f*(1-L)+l*L);break t}g+=D}t.closePath(),u=s,f=l}}},r.prototype.clone=function(){var t=new r,e=this.data;return t.data=e.slice?e.slice():Array.prototype.slice.call(e),t._len=this._len,t},r.CMD=mt,r.initDefaultProps=(function(){var t=r.prototype;t._saveData=!0,t._ux=0,t._uy=0,t._pendingPtDist=0,t._version=0})(),r})();function An(r,t,e,i,n,a,o){if(n===0)return!1;var s=n,l=0,u=r;if(o>t+s&&o>i+s||or+s&&a>e+s||at+h&&f>i+h&&f>a+h&&f>s+h||fr+h&&u>e+h&&u>n+h&&u>o+h||ut+u&&l>i+u&&l>a+u||lr+u&&s>e+u&&s>n+u||se||f+un&&(n+=Ta);var c=Math.atan2(l,s);return c<0&&(c+=Ta),c>=i&&c<=n||c+Ta>=i&&c+Ta<=n}function Ir(r,t,e,i,n,a){if(a>t&&a>i||an?s:0}var Kr=pi.CMD,Ei=Math.PI*2,pA=1e-4;function dA(r,t){return Math.abs(r-t)t&&u>i&&u>a&&u>s||u1&&gA(),v=Et(t,i,a,s,Ee[0]),c>1&&(p=Et(t,i,a,s,Ee[1]))),c===2?gt&&s>i&&s>a||s=0&&u<=1){for(var f=0,h=Zt(t,i,a,u),c=0;ce||s<-e)return 0;var l=Math.sqrt(e*e-s*s);ee[0]=-l,ee[1]=l;var u=Math.abs(i-n);if(u<1e-4)return 0;if(u>=Ei-1e-4){i=0,n=Ei;var f=a?1:-1;return o>=ee[0]+r&&o<=ee[1]+r?f:0}if(i>n){var h=i;i=n,n=h}i<0&&(i+=Ei,n+=Ei);for(var c=0,v=0;v<2;v++){var p=ee[v];if(p+r>o){var d=Math.atan2(s,p),f=a?1:-1;d<0&&(d=Ei+d),(d>=i&&d<=n||d+Ei>=i&&d+Ei<=n)&&(d>Math.PI/2&&d1&&(e||(s+=Ir(l,u,f,h,i,n))),g&&(l=a[p],u=a[p+1],f=l,h=u),d){case Kr.M:f=a[p++],h=a[p++],l=f,u=h;break;case Kr.L:if(e){if(An(l,u,a[p],a[p+1],t,i,n))return!0}else s+=Ir(l,u,a[p],a[p+1],i,n)||0;l=a[p++],u=a[p++];break;case Kr.C:if(e){if(hA(l,u,a[p++],a[p++],a[p++],a[p++],a[p],a[p+1],t,i,n))return!0}else s+=yA(l,u,a[p++],a[p++],a[p++],a[p++],a[p],a[p+1],i,n)||0;l=a[p++],u=a[p++];break;case Kr.Q:if(e){if(vA(l,u,a[p++],a[p++],a[p],a[p+1],t,i,n))return!0}else s+=mA(l,u,a[p++],a[p++],a[p],a[p+1],i,n)||0;l=a[p++],u=a[p++];break;case Kr.A:var y=a[p++],m=a[p++],_=a[p++],S=a[p++],b=a[p++],x=a[p++];p+=1;var T=!!(1-a[p++]);c=Math.cos(b)*_+y,v=Math.sin(b)*S+m,g?(f=c,h=v):s+=Ir(l,u,c,v,i,n);var C=(i-y)*S/_+y;if(e){if(cA(y,m,S,b,b+x,T,t,C,n))return!0}else s+=_A(y,m,S,b,b+x,T,C,n);l=Math.cos(b+x)*_+y,u=Math.sin(b+x)*S+m;break;case Kr.R:f=l=a[p++],h=u=a[p++];var A=a[p++],M=a[p++];if(c=f+A,v=h+M,e){if(An(f,h,c,h,t,i,n)||An(c,h,c,v,t,i,n)||An(c,v,f,v,t,i,n)||An(f,v,f,h,t,i,n))return!0}else s+=Ir(c,h,c,v,i,n),s+=Ir(f,v,f,h,i,n);break;case Kr.Z:if(e){if(An(l,u,f,h,t,i,n))return!0}else s+=Ir(l,u,f,h,i,n);l=f,u=h;break}}return!e&&!dA(u,h)&&(s+=Ir(l,u,f,h,i,n)||0),s!==0}function SA(r,t,e){return t1(r,0,!1,t,e)}function xA(r,t,e,i){return t1(r,t,!0,e,i)}var e1=K({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},nn),bA={style:K({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},Ql.style)},uf=xr.concat(["invisible","culling","z","z2","zlevel","parent"]),gt=(function(r){E(t,r);function t(e){return r.call(this,e)||this}return t.prototype.update=function(){var e=this;r.prototype.update.call(this);var i=this.style;if(i.decal){var n=this._decalEl=this._decalEl||new t;n.buildPath===t.prototype.buildPath&&(n.buildPath=function(l){e.buildPath(l,e.shape)}),n.silent=!0;var a=n.style;for(var o in i)a[o]!==i[o]&&(a[o]=i[o]);a.fill=i.fill?i.decal:null,a.decal=null,a.shadowColor=null,i.strokeFirst&&(a.stroke=null);for(var s=0;s.5?kh:i>.2?eC:Oh}else if(e)return Oh}return kh},t.prototype.getInsideTextStroke=function(e){var i=this.style.fill;if(G(i)){var n=this.__zr,a=!!(n&&n.isDarkMode()),o=yo(e,0)0))},t.prototype.hasFill=function(){var e=this.style,i=e.fill;return i!=null&&i!=="none"},t.prototype.getBoundingRect=function(){var e=this._rect,i=this.style,n=!e;if(n){var a=!1;this.path||(a=!0,this.createPathProxy());var o=this.path;(a||this.__dirty&Vn)&&(o.beginPath(),this.buildPath(o,this.shape,!1),this.pathUpdated()),e=o.getBoundingRect()}if(this._rect=e,this.hasStroke()&&this.path&&this.path.len()>0){var s=this._rectStroke||(this._rectStroke=e.clone());if(this.__dirty||n){s.copy(e);var l=i.strokeNoScale?this.getLineScale():1,u=i.lineWidth;if(!this.hasFill()){var f=this.strokeContainThreshold;u=Math.max(u,f==null?4:f)}l>1e-10&&(s.width+=u/l,s.height+=u/l,s.x-=u/l/2,s.y-=u/l/2)}return s}return e},t.prototype.contain=function(e,i){var n=this.transformCoordToLocal(e,i),a=this.getBoundingRect(),o=this.style;if(e=n[0],i=n[1],a.contain(e,i)){var s=this.path;if(this.hasStroke()){var l=o.lineWidth,u=o.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(this.hasFill()||(l=Math.max(l,this.strokeContainThreshold)),xA(s,l/u,e,i)))return!0}if(this.hasFill())return SA(s,e,i)}return!1},t.prototype.dirtyShape=function(){this.__dirty|=Vn,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},t.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},t.prototype.animateShape=function(e){return this.animate("shape",e)},t.prototype.updateDuringAnimation=function(e){e==="style"?this.dirtyStyle():e==="shape"?this.dirtyShape():this.markRedraw()},t.prototype.attrKV=function(e,i){e==="shape"?this.setShape(i):r.prototype.attrKV.call(this,e,i)},t.prototype.setShape=function(e,i){var n=this.shape;return n||(n=this.shape={}),typeof e=="string"?n[e]=i:O(n,e),this.dirtyShape(),this},t.prototype.shapeChanged=function(){return!!(this.__dirty&Vn)},t.prototype.createStyle=function(e){return zo(e1,e)},t.prototype._innerSaveToNormal=function(e){r.prototype._innerSaveToNormal.call(this,e);var i=this._normalState;e.shape&&!i.shape&&(i.shape=O({},this.shape))},t.prototype._applyStateObj=function(e,i,n,a,o,s){r.prototype._applyStateObj.call(this,e,i,n,a,o,s);var l=!(i&&a),u;if(i&&i.shape?o?a?u=i.shape:(u=O({},n.shape),O(u,i.shape)):(u=O({},a?this.shape:n.shape),O(u,i.shape)):l&&(u=n.shape),u)if(o){this.shape=O({},this.shape);for(var f={},h=pt(u),c=0;c0},t.prototype.hasFill=function(){var e=this.style,i=e.fill;return i!=null&&i!=="none"},t.prototype.createStyle=function(e){return zo(wA,e)},t.prototype.setBoundingRect=function(e){this._rect=e},t.prototype.getBoundingRect=function(){var e=this.style;if(!this._rect){var i=e.text;i!=null?i+="":i="";var n=Go(i,e.font,e.textAlign,e.textBaseline);if(n.x+=e.x||0,n.y+=e.y||0,this.hasStroke()){var a=e.lineWidth;n.x-=a/2,n.y-=a/2,n.width+=a,n.height+=a}this._rect=n}return this._rect},t.initDefaultProps=(function(){var e=t.prototype;e.dirtyRectTolerance=10})(),t})(Hr);So.prototype.type="tspan";var TA=K({x:0,y:0},nn),CA={style:K({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},Ql.style)};function AA(r){return!!(r&&typeof r!="string"&&r.width&&r.height)}var ye=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.createStyle=function(e){return zo(TA,e)},t.prototype._getSize=function(e){var i=this.style,n=i[e];if(n!=null)return n;var a=AA(i.image)?i.image:this.__image;if(!a)return 0;var o=e==="width"?"height":"width",s=i[o];return s==null?a[e]:a[e]/a[o]*s},t.prototype.getWidth=function(){return this._getSize("width")},t.prototype.getHeight=function(){return this._getSize("height")},t.prototype.getAnimationStyleProps=function(){return CA},t.prototype.getBoundingRect=function(){var e=this.style;return this._rect||(this._rect=new st(e.x||0,e.y||0,this.getWidth(),this.getHeight())),this._rect},t})(Hr);ye.prototype.type="image";function MA(r,t){var e=t.x,i=t.y,n=t.width,a=t.height,o=t.r,s,l,u,f;n<0&&(e=e+n,n=-n),a<0&&(i=i+a,a=-a),typeof o=="number"?s=l=u=f=o:o instanceof Array?o.length===1?s=l=u=f=o[0]:o.length===2?(s=u=o[0],l=f=o[1]):o.length===3?(s=o[0],l=f=o[1],u=o[2]):(s=o[0],l=o[1],u=o[2],f=o[3]):s=l=u=f=0;var h;s+l>n&&(h=s+l,s*=n/h,l*=n/h),u+f>n&&(h=u+f,u*=n/h,f*=n/h),l+u>a&&(h=l+u,l*=a/h,u*=a/h),s+f>a&&(h=s+f,s*=a/h,f*=a/h),r.moveTo(e+s,i),r.lineTo(e+n-l,i),l!==0&&r.arc(e+n-l,i+l,l,-Math.PI/2,0),r.lineTo(e+n,i+a-u),u!==0&&r.arc(e+n-u,i+a-u,u,0,Math.PI/2),r.lineTo(e+f,i+a),f!==0&&r.arc(e+f,i+a-f,f,Math.PI/2,Math.PI),r.lineTo(e,i+s),s!==0&&r.arc(e+s,i+s,s,Math.PI,Math.PI*1.5)}var Yn=Math.round;function r1(r,t,e){if(t){var i=t.x1,n=t.x2,a=t.y1,o=t.y2;r.x1=i,r.x2=n,r.y1=a,r.y2=o;var s=e&&e.lineWidth;return s&&(Yn(i*2)===Yn(n*2)&&(r.x1=r.x2=Ki(i,s,!0)),Yn(a*2)===Yn(o*2)&&(r.y1=r.y2=Ki(a,s,!0))),r}}function i1(r,t,e){if(t){var i=t.x,n=t.y,a=t.width,o=t.height;r.x=i,r.y=n,r.width=a,r.height=o;var s=e&&e.lineWidth;return s&&(r.x=Ki(i,s,!0),r.y=Ki(n,s,!0),r.width=Math.max(Ki(i+a,s,!1)-r.x,a===0?0:1),r.height=Math.max(Ki(n+o,s,!1)-r.y,o===0?0:1)),r}}function Ki(r,t,e){if(!t)return r;var i=Yn(r*2);return(i+Yn(t))%2===0?i/2:(i+(e?1:-1))/2}var DA=(function(){function r(){this.x=0,this.y=0,this.width=0,this.height=0}return r})(),LA={},vt=(function(r){E(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new DA},t.prototype.buildPath=function(e,i){var n,a,o,s;if(this.subPixelOptimize){var l=i1(LA,i,this.style);n=l.x,a=l.y,o=l.width,s=l.height,l.r=i.r,i=l}else n=i.x,a=i.y,o=i.width,s=i.height;i.r?MA(e,i):e.rect(n,a,o,s)},t.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},t})(gt);vt.prototype.type="rect";var gd={fill:"#000"},yd=2,PA={style:K({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},Ql.style)},ct=(function(r){E(t,r);function t(e){var i=r.call(this)||this;return i.type="text",i._children=[],i._defaultStyle=gd,i.attr(e),i}return t.prototype.childrenRef=function(){return this._children},t.prototype.update=function(){r.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var e=0;e0,L=e.width!=null&&(e.overflow==="truncate"||e.overflow==="break"||e.overflow==="breakAll"),P=o.calculatedLineHeight,I=0;I=0&&(I=x[P],I.align==="right");)this._placeToken(I,e,C,y,L,"right",_),A-=I.width,L-=I.width,P--;for(D+=(a-(D-g)-(m-L)-A)/2;M<=P;)I=x[M],this._placeToken(I,e,C,y,D+I.width/2,"center",_),D+=I.width,M++;y+=C}},t.prototype._placeToken=function(e,i,n,a,o,s,l){var u=i.rich[e.styleName]||{};u.text=e.text;var f=e.verticalAlign,h=a+n/2;f==="top"?h=a+e.height/2:f==="bottom"&&(h=a+n-e.height/2);var c=!e.isLineHolder&&ff(u);c&&this._renderBackground(u,i,s==="right"?o-e.width:s==="center"?o-e.width/2:o,h-e.height/2,e.width,e.height);var v=!!u.backgroundColor,p=e.textPadding;p&&(o=wd(o,s,p),h-=e.height/2-p[0]-e.innerHeight/2);var d=this._getOrCreateChild(So),g=d.createStyle();d.useStyle(g);var y=this._defaultStyle,m=!1,_=0,S=bd("fill"in u?u.fill:"fill"in i?i.fill:(m=!0,y.fill)),b=xd("stroke"in u?u.stroke:"stroke"in i?i.stroke:!v&&!l&&(!y.autoStroke||m)?(_=yd,y.stroke):null),x=u.textShadowBlur>0||i.textShadowBlur>0;g.text=e.text,g.x=o,g.y=h,x&&(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=e.font||fn,g.opacity=Un(u.opacity,i.opacity,1),_d(g,u),b&&(g.lineWidth=Un(u.lineWidth,i.lineWidth,_),g.lineDash=rt(u.lineDash,i.lineDash),g.lineDashOffset=i.lineDashOffset||0,g.stroke=b),S&&(g.fill=S);var T=e.contentWidth,C=e.contentHeight;d.setBoundingRect(new st(Za(g.x,T,g.textAlign),Gn(g.y,C,g.textBaseline),T,C))},t.prototype._renderBackground=function(e,i,n,a,o,s){var l=e.backgroundColor,u=e.borderWidth,f=e.borderColor,h=l&&l.image,c=l&&!h,v=e.borderRadius,p=this,d,g;if(c||e.lineHeight||u&&f){d=this._getOrCreateChild(vt),d.useStyle(d.createStyle()),d.style.fill=null;var y=d.shape;y.x=n,y.y=a,y.width=o,y.height=s,y.r=v,d.dirtyShape()}if(c){var m=d.style;m.fill=l||null,m.fillOpacity=rt(e.fillOpacity,1)}else if(h){g=this._getOrCreateChild(ye),g.onload=function(){p.dirtyStyle()};var _=g.style;_.image=l.image,_.x=n,_.y=a,_.width=o,_.height=s}if(u&&f){var m=d.style;m.lineWidth=u,m.stroke=f,m.strokeOpacity=rt(e.strokeOpacity,1),m.lineDash=e.borderDash,m.lineDashOffset=e.borderDashOffset||0,d.strokeContainThreshold=0,d.hasFill()&&d.hasStroke()&&(m.strokeFirst=!0,m.lineWidth*=2)}var S=(d||g).style;S.shadowBlur=e.shadowBlur||0,S.shadowColor=e.shadowColor||"transparent",S.shadowOffsetX=e.shadowOffsetX||0,S.shadowOffsetY=e.shadowOffsetY||0,S.opacity=Un(e.opacity,i.opacity,1)},t.makeFont=function(e){var i="";return kA(e)&&(i=[e.fontStyle,e.fontWeight,EA(e.fontSize),e.fontFamily||"sans-serif"].join(" ")),i&&ze(i)||e.textFont||e.font},t})(Hr),IA={left:!0,right:1,center:1},RA={top:1,bottom:1,middle:1},md=["fontStyle","fontWeight","fontSize","fontFamily"];function EA(r){return typeof r=="string"&&(r.indexOf("px")!==-1||r.indexOf("rem")!==-1||r.indexOf("em")!==-1)?r:isNaN(+r)?Vv+"px":r+"px"}function _d(r,t){for(var e=0;e=0,a=!1;if(r instanceof gt){var o=n1(r),s=n&&o.selectFill||o.normalFill,l=n&&o.selectStroke||o.normalStroke;if(Mn(s)||Mn(l)){i=i||{};var u=i.style||{};u.fill==="inherit"?(a=!0,i=O({},i),u=O({},u),u.fill=s):!Mn(u.fill)&&Mn(s)?(a=!0,i=O({},i),u=O({},u),u.fill=Mh(s)):!Mn(u.stroke)&&Mn(l)&&(a||(i=O({},i),u=O({},u)),u.stroke=Mh(l)),i.style=u}}if(i&&i.z2==null){a||(i=O({},i));var f=r.z2EmphasisLift;i.z2=r.z2+(f!=null?f:a1)}return i}function HA(r,t,e){if(e&&e.z2==null){e=O({},e);var i=r.z2SelectLift;e.z2=r.z2+(i!=null?i:NA)}return e}function WA(r,t,e){var i=lt(r.currentStates,t)>=0,n=r.style.opacity,a=i?null:VA(r,["opacity"],t,{opacity:1});e=e||{};var o=e.style||{};return o.opacity==null&&(e=O({},e),o=O({opacity:i?n:a.opacity*.1},o),e.style=o),e}function hf(r,t){var e=this.states[r];if(this.style){if(r==="emphasis")return GA(this,r,t,e);if(r==="blur")return WA(this,r,e);if(r==="select")return HA(this,r,e)}return e}function fc(r){r.stateProxy=hf;var t=r.getTextContent(),e=r.getTextGuideLine();t&&(t.stateProxy=hf),e&&(e.stateProxy=hf)}function Dd(r,t){!v1(r,t)&&!r.__highByOuter&&Ur(r,o1)}function Ld(r,t){!v1(r,t)&&!r.__highByOuter&&Ur(r,s1)}function Qn(r,t){r.__highByOuter|=1<<(t||0),Ur(r,o1)}function ta(r,t){!(r.__highByOuter&=~(1<<(t||0)))&&Ur(r,s1)}function YA(r){Ur(r,uc)}function u1(r){Ur(r,l1)}function f1(r){Ur(r,zA)}function h1(r){Ur(r,FA)}function v1(r,t){return r.__highDownSilentOnTouch&&t.zrByTouch}function c1(r){var t=r.getModel(),e=[],i=[];t.eachComponent(function(n,a){var o=sc(a),s=n==="series",l=s?r.getViewOfSeriesModel(a):r.getViewOfComponentModel(a);!s&&i.push(l),o.isBlured&&(l.group.traverse(function(u){l1(u)}),s&&e.push(a)),o.isBlured=!1}),w(i,function(n){n&&n.toggleBlurSeries&&n.toggleBlurSeries(e,!1,t)})}function Wh(r,t,e,i){var n=i.getModel();e=e||"coordinateSystem";function a(u,f){for(var h=0;h0){var s={dataIndex:o,seriesIndex:e.seriesIndex};a!=null&&(s.dataType=a),t.push(s)}})}),t}function hi(r,t,e){vc(r,!0),Ur(r,fc),JA(r,t,e)}function KA(r){vc(r,!1)}function di(r,t,e,i){i?KA(r):hi(r,t,e)}function JA(r,t,e){var i=ot(r);t!=null?(i.focus=t,i.blurScope=e):i.focus&&(i.focus=null)}var Id=["emphasis","blur","select"],jA={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function ea(r,t,e,i){e=e||"itemStyle";for(var n=0;n1&&(o*=vf(p),s*=vf(p));var d=(n===a?-1:1)*vf((o*o*(s*s)-o*o*(v*v)-s*s*(c*c))/(o*o*(v*v)+s*s*(c*c)))||0,g=d*o*v/s,y=d*-s*c/o,m=(r+e)/2+hs(h)*g-fs(h)*y,_=(t+i)/2+fs(h)*g+hs(h)*y,S=Od([1,0],[(c-g)/o,(v-y)/s]),b=[(c-g)/o,(v-y)/s],x=[(-1*c-g)/o,(-1*v-y)/s],T=Od(b,x);if(Zh(b,x)<=-1&&(T=Ca),Zh(b,x)>=1&&(T=0),T<0){var C=Math.round(T/Ca*1e6)/1e6;T=Ca*2+C%2*Ca}f.addData(u,m,_,o,s,S,T,h,a)}var nM=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/ig,aM=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function oM(r){var t=new pi;if(!r)return t;var e=0,i=0,n=e,a=i,o,s=pi.CMD,l=r.match(nM);if(!l)return t;for(var u=0;uI*I+R*R&&(C=M,A=D),{cx:C,cy:A,x0:-f,y0:-h,x1:C*(n/b-1),y1:A*(n/b-1)}}function cM(r){var t;if(z(r)){var e=r.length;if(!e)return r;e===1?t=[r[0],r[0],0,0]:e===2?t=[r[0],r[0],r[1],r[1]]:e===3?t=r.concat(r[2]):t=r}else t=[r,r,r,r];return t}function pM(r,t){var e,i=$a(t.r,0),n=$a(t.r0||0,0),a=i>0,o=n>0;if(!(!a&&!o)){if(a||(i=n,n=0),n>i){var s=i;i=n,n=s}var l=t.startAngle,u=t.endAngle;if(!(isNaN(l)||isNaN(u))){var f=t.cx,h=t.cy,c=!!t.clockwise,v=Nd(u-l),p=v>cf&&v%cf;if(p>Xe&&(v=p),!(i>Xe))r.moveTo(f,h);else if(v>cf-Xe)r.moveTo(f+i*Ln(l),h+i*ki(l)),r.arc(f,h,i,l,u,!c),n>Xe&&(r.moveTo(f+n*Ln(u),h+n*ki(u)),r.arc(f,h,n,u,l,c));else{var d=void 0,g=void 0,y=void 0,m=void 0,_=void 0,S=void 0,b=void 0,x=void 0,T=void 0,C=void 0,A=void 0,M=void 0,D=void 0,L=void 0,P=void 0,I=void 0,R=i*Ln(l),k=i*ki(l),V=n*Ln(u),B=n*ki(u),N=v>Xe;if(N){var Y=t.cornerRadius;Y&&(e=cM(Y),d=e[0],g=e[1],y=e[2],m=e[3]);var Z=Nd(i-n)/2;if(_=hr(Z,y),S=hr(Z,m),b=hr(Z,d),x=hr(Z,g),A=T=$a(_,S),M=C=$a(b,x),(T>Xe||C>Xe)&&(D=i*Ln(u),L=i*ki(u),P=n*Ln(l),I=n*ki(l),v<_1)){var $=vM(R,k,P,I,D,L,V,B);if($){var ut=R-$[0],dt=k-$[1],bt=D-$[0],ue=L-$[1],Ae=1/ki(hM((ut*bt+dt*ue)/(so(ut*ut+dt*dt)*so(bt*bt+ue*ue)))/2),me=so($[0]*$[0]+$[1]*$[1]);A=hr(T,(i-me)/(Ae+1)),M=hr(C,(n-me)/(Ae-1))}}}if(!N)r.moveTo(f+R,h+k);else if(A>Xe){var zt=hr(y,A),Pt=hr(m,A),it=vs(P,I,R,k,i,zt,c),ht=vs(D,L,V,B,i,Pt,c);r.moveTo(f+it.cx+it.x0,h+it.cy+it.y0),A0&&r.arc(f+it.cx,h+it.cy,zt,Yt(it.y0,it.x0),Yt(it.y1,it.x1),!c),r.arc(f,h,i,Yt(it.cy+it.y1,it.cx+it.x1),Yt(ht.cy+ht.y1,ht.cx+ht.x1),!c),Pt>0&&r.arc(f+ht.cx,h+ht.cy,Pt,Yt(ht.y1,ht.x1),Yt(ht.y0,ht.x0),!c))}else r.moveTo(f+R,h+k),r.arc(f,h,i,l,u,!c);if(!(n>Xe)||!N)r.lineTo(f+V,h+B);else if(M>Xe){var zt=hr(d,M),Pt=hr(g,M),it=vs(V,B,D,L,n,-Pt,c),ht=vs(R,k,P,I,n,-zt,c);r.lineTo(f+it.cx+it.x0,h+it.cy+it.y0),M0&&r.arc(f+it.cx,h+it.cy,Pt,Yt(it.y0,it.x0),Yt(it.y1,it.x1),!c),r.arc(f,h,n,Yt(it.cy+it.y1,it.cx+it.x1),Yt(ht.cy+ht.y1,ht.cx+ht.x1),c),zt>0&&r.arc(f+ht.cx,h+ht.cy,zt,Yt(ht.y1,ht.x1),Yt(ht.y0,ht.x0),!c))}else r.lineTo(f+V,h+B),r.arc(f,h,n,u,l,c)}r.closePath()}}}var dM=(function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0,this.cornerRadius=0}return r})(),rr=(function(r){E(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new dM},t.prototype.buildPath=function(e,i){pM(e,i)},t.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},t})(gt);rr.prototype.type="sector";var gM=(function(){function r(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return r})(),ua=(function(r){E(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new gM},t.prototype.buildPath=function(e,i){var n=i.cx,a=i.cy,o=Math.PI*2;e.moveTo(n+i.r,a),e.arc(n,a,i.r,0,o,!1),e.moveTo(n+i.r0,a),e.arc(n,a,i.r0,0,o,!0)},t})(gt);ua.prototype.type="ring";function yM(r,t,e,i){var n=[],a=[],o=[],s=[],l,u,f,h;if(i){f=[1/0,1/0],h=[-1/0,-1/0];for(var c=0,v=r.length;c=2){if(i){var a=yM(n,i,e,t.smoothConstraint);r.moveTo(n[0][0],n[0][1]);for(var o=n.length,s=0;s<(e?o:o-1);s++){var l=a[s*2],u=a[s*2+1],f=n[(s+1)%o];r.bezierCurveTo(l[0],l[1],u[0],u[1],f[0],f[1])}}else{r.moveTo(n[0][0],n[0][1]);for(var s=1,h=n.length;sBi[1]){if(s=!1,a)return s;var f=Math.abs(Bi[0]-Oi[1]),h=Math.abs(Oi[0]-Bi[1]);Math.min(f,h)>n.len()&&(f0){var h=f.duration,c=f.delay,v=f.easing,p={duration:h,delay:c||0,easing:v,done:a,force:!!a||!!o,setToFinal:!u,scope:r,during:o};s?t.animateFrom(e,p):t.animateTo(e,p)}else t.stopAnimation(),!s&&t.attr(e),o&&o(1),a&&a()}function Mt(r,t,e,i,n,a){gc("update",r,t,e,i,n,a)}function Jt(r,t,e,i,n,a){gc("enter",r,t,e,i,n,a)}function lo(r){if(!r.__zr)return!0;for(var t=0;tMath.abs(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"}function Vd(r){return!r.isGroup}function DM(r){return r.shape!=null}function ou(r,t,e){if(!r||!t)return;function i(o){var s={};return o.traverse(function(l){Vd(l)&&l.anid&&(s[l.anid]=l)}),s}function n(o){var s={x:o.x,y:o.y,rotation:o.rotation};return DM(o)&&(s.shape=O({},o.shape)),s}var a=i(r);t.traverse(function(o){if(Vd(o)&&o.anid){var s=a[o.anid];if(s){var l=n(o);o.attr(n(s)),Mt(o,l,e,ot(o).dataIndex)}}})}function Sc(r,t){return F(r,function(e){var i=e[0];i=wl(i,t.x),i=Tl(i,t.x+t.width);var n=e[1];return n=wl(n,t.y),n=Tl(n,t.y+t.height),[i,n]})}function M1(r,t){var e=wl(r.x,t.x),i=Tl(r.x+r.width,t.x+t.width),n=wl(r.y,t.y),a=Tl(r.y+r.height,t.y+t.height);if(i>=e&&a>=n)return{x:e,y:n,width:i-e,height:a-n}}function fa(r,t,e){var i=O({rectHover:!0},t),n=i.style={strokeNoScale:!0};if(e=e||{x:-1,y:-1,width:2,height:2},r)return r.indexOf("image://")===0?(n.image=r.slice(8),K(n,e),new ye(i)):nu(r.replace("path://",""),i,e,"center")}function LM(r,t,e,i,n){for(var a=0,o=n[n.length-1];a1)return!1;var g=pf(v,p,f,h)/c;return!(g<0||g>1)}function pf(r,t,e,i){return r*i-e*t}function PM(r){return r<=1e-6&&r>=-1e-6}function mn(r){var t=r.itemTooltipOption,e=r.componentModel,i=r.itemName,n=G(t)?{formatter:t}:t,a=e.mainType,o=e.componentIndex,s={componentType:a,name:i,$vars:["name"]};s[a+"Index"]=o;var l=r.formatterParamsExtra;l&&w(pt(l),function(f){H(s,f)||(s[f]=l[f],s.$vars.push(f))});var u=ot(r.el);u.componentMainType=a,u.componentIndex=o,u.tooltipConfig={name:i,option:K({content:i,encodeHTMLContent:!0,formatterParams:s},n)}}function Gd(r,t){var e;r.isGroup&&(e=t(r)),e||r.traverse(t)}function su(r,t){if(r)if(z(r))for(var e=0;e=0&&s.push(l)}),s}}function _i(r,t){return J(J({},r,!0),t,!0)}const WM={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:". "}}}},YM={time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图",custom:"自定义图表",chart:"图表"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}};var Cl="ZH",xc="EN",$n=xc,tl={},bc={},E1=tt.domSupported?(function(){var r=(document.documentElement.lang||navigator.language||navigator.browserLanguage||$n).toUpperCase();return r.indexOf(Cl)>-1?Cl:$n})():$n;function wc(r,t){r=r.toUpperCase(),bc[r]=new _t(t),tl[r]=t}function UM(r){if(G(r)){var t=tl[r.toUpperCase()]||{};return r===Cl||r===xc?q(t):J(q(t),q(tl[$n]),!1)}else return J(q(r),q(tl[$n]),!1)}function Kh(r){return bc[r]}function XM(){return bc[$n]}wc(xc,WM);wc(Cl,YM);var Tc=1e3,Cc=Tc*60,uo=Cc*60,Ne=uo*24,Zd=Ne*365,qa={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}"},ds="{yyyy}-{MM}-{dd}",$d={year:"{yyyy}",month:"{yyyy}-{MM}",day:ds,hour:ds+" "+qa.hour,minute:ds+" "+qa.minute,second:ds+" "+qa.second,millisecond:qa.none},yf=["year","month","day","hour","minute","second","millisecond"],k1=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function re(r,t){return r+="","0000".substr(0,t-r.length)+r}function qn(r){switch(r){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return r}}function ZM(r){return r===qn(r)}function $M(r){switch(r){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function Zo(r,t,e,i){var n=Te(r),a=n[Ac(e)](),o=n[Kn(e)]()+1,s=Math.floor((o-1)/3)+1,l=n[uu(e)](),u=n["get"+(e?"UTC":"")+"Day"](),f=n[To(e)](),h=(f-1)%12+1,c=n[fu(e)](),v=n[hu(e)](),p=n[vu(e)](),d=f>=12?"pm":"am",g=d.toUpperCase(),y=i instanceof _t?i:Kh(i||E1)||XM(),m=y.getModel("time"),_=m.get("month"),S=m.get("monthAbbr"),b=m.get("dayOfWeek"),x=m.get("dayOfWeekAbbr");return(t||"").replace(/{a}/g,d+"").replace(/{A}/g,g+"").replace(/{yyyy}/g,a+"").replace(/{yy}/g,re(a%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,_[o-1]).replace(/{MMM}/g,S[o-1]).replace(/{MM}/g,re(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,re(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,b[u]).replace(/{ee}/g,x[u]).replace(/{e}/g,u+"").replace(/{HH}/g,re(f,2)).replace(/{H}/g,f+"").replace(/{hh}/g,re(h+"",2)).replace(/{h}/g,h+"").replace(/{mm}/g,re(c,2)).replace(/{m}/g,c+"").replace(/{ss}/g,re(v,2)).replace(/{s}/g,v+"").replace(/{SSS}/g,re(p,3)).replace(/{S}/g,p+"")}function qM(r,t,e,i,n){var a=null;if(G(e))a=e;else if(j(e))a=e(r.value,t,{level:r.level});else{var o=O({},qa);if(r.level>0)for(var s=0;s=0;--s)if(l[u]){a=l[u];break}a=a||o.none}if(z(a)){var h=r.level==null?0:r.level>=0?r.level:a.length+r.level;h=Math.min(h,a.length-1),a=a[h]}}return Zo(new Date(r.value),a,n,i)}function O1(r,t){var e=Te(r),i=e[Kn(t)]()+1,n=e[uu(t)](),a=e[To(t)](),o=e[fu(t)](),s=e[hu(t)](),l=e[vu(t)](),u=l===0,f=u&&s===0,h=f&&o===0,c=h&&a===0,v=c&&n===1,p=v&&i===1;return p?"year":v?"month":c?"day":h?"hour":f?"minute":u?"second":"millisecond"}function qd(r,t,e){var i=yt(r)?Te(r):r;switch(t=t||O1(r,e),t){case"year":return i[Ac(e)]();case"half-year":return i[Kn(e)]()>=6?1:0;case"quarter":return Math.floor((i[Kn(e)]()+1)/4);case"month":return i[Kn(e)]();case"day":return i[uu(e)]();case"half-day":return i[To(e)]()/24;case"hour":return i[To(e)]();case"minute":return i[fu(e)]();case"second":return i[hu(e)]();case"millisecond":return i[vu(e)]()}}function Ac(r){return r?"getUTCFullYear":"getFullYear"}function Kn(r){return r?"getUTCMonth":"getMonth"}function uu(r){return r?"getUTCDate":"getDate"}function To(r){return r?"getUTCHours":"getHours"}function fu(r){return r?"getUTCMinutes":"getMinutes"}function hu(r){return r?"getUTCSeconds":"getSeconds"}function vu(r){return r?"getUTCMilliseconds":"getMilliseconds"}function KM(r){return r?"setUTCFullYear":"setFullYear"}function B1(r){return r?"setUTCMonth":"setMonth"}function N1(r){return r?"setUTCDate":"setDate"}function z1(r){return r?"setUTCHours":"setHours"}function F1(r){return r?"setUTCMinutes":"setMinutes"}function V1(r){return r?"setUTCSeconds":"setSeconds"}function G1(r){return r?"setUTCMilliseconds":"setMilliseconds"}function JM(r,t,e,i,n,a,o,s){var l=new ct({style:{text:r,font:t,align:e,verticalAlign:i,padding:n,rich:a,overflow:o?"truncate":null,lineHeight:s}});return l.getBoundingRect()}function Mc(r){if(!ic(r))return G(r)?r:"-";var t=(r+"").split(".");return t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t.length>1?"."+t[1]:"")}function Dc(r,t){return r=(r||"").toLowerCase().replace(/-(.)/g,function(e,i){return i.toUpperCase()}),t&&r&&(r=r.charAt(0).toUpperCase()+r.slice(1)),r}var _n=Uv;function Jh(r,t,e){var i="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function n(f){return f&&ze(f)?f:"-"}function a(f){return!!(f!=null&&!isNaN(f)&&isFinite(f))}var o=t==="time",s=r instanceof Date;if(o||s){var l=o?Te(r):r;if(isNaN(+l)){if(s)return"-"}else return Zo(l,i,e)}if(t==="ordinal")return ll(r)?n(r):yt(r)&&a(r)?r+"":"-";var u=Gr(r);return a(u)?Mc(u):ll(r)?n(r):typeof r=="boolean"?r+"":"-"}var Kd=["a","b","c","d","e","f","g"],mf=function(r,t){return"{"+r+(t==null?"":t)+"}"};function Lc(r,t,e){z(t)||(t=[t]);var i=t.length;if(!i)return"";for(var n=t[0].$vars||[],a=0;a':'';var o=e.markerId||"markerX";return{renderMode:a,content:"{"+o+"|} ",style:n==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:i}:{width:10,height:10,borderRadius:5,backgroundColor:i}}}function QM(r,t,e){(r==="week"||r==="month"||r==="quarter"||r==="half-year"||r==="year")&&(r=`MM-dd yyyy`);var i=Te(t),n=e?"getUTC":"get",a=i[n+"FullYear"](),o=i[n+"Month"]()+1,s=i[n+"Date"](),l=i[n+"Hours"](),u=i[n+"Minutes"](),f=i[n+"Seconds"](),h=i[n+"Milliseconds"]();return r=r.replace("MM",re(o,2)).replace("M",o).replace("yyyy",a).replace("yy",re(a%100+"",2)).replace("dd",re(s,2)).replace("d",s).replace("hh",re(l,2)).replace("h",l).replace("mm",re(u,2)).replace("m",u).replace("ss",re(f,2)).replace("s",f).replace("SSS",re(h,3)),r}function tD(r){return r&&r.charAt(0).toUpperCase()+r.substr(1)}function cn(r,t){return t=t||"transparent",G(r)?r:X(r)&&r.colorStops&&(r.colorStops[0]||{}).color||t}function Jd(r,t){if(t==="_blank"||t==="blank"){var e=window.open();e.opener=null,e.location.href=r}else window.open(r,t)}var el=w,W1=["left","right","top","bottom","width","height"],Ji=[["width","left","right"],["height","top","bottom"]];function Pc(r,t,e,i,n){var a=0,o=0;i==null&&(i=1/0),n==null&&(n=1/0);var s=0;t.eachChild(function(l,u){var f=l.getBoundingRect(),h=t.childAt(u+1),c=h&&h.getBoundingRect(),v,p;if(r==="horizontal"){var d=f.width+(c?-c.x+f.x:0);v=a+d,v>i||l.newline?(a=0,v=d,o+=s+e,s=f.height):s=Math.max(s,f.height)}else{var g=f.height+(c?-c.y+f.y:0);p=o+g,p>n||l.newline?(a+=s+e,o=0,p=g,s=f.width):s=Math.max(s,f.width)}l.newline||(l.x=a,l.y=o,l.markRedraw(),r==="horizontal"?a=v+e:o=p+e)})}var on=Pc;ft(Pc,"vertical");ft(Pc,"horizontal");function hz(r,t,e){var i=t.width,n=t.height,a=Q(r.left,i),o=Q(r.top,n),s=Q(r.right,i),l=Q(r.bottom,n);return(isNaN(a)||isNaN(parseFloat(r.left)))&&(a=0),(isNaN(s)||isNaN(parseFloat(r.right)))&&(s=i),(isNaN(o)||isNaN(parseFloat(r.top)))&&(o=0),(isNaN(l)||isNaN(parseFloat(r.bottom)))&&(l=n),e=_n(e||0),{width:Math.max(s-a-e[1]-e[3],0),height:Math.max(l-o-e[0]-e[2],0)}}function le(r,t,e){e=_n(e||0);var i=t.width,n=t.height,a=Q(r.left,i),o=Q(r.top,n),s=Q(r.right,i),l=Q(r.bottom,n),u=Q(r.width,i),f=Q(r.height,n),h=e[2]+e[0],c=e[1]+e[3],v=r.aspect;switch(isNaN(u)&&(u=i-s-c-a),isNaN(f)&&(f=n-l-h-o),v!=null&&(isNaN(u)&&isNaN(f)&&(v>i/n?u=i*.8:f=n*.8),isNaN(u)&&(u=v*f),isNaN(f)&&(f=u/v)),isNaN(a)&&(a=i-s-u-c),isNaN(o)&&(o=n-l-f-h),r.left||r.right){case"center":a=i/2-u/2-e[3];break;case"right":a=i-u-c;break}switch(r.top||r.bottom){case"middle":case"center":o=n/2-f/2-e[0];break;case"bottom":o=n-f-h;break}a=a||0,o=o||0,isNaN(u)&&(u=i-c-a-(s||0)),isNaN(f)&&(f=n-h-o-(l||0));var p=new st(a+e[3],o+e[0],u,f);return p.margin=e,p}function Ic(r,t,e,i,n,a){var o=!n||!n.hv||n.hv[0],s=!n||!n.hv||n.hv[1],l=n&&n.boundingMode||"all";if(a=a||r,a.x=r.x,a.y=r.y,!o&&!s)return!1;var u;if(l==="raw")u=r.type==="group"?new st(0,0,+t.width||0,+t.height||0):r.getBoundingRect();else if(u=r.getBoundingRect(),r.needLocalTransform()){var f=r.getLocalTransform();u=u.clone(),u.applyTransform(f)}var h=le(K({width:u.width,height:u.height},t),e,i),c=o?h.x-u.x:0,v=s?h.y-u.y:0;return l==="raw"?(a.x=c,a.y=v):(a.x+=c,a.y+=v),a===r&&r.markRedraw(),!0}function eD(r,t){return r[Ji[t][0]]!=null||r[Ji[t][1]]!=null&&r[Ji[t][2]]!=null}function Co(r){var t=r.layoutMode||r.constructor.layoutMode;return X(t)?t:t?{type:t}:null}function gi(r,t,e){var i=e&&e.ignoreSize;!z(i)&&(i=[i,i]);var n=o(Ji[0],0),a=o(Ji[1],1);u(Ji[0],r,n),u(Ji[1],r,a);function o(f,h){var c={},v=0,p={},d=0,g=2;if(el(f,function(_){p[_]=r[_]}),el(f,function(_){s(t,_)&&(c[_]=p[_]=t[_]),l(c,_)&&v++,l(p,_)&&d++}),i[h])return l(t,f[1])?p[f[2]]=null:l(t,f[2])&&(p[f[1]]=null),p;if(d===g||!v)return p;if(v>=g)return c;for(var y=0;y=0;l--)s=J(s,n[l],!0);i.defaultOption=s}return i.defaultOption},t.prototype.getReferringComponents=function(e,i){var n=e+"Index",a=e+"Id";return Ho(this.ecModel,e,{index:this.get(n,!0),id:this.get(a,!0)},i)},t.prototype.getBoxLayoutParams=function(){var e=this;return{left:e.get("left"),top:e.get("top"),right:e.get("right"),bottom:e.get("bottom"),width:e.get("width"),height:e.get("height")}},t.prototype.getZLevelKey=function(){return""},t.prototype.setZLevel=function(e){this.option.zlevel=e},t.protoInitialize=(function(){var e=t.prototype;e.type="component",e.id="",e.name="",e.mainType="",e.subType="",e.componentIndex=0})(),t})(_t);Z_(at,_t);Jl(at);GM(at);HM(at,iD);function iD(r){var t=[];return w(at.getClassesByMainType(r),function(e){t=t.concat(e.dependencies||e.prototype.dependencies||[])}),t=F(t,function(e){return mr(e).main}),r!=="dataset"&<(t,"dataset")<=0&&t.unshift("dataset"),t}var U1="";typeof navigator!="undefined"&&(U1=navigator.platform||"");var Pn="rgba(0, 0, 0, 0.2)";const nD={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:Pn,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:Pn,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:Pn,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:Pn,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:Pn,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:Pn,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:U1.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 X1=U(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),We="original",ge="arrayRows",nr="objectRows",Tr="keyedColumns",ci="typedArray",Z1="unknown",Br="column",pa="row",Ft={Must:1,Might:2,Not:3},$1=St();function aD(r){$1(r).datasetMap=U()}function oD(r,t,e){var i={},n=Rc(t);if(!n||!r)return i;var a=[],o=[],s=t.ecModel,l=$1(s).datasetMap,u=n.uid+"_"+e.seriesLayoutBy,f,h;r=r.slice(),w(r,function(d,g){var y=X(d)?d:r[g]={name:d};y.type==="ordinal"&&f==null&&(f=g,h=p(y)),i[y.name]=[]});var c=l.get(u)||l.set(u,{categoryWayDim:h,valueWayDim:0});w(r,function(d,g){var y=d.name,m=p(d);if(f==null){var _=c.valueWayDim;v(i[y],_,m),v(o,_,m),c.valueWayDim+=m}else if(f===g)v(i[y],0,m),v(a,0,m);else{var _=c.categoryWayDim;v(i[y],_,m),v(o,_,m),c.categoryWayDim+=m}});function v(d,g,y){for(var m=0;mt)return r[i];return r[e-1]}function j1(r,t,e,i,n,a,o){a=a||r;var s=t(a),l=s.paletteIdx||0,u=s.paletteNameMap=s.paletteNameMap||{};if(u.hasOwnProperty(n))return u[n];var f=o==null||!i?e:hD(i,o);if(f=f||e,!(!f||!f.length)){var h=f[l];return n&&(u[n]=h),s.paletteIdx=(l+1)%f.length,h}}function vD(r,t){t(r).paletteIdx=0,t(r).paletteNameMap={}}var gs,Aa,tg,eg="\0_ec_inner",cD=1,kc=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.init=function(e,i,n,a,o,s){a=a||{},this.option=null,this._theme=new _t(a),this._locale=new _t(o),this._optionManager=s},t.prototype.setOption=function(e,i,n){var a=ng(i);this._optionManager.setOption(e,n,a),this._resetOption(null,a)},t.prototype.resetOption=function(e,i){return this._resetOption(e,ng(i))},t.prototype._resetOption=function(e,i){var n=!1,a=this._optionManager;if(!e||e==="recreate"){var o=a.mountOption(e==="recreate");!this.option||e==="recreate"?tg(this,o):(this.restoreData(),this._mergeOption(o,i)),n=!0}if((e==="timeline"||e==="media")&&this.restoreData(),!e||e==="recreate"||e==="timeline"){var s=a.getTimelineOption(this);s&&(n=!0,this._mergeOption(s,i))}if(!e||e==="recreate"||e==="media"){var l=a.getMediaOption(this);l.length&&w(l,function(u){n=!0,this._mergeOption(u,i)},this)}return n},t.prototype.mergeOption=function(e){this._mergeOption(e,null)},t.prototype._mergeOption=function(e,i){var n=this.option,a=this._componentsMap,o=this._componentsCount,s=[],l=U(),u=i&&i.replaceMergeMainTypeMap;aD(this),w(e,function(h,c){h!=null&&(at.hasClass(c)?c&&(s.push(c),l.set(c,!0)):n[c]=n[c]==null?q(h):J(n[c],h,!0))}),u&&u.each(function(h,c){at.hasClass(c)&&!l.get(c)&&(s.push(c),l.set(c,!0))}),at.topologicalTravel(s,at.getAllClassMainTypes(),f,this);function f(h){var c=uD(this,h,At(e[h])),v=a.get(h),p=v?u&&u.get(h)?"replaceMerge":"normalMerge":"replaceAll",d=H_(v,c,p);RC(d,h,at),n[h]=null,a.set(h,null),o.set(h,0);var g=[],y=[],m=0,_;w(d,function(S,b){var x=S.existing,T=S.newOption;if(!T)x&&(x.mergeOption({},this),x.optionUpdated({},!1));else{var C=h==="series",A=at.getClass(h,S.keyInfo.subType,!C);if(!A)return;if(h==="tooltip"){if(_)return;_=!0}if(x&&x.constructor===A)x.name=S.keyInfo.name,x.mergeOption(T,this),x.optionUpdated(T,!1);else{var M=O({componentIndex:b},S.keyInfo);x=new A(T,this,this,M),O(x,M),S.brandNew&&(x.__requireNewView=!0),x.init(T,this,this),x.optionUpdated(null,!0)}}x?(g.push(x.option),y.push(x),m++):(g.push(void 0),y.push(void 0))},this),n[h]=g,a.set(h,y),o.set(h,m),h==="series"&&gs(this)}this._seriesIndices||gs(this)},t.prototype.getOption=function(){var e=q(this.option);return w(e,function(i,n){if(at.hasClass(n)){for(var a=At(i),o=a.length,s=!1,l=o-1;l>=0;l--)a[l]&&!_o(a[l])?s=!0:(a[l]=null,!s&&o--);a.length=o,e[n]=a}}),delete e[eg],e},t.prototype.getTheme=function(){return this._theme},t.prototype.getLocaleModel=function(){return this._locale},t.prototype.setUpdatePayload=function(e){this._payload=e},t.prototype.getUpdatePayload=function(){return this._payload},t.prototype.getComponent=function(e,i){var n=this._componentsMap.get(e);if(n){var a=n[i||0];if(a)return a;if(i==null){for(var o=0;o=t:e==="max"?r<=t:r===t}function bD(r,t){return r.join(",")===t.join(",")}var Ye=w,Ao=X,ag=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function Sf(r){var t=r&&r.itemStyle;if(t)for(var e=0,i=ag.length;e=0;g--){var y=r[g];if(s||(p=y.data.rawIndexOf(y.stackedByDimension,v)),p>=0){var m=y.data.getByRawIndex(y.stackResultDimension,p);if(l==="all"||l==="positive"&&m>0||l==="negative"&&m<0||l==="samesign"&&c>=0&&m>0||l==="samesign"&&c<=0&&m<0){c=SC(c,m),d=m;break}}}return i[0]=c,i[1]=d,i})})}var pu=(function(){function r(t){this.data=t.data||(t.sourceFormat===Tr?{}:[]),this.sourceFormat=t.sourceFormat||Z1,this.seriesLayoutBy=t.seriesLayoutBy||Br,this.startIndex=t.startIndex||0,this.dimensionsDetectedCount=t.dimensionsDetectedCount,this.metaRawOption=t.metaRawOption;var e=this.dimensionsDefine=t.dimensionsDefine;if(e)for(var i=0;id&&(d=_)}v[0]=p,v[1]=d}},n=function(){return this._data?this._data.length/this._dimSize:0};vg=(t={},t[ge+"_"+Br]={pure:!0,appendData:a},t[ge+"_"+pa]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},t[nr]={pure:!0,appendData:a},t[Tr]={pure:!0,appendData:function(o){var s=this._data;w(o,function(l,u){for(var f=s[u]||(s[u]=[]),h=0;h<(l||[]).length;h++)f.push(l[h])})}},t[We]={appendData:a},t[ci]={persistent:!1,pure:!0,appendData:function(o){this._data=o},clean:function(){this._offset+=this.count(),this._data=null}},t);function a(o){for(var s=0;s=0&&(d=o.interpolatedValue[g])}return d!=null?d+"":""})}},r.prototype.getRawValue=function(t,e){return ra(this.getData(e),t)},r.prototype.formatTooltip=function(t,e,i){},r})();function gg(r){var t,e;return X(r)?r.type&&(e=r):t=r,{text:t,frag:e}}function fo(r){return new FD(r)}var FD=(function(){function r(t){t=t||{},this._reset=t.reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0}return r.prototype.perform=function(t){var e=this._upstream,i=t&&t.skip;if(this._dirty&&e){var n=this.context;n.data=n.outputData=e.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var a;this._plan&&!i&&(a=this._plan(this.context));var o=f(this._modBy),s=this._modDataCount||0,l=f(t&&t.modBy),u=t&&t.modDataCount||0;(o!==l||s!==u)&&(a="reset");function f(m){return!(m>=1)&&(m=1),m}var h;(this._dirty||a==="reset")&&(this._dirty=!1,h=this._doReset(i)),this._modBy=l,this._modDataCount=u;var c=t&&t.step;if(e?this._dueEnd=e._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var v=this._dueIndex,p=Math.min(c!=null?this._dueIndex+c:1/0,this._dueEnd);if(!i&&(h||v1&&i>0?s:o}};return a;function o(){return t=r?null:lt},gte:function(r,t){return r>=t}},GD=(function(){function r(t,e){if(!yt(e)){var i="";ae(i)}this._opFn=uS[t],this._rvalFloat=Gr(e)}return r.prototype.evaluate=function(t){return yt(t)?this._opFn(t,this._rvalFloat):this._opFn(Gr(t),this._rvalFloat)},r})(),HD=(function(){function r(t,e){var i=t==="desc";this._resultLT=i?1:-1,e==null&&(e=i?"min":"max"),this._incomparable=e==="min"?-1/0:1/0}return r.prototype.evaluate=function(t,e){var i=yt(t)?t:Gr(t),n=yt(e)?e:Gr(e),a=isNaN(i),o=isNaN(n);if(a&&(i=this._incomparable),o&&(n=this._incomparable),a&&o){var s=G(t),l=G(e);s&&(i=l?t:0),l&&(n=s?e:0)}return in?-this._resultLT:0},r})(),WD=(function(){function r(t,e){this._rval=e,this._isEQ=t,this._rvalTypeof=typeof e,this._rvalFloat=Gr(e)}return r.prototype.evaluate=function(t){var e=t===this._rval;if(!e){var i=typeof t;i!==this._rvalTypeof&&(i==="number"||this._rvalTypeof==="number")&&(e=Gr(t)===this._rvalFloat)}return this._isEQ?e:!e},r})();function cz(r,t){return r==="eq"||r==="ne"?new WD(r==="eq",t):H(uS,r)?new GD(r,t):null}var YD=(function(){function r(){}return r.prototype.getRawData=function(){throw new Error("not supported")},r.prototype.getRawDataItem=function(t){throw new Error("not supported")},r.prototype.cloneRawData=function(){},r.prototype.getDimensionInfo=function(t){},r.prototype.cloneAllDimensionInfo=function(){},r.prototype.count=function(){},r.prototype.retrieveValue=function(t,e){},r.prototype.retrieveValueFromItem=function(t,e){},r.prototype.convertValue=function(t,e){return rl(t,e)},r})();function UD(r,t){var e=new YD,i=r.data,n=e.sourceFormat=r.sourceFormat,a=r.startIndex,o="";r.seriesLayoutBy!==Br&&ae(o);var s=[],l={},u=r.dimensionsDefine;if(u)w(u,function(d,g){var y=d.name,m={index:g,name:y,displayName:d.displayName};if(s.push(m),y!=null){var _="";H(l,y)&&ae(_),l[y]=m}});else for(var f=0;f65535?QD:t2}function Rn(){return[1/0,-1/0]}function e2(r){var t=r.constructor;return t===Array?r.slice():new t(r)}function _g(r,t,e,i,n){var a=vS[e||"float"];if(n){var o=r[t],s=o&&o.length;if(s!==i){for(var l=new a(i),u=0;ug[1]&&(g[1]=d)}return this._rawCount=this._count=l,{start:s,end:l}},r.prototype._initDataFromProvider=function(t,e,i){for(var n=this._provider,a=this._chunks,o=this._dimensions,s=o.length,l=this._rawExtent,u=F(o,function(m){return m.property}),f=0;fy[1]&&(y[1]=g)}}!n.persistent&&n.clean&&n.clean(),this._rawCount=this._count=e,this._extent=[]},r.prototype.count=function(){return this._count},r.prototype.get=function(t,e){if(!(e>=0&&e=0&&e=this._rawCount||t<0)return-1;if(!this._indices)return t;var e=this._indices,i=e[t];if(i!=null&&it)a=o-1;else return o}return-1},r.prototype.indicesOfNearest=function(t,e,i){var n=this._chunks,a=n[t],o=[];if(!a)return o;i==null&&(i=1/0);for(var s=1/0,l=-1,u=0,f=0,h=this.count();f=0&&l<0)&&(s=p,l=v,u=0),v===l&&(o[u++]=f))}return o.length=u,o},r.prototype.getIndices=function(){var t,e=this._indices;if(e){var i=e.constructor,n=this._count;if(i===Array){t=new i(n);for(var a=0;a=h&&m<=c||isNaN(m))&&(l[u++]=d),d++}p=!0}else if(a===2){for(var g=v[n[0]],_=v[n[1]],S=t[n[1]][0],b=t[n[1]][1],y=0;y=h&&m<=c||isNaN(m))&&(x>=S&&x<=b||isNaN(x))&&(l[u++]=d),d++}p=!0}}if(!p)if(a===1)for(var y=0;y=h&&m<=c||isNaN(m))&&(l[u++]=T)}else for(var y=0;yt[M][1])&&(C=!1)}C&&(l[u++]=e.getRawIndex(y))}return uy[1]&&(y[1]=g)}}}},r.prototype.lttbDownSample=function(t,e){var i=this.clone([t],!0),n=i._chunks,a=n[t],o=this.count(),s=0,l=Math.floor(1/e),u=this.getRawIndex(0),f,h,c,v=new(In(this._rawCount))(Math.min((Math.ceil(o/l)+2)*2,o));v[s++]=u;for(var p=1;pf&&(f=h,c=S)}D>0&&Ds&&(d=s-f);for(var g=0;gp&&(p=m,v=f+g)}var _=this.getRawIndex(h),S=this.getRawIndex(v);hf-p&&(l=f-p,s.length=l);for(var d=0;dh[1]&&(h[1]=y),c[v++]=m}return a._count=v,a._indices=c,a._updateGetRawIdx(),a},r.prototype.each=function(t,e){if(this._count)for(var i=t.length,n=this._chunks,a=0,o=this.count();al&&(l=h)}return o=[s,l],this._extent[t]=o,o},r.prototype.getRawDataItem=function(t){var e=this.getRawIndex(t);if(this._provider.persistent)return this._provider.getItem(e);for(var i=[],n=this._chunks,a=0;a=0?this._indices[t]:-1},r.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},r.internalField=(function(){function t(e,i,n,a){return rl(e[a],this._dimensions[a])}wf={arrayRows:t,objectRows:function(e,i,n,a){return rl(e[i],this._dimensions[a])},keyedColumns:t,original:function(e,i,n,a){var o=e&&(e.value==null?e:e.value);return rl(o instanceof Array?o[a]:o,this._dimensions[a])},typedArray:function(e,i,n,a){return e[a]}}})(),r})(),r2=(function(){function r(t){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=t}return r.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},r.prototype._setLocalSource=function(t,e){this._sourceList=t,this._upstreamSignList=e,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},r.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},r.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},r.prototype._createSource=function(){this._setLocalSource([],[]);var t=this._sourceHost,e=this._getUpstreamSourceManagers(),i=!!e.length,n,a;if(ys(t)){var o=t,s=void 0,l=void 0,u=void 0;if(i){var f=e[0];f.prepareSource(),u=f.getSource(),s=u.data,l=u.sourceFormat,a=[f._getVersionSign()]}else s=o.get("data",!0),l=se(s)?ci:We,a=[];var h=this._getSourceMetaRawOption()||{},c=u&&u.metaRawOption||{},v=rt(h.seriesLayoutBy,c.seriesLayoutBy)||null,p=rt(h.sourceHeader,c.sourceHeader),d=rt(h.dimensions,c.dimensions),g=v!==c.seriesLayoutBy||!!p!=!!c.sourceHeader||d;n=g?[Qh(s,{seriesLayoutBy:v,sourceHeader:p,dimensions:d},l)]:[]}else{var y=t;if(i){var m=this._applyTransform(e);n=m.sourceList,a=m.upstreamSignList}else{var _=y.get("source",!0);n=[Qh(_,this._getSourceMetaRawOption(),null)],a=[]}}this._setLocalSource(n,a)},r.prototype._applyTransform=function(t){var e=this._sourceHost,i=e.get("transform",!0),n=e.get("fromTransformResult",!0);if(n!=null){var a="";t.length!==1&&Sg(a)}var o,s=[],l=[];return w(t,function(u){u.prepareSource();var f=u.getSource(n||0),h="";n!=null&&!f&&Sg(h),s.push(f),l.push(u._getVersionSign())}),i?o=JD(i,s,{datasetIndex:e.componentIndex}):n!=null&&(o=[RD(s[0])]),{sourceList:o,upstreamSignList:l}},r.prototype._isDirty=function(){if(this._dirty)return!0;for(var t=this._getUpstreamSourceManagers(),e=0;e1||e>0&&!r.noHeader;return w(r.blocks,function(n){var a=gS(n);a>=t&&(t=a+ +(i&&(!a||ev(n)&&!n.noHeader)))}),t}return 0}function o2(r,t,e,i){var n=t.noHeader,a=l2(gS(t)),o=[],s=t.blocks||[];we(!s||z(s)),s=s||[];var l=r.orderMode;if(t.sortBlocks&&l){s=s.slice();var u={valueAsc:"asc",valueDesc:"desc"};if(H(u,l)){var f=new HD(u[l],null);s.sort(function(d,g){return f.evaluate(d.sortParam,g.sortParam)})}else l==="seriesDesc"&&s.reverse()}w(s,function(d,g){var y=t.valueFormatter,m=dS(d)(y?O(O({},r),{valueFormatter:y}):r,d,g>0?a.html:0,i);m!=null&&o.push(m)});var h=r.renderMode==="richText"?o.join(a.richText):rv(i,o.join(""),n?e:a.html);if(n)return h;var c=Jh(t.header,"ordinal",r.useUTC),v=pS(i,r.renderMode).nameStyle,p=cS(i);return r.renderMode==="richText"?yS(r,c,v)+a.richText+h:rv(i,'
'+ne(c)+"
"+h,e)}function s2(r,t,e,i){var n=r.renderMode,a=t.noName,o=t.noValue,s=!t.markerType,l=t.name,u=r.useUTC,f=t.valueFormatter||r.valueFormatter||function(S){return S=z(S)?S:[S],F(S,function(b,x){return Jh(b,z(v)?v[x]:v,u)})};if(!(a&&o)){var h=s?"":r.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||"#333",n),c=a?"":Jh(l,"ordinal",u),v=t.valueType,p=o?[]:f(t.value,t.dataIndex),d=!s||!a,g=!s&&a,y=pS(i,n),m=y.nameStyle,_=y.valueStyle;return n==="richText"?(s?"":h)+(a?"":yS(r,c,m))+(o?"":h2(r,p,d,g,_)):rv(i,(s?"":h)+(a?"":u2(c,!s,m))+(o?"":f2(p,d,g,_)),e)}}function xg(r,t,e,i,n,a){if(r){var o=dS(r),s={useUTC:n,renderMode:e,orderMode:i,markupStyleCreator:t,valueFormatter:r.valueFormatter};return o(s,r,0,a)}}function l2(r){return{html:n2[r],richText:a2[r]}}function rv(r,t,e){var i='
',n="margin: "+e+"px 0 0",a=cS(r);return'
'+t+i+"
"}function u2(r,t,e){var i=t?"margin-left:2px":"";return''+ne(r)+""}function f2(r,t,e,i){var n=e?"10px":"20px",a=t?"float:right;margin-left:"+n:"";return r=z(r)?r:[r],''+F(r,function(o){return ne(o)}).join("  ")+""}function yS(r,t,e){return r.markupStyleCreator.wrapRichTextStyle(t,e)}function h2(r,t,e,i,n){var a=[n],o=i?10:20;return e&&a.push({padding:[0,0,0,o],align:"right"}),r.markupStyleCreator.wrapRichTextStyle(z(t)?t.join(" "):t,a)}function mS(r,t){var e=r.getData().getItemVisual(t,"style"),i=e[r.visualDrawType];return cn(i)}function _S(r,t){var e=r.get("padding");return e!=null?e:t==="richText"?[8,10]:10}var Tf=(function(){function r(){this.richTextStyles={},this._nextStyleNameId=z_()}return r.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},r.prototype.makeTooltipMarker=function(t,e,i){var n=i==="richText"?this._generateStyleName():null,a=H1({color:e,type:t,renderMode:i,markerId:n});return G(a)?a:(this.richTextStyles[n]=a.style,a.content)},r.prototype.wrapRichTextStyle=function(t,e){var i={};z(e)?w(e,function(a){return O(i,a)}):O(i,e);var n=this._generateStyleName();return this.richTextStyles[n]=i,"{"+n+"|"+t+"}"},r})();function v2(r){var t=r.series,e=r.dataIndex,i=r.multipleSeries,n=t.getData(),a=n.mapDimensionsAll("defaultedTooltip"),o=a.length,s=t.getRawValue(e),l=z(s),u=mS(t,e),f,h,c,v;if(o>1||l&&!o){var p=c2(s,t,e,a,u);f=p.inlineValues,h=p.inlineValueTypes,c=p.blocks,v=p.inlineValues[0]}else if(o){var d=n.getDimensionInfo(a[0]);v=f=ra(n,e,a[0]),h=d.type}else v=f=l?s[0]:s;var g=nc(t),y=g&&t.name||"",m=n.getName(e),_=i?y:m;return br("section",{header:y,noHeader:i||!g,sortParam:v,blocks:[br("nameValue",{markerType:"item",markerColor:u,name:_,noName:!ze(_),value:f,valueType:h,dataIndex:e})].concat(c||[])})}function c2(r,t,e,i,n){var a=t.getData(),o=Fe(r,function(h,c,v){var p=a.getDimensionInfo(v);return h=h||p&&p.tooltip!==!1&&p.displayName!=null},!1),s=[],l=[],u=[];i.length?w(i,function(h){f(ra(a,e,h),h)}):w(r,f);function f(h,c){var v=a.getDimensionInfo(c);!v||v.otherDims.tooltip===!1||(o?u.push(br("nameValue",{markerType:"subItem",markerColor:n,name:v.displayName,value:h,valueType:v.type})):(s.push(h),l.push(v.type)))}return{inlineValues:s,inlineValueTypes:l,blocks:u}}var Jr=St();function ms(r,t){return r.getName(t)||r.getId(t)}var p2="__universalTransitionEnabled",Qt=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e._selectedDataIndicesMap={},e}return t.prototype.init=function(e,i,n){this.seriesIndex=this.componentIndex,this.dataTask=fo({count:g2,reset:y2}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(e,n);var a=Jr(this).sourceManager=new r2(this);a.prepareSource();var o=this.getInitialData(e,n);wg(o,this),this.dataTask.context.data=o,Jr(this).dataBeforeProcessed=o,bg(this),this._initSelectedMapFromData(o)},t.prototype.mergeDefaultAndTheme=function(e,i){var n=Co(this),a=n?ca(e):{},o=this.subType;at.hasClass(o)&&(o+="Series"),J(e,i.getTheme().get(this.subType)),J(e,this.getDefaultOption()),_l(e,"label",["show"]),this.fillDataTextStyle(e.data),n&&gi(e,a,n)},t.prototype.mergeOption=function(e,i){e=J(this.option,e,!0),this.fillDataTextStyle(e.data);var n=Co(this);n&&gi(this.option,e,n);var a=Jr(this).sourceManager;a.dirty(),a.prepareSource();var o=this.getInitialData(e,i);wg(o,this),this.dataTask.dirty(),this.dataTask.context.data=o,Jr(this).dataBeforeProcessed=o,bg(this),this._initSelectedMapFromData(o)},t.prototype.fillDataTextStyle=function(e){if(e&&!se(e))for(var i=["show"],n=0;nthis.getShallow("animationThreshold")&&(i=!1),!!i},t.prototype.restoreData=function(){this.dataTask.dirty()},t.prototype.getColorFromPalette=function(e,i,n){var a=this.ecModel,o=Ec.prototype.getColorFromPalette.call(this,e,i,n);return o||(o=a.getColorFromPalette(e,i,n)),o},t.prototype.coordDimToDataDim=function(e){return this.getRawData().mapDimensionsAll(e)},t.prototype.getProgressive=function(){return this.get("progressive")},t.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},t.prototype.select=function(e,i){this._innerSelect(this.getData(i),e)},t.prototype.unselect=function(e,i){var n=this.option.selectedMap;if(n){var a=this.option.selectedMode,o=this.getData(i);if(a==="series"||n==="all"){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var s=0;s=0&&n.push(o)}return n},t.prototype.isSelected=function(e,i){var n=this.option.selectedMap;if(!n)return!1;var a=this.getData(i);return(n==="all"||n[ms(a,e)])&&!a.getItemModel(e).get(["select","disabled"])},t.prototype.isUniversalTransitionEnabled=function(){if(this[p2])return!0;var e=this.option.universalTransition;return e?e===!0?!0:e&&e.enabled:!1},t.prototype._innerSelect=function(e,i){var n,a,o=this.option,s=o.selectedMode,l=i.length;if(!(!s||!l)){if(s==="series")o.selectedMap="all";else if(s==="multiple"){X(o.selectedMap)||(o.selectedMap={});for(var u=o.selectedMap,f=0;f0&&this._innerSelect(e,i)}},t.registerClass=function(e){return at.registerClass(e)},t.protoInitialize=(function(){var e=t.prototype;e.type="series.__base__",e.seriesIndex=0,e.ignoreStyleOnData=!1,e.hasSymbolVisual=!1,e.defaultSymbol="circle",e.visualStyleAccessPath="itemStyle",e.visualDrawType="fill"})(),t})(at);Wt(Qt,lS);Wt(Qt,Ec);Z_(Qt,at);function bg(r){var t=r.name;nc(r)||(r.name=d2(r)||t)}function d2(r){var t=r.getRawData(),e=t.mapDimensionsAll("seriesName"),i=[];return w(e,function(n){var a=t.getDimensionInfo(n);a.displayName&&i.push(a.displayName)}),i.join(" ")}function g2(r){return r.model.getRawData().count()}function y2(r){var t=r.model;return t.setData(t.getRawData().cloneShallow()),m2}function m2(r,t){t.outputData&&r.end>t.outputData.count()&&t.model.getRawData().cloneShallow(t.outputData)}function wg(r,t){w(s_(r.CHANGABLE_METHODS,r.DOWNSAMPLE_METHODS),function(e){r.wrapMethod(e,ft(_2,t))})}function _2(r,t){var e=iv(r);return e&&e.setOutputEnd((t||this).count()),t}function iv(r){var t=(r.ecModel||{}).scheduler,e=t&&t.getPipeline(r.uid);if(e){var i=e.currentTask;if(i){var n=i.agentStubMap;n&&(i=n.get(r.uid))}return i}}var Ct=(function(){function r(){this.group=new nt,this.uid=va("viewComponent")}return r.prototype.init=function(t,e){},r.prototype.render=function(t,e,i,n){},r.prototype.dispose=function(t,e){},r.prototype.updateView=function(t,e,i,n){},r.prototype.updateLayout=function(t,e,i,n){},r.prototype.updateVisual=function(t,e,i,n){},r.prototype.toggleBlurSeries=function(t,e,i){},r.prototype.eachRendered=function(t){var e=this.group;e&&e.traverse(t)},r})();oc(Ct);Jl(Ct);function Fc(){var r=St();return function(t){var e=r(t),i=t.pipelineContext,n=!!e.large,a=!!e.progressiveRender,o=e.large=!!(i&&i.large),s=e.progressiveRender=!!(i&&i.progressiveRender);return(n!==o||a!==s)&&"reset"}}var SS=St(),S2=Fc(),Nt=(function(){function r(){this.group=new nt,this.uid=va("viewChart"),this.renderTask=fo({plan:x2,reset:b2}),this.renderTask.context={view:this}}return r.prototype.init=function(t,e){},r.prototype.render=function(t,e,i,n){},r.prototype.highlight=function(t,e,i,n){var a=t.getData(n&&n.dataType);a&&Cg(a,n,"emphasis")},r.prototype.downplay=function(t,e,i,n){var a=t.getData(n&&n.dataType);a&&Cg(a,n,"normal")},r.prototype.remove=function(t,e){this.group.removeAll()},r.prototype.dispose=function(t,e){},r.prototype.updateView=function(t,e,i,n){this.render(t,e,i,n)},r.prototype.updateLayout=function(t,e,i,n){this.render(t,e,i,n)},r.prototype.updateVisual=function(t,e,i,n){this.render(t,e,i,n)},r.prototype.eachRendered=function(t){su(this.group,t)},r.markUpdateMethod=function(t,e){SS(t).updateMethod=e},r.protoInitialize=(function(){var t=r.prototype;t.type="chart"})(),r})();function Tg(r,t,e){r&&Uh(r)&&(t==="emphasis"?Qn:ta)(r,e)}function Cg(r,t,e){var i=vn(r,t),n=t&&t.highlightKey!=null?tM(t.highlightKey):null;i!=null?w(At(i),function(a){Tg(r.getItemGraphicEl(a),e,n)}):r.eachItemGraphicEl(function(a){Tg(a,e,n)})}oc(Nt);Jl(Nt);function x2(r){return S2(r.model)}function b2(r){var t=r.model,e=r.ecModel,i=r.api,n=r.payload,a=t.pipelineContext.progressiveRender,o=r.view,s=n&&SS(n).updateMethod,l=a?"incrementalPrepareRender":s&&o[s]?s:"render";return l!=="render"&&o[l](t,e,i,n),w2[l]}var w2={incrementalPrepareRender:{progress:function(r,t){t.view.incrementalRender(r,t.model,t.ecModel,t.api,t.payload)}},render:{forceFirstProgress:!0,progress:function(r,t){t.view.render(t.model,t.ecModel,t.api,t.payload)}}},Al="\0__throttleOriginMethod",Ag="\0__throttleRate",Mg="\0__throttleType";function gu(r,t,e){var i,n=0,a=0,o=null,s,l,u,f;t=t||0;function h(){a=new Date().getTime(),o=null,r.apply(l,u||[])}var c=function(){for(var v=[],p=0;p=0?h():o=setTimeout(h,-s),n=i};return c.clear=function(){o&&(clearTimeout(o),o=null)},c.debounceNextCall=function(v){f=v},c}function $o(r,t,e,i){var n=r[t];if(n){var a=n[Al]||n,o=n[Mg],s=n[Ag];if(s!==e||o!==i){if(e==null||!i)return r[t]=a;n=r[t]=gu(a,e,i==="debounce"),n[Al]=a,n[Mg]=i,n[Ag]=e}return n}}function Mo(r,t){var e=r[t];e&&e[Al]&&(e.clear&&e.clear(),r[t]=e[Al])}var Dg=St(),Lg={itemStyle:jn(R1,!0),lineStyle:jn(I1,!0)},T2={lineStyle:"stroke",itemStyle:"fill"};function xS(r,t){var e=r.visualStyleMapper||Lg[t];return e||Lg.itemStyle}function bS(r,t){var e=r.visualDrawType||T2[t];return e||"fill"}var C2={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){var e=r.getData(),i=r.visualStyleAccessPath||"itemStyle",n=r.getModel(i),a=xS(r,i),o=a(n),s=n.getShallow("decal");s&&(e.setVisual("decal",s),s.dirty=!0);var l=bS(r,i),u=o[l],f=j(u)?u:null,h=o.fill==="auto"||o.stroke==="auto";if(!o[l]||f||h){var c=r.getColorFromPalette(r.name,null,t.getSeriesCount());o[l]||(o[l]=c,e.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||j(o.fill)?c:o.fill,o.stroke=o.stroke==="auto"||j(o.stroke)?c:o.stroke}if(e.setVisual("style",o),e.setVisual("drawType",l),!t.isSeriesFiltered(r)&&f)return e.setVisual("colorFromPalette",!1),{dataEach:function(v,p){var d=r.getDataParams(p),g=O({},o);g[l]=f(d),v.setItemVisual(p,"style",g)}}}},Da=new _t,A2={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){if(!(r.ignoreStyleOnData||t.isSeriesFiltered(r))){var e=r.getData(),i=r.visualStyleAccessPath||"itemStyle",n=xS(r,i),a=e.getVisual("drawType");return{dataEach:e.hasItemOption?function(o,s){var l=o.getRawDataItem(s);if(l&&l[i]){Da.option=l[i];var u=n(Da),f=o.ensureUniqueItemVisual(s,"style");O(f,u),Da.option.decal&&(o.setItemVisual(s,"decal",Da.option.decal),Da.option.decal.dirty=!0),a in u&&o.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},M2={performRawSeries:!0,overallReset:function(r){var t=U();r.eachSeries(function(e){var i=e.getColorBy();if(!e.isColorBySeries()){var n=e.type+"-"+i,a=t.get(n);a||(a={},t.set(n,a)),Dg(e).scope=a}}),r.eachSeries(function(e){if(!(e.isColorBySeries()||r.isSeriesFiltered(e))){var i=e.getRawData(),n={},a=e.getData(),o=Dg(e).scope,s=e.visualStyleAccessPath||"itemStyle",l=bS(e,s);a.each(function(u){var f=a.getRawIndex(u);n[f]=u}),i.each(function(u){var f=n[u],h=a.getItemVisual(f,"colorFromPalette");if(h){var c=a.ensureUniqueItemVisual(f,"style"),v=i.getName(u)||u+"",p=i.count();c[l]=e.getColorFromPalette(v,o,p)}})}})}},_s=Math.PI;function D2(r,t){t=t||{},K(t,{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 e=new nt,i=new vt({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4});e.add(i);var n=new ct({style:{text:t.text,fill:t.textColor,fontSize:t.fontSize,fontWeight:t.fontWeight,fontStyle:t.fontStyle,fontFamily:t.fontFamily},zlevel:t.zlevel,z:10001}),a=new vt({style:{fill:"none"},textContent:n,textConfig:{position:"right",distance:10},zlevel:t.zlevel,z:10001});e.add(a);var o;return t.showSpinner&&(o=new Yo({shape:{startAngle:-_s/2,endAngle:-_s/2+.1,r:t.spinnerRadius},style:{stroke:t.color,lineCap:"round",lineWidth:t.lineWidth},zlevel:t.zlevel,z:10001}),o.animateShape(!0).when(1e3,{endAngle:_s*3/2}).start("circularInOut"),o.animateShape(!0).when(1e3,{startAngle:_s*3/2}).delay(300).start("circularInOut"),e.add(o)),e.resize=function(){var s=n.getBoundingRect().width,l=t.showSpinner?t.spinnerRadius:0,u=(r.getWidth()-l*2-(t.showSpinner&&s?10:0)-s)/2-(t.showSpinner&&s?0:5+s/2)+(t.showSpinner?0:s/2)+(s?0:l),f=r.getHeight()/2;t.showSpinner&&o.setShape({cx:u,cy:f}),a.setShape({x:u-l,y:f-l,width:l*2,height:l*2}),i.setShape({x:0,y:0,width:r.getWidth(),height:r.getHeight()})},e.resize(),e}var wS=(function(){function r(t,e,i,n){this._stageTaskMap=U(),this.ecInstance=t,this.api=e,i=this._dataProcessorHandlers=i.slice(),n=this._visualHandlers=n.slice(),this._allHandlers=i.concat(n)}return r.prototype.restoreData=function(t,e){t.restoreData(e),this._stageTaskMap.each(function(i){var n=i.overallTask;n&&n.dirty()})},r.prototype.getPerformArgs=function(t,e){if(t.__pipeline){var i=this._pipelineMap.get(t.__pipeline.id),n=i.context,a=!e&&i.progressiveEnabled&&(!n||n.progressiveRender)&&t.__idxInPipeline>i.blockIndex,o=a?i.step:null,s=n&&n.modDataCount,l=s!=null?Math.ceil(s/o):null;return{step:o,modBy:l,modDataCount:s}}},r.prototype.getPipeline=function(t){return this._pipelineMap.get(t)},r.prototype.updateStreamModes=function(t,e){var i=this._pipelineMap.get(t.uid),n=t.getData(),a=n.count(),o=i.progressiveEnabled&&e.incrementalPrepareRender&&a>=i.threshold,s=t.get("large")&&a>=t.get("largeThreshold"),l=t.get("progressiveChunkMode")==="mod"?a:null;t.pipelineContext=i.context={progressiveRender:o,modDataCount:l,large:s}},r.prototype.restorePipelines=function(t){var e=this,i=e._pipelineMap=U();t.eachSeries(function(n){var a=n.getProgressive(),o=n.uid;i.set(o,{id:o,head:null,tail:null,threshold:n.getProgressiveThreshold(),progressiveEnabled:a&&!(n.preventIncremental&&n.preventIncremental()),blockIndex:-1,step:Math.round(a||700),count:0}),e._pipe(n,n.dataTask)})},r.prototype.prepareStageTasks=function(){var t=this._stageTaskMap,e=this.api.getModel(),i=this.api;w(this._allHandlers,function(n){var a=t.get(n.uid)||t.set(n.uid,{}),o="";we(!(n.reset&&n.overallReset),o),n.reset&&this._createSeriesStageTask(n,a,e,i),n.overallReset&&this._createOverallStageTask(n,a,e,i)},this)},r.prototype.prepareView=function(t,e,i,n){var a=t.renderTask,o=a.context;o.model=e,o.ecModel=i,o.api=n,a.__block=!t.incrementalPrepareRender,this._pipe(e,a)},r.prototype.performDataProcessorTasks=function(t,e){this._performStageTasks(this._dataProcessorHandlers,t,e,{block:!0})},r.prototype.performVisualTasks=function(t,e,i){this._performStageTasks(this._visualHandlers,t,e,i)},r.prototype._performStageTasks=function(t,e,i,n){n=n||{};var a=!1,o=this;w(t,function(l,u){if(!(n.visualType&&n.visualType!==l.visualType)){var f=o._stageTaskMap.get(l.uid),h=f.seriesTaskMap,c=f.overallTask;if(c){var v,p=c.agentStubMap;p.each(function(g){s(n,g)&&(g.dirty(),v=!0)}),v&&c.dirty(),o.updatePayload(c,i);var d=o.getPerformArgs(c,n.block);p.each(function(g){g.perform(d)}),c.perform(d)&&(a=!0)}else h&&h.each(function(g,y){s(n,g)&&g.dirty();var m=o.getPerformArgs(g,n.block);m.skip=!l.performRawSeries&&e.isSeriesFiltered(g.context.model),o.updatePayload(g,i),g.perform(m)&&(a=!0)})}});function s(l,u){return l.setDirty&&(!l.dirtyMap||l.dirtyMap.get(u.__pipeline.id))}this.unfinished=a||this.unfinished},r.prototype.performSeriesTasks=function(t){var e;t.eachSeries(function(i){e=i.dataTask.perform()||e}),this.unfinished=e||this.unfinished},r.prototype.plan=function(){this._pipelineMap.each(function(t){var e=t.tail;do{if(e.__block){t.blockIndex=e.__idxInPipeline;break}e=e.getUpstream()}while(e)})},r.prototype.updatePayload=function(t,e){e!=="remain"&&(t.context.payload=e)},r.prototype._createSeriesStageTask=function(t,e,i,n){var a=this,o=e.seriesTaskMap,s=e.seriesTaskMap=U(),l=t.seriesType,u=t.getTargetSeries;t.createOnAllSeries?i.eachRawSeries(f):l?i.eachRawSeriesByType(l,f):u&&u(i,n).each(f);function f(h){var c=h.uid,v=s.set(c,o&&o.get(c)||fo({plan:E2,reset:k2,count:B2}));v.context={model:h,ecModel:i,api:n,useClearVisual:t.isVisual&&!t.isLayout,plan:t.plan,reset:t.reset,scheduler:a},a._pipe(h,v)}},r.prototype._createOverallStageTask=function(t,e,i,n){var a=this,o=e.overallTask=e.overallTask||fo({reset:L2});o.context={ecModel:i,api:n,overallReset:t.overallReset,scheduler:a};var s=o.agentStubMap,l=o.agentStubMap=U(),u=t.seriesType,f=t.getTargetSeries,h=!0,c=!1,v="";we(!t.createOnAllSeries,v),u?i.eachRawSeriesByType(u,p):f?f(i,n).each(p):(h=!1,w(i.getSeries(),p));function p(d){var g=d.uid,y=l.set(g,s&&s.get(g)||(c=!0,fo({reset:P2,onDirty:R2})));y.context={model:d,overallProgress:h},y.agent=o,y.__block=h,a._pipe(d,y)}c&&o.dirty()},r.prototype._pipe=function(t,e){var i=t.uid,n=this._pipelineMap.get(i);!n.head&&(n.head=e),n.tail&&n.tail.pipe(e),n.tail=e,e.__idxInPipeline=n.count++,e.__pipeline=n},r.wrapStageHandler=function(t,e){return j(t)&&(t={overallReset:t,seriesType:N2(t)}),t.uid=va("stageHandler"),e&&(t.visualType=e),t},r})();function L2(r){r.overallReset(r.ecModel,r.api,r.payload)}function P2(r){return r.overallProgress&&I2}function I2(){this.agent.dirty(),this.getDownstream().dirty()}function R2(){this.agent&&this.agent.dirty()}function E2(r){return r.plan?r.plan(r.model,r.ecModel,r.api,r.payload):null}function k2(r){r.useClearVisual&&r.data.clearAllVisual();var t=r.resetDefines=At(r.reset(r.model,r.ecModel,r.api,r.payload));return t.length>1?F(t,function(e,i){return TS(i)}):O2}var O2=TS(0);function TS(r){return function(t,e){var i=e.data,n=e.resetDefines[r];if(n&&n.dataEach)for(var a=t.start;a0&&v===u.length-c.length){var p=u.slice(0,v);p!=="data"&&(e.mainType=p,e[c.toLowerCase()]=l,f=!0)}}s.hasOwnProperty(u)&&(i[u]=l,f=!0),f||(n[u]=l)})}return{cptQuery:e,dataQuery:i,otherQuery:n}},r.prototype.filter=function(t,e){var i=this.eventInfo;if(!i)return!0;var n=i.targetEl,a=i.packedEvent,o=i.model,s=i.view;if(!o||!s)return!0;var l=e.cptQuery,u=e.dataQuery;return f(l,o,"mainType")&&f(l,o,"subType")&&f(l,o,"index","componentIndex")&&f(l,o,"name")&&f(l,o,"id")&&f(u,a,"name")&&f(u,a,"dataIndex")&&f(u,a,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(t,e.otherQuery,n,a));function f(h,c,v,p){return h[v]==null||c[p||v]===h[v]}},r.prototype.afterTrigger=function(){this.eventInfo=null},r})(),nv=["symbol","symbolSize","symbolRotate","symbolOffset"],Eg=nv.concat(["symbolKeepAspect"]),V2={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){var e=r.getData();if(r.legendIcon&&e.setVisual("legendIcon",r.legendIcon),!r.hasSymbolVisual)return;for(var i={},n={},a=!1,o=0;o=0&&Qi(l)?l:.5;var u=r.createRadialGradient(o,s,0,o,s,l);return u}function av(r,t,e){for(var i=t.type==="radial"?eL(r,t,e):tL(r,t,e),n=t.colorStops,a=0;a0)?null:r==="dashed"?[4*t,2*t]:r==="dotted"?[t]:yt(r)?[r]:z(r)?r:null}function IS(r){var t=r.style,e=t.lineDash&&t.lineWidth>0&&iL(t.lineDash,t.lineWidth),i=t.lineDashOffset;if(e){var n=t.strokeNoScale&&r.getLineScale?r.getLineScale():1;n&&n!==1&&(e=F(e,function(a){return a/n}),i/=n)}return[e,i]}var nL=new pi(!0);function Ll(r){var t=r.stroke;return!(t==null||t==="none"||!(r.lineWidth>0))}function kg(r){return typeof r=="string"&&r!=="none"}function Pl(r){var t=r.fill;return t!=null&&t!=="none"}function Og(r,t){if(t.fillOpacity!=null&&t.fillOpacity!==1){var e=r.globalAlpha;r.globalAlpha=t.fillOpacity*t.opacity,r.fill(),r.globalAlpha=e}else r.fill()}function Bg(r,t){if(t.strokeOpacity!=null&&t.strokeOpacity!==1){var e=r.globalAlpha;r.globalAlpha=t.strokeOpacity*t.opacity,r.stroke(),r.globalAlpha=e}else r.stroke()}function ov(r,t,e){var i=$_(t.image,t.__image,e);if(jl(i)){var n=r.createPattern(i,t.repeat||"repeat");if(typeof DOMMatrix=="function"&&n&&n.setTransform){var a=new DOMMatrix;a.translateSelf(t.x||0,t.y||0),a.rotateSelf(0,0,(t.rotation||0)*Qa),a.scaleSelf(t.scaleX||1,t.scaleY||1),n.setTransform(a)}return n}}function aL(r,t,e,i){var n,a=Ll(e),o=Pl(e),s=e.strokePercent,l=s<1,u=!t.path;(!t.silent||l)&&u&&t.createPathProxy();var f=t.path||nL,h=t.__dirty;if(!i){var c=e.fill,v=e.stroke,p=o&&!!c.colorStops,d=a&&!!v.colorStops,g=o&&!!c.image,y=a&&!!v.image,m=void 0,_=void 0,S=void 0,b=void 0,x=void 0;(p||d)&&(x=t.getBoundingRect()),p&&(m=h?av(r,c,x):t.__canvasFillGradient,t.__canvasFillGradient=m),d&&(_=h?av(r,v,x):t.__canvasStrokeGradient,t.__canvasStrokeGradient=_),g&&(S=h||!t.__canvasFillPattern?ov(r,c,t):t.__canvasFillPattern,t.__canvasFillPattern=S),y&&(b=h||!t.__canvasStrokePattern?ov(r,v,t):t.__canvasStrokePattern,t.__canvasStrokePattern=S),p?r.fillStyle=m:g&&(S?r.fillStyle=S:o=!1),d?r.strokeStyle=_:y&&(b?r.strokeStyle=b:a=!1)}var T=t.getGlobalScale();f.setScale(T[0],T[1],t.segmentIgnoreThreshold);var C,A;r.setLineDash&&e.lineDash&&(n=IS(t),C=n[0],A=n[1]);var M=!0;(u||h&Vn)&&(f.setDPR(r.dpr),l?f.setContext(null):(f.setContext(r),M=!1),f.reset(),t.buildPath(f,t.shape,i),f.toStatic(),t.pathUpdated()),M&&f.rebuildPath(r,l?s:1),C&&(r.setLineDash(C),r.lineDashOffset=A),i||(e.strokeFirst?(a&&Bg(r,e),o&&Og(r,e)):(o&&Og(r,e),a&&Bg(r,e))),C&&r.setLineDash([])}function oL(r,t,e){var i=t.__image=$_(e.image,t.__image,t,t.onload);if(!(!i||!jl(i))){var n=e.x||0,a=e.y||0,o=t.getWidth(),s=t.getHeight(),l=i.width/i.height;if(o==null&&s!=null?o=s*l:s==null&&o!=null?s=o/l:o==null&&s==null&&(o=i.width,s=i.height),e.sWidth&&e.sHeight){var u=e.sx||0,f=e.sy||0;r.drawImage(i,u,f,e.sWidth,e.sHeight,n,a,o,s)}else if(e.sx&&e.sy){var u=e.sx,f=e.sy,h=o-u,c=s-f;r.drawImage(i,u,f,h,c,n,a,o,s)}else r.drawImage(i,n,a,o,s)}}function sL(r,t,e){var i,n=e.text;if(n!=null&&(n+=""),n){r.font=e.font||fn,r.textAlign=e.textAlign,r.textBaseline=e.textBaseline;var a=void 0,o=void 0;r.setLineDash&&e.lineDash&&(i=IS(t),a=i[0],o=i[1]),a&&(r.setLineDash(a),r.lineDashOffset=o),e.strokeFirst?(Ll(e)&&r.strokeText(n,e.x,e.y),Pl(e)&&r.fillText(n,e.x,e.y)):(Pl(e)&&r.fillText(n,e.x,e.y),Ll(e)&&r.strokeText(n,e.x,e.y)),a&&r.setLineDash([])}}var Ng=["shadowBlur","shadowOffsetX","shadowOffsetY"],zg=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function RS(r,t,e,i,n){var a=!1;if(!i&&(e=e||{},t===e))return!1;if(i||t.opacity!==e.opacity){pe(r,n),a=!0;var o=Math.max(Math.min(t.opacity,1),0);r.globalAlpha=isNaN(o)?nn.opacity:o}(i||t.blend!==e.blend)&&(a||(pe(r,n),a=!0),r.globalCompositeOperation=t.blend||nn.blend);for(var s=0;s0&&e.unfinished);e.unfinished||this._zr.flush()}}},t.prototype.getDom=function(){return this._dom},t.prototype.getId=function(){return this.id},t.prototype.getZr=function(){return this._zr},t.prototype.isSSR=function(){return this._ssr},t.prototype.setOption=function(e,i,n){if(!this[Ut]){if(this._disposed){this.id;return}var a,o,s;if(X(i)&&(n=i.lazyUpdate,a=i.silent,o=i.replaceMerge,s=i.transition,i=i.notMerge),this[Ut]=!0,!this._model||i){var l=new mD(this._api),u=this._theme,f=this._model=new kc;f.scheduler=this._scheduler,f.ssr=this._ssr,f.init(null,null,null,u,this._locale,l)}this._model.setOption(e,{replaceMerge:o},lv);var h={seriesTransition:s,optionChanged:!0};if(n)this[he]={silent:a,updateParams:h},this[Ut]=!1,this.getZr().wakeUp();else{try{kn(this),jr.update.call(this,null,h)}catch(c){throw this[he]=null,this[Ut]=!1,c}this._ssr||this._zr.flush(),this[he]=null,this[Ut]=!1,La.call(this,a),Pa.call(this,a)}}},t.prototype.setTheme=function(){},t.prototype.getModel=function(){return this._model},t.prototype.getOption=function(){return this._model&&this._model.getOption()},t.prototype.getWidth=function(){return this._zr.getWidth()},t.prototype.getHeight=function(){return this._zr.getHeight()},t.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||tt.hasGlobalWindow&&window.devicePixelRatio||1},t.prototype.getRenderedCanvas=function(e){return this.renderToCanvas(e)},t.prototype.renderToCanvas=function(e){e=e||{};var i=this._zr.painter;return i.getRenderedCanvas({backgroundColor:e.backgroundColor||this._model.get("backgroundColor"),pixelRatio:e.pixelRatio||this.getDevicePixelRatio()})},t.prototype.renderToSVGString=function(e){e=e||{};var i=this._zr.painter;return i.renderToString({useViewBox:e.useViewBox})},t.prototype.getSvgDataURL=function(){if(tt.svgSupported){var e=this._zr,i=e.storage.getDisplayList();return w(i,function(n){n.stopAnimation(null,!0)}),e.painter.toDataURL()}},t.prototype.getDataURL=function(e){if(this._disposed){this.id;return}e=e||{};var i=e.excludeComponents,n=this._model,a=[],o=this;w(i,function(l){n.eachComponent({mainType:l},function(u){var f=o._componentsMap[u.__viewId];f.group.ignore||(a.push(f),f.group.ignore=!0)})});var s=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(e).toDataURL("image/"+(e&&e.type||"png"));return w(a,function(l){l.group.ignore=!1}),s},t.prototype.getConnectedDataURL=function(e){if(this._disposed){this.id;return}var i=e.type==="svg",n=this.group,a=Math.min,o=Math.max,s=1/0;if(Ol[n]){var l=s,u=s,f=-s,h=-s,c=[],v=e&&e.pixelRatio||this.getDevicePixelRatio();w(sn,function(_,S){if(_.group===n){var b=i?_.getZr().painter.getSvgDom().innerHTML:_.renderToCanvas(q(e)),x=_.getDom().getBoundingClientRect();l=a(x.left,l),u=a(x.top,u),f=o(x.right,f),h=o(x.bottom,h),c.push({dom:b,left:x.left,top:x.top})}}),l*=v,u*=v,f*=v,h*=v;var p=f-l,d=h-u,g=Nr.createCanvas(),y=Bh(g,{renderer:i?"svg":"canvas"});if(y.resize({width:p,height:d}),i){var m="";return w(c,function(_){var S=_.left-l,b=_.top-u;m+=''+_.dom+""}),y.painter.getSvgRoot().innerHTML=m,e.connectedBackgroundColor&&y.painter.setBackgroundColor(e.connectedBackgroundColor),y.refreshImmediately(),y.painter.toDataURL()}else return e.connectedBackgroundColor&&y.add(new vt({shape:{x:0,y:0,width:p,height:d},style:{fill:e.connectedBackgroundColor}})),w(c,function(_){var S=new ye({style:{x:_.left*v-l,y:_.top*v-u,image:_.dom}});y.add(S)}),y.refreshImmediately(),g.toDataURL("image/"+(e&&e.type||"png"))}else return this.getDataURL(e)},t.prototype.convertToPixel=function(e,i){return Lf(this,"convertToPixel",e,i)},t.prototype.convertFromPixel=function(e,i){return Lf(this,"convertFromPixel",e,i)},t.prototype.containPixel=function(e,i){if(this._disposed){this.id;return}var n=this._model,a,o=no(n,e);return w(o,function(s,l){l.indexOf("Models")>=0&&w(s,function(u){var f=u.coordinateSystem;if(f&&f.containPoint)a=a||!!f.containPoint(i);else if(l==="seriesModels"){var h=this._chartsMap[u.__viewId];h&&h.containPoint&&(a=a||h.containPoint(i,u))}},this)},this),!!a},t.prototype.getVisual=function(e,i){var n=this._model,a=no(n,e,{defaultMainType:"series"}),o=a.seriesModel,s=o.getData(),l=a.hasOwnProperty("dataIndexInside")?a.dataIndexInside:a.hasOwnProperty("dataIndex")?s.indexOfRawIndex(a.dataIndex):null;return l!=null?Vc(s,l,i):DS(s,i)},t.prototype.getViewOfComponentModel=function(e){return this._componentsMap[e.__viewId]},t.prototype.getViewOfSeriesModel=function(e){return this._chartsMap[e.__viewId]},t.prototype._initEvents=function(){var e=this;w(RL,function(i){var n=function(a){var o=e.getModel(),s=a.target,l,u=i==="globalout";if(u?l={}:s&&ji(s,function(p){var d=ot(p);if(d&&d.dataIndex!=null){var g=d.dataModel||o.getSeriesByIndex(d.seriesIndex);return l=g&&g.getDataParams(d.dataIndex,d.dataType,s)||{},!0}else if(d.eventData)return l=O({},d.eventData),!0},!0),l){var f=l.componentType,h=l.componentIndex;(f==="markLine"||f==="markPoint"||f==="markArea")&&(f="series",h=l.seriesIndex);var c=f&&h!=null&&o.getComponent(f,h),v=c&&e[c.mainType==="series"?"_chartsMap":"_componentsMap"][c.__viewId];l.event=a,l.type=i,e._$eventProcessor.eventInfo={targetEl:s,packedEvent:l,model:c,view:v},e.trigger(i,l)}};n.zrEventfulCallAtLast=!0,e._zr.on(i,n,e)}),w(ho,function(i,n){e._messageCenter.on(n,function(a){this.trigger(n,a)},e)}),w(["selectchanged"],function(i){e._messageCenter.on(i,function(n){this.trigger(i,n)},e)}),H2(this._messageCenter,this,this._api)},t.prototype.isDisposed=function(){return this._disposed},t.prototype.clear=function(){if(this._disposed){this.id;return}this.setOption({series:[]},!0)},t.prototype.dispose=function(){if(this._disposed){this.id;return}this._disposed=!0;var e=this.getDom();e&&Y_(this.getDom(),Uc,"");var i=this,n=i._api,a=i._model;w(i._componentsViews,function(o){o.dispose(a,n)}),w(i._chartsViews,function(o){o.dispose(a,n)}),i._zr.dispose(),i._dom=i._model=i._chartsMap=i._componentsMap=i._chartsViews=i._componentsViews=i._scheduler=i._api=i._zr=i._throttledZrFlush=i._theme=i._coordSysMgr=i._messageCenter=null,delete sn[i.id]},t.prototype.resize=function(e){if(!this[Ut]){if(this._disposed){this.id;return}this._zr.resize(e);var i=this._model;if(this._loadingFX&&this._loadingFX.resize(),!!i){var n=i.resetOption("media"),a=e&&e.silent;this[he]&&(a==null&&(a=this[he].silent),n=!0,this[he]=null),this[Ut]=!0;try{n&&kn(this),jr.update.call(this,{type:"resize",animation:O({duration:0},e&&e.animation)})}catch(o){throw this[Ut]=!1,o}this[Ut]=!1,La.call(this,a),Pa.call(this,a)}}},t.prototype.showLoading=function(e,i){if(this._disposed){this.id;return}if(X(e)&&(i=e,e=""),e=e||"default",this.hideLoading(),!!uv[e]){var n=uv[e](this._api,i),a=this._zr;this._loadingFX=n,a.add(n)}},t.prototype.hideLoading=function(){if(this._disposed){this.id;return}this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},t.prototype.makeActionFromEvent=function(e){var i=O({},e);return i.type=ho[e.type],i},t.prototype.dispatchAction=function(e,i){if(this._disposed){this.id;return}if(X(i)||(i={silent:!!i}),!!El[e.type]&&this._model){if(this[Ut]){this._pendingActions.push(e);return}var n=i.silent;If.call(this,e,n);var a=i.flush;a?this._zr.flush():a!==!1&&tt.browser.weChat&&this._throttledZrFlush(),La.call(this,n),Pa.call(this,n)}},t.prototype.updateLabelLayout=function(){$e.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},t.prototype.appendData=function(e){if(this._disposed){this.id;return}var i=e.seriesIndex,n=this.getModel(),a=n.getSeriesByIndex(i);a.appendData(e),this._scheduler.unfinished=!0,this.getZr().wakeUp()},t.internalField=(function(){kn=function(h){var c=h._scheduler;c.restorePipelines(h._model),c.prepareStageTasks(),Df(h,!0),Df(h,!1),c.plan()},Df=function(h,c){for(var v=h._model,p=h._scheduler,d=c?h._componentsViews:h._chartsViews,g=c?h._componentsMap:h._chartsMap,y=h._zr,m=h._api,_=0;_c.get("hoverLayerThreshold")&&!tt.node&&!tt.worker&&c.eachSeries(function(g){if(!g.preventUsingHoverLayer){var y=h._chartsMap[g.__viewId];y.__alive&&y.eachRendered(function(m){m.states.emphasis&&(m.states.emphasis.hoverLayer=!0)})}})}function o(h,c){var v=h.get("blendMode")||null;c.eachRendered(function(p){p.isGroup||(p.style.blend=v)})}function s(h,c){if(!h.preventAutoZ){var v=h.get("z")||0,p=h.get("zlevel")||0;c.eachRendered(function(d){return l(d,v,p,-1/0),!0})}}function l(h,c,v,p){var d=h.getTextContent(),g=h.getTextGuideLine(),y=h.isGroup;if(y)for(var m=h.childrenRef(),_=0;_0?{duration:d,delay:v.get("delay"),easing:v.get("easing")}:null;c.eachRendered(function(y){if(y.states&&y.states.emphasis){if(lo(y))return;if(y instanceof gt&&eM(y),y.__dirty){var m=y.prevStates;m&&y.useStates(m)}if(p){y.stateTransition=g;var _=y.getTextContent(),S=y.getTextGuideLine();_&&(_.stateTransition=g),S&&(S.stateTransition=g)}y.__dirty&&n(y)}})}Jg=function(h){return new((function(c){E(v,c);function v(){return c!==null&&c.apply(this,arguments)||this}return v.prototype.getCoordinateSystems=function(){return h._coordSysMgr.getCoordinateSystems()},v.prototype.getComponentByElement=function(p){for(;p;){var d=p.__ecComponentInfo;if(d!=null)return h._model.getComponent(d.mainType,d.index);p=p.parent}},v.prototype.enterEmphasis=function(p,d){Qn(p,d),Me(h)},v.prototype.leaveEmphasis=function(p,d){ta(p,d),Me(h)},v.prototype.enterBlur=function(p){YA(p),Me(h)},v.prototype.leaveBlur=function(p){u1(p),Me(h)},v.prototype.enterSelect=function(p){f1(p),Me(h)},v.prototype.leaveSelect=function(p){h1(p),Me(h)},v.prototype.getModel=function(){return h.getModel()},v.prototype.getViewOfComponentModel=function(p){return h.getViewOfComponentModel(p)},v.prototype.getViewOfSeriesModel=function(p){return h.getViewOfSeriesModel(p)},v})(Q1))(h)},$S=function(h){function c(v,p){for(var d=0;d=0)){Qg.push(e);var a=wS.wrapStageHandler(e,n);a.__prio=t,a.__raw=e,r.push(a)}}function Jc(r,t){uv[r]=t}function GL(r){j0({createCanvas:r})}function ex(r,t,e){var i=zS("registerMap");i&&i(r,t,e)}function HL(r){var t=zS("getMap");return t&&t(r)}var rx=KD;Si(Wc,C2);Si(mu,A2);Si(mu,M2);Si(Wc,V2);Si(mu,G2);Si(GS,dL);$c(eS);qc(xL,PD);Jc("default",D2);ar({type:an,event:an,update:an},Vt);ar({type:js,event:js,update:js},Vt);ar({type:ao,event:ao,update:ao},Vt);ar({type:Qs,event:Qs,update:Qs},Vt);ar({type:oo,event:oo,update:oo},Vt);Zc("light",z2);Zc("dark",MS);var WL={};function Ia(r){return r==null?0:r.length||1}function ty(r){return r}var jc=(function(){function r(t,e,i,n,a,o){this._old=t,this._new=e,this._oldKeyGetter=i||ty,this._newKeyGetter=n||ty,this.context=a,this._diffModeMultiple=o==="multiple"}return r.prototype.add=function(t){return this._add=t,this},r.prototype.update=function(t){return this._update=t,this},r.prototype.updateManyToOne=function(t){return this._updateManyToOne=t,this},r.prototype.updateOneToMany=function(t){return this._updateOneToMany=t,this},r.prototype.updateManyToMany=function(t){return this._updateManyToMany=t,this},r.prototype.remove=function(t){return this._remove=t,this},r.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},r.prototype._executeOneToOne=function(){var t=this._old,e=this._new,i={},n=new Array(t.length),a=new Array(e.length);this._initIndexMap(t,null,n,"_oldKeyGetter"),this._initIndexMap(e,i,a,"_newKeyGetter");for(var o=0;o1){var f=l.shift();l.length===1&&(i[s]=l[0]),this._update&&this._update(f,o)}else u===1?(i[s]=null,this._update&&this._update(l,o)):this._remove&&this._remove(o)}this._performRestAdd(a,i)},r.prototype._executeMultiple=function(){var t=this._old,e=this._new,i={},n={},a=[],o=[];this._initIndexMap(t,i,a,"_oldKeyGetter"),this._initIndexMap(e,n,o,"_newKeyGetter");for(var s=0;s1&&c===1)this._updateManyToOne&&this._updateManyToOne(f,u),n[l]=null;else if(h===1&&c>1)this._updateOneToMany&&this._updateOneToMany(f,u),n[l]=null;else if(h===1&&c===1)this._update&&this._update(f,u),n[l]=null;else if(h>1&&c>1)this._updateManyToMany&&this._updateManyToMany(f,u),n[l]=null;else if(h>1)for(var v=0;v1)for(var s=0;s30}var Ra=X,Qr=F,KL=typeof Int32Array=="undefined"?Array:Int32Array,JL="e\0\0",ey=-1,jL=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],QL=["_approximateExtent"],ry,Cs,Ea,ka,kf,Oa,Of,Su=(function(){function r(t,e){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","minmaxDownSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","minmaxDownSample","lttbDownSample"];var i,n=!1;nx(t)?(i=t.dimensions,this._dimOmitted=t.isDimensionOmitted(),this._schema=t):(n=!0,i=t),i=i||["x","y"];for(var a={},o=[],s={},l=!1,u={},f=0;f=e)){var i=this._store,n=i.getProvider();this._updateOrdinalMeta();var a=this._nameList,o=this._idList,s=n.getSource().sourceFormat,l=s===We;if(l&&!n.pure)for(var u=[],f=t;f0},r.prototype.ensureUniqueItemVisual=function(t,e){var i=this._itemVisuals,n=i[t];n||(n=i[t]={});var a=n[e];return a==null&&(a=this.getVisual(e),z(a)?a=a.slice():Ra(a)&&(a=O({},a)),n[e]=a),a},r.prototype.setItemVisual=function(t,e,i){var n=this._itemVisuals[t]||{};this._itemVisuals[t]=n,Ra(e)?O(n,e):n[e]=i},r.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},r.prototype.setLayout=function(t,e){Ra(t)?O(this._layout,t):this._layout[t]=e},r.prototype.getLayout=function(t){return this._layout[t]},r.prototype.getItemLayout=function(t){return this._itemLayouts[t]},r.prototype.setItemLayout=function(t,e,i){this._itemLayouts[t]=i?O(this._itemLayouts[t]||{},e):e},r.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},r.prototype.setItemGraphicEl=function(t,e){var i=this.hostModel&&this.hostModel.seriesIndex;BA(i,this.dataType,t,e),this._graphicEls[t]=e},r.prototype.getItemGraphicEl=function(t){return this._graphicEls[t]},r.prototype.eachItemGraphicEl=function(t,e){w(this._graphicEls,function(i,n){i&&t&&t.call(e,i,n)})},r.prototype.cloneShallow=function(t){return t||(t=new r(this._schema?this._schema:Qr(this.dimensions,this._getDimInfo,this),this.hostModel)),kf(t,this),t._store=this._store,t},r.prototype.wrapMethod=function(t,e){var i=this[t];j(i)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var n=i.apply(this,arguments);return e.apply(this,[n].concat(Zl(arguments)))})},r.internalField=(function(){ry=function(t){var e=t._invertedIndicesMap;w(e,function(i,n){var a=t._dimInfos[n],o=a.ordinalMeta,s=t._store;if(o){i=e[n]=new KL(o.categories.length);for(var l=0;l1&&(l+="__ec__"+f),n[e]=l}}})(),r})();function tP(r,t){return Qc(r,t).dimensions}function Qc(r,t){Oc(r)||(r=Bc(r)),t=t||{};var e=t.coordDimensions||[],i=t.dimensionsDefine||r.dimensionsDefine||[],n=U(),a=[],o=rP(r,e,i,t.dimensionsCount),s=t.canOmitUnusedDimensions&&sx(o),l=i===r.dimensionsDefine,u=l?ox(r):ax(i),f=t.encodeDefine;!f&&t.encodeDefaulter&&(f=t.encodeDefaulter(r,o));for(var h=U(f),c=new hS(o),v=0;v0&&(i.name=n+(a-1)),a++,t.set(n,a)}}function rP(r,t,e,i){var n=Math.max(r.dimensionsDetectedCount||1,t.length,e.length,i||0);return w(t,function(a){var o;X(a)&&(o=a.dimsDef)&&(n=Math.max(n,o.length))}),n}function iP(r,t,e){if(e||t.hasKey(r)){for(var i=0;t.hasKey(r+i);)i++;r+=i}return t.set(r,!0),r}var nP=(function(){function r(t){this.coordSysDims=[],this.axisMap=U(),this.categoryAxisMap=U(),this.coordSysName=t}return r})();function aP(r){var t=r.get("coordinateSystem"),e=new nP(t),i=oP[t];if(i)return i(r,e,e.axisMap,e.categoryAxisMap),e}var oP={cartesian2d:function(r,t,e,i){var n=r.getReferringComponents("xAxis",kt).models[0],a=r.getReferringComponents("yAxis",kt).models[0];t.coordSysDims=["x","y"],e.set("x",n),e.set("y",a),On(n)&&(i.set("x",n),t.firstCategoryDimIndex=0),On(a)&&(i.set("y",a),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=1))},singleAxis:function(r,t,e,i){var n=r.getReferringComponents("singleAxis",kt).models[0];t.coordSysDims=["single"],e.set("single",n),On(n)&&(i.set("single",n),t.firstCategoryDimIndex=0)},polar:function(r,t,e,i){var n=r.getReferringComponents("polar",kt).models[0],a=n.findAxisModel("radiusAxis"),o=n.findAxisModel("angleAxis");t.coordSysDims=["radius","angle"],e.set("radius",a),e.set("angle",o),On(a)&&(i.set("radius",a),t.firstCategoryDimIndex=0),On(o)&&(i.set("angle",o),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=1))},geo:function(r,t,e,i){t.coordSysDims=["lng","lat"]},parallel:function(r,t,e,i){var n=r.ecModel,a=n.getComponent("parallel",r.get("parallelIndex")),o=t.coordSysDims=a.dimensions.slice();w(a.parallelAxisIndex,function(s,l){var u=n.getComponent("parallelAxis",s),f=o[l];e.set(f,u),On(u)&&(i.set(f,u),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=l))})}};function On(r){return r.get("type")==="category"}function lx(r,t,e){e=e||{};var i=e.byIndex,n=e.stackedCoordDimension,a,o,s;sP(t)?a=t:(o=t.schema,a=o.dimensions,s=t.store);var l=!!(r&&r.get("stack")),u,f,h,c;if(w(a,function(m,_){G(m)&&(a[_]=m={name:m}),l&&!m.isExtraCoord&&(!i&&!u&&m.ordinalMeta&&(u=m),!f&&m.type!=="ordinal"&&m.type!=="time"&&(!n||n===m.coordDim)&&(f=m))}),f&&!i&&!u&&(i=!0),f){h="__\0ecstackresult_"+r.id,c="__\0ecstackedover_"+r.id,u&&(u.createInvertedIndices=!0);var v=f.coordDim,p=f.type,d=0;w(a,function(m){m.coordDim===v&&d++});var g={name:h,coordDim:v,coordDimIndex:d,type:p,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length},y={name:c,coordDim:c,coordDimIndex:d+1,type:p,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length+1};o?(s&&(g.storeDimIndex=s.ensureCalculationDimension(c,p),y.storeDimIndex=s.ensureCalculationDimension(h,p)),o.appendCalculationDimension(g),o.appendCalculationDimension(y)):(a.push(g),a.push(y))}return{stackedDimension:f&&f.name,stackedByDimension:u&&u.name,isStackedByIndex:i,stackedOverDimension:c,stackResultDimension:h}}function sP(r){return!nx(r.schema)}function yi(r,t){return!!t&&t===r.getCalculationInfo("stackedDimension")}function ux(r,t){return yi(r,t)?r.getCalculationInfo("stackResultDimension"):t}function lP(r,t){var e=r.get("coordinateSystem"),i=cu.get(e),n;return t&&t.coordSysDims&&(n=F(t.coordSysDims,function(a){var o={name:a},s=t.axisMap.get(a);if(s){var l=s.get("type");o.type=XL(l)}return o})),n||(n=i&&(i.getDimensionsInfo?i.getDimensionsInfo():i.dimensions.slice())||["x","y"]),n}function uP(r,t,e){var i,n;return e&&w(r,function(a,o){var s=a.coordDim,l=e.categoryAxisMap.get(s);l&&(i==null&&(i=o),a.ordinalMeta=l.getOrdinalMeta(),t&&(a.createInvertedIndices=!0)),a.otherDims.itemName!=null&&(n=!0)}),!n&&i!=null&&(r[i].otherDims.itemName=0),i}function xu(r,t,e){e=e||{};var i=t.getSourceManager(),n,a=!1;r?(a=!0,n=Bc(r)):(n=i.getSource(),a=n.sourceFormat===We);var o=aP(t),s=lP(t,o),l=e.useEncodeDefaulter,u=j(l)?l:l?ft(oD,s,t):null,f={coordDimensions:s,generateCoord:e.generateCoord,encodeDefine:t.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!a},h=Qc(n,f),c=uP(h.dimensions,e.createInvertedIndices,o),v=a?null:i.getSharedDataStore(h),p=lx(t,{schema:h,store:v}),d=new Su(h,t);d.setCalculationInfo(p);var g=c!=null&&fP(n)?function(y,m,_,S){return S===c?_:this.defaultDimValueGetter(y,m,_,S)}:null;return d.hasItemOption=!1,d.initData(a?n:v,null,g),d}function fP(r){if(r.sourceFormat===We){var t=hP(r.data||[]);return!z(la(t))}}function hP(r){for(var t=0;te[1]&&(e[1]=t[1])},r.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.setExtent=function(t,e){var i=this._extent;isNaN(t)||(i[0]=t),isNaN(e)||(i[1]=e)},r.prototype.isInExtentRange=function(t){return this._extent[0]<=t&&this._extent[1]>=t},r.prototype.isBlank=function(){return this._isBlank},r.prototype.setBlank=function(t){this._isBlank=t},r})();Jl(Cr);var vP=0,fv=(function(){function r(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this.uid=++vP}return r.createByAxisModel=function(t){var e=t.option,i=e.data,n=i&&F(i,cP);return new r({categories:n,needCollect:!n,deduplication:e.dedplication!==!1})},r.prototype.getOrdinal=function(t){return this._getOrCreateMap().get(t)},r.prototype.parseAndCollect=function(t){var e,i=this._needCollect;if(!G(t)&&!i)return t;if(i&&!this._deduplication)return e=this.categories.length,this.categories[e]=t,e;var n=this._getOrCreateMap();return e=n.get(t),e==null&&(i?(e=this.categories.length,this.categories[e]=t,n.set(t,e)):e=NaN),e},r.prototype._getOrCreateMap=function(){return this._map||(this._map=U(this.categories))},r})();function cP(r){return X(r)&&r.value!=null?r.value:r+""}function hv(r){return r.type==="interval"||r.type==="log"}function pP(r,t,e,i){var n={},a=r[1]-r[0],o=n.interval=rc(a/t,!0);e!=null&&oi&&(o=n.interval=i);var s=n.intervalPrecision=fx(o),l=n.niceTickExtent=[Lt(Math.ceil(r[0]/o)*o,s),Lt(Math.floor(r[1]/o)*o,s)];return dP(l,r),n}function Bf(r){var t=Math.pow(10,Kl(r)),e=r/t;return e?e===2?e=3:e===3?e=5:e*=2:e=1,Lt(e*t)}function fx(r){return yr(r)+2}function iy(r,t,e){r[t]=Math.max(Math.min(r[t],e[1]),e[0])}function dP(r,t){!isFinite(r[0])&&(r[0]=t[0]),!isFinite(r[1])&&(r[1]=t[1]),iy(r,0,t),iy(r,1,t),r[0]>r[1]&&(r[0]=r[1])}function bu(r,t){return r>=t[0]&&r<=t[1]}function wu(r,t){return t[1]===t[0]?.5:(r-t[0])/(t[1]-t[0])}function Tu(r,t){return r*(t[1]-t[0])+t[0]}var Cu=(function(r){E(t,r);function t(e){var i=r.call(this,e)||this;i.type="ordinal";var n=i.getSetting("ordinalMeta");return n||(n=new fv({})),z(n)&&(n=new fv({categories:F(n,function(a){return X(a)?a.value:a})})),i._ordinalMeta=n,i._extent=i.getSetting("extent")||[0,n.categories.length-1],i}return t.prototype.parse=function(e){return e==null?NaN:G(e)?this._ordinalMeta.getOrdinal(e):Math.round(e)},t.prototype.contain=function(e){return e=this.parse(e),bu(e,this._extent)&&this._ordinalMeta.categories[e]!=null},t.prototype.normalize=function(e){return e=this._getTickNumber(this.parse(e)),wu(e,this._extent)},t.prototype.scale=function(e){return e=Math.round(Tu(e,this._extent)),this.getRawOrdinalNumber(e)},t.prototype.getTicks=function(){for(var e=[],i=this._extent,n=i[0];n<=i[1];)e.push({value:n}),n++;return e},t.prototype.getMinorTicks=function(e){},t.prototype.setSortInfo=function(e){if(e==null){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var i=e.ordinalNumbers,n=this._ordinalNumbersByTick=[],a=this._ticksByOrdinalNumber=[],o=0,s=this._ordinalMeta.categories.length,l=Math.min(s,i.length);o=0&&e=0&&e=e},t.prototype.getOrdinalMeta=function(){return this._ordinalMeta},t.prototype.calcNiceTicks=function(){},t.prototype.calcNiceExtent=function(){},t.type="ordinal",t})(Cr);Cr.registerClass(Cu);var Vi=Lt,Wr=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="interval",e._interval=0,e._intervalPrecision=2,e}return t.prototype.parse=function(e){return e},t.prototype.contain=function(e){return bu(e,this._extent)},t.prototype.normalize=function(e){return wu(e,this._extent)},t.prototype.scale=function(e){return Tu(e,this._extent)},t.prototype.setExtent=function(e,i){var n=this._extent;isNaN(e)||(n[0]=parseFloat(e)),isNaN(i)||(n[1]=parseFloat(i))},t.prototype.unionExtent=function(e){var i=this._extent;e[0]i[1]&&(i[1]=e[1]),this.setExtent(i[0],i[1])},t.prototype.getInterval=function(){return this._interval},t.prototype.setInterval=function(e){this._interval=e,this._niceExtent=this._extent.slice(),this._intervalPrecision=fx(e)},t.prototype.getTicks=function(e){var i=this._interval,n=this._extent,a=this._niceExtent,o=this._intervalPrecision,s=[];if(!i)return s;var l=1e4;n[0]l)return[];var f=s.length?s[s.length-1].value:a[1];return n[1]>f&&(e?s.push({value:Vi(f+i,o)}):s.push({value:n[1]})),s},t.prototype.getMinorTicks=function(e){for(var i=this.getTicks(!0),n=[],a=this.getExtent(),o=1;oa[0]&&v0&&(a=a===null?s:Math.min(a,s))}e[i]=a}}return e}function px(r){var t=yP(r),e=[];return w(r,function(i){var n=i.coordinateSystem,a=n.getBaseAxis(),o=a.getExtent(),s;if(a.type==="category")s=a.getBandWidth();else if(a.type==="value"||a.type==="time"){var l=a.dim+"_"+a.index,u=t[l],f=Math.abs(o[1]-o[0]),h=a.scale.getExtent(),c=Math.abs(h[1]-h[0]);s=u?f/c*u:f}else{var v=i.getData();s=Math.abs(o[1]-o[0])/v.count()}var p=Q(i.get("barWidth"),s),d=Q(i.get("barMaxWidth"),s),g=Q(i.get("barMinWidth")||(_x(i)?.5:1),s),y=i.get("barGap"),m=i.get("barCategoryGap");e.push({bandWidth:s,barWidth:p,barMaxWidth:d,barMinWidth:g,barGap:y,barCategoryGap:m,axisKey:tp(a),stackId:vx(i)})}),dx(e)}function dx(r){var t={};w(r,function(i,n){var a=i.axisKey,o=i.bandWidth,s=t[a]||{bandWidth:o,remainedWidth:o,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},l=s.stacks;t[a]=s;var u=i.stackId;l[u]||s.autoWidthCount++,l[u]=l[u]||{width:0,maxWidth:0};var f=i.barWidth;f&&!l[u].width&&(l[u].width=f,f=Math.min(s.remainedWidth,f),s.remainedWidth-=f);var h=i.barMaxWidth;h&&(l[u].maxWidth=h);var c=i.barMinWidth;c&&(l[u].minWidth=c);var v=i.barGap;v!=null&&(s.gap=v);var p=i.barCategoryGap;p!=null&&(s.categoryGap=p)});var e={};return w(t,function(i,n){e[n]={};var a=i.stacks,o=i.bandWidth,s=i.categoryGap;if(s==null){var l=pt(a).length;s=Math.max(35-l*4,15)+"%"}var u=Q(s,o),f=Q(i.gap,1),h=i.remainedWidth,c=i.autoWidthCount,v=(h-u)/(c+(c-1)*f);v=Math.max(v,0),w(a,function(y){var m=y.maxWidth,_=y.minWidth;if(y.width){var S=y.width;m&&(S=Math.min(S,m)),_&&(S=Math.max(S,_)),y.width=S,h-=S+f*S,c--}else{var S=v;m&&mS&&(S=_),S!==v&&(y.width=S,h-=S+f*S,c--)}}),v=(h-u)/(c+(c-1)*f),v=Math.max(v,0);var p=0,d;w(a,function(y,m){y.width||(y.width=v),d=y,p+=y.width*(1+f)}),d&&(p-=d.width*f);var g=-p/2;w(a,function(y,m){e[n][m]=e[n][m]||{bandWidth:o,offset:g,width:y.width},g+=y.width*(1+f)})}),e}function mP(r,t,e){if(r&&t){var i=r[tp(t)];return i}}function gx(r,t){var e=cx(r,t),i=px(e);w(e,function(n){var a=n.getData(),o=n.coordinateSystem,s=o.getBaseAxis(),l=vx(n),u=i[tp(s)][l],f=u.offset,h=u.width;a.setLayout({bandWidth:u.bandWidth,offset:f,size:h})})}function yx(r){return{seriesType:r,plan:Fc(),reset:function(t){if(mx(t)){var e=t.getData(),i=t.coordinateSystem,n=i.getBaseAxis(),a=i.getOtherAxis(n),o=e.getDimensionIndex(e.mapDimension(a.dim)),s=e.getDimensionIndex(e.mapDimension(n.dim)),l=t.get("showBackground",!0),u=e.mapDimension(a.dim),f=e.getCalculationInfo("stackResultDimension"),h=yi(e,u)&&!!e.getCalculationInfo("stackedOnSeries"),c=a.isHorizontal(),v=_P(n,a),p=_x(t),d=t.get("barMinHeight")||0,g=f&&e.getDimensionIndex(f),y=e.getLayout("size"),m=e.getLayout("offset");return{progress:function(_,S){for(var b=_.count,x=p&&kr(b*3),T=p&&l&&kr(b*3),C=p&&kr(b),A=i.master.getRect(),M=c?A.width:A.height,D,L=S.getStore(),P=0;(D=_.next())!=null;){var I=L.get(h?g:o,D),R=L.get(s,D),k=v,V=void 0;h&&(V=+I-L.get(o,D));var B=void 0,N=void 0,Y=void 0,Z=void 0;if(c){var $=i.dataToPoint([I,R]);if(h){var ut=i.dataToPoint([V,R]);k=ut[0]}B=k,N=$[1]+m,Y=$[0]-k,Z=y,Math.abs(Y)0?e:1:e))}var SP=function(r,t,e,i){for(;e>>1;r[n][1]n&&(this._approxInterval=n);var s=As.length,l=Math.min(SP(As,this._approxInterval,0,s),s-1);this._interval=As[l][1],this._minLevelUnit=As[Math.max(l-1,0)][0]},t.prototype.parse=function(e){return yt(e)?e:+Te(e)},t.prototype.contain=function(e){return bu(this.parse(e),this._extent)},t.prototype.normalize=function(e){return wu(this.parse(e),this._extent)},t.prototype.scale=function(e){return Tu(e,this._extent)},t.type="time",t})(Wr),As=[["second",Tc],["minute",Cc],["hour",uo],["quarter-day",uo*6],["half-day",uo*12],["day",Ne*1.2],["half-week",Ne*3.5],["week",Ne*7],["month",Ne*31],["quarter",Ne*95],["half-year",Zd/2],["year",Zd]];function xP(r,t,e,i){var n=Te(t),a=Te(e),o=function(p){return qd(n,p,i)===qd(a,p,i)},s=function(){return o("year")},l=function(){return s()&&o("month")},u=function(){return l()&&o("day")},f=function(){return u()&&o("hour")},h=function(){return f()&&o("minute")},c=function(){return h()&&o("second")},v=function(){return c()&&o("millisecond")};switch(r){case"year":return s();case"month":return l();case"day":return u();case"hour":return f();case"minute":return h();case"second":return c();case"millisecond":return v()}}function bP(r,t){return r/=Ne,r>16?16:r>7.5?7:r>3.5?4:r>1.5?2:1}function wP(r){var t=30*Ne;return r/=t,r>6?6:r>3?3:r>2?2:1}function TP(r){return r/=uo,r>12?12:r>6?6:r>3.5?4:r>2?2:1}function ny(r,t){return r/=t?Cc:Tc,r>30?30:r>20?20:r>15?15:r>10?10:r>5?5:r>2?2:1}function CP(r){return rc(r,!0)}function AP(r,t,e){var i=new Date(r);switch(qn(t)){case"year":case"month":i[B1(e)](0);case"day":i[N1(e)](1);case"hour":i[z1(e)](0);case"minute":i[F1(e)](0);case"second":i[V1(e)](0),i[G1(e)](0)}return i.getTime()}function MP(r,t,e,i){var n=1e4,a=k1,o=0;function s(M,D,L,P,I,R,k){for(var V=new Date(D),B=D,N=V[P]();B1&&R===0&&L.unshift({value:L[0].value-B})}}for(var R=0;R=i[0]&&m<=i[1]&&h++)}var _=(i[1]-i[0])/t;if(h>_*1.5&&c>_/1.5||(u.push(g),h>_||r===a[v]))break}f=[]}}}for(var S=wt(F(u,function(M){return wt(M,function(D){return D.value>=i[0]&&D.value<=i[1]&&!D.notAdd})}),function(M){return M.length>0}),b=[],x=S.length-1,v=0;v0;)a*=10;var s=[Lt(PP(i[0]/a)*a),Lt(LP(i[1]/a)*a)];this._interval=a,this._niceExtent=s}},t.prototype.calcNiceExtent=function(e){vo.calcNiceExtent.call(this,e),this._fixMin=e.fixMin,this._fixMax=e.fixMax},t.prototype.parse=function(e){return e},t.prototype.contain=function(e){return e=Ue(e)/Ue(this.base),bu(e,this._extent)},t.prototype.normalize=function(e){return e=Ue(e)/Ue(this.base),wu(e,this._extent)},t.prototype.scale=function(e){return e=Tu(e,this._extent),Ms(this.base,e)},t.type="log",t})(Cr),Sx=rp.prototype;Sx.getMinorTicks=vo.getMinorTicks;Sx.getLabel=vo.getLabel;function Ds(r,t){return DP(r,yr(t))}Cr.registerClass(rp);var IP=(function(){function r(t,e,i){this._prepareParams(t,e,i)}return r.prototype._prepareParams=function(t,e,i){i[1]0&&l>0&&!u&&(s=0),s<0&&l<0&&!f&&(l=0));var c=this._determinedMin,v=this._determinedMax;return c!=null&&(s=c,u=!0),v!=null&&(l=v,f=!0),{min:s,max:l,minFixed:u,maxFixed:f,isBlank:h}},r.prototype.modifyDataMinMax=function(t,e){this[EP[t]]=e},r.prototype.setDeterminedMinMax=function(t,e){var i=RP[t];this[i]=e},r.prototype.freeze=function(){this.frozen=!0},r})(),RP={min:"_determinedMin",max:"_determinedMax"},EP={min:"_dataMin",max:"_dataMax"};function xx(r,t,e){var i=r.rawExtentInfo;return i||(i=new IP(r,t,e),r.rawExtentInfo=i,i)}function Ls(r,t){return t==null?null:co(t)?NaN:r.parse(t)}function bx(r,t){var e=r.type,i=xx(r,t,r.getExtent()).calculate();r.setBlank(i.isBlank);var n=i.min,a=i.max,o=t.ecModel;if(o&&e==="time"){var s=cx("bar",o),l=!1;if(w(s,function(h){l=l||h.getBaseAxis()===t.axis}),l){var u=px(s),f=kP(n,a,t,u);n=f.min,a=f.max}}return{extent:[n,a],fixMin:i.minFixed,fixMax:i.maxFixed}}function kP(r,t,e,i){var n=e.axis.getExtent(),a=Math.abs(n[1]-n[0]),o=mP(i,e.axis);if(o===void 0)return{min:r,max:t};var s=1/0;w(o,function(v){s=Math.min(v.offset,s)});var l=-1/0;w(o,function(v){l=Math.max(v.offset+v.width,l)}),s=Math.abs(s),l=Math.abs(l);var u=s+l,f=t-r,h=1-(s+l)/a,c=f/h-f;return t+=c*(l/u),r-=c*(s/u),{min:r,max:t}}function ia(r,t){var e=t,i=bx(r,e),n=i.extent,a=e.get("splitNumber");r instanceof rp&&(r.base=e.get("logBase"));var o=r.type,s=e.get("interval"),l=o==="interval"||o==="time";r.setExtent(n[0],n[1]),r.calcNiceExtent({splitNumber:a,fixMin:i.fixMin,fixMax:i.fixMax,minInterval:l?e.get("minInterval"):null,maxInterval:l?e.get("maxInterval"):null}),s!=null&&r.setInterval&&r.setInterval(s)}function Au(r,t){if(t=t||r.get("type"),t)switch(t){case"category":return new Cu({ordinalMeta:r.getOrdinalMeta?r.getOrdinalMeta():r.getCategories(),extent:[1/0,-1/0]});case"time":return new ep({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new(Cr.getClass(t)||Wr)}}function OP(r){var t=r.scale.getExtent(),e=t[0],i=t[1];return!(e>0&&i>0||e<0&&i<0)}function da(r){var t=r.getLabelModel().get("formatter"),e=r.type==="category"?r.scale.getExtent()[0]:null;return r.scale.type==="time"?(function(i){return function(n,a){return r.scale.getFormattedLabel(n,a,i)}})(t):G(t)?(function(i){return function(n){var a=r.scale.getLabel(n),o=i.replace("{value}",a!=null?a:"");return o}})(t):j(t)?(function(i){return function(n,a){return e!=null&&(a=n.value-e),i(ip(r,n),a,n.level!=null?{level:n.level}:null)}})(t):function(i){return r.scale.getLabel(i)}}function ip(r,t){return r.type==="category"?r.scale.getLabel(t):t.value}function BP(r){var t=r.model,e=r.scale;if(!(!t.get(["axisLabel","show"])||e.isBlank())){var i,n,a=e.getExtent();e instanceof Cu?n=e.count():(i=e.getTicks(),n=i.length);var o=r.getLabelModel(),s=da(r),l,u=1;n>40&&(u=Math.ceil(n/40));for(var f=0;fr[1]&&(r[1]=n[1])})}var qo=(function(){function r(){}return r.prototype.getNeedCrossZero=function(){var t=this.option;return!t.scale},r.prototype.getCoordSysModel=function(){},r})();function FP(r){return xu(null,r)}var VP={isDimensionStacked:yi,enableDataStack:lx,getStackedDimension:ux};function GP(r,t){var e=t;t instanceof _t||(e=new _t(t));var i=Au(e);return i.setExtent(r[0],r[1]),ia(i,e),i}function HP(r){Wt(r,qo)}function WP(r,t){return t=t||{},Rt(r,null,null,t.state!=="normal")}const YP=Object.freeze(Object.defineProperty({__proto__:null,createDimensions:tP,createList:FP,createScale:GP,createSymbol:te,createTextStyle:WP,dataStack:VP,enableHoverEmphasis:hi,getECData:ot,getLayoutRect:le,mixinAxisModelCommonMethods:HP},Symbol.toStringTag,{value:"Module"}));var oy=[],UP={registerPreprocessor:$c,registerProcessor:qc,registerPostInit:JS,registerPostUpdate:jS,registerUpdateLifecycle:_u,registerAction:ar,registerCoordinateSystem:QS,registerLayout:tx,registerVisual:Si,registerTransform:rx,registerLoading:Jc,registerMap:ex,registerImpl:gL,PRIORITY:HS,ComponentModel:at,ComponentView:Ct,SeriesModel:Qt,ChartView:Nt,registerComponentModel:function(r){at.registerClass(r)},registerComponentView:function(r){Ct.registerClass(r)},registerSeriesModel:function(r){Qt.registerClass(r)},registerChartView:function(r){Nt.registerClass(r)},registerSubTypeDefaulter:function(r,t){at.registerSubTypeDefaulter(r,t)},registerPainter:function(r,t){R_(r,t)}};function Ht(r){if(z(r)){w(r,function(t){Ht(t)});return}lt(oy,r)>=0||(oy.push(r),j(r)&&(r={install:r}),r.install(UP))}var XP=1e-8;function sy(r,t){return Math.abs(r-t)n&&(i=o,n=l)}if(i)return $P(i.exterior);var u=this.getBoundingRect();return[u.x+u.width/2,u.y+u.height/2]},t.prototype.getBoundingRect=function(e){var i=this._rect;if(i&&!e)return i;var n=[1/0,1/0],a=[-1/0,-1/0],o=this.geometries;return w(o,function(s){s.type==="polygon"?uy(s.exterior,n,a,e):w(s.points,function(l){uy(l,n,a,e)})}),isFinite(n[0])&&isFinite(n[1])&&isFinite(a[0])&&isFinite(a[1])||(n[0]=n[1]=a[0]=a[1]=0),i=new st(n[0],n[1],a[0]-n[0],a[1]-n[1]),e||(this._rect=i),i},t.prototype.contain=function(e){var i=this.getBoundingRect(),n=this.geometries;if(!i.contain(e[0],e[1]))return!1;t:for(var a=0,o=n.length;a>1^-(s&1),l=l>>1^-(l&1),s+=n,l+=a,n=s,a=l,i.push([s/e,l/e])}return i}function cv(r,t){return r=KP(r),F(wt(r.features,function(e){return e.geometry&&e.properties&&e.geometry.coordinates.length>0}),function(e){var i=e.properties,n=e.geometry,a=[];switch(n.type){case"Polygon":var o=n.coordinates;a.push(new fy(o[0],o.slice(1)));break;case"MultiPolygon":w(n.coordinates,function(l){l[0]&&a.push(new fy(l[0],l.slice(1)))});break;case"LineString":a.push(new hy([n.coordinates]));break;case"MultiLineString":a.push(new hy(n.coordinates))}var s=new Ax(i[t||"name"],a,i.cp);return s.properties=i,s})}const JP=Object.freeze(Object.defineProperty({__proto__:null,MAX_SAFE_INTEGER:xC,asc:gr,getPercentWithPrecision:_C,getPixelPrecision:tc,getPrecision:yr,getPrecisionSafe:O_,isNumeric:ic,isRadianAroundZero:mo,linearMap:Tt,nice:rc,numericToNumber:Gr,parseDate:Te,quantile:wC,quantity:N_,quantityExponent:Kl,reformIntervals:zh,remRadian:ec,round:Lt},Symbol.toStringTag,{value:"Module"})),jP=Object.freeze(Object.defineProperty({__proto__:null,format:Zo,parse:Te},Symbol.toStringTag,{value:"Module"})),QP=Object.freeze(Object.defineProperty({__proto__:null,Arc:Yo,BezierCurve:iu,BoundingRect:st,Circle:wr,CompoundPath:cc,Ellipse:Wo,Group:nt,Image:ye,IncrementalDisplayable:b1,Line:Kt,LinearGradient:Uo,Polygon:ir,Polyline:Ce,RadialGradient:pc,Rect:vt,Ring:ua,Sector:rr,Text:ct,clipPointsByRect:Sc,clipRectByRect:M1,createIcon:fa,extendPath:C1,extendShape:T1,getShapeClass:yc,getTransform:vi,initProps:Jt,makeImage:mc,makePath:nu,mergePath:Be,registerShape:He,resizePath:_c,updateProps:Mt},Symbol.toStringTag,{value:"Module"})),tI=Object.freeze(Object.defineProperty({__proto__:null,addCommas:Mc,capitalFirst:tD,encodeHTML:ne,formatTime:QM,formatTpl:Lc,getTextRect:JM,getTooltipMarker:H1,normalizeCssArray:_n,toCamelCase:Dc,truncateText:JC},Symbol.toStringTag,{value:"Module"})),eI=Object.freeze(Object.defineProperty({__proto__:null,bind:W,clone:q,curry:ft,defaults:K,each:w,extend:O,filter:wt,indexOf:lt,inherits:Yv,isArray:z,isFunction:j,isObject:X,isString:G,map:F,merge:J,reduce:Fe},Symbol.toStringTag,{value:"Module"}));var Po=St();function Dx(r,t){var e=F(t,function(i){return r.scale.parse(i)});return r.type==="time"&&e.length>0&&(e.sort(),e.unshift(e[0]),e.push(e[e.length-1])),e}function rI(r){var t=r.getLabelModel().get("customValues");if(t){var e=da(r),i=r.scale.getExtent(),n=Dx(r,t),a=wt(n,function(o){return o>=i[0]&&o<=i[1]});return{labels:F(a,function(o){var s={value:o};return{formattedLabel:e(s),rawLabel:r.scale.getLabel(s),tickValue:o}})}}return r.type==="category"?nI(r):oI(r)}function iI(r,t){var e=r.getTickModel().get("customValues");if(e){var i=r.scale.getExtent(),n=Dx(r,e);return{ticks:wt(n,function(a){return a>=i[0]&&a<=i[1]})}}return r.type==="category"?aI(r,t):{ticks:F(r.scale.getTicks(),function(a){return a.value})}}function nI(r){var t=r.getLabelModel(),e=Lx(r,t);return!t.get("show")||r.scale.isBlank()?{labels:[],labelCategoryInterval:e.labelCategoryInterval}:e}function Lx(r,t){var e=Px(r,"labels"),i=np(t),n=Ix(e,i);if(n)return n;var a,o;return j(i)?a=kx(r,i):(o=i==="auto"?sI(r):i,a=Ex(r,o)),Rx(e,i,{labels:a,labelCategoryInterval:o})}function aI(r,t){var e=Px(r,"ticks"),i=np(t),n=Ix(e,i);if(n)return n;var a,o;if((!t.get("show")||r.scale.isBlank())&&(a=[]),j(i))a=kx(r,i,!0);else if(i==="auto"){var s=Lx(r,r.getLabelModel());o=s.labelCategoryInterval,a=F(s.labels,function(l){return l.tickValue})}else o=i,a=Ex(r,o,!0);return Rx(e,i,{ticks:a,tickCategoryInterval:o})}function oI(r){var t=r.scale.getTicks(),e=da(r);return{labels:F(t,function(i,n){return{level:i.level,formattedLabel:e(i,n),rawLabel:r.scale.getLabel(i),tickValue:i.value}})}}function Px(r,t){return Po(r)[t]||(Po(r)[t]=[])}function Ix(r,t){for(var e=0;e40&&(s=Math.max(1,Math.floor(o/40)));for(var l=a[0],u=r.dataToCoord(l+1)-r.dataToCoord(l),f=Math.abs(u*Math.cos(i)),h=Math.abs(u*Math.sin(i)),c=0,v=0;l<=a[1];l+=s){var p=0,d=0,g=Go(e({value:l}),t.font,"center","top");p=g.width*1.3,d=g.height*1.3,c=Math.max(c,p,7),v=Math.max(v,d,7)}var y=c/f,m=v/h;isNaN(y)&&(y=1/0),isNaN(m)&&(m=1/0);var _=Math.max(0,Math.floor(Math.min(y,m))),S=Po(r.model),b=r.getExtent(),x=S.lastAutoInterval,T=S.lastTickCount;return x!=null&&T!=null&&Math.abs(x-_)<=1&&Math.abs(T-o)<=1&&x>_&&S.axisExtent0===b[0]&&S.axisExtent1===b[1]?_=x:(S.lastTickCount=o,S.lastAutoInterval=_,S.axisExtent0=b[0],S.axisExtent1=b[1]),_}function uI(r){var t=r.getLabelModel();return{axisRotate:r.getRotate?r.getRotate():r.isHorizontal&&!r.isHorizontal()?90:0,labelRotate:t.get("rotate")||0,font:t.getFont()}}function Ex(r,t,e){var i=da(r),n=r.scale,a=n.getExtent(),o=r.getLabelModel(),s=[],l=Math.max((t||0)+1,1),u=a[0],f=n.count();u!==0&&l>1&&f/l>2&&(u=Math.round(Math.ceil(u/l)*l));var h=Tx(r),c=o.get("showMinLabel")||h,v=o.get("showMaxLabel")||h;c&&u!==a[0]&&d(a[0]);for(var p=u;p<=a[1];p+=l)d(p);v&&p-l!==a[1]&&d(a[1]);function d(g){var y={value:g};s.push(e?g:{formattedLabel:i(y),rawLabel:n.getLabel(y),tickValue:g})}return s}function kx(r,t,e){var i=r.scale,n=da(r),a=[];return w(i.getTicks(),function(o){var s=i.getLabel(o),l=o.value;t(o.value,s)&&a.push(e?l:{formattedLabel:n(o),rawLabel:s,tickValue:l})}),a}var vy=[0,1],or=(function(){function r(t,e,i){this.onBand=!1,this.inverse=!1,this.dim=t,this.scale=e,this._extent=i||[0,0]}return r.prototype.contain=function(t){var e=this._extent,i=Math.min(e[0],e[1]),n=Math.max(e[0],e[1]);return t>=i&&t<=n},r.prototype.containData=function(t){return this.scale.contain(t)},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.getPixelPrecision=function(t){return tc(t||this.scale.getExtent(),this._extent)},r.prototype.setExtent=function(t,e){var i=this._extent;i[0]=t,i[1]=e},r.prototype.dataToCoord=function(t,e){var i=this._extent,n=this.scale;return t=n.normalize(t),this.onBand&&n.type==="ordinal"&&(i=i.slice(),cy(i,n.count())),Tt(t,vy,i,e)},r.prototype.coordToData=function(t,e){var i=this._extent,n=this.scale;this.onBand&&n.type==="ordinal"&&(i=i.slice(),cy(i,n.count()));var a=Tt(t,i,vy,e);return this.scale.scale(a)},r.prototype.pointToData=function(t,e){},r.prototype.getTicksCoords=function(t){t=t||{};var e=t.tickModel||this.getTickModel(),i=iI(this,e),n=i.ticks,a=F(n,function(s){return{coord:this.dataToCoord(this.scale.type==="ordinal"?this.scale.getRawOrdinalNumber(s):s),tickValue:s}},this),o=e.get("alignWithLabel");return fI(this,a,o,t.clamp),a},r.prototype.getMinorTicksCoords=function(){if(this.scale.type==="ordinal")return[];var t=this.model.getModel("minorTick"),e=t.get("splitNumber");e>0&&e<100||(e=5);var i=this.scale.getMinorTicks(e),n=F(i,function(a){return F(a,function(o){return{coord:this.dataToCoord(o),tickValue:o}},this)},this);return n},r.prototype.getViewLabels=function(){return rI(this).labels},r.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},r.prototype.getTickModel=function(){return this.model.getModel("axisTick")},r.prototype.getBandWidth=function(){var t=this._extent,e=this.scale.getExtent(),i=e[1]-e[0]+(this.onBand?1:0);i===0&&(i=1);var n=Math.abs(t[1]-t[0]);return Math.abs(n)/i},r.prototype.calculateCategoryInterval=function(){return lI(this)},r})();function cy(r,t){var e=r[1]-r[0],i=t,n=e/i/2;r[0]+=n,r[1]-=n}function fI(r,t,e,i){var n=t.length;if(!r.onBand||e||!n)return;var a=r.getExtent(),o,s;if(n===1)t[0].coord=a[0],o=t[1]={coord:a[1],tickValue:t[0].tickValue};else{var l=t[n-1].tickValue-t[0].tickValue,u=(t[n-1].coord-t[0].coord)/l;w(t,function(v){v.coord-=u/2});var f=r.scale.getExtent();s=1+f[1]-t[n-1].tickValue,o={coord:t[n-1].coord+u*s,tickValue:f[1]+1},t.push(o)}var h=a[0]>a[1];c(t[0].coord,a[0])&&(i?t[0].coord=a[0]:t.shift()),i&&c(a[0],t[0].coord)&&t.unshift({coord:a[0]}),c(a[1],o.coord)&&(i?o.coord=a[1]:t.pop()),i&&c(o.coord,a[1])&&t.push({coord:a[1]});function c(v,p){return v=Lt(v),p=Lt(p),h?v>p:vn&&(n+=Ba);var v=Math.atan2(s,o);if(v<0&&(v+=Ba),v>=i&&v<=n||v+Ba>=i&&v+Ba<=n)return l[0]=f,l[1]=h,u-e;var p=e*Math.cos(i)+r,d=e*Math.sin(i)+t,g=e*Math.cos(n)+r,y=e*Math.sin(n)+t,m=(p-o)*(p-o)+(d-s)*(d-s),_=(g-o)*(g-o)+(y-s)*(y-s);return m<_?(l[0]=p,l[1]=d,Math.sqrt(m)):(l[0]=g,l[1]=y,Math.sqrt(_))}function Nl(r,t,e,i,n,a,o,s){var l=n-r,u=a-t,f=e-r,h=i-t,c=Math.sqrt(f*f+h*h);f/=c,h/=c;var v=l*f+u*h,p=v/c;s&&(p=Math.min(Math.max(p,0),1)),p*=c;var d=o[0]=r+p*f,g=o[1]=t+p*h;return Math.sqrt((d-n)*(d-n)+(g-a)*(g-a))}function Ox(r,t,e,i,n,a,o){e<0&&(r=r+e,e=-e),i<0&&(t=t+i,i=-i);var s=r+e,l=t+i,u=o[0]=Math.min(Math.max(n,r),s),f=o[1]=Math.min(Math.max(a,t),l);return Math.sqrt((u-n)*(u-n)+(f-a)*(f-a))}var qe=[];function mI(r,t,e){var i=Ox(t.x,t.y,t.width,t.height,r.x,r.y,qe);return e.set(qe[0],qe[1]),i}function _I(r,t,e){for(var i=0,n=0,a=0,o=0,s,l,u=1/0,f=t.data,h=r.x,c=r.y,v=0;v0){t=t/180*Math.PI,Je.fromArray(r[0]),xt.fromArray(r[1]),Dt.fromArray(r[2]),et.sub(_r,Je,xt),et.sub(dr,Dt,xt);var e=_r.len(),i=dr.len();if(!(e<.001||i<.001)){_r.scale(1/e),dr.scale(1/i);var n=_r.dot(dr),a=Math.cos(t);if(a1&&et.copy(ie,Dt),ie.toArray(r[1])}}}}function SI(r,t,e){if(e<=180&&e>0){e=e/180*Math.PI,Je.fromArray(r[0]),xt.fromArray(r[1]),Dt.fromArray(r[2]),et.sub(_r,xt,Je),et.sub(dr,Dt,xt);var i=_r.len(),n=dr.len();if(!(i<.001||n<.001)){_r.scale(1/i),dr.scale(1/n);var a=_r.dot(t),o=Math.cos(e);if(a=l)et.copy(ie,Dt);else{ie.scaleAndAdd(dr,s/Math.tan(Math.PI/2-f));var h=Dt.x!==xt.x?(ie.x-xt.x)/(Dt.x-xt.x):(ie.y-xt.y)/(Dt.y-xt.y);if(isNaN(h))return;h<0?et.copy(ie,xt):h>1&&et.copy(ie,Dt)}ie.toArray(r[1])}}}}function Ff(r,t,e,i){var n=e==="normal",a=n?r:r.ensureState(e);a.ignore=t;var o=i.get("smooth");o&&o===!0&&(o=.3),a.shape=a.shape||{},o>0&&(a.shape.smooth=o);var s=i.getModel("lineStyle").getLineStyle();n?r.useStyle(s):a.style=s}function xI(r,t){var e=t.smooth,i=t.points;if(i)if(r.moveTo(i[0][0],i[0][1]),e>0&&i.length>=3){var n=fl(i[0],i[1]),a=fl(i[1],i[2]);if(!n||!a){r.lineTo(i[1][0],i[1][1]),r.lineTo(i[2][0],i[2][1]);return}var o=Math.min(n,a)*e,s=Us([],i[1],i[0],o/n),l=Us([],i[1],i[2],o/a),u=Us([],s,l,.5);r.bezierCurveTo(s[0],s[1],s[0],s[1],u[0],u[1]),r.bezierCurveTo(l[0],l[1],l[0],l[1],i[2][0],i[2][1])}else for(var f=1;f0){_(A*C,0,o);var M=A+x;M<0&&S(-M*C,1)}else S(-x*C,1)}}function _(x,T,C){x!==0&&(u=!0);for(var A=T;A0)for(var M=0;M0;M--){var I=C[M-1]*P;_(-I,M,o)}}}function b(x){var T=x<0?-1:1;x=Math.abs(x);for(var C=Math.ceil(x/(o-1)),A=0;A0?_(C,0,A+1):_(-C,o-A-1,o),x-=C,x<=0)return}return u}function yz(r,t,e,i){return Nx(r,"x","width",t,e)}function CI(r,t,e,i){return Nx(r,"y","height",t,e)}function AI(r){var t=[];r.sort(function(d,g){return g.priority-d.priority});var e=new st(0,0,0,0);function i(d){if(!d.ignore){var g=d.ensureState("emphasis");g.ignore==null&&(g.ignore=!1)}d.ignore=!0}for(var n=0;n-1&&(u.style.stroke=u.style.fill,u.style.fill="#fff",u.style.lineWidth=2),i},t.type="series.line",t.dependencies=["grid","polar"],t.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},t})(Qt);function Mu(r,t){var e=r.mapDimensionsAll("defaultedLabel"),i=e.length;if(i===1){var n=ra(r,t,e[0]);return n!=null?n+"":null}else if(i){for(var a=[],o=0;o=0&&i.push(t[a])}return i.join(" ")}var ap=(function(r){E(t,r);function t(e,i,n,a){var o=r.call(this)||this;return o.updateData(e,i,n,a),o}return t.prototype._createSymbol=function(e,i,n,a,o){this.removeAll();var s=te(e,-1,-1,2,2,null,o);s.attr({z2:100,culling:!0,scaleX:a[0]/2,scaleY:a[1]/2}),s.drift=LI,this._symbolType=e,this.add(s)},t.prototype.stopSymbolAnimation=function(e){this.childAt(0).stopAnimation(null,e)},t.prototype.getSymbolType=function(){return this._symbolType},t.prototype.getSymbolPath=function(){return this.childAt(0)},t.prototype.highlight=function(){Qn(this.childAt(0))},t.prototype.downplay=function(){ta(this.childAt(0))},t.prototype.setZ=function(e,i){var n=this.childAt(0);n.zlevel=e,n.z=i},t.prototype.setDraggable=function(e,i){var n=this.childAt(0);n.draggable=e,n.cursor=!i&&e?"move":n.cursor},t.prototype.updateData=function(e,i,n,a){this.silent=!1;var o=e.getItemVisual(i,"symbol")||"circle",s=e.hostModel,l=t.getSymbolSize(e,i),u=o!==this._symbolType,f=a&&a.disableAnimation;if(u){var h=e.getItemVisual(i,"symbolKeepAspect");this._createSymbol(o,e,i,l,h)}else{var c=this.childAt(0);c.silent=!1;var v={scaleX:l[0]/2,scaleY:l[1]/2};f?c.attr(v):Mt(c,v,s,i),bo(c)}if(this._updateCommon(e,i,l,n,a),u){var c=this.childAt(0);if(!f){var v={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:c.style.opacity}};c.scaleX=c.scaleY=0,c.style.opacity=0,Jt(c,v,s,i)}}f&&this.childAt(0).stopAnimation("leave")},t.prototype._updateCommon=function(e,i,n,a,o){var s=this.childAt(0),l=e.hostModel,u,f,h,c,v,p,d,g,y;if(a&&(u=a.emphasisItemStyle,f=a.blurItemStyle,h=a.selectItemStyle,c=a.focus,v=a.blurScope,d=a.labelStatesModels,g=a.hoverScale,y=a.cursorStyle,p=a.emphasisDisabled),!a||e.hasItemOption){var m=a&&a.itemModel?a.itemModel:e.getItemModel(i),_=m.getModel("emphasis");u=_.getModel("itemStyle").getItemStyle(),h=m.getModel(["select","itemStyle"]).getItemStyle(),f=m.getModel(["blur","itemStyle"]).getItemStyle(),c=_.get("focus"),v=_.get("blurScope"),p=_.get("disabled"),d=Zr(m),g=_.getShallow("scale"),y=m.getShallow("cursor")}var S=e.getItemVisual(i,"symbolRotate");s.attr("rotation",(S||0)*Math.PI/180||0);var b=yu(e.getItemVisual(i,"symbolOffset"),n);b&&(s.x=b[0],s.y=b[1]),y&&s.attr("cursor",y);var x=e.getItemVisual(i,"style"),T=x.fill;if(s instanceof ye){var C=s.style;s.useStyle(O({image:C.image,x:C.x,y:C.y,width:C.width,height:C.height},x))}else s.__isEmptyBrush?s.useStyle(O({},x)):s.useStyle(x),s.style.decal=null,s.setColor(T,o&&o.symbolInnerColor),s.style.strokeNoScale=!0;var A=e.getItemVisual(i,"liftZ"),M=this._z2;A!=null?M==null&&(this._z2=s.z2,s.z2+=A):M!=null&&(s.z2=M,this._z2=null);var D=o&&o.useNameLabel;Xr(s,d,{labelFetcher:l,labelDataIndex:i,defaultText:L,inheritColor:T,defaultOpacity:x.opacity});function L(R){return D?e.getName(R):Mu(e,R)}this._sizeX=n[0]/2,this._sizeY=n[1]/2;var P=s.ensureState("emphasis");P.style=u,s.ensureState("select").style=h,s.ensureState("blur").style=f;var I=g==null||g===!0?Math.max(1.1,3/this._sizeY):isFinite(g)&&g>0?+g:1;P.scaleX=this._sizeX*I,P.scaleY=this._sizeY*I,this.setSymbolScale(1),di(this,c,v,p)},t.prototype.setSymbolScale=function(e){this.scaleX=this.scaleY=e},t.prototype.fadeOut=function(e,i,n){var a=this.childAt(0),o=ot(this).dataIndex,s=n&&n.animation;if(this.silent=a.silent=!0,n&&n.fadeLabel){var l=a.getTextContent();l&&xo(l,{style:{opacity:0}},i,{dataIndex:o,removeOpt:s,cb:function(){a.removeTextContent()}})}else a.removeTextContent();xo(a,{style:{opacity:0},scaleX:0,scaleY:0},i,{dataIndex:o,cb:e,removeOpt:s})},t.getSymbolSize=function(e,i){return Gc(e.getItemVisual(i,"symbolSize"))},t})(nt);function LI(r,t){this.parent.drift(r,t)}function Vf(r,t,e,i){return t&&!isNaN(t[0])&&!isNaN(t[1])&&!(i.isIgnore&&i.isIgnore(e))&&!(i.clipShape&&!i.clipShape.contain(t[0],t[1]))&&r.getItemVisual(e,"symbol")!=="none"}function py(r){return r!=null&&!X(r)&&(r={isIgnore:r}),r||{}}function dy(r){var t=r.hostModel,e=t.getModel("emphasis");return{emphasisItemStyle:e.getModel("itemStyle").getItemStyle(),blurItemStyle:t.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:t.getModel(["select","itemStyle"]).getItemStyle(),focus:e.get("focus"),blurScope:e.get("blurScope"),emphasisDisabled:e.get("disabled"),hoverScale:e.get("scale"),labelStatesModels:Zr(t),cursorStyle:t.get("cursor")}}var PI=(function(){function r(t){this.group=new nt,this._SymbolCtor=t||ap}return r.prototype.updateData=function(t,e){this._progressiveEls=null,e=py(e);var i=this.group,n=t.hostModel,a=this._data,o=this._SymbolCtor,s=e.disableAnimation,l=dy(t),u={disableAnimation:s},f=e.getSymbolPoint||function(h){return t.getItemLayout(h)};a||i.removeAll(),t.diff(a).add(function(h){var c=f(h);if(Vf(t,c,h,e)){var v=new o(t,h,l,u);v.setPosition(c),t.setItemGraphicEl(h,v),i.add(v)}}).update(function(h,c){var v=a.getItemGraphicEl(c),p=f(h);if(!Vf(t,p,h,e)){i.remove(v);return}var d=t.getItemVisual(h,"symbol")||"circle",g=v&&v.getSymbolType&&v.getSymbolType();if(!v||g&&g!==d)i.remove(v),v=new o(t,h,l,u),v.setPosition(p);else{v.updateData(t,h,l,u);var y={x:p[0],y:p[1]};s?v.attr(y):Mt(v,y,n)}i.add(v),t.setItemGraphicEl(h,v)}).remove(function(h){var c=a.getItemGraphicEl(h);c&&c.fadeOut(function(){i.remove(c)},n)}).execute(),this._getSymbolPoint=f,this._data=t},r.prototype.updateLayout=function(){var t=this,e=this._data;e&&e.eachItemGraphicEl(function(i,n){var a=t._getSymbolPoint(n);i.setPosition(a),i.markRedraw()})},r.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=dy(t),this._data=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(t,e,i){this._progressiveEls=[],i=py(i);function n(l){l.isGroup||(l.incremental=!0,l.ensureState("emphasis").hoverLayer=!0)}for(var a=t.start;a0?e=i[0]:i[1]<0&&(e=i[1]),e}function Vx(r,t,e,i){var n=NaN;r.stacked&&(n=e.get(e.getCalculationInfo("stackedOverDimension"),i)),isNaN(n)&&(n=r.valueStart);var a=r.baseDataOffset,o=[];return o[a]=e.get(r.baseDim,i),o[1-a]=n,t.dataToPoint(o)}function RI(r,t){var e=[];return t.diff(r).add(function(i){e.push({cmd:"+",idx:i})}).update(function(i,n){e.push({cmd:"=",idx:n,idx1:i})}).remove(function(i){e.push({cmd:"-",idx:i})}).execute(),e}function EI(r,t,e,i,n,a,o,s){for(var l=RI(r,t),u=[],f=[],h=[],c=[],v=[],p=[],d=[],g=Fx(n,t,o),y=r.getLayout("points")||[],m=t.getLayout("points")||[],_=0;_=n||d<0)break;if(ln(y,m)){if(l){d+=a;continue}break}if(d===e)r[a>0?"moveTo":"lineTo"](y,m),h=y,c=m;else{var _=y-u,S=m-f;if(_*_+S*S<.5){d+=a;continue}if(o>0){for(var b=d+a,x=t[b*2],T=t[b*2+1];x===y&&T===m&&g=i||ln(x,T))v=y,p=m;else{M=x-u,D=T-f;var I=y-u,R=x-y,k=m-f,V=T-m,B=void 0,N=void 0;if(s==="x"){B=Math.abs(I),N=Math.abs(R);var Y=M>0?1:-1;v=y-Y*B*o,p=m,L=y+Y*N*o,P=m}else if(s==="y"){B=Math.abs(k),N=Math.abs(V);var Z=D>0?1:-1;v=y,p=m-Z*B*o,L=y,P=m+Z*N*o}else B=Math.sqrt(I*I+k*k),N=Math.sqrt(R*R+V*V),A=N/(N+B),v=y-M*o*(1-A),p=m-D*o*(1-A),L=y+M*o*A,P=m+D*o*A,L=ti(L,ei(x,y)),P=ti(P,ei(T,m)),L=ei(L,ti(x,y)),P=ei(P,ti(T,m)),M=L-y,D=P-m,v=y-M*B/N,p=m-D*B/N,v=ti(v,ei(u,y)),p=ti(p,ei(f,m)),v=ei(v,ti(u,y)),p=ei(p,ti(f,m)),M=y-v,D=m-p,L=y+M*N/B,P=m+D*N/B}r.bezierCurveTo(h,c,v,p,y,m),h=L,c=P}else r.lineTo(y,m)}u=y,f=m,d+=a}return g}var Gx=(function(){function r(){this.smooth=0,this.smoothConstraint=!0}return r})(),kI=(function(r){E(t,r);function t(e){var i=r.call(this,e)||this;return i.type="ec-polyline",i}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new Gx},t.prototype.buildPath=function(e,i){var n=i.points,a=0,o=n.length/2;if(i.connectNulls){for(;o>0&&ln(n[o*2-2],n[o*2-1]);o--);for(;a=0){var S=u?(p-l)*_+l:(v-s)*_+s;return u?[e,S]:[S,e]}s=v,l=p;break;case o.C:v=a[h++],p=a[h++],d=a[h++],g=a[h++],y=a[h++],m=a[h++];var b=u?cl(s,v,d,y,e,f):cl(l,p,g,m,e,f);if(b>0)for(var x=0;x=0){var S=u?Et(l,p,g,m,T):Et(s,v,d,y,T);return u?[e,S]:[S,e]}}s=y,l=m;break}}},t})(gt),OI=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t})(Gx),BI=(function(r){E(t,r);function t(e){var i=r.call(this,e)||this;return i.type="ec-polygon",i}return t.prototype.getDefaultShape=function(){return new OI},t.prototype.buildPath=function(e,i){var n=i.points,a=i.stackedOnPoints,o=0,s=n.length/2,l=i.smoothMonotone;if(i.connectNulls){for(;s>0&&ln(n[s*2-2],n[s*2-1]);s--);for(;ot){a?e.push(o(a,l,t)):n&&e.push(o(n,l,0),o(n,l,t));break}else n&&(e.push(o(n,l,0)),n=null),e.push(l),a=l}return e}function FI(r,t,e){var i=r.getVisual("visualMeta");if(!(!i||!i.length||!r.count())&&t.type==="cartesian2d"){for(var n,a,o=i.length-1;o>=0;o--){var s=r.getDimensionInfo(i[o].dimension);if(n=s&&s.coordDim,n==="x"||n==="y"){a=i[o];break}}if(a){var l=t.getAxis(n),u=F(a.stops,function(_){return{coord:l.toGlobalCoord(l.dataToCoord(_.value)),color:_.color}}),f=u.length,h=a.outerColors.slice();f&&u[0].coord>u[f-1].coord&&(u.reverse(),h.reverse());var c=zI(u,n==="x"?e.getWidth():e.getHeight()),v=c.length;if(!v&&f)return u[0].coord<0?h[1]?h[1]:u[f-1].color:h[0]?h[0]:u[0].color;var p=10,d=c[0].coord-p,g=c[v-1].coord+p,y=g-d;if(y<.001)return"transparent";w(c,function(_){_.offset=(_.coord-d)/y}),c.push({offset:v?c[v-1].offset:.5,color:h[1]||"transparent"}),c.unshift({offset:v?c[0].offset:.5,color:h[0]||"transparent"});var m=new Uo(0,0,0,0,c,!0);return m[n]=d,m[n+"2"]=g,m}}}function VI(r,t,e){var i=r.get("showAllSymbol"),n=i==="auto";if(!(i&&!n)){var a=e.getAxesByScale("ordinal")[0];if(a&&!(n&&GI(a,t))){var o=t.mapDimension(a.dim),s={};return w(a.getViewLabels(),function(l){var u=a.scale.getRawOrdinalNumber(l.tickValue);s[u]=1}),function(l){return!s.hasOwnProperty(t.get(o,l))}}}}function GI(r,t){var e=r.getExtent(),i=Math.abs(e[1]-e[0])/r.scale.count();isNaN(i)&&(i=0);for(var n=t.count(),a=Math.max(1,Math.round(n/5)),o=0;oi)return!1;return!0}function HI(r,t){return isNaN(r)||isNaN(t)}function WI(r){for(var t=r.length/2;t>0&&HI(r[t*2-2],r[t*2-1]);t--);return t-1}function Sy(r,t){return[r[t*2],r[t*2+1]]}function YI(r,t,e){for(var i=r.length/2,n=e==="x"?0:1,a,o,s=0,l=-1,u=0;u=t||a>=t&&o<=t){l=u;break}s=u,a=o}return{range:[s,l],t:(t-a)/(o-a)}}function Ux(r){if(r.get(["endLabel","show"]))return!0;for(var t=0;t0&&e.get(["emphasis","lineStyle","width"])==="bolder"){var N=p.getState("emphasis").style;N.lineWidth=+p.style.lineWidth+1}ot(p).seriesIndex=e.seriesIndex,di(p,k,V,B);var Y=_y(e.get("smooth")),Z=e.get("smoothMonotone");if(p.setShape({smooth:Y,smoothMonotone:Z,connectNulls:T}),d){var $=s.getCalculationInfo("stackedOnSeries"),ut=0;d.useStyle(K(u.getAreaStyle(),{fill:L,opacity:.7,lineJoin:"bevel",decal:s.getVisual("style").decal})),$&&(ut=_y($.get("smooth"))),d.setShape({smooth:Y,stackedOnSmooth:ut,smoothMonotone:Z,connectNulls:T}),ea(d,e,"areaStyle"),ot(d).seriesIndex=e.seriesIndex,di(d,k,V,B)}var dt=this._changePolyState;s.eachItemGraphicEl(function(bt){bt&&(bt.onHoverStateChange=dt)}),this._polyline.onHoverStateChange=dt,this._data=s,this._coordSys=a,this._stackedOnPoints=b,this._points=f,this._step=M,this._valueOrigin=_,e.get("triggerLineEvent")&&(this.packEventData(e,p),d&&this.packEventData(e,d))},t.prototype.packEventData=function(e,i){ot(i).eventData={componentType:"series",componentSubType:"line",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"line"}},t.prototype.highlight=function(e,i,n,a){var o=e.getData(),s=vn(o,a);if(this._changePolyState("emphasis"),!(s instanceof Array)&&s!=null&&s>=0){var l=o.getLayout("points"),u=o.getItemGraphicEl(s);if(!u){var f=l[s*2],h=l[s*2+1];if(isNaN(f)||isNaN(h)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(f,h))return;var c=e.get("zlevel")||0,v=e.get("z")||0;u=new ap(o,s),u.x=f,u.y=h,u.setZ(c,v);var p=u.getSymbolPath().getTextContent();p&&(p.zlevel=c,p.z=v,p.z2=this._polyline.z2+1),u.__temp=!0,o.setItemGraphicEl(s,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else Nt.prototype.highlight.call(this,e,i,n,a)},t.prototype.downplay=function(e,i,n,a){var o=e.getData(),s=vn(o,a);if(this._changePolyState("normal"),s!=null&&s>=0){var l=o.getItemGraphicEl(s);l&&(l.__temp?(o.setItemGraphicEl(s,null),this.group.remove(l)):l.downplay())}else Nt.prototype.downplay.call(this,e,i,n,a)},t.prototype._changePolyState=function(e){var i=this._polygon;Hh(this._polyline,e),i&&Hh(i,e)},t.prototype._newPolyline=function(e){var i=this._polyline;return i&&this._lineGroup.remove(i),i=new kI({shape:{points:e},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(i),this._polyline=i,i},t.prototype._newPolygon=function(e,i){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new BI({shape:{points:e,stackedOnPoints:i},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},t.prototype._initSymbolLabelAnimation=function(e,i,n){var a,o,s=i.getBaseAxis(),l=s.inverse;i.type==="cartesian2d"?(a=s.isHorizontal(),o=!1):i.type==="polar"&&(a=s.dim==="angle",o=!0);var u=e.hostModel,f=u.get("animationDuration");j(f)&&(f=f(null));var h=u.get("animationDelay")||0,c=j(h)?h(null):h;e.eachItemGraphicEl(function(v,p){var d=v;if(d){var g=[v.x,v.y],y=void 0,m=void 0,_=void 0;if(n)if(o){var S=n,b=i.pointToCoord(g);a?(y=S.startAngle,m=S.endAngle,_=-b[1]/180*Math.PI):(y=S.r0,m=S.r,_=b[0])}else{var x=n;a?(y=x.x,m=x.x+x.width,_=v.x):(y=x.y+x.height,m=x.y,_=v.y)}var T=m===y?0:(_-y)/(m-y);l&&(T=1-T);var C=j(h)?h(p):f*T+c,A=d.getSymbolPath(),M=A.getTextContent();d.attr({scaleX:0,scaleY:0}),d.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:C}),M&&M.animateFrom({style:{opacity:0}},{duration:300,delay:C}),A.disableLabelAnimation=!0}})},t.prototype._initOrUpdateEndLabel=function(e,i,n){var a=e.getModel("endLabel");if(Ux(e)){var o=e.getData(),s=this._polyline,l=o.getLayout("points");if(!l){s.removeTextContent(),this._endLabel=null;return}var u=this._endLabel;u||(u=this._endLabel=new ct({z2:200}),u.ignoreClip=!0,s.setTextContent(this._endLabel),s.disableLabelAnimation=!0);var f=WI(l);f>=0&&(Xr(s,Zr(e,"endLabel"),{inheritColor:n,labelFetcher:e,labelDataIndex:f,defaultText:function(h,c,v){return v!=null?zx(o,v):Mu(o,h)},enableTextSetter:!0},UI(a,i)),s.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},t.prototype._endLabelOnDuring=function(e,i,n,a,o,s,l){var u=this._endLabel,f=this._polyline;if(u){e<1&&a.originalX==null&&(a.originalX=u.x,a.originalY=u.y);var h=n.getLayout("points"),c=n.hostModel,v=c.get("connectNulls"),p=s.get("precision"),d=s.get("distance")||0,g=l.getBaseAxis(),y=g.isHorizontal(),m=g.inverse,_=i.shape,S=m?y?_.x:_.y+_.height:y?_.x+_.width:_.y,b=(y?d:0)*(m?-1:1),x=(y?0:-d)*(m?-1:1),T=y?"x":"y",C=YI(h,S,T),A=C.range,M=A[1]-A[0],D=void 0;if(M>=1){if(M>1&&!v){var L=Sy(h,A[0]);u.attr({x:L[0]+b,y:L[1]+x}),o&&(D=c.getRawValue(A[0]))}else{var L=f.getPointOn(S,T);L&&u.attr({x:L[0]+b,y:L[1]+x});var P=c.getRawValue(A[0]),I=c.getRawValue(A[1]);o&&(D=U_(n,p,P,I,C.t))}a.lastFrameIndex=A[0]}else{var R=e===1||a.lastFrameIndex>0?A[0]:0,L=Sy(h,R);o&&(D=c.getRawValue(R)),u.attr({x:L[0]+b,y:L[1]+x})}if(o){var k=Xo(u);typeof k.setLabelText=="function"&&k.setLabelText(D)}}},t.prototype._doUpdateAnimation=function(e,i,n,a,o,s,l){var u=this._polyline,f=this._polygon,h=e.hostModel,c=EI(this._data,e,this._stackedOnPoints,i,this._coordSys,n,this._valueOrigin),v=c.current,p=c.stackedOnCurrent,d=c.next,g=c.stackedOnNext;if(o&&(p=ri(c.stackedOnCurrent,c.current,n,o,l),v=ri(c.current,null,n,o,l),g=ri(c.stackedOnNext,c.next,n,o,l),d=ri(c.next,null,n,o,l)),my(v,d)>3e3||f&&my(p,g)>3e3){u.stopAnimation(),u.setShape({points:d}),f&&(f.stopAnimation(),f.setShape({points:d,stackedOnPoints:g}));return}u.shape.__points=c.current,u.shape.points=v;var y={shape:{points:d}};c.current!==v&&(y.shape.__points=c.next),u.stopAnimation(),Mt(u,y,h),f&&(f.setShape({points:v,stackedOnPoints:p}),f.stopAnimation(),Mt(f,{shape:{stackedOnPoints:g}},h),u.shape.points!==f.shape.points&&(f.shape.points=u.shape.points));for(var m=[],_=c.status,S=0;S<_.length;S++){var b=_[S].cmd;if(b==="="){var x=e.getItemGraphicEl(_[S].idx1);x&&m.push({el:x,ptIdx:S})}}u.animators&&u.animators.length&&u.animators[0].during(function(){f&&f.dirtyShape();for(var T=u.shape.__points,C=0;Ct&&(t=r[e]);return isFinite(t)?t:NaN},min:function(r){for(var t=1/0,e=0;e10&&o.type==="cartesian2d"&&a){var l=o.getBaseAxis(),u=o.getOtherAxis(l),f=l.getExtent(),h=i.getDevicePixelRatio(),c=Math.abs(f[1]-f[0])*(h||1),v=Math.round(s/c);if(isFinite(v)&&v>1){a==="lttb"?t.setData(n.lttbDownSample(n.mapDimension(u.dim),1/v)):a==="minmax"&&t.setData(n.minmaxDownSample(n.mapDimension(u.dim),1/v));var p=void 0;G(a)?p=$I[a]:j(a)&&(p=a),p&&t.setData(n.downSample(n.mapDimension(u.dim),1/v,p,qI))}}}}}function KI(r){r.registerChartView(XI),r.registerSeriesModel(DI),r.registerLayout(ZI("line",!0)),r.registerVisual({seriesType:"line",reset:function(t){var e=t.getData(),i=t.getModel("lineStyle").getLineStyle();i&&!i.stroke&&(i.stroke=e.getVisual("style").fill),e.setVisual("legendLineStyle",i)}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,Xx("line"))}var Io=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.getInitialData=function(e,i){return xu(null,this,{useEncodeDefaulter:!0})},t.prototype.getMarkerPosition=function(e,i,n){var a=this.coordinateSystem;if(a&&a.clampData){var o=a.clampData(e),s=a.dataToPoint(o);if(n)w(a.getAxes(),function(c,v){if(c.type==="category"&&i!=null){var p=c.getTicksCoords(),d=c.getTickModel().get("alignWithLabel"),g=o[v],y=i[v]==="x1"||i[v]==="y1";if(y&&!d&&(g+=1),p.length<2)return;if(p.length===2){s[v]=c.toGlobalCoord(c.getExtent()[y?1:0]);return}for(var m=void 0,_=void 0,S=1,b=0;bg){_=(x+m)/2;break}b===1&&(S=T-p[0].tickValue)}_==null&&(m?m&&(_=p[p.length-1].coord):_=p[0].coord),s[v]=c.toGlobalCoord(_)}});else{var l=this.getData(),u=l.getLayout("offset"),f=l.getLayout("size"),h=a.getBaseAxis().isHorizontal()?0:1;s[h]+=u+f/2}return s}return[NaN,NaN]},t.type="series.__base_bar__",t.defaultOption={z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod"},t})(Qt);Qt.registerClass(Io);var JI=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.getInitialData=function(){return xu(null,this,{useEncodeDefaulter:!0,createInvertedIndices:!!this.get("realtimeSort",!0)||null})},t.prototype.getProgressive=function(){return this.get("large")?this.get("progressive"):!1},t.prototype.getProgressiveThreshold=function(){var e=this.get("progressiveThreshold"),i=this.get("largeThreshold");return i>e&&(e=i),e},t.prototype.brushSelector=function(e,i,n){return n.rect(i.getItemLayout(e))},t.type="series.bar",t.dependencies=["grid","polar"],t.defaultOption=_i(Io.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}),t})(Io),jI=(function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r})(),xy=(function(r){E(t,r);function t(e){var i=r.call(this,e)||this;return i.type="sausage",i}return t.prototype.getDefaultShape=function(){return new jI},t.prototype.buildPath=function(e,i){var n=i.cx,a=i.cy,o=Math.max(i.r0||0,0),s=Math.max(i.r,0),l=(s-o)*.5,u=o+l,f=i.startAngle,h=i.endAngle,c=i.clockwise,v=Math.PI*2,p=c?h-fMath.PI/2&&fs)return!0;s=h}return!1},t.prototype._isOrderDifferentInView=function(e,i){for(var n=i.scale,a=n.getExtent(),o=Math.max(0,a[0]),s=Math.min(a[1],n.getOrdinalMeta().categories.length-1);o<=s;++o)if(e.ordinalNumbers[o]!==n.getRawOrdinalNumber(o))return!0},t.prototype._updateSortWithinSameData=function(e,i,n,a){if(this._isOrderChangedWithinSameData(e,i,n)){var o=this._dataSort(e,n,i);this._isOrderDifferentInView(o,n)&&(this._removeOnRenderedListener(a),a.dispatchAction({type:"changeAxisOrder",componentType:n.dim+"Axis",axisId:n.index,sortInfo:o}))}},t.prototype._dispatchInitSort=function(e,i,n){var a=i.baseAxis,o=this._dataSort(e,a,function(s){return e.get(e.mapDimension(i.otherAxis.dim),s)});n.dispatchAction({type:"changeAxisOrder",componentType:a.dim+"Axis",isInitSort:!0,axisId:a.index,sortInfo:o})},t.prototype.remove=function(e,i){this._clear(this._model),this._removeOnRenderedListener(i)},t.prototype.dispose=function(e,i){this._removeOnRenderedListener(i)},t.prototype._removeOnRenderedListener=function(e){this._onRendered&&(e.getZr().off("rendered",this._onRendered),this._onRendered=null)},t.prototype._clear=function(e){var i=this.group,n=this._data;e&&e.isAnimationEnabled()&&n&&!this._isLargeDraw?(this._removeBackground(),this._backgroundEls=[],n.eachItemGraphicEl(function(a){bl(a,e,ot(a).dataIndex)})):i.removeAll(),this._data=null,this._isFirstFrame=!0},t.prototype._removeBackground=function(){this.group.remove(this._backgroundGroup),this._backgroundGroup=null},t.type="bar",t})(Nt),by={cartesian2d:function(r,t){var e=t.width<0?-1:1,i=t.height<0?-1:1;e<0&&(t.x+=t.width,t.width=-t.width),i<0&&(t.y+=t.height,t.height=-t.height);var n=r.x+r.width,a=r.y+r.height,o=Hf(t.x,r.x),s=Wf(t.x+t.width,n),l=Hf(t.y,r.y),u=Wf(t.y+t.height,a),f=sn?s:o,t.y=h&&l>a?u:l,t.width=f?0:s-o,t.height=h?0:u-l,e<0&&(t.x+=t.width,t.width=-t.width),i<0&&(t.y+=t.height,t.height=-t.height),f||h},polar:function(r,t){var e=t.r0<=t.r?1:-1;if(e<0){var i=t.r;t.r=t.r0,t.r0=i}var n=Wf(t.r,r.r),a=Hf(t.r0,r.r0);t.r=n,t.r0=a;var o=n-a<0;if(e<0){var i=t.r;t.r=t.r0,t.r0=i}return o}},wy={cartesian2d:function(r,t,e,i,n,a,o,s,l){var u=new vt({shape:O({},i),z2:1});if(u.__dataIndex=e,u.name="item",a){var f=u.shape,h=n?"height":"width";f[h]=0}return u},polar:function(r,t,e,i,n,a,o,s,l){var u=!n&&l?xy:rr,f=new u({shape:i,z2:1});f.name="item";var h=Zx(n);if(f.calculateTextPosition=QI(h,{isRoundCap:u===xy}),a){var c=f.shape,v=n?"r":"endAngle",p={};c[v]=n?i.r0:i.startAngle,p[v]=i[v],(s?Mt:Jt)(f,{shape:p},a)}return f}};function iR(r,t){var e=r.get("realtimeSort",!0),i=t.getBaseAxis();if(e&&i.type==="category"&&t.type==="cartesian2d")return{baseAxis:i,otherAxis:t.getOtherAxis(i)}}function Ty(r,t,e,i,n,a,o,s){var l,u;a?(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||(o?Mt:Jt)(e,{shape:l},t,n,null);var f=t?r.baseAxis.model:null;(o?Mt:Jt)(e,{shape:u},f,n)}function Cy(r,t){for(var e=0;e0?1:-1,o=i.height>0?1:-1;return{x:i.x+a*n/2,y:i.y+o*n/2,width:i.width-a*n,height:i.height-o*n}},polar:function(r,t,e){var i=r.getItemLayout(t);return{cx:i.cx,cy:i.cy,r0:i.r0,r:i.r,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}}};function oR(r){return r.startAngle!=null&&r.endAngle!=null&&r.startAngle===r.endAngle}function Zx(r){return(function(t){var e=t?"Arc":"Angle";return function(i){switch(i){case"start":case"insideStart":case"end":case"insideEnd":return i+e;default:return i}}})(r)}function My(r,t,e,i,n,a,o,s){var l=t.getItemVisual(e,"style");if(s){if(!a.get("roundCap")){var f=r.shape,h=Ja(i.getModel("itemStyle"),f,!0);O(f,h),r.setShape(f)}}else{var u=i.get(["itemStyle","borderRadius"])||0;r.setShape("r",u)}r.useStyle(l);var c=i.getShallow("cursor");c&&r.attr("cursor",c);var v=s?o?n.r>=n.r0?"endArc":"startArc":n.endAngle>=n.startAngle?"endAngle":"startAngle":o?n.height>=0?"bottom":"top":n.width>=0?"right":"left",p=Zr(i);Xr(r,p,{labelFetcher:a,labelDataIndex:e,defaultText:Mu(a.getData(),e),inheritColor:l.fill,defaultOpacity:l.opacity,defaultOutsidePosition:v});var d=r.getTextContent();if(s&&d){var g=i.get(["label","position"]);r.textConfig.inside=g==="middle"?!0:null,tR(r,g==="outside"?v:g,Zx(o),i.get(["label","rotate"]))}EM(d,p,a.getRawValue(e),function(m){return zx(t,m)});var y=i.getModel(["emphasis"]);di(r,y.get("focus"),y.get("blurScope"),y.get("disabled")),ea(r,i),oR(n)&&(r.style.fill="none",r.style.stroke="none",w(r.states,function(m){m.style&&(m.style.fill=m.style.stroke="none")}))}function sR(r,t){var e=r.get(["itemStyle","borderColor"]);if(!e||e==="none")return 0;var i=r.get(["itemStyle","borderWidth"])||0,n=isNaN(t.width)?Number.MAX_VALUE:Math.abs(t.width),a=isNaN(t.height)?Number.MAX_VALUE:Math.abs(t.height);return Math.min(i,n,a)}var lR=(function(){function r(){}return r})(),Dy=(function(r){E(t,r);function t(e){var i=r.call(this,e)||this;return i.type="largeBar",i}return t.prototype.getDefaultShape=function(){return new lR},t.prototype.buildPath=function(e,i){for(var n=i.points,a=this.baseDimIdx,o=1-this.baseDimIdx,s=[],l=[],u=this.barWidth,f=0;f=0?e:null},30,!1);function uR(r,t,e){for(var i=r.baseDimIdx,n=1-i,a=r.shape.points,o=r.largeDataIndices,s=[],l=[],u=r.barWidth,f=0,h=a.length/3;f=s[0]&&t<=s[0]+l[0]&&e>=s[1]&&e<=s[1]+l[1])return o[f]}return-1}function $x(r,t,e){if(op(e,"cartesian2d")){var i=t,n=e.getArea();return{x:r?i.x:n.x,y:r?n.y:i.y,width:r?i.width:n.width,height:r?n.height:i.height}}else{var n=e.getArea(),a=t;return{cx:n.cx,cy:n.cy,r0:r?n.r0:a.r0,r:r?n.r:a.r,startAngle:r?a.startAngle:0,endAngle:r?a.endAngle:Math.PI*2}}}function fR(r,t,e){var i=r.type==="polar"?rr:vt;return new i({shape:$x(t,e,r),silent:!0,z2:0})}function hR(r){r.registerChartView(rR),r.registerSeriesModel(JI),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,ft(gx,"bar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,yx("bar")),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,Xx("bar")),r.registerAction({type:"changeAxisOrder",event:"changeAxisOrder",update:"update"},function(t,e){var i=t.componentType||"series";e.eachComponent({mainType:i,query:t},function(n){t.sortInfo&&n.axis.setCategorySortInfo(t.sortInfo)})})}var Iy=Math.PI*2,Es=Math.PI/180;function qx(r,t){return le(r.getBoxLayoutParams(),{width:t.getWidth(),height:t.getHeight()})}function Kx(r,t){var e=qx(r,t),i=r.get("center"),n=r.get("radius");z(n)||(n=[0,n]);var a=Q(e.width,t.getWidth()),o=Q(e.height,t.getHeight()),s=Math.min(a,o),l=Q(n[0],s/2),u=Q(n[1],s/2),f,h,c=r.coordinateSystem;if(c){var v=c.dataToPoint(i);f=v[0]||0,h=v[1]||0}else z(i)||(i=[i,i]),f=Q(i[0],a)+e.x,h=Q(i[1],o)+e.y;return{cx:f,cy:h,r0:l,r:u}}function vR(r,t,e){t.eachSeriesByType(r,function(i){var n=i.getData(),a=n.mapDimension("value"),o=qx(i,e),s=Kx(i,e),l=s.cx,u=s.cy,f=s.r,h=s.r0,c=-i.get("startAngle")*Es,v=i.get("endAngle"),p=i.get("padAngle")*Es;v=v==="auto"?c-Iy:-v*Es;var d=i.get("minAngle")*Es,g=d+p,y=0;n.each(a,function(V){!isNaN(V)&&y++});var m=n.getSum(a),_=Math.PI/(m||y)*2,S=i.get("clockwise"),b=i.get("roseType"),x=i.get("stillShowZeroSum"),T=n.getDataExtent(a);T[0]=0;var C=S?1:-1,A=[c,v],M=C*p/2;Q_(A,!S),c=A[0],v=A[1];var D=Jx(i);D.startAngle=c,D.endAngle=v,D.clockwise=S;var L=Math.abs(v-c),P=L,I=0,R=c;if(n.setLayout({viewRect:o,r:f}),n.each(a,function(V,B){var N;if(isNaN(V)){n.setItemLayout(B,{angle:NaN,startAngle:NaN,endAngle:NaN,clockwise:S,cx:l,cy:u,r0:h,r:b?NaN:f});return}b!=="area"?N=m===0&&x?_:V*_:N=L/y,NN?(Z=R+C*N/2,$=Z):(Z=R+M,$=Y-M),n.setItemLayout(B,{angle:N,startAngle:Z,endAngle:$,clockwise:S,cx:l,cy:u,r0:h,r:b?Tt(V,T,[h,f]):f}),R=Y}),Pe?y:g,b=Math.abs(_.label.y-e);if(b>=S.maxY){var x=_.label.x-t-_.len2*n,T=i+_.len,C=Math.abs(x)r.unconstrainedWidth?null:v:null;i.setStyle("width",p)}var d=i.getBoundingRect();a.width=d.width;var g=(i.style.margin||0)+2.1;a.height=d.height+g,a.y-=(a.height-h)/2}}}function Yf(r){return r.position==="center"}function dR(r){var t=r.getData(),e=[],i,n,a=!1,o=(r.get("minShowLabelAngle")||0)*cR,s=t.getLayout("viewRect"),l=t.getLayout("r"),u=s.width,f=s.x,h=s.y,c=s.height;function v(x){x.ignore=!0}function p(x){if(!x.ignore)return!0;for(var T in x.states)if(x.states[T].ignore===!1)return!0;return!1}t.each(function(x){var T=t.getItemGraphicEl(x),C=T.shape,A=T.getTextContent(),M=T.getTextGuideLine(),D=t.getItemModel(x),L=D.getModel("label"),P=L.get("position")||D.get(["emphasis","label","position"]),I=L.get("distanceToLabelLine"),R=L.get("alignTo"),k=Q(L.get("edgeDistance"),u),V=L.get("bleedMargin"),B=D.getModel("labelLine"),N=B.get("length");N=Q(N,u);var Y=B.get("length2");if(Y=Q(Y,u),Math.abs(C.endAngle-C.startAngle)0?"right":"left":$>0?"left":"right"}var $r=Math.PI,Ar=0,ga=L.get("rotate");if(yt(ga))Ar=ga*($r/180);else if(P==="center")Ar=0;else if(ga==="radial"||ga===!0){var Cw=$<0?-Z+$r:-Z;Ar=Cw}else if(ga==="tangential"&&P!=="outside"&&P!=="outer"){var xn=Math.atan2($,ut);xn<0&&(xn=$r*2+xn);var Aw=ut>0;Aw&&(xn=$r+xn),Ar=xn-$r}if(a=!!Ar,A.x=dt,A.y=bt,A.rotation=Ar,A.setStyle({verticalAlign:"middle"}),me){A.setStyle({align:Ae});var Iu=A.states.select;Iu&&(Iu.x+=A.x,Iu.y+=A.y)}else{var ya=A.getBoundingRect().clone();ya.applyTransform(A.getComputedTransform());var Pp=(A.style.margin||0)+2.1;ya.y-=Pp/2,ya.height+=Pp,e.push({label:A,labelLine:M,position:P,len:N,len2:Y,minTurnAngle:B.get("minTurnAngle"),maxSurfaceAngle:B.get("maxSurfaceAngle"),surfaceNormal:new et($,ut),linePoints:ue,textAlign:Ae,labelDistance:I,labelAlignTo:R,edgeDistance:k,bleedMargin:V,rect:ya,unconstrainedWidth:ya.width,labelStyleWidth:A.style.width})}T.setTextConfig({inside:me})}}),!a&&r.get("avoidLabelOverlap")&&pR(e,i,n,l,u,c,f,h);for(var d=0;d0){for(var f=o.getItemLayout(0),h=1;isNaN(f&&f.startAngle)&&h=a.r0}},t.type="pie",t})(Nt);function sp(r,t,e){t=z(t)&&{coordDimensions:t}||O({encodeDefine:r.getEncode()},t);var i=r.getSource(),n=Qc(i,t).dimensions,a=new Su(n,r);return a.initData(i,e),a}var tb=(function(){function r(t,e){this._getDataWithEncodedVisual=t,this._getRawData=e}return r.prototype.getAllNames=function(){var t=this._getRawData();return t.mapArray(t.getName)},r.prototype.containName=function(t){var e=this._getRawData();return e.indexOfName(t)>=0},r.prototype.indexOfName=function(t){var e=this._getDataWithEncodedVisual();return e.indexOfName(t)},r.prototype.getItemVisual=function(t,e){var i=this._getDataWithEncodedVisual();return i.getItemVisual(t,e)},r})(),mR=St(),_R=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.init=function(e){r.prototype.init.apply(this,arguments),this.legendVisualProvider=new tb(W(this.getData,this),W(this.getRawData,this)),this._defaultLabelLine(e)},t.prototype.mergeOption=function(){r.prototype.mergeOption.apply(this,arguments)},t.prototype.getInitialData=function(){return sp(this,{coordDimensions:["value"],encodeDefaulter:ft(q1,this)})},t.prototype.getDataParams=function(e){var i=this.getData(),n=mR(i),a=n.seats;if(!a){var o=[];i.each(i.mapDimension("value"),function(l){o.push(l)}),a=n.seats=B_(o,i.hostModel.get("percentPrecision"))}var s=r.prototype.getDataParams.call(this,e);return s.percent=a[e]||0,s.$vars.push("percent"),s},t.prototype._defaultLabelLine=function(e){_l(e,"labelLine",["show"]);var i=e.labelLine,n=e.emphasis.labelLine;i.show=i.show&&e.label.show,n.show=n.show&&e.emphasis.label.show},t.type="series.pie",t.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"},t})(Qt);function SR(r){return{seriesType:r,reset:function(t,e){var i=t.getData();i.filterSelf(function(n){var a=i.mapDimension("value"),o=i.get(a,n);return!(yt(o)&&!isNaN(o)&&o<0)})}}}function xR(r){r.registerChartView(yR),r.registerSeriesModel(_R),PS("pie",r.registerAction),r.registerLayout(ft(vR,"pie")),r.registerProcessor(jx("pie")),r.registerProcessor(SR("pie"))}var bR=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.type="grid",t.dependencies=["xAxis","yAxis"],t.layoutMode="box",t.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"},t})(at),dv=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",kt).models[0]},t.type="cartesian2dAxis",t})(at);Wt(dv,qo);var eb={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,showMinLine:!0,showMaxLine:!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)"]}}},wR=J({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},eb),lp=J({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}}},eb),TR=J({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},lp),CR=K({logBase:10},lp);const rb={category:wR,value:lp,time:TR,log:CR};var AR={value:1,category:1,time:1,log:1};function Ro(r,t,e,i){w(AR,function(n,a){var o=J(J({},rb[a],!0),i,!0),s=(function(l){E(u,l);function u(){var f=l!==null&&l.apply(this,arguments)||this;return f.type=t+"Axis."+a,f}return u.prototype.mergeDefaultAndTheme=function(f,h){var c=Co(this),v=c?ca(f):{},p=h.getTheme();J(f,p.get(a+"Axis")),J(f,this.getDefaultOption()),f.type=Ey(f),c&&gi(f,v,c)},u.prototype.optionUpdated=function(){var f=this.option;f.type==="category"&&(this.__ordinalMeta=fv.createByAxisModel(this))},u.prototype.getCategories=function(f){var h=this.option;if(h.type==="category")return f?h.data:this.__ordinalMeta.categories},u.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},u.type=t+"Axis."+a,u.defaultOption=o,u})(e);r.registerComponentModel(s)}),r.registerSubTypeDefaulter(t+"Axis",Ey)}function Ey(r){return r.type||(r.data?"category":"value")}var MR=(function(){function r(t){this.type="cartesian",this._dimList=[],this._axes={},this.name=t||""}return r.prototype.getAxis=function(t){return this._axes[t]},r.prototype.getAxes=function(){return F(this._dimList,function(t){return this._axes[t]},this)},r.prototype.getAxesByScale=function(t){return t=t.toLowerCase(),wt(this.getAxes(),function(e){return e.scale.type===t})},r.prototype.addAxis=function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)},r})(),gv=["x","y"];function ky(r){return r.type==="interval"||r.type==="time"}var DR=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="cartesian2d",e.dimensions=gv,e}return t.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var e=this.getAxis("x").scale,i=this.getAxis("y").scale;if(!(!ky(e)||!ky(i))){var n=e.getExtent(),a=i.getExtent(),o=this.dataToPoint([n[0],a[0]]),s=this.dataToPoint([n[1],a[1]]),l=n[1]-n[0],u=a[1]-a[0];if(!(!l||!u)){var f=(s[0]-o[0])/l,h=(s[1]-o[1])/u,c=o[0]-n[0]*f,v=o[1]-a[0]*h,p=this._transform=[f,0,0,h,c,v];this._invTransform=yn([],p)}}},t.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},t.prototype.containPoint=function(e){var i=this.getAxis("x"),n=this.getAxis("y");return i.contain(i.toLocalCoord(e[0]))&&n.contain(n.toLocalCoord(e[1]))},t.prototype.containData=function(e){return this.getAxis("x").containData(e[0])&&this.getAxis("y").containData(e[1])},t.prototype.containZone=function(e,i){var n=this.dataToPoint(e),a=this.dataToPoint(i),o=this.getArea(),s=new st(n[0],n[1],a[0]-n[0],a[1]-n[1]);return o.intersect(s)},t.prototype.dataToPoint=function(e,i,n){n=n||[];var a=e[0],o=e[1];if(this._transform&&a!=null&&isFinite(a)&&o!=null&&isFinite(o))return Bt(n,e,this._transform);var s=this.getAxis("x"),l=this.getAxis("y");return n[0]=s.toGlobalCoord(s.dataToCoord(a,i)),n[1]=l.toGlobalCoord(l.dataToCoord(o,i)),n},t.prototype.clampData=function(e,i){var n=this.getAxis("x").scale,a=this.getAxis("y").scale,o=n.getExtent(),s=a.getExtent(),l=n.parse(e[0]),u=a.parse(e[1]);return i=i||[],i[0]=Math.min(Math.max(Math.min(o[0],o[1]),l),Math.max(o[0],o[1])),i[1]=Math.min(Math.max(Math.min(s[0],s[1]),u),Math.max(s[0],s[1])),i},t.prototype.pointToData=function(e,i){var n=[];if(this._invTransform)return Bt(n,e,this._invTransform);var a=this.getAxis("x"),o=this.getAxis("y");return n[0]=a.coordToData(a.toLocalCoord(e[0]),i),n[1]=o.coordToData(o.toLocalCoord(e[1]),i),n},t.prototype.getOtherAxis=function(e){return this.getAxis(e.dim==="x"?"y":"x")},t.prototype.getArea=function(e){e=e||0;var i=this.getAxis("x").getGlobalExtent(),n=this.getAxis("y").getGlobalExtent(),a=Math.min(i[0],i[1])-e,o=Math.min(n[0],n[1])-e,s=Math.max(i[0],i[1])-a+e,l=Math.max(n[0],n[1])-o+e;return new st(a,o,s,l)},t})(MR),LR=(function(r){E(t,r);function t(e,i,n,a,o){var s=r.call(this,e,i,n)||this;return s.index=0,s.type=a||"value",s.position=o||"bottom",s}return t.prototype.isHorizontal=function(){var e=this.position;return e==="top"||e==="bottom"},t.prototype.getGlobalExtent=function(e){var i=this.getExtent();return i[0]=this.toGlobalCoord(i[0]),i[1]=this.toGlobalCoord(i[1]),e&&i[0]>i[1]&&i.reverse(),i},t.prototype.pointToData=function(e,i){return this.coordToData(this.toLocalCoord(e[this.dim==="x"?0:1]),i)},t.prototype.setCategorySortInfo=function(e){if(this.type!=="category")return!1;this.model.option.categorySortInfo=e,this.scale.setSortInfo(e)},t})(or);function yv(r,t,e){e=e||{};var i=r.coordinateSystem,n=t.axis,a={},o=n.getAxesOnZeroOf()[0],s=n.position,l=o?"onZero":s,u=n.dim,f=i.getRect(),h=[f.x,f.x+f.width,f.y,f.y+f.height],c={left:0,right:1,top:0,bottom:1,onZero:2},v=t.get("offset")||0,p=u==="x"?[h[2]-v,h[3]+v]:[h[0]-v,h[1]+v];if(o){var d=o.toGlobalCoord(o.dataToCoord(0));p[c.onZero]=Math.max(Math.min(d,p[1]),p[0])}a.position=[u==="y"?p[c[l]]:h[0],u==="x"?p[c[l]]:h[3]],a.rotation=Math.PI/2*(u==="x"?0:1);var g={top:-1,bottom:1,left:-1,right:1};a.labelDirection=a.tickDirection=a.nameDirection=g[s],a.labelOffset=o?p[c[s]]-p[c.onZero]:0,t.get(["axisTick","inside"])&&(a.tickDirection=-a.tickDirection),zr(e.labelInside,t.get(["axisLabel","inside"]))&&(a.labelDirection=-a.labelDirection);var y=t.get(["axisLabel","rotate"]);return a.labelRotate=l==="top"?-y:y,a.z2=1,a}function Oy(r){return r.get("coordinateSystem")==="cartesian2d"}function By(r){var t={xAxisModel:null,yAxisModel:null};return w(t,function(e,i){var n=i.replace(/Model$/,""),a=r.getReferringComponents(n,kt).models[0];t[i]=a}),t}var Uf=Math.log;function ib(r,t,e){var i=Wr.prototype,n=i.getTicks.call(e),a=i.getTicks.call(e,!0),o=n.length-1,s=i.getInterval.call(e),l=bx(r,t),u=l.extent,f=l.fixMin,h=l.fixMax;if(r.type==="log"){var c=Uf(r.base);u=[Uf(u[0])/c,Uf(u[1])/c]}r.setExtent(u[0],u[1]),r.calcNiceExtent({splitNumber:o,fixMin:f,fixMax:h});var v=i.getExtent.call(r);f&&(u[0]=v[0]),h&&(u[1]=v[1]);var p=i.getInterval.call(r),d=u[0],g=u[1];if(f&&h)p=(g-d)/o;else if(f)for(g=u[0]+p*o;gu[0]&&isFinite(d)&&isFinite(u[0]);)p=Bf(p),d=u[1]-p*o;else{var y=r.getTicks().length-1;y>o&&(p=Bf(p));var m=p*o;g=Math.ceil(u[1]/p)*p,d=Lt(g-m),d<0&&u[0]>=0?(d=0,g=Lt(m)):g>0&&u[1]<=0&&(g=0,d=-Lt(m))}var _=(n[0].value-a[0].value)/s,S=(n[o].value-a[o].value)/s;i.setExtent.call(r,d+p*_,g+p*S),i.setInterval.call(r,p),(_||S)&&i.setNiceExtent.call(r,d+p,g-p)}var PR=(function(){function r(t,e,i){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=gv,this._initCartesian(t,e,i),this.model=t}return r.prototype.getRect=function(){return this._rect},r.prototype.update=function(t,e){var i=this._axesMap;this._updateScale(t,this.model);function n(o){var s,l=pt(o),u=l.length;if(u){for(var f=[],h=u-1;h>=0;h--){var c=+l[h],v=o[c],p=v.model,d=v.scale;hv(d)&&p.get("alignTicks")&&p.get("interval")==null?f.push(v):(ia(d,p),hv(d)&&(s=v))}f.length&&(s||(s=f.pop(),ia(s.scale,s.model)),w(f,function(g){ib(g.scale,g.model,s.scale)}))}}n(i.x),n(i.y);var a={};w(i.x,function(o){Ny(i,"y",o,a)}),w(i.y,function(o){Ny(i,"x",o,a)}),this.resize(this.model,e)},r.prototype.resize=function(t,e,i){var n=t.getBoxLayoutParams(),a=!i&&t.get("containLabel"),o=le(n,{width:e.getWidth(),height:e.getHeight()});this._rect=o;var s=this._axesList;l(),a&&(w(s,function(u){if(!u.model.get(["axisLabel","inside"])){var f=BP(u);if(f){var h=u.isHorizontal()?"height":"width",c=u.model.get(["axisLabel","margin"]);o[h]-=f[h]+c,u.position==="top"?o.y+=f.height+c:u.position==="left"&&(o.x+=f.width+c)}}}),l()),w(this._coordsList,function(u){u.calcAffineTransform()});function l(){w(s,function(u){var f=u.isHorizontal(),h=f?[0,o.width]:[0,o.height],c=u.inverse?1:0;u.setExtent(h[c],h[1-c]),IR(u,f?o.x:o.y)})}},r.prototype.getAxis=function(t,e){var i=this._axesMap[t];if(i!=null)return i[e||0]},r.prototype.getAxes=function(){return this._axesList.slice()},r.prototype.getCartesian=function(t,e){if(t!=null&&e!=null){var i="x"+t+"y"+e;return this._coordsMap[i]}X(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var n=0,a=this._coordsList;n0?"top":"bottom",a="center"):mo(n-li)?(o=i>0?"bottom":"top",a="center"):(o="middle",n>0&&n0?"right":"left":a=i>0?"left":"right"),{rotation:n,textAlign:a,textVerticalAlign:o}},r.makeAxisEventDataBase=function(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e},r.isLabelSilent=function(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)},r})(),Fy={axisLine:function(r,t,e,i){var n=t.get(["axisLine","show"]);if(n==="auto"&&r.handleAutoShown&&(n=r.handleAutoShown("axisLine")),!!n){var a=t.axis.getExtent(),o=i.transform,s=[a[0],0],l=[a[1],0],u=s[0]>l[0];o&&(Bt(s,s,o),Bt(l,l,o));var f=O({lineCap:"round"},t.getModel(["axisLine","lineStyle"]).getLineStyle()),h=new Kt({shape:{x1:s[0],y1:s[1],x2:l[0],y2:l[1]},style:f,strokeContainThreshold:r.strokeContainThreshold||5,silent:!0,z2:1});wo(h.shape,h.style.lineWidth),h.anid="line",e.add(h);var c=t.get(["axisLine","symbol"]);if(c!=null){var v=t.get(["axisLine","symbolSize"]);G(c)&&(c=[c,c]),(G(v)||yt(v))&&(v=[v,v]);var p=yu(t.get(["axisLine","symbolOffset"])||0,v),d=v[0],g=v[1];w([{rotate:r.rotation+Math.PI/2,offset:p[0],r:0},{rotate:r.rotation-Math.PI/2,offset:p[1],r:Math.sqrt((s[0]-l[0])*(s[0]-l[0])+(s[1]-l[1])*(s[1]-l[1]))}],function(y,m){if(c[m]!=="none"&&c[m]!=null){var _=te(c[m],-d/2,-g/2,d,g,f.stroke,!0),S=y.r+y.offset,b=u?l:s;_.attr({rotation:y.rotate,x:b[0]+S*Math.cos(r.rotation),y:b[1]-S*Math.sin(r.rotation),silent:!0,z2:11}),e.add(_)}})}}},axisTickLabel:function(r,t,e,i){var n=kR(e,i,t,r),a=BR(e,i,t,r);if(ER(t,a,n),OR(e,i,t,r.tickDirection),t.get(["axisLabel","hideOverlap"])){var o=TI(F(a,function(s){return{label:s,priority:s.z2,defaultAttr:{ignore:s.ignore}}}));AI(o)}},axisName:function(r,t,e,i){var n=zr(r.axisName,t.get("name"));if(n){var a=t.get("nameLocation"),o=r.nameDirection,s=t.getModel("nameTextStyle"),l=t.get("nameGap")||0,u=t.axis.getExtent(),f=u[0]>u[1]?-1:1,h=[a==="start"?u[0]-f*l:a==="end"?u[1]+f*l:(u[0]+u[1])/2,Gy(a)?r.labelOffset+o*l:0],c,v=t.get("nameRotate");v!=null&&(v=v*li/180);var p;Gy(a)?c=de.innerTextLayout(r.rotation,v!=null?v:r.rotation,o):(c=RR(r.rotation,a,v||0,u),p=r.axisNameAvailableWidth,p!=null&&(p=Math.abs(p/Math.sin(c.rotation)),!isFinite(p)&&(p=null)));var d=s.getFont(),g=t.get("nameTruncate",!0)||{},y=g.ellipsis,m=zr(r.nameTruncateMaxWidth,g.maxWidth,p),_=new ct({x:h[0],y:h[1],rotation:c.rotation,silent:de.isLabelSilent(t),style:Rt(s,{text:n,font:d,overflow:"truncate",width:m,ellipsis:y,fill:s.getTextColor()||t.get(["axisLine","lineStyle","color"]),align:s.get("align")||c.textAlign,verticalAlign:s.get("verticalAlign")||c.textVerticalAlign}),z2:1});if(mn({el:_,componentModel:t,itemName:n}),_.__fullText=n,_.anid="name",t.get("triggerEvent")){var S=de.makeAxisEventDataBase(t);S.targetType="axisName",S.name=n,ot(_).eventData=S}i.add(_),_.updateTransform(),e.add(_),_.decomposeTransform()}}};function RR(r,t,e,i){var n=ec(e-r),a,o,s=i[0]>i[1],l=t==="start"&&!s||t!=="start"&&s;return mo(n-li/2)?(o=l?"bottom":"top",a="center"):mo(n-li*1.5)?(o=l?"top":"bottom",a="center"):(o="middle",nli/2?a=l?"left":"right":a=l?"right":"left"),{rotation:n,textAlign:a,textVerticalAlign:o}}function ER(r,t,e){if(!Tx(r.axis)){var i=r.get(["axisLabel","showMinLabel"]),n=r.get(["axisLabel","showMaxLabel"]);t=t||[],e=e||[];var a=t[0],o=t[1],s=t[t.length-1],l=t[t.length-2],u=e[0],f=e[1],h=e[e.length-1],c=e[e.length-2];i===!1?(De(a),De(u)):Vy(a,o)&&(i?(De(o),De(f)):(De(a),De(u))),n===!1?(De(s),De(h)):Vy(l,s)&&(n?(De(l),De(c)):(De(s),De(h)))}}function De(r){r&&(r.ignore=!0)}function Vy(r,t){var e=r&&r.getBoundingRect().clone(),i=t&&t.getBoundingRect().clone();if(!(!e||!i)){var n=Fo([]);return mi(n,n,-r.rotation),e.applyTransform(Sr([],n,r.getLocalTransform())),i.applyTransform(Sr([],n,t.getLocalTransform())),e.intersect(i)}}function Gy(r){return r==="middle"||r==="center"}function nb(r,t,e,i,n){for(var a=[],o=[],s=[],l=0;l=0||r===t}function HR(r){var t=up(r);if(t){var e=t.axisPointerModel,i=t.axis.scale,n=e.option,a=e.get("status"),o=e.get("value");o!=null&&(o=i.parse(o));var s=mv(e);a==null&&(n.status=s?"show":"hide");var l=i.getExtent().slice();l[0]>l[1]&&l.reverse(),(o==null||o>l[1])&&(o=l[1]),o0&&!p.min?p.min=0:p.min!=null&&p.min<0&&!p.max&&(p.max=0);var d=l;p.color!=null&&(d=K({color:p.color},l));var g=J(q(p),{boundaryGap:e,splitNumber:i,scale:n,axisLine:a,axisTick:o,axisLabel:s,name:p.text,showName:u,nameLocation:"end",nameGap:h,nameTextStyle:d,triggerEvent:c},!1);if(G(f)){var y=g.name;g.name=f.replace("{value}",y!=null?y:"")}else j(f)&&(g.name=f(g.name,g));var m=new _t(g,null,this.ecModel);return Wt(m,qo.prototype),m.mainType="radar",m.componentIndex=this.componentIndex,m},this);this._indicatorModels=v},t.prototype.getIndicatorModels=function(){return this._indicatorModels},t.type="radar",t.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:J({lineStyle:{color:"#bbb"}},Na.axisLine),axisLabel:ks(Na.axisLabel,!1),axisTick:ks(Na.axisTick,!1),splitLine:ks(Na.splitLine,!0),splitArea:ks(Na.splitArea,!0),indicator:[]},t})(at),iE=["axisLine","axisTickLabel","axisName"],nE=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n){var a=this.group;a.removeAll(),this._buildAxes(e),this._buildSplitLineAndArea(e)},t.prototype._buildAxes=function(e){var i=e.coordinateSystem,n=i.getIndicatorAxes(),a=F(n,function(o){var s=o.model.get("showName")?o.name:"",l=new de(o.model,{axisName:s,position:[i.cx,i.cy],rotation:o.angle,labelDirection:-1,tickDirection:-1,nameDirection:1});return l});w(a,function(o){w(iE,o.add,o),this.group.add(o.getGroup())},this)},t.prototype._buildSplitLineAndArea=function(e){var i=e.coordinateSystem,n=i.getIndicatorAxes();if(!n.length)return;var a=e.get("shape"),o=e.getModel("splitLine"),s=e.getModel("splitArea"),l=o.getModel("lineStyle"),u=s.getModel("areaStyle"),f=o.get("show"),h=s.get("show"),c=l.get("color"),v=u.get("color"),p=z(c)?c:[c],d=z(v)?v:[v],g=[],y=[];function m(R,k,V){var B=V%k.length;return R[B]=R[B]||[],B}if(a==="circle")for(var _=n[0].getTicksCoords(),S=i.cx,b=i.cy,x=0;x<_.length;x++){if(f){var T=m(g,p,x);g[T].push(new wr({shape:{cx:S,cy:b,r:_[x].coord}}))}if(h&&x<_.length-1){var T=m(y,d,x);y[T].push(new ua({shape:{cx:S,cy:b,r0:_[x].coord,r:_[x+1].coord}}))}}else for(var C,A=F(n,function(R,k){var V=R.getTicksCoords();return C=C==null?V.length-1:Math.min(V.length-1,C),F(V,function(B){return i.coordToPoint(B.coord,k)})}),M=[],x=0;x<=C;x++){for(var D=[],L=0;L3?1.4:o>1?1.2:1.1,f=a>0?u:1/u;$f(this,"zoom","zoomOnMouseWheel",e,{scale:f,originX:s,originY:l,isAvailableBehavior:null})}if(n){var h=Math.abs(a),c=(a>0?1:-1)*(h>3?.4:h>1?.15:.05);$f(this,"scrollMove","moveOnMouseWheel",e,{scrollDelta:c,originX:s,originY:l,isAvailableBehavior:null})}}},t.prototype._pinchHandler=function(e){if(!Zy(this._zr,"globalPan")){var i=e.pinchScale>1?1.1:1/1.1;$f(this,"zoom",null,e,{scale:i,originX:e.pinchX,originY:e.pinchY,isAvailableBehavior:null})}},t})(Ge);function $f(r,t,e,i,n){r.pointerChecker&&r.pointerChecker(i,n.originX,n.originY)&&(Fr(i.event),ub(r,t,e,i,n))}function ub(r,t,e,i,n){n.isAvailableBehavior=W(nl,null,e,i),r.trigger(t,n)}function nl(r,t,e){var i=e[r];return!r||i&&(!G(i)||t.event[i+"Key"])}function fE(r,t,e){var i=r.target;i.x+=t,i.y+=e,i.dirty()}function hE(r,t,e,i){var n=r.target,a=r.zoomLimit,o=r.zoom=r.zoom||1;if(o*=t,a){var s=a.min||0,l=a.max||1/0;o=Math.max(Math.min(l,o),s)}var u=o/r.zoom;r.zoom=o,n.x-=(e-n.x)*(u-1),n.y-=(i-n.y)*(u-1),n.scaleX*=u,n.scaleY*=u,n.dirty()}var vE={axisPointer:1,tooltip:1,brush:1};function fb(r,t,e){var i=t.getComponentByElement(r.topTarget),n=i&&i.coordinateSystem;return i&&i!==e&&!vE.hasOwnProperty(i.mainType)&&n&&n.model!==e}function hb(r){if(G(r)){var t=new DOMParser;r=t.parseFromString(r,"text/xml")}var e=r;for(e.nodeType===9&&(e=e.firstChild);e.nodeName.toLowerCase()!=="svg"||e.nodeType!==1;)e=e.nextSibling;return e}var qf,Fl={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"},$y=pt(Fl),Vl={"alignment-baseline":"textBaseline","stop-color":"stopColor"},qy=pt(Vl),cE=(function(){function r(){this._defs={},this._root=null}return r.prototype.parse=function(t,e){e=e||{};var i=hb(t);this._defsUsePending=[];var n=new nt;this._root=n;var a=[],o=i.getAttribute("viewBox")||"",s=parseFloat(i.getAttribute("width")||e.width),l=parseFloat(i.getAttribute("height")||e.height);isNaN(s)&&(s=null),isNaN(l)&&(l=null),_e(i,n,null,!0,!1);for(var u=i.firstChild;u;)this._parseNode(u,n,a,null,!1,!1),u=u.nextSibling;gE(this._defs,this._defsUsePending),this._defsUsePending=[];var f,h;if(o){var c=Du(o);c.length>=4&&(f={x:parseFloat(c[0]||0),y:parseFloat(c[1]||0),width:parseFloat(c[2]),height:parseFloat(c[3])})}if(f&&s!=null&&l!=null&&(h=cb(f,{x:0,y:0,width:s,height:l}),!e.ignoreViewBox)){var v=n;n=new nt,n.add(v),v.scaleX=v.scaleY=h.scale,v.x=h.x,v.y=h.y}return!e.ignoreRootClip&&s!=null&&l!=null&&n.setClipPath(new vt({shape:{x:0,y:0,width:s,height:l}})),{root:n,width:s,height:l,viewBoxRect:f,viewBoxTransform:h,named:a}},r.prototype._parseNode=function(t,e,i,n,a,o){var s=t.nodeName.toLowerCase(),l,u=n;if(s==="defs"&&(a=!0),s==="text"&&(o=!0),s==="defs"||s==="switch")l=e;else{if(!a){var f=qf[s];if(f&&H(qf,s)){l=f.call(this,t,e);var h=t.getAttribute("name");if(h){var c={name:h,namedFrom:null,svgNodeTagLower:s,el:l};i.push(c),s==="g"&&(u=c)}else n&&i.push({name:n.name,namedFrom:n,svgNodeTagLower:s,el:l});e.add(l)}}var v=Ky[s];if(v&&H(Ky,s)){var p=v.call(this,t),d=t.getAttribute("id");d&&(this._defs[d]=p)}}if(l&&l.isGroup)for(var g=t.firstChild;g;)g.nodeType===1?this._parseNode(g,l,i,u,a,o):g.nodeType===3&&o&&this._parseText(g,l),g=g.nextSibling},r.prototype._parseText=function(t,e){var i=new So({style:{text:t.textContent},silent:!0,x:this._textX||0,y:this._textY||0});Le(e,i),_e(t,i,this._defsUsePending,!1,!1),pE(i,e);var n=i.style,a=n.fontSize;a&&a<9&&(n.fontSize=9,i.scaleX*=a/9,i.scaleY*=a/9);var o=(n.fontSize||n.fontFamily)&&[n.fontStyle,n.fontWeight,(n.fontSize||12)+"px",n.fontFamily||"sans-serif"].join(" ");n.font=o;var s=i.getBoundingRect();return this._textX+=s.width,e.add(i),i},r.internalField=(function(){qf={g:function(t,e){var i=new nt;return Le(e,i),_e(t,i,this._defsUsePending,!1,!1),i},rect:function(t,e){var i=new vt;return Le(e,i),_e(t,i,this._defsUsePending,!1,!1),i.setShape({x:parseFloat(t.getAttribute("x")||"0"),y:parseFloat(t.getAttribute("y")||"0"),width:parseFloat(t.getAttribute("width")||"0"),height:parseFloat(t.getAttribute("height")||"0")}),i.silent=!0,i},circle:function(t,e){var i=new wr;return Le(e,i),_e(t,i,this._defsUsePending,!1,!1),i.setShape({cx:parseFloat(t.getAttribute("cx")||"0"),cy:parseFloat(t.getAttribute("cy")||"0"),r:parseFloat(t.getAttribute("r")||"0")}),i.silent=!0,i},line:function(t,e){var i=new Kt;return Le(e,i),_e(t,i,this._defsUsePending,!1,!1),i.setShape({x1:parseFloat(t.getAttribute("x1")||"0"),y1:parseFloat(t.getAttribute("y1")||"0"),x2:parseFloat(t.getAttribute("x2")||"0"),y2:parseFloat(t.getAttribute("y2")||"0")}),i.silent=!0,i},ellipse:function(t,e){var i=new Wo;return Le(e,i),_e(t,i,this._defsUsePending,!1,!1),i.setShape({cx:parseFloat(t.getAttribute("cx")||"0"),cy:parseFloat(t.getAttribute("cy")||"0"),rx:parseFloat(t.getAttribute("rx")||"0"),ry:parseFloat(t.getAttribute("ry")||"0")}),i.silent=!0,i},polygon:function(t,e){var i=t.getAttribute("points"),n;i&&(n=Qy(i));var a=new ir({shape:{points:n||[]},silent:!0});return Le(e,a),_e(t,a,this._defsUsePending,!1,!1),a},polyline:function(t,e){var i=t.getAttribute("points"),n;i&&(n=Qy(i));var a=new Ce({shape:{points:n||[]},silent:!0});return Le(e,a),_e(t,a,this._defsUsePending,!1,!1),a},image:function(t,e){var i=new ye;return Le(e,i),_e(t,i,this._defsUsePending,!1,!1),i.setStyle({image:t.getAttribute("xlink:href")||t.getAttribute("href"),x:+t.getAttribute("x"),y:+t.getAttribute("y"),width:+t.getAttribute("width"),height:+t.getAttribute("height")}),i.silent=!0,i},text:function(t,e){var i=t.getAttribute("x")||"0",n=t.getAttribute("y")||"0",a=t.getAttribute("dx")||"0",o=t.getAttribute("dy")||"0";this._textX=parseFloat(i)+parseFloat(a),this._textY=parseFloat(n)+parseFloat(o);var s=new nt;return Le(e,s),_e(t,s,this._defsUsePending,!1,!0),s},tspan:function(t,e){var i=t.getAttribute("x"),n=t.getAttribute("y");i!=null&&(this._textX=parseFloat(i)),n!=null&&(this._textY=parseFloat(n));var a=t.getAttribute("dx")||"0",o=t.getAttribute("dy")||"0",s=new nt;return Le(e,s),_e(t,s,this._defsUsePending,!1,!0),this._textX+=parseFloat(a),this._textY+=parseFloat(o),s},path:function(t,e){var i=t.getAttribute("d")||"",n=m1(i);return Le(e,n),_e(t,n,this._defsUsePending,!1,!1),n.silent=!0,n}}})(),r})(),Ky={lineargradient:function(r){var t=parseInt(r.getAttribute("x1")||"0",10),e=parseInt(r.getAttribute("y1")||"0",10),i=parseInt(r.getAttribute("x2")||"10",10),n=parseInt(r.getAttribute("y2")||"0",10),a=new Uo(t,e,i,n);return Jy(r,a),jy(r,a),a},radialgradient:function(r){var t=parseInt(r.getAttribute("cx")||"0",10),e=parseInt(r.getAttribute("cy")||"0",10),i=parseInt(r.getAttribute("r")||"0",10),n=new pc(t,e,i);return Jy(r,n),jy(r,n),n}};function Jy(r,t){var e=r.getAttribute("gradientUnits");e==="userSpaceOnUse"&&(t.global=!0)}function jy(r,t){for(var e=r.firstChild;e;){if(e.nodeType===1&&e.nodeName.toLocaleLowerCase()==="stop"){var i=e.getAttribute("offset"),n=void 0;i&&i.indexOf("%")>0?n=parseInt(i,10)/100:i?n=parseFloat(i):n=0;var a={};vb(e,a,a);var o=a.stopColor||e.getAttribute("stop-color")||"#000000";t.colorStops.push({offset:n,color:o})}e=e.nextSibling}}function Le(r,t){r&&r.__inheritedStyle&&(t.__inheritedStyle||(t.__inheritedStyle={}),K(t.__inheritedStyle,r.__inheritedStyle))}function Qy(r){for(var t=Du(r),e=[],i=0;i0;a-=2){var o=i[a],s=i[a-1],l=Du(o);switch(n=n||xe(),s){case"translate":Vr(n,n,[parseFloat(l[0]),parseFloat(l[1]||"0")]);break;case"scale":Kv(n,n,[parseFloat(l[0]),parseFloat(l[1]||l[0])]);break;case"rotate":mi(n,n,-parseFloat(l[0])*Kf,[parseFloat(l[1]||"0"),parseFloat(l[2]||"0")]);break;case"skewX":var u=Math.tan(parseFloat(l[0])*Kf);Sr(n,[1,0,u,1,0,0],n);break;case"skewY":var f=Math.tan(parseFloat(l[0])*Kf);Sr(n,[1,f,0,1,0,0],n);break;case"matrix":n[0]=parseFloat(l[0]),n[1]=parseFloat(l[1]),n[2]=parseFloat(l[2]),n[3]=parseFloat(l[3]),n[4]=parseFloat(l[4]),n[5]=parseFloat(l[5]);break}}t.setLocalTransform(n)}}var em=/([^\s:;]+)\s*:\s*([^:;]+)/g;function vb(r,t,e){var i=r.getAttribute("style");if(i){em.lastIndex=0;for(var n;(n=em.exec(i))!=null;){var a=n[1],o=H(Fl,a)?Fl[a]:null;o&&(t[o]=n[2]);var s=H(Vl,a)?Vl[a]:null;s&&(e[s]=n[2])}}}function SE(r,t,e){for(var i=0;i<$y.length;i++){var n=$y[i],a=r.getAttribute(n);a!=null&&(t[Fl[n]]=a)}for(var i=0;i0,g={api:i,geo:l,mapOrGeoModel:t,data:s,isVisualEncodedByVisualMap:d,isGeo:o,transformInfoRaw:c};l.resourceType==="geoJSON"?this._buildGeoJSON(g):l.resourceType==="geoSVG"&&this._buildSVG(g),this._updateController(t,e,i),this._updateMapSelectHandler(t,u,i,n)},r.prototype._buildGeoJSON=function(t){var e=this._regionsGroupByName=U(),i=U(),n=this._regionsGroup,a=t.transformInfoRaw,o=t.mapOrGeoModel,s=t.data,l=t.geo.projection,u=l&&l.stream;function f(v,p){return p&&(v=p(v)),v&&[v[0]*a.scaleX+a.x,v[1]*a.scaleY+a.y]}function h(v){for(var p=[],d=!u&&l&&l.project,g=0;g=0)&&(c=n);var v=o?{normal:{align:"center",verticalAlign:"middle"}}:null;Xr(t,Zr(i),{labelFetcher:c,labelDataIndex:h,defaultText:e},v);var p=t.getTextContent();if(p&&(pb(p).ignore=p.ignore,t.textConfig&&o)){var d=t.getBoundingRect().clone();t.textConfig.layoutRect=d,t.textConfig.position=[(o[0]-d.x)/d.width*100+"%",(o[1]-d.y)/d.height*100+"%"]}t.disableLabelAnimation=!0}else t.removeTextContent(),t.removeTextConfig(),t.disableLabelAnimation=null}function om(r,t,e,i,n,a){r.data?r.data.setItemGraphicEl(a,t):ot(t).eventData={componentType:"geo",componentIndex:n.componentIndex,geoIndex:n.componentIndex,name:e,region:i&&i.option||{}}}function sm(r,t,e,i,n){r.data||mn({el:t,componentModel:n,itemName:e,itemTooltipOption:i.get("tooltip")})}function lm(r,t,e,i,n){t.highDownSilentOnTouch=!!n.get("selectedMode");var a=i.getModel("emphasis"),o=a.get("focus");return di(t,o,a.get("blurScope"),a.get("disabled")),r.isGeo&&QA(t,n,e),o}function um(r,t,e){var i=[],n;function a(){n=[]}function o(){n.length&&(i.push(n),n=[])}var s=t({polygonStart:a,polygonEnd:o,lineStart:a,lineEnd:o,point:function(l,u){isFinite(l)&&isFinite(u)&&n.push([l,u])},sphere:function(){}});return!e&&s.polygonStart(),w(r,function(l){s.lineStart();for(var u=0;u-1&&(n.style.stroke=n.style.fill,n.style.fill="#fff",n.style.lineWidth=2),n},t.type="series.map",t.dependencies=["geo"],t.layoutMode="box",t.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"},t})(Qt);function VE(r,t){var e={};return w(r,function(i){i.each(i.mapDimension("value"),function(n,a){var o="ec-"+i.getName(a);e[o]=e[o]||[],isNaN(n)||e[o].push(n)})}),r[0].map(r[0].mapDimension("value"),function(i,n){for(var a="ec-"+r[0].getName(n),o=0,s=1/0,l=-1/0,u=e[a].length,f=0;f1?(S.width=_,S.height=_/g):(S.height=_,S.width=_*g),S.y=m[1]-S.height/2,S.x=m[0]-S.width/2;else{var b=r.getBoxLayoutParams();b.aspect=g,S=le(b,{width:p,height:d})}this.setViewRect(S.x,S.y,S.width,S.height),this.setCenter(r.get("center"),t),this.setZoom(r.get("zoom"))}function YE(r,t){w(t.get("geoCoord"),function(e,i){r.addGeoCoord(i,e)})}var UE=(function(){function r(){this.dimensions=yb}return r.prototype.create=function(t,e){var i=[];function n(o){return{nameProperty:o.get("nameProperty"),aspectScale:o.get("aspectScale"),projection:o.get("projection")}}t.eachComponent("geo",function(o,s){var l=o.get("map"),u=new xv(l+s,l,O({nameMap:o.get("nameMap")},n(o)));u.zoomLimit=o.get("scaleLimit"),i.push(u),o.coordinateSystem=u,u.model=o,u.resize=cm,u.resize(o,e)}),t.eachSeries(function(o){var s=o.get("coordinateSystem");if(s==="geo"){var l=o.get("geoIndex")||0;o.coordinateSystem=i[l]}});var a={};return t.eachSeriesByType("map",function(o){if(!o.getHostGeoModel()){var s=o.getMapType();a[s]=a[s]||[],a[s].push(o)}}),w(a,function(o,s){var l=F(o,function(f){return f.get("nameMap")}),u=new xv(s,s,O({nameMap:e_(l)},n(o[0])));u.zoomLimit=zr.apply(null,F(o,function(f){return f.get("scaleLimit")})),i.push(u),u.resize=cm,u.resize(o[0],e),w(o,function(f){f.coordinateSystem=u,YE(u,f)})}),i},r.prototype.getFilledRegions=function(t,e,i,n){for(var a=(t||[]).slice(),o=U(),s=0;s=0;a--)i[a]==null&&(delete e[t[a]],t.pop())}function Jf(r,t){var e=r.visual,i=[];X(e)?ko(e,function(a){i.push(a)}):e!=null&&i.push(e);var n={color:1,symbol:1};!t&&i.length===1&&!n.hasOwnProperty(r.type)&&(i[1]=i[0]),_b(r,i)}function Bs(r){return{applyVisual:function(t,e,i){var n=this.mapValueToVisual(t);i("color",r(e("color"),n))},_normalizedToVisual:bv([0,1])}}function dm(r){var t=this.option.visual;return t[Math.round(Tt(r,[0,1],[0,t.length-1],!0))]||{}}function Fa(r){return function(t,e,i){i(r,this.mapValueToVisual(t))}}function ja(r){var t=this.option.visual;return t[this.option.loop&&r!==Gl?r%t.length:r]}function Ui(){return this.option.visual[0]}function bv(r){return{linear:function(t){return Tt(t,r,this.option.visual,!0)},category:ja,piecewise:function(t,e){var i=wv.call(this,e);return i==null&&(i=Tt(t,r,this.option.visual,!0)),i},fixed:Ui}}function wv(r){var t=this.option,e=t.pieceList;if(t.hasSpecialVisual){var i=Gt.findPieceIndex(r,e),n=e[i];if(n&&n.visual)return n.visual[this.type]}}function _b(r,t){return r.visual=t,r.type==="color"&&(r.parsedVisual=F(t,function(e){var i=oe(e);return i||[0,0,0,1]})),t}var ek={linear:function(r){return Tt(r,this.option.dataExtent,[0,1],!0)},piecewise:function(r){var t=this.option.pieceList,e=Gt.findPieceIndex(r,t,!0);if(e!=null)return Tt(e,[0,t.length-1],[0,1],!0)},category:function(r){var t=this.option.categories?this.option.categoryMap[r]:r;return t==null?Gl:t},fixed:Vt};function Ns(r,t,e){return r?t<=e:tak)return;var n=this._model.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]);n.behavior!=="none"&&this._dispatchExpand({axisExpandWindow:n.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(r){if(!(this._mouseDownPoint||!jf(this,"mousemove"))){var t=this._model,e=t.coordinateSystem.getSlidedAxisExpandWindow([r.offsetX,r.offsetY]),i=e.behavior;i==="jump"&&this._throttledDispatchExpand.debounceNextCall(t.get("axisExpandDebounce")),this._throttledDispatchExpand(i==="none"?null:{axisExpandWindow:e.axisExpandWindow,animation:i==="jump"?null:{duration:0}})}}};function jf(r,t){var e=r._model;return e.get("axisExpandable")&&e.get("axisExpandTriggerOn")===t}var lk=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(){r.prototype.init.apply(this,arguments),this.mergeOption({})},t.prototype.mergeOption=function(e){var i=this.option;e&&J(i,e,!0),this._initDimensions()},t.prototype.contains=function(e,i){var n=e.get("parallelIndex");return n!=null&&i.getComponent("parallel",n)===this},t.prototype.setAxisExpand=function(e){w(["axisExpandable","axisExpandCenter","axisExpandCount","axisExpandWidth","axisExpandWindow"],function(i){e.hasOwnProperty(i)&&(this.option[i]=e[i])},this)},t.prototype._initDimensions=function(){var e=this.dimensions=[],i=this.parallelAxisIndex=[],n=wt(this.ecModel.queryComponents({mainType:"parallelAxis"}),function(a){return(a.get("parallelIndex")||0)===this.componentIndex},this);w(n,function(a){e.push("dim"+a.get("dim")),i.push(a.componentIndex)})},t.type="parallel",t.dependencies=["parallelAxis"],t.layoutMode="box",t.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},t})(at),uk=(function(r){E(t,r);function t(e,i,n,a,o){var s=r.call(this,e,i,n)||this;return s.type=a||"value",s.axisIndex=o,s}return t.prototype.isHorizontal=function(){return this.coordinateSystem.getModel().get("layout")!=="horizontal"},t})(or);function Sn(r,t,e,i,n,a){r=r||0;var o=e[1]-e[0];if(n!=null&&(n=Nn(n,[0,o])),a!=null&&(a=Math.max(a,n!=null?n:0)),i==="all"){var s=Math.abs(t[1]-t[0]);s=Nn(s,[0,o]),n=a=Nn(s,[n,a]),i=0}t[0]=Nn(t[0],e),t[1]=Nn(t[1],e);var l=Qf(t,i);t[i]+=r;var u=n||0,f=e.slice();l.sign<0?f[0]+=u:f[1]-=u,t[i]=Nn(t[i],f);var h;return h=Qf(t,i),n!=null&&(h.sign!==l.sign||h.spana&&(t[1-i]=t[i]+h.sign*a),t}function Qf(r,t){var e=r[t]-r[1-t];return{span:Math.abs(e),sign:e>0?-1:e<0?1:t?-1:1}}function Nn(r,t){return Math.min(t[1]!=null?t[1]:1/0,Math.max(t[0]!=null?t[0]:-1/0,r))}var th=w,Sb=Math.min,xb=Math.max,gm=Math.floor,fk=Math.ceil,ym=Lt,hk=Math.PI,vk=(function(){function r(t,e,i){this.type="parallel",this._axesMap=U(),this._axesLayout={},this.dimensions=t.dimensions,this._model=t,this._init(t,e,i)}return r.prototype._init=function(t,e,i){var n=t.dimensions,a=t.parallelAxisIndex;th(n,function(o,s){var l=a[s],u=e.getComponent("parallelAxis",l),f=this._axesMap.set(o,new uk(o,Au(u),[0,0],u.get("type"),l)),h=f.type==="category";f.onBand=h&&u.get("boundaryGap"),f.inverse=u.get("inverse"),u.axis=f,f.model=u,f.coordinateSystem=u.coordinateSystem=this},this)},r.prototype.update=function(t,e){this._updateAxesFromSeries(this._model,t)},r.prototype.containPoint=function(t){var e=this._makeLayoutInfo(),i=e.axisBase,n=e.layoutBase,a=e.pixelDimIndex,o=t[1-a],s=t[a];return o>=i&&o<=i+e.axisLength&&s>=n&&s<=n+e.layoutLength},r.prototype.getModel=function(){return this._model},r.prototype._updateAxesFromSeries=function(t,e){e.eachSeries(function(i){if(t.contains(i,e)){var n=i.getData();th(this.dimensions,function(a){var o=this._axesMap.get(a);o.scale.unionExtentFromData(n,n.mapDimension(a)),ia(o.scale,o.model)},this)}},this)},r.prototype.resize=function(t,e){this._rect=le(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()}),this._layoutAxes()},r.prototype.getRect=function(){return this._rect},r.prototype._makeLayoutInfo=function(){var t=this._model,e=this._rect,i=["x","y"],n=["width","height"],a=t.get("layout"),o=a==="horizontal"?0:1,s=e[n[o]],l=[0,s],u=this.dimensions.length,f=zs(t.get("axisExpandWidth"),l),h=zs(t.get("axisExpandCount")||0,[0,u]),c=t.get("axisExpandable")&&u>3&&u>h&&h>1&&f>0&&s>0,v=t.get("axisExpandWindow"),p;if(v)p=zs(v[1]-v[0],l),v[1]=v[0]+p;else{p=zs(f*(h-1),l);var d=t.get("axisExpandCenter")||gm(u/2);v=[f*d-p/2],v[1]=v[0]+p}var g=(s-p)/(u-h);g<3&&(g=0);var y=[gm(ym(v[0]/f,1))+1,fk(ym(v[1]/f,1))-1],m=g/f*v[0];return{layout:a,pixelDimIndex:o,layoutBase:e[i[o]],layoutLength:s,axisBase:e[i[1-o]],axisLength:e[n[1-o]],axisExpandable:c,axisExpandWidth:f,axisCollapseWidth:g,axisExpandWindow:v,axisCount:u,winInnerIndices:y,axisExpandWindow0Pos:m}},r.prototype._layoutAxes=function(){var t=this._rect,e=this._axesMap,i=this.dimensions,n=this._makeLayoutInfo(),a=n.layout;e.each(function(o){var s=[0,n.axisLength],l=o.inverse?1:0;o.setExtent(s[l],s[1-l])}),th(i,function(o,s){var l=(n.axisExpandable?pk:ck)(s,n),u={horizontal:{x:l.position,y:n.axisLength},vertical:{x:0,y:l.position}},f={horizontal:hk/2,vertical:0},h=[u[a].x+t.x,u[a].y+t.y],c=f[a],v=xe();mi(v,v,c),Vr(v,v,h),this._axesLayout[o]={position:h,rotation:c,transform:v,axisNameAvailableWidth:l.axisNameAvailableWidth,axisLabelShow:l.axisLabelShow,nameTruncateMaxWidth:l.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},r.prototype.getAxis=function(t){return this._axesMap.get(t)},r.prototype.dataToPoint=function(t,e){return this.axisCoordToPoint(this._axesMap.get(e).dataToCoord(t),e)},r.prototype.eachActiveState=function(t,e,i,n){i==null&&(i=0),n==null&&(n=t.count());var a=this._axesMap,o=this.dimensions,s=[],l=[];w(o,function(g){s.push(t.mapDimension(g)),l.push(a.get(g).model)});for(var u=this.hasAxisBrushed(),f=i;fa*(1-h[0])?(u="jump",l=s-a*(1-h[2])):(l=s-a*h[1])>=0&&(l=s-a*(1-h[1]))<=0&&(l=0),l*=e.axisExpandWidth/f,l?Sn(l,n,o,"all"):u="none";else{var v=n[1]-n[0],p=o[1]*s/v;n=[xb(0,p-v/2)],n[1]=Sb(o[1],n[0]+v),n[0]=n[1]-v}return{axisExpandWindow:n,behavior:u}},r})();function zs(r,t){return Sb(xb(r,t[0]),t[1])}function ck(r,t){var e=t.layoutLength/(t.axisCount-1);return{position:e*r,axisNameAvailableWidth:e,axisLabelShow:!0}}function pk(r,t){var e=t.layoutLength,i=t.axisExpandWidth,n=t.axisCount,a=t.axisCollapseWidth,o=t.winInnerIndices,s,l=a,u=!1,f;return r=0;n--)gr(i[n])},t.prototype.getActiveState=function(e){var i=this.activeIntervals;if(!i.length)return"normal";if(e==null||isNaN(+e))return"inactive";if(i.length===1){var n=i[0];if(n[0]<=e&&e<=n[1])return"active"}else for(var a=0,o=i.length;a_k}function Db(r){var t=r.length-1;return t<0&&(t=0),[r[0],r[t]]}function Lb(r,t,e,i){var n=new nt;return n.add(new vt({name:"main",style:dp(e),silent:!0,draggable:!0,cursor:"move",drift:ft(Sm,r,t,n,["n","s","w","e"]),ondragend:ft(dn,t,{isEnd:!0})})),w(i,function(a){n.add(new vt({name:a.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:ft(Sm,r,t,n,a),ondragend:ft(dn,t,{isEnd:!0})}))}),n}function Pb(r,t,e,i){var n=i.brushStyle.lineWidth||0,a=na(n,Sk),o=e[0][0],s=e[1][0],l=o-n/2,u=s-n/2,f=e[0][1],h=e[1][1],c=f-a+n/2,v=h-a+n/2,p=f-o,d=h-s,g=p+n,y=d+n;Lr(r,t,"main",o,s,p,d),i.transformable&&(Lr(r,t,"w",l,u,a,y),Lr(r,t,"e",c,u,a,y),Lr(r,t,"n",l,u,g,a),Lr(r,t,"s",l,v,g,a),Lr(r,t,"nw",l,u,a,a),Lr(r,t,"ne",c,u,a,a),Lr(r,t,"sw",l,v,a,a),Lr(r,t,"se",c,v,a,a))}function Av(r,t){var e=t.__brushOption,i=e.transformable,n=t.childAt(0);n.useStyle(dp(e)),n.attr({silent:!i,cursor:i?"move":"default"}),w([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],function(a){var o=t.childOfName(a.join("")),s=a.length===1?Mv(r,a[0]):Ak(r,a);o&&o.attr({silent:!i,invisible:!i,cursor:i?bk[s]+"-resize":null})})}function Lr(r,t,e,i,n,a,o){var s=t.childOfName(e);s&&s.setShape(Dk(gp(r,t,[[i,n],[i+a,n+o]])))}function dp(r){return K({strokeNoScale:!0},r.brushStyle)}function Ib(r,t,e,i){var n=[Oo(r,e),Oo(t,i)],a=[na(r,e),na(t,i)];return[[n[0],a[0]],[n[1],a[1]]]}function Ck(r){return vi(r.group)}function Mv(r,t){var e={w:"left",e:"right",n:"top",s:"bottom"},i={left:"w",right:"e",top:"n",bottom:"s"},n=au(e[t],Ck(r));return i[n]}function Ak(r,t){var e=[Mv(r,t[0]),Mv(r,t[1])];return(e[0]==="e"||e[0]==="w")&&e.reverse(),e.join("")}function Sm(r,t,e,i,n,a){var o=e.__brushOption,s=r.toRectRange(o.range),l=Rb(t,n,a);w(i,function(u){var f=xk[u];s[f[0]][f[1]]+=l[f[0]]}),o.range=r.fromRectRange(Ib(s[0][0],s[1][0],s[0][1],s[1][1])),vp(t,e),dn(t,{isEnd:!1})}function Mk(r,t,e,i){var n=t.__brushOption.range,a=Rb(r,e,i);w(n,function(o){o[0]+=a[0],o[1]+=a[1]}),vp(r,t),dn(r,{isEnd:!1})}function Rb(r,t,e){var i=r.group,n=i.transformCoordToLocal(t,e),a=i.transformCoordToLocal(0,0);return[n[0]-a[0],n[1]-a[1]]}function gp(r,t,e){var i=Mb(r,t);return i&&i!==pn?i.clipPath(e,r._transform):q(e)}function Dk(r){var t=Oo(r[0][0],r[1][0]),e=Oo(r[0][1],r[1][1]),i=na(r[0][0],r[1][0]),n=na(r[0][1],r[1][1]);return{x:t,y:e,width:i-t,height:n-e}}function Lk(r,t,e){if(!(!r._brushType||Ik(r,t.offsetX,t.offsetY))){var i=r._zr,n=r._covers,a=pp(r,t,e);if(!r._dragging)for(var o=0;oi.getWidth()||e<0||e>i.getHeight()}var Lu={lineX:wm(0),lineY:wm(1),rect:{createCover:function(r,t){function e(i){return i}return Lb({toRectRange:e,fromRectRange:e},r,t,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(r){var t=Db(r);return Ib(t[1][0],t[1][1],t[0][0],t[0][1])},updateCoverShape:function(r,t,e,i){Pb(r,t,e,i)},updateCommon:Av,contain:Lv},polygon:{createCover:function(r,t){var e=new nt;return e.add(new Ce({name:"main",style:dp(t),silent:!0})),e},getCreatingRange:function(r){return r},endCreating:function(r,t){t.remove(t.childAt(0)),t.add(new ir({name:"main",draggable:!0,drift:ft(Mk,r,t),ondragend:ft(dn,r,{isEnd:!0})}))},updateCoverShape:function(r,t,e,i){t.childAt(0).setShape({points:gp(r,t,e)})},updateCommon:Av,contain:Lv}};function wm(r){return{createCover:function(t,e){return Lb({toRectRange:function(i){var n=[i,[0,100]];return r&&n.reverse(),n},fromRectRange:function(i){return i[r]}},t,e,[[["w"],["e"]],[["n"],["s"]]][r])},getCreatingRange:function(t){var e=Db(t),i=Oo(e[0][r],e[1][r]),n=na(e[0][r],e[1][r]);return[i,n]},updateCoverShape:function(t,e,i,n){var a,o=Mb(t,e);if(o!==pn&&o.getLinearBrushOtherExtent)a=o.getLinearBrushOtherExtent(r);else{var s=t._zr;a=[0,[s.getWidth(),s.getHeight()][1-r]]}var l=[i,a];r&&l.reverse(),Pb(t,e,l,n)},updateCommon:Av,contain:Lv}}function kb(r){return r=yp(r),function(t){return Sc(t,r)}}function Ob(r,t){return r=yp(r),function(e){var i=t!=null?t:e,n=i?r.width:r.height,a=i?r.x:r.y;return[a,a+(n||0)]}}function Bb(r,t,e){var i=yp(r);return function(n,a){return i.contain(a[0],a[1])&&!fb(n,t,e)}}function yp(r){return st.create(r)}var Rk=["axisLine","axisTickLabel","axisName"],Ek=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(e,i){r.prototype.init.apply(this,arguments),(this._brushController=new bb(i.getZr())).on("brush",W(this._onBrush,this))},t.prototype.render=function(e,i,n,a){if(!kk(e,i,a)){this.axisModel=e,this.api=n,this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new nt,this.group.add(this._axisGroup),!!e.get("show")){var s=Bk(e,i),l=s.coordinateSystem,u=e.getAreaSelectStyle(),f=u.width,h=e.axis.dim,c=l.getAxisLayout(h),v=O({strokeContainThreshold:f},c),p=new de(e,v);w(Rk,p.add,p),this._axisGroup.add(p.getGroup()),this._refreshBrushController(v,u,e,s,f,n),ou(o,this._axisGroup,e)}}},t.prototype._refreshBrushController=function(e,i,n,a,o,s){var l=n.axis.getExtent(),u=l[1]-l[0],f=Math.min(30,Math.abs(u)*.1),h=st.create({x:l[0],y:-o/2,width:u,height:o});h.x-=f,h.width+=2*f,this._brushController.mount({enableGlobalPan:!0,rotation:e.rotation,x:e.position[0],y:e.position[1]}).setPanels([{panelId:"pl",clipPath:kb(h),isTargetByCursor:Bb(h,s,a),getLinearBrushOtherExtent:Ob(h,0)}]).enableBrush({brushType:"lineX",brushStyle:i,removeOnClick:!0}).updateCovers(Ok(n))},t.prototype._onBrush=function(e){var i=e.areas,n=this.axisModel,a=n.axis,o=F(i,function(s){return[a.coordToData(s.range[0],!0),a.coordToData(s.range[1],!0)]});(!n.option.realtime===e.isEnd||e.removeOnClick)&&this.api.dispatchAction({type:"axisAreaSelect",parallelAxisId:n.id,intervals:o})},t.prototype.dispose=function(){this._brushController.dispose()},t.type="parallelAxis",t})(Ct);function kk(r,t,e){return e&&e.type==="axisAreaSelect"&&t.findComponents({mainType:"parallelAxis",query:e})[0]===r}function Ok(r){var t=r.axis;return F(r.activeIntervals,function(e){return{brushType:"lineX",panelId:"pl",range:[t.dataToCoord(e[0],!0),t.dataToCoord(e[1],!0)]}})}function Bk(r,t){return t.getComponent("parallel",r.get("parallelIndex"))}var Nk={type:"axisAreaSelect",event:"axisAreaSelected"};function zk(r){r.registerAction(Nk,function(t,e){e.eachComponent({mainType:"parallelAxis",query:t},function(i){i.axis.model.setActiveIntervals(t.intervals)})}),r.registerAction("parallelAxisExpand",function(t,e){e.eachComponent({mainType:"parallel",query:t},function(i){i.setAxisExpand(t)})})}var Fk={type:"value",areaSelectStyle:{width:20,borderWidth:1,borderColor:"rgba(160,197,232)",color:"rgba(160,197,232)",opacity:.3},realtime:!0,z:10};function Vk(r){r.registerComponentView(ok),r.registerComponentModel(lk),r.registerCoordinateSystem("parallel",gk),r.registerPreprocessor(rk),r.registerComponentModel(Tv),r.registerComponentView(Ek),Ro(r,"parallel",Tv,Fk),zk(r)}var Gk=["itemStyle","borderWidth"],Tm=[{xy:"x",wh:"width",index:0,posDesc:["left","right"]},{xy:"y",wh:"height",index:1,posDesc:["top","bottom"]}],eh=new wr,Hk=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n){var a=this.group,o=e.getData(),s=this._data,l=e.coordinateSystem,u=l.getBaseAxis(),f=u.isHorizontal(),h=l.master.getRect(),c={ecSize:{width:n.getWidth(),height:n.getHeight()},seriesModel:e,coordSys:l,coordSysExtent:[[h.x,h.x+h.width],[h.y,h.y+h.height]],isHorizontal:f,valueDim:Tm[+f],categoryDim:Tm[1-+f]};o.diff(s).add(function(p){if(o.hasValue(p)){var d=Am(o,p),g=Cm(o,p,d,c),y=Mm(o,c,g);o.setItemGraphicEl(p,y),a.add(y),Lm(y,c,g)}}).update(function(p,d){var g=s.getItemGraphicEl(d);if(!o.hasValue(p)){a.remove(g);return}var y=Am(o,p),m=Cm(o,p,y,c),_=Hb(o,m);g&&_!==g.__pictorialShapeStr&&(a.remove(g),o.setItemGraphicEl(p,null),g=null),g?qk(g,c,m):g=Mm(o,c,m,!0),o.setItemGraphicEl(p,g),g.__pictorialSymbolMeta=m,a.add(g),Lm(g,c,m)}).remove(function(p){var d=s.getItemGraphicEl(p);d&&Dm(s,p,d.__pictorialSymbolMeta.animationModel,d)}).execute();var v=e.get("clip",!0)?Yx(e.coordinateSystem,!1,e):null;return v?a.setClipPath(v):a.removeClipPath(),this._data=o,this.group},t.prototype.remove=function(e,i){var n=this.group,a=this._data;e.get("animation")?a&&a.eachItemGraphicEl(function(o){Dm(a,ot(o).dataIndex,e,o)}):n.removeAll()},t.type="pictorialBar",t})(Nt);function Cm(r,t,e,i){var n=r.getItemLayout(t),a=e.get("symbolRepeat"),o=e.get("symbolClip"),s=e.get("symbolPosition")||"start",l=e.get("symbolRotate"),u=(l||0)*Math.PI/180||0,f=e.get("symbolPatternSize")||2,h=e.isAnimationEnabled(),c={dataIndex:t,layout:n,itemModel:e,symbolType:r.getItemVisual(t,"symbol")||"circle",style:r.getItemVisual(t,"style"),symbolClip:o,symbolRepeat:a,symbolRepeatDirection:e.get("symbolRepeatDirection"),symbolPatternSize:f,rotation:u,animationModel:h?e:null,hoverScale:h&&e.get(["emphasis","scale"]),z2:e.getShallow("z",!0)||0};Wk(e,a,n,i,c),Yk(r,t,n,a,o,c.boundingLength,c.pxSign,f,i,c),Uk(e,c.symbolScale,u,i,c);var v=c.symbolSize,p=yu(e.get("symbolOffset"),v);return Xk(e,v,n,a,o,p,s,c.valueLineWidth,c.boundingLength,c.repeatCutLength,i,c),c}function Wk(r,t,e,i,n){var a=i.valueDim,o=r.get("symbolBoundingData"),s=i.coordSys.getOtherAxis(i.coordSys.getBaseAxis()),l=s.toGlobalCoord(s.dataToCoord(0)),u=1-+(e[a.wh]<=0),f;if(z(o)){var h=[rh(s,o[0])-l,rh(s,o[1])-l];h[1]=0?1:-1:f>0?1:-1}function rh(r,t){return r.toGlobalCoord(r.dataToCoord(r.scale.parse(t)))}function Yk(r,t,e,i,n,a,o,s,l,u){var f=l.valueDim,h=l.categoryDim,c=Math.abs(e[h.wh]),v=r.getItemVisual(t,"symbolSize"),p;z(v)?p=v.slice():v==null?p=["100%","100%"]:p=[v,v],p[h.index]=Q(p[h.index],c),p[f.index]=Q(p[f.index],i?c:Math.abs(a)),u.symbolSize=p;var d=u.symbolScale=[p[0]/s,p[1]/s];d[f.index]*=(l.isHorizontal?-1:1)*o}function Uk(r,t,e,i,n){var a=r.get(Gk)||0;a&&(eh.attr({scaleX:t[0],scaleY:t[1],rotation:e}),eh.updateTransform(),a/=eh.getLineScale(),a*=t[i.valueDim.index]),n.valueLineWidth=a||0}function Xk(r,t,e,i,n,a,o,s,l,u,f,h){var c=f.categoryDim,v=f.valueDim,p=h.pxSign,d=Math.max(t[v.index]+s,0),g=d;if(i){var y=Math.abs(l),m=zr(r.get("symbolMargin"),"15%")+"",_=!1;m.lastIndexOf("!")===m.length-1&&(_=!0,m=m.slice(0,m.length-1));var S=Q(m,t[v.index]),b=Math.max(d+S*2,0),x=_?0:S*2,T=ic(i),C=T?i:Pm((y+x)/b),A=y-C*d;S=A/2/(_?C:Math.max(C-1,1)),b=d+S*2,x=_?0:S*2,!T&&i!=="fixed"&&(C=u?Pm((Math.abs(u)+x)/b):0),g=C*b-x,h.repeatTimes=C,h.symbolMargin=S}var M=p*(g/2),D=h.pathPosition=[];D[c.index]=e[c.wh]/2,D[v.index]=o==="start"?M:o==="end"?l-M:l/2,a&&(D[0]+=a[0],D[1]+=a[1]);var L=h.bundlePosition=[];L[c.index]=e[c.xy],L[v.index]=e[v.xy];var P=h.barRectShape=O({},e);P[v.wh]=p*Math.max(Math.abs(e[v.wh]),Math.abs(D[v.index]+M)),P[c.wh]=e[c.wh];var I=h.clipShape={};I[c.xy]=-e[c.xy],I[c.wh]=f.ecSize[c.wh],I[v.xy]=0,I[v.wh]=e[v.wh]}function Nb(r){var t=r.symbolPatternSize,e=te(r.symbolType,-t/2,-t/2,t,t);return e.attr({culling:!0}),e.type!=="image"&&e.setStyle({strokeNoScale:!0}),e}function zb(r,t,e,i){var n=r.__pictorialBundle,a=e.symbolSize,o=e.valueLineWidth,s=e.pathPosition,l=t.valueDim,u=e.repeatTimes||0,f=0,h=a[t.valueDim.index]+o+e.symbolMargin*2;for(mp(r,function(d){d.__pictorialAnimationIndex=f,d.__pictorialRepeatTimes=u,f0:y<0)&&(m=u-1-d),g[l.index]=h*(m-u/2+.5)+s[l.index],{x:g[0],y:g[1],scaleX:e.symbolScale[0],scaleY:e.symbolScale[1],rotation:e.rotation}}}function Fb(r,t,e,i){var n=r.__pictorialBundle,a=r.__pictorialMainPath;a?Jn(a,null,{x:e.pathPosition[0],y:e.pathPosition[1],scaleX:e.symbolScale[0],scaleY:e.symbolScale[1],rotation:e.rotation},e,i):(a=r.__pictorialMainPath=Nb(e),n.add(a),Jn(a,{x:e.pathPosition[0],y:e.pathPosition[1],scaleX:0,scaleY:0,rotation:e.rotation},{scaleX:e.symbolScale[0],scaleY:e.symbolScale[1]},e,i))}function Vb(r,t,e){var i=O({},t.barRectShape),n=r.__pictorialBarRect;n?Jn(n,null,{shape:i},t,e):(n=r.__pictorialBarRect=new vt({z2:2,shape:i,silent:!0,style:{stroke:"transparent",fill:"transparent",lineWidth:0}}),n.disableMorphing=!0,r.add(n))}function Gb(r,t,e,i){if(e.symbolClip){var n=r.__pictorialClipPath,a=O({},e.clipShape),o=t.valueDim,s=e.animationModel,l=e.dataIndex;if(n)Mt(n,{shape:a},s,l);else{a[o.wh]=0,n=new vt({shape:a}),r.__pictorialBundle.setClipPath(n),r.__pictorialClipPath=n;var u={};u[o.wh]=e.clipShape[o.wh],ha[i?"updateProps":"initProps"](n,{shape:u},s,l)}}}function Am(r,t){var e=r.getItemModel(t);return e.getAnimationDelayParams=Zk,e.isAnimationEnabled=$k,e}function Zk(r){return{index:r.__pictorialAnimationIndex,count:r.__pictorialRepeatTimes}}function $k(){return this.parentModel.isAnimationEnabled()&&!!this.getShallow("animation")}function Mm(r,t,e,i){var n=new nt,a=new nt;return n.add(a),n.__pictorialBundle=a,a.x=e.bundlePosition[0],a.y=e.bundlePosition[1],e.symbolRepeat?zb(n,t,e):Fb(n,t,e),Vb(n,e,i),Gb(n,t,e,i),n.__pictorialShapeStr=Hb(r,e),n.__pictorialSymbolMeta=e,n}function qk(r,t,e){var i=e.animationModel,n=e.dataIndex,a=r.__pictorialBundle;Mt(a,{x:e.bundlePosition[0],y:e.bundlePosition[1]},i,n),e.symbolRepeat?zb(r,t,e,!0):Fb(r,t,e,!0),Vb(r,e,!0),Gb(r,t,e,!0)}function Dm(r,t,e,i){var n=i.__pictorialBarRect;n&&n.removeTextContent();var a=[];mp(i,function(o){a.push(o)}),i.__pictorialMainPath&&a.push(i.__pictorialMainPath),i.__pictorialClipPath&&(e=null),w(a,function(o){xo(o,{scaleX:0,scaleY:0},e,t,function(){i.parent&&i.parent.remove(i)})}),r.setItemGraphicEl(t,null)}function Hb(r,t){return[r.getItemVisual(t.dataIndex,"symbol")||"none",!!t.symbolRepeat,!!t.symbolClip].join(":")}function mp(r,t,e){w(r.__pictorialBundle.children(),function(i){i!==r.__pictorialBarRect&&t.call(e,i)})}function Jn(r,t,e,i,n,a){t&&r.attr(t),i.symbolClip&&!n?e&&r.attr(e):e&&ha[n?"updateProps":"initProps"](r,e,i.animationModel,i.dataIndex,a)}function Lm(r,t,e){var i=e.dataIndex,n=e.itemModel,a=n.getModel("emphasis"),o=a.getModel("itemStyle").getItemStyle(),s=n.getModel(["blur","itemStyle"]).getItemStyle(),l=n.getModel(["select","itemStyle"]).getItemStyle(),u=n.getShallow("cursor"),f=a.get("focus"),h=a.get("blurScope"),c=a.get("scale");mp(r,function(d){if(d instanceof ye){var g=d.style;d.useStyle(O({image:g.image,x:g.x,y:g.y,width:g.width,height:g.height},e.style))}else d.useStyle(e.style);var y=d.ensureState("emphasis");y.style=o,c&&(y.scaleX=d.scaleX*1.1,y.scaleY=d.scaleY*1.1),d.ensureState("blur").style=s,d.ensureState("select").style=l,u&&(d.cursor=u),d.z2=e.z2});var v=t.valueDim.posDesc[+(e.boundingLength>0)],p=r.__pictorialBarRect;p.ignoreClip=!0,Xr(p,Zr(n),{labelFetcher:t.seriesModel,labelDataIndex:i,defaultText:Mu(t.seriesModel.getData(),i),inheritColor:e.style.fill,defaultOpacity:e.style.opacity,defaultOutsidePosition:v}),di(r,f,h,a.get("disabled"))}function Pm(r){var t=Math.round(r);return Math.abs(r-t)<1e-4?t:Math.ceil(r)}var Kk=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e.defaultSymbol="roundRect",e}return t.prototype.getInitialData=function(e){return e.stack=null,r.prototype.getInitialData.apply(this,arguments)},t.type="series.pictorialBar",t.dependencies=["grid"],t.defaultOption=_i(Io.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"}}}),t})(Io);function Jk(r){r.registerChartView(Hk),r.registerSeriesModel(Kk),r.registerLayout(r.PRIORITY.VISUAL.LAYOUT,ft(gx,"pictorialBar")),r.registerLayout(r.PRIORITY.VISUAL.PROGRESSIVE_LAYOUT,yx("pictorialBar"))}function jk(r,t,e,i){return r&&(r.legacy||r.legacy!==!1&&!e&&!i&&t!=="tspan"&&(t==="text"||H(r,"text")))}function Qk(r,t,e){var i=r,n,a,o;if(t==="text")o=i;else{o={},H(i,"text")&&(o.text=i.text),H(i,"rich")&&(o.rich=i.rich),H(i,"textFill")&&(o.fill=i.textFill),H(i,"textStroke")&&(o.stroke=i.textStroke),H(i,"fontFamily")&&(o.fontFamily=i.fontFamily),H(i,"fontSize")&&(o.fontSize=i.fontSize),H(i,"fontStyle")&&(o.fontStyle=i.fontStyle),H(i,"fontWeight")&&(o.fontWeight=i.fontWeight),a={type:"text",style:o,silent:!0},n={};var s=H(i,"textPosition");e?n.position=s?i.textPosition:"inside":s&&(n.position=i.textPosition),H(i,"textPosition")&&(n.position=i.textPosition),H(i,"textOffset")&&(n.offset=i.textOffset),H(i,"textRotation")&&(n.rotation=i.textRotation),H(i,"textDistance")&&(n.distance=i.textDistance)}return Im(o,r),w(o.rich,function(l){Im(l,l)}),{textConfig:n,textContent:a}}function Im(r,t){t&&(t.font=t.textFont||t.font,H(t,"textStrokeWidth")&&(r.lineWidth=t.textStrokeWidth),H(t,"textAlign")&&(r.align=t.textAlign),H(t,"textVerticalAlign")&&(r.verticalAlign=t.textVerticalAlign),H(t,"textLineHeight")&&(r.lineHeight=t.textLineHeight),H(t,"textWidth")&&(r.width=t.textWidth),H(t,"textHeight")&&(r.height=t.textHeight),H(t,"textBackgroundColor")&&(r.backgroundColor=t.textBackgroundColor),H(t,"textPadding")&&(r.padding=t.textPadding),H(t,"textBorderColor")&&(r.borderColor=t.textBorderColor),H(t,"textBorderWidth")&&(r.borderWidth=t.textBorderWidth),H(t,"textBorderRadius")&&(r.borderRadius=t.textBorderRadius),H(t,"textBoxShadowColor")&&(r.shadowColor=t.textBoxShadowColor),H(t,"textBoxShadowBlur")&&(r.shadowBlur=t.textBoxShadowBlur),H(t,"textBoxShadowOffsetX")&&(r.shadowOffsetX=t.textBoxShadowOffsetX),H(t,"textBoxShadowOffsetY")&&(r.shadowOffsetY=t.textBoxShadowOffsetY))}function mz(r,t,e){var i=r;i.textPosition=i.textPosition||e.position||"inside",e.offset!=null&&(i.textOffset=e.offset),e.rotation!=null&&(i.textRotation=e.rotation),e.distance!=null&&(i.textDistance=e.distance);var n=i.textPosition.indexOf("inside")>=0,a=r.fill||"#000";Rm(i,t);var o=i.textFill==null;return n?o&&(i.textFill=e.insideFill||"#fff",!i.textStroke&&e.insideStroke&&(i.textStroke=e.insideStroke),!i.textStroke&&(i.textStroke=a),i.textStrokeWidth==null&&(i.textStrokeWidth=2)):(o&&(i.textFill=r.fill||e.outsideFill||"#000"),!i.textStroke&&e.outsideStroke&&(i.textStroke=e.outsideStroke)),i.text=t.text,i.rich=t.rich,w(t.rich,function(s){Rm(s,s)}),i}function Rm(r,t){t&&(H(t,"fill")&&(r.textFill=t.fill),H(t,"stroke")&&(r.textStroke=t.fill),H(t,"lineWidth")&&(r.textStrokeWidth=t.lineWidth),H(t,"font")&&(r.font=t.font),H(t,"fontStyle")&&(r.fontStyle=t.fontStyle),H(t,"fontWeight")&&(r.fontWeight=t.fontWeight),H(t,"fontSize")&&(r.fontSize=t.fontSize),H(t,"fontFamily")&&(r.fontFamily=t.fontFamily),H(t,"align")&&(r.textAlign=t.align),H(t,"verticalAlign")&&(r.textVerticalAlign=t.verticalAlign),H(t,"lineHeight")&&(r.textLineHeight=t.lineHeight),H(t,"width")&&(r.textWidth=t.width),H(t,"height")&&(r.textHeight=t.height),H(t,"backgroundColor")&&(r.textBackgroundColor=t.backgroundColor),H(t,"padding")&&(r.textPadding=t.padding),H(t,"borderColor")&&(r.textBorderColor=t.borderColor),H(t,"borderWidth")&&(r.textBorderWidth=t.borderWidth),H(t,"borderRadius")&&(r.textBorderRadius=t.borderRadius),H(t,"shadowColor")&&(r.textBoxShadowColor=t.shadowColor),H(t,"shadowBlur")&&(r.textBoxShadowBlur=t.shadowBlur),H(t,"shadowOffsetX")&&(r.textBoxShadowOffsetX=t.shadowOffsetX),H(t,"shadowOffsetY")&&(r.textBoxShadowOffsetY=t.shadowOffsetY),H(t,"textShadowColor")&&(r.textShadowColor=t.textShadowColor),H(t,"textShadowBlur")&&(r.textShadowBlur=t.textShadowBlur),H(t,"textShadowOffsetX")&&(r.textShadowOffsetX=t.textShadowOffsetX),H(t,"textShadowOffsetY")&&(r.textShadowOffsetY=t.textShadowOffsetY))}var Wb={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},Em=pt(Wb);Fe(xr,function(r,t){return r[t]=1,r},{});xr.join(", ");var Hl=["","style","shape","extra"],aa=St();function _p(r,t,e,i,n){var a=r+"Animation",o=dc(r,i,n)||{},s=aa(t).userDuring;return o.duration>0&&(o.during=s?W(aO,{el:t,userDuring:s}):null,o.setToFinal=!0,o.scope=r),O(o,e[a]),o}function ih(r,t,e,i){i=i||{};var n=i.dataIndex,a=i.isInit,o=i.clearStyle,s=e.isAnimationEnabled(),l=aa(r),u=t.style;l.userDuring=t.during;var f={},h={};if(sO(r,t,h),Om("shape",t,h),Om("extra",t,h),!a&&s&&(oO(r,t,f),km("shape",r,t,f),km("extra",r,t,f),lO(r,t,u,f)),h.style=u,eO(r,h,o),iO(r,t),s)if(a){var c={};w(Hl,function(p){var d=p?t[p]:t;d&&d.enterFrom&&(p&&(c[p]=c[p]||{}),O(p?c[p]:c,d.enterFrom))});var v=_p("enter",r,t,e,n);v.duration>0&&r.animateFrom(c,v)}else rO(r,t,n||0,e,f);Yb(r,t),u?r.dirty():r.markRedraw()}function Yb(r,t){for(var e=aa(r).leaveToProps,i=0;i0&&r.animateFrom(n,a)}}function iO(r,t){H(t,"silent")&&(r.silent=t.silent),H(t,"ignore")&&(r.ignore=t.ignore),r instanceof Hr&&H(t,"invisible")&&(r.invisible=t.invisible),r instanceof gt&&H(t,"autoBatch")&&(r.autoBatch=t.autoBatch)}var vr={},nO={setTransform:function(r,t){return vr.el[r]=t,this},getTransform:function(r){return vr.el[r]},setShape:function(r,t){var e=vr.el,i=e.shape||(e.shape={});return i[r]=t,e.dirtyShape&&e.dirtyShape(),this},getShape:function(r){var t=vr.el.shape;if(t)return t[r]},setStyle:function(r,t){var e=vr.el,i=e.style;return i&&(i[r]=t,e.dirtyStyle&&e.dirtyStyle()),this},getStyle:function(r){var t=vr.el.style;if(t)return t[r]},setExtra:function(r,t){var e=vr.el.extra||(vr.el.extra={});return e[r]=t,this},getExtra:function(r){var t=vr.el.extra;if(t)return t[r]}};function aO(){var r=this,t=r.el;if(t){var e=aa(t).userDuring,i=r.userDuring;if(e!==i){r.el=r.userDuring=null;return}vr.el=t,i(nO)}}function km(r,t,e,i){var n=e[r];if(n){var a=t[r],o;if(a){var s=e.transition,l=n.transition;if(l)if(!o&&(o=i[r]={}),un(l))O(o,a);else for(var u=At(l),f=0;f=0){!o&&(o=i[r]={});for(var v=pt(a),f=0;f=0)){var c=r.getAnimationStyleProps(),v=c?c.style:null;if(v){!a&&(a=i.style={});for(var p=pt(e),u=0;us)return!0;if(o){var l=up(t).seriesDataCount,u=n.getExtent();return Math.abs(u[0]-u[1])/l>s}return!1}return i===!0},r.prototype.makeElOption=function(t,e,i,n,a){},r.prototype.createPointerEl=function(t,e,i,n){var a=e.pointer;if(a){var o=Xi(t).pointerEl=new ha[a.type](Bm(e.pointer));t.add(o)}},r.prototype.createLabelEl=function(t,e,i,n){if(e.label){var a=Xi(t).labelEl=new ct(Bm(e.label));t.add(a),zm(a,n)}},r.prototype.updatePointerEl=function(t,e,i){var n=Xi(t).pointerEl;n&&e.pointer&&(n.setStyle(e.pointer.style),i(n,{shape:e.pointer.shape}))},r.prototype.updateLabelEl=function(t,e,i,n){var a=Xi(t).labelEl;a&&(a.setStyle(e.label.style),i(a,{x:e.label.x,y:e.label.y}),zm(a,n))},r.prototype._renderHandle=function(t){if(!(this._dragging||!this.updateHandleTransform)){var e=this._axisPointerModel,i=this._api.getZr(),n=this._handle,a=e.getModel("handle"),o=e.get("status");if(!a.get("show")||!o||o==="hide"){n&&i.remove(n),this._handle=null;return}var s;this._handle||(s=!0,n=this._handle=fa(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){Fr(u.event)},onmousedown:nh(this._onHandleDragMove,this,0,0),drift:nh(this._onHandleDragMove,this),ondragend:nh(this._onHandleDragEnd,this)}),i.add(n)),Fm(n,e,!1),n.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=a.get("size");z(l)||(l=[l,l]),n.scaleX=l[0]/2,n.scaleY=l[1]/2,$o(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,s)}},r.prototype._moveHandleToValue=function(t,e){Nm(this._axisPointerModel,!e&&this._moveAnimation,this._handle,ah(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},r.prototype._onHandleDragMove=function(t,e){var i=this._handle;if(i){this._dragging=!0;var n=this.updateHandleTransform(ah(i),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=n,i.stopAnimation(),i.attr(ah(n)),Xi(i).lastProp=null,this._doDispatchAxisPointer()}},r.prototype._doDispatchAxisPointer=function(){var t=this._handle;if(t){var e=this._payloadInfo,i=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:e.cursorPoint[0],y:e.cursorPoint[1],tooltipOption:e.tooltipOption,axesInfo:[{axisDim:i.axis.dim,axisIndex:i.componentIndex}]})}},r.prototype._onHandleDragEnd=function(){this._dragging=!1;var t=this._handle;if(t){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},r.prototype.clear=function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),i=this._group,n=this._handle;e&&i&&(this._lastGraphicKey=null,i&&e.remove(i),n&&e.remove(n),this._group=null,this._handle=null,this._payloadInfo=null),Mo(this,"_doDispatchAxisPointer")},r.prototype.doClear=function(){},r.prototype.buildLabel=function(t,e,i){return i=i||0,{x:t[i],y:t[1-i],width:e[i],height:e[1-i]}},r})();function Nm(r,t,e,i){Zb(Xi(e).lastProp,i)||(Xi(e).lastProp=i,t?Mt(e,i,r):(e.stopAnimation(),e.attr(i)))}function Zb(r,t){if(X(r)&&X(t)){var e=!0;return w(t,function(i,n){e=e&&Zb(r[n],i)}),!!e}else return r===t}function zm(r,t){r[t.get(["label","show"])?"show":"hide"]()}function ah(r){return{x:r.x||0,y:r.y||0,rotation:r.rotation||0}}function Fm(r,t,e){var i=t.get("z"),n=t.get("zlevel");r&&r.traverse(function(a){a.type!=="group"&&(i!=null&&(a.z=i),n!=null&&(a.zlevel=n),a.silent=e)})}function $b(r){var t=r.get("type"),e=r.getModel(t+"Style"),i;return t==="line"?(i=e.getLineStyle(),i.fill=null):t==="shadow"&&(i=e.getAreaStyle(),i.stroke=null),i}function qb(r,t,e,i,n){var a=e.get("value"),o=Kb(a,t.axis,t.ecModel,e.get("seriesDataIndices"),{precision:e.get(["label","precision"]),formatter:e.get(["label","formatter"])}),s=e.getModel("label"),l=_n(s.get("padding")||0),u=s.getFont(),f=Go(o,u),h=n.position,c=f.width+l[1]+l[3],v=f.height+l[0]+l[2],p=n.align;p==="right"&&(h[0]-=c),p==="center"&&(h[0]-=c/2);var d=n.verticalAlign;d==="bottom"&&(h[1]-=v),d==="middle"&&(h[1]-=v/2),vO(h,c,v,i);var g=s.get("backgroundColor");(!g||g==="auto")&&(g=t.get(["axisLine","lineStyle","color"])),r.label={x:h[0],y:h[1],style:Rt(s,{text:o,font:u,fill:s.getTextColor(),padding:l,backgroundColor:g}),z2:10}}function vO(r,t,e,i){var n=i.getWidth(),a=i.getHeight();r[0]=Math.min(r[0]+t,n)-t,r[1]=Math.min(r[1]+e,a)-e,r[0]=Math.max(r[0],0),r[1]=Math.max(r[1],0)}function Kb(r,t,e,i,n){r=t.scale.parse(r);var a=t.scale.getLabel({value:r},{precision:n.precision}),o=n.formatter;if(o){var s={value:ip(t,{value:r}),axisDimension:t.dim,axisIndex:t.index,seriesData:[]};w(i,function(l){var u=e.getSeriesByIndex(l.seriesIndex),f=l.dataIndexInside,h=u&&u.getDataParams(f);h&&s.seriesData.push(h)}),G(o)?a=o.replace("{value}",a):j(o)&&(a=o(s))}return a}function Jb(r,t,e){var i=xe();return mi(i,i,e.rotation),Vr(i,i,e.position),tr([r.dataToCoord(t),(e.labelOffset||0)+(e.labelDirection||1)*(e.labelMargin||0)],i)}function cO(r,t,e,i,n,a){var o=de.innerTextLayout(e.rotation,0,e.labelDirection);e.labelMargin=n.get(["label","margin"]),qb(t,i,n,a,{position:Jb(i.axis,r,e),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function jb(r,t,e){return e=e||0,{x1:r[e],y1:r[1-e],x2:t[e],y2:t[1-e]}}function pO(r,t,e){return e=e||0,{x:r[e],y:r[1-e],width:t[e],height:t[1-e]}}function Vm(r,t,e,i,n,a){return{cx:r,cy:t,r0:e,r:i,startAngle:n,endAngle:a,clockwise:!0}}var dO=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.makeElOption=function(e,i,n,a,o){var s=n.axis,l=s.grid,u=a.get("type"),f=Gm(l,s).getOtherAxis(s).getGlobalExtent(),h=s.toGlobalCoord(s.dataToCoord(i,!0));if(u&&u!=="none"){var c=$b(a),v=gO[u](s,h,f);v.style=c,e.graphicKey=v.type,e.pointer=v}var p=yv(l.model,n);cO(i,e,p,n,a,o)},t.prototype.getHandleTransform=function(e,i,n){var a=yv(i.axis.grid.model,i,{labelInside:!1});a.labelMargin=n.get(["handle","margin"]);var o=Jb(i.axis,e,a);return{x:o[0],y:o[1],rotation:a.rotation+(a.labelDirection<0?Math.PI:0)}},t.prototype.updateHandleTransform=function(e,i,n,a){var o=n.axis,s=o.grid,l=o.getGlobalExtent(!0),u=Gm(s,o).getOtherAxis(o).getGlobalExtent(),f=o.dim==="x"?0:1,h=[e.x,e.y];h[f]+=i[f],h[f]=Math.min(l[1],h[f]),h[f]=Math.max(l[0],h[f]);var c=(u[1]+u[0])/2,v=[c,c];v[f]=h[f];var p=[{verticalAlign:"middle"},{align:"center"}];return{x:h[0],y:h[1],rotation:e.rotation,cursorPoint:v,tooltipOption:p[f]}},t})(Xb);function Gm(r,t){var e={};return e[t.dim+"AxisIndex"]=t.index,r.getCartesian(e)}var gO={line:function(r,t,e){var i=jb([t,e[0]],[t,e[1]],Hm(r));return{type:"Line",subPixelOptimize:!0,shape:i}},shadow:function(r,t,e){var i=Math.max(1,r.getBandWidth()),n=e[1]-e[0];return{type:"Rect",shape:pO([t-i/2,e[0]],[i,n],Hm(r))}}};function Hm(r){return r.dim==="x"?0:1}var yO=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="axisPointer",t.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}},t})(at),Or=St(),mO=w;function Qb(r,t,e){if(!tt.node){var i=t.getZr();Or(i).records||(Or(i).records={}),_O(i,t);var n=Or(i).records[r]||(Or(i).records[r]={});n.handler=e}}function _O(r,t){if(Or(r).initialized)return;Or(r).initialized=!0,e("click",ft(Wm,"click")),e("mousemove",ft(Wm,"mousemove")),e("globalout",xO);function e(i,n){r.on(i,function(a){var o=bO(t);mO(Or(r).records,function(s){s&&n(s,a,o.dispatchAction)}),SO(o.pendings,t)})}}function SO(r,t){var e=r.showTip.length,i=r.hideTip.length,n;e?n=r.showTip[e-1]:i&&(n=r.hideTip[i-1]),n&&(n.dispatchAction=null,t.dispatchAction(n))}function xO(r,t,e){r.handler("leave",null,e)}function Wm(r,t,e,i){t.handler(r,e,i)}function bO(r){var t={showTip:[],hideTip:[]},e=function(i){var n=t[i.type];n?n.push(i):(i.dispatchAction=e,r.dispatchAction(i))};return{dispatchAction:e,pendings:t}}function Iv(r,t){if(!tt.node){var e=t.getZr(),i=(Or(e).records||{})[r];i&&(Or(e).records[r]=null)}}var wO=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n){var a=i.getComponent("tooltip"),o=e.get("triggerOn")||a&&a.get("triggerOn")||"mousemove|click";Qb("axisPointer",n,function(s,l,u){o!=="none"&&(s==="leave"||o.indexOf(s)>=0)&&u({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},t.prototype.remove=function(e,i){Iv("axisPointer",i)},t.prototype.dispose=function(e,i){Iv("axisPointer",i)},t.type="axisPointer",t})(Ct);function tw(r,t){var e=[],i=r.seriesIndex,n;if(i==null||!(n=t.getSeriesByIndex(i)))return{point:[]};var a=n.getData(),o=vn(a,r);if(o==null||o<0||z(o))return{point:[]};var s=a.getItemGraphicEl(o),l=n.coordinateSystem;if(n.getTooltipPosition)e=n.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)if(r.isStacked){var u=l.getBaseAxis(),f=l.getOtherAxis(u),h=f.dim,c=u.dim,v=h==="x"||h==="radius"?1:0,p=a.mapDimension(c),d=[];d[v]=a.get(p,o),d[1-v]=a.get(a.getCalculationInfo("stackResultDimension"),o),e=l.dataToPoint(d)||[]}else e=l.dataToPoint(a.getValues(F(l.dimensions,function(y){return a.mapDimension(y)}),o))||[];else if(s){var g=s.getBoundingRect().clone();g.applyTransform(s.transform),e=[g.x+g.width/2,g.y+g.height/2]}return{point:e,el:s}}var Ym=St();function TO(r,t,e){var i=r.currTrigger,n=[r.x,r.y],a=r,o=r.dispatchAction||W(e.dispatchAction,e),s=t.getComponent("axisPointer").coordSysAxesInfo;if(s){al(n)&&(n=tw({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},t).point);var l=al(n),u=a.axesInfo,f=s.axesInfo,h=i==="leave"||al(n),c={},v={},p={list:[],map:{}},d={showPointer:ft(AO,v),showTooltip:ft(MO,p)};w(s.coordSysMap,function(y,m){var _=l||y.containPoint(n);w(s.coordSysAxesInfo[m],function(S,b){var x=S.axis,T=IO(u,S);if(!h&&_&&(!u||T)){var C=T&&T.value;C==null&&!l&&(C=x.pointToData(n)),C!=null&&Um(S,C,d,!1,c)}})});var g={};return w(f,function(y,m){var _=y.linkGroup;_&&!v[m]&&w(_.axesInfo,function(S,b){var x=v[b];if(S!==y&&x){var T=x.value;_.mapper&&(T=y.axis.scale.parse(_.mapper(T,Xm(S),Xm(y)))),g[y.key]=T}})}),w(g,function(y,m){Um(f[m],y,d,!0,c)}),DO(v,f,c),LO(p,n,r,o),PO(f,o,e),c}}function Um(r,t,e,i,n){var a=r.axis;if(!(a.scale.isBlank()||!a.containData(t))){if(!r.involveSeries){e.showPointer(r,t);return}var o=CO(t,r),s=o.payloadBatch,l=o.snapToValue;s[0]&&n.seriesIndex==null&&O(n,s[0]),!i&&r.snap&&a.containData(l)&&l!=null&&(t=l),e.showPointer(r,t,s),e.showTooltip(r,o,l)}}function CO(r,t){var e=t.axis,i=e.dim,n=r,a=[],o=Number.MAX_VALUE,s=-1;return w(t.seriesModels,function(l,u){var f=l.getData().mapDimensionsAll(i),h,c;if(l.getAxisTooltipData){var v=l.getAxisTooltipData(f,r,e);c=v.dataIndices,h=v.nestestValue}else{if(c=l.getData().indicesOfNearest(f[0],r,e.type==="category"?.5:null),!c.length)return;h=l.getData().get(f[0],c[0])}if(!(h==null||!isFinite(h))){var p=r-h,d=Math.abs(p);d<=o&&((d=0&&s<0)&&(o=d,s=p,n=h,a.length=0),w(c,function(g){a.push({seriesIndex:l.seriesIndex,dataIndexInside:g,dataIndex:l.getData().getRawIndex(g)})}))}}),{payloadBatch:a,snapToValue:n}}function AO(r,t,e,i){r[t.key]={value:e,payloadBatch:i}}function MO(r,t,e,i){var n=e.payloadBatch,a=t.axis,o=a.model,s=t.axisPointerModel;if(!(!t.triggerTooltip||!n.length)){var l=t.coordSys.model,u=Eo(l),f=r.map[u];f||(f=r.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},r.list.push(f)),f.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:i,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:n.slice()})}}function DO(r,t,e){var i=e.axesInfo=[];w(t,function(n,a){var o=n.axisPointerModel.option,s=r[a];s?(!n.useHandle&&(o.status="show"),o.value=s.value,o.seriesDataIndices=(s.payloadBatch||[]).slice()):!n.useHandle&&(o.status="hide"),o.status==="show"&&i.push({axisDim:n.axis.dim,axisIndex:n.axis.model.componentIndex,value:o.value})})}function LO(r,t,e,i){if(al(t)||!r.list.length){i({type:"hideTip"});return}var n=((r.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:t[0],y:t[1],tooltipOption:e.tooltipOption,position:e.position,dataIndexInside:n.dataIndexInside,dataIndex:n.dataIndex,seriesIndex:n.seriesIndex,dataByCoordSys:r.list})}function PO(r,t,e){var i=e.getZr(),n="axisPointerLastHighlights",a=Ym(i)[n]||{},o=Ym(i)[n]={};w(r,function(u,f){var h=u.axisPointerModel.option;h.status==="show"&&u.triggerEmphasis&&w(h.seriesDataIndices,function(c){var v=c.seriesIndex+" | "+c.dataIndex;o[v]=c})});var s=[],l=[];w(a,function(u,f){!o[f]&&l.push(u)}),w(o,function(u,f){!a[f]&&s.push(u)}),l.length&&e.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&e.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function IO(r,t){for(var e=0;e<(r||[]).length;e++){var i=r[e];if(t.axis.dim===i.axisDim&&t.axis.model.componentIndex===i.axisIndex)return i}}function Xm(r){var t=r.axis.model,e={},i=e.axisDim=r.axis.dim;return e.axisIndex=e[i+"AxisIndex"]=t.componentIndex,e.axisName=e[i+"AxisName"]=t.name,e.axisId=e[i+"AxisId"]=t.id,e}function al(r){return!r||r[0]==null||isNaN(r[0])||r[1]==null||isNaN(r[1])}function Sp(r){Ko.registerAxisPointerClass("CartesianAxisPointer",dO),r.registerComponentModel(yO),r.registerComponentView(wO),r.registerPreprocessor(function(t){if(t){(!t.axisPointer||t.axisPointer.length===0)&&(t.axisPointer={});var e=t.axisPointer.link;e&&!z(e)&&(t.axisPointer.link=[e])}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=NR(t,e)}),r.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},TO)}function RO(r){Ht(JR),Ht(Sp)}var EO=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.makeElOption=function(e,i,n,a,o){var s=n.axis;s.dim==="angle"&&(this.animationThreshold=Math.PI/18);var l=s.polar,u=l.getOtherAxis(s),f=u.getExtent(),h=s.dataToCoord(i),c=a.get("type");if(c&&c!=="none"){var v=$b(a),p=OO[c](s,l,h,f);p.style=v,e.graphicKey=p.type,e.pointer=p}var d=a.get(["label","margin"]),g=kO(i,n,a,l,d);qb(e,n,a,o,g)},t})(Xb);function kO(r,t,e,i,n){var a=t.axis,o=a.dataToCoord(r),s=i.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l=i.getRadiusAxis().getExtent(),u,f,h;if(a.dim==="radius"){var c=xe();mi(c,c,s),Vr(c,c,[i.cx,i.cy]),u=tr([o,-n],c);var v=t.getModel("axisLabel").get("rotate")||0,p=de.innerTextLayout(s,v*Math.PI/180,-1);f=p.textAlign,h=p.textVerticalAlign}else{var d=l[1];u=i.coordToPoint([d+n,o]);var g=i.cx,y=i.cy;f=Math.abs(u[0]-g)/d<.3?"center":u[0]>g?"left":"right",h=Math.abs(u[1]-y)/d<.3?"middle":u[1]>y?"top":"bottom"}return{position:u,align:f,verticalAlign:h}}var OO={line:function(r,t,e,i){return r.dim==="angle"?{type:"Line",shape:jb(t.coordToPoint([i[0],e]),t.coordToPoint([i[1],e]))}:{type:"Circle",shape:{cx:t.cx,cy:t.cy,r:e}}},shadow:function(r,t,e,i){var n=Math.max(1,r.getBandWidth()),a=Math.PI/180;return r.dim==="angle"?{type:"Sector",shape:Vm(t.cx,t.cy,i[0],i[1],(-e-n/2)*a,(-e+n/2)*a)}:{type:"Sector",shape:Vm(t.cx,t.cy,e-n/2,e+n/2,0,Math.PI*2)}}},BO=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.findAxisModel=function(e){var i,n=this.ecModel;return n.eachComponent(e,function(a){a.getCoordSysModel()===this&&(i=a)},this),i},t.type="polar",t.dependencies=["radiusAxis","angleAxis"],t.defaultOption={z:0,center:["50%","50%"],radius:"80%"},t})(at),xp=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.getCoordSysModel=function(){return this.getReferringComponents("polar",kt).models[0]},t.type="polarAxis",t})(at);Wt(xp,qo);var NO=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="angleAxis",t})(xp),zO=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="radiusAxis",t})(xp),bp=(function(r){E(t,r);function t(e,i){return r.call(this,"radius",e,i)||this}return t.prototype.pointToData=function(e,i){return this.polar.pointToData(e,i)[this.dim==="radius"?0:1]},t})(or);bp.prototype.dataToRadius=or.prototype.dataToCoord;bp.prototype.radiusToData=or.prototype.coordToData;var FO=St(),wp=(function(r){E(t,r);function t(e,i){return r.call(this,"angle",e,i||[0,360])||this}return t.prototype.pointToData=function(e,i){return this.polar.pointToData(e,i)[this.dim==="radius"?0:1]},t.prototype.calculateCategoryInterval=function(){var e=this,i=e.getLabelModel(),n=e.scale,a=n.getExtent(),o=n.count();if(a[1]-a[0]<1)return 0;var s=a[0],l=e.dataToCoord(s+1)-e.dataToCoord(s),u=Math.abs(l),f=Go(s==null?"":s+"",i.getFont(),"center","top"),h=Math.max(f.height,7),c=h/u;isNaN(c)&&(c=1/0);var v=Math.max(0,Math.floor(c)),p=FO(e.model),d=p.lastAutoInterval,g=p.lastTickCount;return d!=null&&g!=null&&Math.abs(d-v)<=1&&Math.abs(g-o)<=1&&d>v?v=d:(p.lastTickCount=o,p.lastAutoInterval=v),v},t})(or);wp.prototype.dataToAngle=or.prototype.dataToCoord;wp.prototype.angleToData=or.prototype.coordToData;var ew=["radius","angle"],VO=(function(){function r(t){this.dimensions=ew,this.type="polar",this.cx=0,this.cy=0,this._radiusAxis=new bp,this._angleAxis=new wp,this.axisPointerEnabled=!0,this.name=t||"",this._radiusAxis.polar=this._angleAxis.polar=this}return r.prototype.containPoint=function(t){var e=this.pointToCoord(t);return this._radiusAxis.contain(e[0])&&this._angleAxis.contain(e[1])},r.prototype.containData=function(t){return this._radiusAxis.containData(t[0])&&this._angleAxis.containData(t[1])},r.prototype.getAxis=function(t){var e="_"+t+"Axis";return this[e]},r.prototype.getAxes=function(){return[this._radiusAxis,this._angleAxis]},r.prototype.getAxesByScale=function(t){var e=[],i=this._angleAxis,n=this._radiusAxis;return i.scale.type===t&&e.push(i),n.scale.type===t&&e.push(n),e},r.prototype.getAngleAxis=function(){return this._angleAxis},r.prototype.getRadiusAxis=function(){return this._radiusAxis},r.prototype.getOtherAxis=function(t){var e=this._angleAxis;return t===e?this._radiusAxis:e},r.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},r.prototype.getTooltipAxes=function(t){var e=t!=null&&t!=="auto"?this.getAxis(t):this.getBaseAxis();return{baseAxes:[e],otherAxes:[this.getOtherAxis(e)]}},r.prototype.dataToPoint=function(t,e){return this.coordToPoint([this._radiusAxis.dataToRadius(t[0],e),this._angleAxis.dataToAngle(t[1],e)])},r.prototype.pointToData=function(t,e){var i=this.pointToCoord(t);return[this._radiusAxis.radiusToData(i[0],e),this._angleAxis.angleToData(i[1],e)]},r.prototype.pointToCoord=function(t){var e=t[0]-this.cx,i=t[1]-this.cy,n=this.getAngleAxis(),a=n.getExtent(),o=Math.min(a[0],a[1]),s=Math.max(a[0],a[1]);n.inverse?o=s-360:s=o+360;var l=Math.sqrt(e*e+i*i);e/=l,i/=l;for(var u=Math.atan2(-i,e)/Math.PI*180,f=us;)u+=f*360;return[l,u]},r.prototype.coordToPoint=function(t){var e=t[0],i=t[1]/180*Math.PI,n=Math.cos(i)*e+this.cx,a=-Math.sin(i)*e+this.cy;return[n,a]},r.prototype.getArea=function(){var t=this.getAngleAxis(),e=this.getRadiusAxis(),i=e.getExtent().slice();i[0]>i[1]&&i.reverse();var n=t.getExtent(),a=Math.PI/180,o=1e-4;return{cx:this.cx,cy:this.cy,r0:i[0],r:i[1],startAngle:-n[0]*a,endAngle:-n[1]*a,clockwise:t.inverse,contain:function(s,l){var u=s-this.cx,f=l-this.cy,h=u*u+f*f,c=this.r,v=this.r0;return c!==v&&h-o<=c*c&&h+o>=v*v}}},r.prototype.convertToPixel=function(t,e,i){var n=Zm(e);return n===this?this.dataToPoint(i):null},r.prototype.convertFromPixel=function(t,e,i){var n=Zm(e);return n===this?this.pointToData(i):null},r})();function Zm(r){var t=r.seriesModel,e=r.polarModel;return e&&e.coordinateSystem||t&&t.coordinateSystem}function GO(r,t,e){var i=t.get("center"),n=e.getWidth(),a=e.getHeight();r.cx=Q(i[0],n),r.cy=Q(i[1],a);var o=r.getRadiusAxis(),s=Math.min(n,a)/2,l=t.get("radius");l==null?l=[0,"100%"]:z(l)||(l=[0,l]);var u=[Q(l[0],s),Q(l[1],s)];o.inverse?o.setExtent(u[1],u[0]):o.setExtent(u[0],u[1])}function HO(r,t){var e=this,i=e.getAngleAxis(),n=e.getRadiusAxis();if(i.scale.setExtent(1/0,-1/0),n.scale.setExtent(1/0,-1/0),r.eachSeries(function(s){if(s.coordinateSystem===e){var l=s.getData();w(Bl(l,"radius"),function(u){n.scale.unionExtentFromData(l,u)}),w(Bl(l,"angle"),function(u){i.scale.unionExtentFromData(l,u)})}}),ia(i.scale,i.model),ia(n.scale,n.model),i.type==="category"&&!i.onBand){var a=i.getExtent(),o=360/i.scale.count();i.inverse?a[1]+=o:a[1]-=o,i.setExtent(a[0],a[1])}}function WO(r){return r.mainType==="angleAxis"}function $m(r,t){var e;if(r.type=t.get("type"),r.scale=Au(t),r.onBand=t.get("boundaryGap")&&r.type==="category",r.inverse=t.get("inverse"),WO(t)){r.inverse=r.inverse!==t.get("clockwise");var i=t.get("startAngle"),n=(e=t.get("endAngle"))!==null&&e!==void 0?e:i+(r.inverse?-360:360);r.setExtent(i,n)}t.axis=r,r.model=t}var YO={dimensions:ew,create:function(r,t){var e=[];return r.eachComponent("polar",function(i,n){var a=new VO(n+"");a.update=HO;var o=a.getRadiusAxis(),s=a.getAngleAxis(),l=i.findAxisModel("radiusAxis"),u=i.findAxisModel("angleAxis");$m(o,l),$m(s,u),GO(a,i,t),e.push(a),i.coordinateSystem=a,a.model=i}),r.eachSeries(function(i){if(i.get("coordinateSystem")==="polar"){var n=i.getReferringComponents("polar",kt).models[0];i.coordinateSystem=n.coordinateSystem}}),e}},UO=["axisLine","axisLabel","axisTick","minorTick","splitLine","minorSplitLine","splitArea"];function Fs(r,t,e){t[1]>t[0]&&(t=t.slice().reverse());var i=r.coordToPoint([t[0],e]),n=r.coordToPoint([t[1],e]);return{x1:i[0],y1:i[1],x2:n[0],y2:n[1]}}function Vs(r){var t=r.getRadiusAxis();return t.inverse?0:1}function qm(r){var t=r[0],e=r[r.length-1];t&&e&&Math.abs(Math.abs(t.coord-e.coord)-360)<1e-4&&r.pop()}var XO=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.axisPointerClass="PolarAxisPointer",e}return t.prototype.render=function(e,i){if(this.group.removeAll(),!!e.get("show")){var n=e.axis,a=n.polar,o=a.getRadiusAxis().getExtent(),s=n.getTicksCoords(),l=n.getMinorTicksCoords(),u=F(n.getViewLabels(),function(f){f=q(f);var h=n.scale,c=h.type==="ordinal"?h.getRawOrdinalNumber(f.tickValue):f.tickValue;return f.coord=n.dataToCoord(c),f});qm(u),qm(s),w(UO,function(f){e.get([f,"show"])&&(!n.scale.isBlank()||f==="axisLine")&&ZO[f](this.group,e,a,s,l,o,u)},this)}},t.type="angleAxis",t})(Ko),ZO={axisLine:function(r,t,e,i,n,a){var o=t.getModel(["axisLine","lineStyle"]),s=e.getAngleAxis(),l=Math.PI/180,u=s.getExtent(),f=Vs(e),h=f?0:1,c,v=Math.abs(u[1]-u[0])===360?"Circle":"Arc";a[h]===0?c=new ha[v]({shape:{cx:e.cx,cy:e.cy,r:a[f],startAngle:-u[0]*l,endAngle:-u[1]*l,clockwise:s.inverse},style:o.getLineStyle(),z2:1,silent:!0}):c=new ua({shape:{cx:e.cx,cy:e.cy,r:a[f],r0:a[h]},style:o.getLineStyle(),z2:1,silent:!0}),c.style.fill=null,r.add(c)},axisTick:function(r,t,e,i,n,a){var o=t.getModel("axisTick"),s=(o.get("inside")?-1:1)*o.get("length"),l=a[Vs(e)],u=F(i,function(f){return new Kt({shape:Fs(e,[l,l+s],f.coord)})});r.add(Be(u,{style:K(o.getModel("lineStyle").getLineStyle(),{stroke:t.get(["axisLine","lineStyle","color"])})}))},minorTick:function(r,t,e,i,n,a){if(n.length){for(var o=t.getModel("axisTick"),s=t.getModel("minorTick"),l=(o.get("inside")?-1:1)*s.get("length"),u=a[Vs(e)],f=[],h=0;hy?"left":"right",S=Math.abs(g[1]-m)/d<.3?"middle":g[1]>m?"top":"bottom";if(s&&s[p]){var b=s[p];X(b)&&b.textStyle&&(v=new _t(b.textStyle,l,l.ecModel))}var x=new ct({silent:de.isLabelSilent(t),style:Rt(v,{x:g[0],y:g[1],fill:v.getTextColor()||t.get(["axisLine","lineStyle","color"]),text:h.formattedLabel,align:_,verticalAlign:S})});if(r.add(x),f){var T=de.makeAxisEventDataBase(t);T.targetType="axisLabel",T.value=h.rawLabel,ot(x).eventData=T}},this)},splitLine:function(r,t,e,i,n,a){var o=t.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=0;l=l instanceof Array?l:[l];for(var f=[],h=0;h=0?"p":"n",R=A;b&&(i[f][P]||(i[f][P]={p:A,n:A}),R=i[f][P][I]);var k=void 0,V=void 0,B=void 0,N=void 0;if(p.dim==="radius"){var Y=p.dataToCoord(L)-A,Z=l.dataToCoord(P);Math.abs(Y)=N})}}})}function tB(r){var t={};w(r,function(i,n){var a=i.getData(),o=i.coordinateSystem,s=o.getBaseAxis(),l=iw(o,s),u=s.getExtent(),f=s.type==="category"?s.getBandWidth():Math.abs(u[1]-u[0])/a.count(),h=t[l]||{bandWidth:f,remainedWidth:f,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},c=h.stacks;t[l]=h;var v=rw(i);c[v]||h.autoWidthCount++,c[v]=c[v]||{width:0,maxWidth:0};var p=Q(i.get("barWidth"),f),d=Q(i.get("barMaxWidth"),f),g=i.get("barGap"),y=i.get("barCategoryGap");p&&!c[v].width&&(p=Math.min(h.remainedWidth,p),c[v].width=p,h.remainedWidth-=p),d&&(c[v].maxWidth=d),g!=null&&(h.gap=g),y!=null&&(h.categoryGap=y)});var e={};return w(t,function(i,n){e[n]={};var a=i.stacks,o=i.bandWidth,s=Q(i.categoryGap,o),l=Q(i.gap,1),u=i.remainedWidth,f=i.autoWidthCount,h=(u-s)/(f+(f-1)*l);h=Math.max(h,0),w(a,function(d,g){var y=d.maxWidth;y&&y+i.start.y&&(p=p+"-"+i.end.y);var d=o.get("formatter"),g={start:i.start.y,end:i.end.y,nameMap:p},y=this._formatterLabel(d,g),m=new ct({z2:30,style:Rt(o,{text:y}),silent:o.get("silent")});m.attr(this._yearTextPositionControl(m,v[l],n,l,s)),a.add(m)}},t.prototype._monthTextPositionControl=function(e,i,n,a,o){var s="left",l="top",u=e[0],f=e[1];return n==="horizontal"?(f=f+o,i&&(s="center"),a==="start"&&(l="bottom")):(u=u+o,i&&(l="middle"),a==="start"&&(s="right")),{x:u,y:f,align:s,verticalAlign:l}},t.prototype._renderMonthText=function(e,i,n,a){var o=e.getModel("monthLabel");if(o.get("show")){var s=o.get("nameMap"),l=o.get("margin"),u=o.get("position"),f=o.get("align"),h=[this._tlpoints,this._blpoints];(!s||G(s))&&(s&&(i=Kh(s)||i),s=i.get(["time","monthAbbr"])||[]);var c=u==="start"?0:1,v=n==="horizontal"?0:1;l=u==="start"?-l:l;for(var p=f==="center",d=o.get("silent"),g=0;g=n.start.time&&i.times.end.time&&e.reverse(),e},r.prototype._getRangeInfo=function(t){var e=[this.getDateInfo(t[0]),this.getDateInfo(t[1])],i;e[0].time>e[1].time&&(i=!0,e.reverse());var n=Math.floor(e[1].time/oh)-Math.floor(e[0].time/oh)+1,a=new Date(e[0].time),o=a.getDate(),s=e[1].date.getDate();a.setDate(o+n-1);var l=a.getDate();if(l!==s)for(var u=a.getTime()-e[1].time>0?1:-1;(l=a.getDate())!==s&&(a.getTime()-e[1].time)*u>0;)n-=u,a.setDate(l-u);var f=Math.floor((n+e[0].day+6)/7),h=i?-f+1:f-1;return i&&e.reverse(),{range:[e[0].formatedDate,e[1].formatedDate],start:e[0],end:e[1],allDay:n,weeks:f,nthWeek:h,fweek:e[0].day,lweek:e[1].day}},r.prototype._getDateByWeeksAndDay=function(t,e,i){var n=this._getRangeInfo(i);if(t>n.weeks||t===0&&en.lweek)return null;var a=(t-1)*7-n.fweek+e,o=new Date(n.start.time);return o.setDate(+n.start.d+a),this.getDateInfo(o)},r.create=function(t,e){var i=[];return t.eachComponent("calendar",function(n){var a=new r(n);i.push(a),n.coordinateSystem=a}),t.eachSeries(function(n){n.get("coordinateSystem")==="calendar"&&(n.coordinateSystem=i[n.get("calendarIndex")||0])}),i},r.dimensions=["time","value"],r})();function Jm(r){var t=r.calendarModel,e=r.seriesModel,i=t?t.coordinateSystem:e?e.coordinateSystem:null;return i}function lB(r){r.registerComponentModel(aB),r.registerComponentView(oB),r.registerCoordinateSystem("calendar",sB)}function uB(r,t){var e=r.existing;if(t.id=r.keyInfo.id,!t.type&&e&&(t.type=e.type),t.parentId==null){var i=t.parentOption;i?t.parentId=i.id:e&&(t.parentId=e.parentId)}t.parentOption=null}function jm(r,t){var e;return w(t,function(i){r[i]!=null&&r[i]!=="auto"&&(e=!0)}),e}function fB(r,t,e){var i=O({},e),n=r[t],a=e.$action||"merge";a==="merge"?n?(J(n,i,!0),gi(n,i,{ignoreSize:!0}),Y1(e,n),Gs(e,n),Gs(e,n,"shape"),Gs(e,n,"style"),Gs(e,n,"extra"),e.clipPath=n.clipPath):r[t]=i:a==="replace"?r[t]=i:a==="remove"&&n&&(r[t]=null)}var nw=["transition","enterFrom","leaveTo"],hB=nw.concat(["enterAnimation","updateAnimation","leaveAnimation"]);function Gs(r,t,e){if(e&&(!r[e]&&t[e]&&(r[e]={}),r=r[e],t=t[e]),!(!r||!t))for(var i=e?nw:hB,n=0;n=0;f--){var h=n[f],c=qt(h.id,null),v=c!=null?o.get(c):null;if(v){var p=v.parent,y=ke(p),m=p===a?{width:s,height:l}:{width:y.width,height:y.height},_={},S=Ic(v,h,m,null,{hv:h.hv,boundingMode:h.bounding},_);if(!ke(v).isNew&&S){for(var b=h.transition,x={},T=0;T=0)?x[C]=A:v[C]=A}Mt(v,x,e,0)}else v.attr(_)}}},t.prototype._clear=function(){var e=this,i=this._elMap;i.each(function(n){ol(n,ke(n).option,i,e._lastGraphicModel)}),this._elMap=U()},t.prototype.dispose=function(){this._clear()},t.type="graphic",t})(Ct);function Rv(r){var t=H(Qm,r)?Qm[r]:yc(r),e=new t({});return ke(e).type=r,e}function t0(r,t,e,i){var n=Rv(e);return t.add(n),i.set(r,n),ke(n).id=r,ke(n).isNew=!0,n}function ol(r,t,e,i){var n=r&&r.parent;n&&(r.type==="group"&&r.traverse(function(a){ol(a,t,e,i)}),tO(r,t,i),e.removeKey(ke(r).id))}function e0(r,t,e,i){r.isGroup||w([["cursor",Hr.prototype.cursor],["zlevel",i||0],["z",e||0],["z2",0]],function(n){var a=n[0];H(t,a)?r[a]=rt(t[a],n[1]):r[a]==null&&(r[a]=n[1])}),w(pt(t),function(n){if(n.indexOf("on")===0){var a=t[n];r[n]=j(a)?a:null}}),H(t,"draggable")&&(r.draggable=t.draggable),t.name!=null&&(r.name=t.name),t.id!=null&&(r.id=t.id)}function dB(r){return r=O({},r),w(["id","parentId","$action","hv","bounding","textContent","clipPath"].concat(W1),function(t){delete r[t]}),r}function gB(r,t,e){var i=ot(r).eventData;!r.silent&&!r.ignore&&!i&&(i=ot(r).eventData={componentType:"graphic",componentIndex:t.componentIndex,name:r.name}),i&&(i.info=e.info)}function yB(r){r.registerComponentModel(cB),r.registerComponentView(pB),r.registerPreprocessor(function(t){var e=t.graphic;z(e)?!e[0]||!e[0].elements?t.graphic=[{elements:e}]:t.graphic=[t.graphic[0]]:e&&!e.elements&&(t.graphic=[{elements:[e]}])})}var r0=["x","y","radius","angle","single"],mB=["cartesian2d","polar","singleAxis"];function _B(r){var t=r.get("coordinateSystem");return lt(mB,t)>=0}function ui(r){return r+"Axis"}function SB(r,t){var e=U(),i=[],n=U();r.eachComponent({mainType:"dataZoom",query:t},function(f){n.get(f.uid)||s(f)});var a;do a=!1,r.eachComponent("dataZoom",o);while(a);function o(f){!n.get(f.uid)&&l(f)&&(s(f),a=!0)}function s(f){n.set(f.uid,!0),i.push(f),u(f)}function l(f){var h=!1;return f.eachTargetAxis(function(c,v){var p=e.get(c);p&&p[v]&&(h=!0)}),h}function u(f){f.eachTargetAxis(function(h,c){(e.get(h)||e.set(h,[]))[c]=!0})}return i}function aw(r){var t=r.ecModel,e={infoList:[],infoMap:U()};return r.eachTargetAxis(function(i,n){var a=t.getComponent(ui(i),n);if(a){var o=a.getCoordSysModel();if(o){var s=o.uid,l=e.infoMap.get(s);l||(l={model:o,axisModels:[]},e.infoList.push(l),e.infoMap.set(s,l)),l.axisModels.push(a)}}}),e}var sh=(function(){function r(){this.indexList=[],this.indexMap=[]}return r.prototype.add=function(t){this.indexMap[t]||(this.indexList.push(t),this.indexMap[t]=!0)},r})(),Bo=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e._autoThrottle=!0,e._noTarget=!0,e._rangePropMode=["percent","percent"],e}return t.prototype.init=function(e,i,n){var a=i0(e);this.settledOption=a,this.mergeDefaultAndTheme(e,n),this._doInit(a)},t.prototype.mergeOption=function(e){var i=i0(e);J(this.option,e,!0),J(this.settledOption,i,!0),this._doInit(i)},t.prototype._doInit=function(e){var i=this.option;this._setDefaultThrottle(e),this._updateRangeUse(e);var n=this.settledOption;w([["start","startValue"],["end","endValue"]],function(a,o){this._rangePropMode[o]==="value"&&(i[a[0]]=n[a[0]]=null)},this),this._resetTarget()},t.prototype._resetTarget=function(){var e=this.get("orient",!0),i=this._targetAxisInfoMap=U(),n=this._fillSpecifiedTargetAxis(i);n?this._orient=e||this._makeAutoOrientByTargetAxis():(this._orient=e||"horizontal",this._fillAutoTargetAxisByOrient(i,this._orient)),this._noTarget=!0,i.each(function(a){a.indexList.length&&(this._noTarget=!1)},this)},t.prototype._fillSpecifiedTargetAxis=function(e){var i=!1;return w(r0,function(n){var a=this.getReferringComponents(ui(n),BC);if(a.specified){i=!0;var o=new sh;w(a.models,function(s){o.add(s.componentIndex)}),e.set(n,o)}},this),i},t.prototype._fillAutoTargetAxisByOrient=function(e,i){var n=this.ecModel,a=!0;if(a){var o=i==="vertical"?"y":"x",s=n.findComponents({mainType:o+"Axis"});l(s,o)}if(a){var s=n.findComponents({mainType:"singleAxis",filter:function(f){return f.get("orient",!0)===i}});l(s,"single")}function l(u,f){var h=u[0];if(h){var c=new sh;if(c.add(h.componentIndex),e.set(f,c),a=!1,f==="x"||f==="y"){var v=h.getReferringComponents("grid",kt).models[0];v&&w(u,function(p){h.componentIndex!==p.componentIndex&&v===p.getReferringComponents("grid",kt).models[0]&&c.add(p.componentIndex)})}}}a&&w(r0,function(u){if(a){var f=n.findComponents({mainType:ui(u),filter:function(c){return c.get("type",!0)==="category"}});if(f[0]){var h=new sh;h.add(f[0].componentIndex),e.set(u,h),a=!1}}},this)},t.prototype._makeAutoOrientByTargetAxis=function(){var e;return this.eachTargetAxis(function(i){!e&&(e=i)},this),e==="y"?"vertical":"horizontal"},t.prototype._setDefaultThrottle=function(e){if(e.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var i=this.ecModel.option;this.option.throttle=i.animation&&i.animationDurationUpdate>0?100:20}},t.prototype._updateRangeUse=function(e){var i=this._rangePropMode,n=this.get("rangeMode");w([["start","startValue"],["end","endValue"]],function(a,o){var s=e[a[0]]!=null,l=e[a[1]]!=null;s&&!l?i[o]="percent":!s&&l?i[o]="value":n?i[o]=n[o]:s&&(i[o]="percent")})},t.prototype.noTarget=function(){return this._noTarget},t.prototype.getFirstTargetAxisModel=function(){var e;return this.eachTargetAxis(function(i,n){e==null&&(e=this.ecModel.getComponent(ui(i),n))},this),e},t.prototype.eachTargetAxis=function(e,i){this._targetAxisInfoMap.each(function(n,a){w(n.indexList,function(o){e.call(i,a,o)})})},t.prototype.getAxisProxy=function(e,i){var n=this.getAxisModel(e,i);if(n)return n.__dzAxisProxy},t.prototype.getAxisModel=function(e,i){var n=this._targetAxisInfoMap.get(e);if(n&&n.indexMap[i])return this.ecModel.getComponent(ui(e),i)},t.prototype.setRawRange=function(e){var i=this.option,n=this.settledOption;w([["start","startValue"],["end","endValue"]],function(a){(e[a[0]]!=null||e[a[1]]!=null)&&(i[a[0]]=n[a[0]]=e[a[0]],i[a[1]]=n[a[1]]=e[a[1]])},this),this._updateRangeUse(e)},t.prototype.setCalculatedRange=function(e){var i=this.option;w(["start","startValue","end","endValue"],function(n){i[n]=e[n]})},t.prototype.getPercentRange=function(){var e=this.findRepresentativeAxisProxy();if(e)return e.getDataPercentWindow()},t.prototype.getValueRange=function(e,i){if(e==null&&i==null){var n=this.findRepresentativeAxisProxy();if(n)return n.getDataValueWindow()}else return this.getAxisProxy(e,i).getDataValueWindow()},t.prototype.findRepresentativeAxisProxy=function(e){if(e)return e.__dzAxisProxy;for(var i,n=this._targetAxisInfoMap.keys(),a=0;ao[1];if(_&&!S&&!b)return!0;_&&(g=!0),S&&(p=!0),b&&(d=!0)}return g&&p&&d})}else Hn(f,function(v){if(a==="empty")l.setData(u=u.map(v,function(d){return s(d)?d:NaN}));else{var p={};p[v]=o,u.selectRange(p)}});Hn(f,function(v){u.setApproximateExtent(o,v)})}});function s(l){return l>=o[0]&&l<=o[1]}},r.prototype._updateMinMaxSpan=function(){var t=this._minMaxSpan={},e=this._dataZoomModel,i=this._dataExtent;Hn(["min","max"],function(n){var a=e.get(n+"Span"),o=e.get(n+"ValueSpan");o!=null&&(o=this.getAxisModel().axis.scale.parse(o)),o!=null?a=Tt(i[0]+o,i,[0,100],!0):a!=null&&(o=Tt(a,[0,100],i,!0)-i[0]),t[n+"Span"]=a,t[n+"ValueSpan"]=o},this)},r.prototype._setAxisModel=function(){var t=this.getAxisModel(),e=this._percentWindow,i=this._valueWindow;if(e){var n=tc(i,[0,500]);n=Math.min(n,20);var a=t.axis.scale.rawExtentInfo;e[0]!==0&&a.setDeterminedMinMax("min",+i[0].toFixed(n)),e[1]!==100&&a.setDeterminedMinMax("max",+i[1].toFixed(n)),a.freeze()}},r})();function TB(r,t,e){var i=[1/0,-1/0];Hn(e,function(o){zP(i,o.getData(),t)});var n=r.getAxisModel(),a=xx(n.axis.scale,n,i).calculate();return[a.min,a.max]}var CB={getTargetSeries:function(r){function t(n){r.eachComponent("dataZoom",function(a){a.eachTargetAxis(function(o,s){var l=r.getComponent(ui(o),s);n(o,s,l,a)})})}t(function(n,a,o,s){o.__dzAxisProxy=null});var e=[];t(function(n,a,o,s){o.__dzAxisProxy||(o.__dzAxisProxy=new wB(n,a,s,r),e.push(o.__dzAxisProxy))});var i=U();return w(e,function(n){w(n.getTargetSeriesModels(),function(a){i.set(a.uid,a)})}),i},overallReset:function(r,t){r.eachComponent("dataZoom",function(e){e.eachTargetAxis(function(i,n){e.getAxisProxy(i,n).reset(e)}),e.eachTargetAxis(function(i,n){e.getAxisProxy(i,n).filterData(e,t)})}),r.eachComponent("dataZoom",function(e){var i=e.findRepresentativeAxisProxy();if(i){var n=i.getDataPercentWindow(),a=i.getDataValueWindow();e.setCalculatedRange({start:n[0],end:n[1],startValue:a[0],endValue:a[1]})}})}};function AB(r){r.registerAction("dataZoom",function(t,e){var i=SB(e,t);w(i,function(n){n.setRawRange({start:t.start,end:t.end,startValue:t.startValue,endValue:t.endValue})})})}var a0=!1;function Cp(r){a0||(a0=!0,r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,CB),AB(r),r.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}function MB(r){r.registerComponentModel(xB),r.registerComponentView(bB),Cp(r)}var Ke=(function(){function r(){}return r})(),ow={};function Va(r,t){ow[r]=t}function sw(r){return ow[r]}var DB=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.optionUpdated=function(){r.prototype.optionUpdated.apply(this,arguments);var e=this.ecModel;w(this.option.feature,function(i,n){var a=sw(n);a&&(a.getDefaultOption&&(a.defaultOption=a.getDefaultOption(e)),J(i,a.defaultOption))})},t.type="toolbox",t.layoutMode={type:"box",ignoreSize:!0},t.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"}},t})(at);function LB(r,t,e){var i=t.getBoxLayoutParams(),n=t.get("padding"),a={width:e.getWidth(),height:e.getHeight()},o=le(i,a,n);on(t.get("orient"),r,t.get("itemGap"),o.width,o.height),Ic(r,i,a,n)}function lw(r,t){var e=_n(t.get("padding")),i=t.getItemStyle(["color","opacity"]);return i.fill=t.get("backgroundColor"),r=new vt({shape:{x:r.x-e[3],y:r.y-e[0],width:r.width+e[1]+e[3],height:r.height+e[0]+e[2],r:t.get("borderRadius")},style:i,silent:!0,z2:-1}),r}var PB=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.render=function(e,i,n,a){var o=this.group;if(o.removeAll(),!e.get("show"))return;var s=+e.get("itemSize"),l=e.get("orient")==="vertical",u=e.get("feature")||{},f=this._features||(this._features={}),h=[];w(u,function(p,d){h.push(d)}),new jc(this._featureNames||[],h).add(c).update(c).remove(ft(c,null)).execute(),this._featureNames=h;function c(p,d){var g=h[p],y=h[d],m=u[g],_=new _t(m,e,e.ecModel),S;if(a&&a.newTitle!=null&&a.featureName===g&&(m.title=a.newTitle),g&&!y){if(IB(g))S={onclick:_.option.onclick,featureName:g};else{var b=sw(g);if(!b)return;S=new b}f[g]=S}else if(S=f[y],!S)return;S.uid=va("toolbox-feature"),S.model=_,S.ecModel=i,S.api=n;var x=S instanceof Ke;if(!g&&y){x&&S.dispose&&S.dispose(i,n);return}if(!_.get("show")||x&&S.unusable){x&&S.remove&&S.remove(i,n);return}v(_,S,g),_.setIconStatus=function(T,C){var A=this.option,M=this.iconPaths;A.iconStatus=A.iconStatus||{},A.iconStatus[T]=C,M[T]&&(C==="emphasis"?Qn:ta)(M[T])},S instanceof Ke&&S.render&&S.render(_,i,n,a)}function v(p,d,g){var y=p.getModel("iconStyle"),m=p.getModel(["emphasis","iconStyle"]),_=d instanceof Ke&&d.getIcons?d.getIcons():p.get("icon"),S=p.get("title")||{},b,x;G(_)?(b={},b[g]=_):b=_,G(S)?(x={},x[g]=S):x=S;var T=p.iconPaths={};w(b,function(C,A){var M=fa(C,{},{x:-s/2,y:-s/2,width:s,height:s});M.setStyle(y.getItemStyle());var D=M.ensureState("emphasis");D.style=m.getItemStyle();var L=new ct({style:{text:x[A],align:m.get("textAlign"),borderRadius:m.get("textBorderRadius"),padding:m.get("textPadding"),fill:null,font:P1({fontStyle:m.get("textFontStyle"),fontFamily:m.get("textFontFamily"),fontSize:m.get("textFontSize"),fontWeight:m.get("textFontWeight")},i)},ignore:!0});M.setTextContent(L),mn({el:M,componentModel:e,itemName:A,formatterParamsExtra:{title:x[A]}}),M.__title=x[A],M.on("mouseover",function(){var P=m.getItemStyle(),I=l?e.get("right")==null&&e.get("left")!=="right"?"right":"left":e.get("bottom")==null&&e.get("top")!=="bottom"?"bottom":"top";L.setStyle({fill:m.get("textFill")||P.fill||P.stroke||"#000",backgroundColor:m.get("textBackgroundColor")}),M.setTextConfig({position:m.get("textPosition")||I}),L.ignore=!e.get("showTitle"),n.enterEmphasis(this)}).on("mouseout",function(){p.get(["iconStatus",A])!=="emphasis"&&n.leaveEmphasis(this),L.hide()}),(p.get(["iconStatus",A])==="emphasis"?Qn:ta)(M),o.add(M),M.on("click",W(d.onclick,d,i,n,A)),T[A]=M})}LB(o,e,n),o.add(lw(o.getBoundingRect(),e)),l||o.eachChild(function(p){var d=p.__title,g=p.ensureState("emphasis"),y=g.textConfig||(g.textConfig={}),m=p.getTextContent(),_=m&&m.ensureState("emphasis");if(_&&!j(_)&&d){var S=_.style||(_.style={}),b=Go(d,ct.makeFont(S)),x=p.x+o.x,T=p.y+o.y+s,C=!1;T+b.height>n.getHeight()&&(y.position="top",C=!0);var A=C?-5-b.height:s+10;x+b.width/2>n.getWidth()?(y.position=["100%",A],S.align="right"):x-b.width/2<0&&(y.position=[0,A],S.align="left")}})},t.prototype.updateView=function(e,i,n,a){w(this._features,function(o){o instanceof Ke&&o.updateView&&o.updateView(o.model,i,n,a)})},t.prototype.remove=function(e,i){w(this._features,function(n){n instanceof Ke&&n.remove&&n.remove(e,i)}),this.group.removeAll()},t.prototype.dispose=function(e,i){w(this._features,function(n){n instanceof Ke&&n.dispose&&n.dispose(e,i)})},t.type="toolbox",t})(Ct);function IB(r){return r.indexOf("my")===0}var RB=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.onclick=function(e,i){var n=this.model,a=n.get("name")||e.get("title.0.text")||"echarts",o=i.getZr().painter.getType()==="svg",s=o?"svg":n.get("type",!0)||"png",l=i.getConnectedDataURL({type:s,backgroundColor:n.get("backgroundColor",!0)||e.get("backgroundColor")||"#fff",connectedBackgroundColor:n.get("connectedBackgroundColor"),excludeComponents:n.get("excludeComponents"),pixelRatio:n.get("pixelRatio")}),u=tt.browser;if(typeof MouseEvent=="function"&&(u.newEdge||!u.ie&&!u.edge)){var f=document.createElement("a");f.download=a+"."+s,f.target="_blank",f.href=l;var h=new MouseEvent("click",{view:document.defaultView,bubbles:!0,cancelable:!1});f.dispatchEvent(h)}else if(window.navigator.msSaveOrOpenBlob||o){var c=l.split(","),v=c[0].indexOf("base64")>-1,p=o?decodeURIComponent(c[1]):c[1];v&&(p=window.atob(p));var d=a+"."+s;if(window.navigator.msSaveOrOpenBlob){for(var g=p.length,y=new Uint8Array(g);g--;)y[g]=p.charCodeAt(g);var m=new Blob([y]);window.navigator.msSaveOrOpenBlob(m,d)}else{var _=document.createElement("iframe");document.body.appendChild(_);var S=_.contentWindow,b=S.document;b.open("image/svg+xml","replace"),b.write(p),b.close(),S.focus(),b.execCommand("SaveAs",!0,d),document.body.removeChild(_)}}else{var x=n.get("lang"),T='',C=window.open();C.document.write(T),C.document.title=a}},t.getDefaultOption=function(e){var i={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:e.getLocaleModel().get(["toolbox","saveAsImage","title"]),type:"png",connectedBackgroundColor:"#fff",name:"",excludeComponents:["toolbox"],lang:e.getLocaleModel().get(["toolbox","saveAsImage","lang"])};return i},t})(Ke),o0="__ec_magicType_stack__",EB=[["line","bar"],["stack"]],kB=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.getIcons=function(){var e=this.model,i=e.get("icon"),n={};return w(e.get("type"),function(a){i[a]&&(n[a]=i[a])}),n},t.getDefaultOption=function(e){var i={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:e.getLocaleModel().get(["toolbox","magicType","title"]),option:{},seriesIndex:{}};return i},t.prototype.onclick=function(e,i,n){var a=this.model,o=a.get(["seriesIndex",n]);if(s0[n]){var s={series:[]},l=function(h){var c=h.subType,v=h.id,p=s0[n](c,v,h,a);p&&(K(p,h.option),s.series.push(p));var d=h.coordinateSystem;if(d&&d.type==="cartesian2d"&&(n==="line"||n==="bar")){var g=d.getAxesByScale("ordinal")[0];if(g){var y=g.dim,m=y+"Axis",_=h.getReferringComponents(m,kt).models[0],S=_.componentIndex;s[m]=s[m]||[];for(var b=0;b<=S;b++)s[m][S]=s[m][S]||{};s[m][S].boundaryGap=n==="bar"}}};w(EB,function(h){lt(h,n)>=0&&w(h,function(c){a.setIconStatus(c,"normal")})}),a.setIconStatus(n,"emphasis"),e.eachComponent({mainType:"series",query:o==null?null:{seriesIndex:o}},l);var u,f=n;n==="stack"&&(u=J({stack:a.option.title.tiled,tiled:a.option.title.stack},a.option.title),a.get(["iconStatus",n])!=="emphasis"&&(f="tiled")),i.dispatchAction({type:"changeMagicType",currentType:f,newOption:s,newTitle:u,featureName:"magicType"})}},t})(Ke),s0={line:function(r,t,e,i){if(r==="bar")return J({id:t,type:"line",data:e.get("data"),stack:e.get("stack"),markPoint:e.get("markPoint"),markLine:e.get("markLine")},i.get(["option","line"])||{},!0)},bar:function(r,t,e,i){if(r==="line")return J({id:t,type:"bar",data:e.get("data"),stack:e.get("stack"),markPoint:e.get("markPoint"),markLine:e.get("markLine")},i.get(["option","bar"])||{},!0)},stack:function(r,t,e,i){var n=e.get("stack")===o0;if(r==="line"||r==="bar")return i.setIconStatus("stack",n?"normal":"emphasis"),J({id:t,stack:n?"":o0},i.get(["option","stack"])||{},!0)}};ar({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(r,t){t.mergeOption(r.newOption)});var Pu=new Array(60).join("-"),oa=" ";function OB(r){var t={},e=[],i=[];return r.eachRawSeries(function(n){var a=n.coordinateSystem;if(a&&(a.type==="cartesian2d"||a.type==="polar")){var o=a.getBaseAxis();if(o.type==="category"){var s=o.dim+"_"+o.index;t[s]||(t[s]={categoryAxis:o,valueAxis:a.getOtherAxis(o),series:[]},i.push({axisDim:o.dim,axisIndex:o.index})),t[s].series.push(n)}else e.push(n)}else e.push(n)}),{seriesGroupByCategoryAxis:t,other:e,meta:i}}function BB(r){var t=[];return w(r,function(e,i){var n=e.categoryAxis,a=e.valueAxis,o=a.dim,s=[" "].concat(F(e.series,function(v){return v.name})),l=[n.model.getCategories()];w(e.series,function(v){var p=v.getRawData();l.push(v.getRawData().mapArray(p.mapDimension(o),function(d){return d}))});for(var u=[s.join(oa)],f=0;f=0)return!0}var Ev=new RegExp("["+oa+"]+","g");function VB(r){for(var t=r.split(/\n+/g),e=Wl(t.shift()).split(Ev),i=[],n=F(e,function(l){return{name:l,data:[]}}),a=0;a=0;a--){var o=e[a];if(o[n])break}if(a<0){var s=r.queryComponents({mainType:"dataZoom",subType:"select",id:n})[0];if(s){var l=s.getPercentRange();e[0][n]={dataZoomId:n,start:l[0],end:l[1]}}}}),e.push(t)}function XB(r){var t=Ap(r),e=t[t.length-1];t.length>1&&t.pop();var i={};return uw(e,function(n,a){for(var o=t.length-1;o>=0;o--)if(n=t[o][a],n){i[a]=n;break}}),i}function ZB(r){fw(r).snapshots=null}function $B(r){return Ap(r).length}function Ap(r){var t=fw(r);return t.snapshots||(t.snapshots=[{}]),t.snapshots}var qB=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.onclick=function(e,i){ZB(e),i.dispatchAction({type:"restore",from:this.uid})},t.getDefaultOption=function(e){var i={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:e.getLocaleModel().get(["toolbox","restore","title"])};return i},t})(Ke);ar({type:"restore",event:"restore",update:"prepareAndUpdate"},function(r,t){t.resetOption("recreate")});var KB=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],hw=(function(){function r(t,e,i){var n=this;this._targetInfoList=[];var a=l0(e,t);w(JB,function(o,s){(!i||!i.include||lt(i.include,s)>=0)&&o(a,n._targetInfoList)})}return r.prototype.setOutputRanges=function(t,e){return this.matchOutputRanges(t,e,function(i,n,a){if((i.coordRanges||(i.coordRanges=[])).push(n),!i.coordRange){i.coordRange=n;var o=lh[i.brushType](0,a,n);i.__rangeOffset={offset:v0[i.brushType](o.values,i.range,[1,1]),xyMinMax:o.xyMinMax}}}),t},r.prototype.matchOutputRanges=function(t,e,i){w(t,function(n){var a=this.findTargetInfo(n,e);a&&a!==!0&&w(a.coordSyses,function(o){var s=lh[n.brushType](1,o,n.range,!0);i(n,s.values,o,e)})},this)},r.prototype.setInputRanges=function(t,e){w(t,function(i){var n=this.findTargetInfo(i,e);if(i.range=i.range||[],n&&n!==!0){i.panelId=n.panelId;var a=lh[i.brushType](0,n.coordSys,i.coordRange),o=i.__rangeOffset;i.range=o?v0[i.brushType](a.values,o.offset,jB(a.xyMinMax,o.xyMinMax)):a.values}},this)},r.prototype.makePanelOpts=function(t,e){return F(this._targetInfoList,function(i){var n=i.getPanelRect();return{panelId:i.panelId,defaultBrushType:e?e(i):null,clipPath:kb(n),isTargetByCursor:Bb(n,t,i.coordSysModel),getLinearBrushOtherExtent:Ob(n)}})},r.prototype.controlSeries=function(t,e,i){var n=this.findTargetInfo(t,i);return n===!0||n&<(n.coordSyses,e.coordinateSystem)>=0},r.prototype.findTargetInfo=function(t,e){for(var i=this._targetInfoList,n=l0(e,t),a=0;ar[1]&&r.reverse(),r}function l0(r,t){return no(r,t,{includeMainTypes:KB})}var JB={grid:function(r,t){var e=r.xAxisModels,i=r.yAxisModels,n=r.gridModels,a=U(),o={},s={};!e&&!i&&!n||(w(e,function(l){var u=l.axis.grid.model;a.set(u.id,u),o[u.id]=!0}),w(i,function(l){var u=l.axis.grid.model;a.set(u.id,u),s[u.id]=!0}),w(n,function(l){a.set(l.id,l),o[l.id]=!0,s[l.id]=!0}),a.each(function(l){var u=l.coordinateSystem,f=[];w(u.getCartesians(),function(h,c){(lt(e,h.getAxis("x").model)>=0||lt(i,h.getAxis("y").model)>=0)&&f.push(h)}),t.push({panelId:"grid--"+l.id,gridModel:l,coordSysModel:l,coordSys:f[0],coordSyses:f,getPanelRect:f0.grid,xAxisDeclared:o[l.id],yAxisDeclared:s[l.id]})}))},geo:function(r,t){w(r.geoModels,function(e){var i=e.coordinateSystem;t.push({panelId:"geo--"+e.id,geoModel:e,coordSysModel:e,coordSys:i,coordSyses:[i],getPanelRect:f0.geo})})}},u0=[function(r,t){var e=r.xAxisModel,i=r.yAxisModel,n=r.gridModel;return!n&&e&&(n=e.axis.grid.model),!n&&i&&(n=i.axis.grid.model),n&&n===t.gridModel},function(r,t){var e=r.geoModel;return e&&e===t.geoModel}],f0={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var r=this.coordSys,t=r.getBoundingRect().clone();return t.applyTransform(vi(r)),t}},lh={lineX:ft(h0,0),lineY:ft(h0,1),rect:function(r,t,e,i){var n=r?t.pointToData([e[0][0],e[1][0]],i):t.dataToPoint([e[0][0],e[1][0]],i),a=r?t.pointToData([e[0][1],e[1][1]],i):t.dataToPoint([e[0][1],e[1][1]],i),o=[kv([n[0],a[0]]),kv([n[1],a[1]])];return{values:o,xyMinMax:o}},polygon:function(r,t,e,i){var n=[[1/0,-1/0],[1/0,-1/0]],a=F(e,function(o){var s=r?t.pointToData(o,i):t.dataToPoint(o,i);return n[0][0]=Math.min(n[0][0],s[0]),n[1][0]=Math.min(n[1][0],s[1]),n[0][1]=Math.max(n[0][1],s[0]),n[1][1]=Math.max(n[1][1],s[1]),s});return{values:a,xyMinMax:n}}};function h0(r,t,e,i){var n=e.getAxis(["x","y"][r]),a=kv(F([0,1],function(s){return t?n.coordToData(n.toLocalCoord(i[s]),!0):n.toGlobalCoord(n.dataToCoord(i[s]))})),o=[];return o[r]=a,o[1-r]=[NaN,NaN],{values:a,xyMinMax:o}}var v0={lineX:ft(c0,0),lineY:ft(c0,1),rect:function(r,t,e){return[[r[0][0]-e[0]*t[0][0],r[0][1]-e[0]*t[0][1]],[r[1][0]-e[1]*t[1][0],r[1][1]-e[1]*t[1][1]]]},polygon:function(r,t,e){return F(r,function(i,n){return[i[0]-e[0]*t[n][0],i[1]-e[1]*t[n][1]]})}};function c0(r,t,e,i){return[t[0]-i[r]*e[0],t[1]-i[r]*e[1]]}function jB(r,t){var e=p0(r),i=p0(t),n=[e[0]/i[0],e[1]/i[1]];return isNaN(n[0])&&(n[0]=1),isNaN(n[1])&&(n[1]=1),n}function p0(r){return r?[r[0][1]-r[0][0],r[1][1]-r[1][0]]:[NaN,NaN]}var Ov=w,QB=IC("toolbox-dataZoom_"),t5=(function(r){E(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.render=function(e,i,n,a){this._brushController||(this._brushController=new bb(n.getZr()),this._brushController.on("brush",W(this._onBrush,this)).mount()),i5(e,i,this,a,n),r5(e,i)},t.prototype.onclick=function(e,i,n){e5[n].call(this)},t.prototype.remove=function(e,i){this._brushController&&this._brushController.unmount()},t.prototype.dispose=function(e,i){this._brushController&&this._brushController.dispose()},t.prototype._onBrush=function(e){var i=e.areas;if(!e.isEnd||!i.length)return;var n={},a=this.ecModel;this._brushController.updateCovers([]);var o=new hw(Mp(this.model),a,{include:["grid"]});o.matchOutputRanges(i,a,function(u,f,h){if(h.type==="cartesian2d"){var c=u.brushType;c==="rect"?(s("x",h,f[0]),s("y",h,f[1])):s({lineX:"x",lineY:"y"}[c],h,f)}}),UB(a,n),this._dispatchZoomAction(n);function s(u,f,h){var c=f.getAxis(u),v=c.model,p=l(u,v,a),d=p.findRepresentativeAxisProxy(v).getMinMaxSpan();(d.minValueSpan!=null||d.maxValueSpan!=null)&&(h=Sn(0,h.slice(),c.scale.getExtent(),0,d.minValueSpan,d.maxValueSpan)),p&&(n[p.id]={dataZoomId:p.id,startValue:h[0],endValue:h[1]})}function l(u,f,h){var c;return h.eachComponent({mainType:"dataZoom",subType:"select"},function(v){var p=v.getAxisModel(u,f.componentIndex);p&&(c=v)}),c}},t.prototype._dispatchZoomAction=function(e){var i=[];Ov(e,function(n,a){i.push(q(n))}),i.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:i})},t.getDefaultOption=function(e){var i={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:e.getLocaleModel().get(["toolbox","dataZoom","title"]),brushStyle:{borderWidth:0,color:"rgba(210,219,238,0.2)"}};return i},t})(Ke),e5={zoom:function(){var r=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:r})},back:function(){this._dispatchZoomAction(XB(this.ecModel))}};function Mp(r){var t={xAxisIndex:r.get("xAxisIndex",!0),yAxisIndex:r.get("yAxisIndex",!0),xAxisId:r.get("xAxisId",!0),yAxisId:r.get("yAxisId",!0)};return t.xAxisIndex==null&&t.xAxisId==null&&(t.xAxisIndex="all"),t.yAxisIndex==null&&t.yAxisId==null&&(t.yAxisIndex="all"),t}function r5(r,t){r.setIconStatus("back",$B(t)>1?"emphasis":"normal")}function i5(r,t,e,i,n){var a=e._isZoomActive;i&&i.type==="takeGlobalCursor"&&(a=i.key==="dataZoomSelect"?i.dataZoomSelectActive:!1),e._isZoomActive=a,r.setIconStatus("zoom",a?"emphasis":"normal");var o=new hw(Mp(r),t,{include:["grid"]}),s=o.makePanelOpts(n,function(l){return l.xAxisDeclared&&!l.yAxisDeclared?"lineX":!l.xAxisDeclared&&l.yAxisDeclared?"lineY":"rect"});e._brushController.setPanels(s).enableBrush(a&&s.length?{brushType:"auto",brushStyle:r.getModel("brushStyle").getItemStyle()}:!1)}lD("dataZoom",function(r){var t=r.getComponent("toolbox",0),e=["feature","dataZoom"];if(!t||t.get(e)==null)return;var i=t.getModel(e),n=[],a=Mp(i),o=no(r,a);Ov(o.xAxisModels,function(l){return s(l,"xAxis","xAxisIndex")}),Ov(o.yAxisModels,function(l){return s(l,"yAxis","yAxisIndex")});function s(l,u,f){var h=l.componentIndex,c={type:"select",$fromToolbox:!0,filterMode:i.get("filterMode",!0)||"filter",id:QB+u+h};c[f]=h,n.push(c)}return n});function n5(r){r.registerComponentModel(DB),r.registerComponentView(PB),Va("saveAsImage",RB),Va("magicType",kB),Va("dataView",WB),Va("dataZoom",t5),Va("restore",qB),Ht(MB)}var a5=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="tooltip",t.dependencies=["axisPointer"],t.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}},t})(at);function vw(r){var t=r.get("confine");return t!=null?!!t:r.get("renderMode")==="richText"}function cw(r){if(tt.domSupported){for(var t=document.documentElement.style,e=0,i=r.length;e-1?(s+="top:50%",l+="translateY(-50%) rotate("+(u=a==="left"?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(u=a==="top"?225:45)+"deg)");var f=u*Math.PI/180,h=o+n,c=h*Math.abs(Math.cos(f))+h*Math.abs(Math.sin(f)),v=Math.round(((c-Math.SQRT2*n)/2+Math.SQRT2*n-(c-h)/2)*100)/100;s+=";"+a+":-"+v+"px";var p=t+" solid "+n+"px;",d=["position:absolute;width:"+o+"px;height:"+o+"px;z-index:-1;",s+";"+l+";","border-bottom:"+p,"border-right:"+p,"background-color:"+i+";"];return'
'}function v5(r,t){var e="cubic-bezier(0.23,1,0.32,1)",i=" "+r/2+"s "+e,n="opacity"+i+",visibility"+i;return t||(i=" "+r+"s "+e,n+=tt.transformSupported?","+Dp+i:",left"+i+",top"+i),l5+":"+n}function d0(r,t,e){var i=r.toFixed(0)+"px",n=t.toFixed(0)+"px";if(!tt.transformSupported)return e?"top:"+n+";left:"+i+";":[["top",n],["left",i]];var a=tt.transform3dSupported,o="translate"+(a?"3d":"")+"("+i+","+n+(a?",0":"")+")";return e?"top:0;left:0;"+Dp+":"+o+";":[["top",0],["left",0],[pw,o]]}function c5(r){var t=[],e=r.get("fontSize"),i=r.getTextColor();i&&t.push("color:"+i),t.push("font:"+r.getFont());var n=rt(r.get("lineHeight"),Math.round(e*3/2));e&&t.push("line-height:"+n+"px");var a=r.get("textShadowColor"),o=r.get("textShadowBlur")||0,s=r.get("textShadowOffsetX")||0,l=r.get("textShadowOffsetY")||0;return a&&o&&t.push("text-shadow:"+s+"px "+l+"px "+o+"px "+a),w(["decoration","align"],function(u){var f=r.get(u);f&&t.push("text-"+u+":"+f)}),t.join(";")}function p5(r,t,e){var i=[],n=r.get("transitionDuration"),a=r.get("backgroundColor"),o=r.get("shadowBlur"),s=r.get("shadowColor"),l=r.get("shadowOffsetX"),u=r.get("shadowOffsetY"),f=r.getModel("textStyle"),h=_S(r,"html"),c=l+"px "+u+"px "+o+"px "+s;return i.push("box-shadow:"+c),t&&n&&i.push(v5(n,e)),a&&i.push("background-color:"+a),w(["width","color","radius"],function(v){var p="border-"+v,d=Dc(p),g=r.get(d);g!=null&&i.push(p+":"+g+(v==="color"?"":"px"))}),i.push(c5(f)),h!=null&&i.push("padding:"+_n(h).join("px ")+"px"),i.join(";")+";"}function g0(r,t,e,i,n){var a=t&&t.painter;if(e){var o=a&&a.getViewportRoot();o&&iT(r,o,e,i,n)}else{r[0]=i,r[1]=n;var s=a&&a.getViewportRootOffset();s&&(r[0]+=s.offsetLeft,r[1]+=s.offsetTop)}r[2]=r[0]/t.getWidth(),r[3]=r[1]/t.getHeight()}var d5=(function(){function r(t,e){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,tt.wxa)return null;var i=document.createElement("div");i.domBelongToZr=!0,this.el=i;var n=this._zr=t.getZr(),a=e.appendTo,o=a&&(G(a)?document.querySelector(a):hn(a)?a:j(a)&&a(t.getDom()));g0(this._styleCoord,n,o,t.getWidth()/2,t.getHeight()/2),(o||t.getDom()).appendChild(i),this._api=t,this._container=o;var s=this;i.onmouseenter=function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0},i.onmousemove=function(l){if(l=l||window.event,!s._enterable){var u=n.handler,f=n.painter.getViewportRoot();Ie(f,l,!0),u.dispatch("mousemove",l)}},i.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return r.prototype.update=function(t){if(!this._container){var e=this._api.getDom(),i=s5(e,"position"),n=e.style;n.position!=="absolute"&&i!=="absolute"&&(n.position="relative")}var a=t.get("alwaysShowContent");a&&this._moveIfResized(),this._alwaysShowContent=a,this.el.className=t.get("className")||""},r.prototype.show=function(t,e){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var i=this.el,n=i.style,a=this._styleCoord;i.innerHTML?n.cssText=u5+p5(t,!this._firstShow,this._longHide)+d0(a[0],a[1],!0)+("border-color:"+cn(e)+";")+(t.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):n.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},r.prototype.setContent=function(t,e,i,n,a){var o=this.el;if(t==null){o.innerHTML="";return}var s="";if(G(a)&&i.get("trigger")==="item"&&!vw(i)&&(s=h5(i,n,a)),G(t))o.innerHTML=t+s;else if(t){o.innerHTML="",z(t)||(t=[t]);for(var l=0;l=0?this._tryShow(a,o):n==="leave"&&this._hide(o))},this))},t.prototype._keepShow=function(){var e=this._tooltipModel,i=this._ecModel,n=this._api,a=e.get("triggerOn");if(this._lastX!=null&&this._lastY!=null&&a!=="none"&&a!=="click"){var o=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!n.isDisposed()&&o.manuallyShowTip(e,i,n,{x:o._lastX,y:o._lastY,dataByCoordSys:o._lastDataByCoordSys})})}},t.prototype.manuallyShowTip=function(e,i,n,a){if(!(a.from===this.uid||tt.node||!n.getDom())){var o=_0(a,n);this._ticket="";var s=a.dataByCoordSys,l=b5(a,i,n);if(l){var u=l.el.getBoundingRect().clone();u.applyTransform(l.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:l.el,position:a.position,positionDefault:"bottom"},o)}else if(a.tooltip&&a.x!=null&&a.y!=null){var f=y5;f.x=a.x,f.y=a.y,f.update(),ot(f).tooltipConfig={name:null,option:a.tooltip},this._tryShow({offsetX:a.x,offsetY:a.y,target:f},o)}else if(s)this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,dataByCoordSys:s,tooltipOption:a.tooltipOption},o);else if(a.seriesIndex!=null){if(this._manuallyAxisShowTip(e,i,n,a))return;var h=tw(a,i),c=h.point[0],v=h.point[1];c!=null&&v!=null&&this._tryShow({offsetX:c,offsetY:v,target:h.el,position:a.position,positionDefault:"bottom"},o)}else a.x!=null&&a.y!=null&&(n.dispatchAction({type:"updateAxisPointer",x:a.x,y:a.y}),this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,target:n.getZr().findHover(a.x,a.y).target},o))}},t.prototype.manuallyHideTip=function(e,i,n,a){var o=this._tooltipContent;this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,a.from!==this.uid&&this._hide(_0(a,n))},t.prototype._manuallyAxisShowTip=function(e,i,n,a){var o=a.seriesIndex,s=a.dataIndex,l=i.getComponent("axisPointer").coordSysAxesInfo;if(!(o==null||s==null||l==null)){var u=i.getSeriesByIndex(o);if(u){var f=u.getData(),h=Ga([f.getItemModel(s),u,(u.coordinateSystem||{}).model],this._tooltipModel);if(h.get("trigger")==="axis")return n.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:s,position:a.position}),!0}}},t.prototype._tryShow=function(e,i){var n=e.target,a=this._tooltipModel;if(a){this._lastX=e.offsetX,this._lastY=e.offsetY;var o=e.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,e);else if(n){var s=ot(n);if(s.ssrType==="legend")return;this._lastDataByCoordSys=null;var l,u;ji(n,function(f){if(ot(f).dataIndex!=null)return l=f,!0;if(ot(f).tooltipConfig!=null)return u=f,!0},!0),l?this._showSeriesItemTooltip(e,l,i):u?this._showComponentItemTooltip(e,u,i):this._hide(i)}else this._lastDataByCoordSys=null,this._hide(i)}},t.prototype._showOrMove=function(e,i){var n=e.get("showDelay");i=W(i,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(i,n):i()},t.prototype._showAxisTooltip=function(e,i){var n=this._ecModel,a=this._tooltipModel,o=[i.offsetX,i.offsetY],s=Ga([i.tooltipOption],a),l=this._renderMode,u=[],f=br("section",{blocks:[],noHeader:!0}),h=[],c=new Tf;w(e,function(m){w(m.dataByAxis,function(_){var S=n.getComponent(_.axisDim+"Axis",_.axisIndex),b=_.value;if(!(!S||b==null)){var x=Kb(b,S.axis,n,_.seriesDataIndices,_.valueLabelOpt),T=br("section",{header:x,noHeader:!ze(x),sortBlocks:!0,blocks:[]});f.blocks.push(T),w(_.seriesDataIndices,function(C){var A=n.getSeriesByIndex(C.seriesIndex),M=C.dataIndexInside,D=A.getDataParams(M);if(!(D.dataIndex<0)){D.axisDim=_.axisDim,D.axisIndex=_.axisIndex,D.axisType=_.axisType,D.axisId=_.axisId,D.axisValue=ip(S.axis,{value:b}),D.axisValueLabel=x,D.marker=c.makeTooltipMarker("item",cn(D.color),l);var L=gg(A.formatTooltip(M,!0,null)),P=L.frag;if(P){var I=Ga([A],a).get("valueFormatter");T.blocks.push(I?O({valueFormatter:I},P):P)}L.text&&h.push(L.text),u.push(D)}})}})}),f.blocks.reverse(),h.reverse();var v=i.position,p=s.get("order"),d=xg(f,c,l,p,n.get("useUTC"),s.get("textStyle"));d&&h.unshift(d);var g=l==="richText"?` `:"
",y=h.join(g);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(e,u)?this._updatePosition(s,v,o[0],o[1],this._tooltipContent,u):this._showTooltipContent(s,y,u,Math.random()+"",o[0],o[1],v,null,c)})},t.prototype._showSeriesItemTooltip=function(e,i,n){var a=this._ecModel,o=ot(i),s=o.seriesIndex,l=a.getSeriesByIndex(s),u=o.dataModel||l,f=o.dataIndex,h=o.dataType,c=u.getData(h),v=this._renderMode,p=e.positionDefault,d=Ga([c.getItemModel(f),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,p?{position:p}:null),g=d.get("trigger");if(!(g!=null&&g!=="item")){var y=u.getDataParams(f,h),m=new Tf;y.marker=m.makeTooltipMarker("item",cn(y.color),v);var _=gg(u.formatTooltip(f,!1,h)),S=d.get("order"),b=d.get("valueFormatter"),x=_.frag,T=x?xg(b?O({valueFormatter:b},x):x,m,v,S,a.get("useUTC"),d.get("textStyle")):_.text,C="item_"+u.name+"_"+f;this._showOrMove(d,function(){this._showTooltipContent(d,T,y,C,e.offsetX,e.offsetY,e.position,e.target,m)}),n({type:"showTip",dataIndexInside:f,dataIndex:c.getRawIndex(f),seriesIndex:s,from:this.uid})}},t.prototype._showComponentItemTooltip=function(e,i,n){var a=this._renderMode==="html",o=ot(i),s=o.tooltipConfig,l=s.option||{},u=l.encodeHTMLContent;if(G(l)){var f=l;l={content:f,formatter:f},u=!0}u&&a&&l.content&&(l=q(l),l.content=ne(l.content));var h=[l],c=this._ecModel.getComponent(o.componentMainType,o.componentIndex);c&&h.push(c),h.push({formatter:l.content});var v=e.positionDefault,p=Ga(h,this._tooltipModel,v?{position:v}:null),d=p.get("content"),g=Math.random()+"",y=new Tf;this._showOrMove(p,function(){var m=q(p.get("formatterParams")||{});this._showTooltipContent(p,d,m,g,e.offsetX,e.offsetY,e.position,i,y)}),n({type:"showTip",from:this.uid})},t.prototype._showTooltipContent=function(e,i,n,a,o,s,l,u,f){if(this._ticket="",!(!e.get("showContent")||!e.get("show"))){var h=this._tooltipContent;h.setEnterable(e.get("enterable"));var c=e.get("formatter");l=l||e.get("position");var v=i,p=this._getNearestPoint([o,s],n,e.get("trigger"),e.get("borderColor")),d=p.color;if(c)if(G(c)){var g=e.ecModel.get("useUTC"),y=z(n)?n[0]:n,m=y&&y.axisType&&y.axisType.indexOf("time")>=0;v=c,m&&(v=Zo(y.axisValue,v,g)),v=Lc(v,n,!0)}else if(j(c)){var _=W(function(S,b){S===this._ticket&&(h.setContent(b,f,e,d,l),this._updatePosition(e,l,o,s,h,n,u))},this);this._ticket=a,v=c(n,a,_)}else v=c;h.setContent(v,f,e,d,l),h.show(e,d),this._updatePosition(e,l,o,s,h,n,u)}},t.prototype._getNearestPoint=function(e,i,n,a){if(n==="axis"||z(i))return{color:a||(this._renderMode==="html"?"#fff":"none")};if(!z(i))return{color:a||i.color||i.borderColor}},t.prototype._updatePosition=function(e,i,n,a,o,s,l){var u=this._api.getWidth(),f=this._api.getHeight();i=i||e.get("position");var h=o.getSize(),c=e.get("align"),v=e.get("verticalAlign"),p=l&&l.getBoundingRect().clone();if(l&&p.applyTransform(l.transform),j(i)&&(i=i([n,a],s,o.el,p,{viewSize:[u,f],contentSize:h.slice()})),z(i))n=Q(i[0],u),a=Q(i[1],f);else if(X(i)){var d=i;d.width=h[0],d.height=h[1];var g=le(d,{width:u,height:f});n=g.x,a=g.y,c=null,v=null}else if(G(i)&&l){var y=x5(i,p,h,e.get("borderWidth"));n=y[0],a=y[1]}else{var y=_5(n,a,o,u,f,c?null:20,v?null:20);n=y[0],a=y[1]}if(c&&(n-=S0(c)?h[0]/2:c==="right"?h[0]:0),v&&(a-=S0(v)?h[1]/2:v==="bottom"?h[1]:0),vw(e)){var y=S5(n,a,o,u,f);n=y[0],a=y[1]}o.moveTo(n,a)},t.prototype._updateContentNotChangedOnAxis=function(e,i){var n=this._lastDataByCoordSys,a=this._cbParamsList,o=!!n&&n.length===e.length;return o&&w(n,function(s,l){var u=s.dataByAxis||[],f=e[l]||{},h=f.dataByAxis||[];o=o&&u.length===h.length,o&&w(u,function(c,v){var p=h[v]||{},d=c.seriesDataIndices||[],g=p.seriesDataIndices||[];o=o&&c.value===p.value&&c.axisType===p.axisType&&c.axisId===p.axisId&&d.length===g.length,o&&w(d,function(y,m){var _=g[m];o=o&&y.seriesIndex===_.seriesIndex&&y.dataIndex===_.dataIndex}),a&&w(c.seriesDataIndices,function(y){var m=y.seriesIndex,_=i[m],S=a[m];_&&S&&S.data!==_.data&&(o=!1)})})}),this._lastDataByCoordSys=e,this._cbParamsList=i,!!o},t.prototype._hide=function(e){this._lastDataByCoordSys=null,e({type:"hideTip",from:this.uid})},t.prototype.dispose=function(e,i){tt.node||!i.getDom()||(Mo(this,"_updatePosition"),this._tooltipContent.dispose(),Iv("itemTooltip",i))},t.type="tooltip",t})(Ct);function Ga(r,t,e){var i=t.ecModel,n;e?(n=new _t(e,i,i),n=new _t(t.option,n,i)):n=t;for(var a=r.length-1;a>=0;a--){var o=r[a];o&&(o instanceof _t&&(o=o.get("tooltip",!0)),G(o)&&(o={formatter:o}),o&&(n=new _t(o,n,i)))}return n}function _0(r,t){return r.dispatchAction||W(t.dispatchAction,t)}function _5(r,t,e,i,n,a,o){var s=e.getSize(),l=s[0],u=s[1];return a!=null&&(r+l+a+2>i?r-=l+a:r+=a),o!=null&&(t+u+o>n?t-=u+o:t+=o),[r,t]}function S5(r,t,e,i,n){var a=e.getSize(),o=a[0],s=a[1];return r=Math.min(r+o,i)-o,t=Math.min(t+s,n)-s,r=Math.max(r,0),t=Math.max(t,0),[r,t]}function x5(r,t,e,i){var n=e[0],a=e[1],o=Math.ceil(Math.SQRT2*i)+8,s=0,l=0,u=t.width,f=t.height;switch(r){case"inside":s=t.x+u/2-n/2,l=t.y+f/2-a/2;break;case"top":s=t.x+u/2-n/2,l=t.y-a-o;break;case"bottom":s=t.x+u/2-n/2,l=t.y+f+o;break;case"left":s=t.x-n-o,l=t.y+f/2-a/2;break;case"right":s=t.x+u+o,l=t.y+f/2-a/2}return[s,l]}function S0(r){return r==="center"||r==="middle"}function b5(r,t,e){var i=ac(r).queryOptionMap,n=i.keys()[0];if(!(!n||n==="series")){var a=Ho(t,n,i.get(n),{useDefault:!1,enableAll:!1,enableNone:!1}),o=a.models[0];if(o){var s=e.getViewOfComponentModel(o),l;if(s.group.traverse(function(u){var f=ot(u).tooltipConfig;if(f&&f.name===r.name)return l=u,!0}),l)return{componentMainType:n,componentIndex:o.componentIndex,el:l}}}}function w5(r){Ht(Sp),r.registerComponentModel(a5),r.registerComponentView(m5),r.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},Vt),r.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},Vt)}var x0=w;function b0(r){if(r){for(var t in r)if(r.hasOwnProperty(t))return!0}}function w0(r,t,e){var i={};return x0(t,function(a){var o=i[a]=n();x0(r[a],function(s,l){if(Gt.isValidType(l)){var u={type:l,visual:s};e&&e(u,a),o[l]=new Gt(u),l==="opacity"&&(u=q(u),u.type="colorAlpha",o.__hidden.__alphaForOpacity=new Gt(u))}})}),i;function n(){var a=function(){};a.prototype.__hidden=a.prototype;var o=new a;return o}}function T5(r,t,e){var i;w(e,function(n){t.hasOwnProperty(n)&&b0(t[n])&&(i=!0)}),i&&w(e,function(n){t.hasOwnProperty(n)&&b0(t[n])?r[n]=q(t[n]):delete r[n]})}function _z(r,t,e,i,n,a){var o={};w(r,function(h){var c=Gt.prepareVisualTypes(t[h]);o[h]=c});var s;function l(h){return Vc(e,s,h)}function u(h,c){LS(e,s,h,c)}e.each(f);function f(h,c){s=h;var v=e.getRawDataItem(s);if(!(v&&v.visualMap===!1))for(var p=i.call(n,h),d=t[p],g=o[p],y=0,m=g.length;y=i&&(e=i-1),e<0&&(e=0)),this.option.currentIndex=e},t.prototype.getCurrentIndex=function(){return this.option.currentIndex},t.prototype.isIndexMax=function(){return this.getCurrentIndex()>=this._data.count()-1},t.prototype.setPlayState=function(e){this.option.autoPlay=!!e},t.prototype.getPlayState=function(){return!!this.option.autoPlay},t.prototype._initData=function(){var e=this.option,i=e.data||[],n=e.axisType,a=this._names=[],o;n==="category"?(o=[],w(i,function(u,f){var h=qt(la(u),""),c;X(u)?(c=q(u),c.value=f):c=f,o.push(c),a.push(h)})):o=i;var s={category:"ordinal",time:"time",value:"number"}[n]||"number",l=this._data=new Su([{name:"value",type:s}],this);l.initData(o,a)},t.prototype.getData=function(){return this._data},t.prototype.getCategories=function(){if(this.get("axisType")==="category")return this._names.slice()},t.type="timeline",t.defaultOption={z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]},t})(at),gw=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="timeline.slider",t.defaultOption=_i(T0.defaultOption,{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"circle",symbolSize:12,lineStyle:{show:!0,width:2,color:"#DAE1F5"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#A4B1D7"},itemStyle:{color:"#A4B1D7",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:15,color:"#316bf3",borderColor:"#fff",borderWidth:2,shadowBlur:2,shadowOffsetX:1,shadowOffsetY:1,shadowColor:"rgba(0, 0, 0, 0.3)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:24,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"M2,18.5A1.52,1.52,0,0,1,.92,18a1.49,1.49,0,0,1,0-2.12L7.81,9.36,1,3.11A1.5,1.5,0,1,1,3,.89l8,7.34a1.48,1.48,0,0,1,.49,1.09,1.51,1.51,0,0,1-.46,1.1L3,18.08A1.5,1.5,0,0,1,2,18.5Z",prevIcon:"M10,.5A1.52,1.52,0,0,1,11.08,1a1.49,1.49,0,0,1,0,2.12L4.19,9.64,11,15.89a1.5,1.5,0,1,1-2,2.22L1,10.77A1.48,1.48,0,0,1,.5,9.68,1.51,1.51,0,0,1,1,8.58L9,.92A1.5,1.5,0,0,1,10,.5Z",prevBtnSize:18,nextBtnSize:18,color:"#A4B1D7",borderColor:"#A4B1D7",borderWidth:1},emphasis:{label:{show:!0,color:"#6f778d"},itemStyle:{color:"#316BF3"},controlStyle:{color:"#316BF3",borderColor:"#316BF3",borderWidth:2}},progress:{lineStyle:{color:"#316BF3"},itemStyle:{color:"#316BF3"},label:{color:"#6f778d"}},data:[]}),t})(T0);Wt(gw,lS.prototype);var L5=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="timeline",t})(Ct),P5=(function(r){E(t,r);function t(e,i,n,a){var o=r.call(this,e,i,n)||this;return o.type=a||"value",o}return t.prototype.getLabelModel=function(){return this.model.getModel("label")},t.prototype.isHorizontal=function(){return this.model.get("orient")==="horizontal"},t})(or),uh=Math.PI,C0=St(),I5=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(e,i){this.api=i},t.prototype.render=function(e,i,n){if(this.model=e,this.api=n,this.ecModel=i,this.group.removeAll(),e.get("show",!0)){var a=this._layout(e,n),o=this._createGroup("_mainGroup"),s=this._createGroup("_labelGroup"),l=this._axis=this._createAxis(a,e);e.formatTooltip=function(u){var f=l.scale.getLabel({value:u});return br("nameValue",{noName:!0,value:f})},w(["AxisLine","AxisTick","Control","CurrentPointer"],function(u){this["_render"+u](a,o,l,e)},this),this._renderAxisLabel(a,s,l,e),this._position(a,e)}this._doPlayStop(),this._updateTicksStatus()},t.prototype.remove=function(){this._clearTimer(),this.group.removeAll()},t.prototype.dispose=function(){this._clearTimer()},t.prototype._layout=function(e,i){var n=e.get(["label","position"]),a=e.get("orient"),o=E5(e,i),s;n==null||n==="auto"?s=a==="horizontal"?o.y+o.height/2=0||s==="+"?"left":"right"},u={horizontal:s>=0||s==="+"?"top":"bottom",vertical:"middle"},f={horizontal:0,vertical:uh/2},h=a==="vertical"?o.height:o.width,c=e.getModel("controlStyle"),v=c.get("show",!0),p=v?c.get("itemSize"):0,d=v?c.get("itemGap"):0,g=p+d,y=e.get(["label","rotate"])||0;y=y*uh/180;var m,_,S,b=c.get("position",!0),x=v&&c.get("showPlayBtn",!0),T=v&&c.get("showPrevBtn",!0),C=v&&c.get("showNextBtn",!0),A=0,M=h;b==="left"||b==="bottom"?(x&&(m=[0,0],A+=g),T&&(_=[A,0],A+=g),C&&(S=[M-p,0],M-=g)):(x&&(m=[M-p,0],M-=g),T&&(_=[0,0],A+=g),C&&(S=[M-p,0],M-=g));var D=[A,M];return e.get("inverse")&&D.reverse(),{viewRect:o,mainLength:h,orient:a,rotation:f[a],labelRotation:y,labelPosOpt:s,labelAlign:e.get(["label","align"])||l[a],labelBaseline:e.get(["label","verticalAlign"])||e.get(["label","baseline"])||u[a],playPosition:m,prevBtnPosition:_,nextBtnPosition:S,axisExtent:D,controlSize:p,controlGap:d}},t.prototype._position=function(e,i){var n=this._mainGroup,a=this._labelGroup,o=e.viewRect;if(e.orient==="vertical"){var s=xe(),l=o.x,u=o.y+o.height;Vr(s,s,[-l,-u]),mi(s,s,-uh/2),Vr(s,s,[l,u]),o=o.clone(),o.applyTransform(s)}var f=m(o),h=m(n.getBoundingRect()),c=m(a.getBoundingRect()),v=[n.x,n.y],p=[a.x,a.y];p[0]=v[0]=f[0][0];var d=e.labelPosOpt;if(d==null||G(d)){var g=d==="+"?0:1;_(v,h,f,1,g),_(p,c,f,1,1-g)}else{var g=d>=0?0:1;_(v,h,f,1,g),p[1]=v[1]+d}n.setPosition(v),a.setPosition(p),n.rotation=a.rotation=e.rotation,y(n),y(a);function y(S){S.originX=f[0][0]-S.x,S.originY=f[1][0]-S.y}function m(S){return[[S.x,S.x+S.width],[S.y,S.y+S.height]]}function _(S,b,x,T,C){S[T]+=x[T][C]-b[T][C]}},t.prototype._createAxis=function(e,i){var n=i.getData(),a=i.get("axisType"),o=R5(i,a);o.getTicks=function(){return n.mapArray(["value"],function(u){return{value:u}})};var s=n.getDataExtent("value");o.setExtent(s[0],s[1]),o.calcNiceTicks();var l=new P5("value",o,e.axisExtent,a);return l.model=i,l},t.prototype._createGroup=function(e){var i=this[e]=new nt;return this.group.add(i),i},t.prototype._renderAxisLine=function(e,i,n,a){var o=n.getExtent();if(a.get(["lineStyle","show"])){var s=new Kt({shape:{x1:o[0],y1:0,x2:o[1],y2:0},style:O({lineCap:"round"},a.getModel("lineStyle").getLineStyle()),silent:!0,z2:1});i.add(s);var l=this._progressLine=new Kt({shape:{x1:o[0],x2:this._currentPointer?this._currentPointer.x:o[0],y1:0,y2:0},style:K({lineCap:"round",lineWidth:s.style.lineWidth},a.getModel(["progress","lineStyle"]).getLineStyle()),silent:!0,z2:1});i.add(l)}},t.prototype._renderAxisTick=function(e,i,n,a){var o=this,s=a.getData(),l=n.scale.getTicks();this._tickSymbols=[],w(l,function(u){var f=n.dataToCoord(u.value),h=s.getItemModel(u.value),c=h.getModel("itemStyle"),v=h.getModel(["emphasis","itemStyle"]),p=h.getModel(["progress","itemStyle"]),d={x:f,y:0,onclick:W(o._changeTimeline,o,u.value)},g=A0(h,c,i,d);g.ensureState("emphasis").style=v.getItemStyle(),g.ensureState("progress").style=p.getItemStyle(),hi(g);var y=ot(g);h.get("tooltip")?(y.dataIndex=u.value,y.dataModel=a):y.dataIndex=y.dataModel=null,o._tickSymbols.push(g)})},t.prototype._renderAxisLabel=function(e,i,n,a){var o=this,s=n.getLabelModel();if(s.get("show")){var l=a.getData(),u=n.getViewLabels();this._tickLabels=[],w(u,function(f){var h=f.tickValue,c=l.getItemModel(h),v=c.getModel("label"),p=c.getModel(["emphasis","label"]),d=c.getModel(["progress","label"]),g=n.dataToCoord(f.tickValue),y=new ct({x:g,y:0,rotation:e.labelRotation-e.rotation,onclick:W(o._changeTimeline,o,h),silent:!1,style:Rt(v,{text:f.formattedLabel,align:e.labelAlign,verticalAlign:e.labelBaseline})});y.ensureState("emphasis").style=Rt(p),y.ensureState("progress").style=Rt(d),i.add(y),hi(y),C0(y).dataIndex=h,o._tickLabels.push(y)})}},t.prototype._renderControl=function(e,i,n,a){var o=e.controlSize,s=e.rotation,l=a.getModel("controlStyle").getItemStyle(),u=a.getModel(["emphasis","controlStyle"]).getItemStyle(),f=a.getPlayState(),h=a.get("inverse",!0);c(e.nextBtnPosition,"next",W(this._changeTimeline,this,h?"-":"+")),c(e.prevBtnPosition,"prev",W(this._changeTimeline,this,h?"+":"-")),c(e.playPosition,f?"stop":"play",W(this._handlePlayClick,this,!f),!0);function c(v,p,d,g){if(v){var y=er(rt(a.get(["controlStyle",p+"BtnSize"]),o),o),m=[0,-y/2,y,y],_=k5(a,p+"Icon",m,{x:v[0],y:v[1],originX:o/2,originY:0,rotation:g?-s:0,rectHover:!0,style:l,onclick:d});_.ensureState("emphasis").style=u,i.add(_),hi(_)}}},t.prototype._renderCurrentPointer=function(e,i,n,a){var o=a.getData(),s=a.getCurrentIndex(),l=o.getItemModel(s).getModel("checkpointStyle"),u=this,f={onCreate:function(h){h.draggable=!0,h.drift=W(u._handlePointerDrag,u),h.ondragend=W(u._handlePointerDragend,u),M0(h,u._progressLine,s,n,a,!0)},onUpdate:function(h){M0(h,u._progressLine,s,n,a)}};this._currentPointer=A0(l,l,this._mainGroup,{},this._currentPointer,f)},t.prototype._handlePlayClick=function(e){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:e,from:this.uid})},t.prototype._handlePointerDrag=function(e,i,n){this._clearTimer(),this._pointerChangeTimeline([n.offsetX,n.offsetY])},t.prototype._handlePointerDragend=function(e){this._pointerChangeTimeline([e.offsetX,e.offsetY],!0)},t.prototype._pointerChangeTimeline=function(e,i){var n=this._toAxisCoord(e)[0],a=this._axis,o=gr(a.getExtent().slice());n>o[1]&&(n=o[1]),n=0},t.prototype.getOrient=function(){return this.get("orient")==="vertical"?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},t.type="legend.plain",t.dependencies=["series"],t.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}},t})(at),zn=ft,Nv=w,Hs=nt,yw=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.newlineDisabled=!1,e}return t.prototype.init=function(){this.group.add(this._contentGroup=new Hs),this.group.add(this._selectorGroup=new Hs),this._isFirstRender=!0},t.prototype.getContentGroup=function(){return this._contentGroup},t.prototype.getSelectorGroup=function(){return this._selectorGroup},t.prototype.render=function(e,i,n){var a=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),!!e.get("show",!0)){var o=e.get("align"),s=e.get("orient");(!o||o==="auto")&&(o=e.get("left")==="right"&&s==="vertical"?"right":"left");var l=e.get("selector",!0),u=e.get("selectorPosition",!0);l&&(!u||u==="auto")&&(u=s==="horizontal"?"end":"start"),this.renderInner(o,e,i,n,l,s,u);var f=e.getBoxLayoutParams(),h={width:n.getWidth(),height:n.getHeight()},c=e.get("padding"),v=le(f,h,c),p=this.layoutInner(e,o,v,a,l,u),d=le(K({width:p.width,height:p.height},f),h,c);this.group.x=d.x-p.x,this.group.y=d.y-p.y,this.group.markRedraw(),this.group.add(this._backgroundEl=lw(p,e))}},t.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},t.prototype.renderInner=function(e,i,n,a,o,s,l){var u=this.getContentGroup(),f=U(),h=i.get("selectedMode"),c=[];n.eachRawSeries(function(v){!v.get("legendHoverLink")&&c.push(v.id)}),Nv(i.getData(),function(v,p){var d=v.get("name");if(!this.newlineDisabled&&(d===""||d===` `)){var g=new Hs;g.newline=!0,u.add(g);return}var y=n.getSeriesByName(d)[0];if(!f.get(d))if(y){var m=y.getData(),_=m.getVisual("legendLineStyle")||{},S=m.getVisual("legendIcon"),b=m.getVisual("style"),x=this._createItem(y,d,p,v,i,e,_,b,S,h,a);x.on("click",zn(L0,d,null,a,c)).on("mouseover",zn(zv,y.name,null,a,c)).on("mouseout",zn(Fv,y.name,null,a,c)),n.ssr&&x.eachChild(function(T){var C=ot(T);C.seriesIndex=y.seriesIndex,C.dataIndex=p,C.ssrType="legend"}),f.set(d,!0)}else n.eachRawSeries(function(T){if(!f.get(d)&&T.legendVisualProvider){var C=T.legendVisualProvider;if(!C.containName(d))return;var A=C.indexOfName(d),M=C.getItemVisual(A,"style"),D=C.getItemVisual(A,"legendIcon"),L=oe(M.fill);L&&L[3]===0&&(L[3]=.2,M=O(O({},M),{fill:Qe(L,"rgba")}));var P=this._createItem(T,d,p,v,i,e,{},M,D,h,a);P.on("click",zn(L0,null,d,a,c)).on("mouseover",zn(zv,null,d,a,c)).on("mouseout",zn(Fv,null,d,a,c)),n.ssr&&P.eachChild(function(I){var R=ot(I);R.seriesIndex=T.seriesIndex,R.dataIndex=p,R.ssrType="legend"}),f.set(d,!0)}},this)},this),o&&this._createSelector(o,i,a,s,l)},t.prototype._createSelector=function(e,i,n,a,o){var s=this.getSelectorGroup();Nv(e,function(u){var f=u.type,h=new ct({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){n.dispatchAction({type:f==="all"?"legendAllSelect":"legendInverseSelect",legendId:i.id})}});s.add(h);var c=i.getModel("selectorLabel"),v=i.getModel(["emphasis","selectorLabel"]);Xr(h,{normal:c,emphasis:v},{defaultText:u.title}),hi(h)})},t.prototype._createItem=function(e,i,n,a,o,s,l,u,f,h,c){var v=e.visualDrawType,p=o.get("itemWidth"),d=o.get("itemHeight"),g=o.isSelected(i),y=a.get("symbolRotate"),m=a.get("symbolKeepAspect"),_=a.get("icon");f=_||f||"roundRect";var S=V5(f,a,l,u,v,g,c),b=new Hs,x=a.getModel("textStyle");if(j(e.getLegendIcon)&&(!_||_==="inherit"))b.add(e.getLegendIcon({itemWidth:p,itemHeight:d,icon:f,iconRotate:y,itemStyle:S.itemStyle,lineStyle:S.lineStyle,symbolKeepAspect:m}));else{var T=_==="inherit"&&e.getData().getVisual("symbol")?y==="inherit"?e.getData().getVisual("symbolRotate"):y:0;b.add(G5({itemWidth:p,itemHeight:d,icon:f,iconRotate:T,itemStyle:S.itemStyle,symbolKeepAspect:m}))}var C=s==="left"?p+5:-5,A=s,M=o.get("formatter"),D=i;G(M)&&M?D=M.replace("{name}",i!=null?i:""):j(M)&&(D=M(i));var L=g?x.getTextColor():a.get("inactiveColor");b.add(new ct({style:Rt(x,{text:D,x:C,y:d/2,fill:L,align:A,verticalAlign:"middle"},{inheritColor:L})}));var P=new vt({shape:b.getBoundingRect(),style:{fill:"transparent"}}),I=a.getModel("tooltip");return I.get("show")&&mn({el:P,componentModel:o,itemName:i,itemTooltipOption:I.option}),b.add(P),b.eachChild(function(R){R.silent=!0}),P.silent=!h,this.getContentGroup().add(b),hi(b),b.__legendDataIndex=n,b},t.prototype.layoutInner=function(e,i,n,a,o,s){var l=this.getContentGroup(),u=this.getSelectorGroup();on(e.get("orient"),l,e.get("itemGap"),n.width,n.height);var f=l.getBoundingRect(),h=[-f.x,-f.y];if(u.markRedraw(),l.markRedraw(),o){on("horizontal",u,e.get("selectorItemGap",!0));var c=u.getBoundingRect(),v=[-c.x,-c.y],p=e.get("selectorButtonGap",!0),d=e.getOrient().index,g=d===0?"width":"height",y=d===0?"height":"width",m=d===0?"y":"x";s==="end"?v[d]+=f[g]+p:h[d]+=c[g]+p,v[1-d]+=f[y]/2-c[y]/2,u.x=v[0],u.y=v[1],l.x=h[0],l.y=h[1];var _={x:0,y:0};return _[g]=f[g]+p+c[g],_[y]=Math.max(f[y],c[y]),_[m]=Math.min(0,c[m]+v[1-d]),_}else return l.x=h[0],l.y=h[1],this.group.getBoundingRect()},t.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},t.type="legend.plain",t})(Ct);function V5(r,t,e,i,n,a,o){function s(g,y){g.lineWidth==="auto"&&(g.lineWidth=y.lineWidth>0?2:0),Nv(g,function(m,_){g[_]==="inherit"&&(g[_]=y[_])})}var l=t.getModel("itemStyle"),u=l.getItemStyle(),f=r.lastIndexOf("empty",0)===0?"fill":"stroke",h=l.getShallow("decal");u.decal=!h||h==="inherit"?i.decal:Il(h,o),u.fill==="inherit"&&(u.fill=i[n]),u.stroke==="inherit"&&(u.stroke=i[f]),u.opacity==="inherit"&&(u.opacity=(n==="fill"?i:e).opacity),s(u,i);var c=t.getModel("lineStyle"),v=c.getLineStyle();if(s(v,e),u.fill==="auto"&&(u.fill=i.fill),u.stroke==="auto"&&(u.stroke=i.fill),v.stroke==="auto"&&(v.stroke=i.fill),!a){var p=t.get("inactiveBorderWidth"),d=u[f];u.lineWidth=p==="auto"?i.lineWidth>0&&d?2:0:u.lineWidth,u.fill=t.get("inactiveColor"),u.stroke=t.get("inactiveBorderColor"),v.stroke=c.get("inactiveColor"),v.lineWidth=c.get("inactiveWidth")}return{itemStyle:u,lineStyle:v}}function G5(r){var t=r.icon||"roundRect",e=te(t,0,0,r.itemWidth,r.itemHeight,r.itemStyle.fill,r.symbolKeepAspect);return e.setStyle(r.itemStyle),e.rotation=(r.iconRotate||0)*Math.PI/180,e.setOrigin([r.itemWidth/2,r.itemHeight/2]),t.indexOf("empty")>-1&&(e.style.stroke=e.style.fill,e.style.fill="#fff",e.style.lineWidth=2),e}function L0(r,t,e,i){Fv(r,t,e,i),e.dispatchAction({type:"legendToggleSelect",name:r!=null?r:t}),zv(r,t,e,i)}function mw(r){for(var t=r.getZr().storage.getDisplayList(),e,i=0,n=t.length;in[o],g=[-v.x,-v.y];i||(g[a]=f[u]);var y=[0,0],m=[-p.x,-p.y],_=rt(e.get("pageButtonGap",!0),e.get("itemGap",!0));if(d){var S=e.get("pageButtonPosition",!0);S==="end"?m[a]+=n[o]-p[o]:y[a]+=p[o]+_}m[1-a]+=v[s]/2-p[s]/2,f.setPosition(g),h.setPosition(y),c.setPosition(m);var b={x:0,y:0};if(b[o]=d?n[o]:v[o],b[s]=Math.max(v[s],p[s]),b[l]=Math.min(0,p[l]+m[1-a]),h.__rectSize=n[o],d){var x={x:0,y:0};x[o]=Math.max(n[o]-p[o]-_,0),x[s]=b[s],h.setClipPath(new vt({shape:x})),h.__rectSize=x[o]}else c.eachChild(function(C){C.attr({invisible:!0,silent:!0})});var T=this._getPageInfo(e);return T.pageIndex!=null&&Mt(f,{x:T.contentPosition[0],y:T.contentPosition[1]},d?e:null),this._updatePageInfoView(e,T),b},t.prototype._pageGo=function(e,i,n){var a=this._getPageInfo(i)[e];a!=null&&n.dispatchAction({type:"legendScroll",scrollDataIndex:a,legendId:i.id})},t.prototype._updatePageInfoView=function(e,i){var n=this._controllerGroup;w(["pagePrev","pageNext"],function(f){var h=f+"DataIndex",c=i[h]!=null,v=n.childOfName(f);v&&(v.setStyle("fill",c?e.get("pageIconColor",!0):e.get("pageIconInactiveColor",!0)),v.cursor=c?"pointer":"default")});var a=n.childOfName("pageText"),o=e.get("pageFormatter"),s=i.pageIndex,l=s!=null?s+1:0,u=i.pageCount;a&&o&&a.setStyle("text",G(o)?o.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):o({current:l,total:u}))},t.prototype._getPageInfo=function(e){var i=e.get("scrollDataIndex",!0),n=this.getContentGroup(),a=this._containerGroup.__rectSize,o=e.getOrient().index,s=fh[o],l=hh[o],u=this._findTargetItemIndex(i),f=n.children(),h=f[u],c=f.length,v=c?1:0,p={contentPosition:[n.x,n.y],pageCount:v,pageIndex:v-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!h)return p;var d=S(h);p.contentPosition[o]=-d.s;for(var g=u+1,y=d,m=d,_=null;g<=c;++g)_=S(f[g]),(!_&&m.e>y.s+a||_&&!b(_,y.s))&&(m.i>y.i?y=m:y=_,y&&(p.pageNextDataIndex==null&&(p.pageNextDataIndex=y.i),++p.pageCount)),m=_;for(var g=u-1,y=d,m=d,_=null;g>=-1;--g)_=S(f[g]),(!_||!b(m,_.s))&&y.i=T&&x.s<=T+a}},t.prototype._findTargetItemIndex=function(e){if(!this._showController)return 0;var i,n=this.getContentGroup(),a;return n.eachChild(function(o,s){var l=o.__legendDataIndex;a==null&&l!=null&&(a=s),l===e&&(i=s)}),i!=null?i:a},t.type="legend.scroll",t})(yw);function X5(r){r.registerAction("legendScroll","legendscroll",function(t,e){var i=t.scrollDataIndex;i!=null&&e.eachComponent({mainType:"legend",subType:"scroll",query:t},function(n){n.setScrollDataIndex(i)})})}function Z5(r){Ht(_w),r.registerComponentModel(Y5),r.registerComponentView(U5),X5(r)}function $5(r){Ht(_w),Ht(Z5)}var q5=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="dataZoom.inside",t.defaultOption=_i(Bo.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),t})(Bo),Lp=St();function K5(r,t,e){Lp(r).coordSysRecordMap.each(function(i){var n=i.dataZoomInfoMap.get(t.uid);n&&(n.getRange=e)})}function J5(r,t){for(var e=Lp(r).coordSysRecordMap,i=e.keys(),n=0;ni[e+t]&&(t=s),n=n&&o.get("preventDefaultMouseMove",!0)}),{controlType:t,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!n}}}function rN(r){r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,function(t,e){var i=Lp(e),n=i.coordSysRecordMap||(i.coordSysRecordMap=U());n.each(function(a){a.dataZoomInfoMap=null}),t.eachComponent({mainType:"dataZoom",subType:"inside"},function(a){var o=aw(a);w(o.infoList,function(s){var l=s.model.uid,u=n.get(l)||n.set(l,j5(e,s.model)),f=u.dataZoomInfoMap||(u.dataZoomInfoMap=U());f.set(a.uid,{dzReferCoordSysInfo:s,model:a,getRange:null})})}),n.each(function(a){var o=a.controller,s,l=a.dataZoomInfoMap;if(l){var u=l.keys()[0];u!=null&&(s=l.get(u))}if(!s){Sw(n,a);return}var f=eN(l);o.enable(f.controlType,f.opt),o.setPointerChecker(a.containsPoint),$o(a,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var iN=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="dataZoom.inside",e}return t.prototype.render=function(e,i,n){if(r.prototype.render.apply(this,arguments),e.noTarget()){this._clear();return}this.range=e.getPercentRange(),K5(n,e,{pan:W(vh.pan,this),zoom:W(vh.zoom,this),scrollMove:W(vh.scrollMove,this)})},t.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){J5(this.api,this.dataZoomModel),this.range=null},t.type="dataZoom.inside",t})(Tp),vh={zoom:function(r,t,e,i){var n=this.range,a=n.slice(),o=r.axisModels[0];if(o){var s=ch[t](null,[i.originX,i.originY],o,e,r),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(a[1]-a[0])+a[0],u=Math.max(1/i.scale,0);a[0]=(a[0]-l)*u+l,a[1]=(a[1]-l)*u+l;var f=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(Sn(0,a,[0,100],0,f.minSpan,f.maxSpan),this.range=a,n[0]!==a[0]||n[1]!==a[1])return a}},pan:E0(function(r,t,e,i,n,a){var o=ch[i]([a.oldX,a.oldY],[a.newX,a.newY],t,n,e);return o.signal*(r[1]-r[0])*o.pixel/o.pixelLength}),scrollMove:E0(function(r,t,e,i,n,a){var o=ch[i]([0,0],[a.scrollDelta,a.scrollDelta],t,n,e);return o.signal*(r[1]-r[0])*a.scrollDelta})};function E0(r){return function(t,e,i,n){var a=this.range,o=a.slice(),s=t.axisModels[0];if(s){var l=r(o,s,t,e,i,n);if(Sn(l,o,[0,100],"all"),this.range=o,a[0]!==o[0]||a[1]!==o[1])return o}}}var ch={grid:function(r,t,e,i,n){var a=e.axis,o={},s=n.model.coordinateSystem.getRect();return r=r||[0,0],a.dim==="x"?(o.pixel=t[0]-r[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=a.inverse?1:-1):(o.pixel=t[1]-r[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=a.inverse?-1:1),o},polar:function(r,t,e,i,n){var a=e.axis,o={},s=n.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return r=r?s.pointToCoord(r):[0,0],t=s.pointToCoord(t),e.mainType==="radiusAxis"?(o.pixel=t[0]-r[0],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=a.inverse?1:-1):(o.pixel=t[1]-r[1],o.pixelLength=u[1]-u[0],o.pixelStart=u[0],o.signal=a.inverse?-1:1),o},singleAxis:function(r,t,e,i,n){var a=e.axis,o=n.model.coordinateSystem.getRect(),s={};return r=r||[0,0],a.orient==="horizontal"?(s.pixel=t[0]-r[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=a.inverse?1:-1):(s.pixel=t[1]-r[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=a.inverse?-1:1),s}};function nN(r){Cp(r),r.registerComponentModel(q5),r.registerComponentView(iN),rN(r)}var aN=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="dataZoom.slider",t.layoutMode="box",t.defaultOption=_i(Bo.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:"#fff",borderColor:"#ACB8D1"},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),t})(Bo),Wa=vt,k0=7,oN=1,ph=30,sN=7,Ya="horizontal",O0="vertical",lN=5,uN=["line","bar","candlestick","scatter"],fN={easing:"cubicOut",duration:100,delay:0},hN=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e._displayables={},e}return t.prototype.init=function(e,i){this.api=i,this._onBrush=W(this._onBrush,this),this._onBrushEnd=W(this._onBrushEnd,this)},t.prototype.render=function(e,i,n,a){if(r.prototype.render.apply(this,arguments),$o(this,"_dispatchZoomAction",e.get("throttle"),"fixRate"),this._orient=e.getOrient(),e.get("show")===!1){this.group.removeAll();return}if(e.noTarget()){this._clear(),this.group.removeAll();return}(!a||a.type!=="dataZoom"||a.from!==this.uid)&&this._buildView(),this._updateView()},t.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){Mo(this,"_dispatchZoomAction");var e=this.api.getZr();e.off("mousemove",this._onBrush),e.off("mouseup",this._onBrushEnd)},t.prototype._buildView=function(){var e=this.group;e.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var i=this._displayables.sliderGroup=new nt;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),e.add(i),this._positionGroup()},t.prototype._resetLocation=function(){var e=this.dataZoomModel,i=this.api,n=e.get("brushSelect"),a=n?sN:0,o=this._findCoordRect(),s={width:i.getWidth(),height:i.getHeight()},l=this._orient===Ya?{right:s.width-o.x-o.width,top:s.height-ph-k0-a,width:o.width,height:ph}:{right:k0,top:o.y,width:ph,height:o.height},u=ca(e.option);w(["right","top","width","height"],function(h){u[h]==="ph"&&(u[h]=l[h])});var f=le(u,s);this._location={x:f.x,y:f.y},this._size=[f.width,f.height],this._orient===O0&&this._size.reverse()},t.prototype._positionGroup=function(){var e=this.group,i=this._location,n=this._orient,a=this.dataZoomModel.getFirstTargetAxisModel(),o=a&&a.get("inverse"),s=this._displayables.sliderGroup,l=(this._dataShadowInfo||{}).otherAxisInverse;s.attr(n===Ya&&!o?{scaleY:l?1:-1,scaleX:1}:n===Ya&&o?{scaleY:l?1:-1,scaleX:-1}:n===O0&&!o?{scaleY:l?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:l?-1:1,scaleX:-1,rotation:Math.PI/2});var u=e.getBoundingRect([s]);e.x=i.x-u.x,e.y=i.y-u.y,e.markRedraw()},t.prototype._getViewExtent=function(){return[0,this._size[0]]},t.prototype._renderBackground=function(){var e=this.dataZoomModel,i=this._size,n=this._displayables.sliderGroup,a=e.get("brushSelect");n.add(new Wa({silent:!0,shape:{x:0,y:0,width:i[0],height:i[1]},style:{fill:e.get("backgroundColor")},z2:-40}));var o=new Wa({shape:{x:0,y:0,width:i[0],height:i[1]},style:{fill:"transparent"},z2:0,onclick:W(this._onClickPanel,this)}),s=this.api.getZr();a?(o.on("mousedown",this._onBrushStart,this),o.cursor="crosshair",s.on("mousemove",this._onBrush),s.on("mouseup",this._onBrushEnd)):(s.off("mousemove",this._onBrush),s.off("mouseup",this._onBrushEnd)),n.add(o)},t.prototype._renderDataShadow=function(){var e=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!e)return;var i=this._size,n=this._shadowSize||[],a=e.series,o=a.getRawData(),s=a.getShadowDim&&a.getShadowDim(),l=s&&o.getDimensionInfo(s)?a.getShadowDim():e.otherDim;if(l==null)return;var u=this._shadowPolygonPts,f=this._shadowPolylinePts;if(o!==this._shadowData||l!==this._shadowDim||i[0]!==n[0]||i[1]!==n[1]){var h=o.getDataExtent(l),c=(h[1]-h[0])*.3;h=[h[0]-c,h[1]+c];var v=[0,i[1]],p=[0,i[0]],d=[[i[0],0],[0,0]],g=[],y=p[1]/(o.count()-1),m=0,_=Math.round(o.count()/i[0]),S;o.each([l],function(A,M){if(_>0&&M%_){m+=y;return}var D=A==null||isNaN(A)||A==="",L=D?0:Tt(A,h,v,!0);D&&!S&&M?(d.push([d[d.length-1][0],0]),g.push([g[g.length-1][0],0])):!D&&S&&(d.push([m,0]),g.push([m,0])),d.push([m,L]),g.push([m,L]),m+=y,S=D}),u=this._shadowPolygonPts=d,f=this._shadowPolylinePts=g}this._shadowData=o,this._shadowDim=l,this._shadowSize=[i[0],i[1]];var b=this.dataZoomModel;function x(A){var M=b.getModel(A?"selectedDataBackground":"dataBackground"),D=new nt,L=new ir({shape:{points:u},segmentIgnoreThreshold:1,style:M.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),P=new Ce({shape:{points:f},segmentIgnoreThreshold:1,style:M.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return D.add(L),D.add(P),D}for(var T=0;T<3;T++){var C=x(T===1);this._displayables.sliderGroup.add(C),this._displayables.dataShadowSegs.push(C)}},t.prototype._prepareDataShadowInfo=function(){var e=this.dataZoomModel,i=e.get("showDataShadow");if(i!==!1){var n,a=this.ecModel;return e.eachTargetAxis(function(o,s){var l=e.getAxisProxy(o,s).getTargetSeriesModels();w(l,function(u){if(!n&&!(i!==!0&<(uN,u.get("type"))<0)){var f=a.getComponent(ui(o),s).axis,h=vN(o),c,v=u.coordinateSystem;h!=null&&v.getOtherAxis&&(c=v.getOtherAxis(f).inverse),h=u.getData().mapDimension(h),n={thisAxis:f,series:u,thisDim:o,otherDim:h,otherAxisInverse:c}}},this)},this),n}},t.prototype._renderHandle=function(){var e=this.group,i=this._displayables,n=i.handles=[null,null],a=i.handleLabels=[null,null],o=this._displayables.sliderGroup,s=this._size,l=this.dataZoomModel,u=this.api,f=l.get("borderRadius")||0,h=l.get("brushSelect"),c=i.filler=new Wa({silent:h,style:{fill:l.get("fillerColor")},textConfig:{position:"inside"}});o.add(c),o.add(new Wa({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:s[0],height:s[1],r:f},style:{stroke:l.get("dataBackgroundColor")||l.get("borderColor"),lineWidth:oN,fill:"rgba(0,0,0,0)"}})),w([0,1],function(_){var S=l.get("handleIcon");!Dl[S]&&S.indexOf("path://")<0&&S.indexOf("image://")<0&&(S="path://"+S);var b=te(S,-1,0,2,2,null,!0);b.attr({cursor:B0(this._orient),draggable:!0,drift:W(this._onDragMove,this,_),ondragend:W(this._onDragEnd,this),onmouseover:W(this._showDataInfo,this,!0),onmouseout:W(this._showDataInfo,this,!1),z2:5});var x=b.getBoundingRect(),T=l.get("handleSize");this._handleHeight=Q(T,this._size[1]),this._handleWidth=x.width/x.height*this._handleHeight,b.setStyle(l.getModel("handleStyle").getItemStyle()),b.style.strokeNoScale=!0,b.rectHover=!0,b.ensureState("emphasis").style=l.getModel(["emphasis","handleStyle"]).getItemStyle(),hi(b);var C=l.get("handleColor");C!=null&&(b.style.fill=C),o.add(n[_]=b);var A=l.getModel("textStyle"),M=l.get("handleLabel")||{},D=M.show||!1;e.add(a[_]=new ct({silent:!0,invisible:!D,style:Rt(A,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:A.getTextColor(),font:A.getFont()}),z2:10}))},this);var v=c;if(h){var p=Q(l.get("moveHandleSize"),s[1]),d=i.moveHandle=new vt({style:l.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:s[1]-.5,height:p}}),g=p*.8,y=i.moveHandleIcon=te(l.get("moveHandleIcon"),-g/2,-g/2,g,g,"#fff",!0);y.silent=!0,y.y=s[1]+p/2-.5,d.ensureState("emphasis").style=l.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var m=Math.min(s[1]/2,Math.max(p,10));v=i.moveZone=new vt({invisible:!0,shape:{y:s[1]-m,height:p+m}}),v.on("mouseover",function(){u.enterEmphasis(d)}).on("mouseout",function(){u.leaveEmphasis(d)}),o.add(d),o.add(y),o.add(v)}v.attr({draggable:!0,cursor:B0(this._orient),drift:W(this._onDragMove,this,"all"),ondragstart:W(this._showDataInfo,this,!0),ondragend:W(this._onDragEnd,this),onmouseover:W(this._showDataInfo,this,!0),onmouseout:W(this._showDataInfo,this,!1)})},t.prototype._resetInterval=function(){var e=this._range=this.dataZoomModel.getPercentRange(),i=this._getViewExtent();this._handleEnds=[Tt(e[0],[0,100],i,!0),Tt(e[1],[0,100],i,!0)]},t.prototype._updateInterval=function(e,i){var n=this.dataZoomModel,a=this._handleEnds,o=this._getViewExtent(),s=n.findRepresentativeAxisProxy().getMinMaxSpan(),l=[0,100];Sn(i,a,o,n.get("zoomLock")?"all":e,s.minSpan!=null?Tt(s.minSpan,l,o,!0):null,s.maxSpan!=null?Tt(s.maxSpan,l,o,!0):null);var u=this._range,f=this._range=gr([Tt(a[0],o,l,!0),Tt(a[1],o,l,!0)]);return!u||u[0]!==f[0]||u[1]!==f[1]},t.prototype._updateView=function(e){var i=this._displayables,n=this._handleEnds,a=gr(n.slice()),o=this._size;w([0,1],function(v){var p=i.handles[v],d=this._handleHeight;p.attr({scaleX:d/2,scaleY:d/2,x:n[v]+(v?-1:1),y:o[1]/2-d/2})},this),i.filler.setShape({x:a[0],y:0,width:a[1]-a[0],height:o[1]});var s={x:a[0],width:a[1]-a[0]};i.moveHandle&&(i.moveHandle.setShape(s),i.moveZone.setShape(s),i.moveZone.getBoundingRect(),i.moveHandleIcon&&i.moveHandleIcon.attr("x",s.x+s.width/2));for(var l=i.dataShadowSegs,u=[0,a[0],a[1],o[0]],f=0;fi[0]||n[1]<0||n[1]>i[1])){var a=this._handleEnds,o=(a[0]+a[1])/2,s=this._updateInterval("all",n[0]-o);this._updateView(),s&&this._dispatchZoomAction(!1)}},t.prototype._onBrushStart=function(e){var i=e.offsetX,n=e.offsetY;this._brushStart=new et(i,n),this._brushing=!0,this._brushStartTime=+new Date},t.prototype._onBrushEnd=function(e){if(this._brushing){var i=this._displayables.brushRect;if(this._brushing=!1,!!i){i.attr("ignore",!0);var n=i.shape,a=+new Date;if(!(a-this._brushStartTime<200&&Math.abs(n.width)<5)){var o=this._getViewExtent(),s=[0,100];this._range=gr([Tt(n.x,o,s,!0),Tt(n.x+n.width,o,s,!0)]),this._handleEnds=[n.x,n.x+n.width],this._updateView(),this._dispatchZoomAction(!1)}}}},t.prototype._onBrush=function(e){this._brushing&&(Fr(e.event),this._updateBrushRect(e.offsetX,e.offsetY))},t.prototype._updateBrushRect=function(e,i){var n=this._displayables,a=this.dataZoomModel,o=n.brushRect;o||(o=n.brushRect=new Wa({silent:!0,style:a.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(o)),o.attr("ignore",!1);var s=this._brushStart,l=this._displayables.sliderGroup,u=l.transformCoordToLocal(e,i),f=l.transformCoordToLocal(s.x,s.y),h=this._size;u[0]=Math.max(Math.min(h[0],u[0]),0),o.setShape({x:f[0],y:0,width:u[0]-f[0],height:h[1]})},t.prototype._dispatchZoomAction=function(e){var i=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:e?fN:null,start:i[0],end:i[1]})},t.prototype._findCoordRect=function(){var e,i=aw(this.dataZoomModel).infoList;if(!e&&i.length){var n=i[0].model.coordinateSystem;e=n.getRect&&n.getRect()}if(!e){var a=this.api.getWidth(),o=this.api.getHeight();e={x:a*.2,y:o*.2,width:a*.6,height:o*.6}}return e},t.type="dataZoom.slider",t})(Tp);function vN(r){var t={x:"y",y:"x",radius:"angle",angle:"radius"};return t[r]}function B0(r){return r==="vertical"?"ns-resize":"ew-resize"}function cN(r){r.registerComponentModel(aN),r.registerComponentView(hN),Cp(r)}function pN(r){Ht(nN),Ht(cN)}var xw={get:function(r,t,e){var i=q((dN[r]||{})[t]);return e&&z(i)?i[i.length-1]:i}},dN={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]}},N0=Gt.mapVisual,gN=Gt.eachVisual,yN=z,z0=w,mN=gr,_N=Tt,Yl=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.stateList=["inRange","outOfRange"],e.replacableOptionKeys=["inRange","outOfRange","target","controller","color"],e.layoutMode={type:"box",ignoreSize:!0},e.dataBound=[-1/0,1/0],e.targetVisuals={},e.controllerVisuals={},e}return t.prototype.init=function(e,i,n){this.mergeDefaultAndTheme(e,n)},t.prototype.optionUpdated=function(e,i){var n=this.option;!i&&T5(n,e,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},t.prototype.resetVisual=function(e){var i=this.stateList;e=W(e,this),this.controllerVisuals=w0(this.option.controller,i,e),this.targetVisuals=w0(this.option.target,i,e)},t.prototype.getItemSymbol=function(){return null},t.prototype.getTargetSeriesIndices=function(){var e=this.option.seriesIndex,i=[];return e==null||e==="all"?this.ecModel.eachSeries(function(n,a){i.push(a)}):i=At(e),i},t.prototype.eachTargetSeries=function(e,i){w(this.getTargetSeriesIndices(),function(n){var a=this.ecModel.getSeriesByIndex(n);a&&e.call(i,a)},this)},t.prototype.isTargetSeries=function(e){var i=!1;return this.eachTargetSeries(function(n){n===e&&(i=!0)}),i},t.prototype.formatValueText=function(e,i,n){var a=this.option,o=a.precision,s=this.dataBound,l=a.formatter,u;n=n||["<",">"],z(e)&&(e=e.slice(),u=!0);var f=i?e:u?[h(e[0]),h(e[1])]:h(e);if(G(l))return l.replace("{value}",u?f[0]:f).replace("{value2}",u?f[1]:f);if(j(l))return u?l(e[0],e[1]):l(e);if(u)return e[0]===s[0]?n[0]+" "+f[1]:e[1]===s[1]?n[1]+" "+f[0]:f[0]+" - "+f[1];return f;function h(c){return c===s[0]?"min":c===s[1]?"max":(+c).toFixed(Math.min(o,20))}},t.prototype.resetExtent=function(){var e=this.option,i=mN([e.min,e.max]);this._dataExtent=i},t.prototype.getDataDimensionIndex=function(e){var i=this.option.dimension;if(i!=null)return e.getDimensionIndex(i);for(var n=e.dimensions,a=n.length-1;a>=0;a--){var o=n[a],s=e.getDimensionInfo(o);if(!s.isCalculationCoord)return s.storeDimIndex}},t.prototype.getExtent=function(){return this._dataExtent.slice()},t.prototype.completeVisualOption=function(){var e=this.ecModel,i=this.option,n={inRange:i.inRange,outOfRange:i.outOfRange},a=i.target||(i.target={}),o=i.controller||(i.controller={});J(a,n),J(o,n);var s=this.isCategory();l.call(this,a),l.call(this,o),u.call(this,a,"inRange","outOfRange"),f.call(this,o);function l(h){yN(i.color)&&!h.inRange&&(h.inRange={color:i.color.slice().reverse()}),h.inRange=h.inRange||{color:e.get("gradientColor")}}function u(h,c,v){var p=h[c],d=h[v];p&&!d&&(d=h[v]={},z0(p,function(g,y){if(Gt.isValidType(y)){var m=xw.get(y,"inactive",s);m!=null&&(d[y]=m,y==="color"&&!d.hasOwnProperty("opacity")&&!d.hasOwnProperty("colorAlpha")&&(d.opacity=[0,0]))}}))}function f(h){var c=(h.inRange||{}).symbol||(h.outOfRange||{}).symbol,v=(h.inRange||{}).symbolSize||(h.outOfRange||{}).symbolSize,p=this.get("inactiveColor"),d=this.getItemSymbol(),g=d||"roundRect";z0(this.stateList,function(y){var m=this.itemSize,_=h[y];_||(_=h[y]={color:s?p:[p]}),_.symbol==null&&(_.symbol=c&&q(c)||(s?g:[g])),_.symbolSize==null&&(_.symbolSize=v&&q(v)||(s?m[0]:[m[0],m[0]])),_.symbol=N0(_.symbol,function(x){return x==="none"?g:x});var S=_.symbolSize;if(S!=null){var b=-1/0;gN(S,function(x){x>b&&(b=x)}),_.symbolSize=N0(S,function(x){return _N(x,[0,b],[0,m[0]],!0)})}},this)}},t.prototype.resetItemSize=function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},t.prototype.isCategory=function(){return!!this.option.categories},t.prototype.setSelected=function(e){},t.prototype.getSelected=function(){return null},t.prototype.getValueState=function(e){return null},t.prototype.getVisualMeta=function(e){return null},t.type="visualMap",t.dependencies=["series"],t.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"}},t})(at),F0=[20,140],SN=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.optionUpdated=function(e,i){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent(),this.resetVisual(function(n){n.mappingMethod="linear",n.dataExtent=this.getExtent()}),this._resetRange()},t.prototype.resetItemSize=function(){r.prototype.resetItemSize.apply(this,arguments);var e=this.itemSize;(e[0]==null||isNaN(e[0]))&&(e[0]=F0[0]),(e[1]==null||isNaN(e[1]))&&(e[1]=F0[1])},t.prototype._resetRange=function(){var e=this.getExtent(),i=this.option.range;!i||i.auto?(e.auto=1,this.option.range=e):z(i)&&(i[0]>i[1]&&i.reverse(),i[0]=Math.max(i[0],e[0]),i[1]=Math.min(i[1],e[1]))},t.prototype.completeVisualOption=function(){r.prototype.completeVisualOption.apply(this,arguments),w(this.stateList,function(e){var i=this.option.controller[e].symbolSize;i&&i[0]!==i[1]&&(i[0]=i[1]/3)},this)},t.prototype.setSelected=function(e){this.option.range=e.slice(),this._resetRange()},t.prototype.getSelected=function(){var e=this.getExtent(),i=gr((this.get("range")||[]).slice());return i[0]>e[1]&&(i[0]=e[1]),i[1]>e[1]&&(i[1]=e[1]),i[0]=n[1]||e<=i[1])?"inRange":"outOfRange"},t.prototype.findTargetDataIndices=function(e){var i=[];return this.eachTargetSeries(function(n){var a=[],o=n.getData();o.each(this.getDataDimensionIndex(o),function(s,l){e[0]<=s&&s<=e[1]&&a.push(l)},this),i.push({seriesId:n.id,dataIndex:a})},this),i},t.prototype.getVisualMeta=function(e){var i=V0(this,"outOfRange",this.getExtent()),n=V0(this,"inRange",this.option.range.slice()),a=[];function o(v,p){a.push({value:v,color:e(v,p)})}for(var s=0,l=0,u=n.length,f=i.length;le[1])break;a.push({color:this.getControllerVisual(l,"color",i),offset:s/n})}return a.push({color:this.getControllerVisual(e[1],"color",i),offset:1}),a},t.prototype._createBarPoints=function(e,i){var n=this.visualMapModel.itemSize;return[[n[0]-i[0],e[0]],[n[0],e[0]],[n[0],e[1]],[n[0]-i[1],e[1]]]},t.prototype._createBarGroup=function(e){var i=this._orient,n=this.visualMapModel.get("inverse");return new nt(i==="horizontal"&&!n?{scaleX:e==="bottom"?1:-1,rotation:Math.PI/2}:i==="horizontal"&&n?{scaleX:e==="bottom"?-1:1,rotation:-Math.PI/2}:i==="vertical"&&!n?{scaleX:e==="left"?1:-1,scaleY:-1}:{scaleX:e==="left"?1:-1})},t.prototype._updateHandle=function(e,i){if(this._useHandle){var n=this._shapes,a=this.visualMapModel,o=n.handleThumbs,s=n.handleLabels,l=a.itemSize,u=a.getExtent(),f=this._applyTransform("left",n.mainGroup);xN([0,1],function(h){var c=o[h];c.setStyle("fill",i.handlesColor[h]),c.y=e[h];var v=cr(e[h],[0,l[1]],u,!0),p=this.getControllerVisual(v,"symbolSize");c.scaleX=c.scaleY=p/l[0],c.x=l[0]-p/2;var d=tr(n.handleLabelPoints[h],vi(c,this.group));if(this._orient==="horizontal"){var g=f==="left"||f==="top"?(l[0]-p)/2:(l[0]-p)/-2;d[1]+=g}s[h].setStyle({x:d[0],y:d[1],text:a.formatValueText(this._dataInterval[h]),verticalAlign:"middle",align:this._orient==="vertical"?this._applyTransform("left",n.mainGroup):"center"})},this)}},t.prototype._showIndicator=function(e,i,n,a){var o=this.visualMapModel,s=o.getExtent(),l=o.itemSize,u=[0,l[1]],f=this._shapes,h=f.indicator;if(h){h.attr("invisible",!1);var c={convertOpacityToAlpha:!0},v=this.getControllerVisual(e,"color",c),p=this.getControllerVisual(e,"symbolSize"),d=cr(e,s,u,!0),g=l[0]-p/2,y={x:h.x,y:h.y};h.y=d,h.x=g;var m=tr(f.indicatorLabelPoint,vi(h,this.group)),_=f.indicatorLabel;_.attr("invisible",!1);var S=this._applyTransform("left",f.mainGroup),b=this._orient,x=b==="horizontal";_.setStyle({text:(n||"")+o.formatValueText(i),verticalAlign:x?S:"middle",align:x?"center":S});var T={x:g,y:d,style:{fill:v}},C={style:{x:m[0],y:m[1]}};if(o.ecModel.isAnimationEnabled()&&!this._firstShowIndicator){var A={duration:100,easing:"cubicInOut",additive:!0};h.x=y.x,h.y=y.y,h.animateTo(T,A),_.animateTo(C,A)}else h.attr(T),_.attr(C);this._firstShowIndicator=!1;var M=this._shapes.handleLabels;if(M)for(var D=0;Do[1]&&(h[1]=1/0),i&&(h[0]===-1/0?this._showIndicator(f,h[1],"< ",l):h[1]===1/0?this._showIndicator(f,h[0],"> ",l):this._showIndicator(f,f,"≈ ",l));var c=this._hoverLinkDataIndices,v=[];(i||Y0(n))&&(v=this._hoverLinkDataIndices=n.findTargetDataIndices(h));var p=kC(c,v);this._dispatchHighDown("downplay",sl(p[0],n)),this._dispatchHighDown("highlight",sl(p[1],n))}},t.prototype._hoverLinkFromSeriesMouseOver=function(e){var i;if(ji(e.target,function(l){var u=ot(l);if(u.dataIndex!=null)return i=u,!0},!0),!!i){var n=this.ecModel.getSeriesByIndex(i.seriesIndex),a=this.visualMapModel;if(a.isTargetSeries(n)){var o=n.getData(i.dataType),s=o.getStore().get(a.getDataDimensionIndex(o),i.dataIndex);isNaN(s)||this._showIndicator(s,s)}}},t.prototype._hideIndicator=function(){var e=this._shapes;e.indicator&&e.indicator.attr("invisible",!0),e.indicatorLabel&&e.indicatorLabel.attr("invisible",!0);var i=this._shapes.handleLabels;if(i)for(var n=0;n=0&&(a.dimension=o,i.push(a))}}),r.getData().setVisual("visualMeta",i)}}];function LN(r,t,e,i){for(var n=t.targetVisuals[i],a=Gt.prepareVisualTypes(n),o={color:DS(r.getData(),"color")},s=0,l=a.length;s0:t.splitNumber>0)||t.calculable)?"continuous":"piecewise"}),r.registerAction(AN,MN),w(DN,function(t){r.registerVisual(r.PRIORITY.VISUAL.COMPONENT,t)}),r.registerPreprocessor(PN))}function IN(r){r.registerComponentModel(SN),r.registerComponentView(TN),Tw(r)}var RN=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e._pieceList=[],e}return t.prototype.optionUpdated=function(e,i){r.prototype.optionUpdated.apply(this,arguments),this.resetExtent();var n=this._mode=this._determineMode();this._pieceList=[],EN[this._mode].call(this,this._pieceList),this._resetSelected(e,i);var a=this.option.categories;this.resetVisual(function(o,s){n==="categories"?(o.mappingMethod="category",o.categories=q(a)):(o.dataExtent=this.getExtent(),o.mappingMethod="piecewise",o.pieceList=F(this._pieceList,function(l){return l=q(l),s!=="inRange"&&(l.visual=null),l}))})},t.prototype.completeVisualOption=function(){var e=this.option,i={},n=Gt.listVisualTypes(),a=this.isCategory();w(e.pieces,function(s){w(n,function(l){s.hasOwnProperty(l)&&(i[l]=1)})}),w(i,function(s,l){var u=!1;w(this.stateList,function(f){u=u||o(e,f,l)||o(e.target,f,l)},this),!u&&w(this.stateList,function(f){(e[f]||(e[f]={}))[l]=xw.get(l,f==="inRange"?"active":"inactive",a)})},this);function o(s,l,u){return s&&s[l]&&s[l].hasOwnProperty(u)}r.prototype.completeVisualOption.apply(this,arguments)},t.prototype._resetSelected=function(e,i){var n=this.option,a=this._pieceList,o=(i?n:e).selected||{};if(n.selected=o,w(a,function(l,u){var f=this.getSelectedMapKey(l);o.hasOwnProperty(f)||(o[f]=!0)},this),n.selectedMode==="single"){var s=!1;w(a,function(l,u){var f=this.getSelectedMapKey(l);o[f]&&(s?o[f]=!1:s=!0)},this)}},t.prototype.getItemSymbol=function(){return this.get("itemSymbol")},t.prototype.getSelectedMapKey=function(e){return this._mode==="categories"?e.value+"":e.index+""},t.prototype.getPieceList=function(){return this._pieceList},t.prototype._determineMode=function(){var e=this.option;return e.pieces&&e.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},t.prototype.setSelected=function(e){this.option.selected=q(e)},t.prototype.getValueState=function(e){var i=Gt.findPieceIndex(e,this._pieceList);return i!=null&&this.option.selected[this.getSelectedMapKey(this._pieceList[i])]?"inRange":"outOfRange"},t.prototype.findTargetDataIndices=function(e){var i=[],n=this._pieceList;return this.eachTargetSeries(function(a){var o=[],s=a.getData();s.each(this.getDataDimensionIndex(s),function(l,u){var f=Gt.findPieceIndex(l,n);f===e&&o.push(u)},this),i.push({seriesId:a.id,dataIndex:o})},this),i},t.prototype.getRepresentValue=function(e){var i;if(this.isCategory())i=e.value;else if(e.value!=null)i=e.value;else{var n=e.interval||[];i=n[0]===-1/0&&n[1]===1/0?0:(n[0]+n[1])/2}return i},t.prototype.getVisualMeta=function(e){if(this.isCategory())return;var i=[],n=["",""],a=this;function o(f,h){var c=a.getRepresentValue({interval:f});h||(h=a.getValueState(c));var v=e(c,h);f[0]===-1/0?n[0]=v:f[1]===1/0?n[1]=v:i.push({value:f[0],color:v},{value:f[1],color:v})}var s=this._pieceList.slice();if(!s.length)s.push({interval:[-1/0,1/0]});else{var l=s[0].interval[0];l!==-1/0&&s.unshift({interval:[-1/0,l]}),l=s[s.length-1].interval[1],l!==1/0&&s.push({interval:[l,1/0]})}var u=-1/0;return w(s,function(f){var h=f.interval;h&&(h[0]>u&&o([u,h[0]],"outOfRange"),o(h.slice()),u=h[1])},this),{stops:i,outerColors:n}},t.type="visualMap.piecewise",t.defaultOption=_i(Yl.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}),t})(Yl),EN={splitNumber:function(r){var t=this.option,e=Math.min(t.precision,20),i=this.getExtent(),n=t.splitNumber;n=Math.max(parseInt(n,10),1),t.splitNumber=n;for(var a=(i[1]-i[0])/n;+a.toFixed(e)!==a&&e<5;)e++;t.precision=e,a=+a.toFixed(e),t.minOpen&&r.push({interval:[-1/0,i[0]],close:[0,0]});for(var o=0,s=i[0];o","≥"][i[0]]];e.text=e.text||this.formatValueText(e.value!=null?e.value:e.interval,!1,n)},this)}};function $0(r,t){var e=r.inverse;(r.orient==="vertical"?!e:e)&&t.reverse()}var kN=(function(r){E(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.doRender=function(){var e=this.group;e.removeAll();var i=this.visualMapModel,n=i.get("textGap"),a=i.textStyleModel,o=a.getFont(),s=a.getTextColor(),l=this._getItemAlign(),u=i.itemSize,f=this._getViewData(),h=f.endsText,c=zr(i.get("showLabel",!0),!h),v=!i.get("selectedMode");h&&this._renderEndsText(e,h[0],u,c,l),w(f.viewPieceList,function(p){var d=p.piece,g=new nt;g.onclick=W(this._onItemClick,this,d),this._enableHoverLink(g,p.indexInModelPieceList);var y=i.getRepresentValue(d);if(this._createItemSymbol(g,y,[0,0,u[0],u[1]],v),c){var m=this.visualMapModel.getValueState(y);g.add(new ct({style:{x:l==="right"?-n:u[0]+n,y:u[1]/2,text:d.text,verticalAlign:"middle",align:l,font:o,fill:s,opacity:m==="outOfRange"?.5:1},silent:v}))}e.add(g)},this),h&&this._renderEndsText(e,h[1],u,c,l),on(i.get("orient"),e,i.get("itemGap")),this.renderBackground(e),this.positionGroup(e)},t.prototype._enableHoverLink=function(e,i){var n=this;e.on("mouseover",function(){return a("highlight")}).on("mouseout",function(){return a("downplay")});var a=function(o){var s=n.visualMapModel;s.option.hoverLink&&n.api.dispatchAction({type:o,batch:sl(s.findTargetDataIndices(i),s)})}},t.prototype._getItemAlign=function(){var e=this.visualMapModel,i=e.option;if(i.orient==="vertical")return ww(e,this.api,e.itemSize);var n=i.align;return(!n||n==="auto")&&(n="left"),n},t.prototype._renderEndsText=function(e,i,n,a,o){if(i){var s=new nt,l=this.visualMapModel.textStyleModel;s.add(new ct({style:Rt(l,{x:a?o==="right"?n[0]:0:n[0]/2,y:n[1]/2,verticalAlign:"middle",align:a?o:"center",text:i})})),e.add(s)}},t.prototype._getViewData=function(){var e=this.visualMapModel,i=F(e.getPieceList(),function(s,l){return{piece:s,indexInModelPieceList:l}}),n=e.get("text"),a=e.get("orient"),o=e.get("inverse");return(a==="horizontal"?o:!o)?i.reverse():n&&(n=n.slice().reverse()),{viewPieceList:i,endsText:n}},t.prototype._createItemSymbol=function(e,i,n,a){var o=te(this.getControllerVisual(i,"symbol"),n[0],n[1],n[2],n[3],this.getControllerVisual(i,"color"));o.silent=a,e.add(o)},t.prototype._onItemClick=function(e){var i=this.visualMapModel,n=i.option,a=n.selectedMode;if(a){var o=q(n.selected),s=i.getSelectedMapKey(e);a==="single"||a===!0?(o[s]=!0,w(o,function(l,u){o[u]=u===s})):o[s]=!o[s],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:o})}},t.type="visualMap.piecewise",t})(bw);function ON(r){r.registerComponentModel(RN),r.registerComponentView(kN),Tw(r)}function BN(r){Ht(IN),Ht(ON)}var NN={label:{enabled:!0},decal:{show:!1}},q0=St(),zN={};function FN(r,t){var e=r.getModel("aria");if(!e.get("enabled"))return;var i=q(NN);J(i.label,r.getLocaleModel().get("aria"),!1),J(e.option,i,!1),n(),a();function n(){var u=e.getModel("decal"),f=u.get("show");if(f){var h=U();r.eachSeries(function(c){if(!c.isColorBySeries()){var v=h.get(c.type);v||(v={},h.set(c.type,v)),q0(c).scope=v}}),r.eachRawSeries(function(c){if(r.isSeriesFiltered(c))return;if(j(c.enableAriaDecal)){c.enableAriaDecal();return}var v=c.getData();if(c.isColorBySeries()){var m=Qd(c.ecModel,c.name,zN,r.getSeriesCount()),_=v.getVisual("decal");v.setVisual("decal",S(_,m))}else{var p=c.getRawData(),d={},g=q0(c).scope;v.each(function(b){var x=v.getRawIndex(b);d[x]=b});var y=p.count();p.each(function(b){var x=d[b],T=p.getName(b)||b+"",C=Qd(c.ecModel,T,g,y),A=v.getItemVisual(x,"decal");v.setItemVisual(x,"decal",S(A,C))})}function S(b,x){var T=b?O(O({},x),b):x;return T.dirty=!0,T}})}}function a(){var u=t.getZr().dom;if(u){var f=r.getLocaleModel().get("aria"),h=e.getModel("label");if(h.option=K(h.option,f),!!h.get("enabled")){if(u.setAttribute("role","img"),h.get("description")){u.setAttribute("aria-label",h.get("description"));return}var c=r.getSeriesCount(),v=h.get(["data","maxCount"])||10,p=h.get(["series","maxCount"])||10,d=Math.min(c,p),g;if(!(c<1)){var y=s();if(y){var m=h.get(["general","withTitle"]);g=o(m,{title:y})}else g=h.get(["general","withoutTitle"]);var _=[],S=c>1?h.get(["series","multiple","prefix"]):h.get(["series","single","prefix"]);g+=o(S,{seriesCount:c}),r.eachSeries(function(C,A){if(A1?h.get(["series","multiple",L]):h.get(["series","single",L]),M=o(M,{seriesId:C.seriesIndex,seriesName:C.get("name"),seriesType:l(C.subType)});var P=C.getData();if(P.count()>v){var I=h.get(["data","partialData"]);M+=o(I,{displayCnt:v})}else M+=h.get(["data","allData"]);for(var R=h.get(["data","separator","middle"]),k=h.get(["data","separator","end"]),V=h.get(["data","excludeDimensionId"]),B=[],N=0;N=s)}}for(var h=this.__startIndex;h15)break}}I.prevElClipPaths&&y.restore()};if(m)if(m.length===0)C=g.__endIndex;else for(var M=v.dpr,D=0;D0&&t>n[0]){for(l=0;lt);l++);s=i[n[l]]}if(n.splice(l+1,0,t),i[t]=e,!e.virtual)if(s){var u=s.dom;u.nextSibling?o.insertBefore(e.dom,u.nextSibling):o.appendChild(e.dom)}else o.firstChild?o.insertBefore(e.dom,o.firstChild):o.appendChild(e.dom);e.painter||(e.painter=this)}},r.prototype.eachLayer=function(t,e){for(var i=this._zlevelList,n=0;n0?Ws:0),this._needsManuallyCompositing),f.__builtin__||Xl("ZLevel "+u+" has been used by unkown layer "+f.id),f!==a&&(f.__used=!0,f.__startIndex!==l&&(f.__dirty=!0),f.__startIndex=l,f.incremental?f.__drawIndex=-1:f.__drawIndex=l,e(l),a=f),n.__dirty&Se&&!n.__inHover&&(f.__dirty=!0,f.incremental&&f.__drawIndex<0&&(f.__drawIndex=l))}e(l),this.eachBuiltinLayer(function(h,c){!h.__used&&h.getElementCount()>0&&(h.__dirty=!0,h.__startIndex=h.__endIndex=h.__drawIndex=0),h.__dirty&&h.__drawIndex<0&&(h.__drawIndex=h.__startIndex)})},r.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},r.prototype._clearLayer=function(t){t.clear()},r.prototype.setBackgroundColor=function(t){this._backgroundColor=t,w(this._layers,function(e){e.setUnpainted()})},r.prototype.configLayer=function(t,e){if(e){var i=this._layerConfig;i[t]?J(i[t],e,!0):i[t]=e;for(var n=0;n