wgts-report 0.0.0-stage → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,37 @@
1
+ import{r as kr,j as y1}from"./wgts-report.js";/*! *****************************************************************************
2
+ Copyright (c) Microsoft Corporation.
3
+
4
+ Permission to use, copy, modify, and/or distribute this software for any
5
+ purpose with or without fee is hereby granted.
6
+
7
+ THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
8
+ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
9
+ AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
10
+ INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
11
+ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
12
+ OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
13
+ PERFORMANCE OF THIS SOFTWARE.
14
+ ***************************************************************************** */var $l=function(r,t){return $l=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,i){e.__proto__=i}||function(e,i){for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(e[n]=i[n])},$l(r,t)};function O(r,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");$l(r,t);function e(){this.constructor=r}r.prototype=t===null?Object.create(t):(e.prototype=t.prototype,new e)}var m1=(function(){function r(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return r})(),_1=(function(){function r(){this.browser=new m1,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 r})(),Z=new _1;typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(Z.wxa=!0,Z.touchEventsSupported=!0):typeof document>"u"&&typeof self<"u"?Z.worker=!0:!Z.hasGlobalWindow||"Deno"in window?(Z.node=!0,Z.svgSupported=!0):S1(navigator.userAgent,Z);function S1(r,t){var e=t.browser,i=r.match(/Firefox\/([\d.]+)/),n=r.match(/MSIE\s([\d.]+)/)||r.match(/Trident\/.+?rv:(([\d.]+))/),a=r.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(r);i&&(e.firefox=!0,e.version=i[1]),n&&(e.ie=!0,e.version=n[1]),a&&(e.edge=!0,e.version=a[1],e.newEdge=+a[1].split(".")[0]>18),o&&(e.weChat=!0),t.svgSupported=typeof SVGRect<"u",t.touchEventsSupported="ontouchstart"in window&&!e.ie&&!e.edge,t.pointerEventsSupported="onpointerdown"in window&&(e.edge||e.ie&&+e.version>=11),t.domSupported=typeof document<"u";var s=document.documentElement.style;t.transform3dSupported=(e.ie&&"transition"in s||e.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in s)&&!("OTransition"in s),t.transformSupported=t.transform3dSupported||e.ie&&+e.version>=9}var fh=12,w1="sans-serif",di=fh+"px "+w1,b1=20,x1=100,T1="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function M1(r){var t={};if(typeof JSON>"u")return t;for(var e=0;e<r.length;e++){var i=String.fromCharCode(e+32),n=(r.charCodeAt(e)-b1)/x1;t[i]=n}return t}var C1=M1(T1),yn={createCanvas:function(){return typeof document<"u"&&document.createElement("canvas")},measureText:(function(){var r,t;return function(e,i){if(!r){var n=yn.createCanvas();r=n&&n.getContext("2d")}if(r)return t!==i&&(t=r.font=i||di),r.measureText(e);e=e||"",i=i||di;var a=/((?:\d+)?\.?\d*)px/.exec(i),o=a&&+a[1]||fh,s=0;if(i.indexOf("mono")>=0)s=o*e.length;else for(var u=0;u<e.length;u++){var l=C1[e[u]];s+=l==null?o:l*o}return{width:s}}})(),loadImage:function(r,t,e){var i=new Image;return i.onload=t,i.onerror=e,i.src=r,i}},ty=Ti(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],function(r,t){return r["[object "+t+"]"]=!0,r},{}),ey=Ti(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],function(r,t){return r["[object "+t+"Array]"]=!0,r},{}),Ba=Object.prototype.toString,Cs=Array.prototype,D1=Cs.forEach,A1=Cs.filter,hh=Cs.slice,L1=Cs.map,Ev=(function(){}).constructor,Ga=Ev?Ev.prototype:null,vh="__proto__",P1=2311;function ry(){return P1++}function ch(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];typeof console<"u"&&console.error.apply(console,r)}function Y(r){if(r==null||typeof r!="object")return r;var t=r,e=Ba.call(r);if(e==="[object Array]"){if(!oa(r)){t=[];for(var i=0,n=r.length;i<n;i++)t[i]=Y(r[i])}}else if(ey[e]){if(!oa(r)){var a=r.constructor;if(a.from)t=a.from(r);else{t=new a(r.length);for(var i=0,n=r.length;i<n;i++)t[i]=r[i]}}}else if(!ty[e]&&!oa(r)&&!ma(r)){t={};for(var o in r)r.hasOwnProperty(o)&&o!==vh&&(t[o]=Y(r[o]))}return t}function tt(r,t,e){if(!W(t)||!W(r))return e?Y(t):r;for(var i in t)if(t.hasOwnProperty(i)&&i!==vh){var n=r[i],a=t[i];W(a)&&W(n)&&!B(a)&&!B(n)&&!ma(a)&&!ma(n)&&!kv(a)&&!kv(n)&&!oa(a)&&!oa(n)?tt(n,a,e):(e||!(i in r))&&(r[i]=Y(t[i]))}return r}function I1(r,t){for(var e=r[0],i=1,n=r.length;i<n;i++)e=tt(e,r[i],t);return e}function k(r,t){if(Object.assign)Object.assign(r,t);else for(var e in t)t.hasOwnProperty(e)&&e!==vh&&(r[e]=t[e]);return r}function rt(r,t,e){for(var i=ft(t),n=0,a=i.length;n<a;n++){var o=i[n];r[o]==null&&(r[o]=t[o])}return r}function Q(r,t){if(r){if(r.indexOf)return r.indexOf(t);for(var e=0,i=r.length;e<i;e++)if(r[e]===t)return e}return-1}function R1(r,t){var e=r.prototype;function i(){}i.prototype=t.prototype,r.prototype=new i;for(var n in e)e.hasOwnProperty(n)&&(r.prototype[n]=e[n]);r.prototype.constructor=r,r.superClass=t}function Ce(r,t,e){if(r="prototype"in r?r.prototype:r,t="prototype"in t?t.prototype:t,Object.getOwnPropertyNames)for(var i=Object.getOwnPropertyNames(t),n=0;n<i.length;n++){var a=i[n];a!=="constructor"&&r[a]==null&&(r[a]=t[a])}else rt(r,t)}function zt(r){return!r||typeof r=="string"?!1:typeof r.length=="number"}function T(r,t,e){if(r&&t)if(r.forEach&&r.forEach===D1)r.forEach(t,e);else if(r.length===+r.length)for(var i=0,n=r.length;i<n;i++)t.call(e,r[i],i,r);else for(var a in r)r.hasOwnProperty(a)&&t.call(e,r[a],a,r)}function z(r,t,e){if(!r)return[];if(!t)return ph(r);if(r.map&&r.map===L1)return r.map(t,e);for(var i=[],n=0,a=r.length;n<a;n++)i.push(t.call(e,r[n],n,r));return i}function Ti(r,t,e,i){if(r&&t){for(var n=0,a=r.length;n<a;n++)e=t.call(i,e,r[n],n,r);return e}}function _t(r,t,e){if(!r)return[];if(!t)return ph(r);if(r.filter&&r.filter===A1)return r.filter(t,e);for(var i=[],n=0,a=r.length;n<a;n++)t.call(e,r[n],n,r)&&i.push(r[n]);return i}function ft(r){if(!r)return[];if(Object.keys)return Object.keys(r);var t=[];for(var e in r)r.hasOwnProperty(e)&&t.push(e);return t}function E1(r,t){for(var e=[],i=2;i<arguments.length;i++)e[i-2]=arguments[i];return function(){return r.apply(t,e.concat(hh.call(arguments)))}}var U=Ga&&q(Ga.bind)?Ga.call.bind(Ga.bind):E1;function ot(r){for(var t=[],e=1;e<arguments.length;e++)t[e-1]=arguments[e];return function(){return r.apply(this,t.concat(hh.call(arguments)))}}function B(r){return Array.isArray?Array.isArray(r):Ba.call(r)==="[object Array]"}function q(r){return typeof r=="function"}function H(r){return typeof r=="string"}function ql(r){return Ba.call(r)==="[object String]"}function dt(r){return typeof r=="number"}function W(r){var t=typeof r;return t==="function"||!!r&&t==="object"}function kv(r){return!!ty[Ba.call(r)]}function Yt(r){return!!ey[Ba.call(r)]}function ma(r){return typeof r=="object"&&typeof r.nodeType=="number"&&typeof r.ownerDocument=="object"}function Ds(r){return r.colorStops!=null}function k1(r){return r.image!=null}function Yo(r){return r!==r}function ke(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];for(var e=0,i=r.length;e<i;e++)if(r[e]!=null)return r[e]}function $(r,t){return r??t}function aa(r,t,e){return r??t??e}function ph(r){for(var t=[],e=1;e<arguments.length;e++)t[e-1]=arguments[e];return hh.apply(r,t)}function iy(r){if(typeof r=="number")return[r,r,r,r];var t=r.length;return t===2?[r[0],r[1],r[0],r[1]]:t===3?[r[0],r[1],r[2],r[1]]:r}function ze(r,t){if(!r)throw new Error(t)}function Oe(r){return r==null?null:typeof r.trim=="function"?r.trim():r.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var ny="__ec_primitive__";function Kl(r){r[ny]=!0}function oa(r){return r[ny]}var O1=(function(){function r(){this.data={}}return r.prototype.delete=function(t){var e=this.has(t);return e&&delete this.data[t],e},r.prototype.has=function(t){return this.data.hasOwnProperty(t)},r.prototype.get=function(t){return this.data[t]},r.prototype.set=function(t,e){return this.data[t]=e,this},r.prototype.keys=function(){return ft(this.data)},r.prototype.forEach=function(t){var e=this.data;for(var i in e)e.hasOwnProperty(i)&&t(e[i],i)},r})(),ay=typeof Map=="function";function B1(){return ay?new Map:new O1}var N1=(function(){function r(t){var e=B(t);this.data=B1();var i=this;t instanceof r?t.each(n):t&&T(t,n);function n(a,o){e?i.set(a,o):i.set(o,a)}}return r.prototype.hasKey=function(t){return this.data.has(t)},r.prototype.get=function(t){return this.data.get(t)},r.prototype.set=function(t,e){return this.data.set(t,e),e},r.prototype.each=function(t,e){this.data.forEach(function(i,n){t.call(e,i,n)})},r.prototype.keys=function(){var t=this.data.keys();return ay?Array.from(t):t},r.prototype.removeKey=function(t){this.data.delete(t)},r})();function X(r){return new N1(r)}function F1(r,t){for(var e=new r.constructor(r.length+t.length),i=0;i<r.length;i++)e[i]=r[i];for(var n=r.length,i=0;i<t.length;i++)e[i+n]=t[i];return e}function As(r,t){var e;if(Object.create)e=Object.create(r);else{var i=function(){};i.prototype=r,e=new i}return t&&k(e,t),e}function oy(r){var t=r.style;t.webkitUserSelect="none",t.userSelect="none",t.webkitTapHighlightColor="rgba(0,0,0,0)",t["-webkit-touch-callout"]="none"}function N(r,t){return r.hasOwnProperty(t)}function At(){}var z1=180/Math.PI;function mn(r,t){return r==null&&(r=0),t==null&&(t=0),[r,t]}function V1(r){return[r[0],r[1]]}function Ov(r,t,e){return r[0]=t[0]+e[0],r[1]=t[1]+e[1],r}function sy(r,t,e){return r[0]=t[0]-e[0],r[1]=t[1]-e[1],r}function H1(r){return Math.sqrt(G1(r))}function G1(r){return r[0]*r[0]+r[1]*r[1]}function fu(r,t,e){return r[0]=t[0]*e,r[1]=t[1]*e,r}function dh(r,t){var e=H1(t);return e===0?(r[0]=0,r[1]=0):(r[0]=t[0]/e,r[1]=t[1]/e),r}function Ql(r,t){return Math.sqrt((r[0]-t[0])*(r[0]-t[0])+(r[1]-t[1])*(r[1]-t[1]))}var Jl=Ql;function W1(r,t){return(r[0]-t[0])*(r[0]-t[0])+(r[1]-t[1])*(r[1]-t[1])}var ji=W1;function hu(r,t,e,i){return r[0]=t[0]+i*(e[0]-t[0]),r[1]=t[1]+i*(e[1]-t[1]),r}function ve(r,t,e){var i=t[0],n=t[1];return r[0]=e[0]*i+e[2]*n+e[4],r[1]=e[1]*i+e[3]*n+e[5],r}function Xi(r,t,e){return r[0]=Math.min(t[0],e[0]),r[1]=Math.min(t[1],e[1]),r}function $i(r,t,e){return r[0]=Math.max(t[0],e[0]),r[1]=Math.max(t[1],e[1]),r}var Li=(function(){function r(t,e){this.target=t,this.topTarget=e&&e.topTarget}return r})(),U1=(function(){function r(t){this.handler=t,t.on("mousedown",this._dragStart,this),t.on("mousemove",this._drag,this),t.on("mouseup",this._dragEnd,this)}return r.prototype._dragStart=function(t){for(var e=t.target;e&&!e.draggable;)e=e.parent||e.__hostTarget;e&&(this._draggingTarget=e,e.dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.handler.dispatchToElement(new Li(e,t),"dragstart",t.event))},r.prototype._drag=function(t){var e=this._draggingTarget;if(e){var i=t.offsetX,n=t.offsetY,a=i-this._x,o=n-this._y;this._x=i,this._y=n,e.drift(a,o,t),this.handler.dispatchToElement(new Li(e,t),"drag",t.event);var s=this.handler.findHover(i,n,e).target,u=this._dropTarget;this._dropTarget=s,e!==s&&(u&&s!==u&&this.handler.dispatchToElement(new Li(u,t),"dragleave",t.event),s&&s!==u&&this.handler.dispatchToElement(new Li(s,t),"dragenter",t.event))}},r.prototype._dragEnd=function(t){var e=this._draggingTarget;e&&(e.dragging=!1),this.handler.dispatchToElement(new Li(e,t),"dragend",t.event),this._dropTarget&&this.handler.dispatchToElement(new Li(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null},r})(),de=(function(){function r(t){t&&(this._$eventProcessor=t)}return r.prototype.on=function(t,e,i,n){this._$handlers||(this._$handlers={});var a=this._$handlers;if(typeof e=="function"&&(n=i,i=e,e=null),!i||!t)return this;var o=this._$eventProcessor;e!=null&&o&&o.normalizeQuery&&(e=o.normalizeQuery(e)),a[t]||(a[t]=[]);for(var s=0;s<a[t].length;s++)if(a[t][s].h===i)return this;var u={h:i,query:e,ctx:n||this,callAtLast:i.zrEventfulCallAtLast},l=a[t].length-1,f=a[t][l];return f&&f.callAtLast?a[t].splice(l,0,u):a[t].push(u),this},r.prototype.isSilent=function(t){var e=this._$handlers;return!e||!e[t]||!e[t].length},r.prototype.off=function(t,e){var i=this._$handlers;if(!i)return this;if(!t)return this._$handlers={},this;if(e){if(i[t]){for(var n=[],a=0,o=i[t].length;a<o;a++)i[t][a].h!==e&&n.push(i[t][a]);i[t]=n}i[t]&&i[t].length===0&&delete i[t]}else delete i[t];return this},r.prototype.trigger=function(t){for(var e=[],i=1;i<arguments.length;i++)e[i-1]=arguments[i];if(!this._$handlers)return this;var n=this._$handlers[t],a=this._$eventProcessor;if(n)for(var o=e.length,s=n.length,u=0;u<s;u++){var l=n[u];if(!(a&&a.filter&&l.query!=null&&!a.filter(t,l.query)))switch(o){case 0:l.h.call(l.ctx);break;case 1:l.h.call(l.ctx,e[0]);break;case 2:l.h.call(l.ctx,e[0],e[1]);break;default:l.h.apply(l.ctx,e);break}}return a&&a.afterTrigger&&a.afterTrigger(t),this},r.prototype.triggerWithContext=function(t){for(var e=[],i=1;i<arguments.length;i++)e[i-1]=arguments[i];if(!this._$handlers)return this;var n=this._$handlers[t],a=this._$eventProcessor;if(n)for(var o=e.length,s=e[o-1],u=n.length,l=0;l<u;l++){var f=n[l];if(!(a&&a.filter&&f.query!=null&&!a.filter(t,f.query)))switch(o){case 0:f.h.call(s);break;case 1:f.h.call(s,e[0]);break;case 2:f.h.call(s,e[0],e[1]);break;default:f.h.apply(s,e.slice(1,o-1));break}}return a&&a.afterTrigger&&a.afterTrigger(t),this},r})(),Y1=Math.log(2);function jl(r,t,e,i,n,a){var o=i+"-"+n,s=r.length;if(a.hasOwnProperty(o))return a[o];if(t===1){var u=Math.round(Math.log((1<<s)-1&~n)/Y1);return r[e][u]}for(var l=i|1<<e,f=e+1;i&1<<f;)f++;for(var h=0,v=0,c=0;v<s;v++){var p=1<<v;p&n||(h+=(c%2?-1:1)*r[e][v]*jl(r,t-1,f,l,n|p,a),c++)}return a[o]=h,h}function Bv(r,t){var e=[[r[0],r[1],1,0,0,0,-t[0]*r[0],-t[0]*r[1]],[0,0,0,r[0],r[1],1,-t[1]*r[0],-t[1]*r[1]],[r[2],r[3],1,0,0,0,-t[2]*r[2],-t[2]*r[3]],[0,0,0,r[2],r[3],1,-t[3]*r[2],-t[3]*r[3]],[r[4],r[5],1,0,0,0,-t[4]*r[4],-t[4]*r[5]],[0,0,0,r[4],r[5],1,-t[5]*r[4],-t[5]*r[5]],[r[6],r[7],1,0,0,0,-t[6]*r[6],-t[6]*r[7]],[0,0,0,r[6],r[7],1,-t[7]*r[6],-t[7]*r[7]]],i={},n=jl(e,8,0,0,0,i);if(n!==0){for(var a=[],o=0;o<8;o++)for(var s=0;s<8;s++)a[s]==null&&(a[s]=0),a[s]+=((o+s)%2?-1:1)*jl(e,7,o===0?1:0,1<<o,1<<s,i)/n*t[o];return function(u,l,f){var h=l*a[6]+f*a[7]+1;u[0]=(l*a[0]+f*a[1]+a[2])/h,u[1]=(l*a[3]+f*a[4]+a[5])/h}}}var Nv="___zrEVENTSAVED",vu=[];function Z1(r,t,e,i,n){return tf(vu,t,i,n,!0)&&tf(r,e,vu[0],vu[1])}function tf(r,t,e,i,n){if(t.getBoundingClientRect&&Z.domSupported&&!uy(t)){var a=t[Nv]||(t[Nv]={}),o=X1(t,a),s=$1(o,a,n);if(s)return s(r,e,i),!0}return!1}function X1(r,t){var e=t.markers;if(e)return e;e=t.markers=[];for(var i=["left","right"],n=["top","bottom"],a=0;a<4;a++){var o=document.createElement("div"),s=o.style,u=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",i[u]+":0",n[l]+":0",i[1-u]+":auto",n[1-l]+":auto",""].join("!important;"),r.appendChild(o),e.push(o)}return e}function $1(r,t,e){for(var i=e?"invTrans":"trans",n=t[i],a=t.srcCoords,o=[],s=[],u=!0,l=0;l<4;l++){var f=r[l].getBoundingClientRect(),h=2*l,v=f.left,c=f.top;o.push(v,c),u=u&&a&&v===a[h]&&c===a[h+1],s.push(r[l].offsetLeft,r[l].offsetTop)}return u&&n?n:(t.srcCoords=o,t[i]=e?Bv(s,o):Bv(o,s))}function uy(r){return r.nodeName.toUpperCase()==="CANVAS"}var q1=/([&<>"'])/g,K1={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function Gt(r){return r==null?"":(r+"").replace(q1,function(t,e){return K1[e]})}var Q1=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,cu=[],J1=Z.browser.firefox&&+Z.browser.version.split(".")[0]<39;function ef(r,t,e,i){return e=e||{},i?Fv(r,t,e):J1&&t.layerX!=null&&t.layerX!==t.offsetX?(e.zrX=t.layerX,e.zrY=t.layerY):t.offsetX!=null?(e.zrX=t.offsetX,e.zrY=t.offsetY):Fv(r,t,e),e}function Fv(r,t,e){if(Z.domSupported&&r.getBoundingClientRect){var i=t.clientX,n=t.clientY;if(uy(r)){var a=r.getBoundingClientRect();e.zrX=i-a.left,e.zrY=n-a.top;return}else if(tf(cu,r,i,n)){e.zrX=cu[0],e.zrY=cu[1];return}}e.zrX=e.zrY=0}function gh(r){return r||window.event}function ae(r,t,e){if(t=gh(t),t.zrX!=null)return t;var i=t.type,n=i&&i.indexOf("touch")>=0;if(n){var o=i!=="touchend"?t.targetTouches[0]:t.changedTouches[0];o&&ef(r,o,t,e)}else{ef(r,t,t,e);var a=j1(t);t.zrDelta=a?a/120:-(t.detail||0)/3}var s=t.button;return t.which==null&&s!==void 0&&Q1.test(t.type)&&(t.which=s&1?1:s&2?3:s&4?2:0),t}function j1(r){var t=r.wheelDelta;if(t)return t;var e=r.deltaX,i=r.deltaY;if(e==null||i==null)return t;var n=Math.abs(i!==0?i:e),a=i>0?-1:i<0?1:e>0?-1:1;return 3*n*a}function tS(r,t,e,i){r.addEventListener(t,e,i)}function eS(r,t,e,i){r.removeEventListener(t,e,i)}var hn=function(r){r.preventDefault(),r.stopPropagation(),r.cancelBubble=!0};function zv(r){return r.which===2||r.which===3}var rS=(function(){function r(){this._track=[]}return r.prototype.recognize=function(t,e,i){return this._doTrack(t,e,i),this._recognize(t)},r.prototype.clear=function(){return this._track.length=0,this},r.prototype._doTrack=function(t,e,i){var n=t.touches;if(n){for(var a={points:[],touches:[],target:e,event:t},o=0,s=n.length;o<s;o++){var u=n[o],l=ef(i,u,{});a.points.push([l.zrX,l.zrY]),a.touches.push(u)}this._track.push(a)}},r.prototype._recognize=function(t){for(var e in pu)if(pu.hasOwnProperty(e)){var i=pu[e](this._track,t);if(i)return i}},r})();function Vv(r){var t=r[1][0]-r[0][0],e=r[1][1]-r[0][1];return Math.sqrt(t*t+e*e)}function iS(r){return[(r[0][0]+r[1][0])/2,(r[0][1]+r[1][1])/2]}var pu={pinch:function(r,t){var e=r.length;if(e){var i=(r[e-1]||{}).points,n=(r[e-2]||{}).points||i;if(n&&n.length>1&&i&&i.length>1){var a=Vv(i)/Vv(n);!isFinite(a)&&(a=1),t.pinchScale=a;var o=iS(i);return t.pinchX=o[0],t.pinchY=o[1],{type:"pinch",target:r[0].target,event:t}}}}};function tn(){return[1,0,0,1,0,0]}function yh(r){return r[0]=1,r[1]=0,r[2]=0,r[3]=1,r[4]=0,r[5]=0,r}function nS(r,t){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r[3]=t[3],r[4]=t[4],r[5]=t[5],r}function en(r,t,e){var i=t[0]*e[0]+t[2]*e[1],n=t[1]*e[0]+t[3]*e[1],a=t[0]*e[2]+t[2]*e[3],o=t[1]*e[2]+t[3]*e[3],s=t[0]*e[4]+t[2]*e[5]+t[4],u=t[1]*e[4]+t[3]*e[5]+t[5];return r[0]=i,r[1]=n,r[2]=a,r[3]=o,r[4]=s,r[5]=u,r}function rf(r,t,e){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r[3]=t[3],r[4]=t[4]+e[0],r[5]=t[5]+e[1],r}function mh(r,t,e,i){i===void 0&&(i=[0,0]);var n=t[0],a=t[2],o=t[4],s=t[1],u=t[3],l=t[5],f=Math.sin(e),h=Math.cos(e);return r[0]=n*h+s*f,r[1]=-n*f+s*h,r[2]=a*h+u*f,r[3]=-a*f+h*u,r[4]=h*(o-i[0])+f*(l-i[1])+i[0],r[5]=h*(l-i[1])-f*(o-i[0])+i[1],r}function aS(r,t,e){var i=e[0],n=e[1];return r[0]=t[0]*i,r[1]=t[1]*n,r[2]=t[2]*i,r[3]=t[3]*n,r[4]=t[4]*i,r[5]=t[5]*n,r}function Ls(r,t){var e=t[0],i=t[2],n=t[4],a=t[1],o=t[3],s=t[5],u=e*o-a*i;return u?(u=1/u,r[0]=o*u,r[1]=-a*u,r[2]=-i*u,r[3]=e*u,r[4]=(i*s-o*n)*u,r[5]=(a*n-e*s)*u,r):null}var j=(function(){function r(t,e){this.x=t||0,this.y=e||0}return r.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this},r.prototype.clone=function(){return new r(this.x,this.y)},r.prototype.set=function(t,e){return this.x=t,this.y=e,this},r.prototype.equal=function(t){return t.x===this.x&&t.y===this.y},r.prototype.add=function(t){return this.x+=t.x,this.y+=t.y,this},r.prototype.scale=function(t){this.x*=t,this.y*=t},r.prototype.scaleAndAdd=function(t,e){this.x+=t.x*e,this.y+=t.y*e},r.prototype.sub=function(t){return this.x-=t.x,this.y-=t.y,this},r.prototype.dot=function(t){return this.x*t.x+this.y*t.y},r.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},r.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},r.prototype.normalize=function(){var t=this.len();return this.x/=t,this.y/=t,this},r.prototype.distance=function(t){var e=this.x-t.x,i=this.y-t.y;return Math.sqrt(e*e+i*i)},r.prototype.distanceSquare=function(t){var e=this.x-t.x,i=this.y-t.y;return e*e+i*i},r.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},r.prototype.transform=function(t){if(t){var e=this.x,i=this.y;return this.x=t[0]*e+t[2]*i+t[4],this.y=t[1]*e+t[3]*i+t[5],this}},r.prototype.toArray=function(t){return t[0]=this.x,t[1]=this.y,t},r.prototype.fromArray=function(t){this.x=t[0],this.y=t[1]},r.set=function(t,e,i){t.x=e,t.y=i},r.copy=function(t,e){t.x=e.x,t.y=e.y},r.len=function(t){return Math.sqrt(t.x*t.x+t.y*t.y)},r.lenSquare=function(t){return t.x*t.x+t.y*t.y},r.dot=function(t,e){return t.x*e.x+t.y*e.y},r.add=function(t,e,i){t.x=e.x+i.x,t.y=e.y+i.y},r.sub=function(t,e,i){t.x=e.x-i.x,t.y=e.y-i.y},r.scale=function(t,e,i){t.x=e.x*i,t.y=e.y*i},r.scaleAndAdd=function(t,e,i,n){t.x=e.x+i.x*n,t.y=e.y+i.y*n},r.lerp=function(t,e,i,n){var a=1-n;t.x=a*e.x+n*i.x,t.y=a*e.y+n*i.y},r})(),Wa=Math.min,Ua=Math.max,Or=new j,Br=new j,Nr=new j,Fr=new j,Tn=new j,Mn=new j,et=(function(){function r(t,e,i,n){i<0&&(t=t+i,i=-i),n<0&&(e=e+n,n=-n),this.x=t,this.y=e,this.width=i,this.height=n}return r.prototype.union=function(t){var e=Wa(t.x,this.x),i=Wa(t.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=Ua(t.x+t.width,this.x+this.width)-e:this.width=t.width,isFinite(this.y)&&isFinite(this.height)?this.height=Ua(t.y+t.height,this.y+this.height)-i:this.height=t.height,this.x=e,this.y=i},r.prototype.applyTransform=function(t){r.applyTransform(this,this,t)},r.prototype.calculateTransform=function(t){var e=this,i=t.width/e.width,n=t.height/e.height,a=tn();return rf(a,a,[-e.x,-e.y]),aS(a,a,[i,n]),rf(a,a,[t.x,t.y]),a},r.prototype.intersect=function(t,e){if(!t)return!1;t instanceof r||(t=r.create(t));var i=this,n=i.x,a=i.x+i.width,o=i.y,s=i.y+i.height,u=t.x,l=t.x+t.width,f=t.y,h=t.y+t.height,v=!(a<u||l<n||s<f||h<o);if(e){var c=1/0,p=0,d=Math.abs(a-u),g=Math.abs(l-n),y=Math.abs(s-f),m=Math.abs(h-o),_=Math.min(d,g),S=Math.min(y,m);a<u||l<n?_>p&&(p=_,d<g?j.set(Mn,-d,0):j.set(Mn,g,0)):_<c&&(c=_,d<g?j.set(Tn,d,0):j.set(Tn,-g,0)),s<f||h<o?S>p&&(p=S,y<m?j.set(Mn,0,-y):j.set(Mn,0,m)):_<c&&(c=_,y<m?j.set(Tn,0,y):j.set(Tn,0,-m))}return e&&j.copy(e,v?Tn:Mn),v},r.prototype.contain=function(t,e){var i=this;return t>=i.x&&t<=i.x+i.width&&e>=i.y&&e<=i.y+i.height},r.prototype.clone=function(){return new r(this.x,this.y,this.width,this.height)},r.prototype.copy=function(t){r.copy(this,t)},r.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},r.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},r.prototype.isZero=function(){return this.width===0||this.height===0},r.create=function(t){return new r(t.x,t.y,t.width,t.height)},r.copy=function(t,e){t.x=e.x,t.y=e.y,t.width=e.width,t.height=e.height},r.applyTransform=function(t,e,i){if(!i){t!==e&&r.copy(t,e);return}if(i[1]<1e-5&&i[1]>-1e-5&&i[2]<1e-5&&i[2]>-1e-5){var n=i[0],a=i[3],o=i[4],s=i[5];t.x=e.x*n+o,t.y=e.y*a+s,t.width=e.width*n,t.height=e.height*a,t.width<0&&(t.x+=t.width,t.width=-t.width),t.height<0&&(t.y+=t.height,t.height=-t.height);return}Or.x=Nr.x=e.x,Or.y=Fr.y=e.y,Br.x=Fr.x=e.x+e.width,Br.y=Nr.y=e.y+e.height,Or.transform(i),Fr.transform(i),Br.transform(i),Nr.transform(i),t.x=Wa(Or.x,Br.x,Nr.x,Fr.x),t.y=Wa(Or.y,Br.y,Nr.y,Fr.y);var u=Ua(Or.x,Br.x,Nr.x,Fr.x),l=Ua(Or.y,Br.y,Nr.y,Fr.y);t.width=u-t.x,t.height=l-t.y},r})(),ly="silent";function oS(r,t,e){return{type:r,event:e,target:t.target,topTarget:t.topTarget,cancelBubble:!1,offsetX:e.zrX,offsetY:e.zrY,gestureEvent:e.gestureEvent,pinchX:e.pinchX,pinchY:e.pinchY,pinchScale:e.pinchScale,wheelDelta:e.zrDelta,zrByTouch:e.zrByTouch,which:e.which,stop:sS}}function sS(){hn(this.event)}var uS=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.handler=null,e}return t.prototype.dispose=function(){},t.prototype.setCursor=function(){},t})(de),Cn=(function(){function r(t,e){this.x=t,this.y=e}return r})(),lS=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],du=new et(0,0,0,0),fy=(function(r){O(t,r);function t(e,i,n,a,o){var s=r.call(this)||this;return s._hovered=new Cn(0,0),s.storage=e,s.painter=i,s.painterRoot=a,s._pointerSize=o,n=n||new uS,s.proxy=null,s.setHandlerProxy(n),s._draggingMgr=new U1(s),s}return t.prototype.setHandlerProxy=function(e){this.proxy&&this.proxy.dispose(),e&&(T(lS,function(i){e.on&&e.on(i,this[i],this)},this),e.handler=this),this.proxy=e},t.prototype.mousemove=function(e){var i=e.zrX,n=e.zrY,a=hy(this,i,n),o=this._hovered,s=o.target;s&&!s.__zr&&(o=this.findHover(o.x,o.y),s=o.target);var u=this._hovered=a?new Cn(i,n):this.findHover(i,n),l=u.target,f=this.proxy;f.setCursor&&f.setCursor(l?l.cursor:"default"),s&&l!==s&&this.dispatchToElement(o,"mouseout",e),this.dispatchToElement(u,"mousemove",e),l&&l!==s&&this.dispatchToElement(u,"mouseover",e)},t.prototype.mouseout=function(e){var i=e.zrEventControl;i!=="only_globalout"&&this.dispatchToElement(this._hovered,"mouseout",e),i!=="no_globalout"&&this.trigger("globalout",{type:"globalout",event:e})},t.prototype.resize=function(){this._hovered=new Cn(0,0)},t.prototype.dispatch=function(e,i){var n=this[e];n&&n.call(this,i)},t.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},t.prototype.setCursorStyle=function(e){var i=this.proxy;i.setCursor&&i.setCursor(e)},t.prototype.dispatchToElement=function(e,i,n){e=e||{};var a=e.target;if(!(a&&a.silent)){for(var o="on"+i,s=oS(i,e,n);a&&(a[o]&&(s.cancelBubble=!!a[o].call(a,s)),a.trigger(i,s),a=a.__hostTarget?a.__hostTarget:a.parent,!s.cancelBubble););s.cancelBubble||(this.trigger(i,s),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(u){typeof u[o]=="function"&&u[o].call(u,s),u.trigger&&u.trigger(i,s)}))}},t.prototype.findHover=function(e,i,n){var a=this.storage.getDisplayList(),o=new Cn(e,i);if(Hv(a,o,e,i,n),this._pointerSize&&!o.target){for(var s=[],u=this._pointerSize,l=u/2,f=new et(e-l,i-l,u,u),h=a.length-1;h>=0;h--){var v=a[h];v!==n&&!v.ignore&&!v.ignoreCoarsePointer&&(!v.parent||!v.parent.ignoreCoarsePointer)&&(du.copy(v.getBoundingRect()),v.transform&&du.applyTransform(v.transform),du.intersect(f)&&s.push(v))}if(s.length)for(var c=4,p=Math.PI/12,d=Math.PI*2,g=0;g<l;g+=c)for(var y=0;y<d;y+=p){var m=e+g*Math.cos(y),_=i+g*Math.sin(y);if(Hv(s,o,m,_,n),o.target)return o}}return o},t.prototype.processGesture=function(e,i){this._gestureMgr||(this._gestureMgr=new rS);var n=this._gestureMgr;i==="start"&&n.clear();var a=n.recognize(e,this.findHover(e.zrX,e.zrY,null).target,this.proxy.dom);if(i==="end"&&n.clear(),a){var o=a.type;e.gestureEvent=o;var s=new Cn;s.target=a.target,this.dispatchToElement(s,o,a.event)}},t})(de);T(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(r){fy.prototype[r]=function(t){var e=t.zrX,i=t.zrY,n=hy(this,e,i),a,o;if((r!=="mouseup"||!n)&&(a=this.findHover(e,i),o=a.target),r==="mousedown")this._downEl=o,this._downPoint=[t.zrX,t.zrY],this._upEl=o;else if(r==="mouseup")this._upEl=o;else if(r==="click"){if(this._downEl!==this._upEl||!this._downPoint||Jl(this._downPoint,[t.zrX,t.zrY])>4)return;this._downPoint=null}this.dispatchToElement(a,r,t)}});function fS(r,t,e){if(r[r.rectHover?"rectContain":"contain"](t,e)){for(var i=r,n=void 0,a=!1;i;){if(i.ignoreClip&&(a=!0),!a){var o=i.getClipPath();if(o&&!o.contain(t,e))return!1}i.silent&&(n=!0);var s=i.__hostTarget;i=s||i.parent}return n?ly:!0}return!1}function Hv(r,t,e,i,n){for(var a=r.length-1;a>=0;a--){var o=r[a],s=void 0;if(o!==n&&!o.ignore&&(s=fS(o,e,i))&&(!t.topTarget&&(t.topTarget=o),s!==ly)){t.target=o;break}}}function hy(r,t,e){var i=r.painter;return t<0||t>i.getWidth()||e<0||e>i.getHeight()}var vy=32,Dn=7;function hS(r){for(var t=0;r>=vy;)t|=r&1,r>>=1;return r+t}function Gv(r,t,e,i){var n=t+1;if(n===e)return 1;if(i(r[n++],r[t])<0){for(;n<e&&i(r[n],r[n-1])<0;)n++;vS(r,t,n)}else for(;n<e&&i(r[n],r[n-1])>=0;)n++;return n-t}function vS(r,t,e){for(e--;t<e;){var i=r[t];r[t++]=r[e],r[e--]=i}}function Wv(r,t,e,i,n){for(i===t&&i++;i<e;i++){for(var a=r[i],o=t,s=i,u;o<s;)u=o+s>>>1,n(a,r[u])<0?s=u:o=u+1;var l=i-o;switch(l){case 3:r[o+3]=r[o+2];case 2:r[o+2]=r[o+1];case 1:r[o+1]=r[o];break;default:for(;l>0;)r[o+l]=r[o+l-1],l--}r[o]=a}}function gu(r,t,e,i,n,a){var o=0,s=0,u=1;if(a(r,t[e+n])>0){for(s=i-n;u<s&&a(r,t[e+n+u])>0;)o=u,u=(u<<1)+1,u<=0&&(u=s);u>s&&(u=s),o+=n,u+=n}else{for(s=n+1;u<s&&a(r,t[e+n-u])<=0;)o=u,u=(u<<1)+1,u<=0&&(u=s);u>s&&(u=s);var l=o;o=n-u,u=n-l}for(o++;o<u;){var f=o+(u-o>>>1);a(r,t[e+f])>0?o=f+1:u=f}return u}function yu(r,t,e,i,n,a){var o=0,s=0,u=1;if(a(r,t[e+n])<0){for(s=n+1;u<s&&a(r,t[e+n-u])<0;)o=u,u=(u<<1)+1,u<=0&&(u=s);u>s&&(u=s);var l=o;o=n-u,u=n-l}else{for(s=i-n;u<s&&a(r,t[e+n+u])>=0;)o=u,u=(u<<1)+1,u<=0&&(u=s);u>s&&(u=s),o+=n,u+=n}for(o++;o<u;){var f=o+(u-o>>>1);a(r,t[e+f])<0?u=f:o=f+1}return u}function cS(r,t){var e=Dn,i,n,a=0,o=[];i=[],n=[];function s(c,p){i[a]=c,n[a]=p,a+=1}function u(){for(;a>1;){var c=a-2;if(c>=1&&n[c-1]<=n[c]+n[c+1]||c>=2&&n[c-2]<=n[c]+n[c-1])n[c-1]<n[c+1]&&c--;else if(n[c]>n[c+1])break;f(c)}}function l(){for(;a>1;){var c=a-2;c>0&&n[c-1]<n[c+1]&&c--,f(c)}}function f(c){var p=i[c],d=n[c],g=i[c+1],y=n[c+1];n[c]=d+y,c===a-3&&(i[c+1]=i[c+2],n[c+1]=n[c+2]),a--;var m=yu(r[g],r,p,d,0,t);p+=m,d-=m,d!==0&&(y=gu(r[p+d-1],r,g,y,y-1,t),y!==0&&(d<=y?h(p,d,g,y):v(p,d,g,y)))}function h(c,p,d,g){var y=0;for(y=0;y<p;y++)o[y]=r[c+y];var m=0,_=d,S=c;if(r[S++]=r[_++],--g===0){for(y=0;y<p;y++)r[S+y]=o[m+y];return}if(p===1){for(y=0;y<g;y++)r[S+y]=r[_+y];r[S+g]=o[m];return}for(var b=e,w,x,C;;){w=0,x=0,C=!1;do if(t(r[_],o[m])<0){if(r[S++]=r[_++],x++,w=0,--g===0){C=!0;break}}else if(r[S++]=o[m++],w++,x=0,--p===1){C=!0;break}while((w|x)<b);if(C)break;do{if(w=yu(r[_],o,m,p,0,t),w!==0){for(y=0;y<w;y++)r[S+y]=o[m+y];if(S+=w,m+=w,p-=w,p<=1){C=!0;break}}if(r[S++]=r[_++],--g===0){C=!0;break}if(x=gu(o[m],r,_,g,0,t),x!==0){for(y=0;y<x;y++)r[S+y]=r[_+y];if(S+=x,_+=x,g-=x,g===0){C=!0;break}}if(r[S++]=o[m++],--p===1){C=!0;break}b--}while(w>=Dn||x>=Dn);if(C)break;b<0&&(b=0),b+=2}if(e=b,e<1&&(e=1),p===1){for(y=0;y<g;y++)r[S+y]=r[_+y];r[S+g]=o[m]}else{if(p===0)throw new Error;for(y=0;y<p;y++)r[S+y]=o[m+y]}}function v(c,p,d,g){var y=0;for(y=0;y<g;y++)o[y]=r[d+y];var m=c+p-1,_=g-1,S=d+g-1,b=0,w=0;if(r[S--]=r[m--],--p===0){for(b=S-(g-1),y=0;y<g;y++)r[b+y]=o[y];return}if(g===1){for(S-=p,m-=p,w=S+1,b=m+1,y=p-1;y>=0;y--)r[w+y]=r[b+y];r[S]=o[_];return}for(var x=e;;){var C=0,M=0,D=!1;do if(t(o[_],r[m])<0){if(r[S--]=r[m--],C++,M=0,--p===0){D=!0;break}}else if(r[S--]=o[_--],M++,C=0,--g===1){D=!0;break}while((C|M)<x);if(D)break;do{if(C=p-yu(o[_],r,c,p,p-1,t),C!==0){for(S-=C,m-=C,p-=C,w=S+1,b=m+1,y=C-1;y>=0;y--)r[w+y]=r[b+y];if(p===0){D=!0;break}}if(r[S--]=o[_--],--g===1){D=!0;break}if(M=g-gu(r[m],o,0,g,g-1,t),M!==0){for(S-=M,_-=M,g-=M,w=S+1,b=_+1,y=0;y<M;y++)r[w+y]=o[b+y];if(g<=1){D=!0;break}}if(r[S--]=r[m--],--p===0){D=!0;break}x--}while(C>=Dn||M>=Dn);if(D)break;x<0&&(x=0),x+=2}if(e=x,e<1&&(e=1),g===1){for(S-=p,m-=p,w=S+1,b=m+1,y=p-1;y>=0;y--)r[w+y]=r[b+y];r[S]=o[_]}else{if(g===0)throw new Error;for(b=S-(g-1),y=0;y<g;y++)r[b+y]=o[y]}}return{mergeRuns:u,forceMergeRuns:l,pushRun:s}}function Ro(r,t,e,i){e||(e=0),i||(i=r.length);var n=i-e;if(!(n<2)){var a=0;if(n<vy){a=Gv(r,e,i,t),Wv(r,e,i,e+a,t);return}var o=cS(r,t),s=hS(n);do{if(a=Gv(r,e,i,t),a<s){var u=n;u>s&&(u=s),Wv(r,e,e+u,e+a,t),a=u}o.pushRun(e,a),o.mergeRuns(),n-=a,e+=a}while(n!==0);o.forceMergeRuns()}}var Jt=1,Kn=2,Ui=4,Uv=!1;function mu(){Uv||(Uv=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function Yv(r,t){return r.zlevel===t.zlevel?r.z===t.z?r.z2-t.z2:r.z-t.z:r.zlevel-t.zlevel}var pS=(function(){function r(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=Yv}return r.prototype.traverse=function(t,e){for(var i=0;i<this._roots.length;i++)this._roots[i].traverse(t,e)},r.prototype.getDisplayList=function(t,e){e=e||!1;var i=this._displayList;return(t||!i.length)&&this.updateDisplayList(e),i},r.prototype.updateDisplayList=function(t){this._displayListLen=0;for(var e=this._roots,i=this._displayList,n=0,a=e.length;n<a;n++)this._updateAndAddDisplayable(e[n],null,t);i.length=this._displayListLen,Ro(i,Yv)},r.prototype._updateAndAddDisplayable=function(t,e,i){if(!(t.ignore&&!i)){t.beforeUpdate(),t.update(),t.afterUpdate();var n=t.getClipPath();if(t.ignoreClip)e=null;else if(n){e?e=e.slice():e=[];for(var a=n,o=t;a;)a.parent=o,a.updateTransform(),e.push(a),o=a,a=a.getClipPath()}if(t.childrenRef){for(var s=t.childrenRef(),u=0;u<s.length;u++){var l=s[u];t.__dirty&&(l.__dirty|=Jt),this._updateAndAddDisplayable(l,e,i)}t.__dirty=0}else{var f=t;e&&e.length?f.__clipPaths=e:f.__clipPaths&&f.__clipPaths.length>0&&(f.__clipPaths=[]),isNaN(f.z)&&(mu(),f.z=0),isNaN(f.z2)&&(mu(),f.z2=0),isNaN(f.zlevel)&&(mu(),f.zlevel=0),this._displayList[this._displayListLen++]=f}var h=t.getDecalElement&&t.getDecalElement();h&&this._updateAndAddDisplayable(h,e,i);var v=t.getTextGuideLine();v&&this._updateAndAddDisplayable(v,e,i);var c=t.getTextContent();c&&this._updateAndAddDisplayable(c,e,i)}},r.prototype.addRoot=function(t){t.__zr&&t.__zr.storage===this||this._roots.push(t)},r.prototype.delRoot=function(t){if(t instanceof Array){for(var e=0,i=t.length;e<i;e++)this.delRoot(t[e]);return}var n=Q(this._roots,t);n>=0&&this._roots.splice(n,1)},r.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},r.prototype.getRoots=function(){return this._roots},r.prototype.dispose=function(){this._displayList=null,this._roots=null},r})(),Zo;Zo=Z.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(r){return setTimeout(r,16)};var sa={linear:function(r){return r},quadraticIn:function(r){return r*r},quadraticOut:function(r){return r*(2-r)},quadraticInOut:function(r){return(r*=2)<1?.5*r*r:-.5*(--r*(r-2)-1)},cubicIn:function(r){return r*r*r},cubicOut:function(r){return--r*r*r+1},cubicInOut:function(r){return(r*=2)<1?.5*r*r*r:.5*((r-=2)*r*r+2)},quarticIn:function(r){return r*r*r*r},quarticOut:function(r){return 1- --r*r*r*r},quarticInOut:function(r){return(r*=2)<1?.5*r*r*r*r:-.5*((r-=2)*r*r*r-2)},quinticIn:function(r){return r*r*r*r*r},quinticOut:function(r){return--r*r*r*r*r+1},quinticInOut:function(r){return(r*=2)<1?.5*r*r*r*r*r:.5*((r-=2)*r*r*r*r+2)},sinusoidalIn:function(r){return 1-Math.cos(r*Math.PI/2)},sinusoidalOut:function(r){return Math.sin(r*Math.PI/2)},sinusoidalInOut:function(r){return .5*(1-Math.cos(Math.PI*r))},exponentialIn:function(r){return r===0?0:Math.pow(1024,r-1)},exponentialOut:function(r){return r===1?1:1-Math.pow(2,-10*r)},exponentialInOut:function(r){return r===0?0:r===1?1:(r*=2)<1?.5*Math.pow(1024,r-1):.5*(-Math.pow(2,-10*(r-1))+2)},circularIn:function(r){return 1-Math.sqrt(1-r*r)},circularOut:function(r){return Math.sqrt(1- --r*r)},circularInOut:function(r){return(r*=2)<1?-.5*(Math.sqrt(1-r*r)-1):.5*(Math.sqrt(1-(r-=2)*r)+1)},elasticIn:function(r){var t,e=.1,i=.4;return r===0?0:r===1?1:(!e||e<1?(e=1,t=i/4):t=i*Math.asin(1/e)/(2*Math.PI),-(e*Math.pow(2,10*(r-=1))*Math.sin((r-t)*(2*Math.PI)/i)))},elasticOut:function(r){var t,e=.1,i=.4;return r===0?0:r===1?1:(!e||e<1?(e=1,t=i/4):t=i*Math.asin(1/e)/(2*Math.PI),e*Math.pow(2,-10*r)*Math.sin((r-t)*(2*Math.PI)/i)+1)},elasticInOut:function(r){var t,e=.1,i=.4;return r===0?0:r===1?1:(!e||e<1?(e=1,t=i/4):t=i*Math.asin(1/e)/(2*Math.PI),(r*=2)<1?-.5*(e*Math.pow(2,10*(r-=1))*Math.sin((r-t)*(2*Math.PI)/i)):e*Math.pow(2,-10*(r-=1))*Math.sin((r-t)*(2*Math.PI)/i)*.5+1)},backIn:function(r){var t=1.70158;return r*r*((t+1)*r-t)},backOut:function(r){var t=1.70158;return--r*r*((t+1)*r+t)+1},backInOut:function(r){var t=2.5949095;return(r*=2)<1?.5*(r*r*((t+1)*r-t)):.5*((r-=2)*r*((t+1)*r+t)+2)},bounceIn:function(r){return 1-sa.bounceOut(1-r)},bounceOut:function(r){return r<1/2.75?7.5625*r*r:r<2/2.75?7.5625*(r-=1.5/2.75)*r+.75:r<2.5/2.75?7.5625*(r-=2.25/2.75)*r+.9375:7.5625*(r-=2.625/2.75)*r+.984375},bounceInOut:function(r){return r<.5?sa.bounceIn(r*2)*.5:sa.bounceOut(r*2-1)*.5+.5}},Ya=Math.pow,xr=Math.sqrt,Xo=1e-8,cy=1e-4,Zv=xr(3),Za=1/3,Ee=mn(),ue=mn(),rn=mn();function mr(r){return r>-Xo&&r<Xo}function py(r){return r>Xo||r<-Xo}function Mt(r,t,e,i,n){var a=1-n;return a*a*(a*r+3*n*t)+n*n*(n*i+3*a*e)}function Xv(r,t,e,i,n){var a=1-n;return 3*(((t-r)*a+2*(e-t)*n)*a+(i-e)*n*n)}function $o(r,t,e,i,n,a){var o=i+3*(t-e)-r,s=3*(e-t*2+r),u=3*(t-r),l=r-n,f=s*s-3*o*u,h=s*u-9*o*l,v=u*u-3*s*l,c=0;if(mr(f)&&mr(h))if(mr(s))a[0]=0;else{var p=-u/s;p>=0&&p<=1&&(a[c++]=p)}else{var d=h*h-4*f*v;if(mr(d)){var g=h/f,p=-s/o+g,y=-g/2;p>=0&&p<=1&&(a[c++]=p),y>=0&&y<=1&&(a[c++]=y)}else if(d>0){var m=xr(d),_=f*s+1.5*o*(-h+m),S=f*s+1.5*o*(-h-m);_<0?_=-Ya(-_,Za):_=Ya(_,Za),S<0?S=-Ya(-S,Za):S=Ya(S,Za);var p=(-s-(_+S))/(3*o);p>=0&&p<=1&&(a[c++]=p)}else{var b=(2*f*s-3*o*h)/(2*xr(f*f*f)),w=Math.acos(b)/3,x=xr(f),C=Math.cos(w),p=(-s-2*x*C)/(3*o),y=(-s+x*(C+Zv*Math.sin(w)))/(3*o),M=(-s+x*(C-Zv*Math.sin(w)))/(3*o);p>=0&&p<=1&&(a[c++]=p),y>=0&&y<=1&&(a[c++]=y),M>=0&&M<=1&&(a[c++]=M)}}return c}function dy(r,t,e,i,n){var a=6*e-12*t+6*r,o=9*t+3*i-3*r-9*e,s=3*t-3*r,u=0;if(mr(o)){if(py(a)){var l=-s/a;l>=0&&l<=1&&(n[u++]=l)}}else{var f=a*a-4*o*s;if(mr(f))n[0]=-a/(2*o);else if(f>0){var h=xr(f),l=(-a+h)/(2*o),v=(-a-h)/(2*o);l>=0&&l<=1&&(n[u++]=l),v>=0&&v<=1&&(n[u++]=v)}}return u}function qo(r,t,e,i,n,a){var o=(t-r)*n+r,s=(e-t)*n+t,u=(i-e)*n+e,l=(s-o)*n+o,f=(u-s)*n+s,h=(f-l)*n+l;a[0]=r,a[1]=o,a[2]=l,a[3]=h,a[4]=h,a[5]=f,a[6]=u,a[7]=i}function gy(r,t,e,i,n,a,o,s,u,l,f){var h,v=.005,c=1/0,p,d,g,y;Ee[0]=u,Ee[1]=l;for(var m=0;m<1;m+=.05)ue[0]=Mt(r,e,n,o,m),ue[1]=Mt(t,i,a,s,m),g=ji(Ee,ue),g<c&&(h=m,c=g);c=1/0;for(var _=0;_<32&&!(v<cy);_++)p=h-v,d=h+v,ue[0]=Mt(r,e,n,o,p),ue[1]=Mt(t,i,a,s,p),g=ji(ue,Ee),p>=0&&g<c?(h=p,c=g):(rn[0]=Mt(r,e,n,o,d),rn[1]=Mt(t,i,a,s,d),y=ji(rn,Ee),d<=1&&y<c?(h=d,c=y):v*=.5);return f&&(f[0]=Mt(r,e,n,o,h),f[1]=Mt(t,i,a,s,h)),xr(c)}function dS(r,t,e,i,n,a,o,s,u){for(var l=r,f=t,h=0,v=1/u,c=1;c<=u;c++){var p=c*v,d=Mt(r,e,n,o,p),g=Mt(t,i,a,s,p),y=d-l,m=g-f;h+=Math.sqrt(y*y+m*m),l=d,f=g}return h}function Et(r,t,e,i){var n=1-i;return n*(n*r+2*i*t)+i*i*e}function $v(r,t,e,i){return 2*((1-i)*(t-r)+i*(e-t))}function gS(r,t,e,i,n){var a=r-2*t+e,o=2*(t-r),s=r-i,u=0;if(mr(a)){if(py(o)){var l=-s/o;l>=0&&l<=1&&(n[u++]=l)}}else{var f=o*o-4*a*s;if(mr(f)){var l=-o/(2*a);l>=0&&l<=1&&(n[u++]=l)}else if(f>0){var h=xr(f),l=(-o+h)/(2*a),v=(-o-h)/(2*a);l>=0&&l<=1&&(n[u++]=l),v>=0&&v<=1&&(n[u++]=v)}}return u}function yy(r,t,e){var i=r+e-2*t;return i===0?.5:(r-t)/i}function Ko(r,t,e,i,n){var a=(t-r)*i+r,o=(e-t)*i+t,s=(o-a)*i+a;n[0]=r,n[1]=a,n[2]=s,n[3]=s,n[4]=o,n[5]=e}function my(r,t,e,i,n,a,o,s,u){var l,f=.005,h=1/0;Ee[0]=o,Ee[1]=s;for(var v=0;v<1;v+=.05){ue[0]=Et(r,e,n,v),ue[1]=Et(t,i,a,v);var c=ji(Ee,ue);c<h&&(l=v,h=c)}h=1/0;for(var p=0;p<32&&!(f<cy);p++){var d=l-f,g=l+f;ue[0]=Et(r,e,n,d),ue[1]=Et(t,i,a,d);var c=ji(ue,Ee);if(d>=0&&c<h)l=d,h=c;else{rn[0]=Et(r,e,n,g),rn[1]=Et(t,i,a,g);var y=ji(rn,Ee);g<=1&&y<h?(l=g,h=y):f*=.5}}return u&&(u[0]=Et(r,e,n,l),u[1]=Et(t,i,a,l)),xr(h)}function yS(r,t,e,i,n,a,o){for(var s=r,u=t,l=0,f=1/o,h=1;h<=o;h++){var v=h*f,c=Et(r,e,n,v),p=Et(t,i,a,v),d=c-s,g=p-u;l+=Math.sqrt(d*d+g*g),s=c,u=p}return l}var mS=/cubic-bezier\(([0-9,\.e ]+)\)/;function _y(r){var t=r&&mS.exec(r);if(t){var e=t[1].split(","),i=+Oe(e[0]),n=+Oe(e[1]),a=+Oe(e[2]),o=+Oe(e[3]);if(isNaN(i+n+a+o))return;var s=[];return function(u){return u<=0?0:u>=1?1:$o(0,i,a,1,u,s)&&Mt(0,n,o,1,s[0])}}}var _S=(function(){function r(t){this._inited=!1,this._startTime=0,this._pausedTime=0,this._paused=!1,this._life=t.life||1e3,this._delay=t.delay||0,this.loop=t.loop||!1,this.onframe=t.onframe||At,this.ondestroy=t.ondestroy||At,this.onrestart=t.onrestart||At,t.easing&&this.setEasing(t.easing)}return r.prototype.step=function(t,e){if(this._inited||(this._startTime=t+this._delay,this._inited=!0),this._paused){this._pausedTime+=e;return}var i=this._life,n=t-this._startTime-this._pausedTime,a=n/i;a<0&&(a=0),a=Math.min(a,1);var o=this.easingFunc,s=o?o(a):a;if(this.onframe(s),a===1)if(this.loop){var u=n%i;this._startTime=t-u,this._pausedTime=0,this.onrestart()}else return!0;return!1},r.prototype.pause=function(){this._paused=!0},r.prototype.resume=function(){this._paused=!1},r.prototype.setEasing=function(t){this.easing=t,this.easingFunc=q(t)?t:sa[t]||_y(t)},r})(),Sy=(function(){function r(t){this.value=t}return r})(),SS=(function(){function r(){this._len=0}return r.prototype.insert=function(t){var e=new Sy(t);return this.insertEntry(e),e},r.prototype.insertEntry=function(t){this.head?(this.tail.next=t,t.prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},r.prototype.remove=function(t){var e=t.prev,i=t.next;e?e.next=i:this.head=i,i?i.prev=e:this.tail=e,t.next=t.prev=null,this._len--},r.prototype.len=function(){return this._len},r.prototype.clear=function(){this.head=this.tail=null,this._len=0},r})(),Na=(function(){function r(t){this._list=new SS,this._maxSize=10,this._map={},this._maxSize=t}return r.prototype.put=function(t,e){var i=this._list,n=this._map,a=null;if(n[t]==null){var o=i.len(),s=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var u=i.head;i.remove(u),delete n[u.key],a=u.value,this._lastRemovedEntry=u}s?s.value=e:s=new Sy(e),s.key=t,i.insertEntry(s),n[t]=s}return a},r.prototype.get=function(t){var e=this._map[t],i=this._list;if(e!=null)return e!==i.tail&&(i.remove(e),i.insertEntry(e)),e.value},r.prototype.clear=function(){this._list.clear(),this._map={}},r.prototype.len=function(){return this._list.len()},r})(),qv={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 Te(r){return r=Math.round(r),r<0?0:r>255?255:r}function wS(r){return r=Math.round(r),r<0?0:r>360?360:r}function _a(r){return r<0?0:r>1?1:r}function _u(r){var t=r;return t.length&&t.charAt(t.length-1)==="%"?Te(parseFloat(t)/100*255):Te(parseInt(t,10))}function hi(r){var t=r;return t.length&&t.charAt(t.length-1)==="%"?_a(parseFloat(t)/100):_a(parseFloat(t))}function Su(r,t,e){return e<0?e+=1:e>1&&(e-=1),e*6<1?r+(t-r)*e*6:e*2<1?t:e*3<2?r+(t-r)*(2/3-e)*6:r}function _r(r,t,e){return r+(t-r)*e}function ne(r,t,e,i,n){return r[0]=t,r[1]=e,r[2]=i,r[3]=n,r}function nf(r,t){return r[0]=t[0],r[1]=t[1],r[2]=t[2],r[3]=t[3],r}var wy=new Na(20),Xa=null;function Pi(r,t){Xa&&nf(Xa,t),Xa=wy.put(r,Xa||t.slice())}function Me(r,t){if(r){t=t||[];var e=wy.get(r);if(e)return nf(t,e);r=r+"";var i=r.replace(/ /g,"").toLowerCase();if(i in qv)return nf(t,qv[i]),Pi(r,t),t;var n=i.length;if(i.charAt(0)==="#"){if(n===4||n===5){var a=parseInt(i.slice(1,4),16);if(!(a>=0&&a<=4095)){ne(t,0,0,0,1);return}return ne(t,(a&3840)>>4|(a&3840)>>8,a&240|(a&240)>>4,a&15|(a&15)<<4,n===5?parseInt(i.slice(4),16)/15:1),Pi(r,t),t}else if(n===7||n===9){var a=parseInt(i.slice(1,7),16);if(!(a>=0&&a<=16777215)){ne(t,0,0,0,1);return}return ne(t,(a&16711680)>>16,(a&65280)>>8,a&255,n===9?parseInt(i.slice(7),16)/255:1),Pi(r,t),t}return}var o=i.indexOf("("),s=i.indexOf(")");if(o!==-1&&s+1===n){var u=i.substr(0,o),l=i.substr(o+1,s-(o+1)).split(","),f=1;switch(u){case"rgba":if(l.length!==4)return l.length===3?ne(t,+l[0],+l[1],+l[2],1):ne(t,0,0,0,1);f=hi(l.pop());case"rgb":if(l.length>=3)return ne(t,_u(l[0]),_u(l[1]),_u(l[2]),l.length===3?f:hi(l[3])),Pi(r,t),t;ne(t,0,0,0,1);return;case"hsla":if(l.length!==4){ne(t,0,0,0,1);return}return l[3]=hi(l[3]),af(l,t),Pi(r,t),t;case"hsl":if(l.length!==3){ne(t,0,0,0,1);return}return af(l,t),Pi(r,t),t;default:return}}ne(t,0,0,0,1)}}function af(r,t){var e=(parseFloat(r[0])%360+360)%360/360,i=hi(r[1]),n=hi(r[2]),a=n<=.5?n*(i+1):n+i-n*i,o=n*2-a;return t=t||[],ne(t,Te(Su(o,a,e+1/3)*255),Te(Su(o,a,e)*255),Te(Su(o,a,e-1/3)*255),1),r.length===4&&(t[3]=r[3]),t}function bS(r){if(r){var t=r[0]/255,e=r[1]/255,i=r[2]/255,n=Math.min(t,e,i),a=Math.max(t,e,i),o=a-n,s=(a+n)/2,u,l;if(o===0)u=0,l=0;else{s<.5?l=o/(a+n):l=o/(2-a-n);var f=((a-t)/6+o/2)/o,h=((a-e)/6+o/2)/o,v=((a-i)/6+o/2)/o;t===a?u=v-h:e===a?u=1/3+f-v:i===a&&(u=2/3+h-f),u<0&&(u+=1),u>1&&(u-=1)}var c=[u*360,l,s];return r[3]!=null&&c.push(r[3]),c}}function Kv(r,t){var e=Me(r);if(e){for(var i=0;i<3;i++)e[i]=e[i]*(1-t)|0,e[i]>255?e[i]=255:e[i]<0&&(e[i]=0);return Tr(e,e.length===4?"rgba":"rgb")}}function wu(r,t,e){if(!(!(t&&t.length)||!(r>=0&&r<=1))){e=e||[];var i=r*(t.length-1),n=Math.floor(i),a=Math.ceil(i),o=t[n],s=t[a],u=i-n;return e[0]=Te(_r(o[0],s[0],u)),e[1]=Te(_r(o[1],s[1],u)),e[2]=Te(_r(o[2],s[2],u)),e[3]=_a(_r(o[3],s[3],u)),e}}function xS(r,t,e){if(!(!(t&&t.length)||!(r>=0&&r<=1))){var i=r*(t.length-1),n=Math.floor(i),a=Math.ceil(i),o=Me(t[n]),s=Me(t[a]),u=i-n,l=Tr([Te(_r(o[0],s[0],u)),Te(_r(o[1],s[1],u)),Te(_r(o[2],s[2],u)),_a(_r(o[3],s[3],u))],"rgba");return e?{color:l,leftIndex:n,rightIndex:a,value:i}:l}}function bu(r,t,e,i){var n=Me(r);if(r)return n=bS(n),t!=null&&(n[0]=wS(t)),e!=null&&(n[1]=hi(e)),i!=null&&(n[2]=hi(i)),Tr(af(n),"rgba")}function of(r,t){var e=Me(r);if(e&&t!=null)return e[3]=_a(t),Tr(e,"rgba")}function Tr(r,t){if(!(!r||!r.length)){var e=r[0]+","+r[1]+","+r[2];return(t==="rgba"||t==="hsva"||t==="hsla")&&(e+=","+r[3]),t+"("+e+")"}}function Qo(r,t){var e=Me(r);return e?(.299*e[0]+.587*e[1]+.114*e[2])*e[3]/255+(1-e[3])*t:0}var Qv=new Na(100);function Jv(r){if(H(r)){var t=Qv.get(r);return t||(t=Kv(r,-.1),Qv.put(r,t)),t}else if(Ds(r)){var e=k({},r);return e.colorStops=z(r.colorStops,function(i){return{offset:i.offset,color:Kv(i.color,-.1)}}),e}return r}function TS(r){return r.type==="linear"}function MS(r){return r.type==="radial"}(function(){return Z.hasGlobalWindow&&q(window.btoa)?function(r){return window.btoa(unescape(encodeURIComponent(r)))}:typeof Buffer<"u"?function(r){return Buffer.from(r).toString("base64")}:function(r){return null}})();var sf=Array.prototype.slice;function Xe(r,t,e){return(t-r)*e+r}function xu(r,t,e,i){for(var n=t.length,a=0;a<n;a++)r[a]=Xe(t[a],e[a],i);return r}function CS(r,t,e,i){for(var n=t.length,a=n&&t[0].length,o=0;o<n;o++){r[o]||(r[o]=[]);for(var s=0;s<a;s++)r[o][s]=Xe(t[o][s],e[o][s],i)}return r}function $a(r,t,e,i){for(var n=t.length,a=0;a<n;a++)r[a]=t[a]+e[a]*i;return r}function jv(r,t,e,i){for(var n=t.length,a=n&&t[0].length,o=0;o<n;o++){r[o]||(r[o]=[]);for(var s=0;s<a;s++)r[o][s]=t[o][s]+e[o][s]*i}return r}function DS(r,t){for(var e=r.length,i=t.length,n=e>i?t:r,a=Math.min(e,i),o=n[a-1]||{color:[0,0,0,0],offset:0},s=a;s<Math.max(e,i);s++)n.push({offset:o.offset,color:o.color.slice()})}function AS(r,t,e){var i=r,n=t;if(!(!i.push||!n.push)){var a=i.length,o=n.length;if(a!==o){var s=a>o;if(s)i.length=o;else for(var u=a;u<o;u++)i.push(e===1?n[u]:sf.call(n[u]))}for(var l=i[0]&&i[0].length,u=0;u<i.length;u++)if(e===1)isNaN(i[u])&&(i[u]=n[u]);else for(var f=0;f<l;f++)isNaN(i[u][f])&&(i[u][f]=n[u][f])}}function ua(r){if(zt(r)){var t=r.length;if(zt(r[0])){for(var e=[],i=0;i<t;i++)e.push(sf.call(r[i]));return e}return sf.call(r)}return r}function Eo(r){return r[0]=Math.floor(r[0])||0,r[1]=Math.floor(r[1])||0,r[2]=Math.floor(r[2])||0,r[3]=r[3]==null?1:r[3],"rgba("+r.join(",")+")"}function LS(r){return zt(r&&r[0])?2:1}var qa=0,ko=1,by=2,Qn=3,uf=4,lf=5,tc=6;function ec(r){return r===uf||r===lf}function Ka(r){return r===ko||r===by}var An=[0,0,0,0],PS=(function(){function r(t){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=t}return r.prototype.isFinished=function(){return this._finished},r.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},r.prototype.needsAnimate=function(){return this.keyframes.length>=1},r.prototype.getAdditiveTrack=function(){return this._additiveTrack},r.prototype.addKeyframe=function(t,e,i){this._needsSort=!0;var n=this.keyframes,a=n.length,o=!1,s=tc,u=e;if(zt(e)){var l=LS(e);s=l,(l===1&&!dt(e[0])||l===2&&!dt(e[0][0]))&&(o=!0)}else if(dt(e)&&!Yo(e))s=qa;else if(H(e))if(!isNaN(+e))s=qa;else{var f=Me(e);f&&(u=f,s=Qn)}else if(Ds(e)){var h=k({},u);h.colorStops=z(e.colorStops,function(c){return{offset:c.offset,color:Me(c.color)}}),TS(e)?s=uf:MS(e)&&(s=lf),u=h}a===0?this.valType=s:(s!==this.valType||s===tc)&&(o=!0),this.discrete=this.discrete||o;var v={time:t,value:u,rawValue:e,percent:0};return i&&(v.easing=i,v.easingFunc=q(i)?i:sa[i]||_y(i)),n.push(v),v},r.prototype.prepare=function(t,e){var i=this.keyframes;this._needsSort&&i.sort(function(d,g){return d.time-g.time});for(var n=this.valType,a=i.length,o=i[a-1],s=this.discrete,u=Ka(n),l=ec(n),f=0;f<a;f++){var h=i[f],v=h.value,c=o.value;h.percent=h.time/t,s||(u&&f!==a-1?AS(v,c,n):l&&DS(v.colorStops,c.colorStops))}if(!s&&n!==lf&&e&&this.needsAnimate()&&e.needsAnimate()&&n===e.valType&&!e._finished){this._additiveTrack=e;for(var p=i[0].value,f=0;f<a;f++)n===qa?i[f].additiveValue=i[f].value-p:n===Qn?i[f].additiveValue=$a([],i[f].value,p,-1):Ka(n)&&(i[f].additiveValue=n===ko?$a([],i[f].value,p,-1):jv([],i[f].value,p,-1))}},r.prototype.step=function(t,e){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var i=this._additiveTrack!=null,n=i?"additiveValue":"value",a=this.valType,o=this.keyframes,s=o.length,u=this.propName,l=a===Qn,f,h=this._lastFr,v=Math.min,c,p;if(s===1)c=p=o[0];else{if(e<0)f=0;else if(e<this._lastFrP){var d=v(h+1,s-1);for(f=d;f>=0&&!(o[f].percent<=e);f--);f=v(f,s-2)}else{for(f=h;f<s&&!(o[f].percent>e);f++);f=v(f-1,s-2)}p=o[f+1],c=o[f]}if(c&&p){this._lastFr=f,this._lastFrP=e;var g=p.percent-c.percent,y=g===0?1:v((e-c.percent)/g,1);p.easingFunc&&(y=p.easingFunc(y));var m=i?this._additiveValue:l?An:t[u];if((Ka(a)||l)&&!m&&(m=this._additiveValue=[]),this.discrete)t[u]=y<1?c.rawValue:p.rawValue;else if(Ka(a))a===ko?xu(m,c[n],p[n],y):CS(m,c[n],p[n],y);else if(ec(a)){var _=c[n],S=p[n],b=a===uf;t[u]={type:b?"linear":"radial",x:Xe(_.x,S.x,y),y:Xe(_.y,S.y,y),colorStops:z(_.colorStops,function(x,C){var M=S.colorStops[C];return{offset:Xe(x.offset,M.offset,y),color:Eo(xu([],x.color,M.color,y))}}),global:S.global},b?(t[u].x2=Xe(_.x2,S.x2,y),t[u].y2=Xe(_.y2,S.y2,y)):t[u].r=Xe(_.r,S.r,y)}else if(l)xu(m,c[n],p[n],y),i||(t[u]=Eo(m));else{var w=Xe(c[n],p[n],y);i?this._additiveValue=w:t[u]=w}i&&this._addToTarget(t)}}},r.prototype._addToTarget=function(t){var e=this.valType,i=this.propName,n=this._additiveValue;e===qa?t[i]=t[i]+n:e===Qn?(Me(t[i],An),$a(An,An,n,1),t[i]=Eo(An)):e===ko?$a(t[i],t[i],n,1):e===by&&jv(t[i],t[i],n,1)},r})(),_h=(function(){function r(t,e,i,n){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=t,this._loop=e,e&&n){ch("Can' use additive animation on looped animation.");return}this._additiveAnimators=n,this._allowDiscrete=i}return r.prototype.getMaxTime=function(){return this._maxTime},r.prototype.getDelay=function(){return this._delay},r.prototype.getLoop=function(){return this._loop},r.prototype.getTarget=function(){return this._target},r.prototype.changeTarget=function(t){this._target=t},r.prototype.when=function(t,e,i){return this.whenWithKeys(t,e,ft(e),i)},r.prototype.whenWithKeys=function(t,e,i,n){for(var a=this._tracks,o=0;o<i.length;o++){var s=i[o],u=a[s];if(!u){u=a[s]=new PS(s);var l=void 0,f=this._getAdditiveTrack(s);if(f){var h=f.keyframes,v=h[h.length-1];l=v&&v.value,f.valType===Qn&&l&&(l=Eo(l))}else l=this._target[s];if(l==null)continue;t>0&&u.addKeyframe(0,ua(l),n),this._trackKeys.push(s)}u.addKeyframe(t,ua(e[s]),n)}return this._maxTime=Math.max(this._maxTime,t),this},r.prototype.pause=function(){this._clip.pause(),this._paused=!0},r.prototype.resume=function(){this._clip.resume(),this._paused=!1},r.prototype.isPaused=function(){return!!this._paused},r.prototype.duration=function(t){return this._maxTime=t,this._force=!0,this},r.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var t=this._doneCbs;if(t)for(var e=t.length,i=0;i<e;i++)t[i].call(this)},r.prototype._abortedCallback=function(){this._setTracksFinished();var t=this.animation,e=this._abortedCbs;if(t&&t.removeClip(this._clip),this._clip=null,e)for(var i=0;i<e.length;i++)e[i].call(this)},r.prototype._setTracksFinished=function(){for(var t=this._tracks,e=this._trackKeys,i=0;i<e.length;i++)t[e[i]].setFinished()},r.prototype._getAdditiveTrack=function(t){var e,i=this._additiveAnimators;if(i)for(var n=0;n<i.length;n++){var a=i[n].getTrack(t);a&&(e=a)}return e},r.prototype.start=function(t){if(!(this._started>0)){this._started=1;for(var e=this,i=[],n=this._maxTime||0,a=0;a<this._trackKeys.length;a++){var o=this._trackKeys[a],s=this._tracks[o],u=this._getAdditiveTrack(o),l=s.keyframes,f=l.length;if(s.prepare(n,u),s.needsAnimate())if(!this._allowDiscrete&&s.discrete){var h=l[f-1];h&&(e._target[s.propName]=h.rawValue),s.setFinished()}else i.push(s)}if(i.length||this._force){var v=new _S({life:n,loop:this._loop,delay:this._delay||0,onframe:function(c){e._started=2;var p=e._additiveAnimators;if(p){for(var d=!1,g=0;g<p.length;g++)if(p[g]._clip){d=!0;break}d||(e._additiveAnimators=null)}for(var g=0;g<i.length;g++)i[g].step(e._target,c);var y=e._onframeCbs;if(y)for(var g=0;g<y.length;g++)y[g](e._target,c)},ondestroy:function(){e._doneCallback()}});this._clip=v,this.animation&&this.animation.addClip(v),t&&v.setEasing(t)}else this._doneCallback();return this}},r.prototype.stop=function(t){if(this._clip){var e=this._clip;t&&e.onframe(1),this._abortedCallback()}},r.prototype.delay=function(t){return this._delay=t,this},r.prototype.during=function(t){return t&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(t)),this},r.prototype.done=function(t){return t&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(t)),this},r.prototype.aborted=function(t){return t&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(t)),this},r.prototype.getClip=function(){return this._clip},r.prototype.getTrack=function(t){return this._tracks[t]},r.prototype.getTracks=function(){var t=this;return z(this._trackKeys,function(e){return t._tracks[e]})},r.prototype.stopTracks=function(t,e){if(!t.length||!this._clip)return!0;for(var i=this._tracks,n=this._trackKeys,a=0;a<t.length;a++){var o=i[t[a]];o&&!o.isFinished()&&(e?o.step(this._target,1):this._started===1&&o.step(this._target,0),o.setFinished())}for(var s=!0,a=0;a<n.length;a++)if(!i[n[a]].isFinished()){s=!1;break}return s&&this._abortedCallback(),s},r.prototype.saveTo=function(t,e,i){if(t){e=e||this._trackKeys;for(var n=0;n<e.length;n++){var a=e[n],o=this._tracks[a];if(!(!o||o.isFinished())){var s=o.keyframes,u=s[i?0:s.length-1];u&&(t[a]=ua(u.rawValue))}}}},r.prototype.__changeFinalValue=function(t,e){e=e||ft(t);for(var i=0;i<e.length;i++){var n=e[i],a=this._tracks[n];if(a){var o=a.keyframes;if(o.length>1){var s=o.pop();a.addKeyframe(s.time,t[n]),a.prepare(this._maxTime,a.getAdditiveTrack())}}}},r})();function qi(){return new Date().getTime()}var IS=(function(r){O(t,r);function t(e){var i=r.call(this)||this;return i._running=!1,i._time=0,i._pausedTime=0,i._pauseStart=0,i._paused=!1,e=e||{},i.stage=e.stage||{},i}return t.prototype.addClip=function(e){e.animation&&this.removeClip(e),this._head?(this._tail.next=e,e.prev=this._tail,e.next=null,this._tail=e):this._head=this._tail=e,e.animation=this},t.prototype.addAnimator=function(e){e.animation=this;var i=e.getClip();i&&this.addClip(i)},t.prototype.removeClip=function(e){if(e.animation){var i=e.prev,n=e.next;i?i.next=n:this._head=n,n?n.prev=i:this._tail=i,e.next=e.prev=e.animation=null}},t.prototype.removeAnimator=function(e){var i=e.getClip();i&&this.removeClip(i),e.animation=null},t.prototype.update=function(e){for(var i=qi()-this._pausedTime,n=i-this._time,a=this._head;a;){var o=a.next,s=a.step(i,n);s&&(a.ondestroy(),this.removeClip(a)),a=o}this._time=i,e||(this.trigger("frame",n),this.stage.update&&this.stage.update())},t.prototype._startLoop=function(){var e=this;this._running=!0;function i(){e._running&&(Zo(i),!e._paused&&e.update())}Zo(i)},t.prototype.start=function(){this._running||(this._time=qi(),this._pausedTime=0,this._startLoop())},t.prototype.stop=function(){this._running=!1},t.prototype.pause=function(){this._paused||(this._pauseStart=qi(),this._paused=!0)},t.prototype.resume=function(){this._paused&&(this._pausedTime+=qi()-this._pauseStart,this._paused=!1)},t.prototype.clear=function(){for(var e=this._head;e;){var i=e.next;e.prev=e.next=e.animation=null,e=i}this._head=this._tail=null},t.prototype.isFinished=function(){return this._head==null},t.prototype.animate=function(e,i){i=i||{},this.start();var n=new _h(e,i.loop);return this.addAnimator(n),n},t})(de),RS=300,Tu=Z.domSupported,Mu=(function(){var r=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],t=["touchstart","touchend","touchmove"],e={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},i=z(r,function(n){var a=n.replace("mouse","pointer");return e.hasOwnProperty(a)?a:n});return{mouse:r,touch:t,pointer:i}})(),rc={mouse:["mousemove","mouseup"],pointer:["pointermove","pointerup"]},ic=!1;function ff(r){var t=r.pointerType;return t==="pen"||t==="touch"}function ES(r){r.touching=!0,r.touchTimer!=null&&(clearTimeout(r.touchTimer),r.touchTimer=null),r.touchTimer=setTimeout(function(){r.touching=!1,r.touchTimer=null},700)}function Cu(r){r&&(r.zrByTouch=!0)}function kS(r,t){return ae(r.dom,new OS(r,t),!0)}function xy(r,t){for(var e=t,i=!1;e&&e.nodeType!==9&&!(i=e.domBelongToZr||e!==t&&e===r.painterRoot);)e=e.parentNode;return i}var OS=(function(){function r(t,e){this.stopPropagation=At,this.stopImmediatePropagation=At,this.preventDefault=At,this.type=e.type,this.target=this.currentTarget=t.dom,this.pointerType=e.pointerType,this.clientX=e.clientX,this.clientY=e.clientY}return r})(),we={mousedown:function(r){r=ae(this.dom,r),this.__mayPointerCapture=[r.zrX,r.zrY],this.trigger("mousedown",r)},mousemove:function(r){r=ae(this.dom,r);var t=this.__mayPointerCapture;t&&(r.zrX!==t[0]||r.zrY!==t[1])&&this.__togglePointerCapture(!0),this.trigger("mousemove",r)},mouseup:function(r){r=ae(this.dom,r),this.__togglePointerCapture(!1),this.trigger("mouseup",r)},mouseout:function(r){r=ae(this.dom,r);var t=r.toElement||r.relatedTarget;xy(this,t)||(this.__pointerCapturing&&(r.zrEventControl="no_globalout"),this.trigger("mouseout",r))},wheel:function(r){ic=!0,r=ae(this.dom,r),this.trigger("mousewheel",r)},mousewheel:function(r){ic||(r=ae(this.dom,r),this.trigger("mousewheel",r))},touchstart:function(r){r=ae(this.dom,r),Cu(r),this.__lastTouchMoment=new Date,this.handler.processGesture(r,"start"),we.mousemove.call(this,r),we.mousedown.call(this,r)},touchmove:function(r){r=ae(this.dom,r),Cu(r),this.handler.processGesture(r,"change"),we.mousemove.call(this,r)},touchend:function(r){r=ae(this.dom,r),Cu(r),this.handler.processGesture(r,"end"),we.mouseup.call(this,r),+new Date-+this.__lastTouchMoment<RS&&we.click.call(this,r)},pointerdown:function(r){we.mousedown.call(this,r)},pointermove:function(r){ff(r)||we.mousemove.call(this,r)},pointerup:function(r){we.mouseup.call(this,r)},pointerout:function(r){ff(r)||we.mouseout.call(this,r)}};T(["click","dblclick","contextmenu"],function(r){we[r]=function(t){t=ae(this.dom,t),this.trigger(r,t)}});var hf={pointermove:function(r){ff(r)||hf.mousemove.call(this,r)},pointerup:function(r){hf.mouseup.call(this,r)},mousemove:function(r){this.trigger("mousemove",r)},mouseup:function(r){var t=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",r),t&&(r.zrEventControl="only_globalout",this.trigger("mouseout",r))}};function BS(r,t){var e=t.domHandlers;Z.pointerEventsSupported?T(Mu.pointer,function(i){Oo(t,i,function(n){e[i].call(r,n)})}):(Z.touchEventsSupported&&T(Mu.touch,function(i){Oo(t,i,function(n){e[i].call(r,n),ES(t)})}),T(Mu.mouse,function(i){Oo(t,i,function(n){n=gh(n),t.touching||e[i].call(r,n)})}))}function NS(r,t){Z.pointerEventsSupported?T(rc.pointer,e):Z.touchEventsSupported||T(rc.mouse,e);function e(i){function n(a){a=gh(a),xy(r,a.target)||(a=kS(r,a),t.domHandlers[i].call(r,a))}Oo(t,i,n,{capture:!0})}}function Oo(r,t,e,i){r.mounted[t]=e,r.listenerOpts[t]=i,tS(r.domTarget,t,e,i)}function Du(r){var t=r.mounted;for(var e in t)t.hasOwnProperty(e)&&eS(r.domTarget,e,t[e],r.listenerOpts[e]);r.mounted={}}var nc=(function(){function r(t,e){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=t,this.domHandlers=e}return r})(),FS=(function(r){O(t,r);function t(e,i){var n=r.call(this)||this;return n.__pointerCapturing=!1,n.dom=e,n.painterRoot=i,n._localHandlerScope=new nc(e,we),Tu&&(n._globalHandlerScope=new nc(document,hf)),BS(n,n._localHandlerScope),n}return t.prototype.dispose=function(){Du(this._localHandlerScope),Tu&&Du(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,Tu&&+this.__pointerCapturing^+e){this.__pointerCapturing=e;var i=this._globalHandlerScope;e?NS(this,i):Du(i)}},t})(de),Ty=1;Z.hasGlobalWindow&&(Ty=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var Jo=Ty,vf=.4,cf="#333",pf="#ccc",zS="#eee",ac=yh,oc=5e-5;function zr(r){return r>oc||r<-oc}var Vr=[],Ii=[],Au=tn(),Lu=Math.abs,Ps=(function(){function r(){}return r.prototype.getLocalTransform=function(t){return r.getLocalTransform(this,t)},r.prototype.setPosition=function(t){this.x=t[0],this.y=t[1]},r.prototype.setScale=function(t){this.scaleX=t[0],this.scaleY=t[1]},r.prototype.setSkew=function(t){this.skewX=t[0],this.skewY=t[1]},r.prototype.setOrigin=function(t){this.originX=t[0],this.originY=t[1]},r.prototype.needLocalTransform=function(){return zr(this.rotation)||zr(this.x)||zr(this.y)||zr(this.scaleX-1)||zr(this.scaleY-1)||zr(this.skewX)||zr(this.skewY)},r.prototype.updateTransform=function(){var t=this.parent&&this.parent.transform,e=this.needLocalTransform(),i=this.transform;if(!(e||t)){i&&(ac(i),this.invTransform=null);return}i=i||tn(),e?this.getLocalTransform(i):ac(i),t&&(e?en(i,t,i):nS(i,t)),this.transform=i,this._resolveGlobalScaleRatio(i)},r.prototype._resolveGlobalScaleRatio=function(t){var e=this.globalScaleRatio;if(e!=null&&e!==1){this.getGlobalScale(Vr);var i=Vr[0]<0?-1:1,n=Vr[1]<0?-1:1,a=((Vr[0]-i)*e+i)/Vr[0]||0,o=((Vr[1]-n)*e+n)/Vr[1]||0;t[0]*=a,t[1]*=a,t[2]*=o,t[3]*=o}this.invTransform=this.invTransform||tn(),Ls(this.invTransform,t)},r.prototype.getComputedTransform=function(){for(var t=this,e=[];t;)e.push(t),t=t.parent;for(;t=e.pop();)t.updateTransform();return this.transform},r.prototype.setLocalTransform=function(t){if(t){var e=t[0]*t[0]+t[1]*t[1],i=t[2]*t[2]+t[3]*t[3],n=Math.atan2(t[1],t[0]),a=Math.PI/2+n-Math.atan2(t[3],t[2]);i=Math.sqrt(i)*Math.cos(a),e=Math.sqrt(e),this.skewX=a,this.skewY=0,this.rotation=-n,this.x=+t[4],this.y=+t[5],this.scaleX=e,this.scaleY=i,this.originX=0,this.originY=0}},r.prototype.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(t.invTransform=t.invTransform||tn(),en(Ii,t.invTransform,e),e=Ii);var i=this.originX,n=this.originY;(i||n)&&(Au[4]=i,Au[5]=n,en(Ii,e,Au),Ii[4]-=i,Ii[5]-=n,e=Ii),this.setLocalTransform(e)}},r.prototype.getGlobalScale=function(t){var e=this.transform;return t=t||[],e?(t[0]=Math.sqrt(e[0]*e[0]+e[1]*e[1]),t[1]=Math.sqrt(e[2]*e[2]+e[3]*e[3]),e[0]<0&&(t[0]=-t[0]),e[3]<0&&(t[1]=-t[1]),t):(t[0]=1,t[1]=1,t)},r.prototype.transformCoordToLocal=function(t,e){var i=[t,e],n=this.invTransform;return n&&ve(i,i,n),i},r.prototype.transformCoordToGlobal=function(t,e){var i=[t,e],n=this.transform;return n&&ve(i,i,n),i},r.prototype.getLineScale=function(){var t=this.transform;return t&&Lu(t[0]-1)>1e-10&&Lu(t[3]-1)>1e-10?Math.sqrt(Lu(t[0]*t[3]-t[2]*t[1])):1},r.prototype.copyTransform=function(t){VS(this,t)},r.getLocalTransform=function(t,e){e=e||[];var i=t.originX||0,n=t.originY||0,a=t.scaleX,o=t.scaleY,s=t.anchorX,u=t.anchorY,l=t.rotation||0,f=t.x,h=t.y,v=t.skewX?Math.tan(t.skewX):0,c=t.skewY?Math.tan(-t.skewY):0;if(i||n||s||u){var p=i+s,d=n+u;e[4]=-p*a-v*d*o,e[5]=-d*o-c*p*a}else e[4]=e[5]=0;return e[0]=a,e[3]=o,e[1]=c*a,e[2]=v*o,l&&mh(e,e,l),e[4]+=i+f,e[5]+=n+h,e},r.initDefaultProps=(function(){var t=r.prototype;t.scaleX=t.scaleY=t.globalScaleRatio=1,t.x=t.y=t.originX=t.originY=t.skewX=t.skewY=t.rotation=t.anchorX=t.anchorY=0})(),r})(),Ve=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function VS(r,t){for(var e=0;e<Ve.length;e++){var i=Ve[e];r[i]=t[i]}}var sc={};function jt(r,t){t=t||di;var e=sc[t];e||(e=sc[t]=new Na(500));var i=e.get(r);return i==null&&(i=yn.measureText(r,t).width,e.put(r,i)),i}function uc(r,t,e,i){var n=jt(r,t),a=wh(t),o=Jn(0,n,e),s=Yi(0,a,i),u=new et(o,s,n,a);return u}function Sh(r,t,e,i){var n=((r||"")+"").split(`
15
+ `),a=n.length;if(a===1)return uc(n[0],t,e,i);for(var o=new et(0,0,0,0),s=0;s<n.length;s++){var u=uc(n[s],t,e,i);s===0?o.copy(u):o.union(u)}return o}function Jn(r,t,e){return e==="right"?r-=t:e==="center"&&(r-=t/2),r}function Yi(r,t,e){return e==="middle"?r-=t/2:e==="bottom"&&(r-=t),r}function wh(r){return jt("国",r)}function gi(r,t){return typeof r=="string"?r.lastIndexOf("%")>=0?parseFloat(r)/100*t:parseFloat(r):r}function My(r,t,e){var i=t.position||"inside",n=t.distance!=null?t.distance:5,a=e.height,o=e.width,s=a/2,u=e.x,l=e.y,f="left",h="top";if(i instanceof Array)u+=gi(i[0],e.width),l+=gi(i[1],e.height),f=null,h=null;else switch(i){case"left":u-=n,l+=s,f="right",h="middle";break;case"right":u+=n+o,l+=s,h="middle";break;case"top":u+=o/2,l-=n,f="center",h="bottom";break;case"bottom":u+=o/2,l+=a+n,f="center";break;case"inside":u+=o/2,l+=s,f="center",h="middle";break;case"insideLeft":u+=n,l+=s,h="middle";break;case"insideRight":u+=o-n,l+=s,f="right",h="middle";break;case"insideTop":u+=o/2,l+=n,f="center";break;case"insideBottom":u+=o/2,l+=a-n,f="center",h="bottom";break;case"insideTopLeft":u+=n,l+=n;break;case"insideTopRight":u+=o-n,l+=n,f="right";break;case"insideBottomLeft":u+=n,l+=a-n,h="bottom";break;case"insideBottomRight":u+=o-n,l+=a-n,f="right",h="bottom";break}return r=r||{},r.x=u,r.y=l,r.align=f,r.verticalAlign=h,r}var Pu="__zr_normal__",Iu=Ve.concat(["ignore"]),HS=Ti(Ve,function(r,t){return r[t]=!0,r},{ignore:!1}),Ri={},GS=new et(0,0,0,0),Is=(function(){function r(t){this.id=ry(),this.animators=[],this.currentStates=[],this.states={},this._init(t)}return r.prototype._init=function(t){this.attr(t)},r.prototype.drift=function(t,e,i){switch(this.draggable){case"horizontal":e=0;break;case"vertical":t=0;break}var n=this.transform;n||(n=this.transform=[1,0,0,1,0,0]),n[4]+=t,n[5]+=e,this.decomposeTransform(),this.markRedraw()},r.prototype.beforeUpdate=function(){},r.prototype.afterUpdate=function(){},r.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},r.prototype.updateInnerText=function(t){var e=this._textContent;if(e&&(!e.ignore||t)){this.textConfig||(this.textConfig={});var i=this.textConfig,n=i.local,a=e.innerTransformable,o=void 0,s=void 0,u=!1;a.parent=n?this:null;var l=!1;if(a.copyTransform(e),i.position!=null){var f=GS;i.layoutRect?f.copy(i.layoutRect):f.copy(this.getBoundingRect()),n||f.applyTransform(this.transform),this.calculateTextPosition?this.calculateTextPosition(Ri,i,f):My(Ri,i,f),a.x=Ri.x,a.y=Ri.y,o=Ri.align,s=Ri.verticalAlign;var h=i.origin;if(h&&i.rotation!=null){var v=void 0,c=void 0;h==="center"?(v=f.width*.5,c=f.height*.5):(v=gi(h[0],f.width),c=gi(h[1],f.height)),l=!0,a.originX=-a.x+v+(n?0:f.x),a.originY=-a.y+c+(n?0:f.y)}}i.rotation!=null&&(a.rotation=i.rotation);var p=i.offset;p&&(a.x+=p[0],a.y+=p[1],l||(a.originX=-p[0],a.originY=-p[1]));var d=i.inside==null?typeof i.position=="string"&&i.position.indexOf("inside")>=0:i.inside,g=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={}),y=void 0,m=void 0,_=void 0;d&&this.canBeInsideText()?(y=i.insideFill,m=i.insideStroke,(y==null||y==="auto")&&(y=this.getInsideTextFill()),(m==null||m==="auto")&&(m=this.getInsideTextStroke(y),_=!0)):(y=i.outsideFill,m=i.outsideStroke,(y==null||y==="auto")&&(y=this.getOutsideFill()),(m==null||m==="auto")&&(m=this.getOutsideStroke(y),_=!0)),y=y||"#000",(y!==g.fill||m!==g.stroke||_!==g.autoStroke||o!==g.align||s!==g.verticalAlign)&&(u=!0,g.fill=y,g.stroke=m,g.autoStroke=_,g.align=o,g.verticalAlign=s,e.setDefaultTextStyle(g)),e.__dirty|=Jt,u&&e.dirtyStyle(!0)}},r.prototype.canBeInsideText=function(){return!0},r.prototype.getInsideTextFill=function(){return"#fff"},r.prototype.getInsideTextStroke=function(t){return"#000"},r.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?pf:cf},r.prototype.getOutsideStroke=function(t){var e=this.__zr&&this.__zr.getBackgroundColor(),i=typeof e=="string"&&Me(e);i||(i=[255,255,255,1]);for(var n=i[3],a=this.__zr.isDarkMode(),o=0;o<3;o++)i[o]=i[o]*n+(a?0:255)*(1-n);return i[3]=1,Tr(i,"rgba")},r.prototype.traverse=function(t,e){},r.prototype.attrKV=function(t,e){t==="textConfig"?this.setTextConfig(e):t==="textContent"?this.setTextContent(e):t==="clipPath"?this.setClipPath(e):t==="extra"?(this.extra=this.extra||{},k(this.extra,e)):this[t]=e},r.prototype.hide=function(){this.ignore=!0,this.markRedraw()},r.prototype.show=function(){this.ignore=!1,this.markRedraw()},r.prototype.attr=function(t,e){if(typeof t=="string")this.attrKV(t,e);else if(W(t))for(var i=t,n=ft(i),a=0;a<n.length;a++){var o=n[a];this.attrKV(o,t[o])}return this.markRedraw(),this},r.prototype.saveCurrentToNormalState=function(t){this._innerSaveToNormal(t);for(var e=this._normalState,i=0;i<this.animators.length;i++){var n=this.animators[i],a=n.__fromStateTransition;if(!(n.getLoop()||a&&a!==Pu)){var o=n.targetName,s=o?e[o]:e;n.saveTo(s)}}},r.prototype._innerSaveToNormal=function(t){var e=this._normalState;e||(e=this._normalState={}),t.textConfig&&!e.textConfig&&(e.textConfig=this.textConfig),this._savePrimaryToNormal(t,e,Iu)},r.prototype._savePrimaryToNormal=function(t,e,i){for(var n=0;n<i.length;n++){var a=i[n];t[a]!=null&&!(a in e)&&(e[a]=this[a])}},r.prototype.hasState=function(){return this.currentStates.length>0},r.prototype.getState=function(t){return this.states[t]},r.prototype.ensureState=function(t){var e=this.states;return e[t]||(e[t]={}),e[t]},r.prototype.clearStates=function(t){this.useState(Pu,!1,t)},r.prototype.useState=function(t,e,i,n){var a=t===Pu,o=this.hasState();if(!(!o&&a)){var s=this.currentStates,u=this.stateTransition;if(!(Q(s,t)>=0&&(e||s.length===1))){var l;if(this.stateProxy&&!a&&(l=this.stateProxy(t)),l||(l=this.states&&this.states[t]),!l&&!a){ch("State "+t+" not exists.");return}a||this.saveCurrentToNormalState(l);var f=!!(l&&l.hoverLayer||n);f&&this._toggleHoverLayerFlag(!0),this._applyStateObj(t,l,this._normalState,e,!i&&!this.__inHover&&u&&u.duration>0,u);var h=this._textContent,v=this._textGuide;return h&&h.useState(t,e,i,f),v&&v.useState(t,e,i,f),a?(this.currentStates=[],this._normalState={}):e?this.currentStates.push(t):this.currentStates=[t],this._updateAnimationTargets(),this.markRedraw(),!f&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~Jt),l}}},r.prototype.useStates=function(t,e,i){if(!t.length)this.clearStates();else{var n=[],a=this.currentStates,o=t.length,s=o===a.length;if(s){for(var u=0;u<o;u++)if(t[u]!==a[u]){s=!1;break}}if(s)return;for(var u=0;u<o;u++){var l=t[u],f=void 0;this.stateProxy&&(f=this.stateProxy(l,t)),f||(f=this.states[l]),f&&n.push(f)}var h=n[o-1],v=!!(h&&h.hoverLayer||i);v&&this._toggleHoverLayerFlag(!0);var c=this._mergeStates(n),p=this.stateTransition;this.saveCurrentToNormalState(c),this._applyStateObj(t.join(","),c,this._normalState,!1,!e&&!this.__inHover&&p&&p.duration>0,p);var d=this._textContent,g=this._textGuide;d&&d.useStates(t,e,v),g&&g.useStates(t,e,v),this._updateAnimationTargets(),this.currentStates=t.slice(),this.markRedraw(),!v&&this.__inHover&&(this._toggleHoverLayerFlag(!1),this.__dirty&=~Jt)}},r.prototype.isSilent=function(){for(var t=this.silent,e=this.parent;!t&&e;){if(e.silent){t=!0;break}e=e.parent}return t},r.prototype._updateAnimationTargets=function(){for(var t=0;t<this.animators.length;t++){var e=this.animators[t];e.targetName&&e.changeTarget(this[e.targetName])}},r.prototype.removeState=function(t){var e=Q(this.currentStates,t);if(e>=0){var i=this.currentStates.slice();i.splice(e,1),this.useStates(i)}},r.prototype.replaceState=function(t,e,i){var n=this.currentStates.slice(),a=Q(n,t),o=Q(n,e)>=0;a>=0?o?n.splice(a,1):n[a]=e:i&&!o&&n.push(e),this.useStates(n)},r.prototype.toggleState=function(t,e){e?this.useState(t,!0):this.removeState(t)},r.prototype._mergeStates=function(t){for(var e={},i,n=0;n<t.length;n++){var a=t[n];k(e,a),a.textConfig&&(i=i||{},k(i,a.textConfig))}return i&&(e.textConfig=i),e},r.prototype._applyStateObj=function(t,e,i,n,a,o){var s=!(e&&n);e&&e.textConfig?(this.textConfig=k({},n?this.textConfig:i.textConfig),k(this.textConfig,e.textConfig)):s&&i.textConfig&&(this.textConfig=i.textConfig);for(var u={},l=!1,f=0;f<Iu.length;f++){var h=Iu[f],v=a&&HS[h];e&&e[h]!=null?v?(l=!0,u[h]=e[h]):this[h]=e[h]:s&&i[h]!=null&&(v?(l=!0,u[h]=i[h]):this[h]=i[h])}if(!a)for(var f=0;f<this.animators.length;f++){var c=this.animators[f],p=c.targetName;c.getLoop()||c.__changeFinalValue(p?(e||i)[p]:e||i)}l&&this._transitionState(t,u,o)},r.prototype._attachComponent=function(t){if(!(t.__zr&&!t.__hostTarget)&&t!==this){var e=this.__zr;e&&t.addSelfToZr(e),t.__zr=e,t.__hostTarget=this}},r.prototype._detachComponent=function(t){t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__hostTarget=null},r.prototype.getClipPath=function(){return this._clipPath},r.prototype.setClipPath=function(t){this._clipPath&&this._clipPath!==t&&this.removeClipPath(),this._attachComponent(t),this._clipPath=t,this.markRedraw()},r.prototype.removeClipPath=function(){var t=this._clipPath;t&&(this._detachComponent(t),this._clipPath=null,this.markRedraw())},r.prototype.getTextContent=function(){return this._textContent},r.prototype.setTextContent=function(t){var e=this._textContent;e!==t&&(e&&e!==t&&this.removeTextContent(),t.innerTransformable=new Ps,this._attachComponent(t),this._textContent=t,this.markRedraw())},r.prototype.setTextConfig=function(t){this.textConfig||(this.textConfig={}),k(this.textConfig,t),this.markRedraw()},r.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},r.prototype.removeTextContent=function(){var t=this._textContent;t&&(t.innerTransformable=null,this._detachComponent(t),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},r.prototype.getTextGuideLine=function(){return this._textGuide},r.prototype.setTextGuideLine=function(t){this._textGuide&&this._textGuide!==t&&this.removeTextGuideLine(),this._attachComponent(t),this._textGuide=t,this.markRedraw()},r.prototype.removeTextGuideLine=function(){var t=this._textGuide;t&&(this._detachComponent(t),this._textGuide=null,this.markRedraw())},r.prototype.markRedraw=function(){this.__dirty|=Jt;var t=this.__zr;t&&(this.__inHover?t.refreshHover():t.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},r.prototype.dirty=function(){this.markRedraw()},r.prototype._toggleHoverLayerFlag=function(t){this.__inHover=t;var e=this._textContent,i=this._textGuide;e&&(e.__inHover=t),i&&(i.__inHover=t)},r.prototype.addSelfToZr=function(t){if(this.__zr!==t){this.__zr=t;var e=this.animators;if(e)for(var i=0;i<e.length;i++)t.animation.addAnimator(e[i]);this._clipPath&&this._clipPath.addSelfToZr(t),this._textContent&&this._textContent.addSelfToZr(t),this._textGuide&&this._textGuide.addSelfToZr(t)}},r.prototype.removeSelfFromZr=function(t){if(this.__zr){this.__zr=null;var e=this.animators;if(e)for(var i=0;i<e.length;i++)t.animation.removeAnimator(e[i]);this._clipPath&&this._clipPath.removeSelfFromZr(t),this._textContent&&this._textContent.removeSelfFromZr(t),this._textGuide&&this._textGuide.removeSelfFromZr(t)}},r.prototype.animate=function(t,e,i){var n=t?this[t]:this,a=new _h(n,e,i);return t&&(a.targetName=t),this.addAnimator(a,t),a},r.prototype.addAnimator=function(t,e){var i=this.__zr,n=this;t.during(function(){n.updateDuringAnimation(e)}).done(function(){var a=n.animators,o=Q(a,t);o>=0&&a.splice(o,1)}),this.animators.push(t),i&&i.animation.addAnimator(t),i&&i.wakeUp()},r.prototype.updateDuringAnimation=function(t){this.markRedraw()},r.prototype.stopAnimation=function(t,e){for(var i=this.animators,n=i.length,a=[],o=0;o<n;o++){var s=i[o];!t||t===s.scope?s.stop(e):a.push(s)}return this.animators=a,this},r.prototype.animateTo=function(t,e,i){Ru(this,t,e,i)},r.prototype.animateFrom=function(t,e,i){Ru(this,t,e,i,!0)},r.prototype._transitionState=function(t,e,i,n){for(var a=Ru(this,e,i,n),o=0;o<a.length;o++)a[o].__fromStateTransition=t},r.prototype.getBoundingRect=function(){return null},r.prototype.getPaintRect=function(){return null},r.initDefaultProps=(function(){var t=r.prototype;t.type="element",t.name="",t.ignore=t.silent=t.isGroup=t.draggable=t.dragging=t.ignoreClip=t.__inHover=!1,t.__dirty=Jt;function e(i,n,a,o){Object.defineProperty(t,i,{get:function(){if(!this[n]){var u=this[n]=[];s(this,u)}return this[n]},set:function(u){this[a]=u[0],this[o]=u[1],this[n]=u,s(this,u)}});function s(u,l){Object.defineProperty(l,0,{get:function(){return u[a]},set:function(f){u[a]=f}}),Object.defineProperty(l,1,{get:function(){return u[o]},set:function(f){u[o]=f}})}}Object.defineProperty&&(e("position","_legacyPos","x","y"),e("scale","_legacyScale","scaleX","scaleY"),e("origin","_legacyOrigin","originX","originY"))})(),r})();Ce(Is,de);Ce(Is,Ps);function Ru(r,t,e,i,n){e=e||{};var a=[];Cy(r,"",r,t,e,i,a,n);var o=a.length,s=!1,u=e.done,l=e.aborted,f=function(){s=!0,o--,o<=0&&(s?u&&u():l&&l())},h=function(){o--,o<=0&&(s?u&&u():l&&l())};o||u&&u(),a.length>0&&e.during&&a[0].during(function(p,d){e.during(d)});for(var v=0;v<a.length;v++){var c=a[v];f&&c.done(f),h&&c.aborted(h),e.force&&c.duration(e.duration),c.start(e.easing)}return a}function Eu(r,t,e){for(var i=0;i<e;i++)r[i]=t[i]}function WS(r){return zt(r[0])}function US(r,t,e){if(zt(t[e]))if(zt(r[e])||(r[e]=[]),Yt(t[e])){var i=t[e].length;r[e].length!==i&&(r[e]=new t[e].constructor(i),Eu(r[e],t[e],i))}else{var n=t[e],a=r[e],o=n.length;if(WS(n))for(var s=n[0].length,u=0;u<o;u++)a[u]?Eu(a[u],n[u],s):a[u]=Array.prototype.slice.call(n[u]);else Eu(a,n,o);a.length=n.length}else r[e]=t[e]}function YS(r,t){return r===t||zt(r)&&zt(t)&&ZS(r,t)}function ZS(r,t){var e=r.length;if(e!==t.length)return!1;for(var i=0;i<e;i++)if(r[i]!==t[i])return!1;return!0}function Cy(r,t,e,i,n,a,o,s){for(var u=ft(i),l=n.duration,f=n.delay,h=n.additive,v=n.setToFinal,c=!W(a),p=r.animators,d=[],g=0;g<u.length;g++){var y=u[g],m=i[y];if(m!=null&&e[y]!=null&&(c||a[y]))if(W(m)&&!zt(m)&&!Ds(m)){if(t){s||(e[y]=m,r.updateDuringAnimation(t));continue}Cy(r,y,e[y],m,n,a&&a[y],o,s)}else d.push(y);else s||(e[y]=m,r.updateDuringAnimation(t),d.push(y))}var _=d.length;if(!h&&_)for(var S=0;S<p.length;S++){var b=p[S];if(b.targetName===t){var w=b.stopTracks(d);if(w){var x=Q(p,b);p.splice(x,1)}}}if(n.force||(d=_t(d,function(A){return!YS(i[A],e[A])}),_=d.length),_>0||n.force&&!o.length){var C=void 0,M=void 0,D=void 0;if(s){M={},v&&(C={});for(var S=0;S<_;S++){var y=d[S];M[y]=e[y],v?C[y]=i[y]:e[y]=i[y]}}else if(v){D={};for(var S=0;S<_;S++){var y=d[S];D[y]=ua(e[y]),US(e,i,y)}}var b=new _h(e,!1,!1,h?_t(p,function(P){return P.targetName===t}):null);b.targetName=t,n.scope&&(b.scope=n.scope),v&&C&&b.whenWithKeys(0,C,d),D&&b.whenWithKeys(0,D,d),b.whenWithKeys(l??500,s?M:i,d).delay(f||0),r.addAnimator(b,t),o.push(b)}}var gt=(function(r){O(t,r);function t(e){var i=r.call(this)||this;return i.isGroup=!0,i._children=[],i.attr(e),i}return t.prototype.childrenRef=function(){return this._children},t.prototype.children=function(){return this._children.slice()},t.prototype.childAt=function(e){return this._children[e]},t.prototype.childOfName=function(e){for(var i=this._children,n=0;n<i.length;n++)if(i[n].name===e)return i[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,i){if(e&&e!==this&&e.parent!==this&&i&&i.parent===this){var n=this._children,a=n.indexOf(i);a>=0&&(n.splice(a,0,e),this._doAdd(e))}return this},t.prototype.replace=function(e,i){var n=Q(this._children,e);return n>=0&&this.replaceAt(i,n),this},t.prototype.replaceAt=function(e,i){var n=this._children,a=n[i];if(e&&e!==this&&e.parent!==this&&e!==a){n[i]=e,a.parent=null;var o=this.__zr;o&&a.removeSelfFromZr(o),this._doAdd(e)}return this},t.prototype._doAdd=function(e){e.parent&&e.parent.remove(e),e.parent=this;var i=this.__zr;i&&i!==e.__zr&&e.addSelfToZr(i),i&&i.refresh()},t.prototype.remove=function(e){var i=this.__zr,n=this._children,a=Q(n,e);return a<0?this:(n.splice(a,1),e.parent=null,i&&e.removeSelfFromZr(i),i&&i.refresh(),this)},t.prototype.removeAll=function(){for(var e=this._children,i=this.__zr,n=0;n<e.length;n++){var a=e[n];i&&a.removeSelfFromZr(i),a.parent=null}return e.length=0,this},t.prototype.eachChild=function(e,i){for(var n=this._children,a=0;a<n.length;a++){var o=n[a];e.call(i,o,a)}return this},t.prototype.traverse=function(e,i){for(var n=0;n<this._children.length;n++){var a=this._children[n],o=e.call(i,a);a.isGroup&&!o&&a.traverse(e,i)}return this},t.prototype.addSelfToZr=function(e){r.prototype.addSelfToZr.call(this,e);for(var i=0;i<this._children.length;i++){var n=this._children[i];n.addSelfToZr(e)}},t.prototype.removeSelfFromZr=function(e){r.prototype.removeSelfFromZr.call(this,e);for(var i=0;i<this._children.length;i++){var n=this._children[i];n.removeSelfFromZr(e)}},t.prototype.getBoundingRect=function(e){for(var i=new et(0,0,0,0),n=e||this._children,a=[],o=null,s=0;s<n.length;s++){var u=n[s];if(!(u.ignore||u.invisible)){var l=u.getBoundingRect(),f=u.getLocalTransform(a);f?(et.applyTransform(i,l,f),o=o||i.clone(),o.union(i)):(o=o||l.clone(),o.union(l))}}return o||i},t})(Is);gt.prototype.type="group";/*!
16
+ * ZRender, a high performance 2d drawing library.
17
+ *
18
+ * Copyright (c) 2013, Baidu Inc.
19
+ * All rights reserved.
20
+ *
21
+ * LICENSE
22
+ * https://github.com/ecomfe/zrender/blob/master/LICENSE.txt
23
+ */var Bo={},Dy={};function XS(r){delete Dy[r]}function $S(r){if(!r)return!1;if(typeof r=="string")return Qo(r,1)<vf;if(r.colorStops){for(var t=r.colorStops,e=0,i=t.length,n=0;n<i;n++)e+=Qo(t[n].color,1);return e/=i,e<vf}return!1}var qS=(function(){function r(t,e,i){var n=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!0,this._darkMode=!1,i=i||{},this.dom=e,this.id=t;var a=new pS,o=i.renderer||"canvas";Bo[o]||(o=ft(Bo)[0]),i.useDirtyRect=i.useDirtyRect==null?!1:i.useDirtyRect;var s=new Bo[o](e,a,i,t),u=i.ssr||s.ssrOnly;this.storage=a,this.painter=s;var l=!Z.node&&!Z.worker&&!u?new FS(s.getViewportRoot(),s.root):null,f=i.useCoarsePointer,h=f==null||f==="auto"?Z.touchEventsSupported:!!f,v=44,c;h&&(c=$(i.pointerSize,v)),this.handler=new fy(a,s,l,s.root,c),this.animation=new IS({stage:{update:u?null:function(){return n._flush(!0)}}}),u||this.animation.start()}return r.prototype.add=function(t){this._disposed||!t||(this.storage.addRoot(t),t.addSelfToZr(this),this.refresh())},r.prototype.remove=function(t){this._disposed||!t||(this.storage.delRoot(t),t.removeSelfFromZr(this),this.refresh())},r.prototype.configLayer=function(t,e){this._disposed||(this.painter.configLayer&&this.painter.configLayer(t,e),this.refresh())},r.prototype.setBackgroundColor=function(t){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this.refresh(),this._backgroundColor=t,this._darkMode=$S(t))},r.prototype.getBackgroundColor=function(){return this._backgroundColor},r.prototype.setDarkMode=function(t){this._darkMode=t},r.prototype.isDarkMode=function(){return this._darkMode},r.prototype.refreshImmediately=function(t){this._disposed||(t||this.animation.update(!0),this._needsRefresh=!1,this.painter.refresh(),this._needsRefresh=!1)},r.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},r.prototype.flush=function(){this._disposed||this._flush(!1)},r.prototype._flush=function(t){var e,i=qi();this._needsRefresh&&(e=!0,this.refreshImmediately(t)),this._needsRefreshHover&&(e=!0,this.refreshHoverImmediately());var n=qi();e?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:n-i})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},r.prototype.setSleepAfterStill=function(t){this._sleepAfterStill=t},r.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},r.prototype.refreshHover=function(){this._needsRefreshHover=!0},r.prototype.refreshHoverImmediately=function(){this._disposed||(this._needsRefreshHover=!1,this.painter.refreshHover&&this.painter.getType()==="canvas"&&this.painter.refreshHover())},r.prototype.resize=function(t){this._disposed||(t=t||{},this.painter.resize(t.width,t.height),this.handler.resize())},r.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},r.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},r.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},r.prototype.setCursorStyle=function(t){this._disposed||this.handler.setCursorStyle(t)},r.prototype.findHover=function(t,e){if(!this._disposed)return this.handler.findHover(t,e)},r.prototype.on=function(t,e,i){return this._disposed||this.handler.on(t,e,i),this},r.prototype.off=function(t,e){this._disposed||this.handler.off(t,e)},r.prototype.trigger=function(t,e){this._disposed||this.handler.trigger(t,e)},r.prototype.clear=function(){if(!this._disposed){for(var t=this.storage.getRoots(),e=0;e<t.length;e++)t[e]instanceof gt&&t[e].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},r.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,XS(this.id))},r})();function lc(r,t){var e=new qS(ry(),r,t);return Dy[e.id]=e,e}function KS(r,t){Bo[r]=t}var fc=1e-4,Ay=20;function QS(r){return r.replace(/^\s+|\s+$/g,"")}function bt(r,t,e,i){var n=t[0],a=t[1],o=e[0],s=e[1],u=a-n,l=s-o;if(u===0)return l===0?o:(o+s)/2;if(i)if(u>0){if(r<=n)return o;if(r>=a)return s}else{if(r>=n)return o;if(r<=a)return s}else{if(r===n)return o;if(r===a)return s}return(r-n)/u*l+o}function yt(r,t){switch(r){case"center":case"middle":r="50%";break;case"left":case"top":r="0%";break;case"right":case"bottom":r="100%";break}return H(r)?QS(r).match(/%$/)?parseFloat(r)/100*t:parseFloat(r):r==null?NaN:+r}function xt(r,t,e){return t==null&&(t=10),t=Math.min(Math.max(0,t),Ay),r=(+r).toFixed(t),e?r:+r}function oi(r){return r.sort(function(t,e){return t-e}),r}function Be(r){if(r=+r,isNaN(r))return 0;if(r>1e-14){for(var t=1,e=0;e<15;e++,t*=10)if(Math.round(r*t)/t===r)return e}return JS(r)}function JS(r){var t=r.toString().toLowerCase(),e=t.indexOf("e"),i=e>0?+t.slice(e+1):0,n=e>0?e:t.length,a=t.indexOf("."),o=a<0?0:n-1-a;return Math.max(0,o-i)}function Ly(r,t){var e=Math.log,i=Math.LN10,n=Math.floor(e(r[1]-r[0])/i),a=Math.round(e(Math.abs(t[1]-t[0]))/i),o=Math.min(Math.max(-n+a,0),20);return isFinite(o)?o:20}function jS(r,t){var e=Math.max(Be(r),Be(t)),i=r+t;return e>Ay?i:xt(i,e)}function Py(r){var t=Math.PI*2;return(r%t+t)%t}function jo(r){return r>-fc&&r<fc}var tw=/^(?:(\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 tr(r){if(r instanceof Date)return r;if(H(r)){var t=tw.exec(r);if(!t)return new Date(NaN);if(t[8]){var e=+t[4]||0;return t[8].toUpperCase()!=="Z"&&(e-=+t[8].slice(0,3)),new Date(Date.UTC(+t[1],+(t[2]||1)-1,+t[3]||1,e,+(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(r==null)return new Date(NaN);return new Date(Math.round(r))}function ew(r){return Math.pow(10,bh(r))}function bh(r){if(r===0)return 0;var t=Math.floor(Math.log(r)/Math.LN10);return r/Math.pow(10,t)>=10&&t++,t}function Iy(r,t){var e=bh(r),i=Math.pow(10,e),n=r/i,a;return n<1.5?a=1:n<2.5?a=2:n<4?a=3:n<7?a=5:a=10,r=a*i,e>=-20?+r.toFixed(e<0?-e:0):r}function ts(r){var t=parseFloat(r);return t==r&&(t!==0||!H(r)||r.indexOf("x")<=0)?t:NaN}function rw(r){return!isNaN(ts(r))}function Ry(){return Math.round(Math.random()*9)}function Ey(r,t){return t===0?r:Ey(t,r%t)}function hc(r,t){return r==null?t:t==null?r:r*t/Ey(r,t)}function Ft(r){throw new Error(r)}function vc(r,t,e){return(t-r)*e+r}var ky="series\0",iw="\0_ec_\0";function Ct(r){return r instanceof Array?r:r==null?[]:[r]}function df(r,t,e){if(r){r[t]=r[t]||{},r.emphasis=r.emphasis||{},r.emphasis[t]=r.emphasis[t]||{};for(var i=0,n=e.length;i<n;i++){var a=e[i];!r.emphasis[t].hasOwnProperty(a)&&r[t].hasOwnProperty(a)&&(r.emphasis[t][a]=r[t][a])}}}var cc=["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"];function Fa(r){return W(r)&&!B(r)&&!(r instanceof Date)?r.value:r}function nw(r){return W(r)&&!(r instanceof Array)}function aw(r,t,e){var i=e==="normalMerge",n=e==="replaceMerge",a=e==="replaceAll";r=r||[],t=(t||[]).slice();var o=X();T(t,function(u,l){if(!W(u)){t[l]=null;return}});var s=ow(r,o,e);return(i||n)&&sw(s,r,o,t),i&&uw(s,t),i||n?lw(s,t,n):a&&fw(s,t),hw(s),s}function ow(r,t,e){var i=[];if(e==="replaceAll")return i;for(var n=0;n<r.length;n++){var a=r[n];a&&a.id!=null&&t.set(a.id,n),i.push({existing:e==="replaceMerge"||Sa(a)?null:a,newOption:null,keyInfo:null,brandNew:null})}return i}function sw(r,t,e,i){T(i,function(n,a){if(!(!n||n.id==null)){var o=la(n.id),s=e.get(o);if(s!=null){var u=r[s];ze(!u.newOption,'Duplicated option on id "'+o+'".'),u.newOption=n,u.existing=t[s],i[a]=null}}})}function uw(r,t){T(t,function(e,i){if(!(!e||e.name==null))for(var n=0;n<r.length;n++){var a=r[n].existing;if(!r[n].newOption&&a&&(a.id==null||e.id==null)&&!Sa(e)&&!Sa(a)&&Oy("name",a,e)){r[n].newOption=e,t[i]=null;return}}})}function lw(r,t,e){T(t,function(i){if(i){for(var n,a=0;(n=r[a])&&(n.newOption||Sa(n.existing)||n.existing&&i.id!=null&&!Oy("id",i,n.existing));)a++;n?(n.newOption=i,n.brandNew=e):r.push({newOption:i,brandNew:e,existing:null,keyInfo:null}),a++}})}function fw(r,t){T(t,function(e){r.push({newOption:e,brandNew:!0,existing:null,keyInfo:null})})}function hw(r){var t=X();T(r,function(e){var i=e.existing;i&&t.set(i.id,e)}),T(r,function(e){var i=e.newOption;ze(!i||i.id==null||!t.get(i.id)||t.get(i.id)===e,"id duplicates: "+(i&&i.id)),i&&i.id!=null&&t.set(i.id,e),!e.keyInfo&&(e.keyInfo={})}),T(r,function(e,i){var n=e.existing,a=e.newOption,o=e.keyInfo;if(W(a)){if(o.name=a.name!=null?la(a.name):n?n.name:ky+i,n)o.id=la(n.id);else if(a.id!=null)o.id=la(a.id);else{var s=0;do o.id="\0"+o.name+"\0"+s++;while(t.get(o.id))}t.set(o.id,e)}})}function Oy(r,t,e){var i=Fe(t[r],null),n=Fe(e[r],null);return i!=null&&n!=null&&i===n}function la(r){return Fe(r,"")}function Fe(r,t){return r==null?t:H(r)?r:dt(r)||ql(r)?r+"":t}function By(r){var t=r.name;return!!(t&&t.indexOf(ky))}function Sa(r){return r&&r.id!=null&&la(r.id).indexOf(iw)===0}function vw(r,t,e){T(r,function(i){var n=i.newOption;W(n)&&(i.keyInfo.mainType=t,i.keyInfo.subType=cw(t,n,i.existing,e))})}function cw(r,t,e,i){var n=t.type?t.type:e?e.subType:i.determineSubType(r,t);return n}function yi(r,t){if(t.dataIndexInside!=null)return t.dataIndexInside;if(t.dataIndex!=null)return B(t.dataIndex)?z(t.dataIndex,function(e){return r.indexOfRawIndex(e)}):r.indexOfRawIndex(t.dataIndex);if(t.name!=null)return B(t.name)?z(t.name,function(e){return r.indexOfName(e)}):r.indexOfName(t.name)}function vt(){var r="__ec_inner_"+pw++;return function(t){return t[r]||(t[r]={})}}var pw=Ry();function No(r,t,e){var i=xh(t,e),n=i.mainTypeSpecified,a=i.queryOptionMap,o=i.others,s=o,u=e?e.defaultMainType:null;return!n&&u&&a.set(u,{}),a.each(function(l,f){var h=za(r,f,l,{useDefault:u===f,enableAll:e&&e.enableAll!=null?e.enableAll:!0,enableNone:e&&e.enableNone!=null?e.enableNone:!0});s[f+"Models"]=h.models,s[f+"Model"]=h.models[0]}),s}function xh(r,t){var e;if(H(r)){var i={};i[r+"Index"]=0,e=i}else e=r;var n=X(),a={},o=!1;return T(e,function(s,u){if(u==="dataIndex"||u==="dataIndexInside"){a[u]=s;return}var l=u.match(/^(\w+)(Index|Id|Name)$/)||[],f=l[1],h=(l[2]||"").toLowerCase();if(!(!f||!h||t&&t.includeMainTypes&&Q(t.includeMainTypes,f)<0)){o=o||!!f;var v=n.get(f)||n.set(f,{});v[h]=s}}),{mainTypeSpecified:o,queryOptionMap:n,others:a}}var Ut={useDefault:!0,enableAll:!1,enableNone:!1},dw={useDefault:!1,enableAll:!0,enableNone:!0};function za(r,t,e,i){i=i||Ut;var n=e.index,a=e.id,o=e.name,s={models:null,specified:n!=null||a!=null||o!=null};if(!s.specified){var u=void 0;return s.models=i.useDefault&&(u=r.getComponent(t))?[u]:[],s}return n==="none"||n===!1?(ze(i.enableNone,'`"none"` or `false` is not a valid value on index option.'),s.models=[],s):(n==="all"&&(ze(i.enableAll,'`"all"` is not a valid value on index option.'),n=a=o=null),s.models=r.queryComponents({mainType:t,index:n,id:a,name:o}),s)}function Ny(r,t,e){r.setAttribute?r.setAttribute(t,e):r[t]=e}function gw(r,t){return r.getAttribute?r.getAttribute(t):r[t]}function yw(r){return r==="auto"?Z.domSupported?"html":"richText":r||"html"}function Fy(r,t,e,i,n){var a=t==null||t==="auto";if(i==null)return i;if(dt(i)){var o=vc(e||0,i,n);return xt(o,a?Math.max(Be(e||0),Be(i)):t)}else{if(H(i))return n<1?e:i;for(var s=[],u=e,l=i,f=Math.max(u?u.length:0,l.length),h=0;h<f;++h){var v=r.getDimensionInfo(h);if(v&&v.type==="ordinal")s[h]=(n<1&&u?u:l)[h];else{var c=u&&u[h]?u[h]:0,p=l[h],o=vc(c,p,n);s[h]=xt(o,a?Math.max(Be(c),Be(p)):t)}}return s}}var mw=".",Hr="___EC__COMPONENT__CONTAINER___",zy="___EC__EXTENDED_CLASS___";function Ne(r){var t={main:"",sub:""};if(r){var e=r.split(mw);t.main=e[0]||"",t.sub=e[1]||""}return t}function _w(r){ze(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(r),'componentType "'+r+'" illegal')}function Sw(r){return!!(r&&r[zy])}function Th(r,t){r.$constructor=r,r.extend=function(e){var i=this,n;return ww(i)?n=(function(a){O(o,a);function o(){return a.apply(this,arguments)||this}return o})(i):(n=function(){(e.$constructor||i).apply(this,arguments)},R1(n,this)),k(n.prototype,e),n[zy]=!0,n.extend=this.extend,n.superCall=Tw,n.superApply=Mw,n.superClass=i,n}}function ww(r){return q(r)&&/^class\s/.test(Function.prototype.toString.call(r))}function Vy(r,t){r.extend=t.extend}var bw=Math.round(Math.random()*10);function xw(r){var t=["__\0is_clz",bw++].join("_");r.prototype[t]=!0,r.isInstance=function(e){return!!(e&&e[t])}}function Tw(r,t){for(var e=[],i=2;i<arguments.length;i++)e[i-2]=arguments[i];return this.superClass.prototype[t].apply(r,e)}function Mw(r,t,e){return this.superClass.prototype[t].apply(r,e)}function Rs(r){var t={};r.registerClass=function(i){var n=i.type||i.prototype.type;if(n){_w(n),i.prototype.type=n;var a=Ne(n);if(!a.sub)t[a.main]=i;else if(a.sub!==Hr){var o=e(a);o[a.sub]=i}}return i},r.getClass=function(i,n,a){var o=t[i];if(o&&o[Hr]&&(o=n?o[n]:null),a&&!o)throw new Error(n?"Component "+i+"."+(n||"")+" is used but not imported.":i+".type should be specified.");return o},r.getClassesByMainType=function(i){var n=Ne(i),a=[],o=t[n.main];return o&&o[Hr]?T(o,function(s,u){u!==Hr&&a.push(s)}):a.push(o),a},r.hasClass=function(i){var n=Ne(i);return!!t[n.main]},r.getAllClassMainTypes=function(){var i=[];return T(t,function(n,a){i.push(a)}),i},r.hasSubTypes=function(i){var n=Ne(i),a=t[n.main];return a&&a[Hr]};function e(i){var n=t[i.main];return(!n||!n[Hr])&&(n=t[i.main]={},n[Hr]=!0),n}}function wa(r,t){for(var e=0;e<r.length;e++)r[e][1]||(r[e][1]=r[e][0]);return t=t||!1,function(i,n,a){for(var o={},s=0;s<r.length;s++){var u=r[s][1];if(!(n&&Q(n,u)>=0||a&&Q(a,u)<0)){var l=i.getShallow(u,t);l!=null&&(o[r[s][0]]=l)}}return o}}var Cw=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],Dw=wa(Cw),Aw=(function(){function r(){}return r.prototype.getAreaStyle=function(t,e){return Dw(this,t,e)},r})(),gf=new Na(50);function Lw(r){if(typeof r=="string"){var t=gf.get(r);return t&&t.image}else return r}function Hy(r,t,e,i,n){if(r)if(typeof r=="string"){if(t&&t.__zrImageSrc===r||!e)return t;var a=gf.get(r),o={hostEl:e,cb:i,cbPayload:n};return a?(t=a.image,!Es(t)&&a.pending.push(o)):(t=yn.loadImage(r,pc,pc),t.__zrImageSrc=r,gf.put(r,t.__cachedImgObj={image:t,pending:[o]})),t}else return r;else return t}function pc(){var r=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t<r.pending.length;t++){var e=r.pending[t],i=e.cb;i&&i(this,e.cbPayload),e.hostEl.dirty()}r.pending.length=0}function Es(r){return r&&r.width&&r.height}var ku=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function Pw(r,t,e,i,n,a){if(!e){r.text="",r.isTruncated=!1;return}var o=(t+"").split(`
24
+ `);a=Gy(e,i,n,a);for(var s=!1,u={},l=0,f=o.length;l<f;l++)Wy(u,o[l],a),o[l]=u.textLine,s=s||u.isTruncated;r.text=o.join(`
25
+ `),r.isTruncated=s}function Gy(r,t,e,i){i=i||{};var n=k({},i);n.font=t,e=$(e,"..."),n.maxIterations=$(i.maxIterations,2);var a=n.minChar=$(i.minChar,0);n.cnCharWidth=jt("国",t);var o=n.ascCharWidth=jt("a",t);n.placeholder=$(i.placeholder,"");for(var s=r=Math.max(0,r-1),u=0;u<a&&s>=o;u++)s-=o;var l=jt(e,t);return l>s&&(e="",l=0),s=r-l,n.ellipsis=e,n.ellipsisWidth=l,n.contentWidth=s,n.containerWidth=r,n}function Wy(r,t,e){var i=e.containerWidth,n=e.font,a=e.contentWidth;if(!i){r.textLine="",r.isTruncated=!1;return}var o=jt(t,n);if(o<=i){r.textLine=t,r.isTruncated=!1;return}for(var s=0;;s++){if(o<=a||s>=e.maxIterations){t+=e.ellipsis;break}var u=s===0?Iw(t,a,e.ascCharWidth,e.cnCharWidth):o>0?Math.floor(t.length*a/o):0;t=t.substr(0,u),o=jt(t,n)}t===""&&(t=e.placeholder),r.textLine=t,r.isTruncated=!0}function Iw(r,t,e,i){for(var n=0,a=0,o=r.length;a<o&&n<t;a++){var s=r.charCodeAt(a);n+=0<=s&&s<=127?e:i}return a}function Rw(r,t){r!=null&&(r+="");var e=t.overflow,i=t.padding,n=t.font,a=e==="truncate",o=wh(n),s=$(t.lineHeight,o),u=!!t.backgroundColor,l=t.lineOverflow==="truncate",f=!1,h=t.width,v;h!=null&&(e==="break"||e==="breakAll")?v=r?Uy(r,t.font,h,e==="breakAll",0).lines:[]:v=r?r.split(`
26
+ `):[];var c=v.length*s,p=$(t.height,c);if(c>p&&l){var d=Math.floor(p/s);f=f||v.length>d,v=v.slice(0,d)}if(r&&a&&h!=null)for(var g=Gy(h,n,t.ellipsis,{minChar:t.truncateMinChar,placeholder:t.placeholder}),y={},m=0;m<v.length;m++)Wy(y,v[m],g),v[m]=y.textLine,f=f||y.isTruncated;for(var _=p,S=0,m=0;m<v.length;m++)S=Math.max(jt(v[m],n),S);h==null&&(h=S);var b=S;return i&&(_+=i[0]+i[2],b+=i[1]+i[3],h+=i[1]+i[3]),u&&(b=h),{lines:v,height:p,outerWidth:b,outerHeight:_,lineHeight:s,calculatedLineHeight:o,contentWidth:S,contentHeight:c,width:h,isTruncated:f}}var Ew=(function(){function r(){}return r})(),dc=(function(){function r(t){this.tokens=[],t&&(this.tokens=t)}return r})(),kw=(function(){function r(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[],this.isTruncated=!1}return r})();function Ow(r,t){var e=new kw;if(r!=null&&(r+=""),!r)return e;for(var i=t.width,n=t.height,a=t.overflow,o=(a==="break"||a==="breakAll")&&i!=null?{width:i,accumWidth:0,breakAll:a==="breakAll"}:null,s=ku.lastIndex=0,u;(u=ku.exec(r))!=null;){var l=u.index;l>s&&Ou(e,r.substring(s,l),t,o),Ou(e,u[2],t,o,u[1]),s=ku.lastIndex}s<r.length&&Ou(e,r.substring(s,r.length),t,o);var f=[],h=0,v=0,c=t.padding,p=a==="truncate",d=t.lineOverflow==="truncate",g={};function y(J,ut,lt){J.width=ut,J.lineHeight=lt,h+=lt,v=Math.max(v,ut)}t:for(var m=0;m<e.lines.length;m++){for(var _=e.lines[m],S=0,b=0,w=0;w<_.tokens.length;w++){var x=_.tokens[w],C=x.styleName&&t.rich[x.styleName]||{},M=x.textPadding=C.padding,D=M?M[1]+M[3]:0,A=x.font=C.font||t.font;x.contentHeight=wh(A);var P=$(C.height,x.contentHeight);if(x.innerHeight=P,M&&(P+=M[0]+M[2]),x.height=P,x.lineHeight=aa(C.lineHeight,t.lineHeight,P),x.align=C&&C.align||t.align,x.verticalAlign=C&&C.verticalAlign||"middle",d&&n!=null&&h+x.lineHeight>n){var R=e.lines.length;w>0?(_.tokens=_.tokens.slice(0,w),y(_,b,S),e.lines=e.lines.slice(0,m+1)):e.lines=e.lines.slice(0,m),e.isTruncated=e.isTruncated||e.lines.length<R;break t}var L=C.width,I=L==null||L==="auto";if(typeof L=="string"&&L.charAt(L.length-1)==="%")x.percentWidth=L,f.push(x),x.contentWidth=jt(x.text,A);else{if(I){var E=C.backgroundColor,G=E&&E.image;G&&(G=Lw(G),Es(G)&&(x.width=Math.max(x.width,G.width*P/G.height)))}var V=p&&i!=null?i-b:null;V!=null&&V<x.width?!I||V<D?(x.text="",x.width=x.contentWidth=0):(Pw(g,x.text,V-D,A,t.ellipsis,{minChar:t.truncateMinChar}),x.text=g.text,e.isTruncated=e.isTruncated||g.isTruncated,x.width=x.contentWidth=jt(x.text,A)):x.contentWidth=jt(x.text,A)}x.width+=D,b+=x.width,C&&(S=Math.max(S,x.lineHeight))}y(_,b,S)}e.outerWidth=e.width=$(i,v),e.outerHeight=e.height=$(n,h),e.contentHeight=h,e.contentWidth=v,c&&(e.outerWidth+=c[1]+c[3],e.outerHeight+=c[0]+c[2]);for(var m=0;m<f.length;m++){var x=f[m],F=x.percentWidth;x.width=parseInt(F,10)/100*e.width}return e}function Ou(r,t,e,i,n){var a=t==="",o=n&&e.rich[n]||{},s=r.lines,u=o.font||e.font,l=!1,f,h;if(i){var v=o.padding,c=v?v[1]+v[3]:0;if(o.width!=null&&o.width!=="auto"){var p=gi(o.width,i.width)+c;s.length>0&&p+i.accumWidth>i.width&&(f=t.split(`
27
+ `),l=!0),i.accumWidth=p}else{var d=Uy(t,u,i.width,i.breakAll,i.accumWidth);i.accumWidth=d.accumWidth+c,h=d.linesWidths,f=d.lines}}else f=t.split(`
28
+ `);for(var g=0;g<f.length;g++){var y=f[g],m=new Ew;if(m.styleName=n,m.text=y,m.isLineHolder=!y&&!a,typeof o.width=="number"?m.width=o.width:m.width=h?h[g]:jt(y,u),!g&&!l){var _=(s[s.length-1]||(s[0]=new dc)).tokens,S=_.length;S===1&&_[0].isLineHolder?_[0]=m:(y||!S||a)&&_.push(m)}else s.push(new dc([m]))}}function Bw(r){var t=r.charCodeAt(0);return t>=32&&t<=591||t>=880&&t<=4351||t>=4608&&t<=5119||t>=7680&&t<=8303}var Nw=Ti(",&?/;] ".split(""),function(r,t){return r[t]=!0,r},{});function Fw(r){return Bw(r)?!!Nw[r]:!0}function Uy(r,t,e,i,n){for(var a=[],o=[],s="",u="",l=0,f=0,h=0;h<r.length;h++){var v=r.charAt(h);if(v===`
29
+ `){u&&(s+=u,f+=l),a.push(s),o.push(f),s="",u="",l=0,f=0;continue}var c=jt(v,t),p=i?!1:!Fw(v);if(a.length?f+c>e:n+f+c>e){f?(s||u)&&(p?(s||(s=u,u="",l=0,f=l),a.push(s),o.push(f-l),u+=v,l+=c,s="",f=l):(u&&(s+=u,u="",l=0),a.push(s),o.push(f),s=v,f=c)):p?(a.push(u),o.push(l),u=v,l=c):(a.push(v),o.push(c));continue}f+=c,p?(u+=v,l+=c):(u&&(s+=u,u="",l=0),s+=v)}return!a.length&&!s&&(s=r,u="",l=0),u&&(s+=u),s&&(a.push(s),o.push(f)),a.length===1&&(f+=n),{accumWidth:f,lines:a,linesWidths:o}}var yf="__zr_style_"+Math.round(Math.random()*10),vi={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},ks={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};vi[yf]=!0;var gc=["z","z2","invisible"],zw=["invisible"],Mi=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype._init=function(e){for(var i=ft(e),n=0;n<i.length;n++){var a=i[n];a==="style"?this.useStyle(e[a]):r.prototype.attrKV.call(this,a,e[a])}this.style||this.useStyle({})},t.prototype.beforeBrush=function(){},t.prototype.afterBrush=function(){},t.prototype.innerBeforeBrush=function(){},t.prototype.innerAfterBrush=function(){},t.prototype.shouldBePainted=function(e,i,n,a){var o=this.transform;if(this.ignore||this.invisible||this.style.opacity===0||this.culling&&Vw(this,e,i)||o&&!o[0]&&!o[3])return!1;if(n&&this.__clipPaths){for(var s=0;s<this.__clipPaths.length;++s)if(this.__clipPaths[s].isZeroArea())return!1}if(a&&this.parent)for(var u=this.parent;u;){if(u.ignore)return!1;u=u.parent}return!0},t.prototype.contain=function(e,i){return this.rectContain(e,i)},t.prototype.traverse=function(e,i){e.call(i,this)},t.prototype.rectContain=function(e,i){var n=this.transformCoordToLocal(e,i),a=this.getBoundingRect();return a.contain(n[0],n[1])},t.prototype.getPaintRect=function(){var e=this._paintRect;if(!this._paintRect||this.__dirty){var i=this.transform,n=this.getBoundingRect(),a=this.style,o=a.shadowBlur||0,s=a.shadowOffsetX||0,u=a.shadowOffsetY||0;e=this._paintRect||(this._paintRect=new et(0,0,0,0)),i?et.applyTransform(e,n,i):e.copy(n),(o||s||u)&&(e.width+=o*2+Math.abs(s),e.height+=o*2+Math.abs(u),e.x=Math.min(e.x,e.x+s-o),e.y=Math.min(e.y,e.y+u-o));var l=this.dirtyRectTolerance;e.isZero()||(e.x=Math.floor(e.x-l),e.y=Math.floor(e.y-l),e.width=Math.ceil(e.width+1+l*2),e.height=Math.ceil(e.height+1+l*2))}return e},t.prototype.setPrevPaintRect=function(e){e?(this._prevPaintRect=this._prevPaintRect||new et(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(e,i){e!=="style"?r.prototype.attrKV.call(this,e,i):this.style?this.setStyle(i):this.useStyle(i)},t.prototype.setStyle=function(e,i){return typeof e=="string"?this.style[e]=i:k(this.style,e),this.dirtyStyle(),this},t.prototype.dirtyStyle=function(e){e||this.markRedraw(),this.__dirty|=Kn,this._rect&&(this._rect=null)},t.prototype.dirty=function(){this.dirtyStyle()},t.prototype.styleChanged=function(){return!!(this.__dirty&Kn)},t.prototype.styleUpdated=function(){this.__dirty&=~Kn},t.prototype.createStyle=function(e){return As(vi,e)},t.prototype.useStyle=function(e){e[yf]||(e=this.createStyle(e)),this.__inHover?this.__hoverStyle=e:this.style=e,this.dirtyStyle()},t.prototype.isStyleObject=function(e){return e[yf]},t.prototype._innerSaveToNormal=function(e){r.prototype._innerSaveToNormal.call(this,e);var i=this._normalState;e.style&&!i.style&&(i.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(e,i,gc)},t.prototype._applyStateObj=function(e,i,n,a,o,s){r.prototype._applyStateObj.call(this,e,i,n,a,o,s);var u=!(i&&a),l;if(i&&i.style?o?a?l=i.style:(l=this._mergeStyle(this.createStyle(),n.style),this._mergeStyle(l,i.style)):(l=this._mergeStyle(this.createStyle(),a?this.style:n.style),this._mergeStyle(l,i.style)):u&&(l=n.style),l)if(o){var f=this.style;if(this.style=this.createStyle(u?{}:f),u)for(var h=ft(f),v=0;v<h.length;v++){var c=h[v];c in l&&(l[c]=l[c],this.style[c]=f[c])}for(var p=ft(l),v=0;v<p.length;v++){var c=p[v];this.style[c]=this.style[c]}this._transitionState(e,{style:l},s,this.getAnimationStyleProps())}else this.useStyle(l);for(var d=this.__inHover?zw:gc,v=0;v<d.length;v++){var c=d[v];i&&i[c]!=null?this[c]=i[c]:u&&n[c]!=null&&(this[c]=n[c])}},t.prototype._mergeStates=function(e){for(var i=r.prototype._mergeStates.call(this,e),n,a=0;a<e.length;a++){var o=e[a];o.style&&(n=n||{},this._mergeStyle(n,o.style))}return n&&(i.style=n),i},t.prototype._mergeStyle=function(e,i){return k(e,i),e},t.prototype.getAnimationStyleProps=function(){return ks},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=!1,e._rect=null,e.dirtyRectTolerance=0,e.__dirty=Jt|Kn})(),t})(Is),Bu=new et(0,0,0,0),Nu=new et(0,0,0,0);function Vw(r,t,e){return Bu.copy(r.getBoundingRect()),r.transform&&Bu.applyTransform(r.transform),Nu.width=t,Nu.height=e,!Bu.intersect(Nu)}var le=Math.min,fe=Math.max,Fu=Math.sin,zu=Math.cos,Gr=Math.PI*2,Qa=mn(),Ja=mn(),ja=mn();function yc(r,t,e,i,n,a){n[0]=le(r,e),n[1]=le(t,i),a[0]=fe(r,e),a[1]=fe(t,i)}var mc=[],_c=[];function Hw(r,t,e,i,n,a,o,s,u,l){var f=dy,h=Mt,v=f(r,e,n,o,mc);u[0]=1/0,u[1]=1/0,l[0]=-1/0,l[1]=-1/0;for(var c=0;c<v;c++){var p=h(r,e,n,o,mc[c]);u[0]=le(p,u[0]),l[0]=fe(p,l[0])}v=f(t,i,a,s,_c);for(var c=0;c<v;c++){var d=h(t,i,a,s,_c[c]);u[1]=le(d,u[1]),l[1]=fe(d,l[1])}u[0]=le(r,u[0]),l[0]=fe(r,l[0]),u[0]=le(o,u[0]),l[0]=fe(o,l[0]),u[1]=le(t,u[1]),l[1]=fe(t,l[1]),u[1]=le(s,u[1]),l[1]=fe(s,l[1])}function Gw(r,t,e,i,n,a,o,s){var u=yy,l=Et,f=fe(le(u(r,e,n),1),0),h=fe(le(u(t,i,a),1),0),v=l(r,e,n,f),c=l(t,i,a,h);o[0]=le(r,n,v),o[1]=le(t,a,c),s[0]=fe(r,n,v),s[1]=fe(t,a,c)}function Ww(r,t,e,i,n,a,o,s,u){var l=Xi,f=$i,h=Math.abs(n-a);if(h%Gr<1e-4&&h>1e-4){s[0]=r-e,s[1]=t-i,u[0]=r+e,u[1]=t+i;return}if(Qa[0]=zu(n)*e+r,Qa[1]=Fu(n)*i+t,Ja[0]=zu(a)*e+r,Ja[1]=Fu(a)*i+t,l(s,Qa,Ja),f(u,Qa,Ja),n=n%Gr,n<0&&(n=n+Gr),a=a%Gr,a<0&&(a=a+Gr),n>a&&!o?a+=Gr:n<a&&o&&(n+=Gr),o){var v=a;a=n,n=v}for(var c=0;c<a;c+=Math.PI/2)c>n&&(ja[0]=zu(c)*e+r,ja[1]=Fu(c)*i+t,l(s,ja,s),f(u,ja,u))}var ht={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},Wr=[],Ur=[],Ae=[],sr=[],Le=[],Pe=[],Vu=Math.min,Hu=Math.max,Yr=Math.cos,Zr=Math.sin,Ue=Math.abs,mf=Math.PI,gr=mf*2,Gu=typeof Float32Array<"u",Ln=[];function Wu(r){var t=Math.round(r/mf*1e8)/1e8;return t%2*mf}function Uw(r,t){var e=Wu(r[0]);e<0&&(e+=gr);var i=e-r[0],n=r[1];n+=i,!t&&n-e>=gr?n=e+gr:t&&e-n>=gr?n=e-gr:!t&&e>n?n=e+(gr-Wu(e-n)):t&&e<n&&(n=e-(gr-Wu(n-e))),r[0]=e,r[1]=n}var Ar=(function(){function r(t){this.dpr=1,this._xi=0,this._yi=0,this._x0=0,this._y0=0,this._len=0,t&&(this._saveData=!1),this._saveData&&(this.data=[])}return r.prototype.increaseVersion=function(){this._version++},r.prototype.getVersion=function(){return this._version},r.prototype.setScale=function(t,e,i){i=i||0,i>0&&(this._ux=Ue(i/Jo/t)||0,this._uy=Ue(i/Jo/e)||0)},r.prototype.setDPR=function(t){this.dpr=t},r.prototype.setContext=function(t){this._ctx=t},r.prototype.getContext=function(){return this._ctx},r.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},r.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},r.prototype.moveTo=function(t,e){return this._drawPendingPt(),this.addData(ht.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},r.prototype.lineTo=function(t,e){var i=Ue(t-this._xi),n=Ue(e-this._yi),a=i>this._ux||n>this._uy;if(this.addData(ht.L,t,e),this._ctx&&a&&this._ctx.lineTo(t,e),a)this._xi=t,this._yi=e,this._pendingPtDist=0;else{var o=i*i+n*n;o>this._pendingPtDist&&(this._pendingPtX=t,this._pendingPtY=e,this._pendingPtDist=o)}return this},r.prototype.bezierCurveTo=function(t,e,i,n,a,o){return this._drawPendingPt(),this.addData(ht.C,t,e,i,n,a,o),this._ctx&&this._ctx.bezierCurveTo(t,e,i,n,a,o),this._xi=a,this._yi=o,this},r.prototype.quadraticCurveTo=function(t,e,i,n){return this._drawPendingPt(),this.addData(ht.Q,t,e,i,n),this._ctx&&this._ctx.quadraticCurveTo(t,e,i,n),this._xi=i,this._yi=n,this},r.prototype.arc=function(t,e,i,n,a,o){this._drawPendingPt(),Ln[0]=n,Ln[1]=a,Uw(Ln,o),n=Ln[0],a=Ln[1];var s=a-n;return this.addData(ht.A,t,e,i,i,n,s,0,o?0:1),this._ctx&&this._ctx.arc(t,e,i,n,a,o),this._xi=Yr(a)*i+t,this._yi=Zr(a)*i+e,this},r.prototype.arcTo=function(t,e,i,n,a){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(t,e,i,n,a),this},r.prototype.rect=function(t,e,i,n){return this._drawPendingPt(),this._ctx&&this._ctx.rect(t,e,i,n),this.addData(ht.R,t,e,i,n),this},r.prototype.closePath=function(){this._drawPendingPt(),this.addData(ht.Z);var t=this._ctx,e=this._x0,i=this._y0;return t&&t.closePath(),this._xi=e,this._yi=i,this},r.prototype.fill=function(t){t&&t.fill(),this.toStatic()},r.prototype.stroke=function(t){t&&t.stroke(),this.toStatic()},r.prototype.len=function(){return this._len},r.prototype.setData=function(t){var e=t.length;!(this.data&&this.data.length===e)&&Gu&&(this.data=new Float32Array(e));for(var i=0;i<e;i++)this.data[i]=t[i];this._len=e},r.prototype.appendPath=function(t){t instanceof Array||(t=[t]);for(var e=t.length,i=0,n=this._len,a=0;a<e;a++)i+=t[a].len();Gu&&this.data instanceof Float32Array&&(this.data=new Float32Array(n+i));for(var a=0;a<e;a++)for(var o=t[a].data,s=0;s<o.length;s++)this.data[n++]=o[s];this._len=n},r.prototype.addData=function(t,e,i,n,a,o,s,u,l){if(this._saveData){var f=this.data;this._len+arguments.length>f.length&&(this._expandData(),f=this.data);for(var h=0;h<arguments.length;h++)f[this._len++]=arguments[h]}},r.prototype._drawPendingPt=function(){this._pendingPtDist>0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},r.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var t=[],e=0;e<this._len;e++)t[e]=this.data[e];this.data=t}},r.prototype.toStatic=function(){if(this._saveData){this._drawPendingPt();var t=this.data;t instanceof Array&&(t.length=this._len,Gu&&this._len>11&&(this.data=new Float32Array(t)))}},r.prototype.getBoundingRect=function(){Ae[0]=Ae[1]=Le[0]=Le[1]=Number.MAX_VALUE,sr[0]=sr[1]=Pe[0]=Pe[1]=-Number.MAX_VALUE;var t=this.data,e=0,i=0,n=0,a=0,o;for(o=0;o<this._len;){var s=t[o++],u=o===1;switch(u&&(e=t[o],i=t[o+1],n=e,a=i),s){case ht.M:e=n=t[o++],i=a=t[o++],Le[0]=n,Le[1]=a,Pe[0]=n,Pe[1]=a;break;case ht.L:yc(e,i,t[o],t[o+1],Le,Pe),e=t[o++],i=t[o++];break;case ht.C:Hw(e,i,t[o++],t[o++],t[o++],t[o++],t[o],t[o+1],Le,Pe),e=t[o++],i=t[o++];break;case ht.Q:Gw(e,i,t[o++],t[o++],t[o],t[o+1],Le,Pe),e=t[o++],i=t[o++];break;case ht.A:var l=t[o++],f=t[o++],h=t[o++],v=t[o++],c=t[o++],p=t[o++]+c;o+=1;var d=!t[o++];u&&(n=Yr(c)*h+l,a=Zr(c)*v+f),Ww(l,f,h,v,c,p,d,Le,Pe),e=Yr(p)*h+l,i=Zr(p)*v+f;break;case ht.R:n=e=t[o++],a=i=t[o++];var g=t[o++],y=t[o++];yc(n,a,n+g,a+y,Le,Pe);break;case ht.Z:e=n,i=a;break}Xi(Ae,Ae,Le),$i(sr,sr,Pe)}return o===0&&(Ae[0]=Ae[1]=sr[0]=sr[1]=0),new et(Ae[0],Ae[1],sr[0]-Ae[0],sr[1]-Ae[1])},r.prototype._calculateLength=function(){var t=this.data,e=this._len,i=this._ux,n=this._uy,a=0,o=0,s=0,u=0;this._pathSegLen||(this._pathSegLen=[]);for(var l=this._pathSegLen,f=0,h=0,v=0;v<e;){var c=t[v++],p=v===1;p&&(a=t[v],o=t[v+1],s=a,u=o);var d=-1;switch(c){case ht.M:a=s=t[v++],o=u=t[v++];break;case ht.L:{var g=t[v++],y=t[v++],m=g-a,_=y-o;(Ue(m)>i||Ue(_)>n||v===e-1)&&(d=Math.sqrt(m*m+_*_),a=g,o=y);break}case ht.C:{var S=t[v++],b=t[v++],g=t[v++],y=t[v++],w=t[v++],x=t[v++];d=dS(a,o,S,b,g,y,w,x,10),a=w,o=x;break}case ht.Q:{var S=t[v++],b=t[v++],g=t[v++],y=t[v++];d=yS(a,o,S,b,g,y,10),a=g,o=y;break}case ht.A:var C=t[v++],M=t[v++],D=t[v++],A=t[v++],P=t[v++],R=t[v++],L=R+P;v+=1,p&&(s=Yr(P)*D+C,u=Zr(P)*A+M),d=Hu(D,A)*Vu(gr,Math.abs(R)),a=Yr(L)*D+C,o=Zr(L)*A+M;break;case ht.R:{s=a=t[v++],u=o=t[v++];var I=t[v++],E=t[v++];d=I*2+E*2;break}case ht.Z:{var m=s-a,_=u-o;d=Math.sqrt(m*m+_*_),a=s,o=u;break}}d>=0&&(l[h++]=d,f+=d)}return this._pathLen=f,f},r.prototype.rebuildPath=function(t,e){var i=this.data,n=this._ux,a=this._uy,o=this._len,s,u,l,f,h,v,c=e<1,p,d,g=0,y=0,m,_=0,S,b;if(!(c&&(this._pathSegLen||this._calculateLength(),p=this._pathSegLen,d=this._pathLen,m=e*d,!m)))t:for(var w=0;w<o;){var x=i[w++],C=w===1;switch(C&&(l=i[w],f=i[w+1],s=l,u=f),x!==ht.L&&_>0&&(t.lineTo(S,b),_=0),x){case ht.M:s=l=i[w++],u=f=i[w++],t.moveTo(l,f);break;case ht.L:{h=i[w++],v=i[w++];var M=Ue(h-l),D=Ue(v-f);if(M>n||D>a){if(c){var A=p[y++];if(g+A>m){var P=(m-g)/A;t.lineTo(l*(1-P)+h*P,f*(1-P)+v*P);break t}g+=A}t.lineTo(h,v),l=h,f=v,_=0}else{var R=M*M+D*D;R>_&&(S=h,b=v,_=R)}break}case ht.C:{var L=i[w++],I=i[w++],E=i[w++],G=i[w++],V=i[w++],F=i[w++];if(c){var A=p[y++];if(g+A>m){var P=(m-g)/A;qo(l,L,E,V,P,Wr),qo(f,I,G,F,P,Ur),t.bezierCurveTo(Wr[1],Ur[1],Wr[2],Ur[2],Wr[3],Ur[3]);break t}g+=A}t.bezierCurveTo(L,I,E,G,V,F),l=V,f=F;break}case ht.Q:{var L=i[w++],I=i[w++],E=i[w++],G=i[w++];if(c){var A=p[y++];if(g+A>m){var P=(m-g)/A;Ko(l,L,E,P,Wr),Ko(f,I,G,P,Ur),t.quadraticCurveTo(Wr[1],Ur[1],Wr[2],Ur[2]);break t}g+=A}t.quadraticCurveTo(L,I,E,G),l=E,f=G;break}case ht.A:var J=i[w++],ut=i[w++],lt=i[w++],ct=i[w++],pt=i[w++],mt=i[w++],ye=i[w++],Rr=!i[w++],Ai=lt>ct?lt:ct,qt=Ue(lt-ct)>.001,Lt=pt+mt,K=!1;if(c){var A=p[y++];g+A>m&&(Lt=pt+mt*(m-g)/A,K=!0),g+=A}if(qt&&t.ellipse?t.ellipse(J,ut,lt,ct,ye,pt,Lt,Rr):t.arc(J,ut,Ai,pt,Lt,Rr),K)break t;C&&(s=Yr(pt)*lt+J,u=Zr(pt)*ct+ut),l=Yr(Lt)*lt+J,f=Zr(Lt)*ct+ut;break;case ht.R:s=l=i[w],u=f=i[w+1],h=i[w++],v=i[w++];var it=i[w++],Er=i[w++];if(c){var A=p[y++];if(g+A>m){var Ot=m-g;t.moveTo(h,v),t.lineTo(h+Vu(Ot,it),v),Ot-=it,Ot>0&&t.lineTo(h+it,v+Vu(Ot,Er)),Ot-=Er,Ot>0&&t.lineTo(h+Hu(it-Ot,0),v+Er),Ot-=it,Ot>0&&t.lineTo(h,v+Hu(Er-Ot,0));break t}g+=A}t.rect(h,v,it,Er);break;case ht.Z:if(c){var A=p[y++];if(g+A>m){var P=(m-g)/A;t.lineTo(l*(1-P)+s*P,f*(1-P)+u*P);break t}g+=A}t.closePath(),l=s,f=u}}},r.prototype.clone=function(){var t=new r,e=this.data;return t.data=e.slice?e.slice():Array.prototype.slice.call(e),t._len=this._len,t},r.CMD=ht,r.initDefaultProps=(function(){var t=r.prototype;t._saveData=!0,t._ux=0,t._uy=0,t._pendingPtDist=0,t._version=0})(),r})();function Ei(r,t,e,i,n,a,o){if(n===0)return!1;var s=n,u=0,l=r;if(o>t+s&&o>i+s||o<t-s&&o<i-s||a>r+s&&a>e+s||a<r-s&&a<e-s)return!1;if(r!==e)u=(t-i)/(r-e),l=(r*i-e*t)/(r-e);else return Math.abs(a-r)<=s/2;var f=u*a-o+l,h=f*f/(u*u+1);return h<=s/2*s/2}function Yw(r,t,e,i,n,a,o,s,u,l,f){if(u===0)return!1;var h=u;if(f>t+h&&f>i+h&&f>a+h&&f>s+h||f<t-h&&f<i-h&&f<a-h&&f<s-h||l>r+h&&l>e+h&&l>n+h&&l>o+h||l<r-h&&l<e-h&&l<n-h&&l<o-h)return!1;var v=gy(r,t,e,i,n,a,o,s,l,f,null);return v<=h/2}function Zw(r,t,e,i,n,a,o,s,u){if(o===0)return!1;var l=o;if(u>t+l&&u>i+l&&u>a+l||u<t-l&&u<i-l&&u<a-l||s>r+l&&s>e+l&&s>n+l||s<r-l&&s<e-l&&s<n-l)return!1;var f=my(r,t,e,i,n,a,s,u,null);return f<=l/2}var Sc=Math.PI*2;function qe(r){return r%=Sc,r<0&&(r+=Sc),r}var Pn=Math.PI*2;function Xw(r,t,e,i,n,a,o,s,u){if(o===0)return!1;var l=o;s-=r,u-=t;var f=Math.sqrt(s*s+u*u);if(f-l>e||f+l<e)return!1;if(Math.abs(i-n)%Pn<1e-4)return!0;if(a){var h=i;i=qe(n),n=qe(h)}else i=qe(i),n=qe(n);i>n&&(n+=Pn);var v=Math.atan2(u,s);return v<0&&(v+=Pn),v>=i&&v<=n||v+Pn>=i&&v+Pn<=n}function $e(r,t,e,i,n,a){if(a>t&&a>i||a<t&&a<i||i===t)return 0;var o=(a-t)/(i-t),s=i<t?1:-1;(o===1||o===0)&&(s=i<t?.5:-.5);var u=o*(e-r)+r;return u===n?1/0:u>n?s:0}var ur=Ar.CMD,Xr=Math.PI*2,$w=1e-4;function qw(r,t){return Math.abs(r-t)<$w}var Nt=[-1,-1,-1],se=[-1,-1];function Kw(){var r=se[0];se[0]=se[1],se[1]=r}function Qw(r,t,e,i,n,a,o,s,u,l){if(l>t&&l>i&&l>a&&l>s||l<t&&l<i&&l<a&&l<s)return 0;var f=$o(t,i,a,s,l,Nt);if(f===0)return 0;for(var h=0,v=-1,c=void 0,p=void 0,d=0;d<f;d++){var g=Nt[d],y=g===0||g===1?.5:1,m=Mt(r,e,n,o,g);m<u||(v<0&&(v=dy(t,i,a,s,se),se[1]<se[0]&&v>1&&Kw(),c=Mt(t,i,a,s,se[0]),v>1&&(p=Mt(t,i,a,s,se[1]))),v===2?g<se[0]?h+=c<t?y:-y:g<se[1]?h+=p<c?y:-y:h+=s<p?y:-y:g<se[0]?h+=c<t?y:-y:h+=s<c?y:-y)}return h}function Jw(r,t,e,i,n,a,o,s){if(s>t&&s>i&&s>a||s<t&&s<i&&s<a)return 0;var u=gS(t,i,a,s,Nt);if(u===0)return 0;var l=yy(t,i,a);if(l>=0&&l<=1){for(var f=0,h=Et(t,i,a,l),v=0;v<u;v++){var c=Nt[v]===0||Nt[v]===1?.5:1,p=Et(r,e,n,Nt[v]);p<o||(Nt[v]<l?f+=h<t?c:-c:f+=a<h?c:-c)}return f}else{var c=Nt[0]===0||Nt[0]===1?.5:1,p=Et(r,e,n,Nt[0]);return p<o?0:a<t?c:-c}}function jw(r,t,e,i,n,a,o,s){if(s-=t,s>e||s<-e)return 0;var u=Math.sqrt(e*e-s*s);Nt[0]=-u,Nt[1]=u;var l=Math.abs(i-n);if(l<1e-4)return 0;if(l>=Xr-1e-4){i=0,n=Xr;var f=a?1:-1;return o>=Nt[0]+r&&o<=Nt[1]+r?f:0}if(i>n){var h=i;i=n,n=h}i<0&&(i+=Xr,n+=Xr);for(var v=0,c=0;c<2;c++){var p=Nt[c];if(p+r>o){var d=Math.atan2(s,p),f=a?1:-1;d<0&&(d=Xr+d),(d>=i&&d<=n||d+Xr>=i&&d+Xr<=n)&&(d>Math.PI/2&&d<Math.PI*1.5&&(f=-f),v+=f)}}return v}function Yy(r,t,e,i,n){for(var a=r.data,o=r.len(),s=0,u=0,l=0,f=0,h=0,v,c,p=0;p<o;){var d=a[p++],g=p===1;switch(d===ur.M&&p>1&&(e||(s+=$e(u,l,f,h,i,n))),g&&(u=a[p],l=a[p+1],f=u,h=l),d){case ur.M:f=a[p++],h=a[p++],u=f,l=h;break;case ur.L:if(e){if(Ei(u,l,a[p],a[p+1],t,i,n))return!0}else s+=$e(u,l,a[p],a[p+1],i,n)||0;u=a[p++],l=a[p++];break;case ur.C:if(e){if(Yw(u,l,a[p++],a[p++],a[p++],a[p++],a[p],a[p+1],t,i,n))return!0}else s+=Qw(u,l,a[p++],a[p++],a[p++],a[p++],a[p],a[p+1],i,n)||0;u=a[p++],l=a[p++];break;case ur.Q:if(e){if(Zw(u,l,a[p++],a[p++],a[p],a[p+1],t,i,n))return!0}else s+=Jw(u,l,a[p++],a[p++],a[p],a[p+1],i,n)||0;u=a[p++],l=a[p++];break;case ur.A:var y=a[p++],m=a[p++],_=a[p++],S=a[p++],b=a[p++],w=a[p++];p+=1;var x=!!(1-a[p++]);v=Math.cos(b)*_+y,c=Math.sin(b)*S+m,g?(f=v,h=c):s+=$e(u,l,v,c,i,n);var C=(i-y)*S/_+y;if(e){if(Xw(y,m,S,b,b+w,x,t,C,n))return!0}else s+=jw(y,m,S,b,b+w,x,C,n);u=Math.cos(b+w)*_+y,l=Math.sin(b+w)*S+m;break;case ur.R:f=u=a[p++],h=l=a[p++];var M=a[p++],D=a[p++];if(v=f+M,c=h+D,e){if(Ei(f,h,v,h,t,i,n)||Ei(v,h,v,c,t,i,n)||Ei(v,c,f,c,t,i,n)||Ei(f,c,f,h,t,i,n))return!0}else s+=$e(v,h,v,c,i,n),s+=$e(f,c,f,h,i,n);break;case ur.Z:if(e){if(Ei(u,l,f,h,t,i,n))return!0}else s+=$e(u,l,f,h,i,n);u=f,l=h;break}}return!e&&!qw(l,h)&&(s+=$e(u,l,f,h,i,n)||0),s!==0}function tb(r,t,e){return Yy(r,0,!1,t,e)}function eb(r,t,e,i){return Yy(r,t,!0,e,i)}var Zy=rt({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},vi),rb={style:rt({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},ks.style)},Uu=Ve.concat(["invisible","culling","z","z2","zlevel","parent"]),st=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.update=function(){var e=this;r.prototype.update.call(this);var i=this.style;if(i.decal){var n=this._decalEl=this._decalEl||new t;n.buildPath===t.prototype.buildPath&&(n.buildPath=function(u){e.buildPath(u,e.shape)}),n.silent=!0;var a=n.style;for(var o in i)a[o]!==i[o]&&(a[o]=i[o]);a.fill=i.fill?i.decal:null,a.decal=null,a.shadowColor=null,i.strokeFirst&&(a.stroke=null);for(var s=0;s<Uu.length;++s)n[Uu[s]]=this[Uu[s]];n.__dirty|=Jt}else this._decalEl&&(this._decalEl=null)},t.prototype.getDecalElement=function(){return this._decalEl},t.prototype._init=function(e){var i=ft(e);this.shape=this.getDefaultShape();var n=this.getDefaultStyle();n&&this.useStyle(n);for(var a=0;a<i.length;a++){var o=i[a],s=e[o];o==="style"?this.style?k(this.style,s):this.useStyle(s):o==="shape"?k(this.shape,s):r.prototype.attrKV.call(this,o,s)}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(H(e)){var i=Qo(e,0);return i>.5?cf:i>.2?zS:pf}else if(e)return pf}return cf},t.prototype.getInsideTextStroke=function(e){var i=this.style.fill;if(H(i)){var n=this.__zr,a=!!(n&&n.isDarkMode()),o=Qo(e,0)<vf;if(a===o)return i}},t.prototype.buildPath=function(e,i,n){},t.prototype.pathUpdated=function(){this.__dirty&=~Ui},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 Ar(!1)},t.prototype.hasStroke=function(){var e=this.style,i=e.stroke;return!(i==null||i==="none"||!(e.lineWidth>0))},t.prototype.hasFill=function(){var e=this.style,i=e.fill;return i!=null&&i!=="none"},t.prototype.getBoundingRect=function(){var e=this._rect,i=this.style,n=!e;if(n){var a=!1;this.path||(a=!0,this.createPathProxy());var o=this.path;(a||this.__dirty&Ui)&&(o.beginPath(),this.buildPath(o,this.shape,!1),this.pathUpdated()),e=o.getBoundingRect()}if(this._rect=e,this.hasStroke()&&this.path&&this.path.len()>0){var s=this._rectStroke||(this._rectStroke=e.clone());if(this.__dirty||n){s.copy(e);var u=i.strokeNoScale?this.getLineScale():1,l=i.lineWidth;if(!this.hasFill()){var f=this.strokeContainThreshold;l=Math.max(l,f??4)}u>1e-10&&(s.width+=l/u,s.height+=l/u,s.x-=l/u/2,s.y-=l/u/2)}return s}return e},t.prototype.contain=function(e,i){var n=this.transformCoordToLocal(e,i),a=this.getBoundingRect(),o=this.style;if(e=n[0],i=n[1],a.contain(e,i)){var s=this.path;if(this.hasStroke()){var u=o.lineWidth,l=o.strokeNoScale?this.getLineScale():1;if(l>1e-10&&(this.hasFill()||(u=Math.max(u,this.strokeContainThreshold)),eb(s,u/l,e,i)))return!0}if(this.hasFill())return tb(s,e,i)}return!1},t.prototype.dirtyShape=function(){this.__dirty|=Ui,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},t.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},t.prototype.animateShape=function(e){return this.animate("shape",e)},t.prototype.updateDuringAnimation=function(e){e==="style"?this.dirtyStyle():e==="shape"?this.dirtyShape():this.markRedraw()},t.prototype.attrKV=function(e,i){e==="shape"?this.setShape(i):r.prototype.attrKV.call(this,e,i)},t.prototype.setShape=function(e,i){var n=this.shape;return n||(n=this.shape={}),typeof e=="string"?n[e]=i:k(n,e),this.dirtyShape(),this},t.prototype.shapeChanged=function(){return!!(this.__dirty&Ui)},t.prototype.createStyle=function(e){return As(Zy,e)},t.prototype._innerSaveToNormal=function(e){r.prototype._innerSaveToNormal.call(this,e);var i=this._normalState;e.shape&&!i.shape&&(i.shape=k({},this.shape))},t.prototype._applyStateObj=function(e,i,n,a,o,s){r.prototype._applyStateObj.call(this,e,i,n,a,o,s);var u=!(i&&a),l;if(i&&i.shape?o?a?l=i.shape:(l=k({},n.shape),k(l,i.shape)):(l=k({},a?this.shape:n.shape),k(l,i.shape)):u&&(l=n.shape),l)if(o){this.shape=k({},this.shape);for(var f={},h=ft(l),v=0;v<h.length;v++){var c=h[v];typeof l[c]=="object"?this.shape[c]=l[c]:f[c]=l[c]}this._transitionState(e,{shape:f},s)}else this.shape=l,this.dirtyShape()},t.prototype._mergeStates=function(e){for(var i=r.prototype._mergeStates.call(this,e),n,a=0;a<e.length;a++){var o=e[a];o.shape&&(n=n||{},this._mergeStyle(n,o.shape))}return n&&(i.shape=n),i},t.prototype.getAnimationStyleProps=function(){return rb},t.prototype.isZeroArea=function(){return!1},t.extend=function(e){var i=(function(a){O(o,a);function o(s){var u=a.call(this,s)||this;return e.init&&e.init.call(u,s),u}return o.prototype.getDefaultStyle=function(){return Y(e.style)},o.prototype.getDefaultShape=function(){return Y(e.shape)},o})(t);for(var n in e)typeof e[n]=="function"&&(i.prototype[n]=e[n]);return i},t.initDefaultProps=(function(){var e=t.prototype;e.type="path",e.strokeContainThreshold=5,e.segmentIgnoreThreshold=0,e.subPixelOptimize=!1,e.autoBatch=!1,e.__dirty=Jt|Kn|Ui})(),t})(Mi),ib=rt({strokeFirst:!0,font:di,x:0,y:0,textAlign:"left",textBaseline:"top",miterLimit:2},Zy),es=(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.hasStroke=function(){var e=this.style,i=e.stroke;return i!=null&&i!=="none"&&e.lineWidth>0},t.prototype.hasFill=function(){var e=this.style,i=e.fill;return i!=null&&i!=="none"},t.prototype.createStyle=function(e){return As(ib,e)},t.prototype.setBoundingRect=function(e){this._rect=e},t.prototype.getBoundingRect=function(){var e=this.style;if(!this._rect){var i=e.text;i!=null?i+="":i="";var n=Sh(i,e.font,e.textAlign,e.textBaseline);if(n.x+=e.x||0,n.y+=e.y||0,this.hasStroke()){var a=e.lineWidth;n.x-=a/2,n.y-=a/2,n.width+=a,n.height+=a}this._rect=n}return this._rect},t.initDefaultProps=(function(){var e=t.prototype;e.dirtyRectTolerance=10})(),t})(Mi);es.prototype.type="tspan";var nb=rt({x:0,y:0},vi),ab={style:rt({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},ks.style)};function ob(r){return!!(r&&typeof r!="string"&&r.width&&r.height)}var nr=(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.createStyle=function(e){return As(nb,e)},t.prototype._getSize=function(e){var i=this.style,n=i[e];if(n!=null)return n;var a=ob(i.image)?i.image:this.__image;if(!a)return 0;var o=e==="width"?"height":"width",s=i[o];return s==null?a[e]:a[e]/a[o]*s},t.prototype.getWidth=function(){return this._getSize("width")},t.prototype.getHeight=function(){return this._getSize("height")},t.prototype.getAnimationStyleProps=function(){return ab},t.prototype.getBoundingRect=function(){var e=this.style;return this._rect||(this._rect=new et(e.x||0,e.y||0,this.getWidth(),this.getHeight())),this._rect},t})(Mi);nr.prototype.type="image";function sb(r,t){var e=t.x,i=t.y,n=t.width,a=t.height,o=t.r,s,u,l,f;n<0&&(e=e+n,n=-n),a<0&&(i=i+a,a=-a),typeof o=="number"?s=u=l=f=o:o instanceof Array?o.length===1?s=u=l=f=o[0]:o.length===2?(s=l=o[0],u=f=o[1]):o.length===3?(s=o[0],u=f=o[1],l=o[2]):(s=o[0],u=o[1],l=o[2],f=o[3]):s=u=l=f=0;var h;s+u>n&&(h=s+u,s*=n/h,u*=n/h),l+f>n&&(h=l+f,l*=n/h,f*=n/h),u+l>a&&(h=u+l,u*=a/h,l*=a/h),s+f>a&&(h=s+f,s*=a/h,f*=a/h),r.moveTo(e+s,i),r.lineTo(e+n-u,i),u!==0&&r.arc(e+n-u,i+u,u,-Math.PI/2,0),r.lineTo(e+n,i+a-l),l!==0&&r.arc(e+n-l,i+a-l,l,0,Math.PI/2),r.lineTo(e+f,i+a),f!==0&&r.arc(e+f,i+a-f,f,Math.PI/2,Math.PI),r.lineTo(e,i+s),s!==0&&r.arc(e+s,i+s,s,Math.PI,Math.PI*1.5)}var Ki=Math.round;function Xy(r,t,e){if(t){var i=t.x1,n=t.x2,a=t.y1,o=t.y2;r.x1=i,r.x2=n,r.y1=a,r.y2=o;var s=e&&e.lineWidth;return s&&(Ki(i*2)===Ki(n*2)&&(r.x1=r.x2=si(i,s,!0)),Ki(a*2)===Ki(o*2)&&(r.y1=r.y2=si(a,s,!0))),r}}function $y(r,t,e){if(t){var i=t.x,n=t.y,a=t.width,o=t.height;r.x=i,r.y=n,r.width=a,r.height=o;var s=e&&e.lineWidth;return s&&(r.x=si(i,s,!0),r.y=si(n,s,!0),r.width=Math.max(si(i+a,s,!1)-r.x,a===0?0:1),r.height=Math.max(si(n+o,s,!1)-r.y,o===0?0:1)),r}}function si(r,t,e){if(!t)return r;var i=Ki(r*2);return(i+Ki(t))%2===0?i/2:(i+(e?1:-1))/2}var ub=(function(){function r(){this.x=0,this.y=0,this.width=0,this.height=0}return r})(),lb={},Tt=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new ub},t.prototype.buildPath=function(e,i){var n,a,o,s;if(this.subPixelOptimize){var u=$y(lb,i,this.style);n=u.x,a=u.y,o=u.width,s=u.height,u.r=i.r,i=u}else n=i.x,a=i.y,o=i.width,s=i.height;i.r?sb(e,i):e.rect(n,a,o,s)},t.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},t})(st);Tt.prototype.type="rect";var wc={fill:"#000"},bc=2,fb={style:rt({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},ks.style)},te=(function(r){O(t,r);function t(e){var i=r.call(this)||this;return i.type="text",i._children=[],i._defaultStyle=wc,i.attr(e),i}return t.prototype.childrenRef=function(){return this._children},t.prototype.update=function(){r.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var e=0;e<this._children.length;e++){var i=this._children[e];i.zlevel=this.zlevel,i.z=this.z,i.z2=this.z2,i.culling=this.culling,i.cursor=this.cursor,i.invisible=this.invisible}},t.prototype.updateTransform=function(){var e=this.innerTransformable;e?(e.updateTransform(),e.transform&&(this.transform=e.transform)):r.prototype.updateTransform.call(this)},t.prototype.getLocalTransform=function(e){var i=this.innerTransformable;return i?i.getLocalTransform(e):r.prototype.getLocalTransform.call(this,e)},t.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),r.prototype.getComputedTransform.call(this)},t.prototype._updateSubTexts=function(){this._childCursor=0,db(this.style),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},t.prototype.addSelfToZr=function(e){r.prototype.addSelfToZr.call(this,e);for(var i=0;i<this._children.length;i++)this._children[i].__zr=e},t.prototype.removeSelfFromZr=function(e){r.prototype.removeSelfFromZr.call(this,e);for(var i=0;i<this._children.length;i++)this._children[i].__zr=null},t.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var e=new et(0,0,0,0),i=this._children,n=[],a=null,o=0;o<i.length;o++){var s=i[o],u=s.getBoundingRect(),l=s.getLocalTransform(n);l?(e.copy(u),e.applyTransform(l),a=a||e.clone(),a.union(e)):(a=a||u.clone(),a.union(u))}this._rect=a||e}return this._rect},t.prototype.setDefaultTextStyle=function(e){this._defaultStyle=e||wc},t.prototype.setTextContent=function(e){},t.prototype._mergeStyle=function(e,i){if(!i)return e;var n=i.rich,a=e.rich||n&&{};return k(e,i),n&&a?(this._mergeRich(a,n),e.rich=a):a&&(e.rich=a),e},t.prototype._mergeRich=function(e,i){for(var n=ft(i),a=0;a<n.length;a++){var o=n[a];e[o]=e[o]||{},k(e[o],i[o])}},t.prototype.getAnimationStyleProps=function(){return fb},t.prototype._getOrCreateChild=function(e){var i=this._children[this._childCursor];return(!i||!(i instanceof e))&&(i=new e),this._children[this._childCursor++]=i,i.__zr=this.__zr,i.parent=this,i},t.prototype._updatePlainTexts=function(){var e=this.style,i=e.font||di,n=e.padding,a=Lc(e),o=Rw(a,e),s=Yu(e),u=!!e.backgroundColor,l=o.outerHeight,f=o.outerWidth,h=o.contentWidth,v=o.lines,c=o.lineHeight,p=this._defaultStyle;this.isTruncated=!!o.isTruncated;var d=e.x||0,g=e.y||0,y=e.align||p.align||"left",m=e.verticalAlign||p.verticalAlign||"top",_=d,S=Yi(g,o.contentHeight,m);if(s||n){var b=Jn(d,f,y),w=Yi(g,l,m);s&&this._renderBackground(e,e,b,w,f,l)}S+=c/2,n&&(_=Ac(d,y,n),m==="top"?S+=n[0]:m==="bottom"&&(S-=n[2]));for(var x=0,C=!1,M=Dc("fill"in e?e.fill:(C=!0,p.fill)),D=Cc("stroke"in e?e.stroke:!u&&(!p.autoStroke||C)?(x=bc,p.stroke):null),A=e.textShadowBlur>0,P=e.width!=null&&(e.overflow==="truncate"||e.overflow==="break"||e.overflow==="breakAll"),R=o.calculatedLineHeight,L=0;L<v.length;L++){var I=this._getOrCreateChild(es),E=I.createStyle();I.useStyle(E),E.text=v[L],E.x=_,E.y=S,E.textAlign=y,E.textBaseline="middle",E.opacity=e.opacity,E.strokeFirst=!0,A&&(E.shadowBlur=e.textShadowBlur||0,E.shadowColor=e.textShadowColor||"transparent",E.shadowOffsetX=e.textShadowOffsetX||0,E.shadowOffsetY=e.textShadowOffsetY||0),E.stroke=D,E.fill=M,D&&(E.lineWidth=e.lineWidth||x,E.lineDash=e.lineDash,E.lineDashOffset=e.lineDashOffset||0),E.font=i,Tc(E,e),S+=c,P&&I.setBoundingRect(new et(Jn(E.x,h,E.textAlign),Yi(E.y,R,E.textBaseline),h,R))}},t.prototype._updateRichTexts=function(){var e=this.style,i=Lc(e),n=Ow(i,e),a=n.width,o=n.outerWidth,s=n.outerHeight,u=e.padding,l=e.x||0,f=e.y||0,h=this._defaultStyle,v=e.align||h.align,c=e.verticalAlign||h.verticalAlign;this.isTruncated=!!n.isTruncated;var p=Jn(l,o,v),d=Yi(f,s,c),g=p,y=d;u&&(g+=u[3],y+=u[0]);var m=g+a;Yu(e)&&this._renderBackground(e,e,p,d,o,s);for(var _=!!e.backgroundColor,S=0;S<n.lines.length;S++){for(var b=n.lines[S],w=b.tokens,x=w.length,C=b.lineHeight,M=b.width,D=0,A=g,P=m,R=x-1,L=void 0;D<x&&(L=w[D],!L.align||L.align==="left");)this._placeToken(L,e,C,y,A,"left",_),M-=L.width,A+=L.width,D++;for(;R>=0&&(L=w[R],L.align==="right");)this._placeToken(L,e,C,y,P,"right",_),M-=L.width,P-=L.width,R--;for(A+=(a-(A-g)-(m-P)-M)/2;D<=R;)L=w[D],this._placeToken(L,e,C,y,A+L.width/2,"center",_),A+=L.width,D++;y+=C}},t.prototype._placeToken=function(e,i,n,a,o,s,u){var l=i.rich[e.styleName]||{};l.text=e.text;var f=e.verticalAlign,h=a+n/2;f==="top"?h=a+e.height/2:f==="bottom"&&(h=a+n-e.height/2);var v=!e.isLineHolder&&Yu(l);v&&this._renderBackground(l,i,s==="right"?o-e.width:s==="center"?o-e.width/2:o,h-e.height/2,e.width,e.height);var c=!!l.backgroundColor,p=e.textPadding;p&&(o=Ac(o,s,p),h-=e.height/2-p[0]-e.innerHeight/2);var d=this._getOrCreateChild(es),g=d.createStyle();d.useStyle(g);var y=this._defaultStyle,m=!1,_=0,S=Dc("fill"in l?l.fill:"fill"in i?i.fill:(m=!0,y.fill)),b=Cc("stroke"in l?l.stroke:"stroke"in i?i.stroke:!c&&!u&&(!y.autoStroke||m)?(_=bc,y.stroke):null),w=l.textShadowBlur>0||i.textShadowBlur>0;g.text=e.text,g.x=o,g.y=h,w&&(g.shadowBlur=l.textShadowBlur||i.textShadowBlur||0,g.shadowColor=l.textShadowColor||i.textShadowColor||"transparent",g.shadowOffsetX=l.textShadowOffsetX||i.textShadowOffsetX||0,g.shadowOffsetY=l.textShadowOffsetY||i.textShadowOffsetY||0),g.textAlign=s,g.textBaseline="middle",g.font=e.font||di,g.opacity=aa(l.opacity,i.opacity,1),Tc(g,l),b&&(g.lineWidth=aa(l.lineWidth,i.lineWidth,_),g.lineDash=$(l.lineDash,i.lineDash),g.lineDashOffset=i.lineDashOffset||0,g.stroke=b),S&&(g.fill=S);var x=e.contentWidth,C=e.contentHeight;d.setBoundingRect(new et(Jn(g.x,x,g.textAlign),Yi(g.y,C,g.textBaseline),x,C))},t.prototype._renderBackground=function(e,i,n,a,o,s){var u=e.backgroundColor,l=e.borderWidth,f=e.borderColor,h=u&&u.image,v=u&&!h,c=e.borderRadius,p=this,d,g;if(v||e.lineHeight||l&&f){d=this._getOrCreateChild(Tt),d.useStyle(d.createStyle()),d.style.fill=null;var y=d.shape;y.x=n,y.y=a,y.width=o,y.height=s,y.r=c,d.dirtyShape()}if(v){var m=d.style;m.fill=u||null,m.fillOpacity=$(e.fillOpacity,1)}else if(h){g=this._getOrCreateChild(nr),g.onload=function(){p.dirtyStyle()};var _=g.style;_.image=u.image,_.x=n,_.y=a,_.width=o,_.height=s}if(l&&f){var m=d.style;m.lineWidth=l,m.stroke=f,m.strokeOpacity=$(e.strokeOpacity,1),m.lineDash=e.borderDash,m.lineDashOffset=e.borderDashOffset||0,d.strokeContainThreshold=0,d.hasFill()&&d.hasStroke()&&(m.strokeFirst=!0,m.lineWidth*=2)}var S=(d||g).style;S.shadowBlur=e.shadowBlur||0,S.shadowColor=e.shadowColor||"transparent",S.shadowOffsetX=e.shadowOffsetX||0,S.shadowOffsetY=e.shadowOffsetY||0,S.opacity=aa(e.opacity,i.opacity,1)},t.makeFont=function(e){var i="";return pb(e)&&(i=[e.fontStyle,e.fontWeight,cb(e.fontSize),e.fontFamily||"sans-serif"].join(" ")),i&&Oe(i)||e.textFont||e.font},t})(Mi),hb={left:!0,right:1,center:1},vb={top:1,bottom:1,middle:1},xc=["fontStyle","fontWeight","fontSize","fontFamily"];function cb(r){return typeof r=="string"&&(r.indexOf("px")!==-1||r.indexOf("rem")!==-1||r.indexOf("em")!==-1)?r:isNaN(+r)?fh+"px":r+"px"}function Tc(r,t){for(var e=0;e<xc.length;e++){var i=xc[e],n=t[i];n!=null&&(r[i]=n)}}function pb(r){return r.fontSize!=null||r.fontFamily||r.fontWeight}function db(r){return Mc(r),T(r.rich,Mc),r}function Mc(r){if(r){r.font=te.makeFont(r);var t=r.align;t==="middle"&&(t="center"),r.align=t==null||hb[t]?t:"left";var e=r.verticalAlign;e==="center"&&(e="middle"),r.verticalAlign=e==null||vb[e]?e:"top";var i=r.padding;i&&(r.padding=iy(r.padding))}}function Cc(r,t){return r==null||t<=0||r==="transparent"||r==="none"?null:r.image||r.colorStops?"#000":r}function Dc(r){return r==null||r==="none"?null:r.image||r.colorStops?"#000":r}function Ac(r,t,e){return t==="right"?r-e[1]:t==="center"?r+e[3]/2-e[1]/2:r+e[3]}function Lc(r){var t=r.text;return t!=null&&(t+=""),t}function Yu(r){return!!(r.backgroundColor||r.lineHeight||r.borderWidth&&r.borderColor)}var at=vt(),gb=function(r,t,e,i){if(i){var n=at(i);n.dataIndex=e,n.dataType=t,n.seriesIndex=r,n.ssrType="chart",i.type==="group"&&i.traverse(function(a){var o=at(a);o.seriesIndex=r,o.dataIndex=e,o.dataType=t,o.ssrType="chart"})}},Pc=1,Ic={},qy=vt(),Mh=vt(),Ch=0,Os=1,Bs=2,Zt=["emphasis","blur","select"],rs=["normal","emphasis","blur","select"],yb=10,mb=9,ci="highlight",Fo="downplay",fa="select",zo="unselect",ha="toggleSelect";function ki(r){return r!=null&&r!=="none"}function Ns(r,t,e){r.onHoverStateChange&&(r.hoverState||0)!==e&&r.onHoverStateChange(t),r.hoverState=e}function Ky(r){Ns(r,"emphasis",Bs)}function Qy(r){r.hoverState===Bs&&Ns(r,"normal",Ch)}function Dh(r){Ns(r,"blur",Os)}function Jy(r){r.hoverState===Os&&Ns(r,"normal",Ch)}function _b(r){r.selected=!0}function Sb(r){r.selected=!1}function Rc(r,t,e){t(r,e)}function ar(r,t,e){Rc(r,t,e),r.isGroup&&r.traverse(function(i){Rc(i,t,e)})}function Ec(r,t){switch(t){case"emphasis":r.hoverState=Bs;break;case"normal":r.hoverState=Ch;break;case"blur":r.hoverState=Os;break;case"select":r.selected=!0}}function wb(r,t,e,i){for(var n=r.style,a={},o=0;o<t.length;o++){var s=t[o],u=n[s];a[s]=u??(i&&i[s])}for(var o=0;o<r.animators.length;o++){var l=r.animators[o];l.__fromStateTransition&&l.__fromStateTransition.indexOf(e)<0&&l.targetName==="style"&&l.saveTo(a,t)}return a}function bb(r,t,e,i){var n=e&&Q(e,"select")>=0,a=!1;if(r instanceof st){var o=qy(r),s=n&&o.selectFill||o.normalFill,u=n&&o.selectStroke||o.normalStroke;if(ki(s)||ki(u)){i=i||{};var l=i.style||{};l.fill==="inherit"?(a=!0,i=k({},i),l=k({},l),l.fill=s):!ki(l.fill)&&ki(s)?(a=!0,i=k({},i),l=k({},l),l.fill=Jv(s)):!ki(l.stroke)&&ki(u)&&(a||(i=k({},i),l=k({},l)),l.stroke=Jv(u)),i.style=l}}if(i&&i.z2==null){a||(i=k({},i));var f=r.z2EmphasisLift;i.z2=r.z2+(f??yb)}return i}function xb(r,t,e){if(e&&e.z2==null){e=k({},e);var i=r.z2SelectLift;e.z2=r.z2+(i??mb)}return e}function Tb(r,t,e){var i=Q(r.currentStates,t)>=0,n=r.style.opacity,a=i?null:wb(r,["opacity"],t,{opacity:1});e=e||{};var o=e.style||{};return o.opacity==null&&(e=k({},e),o=k({opacity:i?n:a.opacity*.1},o),e.style=o),e}function Zu(r,t){var e=this.states[r];if(this.style){if(r==="emphasis")return bb(this,r,t,e);if(r==="blur")return Tb(this,r,e);if(r==="select")return xb(this,r,e)}return e}function jy(r){r.stateProxy=Zu;var t=r.getTextContent(),e=r.getTextGuideLine();t&&(t.stateProxy=Zu),e&&(e.stateProxy=Zu)}function kc(r,t){!im(r,t)&&!r.__highByOuter&&ar(r,Ky)}function Oc(r,t){!im(r,t)&&!r.__highByOuter&&ar(r,Qy)}function ba(r,t){r.__highByOuter|=1<<(t||0),ar(r,Ky)}function xa(r,t){!(r.__highByOuter&=~(1<<(t||0)))&&ar(r,Qy)}function tm(r){ar(r,Dh)}function Ah(r){ar(r,Jy)}function em(r){ar(r,_b)}function rm(r){ar(r,Sb)}function im(r,t){return r.__highDownSilentOnTouch&&t.zrByTouch}function nm(r){var t=r.getModel(),e=[],i=[];t.eachComponent(function(n,a){var o=Mh(a),s=n==="series",u=s?r.getViewOfSeriesModel(a):r.getViewOfComponentModel(a);!s&&i.push(u),o.isBlured&&(u.group.traverse(function(l){Jy(l)}),s&&e.push(a)),o.isBlured=!1}),T(i,function(n){n&&n.toggleBlurSeries&&n.toggleBlurSeries(e,!1,t)})}function _f(r,t,e,i){var n=i.getModel();e=e||"coordinateSystem";function a(l,f){for(var h=0;h<f.length;h++){var v=l.getItemGraphicEl(f[h]);v&&Ah(v)}}if(r!=null&&!(!t||t==="none")){var o=n.getSeriesByIndex(r),s=o.coordinateSystem;s&&s.master&&(s=s.master);var u=[];n.eachSeries(function(l){var f=o===l,h=l.coordinateSystem;h&&h.master&&(h=h.master);var v=h&&s?h===s:f;if(!(e==="series"&&!f||e==="coordinateSystem"&&!v||t==="series"&&f)){var c=i.getViewOfSeriesModel(l);if(c.group.traverse(function(g){g.__highByOuter&&f&&t==="self"||Dh(g)}),zt(t))a(l.getData(),t);else if(W(t))for(var p=ft(t),d=0;d<p.length;d++)a(l.getData(p[d]),t[p[d]]);u.push(l),Mh(l).isBlured=!0}}),n.eachComponent(function(l,f){if(l!=="series"){var h=i.getViewOfComponentModel(f);h&&h.toggleBlurSeries&&h.toggleBlurSeries(u,!0,n)}})}}function Sf(r,t,e){if(!(r==null||t==null)){var i=e.getModel().getComponent(r,t);if(i){Mh(i).isBlured=!0;var n=e.getViewOfComponentModel(i);!n||!n.focusBlurEnabled||n.group.traverse(function(a){Dh(a)})}}}function Mb(r,t,e){var i=r.seriesIndex,n=r.getData(t.dataType);if(n){var a=yi(n,t);a=(B(a)?a[0]:a)||0;var o=n.getItemGraphicEl(a);if(!o)for(var s=n.count(),u=0;!o&&u<s;)o=n.getItemGraphicEl(u++);if(o){var l=at(o);_f(i,l.focus,l.blurScope,e)}else{var f=r.get(["emphasis","focus"]),h=r.get(["emphasis","blurScope"]);f!=null&&_f(i,f,h,e)}}}function Lh(r,t,e,i){var n={focusSelf:!1,dispatchers:null};if(r==null||r==="series"||t==null||e==null)return n;var a=i.getModel().getComponent(r,t);if(!a)return n;var o=i.getViewOfComponentModel(a);if(!o||!o.findHighDownDispatchers)return n;for(var s=o.findHighDownDispatchers(e),u,l=0;l<s.length;l++)if(at(s[l]).focus==="self"){u=!0;break}return{focusSelf:u,dispatchers:s}}function Cb(r,t,e){var i=at(r),n=Lh(i.componentMainType,i.componentIndex,i.componentHighDownName,e),a=n.dispatchers,o=n.focusSelf;a?(o&&Sf(i.componentMainType,i.componentIndex,e),T(a,function(s){return kc(s,t)})):(_f(i.seriesIndex,i.focus,i.blurScope,e),i.focus==="self"&&Sf(i.componentMainType,i.componentIndex,e),kc(r,t))}function Db(r,t,e){nm(e);var i=at(r),n=Lh(i.componentMainType,i.componentIndex,i.componentHighDownName,e).dispatchers;n?T(n,function(a){return Oc(a,t)}):Oc(r,t)}function Ab(r,t,e){if(xf(t)){var i=t.dataType,n=r.getData(i),a=yi(n,t);B(a)||(a=[a]),r[t.type===ha?"toggleSelect":t.type===fa?"select":"unselect"](a,i)}}function Bc(r){var t=r.getAllData();T(t,function(e){var i=e.data,n=e.type;i.eachItemGraphicEl(function(a,o){r.isSelected(o,n)?em(a):rm(a)})})}function Lb(r){var t=[];return r.eachSeries(function(e){var i=e.getAllData();T(i,function(n){n.data;var a=n.type,o=e.getSelectedDataIndices();if(o.length>0){var s={dataIndex:o,seriesIndex:e.seriesIndex};a!=null&&(s.dataType=a),t.push(s)}})}),t}function am(r,t,e){om(r,!0),ar(r,jy),Ib(r,t,e)}function Pb(r){om(r,!1)}function vn(r,t,e,i){i?Pb(r):am(r,t,e)}function Ib(r,t,e){var i=at(r);t!=null?(i.focus=t,i.blurScope=e):i.focus&&(i.focus=null)}var Nc=["emphasis","blur","select"],Rb={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function wf(r,t,e,i){e=e||"itemStyle";for(var n=0;n<Nc.length;n++){var a=Nc[n],o=t.getModel([a,e]),s=r.ensureState(a);s.style=o[Rb[e]]()}}function om(r,t){var e=t===!1,i=r;r.highDownSilentOnTouch&&(i.__highDownSilentOnTouch=r.highDownSilentOnTouch),(!e||i.__highDownDispatcher)&&(i.__highByOuter=i.__highByOuter||0,i.__highDownDispatcher=!e)}function bf(r){return!!(r&&r.__highDownDispatcher)}function Eb(r){var t=Ic[r];return t==null&&Pc<=32&&(t=Ic[r]=Pc++),t}function xf(r){var t=r.type;return t===fa||t===zo||t===ha}function Fc(r){var t=r.type;return t===ci||t===Fo}function kb(r){var t=qy(r);t.normalFill=r.style.fill,t.normalStroke=r.style.stroke;var e=r.states.select||{};t.selectFill=e.style&&e.style.fill||null,t.selectStroke=e.style&&e.style.stroke||null}var Oi=Ar.CMD,Ob=[[],[],[]],zc=Math.sqrt,Bb=Math.atan2;function Nb(r,t){if(t){var e=r.data,i=r.len(),n,a,o,s,u,l,f=Oi.M,h=Oi.C,v=Oi.L,c=Oi.R,p=Oi.A,d=Oi.Q;for(o=0,s=0;o<i;){switch(n=e[o++],s=o,a=0,n){case f:a=1;break;case v:a=1;break;case h:a=3;break;case d:a=2;break;case p:var g=t[4],y=t[5],m=zc(t[0]*t[0]+t[1]*t[1]),_=zc(t[2]*t[2]+t[3]*t[3]),S=Bb(-t[1]/_,t[0]/m);e[o]*=m,e[o++]+=g,e[o]*=_,e[o++]+=y,e[o++]*=m,e[o++]*=_,e[o++]+=S,e[o++]+=S,o+=2,s=o;break;case c:l[0]=e[o++],l[1]=e[o++],ve(l,l,t),e[s++]=l[0],e[s++]=l[1],l[0]+=e[o++],l[1]+=e[o++],ve(l,l,t),e[s++]=l[0],e[s++]=l[1]}for(u=0;u<a;u++){var b=Ob[u];b[0]=e[o++],b[1]=e[o++],ve(b,b,t),e[s++]=b[0],e[s++]=b[1]}}r.increaseVersion()}}var Xu=Math.sqrt,to=Math.sin,eo=Math.cos,In=Math.PI;function Vc(r){return Math.sqrt(r[0]*r[0]+r[1]*r[1])}function Tf(r,t){return(r[0]*t[0]+r[1]*t[1])/(Vc(r)*Vc(t))}function Hc(r,t){return(r[0]*t[1]<r[1]*t[0]?-1:1)*Math.acos(Tf(r,t))}function Gc(r,t,e,i,n,a,o,s,u,l,f){var h=u*(In/180),v=eo(h)*(r-e)/2+to(h)*(t-i)/2,c=-1*to(h)*(r-e)/2+eo(h)*(t-i)/2,p=v*v/(o*o)+c*c/(s*s);p>1&&(o*=Xu(p),s*=Xu(p));var d=(n===a?-1:1)*Xu((o*o*(s*s)-o*o*(c*c)-s*s*(v*v))/(o*o*(c*c)+s*s*(v*v)))||0,g=d*o*c/s,y=d*-s*v/o,m=(r+e)/2+eo(h)*g-to(h)*y,_=(t+i)/2+to(h)*g+eo(h)*y,S=Hc([1,0],[(v-g)/o,(c-y)/s]),b=[(v-g)/o,(c-y)/s],w=[(-1*v-g)/o,(-1*c-y)/s],x=Hc(b,w);if(Tf(b,w)<=-1&&(x=In),Tf(b,w)>=1&&(x=0),x<0){var C=Math.round(x/In*1e6)/1e6;x=In*2+C%2*In}f.addData(l,m,_,o,s,S,x,h,a)}var Fb=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/ig,zb=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function Vb(r){var t=new Ar;if(!r)return t;var e=0,i=0,n=e,a=i,o,s=Ar.CMD,u=r.match(Fb);if(!u)return t;for(var l=0;l<u.length;l++){for(var f=u[l],h=f.charAt(0),v=void 0,c=f.match(zb)||[],p=c.length,d=0;d<p;d++)c[d]=parseFloat(c[d]);for(var g=0;g<p;){var y=void 0,m=void 0,_=void 0,S=void 0,b=void 0,w=void 0,x=void 0,C=e,M=i,D=void 0,A=void 0;switch(h){case"l":e+=c[g++],i+=c[g++],v=s.L,t.addData(v,e,i);break;case"L":e=c[g++],i=c[g++],v=s.L,t.addData(v,e,i);break;case"m":e+=c[g++],i+=c[g++],v=s.M,t.addData(v,e,i),n=e,a=i,h="l";break;case"M":e=c[g++],i=c[g++],v=s.M,t.addData(v,e,i),n=e,a=i,h="L";break;case"h":e+=c[g++],v=s.L,t.addData(v,e,i);break;case"H":e=c[g++],v=s.L,t.addData(v,e,i);break;case"v":i+=c[g++],v=s.L,t.addData(v,e,i);break;case"V":i=c[g++],v=s.L,t.addData(v,e,i);break;case"C":v=s.C,t.addData(v,c[g++],c[g++],c[g++],c[g++],c[g++],c[g++]),e=c[g-2],i=c[g-1];break;case"c":v=s.C,t.addData(v,c[g++]+e,c[g++]+i,c[g++]+e,c[g++]+i,c[g++]+e,c[g++]+i),e+=c[g-2],i+=c[g-1];break;case"S":y=e,m=i,D=t.len(),A=t.data,o===s.C&&(y+=e-A[D-4],m+=i-A[D-3]),v=s.C,C=c[g++],M=c[g++],e=c[g++],i=c[g++],t.addData(v,y,m,C,M,e,i);break;case"s":y=e,m=i,D=t.len(),A=t.data,o===s.C&&(y+=e-A[D-4],m+=i-A[D-3]),v=s.C,C=e+c[g++],M=i+c[g++],e+=c[g++],i+=c[g++],t.addData(v,y,m,C,M,e,i);break;case"Q":C=c[g++],M=c[g++],e=c[g++],i=c[g++],v=s.Q,t.addData(v,C,M,e,i);break;case"q":C=c[g++]+e,M=c[g++]+i,e+=c[g++],i+=c[g++],v=s.Q,t.addData(v,C,M,e,i);break;case"T":y=e,m=i,D=t.len(),A=t.data,o===s.Q&&(y+=e-A[D-4],m+=i-A[D-3]),e=c[g++],i=c[g++],v=s.Q,t.addData(v,y,m,e,i);break;case"t":y=e,m=i,D=t.len(),A=t.data,o===s.Q&&(y+=e-A[D-4],m+=i-A[D-3]),e+=c[g++],i+=c[g++],v=s.Q,t.addData(v,y,m,e,i);break;case"A":_=c[g++],S=c[g++],b=c[g++],w=c[g++],x=c[g++],C=e,M=i,e=c[g++],i=c[g++],v=s.A,Gc(C,M,e,i,w,x,_,S,b,v,t);break;case"a":_=c[g++],S=c[g++],b=c[g++],w=c[g++],x=c[g++],C=e,M=i,e+=c[g++],i+=c[g++],v=s.A,Gc(C,M,e,i,w,x,_,S,b,v,t);break}}(h==="z"||h==="Z")&&(v=s.Z,t.addData(v),e=n,i=a),o=v}return t.toStatic(),t}var sm=(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.applyTransform=function(e){},t})(st);function um(r){return r.setData!=null}function lm(r,t){var e=Vb(r),i=k({},t);return i.buildPath=function(n){if(um(n)){n.setData(e.data);var a=n.getContext();a&&n.rebuildPath(a,1)}else{var a=n;e.rebuildPath(a,1)}},i.applyTransform=function(n){Nb(e,n),this.dirtyShape()},i}function Hb(r,t){return new sm(lm(r,t))}function Gb(r,t){var e=lm(r,t),i=(function(n){O(a,n);function a(o){var s=n.call(this,o)||this;return s.applyTransform=e.applyTransform,s.buildPath=e.buildPath,s}return a})(sm);return i}function Wb(r,t){for(var e=[],i=r.length,n=0;n<i;n++){var a=r[n];e.push(a.getUpdatedPathProxy(!0))}var o=new st(t);return o.createPathProxy(),o.buildPath=function(s){if(um(s)){s.appendPath(e);var u=s.getContext();u&&s.rebuildPath(u,1)}},o}var Ub=(function(){function r(){this.cx=0,this.cy=0,this.r=0}return r})(),Fs=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new Ub},t.prototype.buildPath=function(e,i){e.moveTo(i.cx+i.r,i.cy),e.arc(i.cx,i.cy,i.r,0,Math.PI*2)},t})(st);Fs.prototype.type="circle";var Yb=(function(){function r(){this.cx=0,this.cy=0,this.rx=0,this.ry=0}return r})(),Ph=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new Yb},t.prototype.buildPath=function(e,i){var n=.5522848,a=i.cx,o=i.cy,s=i.rx,u=i.ry,l=s*n,f=u*n;e.moveTo(a-s,o),e.bezierCurveTo(a-s,o-f,a-l,o-u,a,o-u),e.bezierCurveTo(a+l,o-u,a+s,o-f,a+s,o),e.bezierCurveTo(a+s,o+f,a+l,o+u,a,o+u),e.bezierCurveTo(a-l,o+u,a-s,o+f,a-s,o),e.closePath()},t})(st);Ph.prototype.type="ellipse";var fm=Math.PI,$u=fm*2,$r=Math.sin,Bi=Math.cos,Zb=Math.acos,Pt=Math.atan2,Wc=Math.abs,va=Math.sqrt,jn=Math.max,Ie=Math.min,Se=1e-4;function Xb(r,t,e,i,n,a,o,s){var u=e-r,l=i-t,f=o-n,h=s-a,v=h*u-f*l;if(!(v*v<Se))return v=(f*(t-a)-h*(r-n))/v,[r+v*u,t+v*l]}function ro(r,t,e,i,n,a,o){var s=r-e,u=t-i,l=(o?a:-a)/va(s*s+u*u),f=l*u,h=-l*s,v=r+f,c=t+h,p=e+f,d=i+h,g=(v+p)/2,y=(c+d)/2,m=p-v,_=d-c,S=m*m+_*_,b=n-a,w=v*d-p*c,x=(_<0?-1:1)*va(jn(0,b*b*S-w*w)),C=(w*_-m*x)/S,M=(-w*m-_*x)/S,D=(w*_+m*x)/S,A=(-w*m+_*x)/S,P=C-g,R=M-y,L=D-g,I=A-y;return P*P+R*R>L*L+I*I&&(C=D,M=A),{cx:C,cy:M,x0:-f,y0:-h,x1:C*(n/b-1),y1:M*(n/b-1)}}function $b(r){var t;if(B(r)){var e=r.length;if(!e)return r;e===1?t=[r[0],r[0],0,0]:e===2?t=[r[0],r[0],r[1],r[1]]:e===3?t=r.concat(r[2]):t=r}else t=[r,r,r,r];return t}function qb(r,t){var e,i=jn(t.r,0),n=jn(t.r0||0,0),a=i>0,o=n>0;if(!(!a&&!o)){if(a||(i=n,n=0),n>i){var s=i;i=n,n=s}var u=t.startAngle,l=t.endAngle;if(!(isNaN(u)||isNaN(l))){var f=t.cx,h=t.cy,v=!!t.clockwise,c=Wc(l-u),p=c>$u&&c%$u;if(p>Se&&(c=p),!(i>Se))r.moveTo(f,h);else if(c>$u-Se)r.moveTo(f+i*Bi(u),h+i*$r(u)),r.arc(f,h,i,u,l,!v),n>Se&&(r.moveTo(f+n*Bi(l),h+n*$r(l)),r.arc(f,h,n,l,u,v));else{var d=void 0,g=void 0,y=void 0,m=void 0,_=void 0,S=void 0,b=void 0,w=void 0,x=void 0,C=void 0,M=void 0,D=void 0,A=void 0,P=void 0,R=void 0,L=void 0,I=i*Bi(u),E=i*$r(u),G=n*Bi(l),V=n*$r(l),F=c>Se;if(F){var J=t.cornerRadius;J&&(e=$b(J),d=e[0],g=e[1],y=e[2],m=e[3]);var ut=Wc(i-n)/2;if(_=Ie(ut,y),S=Ie(ut,m),b=Ie(ut,d),w=Ie(ut,g),M=x=jn(_,S),D=C=jn(b,w),(x>Se||C>Se)&&(A=i*Bi(l),P=i*$r(l),R=n*Bi(u),L=n*$r(u),c<fm)){var lt=Xb(I,E,R,L,A,P,G,V);if(lt){var ct=I-lt[0],pt=E-lt[1],mt=A-lt[0],ye=P-lt[1],Rr=1/$r(Zb((ct*mt+pt*ye)/(va(ct*ct+pt*pt)*va(mt*mt+ye*ye)))/2),Ai=va(lt[0]*lt[0]+lt[1]*lt[1]);M=Ie(x,(i-Ai)/(Rr+1)),D=Ie(C,(n-Ai)/(Rr-1))}}}if(!F)r.moveTo(f+I,h+E);else if(M>Se){var qt=Ie(y,M),Lt=Ie(m,M),K=ro(R,L,I,E,i,qt,v),it=ro(A,P,G,V,i,Lt,v);r.moveTo(f+K.cx+K.x0,h+K.cy+K.y0),M<x&&qt===Lt?r.arc(f+K.cx,h+K.cy,M,Pt(K.y0,K.x0),Pt(it.y0,it.x0),!v):(qt>0&&r.arc(f+K.cx,h+K.cy,qt,Pt(K.y0,K.x0),Pt(K.y1,K.x1),!v),r.arc(f,h,i,Pt(K.cy+K.y1,K.cx+K.x1),Pt(it.cy+it.y1,it.cx+it.x1),!v),Lt>0&&r.arc(f+it.cx,h+it.cy,Lt,Pt(it.y1,it.x1),Pt(it.y0,it.x0),!v))}else r.moveTo(f+I,h+E),r.arc(f,h,i,u,l,!v);if(!(n>Se)||!F)r.lineTo(f+G,h+V);else if(D>Se){var qt=Ie(d,D),Lt=Ie(g,D),K=ro(G,V,A,P,n,-Lt,v),it=ro(I,E,R,L,n,-qt,v);r.lineTo(f+K.cx+K.x0,h+K.cy+K.y0),D<C&&qt===Lt?r.arc(f+K.cx,h+K.cy,D,Pt(K.y0,K.x0),Pt(it.y0,it.x0),!v):(Lt>0&&r.arc(f+K.cx,h+K.cy,Lt,Pt(K.y0,K.x0),Pt(K.y1,K.x1),!v),r.arc(f,h,n,Pt(K.cy+K.y1,K.cx+K.x1),Pt(it.cy+it.y1,it.cx+it.x1),v),qt>0&&r.arc(f+it.cx,h+it.cy,qt,Pt(it.y1,it.x1),Pt(it.y0,it.x0),!v))}else r.lineTo(f+G,h+V),r.arc(f,h,n,l,u,v)}r.closePath()}}}var Kb=(function(){function r(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0,this.cornerRadius=0}return r})(),zs=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new Kb},t.prototype.buildPath=function(e,i){qb(e,i)},t.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},t})(st);zs.prototype.type="sector";var Qb=(function(){function r(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return r})(),Ih=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new Qb},t.prototype.buildPath=function(e,i){var n=i.cx,a=i.cy,o=Math.PI*2;e.moveTo(n+i.r,a),e.arc(n,a,i.r,0,o,!1),e.moveTo(n+i.r0,a),e.arc(n,a,i.r0,0,o,!0)},t})(st);Ih.prototype.type="ring";function Jb(r,t,e,i){var n=[],a=[],o=[],s=[],u,l,f,h;if(i){f=[1/0,1/0],h=[-1/0,-1/0];for(var v=0,c=r.length;v<c;v++)Xi(f,f,r[v]),$i(h,h,r[v]);Xi(f,f,i[0]),$i(h,h,i[1])}for(var v=0,c=r.length;v<c;v++){var p=r[v];if(e)u=r[v?v-1:c-1],l=r[(v+1)%c];else if(v===0||v===c-1){n.push(V1(r[v]));continue}else u=r[v-1],l=r[v+1];sy(a,l,u),fu(a,a,t);var d=Ql(p,u),g=Ql(p,l),y=d+g;y!==0&&(d/=y,g/=y),fu(o,a,-d),fu(s,a,g);var m=Ov([],p,o),_=Ov([],p,s);i&&($i(m,m,f),Xi(m,m,h),$i(_,_,f),Xi(_,_,h)),n.push(m),n.push(_)}return e&&n.push(n.shift()),n}function hm(r,t,e){var i=t.smooth,n=t.points;if(n&&n.length>=2){if(i){var a=Jb(n,i,e,t.smoothConstraint);r.moveTo(n[0][0],n[0][1]);for(var o=n.length,s=0;s<(e?o:o-1);s++){var u=a[s*2],l=a[s*2+1],f=n[(s+1)%o];r.bezierCurveTo(u[0],u[1],l[0],l[1],f[0],f[1])}}else{r.moveTo(n[0][0],n[0][1]);for(var s=1,h=n.length;s<h;s++)r.lineTo(n[s][0],n[s][1])}e&&r.closePath()}}var jb=(function(){function r(){this.points=null,this.smooth=0,this.smoothConstraint=null}return r})(),mi=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultShape=function(){return new jb},t.prototype.buildPath=function(e,i){hm(e,i,!0)},t})(st);mi.prototype.type="polygon";var tx=(function(){function r(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null}return r})(),_n=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new tx},t.prototype.buildPath=function(e,i){hm(e,i,!1)},t})(st);_n.prototype.type="polyline";var ex={},rx=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r})(),er=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new rx},t.prototype.buildPath=function(e,i){var n,a,o,s;if(this.subPixelOptimize){var u=Xy(ex,i,this.style);n=u.x1,a=u.y1,o=u.x2,s=u.y2}else n=i.x1,a=i.y1,o=i.x2,s=i.y2;var l=i.percent;l!==0&&(e.moveTo(n,a),l<1&&(o=n*(1-l)+o*l,s=a*(1-l)+s*l),e.lineTo(o,s))},t.prototype.pointAt=function(e){var i=this.shape;return[i.x1*(1-e)+i.x2*e,i.y1*(1-e)+i.y2*e]},t})(st);er.prototype.type="line";var Vt=[],ix=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1}return r})();function Uc(r,t,e){var i=r.cpx2,n=r.cpy2;return i!=null||n!=null?[(e?Xv:Mt)(r.x1,r.cpx1,r.cpx2,r.x2,t),(e?Xv:Mt)(r.y1,r.cpy1,r.cpy2,r.y2,t)]:[(e?$v:Et)(r.x1,r.cpx1,r.x2,t),(e?$v:Et)(r.y1,r.cpy1,r.y2,t)]}var Vs=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new ix},t.prototype.buildPath=function(e,i){var n=i.x1,a=i.y1,o=i.x2,s=i.y2,u=i.cpx1,l=i.cpy1,f=i.cpx2,h=i.cpy2,v=i.percent;v!==0&&(e.moveTo(n,a),f==null||h==null?(v<1&&(Ko(n,u,o,v,Vt),u=Vt[1],o=Vt[2],Ko(a,l,s,v,Vt),l=Vt[1],s=Vt[2]),e.quadraticCurveTo(u,l,o,s)):(v<1&&(qo(n,u,f,o,v,Vt),u=Vt[1],f=Vt[2],o=Vt[3],qo(a,l,h,s,v,Vt),l=Vt[1],h=Vt[2],s=Vt[3]),e.bezierCurveTo(u,l,f,h,o,s)))},t.prototype.pointAt=function(e){return Uc(this.shape,e,!1)},t.prototype.tangentAt=function(e){var i=Uc(this.shape,e,!0);return dh(i,i)},t})(st);Vs.prototype.type="bezier-curve";var nx=(function(){function r(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return r})(),Hs=(function(r){O(t,r);function t(e){return r.call(this,e)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new nx},t.prototype.buildPath=function(e,i){var n=i.cx,a=i.cy,o=Math.max(i.r,0),s=i.startAngle,u=i.endAngle,l=i.clockwise,f=Math.cos(s),h=Math.sin(s);e.moveTo(f*o+n,h*o+a),e.arc(n,a,o,s,u,!l)},t})(st);Hs.prototype.type="arc";var ax=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="compound",e}return t.prototype._updatePathDirty=function(){for(var e=this.shape.paths,i=this.shapeChanged(),n=0;n<e.length;n++)i=i||e[n].shapeChanged();i&&this.dirtyShape()},t.prototype.beforeBrush=function(){this._updatePathDirty();for(var e=this.shape.paths||[],i=this.getGlobalScale(),n=0;n<e.length;n++)e[n].path||e[n].createPathProxy(),e[n].path.setScale(i[0],i[1],e[n].segmentIgnoreThreshold)},t.prototype.buildPath=function(e,i){for(var n=i.paths||[],a=0;a<n.length;a++)n[a].buildPath(e,n[a].shape,!0)},t.prototype.afterBrush=function(){for(var e=this.shape.paths||[],i=0;i<e.length;i++)e[i].pathUpdated()},t.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),st.prototype.getBoundingRect.call(this)},t})(st),vm=(function(){function r(t){this.colorStops=t||[]}return r.prototype.addColorStop=function(t,e){this.colorStops.push({offset:t,color:e})},r})(),cm=(function(r){O(t,r);function t(e,i,n,a,o,s){var u=r.call(this,o)||this;return u.x=e??0,u.y=i??0,u.x2=n??1,u.y2=a??0,u.type="linear",u.global=s||!1,u}return t})(vm),ox=(function(r){O(t,r);function t(e,i,n,a,o){var s=r.call(this,a)||this;return s.x=e??.5,s.y=i??.5,s.r=n??.5,s.type="radial",s.global=o||!1,s}return t})(vm),qr=[0,0],Kr=[0,0],io=new j,no=new j,is=(function(){function r(t,e){this._corners=[],this._axes=[],this._origin=[0,0];for(var i=0;i<4;i++)this._corners[i]=new j;for(var i=0;i<2;i++)this._axes[i]=new j;t&&this.fromBoundingRect(t,e)}return r.prototype.fromBoundingRect=function(t,e){var i=this._corners,n=this._axes,a=t.x,o=t.y,s=a+t.width,u=o+t.height;if(i[0].set(a,o),i[1].set(s,o),i[2].set(s,u),i[3].set(a,u),e)for(var l=0;l<4;l++)i[l].transform(e);j.sub(n[0],i[1],i[0]),j.sub(n[1],i[3],i[0]),n[0].normalize(),n[1].normalize();for(var l=0;l<2;l++)this._origin[l]=n[l].dot(i[0])},r.prototype.intersect=function(t,e){var i=!0,n=!e;return io.set(1/0,1/0),no.set(0,0),!this._intersectCheckOneSide(this,t,io,no,n,1)&&(i=!1,n)||!this._intersectCheckOneSide(t,this,io,no,n,-1)&&(i=!1,n)||n||j.copy(e,i?io:no),i},r.prototype._intersectCheckOneSide=function(t,e,i,n,a,o){for(var s=!0,u=0;u<2;u++){var l=this._axes[u];if(this._getProjMinMaxOnAxis(u,t._corners,qr),this._getProjMinMaxOnAxis(u,e._corners,Kr),qr[1]<Kr[0]||qr[0]>Kr[1]){if(s=!1,a)return s;var f=Math.abs(Kr[0]-qr[1]),h=Math.abs(qr[0]-Kr[1]);Math.min(f,h)>n.len()&&(f<h?j.scale(n,l,-f*o):j.scale(n,l,h*o))}else if(i){var f=Math.abs(Kr[0]-qr[1]),h=Math.abs(qr[0]-Kr[1]);Math.min(f,h)<i.len()&&(f<h?j.scale(i,l,f*o):j.scale(i,l,-h*o))}}return s},r.prototype._getProjMinMaxOnAxis=function(t,e,i){for(var n=this._axes[t],a=this._origin,o=e[0].dot(n)+a[t],s=o,u=o,l=1;l<e.length;l++){var f=e[l].dot(n)+a[t];s=Math.min(f,s),u=Math.max(f,u)}i[0]=s,i[1]=u},r})(),sx=[],ux=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.notClear=!0,e.incremental=!0,e._displayables=[],e._temporaryDisplayables=[],e._cursor=0,e}return t.prototype.traverse=function(e,i){e.call(i,this)},t.prototype.useStyle=function(){this.style={}},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,i){i?this._temporaryDisplayables.push(e):this._displayables.push(e),this.markRedraw()},t.prototype.addDisplayables=function(e,i){i=i||!1;for(var n=0;n<e.length;n++)this.addDisplayable(e[n],i)},t.prototype.getDisplayables=function(){return this._displayables},t.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},t.prototype.eachPendingDisplayable=function(e){for(var i=this._cursor;i<this._displayables.length;i++)e&&e(this._displayables[i]);for(var i=0;i<this._temporaryDisplayables.length;i++)e&&e(this._temporaryDisplayables[i])},t.prototype.update=function(){this.updateTransform();for(var e=this._cursor;e<this._displayables.length;e++){var i=this._displayables[e];i.parent=this,i.update(),i.parent=null}for(var e=0;e<this._temporaryDisplayables.length;e++){var i=this._temporaryDisplayables[e];i.parent=this,i.update(),i.parent=null}},t.prototype.getBoundingRect=function(){if(!this._rect){for(var e=new et(1/0,1/0,-1/0,-1/0),i=0;i<this._displayables.length;i++){var n=this._displayables[i],a=n.getBoundingRect().clone();n.needLocalTransform()&&a.applyTransform(n.getLocalTransform(sx)),e.union(a)}this._rect=e}return this._rect},t.prototype.contain=function(e,i){var n=this.transformCoordToLocal(e,i),a=this.getBoundingRect();if(a.contain(n[0],n[1]))for(var o=0;o<this._displayables.length;o++){var s=this._displayables[o];if(s.contain(e,i))return!0}return!1},t})(Mi),lx=vt();function Rh(r,t,e,i,n){var a;if(t&&t.ecModel){var o=t.ecModel.getUpdatePayload();a=o&&o.animation}var s=t&&t.isAnimationEnabled(),u=r==="update";if(s){var l=void 0,f=void 0,h=void 0;i?(l=$(i.duration,200),f=$(i.easing,"cubicOut"),h=0):(l=t.getShallow(u?"animationDurationUpdate":"animationDuration"),f=t.getShallow(u?"animationEasingUpdate":"animationEasing"),h=t.getShallow(u?"animationDelayUpdate":"animationDelay")),a&&(a.duration!=null&&(l=a.duration),a.easing!=null&&(f=a.easing),a.delay!=null&&(h=a.delay)),q(h)&&(h=h(e,n)),q(l)&&(l=l(e));var v={duration:l||0,delay:h,easing:f};return v}else return null}function Eh(r,t,e,i,n,a,o){var s=!1,u;q(n)?(o=a,a=n,n=null):W(n)&&(a=n.cb,o=n.during,s=n.isFrom,u=n.removeOpt,n=n.dataIndex);var l=r==="leave";l||t.stopAnimation("leave");var f=Rh(r,i,n,l?u||{}:null,i&&i.getAnimationDelayParams?i.getAnimationDelayParams(t,n):null);if(f&&f.duration>0){var h=f.duration,v=f.delay,c=f.easing,p={duration:h,delay:v||0,easing:c,done:a,force:!!a||!!o,setToFinal:!l,scope:r,during:o};s?t.animateFrom(e,p):t.animateTo(e,p)}else t.stopAnimation(),!s&&t.attr(e),o&&o(1),a&&a()}function pe(r,t,e,i,n,a){Eh("update",r,t,e,i,n,a)}function rr(r,t,e,i,n,a){Eh("enter",r,t,e,i,n,a)}function nn(r){if(!r.__zr)return!0;for(var t=0;t<r.animators.length;t++){var e=r.animators[t];if(e.scope==="leave")return!0}return!1}function ns(r,t,e,i,n,a){nn(r)||Eh("leave",r,t,e,i,n,a)}function Yc(r,t,e,i){r.removeTextContent(),r.removeTextGuideLine(),ns(r,{style:{opacity:0}},t,e,i)}function fx(r,t,e){function i(){r.parent&&r.parent.remove(r)}r.isGroup?r.traverse(function(n){n.isGroup||Yc(n,t,e,i)}):Yc(r,t,e,i)}function hx(r){lx(r).oldStyle=r.style}var as=Math.max,os=Math.min,Mf={};function vx(r){return st.extend(r)}var cx=Gb;function px(r,t){return cx(r,t)}function De(r,t){Mf[r]=t}function pm(r){if(Mf.hasOwnProperty(r))return Mf[r]}function Gs(r,t,e,i){var n=Hb(r,t);return e&&(i==="center"&&(e=gm(e,n.getBoundingRect())),ym(n,e)),n}function dm(r,t,e){var i=new nr({style:{image:r,x:t.x,y:t.y,width:t.width,height:t.height},onload:function(n){if(e==="center"){var a={width:n.width,height:n.height};i.setStyle(gm(t,a))}}});return i}function gm(r,t){var e=t.width/t.height,i=r.height*e,n;i<=r.width?n=r.height:(i=r.width,n=i/e);var a=r.x+r.width/2,o=r.y+r.height/2;return{x:a-i/2,y:o-n/2,width:i,height:n}}var dx=Wb;function ym(r,t){if(r.applyTransform){var e=r.getBoundingRect(),i=e.calculateTransform(t);r.applyTransform(i)}}function Ta(r,t){return Xy(r,r,{lineWidth:t}),r}function gx(r){return $y(r.shape,r.shape,r.style),r}var yx=si;function Ws(r,t){for(var e=yh([]);r&&r!==t;)en(e,r.getLocalTransform(),e),r=r.parent;return e}function Ma(r,t,e){return t&&!zt(t)&&(t=Ps.getLocalTransform(t)),e&&(t=Ls([],t)),ve([],r,t)}function kh(r,t,e){var i=t[4]===0||t[5]===0||t[0]===0?1:Math.abs(2*t[4]/t[0]),n=t[4]===0||t[5]===0||t[2]===0?1:Math.abs(2*t[4]/t[2]),a=[r==="left"?-i:r==="right"?i:0,r==="top"?-n:r==="bottom"?n:0];return a=Ma(a,t,e),Math.abs(a[0])>Math.abs(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"}function Zc(r){return!r.isGroup}function mx(r){return r.shape!=null}function mm(r,t,e){if(!r||!t)return;function i(o){var s={};return o.traverse(function(u){Zc(u)&&u.anid&&(s[u.anid]=u)}),s}function n(o){var s={x:o.x,y:o.y,rotation:o.rotation};return mx(o)&&(s.shape=k({},o.shape)),s}var a=i(r);t.traverse(function(o){if(Zc(o)&&o.anid){var s=a[o.anid];if(s){var u=n(o);o.attr(n(s)),pe(o,u,e,at(o).dataIndex)}}})}function _m(r,t){return z(r,function(e){var i=e[0];i=as(i,t.x),i=os(i,t.x+t.width);var n=e[1];return n=as(n,t.y),n=os(n,t.y+t.height),[i,n]})}function _x(r,t){var e=as(r.x,t.x),i=os(r.x+r.width,t.x+t.width),n=as(r.y,t.y),a=os(r.y+r.height,t.y+t.height);if(i>=e&&a>=n)return{x:e,y:n,width:i-e,height:a-n}}function Sm(r,t,e){var i=k({rectHover:!0},t),n=i.style={strokeNoScale:!0};if(e=e||{x:-1,y:-1,width:2,height:2},r)return r.indexOf("image://")===0?(n.image=r.slice(8),rt(n,e),new nr(i)):Gs(r.replace("path://",""),i,e,"center")}function ta(r,t,e,i,n){for(var a=0,o=n[n.length-1];a<n.length;a++){var s=n[a];if(wm(r,t,e,i,s[0],s[1],o[0],o[1]))return!0;o=s}}function wm(r,t,e,i,n,a,o,s){var u=e-r,l=i-t,f=o-n,h=s-a,v=qu(f,h,u,l);if(Sx(v))return!1;var c=r-n,p=t-a,d=qu(c,p,u,l)/v;if(d<0||d>1)return!1;var g=qu(c,p,f,h)/v;return!(g<0||g>1)}function qu(r,t,e,i){return r*i-e*t}function Sx(r){return r<=1e-6&&r>=-1e-6}function Oh(r){var t=r.itemTooltipOption,e=r.componentModel,i=r.itemName,n=H(t)?{formatter:t}:t,a=e.mainType,o=e.componentIndex,s={componentType:a,name:i,$vars:["name"]};s[a+"Index"]=o;var u=r.formatterParamsExtra;u&&T(ft(u),function(f){N(s,f)||(s[f]=u[f],s.$vars.push(f))});var l=at(r.el);l.componentMainType=a,l.componentIndex=o,l.tooltipConfig={name:i,option:rt({content:i,encodeHTMLContent:!0,formatterParams:s},n)}}function Xc(r,t){var e;r.isGroup&&(e=t(r)),e||r.traverse(t)}function Va(r,t){if(r)if(B(r))for(var e=0;e<r.length;e++)Xc(r[e],t);else Xc(r,t)}De("circle",Fs);De("ellipse",Ph);De("sector",zs);De("ring",Ih);De("polygon",mi);De("polyline",_n);De("rect",Tt);De("line",er);De("bezierCurve",Vs);De("arc",Hs);const bx=Object.freeze(Object.defineProperty({__proto__:null,Arc:Hs,BezierCurve:Vs,BoundingRect:et,Circle:Fs,CompoundPath:ax,Ellipse:Ph,Group:gt,Image:nr,IncrementalDisplayable:ux,Line:er,LinearGradient:cm,OrientedBoundingRect:is,Path:st,Point:j,Polygon:mi,Polyline:_n,RadialGradient:ox,Rect:Tt,Ring:Ih,Sector:zs,Text:te,applyTransform:Ma,clipPointsByRect:_m,clipRectByRect:_x,createIcon:Sm,extendPath:px,extendShape:vx,getShapeClass:pm,getTransform:Ws,groupTransition:mm,initProps:rr,isElementRemoved:nn,lineLineIntersect:wm,linePolygonIntersect:ta,makeImage:dm,makePath:Gs,mergePath:dx,registerShape:De,removeElement:ns,removeElementWithFadeOut:fx,resizePath:ym,setTooltipConfig:Oh,subPixelOptimize:yx,subPixelOptimizeLine:Ta,subPixelOptimizeRect:gx,transformDirection:kh,traverseElements:Va,updateProps:pe},Symbol.toStringTag,{value:"Module"}));var Us={};function bm(r,t){for(var e=0;e<Zt.length;e++){var i=Zt[e],n=t[i],a=r.ensureState(i);a.style=a.style||{},a.style.text=n}var o=r.currentStates.slice();r.clearStates(!0),r.setStyle({text:t.normal}),r.useStates(o,!0)}function Cf(r,t,e){var i=r.labelFetcher,n=r.labelDataIndex,a=r.labelDimIndex,o=t.normal,s;i&&(s=i.getFormattedLabel(n,"normal",null,a,o&&o.get("formatter"),e!=null?{interpolatedValue:e}:null)),s==null&&(s=q(r.defaultText)?r.defaultText(n,r,e):r.defaultText);for(var u={normal:s},l=0;l<Zt.length;l++){var f=Zt[l],h=t[f];u[f]=$(i?i.getFormattedLabel(n,f,null,a,h&&h.get("formatter")):null,s)}return u}function Ys(r,t,e,i){e=e||Us;for(var n=r instanceof te,a=!1,o=0;o<rs.length;o++){var s=t[rs[o]];if(s&&s.getShallow("show")){a=!0;break}}var u=n?r:r.getTextContent();if(a){n||(u||(u=new te,r.setTextContent(u)),r.stateProxy&&(u.stateProxy=r.stateProxy));var l=Cf(e,t),f=t.normal,h=!!f.getShallow("show"),v=Lr(f,i&&i.normal,e,!1,!n);v.text=l.normal,n||r.setTextConfig(ss(f,e,!1));for(var o=0;o<Zt.length;o++){var c=Zt[o],s=t[c];if(s){var p=u.ensureState(c),d=!!$(s.getShallow("show"),h);if(d!==h&&(p.ignore=!d),p.style=Lr(s,i&&i[c],e,!0,!n),p.style.text=l[c],!n){var g=r.ensureState(c);g.textConfig=ss(s,e,!0)}}}u.silent=!!f.getShallow("silent"),u.style.x!=null&&(v.x=u.style.x),u.style.y!=null&&(v.y=u.style.y),u.ignore=!h,u.useStyle(v),u.dirty(),e.enableTextSetter&&(Zs(u).setLabelText=function(y){var m=Cf(e,t,y);bm(u,m)})}else u&&(u.ignore=!0);r.dirty()}function Sn(r,t){t=t||"label";for(var e={normal:r.getModel(t)},i=0;i<Zt.length;i++){var n=Zt[i];e[n]=r.getModel([n,t])}return e}function Lr(r,t,e,i,n){var a={};return xx(a,r,e,i,n),t&&k(a,t),a}function ss(r,t,e){t=t||{};var i={},n,a=r.getShallow("rotate"),o=$(r.getShallow("distance"),e?null:5),s=r.getShallow("offset");return n=r.getShallow("position")||(e?null:"inside"),n==="outside"&&(n=t.defaultOutsidePosition||"top"),n!=null&&(i.position=n),s!=null&&(i.offset=s),a!=null&&(a*=Math.PI/180,i.rotation=a),o!=null&&(i.distance=o),i.outsideFill=r.get("color")==="inherit"?t.inheritColor||null:"auto",i}function xx(r,t,e,i,n){e=e||Us;var a=t.ecModel,o=a&&a.option.textStyle,s=Tx(t),u;if(s){u={};for(var l in s)if(s.hasOwnProperty(l)){var f=t.getModel(["rich",l]);Qc(u[l]={},f,o,e,i,n,!1,!0)}}u&&(r.rich=u);var h=t.get("overflow");h&&(r.overflow=h);var v=t.get("minMargin");v!=null&&(r.margin=v),Qc(r,t,o,e,i,n,!0,!1)}function Tx(r){for(var t;r&&r!==r.ecModel;){var e=(r.option||Us).rich;if(e){t=t||{};for(var i=ft(e),n=0;n<i.length;n++){var a=i[n];t[a]=1}}r=r.parentModel}return t}var $c=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],qc=["align","lineHeight","width","height","tag","verticalAlign","ellipsis"],Kc=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function Qc(r,t,e,i,n,a,o,s){e=!n&&e||Us;var u=i&&i.inheritColor,l=t.getShallow("color"),f=t.getShallow("textBorderColor"),h=$(t.getShallow("opacity"),e.opacity);(l==="inherit"||l==="auto")&&(u?l=u:l=null),(f==="inherit"||f==="auto")&&(u?f=u:f=null),a||(l=l||e.color,f=f||e.textBorderColor),l!=null&&(r.fill=l),f!=null&&(r.stroke=f);var v=$(t.getShallow("textBorderWidth"),e.textBorderWidth);v!=null&&(r.lineWidth=v);var c=$(t.getShallow("textBorderType"),e.textBorderType);c!=null&&(r.lineDash=c);var p=$(t.getShallow("textBorderDashOffset"),e.textBorderDashOffset);p!=null&&(r.lineDashOffset=p),!n&&h==null&&!s&&(h=i&&i.defaultOpacity),h!=null&&(r.opacity=h),!n&&!a&&r.fill==null&&i.inheritColor&&(r.fill=i.inheritColor);for(var d=0;d<$c.length;d++){var g=$c[d],y=$(t.getShallow(g),e[g]);y!=null&&(r[g]=y)}for(var d=0;d<qc.length;d++){var g=qc[d],y=t.getShallow(g);y!=null&&(r[g]=y)}if(r.verticalAlign==null){var m=t.getShallow("baseline");m!=null&&(r.verticalAlign=m)}if(!o||!i.disableBox){for(var d=0;d<Kc.length;d++){var g=Kc[d],y=t.getShallow(g);y!=null&&(r[g]=y)}var _=t.getShallow("borderType");_!=null&&(r.borderDash=_),(r.backgroundColor==="auto"||r.backgroundColor==="inherit")&&u&&(r.backgroundColor=u),(r.borderColor==="auto"||r.borderColor==="inherit")&&u&&(r.borderColor=u)}}function xm(r,t){var e=t&&t.getModel("textStyle");return Oe([r.fontStyle||e&&e.getShallow("fontStyle")||"",r.fontWeight||e&&e.getShallow("fontWeight")||"",(r.fontSize||e&&e.getShallow("fontSize")||12)+"px",r.fontFamily||e&&e.getShallow("fontFamily")||"sans-serif"].join(" "))}var Zs=vt();function Mx(r,t,e,i,n){var a=Zs(r);if(!a.valueAnimation||a.prevValue===a.value)return;var o=a.defaultInterpolatedText,s=$(a.interpolatedValue,a.prevValue),u=a.value;function l(f){var h=Fy(e,a.precision,s,u,f);a.interpolatedValue=f===1?null:h;var v=Cf({labelDataIndex:t,labelFetcher:n,defaultText:o?o(h):h+""},a.statesModels,h);bm(r,v)}r.percent=0,(a.prevValue==null?rr:pe)(r,{percent:1},i,t,null,l)}var Cx=["textStyle","color"],Ku=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],Qu=new te,Dx=(function(){function r(){}return r.prototype.getTextColor=function(t){var e=this.ecModel;return this.getShallow("color")||(!t&&e?e.get(Cx):null)},r.prototype.getFont=function(){return xm({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},r.prototype.getTextRect=function(t){for(var e={text:t,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},i=0;i<Ku.length;i++)e[Ku[i]]=this.getShallow(Ku[i]);return Qu.useStyle(e),Qu.update(),Qu.getBoundingRect()},r})(),Tm=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],Ax=wa(Tm),Lx=(function(){function r(){}return r.prototype.getLineStyle=function(t){return Ax(this,t)},r})(),Mm=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],Px=wa(Mm),Ix=(function(){function r(){}return r.prototype.getItemStyle=function(t,e){return Px(this,t,e)},r})(),St=(function(){function r(t,e,i){this.parentModel=e,this.ecModel=i,this.option=t}return r.prototype.init=function(t,e,i){},r.prototype.mergeOption=function(t,e){tt(this.option,t,!0)},r.prototype.get=function(t,e){return t==null?this.option:this._doGet(this.parsePath(t),!e&&this.parentModel)},r.prototype.getShallow=function(t,e){var i=this.option,n=i==null?i:i[t];if(n==null&&!e){var a=this.parentModel;a&&(n=a.getShallow(t))}return n},r.prototype.getModel=function(t,e){var i=t!=null,n=i?this.parsePath(t):null,a=i?this._doGet(n):this.option;return e=e||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(n)),new r(a,e,this.ecModel)},r.prototype.isEmpty=function(){return this.option==null},r.prototype.restoreData=function(){},r.prototype.clone=function(){var t=this.constructor;return new t(Y(this.option))},r.prototype.parsePath=function(t){return typeof t=="string"?t.split("."):t},r.prototype.resolveParentPath=function(t){return t},r.prototype.isAnimationEnabled=function(){if(!Z.node&&this.option){if(this.option.animation!=null)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},r.prototype._doGet=function(t,e){var i=this.option;if(!t)return i;for(var n=0;n<t.length&&!(t[n]&&(i=i&&typeof i=="object"?i[t[n]]:null,i==null));n++);return i==null&&e&&(i=e._doGet(this.resolveParentPath(t),e.parentModel)),i},r})();Th(St);xw(St);Ce(St,Lx);Ce(St,Ix);Ce(St,Aw);Ce(St,Dx);var Rx=Math.round(Math.random()*10);function Xs(r){return[r||"",Rx++].join("_")}function Ex(r){var t={};r.registerSubTypeDefaulter=function(e,i){var n=Ne(e);t[n.main]=i},r.determineSubType=function(e,i){var n=i.type;if(!n){var a=Ne(e).main;r.hasSubTypes(e)&&t[a]&&(n=t[a](i))}return n}}function kx(r,t){r.topologicalTravel=function(a,o,s,u){if(!a.length)return;var l=e(o),f=l.graph,h=l.noEntryList,v={};for(T(a,function(m){v[m]=!0});h.length;){var c=h.pop(),p=f[c],d=!!v[c];d&&(s.call(u,c,p.originalDeps.slice()),delete v[c]),T(p.successor,d?y:g)}T(v,function(){var m="";throw new Error(m)});function g(m){f[m].entryCount--,f[m].entryCount===0&&h.push(m)}function y(m){v[m]=!0,g(m)}};function e(a){var o={},s=[];return T(a,function(u){var l=i(o,u),f=l.originalDeps=t(u),h=n(f,a);l.entryCount=h.length,l.entryCount===0&&s.push(u),T(h,function(v){Q(l.predecessor,v)<0&&l.predecessor.push(v);var c=i(o,v);Q(c.successor,v)<0&&c.successor.push(u)})}),{graph:o,noEntryList:s}}function i(a,o){return a[o]||(a[o]={predecessor:[],successor:[]}),a[o]}function n(a,o){var s=[];return T(a,function(u){Q(o,u)>=0&&s.push(u)}),s}}function Cm(r,t){return tt(tt({},r,!0),t,!0)}const Ox={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:". "}}}},Bx={time:{month:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"],monthAbbr:["1月","2月","3月","4月","5月","6月","7月","8月","9月","10月","11月","12月"],dayOfWeek:["星期日","星期一","星期二","星期三","星期四","星期五","星期六"],dayOfWeekAbbr:["日","一","二","三","四","五","六"]},legend:{selector:{all:"全选",inverse:"反选"}},toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图",custom:"自定义图表",chart:"图表"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}};var us="ZH",Bh="EN",an=Bh,Vo={},Nh={},Dm=Z.domSupported?(function(){var r=(document.documentElement.lang||navigator.language||navigator.browserLanguage||an).toUpperCase();return r.indexOf(us)>-1?us:an})():an;function Am(r,t){r=r.toUpperCase(),Nh[r]=new St(t),Vo[r]=t}function Nx(r){if(H(r)){var t=Vo[r.toUpperCase()]||{};return r===us||r===Bh?Y(t):tt(Y(t),Y(Vo[an]),!1)}else return tt(Y(r),Y(Vo[an]),!1)}function Fx(r){return Nh[r]}function zx(){return Nh[an]}Am(Bh,Ox);Am(us,Bx);var Fh=1e3,zh=Fh*60,ca=zh*60,he=ca*24,Jc=he*365,ea={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}",none:"{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}"},ao="{yyyy}-{MM}-{dd}",jc={year:"{yyyy}",month:"{yyyy}-{MM}",day:ao,hour:ao+" "+ea.hour,minute:ao+" "+ea.minute,second:ao+" "+ea.second,millisecond:ea.none},Ju=["year","month","day","hour","minute","second","millisecond"],Lm=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function lr(r,t){return r+="","0000".substr(0,t-r.length)+r}function on(r){switch(r){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return r}}function Vx(r){return r===on(r)}function Hx(r){switch(r){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function $s(r,t,e,i){var n=tr(r),a=n[Vh(e)](),o=n[sn(e)]()+1,s=Math.floor((o-1)/3)+1,u=n[qs(e)](),l=n["get"+(e?"UTC":"")+"Day"](),f=n[Ca(e)](),h=(f-1)%12+1,v=n[Ks(e)](),c=n[Qs(e)](),p=n[Js(e)](),d=f>=12?"pm":"am",g=d.toUpperCase(),y=i instanceof St?i:Fx(i||Dm)||zx(),m=y.getModel("time"),_=m.get("month"),S=m.get("monthAbbr"),b=m.get("dayOfWeek"),w=m.get("dayOfWeekAbbr");return(t||"").replace(/{a}/g,d+"").replace(/{A}/g,g+"").replace(/{yyyy}/g,a+"").replace(/{yy}/g,lr(a%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,_[o-1]).replace(/{MMM}/g,S[o-1]).replace(/{MM}/g,lr(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,lr(u,2)).replace(/{d}/g,u+"").replace(/{eeee}/g,b[l]).replace(/{ee}/g,w[l]).replace(/{e}/g,l+"").replace(/{HH}/g,lr(f,2)).replace(/{H}/g,f+"").replace(/{hh}/g,lr(h+"",2)).replace(/{h}/g,h+"").replace(/{mm}/g,lr(v,2)).replace(/{m}/g,v+"").replace(/{ss}/g,lr(c,2)).replace(/{s}/g,c+"").replace(/{SSS}/g,lr(p,3)).replace(/{S}/g,p+"")}function Gx(r,t,e,i,n){var a=null;if(H(e))a=e;else if(q(e))a=e(r.value,t,{level:r.level});else{var o=k({},ea);if(r.level>0)for(var s=0;s<Ju.length;++s)o[Ju[s]]="{primary|"+o[Ju[s]]+"}";var u=e?e.inherit===!1?e:rt(e,o):o,l=Pm(r.value,n);if(u[l])a=u[l];else if(u.inherit){for(var f=Lm.indexOf(l),s=f-1;s>=0;--s)if(u[l]){a=u[l];break}a=a||o.none}if(B(a)){var h=r.level==null?0:r.level>=0?r.level:a.length+r.level;h=Math.min(h,a.length-1),a=a[h]}}return $s(new Date(r.value),a,n,i)}function Pm(r,t){var e=tr(r),i=e[sn(t)]()+1,n=e[qs(t)](),a=e[Ca(t)](),o=e[Ks(t)](),s=e[Qs(t)](),u=e[Js(t)](),l=u===0,f=l&&s===0,h=f&&o===0,v=h&&a===0,c=v&&n===1,p=c&&i===1;return p?"year":c?"month":v?"day":h?"hour":f?"minute":l?"second":"millisecond"}function tp(r,t,e){var i=dt(r)?tr(r):r;switch(t=t||Pm(r,e),t){case"year":return i[Vh(e)]();case"half-year":return i[sn(e)]()>=6?1:0;case"quarter":return Math.floor((i[sn(e)]()+1)/4);case"month":return i[sn(e)]();case"day":return i[qs(e)]();case"half-day":return i[Ca(e)]()/24;case"hour":return i[Ca(e)]();case"minute":return i[Ks(e)]();case"second":return i[Qs(e)]();case"millisecond":return i[Js(e)]()}}function Vh(r){return r?"getUTCFullYear":"getFullYear"}function sn(r){return r?"getUTCMonth":"getMonth"}function qs(r){return r?"getUTCDate":"getDate"}function Ca(r){return r?"getUTCHours":"getHours"}function Ks(r){return r?"getUTCMinutes":"getMinutes"}function Qs(r){return r?"getUTCSeconds":"getSeconds"}function Js(r){return r?"getUTCMilliseconds":"getMilliseconds"}function Wx(r){return r?"setUTCFullYear":"setFullYear"}function Im(r){return r?"setUTCMonth":"setMonth"}function Rm(r){return r?"setUTCDate":"setDate"}function Em(r){return r?"setUTCHours":"setHours"}function km(r){return r?"setUTCMinutes":"setMinutes"}function Om(r){return r?"setUTCSeconds":"setSeconds"}function Bm(r){return r?"setUTCMilliseconds":"setMilliseconds"}function Nm(r){if(!rw(r))return H(r)?r:"-";var t=(r+"").split(".");return t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t.length>1?"."+t[1]:"")}function Fm(r,t){return r=(r||"").toLowerCase().replace(/-(.)/g,function(e,i){return i.toUpperCase()}),t&&r&&(r=r.charAt(0).toUpperCase()+r.slice(1)),r}var Hh=iy;function Df(r,t,e){var i="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function n(f){return f&&Oe(f)?f:"-"}function a(f){return!!(f!=null&&!isNaN(f)&&isFinite(f))}var o=t==="time",s=r instanceof Date;if(o||s){var u=o?tr(r):r;if(isNaN(+u)){if(s)return"-"}else return $s(u,i,e)}if(t==="ordinal")return ql(r)?n(r):dt(r)&&a(r)?r+"":"-";var l=ts(r);return a(l)?Nm(l):ql(r)?n(r):typeof r=="boolean"?r+"":"-"}var ep=["a","b","c","d","e","f","g"],ju=function(r,t){return"{"+r+(t??"")+"}"};function zm(r,t,e){B(t)||(t=[t]);var i=t.length;if(!i)return"";for(var n=t[0].$vars||[],a=0;a<n.length;a++){var o=ep[a];r=r.replace(ju(o),ju(o,0))}for(var s=0;s<i;s++)for(var u=0;u<n.length;u++){var l=t[s][n[u]];r=r.replace(ju(ep[u],s),e?Gt(l):l)}return r}function Ux(r,t){var e=H(r)?{color:r,extraCssText:t}:r||{},i=e.color,n=e.type;t=e.extraCssText;var a=e.renderMode||"html";if(!i)return"";if(a==="html")return n==="subItem"?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+Gt(i)+";"+(t||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+Gt(i)+";"+(t||"")+'"></span>';var o=e.markerId||"markerX";return{renderMode:a,content:"{"+o+"|} ",style:n==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:i}:{width:10,height:10,borderRadius:5,backgroundColor:i}}}function _i(r,t){return t=t||"transparent",H(r)?r:W(r)&&r.colorStops&&(r.colorStops[0]||{}).color||t}var Ho=T,Yx=["left","right","top","bottom","width","height"],oo=[["width","left","right"],["height","top","bottom"]];function Vm(r,t,e,i,n){var a=0,o=0;i==null&&(i=1/0),n==null&&(n=1/0);var s=0;t.eachChild(function(u,l){var f=u.getBoundingRect(),h=t.childAt(l+1),v=h&&h.getBoundingRect(),c,p;if(r==="horizontal"){var d=f.width+(v?-v.x+f.x:0);c=a+d,c>i||u.newline?(a=0,c=d,o+=s+e,s=f.height):s=Math.max(s,f.height)}else{var g=f.height+(v?-v.y+f.y:0);p=o+g,p>n||u.newline?(a+=s+e,o=0,p=g,s=f.width):s=Math.max(s,f.width)}u.newline||(u.x=a,u.y=o,u.markRedraw(),r==="horizontal"?a=c+e:o=p+e)})}ot(Vm,"vertical");ot(Vm,"horizontal");function Gh(r,t,e){e=Hh(e||0);var i=t.width,n=t.height,a=yt(r.left,i),o=yt(r.top,n),s=yt(r.right,i),u=yt(r.bottom,n),l=yt(r.width,i),f=yt(r.height,n),h=e[2]+e[0],v=e[1]+e[3],c=r.aspect;switch(isNaN(l)&&(l=i-s-v-a),isNaN(f)&&(f=n-u-h-o),c!=null&&(isNaN(l)&&isNaN(f)&&(c>i/n?l=i*.8:f=n*.8),isNaN(l)&&(l=c*f),isNaN(f)&&(f=l/c)),isNaN(a)&&(a=i-s-l-v),isNaN(o)&&(o=n-u-f-h),r.left||r.right){case"center":a=i/2-l/2-e[3];break;case"right":a=i-l-v;break}switch(r.top||r.bottom){case"middle":case"center":o=n/2-f/2-e[0];break;case"bottom":o=n-f-h;break}a=a||0,o=o||0,isNaN(l)&&(l=i-v-a-(s||0)),isNaN(f)&&(f=n-h-o-(u||0));var p=new et(a+e[3],o+e[0],l,f);return p.margin=e,p}function Da(r){var t=r.layoutMode||r.constructor.layoutMode;return W(t)?t:t?{type:t}:null}function Aa(r,t,e){var i=e&&e.ignoreSize;!B(i)&&(i=[i,i]);var n=o(oo[0],0),a=o(oo[1],1);l(oo[0],r,n),l(oo[1],r,a);function o(f,h){var v={},c=0,p={},d=0,g=2;if(Ho(f,function(_){p[_]=r[_]}),Ho(f,function(_){s(t,_)&&(v[_]=p[_]=t[_]),u(v,_)&&c++,u(p,_)&&d++}),i[h])return u(t,f[1])?p[f[2]]=null:u(t,f[2])&&(p[f[1]]=null),p;if(d===g||!c)return p;if(c>=g)return v;for(var y=0;y<f.length;y++){var m=f[y];if(!s(v,m)&&s(r,m)){v[m]=r[m];break}}return v}function s(f,h){return f.hasOwnProperty(h)}function u(f,h){return f[h]!=null&&f[h]!=="auto"}function l(f,h,v){Ho(f,function(c){h[c]=v[c]})}}function js(r){return Zx({},r)}function Zx(r,t){return t&&r&&Ho(Yx,function(e){t.hasOwnProperty(e)&&(r[e]=t[e])}),r}var Xx=vt(),nt=(function(r){O(t,r);function t(e,i,n){var a=r.call(this,e,i,n)||this;return a.uid=Xs("ec_cpt_model"),a}return t.prototype.init=function(e,i,n){this.mergeDefaultAndTheme(e,n)},t.prototype.mergeDefaultAndTheme=function(e,i){var n=Da(this),a=n?js(e):{},o=i.getTheme();tt(e,o.get(this.mainType)),tt(e,this.getDefaultOption()),n&&Aa(e,a,n)},t.prototype.mergeOption=function(e,i){tt(this.option,e,!0);var n=Da(this);n&&Aa(this.option,e,n)},t.prototype.optionUpdated=function(e,i){},t.prototype.getDefaultOption=function(){var e=this.constructor;if(!Sw(e))return e.defaultOption;var i=Xx(this);if(!i.defaultOption){for(var n=[],a=e;a;){var o=a.prototype.defaultOption;o&&n.push(o),a=a.superClass}for(var s={},u=n.length-1;u>=0;u--)s=tt(s,n[u],!0);i.defaultOption=s}return i.defaultOption},t.prototype.getReferringComponents=function(e,i){var n=e+"Index",a=e+"Id";return za(this.ecModel,e,{index:this.get(n,!0),id:this.get(a,!0)},i)},t.prototype.getBoxLayoutParams=function(){var e=this;return{left:e.get("left"),top:e.get("top"),right:e.get("right"),bottom:e.get("bottom"),width:e.get("width"),height:e.get("height")}},t.prototype.getZLevelKey=function(){return""},t.prototype.setZLevel=function(e){this.option.zlevel=e},t.protoInitialize=(function(){var e=t.prototype;e.type="component",e.id="",e.name="",e.mainType="",e.subType="",e.componentIndex=0})(),t})(St);Vy(nt,St);Rs(nt);Ex(nt);kx(nt,$x);function $x(r){var t=[];return T(nt.getClassesByMainType(r),function(e){t=t.concat(e.dependencies||e.prototype.dependencies||[])}),t=z(t,function(e){return Ne(e).main}),r!=="dataset"&&Q(t,"dataset")<=0&&t.unshift("dataset"),t}var Hm="";typeof navigator<"u"&&(Hm=navigator.platform||"");var Ni="rgba(0, 0, 0, 0.2)";const qx={darkMode:"auto",colorBy:"series",color:["#5470c6","#91cc75","#fac858","#ee6666","#73c0de","#3ba272","#fc8452","#9a60b4","#ea7ccc"],gradientColor:["#f6efa6","#d88273","#bf444c"],aria:{decal:{decals:[{color:Ni,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:Ni,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:Ni,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:Ni,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:Ni,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:Ni,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:Hm.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,stateAnimation:{duration:300,easing:"cubicOut"},animation:"auto",animationDuration:1e3,animationDurationUpdate:500,animationEasing:"cubicInOut",animationEasingUpdate:"cubicInOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1};var Gm=X(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),ge="original",Xt="arrayRows",Ge="objectRows",or="keyedColumns",Mr="typedArray",Wm="unknown",Qe="column",wn="row",Kt={Must:1,Might:2,Not:3},Um=vt();function Kx(r){Um(r).datasetMap=X()}function Qx(r,t,e){var i={},n=Ym(t);if(!n||!r)return i;var a=[],o=[],s=t.ecModel,u=Um(s).datasetMap,l=n.uid+"_"+e.seriesLayoutBy,f,h;r=r.slice(),T(r,function(d,g){var y=W(d)?d:r[g]={name:d};y.type==="ordinal"&&f==null&&(f=g,h=p(y)),i[y.name]=[]});var v=u.get(l)||u.set(l,{categoryWayDim:h,valueWayDim:0});T(r,function(d,g){var y=d.name,m=p(d);if(f==null){var _=v.valueWayDim;c(i[y],_,m),c(o,_,m),v.valueWayDim+=m}else if(f===g)c(i[y],0,m),c(a,0,m);else{var _=v.categoryWayDim;c(i[y],_,m),c(o,_,m),v.categoryWayDim+=m}});function c(d,g,y){for(var m=0;m<y;m++)d.push(g+m)}function p(d){var g=d.dimsDef;return g?g.length:1}return a.length&&(i.itemName=a),o.length&&(i.seriesName=o),i}function Ym(r){var t=r.get("data",!0);if(!t)return za(r.ecModel,"dataset",{index:r.get("datasetIndex",!0),id:r.get("datasetId",!0)},Ut).models[0]}function Jx(r){return!r.get("transform",!0)&&!r.get("fromTransformResult",!0)?[]:za(r.ecModel,"dataset",{index:r.get("fromDatasetIndex",!0),id:r.get("fromDatasetId",!0)},Ut).models}function Zm(r,t){return jx(r.data,r.sourceFormat,r.seriesLayoutBy,r.dimensionsDefine,r.startIndex,t)}function jx(r,t,e,i,n,a){var o,s=5;if(Yt(r))return Kt.Not;var u,l;if(i){var f=i[a];W(f)?(u=f.name,l=f.type):H(f)&&(u=f)}if(l!=null)return l==="ordinal"?Kt.Must:Kt.Not;if(t===Xt){var h=r;if(e===wn){for(var v=h[a],c=0;c<(v||[]).length&&c<s;c++)if((o=S(v[n+c]))!=null)return o}else for(var c=0;c<h.length&&c<s;c++){var p=h[n+c];if(p&&(o=S(p[a]))!=null)return o}}else if(t===Ge){var d=r;if(!u)return Kt.Not;for(var c=0;c<d.length&&c<s;c++){var g=d[c];if(g&&(o=S(g[u]))!=null)return o}}else if(t===or){var y=r;if(!u)return Kt.Not;var v=y[u];if(!v||Yt(v))return Kt.Not;for(var c=0;c<v.length&&c<s;c++)if((o=S(v[c]))!=null)return o}else if(t===ge)for(var m=r,c=0;c<m.length&&c<s;c++){var g=m[c],_=Fa(g);if(!B(_))return Kt.Not;if((o=S(_[a]))!=null)return o}function S(b){var w=H(b);if(b!=null&&Number.isFinite(Number(b))&&b!=="")return w?Kt.Might:Kt.Not;if(w&&b!=="-")return Kt.Must}return Kt.Not}var tT=X();function eT(r,t,e){var i=tT.get(t);if(!i)return e;var n=i(r);return n?e.concat(n):e}var rp=vt();vt();var Wh=(function(){function r(){}return r.prototype.getColorFromPalette=function(t,e,i){var n=Ct(this.get("color",!0)),a=this.get("colorLayer",!0);return iT(this,rp,n,a,t,e,i)},r.prototype.clearColorPalette=function(){nT(this,rp)},r})();function rT(r,t){for(var e=r.length,i=0;i<e;i++)if(r[i].length>t)return r[i];return r[e-1]}function iT(r,t,e,i,n,a,o){a=a||r;var s=t(a),u=s.paletteIdx||0,l=s.paletteNameMap=s.paletteNameMap||{};if(l.hasOwnProperty(n))return l[n];var f=o==null||!i?e:rT(i,o);if(f=f||e,!(!f||!f.length)){var h=f[u];return n&&(l[n]=h),s.paletteIdx=(u+1)%f.length,h}}function nT(r,t){t(r).paletteIdx=0,t(r).paletteNameMap={}}var so,Rn,ip,np="\0_ec_inner",aT=1,Uh=(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.init=function(e,i,n,a,o,s){a=a||{},this.option=null,this._theme=new St(a),this._locale=new St(o),this._optionManager=s},t.prototype.setOption=function(e,i,n){var a=sp(i);this._optionManager.setOption(e,n,a),this._resetOption(null,a)},t.prototype.resetOption=function(e,i){return this._resetOption(e,sp(i))},t.prototype._resetOption=function(e,i){var n=!1,a=this._optionManager;if(!e||e==="recreate"){var o=a.mountOption(e==="recreate");!this.option||e==="recreate"?ip(this,o):(this.restoreData(),this._mergeOption(o,i)),n=!0}if((e==="timeline"||e==="media")&&this.restoreData(),!e||e==="recreate"||e==="timeline"){var s=a.getTimelineOption(this);s&&(n=!0,this._mergeOption(s,i))}if(!e||e==="recreate"||e==="media"){var u=a.getMediaOption(this);u.length&&T(u,function(l){n=!0,this._mergeOption(l,i)},this)}return n},t.prototype.mergeOption=function(e){this._mergeOption(e,null)},t.prototype._mergeOption=function(e,i){var n=this.option,a=this._componentsMap,o=this._componentsCount,s=[],u=X(),l=i&&i.replaceMergeMainTypeMap;Kx(this),T(e,function(h,v){h!=null&&(nt.hasClass(v)?v&&(s.push(v),u.set(v,!0)):n[v]=n[v]==null?Y(h):tt(n[v],h,!0))}),l&&l.each(function(h,v){nt.hasClass(v)&&!u.get(v)&&(s.push(v),u.set(v,!0))}),nt.topologicalTravel(s,nt.getAllClassMainTypes(),f,this);function f(h){var v=eT(this,h,Ct(e[h])),c=a.get(h),p=c?l&&l.get(h)?"replaceMerge":"normalMerge":"replaceAll",d=aw(c,v,p);vw(d,h,nt),n[h]=null,a.set(h,null),o.set(h,0);var g=[],y=[],m=0,_;T(d,function(S,b){var w=S.existing,x=S.newOption;if(!x)w&&(w.mergeOption({},this),w.optionUpdated({},!1));else{var C=h==="series",M=nt.getClass(h,S.keyInfo.subType,!C);if(!M)return;if(h==="tooltip"){if(_)return;_=!0}if(w&&w.constructor===M)w.name=S.keyInfo.name,w.mergeOption(x,this),w.optionUpdated(x,!1);else{var D=k({componentIndex:b},S.keyInfo);w=new M(x,this,this,D),k(w,D),S.brandNew&&(w.__requireNewView=!0),w.init(x,this,this),w.optionUpdated(null,!0)}}w?(g.push(w.option),y.push(w),m++):(g.push(void 0),y.push(void 0))},this),n[h]=g,a.set(h,y),o.set(h,m),h==="series"&&so(this)}this._seriesIndices||so(this)},t.prototype.getOption=function(){var e=Y(this.option);return T(e,function(i,n){if(nt.hasClass(n)){for(var a=Ct(i),o=a.length,s=!1,u=o-1;u>=0;u--)a[u]&&!Sa(a[u])?s=!0:(a[u]=null,!s&&o--);a.length=o,e[n]=a}}),delete e[np],e},t.prototype.getTheme=function(){return this._theme},t.prototype.getLocaleModel=function(){return this._locale},t.prototype.setUpdatePayload=function(e){this._payload=e},t.prototype.getUpdatePayload=function(){return this._payload},t.prototype.getComponent=function(e,i){var n=this._componentsMap.get(e);if(n){var a=n[i||0];if(a)return a;if(i==null){for(var o=0;o<n.length;o++)if(n[o])return n[o]}}},t.prototype.queryComponents=function(e){var i=e.mainType;if(!i)return[];var n=e.index,a=e.id,o=e.name,s=this._componentsMap.get(i);if(!s||!s.length)return[];var u;return n!=null?(u=[],T(Ct(n),function(l){s[l]&&u.push(s[l])})):a!=null?u=ap("id",a,s):o!=null?u=ap("name",o,s):u=_t(s,function(l){return!!l}),op(u,e)},t.prototype.findComponents=function(e){var i=e.query,n=e.mainType,a=s(i),o=a?this.queryComponents(a):_t(this._componentsMap.get(n),function(l){return!!l});return u(op(o,e));function s(l){var f=n+"Index",h=n+"Id",v=n+"Name";return l&&(l[f]!=null||l[h]!=null||l[v]!=null)?{mainType:n,index:l[f],id:l[h],name:l[v]}:null}function u(l){return e.filter?_t(l,e.filter):l}},t.prototype.eachComponent=function(e,i,n){var a=this._componentsMap;if(q(e)){var o=i,s=e;a.each(function(h,v){for(var c=0;h&&c<h.length;c++){var p=h[c];p&&s.call(o,v,p,p.componentIndex)}})}else for(var u=H(e)?a.get(e):W(e)?this.findComponents(e):null,l=0;u&&l<u.length;l++){var f=u[l];f&&i.call(n,f,f.componentIndex)}},t.prototype.getSeriesByName=function(e){var i=Fe(e,null);return _t(this._componentsMap.get("series"),function(n){return!!n&&i!=null&&n.name===i})},t.prototype.getSeriesByIndex=function(e){return this._componentsMap.get("series")[e]},t.prototype.getSeriesByType=function(e){return _t(this._componentsMap.get("series"),function(i){return!!i&&i.subType===e})},t.prototype.getSeries=function(){return _t(this._componentsMap.get("series"),function(e){return!!e})},t.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},t.prototype.eachSeries=function(e,i){Rn(this),T(this._seriesIndices,function(n){var a=this._componentsMap.get("series")[n];e.call(i,a,n)},this)},t.prototype.eachRawSeries=function(e,i){T(this._componentsMap.get("series"),function(n){n&&e.call(i,n,n.componentIndex)})},t.prototype.eachSeriesByType=function(e,i,n){Rn(this),T(this._seriesIndices,function(a){var o=this._componentsMap.get("series")[a];o.subType===e&&i.call(n,o,a)},this)},t.prototype.eachRawSeriesByType=function(e,i,n){return T(this.getSeriesByType(e),i,n)},t.prototype.isSeriesFiltered=function(e){return Rn(this),this._seriesIndicesMap.get(e.componentIndex)==null},t.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},t.prototype.filterSeries=function(e,i){Rn(this);var n=[];T(this._seriesIndices,function(a){var o=this._componentsMap.get("series")[a];e.call(i,o,a)&&n.push(a)},this),this._seriesIndices=n,this._seriesIndicesMap=X(n)},t.prototype.restoreData=function(e){so(this);var i=this._componentsMap,n=[];i.each(function(a,o){nt.hasClass(o)&&n.push(o)}),nt.topologicalTravel(n,nt.getAllClassMainTypes(),function(a){T(i.get(a),function(o){o&&(a!=="series"||!oT(o,e))&&o.restoreData()})})},t.internalField=(function(){so=function(e){var i=e._seriesIndices=[];T(e._componentsMap.get("series"),function(n){n&&i.push(n.componentIndex)}),e._seriesIndicesMap=X(i)},Rn=function(e){},ip=function(e,i){e.option={},e.option[np]=aT,e._componentsMap=X({series:[]}),e._componentsCount=X();var n=i.aria;W(n)&&n.enabled==null&&(n.enabled=!0),sT(i,e._theme.option),tt(i,qx,!1),e._mergeOption(i,null)}})(),t})(St);function oT(r,t){if(t){var e=t.seriesIndex,i=t.seriesId,n=t.seriesName;return e!=null&&r.componentIndex!==e||i!=null&&r.id!==i||n!=null&&r.name!==n}}function sT(r,t){var e=r.color&&!r.colorLayer;T(t,function(i,n){n==="colorLayer"&&e||nt.hasClass(n)||(typeof i=="object"?r[n]=r[n]?tt(r[n],i,!1):Y(i):r[n]==null&&(r[n]=i))})}function ap(r,t,e){if(B(t)){var i=X();return T(t,function(a){if(a!=null){var o=Fe(a,null);o!=null&&i.set(a,!0)}}),_t(e,function(a){return a&&i.get(a[r])})}else{var n=Fe(t,null);return _t(e,function(a){return a&&n!=null&&a[r]===n})}}function op(r,t){return t.hasOwnProperty("subType")?_t(r,function(e){return e&&e.subType===t.subType}):r}function sp(r){var t=X();return r&&T(Ct(r.replaceMerge),function(e){t.set(e,!0)}),{replaceMergeMainTypeMap:t}}Ce(Uh,Wh);var uT=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],Xm=(function(){function r(t){T(uT,function(e){this[e]=U(t[e],t)},this)}return r})(),tl={},Yh=(function(){function r(){this._coordinateSystems=[]}return r.prototype.create=function(t,e){var i=[];T(tl,function(n,a){var o=n.create(t,e);i=i.concat(o||[])}),this._coordinateSystems=i},r.prototype.update=function(t,e){T(this._coordinateSystems,function(i){i.update&&i.update(t,e)})},r.prototype.getCoordinateSystems=function(){return this._coordinateSystems.slice()},r.register=function(t,e){tl[t]=e},r.get=function(t){return tl[t]},r})(),lT=/^(min|max)?(.+)$/,fT=(function(){function r(t){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=t}return r.prototype.setOption=function(t,e,i){t&&(T(Ct(t.series),function(o){o&&o.data&&Yt(o.data)&&Kl(o.data)}),T(Ct(t.dataset),function(o){o&&o.source&&Yt(o.source)&&Kl(o.source)})),t=Y(t);var n=this._optionBackup,a=hT(t,e,!n);this._newBaseOption=a.baseOption,n?(a.timelineOptions.length&&(n.timelineOptions=a.timelineOptions),a.mediaList.length&&(n.mediaList=a.mediaList),a.mediaDefault&&(n.mediaDefault=a.mediaDefault)):this._optionBackup=a},r.prototype.mountOption=function(t){var e=this._optionBackup;return this._timelineOptions=e.timelineOptions,this._mediaList=e.mediaList,this._mediaDefault=e.mediaDefault,this._currentMediaIndices=[],Y(t?e.baseOption:this._newBaseOption)},r.prototype.getTimelineOption=function(t){var e,i=this._timelineOptions;if(i.length){var n=t.getComponent("timeline");n&&(e=Y(i[n.getCurrentIndex()]))}return e},r.prototype.getMediaOption=function(t){var e=this._api.getWidth(),i=this._api.getHeight(),n=this._mediaList,a=this._mediaDefault,o=[],s=[];if(!n.length&&!a)return s;for(var u=0,l=n.length;u<l;u++)vT(n[u].query,e,i)&&o.push(u);return!o.length&&a&&(o=[-1]),o.length&&!pT(o,this._currentMediaIndices)&&(s=z(o,function(f){return Y(f===-1?a.option:n[f].option)})),this._currentMediaIndices=o,s},r})();function hT(r,t,e){var i=[],n,a,o=r.baseOption,s=r.timeline,u=r.options,l=r.media,f=!!r.media,h=!!(u||s||o&&o.timeline);o?(a=o,a.timeline||(a.timeline=s)):((h||f)&&(r.options=r.media=null),a=r),f&&B(l)&&T(l,function(c){c&&c.option&&(c.query?i.push(c):n||(n=c))}),v(a),T(u,function(c){return v(c)}),T(i,function(c){return v(c.option)});function v(c){T(t,function(p){p(c,e)})}return{baseOption:a,timelineOptions:u||[],mediaDefault:n,mediaList:i}}function vT(r,t,e){var i={width:t,height:e,aspectratio:t/e},n=!0;return T(r,function(a,o){var s=o.match(lT);if(!(!s||!s[1]||!s[2])){var u=s[1],l=s[2].toLowerCase();cT(i[l],a,u)||(n=!1)}}),n}function cT(r,t,e){return e==="min"?r>=t:e==="max"?r<=t:r===t}function pT(r,t){return r.join(",")===t.join(",")}var me=T,La=W,up=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function el(r){var t=r&&r.itemStyle;if(t)for(var e=0,i=up.length;e<i;e++){var n=up[e],a=t.normal,o=t.emphasis;a&&a[n]&&(r[n]=r[n]||{},r[n].normal?tt(r[n].normal,a[n]):r[n].normal=a[n],a[n]=null),o&&o[n]&&(r[n]=r[n]||{},r[n].emphasis?tt(r[n].emphasis,o[n]):r[n].emphasis=o[n],o[n]=null)}}function kt(r,t,e){if(r&&r[t]&&(r[t].normal||r[t].emphasis)){var i=r[t].normal,n=r[t].emphasis;i&&(e?(r[t].normal=r[t].emphasis=null,rt(r[t],i)):r[t]=i),n&&(r.emphasis=r.emphasis||{},r.emphasis[t]=n,n.focus&&(r.emphasis.focus=n.focus),n.blurScope&&(r.emphasis.blurScope=n.blurScope))}}function ra(r){kt(r,"itemStyle"),kt(r,"lineStyle"),kt(r,"areaStyle"),kt(r,"label"),kt(r,"labelLine"),kt(r,"upperLabel"),kt(r,"edgeLabel")}function wt(r,t){var e=La(r)&&r[t],i=La(e)&&e.textStyle;if(i)for(var n=0,a=cc.length;n<a;n++){var o=cc[n];i.hasOwnProperty(o)&&(e[o]=i[o])}}function oe(r){r&&(ra(r),wt(r,"label"),r.emphasis&&wt(r.emphasis,"label"))}function dT(r){if(La(r)){el(r),ra(r),wt(r,"label"),wt(r,"upperLabel"),wt(r,"edgeLabel"),r.emphasis&&(wt(r.emphasis,"label"),wt(r.emphasis,"upperLabel"),wt(r.emphasis,"edgeLabel"));var t=r.markPoint;t&&(el(t),oe(t));var e=r.markLine;e&&(el(e),oe(e));var i=r.markArea;i&&oe(i);var n=r.data;if(r.type==="graph"){n=n||r.nodes;var a=r.links||r.edges;if(a&&!Yt(a))for(var o=0;o<a.length;o++)oe(a[o]);T(r.categories,function(l){ra(l)})}if(n&&!Yt(n))for(var o=0;o<n.length;o++)oe(n[o]);if(t=r.markPoint,t&&t.data)for(var s=t.data,o=0;o<s.length;o++)oe(s[o]);if(e=r.markLine,e&&e.data)for(var u=e.data,o=0;o<u.length;o++)B(u[o])?(oe(u[o][0]),oe(u[o][1])):oe(u[o]);r.type==="gauge"?(wt(r,"axisLabel"),wt(r,"title"),wt(r,"detail")):r.type==="treemap"?(kt(r.breadcrumb,"itemStyle"),T(r.levels,function(l){ra(l)})):r.type==="tree"&&ra(r.leaves)}}function Ye(r){return B(r)?r:r?[r]:[]}function lp(r){return(B(r)?r[0]:r)||{}}function gT(r,t){me(Ye(r.series),function(i){La(i)&&dT(i)});var e=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];t&&e.push("valueAxis","categoryAxis","logAxis","timeAxis"),me(e,function(i){me(Ye(r[i]),function(n){n&&(wt(n,"axisLabel"),wt(n.axisPointer,"label"))})}),me(Ye(r.parallel),function(i){var n=i&&i.parallelAxisDefault;wt(n,"axisLabel"),wt(n&&n.axisPointer,"label")}),me(Ye(r.calendar),function(i){kt(i,"itemStyle"),wt(i,"dayLabel"),wt(i,"monthLabel"),wt(i,"yearLabel")}),me(Ye(r.radar),function(i){wt(i,"name"),i.name&&i.axisName==null&&(i.axisName=i.name,delete i.name),i.nameGap!=null&&i.axisNameGap==null&&(i.axisNameGap=i.nameGap,delete i.nameGap)}),me(Ye(r.geo),function(i){La(i)&&(oe(i),me(Ye(i.regions),function(n){oe(n)}))}),me(Ye(r.timeline),function(i){oe(i),kt(i,"label"),kt(i,"itemStyle"),kt(i,"controlStyle",!0);var n=i.data;B(n)&&T(n,function(a){W(a)&&(kt(a,"label"),kt(a,"itemStyle"))})}),me(Ye(r.toolbox),function(i){kt(i,"iconStyle"),me(i.feature,function(n){kt(n,"iconStyle")})}),wt(lp(r.axisPointer),"label"),wt(lp(r.tooltip).axisPointer,"label")}function yT(r,t){for(var e=t.split(","),i=r,n=0;n<e.length&&(i=i&&i[e[n]],i!=null);n++);return i}function mT(r,t,e,i){for(var n=t.split(","),a=r,o,s=0;s<n.length-1;s++)o=n[s],a[o]==null&&(a[o]={}),a=a[o];a[n[s]]==null&&(a[n[s]]=e)}function fp(r){r&&T(_T,function(t){t[0]in r&&!(t[1]in r)&&(r[t[1]]=r[t[0]])})}var _T=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],ST=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],rl=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function En(r){var t=r&&r.itemStyle;if(t)for(var e=0;e<rl.length;e++){var i=rl[e][1],n=rl[e][0];t[i]!=null&&(t[n]=t[i])}}function hp(r){r&&r.alignTo==="edge"&&r.margin!=null&&r.edgeDistance==null&&(r.edgeDistance=r.margin)}function vp(r){r&&r.downplay&&!r.blur&&(r.blur=r.downplay)}function wT(r){r&&r.focusNodeAdjacency!=null&&(r.emphasis=r.emphasis||{},r.emphasis.focus==null&&(r.emphasis.focus="adjacency"))}function $m(r,t){if(r)for(var e=0;e<r.length;e++)t(r[e]),r[e]&&$m(r[e].children,t)}function qm(r,t){gT(r,t),r.series=Ct(r.series),T(r.series,function(e){if(W(e)){var i=e.type;if(i==="line")e.clipOverflow!=null&&(e.clip=e.clipOverflow);else if(i==="pie"||i==="gauge"){e.clockWise!=null&&(e.clockwise=e.clockWise),hp(e.label);var n=e.data;if(n&&!Yt(n))for(var a=0;a<n.length;a++)hp(n[a]);e.hoverOffset!=null&&(e.emphasis=e.emphasis||{},(e.emphasis.scaleSize=null)&&(e.emphasis.scaleSize=e.hoverOffset))}else if(i==="gauge"){var o=yT(e,"pointer.color");o!=null&&mT(e,"itemStyle.color",o)}else if(i==="bar"){En(e),En(e.backgroundStyle),En(e.emphasis);var n=e.data;if(n&&!Yt(n))for(var a=0;a<n.length;a++)typeof n[a]=="object"&&(En(n[a]),En(n[a]&&n[a].emphasis))}else if(i==="sunburst"){var s=e.highlightPolicy;s&&(e.emphasis=e.emphasis||{},e.emphasis.focus||(e.emphasis.focus=s)),vp(e),$m(e.data,vp)}else i==="graph"||i==="sankey"?wT(e):i==="map"&&(e.mapType&&!e.map&&(e.map=e.mapType),e.mapLocation&&rt(e,e.mapLocation));e.hoverAnimation!=null&&(e.emphasis=e.emphasis||{},e.emphasis&&e.emphasis.scale==null&&(e.emphasis.scale=e.hoverAnimation)),fp(e)}}),r.dataRange&&(r.visualMap=r.dataRange),T(ST,function(e){var i=r[e];i&&(B(i)||(i=[i]),T(i,function(n){fp(n)}))})}function bT(r){var t=X();r.eachSeries(function(e){var i=e.get("stack");if(i){var n=t.get(i)||t.set(i,[]),a=e.getData(),o={stackResultDimension:a.getCalculationInfo("stackResultDimension"),stackedOverDimension:a.getCalculationInfo("stackedOverDimension"),stackedDimension:a.getCalculationInfo("stackedDimension"),stackedByDimension:a.getCalculationInfo("stackedByDimension"),isStackedByIndex:a.getCalculationInfo("isStackedByIndex"),data:a,seriesModel:e};if(!o.stackedDimension||!(o.isStackedByIndex||o.stackedByDimension))return;n.length&&a.setCalculationInfo("stackedOnSeries",n[n.length-1].seriesModel),n.push(o)}}),t.each(xT)}function xT(r){T(r,function(t,e){var i=[],n=[NaN,NaN],a=[t.stackResultDimension,t.stackedOverDimension],o=t.data,s=t.isStackedByIndex,u=t.seriesModel.get("stackStrategy")||"samesign";o.modify(a,function(l,f,h){var v=o.get(t.stackedDimension,h);if(isNaN(v))return n;var c,p;s?p=o.getRawIndex(h):c=o.get(t.stackedByDimension,h);for(var d=NaN,g=e-1;g>=0;g--){var y=r[g];if(s||(p=y.data.rawIndexOf(y.stackedByDimension,c)),p>=0){var m=y.data.getByRawIndex(y.stackResultDimension,p);if(u==="all"||u==="positive"&&m>0||u==="negative"&&m<0||u==="samesign"&&v>=0&&m>0||u==="samesign"&&v<=0&&m<0){v=jS(v,m),d=m;break}}}return i[0]=v,i[1]=d,i})})}var tu=(function(){function r(t){this.data=t.data||(t.sourceFormat===or?{}:[]),this.sourceFormat=t.sourceFormat||Wm,this.seriesLayoutBy=t.seriesLayoutBy||Qe,this.startIndex=t.startIndex||0,this.dimensionsDetectedCount=t.dimensionsDetectedCount,this.metaRawOption=t.metaRawOption;var e=this.dimensionsDefine=t.dimensionsDefine;if(e)for(var i=0;i<e.length;i++){var n=e[i];n.type==null&&Zm(this,i)===Kt.Must&&(n.type="ordinal")}}return r})();function Zh(r){return r instanceof tu}function Af(r,t,e){e=e||Qm(r);var i=t.seriesLayoutBy,n=MT(r,e,i,t.sourceHeader,t.dimensions),a=new tu({data:r,sourceFormat:e,seriesLayoutBy:i,dimensionsDefine:n.dimensionsDefine,startIndex:n.startIndex,dimensionsDetectedCount:n.dimensionsDetectedCount,metaRawOption:Y(t)});return a}function Km(r){return new tu({data:r,sourceFormat:Yt(r)?Mr:ge})}function TT(r){return new tu({data:r.data,sourceFormat:r.sourceFormat,seriesLayoutBy:r.seriesLayoutBy,dimensionsDefine:Y(r.dimensionsDefine),startIndex:r.startIndex,dimensionsDetectedCount:r.dimensionsDetectedCount})}function Qm(r){var t=Wm;if(Yt(r))t=Mr;else if(B(r)){r.length===0&&(t=Xt);for(var e=0,i=r.length;e<i;e++){var n=r[e];if(n!=null){if(B(n)||Yt(n)){t=Xt;break}else if(W(n)){t=Ge;break}}}}else if(W(r)){for(var a in r)if(N(r,a)&&zt(r[a])){t=or;break}}return t}function MT(r,t,e,i,n){var a,o;if(!r)return{dimensionsDefine:cp(n),startIndex:o,dimensionsDetectedCount:a};if(t===Xt){var s=r;i==="auto"||i==null?pp(function(l){l!=null&&l!=="-"&&(H(l)?o==null&&(o=1):o=0)},e,s,10):o=dt(i)?i:i?1:0,!n&&o===1&&(n=[],pp(function(l,f){n[f]=l!=null?l+"":""},e,s,1/0)),a=n?n.length:e===wn?s.length:s[0]?s[0].length:null}else if(t===Ge)n||(n=CT(r));else if(t===or)n||(n=[],T(r,function(l,f){n.push(f)}));else if(t===ge){var u=Fa(r[0]);a=B(u)&&u.length||1}return{startIndex:o,dimensionsDefine:cp(n),dimensionsDetectedCount:a}}function CT(r){for(var t=0,e;t<r.length&&!(e=r[t++]););if(e)return ft(e)}function cp(r){if(r){var t=X();return z(r,function(e,i){e=W(e)?e:{name:e};var n={name:e.name,displayName:e.displayName,type:e.type};if(n.name==null)return n;n.name+="",n.displayName==null&&(n.displayName=n.name);var a=t.get(n.name);return a?n.name+="-"+a.count++:t.set(n.name,{count:1}),n})}}function pp(r,t,e,i){if(t===wn)for(var n=0;n<e.length&&n<i;n++)r(e[n]?e[n][0]:null,n);else for(var a=e[0]||[],n=0;n<a.length&&n<i;n++)r(a[n],n)}function Jm(r){var t=r.sourceFormat;return t===Ge||t===or}var Qr,Jr,jr,dp,gp,jm=(function(){function r(t,e){var i=Zh(t)?t:Km(t);this._source=i;var n=this._data=i.data;i.sourceFormat===Mr&&(this._offset=0,this._dimSize=e,this._data=n),gp(this,n,i)}return r.prototype.getSource=function(){return this._source},r.prototype.count=function(){return 0},r.prototype.getItem=function(t,e){},r.prototype.appendData=function(t){},r.prototype.clean=function(){},r.protoInitialize=(function(){var t=r.prototype;t.pure=!1,t.persistent=!0})(),r.internalField=(function(){var t;gp=function(o,s,u){var l=u.sourceFormat,f=u.seriesLayoutBy,h=u.startIndex,v=u.dimensionsDefine,c=dp[Xh(l,f)];if(k(o,c),l===Mr)o.getItem=e,o.count=n,o.fillStorage=i;else{var p=t0(l,f);o.getItem=U(p,null,s,h,v);var d=e0(l,f);o.count=U(d,null,s,h,v)}};var e=function(o,s){o=o-this._offset,s=s||[];for(var u=this._data,l=this._dimSize,f=l*o,h=0;h<l;h++)s[h]=u[f+h];return s},i=function(o,s,u,l){for(var f=this._data,h=this._dimSize,v=0;v<h;v++){for(var c=l[v],p=c[0]==null?1/0:c[0],d=c[1]==null?-1/0:c[1],g=s-o,y=u[v],m=0;m<g;m++){var _=f[m*h+v];y[o+m]=_,_<p&&(p=_),_>d&&(d=_)}c[0]=p,c[1]=d}},n=function(){return this._data?this._data.length/this._dimSize:0};dp=(t={},t[Xt+"_"+Qe]={pure:!0,appendData:a},t[Xt+"_"+wn]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},t[Ge]={pure:!0,appendData:a},t[or]={pure:!0,appendData:function(o){var s=this._data;T(o,function(u,l){for(var f=s[l]||(s[l]=[]),h=0;h<(u||[]).length;h++)f.push(u[h])})}},t[ge]={appendData:a},t[Mr]={persistent:!1,pure:!0,appendData:function(o){this._data=o},clean:function(){this._offset+=this.count(),this._data=null}},t);function a(o){for(var s=0;s<o.length;s++)this._data.push(o[s])}})(),r})(),yp=function(r,t,e,i){return r[i]},DT=(Qr={},Qr[Xt+"_"+Qe]=function(r,t,e,i){return r[i+t]},Qr[Xt+"_"+wn]=function(r,t,e,i,n){i+=t;for(var a=n||[],o=r,s=0;s<o.length;s++){var u=o[s];a[s]=u?u[i]:null}return a},Qr[Ge]=yp,Qr[or]=function(r,t,e,i,n){for(var a=n||[],o=0;o<e.length;o++){var s=e[o].name,u=r[s];a[o]=u?u[i]:null}return a},Qr[ge]=yp,Qr);function t0(r,t){var e=DT[Xh(r,t)];return e}var mp=function(r,t,e){return r.length},AT=(Jr={},Jr[Xt+"_"+Qe]=function(r,t,e){return Math.max(0,r.length-t)},Jr[Xt+"_"+wn]=function(r,t,e){var i=r[0];return i?Math.max(0,i.length-t):0},Jr[Ge]=mp,Jr[or]=function(r,t,e){var i=e[0].name,n=r[i];return n?n.length:0},Jr[ge]=mp,Jr);function e0(r,t){var e=AT[Xh(r,t)];return e}var il=function(r,t,e){return r[t]},LT=(jr={},jr[Xt]=il,jr[Ge]=function(r,t,e){return r[e]},jr[or]=il,jr[ge]=function(r,t,e){var i=Fa(r);return i instanceof Array?i[t]:i},jr[Mr]=il,jr);function r0(r){var t=LT[r];return t}function Xh(r,t){return r===Xt?r+"_"+t:r}function cn(r,t,e){if(r){var i=r.getRawDataItem(t);if(i!=null){var n=r.getStore(),a=n.getSource().sourceFormat;if(e!=null){var o=r.getDimensionIndex(e),s=n.getDimensionProperty(o);return r0(a)(i,o,s)}else{var u=i;return a===ge&&(u=Fa(i)),u}}}}var PT=/\{@(.+?)\}/g,$h=(function(){function r(){}return r.prototype.getDataParams=function(t,e){var i=this.getData(e),n=this.getRawValue(t,e),a=i.getRawIndex(t),o=i.getName(t),s=i.getRawDataItem(t),u=i.getItemVisual(t,"style"),l=u&&u[i.getItemVisual(t,"drawType")||"fill"],f=u&&u.stroke,h=this.mainType,v=h==="series",c=i.userOutput&&i.userOutput.get();return{componentType:h,componentSubType:this.subType,componentIndex:this.componentIndex,seriesType:v?this.subType:null,seriesIndex:this.seriesIndex,seriesId:v?this.id:null,seriesName:v?this.name:null,name:o,dataIndex:a,data:s,dataType:e,value:n,color:l,borderColor:f,dimensionNames:c?c.fullDimensions:null,encode:c?c.encode:null,$vars:["seriesName","name","value"]}},r.prototype.getFormattedLabel=function(t,e,i,n,a,o){e=e||"normal";var s=this.getData(i),u=this.getDataParams(t,i);if(o&&(u.value=o.interpolatedValue),n!=null&&B(u.value)&&(u.value=u.value[n]),!a){var l=s.getItemModel(t);a=l.get(e==="normal"?["label","formatter"]:[e,"label","formatter"])}if(q(a))return u.status=e,u.dimensionIndex=n,a(u);if(H(a)){var f=zm(a,u);return f.replace(PT,function(h,v){var c=v.length,p=v;p.charAt(0)==="["&&p.charAt(c-1)==="]"&&(p=+p.slice(1,c-1));var d=cn(s,t,p);if(o&&B(o.interpolatedValue)){var g=s.getDimensionIndex(p);g>=0&&(d=o.interpolatedValue[g])}return d!=null?d+"":""})}},r.prototype.getRawValue=function(t,e){return cn(this.getData(e),t)},r.prototype.formatTooltip=function(t,e,i){},r})();function _p(r){var t,e;return W(r)?r.type&&(e=r):t=r,{text:t,frag:e}}function pa(r){return new IT(r)}var IT=(function(){function r(t){t=t||{},this._reset=t.reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0}return r.prototype.perform=function(t){var e=this._upstream,i=t&&t.skip;if(this._dirty&&e){var n=this.context;n.data=n.outputData=e.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var a;this._plan&&!i&&(a=this._plan(this.context));var o=f(this._modBy),s=this._modDataCount||0,u=f(t&&t.modBy),l=t&&t.modDataCount||0;(o!==u||s!==l)&&(a="reset");function f(m){return!(m>=1)&&(m=1),m}var h;(this._dirty||a==="reset")&&(this._dirty=!1,h=this._doReset(i)),this._modBy=u,this._modDataCount=l;var v=t&&t.step;if(e?this._dueEnd=e._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var c=this._dueIndex,p=Math.min(v!=null?this._dueIndex+v:1/0,this._dueEnd);if(!i&&(h||c<p)){var d=this._progress;if(B(d))for(var g=0;g<d.length;g++)this._doProgress(d[g],c,p,u,l);else this._doProgress(d,c,p,u,l)}this._dueIndex=p;var y=this._settedOutputEnd!=null?this._settedOutputEnd:p;this._outputDueEnd=y}else this._dueIndex=this._outputDueEnd=this._settedOutputEnd!=null?this._settedOutputEnd:this._dueEnd;return this.unfinished()},r.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},r.prototype._doProgress=function(t,e,i,n,a){Sp.reset(e,i,n,a),this._callingProgress=t,this._callingProgress({start:e,end:i,count:i-e,next:Sp.next},this.context)},r.prototype._doReset=function(t){this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null;var e,i;!t&&this._reset&&(e=this._reset(this.context),e&&e.progress&&(i=e.forceFirstProgress,e=e.progress),B(e)&&!e.length&&(e=null)),this._progress=e,this._modBy=this._modDataCount=null;var n=this._downstream;return n&&n.dirty(),i},r.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},r.prototype.pipe=function(t){(this._downstream!==t||this._dirty)&&(this._downstream=t,t._upstream=this,t.dirty())},r.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},r.prototype.getUpstream=function(){return this._upstream},r.prototype.getDownstream=function(){return this._downstream},r.prototype.setOutputEnd=function(t){this._outputDueEnd=this._settedOutputEnd=t},r})(),Sp=(function(){var r,t,e,i,n,a={reset:function(u,l,f,h){t=u,r=l,e=f,i=h,n=Math.ceil(i/e),a.next=e>1&&i>0?s:o}};return a;function o(){return t<r?t++:null}function s(){var u=t%n*e+Math.ceil(t/n),l=t>=r?null:u<i?u:t;return t++,l}})();function Cr(r,t){var e=t&&t.type;return e==="ordinal"?r:(e==="time"&&!dt(r)&&r!=null&&r!=="-"&&(r=+tr(r)),r==null||r===""?NaN:Number(r))}X({number:function(r){return parseFloat(r)},time:function(r){return+tr(r)},trim:function(r){return H(r)?Oe(r):r}});var RT=(function(){function r(t,e){var i=t==="desc";this._resultLT=i?1:-1,e==null&&(e=i?"min":"max"),this._incomparable=e==="min"?-1/0:1/0}return r.prototype.evaluate=function(t,e){var i=dt(t)?t:ts(t),n=dt(e)?e:ts(e),a=isNaN(i),o=isNaN(n);if(a&&(i=this._incomparable),o&&(n=this._incomparable),a&&o){var s=H(t),u=H(e);s&&(i=u?t:0),u&&(n=s?e:0)}return i<n?this._resultLT:i>n?-this._resultLT:0},r})(),ET=(function(){function r(){}return r.prototype.getRawData=function(){throw new Error("not supported")},r.prototype.getRawDataItem=function(t){throw new Error("not supported")},r.prototype.cloneRawData=function(){},r.prototype.getDimensionInfo=function(t){},r.prototype.cloneAllDimensionInfo=function(){},r.prototype.count=function(){},r.prototype.retrieveValue=function(t,e){},r.prototype.retrieveValueFromItem=function(t,e){},r.prototype.convertValue=function(t,e){return Cr(t,e)},r})();function kT(r,t){var e=new ET,i=r.data,n=e.sourceFormat=r.sourceFormat,a=r.startIndex,o="";r.seriesLayoutBy!==Qe&&Ft(o);var s=[],u={},l=r.dimensionsDefine;if(l)T(l,function(d,g){var y=d.name,m={index:g,name:y,displayName:d.displayName};if(s.push(m),y!=null){var _="";N(u,y)&&Ft(_),u[y]=m}});else for(var f=0;f<r.dimensionsDetectedCount;f++)s.push({index:f});var h=t0(n,Qe);t.__isBuiltIn&&(e.getRawDataItem=function(d){return h(i,a,s,d)},e.getRawData=U(OT,null,r)),e.cloneRawData=U(BT,null,r);var v=e0(n,Qe);e.count=U(v,null,i,a,s);var c=r0(n);e.retrieveValue=function(d,g){var y=h(i,a,s,d);return p(y,g)};var p=e.retrieveValueFromItem=function(d,g){if(d!=null){var y=s[g];if(y)return c(d,g,y.name)}};return e.getDimensionInfo=U(NT,null,s,u),e.cloneAllDimensionInfo=U(FT,null,s),e}function OT(r){var t=r.sourceFormat;if(!qh(t)){var e="";Ft(e)}return r.data}function BT(r){var t=r.sourceFormat,e=r.data;if(!qh(t)){var i="";Ft(i)}if(t===Xt){for(var n=[],a=0,o=e.length;a<o;a++)n.push(e[a].slice());return n}else if(t===Ge){for(var n=[],a=0,o=e.length;a<o;a++)n.push(k({},e[a]));return n}}function NT(r,t,e){if(e!=null){if(dt(e)||!isNaN(e)&&!N(t,e))return r[e];if(N(t,e))return t[e]}}function FT(r){return Y(r)}var i0=X();function zT(r){r=Y(r);var t=r.type,e="";t||Ft(e);var i=t.split(":");i.length!==2&&Ft(e);var n=!1;i[0]==="echarts"&&(t=i[1],n=!0),r.__isBuiltIn=n,i0.set(t,r)}function VT(r,t,e){var i=Ct(r),n=i.length,a="";n||Ft(a);for(var o=0,s=n;o<s;o++){var u=i[o];t=HT(u,t),o!==s-1&&(t.length=Math.max(t.length,1))}return t}function HT(r,t,e,i){var n="";t.length||Ft(n),W(r)||Ft(n);var a=r.type,o=i0.get(a);o||Ft(n);var s=z(t,function(l){return kT(l,o)}),u=Ct(o.transform({upstream:s[0],upstreamList:s,config:Y(r.config)}));return z(u,function(l,f){var h="";W(l)||Ft(h),l.data||Ft(h);var v=Qm(l.data);qh(v)||Ft(h);var c,p=t[0];if(p&&f===0&&!l.dimensions){var d=p.startIndex;d&&(l.data=p.data.slice(0,d).concat(l.data)),c={seriesLayoutBy:Qe,sourceHeader:d,dimensions:p.metaRawOption.dimensions}}else c={seriesLayoutBy:Qe,sourceHeader:0,dimensions:l.dimensions};return Af(l.data,c,null)})}function qh(r){return r===Xt||r===Ge}var eu="undefined",GT=typeof Uint32Array===eu?Array:Uint32Array,WT=typeof Uint16Array===eu?Array:Uint16Array,n0=typeof Int32Array===eu?Array:Int32Array,wp=typeof Float64Array===eu?Array:Float64Array,a0={float:wp,int:n0,ordinal:Array,number:Array,time:wp},nl;function Fi(r){return r>65535?GT:WT}function zi(){return[1/0,-1/0]}function UT(r){var t=r.constructor;return t===Array?r.slice():new t(r)}function bp(r,t,e,i,n){var a=a0[e||"float"];if(n){var o=r[t],s=o&&o.length;if(s!==i){for(var u=new a(i),l=0;l<s;l++)u[l]=o[l];r[t]=u}}else r[t]=new a(i)}var Lf=(function(){function r(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=X()}return r.prototype.initData=function(t,e,i){this._provider=t,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var n=t.getSource(),a=this.defaultDimValueGetter=nl[n.sourceFormat];this._dimValueGetter=i||a,this._rawExtent=[],Jm(n),this._dimensions=z(e,function(o){return{type:o.type,property:o.property}}),this._initDataFromProvider(0,t.count())},r.prototype.getProvider=function(){return this._provider},r.prototype.getSource=function(){return this._provider.getSource()},r.prototype.ensureCalculationDimension=function(t,e){var i=this._calcDimNameToIdx,n=this._dimensions,a=i.get(t);if(a!=null){if(n[a].type===e)return a}else a=n.length;return n[a]={type:e},i.set(t,a),this._chunks[a]=new a0[e||"float"](this._rawCount),this._rawExtent[a]=zi(),a},r.prototype.collectOrdinalMeta=function(t,e){var i=this._chunks[t],n=this._dimensions[t],a=this._rawExtent,o=n.ordinalOffset||0,s=i.length;o===0&&(a[t]=zi());for(var u=a[t],l=o;l<s;l++){var f=i[l]=e.parseAndCollect(i[l]);isNaN(f)||(u[0]=Math.min(f,u[0]),u[1]=Math.max(f,u[1]))}n.ordinalMeta=e,n.ordinalOffset=s,n.type="ordinal"},r.prototype.getOrdinalMeta=function(t){var e=this._dimensions[t],i=e.ordinalMeta;return i},r.prototype.getDimensionProperty=function(t){var e=this._dimensions[t];return e&&e.property},r.prototype.appendData=function(t){var e=this._provider,i=this.count();e.appendData(t);var n=e.count();return e.persistent||(n+=i),i<n&&this._initDataFromProvider(i,n,!0),[i,n]},r.prototype.appendValues=function(t,e){for(var i=this._chunks,n=this._dimensions,a=n.length,o=this._rawExtent,s=this.count(),u=s+Math.max(t.length,e||0),l=0;l<a;l++){var f=n[l];bp(i,l,f.type,u,!0)}for(var h=[],v=s;v<u;v++)for(var c=v-s,p=0;p<a;p++){var f=n[p],d=nl.arrayRows.call(this,t[c]||h,f.property,c,p);i[p][v]=d;var g=o[p];d<g[0]&&(g[0]=d),d>g[1]&&(g[1]=d)}return this._rawCount=this._count=u,{start:s,end:u}},r.prototype._initDataFromProvider=function(t,e,i){for(var n=this._provider,a=this._chunks,o=this._dimensions,s=o.length,u=this._rawExtent,l=z(o,function(m){return m.property}),f=0;f<s;f++){var h=o[f];u[f]||(u[f]=zi()),bp(a,f,h.type,e,i)}if(n.fillStorage)n.fillStorage(t,e,a,u);else for(var v=[],c=t;c<e;c++){v=n.getItem(c,v);for(var p=0;p<s;p++){var d=a[p],g=this._dimValueGetter(v,l[p],c,p);d[c]=g;var y=u[p];g<y[0]&&(y[0]=g),g>y[1]&&(y[1]=g)}}!n.persistent&&n.clean&&n.clean(),this._rawCount=this._count=e,this._extent=[]},r.prototype.count=function(){return this._count},r.prototype.get=function(t,e){if(!(e>=0&&e<this._count))return NaN;var i=this._chunks[t];return i?i[this.getRawIndex(e)]:NaN},r.prototype.getValues=function(t,e){var i=[],n=[];if(e==null){e=t,t=[];for(var a=0;a<this._dimensions.length;a++)n.push(a)}else n=t;for(var a=0,o=n.length;a<o;a++)i.push(this.get(n[a],e));return i},r.prototype.getByRawIndex=function(t,e){if(!(e>=0&&e<this._rawCount))return NaN;var i=this._chunks[t];return i?i[e]:NaN},r.prototype.getSum=function(t){var e=this._chunks[t],i=0;if(e)for(var n=0,a=this.count();n<a;n++){var o=this.get(t,n);isNaN(o)||(i+=o)}return i},r.prototype.getMedian=function(t){var e=[];this.each([t],function(a){isNaN(a)||e.push(a)});var i=e.sort(function(a,o){return a-o}),n=this.count();return n===0?0:n%2===1?i[(n-1)/2]:(i[n/2]+i[n/2-1])/2},r.prototype.indexOfRawIndex=function(t){if(t>=this._rawCount||t<0)return-1;if(!this._indices)return t;var e=this._indices,i=e[t];if(i!=null&&i<this._count&&i===t)return t;for(var n=0,a=this._count-1;n<=a;){var o=(n+a)/2|0;if(e[o]<t)n=o+1;else if(e[o]>t)a=o-1;else return o}return-1},r.prototype.indicesOfNearest=function(t,e,i){var n=this._chunks,a=n[t],o=[];if(!a)return o;i==null&&(i=1/0);for(var s=1/0,u=-1,l=0,f=0,h=this.count();f<h;f++){var v=this.getRawIndex(f),c=e-a[v],p=Math.abs(c);p<=i&&((p<s||p===s&&c>=0&&u<0)&&(s=p,u=c,l=0),c===u&&(o[l++]=f))}return o.length=l,o},r.prototype.getIndices=function(){var t,e=this._indices;if(e){var i=e.constructor,n=this._count;if(i===Array){t=new i(n);for(var a=0;a<n;a++)t[a]=e[a]}else t=new i(e.buffer,0,n)}else{var i=Fi(this._rawCount);t=new i(this.count());for(var a=0;a<t.length;a++)t[a]=a}return t},r.prototype.filter=function(t,e){if(!this._count)return this;for(var i=this.clone(),n=i.count(),a=Fi(i._rawCount),o=new a(n),s=[],u=t.length,l=0,f=t[0],h=i._chunks,v=0;v<n;v++){var c=void 0,p=i.getRawIndex(v);if(u===0)c=e(v);else if(u===1){var d=h[f][p];c=e(d,v)}else{for(var g=0;g<u;g++)s[g]=h[t[g]][p];s[g]=v,c=e.apply(null,s)}c&&(o[l++]=p)}return l<n&&(i._indices=o),i._count=l,i._extent=[],i._updateGetRawIdx(),i},r.prototype.selectRange=function(t){var e=this.clone(),i=e._count;if(!i)return this;var n=ft(t),a=n.length;if(!a)return this;var o=e.count(),s=Fi(e._rawCount),u=new s(o),l=0,f=n[0],h=t[f][0],v=t[f][1],c=e._chunks,p=!1;if(!e._indices){var d=0;if(a===1){for(var g=c[n[0]],y=0;y<i;y++){var m=g[y];(m>=h&&m<=v||isNaN(m))&&(u[l++]=d),d++}p=!0}else if(a===2){for(var g=c[n[0]],_=c[n[1]],S=t[n[1]][0],b=t[n[1]][1],y=0;y<i;y++){var m=g[y],w=_[y];(m>=h&&m<=v||isNaN(m))&&(w>=S&&w<=b||isNaN(w))&&(u[l++]=d),d++}p=!0}}if(!p)if(a===1)for(var y=0;y<o;y++){var x=e.getRawIndex(y),m=c[n[0]][x];(m>=h&&m<=v||isNaN(m))&&(u[l++]=x)}else for(var y=0;y<o;y++){for(var C=!0,x=e.getRawIndex(y),M=0;M<a;M++){var D=n[M],m=c[D][x];(m<t[D][0]||m>t[D][1])&&(C=!1)}C&&(u[l++]=e.getRawIndex(y))}return l<o&&(e._indices=u),e._count=l,e._extent=[],e._updateGetRawIdx(),e},r.prototype.map=function(t,e){var i=this.clone(t);return this._updateDims(i,t,e),i},r.prototype.modify=function(t,e){this._updateDims(this,t,e)},r.prototype._updateDims=function(t,e,i){for(var n=t._chunks,a=[],o=e.length,s=t.count(),u=[],l=t._rawExtent,f=0;f<e.length;f++)l[e[f]]=zi();for(var h=0;h<s;h++){for(var v=t.getRawIndex(h),c=0;c<o;c++)u[c]=n[e[c]][v];u[o]=h;var p=i&&i.apply(null,u);if(p!=null){typeof p!="object"&&(a[0]=p,p=a);for(var f=0;f<p.length;f++){var d=e[f],g=p[f],y=l[d],m=n[d];m&&(m[v]=g),g<y[0]&&(y[0]=g),g>y[1]&&(y[1]=g)}}}},r.prototype.lttbDownSample=function(t,e){var i=this.clone([t],!0),n=i._chunks,a=n[t],o=this.count(),s=0,u=Math.floor(1/e),l=this.getRawIndex(0),f,h,v,c=new(Fi(this._rawCount))(Math.min((Math.ceil(o/u)+2)*2,o));c[s++]=l;for(var p=1;p<o-1;p+=u){for(var d=Math.min(p+u,o-1),g=Math.min(p+u*2,o),y=(g+d)/2,m=0,_=d;_<g;_++){var S=this.getRawIndex(_),b=a[S];isNaN(b)||(m+=b)}m/=g-d;var w=p,x=Math.min(p+u,o),C=p-1,M=a[l];f=-1,v=w;for(var D=-1,A=0,_=w;_<x;_++){var S=this.getRawIndex(_),b=a[S];if(isNaN(b)){A++,D<0&&(D=S);continue}h=Math.abs((C-y)*(b-M)-(C-_)*(m-M)),h>f&&(f=h,v=S)}A>0&&A<x-w&&(c[s++]=Math.min(D,v),v=Math.max(D,v)),c[s++]=v,l=v}return c[s++]=this.getRawIndex(o-1),i._count=s,i._indices=c,i.getRawIndex=this._getRawIdx,i},r.prototype.minmaxDownSample=function(t,e){for(var i=this.clone([t],!0),n=i._chunks,a=Math.floor(1/e),o=n[t],s=this.count(),u=new(Fi(this._rawCount))(Math.ceil(s/a)*2),l=0,f=0;f<s;f+=a){var h=f,v=o[this.getRawIndex(h)],c=f,p=o[this.getRawIndex(c)],d=a;f+a>s&&(d=s-f);for(var g=0;g<d;g++){var y=this.getRawIndex(f+g),m=o[y];m<v&&(v=m,h=f+g),m>p&&(p=m,c=f+g)}var _=this.getRawIndex(h),S=this.getRawIndex(c);h<c?(u[l++]=_,u[l++]=S):(u[l++]=S,u[l++]=_)}return i._count=l,i._indices=u,i._updateGetRawIdx(),i},r.prototype.downSample=function(t,e,i,n){for(var a=this.clone([t],!0),o=a._chunks,s=[],u=Math.floor(1/e),l=o[t],f=this.count(),h=a._rawExtent[t]=zi(),v=new(Fi(this._rawCount))(Math.ceil(f/u)),c=0,p=0;p<f;p+=u){u>f-p&&(u=f-p,s.length=u);for(var d=0;d<u;d++){var g=this.getRawIndex(p+d);s[d]=l[g]}var y=i(s),m=this.getRawIndex(Math.min(p+n(s,y)||0,f-1));l[m]=y,y<h[0]&&(h[0]=y),y>h[1]&&(h[1]=y),v[c++]=m}return a._count=c,a._indices=v,a._updateGetRawIdx(),a},r.prototype.each=function(t,e){if(this._count)for(var i=t.length,n=this._chunks,a=0,o=this.count();a<o;a++){var s=this.getRawIndex(a);switch(i){case 0:e(a);break;case 1:e(n[t[0]][s],a);break;case 2:e(n[t[0]][s],n[t[1]][s],a);break;default:for(var u=0,l=[];u<i;u++)l[u]=n[t[u]][s];l[u]=a,e.apply(null,l)}}},r.prototype.getDataExtent=function(t){var e=this._chunks[t],i=zi();if(!e)return i;var n=this.count(),a=!this._indices,o;if(a)return this._rawExtent[t].slice();if(o=this._extent[t],o)return o.slice();o=i;for(var s=o[0],u=o[1],l=0;l<n;l++){var f=this.getRawIndex(l),h=e[f];h<s&&(s=h),h>u&&(u=h)}return o=[s,u],this._extent[t]=o,o},r.prototype.getRawDataItem=function(t){var e=this.getRawIndex(t);if(this._provider.persistent)return this._provider.getItem(e);for(var i=[],n=this._chunks,a=0;a<n.length;a++)i.push(n[a][e]);return i},r.prototype.clone=function(t,e){var i=new r,n=this._chunks,a=t&&Ti(t,function(s,u){return s[u]=!0,s},{});if(a)for(var o=0;o<n.length;o++)i._chunks[o]=a[o]?UT(n[o]):n[o];else i._chunks=n;return this._copyCommonProps(i),e||(i._indices=this._cloneIndices()),i._updateGetRawIdx(),i},r.prototype._copyCommonProps=function(t){t._count=this._count,t._rawCount=this._rawCount,t._provider=this._provider,t._dimensions=this._dimensions,t._extent=Y(this._extent),t._rawExtent=Y(this._rawExtent)},r.prototype._cloneIndices=function(){if(this._indices){var t=this._indices.constructor,e=void 0;if(t===Array){var i=this._indices.length;e=new t(i);for(var n=0;n<i;n++)e[n]=this._indices[n]}else e=new t(this._indices);return e}return null},r.prototype._getRawIdxIdentity=function(t){return t},r.prototype._getRawIdx=function(t){return t<this._count&&t>=0?this._indices[t]:-1},r.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},r.internalField=(function(){function t(e,i,n,a){return Cr(e[a],this._dimensions[a])}nl={arrayRows:t,objectRows:function(e,i,n,a){return Cr(e[i],this._dimensions[a])},keyedColumns:t,original:function(e,i,n,a){var o=e&&(e.value==null?e:e.value);return Cr(o instanceof Array?o[a]:o,this._dimensions[a])},typedArray:function(e,i,n,a){return e[a]}}})(),r})(),YT=(function(){function r(t){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=t}return r.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},r.prototype._setLocalSource=function(t,e){this._sourceList=t,this._upstreamSignList=e,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},r.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},r.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},r.prototype._createSource=function(){this._setLocalSource([],[]);var t=this._sourceHost,e=this._getUpstreamSourceManagers(),i=!!e.length,n,a;if(uo(t)){var o=t,s=void 0,u=void 0,l=void 0;if(i){var f=e[0];f.prepareSource(),l=f.getSource(),s=l.data,u=l.sourceFormat,a=[f._getVersionSign()]}else s=o.get("data",!0),u=Yt(s)?Mr:ge,a=[];var h=this._getSourceMetaRawOption()||{},v=l&&l.metaRawOption||{},c=$(h.seriesLayoutBy,v.seriesLayoutBy)||null,p=$(h.sourceHeader,v.sourceHeader),d=$(h.dimensions,v.dimensions),g=c!==v.seriesLayoutBy||!!p!=!!v.sourceHeader||d;n=g?[Af(s,{seriesLayoutBy:c,sourceHeader:p,dimensions:d},u)]:[]}else{var y=t;if(i){var m=this._applyTransform(e);n=m.sourceList,a=m.upstreamSignList}else{var _=y.get("source",!0);n=[Af(_,this._getSourceMetaRawOption(),null)],a=[]}}this._setLocalSource(n,a)},r.prototype._applyTransform=function(t){var e=this._sourceHost,i=e.get("transform",!0),n=e.get("fromTransformResult",!0);if(n!=null){var a="";t.length!==1&&xp(a)}var o,s=[],u=[];return T(t,function(l){l.prepareSource();var f=l.getSource(n||0),h="";n!=null&&!f&&xp(h),s.push(f),u.push(l._getVersionSign())}),i?o=VT(i,s,{datasetIndex:e.componentIndex}):n!=null&&(o=[TT(s[0])]),{sourceList:o,upstreamSignList:u}},r.prototype._isDirty=function(){if(this._dirty)return!0;for(var t=this._getUpstreamSourceManagers(),e=0;e<t.length;e++){var i=t[e];if(i._isDirty()||this._upstreamSignList[e]!==i._getVersionSign())return!0}},r.prototype.getSource=function(t){t=t||0;var e=this._sourceList[t];if(!e){var i=this._getUpstreamSourceManagers();return i[0]&&i[0].getSource(t)}return e},r.prototype.getSharedDataStore=function(t){var e=t.makeStoreSchema();return this._innerGetDataStore(e.dimensions,t.source,e.hash)},r.prototype._innerGetDataStore=function(t,e,i){var n=0,a=this._storeList,o=a[n];o||(o=a[n]={});var s=o[i];if(!s){var u=this._getUpstreamSourceManagers()[0];uo(this._sourceHost)&&u?s=u._innerGetDataStore(t,e,i):(s=new Lf,s.initData(new jm(e,t.length),t)),o[i]=s}return s},r.prototype._getUpstreamSourceManagers=function(){var t=this._sourceHost;if(uo(t)){var e=Ym(t);return e?[e.getSourceManager()]:[]}else return z(Jx(t),function(i){return i.getSourceManager()})},r.prototype._getSourceMetaRawOption=function(){var t=this._sourceHost,e,i,n;if(uo(t))e=t.get("seriesLayoutBy",!0),i=t.get("sourceHeader",!0),n=t.get("dimensions",!0);else if(!this._getUpstreamSourceManagers().length){var a=t;e=a.get("seriesLayoutBy",!0),i=a.get("sourceHeader",!0),n=a.get("dimensions",!0)}return{seriesLayoutBy:e,sourceHeader:i,dimensions:n}},r})();function uo(r){return r.mainType==="series"}function xp(r){throw new Error(r)}var ZT="line-height:1";function o0(r){var t=r.lineHeight;return t==null?ZT:"line-height:"+Gt(t+"")+"px"}function s0(r,t){var e=r.color||"#6e7079",i=r.fontSize||12,n=r.fontWeight||"400",a=r.color||"#464646",o=r.fontSize||14,s=r.fontWeight||"900";return t==="html"?{nameStyle:"font-size:"+Gt(i+"")+"px;color:"+Gt(e)+";font-weight:"+Gt(n+""),valueStyle:"font-size:"+Gt(o+"")+"px;color:"+Gt(a)+";font-weight:"+Gt(s+"")}:{nameStyle:{fontSize:i,fill:e,fontWeight:n},valueStyle:{fontSize:o,fill:a,fontWeight:s}}}var XT=[0,10,20,30],$T=["",`
30
+ `,`
31
+
32
+ `,`
33
+
34
+
35
+ `];function Si(r,t){return t.type=r,t}function Pf(r){return r.type==="section"}function u0(r){return Pf(r)?qT:KT}function l0(r){if(Pf(r)){var t=0,e=r.blocks.length,i=e>1||e>0&&!r.noHeader;return T(r.blocks,function(n){var a=l0(n);a>=t&&(t=a+ +(i&&(!a||Pf(n)&&!n.noHeader)))}),t}return 0}function qT(r,t,e,i){var n=t.noHeader,a=QT(l0(t)),o=[],s=t.blocks||[];ze(!s||B(s)),s=s||[];var u=r.orderMode;if(t.sortBlocks&&u){s=s.slice();var l={valueAsc:"asc",valueDesc:"desc"};if(N(l,u)){var f=new RT(l[u],null);s.sort(function(d,g){return f.evaluate(d.sortParam,g.sortParam)})}else u==="seriesDesc"&&s.reverse()}T(s,function(d,g){var y=t.valueFormatter,m=u0(d)(y?k(k({},r),{valueFormatter:y}):r,d,g>0?a.html:0,i);m!=null&&o.push(m)});var h=r.renderMode==="richText"?o.join(a.richText):If(i,o.join(""),n?e:a.html);if(n)return h;var v=Df(t.header,"ordinal",r.useUTC),c=s0(i,r.renderMode).nameStyle,p=o0(i);return r.renderMode==="richText"?f0(r,v,c)+a.richText+h:If(i,'<div style="'+c+";"+p+';">'+Gt(v)+"</div>"+h,e)}function KT(r,t,e,i){var n=r.renderMode,a=t.noName,o=t.noValue,s=!t.markerType,u=t.name,l=r.useUTC,f=t.valueFormatter||r.valueFormatter||function(S){return S=B(S)?S:[S],z(S,function(b,w){return Df(b,B(c)?c[w]:c,l)})};if(!(a&&o)){var h=s?"":r.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||"#333",n),v=a?"":Df(u,"ordinal",l),c=t.valueType,p=o?[]:f(t.value,t.dataIndex),d=!s||!a,g=!s&&a,y=s0(i,n),m=y.nameStyle,_=y.valueStyle;return n==="richText"?(s?"":h)+(a?"":f0(r,v,m))+(o?"":tM(r,p,d,g,_)):If(i,(s?"":h)+(a?"":JT(v,!s,m))+(o?"":jT(p,d,g,_)),e)}}function Tp(r,t,e,i,n,a){if(r){var o=u0(r),s={useUTC:n,renderMode:e,orderMode:i,markupStyleCreator:t,valueFormatter:r.valueFormatter};return o(s,r,0,a)}}function QT(r){return{html:XT[r],richText:$T[r]}}function If(r,t,e){var i='<div style="clear:both"></div>',n="margin: "+e+"px 0 0",a=o0(r);return'<div style="'+n+";"+a+';">'+t+i+"</div>"}function JT(r,t,e){var i=t?"margin-left:2px":"";return'<span style="'+e+";"+i+'">'+Gt(r)+"</span>"}function jT(r,t,e,i){var n=e?"10px":"20px",a=t?"float:right;margin-left:"+n:"";return r=B(r)?r:[r],'<span style="'+a+";"+i+'">'+z(r,function(o){return Gt(o)}).join("&nbsp;&nbsp;")+"</span>"}function f0(r,t,e){return r.markupStyleCreator.wrapRichTextStyle(t,e)}function tM(r,t,e,i,n){var a=[n],o=i?10:20;return e&&a.push({padding:[0,0,0,o],align:"right"}),r.markupStyleCreator.wrapRichTextStyle(B(t)?t.join(" "):t,a)}function eM(r,t){var e=r.getData().getItemVisual(t,"style"),i=e[r.visualDrawType];return _i(i)}function h0(r,t){var e=r.get("padding");return e??(t==="richText"?[8,10]:10)}var al=(function(){function r(){this.richTextStyles={},this._nextStyleNameId=Ry()}return r.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},r.prototype.makeTooltipMarker=function(t,e,i){var n=i==="richText"?this._generateStyleName():null,a=Ux({color:e,type:t,renderMode:i,markerId:n});return H(a)?a:(this.richTextStyles[n]=a.style,a.content)},r.prototype.wrapRichTextStyle=function(t,e){var i={};B(e)?T(e,function(a){return k(i,a)}):k(i,e);var n=this._generateStyleName();return this.richTextStyles[n]=i,"{"+n+"|"+t+"}"},r})();function rM(r){var t=r.series,e=r.dataIndex,i=r.multipleSeries,n=t.getData(),a=n.mapDimensionsAll("defaultedTooltip"),o=a.length,s=t.getRawValue(e),u=B(s),l=eM(t,e),f,h,v,c;if(o>1||u&&!o){var p=iM(s,t,e,a,l);f=p.inlineValues,h=p.inlineValueTypes,v=p.blocks,c=p.inlineValues[0]}else if(o){var d=n.getDimensionInfo(a[0]);c=f=cn(n,e,a[0]),h=d.type}else c=f=u?s[0]:s;var g=By(t),y=g&&t.name||"",m=n.getName(e),_=i?y:m;return Si("section",{header:y,noHeader:i||!g,sortParam:c,blocks:[Si("nameValue",{markerType:"item",markerColor:l,name:_,noName:!Oe(_),value:f,valueType:h,dataIndex:e})].concat(v||[])})}function iM(r,t,e,i,n){var a=t.getData(),o=Ti(r,function(h,v,c){var p=a.getDimensionInfo(c);return h=h||p&&p.tooltip!==!1&&p.displayName!=null},!1),s=[],u=[],l=[];i.length?T(i,function(h){f(cn(a,e,h),h)}):T(r,f);function f(h,v){var c=a.getDimensionInfo(v);!c||c.otherDims.tooltip===!1||(o?l.push(Si("nameValue",{markerType:"subItem",markerColor:n,name:c.displayName,value:h,valueType:c.type})):(s.push(h),u.push(c.type)))}return{inlineValues:s,inlineValueTypes:u,blocks:l}}var fr=vt();function lo(r,t){return r.getName(t)||r.getId(t)}var nM="__universalTransitionEnabled",He=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e._selectedDataIndicesMap={},e}return t.prototype.init=function(e,i,n){this.seriesIndex=this.componentIndex,this.dataTask=pa({count:oM,reset:sM}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(e,n);var a=fr(this).sourceManager=new YT(this);a.prepareSource();var o=this.getInitialData(e,n);Cp(o,this),this.dataTask.context.data=o,fr(this).dataBeforeProcessed=o,Mp(this),this._initSelectedMapFromData(o)},t.prototype.mergeDefaultAndTheme=function(e,i){var n=Da(this),a=n?js(e):{},o=this.subType;nt.hasClass(o)&&(o+="Series"),tt(e,i.getTheme().get(this.subType)),tt(e,this.getDefaultOption()),df(e,"label",["show"]),this.fillDataTextStyle(e.data),n&&Aa(e,a,n)},t.prototype.mergeOption=function(e,i){e=tt(this.option,e,!0),this.fillDataTextStyle(e.data);var n=Da(this);n&&Aa(this.option,e,n);var a=fr(this).sourceManager;a.dirty(),a.prepareSource();var o=this.getInitialData(e,i);Cp(o,this),this.dataTask.dirty(),this.dataTask.context.data=o,fr(this).dataBeforeProcessed=o,Mp(this),this._initSelectedMapFromData(o)},t.prototype.fillDataTextStyle=function(e){if(e&&!Yt(e))for(var i=["show"],n=0;n<e.length;n++)e[n]&&e[n].label&&df(e[n],"label",i)},t.prototype.getInitialData=function(e,i){},t.prototype.appendData=function(e){var i=this.getRawData();i.appendData(e.data)},t.prototype.getData=function(e){var i=Rf(this);if(i){var n=i.context.data;return e==null||!n.getLinkedData?n:n.getLinkedData(e)}else return fr(this).data},t.prototype.getAllData=function(){var e=this.getData();return e&&e.getLinkedDataAll?e.getLinkedDataAll():[{data:e}]},t.prototype.setData=function(e){var i=Rf(this);if(i){var n=i.context;n.outputData=e,i!==this.dataTask&&(n.data=e)}fr(this).data=e},t.prototype.getEncode=function(){var e=this.get("encode",!0);if(e)return X(e)},t.prototype.getSourceManager=function(){return fr(this).sourceManager},t.prototype.getSource=function(){return this.getSourceManager().getSource()},t.prototype.getRawData=function(){return fr(this).dataBeforeProcessed},t.prototype.getColorBy=function(){var e=this.get("colorBy");return e||"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.formatTooltip=function(e,i,n){return rM({series:this,dataIndex:e,multipleSeries:i})},t.prototype.isAnimationEnabled=function(){var e=this.ecModel;if(Z.node&&!(e&&e.ssr))return!1;var i=this.getShallow("animation");return i&&this.getData().count()>this.getShallow("animationThreshold")&&(i=!1),!!i},t.prototype.restoreData=function(){this.dataTask.dirty()},t.prototype.getColorFromPalette=function(e,i,n){var a=this.ecModel,o=Wh.prototype.getColorFromPalette.call(this,e,i,n);return o||(o=a.getColorFromPalette(e,i,n)),o},t.prototype.coordDimToDataDim=function(e){return this.getRawData().mapDimensionsAll(e)},t.prototype.getProgressive=function(){return this.get("progressive")},t.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},t.prototype.select=function(e,i){this._innerSelect(this.getData(i),e)},t.prototype.unselect=function(e,i){var n=this.option.selectedMap;if(n){var a=this.option.selectedMode,o=this.getData(i);if(a==="series"||n==="all"){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var s=0;s<e.length;s++){var u=e[s],l=lo(o,u);n[l]=!1,this._selectedDataIndicesMap[l]=-1}}},t.prototype.toggleSelect=function(e,i){for(var n=[],a=0;a<e.length;a++)n[0]=e[a],this.isSelected(e[a],i)?this.unselect(n,i):this.select(n,i)},t.prototype.getSelectedDataIndices=function(){if(this.option.selectedMap==="all")return[].slice.call(this.getData().getIndices());for(var e=this._selectedDataIndicesMap,i=ft(e),n=[],a=0;a<i.length;a++){var o=e[i[a]];o>=0&&n.push(o)}return n},t.prototype.isSelected=function(e,i){var n=this.option.selectedMap;if(!n)return!1;var a=this.getData(i);return(n==="all"||n[lo(a,e)])&&!a.getItemModel(e).get(["select","disabled"])},t.prototype.isUniversalTransitionEnabled=function(){if(this[nM])return!0;var e=this.option.universalTransition;return e?e===!0?!0:e&&e.enabled:!1},t.prototype._innerSelect=function(e,i){var n,a,o=this.option,s=o.selectedMode,u=i.length;if(!(!s||!u)){if(s==="series")o.selectedMap="all";else if(s==="multiple"){W(o.selectedMap)||(o.selectedMap={});for(var l=o.selectedMap,f=0;f<u;f++){var h=i[f],v=lo(e,h);l[v]=!0,this._selectedDataIndicesMap[v]=e.getRawIndex(h)}}else if(s==="single"||s===!0){var c=i[u-1],v=lo(e,c);o.selectedMap=(n={},n[v]=!0,n),this._selectedDataIndicesMap=(a={},a[v]=e.getRawIndex(c),a)}}},t.prototype._initSelectedMapFromData=function(e){if(!this.option.selectedMap){var i=[];e.hasItemOption&&e.each(function(n){var a=e.getRawDataItem(n);a&&a.selected&&i.push(n)}),i.length>0&&this._innerSelect(e,i)}},t.registerClass=function(e){return nt.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})(nt);Ce(He,$h);Ce(He,Wh);Vy(He,nt);function Mp(r){var t=r.name;By(r)||(r.name=aM(r)||t)}function aM(r){var t=r.getRawData(),e=t.mapDimensionsAll("seriesName"),i=[];return T(e,function(n){var a=t.getDimensionInfo(n);a.displayName&&i.push(a.displayName)}),i.join(" ")}function oM(r){return r.model.getRawData().count()}function sM(r){var t=r.model;return t.setData(t.getRawData().cloneShallow()),uM}function uM(r,t){t.outputData&&r.end>t.outputData.count()&&t.model.getRawData().cloneShallow(t.outputData)}function Cp(r,t){T(F1(r.CHANGABLE_METHODS,r.DOWNSAMPLE_METHODS),function(e){r.wrapMethod(e,ot(lM,t))})}function lM(r,t){var e=Rf(r);return e&&e.setOutputEnd((t||this).count()),t}function Rf(r){var t=(r.ecModel||{}).scheduler,e=t&&t.getPipeline(r.uid);if(e){var i=e.currentTask;if(i){var n=i.agentStubMap;n&&(i=n.get(r.uid))}return i}}var $t=(function(){function r(){this.group=new gt,this.uid=Xs("viewComponent")}return r.prototype.init=function(t,e){},r.prototype.render=function(t,e,i,n){},r.prototype.dispose=function(t,e){},r.prototype.updateView=function(t,e,i,n){},r.prototype.updateLayout=function(t,e,i,n){},r.prototype.updateVisual=function(t,e,i,n){},r.prototype.toggleBlurSeries=function(t,e,i){},r.prototype.eachRendered=function(t){var e=this.group;e&&e.traverse(t)},r})();Th($t);Rs($t);function v0(){var r=vt();return function(t){var e=r(t),i=t.pipelineContext,n=!!e.large,a=!!e.progressiveRender,o=e.large=!!(i&&i.large),s=e.progressiveRender=!!(i&&i.progressiveRender);return(n!==o||a!==s)&&"reset"}}var c0=vt(),fM=v0(),ce=(function(){function r(){this.group=new gt,this.uid=Xs("viewChart"),this.renderTask=pa({plan:hM,reset:vM}),this.renderTask.context={view:this}}return r.prototype.init=function(t,e){},r.prototype.render=function(t,e,i,n){},r.prototype.highlight=function(t,e,i,n){var a=t.getData(n&&n.dataType);a&&Ap(a,n,"emphasis")},r.prototype.downplay=function(t,e,i,n){var a=t.getData(n&&n.dataType);a&&Ap(a,n,"normal")},r.prototype.remove=function(t,e){this.group.removeAll()},r.prototype.dispose=function(t,e){},r.prototype.updateView=function(t,e,i,n){this.render(t,e,i,n)},r.prototype.updateLayout=function(t,e,i,n){this.render(t,e,i,n)},r.prototype.updateVisual=function(t,e,i,n){this.render(t,e,i,n)},r.prototype.eachRendered=function(t){Va(this.group,t)},r.markUpdateMethod=function(t,e){c0(t).updateMethod=e},r.protoInitialize=(function(){var t=r.prototype;t.type="chart"})(),r})();function Dp(r,t,e){r&&bf(r)&&(t==="emphasis"?ba:xa)(r,e)}function Ap(r,t,e){var i=yi(r,t),n=t&&t.highlightKey!=null?Eb(t.highlightKey):null;i!=null?T(Ct(i),function(a){Dp(r.getItemGraphicEl(a),e,n)}):r.eachItemGraphicEl(function(a){Dp(a,e,n)})}Th(ce);Rs(ce);function hM(r){return fM(r.model)}function vM(r){var t=r.model,e=r.ecModel,i=r.api,n=r.payload,a=t.pipelineContext.progressiveRender,o=r.view,s=n&&c0(n).updateMethod,u=a?"incrementalPrepareRender":s&&o[s]?s:"render";return u!=="render"&&o[u](t,e,i,n),cM[u]}var cM={incrementalPrepareRender:{progress:function(r,t){t.view.incrementalRender(r,t.model,t.ecModel,t.api,t.payload)}},render:{forceFirstProgress:!0,progress:function(r,t){t.view.render(t.model,t.ecModel,t.api,t.payload)}}},ls="\0__throttleOriginMethod",Lp="\0__throttleRate",Pp="\0__throttleType";function p0(r,t,e){var i,n=0,a=0,o=null,s,u,l,f;t=t||0;function h(){a=new Date().getTime(),o=null,r.apply(u,l||[])}var v=function(){for(var c=[],p=0;p<arguments.length;p++)c[p]=arguments[p];i=new Date().getTime(),u=this,l=c;var d=f||t,g=f||e;f=null,s=i-(g?n:a)-d,clearTimeout(o),g?o=setTimeout(h,d):s>=0?h():o=setTimeout(h,-s),n=i};return v.clear=function(){o&&(clearTimeout(o),o=null)},v.debounceNextCall=function(c){f=c},v}function Ha(r,t,e,i){var n=r[t];if(n){var a=n[ls]||n,o=n[Pp],s=n[Lp];if(s!==e||o!==i){if(e==null||!i)return r[t]=a;n=r[t]=p0(a,e,i==="debounce"),n[ls]=a,n[Pp]=i,n[Lp]=e}return n}}function fs(r,t){var e=r[t];e&&e[ls]&&(e.clear&&e.clear(),r[t]=e[ls])}var Ip=vt(),Rp={itemStyle:wa(Mm,!0),lineStyle:wa(Tm,!0)},pM={lineStyle:"stroke",itemStyle:"fill"};function d0(r,t){var e=r.visualStyleMapper||Rp[t];return e||(console.warn("Unknown style type '"+t+"'."),Rp.itemStyle)}function g0(r,t){var e=r.visualDrawType||pM[t];return e||(console.warn("Unknown style type '"+t+"'."),"fill")}var dM={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){var e=r.getData(),i=r.visualStyleAccessPath||"itemStyle",n=r.getModel(i),a=d0(r,i),o=a(n),s=n.getShallow("decal");s&&(e.setVisual("decal",s),s.dirty=!0);var u=g0(r,i),l=o[u],f=q(l)?l:null,h=o.fill==="auto"||o.stroke==="auto";if(!o[u]||f||h){var v=r.getColorFromPalette(r.name,null,t.getSeriesCount());o[u]||(o[u]=v,e.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||q(o.fill)?v:o.fill,o.stroke=o.stroke==="auto"||q(o.stroke)?v:o.stroke}if(e.setVisual("style",o),e.setVisual("drawType",u),!t.isSeriesFiltered(r)&&f)return e.setVisual("colorFromPalette",!1),{dataEach:function(c,p){var d=r.getDataParams(p),g=k({},o);g[u]=f(d),c.setItemVisual(p,"style",g)}}}},kn=new St,gM={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){if(!(r.ignoreStyleOnData||t.isSeriesFiltered(r))){var e=r.getData(),i=r.visualStyleAccessPath||"itemStyle",n=d0(r,i),a=e.getVisual("drawType");return{dataEach:e.hasItemOption?function(o,s){var u=o.getRawDataItem(s);if(u&&u[i]){kn.option=u[i];var l=n(kn),f=o.ensureUniqueItemVisual(s,"style");k(f,l),kn.option.decal&&(o.setItemVisual(s,"decal",kn.option.decal),kn.option.decal.dirty=!0),a in l&&o.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},yM={performRawSeries:!0,overallReset:function(r){var t=X();r.eachSeries(function(e){var i=e.getColorBy();if(!e.isColorBySeries()){var n=e.type+"-"+i,a=t.get(n);a||(a={},t.set(n,a)),Ip(e).scope=a}}),r.eachSeries(function(e){if(!(e.isColorBySeries()||r.isSeriesFiltered(e))){var i=e.getRawData(),n={},a=e.getData(),o=Ip(e).scope,s=e.visualStyleAccessPath||"itemStyle",u=g0(e,s);a.each(function(l){var f=a.getRawIndex(l);n[f]=l}),i.each(function(l){var f=n[l],h=a.getItemVisual(f,"colorFromPalette");if(h){var v=a.ensureUniqueItemVisual(f,"style"),c=i.getName(l)||l+"",p=i.count();v[u]=e.getColorFromPalette(c,o,p)}})}})}},fo=Math.PI;function mM(r,t){t=t||{},rt(t,{text:"loading",textColor:"#000",fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255, 255, 255, 0.8)",showSpinner:!0,color:"#5470c6",spinnerRadius:10,lineWidth:5,zlevel:0});var e=new gt,i=new Tt({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4});e.add(i);var n=new te({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 Tt({style:{fill:"none"},textContent:n,textConfig:{position:"right",distance:10},zlevel:t.zlevel,z:10001});e.add(a);var o;return t.showSpinner&&(o=new Hs({shape:{startAngle:-fo/2,endAngle:-fo/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:fo*3/2}).start("circularInOut"),o.animateShape(!0).when(1e3,{startAngle:fo*3/2}).delay(300).start("circularInOut"),e.add(o)),e.resize=function(){var s=n.getBoundingRect().width,u=t.showSpinner?t.spinnerRadius:0,l=(r.getWidth()-u*2-(t.showSpinner&&s?10:0)-s)/2-(t.showSpinner&&s?0:5+s/2)+(t.showSpinner?0:s/2)+(s?0:u),f=r.getHeight()/2;t.showSpinner&&o.setShape({cx:l,cy:f}),a.setShape({x:l-u,y:f-u,width:u*2,height:u*2}),i.setShape({x:0,y:0,width:r.getWidth(),height:r.getHeight()})},e.resize(),e}var y0=(function(){function r(t,e,i,n){this._stageTaskMap=X(),this.ecInstance=t,this.api=e,i=this._dataProcessorHandlers=i.slice(),n=this._visualHandlers=n.slice(),this._allHandlers=i.concat(n)}return r.prototype.restoreData=function(t,e){t.restoreData(e),this._stageTaskMap.each(function(i){var n=i.overallTask;n&&n.dirty()})},r.prototype.getPerformArgs=function(t,e){if(t.__pipeline){var i=this._pipelineMap.get(t.__pipeline.id),n=i.context,a=!e&&i.progressiveEnabled&&(!n||n.progressiveRender)&&t.__idxInPipeline>i.blockIndex,o=a?i.step:null,s=n&&n.modDataCount,u=s!=null?Math.ceil(s/o):null;return{step:o,modBy:u,modDataCount:s}}},r.prototype.getPipeline=function(t){return this._pipelineMap.get(t)},r.prototype.updateStreamModes=function(t,e){var i=this._pipelineMap.get(t.uid),n=t.getData(),a=n.count(),o=i.progressiveEnabled&&e.incrementalPrepareRender&&a>=i.threshold,s=t.get("large")&&a>=t.get("largeThreshold"),u=t.get("progressiveChunkMode")==="mod"?a:null;t.pipelineContext=i.context={progressiveRender:o,modDataCount:u,large:s}},r.prototype.restorePipelines=function(t){var e=this,i=e._pipelineMap=X();t.eachSeries(function(n){var a=n.getProgressive(),o=n.uid;i.set(o,{id:o,head:null,tail:null,threshold:n.getProgressiveThreshold(),progressiveEnabled:a&&!(n.preventIncremental&&n.preventIncremental()),blockIndex:-1,step:Math.round(a||700),count:0}),e._pipe(n,n.dataTask)})},r.prototype.prepareStageTasks=function(){var t=this._stageTaskMap,e=this.api.getModel(),i=this.api;T(this._allHandlers,function(n){var a=t.get(n.uid)||t.set(n.uid,{}),o="";ze(!(n.reset&&n.overallReset),o),n.reset&&this._createSeriesStageTask(n,a,e,i),n.overallReset&&this._createOverallStageTask(n,a,e,i)},this)},r.prototype.prepareView=function(t,e,i,n){var a=t.renderTask,o=a.context;o.model=e,o.ecModel=i,o.api=n,a.__block=!t.incrementalPrepareRender,this._pipe(e,a)},r.prototype.performDataProcessorTasks=function(t,e){this._performStageTasks(this._dataProcessorHandlers,t,e,{block:!0})},r.prototype.performVisualTasks=function(t,e,i){this._performStageTasks(this._visualHandlers,t,e,i)},r.prototype._performStageTasks=function(t,e,i,n){n=n||{};var a=!1,o=this;T(t,function(u,l){if(!(n.visualType&&n.visualType!==u.visualType)){var f=o._stageTaskMap.get(u.uid),h=f.seriesTaskMap,v=f.overallTask;if(v){var c,p=v.agentStubMap;p.each(function(g){s(n,g)&&(g.dirty(),c=!0)}),c&&v.dirty(),o.updatePayload(v,i);var d=o.getPerformArgs(v,n.block);p.each(function(g){g.perform(d)}),v.perform(d)&&(a=!0)}else h&&h.each(function(g,y){s(n,g)&&g.dirty();var m=o.getPerformArgs(g,n.block);m.skip=!u.performRawSeries&&e.isSeriesFiltered(g.context.model),o.updatePayload(g,i),g.perform(m)&&(a=!0)})}});function s(u,l){return u.setDirty&&(!u.dirtyMap||u.dirtyMap.get(l.__pipeline.id))}this.unfinished=a||this.unfinished},r.prototype.performSeriesTasks=function(t){var e;t.eachSeries(function(i){e=i.dataTask.perform()||e}),this.unfinished=e||this.unfinished},r.prototype.plan=function(){this._pipelineMap.each(function(t){var e=t.tail;do{if(e.__block){t.blockIndex=e.__idxInPipeline;break}e=e.getUpstream()}while(e)})},r.prototype.updatePayload=function(t,e){e!=="remain"&&(t.context.payload=e)},r.prototype._createSeriesStageTask=function(t,e,i,n){var a=this,o=e.seriesTaskMap,s=e.seriesTaskMap=X(),u=t.seriesType,l=t.getTargetSeries;t.createOnAllSeries?i.eachRawSeries(f):u?i.eachRawSeriesByType(u,f):l&&l(i,n).each(f);function f(h){var v=h.uid,c=s.set(v,o&&o.get(v)||pa({plan:xM,reset:TM,count:CM}));c.context={model:h,ecModel:i,api:n,useClearVisual:t.isVisual&&!t.isLayout,plan:t.plan,reset:t.reset,scheduler:a},a._pipe(h,c)}},r.prototype._createOverallStageTask=function(t,e,i,n){var a=this,o=e.overallTask=e.overallTask||pa({reset:_M});o.context={ecModel:i,api:n,overallReset:t.overallReset,scheduler:a};var s=o.agentStubMap,u=o.agentStubMap=X(),l=t.seriesType,f=t.getTargetSeries,h=!0,v=!1,c="";ze(!t.createOnAllSeries,c),l?i.eachRawSeriesByType(l,p):f?f(i,n).each(p):(h=!1,T(i.getSeries(),p));function p(d){var g=d.uid,y=u.set(g,s&&s.get(g)||(v=!0,pa({reset:SM,onDirty:bM})));y.context={model:d,overallProgress:h},y.agent=o,y.__block=h,a._pipe(d,y)}v&&o.dirty()},r.prototype._pipe=function(t,e){var i=t.uid,n=this._pipelineMap.get(i);!n.head&&(n.head=e),n.tail&&n.tail.pipe(e),n.tail=e,e.__idxInPipeline=n.count++,e.__pipeline=n},r.wrapStageHandler=function(t,e){return q(t)&&(t={overallReset:t,seriesType:DM(t)}),t.uid=Xs("stageHandler"),e&&(t.visualType=e),t},r})();function _M(r){r.overallReset(r.ecModel,r.api,r.payload)}function SM(r){return r.overallProgress&&wM}function wM(){this.agent.dirty(),this.getDownstream().dirty()}function bM(){this.agent&&this.agent.dirty()}function xM(r){return r.plan?r.plan(r.model,r.ecModel,r.api,r.payload):null}function TM(r){r.useClearVisual&&r.data.clearAllVisual();var t=r.resetDefines=Ct(r.reset(r.model,r.ecModel,r.api,r.payload));return t.length>1?z(t,function(e,i){return m0(i)}):MM}var MM=m0(0);function m0(r){return function(t,e){var i=e.data,n=e.resetDefines[r];if(n&&n.dataEach)for(var a=t.start;a<t.end;a++)n.dataEach(i,a);else n&&n.progress&&n.progress(t,i)}}function CM(r){return r.data.count()}function DM(r){hs=null;try{r(Pa,_0)}catch{}return hs}var Pa={},_0={},hs;S0(Pa,Uh);S0(_0,Xm);Pa.eachSeriesByType=Pa.eachRawSeriesByType=function(r){hs=r};Pa.eachComponent=function(r){r.mainType==="series"&&r.subType&&(hs=r.subType)};function S0(r,t){for(var e in t.prototype)r[e]=At}var Ep=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"];const AM={color:Ep,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],Ep]};var Rt="#B9B8CE",kp="#100C2A",ho=function(){return{axisLine:{lineStyle:{color:Rt}},splitLine:{lineStyle:{color:"#484753"}},splitArea:{areaStyle:{color:["rgba(255,255,255,0.02)","rgba(255,255,255,0.05)"]}},minorSplitLine:{lineStyle:{color:"#20203B"}}}},Op=["#4992ff","#7cffb2","#fddd60","#ff6e76","#58d9f9","#05c091","#ff8a45","#8d48e3","#dd79ff"],w0={darkMode:!0,color:Op,backgroundColor:kp,axisPointer:{lineStyle:{color:"#817f91"},crossStyle:{color:"#817f91"},label:{color:"#fff"}},legend:{textStyle:{color:Rt},pageTextStyle:{color:Rt}},textStyle:{color:Rt},title:{textStyle:{color:"#EEF1FA"},subtextStyle:{color:"#B9B8CE"}},toolbox:{iconStyle:{borderColor:Rt}},dataZoom:{borderColor:"#71708A",textStyle:{color:Rt},brushStyle:{color:"rgba(135,163,206,0.3)"},handleStyle:{color:"#353450",borderColor:"#C5CBE3"},moveHandleStyle:{color:"#B0B6C3",opacity:.3},fillerColor:"rgba(135,163,206,0.2)",emphasis:{handleStyle:{borderColor:"#91B7F2",color:"#4D587D"},moveHandleStyle:{color:"#636D9A",opacity:.7}},dataBackground:{lineStyle:{color:"#71708A",width:1},areaStyle:{color:"#71708A"}},selectedDataBackground:{lineStyle:{color:"#87A3CE"},areaStyle:{color:"#87A3CE"}}},visualMap:{textStyle:{color:Rt}},timeline:{lineStyle:{color:Rt},label:{color:Rt},controlStyle:{color:Rt,borderColor:Rt}},calendar:{itemStyle:{color:kp},dayLabel:{color:Rt},monthLabel:{color:Rt},yearLabel:{color:Rt}},timeAxis:ho(),logAxis:ho(),valueAxis:ho(),categoryAxis:ho(),line:{symbol:"circle"},graph:{color:Op},gauge:{title:{color:Rt},axisLine:{lineStyle:{color:[[1,"rgba(207,212,219,0.2)"]]}},axisLabel:{color:Rt},detail:{color:"#EEF1FA"}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}}};w0.categoryAxis.splitLine.show=!1;var LM=(function(){function r(){}return r.prototype.normalizeQuery=function(t){var e={},i={},n={};if(H(t)){var a=Ne(t);e.mainType=a.main||null,e.subType=a.sub||null}else{var o=["Index","Name","Id"],s={name:1,dataIndex:1,dataType:1};T(t,function(u,l){for(var f=!1,h=0;h<o.length;h++){var v=o[h],c=l.lastIndexOf(v);if(c>0&&c===l.length-v.length){var p=l.slice(0,c);p!=="data"&&(e.mainType=p,e[v.toLowerCase()]=u,f=!0)}}s.hasOwnProperty(l)&&(i[l]=u,f=!0),f||(n[l]=u)})}return{cptQuery:e,dataQuery:i,otherQuery:n}},r.prototype.filter=function(t,e){var i=this.eventInfo;if(!i)return!0;var n=i.targetEl,a=i.packedEvent,o=i.model,s=i.view;if(!o||!s)return!0;var u=e.cptQuery,l=e.dataQuery;return f(u,o,"mainType")&&f(u,o,"subType")&&f(u,o,"index","componentIndex")&&f(u,o,"name")&&f(u,o,"id")&&f(l,a,"name")&&f(l,a,"dataIndex")&&f(l,a,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(t,e.otherQuery,n,a));function f(h,v,c,p){return h[c]==null||v[p||c]===h[c]}},r.prototype.afterTrigger=function(){this.eventInfo=null},r})(),Ef=["symbol","symbolSize","symbolRotate","symbolOffset"],Bp=Ef.concat(["symbolKeepAspect"]),PM={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){var e=r.getData();if(r.legendIcon&&e.setVisual("legendIcon",r.legendIcon),!r.hasSymbolVisual)return;for(var i={},n={},a=!1,o=0;o<Ef.length;o++){var s=Ef[o],u=r.get(s);q(u)?(a=!0,n[s]=u):i[s]=u}if(i.symbol=i.symbol||r.defaultSymbol,e.setVisual(k({legendIcon:r.legendIcon||i.symbol,symbolKeepAspect:r.get("symbolKeepAspect")},i)),t.isSeriesFiltered(r))return;var l=ft(n);function f(h,v){for(var c=r.getRawValue(v),p=r.getDataParams(v),d=0;d<l.length;d++){var g=l[d];h.setItemVisual(v,g,n[g](c,p))}}return{dataEach:a?f:null}}},IM={createOnAllSeries:!0,performRawSeries:!0,reset:function(r,t){if(!r.hasSymbolVisual||t.isSeriesFiltered(r))return;var e=r.getData();function i(n,a){for(var o=n.getItemModel(a),s=0;s<Bp.length;s++){var u=Bp[s],l=o.getShallow(u,!0);l!=null&&n.setItemVisual(a,u,l)}}return{dataEach:e.hasItemOption?i:null}}};function b0(r,t,e){switch(e){case"color":var i=r.getItemVisual(t,"style");return i[r.getVisual("drawType")];case"opacity":return r.getItemVisual(t,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getItemVisual(t,e)}}function Kh(r,t){switch(t){case"color":var e=r.getVisual("style");return e[r.getVisual("drawType")];case"opacity":return r.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return r.getVisual(t)}}function RM(r,t,e,i){switch(e){case"color":var n=r.ensureUniqueItemVisual(t,"style");n[r.getVisual("drawType")]=i,r.setItemVisual(t,"colorFromPalette",!1);break;case"opacity":r.ensureUniqueItemVisual(t,"style").opacity=i;break;case"symbol":case"symbolSize":case"liftZ":r.setItemVisual(t,e,i);break}}function Vi(r,t,e,i,n){var a=r+t;e.isSilent(a)||i.eachComponent({mainType:"series",subType:"pie"},function(o){for(var s=o.seriesIndex,u=o.option.selectedMap,l=n.selected,f=0;f<l.length;f++)if(l[f].seriesIndex===s){var h=o.getData(),v=yi(h,n.fromActionPayload);e.trigger(a,{type:a,seriesId:o.id,name:B(v)?h.getName(v[0]):h.getName(v),selected:H(u)?u:k({},u)})}})}function EM(r,t,e){r.on("selectchanged",function(i){var n=e.getModel();i.isFromClick?(Vi("map","selectchanged",t,n,i),Vi("pie","selectchanged",t,n,i)):i.fromAction==="select"?(Vi("map","selected",t,n,i),Vi("pie","selected",t,n,i)):i.fromAction==="unselect"&&(Vi("map","unselected",t,n,i),Vi("pie","unselected",t,n,i))})}function ia(r,t,e){for(var i;r&&!(t(r)&&(i=r,e));)r=r.__hostTarget||r.parent;return i}var kM=Math.round(Math.random()*9),OM=typeof Object.defineProperty=="function",BM=(function(){function r(){this._id="__ec_inner_"+kM++}return r.prototype.get=function(t){return this._guard(t)[this._id]},r.prototype.set=function(t,e){var i=this._guard(t);return OM?Object.defineProperty(i,this._id,{value:e,enumerable:!1,configurable:!0}):i[this._id]=e,this},r.prototype.delete=function(t){return this.has(t)?(delete this._guard(t)[this._id],!0):!1},r.prototype.has=function(t){return!!this._guard(t)[this._id]},r.prototype._guard=function(t){if(t!==Object(t))throw TypeError("Value of WeakMap is not a non-null object.");return t},r})(),NM=st.extend({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,t){var e=t.cx,i=t.cy,n=t.width/2,a=t.height/2;r.moveTo(e,i-a),r.lineTo(e+n,i+a),r.lineTo(e-n,i+a),r.closePath()}}),FM=st.extend({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(r,t){var e=t.cx,i=t.cy,n=t.width/2,a=t.height/2;r.moveTo(e,i-a),r.lineTo(e+n,i),r.lineTo(e,i+a),r.lineTo(e-n,i),r.closePath()}}),zM=st.extend({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,t){var e=t.x,i=t.y,n=t.width/5*3,a=Math.max(n,t.height),o=n/2,s=o*o/(a-o),u=i-a+o+s,l=Math.asin(s/o),f=Math.cos(l)*o,h=Math.sin(l),v=Math.cos(l),c=o*.6,p=o*.7;r.moveTo(e-f,u+s),r.arc(e,u,o,Math.PI-l,Math.PI*2+l),r.bezierCurveTo(e+f-h*c,u+s+v*c,e,i-p,e,i),r.bezierCurveTo(e,i-p,e-f+h*c,u+s+v*c,e-f,u+s),r.closePath()}}),VM=st.extend({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(r,t){var e=t.height,i=t.width,n=t.x,a=t.y,o=i/3*2;r.moveTo(n,a),r.lineTo(n+o,a+e),r.lineTo(n,a+e/4*3),r.lineTo(n-o,a+e),r.lineTo(n,a),r.closePath()}}),HM={line:er,rect:Tt,roundRect:Tt,square:Tt,circle:Fs,diamond:FM,pin:zM,arrow:VM,triangle:NM},GM={line:function(r,t,e,i,n){n.x1=r,n.y1=t+i/2,n.x2=r+e,n.y2=t+i/2},rect:function(r,t,e,i,n){n.x=r,n.y=t,n.width=e,n.height=i},roundRect:function(r,t,e,i,n){n.x=r,n.y=t,n.width=e,n.height=i,n.r=Math.min(e,i)/4},square:function(r,t,e,i,n){var a=Math.min(e,i);n.x=r,n.y=t,n.width=a,n.height=a},circle:function(r,t,e,i,n){n.cx=r+e/2,n.cy=t+i/2,n.r=Math.min(e,i)/2},diamond:function(r,t,e,i,n){n.cx=r+e/2,n.cy=t+i/2,n.width=e,n.height=i},pin:function(r,t,e,i,n){n.x=r+e/2,n.y=t+i/2,n.width=e,n.height=i},arrow:function(r,t,e,i,n){n.x=r+e/2,n.y=t+i/2,n.width=e,n.height=i},triangle:function(r,t,e,i,n){n.cx=r+e/2,n.cy=t+i/2,n.width=e,n.height=i}},vs={};T(HM,function(r,t){vs[t]=new r});var WM=st.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(r,t,e){var i=My(r,t,e),n=this.shape;return n&&n.symbolType==="pin"&&t.position==="inside"&&(i.y=e.y+e.height*.4),i},buildPath:function(r,t,e){var i=t.symbolType;if(i!=="none"){var n=vs[i];n||(i="rect",n=vs[i]),GM[i](t.x,t.y,t.width,t.height,n.shape),n.buildPath(r,n.shape,e)}}});function UM(r,t){if(this.type!=="image"){var e=this.style;this.__isEmptyBrush?(e.stroke=r,e.fill=t||"#fff",e.lineWidth=2):this.shape.symbolType==="line"?e.stroke=r:e.fill=r,this.markRedraw()}}function ir(r,t,e,i,n,a,o){var s=r.indexOf("empty")===0;s&&(r=r.substr(5,1).toLowerCase()+r.substr(6));var u;return r.indexOf("image://")===0?u=dm(r.slice(8),new et(t,e,i,n),o?"center":"cover"):r.indexOf("path://")===0?u=Gs(r.slice(7),{},new et(t,e,i,n),o?"center":"cover"):u=new WM({shape:{symbolType:r,x:t,y:e,width:i,height:n}}),u.__isEmptyBrush=s,u.setColor=UM,a&&u.setColor(a),u}function Qh(r){return B(r)||(r=[+r,+r]),[r[0]||0,r[1]||0]}function ru(r,t){if(r!=null)return B(r)||(r=[r,r]),[yt(r[0],t[0])||0,yt($(r[1],r[0]),t[1])||0]}function ui(r){return isFinite(r)}function YM(r,t,e){var i=t.x==null?0:t.x,n=t.x2==null?1:t.x2,a=t.y==null?0:t.y,o=t.y2==null?0:t.y2;t.global||(i=i*e.width+e.x,n=n*e.width+e.x,a=a*e.height+e.y,o=o*e.height+e.y),i=ui(i)?i:0,n=ui(n)?n:1,a=ui(a)?a:0,o=ui(o)?o:0;var s=r.createLinearGradient(i,a,n,o);return s}function ZM(r,t,e){var i=e.width,n=e.height,a=Math.min(i,n),o=t.x==null?.5:t.x,s=t.y==null?.5:t.y,u=t.r==null?.5:t.r;t.global||(o=o*i+e.x,s=s*n+e.y,u=u*a),o=ui(o)?o:.5,s=ui(s)?s:.5,u=u>=0&&ui(u)?u:.5;var l=r.createRadialGradient(o,s,0,o,s,u);return l}function kf(r,t,e){for(var i=t.type==="radial"?ZM(r,t,e):YM(r,t,e),n=t.colorStops,a=0;a<n.length;a++)i.addColorStop(n[a].offset,n[a].color);return i}function XM(r,t){if(r===t||!r&&!t)return!1;if(!r||!t||r.length!==t.length)return!0;for(var e=0;e<r.length;e++)if(r[e]!==t[e])return!0;return!1}function vo(r){return parseInt(r,10)}function co(r,t,e){var i=["width","height"][t],n=["clientWidth","clientHeight"][t],a=["paddingLeft","paddingTop"][t],o=["paddingRight","paddingBottom"][t];if(e[i]!=null&&e[i]!=="auto")return parseFloat(e[i]);var s=document.defaultView.getComputedStyle(r);return(r[n]||vo(s[i])||vo(r.style[i]))-(vo(s[a])||0)-(vo(s[o])||0)|0}function $M(r,t){return!r||r==="solid"||!(t>0)?null:r==="dashed"?[4*t,2*t]:r==="dotted"?[t]:dt(r)?[r]:B(r)?r:null}function x0(r){var t=r.style,e=t.lineDash&&t.lineWidth>0&&$M(t.lineDash,t.lineWidth),i=t.lineDashOffset;if(e){var n=t.strokeNoScale&&r.getLineScale?r.getLineScale():1;n&&n!==1&&(e=z(e,function(a){return a/n}),i/=n)}return[e,i]}var qM=new Ar(!0);function cs(r){var t=r.stroke;return!(t==null||t==="none"||!(r.lineWidth>0))}function Np(r){return typeof r=="string"&&r!=="none"}function ps(r){var t=r.fill;return t!=null&&t!=="none"}function Fp(r,t){if(t.fillOpacity!=null&&t.fillOpacity!==1){var e=r.globalAlpha;r.globalAlpha=t.fillOpacity*t.opacity,r.fill(),r.globalAlpha=e}else r.fill()}function zp(r,t){if(t.strokeOpacity!=null&&t.strokeOpacity!==1){var e=r.globalAlpha;r.globalAlpha=t.strokeOpacity*t.opacity,r.stroke(),r.globalAlpha=e}else r.stroke()}function Of(r,t,e){var i=Hy(t.image,t.__image,e);if(Es(i)){var n=r.createPattern(i,t.repeat||"repeat");if(typeof DOMMatrix=="function"&&n&&n.setTransform){var a=new DOMMatrix;a.translateSelf(t.x||0,t.y||0),a.rotateSelf(0,0,(t.rotation||0)*z1),a.scaleSelf(t.scaleX||1,t.scaleY||1),n.setTransform(a)}return n}}function KM(r,t,e,i){var n,a=cs(e),o=ps(e),s=e.strokePercent,u=s<1,l=!t.path;(!t.silent||u)&&l&&t.createPathProxy();var f=t.path||qM,h=t.__dirty;if(!i){var v=e.fill,c=e.stroke,p=o&&!!v.colorStops,d=a&&!!c.colorStops,g=o&&!!v.image,y=a&&!!c.image,m=void 0,_=void 0,S=void 0,b=void 0,w=void 0;(p||d)&&(w=t.getBoundingRect()),p&&(m=h?kf(r,v,w):t.__canvasFillGradient,t.__canvasFillGradient=m),d&&(_=h?kf(r,c,w):t.__canvasStrokeGradient,t.__canvasStrokeGradient=_),g&&(S=h||!t.__canvasFillPattern?Of(r,v,t):t.__canvasFillPattern,t.__canvasFillPattern=S),y&&(b=h||!t.__canvasStrokePattern?Of(r,c,t):t.__canvasStrokePattern,t.__canvasStrokePattern=S),p?r.fillStyle=m:g&&(S?r.fillStyle=S:o=!1),d?r.strokeStyle=_:y&&(b?r.strokeStyle=b:a=!1)}var x=t.getGlobalScale();f.setScale(x[0],x[1],t.segmentIgnoreThreshold);var C,M;r.setLineDash&&e.lineDash&&(n=x0(t),C=n[0],M=n[1]);var D=!0;(l||h&Ui)&&(f.setDPR(r.dpr),u?f.setContext(null):(f.setContext(r),D=!1),f.reset(),t.buildPath(f,t.shape,i),f.toStatic(),t.pathUpdated()),D&&f.rebuildPath(r,u?s:1),C&&(r.setLineDash(C),r.lineDashOffset=M),i||(e.strokeFirst?(a&&zp(r,e),o&&Fp(r,e)):(o&&Fp(r,e),a&&zp(r,e))),C&&r.setLineDash([])}function QM(r,t,e){var i=t.__image=Hy(e.image,t.__image,t,t.onload);if(!(!i||!Es(i))){var n=e.x||0,a=e.y||0,o=t.getWidth(),s=t.getHeight(),u=i.width/i.height;if(o==null&&s!=null?o=s*u:s==null&&o!=null?s=o/u:o==null&&s==null&&(o=i.width,s=i.height),e.sWidth&&e.sHeight){var l=e.sx||0,f=e.sy||0;r.drawImage(i,l,f,e.sWidth,e.sHeight,n,a,o,s)}else if(e.sx&&e.sy){var l=e.sx,f=e.sy,h=o-l,v=s-f;r.drawImage(i,l,f,h,v,n,a,o,s)}else r.drawImage(i,n,a,o,s)}}function JM(r,t,e){var i,n=e.text;if(n!=null&&(n+=""),n){r.font=e.font||di,r.textAlign=e.textAlign,r.textBaseline=e.textBaseline;var a=void 0,o=void 0;r.setLineDash&&e.lineDash&&(i=x0(t),a=i[0],o=i[1]),a&&(r.setLineDash(a),r.lineDashOffset=o),e.strokeFirst?(cs(e)&&r.strokeText(n,e.x,e.y),ps(e)&&r.fillText(n,e.x,e.y)):(ps(e)&&r.fillText(n,e.x,e.y),cs(e)&&r.strokeText(n,e.x,e.y)),a&&r.setLineDash([])}}var Vp=["shadowBlur","shadowOffsetX","shadowOffsetY"],Hp=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function T0(r,t,e,i,n){var a=!1;if(!i&&(e=e||{},t===e))return!1;if(i||t.opacity!==e.opacity){Wt(r,n),a=!0;var o=Math.max(Math.min(t.opacity,1),0);r.globalAlpha=isNaN(o)?vi.opacity:o}(i||t.blend!==e.blend)&&(a||(Wt(r,n),a=!0),r.globalCompositeOperation=t.blend||vi.blend);for(var s=0;s<Vp.length;s++){var u=Vp[s];(i||t[u]!==e[u])&&(a||(Wt(r,n),a=!0),r[u]=r.dpr*(t[u]||0))}return(i||t.shadowColor!==e.shadowColor)&&(a||(Wt(r,n),a=!0),r.shadowColor=t.shadowColor||vi.shadowColor),a}function Gp(r,t,e,i,n){var a=Ia(t,n.inHover),o=i?null:e&&Ia(e,n.inHover)||{};if(a===o)return!1;var s=T0(r,a,o,i,n);if((i||a.fill!==o.fill)&&(s||(Wt(r,n),s=!0),Np(a.fill)&&(r.fillStyle=a.fill)),(i||a.stroke!==o.stroke)&&(s||(Wt(r,n),s=!0),Np(a.stroke)&&(r.strokeStyle=a.stroke)),(i||a.opacity!==o.opacity)&&(s||(Wt(r,n),s=!0),r.globalAlpha=a.opacity==null?1:a.opacity),t.hasStroke()){var u=a.lineWidth,l=u/(a.strokeNoScale&&t.getLineScale?t.getLineScale():1);r.lineWidth!==l&&(s||(Wt(r,n),s=!0),r.lineWidth=l)}for(var f=0;f<Hp.length;f++){var h=Hp[f],v=h[0];(i||a[v]!==o[v])&&(s||(Wt(r,n),s=!0),r[v]=a[v]||h[1])}return s}function jM(r,t,e,i,n){return T0(r,Ia(t,n.inHover),e&&Ia(e,n.inHover),i,n)}function M0(r,t){var e=t.transform,i=r.dpr||1;e?r.setTransform(i*e[0],i*e[1],i*e[2],i*e[3],i*e[4],i*e[5]):r.setTransform(i,0,0,i,0,0)}function tC(r,t,e){for(var i=!1,n=0;n<r.length;n++){var a=r[n];i=i||a.isZeroArea(),M0(t,a),t.beginPath(),a.buildPath(t,a.shape),t.clip()}e.allClipped=i}function eC(r,t){return r&&t?r[0]!==t[0]||r[1]!==t[1]||r[2]!==t[2]||r[3]!==t[3]||r[4]!==t[4]||r[5]!==t[5]:!(!r&&!t)}var Wp=1,Up=2,Yp=3,Zp=4;function rC(r){var t=ps(r),e=cs(r);return!(r.lineDash||!(+t^+e)||t&&typeof r.fill!="string"||e&&typeof r.stroke!="string"||r.strokePercent<1||r.strokeOpacity<1||r.fillOpacity<1)}function Wt(r,t){t.batchFill&&r.fill(),t.batchStroke&&r.stroke(),t.batchFill="",t.batchStroke=""}function Ia(r,t){return t&&r.__hoverStyle||r.style}function C0(r,t){li(r,t,{inHover:!1,viewWidth:0,viewHeight:0},!0)}function li(r,t,e,i){var n=t.transform;if(!t.shouldBePainted(e.viewWidth,e.viewHeight,!1,!1)){t.__dirty&=~Jt,t.__isRendered=!1;return}var a=t.__clipPaths,o=e.prevElClipPaths,s=!1,u=!1;if((!o||XM(a,o))&&(o&&o.length&&(Wt(r,e),r.restore(),u=s=!0,e.prevElClipPaths=null,e.allClipped=!1,e.prevEl=null),a&&a.length&&(Wt(r,e),r.save(),tC(a,r,e),s=!0),e.prevElClipPaths=a),e.allClipped){t.__isRendered=!1;return}t.beforeBrush&&t.beforeBrush(),t.innerBeforeBrush();var l=e.prevEl;l||(u=s=!0);var f=t instanceof st&&t.autoBatch&&rC(t.style);s||eC(n,l.transform)?(Wt(r,e),M0(r,t)):f||Wt(r,e);var h=Ia(t,e.inHover);t instanceof st?(e.lastDrawType!==Wp&&(u=!0,e.lastDrawType=Wp),Gp(r,t,l,u,e),(!f||!e.batchFill&&!e.batchStroke)&&r.beginPath(),KM(r,t,h,f),f&&(e.batchFill=h.fill||"",e.batchStroke=h.stroke||"")):t instanceof es?(e.lastDrawType!==Yp&&(u=!0,e.lastDrawType=Yp),Gp(r,t,l,u,e),JM(r,t,h)):t instanceof nr?(e.lastDrawType!==Up&&(u=!0,e.lastDrawType=Up),jM(r,t,l,u,e),QM(r,t,h)):t.getTemporalDisplayables&&(e.lastDrawType!==Zp&&(u=!0,e.lastDrawType=Zp),iC(r,t,e)),f&&i&&Wt(r,e),t.innerAfterBrush(),t.afterBrush&&t.afterBrush(),e.prevEl=t,t.__dirty=0,t.__isRendered=!0}function iC(r,t,e){var i=t.getDisplayables(),n=t.getTemporalDisplayables();r.save();var a={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:e.viewWidth,viewHeight:e.viewHeight,inHover:e.inHover},o,s;for(o=t.getCursor(),s=i.length;o<s;o++){var u=i[o];u.beforeBrush&&u.beforeBrush(),u.innerBeforeBrush(),li(r,u,a,o===s-1),u.innerAfterBrush(),u.afterBrush&&u.afterBrush(),a.prevEl=u}for(var l=0,f=n.length;l<f;l++){var u=n[l];u.beforeBrush&&u.beforeBrush(),u.innerBeforeBrush(),li(r,u,a,l===f-1),u.innerAfterBrush(),u.afterBrush&&u.afterBrush(),a.prevEl=u}t.clearTemporalDisplayables(),t.notClear=!0,r.restore()}var ol=new BM,Xp=new Na(100),$p=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function Bf(r,t){if(r==="none")return null;var e=t.getDevicePixelRatio(),i=t.getZr(),n=i.painter.type==="svg";r.dirty&&ol.delete(r);var a=ol.get(r);if(a)return a;var o=rt(r,{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 u(s),s.rotation=o.rotation,s.scaleX=s.scaleY=n?1:1/e,ol.set(r,s),r.dirty=!1,s;function u(l){for(var f=[e],h=!0,v=0;v<$p.length;++v){var c=o[$p[v]];if(c!=null&&!B(c)&&!H(c)&&!dt(c)&&typeof c!="boolean"){h=!1;break}f.push(c)}var p;if(h){p=f.join(",")+(n?"-svg":"");var d=Xp.get(p);d&&(n?l.svgElement=d:l.image=d)}var g=A0(o.dashArrayX),y=nC(o.dashArrayY),m=D0(o.symbol),_=aC(g),S=L0(y),b=!n&&yn.createCanvas(),w=n&&{tag:"g",attrs:{},key:"dcl",children:[]},x=M(),C;b&&(b.width=x.width*e,b.height=x.height*e,C=b.getContext("2d")),D(),h&&Xp.put(p,b||w),l.image=b,l.svgElement=w,l.svgWidth=x.width,l.svgHeight=x.height;function M(){for(var A=1,P=0,R=_.length;P<R;++P)A=hc(A,_[P]);for(var L=1,P=0,R=m.length;P<R;++P)L=hc(L,m[P].length);A*=L;var I=S*_.length*m.length;return{width:Math.max(1,Math.min(A,o.maxTileWidth)),height:Math.max(1,Math.min(I,o.maxTileHeight))}}function D(){C&&(C.clearRect(0,0,b.width,b.height),o.backgroundColor&&(C.fillStyle=o.backgroundColor,C.fillRect(0,0,b.width,b.height)));for(var A=0,P=0;P<y.length;++P)A+=y[P];if(A<=0)return;for(var R=-S,L=0,I=0,E=0;R<x.height;){if(L%2===0){for(var G=I/2%m.length,V=0,F=0,J=0;V<x.width*2;){for(var ut=0,P=0;P<g[E].length;++P)ut+=g[E][P];if(ut<=0)break;if(F%2===0){var lt=(1-o.symbolSize)*.5,ct=V+g[E][F]*lt,pt=R+y[L]*lt,mt=g[E][F]*o.symbolSize,ye=y[L]*o.symbolSize,Rr=J/2%m[G].length;Ai(ct,pt,mt,ye,m[G][Rr])}V+=g[E][F],++J,++F,F===g[E].length&&(F=0)}++E,E===g.length&&(E=0)}R+=y[L],++I,++L,L===y.length&&(L=0)}function Ai(qt,Lt,K,it,Er){var Ot=n?1:e,Iv=ir(Er,qt*Ot,Lt*Ot,K*Ot,it*Ot,o.color,o.symbolKeepAspect);if(n){var Rv=i.painter.renderOneToVNode(Iv);Rv&&w.children.push(Rv)}else C0(C,Iv)}}}}function D0(r){if(!r||r.length===0)return[["rect"]];if(H(r))return[[r]];for(var t=!0,e=0;e<r.length;++e)if(!H(r[e])){t=!1;break}if(t)return D0([r]);for(var i=[],e=0;e<r.length;++e)H(r[e])?i.push([r[e]]):i.push(r[e]);return i}function A0(r){if(!r||r.length===0)return[[0,0]];if(dt(r)){var t=Math.ceil(r);return[[t,t]]}for(var e=!0,i=0;i<r.length;++i)if(!dt(r[i])){e=!1;break}if(e)return A0([r]);for(var n=[],i=0;i<r.length;++i)if(dt(r[i])){var t=Math.ceil(r[i]);n.push([t,t])}else{var t=z(r[i],function(s){return Math.ceil(s)});t.length%2===1?n.push(t.concat(t)):n.push(t)}return n}function nC(r){if(!r||typeof r=="object"&&r.length===0)return[0,0];if(dt(r)){var t=Math.ceil(r);return[t,t]}var e=z(r,function(i){return Math.ceil(i)});return r.length%2?e.concat(e):e}function aC(r){return z(r,function(t){return L0(t)})}function L0(r){for(var t=0,e=0;e<r.length;++e)t+=r[e];return r.length%2===1?t*2:t}function oC(r,t){r.eachRawSeries(function(e){if(!r.isSeriesFiltered(e)){var i=e.getData();i.hasItemVisual()&&i.each(function(o){var s=i.getItemVisual(o,"decal");if(s){var u=i.ensureUniqueItemVisual(o,"style");u.decal=Bf(s,t)}});var n=i.getVisual("decal");if(n){var a=i.getVisual("style");a.decal=Bf(n,t)}}})}var be=new de,P0={};function sC(r,t){P0[r]=t}function uC(r){return P0[r]}var lC=1,fC=800,hC=900,vC=1e3,cC=2e3,pC=5e3,I0=1e3,dC=1100,Jh=2e3,R0=3e3,gC=4e3,iu=4500,yC=4600,mC=5e3,_C=6e3,E0=7e3,SC={PROCESSOR:{FILTER:vC,SERIES_FILTER:fC,STATISTIC:pC},VISUAL:{LAYOUT:I0,PROGRESSIVE_LAYOUT:dC,GLOBAL:Jh,CHART:R0,POST_CHART_LAYOUT:yC,COMPONENT:gC,BRUSH:mC,CHART_ITEM:iu,ARIA:_C,DECAL:E0}},It="__flagInMainProcess",Ht="__pendingUpdate",sl="__needsUpdateStatus",qp=/^[a-zA-Z0-9_]+$/,ul="__connectUpdateStatus",Kp=0,wC=1,bC=2;function k0(r){return function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];if(this.isDisposed()){this.id;return}return B0(this,r,t)}}function O0(r){return function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return B0(this,r,t)}}function B0(r,t,e){return e[0]=e[0]&&e[0].toLowerCase(),de.prototype[t].apply(r,e)}var N0=(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t})(de),F0=N0.prototype;F0.on=O0("on");F0.off=O0("off");var Hi,ll,po,hr,fl,hl,vl,On,Bn,Qp,Jp,cl,jp,go,td,z0,ee,ed,V0=(function(r){O(t,r);function t(e,i,n){var a=r.call(this,new LM)||this;a._chartsViews=[],a._chartsMap={},a._componentsViews=[],a._componentsMap={},a._pendingActions=[],n=n||{},H(i)&&(i=H0[i]),a._dom=e;var o="canvas",s="auto",u=!1;n.ssr;var l=a._zr=lc(e,{renderer:n.renderer||o,devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height,ssr:n.ssr,useDirtyRect:$(n.useDirtyRect,u),useCoarsePointer:$(n.useCoarsePointer,s),pointerSize:n.pointerSize});a._ssr=n.ssr,a._throttledZrFlush=p0(U(l.flush,l),17),i=Y(i),i&&qm(i,!0),a._theme=i,a._locale=Nx(n.locale||Dm),a._coordSysMgr=new Yh;var f=a._api=td(a);function h(v,c){return v.__prio-c.__prio}return Ro(gs,h),Ro(Nf,h),a._scheduler=new y0(a,f,Nf,gs),a._messageCenter=new N0,a._initEvents(),a.resize=U(a.resize,a),l.animation.on("frame",a._onframe,a),Qp(l,a),Jp(l,a),Kl(a),a}return t.prototype._onframe=function(){if(!this._disposed){ed(this);var e=this._scheduler;if(this[Ht]){var i=this[Ht].silent;this[It]=!0;try{Hi(this),hr.update.call(this,null,this[Ht].updateParams)}catch(u){throw this[It]=!1,this[Ht]=null,u}this._zr.flush(),this[It]=!1,this[Ht]=null,On.call(this,i),Bn.call(this,i)}else if(e.unfinished){var n=lC,a=this._model,o=this._api;e.unfinished=!1;do{var s=+new Date;e.performSeriesTasks(a),e.performDataProcessorTasks(a),hl(this,a),e.performVisualTasks(a),go(this,this._model,o,"remain",{}),n-=+new Date-s}while(n>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,i,n){if(!this[It]){if(this._disposed){this.id;return}var a,o,s;if(W(i)&&(n=i.lazyUpdate,a=i.silent,o=i.replaceMerge,s=i.transition,i=i.notMerge),this[It]=!0,!this._model||i){var u=new fT(this._api),l=this._theme,f=this._model=new Uh;f.scheduler=this._scheduler,f.ssr=this._ssr,f.init(null,null,null,l,this._locale,u)}this._model.setOption(e,{replaceMerge:o},Ff);var h={seriesTransition:s,optionChanged:!0};if(n)this[Ht]={silent:a,updateParams:h},this[It]=!1,this.getZr().wakeUp();else{try{Hi(this),hr.update.call(this,null,h)}catch(v){throw this[Ht]=null,this[It]=!1,v}this._ssr||this._zr.flush(),this[Ht]=null,this[It]=!1,On.call(this,a),Bn.call(this,a)}}},t.prototype.setTheme=function(){},t.prototype.getModel=function(){return this._model},t.prototype.getOption=function(){return this._model&&this._model.getOption()},t.prototype.getWidth=function(){return this._zr.getWidth()},t.prototype.getHeight=function(){return this._zr.getHeight()},t.prototype.getDevicePixelRatio=function(){return this._zr.painter.dpr||Z.hasGlobalWindow&&window.devicePixelRatio||1},t.prototype.getRenderedCanvas=function(e){return this.renderToCanvas(e)},t.prototype.renderToCanvas=function(e){e=e||{};var i=this._zr.painter;return i.getRenderedCanvas({backgroundColor:e.backgroundColor||this._model.get("backgroundColor"),pixelRatio:e.pixelRatio||this.getDevicePixelRatio()})},t.prototype.renderToSVGString=function(e){e=e||{};var i=this._zr.painter;return i.renderToString({useViewBox:e.useViewBox})},t.prototype.getSvgDataURL=function(){if(Z.svgSupported){var e=this._zr,i=e.storage.getDisplayList();return T(i,function(n){n.stopAnimation(null,!0)}),e.painter.toDataURL()}},t.prototype.getDataURL=function(e){if(this._disposed){this.id;return}e=e||{};var i=e.excludeComponents,n=this._model,a=[],o=this;T(i,function(u){n.eachComponent({mainType:u},function(l){var f=o._componentsMap[l.__viewId];f.group.ignore||(a.push(f),f.group.ignore=!0)})});var s=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(e).toDataURL("image/"+(e&&e.type||"png"));return T(a,function(u){u.group.ignore=!1}),s},t.prototype.getConnectedDataURL=function(e){if(this._disposed){this.id;return}var i=e.type==="svg",n=this.group,a=Math.min,o=Math.max,s=1/0;if(rd[n]){var u=s,l=s,f=-s,h=-s,v=[],c=e&&e.pixelRatio||this.getDevicePixelRatio();T(ga,function(_,S){if(_.group===n){var b=i?_.getZr().painter.getSvgDom().innerHTML:_.renderToCanvas(Y(e)),w=_.getDom().getBoundingClientRect();u=a(w.left,u),l=a(w.top,l),f=o(w.right,f),h=o(w.bottom,h),v.push({dom:b,left:w.left,top:w.top})}}),u*=c,l*=c,f*=c,h*=c;var p=f-u,d=h-l,g=yn.createCanvas(),y=lc(g,{renderer:i?"svg":"canvas"});if(y.resize({width:p,height:d}),i){var m="";return T(v,function(_){var S=_.left-u,b=_.top-l;m+='<g transform="translate('+S+","+b+')">'+_.dom+"</g>"}),y.painter.getSvgRoot().innerHTML=m,e.connectedBackgroundColor&&y.painter.setBackgroundColor(e.connectedBackgroundColor),y.refreshImmediately(),y.painter.toDataURL()}else return e.connectedBackgroundColor&&y.add(new Tt({shape:{x:0,y:0,width:p,height:d},style:{fill:e.connectedBackgroundColor}})),T(v,function(_){var S=new nr({style:{x:_.left*c-u,y:_.top*c-l,image:_.dom}});y.add(S)}),y.refreshImmediately(),g.toDataURL("image/"+(e&&e.type||"png"))}else return this.getDataURL(e)},t.prototype.convertToPixel=function(e,i){return fl(this,"convertToPixel",e,i)},t.prototype.convertFromPixel=function(e,i){return fl(this,"convertFromPixel",e,i)},t.prototype.containPixel=function(e,i){if(this._disposed){this.id;return}var n=this._model,a,o=No(n,e);return T(o,function(s,u){u.indexOf("Models")>=0&&T(s,function(l){var f=l.coordinateSystem;if(f&&f.containPoint)a=a||!!f.containPoint(i);else if(u==="seriesModels"){var h=this._chartsMap[l.__viewId];h&&h.containPoint&&(a=a||h.containPoint(i,l))}},this)},this),!!a},t.prototype.getVisual=function(e,i){var n=this._model,a=No(n,e,{defaultMainType:"series"}),o=a.seriesModel,s=o.getData(),u=a.hasOwnProperty("dataIndexInside")?a.dataIndexInside:a.hasOwnProperty("dataIndex")?s.indexOfRawIndex(a.dataIndex):null;return u!=null?b0(s,u,i):Kh(s,i)},t.prototype.getViewOfComponentModel=function(e){return this._componentsMap[e.__viewId]},t.prototype.getViewOfSeriesModel=function(e){return this._chartsMap[e.__viewId]},t.prototype._initEvents=function(){var e=this;T(xC,function(i){var n=function(a){var o=e.getModel(),s=a.target,u,l=i==="globalout";if(l?u={}:s&&ia(s,function(p){var d=at(p);if(d&&d.dataIndex!=null){var g=d.dataModel||o.getSeriesByIndex(d.seriesIndex);return u=g&&g.getDataParams(d.dataIndex,d.dataType,s)||{},!0}else if(d.eventData)return u=k({},d.eventData),!0},!0),u){var f=u.componentType,h=u.componentIndex;(f==="markLine"||f==="markPoint"||f==="markArea")&&(f="series",h=u.seriesIndex);var v=f&&h!=null&&o.getComponent(f,h),c=v&&e[v.mainType==="series"?"_chartsMap":"_componentsMap"][v.__viewId];u.event=a,u.type=i,e._$eventProcessor.eventInfo={targetEl:s,packedEvent:u,model:v,view:c},e.trigger(i,u)}};n.zrEventfulCallAtLast=!0,e._zr.on(i,n,e)}),T(da,function(i,n){e._messageCenter.on(n,function(a){this.trigger(n,a)},e)}),T(["selectchanged"],function(i){e._messageCenter.on(i,function(n){this.trigger(i,n)},e)}),EM(this._messageCenter,this,this._api)},t.prototype.isDisposed=function(){return this._disposed},t.prototype.clear=function(){if(this._disposed){this.id;return}this.setOption({series:[]},!0)},t.prototype.dispose=function(){if(this._disposed){this.id;return}this._disposed=!0;var e=this.getDom();e&&Ny(this.getDom(),tv,"");var i=this,n=i._api,a=i._model;T(i._componentsViews,function(o){o.dispose(a,n)}),T(i._chartsViews,function(o){o.dispose(a,n)}),i._zr.dispose(),i._dom=i._model=i._chartsMap=i._componentsMap=i._chartsViews=i._componentsViews=i._scheduler=i._api=i._zr=i._throttledZrFlush=i._theme=i._coordSysMgr=i._messageCenter=null,delete ga[i.id]},t.prototype.resize=function(e){if(!this[It]){if(this._disposed){this.id;return}this._zr.resize(e);var i=this._model;if(this._loadingFX&&this._loadingFX.resize(),!!i){var n=i.resetOption("media"),a=e&&e.silent;this[Ht]&&(a==null&&(a=this[Ht].silent),n=!0,this[Ht]=null),this[It]=!0;try{n&&Hi(this),hr.update.call(this,{type:"resize",animation:k({duration:0},e&&e.animation)})}catch(o){throw this[It]=!1,o}this[It]=!1,On.call(this,a),Bn.call(this,a)}}},t.prototype.showLoading=function(e,i){if(this._disposed){this.id;return}if(W(e)&&(i=e,e=""),e=e||"default",this.hideLoading(),!!zf[e]){var n=zf[e](this._api,i),a=this._zr;this._loadingFX=n,a.add(n)}},t.prototype.hideLoading=function(){if(this._disposed){this.id;return}this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},t.prototype.makeActionFromEvent=function(e){var i=k({},e);return i.type=da[e.type],i},t.prototype.dispatchAction=function(e,i){if(this._disposed){this.id;return}if(W(i)||(i={silent:!!i}),!!ds[e.type]&&this._model){if(this[It]){this._pendingActions.push(e);return}var n=i.silent;vl.call(this,e,n);var a=i.flush;a?this._zr.flush():a!==!1&&Z.browser.weChat&&this._throttledZrFlush(),On.call(this,n),Bn.call(this,n)}},t.prototype.updateLabelLayout=function(){be.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},t.prototype.appendData=function(e){if(this._disposed){this.id;return}var i=e.seriesIndex,n=this.getModel(),a=n.getSeriesByIndex(i);a.appendData(e),this._scheduler.unfinished=!0,this.getZr().wakeUp()},t.internalField=(function(){Hi=function(h){var v=h._scheduler;v.restorePipelines(h._model),v.prepareStageTasks(),ll(h,!0),ll(h,!1),v.plan()},ll=function(h,v){for(var c=h._model,p=h._scheduler,d=v?h._componentsViews:h._chartsViews,g=v?h._componentsMap:h._chartsMap,y=h._zr,m=h._api,_=0;_<d.length;_++)d[_].__alive=!1;v?c.eachComponent(function(w,x){w!=="series"&&S(x)}):c.eachSeries(S);function S(w){var x=w.__requireNewView;w.__requireNewView=!1;var C="_ec_"+w.id+"_"+w.type,M=!x&&g[C];if(!M){var D=Ne(w.type),A=v?$t.getClass(D.main,D.sub):ce.getClass(D.sub);M=new A,M.init(c,m),g[C]=M,d.push(M),y.add(M.group)}w.__viewId=M.__id=C,M.__alive=!0,M.__model=w,M.group.__ecComponentInfo={mainType:w.mainType,index:w.componentIndex},!v&&p.prepareView(M,w,c,m)}for(var _=0;_<d.length;){var b=d[_];b.__alive?_++:(!v&&b.renderTask.dispose(),y.remove(b.group),b.dispose(c,m),d.splice(_,1),g[b.__id]===b&&delete g[b.__id],b.__id=b.group.__ecComponentInfo=null)}},po=function(h,v,c,p,d){var g=h._model;if(g.setUpdatePayload(c),!p){T([].concat(h._componentsViews).concat(h._chartsViews),b);return}var y={};y[p+"Id"]=c[p+"Id"],y[p+"Index"]=c[p+"Index"],y[p+"Name"]=c[p+"Name"];var m={mainType:p,query:y};d&&(m.subType=d);var _=c.excludeSeriesId,S;_!=null&&(S=X(),T(Ct(_),function(w){var x=Fe(w,null);x!=null&&S.set(x,!0)})),g&&g.eachComponent(m,function(w){var x=S&&S.get(w.id)!=null;if(!x)if(Fc(c))if(w instanceof He)c.type===ci&&!c.notBlur&&!w.get(["emphasis","disabled"])&&Mb(w,c,h._api);else{var C=Lh(w.mainType,w.componentIndex,c.name,h._api),M=C.focusSelf,D=C.dispatchers;c.type===ci&&M&&!c.notBlur&&Sf(w.mainType,w.componentIndex,h._api),D&&T(D,function(A){c.type===ci?ba(A):xa(A)})}else xf(c)&&w instanceof He&&(Ab(w,c,h._api),Bc(w),ee(h))},h),g&&g.eachComponent(m,function(w){var x=S&&S.get(w.id)!=null;x||b(h[p==="series"?"_chartsMap":"_componentsMap"][w.__viewId])},h);function b(w){w&&w.__alive&&w[v]&&w[v](w.__model,g,h._api,c)}},hr={prepareAndUpdate:function(h){Hi(this),hr.update.call(this,h,{optionChanged:h.newOption!=null})},update:function(h,v){var c=this._model,p=this._api,d=this._zr,g=this._coordSysMgr,y=this._scheduler;if(c){c.setUpdatePayload(h),y.restoreData(c,h),y.performSeriesTasks(c),g.create(c,p),y.performDataProcessorTasks(c,h),hl(this,c),g.update(c,p),e(c),y.performVisualTasks(c,h),cl(this,c,p,h,v);var m=c.get("backgroundColor")||"transparent",_=c.get("darkMode");d.setBackgroundColor(m),_!=null&&_!=="auto"&&d.setDarkMode(_),be.trigger("afterupdate",c,p)}},updateTransform:function(h){var v=this,c=this._model,p=this._api;if(c){c.setUpdatePayload(h);var d=[];c.eachComponent(function(y,m){if(y!=="series"){var _=v.getViewOfComponentModel(m);if(_&&_.__alive)if(_.updateTransform){var S=_.updateTransform(m,c,p,h);S&&S.update&&d.push(_)}else d.push(_)}});var g=X();c.eachSeries(function(y){var m=v._chartsMap[y.__viewId];if(m.updateTransform){var _=m.updateTransform(y,c,p,h);_&&_.update&&g.set(y.uid,1)}else g.set(y.uid,1)}),e(c),this._scheduler.performVisualTasks(c,h,{setDirty:!0,dirtyMap:g}),go(this,c,p,h,{},g),be.trigger("afterupdate",c,p)}},updateView:function(h){var v=this._model;v&&(v.setUpdatePayload(h),ce.markUpdateMethod(h,"updateView"),e(v),this._scheduler.performVisualTasks(v,h,{setDirty:!0}),cl(this,v,this._api,h,{}),be.trigger("afterupdate",v,this._api))},updateVisual:function(h){var v=this,c=this._model;c&&(c.setUpdatePayload(h),c.eachSeries(function(p){p.getData().clearAllVisual()}),ce.markUpdateMethod(h,"updateVisual"),e(c),this._scheduler.performVisualTasks(c,h,{visualType:"visual",setDirty:!0}),c.eachComponent(function(p,d){if(p!=="series"){var g=v.getViewOfComponentModel(d);g&&g.__alive&&g.updateVisual(d,c,v._api,h)}}),c.eachSeries(function(p){var d=v._chartsMap[p.__viewId];d.updateVisual(p,c,v._api,h)}),be.trigger("afterupdate",c,this._api))},updateLayout:function(h){hr.update.call(this,h)}},fl=function(h,v,c,p){if(h._disposed){h.id;return}for(var d=h._model,g=h._coordSysMgr.getCoordinateSystems(),y,m=No(d,c),_=0;_<g.length;_++){var S=g[_];if(S[v]&&(y=S[v](d,m,p))!=null)return y}},hl=function(h,v){var c=h._chartsMap,p=h._scheduler;v.eachSeries(function(d){p.updateStreamModes(d,c[d.__viewId])})},vl=function(h,v){var c=this,p=this.getModel(),d=h.type,g=h.escapeConnect,y=ds[d],m=y.actionInfo,_=(m.update||"update").split(":"),S=_.pop(),b=_[0]!=null&&Ne(_[0]);this[It]=!0;var w=[h],x=!1;h.batch&&(x=!0,w=z(h.batch,function(L){return L=rt(k({},L),h),L.batch=null,L}));var C=[],M,D=xf(h),A=Fc(h);if(A&&nm(this._api),T(w,function(L){if(M=y.action(L,c._model,c._api),M=M||k({},L),M.type=m.event||M.type,C.push(M),A){var I=xh(h),E=I.queryOptionMap,G=I.mainTypeSpecified,V=G?E.keys()[0]:"series";po(c,S,L,V),ee(c)}else D?(po(c,S,L,"series"),ee(c)):b&&po(c,S,L,b.main,b.sub)}),S!=="none"&&!A&&!D&&!b)try{this[Ht]?(Hi(this),hr.update.call(this,h),this[Ht]=null):hr[S].call(this,h)}catch(L){throw this[It]=!1,L}if(x?M={type:m.event||d,escapeConnect:g,batch:C}:M=C[0],this[It]=!1,!v){var P=this._messageCenter;if(P.trigger(M.type,M),D){var R={type:"selectchanged",escapeConnect:g,selected:Lb(p),isFromClick:h.isFromClick||!1,fromAction:h.type,fromActionPayload:h};P.trigger(R.type,R)}}},On=function(h){for(var v=this._pendingActions;v.length;){var c=v.shift();vl.call(this,c,h)}},Bn=function(h){!h&&this.trigger("updated")},Qp=function(h,v){h.on("rendered",function(c){v.trigger("rendered",c),h.animation.isFinished()&&!v[Ht]&&!v._scheduler.unfinished&&!v._pendingActions.length&&v.trigger("finished")})},Jp=function(h,v){h.on("mouseover",function(c){var p=c.target,d=ia(p,bf);d&&(Cb(d,c,v._api),ee(v))}).on("mouseout",function(c){var p=c.target,d=ia(p,bf);d&&(Db(d,c,v._api),ee(v))}).on("click",function(c){var p=c.target,d=ia(p,function(m){return at(m).dataIndex!=null},!0);if(d){var g=d.selected?"unselect":"select",y=at(d);v._api.dispatchAction({type:g,dataType:y.dataType,dataIndexInside:y.dataIndex,seriesIndex:y.seriesIndex,isFromClick:!0})}})};function e(h){h.clearColorPalette(),h.eachSeries(function(v){v.clearColorPalette()})}function i(h){var v=[],c=[],p=!1;if(h.eachComponent(function(m,_){var S=_.get("zlevel")||0,b=_.get("z")||0,w=_.getZLevelKey();p=p||!!w,(m==="series"?c:v).push({zlevel:S,z:b,idx:_.componentIndex,type:m,key:w})}),p){var d=v.concat(c),g,y;Ro(d,function(m,_){return m.zlevel===_.zlevel?m.z-_.z:m.zlevel-_.zlevel}),T(d,function(m){var _=h.getComponent(m.type,m.idx),S=m.zlevel,b=m.key;g!=null&&(S=Math.max(g,S)),b?(S===g&&b!==y&&S++,y=b):y&&(S===g&&S++,y=""),g=S,_.setZLevel(S)})}}cl=function(h,v,c,p,d){i(v),jp(h,v,c,p,d),T(h._chartsViews,function(g){g.__alive=!1}),go(h,v,c,p,d),T(h._chartsViews,function(g){g.__alive||g.remove(v,c)})},jp=function(h,v,c,p,d,g){T(g||h._componentsViews,function(y){var m=y.__model;l(m,y),y.render(m,v,c,p),s(m,y),f(m,y)})},go=function(h,v,c,p,d,g){var y=h._scheduler;d=k(d||{},{updatedSeries:v.getSeries()}),be.trigger("series:beforeupdate",v,c,d);var m=!1;v.eachSeries(function(_){var S=h._chartsMap[_.__viewId];S.__alive=!0;var b=S.renderTask;y.updatePayload(b,p),l(_,S),g&&g.get(_.uid)&&b.dirty(),b.perform(y.getPerformArgs(b))&&(m=!0),S.group.silent=!!_.get("silent"),o(_,S),Bc(_)}),y.unfinished=m||y.unfinished,be.trigger("series:layoutlabels",v,c,d),be.trigger("series:transition",v,c,d),v.eachSeries(function(_){var S=h._chartsMap[_.__viewId];s(_,S),f(_,S)}),a(h,v),be.trigger("series:afterupdate",v,c,d)},ee=function(h){h[sl]=!0,h.getZr().wakeUp()},ed=function(h){h[sl]&&(h.getZr().storage.traverse(function(v){nn(v)||n(v)}),h[sl]=!1)};function n(h){for(var v=[],c=h.currentStates,p=0;p<c.length;p++){var d=c[p];d==="emphasis"||d==="blur"||d==="select"||v.push(d)}h.selected&&h.states.select&&v.push("select"),h.hoverState===Bs&&h.states.emphasis?v.push("emphasis"):h.hoverState===Os&&h.states.blur&&v.push("blur"),h.useStates(v)}function a(h,v){var c=h._zr,p=c.storage,d=0;p.traverse(function(g){g.isGroup||d++}),d>v.get("hoverLayerThreshold")&&!Z.node&&!Z.worker&&v.eachSeries(function(g){if(!g.preventUsingHoverLayer){var y=h._chartsMap[g.__viewId];y.__alive&&y.eachRendered(function(m){m.states.emphasis&&(m.states.emphasis.hoverLayer=!0)})}})}function o(h,v){var c=h.get("blendMode")||null;v.eachRendered(function(p){p.isGroup||(p.style.blend=c)})}function s(h,v){if(!h.preventAutoZ){var c=h.get("z")||0,p=h.get("zlevel")||0;v.eachRendered(function(d){return u(d,c,p,-1/0),!0})}}function u(h,v,c,p){var d=h.getTextContent(),g=h.getTextGuideLine(),y=h.isGroup;if(y)for(var m=h.childrenRef(),_=0;_<m.length;_++)p=Math.max(u(m[_],v,c,p),p);else h.z=v,h.zlevel=c,p=Math.max(h.z2,p);if(d&&(d.z=v,d.zlevel=c,isFinite(p)&&(d.z2=p+2)),g){var S=h.textGuideLineConfig;g.z=v,g.zlevel=c,isFinite(p)&&(g.z2=p+(S&&S.showAbove?1:-1))}return p}function l(h,v){v.eachRendered(function(c){if(!nn(c)){var p=c.getTextContent(),d=c.getTextGuideLine();c.stateTransition&&(c.stateTransition=null),p&&p.stateTransition&&(p.stateTransition=null),d&&d.stateTransition&&(d.stateTransition=null),c.hasState()?(c.prevStates=c.currentStates,c.clearStates()):c.prevStates&&(c.prevStates=null)}})}function f(h,v){var c=h.getModel("stateAnimation"),p=h.isAnimationEnabled(),d=c.get("duration"),g=d>0?{duration:d,delay:c.get("delay"),easing:c.get("easing")}:null;v.eachRendered(function(y){if(y.states&&y.states.emphasis){if(nn(y))return;if(y instanceof st&&kb(y),y.__dirty){var m=y.prevStates;m&&y.useStates(m)}if(p){y.stateTransition=g;var _=y.getTextContent(),S=y.getTextGuideLine();_&&(_.stateTransition=g),S&&(S.stateTransition=g)}y.__dirty&&n(y)}})}td=function(h){return new((function(v){O(c,v);function c(){return v!==null&&v.apply(this,arguments)||this}return c.prototype.getCoordinateSystems=function(){return h._coordSysMgr.getCoordinateSystems()},c.prototype.getComponentByElement=function(p){for(;p;){var d=p.__ecComponentInfo;if(d!=null)return h._model.getComponent(d.mainType,d.index);p=p.parent}},c.prototype.enterEmphasis=function(p,d){ba(p,d),ee(h)},c.prototype.leaveEmphasis=function(p,d){xa(p,d),ee(h)},c.prototype.enterBlur=function(p){tm(p),ee(h)},c.prototype.leaveBlur=function(p){Ah(p),ee(h)},c.prototype.enterSelect=function(p){em(p),ee(h)},c.prototype.leaveSelect=function(p){rm(p),ee(h)},c.prototype.getModel=function(){return h.getModel()},c.prototype.getViewOfComponentModel=function(p){return h.getViewOfComponentModel(p)},c.prototype.getViewOfSeriesModel=function(p){return h.getViewOfSeriesModel(p)},c})(Xm))(h)},z0=function(h){function v(c,p){for(var d=0;d<c.length;d++){var g=c[d];g[ul]=p}}T(da,function(c,p){h._messageCenter.on(p,function(d){if(rd[h.group]&&h[ul]!==Kp){if(d&&d.escapeConnect)return;var g=h.makeActionFromEvent(d),y=[];T(ga,function(m){m!==h&&m.group===h.group&&y.push(m)}),v(y,Kp),T(y,function(m){m[ul]!==wC&&m.dispatchAction(g)}),v(y,bC)}})})}})(),t})(de),jh=V0.prototype;jh.on=k0("on");jh.off=k0("off");jh.one=function(r,t,e){var i=this;function n(){for(var a=[],o=0;o<arguments.length;o++)a[o]=arguments[o];t&&t.apply&&t.apply(this,a),i.off(r,n)}this.on.call(this,r,n,e)};var xC=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];var ds={},da={},Nf=[],Ff=[],gs=[],H0={},zf={},ga={},rd={},TC=+new Date-0,tv="_echarts_instance_";function MC(r,t,e){var i=!(e&&e.ssr);if(i){var n=CC(r);if(n)return n}var a=new V0(r,t,e);return a.id="ec_"+TC++,ga[a.id]=a,i&&Ny(r,tv,a.id),z0(a),be.trigger("afterinit",a),a}function CC(r){return ga[gw(r,tv)]}function G0(r,t){H0[r]=t}function W0(r){Q(Ff,r)<0&&Ff.push(r)}function U0(r,t){rv(Nf,r,t,cC)}function DC(r){ev("afterinit",r)}function AC(r){ev("afterupdate",r)}function ev(r,t){be.on(r,t)}function Ci(r,t,e){q(t)&&(e=t,t="");var i=W(r)?r.type:[r,r={event:t}][0];r.event=(r.event||i).toLowerCase(),t=r.event,!da[t]&&(ze(qp.test(i)&&qp.test(t)),ds[i]||(ds[i]={action:e,actionInfo:r}),da[t]=i)}function LC(r,t){Yh.register(r,t)}function PC(r,t){rv(gs,r,t,I0,"layout")}function Di(r,t){rv(gs,r,t,R0,"visual")}var id=[];function rv(r,t,e,i,n){if((q(t)||W(t))&&(e=t,t=i),!(Q(id,e)>=0)){id.push(e);var a=y0.wrapStageHandler(e,n);a.__prio=t,a.__raw=e,r.push(a)}}function Y0(r,t){zf[r]=t}function IC(r,t,e){var i=uC("registerMap");i&&i(r,t,e)}var RC=zT;Di(Jh,dM);Di(iu,gM);Di(iu,yM);Di(Jh,PM);Di(iu,IM);Di(E0,oC);W0(qm);U0(hC,bT);Y0("default",mM);Ci({type:ci,event:ci,update:ci},At);Ci({type:Fo,event:Fo,update:Fo},At);Ci({type:fa,event:fa,update:fa},At);Ci({type:zo,event:zo,update:zo},At);Ci({type:ha,event:ha,update:ha},At);G0("light",AM);G0("dark",w0);function Nn(r){return r==null?0:r.length||1}function nd(r){return r}var iv=(function(){function r(t,e,i,n,a,o){this._old=t,this._new=e,this._oldKeyGetter=i||nd,this._newKeyGetter=n||nd,this.context=a,this._diffModeMultiple=o==="multiple"}return r.prototype.add=function(t){return this._add=t,this},r.prototype.update=function(t){return this._update=t,this},r.prototype.updateManyToOne=function(t){return this._updateManyToOne=t,this},r.prototype.updateOneToMany=function(t){return this._updateOneToMany=t,this},r.prototype.updateManyToMany=function(t){return this._updateManyToMany=t,this},r.prototype.remove=function(t){return this._remove=t,this},r.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},r.prototype._executeOneToOne=function(){var t=this._old,e=this._new,i={},n=new Array(t.length),a=new Array(e.length);this._initIndexMap(t,null,n,"_oldKeyGetter"),this._initIndexMap(e,i,a,"_newKeyGetter");for(var o=0;o<t.length;o++){var s=n[o],u=i[s],l=Nn(u);if(l>1){var f=u.shift();u.length===1&&(i[s]=u[0]),this._update&&this._update(f,o)}else l===1?(i[s]=null,this._update&&this._update(u,o)):this._remove&&this._remove(o)}this._performRestAdd(a,i)},r.prototype._executeMultiple=function(){var t=this._old,e=this._new,i={},n={},a=[],o=[];this._initIndexMap(t,i,a,"_oldKeyGetter"),this._initIndexMap(e,n,o,"_newKeyGetter");for(var s=0;s<a.length;s++){var u=a[s],l=i[u],f=n[u],h=Nn(l),v=Nn(f);if(h>1&&v===1)this._updateManyToOne&&this._updateManyToOne(f,l),n[u]=null;else if(h===1&&v>1)this._updateOneToMany&&this._updateOneToMany(f,l),n[u]=null;else if(h===1&&v===1)this._update&&this._update(f,l),n[u]=null;else if(h>1&&v>1)this._updateManyToMany&&this._updateManyToMany(f,l),n[u]=null;else if(h>1)for(var c=0;c<h;c++)this._remove&&this._remove(l[c]);else this._remove&&this._remove(l)}this._performRestAdd(o,n)},r.prototype._performRestAdd=function(t,e){for(var i=0;i<t.length;i++){var n=t[i],a=e[n],o=Nn(a);if(o>1)for(var s=0;s<o;s++)this._add&&this._add(a[s]);else o===1&&this._add&&this._add(a);e[n]=null}},r.prototype._initIndexMap=function(t,e,i,n){for(var a=this._diffModeMultiple,o=0;o<t.length;o++){var s="_ec_"+this[n](t[o],o);if(a||(i[o]=s),!!e){var u=e[s],l=Nn(u);l===0?(e[s]=o,a&&i.push(s)):l===1?e[s]=[u,o]:u.push(o)}}},r})(),EC=(function(){function r(t,e){this._encode=t,this._schema=e}return r.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},r.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames},r})();function kC(r,t){var e={},i=e.encode={},n=X(),a=[],o=[],s={};T(r.dimensions,function(v){var c=r.getDimensionInfo(v),p=c.coordDim;if(p){var d=c.coordDimIndex;pl(i,p)[d]=v,c.isExtraCoord||(n.set(p,1),BC(c.type)&&(a[0]=v),pl(s,p)[d]=r.getDimensionIndex(c.name)),c.defaultTooltip&&o.push(v)}Gm.each(function(g,y){var m=pl(i,y),_=c.otherDims[y];_!=null&&_!==!1&&(m[_]=c.name)})});var u=[],l={};n.each(function(v,c){var p=i[c];l[c]=p[0],u=u.concat(p)}),e.dataDimsOnCoord=u,e.dataDimIndicesOnCoord=z(u,function(v){return r.getDimensionInfo(v).storeDimIndex}),e.encodeFirstDimNotExtra=l;var f=i.label;f&&f.length&&(a=f.slice());var h=i.tooltip;return h&&h.length?o=h.slice():o.length||(o=a.slice()),i.defaultedLabel=a,i.defaultedTooltip=o,e.userOutput=new EC(s,t),e}function pl(r,t){return r.hasOwnProperty(t)||(r[t]=[]),r[t]}function OC(r){return r==="category"?"ordinal":r==="time"?"time":"float"}function BC(r){return!(r==="ordinal"||r==="time")}var Go=(function(){function r(t){this.otherDims={},t!=null&&k(this,t)}return r})(),NC=vt(),FC={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},Z0=(function(){function r(t){this.dimensions=t.dimensions,this._dimOmitted=t.dimensionOmitted,this.source=t.source,this._fullDimCount=t.fullDimensionCount,this._updateDimOmitted(t.dimensionOmitted)}return r.prototype.isDimensionOmitted=function(){return this._dimOmitted},r.prototype._updateDimOmitted=function(t){this._dimOmitted=t,t&&(this._dimNameMap||(this._dimNameMap=q0(this.source)))},r.prototype.getSourceDimensionIndex=function(t){return $(this._dimNameMap.get(t),-1)},r.prototype.getSourceDimension=function(t){var e=this.source.dimensionsDefine;if(e)return e[t]},r.prototype.makeStoreSchema=function(){for(var t=this._fullDimCount,e=Jm(this.source),i=!K0(t),n="",a=[],o=0,s=0;o<t;o++){var u=void 0,l=void 0,f=void 0,h=this.dimensions[s];if(h&&h.storeDimIndex===o)u=e?h.name:null,l=h.type,f=h.ordinalMeta,s++;else{var v=this.getSourceDimension(o);v&&(u=e?v.name:null,l=v.type)}a.push({property:u,type:l,ordinalMeta:f}),e&&u!=null&&(!h||!h.isCalculationCoord)&&(n+=i?u.replace(/\`/g,"`1").replace(/\$/g,"`2"):u),n+="$",n+=FC[l]||"f",f&&(n+=f.uid),n+="$"}var c=this.source,p=[c.seriesLayoutBy,c.startIndex,n].join("$$");return{dimensions:a,hash:p}},r.prototype.makeOutputDimensionNames=function(){for(var t=[],e=0,i=0;e<this._fullDimCount;e++){var n=void 0,a=this.dimensions[i];if(a&&a.storeDimIndex===e)a.isCalculationCoord||(n=a.name),i++;else{var o=this.getSourceDimension(e);o&&(n=o.name)}t.push(n)}return t},r.prototype.appendCalculationDimension=function(t){this.dimensions.push(t),t.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},r})();function X0(r){return r instanceof Z0}function $0(r){for(var t=X(),e=0;e<(r||[]).length;e++){var i=r[e],n=W(i)?i.name:i;n!=null&&t.get(n)==null&&t.set(n,e)}return t}function q0(r){var t=NC(r);return t.dimNameMap||(t.dimNameMap=$0(r.dimensionsDefine))}function K0(r){return r>30}var Fn=W,vr=z,zC=typeof Int32Array>"u"?Array:Int32Array,VC="e\0\0",ad=-1,HC=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],GC=["_approximateExtent"],od,yo,zn,Vn,dl,Hn,gl,un=(function(){function r(t,e){this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","minmaxDownSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","minmaxDownSample","lttbDownSample"];var i,n=!1;X0(t)?(i=t.dimensions,this._dimOmitted=t.isDimensionOmitted(),this._schema=t):(n=!0,i=t),i=i||["x","y"];for(var a={},o=[],s={},u=!1,l={},f=0;f<i.length;f++){var h=i[f],v=H(h)?new Go({name:h}):h instanceof Go?h:new Go(h),c=v.name;v.type=v.type||"float",v.coordDim||(v.coordDim=c,v.coordDimIndex=0);var p=v.otherDims=v.otherDims||{};o.push(c),a[c]=v,l[c]!=null&&(u=!0),v.createInvertedIndices&&(s[c]=[]),p.itemName===0&&(this._nameDimIdx=f),p.itemId===0&&(this._idDimIdx=f),n&&(v.storeDimIndex=f)}if(this.dimensions=o,this._dimInfos=a,this._initGetDimensionInfo(u),this.hostModel=e,this._invertedIndicesMap=s,this._dimOmitted){var d=this._dimIdxToName=X();T(o,function(g){d.set(a[g].storeDimIndex,g)})}}return r.prototype.getDimension=function(t){var e=this._recognizeDimIndex(t);if(e==null)return t;if(e=t,!this._dimOmitted)return this.dimensions[e];var i=this._dimIdxToName.get(e);if(i!=null)return i;var n=this._schema.getSourceDimension(e);if(n)return n.name},r.prototype.getDimensionIndex=function(t){var e=this._recognizeDimIndex(t);if(e!=null)return e;if(t==null)return-1;var i=this._getDimInfo(t);return i?i.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(t):-1},r.prototype._recognizeDimIndex=function(t){if(dt(t)||t!=null&&!isNaN(t)&&!this._getDimInfo(t)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(t)<0))return+t},r.prototype._getStoreDimIndex=function(t){var e=this.getDimensionIndex(t);return e},r.prototype.getDimensionInfo=function(t){return this._getDimInfo(this.getDimension(t))},r.prototype._initGetDimensionInfo=function(t){var e=this._dimInfos;this._getDimInfo=t?function(i){return e.hasOwnProperty(i)?e[i]:void 0}:function(i){return e[i]}},r.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},r.prototype.mapDimension=function(t,e){var i=this._dimSummary;if(e==null)return i.encodeFirstDimNotExtra[t];var n=i.encode[t];return n?n[e]:null},r.prototype.mapDimensionsAll=function(t){var e=this._dimSummary,i=e.encode[t];return(i||[]).slice()},r.prototype.getStore=function(){return this._store},r.prototype.initData=function(t,e,i){var n=this,a;if(t instanceof Lf&&(a=t),!a){var o=this.dimensions,s=Zh(t)||zt(t)?new jm(t,o.length):t;a=new Lf;var u=vr(o,function(l){return{type:n._dimInfos[l].type,property:l}});a.initData(s,u,i)}this._store=a,this._nameList=(e||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,a.count()),this._dimSummary=kC(this,this._schema),this.userOutput=this._dimSummary.userOutput},r.prototype.appendData=function(t){var e=this._store.appendData(t);this._doInit(e[0],e[1])},r.prototype.appendValues=function(t,e){var i=this._store.appendValues(t,e&&e.length),n=i.start,a=i.end,o=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),e)for(var s=n;s<a;s++){var u=s-n;this._nameList[s]=e[u],o&&gl(this,s)}},r.prototype._updateOrdinalMeta=function(){for(var t=this._store,e=this.dimensions,i=0;i<e.length;i++){var n=this._dimInfos[e[i]];n.ordinalMeta&&t.collectOrdinalMeta(n.storeDimIndex,n.ordinalMeta)}},r.prototype._shouldMakeIdFromName=function(){var t=this._store.getProvider();return this._idDimIdx==null&&t.getSource().sourceFormat!==Mr&&!t.fillStorage},r.prototype._doInit=function(t,e){if(!(t>=e)){var i=this._store,n=i.getProvider();this._updateOrdinalMeta();var a=this._nameList,o=this._idList,s=n.getSource().sourceFormat,u=s===ge;if(u&&!n.pure)for(var l=[],f=t;f<e;f++){var h=n.getItem(f,l);if(!this.hasItemOption&&nw(h)&&(this.hasItemOption=!0),h){var v=h.name;a[f]==null&&v!=null&&(a[f]=Fe(v,null));var c=h.id;o[f]==null&&c!=null&&(o[f]=Fe(c,null))}}if(this._shouldMakeIdFromName())for(var f=t;f<e;f++)gl(this,f);od(this)}},r.prototype.getApproximateExtent=function(t){return this._approximateExtent[t]||this._store.getDataExtent(this._getStoreDimIndex(t))},r.prototype.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},r.prototype.getCalculationInfo=function(t){return this._calculationInfo[t]},r.prototype.setCalculationInfo=function(t,e){Fn(t)?k(this._calculationInfo,t):this._calculationInfo[t]=e},r.prototype.getName=function(t){var e=this.getRawIndex(t),i=this._nameList[e];return i==null&&this._nameDimIdx!=null&&(i=zn(this,this._nameDimIdx,e)),i==null&&(i=""),i},r.prototype._getCategory=function(t,e){var i=this._store.get(t,e),n=this._store.getOrdinalMeta(t);return n?n.categories[i]:i},r.prototype.getId=function(t){return yo(this,this.getRawIndex(t))},r.prototype.count=function(){return this._store.count()},r.prototype.get=function(t,e){var i=this._store,n=this._dimInfos[t];if(n)return i.get(n.storeDimIndex,e)},r.prototype.getByRawIndex=function(t,e){var i=this._store,n=this._dimInfos[t];if(n)return i.getByRawIndex(n.storeDimIndex,e)},r.prototype.getIndices=function(){return this._store.getIndices()},r.prototype.getDataExtent=function(t){return this._store.getDataExtent(this._getStoreDimIndex(t))},r.prototype.getSum=function(t){return this._store.getSum(this._getStoreDimIndex(t))},r.prototype.getMedian=function(t){return this._store.getMedian(this._getStoreDimIndex(t))},r.prototype.getValues=function(t,e){var i=this,n=this._store;return B(t)?n.getValues(vr(t,function(a){return i._getStoreDimIndex(a)}),e):n.getValues(t)},r.prototype.hasValue=function(t){for(var e=this._dimSummary.dataDimIndicesOnCoord,i=0,n=e.length;i<n;i++)if(isNaN(this._store.get(e[i],t)))return!1;return!0},r.prototype.indexOfName=function(t){for(var e=0,i=this._store.count();e<i;e++)if(this.getName(e)===t)return e;return-1},r.prototype.getRawIndex=function(t){return this._store.getRawIndex(t)},r.prototype.indexOfRawIndex=function(t){return this._store.indexOfRawIndex(t)},r.prototype.rawIndexOf=function(t,e){var i=t&&this._invertedIndicesMap[t],n=i&&i[e];return n==null||isNaN(n)?ad:n},r.prototype.indicesOfNearest=function(t,e,i){return this._store.indicesOfNearest(this._getStoreDimIndex(t),e,i)},r.prototype.each=function(t,e,i){q(t)&&(i=e,e=t,t=[]);var n=i||this,a=vr(Vn(t),this._getStoreDimIndex,this);this._store.each(a,n?U(e,n):e)},r.prototype.filterSelf=function(t,e,i){q(t)&&(i=e,e=t,t=[]);var n=i||this,a=vr(Vn(t),this._getStoreDimIndex,this);return this._store=this._store.filter(a,n?U(e,n):e),this},r.prototype.selectRange=function(t){var e=this,i={},n=ft(t);return T(n,function(a){var o=e._getStoreDimIndex(a);i[o]=t[a]}),this._store=this._store.selectRange(i),this},r.prototype.mapArray=function(t,e,i){q(t)&&(i=e,e=t,t=[]),i=i||this;var n=[];return this.each(t,function(){n.push(e&&e.apply(this,arguments))},i),n},r.prototype.map=function(t,e,i,n){var a=i||n||this,o=vr(Vn(t),this._getStoreDimIndex,this),s=Hn(this);return s._store=this._store.map(o,a?U(e,a):e),s},r.prototype.modify=function(t,e,i,n){var a=i||n||this,o=vr(Vn(t),this._getStoreDimIndex,this);this._store.modify(o,a?U(e,a):e)},r.prototype.downSample=function(t,e,i,n){var a=Hn(this);return a._store=this._store.downSample(this._getStoreDimIndex(t),e,i,n),a},r.prototype.minmaxDownSample=function(t,e){var i=Hn(this);return i._store=this._store.minmaxDownSample(this._getStoreDimIndex(t),e),i},r.prototype.lttbDownSample=function(t,e){var i=Hn(this);return i._store=this._store.lttbDownSample(this._getStoreDimIndex(t),e),i},r.prototype.getRawDataItem=function(t){return this._store.getRawDataItem(t)},r.prototype.getItemModel=function(t){var e=this.hostModel,i=this.getRawDataItem(t);return new St(i,e,e&&e.ecModel)},r.prototype.diff=function(t){var e=this;return new iv(t?t.getStore().getIndices():[],this.getStore().getIndices(),function(i){return yo(t,i)},function(i){return yo(e,i)})},r.prototype.getVisual=function(t){var e=this._visual;return e&&e[t]},r.prototype.setVisual=function(t,e){this._visual=this._visual||{},Fn(t)?k(this._visual,t):this._visual[t]=e},r.prototype.getItemVisual=function(t,e){var i=this._itemVisuals[t],n=i&&i[e];return n??this.getVisual(e)},r.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},r.prototype.ensureUniqueItemVisual=function(t,e){var i=this._itemVisuals,n=i[t];n||(n=i[t]={});var a=n[e];return a==null&&(a=this.getVisual(e),B(a)?a=a.slice():Fn(a)&&(a=k({},a)),n[e]=a),a},r.prototype.setItemVisual=function(t,e,i){var n=this._itemVisuals[t]||{};this._itemVisuals[t]=n,Fn(e)?k(n,e):n[e]=i},r.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},r.prototype.setLayout=function(t,e){Fn(t)?k(this._layout,t):this._layout[t]=e},r.prototype.getLayout=function(t){return this._layout[t]},r.prototype.getItemLayout=function(t){return this._itemLayouts[t]},r.prototype.setItemLayout=function(t,e,i){this._itemLayouts[t]=i?k(this._itemLayouts[t]||{},e):e},r.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},r.prototype.setItemGraphicEl=function(t,e){var i=this.hostModel&&this.hostModel.seriesIndex;gb(i,this.dataType,t,e),this._graphicEls[t]=e},r.prototype.getItemGraphicEl=function(t){return this._graphicEls[t]},r.prototype.eachItemGraphicEl=function(t,e){T(this._graphicEls,function(i,n){i&&t&&t.call(e,i,n)})},r.prototype.cloneShallow=function(t){return t||(t=new r(this._schema?this._schema:vr(this.dimensions,this._getDimInfo,this),this.hostModel)),dl(t,this),t._store=this._store,t},r.prototype.wrapMethod=function(t,e){var i=this[t];q(i)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var n=i.apply(this,arguments);return e.apply(this,[n].concat(ph(arguments)))})},r.internalField=(function(){od=function(t){var e=t._invertedIndicesMap;T(e,function(i,n){var a=t._dimInfos[n],o=a.ordinalMeta,s=t._store;if(o){i=e[n]=new zC(o.categories.length);for(var u=0;u<i.length;u++)i[u]=ad;for(var u=0;u<s.count();u++)i[s.get(a.storeDimIndex,u)]=u}})},zn=function(t,e,i){return Fe(t._getCategory(e,i),null)},yo=function(t,e){var i=t._idList[e];return i==null&&t._idDimIdx!=null&&(i=zn(t,t._idDimIdx,e)),i==null&&(i=VC+e),i},Vn=function(t){return B(t)||(t=t!=null?[t]:[]),t},Hn=function(t){var e=new r(t._schema?t._schema:vr(t.dimensions,t._getDimInfo,t),t.hostModel);return dl(e,t),e},dl=function(t,e){T(HC.concat(e.__wrappedMethods||[]),function(i){e.hasOwnProperty(i)&&(t[i]=e[i])}),t.__wrappedMethods=e.__wrappedMethods,T(GC,function(i){t[i]=Y(e[i])}),t._calculationInfo=k({},e._calculationInfo)},gl=function(t,e){var i=t._nameList,n=t._idList,a=t._nameDimIdx,o=t._idDimIdx,s=i[e],u=n[e];if(s==null&&a!=null&&(i[e]=s=zn(t,a,e)),u==null&&o!=null&&(n[e]=u=zn(t,o,e)),u==null&&s!=null){var l=t._nameRepeatCount,f=l[s]=(l[s]||0)+1;u=s,f>1&&(u+="__ec__"+f),n[e]=u}}})(),r})();function WC(r,t){Zh(r)||(r=Km(r)),t=t||{};var e=t.coordDimensions||[],i=t.dimensionsDefine||r.dimensionsDefine||[],n=X(),a=[],o=YC(r,e,i,t.dimensionsCount),s=t.canOmitUnusedDimensions&&K0(o),u=i===r.dimensionsDefine,l=u?q0(r):$0(i),f=t.encodeDefine;!f&&t.encodeDefaulter&&(f=t.encodeDefaulter(r,o));for(var h=X(f),v=new n0(o),c=0;c<v.length;c++)v[c]=-1;function p(M){var D=v[M];if(D<0){var A=i[M],P=W(A)?A:{name:A},R=new Go,L=P.name;L!=null&&l.get(L)!=null&&(R.name=R.displayName=L),P.type!=null&&(R.type=P.type),P.displayName!=null&&(R.displayName=P.displayName);var I=a.length;return v[M]=I,R.storeDimIndex=M,a.push(R),R}return a[D]}if(!s)for(var c=0;c<o;c++)p(c);h.each(function(M,D){var A=Ct(M).slice();if(A.length===1&&!H(A[0])&&A[0]<0){h.set(D,!1);return}var P=h.set(D,[]);T(A,function(R,L){var I=H(R)?l.get(R):R;I!=null&&I<o&&(P[L]=I,g(p(I),D,L))})});var d=0;T(e,function(M){var D,A,P,R;if(H(M))D=M,R={};else{R=M,D=R.name;var L=R.ordinalMeta;R.ordinalMeta=null,R=k({},R),R.ordinalMeta=L,A=R.dimsDef,P=R.otherDims,R.name=R.coordDim=R.coordDimIndex=R.dimsDef=R.otherDims=null}var I=h.get(D);if(I!==!1){if(I=Ct(I),!I.length)for(var E=0;E<(A&&A.length||1);E++){for(;d<o&&p(d).coordDim!=null;)d++;d<o&&I.push(d++)}T(I,function(G,V){var F=p(G);if(u&&R.type!=null&&(F.type=R.type),g(rt(F,R),D,V),F.name==null&&A){var J=A[V];!W(J)&&(J={name:J}),F.name=F.displayName=J.name,F.defaultTooltip=J.defaultTooltip}P&&rt(F.otherDims,P)})}});function g(M,D,A){Gm.get(D)!=null?M.otherDims[D]=A:(M.coordDim=D,M.coordDimIndex=A,n.set(D,!0))}var y=t.generateCoord,m=t.generateCoordCount,_=m!=null;m=y?m||1:0;var S=y||"value";function b(M){M.name==null&&(M.name=M.coordDim)}if(s)T(a,function(M){b(M)}),a.sort(function(M,D){return M.storeDimIndex-D.storeDimIndex});else for(var w=0;w<o;w++){var x=p(w),C=x.coordDim;C==null&&(x.coordDim=ZC(S,n,_),x.coordDimIndex=0,(!y||m<=0)&&(x.isExtraCoord=!0),m--),b(x),x.type==null&&(Zm(r,w)===Kt.Must||x.isExtraCoord&&(x.otherDims.itemName!=null||x.otherDims.seriesName!=null))&&(x.type="ordinal")}return UC(a),new Z0({source:r,dimensions:a,fullDimensionCount:o,dimensionOmitted:s})}function UC(r){for(var t=X(),e=0;e<r.length;e++){var i=r[e],n=i.name,a=t.get(n)||0;a>0&&(i.name=n+(a-1)),a++,t.set(n,a)}}function YC(r,t,e,i){var n=Math.max(r.dimensionsDetectedCount||1,t.length,e.length,i||0);return T(t,function(a){var o;W(a)&&(o=a.dimsDef)&&(n=Math.max(n,o.length))}),n}function ZC(r,t,e){if(e||t.hasKey(r)){for(var i=0;t.hasKey(r+i);)i++;r+=i}return t.set(r,!0),r}var XC=(function(){function r(t){this.coordSysDims=[],this.axisMap=X(),this.categoryAxisMap=X(),this.coordSysName=t}return r})();function $C(r){var t=r.get("coordinateSystem"),e=new XC(t),i=qC[t];if(i)return i(r,e,e.axisMap,e.categoryAxisMap),e}var qC={cartesian2d:function(r,t,e,i){var n=r.getReferringComponents("xAxis",Ut).models[0],a=r.getReferringComponents("yAxis",Ut).models[0];t.coordSysDims=["x","y"],e.set("x",n),e.set("y",a),Gi(n)&&(i.set("x",n),t.firstCategoryDimIndex=0),Gi(a)&&(i.set("y",a),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=1))},singleAxis:function(r,t,e,i){var n=r.getReferringComponents("singleAxis",Ut).models[0];t.coordSysDims=["single"],e.set("single",n),Gi(n)&&(i.set("single",n),t.firstCategoryDimIndex=0)},polar:function(r,t,e,i){var n=r.getReferringComponents("polar",Ut).models[0],a=n.findAxisModel("radiusAxis"),o=n.findAxisModel("angleAxis");t.coordSysDims=["radius","angle"],e.set("radius",a),e.set("angle",o),Gi(a)&&(i.set("radius",a),t.firstCategoryDimIndex=0),Gi(o)&&(i.set("angle",o),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=1))},geo:function(r,t,e,i){t.coordSysDims=["lng","lat"]},parallel:function(r,t,e,i){var n=r.ecModel,a=n.getComponent("parallel",r.get("parallelIndex")),o=t.coordSysDims=a.dimensions.slice();T(a.parallelAxisIndex,function(s,u){var l=n.getComponent("parallelAxis",s),f=o[u];e.set(f,l),Gi(l)&&(i.set(f,l),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=u))})}};function Gi(r){return r.get("type")==="category"}function KC(r,t,e){e=e||{};var i=e.byIndex,n=e.stackedCoordDimension,a,o,s;QC(t)?a=t:(o=t.schema,a=o.dimensions,s=t.store);var u=!!(r&&r.get("stack")),l,f,h,v;if(T(a,function(m,_){H(m)&&(a[_]=m={name:m}),u&&!m.isExtraCoord&&(!i&&!l&&m.ordinalMeta&&(l=m),!f&&m.type!=="ordinal"&&m.type!=="time"&&(!n||n===m.coordDim)&&(f=m))}),f&&!i&&!l&&(i=!0),f){h="__\0ecstackresult_"+r.id,v="__\0ecstackedover_"+r.id,l&&(l.createInvertedIndices=!0);var c=f.coordDim,p=f.type,d=0;T(a,function(m){m.coordDim===c&&d++});var g={name:h,coordDim:c,coordDimIndex:d,type:p,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length},y={name:v,coordDim:v,coordDimIndex:d+1,type:p,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length+1};o?(s&&(g.storeDimIndex=s.ensureCalculationDimension(v,p),y.storeDimIndex=s.ensureCalculationDimension(h,p)),o.appendCalculationDimension(g),o.appendCalculationDimension(y)):(a.push(g),a.push(y))}return{stackedDimension:f&&f.name,stackedByDimension:l&&l.name,isStackedByIndex:i,stackedOverDimension:v,stackResultDimension:h}}function QC(r){return!X0(r.schema)}function pn(r,t){return!!t&&t===r.getCalculationInfo("stackedDimension")}function Q0(r,t){return pn(r,t)?r.getCalculationInfo("stackResultDimension"):t}function JC(r,t){var e=r.get("coordinateSystem"),i=Yh.get(e),n;return t&&t.coordSysDims&&(n=z(t.coordSysDims,function(a){var o={name:a},s=t.axisMap.get(a);if(s){var u=s.get("type");o.type=OC(u)}return o})),n||(n=i&&(i.getDimensionsInfo?i.getDimensionsInfo():i.dimensions.slice())||["x","y"]),n}function jC(r,t,e){var i,n;return e&&T(r,function(a,o){var s=a.coordDim,u=e.categoryAxisMap.get(s);u&&(i==null&&(i=o),a.ordinalMeta=u.getOrdinalMeta(),t&&(a.createInvertedIndices=!0)),a.otherDims.itemName!=null&&(n=!0)}),!n&&i!=null&&(r[i].otherDims.itemName=0),i}function nv(r,t,e){e=e||{};var i=t.getSourceManager(),n,a=!1;n=i.getSource(),a=n.sourceFormat===ge;var o=$C(t),s=JC(t,o),u=e.useEncodeDefaulter,l=q(u)?u:u?ot(Qx,s,t):null,f={coordDimensions:s,generateCoord:e.generateCoord,encodeDefine:t.getEncode(),encodeDefaulter:l,canOmitUnusedDimensions:!a},h=WC(n,f),v=jC(h.dimensions,e.createInvertedIndices,o),c=a?null:i.getSharedDataStore(h),p=KC(t,{schema:h,store:c}),d=new un(h,t);d.setCalculationInfo(p);var g=v!=null&&tD(n)?function(y,m,_,S){return S===v?_:this.defaultDimValueGetter(y,m,_,S)}:null;return d.hasItemOption=!1,d.initData(a?n:c,null,g),d}function tD(r){if(r.sourceFormat===ge){var t=eD(r.data||[]);return!B(Fa(t))}}function eD(r){for(var t=0;t<r.length&&r[t]==null;)t++;return r[t]}var We=(function(){function r(t){this._setting=t||{},this._extent=[1/0,-1/0]}return r.prototype.getSetting=function(t){return this._setting[t]},r.prototype.unionExtent=function(t){var e=this._extent;t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1])},r.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.setExtent=function(t,e){var i=this._extent;isNaN(t)||(i[0]=t),isNaN(e)||(i[1]=e)},r.prototype.isInExtentRange=function(t){return this._extent[0]<=t&&this._extent[1]>=t},r.prototype.isBlank=function(){return this._isBlank},r.prototype.setBlank=function(t){this._isBlank=t},r})();Rs(We);var rD=0,Vf=(function(){function r(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this.uid=++rD}return r.createByAxisModel=function(t){var e=t.option,i=e.data,n=i&&z(i,iD);return new r({categories:n,needCollect:!n,deduplication:e.dedplication!==!1})},r.prototype.getOrdinal=function(t){return this._getOrCreateMap().get(t)},r.prototype.parseAndCollect=function(t){var e,i=this._needCollect;if(!H(t)&&!i)return t;if(i&&!this._deduplication)return e=this.categories.length,this.categories[e]=t,e;var n=this._getOrCreateMap();return e=n.get(t),e==null&&(i?(e=this.categories.length,this.categories[e]=t,n.set(t,e)):e=NaN),e},r.prototype._getOrCreateMap=function(){return this._map||(this._map=X(this.categories))},r})();function iD(r){return W(r)&&r.value!=null?r.value:r+""}function Hf(r){return r.type==="interval"||r.type==="log"}function nD(r,t,e,i){var n={},a=r[1]-r[0],o=n.interval=Iy(a/t);e!=null&&o<e&&(o=n.interval=e),i!=null&&o>i&&(o=n.interval=i);var s=n.intervalPrecision=J0(o),u=n.niceTickExtent=[xt(Math.ceil(r[0]/o)*o,s),xt(Math.floor(r[1]/o)*o,s)];return aD(u,r),n}function yl(r){var t=Math.pow(10,bh(r)),e=r/t;return e?e===2?e=3:e===3?e=5:e*=2:e=1,xt(e*t)}function J0(r){return Be(r)+2}function sd(r,t,e){r[t]=Math.max(Math.min(r[t],e[1]),e[0])}function aD(r,t){!isFinite(r[0])&&(r[0]=t[0]),!isFinite(r[1])&&(r[1]=t[1]),sd(r,0,t),sd(r,1,t),r[0]>r[1]&&(r[0]=r[1])}function nu(r,t){return r>=t[0]&&r<=t[1]}function au(r,t){return t[1]===t[0]?.5:(r-t[0])/(t[1]-t[0])}function ou(r,t){return r*(t[1]-t[0])+t[0]}var av=(function(r){O(t,r);function t(e){var i=r.call(this,e)||this;i.type="ordinal";var n=i.getSetting("ordinalMeta");return n||(n=new Vf({})),B(n)&&(n=new Vf({categories:z(n,function(a){return W(a)?a.value:a})})),i._ordinalMeta=n,i._extent=i.getSetting("extent")||[0,n.categories.length-1],i}return t.prototype.parse=function(e){return e==null?NaN:H(e)?this._ordinalMeta.getOrdinal(e):Math.round(e)},t.prototype.contain=function(e){return e=this.parse(e),nu(e,this._extent)&&this._ordinalMeta.categories[e]!=null},t.prototype.normalize=function(e){return e=this._getTickNumber(this.parse(e)),au(e,this._extent)},t.prototype.scale=function(e){return e=Math.round(ou(e,this._extent)),this.getRawOrdinalNumber(e)},t.prototype.getTicks=function(){for(var e=[],i=this._extent,n=i[0];n<=i[1];)e.push({value:n}),n++;return e},t.prototype.getMinorTicks=function(e){},t.prototype.setSortInfo=function(e){if(e==null){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var i=e.ordinalNumbers,n=this._ordinalNumbersByTick=[],a=this._ticksByOrdinalNumber=[],o=0,s=this._ordinalMeta.categories.length,u=Math.min(s,i.length);o<u;++o){var l=i[o];n[o]=l,a[l]=o}for(var f=0;o<s;++o){for(;a[f]!=null;)f++;n.push(f),a[f]=o}},t.prototype._getTickNumber=function(e){var i=this._ticksByOrdinalNumber;return i&&e>=0&&e<i.length?i[e]:e},t.prototype.getRawOrdinalNumber=function(e){var i=this._ordinalNumbersByTick;return i&&e>=0&&e<i.length?i[e]:e},t.prototype.getLabel=function(e){if(!this.isBlank()){var i=this.getRawOrdinalNumber(e.value),n=this._ordinalMeta.categories[i];return n==null?"":n+""}},t.prototype.count=function(){return this._extent[1]-this._extent[0]+1},t.prototype.unionExtentFromData=function(e,i){this.unionExtent(e.getApproximateExtent(i))},t.prototype.isInExtentRange=function(e){return e=this._getTickNumber(e),this._extent[0]<=e&&this._extent[1]>=e},t.prototype.getOrdinalMeta=function(){return this._ordinalMeta},t.prototype.calcNiceTicks=function(){},t.prototype.calcNiceExtent=function(){},t.type="ordinal",t})(We);We.registerClass(av);var ti=xt,bn=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="interval",e._interval=0,e._intervalPrecision=2,e}return t.prototype.parse=function(e){return e},t.prototype.contain=function(e){return nu(e,this._extent)},t.prototype.normalize=function(e){return au(e,this._extent)},t.prototype.scale=function(e){return ou(e,this._extent)},t.prototype.setExtent=function(e,i){var n=this._extent;isNaN(e)||(n[0]=parseFloat(e)),isNaN(i)||(n[1]=parseFloat(i))},t.prototype.unionExtent=function(e){var i=this._extent;e[0]<i[0]&&(i[0]=e[0]),e[1]>i[1]&&(i[1]=e[1]),this.setExtent(i[0],i[1])},t.prototype.getInterval=function(){return this._interval},t.prototype.setInterval=function(e){this._interval=e,this._niceExtent=this._extent.slice(),this._intervalPrecision=J0(e)},t.prototype.getTicks=function(e){var i=this._interval,n=this._extent,a=this._niceExtent,o=this._intervalPrecision,s=[];if(!i)return s;var u=1e4;n[0]<a[0]&&(e?s.push({value:ti(a[0]-i,o)}):s.push({value:n[0]}));for(var l=a[0];l<=a[1]&&(s.push({value:l}),l=ti(l+i,o),l!==s[s.length-1].value);)if(s.length>u)return[];var f=s.length?s[s.length-1].value:a[1];return n[1]>f&&(e?s.push({value:ti(f+i,o)}):s.push({value:n[1]})),s},t.prototype.getMinorTicks=function(e){for(var i=this.getTicks(!0),n=[],a=this.getExtent(),o=1;o<i.length;o++){for(var s=i[o],u=i[o-1],l=0,f=[],h=s.value-u.value,v=h/e;l<e-1;){var c=ti(u.value+(l+1)*v);c>a[0]&&c<a[1]&&f.push(c),l++}n.push(f)}return n},t.prototype.getLabel=function(e,i){if(e==null)return"";var n=i&&i.precision;n==null?n=Be(e.value)||0:n==="auto"&&(n=this._intervalPrecision);var a=ti(e.value,n,!0);return Nm(a)},t.prototype.calcNiceTicks=function(e,i,n){e=e||5;var a=this._extent,o=a[1]-a[0];if(isFinite(o)){o<0&&(o=-o,a.reverse());var s=nD(a,e,i,n);this._intervalPrecision=s.intervalPrecision,this._interval=s.interval,this._niceExtent=s.niceTickExtent}},t.prototype.calcNiceExtent=function(e){var i=this._extent;if(i[0]===i[1])if(i[0]!==0){var n=Math.abs(i[0]);e.fixMax||(i[1]+=n/2),i[0]-=n/2}else i[1]=1;var a=i[1]-i[0];isFinite(a)||(i[0]=0,i[1]=1),this.calcNiceTicks(e.splitNumber,e.minInterval,e.maxInterval);var o=this._interval;e.fixMin||(i[0]=ti(Math.floor(i[0]/o)*o)),e.fixMax||(i[1]=ti(Math.ceil(i[1]/o)*o))},t.prototype.setNiceExtent=function(e,i){this._niceExtent=[e,i]},t.type="interval",t})(We);We.registerClass(bn);var j0=typeof Float32Array<"u",oD=j0?Float32Array:Array;function Qi(r){return B(r)?j0?new Float32Array(r):r:new oD(r)}var Gf="__ec_stack_";function sD(r){return r.get("stack")||Gf+r.seriesIndex}function t_(r){return r.dim+r.index}function uD(r){var t=[],e=r.axis,i="axis0";if(e.type==="category"){for(var n=e.getBandWidth(),a=0;a<r.count;a++)t.push(rt({bandWidth:n,axisKey:i,stackId:Gf+a},r));for(var o=e_(t),s=[],a=0;a<r.count;a++){var u=o[i][Gf+a];u.offsetCenter=u.offset+u.width/2,s.push(u)}return s}}function lD(r,t){var e=[];return t.eachSeriesByType(r,function(i){cD(i)&&e.push(i)}),e}function fD(r){var t={};T(r,function(u){var l=u.coordinateSystem,f=l.getBaseAxis();if(!(f.type!=="time"&&f.type!=="value"))for(var h=u.getData(),v=f.dim+"_"+f.index,c=h.getDimensionIndex(h.mapDimension(f.dim)),p=h.getStore(),d=0,g=p.count();d<g;++d){var y=p.get(c,d);t[v]?t[v].push(y):t[v]=[y]}});var e={};for(var i in t)if(t.hasOwnProperty(i)){var n=t[i];if(n){n.sort(function(u,l){return u-l});for(var a=null,o=1;o<n.length;++o){var s=n[o]-n[o-1];s>0&&(a=a===null?s:Math.min(a,s))}e[i]=a}}return e}function hD(r){var t=fD(r),e=[];return T(r,function(i){var n=i.coordinateSystem,a=n.getBaseAxis(),o=a.getExtent(),s;if(a.type==="category")s=a.getBandWidth();else if(a.type==="value"||a.type==="time"){var u=a.dim+"_"+a.index,l=t[u],f=Math.abs(o[1]-o[0]),h=a.scale.getExtent(),v=Math.abs(h[1]-h[0]);s=l?f/v*l:f}else{var c=i.getData();s=Math.abs(o[1]-o[0])/c.count()}var p=yt(i.get("barWidth"),s),d=yt(i.get("barMaxWidth"),s),g=yt(i.get("barMinWidth")||(pD(i)?.5:1),s),y=i.get("barGap"),m=i.get("barCategoryGap");e.push({bandWidth:s,barWidth:p,barMaxWidth:d,barMinWidth:g,barGap:y,barCategoryGap:m,axisKey:t_(a),stackId:sD(i)})}),e_(e)}function e_(r){var t={};T(r,function(i,n){var a=i.axisKey,o=i.bandWidth,s=t[a]||{bandWidth:o,remainedWidth:o,autoWidthCount:0,categoryGap:null,gap:"20%",stacks:{}},u=s.stacks;t[a]=s;var l=i.stackId;u[l]||s.autoWidthCount++,u[l]=u[l]||{width:0,maxWidth:0};var f=i.barWidth;f&&!u[l].width&&(u[l].width=f,f=Math.min(s.remainedWidth,f),s.remainedWidth-=f);var h=i.barMaxWidth;h&&(u[l].maxWidth=h);var v=i.barMinWidth;v&&(u[l].minWidth=v);var c=i.barGap;c!=null&&(s.gap=c);var p=i.barCategoryGap;p!=null&&(s.categoryGap=p)});var e={};return T(t,function(i,n){e[n]={};var a=i.stacks,o=i.bandWidth,s=i.categoryGap;if(s==null){var u=ft(a).length;s=Math.max(35-u*4,15)+"%"}var l=yt(s,o),f=yt(i.gap,1),h=i.remainedWidth,v=i.autoWidthCount,c=(h-l)/(v+(v-1)*f);c=Math.max(c,0),T(a,function(y){var m=y.maxWidth,_=y.minWidth;if(y.width){var S=y.width;m&&(S=Math.min(S,m)),_&&(S=Math.max(S,_)),y.width=S,h-=S+f*S,v--}else{var S=c;m&&m<S&&(S=Math.min(m,h)),_&&_>S&&(S=_),S!==c&&(y.width=S,h-=S+f*S,v--)}}),c=(h-l)/(v+(v-1)*f),c=Math.max(c,0);var p=0,d;T(a,function(y,m){y.width||(y.width=c),d=y,p+=y.width*(1+f)}),d&&(p-=d.width*f);var g=-p/2;T(a,function(y,m){e[n][m]=e[n][m]||{bandWidth:o,offset:g,width:y.width},g+=y.width*(1+f)})}),e}function vD(r,t,e){if(r&&t){var i=r[t_(t)];return i}}function cD(r){return r.coordinateSystem&&r.coordinateSystem.type==="cartesian2d"}function pD(r){return r.pipelineContext&&r.pipelineContext.large}var dD=function(r,t,e,i){for(;e<i;){var n=e+i>>>1;r[n][1]<t?e=n+1:i=n}return e},r_=(function(r){O(t,r);function t(e){var i=r.call(this,e)||this;return i.type="time",i}return t.prototype.getLabel=function(e){var i=this.getSetting("useUTC");return $s(e.value,jc[Hx(on(this._minLevelUnit))]||jc.second,i,this.getSetting("locale"))},t.prototype.getFormattedLabel=function(e,i,n){var a=this.getSetting("useUTC"),o=this.getSetting("locale");return Gx(e,i,n,o,a)},t.prototype.getTicks=function(){var e=this._interval,i=this._extent,n=[];if(!e)return n;n.push({value:i[0],level:0});var a=this.getSetting("useUTC"),o=bD(this._minLevelUnit,this._approxInterval,a,i);return n=n.concat(o),n.push({value:i[1],level:0}),n},t.prototype.calcNiceExtent=function(e){var i=this._extent;if(i[0]===i[1]&&(i[0]-=he,i[1]+=he),i[1]===-1/0&&i[0]===1/0){var n=new Date;i[1]=+new Date(n.getFullYear(),n.getMonth(),n.getDate()),i[0]=i[1]-he}this.calcNiceTicks(e.splitNumber,e.minInterval,e.maxInterval)},t.prototype.calcNiceTicks=function(e,i,n){e=e||10;var a=this._extent,o=a[1]-a[0];this._approxInterval=o/e,i!=null&&this._approxInterval<i&&(this._approxInterval=i),n!=null&&this._approxInterval>n&&(this._approxInterval=n);var s=mo.length,u=Math.min(dD(mo,this._approxInterval,0,s),s-1);this._interval=mo[u][1],this._minLevelUnit=mo[Math.max(u-1,0)][0]},t.prototype.parse=function(e){return dt(e)?e:+tr(e)},t.prototype.contain=function(e){return nu(this.parse(e),this._extent)},t.prototype.normalize=function(e){return au(this.parse(e),this._extent)},t.prototype.scale=function(e){return ou(e,this._extent)},t.type="time",t})(bn),mo=[["second",Fh],["minute",zh],["hour",ca],["quarter-day",ca*6],["half-day",ca*12],["day",he*1.2],["half-week",he*3.5],["week",he*7],["month",he*31],["quarter",he*95],["half-year",Jc/2],["year",Jc]];function gD(r,t,e,i){var n=tr(t),a=tr(e),o=function(p){return tp(n,p,i)===tp(a,p,i)},s=function(){return o("year")},u=function(){return s()&&o("month")},l=function(){return u()&&o("day")},f=function(){return l()&&o("hour")},h=function(){return f()&&o("minute")},v=function(){return h()&&o("second")},c=function(){return v()&&o("millisecond")};switch(r){case"year":return s();case"month":return u();case"day":return l();case"hour":return f();case"minute":return h();case"second":return v();case"millisecond":return c()}}function yD(r,t){return r/=he,r>16?16:r>7.5?7:r>3.5?4:r>1.5?2:1}function mD(r){var t=30*he;return r/=t,r>6?6:r>3?3:r>2?2:1}function _D(r){return r/=ca,r>12?12:r>6?6:r>3.5?4:r>2?2:1}function ud(r,t){return r/=t?zh:Fh,r>30?30:r>20?20:r>15?15:r>10?10:r>5?5:r>2?2:1}function SD(r){return Iy(r)}function wD(r,t,e){var i=new Date(r);switch(on(t)){case"year":case"month":i[Im(e)](0);case"day":i[Rm(e)](1);case"hour":i[Em(e)](0);case"minute":i[km(e)](0);case"second":i[Om(e)](0),i[Bm(e)](0)}return i.getTime()}function bD(r,t,e,i){var n=1e4,a=Lm,o=0;function s(D,A,P,R,L,I,E){for(var G=new Date(A),V=A,F=G[R]();V<P&&V<=i[1];)E.push({value:V}),F+=D,G[L](F),V=G.getTime();E.push({value:V,notAdd:!0})}function u(D,A,P){var R=[],L=!A.length;if(!gD(on(D),i[0],i[1],e)){L&&(A=[{value:wD(new Date(i[0]),D,e)},{value:i[1]}]);for(var I=0;I<A.length-1;I++){var E=A[I].value,G=A[I+1].value;if(E!==G){var V=void 0,F=void 0,J=void 0,ut=!1;switch(D){case"year":V=Math.max(1,Math.round(t/he/365)),F=Vh(e),J=Wx(e);break;case"half-year":case"quarter":case"month":V=mD(t),F=sn(e),J=Im(e);break;case"week":case"half-week":case"day":V=yD(t),F=qs(e),J=Rm(e),ut=!0;break;case"half-day":case"quarter-day":case"hour":V=_D(t),F=Ca(e),J=Em(e);break;case"minute":V=ud(t,!0),F=Ks(e),J=km(e);break;case"second":V=ud(t,!1),F=Qs(e),J=Om(e);break;case"millisecond":V=SD(t),F=Js(e),J=Bm(e);break}s(V,E,G,F,J,ut,R),D==="year"&&P.length>1&&I===0&&P.unshift({value:P[0].value-V})}}for(var I=0;I<R.length;I++)P.push(R[I]);return R}}for(var l=[],f=[],h=0,v=0,c=0;c<a.length&&o++<n;++c){var p=on(a[c]);if(Vx(a[c])){u(a[c],l[l.length-1]||[],f);var d=a[c+1]?on(a[c+1]):null;if(p!==d){if(f.length){v=h,f.sort(function(D,A){return D.value-A.value});for(var g=[],y=0;y<f.length;++y){var m=f[y].value;(y===0||f[y-1].value!==m)&&(g.push(f[y]),m>=i[0]&&m<=i[1]&&h++)}var _=(i[1]-i[0])/t;if(h>_*1.5&&v>_/1.5||(l.push(g),h>_||r===a[c]))break}f=[]}}}for(var S=_t(z(l,function(D){return _t(D,function(A){return A.value>=i[0]&&A.value<=i[1]&&!A.notAdd})}),function(D){return D.length>0}),b=[],w=S.length-1,c=0;c<S.length;++c)for(var x=S[c],C=0;C<x.length;++C)b.push({value:x[C].value,level:w-c});b.sort(function(D,A){return D.value-A.value});for(var M=[],c=0;c<b.length;++c)(c===0||b[c].value!==b[c-1].value)&&M.push(b[c]);return M}We.registerClass(r_);var ld=We.prototype,ya=bn.prototype,xD=xt,TD=Math.floor,MD=Math.ceil,_o=Math.pow,_e=Math.log,ov=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="log",e.base=10,e._originalScale=new bn,e._interval=0,e}return t.prototype.getTicks=function(e){var i=this._originalScale,n=this._extent,a=i.getExtent(),o=ya.getTicks.call(this,e);return z(o,function(s){var u=s.value,l=xt(_o(this.base,u));return l=u===n[0]&&this._fixMin?So(l,a[0]):l,l=u===n[1]&&this._fixMax?So(l,a[1]):l,{value:l}},this)},t.prototype.setExtent=function(e,i){var n=_e(this.base);e=_e(Math.max(0,e))/n,i=_e(Math.max(0,i))/n,ya.setExtent.call(this,e,i)},t.prototype.getExtent=function(){var e=this.base,i=ld.getExtent.call(this);i[0]=_o(e,i[0]),i[1]=_o(e,i[1]);var n=this._originalScale,a=n.getExtent();return this._fixMin&&(i[0]=So(i[0],a[0])),this._fixMax&&(i[1]=So(i[1],a[1])),i},t.prototype.unionExtent=function(e){this._originalScale.unionExtent(e);var i=this.base;e[0]=_e(e[0])/_e(i),e[1]=_e(e[1])/_e(i),ld.unionExtent.call(this,e)},t.prototype.unionExtentFromData=function(e,i){this.unionExtent(e.getApproximateExtent(i))},t.prototype.calcNiceTicks=function(e){e=e||10;var i=this._extent,n=i[1]-i[0];if(!(n===1/0||n<=0)){var a=ew(n),o=e/n*a;for(o<=.5&&(a*=10);!isNaN(a)&&Math.abs(a)<1&&Math.abs(a)>0;)a*=10;var s=[xt(MD(i[0]/a)*a),xt(TD(i[1]/a)*a)];this._interval=a,this._niceExtent=s}},t.prototype.calcNiceExtent=function(e){ya.calcNiceExtent.call(this,e),this._fixMin=e.fixMin,this._fixMax=e.fixMax},t.prototype.parse=function(e){return e},t.prototype.contain=function(e){return e=_e(e)/_e(this.base),nu(e,this._extent)},t.prototype.normalize=function(e){return e=_e(e)/_e(this.base),au(e,this._extent)},t.prototype.scale=function(e){return e=ou(e,this._extent),_o(this.base,e)},t.type="log",t})(We),i_=ov.prototype;i_.getMinorTicks=ya.getMinorTicks;i_.getLabel=ya.getLabel;function So(r,t){return xD(r,Be(t))}We.registerClass(ov);var CD=(function(){function r(t,e,i){this._prepareParams(t,e,i)}return r.prototype._prepareParams=function(t,e,i){i[1]<i[0]&&(i=[NaN,NaN]),this._dataMin=i[0],this._dataMax=i[1];var n=this._isOrdinal=t.type==="ordinal";this._needCrossZero=t.type==="interval"&&e.getNeedCrossZero&&e.getNeedCrossZero();var a=e.get("min",!0);a==null&&(a=e.get("startValue",!0));var o=this._modelMinRaw=a;q(o)?this._modelMinNum=wo(t,o({min:i[0],max:i[1]})):o!=="dataMin"&&(this._modelMinNum=wo(t,o));var s=this._modelMaxRaw=e.get("max",!0);if(q(s)?this._modelMaxNum=wo(t,s({min:i[0],max:i[1]})):s!=="dataMax"&&(this._modelMaxNum=wo(t,s)),n)this._axisDataLen=e.getCategories().length;else{var u=e.get("boundaryGap"),l=B(u)?u:[u||0,u||0];typeof l[0]=="boolean"||typeof l[1]=="boolean"?this._boundaryGapInner=[0,0]:this._boundaryGapInner=[gi(l[0],1),gi(l[1],1)]}},r.prototype.calculate=function(){var t=this._isOrdinal,e=this._dataMin,i=this._dataMax,n=this._axisDataLen,a=this._boundaryGapInner,o=t?null:i-e||Math.abs(e),s=this._modelMinRaw==="dataMin"?e:this._modelMinNum,u=this._modelMaxRaw==="dataMax"?i:this._modelMaxNum,l=s!=null,f=u!=null;s==null&&(s=t?n?0:NaN:e-a[0]*o),u==null&&(u=t?n?n-1:NaN:i+a[1]*o),(s==null||!isFinite(s))&&(s=NaN),(u==null||!isFinite(u))&&(u=NaN);var h=Yo(s)||Yo(u)||t&&!n;this._needCrossZero&&(s>0&&u>0&&!l&&(s=0),s<0&&u<0&&!f&&(u=0));var v=this._determinedMin,c=this._determinedMax;return v!=null&&(s=v,l=!0),c!=null&&(u=c,f=!0),{min:s,max:u,minFixed:l,maxFixed:f,isBlank:h}},r.prototype.modifyDataMinMax=function(t,e){this[AD[t]]=e},r.prototype.setDeterminedMinMax=function(t,e){var i=DD[t];this[i]=e},r.prototype.freeze=function(){this.frozen=!0},r})(),DD={min:"_determinedMin",max:"_determinedMax"},AD={min:"_dataMin",max:"_dataMax"};function n_(r,t,e){var i=r.rawExtentInfo;return i||(i=new CD(r,t,e),r.rawExtentInfo=i,i)}function wo(r,t){return t==null?null:Yo(t)?NaN:r.parse(t)}function a_(r,t){var e=r.type,i=n_(r,t,r.getExtent()).calculate();r.setBlank(i.isBlank);var n=i.min,a=i.max,o=t.ecModel;if(o&&e==="time"){var s=lD("bar",o),u=!1;if(T(s,function(h){u=u||h.getBaseAxis()===t.axis}),u){var l=hD(s),f=LD(n,a,t,l);n=f.min,a=f.max}}return{extent:[n,a],fixMin:i.minFixed,fixMax:i.maxFixed}}function LD(r,t,e,i){var n=e.axis.getExtent(),a=Math.abs(n[1]-n[0]),o=vD(i,e.axis);if(o===void 0)return{min:r,max:t};var s=1/0;T(o,function(c){s=Math.min(c.offset,s)});var u=-1/0;T(o,function(c){u=Math.max(c.offset+c.width,u)}),s=Math.abs(s),u=Math.abs(u);var l=s+u,f=t-r,h=1-(s+u)/a,v=f/h-f;return t+=v*(u/l),r-=v*(s/l),{min:r,max:t}}function fd(r,t){var e=t,i=a_(r,e),n=i.extent,a=e.get("splitNumber");r instanceof ov&&(r.base=e.get("logBase"));var o=r.type,s=e.get("interval"),u=o==="interval"||o==="time";r.setExtent(n[0],n[1]),r.calcNiceExtent({splitNumber:a,fixMin:i.fixMin,fixMax:i.fixMax,minInterval:u?e.get("minInterval"):null,maxInterval:u?e.get("maxInterval"):null}),s!=null&&r.setInterval&&r.setInterval(s)}function PD(r,t){if(t=t||r.get("type"),t)switch(t){case"category":return new av({ordinalMeta:r.getOrdinalMeta?r.getOrdinalMeta():r.getCategories(),extent:[1/0,-1/0]});case"time":return new r_({locale:r.ecModel.getLocaleModel(),useUTC:r.ecModel.get("useUTC")});default:return new(We.getClass(t)||bn)}}function ID(r){var t=r.scale.getExtent(),e=t[0],i=t[1];return!(e>0&&i>0||e<0&&i<0)}function xn(r){var t=r.getLabelModel().get("formatter"),e=r.type==="category"?r.scale.getExtent()[0]:null;return r.scale.type==="time"?(function(i){return function(n,a){return r.scale.getFormattedLabel(n,a,i)}})(t):H(t)?(function(i){return function(n){var a=r.scale.getLabel(n),o=i.replace("{value}",a??"");return o}})(t):q(t)?(function(i){return function(n,a){return e!=null&&(a=n.value-e),i(sv(r,n),a,n.level!=null?{level:n.level}:null)}})(t):function(i){return r.scale.getLabel(i)}}function sv(r,t){return r.type==="category"?r.scale.getLabel(t):t.value}function RD(r){var t=r.model,e=r.scale;if(!(!t.get(["axisLabel","show"])||e.isBlank())){var i,n,a=e.getExtent();e instanceof av?n=e.count():(i=e.getTicks(),n=i.length);var o=r.getLabelModel(),s=xn(r),u,l=1;n>40&&(l=Math.ceil(n/40));for(var f=0;f<n;f+=l){var h=i?i[f]:{value:a[0]+f},v=s(h,f),c=o.getTextRect(v),p=ED(c,o.get("rotate")||0);u?u.union(p):u=p}return u}}function ED(r,t){var e=t*Math.PI/180,i=r.width,n=r.height,a=i*Math.abs(Math.cos(e))+Math.abs(n*Math.sin(e)),o=i*Math.abs(Math.sin(e))+Math.abs(n*Math.cos(e)),s=new et(r.x,r.y,a,o);return s}function uv(r){var t=r.get("interval");return t??"auto"}function o_(r){return r.type==="category"&&uv(r.getLabelModel())===0}function s_(r,t){var e={};return T(r.mapDimensionsAll(t),function(i){e[Q0(r,i)]=!0}),ft(e)}function kD(r,t,e){t&&T(s_(t,e),function(i){var n=t.getApproximateExtent(i);n[0]<r[0]&&(r[0]=n[0]),n[1]>r[1]&&(r[1]=n[1])})}var OD=(function(){function r(){}return r.prototype.getNeedCrossZero=function(){var t=this.option;return!t.scale},r.prototype.getCoordSysModel=function(){},r})(),hd=[],BD={registerPreprocessor:W0,registerProcessor:U0,registerPostInit:DC,registerPostUpdate:AC,registerUpdateLifecycle:ev,registerAction:Ci,registerCoordinateSystem:LC,registerLayout:PC,registerVisual:Di,registerTransform:RC,registerLoading:Y0,registerMap:IC,registerImpl:sC,PRIORITY:SC,ComponentModel:nt,ComponentView:$t,SeriesModel:He,ChartView:ce,registerComponentModel:function(r){nt.registerClass(r)},registerComponentView:function(r){$t.registerClass(r)},registerSeriesModel:function(r){He.registerClass(r)},registerChartView:function(r){ce.registerClass(r)},registerSubTypeDefaulter:function(r,t){nt.registerSubTypeDefaulter(r,t)},registerPainter:function(r,t){KS(r,t)}};function Pr(r){if(B(r)){T(r,function(t){Pr(t)});return}Q(hd,r)>=0||(hd.push(r),q(r)&&(r={install:r}),r.install(BD))}var ND=1e-8;function vd(r,t){return Math.abs(r-t)<ND}function Gn(r,t,e){var i=0,n=r[0];if(!n)return!1;for(var a=1;a<r.length;a++){var o=r[a];i+=$e(n[0],n[1],o[0],o[1],t,e),n=o}var s=r[0];return(!vd(n[0],s[0])||!vd(n[1],s[1]))&&(i+=$e(n[0],n[1],s[0],s[1],t,e)),i!==0}var Ra=vt();function u_(r,t){var e=z(t,function(i){return r.scale.parse(i)});return r.type==="time"&&e.length>0&&(e.sort(),e.unshift(e[0]),e.push(e[e.length-1])),e}function FD(r){var t=r.getLabelModel().get("customValues");if(t){var e=xn(r),i=r.scale.getExtent(),n=u_(r,t),a=_t(n,function(o){return o>=i[0]&&o<=i[1]});return{labels:z(a,function(o){var s={value:o};return{formattedLabel:e(s),rawLabel:r.scale.getLabel(s),tickValue:o}})}}return r.type==="category"?VD(r):GD(r)}function zD(r,t){var e=r.getTickModel().get("customValues");if(e){var i=r.scale.getExtent(),n=u_(r,e);return{ticks:_t(n,function(a){return a>=i[0]&&a<=i[1]})}}return r.type==="category"?HD(r,t):{ticks:z(r.scale.getTicks(),function(a){return a.value})}}function VD(r){var t=r.getLabelModel(),e=l_(r,t);return!t.get("show")||r.scale.isBlank()?{labels:[],labelCategoryInterval:e.labelCategoryInterval}:e}function l_(r,t){var e=f_(r,"labels"),i=uv(t),n=h_(e,i);if(n)return n;var a,o;return q(i)?a=p_(r,i):(o=i==="auto"?WD(r):i,a=c_(r,o)),v_(e,i,{labels:a,labelCategoryInterval:o})}function HD(r,t){var e=f_(r,"ticks"),i=uv(t),n=h_(e,i);if(n)return n;var a,o;if((!t.get("show")||r.scale.isBlank())&&(a=[]),q(i))a=p_(r,i,!0);else if(i==="auto"){var s=l_(r,r.getLabelModel());o=s.labelCategoryInterval,a=z(s.labels,function(u){return u.tickValue})}else o=i,a=c_(r,o,!0);return v_(e,i,{ticks:a,tickCategoryInterval:o})}function GD(r){var t=r.scale.getTicks(),e=xn(r);return{labels:z(t,function(i,n){return{level:i.level,formattedLabel:e(i,n),rawLabel:r.scale.getLabel(i),tickValue:i.value}})}}function f_(r,t){return Ra(r)[t]||(Ra(r)[t]=[])}function h_(r,t){for(var e=0;e<r.length;e++)if(r[e].key===t)return r[e].value}function v_(r,t,e){return r.push({key:t,value:e}),e}function WD(r){var t=Ra(r).autoInterval;return t??(Ra(r).autoInterval=r.calculateCategoryInterval())}function UD(r){var t=YD(r),e=xn(r),i=(t.axisRotate-t.labelRotate)/180*Math.PI,n=r.scale,a=n.getExtent(),o=n.count();if(a[1]-a[0]<1)return 0;var s=1;o>40&&(s=Math.max(1,Math.floor(o/40)));for(var u=a[0],l=r.dataToCoord(u+1)-r.dataToCoord(u),f=Math.abs(l*Math.cos(i)),h=Math.abs(l*Math.sin(i)),v=0,c=0;u<=a[1];u+=s){var p=0,d=0,g=Sh(e({value:u}),t.font,"center","top");p=g.width*1.3,d=g.height*1.3,v=Math.max(v,p,7),c=Math.max(c,d,7)}var y=v/f,m=c/h;isNaN(y)&&(y=1/0),isNaN(m)&&(m=1/0);var _=Math.max(0,Math.floor(Math.min(y,m))),S=Ra(r.model),b=r.getExtent(),w=S.lastAutoInterval,x=S.lastTickCount;return w!=null&&x!=null&&Math.abs(w-_)<=1&&Math.abs(x-o)<=1&&w>_&&S.axisExtent0===b[0]&&S.axisExtent1===b[1]?_=w:(S.lastTickCount=o,S.lastAutoInterval=_,S.axisExtent0=b[0],S.axisExtent1=b[1]),_}function YD(r){var t=r.getLabelModel();return{axisRotate:r.getRotate?r.getRotate():r.isHorizontal&&!r.isHorizontal()?90:0,labelRotate:t.get("rotate")||0,font:t.getFont()}}function c_(r,t,e){var i=xn(r),n=r.scale,a=n.getExtent(),o=r.getLabelModel(),s=[],u=Math.max((t||0)+1,1),l=a[0],f=n.count();l!==0&&u>1&&f/u>2&&(l=Math.round(Math.ceil(l/u)*u));var h=o_(r),v=o.get("showMinLabel")||h,c=o.get("showMaxLabel")||h;v&&l!==a[0]&&d(a[0]);for(var p=l;p<=a[1];p+=u)d(p);c&&p-u!==a[1]&&d(a[1]);function d(g){var y={value:g};s.push(e?g:{formattedLabel:i(y),rawLabel:n.getLabel(y),tickValue:g})}return s}function p_(r,t,e){var i=r.scale,n=xn(r),a=[];return T(i.getTicks(),function(o){var s=i.getLabel(o),u=o.value;t(o.value,s)&&a.push(e?u:{formattedLabel:n(o),rawLabel:s,tickValue:u})}),a}var cd=[0,1],ZD=(function(){function r(t,e,i){this.onBand=!1,this.inverse=!1,this.dim=t,this.scale=e,this._extent=i||[0,0]}return r.prototype.contain=function(t){var e=this._extent,i=Math.min(e[0],e[1]),n=Math.max(e[0],e[1]);return t>=i&&t<=n},r.prototype.containData=function(t){return this.scale.contain(t)},r.prototype.getExtent=function(){return this._extent.slice()},r.prototype.getPixelPrecision=function(t){return Ly(t||this.scale.getExtent(),this._extent)},r.prototype.setExtent=function(t,e){var i=this._extent;i[0]=t,i[1]=e},r.prototype.dataToCoord=function(t,e){var i=this._extent,n=this.scale;return t=n.normalize(t),this.onBand&&n.type==="ordinal"&&(i=i.slice(),pd(i,n.count())),bt(t,cd,i,e)},r.prototype.coordToData=function(t,e){var i=this._extent,n=this.scale;this.onBand&&n.type==="ordinal"&&(i=i.slice(),pd(i,n.count()));var a=bt(t,i,cd,e);return this.scale.scale(a)},r.prototype.pointToData=function(t,e){},r.prototype.getTicksCoords=function(t){t=t||{};var e=t.tickModel||this.getTickModel(),i=zD(this,e),n=i.ticks,a=z(n,function(s){return{coord:this.dataToCoord(this.scale.type==="ordinal"?this.scale.getRawOrdinalNumber(s):s),tickValue:s}},this),o=e.get("alignWithLabel");return XD(this,a,o,t.clamp),a},r.prototype.getMinorTicksCoords=function(){if(this.scale.type==="ordinal")return[];var t=this.model.getModel("minorTick"),e=t.get("splitNumber");e>0&&e<100||(e=5);var i=this.scale.getMinorTicks(e),n=z(i,function(a){return z(a,function(o){return{coord:this.dataToCoord(o),tickValue:o}},this)},this);return n},r.prototype.getViewLabels=function(){return FD(this).labels},r.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},r.prototype.getTickModel=function(){return this.model.getModel("axisTick")},r.prototype.getBandWidth=function(){var t=this._extent,e=this.scale.getExtent(),i=e[1]-e[0]+(this.onBand?1:0);i===0&&(i=1);var n=Math.abs(t[1]-t[0]);return Math.abs(n)/i},r.prototype.calculateCategoryInterval=function(){return UD(this)},r})();function pd(r,t){var e=r[1]-r[0],i=t,n=e/i/2;r[0]+=n,r[1]-=n}function XD(r,t,e,i){var n=t.length;if(!r.onBand||e||!n)return;var a=r.getExtent(),o,s;if(n===1)t[0].coord=a[0],o=t[1]={coord:a[1],tickValue:t[0].tickValue};else{var u=t[n-1].tickValue-t[0].tickValue,l=(t[n-1].coord-t[0].coord)/u;T(t,function(c){c.coord-=l/2});var f=r.scale.getExtent();s=1+f[1]-t[n-1].tickValue,o={coord:t[n-1].coord+l*s,tickValue:f[1]+1},t.push(o)}var h=a[0]>a[1];v(t[0].coord,a[0])&&(i?t[0].coord=a[0]:t.shift()),i&&v(a[0],t[0].coord)&&t.unshift({coord:a[0]}),v(a[1],o.coord)&&(i?o.coord=a[1]:t.pop()),i&&v(o.coord,a[1])&&t.push({coord:a[1]});function v(c,p){return c=xt(c),p=xt(p),h?c>p:c<p}}function $D(r){var t=nt.extend(r);return nt.registerClass(t),t}function qD(r){var t=$t.extend(r);return $t.registerClass(t),t}var Wn=Math.PI*2,ei=Ar.CMD,KD=["top","right","bottom","left"];function QD(r,t,e,i,n){var a=e.width,o=e.height;switch(r){case"top":i.set(e.x+a/2,e.y-t),n.set(0,-1);break;case"bottom":i.set(e.x+a/2,e.y+o+t),n.set(0,1);break;case"left":i.set(e.x-t,e.y+o/2),n.set(-1,0);break;case"right":i.set(e.x+a+t,e.y+o/2),n.set(1,0);break}}function JD(r,t,e,i,n,a,o,s,u){o-=r,s-=t;var l=Math.sqrt(o*o+s*s);o/=l,s/=l;var f=o*e+r,h=s*e+t;if(Math.abs(i-n)%Wn<1e-4)return u[0]=f,u[1]=h,l-e;if(a){var v=i;i=qe(n),n=qe(v)}else i=qe(i),n=qe(n);i>n&&(n+=Wn);var c=Math.atan2(s,o);if(c<0&&(c+=Wn),c>=i&&c<=n||c+Wn>=i&&c+Wn<=n)return u[0]=f,u[1]=h,l-e;var p=e*Math.cos(i)+r,d=e*Math.sin(i)+t,g=e*Math.cos(n)+r,y=e*Math.sin(n)+t,m=(p-o)*(p-o)+(d-s)*(d-s),_=(g-o)*(g-o)+(y-s)*(y-s);return m<_?(u[0]=p,u[1]=d,Math.sqrt(m)):(u[0]=g,u[1]=y,Math.sqrt(_))}function Wf(r,t,e,i,n,a,o,s){var u=n-r,l=a-t,f=e-r,h=i-t,v=Math.sqrt(f*f+h*h);f/=v,h/=v;var c=u*f+l*h,p=c/v;s&&(p=Math.min(Math.max(p,0),1)),p*=v;var d=o[0]=r+p*f,g=o[1]=t+p*h;return Math.sqrt((d-n)*(d-n)+(g-a)*(g-a))}function d_(r,t,e,i,n,a,o){e<0&&(r=r+e,e=-e),i<0&&(t=t+i,i=-i);var s=r+e,u=t+i,l=o[0]=Math.min(Math.max(n,r),s),f=o[1]=Math.min(Math.max(a,t),u);return Math.sqrt((l-n)*(l-n)+(f-a)*(f-a))}var xe=[];function jD(r,t,e){var i=d_(t.x,t.y,t.width,t.height,r.x,r.y,xe);return e.set(xe[0],xe[1]),i}function tA(r,t,e){for(var i=0,n=0,a=0,o=0,s,u,l=1/0,f=t.data,h=r.x,v=r.y,c=0;c<f.length;){var p=f[c++];c===1&&(i=f[c],n=f[c+1],a=i,o=n);var d=l;switch(p){case ei.M:a=f[c++],o=f[c++],i=a,n=o;break;case ei.L:d=Wf(i,n,f[c],f[c+1],h,v,xe,!0),i=f[c++],n=f[c++];break;case ei.C:d=gy(i,n,f[c++],f[c++],f[c++],f[c++],f[c],f[c+1],h,v,xe),i=f[c++],n=f[c++];break;case ei.Q:d=my(i,n,f[c++],f[c++],f[c],f[c+1],h,v,xe),i=f[c++],n=f[c++];break;case ei.A:var g=f[c++],y=f[c++],m=f[c++],_=f[c++],S=f[c++],b=f[c++];c+=1;var w=!!(1-f[c++]);s=Math.cos(S)*m+g,u=Math.sin(S)*_+y,c<=1&&(a=s,o=u);var x=(h-g)*_/m+g;d=JD(g,y,_,S,S+b,w,x,v,xe),i=Math.cos(S+b)*m+g,n=Math.sin(S+b)*_+y;break;case ei.R:a=i=f[c++],o=n=f[c++];var C=f[c++],M=f[c++];d=d_(a,o,C,M,h,v,xe);break;case ei.Z:d=Wf(i,n,a,o,h,v,xe,!0),i=a,n=o;break}d<l&&(l=d,e.set(xe[0],xe[1]))}return l}var fi=new j,Dt=new j,Qt=new j,Ji=new j,Un=new j;function dd(r,t){if(r){var e=r.getTextGuideLine(),i=r.getTextContent();if(i&&e){var n=r.textGuideLineConfig||{},a=[[0,0],[0,0],[0,0]],o=n.candidates||KD,s=i.getBoundingRect().clone();s.applyTransform(i.getComputedTransform());var u=1/0,l=n.anchor,f=r.getComputedTransform(),h=f&&Ls([],f),v=t.get("length2")||0;l&&Qt.copy(l);for(var c=0;c<o.length;c++){var p=o[c];QD(p,0,s,fi,Ji),j.scaleAndAdd(Dt,fi,Ji,v),Dt.transform(h);var d=r.getBoundingRect(),g=l?l.distance(Dt):r instanceof st?tA(Dt,r.path,Qt):jD(Dt,d,Qt);g<u&&(u=g,Dt.transform(f),Qt.transform(f),Qt.toArray(a[0]),Dt.toArray(a[1]),fi.toArray(a[2]))}eA(a,t.get("minTurnAngle")),e.setShape({points:a})}}}var gd=[],ri=new j;function eA(r,t){if(t<=180&&t>0){t=t/180*Math.PI,fi.fromArray(r[0]),Dt.fromArray(r[1]),Qt.fromArray(r[2]),j.sub(Ji,fi,Dt),j.sub(Un,Qt,Dt);var e=Ji.len(),i=Un.len();if(!(e<.001||i<.001)){Ji.scale(1/e),Un.scale(1/i);var n=Ji.dot(Un),a=Math.cos(t);if(a<n){var o=Wf(Dt.x,Dt.y,Qt.x,Qt.y,fi.x,fi.y,gd,!1);ri.fromArray(gd),ri.scaleAndAdd(Un,o/Math.tan(Math.PI-t));var s=Qt.x!==Dt.x?(ri.x-Dt.x)/(Qt.x-Dt.x):(ri.y-Dt.y)/(Qt.y-Dt.y);if(isNaN(s))return;s<0?j.copy(ri,Dt):s>1&&j.copy(ri,Qt),ri.toArray(r[1])}}}}function ml(r,t,e,i){var n=e==="normal",a=n?r:r.ensureState(e);a.ignore=t;var o=i.get("smooth");o&&o===!0&&(o=.3),a.shape=a.shape||{},o>0&&(a.shape.smooth=o);var s=i.getModel("lineStyle").getLineStyle();n?r.useStyle(s):a.style=s}function rA(r,t){var e=t.smooth,i=t.points;if(i)if(r.moveTo(i[0][0],i[0][1]),e>0&&i.length>=3){var n=Jl(i[0],i[1]),a=Jl(i[1],i[2]);if(!n||!a){r.lineTo(i[1][0],i[1][1]),r.lineTo(i[2][0],i[2][1]);return}var o=Math.min(n,a)*e,s=hu([],i[1],i[0],o/n),u=hu([],i[1],i[2],o/a),l=hu([],s,u,.5);r.bezierCurveTo(s[0],s[1],s[0],s[1],l[0],l[1]),r.bezierCurveTo(u[0],u[1],u[0],u[1],i[2][0],i[2][1])}else for(var f=1;f<i.length;f++)r.lineTo(i[f][0],i[f][1])}function iA(r,t,e){var i=r.getTextGuideLine(),n=r.getTextContent();if(!n){i&&r.removeTextGuideLine();return}for(var a=t.normal,o=a.get("show"),s=n.ignore,u=0;u<rs.length;u++){var l=rs[u],f=t[l],h=l==="normal";if(f){var v=f.get("show"),c=h?s:$(n.states[l]&&n.states[l].ignore,s);if(c||!$(v,o)){var p=h?i:i&&i.states[l];p&&(p.ignore=!0),i&&ml(i,!0,l,f);continue}i||(i=new _n,r.setTextGuideLine(i),!h&&(s||!o)&&ml(i,!0,"normal",t.normal),r.stateProxy&&(i.stateProxy=r.stateProxy)),ml(i,!1,l,f)}}if(i){rt(i.style,e),i.style.fill=null;var d=a.get("showAbove"),g=r.textGuideLineConfig=r.textGuideLineConfig||{};g.showAbove=d||!1,i.buildPath=rA}}function nA(r,t){t=t||"labelLine";for(var e={normal:r.getModel(t)},i=0;i<Zt.length;i++){var n=Zt[i];e[n]=r.getModel([n,t])}return e}function g_(r){for(var t=[],e=0;e<r.length;e++){var i=r[e];if(!i.defaultAttr.ignore){var n=i.label,a=n.getComputedTransform(),o=n.getBoundingRect(),s=!a||a[1]<1e-5&&a[2]<1e-5,u=n.style.margin||0,l=o.clone();l.applyTransform(a),l.x-=u/2,l.y-=u/2,l.width+=u,l.height+=u;var f=s?new is(o,a):null;t.push({label:n,labelLine:i.labelLine,rect:l,localRect:o,obb:f,priority:i.priority,defaultAttr:i.defaultAttr,layoutOption:i.computedLayoutOption,axisAligned:s,transform:a})}}return t}function y_(r,t,e,i,n,a){var o=r.length;if(o<2)return;r.sort(function(w,x){return w.rect[t]-x.rect[t]});for(var s=0,u,l=!1,f=0;f<o;f++){var h=r[f],v=h.rect;u=v[t]-s,u<0&&(v[t]-=u,h.label[t]-=u,l=!0),s=v[t]+v[e]}var c=r[0],p=r[o-1],d,g;y(),d<0&&S(-d,.8),g<0&&S(g,.8),y(),m(d,g,1),m(g,d,-1),y(),d<0&&b(-d),g<0&&b(g);function y(){d=c.rect[t]-i,g=n-p.rect[t]-p.rect[e]}function m(w,x,C){if(w<0){var M=Math.min(x,-w);if(M>0){_(M*C,0,o);var D=M+w;D<0&&S(-D*C,1)}else S(-w*C,1)}}function _(w,x,C){w!==0&&(l=!0);for(var M=x;M<C;M++){var D=r[M],A=D.rect;A[t]+=w,D.label[t]+=w}}function S(w,x){for(var C=[],M=0,D=1;D<o;D++){var A=r[D-1].rect,P=Math.max(r[D].rect[t]-A[t]-A[e],0);C.push(P),M+=P}if(M){var R=Math.min(Math.abs(w)/M,x);if(w>0)for(var D=0;D<o-1;D++){var L=C[D]*R;_(L,0,D+1)}else for(var D=o-1;D>0;D--){var L=C[D-1]*R;_(-L,D,o)}}}function b(w){var x=w<0?-1:1;w=Math.abs(w);for(var C=Math.ceil(w/(o-1)),M=0;M<o-1;M++)if(x>0?_(C,0,M+1):_(-C,o-M-1,o),w-=C,w<=0)return}return l}function aA(r,t,e,i){return y_(r,"x","width",t,e)}function oA(r,t,e,i){return y_(r,"y","height",t,e)}function m_(r){var t=[];r.sort(function(d,g){return g.priority-d.priority});var e=new et(0,0,0,0);function i(d){if(!d.ignore){var g=d.ensureState("emphasis");g.ignore==null&&(g.ignore=!1)}d.ignore=!0}for(var n=0;n<r.length;n++){var a=r[n],o=a.axisAligned,s=a.localRect,u=a.transform,l=a.label,f=a.labelLine;e.copy(a.rect),e.width-=.1,e.height-=.1,e.x+=.05,e.y+=.05;for(var h=a.obb,v=!1,c=0;c<t.length;c++){var p=t[c];if(e.intersect(p.rect)){if(o&&p.axisAligned){v=!0;break}if(p.obb||(p.obb=new is(p.localRect,p.transform)),h||(h=new is(s,u)),h.intersect(p.obb)){v=!0;break}}}v?(i(l),f&&i(f)):(l.attr("ignore",a.defaultAttr.ignore),f&&f.attr("ignore",a.defaultAttr.labelGuideIgnore),t.push(a))}}function sA(r){if(r){for(var t=[],e=0;e<r.length;e++)t.push(r[e].slice());return t}}function uA(r,t){var e=r.label,i=t&&t.getTextGuideLine();return{dataIndex:r.dataIndex,dataType:r.dataType,seriesIndex:r.seriesModel.seriesIndex,text:r.label.style.text,rect:r.hostRect,labelRect:r.rect,align:e.style.align,verticalAlign:e.style.verticalAlign,labelLinePoints:sA(i&&i.shape.points)}}var yd=["align","verticalAlign","width","height","fontSize"],Bt=new Ps,_l=vt(),lA=vt();function bo(r,t,e){for(var i=0;i<e.length;i++){var n=e[i];t[n]!=null&&(r[n]=t[n])}}var xo=["x","y","rotation"],fA=(function(){function r(){this._labelList=[],this._chartViewList=[]}return r.prototype.clearLabels=function(){this._labelList=[],this._chartViewList=[]},r.prototype._addLabel=function(t,e,i,n,a){var o=n.style,s=n.__hostTarget,u=s.textConfig||{},l=n.getComputedTransform(),f=n.getBoundingRect().plain();et.applyTransform(f,f,l),l?Bt.setLocalTransform(l):(Bt.x=Bt.y=Bt.rotation=Bt.originX=Bt.originY=0,Bt.scaleX=Bt.scaleY=1),Bt.rotation=qe(Bt.rotation);var h=n.__hostTarget,v;if(h){v=h.getBoundingRect().plain();var c=h.getComputedTransform();et.applyTransform(v,v,c)}var p=v&&h.getTextGuideLine();this._labelList.push({label:n,labelLine:p,seriesModel:i,dataIndex:t,dataType:e,layoutOption:a,computedLayoutOption:null,rect:f,hostRect:v,priority:v?v.width*v.height:0,defaultAttr:{ignore:n.ignore,labelGuideIgnore:p&&p.ignore,x:Bt.x,y:Bt.y,scaleX:Bt.scaleX,scaleY:Bt.scaleY,rotation:Bt.rotation,style:{x:o.x,y:o.y,align:o.align,verticalAlign:o.verticalAlign,width:o.width,height:o.height,fontSize:o.fontSize},cursor:n.cursor,attachedPos:u.position,attachedRot:u.rotation}})},r.prototype.addLabelsOfSeries=function(t){var e=this;this._chartViewList.push(t);var i=t.__model,n=i.get("labelLayout");(q(n)||ft(n).length)&&t.group.traverse(function(a){if(a.ignore)return!0;var o=a.getTextContent(),s=at(a);o&&!o.disableLabelLayout&&e._addLabel(s.dataIndex,s.dataType,i,o,n)})},r.prototype.updateLayoutConfig=function(t){var e=t.getWidth(),i=t.getHeight();function n(_,S){return function(){dd(_,S)}}for(var a=0;a<this._labelList.length;a++){var o=this._labelList[a],s=o.label,u=s.__hostTarget,l=o.defaultAttr,f=void 0;q(o.layoutOption)?f=o.layoutOption(uA(o,u)):f=o.layoutOption,f=f||{},o.computedLayoutOption=f;var h=Math.PI/180;u&&u.setTextConfig({local:!1,position:f.x!=null||f.y!=null?null:l.attachedPos,rotation:f.rotate!=null?f.rotate*h:l.attachedRot,offset:[f.dx||0,f.dy||0]});var v=!1;if(f.x!=null?(s.x=yt(f.x,e),s.setStyle("x",0),v=!0):(s.x=l.x,s.setStyle("x",l.style.x)),f.y!=null?(s.y=yt(f.y,i),s.setStyle("y",0),v=!0):(s.y=l.y,s.setStyle("y",l.style.y)),f.labelLinePoints){var c=u.getTextGuideLine();c&&(c.setShape({points:f.labelLinePoints}),v=!1)}var p=_l(s);p.needsUpdateLabelLine=v,s.rotation=f.rotate!=null?f.rotate*h:l.rotation,s.scaleX=l.scaleX,s.scaleY=l.scaleY;for(var d=0;d<yd.length;d++){var g=yd[d];s.setStyle(g,f[g]!=null?f[g]:l.style[g])}if(f.draggable){if(s.draggable=!0,s.cursor="move",u){var y=o.seriesModel;if(o.dataIndex!=null){var m=o.seriesModel.getData(o.dataType);y=m.getItemModel(o.dataIndex)}s.on("drag",n(u,y.getModel("labelLine")))}}else s.off("drag"),s.cursor=l.cursor}},r.prototype.layout=function(t){var e=t.getWidth(),i=t.getHeight(),n=g_(this._labelList),a=_t(n,function(u){return u.layoutOption.moveOverlap==="shiftX"}),o=_t(n,function(u){return u.layoutOption.moveOverlap==="shiftY"});aA(a,0,e),oA(o,0,i);var s=_t(n,function(u){return u.layoutOption.hideOverlap});m_(s)},r.prototype.processLabelsOverall=function(){var t=this;T(this._chartViewList,function(e){var i=e.__model,n=e.ignoreLabelLineUpdate,a=i.isAnimationEnabled();e.group.traverse(function(o){if(o.ignore&&!o.forceLabelAnimation)return!0;var s=!n,u=o.getTextContent();!s&&u&&(s=_l(u).needsUpdateLabelLine),s&&t._updateLabelLine(o,i),a&&t._animateLabels(o,i)})})},r.prototype._updateLabelLine=function(t,e){var i=t.getTextContent(),n=at(t),a=n.dataIndex;if(i&&a!=null){var o=e.getData(n.dataType),s=o.getItemModel(a),u={},l=o.getItemVisual(a,"style");if(l){var f=o.getVisual("drawType");u.stroke=l[f]}var h=s.getModel("labelLine");iA(t,nA(s),u),dd(t,h)}},r.prototype._animateLabels=function(t,e){var i=t.getTextContent(),n=t.getTextGuideLine();if(i&&(t.forceLabelAnimation||!i.ignore&&!i.invisible&&!t.disableLabelAnimation&&!nn(t))){var a=_l(i),o=a.oldLayout,s=at(t),u=s.dataIndex,l={x:i.x,y:i.y,rotation:i.rotation},f=e.getData(s.dataType);if(o){i.attr(o);var v=t.prevStates;v&&(Q(v,"select")>=0&&i.attr(a.oldLayoutSelect),Q(v,"emphasis")>=0&&i.attr(a.oldLayoutEmphasis)),pe(i,l,e,u)}else if(i.attr(l),!Zs(i).valueAnimation){var h=$(i.style.opacity,1);i.style.opacity=0,rr(i,{style:{opacity:h}},e,u)}if(a.oldLayout=l,i.states.select){var c=a.oldLayoutSelect={};bo(c,l,xo),bo(c,i.states.select,xo)}if(i.states.emphasis){var p=a.oldLayoutEmphasis={};bo(p,l,xo),bo(p,i.states.emphasis,xo)}Mx(i,u,f,e,e)}if(n&&!n.ignore&&!n.invisible){var a=lA(n),o=a.oldLayout,d={points:n.shape.points};o?(n.attr({shape:o}),pe(n,{shape:d},e)):(n.setShape(d),n.style.strokePercent=0,rr(n,{style:{strokePercent:1}},e)),a.oldLayout=d}},r})(),Sl=vt();function hA(r){r.registerUpdateLifecycle("series:beforeupdate",function(t,e,i){var n=Sl(e).labelManager;n||(n=Sl(e).labelManager=new fA),n.clearLabels()}),r.registerUpdateLifecycle("series:layoutlabels",function(t,e,i){var n=Sl(e).labelManager;i.updatedSeries.forEach(function(a){n.addLabelsOfSeries(e.getViewOfSeriesModel(a))}),n.updateLayoutConfig(e),n.layout(e),n.processLabelsOverall()})}var vA=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e}return t.prototype.getInitialData=function(e){return nv(null,this,{useEncodeDefaulter:!0})},t.prototype.getLegendIcon=function(e){var i=new gt,n=ir("line",0,e.itemHeight/2,e.itemWidth,0,e.lineStyle.stroke,!1);i.add(n),n.setStyle(e.lineStyle);var a=this.getData().getVisual("symbol"),o=this.getData().getVisual("symbolRotate"),s=a==="none"?"circle":a,u=e.itemHeight*.8,l=ir(s,(e.itemWidth-u)/2,(e.itemHeight-u)/2,u,u,e.itemStyle.fill);i.add(l),l.setStyle(e.itemStyle);var f=e.iconRotate==="inherit"?o:e.iconRotate||0;return l.rotation=f*Math.PI/180,l.setOrigin([e.itemWidth/2,e.itemHeight/2]),s.indexOf("empty")>-1&&(l.style.stroke=l.style.fill,l.style.fill="#fff",l.style.lineWidth=2),i},t.type="series.line",t.dependencies=["grid","polar"],t.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1},t})(He);function ys(r,t){var e=r.mapDimensionsAll("defaultedLabel"),i=e.length;if(i===1){var n=cn(r,t,e[0]);return n!=null?n+"":null}else if(i){for(var a=[],o=0;o<e.length;o++)a.push(cn(r,t,e[o]));return a.join(" ")}}function cA(r,t){var e=r.mapDimensionsAll("defaultedLabel");if(!B(t))return t+"";for(var i=[],n=0;n<e.length;n++){var a=r.getDimensionIndex(e[n]);a>=0&&i.push(t[a])}return i.join(" ")}var lv=(function(r){O(t,r);function t(e,i,n,a){var o=r.call(this)||this;return o.updateData(e,i,n,a),o}return t.prototype._createSymbol=function(e,i,n,a,o){this.removeAll();var s=ir(e,-1,-1,2,2,null,o);s.attr({z2:100,culling:!0,scaleX:a[0]/2,scaleY:a[1]/2}),s.drift=pA,this._symbolType=e,this.add(s)},t.prototype.stopSymbolAnimation=function(e){this.childAt(0).stopAnimation(null,e)},t.prototype.getSymbolType=function(){return this._symbolType},t.prototype.getSymbolPath=function(){return this.childAt(0)},t.prototype.highlight=function(){ba(this.childAt(0))},t.prototype.downplay=function(){xa(this.childAt(0))},t.prototype.setZ=function(e,i){var n=this.childAt(0);n.zlevel=e,n.z=i},t.prototype.setDraggable=function(e,i){var n=this.childAt(0);n.draggable=e,n.cursor=!i&&e?"move":n.cursor},t.prototype.updateData=function(e,i,n,a){this.silent=!1;var o=e.getItemVisual(i,"symbol")||"circle",s=e.hostModel,u=t.getSymbolSize(e,i),l=o!==this._symbolType,f=a&&a.disableAnimation;if(l){var h=e.getItemVisual(i,"symbolKeepAspect");this._createSymbol(o,e,i,u,h)}else{var v=this.childAt(0);v.silent=!1;var c={scaleX:u[0]/2,scaleY:u[1]/2};f?v.attr(c):pe(v,c,s,i),hx(v)}if(this._updateCommon(e,i,u,n,a),l){var v=this.childAt(0);if(!f){var c={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:v.style.opacity}};v.scaleX=v.scaleY=0,v.style.opacity=0,rr(v,c,s,i)}}f&&this.childAt(0).stopAnimation("leave")},t.prototype._updateCommon=function(e,i,n,a,o){var s=this.childAt(0),u=e.hostModel,l,f,h,v,c,p,d,g,y;if(a&&(l=a.emphasisItemStyle,f=a.blurItemStyle,h=a.selectItemStyle,v=a.focus,c=a.blurScope,d=a.labelStatesModels,g=a.hoverScale,y=a.cursorStyle,p=a.emphasisDisabled),!a||e.hasItemOption){var m=a&&a.itemModel?a.itemModel:e.getItemModel(i),_=m.getModel("emphasis");l=_.getModel("itemStyle").getItemStyle(),h=m.getModel(["select","itemStyle"]).getItemStyle(),f=m.getModel(["blur","itemStyle"]).getItemStyle(),v=_.get("focus"),c=_.get("blurScope"),p=_.get("disabled"),d=Sn(m),g=_.getShallow("scale"),y=m.getShallow("cursor")}var S=e.getItemVisual(i,"symbolRotate");s.attr("rotation",(S||0)*Math.PI/180||0);var b=ru(e.getItemVisual(i,"symbolOffset"),n);b&&(s.x=b[0],s.y=b[1]),y&&s.attr("cursor",y);var w=e.getItemVisual(i,"style"),x=w.fill;if(s instanceof nr){var C=s.style;s.useStyle(k({image:C.image,x:C.x,y:C.y,width:C.width,height:C.height},w))}else s.__isEmptyBrush?s.useStyle(k({},w)):s.useStyle(w),s.style.decal=null,s.setColor(x,o&&o.symbolInnerColor),s.style.strokeNoScale=!0;var M=e.getItemVisual(i,"liftZ"),D=this._z2;M!=null?D==null&&(this._z2=s.z2,s.z2+=M):D!=null&&(s.z2=D,this._z2=null);var A=o&&o.useNameLabel;Ys(s,d,{labelFetcher:u,labelDataIndex:i,defaultText:P,inheritColor:x,defaultOpacity:w.opacity});function P(I){return A?e.getName(I):ys(e,I)}this._sizeX=n[0]/2,this._sizeY=n[1]/2;var R=s.ensureState("emphasis");R.style=l,s.ensureState("select").style=h,s.ensureState("blur").style=f;var L=g==null||g===!0?Math.max(1.1,3/this._sizeY):isFinite(g)&&g>0?+g:1;R.scaleX=this._sizeX*L,R.scaleY=this._sizeY*L,this.setSymbolScale(1),vn(this,v,c,p)},t.prototype.setSymbolScale=function(e){this.scaleX=this.scaleY=e},t.prototype.fadeOut=function(e,i,n){var a=this.childAt(0),o=at(this).dataIndex,s=n&&n.animation;if(this.silent=a.silent=!0,n&&n.fadeLabel){var u=a.getTextContent();u&&ns(u,{style:{opacity:0}},i,{dataIndex:o,removeOpt:s,cb:function(){a.removeTextContent()}})}else a.removeTextContent();ns(a,{style:{opacity:0},scaleX:0,scaleY:0},i,{dataIndex:o,cb:e,removeOpt:s})},t.getSymbolSize=function(e,i){return Qh(e.getItemVisual(i,"symbolSize"))},t})(gt);function pA(r,t){this.parent.drift(r,t)}function wl(r,t,e,i){return t&&!isNaN(t[0])&&!isNaN(t[1])&&!(i.isIgnore&&i.isIgnore(e))&&!(i.clipShape&&!i.clipShape.contain(t[0],t[1]))&&r.getItemVisual(e,"symbol")!=="none"}function md(r){return r!=null&&!W(r)&&(r={isIgnore:r}),r||{}}function _d(r){var t=r.hostModel,e=t.getModel("emphasis");return{emphasisItemStyle:e.getModel("itemStyle").getItemStyle(),blurItemStyle:t.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:t.getModel(["select","itemStyle"]).getItemStyle(),focus:e.get("focus"),blurScope:e.get("blurScope"),emphasisDisabled:e.get("disabled"),hoverScale:e.get("scale"),labelStatesModels:Sn(t),cursorStyle:t.get("cursor")}}var __=(function(){function r(t){this.group=new gt,this._SymbolCtor=t||lv}return r.prototype.updateData=function(t,e){this._progressiveEls=null,e=md(e);var i=this.group,n=t.hostModel,a=this._data,o=this._SymbolCtor,s=e.disableAnimation,u=_d(t),l={disableAnimation:s},f=e.getSymbolPoint||function(h){return t.getItemLayout(h)};a||i.removeAll(),t.diff(a).add(function(h){var v=f(h);if(wl(t,v,h,e)){var c=new o(t,h,u,l);c.setPosition(v),t.setItemGraphicEl(h,c),i.add(c)}}).update(function(h,v){var c=a.getItemGraphicEl(v),p=f(h);if(!wl(t,p,h,e)){i.remove(c);return}var d=t.getItemVisual(h,"symbol")||"circle",g=c&&c.getSymbolType&&c.getSymbolType();if(!c||g&&g!==d)i.remove(c),c=new o(t,h,u,l),c.setPosition(p);else{c.updateData(t,h,u,l);var y={x:p[0],y:p[1]};s?c.attr(y):pe(c,y,n)}i.add(c),t.setItemGraphicEl(h,c)}).remove(function(h){var v=a.getItemGraphicEl(h);v&&v.fadeOut(function(){i.remove(v)},n)}).execute(),this._getSymbolPoint=f,this._data=t},r.prototype.updateLayout=function(){var t=this,e=this._data;e&&e.eachItemGraphicEl(function(i,n){var a=t._getSymbolPoint(n);i.setPosition(a),i.markRedraw()})},r.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=_d(t),this._data=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(t,e,i){this._progressiveEls=[],i=md(i);function n(u){u.isGroup||(u.incremental=!0,u.ensureState("emphasis").hoverLayer=!0)}for(var a=t.start;a<t.end;a++){var o=e.getItemLayout(a);if(wl(e,o,a,i)){var s=new this._SymbolCtor(e,a,this._seriesScope);s.traverse(n),s.setPosition(o),this.group.add(s),e.setItemGraphicEl(a,s),this._progressiveEls.push(s)}}},r.prototype.eachRendered=function(t){Va(this._progressiveEls||this.group,t)},r.prototype.remove=function(t){var e=this.group,i=this._data;i&&t?i.eachItemGraphicEl(function(n){n.fadeOut(function(){e.remove(n)},i.hostModel)}):e.removeAll()},r})();function S_(r,t,e){var i=r.getBaseAxis(),n=r.getOtherAxis(i),a=dA(n,e),o=i.dim,s=n.dim,u=t.mapDimension(s),l=t.mapDimension(o),f=s==="x"||s==="radius"?1:0,h=z(r.dimensions,function(p){return t.mapDimension(p)}),v=!1,c=t.getCalculationInfo("stackResultDimension");return pn(t,h[0])&&(v=!0,h[0]=c),pn(t,h[1])&&(v=!0,h[1]=c),{dataDimsForPoint:h,valueStart:a,valueAxisDim:s,baseAxisDim:o,stacked:!!v,valueDim:u,baseDim:l,baseDataOffset:f,stackedOverDimension:t.getCalculationInfo("stackedOverDimension")}}function dA(r,t){var e=0,i=r.scale.getExtent();return t==="start"?e=i[0]:t==="end"?e=i[1]:dt(t)&&!isNaN(t)?e=t:i[0]>0?e=i[0]:i[1]<0&&(e=i[1]),e}function w_(r,t,e,i){var n=NaN;r.stacked&&(n=e.get(e.getCalculationInfo("stackedOverDimension"),i)),isNaN(n)&&(n=r.valueStart);var a=r.baseDataOffset,o=[];return o[a]=e.get(r.baseDim,i),o[1-a]=n,t.dataToPoint(o)}function gA(r,t){var e=[];return t.diff(r).add(function(i){e.push({cmd:"+",idx:i})}).update(function(i,n){e.push({cmd:"=",idx:n,idx1:i})}).remove(function(i){e.push({cmd:"-",idx:i})}).execute(),e}function yA(r,t,e,i,n,a,o,s){for(var u=gA(r,t),l=[],f=[],h=[],v=[],c=[],p=[],d=[],g=S_(n,t,o),y=r.getLayout("points")||[],m=t.getLayout("points")||[],_=0;_<u.length;_++){var S=u[_],b=!0,w=void 0,x=void 0;switch(S.cmd){case"=":w=S.idx*2,x=S.idx1*2;var C=y[w],M=y[w+1],D=m[x],A=m[x+1];(isNaN(C)||isNaN(M))&&(C=D,M=A),l.push(C,M),f.push(D,A),h.push(e[w],e[w+1]),v.push(i[x],i[x+1]),d.push(t.getRawIndex(S.idx1));break;case"+":var P=S.idx,R=g.dataDimsForPoint,L=n.dataToPoint([t.get(R[0],P),t.get(R[1],P)]);x=P*2,l.push(L[0],L[1]),f.push(m[x],m[x+1]);var I=w_(g,n,t,P);h.push(I[0],I[1]),v.push(i[x],i[x+1]),d.push(t.getRawIndex(P));break;case"-":b=!1}b&&(c.push(S),p.push(p.length))}p.sort(function(mt,ye){return d[mt]-d[ye]});for(var E=l.length,G=Qi(E),V=Qi(E),F=Qi(E),J=Qi(E),ut=[],_=0;_<p.length;_++){var lt=p[_],ct=_*2,pt=lt*2;G[ct]=l[pt],G[ct+1]=l[pt+1],V[ct]=f[pt],V[ct+1]=f[pt+1],F[ct]=h[pt],F[ct+1]=h[pt+1],J[ct]=v[pt],J[ct+1]=v[pt+1],ut[_]=c[lt]}return{current:G,next:V,stackedOnCurrent:F,stackedOnNext:J,status:ut}}var cr=Math.min,pr=Math.max;function pi(r,t){return isNaN(r)||isNaN(t)}function Uf(r,t,e,i,n,a,o,s,u){for(var l,f,h,v,c,p,d=e,g=0;g<i;g++){var y=t[d*2],m=t[d*2+1];if(d>=n||d<0)break;if(pi(y,m)){if(u){d+=a;continue}break}if(d===e)r[a>0?"moveTo":"lineTo"](y,m),h=y,v=m;else{var _=y-l,S=m-f;if(_*_+S*S<.5){d+=a;continue}if(o>0){for(var b=d+a,w=t[b*2],x=t[b*2+1];w===y&&x===m&&g<i;)g++,b+=a,d+=a,w=t[b*2],x=t[b*2+1],y=t[d*2],m=t[d*2+1],_=y-l,S=m-f;var C=g+1;if(u)for(;pi(w,x)&&C<i;)C++,b+=a,w=t[b*2],x=t[b*2+1];var M=.5,D=0,A=0,P=void 0,R=void 0;if(C>=i||pi(w,x))c=y,p=m;else{D=w-l,A=x-f;var L=y-l,I=w-y,E=m-f,G=x-m,V=void 0,F=void 0;if(s==="x"){V=Math.abs(L),F=Math.abs(I);var J=D>0?1:-1;c=y-J*V*o,p=m,P=y+J*F*o,R=m}else if(s==="y"){V=Math.abs(E),F=Math.abs(G);var ut=A>0?1:-1;c=y,p=m-ut*V*o,P=y,R=m+ut*F*o}else V=Math.sqrt(L*L+E*E),F=Math.sqrt(I*I+G*G),M=F/(F+V),c=y-D*o*(1-M),p=m-A*o*(1-M),P=y+D*o*M,R=m+A*o*M,P=cr(P,pr(w,y)),R=cr(R,pr(x,m)),P=pr(P,cr(w,y)),R=pr(R,cr(x,m)),D=P-y,A=R-m,c=y-D*V/F,p=m-A*V/F,c=cr(c,pr(l,y)),p=cr(p,pr(f,m)),c=pr(c,cr(l,y)),p=pr(p,cr(f,m)),D=y-c,A=m-p,P=y+D*F/V,R=m+A*F/V}r.bezierCurveTo(h,v,c,p,y,m),h=P,v=R}else r.lineTo(y,m)}l=y,f=m,d+=a}return g}var b_=(function(){function r(){this.smooth=0,this.smoothConstraint=!0}return r})(),mA=(function(r){O(t,r);function t(e){var i=r.call(this,e)||this;return i.type="ec-polyline",i}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new b_},t.prototype.buildPath=function(e,i){var n=i.points,a=0,o=n.length/2;if(i.connectNulls){for(;o>0&&pi(n[o*2-2],n[o*2-1]);o--);for(;a<o&&pi(n[a*2],n[a*2+1]);a++);}for(;a<o;)a+=Uf(e,n,a,o,o,1,i.smooth,i.smoothMonotone,i.connectNulls)+1},t.prototype.getPointOn=function(e,i){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var n=this.path,a=n.data,o=Ar.CMD,s,u,l=i==="x",f=[],h=0;h<a.length;){var v=a[h++],c=void 0,p=void 0,d=void 0,g=void 0,y=void 0,m=void 0,_=void 0;switch(v){case o.M:s=a[h++],u=a[h++];break;case o.L:if(c=a[h++],p=a[h++],_=l?(e-s)/(c-s):(e-u)/(p-u),_<=1&&_>=0){var S=l?(p-u)*_+u:(c-s)*_+s;return l?[e,S]:[S,e]}s=c,u=p;break;case o.C:c=a[h++],p=a[h++],d=a[h++],g=a[h++],y=a[h++],m=a[h++];var b=l?$o(s,c,d,y,e,f):$o(u,p,g,m,e,f);if(b>0)for(var w=0;w<b;w++){var x=f[w];if(x<=1&&x>=0){var S=l?Mt(u,p,g,m,x):Mt(s,c,d,y,x);return l?[e,S]:[S,e]}}s=y,u=m;break}}},t})(st),_A=(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t})(b_),SA=(function(r){O(t,r);function t(e){var i=r.call(this,e)||this;return i.type="ec-polygon",i}return t.prototype.getDefaultShape=function(){return new _A},t.prototype.buildPath=function(e,i){var n=i.points,a=i.stackedOnPoints,o=0,s=n.length/2,u=i.smoothMonotone;if(i.connectNulls){for(;s>0&&pi(n[s*2-2],n[s*2-1]);s--);for(;o<s&&pi(n[o*2],n[o*2+1]);o++);}for(;o<s;){var l=Uf(e,n,o,s,s,1,i.smooth,u,i.connectNulls);Uf(e,a,o+l-1,l,s,-1,i.stackedOnSmooth,u,i.connectNulls),o+=l+1,e.closePath()}},t})(st);function x_(r,t,e,i,n){var a=r.getArea(),o=a.x,s=a.y,u=a.width,l=a.height,f=e.get(["lineStyle","width"])||0;o-=f/2,s-=f/2,u+=f,l+=f,u=Math.ceil(u),o!==Math.floor(o)&&(o=Math.floor(o),u++);var h=new Tt({shape:{x:o,y:s,width:u,height:l}});if(t){var v=r.getBaseAxis(),c=v.isHorizontal(),p=v.inverse;c?(p&&(h.shape.x+=u),h.shape.width=0):(p||(h.shape.y+=l),h.shape.height=0);var d=q(n)?function(g){n(g,h)}:null;rr(h,{shape:{width:u,height:l,x:o,y:s}},e,null,i,d)}return h}function T_(r,t,e){var i=r.getArea(),n=xt(i.r0,1),a=xt(i.r,1),o=new zs({shape:{cx:xt(r.cx,1),cy:xt(r.cy,1),r0:n,r:a,startAngle:i.startAngle,endAngle:i.endAngle,clockwise:i.clockwise}});if(t){var s=r.getBaseAxis().dim==="angle";s?o.shape.endAngle=i.startAngle:o.shape.r=n,rr(o,{shape:{endAngle:i.endAngle,r:a}},e)}return o}function wA(r,t,e,i,n){if(r){if(r.type==="polar")return T_(r,t,e);if(r.type==="cartesian2d")return x_(r,t,e,i,n)}else return null;return null}function su(r,t){return r.type===t}function Sd(r,t){if(r.length===t.length){for(var e=0;e<r.length;e++)if(r[e]!==t[e])return;return!0}}function wd(r){for(var t=1/0,e=1/0,i=-1/0,n=-1/0,a=0;a<r.length;){var o=r[a++],s=r[a++];isNaN(o)||(t=Math.min(o,t),i=Math.max(o,i)),isNaN(s)||(e=Math.min(s,e),n=Math.max(s,n))}return[[t,e],[i,n]]}function bd(r,t){var e=wd(r),i=e[0],n=e[1],a=wd(t),o=a[0],s=a[1];return Math.max(Math.abs(i[0]-o[0]),Math.abs(i[1]-o[1]),Math.abs(n[0]-s[0]),Math.abs(n[1]-s[1]))}function xd(r){return dt(r)?r:r?.5:0}function bA(r,t,e){if(!e.valueDim)return[];for(var i=t.count(),n=Qi(i*2),a=0;a<i;a++){var o=w_(e,r,t,a);n[a*2]=o[0],n[a*2+1]=o[1]}return n}function dr(r,t,e,i,n){var a=e.getBaseAxis(),o=a.dim==="x"||a.dim==="radius"?0:1,s=[],u=0,l=[],f=[],h=[],v=[];if(n){for(u=0;u<r.length;u+=2){var c=t||r;!isNaN(c[u])&&!isNaN(c[u+1])&&v.push(r[u],r[u+1])}r=v}for(u=0;u<r.length-2;u+=2)switch(h[0]=r[u+2],h[1]=r[u+3],f[0]=r[u],f[1]=r[u+1],s.push(f[0],f[1]),i){case"end":l[o]=h[o],l[1-o]=f[1-o],s.push(l[0],l[1]);break;case"middle":var p=(f[o]+h[o])/2,d=[];l[o]=d[o]=p,l[1-o]=f[1-o],d[1-o]=h[1-o],s.push(l[0],l[1]),s.push(d[0],d[1]);break;default:l[o]=f[o],l[1-o]=h[1-o],s.push(l[0],l[1])}return s.push(r[u++],r[u++]),s}function xA(r,t){var e=[],i=r.length,n,a;function o(f,h,v){var c=f.coord,p=(v-c)/(h.coord-c),d=xS(p,[f.color,h.color]);return{coord:v,color:d}}for(var s=0;s<i;s++){var u=r[s],l=u.coord;if(l<0)n=u;else if(l>t){a?e.push(o(a,u,t)):n&&e.push(o(n,u,0),o(n,u,t));break}else n&&(e.push(o(n,u,0)),n=null),e.push(u),a=u}return e}function TA(r,t,e){var i=r.getVisual("visualMeta");if(!(!i||!i.length||!r.count())&&t.type==="cartesian2d"){for(var n,a,o=i.length-1;o>=0;o--){var s=r.getDimensionInfo(i[o].dimension);if(n=s&&s.coordDim,n==="x"||n==="y"){a=i[o];break}}if(a){var u=t.getAxis(n),l=z(a.stops,function(_){return{coord:u.toGlobalCoord(u.dataToCoord(_.value)),color:_.color}}),f=l.length,h=a.outerColors.slice();f&&l[0].coord>l[f-1].coord&&(l.reverse(),h.reverse());var v=xA(l,n==="x"?e.getWidth():e.getHeight()),c=v.length;if(!c&&f)return l[0].coord<0?h[1]?h[1]:l[f-1].color:h[0]?h[0]:l[0].color;var p=10,d=v[0].coord-p,g=v[c-1].coord+p,y=g-d;if(y<.001)return"transparent";T(v,function(_){_.offset=(_.coord-d)/y}),v.push({offset:c?v[c-1].offset:.5,color:h[1]||"transparent"}),v.unshift({offset:c?v[0].offset:.5,color:h[0]||"transparent"});var m=new cm(0,0,0,0,v,!0);return m[n]=d,m[n+"2"]=g,m}}}function MA(r,t,e){var i=r.get("showAllSymbol"),n=i==="auto";if(!(i&&!n)){var a=e.getAxesByScale("ordinal")[0];if(a&&!(n&&CA(a,t))){var o=t.mapDimension(a.dim),s={};return T(a.getViewLabels(),function(u){var l=a.scale.getRawOrdinalNumber(u.tickValue);s[l]=1}),function(u){return!s.hasOwnProperty(t.get(o,u))}}}}function CA(r,t){var e=r.getExtent(),i=Math.abs(e[1]-e[0])/r.scale.count();isNaN(i)&&(i=0);for(var n=t.count(),a=Math.max(1,Math.round(n/5)),o=0;o<n;o+=a)if(lv.getSymbolSize(t,o)[r.isHorizontal()?1:0]*1.5>i)return!1;return!0}function DA(r,t){return isNaN(r)||isNaN(t)}function AA(r){for(var t=r.length/2;t>0&&DA(r[t*2-2],r[t*2-1]);t--);return t-1}function Td(r,t){return[r[t*2],r[t*2+1]]}function LA(r,t,e){for(var i=r.length/2,n=e==="x"?0:1,a,o,s=0,u=-1,l=0;l<i;l++)if(o=r[l*2+n],!(isNaN(o)||isNaN(r[l*2+1-n]))){if(l===0){a=o;continue}if(a<=t&&o>=t||a>=t&&o<=t){u=l;break}s=l,a=o}return{range:[s,u],t:(t-a)/(o-a)}}function M_(r){if(r.get(["endLabel","show"]))return!0;for(var t=0;t<Zt.length;t++)if(r.get([Zt[t],"endLabel","show"]))return!0;return!1}function bl(r,t,e,i){if(su(t,"cartesian2d")){var n=i.getModel("endLabel"),a=n.get("valueAnimation"),o=i.getData(),s={lastFrameIndex:0},u=M_(i)?function(c,p){r._endLabelOnDuring(c,p,o,s,a,n,t)}:null,l=t.getBaseAxis().isHorizontal(),f=x_(t,e,i,function(){var c=r._endLabel;c&&e&&s.originalX!=null&&c.attr({x:s.originalX,y:s.originalY})},u);if(!i.get("clip",!0)){var h=f.shape,v=Math.max(h.width,h.height);l?(h.y-=v,h.height+=v*2):(h.x-=v,h.width+=v*2)}return u&&u(1,f),f}else return T_(t,e,i)}function PA(r,t){var e=t.getBaseAxis(),i=e.isHorizontal(),n=e.inverse,a=i?n?"right":"left":"center",o=i?"middle":n?"top":"bottom";return{normal:{align:r.get("align")||a,verticalAlign:r.get("verticalAlign")||o}}}var IA=(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.init=function(){var e=new gt,i=new __;this.group.add(i.group),this._symbolDraw=i,this._lineGroup=e,this._changePolyState=U(this._changePolyState,this)},t.prototype.render=function(e,i,n){var a=e.coordinateSystem,o=this.group,s=e.getData(),u=e.getModel("lineStyle"),l=e.getModel("areaStyle"),f=s.getLayout("points")||[],h=a.type==="polar",v=this._coordSys,c=this._symbolDraw,p=this._polyline,d=this._polygon,g=this._lineGroup,y=!i.ssr&&e.get("animation"),m=!l.isEmpty(),_=l.get("origin"),S=S_(a,s,_),b=m&&bA(a,s,S),w=e.get("showSymbol"),x=e.get("connectNulls"),C=w&&!h&&MA(e,s,a),M=this._data;M&&M.eachItemGraphicEl(function(mt,ye){mt.__temp&&(o.remove(mt),M.setItemGraphicEl(ye,null))}),w||c.remove(),o.add(g);var D=h?!1:e.get("step"),A;a&&a.getArea&&e.get("clip",!0)&&(A=a.getArea(),A.width!=null?(A.x-=.1,A.y-=.1,A.width+=.2,A.height+=.2):A.r0&&(A.r0-=.5,A.r+=.5)),this._clipShapeForSymbol=A;var P=TA(s,a,n)||s.getVisual("style")[s.getVisual("drawType")];if(!(p&&v.type===a.type&&D===this._step))w&&c.updateData(s,{isIgnore:C,clipShape:A,disableAnimation:!0,getSymbolPoint:function(mt){return[f[mt*2],f[mt*2+1]]}}),y&&this._initSymbolLabelAnimation(s,a,A),D&&(b&&(b=dr(b,f,a,D,x)),f=dr(f,null,a,D,x)),p=this._newPolyline(f),m?d=this._newPolygon(f,b):d&&(g.remove(d),d=this._polygon=null),h||this._initOrUpdateEndLabel(e,a,_i(P)),g.setClipPath(bl(this,a,!0,e));else{m&&!d?d=this._newPolygon(f,b):d&&!m&&(g.remove(d),d=this._polygon=null),h||this._initOrUpdateEndLabel(e,a,_i(P));var R=g.getClipPath();if(R){var L=bl(this,a,!1,e);rr(R,{shape:L.shape},e)}else g.setClipPath(bl(this,a,!0,e));w&&c.updateData(s,{isIgnore:C,clipShape:A,disableAnimation:!0,getSymbolPoint:function(mt){return[f[mt*2],f[mt*2+1]]}}),(!Sd(this._stackedOnPoints,b)||!Sd(this._points,f))&&(y?this._doUpdateAnimation(s,b,a,n,D,_,x):(D&&(b&&(b=dr(b,f,a,D,x)),f=dr(f,null,a,D,x)),p.setShape({points:f}),d&&d.setShape({points:f,stackedOnPoints:b})))}var I=e.getModel("emphasis"),E=I.get("focus"),G=I.get("blurScope"),V=I.get("disabled");if(p.useStyle(rt(u.getLineStyle(),{fill:"none",stroke:P,lineJoin:"bevel"})),wf(p,e,"lineStyle"),p.style.lineWidth>0&&e.get(["emphasis","lineStyle","width"])==="bolder"){var F=p.getState("emphasis").style;F.lineWidth=+p.style.lineWidth+1}at(p).seriesIndex=e.seriesIndex,vn(p,E,G,V);var J=xd(e.get("smooth")),ut=e.get("smoothMonotone");if(p.setShape({smooth:J,smoothMonotone:ut,connectNulls:x}),d){var lt=s.getCalculationInfo("stackedOnSeries"),ct=0;d.useStyle(rt(l.getAreaStyle(),{fill:P,opacity:.7,lineJoin:"bevel",decal:s.getVisual("style").decal})),lt&&(ct=xd(lt.get("smooth"))),d.setShape({smooth:J,stackedOnSmooth:ct,smoothMonotone:ut,connectNulls:x}),wf(d,e,"areaStyle"),at(d).seriesIndex=e.seriesIndex,vn(d,E,G,V)}var pt=this._changePolyState;s.eachItemGraphicEl(function(mt){mt&&(mt.onHoverStateChange=pt)}),this._polyline.onHoverStateChange=pt,this._data=s,this._coordSys=a,this._stackedOnPoints=b,this._points=f,this._step=D,this._valueOrigin=_,e.get("triggerLineEvent")&&(this.packEventData(e,p),d&&this.packEventData(e,d))},t.prototype.packEventData=function(e,i){at(i).eventData={componentType:"series",componentSubType:"line",componentIndex:e.componentIndex,seriesIndex:e.seriesIndex,seriesName:e.name,seriesType:"line"}},t.prototype.highlight=function(e,i,n,a){var o=e.getData(),s=yi(o,a);if(this._changePolyState("emphasis"),!(s instanceof Array)&&s!=null&&s>=0){var u=o.getLayout("points"),l=o.getItemGraphicEl(s);if(!l){var f=u[s*2],h=u[s*2+1];if(isNaN(f)||isNaN(h)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(f,h))return;var v=e.get("zlevel")||0,c=e.get("z")||0;l=new lv(o,s),l.x=f,l.y=h,l.setZ(v,c);var p=l.getSymbolPath().getTextContent();p&&(p.zlevel=v,p.z=c,p.z2=this._polyline.z2+1),l.__temp=!0,o.setItemGraphicEl(s,l),l.stopSymbolAnimation(!0),this.group.add(l)}l.highlight()}else ce.prototype.highlight.call(this,e,i,n,a)},t.prototype.downplay=function(e,i,n,a){var o=e.getData(),s=yi(o,a);if(this._changePolyState("normal"),s!=null&&s>=0){var u=o.getItemGraphicEl(s);u&&(u.__temp?(o.setItemGraphicEl(s,null),this.group.remove(u)):u.downplay())}else ce.prototype.downplay.call(this,e,i,n,a)},t.prototype._changePolyState=function(e){var i=this._polygon;Ec(this._polyline,e),i&&Ec(i,e)},t.prototype._newPolyline=function(e){var i=this._polyline;return i&&this._lineGroup.remove(i),i=new mA({shape:{points:e},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(i),this._polyline=i,i},t.prototype._newPolygon=function(e,i){var n=this._polygon;return n&&this._lineGroup.remove(n),n=new SA({shape:{points:e,stackedOnPoints:i},segmentIgnoreThreshold:2}),this._lineGroup.add(n),this._polygon=n,n},t.prototype._initSymbolLabelAnimation=function(e,i,n){var a,o,s=i.getBaseAxis(),u=s.inverse;i.type==="cartesian2d"?(a=s.isHorizontal(),o=!1):i.type==="polar"&&(a=s.dim==="angle",o=!0);var l=e.hostModel,f=l.get("animationDuration");q(f)&&(f=f(null));var h=l.get("animationDelay")||0,v=q(h)?h(null):h;e.eachItemGraphicEl(function(c,p){var d=c;if(d){var g=[c.x,c.y],y=void 0,m=void 0,_=void 0;if(n)if(o){var S=n,b=i.pointToCoord(g);a?(y=S.startAngle,m=S.endAngle,_=-b[1]/180*Math.PI):(y=S.r0,m=S.r,_=b[0])}else{var w=n;a?(y=w.x,m=w.x+w.width,_=c.x):(y=w.y+w.height,m=w.y,_=c.y)}var x=m===y?0:(_-y)/(m-y);u&&(x=1-x);var C=q(h)?h(p):f*x+v,M=d.getSymbolPath(),D=M.getTextContent();d.attr({scaleX:0,scaleY:0}),d.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:C}),D&&D.animateFrom({style:{opacity:0}},{duration:300,delay:C}),M.disableLabelAnimation=!0}})},t.prototype._initOrUpdateEndLabel=function(e,i,n){var a=e.getModel("endLabel");if(M_(e)){var o=e.getData(),s=this._polyline,u=o.getLayout("points");if(!u){s.removeTextContent(),this._endLabel=null;return}var l=this._endLabel;l||(l=this._endLabel=new te({z2:200}),l.ignoreClip=!0,s.setTextContent(this._endLabel),s.disableLabelAnimation=!0);var f=AA(u);f>=0&&(Ys(s,Sn(e,"endLabel"),{inheritColor:n,labelFetcher:e,labelDataIndex:f,defaultText:function(h,v,c){return c!=null?cA(o,c):ys(o,h)},enableTextSetter:!0},PA(a,i)),s.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},t.prototype._endLabelOnDuring=function(e,i,n,a,o,s,u){var l=this._endLabel,f=this._polyline;if(l){e<1&&a.originalX==null&&(a.originalX=l.x,a.originalY=l.y);var h=n.getLayout("points"),v=n.hostModel,c=v.get("connectNulls"),p=s.get("precision"),d=s.get("distance")||0,g=u.getBaseAxis(),y=g.isHorizontal(),m=g.inverse,_=i.shape,S=m?y?_.x:_.y+_.height:y?_.x+_.width:_.y,b=(y?d:0)*(m?-1:1),w=(y?0:-d)*(m?-1:1),x=y?"x":"y",C=LA(h,S,x),M=C.range,D=M[1]-M[0],A=void 0;if(D>=1){if(D>1&&!c){var P=Td(h,M[0]);l.attr({x:P[0]+b,y:P[1]+w}),o&&(A=v.getRawValue(M[0]))}else{var P=f.getPointOn(S,x);P&&l.attr({x:P[0]+b,y:P[1]+w});var R=v.getRawValue(M[0]),L=v.getRawValue(M[1]);o&&(A=Fy(n,p,R,L,C.t))}a.lastFrameIndex=M[0]}else{var I=e===1||a.lastFrameIndex>0?M[0]:0,P=Td(h,I);o&&(A=v.getRawValue(I)),l.attr({x:P[0]+b,y:P[1]+w})}if(o){var E=Zs(l);typeof E.setLabelText=="function"&&E.setLabelText(A)}}},t.prototype._doUpdateAnimation=function(e,i,n,a,o,s,u){var l=this._polyline,f=this._polygon,h=e.hostModel,v=yA(this._data,e,this._stackedOnPoints,i,this._coordSys,n,this._valueOrigin),c=v.current,p=v.stackedOnCurrent,d=v.next,g=v.stackedOnNext;if(o&&(p=dr(v.stackedOnCurrent,v.current,n,o,u),c=dr(v.current,null,n,o,u),g=dr(v.stackedOnNext,v.next,n,o,u),d=dr(v.next,null,n,o,u)),bd(c,d)>3e3||f&&bd(p,g)>3e3){l.stopAnimation(),l.setShape({points:d}),f&&(f.stopAnimation(),f.setShape({points:d,stackedOnPoints:g}));return}l.shape.__points=v.current,l.shape.points=c;var y={shape:{points:d}};v.current!==c&&(y.shape.__points=v.next),l.stopAnimation(),pe(l,y,h),f&&(f.setShape({points:c,stackedOnPoints:p}),f.stopAnimation(),pe(f,{shape:{stackedOnPoints:g}},h),l.shape.points!==f.shape.points&&(f.shape.points=l.shape.points));for(var m=[],_=v.status,S=0;S<_.length;S++){var b=_[S].cmd;if(b==="="){var w=e.getItemGraphicEl(_[S].idx1);w&&m.push({el:w,ptIdx:S})}}l.animators&&l.animators.length&&l.animators[0].during(function(){f&&f.dirtyShape();for(var x=l.shape.__points,C=0;C<m.length;C++){var M=m[C].el,D=m[C].ptIdx*2;M.x=x[D],M.y=x[D+1],M.markRedraw()}})},t.prototype.remove=function(e){var i=this.group,n=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),n&&n.eachItemGraphicEl(function(a,o){a.__temp&&(i.remove(a),n.setItemGraphicEl(o,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},t.type="line",t})(ce);function fv(r,t){return{seriesType:r,plan:v0(),reset:function(e){var i=e.getData(),n=e.coordinateSystem,a=e.pipelineContext,o=t||a.large;if(n){var s=z(n.dimensions,function(c){return i.mapDimension(c)}).slice(0,2),u=s.length,l=i.getCalculationInfo("stackResultDimension");pn(i,s[0])&&(s[0]=l),pn(i,s[1])&&(s[1]=l);var f=i.getStore(),h=i.getDimensionIndex(s[0]),v=i.getDimensionIndex(s[1]);return u&&{progress:function(c,p){for(var d=c.end-c.start,g=o&&Qi(d*u),y=[],m=[],_=c.start,S=0;_<c.end;_++){var b=void 0;if(u===1){var w=f.get(h,_);b=n.dataToPoint(w,null,m)}else y[0]=f.get(h,_),y[1]=f.get(v,_),b=n.dataToPoint(y,null,m);o?(g[S++]=b[0],g[S++]=b[1]):p.setItemLayout(_,b.slice())}o&&p.setLayout("points",g)}}}}}}var RA={average:function(r){for(var t=0,e=0,i=0;i<r.length;i++)isNaN(r[i])||(t+=r[i],e++);return e===0?NaN:t/e},sum:function(r){for(var t=0,e=0;e<r.length;e++)t+=r[e]||0;return t},max:function(r){for(var t=-1/0,e=0;e<r.length;e++)r[e]>t&&(t=r[e]);return isFinite(t)?t:NaN},min:function(r){for(var t=1/0,e=0;e<r.length;e++)r[e]<t&&(t=r[e]);return isFinite(t)?t:NaN},nearest:function(r){return r[0]}},EA=function(r){return Math.round(r.length/2)};function kA(r){return{seriesType:r,reset:function(t,e,i){var n=t.getData(),a=t.get("sampling"),o=t.coordinateSystem,s=n.count();if(s>10&&o.type==="cartesian2d"&&a){var u=o.getBaseAxis(),l=o.getOtherAxis(u),f=u.getExtent(),h=i.getDevicePixelRatio(),v=Math.abs(f[1]-f[0])*(h||1),c=Math.round(s/v);if(isFinite(c)&&c>1){a==="lttb"?t.setData(n.lttbDownSample(n.mapDimension(l.dim),1/c)):a==="minmax"&&t.setData(n.minmaxDownSample(n.mapDimension(l.dim),1/c));var p=void 0;H(a)?p=RA[a]:q(a)&&(p=a),p&&t.setData(n.downSample(n.mapDimension(l.dim),1/c,p,EA))}}}}}function OA(r){r.registerChartView(IA),r.registerSeriesModel(vA),r.registerLayout(fv("line",!0)),r.registerVisual({seriesType:"line",reset:function(t){var e=t.getData(),i=t.getModel("lineStyle").getLineStyle();i&&!i.stroke&&(i.stroke=e.getVisual("style").fill),e.setVisual("legendLineStyle",i)}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,kA("line"))}var BA=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.hasSymbolVisual=!0,e}return t.prototype.getInitialData=function(e,i){return nv(null,this,{useEncodeDefaulter:!0})},t.prototype.getProgressive=function(){var e=this.option.progressive;return e??(this.option.large?5e3:this.get("progressive"))},t.prototype.getProgressiveThreshold=function(){var e=this.option.progressiveThreshold;return e??(this.option.large?1e4:this.get("progressiveThreshold"))},t.prototype.brushSelector=function(e,i,n){return n.point(i.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"],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:"#212121"}},universalTransition:{divideShape:"clone"}},t})(He),C_=4,NA=(function(){function r(){}return r})(),FA=(function(r){O(t,r);function t(e){var i=r.call(this,e)||this;return i._off=0,i.hoverDataIdx=-1,i}return t.prototype.getDefaultShape=function(){return new NA},t.prototype.reset=function(){this.notClear=!1,this._off=0},t.prototype.buildPath=function(e,i){var n=i.points,a=i.size,o=this.symbolProxy,s=o.shape,u=e.getContext?e.getContext():e,l=u&&a[0]<C_,f=this.softClipShape,h;if(l){this._ctx=u;return}for(this._ctx=null,h=this._off;h<n.length;){var v=n[h++],c=n[h++];isNaN(v)||isNaN(c)||f&&!f.contain(v,c)||(s.x=v-a[0]/2,s.y=c-a[1]/2,s.width=a[0],s.height=a[1],o.buildPath(e,s,!0))}this.incremental&&(this._off=h,this.notClear=!0)},t.prototype.afterBrush=function(){var e=this.shape,i=e.points,n=e.size,a=this._ctx,o=this.softClipShape,s;if(a){for(s=this._off;s<i.length;){var u=i[s++],l=i[s++];isNaN(u)||isNaN(l)||o&&!o.contain(u,l)||a.fillRect(u-n[0]/2,l-n[1]/2,n[0],n[1])}this.incremental&&(this._off=s,this.notClear=!0)}},t.prototype.findDataIndex=function(e,i){for(var n=this.shape,a=n.points,o=n.size,s=Math.max(o[0],4),u=Math.max(o[1],4),l=a.length/2-1;l>=0;l--){var f=l*2,h=a[f]-s/2,v=a[f+1]-u/2;if(e>=h&&i>=v&&e<=h+s&&i<=v+u)return l}return-1},t.prototype.contain=function(e,i){var n=this.transformCoordToLocal(e,i),a=this.getBoundingRect();if(e=n[0],i=n[1],a.contain(e,i)){var o=this.hoverDataIdx=this.findDataIndex(e,i);return o>=0}return this.hoverDataIdx=-1,!1},t.prototype.getBoundingRect=function(){var e=this._rect;if(!e){for(var i=this.shape,n=i.points,a=i.size,o=a[0],s=a[1],u=1/0,l=1/0,f=-1/0,h=-1/0,v=0;v<n.length;){var c=n[v++],p=n[v++];u=Math.min(c,u),f=Math.max(c,f),l=Math.min(p,l),h=Math.max(p,h)}e=this._rect=new et(u-o/2,l-s/2,f-u+o,h-l+s)}return e},t})(st),zA=(function(){function r(){this.group=new gt}return r.prototype.updateData=function(t,e){this._clear();var i=this._create();i.setShape({points:t.getLayout("points")}),this._setCommon(i,t,e)},r.prototype.updateLayout=function(t){var e=t.getLayout("points");this.group.eachChild(function(i){if(i.startIndex!=null){var n=(i.endIndex-i.startIndex)*2,a=i.startIndex*4*2;e=new Float32Array(e.buffer,a,n)}i.setShape("points",e),i.reset()})},r.prototype.incrementalPrepareUpdate=function(t){this._clear()},r.prototype.incrementalUpdate=function(t,e,i){var n=this._newAdded[0],a=e.getLayout("points"),o=n&&n.shape.points;if(o&&o.length<2e4){var s=o.length,u=new Float32Array(s+a.length);u.set(o),u.set(a,s),n.endIndex=t.end,n.setShape({points:u})}else{this._newAdded=[];var l=this._create();l.startIndex=t.start,l.endIndex=t.end,l.incremental=!0,l.setShape({points:a}),this._setCommon(l,e,i)}},r.prototype.eachRendered=function(t){this._newAdded[0]&&t(this._newAdded[0])},r.prototype._create=function(){var t=new FA({cursor:"default"});return t.ignoreCoarsePointer=!0,this.group.add(t),this._newAdded.push(t),t},r.prototype._setCommon=function(t,e,i){var n=e.hostModel;i=i||{};var a=e.getVisual("symbolSize");t.setShape("size",a instanceof Array?a:[a,a]),t.softClipShape=i.clipShape||null,t.symbolProxy=ir(e.getVisual("symbol"),0,0,0,0),t.setColor=t.symbolProxy.setColor;var o=t.shape.size[0]<C_;t.useStyle(n.getModel("itemStyle").getItemStyle(o?["color","shadowBlur","shadowColor"]:["color"]));var s=e.getVisual("style"),u=s&&s.fill;u&&t.setColor(u);var l=at(t);l.seriesIndex=n.seriesIndex,t.on("mousemove",function(f){l.dataIndex=null;var h=t.hoverDataIdx;h>=0&&(l.dataIndex=h+(t.startIndex||0))})},r.prototype.remove=function(){this._clear()},r.prototype._clear=function(){this._newAdded=[],this.group.removeAll()},r})(),VA=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n){var a=e.getData(),o=this._updateSymbolDraw(a,e);o.updateData(a,{clipShape:this._getClipShape(e)}),this._finished=!0},t.prototype.incrementalPrepareRender=function(e,i,n){var a=e.getData(),o=this._updateSymbolDraw(a,e);o.incrementalPrepareUpdate(a),this._finished=!1},t.prototype.incrementalRender=function(e,i,n){this._symbolDraw.incrementalUpdate(e,i.getData(),{clipShape:this._getClipShape(i)}),this._finished=e.end===i.getData().count()},t.prototype.updateTransform=function(e,i,n){var a=e.getData();if(this.group.dirty(),!this._finished||a.count()>1e4)return{update:!0};var o=fv("").reset(e,i,n);o.progress&&o.progress({start:0,end:a.count(),count:a.count()},a),this._symbolDraw.updateLayout(a)},t.prototype.eachRendered=function(e){this._symbolDraw&&this._symbolDraw.eachRendered(e)},t.prototype._getClipShape=function(e){if(e.get("clip",!0)){var i=e.coordinateSystem;return i&&i.getArea&&i.getArea(.1)}},t.prototype._updateSymbolDraw=function(e,i){var n=this._symbolDraw,a=i.pipelineContext,o=a.large;return(!n||o!==this._isLargeDraw)&&(n&&n.remove(),n=this._symbolDraw=o?new zA:new __,this._isLargeDraw=o,this.group.removeAll()),this.group.add(n.group),n},t.prototype.remove=function(e,i){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},t.prototype.dispose=function(){},t.type="scatter",t})(ce),HA=(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.type="grid",t.dependencies=["xAxis","yAxis"],t.layoutMode="box",t.defaultOption={show:!1,z:0,left:"10%",top:60,right:"10%",bottom:70,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"},t})(nt),Yf=(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",Ut).models[0]},t.type="cartesian2dAxis",t})(nt);Ce(Yf,OD);var D_={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#6E7079",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,showMinLine:!0,showMaxLine:!0,lineStyle:{color:["#E0E6F1"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.2)","rgba(210,219,238,0.2)"]}}},GA=tt({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},D_),hv=tt({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:"#F4F7FD",width:1}}},D_),WA=tt({splitNumber:6,axisLabel:{showMinLabel:!1,showMaxLabel:!1,rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},hv),UA=rt({logBase:10},hv);const YA={category:GA,value:hv,time:WA,log:UA};var ZA={value:1,category:1,time:1,log:1};function Md(r,t,e,i){T(ZA,function(n,a){var o=tt(tt({},YA[a],!0),i,!0),s=(function(u){O(l,u);function l(){var f=u!==null&&u.apply(this,arguments)||this;return f.type=t+"Axis."+a,f}return l.prototype.mergeDefaultAndTheme=function(f,h){var v=Da(this),c=v?js(f):{},p=h.getTheme();tt(f,p.get(a+"Axis")),tt(f,this.getDefaultOption()),f.type=Cd(f),v&&Aa(f,c,v)},l.prototype.optionUpdated=function(){var f=this.option;f.type==="category"&&(this.__ordinalMeta=Vf.createByAxisModel(this))},l.prototype.getCategories=function(f){var h=this.option;if(h.type==="category")return f?h.data:this.__ordinalMeta.categories},l.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},l.type=t+"Axis."+a,l.defaultOption=o,l})(e);r.registerComponentModel(s)}),r.registerSubTypeDefaulter(t+"Axis",Cd)}function Cd(r){return r.type||(r.data?"category":"value")}var XA=(function(){function r(t){this.type="cartesian",this._dimList=[],this._axes={},this.name=t||""}return r.prototype.getAxis=function(t){return this._axes[t]},r.prototype.getAxes=function(){return z(this._dimList,function(t){return this._axes[t]},this)},r.prototype.getAxesByScale=function(t){return t=t.toLowerCase(),_t(this.getAxes(),function(e){return e.scale.type===t})},r.prototype.addAxis=function(t){var e=t.dim;this._axes[e]=t,this._dimList.push(e)},r})(),Zf=["x","y"];function Dd(r){return r.type==="interval"||r.type==="time"}var $A=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="cartesian2d",e.dimensions=Zf,e}return t.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var e=this.getAxis("x").scale,i=this.getAxis("y").scale;if(!(!Dd(e)||!Dd(i))){var n=e.getExtent(),a=i.getExtent(),o=this.dataToPoint([n[0],a[0]]),s=this.dataToPoint([n[1],a[1]]),u=n[1]-n[0],l=a[1]-a[0];if(!(!u||!l)){var f=(s[0]-o[0])/u,h=(s[1]-o[1])/l,v=o[0]-n[0]*f,c=o[1]-a[0]*h,p=this._transform=[f,0,0,h,v,c];this._invTransform=Ls([],p)}}},t.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},t.prototype.containPoint=function(e){var i=this.getAxis("x"),n=this.getAxis("y");return i.contain(i.toLocalCoord(e[0]))&&n.contain(n.toLocalCoord(e[1]))},t.prototype.containData=function(e){return this.getAxis("x").containData(e[0])&&this.getAxis("y").containData(e[1])},t.prototype.containZone=function(e,i){var n=this.dataToPoint(e),a=this.dataToPoint(i),o=this.getArea(),s=new et(n[0],n[1],a[0]-n[0],a[1]-n[1]);return o.intersect(s)},t.prototype.dataToPoint=function(e,i,n){n=n||[];var a=e[0],o=e[1];if(this._transform&&a!=null&&isFinite(a)&&o!=null&&isFinite(o))return ve(n,e,this._transform);var s=this.getAxis("x"),u=this.getAxis("y");return n[0]=s.toGlobalCoord(s.dataToCoord(a,i)),n[1]=u.toGlobalCoord(u.dataToCoord(o,i)),n},t.prototype.clampData=function(e,i){var n=this.getAxis("x").scale,a=this.getAxis("y").scale,o=n.getExtent(),s=a.getExtent(),u=n.parse(e[0]),l=a.parse(e[1]);return i=i||[],i[0]=Math.min(Math.max(Math.min(o[0],o[1]),u),Math.max(o[0],o[1])),i[1]=Math.min(Math.max(Math.min(s[0],s[1]),l),Math.max(s[0],s[1])),i},t.prototype.pointToData=function(e,i){var n=[];if(this._invTransform)return ve(n,e,this._invTransform);var a=this.getAxis("x"),o=this.getAxis("y");return n[0]=a.coordToData(a.toLocalCoord(e[0]),i),n[1]=o.coordToData(o.toLocalCoord(e[1]),i),n},t.prototype.getOtherAxis=function(e){return this.getAxis(e.dim==="x"?"y":"x")},t.prototype.getArea=function(e){e=e||0;var i=this.getAxis("x").getGlobalExtent(),n=this.getAxis("y").getGlobalExtent(),a=Math.min(i[0],i[1])-e,o=Math.min(n[0],n[1])-e,s=Math.max(i[0],i[1])-a+e,u=Math.max(n[0],n[1])-o+e;return new et(a,o,s,u)},t})(XA),qA=(function(r){O(t,r);function t(e,i,n,a,o){var s=r.call(this,e,i,n)||this;return s.index=0,s.type=a||"value",s.position=o||"bottom",s}return t.prototype.isHorizontal=function(){var e=this.position;return e==="top"||e==="bottom"},t.prototype.getGlobalExtent=function(e){var i=this.getExtent();return i[0]=this.toGlobalCoord(i[0]),i[1]=this.toGlobalCoord(i[1]),e&&i[0]>i[1]&&i.reverse(),i},t.prototype.pointToData=function(e,i){return this.coordToData(this.toLocalCoord(e[this.dim==="x"?0:1]),i)},t.prototype.setCategorySortInfo=function(e){if(this.type!=="category")return!1;this.model.option.categorySortInfo=e,this.scale.setSortInfo(e)},t})(ZD);function Xf(r,t,e){e=e||{};var i=r.coordinateSystem,n=t.axis,a={},o=n.getAxesOnZeroOf()[0],s=n.position,u=o?"onZero":s,l=n.dim,f=i.getRect(),h=[f.x,f.x+f.width,f.y,f.y+f.height],v={left:0,right:1,top:0,bottom:1,onZero:2},c=t.get("offset")||0,p=l==="x"?[h[2]-c,h[3]+c]:[h[0]-c,h[1]+c];if(o){var d=o.toGlobalCoord(o.dataToCoord(0));p[v.onZero]=Math.max(Math.min(d,p[1]),p[0])}a.position=[l==="y"?p[v[u]]:h[0],l==="x"?p[v[u]]:h[3]],a.rotation=Math.PI/2*(l==="x"?0:1);var g={top:-1,bottom:1,left:-1,right:1};a.labelDirection=a.tickDirection=a.nameDirection=g[s],a.labelOffset=o?p[v[s]]-p[v.onZero]:0,t.get(["axisTick","inside"])&&(a.tickDirection=-a.tickDirection),ke(e.labelInside,t.get(["axisLabel","inside"]))&&(a.labelDirection=-a.labelDirection);var y=t.get(["axisLabel","rotate"]);return a.labelRotate=u==="top"?-y:y,a.z2=1,a}function Ad(r){return r.get("coordinateSystem")==="cartesian2d"}function Ld(r){var t={xAxisModel:null,yAxisModel:null};return T(t,function(e,i){var n=i.replace(/Model$/,""),a=r.getReferringComponents(n,Ut).models[0];t[i]=a}),t}var xl=Math.log;function KA(r,t,e){var i=bn.prototype,n=i.getTicks.call(e),a=i.getTicks.call(e,!0),o=n.length-1,s=i.getInterval.call(e),u=a_(r,t),l=u.extent,f=u.fixMin,h=u.fixMax;if(r.type==="log"){var v=xl(r.base);l=[xl(l[0])/v,xl(l[1])/v]}r.setExtent(l[0],l[1]),r.calcNiceExtent({splitNumber:o,fixMin:f,fixMax:h});var c=i.getExtent.call(r);f&&(l[0]=c[0]),h&&(l[1]=c[1]);var p=i.getInterval.call(r),d=l[0],g=l[1];if(f&&h)p=(g-d)/o;else if(f)for(g=l[0]+p*o;g<l[1]&&isFinite(g)&&isFinite(l[1]);)p=yl(p),g=l[0]+p*o;else if(h)for(d=l[1]-p*o;d>l[0]&&isFinite(d)&&isFinite(l[0]);)p=yl(p),d=l[1]-p*o;else{var y=r.getTicks().length-1;y>o&&(p=yl(p));var m=p*o;g=Math.ceil(l[1]/p)*p,d=xt(g-m),d<0&&l[0]>=0?(d=0,g=xt(m)):g>0&&l[1]<=0&&(g=0,d=-xt(m))}var _=(n[0].value-a[0].value)/s,S=(n[o].value-a[o].value)/s;i.setExtent.call(r,d+p*_,g+p*S),i.setInterval.call(r,p),(_||S)&&i.setNiceExtent.call(r,d+p,g-p)}var QA=(function(){function r(t,e,i){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=Zf,this._initCartesian(t,e,i),this.model=t}return r.prototype.getRect=function(){return this._rect},r.prototype.update=function(t,e){var i=this._axesMap;this._updateScale(t,this.model);function n(o){var s,u=ft(o),l=u.length;if(l){for(var f=[],h=l-1;h>=0;h--){var v=+u[h],c=o[v],p=c.model,d=c.scale;Hf(d)&&p.get("alignTicks")&&p.get("interval")==null?f.push(c):(fd(d,p),Hf(d)&&(s=c))}f.length&&(s||(s=f.pop(),fd(s.scale,s.model)),T(f,function(g){KA(g.scale,g.model,s.scale)}))}}n(i.x),n(i.y);var a={};T(i.x,function(o){Pd(i,"y",o,a)}),T(i.y,function(o){Pd(i,"x",o,a)}),this.resize(this.model,e)},r.prototype.resize=function(t,e,i){var n=t.getBoxLayoutParams(),a=!i&&t.get("containLabel"),o=Gh(n,{width:e.getWidth(),height:e.getHeight()});this._rect=o;var s=this._axesList;u(),a&&(T(s,function(l){if(!l.model.get(["axisLabel","inside"])){var f=RD(l);if(f){var h=l.isHorizontal()?"height":"width",v=l.model.get(["axisLabel","margin"]);o[h]-=f[h]+v,l.position==="top"?o.y+=f.height+v:l.position==="left"&&(o.x+=f.width+v)}}}),u()),T(this._coordsList,function(l){l.calcAffineTransform()});function u(){T(s,function(l){var f=l.isHorizontal(),h=f?[0,o.width]:[0,o.height],v=l.inverse?1:0;l.setExtent(h[v],h[1-v]),JA(l,f?o.x:o.y)})}},r.prototype.getAxis=function(t,e){var i=this._axesMap[t];if(i!=null)return i[e||0]},r.prototype.getAxes=function(){return this._axesList.slice()},r.prototype.getCartesian=function(t,e){if(t!=null&&e!=null){var i="x"+t+"y"+e;return this._coordsMap[i]}W(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var n=0,a=this._coordsList;n<a.length;n++)if(a[n].getAxis("x").index===t||a[n].getAxis("y").index===e)return a[n]},r.prototype.getCartesians=function(){return this._coordsList.slice()},r.prototype.convertToPixel=function(t,e,i){var n=this._findConvertTarget(e);return n.cartesian?n.cartesian.dataToPoint(i):n.axis?n.axis.toGlobalCoord(n.axis.dataToCoord(i)):null},r.prototype.convertFromPixel=function(t,e,i){var n=this._findConvertTarget(e);return n.cartesian?n.cartesian.pointToData(i):n.axis?n.axis.coordToData(n.axis.toLocalCoord(i)):null},r.prototype._findConvertTarget=function(t){var e=t.seriesModel,i=t.xAxisModel||e&&e.getReferringComponents("xAxis",Ut).models[0],n=t.yAxisModel||e&&e.getReferringComponents("yAxis",Ut).models[0],a=t.gridModel,o=this._coordsList,s,u;if(e)s=e.coordinateSystem,Q(o,s)<0&&(s=null);else if(i&&n)s=this.getCartesian(i.componentIndex,n.componentIndex);else if(i)u=this.getAxis("x",i.componentIndex);else if(n)u=this.getAxis("y",n.componentIndex);else if(a){var l=a.coordinateSystem;l===this&&(s=this._coordsList[0])}return{cartesian:s,axis:u}},r.prototype.containPoint=function(t){var e=this._coordsList[0];if(e)return e.containPoint(t)},r.prototype._initCartesian=function(t,e,i){var n=this,a=this,o={left:!1,right:!1,top:!1,bottom:!1},s={x:{},y:{}},u={x:0,y:0};if(e.eachComponent("xAxis",l("x"),this),e.eachComponent("yAxis",l("y"),this),!u.x||!u.y){this._axesMap={},this._axesList=[];return}this._axesMap=s,T(s.x,function(f,h){T(s.y,function(v,c){var p="x"+h+"y"+c,d=new $A(p);d.master=n,d.model=t,n._coordsMap[p]=d,n._coordsList.push(d),d.addAxis(f),d.addAxis(v)})});function l(f){return function(h,v){if(Tl(h,t)){var c=h.get("position");f==="x"?c!=="top"&&c!=="bottom"&&(c=o.bottom?"top":"bottom"):c!=="left"&&c!=="right"&&(c=o.left?"right":"left"),o[c]=!0;var p=new qA(f,PD(h),[0,0],h.get("type"),c),d=p.type==="category";p.onBand=d&&h.get("boundaryGap"),p.inverse=h.get("inverse"),h.axis=p,p.model=h,p.grid=a,p.index=v,a._axesList.push(p),s[f][v]=p,u[f]++}}}},r.prototype._updateScale=function(t,e){T(this._axesList,function(n){if(n.scale.setExtent(1/0,-1/0),n.type==="category"){var a=n.model.get("categorySortInfo");n.scale.setSortInfo(a)}}),t.eachSeries(function(n){if(Ad(n)){var a=Ld(n),o=a.xAxisModel,s=a.yAxisModel;if(!Tl(o,e)||!Tl(s,e))return;var u=this.getCartesian(o.componentIndex,s.componentIndex),l=n.getData(),f=u.getAxis("x"),h=u.getAxis("y");i(l,f),i(l,h)}},this);function i(n,a){T(s_(n,a.dim),function(o){a.scale.unionExtentFromData(n,o)})}},r.prototype.getTooltipAxes=function(t){var e=[],i=[];return T(this.getCartesians(),function(n){var a=t!=null&&t!=="auto"?n.getAxis(t):n.getBaseAxis(),o=n.getOtherAxis(a);Q(e,a)<0&&e.push(a),Q(i,o)<0&&i.push(o)}),{baseAxes:e,otherAxes:i}},r.create=function(t,e){var i=[];return t.eachComponent("grid",function(n,a){var o=new r(n,t,e);o.name="grid_"+a,o.resize(n,e,!0),n.coordinateSystem=o,i.push(o)}),t.eachSeries(function(n){if(Ad(n)){var a=Ld(n),o=a.xAxisModel,s=a.yAxisModel,u=o.getCoordSysModel(),l=u.coordinateSystem;n.coordinateSystem=l.getCartesian(o.componentIndex,s.componentIndex)}}),i},r.dimensions=Zf,r})();function Tl(r,t){return r.getCoordSysModel()===t}function Pd(r,t,e,i){e.getAxesOnZeroOf=function(){return a?[a]:[]};var n=r[t],a,o=e.model,s=o.get(["axisLine","onZero"]),u=o.get(["axisLine","onZeroAxisIndex"]);if(!s)return;if(u!=null)Id(n[u])&&(a=n[u]);else for(var l in n)if(n.hasOwnProperty(l)&&Id(n[l])&&!i[f(n[l])]){a=n[l];break}a&&(i[f(a)]=!0);function f(h){return h.dim+"_"+h.index}}function Id(r){return r&&r.type!=="category"&&r.type!=="time"&&ID(r)}function JA(r,t){var e=r.getExtent(),i=e[0]+e[1];r.toGlobalCoord=r.dim==="x"?function(n){return n+t}:function(n){return i-n+t},r.toLocalCoord=r.dim==="x"?function(n){return n-t}:function(n){return i-n+t}}var Sr=Math.PI,Dr=(function(){function r(t,e){this.group=new gt,this.opt=e,this.axisModel=t,rt(e,{labelOffset:0,nameDirection:1,tickDirection:1,labelDirection:1,silent:!0,handleAutoShown:function(){return!0}});var i=new gt({x:e.position[0],y:e.position[1],rotation:e.rotation});i.updateTransform(),this._transformGroup=i}return r.prototype.hasBuilder=function(t){return!!Rd[t]},r.prototype.add=function(t){Rd[t](this.opt,this.axisModel,this.group,this._transformGroup)},r.prototype.getGroup=function(){return this.group},r.innerTextLayout=function(t,e,i){var n=Py(e-t),a,o;return jo(n)?(o=i>0?"top":"bottom",a="center"):jo(n-Sr)?(o=i>0?"bottom":"top",a="center"):(o="middle",n>0&&n<Sr?a=i>0?"right":"left":a=i>0?"left":"right"),{rotation:n,textAlign:a,textVerticalAlign:o}},r.makeAxisEventDataBase=function(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e},r.isLabelSilent=function(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)},r})(),Rd={axisLine:function(r,t,e,i){var n=t.get(["axisLine","show"]);if(n==="auto"&&r.handleAutoShown&&(n=r.handleAutoShown("axisLine")),!!n){var a=t.axis.getExtent(),o=i.transform,s=[a[0],0],u=[a[1],0],l=s[0]>u[0];o&&(ve(s,s,o),ve(u,u,o));var f=k({lineCap:"round"},t.getModel(["axisLine","lineStyle"]).getLineStyle()),h=new er({shape:{x1:s[0],y1:s[1],x2:u[0],y2:u[1]},style:f,strokeContainThreshold:r.strokeContainThreshold||5,silent:!0,z2:1});Ta(h.shape,h.style.lineWidth),h.anid="line",e.add(h);var v=t.get(["axisLine","symbol"]);if(v!=null){var c=t.get(["axisLine","symbolSize"]);H(v)&&(v=[v,v]),(H(c)||dt(c))&&(c=[c,c]);var p=ru(t.get(["axisLine","symbolOffset"])||0,c),d=c[0],g=c[1];T([{rotate:r.rotation+Math.PI/2,offset:p[0],r:0},{rotate:r.rotation-Math.PI/2,offset:p[1],r:Math.sqrt((s[0]-u[0])*(s[0]-u[0])+(s[1]-u[1])*(s[1]-u[1]))}],function(y,m){if(v[m]!=="none"&&v[m]!=null){var _=ir(v[m],-d/2,-g/2,d,g,f.stroke,!0),S=y.r+y.offset,b=l?u:s;_.attr({rotation:y.rotate,x:b[0]+S*Math.cos(r.rotation),y:b[1]-S*Math.sin(r.rotation),silent:!0,z2:11}),e.add(_)}})}}},axisTickLabel:function(r,t,e,i){var n=eL(e,i,t,r),a=iL(e,i,t,r);if(tL(t,a,n),rL(e,i,t,r.tickDirection),t.get(["axisLabel","hideOverlap"])){var o=g_(z(a,function(s){return{label:s,priority:s.z2,defaultAttr:{ignore:s.ignore}}}));m_(o)}},axisName:function(r,t,e,i){var n=ke(r.axisName,t.get("name"));if(n){var a=t.get("nameLocation"),o=r.nameDirection,s=t.getModel("nameTextStyle"),u=t.get("nameGap")||0,l=t.axis.getExtent(),f=l[0]>l[1]?-1:1,h=[a==="start"?l[0]-f*u:a==="end"?l[1]+f*u:(l[0]+l[1])/2,kd(a)?r.labelOffset+o*u:0],v,c=t.get("nameRotate");c!=null&&(c=c*Sr/180);var p;kd(a)?v=Dr.innerTextLayout(r.rotation,c??r.rotation,o):(v=jA(r.rotation,a,c||0,l),p=r.axisNameAvailableWidth,p!=null&&(p=Math.abs(p/Math.sin(v.rotation)),!isFinite(p)&&(p=null)));var d=s.getFont(),g=t.get("nameTruncate",!0)||{},y=g.ellipsis,m=ke(r.nameTruncateMaxWidth,g.maxWidth,p),_=new te({x:h[0],y:h[1],rotation:v.rotation,silent:Dr.isLabelSilent(t),style:Lr(s,{text:n,font:d,overflow:"truncate",width:m,ellipsis:y,fill:s.getTextColor()||t.get(["axisLine","lineStyle","color"]),align:s.get("align")||v.textAlign,verticalAlign:s.get("verticalAlign")||v.textVerticalAlign}),z2:1});if(Oh({el:_,componentModel:t,itemName:n}),_.__fullText=n,_.anid="name",t.get("triggerEvent")){var S=Dr.makeAxisEventDataBase(t);S.targetType="axisName",S.name=n,at(_).eventData=S}i.add(_),_.updateTransform(),e.add(_),_.decomposeTransform()}}};function jA(r,t,e,i){var n=Py(e-r),a,o,s=i[0]>i[1],u=t==="start"&&!s||t!=="start"&&s;return jo(n-Sr/2)?(o=u?"bottom":"top",a="center"):jo(n-Sr*1.5)?(o=u?"top":"bottom",a="center"):(o="middle",n<Sr*1.5&&n>Sr/2?a=u?"left":"right":a=u?"right":"left"),{rotation:n,textAlign:a,textVerticalAlign:o}}function tL(r,t,e){if(!o_(r.axis)){var i=r.get(["axisLabel","showMinLabel"]),n=r.get(["axisLabel","showMaxLabel"]);t=t||[],e=e||[];var a=t[0],o=t[1],s=t[t.length-1],u=t[t.length-2],l=e[0],f=e[1],h=e[e.length-1],v=e[e.length-2];i===!1?(re(a),re(l)):Ed(a,o)&&(i?(re(o),re(f)):(re(a),re(l))),n===!1?(re(s),re(h)):Ed(u,s)&&(n?(re(u),re(v)):(re(s),re(h)))}}function re(r){r&&(r.ignore=!0)}function Ed(r,t){var e=r&&r.getBoundingRect().clone(),i=t&&t.getBoundingRect().clone();if(!(!e||!i)){var n=yh([]);return mh(n,n,-r.rotation),e.applyTransform(en([],n,r.getLocalTransform())),i.applyTransform(en([],n,t.getLocalTransform())),e.intersect(i)}}function kd(r){return r==="middle"||r==="center"}function A_(r,t,e,i,n){for(var a=[],o=[],s=[],u=0;u<r.length;u++){var l=r[u].coord;o[0]=l,o[1]=0,s[0]=l,s[1]=e,t&&(ve(o,o,t),ve(s,s,t));var f=new er({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:i,z2:2,autoBatch:!0,silent:!0});Ta(f.shape,f.style.lineWidth),f.anid=n+"_"+r[u].tickValue,a.push(f)}return a}function eL(r,t,e,i){var n=e.axis,a=e.getModel("axisTick"),o=a.get("show");if(o==="auto"&&i.handleAutoShown&&(o=i.handleAutoShown("axisTick")),!(!o||n.scale.isBlank())){for(var s=a.getModel("lineStyle"),u=i.tickDirection*a.get("length"),l=n.getTicksCoords(),f=A_(l,t.transform,u,rt(s.getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])}),"ticks"),h=0;h<f.length;h++)r.add(f[h]);return f}}function rL(r,t,e,i){var n=e.axis,a=e.getModel("minorTick");if(!(!a.get("show")||n.scale.isBlank())){var o=n.getMinorTicksCoords();if(o.length)for(var s=a.getModel("lineStyle"),u=i*a.get("length"),l=rt(s.getLineStyle(),rt(e.getModel("axisTick").getLineStyle(),{stroke:e.get(["axisLine","lineStyle","color"])})),f=0;f<o.length;f++)for(var h=A_(o[f],t.transform,u,l,"minorticks_"+f),v=0;v<h.length;v++)r.add(h[v])}}function iL(r,t,e,i){var n=e.axis,a=ke(i.axisLabelShow,e.get(["axisLabel","show"]));if(!(!a||n.scale.isBlank())){var o=e.getModel("axisLabel"),s=o.get("margin"),u=n.getViewLabels(),l=(ke(i.labelRotate,o.get("rotate"))||0)*Sr/180,f=Dr.innerTextLayout(i.rotation,l,i.labelDirection),h=e.getCategories&&e.getCategories(!0),v=[],c=Dr.isLabelSilent(e),p=e.get("triggerEvent");return T(u,function(d,g){var y=n.scale.type==="ordinal"?n.scale.getRawOrdinalNumber(d.tickValue):d.tickValue,m=d.formattedLabel,_=d.rawLabel,S=o;if(h&&h[y]){var b=h[y];W(b)&&b.textStyle&&(S=new St(b.textStyle,o,e.ecModel))}var w=S.getTextColor()||e.get(["axisLine","lineStyle","color"]),x=n.dataToCoord(y),C=S.getShallow("align",!0)||f.textAlign,M=$(S.getShallow("alignMinLabel",!0),C),D=$(S.getShallow("alignMaxLabel",!0),C),A=S.getShallow("verticalAlign",!0)||S.getShallow("baseline",!0)||f.textVerticalAlign,P=$(S.getShallow("verticalAlignMinLabel",!0),A),R=$(S.getShallow("verticalAlignMaxLabel",!0),A),L=new te({x,y:i.labelOffset+i.labelDirection*s,rotation:f.rotation,silent:c,z2:10+(d.level||0),style:Lr(S,{text:m,align:g===0?M:g===u.length-1?D:C,verticalAlign:g===0?P:g===u.length-1?R:A,fill:q(w)?w(n.type==="category"?_:n.type==="value"?y+"":y,g):w})});if(L.anid="label_"+y,Oh({el:L,componentModel:e,itemName:m,formatterParamsExtra:{isTruncated:function(){return L.isTruncated},value:_,tickIndex:g}}),p){var I=Dr.makeAxisEventDataBase(e);I.targetType="axisLabel",I.value=_,I.tickIndex=g,n.type==="category"&&(I.dataIndex=y),at(L).eventData=I}t.add(L),L.updateTransform(),v.push(L),r.add(L),L.decomposeTransform()}),v}}function nL(r,t){var e={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return aL(e,r,t),e.seriesInvolved&&sL(e,r),e}function aL(r,t,e){var i=t.getComponent("tooltip"),n=t.getComponent("axisPointer"),a=n.get("link",!0)||[],o=[];T(e.getCoordinateSystems(),function(s){if(!s.axisPointerEnabled)return;var u=Ea(s.model),l=r.coordSysAxesInfo[u]={};r.coordSysMap[u]=s;var f=s.model,h=f.getModel("tooltip",i);if(T(s.getAxes(),ot(d,!1,null)),s.getTooltipAxes&&i&&h.get("show")){var v=h.get("trigger")==="axis",c=h.get(["axisPointer","type"])==="cross",p=s.getTooltipAxes(h.get(["axisPointer","axis"]));(v||c)&&T(p.baseAxes,ot(d,c?"cross":!0,v)),c&&T(p.otherAxes,ot(d,"cross",!1))}function d(g,y,m){var _=m.model.getModel("axisPointer",n),S=_.get("show");if(!(!S||S==="auto"&&!g&&!$f(_))){y==null&&(y=_.get("triggerTooltip")),_=g?oL(m,h,n,t,g,y):_;var b=_.get("snap"),w=_.get("triggerEmphasis"),x=Ea(m.model),C=y||b||m.type==="category",M=r.axesInfo[x]={key:x,axis:m,coordSys:s,axisPointerModel:_,triggerTooltip:y,triggerEmphasis:w,involveSeries:C,snap:b,useHandle:$f(_),seriesModels:[],linkGroup:null};l[x]=M,r.seriesInvolved=r.seriesInvolved||C;var D=uL(a,m);if(D!=null){var A=o[D]||(o[D]={axesInfo:{}});A.axesInfo[x]=M,A.mapper=a[D].mapper,M.linkGroup=A}}}})}function oL(r,t,e,i,n,a){var o=t.getModel("axisPointer"),s=["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],u={};T(s,function(v){u[v]=Y(o.get(v))}),u.snap=r.type!=="category"&&!!a,o.get("type")==="cross"&&(u.type="line");var l=u.label||(u.label={});if(l.show==null&&(l.show=!1),n==="cross"){var f=o.get(["label","show"]);if(l.show=f??!0,!a){var h=u.lineStyle=o.get("crossStyle");h&&rt(l,h.textStyle)}}return r.model.getModel("axisPointer",new St(u,e,i))}function sL(r,t){t.eachSeries(function(e){var i=e.coordinateSystem,n=e.get(["tooltip","trigger"],!0),a=e.get(["tooltip","show"],!0);!i||n==="none"||n===!1||n==="item"||a===!1||e.get(["axisPointer","show"],!0)===!1||T(r.coordSysAxesInfo[Ea(i.model)],function(o){var s=o.axis;i.getAxis(s.dim)===s&&(o.seriesModels.push(e),o.seriesDataCount==null&&(o.seriesDataCount=0),o.seriesDataCount+=e.getData().count())})})}function uL(r,t){for(var e=t.model,i=t.dim,n=0;n<r.length;n++){var a=r[n]||{};if(Ml(a[i+"AxisId"],e.id)||Ml(a[i+"AxisIndex"],e.componentIndex)||Ml(a[i+"AxisName"],e.name))return n}}function Ml(r,t){return r==="all"||B(r)&&Q(r,t)>=0||r===t}function lL(r){var t=vv(r);if(t){var e=t.axisPointerModel,i=t.axis.scale,n=e.option,a=e.get("status"),o=e.get("value");o!=null&&(o=i.parse(o));var s=$f(e);a==null&&(n.status=s?"show":"hide");var u=i.getExtent().slice();u[0]>u[1]&&u.reverse(),(o==null||o>u[1])&&(o=u[1]),o<u[0]&&(o=u[0]),n.value=o,s&&(n.status=t.axis.scale.isBlank()?"hide":"show")}}function vv(r){var t=(r.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return t&&t.axesInfo[Ea(r)]}function fL(r){var t=vv(r);return t&&t.axisPointerModel}function $f(r){return!!r.get(["handle","show"])}function Ea(r){return r.type+"||"+r.id}var Od={},L_=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n,a){this.axisPointerClass&&lL(e),r.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(e,n,!0)},t.prototype.updateAxisPointer=function(e,i,n,a){this._doUpdateAxisPointerClass(e,n,!1)},t.prototype.remove=function(e,i){var n=this._axisPointer;n&&n.remove(i)},t.prototype.dispose=function(e,i){this._disposeAxisPointer(i),r.prototype.dispose.apply(this,arguments)},t.prototype._doUpdateAxisPointerClass=function(e,i,n){var a=t.getAxisPointerClass(this.axisPointerClass);if(a){var o=fL(e);o?(this._axisPointer||(this._axisPointer=new a)).render(e,o,i,n):this._disposeAxisPointer(i)}},t.prototype._disposeAxisPointer=function(e){this._axisPointer&&this._axisPointer.dispose(e),this._axisPointer=null},t.registerAxisPointerClass=function(e,i){Od[e]=i},t.getAxisPointerClass=function(e){return e&&Od[e]},t.type="axis",t})($t),qf=vt();function hL(r,t,e,i){var n=e.axis;if(!n.scale.isBlank()){var a=e.getModel("splitArea"),o=a.getModel("areaStyle"),s=o.get("color"),u=i.coordinateSystem.getRect(),l=n.getTicksCoords({tickModel:a,clamp:!0});if(l.length){var f=s.length,h=qf(r).splitAreaColors,v=X(),c=0;if(h)for(var p=0;p<l.length;p++){var d=h.get(l[p].tickValue);if(d!=null){c=(d+(f-1)*p)%f;break}}var g=n.toGlobalCoord(l[0].coord),y=o.getAreaStyle();s=B(s)?s:[s];for(var p=1;p<l.length;p++){var m=n.toGlobalCoord(l[p].coord),_=void 0,S=void 0,b=void 0,w=void 0;n.isHorizontal()?(_=g,S=u.y,b=m-_,w=u.height,g=_+b):(_=u.x,S=g,b=u.width,w=m-S,g=S+w);var x=l[p-1].tickValue;x!=null&&v.set(x,c),t.add(new Tt({anid:x!=null?"area_"+x:null,shape:{x:_,y:S,width:b,height:w},style:rt({fill:s[c]},y),autoBatch:!0,silent:!0})),c=(c+1)%f}qf(r).splitAreaColors=v}}}function vL(r){qf(r).splitAreaColors=null}var cL=["axisLine","axisTickLabel","axisName"],pL=["splitArea","splitLine","minorSplitLine"],P_=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.axisPointerClass="CartesianAxisPointer",e}return t.prototype.render=function(e,i,n,a){this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new gt,this.group.add(this._axisGroup),!!e.get("show")){var s=e.getCoordSysModel(),u=Xf(s,e),l=new Dr(e,k({handleAutoShown:function(h){for(var v=s.coordinateSystem.getCartesians(),c=0;c<v.length;c++)if(Hf(v[c].getOtherAxis(e.axis).scale))return!0;return!1}},u));T(cL,l.add,l),this._axisGroup.add(l.getGroup()),T(pL,function(h){e.get([h,"show"])&&dL[h](this,this._axisGroup,e,s)},this);var f=a&&a.type==="changeAxisOrder"&&a.isInitSort;f||mm(o,this._axisGroup,e),r.prototype.render.call(this,e,i,n,a)}},t.prototype.remove=function(){vL(this)},t.type="cartesianAxis",t})(L_),dL={splitLine:function(r,t,e,i){var n=e.axis;if(!n.scale.isBlank()){var a=e.getModel("splitLine"),o=a.getModel("lineStyle"),s=o.get("color"),u=a.get("showMinLine")!==!1,l=a.get("showMaxLine")!==!1;s=B(s)?s:[s];for(var f=i.coordinateSystem.getRect(),h=n.isHorizontal(),v=0,c=n.getTicksCoords({tickModel:a}),p=[],d=[],g=o.getLineStyle(),y=0;y<c.length;y++){var m=n.toGlobalCoord(c[y].coord);if(!(y===0&&!u||y===c.length-1&&!l)){var _=c[y].tickValue;h?(p[0]=m,p[1]=f.y,d[0]=m,d[1]=f.y+f.height):(p[0]=f.x,p[1]=m,d[0]=f.x+f.width,d[1]=m);var S=v++%s.length,b=new er({anid:_!=null?"line_"+_:null,autoBatch:!0,shape:{x1:p[0],y1:p[1],x2:d[0],y2:d[1]},style:rt({stroke:s[S]},g),silent:!0});Ta(b.shape,g.lineWidth),t.add(b)}}}},minorSplitLine:function(r,t,e,i){var n=e.axis,a=e.getModel("minorSplitLine"),o=a.getModel("lineStyle"),s=i.coordinateSystem.getRect(),u=n.isHorizontal(),l=n.getMinorTicksCoords();if(l.length)for(var f=[],h=[],v=o.getLineStyle(),c=0;c<l.length;c++)for(var p=0;p<l[c].length;p++){var d=n.toGlobalCoord(l[c][p].coord);u?(f[0]=d,f[1]=s.y,h[0]=d,h[1]=s.y+s.height):(f[0]=s.x,f[1]=d,h[0]=s.x+s.width,h[1]=d);var g=new er({anid:"minor_line_"+l[c][p].tickValue,autoBatch:!0,shape:{x1:f[0],y1:f[1],x2:h[0],y2:h[1]},style:v,silent:!0});Ta(g.shape,v.lineWidth),t.add(g)}},splitArea:function(r,t,e,i){hL(r,t,e,i)}},I_=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="xAxis",t})(P_),gL=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=I_.type,e}return t.type="yAxis",t})(P_),yL=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="grid",e}return t.prototype.render=function(e,i){this.group.removeAll(),e.get("show")&&this.group.add(new Tt({shape:e.coordinateSystem.getRect(),style:rt({fill:e.get("backgroundColor")},e.getItemStyle()),silent:!0,z2:-1}))},t.type="grid",t})($t),Bd={offset:0};function R_(r){r.registerComponentView(yL),r.registerComponentModel(HA),r.registerCoordinateSystem("cartesian2d",QA),Md(r,"x",Yf,Bd),Md(r,"y",Yf,Bd),r.registerComponentView(I_),r.registerComponentView(gL),r.registerPreprocessor(function(t){t.xAxis&&t.yAxis&&!t.grid&&(t.grid={})})}function mL(r){Pr(R_),r.registerSeriesModel(BA),r.registerChartView(VA),r.registerLayout(fv("scatter"))}var Nd="\0_ec_interaction_mutex";function _L(r,t,e){var i=cv(r);i[t]=e}function SL(r,t,e){var i=cv(r),n=i[t];n===e&&(i[t]=null)}function Fd(r,t){return!!cv(r)[t]}function cv(r){return r[Nd]||(r[Nd]={})}Ci({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},At);var wL=(function(r){O(t,r);function t(e){var i=r.call(this)||this;i._zr=e;var n=U(i._mousedownHandler,i),a=U(i._mousemoveHandler,i),o=U(i._mouseupHandler,i),s=U(i._mousewheelHandler,i),u=U(i._pinchHandler,i);return i.enable=function(l,f){this.disable(),this._opt=rt(Y(f)||{},{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),l==null&&(l=!0),(l===!0||l==="move"||l==="pan")&&(e.on("mousedown",n),e.on("mousemove",a),e.on("mouseup",o)),(l===!0||l==="scale"||l==="zoom")&&(e.on("mousewheel",s),e.on("pinch",u))},i.disable=function(){e.off("mousedown",n),e.off("mousemove",a),e.off("mouseup",o),e.off("mousewheel",s),e.off("pinch",u)},i}return t.prototype.isDragging=function(){return this._dragging},t.prototype.isPinching=function(){return this._pinching},t.prototype.setPointerChecker=function(e){this.pointerChecker=e},t.prototype.dispose=function(){this.disable()},t.prototype._mousedownHandler=function(e){if(!zv(e)){for(var i=e.target;i;){if(i.draggable)return;i=i.__hostTarget||i.parent}var n=e.offsetX,a=e.offsetY;this.pointerChecker&&this.pointerChecker(e,n,a)&&(this._x=n,this._y=a,this._dragging=!0)}},t.prototype._mousemoveHandler=function(e){if(!(!this._dragging||!Wo("moveOnMouseMove",e,this._opt)||e.gestureEvent==="pinch"||Fd(this._zr,"globalPan"))){var i=e.offsetX,n=e.offsetY,a=this._x,o=this._y,s=i-a,u=n-o;this._x=i,this._y=n,this._opt.preventDefaultMouseMove&&hn(e.event),E_(this,"pan","moveOnMouseMove",e,{dx:s,dy:u,oldX:a,oldY:o,newX:i,newY:n,isAvailableBehavior:null})}},t.prototype._mouseupHandler=function(e){zv(e)||(this._dragging=!1)},t.prototype._mousewheelHandler=function(e){var i=Wo("zoomOnMouseWheel",e,this._opt),n=Wo("moveOnMouseWheel",e,this._opt),a=e.wheelDelta,o=Math.abs(a),s=e.offsetX,u=e.offsetY;if(!(a===0||!i&&!n)){if(i){var l=o>3?1.4:o>1?1.2:1.1,f=a>0?l:1/l;Cl(this,"zoom","zoomOnMouseWheel",e,{scale:f,originX:s,originY:u,isAvailableBehavior:null})}if(n){var h=Math.abs(a),v=(a>0?1:-1)*(h>3?.4:h>1?.15:.05);Cl(this,"scrollMove","moveOnMouseWheel",e,{scrollDelta:v,originX:s,originY:u,isAvailableBehavior:null})}}},t.prototype._pinchHandler=function(e){if(!Fd(this._zr,"globalPan")){var i=e.pinchScale>1?1.1:1/1.1;Cl(this,"zoom",null,e,{scale:i,originX:e.pinchX,originY:e.pinchY,isAvailableBehavior:null})}},t})(de);function Cl(r,t,e,i,n){r.pointerChecker&&r.pointerChecker(i,n.originX,n.originY)&&(hn(i.event),E_(r,t,e,i,n))}function E_(r,t,e,i,n){n.isAvailableBehavior=U(Wo,null,e,i),r.trigger(t,n)}function Wo(r,t,e){var i=e[r];return!r||i&&(!H(i)||t.event[i+"Key"])}var bL={axisPointer:1,tooltip:1,brush:1};function xL(r,t,e){var i=t.getComponentByElement(r.topTarget),n=i&&i.coordinateSystem;return i&&i!==e&&!bL.hasOwnProperty(i.mainType)&&n&&n.model!==e}var ka=T,TL=W,ms=-1,ln=(function(){function r(t){var e=t.mappingMethod,i=t.type,n=this.option=Y(t);this.type=i,this.mappingMethod=e,this._normalizeData=DL[e];var a=r.visualHandlers[i];this.applyVisual=a.applyVisual,this.getColorMapper=a.getColorMapper,this._normalizedToVisual=a._normalizedToVisual[e],e==="piecewise"?(Dl(n),ML(n)):e==="category"?n.categories?CL(n):Dl(n,!0):(ze(e!=="linear"||n.dataExtent),Dl(n))}return r.prototype.mapValueToVisual=function(t){var e=this._normalizeData(t);return this._normalizedToVisual(e,t)},r.prototype.getNormalizer=function(){return U(this._normalizeData,this)},r.listVisualTypes=function(){return ft(r.visualHandlers)},r.isValidType=function(t){return r.visualHandlers.hasOwnProperty(t)},r.eachVisual=function(t,e,i){W(t)?T(t,e,i):e.call(i,t)},r.mapVisual=function(t,e,i){var n,a=B(t)?[]:W(t)?{}:(n=!0,null);return r.eachVisual(t,function(o,s){var u=e.call(i,o,s);n?a=u:a[s]=u}),a},r.retrieveVisuals=function(t){var e={},i;return t&&ka(r.visualHandlers,function(n,a){t.hasOwnProperty(a)&&(e[a]=t[a],i=!0)}),i?e:null},r.prepareVisualTypes=function(t){if(B(t))t=t.slice();else if(TL(t)){var e=[];ka(t,function(i,n){e.push(n)}),t=e}else return[];return t.sort(function(i,n){return n==="color"&&i!=="color"&&i.indexOf("color")===0?1:-1}),t},r.dependsOn=function(t,e){return e==="color"?!!(t&&t.indexOf(e)===0):t===e},r.findPieceIndex=function(t,e,i){for(var n,a=1/0,o=0,s=e.length;o<s;o++){var u=e[o].value;if(u!=null){if(u===t||H(u)&&u===t+"")return o;i&&v(u,o)}}for(var o=0,s=e.length;o<s;o++){var l=e[o],f=l.interval,h=l.close;if(f){if(f[0]===-1/0){if(Mo(h[1],t,f[1]))return o}else if(f[1]===1/0){if(Mo(h[0],f[0],t))return o}else if(Mo(h[0],f[0],t)&&Mo(h[1],t,f[1]))return o;i&&v(f[0],o),i&&v(f[1],o)}}if(i)return t===1/0?e.length-1:t===-1/0?0:n;function v(c,p){var d=Math.abs(c-t);d<a&&(a=d,n=p)}},r.visualHandlers={color:{applyVisual:Yn("color"),getColorMapper:function(){var t=this.option;return U(t.mappingMethod==="category"?function(e,i){return!i&&(e=this._normalizeData(e)),na.call(this,e)}:function(e,i,n){var a=!!n;return!i&&(e=this._normalizeData(e)),n=wu(e,t.parsedVisual,n),a?n:Tr(n,"rgba")},this)},_normalizedToVisual:{linear:function(t){return Tr(wu(t,this.option.parsedVisual),"rgba")},category:na,piecewise:function(t,e){var i=Qf.call(this,e);return i==null&&(i=Tr(wu(t,this.option.parsedVisual),"rgba")),i},fixed:ni}},colorHue:To(function(t,e){return bu(t,e)}),colorSaturation:To(function(t,e){return bu(t,null,e)}),colorLightness:To(function(t,e){return bu(t,null,null,e)}),colorAlpha:To(function(t,e){return of(t,e)}),decal:{applyVisual:Yn("decal"),_normalizedToVisual:{linear:null,category:na,piecewise:null,fixed:null}},opacity:{applyVisual:Yn("opacity"),_normalizedToVisual:Kf([0,1])},liftZ:{applyVisual:Yn("liftZ"),_normalizedToVisual:{linear:ni,category:ni,piecewise:ni,fixed:ni}},symbol:{applyVisual:function(t,e,i){var n=this.mapValueToVisual(t);i("symbol",n)},_normalizedToVisual:{linear:zd,category:na,piecewise:function(t,e){var i=Qf.call(this,e);return i==null&&(i=zd.call(this,t)),i},fixed:ni}},symbolSize:{applyVisual:Yn("symbolSize"),_normalizedToVisual:Kf([0,1])}},r})();function ML(r){var t=r.pieceList;r.hasSpecialVisual=!1,T(t,function(e,i){e.originIndex=i,e.visual!=null&&(r.hasSpecialVisual=!0)})}function CL(r){var t=r.categories,e=r.categoryMap={},i=r.visual;if(ka(t,function(o,s){e[o]=s}),!B(i)){var n=[];W(i)?ka(i,function(o,s){var u=e[s];n[u??ms]=o}):n[ms]=i,i=k_(r,n)}for(var a=t.length-1;a>=0;a--)i[a]==null&&(delete e[t[a]],t.pop())}function Dl(r,t){var e=r.visual,i=[];W(e)?ka(e,function(a){i.push(a)}):e!=null&&i.push(e);var n={color:1,symbol:1};!t&&i.length===1&&!n.hasOwnProperty(r.type)&&(i[1]=i[0]),k_(r,i)}function To(r){return{applyVisual:function(t,e,i){var n=this.mapValueToVisual(t);i("color",r(e("color"),n))},_normalizedToVisual:Kf([0,1])}}function zd(r){var t=this.option.visual;return t[Math.round(bt(r,[0,1],[0,t.length-1],!0))]||{}}function Yn(r){return function(t,e,i){i(r,this.mapValueToVisual(t))}}function na(r){var t=this.option.visual;return t[this.option.loop&&r!==ms?r%t.length:r]}function ni(){return this.option.visual[0]}function Kf(r){return{linear:function(t){return bt(t,r,this.option.visual,!0)},category:na,piecewise:function(t,e){var i=Qf.call(this,e);return i==null&&(i=bt(t,r,this.option.visual,!0)),i},fixed:ni}}function Qf(r){var t=this.option,e=t.pieceList;if(t.hasSpecialVisual){var i=ln.findPieceIndex(r,e),n=e[i];if(n&&n.visual)return n.visual[this.type]}}function k_(r,t){return r.visual=t,r.type==="color"&&(r.parsedVisual=z(t,function(e){var i=Me(e);return i||[0,0,0,1]})),t}var DL={linear:function(r){return bt(r,this.option.dataExtent,[0,1],!0)},piecewise:function(r){var t=this.option.pieceList,e=ln.findPieceIndex(r,t,!0);if(e!=null)return bt(e,[0,t.length-1],[0,1],!0)},category:function(r){var t=this.option.categories?this.option.categoryMap[r]:r;return t??ms},fixed:At};function Mo(r,t,e){return r?t<=e:t<e}var Vd=er.prototype,Al=Vs.prototype,O_=(function(){function r(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return r})();(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t})(O_);function Ll(r){return isNaN(+r.cpx1)||isNaN(+r.cpy1)}var AL=(function(r){O(t,r);function t(e){var i=r.call(this,e)||this;return i.type="ec-line",i}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new O_},t.prototype.buildPath=function(e,i){Ll(i)?Vd.buildPath.call(this,e,i):Al.buildPath.call(this,e,i)},t.prototype.pointAt=function(e){return Ll(this.shape)?Vd.pointAt.call(this,e):Al.pointAt.call(this,e)},t.prototype.tangentAt=function(e){var i=this.shape,n=Ll(i)?[i.x2-i.x1,i.y2-i.y1]:Al.tangentAt.call(this,e);return dh(n,n)},t})(st),Pl=["fromSymbol","toSymbol"];function Hd(r){return"_"+r+"Type"}function Gd(r,t,e){var i=t.getItemVisual(e,r);if(!i||i==="none")return i;var n=t.getItemVisual(e,r+"Size"),a=t.getItemVisual(e,r+"Rotate"),o=t.getItemVisual(e,r+"Offset"),s=t.getItemVisual(e,r+"KeepAspect"),u=Qh(n),l=ru(o||0,u);return i+u+l+(a||"")+(s||"")}function Wd(r,t,e){var i=t.getItemVisual(e,r);if(!(!i||i==="none")){var n=t.getItemVisual(e,r+"Size"),a=t.getItemVisual(e,r+"Rotate"),o=t.getItemVisual(e,r+"Offset"),s=t.getItemVisual(e,r+"KeepAspect"),u=Qh(n),l=ru(o||0,u),f=ir(i,-u[0]/2+l[0],-u[1]/2+l[1],u[0],u[1],null,s);return f.__specifiedRotation=a==null||isNaN(a)?void 0:+a*Math.PI/180||0,f.name=r,f}}function LL(r){var t=new AL({name:"line",subPixelOptimize:!0});return Jf(t.shape,r),t}function Jf(r,t){r.x1=t[0][0],r.y1=t[0][1],r.x2=t[1][0],r.y2=t[1][1],r.percent=1;var e=t[2];e?(r.cpx1=e[0],r.cpy1=e[1]):(r.cpx1=NaN,r.cpy1=NaN)}var PL=(function(r){O(t,r);function t(e,i,n){var a=r.call(this)||this;return a._createLine(e,i,n),a}return t.prototype._createLine=function(e,i,n){var a=e.hostModel,o=e.getItemLayout(i),s=LL(o);s.shape.percent=0,rr(s,{shape:{percent:1}},a,i),this.add(s),T(Pl,function(u){var l=Wd(u,e,i);this.add(l),this[Hd(u)]=Gd(u,e,i)},this),this._updateCommonStl(e,i,n)},t.prototype.updateData=function(e,i,n){var a=e.hostModel,o=this.childOfName("line"),s=e.getItemLayout(i),u={shape:{}};Jf(u.shape,s),pe(o,u,a,i),T(Pl,function(l){var f=Gd(l,e,i),h=Hd(l);if(this[h]!==f){this.remove(this.childOfName(l));var v=Wd(l,e,i);this.add(v)}this[h]=f},this),this._updateCommonStl(e,i,n)},t.prototype.getLinePath=function(){return this.childAt(0)},t.prototype._updateCommonStl=function(e,i,n){var a=e.hostModel,o=this.childOfName("line"),s=n&&n.emphasisLineStyle,u=n&&n.blurLineStyle,l=n&&n.selectLineStyle,f=n&&n.labelStatesModels,h=n&&n.emphasisDisabled,v=n&&n.focus,c=n&&n.blurScope;if(!n||e.hasItemOption){var p=e.getItemModel(i),d=p.getModel("emphasis");s=d.getModel("lineStyle").getLineStyle(),u=p.getModel(["blur","lineStyle"]).getLineStyle(),l=p.getModel(["select","lineStyle"]).getLineStyle(),h=d.get("disabled"),v=d.get("focus"),c=d.get("blurScope"),f=Sn(p)}var g=e.getItemVisual(i,"style"),y=g.stroke;o.useStyle(g),o.style.fill=null,o.style.strokeNoScale=!0,o.ensureState("emphasis").style=s,o.ensureState("blur").style=u,o.ensureState("select").style=l,T(Pl,function(w){var x=this.childOfName(w);if(x){x.setColor(y),x.style.opacity=g.opacity;for(var C=0;C<Zt.length;C++){var M=Zt[C],D=o.getState(M);if(D){var A=D.style||{},P=x.ensureState(M),R=P.style||(P.style={});A.stroke!=null&&(R[x.__isEmptyBrush?"stroke":"fill"]=A.stroke),A.opacity!=null&&(R.opacity=A.opacity)}}x.markRedraw()}},this);var m=a.getRawValue(i);Ys(this,f,{labelDataIndex:i,labelFetcher:{getFormattedLabel:function(w,x){return a.getFormattedLabel(w,x,e.dataType)}},inheritColor:y||"#000",defaultOpacity:g.opacity,defaultText:(m==null?e.getName(i):isFinite(m)?xt(m):m)+""});var _=this.getTextContent();if(_){var S=f.normal;_.__align=_.style.align,_.__verticalAlign=_.style.verticalAlign,_.__position=S.get("position")||"middle";var b=S.get("distance");B(b)||(b=[b,b]),_.__labelDistance=b}this.setTextConfig({position:null,local:!0,inside:!1}),vn(this,v,c,h)},t.prototype.highlight=function(){ba(this)},t.prototype.downplay=function(){xa(this)},t.prototype.updateLayout=function(e,i){this.setLinePoints(e.getItemLayout(i))},t.prototype.setLinePoints=function(e){var i=this.childOfName("line");Jf(i.shape,e),i.dirty()},t.prototype.beforeUpdate=function(){var e=this,i=e.childOfName("fromSymbol"),n=e.childOfName("toSymbol"),a=e.getTextContent();if(!i&&!n&&(!a||a.ignore))return;for(var o=1,s=this.parent;s;)s.scaleX&&(o/=s.scaleX),s=s.parent;var u=e.childOfName("line");if(!this.__dirty&&!u.__dirty)return;var l=u.shape.percent,f=u.pointAt(0),h=u.pointAt(l),v=sy([],h,f);dh(v,v);function c(D,A){var P=D.__specifiedRotation;if(P==null){var R=u.tangentAt(A);D.attr("rotation",(A===1?-1:1)*Math.PI/2-Math.atan2(R[1],R[0]))}else D.attr("rotation",P)}if(i&&(i.setPosition(f),c(i,0),i.scaleX=i.scaleY=o*l,i.markRedraw()),n&&(n.setPosition(h),c(n,1),n.scaleX=n.scaleY=o*l,n.markRedraw()),a&&!a.ignore){a.x=a.y=0,a.originX=a.originY=0;var p=void 0,d=void 0,g=a.__labelDistance,y=g[0]*o,m=g[1]*o,_=l/2,S=u.tangentAt(_),b=[S[1],-S[0]],w=u.pointAt(_);b[1]>0&&(b[0]=-b[0],b[1]=-b[1]);var x=S[0]<0?-1:1;if(a.__position!=="start"&&a.__position!=="end"){var C=-Math.atan2(S[1],S[0]);h[0]<f[0]&&(C=Math.PI+C),a.rotation=C}var M=void 0;switch(a.__position){case"insideStartTop":case"insideMiddleTop":case"insideEndTop":case"middle":M=-m,d="bottom";break;case"insideStartBottom":case"insideMiddleBottom":case"insideEndBottom":M=m,d="top";break;default:M=0,d="middle"}switch(a.__position){case"end":a.x=v[0]*y+h[0],a.y=v[1]*m+h[1],p=v[0]>.8?"left":v[0]<-.8?"right":"center",d=v[1]>.8?"top":v[1]<-.8?"bottom":"middle";break;case"start":a.x=-v[0]*y+f[0],a.y=-v[1]*m+f[1],p=v[0]>.8?"right":v[0]<-.8?"left":"center",d=v[1]>.8?"bottom":v[1]<-.8?"top":"middle";break;case"insideStartTop":case"insideStart":case"insideStartBottom":a.x=y*x+f[0],a.y=f[1]+M,p=S[0]<0?"right":"left",a.originX=-y*x,a.originY=-M;break;case"insideMiddleTop":case"insideMiddle":case"insideMiddleBottom":case"middle":a.x=w[0],a.y=w[1]+M,p="center",a.originY=-M;break;case"insideEndTop":case"insideEnd":case"insideEndBottom":a.x=-y*x+h[0],a.y=h[1]+M,p=S[0]>=0?"right":"left",a.originX=y*x,a.originY=-M;break}a.scaleX=a.scaleY=o,a.setStyle({verticalAlign:a.__verticalAlign||d,align:a.__align||p})}},t})(gt),IL=(function(){function r(t){this.group=new gt,this._LineCtor=t||PL}return r.prototype.updateData=function(t){var e=this;this._progressiveEls=null;var i=this,n=i.group,a=i._lineData;i._lineData=t,a||n.removeAll();var o=Ud(t);t.diff(a).add(function(s){e._doAdd(t,s,o)}).update(function(s,u){e._doUpdate(a,t,u,s,o)}).remove(function(s){n.remove(a.getItemGraphicEl(s))}).execute()},r.prototype.updateLayout=function(){var t=this._lineData;t&&t.eachItemGraphicEl(function(e,i){e.updateLayout(t,i)},this)},r.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=Ud(t),this._lineData=null,this.group.removeAll()},r.prototype.incrementalUpdate=function(t,e){this._progressiveEls=[];function i(s){!s.isGroup&&!RL(s)&&(s.incremental=!0,s.ensureState("emphasis").hoverLayer=!0)}for(var n=t.start;n<t.end;n++){var a=e.getItemLayout(n);if(Il(a)){var o=new this._LineCtor(e,n,this._seriesScope);o.traverse(i),this.group.add(o),e.setItemGraphicEl(n,o),this._progressiveEls.push(o)}}},r.prototype.remove=function(){this.group.removeAll()},r.prototype.eachRendered=function(t){Va(this._progressiveEls||this.group,t)},r.prototype._doAdd=function(t,e,i){var n=t.getItemLayout(e);if(Il(n)){var a=new this._LineCtor(t,e,i);t.setItemGraphicEl(e,a),this.group.add(a)}},r.prototype._doUpdate=function(t,e,i,n,a){var o=t.getItemGraphicEl(i);if(!Il(e.getItemLayout(n))){this.group.remove(o);return}o?o.updateData(e,n,a):o=new this._LineCtor(e,n,a),e.setItemGraphicEl(n,o),this.group.add(o)},r})();function RL(r){return r.animators&&r.animators.length>0}function Ud(r){var t=r.hostModel,e=t.getModel("emphasis");return{lineStyle:t.getModel("lineStyle").getLineStyle(),emphasisLineStyle:e.getModel(["lineStyle"]).getLineStyle(),blurLineStyle:t.getModel(["blur","lineStyle"]).getLineStyle(),selectLineStyle:t.getModel(["select","lineStyle"]).getLineStyle(),emphasisDisabled:e.get("disabled"),blurScope:e.get("blurScope"),focus:e.get("focus"),labelStatesModels:Sn(t)}}function Yd(r){return isNaN(r[0])||isNaN(r[1])}function Il(r){return r&&!Yd(r[0])&&!Yd(r[1])}function uu(r,t,e,i,n,a){r=r||0;var o=e[1]-e[0];if(n!=null&&(n=Wi(n,[0,o])),a!=null&&(a=Math.max(a,n??0)),i==="all"){var s=Math.abs(t[1]-t[0]);s=Wi(s,[0,o]),n=a=Wi(s,[n,a]),i=0}t[0]=Wi(t[0],e),t[1]=Wi(t[1],e);var u=Rl(t,i);t[i]+=r;var l=n||0,f=e.slice();u.sign<0?f[0]+=l:f[1]-=l,t[i]=Wi(t[i],f);var h;return h=Rl(t,i),n!=null&&(h.sign!==u.sign||h.span<n)&&(t[1-i]=t[i]+u.sign*n),h=Rl(t,i),a!=null&&h.span>a&&(t[1-i]=t[i]+h.sign*a),t}function Rl(r,t){var e=r[t]-r[1-t];return{span:Math.abs(e),sign:e>0?-1:e<0?1:t?-1:1}}function Wi(r,t){return Math.min(t[1]!=null?t[1]:1/0,Math.max(t[0]!=null?t[0]:-1/0,r))}var wi=!0,Oa=Math.min,dn=Math.max,EL=Math.pow,kL=1e4,OL=6,BL=6,Zd="globalPan",NL={w:[0,0],e:[0,1],n:[1,0],s:[1,1]},FL={w:"ew",e:"ew",n:"ns",s:"ns",ne:"nesw",sw:"nesw",nw:"nwse",se:"nwse"},Xd={brushStyle:{lineWidth:2,stroke:"rgba(210,219,238,0.3)",fill:"#D2DBEE"},transformable:!0,brushMode:"single",removeOnClick:!1},zL=0,VL=(function(r){O(t,r);function t(e){var i=r.call(this)||this;return i._track=[],i._covers=[],i._handlers={},i._zr=e,i.group=new gt,i._uid="brushController_"+zL++,T(XL,function(n,a){this._handlers[a]=U(n,this)},i),i}return t.prototype.enableBrush=function(e){return this._brushType&&this._doDisableBrush(),e.brushType&&this._doEnableBrush(e),this},t.prototype._doEnableBrush=function(e){var i=this._zr;this._enableGlobalPan||_L(i,Zd,this._uid),T(this._handlers,function(n,a){i.on(a,n)}),this._brushType=e.brushType,this._brushOption=tt(Y(Xd),e,!0)},t.prototype._doDisableBrush=function(){var e=this._zr;SL(e,Zd,this._uid),T(this._handlers,function(i,n){e.off(n,i)}),this._brushType=this._brushOption=null},t.prototype.setPanels=function(e){if(e&&e.length){var i=this._panels={};T(e,function(n){i[n.panelId]=Y(n)})}else this._panels=null;return this},t.prototype.mount=function(e){e=e||{},this._enableGlobalPan=e.enableGlobalPan;var i=this.group;return this._zr.add(i),i.attr({x:e.x||0,y:e.y||0,rotation:e.rotation||0,scaleX:e.scaleX||1,scaleY:e.scaleY||1}),this._transform=i.getLocalTransform(),this},t.prototype.updateCovers=function(e){e=z(e,function(v){return tt(Y(Xd),v,!0)});var i="\0-brush-index-",n=this._covers,a=this._covers=[],o=this,s=this._creatingCover;return new iv(n,e,l,u).add(f).update(f).remove(h).execute(),this;function u(v,c){return(v.id!=null?v.id:i+c)+"-"+v.brushType}function l(v,c){return u(v.__brushOption,c)}function f(v,c){var p=e[v];if(c!=null&&n[c]===s)a[v]=n[c];else{var d=a[v]=c!=null?(n[c].__brushOption=p,n[c]):N_(o,B_(o,p));pv(o,d)}}function h(v){n[v]!==s&&o.group.remove(n[v])}},t.prototype.unmount=function(){return this.enableBrush(!1),jf(this),this._zr.remove(this.group),this},t.prototype.dispose=function(){this.unmount(),this.off()},t})(de);function B_(r,t){var e=lu[t.brushType].createCover(r,t);return e.__brushOption=t,z_(e,t),r.group.add(e),e}function N_(r,t){var e=dv(t);return e.endCreating&&(e.endCreating(r,t),z_(t,t.__brushOption)),t}function F_(r,t){var e=t.__brushOption;dv(t).updateCoverShape(r,t,e.range,e)}function z_(r,t){var e=t.z;e==null&&(e=kL),r.traverse(function(i){i.z=e,i.z2=e})}function pv(r,t){dv(t).updateCommon(r,t),F_(r,t)}function dv(r){return lu[r.__brushOption.brushType]}function gv(r,t,e){var i=r._panels;if(!i)return wi;var n,a=r._transform;return T(i,function(o){o.isTargetByCursor(t,e,a)&&(n=o)}),n}function V_(r,t){var e=r._panels;if(!e)return wi;var i=t.__brushOption.panelId;return i!=null?e[i]:wi}function jf(r){var t=r._covers,e=t.length;return T(t,function(i){r.group.remove(i)},r),t.length=0,!!e}function bi(r,t){var e=z(r._covers,function(i){var n=i.__brushOption,a=Y(n.range);return{brushType:n.brushType,panelId:n.panelId,range:a}});r.trigger("brush",{areas:e,isEnd:!!t.isEnd,removeOnClick:!!t.removeOnClick})}function HL(r){var t=r._track;if(!t.length)return!1;var e=t[t.length-1],i=t[0],n=e[0]-i[0],a=e[1]-i[1],o=EL(n*n+a*a,.5);return o>OL}function H_(r){var t=r.length-1;return t<0&&(t=0),[r[0],r[t]]}function G_(r,t,e,i){var n=new gt;return n.add(new Tt({name:"main",style:yv(e),silent:!0,draggable:!0,cursor:"move",drift:ot($d,r,t,n,["n","s","w","e"]),ondragend:ot(bi,t,{isEnd:!0})})),T(i,function(a){n.add(new Tt({name:a.join(""),style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:ot($d,r,t,n,a),ondragend:ot(bi,t,{isEnd:!0})}))}),n}function W_(r,t,e,i){var n=i.brushStyle.lineWidth||0,a=dn(n,BL),o=e[0][0],s=e[1][0],u=o-n/2,l=s-n/2,f=e[0][1],h=e[1][1],v=f-a+n/2,c=h-a+n/2,p=f-o,d=h-s,g=p+n,y=d+n;Ze(r,t,"main",o,s,p,d),i.transformable&&(Ze(r,t,"w",u,l,a,y),Ze(r,t,"e",v,l,a,y),Ze(r,t,"n",u,l,g,a),Ze(r,t,"s",u,c,g,a),Ze(r,t,"nw",u,l,a,a),Ze(r,t,"ne",v,l,a,a),Ze(r,t,"sw",u,c,a,a),Ze(r,t,"se",v,c,a,a))}function th(r,t){var e=t.__brushOption,i=e.transformable,n=t.childAt(0);n.useStyle(yv(e)),n.attr({silent:!i,cursor:i?"move":"default"}),T([["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]],function(a){var o=t.childOfName(a.join("")),s=a.length===1?eh(r,a[0]):WL(r,a);o&&o.attr({silent:!i,invisible:!i,cursor:i?FL[s]+"-resize":null})})}function Ze(r,t,e,i,n,a,o){var s=t.childOfName(e);s&&s.setShape(YL(mv(r,t,[[i,n],[i+a,n+o]])))}function yv(r){return rt({strokeNoScale:!0},r.brushStyle)}function U_(r,t,e,i){var n=[Oa(r,e),Oa(t,i)],a=[dn(r,e),dn(t,i)];return[[n[0],a[0]],[n[1],a[1]]]}function GL(r){return Ws(r.group)}function eh(r,t){var e={w:"left",e:"right",n:"top",s:"bottom"},i={left:"w",right:"e",top:"n",bottom:"s"},n=kh(e[t],GL(r));return i[n]}function WL(r,t){var e=[eh(r,t[0]),eh(r,t[1])];return(e[0]==="e"||e[0]==="w")&&e.reverse(),e.join("")}function $d(r,t,e,i,n,a){var o=e.__brushOption,s=r.toRectRange(o.range),u=Y_(t,n,a);T(i,function(l){var f=NL[l];s[f[0]][f[1]]+=u[f[0]]}),o.range=r.fromRectRange(U_(s[0][0],s[1][0],s[0][1],s[1][1])),pv(t,e),bi(t,{isEnd:!1})}function UL(r,t,e,i){var n=t.__brushOption.range,a=Y_(r,e,i);T(n,function(o){o[0]+=a[0],o[1]+=a[1]}),pv(r,t),bi(r,{isEnd:!1})}function Y_(r,t,e){var i=r.group,n=i.transformCoordToLocal(t,e),a=i.transformCoordToLocal(0,0);return[n[0]-a[0],n[1]-a[1]]}function mv(r,t,e){var i=V_(r,t);return i&&i!==wi?i.clipPath(e,r._transform):Y(e)}function YL(r){var t=Oa(r[0][0],r[1][0]),e=Oa(r[0][1],r[1][1]),i=dn(r[0][0],r[1][0]),n=dn(r[0][1],r[1][1]);return{x:t,y:e,width:i-t,height:n-e}}function ZL(r,t,e){if(!(!r._brushType||$L(r,t.offsetX,t.offsetY))){var i=r._zr,n=r._covers,a=gv(r,t,e);if(!r._dragging)for(var o=0;o<n.length;o++){var s=n[o].__brushOption;if(a&&(a===wi||s.panelId===a.panelId)&&lu[s.brushType].contain(n[o],e[0],e[1]))return}a&&i.setCursorStyle("crosshair")}}function rh(r){var t=r.event;t.preventDefault&&t.preventDefault()}function ih(r,t,e){return r.childOfName("main").contain(t,e)}function Z_(r,t,e,i){var n=r._creatingCover,a=r._creatingPanel,o=r._brushOption,s;if(r._track.push(e.slice()),HL(r)||n){if(a&&!n){o.brushMode==="single"&&jf(r);var u=Y(o);u.brushType=qd(u.brushType,a),u.panelId=a===wi?null:a.panelId,n=r._creatingCover=B_(r,u),r._covers.push(n)}if(n){var l=lu[qd(r._brushType,a)],f=n.__brushOption;f.range=l.getCreatingRange(mv(r,n,r._track)),i&&(N_(r,n),l.updateCommon(r,n)),F_(r,n),s={isEnd:i}}}else i&&o.brushMode==="single"&&o.removeOnClick&&gv(r,t,e)&&jf(r)&&(s={isEnd:i,removeOnClick:!0});return s}function qd(r,t){return r==="auto"?t.defaultBrushType:r}var XL={mousedown:function(r){if(this._dragging)Kd(this,r);else if(!r.target||!r.target.draggable){rh(r);var t=this.group.transformCoordToLocal(r.offsetX,r.offsetY);this._creatingCover=null;var e=this._creatingPanel=gv(this,r,t);e&&(this._dragging=!0,this._track=[t.slice()])}},mousemove:function(r){var t=r.offsetX,e=r.offsetY,i=this.group.transformCoordToLocal(t,e);if(ZL(this,r,i),this._dragging){rh(r);var n=Z_(this,r,i,!1);n&&bi(this,n)}},mouseup:function(r){Kd(this,r)}};function Kd(r,t){if(r._dragging){rh(t);var e=t.offsetX,i=t.offsetY,n=r.group.transformCoordToLocal(e,i),a=Z_(r,t,n,!0);r._dragging=!1,r._track=[],r._creatingCover=null,a&&bi(r,a)}}function $L(r,t,e){var i=r._zr;return t<0||t>i.getWidth()||e<0||e>i.getHeight()}var lu={lineX:Qd(0),lineY:Qd(1),rect:{createCover:function(r,t){function e(i){return i}return G_({toRectRange:e,fromRectRange:e},r,t,[["w"],["e"],["n"],["s"],["s","e"],["s","w"],["n","e"],["n","w"]])},getCreatingRange:function(r){var t=H_(r);return U_(t[1][0],t[1][1],t[0][0],t[0][1])},updateCoverShape:function(r,t,e,i){W_(r,t,e,i)},updateCommon:th,contain:ih},polygon:{createCover:function(r,t){var e=new gt;return e.add(new _n({name:"main",style:yv(t),silent:!0})),e},getCreatingRange:function(r){return r},endCreating:function(r,t){t.remove(t.childAt(0)),t.add(new mi({name:"main",draggable:!0,drift:ot(UL,r,t),ondragend:ot(bi,r,{isEnd:!0})}))},updateCoverShape:function(r,t,e,i){t.childAt(0).setShape({points:mv(r,t,e)})},updateCommon:th,contain:ih}};function Qd(r){return{createCover:function(t,e){return G_({toRectRange:function(i){var n=[i,[0,100]];return r&&n.reverse(),n},fromRectRange:function(i){return i[r]}},t,e,[[["w"],["e"]],[["n"],["s"]]][r])},getCreatingRange:function(t){var e=H_(t),i=Oa(e[0][r],e[1][r]),n=dn(e[0][r],e[1][r]);return[i,n]},updateCoverShape:function(t,e,i,n){var a,o=V_(t,e);if(o!==wi&&o.getLinearBrushOtherExtent)a=o.getLinearBrushOtherExtent(r);else{var s=t._zr;a=[0,[s.getWidth(),s.getHeight()][1-r]]}var u=[i,a];r&&u.reverse(),W_(t,e,u,n)},updateCommon:th,contain:ih}}function qL(r){return r=_v(r),function(t){return _m(t,r)}}function KL(r,t){return r=_v(r),function(e){var i=t??e,n=i?r.width:r.height,a=i?r.x:r.y;return[a,a+(n||0)]}}function QL(r,t,e){var i=_v(r);return function(n,a){return i.contain(a[0],a[1])&&!xL(n,t,e)}}function _v(r){return et.create(r)}var Jd={color:"fill",borderColor:"stroke"},JL={symbol:1,symbolSize:1,symbolKeepAspect:1,legendIcon:1,visualMeta:1,liftZ:1,decal:1},Je=vt(),jL=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.optionUpdated=function(){this.currentZLevel=this.get("zlevel",!0),this.currentZ=this.get("z",!0)},t.prototype.getInitialData=function(e,i){return nv(null,this)},t.prototype.getDataParams=function(e,i,n){var a=r.prototype.getDataParams.call(this,e,i);return n&&(a.info=Je(n).info),a},t.type="series.custom",t.dependencies=["grid","polar","geo","singleAxis","calendar"],t.defaultOption={coordinateSystem:"cartesian2d",z:2,legendHoverLink:!0,clip:!1},t})(He);function t2(r,t){return t=t||[0,0],z(["x","y"],function(e,i){var n=this.getAxis(e),a=t[i],o=r[i]/2;return n.type==="category"?n.getBandWidth():Math.abs(n.dataToCoord(a-o)-n.dataToCoord(a+o))},this)}function e2(r){var t=r.master.getRect();return{coordSys:{type:"cartesian2d",x:t.x,y:t.y,width:t.width,height:t.height},api:{coord:function(e){return r.dataToPoint(e)},size:U(t2,r)}}}function r2(r,t){return t=t||[0,0],z([0,1],function(e){var i=t[e],n=r[e]/2,a=[],o=[];return a[e]=i-n,o[e]=i+n,a[1-e]=o[1-e]=t[1-e],Math.abs(this.dataToPoint(a)[e]-this.dataToPoint(o)[e])},this)}function i2(r){var t=r.getBoundingRect();return{coordSys:{type:"geo",x:t.x,y:t.y,width:t.width,height:t.height,zoom:r.getZoom()},api:{coord:function(e){return r.dataToPoint(e)},size:U(r2,r)}}}function n2(r,t){var e=this.getAxis(),i=t instanceof Array?t[0]:t,n=(r instanceof Array?r[0]:r)/2;return e.type==="category"?e.getBandWidth():Math.abs(e.dataToCoord(i-n)-e.dataToCoord(i+n))}function a2(r){var t=r.getRect();return{coordSys:{type:"singleAxis",x:t.x,y:t.y,width:t.width,height:t.height},api:{coord:function(e){return r.dataToPoint(e)},size:U(n2,r)}}}function o2(r,t){return t=t||[0,0],z(["Radius","Angle"],function(e,i){var n="get"+e+"Axis",a=this[n](),o=t[i],s=r[i]/2,u=a.type==="category"?a.getBandWidth():Math.abs(a.dataToCoord(o-s)-a.dataToCoord(o+s));return e==="Angle"&&(u=u*Math.PI/180),u},this)}function s2(r){var t=r.getRadiusAxis(),e=r.getAngleAxis(),i=t.getExtent();return i[0]>i[1]&&i.reverse(),{coordSys:{type:"polar",cx:r.cx,cy:r.cy,r:i[1],r0:i[0]},api:{coord:function(n){var a=t.dataToRadius(n[0]),o=e.dataToAngle(n[1]),s=r.coordToPoint([a,o]);return s.push(a,o*Math.PI/180),s},size:U(o2,r)}}}function u2(r){var t=r.getRect(),e=r.getRangeInfo();return{coordSys:{type:"calendar",x:t.x,y:t.y,width:t.width,height:t.height,cellWidth:r.getCellWidth(),cellHeight:r.getCellHeight(),rangeInfo:{start:e.start,end:e.end,weeks:e.weeks,dayCount:e.allDay}},api:{coord:function(i,n){return r.dataToPoint(i,n)}}}}function l2(r,t,e,i){return r&&(r.legacy||r.legacy!==!1&&!e&&!i&&t!=="tspan"&&(t==="text"||N(r,"text")))}function f2(r,t,e){var i=r,n,a,o;if(t==="text")o=i;else{o={},N(i,"text")&&(o.text=i.text),N(i,"rich")&&(o.rich=i.rich),N(i,"textFill")&&(o.fill=i.textFill),N(i,"textStroke")&&(o.stroke=i.textStroke),N(i,"fontFamily")&&(o.fontFamily=i.fontFamily),N(i,"fontSize")&&(o.fontSize=i.fontSize),N(i,"fontStyle")&&(o.fontStyle=i.fontStyle),N(i,"fontWeight")&&(o.fontWeight=i.fontWeight),a={type:"text",style:o,silent:!0},n={};var s=N(i,"textPosition");e?n.position=s?i.textPosition:"inside":s&&(n.position=i.textPosition),N(i,"textPosition")&&(n.position=i.textPosition),N(i,"textOffset")&&(n.offset=i.textOffset),N(i,"textRotation")&&(n.rotation=i.textRotation),N(i,"textDistance")&&(n.distance=i.textDistance)}return jd(o,r),T(o.rich,function(u){jd(u,u)}),{textConfig:n,textContent:a}}function jd(r,t){t&&(t.font=t.textFont||t.font,N(t,"textStrokeWidth")&&(r.lineWidth=t.textStrokeWidth),N(t,"textAlign")&&(r.align=t.textAlign),N(t,"textVerticalAlign")&&(r.verticalAlign=t.textVerticalAlign),N(t,"textLineHeight")&&(r.lineHeight=t.textLineHeight),N(t,"textWidth")&&(r.width=t.textWidth),N(t,"textHeight")&&(r.height=t.textHeight),N(t,"textBackgroundColor")&&(r.backgroundColor=t.textBackgroundColor),N(t,"textPadding")&&(r.padding=t.textPadding),N(t,"textBorderColor")&&(r.borderColor=t.textBorderColor),N(t,"textBorderWidth")&&(r.borderWidth=t.textBorderWidth),N(t,"textBorderRadius")&&(r.borderRadius=t.textBorderRadius),N(t,"textBoxShadowColor")&&(r.shadowColor=t.textBoxShadowColor),N(t,"textBoxShadowBlur")&&(r.shadowBlur=t.textBoxShadowBlur),N(t,"textBoxShadowOffsetX")&&(r.shadowOffsetX=t.textBoxShadowOffsetX),N(t,"textBoxShadowOffsetY")&&(r.shadowOffsetY=t.textBoxShadowOffsetY))}function tg(r,t,e){var i=r;i.textPosition=i.textPosition||e.position||"inside",e.offset!=null&&(i.textOffset=e.offset),e.rotation!=null&&(i.textRotation=e.rotation),e.distance!=null&&(i.textDistance=e.distance);var n=i.textPosition.indexOf("inside")>=0,a=r.fill||"#000";eg(i,t);var o=i.textFill==null;return n?o&&(i.textFill=e.insideFill||"#fff",!i.textStroke&&e.insideStroke&&(i.textStroke=e.insideStroke),!i.textStroke&&(i.textStroke=a),i.textStrokeWidth==null&&(i.textStrokeWidth=2)):(o&&(i.textFill=r.fill||e.outsideFill||"#000"),!i.textStroke&&e.outsideStroke&&(i.textStroke=e.outsideStroke)),i.text=t.text,i.rich=t.rich,T(t.rich,function(s){eg(s,s)}),i}function eg(r,t){t&&(N(t,"fill")&&(r.textFill=t.fill),N(t,"stroke")&&(r.textStroke=t.fill),N(t,"lineWidth")&&(r.textStrokeWidth=t.lineWidth),N(t,"font")&&(r.font=t.font),N(t,"fontStyle")&&(r.fontStyle=t.fontStyle),N(t,"fontWeight")&&(r.fontWeight=t.fontWeight),N(t,"fontSize")&&(r.fontSize=t.fontSize),N(t,"fontFamily")&&(r.fontFamily=t.fontFamily),N(t,"align")&&(r.textAlign=t.align),N(t,"verticalAlign")&&(r.textVerticalAlign=t.verticalAlign),N(t,"lineHeight")&&(r.textLineHeight=t.lineHeight),N(t,"width")&&(r.textWidth=t.width),N(t,"height")&&(r.textHeight=t.height),N(t,"backgroundColor")&&(r.textBackgroundColor=t.backgroundColor),N(t,"padding")&&(r.textPadding=t.padding),N(t,"borderColor")&&(r.textBorderColor=t.borderColor),N(t,"borderWidth")&&(r.textBorderWidth=t.borderWidth),N(t,"borderRadius")&&(r.textBorderRadius=t.borderRadius),N(t,"shadowColor")&&(r.textBoxShadowColor=t.shadowColor),N(t,"shadowBlur")&&(r.textBoxShadowBlur=t.shadowBlur),N(t,"shadowOffsetX")&&(r.textBoxShadowOffsetX=t.shadowOffsetX),N(t,"shadowOffsetY")&&(r.textBoxShadowOffsetY=t.shadowOffsetY),N(t,"textShadowColor")&&(r.textShadowColor=t.textShadowColor),N(t,"textShadowBlur")&&(r.textShadowBlur=t.textShadowBlur),N(t,"textShadowOffsetX")&&(r.textShadowOffsetX=t.textShadowOffsetX),N(t,"textShadowOffsetY")&&(r.textShadowOffsetY=t.textShadowOffsetY))}var X_={position:["x","y"],scale:["scaleX","scaleY"],origin:["originX","originY"]},rg=ft(X_);Ti(Ve,function(r,t){return r[t]=1,r},{});Ve.join(", ");var _s=["","style","shape","extra"],gn=vt();function Sv(r,t,e,i,n){var a=r+"Animation",o=Rh(r,i,n)||{},s=gn(t).userDuring;return o.duration>0&&(o.during=s?U(y2,{el:t,userDuring:s}):null,o.setToFinal=!0,o.scope=r),k(o,e[a]),o}function h2(r,t,e,i){i=i||{};var n=i.dataIndex,a=i.isInit,o=i.clearStyle,s=e.isAnimationEnabled(),u=gn(r),l=t.style;u.userDuring=t.during;var f={},h={};if(_2(r,t,h),ng("shape",t,h),ng("extra",t,h),!a&&s&&(m2(r,t,f),ig("shape",r,t,f),ig("extra",r,t,f),S2(r,t,l,f)),h.style=l,c2(r,h,o),d2(r,t),s)if(a){var v={};T(_s,function(p){var d=p?t[p]:t;d&&d.enterFrom&&(p&&(v[p]=v[p]||{}),k(p?v[p]:v,d.enterFrom))});var c=Sv("enter",r,t,e,n);c.duration>0&&r.animateFrom(v,c)}else p2(r,t,n||0,e,f);v2(r,t),l?r.dirty():r.markRedraw()}function v2(r,t){for(var e=gn(r).leaveToProps,i=0;i<_s.length;i++){var n=_s[i],a=n?t[n]:t;a&&a.leaveTo&&(e||(e=gn(r).leaveToProps={}),n&&(e[n]=e[n]||{}),k(n?e[n]:e,a.leaveTo))}}function wv(r,t,e,i){if(r){var n=r.parent,a=gn(r).leaveToProps;if(a){var o=Sv("update",r,t,e,0);o.done=function(){n.remove(r)},r.animateTo(a,o)}else n.remove(r)}}function fn(r){return r==="all"}function c2(r,t,e){var i=t.style;if(!r.isGroup&&i){if(e){r.useStyle({});for(var n=r.animators,a=0;a<n.length;a++){var o=n[a];o.targetName==="style"&&o.changeTarget(r.style)}}r.setStyle(i)}t&&(t.style=null,t&&r.attr(t),t.style=i)}function p2(r,t,e,i,n){if(n){var a=Sv("update",r,t,i,e);a.duration>0&&r.animateFrom(n,a)}}function d2(r,t){N(t,"silent")&&(r.silent=t.silent),N(t,"ignore")&&(r.ignore=t.ignore),r instanceof Mi&&N(t,"invisible")&&(r.invisible=t.invisible),r instanceof st&&N(t,"autoBatch")&&(r.autoBatch=t.autoBatch)}var Re={},g2={setTransform:function(r,t){return Re.el[r]=t,this},getTransform:function(r){return Re.el[r]},setShape:function(r,t){var e=Re.el,i=e.shape||(e.shape={});return i[r]=t,e.dirtyShape&&e.dirtyShape(),this},getShape:function(r){var t=Re.el.shape;if(t)return t[r]},setStyle:function(r,t){var e=Re.el,i=e.style;return i&&(i[r]=t,e.dirtyStyle&&e.dirtyStyle()),this},getStyle:function(r){var t=Re.el.style;if(t)return t[r]},setExtra:function(r,t){var e=Re.el.extra||(Re.el.extra={});return e[r]=t,this},getExtra:function(r){var t=Re.el.extra;if(t)return t[r]}};function y2(){var r=this,t=r.el;if(t){var e=gn(t).userDuring,i=r.userDuring;if(e!==i){r.el=r.userDuring=null;return}Re.el=t,i(g2)}}function ig(r,t,e,i){var n=e[r];if(n){var a=t[r],o;if(a){var s=e.transition,u=n.transition;if(u)if(!o&&(o=i[r]={}),fn(u))k(o,a);else for(var l=Ct(u),f=0;f<l.length;f++){var h=l[f],v=a[h];o[h]=v}else if(fn(s)||Q(s,r)>=0){!o&&(o=i[r]={});for(var c=ft(a),f=0;f<c.length;f++){var h=c[f],v=a[h];w2(n[h],v)&&(o[h]=v)}}}}}function ng(r,t,e){var i=t[r];if(i)for(var n=e[r]={},a=ft(i),o=0;o<a.length;o++){var s=a[o];n[s]=ua(i[s])}}function m2(r,t,e){for(var i=t.transition,n=fn(i)?Ve:Ct(i||[]),a=0;a<n.length;a++){var o=n[a];if(!(o==="style"||o==="shape"||o==="extra")){var s=r[o];e[o]=s}}}function _2(r,t,e){for(var i=0;i<rg.length;i++){var n=rg[i],a=X_[n],o=t[n];o&&(e[a[0]]=o[0],e[a[1]]=o[1])}for(var i=0;i<Ve.length;i++){var s=Ve[i];t[s]!=null&&(e[s]=t[s])}}function S2(r,t,e,i){if(e){var n=r.style,a;if(n){var o=e.transition,s=t.transition;if(o&&!fn(o)){var u=Ct(o);!a&&(a=i.style={});for(var l=0;l<u.length;l++){var f=u[l],h=n[f];a[f]=h}}else if(r.getAnimationStyleProps&&(fn(s)||fn(o)||Q(s,"style")>=0)){var v=r.getAnimationStyleProps(),c=v?v.style:null;if(c){!a&&(a=i.style={});for(var p=ft(e),l=0;l<p.length;l++){var f=p[l];if(c[f]){var h=n[f];a[f]=h}}}}}}}function w2(r,t){return zt(r)?r!==t:r!=null&&isFinite(r)}var $_=vt(),b2=["percent","easing","shape","style","extra"];function x2(r){r.stopAnimation("keyframe"),r.attr($_(r))}function q_(r,t,e){if(!(!e.isAnimationEnabled()||!t)){if(B(t)){T(t,function(s){q_(r,s,e)});return}var i=t.keyframes,n=t.duration;if(e&&n==null){var a=Rh("enter",e,0);n=a&&a.duration}if(!(!i||!n)){var o=$_(r);T(_s,function(s){if(!(s&&!r[s])){var u;i.sort(function(l,f){return l.percent-f.percent}),T(i,function(l){var f=r.animators,h=s?l[s]:l;if(h){var v=ft(h);if(s||(v=_t(v,function(d){return Q(b2,d)<0})),!!v.length){u||(u=r.animate(s,t.loop,!0),u.scope="keyframe");for(var c=0;c<f.length;c++)f[c]!==u&&f[c].targetName===u.targetName&&f[c].stopTracks(v);s&&(o[s]=o[s]||{});var p=s?o[s]:o;T(v,function(d){p[d]=((s?r[s]:r)||{})[d]}),u.whenWithKeys(n*l.percent,h,v,l.easing)}}}),u&&u.delay(t.delay||0).duration(n).start(t.easing)}})}}}var je="emphasis",wr="normal",bv="blur",xv="select",Ir=[wr,je,bv,xv],El={normal:["itemStyle"],emphasis:[je,"itemStyle"],blur:[bv,"itemStyle"],select:[xv,"itemStyle"]},kl={normal:["label"],emphasis:[je,"label"],blur:[bv,"label"],select:[xv,"label"]},T2=["x","y"],M2="e\0\0",ie={normal:{},emphasis:{},blur:{},select:{}},C2={cartesian2d:e2,geo:i2,single:a2,polar:s2,calendar:u2};function nh(r){return r instanceof st}function ah(r){return r instanceof Mi}function D2(r,t){t.copyTransform(r),ah(t)&&ah(r)&&(t.setStyle(r.style),t.z=r.z,t.z2=r.z2,t.zlevel=r.zlevel,t.invisible=r.invisible,t.ignore=r.ignore,nh(t)&&nh(r)&&t.setShape(r.shape))}var A2=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n,a){this._progressiveEls=null;var o=this._data,s=e.getData(),u=this.group,l=ag(e,s,i,n);o||u.removeAll(),s.diff(o).add(function(h){Ol(n,null,h,l(h,a),e,u,s)}).remove(function(h){var v=o.getItemGraphicEl(h);v&&wv(v,Je(v).option,e)}).update(function(h,v){var c=o.getItemGraphicEl(v);Ol(n,c,h,l(h,a),e,u,s)}).execute();var f=e.get("clip",!0)?wA(e.coordinateSystem,!1,e):null;f?u.setClipPath(f):u.removeClipPath(),this._data=s},t.prototype.incrementalPrepareRender=function(e,i,n){this.group.removeAll(),this._data=null},t.prototype.incrementalRender=function(e,i,n,a,o){var s=i.getData(),u=ag(i,s,n,a),l=this._progressiveEls=[];function f(c){c.isGroup||(c.incremental=!0,c.ensureState("emphasis").hoverLayer=!0)}for(var h=e.start;h<e.end;h++){var v=Ol(null,null,h,u(h,o),i,this.group,s);v&&(v.traverse(f),l.push(v))}},t.prototype.eachRendered=function(e){Va(this._progressiveEls||this.group,e)},t.prototype.filterForExposedEvent=function(e,i,n,a){var o=i.element;if(o==null||n.name===o)return!0;for(;(n=n.__hostTarget||n.parent)&&n!==this.group;)if(n.name===o)return!0;return!1},t.type="custom",t})(ce);function Tv(r){var t=r.type,e;if(t==="path"){var i=r.shape,n=i.width!=null&&i.height!=null?{x:i.x||0,y:i.y||0,width:i.width,height:i.height}:null,a=J_(i);e=Gs(a,null,n,i.layout||"center"),Je(e).customPathData=a}else if(t==="image")e=new nr({}),Je(e).customImagePath=r.style.image;else if(t==="text")e=new te({});else if(t==="group")e=new gt;else{if(t==="compoundPath")throw new Error('"compoundPath" is not supported yet.');var o=pm(t);if(!o){var s="";Ft(s)}e=new o}return Je(e).customGraphicType=t,e.name=r.name,e.z2EmphasisLift=1,e.z2SelectLift=1,e}function Mv(r,t,e,i,n,a,o){x2(t);var s=n&&n.normal.cfg;s&&t.setTextConfig(s),i&&i.transition==null&&(i.transition=T2);var u=i&&i.style;if(u){if(t.type==="text"){var l=u;N(l,"textFill")&&(l.fill=l.textFill),N(l,"textStroke")&&(l.stroke=l.textStroke)}var f=void 0,h=nh(t)?u.decal:null;r&&h&&(h.dirty=!0,f=Bf(h,r)),u.__decalPattern=f}if(ah(t)&&u){var f=u.__decalPattern;f&&(u.decal=f)}h2(t,i,a,{dataIndex:e,isInit:o,clearStyle:!0}),q_(t,i.keyframeAnimation,a)}function K_(r,t,e,i,n){var a=t.isGroup?null:t,o=n&&n[r].cfg;if(a){var s=a.ensureState(r);if(i===!1){var u=a.getState(r);u&&(u.style=null)}else s.style=i||null;o&&(s.textConfig=o),jy(a)}}function L2(r,t,e){if(!r.isGroup){var i=r,n=e.currentZ,a=e.currentZLevel;i.z=n,i.zlevel=a;var o=t.z2;o!=null&&(i.z2=o||0);for(var s=0;s<Ir.length;s++)P2(i,t,Ir[s])}}function P2(r,t,e){var i=e===wr,n=i?t:Ss(t,e),a=n?n.z2:null,o;a!=null&&(o=i?r:r.ensureState(e),o.z2=a||0)}function ag(r,t,e,i){var n=r.get("renderItem"),a=r.coordinateSystem,o={};a&&(o=a.prepareCustoms?a.prepareCustoms(a):C2[a.type](a));for(var s=rt({getWidth:i.getWidth,getHeight:i.getHeight,getZr:i.getZr,getDevicePixelRatio:i.getDevicePixelRatio,value:S,style:w,ordinalRawValue:b,styleEmphasis:x,visual:D,barLayout:A,currentSeriesIndices:P,font:R},o.api||{}),u={context:{},seriesId:r.id,seriesName:r.name,seriesIndex:r.seriesIndex,coordSys:o.coordSys,dataInsideLength:t.count(),encode:I2(r.getData())},l,f,h={},v={},c={},p={},d=0;d<Ir.length;d++){var g=Ir[d];c[g]=r.getModel(El[g]),p[g]=r.getModel(kl[g])}function y(L){return L===l?f||(f=t.getItemModel(L)):t.getItemModel(L)}function m(L,I){return t.hasItemOption?L===l?h[I]||(h[I]=y(L).getModel(El[I])):y(L).getModel(El[I]):c[I]}function _(L,I){return t.hasItemOption?L===l?v[I]||(v[I]=y(L).getModel(kl[I])):y(L).getModel(kl[I]):p[I]}return function(L,I){return l=L,f=null,h={},v={},n&&n(rt({dataIndexInside:L,dataIndex:t.getRawIndex(L),actionType:I?I.type:null},u),s)};function S(L,I){return I==null&&(I=l),t.getStore().get(t.getDimensionIndex(L||0),I)}function b(L,I){I==null&&(I=l),L=L||0;var E=t.getDimensionInfo(L);if(!E){var G=t.getDimensionIndex(L);return G>=0?t.getStore().get(G,I):void 0}var V=t.get(E.name,I),F=E&&E.ordinalMeta;return F?F.categories[V]:V}function w(L,I){I==null&&(I=l);var E=t.getItemVisual(I,"style"),G=E&&E.fill,V=E&&E.opacity,F=m(I,wr).getItemStyle();G!=null&&(F.fill=G),V!=null&&(F.opacity=V);var J={inheritColor:H(G)?G:"#000"},ut=_(I,wr),lt=Lr(ut,null,J,!1,!0);lt.text=ut.getShallow("show")?$(r.getFormattedLabel(I,wr),ys(t,I)):null;var ct=ss(ut,J,!1);return M(L,F),F=tg(F,lt,ct),L&&C(F,L),F.legacy=!0,F}function x(L,I){I==null&&(I=l);var E=m(I,je).getItemStyle(),G=_(I,je),V=Lr(G,null,null,!0,!0);V.text=G.getShallow("show")?aa(r.getFormattedLabel(I,je),r.getFormattedLabel(I,wr),ys(t,I)):null;var F=ss(G,null,!0);return M(L,E),E=tg(E,V,F),L&&C(E,L),E.legacy=!0,E}function C(L,I){for(var E in I)N(I,E)&&(L[E]=I[E])}function M(L,I){L&&(L.textFill&&(I.textFill=L.textFill),L.textPosition&&(I.textPosition=L.textPosition))}function D(L,I){if(I==null&&(I=l),N(Jd,L)){var E=t.getItemVisual(I,"style");return E?E[Jd[L]]:null}if(N(JL,L))return t.getItemVisual(I,L)}function A(L){if(a.type==="cartesian2d"){var I=a.getBaseAxis();return uD(rt({axis:I},L))}}function P(){return e.getCurrentSeriesIndices()}function R(L){return xm(L,e)}}function I2(r){var t={};return T(r.dimensions,function(e){var i=r.getDimensionInfo(e);if(!i.isExtraCoord){var n=i.coordDim,a=t[n]=t[n]||[];a[i.coordDimIndex]=r.getDimensionIndex(e)}}),t}function Ol(r,t,e,i,n,a,o){if(!i){a.remove(t);return}var s=Cv(r,t,e,i,n,a);return s&&o.setItemGraphicEl(e,s),s&&vn(s,i.focus,i.blurScope,i.emphasisDisabled),s}function Cv(r,t,e,i,n,a){var o=-1,s=t;t&&Q_(t,i,n)&&(o=Q(a.childrenRef(),t),t=null);var u=!t,l=t;l?l.clearStates():(l=Tv(i),s&&D2(s,l)),i.morph===!1?l.disableMorphing=!0:l.disableMorphing&&(l.disableMorphing=!1),ie.normal.cfg=ie.normal.conOpt=ie.emphasis.cfg=ie.emphasis.conOpt=ie.blur.cfg=ie.blur.conOpt=ie.select.cfg=ie.select.conOpt=null,ie.isLegacy=!1,E2(l,e,i,n,u,ie),R2(l,e,i,n,u),Mv(r,l,e,i,ie,n,u),N(i,"info")&&(Je(l).info=i.info);for(var f=0;f<Ir.length;f++){var h=Ir[f];if(h!==wr){var v=Ss(i,h),c=Dv(i,v,h);K_(h,l,v,c,ie)}}return L2(l,i,n),i.type==="group"&&k2(r,l,e,i,n),o>=0?a.replaceAt(l,o):a.add(l),l}function Q_(r,t,e){var i=Je(r),n=t.type,a=t.shape,o=t.style;return e.isUniversalTransitionEnabled()||n!=null&&n!==i.customGraphicType||n==="path"&&F2(a)&&J_(a)!==i.customPathData||n==="image"&&N(o,"image")&&o.image!==i.customImagePath}function R2(r,t,e,i,n){var a=e.clipPath;if(a===!1)r&&r.getClipPath()&&r.removeClipPath();else if(a){var o=r.getClipPath();o&&Q_(o,a,i)&&(o=null),o||(o=Tv(a),r.setClipPath(o)),Mv(null,o,t,a,null,i,n)}}function E2(r,t,e,i,n,a){if(!r.isGroup){og(e,null,a),og(e,je,a);var o=a.normal.conOpt,s=a.emphasis.conOpt,u=a.blur.conOpt,l=a.select.conOpt;if(o!=null||s!=null||l!=null||u!=null){var f=r.getTextContent();if(o===!1)f&&r.removeTextContent();else{o=a.normal.conOpt=o||{type:"text"},f?f.clearStates():(f=Tv(o),r.setTextContent(f)),Mv(null,f,t,o,null,i,n);for(var h=o&&o.style,v=0;v<Ir.length;v++){var c=Ir[v];if(c!==wr){var p=a[c].conOpt;K_(c,f,p,Dv(o,p,c),null)}}h?f.dirty():f.markRedraw()}}}}function og(r,t,e){var i=t?Ss(r,t):r,n=t?Dv(r,i,je):r.style,a=r.type,o=i?i.textConfig:null,s=r.textContent,u=s?t?Ss(s,t):s:null;if(n&&(e.isLegacy||l2(n,a,!!o,!!u))){e.isLegacy=!0;var l=f2(n,a,!t);!o&&l.textConfig&&(o=l.textConfig),!u&&l.textContent&&(u=l.textContent)}if(!t&&u){var f=u;!f.type&&(f.type="text")}var h=t?e[t]:e.normal;h.cfg=o,h.conOpt=u}function Ss(r,t){return t?r?r[t]:null:r}function Dv(r,t,e){var i=t&&t.style;return i==null&&e===je&&r&&(i=r.styleEmphasis),i}function k2(r,t,e,i,n){var a=i.children,o=a?a.length:0,s=i.$mergeChildren,u=s==="byName"||i.diffChildrenByName,l=s===!1;if(!(!o&&!u&&!l)){if(u){B2({api:r,oldChildren:t.children()||[],newChildren:a||[],dataIndex:e,seriesModel:n,group:t});return}l&&t.removeAll();for(var f=0;f<o;f++){var h=a[f],v=t.childAt(f);h?(h.ignore==null&&(h.ignore=!1),Cv(r,v,e,h,n,t)):v.ignore=!0}for(var c=t.childCount()-1;c>=f;c--){var p=t.childAt(c);O2(t,p,n)}}}function O2(r,t,e){t&&wv(t,Je(r).option,e)}function B2(r){new iv(r.oldChildren,r.newChildren,sg,sg,r).add(ug).update(ug).remove(N2).execute()}function sg(r,t){var e=r&&r.name;return e??M2+t}function ug(r,t){var e=this.context,i=r!=null?e.newChildren[r]:null,n=t!=null?e.oldChildren[t]:null;Cv(e.api,n,e.dataIndex,i,e.seriesModel,e.group)}function N2(r){var t=this.context,e=t.oldChildren[r];e&&wv(e,Je(e).option,t.seriesModel)}function J_(r){return r&&(r.pathData||r.d)}function F2(r){return r&&(N(r,"pathData")||N(r,"d"))}function z2(r){r.registerChartView(A2),r.registerSeriesModel(jL)}var ai=vt(),lg=Y,Bl=U,V2=(function(){function r(){this._dragging=!1,this.animationThreshold=15}return r.prototype.render=function(t,e,i,n){var a=e.get("value"),o=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=i,!(!n&&this._lastValue===a&&this._lastStatus===o)){this._lastValue=a,this._lastStatus=o;var s=this._group,u=this._handle;if(!o||o==="hide"){s&&s.hide(),u&&u.hide();return}s&&s.show(),u&&u.show();var l={};this.makeElOption(l,a,t,e,i);var f=l.graphicKey;f!==this._lastGraphicKey&&this.clear(i),this._lastGraphicKey=f;var h=this._moveAnimation=this.determineAnimation(t,e);if(!s)s=this._group=new gt,this.createPointerEl(s,l,t,e),this.createLabelEl(s,l,t,e),i.getZr().add(s);else{var v=ot(fg,e,h);this.updatePointerEl(s,l,v),this.updateLabelEl(s,l,v,e)}vg(s,e,!0),this._renderHandle(a)}},r.prototype.remove=function(t){this.clear(t)},r.prototype.dispose=function(t){this.clear(t)},r.prototype.determineAnimation=function(t,e){var i=e.get("animation"),n=t.axis,a=n.type==="category",o=e.get("snap");if(!o&&!a)return!1;if(i==="auto"||i==null){var s=this.animationThreshold;if(a&&n.getBandWidth()>s)return!0;if(o){var u=vv(t).seriesDataCount,l=n.getExtent();return Math.abs(l[0]-l[1])/u>s}return!1}return i===!0},r.prototype.makeElOption=function(t,e,i,n,a){},r.prototype.createPointerEl=function(t,e,i,n){var a=e.pointer;if(a){var o=ai(t).pointerEl=new bx[a.type](lg(e.pointer));t.add(o)}},r.prototype.createLabelEl=function(t,e,i,n){if(e.label){var a=ai(t).labelEl=new te(lg(e.label));t.add(a),hg(a,n)}},r.prototype.updatePointerEl=function(t,e,i){var n=ai(t).pointerEl;n&&e.pointer&&(n.setStyle(e.pointer.style),i(n,{shape:e.pointer.shape}))},r.prototype.updateLabelEl=function(t,e,i,n){var a=ai(t).labelEl;a&&(a.setStyle(e.label.style),i(a,{x:e.label.x,y:e.label.y}),hg(a,n))},r.prototype._renderHandle=function(t){if(!(this._dragging||!this.updateHandleTransform)){var e=this._axisPointerModel,i=this._api.getZr(),n=this._handle,a=e.getModel("handle"),o=e.get("status");if(!a.get("show")||!o||o==="hide"){n&&i.remove(n),this._handle=null;return}var s;this._handle||(s=!0,n=this._handle=Sm(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(l){hn(l.event)},onmousedown:Bl(this._onHandleDragMove,this,0,0),drift:Bl(this._onHandleDragMove,this),ondragend:Bl(this._onHandleDragEnd,this)}),i.add(n)),vg(n,e,!1),n.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var u=a.get("size");B(u)||(u=[u,u]),n.scaleX=u[0]/2,n.scaleY=u[1]/2,Ha(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,s)}},r.prototype._moveHandleToValue=function(t,e){fg(this._axisPointerModel,!e&&this._moveAnimation,this._handle,Nl(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},r.prototype._onHandleDragMove=function(t,e){var i=this._handle;if(i){this._dragging=!0;var n=this.updateHandleTransform(Nl(i),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=n,i.stopAnimation(),i.attr(Nl(n)),ai(i).lastProp=null,this._doDispatchAxisPointer()}},r.prototype._doDispatchAxisPointer=function(){var t=this._handle;if(t){var e=this._payloadInfo,i=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:e.cursorPoint[0],y:e.cursorPoint[1],tooltipOption:e.tooltipOption,axesInfo:[{axisDim:i.axis.dim,axisIndex:i.componentIndex}]})}},r.prototype._onHandleDragEnd=function(){this._dragging=!1;var t=this._handle;if(t){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},r.prototype.clear=function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),i=this._group,n=this._handle;e&&i&&(this._lastGraphicKey=null,i&&e.remove(i),n&&e.remove(n),this._group=null,this._handle=null,this._payloadInfo=null),fs(this,"_doDispatchAxisPointer")},r.prototype.doClear=function(){},r.prototype.buildLabel=function(t,e,i){return i=i||0,{x:t[i],y:t[1-i],width:e[i],height:e[1-i]}},r})();function fg(r,t,e,i){j_(ai(e).lastProp,i)||(ai(e).lastProp=i,t?pe(e,i,r):(e.stopAnimation(),e.attr(i)))}function j_(r,t){if(W(r)&&W(t)){var e=!0;return T(t,function(i,n){e=e&&j_(r[n],i)}),!!e}else return r===t}function hg(r,t){r[t.get(["label","show"])?"show":"hide"]()}function Nl(r){return{x:r.x||0,y:r.y||0,rotation:r.rotation||0}}function vg(r,t,e){var i=t.get("z"),n=t.get("zlevel");r&&r.traverse(function(a){a.type!=="group"&&(i!=null&&(a.z=i),n!=null&&(a.zlevel=n),a.silent=e)})}function H2(r){var t=r.get("type"),e=r.getModel(t+"Style"),i;return t==="line"?(i=e.getLineStyle(),i.fill=null):t==="shadow"&&(i=e.getAreaStyle(),i.stroke=null),i}function G2(r,t,e,i,n){var a=e.get("value"),o=t1(a,t.axis,t.ecModel,e.get("seriesDataIndices"),{precision:e.get(["label","precision"]),formatter:e.get(["label","formatter"])}),s=e.getModel("label"),u=Hh(s.get("padding")||0),l=s.getFont(),f=Sh(o,l),h=n.position,v=f.width+u[1]+u[3],c=f.height+u[0]+u[2],p=n.align;p==="right"&&(h[0]-=v),p==="center"&&(h[0]-=v/2);var d=n.verticalAlign;d==="bottom"&&(h[1]-=c),d==="middle"&&(h[1]-=c/2),W2(h,v,c,i);var g=s.get("backgroundColor");(!g||g==="auto")&&(g=t.get(["axisLine","lineStyle","color"])),r.label={x:h[0],y:h[1],style:Lr(s,{text:o,font:l,fill:s.getTextColor(),padding:u,backgroundColor:g}),z2:10}}function W2(r,t,e,i){var n=i.getWidth(),a=i.getHeight();r[0]=Math.min(r[0]+t,n)-t,r[1]=Math.min(r[1]+e,a)-e,r[0]=Math.max(r[0],0),r[1]=Math.max(r[1],0)}function t1(r,t,e,i,n){r=t.scale.parse(r);var a=t.scale.getLabel({value:r},{precision:n.precision}),o=n.formatter;if(o){var s={value:sv(t,{value:r}),axisDimension:t.dim,axisIndex:t.index,seriesData:[]};T(i,function(u){var l=e.getSeriesByIndex(u.seriesIndex),f=u.dataIndexInside,h=l&&l.getDataParams(f);h&&s.seriesData.push(h)}),H(o)?a=o.replace("{value}",a):q(o)&&(a=o(s))}return a}function e1(r,t,e){var i=tn();return mh(i,i,e.rotation),rf(i,i,e.position),Ma([r.dataToCoord(t),(e.labelOffset||0)+(e.labelDirection||1)*(e.labelMargin||0)],i)}function U2(r,t,e,i,n,a){var o=Dr.innerTextLayout(e.rotation,0,e.labelDirection);e.labelMargin=n.get(["label","margin"]),G2(t,i,n,a,{position:e1(i.axis,r,e),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function Y2(r,t,e){return e=e||0,{x1:r[e],y1:r[1-e],x2:t[e],y2:t[1-e]}}function Z2(r,t,e){return e=e||0,{x:r[e],y:r[1-e],width:t[e],height:t[1-e]}}var X2=(function(r){O(t,r);function t(){return r!==null&&r.apply(this,arguments)||this}return t.prototype.makeElOption=function(e,i,n,a,o){var s=n.axis,u=s.grid,l=a.get("type"),f=cg(u,s).getOtherAxis(s).getGlobalExtent(),h=s.toGlobalCoord(s.dataToCoord(i,!0));if(l&&l!=="none"){var v=H2(a),c=$2[l](s,h,f);c.style=v,e.graphicKey=c.type,e.pointer=c}var p=Xf(u.model,n);U2(i,e,p,n,a,o)},t.prototype.getHandleTransform=function(e,i,n){var a=Xf(i.axis.grid.model,i,{labelInside:!1});a.labelMargin=n.get(["handle","margin"]);var o=e1(i.axis,e,a);return{x:o[0],y:o[1],rotation:a.rotation+(a.labelDirection<0?Math.PI:0)}},t.prototype.updateHandleTransform=function(e,i,n,a){var o=n.axis,s=o.grid,u=o.getGlobalExtent(!0),l=cg(s,o).getOtherAxis(o).getGlobalExtent(),f=o.dim==="x"?0:1,h=[e.x,e.y];h[f]+=i[f],h[f]=Math.min(u[1],h[f]),h[f]=Math.max(u[0],h[f]);var v=(l[1]+l[0])/2,c=[v,v];c[f]=h[f];var p=[{verticalAlign:"middle"},{align:"center"}];return{x:h[0],y:h[1],rotation:e.rotation,cursorPoint:c,tooltipOption:p[f]}},t})(V2);function cg(r,t){var e={};return e[t.dim+"AxisIndex"]=t.index,r.getCartesian(e)}var $2={line:function(r,t,e){var i=Y2([t,e[0]],[t,e[1]],pg(r));return{type:"Line",subPixelOptimize:!0,shape:i}},shadow:function(r,t,e){var i=Math.max(1,r.getBandWidth()),n=e[1]-e[0];return{type:"Rect",shape:Z2([t-i/2,e[0]],[i,n],pg(r))}}};function pg(r){return r.dim==="x"?0:1}var q2=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="axisPointer",t.defaultOption={show:"auto",z:50,type:"line",snap:!1,triggerTooltip:!0,triggerEmphasis:!0,value:null,status:null,link:[],animation:null,animationDurationUpdate:200,lineStyle:{color:"#B9BEC9",width:1,type:"dashed"},shadowStyle:{color:"rgba(210,219,238,0.2)"},label:{show:!0,formatter:null,precision:"auto",margin:3,color:"#fff",padding:[5,7,5,7],backgroundColor:"auto",borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:"#333",shadowBlur:3,shadowColor:"#aaa",shadowOffsetX:0,shadowOffsetY:2,throttle:40}},t})(nt),Ke=vt(),K2=T;function r1(r,t,e){if(!Z.node){var i=t.getZr();Ke(i).records||(Ke(i).records={}),Q2(i,t);var n=Ke(i).records[r]||(Ke(i).records[r]={});n.handler=e}}function Q2(r,t){if(Ke(r).initialized)return;Ke(r).initialized=!0,e("click",ot(dg,"click")),e("mousemove",ot(dg,"mousemove")),e("globalout",j2);function e(i,n){r.on(i,function(a){var o=tP(t);K2(Ke(r).records,function(s){s&&n(s,a,o.dispatchAction)}),J2(o.pendings,t)})}}function J2(r,t){var e=r.showTip.length,i=r.hideTip.length,n;e?n=r.showTip[e-1]:i&&(n=r.hideTip[i-1]),n&&(n.dispatchAction=null,t.dispatchAction(n))}function j2(r,t,e){r.handler("leave",null,e)}function dg(r,t,e,i){t.handler(r,e,i)}function tP(r){var t={showTip:[],hideTip:[]},e=function(i){var n=t[i.type];n?n.push(i):(i.dispatchAction=e,r.dispatchAction(i))};return{dispatchAction:e,pendings:t}}function oh(r,t){if(!Z.node){var e=t.getZr(),i=(Ke(e).records||{})[r];i&&(Ke(e).records[r]=null)}}var eP=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n){var a=i.getComponent("tooltip"),o=e.get("triggerOn")||a&&a.get("triggerOn")||"mousemove|click";r1("axisPointer",n,function(s,u,l){o!=="none"&&(s==="leave"||o.indexOf(s)>=0)&&l({type:"updateAxisPointer",currTrigger:s,x:u&&u.offsetX,y:u&&u.offsetY})})},t.prototype.remove=function(e,i){oh("axisPointer",i)},t.prototype.dispose=function(e,i){oh("axisPointer",i)},t.type="axisPointer",t})($t);function i1(r,t){var e=[],i=r.seriesIndex,n;if(i==null||!(n=t.getSeriesByIndex(i)))return{point:[]};var a=n.getData(),o=yi(a,r);if(o==null||o<0||B(o))return{point:[]};var s=a.getItemGraphicEl(o),u=n.coordinateSystem;if(n.getTooltipPosition)e=n.getTooltipPosition(o)||[];else if(u&&u.dataToPoint)if(r.isStacked){var l=u.getBaseAxis(),f=u.getOtherAxis(l),h=f.dim,v=l.dim,c=h==="x"||h==="radius"?1:0,p=a.mapDimension(v),d=[];d[c]=a.get(p,o),d[1-c]=a.get(a.getCalculationInfo("stackResultDimension"),o),e=u.dataToPoint(d)||[]}else e=u.dataToPoint(a.getValues(z(u.dimensions,function(y){return a.mapDimension(y)}),o))||[];else if(s){var g=s.getBoundingRect().clone();g.applyTransform(s.transform),e=[g.x+g.width/2,g.y+g.height/2]}return{point:e,el:s}}var gg=vt();function rP(r,t,e){var i=r.currTrigger,n=[r.x,r.y],a=r,o=r.dispatchAction||U(e.dispatchAction,e),s=t.getComponent("axisPointer").coordSysAxesInfo;if(s){Uo(n)&&(n=i1({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},t).point);var u=Uo(n),l=a.axesInfo,f=s.axesInfo,h=i==="leave"||Uo(n),v={},c={},p={list:[],map:{}},d={showPointer:ot(nP,c),showTooltip:ot(aP,p)};T(s.coordSysMap,function(y,m){var _=u||y.containPoint(n);T(s.coordSysAxesInfo[m],function(S,b){var w=S.axis,x=lP(l,S);if(!h&&_&&(!l||x)){var C=x&&x.value;C==null&&!u&&(C=w.pointToData(n)),C!=null&&yg(S,C,d,!1,v)}})});var g={};return T(f,function(y,m){var _=y.linkGroup;_&&!c[m]&&T(_.axesInfo,function(S,b){var w=c[b];if(S!==y&&w){var x=w.value;_.mapper&&(x=y.axis.scale.parse(_.mapper(x,mg(S),mg(y)))),g[y.key]=x}})}),T(g,function(y,m){yg(f[m],y,d,!0,v)}),oP(c,f,v),sP(p,n,r,o),uP(f,o,e),v}}function yg(r,t,e,i,n){var a=r.axis;if(!(a.scale.isBlank()||!a.containData(t))){if(!r.involveSeries){e.showPointer(r,t);return}var o=iP(t,r),s=o.payloadBatch,u=o.snapToValue;s[0]&&n.seriesIndex==null&&k(n,s[0]),!i&&r.snap&&a.containData(u)&&u!=null&&(t=u),e.showPointer(r,t,s),e.showTooltip(r,o,u)}}function iP(r,t){var e=t.axis,i=e.dim,n=r,a=[],o=Number.MAX_VALUE,s=-1;return T(t.seriesModels,function(u,l){var f=u.getData().mapDimensionsAll(i),h,v;if(u.getAxisTooltipData){var c=u.getAxisTooltipData(f,r,e);v=c.dataIndices,h=c.nestestValue}else{if(v=u.getData().indicesOfNearest(f[0],r,e.type==="category"?.5:null),!v.length)return;h=u.getData().get(f[0],v[0])}if(!(h==null||!isFinite(h))){var p=r-h,d=Math.abs(p);d<=o&&((d<o||p>=0&&s<0)&&(o=d,s=p,n=h,a.length=0),T(v,function(g){a.push({seriesIndex:u.seriesIndex,dataIndexInside:g,dataIndex:u.getData().getRawIndex(g)})}))}}),{payloadBatch:a,snapToValue:n}}function nP(r,t,e,i){r[t.key]={value:e,payloadBatch:i}}function aP(r,t,e,i){var n=e.payloadBatch,a=t.axis,o=a.model,s=t.axisPointerModel;if(!(!t.triggerTooltip||!n.length)){var u=t.coordSys.model,l=Ea(u),f=r.map[l];f||(f=r.map[l]={coordSysId:u.id,coordSysIndex:u.componentIndex,coordSysType:u.type,coordSysMainType:u.mainType,dataByAxis:[]},r.list.push(f)),f.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:i,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:n.slice()})}}function oP(r,t,e){var i=e.axesInfo=[];T(t,function(n,a){var o=n.axisPointerModel.option,s=r[a];s?(!n.useHandle&&(o.status="show"),o.value=s.value,o.seriesDataIndices=(s.payloadBatch||[]).slice()):!n.useHandle&&(o.status="hide"),o.status==="show"&&i.push({axisDim:n.axis.dim,axisIndex:n.axis.model.componentIndex,value:o.value})})}function sP(r,t,e,i){if(Uo(t)||!r.list.length){i({type:"hideTip"});return}var n=((r.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};i({type:"showTip",escapeConnect:!0,x:t[0],y:t[1],tooltipOption:e.tooltipOption,position:e.position,dataIndexInside:n.dataIndexInside,dataIndex:n.dataIndex,seriesIndex:n.seriesIndex,dataByCoordSys:r.list})}function uP(r,t,e){var i=e.getZr(),n="axisPointerLastHighlights",a=gg(i)[n]||{},o=gg(i)[n]={};T(r,function(l,f){var h=l.axisPointerModel.option;h.status==="show"&&l.triggerEmphasis&&T(h.seriesDataIndices,function(v){var c=v.seriesIndex+" | "+v.dataIndex;o[c]=v})});var s=[],u=[];T(a,function(l,f){!o[f]&&u.push(l)}),T(o,function(l,f){!a[f]&&s.push(l)}),u.length&&e.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:u}),s.length&&e.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function lP(r,t){for(var e=0;e<(r||[]).length;e++){var i=r[e];if(t.axis.dim===i.axisDim&&t.axis.model.componentIndex===i.axisIndex)return i}}function mg(r){var t=r.axis.model,e={},i=e.axisDim=r.axis.dim;return e.axisIndex=e[i+"AxisIndex"]=t.componentIndex,e.axisName=e[i+"AxisName"]=t.name,e.axisId=e[i+"AxisId"]=t.id,e}function Uo(r){return!r||r[0]==null||isNaN(r[0])||r[1]==null||isNaN(r[1])}function n1(r){L_.registerAxisPointerClass("CartesianAxisPointer",X2),r.registerComponentModel(q2),r.registerComponentView(eP),r.registerPreprocessor(function(t){if(t){(!t.axisPointer||t.axisPointer.length===0)&&(t.axisPointer={});var e=t.axisPointer.link;e&&!B(e)&&(t.axisPointer.link=[e])}}),r.registerProcessor(r.PRIORITY.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=nL(t,e)}),r.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},rP)}function fP(r){Pr(R_),Pr(n1)}var _g=["x","y","radius","angle","single"],hP=["cartesian2d","polar","singleAxis"];function vP(r){var t=r.get("coordinateSystem");return Q(hP,t)>=0}function br(r){return r+"Axis"}function cP(r,t){var e=X(),i=[],n=X();r.eachComponent({mainType:"dataZoom",query:t},function(f){n.get(f.uid)||s(f)});var a;do a=!1,r.eachComponent("dataZoom",o);while(a);function o(f){!n.get(f.uid)&&u(f)&&(s(f),a=!0)}function s(f){n.set(f.uid,!0),i.push(f),l(f)}function u(f){var h=!1;return f.eachTargetAxis(function(v,c){var p=e.get(v);p&&p[c]&&(h=!0)}),h}function l(f){f.eachTargetAxis(function(h,v){(e.get(h)||e.set(h,[]))[v]=!0})}return i}function a1(r){var t=r.ecModel,e={infoList:[],infoMap:X()};return r.eachTargetAxis(function(i,n){var a=t.getComponent(br(i),n);if(a){var o=a.getCoordSysModel();if(o){var s=o.uid,u=e.infoMap.get(s);u||(u={model:o,axisModels:[]},e.infoList.push(u),e.infoMap.set(s,u)),u.axisModels.push(a)}}}),e}var Fl=(function(){function r(){this.indexList=[],this.indexMap=[]}return r.prototype.add=function(t){this.indexMap[t]||(this.indexList.push(t),this.indexMap[t]=!0)},r})(),ws=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e._autoThrottle=!0,e._noTarget=!0,e._rangePropMode=["percent","percent"],e}return t.prototype.init=function(e,i,n){var a=Sg(e);this.settledOption=a,this.mergeDefaultAndTheme(e,n),this._doInit(a)},t.prototype.mergeOption=function(e){var i=Sg(e);tt(this.option,e,!0),tt(this.settledOption,i,!0),this._doInit(i)},t.prototype._doInit=function(e){var i=this.option;this._setDefaultThrottle(e),this._updateRangeUse(e);var n=this.settledOption;T([["start","startValue"],["end","endValue"]],function(a,o){this._rangePropMode[o]==="value"&&(i[a[0]]=n[a[0]]=null)},this),this._resetTarget()},t.prototype._resetTarget=function(){var e=this.get("orient",!0),i=this._targetAxisInfoMap=X(),n=this._fillSpecifiedTargetAxis(i);n?this._orient=e||this._makeAutoOrientByTargetAxis():(this._orient=e||"horizontal",this._fillAutoTargetAxisByOrient(i,this._orient)),this._noTarget=!0,i.each(function(a){a.indexList.length&&(this._noTarget=!1)},this)},t.prototype._fillSpecifiedTargetAxis=function(e){var i=!1;return T(_g,function(n){var a=this.getReferringComponents(br(n),dw);if(a.specified){i=!0;var o=new Fl;T(a.models,function(s){o.add(s.componentIndex)}),e.set(n,o)}},this),i},t.prototype._fillAutoTargetAxisByOrient=function(e,i){var n=this.ecModel,a=!0;if(a){var o=i==="vertical"?"y":"x",s=n.findComponents({mainType:o+"Axis"});u(s,o)}if(a){var s=n.findComponents({mainType:"singleAxis",filter:function(f){return f.get("orient",!0)===i}});u(s,"single")}function u(l,f){var h=l[0];if(h){var v=new Fl;if(v.add(h.componentIndex),e.set(f,v),a=!1,f==="x"||f==="y"){var c=h.getReferringComponents("grid",Ut).models[0];c&&T(l,function(p){h.componentIndex!==p.componentIndex&&c===p.getReferringComponents("grid",Ut).models[0]&&v.add(p.componentIndex)})}}}a&&T(_g,function(l){if(a){var f=n.findComponents({mainType:br(l),filter:function(v){return v.get("type",!0)==="category"}});if(f[0]){var h=new Fl;h.add(f[0].componentIndex),e.set(l,h),a=!1}}},this)},t.prototype._makeAutoOrientByTargetAxis=function(){var e;return this.eachTargetAxis(function(i){!e&&(e=i)},this),e==="y"?"vertical":"horizontal"},t.prototype._setDefaultThrottle=function(e){if(e.hasOwnProperty("throttle")&&(this._autoThrottle=!1),this._autoThrottle){var i=this.ecModel.option;this.option.throttle=i.animation&&i.animationDurationUpdate>0?100:20}},t.prototype._updateRangeUse=function(e){var i=this._rangePropMode,n=this.get("rangeMode");T([["start","startValue"],["end","endValue"]],function(a,o){var s=e[a[0]]!=null,u=e[a[1]]!=null;s&&!u?i[o]="percent":!s&&u?i[o]="value":n?i[o]=n[o]:s&&(i[o]="percent")})},t.prototype.noTarget=function(){return this._noTarget},t.prototype.getFirstTargetAxisModel=function(){var e;return this.eachTargetAxis(function(i,n){e==null&&(e=this.ecModel.getComponent(br(i),n))},this),e},t.prototype.eachTargetAxis=function(e,i){this._targetAxisInfoMap.each(function(n,a){T(n.indexList,function(o){e.call(i,a,o)})})},t.prototype.getAxisProxy=function(e,i){var n=this.getAxisModel(e,i);if(n)return n.__dzAxisProxy},t.prototype.getAxisModel=function(e,i){var n=this._targetAxisInfoMap.get(e);if(n&&n.indexMap[i])return this.ecModel.getComponent(br(e),i)},t.prototype.setRawRange=function(e){var i=this.option,n=this.settledOption;T([["start","startValue"],["end","endValue"]],function(a){(e[a[0]]!=null||e[a[1]]!=null)&&(i[a[0]]=n[a[0]]=e[a[0]],i[a[1]]=n[a[1]]=e[a[1]])},this),this._updateRangeUse(e)},t.prototype.setCalculatedRange=function(e){var i=this.option;T(["start","startValue","end","endValue"],function(n){i[n]=e[n]})},t.prototype.getPercentRange=function(){var e=this.findRepresentativeAxisProxy();if(e)return e.getDataPercentWindow()},t.prototype.getValueRange=function(e,i){if(e==null&&i==null){var n=this.findRepresentativeAxisProxy();if(n)return n.getDataValueWindow()}else return this.getAxisProxy(e,i).getDataValueWindow()},t.prototype.findRepresentativeAxisProxy=function(e){if(e)return e.__dzAxisProxy;for(var i,n=this._targetAxisInfoMap.keys(),a=0;a<n.length;a++)for(var o=n[a],s=this._targetAxisInfoMap.get(o),u=0;u<s.indexList.length;u++){var l=this.getAxisProxy(o,s.indexList[u]);if(l.hostedBy(this))return l;i||(i=l)}return i},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})(nt);function Sg(r){var t={};return T(["start","end","startValue","endValue","throttle"],function(e){r.hasOwnProperty(e)&&(t[e]=r[e])}),t}var o1=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.render=function(e,i,n,a){this.dataZoomModel=e,this.ecModel=i,this.api=n},t.type="dataZoom",t})($t),Zi=T,wg=oi,pP=(function(){function r(t,e,i,n){this._dimName=t,this._axisIndex=e,this.ecModel=n,this._dataZoomModel=i}return r.prototype.hostedBy=function(t){return this._dataZoomModel===t},r.prototype.getDataValueWindow=function(){return this._valueWindow.slice()},r.prototype.getDataPercentWindow=function(){return this._percentWindow.slice()},r.prototype.getTargetSeriesModels=function(){var t=[];return this.ecModel.eachSeries(function(e){if(vP(e)){var i=br(this._dimName),n=e.getReferringComponents(i,Ut).models[0];n&&this._axisIndex===n.componentIndex&&t.push(e)}},this),t},r.prototype.getAxisModel=function(){return this.ecModel.getComponent(this._dimName+"Axis",this._axisIndex)},r.prototype.getMinMaxSpan=function(){return Y(this._minMaxSpan)},r.prototype.calculateDataWindow=function(t){var e=this._dataExtent,i=this.getAxisModel(),n=i.axis.scale,a=this._dataZoomModel.getRangePropMode(),o=[0,100],s=[],u=[],l;Zi(["start","end"],function(v,c){var p=t[v],d=t[v+"Value"];a[c]==="percent"?(p==null&&(p=o[c]),d=n.parse(bt(p,o,e))):(l=!0,d=d==null?e[c]:n.parse(d),p=bt(d,e,o)),u[c]=d==null||isNaN(d)?e[c]:d,s[c]=p==null||isNaN(p)?o[c]:p}),wg(u),wg(s);var f=this._minMaxSpan;l?h(u,s,e,o,!1):h(s,u,o,e,!0);function h(v,c,p,d,g){var y=g?"Span":"ValueSpan";uu(0,v,p,"all",f["min"+y],f["max"+y]);for(var m=0;m<2;m++)c[m]=bt(v[m],p,d,!0),g&&(c[m]=n.parse(c[m]))}return{valueWindow:u,percentWindow:s}},r.prototype.reset=function(t){if(t===this._dataZoomModel){var e=this.getTargetSeriesModels();this._dataExtent=dP(this,this._dimName,e),this._updateMinMaxSpan();var i=this.calculateDataWindow(t.settledOption);this._valueWindow=i.valueWindow,this._percentWindow=i.percentWindow,this._setAxisModel()}},r.prototype.filterData=function(t,e){if(t!==this._dataZoomModel)return;var i=this._dimName,n=this.getTargetSeriesModels(),a=t.get("filterMode"),o=this._valueWindow;if(a==="none")return;Zi(n,function(u){var l=u.getData(),f=l.mapDimensionsAll(i);if(f.length){if(a==="weakFilter"){var h=l.getStore(),v=z(f,function(c){return l.getDimensionIndex(c)},l);l.filterSelf(function(c){for(var p,d,g,y=0;y<f.length;y++){var m=h.get(v[y],c),_=!isNaN(m),S=m<o[0],b=m>o[1];if(_&&!S&&!b)return!0;_&&(g=!0),S&&(p=!0),b&&(d=!0)}return g&&p&&d})}else Zi(f,function(c){if(a==="empty")u.setData(l=l.map(c,function(d){return s(d)?d:NaN}));else{var p={};p[c]=o,l.selectRange(p)}});Zi(f,function(c){l.setApproximateExtent(o,c)})}});function s(u){return u>=o[0]&&u<=o[1]}},r.prototype._updateMinMaxSpan=function(){var t=this._minMaxSpan={},e=this._dataZoomModel,i=this._dataExtent;Zi(["min","max"],function(n){var a=e.get(n+"Span"),o=e.get(n+"ValueSpan");o!=null&&(o=this.getAxisModel().axis.scale.parse(o)),o!=null?a=bt(i[0]+o,i,[0,100],!0):a!=null&&(o=bt(a,[0,100],i,!0)-i[0]),t[n+"Span"]=a,t[n+"ValueSpan"]=o},this)},r.prototype._setAxisModel=function(){var t=this.getAxisModel(),e=this._percentWindow,i=this._valueWindow;if(e){var n=Ly(i,[0,500]);n=Math.min(n,20);var a=t.axis.scale.rawExtentInfo;e[0]!==0&&a.setDeterminedMinMax("min",+i[0].toFixed(n)),e[1]!==100&&a.setDeterminedMinMax("max",+i[1].toFixed(n)),a.freeze()}},r})();function dP(r,t,e){var i=[1/0,-1/0];Zi(e,function(o){kD(i,o.getData(),t)});var n=r.getAxisModel(),a=n_(n.axis.scale,n,i).calculate();return[a.min,a.max]}var gP={getTargetSeries:function(r){function t(n){r.eachComponent("dataZoom",function(a){a.eachTargetAxis(function(o,s){var u=r.getComponent(br(o),s);n(o,s,u,a)})})}t(function(n,a,o,s){o.__dzAxisProxy=null});var e=[];t(function(n,a,o,s){o.__dzAxisProxy||(o.__dzAxisProxy=new pP(n,a,s,r),e.push(o.__dzAxisProxy))});var i=X();return T(e,function(n){T(n.getTargetSeriesModels(),function(a){i.set(a.uid,a)})}),i},overallReset:function(r,t){r.eachComponent("dataZoom",function(e){e.eachTargetAxis(function(i,n){e.getAxisProxy(i,n).reset(e)}),e.eachTargetAxis(function(i,n){e.getAxisProxy(i,n).filterData(e,t)})}),r.eachComponent("dataZoom",function(e){var i=e.findRepresentativeAxisProxy();if(i){var n=i.getDataPercentWindow(),a=i.getDataValueWindow();e.setCalculatedRange({start:n[0],end:n[1],startValue:a[0],endValue:a[1]})}})}};function yP(r){r.registerAction("dataZoom",function(t,e){var i=cP(e,t);T(i,function(n){n.setRawRange({start:t.start,end:t.end,startValue:t.startValue,endValue:t.endValue})})})}var bg=!1;function s1(r){bg||(bg=!0,r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,gP),yP(r),r.registerSubTypeDefaulter("dataZoom",function(){return"slider"}))}var mP=["grid","xAxis","yAxis","geo","graph","polar","radiusAxis","angleAxis","bmap"],_P=(function(){function r(t,e,i){var n=this;this._targetInfoList=[];var a=xg(e,t);T(SP,function(o,s){(!i||!i.include||Q(i.include,s)>=0)&&o(a,n._targetInfoList)})}return r.prototype.setOutputRanges=function(t,e){return this.matchOutputRanges(t,e,function(i,n,a){if((i.coordRanges||(i.coordRanges=[])).push(n),!i.coordRange){i.coordRange=n;var o=zl[i.brushType](0,a,n);i.__rangeOffset={offset:Dg[i.brushType](o.values,i.range,[1,1]),xyMinMax:o.xyMinMax}}}),t},r.prototype.matchOutputRanges=function(t,e,i){T(t,function(n){var a=this.findTargetInfo(n,e);a&&a!==!0&&T(a.coordSyses,function(o){var s=zl[n.brushType](1,o,n.range,!0);i(n,s.values,o,e)})},this)},r.prototype.setInputRanges=function(t,e){T(t,function(i){var n=this.findTargetInfo(i,e);if(i.range=i.range||[],n&&n!==!0){i.panelId=n.panelId;var a=zl[i.brushType](0,n.coordSys,i.coordRange),o=i.__rangeOffset;i.range=o?Dg[i.brushType](a.values,o.offset,wP(a.xyMinMax,o.xyMinMax)):a.values}},this)},r.prototype.makePanelOpts=function(t,e){return z(this._targetInfoList,function(i){var n=i.getPanelRect();return{panelId:i.panelId,defaultBrushType:e?e(i):null,clipPath:qL(n),isTargetByCursor:QL(n,t,i.coordSysModel),getLinearBrushOtherExtent:KL(n)}})},r.prototype.controlSeries=function(t,e,i){var n=this.findTargetInfo(t,i);return n===!0||n&&Q(n.coordSyses,e.coordinateSystem)>=0},r.prototype.findTargetInfo=function(t,e){for(var i=this._targetInfoList,n=xg(e,t),a=0;a<i.length;a++){var o=i[a],s=t.panelId;if(s){if(o.panelId===s)return o}else for(var u=0;u<Tg.length;u++)if(Tg[u](n,o))return o}return!0},r})();function sh(r){return r[0]>r[1]&&r.reverse(),r}function xg(r,t){return No(r,t,{includeMainTypes:mP})}var SP={grid:function(r,t){var e=r.xAxisModels,i=r.yAxisModels,n=r.gridModels,a=X(),o={},s={};!e&&!i&&!n||(T(e,function(u){var l=u.axis.grid.model;a.set(l.id,l),o[l.id]=!0}),T(i,function(u){var l=u.axis.grid.model;a.set(l.id,l),s[l.id]=!0}),T(n,function(u){a.set(u.id,u),o[u.id]=!0,s[u.id]=!0}),a.each(function(u){var l=u.coordinateSystem,f=[];T(l.getCartesians(),function(h,v){(Q(e,h.getAxis("x").model)>=0||Q(i,h.getAxis("y").model)>=0)&&f.push(h)}),t.push({panelId:"grid--"+u.id,gridModel:u,coordSysModel:u,coordSys:f[0],coordSyses:f,getPanelRect:Mg.grid,xAxisDeclared:o[u.id],yAxisDeclared:s[u.id]})}))},geo:function(r,t){T(r.geoModels,function(e){var i=e.coordinateSystem;t.push({panelId:"geo--"+e.id,geoModel:e,coordSysModel:e,coordSys:i,coordSyses:[i],getPanelRect:Mg.geo})})}},Tg=[function(r,t){var e=r.xAxisModel,i=r.yAxisModel,n=r.gridModel;return!n&&e&&(n=e.axis.grid.model),!n&&i&&(n=i.axis.grid.model),n&&n===t.gridModel},function(r,t){var e=r.geoModel;return e&&e===t.geoModel}],Mg={grid:function(){return this.coordSys.master.getRect().clone()},geo:function(){var r=this.coordSys,t=r.getBoundingRect().clone();return t.applyTransform(Ws(r)),t}},zl={lineX:ot(Cg,0),lineY:ot(Cg,1),rect:function(r,t,e,i){var n=r?t.pointToData([e[0][0],e[1][0]],i):t.dataToPoint([e[0][0],e[1][0]],i),a=r?t.pointToData([e[0][1],e[1][1]],i):t.dataToPoint([e[0][1],e[1][1]],i),o=[sh([n[0],a[0]]),sh([n[1],a[1]])];return{values:o,xyMinMax:o}},polygon:function(r,t,e,i){var n=[[1/0,-1/0],[1/0,-1/0]],a=z(e,function(o){var s=r?t.pointToData(o,i):t.dataToPoint(o,i);return n[0][0]=Math.min(n[0][0],s[0]),n[1][0]=Math.min(n[1][0],s[1]),n[0][1]=Math.max(n[0][1],s[0]),n[1][1]=Math.max(n[1][1],s[1]),s});return{values:a,xyMinMax:n}}};function Cg(r,t,e,i){var n=e.getAxis(["x","y"][r]),a=sh(z([0,1],function(s){return t?n.coordToData(n.toLocalCoord(i[s]),!0):n.toGlobalCoord(n.dataToCoord(i[s]))})),o=[];return o[r]=a,o[1-r]=[NaN,NaN],{values:a,xyMinMax:o}}var Dg={lineX:ot(Ag,0),lineY:ot(Ag,1),rect:function(r,t,e){return[[r[0][0]-e[0]*t[0][0],r[0][1]-e[0]*t[0][1]],[r[1][0]-e[1]*t[1][0],r[1][1]-e[1]*t[1][1]]]},polygon:function(r,t,e){return z(r,function(i,n){return[i[0]-e[0]*t[n][0],i[1]-e[1]*t[n][1]]})}};function Ag(r,t,e,i){return[t[0]-i[r]*e[0],t[1]-i[r]*e[1]]}function wP(r,t){var e=Lg(r),i=Lg(t),n=[e[0]/i[0],e[1]/i[1]];return isNaN(n[0])&&(n[0]=1),isNaN(n[1])&&(n[1]=1),n}function Lg(r){return r?[r[0][1]-r[0][0],r[1][1]-r[1][0]]:[NaN,NaN]}var bP=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="tooltip",t.dependencies=["axisPointer"],t.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click",alwaysShowContent:!1,displayMode:"single",renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,enterable:!1,backgroundColor:"#fff",shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:"#999",width:1,type:"dashed",textStyle:{}}},textStyle:{color:"#666",fontSize:14}},t})(nt);function u1(r){var t=r.get("confine");return t!=null?!!t:r.get("renderMode")==="richText"}function l1(r){if(Z.domSupported){for(var t=document.documentElement.style,e=0,i=r.length;e<i;e++)if(r[e]in t)return r[e]}}var f1=l1(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),xP=l1(["webkitTransition","transition","OTransition","MozTransition","msTransition"]);function h1(r,t){if(!r)return t;t=Fm(t,!0);var e=r.indexOf(t);return r=e===-1?t:"-"+r.slice(0,e)+"-"+t,r.toLowerCase()}function TP(r,t){var e=r.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(r);return e?e[t]:null}var MP=h1(xP,"transition"),Av=h1(f1,"transform"),CP="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(Z.transform3dSupported?"will-change:transform;":"");function DP(r){return r=r==="left"?"right":r==="right"?"left":r==="top"?"bottom":"top",r}function AP(r,t,e){if(!H(e)||e==="inside")return"";var i=r.get("backgroundColor"),n=r.get("borderWidth");t=_i(t);var a=DP(e),o=Math.max(Math.round(n)*1.5,6),s="",u=Av+":",l;Q(["left","right"],a)>-1?(s+="top:50%",u+="translateY(-50%) rotate("+(l=a==="left"?-225:-45)+"deg)"):(s+="left:50%",u+="translateX(-50%) rotate("+(l=a==="top"?225:45)+"deg)");var f=l*Math.PI/180,h=o+n,v=h*Math.abs(Math.cos(f))+h*Math.abs(Math.sin(f)),c=Math.round(((v-Math.SQRT2*n)/2+Math.SQRT2*n-(v-h)/2)*100)/100;s+=";"+a+":-"+c+"px";var p=t+" solid "+n+"px;",d=["position:absolute;width:"+o+"px;height:"+o+"px;z-index:-1;",s+";"+u+";","border-bottom:"+p,"border-right:"+p,"background-color:"+i+";"];return'<div style="'+d.join("")+'"></div>'}function LP(r,t){var e="cubic-bezier(0.23,1,0.32,1)",i=" "+r/2+"s "+e,n="opacity"+i+",visibility"+i;return t||(i=" "+r+"s "+e,n+=Z.transformSupported?","+Av+i:",left"+i+",top"+i),MP+":"+n}function Pg(r,t,e){var i=r.toFixed(0)+"px",n=t.toFixed(0)+"px";if(!Z.transformSupported)return e?"top:"+n+";left:"+i+";":[["top",n],["left",i]];var a=Z.transform3dSupported,o="translate"+(a?"3d":"")+"("+i+","+n+(a?",0":"")+")";return e?"top:0;left:0;"+Av+":"+o+";":[["top",0],["left",0],[f1,o]]}function PP(r){var t=[],e=r.get("fontSize"),i=r.getTextColor();i&&t.push("color:"+i),t.push("font:"+r.getFont());var n=$(r.get("lineHeight"),Math.round(e*3/2));e&&t.push("line-height:"+n+"px");var a=r.get("textShadowColor"),o=r.get("textShadowBlur")||0,s=r.get("textShadowOffsetX")||0,u=r.get("textShadowOffsetY")||0;return a&&o&&t.push("text-shadow:"+s+"px "+u+"px "+o+"px "+a),T(["decoration","align"],function(l){var f=r.get(l);f&&t.push("text-"+l+":"+f)}),t.join(";")}function IP(r,t,e){var i=[],n=r.get("transitionDuration"),a=r.get("backgroundColor"),o=r.get("shadowBlur"),s=r.get("shadowColor"),u=r.get("shadowOffsetX"),l=r.get("shadowOffsetY"),f=r.getModel("textStyle"),h=h0(r,"html"),v=u+"px "+l+"px "+o+"px "+s;return i.push("box-shadow:"+v),t&&n&&i.push(LP(n,e)),a&&i.push("background-color:"+a),T(["width","color","radius"],function(c){var p="border-"+c,d=Fm(p),g=r.get(d);g!=null&&i.push(p+":"+g+(c==="color"?"":"px"))}),i.push(PP(f)),h!=null&&i.push("padding:"+Hh(h).join("px ")+"px"),i.join(";")+";"}function Ig(r,t,e,i,n){var a=t&&t.painter;if(e){var o=a&&a.getViewportRoot();o&&Z1(r,o,e,i,n)}else{r[0]=i,r[1]=n;var s=a&&a.getViewportRootOffset();s&&(r[0]+=s.offsetLeft,r[1]+=s.offsetTop)}r[2]=r[0]/t.getWidth(),r[3]=r[1]/t.getHeight()}var RP=(function(){function r(t,e){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,Z.wxa)return null;var i=document.createElement("div");i.domBelongToZr=!0,this.el=i;var n=this._zr=t.getZr(),a=e.appendTo,o=a&&(H(a)?document.querySelector(a):ma(a)?a:q(a)&&a(t.getDom()));Ig(this._styleCoord,n,o,t.getWidth()/2,t.getHeight()/2),(o||t.getDom()).appendChild(i),this._api=t,this._container=o;var s=this;i.onmouseenter=function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0},i.onmousemove=function(u){if(u=u||window.event,!s._enterable){var l=n.handler,f=n.painter.getViewportRoot();ae(f,u,!0),l.dispatch("mousemove",u)}},i.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return r.prototype.update=function(t){if(!this._container){var e=this._api.getDom(),i=TP(e,"position"),n=e.style;n.position!=="absolute"&&i!=="absolute"&&(n.position="relative")}var a=t.get("alwaysShowContent");a&&this._moveIfResized(),this._alwaysShowContent=a,this.el.className=t.get("className")||""},r.prototype.show=function(t,e){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var i=this.el,n=i.style,a=this._styleCoord;i.innerHTML?n.cssText=CP+IP(t,!this._firstShow,this._longHide)+Pg(a[0],a[1],!0)+("border-color:"+_i(e)+";")+(t.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):n.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},r.prototype.setContent=function(t,e,i,n,a){var o=this.el;if(t==null){o.innerHTML="";return}var s="";if(H(a)&&i.get("trigger")==="item"&&!u1(i)&&(s=AP(i,n,a)),H(t))o.innerHTML=t+s;else if(t){o.innerHTML="",B(t)||(t=[t]);for(var u=0;u<t.length;u++)ma(t[u])&&t[u].parentNode!==o&&o.appendChild(t[u]);if(s&&o.childNodes.length){var l=document.createElement("div");l.innerHTML=s,o.appendChild(l)}}},r.prototype.setEnterable=function(t){this._enterable=t},r.prototype.getSize=function(){var t=this.el;return t?[t.offsetWidth,t.offsetHeight]:[0,0]},r.prototype.moveTo=function(t,e){if(this.el){var i=this._styleCoord;if(Ig(i,this._zr,this._container,t,e),i[0]!=null&&i[1]!=null){var n=this.el.style,a=Pg(i[0],i[1]);T(a,function(o){n[o[0]]=o[1]})}}},r.prototype._moveIfResized=function(){var t=this._styleCoord[2],e=this._styleCoord[3];this.moveTo(t*this._zr.getWidth(),e*this._zr.getHeight())},r.prototype.hide=function(){var t=this,e=this.el.style;e.visibility="hidden",e.opacity="0",Z.transform3dSupported&&(e.willChange=""),this._show=!1,this._longHideTimeout=setTimeout(function(){return t._longHide=!0},500)},r.prototype.hideLater=function(t){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(U(this.hide,this),t)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var t=this.el.parentNode;t&&t.removeChild(this.el),this.el=this._container=null},r})(),EP=(function(){function r(t){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=t.getZr(),Eg(this._styleCoord,this._zr,t.getWidth()/2,t.getHeight()/2)}return r.prototype.update=function(t){var e=t.get("alwaysShowContent");e&&this._moveIfResized(),this._alwaysShowContent=e},r.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},r.prototype.setContent=function(t,e,i,n,a){var o=this;W(t)&&Ft(""),this.el&&this._zr.remove(this.el);var s=i.getModel("textStyle");this.el=new te({style:{rich:e.richTextStyles,text:t,lineHeight:22,borderWidth:1,borderColor:n,textShadowColor:s.get("textShadowColor"),fill:i.get(["textStyle","color"]),padding:h0(i,"richText"),verticalAlign:"top",align:"left"},z:i.get("z")}),T(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],function(l){o.el.style[l]=i.get(l)}),T(["textShadowBlur","textShadowOffsetX","textShadowOffsetY"],function(l){o.el.style[l]=s.get(l)||0}),this._zr.add(this.el);var u=this;this.el.on("mouseover",function(){u._enterable&&(clearTimeout(u._hideTimeout),u._show=!0),u._inContent=!0}),this.el.on("mouseout",function(){u._enterable&&u._show&&u.hideLater(u._hideDelay),u._inContent=!1})},r.prototype.setEnterable=function(t){this._enterable=t},r.prototype.getSize=function(){var t=this.el,e=this.el.getBoundingRect(),i=Rg(t.style);return[e.width+i.left+i.right,e.height+i.top+i.bottom]},r.prototype.moveTo=function(t,e){var i=this.el;if(i){var n=this._styleCoord;Eg(n,this._zr,t,e),t=n[0],e=n[1];var a=i.style,o=yr(a.borderWidth||0),s=Rg(a);i.x=t+o+s.left,i.y=e+o+s.top,i.markRedraw()}},r.prototype._moveIfResized=function(){var t=this._styleCoord[2],e=this._styleCoord[3];this.moveTo(t*this._zr.getWidth(),e*this._zr.getHeight())},r.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},r.prototype.hideLater=function(t){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(U(this.hide,this),t)):this.hide())},r.prototype.isShow=function(){return this._show},r.prototype.dispose=function(){this._zr.remove(this.el)},r})();function yr(r){return Math.max(0,r)}function Rg(r){var t=yr(r.shadowBlur||0),e=yr(r.shadowOffsetX||0),i=yr(r.shadowOffsetY||0);return{left:yr(t-e),right:yr(t+e),top:yr(t-i),bottom:yr(t+i)}}function Eg(r,t,e,i){r[0]=e,r[1]=i,r[2]=r[0]/t.getWidth(),r[3]=r[1]/t.getHeight()}var kP=new Tt({shape:{x:-1,y:-1,width:2,height:2}}),OP=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(e,i){if(!(Z.node||!i.getDom())){var n=e.getComponent("tooltip"),a=this._renderMode=yw(n.get("renderMode"));this._tooltipContent=a==="richText"?new EP(i):new RP(i,{appendTo:n.get("appendToBody",!0)?"body":n.get("appendTo",!0)})}},t.prototype.render=function(e,i,n){if(!(Z.node||!n.getDom())){this.group.removeAll(),this._tooltipModel=e,this._ecModel=i,this._api=n;var a=this._tooltipContent;a.update(e),a.setEnterable(e.get("enterable")),this._initGlobalListener(),this._keepShow(),this._renderMode!=="richText"&&e.get("transitionDuration")?Ha(this,"_updatePosition",50,"fixRate"):fs(this,"_updatePosition")}},t.prototype._initGlobalListener=function(){var e=this._tooltipModel,i=e.get("triggerOn");r1("itemTooltip",this._api,U(function(n,a,o){i!=="none"&&(i.indexOf(n)>=0?this._tryShow(a,o):n==="leave"&&this._hide(o))},this))},t.prototype._keepShow=function(){var e=this._tooltipModel,i=this._ecModel,n=this._api,a=e.get("triggerOn");if(this._lastX!=null&&this._lastY!=null&&a!=="none"&&a!=="click"){var o=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!n.isDisposed()&&o.manuallyShowTip(e,i,n,{x:o._lastX,y:o._lastY,dataByCoordSys:o._lastDataByCoordSys})})}},t.prototype.manuallyShowTip=function(e,i,n,a){if(!(a.from===this.uid||Z.node||!n.getDom())){var o=kg(a,n);this._ticket="";var s=a.dataByCoordSys,u=zP(a,i,n);if(u){var l=u.el.getBoundingRect().clone();l.applyTransform(u.el.transform),this._tryShow({offsetX:l.x+l.width/2,offsetY:l.y+l.height/2,target:u.el,position:a.position,positionDefault:"bottom"},o)}else if(a.tooltip&&a.x!=null&&a.y!=null){var f=kP;f.x=a.x,f.y=a.y,f.update(),at(f).tooltipConfig={name:null,option:a.tooltip},this._tryShow({offsetX:a.x,offsetY:a.y,target:f},o)}else if(s)this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,dataByCoordSys:s,tooltipOption:a.tooltipOption},o);else if(a.seriesIndex!=null){if(this._manuallyAxisShowTip(e,i,n,a))return;var h=i1(a,i),v=h.point[0],c=h.point[1];v!=null&&c!=null&&this._tryShow({offsetX:v,offsetY:c,target:h.el,position:a.position,positionDefault:"bottom"},o)}else a.x!=null&&a.y!=null&&(n.dispatchAction({type:"updateAxisPointer",x:a.x,y:a.y}),this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,target:n.getZr().findHover(a.x,a.y).target},o))}},t.prototype.manuallyHideTip=function(e,i,n,a){var o=this._tooltipContent;this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,a.from!==this.uid&&this._hide(kg(a,n))},t.prototype._manuallyAxisShowTip=function(e,i,n,a){var o=a.seriesIndex,s=a.dataIndex,u=i.getComponent("axisPointer").coordSysAxesInfo;if(!(o==null||s==null||u==null)){var l=i.getSeriesByIndex(o);if(l){var f=l.getData(),h=Zn([f.getItemModel(s),l,(l.coordinateSystem||{}).model],this._tooltipModel);if(h.get("trigger")==="axis")return n.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:s,position:a.position}),!0}}},t.prototype._tryShow=function(e,i){var n=e.target,a=this._tooltipModel;if(a){this._lastX=e.offsetX,this._lastY=e.offsetY;var o=e.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,e);else if(n){var s=at(n);if(s.ssrType==="legend")return;this._lastDataByCoordSys=null;var u,l;ia(n,function(f){if(at(f).dataIndex!=null)return u=f,!0;if(at(f).tooltipConfig!=null)return l=f,!0},!0),u?this._showSeriesItemTooltip(e,u,i):l?this._showComponentItemTooltip(e,l,i):this._hide(i)}else this._lastDataByCoordSys=null,this._hide(i)}},t.prototype._showOrMove=function(e,i){var n=e.get("showDelay");i=U(i,this),clearTimeout(this._showTimout),n>0?this._showTimout=setTimeout(i,n):i()},t.prototype._showAxisTooltip=function(e,i){var n=this._ecModel,a=this._tooltipModel,o=[i.offsetX,i.offsetY],s=Zn([i.tooltipOption],a),u=this._renderMode,l=[],f=Si("section",{blocks:[],noHeader:!0}),h=[],v=new al;T(e,function(m){T(m.dataByAxis,function(_){var S=n.getComponent(_.axisDim+"Axis",_.axisIndex),b=_.value;if(!(!S||b==null)){var w=t1(b,S.axis,n,_.seriesDataIndices,_.valueLabelOpt),x=Si("section",{header:w,noHeader:!Oe(w),sortBlocks:!0,blocks:[]});f.blocks.push(x),T(_.seriesDataIndices,function(C){var M=n.getSeriesByIndex(C.seriesIndex),D=C.dataIndexInside,A=M.getDataParams(D);if(!(A.dataIndex<0)){A.axisDim=_.axisDim,A.axisIndex=_.axisIndex,A.axisType=_.axisType,A.axisId=_.axisId,A.axisValue=sv(S.axis,{value:b}),A.axisValueLabel=w,A.marker=v.makeTooltipMarker("item",_i(A.color),u);var P=_p(M.formatTooltip(D,!0,null)),R=P.frag;if(R){var L=Zn([M],a).get("valueFormatter");x.blocks.push(L?k({valueFormatter:L},R):R)}P.text&&h.push(P.text),l.push(A)}})}})}),f.blocks.reverse(),h.reverse();var c=i.position,p=s.get("order"),d=Tp(f,v,u,p,n.get("useUTC"),s.get("textStyle"));d&&h.unshift(d);var g=u==="richText"?`
36
+
37
+ `:"<br/>",y=h.join(g);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(e,l)?this._updatePosition(s,c,o[0],o[1],this._tooltipContent,l):this._showTooltipContent(s,y,l,Math.random()+"",o[0],o[1],c,null,v)})},t.prototype._showSeriesItemTooltip=function(e,i,n){var a=this._ecModel,o=at(i),s=o.seriesIndex,u=a.getSeriesByIndex(s),l=o.dataModel||u,f=o.dataIndex,h=o.dataType,v=l.getData(h),c=this._renderMode,p=e.positionDefault,d=Zn([v.getItemModel(f),l,u&&(u.coordinateSystem||{}).model],this._tooltipModel,p?{position:p}:null),g=d.get("trigger");if(!(g!=null&&g!=="item")){var y=l.getDataParams(f,h),m=new al;y.marker=m.makeTooltipMarker("item",_i(y.color),c);var _=_p(l.formatTooltip(f,!1,h)),S=d.get("order"),b=d.get("valueFormatter"),w=_.frag,x=w?Tp(b?k({valueFormatter:b},w):w,m,c,S,a.get("useUTC"),d.get("textStyle")):_.text,C="item_"+l.name+"_"+f;this._showOrMove(d,function(){this._showTooltipContent(d,x,y,C,e.offsetX,e.offsetY,e.position,e.target,m)}),n({type:"showTip",dataIndexInside:f,dataIndex:v.getRawIndex(f),seriesIndex:s,from:this.uid})}},t.prototype._showComponentItemTooltip=function(e,i,n){var a=this._renderMode==="html",o=at(i),s=o.tooltipConfig,u=s.option||{},l=u.encodeHTMLContent;if(H(u)){var f=u;u={content:f,formatter:f},l=!0}l&&a&&u.content&&(u=Y(u),u.content=Gt(u.content));var h=[u],v=this._ecModel.getComponent(o.componentMainType,o.componentIndex);v&&h.push(v),h.push({formatter:u.content});var c=e.positionDefault,p=Zn(h,this._tooltipModel,c?{position:c}:null),d=p.get("content"),g=Math.random()+"",y=new al;this._showOrMove(p,function(){var m=Y(p.get("formatterParams")||{});this._showTooltipContent(p,d,m,g,e.offsetX,e.offsetY,e.position,i,y)}),n({type:"showTip",from:this.uid})},t.prototype._showTooltipContent=function(e,i,n,a,o,s,u,l,f){if(this._ticket="",!(!e.get("showContent")||!e.get("show"))){var h=this._tooltipContent;h.setEnterable(e.get("enterable"));var v=e.get("formatter");u=u||e.get("position");var c=i,p=this._getNearestPoint([o,s],n,e.get("trigger"),e.get("borderColor")),d=p.color;if(v)if(H(v)){var g=e.ecModel.get("useUTC"),y=B(n)?n[0]:n,m=y&&y.axisType&&y.axisType.indexOf("time")>=0;c=v,m&&(c=$s(y.axisValue,c,g)),c=zm(c,n,!0)}else if(q(v)){var _=U(function(S,b){S===this._ticket&&(h.setContent(b,f,e,d,u),this._updatePosition(e,u,o,s,h,n,l))},this);this._ticket=a,c=v(n,a,_)}else c=v;h.setContent(c,f,e,d,u),h.show(e,d),this._updatePosition(e,u,o,s,h,n,l)}},t.prototype._getNearestPoint=function(e,i,n,a){if(n==="axis"||B(i))return{color:a||(this._renderMode==="html"?"#fff":"none")};if(!B(i))return{color:a||i.color||i.borderColor}},t.prototype._updatePosition=function(e,i,n,a,o,s,u){var l=this._api.getWidth(),f=this._api.getHeight();i=i||e.get("position");var h=o.getSize(),v=e.get("align"),c=e.get("verticalAlign"),p=u&&u.getBoundingRect().clone();if(u&&p.applyTransform(u.transform),q(i)&&(i=i([n,a],s,o.el,p,{viewSize:[l,f],contentSize:h.slice()})),B(i))n=yt(i[0],l),a=yt(i[1],f);else if(W(i)){var d=i;d.width=h[0],d.height=h[1];var g=Gh(d,{width:l,height:f});n=g.x,a=g.y,v=null,c=null}else if(H(i)&&u){var y=FP(i,p,h,e.get("borderWidth"));n=y[0],a=y[1]}else{var y=BP(n,a,o,l,f,v?null:20,c?null:20);n=y[0],a=y[1]}if(v&&(n-=Og(v)?h[0]/2:v==="right"?h[0]:0),c&&(a-=Og(c)?h[1]/2:c==="bottom"?h[1]:0),u1(e)){var y=NP(n,a,o,l,f);n=y[0],a=y[1]}o.moveTo(n,a)},t.prototype._updateContentNotChangedOnAxis=function(e,i){var n=this._lastDataByCoordSys,a=this._cbParamsList,o=!!n&&n.length===e.length;return o&&T(n,function(s,u){var l=s.dataByAxis||[],f=e[u]||{},h=f.dataByAxis||[];o=o&&l.length===h.length,o&&T(l,function(v,c){var p=h[c]||{},d=v.seriesDataIndices||[],g=p.seriesDataIndices||[];o=o&&v.value===p.value&&v.axisType===p.axisType&&v.axisId===p.axisId&&d.length===g.length,o&&T(d,function(y,m){var _=g[m];o=o&&y.seriesIndex===_.seriesIndex&&y.dataIndex===_.dataIndex}),a&&T(v.seriesDataIndices,function(y){var m=y.seriesIndex,_=i[m],S=a[m];_&&S&&S.data!==_.data&&(o=!1)})})}),this._lastDataByCoordSys=e,this._cbParamsList=i,!!o},t.prototype._hide=function(e){this._lastDataByCoordSys=null,e({type:"hideTip",from:this.uid})},t.prototype.dispose=function(e,i){Z.node||!i.getDom()||(fs(this,"_updatePosition"),this._tooltipContent.dispose(),oh("itemTooltip",i))},t.type="tooltip",t})($t);function Zn(r,t,e){var i=t.ecModel,n;e?(n=new St(e,i,i),n=new St(t.option,n,i)):n=t;for(var a=r.length-1;a>=0;a--){var o=r[a];o&&(o instanceof St&&(o=o.get("tooltip",!0)),H(o)&&(o={formatter:o}),o&&(n=new St(o,n,i)))}return n}function kg(r,t){return r.dispatchAction||U(t.dispatchAction,t)}function BP(r,t,e,i,n,a,o){var s=e.getSize(),u=s[0],l=s[1];return a!=null&&(r+u+a+2>i?r-=u+a:r+=a),o!=null&&(t+l+o>n?t-=l+o:t+=o),[r,t]}function NP(r,t,e,i,n){var a=e.getSize(),o=a[0],s=a[1];return r=Math.min(r+o,i)-o,t=Math.min(t+s,n)-s,r=Math.max(r,0),t=Math.max(t,0),[r,t]}function FP(r,t,e,i){var n=e[0],a=e[1],o=Math.ceil(Math.SQRT2*i)+8,s=0,u=0,l=t.width,f=t.height;switch(r){case"inside":s=t.x+l/2-n/2,u=t.y+f/2-a/2;break;case"top":s=t.x+l/2-n/2,u=t.y-a-o;break;case"bottom":s=t.x+l/2-n/2,u=t.y+f+o;break;case"left":s=t.x-n-o,u=t.y+f/2-a/2;break;case"right":s=t.x+l+o,u=t.y+f/2-a/2}return[s,u]}function Og(r){return r==="center"||r==="middle"}function zP(r,t,e){var i=xh(r).queryOptionMap,n=i.keys()[0];if(!(!n||n==="series")){var a=za(t,n,i.get(n),{useDefault:!1,enableAll:!1,enableNone:!1}),o=a.models[0];if(o){var s=e.getViewOfComponentModel(o),u;if(s.group.traverse(function(l){var f=at(l).tooltipConfig;if(f&&f.name===r.name)return u=l,!0}),u)return{componentMainType:n,componentIndex:o.componentIndex,el:u}}}}function VP(r){Pr(n1),r.registerComponentModel(bP),r.registerComponentView(OP),r.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},At),r.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},At)}var HP=["rect","polygon","keep","clear"];function GP(r,t){var e=Ct(r?r.brush:[]);if(e.length){var i=[];T(e,function(u){var l=u.hasOwnProperty("toolbox")?u.toolbox:[];l instanceof Array&&(i=i.concat(l))});var n=r&&r.toolbox;B(n)&&(n=n[0]),n||(n={feature:{}},r.toolbox=[n]);var a=n.feature||(n.feature={}),o=a.brush||(a.brush={}),s=o.type||(o.type=[]);s.push.apply(s,i),WP(s),t&&!s.length&&s.push.apply(s,HP)}}function WP(r){var t={};T(r,function(e){t[e]=1}),r.length=0,T(t,function(e,i){r.push(i)})}var Bg=T;function Ng(r){if(r){for(var t in r)if(r.hasOwnProperty(t))return!0}}function UP(r,t,e){var i={};return Bg(t,function(a){var o=i[a]=n();Bg(r[a],function(s,u){if(ln.isValidType(u)){var l={type:u,visual:s};e&&e(l,a),o[u]=new ln(l),u==="opacity"&&(l=Y(l),l.type="colorAlpha",o.__hidden.__alphaForOpacity=new ln(l))}})}),i;function n(){var a=function(){};a.prototype.__hidden=a.prototype;var o=new a;return o}}function YP(r,t,e){var i;T(e,function(n){t.hasOwnProperty(n)&&Ng(t[n])&&(i=!0)}),i&&T(e,function(n){t.hasOwnProperty(n)&&Ng(t[n])?r[n]=Y(t[n]):delete r[n]})}function ZP(r,t,e,i,n,a){var o={};T(r,function(h){var v=ln.prepareVisualTypes(t[h]);o[h]=v});var s;function u(h){return b0(e,s,h)}function l(h,v){RM(e,s,h,v)}e.each(f);function f(h,v){s=h;var c=e.getRawDataItem(s);if(!(c&&c.visualMap===!1))for(var p=i.call(n,h),d=t[p],g=o[p],y=0,m=g.length;y<m;y++){var _=g[y];d[_]&&d[_].applyVisual(h,u,l)}}}function XP(r){var t=r.brushType,e={point:function(i){return Fg[t].point(i,e,r)},rect:function(i){return Fg[t].rect(i,e,r)}};return e}var Fg={lineX:zg(0),lineY:zg(1),rect:{point:function(r,t,e){return r&&e.boundingRect.contain(r[0],r[1])},rect:function(r,t,e){return r&&e.boundingRect.intersect(r)}},polygon:{point:function(r,t,e){return r&&e.boundingRect.contain(r[0],r[1])&&Gn(e.range,r[0],r[1])},rect:function(r,t,e){var i=e.range;if(!r||i.length<=1)return!1;var n=r.x,a=r.y,o=r.width,s=r.height,u=i[0];if(Gn(i,n,a)||Gn(i,n+o,a)||Gn(i,n,a+s)||Gn(i,n+o,a+s)||et.create(r).contain(u[0],u[1])||ta(n,a,n+o,a,i)||ta(n,a,n,a+s,i)||ta(n+o,a,n+o,a+s,i)||ta(n,a+s,n+o,a+s,i))return!0}}};function zg(r){var t=["x","y"],e=["width","height"];return{point:function(i,n,a){if(i){var o=a.range,s=i[r];return Xn(s,o)}},rect:function(i,n,a){if(i){var o=a.range,s=[i[t[r]],i[t[r]]+i[e[r]]];return s[1]<s[0]&&s.reverse(),Xn(s[0],o)||Xn(s[1],o)||Xn(o[0],s)||Xn(o[1],s)}}}}function Xn(r,t){return t[0]<=r&&r<=t[1]}var Vg=["inBrush","outOfBrush"],Vl="__ecBrushSelect",uh="__ecInBrushSelectEvent";function v1(r){r.eachComponent({mainType:"brush"},function(t){var e=t.brushTargetManager=new _P(t.option,r);e.setInputRanges(t.areas,r)})}function $P(r,t,e){var i=[],n,a;r.eachComponent({mainType:"brush"},function(o){e&&e.type==="takeGlobalCursor"&&o.setBrushOption(e.key==="brush"?e.brushOption:{brushType:!1})}),v1(r),r.eachComponent({mainType:"brush"},function(o,s){var u={brushId:o.id,brushIndex:s,brushName:o.name,areas:Y(o.areas),selected:[]};i.push(u);var l=o.option,f=l.brushLink,h=[],v=[],c=[],p=!1;s||(n=l.throttleType,a=l.throttleDelay);var d=z(o.areas,function(b){var w=JP[b.brushType],x=rt({boundingRect:w?w(b):void 0},b);return x.selectors=XP(x),x}),g=UP(o.option,Vg,function(b){b.mappingMethod="fixed"});B(f)&&T(f,function(b){h[b]=1});function y(b){return f==="all"||!!h[b]}function m(b){return!!b.length}r.eachSeries(function(b,w){var x=c[w]=[];b.subType==="parallel"?_(b,w):S(b,w,x)});function _(b,w){var x=b.coordinateSystem;p=p||x.hasAxisBrushed(),y(w)&&x.eachActiveState(b.getData(),function(C,M){C==="active"&&(v[M]=1)})}function S(b,w,x){if(!(!b.brushSelector||QP(o,w))&&(T(d,function(M){o.brushTargetManager.controlSeries(M,b,r)&&x.push(M),p=p||m(x)}),y(w)&&m(x))){var C=b.getData();C.each(function(M){Hg(b,x,C,M)&&(v[M]=1)})}}r.eachSeries(function(b,w){var x={seriesId:b.id,seriesIndex:w,seriesName:b.name,dataIndex:[]};u.selected.push(x);var C=c[w],M=b.getData(),D=y(w)?function(A){return v[A]?(x.dataIndex.push(M.getRawIndex(A)),"inBrush"):"outOfBrush"}:function(A){return Hg(b,C,M,A)?(x.dataIndex.push(M.getRawIndex(A)),"inBrush"):"outOfBrush"};(y(w)?p:m(C))&&ZP(Vg,g,M,D)})}),qP(t,n,a,i,e)}function qP(r,t,e,i,n){if(n){var a=r.getZr();if(!a[uh]){a[Vl]||(a[Vl]=KP);var o=Ha(a,Vl,e,t);o(r,i)}}}function KP(r,t){if(!r.isDisposed()){var e=r.getZr();e[uh]=!0,r.dispatchAction({type:"brushSelect",batch:t}),e[uh]=!1}}function Hg(r,t,e,i){for(var n=0,a=t.length;n<a;n++){var o=t[n];if(r.brushSelector(i,e,o.selectors,o))return!0}}function QP(r,t){var e=r.option.seriesIndex;return e!=null&&e!=="all"&&(B(e)?Q(e,t)<0:t!==e)}var JP={rect:function(r){return Gg(r.range)},polygon:function(r){for(var t,e=r.range,i=0,n=e.length;i<n;i++){t=t||[[1/0,-1/0],[1/0,-1/0]];var a=e[i];a[0]<t[0][0]&&(t[0][0]=a[0]),a[0]>t[0][1]&&(t[0][1]=a[0]),a[1]<t[1][0]&&(t[1][0]=a[1]),a[1]>t[1][1]&&(t[1][1]=a[1])}return t&&Gg(t)}};function Gg(r){return new et(r[0][0],r[1][0],r[0][1]-r[0][0],r[1][1]-r[1][0])}var jP=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(e,i){this.ecModel=e,this.api=i,this.model,(this._brushController=new VL(i.getZr())).on("brush",U(this._onBrush,this)).mount()},t.prototype.render=function(e,i,n,a){this.model=e,this._updateController(e,i,n,a)},t.prototype.updateTransform=function(e,i,n,a){v1(i),this._updateController(e,i,n,a)},t.prototype.updateVisual=function(e,i,n,a){this.updateTransform(e,i,n,a)},t.prototype.updateView=function(e,i,n,a){this._updateController(e,i,n,a)},t.prototype._updateController=function(e,i,n,a){(!a||a.$from!==e.id)&&this._brushController.setPanels(e.brushTargetManager.makePanelOpts(n)).enableBrush(e.brushOption).updateCovers(e.areas.slice())},t.prototype.dispose=function(){this._brushController.dispose()},t.prototype._onBrush=function(e){var i=this.model.id,n=this.model.brushTargetManager.setOutputRanges(e.areas,this.ecModel);(!e.isEnd||e.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:i,areas:Y(n),$from:i}),e.isEnd&&this.api.dispatchAction({type:"brushEnd",brushId:i,areas:Y(n),$from:i})},t.type="brush",t})($t),tI="#ddd",eI=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.areas=[],e.brushOption={},e}return t.prototype.optionUpdated=function(e,i){var n=this.option;!i&&YP(n,e,["inBrush","outOfBrush"]);var a=n.inBrush=n.inBrush||{};n.outOfBrush=n.outOfBrush||{color:tI},a.hasOwnProperty("liftZ")||(a.liftZ=5)},t.prototype.setAreas=function(e){e&&(this.areas=z(e,function(i){return Wg(this.option,i)},this))},t.prototype.setBrushOption=function(e){this.brushOption=Wg(this.option,e),this.brushType=this.brushOption.brushType},t.type="brush",t.dependencies=["geo","grid","xAxis","yAxis","parallel","series"],t.defaultOption={seriesIndex:"all",brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:"rgba(210,219,238,0.3)",borderColor:"#D2DBEE"},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4},t})(nt);function Wg(r,t){return tt({brushType:r.brushType,brushMode:r.brushMode,transformable:r.transformable,brushStyle:new St(r.brushStyle).getItemStyle(),removeOnClick:r.removeOnClick,z:r.z},t,!0)}function rI(r){r.registerComponentView(jP),r.registerComponentModel(eI),r.registerPreprocessor(GP),r.registerVisual(r.PRIORITY.VISUAL.BRUSH,$P),r.registerAction({type:"brush",event:"brush",update:"updateVisual"},function(t,e){e.eachComponent({mainType:"brush",query:t},function(i){i.setAreas(t.areas)})}),r.registerAction({type:"brushSelect",event:"brushSelected",update:"none"},At),r.registerAction({type:"brushEnd",event:"brushEnd",update:"none"},At)}function c1(r,t){if(!r)return!1;for(var e=B(r)?r:[r],i=0;i<e.length;i++)if(e[i]&&e[i][t])return!0;return!1}function Co(r){df(r,"label",["show"])}var Do=vt(),xi=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e.createdBySelf=!1,e}return t.prototype.init=function(e,i,n){this.mergeDefaultAndTheme(e,n),this._mergeOption(e,n,!1,!0)},t.prototype.isAnimationEnabled=function(){if(Z.node)return!1;var e=this.__hostSeries;return this.getShallow("animation")&&e&&e.isAnimationEnabled()},t.prototype.mergeOption=function(e,i){this._mergeOption(e,i,!1,!1)},t.prototype._mergeOption=function(e,i,n,a){var o=this.mainType;n||i.eachSeries(function(s){var u=s.get(this.mainType,!0),l=Do(s)[o];if(!u||!u.data){Do(s)[o]=null;return}l?l._mergeOption(u,i,!0):(a&&Co(u),T(u.data,function(f){f instanceof Array?(Co(f[0]),Co(f[1])):Co(f)}),l=this.createMarkerModelFromSeries(u,this,i),k(l,{mainType:this.mainType,seriesIndex:s.seriesIndex,name:s.name,createdBySelf:!0}),l.__hostSeries=s),Do(s)[o]=l},this)},t.prototype.formatTooltip=function(e,i,n){var a=this.getData(),o=this.getRawValue(e),s=a.getName(e);return Si("section",{header:this.name,blocks:[Si("nameValue",{name:s,value:o,noName:!s,noValue:o==null})]})},t.prototype.getData=function(){return this._data},t.prototype.setData=function(e){this._data=e},t.prototype.getDataParams=function(e,i){var n=$h.prototype.getDataParams.call(this,e,i),a=this.__hostSeries;return a&&(n.seriesId=a.id,n.seriesName=a.name,n.seriesType=a.subType),n},t.getMarkerModelFromSeries=function(e,i){return Do(e)[i]},t.type="marker",t.dependencies=["series","grid","polar","geo"],t})(nt);Ce(xi,$h.prototype);function lh(r){return!(isNaN(parseFloat(r.x))&&isNaN(parseFloat(r.y)))}function iI(r){return!isNaN(parseFloat(r.x))&&!isNaN(parseFloat(r.y))}function Ao(r,t,e,i,n,a){var o=[],s=pn(t,i),u=s?t.getCalculationInfo("stackResultDimension"):i,l=Lv(t,u,r),f=t.indicesOfNearest(u,l)[0];o[n]=t.get(e,f),o[a]=t.get(u,f);var h=t.get(i,f),v=Be(t.get(i,f));return v=Math.min(v,20),v>=0&&(o[a]=+o[a].toFixed(v)),[o,h]}var Hl={min:ot(Ao,"min"),max:ot(Ao,"max"),average:ot(Ao,"average"),median:ot(Ao,"median")};function bs(r,t){if(t){var e=r.getData(),i=r.coordinateSystem,n=i&&i.dimensions;if(!iI(t)&&!B(t.coord)&&B(n)){var a=p1(t,e,i,r);if(t=Y(t),t.type&&Hl[t.type]&&a.baseAxis&&a.valueAxis){var o=Q(n,a.baseAxis.dim),s=Q(n,a.valueAxis.dim),u=Hl[t.type](e,a.baseDataDim,a.valueDataDim,o,s);t.coord=u[0],t.value=u[1]}else t.coord=[t.xAxis!=null?t.xAxis:t.radiusAxis,t.yAxis!=null?t.yAxis:t.angleAxis]}if(t.coord==null||!B(n))t.coord=[];else for(var l=t.coord,f=0;f<2;f++)Hl[l[f]]&&(l[f]=Lv(e,e.mapDimension(n[f]),l[f]));return t}}function p1(r,t,e,i){var n={};return r.valueIndex!=null||r.valueDim!=null?(n.valueDataDim=r.valueIndex!=null?t.getDimension(r.valueIndex):r.valueDim,n.valueAxis=e.getAxis(nI(i,n.valueDataDim)),n.baseAxis=e.getOtherAxis(n.valueAxis),n.baseDataDim=t.mapDimension(n.baseAxis.dim)):(n.baseAxis=i.getBaseAxis(),n.valueAxis=e.getOtherAxis(n.baseAxis),n.baseDataDim=t.mapDimension(n.baseAxis.dim),n.valueDataDim=t.mapDimension(n.valueAxis.dim)),n}function nI(r,t){var e=r.getData().getDimensionInfo(t);return e&&e.coordDim}function xs(r,t){return r&&r.containData&&t.coord&&!lh(t)?r.containData(t.coord):!0}function aI(r,t,e){return r&&r.containZone&&t.coord&&e.coord&&!lh(t)&&!lh(e)?r.containZone(t.coord,e.coord):!0}function oI(r,t){return r?function(e,i,n,a){var o=a<2?e.coord&&e.coord[a]:e.value;return Cr(o,t[a])}:function(e,i,n,a){return Cr(e.value,t[a])}}function Lv(r,t,e){if(e==="average"){var i=0,n=0;return r.each(t,function(a,o){isNaN(a)||(i+=a,n++)}),i/n}else return e==="median"?r.getMedian(t):r.getDataExtent(t)[e==="max"?1:0]}var Gl=vt(),d1=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.init=function(){this.markerGroupMap=X()},t.prototype.render=function(e,i,n){var a=this,o=this.markerGroupMap;o.each(function(s){Gl(s).keep=!1}),i.eachSeries(function(s){var u=xi.getMarkerModelFromSeries(s,a.type);u&&a.renderSeries(s,u,i,n)}),o.each(function(s){!Gl(s).keep&&a.group.remove(s.group)})},t.prototype.markKeep=function(e){Gl(e).keep=!0},t.prototype.toggleBlurSeries=function(e,i){var n=this;T(e,function(a){var o=xi.getMarkerModelFromSeries(a,n.type);if(o){var s=o.getData();s.eachItemGraphicEl(function(u){u&&(i?tm(u):Ah(u))})}})},t.type="marker",t})($t),sI=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.createMarkerModelFromSeries=function(e,i,n){return new t(e,i,n)},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})(xi),Lo=vt(),uI=function(r,t,e,i){var n=r.getData(),a;if(B(i))a=i;else{var o=i.type;if(o==="min"||o==="max"||o==="average"||o==="median"||i.xAxis!=null||i.yAxis!=null){var s=void 0,u=void 0;if(i.yAxis!=null||i.xAxis!=null)s=t.getAxis(i.yAxis!=null?"y":"x"),u=ke(i.yAxis,i.xAxis);else{var l=p1(i,n,t,r);s=l.valueAxis;var f=Q0(n,l.valueDataDim);u=Lv(n,f,o)}var h=s.dim==="x"?0:1,v=1-h,c=Y(i),p={coord:[]};c.type=null,c.coord=[],c.coord[v]=-1/0,p.coord[v]=1/0;var d=e.get("precision");d>=0&&dt(u)&&(u=+u.toFixed(Math.min(d,20))),c.coord[h]=p.coord[h]=u,a=[c,p,{type:o,valueIndex:i.valueIndex,value:u}]}else a=[]}var g=[bs(r,a[0]),bs(r,a[1]),k({},a[2])];return g[2].type=g[2].type||null,tt(g[2],g[0]),tt(g[2],g[1]),g};function Ts(r){return!isNaN(r)&&!isFinite(r)}function Ug(r,t,e,i){var n=1-r,a=i.dimensions[r];return Ts(t[n])&&Ts(e[n])&&t[r]===e[r]&&i.getAxis(a).containData(t[r])}function lI(r,t){if(r.type==="cartesian2d"){var e=t[0].coord,i=t[1].coord;if(e&&i&&(Ug(1,e,i,r)||Ug(0,e,i,r)))return!0}return xs(r,t[0])&&xs(r,t[1])}function Wl(r,t,e,i,n){var a=i.coordinateSystem,o=r.getItemModel(t),s,u=yt(o.get("x"),n.getWidth()),l=yt(o.get("y"),n.getHeight());if(!isNaN(u)&&!isNaN(l))s=[u,l];else{if(i.getMarkerPosition)s=i.getMarkerPosition(r.getValues(r.dimensions,t));else{var f=a.dimensions,h=r.get(f[0],t),v=r.get(f[1],t);s=a.dataToPoint([h,v])}if(su(a,"cartesian2d")){var c=a.getAxis("x"),p=a.getAxis("y"),f=a.dimensions;Ts(r.get(f[0],t))?s[0]=c.toGlobalCoord(c.getExtent()[e?0:1]):Ts(r.get(f[1],t))&&(s[1]=p.toGlobalCoord(p.getExtent()[e?0:1]))}isNaN(u)||(s[0]=u),isNaN(l)||(s[1]=l)}r.setItemLayout(t,s)}var fI=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.updateTransform=function(e,i,n){i.eachSeries(function(a){var o=xi.getMarkerModelFromSeries(a,"markLine");if(o){var s=o.getData(),u=Lo(o).from,l=Lo(o).to;u.each(function(f){Wl(u,f,!0,a,n),Wl(l,f,!1,a,n)}),s.each(function(f){s.setItemLayout(f,[u.getItemLayout(f),l.getItemLayout(f)])}),this.markerGroupMap.get(a.id).updateLayout()}},this)},t.prototype.renderSeries=function(e,i,n,a){var o=e.coordinateSystem,s=e.id,u=e.getData(),l=this.markerGroupMap,f=l.get(s)||l.set(s,new IL);this.group.add(f.group);var h=hI(o,e,i),v=h.from,c=h.to,p=h.line;Lo(i).from=v,Lo(i).to=c,i.setData(p);var d=i.get("symbol"),g=i.get("symbolSize"),y=i.get("symbolRotate"),m=i.get("symbolOffset");B(d)||(d=[d,d]),B(g)||(g=[g,g]),B(y)||(y=[y,y]),B(m)||(m=[m,m]),h.from.each(function(S){_(v,S,!0),_(c,S,!1)}),p.each(function(S){var b=p.getItemModel(S).getModel("lineStyle").getLineStyle();p.setItemLayout(S,[v.getItemLayout(S),c.getItemLayout(S)]),b.stroke==null&&(b.stroke=v.getItemVisual(S,"style").fill),p.setItemVisual(S,{fromSymbolKeepAspect:v.getItemVisual(S,"symbolKeepAspect"),fromSymbolOffset:v.getItemVisual(S,"symbolOffset"),fromSymbolRotate:v.getItemVisual(S,"symbolRotate"),fromSymbolSize:v.getItemVisual(S,"symbolSize"),fromSymbol:v.getItemVisual(S,"symbol"),toSymbolKeepAspect:c.getItemVisual(S,"symbolKeepAspect"),toSymbolOffset:c.getItemVisual(S,"symbolOffset"),toSymbolRotate:c.getItemVisual(S,"symbolRotate"),toSymbolSize:c.getItemVisual(S,"symbolSize"),toSymbol:c.getItemVisual(S,"symbol"),style:b})}),f.updateData(p),h.line.eachItemGraphicEl(function(S){at(S).dataModel=i,S.traverse(function(b){at(b).dataModel=i})});function _(S,b,w){var x=S.getItemModel(b);Wl(S,b,w,e,a);var C=x.getModel("itemStyle").getItemStyle();C.fill==null&&(C.fill=Kh(u,"color")),S.setItemVisual(b,{symbolKeepAspect:x.get("symbolKeepAspect"),symbolOffset:$(x.get("symbolOffset",!0),m[w?0:1]),symbolRotate:$(x.get("symbolRotate",!0),y[w?0:1]),symbolSize:$(x.get("symbolSize"),g[w?0:1]),symbol:$(x.get("symbol",!0),d[w?0:1]),style:C})}this.markKeep(f),f.group.silent=i.get("silent")||e.get("silent")},t.type="markLine",t})(d1);function hI(r,t,e){var i;r?i=z(r&&r.dimensions,function(l){var f=t.getData().getDimensionInfo(t.getData().mapDimension(l))||{};return k(k({},f),{name:l,ordinalMeta:null})}):i=[{name:"value",type:"float"}];var n=new un(i,e),a=new un(i,e),o=new un([],e),s=z(e.get("data"),ot(uI,t,r,e));r&&(s=_t(s,ot(lI,r)));var u=oI(!!r,i);return n.initData(z(s,function(l){return l[0]}),null,u),a.initData(z(s,function(l){return l[1]}),null,u),o.initData(z(s,function(l){return l[2]})),o.hasItemOption=!0,{from:n,to:a,line:o}}function vI(r){r.registerComponentModel(sI),r.registerComponentView(fI),r.registerPreprocessor(function(t){c1(t.series,"markLine")&&(t.markLine=t.markLine||{})})}var cI=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.createMarkerModelFromSeries=function(e,i,n){return new t(e,i,n)},t.type="markArea",t.defaultOption={z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}},t})(xi),Po=vt(),pI=function(r,t,e,i){var n=i[0],a=i[1];if(!(!n||!a)){var o=bs(r,n),s=bs(r,a),u=o.coord,l=s.coord;u[0]=ke(u[0],-1/0),u[1]=ke(u[1],-1/0),l[0]=ke(l[0],1/0),l[1]=ke(l[1],1/0);var f=I1([{},o,s]);return f.coord=[o.coord,s.coord],f.x0=o.x,f.y0=o.y,f.x1=s.x,f.y1=s.y,f}};function Ms(r){return!isNaN(r)&&!isFinite(r)}function Yg(r,t,e,i){var n=1-r;return Ms(t[n])&&Ms(e[n])}function dI(r,t){var e=t.coord[0],i=t.coord[1],n={coord:e,x:t.x0,y:t.y0},a={coord:i,x:t.x1,y:t.y1};return su(r,"cartesian2d")?e&&i&&(Yg(1,e,i)||Yg(0,e,i))?!0:aI(r,n,a):xs(r,n)||xs(r,a)}function Zg(r,t,e,i,n){var a=i.coordinateSystem,o=r.getItemModel(t),s,u=yt(o.get(e[0]),n.getWidth()),l=yt(o.get(e[1]),n.getHeight());if(!isNaN(u)&&!isNaN(l))s=[u,l];else{if(i.getMarkerPosition){var f=r.getValues(["x0","y0"],t),h=r.getValues(["x1","y1"],t),v=a.clampData(f),c=a.clampData(h),p=[];e[0]==="x0"?p[0]=v[0]>c[0]?h[0]:f[0]:p[0]=v[0]>c[0]?f[0]:h[0],e[1]==="y0"?p[1]=v[1]>c[1]?h[1]:f[1]:p[1]=v[1]>c[1]?f[1]:h[1],s=i.getMarkerPosition(p,e,!0)}else{var d=r.get(e[0],t),g=r.get(e[1],t),y=[d,g];a.clampData&&a.clampData(y,y),s=a.dataToPoint(y,!0)}if(su(a,"cartesian2d")){var m=a.getAxis("x"),_=a.getAxis("y"),d=r.get(e[0],t),g=r.get(e[1],t);Ms(d)?s[0]=m.toGlobalCoord(m.getExtent()[e[0]==="x0"?0:1]):Ms(g)&&(s[1]=_.toGlobalCoord(_.getExtent()[e[1]==="y0"?0:1]))}isNaN(u)||(s[0]=u),isNaN(l)||(s[1]=l)}return s}var Xg=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]],gI=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.prototype.updateTransform=function(e,i,n){i.eachSeries(function(a){var o=xi.getMarkerModelFromSeries(a,"markArea");if(o){var s=o.getData();s.each(function(u){var l=z(Xg,function(h){return Zg(s,u,h,a,n)});s.setItemLayout(u,l);var f=s.getItemGraphicEl(u);f.setShape("points",l)})}},this)},t.prototype.renderSeries=function(e,i,n,a){var o=e.coordinateSystem,s=e.id,u=e.getData(),l=this.markerGroupMap,f=l.get(s)||l.set(s,{group:new gt});this.group.add(f.group),this.markKeep(f);var h=yI(o,e,i);i.setData(h),h.each(function(v){var c=z(Xg,function(C){return Zg(h,v,C,e,a)}),p=o.getAxis("x").scale,d=o.getAxis("y").scale,g=p.getExtent(),y=d.getExtent(),m=[p.parse(h.get("x0",v)),p.parse(h.get("x1",v))],_=[d.parse(h.get("y0",v)),d.parse(h.get("y1",v))];oi(m),oi(_);var S=!(g[0]>m[1]||g[1]<m[0]||y[0]>_[1]||y[1]<_[0]),b=!S;h.setItemLayout(v,{points:c,allClipped:b});var w=h.getItemModel(v).getModel("itemStyle").getItemStyle(),x=Kh(u,"color");w.fill||(w.fill=x,H(w.fill)&&(w.fill=of(w.fill,.4))),w.stroke||(w.stroke=x),h.setItemVisual(v,"style",w)}),h.diff(Po(f).data).add(function(v){var c=h.getItemLayout(v);if(!c.allClipped){var p=new mi({shape:{points:c.points}});h.setItemGraphicEl(v,p),f.group.add(p)}}).update(function(v,c){var p=Po(f).data.getItemGraphicEl(c),d=h.getItemLayout(v);d.allClipped?p&&f.group.remove(p):(p?pe(p,{shape:{points:d.points}},i,v):p=new mi({shape:{points:d.points}}),h.setItemGraphicEl(v,p),f.group.add(p))}).remove(function(v){var c=Po(f).data.getItemGraphicEl(v);f.group.remove(c)}).execute(),h.eachItemGraphicEl(function(v,c){var p=h.getItemModel(c),d=h.getItemVisual(c,"style");v.useStyle(h.getItemVisual(c,"style")),Ys(v,Sn(p),{labelFetcher:i,labelDataIndex:c,defaultText:h.getName(c)||"",inheritColor:H(d.fill)?of(d.fill,1):"#000"}),wf(v,p),vn(v,null,null,p.get(["emphasis","disabled"])),at(v).dataModel=i}),Po(f).data=h,f.group.silent=i.get("silent")||e.get("silent")},t.type="markArea",t})(d1);function yI(r,t,e){var i,n,a=["x0","y0","x1","y1"];if(r){var o=z(r&&r.dimensions,function(l){var f=t.getData(),h=f.getDimensionInfo(f.mapDimension(l))||{};return k(k({},h),{name:l,ordinalMeta:null})});n=z(a,function(l,f){return{name:l,type:o[f%2].type}}),i=new un(n,e)}else n=[{name:"value",type:"float"}],i=new un(n,e);var s=z(e.get("data"),ot(pI,t,r,e));r&&(s=_t(s,ot(dI,r)));var u=r?function(l,f,h,v){var c=l.coord[Math.floor(v/2)][v%2];return Cr(c,n[v])}:function(l,f,h,v){return Cr(l.value,n[v])};return i.initData(s,null,u),i.hasItemOption=!0,i}function mI(r){r.registerComponentModel(cI),r.registerComponentView(gI),r.registerPreprocessor(function(t){c1(t.series,"markArea")&&(t.markArea=t.markArea||{})})}var _I=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="dataZoom.inside",t.defaultOption=Cm(ws.defaultOption,{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}),t})(ws),Pv=vt();function SI(r,t,e){Pv(r).coordSysRecordMap.each(function(i){var n=i.dataZoomInfoMap.get(t.uid);n&&(n.getRange=e)})}function wI(r,t){for(var e=Pv(r).coordSysRecordMap,i=e.keys(),n=0;n<i.length;n++){var a=i[n],o=e.get(a),s=o.dataZoomInfoMap;if(s){var u=t.uid,l=s.get(u);l&&(s.removeKey(u),s.keys().length||g1(e,o))}}}function g1(r,t){if(t){r.removeKey(t.model.uid);var e=t.controller;e&&e.dispose()}}function bI(r,t){var e={model:t,containsPoint:ot(TI,t),dispatchAction:ot(xI,r),dataZoomInfoMap:null,controller:null},i=e.controller=new wL(r.getZr());return T(["pan","zoom","scrollMove"],function(n){i.on(n,function(a){var o=[];e.dataZoomInfoMap.each(function(s){if(a.isAvailableBehavior(s.model.option)){var u=(s.getRange||{})[n],l=u&&u(s.dzReferCoordSysInfo,e.model.mainType,e.controller,a);!s.model.get("disabled",!0)&&l&&o.push({dataZoomId:s.model.id,start:l[0],end:l[1]})}}),o.length&&e.dispatchAction(o)})}),e}function xI(r,t){r.isDisposed()||r.dispatchAction({type:"dataZoom",animation:{easing:"cubicOut",duration:100},batch:t})}function TI(r,t,e,i){return r.coordinateSystem.containPoint([e,i])}function MI(r){var t,e="type_",i={type_true:2,type_move:1,type_false:0,type_undefined:-1},n=!0;return r.each(function(a){var o=a.model,s=o.get("disabled",!0)?!1:o.get("zoomLock",!0)?"move":!0;i[e+s]>i[e+t]&&(t=s),n=n&&o.get("preventDefaultMouseMove",!0)}),{controlType:t,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!n}}}function CI(r){r.registerProcessor(r.PRIORITY.PROCESSOR.FILTER,function(t,e){var i=Pv(e),n=i.coordSysRecordMap||(i.coordSysRecordMap=X());n.each(function(a){a.dataZoomInfoMap=null}),t.eachComponent({mainType:"dataZoom",subType:"inside"},function(a){var o=a1(a);T(o.infoList,function(s){var u=s.model.uid,l=n.get(u)||n.set(u,bI(e,s.model)),f=l.dataZoomInfoMap||(l.dataZoomInfoMap=X());f.set(a.uid,{dzReferCoordSysInfo:s,model:a,getRange:null})})}),n.each(function(a){var o=a.controller,s,u=a.dataZoomInfoMap;if(u){var l=u.keys()[0];l!=null&&(s=u.get(l))}if(!s){g1(n,a);return}var f=MI(u);o.enable(f.controlType,f.opt),o.setPointerChecker(a.containsPoint),Ha(a,"dispatchAction",s.model.get("throttle",!0),"fixRate")})})}var DI=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type="dataZoom.inside",e}return t.prototype.render=function(e,i,n){if(r.prototype.render.apply(this,arguments),e.noTarget()){this._clear();return}this.range=e.getPercentRange(),SI(n,e,{pan:U(Ul.pan,this),zoom:U(Ul.zoom,this),scrollMove:U(Ul.scrollMove,this)})},t.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){wI(this.api,this.dataZoomModel),this.range=null},t.type="dataZoom.inside",t})(o1),Ul={zoom:function(r,t,e,i){var n=this.range,a=n.slice(),o=r.axisModels[0];if(o){var s=Yl[t](null,[i.originX,i.originY],o,e,r),u=(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/i.scale,0);a[0]=(a[0]-u)*l+u,a[1]=(a[1]-u)*l+u;var f=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();if(uu(0,a,[0,100],0,f.minSpan,f.maxSpan),this.range=a,n[0]!==a[0]||n[1]!==a[1])return a}},pan:$g(function(r,t,e,i,n,a){var o=Yl[i]([a.oldX,a.oldY],[a.newX,a.newY],t,n,e);return o.signal*(r[1]-r[0])*o.pixel/o.pixelLength}),scrollMove:$g(function(r,t,e,i,n,a){var o=Yl[i]([0,0],[a.scrollDelta,a.scrollDelta],t,n,e);return o.signal*(r[1]-r[0])*a.scrollDelta})};function $g(r){return function(t,e,i,n){var a=this.range,o=a.slice(),s=t.axisModels[0];if(s){var u=r(o,s,t,e,i,n);if(uu(u,o,[0,100],"all"),this.range=o,a[0]!==o[0]||a[1]!==o[1])return o}}}var Yl={grid:function(r,t,e,i,n){var a=e.axis,o={},s=n.model.coordinateSystem.getRect();return r=r||[0,0],a.dim==="x"?(o.pixel=t[0]-r[0],o.pixelLength=s.width,o.pixelStart=s.x,o.signal=a.inverse?1:-1):(o.pixel=t[1]-r[1],o.pixelLength=s.height,o.pixelStart=s.y,o.signal=a.inverse?-1:1),o},polar:function(r,t,e,i,n){var a=e.axis,o={},s=n.model.coordinateSystem,u=s.getRadiusAxis().getExtent(),l=s.getAngleAxis().getExtent();return r=r?s.pointToCoord(r):[0,0],t=s.pointToCoord(t),e.mainType==="radiusAxis"?(o.pixel=t[0]-r[0],o.pixelLength=u[1]-u[0],o.pixelStart=u[0],o.signal=a.inverse?1:-1):(o.pixel=t[1]-r[1],o.pixelLength=l[1]-l[0],o.pixelStart=l[0],o.signal=a.inverse?-1:1),o},singleAxis:function(r,t,e,i,n){var a=e.axis,o=n.model.coordinateSystem.getRect(),s={};return r=r||[0,0],a.orient==="horizontal"?(s.pixel=t[0]-r[0],s.pixelLength=o.width,s.pixelStart=o.x,s.signal=a.inverse?1:-1):(s.pixel=t[1]-r[1],s.pixelLength=o.height,s.pixelStart=o.y,s.signal=a.inverse?-1:1),s}};function AI(r){s1(r),r.registerComponentModel(_I),r.registerComponentView(DI),CI(r)}var LI=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e}return t.type="dataZoom.slider",t.layoutMode="box",t.defaultOption=Cm(ws.defaultOption,{show:!0,right:"ph",top:"ph",width:"ph",height:"ph",left:null,bottom:null,borderColor:"#d2dbee",borderRadius:3,backgroundColor:"rgba(47,69,84,0)",dataBackground:{lineStyle:{color:"#d2dbee",width:.5},areaStyle:{color:"#d2dbee",opacity:.2}},selectedDataBackground:{lineStyle:{color:"#8fb0f7",width:.5},areaStyle:{color:"#8fb0f7",opacity:.2}},fillerColor:"rgba(135,175,274,0.2)",handleIcon:"path://M-9.35,34.56V42m0-40V9.5m-2,0h4a2,2,0,0,1,2,2v21a2,2,0,0,1-2,2h-4a2,2,0,0,1-2-2v-21A2,2,0,0,1-11.35,9.5Z",handleSize:"100%",handleStyle:{color:"#fff",borderColor:"#ACB8D1"},moveHandleSize:7,moveHandleIcon:"path://M-320.9-50L-320.9-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-348-41-339-50-320.9-50z M-212.3-50L-212.3-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-239.4-41-230.4-50-212.3-50z M-103.7-50L-103.7-50c18.1,0,27.1,9,27.1,27.1V85.7c0,18.1-9,27.1-27.1,27.1l0,0c-18.1,0-27.1-9-27.1-27.1V-22.9C-130.9-41-121.8-50-103.7-50z",moveHandleStyle:{color:"#D2DBEE",opacity:.7},showDetail:!0,showDataShadow:"auto",realtime:!0,zoomLock:!1,textStyle:{color:"#6E7079"},brushSelect:!0,brushStyle:{color:"rgba(135,175,274,0.15)"},emphasis:{handleLabel:{show:!0},handleStyle:{borderColor:"#8FB0F7"},moveHandleStyle:{color:"#8FB0F7"}}}),t})(ws),$n=Tt,qg=7,PI=1,Zl=30,II=7,qn="horizontal",Kg="vertical",RI=5,EI=["line","bar","candlestick","scatter"],kI={easing:"cubicOut",duration:100,delay:0},OI=(function(r){O(t,r);function t(){var e=r!==null&&r.apply(this,arguments)||this;return e.type=t.type,e._displayables={},e}return t.prototype.init=function(e,i){this.api=i,this._onBrush=U(this._onBrush,this),this._onBrushEnd=U(this._onBrushEnd,this)},t.prototype.render=function(e,i,n,a){if(r.prototype.render.apply(this,arguments),Ha(this,"_dispatchZoomAction",e.get("throttle"),"fixRate"),this._orient=e.getOrient(),e.get("show")===!1){this.group.removeAll();return}if(e.noTarget()){this._clear(),this.group.removeAll();return}(!a||a.type!=="dataZoom"||a.from!==this.uid)&&this._buildView(),this._updateView()},t.prototype.dispose=function(){this._clear(),r.prototype.dispose.apply(this,arguments)},t.prototype._clear=function(){fs(this,"_dispatchZoomAction");var e=this.api.getZr();e.off("mousemove",this._onBrush),e.off("mouseup",this._onBrushEnd)},t.prototype._buildView=function(){var e=this.group;e.removeAll(),this._brushing=!1,this._displayables.brushRect=null,this._resetLocation(),this._resetInterval();var i=this._displayables.sliderGroup=new gt;this._renderBackground(),this._renderHandle(),this._renderDataShadow(),e.add(i),this._positionGroup()},t.prototype._resetLocation=function(){var e=this.dataZoomModel,i=this.api,n=e.get("brushSelect"),a=n?II:0,o=this._findCoordRect(),s={width:i.getWidth(),height:i.getHeight()},u=this._orient===qn?{right:s.width-o.x-o.width,top:s.height-Zl-qg-a,width:o.width,height:Zl}:{right:qg,top:o.y,width:Zl,height:o.height},l=js(e.option);T(["right","top","width","height"],function(h){l[h]==="ph"&&(l[h]=u[h])});var f=Gh(l,s);this._location={x:f.x,y:f.y},this._size=[f.width,f.height],this._orient===Kg&&this._size.reverse()},t.prototype._positionGroup=function(){var e=this.group,i=this._location,n=this._orient,a=this.dataZoomModel.getFirstTargetAxisModel(),o=a&&a.get("inverse"),s=this._displayables.sliderGroup,u=(this._dataShadowInfo||{}).otherAxisInverse;s.attr(n===qn&&!o?{scaleY:u?1:-1,scaleX:1}:n===qn&&o?{scaleY:u?1:-1,scaleX:-1}:n===Kg&&!o?{scaleY:u?-1:1,scaleX:1,rotation:Math.PI/2}:{scaleY:u?-1:1,scaleX:-1,rotation:Math.PI/2});var l=e.getBoundingRect([s]);e.x=i.x-l.x,e.y=i.y-l.y,e.markRedraw()},t.prototype._getViewExtent=function(){return[0,this._size[0]]},t.prototype._renderBackground=function(){var e=this.dataZoomModel,i=this._size,n=this._displayables.sliderGroup,a=e.get("brushSelect");n.add(new $n({silent:!0,shape:{x:0,y:0,width:i[0],height:i[1]},style:{fill:e.get("backgroundColor")},z2:-40}));var o=new $n({shape:{x:0,y:0,width:i[0],height:i[1]},style:{fill:"transparent"},z2:0,onclick:U(this._onClickPanel,this)}),s=this.api.getZr();a?(o.on("mousedown",this._onBrushStart,this),o.cursor="crosshair",s.on("mousemove",this._onBrush),s.on("mouseup",this._onBrushEnd)):(s.off("mousemove",this._onBrush),s.off("mouseup",this._onBrushEnd)),n.add(o)},t.prototype._renderDataShadow=function(){var e=this._dataShadowInfo=this._prepareDataShadowInfo();if(this._displayables.dataShadowSegs=[],!e)return;var i=this._size,n=this._shadowSize||[],a=e.series,o=a.getRawData(),s=a.getShadowDim&&a.getShadowDim(),u=s&&o.getDimensionInfo(s)?a.getShadowDim():e.otherDim;if(u==null)return;var l=this._shadowPolygonPts,f=this._shadowPolylinePts;if(o!==this._shadowData||u!==this._shadowDim||i[0]!==n[0]||i[1]!==n[1]){var h=o.getDataExtent(u),v=(h[1]-h[0])*.3;h=[h[0]-v,h[1]+v];var c=[0,i[1]],p=[0,i[0]],d=[[i[0],0],[0,0]],g=[],y=p[1]/(o.count()-1),m=0,_=Math.round(o.count()/i[0]),S;o.each([u],function(M,D){if(_>0&&D%_){m+=y;return}var A=M==null||isNaN(M)||M==="",P=A?0:bt(M,h,c,!0);A&&!S&&D?(d.push([d[d.length-1][0],0]),g.push([g[g.length-1][0],0])):!A&&S&&(d.push([m,0]),g.push([m,0])),d.push([m,P]),g.push([m,P]),m+=y,S=A}),l=this._shadowPolygonPts=d,f=this._shadowPolylinePts=g}this._shadowData=o,this._shadowDim=u,this._shadowSize=[i[0],i[1]];var b=this.dataZoomModel;function w(M){var D=b.getModel(M?"selectedDataBackground":"dataBackground"),A=new gt,P=new mi({shape:{points:l},segmentIgnoreThreshold:1,style:D.getModel("areaStyle").getAreaStyle(),silent:!0,z2:-20}),R=new _n({shape:{points:f},segmentIgnoreThreshold:1,style:D.getModel("lineStyle").getLineStyle(),silent:!0,z2:-19});return A.add(P),A.add(R),A}for(var x=0;x<3;x++){var C=w(x===1);this._displayables.sliderGroup.add(C),this._displayables.dataShadowSegs.push(C)}},t.prototype._prepareDataShadowInfo=function(){var e=this.dataZoomModel,i=e.get("showDataShadow");if(i!==!1){var n,a=this.ecModel;return e.eachTargetAxis(function(o,s){var u=e.getAxisProxy(o,s).getTargetSeriesModels();T(u,function(l){if(!n&&!(i!==!0&&Q(EI,l.get("type"))<0)){var f=a.getComponent(br(o),s).axis,h=BI(o),v,c=l.coordinateSystem;h!=null&&c.getOtherAxis&&(v=c.getOtherAxis(f).inverse),h=l.getData().mapDimension(h),n={thisAxis:f,series:l,thisDim:o,otherDim:h,otherAxisInverse:v}}},this)},this),n}},t.prototype._renderHandle=function(){var e=this.group,i=this._displayables,n=i.handles=[null,null],a=i.handleLabels=[null,null],o=this._displayables.sliderGroup,s=this._size,u=this.dataZoomModel,l=this.api,f=u.get("borderRadius")||0,h=u.get("brushSelect"),v=i.filler=new $n({silent:h,style:{fill:u.get("fillerColor")},textConfig:{position:"inside"}});o.add(v),o.add(new $n({silent:!0,subPixelOptimize:!0,shape:{x:0,y:0,width:s[0],height:s[1],r:f},style:{stroke:u.get("dataBackgroundColor")||u.get("borderColor"),lineWidth:PI,fill:"rgba(0,0,0,0)"}})),T([0,1],function(_){var S=u.get("handleIcon");!vs[S]&&S.indexOf("path://")<0&&S.indexOf("image://")<0&&(S="path://"+S);var b=ir(S,-1,0,2,2,null,!0);b.attr({cursor:Qg(this._orient),draggable:!0,drift:U(this._onDragMove,this,_),ondragend:U(this._onDragEnd,this),onmouseover:U(this._showDataInfo,this,!0),onmouseout:U(this._showDataInfo,this,!1),z2:5});var w=b.getBoundingRect(),x=u.get("handleSize");this._handleHeight=yt(x,this._size[1]),this._handleWidth=w.width/w.height*this._handleHeight,b.setStyle(u.getModel("handleStyle").getItemStyle()),b.style.strokeNoScale=!0,b.rectHover=!0,b.ensureState("emphasis").style=u.getModel(["emphasis","handleStyle"]).getItemStyle(),am(b);var C=u.get("handleColor");C!=null&&(b.style.fill=C),o.add(n[_]=b);var M=u.getModel("textStyle"),D=u.get("handleLabel")||{},A=D.show||!1;e.add(a[_]=new te({silent:!0,invisible:!A,style:Lr(M,{x:0,y:0,text:"",verticalAlign:"middle",align:"center",fill:M.getTextColor(),font:M.getFont()}),z2:10}))},this);var c=v;if(h){var p=yt(u.get("moveHandleSize"),s[1]),d=i.moveHandle=new Tt({style:u.getModel("moveHandleStyle").getItemStyle(),silent:!0,shape:{r:[0,0,2,2],y:s[1]-.5,height:p}}),g=p*.8,y=i.moveHandleIcon=ir(u.get("moveHandleIcon"),-g/2,-g/2,g,g,"#fff",!0);y.silent=!0,y.y=s[1]+p/2-.5,d.ensureState("emphasis").style=u.getModel(["emphasis","moveHandleStyle"]).getItemStyle();var m=Math.min(s[1]/2,Math.max(p,10));c=i.moveZone=new Tt({invisible:!0,shape:{y:s[1]-m,height:p+m}}),c.on("mouseover",function(){l.enterEmphasis(d)}).on("mouseout",function(){l.leaveEmphasis(d)}),o.add(d),o.add(y),o.add(c)}c.attr({draggable:!0,cursor:Qg(this._orient),drift:U(this._onDragMove,this,"all"),ondragstart:U(this._showDataInfo,this,!0),ondragend:U(this._onDragEnd,this),onmouseover:U(this._showDataInfo,this,!0),onmouseout:U(this._showDataInfo,this,!1)})},t.prototype._resetInterval=function(){var e=this._range=this.dataZoomModel.getPercentRange(),i=this._getViewExtent();this._handleEnds=[bt(e[0],[0,100],i,!0),bt(e[1],[0,100],i,!0)]},t.prototype._updateInterval=function(e,i){var n=this.dataZoomModel,a=this._handleEnds,o=this._getViewExtent(),s=n.findRepresentativeAxisProxy().getMinMaxSpan(),u=[0,100];uu(i,a,o,n.get("zoomLock")?"all":e,s.minSpan!=null?bt(s.minSpan,u,o,!0):null,s.maxSpan!=null?bt(s.maxSpan,u,o,!0):null);var l=this._range,f=this._range=oi([bt(a[0],o,u,!0),bt(a[1],o,u,!0)]);return!l||l[0]!==f[0]||l[1]!==f[1]},t.prototype._updateView=function(e){var i=this._displayables,n=this._handleEnds,a=oi(n.slice()),o=this._size;T([0,1],function(c){var p=i.handles[c],d=this._handleHeight;p.attr({scaleX:d/2,scaleY:d/2,x:n[c]+(c?-1:1),y:o[1]/2-d/2})},this),i.filler.setShape({x:a[0],y:0,width:a[1]-a[0],height:o[1]});var s={x:a[0],width:a[1]-a[0]};i.moveHandle&&(i.moveHandle.setShape(s),i.moveZone.setShape(s),i.moveZone.getBoundingRect(),i.moveHandleIcon&&i.moveHandleIcon.attr("x",s.x+s.width/2));for(var u=i.dataShadowSegs,l=[0,a[0],a[1],o[0]],f=0;f<u.length;f++){var h=u[f],v=h.getClipPath();v||(v=new Tt,h.setClipPath(v)),v.setShape({x:l[f],y:0,width:l[f+1]-l[f],height:o[1]})}this._updateDataInfo(e)},t.prototype._updateDataInfo=function(e){var i=this.dataZoomModel,n=this._displayables,a=n.handleLabels,o=this._orient,s=["",""];if(i.get("showDetail")){var u=i.findRepresentativeAxisProxy();if(u){var l=u.getAxisModel().axis,f=this._range,h=e?u.calculateDataWindow({start:f[0],end:f[1]}).valueWindow:u.getDataValueWindow();s=[this._formatLabel(h[0],l),this._formatLabel(h[1],l)]}}var v=oi(this._handleEnds.slice());c.call(this,0),c.call(this,1);function c(p){var d=Ws(n.handles[p].parent,this.group),g=kh(p===0?"right":"left",d),y=this._handleWidth/2+RI,m=Ma([v[p]+(p===0?-y:y),this._size[1]/2],d);a[p].setStyle({x:m[0],y:m[1],verticalAlign:o===qn?"middle":g,align:o===qn?g:"center",text:s[p]})}},t.prototype._formatLabel=function(e,i){var n=this.dataZoomModel,a=n.get("labelFormatter"),o=n.get("labelPrecision");(o==null||o==="auto")&&(o=i.getPixelPrecision());var s=e==null||isNaN(e)?"":i.type==="category"||i.type==="time"?i.scale.getLabel({value:Math.round(e)}):e.toFixed(Math.min(o,20));return q(a)?a(e,s):H(a)?a.replace("{value}",s):s},t.prototype._showDataInfo=function(e){var i=this.dataZoomModel.get("handleLabel")||{},n=i.show||!1,a=this.dataZoomModel.getModel(["emphasis","handleLabel"]),o=a.get("show")||!1,s=e||this._dragging?o:n,u=this._displayables,l=u.handleLabels;l[0].attr("invisible",!s),l[1].attr("invisible",!s),u.moveHandle&&this.api[s?"enterEmphasis":"leaveEmphasis"](u.moveHandle,1)},t.prototype._onDragMove=function(e,i,n,a){this._dragging=!0,hn(a.event);var o=this._displayables.sliderGroup.getLocalTransform(),s=Ma([i,n],o,!0),u=this._updateInterval(e,s[0]),l=this.dataZoomModel.get("realtime");this._updateView(!l),u&&l&&this._dispatchZoomAction(!0)},t.prototype._onDragEnd=function(){this._dragging=!1,this._showDataInfo(!1);var e=this.dataZoomModel.get("realtime");!e&&this._dispatchZoomAction(!1)},t.prototype._onClickPanel=function(e){var i=this._size,n=this._displayables.sliderGroup.transformCoordToLocal(e.offsetX,e.offsetY);if(!(n[0]<0||n[0]>i[0]||n[1]<0||n[1]>i[1])){var a=this._handleEnds,o=(a[0]+a[1])/2,s=this._updateInterval("all",n[0]-o);this._updateView(),s&&this._dispatchZoomAction(!1)}},t.prototype._onBrushStart=function(e){var i=e.offsetX,n=e.offsetY;this._brushStart=new j(i,n),this._brushing=!0,this._brushStartTime=+new Date},t.prototype._onBrushEnd=function(e){if(this._brushing){var i=this._displayables.brushRect;if(this._brushing=!1,!!i){i.attr("ignore",!0);var n=i.shape,a=+new Date;if(!(a-this._brushStartTime<200&&Math.abs(n.width)<5)){var o=this._getViewExtent(),s=[0,100];this._range=oi([bt(n.x,o,s,!0),bt(n.x+n.width,o,s,!0)]),this._handleEnds=[n.x,n.x+n.width],this._updateView(),this._dispatchZoomAction(!1)}}}},t.prototype._onBrush=function(e){this._brushing&&(hn(e.event),this._updateBrushRect(e.offsetX,e.offsetY))},t.prototype._updateBrushRect=function(e,i){var n=this._displayables,a=this.dataZoomModel,o=n.brushRect;o||(o=n.brushRect=new $n({silent:!0,style:a.getModel("brushStyle").getItemStyle()}),n.sliderGroup.add(o)),o.attr("ignore",!1);var s=this._brushStart,u=this._displayables.sliderGroup,l=u.transformCoordToLocal(e,i),f=u.transformCoordToLocal(s.x,s.y),h=this._size;l[0]=Math.max(Math.min(h[0],l[0]),0),o.setShape({x:f[0],y:0,width:l[0]-f[0],height:h[1]})},t.prototype._dispatchZoomAction=function(e){var i=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,animation:e?kI:null,start:i[0],end:i[1]})},t.prototype._findCoordRect=function(){var e,i=a1(this.dataZoomModel).infoList;if(!e&&i.length){var n=i[0].model.coordinateSystem;e=n.getRect&&n.getRect()}if(!e){var a=this.api.getWidth(),o=this.api.getHeight();e={x:a*.2,y:o*.2,width:a*.6,height:o*.6}}return e},t.type="dataZoom.slider",t})(o1);function BI(r){var t={x:"y",y:"x",radius:"angle",angle:"radius"};return t[r]}function Qg(r){return r==="vertical"?"ns-resize":"ew-resize"}function NI(r){r.registerComponentModel(LI),r.registerComponentView(OI),s1(r)}function FI(r){Pr(AI),Pr(NI)}function Jg(r,t,e){var i=yn.createCanvas(),n=t.getWidth(),a=t.getHeight(),o=i.style;return o&&(o.position="absolute",o.left="0",o.top="0",o.width=n+"px",o.height=a+"px",i.setAttribute("data-zr-dom-id",r)),i.width=n*e,i.height=a*e,i}var Xl=(function(r){O(t,r);function t(e,i,n){var a=r.call(this)||this;a.motionBlur=!1,a.lastFrameAlpha=.7,a.dpr=1,a.virtual=!1,a.config={},a.incremental=!1,a.zlevel=0,a.maxRepaintRectCount=5,a.__dirty=!0,a.__firstTimePaint=!0,a.__used=!1,a.__drawIndex=0,a.__startIndex=0,a.__endIndex=0,a.__prevStartIndex=null,a.__prevEndIndex=null;var o;n=n||Jo,typeof e=="string"?o=Jg(e,i,n):W(e)&&(o=e,e=o.id),a.id=e,a.dom=o;var s=o.style;return s&&(oy(o),o.onselectstart=function(){return!1},s.padding="0",s.margin="0",s.borderWidth="0"),a.painter=i,a.dpr=n,a}return t.prototype.getElementCount=function(){return this.__endIndex-this.__startIndex},t.prototype.afterBrush=function(){this.__prevStartIndex=this.__startIndex,this.__prevEndIndex=this.__endIndex},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=Jg("back-"+this.id,this.painter,e),this.ctxBack=this.domBack.getContext("2d"),e!==1&&this.ctxBack.scale(e,e)},t.prototype.createRepaintRects=function(e,i,n,a){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var o=[],s=this.maxRepaintRectCount,u=!1,l=new et(0,0,0,0);function f(m){if(!(!m.isFinite()||m.isZero()))if(o.length===0){var _=new et(0,0,0,0);_.copy(m),o.push(_)}else{for(var S=!1,b=1/0,w=0,x=0;x<o.length;++x){var C=o[x];if(C.intersect(m)){var M=new et(0,0,0,0);M.copy(C),M.union(m),o[x]=M,S=!0;break}else if(u){l.copy(m),l.union(C);var D=m.width*m.height,A=C.width*C.height,P=l.width*l.height,R=P-D-A;R<b&&(b=R,w=x)}}if(u&&(o[w].union(m),S=!0),!S){var _=new et(0,0,0,0);_.copy(m),o.push(_)}u||(u=o.length>=s)}}for(var h=this.__startIndex;h<this.__endIndex;++h){var v=e[h];if(v){var c=v.shouldBePainted(n,a,!0,!0),p=v.__isRendered&&(v.__dirty&Jt||!c)?v.getPrevPaintRect():null;p&&f(p);var d=c&&(v.__dirty&Jt||!v.__isRendered)?v.getPaintRect():null;d&&f(d)}}for(var h=this.__prevStartIndex;h<this.__prevEndIndex;++h){var v=i[h],c=v&&v.shouldBePainted(n,a,!0,!0);if(v&&(!c||!v.__zr)&&v.__isRendered){var p=v.getPrevPaintRect();p&&f(p)}}var g;do{g=!1;for(var h=0;h<o.length;){if(o[h].isZero()){o.splice(h,1);continue}for(var y=h+1;y<o.length;)o[h].intersect(o[y])?(g=!0,o[h].union(o[y]),o.splice(y,1)):y++;h++}}while(g);return this._paintRects=o,o},t.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},t.prototype.resize=function(e,i){var n=this.dpr,a=this.dom,o=a.style,s=this.domBack;o&&(o.width=e+"px",o.height=i+"px"),a.width=e*n,a.height=i*n,s&&(s.width=e*n,s.height=i*n,n!==1&&this.ctxBack.scale(n,n))},t.prototype.clear=function(e,i,n){var a=this.dom,o=this.ctx,s=a.width,u=a.height;i=i||this.clearColor;var l=this.motionBlur&&!e,f=this.lastFrameAlpha,h=this.dpr,v=this;l&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(a,0,0,s/h,u/h));var c=this.domBack;function p(d,g,y,m){if(o.clearRect(d,g,y,m),i&&i!=="transparent"){var _=void 0;if(Ds(i)){var S=i.global||i.__width===y&&i.__height===m;_=S&&i.__canvasGradient||kf(o,i,{x:0,y:0,width:y,height:m}),i.__canvasGradient=_,i.__width=y,i.__height=m}else k1(i)&&(i.scaleX=i.scaleX||h,i.scaleY=i.scaleY||h,_=Of(o,i,{dirty:function(){v.setUnpainted(),v.painter.refresh()}}));o.save(),o.fillStyle=_||i,o.fillRect(d,g,y,m),o.restore()}l&&(o.save(),o.globalAlpha=f,o.drawImage(c,d,g,y,m),o.restore())}!n||l?p(0,0,s,u):n.length&&T(n,function(d){p(d.x*h,d.y*h,d.width*h,d.height*h)})},t})(de),jg=1e5,ii=314159,Io=.01,zI=.001;function VI(r){return r?r.__builtin__?!0:!(typeof r.resize!="function"||typeof r.refresh!="function"):!1}function HI(r,t){var e=document.createElement("div");return e.style.cssText=["position:relative","width:"+r+"px","height:"+t+"px","padding:0","margin:0","border-width:0"].join(";")+";",e}var GI=(function(){function r(t,e,i,n){this.type="canvas",this._zlevelList=[],this._prevDisplayList=[],this._layers={},this._layerConfig={},this._needsManuallyCompositing=!1,this.type="canvas";var a=!t.nodeName||t.nodeName.toUpperCase()==="CANVAS";this._opts=i=k({},i||{}),this.dpr=i.devicePixelRatio||Jo,this._singleCanvas=a,this.root=t;var o=t.style;o&&(oy(t),t.innerHTML=""),this.storage=e;var s=this._zlevelList;this._prevDisplayList=[];var u=this._layers;if(a){var f=t,h=f.width,v=f.height;i.width!=null&&(h=i.width),i.height!=null&&(v=i.height),this.dpr=i.devicePixelRatio||1,f.width=h*this.dpr,f.height=v*this.dpr,this._width=h,this._height=v;var c=new Xl(f,this,this.dpr);c.__builtin__=!0,c.initContext(),u[ii]=c,c.zlevel=ii,s.push(ii),this._domRoot=t}else{this._width=co(t,0,i),this._height=co(t,1,i);var l=this._domRoot=HI(this._width,this._height);t.appendChild(l)}}return r.prototype.getType=function(){return"canvas"},r.prototype.isSingleCanvas=function(){return this._singleCanvas},r.prototype.getViewportRoot=function(){return this._domRoot},r.prototype.getViewportRootOffset=function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},r.prototype.refresh=function(t){var e=this.storage.getDisplayList(!0),i=this._prevDisplayList,n=this._zlevelList;this._redrawId=Math.random(),this._paintList(e,i,t,this._redrawId);for(var a=0;a<n.length;a++){var o=n[a],s=this._layers[o];if(!s.__builtin__&&s.refresh){var u=a===0?this._backgroundColor:null;s.refresh(u)}}return this._opts.useDirtyRect&&(this._prevDisplayList=e.slice()),this},r.prototype.refreshHover=function(){this._paintHoverList(this.storage.getDisplayList(!1))},r.prototype._paintHoverList=function(t){var e=t.length,i=this._hoverlayer;if(i&&i.clear(),!!e){for(var n={inHover:!0,viewWidth:this._width,viewHeight:this._height},a,o=0;o<e;o++){var s=t[o];s.__inHover&&(i||(i=this._hoverlayer=this.getLayer(jg)),a||(a=i.ctx,a.save()),li(a,s,n,o===e-1))}a&&a.restore()}},r.prototype.getHoverLayer=function(){return this.getLayer(jg)},r.prototype.paintOne=function(t,e){C0(t,e)},r.prototype._paintList=function(t,e,i,n){if(this._redrawId===n){i=i||!1,this._updateLayerStatus(t);var a=this._doPaintList(t,e,i),o=a.finished,s=a.needsRefreshHover;if(this._needsManuallyCompositing&&this._compositeManually(),s&&this._paintHoverList(t),o)this.eachLayer(function(l){l.afterBrush&&l.afterBrush()});else{var u=this;Zo(function(){u._paintList(t,e,i,n)})}}},r.prototype._compositeManually=function(){var t=this.getLayer(ii).ctx,e=this._domRoot.width,i=this._domRoot.height;t.clearRect(0,0,e,i),this.eachBuiltinLayer(function(n){n.virtual&&t.drawImage(n.dom,0,0,e,i)})},r.prototype._doPaintList=function(t,e,i){for(var n=this,a=[],o=this._opts.useDirtyRect,s=0;s<this._zlevelList.length;s++){var u=this._zlevelList[s],l=this._layers[u];l.__builtin__&&l!==this._hoverlayer&&(l.__dirty||i)&&a.push(l)}for(var f=!0,h=!1,v=function(d){var g=a[d],y=g.ctx,m=o&&g.createRepaintRects(t,e,c._width,c._height),_=i?g.__startIndex:g.__drawIndex,S=!i&&g.incremental&&Date.now,b=S&&Date.now(),w=g.zlevel===c._zlevelList[0]?c._backgroundColor:null;if(g.__startIndex===g.__endIndex)g.clear(!1,w,m);else if(_===g.__startIndex){var x=t[_];(!x.incremental||!x.notClear||i)&&g.clear(!1,w,m)}_===-1&&(console.error("For some unknown reason. drawIndex is -1"),_=g.__startIndex);var C,M=function(R){var L={inHover:!1,allClipped:!1,prevEl:null,viewWidth:n._width,viewHeight:n._height};for(C=_;C<g.__endIndex;C++){var I=t[C];if(I.__inHover&&(h=!0),n._doPaintEl(I,g,o,R,L,C===g.__endIndex-1),S){var E=Date.now()-b;if(E>15)break}}L.prevElClipPaths&&y.restore()};if(m)if(m.length===0)C=g.__endIndex;else for(var D=c.dpr,A=0;A<m.length;++A){var P=m[A];y.save(),y.beginPath(),y.rect(P.x*D,P.y*D,P.width*D,P.height*D),y.clip(),M(P),y.restore()}else y.save(),M(),y.restore();g.__drawIndex=C,g.__drawIndex<g.__endIndex&&(f=!1)},c=this,p=0;p<a.length;p++)v(p);return Z.wxa&&T(this._layers,function(d){d&&d.ctx&&d.ctx.draw&&d.ctx.draw()}),{finished:f,needsRefreshHover:h}},r.prototype._doPaintEl=function(t,e,i,n,a,o){var s=e.ctx;if(i){var u=t.getPaintRect();(!n||u&&u.intersect(n))&&(li(s,t,a,o),t.setPrevPaintRect(u))}else li(s,t,a,o)},r.prototype.getLayer=function(t,e){this._singleCanvas&&!this._needsManuallyCompositing&&(t=ii);var i=this._layers[t];return i||(i=new Xl("zr_"+t,this,this.dpr),i.zlevel=t,i.__builtin__=!0,this._layerConfig[t]?tt(i,this._layerConfig[t],!0):this._layerConfig[t-Io]&&tt(i,this._layerConfig[t-Io],!0),e&&(i.virtual=e),this.insertLayer(t,i),i.initContext()),i},r.prototype.insertLayer=function(t,e){var i=this._layers,n=this._zlevelList,a=n.length,o=this._domRoot,s=null,u=-1;if(!i[t]&&VI(e)){if(a>0&&t>n[0]){for(u=0;u<a-1&&!(n[u]<t&&n[u+1]>t);u++);s=i[n[u]]}if(n.splice(u+1,0,t),i[t]=e,!e.virtual)if(s){var l=s.dom;l.nextSibling?o.insertBefore(e.dom,l.nextSibling):o.appendChild(e.dom)}else o.firstChild?o.insertBefore(e.dom,o.firstChild):o.appendChild(e.dom);e.painter||(e.painter=this)}},r.prototype.eachLayer=function(t,e){for(var i=this._zlevelList,n=0;n<i.length;n++){var a=i[n];t.call(e,this._layers[a],a)}},r.prototype.eachBuiltinLayer=function(t,e){for(var i=this._zlevelList,n=0;n<i.length;n++){var a=i[n],o=this._layers[a];o.__builtin__&&t.call(e,o,a)}},r.prototype.eachOtherLayer=function(t,e){for(var i=this._zlevelList,n=0;n<i.length;n++){var a=i[n],o=this._layers[a];o.__builtin__||t.call(e,o,a)}},r.prototype.getLayers=function(){return this._layers},r.prototype._updateLayerStatus=function(t){this.eachBuiltinLayer(function(h,v){h.__dirty=h.__used=!1});function e(h){a&&(a.__endIndex!==h&&(a.__dirty=!0),a.__endIndex=h)}if(this._singleCanvas)for(var i=1;i<t.length;i++){var n=t[i];if(n.zlevel!==t[i-1].zlevel||n.incremental){this._needsManuallyCompositing=!0;break}}var a=null,o=0,s,u;for(u=0;u<t.length;u++){var n=t[u],l=n.zlevel,f=void 0;s!==l&&(s=l,o=0),n.incremental?(f=this.getLayer(l+zI,this._needsManuallyCompositing),f.incremental=!0,o=1):f=this.getLayer(l+(o>0?Io:0),this._needsManuallyCompositing),f.__builtin__||ch("ZLevel "+l+" has been used by unkown layer "+f.id),f!==a&&(f.__used=!0,f.__startIndex!==u&&(f.__dirty=!0),f.__startIndex=u,f.incremental?f.__drawIndex=-1:f.__drawIndex=u,e(u),a=f),n.__dirty&Jt&&!n.__inHover&&(f.__dirty=!0,f.incremental&&f.__drawIndex<0&&(f.__drawIndex=u))}e(u),this.eachBuiltinLayer(function(h,v){!h.__used&&h.getElementCount()>0&&(h.__dirty=!0,h.__startIndex=h.__endIndex=h.__drawIndex=0),h.__dirty&&h.__drawIndex<0&&(h.__drawIndex=h.__startIndex)})},r.prototype.clear=function(){return this.eachBuiltinLayer(this._clearLayer),this},r.prototype._clearLayer=function(t){t.clear()},r.prototype.setBackgroundColor=function(t){this._backgroundColor=t,T(this._layers,function(e){e.setUnpainted()})},r.prototype.configLayer=function(t,e){if(e){var i=this._layerConfig;i[t]?tt(i[t],e,!0):i[t]=e;for(var n=0;n<this._zlevelList.length;n++){var a=this._zlevelList[n];if(a===t||a===t+Io){var o=this._layers[a];tt(o,i[t],!0)}}}},r.prototype.delLayer=function(t){var e=this._layers,i=this._zlevelList,n=e[t];n&&(n.dom.parentNode.removeChild(n.dom),delete e[t],i.splice(Q(i,t),1))},r.prototype.resize=function(t,e){if(this._domRoot.style){var i=this._domRoot;i.style.display="none";var n=this._opts,a=this.root;if(t!=null&&(n.width=t),e!=null&&(n.height=e),t=co(a,0,n),e=co(a,1,n),i.style.display="",this._width!==t||e!==this._height){i.style.width=t+"px",i.style.height=e+"px";for(var o in this._layers)this._layers.hasOwnProperty(o)&&this._layers[o].resize(t,e);this.refresh(!0)}this._width=t,this._height=e}else{if(t==null||e==null)return;this._width=t,this._height=e,this.getLayer(ii).resize(t,e)}return this},r.prototype.clearLayer=function(t){var e=this._layers[t];e&&e.clear()},r.prototype.dispose=function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._layers=null},r.prototype.getRenderedCanvas=function(t){if(t=t||{},this._singleCanvas&&!this._compositeManually)return this._layers[ii].dom;var e=new Xl("image",this,t.pixelRatio||this.dpr);e.initContext(),e.clear(!1,t.backgroundColor||this._backgroundColor);var i=e.ctx;if(t.pixelRatio<=this.dpr){this.refresh();var n=e.dom.width,a=e.dom.height;this.eachLayer(function(h){h.__builtin__?i.drawImage(h.dom,0,0,n,a):h.renderToCanvas&&(i.save(),h.renderToCanvas(i),i.restore())})}else for(var o={inHover:!1,viewWidth:this._width,viewHeight:this._height},s=this.storage.getDisplayList(!0),u=0,l=s.length;u<l;u++){var f=s[u];li(i,f,o,u===l-1)}return e.dom},r.prototype.getWidth=function(){return this._width},r.prototype.getHeight=function(){return this._height},r})();function WI(r){r.registerPainter("canvas",GI)}Pr([z2,OA,mL,rI,FI,fP,mI,vI,VP,hA,WI]);$D({type:"toolbox"});qD({type:"toolbox"});function YI({option:r,overlay:t,height:e,ariaLabel:i,onEvents:n,onReady:a,onDrawn:o}){const s=kr.useRef(null),u=kr.useRef(null),l=kr.useRef({overlay:t,onDrawn:o});return l.current={overlay:t,onDrawn:o},kr.useEffect(()=>{if(!s.current)return;const f=MC(s.current,void 0,{renderer:"canvas"});u.current=f;const h=a==null?void 0:a(f),v=typeof ResizeObserver<"u"?new ResizeObserver(()=>f.resize()):null;return v==null||v.observe(s.current),()=>{typeof h=="function"&&h(),v==null||v.disconnect(),f.dispose(),u.current=null}},[]),kr.useEffect(()=>{var h,v;const f=u.current;f&&(f.setOption(r,{notMerge:!0}),l.current.overlay&&f.setOption(l.current.overlay),(v=(h=l.current).onDrawn)==null||v.call(h,f))},[r]),kr.useEffect(()=>{var f;t&&((f=u.current)==null||f.setOption(t,{lazyUpdate:!0}))},[t]),kr.useEffect(()=>{const f=u.current;if(!f||!n)return;const h=Object.entries(n);for(const[v,c]of h)f.on(v,c);return()=>{if(!f.isDisposed())for(const[v,c]of h)f.off(v,c)}},[n]),y1.jsx("div",{ref:s,role:"img","aria-label":i,style:{width:"100%",height:e,overflow:"hidden"}})}export{YI as default};