Files
Nexus/web/app/assets/FleetTrendEChart-DuBaa-sD.js
T
Nexus Agent f127f07ab2 feat(rdp): 3389 页独立管理 RDP 主机
rdp_hosts 表与专用 API,在 3389远程页添加/连接,不再依赖子机列表。

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-10 20:58:46 +08:00

54 lines
611 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import{t as e}from"./chunk-DK3Fl9T5.js";import{Ar as t,Br as n,Ir as r,Jr as i,Jt as a,Nr as o,Or as s,Rr as c,Vr as l,Xr as u,Yr as d,_r as f,ai as p,di as m,kr as h,li as g,ln as _,mi as v,oi as y,ui as b,xr as x,yr as S,zr as C}from"./index-_6O5JL4W.js";import{d as w,g as T,p as E}from"./StatCardsRow-BGQi59My.js";import{t as D}from"./_plugin-vue_export-helper-BDNMzG2s.js";var O=function(e,t){return O=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},O(e,t)};function k(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Class extends value `+String(t)+` is not a constructor or null`);O(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var A=function(){function e(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return e}(),j=new(function(){function e(){this.browser=new A,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<`u`}return e}());typeof wx==`object`&&typeof wx.getSystemInfoSync==`function`?(j.wxa=!0,j.touchEventsSupported=!0):typeof document>`u`&&typeof self<`u`?j.worker=!0:!j.hasGlobalWindow||`Deno`in window||typeof navigator<`u`&&typeof navigator.userAgent==`string`&&navigator.userAgent.indexOf(`Node.js`)>-1?(j.node=!0,j.svgSupported=!0):ee(navigator.userAgent,j);function ee(e,t){var n=t.browser,r=e.match(/Firefox\/([\d.]+)/),i=e.match(/MSIE\s([\d.]+)/)||e.match(/Trident\/.+?rv:(([\d.]+))/),a=e.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(e);if(r&&(n.firefox=!0,n.version=r[1]),i&&(n.ie=!0,n.version=i[1]),a&&(n.edge=!0,n.version=a[1],n.newEdge=+a[1].split(`.`)[0]>18),o&&(n.weChat=!0),t.svgSupported=typeof SVGRect<`u`,t.touchEventsSupported=`ontouchstart`in window&&!n.ie&&!n.edge,t.pointerEventsSupported=`onpointerdown`in window&&(n.edge||n.ie&&+n.version>=11),t.domSupported=typeof document<`u`){var s=document.documentElement.style;t.transform3dSupported=(n.ie&&`transition`in s||n.edge||`WebKitCSSMatrix`in window&&`m11`in new WebKitCSSMatrix||`MozPerspective`in s)&&!(`OTransition`in s),t.transformSupported=t.transform3dSupported||n.ie&&+n.version>=9}}var te=`12px sans-serif`,ne=20,re=100,ie=`007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N`;function ae(e){var t={};if(typeof JSON>`u`)return t;for(var n=0;n<e.length;n++){var r=String.fromCharCode(n+32);t[r]=(e.charCodeAt(n)-ne)/re}return t}var oe=ae(ie),M={createCanvas:function(){return typeof document<`u`&&document.createElement(`canvas`)},measureText:(function(){var e,t;return function(n,r){if(!e){var i=M.createCanvas();e=i&&i.getContext(`2d`)}if(e)return t!==r&&(t=e.font=r||`12px sans-serif`),e.measureText(n);n||=``,r||=`12px sans-serif`;var a=/((?:\d+)?\.?\d*)px/.exec(r),o=a&&+a[1]||12,s=0;if(r.indexOf(`mono`)>=0)s=o*n.length;else for(var c=0;c<n.length;c++){var l=oe[n[c]];s+=l==null?o:l*o}return{width:s}}})(),loadImage:function(e,t,n){var r=new Image;return r.onload=t,r.onerror=n,r.src=e,r},getTime:function(){return Date.now?Date.now():+new Date}},se=Te([`Function`,`RegExp`,`Date`,`Error`,`CanvasGradient`,`CanvasPattern`,`Image`,`Canvas`],function(e,t){return e[`[object `+t+`]`]=!0,e},{}),ce=Te([`Int8`,`Uint8`,`Uint8Clamped`,`Int16`,`Uint16`,`Int32`,`Uint32`,`Float32`,`Float64`],function(e,t){return e[`[object `+t+`Array]`]=!0,e},{}),le=Object.prototype.toString,ue=Array.prototype,de=ue.forEach,fe=ue.filter,N=ue.slice,pe=ue.map,me=function(){}.constructor,he=me?me.prototype:null,ge=`__proto__`,_e=2311,ve=2**53-1;function ye(){return _e>=ve&&(_e=0),_e++}function be(){var e=[...arguments];typeof console<`u`&&console.error.apply(console,e)}function P(e){if(typeof e!=`object`||!e)return e;var t=e,n=le.call(e);if(n===`[object Array]`){if(!Ke(e)){t=[];for(var r=0,i=e.length;r<i;r++)t[r]=P(e[r])}}else if(ce[n]){if(!Ke(e)){var a=e.constructor;if(a.from)t=a.from(e);else{t=new a(e.length);for(var r=0,i=e.length;r<i;r++)t[r]=e[r]}}}else if(!se[n]&&!Ke(e)&&!Pe(e))for(var o in t={},e)e.hasOwnProperty(o)&&o!==ge&&(t[o]=P(e[o]));return t}function F(e,t,n){if(!K(t)||!K(e))return n?P(t):e;for(var r in t)if(t.hasOwnProperty(r)&&r!==ge){var i=e[r],a=t[r];K(a)&&K(i)&&!U(a)&&!U(i)&&!Pe(a)&&!Pe(i)&&!Me(a)&&!Me(i)&&!Ke(a)&&!Ke(i)?F(i,a,n):(n||!(r in e))&&(e[r]=P(t[r]))}return e}function I(e,t){if(Object.assign)Object.assign(e,t);else for(var n in t)t.hasOwnProperty(n)&&n!==ge&&(e[n]=t[n]);return e}function xe(e,t,n){e||={};for(var r=0;r<n.length;r++){var i=n[r];e[i]=t[i]}return e}function L(e,t,n){for(var r=Oe(t),i=0,a=r.length;i<a;i++){var o=r[i];(n?t[o]!=null:e[o]==null)&&(e[o]=t[o])}return e}M.createCanvas;function R(e,t){if(e){if(e.indexOf)return e.indexOf(t);for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n}return-1}function Se(e,t){var n=e.prototype;function r(){}for(var i in r.prototype=t.prototype,e.prototype=new r,n)n.hasOwnProperty(i)&&(e.prototype[i]=n[i]);e.prototype.constructor=e,e.superClass=t}function Ce(e,t,n){if(e=`prototype`in e?e.prototype:e,t=`prototype`in t?t.prototype:t,Object.getOwnPropertyNames)for(var r=Object.getOwnPropertyNames(t),i=0;i<r.length;i++){var a=r[i];a!==`constructor`&&(n?t[a]!=null:e[a]==null)&&(e[a]=t[a])}else L(e,t,n)}function we(e){return!e||typeof e==`string`?!1:typeof e.length==`number`}function z(e,t,n){if(e&&t)if(e.forEach&&e.forEach===de)e.forEach(t,n);else if(e.length===+e.length)for(var r=0,i=e.length;r<i;r++)t.call(n,e[r],r,e);else for(var a in e)e.hasOwnProperty(a)&&t.call(n,e[a],a,e)}function B(e,t,n){if(!e)return[];if(!t)return Be(e);if(e.map&&e.map===pe)return e.map(t,n);for(var r=[],i=0,a=e.length;i<a;i++)r.push(t.call(n,e[i],i,e));return r}function Te(e,t,n,r){if(e&&t){for(var i=0,a=e.length;i<a;i++)n=t.call(r,n,e[i],i,e);return n}}function Ee(e,t,n){if(!e)return[];if(!t)return Be(e);if(e.filter&&e.filter===fe)return e.filter(t,n);for(var r=[],i=0,a=e.length;i<a;i++)t.call(n,e[i],i,e)&&r.push(e[i]);return r}function De(e,t,n){if(e&&t){for(var r=0,i=e.length;r<i;r++)if(t.call(n,e[r],r,e))return e[r]}}function Oe(e){if(!e)return[];if(Object.keys)return Object.keys(e);var t=[];for(var n in e)e.hasOwnProperty(n)&&t.push(n);return t}function ke(e,t){var n=[...arguments].slice(2);return function(){return e.apply(t,n.concat(N.call(arguments)))}}var V=he&&W(he.bind)?he.call.bind(he.bind):ke;function H(e){var t=[...arguments].slice(1);return function(){return e.apply(this,t.concat(N.call(arguments)))}}function U(e){return Array.isArray?Array.isArray(e):le.call(e)===`[object Array]`}function W(e){return typeof e==`function`}function G(e){return typeof e==`string`}function Ae(e){return le.call(e)===`[object String]`}function je(e){return typeof e==`number`}function K(e){var t=typeof e;return t===`function`||!!e&&t===`object`}function Me(e){return!!se[le.call(e)]}function Ne(e){return!!ce[le.call(e)]}function Pe(e){return typeof e==`object`&&typeof e.nodeType==`number`&&typeof e.ownerDocument==`object`}function Fe(e){return e.colorStops!=null}function Ie(e){return e.image!=null}function Le(e){return e!==e}function Re(){for(var e=[...arguments],t=0,n=e.length;t<n;t++)if(e[t]!=null)return e[t]}function q(e,t){return e??t}function ze(e,t,n){return e??t??n}function Be(e){var t=[...arguments].slice(1);return N.apply(e,t)}function Ve(e){if(typeof e==`number`)return[e,e,e,e];var t=e.length;return t===2?[e[0],e[1],e[0],e[1]]:t===3?[e[0],e[1],e[2],e[1]]:e}function He(e,t){if(!e)throw Error(t)}function Ue(e){return e==null?null:typeof e.trim==`function`?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,``)}var We=`__ec_primitive__`;function Ge(e){e[We]=!0}function Ke(e){return e[We]}var qe=function(){function e(){this.data={}}return e.prototype.delete=function(e){var t=this.has(e);return t&&delete this.data[e],t},e.prototype.has=function(e){return this.data.hasOwnProperty(e)},e.prototype.get=function(e){return this.data[e]},e.prototype.set=function(e,t){return this.data[e]=t,this},e.prototype.keys=function(){return Oe(this.data)},e.prototype.forEach=function(e){var t=this.data;for(var n in t)t.hasOwnProperty(n)&&e(t[n],n)},e}(),Je=typeof Map==`function`;function Ye(){return Je?new Map:new qe}var Xe=function(){function e(t){var n=U(t);this.data=Ye();var r=this;t instanceof e?t.each(i):t&&z(t,i);function i(e,t){n?r.set(e,t):r.set(t,e)}}return e.prototype.hasKey=function(e){return this.data.has(e)},e.prototype.get=function(e){return this.data.get(e)},e.prototype.set=function(e,t){return this.data.set(e,t),t},e.prototype.each=function(e,t){this.data.forEach(function(n,r){e.call(t,n,r)})},e.prototype.keys=function(){var e=this.data.keys();return Je?Array.from(e):e},e.prototype.removeKey=function(e){this.data.delete(e)},e}();function J(e){return new Xe(e)}function Ze(e,t){for(var n=new e.constructor(e.length+t.length),r=0;r<e.length;r++)n[r]=e[r];for(var i=e.length,r=0;r<t.length;r++)n[r+i]=t[r];return n}function Qe(e,t){var n;if(Object.create)n=Object.create(e);else{var r=function(){};r.prototype=e,n=new r}return t&&I(n,t),n}function $e(e){var t=e.style;t.webkitUserSelect=`none`,t.userSelect=`none`,t.webkitTapHighlightColor=`rgba(0,0,0,0)`,t[`-webkit-touch-callout`]=`none`}function et(e,t){return e.hasOwnProperty(t)}function tt(){}var nt=180/Math.PI,rt=function(e,t){return rt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},rt(e,t)};function it(e,t){if(typeof t!=`function`&&t!==null)throw TypeError(`Class extends value `+String(t)+` is not a constructor or null`);rt(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}function at(e,t){return e??=0,t??=0,[e,t]}function ot(e,t){return e[0]=t[0],e[1]=t[1],e}function st(e){return[e[0],e[1]]}function ct(e,t,n){return e[0]=t,e[1]=n,e}function lt(e,t,n){return e[0]=t[0]+n[0],e[1]=t[1]+n[1],e}function ut(e,t,n){return e[0]=t[0]-n[0],e[1]=t[1]-n[1],e}function dt(e){return Math.sqrt(ft(e))}function ft(e){return e[0]*e[0]+e[1]*e[1]}function pt(e,t,n){return e[0]=t[0]*n,e[1]=t[1]*n,e}function mt(e,t){var n=dt(t);return n===0?(e[0]=0,e[1]=0):(e[0]=t[0]/n,e[1]=t[1]/n),e}function ht(e,t){return Math.sqrt((e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1]))}var gt=ht;function _t(e,t){return(e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1])}var vt=_t;function yt(e,t,n){var r=t[0],i=t[1];return e[0]=n[0]*r+n[2]*i+n[4],e[1]=n[1]*r+n[3]*i+n[5],e}function bt(e,t,n){return e[0]=Math.min(t[0],n[0]),e[1]=Math.min(t[1],n[1]),e}function xt(e,t,n){return e[0]=Math.max(t[0],n[0]),e[1]=Math.max(t[1],n[1]),e}var St=function(){function e(e,t){this.target=e,this.topTarget=t&&t.topTarget}return e}(),Ct=function(){function e(e){this.handler=e,e.on(`mousedown`,this._dragStart,this),e.on(`mousemove`,this._drag,this),e.on(`mouseup`,this._dragEnd,this)}return e.prototype._dragStart=function(e){for(var t=e.target;t&&!t.draggable;)t=t.parent||t.__hostTarget;t&&(this._draggingTarget=t,t.dragging=!0,this._x=e.offsetX,this._y=e.offsetY,this.handler.dispatchToElement(new St(t,e),`dragstart`,e.event))},e.prototype._drag=function(e){var t=this._draggingTarget;if(t){var n=e.offsetX,r=e.offsetY,i=n-this._x,a=r-this._y;this._x=n,this._y=r,t.drift(i,a,e),this.handler.dispatchToElement(new St(t,e),`drag`,e.event);var o=this.handler.findHover(n,r,t).target,s=this._dropTarget;this._dropTarget=o,t!==o&&(s&&o!==s&&this.handler.dispatchToElement(new St(s,e),`dragleave`,e.event),o&&o!==s&&this.handler.dispatchToElement(new St(o,e),`dragenter`,e.event))}},e.prototype._dragEnd=function(e){var t=this._draggingTarget;t&&(t.dragging=!1),this.handler.dispatchToElement(new St(t,e),`dragend`,e.event),this._dropTarget&&this.handler.dispatchToElement(new St(this._dropTarget,e),`drop`,e.event),this._draggingTarget=null,this._dropTarget=null},e}(),wt=function(){function e(e){e&&(this._$eventProcessor=e)}return e.prototype.on=function(e,t,n,r){this._$handlers||={};var i=this._$handlers;if(typeof t==`function`&&(r=n,n=t,t=null),!n||!e)return this;var a=this._$eventProcessor;t!=null&&a&&a.normalizeQuery&&(t=a.normalizeQuery(t)),i[e]||(i[e]=[]);for(var o=0;o<i[e].length;o++)if(i[e][o].h===n)return this;var s={h:n,query:t,ctx:r||this,callAtLast:n.zrEventfulCallAtLast},c=i[e].length-1,l=i[e][c];return l&&l.callAtLast?i[e].splice(c,0,s):i[e].push(s),this},e.prototype.isSilent=function(e){var t=this._$handlers;return!t||!t[e]||!t[e].length},e.prototype.off=function(e,t){var n=this._$handlers;if(!n)return this;if(!e)return this._$handlers={},this;if(t){if(n[e]){for(var r=[],i=0,a=n[e].length;i<a;i++)n[e][i].h!==t&&r.push(n[e][i]);n[e]=r}n[e]&&n[e].length===0&&delete n[e]}else delete n[e];return this},e.prototype.trigger=function(e){var t=[...arguments].slice(1);if(!this._$handlers)return this;var n=this._$handlers[e],r=this._$eventProcessor;if(n)for(var i=t.length,a=n.length,o=0;o<a;o++){var s=n[o];if(!(r&&r.filter&&s.query!=null&&!r.filter(e,s.query)))switch(i){case 0:s.h.call(s.ctx);break;case 1:s.h.call(s.ctx,t[0]);break;case 2:s.h.call(s.ctx,t[0],t[1]);break;default:s.h.apply(s.ctx,t);break}}return r&&r.afterTrigger&&r.afterTrigger(e),this},e.prototype.triggerWithContext=function(e){var t=[...arguments].slice(1);if(!this._$handlers)return this;var n=this._$handlers[e],r=this._$eventProcessor;if(n)for(var i=t.length,a=t[i-1],o=n.length,s=0;s<o;s++){var c=n[s];if(!(r&&r.filter&&c.query!=null&&!r.filter(e,c.query)))switch(i){case 0:c.h.call(a);break;case 1:c.h.call(a,t[0]);break;case 2:c.h.call(a,t[0],t[1]);break;default:c.h.apply(a,t.slice(1,i-1));break}}return r&&r.afterTrigger&&r.afterTrigger(e),this},e}(),Tt=Math.log(2);function Et(e,t,n,r,i,a){var o=r+`-`+i,s=e.length;if(a.hasOwnProperty(o))return a[o];if(t===1){var c=Math.round(Math.log((1<<s)-1&~i)/Tt);return e[n][c]}for(var l=r|1<<n,u=n+1;r&1<<u;)u++;for(var d=0,f=0,p=0;f<s;f++){var m=1<<f;m&i||(d+=(p%2?-1:1)*e[n][f]*Et(e,t-1,u,l,i|m,a),p++)}return a[o]=d,d}function Dt(e,t){var n=[[e[0],e[1],1,0,0,0,-t[0]*e[0],-t[0]*e[1]],[0,0,0,e[0],e[1],1,-t[1]*e[0],-t[1]*e[1]],[e[2],e[3],1,0,0,0,-t[2]*e[2],-t[2]*e[3]],[0,0,0,e[2],e[3],1,-t[3]*e[2],-t[3]*e[3]],[e[4],e[5],1,0,0,0,-t[4]*e[4],-t[4]*e[5]],[0,0,0,e[4],e[5],1,-t[5]*e[4],-t[5]*e[5]],[e[6],e[7],1,0,0,0,-t[6]*e[6],-t[6]*e[7]],[0,0,0,e[6],e[7],1,-t[7]*e[6],-t[7]*e[7]]],r={},i=Et(n,8,0,0,0,r);if(i!==0){for(var a=[],o=0;o<8;o++)for(var s=0;s<8;s++)a[s]??(a[s]=0),a[s]+=((o+s)%2?-1:1)*Et(n,7,+(o===0),1<<o,1<<s,r)/i*t[o];return function(e,t,n){var r=t*a[6]+n*a[7]+1;e[0]=(t*a[0]+n*a[1]+a[2])/r,e[1]=(t*a[3]+n*a[4]+a[5])/r}}}var Ot=`___zrEVENTSAVED`,kt=[];function At(e,t,n,r,i){return Mt(kt,t,r,i,!0)&&Mt(e,n,kt[0],kt[1])}function jt(e,t){e&&n(e),t&&n(t);function n(e){var t=e[Ot];t&&(t.clearMarkers&&t.clearMarkers(),delete e[Ot])}}function Mt(e,t,n,r,i){if(t.getBoundingClientRect&&j.domSupported&&!Ft(t)){var a=t[Ot]||(t[Ot]={}),o=Pt(Nt(t,a),a,i);if(o)return o(e,n,r),!0}return!1}function Nt(e,t){var n=t.markers;if(n)return n;n=t.markers=[];for(var r=[`left`,`right`],i=[`top`,`bottom`],a=0;a<4;a++){var o=document.createElement(`div`),s=o.style,c=a%2,l=(a>>1)%2;s.cssText=[`position: absolute`,`visibility: hidden`,`padding: 0`,`margin: 0`,`border-width: 0`,`user-select: none`,`width:0`,`height:0`,r[c]+`:0`,i[l]+`:0`,r[1-c]+`:auto`,i[1-l]+`:auto`,``].join(`!important;`),e.appendChild(o),n.push(o)}return t.clearMarkers=function(){z(n,function(e){e.parentNode&&e.parentNode.removeChild(e)})},n}function Pt(e,t,n){for(var r=n?`invTrans`:`trans`,i=t[r],a=t.srcCoords,o=[],s=[],c=!0,l=0;l<4;l++){var u=e[l].getBoundingClientRect(),d=2*l,f=u.left,p=u.top;o.push(f,p),c=c&&a&&f===a[d]&&p===a[d+1],s.push(e[l].offsetLeft,e[l].offsetTop)}return c&&i?i:(t.srcCoords=o,t[r]=n?Dt(s,o):Dt(o,s))}function Ft(e){return e.nodeName.toUpperCase()===`CANVAS`}var It=/([&<>"'])/g,Lt={"&":`&amp;`,"<":`&lt;`,">":`&gt;`,'"':`&quot;`,"'":`&#39;`};function Rt(e){return e==null?``:(e+``).replace(It,function(e,t){return Lt[t]})}var zt=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Bt=[],Vt=j.browser.firefox&&+j.browser.version.split(`.`)[0]<39;function Ht(e,t,n,r){return n||={},r?Ut(e,t,n):Vt&&t.layerX!=null&&t.layerX!==t.offsetX?(n.zrX=t.layerX,n.zrY=t.layerY):t.offsetX==null?Ut(e,t,n):(n.zrX=t.offsetX,n.zrY=t.offsetY),n}function Ut(e,t,n){if(j.domSupported&&e.getBoundingClientRect){var r=t.clientX,i=t.clientY;if(Ft(e)){var a=e.getBoundingClientRect();n.zrX=r-a.left,n.zrY=i-a.top;return}else if(Mt(Bt,e,r,i)){n.zrX=Bt[0],n.zrY=Bt[1];return}}n.zrX=n.zrY=0}function Wt(e){return e||window.event}function Gt(e,t,n){if(t=Wt(t),t.zrX!=null)return t;var r=t.type;if(r&&r.indexOf(`touch`)>=0){var i=r===`touchend`?t.changedTouches[0]:t.targetTouches[0];i&&Ht(e,i,t,n)}else{Ht(e,t,t,n);var a=Kt(t);t.zrDelta=a?a/120:-(t.detail||0)/3}var o=t.button;return t.which==null&&o!==void 0&&zt.test(t.type)&&(t.which=o&1?1:o&2?3:o&4?2:0),t}function Kt(e){var t=e.wheelDelta;if(t)return t;var n=e.deltaX,r=e.deltaY;if(n==null||r==null)return t;var i=Math.abs(r===0?n:r),a=r>0?-1:r<0?1:n>0?-1:1;return 3*i*a}function qt(e,t,n,r){e.addEventListener(t,n,r)}function Jt(e,t,n,r){e.removeEventListener(t,n,r)}var Yt=function(e){e.preventDefault(),e.stopPropagation(),e.cancelBubble=!0};function Xt(e){return e.which===2||e.which===3}var Zt=function(){function e(){this._track=[]}return e.prototype.recognize=function(e,t,n){return this._doTrack(e,t,n),this._recognize(e)},e.prototype.clear=function(){return this._track.length=0,this},e.prototype._doTrack=function(e,t,n){var r=e.touches;if(r){for(var i={points:[],touches:[],target:t,event:e},a=0,o=r.length;a<o;a++){var s=r[a],c=Ht(n,s,{});i.points.push([c.zrX,c.zrY]),i.touches.push(s)}this._track.push(i)}},e.prototype._recognize=function(e){for(var t in en)if(en.hasOwnProperty(t)){var n=en[t](this._track,e);if(n)return n}},e}();function Qt(e){var t=e[1][0]-e[0][0],n=e[1][1]-e[0][1];return Math.sqrt(t*t+n*n)}function $t(e){return[(e[0][0]+e[1][0])/2,(e[0][1]+e[1][1])/2]}var en={pinch:function(e,t){var n=e.length;if(n){var r=(e[n-1]||{}).points,i=(e[n-2]||{}).points||r;if(i&&i.length>1&&r&&r.length>1){var a=Qt(r)/Qt(i);!isFinite(a)&&(a=1),t.pinchScale=a;var o=$t(r);return t.pinchX=o[0],t.pinchY=o[1],{type:`pinch`,target:e[0].target,event:t}}}}};function tn(){return[1,0,0,1,0,0]}function nn(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=1,e[4]=0,e[5]=0,e}function rn(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function an(e,t,n){var r=t[0]*n[0]+t[2]*n[1],i=t[1]*n[0]+t[3]*n[1],a=t[0]*n[2]+t[2]*n[3],o=t[1]*n[2]+t[3]*n[3],s=t[0]*n[4]+t[2]*n[5]+t[4],c=t[1]*n[4]+t[3]*n[5]+t[5];return e[0]=r,e[1]=i,e[2]=a,e[3]=o,e[4]=s,e[5]=c,e}function on(e,t,n){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4]+n[0],e[5]=t[5]+n[1],e}function sn(e,t,n,r){r===void 0&&(r=[0,0]);var i=t[0],a=t[2],o=t[4],s=t[1],c=t[3],l=t[5],u=Math.sin(n),d=Math.cos(n);return e[0]=i*d+s*u,e[1]=-i*u+s*d,e[2]=a*d+c*u,e[3]=-a*u+d*c,e[4]=d*(o-r[0])+u*(l-r[1])+r[0],e[5]=d*(l-r[1])-u*(o-r[0])+r[1],e}function cn(e,t,n){var r=n[0],i=n[1];return e[0]=t[0]*r,e[1]=t[1]*i,e[2]=t[2]*r,e[3]=t[3]*i,e[4]=t[4]*r,e[5]=t[5]*i,e}function ln(e,t){var n=t[0],r=t[2],i=t[4],a=t[1],o=t[3],s=t[5],c=n*o-a*r;return c?(c=1/c,e[0]=o*c,e[1]=-a*c,e[2]=-r*c,e[3]=n*c,e[4]=(r*s-o*i)*c,e[5]=(a*i-n*s)*c,e):null}var un=function(){function e(e,t){this.x=e||0,this.y=t||0}return e.prototype.copy=function(e){return this.x=e.x,this.y=e.y,this},e.prototype.clone=function(){return new e(this.x,this.y)},e.prototype.set=function(e,t){return this.x=e,this.y=t,this},e.prototype.equal=function(e){return e.x===this.x&&e.y===this.y},e.prototype.add=function(e){return this.x+=e.x,this.y+=e.y,this},e.prototype.scale=function(e){this.x*=e,this.y*=e},e.prototype.scaleAndAdd=function(e,t){this.x+=e.x*t,this.y+=e.y*t},e.prototype.sub=function(e){return this.x-=e.x,this.y-=e.y,this},e.prototype.dot=function(e){return this.x*e.x+this.y*e.y},e.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},e.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},e.prototype.normalize=function(){var e=this.len();return this.x/=e,this.y/=e,this},e.prototype.distance=function(e){var t=this.x-e.x,n=this.y-e.y;return Math.sqrt(t*t+n*n)},e.prototype.distanceSquare=function(e){var t=this.x-e.x,n=this.y-e.y;return t*t+n*n},e.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},e.prototype.transform=function(e){if(e){var t=this.x,n=this.y;return this.x=e[0]*t+e[2]*n+e[4],this.y=e[1]*t+e[3]*n+e[5],this}},e.prototype.toArray=function(e){return e[0]=this.x,e[1]=this.y,e},e.prototype.fromArray=function(e){this.x=e[0],this.y=e[1]},e.set=function(e,t,n){e.x=t,e.y=n},e.copy=function(e,t){e.x=t.x,e.y=t.y},e.len=function(e){return Math.sqrt(e.x*e.x+e.y*e.y)},e.lenSquare=function(e){return e.x*e.x+e.y*e.y},e.dot=function(e,t){return e.x*t.x+e.y*t.y},e.add=function(e,t,n){e.x=t.x+n.x,e.y=t.y+n.y},e.sub=function(e,t,n){e.x=t.x-n.x,e.y=t.y-n.y},e.scale=function(e,t,n){e.x=t.x*n,e.y=t.y*n},e.scaleAndAdd=function(e,t,n,r){e.x=t.x+n.x*r,e.y=t.y+n.y*r},e.lerp=function(e,t,n,r){var i=1-r;e.x=i*t.x+r*n.x,e.y=i*t.y+r*n.y},e}(),dn=Math.min,fn=Math.max,pn=Math.abs,mn=[`x`,`y`],hn=[`width`,`height`],gn=new un,_n=new un,vn=new un,yn=new un,bn=Pn(),xn=bn.minTv,Sn=bn.maxTv,Cn=[0,0],Y=function(){function e(e,t,n,r){Tn(this,e,t,n,r)}return e.set=function(e,t,n,r,i){return r<0&&(t+=r,r=-r),i<0&&(n+=i,i=-i),e.x=t,e.y=n,e.width=r,e.height=i,e},e.prototype.union=function(e){var t=dn(e.x,this.x),n=dn(e.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=fn(e.x+e.width,this.x+this.width)-t:this.width=e.width,isFinite(this.y)&&isFinite(this.height)?this.height=fn(e.y+e.height,this.y+this.height)-n:this.height=e.height,this.x=t,this.y=n},e.prototype.applyTransform=function(t){e.applyTransform(this,this,t)},e.prototype.calculateTransform=function(e){return Dn(tn(),this,e)},e.prototype.intersect=function(t,n,r){return e.intersect(this,t,n,r)},e.intersect=function(t,n,r,i){r&&un.set(r,0,0);var a=i&&i.outIntersectRect||null,o=i&&i.clamp;if(a&&(a.x=a.y=a.width=a.height=NaN),!t||!n)return!1;t instanceof e||(t=Tn(An,t.x,t.y,t.width,t.height)),n instanceof e||(n=Tn(jn,n.x,n.y,n.width,n.height));var s=!!r;bn.reset(i,s);var c=bn.touchThreshold,l=t.x+c,u=t.x+t.width-c,d=t.y+c,f=t.y+t.height-c,p=n.x+c,m=n.x+n.width-c,h=n.y+c,g=n.y+n.height-c;if(l>u||d>f||p>m||h>g)return!1;var _=!(u<p||m<l||f<h||g<d);return(s||a)&&(Cn[0]=1/0,Cn[1]=0,Nn(l,u,p,m,0,s,a,o),Nn(d,f,h,g,1,s,a,o),s&&un.copy(r,_?bn.useDir?bn.dirMinTv:xn:Sn)),_},e.contain=function(e,t,n){return t>=e.x&&t<=e.x+e.width&&n>=e.y&&n<=e.y+e.height},e.prototype.contain=function(t,n){return e.contain(this,t,n)},e.prototype.clone=function(){return new e(this.x,this.y,this.width,this.height)},e.prototype.copy=function(e){En(this,e)},e.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},e.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},e.prototype.isZero=function(){return this.width===0||this.height===0},e.create=function(t){return new e(t?t.x:0,t?t.y:0,t?t.width:0,t?t.height:0)},e.copy=function(e,t){return e.x=t.x,e.y=t.y,e.width=t.width,e.height=t.height,e},e.applyTransform=function(e,t,n){if(!n){e!==t&&En(e,t);return}if(n[1]<1e-5&&n[1]>-1e-5&&n[2]<1e-5&&n[2]>-1e-5){var r=n[0],i=n[3],a=n[4],o=n[5];e.x=t.x*r+a,e.y=t.y*i+o,e.width=t.width*r,e.height=t.height*i,e.width<0&&(e.x+=e.width,e.width=-e.width),e.height<0&&(e.y+=e.height,e.height=-e.height);return}gn.x=vn.x=t.x,gn.y=yn.y=t.y,_n.x=yn.x=t.x+t.width,_n.y=vn.y=t.y+t.height,gn.transform(n),yn.transform(n),_n.transform(n),vn.transform(n),e.x=dn(gn.x,_n.x,vn.x,yn.x),e.y=dn(gn.y,_n.y,vn.y,yn.y);var s=fn(gn.x,_n.x,vn.x,yn.x),c=fn(gn.y,_n.y,vn.y,yn.y);e.width=s-e.x,e.height=c-e.y},e.calculateTransform=function(e,t,n){var r=n.width/t.width,i=n.height/t.height;return e=nn(e||[]),on(e,e,ct(Mn,-t.x,-t.y)),cn(e,e,ct(Mn,r,i)),on(e,e,ct(Mn,n.x,n.y)),e},e}(),wn=Y.create,Tn=Y.set,En=Y.copy,Dn=Y.calculateTransform,On=Y.applyTransform,kn=Y.contain,An=new Y(0,0,0,0),jn=new Y(0,0,0,0),Mn=[];function Nn(e,t,n,r,i,a,o,s){var c=pn(t-n),l=pn(r-e),u=dn(c,l),d=mn[i],f=mn[1-i],p=hn[i];t<n||r<e?c<l?(a&&(Sn[d]=-c),s&&(o[d]=t,o[p]=0)):(a&&(Sn[d]=l),s&&(o[d]=e,o[p]=0)):(o&&(o[d]=fn(e,n),o[p]=dn(t,r)-o[d]),a&&(u<Cn[0]||bn.useDir)&&(Cn[0]=dn(u,Cn[0]),(c<l||!bn.bidirectional)&&(xn[d]=c,xn[f]=0,bn.useDir&&bn.calcDirMTV()),(c>=l||!bn.bidirectional)&&(xn[d]=-l,xn[f]=0,bn.useDir&&bn.calcDirMTV())))}function Pn(){var e=0,t=new un,n=new un,r={minTv:new un,maxTv:new un,useDir:!1,dirMinTv:new un,touchThreshold:0,bidirectional:!0,negativeSize:!1,reset:function(i,a){r.touchThreshold=0,i&&i.touchThreshold!=null&&(r.touchThreshold=fn(0,i.touchThreshold)),r.negativeSize=!1,a&&(r.minTv.set(1/0,1/0),r.maxTv.set(0,0),r.useDir=!1,i&&i.direction!=null&&(r.useDir=!0,r.dirMinTv.copy(r.minTv),n.copy(r.minTv),e=i.direction,r.bidirectional=i.bidirectional==null||!!i.bidirectional,r.bidirectional||t.set(Math.cos(e),Math.sin(e))))},calcDirMTV:function(){var a=r.minTv,o=r.dirMinTv,s=a.y*a.y+a.x*a.x,c=Math.sin(e),l=Math.cos(e),u=c*a.y+l*a.x;if(i(u)){i(a.x)&&i(a.y)&&o.set(0,0);return}if(n.x=s*l/u,n.y=s*c/u,i(n.x)&&i(n.y)){o.set(0,0);return}(r.bidirectional||t.dot(n)>0)&&n.len()<o.len()&&o.copy(n)}};function i(e){return pn(e)<1e-10}return r}var Fn=`silent`;function In(e,t,n){return{type:e,event:n,target:t.target,topTarget:t.topTarget,cancelBubble:!1,offsetX:n.zrX,offsetY:n.zrY,gestureEvent:n.gestureEvent,pinchX:n.pinchX,pinchY:n.pinchY,pinchScale:n.pinchScale,wheelDelta:n.zrDelta,zrByTouch:n.zrByTouch,which:n.which,stop:Ln}}function Ln(){Yt(this.event)}var Rn=function(e){it(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.handler=null,t}return t.prototype.dispose=function(){},t.prototype.setCursor=function(){},t}(wt),zn=function(){function e(e,t){this.x=e,this.y=t}return e}(),Bn=[`click`,`dblclick`,`mousewheel`,`mouseout`,`mouseup`,`mousedown`,`mousemove`,`contextmenu`],Vn=new Y(0,0,0,0),Hn=function(e){it(t,e);function t(t,n,r,i,a){var o=e.call(this)||this;return o._hovered=new zn(0,0),o.storage=t,o.painter=n,o.painterRoot=i,o._pointerSize=a,r||=new Rn,o.proxy=null,o.setHandlerProxy(r),o._draggingMgr=new Ct(o),o}return t.prototype.setHandlerProxy=function(e){this.proxy&&this.proxy.dispose(),e&&(z(Bn,function(t){e.on&&e.on(t,this[t],this)},this),e.handler=this),this.proxy=e},t.prototype.mousemove=function(e){var t=e.zrX,n=e.zrY,r=Gn(this,t,n),i=this._hovered,a=i.target;a&&!a.__zr&&(i=this.findHover(i.x,i.y),a=i.target);var o=this._hovered=r?new zn(t,n):this.findHover(t,n),s=o.target,c=this.proxy;c.setCursor&&c.setCursor(s?s.cursor:`default`),a&&s!==a&&this.dispatchToElement(i,`mouseout`,e),this.dispatchToElement(o,`mousemove`,e),s&&s!==a&&this.dispatchToElement(o,`mouseover`,e)},t.prototype.mouseout=function(e){var t=e.zrEventControl;t!==`only_globalout`&&this.dispatchToElement(this._hovered,`mouseout`,e),t!==`no_globalout`&&this.trigger(`globalout`,{type:`globalout`,event:e})},t.prototype.resize=function(){this._hovered=new zn(0,0)},t.prototype.dispatch=function(e,t){var n=this[e];n&&n.call(this,t)},t.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},t.prototype.setCursorStyle=function(e){var t=this.proxy;t.setCursor&&t.setCursor(e)},t.prototype.dispatchToElement=function(e,t,n){e||={};var r=e.target;if(!(r&&r.silent)){for(var i=`on`+t,a=In(t,e,n);r&&(r[i]&&(a.cancelBubble=!!r[i].call(r,a)),r.trigger(t,a),r=r.__hostTarget?r.__hostTarget:r.parent,!a.cancelBubble););a.cancelBubble||(this.trigger(t,a),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(e){typeof e[i]==`function`&&e[i].call(e,a),e.trigger&&e.trigger(t,a)}))}},t.prototype.findHover=function(e,t,n){var r=this.storage.getDisplayList(),i=new zn(e,t);if(Wn(r,i,e,t,n),this._pointerSize&&!i.target){for(var a=[],o=this._pointerSize,s=o/2,c=new Y(e-s,t-s,o,o),l=r.length-1;l>=0;l--){var u=r[l];u!==n&&!u.ignore&&!u.ignoreCoarsePointer&&(!u.parent||!u.parent.ignoreCoarsePointer)&&(Vn.copy(u.getBoundingRect()),u.transform&&Vn.applyTransform(u.transform),Vn.intersect(c)&&a.push(u))}if(a.length){for(var d=4,f=Math.PI/12,p=Math.PI*2,m=0;m<s;m+=d)for(var h=0;h<p;h+=f)if(Wn(a,i,e+m*Math.cos(h),t+m*Math.sin(h),n),i.target)return i}}return i},t.prototype.processGesture=function(e,t){this._gestureMgr||=new Zt;var n=this._gestureMgr;t===`start`&&n.clear();var r=n.recognize(e,this.findHover(e.zrX,e.zrY,null).target,this.proxy.dom);if(t===`end`&&n.clear(),r){var i=r.type;e.gestureEvent=i;var a=new zn;a.target=r.target,this.dispatchToElement(a,i,r.event)}},t}(wt);z([`click`,`mousedown`,`mouseup`,`mousewheel`,`dblclick`,`contextmenu`],function(e){Hn.prototype[e]=function(t){var n=t.zrX,r=t.zrY,i=Gn(this,n,r),a,o;if((e!==`mouseup`||!i)&&(a=this.findHover(n,r),o=a.target),e===`mousedown`)this._downEl=o,this._downPoint=[t.zrX,t.zrY],this._upEl=o;else if(e===`mouseup`)this._upEl=o;else if(e===`click`){if(this._downEl!==this._upEl||!this._downPoint||gt(this._downPoint,[t.zrX,t.zrY])>4)return;this._downPoint=null}this.dispatchToElement(a,e,t)}});function Un(e,t,n){if(e[e.rectHover?`rectContain`:`contain`](t,n)){for(var r=e,i=void 0,a=!1;r;){if(r.ignoreClip&&(a=!0),!a){var o=r.getClipPath();if(o&&!o.contain(t,n))return!1}r.silent&&(i=!0);var s=r.__hostTarget;r=s?r.ignoreHostSilent?null:s:r.parent}return i?Fn:!0}return!1}function Wn(e,t,n,r,i){for(var a=e.length-1;a>=0;a--){var o=e[a],s=void 0;if(o!==i&&!o.ignore&&(s=Un(o,n,r))&&(!t.topTarget&&(t.topTarget=o),s!==Fn)){t.target=o;break}}}function Gn(e,t,n){var r=e.painter;return t<0||t>r.getWidth()||n<0||n>r.getHeight()}var Kn=32,qn=7;function Jn(e){for(var t=0;e>=Kn;)t|=e&1,e>>=1;return e+t}function Yn(e,t,n,r){var i=t+1;if(i===n)return 1;if(r(e[i++],e[t])<0){for(;i<n&&r(e[i],e[i-1])<0;)i++;Xn(e,t,i)}else for(;i<n&&r(e[i],e[i-1])>=0;)i++;return i-t}function Xn(e,t,n){for(n--;t<n;){var r=e[t];e[t++]=e[n],e[n--]=r}}function Zn(e,t,n,r,i){for(r===t&&r++;r<n;r++){for(var a=e[r],o=t,s=r,c;o<s;)c=o+s>>>1,i(a,e[c])<0?s=c:o=c+1;var l=r-o;switch(l){case 3:e[o+3]=e[o+2];case 2:e[o+2]=e[o+1];case 1:e[o+1]=e[o];break;default:for(;l>0;)e[o+l]=e[o+l-1],l--}e[o]=a}}function Qn(e,t,n,r,i,a){var o=0,s=0,c=1;if(a(e,t[n+i])>0){for(s=r-i;c<s&&a(e,t[n+i+c])>0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s),o+=i,c+=i}else{for(s=i+1;c<s&&a(e,t[n+i-c])<=0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s);var l=o;o=i-c,c=i-l}for(o++;o<c;){var u=o+(c-o>>>1);a(e,t[n+u])>0?o=u+1:c=u}return c}function $n(e,t,n,r,i,a){var o=0,s=0,c=1;if(a(e,t[n+i])<0){for(s=i+1;c<s&&a(e,t[n+i-c])<0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s);var l=o;o=i-c,c=i-l}else{for(s=r-i;c<s&&a(e,t[n+i+c])>=0;)o=c,c=(c<<1)+1,c<=0&&(c=s);c>s&&(c=s),o+=i,c+=i}for(o++;o<c;){var u=o+(c-o>>>1);a(e,t[n+u])<0?c=u:o=u+1}return c}function er(e,t){var n=qn,r,i,a=0,o=[];r=[],i=[];function s(e,t){r[a]=e,i[a]=t,a+=1}function c(){for(;a>1;){var e=a-2;if(e>=1&&i[e-1]<=i[e]+i[e+1]||e>=2&&i[e-2]<=i[e]+i[e-1])i[e-1]<i[e+1]&&e--;else if(i[e]>i[e+1])break;u(e)}}function l(){for(;a>1;){var e=a-2;e>0&&i[e-1]<i[e+1]&&e--,u(e)}}function u(n){var o=r[n],s=i[n],c=r[n+1],l=i[n+1];i[n]=s+l,n===a-3&&(r[n+1]=r[n+2],i[n+1]=i[n+2]),a--;var u=$n(e[c],e,o,s,0,t);o+=u,s-=u,s!==0&&(l=Qn(e[o+s-1],e,c,l,l-1,t),l!==0&&(s<=l?d(o,s,c,l):f(o,s,c,l)))}function d(r,i,a,s){var c=0;for(c=0;c<i;c++)o[c]=e[r+c];var l=0,u=a,d=r;if(e[d++]=e[u++],--s===0){for(c=0;c<i;c++)e[d+c]=o[l+c];return}if(i===1){for(c=0;c<s;c++)e[d+c]=e[u+c];e[d+s]=o[l];return}for(var f=n,p,m,h;;){p=0,m=0,h=!1;do if(t(e[u],o[l])<0){if(e[d++]=e[u++],m++,p=0,--s===0){h=!0;break}}else if(e[d++]=o[l++],p++,m=0,--i===1){h=!0;break}while((p|m)<f);if(h)break;do{if(p=$n(e[u],o,l,i,0,t),p!==0){for(c=0;c<p;c++)e[d+c]=o[l+c];if(d+=p,l+=p,i-=p,i<=1){h=!0;break}}if(e[d++]=e[u++],--s===0){h=!0;break}if(m=Qn(o[l],e,u,s,0,t),m!==0){for(c=0;c<m;c++)e[d+c]=e[u+c];if(d+=m,u+=m,s-=m,s===0){h=!0;break}}if(e[d++]=o[l++],--i===1){h=!0;break}f--}while(p>=qn||m>=qn);if(h)break;f<0&&(f=0),f+=2}if(n=f,n<1&&(n=1),i===1){for(c=0;c<s;c++)e[d+c]=e[u+c];e[d+s]=o[l]}else if(i===0)throw Error();else for(c=0;c<i;c++)e[d+c]=o[l+c]}function f(r,i,a,s){var c=0;for(c=0;c<s;c++)o[c]=e[a+c];var l=r+i-1,u=s-1,d=a+s-1,f=0,p=0;if(e[d--]=e[l--],--i===0){for(f=d-(s-1),c=0;c<s;c++)e[f+c]=o[c];return}if(s===1){for(d-=i,l-=i,p=d+1,f=l+1,c=i-1;c>=0;c--)e[p+c]=e[f+c];e[d]=o[u];return}for(var m=n;;){var h=0,g=0,_=!1;do if(t(o[u],e[l])<0){if(e[d--]=e[l--],h++,g=0,--i===0){_=!0;break}}else if(e[d--]=o[u--],g++,h=0,--s===1){_=!0;break}while((h|g)<m);if(_)break;do{if(h=i-$n(o[u],e,r,i,i-1,t),h!==0){for(d-=h,l-=h,i-=h,p=d+1,f=l+1,c=h-1;c>=0;c--)e[p+c]=e[f+c];if(i===0){_=!0;break}}if(e[d--]=o[u--],--s===1){_=!0;break}if(g=s-Qn(e[l],o,0,s,s-1,t),g!==0){for(d-=g,u-=g,s-=g,p=d+1,f=u+1,c=0;c<g;c++)e[p+c]=o[f+c];if(s<=1){_=!0;break}}if(e[d--]=e[l--],--i===0){_=!0;break}m--}while(h>=qn||g>=qn);if(_)break;m<0&&(m=0),m+=2}if(n=m,n<1&&(n=1),s===1){for(d-=i,l-=i,p=d+1,f=l+1,c=i-1;c>=0;c--)e[p+c]=e[f+c];e[d]=o[u]}else if(s===0)throw Error();else for(f=d-(s-1),c=0;c<s;c++)e[f+c]=o[c]}return{mergeRuns:c,forceMergeRuns:l,pushRun:s}}function tr(e,t,n,r){n||=0,r||=e.length;var i=r-n;if(!(i<2)){var a=0;if(i<Kn){a=Yn(e,n,r,t),Zn(e,n,r,n+a,t);return}var o=er(e,t),s=Jn(i);do{if(a=Yn(e,n,r,t),a<s){var c=i;c>s&&(c=s),Zn(e,n,n+c,n+a,t),a=c}o.pushRun(n,a),o.mergeRuns(),i-=a,n+=a}while(i!==0);o.forceMergeRuns()}}var nr=!1;function rr(){nr||(nr=!0,console.warn(`z / z2 / zlevel of displayable is invalid, which may cause unexpected errors`))}function ir(e,t){return e.zlevel===t.zlevel?e.z===t.z?e.z2-t.z2:e.z-t.z:e.zlevel-t.zlevel}var ar=function(){function e(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=ir}return e.prototype.traverse=function(e,t){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(e,t)},e.prototype.getDisplayList=function(e,t){t||=!1;var n=this._displayList;return(e||!n.length)&&this.updateDisplayList(t),n},e.prototype.updateDisplayList=function(e){this._displayListLen=0;for(var t=this._roots,n=this._displayList,r=0,i=t.length;r<i;r++)this._updateAndAddDisplayable(t[r],null,e);n.length=this._displayListLen,tr(n,ir)},e.prototype._updateAndAddDisplayable=function(e,t,n){if(!(e.ignore&&!n)){e.beforeUpdate(),e.update(),e.afterUpdate();var r=e.getClipPath(),i=t&&t.length,a=0,o=e.__clipPaths;if(!e.ignoreClip&&(i||r)){if(o||=e.__clipPaths=[],i)for(var s=0;s<t.length;s++)o[a++]=t[s];for(var c=r,l=e;c;)c.parent=l,c.updateTransform(),o[a++]=c,l=c,c=c.getClipPath()}if(o&&(o.length=a),e.childrenRef){for(var u=e.childrenRef(),d=0;d<u.length;d++){var f=u[d];e.__dirty&&(f.__dirty|=1),this._updateAndAddDisplayable(f,o,n)}e.__dirty=0}else{var p=e;isNaN(p.z)&&(rr(),p.z=0),isNaN(p.z2)&&(rr(),p.z2=0),isNaN(p.zlevel)&&(rr(),p.zlevel=0),this._displayList[this._displayListLen++]=p}var m=e.getDecalElement&&e.getDecalElement();m&&this._updateAndAddDisplayable(m,o,n);var h=e.getTextGuideLine();h&&this._updateAndAddDisplayable(h,o,n);var g=e.getTextContent();g&&this._updateAndAddDisplayable(g,o,n)}},e.prototype.addRoot=function(e){e.__zr&&e.__zr.storage===this||this._roots.push(e)},e.prototype.delRoot=function(e){if(e instanceof Array){for(var t=0,n=e.length;t<n;t++)this.delRoot(e[t]);return}var r=R(this._roots,e);r>=0&&this._roots.splice(r,1)},e.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},e.prototype.getRoots=function(){return this._roots},e.prototype.dispose=function(){this._displayList=null,this._roots=null},e}(),or=j.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(e){return setTimeout(e,16)},sr={linear:function(e){return e},quadraticIn:function(e){return e*e},quadraticOut:function(e){return e*(2-e)},quadraticInOut:function(e){return(e*=2)<1?.5*e*e:-.5*(--e*(e-2)-1)},cubicIn:function(e){return e*e*e},cubicOut:function(e){return--e*e*e+1},cubicInOut:function(e){return(e*=2)<1?.5*e*e*e:.5*((e-=2)*e*e+2)},quarticIn:function(e){return e*e*e*e},quarticOut:function(e){return 1- --e*e*e*e},quarticInOut:function(e){return(e*=2)<1?.5*e*e*e*e:-.5*((e-=2)*e*e*e-2)},quinticIn:function(e){return e*e*e*e*e},quinticOut:function(e){return--e*e*e*e*e+1},quinticInOut:function(e){return(e*=2)<1?.5*e*e*e*e*e:.5*((e-=2)*e*e*e*e+2)},sinusoidalIn:function(e){return 1-Math.cos(e*Math.PI/2)},sinusoidalOut:function(e){return Math.sin(e*Math.PI/2)},sinusoidalInOut:function(e){return .5*(1-Math.cos(Math.PI*e))},exponentialIn:function(e){return e===0?0:1024**(e-1)},exponentialOut:function(e){return e===1?1:1-2**(-10*e)},exponentialInOut:function(e){return e===0?0:e===1?1:(e*=2)<1?.5*1024**(e-1):.5*(-(2**(-10*(e-1)))+2)},circularIn:function(e){return 1-Math.sqrt(1-e*e)},circularOut:function(e){return Math.sqrt(1- --e*e)},circularInOut:function(e){return(e*=2)<1?-.5*(Math.sqrt(1-e*e)-1):.5*(Math.sqrt(1-(e-=2)*e)+1)},elasticIn:function(e){var t,n=.1,r=.4;return e===0?0:e===1?1:(!n||n<1?(n=1,t=r/4):t=r*Math.asin(1/n)/(2*Math.PI),-(n*2**(10*--e)*Math.sin((e-t)*(2*Math.PI)/r)))},elasticOut:function(e){var t,n=.1,r=.4;return e===0?0:e===1?1:(!n||n<1?(n=1,t=r/4):t=r*Math.asin(1/n)/(2*Math.PI),n*2**(-10*e)*Math.sin((e-t)*(2*Math.PI)/r)+1)},elasticInOut:function(e){var t,n=.1,r=.4;return e===0?0:e===1?1:(!n||n<1?(n=1,t=r/4):t=r*Math.asin(1/n)/(2*Math.PI),(e*=2)<1?-.5*(n*2**(10*--e)*Math.sin((e-t)*(2*Math.PI)/r)):n*2**(-10*--e)*Math.sin((e-t)*(2*Math.PI)/r)*.5+1)},backIn:function(e){var t=1.70158;return e*e*((t+1)*e-t)},backOut:function(e){var t=1.70158;return--e*e*((t+1)*e+t)+1},backInOut:function(e){var t=1.70158*1.525;return(e*=2)<1?.5*(e*e*((t+1)*e-t)):.5*((e-=2)*e*((t+1)*e+t)+2)},bounceIn:function(e){return 1-sr.bounceOut(1-e)},bounceOut:function(e){return e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375},bounceInOut:function(e){return e<.5?sr.bounceIn(e*2)*.5:sr.bounceOut(e*2-1)*.5+.5}},cr=Math.pow,lr=Math.sqrt,ur=1e-8,dr=1e-4,fr=lr(3),pr=1/3,mr=at(),hr=at(),gr=at();function _r(e){return e>-ur&&e<ur}function vr(e){return e>ur||e<-ur}function yr(e,t,n,r,i){var a=1-i;return a*a*(a*e+3*i*t)+i*i*(i*r+3*a*n)}function br(e,t,n,r,i){var a=1-i;return 3*(((t-e)*a+2*(n-t)*i)*a+(r-n)*i*i)}function xr(e,t,n,r,i,a){var o=r+3*(t-n)-e,s=3*(n-t*2+e),c=3*(t-e),l=e-i,u=s*s-3*o*c,d=s*c-9*o*l,f=c*c-3*s*l,p=0;if(_r(u)&&_r(d))if(_r(s))a[0]=0;else{var m=-c/s;m>=0&&m<=1&&(a[p++]=m)}else{var h=d*d-4*u*f;if(_r(h)){var g=d/u,m=-s/o+g,_=-g/2;m>=0&&m<=1&&(a[p++]=m),_>=0&&_<=1&&(a[p++]=_)}else if(h>0){var v=lr(h),y=u*s+1.5*o*(-d+v),b=u*s+1.5*o*(-d-v);y=y<0?-cr(-y,pr):cr(y,pr),b=b<0?-cr(-b,pr):cr(b,pr);var m=(-s-(y+b))/(3*o);m>=0&&m<=1&&(a[p++]=m)}else{var x=(2*u*s-3*o*d)/(2*lr(u*u*u)),S=Math.acos(x)/3,C=lr(u),w=Math.cos(S),m=(-s-2*C*w)/(3*o),_=(-s+C*(w+fr*Math.sin(S)))/(3*o),T=(-s+C*(w-fr*Math.sin(S)))/(3*o);m>=0&&m<=1&&(a[p++]=m),_>=0&&_<=1&&(a[p++]=_),T>=0&&T<=1&&(a[p++]=T)}}return p}function Sr(e,t,n,r,i){var a=6*n-12*t+6*e,o=9*t+3*r-3*e-9*n,s=3*t-3*e,c=0;if(_r(o)){if(vr(a)){var l=-s/a;l>=0&&l<=1&&(i[c++]=l)}}else{var u=a*a-4*o*s;if(_r(u))i[0]=-a/(2*o);else if(u>0){var d=lr(u),l=(-a+d)/(2*o),f=(-a-d)/(2*o);l>=0&&l<=1&&(i[c++]=l),f>=0&&f<=1&&(i[c++]=f)}}return c}function Cr(e,t,n,r,i,a){var o=(t-e)*i+e,s=(n-t)*i+t,c=(r-n)*i+n,l=(s-o)*i+o,u=(c-s)*i+s,d=(u-l)*i+l;a[0]=e,a[1]=o,a[2]=l,a[3]=d,a[4]=d,a[5]=u,a[6]=c,a[7]=r}function wr(e,t,n,r,i,a,o,s,c,l,u){var d,f=.005,p=1/0,m,h,g,_;mr[0]=c,mr[1]=l;for(var v=0;v<1;v+=.05)hr[0]=yr(e,n,i,o,v),hr[1]=yr(t,r,a,s,v),g=vt(mr,hr),g<p&&(d=v,p=g);p=1/0;for(var y=0;y<32&&!(f<dr);y++)m=d-f,h=d+f,hr[0]=yr(e,n,i,o,m),hr[1]=yr(t,r,a,s,m),g=vt(hr,mr),m>=0&&g<p?(d=m,p=g):(gr[0]=yr(e,n,i,o,h),gr[1]=yr(t,r,a,s,h),_=vt(gr,mr),h<=1&&_<p?(d=h,p=_):f*=.5);return u&&(u[0]=yr(e,n,i,o,d),u[1]=yr(t,r,a,s,d)),lr(p)}function Tr(e,t,n,r,i,a,o,s,c){for(var l=e,u=t,d=0,f=1/c,p=1;p<=c;p++){var m=p*f,h=yr(e,n,i,o,m),g=yr(t,r,a,s,m),_=h-l,v=g-u;d+=Math.sqrt(_*_+v*v),l=h,u=g}return d}function Er(e,t,n,r){var i=1-r;return i*(i*e+2*r*t)+r*r*n}function Dr(e,t,n,r){return 2*((1-r)*(t-e)+r*(n-t))}function Or(e,t,n,r,i){var a=e-2*t+n,o=2*(t-e),s=e-r,c=0;if(_r(a)){if(vr(o)){var l=-s/o;l>=0&&l<=1&&(i[c++]=l)}}else{var u=o*o-4*a*s;if(_r(u)){var l=-o/(2*a);l>=0&&l<=1&&(i[c++]=l)}else if(u>0){var d=lr(u),l=(-o+d)/(2*a),f=(-o-d)/(2*a);l>=0&&l<=1&&(i[c++]=l),f>=0&&f<=1&&(i[c++]=f)}}return c}function kr(e,t,n){var r=e+n-2*t;return r===0?.5:(e-t)/r}function Ar(e,t,n,r,i){var a=(t-e)*r+e,o=(n-t)*r+t,s=(o-a)*r+a;i[0]=e,i[1]=a,i[2]=s,i[3]=s,i[4]=o,i[5]=n}function jr(e,t,n,r,i,a,o,s,c){var l,u=.005,d=1/0;mr[0]=o,mr[1]=s;for(var f=0;f<1;f+=.05){hr[0]=Er(e,n,i,f),hr[1]=Er(t,r,a,f);var p=vt(mr,hr);p<d&&(l=f,d=p)}d=1/0;for(var m=0;m<32&&!(u<dr);m++){var h=l-u,g=l+u;hr[0]=Er(e,n,i,h),hr[1]=Er(t,r,a,h);var p=vt(hr,mr);if(h>=0&&p<d)l=h,d=p;else{gr[0]=Er(e,n,i,g),gr[1]=Er(t,r,a,g);var _=vt(gr,mr);g<=1&&_<d?(l=g,d=_):u*=.5}}return c&&(c[0]=Er(e,n,i,l),c[1]=Er(t,r,a,l)),lr(d)}function Mr(e,t,n,r,i,a,o){for(var s=e,c=t,l=0,u=1/o,d=1;d<=o;d++){var f=d*u,p=Er(e,n,i,f),m=Er(t,r,a,f),h=p-s,g=m-c;l+=Math.sqrt(h*h+g*g),s=p,c=m}return l}var Nr=/cubic-bezier\(([0-9,\.e ]+)\)/;function Pr(e){var t=e&&Nr.exec(e);if(t){var n=t[1].split(`,`),r=+Ue(n[0]),i=+Ue(n[1]),a=+Ue(n[2]),o=+Ue(n[3]);if(isNaN(r+i+a+o))return;var s=[];return function(e){return e<=0?0:e>=1?1:xr(0,r,a,1,e,s)&&yr(0,i,o,1,s[0])}}}var Fr=function(){function e(e){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=e.life||1e3,this._delay=e.delay||0,this.loop=e.loop||!1,this.onframe=e.onframe||tt,this.ondestroy=e.ondestroy||tt,this.onrestart=e.onrestart||tt,e.easing&&this.setEasing(e.easing)}return e.prototype.step=function(e,t){if(this._inited||=(this._startTime=e+this._delay,!0),this._paused){this._pausedTime+=t;return}var n=this._life,r=e-this._startTime-this._pausedTime,i=r/n;i<0&&(i=0),i=Math.min(i,1);var a=this.easingFunc,o=a?a(i):i;if(this.onframe(o),i===1)if(this.loop){var s=r%n;this._startTime=e-s,this._pausedTime=0,this.onrestart()}else return!0;return!1},e.prototype.pause=function(){this._paused=!0},e.prototype.resume=function(){this._paused=!1},e.prototype.setEasing=function(e){this.easing=e,this.easingFunc=W(e)?e:sr[e]||Pr(e)},e}(),Ir=function(){function e(e){this.value=e}return e}(),Lr=function(){function e(){this._len=0}return e.prototype.insert=function(e){var t=new Ir(e);return this.insertEntry(t),t},e.prototype.insertEntry=function(e){this.head?(this.tail.next=e,e.prev=this.tail,e.next=null,this.tail=e):this.head=this.tail=e,this._len++},e.prototype.remove=function(e){var t=e.prev,n=e.next;t?t.next=n:this.head=n,n?n.prev=t:this.tail=t,e.next=e.prev=null,this._len--},e.prototype.len=function(){return this._len},e.prototype.clear=function(){this.head=this.tail=null,this._len=0},e}(),Rr=function(){function e(e){this._list=new Lr,this._maxSize=10,this._map={},this._maxSize=e}return e.prototype.put=function(e,t){var n=this._list,r=this._map,i=null;if(r[e]==null){var a=n.len(),o=this._lastRemovedEntry;if(a>=this._maxSize&&a>0){var s=n.head;n.remove(s),delete r[s.key],i=s.value,this._lastRemovedEntry=s}o?o.value=t:o=new Ir(t),o.key=e,n.insertEntry(o),r[e]=o}return i},e.prototype.get=function(e){var t=this._map[e],n=this._list;if(t!=null)return t!==n.tail&&(n.remove(t),n.insertEntry(t)),t.value},e.prototype.clear=function(){this._list.clear(),this._map={}},e.prototype.len=function(){return this._list.len()},e}(),zr={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 Br(e){return e=Math.round(e),e<0?0:e>255?255:e}function Vr(e){return e=Math.round(e),e<0?0:e>360?360:e}function Hr(e){return e<0?0:e>1?1:e}function Ur(e){var t=e;return t.length&&t.charAt(t.length-1)===`%`?Br(parseFloat(t)/100*255):Br(parseInt(t,10))}function Wr(e){var t=e;return t.length&&t.charAt(t.length-1)===`%`?Hr(parseFloat(t)/100):Hr(parseFloat(t))}function Gr(e,t,n){return n<0?n+=1:n>1&&--n,n*6<1?e+(t-e)*n*6:n*2<1?t:n*3<2?e+(t-e)*(2/3-n)*6:e}function Kr(e,t,n){return e+(t-e)*n}function qr(e,t,n,r,i){return e[0]=t,e[1]=n,e[2]=r,e[3]=i,e}function Jr(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}var Yr=new Rr(20),Xr=null;function Zr(e,t){Xr&&Jr(Xr,t),Xr=Yr.put(e,Xr||t.slice())}function Qr(e,t){if(e){t||=[];var n=Yr.get(e);if(n)return Jr(t,n);e+=``;var r=e.replace(/ /g,``).toLowerCase();if(r in zr)return Jr(t,zr[r]),Zr(e,t),t;var i=r.length;if(r.charAt(0)===`#`){if(i===4||i===5){var a=parseInt(r.slice(1,4),16);if(!(a>=0&&a<=4095)){qr(t,0,0,0,1);return}return qr(t,(a&3840)>>4|(a&3840)>>8,a&240|(a&240)>>4,a&15|(a&15)<<4,i===5?parseInt(r.slice(4),16)/15:1),Zr(e,t),t}else if(i===7||i===9){var a=parseInt(r.slice(1,7),16);if(!(a>=0&&a<=16777215)){qr(t,0,0,0,1);return}return qr(t,(a&16711680)>>16,(a&65280)>>8,a&255,i===9?parseInt(r.slice(7),16)/255:1),Zr(e,t),t}return}var o=r.indexOf(`(`),s=r.indexOf(`)`);if(o!==-1&&s+1===i){var c=r.substr(0,o),l=r.substr(o+1,s-(o+1)).split(`,`),u=1;switch(c){case`rgba`:if(l.length!==4)return l.length===3?qr(t,+l[0],+l[1],+l[2],1):qr(t,0,0,0,1);u=Wr(l.pop());case`rgb`:if(l.length>=3)return qr(t,Ur(l[0]),Ur(l[1]),Ur(l[2]),l.length===3?u:Wr(l[3])),Zr(e,t),t;qr(t,0,0,0,1);return;case`hsla`:if(l.length!==4){qr(t,0,0,0,1);return}return l[3]=Wr(l[3]),$r(l,t),Zr(e,t),t;case`hsl`:if(l.length!==3){qr(t,0,0,0,1);return}return $r(l,t),Zr(e,t),t;default:return}}qr(t,0,0,0,1)}}function $r(e,t){var n=(parseFloat(e[0])%360+360)%360/360,r=Wr(e[1]),i=Wr(e[2]),a=i<=.5?i*(r+1):i+r-i*r,o=i*2-a;return t||=[],qr(t,Br(Gr(o,a,n+1/3)*255),Br(Gr(o,a,n)*255),Br(Gr(o,a,n-1/3)*255),1),e.length===4&&(t[3]=e[3]),t}function ei(e){if(e){var t=e[0]/255,n=e[1]/255,r=e[2]/255,i=Math.min(t,n,r),a=Math.max(t,n,r),o=a-i,s=(a+i)/2,c,l;if(o===0)c=0,l=0;else{l=s<.5?o/(a+i):o/(2-a-i);var u=((a-t)/6+o/2)/o,d=((a-n)/6+o/2)/o,f=((a-r)/6+o/2)/o;t===a?c=f-d:n===a?c=1/3+u-f:r===a&&(c=2/3+d-u),c<0&&(c+=1),c>1&&--c}var p=[c*360,l,s];return e[3]!=null&&p.push(e[3]),p}}function ti(e,t){var n=Qr(e);if(n){for(var r=0;r<3;r++)t<0?n[r]=n[r]*(1-t)|0:n[r]=(255-n[r])*t+n[r]|0,n[r]>255?n[r]=255:n[r]<0&&(n[r]=0);return ii(n,n.length===4?`rgba`:`rgb`)}}function ni(e,t,n){if(!(!(t&&t.length)||!(e>=0&&e<=1))){var r=e*(t.length-1),i=Math.floor(r),a=Math.ceil(r),o=Qr(t[i]),s=Qr(t[a]),c=r-i,l=ii([Br(Kr(o[0],s[0],c)),Br(Kr(o[1],s[1],c)),Br(Kr(o[2],s[2],c)),Hr(Kr(o[3],s[3],c))],`rgba`);return n?{color:l,leftIndex:i,rightIndex:a,value:r}:l}}function ri(e,t,n,r){var i=Qr(e);if(e)return i=ei(i),t!=null&&(i[0]=Vr(W(t)?t(i[0]):t)),n!=null&&(i[1]=Wr(W(n)?n(i[1]):n)),r!=null&&(i[2]=Wr(W(r)?r(i[2]):r)),ii($r(i),`rgba`)}function ii(e,t){if(!(!e||!e.length)){var n=e[0]+`,`+e[1]+`,`+e[2];return(t===`rgba`||t===`hsva`||t===`hsla`)&&(n+=`,`+e[3]),t+`(`+n+`)`}}function ai(e,t){var n=Qr(e);return n?(.299*n[0]+.587*n[1]+.114*n[2])*n[3]/255+(1-n[3])*t:0}var oi=new Rr(100);function si(e){if(G(e)){var t=oi.get(e);return t||(t=ti(e,-.1),oi.put(e,t)),t}else if(Fe(e)){var n=I({},e);return n.colorStops=B(e.colorStops,function(e){return{offset:e.offset,color:ti(e.color,-.1)}}),n}return e}function ci(e){return e.type===`linear`}function li(e){return e.type===`radial`}(function(){return typeof Buffer<`u`&&typeof Buffer.from==`function`?function(e){return Buffer.from(e).toString(`base64`)}:typeof btoa==`function`&&typeof unescape==`function`&&typeof encodeURIComponent==`function`?function(e){return btoa(unescape(encodeURIComponent(e)))}:function(e){return null}})();var ui=Array.prototype.slice;function di(e,t,n){return(t-e)*n+e}function fi(e,t,n,r){for(var i=t.length,a=0;a<i;a++)e[a]=di(t[a],n[a],r);return e}function pi(e,t,n,r){for(var i=t.length,a=i&&t[0].length,o=0;o<i;o++){e[o]||(e[o]=[]);for(var s=0;s<a;s++)e[o][s]=di(t[o][s],n[o][s],r)}return e}function mi(e,t,n,r){for(var i=t.length,a=0;a<i;a++)e[a]=t[a]+n[a]*r;return e}function hi(e,t,n,r){for(var i=t.length,a=i&&t[0].length,o=0;o<i;o++){e[o]||(e[o]=[]);for(var s=0;s<a;s++)e[o][s]=t[o][s]+n[o][s]*r}return e}function gi(e,t){for(var n=e.length,r=t.length,i=n>r?t:e,a=Math.min(n,r),o=i[a-1]||{color:[0,0,0,0],offset:0},s=a;s<Math.max(n,r);s++)i.push({offset:o.offset,color:o.color.slice()})}function _i(e,t,n){var r=e,i=t;if(!(!r.push||!i.push)){var a=r.length,o=i.length;if(a!==o)if(a>o)r.length=o;else for(var s=a;s<o;s++)r.push(n===1?i[s]:ui.call(i[s]));for(var c=r[0]&&r[0].length,s=0;s<r.length;s++)if(n===1)isNaN(r[s])&&(r[s]=i[s]);else for(var l=0;l<c;l++)isNaN(r[s][l])&&(r[s][l]=i[s][l])}}function vi(e){if(we(e)){var t=e.length;if(we(e[0])){for(var n=[],r=0;r<t;r++)n.push(ui.call(e[r]));return n}return ui.call(e)}return e}function yi(e){return e[0]=Math.floor(e[0])||0,e[1]=Math.floor(e[1])||0,e[2]=Math.floor(e[2])||0,e[3]=e[3]==null?1:e[3],`rgba(`+e.join(`,`)+`)`}function bi(e){return we(e&&e[0])?2:1}var xi=0,Si=1,Ci=2,wi=3,Ti=4,Ei=5,Di=6;function Oi(e){return e===Ti||e===Ei}function ki(e){return e===Si||e===Ci}var Ai=[0,0,0,0],ji=function(){function e(e){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=e}return e.prototype.isFinished=function(){return this._finished},e.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},e.prototype.needsAnimate=function(){return this.keyframes.length>=1},e.prototype.getAdditiveTrack=function(){return this._additiveTrack},e.prototype.addKeyframe=function(e,t,n){this._needsSort=!0;var r=this.keyframes,i=r.length,a=!1,o=Di,s=t;if(we(t)){var c=bi(t);o=c,(c===1&&!je(t[0])||c===2&&!je(t[0][0]))&&(a=!0)}else if(je(t)&&!Le(t))o=xi;else if(G(t))if(!isNaN(+t))o=xi;else{var l=Qr(t);l&&(s=l,o=wi)}else if(Fe(t)){var u=I({},s);u.colorStops=B(t.colorStops,function(e){return{offset:e.offset,color:Qr(e.color)}}),ci(t)?o=Ti:li(t)&&(o=Ei),s=u}i===0?this.valType=o:(o!==this.valType||o===Di)&&(a=!0),this.discrete=this.discrete||a;var d={time:e,value:s,rawValue:t,percent:0};return n&&(d.easing=n,d.easingFunc=W(n)?n:sr[n]||Pr(n)),r.push(d),d},e.prototype.prepare=function(e,t){var n=this.keyframes;this._needsSort&&n.sort(function(e,t){return e.time-t.time});for(var r=this.valType,i=n.length,a=n[i-1],o=this.discrete,s=ki(r),c=Oi(r),l=0;l<i;l++){var u=n[l],d=u.value,f=a.value;u.percent=u.time/e,o||(s&&l!==i-1?_i(d,f,r):c&&gi(d.colorStops,f.colorStops))}if(!o&&r!==Ei&&t&&this.needsAnimate()&&t.needsAnimate()&&r===t.valType&&!t._finished){this._additiveTrack=t;for(var p=n[0].value,l=0;l<i;l++)r===xi?n[l].additiveValue=n[l].value-p:r===wi?n[l].additiveValue=mi([],n[l].value,p,-1):ki(r)&&(n[l].additiveValue=r===Si?mi([],n[l].value,p,-1):hi([],n[l].value,p,-1))}},e.prototype.step=function(e,t){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var n=this._additiveTrack!=null,r=n?`additiveValue`:`value`,i=this.valType,a=this.keyframes,o=a.length,s=this.propName,c=i===wi,l,u=this._lastFr,d=Math.min,f,p;if(o===1)f=p=a[0];else{if(t<0)l=0;else if(t<this._lastFrP){for(l=d(u+1,o-1);l>=0&&!(a[l].percent<=t);l--);l=d(l,o-2)}else{for(l=u;l<o&&!(a[l].percent>t);l++);l=d(l-1,o-2)}p=a[l+1],f=a[l]}if(f&&p){this._lastFr=l,this._lastFrP=t;var m=p.percent-f.percent,h=m===0?1:d((t-f.percent)/m,1);p.easingFunc&&(h=p.easingFunc(h));var g=n?this._additiveValue:c?Ai:e[s];if((ki(i)||c)&&!g&&(g=this._additiveValue=[]),this.discrete)e[s]=h<1?f.rawValue:p.rawValue;else if(ki(i))i===Si?fi(g,f[r],p[r],h):pi(g,f[r],p[r],h);else if(Oi(i)){var _=f[r],v=p[r],y=i===Ti;e[s]={type:y?`linear`:`radial`,x:di(_.x,v.x,h),y:di(_.y,v.y,h),colorStops:B(_.colorStops,function(e,t){var n=v.colorStops[t];return{offset:di(e.offset,n.offset,h),color:yi(fi([],e.color,n.color,h))}}),global:v.global},y?(e[s].x2=di(_.x2,v.x2,h),e[s].y2=di(_.y2,v.y2,h)):e[s].r=di(_.r,v.r,h)}else if(c)fi(g,f[r],p[r],h),n||(e[s]=yi(g));else{var b=di(f[r],p[r],h);n?this._additiveValue=b:e[s]=b}n&&this._addToTarget(e)}}},e.prototype._addToTarget=function(e){var t=this.valType,n=this.propName,r=this._additiveValue;t===xi?e[n]=e[n]+r:t===wi?(Qr(e[n],Ai),mi(Ai,Ai,r,1),e[n]=yi(Ai)):t===Si?mi(e[n],e[n],r,1):t===Ci&&hi(e[n],e[n],r,1)},e}(),Mi=function(){function e(e,t,n,r){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=e,this._loop=t,t&&r){be(`Can' use additive animation on looped animation.`);return}this._additiveAnimators=r,this._allowDiscrete=n}return e.prototype.getMaxTime=function(){return this._maxTime},e.prototype.getDelay=function(){return this._delay},e.prototype.getLoop=function(){return this._loop},e.prototype.getTarget=function(){return this._target},e.prototype.changeTarget=function(e){this._target=e},e.prototype.when=function(e,t,n){return this.whenWithKeys(e,t,Oe(t),n)},e.prototype.whenWithKeys=function(e,t,n,r){for(var i=this._tracks,a=0;a<n.length;a++){var o=n[a],s=i[o];if(!s){s=i[o]=new ji(o);var c=void 0,l=this._getAdditiveTrack(o);if(l){var u=l.keyframes,d=u[u.length-1];c=d&&d.value,l.valType===wi&&c&&(c=yi(c))}else c=this._target[o];if(c==null)continue;e>0&&s.addKeyframe(0,vi(c),r),this._trackKeys.push(o)}s.addKeyframe(e,vi(t[o]),r)}return this._maxTime=Math.max(this._maxTime,e),this},e.prototype.pause=function(){this._clip.pause(),this._paused=!0},e.prototype.resume=function(){this._clip.resume(),this._paused=!1},e.prototype.isPaused=function(){return!!this._paused},e.prototype.duration=function(e){return this._maxTime=e,this._force=!0,this},e.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var e=this._doneCbs;if(e)for(var t=e.length,n=0;n<t;n++)e[n].call(this)},e.prototype._abortedCallback=function(){this._setTracksFinished();var e=this.animation,t=this._abortedCbs;if(e&&e.removeClip(this._clip),this._clip=null,t)for(var n=0;n<t.length;n++)t[n].call(this)},e.prototype._setTracksFinished=function(){for(var e=this._tracks,t=this._trackKeys,n=0;n<t.length;n++)e[t[n]].setFinished()},e.prototype._getAdditiveTrack=function(e){var t,n=this._additiveAnimators;if(n)for(var r=0;r<n.length;r++){var i=n[r].getTrack(e);i&&(t=i)}return t},e.prototype.start=function(e){if(!(this._started>0)){this._started=1;for(var t=this,n=[],r=this._maxTime||0,i=0;i<this._trackKeys.length;i++){var a=this._trackKeys[i],o=this._tracks[a],s=this._getAdditiveTrack(a),c=o.keyframes,l=c.length;if(o.prepare(r,s),o.needsAnimate())if(!this._allowDiscrete&&o.discrete){var u=c[l-1];u&&(t._target[o.propName]=u.rawValue),o.setFinished()}else n.push(o)}if(n.length||this._force){var d=new Fr({life:r,loop:this._loop,delay:this._delay||0,onframe:function(e){t._started=2;var r=t._additiveAnimators;if(r){for(var i=!1,a=0;a<r.length;a++)if(r[a]._clip){i=!0;break}i||(t._additiveAnimators=null)}for(var a=0;a<n.length;a++)n[a].step(t._target,e);var o=t._onframeCbs;if(o)for(var a=0;a<o.length;a++)o[a](t._target,e)},ondestroy:function(){t._doneCallback()}});this._clip=d,this.animation&&this.animation.addClip(d),e&&d.setEasing(e)}else this._doneCallback();return this}},e.prototype.stop=function(e){if(this._clip){var t=this._clip;e&&t.onframe(1),this._abortedCallback()}},e.prototype.delay=function(e){return this._delay=e,this},e.prototype.during=function(e){return e&&(this._onframeCbs||=[],this._onframeCbs.push(e)),this},e.prototype.done=function(e){return e&&(this._doneCbs||=[],this._doneCbs.push(e)),this},e.prototype.aborted=function(e){return e&&(this._abortedCbs||=[],this._abortedCbs.push(e)),this},e.prototype.getClip=function(){return this._clip},e.prototype.getTrack=function(e){return this._tracks[e]},e.prototype.getTracks=function(){var e=this;return B(this._trackKeys,function(t){return e._tracks[t]})},e.prototype.stopTracks=function(e,t){if(!e.length||!this._clip)return!0;for(var n=this._tracks,r=this._trackKeys,i=0;i<e.length;i++){var a=n[e[i]];a&&!a.isFinished()&&(t?a.step(this._target,1):this._started===1&&a.step(this._target,0),a.setFinished())}for(var o=!0,i=0;i<r.length;i++)if(!n[r[i]].isFinished()){o=!1;break}return o&&this._abortedCallback(),o},e.prototype.saveTo=function(e,t,n){if(e){t||=this._trackKeys;for(var r=0;r<t.length;r++){var i=t[r],a=this._tracks[i];if(!(!a||a.isFinished())){var o=a.keyframes,s=o[n?0:o.length-1];s&&(e[i]=vi(s.rawValue))}}}},e.prototype.__changeFinalValue=function(e,t){t||=Oe(e);for(var n=0;n<t.length;n++){var r=t[n],i=this._tracks[r];if(i){var a=i.keyframes;if(a.length>1){var o=a.pop();i.addKeyframe(o.time,e[r]),i.prepare(this._maxTime,i.getAdditiveTrack())}}}},e}();function Ni(){return new Date().getTime()}var Pi=function(e){it(t,e);function t(t){var n=e.call(this)||this;return n._running=!1,n._time=0,n._pausedTime=0,n._pauseStart=0,n._paused=!1,t||={},n.stage=t.stage||{},n}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 t=e.getClip();t&&this.addClip(t)},t.prototype.removeClip=function(e){if(e.animation){var t=e.prev,n=e.next;t?t.next=n:this._head=n,n?n.prev=t:this._tail=t,e.next=e.prev=e.animation=null}},t.prototype.removeAnimator=function(e){var t=e.getClip();t&&this.removeClip(t),e.animation=null},t.prototype.update=function(e){for(var t=Ni()-this._pausedTime,n=t-this._time,r=this._head;r;){var i=r.next;r.step(t,n)?(r.ondestroy(),this.removeClip(r),r=i):r=i}this._time=t,e||(this.trigger(`frame`,n),this.stage.update&&this.stage.update())},t.prototype._startLoop=function(){var e=this;this._running=!0;function t(){e._running&&(or(t),!e._paused&&e.update())}or(t)},t.prototype.start=function(){this._running||(this._time=Ni(),this._pausedTime=0,this._startLoop())},t.prototype.stop=function(){this._running=!1},t.prototype.pause=function(){this._paused||=(this._pauseStart=Ni(),!0)},t.prototype.resume=function(){this._paused&&=(this._pausedTime+=Ni()-this._pauseStart,!1)},t.prototype.clear=function(){for(var e=this._head;e;){var t=e.next;e.prev=e.next=e.animation=null,e=t}this._head=this._tail=null},t.prototype.isFinished=function(){return this._head==null},t.prototype.animate=function(e,t){t||={},this.start();var n=new Mi(e,t.loop);return this.addAnimator(n),n},t}(wt),Fi=300,Ii=j.domSupported,Li=(function(){var e=[`click`,`dblclick`,`mousewheel`,`wheel`,`mouseout`,`mouseup`,`mousedown`,`mousemove`,`contextmenu`],t=[`touchstart`,`touchend`,`touchmove`],n={pointerdown:1,pointerup:1,pointermove:1,pointerout:1};return{mouse:e,touch:t,pointer:B(e,function(e){var t=e.replace(`mouse`,`pointer`);return n.hasOwnProperty(t)?t:e})}})(),Ri={mouse:[`mousemove`,`mouseup`],pointer:[`pointermove`,`pointerup`]},zi=!1;function Bi(e){var t=e.pointerType;return t===`pen`||t===`touch`}function Vi(e){e.touching=!0,e.touchTimer!=null&&(clearTimeout(e.touchTimer),e.touchTimer=null),e.touchTimer=setTimeout(function(){e.touching=!1,e.touchTimer=null},700)}function Hi(e){e&&(e.zrByTouch=!0)}function Ui(e,t){return Gt(e.dom,new Gi(e,t),!0)}function Wi(e,t){for(var n=t,r=!1;n&&n.nodeType!==9&&!(r=n.domBelongToZr||n!==t&&n===e.painterRoot);)n=n.parentNode;return r}var Gi=function(){function e(e,t){this.stopPropagation=tt,this.stopImmediatePropagation=tt,this.preventDefault=tt,this.type=t.type,this.target=this.currentTarget=e.dom,this.pointerType=t.pointerType,this.clientX=t.clientX,this.clientY=t.clientY}return e}(),Ki={mousedown:function(e){e=Gt(this.dom,e),this.__mayPointerCapture=[e.zrX,e.zrY],this.trigger(`mousedown`,e)},mousemove:function(e){e=Gt(this.dom,e);var t=this.__mayPointerCapture;t&&(e.zrX!==t[0]||e.zrY!==t[1])&&this.__togglePointerCapture(!0),this.trigger(`mousemove`,e)},mouseup:function(e){e=Gt(this.dom,e),this.__togglePointerCapture(!1),this.trigger(`mouseup`,e)},mouseout:function(e){e=Gt(this.dom,e);var t=e.toElement||e.relatedTarget;Wi(this,t)||(this.__pointerCapturing&&(e.zrEventControl=`no_globalout`),this.trigger(`mouseout`,e))},wheel:function(e){zi=!0,e=Gt(this.dom,e),this.trigger(`mousewheel`,e)},mousewheel:function(e){zi||(e=Gt(this.dom,e),this.trigger(`mousewheel`,e))},touchstart:function(e){e=Gt(this.dom,e),Hi(e),this.__lastTouchMoment=new Date,this.handler.processGesture(e,`start`),Ki.mousemove.call(this,e),Ki.mousedown.call(this,e)},touchmove:function(e){e=Gt(this.dom,e),Hi(e),this.handler.processGesture(e,`change`),Ki.mousemove.call(this,e)},touchend:function(e){e=Gt(this.dom,e),Hi(e),this.handler.processGesture(e,`end`),Ki.mouseup.call(this,e),new Date-+this.__lastTouchMoment<Fi&&Ki.click.call(this,e)},pointerdown:function(e){Ki.mousedown.call(this,e)},pointermove:function(e){Bi(e)||Ki.mousemove.call(this,e)},pointerup:function(e){Ki.mouseup.call(this,e)},pointerout:function(e){Bi(e)||Ki.mouseout.call(this,e)}};z([`click`,`dblclick`,`contextmenu`],function(e){Ki[e]=function(t){t=Gt(this.dom,t),this.trigger(e,t)}});var qi={pointermove:function(e){Bi(e)||qi.mousemove.call(this,e)},pointerup:function(e){qi.mouseup.call(this,e)},mousemove:function(e){this.trigger(`mousemove`,e)},mouseup:function(e){var t=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger(`mouseup`,e),t&&(e.zrEventControl=`only_globalout`,this.trigger(`mouseout`,e))}};function Ji(e,t){var n=t.domHandlers;j.pointerEventsSupported?z(Li.pointer,function(r){Xi(t,r,function(t){n[r].call(e,t)})}):(j.touchEventsSupported&&z(Li.touch,function(r){Xi(t,r,function(i){n[r].call(e,i),Vi(t)})}),z(Li.mouse,function(r){Xi(t,r,function(i){i=Wt(i),t.touching||n[r].call(e,i)})}))}function Yi(e,t){j.pointerEventsSupported?z(Ri.pointer,n):j.touchEventsSupported||z(Ri.mouse,n);function n(n){function r(r){r=Wt(r),Wi(e,r.target)||(r=Ui(e,r),t.domHandlers[n].call(e,r))}Xi(t,n,r,{capture:!0})}}function Xi(e,t,n,r){e.mounted[t]=n,e.listenerOpts[t]=r,qt(e.domTarget,t,n,r)}function Zi(e){var t=e.mounted;for(var n in t)t.hasOwnProperty(n)&&Jt(e.domTarget,n,t[n],e.listenerOpts[n]);e.mounted={}}var Qi=function(){function e(e,t){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=e,this.domHandlers=t}return e}(),$i=function(e){it(t,e);function t(t,n){var r=e.call(this)||this;return r.__pointerCapturing=!1,r.dom=t,r.painterRoot=n,r._localHandlerScope=new Qi(t,Ki),Ii&&(r._globalHandlerScope=new Qi(document,qi)),Ji(r,r._localHandlerScope),r}return t.prototype.dispose=function(){Zi(this._localHandlerScope),Ii&&Zi(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,Ii&&this.__pointerCapturing^+e){this.__pointerCapturing=e;var t=this._globalHandlerScope;e?Yi(this,t):Zi(t)}},t}(wt),ea=1;j.hasGlobalWindow&&(ea=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var ta=ea,na=.4,ra=`#333`,ia=`#ccc`,aa=`#eee`,oa=nn,sa=5e-5;function ca(e){return e>sa||e<-sa}var la=[],ua=[],da=tn(),fa=Math.abs,pa=function(){function e(){}return e.prototype.getLocalTransform=function(e){return ma(this,e)},e.prototype.setPosition=function(e){this.x=e[0],this.y=e[1]},e.prototype.setScale=function(e){this.scaleX=e[0],this.scaleY=e[1]},e.prototype.setSkew=function(e){this.skewX=e[0],this.skewY=e[1]},e.prototype.setOrigin=function(e){this.originX=e[0],this.originY=e[1]},e.prototype.needLocalTransform=function(){return ca(this.rotation)||ca(this.x)||ca(this.y)||ca(this.scaleX-1)||ca(this.scaleY-1)||ca(this.skewX)||ca(this.skewY)},e.prototype.updateTransform=function(){var e=this.parent&&this.parent.transform,t=this.needLocalTransform(),n=this.transform;if(!(t||e)){n&&(oa(n),this.invTransform=null);return}n||=tn(),t?this.getLocalTransform(n):oa(n),e&&(t?an(n,e,n):rn(n,e)),this.transform=n,this._resolveGlobalScaleRatio(n),this.invTransform=this.invTransform||tn(),ln(this.invTransform,n)},e.prototype._resolveGlobalScaleRatio=function(e){var t=this.globalScaleRatio;if(t!=null&&t!==1){this.getGlobalScale(la);var n=la[0]<0?-1:1,r=la[1]<0?-1:1,i=((la[0]-n)*t+n)/la[0]||0,a=((la[1]-r)*t+r)/la[1]||0;e[0]*=i,e[1]*=i,e[2]*=a,e[3]*=a}},e.prototype.getComputedTransform=function(){for(var e=this,t=[];e;)t.push(e),e=e.parent;for(;e=t.pop();)e.updateTransform();return this.transform},e.prototype.setLocalTransform=function(e){if(e){var t=e[0]*e[0]+e[1]*e[1],n=e[2]*e[2]+e[3]*e[3],r=Math.atan2(e[1],e[0]),i=Math.PI/2+r-Math.atan2(e[3],e[2]);n=Math.sqrt(n)*Math.cos(i),t=Math.sqrt(t),this.skewX=i,this.skewY=0,this.rotation=-r,this.x=+e[4],this.y=+e[5],this.scaleX=t,this.scaleY=n,this.originX=0,this.originY=0}},e.prototype.decomposeTransform=function(){if(this.transform){var e=this.parent,t=this.transform;e&&e.transform&&(e.invTransform=e.invTransform||tn(),an(ua,e.invTransform,t),t=ua);var n=this.originX,r=this.originY;(n||r)&&(da[4]=n,da[5]=r,an(ua,t,da),ua[4]-=n,ua[5]-=r,t=ua),this.setLocalTransform(t)}},e.prototype.getGlobalScale=function(e){var t=this.transform;return e||=[],t?(e[0]=Math.sqrt(t[0]*t[0]+t[1]*t[1]),e[1]=Math.sqrt(t[2]*t[2]+t[3]*t[3]),t[0]<0&&(e[0]=-e[0]),t[3]<0&&(e[1]=-e[1]),e):(e[0]=1,e[1]=1,e)},e.prototype.transformCoordToLocal=function(e,t){var n=[e,t],r=this.invTransform;return r&&yt(n,n,r),n},e.prototype.transformCoordToGlobal=function(e,t){var n=[e,t],r=this.transform;return r&&yt(n,n,r),n},e.prototype.getLineScale=function(){var e=this.transform;return e&&fa(e[0]-1)>1e-10&&fa(e[3]-1)>1e-10?Math.sqrt(fa(e[0]*e[3]-e[2]*e[1])):1},e.prototype.copyTransform=function(e){_a(this,e)},e.getLocalTransform=function(e,t){t||=[];var n=e.originX||0,r=e.originY||0,i=e.scaleX,a=e.scaleY,o=e.anchorX,s=e.anchorY,c=e.rotation||0,l=e.x,u=e.y,d=e.skewX?Math.tan(e.skewX):0,f=e.skewY?Math.tan(-e.skewY):0;if(n||r||o||s){var p=n+o,m=r+s;t[4]=-p*i-d*m*a,t[5]=-m*a-f*p*i}else t[4]=t[5]=0;return t[0]=i,t[3]=a,t[1]=f*i,t[2]=d*a,c&&sn(t,t,c),t[4]+=n+l,t[5]+=r+u,t},e.initDefaultProps=(function(){var t=e.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})(),e}(),ma=pa.getLocalTransform;function ha(){return new pa}var ga=[`x`,`y`,`originX`,`originY`,`anchorX`,`anchorY`,`rotation`,`scaleX`,`scaleY`,`skewX`,`skewY`];function _a(e,t){return xe(e,t,ga)}function va(e){ya||=new Rr(100),e||=`12px sans-serif`;var t=ya.get(e);return t||(t={font:e,strWidthCache:new Rr(500),asciiWidthMap:null,asciiWidthMapTried:!1,stWideCharWidth:M.measureText(`国`,e).width,asciiCharWidth:M.measureText(`a`,e).width},ya.put(e,t)),t}var ya;function ba(e){if(!(xa>=Sa)){e||=`12px sans-serif`;for(var t=[],n=+new Date,r=0;r<=127;r++)t[r]=M.measureText(String.fromCharCode(r),e).width;var i=+new Date-n;return i>16?xa=Sa:i>2&&xa++,t}}var xa=0,Sa=5;function Ca(e,t){return e.asciiWidthMapTried||=(e.asciiWidthMap=ba(e.font),!0),0<=t&&t<=127?e.asciiWidthMap==null?e.asciiCharWidth:e.asciiWidthMap[t]:e.stWideCharWidth}function wa(e,t){var n=e.strWidthCache,r=n.get(t);return r??(r=M.measureText(t,e.font).width,n.put(t,r)),r}function Ta(e,t,n,r){var i=wa(va(t),e),a=ka(t);return new Y(Da(0,i,n),Oa(0,a,r),i,a)}function Ea(e,t,n,r){var i=((e||``)+``).split(`
`);if(i.length===1)return Ta(i[0],t,n,r);for(var a=new Y(0,0,0,0),o=0;o<i.length;o++){var s=Ta(i[o],t,n,r);o===0?a.copy(s):a.union(s)}return a}function Da(e,t,n,r){return n===`right`?r?e+=t:e-=t:n===`center`&&(r?e+=t/2:e-=t/2),e}function Oa(e,t,n,r){return n===`middle`?r?e+=t/2:e-=t/2:n===`bottom`&&(r?e+=t:e-=t),e}function ka(e){return va(e).stWideCharWidth}function Aa(e,t){return typeof e==`string`?e.lastIndexOf(`%`)>=0?parseFloat(e)/100*t:parseFloat(e):e}function ja(e,t,n){var r=t.position||`inside`,i=t.distance==null?5:t.distance,a=n.height,o=n.width,s=a/2,c=n.x,l=n.y,u=`left`,d=`top`;if(r instanceof Array)c+=Aa(r[0],n.width),l+=Aa(r[1],n.height),u=null,d=null;else switch(r){case`left`:c-=i,l+=s,u=`right`,d=`middle`;break;case`right`:c+=i+o,l+=s,d=`middle`;break;case`top`:c+=o/2,l-=i,u=`center`,d=`bottom`;break;case`bottom`:c+=o/2,l+=a+i,u=`center`;break;case`inside`:c+=o/2,l+=s,u=`center`,d=`middle`;break;case`insideLeft`:c+=i,l+=s,d=`middle`;break;case`insideRight`:c+=o-i,l+=s,u=`right`,d=`middle`;break;case`insideTop`:c+=o/2,l+=i,u=`center`;break;case`insideBottom`:c+=o/2,l+=a-i,u=`center`,d=`bottom`;break;case`insideTopLeft`:c+=i,l+=i;break;case`insideTopRight`:c+=o-i,l+=i,u=`right`;break;case`insideBottomLeft`:c+=i,l+=a-i,d=`bottom`;break;case`insideBottomRight`:c+=o-i,l+=a-i,u=`right`,d=`bottom`;break}return e||={},e.x=c,e.y=l,e.align=u,e.verticalAlign=d,e}var Ma=`__zr_normal__`,Na=ga.concat([`ignore`]),Pa=Te(ga,function(e,t){return e[t]=!0,e},{ignore:!1}),Fa={},Ia=new Y(0,0,0,0),La=[],Ra=function(){function e(e){this.id=ye(),this.animators=[],this.currentStates=[],this.states={},this._init(e)}return e.prototype._init=function(e){this.attr(e)},e.prototype.drift=function(e,t,n){switch(this.draggable){case`horizontal`:t=0;break;case`vertical`:e=0;break}var r=this.transform;r||=this.transform=[1,0,0,1,0,0],r[4]+=e,r[5]+=t,this.decomposeTransform(),this.markRedraw()},e.prototype.beforeUpdate=function(){},e.prototype.afterUpdate=function(){},e.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},e.prototype.updateInnerText=function(e){var t=this._textContent;if(t&&(!t.ignore||e)){this.textConfig||={};var n=this.textConfig,r=n.local,i=t.innerTransformable,a=void 0,o=void 0,s=!1;i.parent=r?this:null;var c=!1;i.copyTransform(t);var l=n.position!=null,u=n.autoOverflowArea,d=void 0;if((u||l)&&(d=Ia,n.layoutRect?d.copy(n.layoutRect):d.copy(this.getBoundingRect()),r||d.applyTransform(this.transform)),l){this.calculateTextPosition?this.calculateTextPosition(Fa,n,d):ja(Fa,n,d),i.x=Fa.x,i.y=Fa.y,a=Fa.align,o=Fa.verticalAlign;var f=n.origin;if(f&&n.rotation!=null){var p=void 0,m=void 0;f===`center`?(p=d.width*.5,m=d.height*.5):(p=Aa(f[0],d.width),m=Aa(f[1],d.height)),c=!0,i.originX=-i.x+p+(r?0:d.x),i.originY=-i.y+m+(r?0:d.y)}}n.rotation!=null&&(i.rotation=n.rotation);var h=n.offset;h&&(i.x+=h[0],i.y+=h[1],c||(i.originX=-h[0],i.originY=-h[1]));var g=this._innerTextDefaultStyle||={};if(u){var _=g.overflowRect=g.overflowRect||new Y(0,0,0,0);i.getLocalTransform(La),ln(La,La),Y.copy(_,d),_.applyTransform(La)}else g.overflowRect=null;var v=n.inside==null?typeof n.position==`string`&&n.position.indexOf(`inside`)>=0:n.inside,y=void 0,b=void 0,x=void 0;v&&this.canBeInsideText()?(y=n.insideFill,b=n.insideStroke,(y==null||y===`auto`)&&(y=this.getInsideTextFill()),(b==null||b===`auto`)&&(b=this.getInsideTextStroke(y),x=!0)):(y=n.outsideFill,b=n.outsideStroke,(y==null||y===`auto`)&&(y=this.getOutsideFill()),(b==null||b===`auto`)&&(b=this.getOutsideStroke(y),x=!0)),y||=`#000`,(y!==g.fill||b!==g.stroke||x!==g.autoStroke||a!==g.align||o!==g.verticalAlign)&&(s=!0,g.fill=y,g.stroke=b,g.autoStroke=x,g.align=a,g.verticalAlign=o,t.setDefaultTextStyle(g)),t.__dirty|=1,s&&t.dirtyStyle(!0)}},e.prototype.canBeInsideText=function(){return!0},e.prototype.getInsideTextFill=function(){return`#fff`},e.prototype.getInsideTextStroke=function(e){return`#000`},e.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?ia:ra},e.prototype.getOutsideStroke=function(e){var t=this.__zr&&this.__zr.getBackgroundColor(),n=typeof t==`string`&&Qr(t);n||=[255,255,255,1];for(var r=n[3],i=this.__zr.isDarkMode(),a=0;a<3;a++)n[a]=n[a]*r+(i?0:255)*(1-r);return n[3]=1,ii(n,`rgba`)},e.prototype.traverse=function(e,t){},e.prototype.attrKV=function(e,t){e===`textConfig`?this.setTextConfig(t):e===`textContent`?this.setTextContent(t):e===`clipPath`?this.setClipPath(t):e===`extra`?(this.extra=this.extra||{},I(this.extra,t)):this[e]=t},e.prototype.hide=function(){this.ignore=!0,this.markRedraw()},e.prototype.show=function(){this.ignore=!1,this.markRedraw()},e.prototype.attr=function(e,t){if(typeof e==`string`)this.attrKV(e,t);else if(K(e))for(var n=Oe(e),r=0;r<n.length;r++){var i=n[r];this.attrKV(i,e[i])}return this.markRedraw(),this},e.prototype.saveCurrentToNormalState=function(e){this._innerSaveToNormal(e);for(var t=this._normalState,n=0;n<this.animators.length;n++){var r=this.animators[n],i=r.__fromStateTransition;if(!(r.getLoop()||i&&i!==`__zr_normal__`)){var a=r.targetName,o=a?t[a]:t;r.saveTo(o)}}},e.prototype._innerSaveToNormal=function(e){var t=this._normalState;t||=this._normalState={},e.textConfig&&!t.textConfig&&(t.textConfig=this.textConfig),this._savePrimaryToNormal(e,t,Na)},e.prototype._savePrimaryToNormal=function(e,t,n){for(var r=0;r<n.length;r++){var i=n[r];e[i]!=null&&!(i in t)&&(t[i]=this[i])}},e.prototype.hasState=function(){return this.currentStates.length>0},e.prototype.getState=function(e){return this.states[e]},e.prototype.ensureState=function(e){var t=this.states;return t[e]||(t[e]={}),t[e]},e.prototype.clearStates=function(e){this.useState(Ma,!1,e)},e.prototype.useState=function(e,t,n,r){var i=e===Ma;if(!(!this.hasState()&&i)){var a=this.currentStates,o=this.stateTransition;if(!(R(a,e)>=0&&(t||a.length===1))){var s;if(this.stateProxy&&!i&&(s=this.stateProxy(e)),s||=this.states&&this.states[e],!s&&!i){be(`State `+e+` not exists.`);return}i||this.saveCurrentToNormalState(s);var c=this._textContent,l=Ka(this,c,s,r);l&&!this.__inHover&&(this.__inHover=l),this._applyStateObj(e,s,this._normalState,t,Ja(this,n,o),o);var u=this._textGuide;return c&&c.useState(e,t,n,!!l),u&&u.useState(e,t,n,!!l),i?(this.currentStates=[],this._normalState={}):t?this.currentStates.push(e):this.currentStates=[e],this._updateAnimationTargets(),this.markRedraw(),!l&&this.__inHover&&(this.__inHover=0,this.__dirty&=-2),s}}},e.prototype.useStates=function(e,t,n){if(!e.length)this.clearStates();else{var r=[],i=this.currentStates,a=e.length,o=a===i.length;if(o){for(var s=0;s<a;s++)if(e[s]!==i[s]){o=!1;break}}if(o)return;for(var s=0;s<a;s++){var c=e[s],l=void 0;this.stateProxy&&(l=this.stateProxy(c,e)),l||=this.states[c],l&&r.push(l)}var u=r[a-1],d=this._textContent,f=Ka(this,d,u,n);f&&!this.__inHover&&(this.__inHover=f);var p=this._mergeStates(r),m=this.stateTransition;this.saveCurrentToNormalState(p),this._applyStateObj(e.join(`,`),p,this._normalState,!1,Ja(this,t,m),m);var h=this._textGuide;d&&d.useStates(e,t,!!f),h&&h.useStates(e,t,!!f),this._updateAnimationTargets(),this.currentStates=e.slice(),this.markRedraw(),!f&&this.__inHover&&(this.__inHover=0,this.__dirty&=-2)}},e.prototype.isSilent=function(){for(var e=this;e;){if(e.silent)return!0;var t=e.__hostTarget;e=t?e.ignoreHostSilent?null:t:e.parent}return!1},e.prototype._updateAnimationTargets=function(){for(var e=0;e<this.animators.length;e++){var t=this.animators[e];t.targetName&&t.changeTarget(this[t.targetName])}},e.prototype.removeState=function(e){var t=R(this.currentStates,e);if(t>=0){var n=this.currentStates.slice();n.splice(t,1),this.useStates(n)}},e.prototype.replaceState=function(e,t,n){var r=this.currentStates.slice(),i=R(r,e),a=R(r,t)>=0;i>=0?a?r.splice(i,1):r[i]=t:n&&!a&&r.push(t),this.useStates(r)},e.prototype.toggleState=function(e,t){t?this.useState(e,!0):this.removeState(e)},e.prototype._mergeStates=function(e){for(var t={},n,r=0;r<e.length;r++){var i=e[r];I(t,i),i.textConfig&&(n||={},I(n,i.textConfig))}return n&&(t.textConfig=n),t},e.prototype._applyStateObj=function(e,t,n,r,i,a){if(this.__inHover!==1){var o=!(t&&r);t&&t.textConfig?(this.textConfig=I({},r?this.textConfig:n.textConfig),I(this.textConfig,t.textConfig)):o&&n.textConfig&&(this.textConfig=n.textConfig);for(var s={},c=!1,l=0;l<Na.length;l++){var u=Na[l],d=i&&Pa[u];t&&t[u]!=null?d?(c=!0,s[u]=t[u]):this[u]=t[u]:o&&n[u]!=null&&(d?(c=!0,s[u]=n[u]):this[u]=n[u])}if(!i)for(var l=0;l<this.animators.length;l++){var f=this.animators[l],p=f.targetName;f.getLoop()||f.__changeFinalValue(p?(t||n)[p]:t||n)}c&&this._transitionState(e,s,a)}},e.prototype._attachComponent=function(e){if(!(e.__zr&&!e.__hostTarget)&&e!==this){var t=this.__zr;t&&e.addSelfToZr(t),e.__zr=t,e.__hostTarget=this}},e.prototype._detachComponent=function(e){e.__zr&&e.removeSelfFromZr(e.__zr),e.__zr=null,e.__hostTarget=null},e.prototype.getClipPath=function(){return this._clipPath},e.prototype.setClipPath=function(e){this._clipPath&&this._clipPath!==e&&this.removeClipPath(),this._attachComponent(e),this._clipPath=e,this.markRedraw()},e.prototype.removeClipPath=function(){var e=this._clipPath;e&&(this._detachComponent(e),this._clipPath=null,this.markRedraw())},e.prototype.getTextContent=function(){return this._textContent},e.prototype.setTextContent=function(e){var t=this._textContent;t!==e&&(t&&t!==e&&this.removeTextContent(),e.innerTransformable=new pa,this._attachComponent(e),this._textContent=e,this.markRedraw())},e.prototype.setTextConfig=function(e){this.textConfig||={},I(this.textConfig,e),this.markRedraw()},e.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},e.prototype.removeTextContent=function(){var e=this._textContent;e&&(e.innerTransformable=null,this._detachComponent(e),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},e.prototype.getTextGuideLine=function(){return this._textGuide},e.prototype.setTextGuideLine=function(e){this._textGuide&&this._textGuide!==e&&this.removeTextGuideLine(),this._attachComponent(e),this._textGuide=e,this.markRedraw()},e.prototype.removeTextGuideLine=function(){var e=this._textGuide;e&&(this._detachComponent(e),this._textGuide=null,this.markRedraw())},e.prototype.markRedraw=function(){this.__dirty|=1;var e=this.__zr;e&&(this.__inHover?e.refreshHover():e.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},e.prototype.dirty=function(){this.markRedraw()},e.prototype.addSelfToZr=function(e){if(this.__zr!==e){this.__zr=e;var t=this.animators;if(t)for(var n=0;n<t.length;n++)e.animation.addAnimator(t[n]);this._clipPath&&this._clipPath.addSelfToZr(e),this._textContent&&this._textContent.addSelfToZr(e),this._textGuide&&this._textGuide.addSelfToZr(e)}},e.prototype.removeSelfFromZr=function(e){if(this.__zr){this.__zr=null;var t=this.animators;if(t)for(var n=0;n<t.length;n++)e.animation.removeAnimator(t[n]);this._clipPath&&this._clipPath.removeSelfFromZr(e),this._textContent&&this._textContent.removeSelfFromZr(e),this._textGuide&&this._textGuide.removeSelfFromZr(e)}},e.prototype.animate=function(e,t,n){var r=new Mi(e?this[e]:this,t,n);return e&&(r.targetName=e),this.addAnimator(r,e),r},e.prototype.addAnimator=function(e,t){var n=this.__zr,r=this;e.during(function(){r.updateDuringAnimation(t)}).done(function(){var t=r.animators,n=R(t,e);n>=0&&t.splice(n,1)}),this.animators.push(e),n&&n.animation.addAnimator(e),n&&n.wakeUp()},e.prototype.updateDuringAnimation=function(e){this.markRedraw()},e.prototype.stopAnimation=function(e,t){for(var n=this.animators,r=n.length,i=[],a=0;a<r;a++){var o=n[a];!e||e===o.scope?o.stop(t):i.push(o)}return this.animators=i,this},e.prototype.animateTo=function(e,t,n){za(this,e,t,n)},e.prototype.animateFrom=function(e,t,n){za(this,e,t,n,!0)},e.prototype._transitionState=function(e,t,n,r){for(var i=za(this,t,n,r),a=0;a<i.length;a++)i[a].__fromStateTransition=e},e.prototype.getBoundingRect=function(){return null},e.prototype.getPaintRect=function(){return null},e.initDefaultProps=(function(){var t=e.prototype;t.type=`element`,t.name=``,t.ignore=t.silent=t.ignoreHostSilent=t.isGroup=t.draggable=t.dragging=t.ignoreClip=!1,t.__inHover=0,t.__dirty=1;function n(e,n,r,i){Object.defineProperty(t,e,{get:function(){if(!this[n]){var e=this[n]=[];a(this,e)}return this[n]},set:function(e){this[r]=e[0],this[i]=e[1],this[n]=e,a(this,e)}});function a(e,t){Object.defineProperty(t,0,{get:function(){return e[r]},set:function(t){e[r]=t}}),Object.defineProperty(t,1,{get:function(){return e[i]},set:function(t){e[i]=t}})}}Object.defineProperty&&(n(`position`,`_legacyPos`,`x`,`y`),n(`scale`,`_legacyScale`,`scaleX`,`scaleY`),n(`origin`,`_legacyOrigin`,`originX`,`originY`))})(),e}();Ce(Ra,wt),Ce(Ra,pa);function za(e,t,n,r,i){n||={};var a=[];Ga(e,``,e,t,n,r,a,i);var o=a.length,s=!1,c=n.done,l=n.aborted,u=function(){s=!0,o--,o<=0&&(s?c&&c():l&&l())},d=function(){o--,o<=0&&(s?c&&c():l&&l())};o||c&&c(),a.length>0&&n.during&&a[0].during(function(e,t){n.during(t)});for(var f=0;f<a.length;f++){var p=a[f];u&&p.done(u),d&&p.aborted(d),n.force&&p.duration(n.duration),p.start(n.easing)}return a}function Ba(e,t,n){for(var r=0;r<n;r++)e[r]=t[r]}function Va(e){return we(e[0])}function Ha(e,t,n){if(we(t[n]))if(we(e[n])||(e[n]=[]),Ne(t[n])){var r=t[n].length;e[n].length!==r&&(e[n]=new t[n].constructor(r),Ba(e[n],t[n],r))}else{var i=t[n],a=e[n],o=i.length;if(Va(i))for(var s=i[0].length,c=0;c<o;c++)a[c]?Ba(a[c],i[c],s):a[c]=Array.prototype.slice.call(i[c]);else Ba(a,i,o);a.length=i.length}else e[n]=t[n]}function Ua(e,t){return e===t||we(e)&&we(t)&&Wa(e,t)}function Wa(e,t){var n=e.length;if(n!==t.length)return!1;for(var r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}function Ga(e,t,n,r,i,a,o,s){for(var c=Oe(r),l=i.duration,u=i.delay,d=i.additive,f=i.setToFinal,p=!K(a),m=e.animators,h=[],g=0;g<c.length;g++){var _=c[g],v=r[_];if(v!=null&&n[_]!=null&&(p||a[_]))if(K(v)&&!we(v)&&!Fe(v)){if(t){s||(n[_]=v,e.updateDuringAnimation(t));continue}Ga(e,_,n[_],v,i,a&&a[_],o,s)}else h.push(_);else s||(n[_]=v,e.updateDuringAnimation(t),h.push(_))}var y=h.length;if(!d&&y)for(var b=0;b<m.length;b++){var x=m[b];if(x.targetName===t&&x.stopTracks(h)){var S=R(m,x);m.splice(S,1)}}if(i.force||(h=Ee(h,function(e){return!Ua(r[e],n[e])}),y=h.length),y>0||i.force&&!o.length){var C=void 0,w=void 0,T=void 0;if(s){w={},f&&(C={});for(var b=0;b<y;b++){var _=h[b];w[_]=n[_],f?C[_]=r[_]:n[_]=r[_]}}else if(f){T={};for(var b=0;b<y;b++){var _=h[b];T[_]=vi(n[_]),Ha(n,r,_)}}var x=new Mi(n,!1,!1,d?Ee(m,function(e){return e.targetName===t}):null);x.targetName=t,i.scope&&(x.scope=i.scope),f&&C&&x.whenWithKeys(0,C,h),T&&x.whenWithKeys(0,T,h),x.whenWithKeys(l??500,s?w:r,h).delay(u||0),e.addAnimator(x,t),o.push(x)}}function Ka(e,t,n,r){return!(n&&n.hoverLayer||r)||qa(e)||t&&qa(t)?0:1}function qa(e){return e.type===`text`||e.type===`tspan`}function Ja(e,t,n){return!t&&!e.__inHover&&n&&n.duration>0}var Ya=function(e){it(t,e);function t(t){var n=e.call(this)||this;return n.isGroup=!0,n._children=[],n.attr(t),n}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 t=this._children,n=0;n<t.length;n++)if(t[n].name===e)return t[n]},t.prototype.childCount=function(){return this._children.length},t.prototype.add=function(e){return e&&e!==this&&e.parent!==this&&(this._children.push(e),this._doAdd(e)),this},t.prototype.addBefore=function(e,t){if(e&&e!==this&&e.parent!==this&&t&&t.parent===this){var n=this._children,r=n.indexOf(t);r>=0&&(n.splice(r,0,e),this._doAdd(e))}return this},t.prototype.replace=function(e,t){var n=R(this._children,e);return n>=0&&this.replaceAt(t,n),this},t.prototype.replaceAt=function(e,t){var n=this._children,r=n[t];if(e&&e!==this&&e.parent!==this&&e!==r){n[t]=e,r.parent=null;var i=this.__zr;i&&r.removeSelfFromZr(i),this._doAdd(e)}return this},t.prototype._doAdd=function(e){e.parent&&e.parent.remove(e),e.parent=this;var t=this.__zr;t&&t!==e.__zr&&e.addSelfToZr(t),t&&t.refresh()},t.prototype.remove=function(e){var t=this.__zr,n=this._children,r=R(n,e);return r<0?this:(n.splice(r,1),e.parent=null,t&&e.removeSelfFromZr(t),t&&t.refresh(),this)},t.prototype.removeAll=function(){for(var e=this._children,t=this.__zr,n=0;n<e.length;n++){var r=e[n];t&&r.removeSelfFromZr(t),r.parent=null}return e.length=0,this},t.prototype.eachChild=function(e,t){for(var n=this._children,r=0;r<n.length;r++){var i=n[r];e.call(t,i,r)}return this},t.prototype.traverse=function(e,t){for(var n=0;n<this._children.length;n++){var r=this._children[n],i=e.call(t,r);r.isGroup&&!i&&r.traverse(e,t)}return this},t.prototype.addSelfToZr=function(t){e.prototype.addSelfToZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].addSelfToZr(t)},t.prototype.removeSelfFromZr=function(t){e.prototype.removeSelfFromZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].removeSelfFromZr(t)},t.prototype.getBoundingRect=function(e){for(var t=new Y(0,0,0,0),n=e||this._children,r=[],i=null,a=0;a<n.length;a++){var o=n[a];if(!(o.ignore||o.invisible)){var s=o.getBoundingRect(),c=o.getLocalTransform(r);c?(Y.applyTransform(t,s,c),i||=t.clone(),i.union(t)):(i||=s.clone(),i.union(s))}}return i||t},t}(Ra);Ya.prototype.type=`group`;var Xa={},Za={};function Qa(e){delete Za[e]}function $a(e){if(!e)return!1;if(typeof e==`string`)return ai(e,1)<na;if(e.colorStops){for(var t=e.colorStops,n=0,r=t.length,i=0;i<r;i++)n+=ai(t[i].color,1);return n/=r,n<na}return!1}var eo=function(){function e(e,t,n){var r=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!1,this._darkMode=!1,n||={},this.dom=t,this.id=e;var i=new ar,a=n.renderer||`canvas`;Xa[a]||(a=Oe(Xa)[0]),n.useDirtyRect=n.useDirtyRect==null?!1:n.useDirtyRect;var o=new Xa[a](t,i,n,e),s=n.ssr||o.ssrOnly;this.storage=i,this.painter=o;var c=!j.node&&!j.worker&&!s?new $i(o.getViewportRoot(),o.root):null,l=n.useCoarsePointer,u=l==null||l===`auto`?j.touchEventsSupported:!!l,d=44,f;u&&(f=q(n.pointerSize,d)),this.handler=new Hn(i,o,c,o.root,f),this.animation=new Pi({stage:{update:s?null:function(){return r._flush(!1)}}}),s||this.animation.start()}return e.prototype.add=function(e){this._disposed||!e||(this.storage.addRoot(e),e.addSelfToZr(this),this.refresh())},e.prototype.remove=function(e){this._disposed||!e||(this.storage.delRoot(e),e.removeSelfFromZr(this),this.refresh())},e.prototype.configLayer=function(e,t){this._disposed||(this.painter.configLayer&&this.painter.configLayer(e,t),this.refresh())},e.prototype.setBackgroundColor=function(e){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(e),this.refresh(),this._backgroundColor=e,this._darkMode=$a(e))},e.prototype.getBackgroundColor=function(){return this._backgroundColor},e.prototype.setDarkMode=function(e){this._darkMode=e},e.prototype.isDarkMode=function(){return this._darkMode},e.prototype.refreshImmediately=function(e){this._disposed||this._refresh({animUpdate:!e,refresh:!0,refreshHover:!1})},e.prototype._refresh=function(e){e.animUpdate&&this.animation.update(!0),this._needsRefresh=this._needsRefreshHover=!1,this.painter.refresh({refresh:e.refresh,refreshHover:e.refreshHover}),this._needsRefresh=this._needsRefreshHover=!1},e.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},e.prototype.flush=function(){this._disposed||this._flush(!0)},e.prototype._flush=function(e){var t,n=Ni(),r=this._needsRefresh,i=this._needsRefreshHover;(r||i)&&(t=!0,this._refresh({animUpdate:e,refresh:r,refreshHover:i}));var a=Ni();t?(this._stillFrameAccum=0,this.trigger(`rendered`,{elapsedTime:a-n})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},e.prototype.setSleepAfterStill=function(e){this._sleepAfterStill=e},e.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},e.prototype.refreshHover=function(){this._needsRefreshHover=!0},e.prototype.refreshHoverImmediately=function(){this._disposed||this._refresh({animUpdate:!1,refresh:!1,refreshHover:!0})},e.prototype.resize=function(e){this._disposed||(e||={},this.painter.resize(e.width,e.height),this.handler.resize())},e.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},e.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},e.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},e.prototype.setCursorStyle=function(e){this._disposed||this.handler.setCursorStyle(e)},e.prototype.findHover=function(e,t){if(!this._disposed)return this.handler.findHover(e,t)},e.prototype.on=function(e,t,n){return this._disposed||this.handler.on(e,t,n),this},e.prototype.off=function(e,t){this._disposed||this.handler.off(e,t)},e.prototype.trigger=function(e,t){this._disposed||this.handler.trigger(e,t)},e.prototype.clear=function(){if(!this._disposed){for(var e=this.storage.getRoots(),t=0;t<e.length;t++)e[t]instanceof Ya&&e[t].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},e.prototype.dispose=function(){this._disposed||(this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,this._disposed=!0,Qa(this.id))},e}();function to(e,t){var n=new eo(ye(),e,t);return Za[n.id]=n,n}function no(e,t){Xa[e]=t}var ro=1e-4,io=20;function ao(e){return e.replace(/^\s+|\s+$/g,``)}var oo=Math.min,so=Math.max,co=Math.abs,lo=Math.round,uo=Math.floor,fo=Math.ceil,po=Math.pow,mo=Math.log,ho=Math.LN10,go=Math.PI,_o=Math.random;function vo(e,t,n,r){var i=t[0],a=t[1],o=n[0],s=n[1],c=a-i,l=s-o;if(c===0)return l===0?o:(o+s)/2;if(r){if(c>0){if(e<=i)return o;if(e>=a)return s}else if(e>=i)return o;else if(e<=a)return s}else{if(e===i)return o;if(e===a)return s}return(e-i)/c*l+o}var yo=bo;function bo(e,t,n){switch(e){case`center`:case`middle`:e=`50%`;break;case`left`:case`top`:e=`0%`;break;case`right`:case`bottom`:e=`100%`;break}return xo(e,t,n)}function xo(e,t,n){return G(e)?So(e)?parseFloat(e)/100*t+(n||0):parseFloat(e):e==null?NaN:+e}function So(e){return!!ao(e).match(/%$/)}function X(e,t,n){return isNaN(t)?n?``+e:+e:(t=oo(so(0,t),io),e=(+e).toFixed(t),n?e:+e)}function Co(e){return e.sort(function(e,t){return e-t}),e}function wo(e){if(e=+e,isNaN(e))return 0;if(e>1e-14){for(var t=1,n=0;n<15;n++,t*=10)if(lo(e*t)/t===e)return n}return To(e)}function To(e){var t=e.toString().toLowerCase(),n=t.indexOf(`e`),r=n>0?+t.slice(n+1):0,i=n>0?n:t.length,a=t.indexOf(`.`);return so(0,(a<0?0:i-1-a)-r)}function Eo(e,t,n){var r=co(e[1]-e[0]);if(!isFinite(r)||r===0)return NaN;var i=mo(2*co(n||1)*co(r))/ho,a=mo(co(t))/ho,o=so(0,fo(-i+a));return isFinite(o)||(o=NaN),o}function Do(e,t){var n=so(wo(e),wo(t)),r=e+t;return n>io?r:X(r,n)}var Oo=po(2,53)-1;function ko(e){var t=go*2;return(e%t+t)%t}function Ao(e){return e>-ro&&e<ro}var jo=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d{1,2})(?::(\d{1,2})(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/;function Mo(e){if(e instanceof Date)return e;if(G(e)){var t=jo.exec(e);if(!t)return new Date(NaN);if(t[8]){var n=+t[4]||0;return t[8].toUpperCase()!==`Z`&&(n-=+t[8].slice(0,3)),new Date(Date.UTC(+t[1],(t[2]||1)-1,+t[3]||1,n,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0))}else return new Date(+t[1],(t[2]||1)-1,+t[3]||1,+t[4]||0,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0)}else if(e==null)return new Date(NaN);return new Date(lo(e))}function No(e){return po(10,Po(e))}function Po(e){if(e===0)return 0;var t=uo(mo(e)/ho);return e/po(10,t)>=10&&t++,t}function Fo(e,t){var n=Po(e),r=po(10,n),i=e/r;return e=(t===2?1:t?i<1.5?1:i<2.5?2:i<4?3:i<7?5:10:i<1?1:i<2?2:i<3?3:i<5?5:10)*r,X(e,-n)}function Io(e){var t=parseFloat(e);return t==e&&(t!==0||!G(e)||e.indexOf(`x`)<=0)?t:NaN}function Lo(e){return!isNaN(Io(e))}function Ro(){return lo(_o()*9)}function zo(e,t){return t===0?e:zo(t,e%t)}function Bo(e,t){return e==null?t:t==null?e:e*t/zo(e,t)}function Vo(e){return e!=null&&isFinite(e)}var Ho=`[ECharts] `,Uo={},Wo=typeof console<`u`&&console.warn&&console.log;function Go(e,t,n){if(Wo){if(n){if(Uo[t])return;Uo[t]=!0}console[e](Ho+t)}}function Ko(e,t){Go(`error`,e,t)}function qo(e){throw Error(e)}function Jo(e,t,n){return(t-e)*n+e}var Yo=`series\0`,Xo=`\0_ec_\0`;function Zo(e){return e instanceof Array?e:e==null?[]:[e]}function Qo(e,t,n){if(e){e[t]=e[t]||{},e.emphasis=e.emphasis||{},e.emphasis[t]=e.emphasis[t]||{};for(var r=0,i=n.length;r<i;r++){var a=n[r];!e.emphasis[t].hasOwnProperty(a)&&e[t].hasOwnProperty(a)&&(e.emphasis[t][a]=e[t][a])}}}var $o=`fontStyle.fontWeight.fontSize.fontFamily.rich.tag.color.textBorderColor.textBorderWidth.width.height.lineHeight.align.verticalAlign.baseline.shadowColor.shadowBlur.shadowOffsetX.shadowOffsetY.textShadowColor.textShadowBlur.textShadowOffsetX.textShadowOffsetY.backgroundColor.borderColor.borderWidth.borderRadius.padding`.split(`.`);function es(e){return K(e)&&!U(e)&&!(e instanceof Date)?e.value:e}function ts(e){return K(e)&&!(e instanceof Array)}function ns(e,t,n){var r=n===`normalMerge`,i=n===`replaceMerge`,a=n===`replaceAll`;e||=[],t=(t||[]).slice();var o=J();z(t,function(e,n){if(!K(e)){t[n]=null;return}});var s=rs(e,o,n);return(r||i)&&is(s,e,o,t),r&&as(s,t),r||i?os(s,t,i):a&&ss(s,t),cs(s),s}function rs(e,t,n){var r=[];if(n===`replaceAll`)return r;for(var i=0;i<e.length;i++){var a=e[i];a&&a.id!=null&&t.set(a.id,i),r.push({existing:n===`replaceMerge`||ps(a)?null:a,newOption:null,keyInfo:null,brandNew:null})}return r}function is(e,t,n,r){z(r,function(i,a){if(!(!i||i.id==null)){var o=us(i.id),s=n.get(o);if(s!=null){var c=e[s];He(!c.newOption,`Duplicated option on id "`+o+`".`),c.newOption=i,c.existing=t[s],r[a]=null}}})}function as(e,t){z(t,function(n,r){if(!(!n||n.name==null))for(var i=0;i<e.length;i++){var a=e[i].existing;if(!e[i].newOption&&a&&(a.id==null||n.id==null)&&!ps(n)&&!ps(a)&&ls(`name`,a,n)){e[i].newOption=n,t[r]=null;return}}})}function os(e,t,n){z(t,function(t){if(t){for(var r,i=0;(r=e[i])&&(r.newOption||ps(r.existing)||r.existing&&t.id!=null&&!ls(`id`,t,r.existing));)i++;r?(r.newOption=t,r.brandNew=n):e.push({newOption:t,brandNew:n,existing:null,keyInfo:null}),i++}})}function ss(e,t){z(t,function(t){e.push({newOption:t,brandNew:!0,existing:null,keyInfo:null})})}function cs(e){var t=J();z(e,function(e){var n=e.existing;n&&t.set(n.id,e)}),z(e,function(e){var n=e.newOption;He(!n||n.id==null||!t.get(n.id)||t.get(n.id)===e,`id duplicates: `+(n&&n.id)),n&&n.id!=null&&t.set(n.id,e),!e.keyInfo&&(e.keyInfo={})}),z(e,function(e,n){var r=e.existing,i=e.newOption,a=e.keyInfo;if(K(i)){if(a.name=i.name==null?r?r.name:Yo+n:us(i.name),r)a.id=us(r.id);else if(i.id!=null)a.id=us(i.id);else{var o=0;do a.id=`\0`+a.name+`\0`+ o++;while(t.get(a.id))}t.set(a.id,e)}})}function ls(e,t,n){var r=ds(t[e],null),i=ds(n[e],null);return r!=null&&i!=null&&r===i}function us(e){return ds(e,``)}function ds(e,t){return e==null?t:G(e)?e:je(e)||Ae(e)?e+``:t}function fs(e){var t=e.name;return!!(t&&t.indexOf(Yo))}function ps(e){return e&&e.id!=null&&us(e.id).indexOf(Xo)===0}function ms(e){return Xo+e}function hs(e,t,n){z(e,function(e){var r=e.newOption;K(r)&&(e.keyInfo.mainType=t,e.keyInfo.subType=gs(t,r,e.existing,n))})}function gs(e,t,n,r){return t.type?t.type:n?n.subType:r.determineSubType(e,t)}function _s(e,t){if(t.dataIndexInside!=null)return t.dataIndexInside;if(t.dataIndex!=null)return U(t.dataIndex)?B(t.dataIndex,function(t){return e.indexOfRawIndex(t)}):e.indexOfRawIndex(t.dataIndex);if(t.name!=null)return U(t.name)?B(t.name,function(t){return e.indexOfName(t)}):e.indexOfName(t.name)}function Z(){var e=`__ec_inner_`+ vs++;return function(t){return t[e]||(t[e]={})}}var vs=Ro();function ys(e,t,n){var r=bs(t,n),i=r.mainTypeSpecified,a=r.queryOptionMap,o=r.others,s=n?n.defaultMainType:null;return!i&&s&&a.set(s,{}),a.each(function(t,r){var i=Cs(e,r,t,{useDefault:s===r,enableAll:n&&n.enableAll!=null?n.enableAll:!0,enableNone:n&&n.enableNone!=null?n.enableNone:!0});o[r+`Models`]=i.models,o[r+`Model`]=i.models[0]}),o}function bs(e,t){var n;if(G(e)){var r={};r[e+`Index`]=0,n=r}else n=e;var i=J(),a={},o=!1;return z(n,function(e,n){if(n===`dataIndex`||n===`dataIndexInside`){a[n]=e;return}var r=n.match(/^(\w+)(Index|Id|Name)$/)||[],s=r[1],c=(r[2]||``).toLowerCase();if(!(!s||!c||t&&t.includeMainTypes&&R(t.includeMainTypes,s)<0)){o||=!!s;var l=i.get(s)||i.set(s,{});l[c]=e}}),{mainTypeSpecified:o,queryOptionMap:i,others:a}}var xs={useDefault:!0,enableAll:!1,enableNone:!1},Ss={useDefault:!1,enableAll:!0,enableNone:!0};function Cs(e,t,n,r){r||=xs;var i=n.index,a=n.id,o=n.name,s={models:null,specified:i!=null||a!=null||o!=null};if(!s.specified){var c=void 0;return s.models=r.useDefault&&(c=e.getComponent(t))?[c]:[],s}if(i===`none`||i===!1){if(r.enableNone)return s.models=[],s;i=-1}return i===`all`&&(i=r.enableAll?a=o=null:-1),s.models=e.queryComponents({mainType:t,index:i,id:a,name:o}),s}function ws(e,t,n){var r={};r[t+`Id`]=e[t+`Id`],r[t+`Index`]=e[t+`Index`],r[t+`Name`]=e[t+`Name`];var i={mainType:t,query:r};return n&&(i.subType=n),i}function Ts(e,t,n){e.setAttribute?e.setAttribute(t,n):e[t]=n}function Es(e,t){return e.getAttribute?e.getAttribute(t):e[t]}function Ds(e){return e===`auto`?j.domSupported?`html`:`richText`:e||`html`}function Os(e,t,n,r,i){var a=t==null||t===`auto`;if(r==null)return r;if(je(r)){var o=Jo(n||0,r,i);return X(o,a?Math.max(wo(n||0),wo(r)):t)}else if(G(r))return i<1?n:r;else{for(var s=[],c=n,l=r,u=Math.max(c?c.length:0,l.length),d=0;d<u;++d){var f=e.getDimensionInfo(d);if(f&&f.type===`ordinal`)s[d]=(i<1&&c?c:l)[d];else{var p=c&&c[d]?c[d]:0,m=l[d],o=Jo(p,m,i);s[d]=X(o,a?Math.max(wo(p),wo(m)):t)}}return s}}(function(){function e(){}return e.prototype.reset=function(e,t,n,r){return this._list=e,this._step=r||=1,this._idx=t,this._end=n??(r>0?e.length:0),this.item=null,this.key=NaN,this},e.prototype.next=function(){return(this._step>0?this._idx<this._end:this._idx>=this._end)?(this.item=this._list[this._idx],this.key=this._idx+=this._step,!0):!1},e})();function ks(){return[1/0,-1/0]}function As(e,t){Ps(t)&&(t<e[0]&&(e[0]=t),t>e[1]&&(e[1]=t))}function js(e,t){Ps(t)&&t<e[0]&&(e[0]=t)}function Ms(e,t){Ps(t)&&t>e[1]&&(e[1]=t)}function Ns(e,t){Fs(t[0],t[1])&&(t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1]))}function Ps(e){return e!=null&&isFinite(e)}function Fs(e,t){return Ps(e)&&Ps(t)&&e<=t}function Is(e){var t=e[1]-e[0];return isFinite(t)&&t>=0}function Ls(e){Fs(e[0],e[1])&&e[0]>e[1]&&(e[0]=e[1])}function Rs(){var e=`__ec_once_`+ zs++;return function(t,n){et(t,e)||(t[e]=1,n())}}var zs=Ro();function Bs(e,t,n){var r=J(),i=0;z(e,function(a){var o=t(a),s=r.get(o)||0;n&&n(a,s),!s&&!n&&(e[i++]=a),r.set(o,s+1)}),n||(e.length=i)}function Vs(e){return e.value+``}function Hs(e){return e+``}function Us(e,t){return q(t,!0)?e.seriesIndex+2:0}function Ws(e,t,n){var r=e.getData().count();return{progressiveRender:n.progressiveEnabled&&t.incrementalPrepareRender&&r>=n.threshold,large:e.get(`large`)&&r>=e.get(`largeThreshold`),modDataCount:e.get(`progressiveChunkMode`)===`mod`?e.getData().count():null}}function Gs(e){return{overallReset:e}}var Ks=`.`,qs=`___EC__COMPONENT__CONTAINER___`,Js=`___EC__EXTENDED_CLASS___`;function Ys(e){var t={main:``,sub:``};if(e){var n=e.split(Ks);t.main=n[0]||``,t.sub=n[1]||``}return t}function Xs(e){He(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(e),`componentType "`+e+`" illegal`)}function Zs(e){return!!(e&&e[Js])}function Qs(e,t){e.$constructor=e,e.extend=function(e){var t=this,n;return $s(t)?n=function(e){k(t,e);function t(){return e.apply(this,arguments)||this}return t}(t):(n=function(){(e.$constructor||t).apply(this,arguments)},Se(n,this)),I(n.prototype,e),n[Js]=!0,n.extend=this.extend,n.superCall=rc,n.superApply=ic,n.superClass=t,n}}function $s(e){return W(e)&&/^class\s/.test(Function.prototype.toString.call(e))}function ec(e,t){e.extend=t.extend}var tc=Math.round(Math.random()*10);function nc(e){var t=[`__\0is_clz`,tc++].join(`_`);e.prototype[t]=!0,e.isInstance=function(e){return!!(e&&e[t])}}function rc(e,t){var n=[...arguments].slice(2);return this.superClass.prototype[t].apply(e,n)}function ic(e,t,n){return this.superClass.prototype[t].apply(e,n)}function ac(e){var t={};e.registerClass=function(e){var r=e.type||e.prototype.type;if(r){Xs(r),e.prototype.type=r;var i=Ys(r);if(!i.sub)t[i.main]=e;else if(i.sub!==qs){var a=n(i);a[i.sub]=e}}return e},e.getClass=function(e,n,r){var i=t[e];if(i&&i[qs]&&(i=n?i[n]:null),r&&!i)throw Error(n?`Component `+e+`.`+(n||``)+` is used but not imported.`:e+`.type should be specified.`);return i},e.getClassesByMainType=function(e){var n=Ys(e),r=[],i=t[n.main];return i&&i[qs]?z(i,function(e,t){t!==qs&&r.push(e)}):r.push(i),r},e.hasClass=function(e){return!!t[Ys(e).main]},e.getAllClassMainTypes=function(){var e=[];return z(t,function(t,n){e.push(n)}),e},e.hasSubTypes=function(e){var n=t[Ys(e).main];return n&&n[qs]};function n(e){var n=t[e.main];return(!n||!n[qs])&&(n=t[e.main]={},n[qs]=!0),n}}function oc(e,t){for(var n=0;n<e.length;n++)e[n][1]||(e[n][1]=e[n][0]);return t||=!1,function(n,r,i){for(var a={},o=0;o<e.length;o++){var s=e[o][1];if(!(r&&R(r,s)>=0||i&&R(i,s)<0)){var c=n.getShallow(s,t);c!=null&&(a[e[o][0]]=c)}}return a}}var sc=oc([[`fill`,`color`],[`shadowBlur`],[`shadowOffsetX`],[`shadowOffsetY`],[`opacity`],[`shadowColor`]]),cc=function(){function e(){}return e.prototype.getAreaStyle=function(e,t){return sc(this,e,t)},e}(),lc=new Rr(50);function uc(e){if(typeof e==`string`){var t=lc.get(e);return t&&t.image}else return e}function dc(e,t,n,r,i){if(!e)return t;if(typeof e==`string`){if(t&&t.__zrImageSrc===e||!n)return t;var a=lc.get(e),o={hostEl:n,cb:r,cbPayload:i};return a?(t=a.image,!pc(t)&&a.pending.push(o)):(t=M.loadImage(e,fc,fc),t.__zrImageSrc=e,lc.put(e,t.__cachedImgObj={image:t,pending:[o]})),t}else return e}function fc(){var e=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t<e.pending.length;t++){var n=e.pending[t],r=n.cb;r&&r(this,n.cbPayload),n.hostEl.dirty()}e.pending.length=0}function pc(e){return e&&e.width&&e.height}var mc=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function hc(e,t,n,r,i,a){if(!n){e.text=``,e.isTruncated=!1;return}var o=(t+``).split(`
`);a=gc(n,r,i,a);for(var s=!1,c={},l=0,u=o.length;l<u;l++)_c(c,o[l],a),o[l]=c.textLine,s||=c.isTruncated;e.text=o.join(`
`),e.isTruncated=s}function gc(e,t,n,r){r||={};var i=I({},r);n=q(n,`...`),i.maxIterations=q(r.maxIterations,2);var a=i.minChar=q(r.minChar,0),o=i.fontMeasureInfo=va(t),s=o.asciiCharWidth;i.placeholder=q(r.placeholder,``);for(var c=e=Math.max(0,e-1),l=0;l<a&&c>=s;l++)c-=s;var u=wa(o,n);return u>c&&(n=``,u=0),c=e-u,i.ellipsis=n,i.ellipsisWidth=u,i.contentWidth=c,i.containerWidth=e,i}function _c(e,t,n){var r=n.containerWidth,i=n.contentWidth,a=n.fontMeasureInfo;if(!r){e.textLine=``,e.isTruncated=!1;return}var o=wa(a,t);if(o<=r){e.textLine=t,e.isTruncated=!1;return}for(var s=0;;s++){if(o<=i||s>=n.maxIterations){t+=n.ellipsis;break}var c=s===0?vc(t,i,a):o>0?Math.floor(t.length*i/o):0;t=t.substr(0,c),o=wa(a,t)}t===``&&(t=n.placeholder),e.textLine=t,e.isTruncated=!0}function vc(e,t,n){for(var r=0,i=0,a=e.length;i<a&&r<t;i++)r+=Ca(n,e.charCodeAt(i));return i}function yc(e,t,n,r){var i=Mc(e),a=t.overflow,o=t.padding,s=o?o[1]+o[3]:0,c=o?o[0]+o[2]:0,l=t.font,u=a===`truncate`,d=ka(l),f=q(t.lineHeight,d),p=t.lineOverflow===`truncate`,m=!1,h=t.width;h==null&&n!=null&&(h=n-s);var g=t.height;g==null&&r!=null&&(g=r-c);var _=h!=null&&(a===`break`||a===`breakAll`)?i?Oc(i,t.font,h,a===`breakAll`,0).lines:[]:i?i.split(`
`):[],v=_.length*f;if(g??=v,v>g&&p){var y=Math.floor(g/f);m||=_.length>y,_=_.slice(0,y),v=_.length*f}if(i&&u&&h!=null)for(var b=gc(h,l,t.ellipsis,{minChar:t.truncateMinChar,placeholder:t.placeholder}),x={},S=0;S<_.length;S++)_c(x,_[S],b),_[S]=x.textLine,m||=x.isTruncated;for(var C=g,w=0,T=va(l),S=0;S<_.length;S++)w=Math.max(wa(T,_[S]),w);h??=w;var E=h;return C+=c,E+=s,{lines:_,height:g,outerWidth:E,outerHeight:C,lineHeight:f,calculatedLineHeight:d,contentWidth:w,contentHeight:v,width:h,isTruncated:m}}var bc=function(){function e(){}return e}(),xc=function(){function e(e){this.tokens=[],e&&(this.tokens=e)}return e}(),Sc=function(){function e(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[],this.isTruncated=!1}return e}();function Cc(e,t,n,r,i){var a=new Sc,o=Mc(e);if(!o)return a;var s=t.padding,c=s?s[1]+s[3]:0,l=s?s[0]+s[2]:0,u=t.width;u==null&&n!=null&&(u=n-c);var d=t.height;d==null&&r!=null&&(d=r-l);for(var f=t.overflow,p=(f===`break`||f===`breakAll`)&&u!=null?{width:u,accumWidth:0,breakAll:f===`breakAll`}:null,m=mc.lastIndex=0,h;(h=mc.exec(o))!=null;){var g=h.index;g>m&&wc(a,o.substring(m,g),t,p),wc(a,h[2],t,p,h[1]),m=mc.lastIndex}m<o.length&&wc(a,o.substring(m,o.length),t,p);var _=[],v=0,y=0,b=f===`truncate`,x=t.lineOverflow===`truncate`,S={};function C(e,t,n){e.width=t,e.lineHeight=n,v+=n,y=Math.max(y,t)}outer:for(var w=0;w<a.lines.length;w++){for(var T=a.lines[w],E=0,D=0,O=0;O<T.tokens.length;O++){var k=T.tokens[O],A=k.styleName&&t.rich[k.styleName]||{},j=k.textPadding=A.padding,ee=j?j[1]+j[3]:0,te=k.font=A.font||t.font;k.contentHeight=ka(te);var ne=q(A.height,k.contentHeight);if(k.innerHeight=ne,j&&(ne+=j[0]+j[2]),k.height=ne,k.lineHeight=ze(A.lineHeight,t.lineHeight,ne),k.align=A&&A.align||i,k.verticalAlign=A&&A.verticalAlign||`middle`,x&&d!=null&&v+k.lineHeight>d){var re=a.lines.length;O>0?(T.tokens=T.tokens.slice(0,O),C(T,D,E),a.lines=a.lines.slice(0,w+1)):a.lines=a.lines.slice(0,w),a.isTruncated=a.isTruncated||a.lines.length<re;break outer}var ie=A.width,ae=ie==null||ie===`auto`;if(typeof ie==`string`&&ie.charAt(ie.length-1)===`%`)k.percentWidth=ie,_.push(k),k.contentWidth=wa(va(te),k.text);else{if(ae){var oe=A.backgroundColor,M=oe&&oe.image;M&&(M=uc(M),pc(M)&&(k.width=Math.max(k.width,M.width*ne/M.height)))}var se=b&&u!=null?u-D:null;se!=null&&se<k.width?!ae||se<ee?(k.text=``,k.width=k.contentWidth=0):(hc(S,k.text,se-ee,te,t.ellipsis,{minChar:t.truncateMinChar}),k.text=S.text,a.isTruncated=a.isTruncated||S.isTruncated,k.width=k.contentWidth=wa(va(te),k.text)):k.contentWidth=wa(va(te),k.text)}k.width+=ee,D+=k.width,A&&(E=Math.max(E,k.lineHeight))}C(T,D,E)}a.outerWidth=a.width=q(u,y),a.outerHeight=a.height=q(d,v),a.contentHeight=v,a.contentWidth=y,a.outerWidth+=c,a.outerHeight+=l;for(var w=0;w<_.length;w++){var k=_[w],ce=k.percentWidth;k.width=parseInt(ce,10)/100*a.width}return a}function wc(e,t,n,r,i){var a=t===``,o=i&&n.rich[i]||{},s=e.lines,c=o.font||n.font,l=!1,u,d;if(r){var f=o.padding,p=f?f[1]+f[3]:0;if(o.width!=null&&o.width!==`auto`){var m=Aa(o.width,r.width)+p;s.length>0&&m+r.accumWidth>r.width&&(u=t.split(`
`),l=!0),r.accumWidth=m}else{var h=Oc(t,c,r.width,r.breakAll,r.accumWidth);r.accumWidth=h.accumWidth+p,d=h.linesWidths,u=h.lines}}u||=t.split(`
`);for(var g=va(c),_=0;_<u.length;_++){var v=u[_],y=new bc;if(y.styleName=i,y.text=v,y.isLineHolder=!v&&!a,typeof o.width==`number`?y.width=o.width:y.width=d?d[_]:wa(g,v),!_&&!l){var b=(s[s.length-1]||(s[0]=new xc)).tokens,x=b.length;x===1&&b[0].isLineHolder?b[0]=y:(v||!x||a)&&b.push(y)}else s.push(new xc([y]))}}function Tc(e){var t=e.charCodeAt(0);return t>=32&&t<=591||t>=880&&t<=4351||t>=4608&&t<=5119||t>=7680&&t<=8303}var Ec=Te(`,&?/;] `.split(``),function(e,t){return e[t]=!0,e},{});function Dc(e){return Tc(e)?!!Ec[e]:!0}function Oc(e,t,n,r,i){for(var a=[],o=[],s=``,c=``,l=0,u=0,d=va(t),f=0;f<e.length;f++){var p=e.charAt(f);if(p===`
`){c&&(s+=c,u+=l),a.push(s),o.push(u),s=``,c=``,l=0,u=0;continue}var m=Ca(d,p.charCodeAt(0)),h=r?!1:!Dc(p);if(a.length?u+m>n:i+u+m>n){u?(s||c)&&(h?(s||(s=c,c=``,l=0,u=l),a.push(s),o.push(u-l),c+=p,l+=m,s=``,u=l):(c&&(s+=c,c=``,l=0),a.push(s),o.push(u),s=p,u=m)):h?(a.push(c),o.push(l),c=p,l=m):(a.push(p),o.push(m));continue}u+=m,h?(c+=p,l+=m):(c&&(s+=c,c=``,l=0),s+=p)}return c&&(s+=c),s&&(a.push(s),o.push(u)),a.length===1&&(u+=i),{accumWidth:u,lines:a,linesWidths:o}}function kc(e,t,n,r,i,a){if(e.baseX=n,e.baseY=r,e.outerWidth=e.outerHeight=null,t){var o=t.width*2,s=t.height*2;Y.set(Ac,Da(n,o,i),Oa(r,s,a),o,s),Y.intersect(t,Ac,null,jc);var c=jc.outIntersectRect;e.outerWidth=c.width,e.outerHeight=c.height,e.baseX=Da(c.x,c.width,i,!0),e.baseY=Oa(c.y,c.height,a,!0)}}var Ac=new Y(0,0,0,0),jc={outIntersectRect:{},clamp:!0};function Mc(e){return e==null?e=``:e+=``}function Nc(e){var t=Mc(e.text),n=e.font;return Pc(e,wa(va(n),t),ka(n),null)}function Pc(e,t,n,r){var i=new Y(Da(e.x||0,t,e.textAlign),Oa(e.y||0,n,e.textBaseline),t,n),a=r??(Fc(e)?e.lineWidth:0);return a>0&&(i.x-=a/2,i.y-=a/2,i.width+=a,i.height+=a),i}function Fc(e){var t=e.stroke;return t!=null&&t!==`none`&&e.lineWidth>0}var Ic=`__zr_style_`+Math.round(Math.random()*10),Lc={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:`#000`,opacity:1,blend:`source-over`},Rc={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};Lc[Ic]=!0;var zc=[`z`,`z2`,`invisible`],Bc=[`invisible`],Vc=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype._init=function(t){for(var n=Oe(t),r=0;r<n.length;r++){var i=n[r];i===`style`?this.useStyle(t[i]):e.prototype.attrKV.call(this,i,t[i])}this.style||this.useStyle({})},t.prototype.beforeBrush=function(e){},t.prototype.afterBrush=function(){},t.prototype.innerBeforeBrush=function(){},t.prototype.innerAfterBrush=function(){},t.prototype.shouldBePainted=function(e,t,n,r){var i=this.transform;if(this.ignore||this.invisible||this.style.opacity===0||this.culling&&Wc(this,e,t)||i&&!i[0]&&!i[3])return!1;if(n&&this.__clipPaths&&this.__clipPaths.length){for(var a=0;a<this.__clipPaths.length;++a)if(this.__clipPaths[a].isZeroArea())return!1}if(r&&this.parent)for(var o=this.parent;o;){if(o.ignore)return!1;o=o.parent}return!0},t.prototype.contain=function(e,t){return this.rectContain(e,t)},t.prototype.traverse=function(e,t){e.call(t,this)},t.prototype.rectContain=function(e,t){var n=this.transformCoordToLocal(e,t);return this.getBoundingRect().contain(n[0],n[1])},t.prototype.getPaintRect=function(){var e=this._paintRect;if(!this._paintRect||this.__dirty){var t=this.transform,n=this.getBoundingRect(),r=this.style,i=r.shadowBlur||0,a=r.shadowOffsetX||0,o=r.shadowOffsetY||0;e=this._paintRect||=new Y(0,0,0,0),t?Y.applyTransform(e,n,t):e.copy(n),(i||a||o)&&(e.width+=i*2+Math.abs(a),e.height+=i*2+Math.abs(o),e.x=Math.min(e.x,e.x+a-i),e.y=Math.min(e.y,e.y+o-i));var s=this.dirtyRectTolerance;e.isZero()||(e.x=Math.floor(e.x-s),e.y=Math.floor(e.y-s),e.width=Math.ceil(e.width+1+s*2),e.height=Math.ceil(e.height+1+s*2))}return e},t.prototype.setPrevPaintRect=function(e){e?(this._prevPaintRect=this._prevPaintRect||new Y(0,0,0,0),this._prevPaintRect.copy(e)):this._prevPaintRect=null},t.prototype.getPrevPaintRect=function(){return this._prevPaintRect},t.prototype.animateStyle=function(e){return this.animate(`style`,e)},t.prototype.updateDuringAnimation=function(e){e===`style`?this.dirtyStyle():this.markRedraw()},t.prototype.attrKV=function(t,n){t===`style`?this.style?this.setStyle(n):this.useStyle(n):e.prototype.attrKV.call(this,t,n)},t.prototype.setStyle=function(e,t){return typeof e==`string`?this.style[e]=t:I(this.style,e),this.dirtyStyle(),this},t.prototype.dirtyStyle=function(e){e||this.markRedraw(),this.__dirty|=2,this._rect&&=null},t.prototype.dirty=function(){this.dirtyStyle()},t.prototype.styleChanged=function(){return!!(this.__dirty&2)},t.prototype.styleUpdated=function(){this.__dirty&=-3},t.prototype.createStyle=function(e){return Qe(Lc,e)},t.prototype.useStyle=function(e){e[Ic]||(e=this.createStyle(e)),this.style=e,this.dirtyStyle()},t.prototype._useHoverStyle=function(e){this.__hoverStyle=e},t.prototype.isStyleObject=function(e){return e[Ic]},t.prototype._innerSaveToNormal=function(t){e.prototype._innerSaveToNormal.call(this,t);var n=this._normalState;t.style&&!n.style&&(n.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(t,n,zc)},t.prototype._applyStateObj=function(t,n,r,i,a,o){e.prototype._applyStateObj.call(this,t,n,r,i,a,o);var s=!(n&&i),c=this.__inHover===1,l;if(n&&n.style?a?i?l=n.style:(l=this._mergeStyle(this.createStyle(),r.style),this._mergeStyle(l,n.style)):(l=this._mergeStyle(this.createStyle(),i?this.style:r.style),this._mergeStyle(l,n.style)):s&&(l=r.style),l)if(a){var u=this.style;if(this.style=this.createStyle(s?{}:u),s)for(var d=Oe(u),f=0;f<d.length;f++){var p=d[f];p in l&&(l[p]=l[p],this.style[p]=u[p])}for(var m=Oe(l),f=0;f<m.length;f++){var p=m[f];this.style[p]=this.style[p]}this._transitionState(t,{style:l},o,this.getAnimationStyleProps())}else c?this._useHoverStyle(l):this.useStyle(l);if(!c)for(var h=this.__inHover?Bc:zc,f=0;f<h.length;f++){var p=h[f];n&&n[p]!=null?this[p]=n[p]:s&&r[p]!=null&&(this[p]=r[p])}},t.prototype._mergeStates=function(t){for(var n=e.prototype._mergeStates.call(this,t),r,i=0;i<t.length;i++){var a=t[i];a.style&&(r||={},this._mergeStyle(r,a.style))}return r&&(n.style=r),n},t.prototype._mergeStyle=function(e,t){return I(e,t),e},t.prototype.getAnimationStyleProps=function(){return Rc},t.initDefaultProps=(function(){var e=t.prototype;e.type=`displayable`,e.invisible=!1,e.z=0,e.z2=0,e.zlevel=0,e.culling=!1,e.cursor=`pointer`,e.rectHover=!1,e.incremental=0,e._rect=null,e.dirtyRectTolerance=0,e.__dirty=3})(),t}(Ra),Hc=new Y(0,0,0,0),Uc=new Y(0,0,0,0);function Wc(e,t,n){return Hc.copy(e.getBoundingRect()),e.transform&&Hc.applyTransform(e.transform),Uc.width=t,Uc.height=n,!Hc.intersect(Uc)}var Gc=Math.min,Kc=Math.max,qc=Math.sin,Jc=Math.cos,Yc=Math.PI*2,Xc=at(),Zc=at(),Qc=at();function $c(e,t,n,r,i,a){i[0]=Gc(e,n),i[1]=Gc(t,r),a[0]=Kc(e,n),a[1]=Kc(t,r)}var el=[],tl=[];function nl(e,t,n,r,i,a,o,s,c,l){var u=Sr,d=yr,f=u(e,n,i,o,el);c[0]=1/0,c[1]=1/0,l[0]=-1/0,l[1]=-1/0;for(var p=0;p<f;p++){var m=d(e,n,i,o,el[p]);c[0]=Gc(m,c[0]),l[0]=Kc(m,l[0])}f=u(t,r,a,s,tl);for(var p=0;p<f;p++){var h=d(t,r,a,s,tl[p]);c[1]=Gc(h,c[1]),l[1]=Kc(h,l[1])}c[0]=Gc(e,c[0]),l[0]=Kc(e,l[0]),c[0]=Gc(o,c[0]),l[0]=Kc(o,l[0]),c[1]=Gc(t,c[1]),l[1]=Kc(t,l[1]),c[1]=Gc(s,c[1]),l[1]=Kc(s,l[1])}function rl(e,t,n,r,i,a,o,s){var c=kr,l=Er,u=Kc(Gc(c(e,n,i),1),0),d=Kc(Gc(c(t,r,a),1),0),f=l(e,n,i,u),p=l(t,r,a,d);o[0]=Gc(e,i,f),o[1]=Gc(t,a,p),s[0]=Kc(e,i,f),s[1]=Kc(t,a,p)}function il(e,t,n,r,i,a,o,s,c){var l=bt,u=xt,d=Math.abs(i-a);if(d%Yc<1e-4&&d>1e-4){s[0]=e-n,s[1]=t-r,c[0]=e+n,c[1]=t+r;return}if(Xc[0]=Jc(i)*n+e,Xc[1]=qc(i)*r+t,Zc[0]=Jc(a)*n+e,Zc[1]=qc(a)*r+t,l(s,Xc,Zc),u(c,Xc,Zc),i%=Yc,i<0&&(i+=Yc),a%=Yc,a<0&&(a+=Yc),i>a&&!o?a+=Yc:i<a&&o&&(i+=Yc),o){var f=a;a=i,i=f}for(var p=0;p<a;p+=Math.PI/2)p>i&&(Qc[0]=Jc(p)*n+e,Qc[1]=qc(p)*r+t,l(s,Qc,s),u(c,Qc,c))}var al={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},ol=[],sl=[],cl=[],ll=[],ul=[],dl=[],fl=Math.min,pl=Math.max,ml=Math.cos,hl=Math.sin,gl=Math.abs,_l=Math.PI,vl=_l*2,yl=typeof Float32Array<`u`,bl=[];function xl(e){return Math.round(e/_l*1e8)/1e8%2*_l}function Sl(e,t){var n=xl(e[0]);n<0&&(n+=vl);var r=n-e[0],i=e[1];i+=r,!t&&i-n>=vl?i=n+vl:t&&n-i>=vl?i=n-vl:!t&&n>i?i=n+(vl-xl(n-i)):t&&n<i&&(i=n-(vl-xl(i-n))),e[0]=n,e[1]=i}var Cl=function(){function e(e){this.dpr=1,this._xi=0,this._yi=0,this._x0=0,this._y0=0,this._len=0,e&&(this._saveData=!1),this._saveData&&(this.data=[])}return e.prototype.increaseVersion=function(){this._version++},e.prototype.getVersion=function(){return this._version},e.prototype.setScale=function(e,t,n){n||=0,n>0&&(this._ux=gl(n/ta/e)||0,this._uy=gl(n/ta/t)||0)},e.prototype.setDPR=function(e){this.dpr=e},e.prototype.setContext=function(e){this._ctx=e},e.prototype.getContext=function(){return this._ctx},e.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},e.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},e.prototype.moveTo=function(e,t){return this._drawPendingPt(),this.addData(al.M,e,t),this._ctx&&this._ctx.moveTo(e,t),this._x0=e,this._y0=t,this._xi=e,this._yi=t,this},e.prototype.lineTo=function(e,t){var n=gl(e-this._xi),r=gl(t-this._yi),i=n>this._ux||r>this._uy;if(this.addData(al.L,e,t),this._ctx&&i&&this._ctx.lineTo(e,t),i)this._xi=e,this._yi=t,this._pendingPtDist=0;else{var a=n*n+r*r;a>this._pendingPtDist&&(this._pendingPtX=e,this._pendingPtY=t,this._pendingPtDist=a)}return this},e.prototype.bezierCurveTo=function(e,t,n,r,i,a){return this._drawPendingPt(),this.addData(al.C,e,t,n,r,i,a),this._ctx&&this._ctx.bezierCurveTo(e,t,n,r,i,a),this._xi=i,this._yi=a,this},e.prototype.quadraticCurveTo=function(e,t,n,r){return this._drawPendingPt(),this.addData(al.Q,e,t,n,r),this._ctx&&this._ctx.quadraticCurveTo(e,t,n,r),this._xi=n,this._yi=r,this},e.prototype.arc=function(e,t,n,r,i,a){this._drawPendingPt(),bl[0]=r,bl[1]=i,Sl(bl,a),r=bl[0],i=bl[1];var o=i-r;return this.addData(al.A,e,t,n,n,r,o,0,+!a),this._ctx&&this._ctx.arc(e,t,n,r,i,a),this._xi=ml(i)*n+e,this._yi=hl(i)*n+t,this},e.prototype.arcTo=function(e,t,n,r,i){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(e,t,n,r,i),this},e.prototype.rect=function(e,t,n,r){return this._drawPendingPt(),this._ctx&&this._ctx.rect(e,t,n,r),this.addData(al.R,e,t,n,r),this},e.prototype.closePath=function(){this._drawPendingPt(),this.addData(al.Z);var e=this._ctx,t=this._x0,n=this._y0;return e&&e.closePath(),this._xi=t,this._yi=n,this},e.prototype.fill=function(e){e&&e.fill(),this.toStatic()},e.prototype.stroke=function(e){e&&e.stroke(),this.toStatic()},e.prototype.len=function(){return this._len},e.prototype.setData=function(e){if(this._saveData){var t=e.length;!(this.data&&this.data.length===t)&&yl&&(this.data=new Float32Array(t));for(var n=0;n<t;n++)this.data[n]=e[n];this._len=t}},e.prototype.appendPath=function(e){if(this._saveData){e instanceof Array||(e=[e]);for(var t=e.length,n=0,r=this._len,i=0;i<t;i++)n+=e[i].len();var a=this.data;if(yl&&(a instanceof Float32Array||!a)&&(this.data=new Float32Array(r+n),r>0&&a))for(var o=0;o<r;o++)this.data[o]=a[o];for(var i=0;i<t;i++)for(var s=e[i].data,o=0;o<s.length;o++)this.data[r++]=s[o];this._len=r}},e.prototype.addData=function(e,t,n,r,i,a,o,s,c){if(this._saveData){var l=this.data;this._len+arguments.length>l.length&&(this._expandData(),l=this.data);for(var u=0;u<arguments.length;u++)l[this._len++]=arguments[u]}},e.prototype._drawPendingPt=function(){this._pendingPtDist>0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},e.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var e=[],t=0;t<this._len;t++)e[t]=this.data[t];this.data=e}},e.prototype.toStatic=function(){if(this._saveData){this._drawPendingPt();var e=this.data;e instanceof Array&&(e.length=this._len,yl&&this._len>11&&(this.data=new Float32Array(e)))}},e.prototype.getBoundingRect=function(){cl[0]=cl[1]=ul[0]=ul[1]=Number.MAX_VALUE,ll[0]=ll[1]=dl[0]=dl[1]=-Number.MAX_VALUE;var e=this.data,t=0,n=0,r=0,i=0,a;for(a=0;a<this._len;){var o=e[a++],s=a===1;switch(s&&(t=e[a],n=e[a+1],r=t,i=n),o){case al.M:t=r=e[a++],n=i=e[a++],ul[0]=r,ul[1]=i,dl[0]=r,dl[1]=i;break;case al.L:$c(t,n,e[a],e[a+1],ul,dl),t=e[a++],n=e[a++];break;case al.C:nl(t,n,e[a++],e[a++],e[a++],e[a++],e[a],e[a+1],ul,dl),t=e[a++],n=e[a++];break;case al.Q:rl(t,n,e[a++],e[a++],e[a],e[a+1],ul,dl),t=e[a++],n=e[a++];break;case al.A:var c=e[a++],l=e[a++],u=e[a++],d=e[a++],f=e[a++],p=e[a++]+f;a+=1;var m=!e[a++];s&&(r=ml(f)*u+c,i=hl(f)*d+l),il(c,l,u,d,f,p,m,ul,dl),t=ml(p)*u+c,n=hl(p)*d+l;break;case al.R:r=t=e[a++],i=n=e[a++];var h=e[a++],g=e[a++];$c(r,i,r+h,i+g,ul,dl);break;case al.Z:t=r,n=i;break}bt(cl,cl,ul),xt(ll,ll,dl)}return a===0&&(cl[0]=cl[1]=ll[0]=ll[1]=0),new Y(cl[0],cl[1],ll[0]-cl[0],ll[1]-cl[1])},e.prototype._calculateLength=function(){var e=this.data,t=this._len,n=this._ux,r=this._uy,i=0,a=0,o=0,s=0;this._pathSegLen||=[];for(var c=this._pathSegLen,l=0,u=0,d=0;d<t;){var f=e[d++],p=d===1;p&&(i=e[d],a=e[d+1],o=i,s=a);var m=-1;switch(f){case al.M:i=o=e[d++],a=s=e[d++];break;case al.L:var h=e[d++],g=e[d++],_=h-i,v=g-a;(gl(_)>n||gl(v)>r||d===t-1)&&(m=Math.sqrt(_*_+v*v),i=h,a=g);break;case al.C:var y=e[d++],b=e[d++],h=e[d++],g=e[d++],x=e[d++],S=e[d++];m=Tr(i,a,y,b,h,g,x,S,10),i=x,a=S;break;case al.Q:var y=e[d++],b=e[d++],h=e[d++],g=e[d++];m=Mr(i,a,y,b,h,g,10),i=h,a=g;break;case al.A:var C=e[d++],w=e[d++],T=e[d++],E=e[d++],D=e[d++],O=e[d++],k=O+D;d+=1,p&&(o=ml(D)*T+C,s=hl(D)*E+w),m=pl(T,E)*fl(vl,Math.abs(O)),i=ml(k)*T+C,a=hl(k)*E+w;break;case al.R:o=i=e[d++],s=a=e[d++];var A=e[d++],j=e[d++];m=A*2+j*2;break;case al.Z:var _=o-i,v=s-a;m=Math.sqrt(_*_+v*v),i=o,a=s;break}m>=0&&(c[u++]=m,l+=m)}return this._pathLen=l,l},e.prototype.rebuildPath=function(e,t){var n=this.data,r=this._ux,i=this._uy,a=this._len,o,s,c,l,u,d,f=t<1,p,m,h=0,g=0,_,v=0,y,b;if(!(f&&(this._pathSegLen||this._calculateLength(),p=this._pathSegLen,m=this._pathLen,_=t*m,!_)))lo:for(var x=0;x<a;){var S=n[x++],C=x===1;switch(C&&(c=n[x],l=n[x+1],o=c,s=l),S!==al.L&&v>0&&(e.lineTo(y,b),v=0),S){case al.M:o=c=n[x++],s=l=n[x++],e.moveTo(c,l);break;case al.L:u=n[x++],d=n[x++];var w=gl(u-c),T=gl(d-l);if(w>r||T>i){if(f){var E=p[g++];if(h+E>_){var D=(_-h)/E;e.lineTo(c*(1-D)+u*D,l*(1-D)+d*D);break lo}h+=E}e.lineTo(u,d),c=u,l=d,v=0}else{var O=w*w+T*T;O>v&&(y=u,b=d,v=O)}break;case al.C:var k=n[x++],A=n[x++],j=n[x++],ee=n[x++],te=n[x++],ne=n[x++];if(f){var E=p[g++];if(h+E>_){var D=(_-h)/E;Cr(c,k,j,te,D,ol),Cr(l,A,ee,ne,D,sl),e.bezierCurveTo(ol[1],sl[1],ol[2],sl[2],ol[3],sl[3]);break lo}h+=E}e.bezierCurveTo(k,A,j,ee,te,ne),c=te,l=ne;break;case al.Q:var k=n[x++],A=n[x++],j=n[x++],ee=n[x++];if(f){var E=p[g++];if(h+E>_){var D=(_-h)/E;Ar(c,k,j,D,ol),Ar(l,A,ee,D,sl),e.quadraticCurveTo(ol[1],sl[1],ol[2],sl[2]);break lo}h+=E}e.quadraticCurveTo(k,A,j,ee),c=j,l=ee;break;case al.A:var re=n[x++],ie=n[x++],ae=n[x++],oe=n[x++],M=n[x++],se=n[x++],ce=n[x++],le=!n[x++],ue=ae>oe?ae:oe,de=gl(ae-oe)>.001,fe=M+se,N=!1;if(f){var E=p[g++];h+E>_&&(fe=M+se*(_-h)/E,N=!0),h+=E}if(de&&e.ellipse?e.ellipse(re,ie,ae,oe,ce,M,fe,le):e.arc(re,ie,ue,M,fe,le),N)break lo;C&&(o=ml(M)*ae+re,s=hl(M)*oe+ie),c=ml(fe)*ae+re,l=hl(fe)*oe+ie;break;case al.R:o=c=n[x],s=l=n[x+1],u=n[x++],d=n[x++];var pe=n[x++],me=n[x++];if(f){var E=p[g++];if(h+E>_){var he=_-h;e.moveTo(u,d),e.lineTo(u+fl(he,pe),d),he-=pe,he>0&&e.lineTo(u+pe,d+fl(he,me)),he-=me,he>0&&e.lineTo(u+pl(pe-he,0),d+me),he-=pe,he>0&&e.lineTo(u,d+pl(me-he,0));break lo}h+=E}e.rect(u,d,pe,me);break;case al.Z:if(f){var E=p[g++];if(h+E>_){var D=(_-h)/E;e.lineTo(c*(1-D)+o*D,l*(1-D)+s*D);break lo}h+=E}e.closePath(),c=o,l=s}}},e.prototype.clone=function(){var t=new e,n=this.data;return t.data=n.slice?n.slice():Array.prototype.slice.call(n),t._len=this._len,t},e.prototype.canSave=function(){return!!this._saveData},e.CMD=al,e.initDefaultProps=(function(){var t=e.prototype;t._saveData=!0,t._ux=0,t._uy=0,t._pendingPtDist=0,t._version=0})(),e}();function wl(e,t,n,r,i,a,o){if(i===0)return!1;var s=i,c=0,l=e;if(o>t+s&&o>r+s||o<t-s&&o<r-s||a>e+s&&a>n+s||a<e-s&&a<n-s)return!1;if(e!==n)c=(t-r)/(e-n),l=(e*r-n*t)/(e-n);else return Math.abs(a-e)<=s/2;var u=c*a-o+l;return u*u/(c*c+1)<=s/2*s/2}function Tl(e,t,n,r,i,a,o,s,c,l,u){if(c===0)return!1;var d=c;return u>t+d&&u>r+d&&u>a+d&&u>s+d||u<t-d&&u<r-d&&u<a-d&&u<s-d||l>e+d&&l>n+d&&l>i+d&&l>o+d||l<e-d&&l<n-d&&l<i-d&&l<o-d?!1:wr(e,t,n,r,i,a,o,s,l,u,null)<=d/2}function El(e,t,n,r,i,a,o,s,c){if(o===0)return!1;var l=o;return c>t+l&&c>r+l&&c>a+l||c<t-l&&c<r-l&&c<a-l||s>e+l&&s>n+l&&s>i+l||s<e-l&&s<n-l&&s<i-l?!1:jr(e,t,n,r,i,a,s,c,null)<=l/2}var Dl=Math.PI*2;function Ol(e){return e%=Dl,e<0&&(e+=Dl),e}var kl=Math.PI*2;function Al(e,t,n,r,i,a,o,s,c){if(o===0)return!1;var l=o;s-=e,c-=t;var u=Math.sqrt(s*s+c*c);if(u-l>n||u+l<n)return!1;if(Math.abs(r-i)%kl<1e-4)return!0;if(a){var d=r;r=Ol(i),i=Ol(d)}else r=Ol(r),i=Ol(i);r>i&&(i+=kl);var f=Math.atan2(c,s);return f<0&&(f+=kl),f>=r&&f<=i||f+kl>=r&&f+kl<=i}function jl(e,t,n,r,i,a){if(a>t&&a>r||a<t&&a<r||r===t)return 0;var o=(a-t)/(r-t),s=r<t?1:-1;(o===1||o===0)&&(s=r<t?.5:-.5);var c=o*(n-e)+e;return c===i?1/0:c>i?s:0}var Ml=Cl.CMD,Nl=Math.PI*2,Pl=1e-4;function Fl(e,t){return Math.abs(e-t)<Pl}var Il=[-1,-1,-1],Ll=[-1,-1];function Rl(){var e=Ll[0];Ll[0]=Ll[1],Ll[1]=e}function zl(e,t,n,r,i,a,o,s,c,l){if(l>t&&l>r&&l>a&&l>s||l<t&&l<r&&l<a&&l<s)return 0;var u=xr(t,r,a,s,l,Il);if(u===0)return 0;for(var d=0,f=-1,p=void 0,m=void 0,h=0;h<u;h++){var g=Il[h],_=g===0||g===1?.5:1;yr(e,n,i,o,g)<c||(f<0&&(f=Sr(t,r,a,s,Ll),Ll[1]<Ll[0]&&f>1&&Rl(),p=yr(t,r,a,s,Ll[0]),f>1&&(m=yr(t,r,a,s,Ll[1]))),f===2?g<Ll[0]?d+=p<t?_:-_:g<Ll[1]?d+=m<p?_:-_:d+=s<m?_:-_:g<Ll[0]?d+=p<t?_:-_:d+=s<p?_:-_)}return d}function Bl(e,t,n,r,i,a,o,s){if(s>t&&s>r&&s>a||s<t&&s<r&&s<a)return 0;var c=Or(t,r,a,s,Il);if(c===0)return 0;var l=kr(t,r,a);if(l>=0&&l<=1){for(var u=0,d=Er(t,r,a,l),f=0;f<c;f++){var p=Il[f]===0||Il[f]===1?.5:1,m=Er(e,n,i,Il[f]);m<o||(Il[f]<l?u+=d<t?p:-p:u+=a<d?p:-p)}return u}else{var p=Il[0]===0||Il[0]===1?.5:1,m=Er(e,n,i,Il[0]);return m<o?0:a<t?p:-p}}function Vl(e,t,n,r,i,a,o,s){if(s-=t,s>n||s<-n)return 0;var c=Math.sqrt(n*n-s*s);Il[0]=-c,Il[1]=c;var l=Math.abs(r-i);if(l<1e-4)return 0;if(l>=Nl-1e-4){r=0,i=Nl;var u=a?1:-1;return o>=Il[0]+e&&o<=Il[1]+e?u:0}if(r>i){var d=r;r=i,i=d}r<0&&(r+=Nl,i+=Nl);for(var f=0,p=0;p<2;p++){var m=Il[p];if(m+e>o){var h=Math.atan2(s,m),u=a?1:-1;h<0&&(h=Nl+h),(h>=r&&h<=i||h+Nl>=r&&h+Nl<=i)&&(h>Math.PI/2&&h<Math.PI*1.5&&(u=-u),f+=u)}}return f}function Hl(e,t,n,r,i){for(var a=e.data,o=e.len(),s=0,c=0,l=0,u=0,d=0,f,p,m=0;m<o;){var h=a[m++],g=m===1;switch(h===Ml.M&&m>1&&(n||(s+=jl(c,l,u,d,r,i))),g&&(c=a[m],l=a[m+1],u=c,d=l),h){case Ml.M:u=a[m++],d=a[m++],c=u,l=d;break;case Ml.L:if(n){if(wl(c,l,a[m],a[m+1],t,r,i))return!0}else s+=jl(c,l,a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case Ml.C:if(n){if(Tl(c,l,a[m++],a[m++],a[m++],a[m++],a[m],a[m+1],t,r,i))return!0}else s+=zl(c,l,a[m++],a[m++],a[m++],a[m++],a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case Ml.Q:if(n){if(El(c,l,a[m++],a[m++],a[m],a[m+1],t,r,i))return!0}else s+=Bl(c,l,a[m++],a[m++],a[m],a[m+1],r,i)||0;c=a[m++],l=a[m++];break;case Ml.A:var _=a[m++],v=a[m++],y=a[m++],b=a[m++],x=a[m++],S=a[m++];m+=1;var C=!!(1-a[m++]);f=Math.cos(x)*y+_,p=Math.sin(x)*b+v,g?(u=f,d=p):s+=jl(c,l,f,p,r,i);var w=(r-_)*b/y+_;if(n){if(Al(_,v,b,x,x+S,C,t,w,i))return!0}else s+=Vl(_,v,b,x,x+S,C,w,i);c=Math.cos(x+S)*y+_,l=Math.sin(x+S)*b+v;break;case Ml.R:u=c=a[m++],d=l=a[m++];var T=a[m++],E=a[m++];if(f=u+T,p=d+E,n){if(wl(u,d,f,d,t,r,i)||wl(f,d,f,p,t,r,i)||wl(f,p,u,p,t,r,i)||wl(u,p,u,d,t,r,i))return!0}else s+=jl(f,d,f,p,r,i),s+=jl(u,p,u,d,r,i);break;case Ml.Z:if(n){if(wl(c,l,u,d,t,r,i))return!0}else s+=jl(c,l,u,d,r,i);c=u,l=d;break}}return!n&&!Fl(l,d)&&(s+=jl(c,l,u,d,r,i)||0),s!==0}function Ul(e,t,n){return Hl(e,0,!1,t,n)}function Wl(e,t,n,r){return Hl(e,t,!0,n,r)}var Gl=L({fill:`#000`,stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:`butt`,miterLimit:10,strokeNoScale:!1,strokeFirst:!1},Lc),Kl={style:L({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},Rc.style)},ql=ga.concat([`invisible`,`culling`,`z`,`z2`,`zlevel`,`parent`]),Jl=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.update=function(){var n=this;e.prototype.update.call(this);var r=this.style;if(r.decal){var i=this._decalEl=this._decalEl||new t;i.buildPath===t.prototype.buildPath&&(i.buildPath=function(e){n.buildPath(e,n.shape)}),i.silent=!0;var a=i.style;for(var o in r)a[o]!==r[o]&&(a[o]=r[o]);a.fill=r.fill?r.decal:null,a.decal=null,a.shadowColor=null,r.strokeFirst&&(a.stroke=null);for(var s=0;s<ql.length;++s)i[ql[s]]=this[ql[s]];i.__dirty|=1}else this._decalEl&&=null},t.prototype.getDecalElement=function(){return this._decalEl},t.prototype._init=function(t){var n=Oe(t);this.shape=this.getDefaultShape();var r=this.getDefaultStyle();r&&this.useStyle(r);for(var i=0;i<n.length;i++){var a=n[i],o=t[a];a===`style`?this.style?I(this.style,o):this.useStyle(o):a===`shape`?I(this.shape,o):e.prototype.attrKV.call(this,a,o)}this.style||this.useStyle({})},t.prototype.getDefaultStyle=function(){return null},t.prototype.getDefaultShape=function(){return{}},t.prototype.canBeInsideText=function(){return this.hasFill()},t.prototype.getInsideTextFill=function(){var e=this.style.fill;if(e!==`none`){if(G(e)){var t=ai(e,0);return t>.5?ra:t>.2?aa:ia}else if(e)return ia}return ra},t.prototype.getInsideTextStroke=function(e){var t=this.style.fill;if(G(t)){var n=this.__zr;if(!!(n&&n.isDarkMode())==ai(e,0)<.4)return t}},t.prototype.buildPath=function(e,t,n){},t.prototype.pathUpdated=function(){this.__dirty&=-5},t.prototype.getUpdatedPathProxy=function(e){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,e),this.path},t.prototype.createPathProxy=function(){this.path=new Cl(!1)},t.prototype.hasStroke=function(){var e=this.style,t=e.stroke;return!(t==null||t===`none`||!(e.lineWidth>0))},t.prototype.hasFill=function(){var e=this.style.fill;return e!=null&&e!==`none`},t.prototype.getBoundingRect=function(){var e=this._rect,t=this.style,n=!e;if(n){var r=!1;this.path||(r=!0,this.createPathProxy());var i=this.path;(r||this.__dirty&4)&&(i.beginPath(),this.buildPath(i,this.shape,!1),this.pathUpdated()),e=i.getBoundingRect()}if(this._rect=e,this.hasStroke()&&this.path&&this.path.len()>0){var a=this._rectStroke||=e.clone();if(this.__dirty||n){a.copy(e);var o=t.strokeNoScale?this.getLineScale():1,s=t.lineWidth;if(!this.hasFill()){var c=this.strokeContainThreshold;s=Math.max(s,c??4)}o>1e-10&&(a.width+=s/o,a.height+=s/o,a.x-=s/o/2,a.y-=s/o/2)}return a}return e},t.prototype.contain=function(e,t){var n=this.transformCoordToLocal(e,t),r=this.getBoundingRect(),i=this.style;if(e=n[0],t=n[1],r.contain(e,t)){var a=this.path;if(this.hasStroke()){var o=i.lineWidth,s=i.strokeNoScale?this.getLineScale():1;if(s>1e-10&&(this.hasFill()||(o=Math.max(o,this.strokeContainThreshold)),Wl(a,o/s,e,t)))return!0}if(this.hasFill())return Ul(a,e,t)}return!1},t.prototype.dirtyShape=function(){this.__dirty|=4,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(t,n){t===`shape`?this.setShape(n):e.prototype.attrKV.call(this,t,n)},t.prototype.setShape=function(e,t){var n=this.shape;return n||=this.shape={},typeof e==`string`?n[e]=t:I(n,e),this.dirtyShape(),this},t.prototype.shapeChanged=function(){return!!(this.__dirty&4)},t.prototype.createStyle=function(e){return Qe(Gl,e)},t.prototype._innerSaveToNormal=function(t){e.prototype._innerSaveToNormal.call(this,t);var n=this._normalState;t.shape&&!n.shape&&(n.shape=I({},this.shape))},t.prototype._applyStateObj=function(t,n,r,i,a,o){if(e.prototype._applyStateObj.call(this,t,n,r,i,a,o),this.__inHover!==1){var s=!(n&&i),c;if(n&&n.shape?a?i?c=n.shape:(c=I({},r.shape),I(c,n.shape)):(c=I({},i?this.shape:r.shape),I(c,n.shape)):s&&(c=r.shape),c)if(a){this.shape=I({},this.shape);for(var l={},u=Oe(c),d=0;d<u.length;d++){var f=u[d];typeof c[f]==`object`?this.shape[f]=c[f]:l[f]=c[f]}this._transitionState(t,{shape:l},o)}else this.shape=c,this.dirtyShape()}},t.prototype._mergeStates=function(t){for(var n=e.prototype._mergeStates.call(this,t),r,i=0;i<t.length;i++){var a=t[i];a.shape&&(r||={},this._mergeStyle(r,a.shape))}return r&&(n.shape=r),n},t.prototype.getAnimationStyleProps=function(){return Kl},t.prototype.isZeroArea=function(){return!1},t.extend=function(e){var n=function(t){it(n,t);function n(n){var r=t.call(this,n)||this;return e.init&&e.init.call(r,n),r}return n.prototype.getDefaultStyle=function(){return P(e.style)},n.prototype.getDefaultShape=function(){return P(e.shape)},n}(t);for(var r in e)typeof e[r]==`function`&&(n.prototype[r]=e[r]);return n},t.initDefaultProps=(function(){var e=t.prototype;e.type=`path`,e.strokeContainThreshold=5,e.segmentIgnoreThreshold=0,e.subPixelOptimize=!1,e.autoBatch=!1,e.__dirty=7})(),t}(Vc),Yl=L({strokeFirst:!0,font:te,x:0,y:0,textAlign:`left`,textBaseline:`top`,miterLimit:2},Gl),Xl=function(e){it(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.hasStroke=function(){return Fc(this.style)},t.prototype.hasFill=function(){var e=this.style.fill;return e!=null&&e!==`none`},t.prototype.createStyle=function(e){return Qe(Yl,e)},t.prototype.setBoundingRect=function(e){this._rect=e},t.prototype.getBoundingRect=function(){return this._rect||=Nc(this.style),this._rect},t.initDefaultProps=(function(){var e=t.prototype;e.dirtyRectTolerance=10})(),t}(Vc);Xl.prototype.type=`tspan`;var Zl=L({x:0,y:0},Lc),Ql={style:L({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},Rc.style)};function $l(e){return!!(e&&typeof e!=`string`&&e.width&&e.height)}var eu=function(e){it(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.createStyle=function(e){return Qe(Zl,e)},t.prototype._getSize=function(e){var t=this.style,n=t[e];if(n!=null)return n;var r=$l(t.image)?t.image:this.__image;if(!r)return 0;var i=e===`width`?`height`:`width`,a=t[i];return a==null?r[e]:r[e]/r[i]*a},t.prototype.getWidth=function(){return this._getSize(`width`)},t.prototype.getHeight=function(){return this._getSize(`height`)},t.prototype.getAnimationStyleProps=function(){return Ql},t.prototype.getBoundingRect=function(){var e=this.style;return this._rect||=new Y(e.x||0,e.y||0,this.getWidth(),this.getHeight()),this._rect},t}(Vc);eu.prototype.type=`image`;function tu(e,t){var n=t.x,r=t.y,i=t.width,a=t.height,o=t.r,s,c,l,u;i<0&&(n+=i,i=-i),a<0&&(r+=a,a=-a),typeof o==`number`?s=c=l=u=o:o instanceof Array?o.length===1?s=c=l=u=o[0]:o.length===2?(s=l=o[0],c=u=o[1]):o.length===3?(s=o[0],c=u=o[1],l=o[2]):(s=o[0],c=o[1],l=o[2],u=o[3]):s=c=l=u=0;var d;s+c>i&&(d=s+c,s*=i/d,c*=i/d),l+u>i&&(d=l+u,l*=i/d,u*=i/d),c+l>a&&(d=c+l,c*=a/d,l*=a/d),s+u>a&&(d=s+u,s*=a/d,u*=a/d),e.moveTo(n+s,r),e.lineTo(n+i-c,r),c!==0&&e.arc(n+i-c,r+c,c,-Math.PI/2,0),e.lineTo(n+i,r+a-l),l!==0&&e.arc(n+i-l,r+a-l,l,0,Math.PI/2),e.lineTo(n+u,r+a),u!==0&&e.arc(n+u,r+a-u,u,Math.PI/2,Math.PI),e.lineTo(n,r+s),s!==0&&e.arc(n+s,r+s,s,Math.PI,Math.PI*1.5),e.closePath()}var nu=Math.round;function ru(e,t,n){if(t){var r=t.x1,i=t.x2,a=t.y1,o=t.y2;e.x1=r,e.x2=i,e.y1=a,e.y2=o;var s=n&&n.lineWidth;return s?(nu(r*2)===nu(i*2)&&(e.x1=e.x2=au(r,s,!0)),nu(a*2)===nu(o*2)&&(e.y1=e.y2=au(a,s,!0)),e):e}}function iu(e,t,n){if(t){var r=t.x,i=t.y,a=t.width,o=t.height;e.x=r,e.y=i,e.width=a,e.height=o;var s=n&&n.lineWidth;return s?(e.x=au(r,s,!0),e.y=au(i,s,!0),e.width=Math.max(au(r+a,s,!1)-e.x,a===0?0:1),e.height=Math.max(au(i+o,s,!1)-e.y,o===0?0:1),e):e}}function au(e,t,n){if(!t)return e;var r=nu(e*2);return(r+nu(t))%2==0?r/2:(r+(n?1:-1))/2}var ou=function(){function e(){this.x=0,this.y=0,this.width=0,this.height=0}return e}(),su={},cu=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new ou},t.prototype.buildPath=function(e,t){var n,r,i,a;if(this.subPixelOptimize){var o=iu(su,t,this.style);n=o.x,r=o.y,i=o.width,a=o.height,o.r=t.r,t=o}else n=t.x,r=t.y,i=t.width,a=t.height;t.r?tu(e,t):e.rect(n,r,i,a)},t.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},t}(Jl);cu.prototype.type=`rect`;var lu={fill:`#000`},uu=2,du={},fu={style:L({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},Rc.style)},pu=function(e){it(t,e);function t(t){var n=e.call(this)||this;return n.type=`text`,n._children=[],n._defaultStyle=lu,n.attr(t),n}return t.prototype.childrenRef=function(){return this._children},t.prototype.update=function(){e.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var t=0;t<this._children.length;t++){var n=this._children[t];n.zlevel=this.zlevel,n.z=this.z,n.z2=this.z2,n.culling=this.culling,n.cursor=this.cursor,n.invisible=this.invisible}},t.prototype.updateTransform=function(){var t=this.innerTransformable;t?(t.updateTransform(),t.transform&&(this.transform=t.transform)):e.prototype.updateTransform.call(this)},t.prototype.getLocalTransform=function(t){var n=this.innerTransformable;return n?n.getLocalTransform(t):e.prototype.getLocalTransform.call(this,t)},t.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),e.prototype.getComputedTransform.call(this)},t.prototype._updateSubTexts=function(){this._childCursor=0,bu(this.style),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},t.prototype.addSelfToZr=function(t){e.prototype.addSelfToZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].__zr=t},t.prototype.removeSelfFromZr=function(t){e.prototype.removeSelfFromZr.call(this,t);for(var n=0;n<this._children.length;n++)this._children[n].__zr=null},t.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var e=new Y(0,0,0,0),t=this._children,n=[],r=null,i=0;i<t.length;i++){var a=t[i],o=a.getBoundingRect(),s=a.getLocalTransform(n);s?(e.copy(o),e.applyTransform(s),r||=e.clone(),r.union(e)):(r||=o.clone(),r.union(o))}this._rect=r||e}return this._rect},t.prototype.setDefaultTextStyle=function(e){this._defaultStyle=e||lu},t.prototype.setTextContent=function(e){},t.prototype._mergeStyle=function(e,t){if(!t)return e;var n=t.rich,r=e.rich||n&&{};return I(e,t),n&&r?(this._mergeRich(r,n),e.rich=r):r&&(e.rich=r),e},t.prototype._mergeRich=function(e,t){for(var n=Oe(t),r=0;r<n.length;r++){var i=n[r];e[i]=e[i]||{},I(e[i],t[i])}},t.prototype.getAnimationStyleProps=function(){return fu},t.prototype._getOrCreateChild=function(e){var t=this._children[this._childCursor];return(!t||!(t instanceof e))&&(t=new e),this._children[this._childCursor++]=t,t.__zr=this.__zr,t.parent=this,t},t.prototype._updatePlainTexts=function(){var e=this.style,t=e.font||`12px sans-serif`,n=e.padding,r=this._defaultStyle,i=e.x||0,a=e.y||0,o=e.align||r.align||`left`,s=e.verticalAlign||r.verticalAlign||`top`;kc(du,r.overflowRect,i,a,o,s),i=du.baseX,a=du.baseY;var c=yc(Tu(e),e,du.outerWidth,du.outerHeight),l=Eu(e),u=!!e.backgroundColor,d=c.outerHeight,f=c.outerWidth,p=c.lines,m=c.lineHeight;this.isTruncated=!!c.isTruncated;var h=i,g=Oa(a,c.contentHeight,s);if(l||n){var _=Da(i,f,o),v=Oa(a,d,s);l&&this._renderBackground(e,e,_,v,f,d)}g+=m/2,n&&(h=wu(i,o,n),s===`top`?g+=n[0]:s===`bottom`&&(g-=n[2]));for(var y=0,b=!1,x=!1,S=Cu(`fill`in e?e.fill:(x=!0,r.fill)),C=Su(`stroke`in e?e.stroke:!u&&(!r.autoStroke||x)?(y=uu,b=!0,r.stroke):null),w=e.textShadowBlur>0,T=0;T<p.length;T++){var E=this._getOrCreateChild(Xl),D=E.createStyle();E.useStyle(D),D.text=p[T],D.x=h,D.y=g,o&&(D.textAlign=o),D.textBaseline=`middle`,D.opacity=e.opacity,D.strokeFirst=!0,w&&(D.shadowBlur=e.textShadowBlur||0,D.shadowColor=e.textShadowColor||`transparent`,D.shadowOffsetX=e.textShadowOffsetX||0,D.shadowOffsetY=e.textShadowOffsetY||0),D.stroke=C,D.fill=S,C&&(D.lineWidth=e.lineWidth||y,D.lineDash=e.lineDash,D.lineDashOffset=e.lineDashOffset||0),D.font=t,vu(D,e),g+=m,E.setBoundingRect(Pc(D,c.contentWidth,c.calculatedLineHeight,b?0:null))}},t.prototype._updateRichTexts=function(){var e=this.style,t=this._defaultStyle,n=e.align||t.align,r=e.verticalAlign||t.verticalAlign,i=e.x||0,a=e.y||0;kc(du,t.overflowRect,i,a,n,r),i=du.baseX,a=du.baseY;var o=Cc(Tu(e),e,du.outerWidth,du.outerHeight,n),s=o.width,c=o.outerWidth,l=o.outerHeight,u=e.padding;this.isTruncated=!!o.isTruncated;var d=Da(i,c,n),f=Oa(a,l,r),p=d,m=f;u&&(p+=u[3],m+=u[0]);var h=p+s;Eu(e)&&this._renderBackground(e,e,d,f,c,l);for(var g=!!e.backgroundColor,_=0;_<o.lines.length;_++){for(var v=o.lines[_],y=v.tokens,b=y.length,x=v.lineHeight,S=v.width,C=0,w=p,T=h,E=b-1,D=void 0;C<b&&(D=y[C],!D.align||D.align===`left`);)this._placeToken(D,e,x,m,w,`left`,g),S-=D.width,w+=D.width,C++;for(;E>=0&&(D=y[E],D.align===`right`);)this._placeToken(D,e,x,m,T,`right`,g),S-=D.width,T-=D.width,E--;for(w+=(s-(w-p)-(h-T)-S)/2;C<=E;)D=y[C],this._placeToken(D,e,x,m,w+D.width/2,`center`,g),w+=D.width,C++;m+=x}},t.prototype._placeToken=function(e,t,n,r,i,a,o){var s=t.rich[e.styleName]||{};s.text=e.text;var c=e.verticalAlign,l=r+n/2;c===`top`?l=r+e.height/2:c===`bottom`&&(l=r+n-e.height/2),!e.isLineHolder&&Eu(s)&&this._renderBackground(s,t,a===`right`?i-e.width:a===`center`?i-e.width/2:i,l-e.height/2,e.width,e.height);var u=!!s.backgroundColor,d=e.textPadding;d&&(i=wu(i,a,d),l-=e.height/2-d[0]-e.innerHeight/2);var f=this._getOrCreateChild(Xl),p=f.createStyle();f.useStyle(p);var m=this._defaultStyle,h=!1,g=0,_=!1,v=Cu(`fill`in s?s.fill:`fill`in t?t.fill:(h=!0,m.fill)),y=Su(`stroke`in s?s.stroke:`stroke`in t?t.stroke:!u&&!o&&(!m.autoStroke||h)?(g=uu,_=!0,m.stroke):null),b=s.textShadowBlur>0||t.textShadowBlur>0;p.text=e.text,p.x=i,p.y=l,b&&(p.shadowBlur=s.textShadowBlur||t.textShadowBlur||0,p.shadowColor=s.textShadowColor||t.textShadowColor||`transparent`,p.shadowOffsetX=s.textShadowOffsetX||t.textShadowOffsetX||0,p.shadowOffsetY=s.textShadowOffsetY||t.textShadowOffsetY||0),p.textAlign=a,p.textBaseline=`middle`,p.font=e.font||`12px sans-serif`,p.opacity=ze(s.opacity,t.opacity,1),vu(p,s),y&&(p.lineWidth=ze(s.lineWidth,t.lineWidth,g),p.lineDash=q(s.lineDash,t.lineDash),p.lineDashOffset=t.lineDashOffset||0,p.stroke=y),v&&(p.fill=v),f.setBoundingRect(Pc(p,e.contentWidth,e.contentHeight,_?0:null))},t.prototype._renderBackground=function(e,t,n,r,i,a){var o=e.backgroundColor,s=e.borderWidth,c=e.borderColor,l=o&&o.image,u=o&&!l,d=e.borderRadius,f=this,p,m;if(u||e.lineHeight||s&&c){p=this._getOrCreateChild(cu),p.useStyle(p.createStyle()),p.style.fill=null;var h=p.shape;h.x=n,h.y=r,h.width=i,h.height=a,h.r=d,p.dirtyShape()}if(u){var g=p.style;g.fill=o||null,g.fillOpacity=q(e.fillOpacity,1)}else if(l){m=this._getOrCreateChild(eu),m.onload=function(){f.dirtyStyle()};var _=m.style;_.image=o.image,_.x=n,_.y=r,_.width=i,_.height=a}if(s&&c){var g=p.style;g.lineWidth=s,g.stroke=c,g.strokeOpacity=q(e.strokeOpacity,1),g.lineDash=e.borderDash,g.lineDashOffset=e.borderDashOffset||0,p.strokeContainThreshold=0,p.hasFill()&&p.hasStroke()&&(g.strokeFirst=!0,g.lineWidth*=2)}var v=(p||m).style;v.shadowBlur=e.shadowBlur||0,v.shadowColor=e.shadowColor||`transparent`,v.shadowOffsetX=e.shadowOffsetX||0,v.shadowOffsetY=e.shadowOffsetY||0,v.opacity=ze(e.opacity,t.opacity,1)},t.makeFont=function(e){var t=``;return yu(e)&&(t=[e.fontStyle,e.fontWeight,_u(e.fontSize),e.fontFamily||`sans-serif`].join(` `)),t&&Ue(t)||e.textFont||e.font},t}(Vc),mu={left:!0,right:1,center:1},hu={top:1,bottom:1,middle:1},gu=[`fontStyle`,`fontWeight`,`fontSize`,`fontFamily`];function _u(e){return typeof e==`string`&&(e.indexOf(`px`)!==-1||e.indexOf(`rem`)!==-1||e.indexOf(`em`)!==-1)?e:isNaN(+e)?`12px`:e+`px`}function vu(e,t){for(var n=0;n<gu.length;n++){var r=gu[n],i=t[r];i!=null&&(e[r]=i)}}function yu(e){return e.fontSize!=null||e.fontFamily||e.fontWeight}function bu(e){return xu(e),z(e.rich,xu),e}function xu(e){if(e){e.font=pu.makeFont(e);var t=e.align;t===`middle`&&(t=`center`),e.align=t==null||mu[t]?t:`left`;var n=e.verticalAlign;n===`center`&&(n=`middle`),e.verticalAlign=n==null||hu[n]?n:`top`,e.padding&&=Ve(e.padding)}}function Su(e,t){return e==null||t<=0||e===`transparent`||e===`none`?null:e.image||e.colorStops?`#000`:e}function Cu(e){return e==null||e===`none`?null:e.image||e.colorStops?`#000`:e}function wu(e,t,n){return t===`right`?e-n[1]:t===`center`?e+n[3]/2-n[1]/2:e+n[3]}function Tu(e){var t=e.text;return t!=null&&(t+=``),t}function Eu(e){return!!(e.backgroundColor||e.lineHeight||e.borderWidth&&e.borderColor)}var Du=Z(),Ou=function(e,t,n,r){if(r){var i=Du(r);i.dataIndex=n,i.dataType=t,i.seriesIndex=e,i.ssrType=`chart`,r.type===`group`&&r.traverse(function(r){var i=Du(r);i.seriesIndex=e,i.dataIndex=n,i.dataType=t,i.ssrType=`chart`})}},ku=J([`tooltip`,`label`,`itemName`,`itemId`,`itemGroupId`,`itemChildGroupId`,`seriesName`]),Au=`original`,ju=`arrayRows`,Mu=`objectRows`,Nu=`keyedColumns`,Pu=`typedArray`,Fu=`unknown`,Iu=`column`,Lu=[`getDom`,`getZr`,`getWidth`,`getHeight`,`getDevicePixelRatio`,`dispatchAction`,`isSSR`,`isDisposed`,`on`,`off`,`getDataURL`,`getConnectedDataURL`,`getOption`,`getId`,`updateLabelLayout`],Ru=function(){function e(e){z(Lu,function(t){this[t]=V(e[t],e)},this)}return e}();function zu(e,t){return t.mainType===`series`?e.getViewOfSeriesModel(t):e.getViewOfComponentModel(t)}var Bu=1,Vu={},Hu=Z(),Uu=Z(),Wu=[`emphasis`,`blur`,`select`],Gu=[`normal`,`emphasis`,`blur`,`select`],Ku=`highlight`,qu=`downplay`,Ju=`select`,Yu=`unselect`,Xu=`toggleSelect`,Zu=`selectchanged`;function Qu(e){return e!=null&&e!==`none`}function $u(e,t,n){e.onHoverStateChange&&(e.hoverState||0)!==n&&e.onHoverStateChange(t),e.hoverState=n}function ed(e){$u(e,`emphasis`,2)}function td(e){e.hoverState===2&&$u(e,`normal`,0)}function nd(e){$u(e,`blur`,1)}function rd(e){e.hoverState===1&&$u(e,`normal`,0)}function id(e){e.selected=!0}function ad(e){e.selected=!1}function od(e,t,n){t(e,n)}function sd(e,t,n){od(e,t,n),e.isGroup&&e.traverse(function(e){od(e,t,n)})}function cd(e,t){switch(t){case`emphasis`:e.hoverState=2;break;case`normal`:e.hoverState=0;break;case`blur`:e.hoverState=1;break;case`select`:e.selected=!0}}function ld(e,t,n,r){for(var i=e.style,a={},o=0;o<t.length;o++){var s=t[o];a[s]=i[s]??(r&&r[s])}for(var o=0;o<e.animators.length;o++){var c=e.animators[o];c.__fromStateTransition&&c.__fromStateTransition.indexOf(n)<0&&c.targetName===`style`&&c.saveTo(a,t)}return a}function ud(e,t,n,r){var i=n&&R(n,`select`)>=0,a=!1;if(e instanceof Jl){var o=Hu(e),s=i&&o.selectFill||o.normalFill,c=i&&o.selectStroke||o.normalStroke;if(Qu(s)||Qu(c)){r||={};var l=r.style||{};l.fill===`inherit`?(a=!0,r=I({},r),l=I({},l),l.fill=s):!Qu(l.fill)&&Qu(s)?(a=!0,r=I({},r),l=I({},l),l.fill=si(s)):!Qu(l.stroke)&&Qu(c)&&(a||(r=I({},r),l=I({},l)),l.stroke=si(c)),r.style=l}}if(r&&r.z2==null){a||(r=I({},r));var u=e.z2EmphasisLift;r.z2=e.z2+(u??10)}return r}function dd(e,t,n){if(n&&n.z2==null){n=I({},n);var r=e.z2SelectLift;n.z2=e.z2+(r??9)}return n}function fd(e,t,n){var r=R(e.currentStates,t)>=0,i=e.style.opacity,a=r?null:ld(e,[`opacity`],t,{opacity:1});n||={};var o=n.style||{};return o.opacity??(n=I({},n),o=I({opacity:r?i:a.opacity*.1},o),n.style=o),n}function pd(e,t){var n=this.states[e];if(this.style){if(e===`emphasis`)return ud(this,e,t,n);if(e===`blur`)return fd(this,e,n);if(e===`select`)return dd(this,e,n)}return n}function md(e){e.stateProxy=pd;var t=e.getTextContent(),n=e.getTextGuideLine();t&&(t.stateProxy=pd),n&&(n.stateProxy=pd)}function hd(e,t){!Cd(e,t)&&!e.__highByOuter&&sd(e,ed)}function gd(e,t){!Cd(e,t)&&!e.__highByOuter&&sd(e,td)}function _d(e,t){e.__highByOuter|=1<<(t||0),sd(e,ed)}function vd(e,t){!(e.__highByOuter&=~(1<<(t||0)))&&sd(e,td)}function yd(e){sd(e,nd)}function bd(e){sd(e,rd)}function xd(e){sd(e,id)}function Sd(e){sd(e,ad)}function Cd(e,t){return e.__highDownSilentOnTouch&&t.zrByTouch}function wd(e){var t=e.getModel(),n=[],r=[];t.eachComponent(function(t,i){var a=Uu(i),o=zu(e,i),s=t===`series`;!s&&r.push(o),a.isBlured&&(o.group.traverse(function(e){rd(e)}),s&&n.push(i)),a.isBlured=!1}),z(r,function(e){e&&e.toggleBlurSeries&&e.toggleBlurSeries(n,!1,t)})}function Td(e,t,n,r){var i=r.getModel();n||=`coordinateSystem`;function a(e,t){for(var n=0;n<t.length;n++){var r=e.getItemGraphicEl(t[n]);r&&bd(r)}}if(e!=null&&!(!t||t===`none`)){var o=i.getSeriesByIndex(e),s=o.coordinateSystem;s&&s.master&&(s=s.master);var c=[];i.eachSeries(function(e){var i=o===e,l=e.coordinateSystem;if(l&&l.master&&(l=l.master),!(n===`series`&&!i||n===`coordinateSystem`&&!(l&&s?l===s:i)||t===`series`&&i)){if(r.getViewOfSeriesModel(e).group.traverse(function(e){e.__highByOuter&&i&&t===`self`||nd(e)}),we(t))a(e.getData(),t);else if(K(t))for(var u=Oe(t),d=0;d<u.length;d++)a(e.getData(u[d]),t[u[d]]);c.push(e),Uu(e).isBlured=!0}}),i.eachComponent(function(e,t){if(e!==`series`){var n=r.getViewOfComponentModel(t);n&&n.toggleBlurSeries&&n.toggleBlurSeries(c,!0,i)}})}}function Ed(e,t,n){if(!(e==null||t==null)){var r=n.getModel().getComponent(e,t);if(r){Uu(r).isBlured=!0;var i=n.getViewOfComponentModel(r);!i||!i.focusBlurEnabled||i.group.traverse(function(e){nd(e)})}}}function Dd(e,t,n){var r=e.seriesIndex,i=e.getData(t.dataType);if(i){var a=_s(i,t);a=(U(a)?a[0]:a)||0;var o=i.getItemGraphicEl(a);if(!o)for(var s=i.count(),c=0;!o&&c<s;)o=i.getItemGraphicEl(c++);if(o){var l=Du(o);Td(r,l.focus,l.blurScope,n)}else{var u=e.get([`emphasis`,`focus`]),d=e.get([`emphasis`,`blurScope`]);u!=null&&Td(r,u,d,n)}}}function Od(e,t,n,r){var i={focusSelf:!1,dispatchers:null};if(e==null||e===`series`||t==null||n==null)return i;var a=r.getModel().getComponent(e,t);if(!a)return i;var o=r.getViewOfComponentModel(a);if(!o||!o.findHighDownDispatchers)return i;for(var s=o.findHighDownDispatchers(n),c,l=0;l<s.length;l++)if(Du(s[l]).focus===`self`){c=!0;break}return{focusSelf:c,dispatchers:s}}function kd(e,t,n){var r=Du(e),i=Od(r.componentMainType,r.componentIndex,r.componentHighDownName,n),a=i.dispatchers,o=i.focusSelf;a?(o&&Ed(r.componentMainType,r.componentIndex,n),z(a,function(e){return hd(e,t)})):(Td(r.seriesIndex,r.focus,r.blurScope,n),r.focus===`self`&&Ed(r.componentMainType,r.componentIndex,n),hd(e,t))}function Ad(e,t,n){wd(n);var r=Du(e),i=Od(r.componentMainType,r.componentIndex,r.componentHighDownName,n).dispatchers;i?z(i,function(e){return gd(e,t)}):gd(e,t)}function jd(e,t,n){if(Wd(t)){var r=t.dataType,i=_s(e.getData(r),t);U(i)||(i=[i]),e[t.type===`toggleSelect`?`toggleSelect`:t.type===`select`?`select`:`unselect`](i,r)}}function Md(e){z(e.getAllData(),function(t){var n=t.data,r=t.type;n.eachItemGraphicEl(function(t,n){e.isSelected(n,r)?xd(t):Sd(t)})})}function Nd(e){var t=[];return e.eachSeries(function(e){z(e.getAllData(),function(n){n.data;var r=n.type,i=e.getSelectedDataIndices();if(i.length>0){var a={dataIndex:i,seriesIndex:e.seriesIndex};r!=null&&(a.dataType=r),t.push(a)}})}),t}function Pd(e,t,n){Vd(e,!0),sd(e,md),Ld(e,t,n)}function Fd(e){Vd(e,!1)}function Id(e,t,n,r){r?Fd(e):Pd(e,t,n)}function Ld(e,t,n){var r=Du(e);t==null?r.focus&&=null:(r.focus=t,r.blurScope=n)}var Rd=[`emphasis`,`blur`,`select`],zd={itemStyle:`getItemStyle`,lineStyle:`getLineStyle`,areaStyle:`getAreaStyle`};function Bd(e,t,n,r){n||=`itemStyle`;for(var i=0;i<Rd.length;i++){var a=Rd[i],o=t.getModel([a,n]),s=e.ensureState(a);s.style=r?r(o):o[zd[n]]()}}function Vd(e,t){var n=t===!1,r=e;e.highDownSilentOnTouch&&(r.__highDownSilentOnTouch=e.highDownSilentOnTouch),(!n||r.__highDownDispatcher)&&(r.__highByOuter=r.__highByOuter||0,r.__highDownDispatcher=!n)}function Hd(e){return!!(e&&e.__highDownDispatcher)}function Ud(e){var t=Vu[e];return t==null&&Bu<=32&&(t=Vu[e]=Bu++),t}function Wd(e){var t=e.type;return t===`select`||t===`unselect`||t===`toggleSelect`}function Gd(e){var t=e.type;return t===`highlight`||t===`downplay`}function Kd(e){var t=Hu(e);t.normalFill=e.style.fill,t.normalStroke=e.style.stroke;var n=e.states.select||{};t.selectFill=n.style&&n.style.fill||null,t.selectStroke=n.style&&n.style.stroke||null}var qd=Cl.CMD,Jd=[[],[],[]],Yd=Math.sqrt,Xd=Math.atan2;function Zd(e,t){if(t){var n=e.data,r=e.len(),i,a,o,s,c,l,u=qd.M,d=qd.C,f=qd.L,p=qd.R,m=qd.A,h=qd.Q;for(o=0,s=0;o<r;){switch(i=n[o++],s=o,a=0,i){case u:a=1;break;case f:a=1;break;case d:a=3;break;case h:a=2;break;case m:var g=t[4],_=t[5],v=Yd(t[0]*t[0]+t[1]*t[1]),y=Yd(t[2]*t[2]+t[3]*t[3]),b=Xd(-t[1]/y,t[0]/v);n[o]*=v,n[o++]+=g,n[o]*=y,n[o++]+=_,n[o++]*=v,n[o++]*=y,n[o++]+=b,n[o++]+=b,o+=2,s=o;break;case p:l[0]=n[o++],l[1]=n[o++],yt(l,l,t),n[s++]=l[0],n[s++]=l[1],l[0]+=n[o++],l[1]+=n[o++],yt(l,l,t),n[s++]=l[0],n[s++]=l[1]}for(c=0;c<a;c++){var x=Jd[c];x[0]=n[o++],x[1]=n[o++],yt(x,x,t),n[s++]=x[0],n[s++]=x[1]}}e.increaseVersion()}}var Qd=Math.sqrt,$d=Math.sin,ef=Math.cos,tf=Math.PI;function nf(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function rf(e,t){return(e[0]*t[0]+e[1]*t[1])/(nf(e)*nf(t))}function af(e,t){return(e[0]*t[1]<e[1]*t[0]?-1:1)*Math.acos(rf(e,t))}function of(e,t,n,r,i,a,o,s,c,l,u){var d=tf/180*c,f=ef(d)*(e-n)/2+$d(d)*(t-r)/2,p=-1*$d(d)*(e-n)/2+ef(d)*(t-r)/2,m=f*f/(o*o)+p*p/(s*s);m>1&&(o*=Qd(m),s*=Qd(m));var h=(i===a?-1:1)*Qd((o*o*(s*s)-o*o*(p*p)-s*s*(f*f))/(o*o*(p*p)+s*s*(f*f)))||0,g=h*o*p/s,_=h*-s*f/o,v=(e+n)/2+ef(d)*g-$d(d)*_,y=(t+r)/2+$d(d)*g+ef(d)*_,b=af([1,0],[(f-g)/o,(p-_)/s]),x=[(f-g)/o,(p-_)/s],S=[(-1*f-g)/o,(-1*p-_)/s],C=af(x,S);if(rf(x,S)<=-1&&(C=tf),rf(x,S)>=1&&(C=0),C<0){var w=Math.round(C/tf*1e6)/1e6;C=tf*2+w%2*tf}u.addData(l,v,y,o,s,b,C,d,a)}var sf=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/gi,cf=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function lf(e){var t=new Cl;if(!e)return t;var n=0,r=0,i=n,a=r,o,s=Cl.CMD,c=e.match(sf);if(!c)return t;for(var l=0;l<c.length;l++){for(var u=c[l],d=u.charAt(0),f=void 0,p=u.match(cf)||[],m=p.length,h=0;h<m;h++)p[h]=parseFloat(p[h]);for(var g=0;g<m;){var _=void 0,v=void 0,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0,w=n,T=r,E=void 0,D=void 0;switch(d){case`l`:n+=p[g++],r+=p[g++],f=s.L,t.addData(f,n,r);break;case`L`:n=p[g++],r=p[g++],f=s.L,t.addData(f,n,r);break;case`m`:n+=p[g++],r+=p[g++],f=s.M,t.addData(f,n,r),i=n,a=r,d=`l`;break;case`M`:n=p[g++],r=p[g++],f=s.M,t.addData(f,n,r),i=n,a=r,d=`L`;break;case`h`:n+=p[g++],f=s.L,t.addData(f,n,r);break;case`H`:n=p[g++],f=s.L,t.addData(f,n,r);break;case`v`:r+=p[g++],f=s.L,t.addData(f,n,r);break;case`V`:r=p[g++],f=s.L,t.addData(f,n,r);break;case`C`:f=s.C,t.addData(f,p[g++],p[g++],p[g++],p[g++],p[g++],p[g++]),n=p[g-2],r=p[g-1];break;case`c`:f=s.C,t.addData(f,p[g++]+n,p[g++]+r,p[g++]+n,p[g++]+r,p[g++]+n,p[g++]+r),n+=p[g-2],r+=p[g-1];break;case`S`:_=n,v=r,E=t.len(),D=t.data,o===s.C&&(_+=n-D[E-4],v+=r-D[E-3]),f=s.C,w=p[g++],T=p[g++],n=p[g++],r=p[g++],t.addData(f,_,v,w,T,n,r);break;case`s`:_=n,v=r,E=t.len(),D=t.data,o===s.C&&(_+=n-D[E-4],v+=r-D[E-3]),f=s.C,w=n+p[g++],T=r+p[g++],n+=p[g++],r+=p[g++],t.addData(f,_,v,w,T,n,r);break;case`Q`:w=p[g++],T=p[g++],n=p[g++],r=p[g++],f=s.Q,t.addData(f,w,T,n,r);break;case`q`:w=p[g++]+n,T=p[g++]+r,n+=p[g++],r+=p[g++],f=s.Q,t.addData(f,w,T,n,r);break;case`T`:_=n,v=r,E=t.len(),D=t.data,o===s.Q&&(_+=n-D[E-4],v+=r-D[E-3]),n=p[g++],r=p[g++],f=s.Q,t.addData(f,_,v,n,r);break;case`t`:_=n,v=r,E=t.len(),D=t.data,o===s.Q&&(_+=n-D[E-4],v+=r-D[E-3]),n+=p[g++],r+=p[g++],f=s.Q,t.addData(f,_,v,n,r);break;case`A`:y=p[g++],b=p[g++],x=p[g++],S=p[g++],C=p[g++],w=n,T=r,n=p[g++],r=p[g++],f=s.A,of(w,T,n,r,S,C,y,b,x,f,t);break;case`a`:y=p[g++],b=p[g++],x=p[g++],S=p[g++],C=p[g++],w=n,T=r,n+=p[g++],r+=p[g++],f=s.A,of(w,T,n,r,S,C,y,b,x,f,t);break}}(d===`z`||d===`Z`)&&(f=s.Z,t.addData(f),n=i,r=a),o=f}return t.toStatic(),t}var uf=function(e){it(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.applyTransform=function(e){},t}(Jl);function df(e){return e.setData!=null}function ff(e,t){var n=lf(e),r=I({},t);return r.buildPath=function(e){var t=df(e);if(t&&e.canSave()){e.appendPath(n);var r=e.getContext();r&&e.rebuildPath(r,1)}else{var r=t?e.getContext():e;r&&n.rebuildPath(r,1)}},r.applyTransform=function(e){Zd(n,e),this.dirtyShape()},r}function pf(e,t){return new uf(ff(e,t))}function mf(e,t){var n=ff(e,t);return function(e){it(t,e);function t(t){var r=e.call(this,t)||this;return r.applyTransform=n.applyTransform,r.buildPath=n.buildPath,r}return t}(uf)}function hf(e,t){for(var n=[],r=e.length,i=0;i<r;i++){var a=e[i];n.push(a.getUpdatedPathProxy(!0))}var o=new Jl(t);return o.createPathProxy(),o.buildPath=function(e){if(df(e)){e.appendPath(n);var t=e.getContext();t&&e.rebuildPath(t,1)}},o}var gf=function(){function e(){this.cx=0,this.cy=0,this.r=0}return e}(),_f=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new gf},t.prototype.buildPath=function(e,t){e.moveTo(t.cx+t.r,t.cy),e.arc(t.cx,t.cy,t.r,0,Math.PI*2)},t}(Jl);_f.prototype.type=`circle`;var vf=function(){function e(){this.cx=0,this.cy=0,this.rx=0,this.ry=0}return e}(),yf=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new vf},t.prototype.buildPath=function(e,t){var n=.5522848,r=t.cx,i=t.cy,a=t.rx,o=t.ry,s=a*n,c=o*n;e.moveTo(r-a,i),e.bezierCurveTo(r-a,i-c,r-s,i-o,r,i-o),e.bezierCurveTo(r+s,i-o,r+a,i-c,r+a,i),e.bezierCurveTo(r+a,i+c,r+s,i+o,r,i+o),e.bezierCurveTo(r-s,i+o,r-a,i+c,r-a,i),e.closePath()},t}(Jl);yf.prototype.type=`ellipse`;var bf=Math.PI,xf=bf*2,Sf=Math.sin,Cf=Math.cos,wf=Math.acos,Tf=Math.atan2,Ef=Math.abs,Df=Math.sqrt,Of=Math.max,kf=Math.min,Af=1e-4;function jf(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=d*c-u*l;if(!(f*f<Af))return f=(u*(t-a)-d*(e-i))/f,[e+f*c,t+f*l]}function Mf(e,t,n,r,i,a,o){var s=e-n,c=t-r,l=(o?a:-a)/Df(s*s+c*c),u=l*c,d=-l*s,f=e+u,p=t+d,m=n+u,h=r+d,g=(f+m)/2,_=(p+h)/2,v=m-f,y=h-p,b=v*v+y*y,x=i-a,S=f*h-m*p,C=(y<0?-1:1)*Df(Of(0,x*x*b-S*S)),w=(S*y-v*C)/b,T=(-S*v-y*C)/b,E=(S*y+v*C)/b,D=(-S*v+y*C)/b,O=w-g,k=T-_,A=E-g,j=D-_;return O*O+k*k>A*A+j*j&&(w=E,T=D),{cx:w,cy:T,x0:-u,y0:-d,x1:w*(i/x-1),y1:T*(i/x-1)}}function Nf(e){var t;if(U(e)){var n=e.length;if(!n)return e;t=n===1?[e[0],e[0],0,0]:n===2?[e[0],e[0],e[1],e[1]]:n===3?e.concat(e[2]):e}else t=[e,e,e,e];return t}function Pf(e,t){var n,r=Of(t.r,0),i=Of(t.r0||0,0),a=r>0;if(!(!a&&!(i>0))){if(a||(r=i,i=0),i>r){var o=r;r=i,i=o}var s=t.startAngle,c=t.endAngle;if(!(isNaN(s)||isNaN(c))){var l=t.cx,u=t.cy,d=!!t.clockwise,f=Ef(c-s),p=f>xf&&f%xf;if(p>Af&&(f=p),!(r>Af))e.moveTo(l,u);else if(f>xf-Af)e.moveTo(l+r*Cf(s),u+r*Sf(s)),e.arc(l,u,r,s,c,!d),i>Af&&(e.moveTo(l+i*Cf(c),u+i*Sf(c)),e.arc(l,u,i,c,s,d));else{var m=void 0,h=void 0,g=void 0,_=void 0,v=void 0,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0,w=void 0,T=void 0,E=void 0,D=void 0,O=void 0,k=void 0,A=r*Cf(s),j=r*Sf(s),ee=i*Cf(c),te=i*Sf(c),ne=f>Af;if(ne){var re=t.cornerRadius;re&&(n=Nf(re),m=n[0],h=n[1],g=n[2],_=n[3]);var ie=Ef(r-i)/2;if(v=kf(ie,g),y=kf(ie,_),b=kf(ie,m),x=kf(ie,h),w=S=Of(v,y),T=C=Of(b,x),(S>Af||C>Af)&&(E=r*Cf(c),D=r*Sf(c),O=i*Cf(s),k=i*Sf(s),f<bf)){var ae=jf(A,j,O,k,E,D,ee,te);if(ae){var oe=A-ae[0],M=j-ae[1],se=E-ae[0],ce=D-ae[1],le=1/Sf(wf((oe*se+M*ce)/(Df(oe*oe+M*M)*Df(se*se+ce*ce)))/2),ue=Df(ae[0]*ae[0]+ae[1]*ae[1]);w=kf(S,(r-ue)/(le+1)),T=kf(C,(i-ue)/(le-1))}}}if(!ne)e.moveTo(l+A,u+j);else if(w>Af){var de=kf(g,w),fe=kf(_,w),N=Mf(O,k,A,j,r,de,d),pe=Mf(E,D,ee,te,r,fe,d);e.moveTo(l+N.cx+N.x0,u+N.cy+N.y0),w<S&&de===fe?e.arc(l+N.cx,u+N.cy,w,Tf(N.y0,N.x0),Tf(pe.y0,pe.x0),!d):(de>0&&e.arc(l+N.cx,u+N.cy,de,Tf(N.y0,N.x0),Tf(N.y1,N.x1),!d),e.arc(l,u,r,Tf(N.cy+N.y1,N.cx+N.x1),Tf(pe.cy+pe.y1,pe.cx+pe.x1),!d),fe>0&&e.arc(l+pe.cx,u+pe.cy,fe,Tf(pe.y1,pe.x1),Tf(pe.y0,pe.x0),!d))}else e.moveTo(l+A,u+j),e.arc(l,u,r,s,c,!d);if(!(i>Af)||!ne)e.lineTo(l+ee,u+te);else if(T>Af){var de=kf(m,T),fe=kf(h,T),N=Mf(ee,te,E,D,i,-fe,d),pe=Mf(A,j,O,k,i,-de,d);e.lineTo(l+N.cx+N.x0,u+N.cy+N.y0),T<C&&de===fe?e.arc(l+N.cx,u+N.cy,T,Tf(N.y0,N.x0),Tf(pe.y0,pe.x0),!d):(fe>0&&e.arc(l+N.cx,u+N.cy,fe,Tf(N.y0,N.x0),Tf(N.y1,N.x1),!d),e.arc(l,u,i,Tf(N.cy+N.y1,N.cx+N.x1),Tf(pe.cy+pe.y1,pe.cx+pe.x1),d),de>0&&e.arc(l+pe.cx,u+pe.cy,de,Tf(pe.y1,pe.x1),Tf(pe.y0,pe.x0),!d))}else e.lineTo(l+ee,u+te),e.arc(l,u,i,c,s,d)}e.closePath()}}}var Ff=function(){function e(){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 e}(),If=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new Ff},t.prototype.buildPath=function(e,t){Pf(e,t)},t.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},t}(Jl);If.prototype.type=`sector`;var Lf=function(){function e(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return e}(),Rf=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new Lf},t.prototype.buildPath=function(e,t){var n=t.cx,r=t.cy,i=Math.PI*2;e.moveTo(n+t.r,r),e.arc(n,r,t.r,0,i,!1),e.moveTo(n+t.r0,r),e.arc(n,r,t.r0,0,i,!0)},t}(Jl);Rf.prototype.type=`ring`;function zf(e,t,n,r){var i=[],a=[],o=[],s=[],c,l,u,d;if(r){u=[1/0,1/0],d=[-1/0,-1/0];for(var f=0,p=e.length;f<p;f++)bt(u,u,e[f]),xt(d,d,e[f]);bt(u,u,r[0]),xt(d,d,r[1])}for(var f=0,p=e.length;f<p;f++){var m=e[f];if(n)c=e[f?f-1:p-1],l=e[(f+1)%p];else if(f===0||f===p-1){i.push(st(e[f]));continue}else c=e[f-1],l=e[f+1];ut(a,l,c),pt(a,a,t);var h=ht(m,c),g=ht(m,l),_=h+g;_!==0&&(h/=_,g/=_),pt(o,a,-h),pt(s,a,g);var v=lt([],m,o),y=lt([],m,s);r&&(xt(v,v,u),bt(v,v,d),xt(y,y,u),bt(y,y,d)),i.push(v),i.push(y)}return n&&i.push(i.shift()),i}function Bf(e,t,n){var r=t.smooth,i=t.points;if(i&&i.length>=2){if(r){var a=zf(i,r,n,t.smoothConstraint);e.moveTo(i[0][0],i[0][1]);for(var o=i.length,s=0;s<(n?o:o-1);s++){var c=a[s*2],l=a[s*2+1],u=i[(s+1)%o];e.bezierCurveTo(c[0],c[1],l[0],l[1],u[0],u[1])}}else{e.moveTo(i[0][0],i[0][1]);for(var s=1,d=i.length;s<d;s++)e.lineTo(i[s][0],i[s][1])}n&&e.closePath()}}var Vf=function(){function e(){this.points=null,this.smooth=0,this.smoothConstraint=null}return e}(),Hf=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultShape=function(){return new Vf},t.prototype.buildPath=function(e,t){Bf(e,t,!0)},t}(Jl);Hf.prototype.type=`polygon`;var Uf=function(){function e(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null}return e}(),Wf=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultStyle=function(){return{stroke:`#000`,fill:null}},t.prototype.getDefaultShape=function(){return new Uf},t.prototype.buildPath=function(e,t){Bf(e,t,!1)},t}(Jl);Wf.prototype.type=`polyline`;var Gf={},Kf=function(){function e(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return e}(),qf=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultStyle=function(){return{stroke:`#000`,fill:null}},t.prototype.getDefaultShape=function(){return new Kf},t.prototype.buildPath=function(e,t){var n,r,i,a;if(this.subPixelOptimize){var o=ru(Gf,t,this.style);n=o.x1,r=o.y1,i=o.x2,a=o.y2}else n=t.x1,r=t.y1,i=t.x2,a=t.y2;var s=t.percent;s!==0&&(e.moveTo(n,r),s<1&&(i=n*(1-s)+i*s,a=r*(1-s)+a*s),e.lineTo(i,a))},t.prototype.pointAt=function(e){var t=this.shape;return[t.x1*(1-e)+t.x2*e,t.y1*(1-e)+t.y2*e]},t}(Jl);qf.prototype.type=`line`;var Jf=[],Yf=function(){function e(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1}return e}();function Xf(e,t,n){var r=e.cpx2,i=e.cpy2;return r!=null||i!=null?[(n?br:yr)(e.x1,e.cpx1,e.cpx2,e.x2,t),(n?br:yr)(e.y1,e.cpy1,e.cpy2,e.y2,t)]:[(n?Dr:Er)(e.x1,e.cpx1,e.x2,t),(n?Dr:Er)(e.y1,e.cpy1,e.y2,t)]}var Zf=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultStyle=function(){return{stroke:`#000`,fill:null}},t.prototype.getDefaultShape=function(){return new Yf},t.prototype.buildPath=function(e,t){var n=t.x1,r=t.y1,i=t.x2,a=t.y2,o=t.cpx1,s=t.cpy1,c=t.cpx2,l=t.cpy2,u=t.percent;u!==0&&(e.moveTo(n,r),c==null||l==null?(u<1&&(Ar(n,o,i,u,Jf),o=Jf[1],i=Jf[2],Ar(r,s,a,u,Jf),s=Jf[1],a=Jf[2]),e.quadraticCurveTo(o,s,i,a)):(u<1&&(Cr(n,o,c,i,u,Jf),o=Jf[1],c=Jf[2],i=Jf[3],Cr(r,s,l,a,u,Jf),s=Jf[1],l=Jf[2],a=Jf[3]),e.bezierCurveTo(o,s,c,l,i,a)))},t.prototype.pointAt=function(e){return Xf(this.shape,e,!1)},t.prototype.tangentAt=function(e){var t=Xf(this.shape,e,!0);return mt(t,t)},t}(Jl);Zf.prototype.type=`bezier-curve`;var Qf=function(){function e(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return e}(),$f=function(e){it(t,e);function t(t){return e.call(this,t)||this}return t.prototype.getDefaultStyle=function(){return{stroke:`#000`,fill:null}},t.prototype.getDefaultShape=function(){return new Qf},t.prototype.buildPath=function(e,t){var n=t.cx,r=t.cy,i=Math.max(t.r,0),a=t.startAngle,o=t.endAngle,s=t.clockwise,c=Math.cos(a),l=Math.sin(a);e.moveTo(c*i+n,l*i+r),e.arc(n,r,i,a,o,!s)},t}(Jl);$f.prototype.type=`arc`;var ep=function(e){it(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.type=`compound`,t}return t.prototype._updatePathDirty=function(){for(var e=this.shape.paths,t=this.shapeChanged(),n=0;n<e.length;n++)t||=e[n].shapeChanged();t&&this.dirtyShape()},t.prototype.beforeBrush=function(){this._updatePathDirty();for(var e=this.shape.paths||[],t=this.getGlobalScale(),n=0;n<e.length;n++)e[n].path||e[n].createPathProxy(),e[n].path.setScale(t[0],t[1],e[n].segmentIgnoreThreshold)},t.prototype.buildPath=function(e,t){for(var n=t.paths||[],r=0;r<n.length;r++)n[r].buildPath(e,n[r].shape,!0)},t.prototype.afterBrush=function(){for(var e=this.shape.paths||[],t=0;t<e.length;t++)e[t].pathUpdated()},t.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),Jl.prototype.getBoundingRect.call(this)},t}(Jl),tp=function(){function e(e){this.colorStops=e||[]}return e.prototype.addColorStop=function(e,t){this.colorStops.push({offset:e,color:t})},e}(),np=function(e){it(t,e);function t(t,n,r,i,a,o){var s=e.call(this,a)||this;return s.x=t??0,s.y=n??0,s.x2=r??1,s.y2=i??0,s.type=`linear`,s.global=o||!1,s}return t}(tp),rp=function(e){it(t,e);function t(t,n,r,i,a){var o=e.call(this,i)||this;return o.x=t??.5,o.y=n??.5,o.r=r??.5,o.type=`radial`,o.global=a||!1,o}return t}(tp),ip=Math.min,ap=Math.max,op=Math.abs,sp=[0,0],cp=[0,0],lp=Pn(),up=lp.minTv,dp=lp.maxTv,fp=function(){function e(e,t){this._corners=[],this._axes=[],this._origin=[0,0];for(var n=0;n<4;n++)this._corners[n]=new un;for(var n=0;n<2;n++)this._axes[n]=new un;e&&this.fromBoundingRect(e,t)}return e.prototype.fromBoundingRect=function(e,t){var n=this._corners,r=this._axes,i=e.x,a=e.y,o=i+e.width,s=a+e.height;if(n[0].set(i,a),n[1].set(o,a),n[2].set(o,s),n[3].set(i,s),t)for(var c=0;c<4;c++)n[c].transform(t);un.sub(r[0],n[1],n[0]),un.sub(r[1],n[3],n[0]),r[0].normalize(),r[1].normalize();for(var c=0;c<2;c++)this._origin[c]=r[c].dot(n[0])},e.prototype.intersect=function(e,t,n){var r=!0,i=!t;return t&&un.set(t,0,0),lp.reset(n,!i),!this._intersectCheckOneSide(this,e,i,1)&&(r=!1,i)||!this._intersectCheckOneSide(e,this,i,-1)&&(r=!1,i)||!i&&!lp.negativeSize&&un.copy(t,r?lp.useDir?lp.dirMinTv:up:dp),r},e.prototype._intersectCheckOneSide=function(e,t,n,r){for(var i=!0,a=0;a<2;a++){var o=e._axes[a];if(e._getProjMinMaxOnAxis(a,e._corners,sp),e._getProjMinMaxOnAxis(a,t._corners,cp),lp.negativeSize||sp[1]<cp[0]||sp[0]>cp[1]){if(i=!1,lp.negativeSize||n)return i;var s=op(cp[0]-sp[1]),c=op(sp[0]-cp[1]);ip(s,c)>dp.len()&&(s<c?un.scale(dp,o,-s*r):un.scale(dp,o,c*r))}else if(!n){var s=op(cp[0]-sp[1]),c=op(sp[0]-cp[1]);(lp.useDir||ip(s,c)<up.len())&&((s<c||!lp.bidirectional)&&(un.scale(up,o,s*r),lp.useDir&&lp.calcDirMTV()),(s>=c||!lp.bidirectional)&&(un.scale(up,o,-c*r),lp.useDir&&lp.calcDirMTV()))}}return i},e.prototype._getProjMinMaxOnAxis=function(e,t,n){for(var r=this._axes[e],i=this._origin,a=t[0].dot(r)+i[e],o=a,s=a,c=1;c<t.length;c++){var l=t[c].dot(r)+i[e];o=ip(l,o),s=ap(l,s)}n[0]=o+lp.touchThreshold,n[1]=s-lp.touchThreshold,lp.negativeSize=n[1]<n[0]},e}(),pp=[],mp=function(e){it(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.notClear=!0,t.incremental=1,t._displayables=[],t._temporaryDisplayables=[],t._cursor=0,t}return t.prototype.traverse=function(e,t){e.call(t,this)},t.prototype.useStyle=function(){this.style={}},t.prototype._useHoverStyle=function(){this.__hoverStyle=null},t.prototype.getCursor=function(){return this._cursor},t.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},t.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},t.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},t.prototype.addDisplayable=function(e,t){t?this._temporaryDisplayables.push(e):this._displayables.push(e),this.markRedraw()},t.prototype.addDisplayables=function(e,t){t||=!1;for(var n=0;n<e.length;n++)this.addDisplayable(e[n],t)},t.prototype.getDisplayables=function(){return this._displayables},t.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},t.prototype.eachPendingDisplayable=function(e){for(var t=this._cursor;t<this._displayables.length;t++)e&&e(this._displayables[t]);for(var t=0;t<this._temporaryDisplayables.length;t++)e&&e(this._temporaryDisplayables[t])},t.prototype.update=function(){this.updateTransform();for(var e=this._cursor;e<this._displayables.length;e++){var t=this._displayables[e];t.parent=this,t.update(),t.parent=null}for(var e=0;e<this._temporaryDisplayables.length;e++){var t=this._temporaryDisplayables[e];t.parent=this,t.update(),t.parent=null}},t.prototype.getBoundingRect=function(){if(!this._rect){for(var e=new Y(1/0,1/0,-1/0,-1/0),t=0;t<this._displayables.length;t++){var n=this._displayables[t],r=n.getBoundingRect().clone();n.needLocalTransform()&&r.applyTransform(n.getLocalTransform(pp)),e.union(r)}this._rect=e}return this._rect},t.prototype.contain=function(e,t){var n=this.transformCoordToLocal(e,t);if(this.getBoundingRect().contain(n[0],n[1])){for(var r=0;r<this._displayables.length;r++)if(this._displayables[r].contain(e,t))return!0}return!1},t}(Vc),hp=Z();function gp(e,t,n,r,i){var a;if(t&&t.ecModel){var o=t.ecModel.getUpdatePayload();a=o&&o.animation}var s=t&&t.isAnimationEnabled(),c=e===`update`;if(s){var l=void 0,u=void 0,d=void 0;return r?(l=q(r.duration,200),u=q(r.easing,`cubicOut`),d=0):(l=t.getShallow(c?`animationDurationUpdate`:`animationDuration`),u=t.getShallow(c?`animationEasingUpdate`:`animationEasing`),d=t.getShallow(c?`animationDelayUpdate`:`animationDelay`)),a&&(a.duration!=null&&(l=a.duration),a.easing!=null&&(u=a.easing),a.delay!=null&&(d=a.delay)),W(d)&&(d=d(n,i)),W(l)&&(l=l(n)),{duration:l||0,delay:d,easing:u}}else return null}function _p(e,t,n,r,i,a,o){var s=!1,c;W(i)?(o=a,a=i,i=null):K(i)&&(a=i.cb,o=i.during,s=i.isFrom,c=i.removeOpt,i=i.dataIndex);var l=e===`leave`;l||t.stopAnimation(`leave`);var u=gp(e,r,i,l?c||{}:null,r&&r.getAnimationDelayParams?r.getAnimationDelayParams(t,i):null);if(u&&u.duration>0){var d=u.duration,f=u.delay,p=u.easing,m={duration:d,delay:f||0,easing:p,done:a,force:!!a||!!o,setToFinal:!l,scope:e,during:o};s?t.animateFrom(n,m):t.animateTo(n,m)}else t.stopAnimation(),!s&&t.attr(n),o&&o(1),a&&a()}function vp(e,t,n,r,i,a){_p(`update`,e,t,n,r,i,a)}function yp(e,t,n,r,i,a){_p(`enter`,e,t,n,r,i,a)}function bp(e){if(!e.__zr)return!0;for(var t=0;t<e.animators.length;t++)if(e.animators[t].scope===`leave`)return!0;return!1}function xp(e,t,n,r,i,a){bp(e)||_p(`leave`,e,t,n,r,i,a)}function Sp(e,t,n,r){e.removeTextContent(),e.removeTextGuideLine(),xp(e,{style:{opacity:0}},t,n,r)}function Cp(e,t,n){function r(){e.parent&&e.parent.remove(e)}e.isGroup?e.traverse(function(e){e.isGroup||Sp(e,t,n,r)}):Sp(e,t,n,r)}function wp(e){hp(e).oldStyle=e.style}var Tp=e({Arc:()=>$f,BezierCurve:()=>Zf,BoundingRect:()=>Y,Circle:()=>_f,CompoundPath:()=>ep,Ellipse:()=>yf,Group:()=>Ya,HOVER_LAYER_FOR_INCREMENTAL:()=>2,HOVER_LAYER_FROM_THRESHOLD:()=>1,HOVER_LAYER_NO:()=>0,Image:()=>eu,IncrementalDisplayable:()=>mp,Line:()=>qf,LinearGradient:()=>np,OrientedBoundingRect:()=>fp,Path:()=>Jl,Point:()=>un,Polygon:()=>Hf,Polyline:()=>Wf,RadialGradient:()=>rp,Rect:()=>cu,Ring:()=>Rf,Sector:()=>If,Text:()=>pu,WH:()=>Op,XY:()=>Dp,applyTransform:()=>Up,calcZ2Range:()=>fm,clipPointsByRect:()=>Jp,clipRectByRect:()=>Yp,createIcon:()=>Xp,decomposeTransform:()=>gm,ensureCopyRect:()=>lm,ensureCopyTransform:()=>um,expandOrShrinkRect:()=>tm,extendPath:()=>jp,extendShape:()=>kp,getCurrentCanvasPainter:()=>vm,getShapeClass:()=>Np,getTransform:()=>Hp,groupTransition:()=>qp,initProps:()=>yp,isBoundingRectAxisAligned:()=>sm,isElementRemoved:()=>bp,lineLineIntersect:()=>Qp,linePolygonIntersect:()=>Zp,makeImage:()=>Fp,makePath:()=>Pp,mergePath:()=>Lp,payloadDisableAnimation:()=>hm,registerShape:()=>Mp,removeElement:()=>xp,removeElementWithFadeOut:()=>Cp,resizePath:()=>Rp,retrieveZInfo:()=>dm,setTooltipConfig:()=>im,subPixelOptimize:()=>Vp,subPixelOptimizeLine:()=>zp,subPixelOptimizeRect:()=>Bp,transformDirection:()=>Wp,traverseElements:()=>om,traverseUpdateZ:()=>pm,updateProps:()=>vp}),Ep={},Dp=[`x`,`y`],Op=[`width`,`height`];function kp(e){return Jl.extend(e)}var Ap=mf;function jp(e,t){return Ap(e,t)}function Mp(e,t){Ep[e]=t}function Np(e){if(Ep.hasOwnProperty(e))return Ep[e]}function Pp(e,t,n,r){var i=pf(e,t);return n&&(r===`center`&&(n=Ip(n,i.getBoundingRect())),Rp(i,n)),i}function Fp(e,t,n){var r=new eu({style:{image:e,x:t.x,y:t.y,width:t.width,height:t.height},onload:function(e){if(n===`center`){var i={width:e.width,height:e.height};r.setStyle(Ip(t,i))}}});return r}function Ip(e,t){var n=t.width/t.height,r=e.height*n,i;r<=e.width?i=e.height:(r=e.width,i=r/n);var a=e.x+e.width/2,o=e.y+e.height/2;return{x:a-r/2,y:o-i/2,width:r,height:i}}var Lp=hf;function Rp(e,t){if(e.applyTransform){var n=e.getBoundingRect().calculateTransform(t);e.applyTransform(n)}}function zp(e,t){return ru(e,e,{lineWidth:t}),e}function Bp(e,t){return iu(e,e,t),e}var Vp=au;function Hp(e,t){for(var n=nn([]);e&&e!==t;)an(n,e.getLocalTransform(),n),e=e.parent;return n}function Up(e,t,n){return t&&!we(t)&&(t=pa.getLocalTransform(t)),n&&(t=ln([],t)),yt([],e,t)}function Wp(e,t,n){var r=t[4]===0||t[5]===0||t[0]===0?1:co(2*t[4]/t[0]),i=t[4]===0||t[5]===0||t[2]===0?1:co(2*t[4]/t[2]),a=[e===`left`?-r:e===`right`?r:0,e===`top`?-i:e===`bottom`?i:0];return a=Up(a,t,n),co(a[0])>co(a[1])?a[0]>0?`right`:`left`:a[1]>0?`bottom`:`top`}function Gp(e){return!e.isGroup}function Kp(e){return e.shape!=null}function qp(e,t,n){if(!e||!t)return;function r(e){var t={};return e.traverse(function(e){Gp(e)&&e.anid&&(t[e.anid]=e)}),t}function i(e){var t={x:e.x,y:e.y,rotation:e.rotation};return Kp(e)&&(t.shape=P(e.shape)),t}var a=r(e);t.traverse(function(e){if(Gp(e)&&e.anid){var t=a[e.anid];if(t){var r=i(e);e.attr(i(t)),vp(e,r,n,Du(e).dataIndex)}}})}function Jp(e,t){return B(e,function(e){var n=e[0];n=so(n,t.x),n=oo(n,t.x+t.width);var r=e[1];return r=so(r,t.y),r=oo(r,t.y+t.height),[n,r]})}function Yp(e,t){var n=so(e.x,t.x),r=oo(e.x+e.width,t.x+t.width),i=so(e.y,t.y),a=oo(e.y+e.height,t.y+t.height);if(r>=n&&a>=i)return{x:n,y:i,width:r-n,height:a-i}}function Xp(e,t,n){var r=I({rectHover:!0},t),i=r.style={strokeNoScale:!0};if(n||={x:-1,y:-1,width:2,height:2},e)return e.indexOf(`image://`)===0?(i.image=e.slice(8),L(i,n),new eu(r)):Pp(e.replace(`path://`,``),r,n,`center`)}function Zp(e,t,n,r,i){for(var a=0,o=i[i.length-1];a<i.length;a++){var s=i[a];if(Qp(e,t,n,r,s[0],s[1],o[0],o[1]))return!0;o=s}}function Qp(e,t,n,r,i,a,o,s){var c=n-e,l=r-t,u=o-i,d=s-a,f=$p(u,d,c,l);if(em(f))return!1;var p=e-i,m=t-a,h=$p(p,m,c,l)/f;if(h<0||h>1)return!1;var g=$p(p,m,u,d)/f;return!(g<0||g>1)}function $p(e,t,n,r){return e*r-n*t}function em(e){return e<=1e-6&&e>=-1e-6}function tm(e,t,n,r,i){return t==null?e:(je(t)?nm[0]=nm[1]=nm[2]=nm[3]=t:(nm[0]=t[0],nm[1]=t[1],nm[2]=t[2],nm[3]=t[3]),r&&(nm[0]=so(0,nm[0]),nm[1]=so(0,nm[1]),nm[2]=so(0,nm[2]),nm[3]=so(0,nm[3])),n&&(nm[0]=-nm[0],nm[1]=-nm[1],nm[2]=-nm[2],nm[3]=-nm[3]),rm(e,nm,`x`,`width`,3,1,i&&i[0]||0),rm(e,nm,`y`,`height`,0,2,i&&i[1]||0),e)}var nm=[0,0,0,0];function rm(e,t,n,r,i,a,o){var s=t[a]+t[i],c=e[r];e[r]+=s,o=so(0,oo(o,c)),e[r]<o?(e[r]=o,e[n]+=t[i]>=0?-t[i]:t[a]>=0?c+t[a]:co(s)>1e-8?(c-o)*t[i]/s:0):e[n]-=t[i]}function im(e){var t=e.itemTooltipOption,n=e.componentModel,r=e.itemName,i=G(t)?{formatter:t}:t,a=n.mainType,o=n.componentIndex,s={componentType:a,name:r,$vars:[`name`]};s[a+`Index`]=o;var c=e.formatterParamsExtra;c&&z(Oe(c),function(e){et(s,e)||(s[e]=c[e],s.$vars.push(e))});var l=Du(e.el);l.componentMainType=a,l.componentIndex=o,l.tooltipConfig={name:r,option:L({content:r,encodeHTMLContent:!0,formatterParams:s},i)}}function am(e,t){var n;e.isGroup&&(n=t(e)),n||e.traverse(t)}function om(e,t){if(e)if(U(e))for(var n=0;n<e.length;n++)am(e[n],t);else am(e,t)}function sm(e){return!e||co(e[1])<cm&&co(e[2])<cm||co(e[0])<cm&&co(e[3])<cm}var cm=1e-5;function lm(e,t){return e?Y.copy(e,t):t.clone()}function um(e,t){return t?rn(e||tn(),t):void 0}function dm(e){return{z:e.get(`z`)||0,zlevel:e.get(`zlevel`)||0}}function fm(e){var t=-1/0,n=1/0;am(e,function(e){r(e),r(e.getTextContent()),r(e.getTextGuideLine())});function r(e){if(!(!e||e.isGroup)){var t=e.currentStates;if(t.length)for(var n=0;n<t.length;n++)i(e.states[t[n]]);i(e)}}function i(e){if(e){var r=e.z2;r>t&&(t=r),r<n&&(n=r)}}return n>t&&(n=t=0),{min:n,max:t}}function pm(e,t,n){mm(e,t,n,-1/0)}function mm(e,t,n,r){if(e.ignoreModelZ)return r;var i=e.getTextContent(),a=e.getTextGuideLine();if(e.isGroup)for(var o=e.childrenRef(),s=0;s<o.length;s++)r=so(mm(o[s],t,n,r),r);else e.z=t,e.zlevel=n,r=so(e.z2||0,r);if(i&&(i.z=t,i.zlevel=n,isFinite(r)&&(i.z2=r+2)),a){var c=e.textGuideLineConfig;a.z=t,a.zlevel=n,isFinite(r)&&(a.z2=r+(c&&c.showAbove?1:-1))}return r}function hm(e){return e.animation={duration:0},e}function gm(e,t){return t?rn(_m.transform,t):nn(_m.transform),_m.decomposeTransform(),_a(e,_m),e}var _m=new pa;_m.transform=tn();function vm(e){var t=e.getZr().painter;return t.getType()===`canvas`?t:null}Mp(`circle`,_f),Mp(`ellipse`,yf),Mp(`sector`,If),Mp(`ring`,Rf),Mp(`polygon`,Hf),Mp(`polyline`,Wf),Mp(`rect`,cu),Mp(`line`,qf),Mp(`bezierCurve`,Zf),Mp(`arc`,$f);var ym={};function bm(e,t){for(var n=0;n<Wu.length;n++){var r=Wu[n],i=t[r],a=e.ensureState(r);a.style=a.style||{},a.style.text=i}var o=e.currentStates.slice();e.clearStates(!0),e.setStyle({text:t.normal}),e.useStates(o,!0)}function xm(e,t,n){var r=e.labelFetcher,i=e.labelDataIndex,a=e.labelDimIndex,o=t.normal,s;r&&(s=r.getFormattedLabel(i,`normal`,null,a,o&&o.get(`formatter`),n==null?null:{interpolatedValue:n})),s??=W(e.defaultText)?e.defaultText(i,e,n):e.defaultText;for(var c={normal:s},l=0;l<Wu.length;l++){var u=Wu[l],d=t[u];c[u]=q(r?r.getFormattedLabel(i,u,null,a,d&&d.get(`formatter`)):null,s)}return c}function Sm(e,t,n,r){n||=ym;for(var i=e instanceof pu,a=!1,o=0;o<Gu.length;o++){var s=t[Gu[o]];if(s&&s.getShallow(`show`)){a=!0;break}}var c=i?e:e.getTextContent();if(a){i||(c||(c=new pu,e.setTextContent(c)),e.stateProxy&&(c.stateProxy=e.stateProxy));var l=xm(n,t),u=t.normal,d=!!u.getShallow(`show`),f=wm(u,r&&r.normal,n,!1,!i);f.text=l.normal,i||e.setTextConfig(Tm(u,n,!1));for(var o=0;o<Wu.length;o++){var p=Wu[o],s=t[p];if(s){var m=c.ensureState(p),h=!!q(s.getShallow(`show`),d);if(h!==d&&(m.ignore=!h),m.style=wm(s,r&&r[p],n,!0,!i),m.style.text=l[p],!i){var g=e.ensureState(p);g.textConfig=Tm(s,n,!0)}}}c.silent=!!u.getShallow(`silent`),c.style.x!=null&&(f.x=c.style.x),c.style.y!=null&&(f.y=c.style.y),c.ignore=!d,c.useStyle(f),c.dirty(),n.enableTextSetter&&(Nm(c).setLabelText=function(e){var r=xm(n,t,e);bm(c,r)})}else c&&(c.ignore=!0);e.dirty()}function Cm(e,t){t||=`label`;for(var n={normal:e.getModel(t)},r=0;r<Wu.length;r++){var i=Wu[r];n[i]=e.getModel([i,t])}return n}function wm(e,t,n,r,i){var a={};return Em(a,e,n,r,i),t&&I(a,t),a}function Tm(e,t,n){t||={};var r={},i,a=e.getShallow(`rotate`),o=q(e.getShallow(`distance`),n?null:5),s=e.getShallow(`offset`);return i=e.getShallow(`position`)||(n?null:`inside`),i===`outside`&&(i=t.defaultOutsidePosition||`top`),i!=null&&(r.position=i),s!=null&&(r.offset=s),a!=null&&(a*=Math.PI/180,r.rotation=a),o!=null&&(r.distance=o),r.outsideFill=e.get(`color`)===`inherit`?t.inheritColor||null:`auto`,t.autoOverflowArea!=null&&(r.autoOverflowArea=t.autoOverflowArea),t.layoutRect!=null&&(r.layoutRect=t.layoutRect),r}function Em(e,t,n,r,i){n||=ym;var a=t.ecModel,o=a&&a.option.textStyle,s=Dm(t),c;if(s){c={};var l=`richInheritPlainLabel`,u=q(t.get(l),a?a.get(l):void 0);for(var d in s)if(s.hasOwnProperty(d)){var f=t.getModel([`rich`,d]);jm(c[d]={},f,o,t,u,n,r,i,!1,!0)}}c&&(e.rich=c);var p=t.get(`overflow`);p&&(e.overflow=p);var m=t.get(`lineOverflow`);m&&(e.lineOverflow=m);var h=e,g=t.get(`minMargin`);if(g!=null)g=je(g)?g/2:0,h.margin=[g,g,g,g],h.__marginType=Pm.minMargin;else{var _=t.get(`textMargin`);_!=null&&(h.margin=Ve(_),h.__marginType=Pm.textMargin)}jm(e,t,o,null,null,n,r,i,!0,!1)}function Dm(e){for(var t;e&&e!==e.ecModel;){var n=(e.option||ym).rich;if(n){t||={};for(var r=Oe(n),i=0;i<r.length;i++){var a=r[i];t[a]=1}}e=e.parentModel}return t}var Om=[`fontStyle`,`fontWeight`,`fontSize`,`fontFamily`,`textShadowColor`,`textShadowBlur`,`textShadowOffsetX`,`textShadowOffsetY`],km=[`align`,`lineHeight`,`width`,`height`,`tag`,`verticalAlign`,`ellipsis`],Am=[`padding`,`borderWidth`,`borderRadius`,`borderDashOffset`,`backgroundColor`,`borderColor`,`shadowColor`,`shadowBlur`,`shadowOffsetX`,`shadowOffsetY`];function jm(e,t,n,r,i,a,o,s,c,l){n=!o&&n||ym;var u=a&&a.inheritColor,d=t.getShallow(`color`),f=t.getShallow(`textBorderColor`),p=q(t.getShallow(`opacity`),n.opacity);(d===`inherit`||d===`auto`)&&(d=u||null),(f===`inherit`||f===`auto`)&&(f=u||null),s||(d||=n.color,f||=n.textBorderColor),d!=null&&(e.fill=d),f!=null&&(e.stroke=f);var m=q(t.getShallow(`textBorderWidth`),n.textBorderWidth);m!=null&&(e.lineWidth=m);var h=q(t.getShallow(`textBorderType`),n.textBorderType);h!=null&&(e.lineDash=h);var g=q(t.getShallow(`textBorderDashOffset`),n.textBorderDashOffset);g!=null&&(e.lineDashOffset=g),!o&&p==null&&!l&&(p=a&&a.defaultOpacity),p!=null&&(e.opacity=p),!o&&!s&&e.fill==null&&a.inheritColor&&(e.fill=a.inheritColor);for(var _=0;_<Om.length;_++){var v=Om[_],y=i!==!1&&r?ze(t.getShallow(v),r.getShallow(v),n[v]):q(t.getShallow(v),n[v]);y!=null&&(e[v]=y)}for(var _=0;_<km.length;_++){var v=km[_],y=t.getShallow(v);y!=null&&(e[v]=y)}if(e.verticalAlign==null){var b=t.getShallow(`baseline`);b!=null&&(e.verticalAlign=b)}if(!c||!a.disableBox){for(var _=0;_<Am.length;_++){var v=Am[_],y=t.getShallow(v);y!=null&&(e[v]=y)}var x=t.getShallow(`borderType`);x!=null&&(e.borderDash=x),(e.backgroundColor===`auto`||e.backgroundColor===`inherit`)&&u&&(e.backgroundColor=u),(e.borderColor===`auto`||e.borderColor===`inherit`)&&u&&(e.borderColor=u)}}function Mm(e,t){var n=t&&t.getModel(`textStyle`);return Ue([e.fontStyle||n&&n.getShallow(`fontStyle`)||``,e.fontWeight||n&&n.getShallow(`fontWeight`)||``,(e.fontSize||n&&n.getShallow(`fontSize`)||12)+`px`,e.fontFamily||n&&n.getShallow(`fontFamily`)||`sans-serif`].join(` `))}var Nm=Z(),Pm={minMargin:1,textMargin:2},Fm=[`textStyle`,`color`],Im=[`fontStyle`,`fontWeight`,`fontSize`,`fontFamily`,`padding`,`lineHeight`,`rich`,`width`,`height`,`overflow`],Lm=new pu,Rm=function(){function e(){}return e.prototype.getTextColor=function(e){var t=this.ecModel;return this.getShallow(`color`)||(!e&&t?t.get(Fm):null)},e.prototype.getFont=function(){return Mm({fontStyle:this.getShallow(`fontStyle`),fontWeight:this.getShallow(`fontWeight`),fontSize:this.getShallow(`fontSize`),fontFamily:this.getShallow(`fontFamily`)},this.ecModel)},e.prototype.getTextRect=function(e){for(var t={text:e,verticalAlign:this.getShallow(`verticalAlign`)||this.getShallow(`baseline`)},n=0;n<Im.length;n++)t[Im[n]]=this.getShallow(Im[n]);return Lm.useStyle(t),Lm.update(),Lm.getBoundingRect()},e}(),zm=[[`lineWidth`,`width`],[`stroke`,`color`],[`opacity`],[`shadowBlur`],[`shadowOffsetX`],[`shadowOffsetY`],[`shadowColor`],[`lineDash`,`type`],[`lineDashOffset`,`dashOffset`],[`lineCap`,`cap`],[`lineJoin`,`join`],[`miterLimit`]],Bm=oc(zm),Vm=function(){function e(){}return e.prototype.getLineStyle=function(e){return Bm(this,e)},e}(),Hm=[[`fill`,`color`],[`stroke`,`borderColor`],[`lineWidth`,`borderWidth`],[`opacity`],[`shadowBlur`],[`shadowOffsetX`],[`shadowOffsetY`],[`shadowColor`],[`lineDash`,`borderType`],[`lineDashOffset`,`borderDashOffset`],[`lineCap`,`borderCap`],[`lineJoin`,`borderJoin`],[`miterLimit`,`borderMiterLimit`]],Um=oc(Hm),Wm=function(){function e(){}return e.prototype.getItemStyle=function(e,t){return Um(this,e,t)},e}(),Gm=function(){function e(e,t,n){this.parentModel=t,this.ecModel=n,this.option=e}return e.prototype.init=function(e,t,n){},e.prototype.mergeOption=function(e,t){F(this.option,e,!0)},e.prototype.get=function(e,t){return e==null?this.option:this._doGet(this.parsePath(e),!t&&this.parentModel)},e.prototype.getShallow=function(e,t){var n=this.option,r=n==null?n:n[e];if(r==null&&!t){var i=this.parentModel;i&&(r=i.getShallow(e))}return r},e.prototype.getModel=function(t,n){var r=t!=null,i=r?this.parsePath(t):null,a=r?this._doGet(i):this.option;return n||=this.parentModel&&this.parentModel.getModel(this.resolveParentPath(i)),new e(a,n,this.ecModel)},e.prototype.isEmpty=function(){return this.option==null},e.prototype.restoreData=function(){},e.prototype.clone=function(){var e=this.constructor;return new e(P(this.option))},e.prototype.parsePath=function(e){return typeof e==`string`?e.split(`.`):e},e.prototype.resolveParentPath=function(e){return e},e.prototype.isAnimationEnabled=function(){if(!j.node&&this.option){if(this.option.animation!=null)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},e.prototype._doGet=function(e,t){var n=this.option;if(!e)return n;for(var r=0;r<e.length&&!(e[r]&&(n=n&&typeof n==`object`?n[e[r]]:null,n==null));r++);return n==null&&t&&(n=t._doGet(this.resolveParentPath(e),t.parentModel)),n},e}();Qs(Gm),nc(Gm),Ce(Gm,Vm),Ce(Gm,Wm),Ce(Gm,cc),Ce(Gm,Rm);var Km=Math.round(Math.random()*10);function qm(e){return[e||``,Km++].join(`_`)}function Jm(e){var t={};e.registerSubTypeDefaulter=function(e,n){var r=Ys(e);t[r.main]=n},e.determineSubType=function(n,r){var i=r.type;if(!i){var a=Ys(n).main;e.hasSubTypes(n)&&t[a]&&(i=t[a](r))}return i}}function Ym(e,t){e.topologicalTravel=function(e,t,r,i){if(!e.length)return;var a=n(t),o=a.graph,s=a.noEntryList,c={};for(z(e,function(e){c[e]=!0});s.length;){var l=s.pop(),u=o[l],d=!!c[l];d&&(r.call(i,l,u.originalDeps.slice()),delete c[l]),z(u.successor,d?p:f)}z(c,function(){throw Error(``)});function f(e){o[e].entryCount--,o[e].entryCount===0&&s.push(e)}function p(e){c[e]=!0,f(e)}};function n(e){var n={},a=[];return z(e,function(o){var s=r(n,o),c=i(s.originalDeps=t(o),e);s.entryCount=c.length,s.entryCount===0&&a.push(o),z(c,function(e){R(s.predecessor,e)<0&&s.predecessor.push(e);var t=r(n,e);R(t.successor,e)<0&&t.successor.push(o)})}),{graph:n,noEntryList:a}}function r(e,t){return e[t]||(e[t]={predecessor:[],successor:[]}),e[t]}function i(e,t){var n=[];return z(e,function(e){R(t,e)>=0&&n.push(e)}),n}}function Xm(e,t){return F(F({},e,!0),t,!0)}var Zm={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:`. `}}}},Qm={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:``}}}},$m=`ZH`,eh=`EN`,th=eh,nh={},rh={},ih=j.domSupported?function(){return(document.documentElement.lang||navigator.language||navigator.browserLanguage||th).toUpperCase().indexOf($m)>-1?$m:th}():th;function ah(e,t){e=e.toUpperCase(),rh[e]=new Gm(t),nh[e]=t}function oh(e){if(G(e)){var t=nh[e.toUpperCase()]||{};return e===$m||e===eh?P(t):F(P(t),P(nh[th]),!1)}else return F(P(e),P(nh[th]),!1)}function sh(e){return rh[e]}function ch(){return rh[th]}ah(eh,Zm),ah($m,Qm);var lh=null;function uh(){return lh}function dh(e,t){var n=uh(),r=t.breakOption,i=t.breakParsed;return!i&&n&&(i=n.parseAxisBreakOption(r,e)),i}function fh(e){var t=e.brk;return t?t.breaks:[]}function ph(e){var t=e.brk;return t?t.hasBreaks():!1}var mh=1e3,hh=mh*60,gh=hh*60,_h=gh*24,vh=_h*365,yh={year:/({yyyy}|{yy})/,month:/({MMMM}|{MMM}|{MM}|{M})/,day:/({dd}|{d})/,hour:/({HH}|{H}|{hh}|{h})/,minute:/({mm}|{m})/,second:/({ss}|{s})/,millisecond:/({SSS}|{S})/},bh={year:`{yyyy}`,month:`{MMM}`,day:`{d}`,hour:`{HH}:{mm}`,minute:`{HH}:{mm}`,second:`{HH}:{mm}:{ss}`,millisecond:`{HH}:{mm}:{ss} {SSS}`},xh=`{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}`,Sh=`{yyyy}-{MM}-{dd}`,Ch={year:`{yyyy}`,month:`{yyyy}-{MM}`,day:Sh,hour:Sh+` `+bh.hour,minute:Sh+` `+bh.minute,second:Sh+` `+bh.second,millisecond:xh},wh=[`year`,`month`,`day`,`hour`,`minute`,`second`,`millisecond`],Th=[`year`,`half-year`,`quarter`,`month`,`week`,`half-week`,`day`,`half-day`,`quarter-day`,`hour`,`minute`,`second`,`millisecond`];function Eh(e){return!G(e)&&!W(e)?Dh(e):e}function Dh(e){e||={};var t={},n=!0;return z(wh,function(t){n&&=e[t]==null}),z(wh,function(r,i){var a=e[r];t[r]={};for(var o=null,s=i;s>=0;s--){var c=wh[s],l=K(a)&&!U(a)?a[c]:a,u=void 0;U(l)?(u=l.slice(),o=u[0]||``):G(l)?(o=l,u=[o]):(o==null?o=bh[r]:yh[c].test(o)||(o=t[c][c][0]+` `+o),u=[o],n&&(u[1]=`{primary|`+o+`}`)),t[r][c]=u}}),t}function Oh(e,t){return e+=``,`0000`.substr(0,t-e.length)+e}function kh(e){switch(e){case`half-year`:case`quarter`:return`month`;case`week`:case`half-week`:return`day`;case`half-day`:case`quarter-day`:return`hour`;default:return e}}function Ah(e){return e===kh(e)}function jh(e){switch(e){case`year`:case`month`:return`day`;case`millisecond`:return`millisecond`;default:return`second`}}function Mh(e,t,n,r){var i=Mo(e),a=i[Ih(n)](),o=i[Lh(n)]()+1,s=Math.floor((o-1)/3)+1,c=i[Rh(n)](),l=i[`get`+(n?`UTC`:``)+`Day`](),u=i[zh(n)](),d=(u-1)%12+1,f=i[Bh(n)](),p=i[Vh(n)](),m=i[Hh(n)](),h=u>=12?`pm`:`am`,g=h.toUpperCase(),_=(r instanceof Gm?r:sh(r||ih)||ch()).getModel(`time`),v=_.get(`month`),y=_.get(`monthAbbr`),b=_.get(`dayOfWeek`),x=_.get(`dayOfWeekAbbr`);return(t||``).replace(/{a}/g,h+``).replace(/{A}/g,g+``).replace(/{yyyy}/g,a+``).replace(/{yy}/g,Oh(a%100+``,2)).replace(/{Q}/g,s+``).replace(/{MMMM}/g,v[o-1]).replace(/{MMM}/g,y[o-1]).replace(/{MM}/g,Oh(o,2)).replace(/{M}/g,o+``).replace(/{dd}/g,Oh(c,2)).replace(/{d}/g,c+``).replace(/{eeee}/g,b[l]).replace(/{ee}/g,x[l]).replace(/{e}/g,l+``).replace(/{HH}/g,Oh(u,2)).replace(/{H}/g,u+``).replace(/{hh}/g,Oh(d+``,2)).replace(/{h}/g,d+``).replace(/{mm}/g,Oh(f,2)).replace(/{m}/g,f+``).replace(/{ss}/g,Oh(p,2)).replace(/{s}/g,p+``).replace(/{SSS}/g,Oh(m,3)).replace(/{S}/g,m+``)}function Nh(e,t,n,r,i){var a=null;if(G(n))a=n;else if(W(n)){var o={time:e.time,level:e.time?e.time.level:0},s=uh();s&&s.makeAxisLabelFormatterParamBreak(o,e.break),a=n(e.value,t,o)}else{var c=e.time;if(c){var l=n[c.lowerTimeUnit][c.upperTimeUnit];a=l[Math.min(c.level,l.length-1)]||``}else{var u=Ph(e.value,i);a=n[u][u][0]}}return Mh(new Date(e.value),a,i,r)}function Ph(e,t){var n=Mo(e),r=n[Lh(t)]()+1,i=n[Rh(t)](),a=n[zh(t)](),o=n[Bh(t)](),s=n[Vh(t)](),c=n[Hh(t)]()===0,l=c&&s===0,u=l&&o===0,d=u&&a===0,f=d&&i===1;return f&&r===1?`year`:f?`month`:d?`day`:u?`hour`:l?`minute`:c?`second`:`millisecond`}function Fh(e,t,n){switch(t){case`year`:e[Wh(n)](0);case`month`:e[Gh(n)](1);case`day`:e[Kh(n)](0);case`hour`:e[qh(n)](0);case`minute`:e[Jh(n)](0);case`second`:e[Yh(n)](0)}return e}function Ih(e){return e?`getUTCFullYear`:`getFullYear`}function Lh(e){return e?`getUTCMonth`:`getMonth`}function Rh(e){return e?`getUTCDate`:`getDate`}function zh(e){return e?`getUTCHours`:`getHours`}function Bh(e){return e?`getUTCMinutes`:`getMinutes`}function Vh(e){return e?`getUTCSeconds`:`getSeconds`}function Hh(e){return e?`getUTCMilliseconds`:`getMilliseconds`}function Uh(e){return e?`setUTCFullYear`:`setFullYear`}function Wh(e){return e?`setUTCMonth`:`setMonth`}function Gh(e){return e?`setUTCDate`:`setDate`}function Kh(e){return e?`setUTCHours`:`setHours`}function qh(e){return e?`setUTCMinutes`:`setMinutes`}function Jh(e){return e?`setUTCSeconds`:`setSeconds`}function Yh(e){return e?`setUTCMilliseconds`:`setMilliseconds`}function Xh(e){if(!Lo(e))return G(e)?e:`-`;var t=(e+``).split(`.`);return t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,`$1,`)+(t.length>1?`.`+t[1]:``)}function Zh(e,t){return e=(e||``).toLowerCase().replace(/-(.)/g,function(e,t){return t.toUpperCase()}),t&&e&&(e=e.charAt(0).toUpperCase()+e.slice(1)),e}var Qh=Ve;function $h(e,t,n){var r=`{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}`;function i(e){return e&&Ue(e)?e:`-`}function a(e){return Vo(e)}var o=t===`time`,s=e instanceof Date;if(o||s){var c=o?Mo(e):e;if(!isNaN(+c))return Mh(c,r,n);if(s)return`-`}if(t===`ordinal`)return Ae(e)?i(e):je(e)&&a(e)?e+``:`-`;var l=Io(e);return a(l)?Xh(l):Ae(e)?i(e):typeof e==`boolean`?e+``:`-`}var eg=[`a`,`b`,`c`,`d`,`e`,`f`,`g`],tg=function(e,t){return`{`+e+(t??``)+`}`};function ng(e,t,n){U(t)||(t=[t]);var r=t.length;if(!r)return``;for(var i=t[0].$vars||[],a=0;a<i.length;a++){var o=eg[a];e=e.replace(tg(o),tg(o,0))}for(var s=0;s<r;s++)for(var c=0;c<i.length;c++){var l=t[s][i[c]];e=e.replace(tg(eg[c],s),n?Rt(l):l)}return e}function rg(e,t){var n=G(e)?{color:e,extraCssText:t}:e||{},r=n.color,i=n.type;t=n.extraCssText;var a=n.renderMode||`html`;return r?a===`html`?i===`subItem`?`<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:`+Rt(r)+`;`+(t||``)+`"></span>`:`<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:`+Rt(r)+`;`+(t||``)+`"></span>`:{renderMode:a,content:`{`+(n.markerId||`markerX`)+`|} `,style:i===`subItem`?{width:4,height:4,borderRadius:2,backgroundColor:r}:{width:10,height:10,borderRadius:5,backgroundColor:r}}:``}function ig(e,t){return t||=`transparent`,G(e)?e:K(e)&&e.colorStops&&(e.colorStops[0]||{}).color||t}var ag={},og={},sg=function(){function e(){this._normalMasterList=[],this._nonSeriesBoxMasterList=[]}return e.prototype.create=function(e,t){this._nonSeriesBoxMasterList=n(ag,!0),this._normalMasterList=n(og,!1);function n(n,r){var i=[];return z(n,function(n,r){var a=n.create(e,t);i=i.concat(a||[])}),i}},e.prototype.update=function(e,t){z(this._normalMasterList,function(n){n.update&&n.update(e,t)})},e.prototype.getCoordinateSystems=function(){return this._normalMasterList.concat(this._nonSeriesBoxMasterList)},e.register=function(e,t){if(e===`matrix`||e===`calendar`){ag[e]=t;return}og[e]=t},e.get=function(e){return og[e]||ag[e]},e}();function cg(e){return!!ag[e]}var lg=J();function ug(e){var t=e.getShallow(`coord`,!0),n=1;if(t==null){var r=lg.get(e.type);r&&r.getCoord2&&(n=2,t=r.getCoord2(e))}return{coord:t,from:n}}function dg(e,t){var n=e.getShallow(`coordinateSystem`),r=e.getShallow(`coordinateSystemUsage`,!0),i=0;if(n){var a=e.mainType===`series`;r??=a?`data`:`box`,r===`data`?(i=1,a||(i=0)):r===`box`&&(i=2,!a&&!cg(n)&&(i=0))}return{coordSysType:n,kind:i}}function fg(e){var t=e.targetModel,n=e.coordSysType,r=e.coordSysProvider,i=e.isDefaultDataCoordSys;e.allowNotFound;var a=dg(t,!0),o=a.kind,s=a.coordSysType;if(i&&o!==1&&(o=1,s=n),o===0||s!==n)return 0;var c=r(n,t);return c?(o===1?t.coordinateSystem=c:t.boxCoordinateSystem=c,o):0}var pg=z,mg=[`left`,`right`,`top`,`bottom`,`width`,`height`],hg=[[`width`,`left`,`right`],[`height`,`top`,`bottom`]];function gg(e,t,n,r,i){var a=0,o=0;r??=1/0,i??=1/0;var s=0;t.eachChild(function(c,l){var u=c.getBoundingRect(),d=t.childAt(l+1),f=d&&d.getBoundingRect(),p,m;if(e===`horizontal`){var h=u.width+(f?-f.x+u.x:0);p=a+h,p>r||c.newline?(a=0,p=h,o+=s+n,s=u.height):s=Math.max(s,u.height)}else{var g=u.height+(f?-f.y+u.y:0);m=o+g,m>i||c.newline?(a+=s+n,o=0,m=g,s=u.width):s=Math.max(s,u.width)}c.newline||(c.x=a,c.y=o,c.markRedraw(),e===`horizontal`?a=p+n:o=m+n)})}var _g=gg;H(gg,`vertical`),H(gg,`horizontal`);function vg(e,t){return{left:e.getShallow(`left`,t),top:e.getShallow(`top`,t),right:e.getShallow(`right`,t),bottom:e.getShallow(`bottom`,t),width:e.getShallow(`width`,t),height:e.getShallow(`height`,t)}}function yg(e,t,n){n=Qh(n||0);var r=t.width,i=t.height,a=yo(e.left,r),o=yo(e.top,i),s=yo(e.right,r),c=yo(e.bottom,i),l=yo(e.width,r),u=yo(e.height,i),d=n[2]+n[0],f=n[1]+n[3],p=e.aspect;switch(isNaN(l)&&(l=r-s-f-a),isNaN(u)&&(u=i-c-d-o),p!=null&&(isNaN(l)&&isNaN(u)&&(p>r/i?l=r*.8:u=i*.8),isNaN(l)&&(l=p*u),isNaN(u)&&(u=l/p)),isNaN(a)&&(a=r-s-l-f),isNaN(o)&&(o=i-c-u-d),e.left||e.right){case`center`:a=r/2-l/2-n[3];break;case`right`:a=r-l-f;break}switch(e.top||e.bottom){case`middle`:case`center`:o=i/2-u/2-n[0];break;case`bottom`:o=i-u-d;break}a||=0,o||=0,isNaN(l)&&(l=r-f-a-(s||0)),isNaN(u)&&(u=i-d-o-(c||0));var m=new Y((t.x||0)+a+n[3],(t.y||0)+o+n[0],l,u);return m.margin=n,m}var bg={rect:1,point:2};function xg(e,t,n){var r,i,a,o=e.boxCoordinateSystem,s;if(o){var c=ug(e),l=c.coord,u=c.from;if(o.dataToLayout){a=bg.rect,s=u;var d=o.dataToLayout(l);r=d.contentRect||d.rect}else n&&n.enableLayoutOnlyByCenter&&o.dataToPoint&&(a=bg.point,s=u,i=o.dataToPoint(l))}return a??=bg.rect,a===bg.rect&&(r||={x:0,y:0,width:t.getWidth(),height:t.getHeight()},i=[r.x+r.width/2,r.y+r.height/2]),{type:a,refContainer:r,refPoint:i,boxCoordFrom:s}}function Sg(e,t,n,r,i,a){var o=!i||!i.hv||i.hv[0],s=!i||!i.hv||i.hv[1],c=i&&i.boundingMode||`all`;if(a||=e,a.x=e.x,a.y=e.y,!o&&!s)return!1;var l;if(c===`raw`)l=e.type===`group`?new Y(0,0,+t.width||0,+t.height||0):e.getBoundingRect();else if(l=e.getBoundingRect(),e.needLocalTransform()){var u=e.getLocalTransform();l=l.clone(),l.applyTransform(u)}var d=yg(L({width:l.width,height:l.height},t),n,r),f=o?d.x-l.x:0,p=s?d.y-l.y:0;return c===`raw`?(a.x=f,a.y=p):(a.x+=f,a.y+=p),a===e&&e.markRedraw(),!0}function Cg(e){var t=e.layoutMode||e.constructor.layoutMode;return K(t)?t:t?{type:t}:null}function wg(e,t,n){var r=n&&n.ignoreSize;!U(r)&&(r=[r,r]);var i=o(hg[0],0),a=o(hg[1],1);c(hg[0],e,i),c(hg[1],e,a);function o(n,i){var a={},o=0,c={},l=0,u=2;if(pg(n,function(t){c[t]=e[t]}),pg(n,function(e){et(t,e)&&(a[e]=c[e]=t[e]),s(a,e)&&o++,s(c,e)&&l++}),r[i])return s(t,n[1])?c[n[2]]=null:s(t,n[2])&&(c[n[1]]=null),c;if(l===u||!o)return c;if(o>=u)return a;for(var d=0;d<n.length;d++){var f=n[d];if(!et(a,f)&&et(e,f)){a[f]=e[f];break}}return a}function s(e,t){return e[t]!=null&&e[t]!==`auto`}function c(e,t,n){pg(e,function(e){t[e]=n[e]})}}function Tg(e){return Eg({},e)}function Eg(e,t){return t&&e&&pg(mg,function(n){et(t,n)&&(e[n]=t[n])}),e}var Dg=Z(),Og=function(e){k(t,e);function t(t,n,r){var i=e.call(this,t,n,r)||this;return i.uid=qm(`ec_cpt_model`),i}return t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n)},t.prototype.mergeDefaultAndTheme=function(e,t){var n=Cg(this),r=n?Tg(e):{};F(e,t.getTheme().get(this.mainType)),F(e,this.getDefaultOption()),n&&wg(e,r,n)},t.prototype.mergeOption=function(e,t){F(this.option,e,!0);var n=Cg(this);n&&wg(this.option,e,n)},t.prototype.optionUpdated=function(e,t){},t.prototype.getDefaultOption=function(){var e=this.constructor;if(!Zs(e))return e.defaultOption;var t=Dg(this);if(!t.defaultOption){for(var n=[],r=e;r;){var i=r.prototype.defaultOption;i&&n.push(i),r=r.superClass}for(var a={},o=n.length-1;o>=0;o--)a=F(a,n[o],!0);t.defaultOption=a}return t.defaultOption},t.prototype.getReferringComponents=function(e,t){var n=e+`Index`,r=e+`Id`;return Cs(this.ecModel,e,{index:this.get(n,!0),id:this.get(r,!0)},t)},t.prototype.getBoxLayoutParams=function(){return vg(this,!1)},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}(Gm);ec(Og,Gm),ac(Og),Jm(Og),Ym(Og,kg);function kg(e){var t=[];return z(Og.getClassesByMainType(e),function(e){t=t.concat(e.dependencies||e.prototype.dependencies||[])}),t=B(t,function(e){return Ys(e).main}),e!==`dataset`&&R(t,`dataset`)<=0&&t.unshift(`dataset`),t}var Q={color:{},darkColor:{},size:{}},Ag=Q.color={theme:[`#5070dd`,`#b6d634`,`#505372`,`#ff994d`,`#0ca8df`,`#ffd10a`,`#fb628b`,`#785db0`,`#3fbe95`],neutral00:`#fff`,neutral05:`#f4f7fd`,neutral10:`#e8ebf0`,neutral15:`#dbdee4`,neutral20:`#cfd2d7`,neutral25:`#c3c5cb`,neutral30:`#b7b9be`,neutral35:`#aaacb2`,neutral40:`#9ea0a5`,neutral45:`#929399`,neutral50:`#86878c`,neutral55:`#797b7f`,neutral60:`#6d6e73`,neutral65:`#616266`,neutral70:`#54555a`,neutral75:`#48494d`,neutral80:`#3c3c41`,neutral85:`#303034`,neutral90:`#232328`,neutral95:`#17171b`,neutral99:`#000`,accent05:`#eff1f9`,accent10:`#e0e4f2`,accent15:`#d0d6ec`,accent20:`#c0c9e6`,accent25:`#b1bbdf`,accent30:`#a1aed9`,accent35:`#91a0d3`,accent40:`#8292cc`,accent45:`#7285c6`,accent50:`#6578ba`,accent55:`#5c6da9`,accent60:`#536298`,accent65:`#4a5787`,accent70:`#404c76`,accent75:`#374165`,accent80:`#2e3654`,accent85:`#252b43`,accent90:`#1b2032`,accent95:`#121521`,transparent:`rgba(0,0,0,0)`,highlight:`rgba(255,231,130,0.8)`};for(var jg in I(Ag,{primary:Ag.neutral80,secondary:Ag.neutral70,tertiary:Ag.neutral60,quaternary:Ag.neutral50,disabled:Ag.neutral20,border:Ag.neutral30,borderTint:Ag.neutral20,borderShade:Ag.neutral40,background:Ag.neutral05,backgroundTint:`rgba(234,237,245,0.5)`,backgroundTransparent:`rgba(255,255,255,0)`,backgroundShade:Ag.neutral10,shadow:`rgba(0,0,0,0.2)`,shadowTint:`rgba(129,130,136,0.2)`,axisLine:Ag.neutral70,axisLineTint:Ag.neutral40,axisTick:Ag.neutral70,axisTickMinor:Ag.neutral60,axisLabel:Ag.neutral70,axisSplitLine:Ag.neutral15,axisMinorSplitLine:Ag.neutral05}),Ag)if(Ag.hasOwnProperty(jg)){var Mg=Ag[jg];jg===`theme`?Q.darkColor.theme=Ag.theme.slice():jg===`highlight`?Q.darkColor.highlight=`rgba(255,231,130,0.4)`:jg.indexOf(`accent`)===0?Q.darkColor[jg]=ri(Mg,null,function(e){return e*.5},function(e){return Math.min(1,1.3-e)}):Q.darkColor[jg]=ri(Mg,null,function(e){return e*.9},function(e){return 1-e**1.5})}Q.size={xxs:2,xs:5,s:10,m:15,l:20,xl:30,xxl:40,xxxl:50};var Ng=``;typeof navigator<`u`&&(Ng=navigator.platform||``);var Pg=`rgba(0, 0, 0, 0.2)`,Fg=Q.color.theme[0],Ig=ri(Fg,null,null,.9),Lg={darkMode:`auto`,colorBy:`series`,color:Q.color.theme,gradientColor:[Ig,Fg],aria:{decal:{decals:[{color:Pg,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:Pg,symbol:`circle`,dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:Pg,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:Pg,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:Pg,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:Pg,symbol:`triangle`,dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:Ng.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},Rg={Must:1,Might:2,Not:3},zg=Z();function Bg(e){zg(e).datasetMap=J()}function Vg(e,t,n){var r={},i=Hg(t);if(!i||!e)return r;var a=[],o=[],s=t.ecModel,c=zg(s).datasetMap,l=i.uid+`_`+n.seriesLayoutBy,u,d;e=e.slice(),z(e,function(t,n){var i=K(t)?t:e[n]={name:t};i.type===`ordinal`&&u==null&&(u=n,d=m(i)),r[i.name]=[]});var f=c.get(l)||c.set(l,{categoryWayDim:d,valueWayDim:0});z(e,function(e,t){var n=e.name,i=m(e);if(u==null){var s=f.valueWayDim;p(r[n],s,i),p(o,s,i),f.valueWayDim+=i}else if(u===t)p(r[n],0,i),p(a,0,i);else{var s=f.categoryWayDim;p(r[n],s,i),p(o,s,i),f.categoryWayDim+=i}});function p(e,t,n){for(var r=0;r<n;r++)e.push(t+r)}function m(e){var t=e.dimsDef;return t?t.length:1}return a.length&&(r.itemName=a),o.length&&(r.seriesName=o),r}function Hg(e){if(!e.get(`data`,!0))return Cs(e.ecModel,`dataset`,{index:e.get(`datasetIndex`,!0),id:e.get(`datasetId`,!0)},xs).models[0]}function Ug(e){return!e.get(`transform`,!0)&&!e.get(`fromTransformResult`,!0)?[]:Cs(e.ecModel,`dataset`,{index:e.get(`fromDatasetIndex`,!0),id:e.get(`fromDatasetId`,!0)},xs).models}function Wg(e,t){return Gg(e.data,e.sourceFormat,e.seriesLayoutBy,e.dimensionsDefine,e.startIndex,t)}function Gg(e,t,n,r,i,a){var o,s=5;if(Ne(e))return Rg.Not;var c,l;if(r){var u=r[a];K(u)?(c=u.name,l=u.type):G(u)&&(c=u)}if(l!=null)return l===`ordinal`?Rg.Must:Rg.Not;if(t===`arrayRows`){var d=e;if(n===`row`){for(var f=d[a],p=0;p<(f||[]).length&&p<s;p++)if((o=b(f[i+p]))!=null)return o}else for(var p=0;p<d.length&&p<s;p++){var m=d[i+p];if(m&&(o=b(m[a]))!=null)return o}}else if(t===`objectRows`){var h=e;if(!c)return Rg.Not;for(var p=0;p<h.length&&p<s;p++){var g=h[p];if(g&&(o=b(g[c]))!=null)return o}}else if(t===`keyedColumns`){var _=e;if(!c)return Rg.Not;var f=_[c];if(!f||Ne(f))return Rg.Not;for(var p=0;p<f.length&&p<s;p++)if((o=b(f[p]))!=null)return o}else if(t===`original`)for(var v=e,p=0;p<v.length&&p<s;p++){var g=v[p],y=es(g);if(!U(y))return Rg.Not;if((o=b(y[a]))!=null)return o}function b(e){var t=G(e);if(e!=null&&isFinite(Number(e))&&e!==``)return t?Rg.Might:Rg.Not;if(t&&e!==`-`)return Rg.Must}return Rg.Not}var Kg=J();function qg(e,t){He(Kg.get(e)==null&&t),Kg.set(e,t)}function Jg(e,t,n){var r=Kg.get(t);if(!r)return n;var i=r(e);return i?n.concat(i):n}var Yg=Z();Z();var Xg=function(){function e(){}return e.prototype.getColorFromPalette=function(e,t,n){var r=Zo(this.get(`color`,!0)),i=this.get(`colorLayer`,!0);return Qg(this,Yg,r,i,e,t,n)},e.prototype.clearColorPalette=function(){$g(this,Yg)},e}();function Zg(e,t){for(var n=e.length,r=0;r<n;r++)if(e[r].length>t)return e[r];return e[n-1]}function Qg(e,t,n,r,i,a,o){a||=e;var s=t(a),c=s.paletteIdx||0,l=s.paletteNameMap=s.paletteNameMap||{};if(l.hasOwnProperty(i))return l[i];var u=o==null||!r?n:Zg(r,o);if(u||=n,!(!u||!u.length)){var d=u[c];return i&&(l[i]=d),s.paletteIdx=(c+1)%u.length,d}}function $g(e,t){t(e).paletteIdx=0,t(e).paletteNameMap={}}var e_,t_,n_,r_=`\0_ec_inner`,i_=1,a_=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.init=function(e,t,n,r,i,a){r||={},this.option=null,this._theme=new Gm(r),this._locale=new Gm(i),this._optionManager=a},t.prototype.setOption=function(e,t,n){var r=u_(t);this._optionManager.setOption(e,n,r),this._resetOption(null,r)},t.prototype.resetOption=function(e,t){return this._resetOption(e,u_(t))},t.prototype._resetOption=function(e,t){var n=!1,r=this._optionManager;if(!e||e===`recreate`){var i=r.mountOption(e===`recreate`);!this.option||e===`recreate`?n_(this,i):(this.restoreData(),this._mergeOption(i,t)),n=!0}if((e===`timeline`||e===`media`)&&this.restoreData(),!e||e===`recreate`||e===`timeline`){var a=r.getTimelineOption(this);a&&(n=!0,this._mergeOption(a,t))}if(!e||e===`recreate`||e===`media`){var o=r.getMediaOption(this);o.length&&z(o,function(e){n=!0,this._mergeOption(e,t)},this)}return n},t.prototype.mergeOption=function(e){this._mergeOption(e,null)},t.prototype._mergeOption=function(e,t){var n=this.option,r=this._componentsMap,i=this._componentsCount,a=[],o=J(),s=t&&t.replaceMergeMainTypeMap;Bg(this),z(e,function(e,t){e!=null&&(Og.hasClass(t)?t&&(a.push(t),o.set(t,!0)):n[t]=n[t]==null?P(e):F(n[t],e,!0))}),s&&s.each(function(e,t){Og.hasClass(t)&&!o.get(t)&&(a.push(t),o.set(t,!0))}),Og.topologicalTravel(a,Og.getAllClassMainTypes(),c,this);function c(t){var a=Jg(this,t,Zo(e[t])),o=r.get(t),c=ns(o,a,o?s&&s.get(t)?`replaceMerge`:`normalMerge`:`replaceAll`);hs(c,t,Og),n[t]=null,r.set(t,null),i.set(t,0);var l=[],u=[],d=0,f;z(c,function(e,n){var r=e.existing,i=e.newOption;if(!i)r&&(r.mergeOption({},this),r.optionUpdated({},!1));else{var a=t===`series`,o=Og.getClass(t,e.keyInfo.subType,!a);if(!o)return;if(t===`tooltip`){if(f)return;f=!0}if(r&&r.constructor===o)r.name=e.keyInfo.name,r.mergeOption(i,this),r.optionUpdated(i,!1);else{var s=I({componentIndex:n},e.keyInfo);r=new o(i,this,this,s),I(r,s),e.brandNew&&(r.__requireNewView=!0),r.init(i,this,this),r.optionUpdated(null,!0)}}r?(l.push(r.option),u.push(r),d++):(l.push(void 0),u.push(void 0))},this),n[t]=l,r.set(t,u),i.set(t,d),t===`series`&&e_(this)}this._seriesIndices||e_(this)},t.prototype.getOption=function(){var e=P(this.option);return z(e,function(t,n){if(Og.hasClass(n)){for(var r=Zo(t),i=r.length,a=!1,o=i-1;o>=0;o--)r[o]&&!ps(r[o])?a=!0:(r[o]=null,!a&&i--);r.length=i,e[n]=r}}),delete e[r_],e},t.prototype.setTheme=function(e){this._theme=new Gm(e),this._resetOption(`recreate`,null)},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,t){var n=this._componentsMap.get(e);if(n){var r=n[t||0];if(r)return r;if(t==null){for(var i=0;i<n.length;i++)if(n[i])return n[i]}}},t.prototype.queryComponents=function(e){var t=e.mainType;if(!t)return[];var n=e.index,r=e.id,i=e.name,a=this._componentsMap.get(t);if(!a||!a.length)return[];var o;return n==null?o=r==null?i==null?Ee(a,function(e){return!!e}):c_(`name`,i,a):c_(`id`,r,a):(o=[],z(Zo(n),function(e){a[e]&&o.push(a[e])})),l_(o,e)},t.prototype.findComponents=function(e){var t=e.query,n=e.mainType,r=i(t);return a(l_(r?this.queryComponents(r):Ee(this._componentsMap.get(n),function(e){return!!e}),e));function i(e){var t=n+`Index`,r=n+`Id`,i=n+`Name`;return e&&(e[t]!=null||e[r]!=null||e[i]!=null)?{mainType:n,index:e[t],id:e[r],name:e[i]}:null}function a(t){return e.filter?Ee(t,e.filter):t}},t.prototype.eachComponent=function(e,t,n){var r=this._componentsMap;if(W(e)){var i=t,a=e;r.each(function(e,t){for(var n=0;e&&n<e.length;n++){var r=e[n];r&&a.call(i,t,r,r.componentIndex)}})}else for(var o=G(e)?r.get(e):K(e)?this.findComponents(e):null,s=0;o&&s<o.length;s++){var c=o[s];c&&t.call(n,c,c.componentIndex)}},t.prototype.getSeriesByName=function(e){var t=ds(e,null);return Ee(this._componentsMap.get(`series`),function(e){return!!e&&t!=null&&e.name===t})},t.prototype.getSeriesByIndex=function(e){return this._componentsMap.get(`series`)[e]},t.prototype.getSeriesByType=function(e){return Ee(this._componentsMap.get(`series`),function(t){return!!t&&t.subType===e})},t.prototype.getSeries=function(){return Ee(this._componentsMap.get(`series`),function(e){return!!e})},t.prototype.getSeriesCount=function(){return this._componentsCount.get(`series`)},t.prototype.eachSeries=function(e,t){t_(this),z(this._seriesIndices,function(n){var r=this._componentsMap.get(`series`)[n];e.call(t,r,n)},this)},t.prototype.eachRawSeries=function(e,t){z(this._componentsMap.get(`series`),function(n){n&&e.call(t,n,n.componentIndex)})},t.prototype.eachSeriesByType=function(e,t,n){t_(this),z(this._seriesIndices,function(r){var i=this._componentsMap.get(`series`)[r];i.subType===e&&t.call(n,i,r)},this)},t.prototype.eachRawSeriesByType=function(e,t,n){return z(this.getSeriesByType(e),t,n)},t.prototype.isSeriesFiltered=function(e){return t_(this),this._seriesIndicesMap.get(e.componentIndex)==null},t.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},t.prototype.filterSeries=function(e,t){t_(this);var n=[];z(this._seriesIndices,function(r){var i=this._componentsMap.get(`series`)[r];e.call(t,i,r)&&n.push(r)},this),this._seriesIndices=n,this._seriesIndicesMap=J(n)},t.prototype.restoreData=function(e){e_(this);var t=this._componentsMap,n=[];t.each(function(e,t){Og.hasClass(t)&&n.push(t)}),Og.topologicalTravel(n,Og.getAllClassMainTypes(),function(n){z(t.get(n),function(t){t&&(n!==`series`||!o_(t,e))&&t.restoreData()})})},t.internalField=function(){e_=function(e){var t=e._seriesIndices=[];z(e._componentsMap.get(`series`),function(e){e&&t.push(e.componentIndex)}),e._seriesIndicesMap=J(t)},t_=function(e){},n_=function(e,t){e.option={},e.option[r_]=i_,e._componentsMap=J({series:[]}),e._componentsCount=J();var n=t.aria;K(n)&&n.enabled==null&&(n.enabled=!0),s_(t,e._theme.option),F(t,Lg,!1),e._mergeOption(t,null)}}(),t}(Gm);function o_(e,t){if(t){var n=t.seriesIndex,r=t.seriesId,i=t.seriesName;return n!=null&&e.componentIndex!==n||r!=null&&e.id!==r||i!=null&&e.name!==i}}function s_(e,t){var n=e.color&&!e.colorLayer;z(t,function(t,r){r===`colorLayer`&&n||r===`color`&&e.color||Og.hasClass(r)||(typeof t==`object`?e[r]=e[r]?F(e[r],t,!1):P(t):e[r]??(e[r]=t))})}function c_(e,t,n){if(U(t)){var r=J();return z(t,function(e){e!=null&&ds(e,null)!=null&&r.set(e,!0)}),Ee(n,function(t){return t&&r.get(t[e])})}else{var i=ds(t,null);return Ee(n,function(t){return t&&i!=null&&t[e]===i})}}function l_(e,t){return t.hasOwnProperty(`subType`)?Ee(e,function(e){return e&&e.subType===t.subType}):e}function u_(e){var t=J();return e&&z(Zo(e.replaceMerge),function(e){t.set(e,!0)}),{replaceMergeMainTypeMap:t}}Ce(a_,Xg);var d_=/^(min|max)?(.+)$/,f_=function(){function e(e){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=e}return e.prototype.setOption=function(e,t,n){e&&(z(Zo(e.series),function(e){e&&e.data&&Ne(e.data)&&Ge(e.data)}),z(Zo(e.dataset),function(e){e&&e.source&&Ne(e.source)&&Ge(e.source)})),e=P(e);var r=this._optionBackup,i=p_(e,t,!r);this._newBaseOption=i.baseOption,r?(i.timelineOptions.length&&(r.timelineOptions=i.timelineOptions),i.mediaList.length&&(r.mediaList=i.mediaList),i.mediaDefault&&(r.mediaDefault=i.mediaDefault)):this._optionBackup=i},e.prototype.mountOption=function(e){var t=this._optionBackup;return this._timelineOptions=t.timelineOptions,this._mediaList=t.mediaList,this._mediaDefault=t.mediaDefault,this._currentMediaIndices=[],P(e?t.baseOption:this._newBaseOption)},e.prototype.getTimelineOption=function(e){var t,n=this._timelineOptions;if(n.length){var r=e.getComponent(`timeline`);r&&(t=P(n[r.getCurrentIndex()]))}return t},e.prototype.getMediaOption=function(e){var t=this._api.getWidth(),n=this._api.getHeight(),r=this._mediaList,i=this._mediaDefault,a=[],o=[];if(!r.length&&!i)return o;for(var s=0,c=r.length;s<c;s++)m_(r[s].query,t,n)&&a.push(s);return!a.length&&i&&(a=[-1]),a.length&&!g_(a,this._currentMediaIndices)&&(o=B(a,function(e){return P(e===-1?i.option:r[e].option)})),this._currentMediaIndices=a,o},e}();function p_(e,t,n){var r=[],i,a,o=e.baseOption,s=e.timeline,c=e.options,l=e.media,u=!!e.media,d=!!(c||s||o&&o.timeline);o?(a=o,a.timeline||=s):((d||u)&&(e.options=e.media=null),a=e),u&&U(l)&&z(l,function(e){e&&e.option&&(e.query?r.push(e):i||=e)}),f(a),z(c,function(e){return f(e)}),z(r,function(e){return f(e.option)});function f(e){z(t,function(t){t(e,n)})}return{baseOption:a,timelineOptions:c||[],mediaDefault:i,mediaList:r}}function m_(e,t,n){var r={width:t,height:n,aspectratio:t/n},i=!0;return z(e,function(e,t){var n=t.match(d_);if(!(!n||!n[1]||!n[2])){var a=n[1];h_(r[n[2].toLowerCase()],e,a)||(i=!1)}}),i}function h_(e,t,n){return n===`min`?e>=t:n===`max`?e<=t:e===t}function g_(e,t){return e.join(`,`)===t.join(`,`)}var __=z,v_=K,y_=[`areaStyle`,`lineStyle`,`nodeStyle`,`linkStyle`,`chordStyle`,`label`,`labelLine`];function b_(e){var t=e&&e.itemStyle;if(t)for(var n=0,r=y_.length;n<r;n++){var i=y_[n],a=t.normal,o=t.emphasis;a&&a[i]&&(e[i]=e[i]||{},e[i].normal?F(e[i].normal,a[i]):e[i].normal=a[i],a[i]=null),o&&o[i]&&(e[i]=e[i]||{},e[i].emphasis?F(e[i].emphasis,o[i]):e[i].emphasis=o[i],o[i]=null)}}function x_(e,t,n){if(e&&e[t]&&(e[t].normal||e[t].emphasis)){var r=e[t].normal,i=e[t].emphasis;r&&(n?(e[t].normal=e[t].emphasis=null,L(e[t],r)):e[t]=r),i&&(e.emphasis=e.emphasis||{},e.emphasis[t]=i,i.focus&&(e.emphasis.focus=i.focus),i.blurScope&&(e.emphasis.blurScope=i.blurScope))}}function S_(e){x_(e,`itemStyle`),x_(e,`lineStyle`),x_(e,`areaStyle`),x_(e,`label`),x_(e,`labelLine`),x_(e,`upperLabel`),x_(e,`edgeLabel`)}function C_(e,t){var n=v_(e)&&e[t],r=v_(n)&&n.textStyle;if(r)for(var i=0,a=$o.length;i<a;i++){var o=$o[i];r.hasOwnProperty(o)&&(n[o]=r[o])}}function w_(e){e&&(S_(e),C_(e,`label`),e.emphasis&&C_(e.emphasis,`label`))}function T_(e){if(v_(e)){b_(e),S_(e),C_(e,`label`),C_(e,`upperLabel`),C_(e,`edgeLabel`),e.emphasis&&(C_(e.emphasis,`label`),C_(e.emphasis,`upperLabel`),C_(e.emphasis,`edgeLabel`));var t=e.markPoint;t&&(b_(t),w_(t));var n=e.markLine;n&&(b_(n),w_(n));var r=e.markArea;r&&w_(r);var i=e.data;if(e.type===`graph`){i||=e.nodes;var a=e.links||e.edges;if(a&&!Ne(a))for(var o=0;o<a.length;o++)w_(a[o]);z(e.categories,function(e){S_(e)})}if(i&&!Ne(i))for(var o=0;o<i.length;o++)w_(i[o]);if(t=e.markPoint,t&&t.data)for(var s=t.data,o=0;o<s.length;o++)w_(s[o]);if(n=e.markLine,n&&n.data)for(var c=n.data,o=0;o<c.length;o++)U(c[o])?(w_(c[o][0]),w_(c[o][1])):w_(c[o]);e.type===`gauge`?(C_(e,`axisLabel`),C_(e,`title`),C_(e,`detail`)):e.type===`treemap`?(x_(e.breadcrumb,`itemStyle`),z(e.levels,function(e){S_(e)})):e.type===`tree`&&S_(e.leaves)}}function E_(e){return U(e)?e:e?[e]:[]}function D_(e){return(U(e)?e[0]:e)||{}}function O_(e,t){__(E_(e.series),function(e){v_(e)&&T_(e)});var n=[`xAxis`,`yAxis`,`radiusAxis`,`angleAxis`,`singleAxis`,`parallelAxis`,`radar`];t&&n.push(`valueAxis`,`categoryAxis`,`logAxis`,`timeAxis`),__(n,function(t){__(E_(e[t]),function(e){e&&(C_(e,`axisLabel`),C_(e.axisPointer,`label`))})}),__(E_(e.parallel),function(e){var t=e&&e.parallelAxisDefault;C_(t,`axisLabel`),C_(t&&t.axisPointer,`label`)}),__(E_(e.calendar),function(e){x_(e,`itemStyle`),C_(e,`dayLabel`),C_(e,`monthLabel`),C_(e,`yearLabel`)}),__(E_(e.radar),function(e){C_(e,`name`),e.name&&e.axisName==null&&(e.axisName=e.name,delete e.name),e.nameGap!=null&&e.axisNameGap==null&&(e.axisNameGap=e.nameGap,delete e.nameGap)}),__(E_(e.geo),function(e){v_(e)&&(w_(e),__(E_(e.regions),function(e){w_(e)}))}),__(E_(e.timeline),function(e){w_(e),x_(e,`label`),x_(e,`itemStyle`),x_(e,`controlStyle`,!0);var t=e.data;U(t)&&z(t,function(e){K(e)&&(x_(e,`label`),x_(e,`itemStyle`))})}),__(E_(e.toolbox),function(e){x_(e,`iconStyle`),__(e.feature,function(e){x_(e,`iconStyle`)})}),C_(D_(e.axisPointer),`label`),C_(D_(e.tooltip).axisPointer,`label`)}function k_(e,t){for(var n=t.split(`,`),r=e,i=0;i<n.length&&(r&&=r[n[i]],r!=null);i++);return r}function A_(e,t,n,r){for(var i=t.split(`,`),a=e,o,s=0;s<i.length-1;s++)o=i[s],a[o]??(a[o]={}),a=a[o];(r||a[i[s]]==null)&&(a[i[s]]=n)}function j_(e){e&&z(M_,function(t){t[0]in e&&!(t[1]in e)&&(e[t[1]]=e[t[0]])})}var M_=[[`x`,`left`],[`y`,`top`],[`x2`,`right`],[`y2`,`bottom`]],N_=[`grid`,`geo`,`parallel`,`legend`,`toolbox`,`title`,`visualMap`,`dataZoom`,`timeline`],P_=[[`borderRadius`,`barBorderRadius`],[`borderColor`,`barBorderColor`],[`borderWidth`,`barBorderWidth`]];function F_(e){var t=e&&e.itemStyle;if(t)for(var n=0;n<P_.length;n++){var r=P_[n][1],i=P_[n][0];t[r]!=null&&(t[i]=t[r])}}function I_(e){e&&e.alignTo===`edge`&&e.margin!=null&&e.edgeDistance==null&&(e.edgeDistance=e.margin)}function L_(e){e&&e.downplay&&!e.blur&&(e.blur=e.downplay)}function R_(e){e&&e.focusNodeAdjacency!=null&&(e.emphasis=e.emphasis||{},e.emphasis.focus??(e.emphasis.focus=`adjacency`))}function z_(e,t){if(e)for(var n=0;n<e.length;n++)t(e[n]),e[n]&&z_(e[n].children,t)}function B_(e,t){O_(e,t),e.series=Zo(e.series),z(e.series,function(e){if(K(e)){var t=e.type;if(t===`line`)e.clipOverflow!=null&&(e.clip=e.clipOverflow);else if(t===`pie`||t===`gauge`){e.clockWise!=null&&(e.clockwise=e.clockWise),I_(e.label);var n=e.data;if(n&&!Ne(n))for(var r=0;r<n.length;r++)I_(n[r]);e.hoverOffset!=null&&(e.emphasis=e.emphasis||{},(e.emphasis.scaleSize=null)&&(e.emphasis.scaleSize=e.hoverOffset))}else if(t===`gauge`){var i=k_(e,`pointer.color`);i!=null&&A_(e,`itemStyle.color`,i)}else if(t===`bar`){F_(e),F_(e.backgroundStyle),F_(e.emphasis);var n=e.data;if(n&&!Ne(n))for(var r=0;r<n.length;r++)typeof n[r]==`object`&&(F_(n[r]),F_(n[r]&&n[r].emphasis))}else if(t===`sunburst`){var a=e.highlightPolicy;a&&(e.emphasis=e.emphasis||{},e.emphasis.focus||(e.emphasis.focus=a)),L_(e),z_(e.data,L_)}else t===`graph`||t===`sankey`?R_(e):t===`map`&&(e.mapType&&!e.map&&(e.map=e.mapType),e.mapLocation&&L(e,e.mapLocation));e.hoverAnimation!=null&&(e.emphasis=e.emphasis||{},e.emphasis&&e.emphasis.scale==null&&(e.emphasis.scale=e.hoverAnimation)),j_(e)}}),e.dataRange&&(e.visualMap=e.dataRange),z(N_,function(t){var n=e[t];n&&(U(n)||(n=[n]),z(n,function(e){j_(e)}))})}var V_=Gs(H_);function H_(e){var t=J();e.eachSeries(function(e){var n=e.get(`stack`);if(n){var r=t.get(n)||t.set(n,[]),i=e.getData(),a={stackResultDimension:i.getCalculationInfo(`stackResultDimension`),stackedOverDimension:i.getCalculationInfo(`stackedOverDimension`),stackedDimension:i.getCalculationInfo(`stackedDimension`),stackedByDimension:i.getCalculationInfo(`stackedByDimension`),isStackedByIndex:i.getCalculationInfo(`isStackedByIndex`),data:i,seriesModel:e};if(!a.stackedDimension||!(a.isStackedByIndex||a.stackedByDimension))return;r.push(a)}}),t.each(function(e){e.length!==0&&((e[0].seriesModel.get(`stackOrder`)||`seriesAsc`)===`seriesDesc`&&e.reverse(),z(e,function(t,n){t.data.setCalculationInfo(`stackedOnSeries`,n>0?e[n-1].seriesModel:null)}),U_(e))})}function U_(e){z(e,function(t,n){var r=[],i=[NaN,NaN],a=[t.stackResultDimension,t.stackedOverDimension],o=t.data,s=t.isStackedByIndex,c=t.seriesModel.get(`stackStrategy`)||`samesign`;o.modify(a,function(a,l,u){var d=o.get(t.stackedDimension,u);if(isNaN(d))return i;var f,p;s?p=o.getRawIndex(u):f=o.get(t.stackedByDimension,u);for(var m=NaN,h=n-1;h>=0;h--){var g=e[h];if(s||(p=g.data.rawIndexOf(g.stackedByDimension,f)),p>=0){var _=g.data.getByRawIndex(g.stackResultDimension,p);if(c===`all`||c===`positive`&&_>0||c===`negative`&&_<0||c===`samesign`&&d>=0&&_>0||c===`samesign`&&d<=0&&_<0){d=Do(d,_),m=_;break}}}return r[0]=d,r[1]=m,r})})}var W_=function(){function e(e){this.data=e.data||(e.sourceFormat===`keyedColumns`?{}:[]),this.sourceFormat=e.sourceFormat||`unknown`,this.seriesLayoutBy=e.seriesLayoutBy||`column`,this.startIndex=e.startIndex||0,this.dimensionsDetectedCount=e.dimensionsDetectedCount,this.metaRawOption=e.metaRawOption;var t=this.dimensionsDefine=e.dimensionsDefine;if(t)for(var n=0;n<t.length;n++){var r=t[n];r.type==null&&Wg(this,n)===Rg.Must&&(r.type=`ordinal`)}}return e}();function G_(e){return e instanceof W_}function K_(e,t,n){n||=Y_(e);var r=t.seriesLayoutBy,i=X_(e,n,r,t.sourceHeader,t.dimensions);return new W_({data:e,sourceFormat:n,seriesLayoutBy:r,dimensionsDefine:i.dimensionsDefine,startIndex:i.startIndex,dimensionsDetectedCount:i.dimensionsDetectedCount,metaRawOption:P(t)})}function q_(e){return new W_({data:e,sourceFormat:Ne(e)?Pu:Au})}function J_(e){return new W_({data:e.data,sourceFormat:e.sourceFormat,seriesLayoutBy:e.seriesLayoutBy,dimensionsDefine:P(e.dimensionsDefine),startIndex:e.startIndex,dimensionsDetectedCount:e.dimensionsDetectedCount})}function Y_(e){var t=Fu;if(Ne(e))t=Pu;else if(U(e)){e.length===0&&(t=ju);for(var n=0,r=e.length;n<r;n++){var i=e[n];if(i!=null){if(U(i)||Ne(i)){t=ju;break}else if(K(i)){t=Mu;break}}}}else if(K(e)){for(var a in e)if(et(e,a)&&we(e[a])){t=Nu;break}}return t}function X_(e,t,n,r,i){var a,o;if(!e)return{dimensionsDefine:Q_(i),startIndex:o,dimensionsDetectedCount:a};if(t===`arrayRows`){var s=e;r===`auto`||r==null?$_(function(e){e!=null&&e!==`-`&&(G(e)?o??=1:o=0)},n,s,10):o=je(r)?r:+!!r,!i&&o===1&&(i=[],$_(function(e,t){i[t]=e==null?``:e+``},n,s,1/0)),a=i?i.length:n===`row`?s.length:s[0]?s[0].length:null}else if(t===`objectRows`)i||=Z_(e);else if(t===`keyedColumns`)i||(i=[],z(e,function(e,t){i.push(t)}));else if(t===`original`){var c=es(e[0]);a=U(c)&&c.length||1}return{startIndex:o,dimensionsDefine:Q_(i),dimensionsDetectedCount:a}}function Z_(e){for(var t=0,n;t<e.length&&!(n=e[t++]););if(n)return Oe(n)}function Q_(e){if(e){var t=J();return B(e,function(e,n){e=K(e)?e:{name:e};var r={name:e.name,displayName:e.displayName,type:e.type};if(r.name==null)return r;r.name+=``,r.displayName??=r.name;var i=t.get(r.name);return i?r.name+=`-`+ i.count++:t.set(r.name,{count:1}),r})}}function $_(e,t,n,r){if(t===`row`)for(var i=0;i<n.length&&i<r;i++)e(n[i]?n[i][0]:null,i);else for(var a=n[0]||[],i=0;i<a.length&&i<r;i++)e(a[i],i)}function ev(e){var t=e.sourceFormat;return t===`objectRows`||t===`keyedColumns`}var tv,nv,rv,iv,av,ov,sv=function(){function e(e,t){var n=G_(e)?e:q_(e);this._source=n;var r=this._data=n.data,i=n.sourceFormat;n.seriesLayoutBy,i===`typedArray`&&(this._offset=0,this._dimSize=t,this._data=r),ov(this,r,n)}return e.prototype.getSource=function(){return this._source},e.prototype.count=function(){return 0},e.prototype.getItem=function(e,t){},e.prototype.appendData=function(e){},e.prototype.clean=function(){},e.protoInitialize=function(){var t=e.prototype;t.pure=!1,t.persistent=!0}(),e.internalField=function(){var e;ov=function(e,i,a){var o=a.sourceFormat,s=a.seriesLayoutBy,c=a.startIndex,l=a.dimensionsDefine,u=av[vv(o,s)];I(e,u),o===`typedArray`?(e.getItem=t,e.count=r,e.fillStorage=n):(e.getItem=V(dv(o,s),null,i,c,l),e.count=V(mv(o,s),null,i,c,l))};var t=function(e,t){e-=this._offset,t||=[];for(var n=this._data,r=this._dimSize,i=r*e,a=0;a<r;a++)t[a]=n[i+a];return t},n=function(e,t,n,r){for(var i=this._data,a=this._dimSize,o=0;o<a;o++){for(var s=r[o],c=s[0]==null?1/0:s[0],l=s[1]==null?-1/0:s[1],u=t-e,d=n[o],f=0;f<u;f++){var p=i[f*a+o];d[e+f]=p,p<c&&(c=p),p>l&&(l=p)}s[0]=c,s[1]=l}},r=function(){return this._data?this._data.length/this._dimSize:0};av=(e={},e[ju+`_`+Iu]={pure:!0,appendData:i},e[ju+`_row`]={pure:!0,appendData:function(){throw Error(`Do not support appendData when set seriesLayoutBy: "row".`)}},e[Mu]={pure:!0,appendData:i},e[Nu]={pure:!0,appendData:function(e){var t=this._data;z(e,function(e,n){for(var r=t[n]||(t[n]=[]),i=0;i<(e||[]).length;i++)r.push(e[i])})}},e[Au]={appendData:i},e[Pu]={persistent:!1,pure:!0,appendData:function(e){this._data=e},clean:function(){this._offset+=this.count(),this._data=null}},e);function i(e){for(var t=0;t<e.length;t++)this._data.push(e[t])}}(),e}(),cv=function(e){U(e)||Ko(`series.data or dataset.source must be an array.`)};tv={},tv[ju+`_`+Iu]=cv,tv[ju+`_row`]=cv,tv[Mu]=cv,tv[Nu]=function(e,t){for(var n=0;n<t.length;n++)t[n].name??Ko(`dimension name must not be null/undefined.`)},tv[Au]=cv;var lv=function(e,t,n,r){return e[r]},uv=(nv={},nv[ju+`_`+Iu]=function(e,t,n,r){return e[r+t]},nv[ju+`_row`]=function(e,t,n,r,i){r+=t;for(var a=i||[],o=e,s=0;s<o.length;s++){var c=o[s];a[s]=c?c[r]:null}return a},nv[Mu]=lv,nv[Nu]=function(e,t,n,r,i){for(var a=i||[],o=0;o<n.length;o++){var s=n[o].name,c=s==null?null:e[s];a[o]=c?c[r]:null}return a},nv[Au]=lv,nv);function dv(e,t){return uv[vv(e,t)]}var fv=function(e,t,n){return e.length},pv=(rv={},rv[ju+`_`+Iu]=function(e,t,n){return Math.max(0,e.length-t)},rv[ju+`_row`]=function(e,t,n){var r=e[0];return r?Math.max(0,r.length-t):0},rv[Mu]=fv,rv[Nu]=function(e,t,n){var r=n[0].name,i=r==null?null:e[r];return i?i.length:0},rv[Au]=fv,rv);function mv(e,t){return pv[vv(e,t)]}var hv=function(e,t,n){return e[t]},gv=(iv={},iv[ju]=hv,iv[Mu]=function(e,t,n){return e[n]},iv[Nu]=hv,iv[Au]=function(e,t,n){var r=es(e);return r instanceof Array?r[t]:r},iv[Pu]=hv,iv);function _v(e){return gv[e]}function vv(e,t){return e===`arrayRows`?e+`_`+t:e}function yv(e,t,n){if(e){var r=e.getRawDataItem(t);if(r!=null){var i=e.getStore(),a=i.getSource().sourceFormat;if(n!=null){var o=e.getDimensionIndex(n),s=i.getDimensionProperty(o);return _v(a)(r,o,s)}else{var c=r;return a===`original`&&(c=es(r)),c}}}}var bv=/\{@(.+?)\}/g,xv=function(){function e(){}return e.prototype.getDataParams=function(e,t){var n=this.getData(t),r=this.getRawValue(e,t),i=n.getRawIndex(e),a=n.getName(e),o=n.getRawDataItem(e),s=n.getItemVisual(e,`style`),c=s&&s[n.getItemVisual(e,`drawType`)||`fill`],l=s&&s.stroke,u=this.mainType,d=u===`series`,f=n.userOutput&&n.userOutput.get();return{componentType:u,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:d?this.subType:null,seriesIndex:this.seriesIndex,seriesId:d?this.id:null,seriesName:d?this.name:null,name:a,dataIndex:i,data:o,dataType:t,value:r,color:c,borderColor:l,dimensionNames:f?f.fullDimensions:null,encode:f?f.encode:null,$vars:[`seriesName`,`name`,`value`]}},e.prototype.getFormattedLabel=function(e,t,n,r,i,a){t||=`normal`;var o=this.getData(n),s=this.getDataParams(e,n);if(a&&(s.value=a.interpolatedValue),r!=null&&U(s.value)&&(s.value=s.value[r]),i||=o.getItemModel(e).get(t===`normal`?[`label`,`formatter`]:[t,`label`,`formatter`]),W(i))return s.status=t,s.dimensionIndex=r,i(s);if(G(i))return ng(i,s).replace(bv,function(t,n){var r=n.length,i=n;i.charAt(0)===`[`&&i.charAt(r-1)===`]`&&(i=+i.slice(1,r-1));var s=yv(o,e,i);if(a&&U(a.interpolatedValue)){var c=o.getDimensionIndex(i);c>=0&&(s=a.interpolatedValue[c])}return s==null?``:s+``})},e.prototype.getRawValue=function(e,t){return yv(this.getData(t),e)},e.prototype.formatTooltip=function(e,t,n){},e}();function Sv(e){var t,n;return K(e)?e.type&&(n=e):t=e,{text:t,frag:n}}function Cv(e){return new wv(e)}var wv=function(){function e(e){e||={},this._reset=e.reset,this._plan=e.plan,this._count=e.count,this._onDirty=e.onDirty,this._dirty=!0}return e.prototype.perform=function(e){var t=this._upstream,n=e&&e.skip;if(this._dirty&&t){var r=this.context;r.data=r.outputData=t.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var i;this._plan&&!n&&(i=this._plan(this.context));var a=l(this._modBy),o=this._modDataCount||0,s=l(e&&e.modBy),c=e&&e.modDataCount||0;(a!==s||o!==c)&&(i=`reset`);function l(e){return!(e>=1)&&(e=1),e}var u;(this._dirty||i===`reset`)&&(this._dirty=!1,u=this._doReset(n)),this._modBy=s,this._modDataCount=c;var d=e&&e.step;if(t?this._dueEnd=t._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var f=this._dueIndex,p=Math.min(d==null?1/0:this._dueIndex+d,this._dueEnd);if(!n&&(u||f<p)){var m=this._progress;if(U(m))for(var h=0;h<m.length;h++)this._doProgress(m[h],f,p,s,c);else this._doProgress(m,f,p,s,c)}this._dueIndex=p;var g=this._settedOutputEnd==null?p:this._settedOutputEnd;this._outputDueEnd=g}else this._dueIndex=this._outputDueEnd=this._settedOutputEnd==null?this._dueEnd:this._settedOutputEnd;return this.unfinished()},e.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},e.prototype._doProgress=function(e,t,n,r,i){Tv.reset(t,n,r,i),this._callingProgress=e,this._callingProgress({start:t,end:n,count:n-t,next:Tv.next},this.context)},e.prototype._doReset=function(e){this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null;var t,n;!e&&this._reset&&(t=this._reset(this.context),t&&t.progress&&(n=t.forceFirstProgress,t=t.progress),U(t)&&!t.length&&(t=null)),this._progress=t,this._modBy=this._modDataCount=null;var r=this._downstream;return r&&r.dirty(),n},e.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},e.prototype.pipe=function(e){(this._downstream!==e||this._dirty)&&(this._downstream=e,e._upstream=this,e.dirty())},e.prototype.dispose=function(){this._disposed||=(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,!0)},e.prototype.getUpstream=function(){return this._upstream},e.prototype.getDownstream=function(){return this._downstream},e.prototype.setOutputEnd=function(e){this._outputDueEnd=this._settedOutputEnd=e},e}(),Tv=function(){var e,t,n,r,i,a={reset:function(c,l,u,d){t=c,e=l,n=u,r=d,i=Math.ceil(r/n),a.next=n>1&&r>0?s:o}};return a;function o(){return t<e?t++:null}function s(){var a=t%i*n+Math.ceil(t/i),o=t>=e?null:a<r?a:t;return t++,o}}();function Ev(e,t){var n=t&&t.type;return n===`ordinal`?e:(n===`time`&&!je(e)&&e!=null&&e!==`-`&&(e=+Mo(e)),e==null||e===``?NaN:Number(e))}J({number:function(e){return parseFloat(e)},time:function(e){return+Mo(e)},trim:function(e){return G(e)?Ue(e):e}});var Dv={lt:function(e,t){return e<t},lte:function(e,t){return e<=t},gt:function(e,t){return e>t},gte:function(e,t){return e>=t}};(function(){function e(e,t){je(t)||qo(``),this._opFn=Dv[e],this._rvalFloat=Io(t)}return e.prototype.evaluate=function(e){return je(e)?this._opFn(e,this._rvalFloat):this._opFn(Io(e),this._rvalFloat)},e})();var Ov=function(){function e(e,t){var n=e===`desc`;this._resultLT=n?1:-1,t??=n?`min`:`max`,this._incomparable=t===`min`?-1/0:1/0}return e.prototype.evaluate=function(e,t){var n=je(e)?e:Io(e),r=je(t)?t:Io(t),i=isNaN(n),a=isNaN(r);if(i&&(n=this._incomparable),a&&(r=this._incomparable),i&&a){var o=G(e),s=G(t);o&&(n=s?e:0),s&&(r=o?t:0)}return n<r?this._resultLT:n>r?-this._resultLT:0},e}();(function(){function e(e,t){this._rval=t,this._isEQ=e,this._rvalTypeof=typeof t,this._rvalFloat=Io(t)}return e.prototype.evaluate=function(e){var t=e===this._rval;if(!t){var n=typeof e;n!==this._rvalTypeof&&(n===`number`||this._rvalTypeof===`number`)&&(t=Io(e)===this._rvalFloat)}return this._isEQ?t:!t},e})();function kv(e){var t=``,n=-1/0,r=-1/0,i=1/0,a=1/0;return e&&(e.g!=null&&(t+=`G`+e.g,n=e.g),e.ge!=null&&(t+=`GE`+e.ge,r=e.ge),e.l!=null&&(t+=`L`+e.l,i=e.l),e.le!=null&&(t+=`LE`+e.le,a=e.le)),{key:t,g:n,ge:r,l:i,le:a}}function Av(e,t){return t>e.g&&t>=e.ge&&t<e.l&&t<=e.le}var jv=function(){function e(){}return e.prototype.getRawData=function(){throw Error(`not supported`)},e.prototype.getRawDataItem=function(e){throw Error(`not supported`)},e.prototype.cloneRawData=function(){},e.prototype.getDimensionInfo=function(e){},e.prototype.cloneAllDimensionInfo=function(){},e.prototype.count=function(){},e.prototype.retrieveValue=function(e,t){},e.prototype.retrieveValueFromItem=function(e,t){},e.prototype.convertValue=function(e,t){return Ev(e,t)},e}();function Mv(e,t){var n=new jv,r=e.data,i=n.sourceFormat=e.sourceFormat,a=e.startIndex;e.seriesLayoutBy!==`column`&&qo(``);var o=[],s={},c=e.dimensionsDefine;if(c)z(c,function(e,t){var n=e.name,r={index:t,name:n,displayName:e.displayName};o.push(r),n!=null&&(et(s,n)&&qo(``),s[n]=r)});else for(var l=0;l<e.dimensionsDetectedCount;l++)o.push({index:l});var u=dv(i,Iu);t.__isBuiltIn&&(n.getRawDataItem=function(e){return u(r,a,o,e)},n.getRawData=V(Nv,null,e)),n.cloneRawData=V(Pv,null,e),n.count=V(mv(i,Iu),null,r,a,o);var d=_v(i);n.retrieveValue=function(e,t){return f(u(r,a,o,e),t)};var f=n.retrieveValueFromItem=function(e,t){if(e!=null){var n=o[t];if(n)return d(e,t,n.name)}};return n.getDimensionInfo=V(Fv,null,o,s),n.cloneAllDimensionInfo=V(Iv,null,o),n}function Nv(e){var t=e.sourceFormat;return Vv(t)||qo(``),e.data}function Pv(e){var t=e.sourceFormat,n=e.data;if(Vv(t)||qo(``),t===`arrayRows`){for(var r=[],i=0,a=n.length;i<a;i++)r.push(n[i].slice());return r}else if(t===`objectRows`){for(var r=[],i=0,a=n.length;i<a;i++)r.push(I({},n[i]));return r}}function Fv(e,t,n){if(n!=null){if(je(n)||!isNaN(n)&&!et(t,n))return e[n];if(et(t,n))return t[n]}}function Iv(e){return P(e)}var Lv=J();function Rv(e){e=P(e);var t=e.type,n=``;t||qo(n);var r=t.split(`:`);r.length!==2&&qo(n);var i=!1;r[0]===`echarts`&&(t=r[1],i=!0),e.__isBuiltIn=i,Lv.set(t,e)}function zv(e,t,n){var r=Zo(e),i=r.length;i||qo(``);for(var a=0,o=i;a<o;a++){var s=r[a];t=Bv(s,t,n,i===1?null:a),a!==o-1&&(t.length=Math.max(t.length,1))}return t}function Bv(e,t,n,r){var i=``;t.length||qo(i),K(e)||qo(i);var a=e.type,o=Lv.get(a);o||qo(i);var s=B(t,function(e){return Mv(e,o)});return B(Zo(o.transform({upstream:s[0],upstreamList:s,config:P(e.config)})),function(e,n){var r=``;K(e)||qo(r),e.data||qo(r),Vv(Y_(e.data))||qo(r);var i,a=t[0];if(a&&n===0&&!e.dimensions){var o=a.startIndex;o&&(e.data=a.data.slice(0,o).concat(e.data)),i={seriesLayoutBy:Iu,sourceHeader:o,dimensions:a.metaRawOption.dimensions}}else i={seriesLayoutBy:Iu,sourceHeader:0,dimensions:e.dimensions};return K_(e.data,i,null)})}function Vv(e){return e===`arrayRows`||e===`objectRows`}var Hv=typeof Uint32Array>`u`?Array:Uint32Array,Uv=typeof Uint16Array>`u`?Array:Uint16Array,Wv=typeof Int32Array>`u`?Array:Int32Array,Gv=typeof Float64Array>`u`?Array:Float64Array,Kv={float:Gv,int:Wv,ordinal:Array,number:Array,time:Gv},qv;function Jv(e){return e>65535?Hv:Uv}function Yv(e){var t=e.constructor;return t===Array?e.slice():new t(e)}function Xv(e,t,n,r,i){var a=Kv[n||`float`];if(i){var o=e[t],s=o&&o.length;if(s!==r){for(var c=new a(r),l=0;l<s;l++)c[l]=o[l];e[t]=c}}else e[t]=new a(r)}var Zv=function(){function e(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=J()}return e.prototype.initData=function(e,t,n){this._provider=e,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var r=e.getSource(),i=this.defaultDimValueGetter=qv[r.sourceFormat];this._dimValueGetter=n||i,this._rawExtent=[],ev(r),this._dimensions=B(t,function(e){return{type:e.type,property:e.property}}),this._initDataFromProvider(0,e.count())},e.prototype.getProvider=function(){return this._provider},e.prototype.getSource=function(){return this._provider.getSource()},e.prototype.ensureCalculationDimension=function(e,t){var n=this._calcDimNameToIdx,r=this._dimensions,i=n.get(e);if(i!=null){if(r[i].type===t)return i}else i=r.length;return r[i]={type:t},n.set(e,i),this._chunks[i]=new Kv[t||`float`](this._rawCount),this._rawExtent[i]=ks(),i},e.prototype.collectOrdinalMeta=function(e,t){var n=this._chunks[e],r=this._dimensions[e],i=this._rawExtent,a=r.ordinalOffset||0,o=n.length;a===0&&(i[e]=ks());for(var s=i[e],c=a;c<o;c++){var l=n[c]=t.parseAndCollect(n[c]);isNaN(l)||(s[0]=Math.min(l,s[0]),s[1]=Math.max(l,s[1]))}r.ordinalMeta=t,r.ordinalOffset=o,r.type=`ordinal`},e.prototype.getOrdinalMeta=function(e){return this._dimensions[e].ordinalMeta},e.prototype.getDimensionProperty=function(e){var t=this._dimensions[e];return t&&t.property},e.prototype.appendData=function(e){var t=this._provider,n=this.count();t.appendData(e);var r=t.count();return t.persistent||(r+=n),n<r&&this._initDataFromProvider(n,r,!0),[n,r]},e.prototype.appendValues=function(e,t){for(var n=this._chunks,r=this._dimensions,i=r.length,a=this._rawExtent,o=this.count(),s=o+Math.max(e.length,t||0),c=0;c<i;c++){var l=r[c];Xv(n,c,l.type,s,!0)}for(var u=[],d=o;d<s;d++)for(var f=d-o,p=0;p<i;p++){var l=r[p],m=qv.arrayRows.call(this,e[f]||u,l.property,f,p);n[p][d]=m;var h=a[p];m<h[0]&&(h[0]=m),m>h[1]&&(h[1]=m)}return this._rawCount=this._count=s,{start:o,end:s}},e.prototype._initDataFromProvider=function(e,t,n){for(var r=this._provider,i=this._chunks,a=this._dimensions,o=a.length,s=this._rawExtent,c=B(a,function(e){return e.property}),l=0;l<o;l++){var u=a[l];s[l]||(s[l]=ks()),Xv(i,l,u.type,t,n)}if(r.fillStorage)r.fillStorage(e,t,i,s);else for(var d=[],f=e;f<t;f++){d=r.getItem(f,d);for(var p=0;p<o;p++){var m=i[p],h=this._dimValueGetter(d,c[p],f,p);m[f]=h;var g=s[p];h<g[0]&&(g[0]=h),h>g[1]&&(g[1]=h)}}!r.persistent&&r.clean&&r.clean(),this._rawCount=this._count=t,this._extent=[]},e.prototype.count=function(){return this._count},e.prototype.get=function(e,t){if(!(t>=0&&t<this._count))return NaN;var n=this._chunks[e];return n?n[this.getRawIndex(t)]:NaN},e.prototype.getValues=function(e,t){var n=[],r=[];if(t==null){t=e,e=[];for(var i=0;i<this._dimensions.length;i++)r.push(i)}else r=e;for(var i=0,a=r.length;i<a;i++)n.push(this.get(r[i],t));return n},e.prototype.getByRawIndex=function(e,t){if(!(t>=0&&t<this._rawCount))return NaN;var n=this._chunks[e];return n?n[t]:NaN},e.prototype.getSum=function(e){var t=this._chunks[e],n=0;if(t)for(var r=0,i=this.count();r<i;r++){var a=this.get(e,r);isNaN(a)||(n+=a)}return n},e.prototype.getMedian=function(e){var t=[];this.each([e],function(e){isNaN(e)||t.push(e)}),Co(t);var n=this.count();return n===0?0:n%2==1?t[(n-1)/2]:(t[n/2]+t[n/2-1])/2},e.prototype.indexOfRawIndex=function(e){if(e>=this._rawCount||e<0)return-1;if(!this._indices)return e;var t=this._indices,n=t[e];if(n!=null&&n<this._count&&n===e)return e;for(var r=0,i=this._count-1;r<=i;){var a=(r+i)/2|0;if(t[a]<e)r=a+1;else if(t[a]>e)i=a-1;else return a}return-1},e.prototype.getIndices=function(){var e,t=this._indices;if(t){var n=t.constructor,r=this._count;if(n===Array){e=new n(r);for(var i=0;i<r;i++)e[i]=t[i]}else e=new n(t.buffer,0,r)}else{var n=Jv(this._rawCount);e=new n(this.count());for(var i=0;i<e.length;i++)e[i]=i}return e},e.prototype.filter=function(e,t){if(!this._count)return this;for(var n=this.clone(),r=n.count(),i=new(Jv(n._rawCount))(r),a=[],o=e.length,s=0,c=e[0],l=n._chunks,u=0;u<r;u++){var d=void 0,f=n.getRawIndex(u);if(o===0)d=t(u);else if(o===1){var p=l[c][f];d=t(p,u)}else{for(var m=0;m<o;m++)a[m]=l[e[m]][f];a[m]=u,d=t.apply(null,a)}d&&(i[s++]=f)}return s<r&&(n._indices=i),n._count=s,n._extent=[],n._updateGetRawIdx(),n},e.prototype.selectRange=function(e){var t=this.clone(),n=t._count;if(!n)return this;var r=Oe(e),i=r.length;if(!i)return this;var a=t.count(),o=new(Jv(t._rawCount))(a),s=0,c=r[0],l=e[c][0],u=e[c][1],d=t._chunks,f=!1;if(!t._indices){var p=0;if(i===1){for(var m=d[r[0]],h=0;h<n;h++){var g=m[h];(g>=l&&g<=u||isNaN(g))&&(o[s++]=p),p++}f=!0}else if(i===2){for(var m=d[r[0]],_=d[r[1]],v=e[r[1]][0],y=e[r[1]][1],h=0;h<n;h++){var g=m[h],b=_[h];(g>=l&&g<=u||isNaN(g))&&(b>=v&&b<=y||isNaN(b))&&(o[s++]=p),p++}f=!0}}if(!f)if(i===1)for(var h=0;h<a;h++){var x=t.getRawIndex(h),g=d[r[0]][x];(g>=l&&g<=u||isNaN(g))&&(o[s++]=x)}else for(var h=0;h<a;h++){for(var S=!0,x=t.getRawIndex(h),C=0;C<i;C++){var w=r[C],g=d[w][x];(g<e[w][0]||g>e[w][1])&&(S=!1)}S&&(o[s++]=t.getRawIndex(h))}return s<a&&(t._indices=o),t._count=s,t._extent=[],t._updateGetRawIdx(),t},e.prototype.map=function(e,t){var n=this.clone(e);return this._updateDims(n,e,t),n},e.prototype.modify=function(e,t){this._updateDims(this,e,t)},e.prototype._updateDims=function(e,t,n){for(var r=e._chunks,i=[],a=t.length,o=e.count(),s=[],c=e._rawExtent,l=0;l<t.length;l++)c[t[l]]=ks();for(var u=0;u<o;u++){for(var d=e.getRawIndex(u),f=0;f<a;f++)s[f]=r[t[f]][d];s[a]=u;var p=n&&n.apply(null,s);if(p!=null){typeof p!=`object`&&(i[0]=p,p=i);for(var l=0;l<p.length;l++){var m=t[l],h=p[l],g=c[m],_=r[m];_&&(_[d]=h),h<g[0]&&(g[0]=h),h>g[1]&&(g[1]=h)}}}},e.prototype.lttbDownSample=function(e,t){var n=this.clone([e],!0),r=n._chunks[e],i=this.count(),a=0,o=Math.floor(1/t),s=this.getRawIndex(0),c,l,u,d=new(Jv(this._rawCount))(Math.min((Math.ceil(i/o)+2)*2,i));d[a++]=s;for(var f=1;f<i-1;f+=o){for(var p=Math.min(f+o,i-1),m=Math.min(f+o*2,i),h=(m+p)/2,g=0,_=p;_<m;_++){var v=this.getRawIndex(_),y=r[v];isNaN(y)||(g+=y)}g/=m-p;var b=f,x=Math.min(f+o,i),S=f-1,C=r[s];c=-1,u=b;for(var w=-1,T=0,_=b;_<x;_++){var v=this.getRawIndex(_),y=r[v];if(isNaN(y)){T++,w<0&&(w=v);continue}l=Math.abs((S-h)*(y-C)-(S-_)*(g-C)),l>c&&(c=l,u=v)}T>0&&T<x-b&&(d[a++]=Math.min(w,u),u=Math.max(w,u)),d[a++]=u,s=u}return d[a++]=this.getRawIndex(i-1),n._count=a,n._indices=d,n.getRawIndex=this._getRawIdx,n},e.prototype.minmaxDownSample=function(e,t){for(var n=this.clone([e],!0),r=n._chunks,i=Math.floor(1/t),a=r[e],o=this.count(),s=new(Jv(this._rawCount))(Math.ceil(o/i)*2),c=0,l=0;l<o;l+=i){var u=l,d=a[this.getRawIndex(u)],f=l,p=a[this.getRawIndex(f)],m=i;l+i>o&&(m=o-l);for(var h=0;h<m;h++){var g=a[this.getRawIndex(l+h)];g<d&&(d=g,u=l+h),g>p&&(p=g,f=l+h)}var _=this.getRawIndex(u),v=this.getRawIndex(f);u<f?(s[c++]=_,s[c++]=v):(s[c++]=v,s[c++]=_)}return n._count=c,n._indices=s,n._updateGetRawIdx(),n},e.prototype.downSample=function(e,t,n,r){for(var i=this.clone([e],!0),a=i._chunks,o=[],s=Math.floor(1/t),c=a[e],l=this.count(),u=i._rawExtent[e]=ks(),d=new(Jv(this._rawCount))(Math.ceil(l/s)),f=0,p=0;p<l;p+=s){s>l-p&&(s=l-p,o.length=s);for(var m=0;m<s;m++)o[m]=c[this.getRawIndex(p+m)];var h=n(o),g=this.getRawIndex(Math.min(p+r(o,h)||0,l-1));c[g]=h,h<u[0]&&(u[0]=h),h>u[1]&&(u[1]=h),d[f++]=g}return i._count=f,i._indices=d,i._updateGetRawIdx(),i},e.prototype.each=function(e,t){if(this._count)for(var n=e.length,r=this._chunks,i=0,a=this.count();i<a;i++){var o=this.getRawIndex(i);switch(n){case 0:t(i);break;case 1:t(r[e[0]][o],i);break;case 2:t(r[e[0]][o],r[e[1]][o],i);break;default:for(var s=0,c=[];s<n;s++)c[s]=r[e[s]][o];c[s]=i,t.apply(null,c)}}},e.prototype.getDataExtent=function(e,t){var n=this._chunks[e],r=ks();if(!n)return r;var i=this.count();if(!this._indices&&!t)return this._rawExtent[e].slice();var a=this._extent,o=a[e]||(a[e]={}),s=kv(t),c=s.key,l=o[c];if(l)return l.slice();for(var u=r[0],d=r[1],f=0;f<i;f++){var p=n[this.getRawIndex(f)];(!t||Av(s,p))&&(p<u&&(u=p),p>d&&(d=p))}return o[c]=[u,d]},e.prototype.getRawDataItem=function(e){var t=this.getRawIndex(e);if(this._provider.persistent)return this._provider.getItem(t);for(var n=[],r=this._chunks,i=0;i<r.length;i++)n.push(r[i][t]);return n},e.prototype.clone=function(t,n){var r=new e,i=this._chunks,a=t&&Te(t,function(e,t){return e[t]=!0,e},{});if(a)for(var o=0;o<i.length;o++)r._chunks[o]=a[o]?Yv(i[o]):i[o];else r._chunks=i;return this._copyCommonProps(r),n||(r._indices=this._cloneIndices()),r._updateGetRawIdx(),r},e.prototype._copyCommonProps=function(e){e._count=this._count,e._rawCount=this._rawCount,e._provider=this._provider,e._dimensions=this._dimensions,e._extent=P(this._extent),e._rawExtent=P(this._rawExtent)},e.prototype._cloneIndices=function(){if(this._indices){var e=this._indices.constructor,t=void 0;if(e===Array){var n=this._indices.length;t=new e(n);for(var r=0;r<n;r++)t[r]=this._indices[r]}else t=new e(this._indices);return t}return null},e.prototype._getRawIdxIdentity=function(e){return e},e.prototype._getRawIdx=function(e){return e<this._count&&e>=0?this._indices[e]:-1},e.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},e.internalField=function(){function e(e,t,n,r){return Ev(e[r],this._dimensions[r])}qv={arrayRows:e,objectRows:function(e,t,n,r){return Ev(e[t],this._dimensions[r])},keyedColumns:e,original:function(e,t,n,r){var i=e&&(e.value==null?e:e.value);return Ev(i instanceof Array?i[r]:i,this._dimensions[r])},typedArray:function(e,t,n,r){return e[r]}}}(),e}(),Qv=function(){function e(e){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=e}return e.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},e.prototype._setLocalSource=function(e,t){this._sourceList=e,this._upstreamSignList=t,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},e.prototype._getVersionSign=function(){return this._sourceHost.uid+`_`+this._versionSignBase},e.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},e.prototype._createSource=function(){this._setLocalSource([],[]);var e=this._sourceHost,t=this._getUpstreamSourceManagers(),n=!!t.length,r,i;if($v(e)){var a=e,o=void 0,s=void 0,c=void 0;if(n){var l=t[0];l.prepareSource(),c=l.getSource(),o=c.data,s=c.sourceFormat,i=[l._getVersionSign()]}else o=a.get(`data`,!0),s=Ne(o)?Pu:Au,i=[];var u=this._getSourceMetaRawOption()||{},d=c&&c.metaRawOption||{},f=q(u.seriesLayoutBy,d.seriesLayoutBy)||null,p=q(u.sourceHeader,d.sourceHeader),m=q(u.dimensions,d.dimensions);r=f!==d.seriesLayoutBy||!!p!=!!d.sourceHeader||m?[K_(o,{seriesLayoutBy:f,sourceHeader:p,dimensions:m},s)]:[]}else{var h=e;if(n){var g=this._applyTransform(t);r=g.sourceList,i=g.upstreamSignList}else r=[K_(h.get(`source`,!0),this._getSourceMetaRawOption(),null)],i=[]}this._setLocalSource(r,i)},e.prototype._applyTransform=function(e){var t=this._sourceHost,n=t.get(`transform`,!0),r=t.get(`fromTransformResult`,!0);r!=null&&e.length!==1&&ey(``);var i,a=[],o=[];return z(e,function(e){e.prepareSource();var t=e.getSource(r||0);r!=null&&!t&&ey(``),a.push(t),o.push(e._getVersionSign())}),n?i=zv(n,a,{datasetIndex:t.componentIndex}):r!=null&&(i=[J_(a[0])]),{sourceList:i,upstreamSignList:o}},e.prototype._isDirty=function(){if(this._dirty)return!0;for(var e=this._getUpstreamSourceManagers(),t=0;t<e.length;t++){var n=e[t];if(n._isDirty()||this._upstreamSignList[t]!==n._getVersionSign())return!0}},e.prototype.getSource=function(e){e||=0;var t=this._sourceList[e];if(!t){var n=this._getUpstreamSourceManagers();return n[0]&&n[0].getSource(e)}return t},e.prototype.getSharedDataStore=function(e){var t=e.makeStoreSchema();return this._innerGetDataStore(t.dimensions,e.source,t.hash)},e.prototype._innerGetDataStore=function(e,t,n){var r=0,i=this._storeList,a=i[r];a||=i[r]={};var o=a[n];if(!o){var s=this._getUpstreamSourceManagers()[0];$v(this._sourceHost)&&s?o=s._innerGetDataStore(e,t,n):(o=new Zv,o.initData(new sv(t,e.length),e)),a[n]=o}return o},e.prototype._getUpstreamSourceManagers=function(){var e=this._sourceHost;if($v(e)){var t=Hg(e);return t?[t.getSourceManager()]:[]}else return B(Ug(e),function(e){return e.getSourceManager()})},e.prototype._getSourceMetaRawOption=function(){var e=this._sourceHost,t,n,r;if($v(e))t=e.get(`seriesLayoutBy`,!0),n=e.get(`sourceHeader`,!0),r=e.get(`dimensions`,!0);else if(!this._getUpstreamSourceManagers().length){var i=e;t=i.get(`seriesLayoutBy`,!0),n=i.get(`sourceHeader`,!0),r=i.get(`dimensions`,!0)}return{seriesLayoutBy:t,sourceHeader:n,dimensions:r}},e}();function $v(e){return e.mainType===`series`}function ey(e){throw Error(e)}var ty=`line-height:1`;function ny(e){var t=e.lineHeight;return t==null?ty:`line-height:`+Rt(t+``)+`px`}function ry(e,t){var n=e.color||Q.color.tertiary,r=e.fontSize||12,i=e.fontWeight||`400`,a=e.color||Q.color.secondary,o=e.fontSize||14,s=e.fontWeight||`900`;return t===`html`?{nameStyle:`font-size:`+Rt(r+``)+`px;color:`+Rt(n)+`;font-weight:`+Rt(i+``),valueStyle:`font-size:`+Rt(o+``)+`px;color:`+Rt(a)+`;font-weight:`+Rt(s+``)}:{nameStyle:{fontSize:r,fill:n,fontWeight:i},valueStyle:{fontSize:o,fill:a,fontWeight:s}}}var iy=[0,10,20,30],ay=[``,`
`,`
`,`
`];function oy(e,t){return t.type=e,t}function sy(e){return e.type===`section`}function cy(e){return sy(e)?uy:dy}function ly(e){if(sy(e)){var t=0,n=e.blocks.length,r=n>1||n>0&&!e.noHeader;return z(e.blocks,function(e){var n=ly(e);n>=t&&(t=n+ +(r&&(!n||sy(e)&&!e.noHeader)))}),t}return 0}function uy(e,t,n,r){var i=t.noHeader,a=py(ly(t)),o=[],s=t.blocks||[];He(!s||U(s)),s||=[];var c=e.orderMode;if(t.sortBlocks&&c){s=s.slice();var l={valueAsc:`asc`,valueDesc:`desc`};if(et(l,c)){var u=new Ov(l[c],null);s.sort(function(e,t){return u.evaluate(e.sortParam,t.sortParam)})}else c===`seriesDesc`&&s.reverse()}z(s,function(n,i){var s=t.valueFormatter,c=cy(n)(s?I(I({},e),{valueFormatter:s}):e,n,i>0?a.html:0,r);c!=null&&o.push(c)});var d=e.renderMode===`richText`?o.join(a.richText):my(r,o.join(``),i?n:a.html);if(i)return d;var f=$h(t.header,`ordinal`,e.useUTC),p=ry(r,e.renderMode).nameStyle,m=ny(r);return e.renderMode===`richText`?_y(e,f,p)+a.richText+d:my(r,`<div style="`+p+`;`+m+`;">`+Rt(f)+`</div>`+d,n)}function dy(e,t,n,r){var i=e.renderMode,a=t.noName,o=t.noValue,s=!t.markerType,c=t.name,l=e.useUTC,u=t.valueFormatter||e.valueFormatter||function(e){return e=U(e)?e:[e],B(e,function(e,t){return $h(e,U(p)?p[t]:p,l)})};if(!(a&&o)){var d=s?``:e.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||Q.color.secondary,i),f=a?``:$h(c,`ordinal`,l),p=t.valueType,m=o?[]:u(t.value,t.rawDataIndex),h=!s||!a,g=!s&&a,_=ry(r,i),v=_.nameStyle,y=_.valueStyle;return i===`richText`?(s?``:d)+(a?``:_y(e,f,v))+(o?``:vy(e,m,h,g,y)):my(r,(s?``:d)+(a?``:hy(f,!s,v))+(o?``:gy(m,h,g,y)),n)}}function fy(e,t,n,r,i,a){if(e)return cy(e)({useUTC:i,renderMode:n,orderMode:r,markupStyleCreator:t,valueFormatter:e.valueFormatter},e,0,a)}function py(e){return{html:iy[e],richText:ay[e]}}function my(e,t,n){var r=`<div style="clear:both"></div>`,i=`margin: `+n+`px 0 0`,a=ny(e);return`<div style="`+i+`;`+a+`;">`+t+r+`</div>`}function hy(e,t,n){var r=t?`margin-left:2px`:``;return`<span style="`+n+`;`+r+`">`+Rt(e)+`</span>`}function gy(e,t,n,r){var i=t?`float:right;margin-left:`+(n?`10px`:`20px`):``;return e=U(e)?e:[e],`<span style="`+i+`;`+r+`">`+B(e,function(e){return Rt(e)}).join(`&nbsp;&nbsp;`)+`</span>`}function _y(e,t,n){return e.markupStyleCreator.wrapRichTextStyle(t,n)}function vy(e,t,n,r,i){var a=[i],o=r?10:20;return n&&a.push({padding:[0,0,0,o],align:`right`}),e.markupStyleCreator.wrapRichTextStyle(U(t)?t.join(` `):t,a)}function yy(e,t){var n=e.getData().getItemVisual(t,`style`)[e.visualDrawType];return ig(n)}function by(e,t){return e.get(`padding`)??(t===`richText`?[8,10]:10)}var xy=function(){function e(){this.richTextStyles={},this._nextStyleNameId=Ro()}return e.prototype._generateStyleName=function(){return`__EC_aUTo_`+ this._nextStyleNameId++},e.prototype.makeTooltipMarker=function(e,t,n){var r=n===`richText`?this._generateStyleName():null,i=rg({color:t,type:e,renderMode:n,markerId:r});return G(i)?i:(this.richTextStyles[r]=i.style,i.content)},e.prototype.wrapRichTextStyle=function(e,t){var n={};U(t)?z(t,function(e){return I(n,e)}):I(n,t);var r=this._generateStyleName();return this.richTextStyles[r]=n,`{`+r+`|`+e+`}`},e}();function Sy(e){var t=e.series,n=e.dataIndex,r=e.multipleSeries,i=t.getData(),a=i.mapDimensionsAll(`defaultedTooltip`),o=a.length,s=t.getRawValue(n),c=U(s),l=yy(t,n),u,d,f,p;if(o>1||c&&!o){var m=Cy(s,t,n,a,l);u=m.inlineValues,d=m.inlineValueTypes,f=m.blocks,p=m.inlineValues[0]}else if(o){var h=i.getDimensionInfo(a[0]);p=u=yv(i,n,a[0]),d=h.type}else p=u=c?s[0]:s;var g=fs(t),_=g&&t.name||``,v=i.getName(n),y=r?_:v;return oy(`section`,{header:_,noHeader:r||!g,sortParam:p,blocks:[oy(`nameValue`,{markerType:`item`,markerColor:l,name:y,noName:!Ue(y),value:u,valueType:d,rawDataIndex:i.getRawIndex(n)})].concat(f||[])})}function Cy(e,t,n,r,i){var a=t.getData(),o=Te(e,function(e,t,n){var r=a.getDimensionInfo(n);return e||=r&&r.tooltip!==!1&&r.displayName!=null},!1),s=[],c=[],l=[];r.length?z(r,function(e){u(yv(a,n,e),e)}):z(e,u);function u(e,t){var n=a.getDimensionInfo(t);!n||n.otherDims.tooltip===!1||(o?l.push(oy(`nameValue`,{markerType:`subItem`,markerColor:i,name:n.displayName,value:e,valueType:n.type})):(s.push(e),c.push(n.type)))}return{inlineValues:s,inlineValueTypes:c,blocks:l}}var wy=Z();function Ty(e,t){return e.getName(t)||e.getId(t)}var Ey=function(e){k(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t._selectedDataIndicesMap={},t}return t.prototype.init=function(e,t,n){this.seriesIndex=this.componentIndex,this.dataTask=Cv({count:ky,reset:Ay}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(e,n),(wy(this).sourceManager=new Qv(this)).prepareSource();var r=this.getInitialData(e,n);My(r,this),this.dataTask.context.data=r,wy(this).dataBeforeProcessed=r,Dy(this),this._initSelectedMapFromData(r)},t.prototype.mergeDefaultAndTheme=function(e,t){var n=Cg(this),r=n?Tg(e):{},i=this.subType;Og.hasClass(i)&&(i+=`Series`),F(e,t.getTheme().get(this.subType)),F(e,this.getDefaultOption()),Qo(e,`label`,[`show`]),this.fillDataTextStyle(e.data),n&&wg(e,r,n)},t.prototype.mergeOption=function(e,t){e=F(this.option,e,!0),this.fillDataTextStyle(e.data);var n=Cg(this);n&&wg(this.option,e,n);var r=wy(this).sourceManager;r.dirty(),r.prepareSource();var i=this.getInitialData(e,t);My(i,this),this.dataTask.dirty(),this.dataTask.context.data=i,wy(this).dataBeforeProcessed=i,Dy(this),this._initSelectedMapFromData(i)},t.prototype.fillDataTextStyle=function(e){if(e&&!Ne(e))for(var t=[`show`],n=0;n<e.length;n++)e[n]&&e[n].label&&Qo(e[n],`label`,t)},t.prototype.getInitialData=function(e,t){},t.prototype.appendData=function(e){this.getRawData().appendData(e.data)},t.prototype.getData=function(e){var t=Py(this);if(t){var n=t.context.data;return e==null||!n.getLinkedData?n:n.getLinkedData(e)}else return wy(this).data},t.prototype.getAllData=function(){var e=this.getData();return e&&e.getLinkedDataAll?e.getLinkedDataAll():[{data:e}]},t.prototype.setData=function(e){var t=Py(this);if(t){var n=t.context;n.outputData=e,t!==this.dataTask&&(n.data=e)}wy(this).data=e},t.prototype.getEncode=function(){var e=this.get(`encode`,!0);if(e)return J(e)},t.prototype.getSourceManager=function(){return wy(this).sourceManager},t.prototype.getSource=function(){return this.getSourceManager().getSource()},t.prototype.getRawData=function(){return wy(this).dataBeforeProcessed},t.prototype.getColorBy=function(){return this.get(`colorBy`)||`series`},t.prototype.isColorBySeries=function(){return this.getColorBy()===`series`},t.prototype.getBaseAxis=function(){var e=this.coordinateSystem;return e&&e.getBaseAxis&&e.getBaseAxis()},t.prototype.indicesOfNearest=function(e,t,n,r){var i=this.getData(),a=this.coordinateSystem,o=a&&a.getAxis(e);if(!a||!o)return[];var s=o.dataToCoord(n);r??=1/0;for(var c=[],l=1/0,u=-1,d=0,f=i.getDimensionIndex(t),p=i.getStore(),m=0,h=p.count();m<h;m++){var g=p.get(f,m),_=s-o.dataToCoord(g),v=Math.abs(_);v<=r&&((v<l||v===l&&_>=0&&u<0)&&(l=v,u=_,d=0),_===u&&(c[d++]=m))}return c.length=d,c},t.prototype.formatTooltip=function(e,t,n){return Sy({series:this,dataIndex:e,multipleSeries:t})},t.prototype.isAnimationEnabled=function(){var e=this.ecModel;if(j.node&&!(e&&e.ssr))return!1;var t=this.getShallow(`animation`);return t&&this.getData().count()>this.getShallow(`animationThreshold`)&&(t=!1),!!t},t.prototype.restoreData=function(){this.dataTask.dirty()},t.prototype.getColorFromPalette=function(e,t,n){var r=this.ecModel,i=Xg.prototype.getColorFromPalette.call(this,e,t,n);return i||=r.getColorFromPalette(e,t,n),i},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,t){this._innerSelect(this.getData(t),e)},t.prototype.unselect=function(e,t){var n=this.option.selectedMap;if(n){var r=this.option.selectedMode,i=this.getData(t);if(r===`series`||n===`all`){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var a=0;a<e.length;a++){var o=e[a],s=Ty(i,o);n[s]=!1,this._selectedDataIndicesMap[s]=-1}}},t.prototype.toggleSelect=function(e,t){for(var n=[],r=0;r<e.length;r++)n[0]=e[r],this.isSelected(e[r],t)?this.unselect(n,t):this.select(n,t)},t.prototype.getSelectedDataIndices=function(){if(this.option.selectedMap===`all`)return[].slice.call(this.getData().getIndices());for(var e=this._selectedDataIndicesMap,t=Oe(e),n=[],r=0;r<t.length;r++){var i=e[t[r]];i>=0&&n.push(i)}return n},t.prototype.isSelected=function(e,t){var n=this.option.selectedMap;if(!n)return!1;var r=this.getData(t);return(n===`all`||n[Ty(r,e)])&&!r.getItemModel(e).get([`select`,`disabled`])},t.prototype.isUniversalTransitionEnabled=function(){if(this.__universalTransitionEnabled)return!0;var e=this.option.universalTransition;return e?e===!0?!0:e&&e.enabled:!1},t.prototype._innerSelect=function(e,t){var n,r,i=this.option,a=i.selectedMode,o=t.length;if(!(!a||!o)){if(a===`series`)i.selectedMap=`all`;else if(a===`multiple`){K(i.selectedMap)||(i.selectedMap={});for(var s=i.selectedMap,c=0;c<o;c++){var l=t[c],u=Ty(e,l);s[u]=!0,this._selectedDataIndicesMap[u]=e.getRawIndex(l)}}else if(a===`single`||a===!0){var d=t[o-1],u=Ty(e,d);i.selectedMap=(n={},n[u]=!0,n),this._selectedDataIndicesMap=(r={},r[u]=e.getRawIndex(d),r)}}},t.prototype._initSelectedMapFromData=function(e){if(!this.option.selectedMap){var t=[];e.hasItemOption&&e.each(function(n){var r=e.getRawDataItem(n);r&&r.selected&&t.push(n)}),t.length>0&&this._innerSelect(e,t)}},t.registerClass=function(e){return Og.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}(Og);Ce(Ey,xv),Ce(Ey,Xg),ec(Ey,Og);function Dy(e){var t=e.name;fs(e)||(e.name=Oy(e)||t)}function Oy(e){var t=e.getRawData(),n=t.mapDimensionsAll(`seriesName`),r=[];return z(n,function(e){var n=t.getDimensionInfo(e);n.displayName&&r.push(n.displayName)}),r.join(` `)}function ky(e){return e.model.getRawData().count()}function Ay(e){var t=e.model;return t.setData(t.getRawData().cloneShallow()),jy}function jy(e,t){t.outputData&&e.end>t.outputData.count()&&t.model.getRawData().cloneShallow(t.outputData)}function My(e,t){z(Ze(e.CHANGABLE_METHODS,e.DOWNSAMPLE_METHODS),function(n){e.wrapMethod(n,H(Ny,t))})}function Ny(e,t){var n=Py(e);return n&&n.setOutputEnd((t||this).count()),t}function Py(e){var t=(e.ecModel||{}).scheduler,n=t&&t.getPipeline(e.uid);if(n){var r=n.currentTask;if(r){var i=r.agentStubMap;i&&(r=i.get(e.uid))}return r}}var Fy=function(){function e(){this.group=new Ya,this.uid=qm(`viewComponent`)}return e.prototype.init=function(e,t){},e.prototype.render=function(e,t,n,r){},e.prototype.dispose=function(e,t){},e.prototype.updateView=function(e,t,n,r){},e.prototype.updateLayout=function(e,t,n,r){},e.prototype.updateVisual=function(e,t,n,r){},e.prototype.toggleBlurSeries=function(e,t,n){},e.prototype.eachRendered=function(e){var t=this.group;t&&t.traverse(e)},e}();Qs(Fy),ac(Fy);function Iy(){var e=Z();return function(t){var n=e(t),r=t.pipelineContext,i=!!n.large,a=!!n.progressiveRender,o=n.large=!!(r&&r.large),s=n.progressiveRender=!!(r&&r.progressiveRender);return(i!==o||a!==s)&&`reset`}}var Ly=Z(),Ry=Iy(),zy=function(){function e(){this.group=new Ya,this.uid=qm(`viewChart`),this.renderTask=Cv({plan:Hy,reset:Uy}),this.renderTask.context={view:this}}return e.prototype.init=function(e,t){},e.prototype.render=function(e,t,n,r){},e.prototype.highlight=function(e,t,n,r){var i=e.getData(r&&r.dataType);i&&Vy(i,r,`emphasis`)},e.prototype.downplay=function(e,t,n,r){var i=e.getData(r&&r.dataType);i&&Vy(i,r,`normal`)},e.prototype.remove=function(e,t){this.group.removeAll()},e.prototype.dispose=function(e,t){},e.prototype.updateView=function(e,t,n,r){this.render(e,t,n,r)},e.prototype.updateVisual=function(e,t,n,r){this.render(e,t,n,r)},e.prototype.eachRendered=function(e){om(this.group,e)},e.markUpdateMethod=function(e,t){Ly(e).updateMethod=t},e.protoInitialize=function(){var t=e.prototype;t.type=`chart`}(),e}();function By(e,t,n){e&&Hd(e)&&(t===`emphasis`?_d:vd)(e,n)}function Vy(e,t,n){var r=_s(e,t),i=t&&t.highlightKey!=null?Ud(t.highlightKey):null;r==null?e.eachItemGraphicEl(function(e){By(e,n,i)}):z(Zo(r),function(t){By(e.getItemGraphicEl(t),n,i)})}Qs(zy,[`dispose`]),ac(zy);function Hy(e){return Ry(e.model)}function Uy(e){var t=e.model,n=e.ecModel,r=e.api,i=e.payload,a=t.pipelineContext.progressiveRender,o=e.view,s=i&&Ly(i).updateMethod,c=a?`incrementalPrepareRender`:s&&o[s]?s:`render`;return c!==`render`&&o[c](t,n,r,i),Wy[c]}var Wy={incrementalPrepareRender:{progress:function(e,t){t.view.incrementalRender(e,t.model,t.ecModel,t.api,t.payload)}},render:{forceFirstProgress:!0,progress:function(e,t){t.view.render(t.model,t.ecModel,t.api,t.payload)}}},Gy=`\0__throttleOriginMethod`,Ky=`\0__throttleRate`,qy=`\0__throttleType`;function Jy(e,t,n){var r,i=0,a=0,o=null,s,c,l,u;t||=0;function d(){a=new Date().getTime(),o=null,e.apply(c,l||[])}var f=function(){var e=[...arguments];r=new Date().getTime(),c=this,l=e;var f=u||t,p=u||n;u=null,s=r-(p?i:a)-f,clearTimeout(o),p?o=setTimeout(d,f):s>=0?d():o=setTimeout(d,-s),i=r};return f.clear=function(){o&&=(clearTimeout(o),null)},f.debounceNextCall=function(e){u=e},f}function Yy(e,t,n,r){var i=e[t];if(i){var a=i[Gy]||i,o=i[qy];if(i[Ky]!==n||o!==r){if(n==null||!r)return e[t]=a;i=e[t]=Jy(a,n,r===`debounce`),i[Gy]=a,i[qy]=r,i[Ky]=n}return i}}function Xy(e,t){var n=e[t];n&&n[Gy]&&(n.clear&&n.clear(),e[t]=n[Gy])}var Zy=Z(),Qy={itemStyle:oc(Hm,!0),lineStyle:oc(zm,!0)},$y={lineStyle:`stroke`,itemStyle:`fill`};function eb(e,t){return e.visualStyleMapper||Qy[t]||(console.warn(`Unknown style type '`+t+`'.`),Qy.itemStyle)}function tb(e,t){return e.visualDrawType||$y[t]||(console.warn(`Unknown style type '`+t+`'.`),`fill`)}var nb={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var n=e.getData(),r=e.visualStyleAccessPath||`itemStyle`,i=e.getModel(r),a=eb(e,r)(i),o=i.getShallow(`decal`);o&&(n.setVisual(`decal`,o),o.dirty=!0);var s=tb(e,r),c=a[s],l=W(c)?c:null,u=a.fill===`auto`||a.stroke===`auto`;if(!a[s]||l||u){var d=e.getColorFromPalette(e.name,null,t.getSeriesCount());a[s]||(a[s]=d,n.setVisual(`colorFromPalette`,!0)),a.fill=a.fill===`auto`||W(a.fill)?d:a.fill,a.stroke=a.stroke===`auto`||W(a.stroke)?d:a.stroke}if(n.setVisual(`style`,a),n.setVisual(`drawType`,s),!t.isSeriesFiltered(e)&&l)return n.setVisual(`colorFromPalette`,!1),{dataEach:function(t,n){var r=e.getDataParams(n),i=I({},a);i[s]=l(r),t.setItemVisual(n,`style`,i)}}}},rb=new Gm,ib={createOnAllSeries:!0,reset:function(e,t){if(!e.ignoreStyleOnData){var n=e.getData(),r=e.visualStyleAccessPath||`itemStyle`,i=eb(e,r),a=n.getVisual(`drawType`);return{dataEach:n.hasItemOption?function(e,t){var n=e.getRawDataItem(t);if(n&&n[r]){rb.option=n[r];var o=i(rb);I(e.ensureUniqueItemVisual(t,`style`),o),rb.option.decal&&(e.setItemVisual(t,`decal`,rb.option.decal),rb.option.decal.dirty=!0),a in o&&e.setItemVisual(t,`colorFromPalette`,!1)}}:null}}}},ab={performRawSeries:!0,overallReset:function(e){var t=J();e.eachSeries(function(e){if(!e.isColorBySeries()){var n=e.type+`-`+e.getColorBy();Zy(e).scope=t.get(n)||t.set(n,{})}}),e.eachSeries(function(e){if(!e.isColorBySeries()){var t=e.getRawData(),n={},r=e.getData(),i=Zy(e).scope,a=tb(e,e.visualStyleAccessPath||`itemStyle`);r.each(function(e){var t=r.getRawIndex(e);n[t]=e}),t.each(function(o){var s=n[o];if(r.getItemVisual(s,`colorFromPalette`)){var c=r.ensureUniqueItemVisual(s,`style`),l=t.getName(o)||o+``,u=t.count();c[a]=e.getColorFromPalette(l,i,u)}})}})}},ob=Math.PI;function sb(e,t){t||={},L(t,{text:`loading`,textColor:Q.color.primary,fontSize:12,fontWeight:`normal`,fontStyle:`normal`,fontFamily:`sans-serif`,maskColor:`rgba(255,255,255,0.8)`,showSpinner:!0,color:Q.color.theme[0],spinnerRadius:10,lineWidth:5,zlevel:0});var n=new Ya,r=new cu({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4});n.add(r);var i=new pu({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 cu({style:{fill:`none`},textContent:i,textConfig:{position:`right`,distance:10},zlevel:t.zlevel,z:10001});n.add(a);var o;return t.showSpinner&&(o=new $f({shape:{startAngle:-ob/2,endAngle:-ob/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:ob*3/2}).start(`circularInOut`),o.animateShape(!0).when(1e3,{startAngle:ob*3/2}).delay(300).start(`circularInOut`),n.add(o)),n.resize=function(){var n=i.getBoundingRect().width,s=t.showSpinner?t.spinnerRadius:0,c=(e.getWidth()-s*2-(t.showSpinner&&n?10:0)-n)/2-(t.showSpinner&&n?0:5+n/2)+(t.showSpinner?0:n/2)+(n?0:s),l=e.getHeight()/2;t.showSpinner&&o.setShape({cx:c,cy:l}),a.setShape({x:c-s,y:l-s,width:s*2,height:s*2}),r.setShape({x:0,y:0,width:e.getWidth(),height:e.getHeight()})},n.resize(),n}var cb=function(){function e(e,t,n,r){this._stageTaskMap=J(),this.ecInstance=e,this.api=t,n=this._dataProcessorHandlers=n.slice(),r=this._visualHandlers=r.slice(),this._allHandlers=n.concat(r)}return e.prototype.restoreData=function(e,t){e.restoreData(t),this._stageTaskMap.each(function(e){var t=e.overallTask;t&&t.dirty()})},e.prototype.getPerformArgs=function(e,t){if(e.__pipeline){var n=this._pipelineMap.get(e.__pipeline.id),r=n.context,i=!t&&n.progressiveEnabled&&(!r||r.progressiveRender)&&e.__idxInPipeline>n.blockIndex?n.step:null,a=r&&r.modDataCount;return{step:i,modBy:a==null?null:Math.ceil(a/i),modDataCount:a}}},e.prototype.getPipeline=function(e){return this._pipelineMap.get(e)},e.prototype.updateStreamModes=function(e,t){var n=this._pipelineMap.get(e.uid);e.pipelineContext=n.context=e.__preparePipelineContext?e.__preparePipelineContext(t,n):Ws(e,t,n)},e.prototype.restorePipelines=function(e,t){var n=this,r=n._pipelineMap=J();t.eachSeries(function(t){var i=e.painter.type===`canvas`&&t.getProgressive(),a=t.uid;r.set(a,{id:a,head:null,tail:null,threshold:t.getProgressiveThreshold(),progressiveEnabled:i&&!(t.preventIncremental&&t.preventIncremental()),blockIndex:-1,step:Math.round(i||700),count:0}),n._pipe(t,t.dataTask)})},e.prototype.prepareStageTasks=function(){var e=this._stageTaskMap,t=this.api.getModel(),n=this.api;z(this._allHandlers,function(r){var i=e.get(r.uid)||e.set(r.uid,{});He(!(r.reset&&r.overallReset),``),r.reset&&this._createSeriesStageTask(r,i,t,n),r.overallReset&&this._createOverallStageTask(r,i,t,n)},this)},e.prototype.prepareView=function(e,t,n,r){var i=e.renderTask,a=i.context;a.model=t,a.ecModel=n,a.api=r,i.__block=!e.incrementalPrepareRender,this._pipe(t,i)},e.prototype.performDataProcessorTasks=function(e,t){this._performStageTasks(this._dataProcessorHandlers,e,t,{block:!0})},e.prototype.performVisualTasks=function(e,t,n){this._performStageTasks(this._visualHandlers,e,t,n)},e.prototype._performStageTasks=function(e,t,n,r){r||={};var i=!1,a=this;z(e,function(e,s){if(!(r.visualType&&r.visualType!==e.visualType)){var c=a._stageTaskMap.get(e.uid),l=c.seriesTaskMap,u=c.overallTask;if(u){var d,f=u.agentStubMap;f.each(function(e){o(r,e)&&(e.dirty(),d=!0)}),d&&u.dirty(),a.updatePayload(u,n);var p=a.getPerformArgs(u,r.block);f.each(function(e){e.perform(p)}),u.perform(p)&&(i=!0)}else l&&l.each(function(s,c){o(r,s)&&s.dirty();var l=a.getPerformArgs(s,r.block);l.skip=!e.performRawSeries&&t.isSeriesFiltered(s.context.model),a.updatePayload(s,n),s.perform(l)&&(i=!0)})}});function o(e,t){return e.setDirty&&(!e.dirtyMap||e.dirtyMap.get(t.__pipeline.id))}this.unfinished=i||this.unfinished},e.prototype.performSeriesTasks=function(e){var t;e.eachSeries(function(e){t=e.dataTask.perform()||t}),this.unfinished=t||this.unfinished},e.prototype.plan=function(){this._pipelineMap.each(function(e){var t=e.tail;do{if(t.__block){e.blockIndex=t.__idxInPipeline;break}t=t.getUpstream()}while(t)})},e.prototype.updatePayload=function(e,t){t!==`remain`&&(e.context.payload=t)},e.prototype._createSeriesStageTask=function(e,t,n,r){var i=this,a=t.seriesTaskMap,o=t.seriesTaskMap=J(),s=e.seriesType,c=e.getTargetSeries;e.createOnAllSeries?n.eachRawSeries(l):s?n.eachRawSeriesByType(s,l):c&&c(n,r).each(l);function l(t){var s=t.uid,c=o.set(s,a&&a.get(s)||Cv({plan:pb,reset:mb,count:_b}));c.context={model:t,ecModel:n,api:r,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:i},i._pipe(t,c)}},e.prototype._createOverallStageTask=function(e,t,n,r){var i=this,a=t.overallTask=t.overallTask||Cv({reset:lb});a.context={ecModel:n,api:r,overallReset:e.overallReset,scheduler:i};var o=a.agentStubMap,s=a.agentStubMap=J(),c=e.seriesType,l=e.getTargetSeries,u=e.dirtyOnOverallProgress,d=!1;He(!e.createOnAllSeries,``),c?n.eachRawSeriesByType(c,f):l?l(n,r).each(f):z(n.getSeries(),f);function f(e){var t=e.uid,n=s.set(t,o&&o.get(t)||(d=!0,Cv({reset:ub,onDirty:fb})));n.context={model:e,dirtyOnOverallProgress:u},n.agent=a,n.__block=u,i._pipe(e,n)}d&&a.dirty()},e.prototype._pipe=function(e,t){var n=e.uid,r=this._pipelineMap.get(n);!r.head&&(r.head=t),r.tail&&r.tail.pipe(t),r.tail=t,t.__idxInPipeline=r.count++,t.__pipeline=r},e.wrapStageHandler=function(e,t){return W(e)&&(e={overallReset:e,seriesType:vb(e)}),e.uid=qm(`stageHandler`),t&&(e.visualType=t),e},e}();function lb(e){e.overallReset(e.ecModel,e.api,e.payload)}function ub(e){return e.dirtyOnOverallProgress&&db}function db(){this.agent.dirty(),this.getDownstream().dirty()}function fb(){this.agent&&this.agent.dirty()}function pb(e){return e.plan?e.plan(e.model,e.ecModel,e.api,e.payload):null}function mb(e){e.useClearVisual&&e.data.clearAllVisual();var t=e.resetDefines=Zo(e.reset(e.model,e.ecModel,e.api,e.payload));return t.length>1?B(t,function(e,t){return gb(t)}):hb}var hb=gb(0);function gb(e){return function(t,n){var r=n.data,i=n.resetDefines[e];if(i&&i.dataEach)for(var a=t.start;a<t.end;a++)i.dataEach(r,a);else i&&i.progress&&i.progress(t,r)}}function _b(e){return e.data.count()}function vb(e){xb=null;try{e(yb,bb)}catch{}return xb}var yb={},bb={},xb;Sb(yb,a_),Sb(bb,Ru),yb.eachSeriesByType=yb.eachRawSeriesByType=function(e){xb=e},yb.eachComponent=function(e){e.mainType===`series`&&e.subType&&(xb=e.subType)};function Sb(e,t){for(var n in t.prototype)e[n]=tt}var $=Q.darkColor,Cb=$.background,wb=function(){return{axisLine:{lineStyle:{color:$.axisLine}},splitLine:{lineStyle:{color:$.axisSplitLine}},splitArea:{areaStyle:{color:[$.backgroundTint,$.backgroundTransparent]}},minorSplitLine:{lineStyle:{color:$.axisMinorSplitLine}},axisLabel:{color:$.axisLabel},axisName:{}}},Tb={label:{color:$.secondary},itemStyle:{borderColor:$.borderTint},dividerLineStyle:{color:$.border}},Eb={darkMode:!0,color:$.theme,backgroundColor:Cb,axisPointer:{lineStyle:{color:$.border},crossStyle:{color:$.borderShade},label:{color:$.tertiary}},legend:{textStyle:{color:$.secondary},pageTextStyle:{color:$.tertiary}},textStyle:{color:$.secondary},title:{textStyle:{color:$.primary},subtextStyle:{color:$.quaternary}},toolbox:{iconStyle:{borderColor:$.accent50},feature:{dataView:{backgroundColor:Cb,textColor:$.primary,textareaColor:$.background,textareaBorderColor:$.border,buttonColor:$.accent50,buttonTextColor:$.neutral00}}},tooltip:{backgroundColor:$.neutral20,defaultBorderColor:$.border,textStyle:{color:$.tertiary}},dataZoom:{borderColor:$.accent10,textStyle:{color:$.tertiary},brushStyle:{color:$.backgroundTint},handleStyle:{color:$.neutral00,borderColor:$.accent20},moveHandleStyle:{color:$.accent40},emphasis:{handleStyle:{borderColor:$.accent50}},dataBackground:{lineStyle:{color:$.accent30},areaStyle:{color:$.accent20}},selectedDataBackground:{lineStyle:{color:$.accent50},areaStyle:{color:$.accent30}}},visualMap:{textStyle:{color:$.secondary},handleStyle:{borderColor:$.neutral30}},timeline:{lineStyle:{color:$.accent10},label:{color:$.tertiary},controlStyle:{color:$.accent30,borderColor:$.accent30}},calendar:{itemStyle:{color:$.neutral00,borderColor:$.neutral20},dayLabel:{color:$.tertiary},monthLabel:{color:$.secondary},yearLabel:{color:$.secondary}},matrix:{x:Tb,y:Tb,backgroundColor:{borderColor:$.axisLine},body:{itemStyle:{borderColor:$.borderTint}}},timeAxis:wb(),logAxis:wb(),valueAxis:wb(),categoryAxis:wb(),line:{symbol:`circle`},graph:{color:$.theme},gauge:{title:{color:$.secondary},axisLine:{lineStyle:{color:[[1,$.neutral05]]}},axisLabel:{color:$.axisLabel},detail:{color:$.primary}},candlestick:{itemStyle:{color:`#f64e56`,color0:`#54ea92`,borderColor:`#f64e56`,borderColor0:`#54ea92`}},funnel:{itemStyle:{borderColor:$.background}},radar:function(){var e=wb();return e.axisName={color:$.axisLabel},e.axisLine.lineStyle.color=$.neutral20,e}(),treemap:{breadcrumb:{itemStyle:{color:$.neutral20,textStyle:{color:$.secondary}},emphasis:{itemStyle:{color:$.neutral30}}}},sunburst:{itemStyle:{borderColor:$.background}},map:{itemStyle:{borderColor:$.border,areaColor:$.neutral10},label:{color:$.tertiary},emphasis:{label:{color:$.primary},itemStyle:{areaColor:$.highlight}},select:{label:{color:$.primary},itemStyle:{areaColor:$.highlight}}},geo:{itemStyle:{borderColor:$.border,areaColor:$.neutral10},emphasis:{label:{color:$.primary},itemStyle:{areaColor:$.highlight}},select:{label:{color:$.primary},itemStyle:{color:$.highlight}}}};Eb.categoryAxis.splitLine.show=!1;var Db=function(){function e(){}return e.prototype.normalizeQuery=function(e){var t={},n={},r={};if(G(e)){var i=Ys(e);t.mainType=i.main||null,t.subType=i.sub||null}else{var a=[`Index`,`Name`,`Id`],o={name:1,dataIndex:1,dataType:1};z(e,function(e,i){for(var s=!1,c=0;c<a.length;c++){var l=a[c],u=i.lastIndexOf(l);if(u>0&&u===i.length-l.length){var d=i.slice(0,u);d!==`data`&&(t.mainType=d,t[l.toLowerCase()]=e,s=!0)}}o.hasOwnProperty(i)&&(n[i]=e,s=!0),s||(r[i]=e)})}return{cptQuery:t,dataQuery:n,otherQuery:r}},e.prototype.filter=function(e,t){var n=this.eventInfo;if(!n)return!0;var r=n.targetEl,i=n.packedEvent,a=n.model,o=n.view;if(!a||!o)return!0;var s=t.cptQuery,c=t.dataQuery;return l(s,a,`mainType`)&&l(s,a,`subType`)&&l(s,a,`index`,`componentIndex`)&&l(s,a,`name`)&&l(s,a,`id`)&&l(c,i,`name`)&&l(c,i,`dataIndex`)&&l(c,i,`dataType`)&&(!o.filterForExposedEvent||o.filterForExposedEvent(e,t.otherQuery,r,i));function l(e,t,n,r){return e[n]==null||t[r||n]===e[n]}},e.prototype.afterTrigger=function(){this.eventInfo=null},e}(),Ob=[`symbol`,`symbolSize`,`symbolRotate`,`symbolOffset`],kb=Ob.concat([`symbolKeepAspect`]),Ab={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var n=e.getData();if(e.legendIcon&&n.setVisual(`legendIcon`,e.legendIcon),!e.hasSymbolVisual)return;for(var r={},i={},a=!1,o=0;o<Ob.length;o++){var s=Ob[o],c=e.get(s);W(c)?(a=!0,i[s]=c):r[s]=c}if(r.symbol=r.symbol||e.defaultSymbol,n.setVisual(I({legendIcon:e.legendIcon||r.symbol,symbolKeepAspect:e.get(`symbolKeepAspect`)},r)),t.isSeriesFiltered(e))return;var l=Oe(i);function u(t,n){for(var r=e.getRawValue(n),a=e.getDataParams(n),o=0;o<l.length;o++){var s=l[o];t.setItemVisual(n,s,i[s](r,a))}}return{dataEach:a?u:null}}},jb={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){if(!e.hasSymbolVisual||t.isSeriesFiltered(e))return;var n=e.getData();function r(e,t){for(var n=e.getItemModel(t),r=0;r<kb.length;r++){var i=kb[r],a=n.getShallow(i,!0);a!=null&&e.setItemVisual(t,i,a)}}return{dataEach:n.hasItemOption?r:null}}};function Mb(e,t,n){switch(n){case`color`:return e.getItemVisual(t,`style`)[e.getVisual(`drawType`)];case`opacity`:return e.getItemVisual(t,`style`).opacity;case`symbol`:case`symbolSize`:case`liftZ`:return e.getItemVisual(t,n);default:}}function Nb(e,t){switch(t){case`color`:return e.getVisual(`style`)[e.getVisual(`drawType`)];case`opacity`:return e.getVisual(`style`).opacity;case`symbol`:case`symbolSize`:case`liftZ`:return e.getVisual(t);default:}}function Pb(e,t,n,r,i){var a=e+t;n.isSilent(a)||r.eachComponent({mainType:`series`,subType:`pie`},function(e){for(var t=e.seriesIndex,r=e.option.selectedMap,o=i.selected,s=0;s<o.length;s++)if(o[s].seriesIndex===t){var c=e.getData(),l=_s(c,i.fromActionPayload);n.trigger(a,{type:a,seriesId:e.id,name:U(l)?c.getName(l[0]):c.getName(l),selected:G(r)?r:I({},r)})}})}function Fb(e,t,n){e.on(`selectchanged`,function(e){var r=n.getModel();e.isFromClick?(Pb(`map`,`selectchanged`,t,r,e),Pb(`pie`,`selectchanged`,t,r,e)):e.fromAction===`select`?(Pb(`map`,`selected`,t,r,e),Pb(`pie`,`selected`,t,r,e)):e.fromAction===`unselect`&&(Pb(`map`,`unselected`,t,r,e),Pb(`pie`,`unselected`,t,r,e))})}function Ib(e,t,n){for(var r;e&&!(t(e)&&(r=e,n));)e=e.__hostTarget||e.parent;return r}var Lb=new wt,Rb={};function zb(e,t){Rb[e]=t}function Bb(e){return Rb[e]}var Vb={};function Hb(e,t){Vb[e]=t}var Ub=Z();function Wb(e){Ub(e).prepare={}}function Gb(e){Ub(e).fullUpdate={}}function Kb(e){return Ub(e).prepare}function qb(e){return Ub(e).fullUpdate}var Jb=Math.round(Math.random()*9),Yb=typeof Object.defineProperty==`function`,Xb=function(){function e(){this._id=`__ec_inner_`+ Jb++}return e.prototype.get=function(e){return this._guard(e)[this._id]},e.prototype.set=function(e,t){var n=this._guard(e);return Yb?Object.defineProperty(n,this._id,{value:t,enumerable:!1,configurable:!0}):n[this._id]=t,this},e.prototype.delete=function(e){return this.has(e)?(delete this._guard(e)[this._id],!0):!1},e.prototype.has=function(e){return!!this._guard(e)[this._id]},e.prototype._guard=function(e){if(e!==Object(e))throw TypeError(`Value of WeakMap is not a non-null object.`);return e},e}(),Zb=Jl.extend({type:`triangle`,shape:{cx:0,cy:0,width:0,height:0},buildPath:function(e,t){var n=t.cx,r=t.cy,i=t.width/2,a=t.height/2;e.moveTo(n,r-a),e.lineTo(n+i,r+a),e.lineTo(n-i,r+a),e.closePath()}}),Qb={line:qf,rect:cu,roundRect:cu,square:cu,circle:_f,diamond:Jl.extend({type:`diamond`,shape:{cx:0,cy:0,width:0,height:0},buildPath:function(e,t){var n=t.cx,r=t.cy,i=t.width/2,a=t.height/2;e.moveTo(n,r-a),e.lineTo(n+i,r),e.lineTo(n,r+a),e.lineTo(n-i,r),e.closePath()}}),pin:Jl.extend({type:`pin`,shape:{x:0,y:0,width:0,height:0},buildPath:function(e,t){var n=t.x,r=t.y,i=t.width/5*3,a=Math.max(i,t.height),o=i/2,s=o*o/(a-o),c=r-a+o+s,l=Math.asin(s/o),u=Math.cos(l)*o,d=Math.sin(l),f=Math.cos(l),p=o*.6,m=o*.7;e.moveTo(n-u,c+s),e.arc(n,c,o,Math.PI-l,Math.PI*2+l),e.bezierCurveTo(n+u-d*p,c+s+f*p,n,r-m,n,r),e.bezierCurveTo(n,r-m,n-u+d*p,c+s+f*p,n-u,c+s),e.closePath()}}),arrow:Jl.extend({type:`arrow`,shape:{x:0,y:0,width:0,height:0},buildPath:function(e,t){var n=t.height,r=t.width,i=t.x,a=t.y,o=r/3*2;e.moveTo(i,a),e.lineTo(i+o,a+n),e.lineTo(i,a+n/4*3),e.lineTo(i-o,a+n),e.lineTo(i,a),e.closePath()}}),triangle:Zb},$b={line:function(e,t,n,r,i){i.x1=e,i.y1=t+r/2,i.x2=e+n,i.y2=t+r/2},rect:function(e,t,n,r,i){i.x=e,i.y=t,i.width=n,i.height=r},roundRect:function(e,t,n,r,i){i.x=e,i.y=t,i.width=n,i.height=r,i.r=Math.min(n,r)/4},square:function(e,t,n,r,i){var a=Math.min(n,r);i.x=e,i.y=t,i.width=a,i.height=a},circle:function(e,t,n,r,i){i.cx=e+n/2,i.cy=t+r/2,i.r=Math.min(n,r)/2},diamond:function(e,t,n,r,i){i.cx=e+n/2,i.cy=t+r/2,i.width=n,i.height=r},pin:function(e,t,n,r,i){i.x=e+n/2,i.y=t+r/2,i.width=n,i.height=r},arrow:function(e,t,n,r,i){i.x=e+n/2,i.y=t+r/2,i.width=n,i.height=r},triangle:function(e,t,n,r,i){i.cx=e+n/2,i.cy=t+r/2,i.width=n,i.height=r}},ex={};z(Qb,function(e,t){ex[t]=new e});var tx=Jl.extend({type:`symbol`,shape:{symbolType:``,x:0,y:0,width:0,height:0},calculateTextPosition:function(e,t,n){var r=ja(e,t,n),i=this.shape;return i&&i.symbolType===`pin`&&t.position===`inside`&&(r.y=n.y+n.height*.4),r},buildPath:function(e,t,n){var r=t.symbolType;if(r!==`none`){var i=ex[r];i||=(r=`rect`,ex[r]),$b[r](t.x,t.y,t.width,t.height,i.shape),i.buildPath(e,i.shape,n)}}});function nx(e,t){if(this.type!==`image`){var n=this.style;this.__isEmptyBrush?(n.stroke=e,n.fill=t||Q.color.neutral00,n.lineWidth=2):this.shape.symbolType===`line`?n.stroke=e:n.fill=e,this.markRedraw()}}function rx(e,t,n,r,i,a,o){var s=e.indexOf(`empty`)===0;s&&(e=e.substr(5,1).toLowerCase()+e.substr(6));var c=e.indexOf(`image://`)===0?Fp(e.slice(8),new Y(t,n,r,i),o?`center`:`cover`):e.indexOf(`path://`)===0?Pp(e.slice(7),{},new Y(t,n,r,i),o?`center`:`cover`):new tx({shape:{symbolType:e,x:t,y:n,width:r,height:i}});return c.__isEmptyBrush=s,c.setColor=nx,a&&c.setColor(a),c}function ix(e){return U(e)||(e=[+e,+e]),[e[0]||0,e[1]||0]}function ax(e,t){if(e!=null)return U(e)||(e=[e,e]),[yo(e[0],t[0])||0,yo(q(e[1],e[0]),t[1])||0]}function ox(e){return isFinite(e)}function sx(e,t,n){var r=t.x==null?0:t.x,i=t.x2==null?1:t.x2,a=t.y==null?0:t.y,o=t.y2==null?0:t.y2;return t.global||(r=r*n.width+n.x,i=i*n.width+n.x,a=a*n.height+n.y,o=o*n.height+n.y),r=ox(r)?r:0,i=ox(i)?i:1,a=ox(a)?a:0,o=ox(o)?o:0,e.createLinearGradient(r,a,i,o)}function cx(e,t,n){var r=n.width,i=n.height,a=Math.min(r,i),o=t.x==null?.5:t.x,s=t.y==null?.5:t.y,c=t.r==null?.5:t.r;return t.global||(o=o*r+n.x,s=s*i+n.y,c*=a),o=ox(o)?o:.5,s=ox(s)?s:.5,c=c>=0&&ox(c)?c:.5,e.createRadialGradient(o,s,0,o,s,c)}function lx(e,t,n){for(var r=t.type===`radial`?cx(e,t,n):sx(e,t,n),i=t.colorStops,a=0;a<i.length;a++)r.addColorStop(i[a].offset,i[a].color);return r}function ux(e,t){if(e===t||!e&&!t)return!1;if(!e||!t||e.length!==t.length)return!0;for(var n=0;n<e.length;n++)if(e[n]!==t[n])return!0;return!1}function dx(e){return parseInt(e,10)}function fx(e,t,n){var r=[`width`,`height`][t],i=[`clientWidth`,`clientHeight`][t],a=[`paddingLeft`,`paddingTop`][t],o=[`paddingRight`,`paddingBottom`][t];if(n[r]!=null&&n[r]!==`auto`)return parseFloat(n[r]);var s=document.defaultView.getComputedStyle(e);return(e[i]||dx(s[r])||dx(e.style[r]))-(dx(s[a])||0)-(dx(s[o])||0)||0}function px(e,t){return!e||e===`solid`||!(t>0)?null:e===`dashed`?[4*t,2*t]:e===`dotted`?[t]:je(e)?[e]:U(e)?e:null}function mx(e){var t=e.style,n=t.lineDash&&t.lineWidth>0&&px(t.lineDash,t.lineWidth),r=t.lineDashOffset;if(n){var i=t.strokeNoScale&&e.getLineScale?e.getLineScale():1;i&&i!==1&&(n=B(n,function(e){return e/i}),r/=i)}return[n,r]}var hx=new Cl(!0);function gx(e){var t=e.stroke;return!(t==null||t===`none`||!(e.lineWidth>0))}function _x(e){return typeof e==`string`&&e!==`none`}function vx(e){var t=e.fill;return t!=null&&t!==`none`}function yx(e,t){if(t.fillOpacity!=null&&t.fillOpacity!==1){var n=e.globalAlpha;e.globalAlpha=t.fillOpacity*t.opacity,e.fill(),e.globalAlpha=n}else e.fill()}function bx(e,t){if(t.strokeOpacity!=null&&t.strokeOpacity!==1){var n=e.globalAlpha;e.globalAlpha=t.strokeOpacity*t.opacity,e.stroke(),e.globalAlpha=n}else e.stroke()}function xx(e,t,n){var r=dc(t.image,t.__image,n);if(pc(r)){var i=e.createPattern(r,t.repeat||`repeat`);if(typeof DOMMatrix==`function`&&i&&i.setTransform){var a=new DOMMatrix;a.translateSelf(t.x||0,t.y||0),a.rotateSelf(0,0,(t.rotation||0)*nt),a.scaleSelf(t.scaleX||1,t.scaleY||1),i.setTransform(a)}return i}}function Sx(e,t,n,r,i){var a,o=gx(n),s=vx(n),c=n.strokePercent,l=c<1,u=!t.path;(!t.silent||l)&&u&&t.createPathProxy();var d=t.path||hx,f=t.__dirty;if(!r){var p=n.fill,m=n.stroke,h=s&&!!p.colorStops,g=o&&!!m.colorStops,_=s&&!!p.image,v=o&&!!m.image,y=void 0,b=void 0,x=void 0,S=void 0,C=void 0;(h||g)&&(C=t.getBoundingRect()),h&&(y=f?lx(e,p,C):t.__canvasFillGradient,t.__canvasFillGradient=y),g&&(b=f?lx(e,m,C):t.__canvasStrokeGradient,t.__canvasStrokeGradient=b),_&&(x=f||!t.__canvasFillPattern?xx(e,p,t):t.__canvasFillPattern,t.__canvasFillPattern=x),v&&(S=f||!t.__canvasStrokePattern?xx(e,m,t):t.__canvasStrokePattern,t.__canvasStrokePattern=S),h?e.fillStyle=y:_&&(x?e.fillStyle=x:s=!1),g?e.strokeStyle=b:v&&(S?e.strokeStyle=S:o=!1)}var w=t.getGlobalScale();d.setScale(w[0],w[1],t.segmentIgnoreThreshold);var T,E;e.setLineDash&&n.lineDash&&(a=mx(t),T=a[0],E=a[1]);var D=!0;(u||f&4)&&(d.setDPR(e.dpr),l?d.setContext(null):(d.setContext(e),D=!1),d.reset(),t.buildPath(d,t.shape,r),d.toStatic(),t.pathUpdated()),D&&d.rebuildPath(e,l?c:1),T&&(e.setLineDash(T),e.lineDashOffset=E),r?(i.batchFill=s,i.batchStroke=o):n.strokeFirst?(o&&bx(e,n),s&&yx(e,n)):(s&&yx(e,n),o&&bx(e,n)),T&&e.setLineDash([])}function Cx(e,t,n){var r=t.__image=dc(n.image,t.__image,t,t.onload);if(!(!r||!pc(r))){var i=n.x||0,a=n.y||0,o=t.getWidth(),s=t.getHeight(),c=r.width/r.height;if(o==null&&s!=null?o=s*c:s==null&&o!=null?s=o/c:o==null&&s==null&&(o=r.width,s=r.height),n.sWidth&&n.sHeight){var l=n.sx||0,u=n.sy||0;e.drawImage(r,l,u,n.sWidth,n.sHeight,i,a,o,s)}else if(n.sx&&n.sy){var l=n.sx,u=n.sy,d=o-l,f=s-u;e.drawImage(r,l,u,d,f,i,a,o,s)}else e.drawImage(r,i,a,o,s)}}function Tx(e,t,n){var r,i=n.text;if(i!=null&&(i+=``),i){e.font=n.font||`12px sans-serif`,e.textAlign=n.textAlign,e.textBaseline=n.textBaseline;var a=void 0,o=void 0;e.setLineDash&&n.lineDash&&(r=mx(t),a=r[0],o=r[1]),a&&(e.setLineDash(a),e.lineDashOffset=o),n.strokeFirst?(gx(n)&&e.strokeText(i,n.x,n.y),vx(n)&&e.fillText(i,n.x,n.y)):(vx(n)&&e.fillText(i,n.x,n.y),gx(n)&&e.strokeText(i,n.x,n.y)),a&&e.setLineDash([])}}var Ex=[`shadowBlur`,`shadowOffsetX`,`shadowOffsetY`],Dx=[[`lineCap`,`butt`],[`lineJoin`,`miter`],[`miterLimit`,10]];function Ox(e,t,n,r,i){var a=!1;if(!r&&(n||={},t===n))return!1;if(r||t.opacity!==n.opacity){zx(e,i),a=!0;var o=Math.max(Math.min(t.opacity,1),0);e.globalAlpha=isNaN(o)?Lc.opacity:o}(r||t.blend!==n.blend)&&(a||=(zx(e,i),!0),e.globalCompositeOperation=t.blend||Lc.blend);for(var s=0;s<Ex.length;s++){var c=Ex[s];(r||t[c]!==n[c])&&(a||=(zx(e,i),!0),e[c]=e.dpr*(t[c]||0))}return(r||t.shadowColor!==n.shadowColor)&&(a||=(zx(e,i),!0),e.shadowColor=t.shadowColor||Lc.shadowColor),a}function kx(e,t,n,r,i){var a=t.style,o=r?null:n&&n.style||{};if(a===o)return!1;var s=Ox(e,a,o,r,i);if((r||a.fill!==o.fill)&&(s||=(zx(e,i),!0),_x(a.fill)&&(e.fillStyle=a.fill)),(r||a.stroke!==o.stroke)&&(s||=(zx(e,i),!0),_x(a.stroke)&&(e.strokeStyle=a.stroke)),(r||a.opacity!==o.opacity)&&(s||=(zx(e,i),!0),e.globalAlpha=a.opacity==null?1:a.opacity),t.hasStroke()){var c=a.lineWidth/(a.strokeNoScale&&t.getLineScale?t.getLineScale():1);e.lineWidth!==c&&(s||=(zx(e,i),!0),e.lineWidth=c)}for(var l=0;l<Dx.length;l++){var u=Dx[l],d=u[0];(r||a[d]!==o[d])&&(s||=(zx(e,i),!0),e[d]=a[d]||u[1])}return s}function Ax(e,t,n,r,i){return Ox(e,t.style,n&&n.style,r,i)}function jx(e,t){var n=t.transform,r=e.dpr||1;n?e.setTransform(r*n[0],r*n[1],r*n[2],r*n[3],r*n[4],r*n[5]):e.setTransform(r,0,0,r,0,0)}function Mx(e,t,n){for(var r=!1,i=0;i<e.length;i++){var a=e[i];r||=a.isZeroArea(),jx(t,a),t.beginPath(),a.buildPath(t,a.shape),t.clip()}n.allClipped=r}function Nx(e,t){return e&&t?e[0]!==t[0]||e[1]!==t[1]||e[2]!==t[2]||e[3]!==t[3]||e[4]!==t[4]||e[5]!==t[5]:!(!e&&!t)}var Px=1,Fx=2,Ix=3,Lx=4;function Rx(e){var t=vx(e),n=gx(e);return!(e.lineDash||!(t^+n)||t&&typeof e.fill!=`string`||n&&typeof e.stroke!=`string`||e.strokePercent<1||e.strokeOpacity<1||e.fillOpacity<1)}function zx(e,t){t.batchFill&&(t.batchFill=!1,e.fill()),t.batchStroke&&(t.batchStroke=!1,e.stroke())}function Bx(e,t){var n={inHover:!1,viewWidth:0,viewHeight:0,beforeBrushParam:{}};Vx(e,t,n),Hx(e,n)}function Vx(e,t,n){var r=t.transform;if(!t.shouldBePainted(n.viewWidth,n.viewHeight,!1,!1)){t.__dirty&=-2,t.__isRendered=!1;return}var i=t.__clipPaths,a=n.prevElClipPaths,o=t.style,s=!1,c=!1;if((!a||ux(i,a))&&(a&&(zx(e,n),e.restore(),c=s=!0,n.prevElClipPaths=null,n.allClipped=!1,n.prevEl=null),i&&i.length&&(zx(e,n),e.save(),Mx(i,e,n),s=!0,n.prevElClipPaths=i)),n.allClipped){t.__dirty&=-2,t.__isRendered=!1;return}t.beforeBrush&&t.beforeBrush(n.beforeBrushParam),t.innerBeforeBrush();var l=n.prevEl;l||(c=s=!0);var u=t instanceof Jl&&t.autoBatch&&Rx(o);s||Nx(r,l.transform)?(zx(e,n),jx(e,t)):u||zx(e,n),t instanceof Jl?(n.lastDrawType!==Px&&(c=!0,n.lastDrawType=Px),kx(e,t,l,c,n),(!u||!n.batchFill&&!n.batchStroke)&&e.beginPath(),Sx(e,t,o,u,n)):t instanceof Xl?(n.lastDrawType!==Ix&&(c=!0,n.lastDrawType=Ix),kx(e,t,l,c,n),Tx(e,t,o)):t instanceof eu?(n.lastDrawType!==Fx&&(c=!0,n.lastDrawType=Fx),Ax(e,t,l,c,n),Cx(e,t,o)):t.getTemporalDisplayables&&(n.lastDrawType!==Lx&&(c=!0,n.lastDrawType=Lx),Ux(e,t,n)),t.innerAfterBrush(),t.afterBrush&&(u&&zx(e,n),t.afterBrush()),n.prevEl=t,t.__dirty=0,t.__isRendered=!0}function Hx(e,t){zx(e,t),t.prevElClipPaths&&e.restore()}function Ux(e,t,n){var r=t.getDisplayables(),i=t.getTemporalDisplayables();e.save();var a={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:n.viewWidth,viewHeight:n.viewHeight,inHover:n.inHover,beforeBrushParam:{}},o,s;for(o=t.getCursor(),s=r.length;o<s;o++){var c=r[o];c.beforeBrush&&c.beforeBrush(n.beforeBrushParam),c.innerBeforeBrush(),Vx(e,c,a),c.innerAfterBrush(),c.afterBrush&&c.afterBrush(),a.prevEl=c}Hx(e,a);for(var l=0,u=i.length;l<u;l++){var c=i[l];c.beforeBrush&&c.beforeBrush(n.beforeBrushParam),c.innerBeforeBrush(),Vx(e,c,a),c.innerAfterBrush(),c.afterBrush&&c.afterBrush(),a.prevEl=c}Hx(e,a),t.clearTemporalDisplayables(),t.notClear=!0,e.restore()}var Wx=new Xb,Gx=new Rr(100),Kx=[`symbol`,`symbolSize`,`symbolKeepAspect`,`color`,`backgroundColor`,`dashArrayX`,`dashArrayY`,`maxTileWidth`,`maxTileHeight`];function qx(e,t){if(e===`none`)return null;var n=t.getDevicePixelRatio(),r=t.getZr(),i=r.painter.type===`svg`;e.dirty&&Wx.delete(e);var a=Wx.get(e);if(a)return a;var o=L(e,{symbol:`rect`,symbolSize:1,symbolKeepAspect:!0,color:`rgba(0, 0, 0, 0.2)`,backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});o.backgroundColor===`none`&&(o.backgroundColor=null);var s={repeat:`repeat`};return c(s),s.rotation=o.rotation,s.scaleX=s.scaleY=i?1:1/n,Wx.set(e,s),e.dirty=!1,s;function c(e){for(var t=[n],a=!0,s=0;s<Kx.length;++s){var c=o[Kx[s]];if(c!=null&&!U(c)&&!G(c)&&!je(c)&&typeof c!=`boolean`){a=!1;break}t.push(c)}var l;if(a){l=t.join(`,`)+(i?`-svg`:``);var u=Gx.get(l);u&&(i?e.svgElement=u:e.image=u)}var d=Yx(o.dashArrayX),f=Xx(o.dashArrayY),p=Jx(o.symbol),m=Zx(d),h=Qx(f),g=!i&&M.createCanvas(),_=i&&{tag:`g`,attrs:{},key:`dcl`,children:[]},v=b(),y;g&&(g.width=v.width*n,g.height=v.height*n,y=g.getContext(`2d`)),x(),a&&Gx.put(l,g||_),e.image=g,e.svgElement=_,e.svgWidth=v.width,e.svgHeight=v.height;function b(){for(var e=1,t=0,n=m.length;t<n;++t)e=Bo(e,m[t]);for(var r=1,t=0,n=p.length;t<n;++t)r=Bo(r,p[t].length);e*=r;var i=h*m.length*p.length;return{width:Math.max(1,Math.min(e,o.maxTileWidth)),height:Math.max(1,Math.min(i,o.maxTileHeight))}}function x(){y&&(y.clearRect(0,0,g.width,g.height),o.backgroundColor&&(y.fillStyle=o.backgroundColor,y.fillRect(0,0,g.width,g.height)));for(var e=0,t=0;t<f.length;++t)e+=f[t];if(e<=0)return;for(var a=-h,s=0,c=0,l=0;a<v.height;){if(s%2==0){for(var u=c/2%p.length,m=0,b=0,x=0;m<v.width*2;){for(var S=0,t=0;t<d[l].length;++t)S+=d[l][t];if(S<=0)break;if(b%2==0){var C=(1-o.symbolSize)*.5,w=m+d[l][b]*C,T=a+f[s]*C,E=d[l][b]*o.symbolSize,D=f[s]*o.symbolSize,O=x/2%p[u].length;k(w,T,E,D,p[u][O])}m+=d[l][b],++x,++b,b===d[l].length&&(b=0)}++l,l===d.length&&(l=0)}a+=f[s],++c,++s,s===f.length&&(s=0)}function k(e,t,a,s,c){var l=i?1:n,u=rx(c,e*l,t*l,a*l,s*l,o.color,o.symbolKeepAspect);if(i){var d=r.painter.renderOneToVNode(u);d&&_.children.push(d)}else Bx(y,u)}}}}function Jx(e){if(!e||e.length===0)return[[`rect`]];if(G(e))return[[e]];for(var t=!0,n=0;n<e.length;++n)if(!G(e[n])){t=!1;break}if(t)return Jx([e]);for(var r=[],n=0;n<e.length;++n)G(e[n])?r.push([e[n]]):r.push(e[n]);return r}function Yx(e){if(!e||e.length===0)return[[0,0]];if(je(e)){var t=Math.ceil(e);return[[t,t]]}for(var n=!0,r=0;r<e.length;++r)if(!je(e[r])){n=!1;break}if(n)return Yx([e]);for(var i=[],r=0;r<e.length;++r)if(je(e[r])){var t=Math.ceil(e[r]);i.push([t,t])}else{var t=B(e[r],function(e){return Math.ceil(e)});t.length%2==1?i.push(t.concat(t)):i.push(t)}return i}function Xx(e){if(!e||typeof e==`object`&&e.length===0)return[0,0];if(je(e)){var t=Math.ceil(e);return[t,t]}var n=B(e,function(e){return Math.ceil(e)});return e.length%2?n.concat(n):n}function Zx(e){return B(e,function(e){return Qx(e)})}function Qx(e){for(var t=0,n=0;n<e.length;++n)t+=e[n];return e.length%2==1?t*2:t}var $x=Gs(eS);function eS(e,t){e.eachRawSeries(function(n){if(!e.isSeriesFiltered(n)){var r=n.getData();r.hasItemVisual()&&r.each(function(e){var n=r.getItemVisual(e,`decal`);if(n){var i=r.ensureUniqueItemVisual(e,`style`);i.decal=qx(n,t)}});var i=r.getVisual(`decal`);if(i){var a=r.getVisual(`style`);a.decal=qx(i,t)}}})}var tS=1,nS=800,rS=900,iS=920,aS=1e3,oS=2e3,sS=5e3,cS=1e3,lS=1100,uS=2e3,dS=3e3,fS=4e3,pS=4500,mS=4600,hS=5e3,gS=6e3,_S=7e3,vS={PROCESSOR:{SERIES_FILTER:nS,AXIS_STATISTICS:iS,FILTER:aS,STATISTIC:sS,STATISTICS:sS},VISUAL:{LAYOUT:cS,PROGRESSIVE_LAYOUT:lS,GLOBAL:uS,CHART:dS,POST_CHART_LAYOUT:mS,COMPONENT:fS,BRUSH:hS,CHART_ITEM:pS,ARIA:gS,DECAL:_S}},yS=`__flagInMainProcess`,bS=`__mainProcessVersion`,xS=`__pendingUpdate`,SS=`__needsUpdateStatus`,CS=/^[a-zA-Z0-9_]+$/,wS=`__connectUpdateStatus`,TS=0,ES=1,DS=2;function OS(e){return function(){var t=[...arguments];if(this.isDisposed()){this.id;return}return AS(this,e,t)}}function kS(e){return function(){var t=[...arguments];return AS(this,e,t)}}function AS(e,t,n){return n[0]=n[0]&&n[0].toLowerCase(),wt.prototype[t].apply(e,n)}var jS=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t}(wt),MS=jS.prototype;MS.on=kS(`on`),MS.off=kS(`off`);var NS,PS,FS,IS,LS,RS,zS,BS,VS,HS,US,WS,GS,KS,qS,JS,YS,XS,ZS,QS=function(e){k(t,e);function t(t,n,r){var i=e.call(this,new Db)||this;i._chartsViews=[],i._chartsMap={},i._componentsViews=[],i._componentsMap={},i._pendingActions=[],r||={},i.__v_skip=!0,i._dom=t;var a=`canvas`,o=`auto`,s=!1;i[bS]=1,r.ssr;var c=i._zr=to(t,{renderer:r.renderer||a,devicePixelRatio:r.devicePixelRatio,width:r.width,height:r.height,ssr:r.ssr,useDirtyRect:q(r.useDirtyRect,s),useCoarsePointer:q(r.useCoarsePointer,o),pointerSize:r.pointerSize});i._ssr=r.ssr,i._throttledZrFlush=Jy(V(c.flush,c),17),i._updateTheme(n),i._locale=oh(r.locale||ih),i._coordSysMgr=new sg;var l=i._api=qS(i);function u(e,t){return e.__prio-t.__prio}return tr(oC,u),tr(iC,u),i._scheduler=new cb(i,l,iC,oC),i._messageCenter=new jS,i._initEvents(),i.resize=V(i.resize,i),c.animation.on(`frame`,i._onframe,i),HS(c,i),US(c,i),Ge(i),i}return t.prototype._onframe=function(){if(!this._disposed){var e=this._scheduler,t=this._model,n=this._api;if(XS(this),this[xS]){var r=this[xS].silent;this[yS]=!0,ZS(this);try{NS(this),IS.update.call(this,null,this[xS].updateParams)}catch(e){throw this[yS]=!1,this[xS]=null,e}this._zr.flush(),this[yS]=!1,this[xS]=null,BS.call(this,r),VS.call(this,r)}else if(e.unfinished){var i=tS;do{e.unfinished=!1;var a=M.getTime();e.performSeriesTasks(t),e.performDataProcessorTasks(t),RS(this,t),e.performVisualTasks(t),KS(this,this._model,n,`remain`,{}),i-=M.getTime()-a}while(i>0&&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,t,n){if(!this[yS]){if(this._disposed){this.id;return}var r,i,a;if(K(t)&&(n=t.lazyUpdate,r=t.silent,i=t.replaceMerge,a=t.transition,t=t.notMerge),this[yS]=!0,ZS(this),!this._model||t){var o=new f_(this._api),s=this._theme,c=this._model=new a_;c.scheduler=this._scheduler,c.ssr=this._ssr,c.init(null,null,null,s,this._locale,o)}this._model.setOption(e,{replaceMerge:i},aC);var l={seriesTransition:a,optionChanged:!0};if(n)this[xS]={silent:r,updateParams:l},this[yS]=!1,this.getZr().wakeUp();else{try{NS(this),IS.update.call(this,null,l)}catch(e){throw this[xS]=null,this[yS]=!1,e}this._ssr||this._zr.flush(),this[xS]=null,this[yS]=!1,BS.call(this,r),VS.call(this,r)}}},t.prototype.setTheme=function(e,t){if(!this[yS]){if(this._disposed){this.id;return}var n=this._model;if(n){var r=t&&t.silent,i=null;this[xS]&&(r??=this[xS].silent,i=this[xS].updateParams,this[xS]=null),this[yS]=!0,ZS(this);try{this._updateTheme(e),n.setTheme(this._theme),NS(this),IS.update.call(this,{type:`setTheme`},i)}catch(e){throw this[yS]=!1,e}this[yS]=!1,BS.call(this,r),VS.call(this,r)}}},t.prototype._updateTheme=function(e){G(e)&&(e=sC[e]),e&&(e=P(e),e&&B_(e,!0),this._theme=e)},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||j.hasGlobalWindow&&window.devicePixelRatio||1},t.prototype.getRenderedCanvas=function(e){return this.renderToCanvas(e)},t.prototype.renderToCanvas=function(e){return e||={},this._zr.painter.getRenderedCanvas({backgroundColor:e.backgroundColor||this._model.get(`backgroundColor`),pixelRatio:e.pixelRatio||this.getDevicePixelRatio()})},t.prototype.renderToSVGString=function(e){return e||={},this._zr.painter.renderToString({useViewBox:e.useViewBox})},t.prototype.getSvgDataURL=function(){var e=this._zr;return z(e.storage.getDisplayList(),function(e){e.stopAnimation(null,!0)}),e.painter.toDataURL()},t.prototype.getDataURL=function(e){if(this._disposed){this.id;return}e||={};var t=e.excludeComponents,n=this._model,r=[],i=this;z(t,function(e){n.eachComponent({mainType:e},function(e){var t=i._componentsMap[e.__viewId];t.group.ignore||(r.push(t),t.group.ignore=!0)})});var a=this._zr.painter.getType()===`svg`?this.getSvgDataURL():this.renderToCanvas(e).toDataURL(`image/`+(e&&e.type||`png`));return z(r,function(e){e.group.ignore=!1}),a},t.prototype.getConnectedDataURL=function(e){if(this._disposed){this.id;return}var t=e.type===`svg`,n=this.group,r=Math.min,i=Math.max,a=1/0;if(uC[n]){var o=a,s=a,c=-a,l=-a,u=[],d=e&&e.pixelRatio||this.getDevicePixelRatio();z(lC,function(a,d){if(a.group===n){var f=t?a.getZr().painter.getSvgDom().innerHTML:a.renderToCanvas(P(e)),p=a.getDom().getBoundingClientRect();o=r(p.left,o),s=r(p.top,s),c=i(p.right,c),l=i(p.bottom,l),u.push({dom:f,left:p.left,top:p.top})}}),o*=d,s*=d,c*=d,l*=d;var f=c-o,p=l-s,m=M.createCanvas(),h=to(m,{renderer:t?`svg`:`canvas`});if(h.resize({width:f,height:p}),t){var g=``;return z(u,function(e){var t=e.left-o,n=e.top-s;g+=`<g transform="translate(`+t+`,`+n+`)">`+e.dom+`</g>`}),h.painter.getSvgRoot().innerHTML=g,e.connectedBackgroundColor&&h.painter.setBackgroundColor(e.connectedBackgroundColor),h.refreshImmediately(),h.painter.toDataURL()}else return e.connectedBackgroundColor&&h.add(new cu({shape:{x:0,y:0,width:f,height:p},style:{fill:e.connectedBackgroundColor}})),z(u,function(e){var t=new eu({style:{x:e.left*d-o,y:e.top*d-s,image:e.dom}});h.add(t)}),h.refreshImmediately(),m.toDataURL(`image/`+(e&&e.type||`png`))}else return this.getDataURL(e)},t.prototype.convertToPixel=function(e,t,n){return LS(this,`convertToPixel`,e,t,n)},t.prototype.convertToLayout=function(e,t,n){return LS(this,`convertToLayout`,e,t,n)},t.prototype.convertFromPixel=function(e,t,n){return LS(this,`convertFromPixel`,e,t,n)},t.prototype.containPixel=function(e,t){if(this._disposed){this.id;return}var n=this._model,r;return z(ys(n,e),function(e,n){n.indexOf(`Models`)>=0&&z(e,function(e){var i=e.coordinateSystem;if(i&&i.containPoint)r||=!!i.containPoint(t);else if(n===`seriesModels`){var a=this._chartsMap[e.__viewId];a&&a.containPoint&&(r||=a.containPoint(t,e))}},this)},this),!!r},t.prototype.getVisual=function(e,t){var n=this._model,r=ys(n,e,{defaultMainType:`series`}),i=r.seriesModel.getData(),a=r.hasOwnProperty(`dataIndexInside`)?r.dataIndexInside:r.hasOwnProperty(`dataIndex`)?i.indexOfRawIndex(r.dataIndex):null;return a==null?Nb(i,t):Mb(i,a,t)},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;z(eC,function(t){var n=function(n){var r=e.getModel(),i=n.target,a;if(t===`globalout`?a={}:i&&Ib(i,function(e){var t=Du(e);if(t&&t.dataIndex!=null){var n=t.dataModel||r.getSeriesByIndex(t.seriesIndex);return a=n&&n.getDataParams(t.dataIndex,t.dataType,i)||{},!0}else if(t.eventData)return a=I({},t.eventData),!0},!0),a){var o=a.componentType,s=a.componentIndex;(o===`markLine`||o===`markPoint`||o===`markArea`)&&(o=`series`,s=a.seriesIndex);var c=o&&s!=null&&r.getComponent(o,s),l=c&&e[c.mainType===`series`?`_chartsMap`:`_componentsMap`][c.__viewId];a.event=n,a.type=t,e._$eventProcessor.eventInfo={targetEl:i,packedEvent:a,model:c,view:l},e.trigger(t,a)}};n.zrEventfulCallAtLast=!0,e._zr.on(t,n,e)});var t=this._messageCenter;z(rC,function(n,r){t.on(r,function(t){e.trigger(r,t)})}),Fb(t,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,this.getDom()&&Ts(this.getDom(),fC,``);var e=this,t=e._api,n=e._model;z(e._componentsViews,function(e){e.dispose(n,t)}),z(e._chartsViews,function(e){e.dispose(n,t)}),e._zr.dispose(),e._dom=e._model=e._chartsMap=e._componentsMap=e._chartsViews=e._componentsViews=e._scheduler=e._api=e._zr=e._throttledZrFlush=e._theme=e._coordSysMgr=e._messageCenter=null,delete lC[e.id]},t.prototype.resize=function(e){if(!this[yS]){if(this._disposed){this.id;return}this._zr.resize(e);var t=this._model;if(this._loadingFX&&this._loadingFX.resize(),t){var n=t.resetOption(`media`),r=e&&e.silent;this[xS]&&(r??=this[xS].silent,n=!0,this[xS]=null),this[yS]=!0,ZS(this);try{n&&NS(this),IS.update.call(this,{type:`resize`,animation:I({duration:0},e&&e.animation)})}catch(e){throw this[yS]=!1,e}this[yS]=!1,BS.call(this,r),VS.call(this,r)}}},t.prototype.showLoading=function(e,t){if(this._disposed){this.id;return}if(K(e)&&(t=e,e=``),e||=`default`,this.hideLoading(),cC[e]){var n=cC[e](this._api,t),r=this._zr;this._loadingFX=n,r.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 t=I({},e);return t.type=nC[e.type],t},t.prototype.dispatchAction=function(e,t){if(this._disposed){this.id;return}if(K(t)||(t={silent:!!t}),tC[e.type]&&this._model){if(this[yS]){this._pendingActions.push(e);return}var n=t.silent;zS.call(this,e,n);var r=t.flush;r?this._zr.flush():r!==!1&&j.browser.weChat&&this._throttledZrFlush(),BS.call(this,n),VS.call(this,n)}},t.prototype.updateLabelLayout=function(){Lb.trigger(`series:layoutlabels`,this._model,this._api,{updatedSeries:[]})},t.prototype.appendData=function(e){if(this._disposed){this.id;return}var t=e.seriesIndex;this.getModel().getSeriesByIndex(t).appendData(e),this._scheduler.unfinished=!0,this.getZr().wakeUp()},t.internalField=function(){NS=function(e){Wb(e._model);var t=e._scheduler;t.restorePipelines(e._zr,e._model),t.prepareStageTasks(),PS(e,!0),PS(e,!1),t.plan()},PS=function(e,t){for(var n=e._model,r=e._scheduler,i=t?e._componentsViews:e._chartsViews,a=t?e._componentsMap:e._chartsMap,o=e._zr,s=e._api,c=0;c<i.length;c++)i[c].__alive=!1;t?n.eachComponent(function(e,t){e!==`series`&&l(t)}):n.eachSeries(l);function l(e){var c=e.__requireNewView;e.__requireNewView=!1;var l=`_ec_`+e.id+`_`+e.type,u=!c&&a[l];if(!u){var d=Ys(e.type);u=new(t?Fy.getClass(d.main,d.sub):zy.getClass(d.sub)),u.init(n,s),a[l]=u,i.push(u),o.add(u.group)}e.__viewId=u.__id=l,u.__alive=!0,u.__model=e,u.group.__ecComponentInfo={mainType:e.mainType,index:e.componentIndex},!t&&r.prepareView(u,e,n,s)}for(var c=0;c<i.length;){var u=i[c];u.__alive?c++:(!t&&u.renderTask.dispose(),o.remove(u.group),u.dispose(n,s),i.splice(c,1),a[u.__id]===u&&delete a[u.__id],u.__id=u.group.__ecComponentInfo=null)}},FS=function(e,t,n,r,i){var a=e._model;if(a.setUpdatePayload(n),!r){z([].concat(e._componentsViews,e._chartsViews),l);return}var o=ws(n,r,i),s=n.excludeSeriesId,c;s!=null&&(c=J(),z(Zo(s),function(e){var t=ds(e,null);t!=null&&c.set(t,!0)})),a&&a.eachComponent(o,function(t){if(!(c&&c.get(t.id)!=null))if(Gd(n))if(t instanceof Ey)n.type===`highlight`&&!n.notBlur&&!t.get([`emphasis`,`disabled`])&&Dd(t,n,e._api);else{var r=Od(t.mainType,t.componentIndex,n.name,e._api),i=r.focusSelf,a=r.dispatchers;n.type===`highlight`&&i&&!n.notBlur&&Ed(t.mainType,t.componentIndex,e._api),a&&z(a,function(e){n.type===`highlight`?_d(e):vd(e)})}else Wd(n)&&t instanceof Ey&&(jd(t,n,e._api),Md(t),YS(e))},e),a&&a.eachComponent(o,function(t){c&&c.get(t.id)!=null||l(e[r===`series`?`_chartsMap`:`_componentsMap`][t.__viewId])},e);function l(r){r&&r.__alive&&r[t]&&r[t](r.__model,a,e._api,n)}},IS={prepareAndUpdate:function(e){NS(this),IS.update.call(this,e,e&&{optionChanged:e.newOption!=null})},update:function(e,n){var r=this._model,i=this._api,a=this._zr,o=this._coordSysMgr,s=this._scheduler;if(r){Gb(r),r.setUpdatePayload(e),s.restoreData(r,e),s.performSeriesTasks(r),o.create(r,i),Lb.trigger(`coordsys:aftercreate`,r,i),s.performDataProcessorTasks(r,e),RS(this,r),o.update(r,i),t(r),s.performVisualTasks(r,e);var c=r.get(`backgroundColor`)||`transparent`;a.setBackgroundColor(c);var l=r.get(`darkMode`);l!=null&&l!==`auto`&&a.setDarkMode(l),WS(this,r,i,e,n),Lb.trigger(`afterupdate`,r,i)}},updateTransform:function(e){var t=this,n=t._model,r=t._api;if(n){n.setUpdatePayload(e);var i=[];n.eachComponent(function(a,o){if(a!==`series`){var s=t.getViewOfComponentModel(o);if(s&&s.__alive)if(s.updateTransform){var c=s.updateTransform(o,n,r,e);c&&c.update&&i.push(s)}else i.push(s)}});var a=J();n.eachSeries(function(i){var o=t._chartsMap[i.__viewId],s=i.pipelineContext;if(o.updateTransform&&!s.progressiveRender){var c=o.updateTransform(i,n,r,e);c&&c.update&&a.set(i.uid,1)}else a.set(i.uid,1)}),t._scheduler.performVisualTasks(n,e,{setDirty:!0,dirtyMap:a}),KS(t,n,r,e,{},a),Lb.trigger(`afterupdate`,n,r)}},updateView:function(e){var n=this._model;n&&(n.setUpdatePayload(e),zy.markUpdateMethod(e,`updateView`),t(n),this._scheduler.performVisualTasks(n,e,{setDirty:!0}),WS(this,n,this._api,e,{}),Lb.trigger(`afterupdate`,n,this._api))},updateVisual:function(e){var n=this,r=this._model;r&&(r.setUpdatePayload(e),r.eachSeries(function(e){e.getData().clearAllVisual()}),zy.markUpdateMethod(e,`updateVisual`),t(r),this._scheduler.performVisualTasks(r,e,{visualType:`visual`,setDirty:!0}),r.eachComponent(function(t,i){if(t!==`series`){var a=n.getViewOfComponentModel(i);a&&a.__alive&&a.updateVisual(i,r,n._api,e)}}),r.eachSeries(function(t){n._chartsMap[t.__viewId].updateVisual(t,r,n._api,e)}),Lb.trigger(`afterupdate`,r,this._api))},updateLayout:function(e){IS.update.call(this,e)}};function e(e,t,n,r,i){if(e._disposed){e.id;return}for(var a=e._model,o=e._coordSysMgr.getCoordinateSystems(),s,c=ys(a,n),l=0;l<o.length;l++){var u=o[l];if(u[t]&&(s=u[t](a,c,r,i))!=null)return s}}LS=e,RS=function(e,t){var n=e._chartsMap,r=e._scheduler;t.eachSeries(function(e){r.updateStreamModes(e,n[e.__viewId])})},zS=function(e,t){var n=this,r=this.getModel(),i=e.type,a=e.escapeConnect,o=tC[i],s=(o.update||`update`).split(`:`),c=s.pop(),l=s[0]!=null&&Ys(s[0]);this[yS]=!0,ZS(this);var u=[e],d=!1;e.batch&&(d=!0,u=B(e.batch,function(t){return t=L(I({},t),e),t.batch=null,t}));var f=[],p,m=[],h=o.nonRefinedEventType,g=Wd(e),_=Gd(e);if(_&&wd(this._api),z(u,function(t){var i=o.action(t,r,n._api);if(o.refineEvent?m.push(i):p=i,p||=I({},t),p.type=h,f.push(p),_){var a=bs(e),s=a.queryOptionMap,u=a.mainTypeSpecified?s.keys()[0]:`series`;FS(n,c,t,u),YS(n)}else g?(FS(n,c,t,`series`),YS(n)):l&&FS(n,c,t,l.main,l.sub)}),c!==`none`&&!_&&!g&&!l)try{this[xS]?(NS(this),IS.update.call(this,e),this[xS]=null):IS[c].call(this,e)}catch(e){throw this[yS]=!1,e}if(p=d?{type:h,escapeConnect:a,batch:f}:f[0],this[yS]=!1,!t){var v=void 0;if(o.refineEvent){var y=o.refineEvent(m,e,r,this._api).eventContent;He(K(y)),v=L({type:o.refinedEventType},y),v.fromAction=e.type,v.fromActionPayload=e,v.escapeConnect=!0}var b=this._messageCenter;b.trigger(p.type,p),v&&b.trigger(v.type,v)}},BS=function(e){for(var t=this._pendingActions;t.length;){var n=t.shift();zS.call(this,n,e)}},VS=function(e){!e&&this.trigger(`updated`)},HS=function(e,t){e.on(`rendered`,function(n){t.trigger(`rendered`,n),e.animation.isFinished()&&!t[xS]&&!t._scheduler.unfinished&&!t._pendingActions.length?t.trigger(`finished`):e.refresh()})},US=function(e,t){e.on(`mouseover`,function(e){var n=e.target,r=Ib(n,Hd);r&&(kd(r,e,t._api),YS(t))}).on(`mouseout`,function(e){var n=e.target,r=Ib(n,Hd);r&&(Ad(r,e,t._api),YS(t))}).on(`click`,function(e){var n=e.target,r=Ib(n,function(e){return Du(e).dataIndex!=null},!0);if(r){var i=r.selected?`unselect`:`select`,a=Du(r);t._api.dispatchAction({type:i,dataType:a.dataType,dataIndexInside:a.dataIndex,seriesIndex:a.seriesIndex,isFromClick:!0})}})};function t(e){e.clearColorPalette(),e.eachSeries(function(e){e.clearColorPalette()})}function n(e){var t=[],n=[],r=!1;if(e.eachComponent(function(e,i){var a=i.get(`zlevel`)||0,o=i.get(`z`)||0,s=i.getZLevelKey();r||=!!s,(e===`series`?n:t).push({zlevel:a,z:o,idx:i.componentIndex,type:e,key:s})}),r){var i=t.concat(n),a,o;tr(i,function(e,t){return e.zlevel===t.zlevel?e.z-t.z:e.zlevel-t.zlevel}),z(i,function(t){var n=e.getComponent(t.type,t.idx),r=t.zlevel,i=t.key;a!=null&&(r=Math.max(a,r)),i?(r===a&&i!==o&&r++,o=i):o&&=(r===a&&r++,``),a=r,n.setZLevel(r)})}}WS=function(e,t,r,i,a){n(t),GS(e,t,r,i,a),z(e._chartsViews,function(e){e.__alive=!1}),KS(e,t,r,i,a),z(e._chartsViews,function(e){e.__alive||e.remove(t,r)})},GS=function(e,t,n,r,i,a){z(a||e._componentsViews,function(e){var i=e.__model;s(i,e),e.render(i,t,n,r),o(i,e),c(i,e)})},KS=function(e,t,n,r,l,u){var d=e._scheduler;l=I(l||{},{updatedSeries:t.getSeries()}),Lb.trigger(`series:beforeupdate`,t,n,l);var f=!1;t.eachSeries(function(t){var n=e._chartsMap[t.__viewId];n.__alive=!0;var i=n.renderTask;d.updatePayload(i,r),s(t,n),u&&u.get(t.uid)&&i.dirty(),i.perform(d.getPerformArgs(i))&&(f=!0),n.group.silent=!!t.get(`silent`),a(t,n),Md(t)}),d.unfinished=f||d.unfinished,Lb.trigger(`series:layoutlabels`,t,n,l),Lb.trigger(`series:transition`,t,n,l),t.eachSeries(function(t){var n=e._chartsMap[t.__viewId];o(t,n),c(t,n)}),i(e,t),Lb.trigger(`series:afterupdate`,t,n,l)},YS=function(e){e[SS]=!0,e.getZr().wakeUp()},ZS=function(e){e[bS]=(e[bS]+1)%1e6},XS=function(e){e[SS]&&(e.getZr().storage.traverse(function(e){bp(e)||r(e)}),e[SS]=!1)};function r(e){for(var t=[],n=e.currentStates,r=0;r<n.length;r++){var i=n[r];i===`emphasis`||i===`blur`||i===`select`||t.push(i)}e.selected&&e.states.select&&t.push(`select`),e.hoverState===2&&e.states.emphasis?t.push(`emphasis`):e.hoverState===1&&e.states.blur&&t.push(`blur`),e.useStates(t)}function i(e,t){var n=e._zr;if(n.painter.type===`canvas`){var r=n.storage,i=0;r.traverse(function(e){e.isGroup||i++});var a=i>q(t.get(`hoverLayerThreshold`),Lg.hoverLayerThreshold)&&!j.node&&!j.worker;(e._usingTHL||a)&&(t.eachSeries(function(t){if(!t.preventUsingHoverLayer){var n=e._chartsMap[t.__viewId];n.__alive&&n.eachRendered(function(e){var t=e.states.emphasis;t&&t.hoverLayer!==2&&(t.hoverLayer=+!!a)})}}),e._usingTHL=a)}}function a(e,t){var n=e.get(`blendMode`)||null;t.eachRendered(function(e){e.isGroup||(e.style.blend=n)})}function o(e,t){if(!e.preventAutoZ){var n=dm(e);t.eachRendered(function(e){return pm(e,n.z,n.zlevel),!0})}}function s(e,t){t.eachRendered(function(e){if(!bp(e)){var t=e.getTextContent(),n=e.getTextGuideLine();e.stateTransition&&=null,t&&t.stateTransition&&(t.stateTransition=null),n&&n.stateTransition&&(n.stateTransition=null),e.hasState()?(e.prevStates=e.currentStates,e.clearStates()):e.prevStates&&=null}})}function c(e,t){var n=e.getModel(`stateAnimation`),i=e.isAnimationEnabled(),a=n.get(`duration`),o=a>0?{duration:a,delay:n.get(`delay`),easing:n.get(`easing`)}:null;t.eachRendered(function(e){if(e.states&&e.states.emphasis){if(bp(e))return;if(e instanceof Jl&&Kd(e),e.__dirty){var t=e.prevStates;t&&e.useStates(t)}if(i){e.stateTransition=o;var n=e.getTextContent(),a=e.getTextGuideLine();n&&(n.stateTransition=o),a&&(a.stateTransition=o)}e.__dirty&&r(e)}})}qS=function(e){return new(function(t){k(n,t);function n(){return t!==null&&t.apply(this,arguments)||this}return n.prototype.getCoordinateSystems=function(){return e._coordSysMgr.getCoordinateSystems()},n.prototype.getComponentByElement=function(t){for(;t;){var n=t.__ecComponentInfo;if(n!=null)return e._model.getComponent(n.mainType,n.index);t=t.parent}},n.prototype.enterEmphasis=function(t,n){_d(t,n),YS(e)},n.prototype.leaveEmphasis=function(t,n){vd(t,n),YS(e)},n.prototype.enterBlur=function(t){yd(t),YS(e)},n.prototype.leaveBlur=function(t){bd(t),YS(e)},n.prototype.enterSelect=function(t){xd(t),YS(e)},n.prototype.leaveSelect=function(t){Sd(t),YS(e)},n.prototype.getModel=function(){return e.getModel()},n.prototype.getViewOfComponentModel=function(t){return e.getViewOfComponentModel(t)},n.prototype.getViewOfSeriesModel=function(t){return e.getViewOfSeriesModel(t)},n.prototype.getECUpdateCycleVersion=function(){return e[bS]},n.prototype.usingTHL=function(){return e._usingTHL},n}(Ru))(e)},JS=function(e){function t(e,t){for(var n=0;n<e.length;n++){var r=e[n];r[wS]=t}}z(nC,function(n,r){e._messageCenter.on(r,function(n){if(uC[e.group]&&e[wS]!==TS){if(n&&n.escapeConnect)return;var r=e.makeActionFromEvent(n),i=[];z(lC,function(t){t!==e&&t.group===e.group&&i.push(t)}),t(i,TS),z(i,function(e){e[wS]!==ES&&e.dispatchAction(r)}),t(i,DS)}})})}}(),t}(wt),$S=QS.prototype;$S.on=OS(`on`),$S.off=OS(`off`),$S.one=function(e,t,n){var r=this;function i(){var n=[...arguments];t&&t.apply&&t.apply(this,n),r.off(e,i)}this.on.call(this,e,i,n)};var eC=[`click`,`dblclick`,`mouseover`,`mouseout`,`mousemove`,`mousedown`,`mouseup`,`globalout`,`contextmenu`],tC={},nC={},rC={},iC=[],aC=[],oC=[],sC={},cC={},lC={},uC={},dC=new Date-0;new Date-0;var fC=`_echarts_instance_`;function pC(e,t,n){var r=!(n&&n.ssr);if(r){var i=mC(e);if(i)return i}var a=new QS(e,t,n);return a.id=`ec_`+ dC++,lC[a.id]=a,r&&Ts(e,fC,a.id),JS(a),Lb.trigger(`afterinit`,a),a}function mC(e){return lC[Es(e,fC)]}function hC(e,t){sC[e]=t}function gC(e){R(aC,e)<0&&aC.push(e)}function _C(e,t){EC(iC,e,t,oS)}function vC(e){bC(`afterinit`,e)}function yC(e){bC(`afterupdate`,e)}function bC(e,t){Lb.on(e,t)}function xC(e,t,n){var r,i,a,o,s;W(t)&&(n=t,t=``),K(e)?(r=e.type,i=e.event,o=e.update,s=e.publishNonRefinedEvent,n||=e.action,a=e.refineEvent):(r=e,i=t);function c(e){return e.toLowerCase()}i=c(i||r);var l=a?c(r):i;tC[r]||(He(CS.test(r)&&CS.test(i)),a&&He(i!==r),tC[r]={actionType:r,refinedEventType:i,nonRefinedEventType:l,update:o,action:n,refineEvent:a},rC[i]=1,a&&s&&(rC[l]=1),nC[l]=r)}function SC(e,t){sg.register(e,t)}function CC(e,t){EC(oC,e,t,cS,`layout`,!0)}function wC(e,t){EC(oC,e,t,dS,`visual`,!0)}var TC=[];function EC(e,t,n,r,i,a){if((W(t)||K(t))&&(n=t,t=r),!(R(TC,n)>=0)){TC.push(n);var o=cb.wrapStageHandler(n,i);o.__prio=t,o.__raw=n,e.push(o)}}function DC(e,t){cC[e]=t}function OC(e,t,n){var r=Bb(`registerMap`);r&&r(e,t,n)}var kC=Rv;wC(uS,nb),wC(pS,ib),wC(pS,ab),wC(uS,Ab),wC(pS,jb),wC(_S,$x),gC(B_),_C(rS,V_),DC(`default`,sb),xC({type:Ku,event:Ku,update:Ku},tt),xC({type:qu,event:qu,update:qu},tt),xC({type:Ju,event:Zu,update:Ju,action:tt,refineEvent:AC,publishNonRefinedEvent:!0}),xC({type:Yu,event:Zu,update:Yu,action:tt,refineEvent:AC,publishNonRefinedEvent:!0}),xC({type:Xu,event:Zu,update:Xu,action:tt,refineEvent:AC,publishNonRefinedEvent:!0});function AC(e,t,n,r){return{eventContent:{selected:Nd(n),isFromClick:t.isFromClick||!1}}}hC(`default`,{}),hC(`dark`,Eb);function jC(e){return e==null?0:e.length||1}function MC(e){return e}var NC=function(){function e(e,t,n,r,i,a){this._old=e,this._new=t,this._oldKeyGetter=n||MC,this._newKeyGetter=r||MC,this.context=i,this._diffModeMultiple=a===`multiple`}return e.prototype.add=function(e){return this._add=e,this},e.prototype.update=function(e){return this._update=e,this},e.prototype.updateManyToOne=function(e){return this._updateManyToOne=e,this},e.prototype.updateOneToMany=function(e){return this._updateOneToMany=e,this},e.prototype.updateManyToMany=function(e){return this._updateManyToMany=e,this},e.prototype.remove=function(e){return this._remove=e,this},e.prototype.execute=function(){this[this._diffModeMultiple?`_executeMultiple`:`_executeOneToOne`]()},e.prototype._executeOneToOne=function(){var e=this._old,t=this._new,n={},r=Array(e.length),i=Array(t.length);this._initIndexMap(e,null,r,`_oldKeyGetter`),this._initIndexMap(t,n,i,`_newKeyGetter`);for(var a=0;a<e.length;a++){var o=r[a],s=n[o],c=jC(s);if(c>1){var l=s.shift();s.length===1&&(n[o]=s[0]),this._update&&this._update(l,a)}else c===1?(n[o]=null,this._update&&this._update(s,a)):this._remove&&this._remove(a)}this._performRestAdd(i,n)},e.prototype._executeMultiple=function(){var e=this._old,t=this._new,n={},r={},i=[],a=[];this._initIndexMap(e,n,i,`_oldKeyGetter`),this._initIndexMap(t,r,a,`_newKeyGetter`);for(var o=0;o<i.length;o++){var s=i[o],c=n[s],l=r[s],u=jC(c),d=jC(l);if(u>1&&d===1)this._updateManyToOne&&this._updateManyToOne(l,c),r[s]=null;else if(u===1&&d>1)this._updateOneToMany&&this._updateOneToMany(l,c),r[s]=null;else if(u===1&&d===1)this._update&&this._update(l,c),r[s]=null;else if(u>1&&d>1)this._updateManyToMany&&this._updateManyToMany(l,c),r[s]=null;else if(u>1)for(var f=0;f<u;f++)this._remove&&this._remove(c[f]);else this._remove&&this._remove(c)}this._performRestAdd(a,r)},e.prototype._performRestAdd=function(e,t){for(var n=0;n<e.length;n++){var r=e[n],i=t[r],a=jC(i);if(a>1)for(var o=0;o<a;o++)this._add&&this._add(i[o]);else a===1&&this._add&&this._add(i);t[r]=null}},e.prototype._initIndexMap=function(e,t,n,r){for(var i=this._diffModeMultiple,a=0;a<e.length;a++){var o=`_ec_`+this[r](e[a],a);if(i||(n[a]=o),t){var s=t[o],c=jC(s);c===0?(t[o]=a,i&&n.push(o)):c===1?t[o]=[s,a]:s.push(a)}}},e}(),PC=function(){function e(e,t){this._encode=e,this._schema=t}return e.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},e.prototype._getFullDimensionNames=function(){return this._cachedDimNames||=this._schema?this._schema.makeOutputDimensionNames():[],this._cachedDimNames},e}();function FC(e,t){var n={},r=n.encode={},i=J(),a=[],o=[],s={};z(e.dimensions,function(t){var n=e.getDimensionInfo(t),c=n.coordDim;if(c){var l=n.coordDimIndex;IC(r,c)[l]=t,n.isExtraCoord||(i.set(c,1),RC(n.type)&&(a[0]=t),IC(s,c)[l]=e.getDimensionIndex(n.name)),n.defaultTooltip&&o.push(t)}ku.each(function(e,t){var i=IC(r,t),a=n.otherDims[t];a!=null&&a!==!1&&(i[a]=n.name)})});var c=[],l={};i.each(function(e,t){var n=r[t];l[t]=n[0],c=c.concat(n)}),n.dataDimsOnCoord=c,n.dataDimIndicesOnCoord=B(c,function(t){return e.getDimensionInfo(t).storeDimIndex}),n.encodeFirstDimNotExtra=l;var u=r.label;u&&u.length&&(a=u.slice());var d=r.tooltip;return d&&d.length?o=d.slice():o.length||(o=a.slice()),r.defaultedLabel=a,r.defaultedTooltip=o,n.userOutput=new PC(s,t),n}function IC(e,t){return e.hasOwnProperty(t)||(e[t]=[]),e[t]}function LC(e){return e===`category`?`ordinal`:e===`time`?`time`:`float`}function RC(e){return!(e===`ordinal`||e===`time`)}var zC=function(){function e(e){this.otherDims={},e!=null&&I(this,e)}return e}(),BC=Z(),VC={float:`f`,int:`i`,ordinal:`o`,number:`n`,time:`t`},HC=function(){function e(e){this.dimensions=e.dimensions,this._dimOmitted=e.dimensionOmitted,this.source=e.source,this._fullDimCount=e.fullDimensionCount,this._updateDimOmitted(e.dimensionOmitted)}return e.prototype.isDimensionOmitted=function(){return this._dimOmitted},e.prototype._updateDimOmitted=function(e){this._dimOmitted=e,e&&(this._dimNameMap||=GC(this.source))},e.prototype.getSourceDimensionIndex=function(e){return q(this._dimNameMap.get(e),-1)},e.prototype.getSourceDimension=function(e){var t=this.source.dimensionsDefine;if(t)return t[e]},e.prototype.makeStoreSchema=function(){for(var e=this._fullDimCount,t=ev(this.source),n=!KC(e),r=``,i=[],a=0,o=0;a<e;a++){var s=void 0,c=void 0,l=void 0,u=this.dimensions[o];if(u&&u.storeDimIndex===a)s=t?u.name:null,c=u.type,l=u.ordinalMeta,o++;else{var d=this.getSourceDimension(a);d&&(s=t?d.name:null,c=d.type)}i.push({property:s,type:c,ordinalMeta:l}),t&&s!=null&&(!u||!u.isCalculationCoord)&&(r+=n?s.replace(/\`/g,"`1").replace(/\$/g,"`2"):s),r+=`$`,r+=VC[c]||`f`,l&&(r+=l.uid),r+=`$`}var f=this.source;return{dimensions:i,hash:[f.seriesLayoutBy,f.startIndex,r].join(`$$`)}},e.prototype.makeOutputDimensionNames=function(){for(var e=[],t=0,n=0;t<this._fullDimCount;t++){var r=void 0,i=this.dimensions[n];if(i&&i.storeDimIndex===t)i.isCalculationCoord||(r=i.name),n++;else{var a=this.getSourceDimension(t);a&&(r=a.name)}e.push(r)}return e},e.prototype.appendCalculationDimension=function(e){this.dimensions.push(e),e.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},e}();function UC(e){return e instanceof HC}function WC(e){for(var t=J(),n=0;n<(e||[]).length;n++){var r=e[n],i=K(r)?r.name:r;i!=null&&t.get(i)==null&&t.set(i,n)}return t}function GC(e){var t=BC(e);return t.dimNameMap||=WC(e.dimensionsDefine)}function KC(e){return e>30}var qC=K,JC=B,YC=typeof Int32Array>`u`?Array:Int32Array,XC=`e\0\0`,ZC=-1,QC=[`hasItemOption`,`_nameList`,`_idList`,`_invertedIndicesMap`,`_dimSummary`,`userOutput`,`_rawData`,`_dimValueGetter`,`_nameDimIdx`,`_idDimIdx`,`_nameRepeatCount`],$C=[`_approximateExtent`],ew,tw,nw,rw,iw,aw,ow,sw=function(){function e(e,t){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 n,r=!1;UC(e)?(n=e.dimensions,this._dimOmitted=e.isDimensionOmitted(),this._schema=e):(r=!0,n=e),n||=[`x`,`y`];for(var i={},a=[],o={},s=!1,c={},l=0;l<n.length;l++){var u=n[l],d=G(u)?new zC({name:u}):u instanceof zC?u:new zC(u),f=d.name;d.type=d.type||`float`,d.coordDim||(d.coordDim=f,d.coordDimIndex=0);var p=d.otherDims=d.otherDims||{};a.push(f),i[f]=d,c[f]!=null&&(s=!0),d.createInvertedIndices&&(o[f]=[]),r&&(d.storeDimIndex=l),p.itemName===0&&(this._nameDimIdx=d.storeDimIndex),p.itemId===0&&(this._idDimIdx=d.storeDimIndex)}if(this.dimensions=a,this._dimInfos=i,this._initGetDimensionInfo(s),this.hostModel=t,this._invertedIndicesMap=o,this._dimOmitted){var m=this._dimIdxToName=J();z(a,function(e){m.set(i[e].storeDimIndex,e)})}}return e.prototype.getDimension=function(e){var t=this._recognizeDimIndex(e);if(t==null)return e;if(t=e,!this._dimOmitted)return this.dimensions[t];var n=this._dimIdxToName.get(t);if(n!=null)return n;var r=this._schema.getSourceDimension(t);if(r)return r.name},e.prototype.getDimensionIndex=function(e){var t=this._recognizeDimIndex(e);if(t!=null)return t;if(e==null)return-1;var n=this._getDimInfo(e);return n?n.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(e):-1},e.prototype._recognizeDimIndex=function(e){if(je(e)||e!=null&&!isNaN(e)&&!this._getDimInfo(e)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(e)<0))return+e},e.prototype._getStoreDimIndex=function(e){return this.getDimensionIndex(e)},e.prototype.getDimensionInfo=function(e){return this._getDimInfo(this.getDimension(e))},e.prototype._initGetDimensionInfo=function(e){var t=this._dimInfos;this._getDimInfo=e?function(e){return t.hasOwnProperty(e)?t[e]:void 0}:function(e){return t[e]}},e.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},e.prototype.mapDimension=function(e,t){var n=this._dimSummary;if(t==null)return n.encodeFirstDimNotExtra[e];var r=n.encode[e];return r?r[t]:null},e.prototype.mapDimensionsAll=function(e){return(this._dimSummary.encode[e]||[]).slice()},e.prototype.getStore=function(){return this._store},e.prototype.initData=function(e,t,n){var r=this,i;if(e instanceof Zv&&(i=e),!i){var a=this.dimensions,o=G_(e)||we(e)?new sv(e,a.length):e;i=new Zv;var s=JC(a,function(e){return{type:r._dimInfos[e].type,property:e}});i.initData(o,s,n)}this._store=i,this._nameList=(t||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,i.count()),this._dimSummary=FC(this,this._schema),this.userOutput=this._dimSummary.userOutput},e.prototype.appendData=function(e){var t=this._store.appendData(e);this._doInit(t[0],t[1])},e.prototype.appendValues=function(e,t){var n=this._store.appendValues(e,t&&t.length),r=n.start,i=n.end,a=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),t)for(var o=r;o<i;o++){var s=o-r;this._nameList[o]=t[s],a&&ow(this,o)}},e.prototype._updateOrdinalMeta=function(){for(var e=this._store,t=this.dimensions,n=0;n<t.length;n++){var r=this._dimInfos[t[n]];r.ordinalMeta&&e.collectOrdinalMeta(r.storeDimIndex,r.ordinalMeta)}},e.prototype._shouldMakeIdFromName=function(){var e=this._store.getProvider();return this._idDimIdx==null&&e.getSource().sourceFormat!==`typedArray`&&!e.fillStorage},e.prototype._doInit=function(e,t){if(!(e>=t)){var n=this._store.getProvider();this._updateOrdinalMeta();var r=this._nameList,i=this._idList;if(n.getSource().sourceFormat===`original`&&!n.pure)for(var a=[],o=e;o<t;o++){var s=n.getItem(o,a);if(!this.hasItemOption&&ts(s)&&(this.hasItemOption=!0),s){var c=s.name;r[o]==null&&c!=null&&(r[o]=ds(c,null));var l=s.id;i[o]==null&&l!=null&&(i[o]=ds(l,null))}}if(this._shouldMakeIdFromName())for(var o=e;o<t;o++)ow(this,o);ew(this)}},e.prototype.getApproximateExtent=function(e,t){return this._approximateExtent[e]||this._store.getDataExtent(this._getStoreDimIndex(e),t)},e.prototype.setApproximateExtent=function(e,t){t=this.getDimension(t),this._approximateExtent[t]=e.slice()},e.prototype.getCalculationInfo=function(e){return this._calculationInfo[e]},e.prototype.setCalculationInfo=function(e,t){qC(e)?I(this._calculationInfo,e):this._calculationInfo[e]=t},e.prototype.getName=function(e){var t=this.getRawIndex(e),n=this._nameList[t];return n==null&&this._nameDimIdx!=null&&(n=nw(this,this._nameDimIdx,t)),n??=``,n},e.prototype._getCategory=function(e,t){var n=this._store.get(e,t),r=this._store.getOrdinalMeta(e);return r?r.categories[n]:n},e.prototype.getId=function(e){return tw(this,this.getRawIndex(e))},e.prototype.count=function(){return this._store.count()},e.prototype.get=function(e,t){var n=this._store,r=this._dimInfos[e];if(r)return n.get(r.storeDimIndex,t)},e.prototype.getByRawIndex=function(e,t){var n=this._store,r=this._dimInfos[e];if(r)return n.getByRawIndex(r.storeDimIndex,t)},e.prototype.getIndices=function(){return this._store.getIndices()},e.prototype.getDataExtent=function(e){return this._store.getDataExtent(this._getStoreDimIndex(e),null)},e.prototype.getSum=function(e){return this._store.getSum(this._getStoreDimIndex(e))},e.prototype.getMedian=function(e){return this._store.getMedian(this._getStoreDimIndex(e))},e.prototype.getValues=function(e,t){var n=this,r=this._store;return U(e)?r.getValues(JC(e,function(e){return n._getStoreDimIndex(e)}),t):r.getValues(e)},e.prototype.hasValue=function(e){for(var t=this._dimSummary.dataDimIndicesOnCoord,n=0,r=t.length;n<r;n++)if(isNaN(this._store.get(t[n],e)))return!1;return!0},e.prototype.indexOfName=function(e){for(var t=0,n=this._store.count();t<n;t++)if(this.getName(t)===e)return t;return-1},e.prototype.getRawIndex=function(e){return this._store.getRawIndex(e)},e.prototype.indexOfRawIndex=function(e){return this._store.indexOfRawIndex(e)},e.prototype.rawIndexOf=function(e,t){var n=e&&this._invertedIndicesMap[e],r=n&&n[t];return r==null||isNaN(r)?ZC:r},e.prototype.each=function(e,t,n){W(e)&&(n=t,t=e,e=[]);var r=n||this,i=JC(rw(e),this._getStoreDimIndex,this);this._store.each(i,r?V(t,r):t)},e.prototype.filterSelf=function(e,t,n){W(e)&&(n=t,t=e,e=[]);var r=n||this,i=JC(rw(e),this._getStoreDimIndex,this);return this._store=this._store.filter(i,r?V(t,r):t),this},e.prototype.selectRange=function(e){var t=this,n={},r=Oe(e),i=[];return z(r,function(r){var a=t._getStoreDimIndex(r);n[a]=e[r],i.push(a)}),this._store=this._store.selectRange(n),this},e.prototype.mapArray=function(e,t,n){W(e)&&(n=t,t=e,e=[]),n||=this;var r=[];return this.each(e,function(){r.push(t&&t.apply(this,arguments))},n),r},e.prototype.map=function(e,t,n,r){var i=n||r||this,a=JC(rw(e),this._getStoreDimIndex,this),o=aw(this);return o._store=this._store.map(a,i?V(t,i):t),o},e.prototype.modify=function(e,t,n,r){var i=n||r||this,a=JC(rw(e),this._getStoreDimIndex,this);this._store.modify(a,i?V(t,i):t)},e.prototype.downSample=function(e,t,n,r){var i=aw(this);return i._store=this._store.downSample(this._getStoreDimIndex(e),t,n,r),i},e.prototype.minmaxDownSample=function(e,t){var n=aw(this);return n._store=this._store.minmaxDownSample(this._getStoreDimIndex(e),t),n},e.prototype.lttbDownSample=function(e,t){var n=aw(this);return n._store=this._store.lttbDownSample(this._getStoreDimIndex(e),t),n},e.prototype.getRawDataItem=function(e){return this._store.getRawDataItem(e)},e.prototype.getItemModel=function(e){var t=this.hostModel;return new Gm(this.getRawDataItem(e),t,t&&t.ecModel)},e.prototype.diff=function(e){var t=this;return new NC(e?e.getStore().getIndices():[],this.getStore().getIndices(),function(t){return tw(e,t)},function(e){return tw(t,e)})},e.prototype.getVisual=function(e){var t=this._visual;return t&&t[e]},e.prototype.setVisual=function(e,t){this._visual=this._visual||{},qC(e)?I(this._visual,e):this._visual[e]=t},e.prototype.getItemVisual=function(e,t){var n=this._itemVisuals[e];return(n&&n[t])??this.getVisual(t)},e.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},e.prototype.ensureUniqueItemVisual=function(e,t){var n=this._itemVisuals,r=n[e];r||=n[e]={};var i=r[t];return i??(i=this.getVisual(t),U(i)?i=i.slice():qC(i)&&(i=I({},i)),r[t]=i),i},e.prototype.setItemVisual=function(e,t,n){var r=this._itemVisuals[e]||{};this._itemVisuals[e]=r,qC(t)?I(r,t):r[t]=n},e.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},e.prototype.setLayout=function(e,t){qC(e)?I(this._layout,e):this._layout[e]=t},e.prototype.getLayout=function(e){return this._layout[e]},e.prototype.getItemLayout=function(e){return this._itemLayouts[e]},e.prototype.setItemLayout=function(e,t,n){this._itemLayouts[e]=n?I(this._itemLayouts[e]||{},t):t},e.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},e.prototype.setItemGraphicEl=function(e,t){Ou(this.hostModel&&this.hostModel.seriesIndex,this.dataType,e,t),this._graphicEls[e]=t},e.prototype.getItemGraphicEl=function(e){return this._graphicEls[e]},e.prototype.eachItemGraphicEl=function(e,t){z(this._graphicEls,function(n,r){n&&e&&e.call(t,n,r)})},e.prototype.cloneShallow=function(t){return t||=new e(this._schema?this._schema:JC(this.dimensions,this._getDimInfo,this),this.hostModel),iw(t,this),t._store=this._store,t},e.prototype.wrapMethod=function(e,t){var n=this[e];W(n)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(e),this[e]=function(){var e=n.apply(this,arguments);return t.apply(this,[e].concat(Be(arguments)))})},e.internalField=function(){ew=function(e){var t=e._invertedIndicesMap;z(t,function(n,r){var i=e._dimInfos[r],a=i.ordinalMeta,o=e._store;if(a){n=t[r]=new YC(a.categories.length);for(var s=0;s<n.length;s++)n[s]=ZC;for(var s=0;s<o.count();s++)n[o.get(i.storeDimIndex,s)]=s}})},nw=function(e,t,n){return ds(e._getCategory(t,n),null)},tw=function(e,t){var n=e._idList[t];return n==null&&e._idDimIdx!=null&&(n=nw(e,e._idDimIdx,t)),n??=XC+t,n},rw=function(e){return U(e)||(e=e==null?[]:[e]),e},aw=function(t){var n=new e(t._schema?t._schema:JC(t.dimensions,t._getDimInfo,t),t.hostModel);return iw(n,t),n},iw=function(e,t){z(QC.concat(t.__wrappedMethods||[]),function(n){t.hasOwnProperty(n)&&(e[n]=t[n])}),e.__wrappedMethods=t.__wrappedMethods,z($C,function(n){e[n]=P(t[n])}),e._calculationInfo=I({},t._calculationInfo)},ow=function(e,t){var n=e._nameList,r=e._idList,i=e._nameDimIdx,a=e._idDimIdx,o=n[t],s=r[t];if(o==null&&i!=null&&(n[t]=o=nw(e,i,t)),s==null&&a!=null&&(r[t]=s=nw(e,a,t)),s==null&&o!=null){var c=e._nameRepeatCount,l=c[o]=(c[o]||0)+1;s=o,l>1&&(s+=`__ec__`+l),r[t]=s}}}(),e}();function cw(e,t){G_(e)||(e=q_(e)),t||={};var n=t.coordDimensions||[],r=t.dimensionsDefine||e.dimensionsDefine||[],i=J(),a=[],o=lw(e,n,r,t.dimensionsCount),s=t.canOmitUnusedDimensions&&KC(o),c=r===e.dimensionsDefine,l=c?GC(e):WC(r),u=t.encodeDefine;!u&&t.encodeDefaulter&&(u=t.encodeDefaulter(e,o));for(var d=J(u),f=new Wv(o),p=0;p<f.length;p++)f[p]=-1;function m(e){var t=f[e];if(t<0){var n=r[e],i=K(n)?n:{name:n},o=new zC,s=i.name;return s!=null&&l.get(s)!=null&&(o.name=o.displayName=s),i.type!=null&&(o.type=i.type),i.displayName!=null&&(o.displayName=i.displayName),f[e]=a.length,o.storeDimIndex=e,a.push(o),o}return a[t]}if(!s)for(var p=0;p<o;p++)m(p);d.each(function(e,t){var n=Zo(e).slice();if(n.length===1&&!G(n[0])&&n[0]<0){d.set(t,!1);return}var r=d.set(t,[]);z(n,function(e,n){var i=G(e)?l.get(e):e;i!=null&&i<o&&(r[n]=i,g(m(i),t,n))})});var h=0;z(n,function(e){var t,n,r,i;if(G(e))t=e,i={};else{i=e,t=i.name;var a=i.ordinalMeta;i.ordinalMeta=null,i=I({},i),i.ordinalMeta=a,n=i.dimsDef,r=i.otherDims,i.name=i.coordDim=i.coordDimIndex=i.dimsDef=i.otherDims=null}var s=d.get(t);if(s!==!1){if(s=Zo(s),!s.length)for(var l=0;l<(n&&n.length||1);l++){for(;h<o&&m(h).coordDim!=null;)h++;h<o&&s.push(h++)}z(s,function(e,a){var o=m(e);if(c&&i.type!=null&&(o.type=i.type),g(L(o,i),t,a),o.name==null&&n){var s=n[a];!K(s)&&(s={name:s}),o.name=o.displayName=s.name,o.defaultTooltip=s.defaultTooltip}r&&L(o.otherDims,r)})}});function g(e,t,n){ku.get(t)==null?(e.coordDim=t,e.coordDimIndex=n,i.set(t,!0)):e.otherDims[t]=n}var _=t.generateCoord,v=t.generateCoordCount,y=v!=null;v=_?v||1:0;var b=_||`value`;function x(e){e.name??=e.coordDim}if(s)z(a,function(e){x(e)}),a.sort(function(e,t){return e.storeDimIndex-t.storeDimIndex});else for(var S=0;S<o;S++){var C=m(S);C.coordDim??(C.coordDim=uw(b,i,y),C.coordDimIndex=0,(!_||v<=0)&&(C.isExtraCoord=!0),v--),x(C),C.type==null&&(Wg(e,S)===Rg.Must||C.isExtraCoord&&(C.otherDims.itemName!=null||C.otherDims.seriesName!=null))&&(C.type=`ordinal`)}return Bs(a,function(e){return e.name},function(e,t){t>0&&(e.name+=t-1)}),new HC({source:e,dimensions:a,fullDimensionCount:o,dimensionOmitted:s})}function lw(e,t,n,r){var i=Math.max(e.dimensionsDetectedCount||1,t.length,n.length,r||0);return z(t,function(e){var t;K(e)&&(t=e.dimsDef)&&(i=Math.max(i,t.length))}),i}function uw(e,t,n){if(n||t.hasKey(e)){for(var r=0;t.hasKey(e+r);)r++;e+=r}return t.set(e,!0),e}var dw=function(){function e(e){this.coordSysDims=[],this.axisMap=J(),this.categoryAxisMap=J(),this.coordSysName=e}return e}();function fw(e){var t=e.get(`coordinateSystem`),n=new dw(t),r=pw[t];if(r)return r(e,n,n.axisMap,n.categoryAxisMap),n}var pw={cartesian2d:function(e,t,n,r){var i=e.getReferringComponents(`xAxis`,xs).models[0],a=e.getReferringComponents(`yAxis`,xs).models[0];t.coordSysDims=[`x`,`y`],n.set(`x`,i),n.set(`y`,a),mw(i)&&(r.set(`x`,i),t.firstCategoryDimIndex=0),mw(a)&&(r.set(`y`,a),t.firstCategoryDimIndex??=1)},singleAxis:function(e,t,n,r){var i=e.getReferringComponents(`singleAxis`,xs).models[0];t.coordSysDims=[`single`],n.set(`single`,i),mw(i)&&(r.set(`single`,i),t.firstCategoryDimIndex=0)},polar:function(e,t,n,r){var i=e.getReferringComponents(`polar`,xs).models[0],a=i.findAxisModel(`radiusAxis`),o=i.findAxisModel(`angleAxis`);t.coordSysDims=[`radius`,`angle`],n.set(`radius`,a),n.set(`angle`,o),mw(a)&&(r.set(`radius`,a),t.firstCategoryDimIndex=0),mw(o)&&(r.set(`angle`,o),t.firstCategoryDimIndex??=1)},geo:function(e,t,n,r){t.coordSysDims=[`lng`,`lat`]},parallel:function(e,t,n,r){var i=e.ecModel,a=i.getComponent(`parallel`,e.get(`parallelIndex`)),o=t.coordSysDims=a.dimensions.slice();z(a.parallelAxisIndex,function(e,a){var s=i.getComponent(`parallelAxis`,e),c=o[a];n.set(c,s),mw(s)&&(r.set(c,s),t.firstCategoryDimIndex??=a)})},matrix:function(e,t,n,r){var i=e.getReferringComponents(`matrix`,xs).models[0];t.coordSysDims=[`x`,`y`];var a=i.getDimensionModel(`x`),o=i.getDimensionModel(`y`);n.set(`x`,a),n.set(`y`,o),r.set(`x`,a),r.set(`y`,o)}};function mw(e){return e.get(`type`)===`category`}function hw(e,t,n){n||={};var r=n.byIndex,i=n.stackedCoordDimension,a,o,s;gw(t)?a=t:(o=t.schema,a=o.dimensions,s=t.store);var c=!!(e&&e.get(`stack`)),l,u,d,f,p=!0;function m(e){return e.type!==`ordinal`&&e.type!==`time`}if(z(a,function(e,t){G(e)&&(a[t]=e={name:e}),m(e)||(p=!1)}),z(a,function(e,t){c&&!e.isExtraCoord&&(!r&&!l&&e.ordinalMeta&&(l=e),!u&&m(e)&&(!p||e.coordDim!==`x`&&e.coordDim!==`angle`)&&(!i||i===e.coordDim)&&(u=e))}),u&&!r&&!l&&(r=!0),u){d=`__\0ecstackresult_`+e.id,f=`__\0ecstackedover_`+e.id,l&&(l.createInvertedIndices=!0);var h=u.coordDim,g=u.type,_=0;z(a,function(e){e.coordDim===h&&_++});var v={name:d,coordDim:h,coordDimIndex:_,type:g,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length},y={name:f,coordDim:f,coordDimIndex:_+1,type:g,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length+1};o?(s&&(v.storeDimIndex=s.ensureCalculationDimension(f,g),y.storeDimIndex=s.ensureCalculationDimension(d,g)),o.appendCalculationDimension(v),o.appendCalculationDimension(y)):(a.push(v),a.push(y))}return{stackedDimension:u&&u.name,stackedByDimension:l&&l.name,isStackedByIndex:r,stackedOverDimension:f,stackResultDimension:d}}function gw(e){return!UC(e.schema)}function _w(e,t){return!!t&&t===e.getCalculationInfo(`stackedDimension`)}function vw(e,t){return _w(e,t)?e.getCalculationInfo(`stackResultDimension`):t}function yw(e,t){var n=e.get(`coordinateSystem`),r=sg.get(n),i;return t&&t.coordSysDims&&(i=B(t.coordSysDims,function(e){var n={name:e},r=t.axisMap.get(e);return r&&(n.type=LC(r.get(`type`))),n})),i||=r&&(r.getDimensionsInfo?r.getDimensionsInfo():r.dimensions.slice())||[`x`,`y`],i}function bw(e,t,n){var r,i;return n&&z(e,function(e,a){var o=e.coordDim,s=n.categoryAxisMap.get(o);s&&(r??=a,e.ordinalMeta=s.getOrdinalMeta(),t&&(e.createInvertedIndices=!0)),e.otherDims.itemName!=null&&(i=!0)}),!i&&r!=null&&(e[r].otherDims.itemName=0),r}function xw(e,t,n){n||={};var r=t.getSourceManager(),i,a=!1;e?(a=!0,i=q_(e)):(i=r.getSource(),a=i.sourceFormat===Au);var o=fw(t),s=yw(t,o),c=n.useEncodeDefaulter,l=W(c)?c:c?H(Vg,s,t):null,u={coordDimensions:s,generateCoord:n.generateCoord,encodeDefine:t.getEncode(),encodeDefaulter:l,canOmitUnusedDimensions:!a},d=cw(i,u),f=bw(d.dimensions,n.createInvertedIndices,o),p=a?null:r.getSharedDataStore(d),m=hw(t,{schema:d,store:p}),h=new sw(d,t);h.setCalculationInfo(m);var g=f!=null&&Sw(i)?function(e,t,n,r){return r===f?n:this.defaultDimValueGetter(e,t,n,r)}:null;return h.hasItemOption=!1,h.initData(a?i:p,null,g),h}function Sw(e){if(e.sourceFormat===`original`)return!U(es(Cw(e.data||[])))}function Cw(e){for(var t=0;t<e.length&&e[t]==null;)t++;return e[t]}var ww=function(){function e(){}return e.prototype.isBlank=function(){return this._isBlank},e.prototype.setBlank=function(e){this._isBlank=e},e}();ac(ww);var Tw=0,Ew=function(){function e(e){this.categories=e.categories||[],this._needCollect=e.needCollect,this._deduplication=e.deduplication,this.uid=++Tw,this._onCollect=e.onCollect}return e.createByAxisModel=function(t){var n=t.option,r=n.data,i=r&&B(r,Dw);return new e({categories:i,needCollect:!i,deduplication:n.dedplication!==!1})},e.prototype.getOrdinal=function(e){return this._getOrCreateMap().get(e)},e.prototype.parseAndCollect=function(e){var t,n=this._needCollect;if(!G(e)&&!n)return e;if(n&&!this._deduplication)return t=this.categories.length,this.categories[t]=e,this._onCollect&&this._onCollect(e,t),t;var r=this._getOrCreateMap();return t=r.get(e),t??(n?(t=this.categories.length,this.categories[t]=e,r.set(e,t),this._onCollect&&this._onCollect(e,t)):t=NaN),t},e.prototype._getOrCreateMap=function(){return this._map||=J(this.categories)},e}();function Dw(e){return K(e)&&e.value!=null?e.value:e+``}var Ow=Oe({needTransform:1,normalize:1,scale:1,transformIn:1,transformOut:1,contain:1,getExtent:1,getExtentUnsafe:1,setExtent:1,setExtent2:1,getFilter:1,sanitize:1,getDefaultStartValue:1,freeze:1});function kw(e,t,n){var r;e||={};var i=uh();if(i){var a=i.createBreakScaleMapper(t,n);a.hasBreaks()&&(z(Ow,function(t){a[t]&&(e[t]=V(a[t],a))}),r=a)}return r??Iw(e,n),{brk:r,mapper:e}}function Aw(e,t){z(Ow,function(n){e[n]=t[n]})}function jw(e,t){e.freeze=tt}function Mw(e){return e.getExtentUnsafe(0,2)}function Nw(e,t){return e.getExtentUnsafe(1,t)||e.getExtentUnsafe(0,t)}function Pw(e){var t=Nw(e,3);return t[1]-t[0]}function Fw(e){var t=e.getExtentUnsafe(0,3);return t[1]-t[0]}function Iw(e,t){var n=e||{},r=[];return n._extents=r,r[0]=t?t.slice():ks(),I(n,Lw),n}var Lw={needTransform:function(){return!1},normalize:function(e){var t=this._extents[1]||this._extents[0];return t[1]===t[0]?.5:(e-t[0])/(t[1]-t[0])},scale:function(e){var t=this._extents[1]||this._extents[0];return e*(t[1]-t[0])+t[0]},transformIn:function(e){return e},transformOut:function(e){return e},contain:function(e){var t=Nw(this,null);return e>=t[0]&&e<=t[1]},getExtent:function(){return this._extents[0].slice()},getExtentUnsafe:function(e){return this._extents[e]},setExtent:function(e,t){Rw(this._extents,0,e,t)},setExtent2:function(e,t,n){var r=this._extents;r[e]||(r[e]=r[0].slice()),Rw(r,e,t,n)},freeze:function(){}};function Rw(e,t,n,r){Fs(n,r)&&(e[t][0]=n,e[t][1]=r)}function zw(e){return Bw(e)||Hw(e)}function Bw(e){return e.type===`interval`}function Vw(e){return e.type===`time`}function Hw(e){return e.type===`log`}function Uw(e){return e.type===`ordinal`}function Ww(e){var t=Po(e),n=po(10,t),r=lo(e/n);return r?r===2?r=3:r===3?r=5:r*=2:r=1,X(r*n,-t)}function Gw(e){return wo(e)+2}function Kw(e,t){return mo(e)/mo(t)}function qw(e,t,n){var r=n&&n.lookup;if(r){for(var i=0;i<r.from.length;i++)if(e===r.from[i])return r.to[i]}return po(t,e)}function Jw(e,t,n){var r=e.slice();if(r[0]===r[1]){var i=n&&n.ctnShp;if(r[0]!==0){var a=co(r[0]);t[1]||(r[1]+=a/2),r[0]-=a/2}else i&&(r[0]=-1),r[1]=1}return(!Ps(r[0])||!Ps(r[1]))&&(r[0]=0,r[1]=1),r[1]<r[0]&&r.reverse(),r}function Yw(e,t){return[e[0]!==t[0],e[1]!==t[1]]}function Xw(e,t){return e||=t,lo(so(e,1))}function Zw(e,t,n){var r=Mw(e),i=r[0],a=e.count(),o=Math.max((t||0)+1,1);i!==0&&o>1&&a/o>2&&(i=Math.round(Math.ceil(i/o)*o)),i!==r[0]&&c(r[0],!0,!0);for(var s=i;s<=r[1];s+=o)c(s,!1,s===r[0]||s===r[1]);s-o!==r[1]&&c(r[1],!0,!0);function c(e,t,r){n({value:e,offInterval:t},r)}}var Qw=function(e){k(t,e);function t(n){var r=e.call(this)||this;r.type=`ordinal`,r.parse=t.parse,Aw(r,t.decoratedMethods);var i=n.ordinalMeta;i||=new Ew({}),U(i)&&(i=new Ew({categories:B(i,function(e){return K(e)?e.value:e})})),r._ordinalMeta=i;var a=kw(null,null,n.extent||[0,i.categories.length-1]);return r._mapper=a.mapper,jw(r,a.mapper),r}return t.parse=function(e){return e==null?e=NaN:G(e)?(e=this._ordinalMeta.getOrdinal(e),e??=NaN):e=lo(e),e},t.prototype.getTicks=function(){var e=[];return Zw(this,0,function(t){e.push(t)}),e},t.prototype.getMinorTicks=function(e){},t.prototype.setSortInfo=function(e){if(e==null){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var t=e.ordinalNumbers,n=this._ordinalNumbersByTick=[],r=this._ticksByOrdinalNumber=[],i=0,a=this._ordinalMeta.categories.length,o=oo(a,t.length);i<o;++i){var s=n[i]=t[i];r[s]=i}for(var c=0;i<a;++i){for(;r[c]!=null;)c++;n[i]=c,r[c]=i}},t.prototype._getTickNumber=function(e){var t=this._ticksByOrdinalNumber;return t&&e>=0&&e<t.length?t[e]:e},t.prototype.getRawOrdinalNumber=function(e){var t=this._ordinalNumbersByTick;return t&&e>=0&&e<t.length?t[e]:e},t.prototype.getLabel=function(e){if(!this.isBlank()){var t=this.getRawOrdinalNumber(e.value),n=this._ordinalMeta.categories[t];return n==null?``:n+``}},t.prototype.count=function(){var e=Mw(this._mapper);return e[1]-e[0]+1},t.prototype.getOrdinalMeta=function(){return this._ordinalMeta},t.type=`ordinal`,t.decoratedMethods={needTransform:function(){return this._mapper.needTransform()},contain:function(e){return this._mapper.contain(this._getTickNumber(e))&&e>=0&&e<this._ordinalMeta.categories.length},normalize:function(e){return this._mapper.normalize(this._getTickNumber(e))},scale:function(e){return this.getRawOrdinalNumber(lo(this._mapper.scale(e)))},transformIn:function(e,t){return this._mapper.transformIn(this._getTickNumber(e),t)},transformOut:function(e,t){return this.getRawOrdinalNumber(this._mapper.transformOut(e,t))},getExtent:function(){return this._mapper.getExtent()},getExtentUnsafe:function(e,t){return this._mapper.getExtentUnsafe(e,t)},setExtent:function(e,t){return this._mapper.setExtent(e,t)},setExtent2:function(e,t,n){return this._mapper.setExtent2(e,t,n)}},t}(ww);ww.registerClass(Qw);function $w(e,t,n,r){for(var i=e.getTicks({expandToNicedExtent:!0}),a=[],o=e.getExtent(),s=1;s<i.length;s++){var c=i[s],l=i[s-1];if(!(l.break||c.break)){for(var u=0,d=[],f=(c.value-l.value)/t,p=Gw(f);u<t-1;){var m=X(l.value+(u+1)*f,p);m>o[0]&&m<o[1]&&d.push(m),u++}var h=uh();h&&h.pruneTicksByBreak(`auto`,d,n,function(e){return e},r,o),a.push(d)}}return a}var eT=function(e){k(t,e);function t(n){var r=e.call(this)||this;return r.type=`interval`,r.parse=t.parse,n||={},r.brk=kw(r,dh(r,n),null).brk,r._cfg={interval:0,intervalPrecision:2,intervalCount:void 0,niceExtent:void 0},r}return t.parse=function(e){return e==null||e===``?NaN:Number(e)},t.prototype.getConfig=function(){return P(this._cfg)},t.prototype.setConfig=function(e){var t=Mw(this);this._cfg=e=P(e),e.niceExtent??=t.slice(),e.intervalPrecision??=Gw(e.interval)},t.prototype.getTicks=function(e){e||={};var t=this._cfg,n=t.interval,r=Mw(this),i=t.niceExtent,a=t.intervalPrecision,o=uh(),s=this.brk,c=o&&s,l=[];if(!n)return l;if(e.breakTicks===`only_break`&&c)return o.addBreaksToTicks(l,s.breaks,r),l;var u=3e3;r[0]<i[0]&&l.push({value:e.expandToNicedExtent?X(i[0]-n,a):r[0]});for(var d=function(e,t){return lo((t-e)/n)},f=t.intervalCount,p=i[0],m=0;;m++){if(f==null){if(p>i[1]||!isFinite(p)||!isFinite(i[1]))break}else{if(m>f)break;p=oo(p,i[1]),m===f&&(p=i[1])}if(l.push({value:p}),p=X(p+n,a),s){var h=s.calcNiceTickMultiple(p,d);h>=0&&(p=X(p+h*n,a))}if(l.length>0&&p===l[l.length-1].value)break;if(l.length>u)return[]}var g=l.length?l[l.length-1].value:i[1];return r[1]>g&&l.push({value:e.expandToNicedExtent?X(g+n,a):r[1]}),c&&o.pruneTicksByBreak(e.pruneByBreak,l,s.breaks,function(e){return e.value},t.interval,r),c&&e.breakTicks!==`none`&&o.addBreaksToTicks(l,s.breaks,r),l},t.prototype.getMinorTicks=function(e){return $w(this,e,fh(this),this._cfg.interval)},t.prototype.getLabel=function(e,t){if(e==null)return``;var n=t&&t.precision;return n==null?n=wo(e.value)||0:n===`auto`&&(n=this._cfg.intervalPrecision),Xh(X(e.value,n,!0))},t.type=`interval`,t}(ww);ww.registerClass(eT);var tT=function(e,t,n,r){for(;n<r;){var i=n+r>>>1;e[i][1]<t?n=i+1:r=i}return n},nT=function(e){k(t,e);function t(n){var r=e.call(this)||this;return r.type=`time`,r.parse=t.parse,r._locale=n.locale,r._useUTC=n.useUTC,r._interval=0,r.brk=kw(r,dh(r,n),null).brk,r}return t.prototype.getLabel=function(e){return Mh(e.value,Ch[jh(kh(this._minLevelUnit))]||Ch.second,this._useUTC,this._locale)},t.prototype.getFormattedLabel=function(e,t,n){return Nh(e,t,n,this._locale,this._useUTC)},t.prototype.getTicks=function(e){e||={};var t=this._interval,n=Mw(this),r=uh(),i=this.brk,a=r&&i,o=[];if(!t)return o;var s=this._useUTC;if(a&&e.breakTicks===`only_break`)return uh().addBreaksToTicks(o,i.breaks,n),o;o=fT(this._minLevelUnit,this._approxInterval,s,n,Fw(this),i);var c=wh.length-1,l=0;return z(o,function(e){e.time&&(c=Math.min(c,R(wh,e.time.upperTimeUnit)),l=Math.max(l,e.time.level))}),a&&uh().pruneTicksByBreak(e.pruneByBreak,o,i.breaks,function(e){return e.value},this._approxInterval,n),a&&e.breakTicks!==`none`&&uh().addBreaksToTicks(o,i.breaks,n,function(e){for(var t=Math.max(R(wh,Ph(e.vmin,s)),R(wh,Ph(e.vmax,s))),n=0,r=0;r<wh.length;r++)if(!iT(wh[r],e.vmin,e.vmax,s)){n=r;break}var i=Math.min(n,c);return{level:l,lowerTimeUnit:wh[Math.max(i,t)],upperTimeUnit:wh[i]}}),o},t.prototype.getMinorTicks=function(e){return $w(this,e,fh(this),this._interval)},t.prototype.setTimeInterval=function(e){this._interval=e.interval,this._approxInterval=e.approxInterval,this._minLevelUnit=e.minLevelUnit},t.parse=function(e){return je(e)?Math.round(e):+Mo(e)},t.type=`time`,t}(ww),rT=[[`second`,mh],[`minute`,hh],[`hour`,gh],[`quarter-day`,gh*6],[`half-day`,gh*12],[`day`,_h*1.2],[`half-week`,_h*3.5],[`week`,_h*7],[`month`,_h*31],[`quarter`,_h*95],[`half-year`,vh/2],[`year`,vh]];function iT(e,t,n,r){return Fh(new Date(t),e,r).getTime()===Fh(new Date(n),e,r).getTime()}function aT(e,t){return e/=_h,e>16?16:e>7.5?7:e>3.5?4:e>1.5?2:1}function oT(e){var t=30*_h;return e/=t,e>6?6:e>3?3:e>2?2:1}function sT(e){return e/=gh,e>12?12:e>6?6:e>3.5?4:e>2?2:1}function cT(e,t){return e/=t?hh:mh,e>30?30:e>20?20:e>15?15:e>10?10:e>5?5:e>2?2:1}function lT(e){return so(Fo(e,!0),1)}function uT(e,t,n){var r=Math.max(0,R(wh,t)-1);return Fh(new Date(e),wh[r],n).getTime()}function dT(e,t){var n=new Date(0);n[e](1);var r=n.getTime();n[e](1+t);var i=n.getTime()-r;return function(e,t){return Math.max(0,Math.round((t-e)/i))}}function fT(e,t,n,r,i,a){var o=3e3,s=Th,c=0;function l(e,t,n,i,s,l,u){for(var d=dT(s,e),f=t,p=new Date(f);f<n&&f<=r[1]&&(u.push({value:f}),!(c++>o));)if(p[s](p[i]()+e),f=p.getTime(),a){var m=a.calcNiceTickMultiple(f,d);m>0&&(p[s](p[i]()+m*e),f=p.getTime())}u.push({value:f,notAdd:f>r[1]})}function u(e,i,a){var o=[],s=!i.length;if(!iT(kh(e),r[0],r[1],n)){s&&(i=[{value:uT(r[0],e,n)},{value:r[1]}]);for(var c=0;c<i.length-1;c++){var u=i[c].value,d=i[c+1].value;if(u!==d){var f=void 0,p=void 0,m=void 0,h=!1;switch(e){case`year`:f=Math.max(1,Math.round(t/_h/365)),p=Ih(n),m=Uh(n);break;case`half-year`:case`quarter`:case`month`:f=oT(t),p=Lh(n),m=Wh(n);break;case`week`:case`half-week`:case`day`:f=aT(t,31),p=Rh(n),m=Gh(n),h=!0;break;case`half-day`:case`quarter-day`:case`hour`:f=sT(t),p=zh(n),m=Kh(n);break;case`minute`:f=cT(t,!0),p=Bh(n),m=qh(n);break;case`second`:f=cT(t,!1),p=Vh(n),m=Jh(n);break;case`millisecond`:f=lT(t),p=Hh(n),m=Yh(n);break}d>=r[0]&&u<=r[1]&&l(f,u,d,p,m,h,o),e===`year`&&a.length>1&&c===0&&a.unshift({value:a[0].value-f})}}for(var c=0;c<o.length;c++)a.push(o[c])}}for(var d=[],f=[],p=0,m=0,h=0;h<s.length;++h){var g=kh(s[h]);if(Ah(s[h])&&(u(s[h],d[d.length-1]||[],f),g!==(s[h+1]?kh(s[h+1]):null))){if(f.length){m=p,f.sort(function(e,t){return e.value-t.value});for(var _=[],v=0;v<f.length;++v){var y=f[v].value;(v===0||f[v-1].value!==y)&&(_.push(f[v]),y>=r[0]&&y<=r[1]&&p++)}var b=i/t;if(p>b*1.5&&m>b/1.5||(d.push(_),p>b||e===s[h]))break}f=[]}}for(var x=Ee(B(d,function(e){return Ee(e,function(e){return e.value>=r[0]&&e.value<=r[1]&&!e.notAdd})}),function(e){return e.length>0}),S=x.length-1,C=[],h=0;h<x.length;++h)for(var w=x[h],T=0;T<w.length;++T){var E=Ph(w[T].value,n);C.push({value:w[T].value,time:{level:S-h,upperTimeUnit:E,lowerTimeUnit:E}})}Bs(C,Vs,null),C.sort(function(e,t){return e.value-t.value});var D=C[0],O=C[C.length-1],k=Ph(r[0],n),A=Ph(r[1],n);return(!D||D.value>r[0])&&C.unshift({value:r[0],time:{level:0,upperTimeUnit:k,lowerTimeUnit:k},notNice:!0}),(!O||O.value<r[1])&&C.push({value:r[1],time:{level:0,upperTimeUnit:A,lowerTimeUnit:A},notNice:!0}),C}var pT=function(e,t){var n=e.getExtent();if(n[0]===n[1]&&(n[0]-=_h,n[1]+=_h),n[1]===-1/0&&n[0]===1/0){var r=new Date;n[1]=+new Date(r.getFullYear(),r.getMonth(),r.getDate()),n[0]=n[1]-_h}e.setExtent(n[0],n[1]);var i=Xw(t.splitNumber,10),a=Fw(e)/i,o=t.minInterval,s=t.maxInterval;o!=null&&a<o&&(a=o),s!=null&&a>s&&(a=s);var c=rT.length,l=Math.min(tT(rT,a,0,c),c-1),u=rT[l][1],d=rT[Math.max(l-1,0)][0];e.setTimeInterval({approxInterval:a,interval:u,minLevelUnit:d})};ww.registerClass(nT);var mT=0,hT=1,gT=2,_T=function(e){k(t,e);function t(n){var r=e.call(this)||this;r.type=`log`,r.parse=eT.parse,r.base=n.logBase||10;var i=[],a=[],o=r._lookup={from:i,to:a};i[mT]=i[hT]=a[mT]=a[hT]=NaN,Aw(r,t.mapperMethods);var s=uh(),c=n.breakOption,l={lookup:o};return s&&s.parseAxisBreakOptionInwardTransform(c,r,{noNegative:!0},gT,l),r.powStub=new eT({breakParsed:l.original}),r.intervalStub=new eT({breakParsed:l.transformed}),jw(r,r.intervalStub),r}return t.prototype.getTicks=function(e){var t=this.base,n=this.powStub,r=uh(),i=this.intervalStub,a={lookup:{from:i.getExtent(),to:n.getExtent()}};return B(i.getTicks(e||{}),function(e){var i=e.value,o=qw(i,t,a),s;if(r){var c=r.getTicksBreakOutwardTransform(this,e,fh(n),this._lookup);c&&(s=c.vBreak,o=c.tickVal)}return{value:o,break:s}},this)},t.prototype.getMinorTicks=function(e){return $w(this,e,fh(this.powStub),this.intervalStub.getConfig().interval)},t.prototype.getLabel=function(e,t){return this.intervalStub.getLabel(e,t)},t.type=`log`,t.mapperMethods={needTransform:function(){return!0},normalize:function(e){return this.intervalStub.normalize(Kw(e,this.base))},scale:function(e){return qw(this.intervalStub.scale(e),this.base,null)},transformIn:function(e,t){return e=Kw(e,this.base),t&&t.depth===2?e:this.intervalStub.transformIn(e,t)},transformOut:function(e,t){var n=t?t.depth:null;return vT.depth=n,yT.lookup=this._lookup,qw(n===2?e:this.intervalStub.transformOut(e,vT),this.base,yT)},contain:function(e){return this.powStub.contain(e)},setExtent:function(e,t){this.setExtent2(0,e,t)},setExtent2:function(e,t,n){if(!(!Fs(t,n)||t<=0||n<=0)){var r=bT,i=bT;if(e===0){var a=this._lookup;r=a.to,i=a.from}this.powStub.setExtent2(e,r[mT]=t,r[hT]=n);var o=this.base;this.intervalStub.setExtent2(e,i[mT]=Kw(t,o),i[hT]=Kw(n,o))}},getFilter:function(){return{g:0}},sanitize:function(e,t){return Fs(t[0],t[1])&&Vo(e)&&e<=0&&(e=t[0]),e},getDefaultStartValue:function(){return 1},getExtent:function(){return this.powStub.getExtent()},getExtentUnsafe:function(e,t){return t===null?this.powStub.getExtentUnsafe(e,null):this.intervalStub.getExtentUnsafe(e,t)}},t}(ww);ww.registerClass(_T);var vT={},yT={},bT=[],xT={value:1,category:1,time:1,log:1},ST=Z();function CT(e){var t=e.get(`type`);return(t==null||!et(xT,t)&&!ww.getClass(t))&&(t=`value`),t}function wT(e,t,n){var r=uh(),i;switch(r&&(i=FT(e,t,n)),t){case`category`:return new Qw({ordinalMeta:e.getOrdinalMeta?e.getOrdinalMeta():e.getCategories(),extent:ks()});case`time`:return new nT({locale:e.ecModel.getLocaleModel(),useUTC:e.ecModel.get(`useUTC`),breakOption:i});case`log`:return new _T({logBase:e.get(`logBase`),breakOption:i});case`value`:return new eT({breakOption:i});default:return new((ww.getClass(t))||eT)({})}}function TT(e,t,n){var r=n?Nw(e,null):e.getExtentUnsafe(0,null),i=r[0],a=r[1];return Fs(i,a)?i===t||a===t?2:i<t&&a>t?1:3:3}function ET(e){ST(e).noOnMyZero=!0}function DT(e){return ST(e).noOnMyZero}function OT(e){var t=e.getLabelModel().get(`formatter`);if(e.type===`time`){var n=Eh(t);return function(t,r){return e.scale.getFormattedLabel(t,r,n)}}else if(G(t))return function(n){var r=e.scale.getLabel(n);return t.replace(`{value}`,r??``)};else if(W(t)){if(e.type===`category`)return function(n,r){return t(kT(e,n),n.value-e.scale.getExtent()[0],null)};var r=uh();return function(n,i){var a=null;return r&&(a=r.makeAxisLabelFormatterParamBreak(a,n.break)),t(kT(e,n),i,a)}}else return function(t){return e.scale.getLabel(t)}}function kT(e,t){var n=e.scale;return Uw(n)?n.getLabel(t):t.value}function AT(e){return e.get(`interval`)??`auto`}function jT(e){return e.type===`category`&&AT(e.getLabelModel())===0}function MT(e,t){var n={};return z(e.mapDimensionsAll(t),function(t){n[vw(e,t)]=!0}),Oe(n)}function NT(e){return e===`middle`||e===`center`}function PT(e){return e.getShallow(`show`)}function FT(e,t,n){var r=e.get(`breaks`,!0);if(r!=null)return!uh()||!n||!IT(t)?void 0:r}function IT(e){return e!==`category`}function LT(e,t,n,r,i,a){var o=Hw(e),s=o?e.intervalStub:e;if(s.setExtent(r[0],r[1]),o){var c=e.powStub,l={depth:2},u=e.transformOut(r[0],l),d=e.transformOut(r[1],l),f=Yw(n,r);t[0]&&!f[0]&&(u=i[0]),t[1]&&!f[1]&&(d=i[1]),c.setExtent(u,d)}s.setConfig(a)}function RT(e,t){return Uw(e)?e.getRawOrdinalNumber(t.value):t.value}function zT(e,t){return Uw(e)&&!!t.get(`boundaryGap`)}var BT=function(){function e(){}return e.prototype.needIncludeZero=function(){return!this.option.scale},e.prototype.getCoordSysModel=function(){},e}();Rs();var VT=Z();Z();function HT(e,t){var n=e.model,r=VT(qb(n.ecModel)).keyed,i=r&&r.get(t);return i&&i.get(n.uid)}function UT(e,t){return KT(HT(e,t))}function WT(e,t){var n=[];return GT(e.model.ecModel,function(e){for(var r=0;r<t.length;r++)t[r]&&e.serByIdx[t[r].seriesIndex]&&n.push(KT(e))}),n}function GT(e,t){var n=VT(qb(e)).keyed;n&&n.each(function(e,n){e.each(function(e,r){t(e,n,r)})})}function KT(e){return{liPosMinGap:e?e.liPosMinGap:void 0}}function qT(e,t){var n=e.model.ecModel,r=VT(qb(n)).axSer;r&&JT(n,r.get(e.model.uid),t)}function JT(e,t,n){if(t)for(var r=0;r<t.length;r++){var i=t[r];e.isSeriesFiltered(i)||n(i)}}function YT(e,t){var n=e.model,r=VT(qb(n.ecModel)).keys;r&&z(r.get(n.uid),function(e){t(e)})}function XT(e,t,n){if(e){var r=t.ecModel,i=VT(qb(r)),a=e.model.uid,o=i.axSer||=J();(o.get(a)||o.set(a,[])).push(t);var s=t.subType,c=t.getBaseAxis()===e,l=QT.get(ZT(s,c,n))||QT.get(ZT(s,c,null));if(l){var u=i.keyed||=J(),d=i.keys||=J(),f=l.key,p=u.get(f)||u.set(f,J()),m=p.get(a);m||(m=p.set(a,{axis:e,sers:[],serByIdx:[]}),m.metrics=l.getMetrics(e),(d.get(a)||d.set(a,[])).push(f)),m.sers.push(t),m.serByIdx[t.seriesIndex]=t}}}function ZT(e,t,n){return e+`|&`+q(t,!0)+`|&`+(n||``)}var QT=J(),$T=Z(),eE=3,tE=function(){function e(e,t,n,r,i){var a=Uw(e),o=a?t.getCategories().length:null,s;if(a){var c=t.getCategories(!0);s=c&&!c.length}var l=n.slice();(Bw(e)||Hw(e)||Vw(e))&&(js(l,rE(e,t.get(`dataMin`,!0))),Ms(l,rE(e,t.get(`dataMax`,!0)))),Is(l)||(l[0]=l[1]=NaN);var u=[],d=[!1,!1],f=t.get(`min`,!0);f===`dataMin`?(u[0]=l[0],d[0]=!0):(u[0]=rE(e,W(f)?f({min:l[0],max:l[1]}):f),d[0]=u[0]!=null);var p=t.get(`max`,!0);p===`dataMax`?(u[1]=l[1],d[1]=!0):(u[1]=rE(e,W(p)?p({min:l[0],max:l[1]}):p),d[1]=u[1]!=null);var m=iE(e,t),h=a?null:l[1]-l[0]||Math.abs(l[0]);u[0]??=a?s?l[0]:o?0:NaN:l[0]-m[0]*h,u[1]??=a?s?l[1]:o?o-1:NaN:l[1]+m[1]*h,!Ps(u[0])&&(u[0]=NaN),!Ps(u[1])&&(u[1]=NaN);var g=s||Le(u[0])||Le(u[1])||a&&!o,_=Bw(e),v=_&&t.needIncludeZero&&t.needIncludeZero();v&&(u[0]>0&&u[1]>0&&!d[0]&&(u[0]=0),u[0]<0&&u[1]<0&&!d[1]&&(u[1]=0));var y=!1;u[0]>u[1]&&(u.reverse(),y=!0);var b=rE(e,t.get(`startValue`,!0)),x=b!=null;!Vo(b)&&r&&(b=e.getDefaultStartValue?e.getDefaultStartValue():0),Vo(b)&&(x||!_||v)&&(b<u[0]&&!d[0]?(u[0]=b,d[0]=!0):b>u[1]&&!d[1]&&(u[1]=b,d[1]=!0)),nE(this._i={scale:e,dataMM:l,noZoomEffMM:u,zoomMM:[],fixMM:d,zoomFixMM:[!1,!1],startValue:b,isBlank:g,incl0:v,tggAxInv:y,ctnShp:i},u)}return e.prototype.makeNoZoom=function(){return this._i.noZoomEffMM.slice()},e.prototype.makeFinal=function(){var e=this._i,t=e.zoomMM,n=e.noZoomEffMM,r=e.zoomFixMM,i=e.fixMM,a={fixMM:i,zoomFixMM:r,isBlank:e.isBlank,incl0:e.incl0,tggAxInv:e.tggAxInv,ctnShp:e.ctnShp,effMM:n.slice()},o=a.effMM;return t[0]!=null&&(o[0]=t[0],i[0]=r[0]=!0),t[1]!=null&&(o[1]=t[1],i[1]=r[1]=!0),nE(e,o),a},e.prototype.makeRenderInfo=function(){return{startValue:this._i.startValue}},e.prototype.setZoomMM=function(e,t){this._i.zoomMM[e]=t},e}();function nE(e,t){var n=e.scale,r=e.dataMM;n.sanitize&&(t[0]=n.sanitize(t[0],r),t[1]=n.sanitize(t[1],r),Ls(t))}function rE(e,t){return t==null?null:Le(t)?NaN:e.parse(t)}function iE(e,t){var n;if(Uw(e))n=[0,0];else{var r=t.get(`boundaryGap`);typeof r==`boolean`&&(r=null),n=U(r)?r:[r,r]}return[aE(n[0]),aE(n[1])]}function aE(e){return Aa(typeof e==`boolean`?0:e,1)||0}function oE(e){var t=$T(e.scale);return t.extent||=ks(),t}function sE(e,t){oE(e).dimIdxInCoord=t.get(e.dim)}function cE(e,t){var n=e.scale,r=e.model,i=e.dim;n.rawExtentInfo||lE(n,e,i,r,t)}function lE(e,t,n,r,i){var a=oE(t),o=a.extent,s=!1;qT(t,function(r){if(r.boxCoordinateSystem){var i=ug(r).coord,c=a.dimIdxInCoord;if(c>=0&&U(i)){var l=i[c];l!=null&&!U(l)&&As(o,e.parse(l))}}else if(r.coordinateSystem){var u=r.getData();if(u){var d=e.getFilter?e.getFilter():null;z(MT(u,n),function(e){Ns(o,u.getApproximateExtent(e,d))})}r.__requireStartValue&&r.__requireStartValue(t)&&(s=!0)}});var c=mE(e,t,r);dE(e,new tE(e,r,o,s,c),i),a.extent=null}function uE(e,t){var n=e.scale;dE(n,new tE(n,e.model,t,!1,!1),eE)}function dE(e,t,n){e.rawExtentInfo=t,t.from=n}var fE=J();function pE(e,t,n,r,i){e.rawExtentInfo||uE({scale:e,model:t},i||ks());var a=e.rawExtentInfo.makeFinal(),o=a.effMM;return e.setExtent(o[0],o[1]),e.setBlank(a.isBlank),r&&a.tggAxInv&&n&&!n.get(`legacyMinMaxDontInverseAxis`)&&(r.inverse=!r.inverse),a}function mE(e,t,n){var r=zT(e,n),i=n.get(`containShape`,!0);if(i==null&&!r&&(i=!0),!i)return!1;var a=!1;return YT(t,function(e){a=!!fE.get(e)||a}),a}function hE(e,t,n,r){if(n.ctnShp){var i;if(YT(e,function(t){var n=fE.get(t);if(n){var a=n(e,r);a&&(i||=[0,0],js(i,a[0]),Ms(i,a[1]),ET(e))}}),i){var a=t.getExtent();if(Uw(t))e.onBand||t.setExtent2(1,oo(a[0],a[0]+i[0]),so(a[1],a[1]+i[1]));else{var o=a.slice();n.zoomFixMM[0]||(o[0]=oo(o[0],t.transformOut(t.transformIn(o[0],null)+i[0],null))),n.zoomFixMM[1]||(o[1]=so(o[1],t.transformOut(t.transformIn(o[1],null)+i[1],null))),(o[0]<a[0]||o[1]>a[1])&&t.setExtent2(1,o[0],o[1])}}}}function gE(e,t){var n=Hw(e),r=n?e.intervalStub:e,i=t.fixMinMax||[],a=n?e.getExtent():null,o=r.getExtent(),s=Jw(o,i,t.rawExtentResult);r.setExtent(s[0],s[1]),s=r.getExtent();var c=n?vE(r,t):_E(r,t),l=c.intervalPrecision,u=c.interval,d=t.userInterval;d!=null&&(c.interval=d,c.intervalPrecision=Gw(d)),i[0]||(s[0]=X(uo(s[0]/u)*u,l)),i[1]||(s[1]=X(fo(s[1]/u)*u,l)),d!=null&&(c.niceExtent=s.slice()),LT(e,i,o,s,a,c)}function _E(e,t){var n=Xw(t.splitNumber,5),r=Fw(e),i=t.minInterval,a=t.maxInterval,o=Fo(r/n,!0);i!=null&&o<i&&(o=i),a!=null&&o>a&&(o=a);var s=Gw(o),c=e.getExtent(),l=[X(fo(c[0]/o)*o,s),X(uo(c[1]/o)*o,s)];return{interval:o,intervalPrecision:s,niceExtent:l}}function vE(e,t){var n=Xw(t.splitNumber,10),r=e.getExtent(),i=Fw(e),a=so(No(i),1);n/i*a<=.5&&(a*=10);var o=Gw(a),s=[X(fo(r[0]/a)*a,o),X(uo(r[1]/a)*a,o)];return{intervalPrecision:o,interval:a,niceExtent:s}}function yE(e){var t=e.scale,n=e.model,r=n.axis,i=n.ecModel;bE(t,n,r,i,null)}function bE(e,t,n,r,i){var a=pE(e,t,r,n,i),o=Bw(e)||Vw(e);xE(e,{splitNumber:t.get(`splitNumber`),fixMinMax:a.fixMM,userInterval:t.get(`interval`),minInterval:o?t.get(`minInterval`):null,maxInterval:o?t.get(`maxInterval`):null,rawExtentResult:a}),n&&r&&hE(n,e,a,r)}function xE(e,t){SE[e.type](e,t)}var SE={interval:gE,log:gE,time:pT,ordinal:tt},CE=[],wE={registerPreprocessor:gC,registerProcessor:_C,registerPostInit:vC,registerPostUpdate:yC,registerUpdateLifecycle:bC,registerAction:xC,registerCoordinateSystem:SC,registerLayout:CC,registerVisual:wC,registerTransform:kC,registerLoading:DC,registerMap:OC,registerImpl:zb,PRIORITY:vS,ComponentModel:Og,ComponentView:Fy,SeriesModel:Ey,ChartView:zy,registerComponentModel:function(e){Og.registerClass(e)},registerComponentView:function(e){Fy.registerClass(e)},registerSeriesModel:function(e){Ey.registerClass(e)},registerChartView:function(e){zy.registerClass(e)},registerCustomSeries:function(e,t){Hb(e,t)},registerSubTypeDefaulter:function(e,t){Og.registerSubTypeDefaulter(e,t)},registerPainter:function(e,t){no(e,t)}};function TE(e){if(U(e)){z(e,function(e){TE(e)});return}R(CE,e)>=0||(CE.push(e),W(e)&&(e={install:e}),e.install(wE))}var EE=Z(),DE=Z(),OE={estimate:1,determine:2};function kE(e){return{out:{noPxChangeTryDetermine:[]},kind:e}}function AE(e,t){var n=e.getLabelModel().get(`customValues`);if(n){var r=e.scale;return{labels:B(ME(n,r),function(t,n){return{formattedLabel:OT(e)(t,n),rawLabel:r.getLabel(t),tick:t}})}}return e.type===`category`?NE(e,t):IE(e)}function jE(e,t,n){var r=e.scale,i=e.getTickModel().get(`customValues`);return i?{ticks:ME(i,r)}:e.type===`category`?FE(e,t):{ticks:r.getTicks(n)}}function ME(e,t){var n=t.getExtent(),r=[];return z(e,function(e){e=t.parse(e),e>=n[0]&&e<=n[1]&&r.push(e)}),Bs(r,Hs,null),Co(r),B(r,function(e){return{value:e}})}function NE(e,t){var n=e.getLabelModel(),r=PE(e,n,t);return!n.get(`show`)||e.scale.isBlank()?{labels:[]}:r}function PE(e,t,n){var r=RE(e),i=AT(t),a=n.kind===OE.estimate;if(!a){var o=BE(r,i);if(o)return o}var s,c;W(i)?s=qE(e,i,!1):(c=i===`auto`?HE(e,n):i,s=qE(e,c,!1));var l={labels:s,labelCategoryInterval:c};return a?n.out.noPxChangeTryDetermine.push(function(){return VE(r,i,l),!0}):VE(r,i,l),l}function FE(e,t){var n=LE(e),r=AT(t),i=BE(n,r);if(i)return i;var a,o;if((!t.get(`show`)||e.scale.isBlank())&&(a=[]),W(r))a=qE(e,r,!0);else if(r===`auto`){var s=PE(e,e.getLabelModel(),kE(OE.determine));o=s.labelCategoryInterval,a=B(s.labels,function(e){return e.tick})}else o=r,a=qE(e,o,!0);return VE(n,r,{ticks:a,tickCategoryInterval:o})}function IE(e){var t=e.scale.getTicks(),n=OT(e);return{labels:B(t,function(t,r){return{formattedLabel:n(t,r),rawLabel:e.scale.getLabel(t),tick:t}})}}var LE=zE(`axisTick`),RE=zE(`axisLabel`);function zE(e){return function(t){return DE(t)[e]||(DE(t)[e]={list:[]})}}function BE(e,t){for(var n=0;n<e.list.length;n++)if(e.list[n].key===t)return e.list[n].value}function VE(e,t,n){return e.list.push({key:t,value:n}),n}function HE(e,t){if(t.kind===OE.estimate){var n=e.calculateCategoryInterval(t);return t.out.noPxChangeTryDetermine.push(function(){return DE(e).autoInterval=n,!0}),n}return DE(e).autoInterval??(DE(e).autoInterval=e.calculateCategoryInterval(t))}function UE(e,t){var n=t.kind,r=KE(e),i=OT(e),a=(r.axisRotate-r.labelRotate)/180*Math.PI,o=e.scale,s=o.getExtent(),c=o.count();if(s[1]-s[0]<1)return 0;var l=1,u=40;c>u&&(l=Math.max(1,Math.floor(c/u)));for(var d=s[0],f=e.dataToCoord(d+1)-e.dataToCoord(d),p=Math.abs(f*Math.cos(a)),m=Math.abs(f*Math.sin(a)),h=0,g=0;d<=s[1];d+=l){var _=0,v=0,y=Ea(i({value:d}),r.font,`center`,`top`);_=y.width*1.3,v=y.height*1.3,h=Math.max(h,_,7),g=Math.max(g,v,7)}var b=h/p,x=g/m;isNaN(b)&&(b=1/0),isNaN(x)&&(x=1/0);var S=Math.max(0,Math.floor(Math.min(b,x)));return n===OE.estimate?(t.out.noPxChangeTryDetermine.push(V(WE,null,e,S,c)),S):GE(e,S,c)??S}function WE(e,t,n){return GE(e,t,n)==null}function GE(e,t,n){var r=EE(e.model),i=e.getExtent(),a=r.lastAutoInterval,o=r.lastTickCount;if(a!=null&&o!=null&&Math.abs(a-t)<=1&&Math.abs(o-n)<=1&&a>t&&r.axisExtent0===i[0]&&r.axisExtent1===i[1])return a;r.lastTickCount=n,r.lastAutoInterval=t,r.axisExtent0=i[0],r.axisExtent1=i[1]}function KE(e){var t=e.getLabelModel();return{axisRotate:e.getRotate?e.getRotate():e.isHorizontal&&!e.isHorizontal()?90:0,labelRotate:t.get(`rotate`)||0,font:t.getFont()}}function qE(e,t,n){var r=OT(e),i=e.scale,a=[],o=W(t);return Zw(i,o?0:t,function(e,s){var c=i.getLabel(e);if(o){var l=!!t(e.value,c);if(e.offInterval=!l,!l&&!s)return}a.push(n?e:{formattedLabel:r(e),rawLabel:c,tick:e})}),a}var JE=.8;function YE(e,t){t||={};var n={w:NaN,w2:NaN},r=e.scale,i=t.fromStat,a=t.min,o=Pw(r);Vo(o)||(o=NaN);var s=e.getExtent(),c=co(s[1]-s[0]);return Uw(r)?XE(n,e,o,c):i&&ZE(n,e,o,c,i),a!=null&&(n.w=Vo(n.w)?so(a,n.w):a),n}function XE(e,t,n,r){var i=t.onBand,a=n+ +!!i;a===0&&(a=1),e.w=r/a,!i&&n&&r&&(e.w2=e.w*n/r)}function ZE(e,t,n,r,i){var a=!1,o=-1/0;z(i.key?[UT(t,i.key)]:WT(t,i.sers||[]),function(e){var t=e.liPosMinGap;t!=null&&(t>0?(t>o&&(o=t),a=!1):t===-2&&(a=!0))}),Vo(n)&&n>0&&Vo(o)?(e.w=r/n*o,e.w2=o):a&&(e.w=r*JE,e.w2=e.w*n/r)}var QE=[0,1],$E=function(){function e(e,t,n){this.onBand=!1,this.inverse=!1,this.dim=e,this.scale=t,this._extent=n||[0,0]}return e.prototype.contain=function(e){var t=this._extent,n=Math.min(t[0],t[1]),r=Math.max(t[0],t[1]);return e>=n&&e<=r},e.prototype.containData=function(e){return this.scale.contain(this.scale.parse(e))},e.prototype.getExtent=function(){return this._extent.slice()},e.prototype.setExtent=function(e,t){var n=this._extent;n[0]=e,n[1]=t},e.prototype.dataToCoord=function(e,t){var n=this.scale;return e=n.normalize(n.parse(e)),vo(e,QE,eD(this),t)},e.prototype.coordToData=function(e,t){var n=vo(e,eD(this),QE,t);return this.scale.scale(n)},e.prototype.pointToData=function(e,t){},e.prototype.getTicksCoords=function(e){e||={};var t=e.tickModel||this.getTickModel(),n=B(jE(this,t,{breakTicks:e.breakTicks,pruneByBreak:e.pruneByBreak}).ticks,function(e){return{coord:this.dataToCoord(RT(this.scale,e)),tick:e}},this),r=t.get(`alignWithLabel`),i=tD(this,n,r);return B(n,function(e){return{coord:e.coord,tickValue:e.tick.value,onBand:i}})},e.prototype.getMinorTicksCoords=function(){if(Uw(this.scale))return[];var e=this.model.getModel(`minorTick`).get(`splitNumber`);return e>0&&e<100||(e=5),B(this.scale.getMinorTicks(e),function(e){return B(e,function(e){return{coord:this.dataToCoord(e),tickValue:e}},this)},this)},e.prototype.getViewLabels=function(e){return e||=kE(OE.determine),AE(this,e).labels},e.prototype.getLabelModel=function(){return this.model.getModel(`axisLabel`)},e.prototype.getTickModel=function(){return this.model.getModel(`axisTick`)},e.prototype.getBandWidth=function(){return YE(this,{min:1}).w},e.prototype.calculateCategoryInterval=function(e){return e||=kE(OE.determine),UE(this,e)},e}();function eD(e){var t=e.getExtent();if(e.onBand){var n=(t[1]-t[0])/e.scale.count()/2;t[0]+=n,t[1]-=n}return t}function tD(e,t,n){var r=t.length;if(!e.onBand||n||!r)return!1;var i=YE(e).w;if(!i)return!1;z(t,function(e){e.coord-=i/2});var a=e.scale.getExtent(),o=t[r-1];return o.tick.offInterval&&t.pop(),t.push({coord:o.coord+i,tick:{value:a[1]+1}}),!0}var nD=[`label`,`labelLine`,`layoutOption`,`priority`,`defaultAttr`,`marginForce`,`minMarginForce`,`marginDefault`,`suggestIgnore`],rD=1,iD=2,aD=rD|iD;function oD(e,t,n){n||=aD,t?e.dirty|=n:e.dirty&=~n}function sD(e,t){return t||=aD,e.dirty==null||!!(e.dirty&t)}function cD(e){if(e)return sD(e)&&lD(e,e.label,e),e}function lD(e,t,n){var r=t.getComputedTransform();e.transform=um(e.transform,r);var i=e.localRect=lm(e.localRect,t.getBoundingRect()),a=t.style,o=a.margin,s=n&&n.marginForce,c=n&&n.minMarginForce,l=n&&n.marginDefault,u=a.__marginType;u==null&&l&&(o=l,u=Pm.textMargin);for(var d=0;d<4;d++)uD[d]=u===Pm.minMargin&&c&&c[d]!=null?c[d]:s&&s[d]!=null?s[d]:o?o[d]:0;u===Pm.textMargin&&tm(i,uD,!1,!1);var f=e.rect=lm(e.rect,i);return r&&f.applyTransform(r),u===Pm.minMargin&&tm(f,uD,!1,!1),e.axisAligned=sm(r),(e.label=e.label||{}).ignore=t.ignore,oD(e,!1),oD(e,!0,iD),e}var uD=[0,0,0,0];function dD(e,t,n){return e.transform=um(e.transform,n),e.localRect=lm(e.localRect,t),e.rect=lm(e.rect,t),n&&e.rect.applyTransform(n),e.axisAligned=sm(n),e.obb=void 0,(e.label=e.label||{}).ignore=!1,e}function fD(e,t){if(e){e.label.x+=t.x,e.label.y+=t.y,e.label.markRedraw();var n=e.transform;n&&(n[4]+=t.x,n[5]+=t.y);var r=e.rect;r&&(r.x+=t.x,r.y+=t.y);var i=e.obb;i&&i.fromBoundingRect(e.localRect,n)}}function pD(e,t){for(var n=0;n<nD.length;n++){var r=nD[n];e[r]??(e[r]=t[r])}return cD(e)}function mD(e){var t=e.obb;return(!t||sD(e,iD))&&(e.obb=t||=new fp,t.fromBoundingRect(e.localRect,e.transform),oD(e,!1,iD)),t}function hD(e){var t=[];e.sort(function(e,t){return!!t.suggestIgnore-+!!e.suggestIgnore||t.priority-e.priority});function n(e){if(!e.ignore){var t=e.ensureState(`emphasis`);t.ignore??=!1}e.ignore=!0}for(var r=0;r<e.length;r++){var i=cD(e[r]);if(!i.label.ignore){for(var a=i.label,o=i.labelLine,s=!1,c=0;c<t.length;c++)if(gD(i,t[c],null,{touchThreshold:.05})){s=!0;break}s?(n(a),o&&n(o)):t.push(i)}}}function gD(e,t,n,r){return!e||!t||e.label&&e.label.ignore||t.label&&t.label.ignore||!e.rect.intersect(t.rect,n,r)?!1:e.axisAligned&&t.axisAligned?!0:mD(e).intersect(mD(t),n,r)}function _D(e,t,n){var r=M.createCanvas(),i=t.getWidth(),a=t.getHeight(),o=r.style;return o&&(o.position=`absolute`,o.left=`0`,o.top=`0`,o.width=i+`px`,o.height=a+`px`,r.setAttribute(`data-zr-dom-id`,e)),r.width=i*n,r.height=a*n,r}function vD(e){return!e.__cursors.get(0)}function yD(e){var t=e.__cursors.get(0);return{startIdx:t?t.startIdx:0,endIdx:t?t.endIdx:0}}var bD=function(e){it(t,e);function t(t,n,r){var i=e.call(this)||this;i.motionBlur=!1,i.lastFrameAlpha=.7,i.dpr=1,i.virtual=!1,i.config={},i.zlevel=0,i.zlevel2=0,i.maxRepaintRectCount=5,i.__dirty=!0,i.__firstTimePaint=!0,i.__prevIdx={startIdx:0,endIdx:0};var a;r||=ta,typeof t==`string`?a=_D(t,n,r):K(t)&&(a=t,t=a.id),i.id=t,i.dom=a;var o=a.style;return o&&($e(a),a.onselectstart=function(){return!1},o.padding=`0`,o.margin=`0`,o.borderWidth=`0`),i.painter=n,i.dpr=r,i}return t.prototype.afterBrush=function(){this.__prevIdx=yD(this)},t.prototype.initContext=function(){this.ctx=this.dom.getContext(`2d`),this.ctx.dpr=this.dpr},t.prototype.setUnpainted=function(){this.__firstTimePaint=!0},t.prototype.createBackBuffer=function(){var e=this.dpr;this.domBack=_D(`back-`+this.id,this.painter,e),this.ctxBack=this.domBack.getContext(`2d`),e!==1&&this.ctxBack.scale(e,e)},t.prototype.createRepaintRects=function(e,t,n,r){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var i=[],a=this.maxRepaintRectCount,o=!1,s=new Y(0,0,0,0);function c(e){if(!(!e.isFinite()||e.isZero()))if(i.length===0){var t=new Y(0,0,0,0);t.copy(e),i.push(t)}else{for(var n=!1,r=1/0,c=0,l=0;l<i.length;++l){var u=i[l];if(u.intersect(e)){var d=new Y(0,0,0,0);d.copy(u),d.union(e),i[l]=d,n=!0;break}else if(o){s.copy(e),s.union(u);var f=e.width*e.height,p=u.width*u.height,m=s.width*s.height-f-p;m<r&&(r=m,c=l)}}if(o&&(i[c].union(e),n=!0),!n){var t=new Y(0,0,0,0);t.copy(e),i.push(t)}o||=i.length>=a}}for(var l=yD(this),u=l.startIdx;u<l.endIdx;++u){var d=e[u];if(d){var f=d.shouldBePainted(n,r,!0,!0),p=d.__isRendered&&(d.__dirty&1||!f)?d.getPrevPaintRect():null;p&&c(p);var m=f&&(d.__dirty&1||!d.__isRendered)?d.getPaintRect():null;m&&c(m)}}for(var h=this.__prevIdx,u=h.startIdx;u<h.endIdx;++u){var d=t[u],f=d&&d.shouldBePainted(n,r,!0,!0);if(d&&(!f||!d.__zr)&&d.__isRendered){var p=d.getPrevPaintRect();p&&c(p)}}var g;do{g=!1;for(var u=0;u<i.length;){if(i[u].isZero()){i.splice(u,1);continue}for(var _=u+1;_<i.length;)i[u].intersect(i[_])?(g=!0,i[u].union(i[_]),i.splice(_,1)):_++;u++}}while(g);return this._paintRects=i,i},t.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},t.prototype.resize=function(e,t){var n=this.dpr,r=this.dom,i=r.style,a=this.domBack;i&&(i.width=e+`px`,i.height=t+`px`),r.width=e*n,r.height=t*n,a&&(a.width=e*n,a.height=t*n,n!==1&&this.ctxBack.scale(n,n))},t.prototype.clear=function(e,t,n){var r=this.dom,i=this.ctx,a=r.width,o=r.height;t||=this.clearColor;var s=this.motionBlur&&!e,c=this.lastFrameAlpha,l=this.dpr,u=this;s&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation=`copy`,this.ctxBack.drawImage(r,0,0,a/l,o/l));var d=this.domBack;function f(e,n,r,a){if(i.clearRect(e,n,r,a),t&&t!==`transparent`){var o=void 0;Fe(t)?(o=(t.global||t.__width===r&&t.__height===a)&&t.__canvasGradient||lx(i,t,{x:0,y:0,width:r,height:a}),t.__canvasGradient=o,t.__width=r,t.__height=a):Ie(t)&&(t.scaleX=t.scaleX||l,t.scaleY=t.scaleY||l,o=xx(i,t,{dirty:function(){u.setUnpainted(),u.painter.refresh()}})),i.save(),i.fillStyle=o||t,i.fillRect(e,n,r,a),i.restore()}s&&(i.save(),i.globalAlpha=c,i.drawImage(d,e,n,r,a),i.restore())}!n||s?f(0,0,a,o):n.length&&z(n,function(e){f(e.x*l,e.y*l,e.width*l,e.height*l)})},t}(wt),xD=1e5,SD=314159,CD=void 0,wD=1,TD=2;function ED(e){return e?e.__builtin__?!0:!(typeof e.resize!=`function`||typeof e.refresh!=`function`):!1}function DD(e,t){var n=document.createElement(`div`);return n.style.cssText=[`position:relative`,`width:`+e+`px`,`height:`+t+`px`,`padding:0`,`margin:0`,`border-width:0`].join(`;`)+`;`,n}function OD(e,t,n,r){var i=new bD(e,t,t.dpr);return i.zlevel=n,i.zlevel2=r,i.__builtin__=!0,kD(i),i}function kD(e){e.__cursorStack=[],e.__cursors=J()}function AD(e){return e.startIdx=e.drawIdx=e.endIdx=e.endIdxNew=0,e.used=!1,e.first=e.last=NaN,e.notClearIdx=-1,e}function jD(e,t){var n=e.__cursors,r=+t;return n.get(r)||(e.__cursorStack.push(r),n.set(r,AD({key:r})))}function MD(e,t){for(var n=e.__cursorStack,r=0;r<n.length;r++)t(e.__cursors.get(n[r]))}function ND(e,t){var n=e.layers;return n[t]||(n[t]=[,,,])}function PD(e,t,n){for(var r=e.layerStack,i=0;i<r.length;i++){var a=r[i].zl,o=r[i].zl2,s=e.layers[a][o];(!n||(!(n&FD)||s.__builtin__)&&(!(n&ID)||!s.__builtin__)&&(!(n&LD)||s!==e.hoverlayer))&&t(s,a,o,i)}}var FD=1,ID=2,LD=4,RD=FD|LD,zD=function(){function e(e,t,n,r){this.type=`canvas`,this._prevDisplayList=[],this._layerConfig={},this._needsManuallyCompositing=!1,this.type=`canvas`,this._i={layerStack:[],layers:[]};var i=!e.nodeName||e.nodeName.toUpperCase()===`CANVAS`;if(this._opts=n=I({},n||{}),this.dpr=n.devicePixelRatio||ta,this._singleCanvas=i,this.root=e,e.style&&($e(e),e.innerHTML=``),this.storage=t,this._prevDisplayList=[],i){var a=e,o=a.width,s=a.height;n.width!=null&&(o=n.width),n.height!=null&&(s=n.height),this.dpr=n.devicePixelRatio||1,a.width=o*this.dpr,a.height=s*this.dpr,this._width=o,this._height=s;var c=OD(a,this,SD,0);c.initContext(),this._insertLayer(c,SD,0,!0),this._domRoot=e}else{this._width=fx(e,0,n),this._height=fx(e,1,n);var l=this._domRoot=DD(this._width,this._height);e.appendChild(l)}}return e.prototype.getType=function(){return`canvas`},e.prototype.isSingleCanvas=function(){return this._singleCanvas},e.prototype.getViewportRoot=function(){return this._domRoot},e.prototype.getViewportRootOffset=function(){var e=this.getViewportRoot();if(e)return{offsetLeft:e.offsetLeft||0,offsetTop:e.offsetTop||0}},e.prototype.refresh=function(e){var t=e&&!K(e)?{paintAll:!!e}:e||{},n=q(t.refresh,!0),r=q(t.refreshHover,!1);if(r&&(this._hoverLayerDirty=TD),!n)return r&&this._paintHoverList(this.storage.getDisplayList(!1)),this;var i=this.storage.getDisplayList(!0);this._updateLayerStatus(i,t.paintAll),this._redrawId=Math.random();var a=this._prevDisplayList;this._paintList(i,a,this._redrawId);var o=this._backgroundColor;return PD(this._i,function(e,t,n,r){e.refresh&&e.refresh(r===0?o:null)},ID),this._opts.useDirtyRect&&(this._prevDisplayList=i.slice()),this},e.prototype._paintHoverList=function(e){var t=this._i.hoverlayer,n=this._hoverLayerDirty;if(this._hoverLayerDirty=CD,n!==CD&&(!t&&n===TD&&(t=this._i.hoverlayer=this._ensureLayer(xD)),t)){t.clear();for(var r={inHover:!0,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{}},i,a=0,o=e.length;a<o;a++){var s=e[a];if(s.__inHover){i||(i=t.ctx,i.save());var c=s.__hoverStyle,l=void 0;c&&(l=s.style,s.style=c),Vx(i,s,r),c&&(s.style=l)}}i&&(Hx(i,r),i.restore())}},e.prototype.getHoverLayer=function(){return this._ensureLayer(xD)},e.prototype.paintOne=function(e,t){Bx(e,t)},e.prototype._paintList=function(e,t,n){if(this._redrawId===n){var r=this._doPaintList(e,t);if(this._needsManuallyCompositing&&this._compositeManually(),r)PD(this._i,function(e){e.afterBrush&&e.afterBrush()},RD),this._paintHoverList(e);else{var i=this;or(function(){i._paintList(e,t,n)})}}},e.prototype._compositeManually=function(){var e=this._ensureLayer(SD).ctx,t=this._domRoot.width,n=this._domRoot.height;e.clearRect(0,0,t,n),PD(this._i,function(r){r.virtual&&e.drawImage(r.dom,0,0,t,n)},FD)},e.prototype._doPaintList=function(e,t){var n=this,r=!0;return PD(this._i,function(i){var a=!1;if(MD(i,function(e){(e.drawIdx<e.endIdx||e.notClearIdx>=0)&&(a=!0)}),!(!a&&!i.__dirty)){var o=n._opts.useDirtyRect&&!vD(i)?i.createRepaintRects(e,t,n._width,n._height):null,s=n._i.layerStack[0],c=!0;if(i.__dirty){c=!1,i.__dirty=!1;var l=i.zlevel===s.zl&&i.zlevel2===s.zl2?n._backgroundColor:null;i.clear(!1,l,o)}MD(i,function(t){var a=n._paintPerCursor(i,t,e,o,c);r&&=a})}},RD),j.wxa&&PD(this._i,function(e){e&&e.ctx&&e.ctx.draw&&e.ctx.draw()}),r},e.prototype._paintPerCursor=function(e,t,n,r,i){var a=e.ctx;if(r)if(!r.length)t.drawIdx=t.endIdx;else for(var o=this.dpr,s=0;s<r.length;++s){var c=r[s];a.save(),a.beginPath(),a.rect(c.x*o,c.y*o,c.width*o,c.height*o),a.clip(),this._paintPerCursorInRect(e,t,n,c,i),a.restore()}else a.save(),this._paintPerCursorInRect(e,t,n,null,i),a.restore();return t.drawIdx>=t.endIdx},e.prototype._paintPerCursorInRect=function(e,t,n,r,i){for(var a={inHover:!1,allClipped:!1,prevEl:null,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{contentRetained:i}},o=e.ctx,s=vD(e),c=s&&M.getTime(),l=t.drawIdx,u=t.notClearIdx,d=u>=0?Math.min(u,l):l;d<t.endIdx;d++){var f=n[d];if(!(d<l&&!f.notClear)){if(f.__inHover&&(this._hoverLayerDirty=TD),r!=null){var p=f.getPaintRect();p&&p.intersect(r)&&(Vx(o,f,a),f.setPrevPaintRect(p))}else Vx(o,f,a);if(s&&M.getTime()-c>15){d++;break}}}Hx(o,a),t.drawIdx=Math.max(d,l)},e.prototype.getLayer=function(e,t){return this._ensureLayer(e,0,t)},e.prototype._ensureLayer=function(e,t,n){t||=0;var r=this._singleCanvas;r&&!this._needsManuallyCompositing&&(e=SD,t=0);var i=ND(this._i,e)[t];return i||(i=OD(`zr_`+e+`.`+t,this,e,t),this._layerConfig[e]&&F(i,this._layerConfig[e],!0),(n||r&&e!==SD)&&(i.virtual=!0),this._insertLayer(i,e,t,!1),i.initContext()),i},e.prototype.insertLayer=function(e,t){this._insertLayer(t,e,0,!1)},e.prototype._insertLayer=function(e,t,n,r){var i=this._i,a=i.layers,o=i.layerStack,s=this._domRoot,c=null;if(!(a[t]&&a[t][n])&&ED(e)){for(var l=o.length,u=0;u<l&&(o[u].zl<t||o[u].zl===t&&o[u].zl2<n);)u++;if(u>0&&(c=ND(i,o[u-1].zl)[o[u-1].zl2]),o.splice(u,0,{zl:t,zl2:n}),ND(i,t)[n]=e,!r&&!e.virtual)if(c){var d=c.dom;d.nextSibling?s.insertBefore(e.dom,d.nextSibling):s.appendChild(e.dom)}else s.firstChild?s.insertBefore(e.dom,s.firstChild):s.appendChild(e.dom);e.painter||=this}},e.prototype.eachLayer=function(e,t){return PD(this._i,function(n,r){e.call(t,n,r)})},e.prototype.eachBuiltinLayer=function(e,t){return PD(this._i,function(n,r){e.call(t,n,r)},FD)},e.prototype.eachOtherLayer=function(e,t){return PD(this._i,function(n,r){e.call(t,n,r)},ID)},e.prototype.getLayers=function(){var e={};return PD(this._i,function(t,n,r){e[t.id]=t}),e},e.prototype._updateLayerStatus=function(e,t){var n=this;if(n._singleCanvas)for(var r=1;r<e.length;r++){var i=e[r];if(i.zlevel!==e[r-1].zlevel||i.incremental){n._needsManuallyCompositing=!0;break}}PD(n._i,function(e){e.__dirty=!1,MD(e,function(e){e.used=!1,e.endIdxNew=0,e.notClearIdx=-1})},RD);for(var a,o=null,s=null,c=!1,l=0,u=e.length;l<u;l++){var i=e[l],d=i.zlevel,f=i.incremental,p=void 0;if(a!==d&&(a=d,c=!1),f?(c=!0,p=1):p=c?2:0,(!o||d!==o.zlevel||p!==o.zlevel2)&&(o=n._ensureLayer(d,p),s=null,!o.__builtin__)){be(`ZLevel `+d+` has been used by unknown layer `+o.id);continue}if((!s||f!==s.key)&&(s=jD(o,f),!s.used))if(s.used=!0,!t&&s.first===i.id){var m=l-s.startIdx;s.startIdx=l,s.drawIdx+=m,s.endIdx+=m}else o.__dirty=!0,s.first=i.id,s.startIdx=s.drawIdx=l,s.endIdx=l+1;s.endIdxNew=l+1,i.__dirty&1&&!i.__inHover&&((!f||!i.notClear&&l<s.drawIdx)&&(o.__dirty=!0),f&&i.notClear&&s.notClearIdx<0&&(s.notClearIdx=l))}PD(n._i,function(t){for(var r=t.__cursorStack,i=t.__cursors,a=r.length-1;a>=0;a--){var o=i.get(r[a]);if(!o.used)t.__dirty=!0,i.removeKey(r[a]),r.splice(a,1);else{var s=o.endIdxNew;(vD(t)?s<o.drawIdx:s!==o.endIdx||!s||e[s-1].id!==o.last)&&(t.__dirty=!0),o.endIdx=o.endIdxNew,o.last=s?e[s-1].id:NaN}}t.__dirty&&(MD(t,function(e){e.drawIdx=e.startIdx}),n._hoverLayerDirty===CD&&(n._hoverLayerDirty=wD))},RD)},e.prototype.clear=function(){return PD(this._i,function(e){e.clear(),kD(e)},FD),this},e.prototype.setBackgroundColor=function(e){this._backgroundColor=e,PD(this._i,function(e){e.setUnpainted()})},e.prototype.configLayer=function(e,t){if(t){var n=this._layerConfig;n[e]?F(n[e],t,!0):n[e]=t,PD(this._i,function(e,t){F(e,n[t],!0)})}},e.prototype.delLayer=function(e){for(var t=this._i.layerStack,n=this._i.layers,r=t.length-1;r>=0;r--){var i=t[r];if(i.zl===e){var a=n[e][i.zl2];if(a.__builtin__)continue;if(t.splice(r,1),n[e][i.zl2]=void 0,!a.virtual){var o=a.dom.parentNode;o&&o.removeChild(a.dom)}}}},e.prototype.resize=function(e,t){if(this._domRoot.style){var n=this._domRoot;n.style.display=`none`;var r=this._opts,i=this.root;e!=null&&(r.width=e),t!=null&&(r.height=t),e=fx(i,0,r),t=fx(i,1,r),n.style.display=``,(this._width!==e||t!==this._height)&&(n.style.width=e+`px`,n.style.height=t+`px`,PD(this._i,function(n){n.resize(e,t)}),this.refresh({paintAll:!0})),this._width=e,this._height=t}else{if(e==null||t==null)return;this._width=e,this._height=t,this._ensureLayer(SD).resize(e,t)}return this},e.prototype.clearLayer=function(e){z(this._i.layers[e],function(e){e&&!e.__builtin__&&e.clear()})},e.prototype.dispose=function(){this.root.innerHTML=``,this.root=this.storage=this._domRoot=this._i=null},e.prototype.getRenderedCanvas=function(e){if(e||={},this._singleCanvas&&!this._compositeManually)return this._i.layers[SD][0].dom;var t=new bD(`image`,this,e.pixelRatio||this.dpr);t.initContext(),t.clear(!1,e.backgroundColor||this._backgroundColor);var n=t.ctx;if(e.pixelRatio<=this.dpr){this.refresh();var r=t.dom.width,i=t.dom.height;PD(this._i,function(e){e.__builtin__?n.drawImage(e.dom,0,0,r,i):e.renderToCanvas&&(n.save(),e.renderToCanvas(n),n.restore())})}else{for(var a={inHover:!1,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{}},o=this.storage.getDisplayList(!0),s=0,c=o.length;s<c;s++){var l=o[s];Vx(n,l,a)}Hx(n,a)}return t.dom},e.prototype.getWidth=function(){return this._width},e.prototype.getHeight=function(){return this._height},e}();function BD(e){e.registerPainter(`canvas`,zD)}var VD=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.hasSymbolVisual=!0,n}return t.prototype.getInitialData=function(e){return xw(null,this,{useEncodeDefaulter:!0})},t.prototype.getLegendIcon=function(e){var t=new Ya,n=rx(`line`,0,e.itemHeight/2,e.itemWidth,0,e.lineStyle.stroke,!1);t.add(n),n.setStyle(e.lineStyle);var r=this.getData().getVisual(`symbol`),i=this.getData().getVisual(`symbolRotate`),a=r===`none`?`circle`:r,o=e.itemHeight*.8,s=rx(a,(e.itemWidth-o)/2,(e.itemHeight-o)/2,o,o,e.itemStyle.fill);return t.add(s),s.setStyle(e.itemStyle),s.rotation=(e.iconRotate===`inherit`?i:e.iconRotate||0)*Math.PI/180,s.setOrigin([e.itemWidth/2,e.itemHeight/2]),a.indexOf(`empty`)>-1&&(s.style.stroke=s.style.fill,s.style.fill=Q.color.neutral00,s.style.lineWidth=2),t},t.type=`series.line`,t.dependencies=[`grid`,`polar`],t.defaultOption={z:3,coordinateSystem:`cartesian2d`,legendHoverLink:!0,clip:!0,label:{position:`top`},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:`solid`},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:`emptyCircle`,symbolSize:6,symbolRotate:null,showSymbol:!0,showAllSymbol:`auto`,connectNulls:!1,sampling:`none`,animationEasing:`linear`,progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:`clone`},triggerLineEvent:!1,triggerEvent:!1},t}(Ey);function HD(e,t){var n=e.mapDimensionsAll(`defaultedLabel`),r=n.length;if(r===1){var i=yv(e,t,n[0]);return i==null?null:i+``}else if(r){for(var a=[],o=0;o<n.length;o++)a.push(yv(e,t,n[o]));return a.join(` `)}}function UD(e,t){var n=e.mapDimensionsAll(`defaultedLabel`);if(!U(t))return t+``;for(var r=[],i=0;i<n.length;i++){var a=e.getDimensionIndex(n[i]);a>=0&&r.push(t[a])}return r.join(` `)}var WD=function(e){k(t,e);function t(t,n,r,i){var a=e.call(this)||this;return a.updateData(t,n,r,i),a}return t.prototype._createSymbol=function(e,t,n,r,i,a){this.removeAll();var o=rx(e,-1,-1,2,2,null,a);o.attr({z2:q(i,100),culling:!0,scaleX:r[0]/2,scaleY:r[1]/2}),o.drift=GD,this._symbolType=e,this.add(o)},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(){_d(this.childAt(0))},t.prototype.downplay=function(){vd(this.childAt(0))},t.prototype.setZ=function(e,t){var n=this.childAt(0);n.zlevel=e,n.z=t},t.prototype.setDraggable=function(e,t){var n=this.childAt(0);n.draggable=e,n.cursor=!t&&e?`move`:n.cursor},t.prototype.updateData=function(e,n,r,i){this.silent=!1;var a=e.getItemVisual(n,`symbol`)||`circle`,o=e.hostModel,s=t.getSymbolSize(e,n),c=t.getSymbolZ2(e,n),l=a!==this._symbolType,u=i&&i.disableAnimation;if(l){var d=e.getItemVisual(n,`symbolKeepAspect`);this._createSymbol(a,e,n,s,c,d)}else{var f=this.childAt(0);f.silent=!1;var p={scaleX:s[0]/2,scaleY:s[1]/2};u?f.attr(p):vp(f,p,o,n),wp(f)}if(this._updateCommon(e,n,s,r,i),l){var f=this.childAt(0);if(!u){var p={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:f.style.opacity}};f.scaleX=f.scaleY=0,f.style.opacity=0,yp(f,p,o,n)}}u&&this.childAt(0).stopAnimation(`leave`)},t.prototype._updateCommon=function(e,t,n,r,i){var a=this.childAt(0),o=e.hostModel,s,c,l,u,d,f,p,m,h;if(r&&(s=r.emphasisItemStyle,c=r.blurItemStyle,l=r.selectItemStyle,u=r.focus,d=r.blurScope,p=r.labelStatesModels,m=r.hoverScale,h=r.cursorStyle,f=r.emphasisDisabled),!r||e.hasItemOption){var g=r&&r.itemModel?r.itemModel:e.getItemModel(t),_=g.getModel(`emphasis`);s=_.getModel(`itemStyle`).getItemStyle(),l=g.getModel([`select`,`itemStyle`]).getItemStyle(),c=g.getModel([`blur`,`itemStyle`]).getItemStyle(),u=_.get(`focus`),d=_.get(`blurScope`),f=_.get(`disabled`),p=Cm(g),m=_.getShallow(`scale`),h=g.getShallow(`cursor`)}var v=e.getItemVisual(t,`symbolRotate`);a.attr(`rotation`,(v||0)*Math.PI/180||0);var y=ax(e.getItemVisual(t,`symbolOffset`),n);y&&(a.x=y[0],a.y=y[1]),h&&a.attr(`cursor`,h);var b=e.getItemVisual(t,`style`),x=b.fill;if(a instanceof eu){var S=a.style;a.useStyle(I({image:S.image,x:S.x,y:S.y,width:S.width,height:S.height},b))}else a.__isEmptyBrush?a.useStyle(I({},b)):a.useStyle(b),a.style.decal=null,a.setColor(x,i&&i.symbolInnerColor),a.style.strokeNoScale=!0;var C=e.getItemVisual(t,`liftZ`),w=this._z2;C==null?w!=null&&(a.z2=w,this._z2=null):w??(this._z2=a.z2,a.z2+=C);var T=i&&i.useNameLabel;Sm(a,p,{labelFetcher:o,labelDataIndex:t,defaultText:E,inheritColor:x,defaultOpacity:b.opacity});function E(t){return T?e.getName(t):HD(e,t)}this._sizeX=n[0]/2,this._sizeY=n[1]/2;var D=a.ensureState(`emphasis`);D.style=s,a.ensureState(`select`).style=l,a.ensureState(`blur`).style=c;var O=m==null||m===!0?Math.max(1.1,3/this._sizeY):isFinite(m)&&m>0?+m:1;D.scaleX=this._sizeX*O,D.scaleY=this._sizeY*O,this.setSymbolScale(1),Id(this,u,d,f)},t.prototype.setSymbolScale=function(e){this.scaleX=this.scaleY=e},t.prototype.fadeOut=function(e,t,n){var r=this.childAt(0),i=Du(this).dataIndex,a=n&&n.animation;if(this.silent=r.silent=!0,n&&n.fadeLabel){var o=r.getTextContent();o&&xp(o,{style:{opacity:0}},t,{dataIndex:i,removeOpt:a,cb:function(){r.removeTextContent()}})}else r.removeTextContent();xp(r,{style:{opacity:0},scaleX:0,scaleY:0},t,{dataIndex:i,cb:e,removeOpt:a})},t.getSymbolSize=function(e,t){return ix(e.getItemVisual(t,`symbolSize`))},t.getSymbolZ2=function(e,t){return e.getItemVisual(t,`z2`)},t}(Ya);function GD(e,t){this.parent.drift(e,t)}function KD(e,t,n,r){return t&&!isNaN(t[0])&&!isNaN(t[1])&&!(r&&r.isIgnore&&r.isIgnore(n))&&!(r&&r.clipShape&&!r.clipShape.contain(t[0],t[1]))&&e.getItemVisual(n,`symbol`)!==`none`}function qD(e){return e!=null&&!K(e)&&(e={isIgnore:e}),e||{}}function JD(e){var t=e.hostModel,n=t.getModel(`emphasis`);return{emphasisItemStyle:n.getModel(`itemStyle`).getItemStyle(),blurItemStyle:t.getModel([`blur`,`itemStyle`]).getItemStyle(),selectItemStyle:t.getModel([`select`,`itemStyle`]).getItemStyle(),focus:n.get(`focus`),blurScope:n.get(`blurScope`),emphasisDisabled:n.get(`disabled`),hoverScale:n.get(`scale`),labelStatesModels:Cm(t),cursorStyle:t.get(`cursor`)}}function YD(e,t,n,r,i,a,o){var s=new e(t,n,r,i);return s.setPosition(a),t.setItemGraphicEl(n,s),o.add(s),s}var XD=function(){function e(e){this.group=new Ya,this._SymbolCtor=e||WD}return e.prototype.updateData=function(e,t){this._progressiveEls=null,t=qD(t);var n=this.group,r=e.hostModel,i=this._data,a=this._SymbolCtor,o=t.disableAnimation,s=this._seriesScope=JD(e),c={disableAnimation:o},l=t.getSymbolPoint||function(t){return e.getItemLayout(t)};i||n.removeAll(),e.diff(i).add(function(r){var i=l(r);KD(e,i,r,t)&&YD(a,e,r,s,c,i,n)}).update(function(u,d){var f=i.getItemGraphicEl(d),p=l(u);if(!KD(e,p,u,t)){n.remove(f);return}var m=e.getItemVisual(u,`symbol`)||`circle`,h=f&&f.getSymbolType&&f.getSymbolType();if(!f||h&&h!==m)n.remove(f),f=new a(e,u,s,c),f.setPosition(p);else{f.updateData(e,u,s,c);var g={x:p[0],y:p[1]};o?f.attr(g):vp(f,g,r)}n.add(f),e.setItemGraphicEl(u,f)}).remove(function(e){var t=i.getItemGraphicEl(e);t&&t.fadeOut(function(){n.remove(t)},r)}).execute(),this._getSymbolPoint=l,this._data=e},e.prototype.updateLayout=function(e){var t=this._data;if(t)for(var n=this,r=t.getStore(),i=0,a=r.count();i<a;i++){var o=t.getItemGraphicEl(i),s=n._getSymbolPoint(i);KD(t,s,i,e)?(o||=YD(n._SymbolCtor,t,i,n._seriesScope,{disableAnimation:!0},s,n.group),o.stopAnimation(),o.setPosition(s),o.markRedraw()):o&&(n.group.remove(o),t.setItemGraphicEl(i,null))}},e.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=JD(e),this._data=null,this.group.removeAll()},e.prototype.incrementalUpdate=function(e,t,n,r){this._progressiveEls=[],r=qD(r);function i(e){e.isGroup||(e.incremental=n,e.ensureState(`emphasis`).hoverLayer=2)}for(var a=e.start;a<e.end;a++){var o=t.getItemLayout(a);if(KD(t,o,a,r)){var s=new this._SymbolCtor(t,a,this._seriesScope);s.traverse(i),s.setPosition(o),this.group.add(s),t.setItemGraphicEl(a,s),this._progressiveEls.push(s)}}},e.prototype.eachRendered=function(e){om(this._progressiveEls||this.group,e)},e.prototype.remove=function(e){var t=this.group,n=this._data;n&&e?n.eachItemGraphicEl(function(e){e.fadeOut(function(){t.remove(e)},n.hostModel)}):t.removeAll()},e}();function ZD(e,t,n){var r=e.getBaseAxis(),i=e.getOtherAxis(r),a=QD(i,n),o=r.dim,s=i.dim,c=t.mapDimension(s),l=t.mapDimension(o),u=+(s===`x`||s===`radius`),d=B(e.dimensions,function(e){return t.mapDimension(e)}),f=!1,p=t.getCalculationInfo(`stackResultDimension`);return _w(t,d[0])&&(f=!0,d[0]=p),_w(t,d[1])&&(f=!0,d[1]=p),{dataDimsForPoint:d,valueStart:a,valueAxisDim:s,baseAxisDim:o,stacked:!!f,valueDim:c,baseDim:l,baseDataOffset:u,stackedOverDimension:t.getCalculationInfo(`stackedOverDimension`)}}function QD(e,t){var n=0,r=e.scale.getExtent();return t===`start`?n=r[0]:t===`end`?n=r[1]:je(t)&&!isNaN(t)?n=t:r[0]>0?n=r[0]:r[1]<0&&(n=r[1]),n}function $D(e,t,n,r){var i=NaN;e.stacked&&(i=n.get(n.getCalculationInfo(`stackedOverDimension`),r)),isNaN(i)&&(i=e.valueStart);var a=e.baseDataOffset,o=[];return o[a]=n.get(e.baseDim,r),o[1-a]=i,t.dataToPoint(o)}function eO(e,t){return!isFinite(e)||!isFinite(t)}var tO=typeof Float32Array<`u`?Float32Array:void 0;function nO(e){return rO({ctor:tO},e).arr}function rO(e,t){var n=e.arr,r=e.ctor;if(t>Oo&&(t=Oo),!n||e.typed&&n.length<t){var i=void 0;if(r)try{i=new r(t),e.typed=!0,n&&i.set(n)}catch{}if(!i&&(i=[],e.typed=!1,n))for(var a=0,o=n.length;a<o;a++)i[a]=n[a];e.arr=i}return e}function iO(e,t){var n=[];return t.diff(e).add(function(e){n.push({cmd:`+`,idx:e})}).update(function(e,t){n.push({cmd:`=`,idx:t,idx1:e})}).remove(function(e){n.push({cmd:`-`,idx:e})}).execute(),n}function aO(e,t,n,r,i,a,o,s){for(var c=iO(e,t),l=[],u=[],d=[],f=[],p=[],m=[],h=[],g=ZD(i,t,o),_=e.getLayout(`points`)||[],v=t.getLayout(`points`)||[],y=0;y<c.length;y++){var b=c[y],x=!0,S=void 0,C=void 0;switch(b.cmd){case`=`:S=b.idx*2,C=b.idx1*2;var w=_[S],T=_[S+1],E=v[C],D=v[C+1];(isNaN(w)||isNaN(T))&&(w=E,T=D),l.push(w,T),u.push(E,D),d.push(n[S],n[S+1]),f.push(r[C],r[C+1]),h.push(t.getRawIndex(b.idx1));break;case`+`:var O=b.idx,k=g.dataDimsForPoint,A=i.dataToPoint([t.get(k[0],O),t.get(k[1],O)]);C=O*2,l.push(A[0],A[1]),u.push(v[C],v[C+1]);var j=$D(g,i,t,O);d.push(j[0],j[1]),f.push(r[C],r[C+1]),h.push(t.getRawIndex(O));break;case`-`:x=!1}x&&(p.push(b),m.push(m.length))}m.sort(function(e,t){return h[e]-h[t]});for(var ee=l.length,te=nO(ee),ne=nO(ee),re=nO(ee),ie=nO(ee),ae=[],y=0;y<m.length;y++){var oe=m[y],M=y*2,se=oe*2;te[M]=l[se],te[M+1]=l[se+1],ne[M]=u[se],ne[M+1]=u[se+1],re[M]=d[se],re[M+1]=d[se+1],ie[M]=f[se],ie[M+1]=f[se+1],ae[y]=p[oe]}return{current:te,next:ne,stackedOnCurrent:re,stackedOnNext:ie,status:ae}}var oO=Math.min,sO=Math.max;function cO(e,t,n,r,i,a,o,s,c){for(var l,u,d,f,p,m,h=n,g=0;g<r;g++){var _=t[h*2],v=t[h*2+1];if(h>=i||h<0)break;if(eO(_,v)){if(c){h+=a;continue}break}if(h===n)e[a>0?`moveTo`:`lineTo`](_,v),d=_,f=v;else{var y=_-l,b=v-u;if(y*y+b*b<.5){h+=a;continue}if(o>0){for(var x=h+a,S=t[x*2],C=t[x*2+1];S===_&&C===v&&g<r;)g++,x+=a,h+=a,S=t[x*2],C=t[x*2+1],_=t[h*2],v=t[h*2+1],y=_-l,b=v-u;var w=g+1;if(c)for(;eO(S,C)&&w<r;)w++,x+=a,S=t[x*2],C=t[x*2+1];var T=.5,E=0,D=0,O=void 0,k=void 0;if(w>=r||eO(S,C))p=_,m=v;else{E=S-l,D=C-u;var A=_-l,j=S-_,ee=v-u,te=C-v,ne=void 0,re=void 0;if(s===`x`){ne=Math.abs(A),re=Math.abs(j);var ie=E>0?1:-1;p=_-ie*ne*o,m=v,O=_+ie*re*o,k=v}else if(s===`y`){ne=Math.abs(ee),re=Math.abs(te);var ae=D>0?1:-1;p=_,m=v-ae*ne*o,O=_,k=v+ae*re*o}else ne=Math.sqrt(A*A+ee*ee),re=Math.sqrt(j*j+te*te),T=re/(re+ne),p=_-E*o*(1-T),m=v-D*o*(1-T),O=_+E*o*T,k=v+D*o*T,O=oO(O,sO(S,_)),k=oO(k,sO(C,v)),O=sO(O,oO(S,_)),k=sO(k,oO(C,v)),E=O-_,D=k-v,p=_-E*ne/re,m=v-D*ne/re,p=oO(p,sO(l,_)),m=oO(m,sO(u,v)),p=sO(p,oO(l,_)),m=sO(m,oO(u,v)),E=_-p,D=v-m,O=_+E*re/ne,k=v+D*re/ne}e.bezierCurveTo(d,f,p,m,_,v),d=O,f=k}else e.lineTo(_,v)}l=_,u=v,h+=a}return g}var lO=function(){function e(){this.smooth=0,this.smoothConstraint=!0}return e}(),uO=function(e){k(t,e);function t(t){var n=e.call(this,t)||this;return n.type=`ec-polyline`,n}return t.prototype.getDefaultStyle=function(){return{stroke:Q.color.neutral99,fill:null}},t.prototype.getDefaultShape=function(){return new lO},t.prototype.buildPath=function(e,t){var n=t.points,r=0,i=n.length/2;if(t.connectNulls){for(;i>0&&eO(n[i*2-2],n[i*2-1]);i--);for(;r<i&&eO(n[r*2],n[r*2+1]);r++);}for(;r<i;)r+=cO(e,n,r,i,i,1,t.smooth,t.smoothMonotone,t.connectNulls)+1},t.prototype.getPointOn=function(e,t){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var n=this.path.data,r=Cl.CMD,i,a,o=t===`x`,s=[],c=0;c<n.length;){var l=n[c++],u=void 0,d=void 0,f=void 0,p=void 0,m=void 0,h=void 0,g=void 0;switch(l){case r.M:i=n[c++],a=n[c++];break;case r.L:if(u=n[c++],d=n[c++],g=o?(e-i)/(u-i):(e-a)/(d-a),g<=1&&g>=0){var _=o?(d-a)*g+a:(u-i)*g+i;return o?[e,_]:[_,e]}i=u,a=d;break;case r.C:u=n[c++],d=n[c++],f=n[c++],p=n[c++],m=n[c++],h=n[c++];var v=o?xr(i,u,f,m,e,s):xr(a,d,p,h,e,s);if(v>0)for(var y=0;y<v;y++){var b=s[y];if(b<=1&&b>=0){var _=o?yr(a,d,p,h,b):yr(i,u,f,m,b);return o?[e,_]:[_,e]}}i=m,a=h;break}}},t}(Jl),dO=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t}(lO),fO=function(e){k(t,e);function t(t){var n=e.call(this,t)||this;return n.type=`ec-polygon`,n}return t.prototype.getDefaultShape=function(){return new dO},t.prototype.buildPath=function(e,t){var n=t.points,r=t.stackedOnPoints,i=0,a=n.length/2,o=t.smoothMonotone;if(t.connectNulls){for(;a>0&&eO(n[a*2-2],n[a*2-1]);a--);for(;i<a&&eO(n[i*2],n[i*2+1]);i++);}for(;i<a;){var s=cO(e,n,i,a,a,1,t.smooth,o,t.connectNulls);cO(e,r,i+s-1,s,a,-1,t.stackedOnSmooth,o,t.connectNulls),i+=s+1,e.closePath()}},t}(Jl);function pO(e,t,n,r,i){var a=e.getArea(),o=a.x,s=a.y,c=a.width,l=a.height,u=n.get([`lineStyle`,`width`])||0;o-=u/2,s-=u/2,c+=u,l+=u,c=Math.ceil(c),o!==Math.floor(o)&&(o=Math.floor(o),c++);var d=new cu({shape:{x:o,y:s,width:c,height:l}});if(t){var f=e.getBaseAxis(),p=f.isHorizontal(),m=f.inverse;p?(m&&(d.shape.x+=c),d.shape.width=0):(m||(d.shape.y+=l),d.shape.height=0);var h=W(i)?function(e){i(e,d)}:null;yp(d,{shape:{width:c,height:l,x:o,y:s}},n,null,r,h)}return d}function mO(e,t,n){var r=e.getArea(),i=X(r.r0,1),a=X(r.r,1),o=new If({shape:{cx:X(e.cx,1),cy:X(e.cy,1),r0:i,r:a,startAngle:r.startAngle,endAngle:r.endAngle,clockwise:r.clockwise}});return t&&(e.getBaseAxis().dim===`angle`?o.shape.endAngle=r.startAngle:o.shape.r=i,yp(o,{shape:{endAngle:r.endAngle,r:a}},n)),o}function hO(e){var t=e.coordinateSystem;if(e.get(`clip`,!0)&&t&&(!t.shouldClip||t.shouldClip()))return t.getArea&&t.getArea(.1)}function gO(e,t){return e.type===t}function _O(e,t){if(e.length===t.length){for(var n=0;n<e.length;n++)if(e[n]!==t[n])return;return!0}}function vO(e){for(var t=ks(),n=ks(),r=0;r<e.length;){var i=e[r++],a=e[r++];eO(i,a)||(As(t,i),As(n,a))}return[t,n]}function yO(e,t){var n=vO(e),r=n[0],i=n[1],a=vO(t),o=a[0],s=a[1];return Math.max(Math.abs(r[0]-o[0]),Math.abs(i[0]-s[0]),Math.abs(r[1]-o[1]),Math.abs(i[1]-s[1]))}function bO(e){return je(e)?e:e?.5:0}function xO(e,t,n){if(n.valueDim==null)return[];for(var r=t.count(),i=nO(r*2),a=0;a<r;a++){var o=$D(n,e,t,a);i[a*2]=o[0],i[a*2+1]=o[1]}return i}function SO(e,t,n,r,i){var a=n.getBaseAxis(),o=a.dim===`x`||a.dim===`radius`?0:1,s=[],c=0,l=[],u=[],d=[],f=[];if(i){for(c=0;c<e.length;c+=2){var p=t||e;eO(p[c],p[c+1])||f.push(e[c],e[c+1])}e=f}for(c=0;c<e.length-2;c+=2)switch(d[0]=e[c+2],d[1]=e[c+3],u[0]=e[c],u[1]=e[c+1],s.push(u[0],u[1]),r){case`end`:l[o]=d[o],l[1-o]=u[1-o],s.push(l[0],l[1]);break;case`middle`:var m=(u[o]+d[o])/2,h=[];l[o]=h[o]=m,l[1-o]=u[1-o],h[1-o]=d[1-o],s.push(l[0],l[1]),s.push(h[0],h[1]);break;default:l[o]=u[o],l[1-o]=d[1-o],s.push(l[0],l[1])}return s.push(e[c++],e[c++]),s}function CO(e,t){var n=[],r=e.length,i,a;function o(e,t,n){var r=e.coord;return{coord:n,color:ni((n-r)/(t.coord-r),[e.color,t.color])}}for(var s=0;s<r;s++){var c=e[s],l=c.coord;if(l<0)i=c;else if(l>t){a?n.push(o(a,c,t)):i&&n.push(o(i,c,0),o(i,c,t));break}else i&&=(n.push(o(i,c,0)),null),n.push(c),a=c}return n}function wO(e,t,n){var r=e.getVisual(`visualMeta`);if(!(!r||!r.length||!e.count())&&t.type===`cartesian2d`){for(var i,a,o=r.length-1;o>=0;o--){var s=e.getDimensionInfo(r[o].dimension);if(i=s&&s.coordDim,i===`x`||i===`y`){a=r[o];break}}if(a){var c=t.getAxis(i),l=B(a.stops,function(e){return{coord:c.toGlobalCoord(c.dataToCoord(e.value)),color:e.color}}),u=l.length,d=a.outerColors.slice();u&&l[0].coord>l[u-1].coord&&(l.reverse(),d.reverse());var f=CO(l,i===`x`?n.getWidth():n.getHeight()),p=f.length;if(!p&&u)return l[0].coord<0?d[1]?d[1]:l[u-1].color:d[0]?d[0]:l[0].color;var m=10,h=f[0].coord-m,g=f[p-1].coord+m,_=g-h;if(_<.001)return`transparent`;z(f,function(e){e.offset=(e.coord-h)/_}),f.push({offset:p?f[p-1].offset:.5,color:d[1]||`transparent`}),f.unshift({offset:p?f[0].offset:.5,color:d[0]||`transparent`});var v=new np(0,0,0,0,f,!0);return v[i]=h,v[i+`2`]=g,v}}}function TO(e,t,n){var r=e.get(`showAllSymbol`),i=r===`auto`;if(!(r&&!i)){var a=n.getAxesByScale(`ordinal`)[0];if(a&&!(i&&EO(a,t))){var o=t.mapDimension(a.dim),s={};return z(a.getViewLabels(),function(e){e.tick.offInterval||(s[RT(a.scale,e.tick)]=1)}),function(e){return!s.hasOwnProperty(t.get(o,e))}}}}function EO(e,t){var n=e.getExtent(),r=Math.abs(n[1]-n[0])/e.scale.count();isNaN(r)&&(r=0);for(var i=t.count(),a=Math.max(1,Math.round(i/5)),o=0;o<i;o+=a)if(WD.getSymbolSize(t,o)[+!!e.isHorizontal()]*1.5>r)return!1;return!0}function DO(e){for(var t=e.length/2;t>0&&eO(e[t*2-2],e[t*2-1]);t--);return t-1}function OO(e,t){return[e[t*2],e[t*2+1]]}function kO(e,t,n){for(var r=e.length/2,i=n===`x`?0:1,a,o,s=0,c=-1,l=0;l<r;l++)if(o=e[l*2+i],!eO(o,e[l*2+1-i])){if(l===0){a=o;continue}if(a<=t&&o>=t||a>=t&&o<=t){c=l;break}s=l,a=o}return{range:[s,c],t:(t-a)/(o-a)}}function AO(e){if(e.get([`endLabel`,`show`]))return!0;for(var t=0;t<Wu.length;t++)if(e.get([Wu[t],`endLabel`,`show`]))return!0;return!1}function jO(e,t,n,r){if(gO(t,`cartesian2d`)){var i=r.getModel(`endLabel`),a=i.get(`valueAnimation`),o=r.getData(),s={lastFrameIndex:0},c=AO(r)?function(n,r){e._endLabelOnDuring(n,r,o,s,a,i,t)}:null,l=t.getBaseAxis().isHorizontal(),u=pO(t,n,r,function(){var t=e._endLabel;t&&n&&s.originalX!=null&&t.attr({x:s.originalX,y:s.originalY})},c);if(!r.get(`clip`,!0)){var d=u.shape,f=Math.max(d.width,d.height);l?(d.y-=f,d.height+=f*2):(d.x-=f,d.width+=f*2)}return c&&c(1,u),u}else return mO(t,n,r)}function MO(e,t){var n=t.getBaseAxis(),r=n.isHorizontal(),i=n.inverse,a=r?i?`right`:`left`:`center`,o=r?`middle`:i?`top`:`bottom`;return{normal:{align:e.get(`align`)||a,verticalAlign:e.get(`verticalAlign`)||o}}}var NO=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.init=function(){var e=new Ya,t=new XD;this.group.add(t.group),this._symbolDraw=t,this._lineGroup=e,this._changePolyState=V(this._changePolyState,this)},t.prototype.render=function(e,t,n){var r=e.coordinateSystem,i=this.group,a=e.getData(),o=e.getModel(`lineStyle`),s=e.getModel(`areaStyle`),c=a.getLayout(`points`)||[],l=r.type===`polar`,u=this._coordSys,d=this._symbolDraw,f=this._polyline,p=this._polygon,m=this._lineGroup,h=!t.ssr&&e.get(`animation`),g=!s.isEmpty(),_=s.get(`origin`),v=ZD(r,a,_),y=g&&xO(r,a,v),b=e.get(`showSymbol`),x=e.get(`connectNulls`),S=b&&!l&&TO(e,a,r),C=this._data;C&&C.eachItemGraphicEl(function(e,t){e.__temp&&(i.remove(e),C.setItemGraphicEl(t,null))}),b||d.remove(),i.add(m);var w=l?!1:e.get(`step`),T;r&&r.getArea&&e.get(`clip`,!0)&&(T=r.getArea(),T.width==null?T.r0&&(T.r0-=.5,T.r+=.5):(T.x-=.1,T.y-=.1,T.width+=.2,T.height+=.2)),this._clipShapeForSymbol=T;var E=wO(a,r,n)||a.getVisual(`style`)[a.getVisual(`drawType`)];if(!(f&&u.type===r.type&&w===this._step))b&&d.updateData(a,{isIgnore:S,clipShape:T,disableAnimation:!0,getSymbolPoint:function(e){return[c[e*2],c[e*2+1]]}}),h&&this._initSymbolLabelAnimation(a,r,T),w&&(y&&=SO(y,c,r,w,x),c=SO(c,null,r,w,x)),f=this._newPolyline(c),g?p=this._newPolygon(c,y):p&&=(m.remove(p),this._polygon=null),l||this._initOrUpdateEndLabel(e,r,ig(E)),m.setClipPath(jO(this,r,!0,e));else{g&&!p?p=this._newPolygon(c,y):p&&!g&&(m.remove(p),p=this._polygon=null),l||this._initOrUpdateEndLabel(e,r,ig(E));var D=m.getClipPath();D?yp(D,{shape:jO(this,r,!1,e).shape},e):m.setClipPath(jO(this,r,!0,e)),b&&d.updateData(a,{isIgnore:S,clipShape:T,disableAnimation:!0,getSymbolPoint:function(e){return[c[e*2],c[e*2+1]]}}),(!_O(this._stackedOnPoints,y)||!_O(this._points,c))&&(h?this._doUpdateAnimation(a,y,r,n,w,_,x):(w&&(y&&=SO(y,c,r,w,x),c=SO(c,null,r,w,x)),f.setShape({points:c}),p&&p.setShape({points:c,stackedOnPoints:y})))}var O=e.getModel(`emphasis`),k=O.get(`focus`),A=O.get(`blurScope`),j=O.get(`disabled`);if(f.useStyle(L(o.getLineStyle(),{fill:`none`,stroke:E,lineJoin:`bevel`})),Bd(f,e,`lineStyle`),f.style.lineWidth>0&&e.get([`emphasis`,`lineStyle`,`width`])===`bolder`){var ee=f.getState(`emphasis`).style;ee.lineWidth=+f.style.lineWidth+1}Du(f).seriesIndex=e.seriesIndex,Id(f,k,A,j);var te=bO(e.get(`smooth`)),ne=e.get(`smoothMonotone`);if(f.setShape({smooth:te,smoothMonotone:ne,connectNulls:x}),p){var re=a.getCalculationInfo(`stackedOnSeries`),ie=0;p.useStyle(L(s.getAreaStyle(),{fill:E,opacity:.7,lineJoin:`bevel`,decal:a.getVisual(`style`).decal})),re&&(ie=bO(re.get(`smooth`))),p.setShape({smooth:te,stackedOnSmooth:ie,smoothMonotone:ne,connectNulls:x}),Bd(p,e,`areaStyle`),Du(p).seriesIndex=e.seriesIndex,Id(p,k,A,j)}var ae=this._changePolyState;a.eachItemGraphicEl(function(e){e&&(e.onHoverStateChange=ae)}),this._polyline.onHoverStateChange=ae,this._data=a,this._coordSys=r,this._stackedOnPoints=y,this._points=c,this._step=w,this._valueOrigin=_;var oe=e.get(`triggerEvent`),M=e.get(`triggerLineEvent`),se=M===!0||oe===!0||oe===`line`,ce=M===!0||oe===!0||oe===`area`;this.packEventData(e,f,se),p&&this.packEventData(e,p,ce)},t.prototype.packEventData=function(e,t,n){Du(t).eventData=n?{componentType:`series`,componentSubType:`line`,componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:`line`,selfType:t===this._polygon?`area`:`line`}:null},t.prototype.highlight=function(e,t,n,r){var i=e.getData(),a=_s(i,r);if(this._changePolyState(`emphasis`),!(a instanceof Array)&&a!=null&&a>=0){var o=i.getLayout(`points`),s=i.getItemGraphicEl(a);if(!s){var c=o[a*2],l=o[a*2+1];if(eO(c,l)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(c,l))return;var u=e.get(`zlevel`)||0,d=e.get(`z`)||0;s=new WD(i,a),s.x=c,s.y=l,s.setZ(u,d);var f=s.getSymbolPath().getTextContent();f&&(f.zlevel=u,f.z=d,f.z2=this._polyline.z2+1),s.__temp=!0,i.setItemGraphicEl(a,s),s.stopSymbolAnimation(!0),this.group.add(s)}s.highlight()}else zy.prototype.highlight.call(this,e,t,n,r)},t.prototype.downplay=function(e,t,n,r){var i=e.getData(),a=_s(i,r);if(this._changePolyState(`normal`),a!=null&&a>=0){var o=i.getItemGraphicEl(a);o&&(o.__temp?(i.setItemGraphicEl(a,null),this.group.remove(o)):o.downplay())}else zy.prototype.downplay.call(this,e,t,n,r)},t.prototype._changePolyState=function(e){var t=this._polygon;cd(this._polyline,e),t&&cd(t,e)},t.prototype._newPolyline=function(e){var t=this._polyline;return t&&this._lineGroup.remove(t),t=new uO({shape:{points:e},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(t),this._polyline=t,t},t.prototype._newPolygon=function(e,t){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new fO({shape:{points:e,stackedOnPoints:t},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},t.prototype._initSymbolLabelAnimation=function(e,t,n){var r,i,a=t.getBaseAxis(),o=a.inverse;t.type===`cartesian2d`?(r=a.isHorizontal(),i=!1):t.type===`polar`&&(r=a.dim===`angle`,i=!0);var s=e.hostModel,c=s.get(`animationDuration`);W(c)&&(c=c(null));var l=s.get(`animationDelay`)||0,u=W(l)?l(null):l;e.eachItemGraphicEl(function(e,a){var s=e;if(s){var d=[e.x,e.y],f=void 0,p=void 0,m=void 0;if(n)if(i){var h=n,g=t.pointToCoord(d);r?(f=h.startAngle,p=h.endAngle,m=-g[1]/180*Math.PI):(f=h.r0,p=h.r,m=g[0])}else{var _=n;r?(f=_.x,p=_.x+_.width,m=e.x):(f=_.y+_.height,p=_.y,m=e.y)}var v=p===f?0:(m-f)/(p-f);o&&(v=1-v);var y=W(l)?l(a):c*v+u,b=s.getSymbolPath(),x=b.getTextContent();s.attr({scaleX:0,scaleY:0}),s.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:y}),x&&x.animateFrom({style:{opacity:0}},{duration:300,delay:y}),b.disableLabelAnimation=!0}})},t.prototype._initOrUpdateEndLabel=function(e,t,n){var r=e.getModel(`endLabel`);if(AO(e)){var i=e.getData(),a=this._polyline,o=i.getLayout(`points`);if(!o){a.removeTextContent(),this._endLabel=null;return}var s=this._endLabel;s||(s=this._endLabel=new pu({z2:200}),s.ignoreClip=!0,a.setTextContent(this._endLabel),a.disableLabelAnimation=!0);var c=DO(o);c>=0&&(Sm(a,Cm(e,`endLabel`),{inheritColor:n,labelFetcher:e,labelDataIndex:c,defaultText:function(e,t,n){return n==null?HD(i,e):UD(i,n)},enableTextSetter:!0},MO(r,t)),a.textConfig.position=null)}else this._endLabel&&=(this._polyline.removeTextContent(),null)},t.prototype._endLabelOnDuring=function(e,t,n,r,i,a,o){var s=this._endLabel,c=this._polyline;if(s){e<1&&r.originalX==null&&(r.originalX=s.x,r.originalY=s.y);var l=n.getLayout(`points`),u=n.hostModel,d=u.get(`connectNulls`),f=a.get(`precision`),p=a.get(`distance`)||0,m=o.getBaseAxis(),h=m.isHorizontal(),g=m.inverse,_=t.shape,v=g?h?_.x:_.y+_.height:h?_.x+_.width:_.y,y=(h?p:0)*(g?-1:1),b=(h?0:-p)*(g?-1:1),x=h?`x`:`y`,S=kO(l,v,x),C=S.range,w=C[1]-C[0],T=void 0;if(w>=1){if(w>1&&!d){var E=OO(l,C[0]);s.attr({x:E[0]+y,y:E[1]+b}),i&&(T=u.getRawValue(C[0]))}else{var E=c.getPointOn(v,x);E&&s.attr({x:E[0]+y,y:E[1]+b});var D=u.getRawValue(C[0]),O=u.getRawValue(C[1]);i&&(T=Os(n,f,D,O,S.t))}r.lastFrameIndex=C[0]}else{var k=e===1||r.lastFrameIndex>0?C[0]:0,E=OO(l,k);i&&(T=u.getRawValue(k)),s.attr({x:E[0]+y,y:E[1]+b})}if(i){var A=Nm(s);typeof A.setLabelText==`function`&&A.setLabelText(T)}}},t.prototype._doUpdateAnimation=function(e,t,n,r,i,a,o){var s=this._polyline,c=this._polygon,l=e.hostModel,u=aO(this._data,e,this._stackedOnPoints,t,this._coordSys,n,this._valueOrigin,a),d=u.current,f=u.stackedOnCurrent,p=u.next,m=u.stackedOnNext;if(i&&(f=SO(u.stackedOnCurrent,u.current,n,i,o),d=SO(u.current,null,n,i,o),m=SO(u.stackedOnNext,u.next,n,i,o),p=SO(u.next,null,n,i,o)),yO(d,p)>3e3||c&&yO(f,m)>3e3){s.stopAnimation(),s.setShape({points:p}),c&&(c.stopAnimation(),c.setShape({points:p,stackedOnPoints:m}));return}s.shape.__points=u.current,s.shape.points=d;var h={shape:{points:p}};u.current!==d&&(h.shape.__points=u.next),s.stopAnimation(),vp(s,h,l),c&&(c.setShape({points:d,stackedOnPoints:f}),c.stopAnimation(),vp(c,{shape:{stackedOnPoints:m}},l),s.shape.points!==c.shape.points&&(c.shape.points=s.shape.points));for(var g=[],_=u.status,v=0;v<_.length;v++)if(_[v].cmd===`=`){var y=e.getItemGraphicEl(_[v].idx1);y&&g.push({el:y,ptIdx:v})}s.animators&&s.animators.length&&s.animators[0].during(function(){c&&c.dirtyShape();for(var e=s.shape.__points,t=0;t<g.length;t++){var n=g[t].el,r=g[t].ptIdx*2;n.x=e[r],n.y=e[r+1],n.markRedraw()}})},t.prototype.remove=function(e){var t=this.group,n=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),n&&n.eachItemGraphicEl(function(e,r){e.__temp&&(t.remove(e),n.setItemGraphicEl(r,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},t.type=`line`,t}(zy);function PO(e,t){return{seriesType:e,plan:Iy(),reset:function(e){var n=e.getData(),r=e.coordinateSystem,i=e.pipelineContext,a=t||i.large;if(r){var o=B(r.dimensions,function(e){return n.mapDimension(e)}).slice(0,2),s=o.length,c=n.getCalculationInfo(`stackResultDimension`);_w(n,o[0])&&(o[0]=c),_w(n,o[1])&&(o[1]=c);var l=n.getStore(),u=n.getDimensionIndex(o[0]),d=n.getDimensionIndex(o[1]);return s&&{progress:function(e,t){for(var n=e.end-e.start,i=a&&nO(n*s),o=[],c=[],f=e.start,p=0;f<e.end;f++){var m=void 0;if(s===1){var h=l.get(u,f);m=r.dataToPoint(h,null,c)}else o[0]=l.get(u,f),o[1]=l.get(d,f),m=r.dataToPoint(o,null,c);a?(i[p++]=m[0],i[p++]=m[1]):t.setItemLayout(f,m.slice())}a&&(t.setLayout(`points`,i),t.setLayout(`pointsRange`,{start:e.start,end:e.end}))}}}}}}var FO={average:function(e){for(var t=0,n=0,r=0;r<e.length;r++)isNaN(e[r])||(t+=e[r],n++);return n===0?NaN:t/n},sum:function(e){for(var t=0,n=0;n<e.length;n++)t+=e[n]||0;return t},max:function(e){for(var t=-1/0,n=0;n<e.length;n++)e[n]>t&&(t=e[n]);return isFinite(t)?t:NaN},min:function(e){for(var t=1/0,n=0;n<e.length;n++)e[n]<t&&(t=e[n]);return isFinite(t)?t:NaN},nearest:function(e){return e[0]}},IO=function(e){return Math.round(e.length/2)};function LO(e){return{seriesType:e,reset:function(e,t,n){var r=e.getData(),i=e.get(`sampling`),a=e.coordinateSystem,o=r.count();if(o>10&&a.type===`cartesian2d`&&i){var s=a.getBaseAxis(),c=a.getOtherAxis(s),l=s.getExtent(),u=n.getDevicePixelRatio(),d=Math.abs(l[1]-l[0])*(u||1),f=Math.round(o/d);if(isFinite(f)&&f>1){i===`lttb`?e.setData(r.lttbDownSample(r.mapDimension(c.dim),1/f)):i===`minmax`&&e.setData(r.minmaxDownSample(r.mapDimension(c.dim),1/f));var p=void 0;G(i)?p=FO[i]:W(i)&&(p=i),p&&e.setData(r.downSample(r.mapDimension(c.dim),1/f,p,IO))}}}}}function RO(e){e.registerChartView(NO),e.registerSeriesModel(VD),e.registerLayout(PO(`line`,!0)),e.registerVisual({seriesType:`line`,reset:function(e){var t=e.getData(),n=e.getModel(`lineStyle`).getLineStyle();n&&!n.stroke&&(n.stroke=t.getVisual(`style`).fill),t.setVisual(`legendLineStyle`,n)}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,LO(`line`))}var zO=function(e){k(t,e);function t(t,n,r,i,a){var o=e.call(this,t,n,r)||this;return o.index=0,o.type=i||`value`,o.position=a||`bottom`,o}return t.prototype.isHorizontal=function(){var e=this.position;return e===`top`||e===`bottom`},t.prototype.getGlobalExtent=function(e){var t=this.getExtent();return t[0]=this.toGlobalCoord(t[0]),t[1]=this.toGlobalCoord(t[1]),e&&t[0]>t[1]&&t.reverse(),t},t.prototype.pointToData=function(e,t){return this.coordToData(this.toLocalCoord(e[this.dim===`x`?0:1]),t)},t.prototype.setCategorySortInfo=function(e){if(this.type!==`category`)return!1;this.model.option.categorySortInfo=e,this.scale.setSortInfo(e)},t}($E),BO=null;function VO(){return BO}var HO=`expandAxisBreak`,UO=Math.PI,WO=[[1,2,1,2],[5,3,5,3],[8,3,8,3]],GO=[[0,1,0,1],[0,3,0,3],[0,3,0,3]],KO=Z(),qO=Z(),JO=function(){function e(e){this.recordMap={},this.resolveAxisNameOverlap=e}return e.prototype.ensureRecord=function(e){var t=e.axis.dim,n=e.componentIndex,r=this.recordMap,i=r[t]||(r[t]=[]);return i[n]||(i[n]={ready:{}})},e}();function YO(e,t,n,r){var i=n.axis,a=t.ensureRecord(n),o=[],s,c=yk(e.axisName)&&NT(e.nameLocation);z(r,function(e){var t=cD(e);if(!(!t||t.label.ignore)){o.push(t);var n=a.transGroup;c&&(n.transform?ln(XO,n.transform):nn(XO),t.transform&&an(XO,XO,t.transform),Y.copy(ZO,t.localRect),ZO.applyTransform(XO),s?s.union(ZO):Y.copy(s=new Y(0,0,0,0),ZO))}});var l=Math.abs(a.dirVec.x)>.1?`x`:`y`,u=a.transGroup[l];if(o.sort(function(e,t){return Math.abs(e.label[l]-u)-Math.abs(t.label[l]-u)}),c&&s){var d=i.getExtent(),f=Math.min(d[0],d[1]),p=Math.max(d[0],d[1])-f;s.union(new Y(f,0,p,1))}a.stOccupiedRect=s,a.labelInfoList=o}var XO=tn(),ZO=new Y(0,0,0,0),QO=function(e,t,n,r,i,a){if(NT(e.nameLocation)){var o=a.stOccupiedRect;o&&$O(dD({},o,a.transGroup.transform),r,i)}else ek(a.labelInfoList,a.dirVec,r,i)};function $O(e,t,n){var r=new un;gD(e,t,r,{direction:Math.atan2(n.y,n.x),bidirectional:!1,touchThreshold:.05})&&fD(t,r)}function ek(e,t,n,r){for(var i=un.dot(r,t)>=0,a=0,o=e.length;a<o;a++){var s=e[i?a:o-1-a];s.label.ignore||$O(s,n,r)}}var tk=function(){function e(e,t,n,r){this.group=new Ya,this._axisModel=e,this._api=t,this._local={},this._shared=r||new JO(QO),this._resetCfgDetermined(n)}return e.prototype.updateCfg=function(e){var t=this._cfg.raw;t.position=e.position,t.labelOffset=e.labelOffset,this._resetCfgDetermined(t)},e.prototype.__getRawCfg=function(){return this._cfg.raw},e.prototype._resetCfgDetermined=function(e){var t=this._axisModel,n=t.getDefaultOption?t.getDefaultOption():{},r=q(e.axisName,t.get(`name`)),i=t.get(`nameMoveOverlap`);(i==null||i===`auto`)&&(i=q(e.defaultNameMoveOverlap,!0));var a={raw:e,position:e.position,rotation:e.rotation,nameDirection:q(e.nameDirection,1),tickDirection:q(e.tickDirection,1),labelDirection:q(e.labelDirection,1),labelOffset:q(e.labelOffset,0),silent:q(e.silent,!0),axisName:r,nameLocation:ze(t.get(`nameLocation`),n.nameLocation,`end`),shouldNameMoveOverlap:yk(r)&&i,optionHideOverlap:t.get([`axisLabel`,`hideOverlap`]),showMinorTicks:t.get([`minorTick`,`show`])};this._cfg=a;var o=new Ya({x:a.position[0],y:a.position[1],rotation:a.rotation});o.updateTransform(),this._transformGroup=o;var s=this._shared.ensureRecord(t);s.transGroup=this._transformGroup,s.dirVec=new un(Math.cos(-a.rotation),Math.sin(-a.rotation))},e.prototype.build=function(e,t){var n=this;return e||={axisLine:!0,axisTickLabelEstimate:!1,axisTickLabelDetermine:!0,axisName:!0},z(nk,function(r){e[r]&&rk[r](n._cfg,n._local,n._shared,n._axisModel,n.group,n._transformGroup,n._api,t||{})}),this},e.innerTextLayout=function(e,t,n){var r=ko(t-e),i,a;return Ao(r)?(a=n>0?`top`:`bottom`,i=`center`):Ao(r-UO)?(a=n>0?`bottom`:`top`,i=`center`):(a=`middle`,i=r>0&&r<UO?n>0?`right`:`left`:n>0?`left`:`right`),{rotation:r,textAlign:i,textVerticalAlign:a}},e.makeAxisEventDataBase=function(e){var t={componentType:e.mainType,componentIndex:e.componentIndex};return t[e.mainType+`Index`]=e.componentIndex,t},e.isLabelSilent=function(e){var t=e.get(`tooltip`);return e.get(`silent`)||!(e.get(`triggerEvent`)||t&&t.show)},e}(),nk=[`axisLine`,`axisTickLabelEstimate`,`axisTickLabelDetermine`,`axisName`],rk={axisLine:function(e,t,n,r,i,a,o){var s=r.get([`axisLine`,`show`]);if(s===`auto`&&(s=!0,e.raw.axisLineAutoShow!=null&&(s=!!e.raw.axisLineAutoShow)),s){var c=r.axis.getExtent(),l=a.transform,u=[c[0],0],d=[c[1],0],f=u[0]>d[0];l&&(yt(u,u,l),yt(d,d,l));var p=I({lineCap:`round`},r.getModel([`axisLine`,`lineStyle`]).getLineStyle()),m={strokeContainThreshold:e.raw.strokeContainThreshold||5,silent:!0,z2:1,style:p};if(r.get([`axisLine`,`breakLine`])&&ph(r.axis.scale))VO().buildAxisBreakLine(r,i,a,m);else{var h=new qf(I({shape:{x1:u[0],y1:u[1],x2:d[0],y2:d[1]}},m));zp(h.shape,h.style.lineWidth),h.anid=`line`,i.add(h)}var g=r.get([`axisLine`,`symbol`]);if(g!=null){var _=r.get([`axisLine`,`symbolSize`]);G(g)&&(g=[g,g]),(G(_)||je(_))&&(_=[_,_]);var v=ax(r.get([`axisLine`,`symbolOffset`])||0,_),y=_[0],b=_[1];z([{rotate:e.rotation+Math.PI/2,offset:v[0],r:0},{rotate:e.rotation-Math.PI/2,offset:v[1],r:Math.sqrt((u[0]-d[0])*(u[0]-d[0])+(u[1]-d[1])*(u[1]-d[1]))}],function(t,n){if(g[n]!==`none`&&g[n]!=null){var r=rx(g[n],-y/2,-b/2,y,b,p.stroke,!0),a=t.r+t.offset,o=f?d:u;r.attr({rotation:t.rotate,x:o[0]+a*Math.cos(e.rotation),y:o[1]-a*Math.sin(e.rotation),silent:!0,z2:11}),i.add(r)}})}}},axisTickLabelEstimate:function(e,t,n,r,i,a,o,s){fk(t,i,s)&&ik(e,t,n,r,i,a,o,OE.estimate)},axisTickLabelDetermine:function(e,t,n,r,i,a,o,s){fk(t,i,s)&&ik(e,t,n,r,i,a,o,OE.determine);var c=uk(e,i,a,r);sk(e,t.labelLayoutList,c),dk(e,i,a,r,e.tickDirection)},axisName:function(e,t,n,r,i,a,o,s){var c=n.ensureRecord(r);t.nameEl&&=(i.remove(t.nameEl),c.nameLayout=c.nameLocation=null);var l=e.axisName;if(yk(l)){var u=e.nameLocation,d=e.nameDirection,f=r.getModel(`nameTextStyle`),p=r.get(`nameGap`)||0,m=r.axis.getExtent(),h=r.axis.inverse?-1:1,g=new un(0,0),_=new un(0,0);u===`start`?(g.x=m[0]-h*p,_.x=-h):u===`end`?(g.x=m[1]+h*p,_.x=h):(g.x=(m[0]+m[1])/2,g.y=e.labelOffset+d*p,_.y=d);var v=tn();_.transform(sn(v,v,e.rotation));var y=r.get(`nameRotate`);y!=null&&(y=y*UO/180);var b,x;NT(u)?b=tk.innerTextLayout(e.rotation,y??e.rotation,d):(b=ak(e.rotation,u,y||0,m),x=e.raw.axisNameAvailableWidth,x!=null&&(x=Math.abs(x/Math.sin(b.rotation)),!isFinite(x)&&(x=null)));var S=f.getFont(),C=r.get(`nameTruncate`,!0)||{},w=C.ellipsis,T=Re(e.raw.nameTruncateMaxWidth,C.maxWidth,x),E=s.nameMarginLevel||0,D=new pu({x:g.x,y:g.y,rotation:b.rotation,silent:tk.isLabelSilent(r),style:wm(f,{text:l,font:S,overflow:`truncate`,width:T,ellipsis:w,fill:f.getTextColor()||r.get([`axisLine`,`lineStyle`,`color`]),align:f.get(`align`)||b.textAlign,verticalAlign:f.get(`verticalAlign`)||b.textVerticalAlign}),z2:1});if(im({el:D,componentModel:r,itemName:l}),D.__fullText=l,D.anid=`name`,r.get(`triggerEvent`)){var O=tk.makeAxisEventDataBase(r);O.targetType=`axisName`,O.name=l,Du(D).eventData=O}a.add(D),D.updateTransform(),t.nameEl=D;var k=c.nameLayout=cD({label:D,priority:D.z2,defaultAttr:{ignore:D.ignore},marginDefault:NT(u)?WO[E]:GO[E]});if(c.nameLocation=u,i.add(D),D.decomposeTransform(),e.shouldNameMoveOverlap&&k){var A=n.ensureRecord(r);n.resolveAxisNameOverlap(e,n,r,k,_,A)}}}};function ik(e,t,n,r,i,a,o,s){mk(t)||pk(e,t,i,s,r,o);var c=t.labelLayoutList;gk(e,r,c,a),xk(r,e.rotation,c);var l=e.optionHideOverlap;ok(r,c,l),l&&hD(Ee(c,function(e){return e&&!e.label.ignore})),YO(e,n,r,c)}function ak(e,t,n,r){var i=ko(n-e),a,o,s=r[0]>r[1],c=t===`start`&&!s||t!==`start`&&s;return Ao(i-UO/2)?(o=c?`bottom`:`top`,a=`center`):Ao(i-UO*1.5)?(o=c?`top`:`bottom`,a=`center`):(o=`middle`,a=i<UO*1.5&&i>UO/2?c?`left`:`right`:c?`right`:`left`),{rotation:i,textAlign:a,textVerticalAlign:o}}function ok(e,t,n){var r=e.axis,i=e.get([`axisLabel`,`customValues`]);if(jT(r))return;function a(e,a,o){var s=cD(t[a]),c=cD(t[o]),l=r.scale;if(!(!s||!c)){if(e==null){if(!n&&i)return;var u=KO(s.label).labelInfo.tick;if(Vw(l)&&u.notNice||Uw(l)&&u.offInterval){ck(s.label);return}}if(e===!1||s.suggestIgnore){ck(s.label);return}if(c.suggestIgnore){ck(c.label);return}var d=.1;if(!n){var f=[0,0,0,0];s=pD({marginForce:f},s),c=pD({marginForce:f},c)}gD(s,c,null,{touchThreshold:d})&&ck(e?c.label:s.label)}}var o=e.get([`axisLabel`,`showMinLabel`]),s=e.get([`axisLabel`,`showMaxLabel`]),c=t.length;a(o,0,1),a(s,c-1,c-2)}function sk(e,t,n){e.showMinorTicks||z(t,function(e){if(e&&e.label.ignore)for(var t=0;t<n.length;t++){var r=n[t],i=qO(r),a=KO(e.label);if(i.tickValue!=null&&!i.onBand&&i.tickValue===a.labelInfo.tick.value){ck(r);return}}})}function ck(e){e&&(e.ignore=!0)}function lk(e,t,n,r,i){for(var a=[],o=[],s=[],c=0;c<e.length;c++){var l=e[c].coord;o[0]=l,o[1]=0,s[0]=l,s[1]=n,t&&(yt(o,o,t),yt(s,s,t));var u=new qf({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:r,z2:2,autoBatch:!0,silent:!0});zp(u.shape,u.style.lineWidth),u.anid=i+`_`+e[c].tickValue,a.push(u);var d=qO(u);d.onBand=!!e[c].onBand,d.tickValue=e[c].tickValue}return a}function uk(e,t,n,r){var i=r.axis,a=r.getModel(`axisTick`),o=a.get(`show`);if(o===`auto`&&(o=!0,e.raw.axisTickAutoShow!=null&&(o=!!e.raw.axisTickAutoShow)),!o||i.scale.isBlank())return[];for(var s=a.getModel(`lineStyle`),c=e.tickDirection*a.get(`length`),l=lk(i.getTicksCoords(),n.transform,c,L(s.getLineStyle(),{stroke:r.get([`axisLine`,`lineStyle`,`color`])}),`ticks`),u=0;u<l.length;u++)t.add(l[u]);return l}function dk(e,t,n,r,i){var a=r.axis,o=r.getModel(`minorTick`);if(!(!e.showMinorTicks||a.scale.isBlank())){var s=a.getMinorTicksCoords();if(s.length)for(var c=o.getModel(`lineStyle`),l=i*o.get(`length`),u=L(c.getLineStyle(),L(r.getModel(`axisTick`).getLineStyle(),{stroke:r.get([`axisLine`,`lineStyle`,`color`])})),d=0;d<s.length;d++)for(var f=lk(s[d],n.transform,l,u,`minorticks_`+d),p=0;p<f.length;p++)t.add(f[p])}}function fk(e,t,n){if(mk(e)){var r=e.axisLabelsCreationContext.out.noPxChangeTryDetermine;if(n.noPxChange){for(var i=!0,a=0;a<r.length;a++)i&&=r[a]();if(i)return!1}r.length&&(t.remove(e.labelGroup),hk(e,null,null,null))}return!0}function pk(e,t,n,r,i,a){var o=i.axis,s=Re(e.raw.axisLabelShow,i.get([`axisLabel`,`show`])),c=new Ya;n.add(c);var l=kE(r);if(!s||o.scale.isBlank()){hk(t,[],c,l);return}var u=i.getModel(`axisLabel`),d=o.getViewLabels(l),f=(Re(e.raw.labelRotate,u.get(`rotate`))||0)*UO/180,p=tk.innerTextLayout(e.rotation,f,e.labelDirection),m=i.getCategories&&i.getCategories(!0),h=[],g=i.get(`triggerEvent`),_=1/0,v=-1/0;z(d,function(e,t){var n=e.tick,r=e.formattedLabel,s=e.rawLabel,l=u,f=RT(o.scale,n);if(m&&m[f]){var y=m[f];K(y)&&y.textStyle&&(l=new Gm(y.textStyle,u,i.ecModel))}var b=l.getTextColor()||i.get([`axisLine`,`lineStyle`,`color`]),x=l.getShallow(`align`,!0)||p.textAlign,S=q(l.getShallow(`alignMinLabel`,!0),x),C=q(l.getShallow(`alignMaxLabel`,!0),x),w=l.getShallow(`verticalAlign`,!0)||l.getShallow(`baseline`,!0)||p.textVerticalAlign,T=q(l.getShallow(`verticalAlignMinLabel`,!0),w),E=q(l.getShallow(`verticalAlignMaxLabel`,!0),w),D=10+(n.time?.level||0);_=Math.min(_,D),v=Math.max(v,D);var O=new pu({x:0,y:0,rotation:0,silent:tk.isLabelSilent(i),z2:D,style:wm(l,{text:r,align:t===0?S:t===d.length-1?C:x,verticalAlign:t===0?T:t===d.length-1?E:w,fill:W(b)?b(o.type===`category`?s:o.type===`value`?f+``:f,t):b})});O.anid=`label_`+f;var k=KO(O);if(k.labelInfo=e,k.layoutRotation=p.rotation,im({el:O,componentModel:i,itemName:r,formatterParamsExtra:{isTruncated:function(){return O.isTruncated},value:s,tickIndex:t}}),g){var A=tk.makeAxisEventDataBase(i);A.targetType=`axisLabel`,A.value=s,A.tickIndex=t;var j=e.tick.break;if(j){var ee=j.parsedBreak;A.break={start:ee.vmin,end:ee.vmax}}o.type===`category`&&(A.dataIndex=f),Du(O).eventData=A,j&&bk(i,a,O,j)}h.push(O),c.add(O)}),hk(t,B(h,function(e){return{label:e,priority:KO(e).labelInfo.tick.break?e.z2+(v-_+1):e.z2,defaultAttr:{ignore:e.ignore}}}),c,l)}function mk(e){return!!e.labelLayoutList}function hk(e,t,n,r){e.labelLayoutList=t,e.labelGroup=n,e.axisLabelsCreationContext=r}function gk(e,t,n,r){var i=t.get([`axisLabel`,`margin`]);z(n,function(n,a){var o=cD(n);if(o){var s=o.label,c=KO(s);o.suggestIgnore=s.ignore,s.ignore=!1,_a(_k,vk);var l=t.axis;_k.x=l.dataToCoord(RT(l.scale,c.labelInfo.tick)),_k.y=e.labelOffset+e.labelDirection*i,_k.rotation=c.layoutRotation,r.add(_k),_k.updateTransform(),r.remove(_k),_k.decomposeTransform(),_a(s,_k),s.markRedraw(),oD(o,!0),cD(o)}})}var _k=new cu,vk=new cu;function yk(e){return!!e}function bk(e,t,n,r){n.on(`click`,function(n){var i={type:HO,breaks:[{start:r.parsedBreak.breakOption.start,end:r.parsedBreak.breakOption.end}]};i[e.axis.dim+`AxisIndex`]=e.componentIndex,t.dispatchAction(i)})}function xk(e,t,n){var r=uh();if(r){var i=r.retrieveAxisBreakPairs(n,function(e){return e&&KO(e.label).labelInfo.tick.break},!0),a=e.get([`breakLabelLayout`,`moveOverlap`],!0);(a===!0||a===`auto`)&&z(i,function(r){VO().adjustBreakLabelPair(e.axis.inverse,t,[cD(n[r[0]]),cD(n[r[1]])])})}}function Sk(e,t,n){n||={};var r=t.axis,i={},a=r.getAxesOnZeroOf()[0],o=r.position,s=a?`onZero`:o,c=r.dim,l=[e.x,e.x+e.width,e.y,e.y+e.height],u={left:0,right:1,top:0,bottom:1,onZero:2},d=t.get(`offset`)||0,f=c===`x`?[l[2]-d,l[3]+d]:[l[0]-d,l[1]+d];if(a){var p=a.toGlobalCoord(a.dataToCoord(0));f[u.onZero]=Math.max(Math.min(p,f[1]),f[0])}i.position=[c===`y`?f[u[s]]:l[0],c===`x`?f[u[s]]:l[3]],i.rotation=Math.PI/2*(c===`x`?0:1),i.labelDirection=i.tickDirection=i.nameDirection={top:-1,bottom:1,left:-1,right:1}[o],i.labelOffset=a?f[u[o]]-f[u.onZero]:0,t.get([`axisTick`,`inside`])&&(i.tickDirection=-i.tickDirection),Re(n.labelInside,t.get([`axisLabel`,`inside`]))&&(i.labelDirection=-i.labelDirection);var m=t.get([`axisLabel`,`rotate`]);return i.labelRotate=s===`top`?-m:m,i.z2=1,i}function Ck(e){var t={xAxisModel:null,yAxisModel:null};return z(t,function(n,r){var i=r.replace(/Model$/,``);t[r]=e.getReferringComponents(i,xs).models[0]}),t}function wk(e,t,n,r,i,a){for(var o=Sk(e,n),s=!1,c=!1,l=0;l<t.length;l++)zw(t[l].getOtherAxis(n.axis).scale)&&(s=c=!0,n.axis.type===`category`&&n.axis.onBand&&(c=!1));return o.axisLineAutoShow=s,o.axisTickAutoShow=c,o.defaultNameMoveOverlap=a,new tk(n,r,o,i)}function Tk(e,t,n){var r=Sk(t,n);e.updateCfg(r)}function Ek(e){return e.dim+`_`+e.index}var Dk={left:0,right:0,top:0,bottom:0},Ok=[`25%`,`25%`],kk=`cartesian2d`,Ak=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.mergeDefaultAndTheme=function(t,n){var r=Tg(t.outerBounds);e.prototype.mergeDefaultAndTheme.apply(this,arguments),r&&t.outerBounds&&wg(t.outerBounds,r)},t.prototype.mergeOption=function(t,n){e.prototype.mergeOption.apply(this,arguments),this.option.outerBounds&&t.outerBounds&&wg(this.option.outerBounds,t.outerBounds)},t.type=`grid`,t.dependencies=[`xAxis`,`yAxis`],t.layoutMode=`box`,t.defaultOption={show:!1,z:0,left:`15%`,top:65,right:`10%`,bottom:80,containLabel:!1,outerBoundsMode:`auto`,outerBounds:Dk,outerBoundsContain:`all`,outerBoundsClampWidth:Ok[0],outerBoundsClampHeight:Ok[1],backgroundColor:Q.color.transparent,borderWidth:1,borderColor:Q.color.neutral30},t}(Og),jk=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.hasSymbolVisual=!0,n}return t.prototype.getInitialData=function(e,t){return xw(null,this,{useEncodeDefaulter:!0})},t.prototype.getProgressive=function(){return this.option.progressive??(this.option.large?5e3:this.get(`progressive`))},t.prototype.getProgressiveThreshold=function(){return this.option.progressiveThreshold??(this.option.large?1e4:this.get(`progressiveThreshold`))},t.prototype.brushSelector=function(e,t,n){return n.point(t.getItemLayout(e))},t.prototype.getZLevelKey=function(){return this.getData().count()>this.getProgressiveThreshold()?this.id:``},t.type=`series.scatter`,t.dependencies=[`grid`,`polar`,`geo`,`singleAxis`,`calendar`,`matrix`],t.defaultOption={coordinateSystem:`cartesian2d`,z:2,legendHoverLink:!0,symbolSize:10,large:!1,largeThreshold:2e3,itemStyle:{opacity:.8},emphasis:{scale:!0},clip:!0,select:{itemStyle:{borderColor:Q.color.primary}},universalTransition:{divideShape:`clone`}},t}(Ey),Mk=4,Nk=function(){function e(){}return e}(),Pk=function(e){k(t,e);function t(t){var n=e.call(this,t)||this;return n._off=0,n.hoverDataIdx=-1,n}return t.prototype.getDefaultShape=function(){return new Nk},t.prototype.reset=function(){this.notClear=!1,this._off=0},t.prototype.beforeBrush=function(e){e&&!e.contentRetained&&this.reset()},t.prototype.buildPath=function(e,t){var n=t.points,r=t.size,i=this.symbolProxy,a=i.shape,o=e.getContext?e.getContext():e,s=o&&r[0]<Mk,c=this.softClipShape,l;if(s){this._ctx=o;return}for(this._ctx=null,l=this._off;l<n.length;){var u=n[l++],d=n[l++];isNaN(u)||isNaN(d)||c&&!c.contain(u,d)||(a.x=u-r[0]/2,a.y=d-r[1]/2,a.width=r[0],a.height=r[1],i.buildPath(e,a,!0))}this.incremental&&(this._off=l,this.notClear=!0)},t.prototype.afterBrush=function(){var e=this.shape,t=e.points,n=e.size,r=this._ctx,i=this.softClipShape,a;if(r){for(a=this._off;a<t.length;){var o=t[a++],s=t[a++];isNaN(o)||isNaN(s)||i&&!i.contain(o,s)||r.fillRect(o-n[0]/2,s-n[1]/2,n[0],n[1])}this.incremental&&(this._off=a,this.notClear=!0)}},t.prototype.findDataIndex=function(e,t){for(var n=this.shape,r=n.points,i=n.size,a=Math.max(i[0],4),o=Math.max(i[1],4),s=r.length/2-1;s>=0;s--){var c=s*2,l=r[c]-a/2,u=r[c+1]-o/2;if(e>=l&&t>=u&&e<=l+a&&t<=u+o)return s}return-1},t.prototype.contain=function(e,t){var n=this.transformCoordToLocal(e,t),r=this.getBoundingRect();return e=n[0],t=n[1],r.contain(e,t)?(this.hoverDataIdx=this.findDataIndex(e,t))>=0:(this.hoverDataIdx=-1,!1)},t.prototype.getBoundingRect=function(){var e=this._rect;if(!e){for(var t=this.shape,n=t.points,r=t.size,i=r[0],a=r[1],o=1/0,s=1/0,c=-1/0,l=-1/0,u=0;u<n.length;){var d=n[u++],f=n[u++];o=Math.min(d,o),c=Math.max(d,c),s=Math.min(f,s),l=Math.max(f,l)}e=this._rect=new Y(o-i/2,s-a/2,c-o+i,l-s+a)}return e},t}(Jl),Fk=function(){function e(){this.group=new Ya}return e.prototype.updateData=function(e,t){this._clear(),this._data=e;var n=this._create();n.setShape({points:e.getLayout(`points`)}),this._setCommon(n,e,t)},e.prototype.updateLayout=function(e){var t=this._data;if(t){var n=t.getLayout(`points`);this.group.eachChild(function(e){if(e.startIndex!=null){var t=(e.endIndex-e.startIndex)*2,r=e.startIndex*4*2;n=new Float32Array(n.buffer,r,t)}e.setShape(`points`,n),e.reset(),e.stopAnimation()})}},e.prototype.incrementalPrepareUpdate=function(e){this._clear()},e.prototype.incrementalUpdate=function(e,t,n,r){var i=this._newAdded[0],a=t.getLayout(`points`),o=i&&i.shape.points;if(o&&o.length<2e4){var s=o.length,c=new Float32Array(s+a.length);c.set(o),c.set(a,s),i.endIndex=e.end,i.setShape({points:c})}else{this._newAdded=[];var l=this._create();l.startIndex=e.start,l.endIndex=e.end,l.incremental=n,l.setShape({points:a}),this._setCommon(l,t,r)}},e.prototype.eachRendered=function(e){this._newAdded[0]&&e(this._newAdded[0])},e.prototype._create=function(){var e=new Pk({cursor:`default`});return e.ignoreCoarsePointer=!0,this.group.add(e),this._newAdded.push(e),e},e.prototype._setCommon=function(e,t,n){var r=t.hostModel;n||={};var i=t.getVisual(`symbolSize`);e.setShape(`size`,i instanceof Array?i:[i,i]),e.softClipShape=n.clipShape||null,e.symbolProxy=rx(t.getVisual(`symbol`),0,0,0,0),e.setColor=e.symbolProxy.setColor;var a=e.shape.size[0]<Mk;e.useStyle(r.getModel(`itemStyle`).getItemStyle(a?[`color`,`shadowBlur`,`shadowColor`]:[`color`]));var o=t.getVisual(`style`),s=o&&o.fill;s&&e.setColor(s);var c=Du(e);c.seriesIndex=r.seriesIndex,e.on(`mousemove`,function(t){c.dataIndex=null;var n=e.hoverDataIdx;n>=0&&(c.dataIndex=n+(e.startIndex||0))})},e.prototype.remove=function(){this._clear()},e.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},e}(),Ik=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.render=function(e,t,n){var r=e.getData();this._updateSymbolDraw(r,e).updateData(r,Lk(e)),this._finished=!0},t.prototype.incrementalPrepareRender=function(e,t,n){var r=e.getData();this._updateSymbolDraw(r,e).incrementalPrepareUpdate(r),this._finished=!1},t.prototype.incrementalRender=function(e,t,n){this._symbolDraw.incrementalUpdate(e,t.getData(),Us(t),Lk(t)),this._finished=e.end===t.getData().count()},t.prototype.updateTransform=function(e,t,n){var r=e.getData();if(this.group.dirty(),this._finished){var i=PO(``).reset(e,t,n);i.progress&&i.progress({start:0,end:r.count(),count:r.count()},r),this._symbolDraw.updateLayout(Lk(e))}else return{update:!0}},t.prototype.eachRendered=function(e){this._symbolDraw&&this._symbolDraw.eachRendered(e)},t.prototype._updateSymbolDraw=function(e,t){var n=this._symbolDraw,r=t.pipelineContext.large;return(!n||r!==this._isLargeDraw)&&(n&&n.remove(),n=this._symbolDraw=r?new Fk:new XD,this._isLargeDraw=r,this.group.removeAll()),this.group.add(n.group),n},t.prototype.remove=function(e,t){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},t.prototype.dispose=function(){},t.type=`scatter`,t}(zy);function Lk(e){return{clipShape:hO(e)}}var Rk=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.getCoordSysModel=function(){return this.getReferringComponents(`grid`,xs).models[0]},t.type=`cartesian2dAxis`,t}(Og);Ce(Rk,BT);var zk={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:`auto`,onZeroAxisIndex:null,lineStyle:{color:Q.color.axisLine,width:1,type:`solid`},symbol:[`none`,`none`],symbolSize:[10,15],breakLine:!0},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,color:Q.color.axisLabel,textMargin:[0,3]},splitLine:{show:!0,showMinLine:!0,showMaxLine:!0,lineStyle:{color:Q.color.axisSplitLine,width:1,type:`solid`}},splitArea:{show:!1,areaStyle:{color:[Q.color.backgroundTint,Q.color.backgroundTransparent]}},breakArea:{show:!0,itemStyle:{color:Q.color.neutral00,borderColor:Q.color.border,borderWidth:1,borderType:[3,3],opacity:.6},zigzagAmplitude:4,zigzagMinSpan:4,zigzagMaxSpan:20,zigzagZ:100,expandOnClick:!0},breakLabelLayout:{moveOverlap:`auto`}},Bk=F({boundaryGap:!0,deduplication:null,jitter:0,jitterOverlap:!0,jitterMargin:2,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:`auto`,show:`auto`},axisLabel:{interval:`auto`}},zk),Vk=F({boundaryGap:[0,0],axisLine:{show:`auto`},axisTick:{show:`auto`},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:Q.color.axisMinorSplitLine,width:1}}},zk),Hk={category:Bk,value:Vk,time:F({splitNumber:6,axisLabel:{rich:{primary:{fontWeight:`bold`}}},splitLine:{show:!1}},Vk),log:L({logBase:10},Vk)};function Uk(e,t,n,r){z(xT,function(i,a){var o=F(F({},Hk[a],!0),r,!0),s=function(e){k(n,e);function n(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t+`Axis.`+a,n}return n.prototype.mergeDefaultAndTheme=function(e,t){var n=Cg(this),r=n?Tg(e):{};F(e,t.getTheme().get(a+`Axis`)),F(e,this.getDefaultOption()),e.type=Wk(e),n&&wg(e,r,n)},n.prototype.optionUpdated=function(){this.option.type===`category`&&(this.__ordinalMeta=Ew.createByAxisModel(this))},n.prototype.getCategories=function(e){var t=this.option;if(t.type===`category`)return e?t.data:this.__ordinalMeta.categories},n.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},n.prototype.updateAxisBreaks=function(e){var t=VO();return t?t.updateModelAxisBreak(this,e):{breaks:[]}},n.type=t+`Axis.`+a,n.defaultOption=o,n}(n);e.registerComponentModel(s)}),e.registerSubTypeDefaulter(t+`Axis`,Wk)}function Wk(e){return e.type||(e.data?`category`:`value`)}var Gk=function(){function e(e){this.type=`cartesian`,this._dimList=[],this._axes={},this.name=e||``}return e.prototype.getAxis=function(e){return this._axes[e]},e.prototype.getAxes=function(){return B(this._dimList,function(e){return this._axes[e]},this)},e.prototype.getAxesByScale=function(e){return e=e.toLowerCase(),Ee(this.getAxes(),function(t){return t.scale.type===e})},e.prototype.addAxis=function(e){var t=e.dim;this._axes[t]=e,this._dimList.push(t)},e}(),Kk=[`x`,`y`];function qk(e){return(e.type===`interval`||e.type===`time`)&&!ph(e)}var Jk=function(e){k(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.type=kk,t.dimensions=Kk,t}return t.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var e=this.getAxis(`x`).scale,t=this.getAxis(`y`).scale;if(!(!qk(e)||!qk(t))){var n=Nw(e,null),r=Nw(t,null),i=this.dataToPoint([n[0],r[0]]),a=this.dataToPoint([n[1],r[1]]),o=n[1]-n[0],s=r[1]-r[0];if(!(!o||!s)){var c=(a[0]-i[0])/o,l=(a[1]-i[1])/s,u=i[0]-n[0]*c,d=i[1]-r[0]*l,f=this._transform=[c,0,0,l,u,d];this._invTransform=ln([],f)}}},t.prototype.getBaseAxis=function(){return this.getAxesByScale(`ordinal`)[0]||this.getAxesByScale(`time`)[0]||this.getAxis(`x`)},t.prototype.containPoint=function(e){var t=this.getAxis(`x`),n=this.getAxis(`y`);return t.contain(t.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,t){var n=this.dataToPoint(e),r=this.dataToPoint(t),i=this.getArea(),a=new Y(n[0],n[1],r[0]-n[0],r[1]-n[1]);return i.intersect(a)},t.prototype.dataToPoint=function(e,t,n){n||=[];var r=e[0],i=e[1];if(this._transform&&r!=null&&isFinite(r)&&i!=null&&isFinite(i))return yt(n,e,this._transform);var a=this.getAxis(`x`),o=this.getAxis(`y`);return n[0]=a.toGlobalCoord(a.dataToCoord(r,t)),n[1]=o.toGlobalCoord(o.dataToCoord(i,t)),n},t.prototype.clampData=function(e,t){var n=this.getAxis(`x`).scale,r=this.getAxis(`y`).scale,i=n.getExtent(),a=r.getExtent(),o=n.parse(e[0]),s=r.parse(e[1]);return t||=[],t[0]=Math.min(Math.max(Math.min(i[0],i[1]),o),Math.max(i[0],i[1])),t[1]=Math.min(Math.max(Math.min(a[0],a[1]),s),Math.max(a[0],a[1])),t},t.prototype.pointToData=function(e,t,n){if(n||=[],this._invTransform)return yt(n,e,this._invTransform);var r=this.getAxis(`x`),i=this.getAxis(`y`);return n[0]=r.coordToData(r.toLocalCoord(e[0]),t),n[1]=i.coordToData(i.toLocalCoord(e[1]),t),n},t.prototype.getOtherAxis=function(e){return this.getAxis(e.dim===`x`?`y`:`x`)},t.prototype.getArea=function(e){e||=0;var t=this.getAxis(`x`).getGlobalExtent(),n=this.getAxis(`y`).getGlobalExtent(),r=Math.min(t[0],t[1])-e,i=Math.min(n[0],n[1])-e;return new Y(r,i,Math.max(t[0],t[1])-r+e,Math.max(n[0],n[1])-i+e)},t}(Gk);function Yk(e,t){var n=e.scale,r=e.model,i=pE(n,r,r.ecModel,e,null),a=Hw(n),o=Hw(t)?t.intervalStub:t,s=a?n.intervalStub:n,c=n.base,l=o.getTicks(),u=o.getTicks({expandToNicedExtent:!0}),d=l.length-1,f,p,m;if(d===1)f=p=0,m=1;else if(d===2){var h=co(l[0].value-l[1].value),g=co(l[1].value-l[2].value);f=p=0,h===g?m=2:(m=1,h<g?f=h/g:p=g/h)}else{var _=o.getConfig().interval;f=(1-(l[0].value-u[0].value)/_)%1,p=(1-(u[d].value-l[d].value)/_)%1,m=d-+!!f-!!p}var v=i.zoomFixMM,y=v[0]||v[1],b=[i.fixMM[0]||y,i.fixMM[1]||y],x=n.getExtent(),S=s.getExtent(),C=Jw(S,b),w,T,E,D,O,k;function A(e){for(var t=50,n=0;n<t&&!e();n++)E=a?E*so(c,2):Ww(E),D=Gw(E)}function j(){w=X(k-E*f,D)}function ee(){T=X(O+E*p,D)}function te(){k=f?X(w+E*f,D):w}function ne(){O=p?X(T-E*p,D):T}if(b[0]&&b[1]){w=C[0],T=C[1],E=(T-w)/(m+f+p);var re=e.getExtent(),ie=co(re[1]-re[0]);D=Eo([T,w],ie,.5/m),te(),ne(),Vo(D)&&(E=X(E,D))}else{var ae=C[1]-C[0];E=a?so(No(ae),1):Fo(ae/m,2),D=Gw(E),b[0]?(w=C[0],A(function(){if(te(),O=X(k+E*m,D),ee(),T>=C[1])return!0})):b[1]?(T=C[1],A(function(){if(ne(),k=X(O-E*m,D),j(),w<=C[0])return!0})):A(function(){k=X(fo(C[0]/E)*E,D),O=X(uo(C[1]/E)*E,D);var e=lo((O-k)/E);if(e<=m){var t=m-e,n=void 0,r=i.incl0||a;if(r&&C[0]===0)n=[0,t];else if(r&&C[1]===0)n=[t,0];else{var o=uo(t/2);n=t%2==0?[o,o]:w+T<C[0]+C[1]?[o,o+1]:[o+1,o]}if(k=X(k-E*n[0],D),O=X(O+E*n[1],D),j(),ee(),w<=C[0]&&T>=C[1])return!0}})}LT(n,b,S,[w,T],x,{interval:E,intervalCount:m,intervalPrecision:D,niceExtent:[k,O]})}var Xk=[[3,1],[0,2]],Zk=function(){function e(e,t,n){this.type=`grid`,this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=Kk,this._initCartesian(e,t,n),this.model=e}return e.prototype.getRect=function(){return this._rect},e.prototype.update=function(e,t){var n=this._axesMap;z(this._axesList,function(e){cE(e,1);var t=e.scale;Uw(t)&&t.setSortInfo(e.model.get(`categorySortInfo`))});function r(e){for(var t=Oe(e),n=[],r=t.length-1;r>=0;r--){var i=e[+t[r]];i.__alignTo?n.push(i):yE(i)}z(n,function(e){nA(e,e.__alignTo)?yE(e):Yk(e,e.__alignTo.scale)})}r(n.x),r(n.y);var i={};z(n.x,function(e){$k(n,`y`,e,i)}),z(n.y,function(e){$k(n,`x`,e,i)}),this.resize(this.model,t)},e.prototype.resize=function(e,t,n){var r=xg(e,t),i=this._rect=yg(e.getBoxLayoutParams(),r.refContainer),a=this._axesMap,o=this._coordsList,s=e.get(`containLabel`);if(iA(a,i),!n){var c=cA(i,o,a,s,t),l=void 0;if(s)oA?(oA(this._axesList,i),iA(a,i)):l=sA(i.clone(),`axisLabel`,null,i,a,c,r);else{var u=uA(e,i,r),d=u.outerBoundsRect,f=u.parsedOuterBoundsContain,p=u.outerBoundsClamp;d&&(l=sA(d,f,p,i,a,c,r))}lA(i,a,OE.determine,null,l,r),z(this._coordsList,function(e){e.calcAffineTransform()})}},e.prototype.getAxis=function(e,t){var n=this._axesMap[e];if(n!=null)return n[t||0]},e.prototype.getAxes=function(){return this._axesList.slice()},e.prototype.getCartesian=function(e,t){if(e!=null&&t!=null){var n=`x`+e+`y`+t;return this._coordsMap[n]}K(e)&&(t=e.yAxisIndex,e=e.xAxisIndex);for(var r=0,i=this._coordsList;r<i.length;r++)if(i[r].getAxis(`x`).index===e||i[r].getAxis(`y`).index===t)return i[r]},e.prototype.getCartesians=function(){return this._coordsList.slice()},e.prototype.convertToPixel=function(e,t,n){var r=this._findConvertTarget(t);return r.cartesian?r.cartesian.dataToPoint(n):r.axis?r.axis.toGlobalCoord(r.axis.dataToCoord(n)):null},e.prototype.convertFromPixel=function(e,t,n){var r=this._findConvertTarget(t);return r.cartesian?r.cartesian.pointToData(n):r.axis?r.axis.coordToData(r.axis.toLocalCoord(n)):null},e.prototype._findConvertTarget=function(e){var t=e.seriesModel,n=e.xAxisModel||t&&t.getReferringComponents(`xAxis`,xs).models[0],r=e.yAxisModel||t&&t.getReferringComponents(`yAxis`,xs).models[0],i=e.gridModel,a=this._coordsList,o,s;return t?(o=t.coordinateSystem,R(a,o)<0&&(o=null)):n&&r?o=this.getCartesian(n.componentIndex,r.componentIndex):n?s=this.getAxis(`x`,n.componentIndex):r?s=this.getAxis(`y`,r.componentIndex):i&&i.coordinateSystem===this&&(o=this._coordsList[0]),{cartesian:o,axis:s}},e.prototype.containPoint=function(e){var t=this._coordsList[0];if(t)return t.containPoint(e)},e.prototype._initCartesian=function(e,t,n){var r=this,i=this,a={left:!1,right:!1,top:!1,bottom:!1},o={x:{},y:{}},s={x:0,y:0};if(t.eachComponent(`xAxis`,c(`x`),this),t.eachComponent(`yAxis`,c(`y`),this),!s.x||!s.y){this._axesMap={},this._axesList=[];return}this._axesMap=o,z(o.x,function(t,n){z(o.y,function(i,a){var o=`x`+n+`y`+a,s=new Jk(o);s.master=r,s.model=e,r._coordsMap[o]=s,r._coordsList.push(s),s.addAxis(t),s.addAxis(i)})}),tA(o.x),tA(o.y);function c(t){return function(n,r){if(Qk(n,e)){var c=n.get(`position`);t===`x`?c!==`top`&&c!==`bottom`&&(c=a.bottom?`top`:`bottom`):c!==`left`&&c!==`right`&&(c=a.left?`right`:`left`),a[c]=!0;var l=CT(n),u=new zO(t,wT(n,l,!0),[0,0],l,c);u.onBand=zT(u.scale,n),u.inverse=n.get(`inverse`),n.axis=u,u.model=n,u.grid=i,u.index=r,i._axesList.push(u),o[t][r]=u,s[t]++}}}},e.prototype.getTooltipAxes=function(e){var t=[],n=[];return z(this.getCartesians(),function(r){var i=e!=null&&e!==`auto`?r.getAxis(e):r.getBaseAxis(),a=r.getOtherAxis(i);R(t,i)<0&&t.push(i),R(n,a)<0&&n.push(a)}),{baseAxes:t,otherAxes:n}},e.create=function(t,n){var r=[];return t.eachComponent(`grid`,function(i,a){var o=new e(i,t,n);o.name=`grid_`+a,o.resize(i,n,!0),i.coordinateSystem=o,r.push(o),z(o._axesList,function(t){sE(t,e.dimIdxMap)})}),t.eachSeries(function(e){var t,n;fg({targetModel:e,coordSysType:kk,coordSysProvider:r});function r(){var r=Ck(e),i=r.xAxisModel,a=r.yAxisModel;return t=i.axis,n=a.axis,i.getCoordSysModel().coordinateSystem.getCartesian(i.componentIndex,a.componentIndex)}t&&n&&(XT(t,e,kk),XT(n,e,kk))},this),r},e.dimensions=Kk,e.dimIdxMap=WC(Kk),e}();function Qk(e,t){return e.getCoordSysModel()===t}function $k(e,t,n,r){n.getAxesOnZeroOf=function(){return a?[a]:[]};var i=e[t],a,o=n.model,s=o.get([`axisLine`,`onZero`]),c=o.get([`axisLine`,`onZeroAxisIndex`]);if(!s)return;if(c!=null)eA(s,i[c])&&(a=i[c]);else for(var l in i)if(et(i,l)&&eA(s,i[l])&&!r[u(i[l])]){a=i[l];break}a&&(r[u(a)]=!0);function u(e){return e.dim+`_`+e.index}}function eA(e,t){if(!t)return!1;var n=t.scale,r=TT(n,0,!1),i=t&&t.type!==`category`&&t.type!==`time`&&r!==3;return i&&e===`auto`&&DT(t)&&(i=!1),i}function tA(e){for(var t=Oe(e),n,r=[],i=t.length-1;i>=0;i--){var a=e[+t[i]];zw(a.scale)&&FT(a.model,a.type,!0)==null&&(a.model.get(`alignTicks`)&&a.model.get(`interval`)==null?r.push(a):n=a)}n||=r.pop(),n&&z(r,function(e){e.__alignTo=n})}function nA(e,t){return ph(e.scale)||ph(t.scale)||t.scale.getTicks().length<2}function rA(e,t){var n=e.getExtent(),r=n[0]+n[1];e.toGlobalCoord=e.dim===`x`?function(e){return e+t}:function(e){return r-e+t},e.toLocalCoord=e.dim===`x`?function(e){return e-t}:function(e){return r-e+t}}function iA(e,t){z(e.x,function(e){return aA(e,t.x,t.width)}),z(e.y,function(e){return aA(e,t.y,t.height)})}function aA(e,t,n){var r=[0,n],i=+!!e.inverse;e.setExtent(r[i],r[1-i]),rA(e,t)}var oA;function sA(e,t,n,r,i,a,o){lA(r,i,OE.estimate,t,!1,o);var s=[0,0,0,0];l(0),l(1),u(r,0,NaN),u(r,1,NaN);var c=De(s,function(e){return e>0})==null;return tm(r,s,!0,!0,n),iA(i,r),c;function l(e){z(i[Dp[e]],function(t){if(PT(t.model)){var n=a.ensureRecord(t.model),r=n.labelInfoList;if(r)for(var i=0;i<r.length;i++){var o=r[i],s=t.scale.normalize(RT(t.scale,KO(o.label).labelInfo.tick));s=e===1?1-s:s,u(o.rect,e,s),u(o.rect,1-e,NaN)}var c=n.nameLayout;if(c){var s=NT(n.nameLocation)?.5:NaN;u(c.rect,e,s),u(c.rect,1-e,NaN)}}})}function u(t,n,r){var i=e[Dp[n]]-t[Dp[n]],a=t[Op[n]]+t[Dp[n]]-(e[Op[n]]+e[Dp[n]]);i=d(i,1-r),a=d(a,r);var o=Xk[n][0],c=Xk[n][1];s[o]=so(s[o],i),s[c]=so(s[c],a)}function d(e,t){return e>0&&!Le(t)&&t>1e-4&&(e/=t),e}}function cA(e,t,n,r,i){var a=new JO(dA);return z(n,function(n){return z(n,function(n){if(PT(n.model)){var o=!r;n.axisBuilder=wk(e,t,n.model,i,a,o)}})}),a}function lA(e,t,n,r,i,a){var o=n===OE.determine;z(t,function(t){return z(t,function(t){PT(t.model)&&(Tk(t.axisBuilder,e,t.model),t.axisBuilder.build(o?{axisTickLabelDetermine:!0}:{axisTickLabelEstimate:!0},{noPxChange:i}))})});var s={x:0,y:0};c(0),c(1);function c(t){s[Dp[1-t]]=e[Op[t]]<=a.refContainer[Op[t]]*.5?0:1-t==1?2:1}z(t,function(e,t){return z(e,function(e){PT(e.model)&&((r===`all`||o)&&e.axisBuilder.build({axisName:!0},{nameMarginLevel:s[t]}),o&&e.axisBuilder.build({axisLine:!0}))})})}function uA(e,t,n){var r,i=e.get(`outerBoundsMode`,!0);i===`same`?r=t.clone():(i==null||i===`auto`)&&(r=yg(e.get(`outerBounds`,!0)||Dk,n.refContainer));var a=e.get(`outerBoundsContain`,!0),o=a==null||a===`auto`||R([`all`,`axisLabel`],a)<0?`all`:a,s=[xo(q(e.get(`outerBoundsClampWidth`,!0),Ok[0]),t.width),xo(q(e.get(`outerBoundsClampHeight`,!0),Ok[1]),t.height)];return{outerBoundsRect:r,parsedOuterBoundsContain:o,outerBoundsClamp:s}}var dA=function(e,t,n,r,i,a){var o=n.axis.dim===`x`?`y`:`x`;QO(e,t,n,r,i,a),NT(e.nameLocation)||z(t.recordMap[o],function(e){e&&e.labelInfoList&&e.dirVec&&ek(e.labelInfoList,e.dirVec,r,i)})};function fA(e,t){var n={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return pA(n,e,t),n.seriesInvolved&&hA(n,e),n}function pA(e,t,n){var r=t.getComponent(`tooltip`),i=t.getComponent(`axisPointer`),a=i.get(`link`,!0)||[],o=[];z(n.getCoordinateSystems(),function(n){if(!n.axisPointerEnabled)return;var s=SA(n.model),c=e.coordSysAxesInfo[s]={};e.coordSysMap[s]=n;var l=n.model.getModel(`tooltip`,r);if(z(n.getAxes(),H(p,!1,null)),n.getTooltipAxes&&r&&l.get(`show`)){var u=l.get(`trigger`)===`axis`,d=l.get([`axisPointer`,`type`])===`cross`,f=n.getTooltipAxes(l.get([`axisPointer`,`axis`]));(u||d)&&z(f.baseAxes,H(p,d?`cross`:!0,u)),d&&z(f.otherAxes,H(p,`cross`,!1))}function p(r,s,u){var d=u.model.getModel(`axisPointer`,i),f=d.get(`show`);if(!(!f||f===`auto`&&!r&&!xA(d))){s??=d.get(`triggerTooltip`),d=r?mA(u,l,i,t,r,s):d;var p=d.get(`snap`),m=d.get(`triggerEmphasis`),h=SA(u.model),g=s||p||u.type===`category`,_=e.axesInfo[h]={key:h,axis:u,coordSys:n,axisPointerModel:d,triggerTooltip:s,triggerEmphasis:m,involveSeries:g,snap:p,useHandle:xA(d),seriesModels:[],linkGroup:null};c[h]=_,e.seriesInvolved=e.seriesInvolved||g;var v=gA(a,u);if(v!=null){var y=o[v]||(o[v]={axesInfo:{}});y.axesInfo[h]=_,y.mapper=a[v].mapper,_.linkGroup=y}}}})}function mA(e,t,n,r,i,a){var o=t.getModel(`axisPointer`),s=[`type`,`snap`,`lineStyle`,`shadowStyle`,`label`,`animation`,`animationDurationUpdate`,`animationEasingUpdate`,`z`],c={};z(s,function(e){c[e]=P(o.get(e))}),c.snap=e.type!==`category`&&!!a,o.get(`type`)===`cross`&&(c.type=`line`);var l=c.label||={};if(l.show??=!1,i===`cross`&&(l.show=o.get([`label`,`show`])??!0,!a)){var u=c.lineStyle=o.get(`crossStyle`);u&&L(l,u.textStyle)}return e.model.getModel(`axisPointer`,new Gm(c,n,r))}function hA(e,t){t.eachSeries(function(t){var n=t.coordinateSystem,r=t.get([`tooltip`,`trigger`],!0),i=t.get([`tooltip`,`show`],!0);!n||!n.model||r===`none`||r===!1||r===`item`||i===!1||t.get([`axisPointer`,`show`],!0)===!1||z(e.coordSysAxesInfo[SA(n.model)],function(e){var r=e.axis;n.getAxis(r.dim)===r&&(e.seriesModels.push(t),e.seriesDataCount??=0,e.seriesDataCount+=t.getData().count())})})}function gA(e,t){for(var n=t.model,r=t.dim,i=0;i<e.length;i++){var a=e[i]||{};if(_A(a[r+`AxisId`],n.id)||_A(a[r+`AxisIndex`],n.componentIndex)||_A(a[r+`AxisName`],n.name))return i}}function _A(e,t){return e===`all`||U(e)&&R(e,t)>=0||e===t}function vA(e){var t=yA(e);if(t){var n=t.axisPointerModel,r=t.axis.scale,i=n.option,a=n.get(`status`),o=n.get(`value`);o!=null&&(o=r.parse(o));var s=xA(n);a??(i.status=s?`show`:`hide`);var c=r.getExtent();(o==null||o>c[1])&&(o=c[1]),o<c[0]&&(o=c[0]),i.value=o,s&&(i.status=t.axis.scale.isBlank()?`hide`:`show`)}}function yA(e){var t=(e.ecModel.getComponent(`axisPointer`)||{}).coordSysAxesInfo;return t&&t.axesInfo[SA(e)]}function bA(e){var t=yA(e);return t&&t.axisPointerModel}function xA(e){return!!e.get([`handle`,`show`])}function SA(e){return e.type+`||`+e.id}var CA={},wA=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.render=function(t,n,r,i){this.axisPointerClass&&vA(t),e.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(t,r,!0)},t.prototype.updateAxisPointer=function(e,t,n,r){this._doUpdateAxisPointerClass(e,n,!1)},t.prototype.remove=function(e,t){var n=this._axisPointer;n&&n.remove(t)},t.prototype.dispose=function(t,n){this._disposeAxisPointer(n),e.prototype.dispose.apply(this,arguments)},t.prototype._doUpdateAxisPointerClass=function(e,n,r){var i=t.getAxisPointerClass(this.axisPointerClass);if(i){var a=bA(e);a?(this._axisPointer||=new i).render(e,a,n,r):this._disposeAxisPointer(n)}},t.prototype._disposeAxisPointer=function(e){this._axisPointer&&this._axisPointer.dispose(e),this._axisPointer=null},t.registerAxisPointerClass=function(e,t){CA[e]=t},t.getAxisPointerClass=function(e){return e&&CA[e]},t.type=`axis`,t}(Fy),TA=Z();function EA(e,t,n,r){var i=n.axis;if(!i.scale.isBlank()){var a=n.getModel(`splitArea`),o=a.getModel(`areaStyle`),s=o.get(`color`),c=r.coordinateSystem.getRect(),l=i.getTicksCoords({tickModel:a,breakTicks:`none`,pruneByBreak:`preserve_extent_bound`});if(l.length){var u=s.length,d=TA(e).splitAreaColors,f=J(),p=0;if(d)for(var m=0;m<l.length;m++){var h=d.get(l[m].tickValue);if(h!=null){p=(h+(u-1)*m)%u;break}}var g=i.toGlobalCoord(l[0].coord),_=o.getAreaStyle();s=U(s)?s:[s];for(var m=1;m<l.length;m++){var v=i.toGlobalCoord(l[m].coord),y=void 0,b=void 0,x=void 0,S=void 0;i.isHorizontal()?(y=g,b=c.y,x=v-y,S=c.height,g=y+x):(y=c.x,b=g,x=c.width,S=v-b,g=b+S);var C=l[m-1].tickValue;C!=null&&f.set(C,p),t.add(new cu({anid:C==null?null:`area_`+C,shape:{x:y,y:b,width:x,height:S},style:L({fill:s[p]},_),autoBatch:!0,silent:!0})),p=(p+1)%u}TA(e).splitAreaColors=f}}}function DA(e){TA(e).splitAreaColors=null}var OA=[`splitArea`,`splitLine`,`minorSplitLine`,`breakArea`],kA=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.axisPointerClass=`CartesianAxisPointer`,n}return t.prototype.render=function(t,n,r,i){this.group.removeAll();var a=this._axisGroup;this._axisGroup=new Ya,this.group.add(this._axisGroup),PT(t)&&(this._axisGroup.add(t.axis.axisBuilder.group),z(OA,function(e){t.get([e,`show`])&&AA[e](this,this._axisGroup,t,t.getCoordSysModel(),r)},this),i&&i.type===`changeAxisOrder`&&i.isInitSort||qp(a,this._axisGroup,t),e.prototype.render.call(this,t,n,r,i))},t.prototype.remove=function(){DA(this)},t.type=`cartesianAxis`,t}(wA),AA={splitLine:function(e,t,n,r,i){var a=n.axis;if(!a.scale.isBlank()){var o=n.getModel(`splitLine`),s=o.getModel(`lineStyle`),c=s.get(`color`),l=o.get(`showMinLine`)!==!1,u=o.get(`showMaxLine`)!==!1;c=U(c)?c:[c];for(var d=r.coordinateSystem.getRect(),f=a.isHorizontal(),p=0,m=a.getTicksCoords({tickModel:o,breakTicks:`none`,pruneByBreak:`preserve_extent_bound`}),h=[],g=[],_=s.getLineStyle(),v=0;v<m.length;v++){var y=a.toGlobalCoord(m[v].coord);if(!(v===0&&!l||v===m.length-1&&!u)){var b=m[v].tickValue;f?(h[0]=y,h[1]=d.y,g[0]=y,g[1]=d.y+d.height):(h[0]=d.x,h[1]=y,g[0]=d.x+d.width,g[1]=y);var x=p++%c.length,S=new qf({anid:b==null?null:`line_`+b,autoBatch:!0,shape:{x1:h[0],y1:h[1],x2:g[0],y2:g[1]},style:L({stroke:c[x]},_),silent:!0});zp(S.shape,_.lineWidth),t.add(S)}}}},minorSplitLine:function(e,t,n,r,i){var a=n.axis,o=n.getModel(`minorSplitLine`).getModel(`lineStyle`),s=r.coordinateSystem.getRect(),c=a.isHorizontal(),l=a.getMinorTicksCoords();if(l.length)for(var u=[],d=[],f=o.getLineStyle(),p=0;p<l.length;p++)for(var m=0;m<l[p].length;m++){var h=a.toGlobalCoord(l[p][m].coord);c?(u[0]=h,u[1]=s.y,d[0]=h,d[1]=s.y+s.height):(u[0]=s.x,u[1]=h,d[0]=s.x+s.width,d[1]=h);var g=new qf({anid:`minor_line_`+l[p][m].tickValue,autoBatch:!0,shape:{x1:u[0],y1:u[1],x2:d[0],y2:d[1]},style:f,silent:!0});zp(g.shape,f.lineWidth),t.add(g)}},splitArea:function(e,t,n,r,i){EA(e,t,n,r)},breakArea:function(e,t,n,r,i){var a=VO(),o=n.axis.scale;a&&o.type!==`ordinal`&&a.rectCoordBuildBreakAxis(t,e,n,r.coordinateSystem.getRect(),i)}},jA=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.type=`xAxis`,t}(kA),MA=function(e){k(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.type=jA.type,t}return t.type=`yAxis`,t}(kA),NA=function(e){k(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.type=`grid`,t}return t.prototype.render=function(e,t){this.group.removeAll(),e.get(`show`)&&this.group.add(new cu({shape:e.coordinateSystem.getRect(),style:L({fill:e.get(`backgroundColor`)},e.getItemStyle()),silent:!0,z2:-1}))},t.type=`grid`,t}(Fy),PA={offset:0};function FA(e){e.registerComponentView(NA),e.registerComponentModel(Ak),e.registerCoordinateSystem(`cartesian2d`,Zk),Uk(e,`x`,Rk,PA),Uk(e,`y`,Rk,PA),e.registerComponentView(jA),e.registerComponentView(MA),e.registerPreprocessor(function(e){e.xAxis&&e.yAxis&&!e.grid&&(e.grid={})})}function IA(e){TE(FA),e.registerSeriesModel(jk),e.registerChartView(Ik),e.registerLayout(PO(`scatter`))}var LA=Z();function RA(e,t,n){LA(e)[t]=n}function zA(e,t,n){var r=LA(e);r[t]===n&&(r[t]=null)}function BA(e,t){return!!LA(e)[t]}xC({type:`takeGlobalCursor`,event:`globalCursorTaken`,update:`update`},tt);var VA={axisPointer:1,tooltip:1,brush:1};function HA(e,t,n){var r=t.getComponentByElement(e.topTarget);if(!r||r===n||VA.hasOwnProperty(r.mainType))return!1;var i=r.coordinateSystem;if(!i||i.model===n)return!1;var a=dm(r),o=dm(n);return!((a.zlevel-o.zlevel||a.z-o.z)<=0)}var UA=function(e){k(t,e);function t(t){var n=e.call(this)||this;n._zr=t;var r=V(n._mousedownHandler,n),i=V(n._mousemoveHandler,n),a=V(n._mouseupHandler,n),o=V(n._mousewheelHandler,n),s=V(n._pinchHandler,n);return n.enable=function(e,n){var c=n.zInfo,l=dm(c.component),u=l.z,d=l.zlevel,f={component:c.component,z:u,zlevel:d,z2:q(c.z2,-1/0)},p=I({},n.triggerInfo);this._opt=L(I({},n),{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0,zInfoParsed:f,triggerInfo:p,cursorGrab:`grab`,cursorGrabbing:`grabbing`}),e??=!0,(!this._enabled||this._controlType!==e)&&(this.disable(),this._enabled=!0,(e===!0||e===`move`||e===`pan`)&&(qA(t,`mousedown`,r,f),qA(t,`mousemove`,i,f),qA(t,`mouseup`,a,f)),(e===!0||e===`scale`||e===`zoom`)&&(qA(t,`mousewheel`,o,f),qA(t,`pinch`,s,f)))},n.disable=function(){this._enabled&&(this._enabled=!1,JA(t,`mousedown`,r),JA(t,`mousemove`,i),JA(t,`mouseup`,a),JA(t,`mousewheel`,o),JA(t,`pinch`,s))},n}return t.prototype.isDragging=function(){return this._dragging},t.prototype.isPinching=function(){return this._pinching},t.prototype._checkPointer=function(e,t,n){var r=this._opt,i=r.zInfoParsed;if(HA(e,r.api,i.component))return!1;var a=r.triggerInfo,o=a.roamTrigger,s=!1;return o===`global`&&(s=!0),s||=a.isInSelf(e,t,n),s&&a.isInClip&&!a.isInClip(e,t,n)&&(s=!1),s},t.prototype._decideCursorStyle=function(e,t,n,r){var i=e.target;if(!i&&this._checkPointer(e,t,n))return this._opt.cursorGrab;if(r)return i&&i.cursor||`default`},t.prototype.dispose=function(){this.disable()},t.prototype._mousedownHandler=function(e){if(!(Xt(e)||WA(e))){for(var t=e.target;t;){if(t.draggable)return;t=t.__hostTarget||t.parent}var n=e.offsetX,r=e.offsetY;this._checkPointer(e,n,r)&&(this._x=n,this._y=r,this._dragging=!0)}},t.prototype._mousemoveHandler=function(e){var t=this._zr;if(!(e.gestureEvent===`pinch`||BA(t,`globalPan`)||WA(e))){var n=e.offsetX,r=e.offsetY;if(!this._dragging||!QA(`moveOnMouseMove`,e,this._opt)){var i=this._decideCursorStyle(e,n,r,!1);i&&t.setCursorStyle(i);return}t.setCursorStyle(this._opt.cursorGrabbing);var a=this._x,o=this._y,s=n-a,c=r-o;this._x=n,this._y=r,this._opt.preventDefaultMouseMove&&Yt(e.event),e.__ecRoamConsumed=!0,ZA(this,`pan`,`moveOnMouseMove`,e,{dx:s,dy:c,oldX:a,oldY:o,newX:n,newY:r,isAvailableBehavior:null})}},t.prototype._mouseupHandler=function(e){if(!WA(e)){var t=this._zr;if(!Xt(e)){this._dragging=!1;var n=this._decideCursorStyle(e,e.offsetX,e.offsetY,!0);n&&t.setCursorStyle(n)}}},t.prototype._mousewheelHandler=function(e){if(!WA(e)){var t=QA(`zoomOnMouseWheel`,e,this._opt),n=QA(`moveOnMouseWheel`,e,this._opt),r=e.wheelDelta,i=Math.abs(r),a=e.offsetX,o=e.offsetY;if(!(r===0||!t&&!n)){if(t){var s=i>3?1.4:i>1?1.2:1.1,c=r>0?s:1/s;this._checkTriggerMoveZoom(this,`zoom`,`zoomOnMouseWheel`,e,{scale:c,originX:a,originY:o,isAvailableBehavior:null})}if(n){var l=Math.abs(r),u=(r>0?1:-1)*(l>3?.4:l>1?.15:.05);this._checkTriggerMoveZoom(this,`scrollMove`,`moveOnMouseWheel`,e,{scrollDelta:u,originX:a,originY:o,isAvailableBehavior:null})}}}},t.prototype._pinchHandler=function(e){if(!(BA(this._zr,`globalPan`)||WA(e))){var t=e.pinchScale>1?1.1:1/1.1;this._checkTriggerMoveZoom(this,`zoom`,null,e,{scale:t,originX:e.pinchX,originY:e.pinchY,isAvailableBehavior:null})}},t.prototype._checkTriggerMoveZoom=function(e,t,n,r,i){e._checkPointer(r,i.originX,i.originY)&&(Yt(r.event),r.__ecRoamConsumed=!0,ZA(e,t,n,r,i))},t}(wt);function WA(e){return e.__ecRoamConsumed}var GA=Z();function KA(e){var t=GA(e);return t.roam=t.roam||{},t.uniform=t.uniform||{},t}function qA(e,t,n,r){for(var i=KA(e).roam,a=i[t]=i[t]||[],o=0;o<a.length;o++){var s=a[o].zInfoParsed;if((s.zlevel-r.zlevel||s.z-r.z||s.z2-r.z2)<=0)break}a.splice(o,0,{listener:n,zInfoParsed:r}),YA(e,t)}function JA(e,t,n){for(var r=KA(e).roam[t]||[],i=0;i<r.length;i++)if(r[i].listener===n){r.splice(i,1),r.length||XA(e,t);return}}function YA(e,t){var n=KA(e);n.uniform[t]||e.on(t,n.uniform[t]=function(e){var r=n.roam[t];if(r)for(var i=0;i<r.length;i++)r[i].listener(e)})}function XA(e,t){var n=KA(e).uniform;n[t]&&(e.off(t,n[t]),n[t]=null)}function ZA(e,t,n,r,i){i.isAvailableBehavior=V(QA,null,n,r),e.trigger(t,i)}function QA(e,t,n){var r=n[e];return!e||r&&(!G(r)||t.event[r+`Key`])}function $A(e){return e}var ej=`view`;(function(e){k(t,e);function t(t,n,r){var i=e.call(this)||this;i.type=ej,i.dimensions=[`x`,`y`];var a=$A(i);a.invertY=t,a.lgCt=n,a.lgGeo=r;var o=a.trans=[];return o[0]=ha(),o[1]=ha(),o[2]=ha(),a.mtRaw=tn(),a.mtRawInv=tn(),a.mtOverall=tn(),a.mtOverallInv=tn(),a.zoom=1,i}return t.prototype.getBoundingRect=function(){return rj(null,this)},t.prototype.getViewRect=function(){return ij(null,this)},t.prototype.getRoamTransform=function(){return ma($A(this).trans[1])},t.prototype.dataToPoint=function(e,t,n){var r=t?$A(this).mtRaw:$A(this).mtOverall;return n||=[],r?yt(n,e,r):ot(n,e)},t.prototype.pointToData=function(e,t,n){n||=[];var r=$A(this).mtOverallInv;return r?yt(n,e,r):ot(n,e)},t.prototype.convertToPixel=function(e,t,n){var r=aj(t);return r===this?r.dataToPoint(n):null},t.prototype.convertFromPixel=function(e,t,n){var r=aj(t);return r===this?r.pointToData(n):null},t.prototype.containPoint=function(e){var t=$A(this);return En(tj,t.dataRect),On(tj,tj,t.mtOverall),kn(tj,e[0],e[1])},t.dimensions=[`x`,`y`],t})(pa);var tj=wn();function nj(e,t){return rn(e||[],$A(t).mtOverall)}function rj(e,t){return En(e||wn(),$A(t).dataRect)}function ij(e,t){return En(e||wn(),$A(t).viewRect)}wn();function aj(e){var t=e.seriesModel;return t?t.coordinateSystem:null}ha(),ha();var oj=qf.prototype,sj=Zf.prototype,cj=function(){function e(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return e}();(function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t})(cj);function lj(e){return isNaN(+e.cpx1)||isNaN(+e.cpy1)}var uj=function(e){k(t,e);function t(t){var n=e.call(this,t)||this;return n.type=`ec-line`,n}return t.prototype.getDefaultStyle=function(){return{stroke:Q.color.neutral99,fill:null}},t.prototype.getDefaultShape=function(){return new cj},t.prototype.buildPath=function(e,t){lj(t)?oj.buildPath.call(this,e,t):sj.buildPath.call(this,e,t)},t.prototype.pointAt=function(e){return lj(this.shape)?oj.pointAt.call(this,e):sj.pointAt.call(this,e)},t.prototype.tangentAt=function(e){var t=this.shape,n=lj(t)?[t.x2-t.x1,t.y2-t.y1]:sj.tangentAt.call(this,e);return mt(n,n)},t}(Jl),dj=[`fromSymbol`,`toSymbol`];function fj(e){return`_`+e+`Type`}function pj(e,t,n){var r=t.getItemVisual(n,e);if(!r||r===`none`)return r;var i=t.getItemVisual(n,e+`Size`),a=t.getItemVisual(n,e+`Rotate`),o=t.getItemVisual(n,e+`Offset`),s=t.getItemVisual(n,e+`KeepAspect`),c=ix(i),l=ax(o||0,c);return r+c+l+(a||``)+(s||``)}function mj(e,t,n){var r=t.getItemVisual(n,e);if(!(!r||r===`none`)){var i=t.getItemVisual(n,e+`Size`),a=t.getItemVisual(n,e+`Rotate`),o=t.getItemVisual(n,e+`Offset`),s=t.getItemVisual(n,e+`KeepAspect`),c=ix(i),l=ax(o||0,c),u=rx(r,-c[0]/2+l[0],-c[1]/2+l[1],c[0],c[1],null,s);return u.__specifiedRotation=a==null||isNaN(a)?void 0:+a*Math.PI/180||0,u.name=e,u}}function hj(e){var t=new uj({name:`line`,subPixelOptimize:!0});return gj(t.shape,e),t}function gj(e,t){e.x1=t[0][0],e.y1=t[0][1],e.x2=t[1][0],e.y2=t[1][1],e.percent=1;var n=t[2];n?(e.cpx1=n[0],e.cpy1=n[1]):(e.cpx1=NaN,e.cpy1=NaN)}var _j=function(e){k(t,e);function t(t,n,r){var i=e.call(this)||this;return i._createLine(t,n,r),i}return t.prototype._createLine=function(e,t,n){var r=e.hostModel,i=e.getItemLayout(t),a=e.getItemVisual(t,`z2`),o=hj(i);o.shape.percent=0,yp(o,{z2:q(a,0),shape:{percent:1}},r,t),this.add(o),z(dj,function(n){var r=mj(n,e,t);this.add(r),this[fj(n)]=pj(n,e,t)},this),this._updateCommonStl(e,t,n)},t.prototype.updateData=function(e,t,n){var r=e.hostModel,i=this.childOfName(`line`),a=e.getItemLayout(t),o={shape:{}};gj(o.shape,a),vp(i,o,r,t),z(dj,function(n){var r=pj(n,e,t),i=fj(n);if(this[i]!==r){this.remove(this.childOfName(n));var a=mj(n,e,t);this.add(a)}this[i]=r},this),this._updateCommonStl(e,t,n)},t.prototype.getLinePath=function(){return this.childAt(0)},t.prototype._updateCommonStl=function(e,t,n){var r=e.hostModel,i=this.childOfName(`line`),a=n&&n.emphasisLineStyle,o=n&&n.blurLineStyle,s=n&&n.selectLineStyle,c=n&&n.labelStatesModels,l=n&&n.emphasisDisabled,u=n&&n.focus,d=n&&n.blurScope;if(!n||e.hasItemOption){var f=e.getItemModel(t),p=f.getModel(`emphasis`);a=p.getModel(`lineStyle`).getLineStyle(),o=f.getModel([`blur`,`lineStyle`]).getLineStyle(),s=f.getModel([`select`,`lineStyle`]).getLineStyle(),l=p.get(`disabled`),u=p.get(`focus`),d=p.get(`blurScope`),c=Cm(f)}var m=e.getItemVisual(t,`style`),h=m.stroke;i.useStyle(m),i.style.fill=null,i.style.strokeNoScale=!0,i.ensureState(`emphasis`).style=a,i.ensureState(`blur`).style=o,i.ensureState(`select`).style=s,z(dj,function(e){var t=this.childOfName(e);if(t){t.setColor(h),t.style.opacity=m.opacity;for(var n=0;n<Wu.length;n++){var r=Wu[n],a=i.getState(r);if(a){var o=a.style||{},s=t.ensureState(r),c=s.style||={};o.stroke!=null&&(c[t.__isEmptyBrush?`stroke`:`fill`]=o.stroke),o.opacity!=null&&(c.opacity=o.opacity)}}t.markRedraw()}},this);var g=r.getRawValue(t);Sm(this,c,{labelDataIndex:t,labelFetcher:{getFormattedLabel:function(t,n){return r.getFormattedLabel(t,n,e.dataType)}},inheritColor:h||Q.color.neutral99,defaultOpacity:m.opacity,defaultText:(g==null?e.getName(t):isFinite(g)?X(g,10):g)+``});var _=this.getTextContent();if(_){var v=c.normal;_.__align=_.style.align,_.__verticalAlign=_.style.verticalAlign,_.__position=v.get(`position`)||`middle`;var y=v.get(`distance`);U(y)||(y=[y,y]),_.__labelDistance=y}this.setTextConfig({position:null,local:!0,inside:!1}),Id(this,u,d,l)},t.prototype.highlight=function(){_d(this)},t.prototype.downplay=function(){vd(this)},t.prototype.updateLayout=function(e,t){this.childOfName(`line`).stopAnimation(),this.setLinePoints(e.getItemLayout(t))},t.prototype.setLinePoints=function(e){var t=this.childOfName(`line`);gj(t.shape,e),t.dirty()},t.prototype.beforeUpdate=function(){var e=this,t=e.childOfName(`fromSymbol`),n=e.childOfName(`toSymbol`),r=e.getTextContent();if(!t&&!n&&(!r||r.ignore))return;for(var i=1,a=this.parent;a;)a.scaleX&&(i/=a.scaleX),a=a.parent;var o=e.childOfName(`line`);if(!this.__dirty&&!o.__dirty)return;var s=o.shape.percent,c=o.pointAt(0),l=o.pointAt(s),u=ut([],l,c);mt(u,u);function d(e,t){var n=e.__specifiedRotation;if(n==null){var r=o.tangentAt(t);e.attr(`rotation`,(t===1?-1:1)*Math.PI/2-Math.atan2(r[1],r[0]))}else e.attr(`rotation`,n)}if(t&&(t.setPosition(c),d(t,0),t.scaleX=t.scaleY=i*s,t.markRedraw()),n&&(n.setPosition(l),d(n,1),n.scaleX=n.scaleY=i*s,n.markRedraw()),r&&!r.ignore){r.x=r.y=0,r.originX=r.originY=0;var f=void 0,p=void 0,m=r.__labelDistance,h=m[0]*i,g=m[1]*i,_=s/2,v=o.tangentAt(_),y=[v[1],-v[0]],b=o.pointAt(_);y[1]>0&&(y[0]=-y[0],y[1]=-y[1]);var x=v[0]<0?-1:1;if(r.__position!==`start`&&r.__position!==`end`){var S=-Math.atan2(v[1],v[0]);l[0]<c[0]&&(S=Math.PI+S),r.rotation=S}var C=void 0;switch(r.__position){case`insideStartTop`:case`insideMiddleTop`:case`insideEndTop`:case`middle`:C=-g,p=`bottom`;break;case`insideStartBottom`:case`insideMiddleBottom`:case`insideEndBottom`:C=g,p=`top`;break;default:C=0,p=`middle`}switch(r.__position){case`end`:r.x=u[0]*h+l[0],r.y=u[1]*g+l[1],f=u[0]>.8?`left`:u[0]<-.8?`right`:`center`,p=u[1]>.8?`top`:u[1]<-.8?`bottom`:`middle`;break;case`start`:r.x=-u[0]*h+c[0],r.y=-u[1]*g+c[1],f=u[0]>.8?`right`:u[0]<-.8?`left`:`center`,p=u[1]>.8?`bottom`:u[1]<-.8?`top`:`middle`;break;case`insideStartTop`:case`insideStart`:case`insideStartBottom`:r.x=h*x+c[0],r.y=c[1]+C,f=v[0]<0?`right`:`left`,r.originX=-h*x,r.originY=-C;break;case`insideMiddleTop`:case`insideMiddle`:case`insideMiddleBottom`:case`middle`:r.x=b[0],r.y=b[1]+C,f=`center`,r.originY=-C;break;case`insideEndTop`:case`insideEnd`:case`insideEndBottom`:r.x=-h*x+l[0],r.y=l[1]+C,f=v[0]>=0?`right`:`left`,r.originX=h*x,r.originY=-C;break}r.scaleX=r.scaleY=i,r.setStyle({verticalAlign:r.__verticalAlign||p,align:r.__align||f})}},t}(Ya),vj=function(){function e(e){this.group=new Ya,this._LineCtor=e||_j}return e.prototype.updateData=function(e){var t=this;this._progressiveEls=null;var n=this,r=n.group,i=n._lineData;n._lineData=e,i||r.removeAll();var a=bj(e);e.diff(i).add(function(n){t._doAdd(e,n,a)}).update(function(n,r){t._doUpdate(i,e,r,n,a)}).remove(function(e){r.remove(i.getItemGraphicEl(e))}).execute()},e.prototype.updateLayout=function(){var e=this._lineData;e&&e.eachItemGraphicEl(function(t,n){t.updateLayout(e,n)},this)},e.prototype.incrementalPrepareUpdate=function(e){this._seriesScope=bj(e),this._lineData=null,this.group.removeAll()},e.prototype.incrementalUpdate=function(e,t,n){this._progressiveEls=[];function r(e){!e.isGroup&&!yj(e)&&(e.incremental=n,e.ensureState(`emphasis`).hoverLayer=2)}for(var i=e.start;i<e.end;i++)if(Sj(t.getItemLayout(i))){var a=new this._LineCtor(t,i,this._seriesScope);a.traverse(r),this.group.add(a),t.setItemGraphicEl(i,a),this._progressiveEls.push(a)}},e.prototype.remove=function(){this.group.removeAll()},e.prototype.eachRendered=function(e){om(this._progressiveEls||this.group,e)},e.prototype._doAdd=function(e,t,n){if(Sj(e.getItemLayout(t))){var r=new this._LineCtor(e,t,n);e.setItemGraphicEl(t,r),this.group.add(r)}},e.prototype._doUpdate=function(e,t,n,r,i){var a=e.getItemGraphicEl(n);if(!Sj(t.getItemLayout(r))){this.group.remove(a);return}a?a.updateData(t,r,i):a=new this._LineCtor(t,r,i),t.setItemGraphicEl(r,a),this.group.add(a)},e}();function yj(e){return e.animators&&e.animators.length>0}function bj(e){var t=e.hostModel,n=t.getModel(`emphasis`);return{lineStyle:t.getModel(`lineStyle`).getLineStyle(),emphasisLineStyle:n.getModel([`lineStyle`]).getLineStyle(),blurLineStyle:t.getModel([`blur`,`lineStyle`]).getLineStyle(),selectLineStyle:t.getModel([`select`,`lineStyle`]).getLineStyle(),emphasisDisabled:n.get(`disabled`),blurScope:n.get(`blurScope`),focus:n.get(`focus`),labelStatesModels:Cm(t)}}function xj(e){return isNaN(e[0])||isNaN(e[1])}function Sj(e){return e&&!xj(e[0])&&!xj(e[1])}function Cj(e,t,n,r,i,a){e||=0;var o=Do(n[1],-n[0]);if(i!=null&&(i=Tj(i,[0,o])),a!=null&&(a=Math.max(a,i??0)),r===`all`){var s=Math.abs(Do(t[1],-t[0]));s=Tj(s,[0,o]),i=a=Tj(s,[i,a]),r=0}t[0]=Tj(t[0],n),t[1]=Tj(t[1],n);var c=wj(t,r);t[r]+=e;var l=i||0,u=n.slice();c.sign<0?u[0]=Do(u[0],l):u[1]=Do(u[1],-l),t[r]=Tj(t[r],u);var d=wj(t,r);return i!=null&&(d.sign!==c.sign||d.span<i)&&(t[1-r]=Do(t[r],c.sign*i)),d=wj(t,r),a!=null&&d.span>a&&(t[1-r]=Do(t[r],d.sign*a)),t}function wj(e,t){var n=e[t]-e[1-t];return{span:Math.abs(n),sign:n>0?-1:n<0?1:t?-1:1}}function Tj(e,t){return Math.min(t[1]==null?1/0:t[1],Math.max(t[0]==null?-1/0:t[0],e))}var Ej=!0,Dj=Math.min,Oj=Math.max,kj=Math.pow,Aj=1e4,jj=6,Mj=6,Nj=`globalPan`,Pj={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},Fj={w:`ew`,e:`ew`,n:`ns`,s:`ns`,ne:`nesw`,sw:`nesw`,nw:`nwse`,se:`nwse`},Ij={brushStyle:{lineWidth:2,stroke:Q.color.backgroundTint,fill:Q.color.borderTint},transformable:!0,brushMode:`single`,removeOnClick:!1},Lj=0,Rj=function(e){k(t,e);function t(t){var n=e.call(this)||this;return n._track=[],n._covers=[],n._handlers={},n._zr=t,n.group=new Ya,n._uid=`brushController_`+ Lj++,z(gM,function(e,t){this._handlers[t]=V(e,this)},n),n}return t.prototype.enableBrush=function(e){return this._brushType&&this._doDisableBrush(),e.brushType&&this._doEnableBrush(e),this},t.prototype._doEnableBrush=function(e){var t=this._zr;this._enableGlobalPan||RA(t,Nj,this._uid),z(this._handlers,function(e,n){t.on(n,e)}),this._brushType=e.brushType,this._brushOption=F(P(Ij),e,!0)},t.prototype._doDisableBrush=function(){var e=this._zr;zA(e,Nj,this._uid),z(this._handlers,function(t,n){e.off(n,t)}),this._brushType=this._brushOption=null},t.prototype.setPanels=function(e){if(e&&e.length){var t=this._panels={};z(e,function(e){t[e.panelId]=P(e)})}else this._panels=null;return this},t.prototype.mount=function(e){e||={},this._enableGlobalPan=e.enableGlobalPan;var t=this.group;return this._zr.add(t),t.attr({x:e.x||0,y:e.y||0,rotation:e.rotation||0,scaleX:e.scaleX||1,scaleY:e.scaleY||1}),this._transform=t.getLocalTransform(),this},t.prototype.updateCovers=function(e){e=B(e,function(e){return F(P(Ij),e,!0)});var t=`\0-brush-index-`,n=this._covers,r=this._covers=[],i=this,a=this._creatingCover;return new NC(n,e,s,o).add(c).update(c).remove(l).execute(),this;function o(e,n){return(e.id==null?t+n:e.id)+`-`+e.brushType}function s(e,t){return o(e.__brushOption,t)}function c(t,o){var s=e[t];o!=null&&n[o]===a?r[t]=n[o]:Uj(i,r[t]=o==null?Bj(i,zj(i,s)):(n[o].__brushOption=s,n[o]))}function l(e){n[e]!==a&&i.group.remove(n[e])}},t.prototype.unmount=function(){return this.enableBrush(!1),qj(this),this._zr.remove(this.group),this},t.prototype.dispose=function(){this.unmount(),this.off()},t}(wt);function zj(e,t){var n=yM[t.brushType].createCover(e,t);return n.__brushOption=t,Hj(n,t),e.group.add(n),n}function Bj(e,t){var n=Wj(t);return n.endCreating&&(n.endCreating(e,t),Hj(t,t.__brushOption)),t}function Vj(e,t){var n=t.__brushOption;Wj(t).updateCoverShape(e,t,n.range,n)}function Hj(e,t){var n=t.z;n??=Aj,e.traverse(function(e){e.z=n,e.z2=n})}function Uj(e,t){Wj(t).updateCommon(e,t),Vj(e,t)}function Wj(e){return yM[e.__brushOption.brushType]}function Gj(e,t,n){var r=e._panels;if(!r)return Ej;var i,a=e._transform;return z(r,function(e){e.isTargetByCursor(t,n,a)&&(i=e)}),i}function Kj(e,t){var n=e._panels;if(!n)return Ej;var r=t.__brushOption.panelId;return r==null?Ej:n[r]}function qj(e){var t=e._covers,n=t.length;return z(t,function(t){e.group.remove(t)},e),t.length=0,!!n}function Jj(e,t){var n=B(e._covers,function(e){var t=e.__brushOption,n=P(t.range);return{brushType:t.brushType,panelId:t.panelId,range:n}});e.trigger(`brush`,{areas:n,isEnd:!!t.isEnd,removeOnClick:!!t.removeOnClick})}function Yj(e){var t=e._track;if(!t.length)return!1;var n=t[t.length-1],r=t[0],i=n[0]-r[0],a=n[1]-r[1];return kj(i*i+a*a,.5)>jj}function Xj(e){var t=e.length-1;return t<0&&(t=0),[e[0],e[t]]}function Zj(e,t,n,r){var i=new Ya;return i.add(new cu({name:`main`,style:tM(n),silent:!0,draggable:!0,cursor:`move`,drift:H(oM,e,t,i,[`n`,`s`,`w`,`e`]),ondragend:H(Jj,t,{isEnd:!0})})),z(r,function(n){i.add(new cu({name:n.join(``),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:H(oM,e,t,i,n),ondragend:H(Jj,t,{isEnd:!0})}))}),i}function Qj(e,t,n,r){var i=r.brushStyle.lineWidth||0,a=Oj(i,Mj),o=n[0][0],s=n[1][0],c=o-i/2,l=s-i/2,u=n[0][1],d=n[1][1],f=u-a+i/2,p=d-a+i/2,m=u-o,h=d-s,g=m+i,_=h+i;eM(e,t,`main`,o,s,m,h),r.transformable&&(eM(e,t,`w`,c,l,a,_),eM(e,t,`e`,f,l,a,_),eM(e,t,`n`,c,l,g,a),eM(e,t,`s`,c,p,g,a),eM(e,t,`nw`,c,l,a,a),eM(e,t,`ne`,f,l,a,a),eM(e,t,`sw`,c,p,a,a),eM(e,t,`se`,f,p,a,a))}function $j(e,t){var n=t.__brushOption,r=n.transformable,i=t.childAt(0);i.useStyle(tM(n)),i.attr({silent:!r,cursor:r?`move`:`default`}),z([[`w`],[`e`],[`n`],[`s`],[`s`,`e`],[`s`,`w`],[`n`,`e`],[`n`,`w`]],function(n){var i=t.childOfName(n.join(``)),a=n.length===1?iM(e,n[0]):aM(e,n);i&&i.attr({silent:!r,invisible:!r,cursor:r?Fj[a]+`-resize`:null})})}function eM(e,t,n,r,i,a,o){var s=t.childOfName(n);s&&s.setShape(uM(lM(e,t,[[r,i],[r+a,i+o]])))}function tM(e){return L({strokeNoScale:!0},e.brushStyle)}function nM(e,t,n,r){var i=[Dj(e,n),Dj(t,r)],a=[Oj(e,n),Oj(t,r)];return[[i[0],a[0]],[i[1],a[1]]]}function rM(e){return Hp(e.group)}function iM(e,t){return{left:`w`,right:`e`,top:`n`,bottom:`s`}[Wp({w:`left`,e:`right`,n:`top`,s:`bottom`}[t],rM(e))]}function aM(e,t){var n=[iM(e,t[0]),iM(e,t[1])];return(n[0]===`e`||n[0]===`w`)&&n.reverse(),n.join(``)}function oM(e,t,n,r,i,a){var o=n.__brushOption,s=e.toRectRange(o.range),c=cM(t,i,a);z(r,function(e){var t=Pj[e];s[t[0]][t[1]]+=c[t[0]]}),o.range=e.fromRectRange(nM(s[0][0],s[1][0],s[0][1],s[1][1])),Uj(t,n),Jj(t,{isEnd:!1})}function sM(e,t,n,r){var i=t.__brushOption.range,a=cM(e,n,r);z(i,function(e){e[0]+=a[0],e[1]+=a[1]}),Uj(e,t),Jj(e,{isEnd:!1})}function cM(e,t,n){var r=e.group,i=r.transformCoordToLocal(t,n),a=r.transformCoordToLocal(0,0);return[i[0]-a[0],i[1]-a[1]]}function lM(e,t,n){var r=Kj(e,t);return r&&r!==Ej?r.clipPath(n,e._transform):P(n)}function uM(e){var t=Dj(e[0][0],e[1][0]),n=Dj(e[0][1],e[1][1]),r=Oj(e[0][0],e[1][0]),i=Oj(e[0][1],e[1][1]);return{x:t,y:n,width:r-t,height:i-n}}function dM(e,t,n){if(!(!e._brushType||vM(e,t.offsetX,t.offsetY))){var r=e._zr,i=e._covers,a=Gj(e,t,n);if(!e._dragging)for(var o=0;o<i.length;o++){var s=i[o].__brushOption;if(a&&(a===Ej||s.panelId===a.panelId)&&yM[s.brushType].contain(i[o],n[0],n[1]))return}a&&r.setCursorStyle(`crosshair`)}}function fM(e){var t=e.event;t.preventDefault&&t.preventDefault()}function pM(e,t,n){return e.childOfName(`main`).contain(t,n)}function mM(e,t,n,r){var i=e._creatingCover,a=e._creatingPanel,o=e._brushOption,s;if(e._track.push(n.slice()),Yj(e)||i){if(a&&!i){o.brushMode===`single`&&qj(e);var c=P(o);c.brushType=hM(c.brushType,a),c.panelId=a===Ej?null:a.panelId,i=e._creatingCover=zj(e,c),e._covers.push(i)}if(i){var l=yM[hM(e._brushType,a)],u=i.__brushOption;u.range=l.getCreatingRange(lM(e,i,e._track)),r&&(Bj(e,i),l.updateCommon(e,i)),Vj(e,i),s={isEnd:r}}}else r&&o.brushMode===`single`&&o.removeOnClick&&Gj(e,t,n)&&qj(e)&&(s={isEnd:r,removeOnClick:!0});return s}function hM(e,t){return e===`auto`?t.defaultBrushType:e}var gM={mousedown:function(e){if(this._dragging)_M(this,e);else if(!e.target||!e.target.draggable){fM(e);var t=this.group.transformCoordToLocal(e.offsetX,e.offsetY);this._creatingCover=null,(this._creatingPanel=Gj(this,e,t))&&(this._dragging=!0,this._track=[t.slice()])}},mousemove:function(e){var t=e.offsetX,n=e.offsetY,r=this.group.transformCoordToLocal(t,n);if(dM(this,e,r),this._dragging){fM(e);var i=mM(this,e,r,!1);i&&Jj(this,i)}},mouseup:function(e){_M(this,e)}};function _M(e,t){if(e._dragging){fM(t);var n=t.offsetX,r=t.offsetY,i=mM(e,t,e.group.transformCoordToLocal(n,r),!0);e._dragging=!1,e._track=[],e._creatingCover=null,i&&Jj(e,i)}}function vM(e,t,n){var r=e._zr;return t<0||t>r.getWidth()||n<0||n>r.getHeight()}var yM={lineX:bM(0),lineY:bM(1),rect:{createCover:function(e,t){function n(e){return e}return Zj({toRectRange:n,fromRectRange:n},e,t,[[`w`],[`e`],[`n`],[`s`],[`s`,`e`],[`s`,`w`],[`n`,`e`],[`n`,`w`]])},getCreatingRange:function(e){var t=Xj(e);return nM(t[1][0],t[1][1],t[0][0],t[0][1])},updateCoverShape:function(e,t,n,r){Qj(e,t,n,r)},updateCommon:$j,contain:pM},polygon:{createCover:function(e,t){var n=new Ya;return n.add(new Wf({name:`main`,style:tM(t),silent:!0})),n},getCreatingRange:function(e){return e},endCreating:function(e,t){t.remove(t.childAt(0)),t.add(new Hf({name:`main`,draggable:!0,drift:H(sM,e,t),ondragend:H(Jj,e,{isEnd:!0})}))},updateCoverShape:function(e,t,n,r){t.childAt(0).setShape({points:lM(e,t,n)})},updateCommon:$j,contain:pM}};function bM(e){return{createCover:function(t,n){return Zj({toRectRange:function(t){var n=[t,[0,100]];return e&&n.reverse(),n},fromRectRange:function(t){return t[e]}},t,n,[[[`w`],[`e`]],[[`n`],[`s`]]][e])},getCreatingRange:function(t){var n=Xj(t);return[Dj(n[0][e],n[1][e]),Oj(n[0][e],n[1][e])]},updateCoverShape:function(t,n,r,i){var a,o=Kj(t,n);if(o!==Ej&&o.getLinearBrushOtherExtent)a=o.getLinearBrushOtherExtent(e);else{var s=t._zr;a=[0,[s.getWidth(),s.getHeight()][1-e]]}var c=[r,a];e&&c.reverse(),Qj(t,n,c,i)},updateCommon:$j,contain:pM}}function xM(e){return e=wM(e),function(t){return Jp(t,e)}}function SM(e,t){return e=wM(e),function(n){var r=t??n,i=r?e.width:e.height,a=r?e.x:e.y;return[a,a+(i||0)]}}function CM(e,t,n){var r=wM(e);return function(e,i){return r.contain(i[0],i[1])&&!HA(e,t,n)}}function wM(e){return Y.create(e)}var TM=Z(),EM=P,DM=V,OM=function(){function e(){this._dragging=!1,this.animationThreshold=15}return e.prototype.render=function(e,t,n,r){var i=t.get(`value`),a=t.get(`status`);if(this._axisModel=e,this._axisPointerModel=t,this._api=n,!(!r&&this._lastValue===i&&this._lastStatus===a)){this._lastValue=i,this._lastStatus=a;var o=this._group,s=this._handle;if(!a||a===`hide`){o&&o.hide(),s&&s.hide();return}o&&o.show(),s&&s.show();var c={};this.makeElOption(c,i,e,t,n);var l=c.graphicKey;l!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=l;var u=this._moveAnimation=this.determineAnimation(e,t);if(!o)o=this._group=new Ya,this.createPointerEl(o,c,e,t),this.createLabelEl(o,c,e,t),n.getZr().add(o);else{var d=H(kM,t,u);this.updatePointerEl(o,c,d),this.updateLabelEl(o,c,d,t)}NM(o,t,!0),this._renderHandle(i)}},e.prototype.remove=function(e){this.clear(e)},e.prototype.dispose=function(e){this.clear(e)},e.prototype.determineAnimation=function(e,t){var n=t.get(`animation`),r=e.axis,i=r.type===`category`,a=t.get(`snap`);if(!a&&!i)return!1;if(n===`auto`||n==null){var o=this.animationThreshold;if(i&&YE(r).w>o)return!0;if(a){var s=yA(e).seriesDataCount,c=r.getExtent();return Math.abs(c[0]-c[1])/s>o}return!1}return n===!0},e.prototype.makeElOption=function(e,t,n,r,i){},e.prototype.createPointerEl=function(e,t,n,r){var i=t.pointer;if(i){var a=TM(e).pointerEl=new Tp[i.type](EM(t.pointer));e.add(a)}},e.prototype.createLabelEl=function(e,t,n,r){if(t.label){var i=TM(e).labelEl=new pu(EM(t.label));e.add(i),jM(i,r)}},e.prototype.updatePointerEl=function(e,t,n){var r=TM(e).pointerEl;r&&t.pointer&&(r.setStyle(t.pointer.style),n(r,{shape:t.pointer.shape}))},e.prototype.updateLabelEl=function(e,t,n,r){var i=TM(e).labelEl;i&&(i.setStyle(t.label.style),n(i,{x:t.label.x,y:t.label.y}),jM(i,r))},e.prototype._renderHandle=function(e){if(!(this._dragging||!this.updateHandleTransform)){var t=this._axisPointerModel,n=this._api.getZr(),r=this._handle,i=t.getModel(`handle`),a=t.get(`status`);if(!i.get(`show`)||!a||a===`hide`){r&&n.remove(r),this._handle=null;return}var o;this._handle||(o=!0,r=this._handle=Xp(i.get(`icon`),{cursor:`move`,draggable:!0,onmousemove:function(e){Yt(e.event)},onmousedown:DM(this._onHandleDragMove,this,0,0),drift:DM(this._onHandleDragMove,this),ondragend:DM(this._onHandleDragEnd,this)}),n.add(r)),NM(r,t,!1),r.setStyle(i.getItemStyle(null,[`color`,`borderColor`,`borderWidth`,`opacity`,`shadowColor`,`shadowBlur`,`shadowOffsetX`,`shadowOffsetY`]));var s=i.get(`size`);U(s)||(s=[s,s]),r.scaleX=s[0]/2,r.scaleY=s[1]/2,Yy(this,`_doDispatchAxisPointer`,i.get(`throttle`)||0,`fixRate`),this._moveHandleToValue(e,o)}},e.prototype._moveHandleToValue=function(e,t){kM(this._axisPointerModel,!t&&this._moveAnimation,this._handle,MM(this.getHandleTransform(e,this._axisModel,this._axisPointerModel)))},e.prototype._onHandleDragMove=function(e,t){var n=this._handle;if(n){this._dragging=!0;var r=this.updateHandleTransform(MM(n),[e,t],this._axisModel,this._axisPointerModel);this._payloadInfo=r,n.stopAnimation(),n.attr(MM(r)),TM(n).lastProp=null,this._doDispatchAxisPointer()}},e.prototype._doDispatchAxisPointer=function(){if(this._handle){var e=this._payloadInfo,t=this._axisModel;this._api.dispatchAction({type:`updateAxisPointer`,x:e.cursorPoint[0],y:e.cursorPoint[1],tooltipOption:e.tooltipOption,axesInfo:[{axisDim:t.axis.dim,axisIndex:t.componentIndex}]})}},e.prototype._onHandleDragEnd=function(){if(this._dragging=!1,this._handle){var e=this._axisPointerModel.get(`value`);this._moveHandleToValue(e),this._api.dispatchAction({type:`hideTip`})}},e.prototype.clear=function(e){this._lastValue=null,this._lastStatus=null;var t=e.getZr(),n=this._group,r=this._handle;t&&n&&(this._lastGraphicKey=null,n&&t.remove(n),r&&t.remove(r),this._group=null,this._handle=null,this._payloadInfo=null),Xy(this,`_doDispatchAxisPointer`)},e.prototype.doClear=function(){},e.prototype.buildLabel=function(e,t,n){return n||=0,{x:e[n],y:e[1-n],width:t[n],height:t[1-n]}},e}();function kM(e,t,n,r){AM(TM(n).lastProp,r)||(TM(n).lastProp=r,t?vp(n,r,e):(n.stopAnimation(),n.attr(r)))}function AM(e,t){if(K(e)&&K(t)){var n=!0;return z(t,function(t,r){n&&=AM(e[r],t)}),!!n}else return e===t}function jM(e,t){e[t.get([`label`,`show`])?`show`:`hide`]()}function MM(e){return{x:e.x||0,y:e.y||0,rotation:e.rotation||0}}function NM(e,t,n){var r=t.get(`z`),i=t.get(`zlevel`);e&&e.traverse(function(e){e.type!==`group`&&(r!=null&&(e.z=r),i!=null&&(e.zlevel=i),e.silent=n)})}function PM(e){var t=e.get(`type`),n=e.getModel(t+`Style`),r;return t===`line`?(r=n.getLineStyle(),r.fill=null):t===`shadow`&&(r=n.getAreaStyle(),r.stroke=null),r}function FM(e,t,n,r,i){var a=LM(n.get(`value`),t.axis,t.ecModel,n.get(`seriesDataIndices`),{precision:n.get([`label`,`precision`]),formatter:n.get([`label`,`formatter`])}),o=n.getModel(`label`),s=Qh(o.get(`padding`)||0),c=o.getFont(),l=Ea(a,c),u=i.position,d=l.width+s[1]+s[3],f=l.height+s[0]+s[2],p=i.align;p===`right`&&(u[0]-=d),p===`center`&&(u[0]-=d/2);var m=i.verticalAlign;m===`bottom`&&(u[1]-=f),m===`middle`&&(u[1]-=f/2),IM(u,d,f,r);var h=o.get(`backgroundColor`);(!h||h===`auto`)&&(h=t.get([`axisLine`,`lineStyle`,`color`])),e.label={x:u[0],y:u[1],style:wm(o,{text:a,font:c,fill:o.getTextColor(),padding:s,backgroundColor:h}),z2:10}}function IM(e,t,n,r){var i=r.getWidth(),a=r.getHeight();e[0]=Math.min(e[0]+t,i)-t,e[1]=Math.min(e[1]+n,a)-n,e[0]=Math.max(e[0],0),e[1]=Math.max(e[1],0)}function LM(e,t,n,r,i){e=t.scale.parse(e);var a=t.scale.getLabel({value:e},{precision:i.precision}),o=i.formatter;if(o){var s={value:kT(t,{value:e}),axisDimension:t.dim,axisIndex:t.index,seriesData:[]};z(r,function(e){var t=n.getSeriesByIndex(e.seriesIndex),r=e.dataIndexInside,i=t&&t.getDataParams(r);i&&s.seriesData.push(i)}),G(o)?a=o.replace(`{value}`,a):W(o)&&(a=o(s))}return a}function RM(e,t,n){var r=tn();return sn(r,r,n.rotation),on(r,r,n.position),Up([e.dataToCoord(t),(n.labelOffset||0)+(n.labelDirection||1)*(n.labelMargin||0)],r)}function zM(e,t,n,r,i,a){var o=tk.innerTextLayout(n.rotation,0,n.labelDirection);n.labelMargin=i.get([`label`,`margin`]),FM(t,r,i,a,{position:RM(r.axis,e,n),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function BM(e,t,n){return n||=0,{x1:e[n],y1:e[1-n],x2:t[n],y2:t[1-n]}}function VM(e,t,n){return n||=0,{x:e[n],y:e[1-n],width:t[n],height:t[1-n]}}function HM(e,t,n){return YE(e,{fromStat:{sers:B(t,function(e){return n.getSeriesByIndex(e.seriesIndex)})},min:1}).w}function UM(e,t,n){return[so(oo(t[0],t[1]),e-n/2),oo(e+n/2,so(t[0],t[1]))]}var WM=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.makeElOption=function(e,t,n,r,i){var a=n.axis,o=a.grid,s=r.get(`type`),c=a.getGlobalExtent(),l=GM(o,a).getOtherAxis(a).getGlobalExtent(),u=a.toGlobalCoord(a.dataToCoord(t,!0));if(s&&s!==`none`){var d=PM(r),f=KM[s](a,u,c,l,r.get(`seriesDataIndices`),r.ecModel);f.style=d,e.graphicKey=f.type,e.pointer=f}zM(t,e,Sk(o.getRect(),n),n,r,i)},t.prototype.getHandleTransform=function(e,t,n){var r=Sk(t.axis.grid.getRect(),t,{labelInside:!1});r.labelMargin=n.get([`handle`,`margin`]);var i=RM(t.axis,e,r);return{x:i[0],y:i[1],rotation:r.rotation+(r.labelDirection<0?Math.PI:0)}},t.prototype.updateHandleTransform=function(e,t,n,r){var i=n.axis,a=i.grid,o=i.getGlobalExtent(!0),s=GM(a,i).getOtherAxis(i).getGlobalExtent(),c=i.dim===`x`?0:1,l=[e.x,e.y];l[c]+=t[c],l[c]=oo(o[1],l[c]),l[c]=so(o[0],l[c]);var u=(s[1]+s[0])/2,d=[u,u];return d[c]=l[c],{x:l[0],y:l[1],rotation:e.rotation,cursorPoint:d,tooltipOption:[{verticalAlign:`middle`},{align:`center`}][c]}},t}(OM);function GM(e,t){var n={};return n[t.dim+`AxisIndex`]=t.index,e.getCartesian(n)}var KM={line:function(e,t,n,r){return{type:`Line`,subPixelOptimize:!0,shape:BM([t,r[0]],[t,r[1]],qM(e))}},shadow:function(e,t,n,r,i,a){var o=HM(e,i,a),s=r[1]-r[0],c=UM(t,n,o),l=c[0],u=c[1];return{type:`Rect`,shape:VM([l,r[0]],[u-l,s],qM(e))}}};function qM(e){return e.dim===`x`?0:1}var JM=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}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:Q.color.border,width:1,type:`dashed`},shadowStyle:{color:Q.color.shadowTint},label:{show:!0,formatter:null,precision:`auto`,margin:3,color:Q.color.neutral00,padding:[5,7,5,7],backgroundColor:Q.color.accent60,borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:`M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z`,size:45,margin:50,color:Q.color.accent40,throttle:40}},t}(Og),YM=Z(),XM=z;function ZM(e,t,n){if(!j.node){var r=t.getZr();YM(r).records||(YM(r).records={}),QM(r,t);var i=YM(r).records[e]||(YM(r).records[e]={});i.handler=n}}function QM(e,t){if(YM(e).initialized)return;YM(e).initialized=!0,n(`click`,H(tN,`click`)),n(`mousemove`,H(tN,`mousemove`)),n(`mousewheel`,H(tN,`mousewheel`)),n(`globalout`,eN);function n(n,r){e.on(n,function(n){var i=nN(t);XM(YM(e).records,function(e){e&&r(e,n,i.dispatchAction)}),$M(i.pendings,t)})}}function $M(e,t){var n=e.showTip.length,r=e.hideTip.length,i;n?i=e.showTip[n-1]:r&&(i=e.hideTip[r-1]),i&&(i.dispatchAction=null,t.dispatchAction(i))}function eN(e,t,n){e.handler(`leave`,null,n)}function tN(e,t,n,r){t.handler(e,n,r)}function nN(e){var t={showTip:[],hideTip:[]},n=function(r){var i=t[r.type];i?i.push(r):(r.dispatchAction=n,e.dispatchAction(r))};return{dispatchAction:n,pendings:t}}function rN(e,t){if(!j.node){var n=t.getZr();(YM(n).records||{})[e]&&(YM(n).records[e]=null)}}var iN=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.render=function(e,t,n){var r=t.getComponent(`tooltip`),i=e.get(`triggerOn`)||r&&r.get(`triggerOn`)||`mousemove|click|mousewheel`;ZM(`axisPointer`,n,function(e,t,n){i!==`none`&&(e===`leave`||i.indexOf(e)>=0)&&n({type:`updateAxisPointer`,currTrigger:e,x:t&&t.offsetX,y:t&&t.offsetY})})},t.prototype.remove=function(e,t){rN(`axisPointer`,t)},t.prototype.dispose=function(e,t){rN(`axisPointer`,t)},t.type=`axisPointer`,t}(Fy);function aN(e,t){var n=[],r=e.seriesIndex,i;if(r==null||!(i=t.getSeriesByIndex(r)))return{point:[]};var a=i.getData(),o=_s(a,e);if(o==null||o<0||U(o))return{point:[]};var s=a.getItemGraphicEl(o),c=i.coordinateSystem;if(i.getTooltipPosition)n=i.getTooltipPosition(o)||[];else if(c&&c.dataToPoint)if(e.isStacked){var l=c.getBaseAxis(),u=c.getOtherAxis(l).dim,d=l.dim,f=+(u===`x`||u===`radius`),p=a.mapDimension(d),m=[];m[f]=a.get(p,o),m[1-f]=a.get(a.getCalculationInfo(`stackResultDimension`),o),n=c.dataToPoint(m)||[]}else n=c.dataToPoint(a.getValues(B(c.dimensions,function(e){return a.mapDimension(e)}),o))||[];else if(s){var h=s.getBoundingRect().clone();h.applyTransform(s.transform),n=[h.x+h.width/2,h.y+h.height/2]}return{point:n,el:s}}var oN=Z();function sN(e,t,n){var r=e.currTrigger,i=[e.x,e.y],a=e,o=e.dispatchAction||V(n.dispatchAction,n),s=t.getComponent(`axisPointer`).coordSysAxesInfo;if(s){_N(i)&&(i=aN({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},t).point);var c=_N(i),l=a.axesInfo,u=s.axesInfo,d=r===`leave`||_N(i),f={},p={},m={list:[],map:{}},h={showPointer:H(uN,p),showTooltip:H(dN,m)};z(s.coordSysMap,function(e,t){var n=c||e.containPoint(i);z(s.coordSysAxesInfo[t],function(e,t){var r=e.axis,a=hN(l,e);if(!d&&n&&(!l||a)){var o=a&&a.value;o==null&&!c&&(o=r.pointToData(i)),o!=null&&cN(e,o,h,!1,f)}})});var g={};return z(u,function(e,t){var n=e.linkGroup;n&&!p[t]&&z(n.axesInfo,function(t,r){var i=p[r];if(t!==e&&i){var a=i.value;n.mapper&&(a=e.axis.scale.parse(n.mapper(a,gN(t),gN(e)))),g[e.key]=a}})}),z(g,function(e,t){cN(u[t],e,h,!0,f)}),fN(p,u,f),pN(m,i,e,o),mN(u,o,n),f}}function cN(e,t,n,r,i){var a=e.axis;if(!(a.scale.isBlank()||!a.containData(t))){if(!e.involveSeries){n.showPointer(e,t);return}var o=lN(t,e),s=o.payloadBatch,c=o.snapToValue;s[0]&&i.seriesIndex==null&&I(i,s[0]),!r&&e.snap&&a.containData(c)&&c!=null&&(t=c),n.showPointer(e,t,s),n.showTooltip(e,o,c)}}function lN(e,t){var n=t.axis,r=n.dim,i=e,a=[],o=Number.MAX_VALUE,s=-1;return z(t.seriesModels,function(t,c){var l=t.getData().mapDimensionsAll(r),u,d;if(t.getAxisTooltipData){var f=t.getAxisTooltipData(l,e,n);d=f.dataIndices,u=f.nestestValue}else{if(d=t.indicesOfNearest(r,l[0],e,n.type===`category`?.5:null),!d.length)return;u=t.getData().get(l[0],d[0])}if(Vo(u)){var p=e-u,m=Math.abs(p);m<=o&&((m<o||p>=0&&s<0)&&(o=m,s=p,i=u,a.length=0),z(d,function(e){a.push({seriesIndex:t.seriesIndex,dataIndexInside:e,dataIndex:t.getData().getRawIndex(e)})}))}}),{payloadBatch:a,snapToValue:i}}function uN(e,t,n,r){e[t.key]={value:n,payloadBatch:r}}function dN(e,t,n,r){var i=n.payloadBatch,a=t.axis,o=a.model,s=t.axisPointerModel;if(!(!t.triggerTooltip||!i.length)){var c=t.coordSys.model,l=SA(c),u=e.map[l];u||(u=e.map[l]={coordSysId:c.id,coordSysIndex:c.componentIndex,coordSysType:c.type,coordSysMainType:c.mainType,dataByAxis:[]},e.list.push(u)),u.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:r,valueLabelOpt:{precision:s.get([`label`,`precision`]),formatter:s.get([`label`,`formatter`])},seriesDataIndices:i.slice()})}}function fN(e,t,n){var r=n.axesInfo=[];z(t,function(t,n){var i=t.axisPointerModel.option,a=e[n];a?(!t.useHandle&&(i.status=`show`),i.value=a.value,i.seriesDataIndices=(a.payloadBatch||[]).slice()):!t.useHandle&&(i.status=`hide`),i.status===`show`&&r.push({axisDim:t.axis.dim,axisIndex:t.axis.model.componentIndex,value:i.value})})}function pN(e,t,n,r){if(_N(t)||!e.list.length){r({type:`hideTip`});return}var i=((e.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};r({type:`showTip`,escapeConnect:!0,x:t[0],y:t[1],tooltipOption:n.tooltipOption,position:n.position,dataIndexInside:i.dataIndexInside,dataIndex:i.dataIndex,seriesIndex:i.seriesIndex,dataByCoordSys:e.list})}function mN(e,t,n){var r=n.getZr(),i=`axisPointerLastHighlights`,a=oN(r)[i]||{},o=oN(r)[i]={};z(e,function(e,t){var n=e.axisPointerModel.option;n.status===`show`&&e.triggerEmphasis&&z(n.seriesDataIndices,function(e){o[e.seriesIndex+`|`+e.dataIndex]=e})});var s=[],c=[];function l(e){return{seriesIndex:e.seriesIndex,dataIndex:e.dataIndex}}z(a,function(e,t){!o[t]&&c.push(l(e))}),z(o,function(e,t){!a[t]&&s.push(l(e))}),c.length&&n.dispatchAction({type:`downplay`,escapeConnect:!0,notBlur:!0,batch:c}),s.length&&n.dispatchAction({type:`highlight`,escapeConnect:!0,notBlur:!0,batch:s})}function hN(e,t){for(var n=0;n<(e||[]).length;n++){var r=e[n];if(t.axis.dim===r.axisDim&&t.axis.model.componentIndex===r.axisIndex)return r}}function gN(e){var t=e.axis.model,n={},r=n.axisDim=e.axis.dim;return n.axisIndex=n[r+`AxisIndex`]=t.componentIndex,n.axisName=n[r+`AxisName`]=t.name,n.axisId=n[r+`AxisId`]=t.id,n}function _N(e){return!e||e[0]==null||isNaN(e[0])||e[1]==null||isNaN(e[1])}function vN(e){wA.registerAxisPointerClass(`CartesianAxisPointer`,WM),e.registerComponentModel(JM),e.registerComponentView(iN),e.registerPreprocessor(function(e){if(e){(!e.axisPointer||e.axisPointer.length===0)&&(e.axisPointer={});var t=e.axisPointer.link;t&&!U(t)&&(e.axisPointer.link=[t])}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,{overallReset:function(e,t){e.getComponent(`axisPointer`).coordSysAxesInfo=fA(e,t)}}),e.registerAction({type:`updateAxisPointer`,event:`updateAxisPointer`,update:`:updateAxisPointer`},sN)}function yN(e){TE(FA),TE(vN)}var bN=[`x`,`y`,`radius`,`angle`,`single`],xN=Z(),SN=[`cartesian2d`,`polar`,`singleAxis`];function CN(e){return R(SN,e.get(`coordinateSystem`))>=0}function wN(e){return e+`Axis`}function TN(e,t){var n=J(),r=[],i=J();e.eachComponent({mainType:`dataZoom`,query:t},function(e){i.get(e.uid)||s(e)});var a;do a=!1,e.eachComponent(`dataZoom`,o);while(a);function o(e){!i.get(e.uid)&&c(e)&&(s(e),a=!0)}function s(e){i.set(e.uid,!0),r.push(e),l(e)}function c(e){var t=!1;return e.eachTargetAxis(function(e,r){var i=n.get(e);i&&i[r]&&(t=!0)}),t}function l(e){e.eachTargetAxis(function(e,t){(n.get(e)||n.set(e,[]))[t]=!0})}return r}function EN(e){var t=e.ecModel,n={infoList:[],infoMap:J()};return e.eachTargetAxis(function(e,r){var i=t.getComponent(wN(e),r);if(i){var a=i.getCoordSysModel();if(a){var o=a.uid,s=n.infoMap.get(o);s||(s={model:a,axisModels:[]},n.infoList.push(s),n.infoMap.set(o,s)),s.axisModels.push(i)}}}),n}function DN(e){var t=xN(Kb(e));return t.axisProxyMap||=J()}function ON(e){if(e)return DN(e.ecModel).get(e.uid)}function kN(e,t){DN(e.ecModel).set(e.uid,t)}function AN(e,t){var n=t.getAxisModel().axis.__alignTo;return n&&e.getAxisProxy(n.dim,n.model.componentIndex)?ON(n.model):null}var jN=function(){function e(){this.indexList=[],this.indexMap=[]}return e.prototype.add=function(e){this.indexMap[e]||(this.indexList.push(e),this.indexMap[e]=!0)},e}(),MN=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n._autoThrottle=!0,n._noTarget=!0,n._rangePropMode=[`percent`,`percent`],n}return t.prototype.init=function(e,t,n){var r=NN(e);this.settledOption=r,this.mergeDefaultAndTheme(e,n),this._doInit(r)},t.prototype.mergeOption=function(e){var t=NN(e);F(this.option,e,!0),F(this.settledOption,t,!0),this._doInit(t)},t.prototype._doInit=function(e){var t=this.option;this._setDefaultThrottle(e),this._updateRangeUse(e);var n=this.settledOption;z([[`start`,`startValue`],[`end`,`endValue`]],function(e,r){this._rangePropMode[r]===`value`&&(t[e[0]]=n[e[0]]=null)},this),this._resetTarget()},t.prototype._resetTarget=function(){var e=this.get(`orient`,!0),t=this._targetAxisInfoMap=J();this._fillSpecifiedTargetAxis(t)?this._orient=e||this._makeAutoOrientByTargetAxis():(this._orient=e||`horizontal`,this._fillAutoTargetAxisByOrient(t,this._orient)),this._noTarget=!0,t.each(function(e){e.indexList.length&&(this._noTarget=!1)},this)},t.prototype._fillSpecifiedTargetAxis=function(e){var t=!1;return z(bN,function(n){var r=this.getReferringComponents(wN(n),Ss);if(r.specified){t=!0;var i=new jN;z(r.models,function(e){i.add(e.componentIndex)}),e.set(n,i)}},this),t},t.prototype._fillAutoTargetAxisByOrient=function(e,t){var n=this.ecModel,r=!0;if(r){var i=t===`vertical`?`y`:`x`,a=n.findComponents({mainType:i+`Axis`});o(a,i)}if(r){var a=n.findComponents({mainType:`singleAxis`,filter:function(e){return e.get(`orient`,!0)===t}});o(a,`single`)}function o(t,n){var i=t[0];if(i){var a=new jN;if(a.add(i.componentIndex),e.set(n,a),r=!1,n===`x`||n===`y`){var o=i.getReferringComponents(`grid`,xs).models[0];o&&z(t,function(e){i.componentIndex!==e.componentIndex&&o===e.getReferringComponents(`grid`,xs).models[0]&&a.add(e.componentIndex)})}}}r&&z(bN,function(t){if(r){var i=n.findComponents({mainType:wN(t),filter:function(e){return e.get(`type`,!0)===`category`}});if(i[0]){var a=new jN;a.add(i[0].componentIndex),e.set(t,a),r=!1}}},this)},t.prototype._makeAutoOrientByTargetAxis=function(){var e;return this.eachTargetAxis(function(t){!e&&(e=t)},this),e===`y`?`vertical`:`horizontal`},t.prototype._setDefaultThrottle=function(e){if(e.hasOwnProperty(`throttle`)&&(this._autoThrottle=!1),this._autoThrottle){var t=this.ecModel.option;this.option.throttle=t.animation&&t.animationDurationUpdate>0?100:20}},t.prototype._updateRangeUse=function(e){var t=this._rangePropMode,n=this.get(`rangeMode`);z([[`start`,`startValue`],[`end`,`endValue`]],function(r,i){var a=e[r[0]]!=null,o=e[r[1]]!=null;a&&!o?t[i]=`percent`:!a&&o?t[i]=`value`:n?t[i]=n[i]:a&&(t[i]=`percent`)})},t.prototype.noTarget=function(){return this._noTarget},t.prototype.getFirstTargetAxisModel=function(){var e;return this.eachTargetAxis(function(t,n){e??=this.ecModel.getComponent(wN(t),n)},this),e},t.prototype.eachTargetAxis=function(e,t){this._targetAxisInfoMap.each(function(n,r){z(n.indexList,function(n){e.call(t,r,n)})})},t.prototype.getAxisProxy=function(e,t){return ON(this.getAxisModel(e,t))},t.prototype.getAxisModel=function(e,t){var n=this._targetAxisInfoMap.get(e);if(n&&n.indexMap[t])return this.ecModel.getComponent(wN(e),t)},t.prototype.setRawRange=function(e){var t=this.option,n=this.settledOption;z([[`start`,`startValue`],[`end`,`endValue`]],function(r){(e[r[0]]!=null||e[r[1]]!=null)&&(t[r[0]]=n[r[0]]=e[r[0]],t[r[1]]=n[r[1]]=e[r[1]])},this),this._updateRangeUse(e)},t.prototype.setCalculatedRange=function(e){var t=this.option;z([`start`,`startValue`,`end`,`endValue`],function(n){t[n]=e[n]})},t.prototype.getPercentRange=function(){var e=this.findRepresentativeAxisProxy();if(e)return e.getWindow().percent},t.prototype.getValueRange=function(e,t){if(e==null&&t==null){var n=this.findRepresentativeAxisProxy();if(n)return n.getWindow().value}else return this.getAxisProxy(e,t).getWindow().value},t.prototype.findRepresentativeAxisProxy=function(e){if(e)return ON(e);for(var t,n=this._targetAxisInfoMap.keys(),r=0;r<n.length;r++)for(var i=n[r],a=this._targetAxisInfoMap.get(i),o=0;o<a.indexList.length;o++){var s=this.getAxisProxy(i,a.indexList[o]);if(s.hostedBy(this))return s;t||=s}return t},t.prototype.getRangePropMode=function(){return this._rangePropMode.slice()},t.prototype.getOrient=function(){return this._orient},t.type=`dataZoom`,t.dependencies=[`xAxis`,`yAxis`,`radiusAxis`,`angleAxis`,`singleAxis`,`series`,`toolbox`],t.defaultOption={z:4,filterMode:`filter`,start:0,end:100},t}(Og);function NN(e){var t={};return z([`start`,`end`,`startValue`,`endValue`,`throttle`],function(n){e.hasOwnProperty(n)&&(t[n]=e[n])}),t}var PN=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.type=`dataZoom.select`,t}(MN),FN=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.render=function(e,t,n,r){this.dataZoomModel=e,this.ecModel=t,this.api=n},t.type=`dataZoom`,t}(Fy),IN=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.type=`dataZoom.select`,t}(FN),LN=function(){function e(e,t,n,r){this._dimName=e,this._axisIndex=t,this.ecModel=r,this._dataZoomModel=n}return e.prototype.hostedBy=function(e){return this._dataZoomModel===e},e.prototype.getWindow=function(){return P(this._window)},e.prototype.getTargetSeriesModels=function(){var e=[];return this.ecModel.eachSeries(function(t){if(CN(t)){var n=wN(this._dimName),r=t.getReferringComponents(n,xs).models[0];r&&this._axisIndex===r.componentIndex&&e.push(t)}},this),e},e.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+`Axis`,this._axisIndex)},e.prototype.getMinMaxSpan=function(){return P(this._minMaxSpan)},e.prototype.calculateDataWindow=function(e){var t=this._extent,n=this.getAxisModel().axis,r=n.scale,i=this._dataZoomModel.getRangePropMode(),a=[0,100],o=[],s=[],c,l=[!1,!1];z([`start`,`end`],function(n,u){var d=e[n],f=e[n+`Value`];i[u]===`percent`?(d??=a[u],f=vo(d,a,t),l[u]=!0):(c=!0,f==null?f=t[u]:(f=r.parse(f),r.sanitize&&(f=r.sanitize(f,t))),d=vo(f,t,a)),s[u]=f==null||isNaN(f)?t[u]:f,o[u]=d==null||isNaN(d)?a[u]:d}),Co(s),Co(o);var u=this._minMaxSpan;c?d(s,o,t,a,!1):d(o,s,a,t,!0);function d(e,t,n,r,i){var a=i?`Span`:`ValueSpan`;Cj(0,e,n,`all`,u[`min`+a],u[`max`+a]);for(var o=0;o<2;o++)t[o]=vo(e[o],n,r,!0),i&&(t[o]=t[o],l[o]=!0);Ls(t)}var f=Uw(r)||Vw(r),p=n.getExtent(),m=co(p[1]-p[0]),h=f?0:Eo(s,m,.5);z([[0,fo],[1,uo]],function(e){var n=e[0],r=e[1];!l[n]||!isFinite(h)||(s[n]=X(s[n],h),s[n]=oo(t[1],so(t[0],s[n])),o[n]===a[n]&&(s[n]=t[n],f&&(s[n]=r(s[n]))))}),Ls(s);var g=[vo(s[0],t,a,!0),vo(s[1],t,a,!0)];return Ls(g),{value:s,percent:o,percentInverted:g,valuePrecision:h}},e.prototype.reset=function(e,t){if(this.hostedBy(e)){var n=this.getAxisModel().axis;cE(n,2);var r=n.scale.rawExtentInfo;this._extent=r.makeNoZoom(),this._updateMinMaxSpan();var i=e.settledOption;t&&(i=L({start:t[0],end:t[1]},i));var a=this._window=this.calculateDataWindow(i),o=a.percent,s=a.value;o[0]!==0&&r.setZoomMM(0,s[0]),o[1]!==100&&r.setZoomMM(1,s[1])}},e.prototype.filterData=function(e,t){if(!this.hostedBy(e))return;var n=this._dimName,r=this.getTargetSeriesModels(),i=e.get(`filterMode`),a=this._window.value;if(i===`none`)return;z(r,function(e){var t=e.getData(),r=t.mapDimensionsAll(n);if(r.length){if(i===`weakFilter`){var s=t.getStore(),c=B(r,function(e){return t.getDimensionIndex(e)},t);t.filterSelf(function(e){for(var t,n,i,o=0;o<r.length;o++){var l=s.get(c[o],e),u=!isNaN(l),d=l<a[0],f=l>a[1];if(u&&!d&&!f)return!0;u&&(i=!0),d&&(t=!0),f&&(n=!0)}return i&&t&&n})}else z(r,function(n){if(i===`empty`)e.setData(t=t.map(n,function(e){return o(e)?e:NaN}));else{var r={};r[n]=a,t.selectRange(r)}});z(r,function(e){t.setApproximateExtent(a,e)})}});function o(e){return e>=a[0]&&e<=a[1]}},e.prototype._updateMinMaxSpan=function(){var e=this._minMaxSpan={},t=this._dataZoomModel,n=this._extent;z([`min`,`max`],function(r){var i=t.get(r+`Span`),a=t.get(r+`ValueSpan`);a!=null&&(a=this.getAxisModel().axis.scale.parse(a)),a==null?i!=null&&(a=vo(i,[0,100],n,!0)-n[0]):i=vo(n[0]+a,n,[0,100],!0),e[r+`Span`]=i,e[r+`ValueSpan`]=a},this)},e}(),RN={dirtyOnOverallProgress:!0,getTargetSeries:function(e){function t(t){e.eachComponent(`dataZoom`,function(n){n.eachTargetAxis(function(r,i){t(r,i,e.getComponent(wN(r),i),n)})})}var n=[];t(function(t,r,i,a){if(!ON(i)){var o=new LN(t,r,a,e);n.push(o),kN(i,o)}});var r=J();return z(n,function(e){z(e.getTargetSeriesModels(),function(e){r.set(e.uid,e)})}),r},overallReset:function(e,t){e.eachComponent(`dataZoom`,function(e){var n=[];e.eachTargetAxis(function(t,r){var i=e.getAxisProxy(t,r),a=AN(e,i);a?n.push([i,a]):i.reset(e,null)}),z(n,function(t){t[0].reset(e,t[1].getWindow().percentInverted)}),e.eachTargetAxis(function(n,r){e.getAxisProxy(n,r).filterData(e,t)})}),e.eachComponent(`dataZoom`,function(e){var t=e.findRepresentativeAxisProxy();if(t){var n=t.getWindow(),r=n.percent,i=n.value;e.setCalculatedRange({start:r[0],end:r[1],startValue:i[0],endValue:i[1]})}})}};function zN(e){e.registerAction(`dataZoom`,function(e,t){z(TN(t,e),function(t){t.setRawRange({start:e.start,end:e.end,startValue:e.startValue,endValue:e.endValue})})})}var BN=Rs();function VN(e){BN(e,function(){e.registerProcessor(e.PRIORITY.PROCESSOR.FILTER,RN),zN(e),e.registerSubTypeDefaulter(`dataZoom`,function(){return`slider`})})}function HN(e){e.registerComponentModel(PN),e.registerComponentView(IN),VN(e)}var UN=function(){function e(){}return e}(),WN={};function GN(e,t){WN[e]=t}function KN(e){return WN[e]}var qN=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.init=function(t,n,r){var i=r.getTheme().get(`toolbox`),a=i?i.feature:null;a&&(this._themeFeatureOption=I({},a),i.feature={}),e.prototype.init.call(this,t,n,r),a&&(i.feature=a)},t.prototype.optionUpdated=function(){z(this.option.feature,function(e,t){var n=this._themeFeatureOption,r=KN(t);r&&(r.getDefaultOption&&(r.defaultOption=r.getDefaultOption(this.ecModel)),n&&n[t]&&(F(e,n[t]),n[t]=null),F(e,r.defaultOption))},this)},t.type=`toolbox`,t.layoutMode={type:`box`,ignoreSize:!0},t.defaultOption={show:!0,z:6,orient:`horizontal`,left:`right`,top:`top`,backgroundColor:`transparent`,borderColor:Q.color.border,borderRadius:0,borderWidth:0,padding:Q.size.m,itemSize:15,itemGap:Q.size.s,showTitle:!0,iconStyle:{borderColor:Q.color.accent50,color:`none`},emphasis:{iconStyle:{borderColor:Q.color.accent70}},tooltip:{show:!1,position:`bottom`}},t}(Og);function JN(e,t){var n=Qh(t.get(`padding`)),r=t.getItemStyle([`color`,`opacity`]);return r.fill=t.get(`backgroundColor`),new cu({shape:{x:e.x-n[3],y:e.y-n[0],width:e.width+n[1]+n[3],height:e.height+n[0]+n[2],r:t.get(`borderRadius`)},style:r,silent:!0,z2:-1})}var YN=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.render=function(e,t,n,r){var i=this.group;if(i.removeAll(),!e.get(`show`))return;var a=+e.get(`itemSize`),o=e.get(`orient`)===`vertical`,s=e.get(`feature`)||{},c=this._features||=J(),l=[];z(s,function(e,t){l.push(t)}),new NC(this._featureNames||[],l).add(u).update(u).remove(H(u,null)).execute(),this._featureNames=Ee(l,function(e){return c.hasKey(e)});function u(i,a){var o=i!=null&&a==null,u=i!=null&&a!=null,f=i==null,p=o||u?l[i]:l[a],m=s[p],h=o||u?new Gm(m,e,t):null,g=h&&h.get(`show`),_;if(o){if(!g)return;if(XN(p))_={onclick:h.option.onclick,featureName:p};else{var v=KN(p);if(!v)return;_=new v}c.set(p,_)}else _=c.get(p);if(f||!g){ZN(_)&&_.dispose&&_.dispose(t,n),c.removeKey(p);return}r&&r.newTitle!=null&&r.featureName===p&&(m.title=r.newTitle),o&&(_.uid=qm(`toolbox-feature`)),_.model=h,_.ecModel=t,_.api=n,d(h,_,p),h.setIconStatus=function(e,t){var n=this.option,r=this.iconPaths;n.iconStatus=n.iconStatus||{},n.iconStatus[e]=t,r[e]&&(t===`emphasis`?_d:vd)(r[e])},ZN(_)&&_.render&&_.render(h,t,n,r)}function d(r,s,c){var l=r.getModel(`iconStyle`),u=r.getModel([`emphasis`,`iconStyle`]),d=s instanceof UN&&s.getIcons?s.getIcons():r.get(`icon`),f=r.get(`title`)||{},p,m;G(d)?(p={},p[c]=d):p=d,G(f)?(m={},m[c]=f):m=f;var h=r.iconPaths={};z(p,function(c,d){var f=Xp(c,{},{x:-a/2,y:-a/2,width:a,height:a});f.setStyle(l.getItemStyle());var p=f.ensureState(`emphasis`);p.style=u.getItemStyle();var g=new pu({style:{text:m[d],align:u.get(`textAlign`),borderRadius:u.get(`textBorderRadius`),padding:u.get(`textPadding`),fill:null,font:Mm({fontStyle:u.get(`textFontStyle`),fontFamily:u.get(`textFontFamily`),fontSize:u.get(`textFontSize`),fontWeight:u.get(`textFontWeight`)},t)},ignore:!0});f.setTextContent(g),im({el:f,componentModel:e,itemName:d,formatterParamsExtra:{title:m[d]}}),f.__title=m[d],f.on(`mouseover`,function(){var t=u.getItemStyle(),r=o?e.get(`right`)==null&&e.get(`left`)!==`right`?`right`:`left`:e.get(`bottom`)==null&&e.get(`top`)!==`bottom`?`bottom`:`top`;g.setStyle({fill:u.get(`textFill`)||t.fill||t.stroke||Q.color.neutral99,backgroundColor:u.get(`textBackgroundColor`)}),f.setTextConfig({position:u.get(`textPosition`)||r}),g.ignore=!e.get(`showTitle`),n.enterEmphasis(this)}).on(`mouseout`,function(){r.get([`iconStatus`,d])!==`emphasis`&&n.leaveEmphasis(this),g.hide()}),(r.get([`iconStatus`,d])===`emphasis`?_d:vd)(f),i.add(f),f.on(`click`,V(s.onclick,s,t,n,d)),h[d]=f})}var f=xg(e,n).refContainer,p=e.getBoxLayoutParams(),m=e.get(`padding`),h=yg(p,f,m);_g(e.get(`orient`),i,e.get(`itemGap`),h.width,h.height),Sg(i,p,f,m),i.add(JN(i.getBoundingRect(),e)),o||i.eachChild(function(e){var t=e.__title,r=e.ensureState(`emphasis`),o=r.textConfig||={},s=e.getTextContent(),c=s&&s.ensureState(`emphasis`);if(c&&!W(c)&&t){var l=c.style||={},u=Ea(t,pu.makeFont(l)),d=e.x+i.x,f=e.y+i.y+a,p=!1;f+u.height>n.getHeight()&&(o.position=`top`,p=!0);var m=p?-5-u.height:a+10;d+u.width/2>n.getWidth()?(o.position=[`100%`,m],l.align=`right`):d-u.width/2<0&&(o.position=[0,m],l.align=`left`)}})},t.prototype.updateView=function(e,t,n,r){z(this._features,function(e){e&&e instanceof UN&&e.updateView&&e.updateView(e.model,t,n,r)})},t.prototype.dispose=function(e,t){z(this._features,function(n){n&&n instanceof UN&&n.dispose&&n.dispose(e,t)})},t.type=`toolbox`,t}(Fy);function XN(e){return e.indexOf(`my`)===0}function ZN(e){return e instanceof UN}var QN=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.onclick=function(e,t){var n=this.model,r=n.get(`name`)||e.get(`title.0.text`)||`echarts`,i=t.getZr().painter.getType()===`svg`,a=i?`svg`:n.get(`type`,!0)||`png`,o=t.getConnectedDataURL({type:a,backgroundColor:n.get(`backgroundColor`,!0)||e.get(`backgroundColor`)||Q.color.neutral00,connectedBackgroundColor:n.get(`connectedBackgroundColor`),excludeComponents:n.get(`excludeComponents`),pixelRatio:n.get(`pixelRatio`)}),s=j.browser;if(typeof MouseEvent==`function`&&(s.newEdge||!s.ie&&!s.edge)){var c=document.createElement(`a`);c.download=r+`.`+a,c.target=`_blank`,c.href=o;var l=new MouseEvent(`click`,{view:document.defaultView,bubbles:!0,cancelable:!1});c.dispatchEvent(l)}else if(window.navigator.msSaveOrOpenBlob||i){var u=o.split(`,`),d=u[0].indexOf(`base64`)>-1,f=i?decodeURIComponent(u[1]):u[1];d&&(f=window.atob(f));var p=r+`.`+a;if(window.navigator.msSaveOrOpenBlob){for(var m=f.length,h=new Uint8Array(m);m--;)h[m]=f.charCodeAt(m);var g=new Blob([h]);window.navigator.msSaveOrOpenBlob(g,p)}else{var _=document.createElement(`iframe`);document.body.appendChild(_);var v=_.contentWindow,y=v.document;y.open(`image/svg+xml`,`replace`),y.write(f),y.close(),v.focus(),y.execCommand(`SaveAs`,!0,p),document.body.removeChild(_)}}else{var b=n.get(`lang`),x=`<body style="margin:0;"><img src="`+o+`" style="max-width:100%;" title="`+(b&&b[0]||``)+`" /></body>`,S=window.open();S.document.write(x),S.document.title=r}},t.getDefaultOption=function(e){return{show:!0,icon:`M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0`,title:e.getLocaleModel().get([`toolbox`,`saveAsImage`,`title`]),type:`png`,connectedBackgroundColor:Q.color.neutral00,name:``,excludeComponents:[`toolbox`],lang:e.getLocaleModel().get([`toolbox`,`saveAsImage`,`lang`])}},t}(UN),$N=`__ec_magicType_stack__`,eP=[[`line`,`bar`],[`stack`]],tP=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.getIcons=function(){var e=this.model,t=e.get(`icon`),n={};return z(e.get(`type`),function(e){t[e]&&(n[e]=t[e])}),n},t.getDefaultOption=function(e){return{show:!0,type:[],icon:{line:`M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4`,bar:`M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7`,stack:`M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z`},title:e.getLocaleModel().get([`toolbox`,`magicType`,`title`]),option:{},seriesIndex:{}}},t.prototype.onclick=function(e,t,n){var r=this.model,i=r.get([`seriesIndex`,n]);if(nP[n]){var a={series:[]};z(eP,function(e){R(e,n)>=0&&z(e,function(e){r.setIconStatus(e,`normal`)})}),r.setIconStatus(n,`emphasis`),e.eachComponent({mainType:`series`,query:i==null?null:{seriesIndex:i}},function(e){var t=e.subType,i=e.id,o=nP[n](t,i,e,r);o&&(L(o,e.option),a.series.push(o));var s=e.coordinateSystem;if(s&&s.type===`cartesian2d`&&(n===`line`||n===`bar`)){var c=s.getAxesByScale(`ordinal`)[0];if(c){var l=c.dim+`Axis`,u=e.getReferringComponents(l,xs).models[0].componentIndex;a[l]=a[l]||[];for(var d=0;d<=u;d++)a[l][u]=a[l][u]||{};a[l][u].boundaryGap=n===`bar`}}});var o,s=n;n===`stack`&&(o=F({stack:r.option.title.tiled,tiled:r.option.title.stack},r.option.title),r.get([`iconStatus`,n])!==`emphasis`&&(s=`tiled`)),t.dispatchAction({type:`changeMagicType`,currentType:s,newOption:a,newTitle:o,featureName:`magicType`})}},t}(UN),nP={line:function(e,t,n,r){if(e===`bar`)return F({id:t,type:`line`,data:n.get(`data`),stack:n.get(`stack`),markPoint:n.get(`markPoint`),markLine:n.get(`markLine`)},r.get([`option`,`line`])||{},!0)},bar:function(e,t,n,r){if(e===`line`)return F({id:t,type:`bar`,data:n.get(`data`),stack:n.get(`stack`),markPoint:n.get(`markPoint`),markLine:n.get(`markLine`)},r.get([`option`,`bar`])||{},!0)},stack:function(e,t,n,r){var i=n.get(`stack`)===$N;if(e===`line`||e===`bar`)return r.setIconStatus(`stack`,i?`normal`:`emphasis`),F({id:t,stack:i?``:$N},r.get([`option`,`stack`])||{},!0)}};xC({type:`changeMagicType`,event:`magicTypeChanged`,update:`prepareAndUpdate`},function(e,t){t.mergeOption(e.newOption)});var rP=Array(60).join(`-`),iP=` `;function aP(e){var t={},n=[],r=[];return e.eachRawSeries(function(e){var i=e.coordinateSystem;if(i&&(i.type===`cartesian2d`||i.type===`polar`)){var a=i.getBaseAxis();if(a.type===`category`){var o=Ek(a);t[o]||(t[o]={categoryAxis:a,valueAxis:i.getOtherAxis(a),series:[]},r.push({axisDim:a.dim,axisIndex:a.index})),t[o].series.push(e)}else n.push(e)}else n.push(e)}),{seriesGroupByCategoryAxis:t,other:n,meta:r}}function oP(e){var t=[];return z(e,function(e,n){var r=e.categoryAxis,i=e.valueAxis.dim,a=[` `].concat(B(e.series,function(e){return e.name})),o=[r.model.getCategories()];z(e.series,function(e){var t=e.getRawData();o.push(e.getRawData().mapArray(t.mapDimension(i),function(e){return e}))});for(var s=[a.join(iP)],c=0;c<o[0].length;c++){for(var l=[],u=0;u<o.length;u++)l.push(o[u][c]);s.push(l.join(iP))}t.push(s.join(`
`))}),t.join(`
`+rP+`
`)}function sP(e){return B(e,function(e){var t=e.getRawData(),n=[e.name],r=[];return t.each(t.dimensions,function(){for(var e=arguments.length,i=arguments[e-1],a=t.getName(i),o=0;o<e-1;o++)r[o]=arguments[o];n.push((a?a+iP:``)+r.join(iP))}),n.join(`
`)}).join(`
`+rP+`
`)}function cP(e){var t=aP(e);return{value:Ee([oP(t.seriesGroupByCategoryAxis),sP(t.other)],function(e){return!!e.replace(/[\n\t\s]/g,``)}).join(`
`+rP+`
`),meta:t.meta}}function lP(e){return e.replace(/^\s\s*/,``).replace(/\s\s*$/,``)}function uP(e){if(e.slice(0,e.indexOf(`
`)).indexOf(iP)>=0)return!0}var dP=RegExp(`[`+iP+`]+`,`g`);function fP(e){for(var t=e.split(/\n+/g),n=lP(t.shift()).split(dP),r=[],i=B(n,function(e){return{name:e,data:[]}}),a=0;a<t.length;a++){var o=lP(t[a]).split(dP);r.push(o.shift());for(var s=0;s<o.length;s++)i[s]&&(i[s].data[a]=o[s])}return{series:i,categories:r}}function pP(e){for(var t=e.split(/\n+/g),n=lP(t.shift()),r=[],i=0;i<t.length;i++){var a=lP(t[i]);if(a){var o=a.split(dP),s=``,c=void 0,l=!1;isNaN(o[0])?(l=!0,s=o[0],o=o.slice(1),r[i]={name:s,value:[]},c=r[i].value):c=r[i]=[];for(var u=0;u<o.length;u++)c.push(+o[u]);c.length===1&&(l?r[i].value=c[0]:r[i]=c[0])}}return{name:n,data:r}}function mP(e,t){var n=e.split(RegExp(`
*`+rP+`
*`,`g`)),r={series:[]};return z(n,function(e,n){if(uP(e)){var i=fP(e),a=t[n],o=a.axisDim+`Axis`;a&&(r[o]=r[o]||[],r[o][a.axisIndex]={data:i.categories},r.series=r.series.concat(i.series))}else{var i=pP(e);r.series.push(i)}}),r}var hP=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.onclick=function(e,t){setTimeout(function(){t.dispatchAction({type:`hideTip`})});var n=t.getDom(),r=this.model;this._dom&&n.removeChild(this._dom);var i=document.createElement(`div`);i.style.cssText=`position:absolute;top:0;bottom:0;left:0;right:0;padding:5px`,i.style.backgroundColor=r.get(`backgroundColor`)||Q.color.neutral00;var a=document.createElement(`h4`),o=r.get(`lang`)||[];a.innerHTML=o[0]||r.get(`title`),a.style.cssText=`margin:10px 20px`,a.style.color=r.get(`textColor`);var s=document.createElement(`div`),c=document.createElement(`textarea`);s.style.cssText=`overflow:auto`;var l=r.get(`optionToContent`),u=r.get(`contentToOption`),d=cP(e);if(W(l)){var f=l(t.getOption());G(f)?s.innerHTML=f:Pe(f)&&s.appendChild(f)}else{c.readOnly=r.get(`readOnly`);var p=c.style;p.cssText=`display:block;width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;resize:none;box-sizing:border-box;outline:none`,p.color=r.get(`textColor`),p.borderColor=r.get(`textareaBorderColor`),p.backgroundColor=r.get(`textareaColor`),c.value=d.value,s.appendChild(c)}var m=d.meta,h=document.createElement(`div`);h.style.cssText=`position:absolute;bottom:5px;left:0;right:0`;var g=`float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px`,_=document.createElement(`div`),v=document.createElement(`div`);g+=`;background-color:`+r.get(`buttonColor`),g+=`;color:`+r.get(`buttonTextColor`);var y=this;function b(){n.removeChild(i),y._dom=null}qt(_,`click`,b),qt(v,`click`,function(){if(u==null&&l!=null||u!=null&&l==null){b();return}var e;try{e=W(u)?u(s,t.getOption()):mP(c.value,m)}catch(e){throw b(),Error(`Data view format error `+e)}e&&t.dispatchAction({type:`changeDataView`,newOption:e}),b()}),_.innerHTML=o[1],v.innerHTML=o[2],v.style.cssText=_.style.cssText=g,!r.get(`readOnly`)&&h.appendChild(v),h.appendChild(_),i.appendChild(a),i.appendChild(s),i.appendChild(h),s.style.height=n.clientHeight-80+`px`,n.appendChild(i),this._dom=i},t.prototype.dispose=function(e,t){this._dom&&t.getDom().removeChild(this._dom)},t.getDefaultOption=function(e){return{show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:`M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28`,title:e.getLocaleModel().get([`toolbox`,`dataView`,`title`]),lang:e.getLocaleModel().get([`toolbox`,`dataView`,`lang`]),backgroundColor:Q.color.background,textColor:Q.color.primary,textareaColor:Q.color.background,textareaBorderColor:Q.color.border,buttonColor:Q.color.accent50,buttonTextColor:Q.color.neutral00}},t}(UN);function gP(e,t){return B(e,function(e,n){var r=t&&t[n];if(K(r)&&!U(r)){K(e)&&!U(e)||(e={value:e});var i=r.name!=null&&e.name==null;return e=L(e,r),i&&delete e.name,e}else return e})}xC({type:`changeDataView`,event:`dataViewChanged`,update:`prepareAndUpdate`},function(e,t){var n=[];z(e.newOption.series,function(e){var r=t.getSeriesByName(e.name)[0];if(!r)n.push(I({type:`scatter`},e));else{var i=r.get(`data`);n.push({name:e.name,data:gP(e.data,i)})}}),t.mergeOption(L({series:n},e.newOption))});var _P=z,vP=Z();function yP(e,t){var n=CP(e);_P(t,function(t,r){for(var i=n.length-1;i>=0&&!n[i][r];i--);if(i<0){var a=e.queryComponents({mainType:`dataZoom`,subType:`select`,id:r})[0];if(a){var o=a.getPercentRange();n[0][r]={dataZoomId:r,start:o[0],end:o[1]}}}}),n.push(t)}function bP(e){var t=CP(e),n=t[t.length-1];t.length>1&&t.pop();var r={};return _P(n,function(e,n){for(var i=t.length-1;i>=0;i--)if(e=t[i][n],e){r[n]=e;break}}),r}function xP(e){vP(e).snapshots=null}function SP(e){return CP(e).length}function CP(e){var t=vP(e);return t.snapshots||=[{}],t.snapshots}var wP=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.onclick=function(e,t){xP(e),t.dispatchAction({type:`restore`,from:this.uid})},t.getDefaultOption=function(e){return{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`])}},t}(UN);xC({type:`restore`,event:`restore`,update:`prepareAndUpdate`},function(e,t){t.resetOption(`recreate`)});var TP=[`grid`,`xAxis`,`yAxis`,`geo`,`graph`,`polar`,`radiusAxis`,`angleAxis`,`bmap`],EP=function(){function e(e,t,n){var r=this;this._targetInfoList=[];var i=OP(t,e);z(kP,function(e,t){(!n||!n.include||R(n.include,t)>=0)&&e(i,r._targetInfoList)})}return e.prototype.setOutputRanges=function(e,t){return this.matchOutputRanges(e,t,function(e,t,n){if((e.coordRanges||=[]).push(t),!e.coordRange){e.coordRange=t;var r=MP[e.brushType](0,n,t);e.__rangeOffset={offset:PP[e.brushType](r.values,e.range,[1,1]),xyMinMax:r.xyMinMax}}}),e},e.prototype.matchOutputRanges=function(e,t,n){z(e,function(e){var r=this.findTargetInfo(e,t);r&&r!==!0&&z(r.coordSyses,function(r){n(e,MP[e.brushType](1,r,e.range,!0).values,r,t)})},this)},e.prototype.setInputRanges=function(e,t){z(e,function(e){var n=this.findTargetInfo(e,t);if(e.range=e.range||[],n&&n!==!0){e.panelId=n.panelId;var r=MP[e.brushType](0,n.coordSys,e.coordRange),i=e.__rangeOffset;e.range=i?PP[e.brushType](r.values,i.offset,IP(r.xyMinMax,i.xyMinMax)):r.values}},this)},e.prototype.makePanelOpts=function(e,t){return B(this._targetInfoList,function(n){var r=n.getPanelRect();return{panelId:n.panelId,defaultBrushType:t?t(n):null,clipPath:xM(r),isTargetByCursor:CM(r,e,n.coordSysModel),getLinearBrushOtherExtent:SM(r)}})},e.prototype.controlSeries=function(e,t,n){var r=this.findTargetInfo(e,n);return r===!0||r&&R(r.coordSyses,t.coordinateSystem)>=0},e.prototype.findTargetInfo=function(e,t){for(var n=this._targetInfoList,r=OP(t,e),i=0;i<n.length;i++){var a=n[i],o=e.panelId;if(o){if(a.panelId===o)return a}else for(var s=0;s<AP.length;s++)if(AP[s](r,a))return a}return!0},e}();function DP(e){return e[0]>e[1]&&e.reverse(),e}function OP(e,t){return ys(e,t,{includeMainTypes:TP})}var kP={grid:function(e,t){var n=e.xAxisModels,r=e.yAxisModels,i=e.gridModels,a=J(),o={},s={};!n&&!r&&!i||(z(n,function(e){var t=e.axis.grid.model;a.set(t.id,t),o[t.id]=!0}),z(r,function(e){var t=e.axis.grid.model;a.set(t.id,t),s[t.id]=!0}),z(i,function(e){a.set(e.id,e),o[e.id]=!0,s[e.id]=!0}),a.each(function(e){var i=e.coordinateSystem,a=[];z(i.getCartesians(),function(e,t){(R(n,e.getAxis(`x`).model)>=0||R(r,e.getAxis(`y`).model)>=0)&&a.push(e)}),t.push({panelId:`grid--`+e.id,gridModel:e,coordSysModel:e,coordSys:a[0],coordSyses:a,getPanelRect:jP.grid,xAxisDeclared:o[e.id],yAxisDeclared:s[e.id]})}))},geo:function(e,t){z(e.geoModels,function(e){var n=e.coordinateSystem;t.push({panelId:`geo--`+e.id,geoModel:e,coordSysModel:e,coordSys:n,coordSyses:[n],getPanelRect:jP.geo})})}},AP=[function(e,t){var n=e.xAxisModel,r=e.yAxisModel,i=e.gridModel;return!i&&n&&(i=n.axis.grid.model),!i&&r&&(i=r.axis.grid.model),i&&i===t.gridModel},function(e,t){var n=e.geoModel;return n&&n===t.geoModel}],jP={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var e=this.coordSys.view,t=rj(null,e);return On(t,t,nj(null,e)),t}},MP={lineX:H(NP,0),lineY:H(NP,1),rect:function(e,t,n,r){var i=e?t.pointToData([n[0][0],n[1][0]],r):t.dataToPoint([n[0][0],n[1][0]],r),a=e?t.pointToData([n[0][1],n[1][1]],r):t.dataToPoint([n[0][1],n[1][1]],r),o=[DP([i[0],a[0]]),DP([i[1],a[1]])];return{values:o,xyMinMax:o}},polygon:function(e,t,n,r){var i=[ks(),ks()];return{values:B(n,function(n){var a=e?t.pointToData(n,r):t.dataToPoint(n,r);return i[0][0]=Math.min(i[0][0],a[0]),i[1][0]=Math.min(i[1][0],a[1]),i[0][1]=Math.max(i[0][1],a[0]),i[1][1]=Math.max(i[1][1],a[1]),a}),xyMinMax:i}}};function NP(e,t,n,r){var i=n.getAxis([`x`,`y`][e]),a=DP(B([0,1],function(e){return t?i.coordToData(i.toLocalCoord(r[e]),!0):i.toGlobalCoord(i.dataToCoord(r[e]))})),o=[];return o[e]=a,o[1-e]=[NaN,NaN],{values:a,xyMinMax:o}}var PP={lineX:H(FP,0),lineY:H(FP,1),rect:function(e,t,n){return[[e[0][0]-n[0]*t[0][0],e[0][1]-n[0]*t[0][1]],[e[1][0]-n[1]*t[1][0],e[1][1]-n[1]*t[1][1]]]},polygon:function(e,t,n){return B(e,function(e,r){return[e[0]-n[0]*t[r][0],e[1]-n[1]*t[r][1]]})}};function FP(e,t,n,r){return[t[0]-r[e]*n[0],t[1]-r[e]*n[1]]}function IP(e,t){var n=LP(e),r=LP(t),i=[n[0]/r[0],n[1]/r[1]];return isNaN(i[0])&&(i[0]=1),isNaN(i[1])&&(i[1]=1),i}function LP(e){return e?[e[0][1]-e[0][0],e[1][1]-e[1][0]]:[NaN,NaN]}var RP=z,zP=ms(`toolbox-dataZoom_`),BP={x:`width`,y:`height`},VP=function(e){k(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.render=function(e,t,n,r){this._brushController||(this._brushController=new Rj(n.getZr()),this._brushController.on(`brush`,V(this._onBrush,this)).mount()),GP(e,t,this,r,n),WP(e,t)},t.prototype.onclick=function(e,t,n){HP[n].call(this)},t.prototype.dispose=function(e,t){this._brushController&&this._brushController.dispose()},t.prototype._onBrush=function(e){var t=e.areas;if(!e.isEnd||!t.length)return;var n={},r=this.ecModel;this._brushController.updateCovers([]),new EP(UP(this.model),r,{include:[`grid`]}).matchOutputRanges(t,r,function(e,t,n){if(n.type===`cartesian2d`){var r=n.master.getRect().clone(),a=e.brushType;a===`rect`?(i(`x`,n,r,t[0]),i(`y`,n,r,t[1])):i({lineX:`x`,lineY:`y`}[a],n,r,t)}}),yP(r,n),this._dispatchZoomAction(n);function i(e,t,i,o){var s=t.getAxis(e),c=s.model,l=a(e,c,r),u=l.findRepresentativeAxisProxy(c).getMinMaxSpan(),d=s.scale.getExtent();(u.minValueSpan!=null||u.maxValueSpan!=null)&&(o=Cj(0,o.slice(),d,0,u.minValueSpan,u.maxValueSpan));var f=Eo(d,i[BP[e]],.5);l&&(n[l.id]={dataZoomId:l.id,startValue:isFinite(f)?X(o[0],f):o[0],endValue:isFinite(f)?X(o[1],f):o[1]})}function a(e,t,n){var r;return n.eachComponent({mainType:`dataZoom`,subType:`select`},function(n){n.getAxisModel(e,t.componentIndex)&&(r=n)}),r}},t.prototype._dispatchZoomAction=function(e){var t=[];RP(e,function(e,n){t.push(P(e))}),t.length&&this.api.dispatchAction({type:`dataZoom`,from:this.uid,batch:t})},t.getDefaultOption=function(e){return{show:!0,filterMode:`filter`,icon:{zoom:`M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1`,back:`M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26`},title:e.getLocaleModel().get([`toolbox`,`dataZoom`,`title`]),brushStyle:{borderWidth:0,color:Q.color.backgroundTint}}},t}(UN),HP={zoom:function(){var e=!this._isZoomActive;this.api.dispatchAction({type:`takeGlobalCursor`,key:`dataZoomSelect`,dataZoomSelectActive:e})},back:function(){this._dispatchZoomAction(bP(this.ecModel))}};function UP(e){var t={xAxisIndex:e.get(`xAxisIndex`,!0),yAxisIndex:e.get(`yAxisIndex`,!0),xAxisId:e.get(`xAxisId`,!0),yAxisId:e.get(`yAxisId`,!0)};return t.xAxisIndex==null&&t.xAxisId==null&&(t.xAxisIndex=`all`),t.yAxisIndex==null&&t.yAxisId==null&&(t.yAxisIndex=`all`),t}function WP(e,t){e.setIconStatus(`back`,SP(t)>1?`emphasis`:`normal`)}function GP(e,t,n,r,i){var a=n._isZoomActive;r&&r.type===`takeGlobalCursor`&&(a=r.key===`dataZoomSelect`?r.dataZoomSelectActive:!1),n._isZoomActive=a,e.setIconStatus(`zoom`,a?`emphasis`:`normal`);var o=new EP(UP(e),t,{include:[`grid`]}).makePanelOpts(i,function(e){return e.xAxisDeclared&&!e.yAxisDeclared?`lineX`:!e.xAxisDeclared&&e.yAxisDeclared?`lineY`:`rect`});n._brushController.setPanels(o).enableBrush(a&&o.length?{brushType:`auto`,brushStyle:e.getModel(`brushStyle`).getItemStyle()}:!1)}qg(`dataZoom`,function(e){var t=e.getComponent(`toolbox`,0),n=[`feature`,`dataZoom`];if(!t||t.get(n)==null)return;var r=t.getModel(n),i=[],a=ys(e,UP(r));RP(a.xAxisModels,function(e){return o(e,`xAxis`,`xAxisIndex`)}),RP(a.yAxisModels,function(e){return o(e,`yAxis`,`yAxisIndex`)});function o(e,t,n){var a=e.componentIndex,o={type:`select`,$fromToolbox:!0,filterMode:r.get(`filterMode`,!0)||`filter`,id:zP+t+a};o[n]=a,i.push(o)}return i});function KP(e){e.registerComponentModel(qN),e.registerComponentView(YN),GN(`saveAsImage`,QN),GN(`magicType`,tP),GN(`dataView`,hP),GN(`dataZoom`,VP),GN(`restore`,wP),TE(HN)}var qP=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.type=`tooltip`,t.dependencies=[`axisPointer`],t.defaultOption={z:60,show:!0,showContent:!0,trigger:`item`,triggerOn:`mousemove|click|mousewheel`,alwaysShowContent:!1,renderMode:`auto`,confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,displayTransition:!0,enterable:!1,backgroundColor:Q.color.neutral00,shadowBlur:10,shadowColor:`rgba(0, 0, 0, .2)`,shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,defaultBorderColor:Q.color.border,padding:null,extraCssText:``,axisPointer:{type:`line`,axis:`auto`,animation:`auto`,animationDurationUpdate:200,animationEasingUpdate:`exponentialOut`,crossStyle:{color:Q.color.borderShade,width:1,type:`dashed`,textStyle:{}}},textStyle:{color:Q.color.tertiary,fontSize:14}},t}(Og);function JP(e){var t=e.get(`confine`);return t==null?e.get(`renderMode`)===`richText`:!!t}function YP(e){if(j.domSupported){for(var t=document.documentElement.style,n=0,r=e.length;n<r;n++)if(e[n]in t)return e[n]}}var XP=YP([`transform`,`webkitTransform`,`OTransform`,`MozTransform`,`msTransform`]),ZP=YP([`webkitTransition`,`transition`,`OTransition`,`MozTransition`,`msTransition`]);function QP(e,t){if(!e)return t;t=Zh(t,!0);var n=e.indexOf(t);return e=n===-1?t:`-`+e.slice(0,n)+`-`+t,e.toLowerCase()}function $P(e,t){var n=e.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(e);return n?t?n[t]:n:null}var eF=QP(ZP,`transition`),tF=QP(XP,`transform`),nF=`position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;`+(j.transform3dSupported?`will-change:transform;`:``);function rF(e){return e=e===`left`?`right`:e===`right`?`left`:e===`top`?`bottom`:`top`,e}function iF(e,t,n){if(!G(n)||n===`inside`)return``;var r=e.get(`backgroundColor`),i=e.get(`borderWidth`);t=ig(t);var a=rF(n),o=Math.max(Math.round(i)*1.5,6),s=``,c=tF+`:`,l;R([`left`,`right`],a)>-1?(s+=`top:50%`,c+=`translateY(-50%) rotate(`+(l=a===`left`?-225:-45)+`deg)`):(s+=`left:50%`,c+=`translateX(-50%) rotate(`+(l=a===`top`?225:45)+`deg)`);var u=l*Math.PI/180,d=o+i,f=d*Math.abs(Math.cos(u))+d*Math.abs(Math.sin(u)),p=Math.round(((f-Math.SQRT2*i)/2+Math.SQRT2*i-(f-d)/2)*100)/100;s+=`;`+a+`:-`+p+`px`;var m=t+` solid `+i+`px;`;return`<div style="`+[`position:absolute;width:`+o+`px;height:`+o+`px;z-index:-1;`,s+`;`+c+`;`,`border-bottom:`+m,`border-right:`+m,`background-color:`+r+`;`].join(``)+`"></div>`}function aF(e,t,n){var r=`cubic-bezier(0.23,1,0.32,1)`,i=``,a=``;return n&&(i=` `+e/2+`s `+r,a=`opacity`+i+`,visibility`+i),t||(i=` `+e+`s `+r,a+=(a.length?`,`:``)+(j.transformSupported?``+tF+i:`,left`+i+`,top`+i)),eF+`:`+a}function oF(e,t,n){var r=e.toFixed(0)+`px`,i=t.toFixed(0)+`px`;if(!j.transformSupported)return n?`top:`+i+`;left:`+r+`;`:[[`top`,i],[`left`,r]];var a=j.transform3dSupported,o=`translate`+(a?`3d`:``)+`(`+r+`,`+i+(a?`,0`:``)+`)`;return n?`top:0;left:0;`+tF+`:`+o+`;`:[[`top`,0],[`left`,0],[XP,o]]}function sF(e){var t=[],n=e.get(`fontSize`),r=e.getTextColor();r&&t.push(`color:`+r),t.push(`font:`+e.getFont());var i=q(e.get(`lineHeight`),Math.round(n*3/2));n&&t.push(`line-height:`+i+`px`);var a=e.get(`textShadowColor`),o=e.get(`textShadowBlur`)||0,s=e.get(`textShadowOffsetX`)||0,c=e.get(`textShadowOffsetY`)||0;return a&&o&&t.push(`text-shadow:`+s+`px `+c+`px `+o+`px `+a),z([`decoration`,`align`],function(n){var r=e.get(n);r&&t.push(`text-`+n+`:`+r)}),t.join(`;`)}function cF(e,t,n,r){var i=[],a=e.get(`transitionDuration`),o=e.get(`backgroundColor`),s=e.get(`shadowBlur`),c=e.get(`shadowColor`),l=e.get(`shadowOffsetX`),u=e.get(`shadowOffsetY`),d=e.getModel(`textStyle`),f=by(e,`html`),p=l+`px `+u+`px `+s+`px `+c;return i.push(`box-shadow:`+p),t&&a>0&&i.push(aF(a,n,r)),o&&i.push(`background-color:`+o),z([`width`,`color`,`radius`],function(t){var n=`border-`+t,r=Zh(n),a=e.get(r);a!=null&&i.push(n+`:`+a+(t===`color`?``:`px`))}),i.push(sF(d)),f!=null&&i.push(`padding:`+Qh(f).join(`px `)+`px`),i.join(`;`)+`;`}function lF(e,t,n,r,i){var a=t&&t.painter;if(n){var o=a&&a.getViewportRoot();o&&At(e,o,n,r,i)}else{e[0]=r,e[1]=i;var s=a&&a.getViewportRootOffset();s&&(e[0]+=s.offsetLeft,e[1]+=s.offsetTop)}e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}var uF=function(){function e(e,t){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,j.wxa)return null;var n=document.createElement(`div`);n.domBelongToZr=!0,this.el=n;var r=this._zr=e.getZr(),i=t.appendTo,a=i&&(G(i)?document.querySelector(i):Pe(i)?i:W(i)&&i(e.getDom()));lF(this._styleCoord,r,a,e.getWidth()/2,e.getHeight()/2),(a||e.getDom()).appendChild(n),this._api=e,this._container=a;var o=this;n.onmouseenter=function(){o._enterable&&(clearTimeout(o._hideTimeout),o._show=!0),o._inContent=!0},n.onmousemove=function(e){if(e||=window.event,!o._enterable){var t=r.handler;Gt(r.painter.getViewportRoot(),e,!0),t.dispatch(`mousemove`,e)}},n.onmouseleave=function(){o._inContent=!1,o._enterable&&o._show&&o.hideLater(o._hideDelay)}}return e.prototype.update=function(e){if(!this._container){var t=this._api.getDom(),n=$P(t,`position`),r=t.style;r.position!==`absolute`&&n!==`absolute`&&(r.position=`relative`)}var i=e.get(`alwaysShowContent`);i&&this._moveIfResized(),this._alwaysShowContent=i,this._enableDisplayTransition=e.get(`displayTransition`)&&e.get(`transitionDuration`)>0,this.el.className=e.get(`className`)||``},e.prototype.show=function(e,t){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var n=this.el,r=n.style,i=this._styleCoord;n.innerHTML?r.cssText=nF+cF(e,!this._firstShow,this._longHide,this._enableDisplayTransition)+oF(i[0],i[1],!0)+(`border-color:`+ig(t)+`;`)+(e.get(`extraCssText`)||``)+(`;pointer-events:`+(this._enterable?`auto`:`none`)):r.display=`none`,this._show=!0,this._firstShow=!1,this._longHide=!1},e.prototype.setContent=function(e,t,n,r,i){var a=this.el;if(e==null){a.innerHTML=``;return}var o=``;if(G(i)&&n.get(`trigger`)===`item`&&!JP(n)&&(o=iF(n,r,i)),G(e))a.innerHTML=e+o;else if(e){a.innerHTML=``,U(e)||(e=[e]);for(var s=0;s<e.length;s++)Pe(e[s])&&e[s].parentNode!==a&&a.appendChild(e[s]);if(o&&a.childNodes.length){var c=document.createElement(`div`);c.innerHTML=o,a.appendChild(c)}}},e.prototype.setEnterable=function(e){this._enterable=e},e.prototype.getSize=function(){var e=this.el;return e?[e.offsetWidth,e.offsetHeight]:[0,0]},e.prototype.moveTo=function(e,t){if(this.el){var n=this._styleCoord;if(lF(n,this._zr,this._container,e,t),n[0]!=null&&n[1]!=null){var r=this.el.style;z(oF(n[0],n[1]),function(e){r[e[0]]=e[1]})}}},e.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},e.prototype.hide=function(){var e=this,t=this.el.style;this._enableDisplayTransition?(t.visibility=`hidden`,t.opacity=`0`):t.display=`none`,j.transform3dSupported&&(t.willChange=``),this._show=!1,this._longHideTimeout=setTimeout(function(){return e._longHide=!0},500)},e.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(V(this.hide,this),e)):this.hide())},e.prototype.isShow=function(){return this._show},e.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var e=this._zr;jt(e&&e.painter&&e.painter.getViewportRoot(),this._container);var t=this.el;if(t){t.onmouseenter=t.onmousemove=t.onmouseleave=null;var n=t.parentNode;n&&n.removeChild(t)}this.el=this._container=null},e}(),dF=function(){function e(e){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=e.getZr(),mF(this._styleCoord,this._zr,e.getWidth()/2,e.getHeight()/2)}return e.prototype.update=function(e){var t=e.get(`alwaysShowContent`);t&&this._moveIfResized(),this._alwaysShowContent=t},e.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},e.prototype.setContent=function(e,t,n,r,i){var a=this;K(e)&&qo(``),this.el&&this._zr.remove(this.el);var o=n.getModel(`textStyle`);this.el=new pu({style:{rich:t.richTextStyles,text:e,lineHeight:22,borderWidth:1,borderColor:r,textShadowColor:o.get(`textShadowColor`),fill:n.get([`textStyle`,`color`]),padding:by(n,`richText`),verticalAlign:`top`,align:`left`},z:n.get(`z`)}),z([`backgroundColor`,`borderRadius`,`shadowColor`,`shadowBlur`,`shadowOffsetX`,`shadowOffsetY`],function(e){a.el.style[e]=n.get(e)}),z([`textShadowBlur`,`textShadowOffsetX`,`textShadowOffsetY`],function(e){a.el.style[e]=o.get(e)||0}),this._zr.add(this.el);var s=this;this.el.on(`mouseover`,function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0}),this.el.on(`mouseout`,function(){s._enterable&&s._show&&s.hideLater(s._hideDelay),s._inContent=!1})},e.prototype.setEnterable=function(e){this._enterable=e},e.prototype.getSize=function(){var e=this.el,t=this.el.getBoundingRect(),n=pF(e.style);return[t.width+n.left+n.right,t.height+n.top+n.bottom]},e.prototype.moveTo=function(e,t){var n=this.el;if(n){var r=this._styleCoord;mF(r,this._zr,e,t),e=r[0],t=r[1];var i=n.style,a=fF(i.borderWidth||0),o=pF(i);n.x=e+a+o.left,n.y=t+a+o.top,n.markRedraw()}},e.prototype._moveIfResized=function(){var e=this._styleCoord[2],t=this._styleCoord[3];this.moveTo(e*this._zr.getWidth(),t*this._zr.getHeight())},e.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},e.prototype.hideLater=function(e){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(e?(this._hideDelay=e,this._show=!1,this._hideTimeout=setTimeout(V(this.hide,this),e)):this.hide())},e.prototype.isShow=function(){return this._show},e.prototype.dispose=function(){this._zr.remove(this.el)},e}();function fF(e){return Math.max(0,e)}function pF(e){var t=fF(e.shadowBlur||0),n=fF(e.shadowOffsetX||0),r=fF(e.shadowOffsetY||0);return{left:fF(t-n),right:fF(t+n),top:fF(t-r),bottom:fF(t+r)}}function mF(e,t,n,r){e[0]=n,e[1]=r,e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}var hF=new cu({shape:{x:-1,y:-1,width:2,height:2}}),gF=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.init=function(e,t){if(!(j.node||!t.getDom())){var n=e.getComponent(`tooltip`),r=this._renderMode=Ds(n.get(`renderMode`));this._tooltipContent=r===`richText`?new dF(t):new uF(t,{appendTo:n.get(`appendToBody`,!0)?`body`:n.get(`appendTo`,!0)})}},t.prototype.render=function(e,t,n){if(!(j.node||!n.getDom())){this.group.removeAll(),this._tooltipModel=e,this._ecModel=t,this._api=n;var r=this._tooltipContent;r.update(e),r.setEnterable(e.get(`enterable`)),this._initGlobalListener(),this._keepShow(),this._renderMode!==`richText`&&e.get(`transitionDuration`)?Yy(this,`_updatePosition`,50,`fixRate`):Xy(this,`_updatePosition`)}},t.prototype._initGlobalListener=function(){var e=this._tooltipModel.get(`triggerOn`);ZM(`itemTooltip`,this._api,V(function(t,n,r){e!==`none`&&(e.indexOf(t)>=0?this._tryShow(n,r):t===`leave`&&this._hide(r))},this))},t.prototype._keepShow=function(){var e=this._tooltipModel,t=this._ecModel,n=this._api,r=e.get(`triggerOn`);if(e.get(`trigger`)!==`axis`&&(this._lastDataByCoordSys=null,this._cbParamsList=null),this._lastX!=null&&this._lastY!=null&&r!==`none`&&r!==`click`){var i=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!n.isDisposed()&&i.manuallyShowTip(e,t,n,{x:i._lastX,y:i._lastY,dataByCoordSys:i._lastDataByCoordSys})})}},t.prototype.manuallyShowTip=function(e,t,n,r){if(!(r.from===this.uid||j.node||!n.getDom())){var i=vF(r,n);this._ticket=``;var a=r.dataByCoordSys,o=CF(r,t,n);if(o){var s=o.el.getBoundingRect().clone();s.applyTransform(o.el.transform),this._tryShow({offsetX:s.x+s.width/2,offsetY:s.y+s.height/2,target:o.el,position:r.position,positionDefault:`bottom`},i)}else if(r.tooltip&&r.x!=null&&r.y!=null){var c=hF;c.x=r.x,c.y=r.y,c.update(),Du(c).tooltipConfig={name:null,option:r.tooltip},this._tryShow({offsetX:r.x,offsetY:r.y,target:c},i)}else if(a)this._tryShow({offsetX:r.x,offsetY:r.y,position:r.position,dataByCoordSys:a,tooltipOption:r.tooltipOption},i);else if(r.seriesIndex!=null){if(this._manuallyAxisShowTip(e,t,n,r))return;var l=aN(r,t),u=l.point[0],d=l.point[1];u!=null&&d!=null&&this._tryShow({offsetX:u,offsetY:d,target:l.el,position:r.position,positionDefault:`bottom`},i)}else r.x!=null&&r.y!=null&&(n.dispatchAction({type:`updateAxisPointer`,x:r.x,y:r.y}),this._tryShow({offsetX:r.x,offsetY:r.y,position:r.position,target:n.getZr().findHover(r.x,r.y).target},i))}},t.prototype.manuallyHideTip=function(e,t,n,r){var i=this._tooltipContent;this._tooltipModel&&i.hideLater(this._tooltipModel.get(`hideDelay`)),this._lastX=this._lastY=this._lastDataByCoordSys=null,this._cbParamsList=null,r.from!==this.uid&&this._hide(vF(r,n))},t.prototype._manuallyAxisShowTip=function(e,t,n,r){var i=r.seriesIndex,a=r.dataIndex,o=t.getComponent(`axisPointer`).coordSysAxesInfo;if(!(i==null||a==null||o==null)){var s=t.getSeriesByIndex(i);if(s&&_F([s.getData().getItemModel(a),s,(s.coordinateSystem||{}).model],this._tooltipModel).get(`trigger`)===`axis`)return n.dispatchAction({type:`updateAxisPointer`,seriesIndex:i,dataIndex:a,position:r.position}),!0}},t.prototype._tryShow=function(e,t){var n=e.target;if(this._tooltipModel){this._lastX=e.offsetX,this._lastY=e.offsetY;var r=e.dataByCoordSys;if(r&&r.length)this._showAxisTooltip(r,e);else if(n){if(Du(n).ssrType===`legend`)return;this._lastDataByCoordSys=null,this._cbParamsList=null;var i,a;Ib(n,function(e){if(e.tooltipDisabled)return i=a=null,!0;i||a||(Du(e).dataIndex==null?Du(e).tooltipConfig!=null&&(a=e):i=e)},!0),i?this._showSeriesItemTooltip(e,i,t):a?this._showComponentItemTooltip(e,a,t):this._hide(t)}else this._lastDataByCoordSys=null,this._cbParamsList=null,this._hide(t)}},t.prototype._showOrMove=function(e,t){var n=e.get(`showDelay`);t=V(t,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(t,n):t()},t.prototype._showAxisTooltip=function(e,t){var n=this._ecModel,r=this._tooltipModel,i=[t.offsetX,t.offsetY],a=_F([t.tooltipOption],r),o=this._renderMode,s=[],c=oy(`section`,{blocks:[],noHeader:!0}),l=[],u=new xy;z(e,function(e){z(e.dataByAxis,function(e){var t=n.getComponent(e.axisDim+`Axis`,e.axisIndex),i=e.value,a=t.axis,d=a.scale.parse(i);if(!(!t||i==null)){var f=LM(i,a,n,e.seriesDataIndices,e.valueLabelOpt),p=oy(`section`,{header:f,noHeader:!Ue(f),sortBlocks:!0,blocks:[]});c.blocks.push(p),z(e.seriesDataIndices,function(i){var a=n.getSeriesByIndex(i.seriesIndex),c=i.dataIndexInside,m=a.getDataParams(c);if(!(m.dataIndex<0)){m.axisDim=e.axisDim,m.axisIndex=e.axisIndex,m.axisType=e.axisType,m.axisId=e.axisId,m.axisValue=kT(t.axis,{value:d}),m.axisValueLabel=f,m.marker=u.makeTooltipMarker(`item`,ig(m.color),o);var h=Sv(a.formatTooltip(c,!0,null)),g=h.frag;if(g){var _=_F([a],r).get(`valueFormatter`);p.blocks.push(_?I({valueFormatter:_},g):g)}h.text&&l.push(h.text),s.push(m)}})}})}),c.blocks.reverse(),l.reverse();var d=t.position,f=fy(c,u,o,a.get(`order`),n.get(`useUTC`),a.get(`textStyle`));f&&l.unshift(f);var p=o===`richText`?`
`:`<br/>`,m=l.join(p);this._showOrMove(a,function(){this._updateContentNotChangedOnAxis(e,s)?this._updatePosition(a,d,i[0],i[1],this._tooltipContent,s):this._showTooltipContent(a,m,s,Math.random()+``,i[0],i[1],d,null,u)})},t.prototype._showSeriesItemTooltip=function(e,t,n){var r=this._ecModel,i=Du(t),a=i.seriesIndex,o=r.getSeriesByIndex(a),s=i.dataModel||o,c=i.dataIndex,l=i.dataType,u=s.getData(l),d=this._renderMode,f=e.positionDefault,p=_F([u.getItemModel(c),s,o&&(o.coordinateSystem||{}).model],this._tooltipModel,f?{position:f}:null),m=p.get(`trigger`);if(!(m!=null&&m!==`item`)){var h=s.getDataParams(c,l),g=new xy;h.marker=g.makeTooltipMarker(`item`,ig(h.color),d);var _=Sv(s.formatTooltip(c,!1,l)),v=p.get(`order`),y=p.get(`valueFormatter`),b=_.frag,x=b?fy(y?I({valueFormatter:y},b):b,g,d,v,r.get(`useUTC`),p.get(`textStyle`)):_.text,S=`item_`+s.name+`_`+c;this._showOrMove(p,function(){this._showTooltipContent(p,x,h,S,e.offsetX,e.offsetY,e.position,e.target,g)}),n({type:`showTip`,dataIndexInside:c,dataIndex:u.getRawIndex(c),seriesIndex:a,from:this.uid})}},t.prototype._showComponentItemTooltip=function(e,t,n){var r=this._renderMode===`html`,i=Du(t),a=i.tooltipConfig.option||{},o=a.encodeHTMLContent;if(G(a)){var s=a;a={content:s,formatter:s},o=!0}o&&r&&a.content&&(a=P(a),a.content=Rt(a.content));var c=[a],l=this._ecModel.getComponent(i.componentMainType,i.componentIndex);l&&c.push(l),c.push({formatter:a.content});var u=e.positionDefault,d=_F(c,this._tooltipModel,u?{position:u}:null),f=d.get(`content`),p=Math.random()+``,m=new xy;this._showOrMove(d,function(){var n=P(d.get(`formatterParams`)||{});this._showTooltipContent(d,f,n,p,e.offsetX,e.offsetY,e.position,t,m)}),n({type:`showTip`,from:this.uid})},t.prototype._showTooltipContent=function(e,t,n,r,i,a,o,s,c){if(this._ticket=``,!(!e.get(`showContent`)||!e.get(`show`))){var l=this._tooltipContent;l.setEnterable(e.get(`enterable`));var u=e.get(`formatter`);o||=e.get(`position`);var d=t,f=this._getNearestPoint([i,a],n,e.get(`trigger`),e.get(`borderColor`),e.get(`defaultBorderColor`,!0)).color;if(u)if(G(u)){var p=e.ecModel.get(`useUTC`),m=U(n)?n[0]:n,h=m&&m.axisType&&m.axisType.indexOf(`time`)>=0;d=u,h&&(d=Mh(m.axisValue,d,p)),d=ng(d,n,!0)}else if(W(u)){var g=V(function(t,r){t===this._ticket&&(l.setContent(r,c,e,f,o),this._updatePosition(e,o,i,a,l,n,s))},this);this._ticket=r,d=u(n,r,g)}else d=u;l.setContent(d,c,e,f,o),l.show(e,f),this._updatePosition(e,o,i,a,l,n,s)}},t.prototype._getNearestPoint=function(e,t,n,r,i){if(n===`axis`||U(t))return{color:r||i};if(!U(t))return{color:r||t.color||t.borderColor}},t.prototype._updatePosition=function(e,t,n,r,i,a,o){var s=this._api.getWidth(),c=this._api.getHeight();t||=e.get(`position`);var l=i.getSize(),u=e.get(`align`),d=e.get(`verticalAlign`),f=o&&o.getBoundingRect().clone();if(o&&f.applyTransform(o.transform),W(t)&&(t=t([n,r],a,i.el,f,{viewSize:[s,c],contentSize:l.slice()})),U(t))n=yo(t[0],s),r=yo(t[1],c);else if(K(t)){var p=t;p.width=l[0],p.height=l[1];var m=yg(p,{width:s,height:c});n=m.x,r=m.y,u=null,d=null}else if(G(t)&&o){var h=xF(t,f,l,e.get(`borderWidth`));n=h[0],r=h[1]}else{var h=yF(n,r,i,s,c,u?null:20,d?null:20);n=h[0],r=h[1]}if(u&&(n-=SF(u)?l[0]/2:u===`right`?l[0]:0),d&&(r-=SF(d)?l[1]/2:d===`bottom`?l[1]:0),JP(e)){var h=bF(n,r,i,s,c);n=h[0],r=h[1]}i.moveTo(n,r)},t.prototype._updateContentNotChangedOnAxis=function(e,t){var n=this._lastDataByCoordSys,r=this._cbParamsList,i=!!n&&n.length===e.length;return i&&z(n,function(n,a){var o=n.dataByAxis||[],s=(e[a]||{}).dataByAxis||[];i&&=o.length===s.length,i&&z(o,function(e,n){var a=s[n]||{},o=e.seriesDataIndices||[],c=a.seriesDataIndices||[];i=i&&e.value===a.value&&e.axisType===a.axisType&&e.axisId===a.axisId&&o.length===c.length,i&&z(o,function(e,t){var n=c[t];i=i&&e.seriesIndex===n.seriesIndex&&e.dataIndex===n.dataIndex}),r&&z(e.seriesDataIndices,function(e){var n=e.seriesIndex,a=t[n],o=r[n];a&&o&&o.data!==a.data&&(i=!1)})})}),this._lastDataByCoordSys=e,this._cbParamsList=t,!!i},t.prototype._hide=function(e){this._lastDataByCoordSys=null,this._cbParamsList=null,e({type:`hideTip`,from:this.uid})},t.prototype.dispose=function(e,t){j.node||!t.getDom()||(Xy(this,`_updatePosition`),this._tooltipContent.dispose(),rN(`itemTooltip`,t),this._tooltipContent=null,this._tooltipModel=null,this._lastDataByCoordSys=null,this._cbParamsList=null)},t.type=`tooltip`,t}(Fy);function _F(e,t,n){var r=t.ecModel,i;n?(i=new Gm(n,r,r),i=new Gm(t.option,i,r)):i=t;for(var a=e.length-1;a>=0;a--){var o=e[a];o&&(o instanceof Gm&&(o=o.get(`tooltip`,!0)),G(o)&&(o={formatter:o}),o&&(i=new Gm(o,i,r)))}return i}function vF(e,t){return e.dispatchAction||V(t.dispatchAction,t)}function yF(e,t,n,r,i,a,o){var s=n.getSize(),c=s[0],l=s[1];return a!=null&&(e+c+a+2>r?e-=c+a:e+=a),o!=null&&(t+l+o>i?t-=l+o:t+=o),[e,t]}function bF(e,t,n,r,i){var a=n.getSize(),o=a[0],s=a[1];return e=Math.min(e+o,r)-o,t=Math.min(t+s,i)-s,e=Math.max(e,0),t=Math.max(t,0),[e,t]}function xF(e,t,n,r){var i=n[0],a=n[1],o=Math.ceil(Math.SQRT2*r)+8,s=0,c=0,l=t.width,u=t.height;switch(e){case`inside`:s=t.x+l/2-i/2,c=t.y+u/2-a/2;break;case`top`:s=t.x+l/2-i/2,c=t.y-a-o;break;case`bottom`:s=t.x+l/2-i/2,c=t.y+u+o;break;case`left`:s=t.x-i-o,c=t.y+u/2-a/2;break;case`right`:s=t.x+l+o,c=t.y+u/2-a/2}return[s,c]}function SF(e){return e===`center`||e===`middle`}function CF(e,t,n){var r=bs(e).queryOptionMap,i=r.keys()[0];if(!(!i||i===`series`)){var a=Cs(t,i,r.get(i),{useDefault:!1,enableAll:!1,enableNone:!1}).models[0];if(a){var o=n.getViewOfComponentModel(a),s;if(o.group.traverse(function(t){var n=Du(t).tooltipConfig;if(n&&n.name===e.name)return s=t,!0}),s)return{componentMainType:i,componentIndex:a.componentIndex,el:s}}}}function wF(e){TE(vN),e.registerComponentModel(qP),e.registerComponentView(gF),e.registerAction({type:`showTip`,event:`showTip`,update:`tooltip:manuallyShowTip`},tt),e.registerAction({type:`hideTip`,event:`hideTip`,update:`tooltip:manuallyHideTip`},tt)}function TF(e,t){if(!e)return!1;for(var n=U(e)?e:[e],r=0;r<n.length;r++)if(n[r]&&n[r][t])return!0;return!1}function EF(e){Qo(e,`label`,[`show`])}var DF=Z(),OF=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.createdBySelf=!1,n.preventAutoZ=!0,n}return t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n),this._mergeOption(e,n,!1,!0)},t.prototype.isAnimationEnabled=function(){if(j.node)return!1;var e=this.__hostSeries;return this.getShallow(`animation`)&&e&&e.isAnimationEnabled()},t.prototype.mergeOption=function(e,t){this._mergeOption(e,t,!1,!1)},t.prototype._mergeOption=function(e,t,n,r){var i=this.mainType;n||t.eachSeries(function(e){var n=e.get(this.mainType,!0),a=DF(e)[i];if(!n||!n.data){DF(e)[i]=null;return}a?a._mergeOption(n,t,!0):(r&&EF(n),z(n.data,function(e){e instanceof Array?(EF(e[0]),EF(e[1])):EF(e)}),a=this.createMarkerModelFromSeries(n,this,t),I(a,{mainType:this.mainType,seriesIndex:e.seriesIndex,name:e.name,createdBySelf:!0}),a.__hostSeries=e),DF(e)[i]=a},this)},t.prototype.formatTooltip=function(e,t,n){var r=this.getData(),i=this.getRawValue(e),a=r.getName(e);return oy(`section`,{header:this.name,blocks:[oy(`nameValue`,{name:a,value:i,noName:!a,noValue:i==null})]})},t.prototype.getData=function(){return this._data},t.prototype.setData=function(e){this._data=e},t.prototype.getDataParams=function(e,t){var n=xv.prototype.getDataParams.call(this,e,t),r=this.__hostSeries;return r&&(n.seriesId=r.id,n.seriesName=r.name,n.seriesType=r.subType),n},t.getMarkerModelFromSeries=function(e,t){return DF(e)[t]},t.type=`marker`,t.dependencies=[`series`,`grid`,`polar`,`geo`],t}(Og);Ce(OF,xv.prototype);var kF=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.createMarkerModelFromSeries=function(e,n,r){return new t(e,n,r)},t.type=`markPoint`,t.defaultOption={z:5,symbol:`pin`,symbolSize:50,tooltip:{trigger:`item`},label:{show:!0,position:`inside`},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}},t}(OF);function AF(e){return!(isNaN(parseFloat(e.x))&&isNaN(parseFloat(e.y)))}function jF(e){return!isNaN(parseFloat(e.x))&&!isNaN(parseFloat(e.y))}function MF(e,t,n,r,i,a,o){var s=[],c=_w(t,i)?t.getCalculationInfo(`stackResultDimension`):i,l=zF(t,c,e),u=t.hostModel.indicesOfNearest(n,c,l)[0];s[a]=t.get(r,u),s[o]=t.get(c,u);var d=t.get(i,u),f=wo(t.get(i,u));return f=Math.min(f,20),f>=0&&(s[o]=+s[o].toFixed(f)),[s,d]}var NF={min:H(MF,`min`),max:H(MF,`max`),average:H(MF,`average`),median:H(MF,`median`)};function PF(e,t){if(t){var n=e.getData(),r=e.coordinateSystem,i=r&&r.dimensions;if(!jF(t)&&!U(t.coord)&&U(i)){var a=FF(t,n,r,e);if(t=P(t),t.type&&NF[t.type]&&a.baseAxis&&a.valueAxis){var o=R(i,a.baseAxis.dim),s=R(i,a.valueAxis.dim),c=NF[t.type](n,a.valueAxis.dim,a.baseDataDim,a.valueDataDim,o,s);t.coord=c[0],t.value=c[1]}else t.coord=[t.xAxis==null?t.radiusAxis:t.xAxis,t.yAxis==null?t.angleAxis:t.yAxis]}if(t.coord==null||!U(i)){t.coord=[];var l=e.getBaseAxis();if(l&&t.type&&NF[t.type]){var u=r.getOtherAxis(l);u&&(t.value=zF(n,n.mapDimension(u.dim),t.type))}}else for(var d=t.coord,f=0;f<2;f++)NF[d[f]]&&(d[f]=zF(n,n.mapDimension(i[f]),d[f]));return t}}function FF(e,t,n,r){var i={};return e.valueIndex!=null||e.valueDim!=null?(i.valueDataDim=e.valueIndex==null?e.valueDim:t.getDimension(e.valueIndex),i.valueAxis=n.getAxis(IF(r,i.valueDataDim)),i.baseAxis=n.getOtherAxis(i.valueAxis),i.baseDataDim=t.mapDimension(i.baseAxis.dim)):(i.baseAxis=r.getBaseAxis(),i.valueAxis=n.getOtherAxis(i.baseAxis),i.baseDataDim=t.mapDimension(i.baseAxis.dim),i.valueDataDim=t.mapDimension(i.valueAxis.dim)),i}function IF(e,t){var n=e.getData().getDimensionInfo(t);return n&&n.coordDim}function LF(e,t){return e&&e.containData&&t.coord&&!AF(t)?e.containData(t.coord):!0}function RF(e,t){return e?function(e,n,r,i){return Ev(i<2?e.coord&&e.coord[i]:e.value,t[i])}:function(e,n,r,i){return Ev(e.value,t[i])}}function zF(e,t,n){if(n===`average`){var r=0,i=0;return e.each(t,function(e,t){isNaN(e)||(r+=e,i++)}),r/i}else if(n===`median`)return e.getMedian(t);else return e.getDataExtent(t)[+(n===`max`)]}var BF=Z(),VF=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.init=function(){this.markerGroupMap=J()},t.prototype.render=function(e,t,n){var r=this,i=this.markerGroupMap;i.each(function(e){BF(e).keep=!1}),t.eachSeries(function(e){var i=OF.getMarkerModelFromSeries(e,r.type);i&&r.renderSeries(e,i,t,n)}),i.each(function(e){!BF(e).keep&&r.group.remove(e.group)}),HF(t,i,this.type)},t.prototype.markKeep=function(e){BF(e).keep=!0},t.prototype.toggleBlurSeries=function(e,t){var n=this;z(e,function(e){var r=OF.getMarkerModelFromSeries(e,n.type);r&&r.getData().eachItemGraphicEl(function(e){e&&(t?yd(e):bd(e))})})},t.type=`marker`,t}(Fy);function HF(e,t,n){e.eachSeries(function(e){var r=OF.getMarkerModelFromSeries(e,n),i=t.get(e.id);if(r&&i&&i.group){var a=dm(r),o=a.z,s=a.zlevel;pm(i.group,o,s)}})}function UF(e,t,n){var r=t.coordinateSystem,i=n.getWidth(),a=n.getHeight(),o=r&&r.getArea&&r.getArea();e.each(function(n){var s=e.getItemModel(n),c=s.get(`relativeTo`)===`coordinate`,l=c?o?o.width:0:i,u=c?o?o.height:0:a,d=c&&o?o.x:0,f=c&&o?o.y:0,p,m=yo(s.get(`x`),l)+d,h=yo(s.get(`y`),u)+f;if(!isNaN(m)&&!isNaN(h))p=[m,h];else if(t.getMarkerPosition)p=t.getMarkerPosition(e.getValues(e.dimensions,n));else if(r){var g=e.get(r.dimensions[0],n),_=e.get(r.dimensions[1],n);p=r.dataToPoint([g,_])}isNaN(m)||(p[0]=m),isNaN(h)||(p[1]=h),e.setItemLayout(n,p)})}var WF=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.updateTransform=function(e,t,n){t.eachSeries(function(e){var t=OF.getMarkerModelFromSeries(e,`markPoint`);t&&(UF(t.getData(),e,n),this.markerGroupMap.get(e.id).updateLayout())},this)},t.prototype.renderSeries=function(e,t,n,r){var i=e.coordinateSystem,a=e.id,o=e.getData(),s=this.markerGroupMap,c=s.get(a)||s.set(a,new XD),l=GF(i,e,t);t.setData(l),UF(t.getData(),e,r),l.each(function(e){var n=l.getItemModel(e),r=n.getShallow(`symbol`),i=n.getShallow(`symbolSize`),a=n.getShallow(`symbolRotate`),s=n.getShallow(`symbolOffset`),c=n.getShallow(`symbolKeepAspect`);if(W(r)||W(i)||W(a)||W(s)){var u=t.getRawValue(e),d=t.getDataParams(e);W(r)&&(r=r(u,d)),W(i)&&(i=i(u,d)),W(a)&&(a=a(u,d)),W(s)&&(s=s(u,d))}var f=n.getModel(`itemStyle`).getItemStyle(),p=n.get(`z2`),m=Nb(o,`color`);f.fill||=m,l.setItemVisual(e,{z2:q(p,0),symbol:r,symbolSize:i,symbolRotate:a,symbolOffset:s,symbolKeepAspect:c,style:f})}),c.updateData(l),this.group.add(c.group),l.eachItemGraphicEl(function(e){e.traverse(function(e){Du(e).dataModel=t})}),this.markKeep(c),c.group.silent=t.get(`silent`)||e.get(`silent`)},t.type=`markPoint`,t}(VF);function GF(e,t,n){var r=e?B(e&&e.dimensions,function(e){var n=t.getData();return I(I({},n.getDimensionInfo(n.mapDimension(e))||{}),{name:e,ordinalMeta:null})}):[{name:`value`,type:`float`}],i=new sw(r,n),a=B(n.get(`data`),H(PF,t));e&&(a=Ee(a,H(LF,e)));var o=RF(!!e,r);return i.initData(a,null,o),i}function KF(e){e.registerComponentModel(kF),e.registerComponentView(WF),e.registerPreprocessor(function(e){TF(e.series,`markPoint`)&&(e.markPoint=e.markPoint||{})})}var qF=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.createMarkerModelFromSeries=function(e,n,r){return new t(e,n,r)},t.type=`markLine`,t.defaultOption={z:5,symbol:[`circle`,`arrow`],symbolSize:[8,16],symbolOffset:0,precision:2,tooltip:{trigger:`item`},label:{show:!0,position:`end`,distance:5},lineStyle:{type:`dashed`},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:`linear`},t}(OF),JF=Z(),YF=function(e,t,n,r){var i=e.getData(),a;if(U(r))a=r;else{var o=r.type;if(o===`min`||o===`max`||o===`average`||o===`median`||r.xAxis!=null||r.yAxis!=null){var s=void 0,c=void 0;if(r.yAxis!=null||r.xAxis!=null)s=t.getAxis(r.yAxis==null?`x`:`y`),c=Re(r.yAxis,r.xAxis);else{var l=FF(r,i,t,e);s=l.valueAxis,c=zF(i,vw(i,l.valueDataDim),o)}var u=s.dim===`x`?0:1,d=1-u,f=P(r),p={coord:[]};f.type=null,f.coord=[],f.coord[d]=-1/0,p.coord[d]=1/0;var m=n.get(`precision`);m>=0&&je(c)&&(c=+c.toFixed(Math.min(m,20))),f.coord[u]=p.coord[u]=c,a=[f,p,{type:o,valueIndex:r.valueIndex,value:c}]}else a=[]}var h=[PF(e,a[0]),PF(e,a[1]),I({},a[2])];return h[2].type=h[2].type||null,F(h[2],h[0]),F(h[2],h[1]),h};function XF(e){return!isNaN(e)&&!isFinite(e)}function ZF(e,t,n,r){var i=1-e,a=r.dimensions[e];return XF(t[i])&&XF(n[i])&&t[e]===n[e]&&r.getAxis(a).containData(t[e])}function QF(e,t){if(e.type===`cartesian2d`){var n=t[0].coord,r=t[1].coord;if(n&&r&&(ZF(1,n,r,e)||ZF(0,n,r,e)))return!0}return LF(e,t[0])&&LF(e,t[1])}function $F(e,t,n,r,i){var a=r.coordinateSystem,o=e.getItemModel(t),s,c=yo(o.get(`x`),i.getWidth()),l=yo(o.get(`y`),i.getHeight());if(!isNaN(c)&&!isNaN(l))s=[c,l];else{if(r.getMarkerPosition)s=r.getMarkerPosition(e.getValues(e.dimensions,t));else{var u=a.dimensions,d=e.get(u[0],t),f=e.get(u[1],t);s=a.dataToPoint([d,f])}if(gO(a,`cartesian2d`)){var p=a.getAxis(`x`),m=a.getAxis(`y`),u=a.dimensions;XF(e.get(u[0],t))?s[0]=p.toGlobalCoord(p.getExtent()[+!n]):XF(e.get(u[1],t))&&(s[1]=m.toGlobalCoord(m.getExtent()[+!n]))}isNaN(c)||(s[0]=c),isNaN(l)||(s[1]=l)}e.setItemLayout(t,s)}var eI=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.updateTransform=function(e,t,n){t.eachSeries(function(e){var t=OF.getMarkerModelFromSeries(e,`markLine`);if(t){var r=t.getData(),i=JF(t).from,a=JF(t).to;i.each(function(t){$F(i,t,!0,e,n),$F(a,t,!1,e,n)}),r.each(function(e){r.setItemLayout(e,[i.getItemLayout(e),a.getItemLayout(e)])}),this.markerGroupMap.get(e.id).updateLayout()}},this)},t.prototype.renderSeries=function(e,t,n,r){var i=e.coordinateSystem,a=e.id,o=e.getData(),s=this.markerGroupMap,c=s.get(a)||s.set(a,new vj);this.group.add(c.group);var l=tI(i,e,t),u=l.from,d=l.to,f=l.line;JF(t).from=u,JF(t).to=d,t.setData(f);var p=t.get(`symbol`),m=t.get(`symbolSize`),h=t.get(`symbolRotate`),g=t.get(`symbolOffset`);U(p)||(p=[p,p]),U(m)||(m=[m,m]),U(h)||(h=[h,h]),U(g)||(g=[g,g]),l.from.each(function(e){_(u,e,!0),_(d,e,!1)}),f.each(function(e){var t=f.getItemModel(e),n=t.getModel(`lineStyle`).getLineStyle();f.setItemLayout(e,[u.getItemLayout(e),d.getItemLayout(e)]);var r=t.get(`z2`);n.stroke??=u.getItemVisual(e,`style`).fill,f.setItemVisual(e,{z2:q(r,0),fromSymbolKeepAspect:u.getItemVisual(e,`symbolKeepAspect`),fromSymbolOffset:u.getItemVisual(e,`symbolOffset`),fromSymbolRotate:u.getItemVisual(e,`symbolRotate`),fromSymbolSize:u.getItemVisual(e,`symbolSize`),fromSymbol:u.getItemVisual(e,`symbol`),toSymbolKeepAspect:d.getItemVisual(e,`symbolKeepAspect`),toSymbolOffset:d.getItemVisual(e,`symbolOffset`),toSymbolRotate:d.getItemVisual(e,`symbolRotate`),toSymbolSize:d.getItemVisual(e,`symbolSize`),toSymbol:d.getItemVisual(e,`symbol`),style:n})}),c.updateData(f),l.line.eachItemGraphicEl(function(e){Du(e).dataModel=t,e.traverse(function(e){Du(e).dataModel=t})});function _(t,n,i){var a=t.getItemModel(n);$F(t,n,i,e,r);var s=a.getModel(`itemStyle`).getItemStyle();s.fill??=Nb(o,`color`),t.setItemVisual(n,{symbolKeepAspect:a.get(`symbolKeepAspect`),symbolOffset:q(a.get(`symbolOffset`,!0),g[+!i]),symbolRotate:q(a.get(`symbolRotate`,!0),h[+!i]),symbolSize:q(a.get(`symbolSize`),m[+!i]),symbol:q(a.get(`symbol`,!0),p[+!i]),style:s})}this.markKeep(c),c.group.silent=t.get(`silent`)||e.get(`silent`)},t.type=`markLine`,t}(VF);function tI(e,t,n){var r=e?B(e&&e.dimensions,function(e){var n=t.getData();return I(I({},n.getDimensionInfo(n.mapDimension(e))||{}),{name:e,ordinalMeta:null})}):[{name:`value`,type:`float`}],i=new sw(r,n),a=new sw(r,n),o=new sw([],n),s=B(n.get(`data`),H(YF,t,e,n));e&&(s=Ee(s,H(QF,e)));var c=RF(!!e,r);return i.initData(B(s,function(e){return e[0]}),null,c),a.initData(B(s,function(e){return e[1]}),null,c),o.initData(B(s,function(e){return e[2]})),o.hasItemOption=!0,{from:i,to:a,line:o}}function nI(e){e.registerComponentModel(qF),e.registerComponentView(eI),e.registerPreprocessor(function(e){TF(e.series,`markLine`)&&(e.markLine=e.markLine||{})})}var rI=function(e,t){if(t===`all`)return{type:`all`,title:e.getLocaleModel().get([`legend`,`selector`,`all`])};if(t===`inverse`)return{type:`inverse`,title:e.getLocaleModel().get([`legend`,`selector`,`inverse`])}},iI=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.layoutMode={type:`box`,ignoreSize:!0},n}return t.prototype.init=function(e,t,n){this.mergeDefaultAndTheme(e,n),e.selected=e.selected||{},this._updateSelector(e)},t.prototype.mergeOption=function(t,n){e.prototype.mergeOption.call(this,t,n),this._updateSelector(t)},t.prototype._updateSelector=function(e){var t=e.selector,n=this.ecModel;t===!0&&(t=e.selector=[`all`,`inverse`]),U(t)&&z(t,function(e,r){G(e)&&(e={type:e}),t[r]=F(e,rI(n,e.type))})},t.prototype.optionUpdated=function(){this._updateData(this.ecModel);var e=this._data;if(e[0]&&this.get(`selectedMode`)===`single`){for(var t=!1,n=0;n<e.length;n++){var r=e[n].get(`name`);if(this.isSelected(r)){this.select(r),t=!0;break}}!t&&this.select(e[0].get(`name`))}},t.prototype._updateData=function(e){var t=[],n=[];e.eachRawSeries(function(r){var i=r.name;n.push(i);var a;if(r.legendVisualProvider){var o=r.legendVisualProvider.getAllNames();e.isSeriesFiltered(r)||(n=n.concat(o)),o.length?t=t.concat(o):a=!0}else a=!0;a&&fs(r)&&t.push(r.name)}),this._availableNames=n;var r=this.get(`data`)||t,i=J(),a=B(r,function(e){return(G(e)||je(e))&&(e={name:e}),i.get(e.name)?null:(i.set(e.name,!0),new Gm(e,this,this.ecModel))},this);this._data=Ee(a,function(e){return!!e})},t.prototype.getData=function(){return this._data},t.prototype.select=function(e){var t=this.option.selected;if(this.get(`selectedMode`)===`single`){var n=this._data;z(n,function(e){t[e.get(`name`)]=!1})}t[e]=!0},t.prototype.unSelect=function(e){this.get(`selectedMode`)!==`single`&&(this.option.selected[e]=!1)},t.prototype.toggleSelected=function(e){var t=this.option.selected;t.hasOwnProperty(e)||(t[e]=!0),this[t[e]?`unSelect`:`select`](e)},t.prototype.allSelect=function(){var e=this._data,t=this.option.selected;z(e,function(e){t[e.get(`name`,!0)]=!0})},t.prototype.inverseSelect=function(){var e=this._data,t=this.option.selected;z(e,function(e){var n=e.get(`name`,!0);t.hasOwnProperty(n)||(t[n]=!0),t[n]=!t[n]})},t.prototype.isSelected=function(e){var t=this.option.selected;return!(t.hasOwnProperty(e)&&!t[e])&&R(this._availableNames,e)>=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`,bottom:Q.size.m,align:`auto`,backgroundColor:Q.color.transparent,borderColor:Q.color.border,borderRadius:0,borderWidth:0,padding:5,itemGap:8,itemWidth:25,itemHeight:14,symbolRotate:`inherit`,symbolKeepAspect:!0,inactiveColor:Q.color.disabled,inactiveBorderColor:Q.color.disabled,inactiveBorderWidth:`auto`,itemStyle:{color:`inherit`,opacity:`inherit`,borderColor:`inherit`,borderWidth:`auto`,borderCap:`inherit`,borderJoin:`inherit`,borderDashOffset:`inherit`,borderMiterLimit:`inherit`},lineStyle:{width:`auto`,color:`inherit`,inactiveColor:Q.color.disabled,inactiveWidth:2,opacity:`inherit`,type:`inherit`,cap:`inherit`,join:`inherit`,dashOffset:`inherit`,miterLimit:`inherit`},textStyle:{color:Q.color.secondary},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:`sans-serif`,color:Q.color.tertiary,borderWidth:1,borderColor:Q.color.border},emphasis:{selectorLabel:{show:!0,color:Q.color.quaternary}},selectorPosition:`auto`,selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1},triggerEvent:!1},t}(Og),aI=H,oI=z,sI=Ya,cI=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.newlineDisabled=!1,n}return t.prototype.init=function(){this.group.add(this._contentGroup=new sI),this.group.add(this._selectorGroup=new sI),this._isFirstRender=!0},t.prototype.getContentGroup=function(){return this._contentGroup},t.prototype.getSelectorGroup=function(){return this._selectorGroup},t.prototype.render=function(e,t,n){var r=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),e.get(`show`,!0)){var i=e.get(`align`),a=e.get(`orient`);(!i||i===`auto`)&&(i=e.get(`left`)===`right`&&a===`vertical`?`right`:`left`);var o=e.get(`selector`,!0),s=e.get(`selectorPosition`,!0);o&&(!s||s===`auto`)&&(s=a===`horizontal`?`end`:`start`),this.renderInner(i,e,t,n,o,a,s);var c=xg(e,n).refContainer,l=e.getBoxLayoutParams(),u=e.get(`padding`),d=yg(l,c,u),f=this.layoutInner(e,i,d,r,o,s),p=yg(L({width:f.width,height:f.height},l),c,u);this.group.x=p.x-f.x,this.group.y=p.y-f.y,this.group.markRedraw(),this.group.add(this._backgroundEl=JN(f,e))}},t.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},t.prototype.renderInner=function(e,t,n,r,i,a,o){var s=this.getContentGroup(),c=J(),l=t.get(`selectedMode`),u=t.get(`triggerEvent`),d=[];n.eachRawSeries(function(e){!e.get(`legendHoverLink`)&&d.push(e.id)}),oI(t.getData(),function(i,a){var o=this,f=i.get(`name`);if(!this.newlineDisabled&&(f===``||f===`
`)){var p=new sI;p.newline=!0,s.add(p);return}var m=n.getSeriesByName(f)[0];if(!c.get(f))if(m){var h=m.getData(),g=h.getVisual(`legendLineStyle`)||{},_=h.getVisual(`legendIcon`),v=h.getVisual(`style`),y=this._createItem(m,f,a,i,t,e,g,v,_,l,r);y.on(`click`,aI(dI,f,null,r,d)).on(`mouseover`,aI(fI,m.name,null,r,d)).on(`mouseout`,aI(pI,m.name,null,r,d)),n.ssr&&y.eachChild(function(e){var t=Du(e);t.seriesIndex=m.seriesIndex,t.dataIndex=a,t.ssrType=`legend`}),u&&y.eachChild(function(e){o.packEventData(e,t,m,a,f)}),c.set(f,!0)}else n.eachRawSeries(function(o){var s=this;if(!c.get(f)&&o.legendVisualProvider){var p=o.legendVisualProvider;if(!p.containName(f))return;var m=p.indexOfName(f),h=p.getItemVisual(m,`style`),g=p.getItemVisual(m,`legendIcon`),_=Qr(h.fill);_&&_[3]===0&&(_[3]=.2,h=I(I({},h),{fill:ii(_,`rgba`)}));var v=this._createItem(o,f,a,i,t,e,{},h,g,l,r);v.on(`click`,aI(dI,null,f,r,d)).on(`mouseover`,aI(fI,null,f,r,d)).on(`mouseout`,aI(pI,null,f,r,d)),n.ssr&&v.eachChild(function(e){var t=Du(e);t.seriesIndex=o.seriesIndex,t.dataIndex=a,t.ssrType=`legend`}),u&&v.eachChild(function(e){s.packEventData(e,t,o,a,f)}),c.set(f,!0)}},this)},this),i&&this._createSelector(i,t,r,a,o)},t.prototype.packEventData=function(e,t,n,r,i){var a={componentType:`legend`,componentIndex:t.componentIndex,dataIndex:r,value:i,seriesIndex:n.seriesIndex};Du(e).eventData=a},t.prototype._createSelector=function(e,t,n,r,i){var a=this.getSelectorGroup();oI(e,function(e){var r=e.type,i=new pu({style:{x:0,y:0,align:`center`,verticalAlign:`middle`},onclick:function(){n.dispatchAction({type:r===`all`?`legendAllSelect`:`legendInverseSelect`,legendId:t.id})}});a.add(i),Sm(i,{normal:t.getModel(`selectorLabel`),emphasis:t.getModel([`emphasis`,`selectorLabel`])},{defaultText:e.title}),Pd(i)})},t.prototype._createItem=function(e,t,n,r,i,a,o,s,c,l,u){var d=e.visualDrawType,f=i.get(`itemWidth`),p=i.get(`itemHeight`),m=i.isSelected(t),h=r.get(`symbolRotate`),g=r.get(`symbolKeepAspect`),_=r.get(`icon`);c=_||c||`roundRect`;var v=lI(c,r,o,s,d,m,u),y=new sI,b=r.getModel(`textStyle`);if(W(e.getLegendIcon)&&(!_||_===`inherit`))y.add(e.getLegendIcon({itemWidth:f,itemHeight:p,icon:c,iconRotate:h,itemStyle:v.itemStyle,lineStyle:v.lineStyle,symbolKeepAspect:g}));else{var x=_===`inherit`&&e.getData().getVisual(`symbol`)?h===`inherit`?e.getData().getVisual(`symbolRotate`):h:0;y.add(uI({itemWidth:f,itemHeight:p,icon:c,iconRotate:x,itemStyle:v.itemStyle,lineStyle:v.lineStyle,symbolKeepAspect:g}))}var S=a===`left`?f+5:-5,C=a,w=i.get(`formatter`),T=t;G(w)&&w?T=w.replace(`{name}`,t??``):W(w)&&(T=w(t));var E=m?b.getTextColor():r.get(`inactiveColor`);y.add(new pu({style:wm(b,{text:T,x:S,y:p/2,fill:E,align:C,verticalAlign:`middle`},{inheritColor:E})}));var D=new cu({shape:y.getBoundingRect(),style:{fill:`transparent`}}),O=r.getModel(`tooltip`);return O.get(`show`)&&im({el:D,componentModel:i,itemName:t,itemTooltipOption:O.option}),y.add(D),y.eachChild(function(e){e.silent=!0}),D.silent=!l,this.getContentGroup().add(y),Pd(y),y.__legendDataIndex=n,y},t.prototype.layoutInner=function(e,t,n,r,i,a){var o=this.getContentGroup(),s=this.getSelectorGroup();_g(e.get(`orient`),o,e.get(`itemGap`),n.width,n.height);var c=o.getBoundingRect(),l=[-c.x,-c.y];if(s.markRedraw(),o.markRedraw(),i){_g(`horizontal`,s,e.get(`selectorItemGap`,!0));var u=s.getBoundingRect(),d=[-u.x,-u.y],f=e.get(`selectorButtonGap`,!0),p=e.getOrient().index,m=p===0?`width`:`height`,h=p===0?`height`:`width`,g=p===0?`y`:`x`;a===`end`?d[p]+=c[m]+f:l[p]+=u[m]+f,d[1-p]+=c[h]/2-u[h]/2,s.x=d[0],s.y=d[1],o.x=l[0],o.y=l[1];var _={x:0,y:0};return _[m]=c[m]+f+u[m],_[h]=Math.max(c[h],u[h]),_[g]=Math.min(0,u[g]+d[1-p]),_}else return o.x=l[0],o.y=l[1],this.group.getBoundingRect()},t.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},t.type=`legend.plain`,t}(Fy);function lI(e,t,n,r,i,a,o){function s(e,t){e.lineWidth===`auto`&&(e.lineWidth=t.lineWidth>0?2:0),oI(e,function(n,r){e[r]===`inherit`&&(e[r]=t[r])})}var c=t.getModel(`itemStyle`),l=c.getItemStyle(),u=e.lastIndexOf(`empty`,0)===0?`fill`:`stroke`,d=c.getShallow(`decal`);l.decal=!d||d===`inherit`?r.decal:qx(d,o),l.fill===`inherit`&&(l.fill=r[i]),l.stroke===`inherit`&&(l.stroke=r[u]),l.opacity===`inherit`&&(l.opacity=(i===`fill`?r:n).opacity),s(l,r);var f=t.getModel(`lineStyle`),p=f.getLineStyle();if(s(p,n),l.fill===`auto`&&(l.fill=r.fill),l.stroke===`auto`&&(l.stroke=r.fill),p.stroke===`auto`&&(p.stroke=r.fill),!a){var m=t.get(`inactiveBorderWidth`),h=l[u];l.lineWidth=m===`auto`?r.lineWidth>0&&h?2:0:l.lineWidth,l.fill=t.get(`inactiveColor`),l.stroke=t.get(`inactiveBorderColor`),p.stroke=f.get(`inactiveColor`),p.lineWidth=f.get(`inactiveWidth`)}return{itemStyle:l,lineStyle:p}}function uI(e){var t=e.icon||`roundRect`,n=rx(t,0,0,e.itemWidth,e.itemHeight,e.itemStyle.fill,e.symbolKeepAspect);return n.setStyle(e.itemStyle),n.rotation=(e.iconRotate||0)*Math.PI/180,n.setOrigin([e.itemWidth/2,e.itemHeight/2]),t.indexOf(`empty`)>-1&&(n.style.stroke=n.style.fill,n.style.fill=Q.color.neutral00,n.style.lineWidth=2),n}function dI(e,t,n,r){pI(e,t,n,r),n.dispatchAction({type:`legendToggleSelect`,name:e??t}),fI(e,t,n,r)}function fI(e,t,n,r){n.usingTHL()||n.dispatchAction({type:`highlight`,seriesName:e,name:t,excludeSeriesId:r})}function pI(e,t,n,r){n.usingTHL()||n.dispatchAction({type:`downplay`,seriesName:e,name:t,excludeSeriesId:r})}function mI(e,t,n){var r=e===`allSelect`||e===`inverseSelect`,i={},a=[];n.eachComponent({mainType:`legend`,query:t},function(n){r?n[e]():n[e](t.name),hI(n,i),a.push(n.componentIndex)});var o={};return n.eachComponent(`legend`,function(e){z(i,function(t,n){e[t?`select`:`unSelect`](n)}),hI(e,o)}),r?{selected:o,legendIndex:a}:{name:t.name,selected:o}}function hI(e,t){var n=t||{};return z(e.getData(),function(t){var r=t.get(`name`);if(!(r===`
`||r===``)){var i=e.isSelected(r);et(n,r)?n[r]=n[r]&&i:n[r]=i}}),n}function gI(e){e.registerAction(`legendToggleSelect`,`legendselectchanged`,H(mI,`toggleSelected`)),e.registerAction(`legendAllSelect`,`legendselectall`,H(mI,`allSelect`)),e.registerAction(`legendInverseSelect`,`legendinverseselect`,H(mI,`inverseSelect`)),e.registerAction(`legendSelect`,`legendselected`,H(mI,`select`)),e.registerAction(`legendUnSelect`,`legendunselected`,H(mI,`unSelect`))}var _I=Gs(vI);function vI(e){var t=e.findComponents({mainType:`legend`});t&&t.length&&e.filterSeries(function(e){for(var n=0;n<t.length;n++)if(!t[n].isSelected(e.name))return!1;return!0})}function yI(e){e.registerComponentModel(iI),e.registerComponentView(cI),e.registerProcessor(e.PRIORITY.PROCESSOR.SERIES_FILTER,_I),e.registerSubTypeDefaulter(`legend`,function(){return`plain`}),gI(e)}var bI=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.prototype.setScrollDataIndex=function(e){this.option.scrollDataIndex=e},t.prototype.init=function(t,n,r){var i=Tg(t);e.prototype.init.call(this,t,n,r),xI(this,t,i)},t.prototype.mergeOption=function(t,n){e.prototype.mergeOption.call(this,t,n),xI(this,this.option,t)},t.type=`legend.scroll`,t.defaultOption=Xm(iI.defaultOption,{scrollDataIndex:0,pageButtonItemGap:5,pageButtonGap:null,pageButtonPosition:`end`,pageFormatter:`{current}/{total}`,pageIcons:{horizontal:[`M0,0L12,-10L12,10z`,`M0,0L-12,-10L-12,10z`],vertical:[`M0,0L20,0L10,-20z`,`M0,0L20,0L10,20z`]},pageIconColor:Q.color.accent50,pageIconInactiveColor:Q.color.accent10,pageIconSize:15,pageTextStyle:{color:Q.color.tertiary},animationDurationUpdate:800}),t}(iI);function xI(e,t,n){var r=e.getOrient(),i=[1,1];i[r.index]=0,wg(t,n,{type:`box`,ignoreSize:!!i})}var SI=Ya,CI=[`width`,`height`],wI=[`x`,`y`],TI=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n.newlineDisabled=!0,n._currentIndex=0,n}return t.prototype.init=function(){e.prototype.init.call(this),this.group.add(this._containerGroup=new SI),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new SI)},t.prototype.resetInner=function(){e.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},t.prototype.renderInner=function(t,n,r,i,a,o,s){var c=this;e.prototype.renderInner.call(this,t,n,r,i,a,o,s);var l=this._controllerGroup,u=n.get(`pageIconSize`,!0),d=U(u)?u:[u,u];p(`pagePrev`,0);var f=n.getModel(`pageTextStyle`);l.add(new pu({name:`pageText`,style:{text:`xx/xx`,fill:f.getTextColor(),font:f.getFont(),verticalAlign:`middle`,align:`center`},silent:!0})),p(`pageNext`,1);function p(e,t){var r=e+`DataIndex`,a=Xp(n.get(`pageIcons`,!0)[n.getOrient().name][t],{onclick:V(c._pageGo,c,r,n,i)},{x:-d[0]/2,y:-d[1]/2,width:d[0],height:d[1]});a.name=e,l.add(a)}},t.prototype.layoutInner=function(e,t,n,r,i,a){var o=this.getSelectorGroup(),s=e.getOrient().index,c=CI[s],l=wI[s],u=CI[1-s],d=wI[1-s];i&&_g(`horizontal`,o,e.get(`selectorItemGap`,!0));var f=e.get(`selectorButtonGap`,!0),p=o.getBoundingRect(),m=[-p.x,-p.y],h=P(n);i&&(h[c]=n[c]-p[c]-f);var g=this._layoutContentAndController(e,r,h,s,c,u,d,l);if(i){if(a===`end`)m[s]+=g[c]+f;else{var _=p[c]+f;m[s]-=_,g[l]-=_}g[c]+=p[c]+f,m[1-s]+=g[d]+g[u]/2-p[u]/2,g[u]=Math.max(g[u],p[u]),g[d]=Math.min(g[d],p[d]+m[1-s]),o.x=m[0],o.y=m[1],o.markRedraw()}return g},t.prototype._layoutContentAndController=function(e,t,n,r,i,a,o,s){var c=this.getContentGroup(),l=this._containerGroup,u=this._controllerGroup;_g(e.get(`orient`),c,e.get(`itemGap`),r?n.width:null,r?null:n.height),_g(`horizontal`,u,e.get(`pageButtonItemGap`,!0));var d=c.getBoundingRect(),f=u.getBoundingRect(),p=this._showController=d[i]>n[i],m=[-d.x,-d.y];t||(m[r]=c[s]);var h=[0,0],g=[-f.x,-f.y],_=q(e.get(`pageButtonGap`,!0),e.get(`itemGap`,!0));p&&(e.get(`pageButtonPosition`,!0)===`end`?g[r]+=n[i]-f[i]:h[r]+=f[i]+_),g[1-r]+=d[a]/2-f[a]/2,c.setPosition(m),l.setPosition(h),u.setPosition(g);var v={x:0,y:0};if(v[i]=p?n[i]:d[i],v[a]=Math.max(d[a],f[a]),v[o]=Math.min(0,f[o]+g[1-r]),l.__rectSize=n[i],p){var y={x:0,y:0};y[i]=Math.max(n[i]-f[i]-_,0),y[a]=v[a],l.setClipPath(new cu({shape:y})),l.__rectSize=y[i]}else u.eachChild(function(e){e.attr({invisible:!0,silent:!0})});var b=this._getPageInfo(e);return b.pageIndex!=null&&vp(c,{x:b.contentPosition[0],y:b.contentPosition[1]},p?e:null),this._updatePageInfoView(e,b),v},t.prototype._pageGo=function(e,t,n){var r=this._getPageInfo(t)[e];r!=null&&n.dispatchAction({type:`legendScroll`,scrollDataIndex:r,legendId:t.id})},t.prototype._updatePageInfoView=function(e,t){var n=this._controllerGroup;z([`pagePrev`,`pageNext`],function(r){var i=t[r+`DataIndex`]!=null,a=n.childOfName(r);a&&(a.setStyle(`fill`,i?e.get(`pageIconColor`,!0):e.get(`pageIconInactiveColor`,!0)),a.cursor=i?`pointer`:`default`)});var r=n.childOfName(`pageText`),i=e.get(`pageFormatter`),a=t.pageIndex,o=a==null?0:a+1,s=t.pageCount;r&&i&&r.setStyle(`text`,G(i)?i.replace(`{current}`,o==null?``:o+``).replace(`{total}`,s==null?``:s+``):i({current:o,total:s}))},t.prototype._getPageInfo=function(e){var t=e.get(`scrollDataIndex`,!0),n=this.getContentGroup(),r=this._containerGroup.__rectSize,i=e.getOrient().index,a=CI[i],o=wI[i],s=this._findTargetItemIndex(t),c=n.children(),l=c[s],u=c.length,d=+!!u,f={contentPosition:[n.x,n.y],pageCount:d,pageIndex:d-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!l)return f;var p=v(l);f.contentPosition[i]=-p.s;for(var m=s+1,h=p,g=p,_=null;m<=u;++m)_=v(c[m]),(!_&&g.e>h.s+r||_&&!y(_,h.s))&&(h=g.i>h.i?g:_,h&&(f.pageNextDataIndex??=h.i,++f.pageCount)),g=_;for(var m=s-1,h=p,g=p,_=null;m>=-1;--m)_=v(c[m]),(!_||!y(g,_.s))&&h.i<g.i&&(g=h,f.pagePrevDataIndex??=h.i,++f.pageCount,++f.pageIndex),h=_;return f;function v(e){if(e){var t=e.getBoundingRect(),n=t[o]+e[o];return{s:n,e:n+t[a],i:e.__legendDataIndex}}}function y(e,t){return e.e>=t&&e.s<=t+r}},t.prototype._findTargetItemIndex=function(e){if(!this._showController)return 0;var t,n=this.getContentGroup(),r;return n.eachChild(function(n,i){var a=n.__legendDataIndex;r==null&&a!=null&&(r=i),a===e&&(t=i)}),t??r},t.type=`legend.scroll`,t}(cI);function EI(e){e.registerAction(`legendScroll`,`legendscroll`,function(e,t){var n=e.scrollDataIndex;n!=null&&t.eachComponent({mainType:`legend`,subType:`scroll`,query:e},function(e){e.setScrollDataIndex(n)})})}function DI(e){TE(yI),e.registerComponentModel(bI),e.registerComponentView(TI),EI(e)}function OI(e){TE(yI),TE(DI)}var kI=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.type=`dataZoom.inside`,t.defaultOption=Xm(MN.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),t}(MN),AI=Z();function jI(e,t,n){AI(e).coordSysRecordMap.each(function(e){var r=e.dataZoomInfoMap.get(t.uid);r&&(r.getRange=n)})}function MI(e,t){for(var n=AI(e).coordSysRecordMap,r=n.keys(),i=0;i<r.length;i++){var a=r[i],o=n.get(a),s=o.dataZoomInfoMap;if(s){var c=t.uid;s.get(c)&&(s.removeKey(c),s.keys().length||NI(n,o))}}}function NI(e,t){if(t){e.removeKey(t.model.uid);var n=t.controller;n&&n.dispose()}}function PI(e,t){var n={model:t,containsPoint:H(II,t),dispatchAction:H(FI,e),dataZoomInfoMap:null,controller:null},r=n.controller=new UA(e.getZr());return z([`pan`,`zoom`,`scrollMove`],function(e){r.on(e,function(t){var r=[];n.dataZoomInfoMap.each(function(i){if(t.isAvailableBehavior(i.model.option)){var a=(i.getRange||{})[e],o=a&&a(i.dzReferCoordSysInfo,n.model.mainType,n.controller,t);!i.model.get(`disabled`,!0)&&o&&r.push({dataZoomId:i.model.id,start:o[0],end:o[1]})}}),r.length&&n.dispatchAction(r)})}),n}function FI(e,t){e.isDisposed()||e.dispatchAction({type:`dataZoom`,animation:{easing:`cubicOut`,duration:100},batch:t})}function II(e,t,n,r){return e.coordinateSystem.containPoint([n,r])}function LI(e,t,n){var r,i=`type_`,a={type_true:2,type_move:1,type_false:0,type_undefined:-1},o=!0,s,c;return e.each(function(e){var t=e.model,n=t.get(`disabled`,!0)?!1:t.get(`zoomLock`,!0)?`move`:!0;a[i+n]>a[i+r]&&(r=n),o&&=t.get(`preventDefaultMouseMove`,!0),s=q(t.get(`cursorGrab`,!0),s),c=q(t.get(`cursorGrabbing`,!0),c)}),{controlType:r,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!o,api:n,zInfo:{component:t.model},triggerInfo:{roamTrigger:null,isInSelf:t.containsPoint},cursorGrab:s,cursorGrabbing:c}}}function RI(e){e.registerUpdateLifecycle(`coordsys:aftercreate`,function(e,t){var n=AI(t),r=n.coordSysRecordMap||=J();r.each(function(e){e.dataZoomInfoMap=null}),e.eachComponent({mainType:`dataZoom`,subType:`inside`},function(e){z(EN(e).infoList,function(n){var i=n.model.uid,a=r.get(i)||r.set(i,PI(t,n.model));(a.dataZoomInfoMap||=J()).set(e.uid,{dzReferCoordSysInfo:n,model:e,getRange:null})})}),r.each(function(e){var n=e.controller,i,a=e.dataZoomInfoMap;if(a){var o=a.keys()[0];o!=null&&(i=a.get(o))}if(!i){NI(r,e);return}var s=LI(a,e,t);n.enable(s.controlType,s.opt),Yy(e,`dispatchAction`,i.model.get(`throttle`,!0),`fixRate`)})})}var zI=function(e){k(t,e);function t(){var t=e!==null&&e.apply(this,arguments)||this;return t.type=`dataZoom.inside`,t}return t.prototype.render=function(t,n,r){if(e.prototype.render.apply(this,arguments),t.noTarget()){this._clear();return}this.range=t.getPercentRange(),jI(r,t,{pan:V(BI.pan,this),zoom:V(BI.zoom,this),scrollMove:V(BI.scrollMove,this)})},t.prototype.dispose=function(){this._clear(),e.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){MI(this.api,this.dataZoomModel),this.range=null},t.type=`dataZoom.inside`,t}(FN),BI={zoom:function(e,t,n,r){var i=this.range,a=i.slice(),o=e.axisModels[0];if(o){var s=HI[t](null,[r.originX,r.originY],o,n,e),c=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(a[1]-a[0])+a[0],l=Math.max(1/r.scale,0);a[0]=(a[0]-c)*l+c,a[1]=(a[1]-c)*l+c;var u=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(Cj(0,a,[0,100],0,u.minSpan,u.maxSpan),this.range=a,i[0]!==a[0]||i[1]!==a[1])return a}},pan:VI(function(e,t,n,r,i,a){var o=HI[r]([a.oldX,a.oldY],[a.newX,a.newY],t,i,n);return o.signal*(e[1]-e[0])*o.pixel/o.pixelLength}),scrollMove:VI(function(e,t,n,r,i,a){return HI[r]([0,0],[a.scrollDelta,a.scrollDelta],t,i,n).signal*(e[1]-e[0])*a.scrollDelta})};function VI(e){return function(t,n,r,i){var a=this.range,o=a.slice(),s=t.axisModels[0];if(s&&(Cj(e(o,s,t,n,r,i),o,[0,100],`all`),this.range=o,a[0]!==o[0]||a[1]!==o[1]))return o}}var HI={grid:function(e,t,n,r,i){var a=n.axis,o={},s=i.model.coordinateSystem.getRect();return e||=[0,0],a.dim===`x`?(o.pixel=t[0]-e[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=a.inverse?1:-1):(o.pixel=t[1]-e[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=a.inverse?-1:1),o},polar:function(e,t,n,r,i){var a=n.axis,o={},s=i.model.coordinateSystem,c=s.getRadiusAxis().getExtent(),l=s.getAngleAxis().getExtent();return e=e?s.pointToCoord(e):[0,0],t=s.pointToCoord(t),n.mainType===`radiusAxis`?(o.pixel=t[0]-e[0],o.pixelLength=c[1]-c[0],o.pixelStart=c[0],o.signal=a.inverse?1:-1):(o.pixel=t[1]-e[1],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=a.inverse?-1:1),o},singleAxis:function(e,t,n,r,i){var a=n.axis,o=i.model.coordinateSystem.getRect(),s={};return e||=[0,0],a.orient===`horizontal`?(s.pixel=t[0]-e[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=a.inverse?1:-1):(s.pixel=t[1]-e[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=a.inverse?-1:1),s}};function UI(e){VN(e),e.registerComponentModel(kI),e.registerComponentView(zI),RI(e)}var WI=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n}return t.type=`dataZoom.slider`,t.layoutMode=`box`,t.defaultOption=Xm(MN.defaultOption,{show:!0,right:`ph`,top:`ph`,width:`ph`,height:`ph`,left:null,bottom:null,borderColor:Q.color.accent10,borderRadius:0,backgroundColor:Q.color.transparent,dataBackground:{lineStyle:{color:Q.color.accent30,width:.5},areaStyle:{color:Q.color.accent20,opacity:.2}},selectedDataBackground:{lineStyle:{color:Q.color.accent40,width:.5},areaStyle:{color:Q.color.accent20,opacity:.3}},fillerColor:`rgba(135,175,274,0.2)`,handleIcon:`path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z`,handleSize:`100%`,handleStyle:{color:Q.color.neutral00,borderColor:Q.color.accent20},moveHandleSize:7,moveHandleIcon:`path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z`,moveHandleStyle:{color:Q.color.accent40,opacity:.5},showDetail:!0,showDataShadow:`auto`,realtime:!0,zoomLock:!1,textStyle:{color:Q.color.tertiary},brushSelect:!0,brushStyle:{color:Q.color.accent30,opacity:.3},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:Q.color.accent40},moveHandleStyle:{opacity:.8}},defaultLocationEdgeGap:15}),t}(MN),GI=cu,KI=1,qI=30,JI=7,YI=`horizontal`,XI=`vertical`,ZI=5,QI=[`line`,`bar`,`candlestick`,`scatter`],$I={easing:`cubicOut`,duration:100,delay:0},eL=function(e){k(t,e);function t(){var n=e!==null&&e.apply(this,arguments)||this;return n.type=t.type,n._displayables={},n}return t.prototype.init=function(e,t){this.api=t,this._onBrush=V(this._onBrush,this),this._onBrushEnd=V(this._onBrushEnd,this)},t.prototype.render=function(t,n,r,i){if(e.prototype.render.apply(this,arguments),Yy(this,`_dispatchZoomAction`,t.get(`throttle`),`fixRate`),this._orient=t.getOrient(),t.get(`show`)===!1){this.group.removeAll();return}if(t.noTarget()){this._clear(),this.group.removeAll();return}(!i||i.type!==`dataZoom`||i.from!==this.uid)&&this._buildView(),this._updateView()},t.prototype.dispose=function(){this._clear(),e.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){Xy(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 t=this._displayables.sliderGroup=new Ya;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),e.add(t),this._positionGroup()},t.prototype._resetLocation=function(){var e=this.dataZoomModel,t=this.api,n=e.get(`brushSelect`)?JI:0,r=xg(e,t).refContainer,i=this._findCoordRect(),a=e.get(`defaultLocationEdgeGap`,!0)||0,o=this._orient===YI?{right:r.width-i.x-i.width,top:r.height-qI-a-n,width:i.width,height:qI}:{right:a,top:i.y,width:qI,height:i.height},s=Tg(e.option);z([`right`,`top`,`width`,`height`],function(e){s[e]===`ph`&&(s[e]=o[e])});var c=yg(s,r);this._location={x:c.x,y:c.y},this._size=[c.width,c.height],this._orient===XI&&this._size.reverse()},t.prototype._positionGroup=function(){var e=this.group,t=this._location,n=this._orient,r=this.dataZoomModel.getFirstTargetAxisModel(),i=r&&r.get(`inverse`),a=this._displayables.sliderGroup,o=(this._dataShadowInfo||{}).otherAxisInverse;a.attr(n===YI&&!i?{scaleY:o?1:-1,scaleX:1}:n===YI&&i?{scaleY:o?1:-1,scaleX:-1}:n===XI&&!i?{scaleY:o?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:o?-1:1,scaleX:-1,rotation:Math.PI/2});var s=e.getBoundingRect([a]),c=isNaN(s.x)?0:s.x,l=isNaN(s.y)?0:s.y;e.x=t.x-c,e.y=t.y-l,e.markRedraw()},t.prototype._getViewExtent=function(){return[0,this._size[0]]},t.prototype._renderBackground=function(){var e=this.dataZoomModel,t=this._size,n=this._displayables.sliderGroup,r=e.get(`brushSelect`);n.add(new GI({silent:!0,shape:{x:0,y:0,width:t[0],height:t[1]},style:{fill:e.get(`backgroundColor`)},z2:-40}));var i=new GI({shape:{x:0,y:0,width:t[0],height:t[1]},style:{fill:`transparent`},z2:0,onclick:V(this._onClickPanel,this)}),a=this.api.getZr();r?(i.on(`mousedown`,this._onBrushStart,this),i.cursor=`crosshair`,a.on(`mousemove`,this._onBrush),a.on(`mouseup`,this._onBrushEnd)):(a.off(`mousemove`,this._onBrush),a.off(`mouseup`,this._onBrushEnd)),n.add(i)},t.prototype._renderDataShadow=function(){var e=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!e)return;var t=this._size,n=this._shadowSize||[],r=e.series,i=r.getRawData(),a=r.getShadowDim&&r.getShadowDim(),o=a&&i.getDimensionInfo(a)?r.getShadowDim():e.otherDim;if(o==null)return;var s=this._shadowPolygonPts,c=this._shadowPolylinePts;if(i!==this._shadowData||o!==this._shadowDim||t[0]!==n[0]||t[1]!==n[1]){var l=i.getDataExtent(e.thisDim),u=i.getDataExtent(o),d=(u[1]-u[0])*.3;u=[u[0]-d,u[1]+d];var f=[0,t[1]],p=[0,t[0]],m=[[t[0],0],[0,0]],h=[],g=p[1]/Math.max(1,i.count()-1),_=t[0]/(l[1]-l[0]),v=e.thisAxis.type===`time`,y=-g,b=Math.round(i.count()/t[0]),x;i.each([e.thisDim,o],function(e,t,n){if(b>0&&n%b){v||(y+=g);return}y=v?(+e-l[0])*_:y+g;var r=t==null||isNaN(t)||t===``,i=r?0:vo(t,u,f,!0);r&&!x&&n?(m.push([m[m.length-1][0],0]),h.push([h[h.length-1][0],0])):!r&&x&&(m.push([y,0]),h.push([y,0])),r||(m.push([y,i]),h.push([y,i])),x=r}),s=this._shadowPolygonPts=m,c=this._shadowPolylinePts=h}this._shadowData=i,this._shadowDim=o,this._shadowSize=[t[0],t[1]];var S=this.dataZoomModel;function C(e){var t=S.getModel(e?`selectedDataBackground`:`dataBackground`),n=new Ya,r=new Hf({shape:{points:s},segmentIgnoreThreshold:1,style:t.getModel(`areaStyle`).getAreaStyle(),silent:!0,z2:-20}),i=new Wf({shape:{points:c},segmentIgnoreThreshold:1,style:t.getModel(`lineStyle`).getLineStyle(),silent:!0,z2:-19});return n.add(r),n.add(i),n}for(var w=0;w<3;w++){var T=C(w===1);this._displayables.sliderGroup.add(T),this._displayables.dataShadowSegs.push(T)}},t.prototype._prepareDataShadowInfo=function(){var e=this.dataZoomModel,t=e.get(`showDataShadow`);if(t!==!1){var n,r=this.ecModel;return e.eachTargetAxis(function(i,a){z(e.getAxisProxy(i,a).getTargetSeriesModels(),function(e){if(!n&&!(t!==!0&&R(QI,e.get(`type`))<0)){var o=r.getComponent(wN(i),a).axis,s=nL(i),c,l=e.coordinateSystem;s!=null&&l.getOtherAxis&&(c=l.getOtherAxis(o).inverse),s=e.getData().mapDimension(s),n={thisAxis:o,series:e,thisDim:e.getData().mapDimension(i),otherDim:s,otherAxisInverse:c}}},this)},this),n}},t.prototype._renderHandle=function(){var e=this.group,t=this._displayables,n=t.handles=[null,null],r=t.handleLabels=[null,null],i=this._displayables.sliderGroup,a=this._size,o=this.dataZoomModel,s=this.api,c=o.get(`borderRadius`)||0,l=o.get(`brushSelect`),u=t.filler=new GI({silent:l,style:{fill:o.get(`fillerColor`)},textConfig:{position:`inside`}});i.add(u),i.add(new GI({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:a[0],height:a[1],r:c},style:{stroke:o.get(`dataBackgroundColor`)||o.get(`borderColor`),lineWidth:KI,fill:Q.color.transparent}})),z([0,1],function(t){var a=o.get(`handleIcon`);!ex[a]&&a.indexOf(`path://`)<0&&a.indexOf(`image://`)<0&&(a=`path://`+a);var s=rx(a,-1,0,2,2,null,!0);s.attr({cursor:rL(this._orient),draggable:!0,drift:V(this._onDragMove,this,t),ondragend:V(this._onDragEnd,this),onmouseover:V(this._onOverDataInfoTriggerArea,this,!0),onmouseout:V(this._onOverDataInfoTriggerArea,this,!1),z2:5});var c=s.getBoundingRect(),l=o.get(`handleSize`);this._handleHeight=yo(l,this._size[1]),this._handleWidth=c.width/c.height*this._handleHeight,s.setStyle(o.getModel(`handleStyle`).getItemStyle()),s.style.strokeNoScale=!0,s.rectHover=!0,s.ensureState(`emphasis`).style=o.getModel([`emphasis`,`handleStyle`]).getItemStyle(),Pd(s);var u=o.get(`handleColor`);u!=null&&(s.style.fill=u),i.add(n[t]=s);var d=o.getModel(`textStyle`),f=(o.get(`handleLabel`)||{}).show||!1;e.add(r[t]=new pu({silent:!0,invisible:!f,style:wm(d,{x:0,y:0,text:``,verticalAlign:`middle`,align:`center`,fill:d.getTextColor(),font:d.getFont()}),z2:10}))},this);var d=u;if(l){var f=yo(o.get(`moveHandleSize`),a[1]),p=t.moveHandle=new cu({style:o.getModel(`moveHandleStyle`).getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:a[1]-.5,height:f}}),m=f*.8,h=t.moveHandleIcon=rx(o.get(`moveHandleIcon`),-m/2,-m/2,m,m,Q.color.neutral00,!0);h.silent=!0,h.y=a[1]+f/2-.5,p.ensureState(`emphasis`).style=o.getModel([`emphasis`,`moveHandleStyle`]).getItemStyle();var g=Math.min(a[1]/2,Math.max(f,10));d=t.moveZone=new cu({invisible:!0,shape:{y:a[1]-g,height:f+g}}),d.on(`mouseover`,function(){s.enterEmphasis(p)}).on(`mouseout`,function(){s.leaveEmphasis(p)}),i.add(p),i.add(h),i.add(d)}d.attr({draggable:!0,cursor:`grab`,drift:V(this._onActualMoveZoneDrift,this),ondragstart:V(this._onActualMoveZoneDragStart,this),ondragend:V(this._onActualMoveZoneDragEnd,this),onmouseover:V(this._onOverDataInfoTriggerArea,this,!0),onmouseout:V(this._onOverDataInfoTriggerArea,this,!1)})},t.prototype._resetInterval=function(){var e=this._range=this.dataZoomModel.getPercentRange(),t=this._getViewExtent();this._handleEnds=[vo(e[0],[0,100],t,!0),vo(e[1],[0,100],t,!0)]},t.prototype._updateInterval=function(e,t){var n=this.dataZoomModel,r=this._handleEnds,i=this._getViewExtent(),a=n.findRepresentativeAxisProxy().getMinMaxSpan(),o=[0,100];Cj(t,r,i,n.get(`zoomLock`)?`all`:e,a.minSpan==null?null:vo(a.minSpan,o,i,!0),a.maxSpan==null?null:vo(a.maxSpan,o,i,!0));var s=this._range,c=this._range=Co([vo(r[0],i,o,!0),vo(r[1],i,o,!0)]);return!s||s[0]!==c[0]||s[1]!==c[1]},t.prototype._updateView=function(e){var t=this._displayables,n=this._handleEnds,r=Co(n.slice()),i=this._size;z([0,1],function(e){var r=t.handles[e],a=this._handleHeight;r.attr({scaleX:a/2,scaleY:a/2,x:n[e]+(e?-1:1),y:i[1]/2-a/2})},this),t.filler.setShape({x:r[0],y:0,width:r[1]-r[0],height:i[1]});var a={x:r[0],width:r[1]-r[0]};t.moveHandle&&(t.moveHandle.setShape(a),t.moveZone.setShape(a),t.moveZone.getBoundingRect(),t.moveHandleIcon&&t.moveHandleIcon.attr(`x`,a.x+a.width/2));for(var o=t.dataShadowSegs,s=[0,r[0],r[1],i[0]],c=0;c<o.length;c++){var l=o[c],u=l.getClipPath();u||(u=new cu,l.setClipPath(u)),u.setShape({x:s[c],y:0,width:s[c+1]-s[c],height:i[1]})}this._updateDataInfo(e)},t.prototype._updateDataInfo=function(e){var t=this.dataZoomModel,n=this._displayables,r=n.handleLabels,i=this._orient,a=[``,``];if(t.get(`showDetail`)){var o=t.findRepresentativeAxisProxy(),s=o.getAxisModel().axis.scale;if(o){var c=this._range,l;if(e){var u={start:c[0],end:c[1]},d=AN(t,o);if(d){var f=d.calculateDataWindow(u).percentInverted;u={start:f[0],end:f[1]}}l=o.calculateDataWindow(u)}else l=o.getWindow();a=[tL(t,0,l,s),tL(t,1,l,s)]}}var p=Co(this._handleEnds.slice());m.call(this,0),m.call(this,1);function m(e){var t=Hp(n.handles[e].parent,this.group),o=Wp(e===0?`right`:`left`,t),s=this._handleWidth/2+ZI,c=Up([p[e]+(e===0?-s:s),this._size[1]/2],t);r[e].setStyle({x:c[0],y:c[1],verticalAlign:i===YI?`middle`:o,align:i===YI?o:`center`,text:a[e]})}},t.prototype._onOverDataInfoTriggerArea=function(e){this._isOverDataInfoTriggerArea=e,this._showDataInfo(e)},t.prototype._showDataInfo=function(e){var t=(this.dataZoomModel.get(`handleLabel`)||{}).show||!1,n=this.dataZoomModel.getModel([`emphasis`,`handleLabel`]).get(`show`)||!1,r=e||this._dragging?n:t,i=this._displayables,a=i.handleLabels;a[0].attr(`invisible`,!r),a[1].attr(`invisible`,!r),i.moveHandle&&this.api[r?`enterEmphasis`:`leaveEmphasis`](i.moveHandle,1)},t.prototype._onActualMoveZoneDrift=function(e,t,n){this.api.getZr().setCursorStyle(`grabbing`),this._onDragMove(`all`,e,t,n)},t.prototype._onActualMoveZoneDragStart=function(e){e.target.attr(`cursor`,`grabbing`),this._showDataInfo(!0)},t.prototype._onActualMoveZoneDragEnd=function(e){e.target.attr(`cursor`,`grab`),this._onDragEnd()},t.prototype._onDragMove=function(e,t,n,r){this._dragging=!0,Yt(r.event);var i=this._displayables.sliderGroup.getLocalTransform(),a=Up([t,n],i,!0),o=this._updateInterval(e,a[0]),s=this.dataZoomModel.get(`realtime`);this._updateView(!s),o&&s&&this._dispatchZoomAction(!0)},t.prototype._onDragEnd=function(){this._dragging=!1,this._isOverDataInfoTriggerArea||this._showDataInfo(!1),!this.dataZoomModel.get(`realtime`)&&this._dispatchZoomAction(!1)},t.prototype._onClickPanel=function(e){var t=this._size,n=this._displayables.sliderGroup.transformCoordToLocal(e.offsetX,e.offsetY);if(!(n[0]<0||n[0]>t[0]||n[1]<0||n[1]>t[1])){var r=this._handleEnds,i=(r[0]+r[1])/2,a=this._updateInterval(`all`,n[0]-i);this._updateView(),a&&this._dispatchZoomAction(!1)}},t.prototype._onBrushStart=function(e){var t=e.offsetX,n=e.offsetY;this._brushStart=new un(t,n),this._brushing=!0,this._brushStartTime=+new Date},t.prototype._onBrushEnd=function(e){if(this._brushing){var t=this._displayables.brushRect;if(this._brushing=!1,t){t.attr(`ignore`,!0);var n=t.shape;if(!(+new Date-this._brushStartTime<200&&Math.abs(n.width)<5)){var r=this._getViewExtent(),i=[0,100],a=this._handleEnds=[n.x,n.x+n.width],o=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();Cj(0,a,r,0,o.minSpan==null?null:vo(o.minSpan,i,r,!0),o.maxSpan==null?null:vo(o.maxSpan,i,r,!0)),this._range=Co([vo(a[0],r,i,!0),vo(a[1],r,i,!0)]),this._updateView(),this._dispatchZoomAction(!1)}}}},t.prototype._onBrush=function(e){this._brushing&&(Yt(e.event),this._updateBrushRect(e.offsetX,e.offsetY))},t.prototype._updateBrushRect=function(e,t){var n=this._displayables,r=this.dataZoomModel,i=n.brushRect;i||(i=n.brushRect=new GI({silent:!0,style:r.getModel(`brushStyle`).getItemStyle()}),n.sliderGroup.add(i)),i.attr(`ignore`,!1);var a=this._brushStart,o=this._displayables.sliderGroup,s=o.transformCoordToLocal(e,t),c=o.transformCoordToLocal(a.x,a.y),l=this._size;s[0]=Math.max(Math.min(l[0],s[0]),0),i.setShape({x:c[0],y:0,width:s[0]-c[0],height:l[1]})},t.prototype._dispatchZoomAction=function(e){var t=this._range;this.api.dispatchAction({type:`dataZoom`,from:this.uid,dataZoomId:this.dataZoomModel.id,animation:e?$I:null,start:t[0],end:t[1]})},t.prototype._findCoordRect=function(){var e,t=EN(this.dataZoomModel).infoList;if(!e&&t.length){var n=t[0].model.coordinateSystem;e=n.getRect&&n.getRect()}if(!e){var r=this.api.getWidth(),i=this.api.getHeight();e={x:r*.2,y:i*.2,width:r*.6,height:i*.6}}return e},t.type=`dataZoom.slider`,t}(FN);function tL(e,t,n,r){var i=e.get(`labelFormatter`),a=e.get(`labelPrecision`);(a==null||a===`auto`)&&(a=n.valuePrecision);var o=n.value[t],s=o==null||isNaN(o)?``:Uw(r)||Vw(r)?r.getLabel({value:Math.round(o)}):isFinite(a)?X(o,a,!0):o+``;return W(i)?i(o,s):G(i)?i.replace(`{value}`,s):s}function nL(e){return{x:`y`,y:`x`,radius:`angle`,angle:`radius`}[e]}function rL(e){return e===`vertical`?`ns-resize`:`ew-resize`}function iL(e){e.registerComponentModel(WI),e.registerComponentView(eL),VN(e)}function aL(e){TE(UI),TE(iL)}var oL=[`getWidth`,`getHeight`,`getDom`,`getOption`,`resize`,`dispatchAction`,`convertToPixel`,`convertFromPixel`,`containPixel`,`getDataURL`,`getConnectedDataURL`,`appendData`,`clear`,`isDisposed`,`dispose`];function sL(e){function t(t){return function(...n){if(!e.value)throw Error(`ECharts is not initialized yet.`);return Reflect.apply(e.value[t],e.value,n)}}return oL.reduce((e,n)=>(e[n]=t(n),e),{})}function cL(e,t,n){d([n,e,t],([e,t,n],r,i)=>{let a=null;if(e&&t&&n){let{offsetWidth:r,offsetHeight:i}=e,{throttle:o=100,onResize:s}=n===!0?{}:n,c=!1,l=()=>{t.resize(),s?.()},u=o?Jy(l,o):l;a=new ResizeObserver(()=>{!c&&(c=!0,e.offsetWidth===r&&e.offsetHeight===i)||e.offsetWidth===0||e.offsetHeight===0||u()}),a.observe(e)}i(()=>{a&&=(a.disconnect(),null)})})}var lL={autoresize:[Boolean,Object]},uL=Symbol();function dL(e,n,r){let i=t(uL,{}),a=S(()=>({...b(i),...r?.value}));u(()=>{let t=e.value;t&&(n.value?t.showLoading(a.value):t.hideLoading())})}var fL={loading:Boolean,loadingOptions:Object};function pL(){return typeof window<`u`&&typeof document<`u`}var mL=/^on[^a-z]/,hL=e=>mL.test(e);function gL(e){let t={};for(let n in e)hL(n)||(t[n]=e[n]);return t}function _L(e){let t=Number(e);return Number.isInteger(t)&&t>=0&&t<2**32-1&&String(t)===e}function vL(e,t){let n=new Set(e),r=new Set(t);if(n.size!==r.size)return!1;for(let e of n)if(!r.has(e))return!1;return!0}function yL(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}var bL=`[vue-echarts]`;function xL(e){i(`${bL} ${e}`)}var SL={tooltip:[`tooltip`,`formatter`],dataView:[`toolbox`,`feature`,`dataView`,`optionToContent`]},CL=Object.keys(SL);function wL(e){return CL.some(t=>e===t||e.startsWith(t+`-`))}function TL(e,t){let r=pL()?document.createElement(`div`):void 0,i=p({}),a=p({}),o=p({}),s=y(!1),l=()=>s.value&&r?h(f,{to:r},Object.entries(e).filter(([e])=>wL(e)).map(([e,t])=>{let n=e;return h(`div`,{ref:e=>{e instanceof HTMLElement&&(i[n]=e)},style:{display:`contents`}},a[n]?t?.(o[n]):void 0)})):void 0;function u(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function d(t){let n={...t},r=(e,t)=>{let n=e[t];if(Array.isArray(n))return e[t]=[...n],e[t];if(u(n))return e[t]={...n},e[t];if(n===void 0)return e[t]=_L(t)?[]:{},e[t]};return Object.keys(e).filter(e=>{let t=wL(e);return t||xL(`Invalid slot name: ${e}`),t}).forEach(e=>{let[t,...s]=e.split(`-`),c=SL[t];if(!c)return;let l=[...s,...c];if(l.length===0)return;let u=n;for(let e=0;e<l.length-1;e++)if(u=r(u,l[e]),!u)return;u[l[l.length-1]]=t=>(a[e]=!0,o[e]=t,i[e])}),n}let m=[];return n(()=>{let n=Object.keys(e).filter(wL);vL(n,m)||(m.forEach(e=>{n.includes(e)||(delete o[e],delete a[e],delete i[e])}),m=n,t())}),c(()=>{s.value=!0}),C(()=>{r?.remove()}),{teleportedSlots:l,patchOption:d}}var EL=null,DL=`x-vue-echarts`;function OL(){if(EL!=null)return EL;let e=globalThis.customElements;if(!pL()||!e?.get)return EL=!1,EL;if(!e.get(DL))try{class t extends HTMLElement{__dispose=null;disconnectedCallback(){this.__dispose&&=(this.__dispose(),null)}}e.define(DL,t)}catch{return EL=!1,EL}return EL=!0,EL}function kL(e){if(!yL(e))return;let t=e.id;if(typeof t==`string`)return t;if(typeof t==`number`&&Number.isFinite(t))return String(t)}function AL(e){let t=e,n=Array.isArray(t.options)?t.options.length:0,r=Array.isArray(t.media)?t.media.length:0,i=Object.create(null),a=[],o=[];for(let e of Object.keys(t)){if(e===`options`||e===`media`)continue;let n=t[e];if(Array.isArray(n)){let t=n,r=new Set,a=0;for(let e=0;e<t.length;e++){let n=kL(t[e]);n===void 0?a++:r.add(n)}i[e]={idsSorted:r.size>0?Array.from(r).sort():[],noIdCount:a}}else yL(n)?a.push(e):n!==void 0&&o.push(e)}return a.length>1&&a.sort(),o.length>1&&o.sort(),{optionsLength:n,mediaLength:r,arrays:i,objects:a,scalars:o}}function jL(e,t){if(e.length===0)return[];if(t.length===0)return e.slice();let n=new Set(t),r=[];for(let t=0;t<e.length;t++){let i=e[t];n.has(i)||r.push(i)}return r}function ML(e,t){if(e.length===0)return!1;if(t.length===0)return!0;let n=new Set(t);for(let t=0;t<e.length;t++)if(!n.has(e[t]))return!0;return!1}function NL(e,t){let n=AL(t);if(!e)return{option:t,signature:n,plan:{notMerge:!1}};if(n.optionsLength<e.optionsLength||n.mediaLength<e.mediaLength||jL(e.scalars,n.scalars).length>0)return{option:t,signature:n,plan:{notMerge:!0}};let r=new Set,i=new Map,a=jL(e.objects,n.objects);for(let e=0;e<a.length;e++)i.set(a[e],null);for(let t of Object.keys(e.arrays)){let a=e.arrays[t];if(!a)continue;let o=n.arrays[t];if(!o){(a.idsSorted.length>0||a.noIdCount>0)&&(i.set(t,[]),r.add(t));continue}if(ML(a.idsSorted,o.idsSorted)){r.add(t);continue}o.noIdCount<a.noIdCount&&r.add(t)}let o=t,s=n;if(i.size>0){let e={...t};i.forEach((t,n)=>{e[n]=t}),o=e,s=AL(o)}let c=r.size>0?Array.from(r).sort():void 0;return{option:o,signature:s,plan:c?{notMerge:!1,replaceMerge:c}:{notMerge:!1}}}var PL=`x-vue-echarts{display:block;width:100%;height:100%;min-width:0;}
x-vue-echarts>:first-child,x-vue-echarts>:first-child>canvas{border-radius:inherit;}
`;if(typeof document<`u`)if(Array.isArray(document.adoptedStyleSheets)&&`replaceSync`in CSSStyleSheet.prototype){let e=new CSSStyleSheet;e.replaceSync(PL),document.adoptedStyleSheets=[...document.adoptedStyleSheets,e]}else{let e=document.createElement(`style`);e.textContent=PL,document.head.appendChild(e)}var FL=OL(),IL=Symbol(),LL=Symbol(),RL=Symbol(),zL=s({name:`Echarts`,inheritAttrs:!1,props:{option:Object,theme:{type:[Object,String]},initOptions:Object,updateOptions:Object,group:String,manualUpdate:Boolean,...lL,...fL},emits:{},slots:Object,setup(e,{attrs:n,expose:i,slots:a}){let s=y(),l=y(),f=t(IL,null),p=t(LL,null),m=t(RL,null),{autoresize:_,manualUpdate:v,loading:x,loadingOptions:C}=g(e),w=S(()=>e.theme||b(f)),T=S(()=>e.initOptions||b(p)||void 0),E=S(()=>e.updateOptions||b(m)),D=S(()=>gL(n)),O={},k=new Map,{teleportedSlots:A,patchOption:j}=TL(a,()=>{!v.value&&e.option&&l.value&&ne(l.value,e.option)}),ee;function te(e){let t={},n=(e?.replaceMerge??[]).filter(e=>e!=null);return n.length>0&&(t.replaceMerge=[...new Set(n)]),e?.notMerge!==void 0&&(t.notMerge=e.notMerge),t}function ne(e,t,n,r=!1){let i=j(t);if(r){e.setOption(i,n??{}),ee=void 0;return}if(E.value){let t=n??E.value;e.setOption(i,t),ee=void 0;return}let a=NL(ee,i),o=te(a.plan);e.setOption(a.option,o),ee=a.signature}Object.keys(n).filter(e=>hL(e)).forEach(e=>{if(e.indexOf(`Native:`)===2){let t=`on${e.charAt(9).toUpperCase()}${e.slice(10)}`;O[t]=n[e];return}let t=e.charAt(2).toLowerCase()+e.slice(3),r;t.indexOf(`zr:`)===0&&(r=!0,t=t.substring(3));let i;t.substring(t.length-4)===`Once`&&(i=!0,t=t.substring(0,t.length-4)),k.set({event:t,zr:r,once:i},n[e])});function re(){if(!s.value)return;let t=l.value=pC(s.value,w.value,T.value);e.group&&(t.group=e.group),k.forEach((e,{zr:n,once:r,event:i})=>{if(!e)return;let a=n?t.getZr():t;if(r){let t=e,n=!1;e=(...r)=>{n||(n=!0,t(...r),a.off(i,e))}}a.on(i,e)});function n(){t&&!t.isDisposed()&&t.resize()}function r(){let{option:n}=e;if(v.value){n&&ne(t,n,void 0,!0);return}n&&ne(t,n)}_.value?o(()=>{n(),r()}):r()}let ie=(t,n,r)=>{if(!e.manualUpdate){xL("`setOption` is only available when `manual-update` is `true`.");return}let i=typeof n==`boolean`?{notMerge:n,lazyUpdate:r}:n;l.value&&ne(l.value,t,i??void 0,!0)};function ae(){l.value&&=(l.value.dispose(),void 0),ee=void 0}d(()=>e.option,e=>{if(!e){ee=void 0;return}if(v.value){xL("`option` prop changes are ignored when `manual-update` is `true`.");return}l.value&&ne(l.value,e)},{deep:!0}),d([v,T],()=>{ae(),re()},{deep:!0}),d(w,e=>{l.value?.setTheme(e||{})},{deep:!0}),u(()=>{e.group&&l.value&&(l.value.group=e.group)});let oe=sL(l);return dL(l,x,C),cL(l,_,s),c(()=>{re()}),r(()=>{FL&&s.value?s.value.__dispose=ae:ae()}),i({setOption:ie,root:s,chart:l,...oe}),(()=>h(DL,{...D.value,...O,ref:s,class:[`echarts`,D.value.class]},A()))}}),BL=600*1e3,VL=D(s({__name:`FleetTrendEChart`,props:{points:{},hours:{},thresholds:{},height:{default:360},zoomStart:{default:void 0},zoomEnd:{default:void 0}},emits:[`range-change`],setup(e,{emit:t}){TE([BD,RO,IA,yN,wF,OI,aL,KP,nI,KF]);let n=e,r=t,i=_();function o(e){let t=i.current.value.colors[e];return typeof t==`string`?t:`#1976D2`}function s(e){return n.points.map(t=>{let n=a(t.recorded_at),r=t[e];return!n||r==null?null:[n.getTime(),r]}).filter(e=>e!=null)}function c(){return n.points.map(e=>{let t=a(e.recorded_at);return t?[t.getTime(),e.online_count]:null}).filter(e=>e!=null)}function u(e,t,n){return[{yAxis:e,name:t,lineStyle:{color:n,type:`dashed`,width:1,opacity:.75},label:{formatter:`${t} ${e}%`,color:n,fontSize:10,position:`insideEndTop`}}]}function d(){return{symbol:`circle`,symbolSize:8,label:{fontSize:10,formatter:e=>{let t=e.value,n=Array.isArray(t)?t[1]:t;return typeof n==`number`?`${n}%`:``}},data:[{type:`max`,name:`峰值`},{type:`min`,name:`谷值`}]}}function f(e,t=!1){let r=E(new Date(e).toISOString());return t?r:(n.hours,r.slice(5,16))}function p(){return n.points.filter(e=>(e.alert_count??0)>0).map(e=>{let t=T(e.recorded_at),n=Math.max(e.cpu_avg??0,e.mem_avg??0,e.disk_avg??0,8);return[t??0,Math.min(n+4,99),e.alert_count??0]}).filter(e=>e[0]>0)}function h(e){let t=e.alerts??[];if(!t.length)return`<div style="margin-top:8px;font-size:11px;opacity:0.65">本 10 分钟无告警</div>`;let n=t.slice(0,8).map(e=>{let t=e.alert_type_label||e.alert_type,n=e.is_recovery?`恢复`:`告警`,r=e.is_recovery?`#4CAF50`:`#F44336`,i=e.created_at?E(e.created_at).slice(11,19):``;return`<div style="font-size:11px;line-height:1.45">
<span style="color:${r};font-weight:600">${n}</span>
${e.server_name||`—`} · ${t} ${e.value||``}
${i?`<span style="opacity:0.7"> @ ${i}</span>`:``}
</div>`}),r=t.length>8?`<div style="font-size:11px;opacity:0.7">还有 ${t.length-8} 条…</div>`:``;return`<div style="margin-top:8px;padding-top:8px;border-top:1px solid rgba(128,128,128,0.25)">
<div style="font-weight:600;font-size:12px;margin-bottom:4px">告警 ${t.length} 条(10 分钟窗口)</div>
${n.join(``)}${r}
</div>`}function g(e,t){let r=E(e.recorded_at),i=t>0?n.points[t-1]:null,a=(e,t,n,r,i)=>{let a=``;if(n!=null&&r!=null){let e=Math.round((n-r)*10)/10;a=`<span style="color:${e>0?`#FB8C00`:e<0?`#4CAF50`:`#9E9E9E`};font-size:11px;margin-left:6px">${e>0?`+`:``}${e}${i}</span>`}return`<tr>
<td style="padding:2px 8px 2px 0;white-space:nowrap">
<span style="display:inline-block;width:8px;height:8px;border-radius:50%;background:${e};margin-right:6px"></span>${t}
</td>
<td style="padding:2px 0;text-align:right">${n==null?`—`:`<b>${n}${i}</b>`}${a}</td>
</tr>`},s=e.sample_count!=null&&e.online_count>0?Math.round(e.sample_count/e.online_count*100):null,c=[`在线 <b>${e.online_count}</b> 台`,e.sample_count==null?null:`采样 <b>${e.sample_count}</b>`,s==null?null:`覆盖率 <b>${s}%</b>`].filter(Boolean).join(` · `);return`<div style="min-width:200px;line-height:1.5">
<div style="font-weight:600;font-size:13px;margin-bottom:8px">${r}</div>
<table style="width:100%;border-collapse:collapse;font-size:12px">${[a(o(`primary`),`CPU`,e.cpu_avg,i?.cpu_avg??null,`%`),a(o(`warning`),`内存`,e.mem_avg,i?.mem_avg??null,`%`),a(`#9C27B0`,`磁盘`,e.disk_avg,i?.disk_avg??null,`%`),a(o(`success`),`在线`,e.online_count,i?.online_count??null,` 台`)].join(``)}</table>
<div style="margin-top:8px;font-size:11px;opacity:0.75">${c}</div>
${h(e)}
</div>`}let y=S(()=>n.zoomStart==null?n.hours>=168?65:0:n.zoomStart),b=S(()=>n.zoomEnd??100),C=S(()=>{let e=i.current.value.dark,t=e?`rgba(255,255,255,0.78)`:`rgba(0,0,0,0.65)`,r=e?`rgba(255,255,255,0.14)`:`rgba(0,0,0,0.1)`,a=e?`rgba(255,255,255,0.07)`:`rgba(0,0,0,0.06)`,l=o(`primary`),m=o(`warning`),h=o(`success`),_=o(`error`),v=p();return{animationDuration:600,animationEasing:`cubicOut`,color:[l,m,`#9C27B0`,h,_],grid:{left:12,right:16,top:52,bottom:78,containLabel:!0},legend:{top:6,left:`center`,textStyle:{color:t,fontSize:12},itemWidth:18,itemHeight:8,itemGap:20,selected:{在线台数:!1,告警:v.length>0}},tooltip:{trigger:`axis`,confine:!0,axisPointer:{type:`cross`,snap:!0,crossStyle:{color:r},lineStyle:{color:l,type:`dashed`,width:1},label:{backgroundColor:e?`#333`:`#666`,formatter:e=>{let t=e.axisDimension,n=e.value;return t===`x`&&n!=null?f(Number(n),!0):t===`y`&&n!=null?`${Math.round(Number(n)*10)/10}`:``}}},backgroundColor:e?`rgba(28,28,32,0.97)`:`rgba(255,255,255,0.98)`,borderColor:r,borderWidth:1,padding:[10,12],extraCssText:`box-shadow:0 8px 24px rgba(0,0,0,0.18);border-radius:8px;`,textStyle:{color:e?`#eee`:`#222`},formatter(e){let t=(Array.isArray(e)?e:[e])[0]?.axisValue;if(t==null)return``;let r=typeof t==`number`?t:Number(t),i=w(n.points,r);return i<0||i>=n.points.length?``:g(n.points[i],i)}},toolbox:{right:12,top:4,itemSize:14,iconStyle:{borderColor:t},feature:{dataZoom:{yAxisIndex:`none`,title:{zoom:`框选`,back:`还原`}},restore:{title:`重置`},saveAsImage:{title:`导出图片`,name:`nexus-fleet-trend`,pixelRatio:2}}},dataZoom:[{type:`inside`,start:y.value,end:b.value,minValueSpan:BL},{type:`slider`,height:24,bottom:10,start:y.value,end:b.value,borderColor:r,backgroundColor:e?`rgba(255,255,255,0.04)`:`rgba(0,0,0,0.03)`,fillerColor:e?`rgba(25,118,210,0.2)`:`rgba(25,118,210,0.15)`,handleStyle:{color:l,borderColor:l},moveHandleStyle:{color:l},textStyle:{color:t,fontSize:10},labelFormatter:e=>f(e,!0)}],xAxis:{type:`time`,minInterval:BL,maxInterval:n.hours>=168?360*60*1e3:3600*1e3,axisLine:{lineStyle:{color:r}},axisLabel:{color:t,fontSize:10,hideOverlap:!0,formatter:e=>f(e,!0)},axisTick:{show:!1},splitLine:{show:!0,lineStyle:{color:a,type:`dotted`}},minorSplitLine:{show:!1}},yAxis:[{type:`value`,name:`利用率`,min:0,max:100,nameTextStyle:{color:t,fontSize:11,padding:[0,0,0,4]},axisLabel:{color:t,fontSize:10,formatter:`{value}%`},splitLine:{lineStyle:{color:a,type:`dashed`}}},{type:`value`,name:`在线台数`,position:`right`,minInterval:1,nameTextStyle:{color:t,fontSize:11},axisLabel:{color:t,fontSize:10},splitLine:{show:!1}}],series:[{name:`CPU`,type:`line`,smooth:.28,showSymbol:!1,symbolSize:7,connectNulls:!1,emphasis:{focus:`series`,scale:!0},lineStyle:{width:2.5},areaStyle:{color:{type:`linear`,x:0,y:0,x2:0,y2:1,colorStops:[{offset:0,color:`${l}40`},{offset:1,color:`${l}06`}]}},markLine:{symbol:`none`,silent:!0,data:u(n.thresholds.cpu,`CPU 告警`,_)},markPoint:d(),data:s(`cpu_avg`)},{name:`内存`,type:`line`,smooth:.28,showSymbol:!1,connectNulls:!1,emphasis:{focus:`series`},lineStyle:{width:2},areaStyle:{color:{type:`linear`,x:0,y:0,x2:0,y2:1,colorStops:[{offset:0,color:`${m}35`},{offset:1,color:`${m}05`}]}},markLine:{symbol:`none`,silent:!0,data:u(n.thresholds.mem,`内存告警`,_)},data:s(`mem_avg`)},{name:`磁盘`,type:`line`,smooth:.28,showSymbol:!1,connectNulls:!1,emphasis:{focus:`series`},lineStyle:{width:2},markLine:{symbol:`none`,silent:!0,data:u(n.thresholds.disk,`磁盘告警`,_)},data:s(`disk_avg`)},{name:`在线台数`,type:`line`,yAxisIndex:1,smooth:.28,showSymbol:!1,connectNulls:!1,emphasis:{focus:`series`},lineStyle:{width:2,type:`dashed`,opacity:.85},data:c()},...v.length?[{name:`告警`,type:`scatter`,yAxisIndex:0,symbol:`pin`,symbolSize:e=>{let t=e?.[2]??1;return Math.min(28,12+Number(t)*3)},itemStyle:{color:_},emphasis:{scale:1.2},z:12,data:v}]:[]]}});function D(e){let t=e.batch?.[0];r(`range-change`,{startPercent:t?.start??e.start??0,endPercent:t?.end??e.end??100})}return(t,n)=>(l(),x(m(zL),{class:`fleet-echart`,style:v({height:`${e.height}px`}),option:C.value,"update-options":{notMerge:!0},autoresize:``,onDatazoom:D},null,8,[`style`,`option`]))}}),[[`__scopeId`,`data-v-a04be566`]]);export{VL as default};