ezllm 0.0.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.
- package/LICENSE +21 -0
- package/README.md +57 -0
- package/bin/ellm-proxy.js +3 -0
- package/dist/cli.js +27667 -0
- package/dist/package.json +1 -0
- package/dist/server.js +42403 -0
- package/dist/web-ui/assets/DashboardView-DwlQExQv.css +1 -0
- package/dist/web-ui/assets/DashboardView-fRDkGq0g.js +1 -0
- package/dist/web-ui/assets/LayoutView-CK_MaWN7.js +1 -0
- package/dist/web-ui/assets/LayoutView-kZ2yGen8.css +1 -0
- package/dist/web-ui/assets/LoginView-B1naaT8E.js +1 -0
- package/dist/web-ui/assets/LoginView-CSfb59pE.css +1 -0
- package/dist/web-ui/assets/LogsView-CCjJTjvZ.css +1 -0
- package/dist/web-ui/assets/LogsView-YtH8gJPU.js +9 -0
- package/dist/web-ui/assets/ProvidersView-Caqpg_0F.css +1 -0
- package/dist/web-ui/assets/ProvidersView-DWtS_e7t.js +31 -0
- package/dist/web-ui/assets/ServiceStatusView-D3ybS2T-.js +39 -0
- package/dist/web-ui/assets/ServiceStatusView-DrPoYMN-.css +1 -0
- package/dist/web-ui/assets/SettingsView-D1kbH5Ev.css +1 -0
- package/dist/web-ui/assets/SettingsView-DepOaZYg.js +1 -0
- package/dist/web-ui/assets/SetupView-BwDwokAd.js +1 -0
- package/dist/web-ui/assets/SetupView-pS9nSnLg.css +1 -0
- package/dist/web-ui/assets/clipboard-aCBIMfw7.js +1 -0
- package/dist/web-ui/assets/config-CdOq1p3C.js +1 -0
- package/dist/web-ui/assets/format-kTdM4RVv.js +1 -0
- package/dist/web-ui/assets/index-BecfPmag.css +1 -0
- package/dist/web-ui/assets/index-CgzCvxTY.js +96 -0
- package/dist/web-ui/assets/providers-i7t_wEzk.js +1 -0
- package/dist/web-ui/assets/useLoadError-UA3r7sR9.js +1 -0
- package/dist/web-ui/assets/useManagerApi-CBQNomtR.js +1 -0
- package/dist/web-ui/assets/useToast-DNMhOOeI.js +1 -0
- package/dist/web-ui/assets/version-BKHjE_LF.js +1 -0
- package/dist/web-ui/config.js +7 -0
- package/dist/web-ui/index.html +15 -0
- package/docs/DESIGN.md +90 -0
- package/ezllm.config.example.json +33 -0
- package/package.json +55 -0
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import{d as Y_,l as X_,y as $_,e as _r,i as Pv,c as Yr,w as At,j as Sl,h as Gt,A as Za,a as ce,r as de,ad as Ev,o as qt,g as Pe,b as qa,ae as bl,f as Ee,F as Ka,t as Qa,z as Rv,p as kv,k as Z_,af as q_,_ as K_}from"./index-CgzCvxTY.js";import{u as Q_}from"./useToast-DNMhOOeI.js";import{u as J_}from"./useLoadError-UA3r7sR9.js";import{c as j_}from"./clipboard-aCBIMfw7.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 Yu=function(e,t){return Yu=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,n){r.__proto__=n}||function(r,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(r[i]=n[i])},Yu(e,t)};function V(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Yu(e,t);function r(){this.constructor=e}e.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}var t1=(function(){function e(){this.firefox=!1,this.ie=!1,this.edge=!1,this.newEdge=!1,this.weChat=!1}return e})(),e1=(function(){function e(){this.browser=new t1,this.node=!1,this.wxa=!1,this.worker=!1,this.svgSupported=!1,this.touchEventsSupported=!1,this.pointerEventsSupported=!1,this.domSupported=!1,this.transformSupported=!1,this.transform3dSupported=!1,this.hasGlobalWindow=typeof window<"u"}return e})(),st=new e1;typeof wx=="object"&&typeof wx.getSystemInfoSync=="function"?(st.wxa=!0,st.touchEventsSupported=!0):typeof document>"u"&&typeof self<"u"?st.worker=!0:!st.hasGlobalWindow||"Deno"in window||typeof navigator<"u"&&typeof navigator.userAgent=="string"&&navigator.userAgent.indexOf("Node.js")>-1?(st.node=!0,st.svgSupported=!0):r1(navigator.userAgent,st);function r1(e,t){var r=t.browser,n=e.match(/Firefox\/([\d.]+)/),i=e.match(/MSIE\s([\d.]+)/)||e.match(/Trident\/.+?rv:(([\d.]+))/),a=e.match(/Edge?\/([\d.]+)/),o=/micromessenger/i.test(e);n&&(r.firefox=!0,r.version=n[1]),i&&(r.ie=!0,r.version=i[1]),a&&(r.edge=!0,r.version=a[1],r.newEdge=+a[1].split(".")[0]>18),o&&(r.weChat=!0),t.svgSupported=typeof SVGRect<"u",t.touchEventsSupported="ontouchstart"in window&&!r.ie&&!r.edge,t.pointerEventsSupported="onpointerdown"in window&&(r.edge||r.ie&&+r.version>=11);var s=t.domSupported=typeof document<"u";if(s){var l=document.documentElement.style;t.transform3dSupported=(r.ie&&"transition"in l||r.edge||"WebKitCSSMatrix"in window&&"m11"in new WebKitCSSMatrix||"MozPerspective"in l)&&!("OTransition"in l),t.transformSupported=t.transform3dSupported||r.ie&&+r.version>=9}}var uh=12,n1="sans-serif",Nr=uh+"px "+n1,i1=20,a1=100,o1="007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N";function s1(e){var t={};if(typeof JSON>"u")return t;for(var r=0;r<e.length;r++){var n=String.fromCharCode(r+32),i=(e.charCodeAt(r)-i1)/a1;t[n]=i}return t}var l1=s1(o1),ue={createCanvas:function(){return typeof document<"u"&&document.createElement("canvas")},measureText:(function(){var e,t;return function(r,n){if(!e){var i=ue.createCanvas();e=i&&i.getContext("2d")}if(e)return t!==n&&(t=e.font=n||Nr),e.measureText(r);r=r||"",n=n||Nr;var a=/((?:\d+)?\.?\d*)px/.exec(n),o=a&&+a[1]||uh,s=0;if(n.indexOf("mono")>=0)s=o*r.length;else for(var l=0;l<r.length;l++){var u=l1[r[l]];s+=u==null?o:u*o}return{width:s}}})(),loadImage:function(e,t,r){var n=new Image;return n.onload=t,n.onerror=r,n.src=e,n},getTime:function(){return Date.now?Date.now():+new Date}},Rg=wi(["Function","RegExp","Date","Error","CanvasGradient","CanvasPattern","Image","Canvas"],function(e,t){return e["[object "+t+"]"]=!0,e},{}),kg=wi(["Int8","Uint8","Uint8Clamped","Int16","Uint16","Int32","Uint32","Float32","Float64"],function(e,t){return e["[object "+t+"Array]"]=!0,e},{}),Ra=Object.prototype.toString,Xs=Array.prototype,u1=Xs.forEach,f1=Xs.filter,fh=Xs.slice,h1=Xs.map,Ov=(function(){}).constructor,Ja=Ov?Ov.prototype:null,hh="__proto__",Tl=2311,v1=Math.pow(2,53)-1;function Og(){return Tl>=v1&&(Tl=0),Tl++}function vh(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];typeof console<"u"&&console.error.apply(console,e)}function ut(e){if(e==null||typeof e!="object")return e;var t=e,r=Ra.call(e);if(r==="[object Array]"){if(!ea(e)){t=[];for(var n=0,i=e.length;n<i;n++)t[n]=ut(e[n])}}else if(kg[r]){if(!ea(e)){var a=e.constructor;if(a.from)t=a.from(e);else{t=new a(e.length);for(var n=0,i=e.length;n<i;n++)t[n]=e[n]}}}else if(!Rg[r]&&!ea(e)&&!pa(e)){t={};for(var o in e)e.hasOwnProperty(o)&&o!==hh&&(t[o]=ut(e[o]))}return t}function ct(e,t,r){if(!K(t)||!K(e))return r?ut(t):e;for(var n in t)if(t.hasOwnProperty(n)&&n!==hh){var i=e[n],a=t[n];K(a)&&K(i)&&!H(a)&&!H(i)&&!pa(a)&&!pa(i)&&!Bv(a)&&!Bv(i)&&!ea(a)&&!ea(i)?ct(i,a,r):(r||!(n in e))&&(e[n]=ut(t[n]))}return e}function N(e,t){if(Object.assign)Object.assign(e,t);else for(var r in t)t.hasOwnProperty(r)&&r!==hh&&(e[r]=t[r]);return e}function c1(e,t,r){e=e||{};for(var n=0;n<r.length;n++){var i=r[n];e[i]=t[i]}return e}function yt(e,t,r){for(var n=xt(t),i=0,a=n.length;i<a;i++){var o=n[i];e[o]==null&&(e[o]=t[o])}return e}function vt(e,t){if(e){if(e.indexOf)return e.indexOf(t);for(var r=0,n=e.length;r<n;r++)if(e[r]===t)return r}return-1}function d1(e,t){var r=e.prototype;function n(){}n.prototype=t.prototype,e.prototype=new n;for(var i in r)r.hasOwnProperty(i)&&(e.prototype[i]=r[i]);e.prototype.constructor=e,e.superClass=t}function ar(e,t,r){if(e="prototype"in e?e.prototype:e,t="prototype"in t?t.prototype:t,Object.getOwnPropertyNames)for(var n=Object.getOwnPropertyNames(t),i=0;i<n.length;i++){var a=n[i];a!=="constructor"&&e[a]==null&&(e[a]=t[a])}else yt(e,t)}function ie(e){return!e||typeof e=="string"?!1:typeof e.length=="number"}function D(e,t,r){if(e&&t)if(e.forEach&&e.forEach===u1)e.forEach(t,r);else if(e.length===+e.length)for(var n=0,i=e.length;n<i;n++)t.call(r,e[n],n,e);else for(var a in e)e.hasOwnProperty(a)&&t.call(r,e[a],a,e)}function rt(e,t,r){if(!e)return[];if(!t)return ch(e);if(e.map&&e.map===h1)return e.map(t,r);for(var n=[],i=0,a=e.length;i<a;i++)n.push(t.call(r,e[i],i,e));return n}function wi(e,t,r,n){if(e&&t){for(var i=0,a=e.length;i<a;i++)r=t.call(n,r,e[i],i,e);return r}}function Xt(e,t,r){if(!e)return[];if(!t)return ch(e);if(e.filter&&e.filter===f1)return e.filter(t,r);for(var n=[],i=0,a=e.length;i<a;i++)t.call(r,e[i],i,e)&&n.push(e[i]);return n}function p1(e,t,r){if(e&&t){for(var n=0,i=e.length;n<i;n++)if(t.call(r,e[n],n,e))return e[n]}}function xt(e){if(!e)return[];if(Object.keys)return Object.keys(e);var t=[];for(var r in e)e.hasOwnProperty(r)&&t.push(r);return t}function g1(e,t){for(var r=[],n=2;n<arguments.length;n++)r[n-2]=arguments[n];return function(){return e.apply(t,r.concat(fh.call(arguments)))}}var wt=Ja&&ot(Ja.bind)?Ja.call.bind(Ja.bind):g1;function Et(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];return function(){return e.apply(this,t.concat(fh.call(arguments)))}}function H(e){return Array.isArray?Array.isArray(e):Ra.call(e)==="[object Array]"}function ot(e){return typeof e=="function"}function W(e){return typeof e=="string"}function Xu(e){return Ra.call(e)==="[object String]"}function Ct(e){return typeof e=="number"}function K(e){var t=typeof e;return t==="function"||!!e&&t==="object"}function Bv(e){return!!Rg[Ra.call(e)]}function ae(e){return!!kg[Ra.call(e)]}function pa(e){return typeof e=="object"&&typeof e.nodeType=="number"&&typeof e.ownerDocument=="object"}function $s(e){return e.colorStops!=null}function m1(e){return e.image!=null}function ga(e){return e!==e}function us(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var r=0,n=e.length;r<n;r++)if(e[r]!=null)return e[r]}function j(e,t){return e??t}function ai(e,t,r){return e??t??r}function ch(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];return fh.apply(e,t)}function dh(e){if(typeof e=="number")return[e,e,e,e];var t=e.length;return t===2?[e[0],e[1],e[0],e[1]]:t===3?[e[0],e[1],e[2],e[1]]:e}function pr(e,t){if(!e)throw new Error(t)}function $e(e){return e==null?null:typeof e.trim=="function"?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}var Bg="__ec_primitive__";function $u(e){e[Bg]=!0}function ea(e){return e[Bg]}var y1=(function(){function e(){this.data={}}return e.prototype.delete=function(t){var r=this.has(t);return r&&delete this.data[t],r},e.prototype.has=function(t){return this.data.hasOwnProperty(t)},e.prototype.get=function(t){return this.data[t]},e.prototype.set=function(t,r){return this.data[t]=r,this},e.prototype.keys=function(){return xt(this.data)},e.prototype.forEach=function(t){var r=this.data;for(var n in r)r.hasOwnProperty(n)&&t(r[n],n)},e})(),Ng=typeof Map=="function";function _1(){return Ng?new Map:new y1}var S1=(function(){function e(t){var r=H(t);this.data=_1();var n=this;t instanceof e?t.each(i):t&&D(t,i);function i(a,o){r?n.set(a,o):n.set(o,a)}}return e.prototype.hasKey=function(t){return this.data.has(t)},e.prototype.get=function(t){return this.data.get(t)},e.prototype.set=function(t,r){return this.data.set(t,r),r},e.prototype.each=function(t,r){this.data.forEach(function(n,i){t.call(r,n,i)})},e.prototype.keys=function(){var t=this.data.keys();return Ng?Array.from(t):t},e.prototype.removeKey=function(t){this.data.delete(t)},e})();function nt(e){return new S1(e)}function b1(e,t){for(var r=new e.constructor(e.length+t.length),n=0;n<e.length;n++)r[n]=e[n];for(var i=e.length,n=0;n<t.length;n++)r[n+i]=t[n];return r}function Zs(e,t){var r;if(Object.create)r=Object.create(e);else{var n=function(){};n.prototype=e,r=new n}return t&&N(r,t),r}function Fg(e){var t=e.style;t.webkitUserSelect="none",t.userSelect="none",t.webkitTapHighlightColor="rgba(0,0,0,0)",t["-webkit-touch-callout"]="none"}function fe(e,t){return e.hasOwnProperty(t)}function $t(){}var T1=180/Math.PI;function xi(e,t){return e==null&&(e=0),t==null&&(t=0),[e,t]}function w1(e){return[e[0],e[1]]}function wl(e,t,r){return e[0]=t,e[1]=r,e}function Nv(e,t,r){return e[0]=t[0]+r[0],e[1]=t[1]+r[1],e}function x1(e,t,r){return e[0]=t[0]-r[0],e[1]=t[1]-r[1],e}function C1(e){return Math.sqrt(D1(e))}function D1(e){return e[0]*e[0]+e[1]*e[1]}function xl(e,t,r){return e[0]=t[0]*r,e[1]=t[1]*r,e}function M1(e,t){var r=C1(t);return r===0?(e[0]=0,e[1]=0):(e[0]=t[0]/r,e[1]=t[1]/r),e}function Zu(e,t){return Math.sqrt((e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1]))}var A1=Zu;function L1(e,t){return(e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1])}var oi=L1;function Ae(e,t,r){var n=t[0],i=t[1];return e[0]=r[0]*n+r[2]*i+r[4],e[1]=r[1]*n+r[3]*i+r[5],e}function Jn(e,t,r){return e[0]=Math.min(t[0],r[0]),e[1]=Math.min(t[1],r[1]),e}function jn(e,t,r){return e[0]=Math.max(t[0],r[0]),e[1]=Math.max(t[1],r[1]),e}var kn=(function(){function e(t,r){this.target=t,this.topTarget=r&&r.topTarget}return e})(),I1=(function(){function e(t){this.handler=t,t.on("mousedown",this._dragStart,this),t.on("mousemove",this._drag,this),t.on("mouseup",this._dragEnd,this)}return e.prototype._dragStart=function(t){for(var r=t.target;r&&!r.draggable;)r=r.parent||r.__hostTarget;r&&(this._draggingTarget=r,r.dragging=!0,this._x=t.offsetX,this._y=t.offsetY,this.handler.dispatchToElement(new kn(r,t),"dragstart",t.event))},e.prototype._drag=function(t){var r=this._draggingTarget;if(r){var n=t.offsetX,i=t.offsetY,a=n-this._x,o=i-this._y;this._x=n,this._y=i,r.drift(a,o,t),this.handler.dispatchToElement(new kn(r,t),"drag",t.event);var s=this.handler.findHover(n,i,r).target,l=this._dropTarget;this._dropTarget=s,r!==s&&(l&&s!==l&&this.handler.dispatchToElement(new kn(l,t),"dragleave",t.event),s&&s!==l&&this.handler.dispatchToElement(new kn(s,t),"dragenter",t.event))}},e.prototype._dragEnd=function(t){var r=this._draggingTarget;r&&(r.dragging=!1),this.handler.dispatchToElement(new kn(r,t),"dragend",t.event),this._dropTarget&&this.handler.dispatchToElement(new kn(this._dropTarget,t),"drop",t.event),this._draggingTarget=null,this._dropTarget=null},e})(),or=(function(){function e(t){t&&(this._$eventProcessor=t)}return e.prototype.on=function(t,r,n,i){this._$handlers||(this._$handlers={});var a=this._$handlers;if(typeof r=="function"&&(i=n,n=r,r=null),!n||!t)return this;var o=this._$eventProcessor;r!=null&&o&&o.normalizeQuery&&(r=o.normalizeQuery(r)),a[t]||(a[t]=[]);for(var s=0;s<a[t].length;s++)if(a[t][s].h===n)return this;var l={h:n,query:r,ctx:i||this,callAtLast:n.zrEventfulCallAtLast},u=a[t].length-1,f=a[t][u];return f&&f.callAtLast?a[t].splice(u,0,l):a[t].push(l),this},e.prototype.isSilent=function(t){var r=this._$handlers;return!r||!r[t]||!r[t].length},e.prototype.off=function(t,r){var n=this._$handlers;if(!n)return this;if(!t)return this._$handlers={},this;if(r){if(n[t]){for(var i=[],a=0,o=n[t].length;a<o;a++)n[t][a].h!==r&&i.push(n[t][a]);n[t]=i}n[t]&&n[t].length===0&&delete n[t]}else delete n[t];return this},e.prototype.trigger=function(t){for(var r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];if(!this._$handlers)return this;var i=this._$handlers[t],a=this._$eventProcessor;if(i)for(var o=r.length,s=i.length,l=0;l<s;l++){var u=i[l];if(!(a&&a.filter&&u.query!=null&&!a.filter(t,u.query)))switch(o){case 0:u.h.call(u.ctx);break;case 1:u.h.call(u.ctx,r[0]);break;case 2:u.h.call(u.ctx,r[0],r[1]);break;default:u.h.apply(u.ctx,r);break}}return a&&a.afterTrigger&&a.afterTrigger(t),this},e.prototype.triggerWithContext=function(t){for(var r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];if(!this._$handlers)return this;var i=this._$handlers[t],a=this._$eventProcessor;if(i)for(var o=r.length,s=r[o-1],l=i.length,u=0;u<l;u++){var f=i[u];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,r[0]);break;case 2:f.h.call(s,r[0],r[1]);break;default:f.h.apply(s,r.slice(1,o-1));break}}return a&&a.afterTrigger&&a.afterTrigger(t),this},e})(),P1=Math.log(2);function qu(e,t,r,n,i,a){var o=n+"-"+i,s=e.length;if(a.hasOwnProperty(o))return a[o];if(t===1){var l=Math.round(Math.log((1<<s)-1&~i)/P1);return e[r][l]}for(var u=n|1<<r,f=r+1;n&1<<f;)f++;for(var h=0,v=0,c=0;v<s;v++){var d=1<<v;d&i||(h+=(c%2?-1:1)*e[r][v]*qu(e,t-1,f,u,i|d,a),c++)}return a[o]=h,h}function Fv(e,t){var r=[[e[0],e[1],1,0,0,0,-t[0]*e[0],-t[0]*e[1]],[0,0,0,e[0],e[1],1,-t[1]*e[0],-t[1]*e[1]],[e[2],e[3],1,0,0,0,-t[2]*e[2],-t[2]*e[3]],[0,0,0,e[2],e[3],1,-t[3]*e[2],-t[3]*e[3]],[e[4],e[5],1,0,0,0,-t[4]*e[4],-t[4]*e[5]],[0,0,0,e[4],e[5],1,-t[5]*e[4],-t[5]*e[5]],[e[6],e[7],1,0,0,0,-t[6]*e[6],-t[6]*e[7]],[0,0,0,e[6],e[7],1,-t[7]*e[6],-t[7]*e[7]]],n={},i=qu(r,8,0,0,0,n);if(i!==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)*qu(r,7,o===0?1:0,1<<o,1<<s,n)/i*t[o];return function(l,u,f){var h=u*a[6]+f*a[7]+1;l[0]=(u*a[0]+f*a[1]+a[2])/h,l[1]=(u*a[3]+f*a[4]+a[5])/h}}}var fs="___zrEVENTSAVED",Cl=[];function E1(e,t,r,n,i){return Ku(Cl,t,n,i,!0)&&Ku(e,r,Cl[0],Cl[1])}function R1(e,t){e&&r(e),t&&r(t);function r(n){var i=n[fs];i&&(i.clearMarkers&&i.clearMarkers(),delete n[fs])}}function Ku(e,t,r,n,i){if(t.getBoundingClientRect&&st.domSupported&&!zg(t)){var a=t[fs]||(t[fs]={}),o=k1(t,a),s=O1(o,a,i);if(s)return s(e,r,n),!0}return!1}function k1(e,t){var r=t.markers;if(r)return r;r=t.markers=[];for(var n=["left","right"],i=["top","bottom"],a=0;a<4;a++){var o=document.createElement("div"),s=o.style,l=a%2,u=(a>>1)%2;s.cssText=["position: absolute","visibility: hidden","padding: 0","margin: 0","border-width: 0","user-select: none","width:0","height:0",n[l]+":0",i[u]+":0",n[1-l]+":auto",i[1-u]+":auto",""].join("!important;"),e.appendChild(o),r.push(o)}return t.clearMarkers=function(){D(r,function(f){f.parentNode&&f.parentNode.removeChild(f)})},r}function O1(e,t,r){for(var n=r?"invTrans":"trans",i=t[n],a=t.srcCoords,o=[],s=[],l=!0,u=0;u<4;u++){var f=e[u].getBoundingClientRect(),h=2*u,v=f.left,c=f.top;o.push(v,c),l=l&&a&&v===a[h]&&c===a[h+1],s.push(e[u].offsetLeft,e[u].offsetTop)}return l&&i?i:(t.srcCoords=o,t[n]=r?Fv(s,o):Fv(o,s))}function zg(e){return e.nodeName.toUpperCase()==="CANVAS"}var B1=/([&<>"'])/g,N1={"&":"&","<":"<",">":">",'"':""","'":"'"};function te(e){return e==null?"":(e+"").replace(B1,function(t,r){return N1[r]})}var F1=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Dl=[],z1=st.browser.firefox&&+st.browser.version.split(".")[0]<39;function Qu(e,t,r,n){return r=r||{},n?zv(e,t,r):z1&&t.layerX!=null&&t.layerX!==t.offsetX?(r.zrX=t.layerX,r.zrY=t.layerY):t.offsetX!=null?(r.zrX=t.offsetX,r.zrY=t.offsetY):zv(e,t,r),r}function zv(e,t,r){if(st.domSupported&&e.getBoundingClientRect){var n=t.clientX,i=t.clientY;if(zg(e)){var a=e.getBoundingClientRect();r.zrX=n-a.left,r.zrY=i-a.top;return}else if(Ku(Dl,e,n,i)){r.zrX=Dl[0],r.zrY=Dl[1];return}}r.zrX=r.zrY=0}function ph(e){return e||window.event}function ye(e,t,r){if(t=ph(t),t.zrX!=null)return t;var n=t.type,i=n&&n.indexOf("touch")>=0;if(i){var o=n!=="touchend"?t.targetTouches[0]:t.changedTouches[0];o&&Qu(e,o,t,r)}else{Qu(e,t,t,r);var a=H1(t);t.zrDelta=a?a/120:-(t.detail||0)/3}var s=t.button;return t.which==null&&s!==void 0&&F1.test(t.type)&&(t.which=s&1?1:s&2?3:s&4?2:0),t}function H1(e){var t=e.wheelDelta;if(t)return t;var r=e.deltaX,n=e.deltaY;if(r==null||n==null)return t;var i=Math.abs(n!==0?n:r),a=n>0?-1:n<0?1:r>0?-1:1;return 3*i*a}function V1(e,t,r,n){e.addEventListener(t,r,n)}function G1(e,t,r,n){e.removeEventListener(t,r,n)}var Hg=function(e){e.preventDefault(),e.stopPropagation(),e.cancelBubble=!0},U1=(function(){function e(){this._track=[]}return e.prototype.recognize=function(t,r,n){return this._doTrack(t,r,n),this._recognize(t)},e.prototype.clear=function(){return this._track.length=0,this},e.prototype._doTrack=function(t,r,n){var i=t.touches;if(i){for(var a={points:[],touches:[],target:r,event:t},o=0,s=i.length;o<s;o++){var l=i[o],u=Qu(n,l,{});a.points.push([u.zrX,u.zrY]),a.touches.push(l)}this._track.push(a)}},e.prototype._recognize=function(t){for(var r in Ml)if(Ml.hasOwnProperty(r)){var n=Ml[r](this._track,t);if(n)return n}},e})();function Hv(e){var t=e[1][0]-e[0][0],r=e[1][1]-e[0][1];return Math.sqrt(t*t+r*r)}function W1(e){return[(e[0][0]+e[1][0])/2,(e[0][1]+e[1][1])/2]}var Ml={pinch:function(e,t){var r=e.length;if(r){var n=(e[r-1]||{}).points,i=(e[r-2]||{}).points||n;if(i&&i.length>1&&n&&n.length>1){var a=Hv(n)/Hv(i);!isFinite(a)&&(a=1),t.pinchScale=a;var o=W1(n);return t.pinchX=o[0],t.pinchY=o[1],{type:"pinch",target:e[0].target,event:t}}}}};function qe(){return[1,0,0,1,0,0]}function ka(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=1,e[4]=0,e[5]=0,e}function gh(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e}function ra(e,t,r){var n=t[0]*r[0]+t[2]*r[1],i=t[1]*r[0]+t[3]*r[1],a=t[0]*r[2]+t[2]*r[3],o=t[1]*r[2]+t[3]*r[3],s=t[0]*r[4]+t[2]*r[5]+t[4],l=t[1]*r[4]+t[3]*r[5]+t[5];return e[0]=n,e[1]=i,e[2]=a,e[3]=o,e[4]=s,e[5]=l,e}function Ju(e,t,r){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4]+r[0],e[5]=t[5]+r[1],e}function mh(e,t,r,n){n===void 0&&(n=[0,0]);var i=t[0],a=t[2],o=t[4],s=t[1],l=t[3],u=t[5],f=Math.sin(r),h=Math.cos(r);return e[0]=i*h+s*f,e[1]=-i*f+s*h,e[2]=a*h+l*f,e[3]=-a*f+h*l,e[4]=h*(o-n[0])+f*(u-n[1])+n[0],e[5]=h*(u-n[1])-f*(o-n[0])+n[1],e}function Y1(e,t,r){var n=r[0],i=r[1];return e[0]=t[0]*n,e[1]=t[1]*i,e[2]=t[2]*n,e[3]=t[3]*i,e[4]=t[4]*n,e[5]=t[5]*i,e}function Oa(e,t){var r=t[0],n=t[2],i=t[4],a=t[1],o=t[3],s=t[5],l=r*o-a*n;return l?(l=1/l,e[0]=o*l,e[1]=-a*l,e[2]=-n*l,e[3]=r*l,e[4]=(n*s-o*i)*l,e[5]=(a*i-r*s)*l,e):null}var _t=(function(){function e(t,r){this.x=t||0,this.y=r||0}return e.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this},e.prototype.clone=function(){return new e(this.x,this.y)},e.prototype.set=function(t,r){return this.x=t,this.y=r,this},e.prototype.equal=function(t){return t.x===this.x&&t.y===this.y},e.prototype.add=function(t){return this.x+=t.x,this.y+=t.y,this},e.prototype.scale=function(t){this.x*=t,this.y*=t},e.prototype.scaleAndAdd=function(t,r){this.x+=t.x*r,this.y+=t.y*r},e.prototype.sub=function(t){return this.x-=t.x,this.y-=t.y,this},e.prototype.dot=function(t){return this.x*t.x+this.y*t.y},e.prototype.len=function(){return Math.sqrt(this.x*this.x+this.y*this.y)},e.prototype.lenSquare=function(){return this.x*this.x+this.y*this.y},e.prototype.normalize=function(){var t=this.len();return this.x/=t,this.y/=t,this},e.prototype.distance=function(t){var r=this.x-t.x,n=this.y-t.y;return Math.sqrt(r*r+n*n)},e.prototype.distanceSquare=function(t){var r=this.x-t.x,n=this.y-t.y;return r*r+n*n},e.prototype.negate=function(){return this.x=-this.x,this.y=-this.y,this},e.prototype.transform=function(t){if(t){var r=this.x,n=this.y;return this.x=t[0]*r+t[2]*n+t[4],this.y=t[1]*r+t[3]*n+t[5],this}},e.prototype.toArray=function(t){return t[0]=this.x,t[1]=this.y,t},e.prototype.fromArray=function(t){this.x=t[0],this.y=t[1]},e.set=function(t,r,n){t.x=r,t.y=n},e.copy=function(t,r){t.x=r.x,t.y=r.y},e.len=function(t){return Math.sqrt(t.x*t.x+t.y*t.y)},e.lenSquare=function(t){return t.x*t.x+t.y*t.y},e.dot=function(t,r){return t.x*r.x+t.y*r.y},e.add=function(t,r,n){t.x=r.x+n.x,t.y=r.y+n.y},e.sub=function(t,r,n){t.x=r.x-n.x,t.y=r.y-n.y},e.scale=function(t,r,n){t.x=r.x*n,t.y=r.y*n},e.scaleAndAdd=function(t,r,n,i){t.x=r.x+n.x*i,t.y=r.y+n.y*i},e.lerp=function(t,r,n,i){var a=1-i;t.x=a*r.x+i*n.x,t.y=a*r.y+i*n.y},e})(),_n=Math.min,ti=Math.max,ju=Math.abs,Vv=["x","y"],X1=["width","height"],Xr=new _t,$r=new _t,Zr=new _t,qr=new _t,le=Vg(),Zi=le.minTv,tf=le.maxTv,na=[0,0],it=(function(){function e(t,r,n,i){Al(this,t,r,n,i)}return e.set=function(t,r,n,i,a){return i<0&&(r=r+i,i=-i),a<0&&(n=n+a,a=-a),t.x=r,t.y=n,t.width=i,t.height=a,t},e.prototype.union=function(t){var r=_n(t.x,this.x),n=_n(t.y,this.y);isFinite(this.x)&&isFinite(this.width)?this.width=ti(t.x+t.width,this.x+this.width)-r:this.width=t.width,isFinite(this.y)&&isFinite(this.height)?this.height=ti(t.y+t.height,this.y+this.height)-n:this.height=t.height,this.x=r,this.y=n},e.prototype.applyTransform=function(t){e.applyTransform(this,this,t)},e.prototype.calculateTransform=function(t){return $1(qe(),this,t)},e.prototype.intersect=function(t,r,n){return e.intersect(this,t,r,n)},e.intersect=function(t,r,n,i){n&&_t.set(n,0,0);var a=i&&i.outIntersectRect||null,o=i&&i.clamp;if(a&&(a.x=a.y=a.width=a.height=NaN),!t||!r)return!1;t instanceof e||(t=Al(Z1,t.x,t.y,t.width,t.height)),r instanceof e||(r=Al(q1,r.x,r.y,r.width,r.height));var s=!!n;le.reset(i,s);var l=le.touchThreshold,u=t.x+l,f=t.x+t.width-l,h=t.y+l,v=t.y+t.height-l,c=r.x+l,d=r.x+r.width-l,p=r.y+l,m=r.y+r.height-l;if(u>f||h>v||c>d||p>m)return!1;var g=!(f<c||d<u||v<p||m<h);return(s||a)&&(na[0]=1/0,na[1]=0,Uv(u,f,c,d,0,s,a,o),Uv(h,v,p,m,1,s,a,o),s&&_t.copy(n,g?le.useDir?le.dirMinTv:Zi:tf)),g},e.contain=function(t,r,n){return r>=t.x&&r<=t.x+t.width&&n>=t.y&&n<=t.y+t.height},e.prototype.contain=function(t,r){return e.contain(this,t,r)},e.prototype.clone=function(){return new e(this.x,this.y,this.width,this.height)},e.prototype.copy=function(t){Gv(this,t)},e.prototype.plain=function(){return{x:this.x,y:this.y,width:this.width,height:this.height}},e.prototype.isFinite=function(){return isFinite(this.x)&&isFinite(this.y)&&isFinite(this.width)&&isFinite(this.height)},e.prototype.isZero=function(){return this.width===0||this.height===0},e.create=function(t){return new e(t?t.x:0,t?t.y:0,t?t.width:0,t?t.height:0)},e.copy=function(t,r){return t.x=r.x,t.y=r.y,t.width=r.width,t.height=r.height,t},e.applyTransform=function(t,r,n){if(!n){t!==r&&Gv(t,r);return}if(n[1]<1e-5&&n[1]>-1e-5&&n[2]<1e-5&&n[2]>-1e-5){var i=n[0],a=n[3],o=n[4],s=n[5];t.x=r.x*i+o,t.y=r.y*a+s,t.width=r.width*i,t.height=r.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}Xr.x=Zr.x=r.x,Xr.y=qr.y=r.y,$r.x=qr.x=r.x+r.width,$r.y=Zr.y=r.y+r.height,Xr.transform(n),qr.transform(n),$r.transform(n),Zr.transform(n),t.x=_n(Xr.x,$r.x,Zr.x,qr.x),t.y=_n(Xr.y,$r.y,Zr.y,qr.y);var l=ti(Xr.x,$r.x,Zr.x,qr.x),u=ti(Xr.y,$r.y,Zr.y,qr.y);t.width=l-t.x,t.height=u-t.y},e.calculateTransform=function(t,r,n){var i=n.width/r.width,a=n.height/r.height;return t=ka(t||[]),Ju(t,t,wl(Ll,-r.x,-r.y)),Y1(t,t,wl(Ll,i,a)),Ju(t,t,wl(Ll,n.x,n.y)),t},e})();it.create;var Al=it.set,Gv=it.copy,$1=it.calculateTransform;it.applyTransform;it.contain;var Z1=new it(0,0,0,0),q1=new it(0,0,0,0),Ll=[];function Uv(e,t,r,n,i,a,o,s){var l=ju(t-r),u=ju(n-e),f=_n(l,u),h=Vv[i],v=Vv[1-i],c=X1[i];t<r||n<e?l<u?(a&&(tf[h]=-l),s&&(o[h]=t,o[c]=0)):(a&&(tf[h]=u),s&&(o[h]=e,o[c]=0)):(o&&(o[h]=ti(e,r),o[c]=_n(t,n)-o[h]),a&&(f<na[0]||le.useDir)&&(na[0]=_n(f,na[0]),(l<u||!le.bidirectional)&&(Zi[h]=l,Zi[v]=0,le.useDir&&le.calcDirMTV()),(l>=u||!le.bidirectional)&&(Zi[h]=-u,Zi[v]=0,le.useDir&&le.calcDirMTV())))}function Vg(){var e=0,t=new _t,r=new _t,n={minTv:new _t,maxTv:new _t,useDir:!1,dirMinTv:new _t,touchThreshold:0,bidirectional:!0,negativeSize:!1,reset:function(a,o){n.touchThreshold=0,a&&a.touchThreshold!=null&&(n.touchThreshold=ti(0,a.touchThreshold)),n.negativeSize=!1,o&&(n.minTv.set(1/0,1/0),n.maxTv.set(0,0),n.useDir=!1,a&&a.direction!=null&&(n.useDir=!0,n.dirMinTv.copy(n.minTv),r.copy(n.minTv),e=a.direction,n.bidirectional=a.bidirectional==null||!!a.bidirectional,n.bidirectional||t.set(Math.cos(e),Math.sin(e))))},calcDirMTV:function(){var a=n.minTv,o=n.dirMinTv,s=a.y*a.y+a.x*a.x,l=Math.sin(e),u=Math.cos(e),f=l*a.y+u*a.x;if(i(f)){i(a.x)&&i(a.y)&&o.set(0,0);return}if(r.x=s*u/f,r.y=s*l/f,i(r.x)&&i(r.y)){o.set(0,0);return}(n.bidirectional||t.dot(r)>0)&&r.len()<o.len()&&o.copy(r)}};function i(a){return ju(a)<1e-10}return n}var Gg="silent";function K1(e,t,r){return{type:e,event:r,target:t.target,topTarget:t.topTarget,cancelBubble:!1,offsetX:r.zrX,offsetY:r.zrY,gestureEvent:r.gestureEvent,pinchX:r.pinchX,pinchY:r.pinchY,pinchScale:r.pinchScale,wheelDelta:r.zrDelta,zrByTouch:r.zrByTouch,which:r.which,stop:Q1}}function Q1(){Hg(this.event)}var J1=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.handler=null,r}return t.prototype.dispose=function(){},t.prototype.setCursor=function(){},t})(or),Li=(function(){function e(t,r){this.x=t,this.y=r}return e})(),j1=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],Il=new it(0,0,0,0),Ug=(function(e){V(t,e);function t(r,n,i,a,o){var s=e.call(this)||this;return s._hovered=new Li(0,0),s.storage=r,s.painter=n,s.painterRoot=a,s._pointerSize=o,i=i||new J1,s.proxy=null,s.setHandlerProxy(i),s._draggingMgr=new I1(s),s}return t.prototype.setHandlerProxy=function(r){this.proxy&&this.proxy.dispose(),r&&(D(j1,function(n){r.on&&r.on(n,this[n],this)},this),r.handler=this),this.proxy=r},t.prototype.mousemove=function(r){var n=r.zrX,i=r.zrY,a=Wg(this,n,i),o=this._hovered,s=o.target;s&&!s.__zr&&(o=this.findHover(o.x,o.y),s=o.target);var l=this._hovered=a?new Li(n,i):this.findHover(n,i),u=l.target,f=this.proxy;f.setCursor&&f.setCursor(u?u.cursor:"default"),s&&u!==s&&this.dispatchToElement(o,"mouseout",r),this.dispatchToElement(l,"mousemove",r),u&&u!==s&&this.dispatchToElement(l,"mouseover",r)},t.prototype.mouseout=function(r){var n=r.zrEventControl;n!=="only_globalout"&&this.dispatchToElement(this._hovered,"mouseout",r),n!=="no_globalout"&&this.trigger("globalout",{type:"globalout",event:r})},t.prototype.resize=function(){this._hovered=new Li(0,0)},t.prototype.dispatch=function(r,n){var i=this[r];i&&i.call(this,n)},t.prototype.dispose=function(){this.proxy.dispose(),this.storage=null,this.proxy=null,this.painter=null},t.prototype.setCursorStyle=function(r){var n=this.proxy;n.setCursor&&n.setCursor(r)},t.prototype.dispatchToElement=function(r,n,i){r=r||{};var a=r.target;if(!(a&&a.silent)){for(var o="on"+n,s=K1(n,r,i);a&&(a[o]&&(s.cancelBubble=!!a[o].call(a,s)),a.trigger(n,s),a=a.__hostTarget?a.__hostTarget:a.parent,!s.cancelBubble););s.cancelBubble||(this.trigger(n,s),this.painter&&this.painter.eachOtherLayer&&this.painter.eachOtherLayer(function(l){typeof l[o]=="function"&&l[o].call(l,s),l.trigger&&l.trigger(n,s)}))}},t.prototype.findHover=function(r,n,i){var a=this.storage.getDisplayList(),o=new Li(r,n);if(Wv(a,o,r,n,i),this._pointerSize&&!o.target){for(var s=[],l=this._pointerSize,u=l/2,f=new it(r-u,n-u,l,l),h=a.length-1;h>=0;h--){var v=a[h];v!==i&&!v.ignore&&!v.ignoreCoarsePointer&&(!v.parent||!v.parent.ignoreCoarsePointer)&&(Il.copy(v.getBoundingRect()),v.transform&&Il.applyTransform(v.transform),Il.intersect(f)&&s.push(v))}if(s.length)for(var c=4,d=Math.PI/12,p=Math.PI*2,m=0;m<u;m+=c)for(var g=0;g<p;g+=d){var y=r+m*Math.cos(g),_=n+m*Math.sin(g);if(Wv(s,o,y,_,i),o.target)return o}}return o},t.prototype.processGesture=function(r,n){this._gestureMgr||(this._gestureMgr=new U1);var i=this._gestureMgr;n==="start"&&i.clear();var a=i.recognize(r,this.findHover(r.zrX,r.zrY,null).target,this.proxy.dom);if(n==="end"&&i.clear(),a){var o=a.type;r.gestureEvent=o;var s=new Li;s.target=a.target,this.dispatchToElement(s,o,a.event)}},t})(or);D(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(e){Ug.prototype[e]=function(t){var r=t.zrX,n=t.zrY,i=Wg(this,r,n),a,o;if((e!=="mouseup"||!i)&&(a=this.findHover(r,n),o=a.target),e==="mousedown")this._downEl=o,this._downPoint=[t.zrX,t.zrY],this._upEl=o;else if(e==="mouseup")this._upEl=o;else if(e==="click"){if(this._downEl!==this._upEl||!this._downPoint||A1(this._downPoint,[t.zrX,t.zrY])>4)return;this._downPoint=null}this.dispatchToElement(a,e,t)}});function tS(e,t,r){if(e[e.rectHover?"rectContain":"contain"](t,r)){for(var n=e,i=void 0,a=!1;n;){if(n.ignoreClip&&(a=!0),!a){var o=n.getClipPath();if(o&&!o.contain(t,r))return!1}n.silent&&(i=!0);var s=n.__hostTarget;n=s?n.ignoreHostSilent?null:s:n.parent}return i?Gg:!0}return!1}function Wv(e,t,r,n,i){for(var a=e.length-1;a>=0;a--){var o=e[a],s=void 0;if(o!==i&&!o.ignore&&(s=tS(o,r,n))&&(!t.topTarget&&(t.topTarget=o),s!==Gg)){t.target=o;break}}}function Wg(e,t,r){var n=e.painter;return t<0||t>n.getWidth()||r<0||r>n.getHeight()}var Yg=32,Ii=7;function eS(e){for(var t=0;e>=Yg;)t|=e&1,e>>=1;return e+t}function Yv(e,t,r,n){var i=t+1;if(i===r)return 1;if(n(e[i++],e[t])<0){for(;i<r&&n(e[i],e[i-1])<0;)i++;rS(e,t,i)}else for(;i<r&&n(e[i],e[i-1])>=0;)i++;return i-t}function rS(e,t,r){for(r--;t<r;){var n=e[t];e[t++]=e[r],e[r--]=n}}function Xv(e,t,r,n,i){for(n===t&&n++;n<r;n++){for(var a=e[n],o=t,s=n,l;o<s;)l=o+s>>>1,i(a,e[l])<0?s=l:o=l+1;var u=n-o;switch(u){case 3:e[o+3]=e[o+2];case 2:e[o+2]=e[o+1];case 1:e[o+1]=e[o];break;default:for(;u>0;)e[o+u]=e[o+u-1],u--}e[o]=a}}function Pl(e,t,r,n,i,a){var o=0,s=0,l=1;if(a(e,t[r+i])>0){for(s=n-i;l<s&&a(e,t[r+i+l])>0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=i,l+=i}else{for(s=i+1;l<s&&a(e,t[r+i-l])<=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=i-l,l=i-u}for(o++;o<l;){var f=o+(l-o>>>1);a(e,t[r+f])>0?o=f+1:l=f}return l}function El(e,t,r,n,i,a){var o=0,s=0,l=1;if(a(e,t[r+i])<0){for(s=i+1;l<s&&a(e,t[r+i-l])<0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s);var u=o;o=i-l,l=i-u}else{for(s=n-i;l<s&&a(e,t[r+i+l])>=0;)o=l,l=(l<<1)+1,l<=0&&(l=s);l>s&&(l=s),o+=i,l+=i}for(o++;o<l;){var f=o+(l-o>>>1);a(e,t[r+f])<0?l=f:o=f+1}return l}function nS(e,t){var r=Ii,n,i,a=0,o=[];n=[],i=[];function s(c,d){n[a]=c,i[a]=d,a+=1}function l(){for(;a>1;){var c=a-2;if(c>=1&&i[c-1]<=i[c]+i[c+1]||c>=2&&i[c-2]<=i[c]+i[c-1])i[c-1]<i[c+1]&&c--;else if(i[c]>i[c+1])break;f(c)}}function u(){for(;a>1;){var c=a-2;c>0&&i[c-1]<i[c+1]&&c--,f(c)}}function f(c){var d=n[c],p=i[c],m=n[c+1],g=i[c+1];i[c]=p+g,c===a-3&&(n[c+1]=n[c+2],i[c+1]=i[c+2]),a--;var y=El(e[m],e,d,p,0,t);d+=y,p-=y,p!==0&&(g=Pl(e[d+p-1],e,m,g,g-1,t),g!==0&&(p<=g?h(d,p,m,g):v(d,p,m,g)))}function h(c,d,p,m){var g=0;for(g=0;g<d;g++)o[g]=e[c+g];var y=0,_=p,S=c;if(e[S++]=e[_++],--m===0){for(g=0;g<d;g++)e[S+g]=o[y+g];return}if(d===1){for(g=0;g<m;g++)e[S+g]=e[_+g];e[S+m]=o[y];return}for(var b=r,T,w,M;;){T=0,w=0,M=!1;do if(t(e[_],o[y])<0){if(e[S++]=e[_++],w++,T=0,--m===0){M=!0;break}}else if(e[S++]=o[y++],T++,w=0,--d===1){M=!0;break}while((T|w)<b);if(M)break;do{if(T=El(e[_],o,y,d,0,t),T!==0){for(g=0;g<T;g++)e[S+g]=o[y+g];if(S+=T,y+=T,d-=T,d<=1){M=!0;break}}if(e[S++]=e[_++],--m===0){M=!0;break}if(w=Pl(o[y],e,_,m,0,t),w!==0){for(g=0;g<w;g++)e[S+g]=e[_+g];if(S+=w,_+=w,m-=w,m===0){M=!0;break}}if(e[S++]=o[y++],--d===1){M=!0;break}b--}while(T>=Ii||w>=Ii);if(M)break;b<0&&(b=0),b+=2}if(r=b,r<1&&(r=1),d===1){for(g=0;g<m;g++)e[S+g]=e[_+g];e[S+m]=o[y]}else{if(d===0)throw new Error;for(g=0;g<d;g++)e[S+g]=o[y+g]}}function v(c,d,p,m){var g=0;for(g=0;g<m;g++)o[g]=e[p+g];var y=c+d-1,_=m-1,S=p+m-1,b=0,T=0;if(e[S--]=e[y--],--d===0){for(b=S-(m-1),g=0;g<m;g++)e[b+g]=o[g];return}if(m===1){for(S-=d,y-=d,T=S+1,b=y+1,g=d-1;g>=0;g--)e[T+g]=e[b+g];e[S]=o[_];return}for(var w=r;;){var M=0,C=0,x=!1;do if(t(o[_],e[y])<0){if(e[S--]=e[y--],M++,C=0,--d===0){x=!0;break}}else if(e[S--]=o[_--],C++,M=0,--m===1){x=!0;break}while((M|C)<w);if(x)break;do{if(M=d-El(o[_],e,c,d,d-1,t),M!==0){for(S-=M,y-=M,d-=M,T=S+1,b=y+1,g=M-1;g>=0;g--)e[T+g]=e[b+g];if(d===0){x=!0;break}}if(e[S--]=o[_--],--m===1){x=!0;break}if(C=m-Pl(e[y],o,0,m,m-1,t),C!==0){for(S-=C,_-=C,m-=C,T=S+1,b=_+1,g=0;g<C;g++)e[T+g]=o[b+g];if(m<=1){x=!0;break}}if(e[S--]=e[y--],--d===0){x=!0;break}w--}while(M>=Ii||C>=Ii);if(x)break;w<0&&(w=0),w+=2}if(r=w,r<1&&(r=1),m===1){for(S-=d,y-=d,T=S+1,b=y+1,g=d-1;g>=0;g--)e[T+g]=e[b+g];e[S]=o[_]}else{if(m===0)throw new Error;for(b=S-(m-1),g=0;g<m;g++)e[b+g]=o[g]}}return{mergeRuns:l,forceMergeRuns:u,pushRun:s}}function Uo(e,t,r,n){r||(r=0),n||(n=e.length);var i=n-r;if(!(i<2)){var a=0;if(i<Yg){a=Yv(e,r,n,t),Xv(e,r,n,r+a,t);return}var o=nS(e,t),s=eS(i);do{if(a=Yv(e,r,n,t),a<s){var l=i;l>s&&(l=s),Xv(e,r,r+l,r+a,t),a=l}o.pushRun(r,a),o.mergeRuns(),i-=a,r+=a}while(i!==0);o.forceMergeRuns()}}var ne=1,qi=2,Kn=4,$v=!1;function Rl(){$v||($v=!0,console.warn("z / z2 / zlevel of displayable is invalid, which may cause unexpected errors"))}function Zv(e,t){return e.zlevel===t.zlevel?e.z===t.z?e.z2-t.z2:e.z-t.z:e.zlevel-t.zlevel}var iS=(function(){function e(){this._roots=[],this._displayList=[],this._displayListLen=0,this.displayableSortFunc=Zv}return e.prototype.traverse=function(t,r){for(var n=0;n<this._roots.length;n++)this._roots[n].traverse(t,r)},e.prototype.getDisplayList=function(t,r){r=r||!1;var n=this._displayList;return(t||!n.length)&&this.updateDisplayList(r),n},e.prototype.updateDisplayList=function(t){this._displayListLen=0;for(var r=this._roots,n=this._displayList,i=0,a=r.length;i<a;i++)this._updateAndAddDisplayable(r[i],null,t);n.length=this._displayListLen,Uo(n,Zv)},e.prototype._updateAndAddDisplayable=function(t,r,n){if(!(t.ignore&&!n)){t.beforeUpdate(),t.update(),t.afterUpdate();var i=t.getClipPath(),a=r&&r.length,o=0,s=t.__clipPaths;if(!t.ignoreClip&&(a||i)){if(s||(s=t.__clipPaths=[]),a)for(var l=0;l<r.length;l++)s[o++]=r[l];for(var u=i,f=t;u;)u.parent=f,u.updateTransform(),s[o++]=u,f=u,u=u.getClipPath()}if(s&&(s.length=o),t.childrenRef){for(var h=t.childrenRef(),v=0;v<h.length;v++){var c=h[v];t.__dirty&&(c.__dirty|=ne),this._updateAndAddDisplayable(c,s,n)}t.__dirty=0}else{var d=t;isNaN(d.z)&&(Rl(),d.z=0),isNaN(d.z2)&&(Rl(),d.z2=0),isNaN(d.zlevel)&&(Rl(),d.zlevel=0),this._displayList[this._displayListLen++]=d}var p=t.getDecalElement&&t.getDecalElement();p&&this._updateAndAddDisplayable(p,s,n);var m=t.getTextGuideLine();m&&this._updateAndAddDisplayable(m,s,n);var g=t.getTextContent();g&&this._updateAndAddDisplayable(g,s,n)}},e.prototype.addRoot=function(t){t.__zr&&t.__zr.storage===this||this._roots.push(t)},e.prototype.delRoot=function(t){if(t instanceof Array){for(var r=0,n=t.length;r<n;r++)this.delRoot(t[r]);return}var i=vt(this._roots,t);i>=0&&this._roots.splice(i,1)},e.prototype.delAllRoots=function(){this._roots=[],this._displayList=[],this._displayListLen=0},e.prototype.getRoots=function(){return this._roots},e.prototype.dispose=function(){this._displayList=null,this._roots=null},e})(),hs;hs=st.hasGlobalWindow&&(window.requestAnimationFrame&&window.requestAnimationFrame.bind(window)||window.msRequestAnimationFrame&&window.msRequestAnimationFrame.bind(window)||window.mozRequestAnimationFrame||window.webkitRequestAnimationFrame)||function(e){return setTimeout(e,16)};var ia={linear:function(e){return e},quadraticIn:function(e){return e*e},quadraticOut:function(e){return e*(2-e)},quadraticInOut:function(e){return(e*=2)<1?.5*e*e:-.5*(--e*(e-2)-1)},cubicIn:function(e){return e*e*e},cubicOut:function(e){return--e*e*e+1},cubicInOut:function(e){return(e*=2)<1?.5*e*e*e:.5*((e-=2)*e*e+2)},quarticIn:function(e){return e*e*e*e},quarticOut:function(e){return 1- --e*e*e*e},quarticInOut:function(e){return(e*=2)<1?.5*e*e*e*e:-.5*((e-=2)*e*e*e-2)},quinticIn:function(e){return e*e*e*e*e},quinticOut:function(e){return--e*e*e*e*e+1},quinticInOut:function(e){return(e*=2)<1?.5*e*e*e*e*e:.5*((e-=2)*e*e*e*e+2)},sinusoidalIn:function(e){return 1-Math.cos(e*Math.PI/2)},sinusoidalOut:function(e){return Math.sin(e*Math.PI/2)},sinusoidalInOut:function(e){return .5*(1-Math.cos(Math.PI*e))},exponentialIn:function(e){return e===0?0:Math.pow(1024,e-1)},exponentialOut:function(e){return e===1?1:1-Math.pow(2,-10*e)},exponentialInOut:function(e){return e===0?0:e===1?1:(e*=2)<1?.5*Math.pow(1024,e-1):.5*(-Math.pow(2,-10*(e-1))+2)},circularIn:function(e){return 1-Math.sqrt(1-e*e)},circularOut:function(e){return Math.sqrt(1- --e*e)},circularInOut:function(e){return(e*=2)<1?-.5*(Math.sqrt(1-e*e)-1):.5*(Math.sqrt(1-(e-=2)*e)+1)},elasticIn:function(e){var t,r=.1,n=.4;return e===0?0:e===1?1:(!r||r<1?(r=1,t=n/4):t=n*Math.asin(1/r)/(2*Math.PI),-(r*Math.pow(2,10*(e-=1))*Math.sin((e-t)*(2*Math.PI)/n)))},elasticOut:function(e){var t,r=.1,n=.4;return e===0?0:e===1?1:(!r||r<1?(r=1,t=n/4):t=n*Math.asin(1/r)/(2*Math.PI),r*Math.pow(2,-10*e)*Math.sin((e-t)*(2*Math.PI)/n)+1)},elasticInOut:function(e){var t,r=.1,n=.4;return e===0?0:e===1?1:(!r||r<1?(r=1,t=n/4):t=n*Math.asin(1/r)/(2*Math.PI),(e*=2)<1?-.5*(r*Math.pow(2,10*(e-=1))*Math.sin((e-t)*(2*Math.PI)/n)):r*Math.pow(2,-10*(e-=1))*Math.sin((e-t)*(2*Math.PI)/n)*.5+1)},backIn:function(e){var t=1.70158;return e*e*((t+1)*e-t)},backOut:function(e){var t=1.70158;return--e*e*((t+1)*e+t)+1},backInOut:function(e){var t=2.5949095;return(e*=2)<1?.5*(e*e*((t+1)*e-t)):.5*((e-=2)*e*((t+1)*e+t)+2)},bounceIn:function(e){return 1-ia.bounceOut(1-e)},bounceOut:function(e){return e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375},bounceInOut:function(e){return e<.5?ia.bounceIn(e*2)*.5:ia.bounceOut(e*2-1)*.5+.5}},ja=Math.pow,Rr=Math.sqrt,vs=1e-8,Xg=1e-4,qv=Rr(3),to=1/3,Xe=xi(),be=xi(),si=xi();function Ir(e){return e>-vs&&e<vs}function $g(e){return e>vs||e<-vs}function Ht(e,t,r,n,i){var a=1-i;return a*a*(a*e+3*i*t)+i*i*(i*n+3*a*r)}function Kv(e,t,r,n,i){var a=1-i;return 3*(((t-e)*a+2*(r-t)*i)*a+(n-r)*i*i)}function cs(e,t,r,n,i,a){var o=n+3*(t-r)-e,s=3*(r-t*2+e),l=3*(t-e),u=e-i,f=s*s-3*o*l,h=s*l-9*o*u,v=l*l-3*s*u,c=0;if(Ir(f)&&Ir(h))if(Ir(s))a[0]=0;else{var d=-l/s;d>=0&&d<=1&&(a[c++]=d)}else{var p=h*h-4*f*v;if(Ir(p)){var m=h/f,d=-s/o+m,g=-m/2;d>=0&&d<=1&&(a[c++]=d),g>=0&&g<=1&&(a[c++]=g)}else if(p>0){var y=Rr(p),_=f*s+1.5*o*(-h+y),S=f*s+1.5*o*(-h-y);_<0?_=-ja(-_,to):_=ja(_,to),S<0?S=-ja(-S,to):S=ja(S,to);var d=(-s-(_+S))/(3*o);d>=0&&d<=1&&(a[c++]=d)}else{var b=(2*f*s-3*o*h)/(2*Rr(f*f*f)),T=Math.acos(b)/3,w=Rr(f),M=Math.cos(T),d=(-s-2*w*M)/(3*o),g=(-s+w*(M+qv*Math.sin(T)))/(3*o),C=(-s+w*(M-qv*Math.sin(T)))/(3*o);d>=0&&d<=1&&(a[c++]=d),g>=0&&g<=1&&(a[c++]=g),C>=0&&C<=1&&(a[c++]=C)}}return c}function Zg(e,t,r,n,i){var a=6*r-12*t+6*e,o=9*t+3*n-3*e-9*r,s=3*t-3*e,l=0;if(Ir(o)){if($g(a)){var u=-s/a;u>=0&&u<=1&&(i[l++]=u)}}else{var f=a*a-4*o*s;if(Ir(f))i[0]=-a/(2*o);else if(f>0){var h=Rr(f),u=(-a+h)/(2*o),v=(-a-h)/(2*o);u>=0&&u<=1&&(i[l++]=u),v>=0&&v<=1&&(i[l++]=v)}}return l}function ds(e,t,r,n,i,a){var o=(t-e)*i+e,s=(r-t)*i+t,l=(n-r)*i+r,u=(s-o)*i+o,f=(l-s)*i+s,h=(f-u)*i+u;a[0]=e,a[1]=o,a[2]=u,a[3]=h,a[4]=h,a[5]=f,a[6]=l,a[7]=n}function aS(e,t,r,n,i,a,o,s,l,u,f){var h,v=.005,c=1/0,d,p,m,g;Xe[0]=l,Xe[1]=u;for(var y=0;y<1;y+=.05)be[0]=Ht(e,r,i,o,y),be[1]=Ht(t,n,a,s,y),m=oi(Xe,be),m<c&&(h=y,c=m);c=1/0;for(var _=0;_<32&&!(v<Xg);_++)d=h-v,p=h+v,be[0]=Ht(e,r,i,o,d),be[1]=Ht(t,n,a,s,d),m=oi(be,Xe),d>=0&&m<c?(h=d,c=m):(si[0]=Ht(e,r,i,o,p),si[1]=Ht(t,n,a,s,p),g=oi(si,Xe),p<=1&&g<c?(h=p,c=g):v*=.5);return Rr(c)}function oS(e,t,r,n,i,a,o,s,l){for(var u=e,f=t,h=0,v=1/l,c=1;c<=l;c++){var d=c*v,p=Ht(e,r,i,o,d),m=Ht(t,n,a,s,d),g=p-u,y=m-f;h+=Math.sqrt(g*g+y*y),u=p,f=m}return h}function ee(e,t,r,n){var i=1-n;return i*(i*e+2*n*t)+n*n*r}function Qv(e,t,r,n){return 2*((1-n)*(t-e)+n*(r-t))}function sS(e,t,r,n,i){var a=e-2*t+r,o=2*(t-e),s=e-n,l=0;if(Ir(a)){if($g(o)){var u=-s/o;u>=0&&u<=1&&(i[l++]=u)}}else{var f=o*o-4*a*s;if(Ir(f)){var u=-o/(2*a);u>=0&&u<=1&&(i[l++]=u)}else if(f>0){var h=Rr(f),u=(-o+h)/(2*a),v=(-o-h)/(2*a);u>=0&&u<=1&&(i[l++]=u),v>=0&&v<=1&&(i[l++]=v)}}return l}function qg(e,t,r){var n=e+r-2*t;return n===0?.5:(e-t)/n}function ps(e,t,r,n,i){var a=(t-e)*n+e,o=(r-t)*n+t,s=(o-a)*n+a;i[0]=e,i[1]=a,i[2]=s,i[3]=s,i[4]=o,i[5]=r}function lS(e,t,r,n,i,a,o,s,l){var u,f=.005,h=1/0;Xe[0]=o,Xe[1]=s;for(var v=0;v<1;v+=.05){be[0]=ee(e,r,i,v),be[1]=ee(t,n,a,v);var c=oi(Xe,be);c<h&&(u=v,h=c)}h=1/0;for(var d=0;d<32&&!(f<Xg);d++){var p=u-f,m=u+f;be[0]=ee(e,r,i,p),be[1]=ee(t,n,a,p);var c=oi(be,Xe);if(p>=0&&c<h)u=p,h=c;else{si[0]=ee(e,r,i,m),si[1]=ee(t,n,a,m);var g=oi(si,Xe);m<=1&&g<h?(u=m,h=g):f*=.5}}return Rr(h)}function uS(e,t,r,n,i,a,o){for(var s=e,l=t,u=0,f=1/o,h=1;h<=o;h++){var v=h*f,c=ee(e,r,i,v),d=ee(t,n,a,v),p=c-s,m=d-l;u+=Math.sqrt(p*p+m*m),s=c,l=d}return u}var fS=/cubic-bezier\(([0-9,\.e ]+)\)/;function Kg(e){var t=e&&fS.exec(e);if(t){var r=t[1].split(","),n=+$e(r[0]),i=+$e(r[1]),a=+$e(r[2]),o=+$e(r[3]);if(isNaN(n+i+a+o))return;var s=[];return function(l){return l<=0?0:l>=1?1:cs(0,n,a,1,l,s)&&Ht(0,i,o,1,s[0])}}}var hS=(function(){function e(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||$t,this.ondestroy=t.ondestroy||$t,this.onrestart=t.onrestart||$t,t.easing&&this.setEasing(t.easing)}return e.prototype.step=function(t,r){if(this._inited||(this._startTime=t+this._delay,this._inited=!0),this._paused){this._pausedTime+=r;return}var n=this._life,i=t-this._startTime-this._pausedTime,a=i/n;a<0&&(a=0),a=Math.min(a,1);var o=this.easingFunc,s=o?o(a):a;if(this.onframe(s),a===1)if(this.loop){var l=i%n;this._startTime=t-l,this._pausedTime=0,this.onrestart()}else return!0;return!1},e.prototype.pause=function(){this._paused=!0},e.prototype.resume=function(){this._paused=!1},e.prototype.setEasing=function(t){this.easing=t,this.easingFunc=ot(t)?t:ia[t]||Kg(t)},e})(),Qg=(function(){function e(t){this.value=t}return e})(),vS=(function(){function e(){this._len=0}return e.prototype.insert=function(t){var r=new Qg(t);return this.insertEntry(r),r},e.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++},e.prototype.remove=function(t){var r=t.prev,n=t.next;r?r.next=n:this.head=n,n?n.prev=r:this.tail=r,t.next=t.prev=null,this._len--},e.prototype.len=function(){return this._len},e.prototype.clear=function(){this.head=this.tail=null,this._len=0},e})(),vi=(function(){function e(t){this._list=new vS,this._maxSize=10,this._map={},this._maxSize=t}return e.prototype.put=function(t,r){var n=this._list,i=this._map,a=null;if(i[t]==null){var o=n.len(),s=this._lastRemovedEntry;if(o>=this._maxSize&&o>0){var l=n.head;n.remove(l),delete i[l.key],a=l.value,this._lastRemovedEntry=l}s?s.value=r:s=new Qg(r),s.key=t,n.insertEntry(s),i[t]=s}return a},e.prototype.get=function(t){var r=this._map[t],n=this._list;if(r!=null)return r!==n.tail&&(n.remove(r),n.insertEntry(r)),r.value},e.prototype.clear=function(){this._list.clear(),this._map={}},e.prototype.len=function(){return this._list.len()},e})(),Jv={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 kr(e){return e=Math.round(e),e<0?0:e>255?255:e}function ef(e){return e<0?0:e>1?1:e}function kl(e){var t=e;return t.length&&t.charAt(t.length-1)==="%"?kr(parseFloat(t)/100*255):kr(parseInt(t,10))}function wn(e){var t=e;return t.length&&t.charAt(t.length-1)==="%"?ef(parseFloat(t)/100):ef(parseFloat(t))}function Ol(e,t,r){return r<0?r+=1:r>1&&(r-=1),r*6<1?e+(t-e)*r*6:r*2<1?t:r*3<2?e+(t-e)*(2/3-r)*6:e}function eo(e,t,r){return e+(t-e)*r}function ge(e,t,r,n,i){return e[0]=t,e[1]=r,e[2]=n,e[3]=i,e}function rf(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e}var Jg=new vi(20),ro=null;function On(e,t){ro&&rf(ro,t),ro=Jg.put(e,ro||t.slice())}function Ke(e,t){if(e){t=t||[];var r=Jg.get(e);if(r)return rf(t,r);e=e+"";var n=e.replace(/ /g,"").toLowerCase();if(n in Jv)return rf(t,Jv[n]),On(e,t),t;var i=n.length;if(n.charAt(0)==="#"){if(i===4||i===5){var a=parseInt(n.slice(1,4),16);if(!(a>=0&&a<=4095)){ge(t,0,0,0,1);return}return ge(t,(a&3840)>>4|(a&3840)>>8,a&240|(a&240)>>4,a&15|(a&15)<<4,i===5?parseInt(n.slice(4),16)/15:1),On(e,t),t}else if(i===7||i===9){var a=parseInt(n.slice(1,7),16);if(!(a>=0&&a<=16777215)){ge(t,0,0,0,1);return}return ge(t,(a&16711680)>>16,(a&65280)>>8,a&255,i===9?parseInt(n.slice(7),16)/255:1),On(e,t),t}return}var o=n.indexOf("("),s=n.indexOf(")");if(o!==-1&&s+1===i){var l=n.substr(0,o),u=n.substr(o+1,s-(o+1)).split(","),f=1;switch(l){case"rgba":if(u.length!==4)return u.length===3?ge(t,+u[0],+u[1],+u[2],1):ge(t,0,0,0,1);f=wn(u.pop());case"rgb":if(u.length>=3)return ge(t,kl(u[0]),kl(u[1]),kl(u[2]),u.length===3?f:wn(u[3])),On(e,t),t;ge(t,0,0,0,1);return;case"hsla":if(u.length!==4){ge(t,0,0,0,1);return}return u[3]=wn(u[3]),nf(u,t),On(e,t),t;case"hsl":if(u.length!==3){ge(t,0,0,0,1);return}return nf(u,t),On(e,t),t;default:return}}ge(t,0,0,0,1)}}function nf(e,t){var r=(parseFloat(e[0])%360+360)%360/360,n=wn(e[1]),i=wn(e[2]),a=i<=.5?i*(n+1):i+n-i*n,o=i*2-a;return t=t||[],ge(t,kr(Ol(o,a,r+1/3)*255),kr(Ol(o,a,r)*255),kr(Ol(o,a,r-1/3)*255),1),e.length===4&&(t[3]=e[3]),t}function cS(e){if(e){var t=e[0]/255,r=e[1]/255,n=e[2]/255,i=Math.min(t,r,n),a=Math.max(t,r,n),o=a-i,s=(a+i)/2,l,u;if(o===0)l=0,u=0;else{s<.5?u=o/(a+i):u=o/(2-a-i);var f=((a-t)/6+o/2)/o,h=((a-r)/6+o/2)/o,v=((a-n)/6+o/2)/o;t===a?l=v-h:r===a?l=1/3+f-v:n===a&&(l=2/3+h-f),l<0&&(l+=1),l>1&&(l-=1)}var c=[l*360,u,s];return e[3]!=null&&c.push(e[3]),c}}function jv(e,t){var r=Ke(e);if(r){for(var n=0;n<3;n++)r[n]=r[n]*(1-t)|0,r[n]>255?r[n]=255:r[n]<0&&(r[n]=0);return Ba(r,r.length===4?"rgba":"rgb")}}function dS(e,t,r){if(!(!(t&&t.length)||!(e>=0&&e<=1))){var n=e*(t.length-1),i=Math.floor(n),a=Math.ceil(n),o=Ke(t[i]),s=Ke(t[a]),l=n-i,u=Ba([kr(eo(o[0],s[0],l)),kr(eo(o[1],s[1],l)),kr(eo(o[2],s[2],l)),ef(eo(o[3],s[3],l))],"rgba");return r?{color:u,leftIndex:i,rightIndex:a,value:n}:u}}function af(e,t,r,n){var i=Ke(e);if(e)return i=cS(i),r!=null&&(i[1]=wn(ot(r)?r(i[1]):r)),n!=null&&(i[2]=wn(ot(n)?n(i[2]):n)),Ba(nf(i),"rgba")}function Ba(e,t){if(!(!e||!e.length)){var r=e[0]+","+e[1]+","+e[2];return(t==="rgba"||t==="hsva"||t==="hsla")&&(r+=","+e[3]),t+"("+r+")"}}function gs(e,t){var r=Ke(e);return r?(.299*r[0]+.587*r[1]+.114*r[2])*r[3]/255+(1-r[3])*t:0}var tc=new vi(100);function ec(e){if(W(e)){var t=tc.get(e);return t||(t=jv(e,-.1),tc.put(e,t)),t}else if($s(e)){var r=N({},e);return r.colorStops=rt(e.colorStops,function(n){return{offset:n.offset,color:jv(n.color,-.1)}}),r}return e}function pS(e){return e.type==="linear"}function gS(e){return e.type==="radial"}(function(){return typeof Buffer<"u"&&typeof Buffer.from=="function"?function(e){return Buffer.from(e).toString("base64")}:typeof btoa=="function"&&typeof unescape=="function"&&typeof encodeURIComponent=="function"?function(e){return btoa(unescape(encodeURIComponent(e)))}:function(e){return null}})();var of=Array.prototype.slice;function cr(e,t,r){return(t-e)*r+e}function Bl(e,t,r,n){for(var i=t.length,a=0;a<i;a++)e[a]=cr(t[a],r[a],n);return e}function mS(e,t,r,n){for(var i=t.length,a=i&&t[0].length,o=0;o<i;o++){e[o]||(e[o]=[]);for(var s=0;s<a;s++)e[o][s]=cr(t[o][s],r[o][s],n)}return e}function no(e,t,r,n){for(var i=t.length,a=0;a<i;a++)e[a]=t[a]+r[a]*n;return e}function rc(e,t,r,n){for(var i=t.length,a=i&&t[0].length,o=0;o<i;o++){e[o]||(e[o]=[]);for(var s=0;s<a;s++)e[o][s]=t[o][s]+r[o][s]*n}return e}function yS(e,t){for(var r=e.length,n=t.length,i=r>n?t:e,a=Math.min(r,n),o=i[a-1]||{color:[0,0,0,0],offset:0},s=a;s<Math.max(r,n);s++)i.push({offset:o.offset,color:o.color.slice()})}function _S(e,t,r){var n=e,i=t;if(!(!n.push||!i.push)){var a=n.length,o=i.length;if(a!==o){var s=a>o;if(s)n.length=o;else for(var l=a;l<o;l++)n.push(r===1?i[l]:of.call(i[l]))}for(var u=n[0]&&n[0].length,l=0;l<n.length;l++)if(r===1)isNaN(n[l])&&(n[l]=i[l]);else for(var f=0;f<u;f++)isNaN(n[l][f])&&(n[l][f]=i[l][f])}}function Wo(e){if(ie(e)){var t=e.length;if(ie(e[0])){for(var r=[],n=0;n<t;n++)r.push(of.call(e[n]));return r}return of.call(e)}return e}function Yo(e){return e[0]=Math.floor(e[0])||0,e[1]=Math.floor(e[1])||0,e[2]=Math.floor(e[2])||0,e[3]=e[3]==null?1:e[3],"rgba("+e.join(",")+")"}function SS(e){return ie(e&&e[0])?2:1}var io=0,Xo=1,jg=2,Ki=3,sf=4,lf=5,nc=6;function ic(e){return e===sf||e===lf}function ao(e){return e===Xo||e===jg}var Pi=[0,0,0,0],bS=(function(){function e(t){this.keyframes=[],this.discrete=!1,this._invalid=!1,this._needsSort=!1,this._lastFr=0,this._lastFrP=0,this.propName=t}return e.prototype.isFinished=function(){return this._finished},e.prototype.setFinished=function(){this._finished=!0,this._additiveTrack&&this._additiveTrack.setFinished()},e.prototype.needsAnimate=function(){return this.keyframes.length>=1},e.prototype.getAdditiveTrack=function(){return this._additiveTrack},e.prototype.addKeyframe=function(t,r,n){this._needsSort=!0;var i=this.keyframes,a=i.length,o=!1,s=nc,l=r;if(ie(r)){var u=SS(r);s=u,(u===1&&!Ct(r[0])||u===2&&!Ct(r[0][0]))&&(o=!0)}else if(Ct(r)&&!ga(r))s=io;else if(W(r))if(!isNaN(+r))s=io;else{var f=Ke(r);f&&(l=f,s=Ki)}else if($s(r)){var h=N({},l);h.colorStops=rt(r.colorStops,function(c){return{offset:c.offset,color:Ke(c.color)}}),pS(r)?s=sf:gS(r)&&(s=lf),l=h}a===0?this.valType=s:(s!==this.valType||s===nc)&&(o=!0),this.discrete=this.discrete||o;var v={time:t,value:l,rawValue:r,percent:0};return n&&(v.easing=n,v.easingFunc=ot(n)?n:ia[n]||Kg(n)),i.push(v),v},e.prototype.prepare=function(t,r){var n=this.keyframes;this._needsSort&&n.sort(function(p,m){return p.time-m.time});for(var i=this.valType,a=n.length,o=n[a-1],s=this.discrete,l=ao(i),u=ic(i),f=0;f<a;f++){var h=n[f],v=h.value,c=o.value;h.percent=h.time/t,s||(l&&f!==a-1?_S(v,c,i):u&&yS(v.colorStops,c.colorStops))}if(!s&&i!==lf&&r&&this.needsAnimate()&&r.needsAnimate()&&i===r.valType&&!r._finished){this._additiveTrack=r;for(var d=n[0].value,f=0;f<a;f++)i===io?n[f].additiveValue=n[f].value-d:i===Ki?n[f].additiveValue=no([],n[f].value,d,-1):ao(i)&&(n[f].additiveValue=i===Xo?no([],n[f].value,d,-1):rc([],n[f].value,d,-1))}},e.prototype.step=function(t,r){if(!this._finished){this._additiveTrack&&this._additiveTrack._finished&&(this._additiveTrack=null);var n=this._additiveTrack!=null,i=n?"additiveValue":"value",a=this.valType,o=this.keyframes,s=o.length,l=this.propName,u=a===Ki,f,h=this._lastFr,v=Math.min,c,d;if(s===1)c=d=o[0];else{if(r<0)f=0;else if(r<this._lastFrP){var p=v(h+1,s-1);for(f=p;f>=0&&!(o[f].percent<=r);f--);f=v(f,s-2)}else{for(f=h;f<s&&!(o[f].percent>r);f++);f=v(f-1,s-2)}d=o[f+1],c=o[f]}if(c&&d){this._lastFr=f,this._lastFrP=r;var m=d.percent-c.percent,g=m===0?1:v((r-c.percent)/m,1);d.easingFunc&&(g=d.easingFunc(g));var y=n?this._additiveValue:u?Pi:t[l];if((ao(a)||u)&&!y&&(y=this._additiveValue=[]),this.discrete)t[l]=g<1?c.rawValue:d.rawValue;else if(ao(a))a===Xo?Bl(y,c[i],d[i],g):mS(y,c[i],d[i],g);else if(ic(a)){var _=c[i],S=d[i],b=a===sf;t[l]={type:b?"linear":"radial",x:cr(_.x,S.x,g),y:cr(_.y,S.y,g),colorStops:rt(_.colorStops,function(w,M){var C=S.colorStops[M];return{offset:cr(w.offset,C.offset,g),color:Yo(Bl([],w.color,C.color,g))}}),global:S.global},b?(t[l].x2=cr(_.x2,S.x2,g),t[l].y2=cr(_.y2,S.y2,g)):t[l].r=cr(_.r,S.r,g)}else if(u)Bl(y,c[i],d[i],g),n||(t[l]=Yo(y));else{var T=cr(c[i],d[i],g);n?this._additiveValue=T:t[l]=T}n&&this._addToTarget(t)}}},e.prototype._addToTarget=function(t){var r=this.valType,n=this.propName,i=this._additiveValue;r===io?t[n]=t[n]+i:r===Ki?(Ke(t[n],Pi),no(Pi,Pi,i,1),t[n]=Yo(Pi)):r===Xo?no(t[n],t[n],i,1):r===jg&&rc(t[n],t[n],i,1)},e})(),yh=(function(){function e(t,r,n,i){if(this._tracks={},this._trackKeys=[],this._maxTime=0,this._started=0,this._clip=null,this._target=t,this._loop=r,r&&i){vh("Can' use additive animation on looped animation.");return}this._additiveAnimators=i,this._allowDiscrete=n}return e.prototype.getMaxTime=function(){return this._maxTime},e.prototype.getDelay=function(){return this._delay},e.prototype.getLoop=function(){return this._loop},e.prototype.getTarget=function(){return this._target},e.prototype.changeTarget=function(t){this._target=t},e.prototype.when=function(t,r,n){return this.whenWithKeys(t,r,xt(r),n)},e.prototype.whenWithKeys=function(t,r,n,i){for(var a=this._tracks,o=0;o<n.length;o++){var s=n[o],l=a[s];if(!l){l=a[s]=new bS(s);var u=void 0,f=this._getAdditiveTrack(s);if(f){var h=f.keyframes,v=h[h.length-1];u=v&&v.value,f.valType===Ki&&u&&(u=Yo(u))}else u=this._target[s];if(u==null)continue;t>0&&l.addKeyframe(0,Wo(u),i),this._trackKeys.push(s)}l.addKeyframe(t,Wo(r[s]),i)}return this._maxTime=Math.max(this._maxTime,t),this},e.prototype.pause=function(){this._clip.pause(),this._paused=!0},e.prototype.resume=function(){this._clip.resume(),this._paused=!1},e.prototype.isPaused=function(){return!!this._paused},e.prototype.duration=function(t){return this._maxTime=t,this._force=!0,this},e.prototype._doneCallback=function(){this._setTracksFinished(),this._clip=null;var t=this._doneCbs;if(t)for(var r=t.length,n=0;n<r;n++)t[n].call(this)},e.prototype._abortedCallback=function(){this._setTracksFinished();var t=this.animation,r=this._abortedCbs;if(t&&t.removeClip(this._clip),this._clip=null,r)for(var n=0;n<r.length;n++)r[n].call(this)},e.prototype._setTracksFinished=function(){for(var t=this._tracks,r=this._trackKeys,n=0;n<r.length;n++)t[r[n]].setFinished()},e.prototype._getAdditiveTrack=function(t){var r,n=this._additiveAnimators;if(n)for(var i=0;i<n.length;i++){var a=n[i].getTrack(t);a&&(r=a)}return r},e.prototype.start=function(t){if(!(this._started>0)){this._started=1;for(var r=this,n=[],i=this._maxTime||0,a=0;a<this._trackKeys.length;a++){var o=this._trackKeys[a],s=this._tracks[o],l=this._getAdditiveTrack(o),u=s.keyframes,f=u.length;if(s.prepare(i,l),s.needsAnimate())if(!this._allowDiscrete&&s.discrete){var h=u[f-1];h&&(r._target[s.propName]=h.rawValue),s.setFinished()}else n.push(s)}if(n.length||this._force){var v=new hS({life:i,loop:this._loop,delay:this._delay||0,onframe:function(c){r._started=2;var d=r._additiveAnimators;if(d){for(var p=!1,m=0;m<d.length;m++)if(d[m]._clip){p=!0;break}p||(r._additiveAnimators=null)}for(var m=0;m<n.length;m++)n[m].step(r._target,c);var g=r._onframeCbs;if(g)for(var m=0;m<g.length;m++)g[m](r._target,c)},ondestroy:function(){r._doneCallback()}});this._clip=v,this.animation&&this.animation.addClip(v),t&&v.setEasing(t)}else this._doneCallback();return this}},e.prototype.stop=function(t){if(this._clip){var r=this._clip;t&&r.onframe(1),this._abortedCallback()}},e.prototype.delay=function(t){return this._delay=t,this},e.prototype.during=function(t){return t&&(this._onframeCbs||(this._onframeCbs=[]),this._onframeCbs.push(t)),this},e.prototype.done=function(t){return t&&(this._doneCbs||(this._doneCbs=[]),this._doneCbs.push(t)),this},e.prototype.aborted=function(t){return t&&(this._abortedCbs||(this._abortedCbs=[]),this._abortedCbs.push(t)),this},e.prototype.getClip=function(){return this._clip},e.prototype.getTrack=function(t){return this._tracks[t]},e.prototype.getTracks=function(){var t=this;return rt(this._trackKeys,function(r){return t._tracks[r]})},e.prototype.stopTracks=function(t,r){if(!t.length||!this._clip)return!0;for(var n=this._tracks,i=this._trackKeys,a=0;a<t.length;a++){var o=n[t[a]];o&&!o.isFinished()&&(r?o.step(this._target,1):this._started===1&&o.step(this._target,0),o.setFinished())}for(var s=!0,a=0;a<i.length;a++)if(!n[i[a]].isFinished()){s=!1;break}return s&&this._abortedCallback(),s},e.prototype.saveTo=function(t,r,n){if(t){r=r||this._trackKeys;for(var i=0;i<r.length;i++){var a=r[i],o=this._tracks[a];if(!(!o||o.isFinished())){var s=o.keyframes,l=s[n?0:s.length-1];l&&(t[a]=Wo(l.rawValue))}}}},e.prototype.__changeFinalValue=function(t,r){r=r||xt(t);for(var n=0;n<r.length;n++){var i=r[n],a=this._tracks[i];if(a){var o=a.keyframes;if(o.length>1){var s=o.pop();a.addKeyframe(s.time,t[i]),a.prepare(this._maxTime,a.getAdditiveTrack())}}}},e})();function ei(){return new Date().getTime()}var TS=(function(e){V(t,e);function t(r){var n=e.call(this)||this;return n._running=!1,n._time=0,n._pausedTime=0,n._pauseStart=0,n._paused=!1,r=r||{},n.stage=r.stage||{},n}return t.prototype.addClip=function(r){r.animation&&this.removeClip(r),this._head?(this._tail.next=r,r.prev=this._tail,r.next=null,this._tail=r):this._head=this._tail=r,r.animation=this},t.prototype.addAnimator=function(r){r.animation=this;var n=r.getClip();n&&this.addClip(n)},t.prototype.removeClip=function(r){if(r.animation){var n=r.prev,i=r.next;n?n.next=i:this._head=i,i?i.prev=n:this._tail=n,r.next=r.prev=r.animation=null}},t.prototype.removeAnimator=function(r){var n=r.getClip();n&&this.removeClip(n),r.animation=null},t.prototype.update=function(r){for(var n=ei()-this._pausedTime,i=n-this._time,a=this._head;a;){var o=a.next,s=a.step(n,i);s&&(a.ondestroy(),this.removeClip(a)),a=o}this._time=n,r||(this.trigger("frame",i),this.stage.update&&this.stage.update())},t.prototype._startLoop=function(){var r=this;this._running=!0;function n(){r._running&&(hs(n),!r._paused&&r.update())}hs(n)},t.prototype.start=function(){this._running||(this._time=ei(),this._pausedTime=0,this._startLoop())},t.prototype.stop=function(){this._running=!1},t.prototype.pause=function(){this._paused||(this._pauseStart=ei(),this._paused=!0)},t.prototype.resume=function(){this._paused&&(this._pausedTime+=ei()-this._pauseStart,this._paused=!1)},t.prototype.clear=function(){for(var r=this._head;r;){var n=r.next;r.prev=r.next=r.animation=null,r=n}this._head=this._tail=null},t.prototype.isFinished=function(){return this._head==null},t.prototype.animate=function(r,n){n=n||{},this.start();var i=new yh(r,n.loop);return this.addAnimator(i),i},t})(or),wS=300,Nl=st.domSupported,Fl=(function(){var e=["click","dblclick","mousewheel","wheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],t=["touchstart","touchend","touchmove"],r={pointerdown:1,pointerup:1,pointermove:1,pointerout:1},n=rt(e,function(i){var a=i.replace("mouse","pointer");return r.hasOwnProperty(a)?a:i});return{mouse:e,touch:t,pointer:n}})(),ac={mouse:["mousemove","mouseup"],pointer:["pointermove","pointerup"]},oc=!1;function uf(e){var t=e.pointerType;return t==="pen"||t==="touch"}function xS(e){e.touching=!0,e.touchTimer!=null&&(clearTimeout(e.touchTimer),e.touchTimer=null),e.touchTimer=setTimeout(function(){e.touching=!1,e.touchTimer=null},700)}function zl(e){e&&(e.zrByTouch=!0)}function CS(e,t){return ye(e.dom,new DS(e,t),!0)}function tm(e,t){for(var r=t,n=!1;r&&r.nodeType!==9&&!(n=r.domBelongToZr||r!==t&&r===e.painterRoot);)r=r.parentNode;return n}var DS=(function(){function e(t,r){this.stopPropagation=$t,this.stopImmediatePropagation=$t,this.preventDefault=$t,this.type=r.type,this.target=this.currentTarget=t.dom,this.pointerType=r.pointerType,this.clientX=r.clientX,this.clientY=r.clientY}return e})(),Oe={mousedown:function(e){e=ye(this.dom,e),this.__mayPointerCapture=[e.zrX,e.zrY],this.trigger("mousedown",e)},mousemove:function(e){e=ye(this.dom,e);var t=this.__mayPointerCapture;t&&(e.zrX!==t[0]||e.zrY!==t[1])&&this.__togglePointerCapture(!0),this.trigger("mousemove",e)},mouseup:function(e){e=ye(this.dom,e),this.__togglePointerCapture(!1),this.trigger("mouseup",e)},mouseout:function(e){e=ye(this.dom,e);var t=e.toElement||e.relatedTarget;tm(this,t)||(this.__pointerCapturing&&(e.zrEventControl="no_globalout"),this.trigger("mouseout",e))},wheel:function(e){oc=!0,e=ye(this.dom,e),this.trigger("mousewheel",e)},mousewheel:function(e){oc||(e=ye(this.dom,e),this.trigger("mousewheel",e))},touchstart:function(e){e=ye(this.dom,e),zl(e),this.__lastTouchMoment=new Date,this.handler.processGesture(e,"start"),Oe.mousemove.call(this,e),Oe.mousedown.call(this,e)},touchmove:function(e){e=ye(this.dom,e),zl(e),this.handler.processGesture(e,"change"),Oe.mousemove.call(this,e)},touchend:function(e){e=ye(this.dom,e),zl(e),this.handler.processGesture(e,"end"),Oe.mouseup.call(this,e),+new Date-+this.__lastTouchMoment<wS&&Oe.click.call(this,e)},pointerdown:function(e){Oe.mousedown.call(this,e)},pointermove:function(e){uf(e)||Oe.mousemove.call(this,e)},pointerup:function(e){Oe.mouseup.call(this,e)},pointerout:function(e){uf(e)||Oe.mouseout.call(this,e)}};D(["click","dblclick","contextmenu"],function(e){Oe[e]=function(t){t=ye(this.dom,t),this.trigger(e,t)}});var ff={pointermove:function(e){uf(e)||ff.mousemove.call(this,e)},pointerup:function(e){ff.mouseup.call(this,e)},mousemove:function(e){this.trigger("mousemove",e)},mouseup:function(e){var t=this.__pointerCapturing;this.__togglePointerCapture(!1),this.trigger("mouseup",e),t&&(e.zrEventControl="only_globalout",this.trigger("mouseout",e))}};function MS(e,t){var r=t.domHandlers;st.pointerEventsSupported?D(Fl.pointer,function(n){$o(t,n,function(i){r[n].call(e,i)})}):(st.touchEventsSupported&&D(Fl.touch,function(n){$o(t,n,function(i){r[n].call(e,i),xS(t)})}),D(Fl.mouse,function(n){$o(t,n,function(i){i=ph(i),t.touching||r[n].call(e,i)})}))}function AS(e,t){st.pointerEventsSupported?D(ac.pointer,r):st.touchEventsSupported||D(ac.mouse,r);function r(n){function i(a){a=ph(a),tm(e,a.target)||(a=CS(e,a),t.domHandlers[n].call(e,a))}$o(t,n,i,{capture:!0})}}function $o(e,t,r,n){e.mounted[t]=r,e.listenerOpts[t]=n,V1(e.domTarget,t,r,n)}function Hl(e){var t=e.mounted;for(var r in t)t.hasOwnProperty(r)&&G1(e.domTarget,r,t[r],e.listenerOpts[r]);e.mounted={}}var sc=(function(){function e(t,r){this.mounted={},this.listenerOpts={},this.touching=!1,this.domTarget=t,this.domHandlers=r}return e})(),LS=(function(e){V(t,e);function t(r,n){var i=e.call(this)||this;return i.__pointerCapturing=!1,i.dom=r,i.painterRoot=n,i._localHandlerScope=new sc(r,Oe),Nl&&(i._globalHandlerScope=new sc(document,ff)),MS(i,i._localHandlerScope),i}return t.prototype.dispose=function(){Hl(this._localHandlerScope),Nl&&Hl(this._globalHandlerScope)},t.prototype.setCursor=function(r){this.dom.style&&(this.dom.style.cursor=r||"default")},t.prototype.__togglePointerCapture=function(r){if(this.__mayPointerCapture=null,Nl&&+this.__pointerCapturing^+r){this.__pointerCapturing=r;var n=this._globalHandlerScope;r?AS(this,n):Hl(n)}},t})(or),em=1;st.hasGlobalWindow&&(em=Math.max(window.devicePixelRatio||window.screen&&window.screen.deviceXDPI/window.screen.logicalXDPI||1,1));var ms=em,hf=.4,vf="#333",cf="#ccc",IS="#eee",lc=ka,uc=5e-5;function Kr(e){return e>uc||e<-uc}var Qr=[],Bn=[],Vl=qe(),Gl=Math.abs,Na=(function(){function e(){}return e.prototype.getLocalTransform=function(t){return PS(this,t)},e.prototype.setPosition=function(t){this.x=t[0],this.y=t[1]},e.prototype.setScale=function(t){this.scaleX=t[0],this.scaleY=t[1]},e.prototype.setSkew=function(t){this.skewX=t[0],this.skewY=t[1]},e.prototype.setOrigin=function(t){this.originX=t[0],this.originY=t[1]},e.prototype.needLocalTransform=function(){return Kr(this.rotation)||Kr(this.x)||Kr(this.y)||Kr(this.scaleX-1)||Kr(this.scaleY-1)||Kr(this.skewX)||Kr(this.skewY)},e.prototype.updateTransform=function(){var t=this.parent&&this.parent.transform,r=this.needLocalTransform(),n=this.transform;if(!(r||t)){n&&(lc(n),this.invTransform=null);return}n=n||qe(),r?this.getLocalTransform(n):lc(n),t&&(r?ra(n,t,n):gh(n,t)),this.transform=n,this._resolveGlobalScaleRatio(n),this.invTransform=this.invTransform||qe(),Oa(this.invTransform,n)},e.prototype._resolveGlobalScaleRatio=function(t){var r=this.globalScaleRatio;if(r!=null&&r!==1){this.getGlobalScale(Qr);var n=Qr[0]<0?-1:1,i=Qr[1]<0?-1:1,a=((Qr[0]-n)*r+n)/Qr[0]||0,o=((Qr[1]-i)*r+i)/Qr[1]||0;t[0]*=a,t[1]*=a,t[2]*=o,t[3]*=o}},e.prototype.getComputedTransform=function(){for(var t=this,r=[];t;)r.push(t),t=t.parent;for(;t=r.pop();)t.updateTransform();return this.transform},e.prototype.setLocalTransform=function(t){if(t){var r=t[0]*t[0]+t[1]*t[1],n=t[2]*t[2]+t[3]*t[3],i=Math.atan2(t[1],t[0]),a=Math.PI/2+i-Math.atan2(t[3],t[2]);n=Math.sqrt(n)*Math.cos(a),r=Math.sqrt(r),this.skewX=a,this.skewY=0,this.rotation=-i,this.x=+t[4],this.y=+t[5],this.scaleX=r,this.scaleY=n,this.originX=0,this.originY=0}},e.prototype.decomposeTransform=function(){if(this.transform){var t=this.parent,r=this.transform;t&&t.transform&&(t.invTransform=t.invTransform||qe(),ra(Bn,t.invTransform,r),r=Bn);var n=this.originX,i=this.originY;(n||i)&&(Vl[4]=n,Vl[5]=i,ra(Bn,r,Vl),Bn[4]-=n,Bn[5]-=i,r=Bn),this.setLocalTransform(r)}},e.prototype.getGlobalScale=function(t){var r=this.transform;return t=t||[],r?(t[0]=Math.sqrt(r[0]*r[0]+r[1]*r[1]),t[1]=Math.sqrt(r[2]*r[2]+r[3]*r[3]),r[0]<0&&(t[0]=-t[0]),r[3]<0&&(t[1]=-t[1]),t):(t[0]=1,t[1]=1,t)},e.prototype.transformCoordToLocal=function(t,r){var n=[t,r],i=this.invTransform;return i&&Ae(n,n,i),n},e.prototype.transformCoordToGlobal=function(t,r){var n=[t,r],i=this.transform;return i&&Ae(n,n,i),n},e.prototype.getLineScale=function(){var t=this.transform;return t&&Gl(t[0]-1)>1e-10&&Gl(t[3]-1)>1e-10?Math.sqrt(Gl(t[0]*t[3]-t[2]*t[1])):1},e.prototype.copyTransform=function(t){ys(this,t)},e.getLocalTransform=function(t,r){r=r||[];var n=t.originX||0,i=t.originY||0,a=t.scaleX,o=t.scaleY,s=t.anchorX,l=t.anchorY,u=t.rotation||0,f=t.x,h=t.y,v=t.skewX?Math.tan(t.skewX):0,c=t.skewY?Math.tan(-t.skewY):0;if(n||i||s||l){var d=n+s,p=i+l;r[4]=-d*a-v*p*o,r[5]=-p*o-c*d*a}else r[4]=r[5]=0;return r[0]=a,r[3]=o,r[1]=c*a,r[2]=v*o,u&&mh(r,r,u),r[4]+=n+f,r[5]+=i+h,r},e.initDefaultProps=(function(){var t=e.prototype;t.scaleX=t.scaleY=t.globalScaleRatio=1,t.x=t.y=t.originX=t.originY=t.skewX=t.skewY=t.rotation=t.anchorX=t.anchorY=0})(),e})(),PS=Na.getLocalTransform,qs=["x","y","originX","originY","anchorX","anchorY","rotation","scaleX","scaleY","skewX","skewY"];function ys(e,t){return c1(e,t,qs)}function Qe(e){oo||(oo=new vi(100)),e=e||Nr;var t=oo.get(e);return t||(t={font:e,strWidthCache:new vi(500),asciiWidthMap:null,asciiWidthMapTried:!1,stWideCharWidth:ue.measureText("国",e).width,asciiCharWidth:ue.measureText("a",e).width},oo.put(e,t)),t}var oo;function ES(e){if(!(Ul>=fc)){e=e||Nr;for(var t=[],r=+new Date,n=0;n<=127;n++)t[n]=ue.measureText(String.fromCharCode(n),e).width;var i=+new Date-r;return i>16?Ul=fc:i>2&&Ul++,t}}var Ul=0,fc=5;function rm(e,t){return e.asciiWidthMapTried||(e.asciiWidthMap=ES(e.font),e.asciiWidthMapTried=!0),0<=t&&t<=127?e.asciiWidthMap!=null?e.asciiWidthMap[t]:e.asciiCharWidth:e.stWideCharWidth}function Je(e,t){var r=e.strWidthCache,n=r.get(t);return n==null&&(n=ue.measureText(t,e.font).width,r.put(t,n)),n}function hc(e,t,r,n){var i=Je(Qe(t),e),a=Ks(t),o=ci(0,i,r),s=xn(0,a,n),l=new it(o,s,i,a);return l}function nm(e,t,r,n){var i=((e||"")+"").split(`
|
|
15
|
+
`),a=i.length;if(a===1)return hc(i[0],t,r,n);for(var o=new it(0,0,0,0),s=0;s<i.length;s++){var l=hc(i[s],t,r,n);s===0?o.copy(l):o.union(l)}return o}function ci(e,t,r,n){return r==="right"?n?e+=t:e-=t:r==="center"&&(n?e+=t/2:e-=t/2),e}function xn(e,t,r,n){return r==="middle"?n?e+=t/2:e-=t/2:r==="bottom"&&(n?e+=t:e-=t),e}function Ks(e){return Qe(e).stWideCharWidth}function di(e,t){return typeof e=="string"?e.lastIndexOf("%")>=0?parseFloat(e)/100*t:parseFloat(e):e}function im(e,t,r){var n=t.position||"inside",i=t.distance!=null?t.distance:5,a=r.height,o=r.width,s=a/2,l=r.x,u=r.y,f="left",h="top";if(n instanceof Array)l+=di(n[0],r.width),u+=di(n[1],r.height),f=null,h=null;else switch(n){case"left":l-=i,u+=s,f="right",h="middle";break;case"right":l+=i+o,u+=s,h="middle";break;case"top":l+=o/2,u-=i,f="center",h="bottom";break;case"bottom":l+=o/2,u+=a+i,f="center";break;case"inside":l+=o/2,u+=s,f="center",h="middle";break;case"insideLeft":l+=i,u+=s,h="middle";break;case"insideRight":l+=o-i,u+=s,f="right",h="middle";break;case"insideTop":l+=o/2,u+=i,f="center";break;case"insideBottom":l+=o/2,u+=a-i,f="center",h="bottom";break;case"insideTopLeft":l+=i,u+=i;break;case"insideTopRight":l+=o-i,u+=i,f="right";break;case"insideBottomLeft":l+=i,u+=a-i,h="bottom";break;case"insideBottomRight":l+=o-i,u+=a-i,f="right",h="bottom";break}return e=e||{},e.x=l,e.y=u,e.align=f,e.verticalAlign=h,e}var Wl="__zr_normal__",Yl=qs.concat(["ignore"]),RS=wi(qs,function(e,t){return e[t]=!0,e},{ignore:!1}),Nn={},kS=new it(0,0,0,0),so=[],Zo=0,Qs=1,Js=(function(){function e(t){this.id=Og(),this.animators=[],this.currentStates=[],this.states={},this._init(t)}return e.prototype._init=function(t){this.attr(t)},e.prototype.drift=function(t,r,n){switch(this.draggable){case"horizontal":r=0;break;case"vertical":t=0;break}var i=this.transform;i||(i=this.transform=[1,0,0,1,0,0]),i[4]+=t,i[5]+=r,this.decomposeTransform(),this.markRedraw()},e.prototype.beforeUpdate=function(){},e.prototype.afterUpdate=function(){},e.prototype.update=function(){this.updateTransform(),this.__dirty&&this.updateInnerText()},e.prototype.updateInnerText=function(t){var r=this._textContent;if(r&&(!r.ignore||t)){this.textConfig||(this.textConfig={});var n=this.textConfig,i=n.local,a=r.innerTransformable,o=void 0,s=void 0,l=!1;a.parent=i?this:null;var u=!1;a.copyTransform(r);var f=n.position!=null,h=n.autoOverflowArea,v=void 0;if((h||f)&&(v=kS,n.layoutRect?v.copy(n.layoutRect):v.copy(this.getBoundingRect()),i||v.applyTransform(this.transform)),f){this.calculateTextPosition?this.calculateTextPosition(Nn,n,v):im(Nn,n,v),a.x=Nn.x,a.y=Nn.y,o=Nn.align,s=Nn.verticalAlign;var c=n.origin;if(c&&n.rotation!=null){var d=void 0,p=void 0;c==="center"?(d=v.width*.5,p=v.height*.5):(d=di(c[0],v.width),p=di(c[1],v.height)),u=!0,a.originX=-a.x+d+(i?0:v.x),a.originY=-a.y+p+(i?0:v.y)}}n.rotation!=null&&(a.rotation=n.rotation);var m=n.offset;m&&(a.x+=m[0],a.y+=m[1],u||(a.originX=-m[0],a.originY=-m[1]));var g=this._innerTextDefaultStyle||(this._innerTextDefaultStyle={});if(h){var y=g.overflowRect=g.overflowRect||new it(0,0,0,0);a.getLocalTransform(so),Oa(so,so),it.copy(y,v),y.applyTransform(so)}else g.overflowRect=null;var _=n.inside==null?typeof n.position=="string"&&n.position.indexOf("inside")>=0:n.inside,S=void 0,b=void 0,T=void 0;_&&this.canBeInsideText()?(S=n.insideFill,b=n.insideStroke,(S==null||S==="auto")&&(S=this.getInsideTextFill()),(b==null||b==="auto")&&(b=this.getInsideTextStroke(S),T=!0)):(S=n.outsideFill,b=n.outsideStroke,(S==null||S==="auto")&&(S=this.getOutsideFill()),(b==null||b==="auto")&&(b=this.getOutsideStroke(S),T=!0)),S=S||"#000",(S!==g.fill||b!==g.stroke||T!==g.autoStroke||o!==g.align||s!==g.verticalAlign)&&(l=!0,g.fill=S,g.stroke=b,g.autoStroke=T,g.align=o,g.verticalAlign=s,r.setDefaultTextStyle(g)),r.__dirty|=ne,l&&r.dirtyStyle(!0)}},e.prototype.canBeInsideText=function(){return!0},e.prototype.getInsideTextFill=function(){return"#fff"},e.prototype.getInsideTextStroke=function(t){return"#000"},e.prototype.getOutsideFill=function(){return this.__zr&&this.__zr.isDarkMode()?cf:vf},e.prototype.getOutsideStroke=function(t){var r=this.__zr&&this.__zr.getBackgroundColor(),n=typeof r=="string"&&Ke(r);n||(n=[255,255,255,1]);for(var i=n[3],a=this.__zr.isDarkMode(),o=0;o<3;o++)n[o]=n[o]*i+(a?0:255)*(1-i);return n[3]=1,Ba(n,"rgba")},e.prototype.traverse=function(t,r){},e.prototype.attrKV=function(t,r){t==="textConfig"?this.setTextConfig(r):t==="textContent"?this.setTextContent(r):t==="clipPath"?this.setClipPath(r):t==="extra"?(this.extra=this.extra||{},N(this.extra,r)):this[t]=r},e.prototype.hide=function(){this.ignore=!0,this.markRedraw()},e.prototype.show=function(){this.ignore=!1,this.markRedraw()},e.prototype.attr=function(t,r){if(typeof t=="string")this.attrKV(t,r);else if(K(t))for(var n=t,i=xt(n),a=0;a<i.length;a++){var o=i[a];this.attrKV(o,t[o])}return this.markRedraw(),this},e.prototype.saveCurrentToNormalState=function(t){this._innerSaveToNormal(t);for(var r=this._normalState,n=0;n<this.animators.length;n++){var i=this.animators[n],a=i.__fromStateTransition;if(!(i.getLoop()||a&&a!==Wl)){var o=i.targetName,s=o?r[o]:r;i.saveTo(s)}}},e.prototype._innerSaveToNormal=function(t){var r=this._normalState;r||(r=this._normalState={}),t.textConfig&&!r.textConfig&&(r.textConfig=this.textConfig),this._savePrimaryToNormal(t,r,Yl)},e.prototype._savePrimaryToNormal=function(t,r,n){for(var i=0;i<n.length;i++){var a=n[i];t[a]!=null&&!(a in r)&&(r[a]=this[a])}},e.prototype.hasState=function(){return this.currentStates.length>0},e.prototype.getState=function(t){return this.states[t]},e.prototype.ensureState=function(t){var r=this.states;return r[t]||(r[t]={}),r[t]},e.prototype.clearStates=function(t){this.useState(Wl,!1,t)},e.prototype.useState=function(t,r,n,i){var a=t===Wl,o=this.hasState();if(!(!o&&a)){var s=this.currentStates,l=this.stateTransition;if(!(vt(s,t)>=0&&(r||s.length===1))){var u;if(this.stateProxy&&!a&&(u=this.stateProxy(t)),u||(u=this.states&&this.states[t]),!u&&!a){vh("State "+t+" not exists.");return}a||this.saveCurrentToNormalState(u);var f=this._textContent,h=vc(this,f,u,i);h&&!this.__inHover&&(this.__inHover=h),this._applyStateObj(t,u,this._normalState,r,dc(this,n,l),l);var v=this._textGuide;return f&&f.useState(t,r,n,!!h),v&&v.useState(t,r,n,!!h),a?(this.currentStates=[],this._normalState={}):r?this.currentStates.push(t):this.currentStates=[t],this._updateAnimationTargets(),this.markRedraw(),!h&&this.__inHover&&(this.__inHover=Zo,this.__dirty&=~ne),u}}},e.prototype.useStates=function(t,r,n){if(!t.length)this.clearStates();else{var i=[],a=this.currentStates,o=t.length,s=o===a.length;if(s){for(var l=0;l<o;l++)if(t[l]!==a[l]){s=!1;break}}if(s)return;for(var l=0;l<o;l++){var u=t[l],f=void 0;this.stateProxy&&(f=this.stateProxy(u,t)),f||(f=this.states[u]),f&&i.push(f)}var h=i[o-1],v=this._textContent,c=vc(this,v,h,n);c&&!this.__inHover&&(this.__inHover=c);var d=this._mergeStates(i),p=this.stateTransition;this.saveCurrentToNormalState(d),this._applyStateObj(t.join(","),d,this._normalState,!1,dc(this,r,p),p);var m=this._textGuide;v&&v.useStates(t,r,!!c),m&&m.useStates(t,r,!!c),this._updateAnimationTargets(),this.currentStates=t.slice(),this.markRedraw(),!c&&this.__inHover&&(this.__inHover=Zo,this.__dirty&=~ne)}},e.prototype.isSilent=function(){for(var t=this;t;){if(t.silent)return!0;var r=t.__hostTarget;t=r?t.ignoreHostSilent?null:r:t.parent}return!1},e.prototype._updateAnimationTargets=function(){for(var t=0;t<this.animators.length;t++){var r=this.animators[t];r.targetName&&r.changeTarget(this[r.targetName])}},e.prototype.removeState=function(t){var r=vt(this.currentStates,t);if(r>=0){var n=this.currentStates.slice();n.splice(r,1),this.useStates(n)}},e.prototype.replaceState=function(t,r,n){var i=this.currentStates.slice(),a=vt(i,t),o=vt(i,r)>=0;a>=0?o?i.splice(a,1):i[a]=r:n&&!o&&i.push(r),this.useStates(i)},e.prototype.toggleState=function(t,r){r?this.useState(t,!0):this.removeState(t)},e.prototype._mergeStates=function(t){for(var r={},n,i=0;i<t.length;i++){var a=t[i];N(r,a),a.textConfig&&(n=n||{},N(n,a.textConfig))}return n&&(r.textConfig=n),r},e.prototype._applyStateObj=function(t,r,n,i,a,o){if(this.__inHover!==Qs){var s=!(r&&i);r&&r.textConfig?(this.textConfig=N({},i?this.textConfig:n.textConfig),N(this.textConfig,r.textConfig)):s&&n.textConfig&&(this.textConfig=n.textConfig);for(var l={},u=!1,f=0;f<Yl.length;f++){var h=Yl[f],v=a&&RS[h];r&&r[h]!=null?v?(u=!0,l[h]=r[h]):this[h]=r[h]:s&&n[h]!=null&&(v?(u=!0,l[h]=n[h]):this[h]=n[h])}if(!a)for(var f=0;f<this.animators.length;f++){var c=this.animators[f],d=c.targetName;c.getLoop()||c.__changeFinalValue(d?(r||n)[d]:r||n)}u&&this._transitionState(t,l,o)}},e.prototype._attachComponent=function(t){if(!(t.__zr&&!t.__hostTarget)&&t!==this){var r=this.__zr;r&&t.addSelfToZr(r),t.__zr=r,t.__hostTarget=this}},e.prototype._detachComponent=function(t){t.__zr&&t.removeSelfFromZr(t.__zr),t.__zr=null,t.__hostTarget=null},e.prototype.getClipPath=function(){return this._clipPath},e.prototype.setClipPath=function(t){this._clipPath&&this._clipPath!==t&&this.removeClipPath(),this._attachComponent(t),this._clipPath=t,this.markRedraw()},e.prototype.removeClipPath=function(){var t=this._clipPath;t&&(this._detachComponent(t),this._clipPath=null,this.markRedraw())},e.prototype.getTextContent=function(){return this._textContent},e.prototype.setTextContent=function(t){var r=this._textContent;r!==t&&(r&&r!==t&&this.removeTextContent(),t.innerTransformable=new Na,this._attachComponent(t),this._textContent=t,this.markRedraw())},e.prototype.setTextConfig=function(t){this.textConfig||(this.textConfig={}),N(this.textConfig,t),this.markRedraw()},e.prototype.removeTextConfig=function(){this.textConfig=null,this.markRedraw()},e.prototype.removeTextContent=function(){var t=this._textContent;t&&(t.innerTransformable=null,this._detachComponent(t),this._textContent=null,this._innerTextDefaultStyle=null,this.markRedraw())},e.prototype.getTextGuideLine=function(){return this._textGuide},e.prototype.setTextGuideLine=function(t){this._textGuide&&this._textGuide!==t&&this.removeTextGuideLine(),this._attachComponent(t),this._textGuide=t,this.markRedraw()},e.prototype.removeTextGuideLine=function(){var t=this._textGuide;t&&(this._detachComponent(t),this._textGuide=null,this.markRedraw())},e.prototype.markRedraw=function(){this.__dirty|=ne;var t=this.__zr;t&&(this.__inHover?t.refreshHover():t.refresh()),this.__hostTarget&&this.__hostTarget.markRedraw()},e.prototype.dirty=function(){this.markRedraw()},e.prototype.addSelfToZr=function(t){if(this.__zr!==t){this.__zr=t;var r=this.animators;if(r)for(var n=0;n<r.length;n++)t.animation.addAnimator(r[n]);this._clipPath&&this._clipPath.addSelfToZr(t),this._textContent&&this._textContent.addSelfToZr(t),this._textGuide&&this._textGuide.addSelfToZr(t)}},e.prototype.removeSelfFromZr=function(t){if(this.__zr){this.__zr=null;var r=this.animators;if(r)for(var n=0;n<r.length;n++)t.animation.removeAnimator(r[n]);this._clipPath&&this._clipPath.removeSelfFromZr(t),this._textContent&&this._textContent.removeSelfFromZr(t),this._textGuide&&this._textGuide.removeSelfFromZr(t)}},e.prototype.animate=function(t,r,n){var i=t?this[t]:this,a=new yh(i,r,n);return t&&(a.targetName=t),this.addAnimator(a,t),a},e.prototype.addAnimator=function(t,r){var n=this.__zr,i=this;t.during(function(){i.updateDuringAnimation(r)}).done(function(){var a=i.animators,o=vt(a,t);o>=0&&a.splice(o,1)}),this.animators.push(t),n&&n.animation.addAnimator(t),n&&n.wakeUp()},e.prototype.updateDuringAnimation=function(t){this.markRedraw()},e.prototype.stopAnimation=function(t,r){for(var n=this.animators,i=n.length,a=[],o=0;o<i;o++){var s=n[o];!t||t===s.scope?s.stop(r):a.push(s)}return this.animators=a,this},e.prototype.animateTo=function(t,r,n){Xl(this,t,r,n)},e.prototype.animateFrom=function(t,r,n){Xl(this,t,r,n,!0)},e.prototype._transitionState=function(t,r,n,i){for(var a=Xl(this,r,n,i),o=0;o<a.length;o++)a[o].__fromStateTransition=t},e.prototype.getBoundingRect=function(){return null},e.prototype.getPaintRect=function(){return null},e.initDefaultProps=(function(){var t=e.prototype;t.type="element",t.name="",t.ignore=t.silent=t.ignoreHostSilent=t.isGroup=t.draggable=t.dragging=t.ignoreClip=!1,t.__inHover=Zo,t.__dirty=ne;function r(n,i,a,o){Object.defineProperty(t,n,{get:function(){if(!this[i]){var l=this[i]=[];s(this,l)}return this[i]},set:function(l){this[a]=l[0],this[o]=l[1],this[i]=l,s(this,l)}});function s(l,u){Object.defineProperty(u,0,{get:function(){return l[a]},set:function(f){l[a]=f}}),Object.defineProperty(u,1,{get:function(){return l[o]},set:function(f){l[o]=f}})}}Object.defineProperty&&(r("position","_legacyPos","x","y"),r("scale","_legacyScale","scaleX","scaleY"),r("origin","_legacyOrigin","originX","originY"))})(),e})();ar(Js,or);ar(Js,Na);function Xl(e,t,r,n,i){r=r||{};var a=[];am(e,"",e,t,r,n,a,i);var o=a.length,s=!1,l=r.done,u=r.aborted,f=function(){s=!0,o--,o<=0&&(s?l&&l():u&&u())},h=function(){o--,o<=0&&(s?l&&l():u&&u())};o||l&&l(),a.length>0&&r.during&&a[0].during(function(d,p){r.during(p)});for(var v=0;v<a.length;v++){var c=a[v];f&&c.done(f),h&&c.aborted(h),r.force&&c.duration(r.duration),c.start(r.easing)}return a}function $l(e,t,r){for(var n=0;n<r;n++)e[n]=t[n]}function OS(e){return ie(e[0])}function BS(e,t,r){if(ie(t[r]))if(ie(e[r])||(e[r]=[]),ae(t[r])){var n=t[r].length;e[r].length!==n&&(e[r]=new t[r].constructor(n),$l(e[r],t[r],n))}else{var i=t[r],a=e[r],o=i.length;if(OS(i))for(var s=i[0].length,l=0;l<o;l++)a[l]?$l(a[l],i[l],s):a[l]=Array.prototype.slice.call(i[l]);else $l(a,i,o);a.length=i.length}else e[r]=t[r]}function NS(e,t){return e===t||ie(e)&&ie(t)&&FS(e,t)}function FS(e,t){var r=e.length;if(r!==t.length)return!1;for(var n=0;n<r;n++)if(e[n]!==t[n])return!1;return!0}function am(e,t,r,n,i,a,o,s){for(var l=xt(n),u=i.duration,f=i.delay,h=i.additive,v=i.setToFinal,c=!K(a),d=e.animators,p=[],m=0;m<l.length;m++){var g=l[m],y=n[g];if(y!=null&&r[g]!=null&&(c||a[g]))if(K(y)&&!ie(y)&&!$s(y)){if(t){s||(r[g]=y,e.updateDuringAnimation(t));continue}am(e,g,r[g],y,i,a&&a[g],o,s)}else p.push(g);else s||(r[g]=y,e.updateDuringAnimation(t),p.push(g))}var _=p.length;if(!h&&_)for(var S=0;S<d.length;S++){var b=d[S];if(b.targetName===t){var T=b.stopTracks(p);if(T){var w=vt(d,b);d.splice(w,1)}}}if(i.force||(p=Xt(p,function(A){return!NS(n[A],r[A])}),_=p.length),_>0||i.force&&!o.length){var M=void 0,C=void 0,x=void 0;if(s){C={},v&&(M={});for(var S=0;S<_;S++){var g=p[S];C[g]=r[g],v?M[g]=n[g]:r[g]=n[g]}}else if(v){x={};for(var S=0;S<_;S++){var g=p[S];x[g]=Wo(r[g]),BS(r,n,g)}}var b=new yh(r,!1,!1,h?Xt(d,function(I){return I.targetName===t}):null);b.targetName=t,i.scope&&(b.scope=i.scope),v&&M&&b.whenWithKeys(0,M,p),x&&b.whenWithKeys(0,x,p),b.whenWithKeys(u??500,s?C:n,p).delay(f||0),e.addAnimator(b,t),o.push(b)}}function vc(e,t,r,n){return!(r&&r.hoverLayer||n)||cc(e)||t&&cc(t)?Zo:Qs}function cc(e){return e.type==="text"||e.type==="tspan"}function dc(e,t,r){return!t&&!e.__inHover&&r&&r.duration>0}var Vt=(function(e){V(t,e);function t(r){var n=e.call(this)||this;return n.isGroup=!0,n._children=[],n.attr(r),n}return t.prototype.childrenRef=function(){return this._children},t.prototype.children=function(){return this._children.slice()},t.prototype.childAt=function(r){return this._children[r]},t.prototype.childOfName=function(r){for(var n=this._children,i=0;i<n.length;i++)if(n[i].name===r)return n[i]},t.prototype.childCount=function(){return this._children.length},t.prototype.add=function(r){return r&&r!==this&&r.parent!==this&&(this._children.push(r),this._doAdd(r)),this},t.prototype.addBefore=function(r,n){if(r&&r!==this&&r.parent!==this&&n&&n.parent===this){var i=this._children,a=i.indexOf(n);a>=0&&(i.splice(a,0,r),this._doAdd(r))}return this},t.prototype.replace=function(r,n){var i=vt(this._children,r);return i>=0&&this.replaceAt(n,i),this},t.prototype.replaceAt=function(r,n){var i=this._children,a=i[n];if(r&&r!==this&&r.parent!==this&&r!==a){i[n]=r,a.parent=null;var o=this.__zr;o&&a.removeSelfFromZr(o),this._doAdd(r)}return this},t.prototype._doAdd=function(r){r.parent&&r.parent.remove(r),r.parent=this;var n=this.__zr;n&&n!==r.__zr&&r.addSelfToZr(n),n&&n.refresh()},t.prototype.remove=function(r){var n=this.__zr,i=this._children,a=vt(i,r);return a<0?this:(i.splice(a,1),r.parent=null,n&&r.removeSelfFromZr(n),n&&n.refresh(),this)},t.prototype.removeAll=function(){for(var r=this._children,n=this.__zr,i=0;i<r.length;i++){var a=r[i];n&&a.removeSelfFromZr(n),a.parent=null}return r.length=0,this},t.prototype.eachChild=function(r,n){for(var i=this._children,a=0;a<i.length;a++){var o=i[a];r.call(n,o,a)}return this},t.prototype.traverse=function(r,n){for(var i=0;i<this._children.length;i++){var a=this._children[i],o=r.call(n,a);a.isGroup&&!o&&a.traverse(r,n)}return this},t.prototype.addSelfToZr=function(r){e.prototype.addSelfToZr.call(this,r);for(var n=0;n<this._children.length;n++){var i=this._children[n];i.addSelfToZr(r)}},t.prototype.removeSelfFromZr=function(r){e.prototype.removeSelfFromZr.call(this,r);for(var n=0;n<this._children.length;n++){var i=this._children[n];i.removeSelfFromZr(r)}},t.prototype.getBoundingRect=function(r){for(var n=new it(0,0,0,0),i=r||this._children,a=[],o=null,s=0;s<i.length;s++){var l=i[s];if(!(l.ignore||l.invisible)){var u=l.getBoundingRect(),f=l.getLocalTransform(a);f?(it.applyTransform(n,u,f),o=o||n.clone(),o.union(n)):(o=o||u.clone(),o.union(u))}}return o||n},t})(Js);Vt.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
|
|
23
|
+
*/var qo={},om={};function zS(e){delete om[e]}function HS(e){if(!e)return!1;if(typeof e=="string")return gs(e,1)<hf;if(e.colorStops){for(var t=e.colorStops,r=0,n=t.length,i=0;i<n;i++)r+=gs(t[i].color,1);return r/=n,r<hf}return!1}var VS=(function(){function e(t,r,n){var i=this;this._sleepAfterStill=10,this._stillFrameAccum=0,this._needsRefresh=!0,this._needsRefreshHover=!1,this._darkMode=!1,n=n||{},this.dom=r,this.id=t;var a=new iS,o=n.renderer||"canvas";qo[o]||(o=xt(qo)[0]),n.useDirtyRect=n.useDirtyRect==null?!1:n.useDirtyRect;var s=new qo[o](r,a,n,t),l=n.ssr||s.ssrOnly;this.storage=a,this.painter=s;var u=!st.node&&!st.worker&&!l?new LS(s.getViewportRoot(),s.root):null,f=n.useCoarsePointer,h=f==null||f==="auto"?st.touchEventsSupported:!!f,v=44,c;h&&(c=j(n.pointerSize,v)),this.handler=new Ug(a,s,u,s.root,c),this.animation=new TS({stage:{update:l?null:function(){return i._flush(!1)}}}),l||this.animation.start()}return e.prototype.add=function(t){this._disposed||!t||(this.storage.addRoot(t),t.addSelfToZr(this),this.refresh())},e.prototype.remove=function(t){this._disposed||!t||(this.storage.delRoot(t),t.removeSelfFromZr(this),this.refresh())},e.prototype.configLayer=function(t,r){this._disposed||(this.painter.configLayer&&this.painter.configLayer(t,r),this.refresh())},e.prototype.setBackgroundColor=function(t){this._disposed||(this.painter.setBackgroundColor&&this.painter.setBackgroundColor(t),this.refresh(),this._backgroundColor=t,this._darkMode=HS(t))},e.prototype.getBackgroundColor=function(){return this._backgroundColor},e.prototype.setDarkMode=function(t){this._darkMode=t},e.prototype.isDarkMode=function(){return this._darkMode},e.prototype.refreshImmediately=function(t){this._disposed||this._refresh({animUpdate:!t,refresh:!0,refreshHover:!1})},e.prototype._refresh=function(t){t.animUpdate&&this.animation.update(!0),this._needsRefresh=this._needsRefreshHover=!1,this.painter.refresh({refresh:t.refresh,refreshHover:t.refreshHover}),this._needsRefresh=this._needsRefreshHover=!1},e.prototype.refresh=function(){this._disposed||(this._needsRefresh=!0,this.animation.start())},e.prototype.flush=function(){this._disposed||this._flush(!0)},e.prototype._flush=function(t){var r,n=ei(),i=this._needsRefresh,a=this._needsRefreshHover;(i||a)&&(r=!0,this._refresh({animUpdate:t,refresh:i,refreshHover:a}));var o=ei();r?(this._stillFrameAccum=0,this.trigger("rendered",{elapsedTime:o-n})):this._sleepAfterStill>0&&(this._stillFrameAccum++,this._stillFrameAccum>this._sleepAfterStill&&this.animation.stop())},e.prototype.setSleepAfterStill=function(t){this._sleepAfterStill=t},e.prototype.wakeUp=function(){this._disposed||(this.animation.start(),this._stillFrameAccum=0)},e.prototype.refreshHover=function(){this._needsRefreshHover=!0},e.prototype.refreshHoverImmediately=function(){this._disposed||this._refresh({animUpdate:!1,refresh:!1,refreshHover:!0})},e.prototype.resize=function(t){this._disposed||(t=t||{},this.painter.resize(t.width,t.height),this.handler.resize())},e.prototype.clearAnimation=function(){this._disposed||this.animation.clear()},e.prototype.getWidth=function(){if(!this._disposed)return this.painter.getWidth()},e.prototype.getHeight=function(){if(!this._disposed)return this.painter.getHeight()},e.prototype.setCursorStyle=function(t){this._disposed||this.handler.setCursorStyle(t)},e.prototype.findHover=function(t,r){if(!this._disposed)return this.handler.findHover(t,r)},e.prototype.on=function(t,r,n){return this._disposed||this.handler.on(t,r,n),this},e.prototype.off=function(t,r){this._disposed||this.handler.off(t,r)},e.prototype.trigger=function(t,r){this._disposed||this.handler.trigger(t,r)},e.prototype.clear=function(){if(!this._disposed){for(var t=this.storage.getRoots(),r=0;r<t.length;r++)t[r]instanceof Vt&&t[r].removeSelfFromZr(this);this.storage.delAllRoots(),this.painter.clear()}},e.prototype.dispose=function(){this._disposed||(this.animation.stop(),this.clear(),this.storage.dispose(),this.painter.dispose(),this.handler.dispose(),this.animation=this.storage=this.painter=this.handler=null,this._disposed=!0,zS(this.id))},e})();function pc(e,t){var r=new VS(Og(),e,t);return om[r.id]=r,r}function GS(e,t){qo[e]=t}var gc=1e-4,sm=20;function US(e){return e.replace(/^\s+|\s+$/g,"")}var he=Math.min,mt=Math.max,Nt=Math.abs,gr=Math.round,pi=Math.floor,Fa=Math.ceil,Ci=Math.pow,ma=Math.log,df=Math.LN10,WS=Math.PI,YS=Math.random;function mc(e,t,r,n){var i=t[0],a=t[1],o=r[0],s=r[1],l=a-i,u=s-o;if(l===0)return u===0?o:(o+s)/2;if(n)if(l>0){if(e<=i)return o;if(e>=a)return s}else{if(e>=i)return o;if(e<=a)return s}else{if(e===i)return o;if(e===a)return s}return(e-i)/l*u+o}var Ye=XS;function XS(e,t,r){switch(e){case"center":case"middle":e="50%";break;case"left":case"top":e="0%";break;case"right":case"bottom":e="100%";break}return pf(e,t,r)}function pf(e,t,r){return W(e)?$S(e)?parseFloat(e)/100*t+(r||0):parseFloat(e):e==null?NaN:+e}function $S(e){return!!US(e).match(/%$/)}function ft(e,t,r){return isNaN(t)?r?""+e:+e:(t=he(mt(0,t),sm),e=(+e).toFixed(t),r?e:+e)}function lm(e){return e.sort(function(t,r){return t-r}),e}function Pr(e){if(e=+e,isNaN(e))return 0;if(e>1e-14){for(var t=1,r=0;r<15;r++,t*=10)if(gr(e*t)/t===e)return r}return ZS(e)}function ZS(e){var t=e.toString().toLowerCase(),r=t.indexOf("e"),n=r>0?+t.slice(r+1):0,i=r>0?r:t.length,a=t.indexOf("."),o=a<0?0:i-1-a;return mt(0,o-n)}function qS(e,t,r){var n=Nt(e[1]-e[0]);if(!isFinite(n)||n===0)return NaN;var i=ma(2*Nt(r||1)*Nt(n))/df,a=ma(Nt(t))/df,o=mt(0,Fa(-i+a));return isFinite(o)||(o=NaN),o}function KS(e,t){var r=mt(Pr(e),Pr(t)),n=e+t;return r>sm?n:ft(n,r)}var yc=Ci(2,53)-1;function um(e){var t=WS*2;return(e%t+t)%t}function _s(e){return e>-gc&&e<gc}var QS=/^(?:(\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 Di(e){if(e instanceof Date)return e;if(W(e)){var t=QS.exec(e);if(!t)return new Date(NaN);if(t[8]){var r=+t[4]||0;return t[8].toUpperCase()!=="Z"&&(r-=+t[8].slice(0,3)),new Date(Date.UTC(+t[1],+(t[2]||1)-1,+t[3]||1,r,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0))}else return new Date(+t[1],+(t[2]||1)-1,+t[3]||1,+t[4]||0,+(t[5]||0),+t[6]||0,t[7]?+t[7].substring(0,3):0)}else if(e==null)return new Date(NaN);return new Date(gr(e))}function fm(e){return Ci(10,_h(e))}function _h(e){if(e===0)return 0;var t=pi(ma(e)/df);return e/Ci(10,t)>=10&&t++,t}var hm=2;function Sh(e,t){var r=_h(e),n=Ci(10,r),i=e/n,a;return t===hm?a=1:t?i<1.5?a=1:i<2.5?a=2:i<4?a=3:i<7?a=5:a=10:i<1?a=1:i<2?a=2:i<3?a=3:i<5?a=5:a=10,e=a*n,ft(e,-r)}function Ss(e){var t=parseFloat(e);return t==e&&(t!==0||!W(e)||e.indexOf("x")<=0)?t:NaN}function JS(e){return!isNaN(Ss(e))}function vm(){return gr(YS()*9)}function cm(e,t){return t===0?e:cm(t,e%t)}function _c(e,t){return e==null?t:t==null?e:e*t/cm(e,t)}function rr(e){return e!=null&&isFinite(e)}var jS="[ECharts] ",tb=typeof console<"u"&&console.warn&&console.log;function eb(e,t,r){tb&&console[e](jS+t)}function dm(e,t){eb("error",e)}function re(e){throw new Error(e)}function Sc(e,t,r){return(t-e)*r+e}var pm="series\0",rb="\0_ec_\0";function Jt(e){return e instanceof Array?e:e==null?[]:[e]}function bc(e,t,r){if(e){e[t]=e[t]||{},e.emphasis=e.emphasis||{},e.emphasis[t]=e.emphasis[t]||{};for(var n=0,i=r.length;n<i;n++){var a=r[n];!e.emphasis[t].hasOwnProperty(a)&&e[t].hasOwnProperty(a)&&(e.emphasis[t][a]=e[t][a])}}}var Tc=["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 za(e){return K(e)&&!H(e)&&!(e instanceof Date)?e.value:e}function nb(e){return K(e)&&!(e instanceof Array)}function ib(e,t,r){var n=r==="normalMerge",i=r==="replaceMerge",a=r==="replaceAll";e=e||[],t=(t||[]).slice();var o=nt();D(t,function(l,u){if(!K(l)){t[u]=null;return}});var s=ab(e,o,r);return(n||i)&&ob(s,e,o,t),n&&sb(s,t),n||i?lb(s,t,i):a&&ub(s,t),fb(s),s}function ab(e,t,r){var n=[];if(r==="replaceAll")return n;for(var i=0;i<e.length;i++){var a=e[i];a&&a.id!=null&&t.set(a.id,i),n.push({existing:r==="replaceMerge"||ya(a)?null:a,newOption:null,keyInfo:null,brandNew:null})}return n}function ob(e,t,r,n){D(n,function(i,a){if(!(!i||i.id==null)){var o=aa(i.id),s=r.get(o);if(s!=null){var l=e[s];pr(!l.newOption,'Duplicated option on id "'+o+'".'),l.newOption=i,l.existing=t[s],n[a]=null}}})}function sb(e,t){D(t,function(r,n){if(!(!r||r.name==null))for(var i=0;i<e.length;i++){var a=e[i].existing;if(!e[i].newOption&&a&&(a.id==null||r.id==null)&&!ya(r)&&!ya(a)&&gm("name",a,r)){e[i].newOption=r,t[n]=null;return}}})}function lb(e,t,r){D(t,function(n){if(n){for(var i,a=0;(i=e[a])&&(i.newOption||ya(i.existing)||i.existing&&n.id!=null&&!gm("id",n,i.existing));)a++;i?(i.newOption=n,i.brandNew=r):e.push({newOption:n,brandNew:r,existing:null,keyInfo:null}),a++}})}function ub(e,t){D(t,function(r){e.push({newOption:r,brandNew:!0,existing:null,keyInfo:null})})}function fb(e){var t=nt();D(e,function(r){var n=r.existing;n&&t.set(n.id,r)}),D(e,function(r){var n=r.newOption;pr(!n||n.id==null||!t.get(n.id)||t.get(n.id)===r,"id duplicates: "+(n&&n.id)),n&&n.id!=null&&t.set(n.id,r),!r.keyInfo&&(r.keyInfo={})}),D(e,function(r,n){var i=r.existing,a=r.newOption,o=r.keyInfo;if(K(a)){if(o.name=a.name!=null?aa(a.name):i?i.name:pm+n,i)o.id=aa(i.id);else if(a.id!=null)o.id=aa(a.id);else{var s=0;do o.id="\0"+o.name+"\0"+s++;while(t.get(o.id))}t.set(o.id,r)}})}function gm(e,t,r){var n=je(t[e],null),i=je(r[e],null);return n!=null&&i!=null&&n===i}function aa(e){return je(e,"")}function je(e,t){return e==null?t:W(e)?e:Ct(e)||Xu(e)?e+"":t}function bh(e){var t=e.name;return!!(t&&t.indexOf(pm))}function ya(e){return e&&e.id!=null&&aa(e.id).indexOf(rb)===0}function hb(e,t,r){D(e,function(n){var i=n.newOption;K(i)&&(n.keyInfo.mainType=t,n.keyInfo.subType=vb(t,i,n.existing,r))})}function vb(e,t,r,n){var i=t.type?t.type:r?r.subType:n.determineSubType(e,t);return i}function An(e,t){if(t.dataIndexInside!=null)return t.dataIndexInside;if(t.dataIndex!=null)return H(t.dataIndex)?rt(t.dataIndex,function(r){return e.indexOfRawIndex(r)}):e.indexOfRawIndex(t.dataIndex);if(t.name!=null)return H(t.name)?rt(t.name,function(r){return e.indexOfName(r)}):e.indexOfName(t.name)}function bt(){var e="__ec_inner_"+cb++;return function(t){return t[e]||(t[e]={})}}var cb=vm();function Zl(e,t,r){var n=Th(t,r),i=n.mainTypeSpecified,a=n.queryOptionMap,o=n.others,s=o,l=r?r.defaultMainType:null;return!i&&l&&a.set(l,{}),a.each(function(u,f){var h=Ha(e,f,u,{useDefault:l===f,enableAll:r&&r.enableAll!=null?r.enableAll:!0,enableNone:r&&r.enableNone!=null?r.enableNone:!0});s[f+"Models"]=h.models,s[f+"Model"]=h.models[0]}),s}function Th(e,t){var r;if(W(e)){var n={};n[e+"Index"]=0,r=n}else r=e;var i=nt(),a={},o=!1;return D(r,function(s,l){if(l==="dataIndex"||l==="dataIndexInside"){a[l]=s;return}var u=l.match(/^(\w+)(Index|Id|Name)$/)||[],f=u[1],h=(u[2]||"").toLowerCase();if(!(!f||!h||t&&t.includeMainTypes&&vt(t.includeMainTypes,f)<0)){o=o||!!f;var v=i.get(f)||i.set(f,{});v[h]=s}}),{mainTypeSpecified:o,queryOptionMap:i,others:a}}var Ce={useDefault:!0,enableAll:!1,enableNone:!1};function Ha(e,t,r,n){n=n||Ce;var i=r.index,a=r.id,o=r.name,s={models:null,specified:i!=null||a!=null||o!=null};if(!s.specified){var l=void 0;return s.models=n.useDefault&&(l=e.getComponent(t))?[l]:[],s}if(i==="none"||i===!1){if(n.enableNone)return s.models=[],s;i=-1}return i==="all"&&(n.enableAll?i=a=o=null:i=-1),s.models=e.queryComponents({mainType:t,index:i,id:a,name:o}),s}function db(e,t,r){var n={};n[t+"Id"]=e[t+"Id"],n[t+"Index"]=e[t+"Index"],n[t+"Name"]=e[t+"Name"];var i={mainType:t,query:n};return r&&(i.subType=r),i}function mm(e,t,r){e.setAttribute?e.setAttribute(t,r):e[t]=r}function pb(e,t){return e.getAttribute?e.getAttribute(t):e[t]}function gb(e){return e==="auto"?st.domSupported?"html":"richText":e||"html"}function mb(e,t,r,n,i){var a=t==null||t==="auto";if(n==null)return n;if(Ct(n)){var o=Sc(r||0,n,i);return ft(o,a?Math.max(Pr(r||0),Pr(n)):t)}else{if(W(n))return i<1?r:n;for(var s=[],l=r,u=n,f=Math.max(l?l.length:0,u.length),h=0;h<f;++h){var v=e.getDimensionInfo(h);if(v&&v.type==="ordinal")s[h]=(i<1&&l?l:u)[h];else{var c=l&&l[h]?l[h]:0,d=u[h],o=Sc(c,d,i);s[h]=ft(o,a?Math.max(Pr(c),Pr(d)):t)}}return s}}function Te(){return[1/0,-1/0]}function gf(e,t){mr(t)&&(t<e[0]&&(e[0]=t),t>e[1]&&(e[1]=t))}function ym(e,t){mr(t)&&t<e[0]&&(e[0]=t)}function _m(e,t){mr(t)&&t>e[1]&&(e[1]=t)}function yb(e,t){gi(t[0],t[1])&&(t[0]<e[0]&&(e[0]=t[0]),t[1]>e[1]&&(e[1]=t[1]))}function mr(e){return e!=null&&isFinite(e)}function gi(e,t){return mr(e)&&mr(t)&&e<=t}function _b(e){var t=e[1]-e[0];return isFinite(t)&&t>=0}function Sb(e){gi(e[0],e[1])&&e[0]>e[1]&&(e[0]=e[1])}function wh(e,t,r){var n=nt(),i=0;D(e,function(a){var o=t(a),s=n.get(o)||0;r&&r(a,s),!s&&!r&&(e[i++]=a),n.set(o,s+1)}),r||(e.length=i)}function bb(e){return e.value+""}function Tb(e){return e+""}function wb(e,t,r){var n=e.getData().count();return{progressiveRender:r.progressiveEnabled&&t.incrementalPrepareRender&&n>=r.threshold,large:e.get("large")&&n>=e.get("largeThreshold"),modDataCount:e.get("progressiveChunkMode")==="mod"?e.getData().count():null}}function xh(e){return{overallReset:e}}var xb=".",Jr="___EC__COMPONENT__CONTAINER___",Sm="___EC__EXTENDED_CLASS___";function Ze(e){var t={main:"",sub:""};if(e){var r=e.split(xb);t.main=r[0]||"",t.sub=r[1]||""}return t}function Cb(e){pr(/^[a-zA-Z0-9_]+([.][a-zA-Z0-9_]+)?$/.test(e),'componentType "'+e+'" illegal')}function Db(e){return!!(e&&e[Sm])}function Ch(e,t){e.$constructor=e,e.extend=function(r){var n=this,i;return Mb(n)?i=(function(a){V(o,a);function o(){return a.apply(this,arguments)||this}return o})(n):(i=function(){(r.$constructor||n).apply(this,arguments)},d1(i,this)),N(i.prototype,r),i[Sm]=!0,i.extend=this.extend,i.superCall=Ib,i.superApply=Pb,i.superClass=n,i}}function Mb(e){return ot(e)&&/^class\s/.test(Function.prototype.toString.call(e))}function bm(e,t){e.extend=t.extend}var Ab=Math.round(Math.random()*10);function Lb(e){var t=["__\0is_clz",Ab++].join("_");e.prototype[t]=!0,e.isInstance=function(r){return!!(r&&r[t])}}function Ib(e,t){for(var r=[],n=2;n<arguments.length;n++)r[n-2]=arguments[n];return this.superClass.prototype[t].apply(e,r)}function Pb(e,t,r){return this.superClass.prototype[t].apply(e,r)}function js(e){var t={};e.registerClass=function(n){var i=n.type||n.prototype.type;if(i){Cb(i),n.prototype.type=i;var a=Ze(i);if(!a.sub)t[a.main]=n;else if(a.sub!==Jr){var o=r(a);o[a.sub]=n}}return n},e.getClass=function(n,i,a){var o=t[n];if(o&&o[Jr]&&(o=i?o[i]:null),a&&!o)throw new Error(i?"Component "+n+"."+(i||"")+" is used but not imported.":n+".type should be specified.");return o},e.getClassesByMainType=function(n){var i=Ze(n),a=[],o=t[i.main];return o&&o[Jr]?D(o,function(s,l){l!==Jr&&a.push(s)}):a.push(o),a},e.hasClass=function(n){var i=Ze(n);return!!t[i.main]},e.getAllClassMainTypes=function(){var n=[];return D(t,function(i,a){n.push(a)}),n},e.hasSubTypes=function(n){var i=Ze(n),a=t[i.main];return a&&a[Jr]};function r(n){var i=t[n.main];return(!i||!i[Jr])&&(i=t[n.main]={},i[Jr]=!0),i}}function _a(e,t){for(var r=0;r<e.length;r++)e[r][1]||(e[r][1]=e[r][0]);return t=t||!1,function(n,i,a){for(var o={},s=0;s<e.length;s++){var l=e[s][1];if(!(i&&vt(i,l)>=0||a&&vt(a,l)<0)){var u=n.getShallow(l,t);u!=null&&(o[e[s][0]]=u)}}return o}}var Eb=[["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]],Rb=_a(Eb),kb=(function(){function e(){}return e.prototype.getAreaStyle=function(t,r){return Rb(this,t,r)},e})(),mf=new vi(50);function Ob(e){if(typeof e=="string"){var t=mf.get(e);return t&&t.image}else return e}function Tm(e,t,r,n,i){if(e)if(typeof e=="string"){if(t&&t.__zrImageSrc===e||!r)return t;var a=mf.get(e),o={hostEl:r,cb:n,cbPayload:i};return a?(t=a.image,!tl(t)&&a.pending.push(o)):(t=ue.loadImage(e,wc,wc),t.__zrImageSrc=e,mf.put(e,t.__cachedImgObj={image:t,pending:[o]})),t}else return e;else return t}function wc(){var e=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var t=0;t<e.pending.length;t++){var r=e.pending[t],n=r.cb;n&&n(this,r.cbPayload),r.hostEl.dirty()}e.pending.length=0}function tl(e){return e&&e.width&&e.height}var ql=/\{([a-zA-Z0-9_]+)\|([^}]*)\}/g;function Bb(e,t,r,n,i,a){if(!r){e.text="",e.isTruncated=!1;return}var o=(t+"").split(`
|
|
24
|
+
`);a=wm(r,n,i,a);for(var s=!1,l={},u=0,f=o.length;u<f;u++)xm(l,o[u],a),o[u]=l.textLine,s=s||l.isTruncated;e.text=o.join(`
|
|
25
|
+
`),e.isTruncated=s}function wm(e,t,r,n){n=n||{};var i=N({},n);r=j(r,"..."),i.maxIterations=j(n.maxIterations,2);var a=i.minChar=j(n.minChar,0),o=i.fontMeasureInfo=Qe(t),s=o.asciiCharWidth;i.placeholder=j(n.placeholder,"");for(var l=e=Math.max(0,e-1),u=0;u<a&&l>=s;u++)l-=s;var f=Je(o,r);return f>l&&(r="",f=0),l=e-f,i.ellipsis=r,i.ellipsisWidth=f,i.contentWidth=l,i.containerWidth=e,i}function xm(e,t,r){var n=r.containerWidth,i=r.contentWidth,a=r.fontMeasureInfo;if(!n){e.textLine="",e.isTruncated=!1;return}var o=Je(a,t);if(o<=n){e.textLine=t,e.isTruncated=!1;return}for(var s=0;;s++){if(o<=i||s>=r.maxIterations){t+=r.ellipsis;break}var l=s===0?Nb(t,i,a):o>0?Math.floor(t.length*i/o):0;t=t.substr(0,l),o=Je(a,t)}t===""&&(t=r.placeholder),e.textLine=t,e.isTruncated=!0}function Nb(e,t,r){for(var n=0,i=0,a=e.length;i<a&&n<t;i++)n+=rm(r,e.charCodeAt(i));return i}function Fb(e,t,r,n){var i=Dh(e),a=t.overflow,o=t.padding,s=o?o[1]+o[3]:0,l=o?o[0]+o[2]:0,u=t.font,f=a==="truncate",h=Ks(u),v=j(t.lineHeight,h),c=t.lineOverflow==="truncate",d=!1,p=t.width;p==null&&r!=null&&(p=r-s);var m=t.height;m==null&&n!=null&&(m=n-l);var g;p!=null&&(a==="break"||a==="breakAll")?g=i?Cm(i,t.font,p,a==="breakAll",0).lines:[]:g=i?i.split(`
|
|
26
|
+
`):[];var y=g.length*v;if(m==null&&(m=y),y>m&&c){var _=Math.floor(m/v);d=d||g.length>_,g=g.slice(0,_),y=g.length*v}if(i&&f&&p!=null)for(var S=wm(p,u,t.ellipsis,{minChar:t.truncateMinChar,placeholder:t.placeholder}),b={},T=0;T<g.length;T++)xm(b,g[T],S),g[T]=b.textLine,d=d||b.isTruncated;for(var w=m,M=0,C=Qe(u),T=0;T<g.length;T++)M=Math.max(Je(C,g[T]),M);p==null&&(p=M);var x=p;return w+=l,x+=s,{lines:g,height:m,outerWidth:x,outerHeight:w,lineHeight:v,calculatedLineHeight:h,contentWidth:M,contentHeight:y,width:p,isTruncated:d}}var zb=(function(){function e(){}return e})(),xc=(function(){function e(t){this.tokens=[],t&&(this.tokens=t)}return e})(),Hb=(function(){function e(){this.width=0,this.height=0,this.contentWidth=0,this.contentHeight=0,this.outerWidth=0,this.outerHeight=0,this.lines=[],this.isTruncated=!1}return e})();function Vb(e,t,r,n,i){var a=new Hb,o=Dh(e);if(!o)return a;var s=t.padding,l=s?s[1]+s[3]:0,u=s?s[0]+s[2]:0,f=t.width;f==null&&r!=null&&(f=r-l);var h=t.height;h==null&&n!=null&&(h=n-u);for(var v=t.overflow,c=(v==="break"||v==="breakAll")&&f!=null?{width:f,accumWidth:0,breakAll:v==="breakAll"}:null,d=ql.lastIndex=0,p;(p=ql.exec(o))!=null;){var m=p.index;m>d&&Kl(a,o.substring(d,m),t,c),Kl(a,p[2],t,c,p[1]),d=ql.lastIndex}d<o.length&&Kl(a,o.substring(d,o.length),t,c);var g=[],y=0,_=0,S=v==="truncate",b=t.lineOverflow==="truncate",T={};function w(k,B,Q){k.width=B,k.lineHeight=Q,y+=Q,_=Math.max(_,B)}t:for(var M=0;M<a.lines.length;M++){for(var C=a.lines[M],x=0,A=0,I=0;I<C.tokens.length;I++){var L=C.tokens[I],P=L.styleName&&t.rich[L.styleName]||{},R=L.textPadding=P.padding,E=R?R[1]+R[3]:0,F=L.font=P.font||t.font;L.contentHeight=Ks(F);var G=j(P.height,L.contentHeight);if(L.innerHeight=G,R&&(G+=R[0]+R[2]),L.height=G,L.lineHeight=ai(P.lineHeight,t.lineHeight,G),L.align=P&&P.align||i,L.verticalAlign=P&&P.verticalAlign||"middle",b&&h!=null&&y+L.lineHeight>h){var U=a.lines.length;I>0?(C.tokens=C.tokens.slice(0,I),w(C,A,x),a.lines=a.lines.slice(0,M+1)):a.lines=a.lines.slice(0,M),a.isTruncated=a.isTruncated||a.lines.length<U;break t}var tt=P.width,Z=tt==null||tt==="auto";if(typeof tt=="string"&&tt.charAt(tt.length-1)==="%")L.percentWidth=tt,g.push(L),L.contentWidth=Je(Qe(F),L.text);else{if(Z){var at=P.backgroundColor,q=at&&at.image;q&&(q=Ob(q),tl(q)&&(L.width=Math.max(L.width,q.width*G/q.height)))}var z=S&&f!=null?f-A:null;z!=null&&z<L.width?!Z||z<E?(L.text="",L.width=L.contentWidth=0):(Bb(T,L.text,z-E,F,t.ellipsis,{minChar:t.truncateMinChar}),L.text=T.text,a.isTruncated=a.isTruncated||T.isTruncated,L.width=L.contentWidth=Je(Qe(F),L.text)):L.contentWidth=Je(Qe(F),L.text)}L.width+=E,A+=L.width,P&&(x=Math.max(x,L.lineHeight))}w(C,A,x)}a.outerWidth=a.width=j(f,_),a.outerHeight=a.height=j(h,y),a.contentHeight=y,a.contentWidth=_,a.outerWidth+=l,a.outerHeight+=u;for(var M=0;M<g.length;M++){var L=g[M],lt=L.percentWidth;L.width=parseInt(lt,10)/100*a.width}return a}function Kl(e,t,r,n,i){var a=t==="",o=i&&r.rich[i]||{},s=e.lines,l=o.font||r.font,u=!1,f,h;if(n){var v=o.padding,c=v?v[1]+v[3]:0;if(o.width!=null&&o.width!=="auto"){var d=di(o.width,n.width)+c;s.length>0&&d+n.accumWidth>n.width&&(f=t.split(`
|
|
27
|
+
`),u=!0),n.accumWidth=d}else{var p=Cm(t,l,n.width,n.breakAll,n.accumWidth);n.accumWidth=p.accumWidth+c,h=p.linesWidths,f=p.lines}}f||(f=t.split(`
|
|
28
|
+
`));for(var m=Qe(l),g=0;g<f.length;g++){var y=f[g],_=new zb;if(_.styleName=i,_.text=y,_.isLineHolder=!y&&!a,typeof o.width=="number"?_.width=o.width:_.width=h?h[g]:Je(m,y),!g&&!u){var S=(s[s.length-1]||(s[0]=new xc)).tokens,b=S.length;b===1&&S[0].isLineHolder?S[0]=_:(y||!b||a)&&S.push(_)}else s.push(new xc([_]))}}function Gb(e){var t=e.charCodeAt(0);return t>=32&&t<=591||t>=880&&t<=4351||t>=4608&&t<=5119||t>=7680&&t<=8303}var Ub=wi(",&?/;] ".split(""),function(e,t){return e[t]=!0,e},{});function Wb(e){return Gb(e)?!!Ub[e]:!0}function Cm(e,t,r,n,i){for(var a=[],o=[],s="",l="",u=0,f=0,h=Qe(t),v=0;v<e.length;v++){var c=e.charAt(v);if(c===`
|
|
29
|
+
`){l&&(s+=l,f+=u),a.push(s),o.push(f),s="",l="",u=0,f=0;continue}var d=rm(h,c.charCodeAt(0)),p=n?!1:!Wb(c);if(a.length?f+d>r:i+f+d>r){f?(s||l)&&(p?(s||(s=l,l="",u=0,f=u),a.push(s),o.push(f-u),l+=c,u+=d,s="",f=u):(l&&(s+=l,l="",u=0),a.push(s),o.push(f),s=c,f=d)):p?(a.push(l),o.push(u),l=c,u=d):(a.push(c),o.push(d));continue}f+=d,p?(l+=c,u+=d):(l&&(s+=l,l="",u=0),s+=c)}return l&&(s+=l),s&&(a.push(s),o.push(f)),a.length===1&&(f+=i),{accumWidth:f,lines:a,linesWidths:o}}function Cc(e,t,r,n,i,a){if(e.baseX=r,e.baseY=n,e.outerWidth=e.outerHeight=null,!!t){var o=t.width*2,s=t.height*2;it.set(Dc,ci(r,o,i),xn(n,s,a),o,s),it.intersect(t,Dc,null,Mc);var l=Mc.outIntersectRect;e.outerWidth=l.width,e.outerHeight=l.height,e.baseX=ci(l.x,l.width,i,!0),e.baseY=xn(l.y,l.height,a,!0)}}var Dc=new it(0,0,0,0),Mc={outIntersectRect:{},clamp:!0};function Dh(e){return e!=null?e+="":e=""}function Yb(e){var t=Dh(e.text),r=e.font,n=Je(Qe(r),t),i=Ks(r);return yf(e,n,i,null)}function yf(e,t,r,n){var i=new it(ci(e.x||0,t,e.textAlign),xn(e.y||0,r,e.textBaseline),t,r),a=n??(Dm(e)?e.lineWidth:0);return a>0&&(i.x-=a/2,i.y-=a/2,i.width+=a,i.height+=a),i}function Dm(e){var t=e.stroke;return t!=null&&t!=="none"&&e.lineWidth>0}var _f="__zr_style_"+Math.round(Math.random()*10),Cn={shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"#000",opacity:1,blend:"source-over"},el={style:{shadowBlur:!0,shadowOffsetX:!0,shadowOffsetY:!0,shadowColor:!0,opacity:!0}};Cn[_f]=!0;var Ac=["z","z2","invisible"],Xb=["invisible"],Va=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype._init=function(r){for(var n=xt(r),i=0;i<n.length;i++){var a=n[i];a==="style"?this.useStyle(r[a]):e.prototype.attrKV.call(this,a,r[a])}this.style||this.useStyle({})},t.prototype.beforeBrush=function(r){},t.prototype.afterBrush=function(){},t.prototype.innerBeforeBrush=function(){},t.prototype.innerAfterBrush=function(){},t.prototype.shouldBePainted=function(r,n,i,a){var o=this.transform;if(this.ignore||this.invisible||this.style.opacity===0||this.culling&&$b(this,r,n)||o&&!o[0]&&!o[3])return!1;if(i&&this.__clipPaths&&this.__clipPaths.length){for(var s=0;s<this.__clipPaths.length;++s)if(this.__clipPaths[s].isZeroArea())return!1}if(a&&this.parent)for(var l=this.parent;l;){if(l.ignore)return!1;l=l.parent}return!0},t.prototype.contain=function(r,n){return this.rectContain(r,n)},t.prototype.traverse=function(r,n){r.call(n,this)},t.prototype.rectContain=function(r,n){var i=this.transformCoordToLocal(r,n),a=this.getBoundingRect();return a.contain(i[0],i[1])},t.prototype.getPaintRect=function(){var r=this._paintRect;if(!this._paintRect||this.__dirty){var n=this.transform,i=this.getBoundingRect(),a=this.style,o=a.shadowBlur||0,s=a.shadowOffsetX||0,l=a.shadowOffsetY||0;r=this._paintRect||(this._paintRect=new it(0,0,0,0)),n?it.applyTransform(r,i,n):r.copy(i),(o||s||l)&&(r.width+=o*2+Math.abs(s),r.height+=o*2+Math.abs(l),r.x=Math.min(r.x,r.x+s-o),r.y=Math.min(r.y,r.y+l-o));var u=this.dirtyRectTolerance;r.isZero()||(r.x=Math.floor(r.x-u),r.y=Math.floor(r.y-u),r.width=Math.ceil(r.width+1+u*2),r.height=Math.ceil(r.height+1+u*2))}return r},t.prototype.setPrevPaintRect=function(r){r?(this._prevPaintRect=this._prevPaintRect||new it(0,0,0,0),this._prevPaintRect.copy(r)):this._prevPaintRect=null},t.prototype.getPrevPaintRect=function(){return this._prevPaintRect},t.prototype.animateStyle=function(r){return this.animate("style",r)},t.prototype.updateDuringAnimation=function(r){r==="style"?this.dirtyStyle():this.markRedraw()},t.prototype.attrKV=function(r,n){r!=="style"?e.prototype.attrKV.call(this,r,n):this.style?this.setStyle(n):this.useStyle(n)},t.prototype.setStyle=function(r,n){return typeof r=="string"?this.style[r]=n:N(this.style,r),this.dirtyStyle(),this},t.prototype.dirtyStyle=function(r){r||this.markRedraw(),this.__dirty|=qi,this._rect&&(this._rect=null)},t.prototype.dirty=function(){this.dirtyStyle()},t.prototype.styleChanged=function(){return!!(this.__dirty&qi)},t.prototype.styleUpdated=function(){this.__dirty&=~qi},t.prototype.createStyle=function(r){return Zs(Cn,r)},t.prototype.useStyle=function(r){r[_f]||(r=this.createStyle(r)),this.style=r,this.dirtyStyle()},t.prototype._useHoverStyle=function(r){this.__hoverStyle=r},t.prototype.isStyleObject=function(r){return r[_f]},t.prototype._innerSaveToNormal=function(r){e.prototype._innerSaveToNormal.call(this,r);var n=this._normalState;r.style&&!n.style&&(n.style=this._mergeStyle(this.createStyle(),this.style)),this._savePrimaryToNormal(r,n,Ac)},t.prototype._applyStateObj=function(r,n,i,a,o,s){e.prototype._applyStateObj.call(this,r,n,i,a,o,s);var l=!(n&&a),u=this.__inHover===Qs,f;if(n&&n.style?o?a?f=n.style:(f=this._mergeStyle(this.createStyle(),i.style),this._mergeStyle(f,n.style)):(f=this._mergeStyle(this.createStyle(),a?this.style:i.style),this._mergeStyle(f,n.style)):l&&(f=i.style),f)if(o){var h=this.style;if(this.style=this.createStyle(l?{}:h),l)for(var v=xt(h),c=0;c<v.length;c++){var d=v[c];d in f&&(f[d]=f[d],this.style[d]=h[d])}for(var p=xt(f),c=0;c<p.length;c++){var d=p[c];this.style[d]=this.style[d]}this._transitionState(r,{style:f},s,this.getAnimationStyleProps())}else u?this._useHoverStyle(f):this.useStyle(f);if(!u)for(var m=this.__inHover?Xb:Ac,c=0;c<m.length;c++){var d=m[c];n&&n[d]!=null?this[d]=n[d]:l&&i[d]!=null&&(this[d]=i[d])}},t.prototype._mergeStates=function(r){for(var n=e.prototype._mergeStates.call(this,r),i,a=0;a<r.length;a++){var o=r[a];o.style&&(i=i||{},this._mergeStyle(i,o.style))}return i&&(n.style=i),n},t.prototype._mergeStyle=function(r,n){return N(r,n),r},t.prototype.getAnimationStyleProps=function(){return el},t.initDefaultProps=(function(){var r=t.prototype;r.type="displayable",r.invisible=!1,r.z=0,r.z2=0,r.zlevel=0,r.culling=!1,r.cursor="pointer",r.rectHover=!1,r.incremental=0,r._rect=null,r.dirtyRectTolerance=0,r.__dirty=ne|qi})(),t})(Js),Ql=new it(0,0,0,0),Jl=new it(0,0,0,0);function $b(e,t,r){return Ql.copy(e.getBoundingRect()),e.transform&&Ql.applyTransform(e.transform),Jl.width=t,Jl.height=r,!Ql.intersect(Jl)}var we=Math.min,xe=Math.max,jl=Math.sin,tu=Math.cos,jr=Math.PI*2,lo=xi(),uo=xi(),fo=xi();function Lc(e,t,r,n,i,a){i[0]=we(e,r),i[1]=we(t,n),a[0]=xe(e,r),a[1]=xe(t,n)}var Ic=[],Pc=[];function Zb(e,t,r,n,i,a,o,s,l,u){var f=Zg,h=Ht,v=f(e,r,i,o,Ic);l[0]=1/0,l[1]=1/0,u[0]=-1/0,u[1]=-1/0;for(var c=0;c<v;c++){var d=h(e,r,i,o,Ic[c]);l[0]=we(d,l[0]),u[0]=xe(d,u[0])}v=f(t,n,a,s,Pc);for(var c=0;c<v;c++){var p=h(t,n,a,s,Pc[c]);l[1]=we(p,l[1]),u[1]=xe(p,u[1])}l[0]=we(e,l[0]),u[0]=xe(e,u[0]),l[0]=we(o,l[0]),u[0]=xe(o,u[0]),l[1]=we(t,l[1]),u[1]=xe(t,u[1]),l[1]=we(s,l[1]),u[1]=xe(s,u[1])}function qb(e,t,r,n,i,a,o,s){var l=qg,u=ee,f=xe(we(l(e,r,i),1),0),h=xe(we(l(t,n,a),1),0),v=u(e,r,i,f),c=u(t,n,a,h);o[0]=we(e,i,v),o[1]=we(t,a,c),s[0]=xe(e,i,v),s[1]=xe(t,a,c)}function Kb(e,t,r,n,i,a,o,s,l){var u=Jn,f=jn,h=Math.abs(i-a);if(h%jr<1e-4&&h>1e-4){s[0]=e-r,s[1]=t-n,l[0]=e+r,l[1]=t+n;return}if(lo[0]=tu(i)*r+e,lo[1]=jl(i)*n+t,uo[0]=tu(a)*r+e,uo[1]=jl(a)*n+t,u(s,lo,uo),f(l,lo,uo),i=i%jr,i<0&&(i=i+jr),a=a%jr,a<0&&(a=a+jr),i>a&&!o?a+=jr:i<a&&o&&(i+=jr),o){var v=a;a=i,i=v}for(var c=0;c<a;c+=Math.PI/2)c>i&&(fo[0]=tu(c)*r+e,fo[1]=jl(c)*n+t,u(s,fo,s),f(l,fo,l))}var ht={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},tn=[],en=[],He=[],Sr=[],Ve=[],Ge=[],eu=Math.min,ru=Math.max,rn=Math.cos,nn=Math.sin,ur=Math.abs,Sf=Math.PI,Ar=Sf*2,nu=typeof Float32Array<"u",Ei=[];function iu(e){var t=Math.round(e/Sf*1e8)/1e8;return t%2*Sf}function Qb(e,t){var r=iu(e[0]);r<0&&(r+=Ar);var n=r-e[0],i=e[1];i+=n,!t&&i-r>=Ar?i=r+Ar:t&&r-i>=Ar?i=r-Ar:!t&&r>i?i=r+(Ar-iu(r-i)):t&&r<i&&(i=r-(Ar-iu(i-r))),e[0]=r,e[1]=i}var Ln=(function(){function e(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 e.prototype.increaseVersion=function(){this._version++},e.prototype.getVersion=function(){return this._version},e.prototype.setScale=function(t,r,n){n=n||0,n>0&&(this._ux=ur(n/ms/t)||0,this._uy=ur(n/ms/r)||0)},e.prototype.setDPR=function(t){this.dpr=t},e.prototype.setContext=function(t){this._ctx=t},e.prototype.getContext=function(){return this._ctx},e.prototype.beginPath=function(){return this._ctx&&this._ctx.beginPath(),this.reset(),this},e.prototype.reset=function(){this._saveData&&(this._len=0),this._pathSegLen&&(this._pathSegLen=null,this._pathLen=0),this._version++},e.prototype.moveTo=function(t,r){return this._drawPendingPt(),this.addData(ht.M,t,r),this._ctx&&this._ctx.moveTo(t,r),this._x0=t,this._y0=r,this._xi=t,this._yi=r,this},e.prototype.lineTo=function(t,r){var n=ur(t-this._xi),i=ur(r-this._yi),a=n>this._ux||i>this._uy;if(this.addData(ht.L,t,r),this._ctx&&a&&this._ctx.lineTo(t,r),a)this._xi=t,this._yi=r,this._pendingPtDist=0;else{var o=n*n+i*i;o>this._pendingPtDist&&(this._pendingPtX=t,this._pendingPtY=r,this._pendingPtDist=o)}return this},e.prototype.bezierCurveTo=function(t,r,n,i,a,o){return this._drawPendingPt(),this.addData(ht.C,t,r,n,i,a,o),this._ctx&&this._ctx.bezierCurveTo(t,r,n,i,a,o),this._xi=a,this._yi=o,this},e.prototype.quadraticCurveTo=function(t,r,n,i){return this._drawPendingPt(),this.addData(ht.Q,t,r,n,i),this._ctx&&this._ctx.quadraticCurveTo(t,r,n,i),this._xi=n,this._yi=i,this},e.prototype.arc=function(t,r,n,i,a,o){this._drawPendingPt(),Ei[0]=i,Ei[1]=a,Qb(Ei,o),i=Ei[0],a=Ei[1];var s=a-i;return this.addData(ht.A,t,r,n,n,i,s,0,o?0:1),this._ctx&&this._ctx.arc(t,r,n,i,a,o),this._xi=rn(a)*n+t,this._yi=nn(a)*n+r,this},e.prototype.arcTo=function(t,r,n,i,a){return this._drawPendingPt(),this._ctx&&this._ctx.arcTo(t,r,n,i,a),this},e.prototype.rect=function(t,r,n,i){return this._drawPendingPt(),this._ctx&&this._ctx.rect(t,r,n,i),this.addData(ht.R,t,r,n,i),this},e.prototype.closePath=function(){this._drawPendingPt(),this.addData(ht.Z);var t=this._ctx,r=this._x0,n=this._y0;return t&&t.closePath(),this._xi=r,this._yi=n,this},e.prototype.fill=function(t){t&&t.fill(),this.toStatic()},e.prototype.stroke=function(t){t&&t.stroke(),this.toStatic()},e.prototype.len=function(){return this._len},e.prototype.setData=function(t){if(this._saveData){var r=t.length;!(this.data&&this.data.length===r)&&nu&&(this.data=new Float32Array(r));for(var n=0;n<r;n++)this.data[n]=t[n];this._len=r}},e.prototype.appendPath=function(t){if(this._saveData){t instanceof Array||(t=[t]);for(var r=t.length,n=0,i=this._len,a=0;a<r;a++)n+=t[a].len();var o=this.data;if(nu&&(o instanceof Float32Array||!o)&&(this.data=new Float32Array(i+n),i>0&&o))for(var s=0;s<i;s++)this.data[s]=o[s];for(var a=0;a<r;a++)for(var l=t[a].data,s=0;s<l.length;s++)this.data[i++]=l[s];this._len=i}},e.prototype.addData=function(t,r,n,i,a,o,s,l,u){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]}},e.prototype._drawPendingPt=function(){this._pendingPtDist>0&&(this._ctx&&this._ctx.lineTo(this._pendingPtX,this._pendingPtY),this._pendingPtDist=0)},e.prototype._expandData=function(){if(!(this.data instanceof Array)){for(var t=[],r=0;r<this._len;r++)t[r]=this.data[r];this.data=t}},e.prototype.toStatic=function(){if(this._saveData){this._drawPendingPt();var t=this.data;t instanceof Array&&(t.length=this._len,nu&&this._len>11&&(this.data=new Float32Array(t)))}},e.prototype.getBoundingRect=function(){He[0]=He[1]=Ve[0]=Ve[1]=Number.MAX_VALUE,Sr[0]=Sr[1]=Ge[0]=Ge[1]=-Number.MAX_VALUE;var t=this.data,r=0,n=0,i=0,a=0,o;for(o=0;o<this._len;){var s=t[o++],l=o===1;switch(l&&(r=t[o],n=t[o+1],i=r,a=n),s){case ht.M:r=i=t[o++],n=a=t[o++],Ve[0]=i,Ve[1]=a,Ge[0]=i,Ge[1]=a;break;case ht.L:Lc(r,n,t[o],t[o+1],Ve,Ge),r=t[o++],n=t[o++];break;case ht.C:Zb(r,n,t[o++],t[o++],t[o++],t[o++],t[o],t[o+1],Ve,Ge),r=t[o++],n=t[o++];break;case ht.Q:qb(r,n,t[o++],t[o++],t[o],t[o+1],Ve,Ge),r=t[o++],n=t[o++];break;case ht.A:var u=t[o++],f=t[o++],h=t[o++],v=t[o++],c=t[o++],d=t[o++]+c;o+=1;var p=!t[o++];l&&(i=rn(c)*h+u,a=nn(c)*v+f),Kb(u,f,h,v,c,d,p,Ve,Ge),r=rn(d)*h+u,n=nn(d)*v+f;break;case ht.R:i=r=t[o++],a=n=t[o++];var m=t[o++],g=t[o++];Lc(i,a,i+m,a+g,Ve,Ge);break;case ht.Z:r=i,n=a;break}Jn(He,He,Ve),jn(Sr,Sr,Ge)}return o===0&&(He[0]=He[1]=Sr[0]=Sr[1]=0),new it(He[0],He[1],Sr[0]-He[0],Sr[1]-He[1])},e.prototype._calculateLength=function(){var t=this.data,r=this._len,n=this._ux,i=this._uy,a=0,o=0,s=0,l=0;this._pathSegLen||(this._pathSegLen=[]);for(var u=this._pathSegLen,f=0,h=0,v=0;v<r;){var c=t[v++],d=v===1;d&&(a=t[v],o=t[v+1],s=a,l=o);var p=-1;switch(c){case ht.M:a=s=t[v++],o=l=t[v++];break;case ht.L:{var m=t[v++],g=t[v++],y=m-a,_=g-o;(ur(y)>n||ur(_)>i||v===r-1)&&(p=Math.sqrt(y*y+_*_),a=m,o=g);break}case ht.C:{var S=t[v++],b=t[v++],m=t[v++],g=t[v++],T=t[v++],w=t[v++];p=oS(a,o,S,b,m,g,T,w,10),a=T,o=w;break}case ht.Q:{var S=t[v++],b=t[v++],m=t[v++],g=t[v++];p=uS(a,o,S,b,m,g,10),a=m,o=g;break}case ht.A:var M=t[v++],C=t[v++],x=t[v++],A=t[v++],I=t[v++],L=t[v++],P=L+I;v+=1,d&&(s=rn(I)*x+M,l=nn(I)*A+C),p=ru(x,A)*eu(Ar,Math.abs(L)),a=rn(P)*x+M,o=nn(P)*A+C;break;case ht.R:{s=a=t[v++],l=o=t[v++];var R=t[v++],E=t[v++];p=R*2+E*2;break}case ht.Z:{var y=s-a,_=l-o;p=Math.sqrt(y*y+_*_),a=s,o=l;break}}p>=0&&(u[h++]=p,f+=p)}return this._pathLen=f,f},e.prototype.rebuildPath=function(t,r){var n=this.data,i=this._ux,a=this._uy,o=this._len,s,l,u,f,h,v,c=r<1,d,p,m=0,g=0,y,_=0,S,b;if(!(c&&(this._pathSegLen||this._calculateLength(),d=this._pathSegLen,p=this._pathLen,y=r*p,!y)))t:for(var T=0;T<o;){var w=n[T++],M=T===1;switch(M&&(u=n[T],f=n[T+1],s=u,l=f),w!==ht.L&&_>0&&(t.lineTo(S,b),_=0),w){case ht.M:s=u=n[T++],l=f=n[T++],t.moveTo(u,f);break;case ht.L:{h=n[T++],v=n[T++];var C=ur(h-u),x=ur(v-f);if(C>i||x>a){if(c){var A=d[g++];if(m+A>y){var I=(y-m)/A;t.lineTo(u*(1-I)+h*I,f*(1-I)+v*I);break t}m+=A}t.lineTo(h,v),u=h,f=v,_=0}else{var L=C*C+x*x;L>_&&(S=h,b=v,_=L)}break}case ht.C:{var P=n[T++],R=n[T++],E=n[T++],F=n[T++],G=n[T++],U=n[T++];if(c){var A=d[g++];if(m+A>y){var I=(y-m)/A;ds(u,P,E,G,I,tn),ds(f,R,F,U,I,en),t.bezierCurveTo(tn[1],en[1],tn[2],en[2],tn[3],en[3]);break t}m+=A}t.bezierCurveTo(P,R,E,F,G,U),u=G,f=U;break}case ht.Q:{var P=n[T++],R=n[T++],E=n[T++],F=n[T++];if(c){var A=d[g++];if(m+A>y){var I=(y-m)/A;ps(u,P,E,I,tn),ps(f,R,F,I,en),t.quadraticCurveTo(tn[1],en[1],tn[2],en[2]);break t}m+=A}t.quadraticCurveTo(P,R,E,F),u=E,f=F;break}case ht.A:var tt=n[T++],Z=n[T++],at=n[T++],q=n[T++],z=n[T++],lt=n[T++],k=n[T++],B=!n[T++],Q=at>q?at:q,$=ur(at-q)>.001,et=z+lt,X=!1;if(c){var A=d[g++];m+A>y&&(et=z+lt*(y-m)/A,X=!0),m+=A}if($&&t.ellipse?t.ellipse(tt,Z,at,q,k,z,et,B):t.arc(tt,Z,Q,z,et,B),X)break t;M&&(s=rn(z)*at+tt,l=nn(z)*q+Z),u=rn(et)*at+tt,f=nn(et)*q+Z;break;case ht.R:s=u=n[T],l=f=n[T+1],h=n[T++],v=n[T++];var Y=n[T++],Ft=n[T++];if(c){var A=d[g++];if(m+A>y){var Dt=y-m;t.moveTo(h,v),t.lineTo(h+eu(Dt,Y),v),Dt-=Y,Dt>0&&t.lineTo(h+Y,v+eu(Dt,Ft)),Dt-=Ft,Dt>0&&t.lineTo(h+ru(Y-Dt,0),v+Ft),Dt-=Y,Dt>0&&t.lineTo(h,v+ru(Ft-Dt,0));break t}m+=A}t.rect(h,v,Y,Ft);break;case ht.Z:if(c){var A=d[g++];if(m+A>y){var I=(y-m)/A;t.lineTo(u*(1-I)+s*I,f*(1-I)+l*I);break t}m+=A}t.closePath(),u=s,f=l}}},e.prototype.clone=function(){var t=new e,r=this.data;return t.data=r.slice?r.slice():Array.prototype.slice.call(r),t._len=this._len,t},e.prototype.canSave=function(){return!!this._saveData},e.CMD=ht,e.initDefaultProps=(function(){var t=e.prototype;t._saveData=!0,t._ux=0,t._uy=0,t._pendingPtDist=0,t._version=0})(),e})();function Fn(e,t,r,n,i,a,o){if(i===0)return!1;var s=i,l=0,u=e;if(o>t+s&&o>n+s||o<t-s&&o<n-s||a>e+s&&a>r+s||a<e-s&&a<r-s)return!1;if(e!==r)l=(t-n)/(e-r),u=(e*n-r*t)/(e-r);else return Math.abs(a-e)<=s/2;var f=l*a-o+u,h=f*f/(l*l+1);return h<=s/2*s/2}function Jb(e,t,r,n,i,a,o,s,l,u,f){if(l===0)return!1;var h=l;if(f>t+h&&f>n+h&&f>a+h&&f>s+h||f<t-h&&f<n-h&&f<a-h&&f<s-h||u>e+h&&u>r+h&&u>i+h&&u>o+h||u<e-h&&u<r-h&&u<i-h&&u<o-h)return!1;var v=aS(e,t,r,n,i,a,o,s,u,f);return v<=h/2}function jb(e,t,r,n,i,a,o,s,l){if(o===0)return!1;var u=o;if(l>t+u&&l>n+u&&l>a+u||l<t-u&&l<n-u&&l<a-u||s>e+u&&s>r+u&&s>i+u||s<e-u&&s<r-u&&s<i-u)return!1;var f=lS(e,t,r,n,i,a,s,l);return f<=u/2}var Ec=Math.PI*2;function ho(e){return e%=Ec,e<0&&(e+=Ec),e}var Ri=Math.PI*2;function tT(e,t,r,n,i,a,o,s,l){if(o===0)return!1;var u=o;s-=e,l-=t;var f=Math.sqrt(s*s+l*l);if(f-u>r||f+u<r)return!1;if(Math.abs(n-i)%Ri<1e-4)return!0;if(a){var h=n;n=ho(i),i=ho(h)}else n=ho(n),i=ho(i);n>i&&(i+=Ri);var v=Math.atan2(l,s);return v<0&&(v+=Ri),v>=n&&v<=i||v+Ri>=n&&v+Ri<=i}function an(e,t,r,n,i,a){if(a>t&&a>n||a<t&&a<n||n===t)return 0;var o=(a-t)/(n-t),s=n<t?1:-1;(o===1||o===0)&&(s=n<t?.5:-.5);var l=o*(r-e)+e;return l===i?1/0:l>i?s:0}var br=Ln.CMD,on=Math.PI*2,eT=1e-4;function rT(e,t){return Math.abs(e-t)<eT}var Kt=[-1,-1,-1],Se=[-1,-1];function nT(){var e=Se[0];Se[0]=Se[1],Se[1]=e}function iT(e,t,r,n,i,a,o,s,l,u){if(u>t&&u>n&&u>a&&u>s||u<t&&u<n&&u<a&&u<s)return 0;var f=cs(t,n,a,s,u,Kt);if(f===0)return 0;for(var h=0,v=-1,c=void 0,d=void 0,p=0;p<f;p++){var m=Kt[p],g=m===0||m===1?.5:1,y=Ht(e,r,i,o,m);y<l||(v<0&&(v=Zg(t,n,a,s,Se),Se[1]<Se[0]&&v>1&&nT(),c=Ht(t,n,a,s,Se[0]),v>1&&(d=Ht(t,n,a,s,Se[1]))),v===2?m<Se[0]?h+=c<t?g:-g:m<Se[1]?h+=d<c?g:-g:h+=s<d?g:-g:m<Se[0]?h+=c<t?g:-g:h+=s<c?g:-g)}return h}function aT(e,t,r,n,i,a,o,s){if(s>t&&s>n&&s>a||s<t&&s<n&&s<a)return 0;var l=sS(t,n,a,s,Kt);if(l===0)return 0;var u=qg(t,n,a);if(u>=0&&u<=1){for(var f=0,h=ee(t,n,a,u),v=0;v<l;v++){var c=Kt[v]===0||Kt[v]===1?.5:1,d=ee(e,r,i,Kt[v]);d<o||(Kt[v]<u?f+=h<t?c:-c:f+=a<h?c:-c)}return f}else{var c=Kt[0]===0||Kt[0]===1?.5:1,d=ee(e,r,i,Kt[0]);return d<o?0:a<t?c:-c}}function oT(e,t,r,n,i,a,o,s){if(s-=t,s>r||s<-r)return 0;var l=Math.sqrt(r*r-s*s);Kt[0]=-l,Kt[1]=l;var u=Math.abs(n-i);if(u<1e-4)return 0;if(u>=on-1e-4){n=0,i=on;var f=a?1:-1;return o>=Kt[0]+e&&o<=Kt[1]+e?f:0}if(n>i){var h=n;n=i,i=h}n<0&&(n+=on,i+=on);for(var v=0,c=0;c<2;c++){var d=Kt[c];if(d+e>o){var p=Math.atan2(s,d),f=a?1:-1;p<0&&(p=on+p),(p>=n&&p<=i||p+on>=n&&p+on<=i)&&(p>Math.PI/2&&p<Math.PI*1.5&&(f=-f),v+=f)}}return v}function Mm(e,t,r,n,i){for(var a=e.data,o=e.len(),s=0,l=0,u=0,f=0,h=0,v,c,d=0;d<o;){var p=a[d++],m=d===1;switch(p===br.M&&d>1&&(r||(s+=an(l,u,f,h,n,i))),m&&(l=a[d],u=a[d+1],f=l,h=u),p){case br.M:f=a[d++],h=a[d++],l=f,u=h;break;case br.L:if(r){if(Fn(l,u,a[d],a[d+1],t,n,i))return!0}else s+=an(l,u,a[d],a[d+1],n,i)||0;l=a[d++],u=a[d++];break;case br.C:if(r){if(Jb(l,u,a[d++],a[d++],a[d++],a[d++],a[d],a[d+1],t,n,i))return!0}else s+=iT(l,u,a[d++],a[d++],a[d++],a[d++],a[d],a[d+1],n,i)||0;l=a[d++],u=a[d++];break;case br.Q:if(r){if(jb(l,u,a[d++],a[d++],a[d],a[d+1],t,n,i))return!0}else s+=aT(l,u,a[d++],a[d++],a[d],a[d+1],n,i)||0;l=a[d++],u=a[d++];break;case br.A:var g=a[d++],y=a[d++],_=a[d++],S=a[d++],b=a[d++],T=a[d++];d+=1;var w=!!(1-a[d++]);v=Math.cos(b)*_+g,c=Math.sin(b)*S+y,m?(f=v,h=c):s+=an(l,u,v,c,n,i);var M=(n-g)*S/_+g;if(r){if(tT(g,y,S,b,b+T,w,t,M,i))return!0}else s+=oT(g,y,S,b,b+T,w,M,i);l=Math.cos(b+T)*_+g,u=Math.sin(b+T)*S+y;break;case br.R:f=l=a[d++],h=u=a[d++];var C=a[d++],x=a[d++];if(v=f+C,c=h+x,r){if(Fn(f,h,v,h,t,n,i)||Fn(v,h,v,c,t,n,i)||Fn(v,c,f,c,t,n,i)||Fn(f,c,f,h,t,n,i))return!0}else s+=an(v,h,v,c,n,i),s+=an(f,c,f,h,n,i);break;case br.Z:if(r){if(Fn(l,u,f,h,t,n,i))return!0}else s+=an(l,u,f,h,n,i);l=f,u=h;break}}return!r&&!rT(u,h)&&(s+=an(l,u,f,h,n,i)||0),s!==0}function sT(e,t,r){return Mm(e,0,!1,t,r)}function lT(e,t,r,n){return Mm(e,t,!0,r,n)}var Am=yt({fill:"#000",stroke:null,strokePercent:1,fillOpacity:1,strokeOpacity:1,lineDashOffset:0,lineWidth:1,lineCap:"butt",miterLimit:10,strokeNoScale:!1,strokeFirst:!1},Cn),uT={style:yt({fill:!0,stroke:!0,strokePercent:!0,fillOpacity:!0,strokeOpacity:!0,lineDashOffset:!0,lineWidth:!0,miterLimit:!0},el.style)},au=qs.concat(["invisible","culling","z","z2","zlevel","parent"]),St=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.update=function(){var r=this;e.prototype.update.call(this);var n=this.style;if(n.decal){var i=this._decalEl=this._decalEl||new t;i.buildPath===t.prototype.buildPath&&(i.buildPath=function(l){r.buildPath(l,r.shape)}),i.silent=!0;var a=i.style;for(var o in n)a[o]!==n[o]&&(a[o]=n[o]);a.fill=n.fill?n.decal:null,a.decal=null,a.shadowColor=null,n.strokeFirst&&(a.stroke=null);for(var s=0;s<au.length;++s)i[au[s]]=this[au[s]];i.__dirty|=ne}else this._decalEl&&(this._decalEl=null)},t.prototype.getDecalElement=function(){return this._decalEl},t.prototype._init=function(r){var n=xt(r);this.shape=this.getDefaultShape();var i=this.getDefaultStyle();i&&this.useStyle(i);for(var a=0;a<n.length;a++){var o=n[a],s=r[o];o==="style"?this.style?N(this.style,s):this.useStyle(s):o==="shape"?N(this.shape,s):e.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 r=this.style.fill;if(r!=="none"){if(W(r)){var n=gs(r,0);return n>.5?vf:n>.2?IS:cf}else if(r)return cf}return vf},t.prototype.getInsideTextStroke=function(r){var n=this.style.fill;if(W(n)){var i=this.__zr,a=!!(i&&i.isDarkMode()),o=gs(r,0)<hf;if(a===o)return n}},t.prototype.buildPath=function(r,n,i){},t.prototype.pathUpdated=function(){this.__dirty&=~Kn},t.prototype.getUpdatedPathProxy=function(r){return!this.path&&this.createPathProxy(),this.path.beginPath(),this.buildPath(this.path,this.shape,r),this.path},t.prototype.createPathProxy=function(){this.path=new Ln(!1)},t.prototype.hasStroke=function(){var r=this.style,n=r.stroke;return!(n==null||n==="none"||!(r.lineWidth>0))},t.prototype.hasFill=function(){var r=this.style,n=r.fill;return n!=null&&n!=="none"},t.prototype.getBoundingRect=function(){var r=this._rect,n=this.style,i=!r;if(i){var a=!1;this.path||(a=!0,this.createPathProxy());var o=this.path;(a||this.__dirty&Kn)&&(o.beginPath(),this.buildPath(o,this.shape,!1),this.pathUpdated()),r=o.getBoundingRect()}if(this._rect=r,this.hasStroke()&&this.path&&this.path.len()>0){var s=this._rectStroke||(this._rectStroke=r.clone());if(this.__dirty||i){s.copy(r);var l=n.strokeNoScale?this.getLineScale():1,u=n.lineWidth;if(!this.hasFill()){var f=this.strokeContainThreshold;u=Math.max(u,f??4)}l>1e-10&&(s.width+=u/l,s.height+=u/l,s.x-=u/l/2,s.y-=u/l/2)}return s}return r},t.prototype.contain=function(r,n){var i=this.transformCoordToLocal(r,n),a=this.getBoundingRect(),o=this.style;if(r=i[0],n=i[1],a.contain(r,n)){var s=this.path;if(this.hasStroke()){var l=o.lineWidth,u=o.strokeNoScale?this.getLineScale():1;if(u>1e-10&&(this.hasFill()||(l=Math.max(l,this.strokeContainThreshold)),lT(s,l/u,r,n)))return!0}if(this.hasFill())return sT(s,r,n)}return!1},t.prototype.dirtyShape=function(){this.__dirty|=Kn,this._rect&&(this._rect=null),this._decalEl&&this._decalEl.dirtyShape(),this.markRedraw()},t.prototype.dirty=function(){this.dirtyStyle(),this.dirtyShape()},t.prototype.animateShape=function(r){return this.animate("shape",r)},t.prototype.updateDuringAnimation=function(r){r==="style"?this.dirtyStyle():r==="shape"?this.dirtyShape():this.markRedraw()},t.prototype.attrKV=function(r,n){r==="shape"?this.setShape(n):e.prototype.attrKV.call(this,r,n)},t.prototype.setShape=function(r,n){var i=this.shape;return i||(i=this.shape={}),typeof r=="string"?i[r]=n:N(i,r),this.dirtyShape(),this},t.prototype.shapeChanged=function(){return!!(this.__dirty&Kn)},t.prototype.createStyle=function(r){return Zs(Am,r)},t.prototype._innerSaveToNormal=function(r){e.prototype._innerSaveToNormal.call(this,r);var n=this._normalState;r.shape&&!n.shape&&(n.shape=N({},this.shape))},t.prototype._applyStateObj=function(r,n,i,a,o,s){if(e.prototype._applyStateObj.call(this,r,n,i,a,o,s),this.__inHover!==Qs){var l=!(n&&a),u;if(n&&n.shape?o?a?u=n.shape:(u=N({},i.shape),N(u,n.shape)):(u=N({},a?this.shape:i.shape),N(u,n.shape)):l&&(u=i.shape),u)if(o){this.shape=N({},this.shape);for(var f={},h=xt(u),v=0;v<h.length;v++){var c=h[v];typeof u[c]=="object"?this.shape[c]=u[c]:f[c]=u[c]}this._transitionState(r,{shape:f},s)}else this.shape=u,this.dirtyShape()}},t.prototype._mergeStates=function(r){for(var n=e.prototype._mergeStates.call(this,r),i,a=0;a<r.length;a++){var o=r[a];o.shape&&(i=i||{},this._mergeStyle(i,o.shape))}return i&&(n.shape=i),n},t.prototype.getAnimationStyleProps=function(){return uT},t.prototype.isZeroArea=function(){return!1},t.extend=function(r){var n=(function(a){V(o,a);function o(s){var l=a.call(this,s)||this;return r.init&&r.init.call(l,s),l}return o.prototype.getDefaultStyle=function(){return ut(r.style)},o.prototype.getDefaultShape=function(){return ut(r.shape)},o})(t);for(var i in r)typeof r[i]=="function"&&(n.prototype[i]=r[i]);return n},t.initDefaultProps=(function(){var r=t.prototype;r.type="path",r.strokeContainThreshold=5,r.segmentIgnoreThreshold=0,r.subPixelOptimize=!1,r.autoBatch=!1,r.__dirty=ne|qi|Kn})(),t})(Va),fT=yt({strokeFirst:!0,font:Nr,x:0,y:0,textAlign:"left",textBaseline:"top",miterLimit:2},Am),bs=(function(e){V(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.hasStroke=function(){return Dm(this.style)},t.prototype.hasFill=function(){var r=this.style,n=r.fill;return n!=null&&n!=="none"},t.prototype.createStyle=function(r){return Zs(fT,r)},t.prototype.setBoundingRect=function(r){this._rect=r},t.prototype.getBoundingRect=function(){return this._rect||(this._rect=Yb(this.style)),this._rect},t.initDefaultProps=(function(){var r=t.prototype;r.dirtyRectTolerance=10})(),t})(Va);bs.prototype.type="tspan";var hT=yt({x:0,y:0},Cn),vT={style:yt({x:!0,y:!0,width:!0,height:!0,sx:!0,sy:!0,sWidth:!0,sHeight:!0},el.style)};function cT(e){return!!(e&&typeof e!="string"&&e.width&&e.height)}var Wr=(function(e){V(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.createStyle=function(r){return Zs(hT,r)},t.prototype._getSize=function(r){var n=this.style,i=n[r];if(i!=null)return i;var a=cT(n.image)?n.image:this.__image;if(!a)return 0;var o=r==="width"?"height":"width",s=n[o];return s==null?a[r]:a[r]/a[o]*s},t.prototype.getWidth=function(){return this._getSize("width")},t.prototype.getHeight=function(){return this._getSize("height")},t.prototype.getAnimationStyleProps=function(){return vT},t.prototype.getBoundingRect=function(){var r=this.style;return this._rect||(this._rect=new it(r.x||0,r.y||0,this.getWidth(),this.getHeight())),this._rect},t})(Va);Wr.prototype.type="image";function dT(e,t){var r=t.x,n=t.y,i=t.width,a=t.height,o=t.r,s,l,u,f;i<0&&(r=r+i,i=-i),a<0&&(n=n+a,a=-a),typeof o=="number"?s=l=u=f=o:o instanceof Array?o.length===1?s=l=u=f=o[0]:o.length===2?(s=u=o[0],l=f=o[1]):o.length===3?(s=o[0],l=f=o[1],u=o[2]):(s=o[0],l=o[1],u=o[2],f=o[3]):s=l=u=f=0;var h;s+l>i&&(h=s+l,s*=i/h,l*=i/h),u+f>i&&(h=u+f,u*=i/h,f*=i/h),l+u>a&&(h=l+u,l*=a/h,u*=a/h),s+f>a&&(h=s+f,s*=a/h,f*=a/h),e.moveTo(r+s,n),e.lineTo(r+i-l,n),l!==0&&e.arc(r+i-l,n+l,l,-Math.PI/2,0),e.lineTo(r+i,n+a-u),u!==0&&e.arc(r+i-u,n+a-u,u,0,Math.PI/2),e.lineTo(r+f,n+a),f!==0&&e.arc(r+f,n+a-f,f,Math.PI/2,Math.PI),e.lineTo(r,n+s),s!==0&&e.arc(r+s,n+s,s,Math.PI,Math.PI*1.5),e.closePath()}var ri=Math.round;function Lm(e,t,r){if(t){var n=t.x1,i=t.x2,a=t.y1,o=t.y2;e.x1=n,e.x2=i,e.y1=a,e.y2=o;var s=r&&r.lineWidth;return s&&(ri(n*2)===ri(i*2)&&(e.x1=e.x2=Sn(n,s,!0)),ri(a*2)===ri(o*2)&&(e.y1=e.y2=Sn(a,s,!0))),e}}function Im(e,t,r){if(t){var n=t.x,i=t.y,a=t.width,o=t.height;e.x=n,e.y=i,e.width=a,e.height=o;var s=r&&r.lineWidth;return s&&(e.x=Sn(n,s,!0),e.y=Sn(i,s,!0),e.width=Math.max(Sn(n+a,s,!1)-e.x,a===0?0:1),e.height=Math.max(Sn(i+o,s,!1)-e.y,o===0?0:1)),e}}function Sn(e,t,r){if(!t)return e;var n=ri(e*2);return(n+ri(t))%2===0?n/2:(n+(r?1:-1))/2}var pT=(function(){function e(){this.x=0,this.y=0,this.width=0,this.height=0}return e})(),gT={},Rt=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.getDefaultShape=function(){return new pT},t.prototype.buildPath=function(r,n){var i,a,o,s;if(this.subPixelOptimize){var l=Im(gT,n,this.style);i=l.x,a=l.y,o=l.width,s=l.height,l.r=n.r,n=l}else i=n.x,a=n.y,o=n.width,s=n.height;n.r?dT(r,n):r.rect(i,a,o,s)},t.prototype.isZeroArea=function(){return!this.shape.width||!this.shape.height},t})(St);Rt.prototype.type="rect";var Rc={fill:"#000"},kc=2,Ue={},mT={style:yt({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},el.style)},oe=(function(e){V(t,e);function t(r){var n=e.call(this)||this;return n.type="text",n._children=[],n._defaultStyle=Rc,n.attr(r),n}return t.prototype.childrenRef=function(){return this._children},t.prototype.update=function(){e.prototype.update.call(this),this.styleChanged()&&this._updateSubTexts();for(var r=0;r<this._children.length;r++){var n=this._children[r];n.zlevel=this.zlevel,n.z=this.z,n.z2=this.z2,n.culling=this.culling,n.cursor=this.cursor,n.invisible=this.invisible}},t.prototype.updateTransform=function(){var r=this.innerTransformable;r?(r.updateTransform(),r.transform&&(this.transform=r.transform)):e.prototype.updateTransform.call(this)},t.prototype.getLocalTransform=function(r){var n=this.innerTransformable;return n?n.getLocalTransform(r):e.prototype.getLocalTransform.call(this,r)},t.prototype.getComputedTransform=function(){return this.__hostTarget&&(this.__hostTarget.getComputedTransform(),this.__hostTarget.updateInnerText(!0)),e.prototype.getComputedTransform.call(this)},t.prototype._updateSubTexts=function(){this._childCursor=0,TT(this.style),this.style.rich?this._updateRichTexts():this._updatePlainTexts(),this._children.length=this._childCursor,this.styleUpdated()},t.prototype.addSelfToZr=function(r){e.prototype.addSelfToZr.call(this,r);for(var n=0;n<this._children.length;n++)this._children[n].__zr=r},t.prototype.removeSelfFromZr=function(r){e.prototype.removeSelfFromZr.call(this,r);for(var n=0;n<this._children.length;n++)this._children[n].__zr=null},t.prototype.getBoundingRect=function(){if(this.styleChanged()&&this._updateSubTexts(),!this._rect){for(var r=new it(0,0,0,0),n=this._children,i=[],a=null,o=0;o<n.length;o++){var s=n[o],l=s.getBoundingRect(),u=s.getLocalTransform(i);u?(r.copy(l),r.applyTransform(u),a=a||r.clone(),a.union(r)):(a=a||l.clone(),a.union(l))}this._rect=a||r}return this._rect},t.prototype.setDefaultTextStyle=function(r){this._defaultStyle=r||Rc},t.prototype.setTextContent=function(r){},t.prototype._mergeStyle=function(r,n){if(!n)return r;var i=n.rich,a=r.rich||i&&{};return N(r,n),i&&a?(this._mergeRich(a,i),r.rich=a):a&&(r.rich=a),r},t.prototype._mergeRich=function(r,n){for(var i=xt(n),a=0;a<i.length;a++){var o=i[a];r[o]=r[o]||{},N(r[o],n[o])}},t.prototype.getAnimationStyleProps=function(){return mT},t.prototype._getOrCreateChild=function(r){var n=this._children[this._childCursor];return(!n||!(n instanceof r))&&(n=new r),this._children[this._childCursor++]=n,n.__zr=this.__zr,n.parent=this,n},t.prototype._updatePlainTexts=function(){var r=this.style,n=r.font||Nr,i=r.padding,a=this._defaultStyle,o=r.x||0,s=r.y||0,l=r.align||a.align||"left",u=r.verticalAlign||a.verticalAlign||"top";Cc(Ue,a.overflowRect,o,s,l,u),o=Ue.baseX,s=Ue.baseY;var f=Vc(r),h=Fb(f,r,Ue.outerWidth,Ue.outerHeight),v=ou(r),c=!!r.backgroundColor,d=h.outerHeight,p=h.outerWidth,m=h.lines,g=h.lineHeight;this.isTruncated=!!h.isTruncated;var y=o,_=xn(s,h.contentHeight,u);if(v||i){var S=ci(o,p,l),b=xn(s,d,u);v&&this._renderBackground(r,r,S,b,p,d)}_+=g/2,i&&(y=Hc(o,l,i),u==="top"?_+=i[0]:u==="bottom"&&(_-=i[2]));for(var T=0,w=!1,M=!1,C=zc("fill"in r?r.fill:(M=!0,a.fill)),x=Fc("stroke"in r?r.stroke:!c&&(!a.autoStroke||M)?(T=kc,w=!0,a.stroke):null),A=r.textShadowBlur>0,I=0;I<m.length;I++){var L=this._getOrCreateChild(bs),P=L.createStyle();L.useStyle(P),P.text=m[I],P.x=y,P.y=_,P.textAlign=l,P.textBaseline="middle",P.opacity=r.opacity,P.strokeFirst=!0,A&&(P.shadowBlur=r.textShadowBlur||0,P.shadowColor=r.textShadowColor||"transparent",P.shadowOffsetX=r.textShadowOffsetX||0,P.shadowOffsetY=r.textShadowOffsetY||0),P.stroke=x,P.fill=C,x&&(P.lineWidth=r.lineWidth||T,P.lineDash=r.lineDash,P.lineDashOffset=r.lineDashOffset||0),P.font=n,Bc(P,r),_+=g,L.setBoundingRect(yf(P,h.contentWidth,h.calculatedLineHeight,w?0:null))}},t.prototype._updateRichTexts=function(){var r=this.style,n=this._defaultStyle,i=r.align||n.align,a=r.verticalAlign||n.verticalAlign,o=r.x||0,s=r.y||0;Cc(Ue,n.overflowRect,o,s,i,a),o=Ue.baseX,s=Ue.baseY;var l=Vc(r),u=Vb(l,r,Ue.outerWidth,Ue.outerHeight,i),f=u.width,h=u.outerWidth,v=u.outerHeight,c=r.padding;this.isTruncated=!!u.isTruncated;var d=ci(o,h,i),p=xn(s,v,a),m=d,g=p;c&&(m+=c[3],g+=c[0]);var y=m+f;ou(r)&&this._renderBackground(r,r,d,p,h,v);for(var _=!!r.backgroundColor,S=0;S<u.lines.length;S++){for(var b=u.lines[S],T=b.tokens,w=T.length,M=b.lineHeight,C=b.width,x=0,A=m,I=y,L=w-1,P=void 0;x<w&&(P=T[x],!P.align||P.align==="left");)this._placeToken(P,r,M,g,A,"left",_),C-=P.width,A+=P.width,x++;for(;L>=0&&(P=T[L],P.align==="right");)this._placeToken(P,r,M,g,I,"right",_),C-=P.width,I-=P.width,L--;for(A+=(f-(A-m)-(y-I)-C)/2;x<=L;)P=T[x],this._placeToken(P,r,M,g,A+P.width/2,"center",_),A+=P.width,x++;g+=M}},t.prototype._placeToken=function(r,n,i,a,o,s,l){var u=n.rich[r.styleName]||{};u.text=r.text;var f=r.verticalAlign,h=a+i/2;f==="top"?h=a+r.height/2:f==="bottom"&&(h=a+i-r.height/2);var v=!r.isLineHolder&&ou(u);v&&this._renderBackground(u,n,s==="right"?o-r.width:s==="center"?o-r.width/2:o,h-r.height/2,r.width,r.height);var c=!!u.backgroundColor,d=r.textPadding;d&&(o=Hc(o,s,d),h-=r.height/2-d[0]-r.innerHeight/2);var p=this._getOrCreateChild(bs),m=p.createStyle();p.useStyle(m);var g=this._defaultStyle,y=!1,_=0,S=!1,b=zc("fill"in u?u.fill:"fill"in n?n.fill:(y=!0,g.fill)),T=Fc("stroke"in u?u.stroke:"stroke"in n?n.stroke:!c&&!l&&(!g.autoStroke||y)?(_=kc,S=!0,g.stroke):null),w=u.textShadowBlur>0||n.textShadowBlur>0;m.text=r.text,m.x=o,m.y=h,w&&(m.shadowBlur=u.textShadowBlur||n.textShadowBlur||0,m.shadowColor=u.textShadowColor||n.textShadowColor||"transparent",m.shadowOffsetX=u.textShadowOffsetX||n.textShadowOffsetX||0,m.shadowOffsetY=u.textShadowOffsetY||n.textShadowOffsetY||0),m.textAlign=s,m.textBaseline="middle",m.font=r.font||Nr,m.opacity=ai(u.opacity,n.opacity,1),Bc(m,u),T&&(m.lineWidth=ai(u.lineWidth,n.lineWidth,_),m.lineDash=j(u.lineDash,n.lineDash),m.lineDashOffset=n.lineDashOffset||0,m.stroke=T),b&&(m.fill=b),p.setBoundingRect(yf(m,r.contentWidth,r.contentHeight,S?0:null))},t.prototype._renderBackground=function(r,n,i,a,o,s){var l=r.backgroundColor,u=r.borderWidth,f=r.borderColor,h=l&&l.image,v=l&&!h,c=r.borderRadius,d=this,p,m;if(v||r.lineHeight||u&&f){p=this._getOrCreateChild(Rt),p.useStyle(p.createStyle()),p.style.fill=null;var g=p.shape;g.x=i,g.y=a,g.width=o,g.height=s,g.r=c,p.dirtyShape()}if(v){var y=p.style;y.fill=l||null,y.fillOpacity=j(r.fillOpacity,1)}else if(h){m=this._getOrCreateChild(Wr),m.onload=function(){d.dirtyStyle()};var _=m.style;_.image=l.image,_.x=i,_.y=a,_.width=o,_.height=s}if(u&&f){var y=p.style;y.lineWidth=u,y.stroke=f,y.strokeOpacity=j(r.strokeOpacity,1),y.lineDash=r.borderDash,y.lineDashOffset=r.borderDashOffset||0,p.strokeContainThreshold=0,p.hasFill()&&p.hasStroke()&&(y.strokeFirst=!0,y.lineWidth*=2)}var S=(p||m).style;S.shadowBlur=r.shadowBlur||0,S.shadowColor=r.shadowColor||"transparent",S.shadowOffsetX=r.shadowOffsetX||0,S.shadowOffsetY=r.shadowOffsetY||0,S.opacity=ai(r.opacity,n.opacity,1)},t.makeFont=function(r){var n="";return bT(r)&&(n=[r.fontStyle,r.fontWeight,ST(r.fontSize),r.fontFamily||"sans-serif"].join(" ")),n&&$e(n)||r.textFont||r.font},t})(Va),yT={left:!0,right:1,center:1},_T={top:1,bottom:1,middle:1},Oc=["fontStyle","fontWeight","fontSize","fontFamily"];function ST(e){return typeof e=="string"&&(e.indexOf("px")!==-1||e.indexOf("rem")!==-1||e.indexOf("em")!==-1)?e:isNaN(+e)?uh+"px":e+"px"}function Bc(e,t){for(var r=0;r<Oc.length;r++){var n=Oc[r],i=t[n];i!=null&&(e[n]=i)}}function bT(e){return e.fontSize!=null||e.fontFamily||e.fontWeight}function TT(e){return Nc(e),D(e.rich,Nc),e}function Nc(e){if(e){e.font=oe.makeFont(e);var t=e.align;t==="middle"&&(t="center"),e.align=t==null||yT[t]?t:"left";var r=e.verticalAlign;r==="center"&&(r="middle"),e.verticalAlign=r==null||_T[r]?r:"top";var n=e.padding;n&&(e.padding=dh(e.padding))}}function Fc(e,t){return e==null||t<=0||e==="transparent"||e==="none"?null:e.image||e.colorStops?"#000":e}function zc(e){return e==null||e==="none"?null:e.image||e.colorStops?"#000":e}function Hc(e,t,r){return t==="right"?e-r[1]:t==="center"?e+r[3]/2-r[1]/2:e+r[3]}function Vc(e){var t=e.text;return t!=null&&(t+=""),t}function ou(e){return!!(e.backgroundColor||e.lineHeight||e.borderWidth&&e.borderColor)}var gt=bt(),wT=function(e,t,r,n){if(n){var i=gt(n);i.dataIndex=r,i.dataType=t,i.seriesIndex=e,i.ssrType="chart",n.type==="group"&&n.traverse(function(a){var o=gt(a);o.seriesIndex=e,o.dataIndex=r,o.dataType=t,o.ssrType="chart"})}},Ga="undefined",Pm="series",Em=nt(["tooltip","label","itemName","itemId","itemGroupId","itemChildGroupId","seriesName"]),ve="original",Zt="arrayRows",Ne="objectRows",sr="keyedColumns",Or="typedArray",Rm="unknown",tr="column",En="row",xT=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isSSR","isDisposed","on","off","getDataURL","getConnectedDataURL","getOption","getId","updateLabelLayout"],km=(function(){function e(t){D(xT,function(r){this[r]=wt(t[r],t)},this)}return e})();function CT(e,t){return t.mainType===Pm?e.getViewOfSeriesModel(t):e.getViewOfComponentModel(t)}var Gc=1,Uc={},Om=bt(),Mh=bt(),Ah=0,rl=1,nl=2,nr=["emphasis","blur","select"],Wc=["normal","emphasis","blur","select"],DT=10,MT=9,Dn="highlight",Ko="downplay",Ts="select",bf="unselect",ws="toggleSelect",Lh="selectchanged";function zn(e){return e!=null&&e!=="none"}function il(e,t,r){e.onHoverStateChange&&(e.hoverState||0)!==r&&e.onHoverStateChange(t),e.hoverState=r}function Bm(e){il(e,"emphasis",nl)}function Nm(e){e.hoverState===nl&&il(e,"normal",Ah)}function Ih(e){il(e,"blur",rl)}function Fm(e){e.hoverState===rl&&il(e,"normal",Ah)}function AT(e){e.selected=!0}function LT(e){e.selected=!1}function Yc(e,t,r){t(e,r)}function yr(e,t,r){Yc(e,t,r),e.isGroup&&e.traverse(function(n){Yc(n,t,r)})}function Xc(e,t){switch(t){case"emphasis":e.hoverState=nl;break;case"normal":e.hoverState=Ah;break;case"blur":e.hoverState=rl;break;case"select":e.selected=!0}}function IT(e,t,r,n){for(var i=e.style,a={},o=0;o<t.length;o++){var s=t[o],l=i[s];a[s]=l??(n&&n[s])}for(var o=0;o<e.animators.length;o++){var u=e.animators[o];u.__fromStateTransition&&u.__fromStateTransition.indexOf(r)<0&&u.targetName==="style"&&u.saveTo(a,t)}return a}function PT(e,t,r,n){var i=r&&vt(r,"select")>=0,a=!1;if(e instanceof St){var o=Om(e),s=i&&o.selectFill||o.normalFill,l=i&&o.selectStroke||o.normalStroke;if(zn(s)||zn(l)){n=n||{};var u=n.style||{};u.fill==="inherit"?(a=!0,n=N({},n),u=N({},u),u.fill=s):!zn(u.fill)&&zn(s)?(a=!0,n=N({},n),u=N({},u),u.fill=ec(s)):!zn(u.stroke)&&zn(l)&&(a||(n=N({},n),u=N({},u)),u.stroke=ec(l)),n.style=u}}if(n&&n.z2==null){a||(n=N({},n));var f=e.z2EmphasisLift;n.z2=e.z2+(f??DT)}return n}function ET(e,t,r){if(r&&r.z2==null){r=N({},r);var n=e.z2SelectLift;r.z2=e.z2+(n??MT)}return r}function RT(e,t,r){var n=vt(e.currentStates,t)>=0,i=e.style.opacity,a=n?null:IT(e,["opacity"],t,{opacity:1});r=r||{};var o=r.style||{};return o.opacity==null&&(r=N({},r),o=N({opacity:n?i:a.opacity*.1},o),r.style=o),r}function su(e,t){var r=this.states[e];if(this.style){if(e==="emphasis")return PT(this,e,t,r);if(e==="blur")return RT(this,e,r);if(e==="select")return ET(this,e,r)}return r}function kT(e){e.stateProxy=su;var t=e.getTextContent(),r=e.getTextGuideLine();t&&(t.stateProxy=su),r&&(r.stateProxy=su)}function $c(e,t){!Gm(e,t)&&!e.__highByOuter&&yr(e,Bm)}function Zc(e,t){!Gm(e,t)&&!e.__highByOuter&&yr(e,Nm)}function xs(e,t){e.__highByOuter|=1<<(t||0),yr(e,Bm)}function Cs(e,t){!(e.__highByOuter&=~(1<<(t||0)))&&yr(e,Nm)}function OT(e){yr(e,Ih)}function zm(e){yr(e,Fm)}function Hm(e){yr(e,AT)}function Vm(e){yr(e,LT)}function Gm(e,t){return e.__highDownSilentOnTouch&&t.zrByTouch}function Um(e){var t=e.getModel(),r=[],n=[];t.eachComponent(function(i,a){var o=Mh(a),s=CT(e,a),l=i==="series";!l&&n.push(s),o.isBlured&&(s.group.traverse(function(u){Fm(u)}),l&&r.push(a)),o.isBlured=!1}),D(n,function(i){i&&i.toggleBlurSeries&&i.toggleBlurSeries(r,!1,t)})}function Tf(e,t,r,n){var i=n.getModel();r=r||"coordinateSystem";function a(u,f){for(var h=0;h<f.length;h++){var v=u.getItemGraphicEl(f[h]);v&&zm(v)}}if(e!=null&&!(!t||t==="none")){var o=i.getSeriesByIndex(e),s=o.coordinateSystem;s&&s.master&&(s=s.master);var l=[];i.eachSeries(function(u){var f=o===u,h=u.coordinateSystem;h&&h.master&&(h=h.master);var v=h&&s?h===s:f;if(!(r==="series"&&!f||r==="coordinateSystem"&&!v||t==="series"&&f)){var c=n.getViewOfSeriesModel(u);if(c.group.traverse(function(m){m.__highByOuter&&f&&t==="self"||Ih(m)}),ie(t))a(u.getData(),t);else if(K(t))for(var d=xt(t),p=0;p<d.length;p++)a(u.getData(d[p]),t[d[p]]);l.push(u),Mh(u).isBlured=!0}}),i.eachComponent(function(u,f){if(u!=="series"){var h=n.getViewOfComponentModel(f);h&&h.toggleBlurSeries&&h.toggleBlurSeries(l,!0,i)}})}}function wf(e,t,r){if(!(e==null||t==null)){var n=r.getModel().getComponent(e,t);if(n){Mh(n).isBlured=!0;var i=r.getViewOfComponentModel(n);!i||!i.focusBlurEnabled||i.group.traverse(function(a){Ih(a)})}}}function BT(e,t,r){var n=e.seriesIndex,i=e.getData(t.dataType);if(i){var a=An(i,t);a=(H(a)?a[0]:a)||0;var o=i.getItemGraphicEl(a);if(!o)for(var s=i.count(),l=0;!o&&l<s;)o=i.getItemGraphicEl(l++);if(o){var u=gt(o);Tf(n,u.focus,u.blurScope,r)}else{var f=e.get(["emphasis","focus"]),h=e.get(["emphasis","blurScope"]);f!=null&&Tf(n,f,h,r)}}}function Ph(e,t,r,n){var i={focusSelf:!1,dispatchers:null};if(e==null||e==="series"||t==null||r==null)return i;var a=n.getModel().getComponent(e,t);if(!a)return i;var o=n.getViewOfComponentModel(a);if(!o||!o.findHighDownDispatchers)return i;for(var s=o.findHighDownDispatchers(r),l,u=0;u<s.length;u++)if(gt(s[u]).focus==="self"){l=!0;break}return{focusSelf:l,dispatchers:s}}function NT(e,t,r){var n=gt(e),i=Ph(n.componentMainType,n.componentIndex,n.componentHighDownName,r),a=i.dispatchers,o=i.focusSelf;a?(o&&wf(n.componentMainType,n.componentIndex,r),D(a,function(s){return $c(s,t)})):(Tf(n.seriesIndex,n.focus,n.blurScope,r),n.focus==="self"&&wf(n.componentMainType,n.componentIndex,r),$c(e,t))}function FT(e,t,r){Um(r);var n=gt(e),i=Ph(n.componentMainType,n.componentIndex,n.componentHighDownName,r).dispatchers;i?D(i,function(a){return Zc(a,t)}):Zc(e,t)}function zT(e,t,r){if(Mf(t)){var n=t.dataType,i=e.getData(n),a=An(i,t);H(a)||(a=[a]),e[t.type===ws?"toggleSelect":t.type===Ts?"select":"unselect"](a,n)}}function qc(e){var t=e.getAllData();D(t,function(r){var n=r.data,i=r.type;n.eachItemGraphicEl(function(a,o){e.isSelected(o,i)?Hm(a):Vm(a)})})}function HT(e){var t=[];return e.eachSeries(function(r){var n=r.getAllData();D(n,function(i){i.data;var a=i.type,o=r.getSelectedDataIndices();if(o.length>0){var s={dataIndex:o,seriesIndex:r.seriesIndex};a!=null&&(s.dataType=a),t.push(s)}})}),t}function xf(e,t,r){Wm(e,!0),yr(e,kT),GT(e,t,r)}function VT(e){Wm(e,!1)}function Cf(e,t,r,n){n?VT(e):xf(e,t,r)}function GT(e,t,r){var n=gt(e);t!=null?(n.focus=t,n.blurScope=r):n.focus&&(n.focus=null)}var Kc=["emphasis","blur","select"],UT={itemStyle:"getItemStyle",lineStyle:"getLineStyle",areaStyle:"getAreaStyle"};function Qc(e,t,r,n){r=r||"itemStyle";for(var i=0;i<Kc.length;i++){var a=Kc[i],o=t.getModel([a,r]),s=e.ensureState(a);s.style=o[UT[r]]()}}function Wm(e,t){var r=t===!1,n=e;e.highDownSilentOnTouch&&(n.__highDownSilentOnTouch=e.highDownSilentOnTouch),(!r||n.__highDownDispatcher)&&(n.__highByOuter=n.__highByOuter||0,n.__highDownDispatcher=!r)}function Df(e){return!!(e&&e.__highDownDispatcher)}function WT(e){var t=Uc[e];return t==null&&Gc<=32&&(t=Uc[e]=Gc++),t}function Mf(e){var t=e.type;return t===Ts||t===bf||t===ws}function Jc(e){var t=e.type;return t===Dn||t===Ko}function YT(e){var t=Om(e);t.normalFill=e.style.fill,t.normalStroke=e.style.stroke;var r=e.states.select||{};t.selectFill=r.style&&r.style.fill||null,t.selectStroke=r.style&&r.style.stroke||null}var Hn=Ln.CMD,XT=[[],[],[]],jc=Math.sqrt,$T=Math.atan2;function ZT(e,t){if(t){var r=e.data,n=e.len(),i,a,o,s,l,u,f=Hn.M,h=Hn.C,v=Hn.L,c=Hn.R,d=Hn.A,p=Hn.Q;for(o=0,s=0;o<n;){switch(i=r[o++],s=o,a=0,i){case f:a=1;break;case v:a=1;break;case h:a=3;break;case p:a=2;break;case d:var m=t[4],g=t[5],y=jc(t[0]*t[0]+t[1]*t[1]),_=jc(t[2]*t[2]+t[3]*t[3]),S=$T(-t[1]/_,t[0]/y);r[o]*=y,r[o++]+=m,r[o]*=_,r[o++]+=g,r[o++]*=y,r[o++]*=_,r[o++]+=S,r[o++]+=S,o+=2,s=o;break;case c:u[0]=r[o++],u[1]=r[o++],Ae(u,u,t),r[s++]=u[0],r[s++]=u[1],u[0]+=r[o++],u[1]+=r[o++],Ae(u,u,t),r[s++]=u[0],r[s++]=u[1]}for(l=0;l<a;l++){var b=XT[l];b[0]=r[o++],b[1]=r[o++],Ae(b,b,t),r[s++]=b[0],r[s++]=b[1]}}e.increaseVersion()}}var lu=Math.sqrt,vo=Math.sin,co=Math.cos,ki=Math.PI;function td(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function Af(e,t){return(e[0]*t[0]+e[1]*t[1])/(td(e)*td(t))}function ed(e,t){return(e[0]*t[1]<e[1]*t[0]?-1:1)*Math.acos(Af(e,t))}function rd(e,t,r,n,i,a,o,s,l,u,f){var h=l*(ki/180),v=co(h)*(e-r)/2+vo(h)*(t-n)/2,c=-1*vo(h)*(e-r)/2+co(h)*(t-n)/2,d=v*v/(o*o)+c*c/(s*s);d>1&&(o*=lu(d),s*=lu(d));var p=(i===a?-1:1)*lu((o*o*(s*s)-o*o*(c*c)-s*s*(v*v))/(o*o*(c*c)+s*s*(v*v)))||0,m=p*o*c/s,g=p*-s*v/o,y=(e+r)/2+co(h)*m-vo(h)*g,_=(t+n)/2+vo(h)*m+co(h)*g,S=ed([1,0],[(v-m)/o,(c-g)/s]),b=[(v-m)/o,(c-g)/s],T=[(-1*v-m)/o,(-1*c-g)/s],w=ed(b,T);if(Af(b,T)<=-1&&(w=ki),Af(b,T)>=1&&(w=0),w<0){var M=Math.round(w/ki*1e6)/1e6;w=ki*2+M%2*ki}f.addData(u,y,_,o,s,S,w,h,a)}var qT=/([mlvhzcqtsa])([^mlvhzcqtsa]*)/ig,KT=/-?([0-9]*\.)?[0-9]+([eE]-?[0-9]+)?/g;function QT(e){var t=new Ln;if(!e)return t;var r=0,n=0,i=r,a=n,o,s=Ln.CMD,l=e.match(qT);if(!l)return t;for(var u=0;u<l.length;u++){for(var f=l[u],h=f.charAt(0),v=void 0,c=f.match(KT)||[],d=c.length,p=0;p<d;p++)c[p]=parseFloat(c[p]);for(var m=0;m<d;){var g=void 0,y=void 0,_=void 0,S=void 0,b=void 0,T=void 0,w=void 0,M=r,C=n,x=void 0,A=void 0;switch(h){case"l":r+=c[m++],n+=c[m++],v=s.L,t.addData(v,r,n);break;case"L":r=c[m++],n=c[m++],v=s.L,t.addData(v,r,n);break;case"m":r+=c[m++],n+=c[m++],v=s.M,t.addData(v,r,n),i=r,a=n,h="l";break;case"M":r=c[m++],n=c[m++],v=s.M,t.addData(v,r,n),i=r,a=n,h="L";break;case"h":r+=c[m++],v=s.L,t.addData(v,r,n);break;case"H":r=c[m++],v=s.L,t.addData(v,r,n);break;case"v":n+=c[m++],v=s.L,t.addData(v,r,n);break;case"V":n=c[m++],v=s.L,t.addData(v,r,n);break;case"C":v=s.C,t.addData(v,c[m++],c[m++],c[m++],c[m++],c[m++],c[m++]),r=c[m-2],n=c[m-1];break;case"c":v=s.C,t.addData(v,c[m++]+r,c[m++]+n,c[m++]+r,c[m++]+n,c[m++]+r,c[m++]+n),r+=c[m-2],n+=c[m-1];break;case"S":g=r,y=n,x=t.len(),A=t.data,o===s.C&&(g+=r-A[x-4],y+=n-A[x-3]),v=s.C,M=c[m++],C=c[m++],r=c[m++],n=c[m++],t.addData(v,g,y,M,C,r,n);break;case"s":g=r,y=n,x=t.len(),A=t.data,o===s.C&&(g+=r-A[x-4],y+=n-A[x-3]),v=s.C,M=r+c[m++],C=n+c[m++],r+=c[m++],n+=c[m++],t.addData(v,g,y,M,C,r,n);break;case"Q":M=c[m++],C=c[m++],r=c[m++],n=c[m++],v=s.Q,t.addData(v,M,C,r,n);break;case"q":M=c[m++]+r,C=c[m++]+n,r+=c[m++],n+=c[m++],v=s.Q,t.addData(v,M,C,r,n);break;case"T":g=r,y=n,x=t.len(),A=t.data,o===s.Q&&(g+=r-A[x-4],y+=n-A[x-3]),r=c[m++],n=c[m++],v=s.Q,t.addData(v,g,y,r,n);break;case"t":g=r,y=n,x=t.len(),A=t.data,o===s.Q&&(g+=r-A[x-4],y+=n-A[x-3]),r+=c[m++],n+=c[m++],v=s.Q,t.addData(v,g,y,r,n);break;case"A":_=c[m++],S=c[m++],b=c[m++],T=c[m++],w=c[m++],M=r,C=n,r=c[m++],n=c[m++],v=s.A,rd(M,C,r,n,T,w,_,S,b,v,t);break;case"a":_=c[m++],S=c[m++],b=c[m++],T=c[m++],w=c[m++],M=r,C=n,r+=c[m++],n+=c[m++],v=s.A,rd(M,C,r,n,T,w,_,S,b,v,t);break}}(h==="z"||h==="Z")&&(v=s.Z,t.addData(v),r=i,n=a),o=v}return t.toStatic(),t}var Ym=(function(e){V(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.applyTransform=function(r){},t})(St);function Xm(e){return e.setData!=null}function $m(e,t){var r=QT(e),n=N({},t);return n.buildPath=function(i){var a=Xm(i);if(a&&i.canSave()){i.appendPath(r);var o=i.getContext();o&&i.rebuildPath(o,1)}else{var o=a?i.getContext():i;o&&r.rebuildPath(o,1)}},n.applyTransform=function(i){ZT(r,i),this.dirtyShape()},n}function JT(e,t){return new Ym($m(e,t))}function jT(e,t){var r=$m(e,t),n=(function(i){V(a,i);function a(o){var s=i.call(this,o)||this;return s.applyTransform=r.applyTransform,s.buildPath=r.buildPath,s}return a})(Ym);return n}function tw(e,t){for(var r=[],n=e.length,i=0;i<n;i++){var a=e[i];r.push(a.getUpdatedPathProxy(!0))}var o=new St(t);return o.createPathProxy(),o.buildPath=function(s){if(Xm(s)){s.appendPath(r);var l=s.getContext();l&&s.rebuildPath(l,1)}},o}var ew=(function(){function e(){this.cx=0,this.cy=0,this.r=0}return e})(),al=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.getDefaultShape=function(){return new ew},t.prototype.buildPath=function(r,n){r.moveTo(n.cx+n.r,n.cy),r.arc(n.cx,n.cy,n.r,0,Math.PI*2)},t})(St);al.prototype.type="circle";var rw=(function(){function e(){this.cx=0,this.cy=0,this.rx=0,this.ry=0}return e})(),Eh=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.getDefaultShape=function(){return new rw},t.prototype.buildPath=function(r,n){var i=.5522848,a=n.cx,o=n.cy,s=n.rx,l=n.ry,u=s*i,f=l*i;r.moveTo(a-s,o),r.bezierCurveTo(a-s,o-f,a-u,o-l,a,o-l),r.bezierCurveTo(a+u,o-l,a+s,o-f,a+s,o),r.bezierCurveTo(a+s,o+f,a+u,o+l,a,o+l),r.bezierCurveTo(a-u,o+l,a-s,o+f,a-s,o),r.closePath()},t})(St);Eh.prototype.type="ellipse";var Zm=Math.PI,uu=Zm*2,sn=Math.sin,Vn=Math.cos,nw=Math.acos,Ut=Math.atan2,nd=Math.abs,oa=Math.sqrt,Qi=Math.max,We=Math.min,ke=1e-4;function iw(e,t,r,n,i,a,o,s){var l=r-e,u=n-t,f=o-i,h=s-a,v=h*l-f*u;if(!(v*v<ke))return v=(f*(t-a)-h*(e-i))/v,[e+v*l,t+v*u]}function po(e,t,r,n,i,a,o){var s=e-r,l=t-n,u=(o?a:-a)/oa(s*s+l*l),f=u*l,h=-u*s,v=e+f,c=t+h,d=r+f,p=n+h,m=(v+d)/2,g=(c+p)/2,y=d-v,_=p-c,S=y*y+_*_,b=i-a,T=v*p-d*c,w=(_<0?-1:1)*oa(Qi(0,b*b*S-T*T)),M=(T*_-y*w)/S,C=(-T*y-_*w)/S,x=(T*_+y*w)/S,A=(-T*y+_*w)/S,I=M-m,L=C-g,P=x-m,R=A-g;return I*I+L*L>P*P+R*R&&(M=x,C=A),{cx:M,cy:C,x0:-f,y0:-h,x1:M*(i/b-1),y1:C*(i/b-1)}}function aw(e){var t;if(H(e)){var r=e.length;if(!r)return e;r===1?t=[e[0],e[0],0,0]:r===2?t=[e[0],e[0],e[1],e[1]]:r===3?t=e.concat(e[2]):t=e}else t=[e,e,e,e];return t}function ow(e,t){var r,n=Qi(t.r,0),i=Qi(t.r0||0,0),a=n>0,o=i>0;if(!(!a&&!o)){if(a||(n=i,i=0),i>n){var s=n;n=i,i=s}var l=t.startAngle,u=t.endAngle;if(!(isNaN(l)||isNaN(u))){var f=t.cx,h=t.cy,v=!!t.clockwise,c=nd(u-l),d=c>uu&&c%uu;if(d>ke&&(c=d),!(n>ke))e.moveTo(f,h);else if(c>uu-ke)e.moveTo(f+n*Vn(l),h+n*sn(l)),e.arc(f,h,n,l,u,!v),i>ke&&(e.moveTo(f+i*Vn(u),h+i*sn(u)),e.arc(f,h,i,u,l,v));else{var p=void 0,m=void 0,g=void 0,y=void 0,_=void 0,S=void 0,b=void 0,T=void 0,w=void 0,M=void 0,C=void 0,x=void 0,A=void 0,I=void 0,L=void 0,P=void 0,R=n*Vn(l),E=n*sn(l),F=i*Vn(u),G=i*sn(u),U=c>ke;if(U){var tt=t.cornerRadius;tt&&(r=aw(tt),p=r[0],m=r[1],g=r[2],y=r[3]);var Z=nd(n-i)/2;if(_=We(Z,g),S=We(Z,y),b=We(Z,p),T=We(Z,m),C=w=Qi(_,S),x=M=Qi(b,T),(w>ke||M>ke)&&(A=n*Vn(u),I=n*sn(u),L=i*Vn(l),P=i*sn(l),c<Zm)){var at=iw(R,E,L,P,A,I,F,G);if(at){var q=R-at[0],z=E-at[1],lt=A-at[0],k=I-at[1],B=1/sn(nw((q*lt+z*k)/(oa(q*q+z*z)*oa(lt*lt+k*k)))/2),Q=oa(at[0]*at[0]+at[1]*at[1]);C=We(w,(n-Q)/(B+1)),x=We(M,(i-Q)/(B-1))}}}if(!U)e.moveTo(f+R,h+E);else if(C>ke){var $=We(g,C),et=We(y,C),X=po(L,P,R,E,n,$,v),Y=po(A,I,F,G,n,et,v);e.moveTo(f+X.cx+X.x0,h+X.cy+X.y0),C<w&&$===et?e.arc(f+X.cx,h+X.cy,C,Ut(X.y0,X.x0),Ut(Y.y0,Y.x0),!v):($>0&&e.arc(f+X.cx,h+X.cy,$,Ut(X.y0,X.x0),Ut(X.y1,X.x1),!v),e.arc(f,h,n,Ut(X.cy+X.y1,X.cx+X.x1),Ut(Y.cy+Y.y1,Y.cx+Y.x1),!v),et>0&&e.arc(f+Y.cx,h+Y.cy,et,Ut(Y.y1,Y.x1),Ut(Y.y0,Y.x0),!v))}else e.moveTo(f+R,h+E),e.arc(f,h,n,l,u,!v);if(!(i>ke)||!U)e.lineTo(f+F,h+G);else if(x>ke){var $=We(p,x),et=We(m,x),X=po(F,G,A,I,i,-et,v),Y=po(R,E,L,P,i,-$,v);e.lineTo(f+X.cx+X.x0,h+X.cy+X.y0),x<M&&$===et?e.arc(f+X.cx,h+X.cy,x,Ut(X.y0,X.x0),Ut(Y.y0,Y.x0),!v):(et>0&&e.arc(f+X.cx,h+X.cy,et,Ut(X.y0,X.x0),Ut(X.y1,X.x1),!v),e.arc(f,h,i,Ut(X.cy+X.y1,X.cx+X.x1),Ut(Y.cy+Y.y1,Y.cx+Y.x1),v),$>0&&e.arc(f+Y.cx,h+Y.cy,$,Ut(Y.y1,Y.x1),Ut(Y.y0,Y.x0),!v))}else e.lineTo(f+F,h+G),e.arc(f,h,i,u,l,v)}e.closePath()}}}var sw=(function(){function e(){this.cx=0,this.cy=0,this.r0=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0,this.cornerRadius=0}return e})(),ol=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.getDefaultShape=function(){return new sw},t.prototype.buildPath=function(r,n){ow(r,n)},t.prototype.isZeroArea=function(){return this.shape.startAngle===this.shape.endAngle||this.shape.r===this.shape.r0},t})(St);ol.prototype.type="sector";var lw=(function(){function e(){this.cx=0,this.cy=0,this.r=0,this.r0=0}return e})(),Rh=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.getDefaultShape=function(){return new lw},t.prototype.buildPath=function(r,n){var i=n.cx,a=n.cy,o=Math.PI*2;r.moveTo(i+n.r,a),r.arc(i,a,n.r,0,o,!1),r.moveTo(i+n.r0,a),r.arc(i,a,n.r0,0,o,!0)},t})(St);Rh.prototype.type="ring";function uw(e,t,r,n){var i=[],a=[],o=[],s=[],l,u,f,h;if(n){f=[1/0,1/0],h=[-1/0,-1/0];for(var v=0,c=e.length;v<c;v++)Jn(f,f,e[v]),jn(h,h,e[v]);Jn(f,f,n[0]),jn(h,h,n[1])}for(var v=0,c=e.length;v<c;v++){var d=e[v];if(r)l=e[v?v-1:c-1],u=e[(v+1)%c];else if(v===0||v===c-1){i.push(w1(e[v]));continue}else l=e[v-1],u=e[v+1];x1(a,u,l),xl(a,a,t);var p=Zu(d,l),m=Zu(d,u),g=p+m;g!==0&&(p/=g,m/=g),xl(o,a,-p),xl(s,a,m);var y=Nv([],d,o),_=Nv([],d,s);n&&(jn(y,y,f),Jn(y,y,h),jn(_,_,f),Jn(_,_,h)),i.push(y),i.push(_)}return r&&i.push(i.shift()),i}function qm(e,t,r){var n=t.smooth,i=t.points;if(i&&i.length>=2){if(n){var a=uw(i,n,r,t.smoothConstraint);e.moveTo(i[0][0],i[0][1]);for(var o=i.length,s=0;s<(r?o:o-1);s++){var l=a[s*2],u=a[s*2+1],f=i[(s+1)%o];e.bezierCurveTo(l[0],l[1],u[0],u[1],f[0],f[1])}}else{e.moveTo(i[0][0],i[0][1]);for(var s=1,h=i.length;s<h;s++)e.lineTo(i[s][0],i[s][1])}r&&e.closePath()}}var fw=(function(){function e(){this.points=null,this.smooth=0,this.smoothConstraint=null}return e})(),kh=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.getDefaultShape=function(){return new fw},t.prototype.buildPath=function(r,n){qm(r,n,!0)},t})(St);kh.prototype.type="polygon";var hw=(function(){function e(){this.points=null,this.percent=1,this.smooth=0,this.smoothConstraint=null}return e})(),Oh=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new hw},t.prototype.buildPath=function(r,n){qm(r,n,!1)},t})(St);Oh.prototype.type="polyline";var vw={},cw=(function(){function e(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.percent=1}return e})(),Fr=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new cw},t.prototype.buildPath=function(r,n){var i,a,o,s;if(this.subPixelOptimize){var l=Lm(vw,n,this.style);i=l.x1,a=l.y1,o=l.x2,s=l.y2}else i=n.x1,a=n.y1,o=n.x2,s=n.y2;var u=n.percent;u!==0&&(r.moveTo(i,a),u<1&&(o=i*(1-u)+o*u,s=a*(1-u)+s*u),r.lineTo(o,s))},t.prototype.pointAt=function(r){var n=this.shape;return[n.x1*(1-r)+n.x2*r,n.y1*(1-r)+n.y2*r]},t})(St);Fr.prototype.type="line";var jt=[],dw=(function(){function e(){this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.cpx1=0,this.cpy1=0,this.percent=1}return e})();function id(e,t,r){var n=e.cpx2,i=e.cpy2;return n!=null||i!=null?[(r?Kv:Ht)(e.x1,e.cpx1,e.cpx2,e.x2,t),(r?Kv:Ht)(e.y1,e.cpy1,e.cpy2,e.y2,t)]:[(r?Qv:ee)(e.x1,e.cpx1,e.x2,t),(r?Qv:ee)(e.y1,e.cpy1,e.y2,t)]}var Bh=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new dw},t.prototype.buildPath=function(r,n){var i=n.x1,a=n.y1,o=n.x2,s=n.y2,l=n.cpx1,u=n.cpy1,f=n.cpx2,h=n.cpy2,v=n.percent;v!==0&&(r.moveTo(i,a),f==null||h==null?(v<1&&(ps(i,l,o,v,jt),l=jt[1],o=jt[2],ps(a,u,s,v,jt),u=jt[1],s=jt[2]),r.quadraticCurveTo(l,u,o,s)):(v<1&&(ds(i,l,f,o,v,jt),l=jt[1],f=jt[2],o=jt[3],ds(a,u,h,s,v,jt),u=jt[1],h=jt[2],s=jt[3]),r.bezierCurveTo(l,u,f,h,o,s)))},t.prototype.pointAt=function(r){return id(this.shape,r,!1)},t.prototype.tangentAt=function(r){var n=id(this.shape,r,!0);return M1(n,n)},t})(St);Bh.prototype.type="bezier-curve";var pw=(function(){function e(){this.cx=0,this.cy=0,this.r=0,this.startAngle=0,this.endAngle=Math.PI*2,this.clockwise=!0}return e})(),sl=(function(e){V(t,e);function t(r){return e.call(this,r)||this}return t.prototype.getDefaultStyle=function(){return{stroke:"#000",fill:null}},t.prototype.getDefaultShape=function(){return new pw},t.prototype.buildPath=function(r,n){var i=n.cx,a=n.cy,o=Math.max(n.r,0),s=n.startAngle,l=n.endAngle,u=n.clockwise,f=Math.cos(s),h=Math.sin(s);r.moveTo(f*o+i,h*o+a),r.arc(i,a,o,s,l,!u)},t})(St);sl.prototype.type="arc";var gw=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type="compound",r}return t.prototype._updatePathDirty=function(){for(var r=this.shape.paths,n=this.shapeChanged(),i=0;i<r.length;i++)n=n||r[i].shapeChanged();n&&this.dirtyShape()},t.prototype.beforeBrush=function(){this._updatePathDirty();for(var r=this.shape.paths||[],n=this.getGlobalScale(),i=0;i<r.length;i++)r[i].path||r[i].createPathProxy(),r[i].path.setScale(n[0],n[1],r[i].segmentIgnoreThreshold)},t.prototype.buildPath=function(r,n){for(var i=n.paths||[],a=0;a<i.length;a++)i[a].buildPath(r,i[a].shape,!0)},t.prototype.afterBrush=function(){for(var r=this.shape.paths||[],n=0;n<r.length;n++)r[n].pathUpdated()},t.prototype.getBoundingRect=function(){return this._updatePathDirty.call(this),St.prototype.getBoundingRect.call(this)},t})(St),Km=(function(){function e(t){this.colorStops=t||[]}return e.prototype.addColorStop=function(t,r){this.colorStops.push({offset:t,color:r})},e})(),Qm=(function(e){V(t,e);function t(r,n,i,a,o,s){var l=e.call(this,o)||this;return l.x=r??0,l.y=n??0,l.x2=i??1,l.y2=a??0,l.type="linear",l.global=s||!1,l}return t})(Km),mw=(function(e){V(t,e);function t(r,n,i,a,o){var s=e.call(this,a)||this;return s.x=r??.5,s.y=n??.5,s.r=i??.5,s.type="radial",s.global=o||!1,s}return t})(Km),fu=Math.min,yw=Math.max,go=Math.abs,ln=[0,0],un=[0,0],Bt=Vg(),mo=Bt.minTv,yo=Bt.maxTv,Jm=(function(){function e(t,r){this._corners=[],this._axes=[],this._origin=[0,0];for(var n=0;n<4;n++)this._corners[n]=new _t;for(var n=0;n<2;n++)this._axes[n]=new _t;t&&this.fromBoundingRect(t,r)}return e.prototype.fromBoundingRect=function(t,r){var n=this._corners,i=this._axes,a=t.x,o=t.y,s=a+t.width,l=o+t.height;if(n[0].set(a,o),n[1].set(s,o),n[2].set(s,l),n[3].set(a,l),r)for(var u=0;u<4;u++)n[u].transform(r);_t.sub(i[0],n[1],n[0]),_t.sub(i[1],n[3],n[0]),i[0].normalize(),i[1].normalize();for(var u=0;u<2;u++)this._origin[u]=i[u].dot(n[0])},e.prototype.intersect=function(t,r,n){var i=!0,a=!r;return r&&_t.set(r,0,0),Bt.reset(n,!a),!this._intersectCheckOneSide(this,t,a,1)&&(i=!1,a)||!this._intersectCheckOneSide(t,this,a,-1)&&(i=!1,a)||!a&&!Bt.negativeSize&&_t.copy(r,i?Bt.useDir?Bt.dirMinTv:mo:yo),i},e.prototype._intersectCheckOneSide=function(t,r,n,i){for(var a=!0,o=0;o<2;o++){var s=t._axes[o];if(t._getProjMinMaxOnAxis(o,t._corners,ln),t._getProjMinMaxOnAxis(o,r._corners,un),Bt.negativeSize||ln[1]<un[0]||ln[0]>un[1]){if(a=!1,Bt.negativeSize||n)return a;var l=go(un[0]-ln[1]),u=go(ln[0]-un[1]);fu(l,u)>yo.len()&&(l<u?_t.scale(yo,s,-l*i):_t.scale(yo,s,u*i))}else if(!n){var l=go(un[0]-ln[1]),u=go(ln[0]-un[1]);(Bt.useDir||fu(l,u)<mo.len())&&((l<u||!Bt.bidirectional)&&(_t.scale(mo,s,l*i),Bt.useDir&&Bt.calcDirMTV()),(l>=u||!Bt.bidirectional)&&(_t.scale(mo,s,-u*i),Bt.useDir&&Bt.calcDirMTV()))}}return a},e.prototype._getProjMinMaxOnAxis=function(t,r,n){for(var i=this._axes[t],a=this._origin,o=r[0].dot(i)+a[t],s=o,l=o,u=1;u<r.length;u++){var f=r[u].dot(i)+a[t];s=fu(f,s),l=yw(f,l)}n[0]=s+Bt.touchThreshold,n[1]=l-Bt.touchThreshold,Bt.negativeSize=n[1]<n[0]},e})(),jm=0,_w=1,Sw=2,bw=1,Qo=0,Tw=[],ww=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.notClear=!0,r.incremental=_w,r._displayables=[],r._temporaryDisplayables=[],r._cursor=0,r}return t.prototype.traverse=function(r,n){r.call(n,this)},t.prototype.useStyle=function(){this.style={}},t.prototype._useHoverStyle=function(){this.__hoverStyle=null},t.prototype.getCursor=function(){return this._cursor},t.prototype.innerAfterBrush=function(){this._cursor=this._displayables.length},t.prototype.clearDisplaybles=function(){this._displayables=[],this._temporaryDisplayables=[],this._cursor=0,this.markRedraw(),this.notClear=!1},t.prototype.clearTemporalDisplayables=function(){this._temporaryDisplayables=[]},t.prototype.addDisplayable=function(r,n){n?this._temporaryDisplayables.push(r):this._displayables.push(r),this.markRedraw()},t.prototype.addDisplayables=function(r,n){n=n||!1;for(var i=0;i<r.length;i++)this.addDisplayable(r[i],n)},t.prototype.getDisplayables=function(){return this._displayables},t.prototype.getTemporalDisplayables=function(){return this._temporaryDisplayables},t.prototype.eachPendingDisplayable=function(r){for(var n=this._cursor;n<this._displayables.length;n++)r&&r(this._displayables[n]);for(var n=0;n<this._temporaryDisplayables.length;n++)r&&r(this._temporaryDisplayables[n])},t.prototype.update=function(){this.updateTransform();for(var r=this._cursor;r<this._displayables.length;r++){var n=this._displayables[r];n.parent=this,n.update(),n.parent=null}for(var r=0;r<this._temporaryDisplayables.length;r++){var n=this._temporaryDisplayables[r];n.parent=this,n.update(),n.parent=null}},t.prototype.getBoundingRect=function(){if(!this._rect){for(var r=new it(1/0,1/0,-1/0,-1/0),n=0;n<this._displayables.length;n++){var i=this._displayables[n],a=i.getBoundingRect().clone();i.needLocalTransform()&&a.applyTransform(i.getLocalTransform(Tw)),r.union(a)}this._rect=r}return this._rect},t.prototype.contain=function(r,n){var i=this.transformCoordToLocal(r,n),a=this.getBoundingRect();if(a.contain(i[0],i[1]))for(var o=0;o<this._displayables.length;o++){var s=this._displayables[o];if(s.contain(r,n))return!0}return!1},t})(Va),xw=bt();function Cw(e,t,r,n,i){var a;if(t&&t.ecModel){var o=t.ecModel.getUpdatePayload();a=o&&o.animation}var s=t&&t.isAnimationEnabled(),l=e==="update";if(s){var u=void 0,f=void 0,h=void 0;n?(u=j(n.duration,200),f=j(n.easing,"cubicOut"),h=0):(u=t.getShallow(l?"animationDurationUpdate":"animationDuration"),f=t.getShallow(l?"animationEasingUpdate":"animationEasing"),h=t.getShallow(l?"animationDelayUpdate":"animationDelay")),a&&(a.duration!=null&&(u=a.duration),a.easing!=null&&(f=a.easing),a.delay!=null&&(h=a.delay)),ot(h)&&(h=h(r,i)),ot(u)&&(u=u(r));var v={duration:u||0,delay:h,easing:f};return v}else return null}function Nh(e,t,r,n,i,a,o){var s=!1,l;ot(i)?(o=a,a=i,i=null):K(i)&&(a=i.cb,o=i.during,s=i.isFrom,l=i.removeOpt,i=i.dataIndex);var u=e==="leave";u||t.stopAnimation("leave");var f=Cw(e,n,i,u?l||{}:null,n&&n.getAnimationDelayParams?n.getAnimationDelayParams(t,i):null);if(f&&f.duration>0){var h=f.duration,v=f.delay,c=f.easing,d={duration:h,delay:v||0,easing:c,done:a,force:!!a||!!o,setToFinal:!u,scope:e,during:o};s?t.animateFrom(r,d):t.animateTo(r,d)}else t.stopAnimation(),!s&&t.attr(r),o&&o(1),a&&a()}function zr(e,t,r,n,i,a){Nh("update",e,t,r,n,i,a)}function Ua(e,t,r,n,i,a){Nh("enter",e,t,r,n,i,a)}function sa(e){if(!e.__zr)return!0;for(var t=0;t<e.animators.length;t++){var r=e.animators[t];if(r.scope==="leave")return!0}return!1}function Ds(e,t,r,n,i,a){sa(e)||Nh("leave",e,t,r,n,i,a)}function ad(e,t,r,n){e.removeTextContent(),e.removeTextGuideLine(),Ds(e,{style:{opacity:0}},t,r,n)}function Dw(e,t,r){function n(){e.parent&&e.parent.remove(e)}e.isGroup?e.traverse(function(i){i.isGroup||ad(i,t,r,n)}):ad(e,t,r,n)}function Mw(e){xw(e).oldStyle=e.style}var Lf={},mn=["x","y"],Sa=["width","height"],ty=0,ey=1,Fh=2;function Aw(e){return St.extend(e)}var Lw=jT;function Iw(e,t){return Lw(e,t)}function Fe(e,t){Lf[e]=t}function Pw(e){if(Lf.hasOwnProperty(e))return Lf[e]}function zh(e,t,r,n){var i=JT(e,t);return r&&(n==="center"&&(r=ny(r,i.getBoundingRect())),iy(i,r)),i}function ry(e,t,r){var n=new Wr({style:{image:e,x:t.x,y:t.y,width:t.width,height:t.height},onload:function(i){if(r==="center"){var a={width:i.width,height:i.height};n.setStyle(ny(t,a))}}});return n}function ny(e,t){var r=t.width/t.height,n=e.height*r,i;n<=e.width?i=e.height:(n=e.width,i=n/r);var a=e.x+e.width/2,o=e.y+e.height/2;return{x:a-n/2,y:o-i/2,width:n,height:i}}var Ew=tw;function iy(e,t){if(e.applyTransform){var r=e.getBoundingRect(),n=r.calculateTransform(t);e.applyTransform(n)}}function ba(e,t){return Lm(e,e,{lineWidth:t}),e}function Rw(e,t){return Im(e,e,t),e}var kw=Sn;function Ow(e,t){for(var r=ka([]);e&&e!==t;)ra(r,e.getLocalTransform(),r),e=e.parent;return r}function Hh(e,t,r){return t&&!ie(t)&&(t=Na.getLocalTransform(t)),r&&(t=Oa([],t)),Ae([],e,t)}function Bw(e,t,r){var n=t[4]===0||t[5]===0||t[0]===0?1:Nt(2*t[4]/t[0]),i=t[4]===0||t[5]===0||t[2]===0?1:Nt(2*t[4]/t[2]),a=[e==="left"?-n:e==="right"?n:0,e==="top"?-i:e==="bottom"?i:0];return a=Hh(a,t,r),Nt(a[0])>Nt(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"}function od(e){return!e.isGroup}function Nw(e){return e.shape!=null}function ay(e,t,r){if(!e||!t)return;function n(o){var s={};return o.traverse(function(l){od(l)&&l.anid&&(s[l.anid]=l)}),s}function i(o){var s={x:o.x,y:o.y,rotation:o.rotation};return Nw(o)&&(s.shape=ut(o.shape)),s}var a=n(e);t.traverse(function(o){if(od(o)&&o.anid){var s=a[o.anid];if(s){var l=i(o);o.attr(i(s)),zr(o,l,r,gt(o).dataIndex)}}})}function Fw(e,t){return rt(e,function(r){var n=r[0];n=mt(n,t.x),n=he(n,t.x+t.width);var i=r[1];return i=mt(i,t.y),i=he(i,t.y+t.height),[n,i]})}function zw(e,t){var r=mt(e.x,t.x),n=he(e.x+e.width,t.x+t.width),i=mt(e.y,t.y),a=he(e.y+e.height,t.y+t.height);if(n>=r&&a>=i)return{x:r,y:i,width:n-r,height:a-i}}function Vh(e,t,r){var n=N({rectHover:!0},t),i=n.style={strokeNoScale:!0};if(r=r||{x:-1,y:-1,width:2,height:2},e)return e.indexOf("image://")===0?(i.image=e.slice(8),yt(i,r),new Wr(n)):zh(e.replace("path://",""),n,r,"center")}function Hw(e,t,r,n,i){for(var a=0,o=i[i.length-1];a<i.length;a++){var s=i[a];if(oy(e,t,r,n,s[0],s[1],o[0],o[1]))return!0;o=s}}function oy(e,t,r,n,i,a,o,s){var l=r-e,u=n-t,f=o-i,h=s-a,v=hu(f,h,l,u);if(Vw(v))return!1;var c=e-i,d=t-a,p=hu(c,d,l,u)/v;if(p<0||p>1)return!1;var m=hu(c,d,f,h)/v;return!(m<0||m>1)}function hu(e,t,r,n){return e*n-r*t}function Vw(e){return e<=1e-6&&e>=-1e-6}function Ms(e,t,r,n,i){return t==null||(Ct(t)?Tt[0]=Tt[1]=Tt[2]=Tt[3]=t:(Tt[0]=t[0],Tt[1]=t[1],Tt[2]=t[2],Tt[3]=t[3]),n&&(Tt[0]=mt(0,Tt[0]),Tt[1]=mt(0,Tt[1]),Tt[2]=mt(0,Tt[2]),Tt[3]=mt(0,Tt[3])),r&&(Tt[0]=-Tt[0],Tt[1]=-Tt[1],Tt[2]=-Tt[2],Tt[3]=-Tt[3]),sd(e,Tt,"x","width",3,1,i&&i[0]||0),sd(e,Tt,"y","height",0,2,i&&i[1]||0)),e}var Tt=[0,0,0,0];function sd(e,t,r,n,i,a,o){var s=t[a]+t[i],l=e[n];e[n]+=s,o=mt(0,he(o,l)),e[n]<o?(e[n]=o,e[r]+=t[i]>=0?-t[i]:t[a]>=0?l+t[a]:Nt(s)>1e-8?(l-o)*t[i]/s:0):e[r]-=t[i]}function ll(e){var t=e.itemTooltipOption,r=e.componentModel,n=e.itemName,i=W(t)?{formatter:t}:t,a=r.mainType,o=r.componentIndex,s={componentType:a,name:n,$vars:["name"]};s[a+"Index"]=o;var l=e.formatterParamsExtra;l&&D(xt(l),function(f){fe(s,f)||(s[f]=l[f],s.$vars.push(f))});var u=gt(e.el);u.componentMainType=a,u.componentIndex=o,u.tooltipConfig={name:n,option:yt({content:n,encodeHTMLContent:!0,formatterParams:s},i)}}function If(e,t){var r;e.isGroup&&(r=t(e)),r||e.traverse(t)}function Gh(e,t){if(e)if(H(e))for(var r=0;r<e.length;r++)If(e[r],t);else If(e,t)}function Uh(e){return!e||Nt(e[1])<_o&&Nt(e[2])<_o||Nt(e[0])<_o&&Nt(e[3])<_o}var _o=1e-5;function Ta(e,t){return e?it.copy(e,t):t.clone()}function Wh(e,t){return t?gh(e||qe(),t):void 0}function sy(e){return{z:e.get("z")||0,zlevel:e.get("zlevel")||0}}function Gw(e){var t=-1/0,r=1/0;If(e,function(a){n(a),n(a.getTextContent()),n(a.getTextGuideLine())});function n(a){if(!(!a||a.isGroup)){var o=a.currentStates;if(o.length)for(var s=0;s<o.length;s++)i(a.states[o[s]]);i(a)}}function i(a){if(a){var o=a.z2;o>t&&(t=o),o<r&&(r=o)}}return r>t&&(r=t=0),{min:r,max:t}}function ly(e,t,r){uy(e,t,r,-1/0)}function uy(e,t,r,n){if(e.ignoreModelZ)return n;var i=e.getTextContent(),a=e.getTextGuideLine(),o=e.isGroup;if(o)for(var s=e.childrenRef(),l=0;l<s.length;l++)n=mt(uy(s[l],t,r,n),n);else e.z=t,e.zlevel=r,n=mt(e.z2||0,n);if(i&&(i.z=t,i.zlevel=r,isFinite(n)&&(i.z2=n+2)),a){var u=e.textGuideLineConfig;a.z=t,a.zlevel=r,isFinite(n)&&(a.z2=n+(u&&u.showAbove?1:-1))}return n}function Uw(e){return e.animation={duration:0},e}function Ww(e,t){return t?gh(Ji.transform,t):ka(Ji.transform),Ji.decomposeTransform(),ys(e,Ji),e}var Ji=new Na;Ji.transform=qe();function Yw(e){var t=e.getZr().painter;return t.getType()==="canvas"?t:null}Fe("circle",al);Fe("ellipse",Eh);Fe("sector",ol);Fe("ring",Rh);Fe("polygon",kh);Fe("polyline",Oh);Fe("rect",Rt);Fe("line",Fr);Fe("bezierCurve",Bh);Fe("arc",sl);const Xw=Object.freeze(Object.defineProperty({__proto__:null,Arc:sl,BezierCurve:Bh,BoundingRect:it,Circle:al,CompoundPath:gw,Ellipse:Eh,Group:Vt,HOVER_LAYER_FOR_INCREMENTAL:Fh,HOVER_LAYER_FROM_THRESHOLD:ey,HOVER_LAYER_NO:ty,Image:Wr,IncrementalDisplayable:ww,Line:Fr,LinearGradient:Qm,OrientedBoundingRect:Jm,Path:St,Point:_t,Polygon:kh,Polyline:Oh,RadialGradient:mw,Rect:Rt,Ring:Rh,Sector:ol,Text:oe,WH:Sa,XY:mn,applyTransform:Hh,calcZ2Range:Gw,clipPointsByRect:Fw,clipRectByRect:zw,createIcon:Vh,decomposeTransform:Ww,ensureCopyRect:Ta,ensureCopyTransform:Wh,expandOrShrinkRect:Ms,extendPath:Iw,extendShape:Aw,getCurrentCanvasPainter:Yw,getShapeClass:Pw,getTransform:Ow,groupTransition:ay,initProps:Ua,isBoundingRectAxisAligned:Uh,isElementRemoved:sa,lineLineIntersect:oy,linePolygonIntersect:Hw,makeImage:ry,makePath:zh,mergePath:Ew,payloadDisableAnimation:Uw,registerShape:Fe,removeElement:Ds,removeElementWithFadeOut:Dw,resizePath:iy,retrieveZInfo:sy,setTooltipConfig:ll,subPixelOptimize:kw,subPixelOptimizeLine:ba,subPixelOptimizeRect:Rw,transformDirection:Bw,traverseElements:Gh,traverseUpdateZ:ly,updateProps:zr},Symbol.toStringTag,{value:"Module"}));var ul={};function $w(e,t){for(var r=0;r<nr.length;r++){var n=nr[r],i=t[n],a=e.ensureState(n);a.style=a.style||{},a.style.text=i}var o=e.currentStates.slice();e.clearStates(!0),e.setStyle({text:t.normal}),e.useStates(o,!0)}function ld(e,t,r){var n=e.labelFetcher,i=e.labelDataIndex,a=e.labelDimIndex,o=t.normal,s;n&&(s=n.getFormattedLabel(i,"normal",null,a,o&&o.get("formatter"),r!=null?{interpolatedValue:r}:null)),s==null&&(s=ot(e.defaultText)?e.defaultText(i,e,r):e.defaultText);for(var l={normal:s},u=0;u<nr.length;u++){var f=nr[u],h=t[f];l[f]=j(n?n.getFormattedLabel(i,f,null,a,h&&h.get("formatter")):null,s)}return l}function Yh(e,t,r,n){r=r||ul;for(var i=e instanceof oe,a=!1,o=0;o<Wc.length;o++){var s=t[Wc[o]];if(s&&s.getShallow("show")){a=!0;break}}var l=i?e:e.getTextContent();if(a){i||(l||(l=new oe,e.setTextContent(l)),e.stateProxy&&(l.stateProxy=e.stateProxy));var u=ld(r,t),f=t.normal,h=!!f.getShallow("show"),v=mi(f,n&&n.normal,r,!1,!i);v.text=u.normal,i||e.setTextConfig(ud(f,r,!1));for(var o=0;o<nr.length;o++){var c=nr[o],s=t[c];if(s){var d=l.ensureState(c),p=!!j(s.getShallow("show"),h);if(p!==h&&(d.ignore=!p),d.style=mi(s,n&&n[c],r,!0,!i),d.style.text=u[c],!i){var m=e.ensureState(c);m.textConfig=ud(s,r,!0)}}}l.silent=!!f.getShallow("silent"),l.style.x!=null&&(v.x=l.style.x),l.style.y!=null&&(v.y=l.style.y),l.ignore=!h,l.useStyle(v),l.dirty(),r.enableTextSetter&&(fy(l).setLabelText=function(g){var y=ld(r,t,g);$w(l,y)})}else l&&(l.ignore=!0);e.dirty()}function Xh(e,t){t=t||"label";for(var r={normal:e.getModel(t)},n=0;n<nr.length;n++){var i=nr[n];r[i]=e.getModel([i,t])}return r}function mi(e,t,r,n,i){var a={};return Zw(a,e,r,n,i),t&&N(a,t),a}function ud(e,t,r){t=t||{};var n={},i,a=e.getShallow("rotate"),o=j(e.getShallow("distance"),r?null:5),s=e.getShallow("offset");return i=e.getShallow("position")||(r?null:"inside"),i==="outside"&&(i=t.defaultOutsidePosition||"top"),i!=null&&(n.position=i),s!=null&&(n.offset=s),a!=null&&(a*=Math.PI/180,n.rotation=a),o!=null&&(n.distance=o),n.outsideFill=e.get("color")==="inherit"?t.inheritColor||null:"auto",t.autoOverflowArea!=null&&(n.autoOverflowArea=t.autoOverflowArea),t.layoutRect!=null&&(n.layoutRect=t.layoutRect),n}function Zw(e,t,r,n,i){r=r||ul;var a=t.ecModel,o=a&&a.option.textStyle,s=qw(t),l;if(s){l={};var u="richInheritPlainLabel",f=j(t.get(u),a?a.get(u):void 0);for(var h in s)if(s.hasOwnProperty(h)){var v=t.getModel(["rich",h]);cd(l[h]={},v,o,t,f,r,n,i,!1,!0)}}l&&(e.rich=l);var c=t.get("overflow");c&&(e.overflow=c);var d=t.get("lineOverflow");d&&(e.lineOverflow=d);var p=e,m=t.get("minMargin");if(m!=null)m=Ct(m)?m/2:0,p.margin=[m,m,m,m],p.__marginType=ni.minMargin;else{var g=t.get("textMargin");g!=null&&(p.margin=dh(g),p.__marginType=ni.textMargin)}cd(e,t,o,null,null,r,n,i,!0,!1)}function qw(e){for(var t;e&&e!==e.ecModel;){var r=(e.option||ul).rich;if(r){t=t||{};for(var n=xt(r),i=0;i<n.length;i++){var a=n[i];t[a]=1}}e=e.parentModel}return t}var fd=["fontStyle","fontWeight","fontSize","fontFamily","textShadowColor","textShadowBlur","textShadowOffsetX","textShadowOffsetY"],hd=["align","lineHeight","width","height","tag","verticalAlign","ellipsis"],vd=["padding","borderWidth","borderRadius","borderDashOffset","backgroundColor","borderColor","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];function cd(e,t,r,n,i,a,o,s,l,u){r=!o&&r||ul;var f=a&&a.inheritColor,h=t.getShallow("color"),v=t.getShallow("textBorderColor"),c=j(t.getShallow("opacity"),r.opacity);(h==="inherit"||h==="auto")&&(f?h=f:h=null),(v==="inherit"||v==="auto")&&(f?v=f:v=null),s||(h=h||r.color,v=v||r.textBorderColor),h!=null&&(e.fill=h),v!=null&&(e.stroke=v);var d=j(t.getShallow("textBorderWidth"),r.textBorderWidth);d!=null&&(e.lineWidth=d);var p=j(t.getShallow("textBorderType"),r.textBorderType);p!=null&&(e.lineDash=p);var m=j(t.getShallow("textBorderDashOffset"),r.textBorderDashOffset);m!=null&&(e.lineDashOffset=m),!o&&c==null&&!u&&(c=a&&a.defaultOpacity),c!=null&&(e.opacity=c),!o&&!s&&e.fill==null&&a.inheritColor&&(e.fill=a.inheritColor);for(var g=0;g<fd.length;g++){var y=fd[g],_=i!==!1&&n?ai(t.getShallow(y),n.getShallow(y),r[y]):j(t.getShallow(y),r[y]);_!=null&&(e[y]=_)}for(var g=0;g<hd.length;g++){var y=hd[g],_=t.getShallow(y);_!=null&&(e[y]=_)}if(e.verticalAlign==null){var S=t.getShallow("baseline");S!=null&&(e.verticalAlign=S)}if(!l||!a.disableBox){for(var g=0;g<vd.length;g++){var y=vd[g],_=t.getShallow(y);_!=null&&(e[y]=_)}var b=t.getShallow("borderType");b!=null&&(e.borderDash=b),(e.backgroundColor==="auto"||e.backgroundColor==="inherit")&&f&&(e.backgroundColor=f),(e.borderColor==="auto"||e.borderColor==="inherit")&&f&&(e.borderColor=f)}}function Kw(e,t){var r=t&&t.getModel("textStyle");return $e([e.fontStyle||r&&r.getShallow("fontStyle")||"",e.fontWeight||r&&r.getShallow("fontWeight")||"",(e.fontSize||r&&r.getShallow("fontSize")||12)+"px",e.fontFamily||r&&r.getShallow("fontFamily")||"sans-serif"].join(" "))}var fy=bt(),ni={minMargin:1,textMargin:2},Qw=["textStyle","color"],vu=["fontStyle","fontWeight","fontSize","fontFamily","padding","lineHeight","rich","width","height","overflow"],cu=new oe,Jw=(function(){function e(){}return e.prototype.getTextColor=function(t){var r=this.ecModel;return this.getShallow("color")||(!t&&r?r.get(Qw):null)},e.prototype.getFont=function(){return Kw({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},e.prototype.getTextRect=function(t){for(var r={text:t,verticalAlign:this.getShallow("verticalAlign")||this.getShallow("baseline")},n=0;n<vu.length;n++)r[vu[n]]=this.getShallow(vu[n]);return cu.useStyle(r),cu.update(),cu.getBoundingRect()},e})(),hy=[["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","type"],["lineDashOffset","dashOffset"],["lineCap","cap"],["lineJoin","join"],["miterLimit"]],jw=_a(hy),tx=(function(){function e(){}return e.prototype.getLineStyle=function(t){return jw(this,t)},e})(),vy=[["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["lineDash","borderType"],["lineDashOffset","borderDashOffset"],["lineCap","borderCap"],["lineJoin","borderJoin"],["miterLimit","borderMiterLimit"]],ex=_a(vy),rx=(function(){function e(){}return e.prototype.getItemStyle=function(t,r){return ex(this,t,r)},e})(),Mt=(function(){function e(t,r,n){this.parentModel=r,this.ecModel=n,this.option=t}return e.prototype.init=function(t,r,n){},e.prototype.mergeOption=function(t,r){ct(this.option,t,!0)},e.prototype.get=function(t,r){return t==null?this.option:this._doGet(this.parsePath(t),!r&&this.parentModel)},e.prototype.getShallow=function(t,r){var n=this.option,i=n==null?n:n[t];if(i==null&&!r){var a=this.parentModel;a&&(i=a.getShallow(t))}return i},e.prototype.getModel=function(t,r){var n=t!=null,i=n?this.parsePath(t):null,a=n?this._doGet(i):this.option;return r=r||this.parentModel&&this.parentModel.getModel(this.resolveParentPath(i)),new e(a,r,this.ecModel)},e.prototype.isEmpty=function(){return this.option==null},e.prototype.restoreData=function(){},e.prototype.clone=function(){var t=this.constructor;return new t(ut(this.option))},e.prototype.parsePath=function(t){return typeof t=="string"?t.split("."):t},e.prototype.resolveParentPath=function(t){return t},e.prototype.isAnimationEnabled=function(){if(!st.node&&this.option){if(this.option.animation!=null)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}},e.prototype._doGet=function(t,r){var n=this.option;if(!t)return n;for(var i=0;i<t.length&&!(t[i]&&(n=n&&typeof n=="object"?n[t[i]]:null,n==null));i++);return n==null&&r&&(n=r._doGet(this.resolveParentPath(t),r.parentModel)),n},e})();Ch(Mt);Lb(Mt);ar(Mt,tx);ar(Mt,rx);ar(Mt,kb);ar(Mt,Jw);var nx=Math.round(Math.random()*10);function fl(e){return[e||"",nx++].join("_")}function ix(e){var t={};e.registerSubTypeDefaulter=function(r,n){var i=Ze(r);t[i.main]=n},e.determineSubType=function(r,n){var i=n.type;if(!i){var a=Ze(r).main;e.hasSubTypes(r)&&t[a]&&(i=t[a](n))}return i}}function ax(e,t){e.topologicalTravel=function(a,o,s,l){if(!a.length)return;var u=r(o),f=u.graph,h=u.noEntryList,v={};for(D(a,function(y){v[y]=!0});h.length;){var c=h.pop(),d=f[c],p=!!v[c];p&&(s.call(l,c,d.originalDeps.slice()),delete v[c]),D(d.successor,p?g:m)}D(v,function(){var y="";throw new Error(y)});function m(y){f[y].entryCount--,f[y].entryCount===0&&h.push(y)}function g(y){v[y]=!0,m(y)}};function r(a){var o={},s=[];return D(a,function(l){var u=n(o,l),f=u.originalDeps=t(l),h=i(f,a);u.entryCount=h.length,u.entryCount===0&&s.push(l),D(h,function(v){vt(u.predecessor,v)<0&&u.predecessor.push(v);var c=n(o,v);vt(c.successor,v)<0&&c.successor.push(l)})}),{graph:o,noEntryList:s}}function n(a,o){return a[o]||(a[o]={predecessor:[],successor:[]}),a[o]}function i(a,o){var s=[];return D(a,function(l){vt(o,l)>=0&&s.push(l)}),s}}function ox(e,t){return ct(ct({},e,!0),t,!0)}const sx={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:". "}}}},lx={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 As="ZH",$h="EN",li=$h,Jo={},Zh={},cy=st.domSupported?(function(){var e=(document.documentElement.lang||navigator.language||navigator.browserLanguage||li).toUpperCase();return e.indexOf(As)>-1?As:li})():li;function dy(e,t){e=e.toUpperCase(),Zh[e]=new Mt(t),Jo[e]=t}function ux(e){if(W(e)){var t=Jo[e.toUpperCase()]||{};return e===As||e===$h?ut(t):ct(ut(t),ut(Jo[li]),!1)}else return ct(ut(e),ut(Jo[li]),!1)}function fx(e){return Zh[e]}function hx(){return Zh[li]}dy($h,sx);dy(As,lx);var vx=null;function hl(){return vx}function py(e,t){t.breakOption;var r=t.breakParsed;return r}function qh(e){var t=e.brk;return t?t.breaks:[]}function Ls(e){var t=e.brk;return t?t.hasBreaks():!1}var Kh=1e3,Qh=Kh*60,la=Qh*60,De=la*24,dd=De*365,cx={year:/({yyyy}|{yy})/,month:/({MMMM}|{MMM}|{MM}|{M})/,day:/({dd}|{d})/,hour:/({HH}|{H}|{hh}|{h})/,minute:/({mm}|{m})/,second:/({ss}|{s})/,millisecond:/({SSS}|{S})/},jo={year:"{yyyy}",month:"{MMM}",day:"{d}",hour:"{HH}:{mm}",minute:"{HH}:{mm}",second:"{HH}:{mm}:{ss}",millisecond:"{HH}:{mm}:{ss} {SSS}"},dx="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss} {SSS}",So="{yyyy}-{MM}-{dd}",pd={year:"{yyyy}",month:"{yyyy}-{MM}",day:So,hour:So+" "+jo.hour,minute:So+" "+jo.minute,second:So+" "+jo.second,millisecond:dx},Mn=["year","month","day","hour","minute","second","millisecond"],px=["year","half-year","quarter","month","week","half-week","day","half-day","quarter-day","hour","minute","second","millisecond"];function gx(e){return!W(e)&&!ot(e)?mx(e):e}function mx(e){e=e||{};var t={},r=!0;return D(Mn,function(n){r&&(r=e[n]==null)}),D(Mn,function(n,i){var a=e[n];t[n]={};for(var o=null,s=i;s>=0;s--){var l=Mn[s],u=K(a)&&!H(a)?a[l]:a,f=void 0;H(u)?(f=u.slice(),o=f[0]||""):W(u)?(o=u,f=[o]):(o==null?o=jo[n]:cx[l].test(o)||(o=t[l][l][0]+" "+o),f=[o],r&&(f[1]="{primary|"+o+"}")),t[n][l]=f}}),t}function Tr(e,t){return e+="","0000".substr(0,t-e.length)+e}function ua(e){switch(e){case"half-year":case"quarter":return"month";case"week":case"half-week":return"day";case"half-day":case"quarter-day":return"hour";default:return e}}function yx(e){return e===ua(e)}function _x(e){switch(e){case"year":case"month":return"day";case"millisecond":return"millisecond";default:return"second"}}function vl(e,t,r,n){var i=Di(e),a=i[gy(r)](),o=i[Jh(r)]()+1,s=Math.floor((o-1)/3)+1,l=i[jh(r)](),u=i["get"+(r?"UTC":"")+"Day"](),f=i[tv(r)](),h=(f-1)%12+1,v=i[ev(r)](),c=i[rv(r)](),d=i[nv(r)](),p=f>=12?"pm":"am",m=p.toUpperCase(),g=n instanceof Mt?n:fx(n||cy)||hx(),y=g.getModel("time"),_=y.get("month"),S=y.get("monthAbbr"),b=y.get("dayOfWeek"),T=y.get("dayOfWeekAbbr");return(t||"").replace(/{a}/g,p+"").replace(/{A}/g,m+"").replace(/{yyyy}/g,a+"").replace(/{yy}/g,Tr(a%100+"",2)).replace(/{Q}/g,s+"").replace(/{MMMM}/g,_[o-1]).replace(/{MMM}/g,S[o-1]).replace(/{MM}/g,Tr(o,2)).replace(/{M}/g,o+"").replace(/{dd}/g,Tr(l,2)).replace(/{d}/g,l+"").replace(/{eeee}/g,b[u]).replace(/{ee}/g,T[u]).replace(/{e}/g,u+"").replace(/{HH}/g,Tr(f,2)).replace(/{H}/g,f+"").replace(/{hh}/g,Tr(h+"",2)).replace(/{h}/g,h+"").replace(/{mm}/g,Tr(v,2)).replace(/{m}/g,v+"").replace(/{ss}/g,Tr(c,2)).replace(/{s}/g,c+"").replace(/{SSS}/g,Tr(d,3)).replace(/{S}/g,d+"")}function Sx(e,t,r,n,i){var a=null;if(W(r))a=r;else if(ot(r)){var o={time:e.time,level:e.time?e.time.level:0},s=hl();s&&s.makeAxisLabelFormatterParamBreak(o,e.break),a=r(e.value,t,o)}else{var l=e.time;if(l){var u=r[l.lowerTimeUnit][l.upperTimeUnit];a=u[Math.min(l.level,u.length-1)]||""}else{var f=ts(e.value,i);a=r[f][f][0]}}return vl(new Date(e.value),a,i,n)}function ts(e,t){var r=Di(e),n=r[Jh(t)]()+1,i=r[jh(t)](),a=r[tv(t)](),o=r[ev(t)](),s=r[rv(t)](),l=r[nv(t)](),u=l===0,f=u&&s===0,h=f&&o===0,v=h&&a===0,c=v&&i===1,d=c&&n===1;return d?"year":c?"month":v?"day":h?"hour":f?"minute":u?"second":"millisecond"}function Pf(e,t,r){switch(t){case"year":e[my(r)](0);case"month":e[yy(r)](1);case"day":e[_y(r)](0);case"hour":e[Sy(r)](0);case"minute":e[by(r)](0);case"second":e[Ty(r)](0)}return e}function gy(e){return e?"getUTCFullYear":"getFullYear"}function Jh(e){return e?"getUTCMonth":"getMonth"}function jh(e){return e?"getUTCDate":"getDate"}function tv(e){return e?"getUTCHours":"getHours"}function ev(e){return e?"getUTCMinutes":"getMinutes"}function rv(e){return e?"getUTCSeconds":"getSeconds"}function nv(e){return e?"getUTCMilliseconds":"getMilliseconds"}function bx(e){return e?"setUTCFullYear":"setFullYear"}function my(e){return e?"setUTCMonth":"setMonth"}function yy(e){return e?"setUTCDate":"setDate"}function _y(e){return e?"setUTCHours":"setHours"}function Sy(e){return e?"setUTCMinutes":"setMinutes"}function by(e){return e?"setUTCSeconds":"setSeconds"}function Ty(e){return e?"setUTCMilliseconds":"setMilliseconds"}function wy(e){if(!JS(e))return W(e)?e:"-";var t=(e+"").split(".");return t[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t.length>1?"."+t[1]:"")}function xy(e,t){return e=(e||"").toLowerCase().replace(/-(.)/g,function(r,n){return n.toUpperCase()}),t&&e&&(e=e.charAt(0).toUpperCase()+e.slice(1)),e}var cl=dh;function Ef(e,t,r){var n="{yyyy}-{MM}-{dd} {HH}:{mm}:{ss}";function i(f){return f&&$e(f)?f:"-"}function a(f){return rr(f)}var o=t==="time",s=e instanceof Date;if(o||s){var l=o?Di(e):e;if(isNaN(+l)){if(s)return"-"}else return vl(l,n,r)}if(t==="ordinal")return Xu(e)?i(e):Ct(e)&&a(e)?e+"":"-";var u=Ss(e);return a(u)?wy(u):Xu(e)?i(e):typeof e=="boolean"?e+"":"-"}var gd=["a","b","c","d","e","f","g"],du=function(e,t){return"{"+e+(t??"")+"}"};function Cy(e,t,r){H(t)||(t=[t]);var n=t.length;if(!n)return"";for(var i=t[0].$vars||[],a=0;a<i.length;a++){var o=gd[a];e=e.replace(du(o),du(o,0))}for(var s=0;s<n;s++)for(var l=0;l<i.length;l++){var u=t[s][i[l]];e=e.replace(du(gd[l],s),r?te(u):u)}return e}function Tx(e,t){var r=W(e)?{color:e,extraCssText:t}:e||{},n=r.color,i=r.type;t=r.extraCssText;var a=r.renderMode||"html";if(!n)return"";if(a==="html")return i==="subItem"?'<span style="display:inline-block;vertical-align:middle;margin-right:8px;margin-left:3px;border-radius:4px;width:4px;height:4px;background-color:'+te(n)+";"+(t||"")+'"></span>':'<span style="display:inline-block;margin-right:4px;border-radius:10px;width:10px;height:10px;background-color:'+te(n)+";"+(t||"")+'"></span>';var o=r.markerId||"markerX";return{renderMode:a,content:"{"+o+"|} ",style:i==="subItem"?{width:4,height:4,borderRadius:2,backgroundColor:n}:{width:10,height:10,borderRadius:5,backgroundColor:n}}}function In(e,t){return t=t||"transparent",W(e)?e:K(e)&&e.colorStops&&(e.colorStops[0]||{}).color||t}var es={},pu={},iv=(function(){function e(){this._normalMasterList=[],this._nonSeriesBoxMasterList=[]}return e.prototype.create=function(t,r){this._nonSeriesBoxMasterList=n(es),this._normalMasterList=n(pu);function n(i,a){var o=[];return D(i,function(s,l){var u=s.create(t,r);o=o.concat(u||[])}),o}},e.prototype.update=function(t,r){D(this._normalMasterList,function(n){n.update&&n.update(t,r)})},e.prototype.getCoordinateSystems=function(){return this._normalMasterList.concat(this._nonSeriesBoxMasterList)},e.register=function(t,r){if(t==="matrix"||t==="calendar"){es[t]=r;return}pu[t]=r},e.get=function(t){return pu[t]||es[t]},e})();function xx(e){return!!es[e]}var Cx=1,Dx=2,Mx=nt();function Dy(e){var t=e.getShallow("coord",!0),r=Cx;if(t==null){var n=Mx.get(e.type);n&&n.getCoord2&&(r=Dx,t=n.getCoord2(e))}return{coord:t,from:r}}var ui=0,rs=1,Ax=2;function Lx(e,t){var r=e.getShallow("coordinateSystem"),n=e.getShallow("coordinateSystemUsage",!0),i=ui;if(r){var a=e.mainType==="series";n==null&&(n=a?"data":"box"),n==="data"?(i=rs,a||(i=ui)):n==="box"&&(i=Ax,!a&&!xx(r)&&(i=ui))}return{coordSysType:r,kind:i}}function Ix(e){var t=e.targetModel,r=e.coordSysType,n=e.coordSysProvider,i=e.isDefaultDataCoordSys,a=Lx(t),o=a.kind,s=a.coordSysType;if(i&&o!==rs&&(o=rs,s=r),o===ui||s!==r)return ui;var l=n(r,t);return l?(o===rs?t.coordinateSystem=l:t.boxCoordinateSystem=l,o):ui}var ns=D,Px=["left","right","top","bottom","width","height"],bo=[["width","left","right"],["height","top","bottom"]];function av(e,t,r,n,i){var a=0,o=0;n==null&&(n=1/0),i==null&&(i=1/0);var s=0;t.eachChild(function(l,u){var f=l.getBoundingRect(),h=t.childAt(u+1),v=h&&h.getBoundingRect(),c,d;if(e==="horizontal"){var p=f.width+(v?-v.x+f.x:0);c=a+p,c>n||l.newline?(a=0,c=p,o+=s+r,s=f.height):s=Math.max(s,f.height)}else{var m=f.height+(v?-v.y+f.y:0);d=o+m,d>i||l.newline?(a+=s+r,o=0,d=m,s=f.width):s=Math.max(s,f.width)}l.newline||(l.x=a,l.y=o,l.markRedraw(),e==="horizontal"?a=c+r:o=d+r)})}var fa=av;Et(av,"vertical");Et(av,"horizontal");function Ex(e,t){return{left:e.getShallow("left",t),top:e.getShallow("top",t),right:e.getShallow("right",t),bottom:e.getShallow("bottom",t),width:e.getShallow("width",t),height:e.getShallow("height",t)}}function wa(e,t,r){r=cl(r||0);var n=t.width,i=t.height,a=Ye(e.left,n),o=Ye(e.top,i),s=Ye(e.right,n),l=Ye(e.bottom,i),u=Ye(e.width,n),f=Ye(e.height,i),h=r[2]+r[0],v=r[1]+r[3],c=e.aspect;switch(isNaN(u)&&(u=n-s-v-a),isNaN(f)&&(f=i-l-h-o),c!=null&&(isNaN(u)&&isNaN(f)&&(c>n/i?u=n*.8:f=i*.8),isNaN(u)&&(u=c*f),isNaN(f)&&(f=u/c)),isNaN(a)&&(a=n-s-u-v),isNaN(o)&&(o=i-l-f-h),e.left||e.right){case"center":a=n/2-u/2-r[3];break;case"right":a=n-u-v;break}switch(e.top||e.bottom){case"middle":case"center":o=i/2-f/2-r[0];break;case"bottom":o=i-f-h;break}a=a||0,o=o||0,isNaN(u)&&(u=n-v-a-(s||0)),isNaN(f)&&(f=i-h-o-(l||0));var d=new it((t.x||0)+a+r[3],(t.y||0)+o+r[0],u,f);return d.margin=r,d}var gu={rect:1};function My(e,t,r){var n,i,a,o=e.boxCoordinateSystem,s;if(o){var l=Dy(e),u=l.coord,f=l.from;if(o.dataToLayout){a=gu.rect,s=f;var h=o.dataToLayout(u);n=h.contentRect||h.rect}}return a==null&&(a=gu.rect),a===gu.rect&&(n||(n={x:0,y:0,width:t.getWidth(),height:t.getHeight()}),i=[n.x+n.width/2,n.y+n.height/2]),{type:a,refContainer:n,refPoint:i,boxCoordFrom:s}}function xa(e){var t=e.layoutMode||e.constructor.layoutMode;return K(t)?t:t?{type:t}:null}function Hr(e,t,r){var n=r&&r.ignoreSize;!H(n)&&(n=[n,n]);var i=o(bo[0],0),a=o(bo[1],1);l(bo[0],e,i),l(bo[1],e,a);function o(u,f){var h={},v=0,c={},d=0,p=2;if(ns(u,function(y){c[y]=e[y]}),ns(u,function(y){fe(t,y)&&(h[y]=c[y]=t[y]),s(h,y)&&v++,s(c,y)&&d++}),n[f])return s(t,u[1])?c[u[2]]=null:s(t,u[2])&&(c[u[1]]=null),c;if(d===p||!v)return c;if(v>=p)return h;for(var m=0;m<u.length;m++){var g=u[m];if(!fe(h,g)&&fe(e,g)){h[g]=e[g];break}}return h}function s(u,f){return u[f]!=null&&u[f]!=="auto"}function l(u,f,h){ns(u,function(v){f[v]=h[v]})}}function Wa(e){return Rx({},e)}function Rx(e,t){return t&&e&&ns(Px,function(r){fe(t,r)&&(e[r]=t[r])}),e}var kx=bt(),pt=(function(e){V(t,e);function t(r,n,i){var a=e.call(this,r,n,i)||this;return a.uid=fl("ec_cpt_model"),a}return t.prototype.init=function(r,n,i){this.mergeDefaultAndTheme(r,i)},t.prototype.mergeDefaultAndTheme=function(r,n){var i=xa(this),a=i?Wa(r):{},o=n.getTheme();ct(r,o.get(this.mainType)),ct(r,this.getDefaultOption()),i&&Hr(r,a,i)},t.prototype.mergeOption=function(r,n){ct(this.option,r,!0);var i=xa(this);i&&Hr(this.option,r,i)},t.prototype.optionUpdated=function(r,n){},t.prototype.getDefaultOption=function(){var r=this.constructor;if(!Db(r))return r.defaultOption;var n=kx(this);if(!n.defaultOption){for(var i=[],a=r;a;){var o=a.prototype.defaultOption;o&&i.push(o),a=a.superClass}for(var s={},l=i.length-1;l>=0;l--)s=ct(s,i[l],!0);n.defaultOption=s}return n.defaultOption},t.prototype.getReferringComponents=function(r,n){var i=r+"Index",a=r+"Id";return Ha(this.ecModel,r,{index:this.get(i,!0),id:this.get(a,!0)},n)},t.prototype.getBoxLayoutParams=function(){return Ex(this,!1)},t.prototype.getZLevelKey=function(){return""},t.prototype.setZLevel=function(r){this.option.zlevel=r},t.protoInitialize=(function(){var r=t.prototype;r.type="component",r.id="",r.name="",r.mainType="",r.subType="",r.componentIndex=0})(),t})(Mt);bm(pt,Mt);js(pt);ix(pt);ax(pt,Ox);function Ox(e){var t=[];return D(pt.getClassesByMainType(e),function(r){t=t.concat(r.dependencies||r.prototype.dependencies||[])}),t=rt(t,function(r){return Ze(r).main}),e!=="dataset"&&vt(t,"dataset")<=0&&t.unshift("dataset"),t}var J={color:{},darkColor:{},size:{}},Lt=J.color={theme:["#5070dd","#b6d634","#505372","#ff994d","#0ca8df","#ffd10a","#fb628b","#785db0","#3fbe95"],neutral00:"#fff",neutral05:"#f4f7fd",neutral10:"#e8ebf0",neutral15:"#dbdee4",neutral20:"#cfd2d7",neutral25:"#c3c5cb",neutral30:"#b7b9be",neutral35:"#aaacb2",neutral40:"#9ea0a5",neutral45:"#929399",neutral50:"#86878c",neutral55:"#797b7f",neutral60:"#6d6e73",neutral65:"#616266",neutral70:"#54555a",neutral75:"#48494d",neutral80:"#3c3c41",neutral85:"#303034",neutral90:"#232328",neutral95:"#17171b",neutral99:"#000",accent05:"#eff1f9",accent10:"#e0e4f2",accent15:"#d0d6ec",accent20:"#c0c9e6",accent25:"#b1bbdf",accent30:"#a1aed9",accent35:"#91a0d3",accent40:"#8292cc",accent45:"#7285c6",accent50:"#6578ba",accent55:"#5c6da9",accent60:"#536298",accent65:"#4a5787",accent70:"#404c76",accent75:"#374165",accent80:"#2e3654",accent85:"#252b43",accent90:"#1b2032",accent95:"#121521",transparent:"rgba(0,0,0,0)",highlight:"rgba(255,231,130,0.8)"};N(Lt,{primary:Lt.neutral80,secondary:Lt.neutral70,tertiary:Lt.neutral60,quaternary:Lt.neutral50,disabled:Lt.neutral20,border:Lt.neutral30,borderTint:Lt.neutral20,borderShade:Lt.neutral40,background:Lt.neutral05,backgroundTint:"rgba(234,237,245,0.5)",backgroundTransparent:"rgba(255,255,255,0)",backgroundShade:Lt.neutral10,shadow:"rgba(0,0,0,0.2)",shadowTint:"rgba(129,130,136,0.2)",axisLine:Lt.neutral70,axisLineTint:Lt.neutral40,axisTick:Lt.neutral70,axisTickMinor:Lt.neutral60,axisLabel:Lt.neutral70,axisSplitLine:Lt.neutral15,axisMinorSplitLine:Lt.neutral05});for(var fn in Lt)if(Lt.hasOwnProperty(fn)){var md=Lt[fn];fn==="theme"?J.darkColor.theme=Lt.theme.slice():fn==="highlight"?J.darkColor.highlight="rgba(255,231,130,0.4)":fn.indexOf("accent")===0?J.darkColor[fn]=af(md,null,function(e){return e*.5},function(e){return Math.min(1,1.3-e)}):J.darkColor[fn]=af(md,null,function(e){return e*.9},function(e){return 1-Math.pow(e,1.5)})}J.size={xxs:2,xs:5,s:10,m:15,l:20,xl:30,xxl:40,xxxl:50};var Ay="";typeof navigator<"u"&&(Ay=navigator.platform||"");var Gn="rgba(0, 0, 0, 0.2)",Ly=J.color.theme[0],Bx=af(Ly,null,null,.9);const Iy={darkMode:"auto",colorBy:"series",color:J.color.theme,gradientColor:[Bx,Ly],aria:{decal:{decals:[{color:Gn,dashArrayX:[1,0],dashArrayY:[2,5],symbolSize:1,rotation:Math.PI/6},{color:Gn,symbol:"circle",dashArrayX:[[8,8],[0,8,8,0]],dashArrayY:[6,0],symbolSize:.8},{color:Gn,dashArrayX:[1,0],dashArrayY:[4,3],rotation:-Math.PI/4},{color:Gn,dashArrayX:[[6,6],[0,6,6,0]],dashArrayY:[6,0]},{color:Gn,dashArrayX:[[1,0],[1,6]],dashArrayY:[1,0,6,0],rotation:Math.PI/4},{color:Gn,symbol:"triangle",dashArrayX:[[9,9],[0,9,9,0]],dashArrayY:[7,2],symbolSize:.75}]}},textStyle:{fontFamily:Ay.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 se={Must:1,Might:2,Not:3},Py=bt();function Nx(e){Py(e).datasetMap=nt()}function Fx(e,t,r){var n={},i=Ey(t);if(!i||!e)return n;var a=[],o=[],s=t.ecModel,l=Py(s).datasetMap,u=i.uid+"_"+r.seriesLayoutBy,f,h;e=e.slice(),D(e,function(p,m){var g=K(p)?p:e[m]={name:p};g.type==="ordinal"&&f==null&&(f=m,h=d(g)),n[g.name]=[]});var v=l.get(u)||l.set(u,{categoryWayDim:h,valueWayDim:0});D(e,function(p,m){var g=p.name,y=d(p);if(f==null){var _=v.valueWayDim;c(n[g],_,y),c(o,_,y),v.valueWayDim+=y}else if(f===m)c(n[g],0,y),c(a,0,y);else{var _=v.categoryWayDim;c(n[g],_,y),c(o,_,y),v.categoryWayDim+=y}});function c(p,m,g){for(var y=0;y<g;y++)p.push(m+y)}function d(p){var m=p.dimsDef;return m?m.length:1}return a.length&&(n.itemName=a),o.length&&(n.seriesName=o),n}function Ey(e){var t=e.get("data",!0);if(!t)return Ha(e.ecModel,"dataset",{index:e.get("datasetIndex",!0),id:e.get("datasetId",!0)},Ce).models[0]}function zx(e){return!e.get("transform",!0)&&!e.get("fromTransformResult",!0)?[]:Ha(e.ecModel,"dataset",{index:e.get("fromDatasetIndex",!0),id:e.get("fromDatasetId",!0)},Ce).models}function Ry(e,t){return Hx(e.data,e.sourceFormat,e.seriesLayoutBy,e.dimensionsDefine,e.startIndex,t)}function Hx(e,t,r,n,i,a){var o,s=5;if(ae(e))return se.Not;var l,u;if(n){var f=n[a];K(f)?(l=f.name,u=f.type):W(f)&&(l=f)}if(u!=null)return u==="ordinal"?se.Must:se.Not;if(t===Zt){var h=e;if(r===En){for(var v=h[a],c=0;c<(v||[]).length&&c<s;c++)if((o=S(v[i+c]))!=null)return o}else for(var c=0;c<h.length&&c<s;c++){var d=h[i+c];if(d&&(o=S(d[a]))!=null)return o}}else if(t===Ne){var p=e;if(!l)return se.Not;for(var c=0;c<p.length&&c<s;c++){var m=p[c];if(m&&(o=S(m[l]))!=null)return o}}else if(t===sr){var g=e;if(!l)return se.Not;var v=g[l];if(!v||ae(v))return se.Not;for(var c=0;c<v.length&&c<s;c++)if((o=S(v[c]))!=null)return o}else if(t===ve)for(var y=e,c=0;c<y.length&&c<s;c++){var m=y[c],_=za(m);if(!H(_))return se.Not;if((o=S(_[a]))!=null)return o}function S(b){var T=W(b);if(b!=null&&isFinite(Number(b))&&b!=="")return T?se.Might:se.Not;if(T&&b!=="-")return se.Must}return se.Not}var Vx=nt();function Gx(e,t,r){var n=Vx.get(t);if(!n)return r;var i=n(e);return i?r.concat(i):r}var yd=bt();bt();var ov=(function(){function e(){}return e.prototype.getColorFromPalette=function(t,r,n){var i=Jt(this.get("color",!0)),a=this.get("colorLayer",!0);return Wx(this,yd,i,a,t,r,n)},e.prototype.clearColorPalette=function(){Yx(this,yd)},e})();function Ux(e,t){for(var r=e.length,n=0;n<r;n++)if(e[n].length>t)return e[n];return e[r-1]}function Wx(e,t,r,n,i,a,o){a=a||e;var s=t(a),l=s.paletteIdx||0,u=s.paletteNameMap=s.paletteNameMap||{};if(u.hasOwnProperty(i))return u[i];var f=o==null||!n?r:Ux(n,o);if(f=f||r,!(!f||!f.length)){var h=f[l];return i&&(u[i]=h),s.paletteIdx=(l+1)%f.length,h}}function Yx(e,t){t(e).paletteIdx=0,t(e).paletteNameMap={}}var To,Oi,_d,Sd="\0_ec_inner",Xx=1,sv=(function(e){V(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.init=function(r,n,i,a,o,s){a=a||{},this.option=null,this._theme=new Mt(a),this._locale=new Mt(o),this._optionManager=s},t.prototype.setOption=function(r,n,i){var a=wd(n);this._optionManager.setOption(r,i,a),this._resetOption(null,a)},t.prototype.resetOption=function(r,n){return this._resetOption(r,wd(n))},t.prototype._resetOption=function(r,n){var i=!1,a=this._optionManager;if(!r||r==="recreate"){var o=a.mountOption(r==="recreate");!this.option||r==="recreate"?_d(this,o):(this.restoreData(),this._mergeOption(o,n)),i=!0}if((r==="timeline"||r==="media")&&this.restoreData(),!r||r==="recreate"||r==="timeline"){var s=a.getTimelineOption(this);s&&(i=!0,this._mergeOption(s,n))}if(!r||r==="recreate"||r==="media"){var l=a.getMediaOption(this);l.length&&D(l,function(u){i=!0,this._mergeOption(u,n)},this)}return i},t.prototype.mergeOption=function(r){this._mergeOption(r,null)},t.prototype._mergeOption=function(r,n){var i=this.option,a=this._componentsMap,o=this._componentsCount,s=[],l=nt(),u=n&&n.replaceMergeMainTypeMap;Nx(this),D(r,function(h,v){h!=null&&(pt.hasClass(v)?v&&(s.push(v),l.set(v,!0)):i[v]=i[v]==null?ut(h):ct(i[v],h,!0))}),u&&u.each(function(h,v){pt.hasClass(v)&&!l.get(v)&&(s.push(v),l.set(v,!0))}),pt.topologicalTravel(s,pt.getAllClassMainTypes(),f,this);function f(h){var v=Gx(this,h,Jt(r[h])),c=a.get(h),d=c?u&&u.get(h)?"replaceMerge":"normalMerge":"replaceAll",p=ib(c,v,d);hb(p,h,pt),i[h]=null,a.set(h,null),o.set(h,0);var m=[],g=[],y=0,_;D(p,function(S,b){var T=S.existing,w=S.newOption;if(!w)T&&(T.mergeOption({},this),T.optionUpdated({},!1));else{var M=h==="series",C=pt.getClass(h,S.keyInfo.subType,!M);if(!C)return;if(h==="tooltip"){if(_)return;_=!0}if(T&&T.constructor===C)T.name=S.keyInfo.name,T.mergeOption(w,this),T.optionUpdated(w,!1);else{var x=N({componentIndex:b},S.keyInfo);T=new C(w,this,this,x),N(T,x),S.brandNew&&(T.__requireNewView=!0),T.init(w,this,this),T.optionUpdated(null,!0)}}T?(m.push(T.option),g.push(T),y++):(m.push(void 0),g.push(void 0))},this),i[h]=m,a.set(h,g),o.set(h,y),h==="series"&&To(this)}this._seriesIndices||To(this)},t.prototype.getOption=function(){var r=ut(this.option);return D(r,function(n,i){if(pt.hasClass(i)){for(var a=Jt(n),o=a.length,s=!1,l=o-1;l>=0;l--)a[l]&&!ya(a[l])?s=!0:(a[l]=null,!s&&o--);a.length=o,r[i]=a}}),delete r[Sd],r},t.prototype.setTheme=function(r){this._theme=new Mt(r),this._resetOption("recreate",null)},t.prototype.getTheme=function(){return this._theme},t.prototype.getLocaleModel=function(){return this._locale},t.prototype.setUpdatePayload=function(r){this._payload=r},t.prototype.getUpdatePayload=function(){return this._payload},t.prototype.getComponent=function(r,n){var i=this._componentsMap.get(r);if(i){var a=i[n||0];if(a)return a;if(n==null){for(var o=0;o<i.length;o++)if(i[o])return i[o]}}},t.prototype.queryComponents=function(r){var n=r.mainType;if(!n)return[];var i=r.index,a=r.id,o=r.name,s=this._componentsMap.get(n);if(!s||!s.length)return[];var l;return i!=null?(l=[],D(Jt(i),function(u){s[u]&&l.push(s[u])})):a!=null?l=bd("id",a,s):o!=null?l=bd("name",o,s):l=Xt(s,function(u){return!!u}),Td(l,r)},t.prototype.findComponents=function(r){var n=r.query,i=r.mainType,a=s(n),o=a?this.queryComponents(a):Xt(this._componentsMap.get(i),function(u){return!!u});return l(Td(o,r));function s(u){var f=i+"Index",h=i+"Id",v=i+"Name";return u&&(u[f]!=null||u[h]!=null||u[v]!=null)?{mainType:i,index:u[f],id:u[h],name:u[v]}:null}function l(u){return r.filter?Xt(u,r.filter):u}},t.prototype.eachComponent=function(r,n,i){var a=this._componentsMap;if(ot(r)){var o=n,s=r;a.each(function(h,v){for(var c=0;h&&c<h.length;c++){var d=h[c];d&&s.call(o,v,d,d.componentIndex)}})}else for(var l=W(r)?a.get(r):K(r)?this.findComponents(r):null,u=0;l&&u<l.length;u++){var f=l[u];f&&n.call(i,f,f.componentIndex)}},t.prototype.getSeriesByName=function(r){var n=je(r,null);return Xt(this._componentsMap.get("series"),function(i){return!!i&&n!=null&&i.name===n})},t.prototype.getSeriesByIndex=function(r){return this._componentsMap.get("series")[r]},t.prototype.getSeriesByType=function(r){return Xt(this._componentsMap.get("series"),function(n){return!!n&&n.subType===r})},t.prototype.getSeries=function(){return Xt(this._componentsMap.get("series"),function(r){return!!r})},t.prototype.getSeriesCount=function(){return this._componentsCount.get("series")},t.prototype.eachSeries=function(r,n){Oi(this),D(this._seriesIndices,function(i){var a=this._componentsMap.get("series")[i];r.call(n,a,i)},this)},t.prototype.eachRawSeries=function(r,n){D(this._componentsMap.get("series"),function(i){i&&r.call(n,i,i.componentIndex)})},t.prototype.eachSeriesByType=function(r,n,i){Oi(this),D(this._seriesIndices,function(a){var o=this._componentsMap.get("series")[a];o.subType===r&&n.call(i,o,a)},this)},t.prototype.eachRawSeriesByType=function(r,n,i){return D(this.getSeriesByType(r),n,i)},t.prototype.isSeriesFiltered=function(r){return Oi(this),this._seriesIndicesMap.get(r.componentIndex)==null},t.prototype.getCurrentSeriesIndices=function(){return(this._seriesIndices||[]).slice()},t.prototype.filterSeries=function(r,n){Oi(this);var i=[];D(this._seriesIndices,function(a){var o=this._componentsMap.get("series")[a];r.call(n,o,a)&&i.push(a)},this),this._seriesIndices=i,this._seriesIndicesMap=nt(i)},t.prototype.restoreData=function(r){To(this);var n=this._componentsMap,i=[];n.each(function(a,o){pt.hasClass(o)&&i.push(o)}),pt.topologicalTravel(i,pt.getAllClassMainTypes(),function(a){D(n.get(a),function(o){o&&(a!=="series"||!$x(o,r))&&o.restoreData()})})},t.internalField=(function(){To=function(r){var n=r._seriesIndices=[];D(r._componentsMap.get("series"),function(i){i&&n.push(i.componentIndex)}),r._seriesIndicesMap=nt(n)},Oi=function(r){},_d=function(r,n){r.option={},r.option[Sd]=Xx,r._componentsMap=nt({series:[]}),r._componentsCount=nt();var i=n.aria;K(i)&&i.enabled==null&&(i.enabled=!0),Zx(n,r._theme.option),ct(n,Iy,!1),r._mergeOption(n,null)}})(),t})(Mt);function $x(e,t){if(t){var r=t.seriesIndex,n=t.seriesId,i=t.seriesName;return r!=null&&e.componentIndex!==r||n!=null&&e.id!==n||i!=null&&e.name!==i}}function Zx(e,t){var r=e.color&&!e.colorLayer;D(t,function(n,i){i==="colorLayer"&&r||i==="color"&&e.color||pt.hasClass(i)||(typeof n=="object"?e[i]=e[i]?ct(e[i],n,!1):ut(n):e[i]==null&&(e[i]=n))})}function bd(e,t,r){if(H(t)){var n=nt();return D(t,function(a){if(a!=null){var o=je(a,null);o!=null&&n.set(a,!0)}}),Xt(r,function(a){return a&&n.get(a[e])})}else{var i=je(t,null);return Xt(r,function(a){return a&&i!=null&&a[e]===i})}}function Td(e,t){return t.hasOwnProperty("subType")?Xt(e,function(r){return r&&r.subType===t.subType}):e}function wd(e){var t=nt();return e&&D(Jt(e.replaceMerge),function(r){t.set(r,!0)}),{replaceMergeMainTypeMap:t}}ar(sv,ov);var qx=/^(min|max)?(.+)$/,Kx=(function(){function e(t){this._timelineOptions=[],this._mediaList=[],this._currentMediaIndices=[],this._api=t}return e.prototype.setOption=function(t,r,n){t&&(D(Jt(t.series),function(o){o&&o.data&&ae(o.data)&&$u(o.data)}),D(Jt(t.dataset),function(o){o&&o.source&&ae(o.source)&&$u(o.source)})),t=ut(t);var i=this._optionBackup,a=Qx(t,r,!i);this._newBaseOption=a.baseOption,i?(a.timelineOptions.length&&(i.timelineOptions=a.timelineOptions),a.mediaList.length&&(i.mediaList=a.mediaList),a.mediaDefault&&(i.mediaDefault=a.mediaDefault)):this._optionBackup=a},e.prototype.mountOption=function(t){var r=this._optionBackup;return this._timelineOptions=r.timelineOptions,this._mediaList=r.mediaList,this._mediaDefault=r.mediaDefault,this._currentMediaIndices=[],ut(t?r.baseOption:this._newBaseOption)},e.prototype.getTimelineOption=function(t){var r,n=this._timelineOptions;if(n.length){var i=t.getComponent("timeline");i&&(r=ut(n[i.getCurrentIndex()]))}return r},e.prototype.getMediaOption=function(t){var r=this._api.getWidth(),n=this._api.getHeight(),i=this._mediaList,a=this._mediaDefault,o=[],s=[];if(!i.length&&!a)return s;for(var l=0,u=i.length;l<u;l++)Jx(i[l].query,r,n)&&o.push(l);return!o.length&&a&&(o=[-1]),o.length&&!tC(o,this._currentMediaIndices)&&(s=rt(o,function(f){return ut(f===-1?a.option:i[f].option)})),this._currentMediaIndices=o,s},e})();function Qx(e,t,r){var n=[],i,a,o=e.baseOption,s=e.timeline,l=e.options,u=e.media,f=!!e.media,h=!!(l||s||o&&o.timeline);o?(a=o,a.timeline||(a.timeline=s)):((h||f)&&(e.options=e.media=null),a=e),f&&H(u)&&D(u,function(c){c&&c.option&&(c.query?n.push(c):i||(i=c))}),v(a),D(l,function(c){return v(c)}),D(n,function(c){return v(c.option)});function v(c){D(t,function(d){d(c,r)})}return{baseOption:a,timelineOptions:l||[],mediaDefault:i,mediaList:n}}function Jx(e,t,r){var n={width:t,height:r,aspectratio:t/r},i=!0;return D(e,function(a,o){var s=o.match(qx);if(!(!s||!s[1]||!s[2])){var l=s[1],u=s[2].toLowerCase();jx(n[u],a,l)||(i=!1)}}),i}function jx(e,t,r){return r==="min"?e>=t:r==="max"?e<=t:e===t}function tC(e,t){return e.join(",")===t.join(",")}var Re=D,Ca=K,xd=["areaStyle","lineStyle","nodeStyle","linkStyle","chordStyle","label","labelLine"];function mu(e){var t=e&&e.itemStyle;if(t)for(var r=0,n=xd.length;r<n;r++){var i=xd[r],a=t.normal,o=t.emphasis;a&&a[i]&&(e[i]=e[i]||{},e[i].normal?ct(e[i].normal,a[i]):e[i].normal=a[i],a[i]=null),o&&o[i]&&(e[i]=e[i]||{},e[i].emphasis?ct(e[i].emphasis,o[i]):e[i].emphasis=o[i],o[i]=null)}}function Yt(e,t,r){if(e&&e[t]&&(e[t].normal||e[t].emphasis)){var n=e[t].normal,i=e[t].emphasis;n&&(r?(e[t].normal=e[t].emphasis=null,yt(e[t],n)):e[t]=n),i&&(e.emphasis=e.emphasis||{},e.emphasis[t]=i,i.focus&&(e.emphasis.focus=i.focus),i.blurScope&&(e.emphasis.blurScope=i.blurScope))}}function ji(e){Yt(e,"itemStyle"),Yt(e,"lineStyle"),Yt(e,"areaStyle"),Yt(e,"label"),Yt(e,"labelLine"),Yt(e,"upperLabel"),Yt(e,"edgeLabel")}function It(e,t){var r=Ca(e)&&e[t],n=Ca(r)&&r.textStyle;if(n)for(var i=0,a=Tc.length;i<a;i++){var o=Tc[i];n.hasOwnProperty(o)&&(r[o]=n[o])}}function _e(e){e&&(ji(e),It(e,"label"),e.emphasis&&It(e.emphasis,"label"))}function eC(e){if(Ca(e)){mu(e),ji(e),It(e,"label"),It(e,"upperLabel"),It(e,"edgeLabel"),e.emphasis&&(It(e.emphasis,"label"),It(e.emphasis,"upperLabel"),It(e.emphasis,"edgeLabel"));var t=e.markPoint;t&&(mu(t),_e(t));var r=e.markLine;r&&(mu(r),_e(r));var n=e.markArea;n&&_e(n);var i=e.data;if(e.type==="graph"){i=i||e.nodes;var a=e.links||e.edges;if(a&&!ae(a))for(var o=0;o<a.length;o++)_e(a[o]);D(e.categories,function(u){ji(u)})}if(i&&!ae(i))for(var o=0;o<i.length;o++)_e(i[o]);if(t=e.markPoint,t&&t.data)for(var s=t.data,o=0;o<s.length;o++)_e(s[o]);if(r=e.markLine,r&&r.data)for(var l=r.data,o=0;o<l.length;o++)H(l[o])?(_e(l[o][0]),_e(l[o][1])):_e(l[o]);e.type==="gauge"?(It(e,"axisLabel"),It(e,"title"),It(e,"detail")):e.type==="treemap"?(Yt(e.breadcrumb,"itemStyle"),D(e.levels,function(u){ji(u)})):e.type==="tree"&&ji(e.leaves)}}function fr(e){return H(e)?e:e?[e]:[]}function Cd(e){return(H(e)?e[0]:e)||{}}function rC(e,t){Re(fr(e.series),function(n){Ca(n)&&eC(n)});var r=["xAxis","yAxis","radiusAxis","angleAxis","singleAxis","parallelAxis","radar"];t&&r.push("valueAxis","categoryAxis","logAxis","timeAxis"),Re(r,function(n){Re(fr(e[n]),function(i){i&&(It(i,"axisLabel"),It(i.axisPointer,"label"))})}),Re(fr(e.parallel),function(n){var i=n&&n.parallelAxisDefault;It(i,"axisLabel"),It(i&&i.axisPointer,"label")}),Re(fr(e.calendar),function(n){Yt(n,"itemStyle"),It(n,"dayLabel"),It(n,"monthLabel"),It(n,"yearLabel")}),Re(fr(e.radar),function(n){It(n,"name"),n.name&&n.axisName==null&&(n.axisName=n.name,delete n.name),n.nameGap!=null&&n.axisNameGap==null&&(n.axisNameGap=n.nameGap,delete n.nameGap)}),Re(fr(e.geo),function(n){Ca(n)&&(_e(n),Re(fr(n.regions),function(i){_e(i)}))}),Re(fr(e.timeline),function(n){_e(n),Yt(n,"label"),Yt(n,"itemStyle"),Yt(n,"controlStyle",!0);var i=n.data;H(i)&&D(i,function(a){K(a)&&(Yt(a,"label"),Yt(a,"itemStyle"))})}),Re(fr(e.toolbox),function(n){Yt(n,"iconStyle"),Re(n.feature,function(i){Yt(i,"iconStyle")})}),It(Cd(e.axisPointer),"label"),It(Cd(e.tooltip).axisPointer,"label")}function nC(e,t){for(var r=t.split(","),n=e,i=0;i<r.length&&(n=n&&n[r[i]],n!=null);i++);return n}function iC(e,t,r,n){for(var i=t.split(","),a=e,o,s=0;s<i.length-1;s++)o=i[s],a[o]==null&&(a[o]={}),a=a[o];a[i[s]]==null&&(a[i[s]]=r)}function Dd(e){e&&D(aC,function(t){t[0]in e&&!(t[1]in e)&&(e[t[1]]=e[t[0]])})}var aC=[["x","left"],["y","top"],["x2","right"],["y2","bottom"]],oC=["grid","geo","parallel","legend","toolbox","title","visualMap","dataZoom","timeline"],yu=[["borderRadius","barBorderRadius"],["borderColor","barBorderColor"],["borderWidth","barBorderWidth"]];function Bi(e){var t=e&&e.itemStyle;if(t)for(var r=0;r<yu.length;r++){var n=yu[r][1],i=yu[r][0];t[n]!=null&&(t[i]=t[n])}}function Md(e){e&&e.alignTo==="edge"&&e.margin!=null&&e.edgeDistance==null&&(e.edgeDistance=e.margin)}function Ad(e){e&&e.downplay&&!e.blur&&(e.blur=e.downplay)}function sC(e){e&&e.focusNodeAdjacency!=null&&(e.emphasis=e.emphasis||{},e.emphasis.focus==null&&(e.emphasis.focus="adjacency"))}function ky(e,t){if(e)for(var r=0;r<e.length;r++)t(e[r]),e[r]&&ky(e[r].children,t)}function Oy(e,t){rC(e,t),e.series=Jt(e.series),D(e.series,function(r){if(K(r)){var n=r.type;if(n==="line")r.clipOverflow!=null&&(r.clip=r.clipOverflow);else if(n==="pie"||n==="gauge"){r.clockWise!=null&&(r.clockwise=r.clockWise),Md(r.label);var i=r.data;if(i&&!ae(i))for(var a=0;a<i.length;a++)Md(i[a]);r.hoverOffset!=null&&(r.emphasis=r.emphasis||{},(r.emphasis.scaleSize=null)&&(r.emphasis.scaleSize=r.hoverOffset))}else if(n==="gauge"){var o=nC(r,"pointer.color");o!=null&&iC(r,"itemStyle.color",o)}else if(n==="bar"){Bi(r),Bi(r.backgroundStyle),Bi(r.emphasis);var i=r.data;if(i&&!ae(i))for(var a=0;a<i.length;a++)typeof i[a]=="object"&&(Bi(i[a]),Bi(i[a]&&i[a].emphasis))}else if(n==="sunburst"){var s=r.highlightPolicy;s&&(r.emphasis=r.emphasis||{},r.emphasis.focus||(r.emphasis.focus=s)),Ad(r),ky(r.data,Ad)}else n==="graph"||n==="sankey"?sC(r):n==="map"&&(r.mapType&&!r.map&&(r.map=r.mapType),r.mapLocation&&yt(r,r.mapLocation));r.hoverAnimation!=null&&(r.emphasis=r.emphasis||{},r.emphasis&&r.emphasis.scale==null&&(r.emphasis.scale=r.hoverAnimation)),Dd(r)}}),e.dataRange&&(e.visualMap=e.dataRange),D(oC,function(r){var n=e[r];n&&(H(n)||(n=[n]),D(n,function(i){Dd(i)}))})}var lC=xh(uC);function uC(e){var t=nt();e.eachSeries(function(r){var n=r.get("stack");if(n){var i=t.get(n)||t.set(n,[]),a=r.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:r};if(!o.stackedDimension||!(o.isStackedByIndex||o.stackedByDimension))return;i.push(o)}}),t.each(function(r){if(r.length!==0){var n=r[0].seriesModel,i=n.get("stackOrder")||"seriesAsc";i==="seriesDesc"&&r.reverse(),D(r,function(a,o){a.data.setCalculationInfo("stackedOnSeries",o>0?r[o-1].seriesModel:null)}),fC(r)}})}function fC(e){D(e,function(t,r){var n=[],i=[NaN,NaN],a=[t.stackResultDimension,t.stackedOverDimension],o=t.data,s=t.isStackedByIndex,l=t.seriesModel.get("stackStrategy")||"samesign";o.modify(a,function(u,f,h){var v=o.get(t.stackedDimension,h);if(isNaN(v))return i;var c,d;s?d=o.getRawIndex(h):c=o.get(t.stackedByDimension,h);for(var p=NaN,m=r-1;m>=0;m--){var g=e[m];if(s||(d=g.data.rawIndexOf(g.stackedByDimension,c)),d>=0){var y=g.data.getByRawIndex(g.stackResultDimension,d);if(l==="all"||l==="positive"&&y>0||l==="negative"&&y<0||l==="samesign"&&v>=0&&y>0||l==="samesign"&&v<=0&&y<0){v=KS(v,y),p=y;break}}}return n[0]=v,n[1]=p,n})})}var dl=(function(){function e(t){this.data=t.data||(t.sourceFormat===sr?{}:[]),this.sourceFormat=t.sourceFormat||Rm,this.seriesLayoutBy=t.seriesLayoutBy||tr,this.startIndex=t.startIndex||0,this.dimensionsDetectedCount=t.dimensionsDetectedCount,this.metaRawOption=t.metaRawOption;var r=this.dimensionsDefine=t.dimensionsDefine;if(r)for(var n=0;n<r.length;n++){var i=r[n];i.type==null&&Ry(this,n)===se.Must&&(i.type="ordinal")}}return e})();function lv(e){return e instanceof dl}function Rf(e,t,r){r=r||Ny(e);var n=t.seriesLayoutBy,i=vC(e,r,n,t.sourceHeader,t.dimensions),a=new dl({data:e,sourceFormat:r,seriesLayoutBy:n,dimensionsDefine:i.dimensionsDefine,startIndex:i.startIndex,dimensionsDetectedCount:i.dimensionsDetectedCount,metaRawOption:ut(t)});return a}function By(e){return new dl({data:e,sourceFormat:ae(e)?Or:ve})}function hC(e){return new dl({data:e.data,sourceFormat:e.sourceFormat,seriesLayoutBy:e.seriesLayoutBy,dimensionsDefine:ut(e.dimensionsDefine),startIndex:e.startIndex,dimensionsDetectedCount:e.dimensionsDetectedCount})}function Ny(e){var t=Rm;if(ae(e))t=Or;else if(H(e)){e.length===0&&(t=Zt);for(var r=0,n=e.length;r<n;r++){var i=e[r];if(i!=null){if(H(i)||ae(i)){t=Zt;break}else if(K(i)){t=Ne;break}}}}else if(K(e)){for(var a in e)if(fe(e,a)&&ie(e[a])){t=sr;break}}return t}function vC(e,t,r,n,i){var a,o;if(!e)return{dimensionsDefine:Ld(i),startIndex:o,dimensionsDetectedCount:a};if(t===Zt){var s=e;n==="auto"||n==null?Id(function(u){u!=null&&u!=="-"&&(W(u)?o==null&&(o=1):o=0)},r,s,10):o=Ct(n)?n:n?1:0,!i&&o===1&&(i=[],Id(function(u,f){i[f]=u!=null?u+"":""},r,s,1/0)),a=i?i.length:r===En?s.length:s[0]?s[0].length:null}else if(t===Ne)i||(i=cC(e));else if(t===sr)i||(i=[],D(e,function(u,f){i.push(f)}));else if(t===ve){var l=za(e[0]);a=H(l)&&l.length||1}return{startIndex:o,dimensionsDefine:Ld(i),dimensionsDetectedCount:a}}function cC(e){for(var t=0,r;t<e.length&&!(r=e[t++]););if(r)return xt(r)}function Ld(e){if(e){var t=nt();return rt(e,function(r,n){r=K(r)?r:{name:r};var i={name:r.name,displayName:r.displayName,type:r.type};if(i.name==null)return i;i.name+="",i.displayName==null&&(i.displayName=i.name);var a=t.get(i.name);return a?i.name+="-"+a.count++:t.set(i.name,{count:1}),i})}}function Id(e,t,r,n){if(t===En)for(var i=0;i<r.length&&i<n;i++)e(r[i]?r[i][0]:null,i);else for(var a=r[0]||[],i=0;i<a.length&&i<n;i++)e(a[i],i)}function Fy(e){var t=e.sourceFormat;return t===Ne||t===sr}var hn,vn,cn,dn,Pd,Ed,zy=(function(){function e(t,r){var n=lv(t)?t:By(t);this._source=n;var i=this._data=n.data,a=n.sourceFormat;n.seriesLayoutBy,a===Or&&(this._offset=0,this._dimSize=r,this._data=i),Ed(this,i,n)}return e.prototype.getSource=function(){return this._source},e.prototype.count=function(){return 0},e.prototype.getItem=function(t,r){},e.prototype.appendData=function(t){},e.prototype.clean=function(){},e.protoInitialize=(function(){var t=e.prototype;t.pure=!1,t.persistent=!0})(),e.internalField=(function(){var t;Ed=function(o,s,l){var u=l.sourceFormat,f=l.seriesLayoutBy,h=l.startIndex,v=l.dimensionsDefine,c=Pd[uv(u,f)];if(N(o,c),u===Or)o.getItem=r,o.count=i,o.fillStorage=n;else{var d=Hy(u,f);o.getItem=wt(d,null,s,h,v);var p=Vy(u,f);o.count=wt(p,null,s,h,v)}};var r=function(o,s){o=o-this._offset,s=s||[];for(var l=this._data,u=this._dimSize,f=u*o,h=0;h<u;h++)s[h]=l[f+h];return s},n=function(o,s,l,u){for(var f=this._data,h=this._dimSize,v=0;v<h;v++){for(var c=u[v],d=c[0]==null?1/0:c[0],p=c[1]==null?-1/0:c[1],m=s-o,g=l[v],y=0;y<m;y++){var _=f[y*h+v];g[o+y]=_,_<d&&(d=_),_>p&&(p=_)}c[0]=d,c[1]=p}},i=function(){return this._data?this._data.length/this._dimSize:0};Pd=(t={},t[Zt+"_"+tr]={pure:!0,appendData:a},t[Zt+"_"+En]={pure:!0,appendData:function(){throw new Error('Do not support appendData when set seriesLayoutBy: "row".')}},t[Ne]={pure:!0,appendData:a},t[sr]={pure:!0,appendData:function(o){var s=this._data;D(o,function(l,u){for(var f=s[u]||(s[u]=[]),h=0;h<(l||[]).length;h++)f.push(l[h])})}},t[ve]={appendData:a},t[Or]={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])}})(),e})(),wo=function(e){H(e)||dm("series.data or dataset.source must be an array.")};hn={},hn[Zt+"_"+tr]=wo,hn[Zt+"_"+En]=wo,hn[Ne]=wo,hn[sr]=function(e,t){for(var r=0;r<t.length;r++){var n=t[r].name;n==null&&dm("dimension name must not be null/undefined.")}},hn[ve]=wo;var Rd=function(e,t,r,n){return e[n]},dC=(vn={},vn[Zt+"_"+tr]=function(e,t,r,n){return e[n+t]},vn[Zt+"_"+En]=function(e,t,r,n,i){n+=t;for(var a=i||[],o=e,s=0;s<o.length;s++){var l=o[s];a[s]=l?l[n]:null}return a},vn[Ne]=Rd,vn[sr]=function(e,t,r,n,i){for(var a=i||[],o=0;o<r.length;o++){var s=r[o].name,l=s!=null?e[s]:null;a[o]=l?l[n]:null}return a},vn[ve]=Rd,vn);function Hy(e,t){var r=dC[uv(e,t)];return r}var kd=function(e,t,r){return e.length},pC=(cn={},cn[Zt+"_"+tr]=function(e,t,r){return Math.max(0,e.length-t)},cn[Zt+"_"+En]=function(e,t,r){var n=e[0];return n?Math.max(0,n.length-t):0},cn[Ne]=kd,cn[sr]=function(e,t,r){var n=r[0].name,i=n!=null?e[n]:null;return i?i.length:0},cn[ve]=kd,cn);function Vy(e,t){var r=pC[uv(e,t)];return r}var _u=function(e,t,r){return e[t]},gC=(dn={},dn[Zt]=_u,dn[Ne]=function(e,t,r){return e[r]},dn[sr]=_u,dn[ve]=function(e,t,r){var n=za(e);return n instanceof Array?n[t]:n},dn[Or]=_u,dn);function Gy(e){var t=gC[e];return t}function uv(e,t){return e===Zt?e+"_"+t:e}function yi(e,t,r){if(e){var n=e.getRawDataItem(t);if(n!=null){var i=e.getStore(),a=i.getSource().sourceFormat;if(r!=null){var o=e.getDimensionIndex(r),s=i.getDimensionProperty(o);return Gy(a)(n,o,s)}else{var l=n;return a===ve&&(l=za(n)),l}}}}var mC=/\{@(.+?)\}/g,yC=(function(){function e(){}return e.prototype.getDataParams=function(t,r){var n=this.getData(r),i=this.getRawValue(t,r),a=n.getRawIndex(t),o=n.getName(t),s=n.getRawDataItem(t),l=n.getItemVisual(t,"style"),u=l&&l[n.getItemVisual(t,"drawType")||"fill"],f=l&&l.stroke,h=this.mainType,v=h==="series",c=n.userOutput&&n.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:r,value:i,color:u,borderColor:f,dimensionNames:c?c.fullDimensions:null,encode:c?c.encode:null,$vars:["seriesName","name","value"]}},e.prototype.getFormattedLabel=function(t,r,n,i,a,o){r=r||"normal";var s=this.getData(n),l=this.getDataParams(t,n);if(o&&(l.value=o.interpolatedValue),i!=null&&H(l.value)&&(l.value=l.value[i]),!a){var u=s.getItemModel(t);a=u.get(r==="normal"?["label","formatter"]:[r,"label","formatter"])}if(ot(a))return l.status=r,l.dimensionIndex=i,a(l);if(W(a)){var f=Cy(a,l);return f.replace(mC,function(h,v){var c=v.length,d=v;d.charAt(0)==="["&&d.charAt(c-1)==="]"&&(d=+d.slice(1,c-1));var p=yi(s,t,d);if(o&&H(o.interpolatedValue)){var m=s.getDimensionIndex(d);m>=0&&(p=o.interpolatedValue[m])}return p!=null?p+"":""})}},e.prototype.getRawValue=function(t,r){return yi(this.getData(r),t)},e.prototype.formatTooltip=function(t,r,n){},e})();function Od(e){var t,r;return K(e)?e.type&&(r=e):t=e,{text:t,frag:r}}function ha(e){return new _C(e)}var _C=(function(){function e(t){t=t||{},this._reset=t.reset,this._plan=t.plan,this._count=t.count,this._onDirty=t.onDirty,this._dirty=!0}return e.prototype.perform=function(t){var r=this._upstream,n=t&&t.skip;if(this._dirty&&r){var i=this.context;i.data=i.outputData=r.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var a;this._plan&&!n&&(a=this._plan(this.context));var o=f(this._modBy),s=this._modDataCount||0,l=f(t&&t.modBy),u=t&&t.modDataCount||0;(o!==l||s!==u)&&(a="reset");function f(y){return!(y>=1)&&(y=1),y}var h;(this._dirty||a==="reset")&&(this._dirty=!1,h=this._doReset(n)),this._modBy=l,this._modDataCount=u;var v=t&&t.step;if(r?this._dueEnd=r._outputDueEnd:this._dueEnd=this._count?this._count(this.context):1/0,this._progress){var c=this._dueIndex,d=Math.min(v!=null?this._dueIndex+v:1/0,this._dueEnd);if(!n&&(h||c<d)){var p=this._progress;if(H(p))for(var m=0;m<p.length;m++)this._doProgress(p[m],c,d,l,u);else this._doProgress(p,c,d,l,u)}this._dueIndex=d;var g=this._settedOutputEnd!=null?this._settedOutputEnd:d;this._outputDueEnd=g}else this._dueIndex=this._outputDueEnd=this._settedOutputEnd!=null?this._settedOutputEnd:this._dueEnd;return this.unfinished()},e.prototype.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},e.prototype._doProgress=function(t,r,n,i,a){Bd.reset(r,n,i,a),this._callingProgress=t,this._callingProgress({start:r,end:n,count:n-r,next:Bd.next},this.context)},e.prototype._doReset=function(t){this._dueIndex=this._outputDueEnd=this._dueEnd=0,this._settedOutputEnd=null;var r,n;!t&&this._reset&&(r=this._reset(this.context),r&&r.progress&&(n=r.forceFirstProgress,r=r.progress),H(r)&&!r.length&&(r=null)),this._progress=r,this._modBy=this._modDataCount=null;var i=this._downstream;return i&&i.dirty(),n},e.prototype.unfinished=function(){return this._progress&&this._dueIndex<this._dueEnd},e.prototype.pipe=function(t){(this._downstream!==t||this._dirty)&&(this._downstream=t,t._upstream=this,t.dirty())},e.prototype.dispose=function(){this._disposed||(this._upstream&&(this._upstream._downstream=null),this._downstream&&(this._downstream._upstream=null),this._dirty=!1,this._disposed=!0)},e.prototype.getUpstream=function(){return this._upstream},e.prototype.getDownstream=function(){return this._downstream},e.prototype.setOutputEnd=function(t){this._outputDueEnd=this._settedOutputEnd=t},e})(),Bd=(function(){var e,t,r,n,i,a={reset:function(l,u,f,h){t=l,e=u,r=f,n=h,i=Math.ceil(n/r),a.next=r>1&&n>0?s:o}};return a;function o(){return t<e?t++:null}function s(){var l=t%i*r+Math.ceil(t/i),u=t>=e?null:l<n?l:t;return t++,u}})();function is(e,t){var r=t&&t.type;return r==="ordinal"?e:(r==="time"&&!Ct(e)&&e!=null&&e!=="-"&&(e=+Di(e)),e==null||e===""?NaN:Number(e))}nt({number:function(e){return parseFloat(e)},time:function(e){return+Di(e)},trim:function(e){return W(e)?$e(e):e}});var SC=(function(){function e(t,r){var n=t==="desc";this._resultLT=n?1:-1,r==null&&(r=n?"min":"max"),this._incomparable=r==="min"?-1/0:1/0}return e.prototype.evaluate=function(t,r){var n=Ct(t)?t:Ss(t),i=Ct(r)?r:Ss(r),a=isNaN(n),o=isNaN(i);if(a&&(n=this._incomparable),o&&(i=this._incomparable),a&&o){var s=W(t),l=W(r);s&&(n=l?t:0),l&&(i=s?r:0)}return n<i?this._resultLT:n>i?-this._resultLT:0},e})();function bC(e){var t="",r=-1/0,n=-1/0,i=1/0,a=1/0;return e&&(e.g!=null&&(t+="G"+e.g,r=e.g),e.ge!=null&&(t+="GE"+e.ge,n=e.ge),e.l!=null&&(t+="L"+e.l,i=e.l),e.le!=null&&(t+="LE"+e.le,a=e.le)),{key:t,g:r,ge:n,l:i,le:a}}function TC(e,t){return t>e.g&&t>=e.ge&&t<e.l&&t<=e.le}var wC=(function(){function e(){}return e.prototype.getRawData=function(){throw new Error("not supported")},e.prototype.getRawDataItem=function(t){throw new Error("not supported")},e.prototype.cloneRawData=function(){},e.prototype.getDimensionInfo=function(t){},e.prototype.cloneAllDimensionInfo=function(){},e.prototype.count=function(){},e.prototype.retrieveValue=function(t,r){},e.prototype.retrieveValueFromItem=function(t,r){},e.prototype.convertValue=function(t,r){return is(t,r)},e})();function xC(e,t){var r=new wC,n=e.data,i=r.sourceFormat=e.sourceFormat,a=e.startIndex,o="";e.seriesLayoutBy!==tr&&re(o);var s=[],l={},u=e.dimensionsDefine;if(u)D(u,function(p,m){var g=p.name,y={index:m,name:g,displayName:p.displayName};if(s.push(y),g!=null){var _="";fe(l,g)&&re(_),l[g]=y}});else for(var f=0;f<e.dimensionsDetectedCount;f++)s.push({index:f});var h=Hy(i,tr);t.__isBuiltIn&&(r.getRawDataItem=function(p){return h(n,a,s,p)},r.getRawData=wt(CC,null,e)),r.cloneRawData=wt(DC,null,e);var v=Vy(i,tr);r.count=wt(v,null,n,a,s);var c=Gy(i);r.retrieveValue=function(p,m){var g=h(n,a,s,p);return d(g,m)};var d=r.retrieveValueFromItem=function(p,m){if(p!=null){var g=s[m];if(g)return c(p,m,g.name)}};return r.getDimensionInfo=wt(MC,null,s,l),r.cloneAllDimensionInfo=wt(AC,null,s),r}function CC(e){var t=e.sourceFormat;if(!fv(t)){var r="";re(r)}return e.data}function DC(e){var t=e.sourceFormat,r=e.data;if(!fv(t)){var n="";re(n)}if(t===Zt){for(var i=[],a=0,o=r.length;a<o;a++)i.push(r[a].slice());return i}else if(t===Ne){for(var i=[],a=0,o=r.length;a<o;a++)i.push(N({},r[a]));return i}}function MC(e,t,r){if(r!=null){if(Ct(r)||!isNaN(r)&&!fe(t,r))return e[r];if(fe(t,r))return t[r]}}function AC(e){return ut(e)}var Uy=nt();function LC(e){e=ut(e);var t=e.type,r="";t||re(r);var n=t.split(":");n.length!==2&&re(r);var i=!1;n[0]==="echarts"&&(t=n[1],i=!0),e.__isBuiltIn=i,Uy.set(t,e)}function IC(e,t,r){var n=Jt(e),i=n.length,a="";i||re(a);for(var o=0,s=i;o<s;o++){var l=n[o];t=PC(l,t),o!==s-1&&(t.length=Math.max(t.length,1))}return t}function PC(e,t,r,n){var i="";t.length||re(i),K(e)||re(i);var a=e.type,o=Uy.get(a);o||re(i);var s=rt(t,function(u){return xC(u,o)}),l=Jt(o.transform({upstream:s[0],upstreamList:s,config:ut(e.config)}));return rt(l,function(u,f){var h="";K(u)||re(h),u.data||re(h);var v=Ny(u.data);fv(v)||re(h);var c,d=t[0];if(d&&f===0&&!u.dimensions){var p=d.startIndex;p&&(u.data=d.data.slice(0,p).concat(u.data)),c={seriesLayoutBy:tr,sourceHeader:p,dimensions:d.metaRawOption.dimensions}}else c={seriesLayoutBy:tr,sourceHeader:0,dimensions:u.dimensions};return Rf(u.data,c,null)})}function fv(e){return e===Zt||e===Ne}var EC=typeof Uint32Array===Ga?Array:Uint32Array,RC=typeof Uint16Array===Ga?Array:Uint16Array,Wy=typeof Int32Array===Ga?Array:Int32Array,Nd=typeof Float64Array===Ga?Array:Float64Array,Yy={float:Nd,int:Wy,ordinal:Array,number:Array,time:Nd},Su;function Un(e){return e>65535?EC:RC}function kC(e){var t=e.constructor;return t===Array?e.slice():new t(e)}function Fd(e,t,r,n,i){var a=Yy[r||"float"];if(i){var o=e[t],s=o&&o.length;if(s!==n){for(var l=new a(n),u=0;u<s;u++)l[u]=o[u];e[t]=l}}else e[t]=new a(n)}var kf=(function(){function e(){this._chunks=[],this._rawExtent=[],this._extent=[],this._count=0,this._rawCount=0,this._calcDimNameToIdx=nt()}return e.prototype.initData=function(t,r,n){this._provider=t,this._chunks=[],this._indices=null,this.getRawIndex=this._getRawIdxIdentity;var i=t.getSource(),a=this.defaultDimValueGetter=Su[i.sourceFormat];this._dimValueGetter=n||a,this._rawExtent=[],Fy(i),this._dimensions=rt(r,function(o){return{type:o.type,property:o.property}}),this._initDataFromProvider(0,t.count())},e.prototype.getProvider=function(){return this._provider},e.prototype.getSource=function(){return this._provider.getSource()},e.prototype.ensureCalculationDimension=function(t,r){var n=this._calcDimNameToIdx,i=this._dimensions,a=n.get(t);if(a!=null){if(i[a].type===r)return a}else a=i.length;return i[a]={type:r},n.set(t,a),this._chunks[a]=new Yy[r||"float"](this._rawCount),this._rawExtent[a]=Te(),a},e.prototype.collectOrdinalMeta=function(t,r){var n=this._chunks[t],i=this._dimensions[t],a=this._rawExtent,o=i.ordinalOffset||0,s=n.length;o===0&&(a[t]=Te());for(var l=a[t],u=o;u<s;u++){var f=n[u]=r.parseAndCollect(n[u]);isNaN(f)||(l[0]=Math.min(f,l[0]),l[1]=Math.max(f,l[1]))}i.ordinalMeta=r,i.ordinalOffset=s,i.type="ordinal"},e.prototype.getOrdinalMeta=function(t){var r=this._dimensions[t],n=r.ordinalMeta;return n},e.prototype.getDimensionProperty=function(t){var r=this._dimensions[t];return r&&r.property},e.prototype.appendData=function(t){var r=this._provider,n=this.count();r.appendData(t);var i=r.count();return r.persistent||(i+=n),n<i&&this._initDataFromProvider(n,i,!0),[n,i]},e.prototype.appendValues=function(t,r){for(var n=this._chunks,i=this._dimensions,a=i.length,o=this._rawExtent,s=this.count(),l=s+Math.max(t.length,r||0),u=0;u<a;u++){var f=i[u];Fd(n,u,f.type,l,!0)}for(var h=[],v=s;v<l;v++)for(var c=v-s,d=0;d<a;d++){var f=i[d],p=Su.arrayRows.call(this,t[c]||h,f.property,c,d);n[d][v]=p;var m=o[d];p<m[0]&&(m[0]=p),p>m[1]&&(m[1]=p)}return this._rawCount=this._count=l,{start:s,end:l}},e.prototype._initDataFromProvider=function(t,r,n){for(var i=this._provider,a=this._chunks,o=this._dimensions,s=o.length,l=this._rawExtent,u=rt(o,function(y){return y.property}),f=0;f<s;f++){var h=o[f];l[f]||(l[f]=Te()),Fd(a,f,h.type,r,n)}if(i.fillStorage)i.fillStorage(t,r,a,l);else for(var v=[],c=t;c<r;c++){v=i.getItem(c,v);for(var d=0;d<s;d++){var p=a[d],m=this._dimValueGetter(v,u[d],c,d);p[c]=m;var g=l[d];m<g[0]&&(g[0]=m),m>g[1]&&(g[1]=m)}}!i.persistent&&i.clean&&i.clean(),this._rawCount=this._count=r,this._extent=[]},e.prototype.count=function(){return this._count},e.prototype.get=function(t,r){if(!(r>=0&&r<this._count))return NaN;var n=this._chunks[t];return n?n[this.getRawIndex(r)]:NaN},e.prototype.getValues=function(t,r){var n=[],i=[];if(r==null){r=t,t=[];for(var a=0;a<this._dimensions.length;a++)i.push(a)}else i=t;for(var a=0,o=i.length;a<o;a++)n.push(this.get(i[a],r));return n},e.prototype.getByRawIndex=function(t,r){if(!(r>=0&&r<this._rawCount))return NaN;var n=this._chunks[t];return n?n[r]:NaN},e.prototype.getSum=function(t){var r=this._chunks[t],n=0;if(r)for(var i=0,a=this.count();i<a;i++){var o=this.get(t,i);isNaN(o)||(n+=o)}return n},e.prototype.getMedian=function(t){var r=[];this.each([t],function(i){isNaN(i)||r.push(i)}),lm(r);var n=this.count();return n===0?0:n%2===1?r[(n-1)/2]:(r[n/2]+r[n/2-1])/2},e.prototype.indexOfRawIndex=function(t){if(t>=this._rawCount||t<0)return-1;if(!this._indices)return t;var r=this._indices,n=r[t];if(n!=null&&n<this._count&&n===t)return t;for(var i=0,a=this._count-1;i<=a;){var o=(i+a)/2|0;if(r[o]<t)i=o+1;else if(r[o]>t)a=o-1;else return o}return-1},e.prototype.getIndices=function(){var t,r=this._indices;if(r){var n=r.constructor,i=this._count;if(n===Array){t=new n(i);for(var a=0;a<i;a++)t[a]=r[a]}else t=new n(r.buffer,0,i)}else{var n=Un(this._rawCount);t=new n(this.count());for(var a=0;a<t.length;a++)t[a]=a}return t},e.prototype.filter=function(t,r){if(!this._count)return this;for(var n=this.clone(),i=n.count(),a=Un(n._rawCount),o=new a(i),s=[],l=t.length,u=0,f=t[0],h=n._chunks,v=0;v<i;v++){var c=void 0,d=n.getRawIndex(v);if(l===0)c=r(v);else if(l===1){var p=h[f][d];c=r(p,v)}else{for(var m=0;m<l;m++)s[m]=h[t[m]][d];s[m]=v,c=r.apply(null,s)}c&&(o[u++]=d)}return u<i&&(n._indices=o),n._count=u,n._extent=[],n._updateGetRawIdx(),n},e.prototype.selectRange=function(t){var r=this.clone(),n=r._count;if(!n)return this;var i=xt(t),a=i.length;if(!a)return this;var o=r.count(),s=Un(r._rawCount),l=new s(o),u=0,f=i[0],h=t[f][0],v=t[f][1],c=r._chunks,d=!1;if(!r._indices){var p=0;if(a===1){for(var m=c[i[0]],g=0;g<n;g++){var y=m[g];(y>=h&&y<=v||isNaN(y))&&(l[u++]=p),p++}d=!0}else if(a===2){for(var m=c[i[0]],_=c[i[1]],S=t[i[1]][0],b=t[i[1]][1],g=0;g<n;g++){var y=m[g],T=_[g];(y>=h&&y<=v||isNaN(y))&&(T>=S&&T<=b||isNaN(T))&&(l[u++]=p),p++}d=!0}}if(!d)if(a===1)for(var g=0;g<o;g++){var w=r.getRawIndex(g),y=c[i[0]][w];(y>=h&&y<=v||isNaN(y))&&(l[u++]=w)}else for(var g=0;g<o;g++){for(var M=!0,w=r.getRawIndex(g),C=0;C<a;C++){var x=i[C],y=c[x][w];(y<t[x][0]||y>t[x][1])&&(M=!1)}M&&(l[u++]=r.getRawIndex(g))}return u<o&&(r._indices=l),r._count=u,r._extent=[],r._updateGetRawIdx(),r},e.prototype.map=function(t,r){var n=this.clone(t);return this._updateDims(n,t,r),n},e.prototype.modify=function(t,r){this._updateDims(this,t,r)},e.prototype._updateDims=function(t,r,n){for(var i=t._chunks,a=[],o=r.length,s=t.count(),l=[],u=t._rawExtent,f=0;f<r.length;f++)u[r[f]]=Te();for(var h=0;h<s;h++){for(var v=t.getRawIndex(h),c=0;c<o;c++)l[c]=i[r[c]][v];l[o]=h;var d=n&&n.apply(null,l);if(d!=null){typeof d!="object"&&(a[0]=d,d=a);for(var f=0;f<d.length;f++){var p=r[f],m=d[f],g=u[p],y=i[p];y&&(y[v]=m),m<g[0]&&(g[0]=m),m>g[1]&&(g[1]=m)}}}},e.prototype.lttbDownSample=function(t,r){var n=this.clone([t],!0),i=n._chunks,a=i[t],o=this.count(),s=0,l=Math.floor(1/r),u=this.getRawIndex(0),f,h,v,c=new(Un(this._rawCount))(Math.min((Math.ceil(o/l)+2)*2,o));c[s++]=u;for(var d=1;d<o-1;d+=l){for(var p=Math.min(d+l,o-1),m=Math.min(d+l*2,o),g=(m+p)/2,y=0,_=p;_<m;_++){var S=this.getRawIndex(_),b=a[S];isNaN(b)||(y+=b)}y/=m-p;var T=d,w=Math.min(d+l,o),M=d-1,C=a[u];f=-1,v=T;for(var x=-1,A=0,_=T;_<w;_++){var S=this.getRawIndex(_),b=a[S];if(isNaN(b)){A++,x<0&&(x=S);continue}h=Math.abs((M-g)*(b-C)-(M-_)*(y-C)),h>f&&(f=h,v=S)}A>0&&A<w-T&&(c[s++]=Math.min(x,v),v=Math.max(x,v)),c[s++]=v,u=v}return c[s++]=this.getRawIndex(o-1),n._count=s,n._indices=c,n.getRawIndex=this._getRawIdx,n},e.prototype.minmaxDownSample=function(t,r){for(var n=this.clone([t],!0),i=n._chunks,a=Math.floor(1/r),o=i[t],s=this.count(),l=new(Un(this._rawCount))(Math.ceil(s/a)*2),u=0,f=0;f<s;f+=a){var h=f,v=o[this.getRawIndex(h)],c=f,d=o[this.getRawIndex(c)],p=a;f+a>s&&(p=s-f);for(var m=0;m<p;m++){var g=this.getRawIndex(f+m),y=o[g];y<v&&(v=y,h=f+m),y>d&&(d=y,c=f+m)}var _=this.getRawIndex(h),S=this.getRawIndex(c);h<c?(l[u++]=_,l[u++]=S):(l[u++]=S,l[u++]=_)}return n._count=u,n._indices=l,n._updateGetRawIdx(),n},e.prototype.downSample=function(t,r,n,i){for(var a=this.clone([t],!0),o=a._chunks,s=[],l=Math.floor(1/r),u=o[t],f=this.count(),h=a._rawExtent[t]=Te(),v=new(Un(this._rawCount))(Math.ceil(f/l)),c=0,d=0;d<f;d+=l){l>f-d&&(l=f-d,s.length=l);for(var p=0;p<l;p++){var m=this.getRawIndex(d+p);s[p]=u[m]}var g=n(s),y=this.getRawIndex(Math.min(d+i(s,g)||0,f-1));u[y]=g,g<h[0]&&(h[0]=g),g>h[1]&&(h[1]=g),v[c++]=y}return a._count=c,a._indices=v,a._updateGetRawIdx(),a},e.prototype.each=function(t,r){if(this._count)for(var n=t.length,i=this._chunks,a=0,o=this.count();a<o;a++){var s=this.getRawIndex(a);switch(n){case 0:r(a);break;case 1:r(i[t[0]][s],a);break;case 2:r(i[t[0]][s],i[t[1]][s],a);break;default:for(var l=0,u=[];l<n;l++)u[l]=i[t[l]][s];u[l]=a,r.apply(null,u)}}},e.prototype.getDataExtent=function(t,r){var n=this._chunks[t],i=Te();if(!n)return i;var a=this.count(),o=!this._indices&&!r;if(o)return this._rawExtent[t].slice();var s=this._extent,l=s[t]||(s[t]={}),u=bC(r),f=u.key,h=l[f];if(h)return h.slice();for(var v=i[0],c=i[1],d=0;d<a;d++){var p=this.getRawIndex(d),m=n[p];(!r||TC(u,m))&&(m<v&&(v=m),m>c&&(c=m))}return l[f]=[v,c]},e.prototype.getRawDataItem=function(t){var r=this.getRawIndex(t);if(this._provider.persistent)return this._provider.getItem(r);for(var n=[],i=this._chunks,a=0;a<i.length;a++)n.push(i[a][r]);return n},e.prototype.clone=function(t,r){var n=new e,i=this._chunks,a=t&&wi(t,function(s,l){return s[l]=!0,s},{});if(a)for(var o=0;o<i.length;o++)n._chunks[o]=a[o]?kC(i[o]):i[o];else n._chunks=i;return this._copyCommonProps(n),r||(n._indices=this._cloneIndices()),n._updateGetRawIdx(),n},e.prototype._copyCommonProps=function(t){t._count=this._count,t._rawCount=this._rawCount,t._provider=this._provider,t._dimensions=this._dimensions,t._extent=ut(this._extent),t._rawExtent=ut(this._rawExtent)},e.prototype._cloneIndices=function(){if(this._indices){var t=this._indices.constructor,r=void 0;if(t===Array){var n=this._indices.length;r=new t(n);for(var i=0;i<n;i++)r[i]=this._indices[i]}else r=new t(this._indices);return r}return null},e.prototype._getRawIdxIdentity=function(t){return t},e.prototype._getRawIdx=function(t){return t<this._count&&t>=0?this._indices[t]:-1},e.prototype._updateGetRawIdx=function(){this.getRawIndex=this._indices?this._getRawIdx:this._getRawIdxIdentity},e.internalField=(function(){function t(r,n,i,a){return is(r[a],this._dimensions[a])}Su={arrayRows:t,objectRows:function(r,n,i,a){return is(r[n],this._dimensions[a])},keyedColumns:t,original:function(r,n,i,a){var o=r&&(r.value==null?r:r.value);return is(o instanceof Array?o[a]:o,this._dimensions[a])},typedArray:function(r,n,i,a){return r[a]}}})(),e})(),OC=(function(){function e(t){this._sourceList=[],this._storeList=[],this._upstreamSignList=[],this._versionSignBase=0,this._dirty=!0,this._sourceHost=t}return e.prototype.dirty=function(){this._setLocalSource([],[]),this._storeList=[],this._dirty=!0},e.prototype._setLocalSource=function(t,r){this._sourceList=t,this._upstreamSignList=r,this._versionSignBase++,this._versionSignBase>9e10&&(this._versionSignBase=0)},e.prototype._getVersionSign=function(){return this._sourceHost.uid+"_"+this._versionSignBase},e.prototype.prepareSource=function(){this._isDirty()&&(this._createSource(),this._dirty=!1)},e.prototype._createSource=function(){this._setLocalSource([],[]);var t=this._sourceHost,r=this._getUpstreamSourceManagers(),n=!!r.length,i,a;if(xo(t)){var o=t,s=void 0,l=void 0,u=void 0;if(n){var f=r[0];f.prepareSource(),u=f.getSource(),s=u.data,l=u.sourceFormat,a=[f._getVersionSign()]}else s=o.get("data",!0),l=ae(s)?Or:ve,a=[];var h=this._getSourceMetaRawOption()||{},v=u&&u.metaRawOption||{},c=j(h.seriesLayoutBy,v.seriesLayoutBy)||null,d=j(h.sourceHeader,v.sourceHeader),p=j(h.dimensions,v.dimensions),m=c!==v.seriesLayoutBy||!!d!=!!v.sourceHeader||p;i=m?[Rf(s,{seriesLayoutBy:c,sourceHeader:d,dimensions:p},l)]:[]}else{var g=t;if(n){var y=this._applyTransform(r);i=y.sourceList,a=y.upstreamSignList}else{var _=g.get("source",!0);i=[Rf(_,this._getSourceMetaRawOption(),null)],a=[]}}this._setLocalSource(i,a)},e.prototype._applyTransform=function(t){var r=this._sourceHost,n=r.get("transform",!0),i=r.get("fromTransformResult",!0);if(i!=null){var a="";t.length!==1&&zd(a)}var o,s=[],l=[];return D(t,function(u){u.prepareSource();var f=u.getSource(i||0),h="";i!=null&&!f&&zd(h),s.push(f),l.push(u._getVersionSign())}),n?o=IC(n,s,{datasetIndex:r.componentIndex}):i!=null&&(o=[hC(s[0])]),{sourceList:o,upstreamSignList:l}},e.prototype._isDirty=function(){if(this._dirty)return!0;for(var t=this._getUpstreamSourceManagers(),r=0;r<t.length;r++){var n=t[r];if(n._isDirty()||this._upstreamSignList[r]!==n._getVersionSign())return!0}},e.prototype.getSource=function(t){t=t||0;var r=this._sourceList[t];if(!r){var n=this._getUpstreamSourceManagers();return n[0]&&n[0].getSource(t)}return r},e.prototype.getSharedDataStore=function(t){var r=t.makeStoreSchema();return this._innerGetDataStore(r.dimensions,t.source,r.hash)},e.prototype._innerGetDataStore=function(t,r,n){var i=0,a=this._storeList,o=a[i];o||(o=a[i]={});var s=o[n];if(!s){var l=this._getUpstreamSourceManagers()[0];xo(this._sourceHost)&&l?s=l._innerGetDataStore(t,r,n):(s=new kf,s.initData(new zy(r,t.length),t)),o[n]=s}return s},e.prototype._getUpstreamSourceManagers=function(){var t=this._sourceHost;if(xo(t)){var r=Ey(t);return r?[r.getSourceManager()]:[]}else return rt(zx(t),function(n){return n.getSourceManager()})},e.prototype._getSourceMetaRawOption=function(){var t=this._sourceHost,r,n,i;if(xo(t))r=t.get("seriesLayoutBy",!0),n=t.get("sourceHeader",!0),i=t.get("dimensions",!0);else if(!this._getUpstreamSourceManagers().length){var a=t;r=a.get("seriesLayoutBy",!0),n=a.get("sourceHeader",!0),i=a.get("dimensions",!0)}return{seriesLayoutBy:r,sourceHeader:n,dimensions:i}},e})();function xo(e){return e.mainType==="series"}function zd(e){throw new Error(e)}var BC="line-height:1";function Xy(e){var t=e.lineHeight;return t==null?BC:"line-height:"+te(t+"")+"px"}function $y(e,t){var r=e.color||J.color.tertiary,n=e.fontSize||12,i=e.fontWeight||"400",a=e.color||J.color.secondary,o=e.fontSize||14,s=e.fontWeight||"900";return t==="html"?{nameStyle:"font-size:"+te(n+"")+"px;color:"+te(r)+";font-weight:"+te(i+""),valueStyle:"font-size:"+te(o+"")+"px;color:"+te(a)+";font-weight:"+te(s+"")}:{nameStyle:{fontSize:n,fill:r,fontWeight:i},valueStyle:{fontSize:o,fill:a,fontWeight:s}}}var NC=[0,10,20,30],FC=["",`
|
|
30
|
+
`,`
|
|
31
|
+
|
|
32
|
+
`,`
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
`];function Da(e,t){return t.type=e,t}function Of(e){return e.type==="section"}function Zy(e){return Of(e)?zC:HC}function qy(e){if(Of(e)){var t=0,r=e.blocks.length,n=r>1||r>0&&!e.noHeader;return D(e.blocks,function(i){var a=qy(i);a>=t&&(t=a+ +(n&&(!a||Of(i)&&!i.noHeader)))}),t}return 0}function zC(e,t,r,n){var i=t.noHeader,a=VC(qy(t)),o=[],s=t.blocks||[];pr(!s||H(s)),s=s||[];var l=e.orderMode;if(t.sortBlocks&&l){s=s.slice();var u={valueAsc:"asc",valueDesc:"desc"};if(fe(u,l)){var f=new SC(u[l],null);s.sort(function(p,m){return f.evaluate(p.sortParam,m.sortParam)})}else l==="seriesDesc"&&s.reverse()}D(s,function(p,m){var g=t.valueFormatter,y=Zy(p)(g?N(N({},e),{valueFormatter:g}):e,p,m>0?a.html:0,n);y!=null&&o.push(y)});var h=e.renderMode==="richText"?o.join(a.richText):Bf(n,o.join(""),i?r:a.html);if(i)return h;var v=Ef(t.header,"ordinal",e.useUTC),c=$y(n,e.renderMode).nameStyle,d=Xy(n);return e.renderMode==="richText"?Ky(e,v,c)+a.richText+h:Bf(n,'<div style="'+c+";"+d+';">'+te(v)+"</div>"+h,r)}function HC(e,t,r,n){var i=e.renderMode,a=t.noName,o=t.noValue,s=!t.markerType,l=t.name,u=e.useUTC,f=t.valueFormatter||e.valueFormatter||function(S){return S=H(S)?S:[S],rt(S,function(b,T){return Ef(b,H(c)?c[T]:c,u)})};if(!(a&&o)){var h=s?"":e.markupStyleCreator.makeTooltipMarker(t.markerType,t.markerColor||J.color.secondary,i),v=a?"":Ef(l,"ordinal",u),c=t.valueType,d=o?[]:f(t.value,t.rawDataIndex),p=!s||!a,m=!s&&a,g=$y(n,i),y=g.nameStyle,_=g.valueStyle;return i==="richText"?(s?"":h)+(a?"":Ky(e,v,y))+(o?"":WC(e,d,p,m,_)):Bf(n,(s?"":h)+(a?"":GC(v,!s,y))+(o?"":UC(d,p,m,_)),r)}}function Hd(e,t,r,n,i,a){if(e){var o=Zy(e),s={useUTC:i,renderMode:r,orderMode:n,markupStyleCreator:t,valueFormatter:e.valueFormatter};return o(s,e,0,a)}}function VC(e){return{html:NC[e],richText:FC[e]}}function Bf(e,t,r){var n='<div style="clear:both"></div>',i="margin: "+r+"px 0 0",a=Xy(e);return'<div style="'+i+";"+a+';">'+t+n+"</div>"}function GC(e,t,r){var n=t?"margin-left:2px":"";return'<span style="'+r+";"+n+'">'+te(e)+"</span>"}function UC(e,t,r,n){var i=r?"10px":"20px",a=t?"float:right;margin-left:"+i:"";return e=H(e)?e:[e],'<span style="'+a+";"+n+'">'+rt(e,function(o){return te(o)}).join(" ")+"</span>"}function Ky(e,t,r){return e.markupStyleCreator.wrapRichTextStyle(t,r)}function WC(e,t,r,n,i){var a=[i],o=n?10:20;return r&&a.push({padding:[0,0,0,o],align:"right"}),e.markupStyleCreator.wrapRichTextStyle(H(t)?t.join(" "):t,a)}function YC(e,t){var r=e.getData().getItemVisual(t,"style"),n=r[e.visualDrawType];return In(n)}function Qy(e,t){var r=e.get("padding");return r??(t==="richText"?[8,10]:10)}var bu=(function(){function e(){this.richTextStyles={},this._nextStyleNameId=vm()}return e.prototype._generateStyleName=function(){return"__EC_aUTo_"+this._nextStyleNameId++},e.prototype.makeTooltipMarker=function(t,r,n){var i=n==="richText"?this._generateStyleName():null,a=Tx({color:r,type:t,renderMode:n,markerId:i});return W(a)?a:(this.richTextStyles[i]=a.style,a.content)},e.prototype.wrapRichTextStyle=function(t,r){var n={};H(r)?D(r,function(a){return N(n,a)}):N(n,r);var i=this._generateStyleName();return this.richTextStyles[i]=n,"{"+i+"|"+t+"}"},e})();function XC(e){var t=e.series,r=e.dataIndex,n=e.multipleSeries,i=t.getData(),a=i.mapDimensionsAll("defaultedTooltip"),o=a.length,s=t.getRawValue(r),l=H(s),u=YC(t,r),f,h,v,c;if(o>1||l&&!o){var d=$C(s,t,r,a,u);f=d.inlineValues,h=d.inlineValueTypes,v=d.blocks,c=d.inlineValues[0]}else if(o){var p=i.getDimensionInfo(a[0]);c=f=yi(i,r,a[0]),h=p.type}else c=f=l?s[0]:s;var m=bh(t),g=m&&t.name||"",y=i.getName(r),_=n?g:y;return Da("section",{header:g,noHeader:n||!m,sortParam:c,blocks:[Da("nameValue",{markerType:"item",markerColor:u,name:_,noName:!$e(_),value:f,valueType:h,rawDataIndex:i.getRawIndex(r)})].concat(v||[])})}function $C(e,t,r,n,i){var a=t.getData(),o=wi(e,function(h,v,c){var d=a.getDimensionInfo(c);return h=h||d&&d.tooltip!==!1&&d.displayName!=null},!1),s=[],l=[],u=[];n.length?D(n,function(h){f(yi(a,r,h),h)}):D(e,f);function f(h,v){var c=a.getDimensionInfo(v);!c||c.otherDims.tooltip===!1||(o?u.push(Da("nameValue",{markerType:"subItem",markerColor:i,name:c.displayName,value:h,valueType:c.type})):(s.push(h),l.push(c.type)))}return{inlineValues:s,inlineValueTypes:l,blocks:u}}var wr=bt();function Co(e,t){return e.getName(t)||e.getId(t)}var ZC="__universalTransitionEnabled",Vr=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r._selectedDataIndicesMap={},r}return t.prototype.init=function(r,n,i){this.seriesIndex=this.componentIndex,this.dataTask=ha({count:KC,reset:QC}),this.dataTask.context={model:this},this.mergeDefaultAndTheme(r,i);var a=wr(this).sourceManager=new OC(this);a.prepareSource();var o=this.getInitialData(r,i);Gd(o,this),this.dataTask.context.data=o,wr(this).dataBeforeProcessed=o,Vd(this),this._initSelectedMapFromData(o)},t.prototype.mergeDefaultAndTheme=function(r,n){var i=xa(this),a=i?Wa(r):{},o=this.subType;pt.hasClass(o)&&(o+="Series"),ct(r,n.getTheme().get(this.subType)),ct(r,this.getDefaultOption()),bc(r,"label",["show"]),this.fillDataTextStyle(r.data),i&&Hr(r,a,i)},t.prototype.mergeOption=function(r,n){r=ct(this.option,r,!0),this.fillDataTextStyle(r.data);var i=xa(this);i&&Hr(this.option,r,i);var a=wr(this).sourceManager;a.dirty(),a.prepareSource();var o=this.getInitialData(r,n);Gd(o,this),this.dataTask.dirty(),this.dataTask.context.data=o,wr(this).dataBeforeProcessed=o,Vd(this),this._initSelectedMapFromData(o)},t.prototype.fillDataTextStyle=function(r){if(r&&!ae(r))for(var n=["show"],i=0;i<r.length;i++)r[i]&&r[i].label&&bc(r[i],"label",n)},t.prototype.getInitialData=function(r,n){},t.prototype.appendData=function(r){var n=this.getRawData();n.appendData(r.data)},t.prototype.getData=function(r){var n=Nf(this);if(n){var i=n.context.data;return r==null||!i.getLinkedData?i:i.getLinkedData(r)}else return wr(this).data},t.prototype.getAllData=function(){var r=this.getData();return r&&r.getLinkedDataAll?r.getLinkedDataAll():[{data:r}]},t.prototype.setData=function(r){var n=Nf(this);if(n){var i=n.context;i.outputData=r,n!==this.dataTask&&(i.data=r)}wr(this).data=r},t.prototype.getEncode=function(){var r=this.get("encode",!0);if(r)return nt(r)},t.prototype.getSourceManager=function(){return wr(this).sourceManager},t.prototype.getSource=function(){return this.getSourceManager().getSource()},t.prototype.getRawData=function(){return wr(this).dataBeforeProcessed},t.prototype.getColorBy=function(){var r=this.get("colorBy");return r||"series"},t.prototype.isColorBySeries=function(){return this.getColorBy()==="series"},t.prototype.getBaseAxis=function(){var r=this.coordinateSystem;return r&&r.getBaseAxis&&r.getBaseAxis()},t.prototype.indicesOfNearest=function(r,n,i,a){var o=this.getData(),s=this.coordinateSystem,l=s&&s.getAxis(r);if(!s||!l)return[];var u=l.dataToCoord(i);a==null&&(a=1/0);for(var f=[],h=1/0,v=-1,c=0,d=o.getDimensionIndex(n),p=o.getStore(),m=0,g=p.count();m<g;m++){var y=p.get(d,m),_=l.dataToCoord(y),S=u-_,b=Math.abs(S);b<=a&&((b<h||b===h&&S>=0&&v<0)&&(h=b,v=S,c=0),S===v&&(f[c++]=m))}return f.length=c,f},t.prototype.formatTooltip=function(r,n,i){return XC({series:this,dataIndex:r,multipleSeries:n})},t.prototype.isAnimationEnabled=function(){var r=this.ecModel;if(st.node&&!(r&&r.ssr))return!1;var n=this.getShallow("animation");return n&&this.getData().count()>this.getShallow("animationThreshold")&&(n=!1),!!n},t.prototype.restoreData=function(){this.dataTask.dirty()},t.prototype.getColorFromPalette=function(r,n,i){var a=this.ecModel,o=ov.prototype.getColorFromPalette.call(this,r,n,i);return o||(o=a.getColorFromPalette(r,n,i)),o},t.prototype.coordDimToDataDim=function(r){return this.getRawData().mapDimensionsAll(r)},t.prototype.getProgressive=function(){return this.get("progressive")},t.prototype.getProgressiveThreshold=function(){return this.get("progressiveThreshold")},t.prototype.select=function(r,n){this._innerSelect(this.getData(n),r)},t.prototype.unselect=function(r,n){var i=this.option.selectedMap;if(i){var a=this.option.selectedMode,o=this.getData(n);if(a==="series"||i==="all"){this.option.selectedMap={},this._selectedDataIndicesMap={};return}for(var s=0;s<r.length;s++){var l=r[s],u=Co(o,l);i[u]=!1,this._selectedDataIndicesMap[u]=-1}}},t.prototype.toggleSelect=function(r,n){for(var i=[],a=0;a<r.length;a++)i[0]=r[a],this.isSelected(r[a],n)?this.unselect(i,n):this.select(i,n)},t.prototype.getSelectedDataIndices=function(){if(this.option.selectedMap==="all")return[].slice.call(this.getData().getIndices());for(var r=this._selectedDataIndicesMap,n=xt(r),i=[],a=0;a<n.length;a++){var o=r[n[a]];o>=0&&i.push(o)}return i},t.prototype.isSelected=function(r,n){var i=this.option.selectedMap;if(!i)return!1;var a=this.getData(n);return(i==="all"||i[Co(a,r)])&&!a.getItemModel(r).get(["select","disabled"])},t.prototype.isUniversalTransitionEnabled=function(){if(this[ZC])return!0;var r=this.option.universalTransition;return r?r===!0?!0:r&&r.enabled:!1},t.prototype._innerSelect=function(r,n){var i,a,o=this.option,s=o.selectedMode,l=n.length;if(!(!s||!l)){if(s==="series")o.selectedMap="all";else if(s==="multiple"){K(o.selectedMap)||(o.selectedMap={});for(var u=o.selectedMap,f=0;f<l;f++){var h=n[f],v=Co(r,h);u[v]=!0,this._selectedDataIndicesMap[v]=r.getRawIndex(h)}}else if(s==="single"||s===!0){var c=n[l-1],v=Co(r,c);o.selectedMap=(i={},i[v]=!0,i),this._selectedDataIndicesMap=(a={},a[v]=r.getRawIndex(c),a)}}},t.prototype._initSelectedMapFromData=function(r){if(!this.option.selectedMap){var n=[];r.hasItemOption&&r.each(function(i){var a=r.getRawDataItem(i);a&&a.selected&&n.push(i)}),n.length>0&&this._innerSelect(r,n)}},t.registerClass=function(r){return pt.registerClass(r)},t.protoInitialize=(function(){var r=t.prototype;r.type="series.__base__",r.seriesIndex=0,r.ignoreStyleOnData=!1,r.hasSymbolVisual=!1,r.defaultSymbol="circle",r.visualStyleAccessPath="itemStyle",r.visualDrawType="fill"})(),t})(pt);ar(Vr,yC);ar(Vr,ov);bm(Vr,pt);function Vd(e){var t=e.name;bh(e)||(e.name=qC(e)||t)}function qC(e){var t=e.getRawData(),r=t.mapDimensionsAll("seriesName"),n=[];return D(r,function(i){var a=t.getDimensionInfo(i);a.displayName&&n.push(a.displayName)}),n.join(" ")}function KC(e){return e.model.getRawData().count()}function QC(e){var t=e.model;return t.setData(t.getRawData().cloneShallow()),JC}function JC(e,t){t.outputData&&e.end>t.outputData.count()&&t.model.getRawData().cloneShallow(t.outputData)}function Gd(e,t){D(b1(e.CHANGABLE_METHODS,e.DOWNSAMPLE_METHODS),function(r){e.wrapMethod(r,Et(jC,t))})}function jC(e,t){var r=Nf(e);return r&&r.setOutputEnd((t||this).count()),t}function Nf(e){var t=(e.ecModel||{}).scheduler,r=t&&t.getPipeline(e.uid);if(r){var n=r.currentTask;if(n){var i=n.agentStubMap;i&&(n=i.get(e.uid))}return n}}var ir=(function(){function e(){this.group=new Vt,this.uid=fl("viewComponent")}return e.prototype.init=function(t,r){},e.prototype.render=function(t,r,n,i){},e.prototype.dispose=function(t,r){},e.prototype.updateView=function(t,r,n,i){},e.prototype.updateLayout=function(t,r,n,i){},e.prototype.updateVisual=function(t,r,n,i){},e.prototype.toggleBlurSeries=function(t,r,n){},e.prototype.eachRendered=function(t){var r=this.group;r&&r.traverse(t)},e})();Ch(ir);js(ir);function Jy(){var e=bt();return function(t){var r=e(t),n=t.pipelineContext,i=!!r.large,a=!!r.progressiveRender,o=r.large=!!(n&&n.large),s=r.progressiveRender=!!(n&&n.progressiveRender);return(i!==o||a!==s)&&"reset"}}var jy=bt(),tD=Jy(),er=(function(){function e(){this.group=new Vt,this.uid=fl("viewChart"),this.renderTask=ha({plan:eD,reset:rD}),this.renderTask.context={view:this}}return e.prototype.init=function(t,r){},e.prototype.render=function(t,r,n,i){},e.prototype.highlight=function(t,r,n,i){var a=t.getData(i&&i.dataType);a&&Wd(a,i,"emphasis")},e.prototype.downplay=function(t,r,n,i){var a=t.getData(i&&i.dataType);a&&Wd(a,i,"normal")},e.prototype.remove=function(t,r){this.group.removeAll()},e.prototype.dispose=function(t,r){},e.prototype.updateView=function(t,r,n,i){this.render(t,r,n,i)},e.prototype.updateVisual=function(t,r,n,i){this.render(t,r,n,i)},e.prototype.eachRendered=function(t){Gh(this.group,t)},e.markUpdateMethod=function(t,r){jy(t).updateMethod=r},e.protoInitialize=(function(){var t=e.prototype;t.type="chart"})(),e})();function Ud(e,t,r){e&&Df(e)&&(t==="emphasis"?xs:Cs)(e,r)}function Wd(e,t,r){var n=An(e,t),i=t&&t.highlightKey!=null?WT(t.highlightKey):null;n!=null?D(Jt(n),function(a){Ud(e.getItemGraphicEl(a),r,i)}):e.eachItemGraphicEl(function(a){Ud(a,r,i)})}Ch(er);js(er);function eD(e){return tD(e.model)}function rD(e){var t=e.model,r=e.ecModel,n=e.api,i=e.payload,a=t.pipelineContext.progressiveRender,o=e.view,s=i&&jy(i).updateMethod,l=a?"incrementalPrepareRender":s&&o[s]?s:"render";return l!=="render"&&o[l](t,r,n,i),nD[l]}var nD={incrementalPrepareRender:{progress:function(e,t){t.view.incrementalRender(e,t.model,t.ecModel,t.api,t.payload)}},render:{forceFirstProgress:!0,progress:function(e,t){t.view.render(t.model,t.ecModel,t.api,t.payload)}}},Is="\0__throttleOriginMethod",Yd="\0__throttleRate",Xd="\0__throttleType";function t0(e,t,r){var n,i=0,a=0,o=null,s,l,u,f;t=t||0;function h(){a=new Date().getTime(),o=null,e.apply(l,u||[])}var v=function(){for(var c=[],d=0;d<arguments.length;d++)c[d]=arguments[d];n=new Date().getTime(),l=this,u=c;var p=f||t,m=f||r;f=null,s=n-(m?i:a)-p,clearTimeout(o),m?o=setTimeout(h,p):s>=0?h():o=setTimeout(h,-s),i=n};return v.clear=function(){o&&(clearTimeout(o),o=null)},v.debounceNextCall=function(c){f=c},v}function e0(e,t,r,n){var i=e[t];if(i){var a=i[Is]||i,o=i[Xd],s=i[Yd];if(s!==r||o!==n){if(r==null||!n)return e[t]=a;i=e[t]=t0(a,r,n==="debounce"),i[Is]=a,i[Xd]=n,i[Yd]=r}return i}}function Ff(e,t){var r=e[t];r&&r[Is]&&(r.clear&&r.clear(),e[t]=r[Is])}var $d=bt(),Zd={itemStyle:_a(vy,!0),lineStyle:_a(hy,!0)},iD={lineStyle:"stroke",itemStyle:"fill"};function r0(e,t){var r=e.visualStyleMapper||Zd[t];return r||(console.warn("Unknown style type '"+t+"'."),Zd.itemStyle)}function n0(e,t){var r=e.visualDrawType||iD[t];return r||(console.warn("Unknown style type '"+t+"'."),"fill")}var aD={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var r=e.getData(),n=e.visualStyleAccessPath||"itemStyle",i=e.getModel(n),a=r0(e,n),o=a(i),s=i.getShallow("decal");s&&(r.setVisual("decal",s),s.dirty=!0);var l=n0(e,n),u=o[l],f=ot(u)?u:null,h=o.fill==="auto"||o.stroke==="auto";if(!o[l]||f||h){var v=e.getColorFromPalette(e.name,null,t.getSeriesCount());o[l]||(o[l]=v,r.setVisual("colorFromPalette",!0)),o.fill=o.fill==="auto"||ot(o.fill)?v:o.fill,o.stroke=o.stroke==="auto"||ot(o.stroke)?v:o.stroke}if(r.setVisual("style",o),r.setVisual("drawType",l),!t.isSeriesFiltered(e)&&f)return r.setVisual("colorFromPalette",!1),{dataEach:function(c,d){var p=e.getDataParams(d),m=N({},o);m[l]=f(p),c.setItemVisual(d,"style",m)}}}},Ni=new Mt,oD={createOnAllSeries:!0,reset:function(e,t){if(!e.ignoreStyleOnData){var r=e.getData(),n=e.visualStyleAccessPath||"itemStyle",i=r0(e,n),a=r.getVisual("drawType");return{dataEach:r.hasItemOption?function(o,s){var l=o.getRawDataItem(s);if(l&&l[n]){Ni.option=l[n];var u=i(Ni),f=o.ensureUniqueItemVisual(s,"style");N(f,u),Ni.option.decal&&(o.setItemVisual(s,"decal",Ni.option.decal),Ni.option.decal.dirty=!0),a in u&&o.setItemVisual(s,"colorFromPalette",!1)}}:null}}}},sD={performRawSeries:!0,overallReset:function(e){var t=nt();e.eachSeries(function(r){if(!r.isColorBySeries()){var n=r.type+"-"+r.getColorBy();$d(r).scope=t.get(n)||t.set(n,{})}}),e.eachSeries(function(r){if(!r.isColorBySeries()){var n=r.getRawData(),i={},a=r.getData(),o=$d(r).scope,s=r.visualStyleAccessPath||"itemStyle",l=n0(r,s);a.each(function(u){var f=a.getRawIndex(u);i[f]=u}),n.each(function(u){var f=i[u],h=a.getItemVisual(f,"colorFromPalette");if(h){var v=a.ensureUniqueItemVisual(f,"style"),c=n.getName(u)||u+"",d=n.count();v[l]=r.getColorFromPalette(c,o,d)}})}})}},Do=Math.PI;function lD(e,t){t=t||{},yt(t,{text:"loading",textColor:J.color.primary,fontSize:12,fontWeight:"normal",fontStyle:"normal",fontFamily:"sans-serif",maskColor:"rgba(255,255,255,0.8)",showSpinner:!0,color:J.color.theme[0],spinnerRadius:10,lineWidth:5,zlevel:0});var r=new Vt,n=new Rt({style:{fill:t.maskColor},zlevel:t.zlevel,z:1e4});r.add(n);var i=new oe({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 Rt({style:{fill:"none"},textContent:i,textConfig:{position:"right",distance:10},zlevel:t.zlevel,z:10001});r.add(a);var o;return t.showSpinner&&(o=new sl({shape:{startAngle:-Do/2,endAngle:-Do/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:Do*3/2}).start("circularInOut"),o.animateShape(!0).when(1e3,{startAngle:Do*3/2}).delay(300).start("circularInOut"),r.add(o)),r.resize=function(){var s=i.getBoundingRect().width,l=t.showSpinner?t.spinnerRadius:0,u=(e.getWidth()-l*2-(t.showSpinner&&s?10:0)-s)/2-(t.showSpinner&&s?0:5+s/2)+(t.showSpinner?0:s/2)+(s?0:l),f=e.getHeight()/2;t.showSpinner&&o.setShape({cx:u,cy:f}),a.setShape({x:u-l,y:f-l,width:l*2,height:l*2}),n.setShape({x:0,y:0,width:e.getWidth(),height:e.getHeight()})},r.resize(),r}var i0=(function(){function e(t,r,n,i){this._stageTaskMap=nt(),this.ecInstance=t,this.api=r,n=this._dataProcessorHandlers=n.slice(),i=this._visualHandlers=i.slice(),this._allHandlers=n.concat(i)}return e.prototype.restoreData=function(t,r){t.restoreData(r),this._stageTaskMap.each(function(n){var i=n.overallTask;i&&i.dirty()})},e.prototype.getPerformArgs=function(t,r){if(t.__pipeline){var n=this._pipelineMap.get(t.__pipeline.id),i=n.context,a=!r&&n.progressiveEnabled&&(!i||i.progressiveRender)&&t.__idxInPipeline>n.blockIndex,o=a?n.step:null,s=i&&i.modDataCount,l=s!=null?Math.ceil(s/o):null;return{step:o,modBy:l,modDataCount:s}}},e.prototype.getPipeline=function(t){return this._pipelineMap.get(t)},e.prototype.updateStreamModes=function(t,r){var n=this._pipelineMap.get(t.uid),i=t.__preparePipelineContext?t.__preparePipelineContext(r,n):wb(t,r,n);t.pipelineContext=n.context=i},e.prototype.restorePipelines=function(t,r){var n=this,i=n._pipelineMap=nt();r.eachSeries(function(a){var o=t.painter.type==="canvas"&&a.getProgressive(),s=a.uid;i.set(s,{id:s,head:null,tail:null,threshold:a.getProgressiveThreshold(),progressiveEnabled:o&&!(a.preventIncremental&&a.preventIncremental()),blockIndex:-1,step:Math.round(o||700),count:0}),n._pipe(a,a.dataTask)})},e.prototype.prepareStageTasks=function(){var t=this._stageTaskMap,r=this.api.getModel(),n=this.api;D(this._allHandlers,function(i){var a=t.get(i.uid)||t.set(i.uid,{}),o="";pr(!(i.reset&&i.overallReset),o),i.reset&&this._createSeriesStageTask(i,a,r,n),i.overallReset&&this._createOverallStageTask(i,a,r,n)},this)},e.prototype.prepareView=function(t,r,n,i){var a=t.renderTask,o=a.context;o.model=r,o.ecModel=n,o.api=i,a.__block=!t.incrementalPrepareRender,this._pipe(r,a)},e.prototype.performDataProcessorTasks=function(t,r){this._performStageTasks(this._dataProcessorHandlers,t,r,{block:!0})},e.prototype.performVisualTasks=function(t,r,n){this._performStageTasks(this._visualHandlers,t,r,n)},e.prototype._performStageTasks=function(t,r,n,i){i=i||{};var a=!1,o=this;D(t,function(l,u){if(!(i.visualType&&i.visualType!==l.visualType)){var f=o._stageTaskMap.get(l.uid),h=f.seriesTaskMap,v=f.overallTask;if(v){var c,d=v.agentStubMap;d.each(function(m){s(i,m)&&(m.dirty(),c=!0)}),c&&v.dirty(),o.updatePayload(v,n);var p=o.getPerformArgs(v,i.block);d.each(function(m){m.perform(p)}),v.perform(p)&&(a=!0)}else h&&h.each(function(m,g){s(i,m)&&m.dirty();var y=o.getPerformArgs(m,i.block);y.skip=!l.performRawSeries&&r.isSeriesFiltered(m.context.model),o.updatePayload(m,n),m.perform(y)&&(a=!0)})}});function s(l,u){return l.setDirty&&(!l.dirtyMap||l.dirtyMap.get(u.__pipeline.id))}this.unfinished=a||this.unfinished},e.prototype.performSeriesTasks=function(t){var r;t.eachSeries(function(n){r=n.dataTask.perform()||r}),this.unfinished=r||this.unfinished},e.prototype.plan=function(){this._pipelineMap.each(function(t){var r=t.tail;do{if(r.__block){t.blockIndex=r.__idxInPipeline;break}r=r.getUpstream()}while(r)})},e.prototype.updatePayload=function(t,r){r!=="remain"&&(t.context.payload=r)},e.prototype._createSeriesStageTask=function(t,r,n,i){var a=this,o=r.seriesTaskMap,s=r.seriesTaskMap=nt(),l=t.seriesType,u=t.getTargetSeries;t.createOnAllSeries?n.eachRawSeries(f):l?n.eachRawSeriesByType(l,f):u&&u(n,i).each(f);function f(h){var v=h.uid,c=s.set(v,o&&o.get(v)||ha({plan:cD,reset:dD,count:gD}));c.context={model:h,ecModel:n,api:i,useClearVisual:t.isVisual&&!t.isLayout,plan:t.plan,reset:t.reset,scheduler:a},a._pipe(h,c)}},e.prototype._createOverallStageTask=function(t,r,n,i){var a=this,o=r.overallTask=r.overallTask||ha({reset:uD});o.context={ecModel:n,api:i,overallReset:t.overallReset,scheduler:a};var s=o.agentStubMap,l=o.agentStubMap=nt(),u=t.seriesType,f=t.getTargetSeries,h=t.dirtyOnOverallProgress,v=!1,c="";pr(!t.createOnAllSeries,c),u?n.eachRawSeriesByType(u,d):f?f(n,i).each(d):D(n.getSeries(),d);function d(p){var m=p.uid,g=l.set(m,s&&s.get(m)||(v=!0,ha({reset:fD,onDirty:vD})));g.context={model:p,dirtyOnOverallProgress:h},g.agent=o,g.__block=h,a._pipe(p,g)}v&&o.dirty()},e.prototype._pipe=function(t,r){var n=t.uid,i=this._pipelineMap.get(n);!i.head&&(i.head=r),i.tail&&i.tail.pipe(r),i.tail=r,r.__idxInPipeline=i.count++,r.__pipeline=i},e.wrapStageHandler=function(t,r){return ot(t)&&(t={overallReset:t,seriesType:mD(t)}),t.uid=fl("stageHandler"),r&&(t.visualType=r),t},e})();function uD(e){e.overallReset(e.ecModel,e.api,e.payload)}function fD(e){return e.dirtyOnOverallProgress&&hD}function hD(){this.agent.dirty(),this.getDownstream().dirty()}function vD(){this.agent&&this.agent.dirty()}function cD(e){return e.plan?e.plan(e.model,e.ecModel,e.api,e.payload):null}function dD(e){e.useClearVisual&&e.data.clearAllVisual();var t=e.resetDefines=Jt(e.reset(e.model,e.ecModel,e.api,e.payload));return t.length>1?rt(t,function(r,n){return a0(n)}):pD}var pD=a0(0);function a0(e){return function(t,r){var n=r.data,i=r.resetDefines[e];if(i&&i.dataEach)for(var a=t.start;a<t.end;a++)i.dataEach(n,a);else i&&i.progress&&i.progress(t,n)}}function gD(e){return e.data.count()}function mD(e){Ps=null;try{e(Ma,o0)}catch{}return Ps}var Ma={},o0={},Ps;s0(Ma,sv);s0(o0,km);Ma.eachSeriesByType=Ma.eachRawSeriesByType=function(e){Ps=e};Ma.eachComponent=function(e){e.mainType==="series"&&e.subType&&(Ps=e.subType)};function s0(e,t){for(var r in t.prototype)e[r]=$t}var O=J.darkColor,qd=O.background,Fi=function(){return{axisLine:{lineStyle:{color:O.axisLine}},splitLine:{lineStyle:{color:O.axisSplitLine}},splitArea:{areaStyle:{color:[O.backgroundTint,O.backgroundTransparent]}},minorSplitLine:{lineStyle:{color:O.axisMinorSplitLine}},axisLabel:{color:O.axisLabel},axisName:{}}},Kd={label:{color:O.secondary},itemStyle:{borderColor:O.borderTint},dividerLineStyle:{color:O.border}},l0={darkMode:!0,color:O.theme,backgroundColor:qd,axisPointer:{lineStyle:{color:O.border},crossStyle:{color:O.borderShade},label:{color:O.tertiary}},legend:{textStyle:{color:O.secondary},pageTextStyle:{color:O.tertiary}},textStyle:{color:O.secondary},title:{textStyle:{color:O.primary},subtextStyle:{color:O.quaternary}},toolbox:{iconStyle:{borderColor:O.accent50},feature:{dataView:{backgroundColor:qd,textColor:O.primary,textareaColor:O.background,textareaBorderColor:O.border,buttonColor:O.accent50,buttonTextColor:O.neutral00}}},tooltip:{backgroundColor:O.neutral20,defaultBorderColor:O.border,textStyle:{color:O.tertiary}},dataZoom:{borderColor:O.accent10,textStyle:{color:O.tertiary},brushStyle:{color:O.backgroundTint},handleStyle:{color:O.neutral00,borderColor:O.accent20},moveHandleStyle:{color:O.accent40},emphasis:{handleStyle:{borderColor:O.accent50}},dataBackground:{lineStyle:{color:O.accent30},areaStyle:{color:O.accent20}},selectedDataBackground:{lineStyle:{color:O.accent50},areaStyle:{color:O.accent30}}},visualMap:{textStyle:{color:O.secondary},handleStyle:{borderColor:O.neutral30}},timeline:{lineStyle:{color:O.accent10},label:{color:O.tertiary},controlStyle:{color:O.accent30,borderColor:O.accent30}},calendar:{itemStyle:{color:O.neutral00,borderColor:O.neutral20},dayLabel:{color:O.tertiary},monthLabel:{color:O.secondary},yearLabel:{color:O.secondary}},matrix:{x:Kd,y:Kd,backgroundColor:{borderColor:O.axisLine},body:{itemStyle:{borderColor:O.borderTint}}},timeAxis:Fi(),logAxis:Fi(),valueAxis:Fi(),categoryAxis:Fi(),line:{symbol:"circle"},graph:{color:O.theme},gauge:{title:{color:O.secondary},axisLine:{lineStyle:{color:[[1,O.neutral05]]}},axisLabel:{color:O.axisLabel},detail:{color:O.primary}},candlestick:{itemStyle:{color:"#f64e56",color0:"#54ea92",borderColor:"#f64e56",borderColor0:"#54ea92"}},funnel:{itemStyle:{borderColor:O.background}},radar:(function(){var e=Fi();return e.axisName={color:O.axisLabel},e.axisLine.lineStyle.color=O.neutral20,e})(),treemap:{breadcrumb:{itemStyle:{color:O.neutral20,textStyle:{color:O.secondary}},emphasis:{itemStyle:{color:O.neutral30}}}},sunburst:{itemStyle:{borderColor:O.background}},map:{itemStyle:{borderColor:O.border,areaColor:O.neutral10},label:{color:O.tertiary},emphasis:{label:{color:O.primary},itemStyle:{areaColor:O.highlight}},select:{label:{color:O.primary},itemStyle:{areaColor:O.highlight}}},geo:{itemStyle:{borderColor:O.border,areaColor:O.neutral10},emphasis:{label:{color:O.primary},itemStyle:{areaColor:O.highlight}},select:{label:{color:O.primary},itemStyle:{color:O.highlight}}}};l0.categoryAxis.splitLine.show=!1;var yD=(function(){function e(){}return e.prototype.normalizeQuery=function(t){var r={},n={},i={};if(W(t)){var a=Ze(t);r.mainType=a.main||null,r.subType=a.sub||null}else{var o=["Index","Name","Id"],s={name:1,dataIndex:1,dataType:1};D(t,function(l,u){for(var f=!1,h=0;h<o.length;h++){var v=o[h],c=u.lastIndexOf(v);if(c>0&&c===u.length-v.length){var d=u.slice(0,c);d!=="data"&&(r.mainType=d,r[v.toLowerCase()]=l,f=!0)}}s.hasOwnProperty(u)&&(n[u]=l,f=!0),f||(i[u]=l)})}return{cptQuery:r,dataQuery:n,otherQuery:i}},e.prototype.filter=function(t,r){var n=this.eventInfo;if(!n)return!0;var i=n.targetEl,a=n.packedEvent,o=n.model,s=n.view;if(!o||!s)return!0;var l=r.cptQuery,u=r.dataQuery;return f(l,o,"mainType")&&f(l,o,"subType")&&f(l,o,"index","componentIndex")&&f(l,o,"name")&&f(l,o,"id")&&f(u,a,"name")&&f(u,a,"dataIndex")&&f(u,a,"dataType")&&(!s.filterForExposedEvent||s.filterForExposedEvent(t,r.otherQuery,i,a));function f(h,v,c,d){return h[c]==null||v[d||c]===h[c]}},e.prototype.afterTrigger=function(){this.eventInfo=null},e})(),zf=["symbol","symbolSize","symbolRotate","symbolOffset"],Qd=zf.concat(["symbolKeepAspect"]),_D={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){var r=e.getData();if(e.legendIcon&&r.setVisual("legendIcon",e.legendIcon),!e.hasSymbolVisual)return;for(var n={},i={},a=!1,o=0;o<zf.length;o++){var s=zf[o],l=e.get(s);ot(l)?(a=!0,i[s]=l):n[s]=l}if(n.symbol=n.symbol||e.defaultSymbol,r.setVisual(N({legendIcon:e.legendIcon||n.symbol,symbolKeepAspect:e.get("symbolKeepAspect")},n)),t.isSeriesFiltered(e))return;var u=xt(i);function f(h,v){for(var c=e.getRawValue(v),d=e.getDataParams(v),p=0;p<u.length;p++){var m=u[p];h.setItemVisual(v,m,i[m](c,d))}}return{dataEach:a?f:null}}},SD={createOnAllSeries:!0,performRawSeries:!0,reset:function(e,t){if(!e.hasSymbolVisual||t.isSeriesFiltered(e))return;var r=e.getData();function n(i,a){for(var o=i.getItemModel(a),s=0;s<Qd.length;s++){var l=Qd[s],u=o.getShallow(l,!0);u!=null&&i.setItemVisual(a,l,u)}}return{dataEach:r.hasItemOption?n:null}}};function bD(e,t,r){switch(r){case"color":var n=e.getItemVisual(t,"style");return n[e.getVisual("drawType")];case"opacity":return e.getItemVisual(t,"style").opacity;case"symbol":case"symbolSize":case"liftZ":return e.getItemVisual(t,r)}}function TD(e,t){switch(t){case"color":var r=e.getVisual("style");return r[e.getVisual("drawType")];case"opacity":return e.getVisual("style").opacity;case"symbol":case"symbolSize":case"liftZ":return e.getVisual(t)}}function Wn(e,t,r,n,i){var a=e+t;r.isSilent(a)||n.eachComponent({mainType:"series",subType:"pie"},function(o){for(var s=o.seriesIndex,l=o.option.selectedMap,u=i.selected,f=0;f<u.length;f++)if(u[f].seriesIndex===s){var h=o.getData(),v=An(h,i.fromActionPayload);r.trigger(a,{type:a,seriesId:o.id,name:H(v)?h.getName(v[0]):h.getName(v),selected:W(l)?l:N({},l)})}})}function wD(e,t,r){e.on("selectchanged",function(n){var i=r.getModel();n.isFromClick?(Wn("map","selectchanged",t,i,n),Wn("pie","selectchanged",t,i,n)):n.fromAction==="select"?(Wn("map","selected",t,i,n),Wn("pie","selected",t,i,n)):n.fromAction==="unselect"&&(Wn("map","unselected",t,i,n),Wn("pie","unselected",t,i,n))})}function ta(e,t,r){for(var n;e&&!(t(e)&&(n=e,r));)e=e.__hostTarget||e.parent;return n}var me=new or,u0={};function xD(e,t){u0[e]=t}function CD(e){return u0[e]}var hv=bt();function DD(e){hv(e).prepare={}}function MD(e){hv(e).fullUpdate={}}function Ya(e){return hv(e).fullUpdate}var AD=Math.round(Math.random()*9),LD=typeof Object.defineProperty=="function",ID=(function(){function e(){this._id="__ec_inner_"+AD++}return e.prototype.get=function(t){return this._guard(t)[this._id]},e.prototype.set=function(t,r){var n=this._guard(t);return LD?Object.defineProperty(n,this._id,{value:r,enumerable:!1,configurable:!0}):n[this._id]=r,this},e.prototype.delete=function(t){return this.has(t)?(delete this._guard(t)[this._id],!0):!1},e.prototype.has=function(t){return!!this._guard(t)[this._id]},e.prototype._guard=function(t){if(t!==Object(t))throw TypeError("Value of WeakMap is not a non-null object.");return t},e})(),PD=St.extend({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(e,t){var r=t.cx,n=t.cy,i=t.width/2,a=t.height/2;e.moveTo(r,n-a),e.lineTo(r+i,n+a),e.lineTo(r-i,n+a),e.closePath()}}),ED=St.extend({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(e,t){var r=t.cx,n=t.cy,i=t.width/2,a=t.height/2;e.moveTo(r,n-a),e.lineTo(r+i,n),e.lineTo(r,n+a),e.lineTo(r-i,n),e.closePath()}}),RD=St.extend({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(e,t){var r=t.x,n=t.y,i=t.width/5*3,a=Math.max(i,t.height),o=i/2,s=o*o/(a-o),l=n-a+o+s,u=Math.asin(s/o),f=Math.cos(u)*o,h=Math.sin(u),v=Math.cos(u),c=o*.6,d=o*.7;e.moveTo(r-f,l+s),e.arc(r,l,o,Math.PI-u,Math.PI*2+u),e.bezierCurveTo(r+f-h*c,l+s+v*c,r,n-d,r,n),e.bezierCurveTo(r,n-d,r-f+h*c,l+s+v*c,r-f,l+s),e.closePath()}}),kD=St.extend({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(e,t){var r=t.height,n=t.width,i=t.x,a=t.y,o=n/3*2;e.moveTo(i,a),e.lineTo(i+o,a+r),e.lineTo(i,a+r/4*3),e.lineTo(i-o,a+r),e.lineTo(i,a),e.closePath()}}),OD={line:Fr,rect:Rt,roundRect:Rt,square:Rt,circle:al,diamond:ED,pin:RD,arrow:kD,triangle:PD},BD={line:function(e,t,r,n,i){i.x1=e,i.y1=t+n/2,i.x2=e+r,i.y2=t+n/2},rect:function(e,t,r,n,i){i.x=e,i.y=t,i.width=r,i.height=n},roundRect:function(e,t,r,n,i){i.x=e,i.y=t,i.width=r,i.height=n,i.r=Math.min(r,n)/4},square:function(e,t,r,n,i){var a=Math.min(r,n);i.x=e,i.y=t,i.width=a,i.height=a},circle:function(e,t,r,n,i){i.cx=e+r/2,i.cy=t+n/2,i.r=Math.min(r,n)/2},diamond:function(e,t,r,n,i){i.cx=e+r/2,i.cy=t+n/2,i.width=r,i.height=n},pin:function(e,t,r,n,i){i.x=e+r/2,i.y=t+n/2,i.width=r,i.height=n},arrow:function(e,t,r,n,i){i.x=e+r/2,i.y=t+n/2,i.width=r,i.height=n},triangle:function(e,t,r,n,i){i.cx=e+r/2,i.cy=t+n/2,i.width=r,i.height=n}},Hf={};D(OD,function(e,t){Hf[t]=new e});var ND=St.extend({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},calculateTextPosition:function(e,t,r){var n=im(e,t,r),i=this.shape;return i&&i.symbolType==="pin"&&t.position==="inside"&&(n.y=r.y+r.height*.4),n},buildPath:function(e,t,r){var n=t.symbolType;if(n!=="none"){var i=Hf[n];i||(n="rect",i=Hf[n]),BD[n](t.x,t.y,t.width,t.height,i.shape),i.buildPath(e,i.shape,r)}}});function FD(e,t){if(this.type!=="image"){var r=this.style;this.__isEmptyBrush?(r.stroke=e,r.fill=t||J.color.neutral00,r.lineWidth=2):this.shape.symbolType==="line"?r.stroke=e:r.fill=e,this.markRedraw()}}function _i(e,t,r,n,i,a,o){var s=e.indexOf("empty")===0;s&&(e=e.substr(5,1).toLowerCase()+e.substr(6));var l;return e.indexOf("image://")===0?l=ry(e.slice(8),new it(t,r,n,i),o?"center":"cover"):e.indexOf("path://")===0?l=zh(e.slice(7),{},new it(t,r,n,i),o?"center":"cover"):l=new ND({shape:{symbolType:e,x:t,y:r,width:n,height:i}}),l.__isEmptyBrush=s,l.setColor=FD,a&&l.setColor(a),l}function zD(e){return H(e)||(e=[+e,+e]),[e[0]||0,e[1]||0]}function f0(e,t){if(e!=null)return H(e)||(e=[e,e]),[Ye(e[0],t[0])||0,Ye(j(e[1],e[0]),t[1])||0]}function bn(e){return isFinite(e)}function HD(e,t,r){var n=t.x==null?0:t.x,i=t.x2==null?1:t.x2,a=t.y==null?0:t.y,o=t.y2==null?0:t.y2;t.global||(n=n*r.width+r.x,i=i*r.width+r.x,a=a*r.height+r.y,o=o*r.height+r.y),n=bn(n)?n:0,i=bn(i)?i:1,a=bn(a)?a:0,o=bn(o)?o:0;var s=e.createLinearGradient(n,a,i,o);return s}function VD(e,t,r){var n=r.width,i=r.height,a=Math.min(n,i),o=t.x==null?.5:t.x,s=t.y==null?.5:t.y,l=t.r==null?.5:t.r;t.global||(o=o*n+r.x,s=s*i+r.y,l=l*a),o=bn(o)?o:.5,s=bn(s)?s:.5,l=l>=0&&bn(l)?l:.5;var u=e.createRadialGradient(o,s,0,o,s,l);return u}function Vf(e,t,r){for(var n=t.type==="radial"?VD(e,t,r):HD(e,t,r),i=t.colorStops,a=0;a<i.length;a++)n.addColorStop(i[a].offset,i[a].color);return n}function GD(e,t){if(e===t||!e&&!t)return!1;if(!e||!t||e.length!==t.length)return!0;for(var r=0;r<e.length;r++)if(e[r]!==t[r])return!0;return!1}function Mo(e){return parseInt(e,10)}function Ao(e,t,r){var n=["width","height"][t],i=["clientWidth","clientHeight"][t],a=["paddingLeft","paddingTop"][t],o=["paddingRight","paddingBottom"][t];if(r[n]!=null&&r[n]!=="auto")return parseFloat(r[n]);var s=document.defaultView.getComputedStyle(e);return(e[i]||Mo(s[n])||Mo(e.style[n]))-(Mo(s[a])||0)-(Mo(s[o])||0)||0}function UD(e,t){return!e||e==="solid"||!(t>0)?null:e==="dashed"?[4*t,2*t]:e==="dotted"?[t]:Ct(e)?[e]:H(e)?e:null}function h0(e){var t=e.style,r=t.lineDash&&t.lineWidth>0&&UD(t.lineDash,t.lineWidth),n=t.lineDashOffset;if(r){var i=t.strokeNoScale&&e.getLineScale?e.getLineScale():1;i&&i!==1&&(r=rt(r,function(a){return a/i}),n/=i)}return[r,n]}var WD=new Ln(!0);function Es(e){var t=e.stroke;return!(t==null||t==="none"||!(e.lineWidth>0))}function Jd(e){return typeof e=="string"&&e!=="none"}function Rs(e){var t=e.fill;return t!=null&&t!=="none"}function jd(e,t){if(t.fillOpacity!=null&&t.fillOpacity!==1){var r=e.globalAlpha;e.globalAlpha=t.fillOpacity*t.opacity,e.fill(),e.globalAlpha=r}else e.fill()}function tp(e,t){if(t.strokeOpacity!=null&&t.strokeOpacity!==1){var r=e.globalAlpha;e.globalAlpha=t.strokeOpacity*t.opacity,e.stroke(),e.globalAlpha=r}else e.stroke()}function Gf(e,t,r){var n=Tm(t.image,t.__image,r);if(tl(n)){var i=e.createPattern(n,t.repeat||"repeat");if(typeof DOMMatrix=="function"&&i&&i.setTransform){var a=new DOMMatrix;a.translateSelf(t.x||0,t.y||0),a.rotateSelf(0,0,(t.rotation||0)*T1),a.scaleSelf(t.scaleX||1,t.scaleY||1),i.setTransform(a)}return i}}function YD(e,t,r,n,i){var a,o=Es(r),s=Rs(r),l=r.strokePercent,u=l<1,f=!t.path;(!t.silent||u)&&f&&t.createPathProxy();var h=t.path||WD,v=t.__dirty;if(!n){var c=r.fill,d=r.stroke,p=s&&!!c.colorStops,m=o&&!!d.colorStops,g=s&&!!c.image,y=o&&!!d.image,_=void 0,S=void 0,b=void 0,T=void 0,w=void 0;(p||m)&&(w=t.getBoundingRect()),p&&(_=v?Vf(e,c,w):t.__canvasFillGradient,t.__canvasFillGradient=_),m&&(S=v?Vf(e,d,w):t.__canvasStrokeGradient,t.__canvasStrokeGradient=S),g&&(b=v||!t.__canvasFillPattern?Gf(e,c,t):t.__canvasFillPattern,t.__canvasFillPattern=b),y&&(T=v||!t.__canvasStrokePattern?Gf(e,d,t):t.__canvasStrokePattern,t.__canvasStrokePattern=T),p?e.fillStyle=_:g&&(b?e.fillStyle=b:s=!1),m?e.strokeStyle=S:y&&(T?e.strokeStyle=T:o=!1)}var M=t.getGlobalScale();h.setScale(M[0],M[1],t.segmentIgnoreThreshold);var C,x;e.setLineDash&&r.lineDash&&(a=h0(t),C=a[0],x=a[1]);var A=!0;(f||v&Kn)&&(h.setDPR(e.dpr),u?h.setContext(null):(h.setContext(e),A=!1),h.reset(),t.buildPath(h,t.shape,n),h.toStatic(),t.pathUpdated()),A&&h.rebuildPath(e,u?l:1),C&&(e.setLineDash(C),e.lineDashOffset=x),n?(i.batchFill=s,i.batchStroke=o):r.strokeFirst?(o&&tp(e,r),s&&jd(e,r)):(s&&jd(e,r),o&&tp(e,r)),C&&e.setLineDash([])}function XD(e,t,r){var n=t.__image=Tm(r.image,t.__image,t,t.onload);if(!(!n||!tl(n))){var i=r.x||0,a=r.y||0,o=t.getWidth(),s=t.getHeight(),l=n.width/n.height;if(o==null&&s!=null?o=s*l:s==null&&o!=null?s=o/l:o==null&&s==null&&(o=n.width,s=n.height),r.sWidth&&r.sHeight){var u=r.sx||0,f=r.sy||0;e.drawImage(n,u,f,r.sWidth,r.sHeight,i,a,o,s)}else if(r.sx&&r.sy){var u=r.sx,f=r.sy,h=o-u,v=s-f;e.drawImage(n,u,f,h,v,i,a,o,s)}else e.drawImage(n,i,a,o,s)}}function $D(e,t,r){var n,i=r.text;if(i!=null&&(i+=""),i){e.font=r.font||Nr,e.textAlign=r.textAlign,e.textBaseline=r.textBaseline;var a=void 0,o=void 0;e.setLineDash&&r.lineDash&&(n=h0(t),a=n[0],o=n[1]),a&&(e.setLineDash(a),e.lineDashOffset=o),r.strokeFirst?(Es(r)&&e.strokeText(i,r.x,r.y),Rs(r)&&e.fillText(i,r.x,r.y)):(Rs(r)&&e.fillText(i,r.x,r.y),Es(r)&&e.strokeText(i,r.x,r.y)),a&&e.setLineDash([])}}var ep=["shadowBlur","shadowOffsetX","shadowOffsetY"],rp=[["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]];function v0(e,t,r,n,i){var a=!1;if(!n&&(r=r||{},t===r))return!1;if(n||t.opacity!==r.opacity){Qt(e,i),a=!0;var o=Math.max(Math.min(t.opacity,1),0);e.globalAlpha=isNaN(o)?Cn.opacity:o}(n||t.blend!==r.blend)&&(a||(Qt(e,i),a=!0),e.globalCompositeOperation=t.blend||Cn.blend);for(var s=0;s<ep.length;s++){var l=ep[s];(n||t[l]!==r[l])&&(a||(Qt(e,i),a=!0),e[l]=e.dpr*(t[l]||0))}return(n||t.shadowColor!==r.shadowColor)&&(a||(Qt(e,i),a=!0),e.shadowColor=t.shadowColor||Cn.shadowColor),a}function np(e,t,r,n,i){var a=t.style,o=n?null:r&&r.style||{};if(a===o)return!1;var s=v0(e,a,o,n,i);if((n||a.fill!==o.fill)&&(s||(Qt(e,i),s=!0),Jd(a.fill)&&(e.fillStyle=a.fill)),(n||a.stroke!==o.stroke)&&(s||(Qt(e,i),s=!0),Jd(a.stroke)&&(e.strokeStyle=a.stroke)),(n||a.opacity!==o.opacity)&&(s||(Qt(e,i),s=!0),e.globalAlpha=a.opacity==null?1:a.opacity),t.hasStroke()){var l=a.lineWidth,u=l/(a.strokeNoScale&&t.getLineScale?t.getLineScale():1);e.lineWidth!==u&&(s||(Qt(e,i),s=!0),e.lineWidth=u)}for(var f=0;f<rp.length;f++){var h=rp[f],v=h[0];(n||a[v]!==o[v])&&(s||(Qt(e,i),s=!0),e[v]=a[v]||h[1])}return s}function ZD(e,t,r,n,i){return v0(e,t.style,r&&r.style,n,i)}function c0(e,t){var r=t.transform,n=e.dpr||1;r?e.setTransform(n*r[0],n*r[1],n*r[2],n*r[3],n*r[4],n*r[5]):e.setTransform(n,0,0,n,0,0)}function qD(e,t,r){for(var n=!1,i=0;i<e.length;i++){var a=e[i];n=n||a.isZeroArea(),c0(t,a),t.beginPath(),a.buildPath(t,a.shape),t.clip()}r.allClipped=n}function KD(e,t){return e&&t?e[0]!==t[0]||e[1]!==t[1]||e[2]!==t[2]||e[3]!==t[3]||e[4]!==t[4]||e[5]!==t[5]:!(!e&&!t)}var ip=1,ap=2,op=3,sp=4;function QD(e){var t=Rs(e),r=Es(e);return!(e.lineDash||!(+t^+r)||t&&typeof e.fill!="string"||r&&typeof e.stroke!="string"||e.strokePercent<1||e.strokeOpacity<1||e.fillOpacity<1)}function Qt(e,t){t.batchFill&&(t.batchFill=!1,e.fill()),t.batchStroke&&(t.batchStroke=!1,e.stroke())}function d0(e,t){var r={inHover:!1,viewWidth:0,viewHeight:0,beforeBrushParam:{}};Tn(e,t,r),fi(e,r)}function Tn(e,t,r){var n=t.transform;if(!t.shouldBePainted(r.viewWidth,r.viewHeight,!1,!1)){t.__dirty&=~ne,t.__isRendered=!1;return}var i=t.__clipPaths,a=r.prevElClipPaths,o=t.style,s=!1,l=!1;if((!a||GD(i,a))&&(a&&(Qt(e,r),e.restore(),l=s=!0,r.prevElClipPaths=null,r.allClipped=!1,r.prevEl=null),i&&i.length&&(Qt(e,r),e.save(),qD(i,e,r),s=!0,r.prevElClipPaths=i)),r.allClipped){t.__dirty&=~ne,t.__isRendered=!1;return}t.beforeBrush&&t.beforeBrush(r.beforeBrushParam),t.innerBeforeBrush();var u=r.prevEl;u||(l=s=!0);var f=t instanceof St&&t.autoBatch&&QD(o);s||KD(n,u.transform)?(Qt(e,r),c0(e,t)):f||Qt(e,r),t instanceof St?(r.lastDrawType!==ip&&(l=!0,r.lastDrawType=ip),np(e,t,u,l,r),(!f||!r.batchFill&&!r.batchStroke)&&e.beginPath(),YD(e,t,o,f,r)):t instanceof bs?(r.lastDrawType!==op&&(l=!0,r.lastDrawType=op),np(e,t,u,l,r),$D(e,t,o)):t instanceof Wr?(r.lastDrawType!==ap&&(l=!0,r.lastDrawType=ap),ZD(e,t,u,l,r),XD(e,t,o)):t.getTemporalDisplayables&&(r.lastDrawType!==sp&&(l=!0,r.lastDrawType=sp),JD(e,t,r)),t.innerAfterBrush(),t.afterBrush&&(f&&Qt(e,r),t.afterBrush()),r.prevEl=t,t.__dirty=0,t.__isRendered=!0}function fi(e,t){Qt(e,t),t.prevElClipPaths&&e.restore()}function JD(e,t,r){var n=t.getDisplayables(),i=t.getTemporalDisplayables();e.save();var a={prevElClipPaths:null,prevEl:null,allClipped:!1,viewWidth:r.viewWidth,viewHeight:r.viewHeight,inHover:r.inHover,beforeBrushParam:{}},o,s;for(o=t.getCursor(),s=n.length;o<s;o++){var l=n[o];l.beforeBrush&&l.beforeBrush(r.beforeBrushParam),l.innerBeforeBrush(),Tn(e,l,a),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),a.prevEl=l}fi(e,a);for(var u=0,f=i.length;u<f;u++){var l=i[u];l.beforeBrush&&l.beforeBrush(r.beforeBrushParam),l.innerBeforeBrush(),Tn(e,l,a),l.innerAfterBrush(),l.afterBrush&&l.afterBrush(),a.prevEl=l}fi(e,a),t.clearTemporalDisplayables(),t.notClear=!0,e.restore()}var Tu=new ID,lp=new vi(100),up=["symbol","symbolSize","symbolKeepAspect","color","backgroundColor","dashArrayX","dashArrayY","maxTileWidth","maxTileHeight"];function Uf(e,t){if(e==="none")return null;var r=t.getDevicePixelRatio(),n=t.getZr(),i=n.painter.type==="svg";e.dirty&&Tu.delete(e);var a=Tu.get(e);if(a)return a;var o=yt(e,{symbol:"rect",symbolSize:1,symbolKeepAspect:!0,color:"rgba(0, 0, 0, 0.2)",backgroundColor:null,dashArrayX:5,dashArrayY:5,rotation:0,maxTileWidth:512,maxTileHeight:512});o.backgroundColor==="none"&&(o.backgroundColor=null);var s={repeat:"repeat"};return l(s),s.rotation=o.rotation,s.scaleX=s.scaleY=i?1:1/r,Tu.set(e,s),e.dirty=!1,s;function l(u){for(var f=[r],h=!0,v=0;v<up.length;++v){var c=o[up[v]];if(c!=null&&!H(c)&&!W(c)&&!Ct(c)&&typeof c!="boolean"){h=!1;break}f.push(c)}var d;if(h){d=f.join(",")+(i?"-svg":"");var p=lp.get(d);p&&(i?u.svgElement=p:u.image=p)}var m=g0(o.dashArrayX),g=jD(o.dashArrayY),y=p0(o.symbol),_=tM(m),S=m0(g),b=!i&&ue.createCanvas(),T=i&&{tag:"g",attrs:{},key:"dcl",children:[]},w=C(),M;b&&(b.width=w.width*r,b.height=w.height*r,M=b.getContext("2d")),x(),h&&lp.put(d,b||T),u.image=b,u.svgElement=T,u.svgWidth=w.width,u.svgHeight=w.height;function C(){for(var A=1,I=0,L=_.length;I<L;++I)A=_c(A,_[I]);for(var P=1,I=0,L=y.length;I<L;++I)P=_c(P,y[I].length);A*=P;var R=S*_.length*y.length;return{width:Math.max(1,Math.min(A,o.maxTileWidth)),height:Math.max(1,Math.min(R,o.maxTileHeight))}}function x(){M&&(M.clearRect(0,0,b.width,b.height),o.backgroundColor&&(M.fillStyle=o.backgroundColor,M.fillRect(0,0,b.width,b.height)));for(var A=0,I=0;I<g.length;++I)A+=g[I];if(A<=0)return;for(var L=-S,P=0,R=0,E=0;L<w.height;){if(P%2===0){for(var F=R/2%y.length,G=0,U=0,tt=0;G<w.width*2;){for(var Z=0,I=0;I<m[E].length;++I)Z+=m[E][I];if(Z<=0)break;if(U%2===0){var at=(1-o.symbolSize)*.5,q=G+m[E][U]*at,z=L+g[P]*at,lt=m[E][U]*o.symbolSize,k=g[P]*o.symbolSize,B=tt/2%y[F].length;Q(q,z,lt,k,y[F][B])}G+=m[E][U],++tt,++U,U===m[E].length&&(U=0)}++E,E===m.length&&(E=0)}L+=g[P],++R,++P,P===g.length&&(P=0)}function Q($,et,X,Y,Ft){var Dt=i?1:r,Ie=_i(Ft,$*Dt,et*Dt,X*Dt,Y*Dt,o.color,o.symbolKeepAspect);if(i){var kt=n.painter.renderOneToVNode(Ie);kt&&T.children.push(kt)}else d0(M,Ie)}}}}function p0(e){if(!e||e.length===0)return[["rect"]];if(W(e))return[[e]];for(var t=!0,r=0;r<e.length;++r)if(!W(e[r])){t=!1;break}if(t)return p0([e]);for(var n=[],r=0;r<e.length;++r)W(e[r])?n.push([e[r]]):n.push(e[r]);return n}function g0(e){if(!e||e.length===0)return[[0,0]];if(Ct(e)){var t=Math.ceil(e);return[[t,t]]}for(var r=!0,n=0;n<e.length;++n)if(!Ct(e[n])){r=!1;break}if(r)return g0([e]);for(var i=[],n=0;n<e.length;++n)if(Ct(e[n])){var t=Math.ceil(e[n]);i.push([t,t])}else{var t=rt(e[n],function(s){return Math.ceil(s)});t.length%2===1?i.push(t.concat(t)):i.push(t)}return i}function jD(e){if(!e||typeof e=="object"&&e.length===0)return[0,0];if(Ct(e)){var t=Math.ceil(e);return[t,t]}var r=rt(e,function(n){return Math.ceil(n)});return e.length%2?r.concat(r):r}function tM(e){return rt(e,function(t){return m0(t)})}function m0(e){for(var t=0,r=0;r<e.length;++r)t+=e[r];return e.length%2===1?t*2:t}var eM=xh(rM);function rM(e,t){e.eachRawSeries(function(r){if(!e.isSeriesFiltered(r)){var n=r.getData();n.hasItemVisual()&&n.each(function(o){var s=n.getItemVisual(o,"decal");if(s){var l=n.ensureUniqueItemVisual(o,"style");l.decal=Uf(s,t)}});var i=n.getVisual("decal");if(i){var a=n.getVisual("style");a.decal=Uf(i,t)}}})}var nM=1,iM=800,aM=900,oM=920,sM=1e3,lM=2e3,fp=5e3,y0=1e3,uM=1100,vv=2e3,_0=3e3,fM=4e3,pl=4500,hM=4600,vM=5e3,cM=6e3,S0=7e3,dM={PROCESSOR:{SERIES_FILTER:iM,AXIS_STATISTICS:oM,FILTER:sM,STATISTIC:fp,STATISTICS:fp},VISUAL:{LAYOUT:y0,PROGRESSIVE_LAYOUT:uM,GLOBAL:vv,CHART:_0,POST_CHART_LAYOUT:hM,COMPONENT:fM,BRUSH:vM,CHART_ITEM:pl,ARIA:cM,DECAL:S0}},Pt="__flagInMainProcess",Lo="__mainProcessVersion",Ot="__pendingUpdate",wu="__needsUpdateStatus",hp=/^[a-zA-Z0-9_]+$/,xu="__connectUpdateStatus",vp=0,pM=1,gM=2;function b0(e){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];if(this.isDisposed()){this.id;return}return w0(this,e,t)}}function T0(e){return function(){for(var t=[],r=0;r<arguments.length;r++)t[r]=arguments[r];return w0(this,e,t)}}function w0(e,t,r){return r[0]=r[0]&&r[0].toLowerCase(),or.prototype[t].apply(e,r)}var x0=(function(e){V(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t})(or),C0=x0.prototype;C0.on=T0("on");C0.off=T0("off");var pn,Cu,Io,hr,Po,Du,Mu,Yn,Xn,cp,dp,Au,pp,Eo,gp,D0,pe,mp,$n,M0=(function(e){V(t,e);function t(r,n,i){var a=e.call(this,new yD)||this;a._chartsViews=[],a._chartsMap={},a._componentsViews=[],a._componentsMap={},a._pendingActions=[],i=i||{},a.__v_skip=!0,a._dom=r;var o="canvas",s="auto",l=!1;a[Lo]=1,i.ssr;var u=a._zr=pc(r,{renderer:i.renderer||o,devicePixelRatio:i.devicePixelRatio,width:i.width,height:i.height,ssr:i.ssr,useDirtyRect:j(i.useDirtyRect,l),useCoarsePointer:j(i.useCoarsePointer,s),pointerSize:i.pointerSize});a._ssr=i.ssr,a._throttledZrFlush=t0(wt(u.flush,u),17),a._updateTheme(n),a._locale=ux(i.locale||cy),a._coordSysMgr=new iv;var f=a._api=gp(a);function h(v,c){return v.__prio-c.__prio}return Uo(Os,h),Uo(Xf,h),a._scheduler=new i0(a,f,Xf,Os),a._messageCenter=new x0,a._initEvents(),a.resize=wt(a.resize,a),u.animation.on("frame",a._onframe,a),cp(u,a),dp(u,a),$u(a),a}return t.prototype._onframe=function(){if(!this._disposed){var r=this._scheduler,n=this._model,i=this._api;if(mp(this),this[Ot]){var a=this[Ot].silent;this[Pt]=!0,$n(this);try{pn(this),hr.update.call(this,null,this[Ot].updateParams)}catch(l){throw this[Pt]=!1,this[Ot]=null,l}this._zr.flush(),this[Pt]=!1,this[Ot]=null,Yn.call(this,a),Xn.call(this,a)}else if(r.unfinished){var o=nM;do{r.unfinished=!1;var s=ue.getTime();r.performSeriesTasks(n),r.performDataProcessorTasks(n),Du(this,n),r.performVisualTasks(n),Eo(this,this._model,i,"remain",{}),o-=ue.getTime()-s}while(o>0&&r.unfinished);r.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(r,n,i){if(!this[Pt]){if(this._disposed){this.id;return}var a,o,s;if(K(n)&&(i=n.lazyUpdate,a=n.silent,o=n.replaceMerge,s=n.transition,n=n.notMerge),this[Pt]=!0,$n(this),!this._model||n){var l=new Kx(this._api),u=this._theme,f=this._model=new sv;f.scheduler=this._scheduler,f.ssr=this._ssr,f.init(null,null,null,u,this._locale,l)}this._model.setOption(r,{replaceMerge:o},$f);var h={seriesTransition:s,optionChanged:!0};if(i)this[Ot]={silent:a,updateParams:h},this[Pt]=!1,this.getZr().wakeUp();else{try{pn(this),hr.update.call(this,null,h)}catch(v){throw this[Ot]=null,this[Pt]=!1,v}this._ssr||this._zr.flush(),this[Ot]=null,this[Pt]=!1,Yn.call(this,a),Xn.call(this,a)}}},t.prototype.setTheme=function(r,n){if(!this[Pt]){if(this._disposed){this.id;return}var i=this._model;if(i){var a=n&&n.silent,o=null;this[Ot]&&(a==null&&(a=this[Ot].silent),o=this[Ot].updateParams,this[Ot]=null),this[Pt]=!0,$n(this);try{this._updateTheme(r),i.setTheme(this._theme),pn(this),hr.update.call(this,{type:"setTheme"},o)}catch(s){throw this[Pt]=!1,s}this[Pt]=!1,Yn.call(this,a),Xn.call(this,a)}}},t.prototype._updateTheme=function(r){W(r)&&(r=A0[r]),r&&(r=ut(r),r&&Oy(r,!0),this._theme=r)},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||st.hasGlobalWindow&&window.devicePixelRatio||1},t.prototype.getRenderedCanvas=function(r){return this.renderToCanvas(r)},t.prototype.renderToCanvas=function(r){r=r||{};var n=this._zr.painter;return n.getRenderedCanvas({backgroundColor:r.backgroundColor||this._model.get("backgroundColor"),pixelRatio:r.pixelRatio||this.getDevicePixelRatio()})},t.prototype.renderToSVGString=function(r){r=r||{};var n=this._zr.painter;return n.renderToString({useViewBox:r.useViewBox})},t.prototype.getSvgDataURL=function(){var r=this._zr,n=r.storage.getDisplayList();return D(n,function(i){i.stopAnimation(null,!0)}),r.painter.toDataURL()},t.prototype.getDataURL=function(r){if(this._disposed){this.id;return}r=r||{};var n=r.excludeComponents,i=this._model,a=[],o=this;D(n,function(l){i.eachComponent({mainType:l},function(u){var f=o._componentsMap[u.__viewId];f.group.ignore||(a.push(f),f.group.ignore=!0)})});var s=this._zr.painter.getType()==="svg"?this.getSvgDataURL():this.renderToCanvas(r).toDataURL("image/"+(r&&r.type||"png"));return D(a,function(l){l.group.ignore=!1}),s},t.prototype.getConnectedDataURL=function(r){if(this._disposed){this.id;return}var n=r.type==="svg",i=this.group,a=Math.min,o=Math.max,s=1/0;if(yp[i]){var l=s,u=s,f=-s,h=-s,v=[],c=r&&r.pixelRatio||this.getDevicePixelRatio();D(va,function(_,S){if(_.group===i){var b=n?_.getZr().painter.getSvgDom().innerHTML:_.renderToCanvas(ut(r)),T=_.getDom().getBoundingClientRect();l=a(T.left,l),u=a(T.top,u),f=o(T.right,f),h=o(T.bottom,h),v.push({dom:b,left:T.left,top:T.top})}}),l*=c,u*=c,f*=c,h*=c;var d=f-l,p=h-u,m=ue.createCanvas(),g=pc(m,{renderer:n?"svg":"canvas"});if(g.resize({width:d,height:p}),n){var y="";return D(v,function(_){var S=_.left-l,b=_.top-u;y+='<g transform="translate('+S+","+b+')">'+_.dom+"</g>"}),g.painter.getSvgRoot().innerHTML=y,r.connectedBackgroundColor&&g.painter.setBackgroundColor(r.connectedBackgroundColor),g.refreshImmediately(),g.painter.toDataURL()}else return r.connectedBackgroundColor&&g.add(new Rt({shape:{x:0,y:0,width:d,height:p},style:{fill:r.connectedBackgroundColor}})),D(v,function(_){var S=new Wr({style:{x:_.left*c-l,y:_.top*c-u,image:_.dom}});g.add(S)}),g.refreshImmediately(),m.toDataURL("image/"+(r&&r.type||"png"))}else return this.getDataURL(r)},t.prototype.convertToPixel=function(r,n,i){return Po(this,"convertToPixel",r,n,i)},t.prototype.convertToLayout=function(r,n,i){return Po(this,"convertToLayout",r,n,i)},t.prototype.convertFromPixel=function(r,n,i){return Po(this,"convertFromPixel",r,n,i)},t.prototype.containPixel=function(r,n){if(this._disposed){this.id;return}var i=this._model,a,o=Zl(i,r);return D(o,function(s,l){l.indexOf("Models")>=0&&D(s,function(u){var f=u.coordinateSystem;if(f&&f.containPoint)a=a||!!f.containPoint(n);else if(l==="seriesModels"){var h=this._chartsMap[u.__viewId];h&&h.containPoint&&(a=a||h.containPoint(n,u))}},this)},this),!!a},t.prototype.getVisual=function(r,n){var i=this._model,a=Zl(i,r,{defaultMainType:"series"}),o=a.seriesModel,s=o.getData(),l=a.hasOwnProperty("dataIndexInside")?a.dataIndexInside:a.hasOwnProperty("dataIndex")?s.indexOfRawIndex(a.dataIndex):null;return l!=null?bD(s,l,n):TD(s,n)},t.prototype.getViewOfComponentModel=function(r){return this._componentsMap[r.__viewId]},t.prototype.getViewOfSeriesModel=function(r){return this._chartsMap[r.__viewId]},t.prototype._initEvents=function(){var r=this;D(mM,function(i){var a=function(o){var s=r.getModel(),l=o.target,u,f=i==="globalout";if(f?u={}:l&&ta(l,function(p){var m=gt(p);if(m&&m.dataIndex!=null){var g=m.dataModel||s.getSeriesByIndex(m.seriesIndex);return u=g&&g.getDataParams(m.dataIndex,m.dataType,l)||{},!0}else if(m.eventData)return u=N({},m.eventData),!0},!0),u){var h=u.componentType,v=u.componentIndex;(h==="markLine"||h==="markPoint"||h==="markArea")&&(h="series",v=u.seriesIndex);var c=h&&v!=null&&s.getComponent(h,v),d=c&&r[c.mainType==="series"?"_chartsMap":"_componentsMap"][c.__viewId];u.event=o,u.type=i,r._$eventProcessor.eventInfo={targetEl:l,packedEvent:u,model:c,view:d},r.trigger(i,u)}};a.zrEventfulCallAtLast=!0,r._zr.on(i,a,r)});var n=this._messageCenter;D(Yf,function(i,a){n.on(a,function(o){r.trigger(a,o)})}),wD(n,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 r=this.getDom();r&&mm(this.getDom(),dv,"");var n=this,i=n._api,a=n._model;D(n._componentsViews,function(o){o.dispose(a,i)}),D(n._chartsViews,function(o){o.dispose(a,i)}),n._zr.dispose(),n._dom=n._model=n._chartsMap=n._componentsMap=n._chartsViews=n._componentsViews=n._scheduler=n._api=n._zr=n._throttledZrFlush=n._theme=n._coordSysMgr=n._messageCenter=null,delete va[n.id]},t.prototype.resize=function(r){if(!this[Pt]){if(this._disposed){this.id;return}this._zr.resize(r);var n=this._model;if(this._loadingFX&&this._loadingFX.resize(),!!n){var i=n.resetOption("media"),a=r&&r.silent;this[Ot]&&(a==null&&(a=this[Ot].silent),i=!0,this[Ot]=null),this[Pt]=!0,$n(this);try{i&&pn(this),hr.update.call(this,{type:"resize",animation:N({duration:0},r&&r.animation)})}catch(o){throw this[Pt]=!1,o}this[Pt]=!1,Yn.call(this,a),Xn.call(this,a)}}},t.prototype.showLoading=function(r,n){if(this._disposed){this.id;return}if(K(r)&&(n=r,r=""),r=r||"default",this.hideLoading(),!!Zf[r]){var i=Zf[r](this._api,n),a=this._zr;this._loadingFX=i,a.add(i)}},t.prototype.hideLoading=function(){if(this._disposed){this.id;return}this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},t.prototype.makeActionFromEvent=function(r){var n=N({},r);return n.type=Wf[r.type],n},t.prototype.dispatchAction=function(r,n){if(this._disposed){this.id;return}if(K(n)||(n={silent:!!n}),!!ks[r.type]&&this._model){if(this[Pt]){this._pendingActions.push(r);return}var i=n.silent;Mu.call(this,r,i);var a=n.flush;a?this._zr.flush():a!==!1&&st.browser.weChat&&this._throttledZrFlush(),Yn.call(this,i),Xn.call(this,i)}},t.prototype.updateLabelLayout=function(){me.trigger("series:layoutlabels",this._model,this._api,{updatedSeries:[]})},t.prototype.appendData=function(r){if(this._disposed){this.id;return}var n=r.seriesIndex,i=this.getModel(),a=i.getSeriesByIndex(n);a.appendData(r),this._scheduler.unfinished=!0,this.getZr().wakeUp()},t.internalField=(function(){pn=function(h){DD(h._model);var v=h._scheduler;v.restorePipelines(h._zr,h._model),v.prepareStageTasks(),Cu(h,!0),Cu(h,!1),v.plan()},Cu=function(h,v){for(var c=h._model,d=h._scheduler,p=v?h._componentsViews:h._chartsViews,m=v?h._componentsMap:h._chartsMap,g=h._zr,y=h._api,_=0;_<p.length;_++)p[_].__alive=!1;v?c.eachComponent(function(T,w){T!=="series"&&S(w)}):c.eachSeries(S);function S(T){var w=T.__requireNewView;T.__requireNewView=!1;var M="_ec_"+T.id+"_"+T.type,C=!w&&m[M];if(!C){var x=Ze(T.type),A=v?ir.getClass(x.main,x.sub):er.getClass(x.sub);C=new A,C.init(c,y),m[M]=C,p.push(C),g.add(C.group)}T.__viewId=C.__id=M,C.__alive=!0,C.__model=T,C.group.__ecComponentInfo={mainType:T.mainType,index:T.componentIndex},!v&&d.prepareView(C,T,c,y)}for(var _=0;_<p.length;){var b=p[_];b.__alive?_++:(!v&&b.renderTask.dispose(),g.remove(b.group),b.dispose(c,y),p.splice(_,1),m[b.__id]===b&&delete m[b.__id],b.__id=b.group.__ecComponentInfo=null)}},Io=function(h,v,c,d,p){var m=h._model;if(m.setUpdatePayload(c),!d){D([].concat(h._componentsViews).concat(h._chartsViews),S);return}var g=db(c,d,p),y=c.excludeSeriesId,_;y!=null&&(_=nt(),D(Jt(y),function(b){var T=je(b,null);T!=null&&_.set(T,!0)})),m&&m.eachComponent(g,function(b){var T=_&&_.get(b.id)!=null;if(!T)if(Jc(c))if(b instanceof Vr)c.type===Dn&&!c.notBlur&&!b.get(["emphasis","disabled"])&&BT(b,c,h._api);else{var w=Ph(b.mainType,b.componentIndex,c.name,h._api),M=w.focusSelf,C=w.dispatchers;c.type===Dn&&M&&!c.notBlur&&wf(b.mainType,b.componentIndex,h._api),C&&D(C,function(x){c.type===Dn?xs(x):Cs(x)})}else Mf(c)&&b instanceof Vr&&(zT(b,c,h._api),qc(b),pe(h))},h),m&&m.eachComponent(g,function(b){var T=_&&_.get(b.id)!=null;T||S(h[d==="series"?"_chartsMap":"_componentsMap"][b.__viewId])},h);function S(b){b&&b.__alive&&b[v]&&b[v](b.__model,m,h._api,c)}},hr={prepareAndUpdate:function(h){pn(this),hr.update.call(this,h,h&&{optionChanged:h.newOption!=null})},update:function(h,v){var c=this._model,d=this._api,p=this._zr,m=this._coordSysMgr,g=this._scheduler;if(c){MD(c),c.setUpdatePayload(h),g.restoreData(c,h),g.performSeriesTasks(c),m.create(c,d),me.trigger("coordsys:aftercreate",c,d),g.performDataProcessorTasks(c,h),Du(this,c),m.update(c,d),n(c),g.performVisualTasks(c,h);var y=c.get("backgroundColor")||"transparent";p.setBackgroundColor(y);var _=c.get("darkMode");_!=null&&_!=="auto"&&p.setDarkMode(_),Au(this,c,d,h,v),me.trigger("afterupdate",c,d)}},updateTransform:function(h){var v=this,c=v._model,d=v._api;if(c){c.setUpdatePayload(h);var p=[];c.eachComponent(function(g,y){if(g!==Pm){var _=v.getViewOfComponentModel(y);if(_&&_.__alive)if(_.updateTransform){var S=_.updateTransform(y,c,d,h);S&&S.update&&p.push(_)}else p.push(_)}});var m=nt();c.eachSeries(function(g){var y=v._chartsMap[g.__viewId],_=g.pipelineContext;if(y.updateTransform&&!_.progressiveRender){var S=y.updateTransform(g,c,d,h);S&&S.update&&m.set(g.uid,1)}else m.set(g.uid,1)}),v._scheduler.performVisualTasks(c,h,{setDirty:!0,dirtyMap:m}),Eo(v,c,d,h,{},m),me.trigger("afterupdate",c,d)}},updateView:function(h){var v=this._model;v&&(v.setUpdatePayload(h),er.markUpdateMethod(h,"updateView"),n(v),this._scheduler.performVisualTasks(v,h,{setDirty:!0}),Au(this,v,this._api,h,{}),me.trigger("afterupdate",v,this._api))},updateVisual:function(h){var v=this,c=this._model;c&&(c.setUpdatePayload(h),c.eachSeries(function(d){d.getData().clearAllVisual()}),er.markUpdateMethod(h,"updateVisual"),n(c),this._scheduler.performVisualTasks(c,h,{visualType:"visual",setDirty:!0}),c.eachComponent(function(d,p){if(d!=="series"){var m=v.getViewOfComponentModel(p);m&&m.__alive&&m.updateVisual(p,c,v._api,h)}}),c.eachSeries(function(d){var p=v._chartsMap[d.__viewId];p.updateVisual(d,c,v._api,h)}),me.trigger("afterupdate",c,this._api))},updateLayout:function(h){hr.update.call(this,h)}};function r(h,v,c,d,p){if(h._disposed){h.id;return}for(var m=h._model,g=h._coordSysMgr.getCoordinateSystems(),y,_=Zl(m,c),S=0;S<g.length;S++){var b=g[S];if(b[v]&&(y=b[v](m,_,d,p))!=null)return y}}Po=r,Du=function(h,v){var c=h._chartsMap,d=h._scheduler;v.eachSeries(function(p){d.updateStreamModes(p,c[p.__viewId])})},Mu=function(h,v){var c=this,d=this.getModel(),p=h.type,m=h.escapeConnect,g=ks[p],y=(g.update||"update").split(":"),_=y.pop(),S=y[0]!=null&&Ze(y[0]);this[Pt]=!0,$n(this);var b=[h],T=!1;h.batch&&(T=!0,b=rt(h.batch,function(E){return E=yt(N({},E),h),E.batch=null,E}));var w=[],M,C=[],x=g.nonRefinedEventType,A=Mf(h),I=Jc(h);if(I&&Um(this._api),D(b,function(E){var F=g.action(E,d,c._api);if(g.refineEvent?C.push(F):M=F,M=M||N({},E),M.type=x,w.push(M),I){var G=Th(h),U=G.queryOptionMap,tt=G.mainTypeSpecified,Z=tt?U.keys()[0]:"series";Io(c,_,E,Z),pe(c)}else A?(Io(c,_,E,"series"),pe(c)):S&&Io(c,_,E,S.main,S.sub)}),_!=="none"&&!I&&!A&&!S)try{this[Ot]?(pn(this),hr.update.call(this,h),this[Ot]=null):hr[_].call(this,h)}catch(E){throw this[Pt]=!1,E}if(T?M={type:x,escapeConnect:m,batch:w}:M=w[0],this[Pt]=!1,!v){var L=void 0;if(g.refineEvent){var P=g.refineEvent(C,h,d,this._api).eventContent;pr(K(P)),L=yt({type:g.refinedEventType},P),L.fromAction=h.type,L.fromActionPayload=h,L.escapeConnect=!0}var R=this._messageCenter;R.trigger(M.type,M),L&&R.trigger(L.type,L)}},Yn=function(h){for(var v=this._pendingActions;v.length;){var c=v.shift();Mu.call(this,c,h)}},Xn=function(h){!h&&this.trigger("updated")},cp=function(h,v){h.on("rendered",function(c){v.trigger("rendered",c),h.animation.isFinished()&&!v[Ot]&&!v._scheduler.unfinished&&!v._pendingActions.length?v.trigger("finished"):h.refresh()})},dp=function(h,v){h.on("mouseover",function(c){var d=c.target,p=ta(d,Df);p&&(NT(p,c,v._api),pe(v))}).on("mouseout",function(c){var d=c.target,p=ta(d,Df);p&&(FT(p,c,v._api),pe(v))}).on("click",function(c){var d=c.target,p=ta(d,function(y){return gt(y).dataIndex!=null},!0);if(p){var m=p.selected?"unselect":"select",g=gt(p);v._api.dispatchAction({type:m,dataType:g.dataType,dataIndexInside:g.dataIndex,seriesIndex:g.seriesIndex,isFromClick:!0})}})};function n(h){h.clearColorPalette(),h.eachSeries(function(v){v.clearColorPalette()})}function i(h){var v=[],c=[],d=!1;if(h.eachComponent(function(y,_){var S=_.get("zlevel")||0,b=_.get("z")||0,T=_.getZLevelKey();d=d||!!T,(y==="series"?c:v).push({zlevel:S,z:b,idx:_.componentIndex,type:y,key:T})}),d){var p=v.concat(c),m,g;Uo(p,function(y,_){return y.zlevel===_.zlevel?y.z-_.z:y.zlevel-_.zlevel}),D(p,function(y){var _=h.getComponent(y.type,y.idx),S=y.zlevel,b=y.key;m!=null&&(S=Math.max(m,S)),b?(S===m&&b!==g&&S++,g=b):g&&(S===m&&S++,g=""),m=S,_.setZLevel(S)})}}Au=function(h,v,c,d,p){i(v),pp(h,v,c,d,p),D(h._chartsViews,function(m){m.__alive=!1}),Eo(h,v,c,d,p),D(h._chartsViews,function(m){m.__alive||m.remove(v,c)})},pp=function(h,v,c,d,p,m){D(m||h._componentsViews,function(g){var y=g.__model;u(y,g),g.render(y,v,c,d),l(y,g),f(y,g)})},Eo=function(h,v,c,d,p,m){var g=h._scheduler;p=N(p||{},{updatedSeries:v.getSeries()}),me.trigger("series:beforeupdate",v,c,p);var y=!1;v.eachSeries(function(_){var S=h._chartsMap[_.__viewId];S.__alive=!0;var b=S.renderTask;g.updatePayload(b,d),u(_,S),m&&m.get(_.uid)&&b.dirty(),b.perform(g.getPerformArgs(b))&&(y=!0),S.group.silent=!!_.get("silent"),s(_,S),qc(_)}),g.unfinished=y||g.unfinished,me.trigger("series:layoutlabels",v,c,p),me.trigger("series:transition",v,c,p),v.eachSeries(function(_){var S=h._chartsMap[_.__viewId];l(_,S),f(_,S)}),o(h,v),me.trigger("series:afterupdate",v,c,p)},pe=function(h){h[wu]=!0,h.getZr().wakeUp()},$n=function(h){h[Lo]=(h[Lo]+1)%1e6},mp=function(h){h[wu]&&(h.getZr().storage.traverse(function(v){sa(v)||a(v)}),h[wu]=!1)};function a(h){for(var v=[],c=h.currentStates,d=0;d<c.length;d++){var p=c[d];p==="emphasis"||p==="blur"||p==="select"||v.push(p)}h.selected&&h.states.select&&v.push("select"),h.hoverState===nl&&h.states.emphasis?v.push("emphasis"):h.hoverState===rl&&h.states.blur&&v.push("blur"),h.useStates(v)}function o(h,v){var c=h._zr;if(c.painter.type==="canvas"){var d=c.storage,p=0;d.traverse(function(g){g.isGroup||p++});var m=p>j(v.get("hoverLayerThreshold"),Iy.hoverLayerThreshold)&&!st.node&&!st.worker;(h._usingTHL||m)&&(v.eachSeries(function(g){if(!g.preventUsingHoverLayer){var y=h._chartsMap[g.__viewId];y.__alive&&y.eachRendered(function(_){var S=_.states.emphasis;S&&S.hoverLayer!==Fh&&(S.hoverLayer=m?ey:ty)})}}),h._usingTHL=m)}}function s(h,v){var c=h.get("blendMode")||null;v.eachRendered(function(d){d.isGroup||(d.style.blend=c)})}function l(h,v){if(!h.preventAutoZ){var c=sy(h);v.eachRendered(function(d){return ly(d,c.z,c.zlevel),!0})}}function u(h,v){v.eachRendered(function(c){if(!sa(c)){var d=c.getTextContent(),p=c.getTextGuideLine();c.stateTransition&&(c.stateTransition=null),d&&d.stateTransition&&(d.stateTransition=null),p&&p.stateTransition&&(p.stateTransition=null),c.hasState()?(c.prevStates=c.currentStates,c.clearStates()):c.prevStates&&(c.prevStates=null)}})}function f(h,v){var c=h.getModel("stateAnimation"),d=h.isAnimationEnabled(),p=c.get("duration"),m=p>0?{duration:p,delay:c.get("delay"),easing:c.get("easing")}:null;v.eachRendered(function(g){if(g.states&&g.states.emphasis){if(sa(g))return;if(g instanceof St&&YT(g),g.__dirty){var y=g.prevStates;y&&g.useStates(y)}if(d){g.stateTransition=m;var _=g.getTextContent(),S=g.getTextGuideLine();_&&(_.stateTransition=m),S&&(S.stateTransition=m)}g.__dirty&&a(g)}})}gp=function(h){return new((function(v){V(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(d){for(;d;){var p=d.__ecComponentInfo;if(p!=null)return h._model.getComponent(p.mainType,p.index);d=d.parent}},c.prototype.enterEmphasis=function(d,p){xs(d,p),pe(h)},c.prototype.leaveEmphasis=function(d,p){Cs(d,p),pe(h)},c.prototype.enterBlur=function(d){OT(d),pe(h)},c.prototype.leaveBlur=function(d){zm(d),pe(h)},c.prototype.enterSelect=function(d){Hm(d),pe(h)},c.prototype.leaveSelect=function(d){Vm(d),pe(h)},c.prototype.getModel=function(){return h.getModel()},c.prototype.getViewOfComponentModel=function(d){return h.getViewOfComponentModel(d)},c.prototype.getViewOfSeriesModel=function(d){return h.getViewOfSeriesModel(d)},c.prototype.getECUpdateCycleVersion=function(){return h[Lo]},c.prototype.usingTHL=function(){return h._usingTHL},c})(km))(h)},D0=function(h){function v(c,d){for(var p=0;p<c.length;p++){var m=c[p];m[xu]=d}}D(Wf,function(c,d){h._messageCenter.on(d,function(p){if(yp[h.group]&&h[xu]!==vp){if(p&&p.escapeConnect)return;var m=h.makeActionFromEvent(p),g=[];D(va,function(y){y!==h&&y.group===h.group&&g.push(y)}),v(g,vp),D(g,function(y){y[xu]!==pM&&y.dispatchAction(m)}),v(g,gM)}})})}})(),t})(or),cv=M0.prototype;cv.on=b0("on");cv.off=b0("off");cv.one=function(e,t,r){var n=this;function i(){for(var a=[],o=0;o<arguments.length;o++)a[o]=arguments[o];t&&t.apply&&t.apply(this,a),n.off(e,i)}this.on.call(this,e,i,r)};var mM=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];var ks={},Wf={},Yf={},Xf=[],$f=[],Os=[],A0={},Zf={},va={},yp={},yM=+new Date-0,dv="_echarts_instance_";function _p(e,t,r){{var n=_M(e);if(n)return n}var i=new M0(e,t,r);return i.id="ec_"+yM++,va[i.id]=i,mm(e,dv,i.id),D0(i),me.trigger("afterinit",i),i}function _M(e){return va[pb(e,dv)]}function L0(e,t){A0[e]=t}function I0(e){vt($f,e)<0&&$f.push(e)}function P0(e,t){gv(Xf,e,t,lM)}function SM(e){pv("afterinit",e)}function bM(e){pv("afterupdate",e)}function pv(e,t){me.on(e,t)}function Mi(e,t,r){var n,i,a,o,s;ot(t)&&(r=t,t=""),K(e)?(n=e.type,i=e.event,o=e.update,s=e.publishNonRefinedEvent,r||(r=e.action),a=e.refineEvent):(n=e,i=t);function l(f){return f.toLowerCase()}i=l(i||n);var u=a?l(n):i;ks[n]||(pr(hp.test(n)&&hp.test(i)),a&&pr(i!==n),ks[n]={actionType:n,refinedEventType:i,nonRefinedEventType:u,update:o,action:r,refineEvent:a},Yf[i]=1,a&&s&&(Yf[u]=1),Wf[u]=n)}function TM(e,t){iv.register(e,t)}function wM(e,t){gv(Os,e,t,y0,"layout")}function Rn(e,t){gv(Os,e,t,_0,"visual")}var Sp=[];function gv(e,t,r,n,i,a){if((ot(t)||K(t))&&(r=t,t=n),!(vt(Sp,r)>=0)){Sp.push(r);var o=i0.wrapStageHandler(r,i);o.__prio=t,o.__raw=r,e.push(o)}}function E0(e,t){Zf[e]=t}function xM(e,t,r){var n=CD("registerMap");n&&n(e,t,r)}var CM=LC;Rn(vv,aD);Rn(pl,oD);Rn(pl,sD);Rn(vv,_D);Rn(pl,SD);Rn(S0,eM);I0(Oy);P0(aM,lC);E0("default",lD);Mi({type:Dn,event:Dn,update:Dn},$t);Mi({type:Ko,event:Ko,update:Ko},$t);Mi({type:Ts,event:Lh,update:Ts,action:$t,refineEvent:mv,publishNonRefinedEvent:!0});Mi({type:bf,event:Lh,update:bf,action:$t,refineEvent:mv,publishNonRefinedEvent:!0});Mi({type:ws,event:Lh,update:ws,action:$t,refineEvent:mv,publishNonRefinedEvent:!0});function mv(e,t,r,n){return{eventContent:{selected:HT(r),isFromClick:t.isFromClick||!1}}}L0("default",{});L0("dark",l0);function zi(e){return e==null?0:e.length||1}function bp(e){return e}var DM=(function(){function e(t,r,n,i,a,o){this._old=t,this._new=r,this._oldKeyGetter=n||bp,this._newKeyGetter=i||bp,this.context=a,this._diffModeMultiple=o==="multiple"}return e.prototype.add=function(t){return this._add=t,this},e.prototype.update=function(t){return this._update=t,this},e.prototype.updateManyToOne=function(t){return this._updateManyToOne=t,this},e.prototype.updateOneToMany=function(t){return this._updateOneToMany=t,this},e.prototype.updateManyToMany=function(t){return this._updateManyToMany=t,this},e.prototype.remove=function(t){return this._remove=t,this},e.prototype.execute=function(){this[this._diffModeMultiple?"_executeMultiple":"_executeOneToOne"]()},e.prototype._executeOneToOne=function(){var t=this._old,r=this._new,n={},i=new Array(t.length),a=new Array(r.length);this._initIndexMap(t,null,i,"_oldKeyGetter"),this._initIndexMap(r,n,a,"_newKeyGetter");for(var o=0;o<t.length;o++){var s=i[o],l=n[s],u=zi(l);if(u>1){var f=l.shift();l.length===1&&(n[s]=l[0]),this._update&&this._update(f,o)}else u===1?(n[s]=null,this._update&&this._update(l,o)):this._remove&&this._remove(o)}this._performRestAdd(a,n)},e.prototype._executeMultiple=function(){var t=this._old,r=this._new,n={},i={},a=[],o=[];this._initIndexMap(t,n,a,"_oldKeyGetter"),this._initIndexMap(r,i,o,"_newKeyGetter");for(var s=0;s<a.length;s++){var l=a[s],u=n[l],f=i[l],h=zi(u),v=zi(f);if(h>1&&v===1)this._updateManyToOne&&this._updateManyToOne(f,u),i[l]=null;else if(h===1&&v>1)this._updateOneToMany&&this._updateOneToMany(f,u),i[l]=null;else if(h===1&&v===1)this._update&&this._update(f,u),i[l]=null;else if(h>1&&v>1)this._updateManyToMany&&this._updateManyToMany(f,u),i[l]=null;else if(h>1)for(var c=0;c<h;c++)this._remove&&this._remove(u[c]);else this._remove&&this._remove(u)}this._performRestAdd(o,i)},e.prototype._performRestAdd=function(t,r){for(var n=0;n<t.length;n++){var i=t[n],a=r[i],o=zi(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);r[i]=null}},e.prototype._initIndexMap=function(t,r,n,i){for(var a=this._diffModeMultiple,o=0;o<t.length;o++){var s="_ec_"+this[i](t[o],o);if(a||(n[o]=s),!!r){var l=r[s],u=zi(l);u===0?(r[s]=o,a&&n.push(s)):u===1?r[s]=[l,o]:l.push(o)}}},e})(),MM=(function(){function e(t,r){this._encode=t,this._schema=r}return e.prototype.get=function(){return{fullDimensions:this._getFullDimensionNames(),encode:this._encode}},e.prototype._getFullDimensionNames=function(){return this._cachedDimNames||(this._cachedDimNames=this._schema?this._schema.makeOutputDimensionNames():[]),this._cachedDimNames},e})();function AM(e,t){var r={},n=r.encode={},i=nt(),a=[],o=[],s={};D(e.dimensions,function(v){var c=e.getDimensionInfo(v),d=c.coordDim;if(d){var p=c.coordDimIndex;Lu(n,d)[p]=v,c.isExtraCoord||(i.set(d,1),IM(c.type)&&(a[0]=v),Lu(s,d)[p]=e.getDimensionIndex(c.name)),c.defaultTooltip&&o.push(v)}Em.each(function(m,g){var y=Lu(n,g),_=c.otherDims[g];_!=null&&_!==!1&&(y[_]=c.name)})});var l=[],u={};i.each(function(v,c){var d=n[c];u[c]=d[0],l=l.concat(d)}),r.dataDimsOnCoord=l,r.dataDimIndicesOnCoord=rt(l,function(v){return e.getDimensionInfo(v).storeDimIndex}),r.encodeFirstDimNotExtra=u;var f=n.label;f&&f.length&&(a=f.slice());var h=n.tooltip;return h&&h.length?o=h.slice():o.length||(o=a.slice()),n.defaultedLabel=a,n.defaultedTooltip=o,r.userOutput=new MM(s,t),r}function Lu(e,t){return e.hasOwnProperty(t)||(e[t]=[]),e[t]}function LM(e){return e==="category"?"ordinal":e==="time"?"time":"float"}function IM(e){return!(e==="ordinal"||e==="time")}var as=(function(){function e(t){this.otherDims={},t!=null&&N(this,t)}return e})(),PM=bt(),EM={float:"f",int:"i",ordinal:"o",number:"n",time:"t"},R0=(function(){function e(t){this.dimensions=t.dimensions,this._dimOmitted=t.dimensionOmitted,this.source=t.source,this._fullDimCount=t.fullDimensionCount,this._updateDimOmitted(t.dimensionOmitted)}return e.prototype.isDimensionOmitted=function(){return this._dimOmitted},e.prototype._updateDimOmitted=function(t){this._dimOmitted=t,t&&(this._dimNameMap||(this._dimNameMap=O0(this.source)))},e.prototype.getSourceDimensionIndex=function(t){return j(this._dimNameMap.get(t),-1)},e.prototype.getSourceDimension=function(t){var r=this.source.dimensionsDefine;if(r)return r[t]},e.prototype.makeStoreSchema=function(){for(var t=this._fullDimCount,r=Fy(this.source),n=!B0(t),i="",a=[],o=0,s=0;o<t;o++){var l=void 0,u=void 0,f=void 0,h=this.dimensions[s];if(h&&h.storeDimIndex===o)l=r?h.name:null,u=h.type,f=h.ordinalMeta,s++;else{var v=this.getSourceDimension(o);v&&(l=r?v.name:null,u=v.type)}a.push({property:l,type:u,ordinalMeta:f}),r&&l!=null&&(!h||!h.isCalculationCoord)&&(i+=n?l.replace(/\`/g,"`1").replace(/\$/g,"`2"):l),i+="$",i+=EM[u]||"f",f&&(i+=f.uid),i+="$"}var c=this.source,d=[c.seriesLayoutBy,c.startIndex,i].join("$$");return{dimensions:a,hash:d}},e.prototype.makeOutputDimensionNames=function(){for(var t=[],r=0,n=0;r<this._fullDimCount;r++){var i=void 0,a=this.dimensions[n];if(a&&a.storeDimIndex===r)a.isCalculationCoord||(i=a.name),n++;else{var o=this.getSourceDimension(r);o&&(i=o.name)}t.push(i)}return t},e.prototype.appendCalculationDimension=function(t){this.dimensions.push(t),t.isCalculationCoord=!0,this._fullDimCount++,this._updateDimOmitted(!0)},e})();function k0(e){return e instanceof R0}function yv(e){for(var t=nt(),r=0;r<(e||[]).length;r++){var n=e[r],i=K(n)?n.name:n;i!=null&&t.get(i)==null&&t.set(i,r)}return t}function O0(e){var t=PM(e);return t.dimNameMap||(t.dimNameMap=yv(e.dimensionsDefine))}function B0(e){return e>30}var Hi=K,xr=rt,RM=typeof Int32Array>"u"?Array:Int32Array,kM="e\0\0",Tp=-1,OM=["hasItemOption","_nameList","_idList","_invertedIndicesMap","_dimSummary","userOutput","_rawData","_dimValueGetter","_nameDimIdx","_idDimIdx","_nameRepeatCount"],BM=["_approximateExtent"],wp,Ro,Vi,Gi,Iu,Ui,Pu,NM=(function(){function e(t,r){this.type="list",this._dimOmitted=!1,this._nameList=[],this._idList=[],this._visual={},this._layout={},this._itemVisuals=[],this._itemLayouts=[],this._graphicEls=[],this._approximateExtent={},this._calculationInfo={},this.hasItemOption=!1,this.TRANSFERABLE_METHODS=["cloneShallow","downSample","minmaxDownSample","lttbDownSample","map"],this.CHANGABLE_METHODS=["filterSelf","selectRange"],this.DOWNSAMPLE_METHODS=["downSample","minmaxDownSample","lttbDownSample"];var n,i=!1;k0(t)?(n=t.dimensions,this._dimOmitted=t.isDimensionOmitted(),this._schema=t):(i=!0,n=t),n=n||["x","y"];for(var a={},o=[],s={},l=!1,u={},f=0;f<n.length;f++){var h=n[f],v=W(h)?new as({name:h}):h instanceof as?h:new as(h),c=v.name;v.type=v.type||"float",v.coordDim||(v.coordDim=c,v.coordDimIndex=0);var d=v.otherDims=v.otherDims||{};o.push(c),a[c]=v,u[c]!=null&&(l=!0),v.createInvertedIndices&&(s[c]=[]),i&&(v.storeDimIndex=f),d.itemName===0&&(this._nameDimIdx=v.storeDimIndex),d.itemId===0&&(this._idDimIdx=v.storeDimIndex)}if(this.dimensions=o,this._dimInfos=a,this._initGetDimensionInfo(l),this.hostModel=r,this._invertedIndicesMap=s,this._dimOmitted){var p=this._dimIdxToName=nt();D(o,function(m){p.set(a[m].storeDimIndex,m)})}}return e.prototype.getDimension=function(t){var r=this._recognizeDimIndex(t);if(r==null)return t;if(r=t,!this._dimOmitted)return this.dimensions[r];var n=this._dimIdxToName.get(r);if(n!=null)return n;var i=this._schema.getSourceDimension(r);if(i)return i.name},e.prototype.getDimensionIndex=function(t){var r=this._recognizeDimIndex(t);if(r!=null)return r;if(t==null)return-1;var n=this._getDimInfo(t);return n?n.storeDimIndex:this._dimOmitted?this._schema.getSourceDimensionIndex(t):-1},e.prototype._recognizeDimIndex=function(t){if(Ct(t)||t!=null&&!isNaN(t)&&!this._getDimInfo(t)&&(!this._dimOmitted||this._schema.getSourceDimensionIndex(t)<0))return+t},e.prototype._getStoreDimIndex=function(t){var r=this.getDimensionIndex(t);return r},e.prototype.getDimensionInfo=function(t){return this._getDimInfo(this.getDimension(t))},e.prototype._initGetDimensionInfo=function(t){var r=this._dimInfos;this._getDimInfo=t?function(n){return r.hasOwnProperty(n)?r[n]:void 0}:function(n){return r[n]}},e.prototype.getDimensionsOnCoord=function(){return this._dimSummary.dataDimsOnCoord.slice()},e.prototype.mapDimension=function(t,r){var n=this._dimSummary;if(r==null)return n.encodeFirstDimNotExtra[t];var i=n.encode[t];return i?i[r]:null},e.prototype.mapDimensionsAll=function(t){var r=this._dimSummary,n=r.encode[t];return(n||[]).slice()},e.prototype.getStore=function(){return this._store},e.prototype.initData=function(t,r,n){var i=this,a;if(t instanceof kf&&(a=t),!a){var o=this.dimensions,s=lv(t)||ie(t)?new zy(t,o.length):t;a=new kf;var l=xr(o,function(u){return{type:i._dimInfos[u].type,property:u}});a.initData(s,l,n)}this._store=a,this._nameList=(r||[]).slice(),this._idList=[],this._nameRepeatCount={},this._doInit(0,a.count()),this._dimSummary=AM(this,this._schema),this.userOutput=this._dimSummary.userOutput},e.prototype.appendData=function(t){var r=this._store.appendData(t);this._doInit(r[0],r[1])},e.prototype.appendValues=function(t,r){var n=this._store.appendValues(t,r&&r.length),i=n.start,a=n.end,o=this._shouldMakeIdFromName();if(this._updateOrdinalMeta(),r)for(var s=i;s<a;s++){var l=s-i;this._nameList[s]=r[l],o&&Pu(this,s)}},e.prototype._updateOrdinalMeta=function(){for(var t=this._store,r=this.dimensions,n=0;n<r.length;n++){var i=this._dimInfos[r[n]];i.ordinalMeta&&t.collectOrdinalMeta(i.storeDimIndex,i.ordinalMeta)}},e.prototype._shouldMakeIdFromName=function(){var t=this._store.getProvider();return this._idDimIdx==null&&t.getSource().sourceFormat!==Or&&!t.fillStorage},e.prototype._doInit=function(t,r){if(!(t>=r)){var n=this._store,i=n.getProvider();this._updateOrdinalMeta();var a=this._nameList,o=this._idList,s=i.getSource().sourceFormat,l=s===ve;if(l&&!i.pure)for(var u=[],f=t;f<r;f++){var h=i.getItem(f,u);if(!this.hasItemOption&&nb(h)&&(this.hasItemOption=!0),h){var v=h.name;a[f]==null&&v!=null&&(a[f]=je(v,null));var c=h.id;o[f]==null&&c!=null&&(o[f]=je(c,null))}}if(this._shouldMakeIdFromName())for(var f=t;f<r;f++)Pu(this,f);wp(this)}},e.prototype.getApproximateExtent=function(t,r){return this._approximateExtent[t]||this._store.getDataExtent(this._getStoreDimIndex(t),r)},e.prototype.setApproximateExtent=function(t,r){r=this.getDimension(r),this._approximateExtent[r]=t.slice()},e.prototype.getCalculationInfo=function(t){return this._calculationInfo[t]},e.prototype.setCalculationInfo=function(t,r){Hi(t)?N(this._calculationInfo,t):this._calculationInfo[t]=r},e.prototype.getName=function(t){var r=this.getRawIndex(t),n=this._nameList[r];return n==null&&this._nameDimIdx!=null&&(n=Vi(this,this._nameDimIdx,r)),n==null&&(n=""),n},e.prototype._getCategory=function(t,r){var n=this._store.get(t,r),i=this._store.getOrdinalMeta(t);return i?i.categories[n]:n},e.prototype.getId=function(t){return Ro(this,this.getRawIndex(t))},e.prototype.count=function(){return this._store.count()},e.prototype.get=function(t,r){var n=this._store,i=this._dimInfos[t];if(i)return n.get(i.storeDimIndex,r)},e.prototype.getByRawIndex=function(t,r){var n=this._store,i=this._dimInfos[t];if(i)return n.getByRawIndex(i.storeDimIndex,r)},e.prototype.getIndices=function(){return this._store.getIndices()},e.prototype.getDataExtent=function(t){return this._store.getDataExtent(this._getStoreDimIndex(t),null)},e.prototype.getSum=function(t){return this._store.getSum(this._getStoreDimIndex(t))},e.prototype.getMedian=function(t){return this._store.getMedian(this._getStoreDimIndex(t))},e.prototype.getValues=function(t,r){var n=this,i=this._store;return H(t)?i.getValues(xr(t,function(a){return n._getStoreDimIndex(a)}),r):i.getValues(t)},e.prototype.hasValue=function(t){for(var r=this._dimSummary.dataDimIndicesOnCoord,n=0,i=r.length;n<i;n++)if(isNaN(this._store.get(r[n],t)))return!1;return!0},e.prototype.indexOfName=function(t){for(var r=0,n=this._store.count();r<n;r++)if(this.getName(r)===t)return r;return-1},e.prototype.getRawIndex=function(t){return this._store.getRawIndex(t)},e.prototype.indexOfRawIndex=function(t){return this._store.indexOfRawIndex(t)},e.prototype.rawIndexOf=function(t,r){var n=t&&this._invertedIndicesMap[t],i=n&&n[r];return i==null||isNaN(i)?Tp:i},e.prototype.each=function(t,r,n){ot(t)&&(n=r,r=t,t=[]);var i=n||this,a=xr(Gi(t),this._getStoreDimIndex,this);this._store.each(a,i?wt(r,i):r)},e.prototype.filterSelf=function(t,r,n){ot(t)&&(n=r,r=t,t=[]);var i=n||this,a=xr(Gi(t),this._getStoreDimIndex,this);return this._store=this._store.filter(a,i?wt(r,i):r),this},e.prototype.selectRange=function(t){var r=this,n={},i=xt(t);return D(i,function(a){var o=r._getStoreDimIndex(a);n[o]=t[a]}),this._store=this._store.selectRange(n),this},e.prototype.mapArray=function(t,r,n){ot(t)&&(n=r,r=t,t=[]),n=n||this;var i=[];return this.each(t,function(){i.push(r&&r.apply(this,arguments))},n),i},e.prototype.map=function(t,r,n,i){var a=n||i||this,o=xr(Gi(t),this._getStoreDimIndex,this),s=Ui(this);return s._store=this._store.map(o,a?wt(r,a):r),s},e.prototype.modify=function(t,r,n,i){var a=n||i||this,o=xr(Gi(t),this._getStoreDimIndex,this);this._store.modify(o,a?wt(r,a):r)},e.prototype.downSample=function(t,r,n,i){var a=Ui(this);return a._store=this._store.downSample(this._getStoreDimIndex(t),r,n,i),a},e.prototype.minmaxDownSample=function(t,r){var n=Ui(this);return n._store=this._store.minmaxDownSample(this._getStoreDimIndex(t),r),n},e.prototype.lttbDownSample=function(t,r){var n=Ui(this);return n._store=this._store.lttbDownSample(this._getStoreDimIndex(t),r),n},e.prototype.getRawDataItem=function(t){return this._store.getRawDataItem(t)},e.prototype.getItemModel=function(t){var r=this.hostModel,n=this.getRawDataItem(t);return new Mt(n,r,r&&r.ecModel)},e.prototype.diff=function(t){var r=this;return new DM(t?t.getStore().getIndices():[],this.getStore().getIndices(),function(n){return Ro(t,n)},function(n){return Ro(r,n)})},e.prototype.getVisual=function(t){var r=this._visual;return r&&r[t]},e.prototype.setVisual=function(t,r){this._visual=this._visual||{},Hi(t)?N(this._visual,t):this._visual[t]=r},e.prototype.getItemVisual=function(t,r){var n=this._itemVisuals[t],i=n&&n[r];return i??this.getVisual(r)},e.prototype.hasItemVisual=function(){return this._itemVisuals.length>0},e.prototype.ensureUniqueItemVisual=function(t,r){var n=this._itemVisuals,i=n[t];i||(i=n[t]={});var a=i[r];return a==null&&(a=this.getVisual(r),H(a)?a=a.slice():Hi(a)&&(a=N({},a)),i[r]=a),a},e.prototype.setItemVisual=function(t,r,n){var i=this._itemVisuals[t]||{};this._itemVisuals[t]=i,Hi(r)?N(i,r):i[r]=n},e.prototype.clearAllVisual=function(){this._visual={},this._itemVisuals=[]},e.prototype.setLayout=function(t,r){Hi(t)?N(this._layout,t):this._layout[t]=r},e.prototype.getLayout=function(t){return this._layout[t]},e.prototype.getItemLayout=function(t){return this._itemLayouts[t]},e.prototype.setItemLayout=function(t,r,n){this._itemLayouts[t]=n?N(this._itemLayouts[t]||{},r):r},e.prototype.clearItemLayouts=function(){this._itemLayouts.length=0},e.prototype.setItemGraphicEl=function(t,r){var n=this.hostModel&&this.hostModel.seriesIndex;wT(n,this.dataType,t,r),this._graphicEls[t]=r},e.prototype.getItemGraphicEl=function(t){return this._graphicEls[t]},e.prototype.eachItemGraphicEl=function(t,r){D(this._graphicEls,function(n,i){n&&t&&t.call(r,n,i)})},e.prototype.cloneShallow=function(t){return t||(t=new e(this._schema?this._schema:xr(this.dimensions,this._getDimInfo,this),this.hostModel)),Iu(t,this),t._store=this._store,t},e.prototype.wrapMethod=function(t,r){var n=this[t];ot(n)&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var i=n.apply(this,arguments);return r.apply(this,[i].concat(ch(arguments)))})},e.internalField=(function(){wp=function(t){var r=t._invertedIndicesMap;D(r,function(n,i){var a=t._dimInfos[i],o=a.ordinalMeta,s=t._store;if(o){n=r[i]=new RM(o.categories.length);for(var l=0;l<n.length;l++)n[l]=Tp;for(var l=0;l<s.count();l++)n[s.get(a.storeDimIndex,l)]=l}})},Vi=function(t,r,n){return je(t._getCategory(r,n),null)},Ro=function(t,r){var n=t._idList[r];return n==null&&t._idDimIdx!=null&&(n=Vi(t,t._idDimIdx,r)),n==null&&(n=kM+r),n},Gi=function(t){return H(t)||(t=t!=null?[t]:[]),t},Ui=function(t){var r=new e(t._schema?t._schema:xr(t.dimensions,t._getDimInfo,t),t.hostModel);return Iu(r,t),r},Iu=function(t,r){D(OM.concat(r.__wrappedMethods||[]),function(n){r.hasOwnProperty(n)&&(t[n]=r[n])}),t.__wrappedMethods=r.__wrappedMethods,D(BM,function(n){t[n]=ut(r[n])}),t._calculationInfo=N({},r._calculationInfo)},Pu=function(t,r){var n=t._nameList,i=t._idList,a=t._nameDimIdx,o=t._idDimIdx,s=n[r],l=i[r];if(s==null&&a!=null&&(n[r]=s=Vi(t,a,r)),l==null&&o!=null&&(i[r]=l=Vi(t,o,r)),l==null&&s!=null){var u=t._nameRepeatCount,f=u[s]=(u[s]||0)+1;l=s,f>1&&(l+="__ec__"+f),i[r]=l}}})(),e})();function FM(e,t){lv(e)||(e=By(e)),t=t||{};var r=t.coordDimensions||[],n=t.dimensionsDefine||e.dimensionsDefine||[],i=nt(),a=[],o=zM(e,r,n,t.dimensionsCount),s=t.canOmitUnusedDimensions&&B0(o),l=n===e.dimensionsDefine,u=l?O0(e):yv(n),f=t.encodeDefine;!f&&t.encodeDefaulter&&(f=t.encodeDefaulter(e,o));for(var h=nt(f),v=new Wy(o),c=0;c<v.length;c++)v[c]=-1;function d(C){var x=v[C];if(x<0){var A=n[C],I=K(A)?A:{name:A},L=new as,P=I.name;P!=null&&u.get(P)!=null&&(L.name=L.displayName=P),I.type!=null&&(L.type=I.type),I.displayName!=null&&(L.displayName=I.displayName);var R=a.length;return v[C]=R,L.storeDimIndex=C,a.push(L),L}return a[x]}if(!s)for(var c=0;c<o;c++)d(c);h.each(function(C,x){var A=Jt(C).slice();if(A.length===1&&!W(A[0])&&A[0]<0){h.set(x,!1);return}var I=h.set(x,[]);D(A,function(L,P){var R=W(L)?u.get(L):L;R!=null&&R<o&&(I[P]=R,m(d(R),x,P))})});var p=0;D(r,function(C){var x,A,I,L;if(W(C))x=C,L={};else{L=C,x=L.name;var P=L.ordinalMeta;L.ordinalMeta=null,L=N({},L),L.ordinalMeta=P,A=L.dimsDef,I=L.otherDims,L.name=L.coordDim=L.coordDimIndex=L.dimsDef=L.otherDims=null}var R=h.get(x);if(R!==!1){if(R=Jt(R),!R.length)for(var E=0;E<(A&&A.length||1);E++){for(;p<o&&d(p).coordDim!=null;)p++;p<o&&R.push(p++)}D(R,function(F,G){var U=d(F);if(l&&L.type!=null&&(U.type=L.type),m(yt(U,L),x,G),U.name==null&&A){var tt=A[G];!K(tt)&&(tt={name:tt}),U.name=U.displayName=tt.name,U.defaultTooltip=tt.defaultTooltip}I&&yt(U.otherDims,I)})}});function m(C,x,A){Em.get(x)!=null?C.otherDims[x]=A:(C.coordDim=x,C.coordDimIndex=A,i.set(x,!0))}var g=t.generateCoord,y=t.generateCoordCount,_=y!=null;y=g?y||1:0;var S=g||"value";function b(C){C.name==null&&(C.name=C.coordDim)}if(s)D(a,function(C){b(C)}),a.sort(function(C,x){return C.storeDimIndex-x.storeDimIndex});else for(var T=0;T<o;T++){var w=d(T),M=w.coordDim;M==null&&(w.coordDim=HM(S,i,_),w.coordDimIndex=0,(!g||y<=0)&&(w.isExtraCoord=!0),y--),b(w),w.type==null&&(Ry(e,T)===se.Must||w.isExtraCoord&&(w.otherDims.itemName!=null||w.otherDims.seriesName!=null))&&(w.type="ordinal")}return wh(a,function(C){return C.name},function(C,x){x>0&&(C.name=C.name+(x-1))}),new R0({source:e,dimensions:a,fullDimensionCount:o,dimensionOmitted:s})}function zM(e,t,r,n){var i=Math.max(e.dimensionsDetectedCount||1,t.length,r.length,n||0);return D(t,function(a){var o;K(a)&&(o=a.dimsDef)&&(i=Math.max(i,o.length))}),i}function HM(e,t,r){if(r||t.hasKey(e)){for(var n=0;t.hasKey(e+n);)n++;e+=n}return t.set(e,!0),e}var VM=(function(){function e(t){this.coordSysDims=[],this.axisMap=nt(),this.categoryAxisMap=nt(),this.coordSysName=t}return e})();function GM(e){var t=e.get("coordinateSystem"),r=new VM(t),n=UM[t];if(n)return n(e,r,r.axisMap,r.categoryAxisMap),r}var UM={cartesian2d:function(e,t,r,n){var i=e.getReferringComponents("xAxis",Ce).models[0],a=e.getReferringComponents("yAxis",Ce).models[0];t.coordSysDims=["x","y"],r.set("x",i),r.set("y",a),Zn(i)&&(n.set("x",i),t.firstCategoryDimIndex=0),Zn(a)&&(n.set("y",a),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=1))},singleAxis:function(e,t,r,n){var i=e.getReferringComponents("singleAxis",Ce).models[0];t.coordSysDims=["single"],r.set("single",i),Zn(i)&&(n.set("single",i),t.firstCategoryDimIndex=0)},polar:function(e,t,r,n){var i=e.getReferringComponents("polar",Ce).models[0],a=i.findAxisModel("radiusAxis"),o=i.findAxisModel("angleAxis");t.coordSysDims=["radius","angle"],r.set("radius",a),r.set("angle",o),Zn(a)&&(n.set("radius",a),t.firstCategoryDimIndex=0),Zn(o)&&(n.set("angle",o),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=1))},geo:function(e,t,r,n){t.coordSysDims=["lng","lat"]},parallel:function(e,t,r,n){var i=e.ecModel,a=i.getComponent("parallel",e.get("parallelIndex")),o=t.coordSysDims=a.dimensions.slice();D(a.parallelAxisIndex,function(s,l){var u=i.getComponent("parallelAxis",s),f=o[l];r.set(f,u),Zn(u)&&(n.set(f,u),t.firstCategoryDimIndex==null&&(t.firstCategoryDimIndex=l))})},matrix:function(e,t,r,n){var i=e.getReferringComponents("matrix",Ce).models[0];t.coordSysDims=["x","y"];var a=i.getDimensionModel("x"),o=i.getDimensionModel("y");r.set("x",a),r.set("y",o),n.set("x",a),n.set("y",o)}};function Zn(e){return e.get("type")==="category"}function WM(e,t,r){r=r||{};var n=r.byIndex,i=r.stackedCoordDimension,a,o,s;YM(t)?a=t:(o=t.schema,a=o.dimensions,s=t.store);var l=!!(e&&e.get("stack")),u,f,h,v,c=!0;function d(S){return S.type!=="ordinal"&&S.type!=="time"}if(D(a,function(S,b){W(S)&&(a[b]=S={name:S}),d(S)||(c=!1)}),D(a,function(S,b){l&&!S.isExtraCoord&&(!n&&!u&&S.ordinalMeta&&(u=S),!f&&d(S)&&(!c||S.coordDim!=="x"&&S.coordDim!=="angle")&&(!i||i===S.coordDim)&&(f=S))}),f&&!n&&!u&&(n=!0),f){h="__\0ecstackresult_"+e.id,v="__\0ecstackedover_"+e.id,u&&(u.createInvertedIndices=!0);var p=f.coordDim,m=f.type,g=0;D(a,function(S){S.coordDim===p&&g++});var y={name:h,coordDim:p,coordDimIndex:g,type:m,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length},_={name:v,coordDim:v,coordDimIndex:g+1,type:m,isExtraCoord:!0,isCalculationCoord:!0,storeDimIndex:a.length+1};o?(s&&(y.storeDimIndex=s.ensureCalculationDimension(v,m),_.storeDimIndex=s.ensureCalculationDimension(h,m)),o.appendCalculationDimension(y),o.appendCalculationDimension(_)):(a.push(y),a.push(_))}return{stackedDimension:f&&f.name,stackedByDimension:u&&u.name,isStackedByIndex:n,stackedOverDimension:v,stackResultDimension:h}}function YM(e){return!k0(e.schema)}function Aa(e,t){return!!t&&t===e.getCalculationInfo("stackedDimension")}function XM(e,t){return Aa(e,t)?e.getCalculationInfo("stackResultDimension"):t}function $M(e,t){var r=e.get("coordinateSystem"),n=iv.get(r),i;return t&&t.coordSysDims&&(i=rt(t.coordSysDims,function(a){var o={name:a},s=t.axisMap.get(a);if(s){var l=s.get("type");o.type=LM(l)}return o})),i||(i=n&&(n.getDimensionsInfo?n.getDimensionsInfo():n.dimensions.slice())||["x","y"]),i}function ZM(e,t,r){var n,i;return r&&D(e,function(a,o){var s=a.coordDim,l=r.categoryAxisMap.get(s);l&&(n==null&&(n=o),a.ordinalMeta=l.getOrdinalMeta(),t&&(a.createInvertedIndices=!0)),a.otherDims.itemName!=null&&(i=!0)}),!i&&n!=null&&(e[n].otherDims.itemName=0),n}function qM(e,t,r){r=r||{};var n=t.getSourceManager(),i,a=!1;i=n.getSource(),a=i.sourceFormat===ve;var o=GM(t),s=$M(t,o),l=r.useEncodeDefaulter,u=ot(l)?l:l?Et(Fx,s,t):null,f={coordDimensions:s,generateCoord:r.generateCoord,encodeDefine:t.getEncode(),encodeDefaulter:u,canOmitUnusedDimensions:!a},h=FM(i,f),v=ZM(h.dimensions,r.createInvertedIndices,o),c=a?null:n.getSharedDataStore(h),d=WM(t,{schema:h,store:c}),p=new NM(h,t);p.setCalculationInfo(d);var m=v!=null&&KM(i)?function(g,y,_,S){return S===v?_:this.defaultDimValueGetter(g,y,_,S)}:null;return p.hasItemOption=!1,p.initData(a?i:c,null,m),p}function KM(e){if(e.sourceFormat===ve){var t=QM(e.data||[]);return!H(za(t))}}function QM(e){for(var t=0;t<e.length&&e[t]==null;)t++;return e[t]}var ze=(function(){function e(){}return e.prototype.isBlank=function(){return this._isBlank},e.prototype.setBlank=function(t){this._isBlank=t},e})();js(ze);var JM=0,qf=(function(){function e(t){this.categories=t.categories||[],this._needCollect=t.needCollect,this._deduplication=t.deduplication,this.uid=++JM,this._onCollect=t.onCollect}return e.createByAxisModel=function(t){var r=t.option,n=r.data,i=n&&rt(n,jM);return new e({categories:i,needCollect:!i,deduplication:r.dedplication!==!1})},e.prototype.getOrdinal=function(t){return this._getOrCreateMap().get(t)},e.prototype.parseAndCollect=function(t){var r,n=this._needCollect;if(!W(t)&&!n)return t;if(n&&!this._deduplication)return r=this.categories.length,this.categories[r]=t,this._onCollect&&this._onCollect(t,r),r;var i=this._getOrCreateMap();return r=i.get(t),r==null&&(n?(r=this.categories.length,this.categories[r]=t,i.set(t,r),this._onCollect&&this._onCollect(t,r)):r=NaN),r},e.prototype._getOrCreateMap=function(){return this._map||(this._map=nt(this.categories))},e})();function jM(e){return K(e)&&e.value!=null?e.value:e+""}var Me=0,La=1,tA={needTransform:1,normalize:1,scale:1,transformIn:1,transformOut:1,contain:1,getExtent:1,getExtentUnsafe:1,setExtent:1,setExtent2:1,getFilter:1,sanitize:1,getDefaultStartValue:1,freeze:1},eA=xt(tA),Bs=2,N0=3;function _v(e,t,r){var n;return e=e||{},nA(e,r),{brk:n,mapper:e}}function F0(e,t){D(eA,function(r){e[r]=t[r]})}function z0(e,t){e.freeze=$t}function Ia(e){return e.getExtentUnsafe(Me,Bs)}function Ns(e,t){return e.getExtentUnsafe(La,t)||e.getExtentUnsafe(Me,t)}function rA(e){var t=Ns(e,N0);return t[1]-t[0]}function gl(e){var t=e.getExtentUnsafe(Me,N0);return t[1]-t[0]}function nA(e,t){var r=e||{},n=[];return r._extents=n,n[Me]=t?t.slice():Te(),N(r,iA),r}var iA={needTransform:function(){return!1},normalize:function(e){var t=this._extents[La]||this._extents[Me];return t[1]===t[0]?.5:(e-t[0])/(t[1]-t[0])},scale:function(e){var t=this._extents[La]||this._extents[Me];return e*(t[1]-t[0])+t[0]},transformIn:function(e){return e},transformOut:function(e){return e},contain:function(e){var t=Ns(this,null);return e>=t[0]&&e<=t[1]},getExtent:function(){return this._extents[Me].slice()},getExtentUnsafe:function(e){return this._extents[e]},setExtent:function(e,t){xp(this._extents,Me,e,t)},setExtent2:function(e,t,r){var n=this._extents;n[e]||(n[e]=n[Me].slice()),xp(n,e,t,r)},freeze:function(){}};function xp(e,t,r,n){gi(r,n)&&(e[t][0]=r,e[t][1]=n)}function H0(e){return Fs(e)||Si(e)}function Fs(e){return e.type==="interval"}function Sv(e){return e.type==="time"}function Si(e){return e.type==="log"}function lr(e){return e.type==="ordinal"}function aA(e){var t=_h(e),r=Ci(10,t),n=gr(e/r);return n?n===2?n=3:n===3?n=5:n*=2:n=1,ft(n*r,-t)}function Pn(e){return Pr(e)+2}function ko(e,t){return ma(e)/ma(t)}function Eu(e,t,r){var n=r&&r.lookup;if(n){for(var i=0;i<n.from.length;i++)if(e===n.from[i])return n.to[i]}return Ci(t,e)}function V0(e,t,r){var n=e.slice();if(n[0]===n[1]){var i=r&&r.ctnShp;if(n[0]!==0){var a=Nt(n[0]);t[1]||(n[1]+=a/2),n[0]-=a/2}else i&&(n[0]=-1),n[1]=1}return(!mr(n[0])||!mr(n[1]))&&(n[0]=0,n[1]=1),n[1]<n[0]&&n.reverse(),n}function oA(e,t){return[e[0]!==t[0],e[1]!==t[1]]}function bv(e,t){return e=e||t,gr(mt(e,1))}function G0(e,t,r){var n=Ia(e),i=n[0],a=e.count(),o=Math.max((t||0)+1,1);i!==0&&o>1&&a/o>2&&(i=Math.round(Math.ceil(i/o)*o)),i!==n[0]&&l(n[0],!0,!0);for(var s=i;s<=n[1];s+=o)l(s,!1,s===n[0]||s===n[1]);s-o!==n[1]&&l(n[1],!0,!0);function l(u,f,h){r({value:u,offInterval:f},h)}}var U0=(function(e){V(t,e);function t(r){var n=e.call(this)||this;n.type="ordinal",n.parse=t.parse,F0(n,t.decoratedMethods);var i=r.ordinalMeta;i||(i=new qf({})),H(i)&&(i=new qf({categories:rt(i,function(o){return K(o)?o.value:o})})),n._ordinalMeta=i;var a=_v(null,null,r.extent||[0,i.categories.length-1]);return n._mapper=a.mapper,z0(n),n}return t.parse=function(r){return r==null?r=NaN:W(r)?(r=this._ordinalMeta.getOrdinal(r),r==null&&(r=NaN)):r=gr(r),r},t.prototype.getTicks=function(){var r=[];return G0(this,0,function(n){r.push(n)}),r},t.prototype.getMinorTicks=function(r){},t.prototype.setSortInfo=function(r){if(r==null){this._ordinalNumbersByTick=this._ticksByOrdinalNumber=null;return}for(var n=r.ordinalNumbers,i=this._ordinalNumbersByTick=[],a=this._ticksByOrdinalNumber=[],o=0,s=this._ordinalMeta.categories.length,l=he(s,n.length);o<l;++o){var u=i[o]=n[o];a[u]=o}for(var f=0;o<s;++o){for(;a[f]!=null;)f++;i[o]=f,a[f]=o}},t.prototype._getTickNumber=function(r){var n=this._ticksByOrdinalNumber;return n&&r>=0&&r<n.length?n[r]:r},t.prototype.getRawOrdinalNumber=function(r){var n=this._ordinalNumbersByTick;return n&&r>=0&&r<n.length?n[r]:r},t.prototype.getLabel=function(r){if(!this.isBlank()){var n=this.getRawOrdinalNumber(r.value),i=this._ordinalMeta.categories[n];return i==null?"":i+""}},t.prototype.count=function(){var r=Ia(this._mapper);return r[1]-r[0]+1},t.prototype.getOrdinalMeta=function(){return this._ordinalMeta},t.type="ordinal",t.decoratedMethods={needTransform:function(){return this._mapper.needTransform()},contain:function(r){return this._mapper.contain(this._getTickNumber(r))&&r>=0&&r<this._ordinalMeta.categories.length},normalize:function(r){return this._mapper.normalize(this._getTickNumber(r))},scale:function(r){return this.getRawOrdinalNumber(gr(this._mapper.scale(r)))},transformIn:function(r,n){return this._mapper.transformIn(this._getTickNumber(r),n)},transformOut:function(r,n){return this.getRawOrdinalNumber(this._mapper.transformOut(r,n))},getExtent:function(){return this._mapper.getExtent()},getExtentUnsafe:function(r,n){return this._mapper.getExtentUnsafe(r,n)},setExtent:function(r,n){return this._mapper.setExtent(r,n)},setExtent2:function(r,n,i){return this._mapper.setExtent2(r,n,i)}},t})(ze);ze.registerClass(U0);function Tv(e,t,r,n){for(var i=e.getTicks({expandToNicedExtent:!0}),a=[],o=e.getExtent(),s=1;s<i.length;s++){var l=i[s],u=i[s-1];if(!(u.break||l.break)){for(var f=0,h=[],v=l.value-u.value,c=v/t,d=Pn(c);f<t-1;){var p=ft(u.value+(f+1)*c,d);p>o[0]&&p<o[1]&&h.push(p),f++}var m=hl();m&&m.pruneTicksByBreak("auto",h,r,function(g){return g},n,o),a.push(h)}}return a}var hi=(function(e){V(t,e);function t(r){var n=e.call(this)||this;n.type="interval",n.parse=t.parse,r=r||{};var i=py(n,r),a=_v(n,i,null);return n.brk=a.brk,n._cfg={interval:0,intervalPrecision:2,intervalCount:void 0,niceExtent:void 0},n}return t.parse=function(r){return r==null||r===""?NaN:Number(r)},t.prototype.getConfig=function(){return ut(this._cfg)},t.prototype.setConfig=function(r){var n=Ia(this);this._cfg=r=ut(r),r.niceExtent==null&&(r.niceExtent=n.slice()),r.intervalPrecision==null&&(r.intervalPrecision=Pn(r.interval))},t.prototype.getTicks=function(r){r=r||{};var n=this._cfg,i=n.interval,a=Ia(this),o=n.niceExtent,s=n.intervalPrecision,l=hl(),u=this.brk,f=l,h=[];if(!i)return h;r.breakTicks;var v=3e3;a[0]<o[0]&&h.push({value:r.expandToNicedExtent?ft(o[0]-i,s):a[0]});for(var c=function(_,S){return gr((S-_)/i)},d=n.intervalCount,p=o[0],m=0;;m++){if(d==null){if(p>o[1]||!isFinite(p)||!isFinite(o[1]))break}else{if(m>d)break;p=he(p,o[1]),m===d&&(p=o[1])}if(h.push({value:p}),p=ft(p+i,s),u){var g=u.calcNiceTickMultiple(p,c);g>=0&&(p=ft(p+g*i,s))}if(h.length>0&&p===h[h.length-1].value)break;if(h.length>v)return[]}var y=h.length?h[h.length-1].value:o[1];return a[1]>y&&h.push({value:r.expandToNicedExtent?ft(y+i,s):a[1]}),h},t.prototype.getMinorTicks=function(r){return Tv(this,r,qh(this),this._cfg.interval)},t.prototype.getLabel=function(r,n){if(r==null)return"";var i=n&&n.precision;i==null?i=Pr(r.value)||0:i==="auto"&&(i=this._cfg.intervalPrecision);var a=ft(r.value,i,!0);return wy(a)},t.type="interval",t})(ze);ze.registerClass(hi);var sA=function(e,t,r,n){for(;r<n;){var i=r+n>>>1;e[i][1]<t?r=i+1:n=i}return r},W0=(function(e){V(t,e);function t(r){var n=e.call(this)||this;n.type="time",n.parse=t.parse,n._locale=r.locale,n._useUTC=r.useUTC,n._interval=0;var i=py(n,r),a=_v(n,i,null);return n.brk=a.brk,n}return t.prototype.getLabel=function(r){return vl(r.value,pd[_x(ua(this._minLevelUnit))]||pd.second,this._useUTC,this._locale)},t.prototype.getFormattedLabel=function(r,n,i){return Sx(r,n,i,this._locale,this._useUTC)},t.prototype.getTicks=function(r){var n=this._interval,i=Ia(this),a=this.brk,o=[];if(!n)return o;var s=this._useUTC;o=pA(this._minLevelUnit,this._approxInterval,s,i,gl(this),a);var l=Mn.length-1,u=0;return D(o,function(f){f.time&&(l=Math.min(l,vt(Mn,f.time.upperTimeUnit)),u=Math.max(u,f.time.level))}),o},t.prototype.getMinorTicks=function(r){return Tv(this,r,qh(this),this._interval)},t.prototype.setTimeInterval=function(r){this._interval=r.interval,this._approxInterval=r.approxInterval,this._minLevelUnit=r.minLevelUnit},t.parse=function(r){return Ct(r)?Math.round(r):+Di(r)},t.type="time",t})(ze),Oo=[["second",Kh],["minute",Qh],["hour",la],["quarter-day",la*6],["half-day",la*12],["day",De*1.2],["half-week",De*3.5],["week",De*7],["month",De*31],["quarter",De*95],["half-year",dd/2],["year",dd]];function lA(e,t,r,n){return Pf(new Date(t),e,n).getTime()===Pf(new Date(r),e,n).getTime()}function uA(e,t){return e/=De,e>16?16:e>7.5?7:e>3.5?4:e>1.5?2:1}function fA(e){var t=30*De;return e/=t,e>6?6:e>3?3:e>2?2:1}function hA(e){return e/=la,e>12?12:e>6?6:e>3.5?4:e>2?2:1}function Cp(e,t){return e/=t?Qh:Kh,e>30?30:e>20?20:e>15?15:e>10?10:e>5?5:e>2?2:1}function vA(e){return mt(Sh(e,!0),1)}function cA(e,t,r){var n=Math.max(0,vt(Mn,t)-1);return Pf(new Date(e),Mn[n],r).getTime()}function dA(e,t){var r=new Date(0);r[e](1);var n=r.getTime();r[e](1+t);var i=r.getTime()-n;return function(a,o){return Math.max(0,Math.round((o-a)/i))}}function pA(e,t,r,n,i,a){var o=3e3,s=px,l=0;function u(E,F,G,U,tt,Z,at){for(var q=dA(tt,E),z=F,lt=new Date(z);z<G&&z<=n[1]&&(at.push({value:z}),!(l++>o));)if(lt[tt](lt[U]()+E),z=lt.getTime(),a){var k=a.calcNiceTickMultiple(z,q);k>0&&(lt[tt](lt[U]()+k*E),z=lt.getTime())}at.push({value:z,notAdd:z>n[1]})}function f(E,F,G){var U=[],tt=!F.length;if(!lA(ua(E),n[0],n[1],r)){tt&&(F=[{value:cA(n[0],E,r)},{value:n[1]}]);for(var Z=0;Z<F.length-1;Z++){var at=F[Z].value,q=F[Z+1].value;if(at!==q){var z=void 0,lt=void 0,k=void 0,B=!1;switch(E){case"year":z=Math.max(1,Math.round(t/De/365)),lt=gy(r),k=bx(r);break;case"half-year":case"quarter":case"month":z=fA(t),lt=Jh(r),k=my(r);break;case"week":case"half-week":case"day":z=uA(t),lt=jh(r),k=yy(r),B=!0;break;case"half-day":case"quarter-day":case"hour":z=hA(t),lt=tv(r),k=_y(r);break;case"minute":z=Cp(t,!0),lt=ev(r),k=Sy(r);break;case"second":z=Cp(t,!1),lt=rv(r),k=by(r);break;case"millisecond":z=vA(t),lt=nv(r),k=Ty(r);break}q>=n[0]&&at<=n[1]&&u(z,at,q,lt,k,B,U),E==="year"&&G.length>1&&Z===0&&G.unshift({value:G[0].value-z})}}for(var Z=0;Z<U.length;Z++)G.push(U[Z])}}for(var h=[],v=[],c=0,d=0,p=0;p<s.length;++p){var m=ua(s[p]);if(yx(s[p])){f(s[p],h[h.length-1]||[],v);var g=s[p+1]?ua(s[p+1]):null;if(m!==g){if(v.length){d=c,v.sort(function(E,F){return E.value-F.value});for(var y=[],_=0;_<v.length;++_){var S=v[_].value;(_===0||v[_-1].value!==S)&&(y.push(v[_]),S>=n[0]&&S<=n[1]&&c++)}var b=i/t;if(c>b*1.5&&d>b/1.5||(h.push(y),c>b||e===s[p]))break}v=[]}}}for(var T=Xt(rt(h,function(E){return Xt(E,function(F){return F.value>=n[0]&&F.value<=n[1]&&!F.notAdd})}),function(E){return E.length>0}),w=T.length-1,M=[],p=0;p<T.length;++p)for(var C=T[p],x=0;x<C.length;++x){var A=ts(C[x].value,r);M.push({value:C[x].value,time:{level:w-p,upperTimeUnit:A,lowerTimeUnit:A}})}wh(M,bb,null),M.sort(function(E,F){return E.value-F.value});var I=M[0],L=M[M.length-1],P=ts(n[0],r),R=ts(n[1],r);return(!I||I.value>n[0])&&M.unshift({value:n[0],time:{level:0,upperTimeUnit:P,lowerTimeUnit:P},notNice:!0}),(!L||L.value<n[1])&&M.push({value:n[1],time:{level:0,upperTimeUnit:R,lowerTimeUnit:R},notNice:!0}),M}var gA=function(e,t){var r=e.getExtent();if(r[0]===r[1]&&(r[0]-=De,r[1]+=De),r[1]===-1/0&&r[0]===1/0){var n=new Date;r[1]=+new Date(n.getFullYear(),n.getMonth(),n.getDate()),r[0]=r[1]-De}e.setExtent(r[0],r[1]);var i=bv(t.splitNumber,10),a=gl(e)/i,o=t.minInterval,s=t.maxInterval;o!=null&&a<o&&(a=o),s!=null&&a>s&&(a=s);var l=Oo.length,u=Math.min(sA(Oo,a,0,l),l-1),f=Oo[u][1],h=Oo[Math.max(u-1,0)][0];e.setTimeInterval({approxInterval:a,interval:f,minLevelUnit:h})};ze.registerClass(W0);var Bo=0,No=1,Y0=(function(e){V(t,e);function t(r){var n=e.call(this)||this;n.type="log",n.parse=hi.parse,n.base=r.logBase||10;var i=[],a=[];n._lookup={from:i,to:a},i[Bo]=i[No]=a[Bo]=a[No]=NaN,F0(n,t.mapperMethods),r.breakOption;var o={};return n.powStub=new hi({breakParsed:o.original}),n.intervalStub=new hi({breakParsed:o.transformed}),z0(n,n.intervalStub),n}return t.prototype.getTicks=function(r){var n=this.base,i=this.powStub,a=this.intervalStub,o=a.getExtent(),s=i.getExtent(),l={lookup:{from:o,to:s}};return rt(a.getTicks(r||{}),function(u){var f=u.value,h=Eu(f,n,l),v;return{value:h,break:v}},this)},t.prototype.getMinorTicks=function(r){return Tv(this,r,qh(this.powStub),this.intervalStub.getConfig().interval)},t.prototype.getLabel=function(r,n){return this.intervalStub.getLabel(r,n)},t.type="log",t.mapperMethods={needTransform:function(){return!0},normalize:function(r){return this.intervalStub.normalize(ko(r,this.base))},scale:function(r){return Eu(this.intervalStub.scale(r),this.base,null)},transformIn:function(r,n){return r=ko(r,this.base),n&&n.depth===Bs?r:this.intervalStub.transformIn(r,n)},transformOut:function(r,n){var i=n?n.depth:null;return Dp.depth=i,Mp.lookup=this._lookup,Eu(i===Bs?r:this.intervalStub.transformOut(r,Dp),this.base,Mp)},contain:function(r){return this.powStub.contain(r)},setExtent:function(r,n){this.setExtent2(Me,r,n)},setExtent2:function(r,n,i){if(!(!gi(n,i)||n<=0||i<=0)){var a=Ap,o=Ap;if(r===Me){var s=this._lookup;a=s.to,o=s.from}this.powStub.setExtent2(r,a[Bo]=n,a[No]=i);var l=this.base;this.intervalStub.setExtent2(r,o[Bo]=ko(n,l),o[No]=ko(i,l))}},getFilter:function(){return{g:0}},sanitize:function(r,n){return gi(n[0],n[1])&&rr(r)&&r<=0&&(r=n[0]),r},getDefaultStartValue:function(){return 1},getExtent:function(){return this.powStub.getExtent()},getExtentUnsafe:function(r,n){return n===null?this.powStub.getExtentUnsafe(r,null):this.intervalStub.getExtentUnsafe(r,n)}},t})(ze);ze.registerClass(Y0);var Dp={},Mp={},Ap=[],X0={value:1,category:1,time:1,log:1},$0=bt();function mA(e){var t=e.get("type");return(t==null||!fe(X0,t)&&!ze.getClass(t))&&(t="value"),t}function yA(e,t,r){var n;switch(t){case"category":return new U0({ordinalMeta:e.getOrdinalMeta?e.getOrdinalMeta():e.getCategories(),extent:Te()});case"time":return new W0({locale:e.ecModel.getLocaleModel(),useUTC:e.ecModel.get("useUTC"),breakOption:n});case"log":return new Y0({logBase:e.get("logBase"),breakOption:n});case"value":return new hi({breakOption:n});default:return new(ze.getClass(t)||hi)({})}}function _A(e,t,r){var n=e.getExtentUnsafe(Me,null),i=n[0],a=n[1];return gi(i,a)?i===t||a===t?bA:i<t&&a>t?SA:Kf:Kf}var SA=1,bA=2,Kf=3;function TA(e){$0(e).noOnMyZero=!0}function wA(e){return $0(e).noOnMyZero}function ml(e){var t=e.getLabelModel().get("formatter");if(e.type==="time"){var r=gx(t);return function(i,a){return e.scale.getFormattedLabel(i,a,r)}}else{if(W(t))return function(i){var a=e.scale.getLabel(i),o=t.replace("{value}",a??"");return o};if(ot(t)){if(e.type==="category")return function(i,a){return t(zs(e,i),i.value-e.scale.getExtent()[0],null)};var n=hl();return function(i,a){var o=null;return n&&(o=n.makeAxisLabelFormatterParamBreak(o,i.break)),t(zs(e,i),a,o)}}else return function(i){return e.scale.getLabel(i)}}}function zs(e,t){var r=e.scale;return lr(r)?r.getLabel(t):t.value}function wv(e){var t=e.get("interval");return t??"auto"}function xA(e){return e.type==="category"&&wv(e.getLabelModel())===0}function CA(e,t){var r={};return D(e.mapDimensionsAll(t),function(n){r[XM(e,n)]=!0}),xt(r)}function bi(e){return e==="middle"||e==="center"}function Pa(e){return e.getShallow("show")}function DA(e,t,r){var n=e.get("breaks",!0);n==null}function Z0(e,t,r,n,i,a){var o=Si(e),s=o?e.intervalStub:e;if(s.setExtent(n[0],n[1]),o){var l=e.powStub,u={depth:Bs},f=e.transformOut(n[0],u),h=e.transformOut(n[1],u),v=oA(r,n);t[0]&&!v[0]&&(f=i[0]),t[1]&&!v[1]&&(h=i[1]),l.setExtent(f,h)}s.setConfig(a)}function Xa(e,t){return lr(e)?e.getRawOrdinalNumber(t.value):t.value}function q0(e,t){return lr(e)&&!!t.get("boundaryGap")}var MA=(function(){function e(){}return e.prototype.needIncludeZero=function(){return!this.option.scale},e.prototype.getCoordSysModel=function(){},e})(),Lp="|&",$a=bt(),AA=-2;bt();function LA(e,t){var r=e.model,n=$a(Ya(r.ecModel)).keyed,i=n&&n.get(t);return i&&i.get(r.uid)}function IA(e,t){return K0(LA(e,t))}function PA(e,t){var r=[];return EA(e.model.ecModel,function(n){for(var i=0;i<t.length;i++)t[i]&&n.serByIdx[t[i].seriesIndex]&&r.push(K0(n))}),r}function EA(e,t){var r=$a(Ya(e)).keyed;r&&r.each(function(n,i){n.each(function(a,o){t(a,i,o)})})}function K0(e){return{liPosMinGap:e?e.liPosMinGap:void 0}}function RA(e,t){var r=e.model.ecModel,n=$a(Ya(r)).axSer;n&&kA(r,n.get(e.model.uid),t)}function kA(e,t,r){if(t)for(var n=0;n<t.length;n++){var i=t[n];e.isSeriesFiltered(i)||r(i)}}function Q0(e,t){var r=e.model,n=$a(Ya(r.ecModel)).keys;n&&D(n.get(r.uid),function(i){t(i)})}function Ip(e,t,r){if(e){var n=t.ecModel,i=$a(Ya(n)),a=e.model.uid,o=i.axSer||(i.axSer=nt()),s=o.get(a)||o.set(a,[]);s.push(t);var l=t.subType,u=t.getBaseAxis()===e,f=Ep.get(Pp(l,u,r))||Ep.get(Pp(l,u,null));if(f){var h=i.keyed||(i.keyed=nt()),v=i.keys||(i.keys=nt()),c=f.key,d=h.get(c)||h.set(c,nt()),p=d.get(a);p||(p=d.set(a,{axis:e,sers:[],serByIdx:[]}),p.metrics=f.getMetrics(e),(v.get(a)||v.set(a,[])).push(c)),p.sers.push(t),p.serByIdx[t.seriesIndex]=t}}}function Pp(e,t,r){return e+Lp+j(t,!0)+Lp+(r||"")}var Ep=nt(),OA=bt(),BA=1,NA=3,J0=(function(){function e(t,r,n,i,a){var o=lr(t),s=o?r.getCategories().length:null,l;if(o){var u=r.getCategories(!0);l=u&&!u.length}var f=n.slice();(Fs(t)||Si(t)||Sv(t))&&(ym(f,Wi(t,r.get("dataMin",!0))),_m(f,Wi(t,r.get("dataMax",!0)))),_b(f)||(f[0]=f[1]=NaN);var h=[],v=[!1,!1],c=r.get("min",!0);c==="dataMin"?(h[0]=f[0],v[0]=!0):(h[0]=Wi(t,ot(c)?c({min:f[0],max:f[1]}):c),v[0]=h[0]!=null);var d=r.get("max",!0);d==="dataMax"?(h[1]=f[1],v[1]=!0):(h[1]=Wi(t,ot(d)?d({min:f[0],max:f[1]}):d),v[1]=h[1]!=null);var p=FA(t,r),m=o?null:f[1]-f[0]||Math.abs(f[0]);h[0]==null&&(h[0]=o?l?f[0]:s?0:NaN:f[0]-p[0]*m),h[1]==null&&(h[1]=o?l?f[1]:s?s-1:NaN:f[1]+p[1]*m),!mr(h[0])&&(h[0]=NaN),!mr(h[1])&&(h[1]=NaN);var g=l||ga(h[0])||ga(h[1])||o&&!s,y=Fs(t),_=y&&r.needIncludeZero&&r.needIncludeZero();_&&(h[0]>0&&h[1]>0&&!v[0]&&(h[0]=0),h[0]<0&&h[1]<0&&!v[1]&&(h[1]=0));var S=!1;h[0]>h[1]&&(h.reverse(),S=!0);var b=Wi(t,r.get("startValue",!0)),T=b!=null;!rr(b)&&i&&(b=t.getDefaultStartValue?t.getDefaultStartValue():0),rr(b)&&(T||!y||_)&&(b<h[0]&&!v[0]?(h[0]=b,v[0]=!0):b>h[1]&&!v[1]&&(h[1]=b,v[1]=!0));var w=this._i={scale:t,dataMM:f,noZoomEffMM:h,zoomMM:[],fixMM:v,zoomFixMM:[!1,!1],startValue:b,isBlank:g,incl0:_,tggAxInv:S,ctnShp:a};Rp(w,h)}return e.prototype.makeNoZoom=function(){return this._i.noZoomEffMM.slice()},e.prototype.makeFinal=function(){var t=this._i,r=t.zoomMM,n=t.noZoomEffMM,i=t.zoomFixMM,a=t.fixMM,o={fixMM:a,zoomFixMM:i,isBlank:t.isBlank,incl0:t.incl0,tggAxInv:t.tggAxInv,ctnShp:t.ctnShp,effMM:n.slice()},s=o.effMM;return r[0]!=null&&(s[0]=r[0],a[0]=i[0]=!0),r[1]!=null&&(s[1]=r[1],a[1]=i[1]=!0),Rp(t,s),o},e.prototype.makeRenderInfo=function(){return{startValue:this._i.startValue}},e.prototype.setZoomMM=function(t,r){this._i.zoomMM[t]=r},e})();function Rp(e,t){var r=e.scale,n=e.dataMM;r.sanitize&&(t[0]=r.sanitize(t[0],n),t[1]=r.sanitize(t[1],n),Sb(t))}function Wi(e,t){return t==null?null:ga(t)?NaN:e.parse(t)}function FA(e,t){var r;if(lr(e))r=[0,0];else{var n=t.get("boundaryGap");typeof n=="boolean"&&(n=null),r=H(n)?n:[n,n]}return[kp(r[0]),kp(r[1])]}function kp(e){return di(typeof e=="boolean"?0:e,1)||0}function j0(e){var t=OA(e.scale);return t.extent||(t.extent=Te()),t}function zA(e,t){j0(e).dimIdxInCoord=t.get(e.dim)}function HA(e,t){var r=e.scale,n=e.model,i=e.dim;r.rawExtentInfo||VA(r,e,i,n,t)}function VA(e,t,r,n,i){var a=j0(t),o=a.extent,s=!1;RA(t,function(f){if(f.boxCoordinateSystem){var h=Dy(f).coord,v=a.dimIdxInCoord;if(v>=0){if(H(h)){var c=h[v];c!=null&&!H(c)&&gf(o,e.parse(c))}}}else if(f.coordinateSystem){var d=f.getData();if(d){var p=e.getFilter?e.getFilter():null;D(CA(d,r),function(m){yb(o,d.getApproximateExtent(m,p))})}f.__requireStartValue&&f.__requireStartValue(t)&&(s=!0)}});var l=UA(e,t,n),u=new J0(e,n,o,s,l);t_(e,u,i),a.extent=null}function GA(e,t){var r=e.scale;t_(r,new J0(r,e.model,t,!1,!1),NA)}function t_(e,t,r){e.rawExtentInfo=t,t.from=r}var e_=nt();function r_(e,t,r,n,i){e.rawExtentInfo||GA({scale:e,model:t},Te());var a=e.rawExtentInfo.makeFinal(),o=a.effMM;return e.setExtent(o[0],o[1]),e.setBlank(a.isBlank),n&&a.tggAxInv&&r&&!r.get("legacyMinMaxDontInverseAxis")&&(n.inverse=!n.inverse),a}function UA(e,t,r){var n=q0(e,r),i=r.get("containShape",!0);if(i==null&&!n&&(i=!0),!i)return!1;var a=!1;return Q0(t,function(o){a=!!e_.get(o)||a}),a}function WA(e,t,r,n){if(r.ctnShp){var i;if(Q0(e,function(s){var l=e_.get(s);if(l){var u=l(e,n);u&&(i=i||[0,0],ym(i,u[0]),_m(i,u[1]),TA(e))}}),!!i){var a=t.getExtent();if(lr(t))e.onBand||t.setExtent2(La,he(a[0],a[0]+i[0]),mt(a[1],a[1]+i[1]));else{var o=a.slice();r.zoomFixMM[0]||(o[0]=he(o[0],t.transformOut(t.transformIn(o[0],null)+i[0],null))),r.zoomFixMM[1]||(o[1]=mt(o[1],t.transformOut(t.transformIn(o[1],null)+i[1],null))),(o[0]<a[0]||o[1]>a[1])&&t.setExtent2(La,o[0],o[1])}}}}function Op(e,t){var r=Si(e),n=r?e.intervalStub:e,i=t.fixMinMax||[],a=r?e.getExtent():null,o=n.getExtent(),s=V0(o,i,t.rawExtentResult);n.setExtent(s[0],s[1]),s=n.getExtent();var l=r?XA(n,t):YA(n,t),u=l.intervalPrecision,f=l.interval,h=t.userInterval;h!=null&&(l.interval=h,l.intervalPrecision=Pn(h)),i[0]||(s[0]=ft(pi(s[0]/f)*f,u)),i[1]||(s[1]=ft(Fa(s[1]/f)*f,u)),h!=null&&(l.niceExtent=s.slice()),Z0(e,i,o,s,a,l)}function YA(e,t){var r=bv(t.splitNumber,5),n=gl(e),i=t.minInterval,a=t.maxInterval,o=Sh(n/r,!0);i!=null&&o<i&&(o=i),a!=null&&o>a&&(o=a);var s=Pn(o),l=e.getExtent(),u=[ft(Fa(l[0]/o)*o,s),ft(pi(l[1]/o)*o,s)];return{interval:o,intervalPrecision:s,niceExtent:u}}function XA(e,t){var r=bv(t.splitNumber,10),n=e.getExtent(),i=gl(e),a=mt(fm(i),1),o=r/i*a;o<=.5&&(a*=10);var s=Pn(a),l=[ft(Fa(n[0]/a)*a,s),ft(pi(n[1]/a)*a,s)];return{intervalPrecision:s,interval:a,niceExtent:l}}function Bp(e){var t=e.scale,r=e.model,n=r.axis,i=r.ecModel;$A(t,r,n,i)}function $A(e,t,r,n,i){var a=r_(e,t,n,r),o=Fs(e)||Sv(e);ZA(e,{splitNumber:t.get("splitNumber"),fixMinMax:a.fixMM,userInterval:t.get("interval"),minInterval:o?t.get("minInterval"):null,maxInterval:o?t.get("maxInterval"):null,rawExtentResult:a}),r&&n&&WA(r,e,a,n)}function ZA(e,t){qA[e.type](e,t)}var qA={interval:Op,log:Op,time:gA,ordinal:$t},Np=[],KA={registerPreprocessor:I0,registerProcessor:P0,registerPostInit:SM,registerPostUpdate:bM,registerUpdateLifecycle:pv,registerAction:Mi,registerCoordinateSystem:TM,registerLayout:wM,registerVisual:Rn,registerTransform:CM,registerLoading:E0,registerMap:xM,registerImpl:xD,PRIORITY:dM,ComponentModel:pt,ComponentView:ir,SeriesModel:Vr,ChartView:er,registerComponentModel:function(e){pt.registerClass(e)},registerComponentView:function(e){ir.registerClass(e)},registerSeriesModel:function(e){Vr.registerClass(e)},registerChartView:function(e){er.registerClass(e)},registerCustomSeries:function(e,t){},registerSubTypeDefaulter:function(e,t){pt.registerSubTypeDefaulter(e,t)},registerPainter:function(e,t){GS(e,t)}};function Gr(e){if(H(e)){D(e,function(t){Gr(t)});return}vt(Np,e)>=0||(Np.push(e),ot(e)&&(e={install:e}),e.install(KA))}var QA=bt(),ca=bt(),Be={estimate:1,determine:2};function Hs(e){return{out:{noPxChangeTryDetermine:[]},kind:e}}function JA(e,t){var r=e.getLabelModel().get("customValues");if(r){var n=e.scale;return{labels:rt(n_(r,n),function(i,a){return{formattedLabel:ml(e)(i,a),rawLabel:n.getLabel(i),tick:i}})}}return e.type==="category"?tL(e,t):rL(e)}function jA(e,t,r){var n=e.scale,i=e.getTickModel().get("customValues");return i?{ticks:n_(i,n)}:e.type==="category"?eL(e,t):{ticks:n.getTicks(r)}}function n_(e,t){var r=t.getExtent(),n=[];return D(e,function(i){i=t.parse(i),i>=r[0]&&i<=r[1]&&n.push(i)}),wh(n,Tb,null),lm(n),rt(n,function(i){return{value:i}})}function tL(e,t){var r=e.getLabelModel(),n=i_(e,r,t);return!r.get("show")||e.scale.isBlank()?{labels:[]}:n}function i_(e,t,r){var n=iL(e),i=wv(t),a=r.kind===Be.estimate;if(!a){var o=o_(n,i);if(o)return o}var s,l;ot(i)?s=Vs(e,i,!1):(l=i==="auto"?aL(e,r):i,s=Vs(e,l,!1));var u={labels:s,labelCategoryInterval:l};return a?r.out.noPxChangeTryDetermine.push(function(){return Qf(n,i,u),!0}):Qf(n,i,u),u}function eL(e,t){var r=nL(e),n=wv(t),i=o_(r,n);if(i)return i;var a,o;if((!t.get("show")||e.scale.isBlank())&&(a=[]),ot(n))a=Vs(e,n,!0);else if(n==="auto"){var s=i_(e,e.getLabelModel(),Hs(Be.determine));o=s.labelCategoryInterval,a=rt(s.labels,function(l){return l.tick})}else o=n,a=Vs(e,o,!0);return Qf(r,n,{ticks:a,tickCategoryInterval:o})}function rL(e){var t=e.scale.getTicks(),r=ml(e);return{labels:rt(t,function(n,i){return{formattedLabel:r(n,i),rawLabel:e.scale.getLabel(n),tick:n}})}}var nL=a_("axisTick"),iL=a_("axisLabel");function a_(e){return function(r){return ca(r)[e]||(ca(r)[e]={list:[]})}}function o_(e,t){for(var r=0;r<e.list.length;r++)if(e.list[r].key===t)return e.list[r].value}function Qf(e,t,r){return e.list.push({key:t,value:r}),r}function aL(e,t){if(t.kind===Be.estimate){var r=e.calculateCategoryInterval(t);return t.out.noPxChangeTryDetermine.push(function(){return ca(e).autoInterval=r,!0}),r}var n=ca(e).autoInterval;return n??(ca(e).autoInterval=e.calculateCategoryInterval(t))}function oL(e,t){var r=t.kind,n=lL(e),i=ml(e),a=(n.axisRotate-n.labelRotate)/180*Math.PI,o=e.scale,s=o.getExtent(),l=o.count();if(s[1]-s[0]<1)return 0;var u=1,f=40;l>f&&(u=Math.max(1,Math.floor(l/f)));for(var h=s[0],v=e.dataToCoord(h+1)-e.dataToCoord(h),c=Math.abs(v*Math.cos(a)),d=Math.abs(v*Math.sin(a)),p=0,m=0;h<=s[1];h+=u){var g=0,y=0,_=nm(i({value:h}),n.font,"center","top");g=_.width*1.3,y=_.height*1.3,p=Math.max(p,g,7),m=Math.max(m,y,7)}var S=p/c,b=m/d;isNaN(S)&&(S=1/0),isNaN(b)&&(b=1/0);var T=Math.max(0,Math.floor(Math.min(S,b)));if(r===Be.estimate)return t.out.noPxChangeTryDetermine.push(wt(sL,null,e,T,l)),T;var w=s_(e,T,l);return w??T}function sL(e,t,r){return s_(e,t,r)==null}function s_(e,t,r){var n=QA(e.model),i=e.getExtent(),a=n.lastAutoInterval,o=n.lastTickCount;if(a!=null&&o!=null&&Math.abs(a-t)<=1&&Math.abs(o-r)<=1&&a>t&&n.axisExtent0===i[0]&&n.axisExtent1===i[1])return a;n.lastTickCount=r,n.lastAutoInterval=t,n.axisExtent0=i[0],n.axisExtent1=i[1]}function lL(e){var t=e.getLabelModel();return{axisRotate:e.getRotate?e.getRotate():e.isHorizontal&&!e.isHorizontal()?90:0,labelRotate:t.get("rotate")||0,font:t.getFont()}}function Vs(e,t,r){var n=ml(e),i=e.scale,a=[],o=ot(t);return G0(i,o?0:t,function(s,l){var u=i.getLabel(s);if(o){var f=!!t(s.value,u);if(s.offInterval=!f,!f&&!l)return}a.push(r?s:{formattedLabel:n(s),rawLabel:u,tick:s})}),a}var uL=.8;function yl(e,t){t=t||{};var r={w:NaN,w2:NaN},n=e.scale,i=t.fromStat,a=t.min,o=rA(n);rr(o)||(o=NaN);var s=e.getExtent(),l=Nt(s[1]-s[0]);return lr(n)?fL(r,e,o,l):i&&hL(r,e,o,l,i),a!=null&&(r.w=rr(r.w)?mt(a,r.w):a),r}function fL(e,t,r,n){var i=t.onBand,a=r+(i?1:0);a===0&&(a=1),e.w=n/a,!i&&r&&n&&(e.w2=e.w*r/n)}function hL(e,t,r,n,i){var a=!1,o=-1/0;D(i.key?[IA(t,i.key)]:PA(t,i.sers||[]),function(s){var l=s.liPosMinGap;l!=null&&(l>0?(l>o&&(o=l),a=!1):l===AA&&(a=!0))}),rr(r)&&r>0&&rr(o)?(e.w=n/r*o,e.w2=o):a&&(e.w=n*uL,e.w2=e.w*r/n)}var Fp=[0,1],vL=(function(){function e(t,r,n){this.onBand=!1,this.inverse=!1,this.dim=t,this.scale=r,this._extent=n||[0,0]}return e.prototype.contain=function(t){var r=this._extent,n=Math.min(r[0],r[1]),i=Math.max(r[0],r[1]);return t>=n&&t<=i},e.prototype.containData=function(t){return this.scale.contain(this.scale.parse(t))},e.prototype.getExtent=function(){return this._extent.slice()},e.prototype.setExtent=function(t,r){var n=this._extent;n[0]=t,n[1]=r},e.prototype.dataToCoord=function(t,r){var n=this.scale;return t=n.normalize(n.parse(t)),mc(t,Fp,zp(this),r)},e.prototype.coordToData=function(t,r){var n=mc(t,zp(this),Fp,r);return this.scale.scale(n)},e.prototype.pointToData=function(t,r){},e.prototype.getTicksCoords=function(t){t=t||{};var r=t.tickModel||this.getTickModel(),n=jA(this,r,{breakTicks:t.breakTicks,pruneByBreak:t.pruneByBreak}),i=rt(n.ticks,function(s){return{coord:this.dataToCoord(Xa(this.scale,s)),tick:s}},this),a=r.get("alignWithLabel"),o=cL(this,i,a);return rt(i,function(s){return{coord:s.coord,tickValue:s.tick.value,onBand:o}})},e.prototype.getMinorTicksCoords=function(){if(lr(this.scale))return[];var t=this.model.getModel("minorTick"),r=t.get("splitNumber");r>0&&r<100||(r=5);var n=this.scale.getMinorTicks(r),i=rt(n,function(a){return rt(a,function(o){return{coord:this.dataToCoord(o),tickValue:o}},this)},this);return i},e.prototype.getViewLabels=function(t){return t=t||Hs(Be.determine),JA(this,t).labels},e.prototype.getLabelModel=function(){return this.model.getModel("axisLabel")},e.prototype.getTickModel=function(){return this.model.getModel("axisTick")},e.prototype.getBandWidth=function(){return yl(this,{min:1}).w},e.prototype.calculateCategoryInterval=function(t){return t=t||Hs(Be.determine),oL(this,t)},e})();function zp(e){var t=e.getExtent();if(e.onBand){var r=t[1]-t[0],n=r/e.scale.count()/2;t[0]+=n,t[1]-=n}return t}function cL(e,t,r){var n=t.length;if(!e.onBand||r||!n)return!1;var i=yl(e).w;if(!i)return!1;D(t,function(s){s.coord-=i/2});var a=e.scale.getExtent(),o=t[n-1];return o.tick.offInterval&&t.pop(),t.push({coord:o.coord+i,tick:{value:a[1]+1}}),!0}var Hp=["label","labelLine","layoutOption","priority","defaultAttr","marginForce","minMarginForce","marginDefault","suggestIgnore"],dL=1,Gs=2,l_=dL|Gs;function Us(e,t,r){r=r||l_,t?e.dirty|=r:e.dirty&=~r}function u_(e,t){return t=t||l_,e.dirty==null||!!(e.dirty&t)}function Ur(e){if(e)return u_(e)&&pL(e,e.label,e),e}function pL(e,t,r){var n=t.getComputedTransform();e.transform=Wh(e.transform,n);var i=e.localRect=Ta(e.localRect,t.getBoundingRect()),a=t.style,o=a.margin,s=r&&r.marginForce,l=r&&r.minMarginForce,u=r&&r.marginDefault,f=a.__marginType;f==null&&u&&(o=u,f=ni.textMargin);for(var h=0;h<4;h++)Ru[h]=f===ni.minMargin&&l&&l[h]!=null?l[h]:s&&s[h]!=null?s[h]:o?o[h]:0;f===ni.textMargin&&Ms(i,Ru,!1,!1);var v=e.rect=Ta(e.rect,i);return n&&v.applyTransform(n),f===ni.minMargin&&Ms(v,Ru,!1,!1),e.axisAligned=Uh(n),(e.label=e.label||{}).ignore=t.ignore,Us(e,!1),Us(e,!0,Gs),e}var Ru=[0,0,0,0];function gL(e,t,r){return e.transform=Wh(e.transform,r),e.localRect=Ta(e.localRect,t),e.rect=Ta(e.rect,t),r&&e.rect.applyTransform(r),e.axisAligned=Uh(r),e.obb=void 0,(e.label=e.label||{}).ignore=!1,e}function mL(e,t){if(e){e.label.x+=t.x,e.label.y+=t.y,e.label.markRedraw();var r=e.transform;r&&(r[4]+=t.x,r[5]+=t.y);var n=e.rect;n&&(n.x+=t.x,n.y+=t.y);var i=e.obb;i&&i.fromBoundingRect(e.localRect,r)}}function Vp(e,t){for(var r=0;r<Hp.length;r++){var n=Hp[r];e[n]==null&&(e[n]=t[n])}return Ur(e)}function Gp(e){var t=e.obb;return(!t||u_(e,Gs))&&(e.obb=t=t||new Jm,t.fromBoundingRect(e.localRect,e.transform),Us(e,!1,Gs)),t}function yL(e){var t=[];e.sort(function(u,f){return(f.suggestIgnore?1:0)-(u.suggestIgnore?1:0)||f.priority-u.priority});function r(u){if(!u.ignore){var f=u.ensureState("emphasis");f.ignore==null&&(f.ignore=!1)}u.ignore=!0}for(var n=0;n<e.length;n++){var i=Ur(e[n]);if(!i.label.ignore){for(var a=i.label,o=i.labelLine,s=!1,l=0;l<t.length;l++)if(xv(i,t[l],null,{touchThreshold:.05})){s=!0;break}s?(r(a),o&&r(o)):t.push(i)}}}function xv(e,t,r,n){return!e||!t||e.label&&e.label.ignore||t.label&&t.label.ignore||!e.rect.intersect(t.rect,r,n)?!1:e.axisAligned&&t.axisAligned?!0:Gp(e).intersect(Gp(t),r,n)}var _L=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r.hasSymbolVisual=!0,r}return t.prototype.getInitialData=function(r){return qM(null,this,{useEncodeDefaulter:!0})},t.prototype.getLegendIcon=function(r){var n=new Vt,i=_i("line",0,r.itemHeight/2,r.itemWidth,0,r.lineStyle.stroke,!1);n.add(i),i.setStyle(r.lineStyle);var a=this.getData().getVisual("symbol"),o=this.getData().getVisual("symbolRotate"),s=a==="none"?"circle":a,l=r.itemHeight*.8,u=_i(s,(r.itemWidth-l)/2,(r.itemHeight-l)/2,l,l,r.itemStyle.fill);n.add(u),u.setStyle(r.itemStyle);var f=r.iconRotate==="inherit"?o:r.iconRotate||0;return u.rotation=f*Math.PI/180,u.setOrigin([r.itemWidth/2,r.itemHeight/2]),s.indexOf("empty")>-1&&(u.style.stroke=u.style.fill,u.style.fill=J.color.neutral00,u.style.lineWidth=2),n},t.type="series.line",t.dependencies=["grid","polar"],t.defaultOption={z:3,coordinateSystem:"cartesian2d",legendHoverLink:!0,clip:!0,label:{position:"top"},endLabel:{show:!1,valueAnimation:!0,distance:8},lineStyle:{width:2,type:"solid"},emphasis:{scale:!0},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:6,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0,universalTransition:{divideShape:"clone"},triggerLineEvent:!1,triggerEvent:!1},t})(Vr);function f_(e,t){var r=e.mapDimensionsAll("defaultedLabel"),n=r.length;if(n===1){var i=yi(e,t,r[0]);return i!=null?i+"":null}else if(n){for(var a=[],o=0;o<r.length;o++)a.push(yi(e,t,r[o]));return a.join(" ")}}function SL(e,t){var r=e.mapDimensionsAll("defaultedLabel");if(!H(t))return t+"";for(var n=[],i=0;i<r.length;i++){var a=e.getDimensionIndex(r[i]);a>=0&&n.push(t[a])}return n.join(" ")}var Cv=(function(e){V(t,e);function t(r,n,i,a){var o=e.call(this)||this;return o.updateData(r,n,i,a),o}return t.prototype._createSymbol=function(r,n,i,a,o,s){this.removeAll();var l=_i(r,-1,-1,2,2,null,s);l.attr({z2:j(o,100),culling:!0,scaleX:a[0]/2,scaleY:a[1]/2}),l.drift=bL,this._symbolType=r,this.add(l)},t.prototype.stopSymbolAnimation=function(r){this.childAt(0).stopAnimation(null,r)},t.prototype.getSymbolType=function(){return this._symbolType},t.prototype.getSymbolPath=function(){return this.childAt(0)},t.prototype.highlight=function(){xs(this.childAt(0))},t.prototype.downplay=function(){Cs(this.childAt(0))},t.prototype.setZ=function(r,n){var i=this.childAt(0);i.zlevel=r,i.z=n},t.prototype.setDraggable=function(r,n){var i=this.childAt(0);i.draggable=r,i.cursor=!n&&r?"move":i.cursor},t.prototype.updateData=function(r,n,i,a){this.silent=!1;var o=r.getItemVisual(n,"symbol")||"circle",s=r.hostModel,l=t.getSymbolSize(r,n),u=t.getSymbolZ2(r,n),f=o!==this._symbolType,h=a&&a.disableAnimation;if(f){var v=r.getItemVisual(n,"symbolKeepAspect");this._createSymbol(o,r,n,l,u,v)}else{var c=this.childAt(0);c.silent=!1;var d={scaleX:l[0]/2,scaleY:l[1]/2};h?c.attr(d):zr(c,d,s,n),Mw(c)}if(this._updateCommon(r,n,l,i,a),f){var c=this.childAt(0);if(!h){var d={scaleX:this._sizeX,scaleY:this._sizeY,style:{opacity:c.style.opacity}};c.scaleX=c.scaleY=0,c.style.opacity=0,Ua(c,d,s,n)}}h&&this.childAt(0).stopAnimation("leave")},t.prototype._updateCommon=function(r,n,i,a,o){var s=this.childAt(0),l=r.hostModel,u,f,h,v,c,d,p,m,g;if(a&&(u=a.emphasisItemStyle,f=a.blurItemStyle,h=a.selectItemStyle,v=a.focus,c=a.blurScope,p=a.labelStatesModels,m=a.hoverScale,g=a.cursorStyle,d=a.emphasisDisabled),!a||r.hasItemOption){var y=a&&a.itemModel?a.itemModel:r.getItemModel(n),_=y.getModel("emphasis");u=_.getModel("itemStyle").getItemStyle(),h=y.getModel(["select","itemStyle"]).getItemStyle(),f=y.getModel(["blur","itemStyle"]).getItemStyle(),v=_.get("focus"),c=_.get("blurScope"),d=_.get("disabled"),p=Xh(y),m=_.getShallow("scale"),g=y.getShallow("cursor")}var S=r.getItemVisual(n,"symbolRotate");s.attr("rotation",(S||0)*Math.PI/180||0);var b=f0(r.getItemVisual(n,"symbolOffset"),i);b&&(s.x=b[0],s.y=b[1]),g&&s.attr("cursor",g);var T=r.getItemVisual(n,"style"),w=T.fill;if(s instanceof Wr){var M=s.style;s.useStyle(N({image:M.image,x:M.x,y:M.y,width:M.width,height:M.height},T))}else s.__isEmptyBrush?s.useStyle(N({},T)):s.useStyle(T),s.style.decal=null,s.setColor(w,o&&o.symbolInnerColor),s.style.strokeNoScale=!0;var C=r.getItemVisual(n,"liftZ"),x=this._z2;C!=null?x==null&&(this._z2=s.z2,s.z2+=C):x!=null&&(s.z2=x,this._z2=null);var A=o&&o.useNameLabel;Yh(s,p,{labelFetcher:l,labelDataIndex:n,defaultText:I,inheritColor:w,defaultOpacity:T.opacity});function I(R){return A?r.getName(R):f_(r,R)}this._sizeX=i[0]/2,this._sizeY=i[1]/2;var L=s.ensureState("emphasis");L.style=u,s.ensureState("select").style=h,s.ensureState("blur").style=f;var P=m==null||m===!0?Math.max(1.1,3/this._sizeY):isFinite(m)&&m>0?+m:1;L.scaleX=this._sizeX*P,L.scaleY=this._sizeY*P,this.setSymbolScale(1),Cf(this,v,c,d)},t.prototype.setSymbolScale=function(r){this.scaleX=this.scaleY=r},t.prototype.fadeOut=function(r,n,i){var a=this.childAt(0),o=gt(this).dataIndex,s=i&&i.animation;if(this.silent=a.silent=!0,i&&i.fadeLabel){var l=a.getTextContent();l&&Ds(l,{style:{opacity:0}},n,{dataIndex:o,removeOpt:s,cb:function(){a.removeTextContent()}})}else a.removeTextContent();Ds(a,{style:{opacity:0},scaleX:0,scaleY:0},n,{dataIndex:o,cb:r,removeOpt:s})},t.getSymbolSize=function(r,n){return zD(r.getItemVisual(n,"symbolSize"))},t.getSymbolZ2=function(r,n){return r.getItemVisual(n,"z2")},t})(Vt);function bL(e,t){this.parent.drift(e,t)}function Fo(e,t,r,n){return t&&!isNaN(t[0])&&!isNaN(t[1])&&!(n&&n.isIgnore&&n.isIgnore(r))&&!(n&&n.clipShape&&!n.clipShape.contain(t[0],t[1]))&&e.getItemVisual(r,"symbol")!=="none"}function Up(e){return e!=null&&!K(e)&&(e={isIgnore:e}),e||{}}function Wp(e){var t=e.hostModel,r=t.getModel("emphasis");return{emphasisItemStyle:r.getModel("itemStyle").getItemStyle(),blurItemStyle:t.getModel(["blur","itemStyle"]).getItemStyle(),selectItemStyle:t.getModel(["select","itemStyle"]).getItemStyle(),focus:r.get("focus"),blurScope:r.get("blurScope"),emphasisDisabled:r.get("disabled"),hoverScale:r.get("scale"),labelStatesModels:Xh(t),cursorStyle:t.get("cursor")}}function Yp(e,t,r,n,i,a,o){var s=new e(t,r,n,i);return s.setPosition(a),t.setItemGraphicEl(r,s),o.add(s),s}var TL=(function(){function e(t){this.group=new Vt,this._SymbolCtor=t||Cv}return e.prototype.updateData=function(t,r){this._progressiveEls=null,r=Up(r);var n=this.group,i=t.hostModel,a=this._data,o=this._SymbolCtor,s=r.disableAnimation,l=this._seriesScope=Wp(t),u={disableAnimation:s},f=r.getSymbolPoint||function(h){return t.getItemLayout(h)};a||n.removeAll(),t.diff(a).add(function(h){var v=f(h);Fo(t,v,h,r)&&Yp(o,t,h,l,u,v,n)}).update(function(h,v){var c=a.getItemGraphicEl(v),d=f(h);if(!Fo(t,d,h,r)){n.remove(c);return}var p=t.getItemVisual(h,"symbol")||"circle",m=c&&c.getSymbolType&&c.getSymbolType();if(!c||m&&m!==p)n.remove(c),c=new o(t,h,l,u),c.setPosition(d);else{c.updateData(t,h,l,u);var g={x:d[0],y:d[1]};s?c.attr(g):zr(c,g,i)}n.add(c),t.setItemGraphicEl(h,c)}).remove(function(h){var v=a.getItemGraphicEl(h);v&&v.fadeOut(function(){n.remove(v)},i)}).execute(),this._getSymbolPoint=f,this._data=t},e.prototype.updateLayout=function(t){var r=this._data;if(r)for(var n=this,i=r.getStore(),a=0,o=i.count();a<o;a++){var s=r.getItemGraphicEl(a),l=n._getSymbolPoint(a);Fo(r,l,a,t)?(s=s||Yp(n._SymbolCtor,r,a,n._seriesScope,{disableAnimation:!0},l,n.group),s.stopAnimation(),s.setPosition(l),s.markRedraw()):s&&(n.group.remove(s),r.setItemGraphicEl(a,null))}},e.prototype.incrementalPrepareUpdate=function(t){this._seriesScope=Wp(t),this._data=null,this.group.removeAll()},e.prototype.incrementalUpdate=function(t,r,n,i){this._progressiveEls=[],i=Up(i);function a(u){u.isGroup||(u.incremental=n,u.ensureState("emphasis").hoverLayer=Fh)}for(var o=t.start;o<t.end;o++){var s=r.getItemLayout(o);if(Fo(r,s,o,i)){var l=new this._SymbolCtor(r,o,this._seriesScope);l.traverse(a),l.setPosition(s),this.group.add(l),r.setItemGraphicEl(o,l),this._progressiveEls.push(l)}}},e.prototype.eachRendered=function(t){Gh(this._progressiveEls||this.group,t)},e.prototype.remove=function(t){var r=this.group,n=this._data;n&&t?n.eachItemGraphicEl(function(i){i.fadeOut(function(){r.remove(i)},n.hostModel)}):r.removeAll()},e})();function h_(e,t,r){var n=e.getBaseAxis(),i=e.getOtherAxis(n),a=wL(i,r),o=n.dim,s=i.dim,l=t.mapDimension(s),u=t.mapDimension(o),f=s==="x"||s==="radius"?1:0,h=rt(e.dimensions,function(d){return t.mapDimension(d)}),v=!1,c=t.getCalculationInfo("stackResultDimension");return Aa(t,h[0])&&(v=!0,h[0]=c),Aa(t,h[1])&&(v=!0,h[1]=c),{dataDimsForPoint:h,valueStart:a,valueAxisDim:s,baseAxisDim:o,stacked:!!v,valueDim:l,baseDim:u,baseDataOffset:f,stackedOverDimension:t.getCalculationInfo("stackedOverDimension")}}function wL(e,t){var r=0,n=e.scale.getExtent();return t==="start"?r=n[0]:t==="end"?r=n[1]:Ct(t)&&!isNaN(t)?r=t:n[0]>0?r=n[0]:n[1]<0&&(r=n[1]),r}function v_(e,t,r,n){var i=NaN;e.stacked&&(i=r.get(r.getCalculationInfo("stackedOverDimension"),n)),isNaN(i)&&(i=e.valueStart);var a=e.baseDataOffset,o=[];return o[a]=r.get(e.baseDim,n),o[1-a]=i,t.dataToPoint(o)}function Le(e,t){return!isFinite(e)||!isFinite(t)}var xL=typeof Float32Array!==Ga?Float32Array:void 0;function ii(e){return CL({ctor:xL},e).arr}function CL(e,t){var r=e.arr,n=e.ctor;if(t>yc&&(t=yc),!r||e.typed&&r.length<t){var i=void 0;if(n)try{i=new n(t),e.typed=!0,r&&i.set(r)}catch{}if(!i&&(i=[],e.typed=!1,r))for(var a=0,o=r.length;a<o;a++)i[a]=r[a];e.arr=i}return e}function DL(e,t){var r=[];return t.diff(e).add(function(n){r.push({cmd:"+",idx:n})}).update(function(n,i){r.push({cmd:"=",idx:i,idx1:n})}).remove(function(n){r.push({cmd:"-",idx:n})}).execute(),r}function ML(e,t,r,n,i,a,o,s){for(var l=DL(e,t),u=[],f=[],h=[],v=[],c=[],d=[],p=[],m=h_(i,t,o),g=e.getLayout("points")||[],y=t.getLayout("points")||[],_=0;_<l.length;_++){var S=l[_],b=!0,T=void 0,w=void 0;switch(S.cmd){case"=":T=S.idx*2,w=S.idx1*2;var M=g[T],C=g[T+1],x=y[w],A=y[w+1];(isNaN(M)||isNaN(C))&&(M=x,C=A),u.push(M,C),f.push(x,A),h.push(r[T],r[T+1]),v.push(n[w],n[w+1]),p.push(t.getRawIndex(S.idx1));break;case"+":var I=S.idx,L=m.dataDimsForPoint,P=i.dataToPoint([t.get(L[0],I),t.get(L[1],I)]);w=I*2,u.push(P[0],P[1]),f.push(y[w],y[w+1]);var R=v_(m,i,t,I);h.push(R[0],R[1]),v.push(n[w],n[w+1]),p.push(t.getRawIndex(I));break;case"-":b=!1}b&&(c.push(S),d.push(d.length))}d.sort(function(lt,k){return p[lt]-p[k]});for(var E=u.length,F=ii(E),G=ii(E),U=ii(E),tt=ii(E),Z=[],_=0;_<d.length;_++){var at=d[_],q=_*2,z=at*2;F[q]=u[z],F[q+1]=u[z+1],G[q]=f[z],G[q+1]=f[z+1],U[q]=h[z],U[q+1]=h[z+1],tt[q]=v[z],tt[q+1]=v[z+1],Z[_]=c[at]}return{current:F,next:G,stackedOnCurrent:U,stackedOnNext:tt,status:Z}}var Cr=Math.min,Dr=Math.max;function Jf(e,t,r,n,i,a,o,s,l){for(var u,f,h,v,c,d,p=r,m=0;m<n;m++){var g=t[p*2],y=t[p*2+1];if(p>=i||p<0)break;if(Le(g,y)){if(l){p+=a;continue}break}if(p===r)e[a>0?"moveTo":"lineTo"](g,y),h=g,v=y;else{var _=g-u,S=y-f;if(_*_+S*S<.5){p+=a;continue}if(o>0){for(var b=p+a,T=t[b*2],w=t[b*2+1];T===g&&w===y&&m<n;)m++,b+=a,p+=a,T=t[b*2],w=t[b*2+1],g=t[p*2],y=t[p*2+1],_=g-u,S=y-f;var M=m+1;if(l)for(;Le(T,w)&&M<n;)M++,b+=a,T=t[b*2],w=t[b*2+1];var C=.5,x=0,A=0,I=void 0,L=void 0;if(M>=n||Le(T,w))c=g,d=y;else{x=T-u,A=w-f;var P=g-u,R=T-g,E=y-f,F=w-y,G=void 0,U=void 0;if(s==="x"){G=Math.abs(P),U=Math.abs(R);var tt=x>0?1:-1;c=g-tt*G*o,d=y,I=g+tt*U*o,L=y}else if(s==="y"){G=Math.abs(E),U=Math.abs(F);var Z=A>0?1:-1;c=g,d=y-Z*G*o,I=g,L=y+Z*U*o}else G=Math.sqrt(P*P+E*E),U=Math.sqrt(R*R+F*F),C=U/(U+G),c=g-x*o*(1-C),d=y-A*o*(1-C),I=g+x*o*C,L=y+A*o*C,I=Cr(I,Dr(T,g)),L=Cr(L,Dr(w,y)),I=Dr(I,Cr(T,g)),L=Dr(L,Cr(w,y)),x=I-g,A=L-y,c=g-x*G/U,d=y-A*G/U,c=Cr(c,Dr(u,g)),d=Cr(d,Dr(f,y)),c=Dr(c,Cr(u,g)),d=Dr(d,Cr(f,y)),x=g-c,A=y-d,I=g+x*U/G,L=y+A*U/G}e.bezierCurveTo(h,v,c,d,g,y),h=I,v=L}else e.lineTo(g,y)}u=g,f=y,p+=a}return m}var c_=(function(){function e(){this.smooth=0,this.smoothConstraint=!0}return e})(),AL=(function(e){V(t,e);function t(r){var n=e.call(this,r)||this;return n.type="ec-polyline",n}return t.prototype.getDefaultStyle=function(){return{stroke:J.color.neutral99,fill:null}},t.prototype.getDefaultShape=function(){return new c_},t.prototype.buildPath=function(r,n){var i=n.points,a=0,o=i.length/2;if(n.connectNulls){for(;o>0&&Le(i[o*2-2],i[o*2-1]);o--);for(;a<o&&Le(i[a*2],i[a*2+1]);a++);}for(;a<o;)a+=Jf(r,i,a,o,o,1,n.smooth,n.smoothMonotone,n.connectNulls)+1},t.prototype.getPointOn=function(r,n){this.path||(this.createPathProxy(),this.buildPath(this.path,this.shape));for(var i=this.path,a=i.data,o=Ln.CMD,s,l,u=n==="x",f=[],h=0;h<a.length;){var v=a[h++],c=void 0,d=void 0,p=void 0,m=void 0,g=void 0,y=void 0,_=void 0;switch(v){case o.M:s=a[h++],l=a[h++];break;case o.L:if(c=a[h++],d=a[h++],_=u?(r-s)/(c-s):(r-l)/(d-l),_<=1&&_>=0){var S=u?(d-l)*_+l:(c-s)*_+s;return u?[r,S]:[S,r]}s=c,l=d;break;case o.C:c=a[h++],d=a[h++],p=a[h++],m=a[h++],g=a[h++],y=a[h++];var b=u?cs(s,c,p,g,r,f):cs(l,d,m,y,r,f);if(b>0)for(var T=0;T<b;T++){var w=f[T];if(w<=1&&w>=0){var S=u?Ht(l,d,m,y,w):Ht(s,c,p,g,w);return u?[r,S]:[S,r]}}s=g,l=y;break}}},t})(St),LL=(function(e){V(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t})(c_),IL=(function(e){V(t,e);function t(r){var n=e.call(this,r)||this;return n.type="ec-polygon",n}return t.prototype.getDefaultShape=function(){return new LL},t.prototype.buildPath=function(r,n){var i=n.points,a=n.stackedOnPoints,o=0,s=i.length/2,l=n.smoothMonotone;if(n.connectNulls){for(;s>0&&Le(i[s*2-2],i[s*2-1]);s--);for(;o<s&&Le(i[o*2],i[o*2+1]);o++);}for(;o<s;){var u=Jf(r,i,o,s,s,1,n.smooth,l,n.connectNulls);Jf(r,a,o+u-1,u,s,-1,n.stackedOnSmooth,l,n.connectNulls),o+=u+1,r.closePath()}},t})(St);function PL(e,t,r,n,i){var a=e.getArea(),o=a.x,s=a.y,l=a.width,u=a.height,f=r.get(["lineStyle","width"])||0;o-=f/2,s-=f/2,l+=f,u+=f,l=Math.ceil(l),o!==Math.floor(o)&&(o=Math.floor(o),l++);var h=new Rt({shape:{x:o,y:s,width:l,height:u}});if(t){var v=e.getBaseAxis(),c=v.isHorizontal(),d=v.inverse;c?(d&&(h.shape.x+=l),h.shape.width=0):(d||(h.shape.y+=u),h.shape.height=0);var p=ot(i)?function(m){i(m,h)}:null;Ua(h,{shape:{width:l,height:u,x:o,y:s}},r,null,n,p)}return h}function EL(e,t,r){var n=e.getArea(),i=ft(n.r0,1),a=ft(n.r,1),o=new ol({shape:{cx:ft(e.cx,1),cy:ft(e.cy,1),r0:i,r:a,startAngle:n.startAngle,endAngle:n.endAngle,clockwise:n.clockwise}});if(t){var s=e.getBaseAxis().dim==="angle";s?o.shape.endAngle=n.startAngle:o.shape.r=i,Ua(o,{shape:{endAngle:n.endAngle,r:a}},r)}return o}function RL(e,t){return e.type===t}function Xp(e,t){if(e.length===t.length){for(var r=0;r<e.length;r++)if(e[r]!==t[r])return;return!0}}function $p(e){for(var t=Te(),r=Te(),n=0;n<e.length;){var i=e[n++],a=e[n++];Le(i,a)||(gf(t,i),gf(r,a))}return[t,r]}function Zp(e,t){var r=$p(e),n=r[0],i=r[1],a=$p(t),o=a[0],s=a[1];return Math.max(Math.abs(n[0]-o[0]),Math.abs(i[0]-s[0]),Math.abs(n[1]-o[1]),Math.abs(i[1]-s[1]))}function qp(e){return Ct(e)?e:e?.5:0}function kL(e,t,r){if(r.valueDim==null)return[];for(var n=t.count(),i=ii(n*2),a=0;a<n;a++){var o=v_(r,e,t,a);i[a*2]=o[0],i[a*2+1]=o[1]}return i}function Mr(e,t,r,n,i){var a=r.getBaseAxis(),o=a.dim==="x"||a.dim==="radius"?0:1,s=[],l=0,u=[],f=[],h=[],v=[];if(i){for(l=0;l<e.length;l+=2){var c=t||e;Le(c[l],c[l+1])||v.push(e[l],e[l+1])}e=v}for(l=0;l<e.length-2;l+=2)switch(h[0]=e[l+2],h[1]=e[l+3],f[0]=e[l],f[1]=e[l+1],s.push(f[0],f[1]),n){case"end":u[o]=h[o],u[1-o]=f[1-o],s.push(u[0],u[1]);break;case"middle":var d=(f[o]+h[o])/2,p=[];u[o]=p[o]=d,u[1-o]=f[1-o],p[1-o]=h[1-o],s.push(u[0],u[1]),s.push(p[0],p[1]);break;default:u[o]=f[o],u[1-o]=h[1-o],s.push(u[0],u[1])}return s.push(e[l++],e[l++]),s}function OL(e,t){var r=[],n=e.length,i,a;function o(f,h,v){var c=f.coord,d=(v-c)/(h.coord-c),p=dS(d,[f.color,h.color]);return{coord:v,color:p}}for(var s=0;s<n;s++){var l=e[s],u=l.coord;if(u<0)i=l;else if(u>t){a?r.push(o(a,l,t)):i&&r.push(o(i,l,0),o(i,l,t));break}else i&&(r.push(o(i,l,0)),i=null),r.push(l),a=l}return r}function BL(e,t,r){var n=e.getVisual("visualMeta");if(!(!n||!n.length||!e.count())&&t.type==="cartesian2d"){for(var i,a,o=n.length-1;o>=0;o--){var s=e.getDimensionInfo(n[o].dimension);if(i=s&&s.coordDim,i==="x"||i==="y"){a=n[o];break}}if(a){var l=t.getAxis(i),u=rt(a.stops,function(_){return{coord:l.toGlobalCoord(l.dataToCoord(_.value)),color:_.color}}),f=u.length,h=a.outerColors.slice();f&&u[0].coord>u[f-1].coord&&(u.reverse(),h.reverse());var v=OL(u,i==="x"?r.getWidth():r.getHeight()),c=v.length;if(!c&&f)return u[0].coord<0?h[1]?h[1]:u[f-1].color:h[0]?h[0]:u[0].color;var d=10,p=v[0].coord-d,m=v[c-1].coord+d,g=m-p;if(g<.001)return"transparent";D(v,function(_){_.offset=(_.coord-p)/g}),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 y=new Qm(0,0,0,0,v,!0);return y[i]=p,y[i+"2"]=m,y}}}function NL(e,t,r){var n=e.get("showAllSymbol"),i=n==="auto";if(!(n&&!i)){var a=r.getAxesByScale("ordinal")[0];if(a&&!(i&&FL(a,t))){var o=t.mapDimension(a.dim),s={};return D(a.getViewLabels(),function(l){l.tick.offInterval||(s[Xa(a.scale,l.tick)]=1)}),function(l){return!s.hasOwnProperty(t.get(o,l))}}}}function FL(e,t){var r=e.getExtent(),n=Math.abs(r[1]-r[0])/e.scale.count();isNaN(n)&&(n=0);for(var i=t.count(),a=Math.max(1,Math.round(i/5)),o=0;o<i;o+=a)if(Cv.getSymbolSize(t,o)[e.isHorizontal()?1:0]*1.5>n)return!1;return!0}function zL(e){for(var t=e.length/2;t>0&&Le(e[t*2-2],e[t*2-1]);t--);return t-1}function Kp(e,t){return[e[t*2],e[t*2+1]]}function HL(e,t,r){for(var n=e.length/2,i=r==="x"?0:1,a,o,s=0,l=-1,u=0;u<n;u++)if(o=e[u*2+i],!Le(o,e[u*2+1-i])){if(u===0){a=o;continue}if(a<=t&&o>=t||a>=t&&o<=t){l=u;break}s=u,a=o}return{range:[s,l],t:(t-a)/(o-a)}}function d_(e){if(e.get(["endLabel","show"]))return!0;for(var t=0;t<nr.length;t++)if(e.get([nr[t],"endLabel","show"]))return!0;return!1}function ku(e,t,r,n){if(RL(t,"cartesian2d")){var i=n.getModel("endLabel"),a=i.get("valueAnimation"),o=n.getData(),s={lastFrameIndex:0},l=d_(n)?function(c,d){e._endLabelOnDuring(c,d,o,s,a,i,t)}:null,u=t.getBaseAxis().isHorizontal(),f=PL(t,r,n,function(){var c=e._endLabel;c&&r&&s.originalX!=null&&c.attr({x:s.originalX,y:s.originalY})},l);if(!n.get("clip",!0)){var h=f.shape,v=Math.max(h.width,h.height);u?(h.y-=v,h.height+=v*2):(h.x-=v,h.width+=v*2)}return l&&l(1,f),f}else return EL(t,r,n)}function VL(e,t){var r=t.getBaseAxis(),n=r.isHorizontal(),i=r.inverse,a=n?i?"right":"left":"center",o=n?"middle":i?"top":"bottom";return{normal:{align:e.get("align")||a,verticalAlign:e.get("verticalAlign")||o}}}var GL=(function(e){V(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.init=function(){var r=new Vt,n=new TL;this.group.add(n.group),this._symbolDraw=n,this._lineGroup=r,this._changePolyState=wt(this._changePolyState,this)},t.prototype.render=function(r,n,i){var a=r.coordinateSystem,o=this.group,s=r.getData(),l=r.getModel("lineStyle"),u=r.getModel("areaStyle"),f=s.getLayout("points")||[],h=a.type==="polar",v=this._coordSys,c=this._symbolDraw,d=this._polyline,p=this._polygon,m=this._lineGroup,g=!n.ssr&&r.get("animation"),y=!u.isEmpty(),_=u.get("origin"),S=h_(a,s,_),b=y&&kL(a,s,S),T=r.get("showSymbol"),w=r.get("connectNulls"),M=T&&!h&&NL(r,s,a),C=this._data;C&&C.eachItemGraphicEl(function($,et){$.__temp&&(o.remove($),C.setItemGraphicEl(et,null))}),T||c.remove(),o.add(m);var x=h?!1:r.get("step"),A;a&&a.getArea&&r.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 I=BL(s,a,i)||s.getVisual("style")[s.getVisual("drawType")];if(!(d&&v.type===a.type&&x===this._step))T&&c.updateData(s,{isIgnore:M,clipShape:A,disableAnimation:!0,getSymbolPoint:function($){return[f[$*2],f[$*2+1]]}}),g&&this._initSymbolLabelAnimation(s,a,A),x&&(b&&(b=Mr(b,f,a,x,w)),f=Mr(f,null,a,x,w)),d=this._newPolyline(f),y?p=this._newPolygon(f,b):p&&(m.remove(p),p=this._polygon=null),h||this._initOrUpdateEndLabel(r,a,In(I)),m.setClipPath(ku(this,a,!0,r));else{y&&!p?p=this._newPolygon(f,b):p&&!y&&(m.remove(p),p=this._polygon=null),h||this._initOrUpdateEndLabel(r,a,In(I));var L=m.getClipPath();if(L){var P=ku(this,a,!1,r);Ua(L,{shape:P.shape},r)}else m.setClipPath(ku(this,a,!0,r));T&&c.updateData(s,{isIgnore:M,clipShape:A,disableAnimation:!0,getSymbolPoint:function($){return[f[$*2],f[$*2+1]]}}),(!Xp(this._stackedOnPoints,b)||!Xp(this._points,f))&&(g?this._doUpdateAnimation(s,b,a,i,x,_,w):(x&&(b&&(b=Mr(b,f,a,x,w)),f=Mr(f,null,a,x,w)),d.setShape({points:f}),p&&p.setShape({points:f,stackedOnPoints:b})))}var R=r.getModel("emphasis"),E=R.get("focus"),F=R.get("blurScope"),G=R.get("disabled");if(d.useStyle(yt(l.getLineStyle(),{fill:"none",stroke:I,lineJoin:"bevel"})),Qc(d,r,"lineStyle"),d.style.lineWidth>0&&r.get(["emphasis","lineStyle","width"])==="bolder"){var U=d.getState("emphasis").style;U.lineWidth=+d.style.lineWidth+1}gt(d).seriesIndex=r.seriesIndex,Cf(d,E,F,G);var tt=qp(r.get("smooth")),Z=r.get("smoothMonotone");if(d.setShape({smooth:tt,smoothMonotone:Z,connectNulls:w}),p){var at=s.getCalculationInfo("stackedOnSeries"),q=0;p.useStyle(yt(u.getAreaStyle(),{fill:I,opacity:.7,lineJoin:"bevel",decal:s.getVisual("style").decal})),at&&(q=qp(at.get("smooth"))),p.setShape({smooth:tt,stackedOnSmooth:q,smoothMonotone:Z,connectNulls:w}),Qc(p,r,"areaStyle"),gt(p).seriesIndex=r.seriesIndex,Cf(p,E,F,G)}var z=this._changePolyState;s.eachItemGraphicEl(function($){$&&($.onHoverStateChange=z)}),this._polyline.onHoverStateChange=z,this._data=s,this._coordSys=a,this._stackedOnPoints=b,this._points=f,this._step=x,this._valueOrigin=_;var lt=r.get("triggerEvent"),k=r.get("triggerLineEvent"),B=k===!0||lt===!0||lt==="line",Q=k===!0||lt===!0||lt==="area";this.packEventData(r,d,B),p&&this.packEventData(r,p,Q)},t.prototype.packEventData=function(r,n,i){gt(n).eventData=i?{componentType:"series",componentSubType:"line",componentIndex:r.componentIndex,seriesIndex:r.seriesIndex,seriesName:r.name,seriesType:"line",selfType:n===this._polygon?"area":"line"}:null},t.prototype.highlight=function(r,n,i,a){var o=r.getData(),s=An(o,a);if(this._changePolyState("emphasis"),!(s instanceof Array)&&s!=null&&s>=0){var l=o.getLayout("points"),u=o.getItemGraphicEl(s);if(!u){var f=l[s*2],h=l[s*2+1];if(Le(f,h)||this._clipShapeForSymbol&&!this._clipShapeForSymbol.contain(f,h))return;var v=r.get("zlevel")||0,c=r.get("z")||0;u=new Cv(o,s),u.x=f,u.y=h,u.setZ(v,c);var d=u.getSymbolPath().getTextContent();d&&(d.zlevel=v,d.z=c,d.z2=this._polyline.z2+1),u.__temp=!0,o.setItemGraphicEl(s,u),u.stopSymbolAnimation(!0),this.group.add(u)}u.highlight()}else er.prototype.highlight.call(this,r,n,i,a)},t.prototype.downplay=function(r,n,i,a){var o=r.getData(),s=An(o,a);if(this._changePolyState("normal"),s!=null&&s>=0){var l=o.getItemGraphicEl(s);l&&(l.__temp?(o.setItemGraphicEl(s,null),this.group.remove(l)):l.downplay())}else er.prototype.downplay.call(this,r,n,i,a)},t.prototype._changePolyState=function(r){var n=this._polygon;Xc(this._polyline,r),n&&Xc(n,r)},t.prototype._newPolyline=function(r){var n=this._polyline;return n&&this._lineGroup.remove(n),n=new AL({shape:{points:r},segmentIgnoreThreshold:2,z2:10}),this._lineGroup.add(n),this._polyline=n,n},t.prototype._newPolygon=function(r,n){var i=this._polygon;return i&&this._lineGroup.remove(i),i=new IL({shape:{points:r,stackedOnPoints:n},segmentIgnoreThreshold:2}),this._lineGroup.add(i),this._polygon=i,i},t.prototype._initSymbolLabelAnimation=function(r,n,i){var a,o,s=n.getBaseAxis(),l=s.inverse;n.type==="cartesian2d"?(a=s.isHorizontal(),o=!1):n.type==="polar"&&(a=s.dim==="angle",o=!0);var u=r.hostModel,f=u.get("animationDuration");ot(f)&&(f=f(null));var h=u.get("animationDelay")||0,v=ot(h)?h(null):h;r.eachItemGraphicEl(function(c,d){var p=c;if(p){var m=[c.x,c.y],g=void 0,y=void 0,_=void 0;if(i)if(o){var S=i,b=n.pointToCoord(m);a?(g=S.startAngle,y=S.endAngle,_=-b[1]/180*Math.PI):(g=S.r0,y=S.r,_=b[0])}else{var T=i;a?(g=T.x,y=T.x+T.width,_=c.x):(g=T.y+T.height,y=T.y,_=c.y)}var w=y===g?0:(_-g)/(y-g);l&&(w=1-w);var M=ot(h)?h(d):f*w+v,C=p.getSymbolPath(),x=C.getTextContent();p.attr({scaleX:0,scaleY:0}),p.animateTo({scaleX:1,scaleY:1},{duration:200,setToFinal:!0,delay:M}),x&&x.animateFrom({style:{opacity:0}},{duration:300,delay:M}),C.disableLabelAnimation=!0}})},t.prototype._initOrUpdateEndLabel=function(r,n,i){var a=r.getModel("endLabel");if(d_(r)){var o=r.getData(),s=this._polyline,l=o.getLayout("points");if(!l){s.removeTextContent(),this._endLabel=null;return}var u=this._endLabel;u||(u=this._endLabel=new oe({z2:200}),u.ignoreClip=!0,s.setTextContent(this._endLabel),s.disableLabelAnimation=!0);var f=zL(l);f>=0&&(Yh(s,Xh(r,"endLabel"),{inheritColor:i,labelFetcher:r,labelDataIndex:f,defaultText:function(h,v,c){return c!=null?SL(o,c):f_(o,h)},enableTextSetter:!0},VL(a,n)),s.textConfig.position=null)}else this._endLabel&&(this._polyline.removeTextContent(),this._endLabel=null)},t.prototype._endLabelOnDuring=function(r,n,i,a,o,s,l){var u=this._endLabel,f=this._polyline;if(u){r<1&&a.originalX==null&&(a.originalX=u.x,a.originalY=u.y);var h=i.getLayout("points"),v=i.hostModel,c=v.get("connectNulls"),d=s.get("precision"),p=s.get("distance")||0,m=l.getBaseAxis(),g=m.isHorizontal(),y=m.inverse,_=n.shape,S=y?g?_.x:_.y+_.height:g?_.x+_.width:_.y,b=(g?p:0)*(y?-1:1),T=(g?0:-p)*(y?-1:1),w=g?"x":"y",M=HL(h,S,w),C=M.range,x=C[1]-C[0],A=void 0;if(x>=1){if(x>1&&!c){var I=Kp(h,C[0]);u.attr({x:I[0]+b,y:I[1]+T}),o&&(A=v.getRawValue(C[0]))}else{var I=f.getPointOn(S,w);I&&u.attr({x:I[0]+b,y:I[1]+T});var L=v.getRawValue(C[0]),P=v.getRawValue(C[1]);o&&(A=mb(i,d,L,P,M.t))}a.lastFrameIndex=C[0]}else{var R=r===1||a.lastFrameIndex>0?C[0]:0,I=Kp(h,R);o&&(A=v.getRawValue(R)),u.attr({x:I[0]+b,y:I[1]+T})}if(o){var E=fy(u);typeof E.setLabelText=="function"&&E.setLabelText(A)}}},t.prototype._doUpdateAnimation=function(r,n,i,a,o,s,l){var u=this._polyline,f=this._polygon,h=r.hostModel,v=ML(this._data,r,this._stackedOnPoints,n,this._coordSys,i,this._valueOrigin),c=v.current,d=v.stackedOnCurrent,p=v.next,m=v.stackedOnNext;if(o&&(d=Mr(v.stackedOnCurrent,v.current,i,o,l),c=Mr(v.current,null,i,o,l),m=Mr(v.stackedOnNext,v.next,i,o,l),p=Mr(v.next,null,i,o,l)),Zp(c,p)>3e3||f&&Zp(d,m)>3e3){u.stopAnimation(),u.setShape({points:p}),f&&(f.stopAnimation(),f.setShape({points:p,stackedOnPoints:m}));return}u.shape.__points=v.current,u.shape.points=c;var g={shape:{points:p}};v.current!==c&&(g.shape.__points=v.next),u.stopAnimation(),zr(u,g,h),f&&(f.setShape({points:c,stackedOnPoints:d}),f.stopAnimation(),zr(f,{shape:{stackedOnPoints:m}},h),u.shape.points!==f.shape.points&&(f.shape.points=u.shape.points));for(var y=[],_=v.status,S=0;S<_.length;S++){var b=_[S].cmd;if(b==="="){var T=r.getItemGraphicEl(_[S].idx1);T&&y.push({el:T,ptIdx:S})}}u.animators&&u.animators.length&&u.animators[0].during(function(){f&&f.dirtyShape();for(var w=u.shape.__points,M=0;M<y.length;M++){var C=y[M].el,x=y[M].ptIdx*2;C.x=w[x],C.y=w[x+1],C.markRedraw()}})},t.prototype.remove=function(r){var n=this.group,i=this._data;this._lineGroup.removeAll(),this._symbolDraw.remove(!0),i&&i.eachItemGraphicEl(function(a,o){a.__temp&&(n.remove(a),i.setItemGraphicEl(o,null))}),this._polyline=this._polygon=this._coordSys=this._points=this._stackedOnPoints=this._endLabel=this._data=null},t.type="line",t})(er);function UL(e,t){return{seriesType:e,plan:Jy(),reset:function(r){var n=r.getData(),i=r.coordinateSystem;if(r.pipelineContext,!!i){var a=rt(i.dimensions,function(h){return n.mapDimension(h)}).slice(0,2),o=a.length,s=n.getCalculationInfo("stackResultDimension");Aa(n,a[0])&&(a[0]=s),Aa(n,a[1])&&(a[1]=s);var l=n.getStore(),u=n.getDimensionIndex(a[0]),f=n.getDimensionIndex(a[1]);return o&&{progress:function(h,v){for(var c=h.end-h.start,d=ii(c*o),p=[],m=[],g=h.start,y=0;g<h.end;g++){var _=void 0;if(o===1){var S=l.get(u,g);_=i.dataToPoint(S,null,m)}else p[0]=l.get(u,g),p[1]=l.get(f,g),_=i.dataToPoint(p,null,m);d[y++]=_[0],d[y++]=_[1]}v.setLayout("points",d),v.setLayout("pointsRange",{start:h.start,end:h.end})}}}}}}var WL={average:function(e){for(var t=0,r=0,n=0;n<e.length;n++)isNaN(e[n])||(t+=e[n],r++);return r===0?NaN:t/r},sum:function(e){for(var t=0,r=0;r<e.length;r++)t+=e[r]||0;return t},max:function(e){for(var t=-1/0,r=0;r<e.length;r++)e[r]>t&&(t=e[r]);return isFinite(t)?t:NaN},min:function(e){for(var t=1/0,r=0;r<e.length;r++)e[r]<t&&(t=e[r]);return isFinite(t)?t:NaN},nearest:function(e){return e[0]}},YL=function(e){return Math.round(e.length/2)};function XL(e){return{seriesType:e,reset:function(t,r,n){var i=t.getData(),a=t.get("sampling"),o=t.coordinateSystem,s=i.count();if(s>10&&o.type==="cartesian2d"&&a){var l=o.getBaseAxis(),u=o.getOtherAxis(l),f=l.getExtent(),h=n.getDevicePixelRatio(),v=Math.abs(f[1]-f[0])*(h||1),c=Math.round(s/v);if(isFinite(c)&&c>1){a==="lttb"?t.setData(i.lttbDownSample(i.mapDimension(u.dim),1/c)):a==="minmax"&&t.setData(i.minmaxDownSample(i.mapDimension(u.dim),1/c));var d=void 0;W(a)?d=WL[a]:ot(a)&&(d=a),d&&t.setData(i.downSample(i.mapDimension(u.dim),1/c,d,YL))}}}}}function $L(e){e.registerChartView(GL),e.registerSeriesModel(_L),e.registerLayout(UL("line")),e.registerVisual({seriesType:"line",reset:function(t){var r=t.getData(),n=t.getModel("lineStyle").getLineStyle();n&&!n.stroke&&(n.stroke=r.getVisual("style").fill),r.setVisual("legendLineStyle",n)}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,XL("line"))}var ZL=(function(e){V(t,e);function t(r,n,i,a,o){var s=e.call(this,r,n,i)||this;return s.index=0,s.type=a||"value",s.position=o||"bottom",s}return t.prototype.isHorizontal=function(){var r=this.position;return r==="top"||r==="bottom"},t.prototype.getGlobalExtent=function(r){var n=this.getExtent();return n[0]=this.toGlobalCoord(n[0]),n[1]=this.toGlobalCoord(n[1]),r&&n[0]>n[1]&&n.reverse(),n},t.prototype.pointToData=function(r,n){return this.coordToData(this.toLocalCoord(r[this.dim==="x"?0:1]),n)},t.prototype.setCategorySortInfo=function(r){if(this.type!=="category")return!1;this.model.option.categorySortInfo=r,this.scale.setSortInfo(r)},t})(vL),qL=null;function KL(){return qL}var QL="expandAxisBreak",Er=Math.PI,JL=[[1,2,1,2],[5,3,5,3],[8,3,8,3]],jL=[[0,1,0,1],[0,3,0,3],[0,3,0,3]],Ti=bt(),p_=bt(),g_=(function(){function e(t){this.recordMap={},this.resolveAxisNameOverlap=t}return e.prototype.ensureRecord=function(t){var r=t.axis.dim,n=t.componentIndex,i=this.recordMap,a=i[r]||(i[r]=[]);return a[n]||(a[n]={ready:{}})},e})();function tI(e,t,r,n){var i=r.axis,a=t.ensureRecord(r),o=[],s,l=Dv(e.axisName)&&bi(e.nameLocation);D(n,function(d){var p=Ur(d);if(!(!p||p.label.ignore)){o.push(p);var m=a.transGroup;l&&(m.transform?Oa(Yi,m.transform):ka(Yi),p.transform&&ra(Yi,Yi,p.transform),it.copy(zo,p.localRect),zo.applyTransform(Yi),s?s.union(zo):it.copy(s=new it(0,0,0,0),zo))}});var u=Math.abs(a.dirVec.x)>.1?"x":"y",f=a.transGroup[u];if(o.sort(function(d,p){return Math.abs(d.label[u]-f)-Math.abs(p.label[u]-f)}),l&&s){var h=i.getExtent(),v=Math.min(h[0],h[1]),c=Math.max(h[0],h[1])-v;s.union(new it(v,0,c,1))}a.stOccupiedRect=s,a.labelInfoList=o}var Yi=qe(),zo=new it(0,0,0,0),m_=function(e,t,r,n,i,a){if(bi(e.nameLocation)){var o=a.stOccupiedRect;o&&y_(gL({},o,a.transGroup.transform),n,i)}else __(a.labelInfoList,a.dirVec,n,i)};function y_(e,t,r){var n=new _t;xv(e,t,n,{direction:Math.atan2(r.y,r.x),bidirectional:!1,touchThreshold:.05})&&mL(t,n)}function __(e,t,r,n){for(var i=_t.dot(n,t)>=0,a=0,o=e.length;a<o;a++){var s=e[i?a:o-1-a];s.label.ignore||y_(s,r,n)}}var Br=(function(){function e(t,r,n,i){this.group=new Vt,this._axisModel=t,this._api=r,this._local={},this._shared=i||new g_(m_),this._resetCfgDetermined(n)}return e.prototype.updateCfg=function(t){var r=this._cfg.raw;r.position=t.position,r.labelOffset=t.labelOffset,this._resetCfgDetermined(r)},e.prototype.__getRawCfg=function(){return this._cfg.raw},e.prototype._resetCfgDetermined=function(t){var r=this._axisModel,n=r.getDefaultOption?r.getDefaultOption():{},i=j(t.axisName,r.get("name")),a=r.get("nameMoveOverlap");(a==null||a==="auto")&&(a=j(t.defaultNameMoveOverlap,!0));var o={raw:t,position:t.position,rotation:t.rotation,nameDirection:j(t.nameDirection,1),tickDirection:j(t.tickDirection,1),labelDirection:j(t.labelDirection,1),labelOffset:j(t.labelOffset,0),silent:j(t.silent,!0),axisName:i,nameLocation:ai(r.get("nameLocation"),n.nameLocation,"end"),shouldNameMoveOverlap:Dv(i)&&a,optionHideOverlap:r.get(["axisLabel","hideOverlap"]),showMinorTicks:r.get(["minorTick","show"])};this._cfg=o;var s=new Vt({x:o.position[0],y:o.position[1],rotation:o.rotation});s.updateTransform(),this._transformGroup=s;var l=this._shared.ensureRecord(r);l.transGroup=this._transformGroup,l.dirVec=new _t(Math.cos(-o.rotation),Math.sin(-o.rotation))},e.prototype.build=function(t,r){var n=this;return t||(t={axisLine:!0,axisTickLabelEstimate:!1,axisTickLabelDetermine:!0,axisName:!0}),D(eI,function(i){t[i]&&rI[i](n._cfg,n._local,n._shared,n._axisModel,n.group,n._transformGroup,n._api,r||{})}),this},e.innerTextLayout=function(t,r,n){var i=um(r-t),a,o;return _s(i)?(o=n>0?"top":"bottom",a="center"):_s(i-Er)?(o=n>0?"bottom":"top",a="center"):(o="middle",i>0&&i<Er?a=n>0?"right":"left":a=n>0?"left":"right"),{rotation:i,textAlign:a,textVerticalAlign:o}},e.makeAxisEventDataBase=function(t){var r={componentType:t.mainType,componentIndex:t.componentIndex};return r[t.mainType+"Index"]=t.componentIndex,r},e.isLabelSilent=function(t){var r=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||r&&r.show)},e})(),eI=["axisLine","axisTickLabelEstimate","axisTickLabelDetermine","axisName"],rI={axisLine:function(e,t,r,n,i,a,o){var s=n.get(["axisLine","show"]);if(s==="auto"&&(s=!0,e.raw.axisLineAutoShow!=null&&(s=!!e.raw.axisLineAutoShow)),!!s){var l=n.axis.getExtent(),u=a.transform,f=[l[0],0],h=[l[1],0],v=f[0]>h[0];u&&(Ae(f,f,u),Ae(h,h,u));var c=N({lineCap:"round"},n.getModel(["axisLine","lineStyle"]).getLineStyle()),d={strokeContainThreshold:e.raw.strokeContainThreshold||5,silent:!0,z2:1,style:c};if(n.get(["axisLine","breakLine"])&&Ls(n.axis.scale))KL().buildAxisBreakLine(n,i,a,d);else{var p=new Fr(N({shape:{x1:f[0],y1:f[1],x2:h[0],y2:h[1]}},d));ba(p.shape,p.style.lineWidth),p.anid="line",i.add(p)}var m=n.get(["axisLine","symbol"]);if(m!=null){var g=n.get(["axisLine","symbolSize"]);W(m)&&(m=[m,m]),(W(g)||Ct(g))&&(g=[g,g]);var y=f0(n.get(["axisLine","symbolOffset"])||0,g),_=g[0],S=g[1];D([{rotate:e.rotation+Math.PI/2,offset:y[0],r:0},{rotate:e.rotation-Math.PI/2,offset:y[1],r:Math.sqrt((f[0]-h[0])*(f[0]-h[0])+(f[1]-h[1])*(f[1]-h[1]))}],function(b,T){if(m[T]!=="none"&&m[T]!=null){var w=_i(m[T],-_/2,-S/2,_,S,c.stroke,!0),M=b.r+b.offset,C=v?h:f;w.attr({rotation:b.rotate,x:C[0]+M*Math.cos(e.rotation),y:C[1]-M*Math.sin(e.rotation),silent:!0,z2:11}),i.add(w)}})}}},axisTickLabelEstimate:function(e,t,r,n,i,a,o,s){var l=Jp(t,i,s);l&&Qp(e,t,r,n,i,a,o,Be.estimate)},axisTickLabelDetermine:function(e,t,r,n,i,a,o,s){var l=Jp(t,i,s);l&&Qp(e,t,r,n,i,a,o,Be.determine);var u=oI(e,i,a,n);aI(e,t.labelLayoutList,u),sI(e,i,a,n,e.tickDirection)},axisName:function(e,t,r,n,i,a,o,s){var l=r.ensureRecord(n);t.nameEl&&(i.remove(t.nameEl),t.nameEl=l.nameLayout=l.nameLocation=null);var u=e.axisName;if(Dv(u)){var f=e.nameLocation,h=e.nameDirection,v=n.getModel("nameTextStyle"),c=n.get("nameGap")||0,d=n.axis.getExtent(),p=n.axis.inverse?-1:1,m=new _t(0,0),g=new _t(0,0);f==="start"?(m.x=d[0]-p*c,g.x=-p):f==="end"?(m.x=d[1]+p*c,g.x=p):(m.x=(d[0]+d[1])/2,m.y=e.labelOffset+h*c,g.y=h);var y=qe();g.transform(mh(y,y,e.rotation));var _=n.get("nameRotate");_!=null&&(_=_*Er/180);var S,b;bi(f)?S=Br.innerTextLayout(e.rotation,_??e.rotation,h):(S=nI(e.rotation,f,_||0,d),b=e.raw.axisNameAvailableWidth,b!=null&&(b=Math.abs(b/Math.sin(S.rotation)),!isFinite(b)&&(b=null)));var T=v.getFont(),w=n.get("nameTruncate",!0)||{},M=w.ellipsis,C=us(e.raw.nameTruncateMaxWidth,w.maxWidth,b),x=s.nameMarginLevel||0,A=new oe({x:m.x,y:m.y,rotation:S.rotation,silent:Br.isLabelSilent(n),style:mi(v,{text:u,font:T,overflow:"truncate",width:C,ellipsis:M,fill:v.getTextColor()||n.get(["axisLine","lineStyle","color"]),align:v.get("align")||S.textAlign,verticalAlign:v.get("verticalAlign")||S.textVerticalAlign}),z2:1});if(ll({el:A,componentModel:n,itemName:u}),A.__fullText=u,A.anid="name",n.get("triggerEvent")){var I=Br.makeAxisEventDataBase(n);I.targetType="axisName",I.name=u,gt(A).eventData=I}a.add(A),A.updateTransform(),t.nameEl=A;var L=l.nameLayout=Ur({label:A,priority:A.z2,defaultAttr:{ignore:A.ignore},marginDefault:bi(f)?JL[x]:jL[x]});if(l.nameLocation=f,i.add(A),A.decomposeTransform(),e.shouldNameMoveOverlap&&L){var P=r.ensureRecord(n);r.resolveAxisNameOverlap(e,r,n,L,g,P)}}}};function Qp(e,t,r,n,i,a,o,s){b_(t)||lI(e,t,i,s,n,o);var l=t.labelLayoutList;uI(e,n,l,a),e.rotation;var u=e.optionHideOverlap;iI(n,l,u),u&&yL(Xt(l,function(f){return f&&!f.label.ignore})),tI(e,r,n,l)}function nI(e,t,r,n){var i=um(r-e),a,o,s=n[0]>n[1],l=t==="start"&&!s||t!=="start"&&s;return _s(i-Er/2)?(o=l?"bottom":"top",a="center"):_s(i-Er*1.5)?(o=l?"top":"bottom",a="center"):(o="middle",i<Er*1.5&&i>Er/2?a=l?"left":"right":a=l?"right":"left"),{rotation:i,textAlign:a,textVerticalAlign:o}}function iI(e,t,r){var n=e.axis,i=e.get(["axisLabel","customValues"]);if(xA(n))return;function a(u,f,h){var v=Ur(t[f]),c=Ur(t[h]),d=n.scale;if(!(!v||!c)){if(u==null){if(!r&&i)return;var p=Ti(v.label).labelInfo.tick;if(Sv(d)&&p.notNice||lr(d)&&p.offInterval){Qn(v.label);return}}if(u===!1||v.suggestIgnore){Qn(v.label);return}if(c.suggestIgnore){Qn(c.label);return}var m=.1;if(!r){var g=[0,0,0,0];v=Vp({marginForce:g},v),c=Vp({marginForce:g},c)}xv(v,c,null,{touchThreshold:m})&&Qn(u?c.label:v.label)}}var o=e.get(["axisLabel","showMinLabel"]),s=e.get(["axisLabel","showMaxLabel"]),l=t.length;a(o,0,1),a(s,l-1,l-2)}function aI(e,t,r){e.showMinorTicks||D(t,function(n){if(n&&n.label.ignore)for(var i=0;i<r.length;i++){var a=r[i],o=p_(a),s=Ti(n.label);if(o.tickValue!=null&&!o.onBand&&o.tickValue===s.labelInfo.tick.value){Qn(a);return}}})}function Qn(e){e&&(e.ignore=!0)}function S_(e,t,r,n,i){for(var a=[],o=[],s=[],l=0;l<e.length;l++){var u=e[l].coord;o[0]=u,o[1]=0,s[0]=u,s[1]=r,t&&(Ae(o,o,t),Ae(s,s,t));var f=new Fr({shape:{x1:o[0],y1:o[1],x2:s[0],y2:s[1]},style:n,z2:2,autoBatch:!0,silent:!0});ba(f.shape,f.style.lineWidth),f.anid=i+"_"+e[l].tickValue,a.push(f);var h=p_(f);h.onBand=!!e[l].onBand,h.tickValue=e[l].tickValue}return a}function oI(e,t,r,n){var i=n.axis,a=n.getModel("axisTick"),o=a.get("show");if(o==="auto"&&(o=!0,e.raw.axisTickAutoShow!=null&&(o=!!e.raw.axisTickAutoShow)),!o||i.scale.isBlank())return[];for(var s=a.getModel("lineStyle"),l=e.tickDirection*a.get("length"),u=i.getTicksCoords(),f=S_(u,r.transform,l,yt(s.getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])}),"ticks"),h=0;h<f.length;h++)t.add(f[h]);return f}function sI(e,t,r,n,i){var a=n.axis,o=n.getModel("minorTick");if(!(!e.showMinorTicks||a.scale.isBlank())){var s=a.getMinorTicksCoords();if(s.length)for(var l=o.getModel("lineStyle"),u=i*o.get("length"),f=yt(l.getLineStyle(),yt(n.getModel("axisTick").getLineStyle(),{stroke:n.get(["axisLine","lineStyle","color"])})),h=0;h<s.length;h++)for(var v=S_(s[h],r.transform,u,f,"minorticks_"+h),c=0;c<v.length;c++)t.add(v[c])}}function Jp(e,t,r){if(b_(e)){var n=e.axisLabelsCreationContext,i=n.out.noPxChangeTryDetermine;if(r.noPxChange){for(var a=!0,o=0;o<i.length;o++)a=a&&i[o]();if(a)return!1}i.length&&(t.remove(e.labelGroup),jf(e,null,null,null))}return!0}function lI(e,t,r,n,i,a){var o=i.axis,s=us(e.raw.axisLabelShow,i.get(["axisLabel","show"])),l=new Vt;r.add(l);var u=Hs(n);if(!s||o.scale.isBlank()){jf(t,[],l,u);return}var f=i.getModel("axisLabel"),h=o.getViewLabels(u),v=(us(e.raw.labelRotate,f.get("rotate"))||0)*Er/180,c=Br.innerTextLayout(e.rotation,v,e.labelDirection),d=i.getCategories&&i.getCategories(!0),p=[],m=i.get("triggerEvent"),g=1/0,y=-1/0;D(h,function(S,b){var T,w=S.tick,M=S.formattedLabel,C=S.rawLabel,x=f,A=Xa(o.scale,w);if(d&&d[A]){var I=d[A];K(I)&&I.textStyle&&(x=new Mt(I.textStyle,f,i.ecModel))}var L=x.getTextColor()||i.get(["axisLine","lineStyle","color"]),P=x.getShallow("align",!0)||c.textAlign,R=j(x.getShallow("alignMinLabel",!0),P),E=j(x.getShallow("alignMaxLabel",!0),P),F=x.getShallow("verticalAlign",!0)||x.getShallow("baseline",!0)||c.textVerticalAlign,G=j(x.getShallow("verticalAlignMinLabel",!0),F),U=j(x.getShallow("verticalAlignMaxLabel",!0),F),tt=10+(((T=w.time)===null||T===void 0?void 0:T.level)||0);g=Math.min(g,tt),y=Math.max(y,tt);var Z=new oe({x:0,y:0,rotation:0,silent:Br.isLabelSilent(i),z2:tt,style:mi(x,{text:M,align:b===0?R:b===h.length-1?E:P,verticalAlign:b===0?G:b===h.length-1?U:F,fill:ot(L)?L(o.type==="category"?C:o.type==="value"?A+"":A,b):L})});Z.anid="label_"+A;var at=Ti(Z);if(at.labelInfo=S,at.layoutRotation=c.rotation,ll({el:Z,componentModel:i,itemName:M,formatterParamsExtra:{isTruncated:function(){return Z.isTruncated},value:C,tickIndex:b}}),m){var q=Br.makeAxisEventDataBase(i);q.targetType="axisLabel",q.value=C,q.tickIndex=b;var z=S.tick.break;if(z){var lt=z.parsedBreak;q.break={start:lt.vmin,end:lt.vmax}}o.type==="category"&&(q.dataIndex=A),gt(Z).eventData=q,z&&hI(i,a,Z,z)}p.push(Z),l.add(Z)});var _=rt(p,function(S){return{label:S,priority:Ti(S).labelInfo.tick.break?S.z2+(y-g+1):S.z2,defaultAttr:{ignore:S.ignore}}});jf(t,_,l,u)}function b_(e){return!!e.labelLayoutList}function jf(e,t,r,n){e.labelLayoutList=t,e.labelGroup=r,e.axisLabelsCreationContext=n}function uI(e,t,r,n){var i=t.get(["axisLabel","margin"]);D(r,function(a,o){var s=Ur(a);if(s){var l=s.label,u=Ti(l);s.suggestIgnore=l.ignore,l.ignore=!1,ys(vr,fI);var f=t.axis;vr.x=f.dataToCoord(Xa(f.scale,u.labelInfo.tick)),vr.y=e.labelOffset+e.labelDirection*i,vr.rotation=u.layoutRotation,n.add(vr),vr.updateTransform(),n.remove(vr),vr.decomposeTransform(),ys(l,vr),l.markRedraw(),Us(s,!0),Ur(s)}})}var vr=new Rt,fI=new Rt;function Dv(e){return!!e}function hI(e,t,r,n){r.on("click",function(i){var a={type:QL,breaks:[{start:n.parsedBreak.breakOption.start,end:n.parsedBreak.breakOption.end}]};a[e.axis.dim+"AxisIndex"]=e.componentIndex,t.dispatchAction(a)})}function Ws(e,t,r){r=r||{};var n=t.axis,i={},a=n.getAxesOnZeroOf()[0],o=n.position,s=a?"onZero":o,l=n.dim,u=[e.x,e.x+e.width,e.y,e.y+e.height],f={left:0,right:1,top:0,bottom:1,onZero:2},h=t.get("offset")||0,v=l==="x"?[u[2]-h,u[3]+h]:[u[0]-h,u[1]+h];if(a){var c=a.toGlobalCoord(a.dataToCoord(0));v[f.onZero]=Math.max(Math.min(c,v[1]),v[0])}i.position=[l==="y"?v[f[s]]:u[0],l==="x"?v[f[s]]:u[3]],i.rotation=Math.PI/2*(l==="x"?0:1);var d={top:-1,bottom:1,left:-1,right:1};i.labelDirection=i.tickDirection=i.nameDirection=d[o],i.labelOffset=a?v[f[o]]-v[f.onZero]:0,t.get(["axisTick","inside"])&&(i.tickDirection=-i.tickDirection),us(r.labelInside,t.get(["axisLabel","inside"]))&&(i.labelDirection=-i.labelDirection);var p=t.get(["axisLabel","rotate"]);return i.labelRotate=s==="top"?-p:p,i.z2=1,i}function vI(e){var t={xAxisModel:null,yAxisModel:null};return D(t,function(r,n){var i=n.replace(/Model$/,""),a=e.getReferringComponents(i,Ce).models[0];t[n]=a}),t}function cI(e,t,r,n,i,a){for(var o=Ws(e,r),s=!1,l=!1,u=0;u<t.length;u++)H0(t[u].getOtherAxis(r.axis).scale)&&(s=l=!0,r.axis.type==="category"&&r.axis.onBand&&(l=!1));return o.axisLineAutoShow=s,o.axisTickAutoShow=l,o.defaultNameMoveOverlap=a,new Br(r,n,o,i)}function dI(e,t,r){var n=Ws(t,r);e.updateCfg(n)}var T_={left:0,right:0,top:0,bottom:0},Ys=["25%","25%"],os="cartesian2d",pI=(function(e){V(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.mergeDefaultAndTheme=function(r,n){var i=Wa(r.outerBounds);e.prototype.mergeDefaultAndTheme.apply(this,arguments),i&&r.outerBounds&&Hr(r.outerBounds,i)},t.prototype.mergeOption=function(r,n){e.prototype.mergeOption.apply(this,arguments),this.option.outerBounds&&r.outerBounds&&Hr(this.option.outerBounds,r.outerBounds)},t.type="grid",t.dependencies=["xAxis","yAxis"],t.layoutMode="box",t.defaultOption={show:!1,z:0,left:"15%",top:65,right:"10%",bottom:80,containLabel:!1,outerBoundsMode:"auto",outerBounds:T_,outerBoundsContain:"all",outerBoundsClampWidth:Ys[0],outerBoundsClampHeight:Ys[1],backgroundColor:J.color.transparent,borderWidth:1,borderColor:J.color.neutral30},t})(pt),th=(function(e){V(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.getCoordSysModel=function(){return this.getReferringComponents("grid",Ce).models[0]},t.type="cartesian2dAxis",t})(pt);ar(th,MA);var w_={show:!0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:"auto",onZeroAxisIndex:null,lineStyle:{color:J.color.axisLine,width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15],breakLine:!0},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12,color:J.color.axisLabel,textMargin:[0,3]},splitLine:{show:!0,showMinLine:!0,showMaxLine:!0,lineStyle:{color:J.color.axisSplitLine,width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:[J.color.backgroundTint,J.color.backgroundTransparent]}},breakArea:{show:!0,itemStyle:{color:J.color.neutral00,borderColor:J.color.border,borderWidth:1,borderType:[3,3],opacity:.6},zigzagAmplitude:4,zigzagMinSpan:4,zigzagMaxSpan:20,zigzagZ:100,expandOnClick:!0},breakLabelLayout:{moveOverlap:"auto"}},gI=ct({boundaryGap:!0,deduplication:null,jitter:0,jitterOverlap:!0,jitterMargin:2,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto",show:"auto"},axisLabel:{interval:"auto"}},w_),Mv=ct({boundaryGap:[0,0],axisLine:{show:"auto"},axisTick:{show:"auto"},splitNumber:5,minorTick:{show:!1,splitNumber:5,length:3,lineStyle:{}},minorSplitLine:{show:!1,lineStyle:{color:J.color.axisMinorSplitLine,width:1}}},w_),mI=ct({splitNumber:6,axisLabel:{rich:{primary:{fontWeight:"bold"}}},splitLine:{show:!1}},Mv),yI=yt({logBase:10},Mv);const _I={category:gI,value:Mv,time:mI,log:yI};function jp(e,t,r,n){D(X0,function(i,a){var o=ct(ct({},_I[a],!0),n,!0),s=(function(l){V(u,l);function u(){var f=l!==null&&l.apply(this,arguments)||this;return f.type=t+"Axis."+a,f}return u.prototype.mergeDefaultAndTheme=function(f,h){var v=xa(this),c=v?Wa(f):{},d=h.getTheme();ct(f,d.get(a+"Axis")),ct(f,this.getDefaultOption()),f.type=tg(f),v&&Hr(f,c,v)},u.prototype.optionUpdated=function(){var f=this.option;f.type==="category"&&(this.__ordinalMeta=qf.createByAxisModel(this))},u.prototype.getCategories=function(f){var h=this.option;if(h.type==="category")return f?h.data:this.__ordinalMeta.categories},u.prototype.getOrdinalMeta=function(){return this.__ordinalMeta},u.prototype.updateAxisBreaks=function(f){return{breaks:[]}},u.type=t+"Axis."+a,u.defaultOption=o,u})(r);e.registerComponentModel(s)}),e.registerSubTypeDefaulter(t+"Axis",tg)}function tg(e){return e.type||(e.data?"category":"value")}var SI=(function(){function e(t){this.type="cartesian",this._dimList=[],this._axes={},this.name=t||""}return e.prototype.getAxis=function(t){return this._axes[t]},e.prototype.getAxes=function(){return rt(this._dimList,function(t){return this._axes[t]},this)},e.prototype.getAxesByScale=function(t){return t=t.toLowerCase(),Xt(this.getAxes(),function(r){return r.scale.type===t})},e.prototype.addAxis=function(t){var r=t.dim;this._axes[r]=t,this._dimList.push(r)},e})(),ss=["x","y"];function eg(e){return(e.type==="interval"||e.type==="time")&&!Ls(e)}var bI=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=os,r.dimensions=ss,r}return t.prototype.calcAffineTransform=function(){this._transform=this._invTransform=null;var r=this.getAxis("x").scale,n=this.getAxis("y").scale;if(!(!eg(r)||!eg(n))){var i=Ns(r,null),a=Ns(n,null),o=this.dataToPoint([i[0],a[0]]),s=this.dataToPoint([i[1],a[1]]),l=i[1]-i[0],u=a[1]-a[0];if(!(!l||!u)){var f=(s[0]-o[0])/l,h=(s[1]-o[1])/u,v=o[0]-i[0]*f,c=o[1]-a[0]*h,d=this._transform=[f,0,0,h,v,c];this._invTransform=Oa([],d)}}},t.prototype.getBaseAxis=function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAxis("x")},t.prototype.containPoint=function(r){var n=this.getAxis("x"),i=this.getAxis("y");return n.contain(n.toLocalCoord(r[0]))&&i.contain(i.toLocalCoord(r[1]))},t.prototype.containData=function(r){return this.getAxis("x").containData(r[0])&&this.getAxis("y").containData(r[1])},t.prototype.containZone=function(r,n){var i=this.dataToPoint(r),a=this.dataToPoint(n),o=this.getArea(),s=new it(i[0],i[1],a[0]-i[0],a[1]-i[1]);return o.intersect(s)},t.prototype.dataToPoint=function(r,n,i){i=i||[];var a=r[0],o=r[1];if(this._transform&&a!=null&&isFinite(a)&&o!=null&&isFinite(o))return Ae(i,r,this._transform);var s=this.getAxis("x"),l=this.getAxis("y");return i[0]=s.toGlobalCoord(s.dataToCoord(a,n)),i[1]=l.toGlobalCoord(l.dataToCoord(o,n)),i},t.prototype.clampData=function(r,n){var i=this.getAxis("x").scale,a=this.getAxis("y").scale,o=i.getExtent(),s=a.getExtent(),l=i.parse(r[0]),u=a.parse(r[1]);return n=n||[],n[0]=Math.min(Math.max(Math.min(o[0],o[1]),l),Math.max(o[0],o[1])),n[1]=Math.min(Math.max(Math.min(s[0],s[1]),u),Math.max(s[0],s[1])),n},t.prototype.pointToData=function(r,n,i){if(i=i||[],this._invTransform)return Ae(i,r,this._invTransform);var a=this.getAxis("x"),o=this.getAxis("y");return i[0]=a.coordToData(a.toLocalCoord(r[0]),n),i[1]=o.coordToData(o.toLocalCoord(r[1]),n),i},t.prototype.getOtherAxis=function(r){return this.getAxis(r.dim==="x"?"y":"x")},t.prototype.getArea=function(r){r=r||0;var n=this.getAxis("x").getGlobalExtent(),i=this.getAxis("y").getGlobalExtent(),a=Math.min(n[0],n[1])-r,o=Math.min(i[0],i[1])-r,s=Math.max(n[0],n[1])-a+r,l=Math.max(i[0],i[1])-o+r;return new it(a,o,s,l)},t})(SI);function TI(e,t){var r=e.scale,n=e.model,i=r_(r,n,n.ecModel,e),a=Si(r),o=Si(t)?t.intervalStub:t,s=a?r.intervalStub:r,l=r.base,u=o.getTicks(),f=o.getTicks({expandToNicedExtent:!0}),h=u.length-1,v,c,d;if(h===1)v=c=0,d=1;else if(h===2){var p=Nt(u[0].value-u[1].value),m=Nt(u[1].value-u[2].value);v=c=0,p===m?d=2:(d=1,p<m?v=p/m:c=m/p)}else{var g=o.getConfig().interval;v=(1-(u[0].value-f[0].value)/g)%1,c=(1-(f[h].value-u[h].value)/g)%1,d=h-(v?1:0)-(c?1:0)}var y=i.zoomFixMM,_=y[0]||y[1],S=[i.fixMM[0]||_,i.fixMM[1]||_],b=r.getExtent(),T=s.getExtent(),w=V0(T,S),M,C,x,A,I,L;function P(at){for(var q=50,z=0;z<q&&!at();z++)x=a?x*mt(l,2):aA(x),A=Pn(x)}function R(){M=ft(L-x*v,A)}function E(){C=ft(I+x*c,A)}function F(){L=v?ft(M+x*v,A):M}function G(){I=c?ft(C-x*c,A):C}if(S[0]&&S[1]){M=w[0],C=w[1],x=(C-M)/(d+v+c);var U=e.getExtent(),tt=Nt(U[1]-U[0]);A=qS([C,M],tt,.5/d),F(),G(),rr(A)&&(x=ft(x,A))}else{var Z=w[1]-w[0];x=a?mt(fm(Z),1):Sh(Z/d,hm),A=Pn(x),S[0]?(M=w[0],P(function(){if(F(),I=ft(L+x*d,A),E(),C>=w[1])return!0})):S[1]?(C=w[1],P(function(){if(G(),L=ft(I-x*d,A),R(),M<=w[0])return!0})):P(function(){L=ft(Fa(w[0]/x)*x,A),I=ft(pi(w[1]/x)*x,A);var at=gr((I-L)/x);if(at<=d){var q=d-at,z=void 0,lt=i.incl0||a;if(lt&&w[0]===0)z=[0,q];else if(lt&&w[1]===0)z=[q,0];else{var k=pi(q/2);z=q%2===0?[k,k]:M+C<w[0]+w[1]?[k,k+1]:[k+1,k]}if(L=ft(L-x*z[0],A),I=ft(I+x*z[1],A),R(),E(),M<=w[0]&&C>=w[1])return!0}})}Z0(r,S,T,[M,C],b,{interval:x,intervalCount:d,intervalPrecision:A,niceExtent:[L,I]})}var rg=[[3,1],[0,2]],wI=(function(){function e(t,r,n){this.type="grid",this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this.axisPointerEnabled=!0,this.dimensions=ss,this._initCartesian(t,r,n),this.model=t}return e.prototype.getRect=function(){return this._rect},e.prototype.update=function(t,r){var n=this._axesMap;D(this._axesList,function(o){HA(o,BA);var s=o.scale;lr(s)&&s.setSortInfo(o.model.get("categorySortInfo"))});function i(o){for(var s=xt(o),l=[],u=s.length-1;u>=0;u--){var f=o[+s[u]];f.__alignTo?l.push(f):Bp(f)}D(l,function(h){CI(h,h.__alignTo)?Bp(h):TI(h,h.__alignTo.scale)})}i(n.x),i(n.y);var a={};D(n.x,function(o){ng(n,"y",o,a)}),D(n.y,function(o){ng(n,"x",o,a)}),this.resize(this.model,r)},e.prototype.resize=function(t,r,n){var i=My(t,r),a=this._rect=wa(t.getBoxLayoutParams(),i.refContainer),o=this._axesMap,s=this._coordsList,l=t.get("containLabel");if(x_(o,a),!n){var u=MI(a,s,o,l,r),f=void 0;if(l)f=sg(a.clone(),"axisLabel",null,a,o,u,i);else{var h=AI(t,a,i),v=h.outerBoundsRect,c=h.parsedOuterBoundsContain,d=h.outerBoundsClamp;v&&(f=sg(v,c,d,a,o,u,i))}C_(a,o,Be.determine,null,f,i),D(this._coordsList,function(p){p.calcAffineTransform()})}},e.prototype.getAxis=function(t,r){var n=this._axesMap[t];if(n!=null)return n[r||0]},e.prototype.getAxes=function(){return this._axesList.slice()},e.prototype.getCartesian=function(t,r){if(t!=null&&r!=null){var n="x"+t+"y"+r;return this._coordsMap[n]}K(t)&&(r=t.yAxisIndex,t=t.xAxisIndex);for(var i=0,a=this._coordsList;i<a.length;i++)if(a[i].getAxis("x").index===t||a[i].getAxis("y").index===r)return a[i]},e.prototype.getCartesians=function(){return this._coordsList.slice()},e.prototype.convertToPixel=function(t,r,n){var i=this._findConvertTarget(r);return i.cartesian?i.cartesian.dataToPoint(n):i.axis?i.axis.toGlobalCoord(i.axis.dataToCoord(n)):null},e.prototype.convertFromPixel=function(t,r,n){var i=this._findConvertTarget(r);return i.cartesian?i.cartesian.pointToData(n):i.axis?i.axis.coordToData(i.axis.toLocalCoord(n)):null},e.prototype._findConvertTarget=function(t){var r=t.seriesModel,n=t.xAxisModel||r&&r.getReferringComponents("xAxis",Ce).models[0],i=t.yAxisModel||r&&r.getReferringComponents("yAxis",Ce).models[0],a=t.gridModel,o=this._coordsList,s,l;if(r)s=r.coordinateSystem,vt(o,s)<0&&(s=null);else if(n&&i)s=this.getCartesian(n.componentIndex,i.componentIndex);else if(n)l=this.getAxis("x",n.componentIndex);else if(i)l=this.getAxis("y",i.componentIndex);else if(a){var u=a.coordinateSystem;u===this&&(s=this._coordsList[0])}return{cartesian:s,axis:l}},e.prototype.containPoint=function(t){var r=this._coordsList[0];if(r)return r.containPoint(t)},e.prototype._initCartesian=function(t,r,n){var i=this,a=this,o={left:!1,right:!1,top:!1,bottom:!1},s={x:{},y:{}},l={x:0,y:0};if(r.eachComponent("xAxis",u("x"),this),r.eachComponent("yAxis",u("y"),this),!l.x||!l.y){this._axesMap={},this._axesList=[];return}this._axesMap=s,D(s.x,function(f,h){D(s.y,function(v,c){var d="x"+h+"y"+c,p=new bI(d);p.master=i,p.model=t,i._coordsMap[d]=p,i._coordsList.push(p),p.addAxis(f),p.addAxis(v)})}),ag(s.x),ag(s.y);function u(f){return function(h,v){if(xI(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 d=mA(h),p=new ZL(f,yA(h,d),[0,0],d,c);p.onBand=q0(p.scale,h),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,l[f]++}}}},e.prototype.getTooltipAxes=function(t){var r=[],n=[];return D(this.getCartesians(),function(i){var a=t!=null&&t!=="auto"?i.getAxis(t):i.getBaseAxis(),o=i.getOtherAxis(a);vt(r,a)<0&&r.push(a),vt(n,o)<0&&n.push(o)}),{baseAxes:r,otherAxes:n}},e.create=function(t,r){var n=[];return t.eachComponent("grid",function(i,a){var o=new e(i,t,r);o.name="grid_"+a,o.resize(i,r,!0),i.coordinateSystem=o,n.push(o),D(o._axesList,function(s){zA(s,e.dimIdxMap)})}),t.eachSeries(function(i){var a,o;Ix({targetModel:i,coordSysType:os,coordSysProvider:s});function s(){var l=vI(i),u=l.xAxisModel,f=l.yAxisModel;a=u.axis,o=f.axis;var h=u.getCoordSysModel(),v=h.coordinateSystem;return v.getCartesian(u.componentIndex,f.componentIndex)}a&&o&&(Ip(a,i,os),Ip(o,i,os))},this),n},e.dimensions=ss,e.dimIdxMap=yv(ss),e})();function xI(e,t){return e.getCoordSysModel()===t}function ng(e,t,r,n){r.getAxesOnZeroOf=function(){return a?[a]:[]};var i=e[t],a,o=r.model,s=o.get(["axisLine","onZero"]),l=o.get(["axisLine","onZeroAxisIndex"]);if(!s)return;if(l!=null)ig(s,i[l])&&(a=i[l]);else for(var u in i)if(fe(i,u)&&ig(s,i[u])&&!n[f(i[u])]){a=i[u];break}a&&(n[f(a)]=!0);function f(h){return h.dim+"_"+h.index}}function ig(e,t){if(!t)return!1;var r=t.scale,n=_A(r,0),i=t&&t.type!=="category"&&t.type!=="time"&&n!==Kf;return i&&e==="auto"&&wA(t)&&(i=!1),i}function ag(e){for(var t=xt(e),r,n=[],i=t.length-1;i>=0;i--){var a=e[+t[i]];H0(a.scale)&&DA(a.model,a.type)==null&&(a.model.get("alignTicks")&&a.model.get("interval")==null?n.push(a):r=a)}r||(r=n.pop()),r&&D(n,function(o){o.__alignTo=r})}function CI(e,t){return Ls(e.scale)||Ls(t.scale)||t.scale.getTicks().length<2}function DI(e,t){var r=e.getExtent(),n=r[0]+r[1];e.toGlobalCoord=e.dim==="x"?function(i){return i+t}:function(i){return n-i+t},e.toLocalCoord=e.dim==="x"?function(i){return i-t}:function(i){return n-i+t}}function x_(e,t){D(e.x,function(r){return og(r,t.x,t.width)}),D(e.y,function(r){return og(r,t.y,t.height)})}function og(e,t,r){var n=[0,r],i=e.inverse?1:0;e.setExtent(n[i],n[1-i]),DI(e,t)}function sg(e,t,r,n,i,a,o){C_(n,i,Be.estimate,t,!1,o);var s=[0,0,0,0];u(0),u(1),f(n,0,NaN),f(n,1,NaN);var l=p1(s,function(v){return v>0})==null;return Ms(n,s,!0,!0,r),x_(i,n),l;function u(v){D(i[mn[v]],function(c){if(Pa(c.model)){var d=a.ensureRecord(c.model),p=d.labelInfoList;if(p)for(var m=0;m<p.length;m++){var g=p[m],y=c.scale.normalize(Xa(c.scale,Ti(g.label).labelInfo.tick));y=v===1?1-y:y,f(g.rect,v,y),f(g.rect,1-v,NaN)}var _=d.nameLayout;if(_){var y=bi(d.nameLocation)?.5:NaN;f(_.rect,v,y),f(_.rect,1-v,NaN)}}})}function f(v,c,d){var p=e[mn[c]]-v[mn[c]],m=v[Sa[c]]+v[mn[c]]-(e[Sa[c]]+e[mn[c]]);p=h(p,1-d),m=h(m,d);var g=rg[c][0],y=rg[c][1];s[g]=mt(s[g],p),s[y]=mt(s[y],m)}function h(v,c){return v>0&&!ga(c)&&c>1e-4&&(v/=c),v}}function MI(e,t,r,n,i){var a=new g_(LI);return D(r,function(o){return D(o,function(s){if(Pa(s.model)){var l=!n;s.axisBuilder=cI(e,t,s.model,i,a,l)}})}),a}function C_(e,t,r,n,i,a){var o=r===Be.determine;D(t,function(u){return D(u,function(f){Pa(f.model)&&(dI(f.axisBuilder,e,f.model),f.axisBuilder.build(o?{axisTickLabelDetermine:!0}:{axisTickLabelEstimate:!0},{noPxChange:i}))})});var s={x:0,y:0};l(0),l(1);function l(u){s[mn[1-u]]=e[Sa[u]]<=a.refContainer[Sa[u]]*.5?0:1-u===1?2:1}D(t,function(u,f){return D(u,function(h){Pa(h.model)&&((n==="all"||o)&&h.axisBuilder.build({axisName:!0},{nameMarginLevel:s[f]}),o&&h.axisBuilder.build({axisLine:!0}))})})}function AI(e,t,r){var n,i=e.get("outerBoundsMode",!0);i==="same"?n=t.clone():(i==null||i==="auto")&&(n=wa(e.get("outerBounds",!0)||T_,r.refContainer));var a=e.get("outerBoundsContain",!0),o;a==null||a==="auto"||vt(["all","axisLabel"],a)<0?o="all":o=a;var s=[pf(j(e.get("outerBoundsClampWidth",!0),Ys[0]),t.width),pf(j(e.get("outerBoundsClampHeight",!0),Ys[1]),t.height)];return{outerBoundsRect:n,parsedOuterBoundsContain:o,outerBoundsClamp:s}}var LI=function(e,t,r,n,i,a){var o=r.axis.dim==="x"?"y":"x";m_(e,t,r,n,i,a),bi(e.nameLocation)||D(t.recordMap[o],function(s){s&&s.labelInfoList&&s.dirVec&&__(s.labelInfoList,s.dirVec,n,i)})};function II(e,t){var r={axesInfo:{},seriesInvolved:!1,coordSysAxesInfo:{},coordSysMap:{}};return PI(r,e,t),r.seriesInvolved&&RI(r,e),r}function PI(e,t,r){var n=t.getComponent("tooltip"),i=t.getComponent("axisPointer"),a=i.get("link",!0)||[],o=[];D(r.getCoordinateSystems(),function(s){if(!s.axisPointerEnabled)return;var l=Ea(s.model),u=e.coordSysAxesInfo[l]={};e.coordSysMap[l]=s;var f=s.model,h=f.getModel("tooltip",n);if(D(s.getAxes(),Et(p,!1,null)),s.getTooltipAxes&&n&&h.get("show")){var v=h.get("trigger")==="axis",c=h.get(["axisPointer","type"])==="cross",d=s.getTooltipAxes(h.get(["axisPointer","axis"]));(v||c)&&D(d.baseAxes,Et(p,c?"cross":!0,v)),c&&D(d.otherAxes,Et(p,"cross",!1))}function p(m,g,y){var _=y.model.getModel("axisPointer",i),S=_.get("show");if(!(!S||S==="auto"&&!m&&!eh(_))){g==null&&(g=_.get("triggerTooltip")),_=m?EI(y,h,i,t,m,g):_;var b=_.get("snap"),T=_.get("triggerEmphasis"),w=Ea(y.model),M=g||b||y.type==="category",C=e.axesInfo[w]={key:w,axis:y,coordSys:s,axisPointerModel:_,triggerTooltip:g,triggerEmphasis:T,involveSeries:M,snap:b,useHandle:eh(_),seriesModels:[],linkGroup:null};u[w]=C,e.seriesInvolved=e.seriesInvolved||M;var x=kI(a,y);if(x!=null){var A=o[x]||(o[x]={axesInfo:{}});A.axesInfo[w]=C,A.mapper=a[x].mapper,C.linkGroup=A}}}})}function EI(e,t,r,n,i,a){var o=t.getModel("axisPointer"),s=["type","snap","lineStyle","shadowStyle","label","animation","animationDurationUpdate","animationEasingUpdate","z"],l={};D(s,function(v){l[v]=ut(o.get(v))}),l.snap=e.type!=="category"&&!!a,o.get("type")==="cross"&&(l.type="line");var u=l.label||(l.label={});if(u.show==null&&(u.show=!1),i==="cross"){var f=o.get(["label","show"]);if(u.show=f??!0,!a){var h=l.lineStyle=o.get("crossStyle");h&&yt(u,h.textStyle)}}return e.model.getModel("axisPointer",new Mt(l,r,n))}function RI(e,t){t.eachSeries(function(r){var n=r.coordinateSystem,i=r.get(["tooltip","trigger"],!0),a=r.get(["tooltip","show"],!0);!n||!n.model||i==="none"||i===!1||i==="item"||a===!1||r.get(["axisPointer","show"],!0)===!1||D(e.coordSysAxesInfo[Ea(n.model)],function(o){var s=o.axis;n.getAxis(s.dim)===s&&(o.seriesModels.push(r),o.seriesDataCount==null&&(o.seriesDataCount=0),o.seriesDataCount+=r.getData().count())})})}function kI(e,t){for(var r=t.model,n=t.dim,i=0;i<e.length;i++){var a=e[i]||{};if(Ou(a[n+"AxisId"],r.id)||Ou(a[n+"AxisIndex"],r.componentIndex)||Ou(a[n+"AxisName"],r.name))return i}}function Ou(e,t){return e==="all"||H(e)&&vt(e,t)>=0||e===t}function OI(e){var t=Av(e);if(t){var r=t.axisPointerModel,n=t.axis.scale,i=r.option,a=r.get("status"),o=r.get("value");o!=null&&(o=n.parse(o));var s=eh(r);a==null&&(i.status=s?"show":"hide");var l=n.getExtent();(o==null||o>l[1])&&(o=l[1]),o<l[0]&&(o=l[0]),i.value=o,s&&(i.status=t.axis.scale.isBlank()?"hide":"show")}}function Av(e){var t=(e.ecModel.getComponent("axisPointer")||{}).coordSysAxesInfo;return t&&t.axesInfo[Ea(e)]}function BI(e){var t=Av(e);return t&&t.axisPointerModel}function eh(e){return!!e.get(["handle","show"])}function Ea(e){return e.type+"||"+e.id}var lg={},D_=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r}return t.prototype.render=function(r,n,i,a){this.axisPointerClass&&OI(r),e.prototype.render.apply(this,arguments),this._doUpdateAxisPointerClass(r,i,!0)},t.prototype.updateAxisPointer=function(r,n,i,a){this._doUpdateAxisPointerClass(r,i,!1)},t.prototype.remove=function(r,n){var i=this._axisPointer;i&&i.remove(n)},t.prototype.dispose=function(r,n){this._disposeAxisPointer(n),e.prototype.dispose.apply(this,arguments)},t.prototype._doUpdateAxisPointerClass=function(r,n,i){var a=t.getAxisPointerClass(this.axisPointerClass);if(a){var o=BI(r);o?(this._axisPointer||(this._axisPointer=new a)).render(r,o,n,i):this._disposeAxisPointer(n)}},t.prototype._disposeAxisPointer=function(r){this._axisPointer&&this._axisPointer.dispose(r),this._axisPointer=null},t.registerAxisPointerClass=function(r,n){lg[r]=n},t.getAxisPointerClass=function(r){return r&&lg[r]},t.type="axis",t})(ir),rh=bt();function NI(e,t,r,n){var i=r.axis;if(!i.scale.isBlank()){var a=r.getModel("splitArea"),o=a.getModel("areaStyle"),s=o.get("color"),l=n.coordinateSystem.getRect(),u=i.getTicksCoords({tickModel:a,breakTicks:"none",pruneByBreak:"preserve_extent_bound"});if(u.length){var f=s.length,h=rh(e).splitAreaColors,v=nt(),c=0;if(h)for(var d=0;d<u.length;d++){var p=h.get(u[d].tickValue);if(p!=null){c=(p+(f-1)*d)%f;break}}var m=i.toGlobalCoord(u[0].coord),g=o.getAreaStyle();s=H(s)?s:[s];for(var d=1;d<u.length;d++){var y=i.toGlobalCoord(u[d].coord),_=void 0,S=void 0,b=void 0,T=void 0;i.isHorizontal()?(_=m,S=l.y,b=y-_,T=l.height,m=_+b):(_=l.x,S=m,b=l.width,T=y-S,m=S+T);var w=u[d-1].tickValue;w!=null&&v.set(w,c),t.add(new Rt({anid:w!=null?"area_"+w:null,shape:{x:_,y:S,width:b,height:T},style:yt({fill:s[c]},g),autoBatch:!0,silent:!0})),c=(c+1)%f}rh(e).splitAreaColors=v}}}function FI(e){rh(e).splitAreaColors=null}var zI=["splitArea","splitLine","minorSplitLine","breakArea"],M_=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r.axisPointerClass="CartesianAxisPointer",r}return t.prototype.render=function(r,n,i,a){this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new Vt,this.group.add(this._axisGroup),!!Pa(r)){this._axisGroup.add(r.axis.axisBuilder.group),D(zI,function(l){r.get([l,"show"])&&HI[l](this,this._axisGroup,r,r.getCoordSysModel(),i)},this);var s=a&&a.type==="changeAxisOrder"&&a.isInitSort;s||ay(o,this._axisGroup,r),e.prototype.render.call(this,r,n,i,a)}},t.prototype.remove=function(){FI(this)},t.type="cartesianAxis",t})(D_),HI={splitLine:function(e,t,r,n,i){var a=r.axis;if(!a.scale.isBlank()){var o=r.getModel("splitLine"),s=o.getModel("lineStyle"),l=s.get("color"),u=o.get("showMinLine")!==!1,f=o.get("showMaxLine")!==!1;l=H(l)?l:[l];for(var h=n.coordinateSystem.getRect(),v=a.isHorizontal(),c=0,d=a.getTicksCoords({tickModel:o,breakTicks:"none",pruneByBreak:"preserve_extent_bound"}),p=[],m=[],g=s.getLineStyle(),y=0;y<d.length;y++){var _=a.toGlobalCoord(d[y].coord);if(!(y===0&&!u||y===d.length-1&&!f)){var S=d[y].tickValue;v?(p[0]=_,p[1]=h.y,m[0]=_,m[1]=h.y+h.height):(p[0]=h.x,p[1]=_,m[0]=h.x+h.width,m[1]=_);var b=c++%l.length,T=new Fr({anid:S!=null?"line_"+S:null,autoBatch:!0,shape:{x1:p[0],y1:p[1],x2:m[0],y2:m[1]},style:yt({stroke:l[b]},g),silent:!0});ba(T.shape,g.lineWidth),t.add(T)}}}},minorSplitLine:function(e,t,r,n,i){var a=r.axis,o=r.getModel("minorSplitLine"),s=o.getModel("lineStyle"),l=n.coordinateSystem.getRect(),u=a.isHorizontal(),f=a.getMinorTicksCoords();if(f.length)for(var h=[],v=[],c=s.getLineStyle(),d=0;d<f.length;d++)for(var p=0;p<f[d].length;p++){var m=a.toGlobalCoord(f[d][p].coord);u?(h[0]=m,h[1]=l.y,v[0]=m,v[1]=l.y+l.height):(h[0]=l.x,h[1]=m,v[0]=l.x+l.width,v[1]=m);var g=new Fr({anid:"minor_line_"+f[d][p].tickValue,autoBatch:!0,shape:{x1:h[0],y1:h[1],x2:v[0],y2:v[1]},style:c,silent:!0});ba(g.shape,c.lineWidth),t.add(g)}},splitArea:function(e,t,r,n,i){NI(e,t,r,n)},breakArea:function(e,t,r,n,i){r.axis.scale}},A_=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r}return t.type="xAxis",t})(M_),VI=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=A_.type,r}return t.type="yAxis",t})(M_),GI=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type="grid",r}return t.prototype.render=function(r,n){this.group.removeAll(),r.get("show")&&this.group.add(new Rt({shape:r.coordinateSystem.getRect(),style:yt({fill:r.get("backgroundColor")},r.getItemStyle()),silent:!0,z2:-1}))},t.type="grid",t})(ir),ug={offset:0};function UI(e){e.registerComponentView(GI),e.registerComponentModel(pI),e.registerCoordinateSystem("cartesian2d",wI),jp(e,"x",th,ug),jp(e,"y",th,ug),e.registerComponentView(A_),e.registerComponentView(VI),e.registerPreprocessor(function(t){t.xAxis&&t.yAxis&&!t.grid&&(t.grid={})})}var yn=bt(),fg=ut,Bu=wt,WI=(function(){function e(){this._dragging=!1,this.animationThreshold=15}return e.prototype.render=function(t,r,n,i){var a=r.get("value"),o=r.get("status");if(this._axisModel=t,this._axisPointerModel=r,this._api=n,!(!i&&this._lastValue===a&&this._lastStatus===o)){this._lastValue=a,this._lastStatus=o;var s=this._group,l=this._handle;if(!o||o==="hide"){s&&s.hide(),l&&l.hide();return}s&&s.show(),l&&l.show();var u={};this.makeElOption(u,a,t,r,n);var f=u.graphicKey;f!==this._lastGraphicKey&&this.clear(n),this._lastGraphicKey=f;var h=this._moveAnimation=this.determineAnimation(t,r);if(!s)s=this._group=new Vt,this.createPointerEl(s,u,t,r),this.createLabelEl(s,u,t,r),n.getZr().add(s);else{var v=Et(hg,r,h);this.updatePointerEl(s,u,v),this.updateLabelEl(s,u,v,r)}cg(s,r,!0),this._renderHandle(a)}},e.prototype.remove=function(t){this.clear(t)},e.prototype.dispose=function(t){this.clear(t)},e.prototype.determineAnimation=function(t,r){var n=r.get("animation"),i=t.axis,a=i.type==="category",o=r.get("snap");if(!o&&!a)return!1;if(n==="auto"||n==null){var s=this.animationThreshold;if(a&&yl(i).w>s)return!0;if(o){var l=Av(t).seriesDataCount,u=i.getExtent();return Math.abs(u[0]-u[1])/l>s}return!1}return n===!0},e.prototype.makeElOption=function(t,r,n,i,a){},e.prototype.createPointerEl=function(t,r,n,i){var a=r.pointer;if(a){var o=yn(t).pointerEl=new Xw[a.type](fg(r.pointer));t.add(o)}},e.prototype.createLabelEl=function(t,r,n,i){if(r.label){var a=yn(t).labelEl=new oe(fg(r.label));t.add(a),vg(a,i)}},e.prototype.updatePointerEl=function(t,r,n){var i=yn(t).pointerEl;i&&r.pointer&&(i.setStyle(r.pointer.style),n(i,{shape:r.pointer.shape}))},e.prototype.updateLabelEl=function(t,r,n,i){var a=yn(t).labelEl;a&&(a.setStyle(r.label.style),n(a,{x:r.label.x,y:r.label.y}),vg(a,i))},e.prototype._renderHandle=function(t){if(!(this._dragging||!this.updateHandleTransform)){var r=this._axisPointerModel,n=this._api.getZr(),i=this._handle,a=r.getModel("handle"),o=r.get("status");if(!a.get("show")||!o||o==="hide"){i&&n.remove(i),this._handle=null;return}var s;this._handle||(s=!0,i=this._handle=Vh(a.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(u){Hg(u.event)},onmousedown:Bu(this._onHandleDragMove,this,0,0),drift:Bu(this._onHandleDragMove,this),ondragend:Bu(this._onHandleDragEnd,this)}),n.add(i)),cg(i,r,!1),i.setStyle(a.getItemStyle(null,["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"]));var l=a.get("size");H(l)||(l=[l,l]),i.scaleX=l[0]/2,i.scaleY=l[1]/2,e0(this,"_doDispatchAxisPointer",a.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,s)}},e.prototype._moveHandleToValue=function(t,r){hg(this._axisPointerModel,!r&&this._moveAnimation,this._handle,Nu(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},e.prototype._onHandleDragMove=function(t,r){var n=this._handle;if(n){this._dragging=!0;var i=this.updateHandleTransform(Nu(n),[t,r],this._axisModel,this._axisPointerModel);this._payloadInfo=i,n.stopAnimation(),n.attr(Nu(i)),yn(n).lastProp=null,this._doDispatchAxisPointer()}},e.prototype._doDispatchAxisPointer=function(){var t=this._handle;if(t){var r=this._payloadInfo,n=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:r.cursorPoint[0],y:r.cursorPoint[1],tooltipOption:r.tooltipOption,axesInfo:[{axisDim:n.axis.dim,axisIndex:n.componentIndex}]})}},e.prototype._onHandleDragEnd=function(){this._dragging=!1;var t=this._handle;if(t){var r=this._axisPointerModel.get("value");this._moveHandleToValue(r),this._api.dispatchAction({type:"hideTip"})}},e.prototype.clear=function(t){this._lastValue=null,this._lastStatus=null;var r=t.getZr(),n=this._group,i=this._handle;r&&n&&(this._lastGraphicKey=null,n&&r.remove(n),i&&r.remove(i),this._group=null,this._handle=null,this._payloadInfo=null),Ff(this,"_doDispatchAxisPointer")},e.prototype.doClear=function(){},e.prototype.buildLabel=function(t,r,n){return n=n||0,{x:t[n],y:t[1-n],width:r[n],height:r[1-n]}},e})();function hg(e,t,r,n){L_(yn(r).lastProp,n)||(yn(r).lastProp=n,t?zr(r,n,e):(r.stopAnimation(),r.attr(n)))}function L_(e,t){if(K(e)&&K(t)){var r=!0;return D(t,function(n,i){r=r&&L_(e[i],n)}),!!r}else return e===t}function vg(e,t){e[t.get(["label","show"])?"show":"hide"]()}function Nu(e){return{x:e.x||0,y:e.y||0,rotation:e.rotation||0}}function cg(e,t,r){var n=t.get("z"),i=t.get("zlevel");e&&e.traverse(function(a){a.type!=="group"&&(n!=null&&(a.z=n),i!=null&&(a.zlevel=i),a.silent=r)})}function YI(e){var t=e.get("type"),r=e.getModel(t+"Style"),n;return t==="line"?(n=r.getLineStyle(),n.fill=null):t==="shadow"&&(n=r.getAreaStyle(),n.stroke=null),n}function XI(e,t,r,n,i){var a=r.get("value"),o=I_(a,t.axis,t.ecModel,r.get("seriesDataIndices"),{precision:r.get(["label","precision"]),formatter:r.get(["label","formatter"])}),s=r.getModel("label"),l=cl(s.get("padding")||0),u=s.getFont(),f=nm(o,u),h=i.position,v=f.width+l[1]+l[3],c=f.height+l[0]+l[2],d=i.align;d==="right"&&(h[0]-=v),d==="center"&&(h[0]-=v/2);var p=i.verticalAlign;p==="bottom"&&(h[1]-=c),p==="middle"&&(h[1]-=c/2),$I(h,v,c,n);var m=s.get("backgroundColor");(!m||m==="auto")&&(m=t.get(["axisLine","lineStyle","color"])),e.label={x:h[0],y:h[1],style:mi(s,{text:o,font:u,fill:s.getTextColor(),padding:l,backgroundColor:m}),z2:10}}function $I(e,t,r,n){var i=n.getWidth(),a=n.getHeight();e[0]=Math.min(e[0]+t,i)-t,e[1]=Math.min(e[1]+r,a)-r,e[0]=Math.max(e[0],0),e[1]=Math.max(e[1],0)}function I_(e,t,r,n,i){e=t.scale.parse(e);var a=t.scale.getLabel({value:e},{precision:i.precision}),o=i.formatter;if(o){var s={value:zs(t,{value:e}),axisDimension:t.dim,axisIndex:t.index,seriesData:[]};D(n,function(l){var u=r.getSeriesByIndex(l.seriesIndex),f=l.dataIndexInside,h=u&&u.getDataParams(f);h&&s.seriesData.push(h)}),W(o)?a=o.replace("{value}",a):ot(o)&&(a=o(s))}return a}function P_(e,t,r){var n=qe();return mh(n,n,r.rotation),Ju(n,n,r.position),Hh([e.dataToCoord(t),(r.labelOffset||0)+(r.labelDirection||1)*(r.labelMargin||0)],n)}function ZI(e,t,r,n,i,a){var o=Br.innerTextLayout(r.rotation,0,r.labelDirection);r.labelMargin=i.get(["label","margin"]),XI(t,n,i,a,{position:P_(n.axis,e,r),align:o.textAlign,verticalAlign:o.textVerticalAlign})}function qI(e,t,r){return r=r||0,{x1:e[r],y1:e[1-r],x2:t[r],y2:t[1-r]}}function KI(e,t,r){return r=r||0,{x:e[r],y:e[1-r],width:t[r],height:t[1-r]}}function QI(e,t,r){return yl(e,{fromStat:{sers:rt(t,function(n){return r.getSeriesByIndex(n.seriesIndex)})},min:1}).w}function JI(e,t,r){return[mt(he(t[0],t[1]),e-r/2),he(e+r/2,mt(t[0],t[1]))]}var jI=(function(e){V(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.prototype.makeElOption=function(r,n,i,a,o){var s=i.axis,l=s.grid,u=a.get("type"),f=s.getGlobalExtent(),h=dg(l,s).getOtherAxis(s).getGlobalExtent(),v=s.toGlobalCoord(s.dataToCoord(n,!0));if(u&&u!=="none"){var c=YI(a),d=t2[u](s,v,f,h,a.get("seriesDataIndices"),a.ecModel);d.style=c,r.graphicKey=d.type,r.pointer=d}var p=Ws(l.getRect(),i);ZI(n,r,p,i,a,o)},t.prototype.getHandleTransform=function(r,n,i){var a=Ws(n.axis.grid.getRect(),n,{labelInside:!1});a.labelMargin=i.get(["handle","margin"]);var o=P_(n.axis,r,a);return{x:o[0],y:o[1],rotation:a.rotation+(a.labelDirection<0?Math.PI:0)}},t.prototype.updateHandleTransform=function(r,n,i,a){var o=i.axis,s=o.grid,l=o.getGlobalExtent(!0),u=dg(s,o).getOtherAxis(o).getGlobalExtent(),f=o.dim==="x"?0:1,h=[r.x,r.y];h[f]+=n[f],h[f]=he(l[1],h[f]),h[f]=mt(l[0],h[f]);var v=(u[1]+u[0])/2,c=[v,v];c[f]=h[f];var d=[{verticalAlign:"middle"},{align:"center"}];return{x:h[0],y:h[1],rotation:r.rotation,cursorPoint:c,tooltipOption:d[f]}},t})(WI);function dg(e,t){var r={};return r[t.dim+"AxisIndex"]=t.index,e.getCartesian(r)}var t2={line:function(e,t,r,n){var i=qI([t,n[0]],[t,n[1]],pg(e));return{type:"Line",subPixelOptimize:!0,shape:i}},shadow:function(e,t,r,n,i,a){var o=QI(e,i,a),s=n[1]-n[0],l=JI(t,r,o),u=l[0],f=l[1];return{type:"Rect",shape:KI([u,n[0]],[f-u,s],pg(e))}}};function pg(e){return e.dim==="x"?0:1}var e2=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r}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:J.color.border,width:1,type:"dashed"},shadowStyle:{color:J.color.shadowTint},label:{show:!0,formatter:null,precision:"auto",margin:3,color:J.color.neutral00,padding:[5,7,5,7],backgroundColor:J.color.accent60,borderColor:null,borderWidth:0,borderRadius:3},handle:{show:!1,icon:"M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4h1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7v-1.2h6.6z M13.3,22H6.7v-1.2h6.6z M13.3,19.6H6.7v-1.2h6.6z",size:45,margin:50,color:J.color.accent40,throttle:40}},t})(pt),dr=bt(),r2=D;function E_(e,t,r){if(!st.node){var n=t.getZr();dr(n).records||(dr(n).records={}),n2(n,t);var i=dr(n).records[e]||(dr(n).records[e]={});i.handler=r}}function n2(e,t){if(dr(e).initialized)return;dr(e).initialized=!0,r("click",Et(Fu,"click")),r("mousemove",Et(Fu,"mousemove")),r("mousewheel",Et(Fu,"mousewheel")),r("globalout",a2);function r(n,i){e.on(n,function(a){var o=o2(t);r2(dr(e).records,function(s){s&&i(s,a,o.dispatchAction)}),i2(o.pendings,t)})}}function i2(e,t){var r=e.showTip.length,n=e.hideTip.length,i;r?i=e.showTip[r-1]:n&&(i=e.hideTip[n-1]),i&&(i.dispatchAction=null,t.dispatchAction(i))}function a2(e,t,r){e.handler("leave",null,r)}function Fu(e,t,r,n){t.handler(e,r,n)}function o2(e){var t={showTip:[],hideTip:[]},r=function(n){var i=t[n.type];i?i.push(n):(n.dispatchAction=r,e.dispatchAction(n))};return{dispatchAction:r,pendings:t}}function nh(e,t){if(!st.node){var r=t.getZr(),n=(dr(r).records||{})[e];n&&(dr(r).records[e]=null)}}var s2=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r}return t.prototype.render=function(r,n,i){var a=n.getComponent("tooltip"),o=r.get("triggerOn")||a&&a.get("triggerOn")||"mousemove|click|mousewheel";E_("axisPointer",i,function(s,l,u){o!=="none"&&(s==="leave"||o.indexOf(s)>=0)&&u({type:"updateAxisPointer",currTrigger:s,x:l&&l.offsetX,y:l&&l.offsetY})})},t.prototype.remove=function(r,n){nh("axisPointer",n)},t.prototype.dispose=function(r,n){nh("axisPointer",n)},t.type="axisPointer",t})(ir);function R_(e,t){var r=[],n=e.seriesIndex,i;if(n==null||!(i=t.getSeriesByIndex(n)))return{point:[]};var a=i.getData(),o=An(a,e);if(o==null||o<0||H(o))return{point:[]};var s=a.getItemGraphicEl(o),l=i.coordinateSystem;if(i.getTooltipPosition)r=i.getTooltipPosition(o)||[];else if(l&&l.dataToPoint)if(e.isStacked){var u=l.getBaseAxis(),f=l.getOtherAxis(u),h=f.dim,v=u.dim,c=h==="x"||h==="radius"?1:0,d=a.mapDimension(v),p=[];p[c]=a.get(d,o),p[1-c]=a.get(a.getCalculationInfo("stackResultDimension"),o),r=l.dataToPoint(p)||[]}else r=l.dataToPoint(a.getValues(rt(l.dimensions,function(g){return a.mapDimension(g)}),o))||[];else if(s){var m=s.getBoundingRect().clone();m.applyTransform(s.transform),r=[m.x+m.width/2,m.y+m.height/2]}return{point:r,el:s}}var gg=bt();function l2(e,t,r){var n=e.currTrigger,i=[e.x,e.y],a=e,o=e.dispatchAction||wt(r.dispatchAction,r),s=t.getComponent("axisPointer").coordSysAxesInfo;if(s){ls(i)&&(i=R_({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},t).point);var l=ls(i),u=a.axesInfo,f=s.axesInfo,h=n==="leave"||ls(i),v={},c={},d={list:[],map:{}},p={showPointer:Et(f2,c),showTooltip:Et(h2,d)};D(s.coordSysMap,function(g,y){var _=l||g.containPoint(i);D(s.coordSysAxesInfo[y],function(S,b){var T=S.axis,w=p2(u,S);if(!h&&_&&(!u||w)){var M=w&&w.value;M==null&&!l&&(M=T.pointToData(i)),M!=null&&mg(S,M,p,!1,v)}})});var m={};return D(f,function(g,y){var _=g.linkGroup;_&&!c[y]&&D(_.axesInfo,function(S,b){var T=c[b];if(S!==g&&T){var w=T.value;_.mapper&&(w=g.axis.scale.parse(_.mapper(w,yg(S),yg(g)))),m[g.key]=w}})}),D(m,function(g,y){mg(f[y],g,p,!0,v)}),v2(c,f,v),c2(d,i,e,o),d2(f,o,r),v}}function mg(e,t,r,n,i){var a=e.axis;if(!(a.scale.isBlank()||!a.containData(t))){if(!e.involveSeries){r.showPointer(e,t);return}var o=u2(t,e),s=o.payloadBatch,l=o.snapToValue;s[0]&&i.seriesIndex==null&&N(i,s[0]),!n&&e.snap&&a.containData(l)&&l!=null&&(t=l),r.showPointer(e,t,s),r.showTooltip(e,o,l)}}function u2(e,t){var r=t.axis,n=r.dim,i=e,a=[],o=Number.MAX_VALUE,s=-1;return D(t.seriesModels,function(l,u){var f=l.getData().mapDimensionsAll(n),h,v;if(l.getAxisTooltipData){var c=l.getAxisTooltipData(f,e,r);v=c.dataIndices,h=c.nestestValue}else{if(v=l.indicesOfNearest(n,f[0],e,r.type==="category"?.5:null),!v.length)return;h=l.getData().get(f[0],v[0])}if(rr(h)){var d=e-h,p=Math.abs(d);p<=o&&((p<o||d>=0&&s<0)&&(o=p,s=d,i=h,a.length=0),D(v,function(m){a.push({seriesIndex:l.seriesIndex,dataIndexInside:m,dataIndex:l.getData().getRawIndex(m)})}))}}),{payloadBatch:a,snapToValue:i}}function f2(e,t,r,n){e[t.key]={value:r,payloadBatch:n}}function h2(e,t,r,n){var i=r.payloadBatch,a=t.axis,o=a.model,s=t.axisPointerModel;if(!(!t.triggerTooltip||!i.length)){var l=t.coordSys.model,u=Ea(l),f=e.map[u];f||(f=e.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},e.list.push(f)),f.dataByAxis.push({axisDim:a.dim,axisIndex:o.componentIndex,axisType:o.type,axisId:o.id,value:n,valueLabelOpt:{precision:s.get(["label","precision"]),formatter:s.get(["label","formatter"])},seriesDataIndices:i.slice()})}}function v2(e,t,r){var n=r.axesInfo=[];D(t,function(i,a){var o=i.axisPointerModel.option,s=e[a];s?(!i.useHandle&&(o.status="show"),o.value=s.value,o.seriesDataIndices=(s.payloadBatch||[]).slice()):!i.useHandle&&(o.status="hide"),o.status==="show"&&n.push({axisDim:i.axis.dim,axisIndex:i.axis.model.componentIndex,value:o.value})})}function c2(e,t,r,n){if(ls(t)||!e.list.length){n({type:"hideTip"});return}var i=((e.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};n({type:"showTip",escapeConnect:!0,x:t[0],y:t[1],tooltipOption:r.tooltipOption,position:r.position,dataIndexInside:i.dataIndexInside,dataIndex:i.dataIndex,seriesIndex:i.seriesIndex,dataByCoordSys:e.list})}function d2(e,t,r){var n=r.getZr(),i="axisPointerLastHighlights",a=gg(n)[i]||{},o=gg(n)[i]={};D(e,function(f,h){var v=f.axisPointerModel.option;v.status==="show"&&f.triggerEmphasis&&D(v.seriesDataIndices,function(c){o[c.seriesIndex+"|"+c.dataIndex]=c})});var s=[],l=[];function u(f){return{seriesIndex:f.seriesIndex,dataIndex:f.dataIndex}}D(a,function(f,h){!o[h]&&l.push(u(f))}),D(o,function(f,h){!a[h]&&s.push(u(f))}),l.length&&r.dispatchAction({type:"downplay",escapeConnect:!0,notBlur:!0,batch:l}),s.length&&r.dispatchAction({type:"highlight",escapeConnect:!0,notBlur:!0,batch:s})}function p2(e,t){for(var r=0;r<(e||[]).length;r++){var n=e[r];if(t.axis.dim===n.axisDim&&t.axis.model.componentIndex===n.axisIndex)return n}}function yg(e){var t=e.axis.model,r={},n=r.axisDim=e.axis.dim;return r.axisIndex=r[n+"AxisIndex"]=t.componentIndex,r.axisName=r[n+"AxisName"]=t.name,r.axisId=r[n+"AxisId"]=t.id,r}function ls(e){return!e||e[0]==null||isNaN(e[0])||e[1]==null||isNaN(e[1])}function k_(e){D_.registerAxisPointerClass("CartesianAxisPointer",jI),e.registerComponentModel(e2),e.registerComponentView(s2),e.registerPreprocessor(function(t){if(t){(!t.axisPointer||t.axisPointer.length===0)&&(t.axisPointer={});var r=t.axisPointer.link;r&&!H(r)&&(t.axisPointer.link=[r])}}),e.registerProcessor(e.PRIORITY.PROCESSOR.STATISTIC,{overallReset:function(t,r){t.getComponent("axisPointer").coordSysAxesInfo=II(t,r)}}),e.registerAction({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},l2)}function g2(e){Gr(UI),Gr(k_)}function m2(e,t){var r=cl(t.get("padding")),n=t.getItemStyle(["color","opacity"]);n.fill=t.get("backgroundColor");var i=new Rt({shape:{x:e.x-r[3],y:e.y-r[0],width:e.width+r[1]+r[3],height:e.height+r[0]+r[2],r:t.get("borderRadius")},style:n,silent:!0,z2:-1});return i}var y2=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r}return t.type="tooltip",t.dependencies=["axisPointer"],t.defaultOption={z:60,show:!0,showContent:!0,trigger:"item",triggerOn:"mousemove|click|mousewheel",alwaysShowContent:!1,renderMode:"auto",confine:null,showDelay:0,hideDelay:100,transitionDuration:.4,displayTransition:!0,enterable:!1,backgroundColor:J.color.neutral00,shadowBlur:10,shadowColor:"rgba(0, 0, 0, .2)",shadowOffsetX:1,shadowOffsetY:2,borderRadius:4,borderWidth:1,defaultBorderColor:J.color.border,padding:null,extraCssText:"",axisPointer:{type:"line",axis:"auto",animation:"auto",animationDurationUpdate:200,animationEasingUpdate:"exponentialOut",crossStyle:{color:J.color.borderShade,width:1,type:"dashed",textStyle:{}}},textStyle:{color:J.color.tertiary,fontSize:14}},t})(pt);function O_(e){var t=e.get("confine");return t!=null?!!t:e.get("renderMode")==="richText"}function B_(e){if(st.domSupported){for(var t=document.documentElement.style,r=0,n=e.length;r<n;r++)if(e[r]in t)return e[r]}}var N_=B_(["transform","webkitTransform","OTransform","MozTransform","msTransform"]),_2=B_(["webkitTransition","transition","OTransition","MozTransition","msTransition"]);function F_(e,t){if(!e)return t;t=xy(t,!0);var r=e.indexOf(t);return e=r===-1?t:"-"+e.slice(0,r)+"-"+t,e.toLowerCase()}function S2(e,t){var r=e.currentStyle||document.defaultView&&document.defaultView.getComputedStyle(e);return r?r[t]:null}var b2=F_(_2,"transition"),Lv=F_(N_,"transform"),T2="position:absolute;display:block;border-style:solid;white-space:nowrap;z-index:9999999;"+(st.transform3dSupported?"will-change:transform;":"");function w2(e){return e=e==="left"?"right":e==="right"?"left":e==="top"?"bottom":"top",e}function x2(e,t,r){if(!W(r)||r==="inside")return"";var n=e.get("backgroundColor"),i=e.get("borderWidth");t=In(t);var a=w2(r),o=Math.max(Math.round(i)*1.5,6),s="",l=Lv+":",u;vt(["left","right"],a)>-1?(s+="top:50%",l+="translateY(-50%) rotate("+(u=a==="left"?-225:-45)+"deg)"):(s+="left:50%",l+="translateX(-50%) rotate("+(u=a==="top"?225:45)+"deg)");var f=u*Math.PI/180,h=o+i,v=h*Math.abs(Math.cos(f))+h*Math.abs(Math.sin(f)),c=Math.round(((v-Math.SQRT2*i)/2+Math.SQRT2*i-(v-h)/2)*100)/100;s+=";"+a+":-"+c+"px";var d=t+" solid "+i+"px;",p=["position:absolute;width:"+o+"px;height:"+o+"px;z-index:-1;",s+";"+l+";","border-bottom:"+d,"border-right:"+d,"background-color:"+n+";"];return'<div style="'+p.join("")+'"></div>'}function C2(e,t,r){var n="cubic-bezier(0.23,1,0.32,1)",i="",a="";return r&&(i=" "+e/2+"s "+n,a="opacity"+i+",visibility"+i),t||(i=" "+e+"s "+n,a+=(a.length?",":"")+(st.transformSupported?""+Lv+i:",left"+i+",top"+i)),b2+":"+a}function _g(e,t,r){var n=e.toFixed(0)+"px",i=t.toFixed(0)+"px";if(!st.transformSupported)return r?"top:"+i+";left:"+n+";":[["top",i],["left",n]];var a=st.transform3dSupported,o="translate"+(a?"3d":"")+"("+n+","+i+(a?",0":"")+")";return r?"top:0;left:0;"+Lv+":"+o+";":[["top",0],["left",0],[N_,o]]}function D2(e){var t=[],r=e.get("fontSize"),n=e.getTextColor();n&&t.push("color:"+n),t.push("font:"+e.getFont());var i=j(e.get("lineHeight"),Math.round(r*3/2));r&&t.push("line-height:"+i+"px");var a=e.get("textShadowColor"),o=e.get("textShadowBlur")||0,s=e.get("textShadowOffsetX")||0,l=e.get("textShadowOffsetY")||0;return a&&o&&t.push("text-shadow:"+s+"px "+l+"px "+o+"px "+a),D(["decoration","align"],function(u){var f=e.get(u);f&&t.push("text-"+u+":"+f)}),t.join(";")}function M2(e,t,r,n){var i=[],a=e.get("transitionDuration"),o=e.get("backgroundColor"),s=e.get("shadowBlur"),l=e.get("shadowColor"),u=e.get("shadowOffsetX"),f=e.get("shadowOffsetY"),h=e.getModel("textStyle"),v=Qy(e,"html"),c=u+"px "+f+"px "+s+"px "+l;return i.push("box-shadow:"+c),t&&a>0&&i.push(C2(a,r,n)),o&&i.push("background-color:"+o),D(["width","color","radius"],function(d){var p="border-"+d,m=xy(p),g=e.get(m);g!=null&&i.push(p+":"+g+(d==="color"?"":"px"))}),i.push(D2(h)),v!=null&&i.push("padding:"+cl(v).join("px ")+"px"),i.join(";")+";"}function Sg(e,t,r,n,i){var a=t&&t.painter;if(r){var o=a&&a.getViewportRoot();o&&E1(e,o,r,n,i)}else{e[0]=n,e[1]=i;var s=a&&a.getViewportRootOffset();s&&(e[0]+=s.offsetLeft,e[1]+=s.offsetTop)}e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}var A2=(function(){function e(t,r){if(this._show=!1,this._styleCoord=[0,0,0,0],this._enterable=!0,this._alwaysShowContent=!1,this._firstShow=!0,this._longHide=!0,st.wxa)return null;var n=document.createElement("div");n.domBelongToZr=!0,this.el=n;var i=this._zr=t.getZr(),a=r.appendTo,o=a&&(W(a)?document.querySelector(a):pa(a)?a:ot(a)&&a(t.getDom()));Sg(this._styleCoord,i,o,t.getWidth()/2,t.getHeight()/2),(o||t.getDom()).appendChild(n),this._api=t,this._container=o;var s=this;n.onmouseenter=function(){s._enterable&&(clearTimeout(s._hideTimeout),s._show=!0),s._inContent=!0},n.onmousemove=function(l){if(l=l||window.event,!s._enterable){var u=i.handler,f=i.painter.getViewportRoot();ye(f,l,!0),u.dispatch("mousemove",l)}},n.onmouseleave=function(){s._inContent=!1,s._enterable&&s._show&&s.hideLater(s._hideDelay)}}return e.prototype.update=function(t){if(!this._container){var r=this._api.getDom(),n=S2(r,"position"),i=r.style;i.position!=="absolute"&&n!=="absolute"&&(i.position="relative")}var a=t.get("alwaysShowContent");a&&this._moveIfResized(),this._alwaysShowContent=a,this._enableDisplayTransition=t.get("displayTransition")&&t.get("transitionDuration")>0,this.el.className=t.get("className")||""},e.prototype.show=function(t,r){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var n=this.el,i=n.style,a=this._styleCoord;n.innerHTML?i.cssText=T2+M2(t,!this._firstShow,this._longHide,this._enableDisplayTransition)+_g(a[0],a[1],!0)+("border-color:"+In(r)+";")+(t.get("extraCssText")||"")+(";pointer-events:"+(this._enterable?"auto":"none")):i.display="none",this._show=!0,this._firstShow=!1,this._longHide=!1},e.prototype.setContent=function(t,r,n,i,a){var o=this.el;if(t==null){o.innerHTML="";return}var s="";if(W(a)&&n.get("trigger")==="item"&&!O_(n)&&(s=x2(n,i,a)),W(t))o.innerHTML=t+s;else if(t){o.innerHTML="",H(t)||(t=[t]);for(var l=0;l<t.length;l++)pa(t[l])&&t[l].parentNode!==o&&o.appendChild(t[l]);if(s&&o.childNodes.length){var u=document.createElement("div");u.innerHTML=s,o.appendChild(u)}}},e.prototype.setEnterable=function(t){this._enterable=t},e.prototype.getSize=function(){var t=this.el;return t?[t.offsetWidth,t.offsetHeight]:[0,0]},e.prototype.moveTo=function(t,r){if(this.el){var n=this._styleCoord;if(Sg(n,this._zr,this._container,t,r),n[0]!=null&&n[1]!=null){var i=this.el.style,a=_g(n[0],n[1]);D(a,function(o){i[o[0]]=o[1]})}}},e.prototype._moveIfResized=function(){var t=this._styleCoord[2],r=this._styleCoord[3];this.moveTo(t*this._zr.getWidth(),r*this._zr.getHeight())},e.prototype.hide=function(){var t=this,r=this.el.style;this._enableDisplayTransition?(r.visibility="hidden",r.opacity="0"):r.display="none",st.transform3dSupported&&(r.willChange=""),this._show=!1,this._longHideTimeout=setTimeout(function(){return t._longHide=!0},500)},e.prototype.hideLater=function(t){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(wt(this.hide,this),t)):this.hide())},e.prototype.isShow=function(){return this._show},e.prototype.dispose=function(){clearTimeout(this._hideTimeout),clearTimeout(this._longHideTimeout);var t=this._zr;R1(t&&t.painter&&t.painter.getViewportRoot(),this._container);var r=this.el;if(r){r.onmouseenter=r.onmousemove=r.onmouseleave=null;var n=r.parentNode;n&&n.removeChild(r)}this.el=this._container=null},e})(),L2=(function(){function e(t){this._show=!1,this._styleCoord=[0,0,0,0],this._alwaysShowContent=!1,this._enterable=!0,this._zr=t.getZr(),Tg(this._styleCoord,this._zr,t.getWidth()/2,t.getHeight()/2)}return e.prototype.update=function(t){var r=t.get("alwaysShowContent");r&&this._moveIfResized(),this._alwaysShowContent=r},e.prototype.show=function(){this._hideTimeout&&clearTimeout(this._hideTimeout),this.el.show(),this._show=!0},e.prototype.setContent=function(t,r,n,i,a){var o=this;K(t)&&re(""),this.el&&this._zr.remove(this.el);var s=n.getModel("textStyle");this.el=new oe({style:{rich:r.richTextStyles,text:t,lineHeight:22,borderWidth:1,borderColor:i,textShadowColor:s.get("textShadowColor"),fill:n.get(["textStyle","color"]),padding:Qy(n,"richText"),verticalAlign:"top",align:"left"},z:n.get("z")}),D(["backgroundColor","borderRadius","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"],function(u){o.el.style[u]=n.get(u)}),D(["textShadowBlur","textShadowOffsetX","textShadowOffsetY"],function(u){o.el.style[u]=s.get(u)||0}),this._zr.add(this.el);var l=this;this.el.on("mouseover",function(){l._enterable&&(clearTimeout(l._hideTimeout),l._show=!0),l._inContent=!0}),this.el.on("mouseout",function(){l._enterable&&l._show&&l.hideLater(l._hideDelay),l._inContent=!1})},e.prototype.setEnterable=function(t){this._enterable=t},e.prototype.getSize=function(){var t=this.el,r=this.el.getBoundingRect(),n=bg(t.style);return[r.width+n.left+n.right,r.height+n.top+n.bottom]},e.prototype.moveTo=function(t,r){var n=this.el;if(n){var i=this._styleCoord;Tg(i,this._zr,t,r),t=i[0],r=i[1];var a=n.style,o=Lr(a.borderWidth||0),s=bg(a);n.x=t+o+s.left,n.y=r+o+s.top,n.markRedraw()}},e.prototype._moveIfResized=function(){var t=this._styleCoord[2],r=this._styleCoord[3];this.moveTo(t*this._zr.getWidth(),r*this._zr.getHeight())},e.prototype.hide=function(){this.el&&this.el.hide(),this._show=!1},e.prototype.hideLater=function(t){this._show&&!(this._inContent&&this._enterable)&&!this._alwaysShowContent&&(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(wt(this.hide,this),t)):this.hide())},e.prototype.isShow=function(){return this._show},e.prototype.dispose=function(){this._zr.remove(this.el)},e})();function Lr(e){return Math.max(0,e)}function bg(e){var t=Lr(e.shadowBlur||0),r=Lr(e.shadowOffsetX||0),n=Lr(e.shadowOffsetY||0);return{left:Lr(t-r),right:Lr(t+r),top:Lr(t-n),bottom:Lr(t+n)}}function Tg(e,t,r,n){e[0]=r,e[1]=n,e[2]=e[0]/t.getWidth(),e[3]=e[1]/t.getHeight()}var I2=new Rt({shape:{x:-1,y:-1,width:2,height:2}}),P2=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r}return t.prototype.init=function(r,n){if(!(st.node||!n.getDom())){var i=r.getComponent("tooltip"),a=this._renderMode=gb(i.get("renderMode"));this._tooltipContent=a==="richText"?new L2(n):new A2(n,{appendTo:i.get("appendToBody",!0)?"body":i.get("appendTo",!0)})}},t.prototype.render=function(r,n,i){if(!(st.node||!i.getDom())){this.group.removeAll(),this._tooltipModel=r,this._ecModel=n,this._api=i;var a=this._tooltipContent;a.update(r),a.setEnterable(r.get("enterable")),this._initGlobalListener(),this._keepShow(),this._renderMode!=="richText"&&r.get("transitionDuration")?e0(this,"_updatePosition",50,"fixRate"):Ff(this,"_updatePosition")}},t.prototype._initGlobalListener=function(){var r=this._tooltipModel,n=r.get("triggerOn");E_("itemTooltip",this._api,wt(function(i,a,o){n!=="none"&&(n.indexOf(i)>=0?this._tryShow(a,o):i==="leave"&&this._hide(o))},this))},t.prototype._keepShow=function(){var r=this._tooltipModel,n=this._ecModel,i=this._api,a=r.get("triggerOn");if(r.get("trigger")!=="axis"&&(this._lastDataByCoordSys=null,this._cbParamsList=null),this._lastX!=null&&this._lastY!=null&&a!=="none"&&a!=="click"){var o=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){!i.isDisposed()&&o.manuallyShowTip(r,n,i,{x:o._lastX,y:o._lastY,dataByCoordSys:o._lastDataByCoordSys})})}},t.prototype.manuallyShowTip=function(r,n,i,a){if(!(a.from===this.uid||st.node||!i.getDom())){var o=wg(a,i);this._ticket="";var s=a.dataByCoordSys,l=O2(a,n,i);if(l){var u=l.el.getBoundingRect().clone();u.applyTransform(l.el.transform),this._tryShow({offsetX:u.x+u.width/2,offsetY:u.y+u.height/2,target:l.el,position:a.position,positionDefault:"bottom"},o)}else if(a.tooltip&&a.x!=null&&a.y!=null){var f=I2;f.x=a.x,f.y=a.y,f.update(),gt(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(r,n,i,a))return;var h=R_(a,n),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&&(i.dispatchAction({type:"updateAxisPointer",x:a.x,y:a.y}),this._tryShow({offsetX:a.x,offsetY:a.y,position:a.position,target:i.getZr().findHover(a.x,a.y).target},o))}},t.prototype.manuallyHideTip=function(r,n,i,a){var o=this._tooltipContent;this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=this._lastDataByCoordSys=null,this._cbParamsList=null,a.from!==this.uid&&this._hide(wg(a,i))},t.prototype._manuallyAxisShowTip=function(r,n,i,a){var o=a.seriesIndex,s=a.dataIndex,l=n.getComponent("axisPointer").coordSysAxesInfo;if(!(o==null||s==null||l==null)){var u=n.getSeriesByIndex(o);if(u){var f=u.getData(),h=Xi([f.getItemModel(s),u,(u.coordinateSystem||{}).model],this._tooltipModel);if(h.get("trigger")==="axis")return i.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:s,position:a.position}),!0}}},t.prototype._tryShow=function(r,n){var i=r.target,a=this._tooltipModel;if(a){this._lastX=r.offsetX,this._lastY=r.offsetY;var o=r.dataByCoordSys;if(o&&o.length)this._showAxisTooltip(o,r);else if(i){var s=gt(i);if(s.ssrType==="legend")return;this._lastDataByCoordSys=null,this._cbParamsList=null;var l,u;ta(i,function(f){if(f.tooltipDisabled)return l=u=null,!0;l||u||(gt(f).dataIndex!=null?l=f:gt(f).tooltipConfig!=null&&(u=f))},!0),l?this._showSeriesItemTooltip(r,l,n):u?this._showComponentItemTooltip(r,u,n):this._hide(n)}else this._lastDataByCoordSys=null,this._cbParamsList=null,this._hide(n)}},t.prototype._showOrMove=function(r,n){var i=r.get("showDelay");n=wt(n,this),clearTimeout(this._showTimout),i>0?this._showTimout=setTimeout(n,i):n()},t.prototype._showAxisTooltip=function(r,n){var i=this._ecModel,a=this._tooltipModel,o=[n.offsetX,n.offsetY],s=Xi([n.tooltipOption],a),l=this._renderMode,u=[],f=Da("section",{blocks:[],noHeader:!0}),h=[],v=new bu;D(r,function(y){D(y.dataByAxis,function(_){var S=i.getComponent(_.axisDim+"Axis",_.axisIndex),b=_.value,T=S.axis,w=T.scale.parse(b);if(!(!S||b==null)){var M=I_(b,T,i,_.seriesDataIndices,_.valueLabelOpt),C=Da("section",{header:M,noHeader:!$e(M),sortBlocks:!0,blocks:[]});f.blocks.push(C),D(_.seriesDataIndices,function(x){var A=i.getSeriesByIndex(x.seriesIndex),I=x.dataIndexInside,L=A.getDataParams(I);if(!(L.dataIndex<0)){L.axisDim=_.axisDim,L.axisIndex=_.axisIndex,L.axisType=_.axisType,L.axisId=_.axisId,L.axisValue=zs(S.axis,{value:w}),L.axisValueLabel=M,L.marker=v.makeTooltipMarker("item",In(L.color),l);var P=Od(A.formatTooltip(I,!0,null)),R=P.frag;if(R){var E=Xi([A],a).get("valueFormatter");C.blocks.push(E?N({valueFormatter:E},R):R)}P.text&&h.push(P.text),u.push(L)}})}})}),f.blocks.reverse(),h.reverse();var c=n.position,d=s.get("order"),p=Hd(f,v,l,d,i.get("useUTC"),s.get("textStyle"));p&&h.unshift(p);var m=l==="richText"?`
|
|
36
|
+
|
|
37
|
+
`:"<br/>",g=h.join(m);this._showOrMove(s,function(){this._updateContentNotChangedOnAxis(r,u)?this._updatePosition(s,c,o[0],o[1],this._tooltipContent,u):this._showTooltipContent(s,g,u,Math.random()+"",o[0],o[1],c,null,v)})},t.prototype._showSeriesItemTooltip=function(r,n,i){var a=this._ecModel,o=gt(n),s=o.seriesIndex,l=a.getSeriesByIndex(s),u=o.dataModel||l,f=o.dataIndex,h=o.dataType,v=u.getData(h),c=this._renderMode,d=r.positionDefault,p=Xi([v.getItemModel(f),u,l&&(l.coordinateSystem||{}).model],this._tooltipModel,d?{position:d}:null),m=p.get("trigger");if(!(m!=null&&m!=="item")){var g=u.getDataParams(f,h),y=new bu;g.marker=y.makeTooltipMarker("item",In(g.color),c);var _=Od(u.formatTooltip(f,!1,h)),S=p.get("order"),b=p.get("valueFormatter"),T=_.frag,w=T?Hd(b?N({valueFormatter:b},T):T,y,c,S,a.get("useUTC"),p.get("textStyle")):_.text,M="item_"+u.name+"_"+f;this._showOrMove(p,function(){this._showTooltipContent(p,w,g,M,r.offsetX,r.offsetY,r.position,r.target,y)}),i({type:"showTip",dataIndexInside:f,dataIndex:v.getRawIndex(f),seriesIndex:s,from:this.uid})}},t.prototype._showComponentItemTooltip=function(r,n,i){var a=this._renderMode==="html",o=gt(n),s=o.tooltipConfig,l=s.option||{},u=l.encodeHTMLContent;if(W(l)){var f=l;l={content:f,formatter:f},u=!0}u&&a&&l.content&&(l=ut(l),l.content=te(l.content));var h=[l],v=this._ecModel.getComponent(o.componentMainType,o.componentIndex);v&&h.push(v),h.push({formatter:l.content});var c=r.positionDefault,d=Xi(h,this._tooltipModel,c?{position:c}:null),p=d.get("content"),m=Math.random()+"",g=new bu;this._showOrMove(d,function(){var y=ut(d.get("formatterParams")||{});this._showTooltipContent(d,p,y,m,r.offsetX,r.offsetY,r.position,n,g)}),i({type:"showTip",from:this.uid})},t.prototype._showTooltipContent=function(r,n,i,a,o,s,l,u,f){if(this._ticket="",!(!r.get("showContent")||!r.get("show"))){var h=this._tooltipContent;h.setEnterable(r.get("enterable"));var v=r.get("formatter");l=l||r.get("position");var c=n,d=this._getNearestPoint([o,s],i,r.get("trigger"),r.get("borderColor"),r.get("defaultBorderColor",!0)),p=d.color;if(v)if(W(v)){var m=r.ecModel.get("useUTC"),g=H(i)?i[0]:i,y=g&&g.axisType&&g.axisType.indexOf("time")>=0;c=v,y&&(c=vl(g.axisValue,c,m)),c=Cy(c,i,!0)}else if(ot(v)){var _=wt(function(S,b){S===this._ticket&&(h.setContent(b,f,r,p,l),this._updatePosition(r,l,o,s,h,i,u))},this);this._ticket=a,c=v(i,a,_)}else c=v;h.setContent(c,f,r,p,l),h.show(r,p),this._updatePosition(r,l,o,s,h,i,u)}},t.prototype._getNearestPoint=function(r,n,i,a,o){if(i==="axis"||H(n))return{color:a||o};if(!H(n))return{color:a||n.color||n.borderColor}},t.prototype._updatePosition=function(r,n,i,a,o,s,l){var u=this._api.getWidth(),f=this._api.getHeight();n=n||r.get("position");var h=o.getSize(),v=r.get("align"),c=r.get("verticalAlign"),d=l&&l.getBoundingRect().clone();if(l&&d.applyTransform(l.transform),ot(n)&&(n=n([i,a],s,o.el,d,{viewSize:[u,f],contentSize:h.slice()})),H(n))i=Ye(n[0],u),a=Ye(n[1],f);else if(K(n)){var p=n;p.width=h[0],p.height=h[1];var m=wa(p,{width:u,height:f});i=m.x,a=m.y,v=null,c=null}else if(W(n)&&l){var g=k2(n,d,h,r.get("borderWidth"));i=g[0],a=g[1]}else{var g=E2(i,a,o,u,f,v?null:20,c?null:20);i=g[0],a=g[1]}if(v&&(i-=xg(v)?h[0]/2:v==="right"?h[0]:0),c&&(a-=xg(c)?h[1]/2:c==="bottom"?h[1]:0),O_(r)){var g=R2(i,a,o,u,f);i=g[0],a=g[1]}o.moveTo(i,a)},t.prototype._updateContentNotChangedOnAxis=function(r,n){var i=this._lastDataByCoordSys,a=this._cbParamsList,o=!!i&&i.length===r.length;return o&&D(i,function(s,l){var u=s.dataByAxis||[],f=r[l]||{},h=f.dataByAxis||[];o=o&&u.length===h.length,o&&D(u,function(v,c){var d=h[c]||{},p=v.seriesDataIndices||[],m=d.seriesDataIndices||[];o=o&&v.value===d.value&&v.axisType===d.axisType&&v.axisId===d.axisId&&p.length===m.length,o&&D(p,function(g,y){var _=m[y];o=o&&g.seriesIndex===_.seriesIndex&&g.dataIndex===_.dataIndex}),a&&D(v.seriesDataIndices,function(g){var y=g.seriesIndex,_=n[y],S=a[y];_&&S&&S.data!==_.data&&(o=!1)})})}),this._lastDataByCoordSys=r,this._cbParamsList=n,!!o},t.prototype._hide=function(r){this._lastDataByCoordSys=null,this._cbParamsList=null,r({type:"hideTip",from:this.uid})},t.prototype.dispose=function(r,n){st.node||!n.getDom()||(Ff(this,"_updatePosition"),this._tooltipContent.dispose(),nh("itemTooltip",n),this._tooltipContent=null,this._tooltipModel=null,this._lastDataByCoordSys=null,this._cbParamsList=null)},t.type="tooltip",t})(ir);function Xi(e,t,r){var n=t.ecModel,i;r?(i=new Mt(r,n,n),i=new Mt(t.option,i,n)):i=t;for(var a=e.length-1;a>=0;a--){var o=e[a];o&&(o instanceof Mt&&(o=o.get("tooltip",!0)),W(o)&&(o={formatter:o}),o&&(i=new Mt(o,i,n)))}return i}function wg(e,t){return e.dispatchAction||wt(t.dispatchAction,t)}function E2(e,t,r,n,i,a,o){var s=r.getSize(),l=s[0],u=s[1];return a!=null&&(e+l+a+2>n?e-=l+a:e+=a),o!=null&&(t+u+o>i?t-=u+o:t+=o),[e,t]}function R2(e,t,r,n,i){var a=r.getSize(),o=a[0],s=a[1];return e=Math.min(e+o,n)-o,t=Math.min(t+s,i)-s,e=Math.max(e,0),t=Math.max(t,0),[e,t]}function k2(e,t,r,n){var i=r[0],a=r[1],o=Math.ceil(Math.SQRT2*n)+8,s=0,l=0,u=t.width,f=t.height;switch(e){case"inside":s=t.x+u/2-i/2,l=t.y+f/2-a/2;break;case"top":s=t.x+u/2-i/2,l=t.y-a-o;break;case"bottom":s=t.x+u/2-i/2,l=t.y+f+o;break;case"left":s=t.x-i-o,l=t.y+f/2-a/2;break;case"right":s=t.x+u+o,l=t.y+f/2-a/2}return[s,l]}function xg(e){return e==="center"||e==="middle"}function O2(e,t,r){var n=Th(e).queryOptionMap,i=n.keys()[0];if(!(!i||i==="series")){var a=Ha(t,i,n.get(i),{useDefault:!1,enableAll:!1,enableNone:!1}),o=a.models[0];if(o){var s=r.getViewOfComponentModel(o),l;if(s.group.traverse(function(u){var f=gt(u).tooltipConfig;if(f&&f.name===e.name)return l=u,!0}),l)return{componentMainType:i,componentIndex:o.componentIndex,el:l}}}}function B2(e){Gr(k_),e.registerComponentModel(y2),e.registerComponentView(P2),e.registerAction({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},$t),e.registerAction({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},$t)}var N2=function(e,t){if(t==="all")return{type:"all",title:e.getLocaleModel().get(["legend","selector","all"])};if(t==="inverse")return{type:"inverse",title:e.getLocaleModel().get(["legend","selector","inverse"])}},ih=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r.layoutMode={type:"box",ignoreSize:!0},r}return t.prototype.init=function(r,n,i){this.mergeDefaultAndTheme(r,i),r.selected=r.selected||{},this._updateSelector(r)},t.prototype.mergeOption=function(r,n){e.prototype.mergeOption.call(this,r,n),this._updateSelector(r)},t.prototype._updateSelector=function(r){var n=r.selector,i=this.ecModel;n===!0&&(n=r.selector=["all","inverse"]),H(n)&&D(n,function(a,o){W(a)&&(a={type:a}),n[o]=ct(a,N2(i,a.type))})},t.prototype.optionUpdated=function(){this._updateData(this.ecModel);var r=this._data;if(r[0]&&this.get("selectedMode")==="single"){for(var n=!1,i=0;i<r.length;i++){var a=r[i].get("name");if(this.isSelected(a)){this.select(a),n=!0;break}}!n&&this.select(r[0].get("name"))}},t.prototype._updateData=function(r){var n=[],i=[];r.eachRawSeries(function(l){var u=l.name;i.push(u);var f;if(l.legendVisualProvider){var h=l.legendVisualProvider,v=h.getAllNames();r.isSeriesFiltered(l)||(i=i.concat(v)),v.length?n=n.concat(v):f=!0}else f=!0;f&&bh(l)&&n.push(l.name)}),this._availableNames=i;var a=this.get("data")||n,o=nt(),s=rt(a,function(l){return(W(l)||Ct(l))&&(l={name:l}),o.get(l.name)?null:(o.set(l.name,!0),new Mt(l,this,this.ecModel))},this);this._data=Xt(s,function(l){return!!l})},t.prototype.getData=function(){return this._data},t.prototype.select=function(r){var n=this.option.selected,i=this.get("selectedMode");if(i==="single"){var a=this._data;D(a,function(o){n[o.get("name")]=!1})}n[r]=!0},t.prototype.unSelect=function(r){this.get("selectedMode")!=="single"&&(this.option.selected[r]=!1)},t.prototype.toggleSelected=function(r){var n=this.option.selected;n.hasOwnProperty(r)||(n[r]=!0),this[n[r]?"unSelect":"select"](r)},t.prototype.allSelect=function(){var r=this._data,n=this.option.selected;D(r,function(i){n[i.get("name",!0)]=!0})},t.prototype.inverseSelect=function(){var r=this._data,n=this.option.selected;D(r,function(i){var a=i.get("name",!0);n.hasOwnProperty(a)||(n[a]=!0),n[a]=!n[a]})},t.prototype.isSelected=function(r){var n=this.option.selected;return!(n.hasOwnProperty(r)&&!n[r])&&vt(this._availableNames,r)>=0},t.prototype.getOrient=function(){return this.get("orient")==="vertical"?{index:1,name:"vertical"}:{index:0,name:"horizontal"}},t.type="legend.plain",t.dependencies=["series"],t.defaultOption={z:4,show:!0,orient:"horizontal",left:"center",bottom:J.size.m,align:"auto",backgroundColor:J.color.transparent,borderColor:J.color.border,borderRadius:0,borderWidth:0,padding:5,itemGap:8,itemWidth:25,itemHeight:14,symbolRotate:"inherit",symbolKeepAspect:!0,inactiveColor:J.color.disabled,inactiveBorderColor:J.color.disabled,inactiveBorderWidth:"auto",itemStyle:{color:"inherit",opacity:"inherit",borderColor:"inherit",borderWidth:"auto",borderCap:"inherit",borderJoin:"inherit",borderDashOffset:"inherit",borderMiterLimit:"inherit"},lineStyle:{width:"auto",color:"inherit",inactiveColor:J.color.disabled,inactiveWidth:2,opacity:"inherit",type:"inherit",cap:"inherit",join:"inherit",dashOffset:"inherit",miterLimit:"inherit"},textStyle:{color:J.color.secondary},selectedMode:!0,selector:!1,selectorLabel:{show:!0,borderRadius:10,padding:[3,5,3,5],fontSize:12,fontFamily:"sans-serif",color:J.color.tertiary,borderWidth:1,borderColor:J.color.border},emphasis:{selectorLabel:{show:!0,color:J.color.quaternary}},selectorPosition:"auto",selectorItemGap:7,selectorButtonGap:10,tooltip:{show:!1},triggerEvent:!1},t})(pt),qn=Et,ah=D,Ho=Vt,z_=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r.newlineDisabled=!1,r}return t.prototype.init=function(){this.group.add(this._contentGroup=new Ho),this.group.add(this._selectorGroup=new Ho),this._isFirstRender=!0},t.prototype.getContentGroup=function(){return this._contentGroup},t.prototype.getSelectorGroup=function(){return this._selectorGroup},t.prototype.render=function(r,n,i){var a=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),!!r.get("show",!0)){var o=r.get("align"),s=r.get("orient");(!o||o==="auto")&&(o=r.get("left")==="right"&&s==="vertical"?"right":"left");var l=r.get("selector",!0),u=r.get("selectorPosition",!0);l&&(!u||u==="auto")&&(u=s==="horizontal"?"end":"start"),this.renderInner(o,r,n,i,l,s,u);var f=My(r,i).refContainer,h=r.getBoxLayoutParams(),v=r.get("padding"),c=wa(h,f,v),d=this.layoutInner(r,o,c,a,l,u),p=wa(yt({width:d.width,height:d.height},h),f,v);this.group.x=p.x-d.x,this.group.y=p.y-d.y,this.group.markRedraw(),this.group.add(this._backgroundEl=m2(d,r))}},t.prototype.resetInner=function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl),this.getSelectorGroup().removeAll()},t.prototype.renderInner=function(r,n,i,a,o,s,l){var u=this.getContentGroup(),f=nt(),h=n.get("selectedMode"),v=n.get("triggerEvent"),c=[];i.eachRawSeries(function(d){!d.get("legendHoverLink")&&c.push(d.id)}),ah(n.getData(),function(d,p){var m=this,g=d.get("name");if(!this.newlineDisabled&&(g===""||g===`
|
|
38
|
+
`)){var y=new Ho;y.newline=!0,u.add(y);return}var _=i.getSeriesByName(g)[0];if(!f.get(g))if(_){var S=_.getData(),b=S.getVisual("legendLineStyle")||{},T=S.getVisual("legendIcon"),w=S.getVisual("style"),M=this._createItem(_,g,p,d,n,r,b,w,T,h,a);M.on("click",qn(Cg,g,null,a,c)).on("mouseover",qn(oh,_.name,null,a,c)).on("mouseout",qn(sh,_.name,null,a,c)),i.ssr&&M.eachChild(function(C){var x=gt(C);x.seriesIndex=_.seriesIndex,x.dataIndex=p,x.ssrType="legend"}),v&&M.eachChild(function(C){m.packEventData(C,n,_,p,g)}),f.set(g,!0)}else i.eachRawSeries(function(C){var x=this;if(!f.get(g)&&C.legendVisualProvider){var A=C.legendVisualProvider;if(!A.containName(g))return;var I=A.indexOfName(g),L=A.getItemVisual(I,"style"),P=A.getItemVisual(I,"legendIcon"),R=Ke(L.fill);R&&R[3]===0&&(R[3]=.2,L=N(N({},L),{fill:Ba(R,"rgba")}));var E=this._createItem(C,g,p,d,n,r,{},L,P,h,a);E.on("click",qn(Cg,null,g,a,c)).on("mouseover",qn(oh,null,g,a,c)).on("mouseout",qn(sh,null,g,a,c)),i.ssr&&E.eachChild(function(F){var G=gt(F);G.seriesIndex=C.seriesIndex,G.dataIndex=p,G.ssrType="legend"}),v&&E.eachChild(function(F){x.packEventData(F,n,C,p,g)}),f.set(g,!0)}},this)},this),o&&this._createSelector(o,n,a,s,l)},t.prototype.packEventData=function(r,n,i,a,o){var s={componentType:"legend",componentIndex:n.componentIndex,dataIndex:a,value:o,seriesIndex:i.seriesIndex};gt(r).eventData=s},t.prototype._createSelector=function(r,n,i,a,o){var s=this.getSelectorGroup();ah(r,function(u){var f=u.type,h=new oe({style:{x:0,y:0,align:"center",verticalAlign:"middle"},onclick:function(){i.dispatchAction({type:f==="all"?"legendAllSelect":"legendInverseSelect",legendId:n.id})}});s.add(h);var v=n.getModel("selectorLabel"),c=n.getModel(["emphasis","selectorLabel"]);Yh(h,{normal:v,emphasis:c},{defaultText:u.title}),xf(h)})},t.prototype._createItem=function(r,n,i,a,o,s,l,u,f,h,v){var c=r.visualDrawType,d=o.get("itemWidth"),p=o.get("itemHeight"),m=o.isSelected(n),g=a.get("symbolRotate"),y=a.get("symbolKeepAspect"),_=a.get("icon");f=_||f||"roundRect";var S=F2(f,a,l,u,c,m,v),b=new Ho,T=a.getModel("textStyle");if(ot(r.getLegendIcon)&&(!_||_==="inherit"))b.add(r.getLegendIcon({itemWidth:d,itemHeight:p,icon:f,iconRotate:g,itemStyle:S.itemStyle,lineStyle:S.lineStyle,symbolKeepAspect:y}));else{var w=_==="inherit"&&r.getData().getVisual("symbol")?g==="inherit"?r.getData().getVisual("symbolRotate"):g:0;b.add(z2({itemWidth:d,itemHeight:p,icon:f,iconRotate:w,itemStyle:S.itemStyle,symbolKeepAspect:y}))}var M=s==="left"?d+5:-5,C=s,x=o.get("formatter"),A=n;W(x)&&x?A=x.replace("{name}",n??""):ot(x)&&(A=x(n));var I=m?T.getTextColor():a.get("inactiveColor");b.add(new oe({style:mi(T,{text:A,x:M,y:p/2,fill:I,align:C,verticalAlign:"middle"},{inheritColor:I})}));var L=new Rt({shape:b.getBoundingRect(),style:{fill:"transparent"}}),P=a.getModel("tooltip");return P.get("show")&&ll({el:L,componentModel:o,itemName:n,itemTooltipOption:P.option}),b.add(L),b.eachChild(function(R){R.silent=!0}),L.silent=!h,this.getContentGroup().add(b),xf(b),b.__legendDataIndex=i,b},t.prototype.layoutInner=function(r,n,i,a,o,s){var l=this.getContentGroup(),u=this.getSelectorGroup();fa(r.get("orient"),l,r.get("itemGap"),i.width,i.height);var f=l.getBoundingRect(),h=[-f.x,-f.y];if(u.markRedraw(),l.markRedraw(),o){fa("horizontal",u,r.get("selectorItemGap",!0));var v=u.getBoundingRect(),c=[-v.x,-v.y],d=r.get("selectorButtonGap",!0),p=r.getOrient().index,m=p===0?"width":"height",g=p===0?"height":"width",y=p===0?"y":"x";s==="end"?c[p]+=f[m]+d:h[p]+=v[m]+d,c[1-p]+=f[g]/2-v[g]/2,u.x=c[0],u.y=c[1],l.x=h[0],l.y=h[1];var _={x:0,y:0};return _[m]=f[m]+d+v[m],_[g]=Math.max(f[g],v[g]),_[y]=Math.min(0,v[y]+c[1-p]),_}else return l.x=h[0],l.y=h[1],this.group.getBoundingRect()},t.prototype.remove=function(){this.getContentGroup().removeAll(),this._isFirstRender=!0},t.type="legend.plain",t})(ir);function F2(e,t,r,n,i,a,o){function s(m,g){m.lineWidth==="auto"&&(m.lineWidth=g.lineWidth>0?2:0),ah(m,function(y,_){m[_]==="inherit"&&(m[_]=g[_])})}var l=t.getModel("itemStyle"),u=l.getItemStyle(),f=e.lastIndexOf("empty",0)===0?"fill":"stroke",h=l.getShallow("decal");u.decal=!h||h==="inherit"?n.decal:Uf(h,o),u.fill==="inherit"&&(u.fill=n[i]),u.stroke==="inherit"&&(u.stroke=n[f]),u.opacity==="inherit"&&(u.opacity=(i==="fill"?n:r).opacity),s(u,n);var v=t.getModel("lineStyle"),c=v.getLineStyle();if(s(c,r),u.fill==="auto"&&(u.fill=n.fill),u.stroke==="auto"&&(u.stroke=n.fill),c.stroke==="auto"&&(c.stroke=n.fill),!a){var d=t.get("inactiveBorderWidth"),p=u[f];u.lineWidth=d==="auto"?n.lineWidth>0&&p?2:0:u.lineWidth,u.fill=t.get("inactiveColor"),u.stroke=t.get("inactiveBorderColor"),c.stroke=v.get("inactiveColor"),c.lineWidth=v.get("inactiveWidth")}return{itemStyle:u,lineStyle:c}}function z2(e){var t=e.icon||"roundRect",r=_i(t,0,0,e.itemWidth,e.itemHeight,e.itemStyle.fill,e.symbolKeepAspect);return r.setStyle(e.itemStyle),r.rotation=(e.iconRotate||0)*Math.PI/180,r.setOrigin([e.itemWidth/2,e.itemHeight/2]),t.indexOf("empty")>-1&&(r.style.stroke=r.style.fill,r.style.fill=J.color.neutral00,r.style.lineWidth=2),r}function Cg(e,t,r,n){sh(e,t,r,n),r.dispatchAction({type:"legendToggleSelect",name:e??t}),oh(e,t,r,n)}function oh(e,t,r,n){r.usingTHL()||r.dispatchAction({type:"highlight",seriesName:e,name:t,excludeSeriesId:n})}function sh(e,t,r,n){r.usingTHL()||r.dispatchAction({type:"downplay",seriesName:e,name:t,excludeSeriesId:n})}function $i(e,t,r){var n=e==="allSelect"||e==="inverseSelect",i={},a=[];r.eachComponent({mainType:"legend",query:t},function(s){n?s[e]():s[e](t.name),Dg(s,i),a.push(s.componentIndex)});var o={};return r.eachComponent("legend",function(s){D(i,function(l,u){s[l?"select":"unSelect"](u)}),Dg(s,o)}),n?{selected:o,legendIndex:a}:{name:t.name,selected:o}}function Dg(e,t){var r=t||{};return D(e.getData(),function(n){var i=n.get("name");if(!(i===`
|
|
39
|
+
`||i==="")){var a=e.isSelected(i);fe(r,i)?r[i]=r[i]&&a:r[i]=a}}),r}function H2(e){e.registerAction("legendToggleSelect","legendselectchanged",Et($i,"toggleSelected")),e.registerAction("legendAllSelect","legendselectall",Et($i,"allSelect")),e.registerAction("legendInverseSelect","legendinverseselect",Et($i,"inverseSelect")),e.registerAction("legendSelect","legendselected",Et($i,"select")),e.registerAction("legendUnSelect","legendunselected",Et($i,"unSelect"))}var V2=xh(G2);function G2(e){var t=e.findComponents({mainType:"legend"});t&&t.length&&e.filterSeries(function(r){for(var n=0;n<t.length;n++)if(!t[n].isSelected(r.name))return!1;return!0})}function H_(e){e.registerComponentModel(ih),e.registerComponentView(z_),e.registerProcessor(e.PRIORITY.PROCESSOR.SERIES_FILTER,V2),e.registerSubTypeDefaulter("legend",function(){return"plain"}),H2(e)}var U2=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r}return t.prototype.setScrollDataIndex=function(r){this.option.scrollDataIndex=r},t.prototype.init=function(r,n,i){var a=Wa(r);e.prototype.init.call(this,r,n,i),Mg(this,r,a)},t.prototype.mergeOption=function(r,n){e.prototype.mergeOption.call(this,r,n),Mg(this,this.option,r)},t.type="legend.scroll",t.defaultOption=ox(ih.defaultOption,{scrollDataIndex:0,pageButtonItemGap:5,pageButtonGap:null,pageButtonPosition:"end",pageFormatter:"{current}/{total}",pageIcons:{horizontal:["M0,0L12,-10L12,10z","M0,0L-12,-10L-12,10z"],vertical:["M0,0L20,0L10,-20z","M0,0L20,0L10,20z"]},pageIconColor:J.color.accent50,pageIconInactiveColor:J.color.accent10,pageIconSize:15,pageTextStyle:{color:J.color.tertiary},animationDurationUpdate:800}),t})(ih);function Mg(e,t,r){var n=e.getOrient(),i=[1,1];i[n.index]=0,Hr(t,r,{type:"box",ignoreSize:!!i})}var Ag=Vt,zu=["width","height"],Hu=["x","y"],W2=(function(e){V(t,e);function t(){var r=e!==null&&e.apply(this,arguments)||this;return r.type=t.type,r.newlineDisabled=!0,r._currentIndex=0,r}return t.prototype.init=function(){e.prototype.init.call(this),this.group.add(this._containerGroup=new Ag),this._containerGroup.add(this.getContentGroup()),this.group.add(this._controllerGroup=new Ag)},t.prototype.resetInner=function(){e.prototype.resetInner.call(this),this._controllerGroup.removeAll(),this._containerGroup.removeClipPath(),this._containerGroup.__rectSize=null},t.prototype.renderInner=function(r,n,i,a,o,s,l){var u=this;e.prototype.renderInner.call(this,r,n,i,a,o,s,l);var f=this._controllerGroup,h=n.get("pageIconSize",!0),v=H(h)?h:[h,h];d("pagePrev",0);var c=n.getModel("pageTextStyle");f.add(new oe({name:"pageText",style:{text:"xx/xx",fill:c.getTextColor(),font:c.getFont(),verticalAlign:"middle",align:"center"},silent:!0})),d("pageNext",1);function d(p,m){var g=p+"DataIndex",y=Vh(n.get("pageIcons",!0)[n.getOrient().name][m],{onclick:wt(u._pageGo,u,g,n,a)},{x:-v[0]/2,y:-v[1]/2,width:v[0],height:v[1]});y.name=p,f.add(y)}},t.prototype.layoutInner=function(r,n,i,a,o,s){var l=this.getSelectorGroup(),u=r.getOrient().index,f=zu[u],h=Hu[u],v=zu[1-u],c=Hu[1-u];o&&fa("horizontal",l,r.get("selectorItemGap",!0));var d=r.get("selectorButtonGap",!0),p=l.getBoundingRect(),m=[-p.x,-p.y],g=ut(i);o&&(g[f]=i[f]-p[f]-d);var y=this._layoutContentAndController(r,a,g,u,f,v,c,h);if(o){if(s==="end")m[u]+=y[f]+d;else{var _=p[f]+d;m[u]-=_,y[h]-=_}y[f]+=p[f]+d,m[1-u]+=y[c]+y[v]/2-p[v]/2,y[v]=Math.max(y[v],p[v]),y[c]=Math.min(y[c],p[c]+m[1-u]),l.x=m[0],l.y=m[1],l.markRedraw()}return y},t.prototype._layoutContentAndController=function(r,n,i,a,o,s,l,u){var f=this.getContentGroup(),h=this._containerGroup,v=this._controllerGroup;fa(r.get("orient"),f,r.get("itemGap"),a?i.width:null,a?null:i.height),fa("horizontal",v,r.get("pageButtonItemGap",!0));var c=f.getBoundingRect(),d=v.getBoundingRect(),p=this._showController=c[o]>i[o],m=[-c.x,-c.y];n||(m[a]=f[u]);var g=[0,0],y=[-d.x,-d.y],_=j(r.get("pageButtonGap",!0),r.get("itemGap",!0));if(p){var S=r.get("pageButtonPosition",!0);S==="end"?y[a]+=i[o]-d[o]:g[a]+=d[o]+_}y[1-a]+=c[s]/2-d[s]/2,f.setPosition(m),h.setPosition(g),v.setPosition(y);var b={x:0,y:0};if(b[o]=p?i[o]:c[o],b[s]=Math.max(c[s],d[s]),b[l]=Math.min(0,d[l]+y[1-a]),h.__rectSize=i[o],p){var T={x:0,y:0};T[o]=Math.max(i[o]-d[o]-_,0),T[s]=b[s],h.setClipPath(new Rt({shape:T})),h.__rectSize=T[o]}else v.eachChild(function(M){M.attr({invisible:!0,silent:!0})});var w=this._getPageInfo(r);return w.pageIndex!=null&&zr(f,{x:w.contentPosition[0],y:w.contentPosition[1]},p?r:null),this._updatePageInfoView(r,w),b},t.prototype._pageGo=function(r,n,i){var a=this._getPageInfo(n)[r];a!=null&&i.dispatchAction({type:"legendScroll",scrollDataIndex:a,legendId:n.id})},t.prototype._updatePageInfoView=function(r,n){var i=this._controllerGroup;D(["pagePrev","pageNext"],function(f){var h=f+"DataIndex",v=n[h]!=null,c=i.childOfName(f);c&&(c.setStyle("fill",v?r.get("pageIconColor",!0):r.get("pageIconInactiveColor",!0)),c.cursor=v?"pointer":"default")});var a=i.childOfName("pageText"),o=r.get("pageFormatter"),s=n.pageIndex,l=s!=null?s+1:0,u=n.pageCount;a&&o&&a.setStyle("text",W(o)?o.replace("{current}",l==null?"":l+"").replace("{total}",u==null?"":u+""):o({current:l,total:u}))},t.prototype._getPageInfo=function(r){var n=r.get("scrollDataIndex",!0),i=this.getContentGroup(),a=this._containerGroup.__rectSize,o=r.getOrient().index,s=zu[o],l=Hu[o],u=this._findTargetItemIndex(n),f=i.children(),h=f[u],v=f.length,c=v?1:0,d={contentPosition:[i.x,i.y],pageCount:c,pageIndex:c-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!h)return d;var p=S(h);d.contentPosition[o]=-p.s;for(var m=u+1,g=p,y=p,_=null;m<=v;++m)_=S(f[m]),(!_&&y.e>g.s+a||_&&!b(_,g.s))&&(y.i>g.i?g=y:g=_,g&&(d.pageNextDataIndex==null&&(d.pageNextDataIndex=g.i),++d.pageCount)),y=_;for(var m=u-1,g=p,y=p,_=null;m>=-1;--m)_=S(f[m]),(!_||!b(y,_.s))&&g.i<y.i&&(y=g,d.pagePrevDataIndex==null&&(d.pagePrevDataIndex=g.i),++d.pageCount,++d.pageIndex),g=_;return d;function S(T){if(T){var w=T.getBoundingRect(),M=w[l]+T[l];return{s:M,e:M+w[s],i:T.__legendDataIndex}}}function b(T,w){return T.e>=w&&T.s<=w+a}},t.prototype._findTargetItemIndex=function(r){if(!this._showController)return 0;var n,i=this.getContentGroup(),a;return i.eachChild(function(o,s){var l=o.__legendDataIndex;a==null&&l!=null&&(a=s),l===r&&(n=s)}),n??a},t.type="legend.scroll",t})(z_);function Y2(e){e.registerAction("legendScroll","legendscroll",function(t,r){var n=t.scrollDataIndex;n!=null&&r.eachComponent({mainType:"legend",subType:"scroll",query:t},function(i){i.setScrollDataIndex(n)})})}function X2(e){Gr(H_),e.registerComponentModel(U2),e.registerComponentView(W2),Y2(e)}function $2(e){Gr(H_),Gr(X2)}function Lg(e,t,r){var n=ue.createCanvas(),i=t.getWidth(),a=t.getHeight(),o=n.style;return o&&(o.position="absolute",o.left="0",o.top="0",o.width=i+"px",o.height=a+"px",n.setAttribute("data-zr-dom-id",e)),n.width=i*r,n.height=a*r,n}function Vu(e){return!e.__cursors.get(jm)}function Ig(e){var t=e.__cursors.get(jm);return{startIdx:t?t.startIdx:0,endIdx:t?t.endIdx:0}}var V_=(function(e){V(t,e);function t(r,n,i){var a=e.call(this)||this;a.motionBlur=!1,a.lastFrameAlpha=.7,a.dpr=1,a.virtual=!1,a.config={},a.zlevel=0,a.zlevel2=Qo,a.maxRepaintRectCount=5,a.__dirty=!0,a.__firstTimePaint=!0,a.__prevIdx={startIdx:0,endIdx:0};var o;i=i||ms,typeof r=="string"?o=Lg(r,n,i):K(r)&&(o=r,r=o.id),a.id=r,a.dom=o;var s=o.style;return s&&(Fg(o),o.onselectstart=function(){return!1},s.padding="0",s.margin="0",s.borderWidth="0"),a.painter=n,a.dpr=i,a}return t.prototype.afterBrush=function(){this.__prevIdx=Ig(this)},t.prototype.initContext=function(){this.ctx=this.dom.getContext("2d"),this.ctx.dpr=this.dpr},t.prototype.setUnpainted=function(){this.__firstTimePaint=!0},t.prototype.createBackBuffer=function(){var r=this.dpr;this.domBack=Lg("back-"+this.id,this.painter,r),this.ctxBack=this.domBack.getContext("2d"),r!==1&&this.ctxBack.scale(r,r)},t.prototype.createRepaintRects=function(r,n,i,a){if(this.__firstTimePaint)return this.__firstTimePaint=!1,null;var o=[],s=this.maxRepaintRectCount,l=!1,u=new it(0,0,0,0);function f(S){if(!(!S.isFinite()||S.isZero()))if(o.length===0){var b=new it(0,0,0,0);b.copy(S),o.push(b)}else{for(var T=!1,w=1/0,M=0,C=0;C<o.length;++C){var x=o[C];if(x.intersect(S)){var A=new it(0,0,0,0);A.copy(x),A.union(S),o[C]=A,T=!0;break}else if(l){u.copy(S),u.union(x);var I=S.width*S.height,L=x.width*x.height,P=u.width*u.height,R=P-I-L;R<w&&(w=R,M=C)}}if(l&&(o[M].union(S),T=!0),!T){var b=new it(0,0,0,0);b.copy(S),o.push(b)}l||(l=o.length>=s)}}for(var h=Ig(this),v=h.startIdx;v<h.endIdx;++v){var c=r[v];if(c){var d=c.shouldBePainted(i,a,!0,!0),p=c.__isRendered&&(c.__dirty&ne||!d)?c.getPrevPaintRect():null;p&&f(p);var m=d&&(c.__dirty&ne||!c.__isRendered)?c.getPaintRect():null;m&&f(m)}}for(var g=this.__prevIdx,v=g.startIdx;v<g.endIdx;++v){var c=n[v],d=c&&c.shouldBePainted(i,a,!0,!0);if(c&&(!d||!c.__zr)&&c.__isRendered){var p=c.getPrevPaintRect();p&&f(p)}}var y;do{y=!1;for(var v=0;v<o.length;){if(o[v].isZero()){o.splice(v,1);continue}for(var _=v+1;_<o.length;)o[v].intersect(o[_])?(y=!0,o[v].union(o[_]),o.splice(_,1)):_++;v++}}while(y);return this._paintRects=o,o},t.prototype.debugGetPaintRects=function(){return(this._paintRects||[]).slice()},t.prototype.resize=function(r,n){var i=this.dpr,a=this.dom,o=a.style,s=this.domBack;o&&(o.width=r+"px",o.height=n+"px"),a.width=r*i,a.height=n*i,s&&(s.width=r*i,s.height=n*i,i!==1&&this.ctxBack.scale(i,i))},t.prototype.clear=function(r,n,i){var a=this.dom,o=this.ctx,s=a.width,l=a.height;n=n||this.clearColor;var u=this.motionBlur&&!r,f=this.lastFrameAlpha,h=this.dpr,v=this;u&&(this.domBack||this.createBackBuffer(),this.ctxBack.globalCompositeOperation="copy",this.ctxBack.drawImage(a,0,0,s/h,l/h));var c=this.domBack;function d(p,m,g,y){if(o.clearRect(p,m,g,y),n&&n!=="transparent"){var _=void 0;if($s(n)){var S=n.global||n.__width===g&&n.__height===y;_=S&&n.__canvasGradient||Vf(o,n,{x:0,y:0,width:g,height:y}),n.__canvasGradient=_,n.__width=g,n.__height=y}else m1(n)&&(n.scaleX=n.scaleX||h,n.scaleY=n.scaleY||h,_=Gf(o,n,{dirty:function(){v.setUnpainted(),v.painter.refresh()}}));o.save(),o.fillStyle=_||n,o.fillRect(p,m,g,y),o.restore()}u&&(o.save(),o.globalAlpha=f,o.drawImage(c,p,m,g,y),o.restore())}!i||u?d(0,0,s,l):i.length&&D(i,function(p){d(p.x*h,p.y*h,p.width*h,p.height*h)})},t})(or),Pg=1e5,gn=314159,Gu=void 0,Z2=1,Uu=2;function q2(e){return e?e.__builtin__?!0:!(typeof e.resize!="function"||typeof e.refresh!="function"):!1}function K2(e,t){var r=document.createElement("div");return r.style.cssText=["position:relative","width:"+e+"px","height:"+t+"px","padding:0","margin:0","border-width:0"].join(";")+";",r}function Eg(e,t,r,n){var i=new V_(e,t,t.dpr);return i.zlevel=r,i.zlevel2=n,i.__builtin__=!0,G_(i),i}function G_(e){e.__cursorStack=[],e.__cursors=nt()}function Q2(e){return e.startIdx=e.drawIdx=e.endIdx=e.endIdxNew=0,e.used=!1,e.first=e.last=NaN,e.notClearIdx=-1,e}function J2(e,t){var r=e.__cursors,n=+t;return r.get(n)||(e.__cursorStack.push(n),r.set(n,Q2({key:n})))}function Vo(e,t){for(var r=e.__cursorStack,n=0;n<r.length;n++)t(e.__cursors.get(r[n]))}function Wu(e,t){var r=e.layers;return r[t]||(r[t]=new Array(3))}function Wt(e,t,r){for(var n=e.layerStack,i=0;i<n.length;i++){var a=n[i].zl,o=n[i].zl2,s=e.layers[a][o];(!r||(!(r&da)||s.__builtin__)&&(!(r&lh)||!s.__builtin__)&&(!(r&U_)||s!==e.hoverlayer))&&t(s,a,o,i)}}var da=1,lh=2,U_=4,Go=da|U_,j2=(function(){function e(t,r,n,i){this.type="canvas",this._prevDisplayList=[],this._layerConfig={},this._needsManuallyCompositing=!1,this.type="canvas",this._i={layerStack:[],layers:[]};var a=!t.nodeName||t.nodeName.toUpperCase()==="CANVAS";this._opts=n=N({},n||{}),this.dpr=n.devicePixelRatio||ms,this._singleCanvas=a,this.root=t;var o=t.style;if(o&&(Fg(t),t.innerHTML=""),this.storage=r,this._prevDisplayList=[],a){var l=t,u=l.width,f=l.height;n.width!=null&&(u=n.width),n.height!=null&&(f=n.height),this.dpr=n.devicePixelRatio||1,l.width=u*this.dpr,l.height=f*this.dpr,this._width=u,this._height=f;var h=Eg(l,this,gn,Qo);h.initContext(),this._insertLayer(h,gn,Qo,!0),this._domRoot=t}else{this._width=Ao(t,0,n),this._height=Ao(t,1,n);var s=this._domRoot=K2(this._width,this._height);t.appendChild(s)}}return e.prototype.getType=function(){return"canvas"},e.prototype.isSingleCanvas=function(){return this._singleCanvas},e.prototype.getViewportRoot=function(){return this._domRoot},e.prototype.getViewportRootOffset=function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},e.prototype.refresh=function(t){var r;t&&!K(t)?r={paintAll:!!t}:r=t||{};var n=j(r.refresh,!0),i=j(r.refreshHover,!1);if(i&&(this._hoverLayerDirty=Uu),!n)return i&&this._paintHoverList(this.storage.getDisplayList(!1)),this;var a=this.storage.getDisplayList(!0);this._updateLayerStatus(a,r.paintAll),this._redrawId=Math.random();var o=this._prevDisplayList;this._paintList(a,o,this._redrawId);var s=this._backgroundColor;return Wt(this._i,function(l,u,f,h){l.refresh&&l.refresh(h===0?s:null)},lh),this._opts.useDirtyRect&&(this._prevDisplayList=a.slice()),this},e.prototype._paintHoverList=function(t){var r=this._i.hoverlayer,n=this._hoverLayerDirty;if(this._hoverLayerDirty=Gu,n!==Gu&&(!r&&n===Uu&&(r=this._i.hoverlayer=this._ensureLayer(Pg)),!!r)){r.clear();for(var i={inHover:!0,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{}},a,o=0,s=t.length;o<s;o++){var l=t[o];if(l.__inHover){a||(a=r.ctx,a.save());var u=l.__hoverStyle,f=void 0;u&&(f=l.style,l.style=u),Tn(a,l,i),u&&(l.style=f)}}a&&(fi(a,i),a.restore())}},e.prototype.getHoverLayer=function(){return this._ensureLayer(Pg)},e.prototype.paintOne=function(t,r){d0(t,r)},e.prototype._paintList=function(t,r,n){if(this._redrawId===n){var i=this._doPaintList(t,r);if(this._needsManuallyCompositing&&this._compositeManually(),i)Wt(this._i,function(o){o.afterBrush&&o.afterBrush()},Go),this._paintHoverList(t);else{var a=this;hs(function(){a._paintList(t,r,n)})}}},e.prototype._compositeManually=function(){var t=this._ensureLayer(gn).ctx,r=this._domRoot.width,n=this._domRoot.height;t.clearRect(0,0,r,n),Wt(this._i,function(i){i.virtual&&t.drawImage(i.dom,0,0,r,n)},da)},e.prototype._doPaintList=function(t,r){var n=this,i=!0;return Wt(this._i,function(a){var o=!1;if(Vo(a,function(h){(h.drawIdx<h.endIdx||h.notClearIdx>=0)&&(o=!0)}),!(!o&&!a.__dirty)){var s=n._opts.useDirtyRect&&!Vu(a)?a.createRepaintRects(t,r,n._width,n._height):null,l=n._i.layerStack[0],u=!0;if(a.__dirty){u=!1,a.__dirty=!1;var f=a.zlevel===l.zl&&a.zlevel2===l.zl2?n._backgroundColor:null;a.clear(!1,f,s)}Vo(a,function(h){var v=n._paintPerCursor(a,h,t,s,u);i=i&&v})}},Go),st.wxa&&Wt(this._i,function(a){a&&a.ctx&&a.ctx.draw&&a.ctx.draw()}),i},e.prototype._paintPerCursor=function(t,r,n,i,a){var o=t.ctx;if(i)if(!i.length)r.drawIdx=r.endIdx;else for(var s=this.dpr,l=0;l<i.length;++l){var u=i[l];o.save(),o.beginPath(),o.rect(u.x*s,u.y*s,u.width*s,u.height*s),o.clip(),this._paintPerCursorInRect(t,r,n,u,a),o.restore()}else o.save(),this._paintPerCursorInRect(t,r,n,null,a),o.restore();return r.drawIdx>=r.endIdx},e.prototype._paintPerCursorInRect=function(t,r,n,i,a){for(var o={inHover:!1,allClipped:!1,prevEl:null,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{contentRetained:a}},s=t.ctx,l=Vu(t),u=l&&ue.getTime(),f=r.drawIdx,h=r.notClearIdx,v=h>=0?Math.min(h,f):f;v<r.endIdx;v++){var c=n[v];if(!(v<f&&!c.notClear)){if(c.__inHover&&(this._hoverLayerDirty=Uu),i!=null){var d=c.getPaintRect();d&&d.intersect(i)&&(Tn(s,c,o),c.setPrevPaintRect(d))}else Tn(s,c,o);if(l){var p=ue.getTime()-u;if(p>15){v++;break}}}}fi(s,o),r.drawIdx=Math.max(v,f)},e.prototype.getLayer=function(t,r){return this._ensureLayer(t,0,r)},e.prototype._ensureLayer=function(t,r,n){r=r||0;var i=this._singleCanvas;i&&!this._needsManuallyCompositing&&(t=gn,r=0);var a=Wu(this._i,t)[r];return a||(a=Eg("zr_"+t+"."+r,this,t,r),this._layerConfig[t]&&ct(a,this._layerConfig[t],!0),(n||i&&t!==gn)&&(a.virtual=!0),this._insertLayer(a,t,r,!1),a.initContext()),a},e.prototype.insertLayer=function(t,r){this._insertLayer(r,t,0,!1)},e.prototype._insertLayer=function(t,r,n,i){var a=this._i,o=a.layers,s=a.layerStack,l=this._domRoot,u=null;if(!(o[r]&&o[r][n])&&q2(t)){for(var f=s.length,h=0;h<f&&(s[h].zl<r||s[h].zl===r&&s[h].zl2<n);)h++;if(h>0&&(u=Wu(a,s[h-1].zl)[s[h-1].zl2]),s.splice(h,0,{zl:r,zl2:n}),Wu(a,r)[n]=t,!i&&!t.virtual)if(u){var v=u.dom;v.nextSibling?l.insertBefore(t.dom,v.nextSibling):l.appendChild(t.dom)}else l.firstChild?l.insertBefore(t.dom,l.firstChild):l.appendChild(t.dom);t.painter||(t.painter=this)}},e.prototype.eachLayer=function(t,r){return Wt(this._i,function(n,i){t.call(r,n,i)})},e.prototype.eachBuiltinLayer=function(t,r){return Wt(this._i,function(n,i){t.call(r,n,i)},da)},e.prototype.eachOtherLayer=function(t,r){return Wt(this._i,function(n,i){t.call(r,n,i)},lh)},e.prototype.getLayers=function(){var t={};return Wt(this._i,function(r,n,i){t[r.id]=r}),t},e.prototype._updateLayerStatus=function(t,r){var n=this;if(n._singleCanvas)for(var i=1;i<t.length;i++){var a=t[i];if(a.zlevel!==t[i-1].zlevel||a.incremental){n._needsManuallyCompositing=!0;break}}Wt(n._i,function(m){m.__dirty=!1,Vo(m,function(g){g.used=!1,g.endIdxNew=0,g.notClearIdx=-1})},Go);for(var o,s=null,l=null,u=!1,f=0,h=t.length;f<h;f++){var a=t[f],v=a.zlevel,c=a.incremental,d=void 0;if(o!==v&&(o=v,u=!1),c?(u=!0,d=bw):d=u?Sw:Qo,(!s||v!==s.zlevel||d!==s.zlevel2)&&(s=n._ensureLayer(v,d),l=null,!s.__builtin__)){vh("ZLevel "+v+" has been used by unknown layer "+s.id);continue}if((!l||c!==l.key)&&(l=J2(s,c),!l.used))if(l.used=!0,!r&&l.first===a.id){var p=f-l.startIdx;l.startIdx=f,l.drawIdx+=p,l.endIdx+=p}else s.__dirty=!0,l.first=a.id,l.startIdx=l.drawIdx=f,l.endIdx=f+1;l.endIdxNew=f+1,a.__dirty&ne&&!a.__inHover&&((!c||!a.notClear&&f<l.drawIdx)&&(s.__dirty=!0),c&&a.notClear&&l.notClearIdx<0&&(l.notClearIdx=f))}Wt(n._i,function(m){for(var g=m.__cursorStack,y=m.__cursors,_=g.length-1;_>=0;_--){var S=y.get(g[_]);if(!S.used)m.__dirty=!0,y.removeKey(g[_]),g.splice(_,1);else{var b=S.endIdxNew;(Vu(m)?b<S.drawIdx:b!==S.endIdx||!b||t[b-1].id!==S.last)&&(m.__dirty=!0),S.endIdx=S.endIdxNew,S.last=b?t[b-1].id:NaN}}m.__dirty&&(Vo(m,function(T){T.drawIdx=T.startIdx}),n._hoverLayerDirty===Gu&&(n._hoverLayerDirty=Z2))},Go)},e.prototype.clear=function(){return Wt(this._i,function(t){t.clear(),G_(t)},da),this},e.prototype.setBackgroundColor=function(t){this._backgroundColor=t,Wt(this._i,function(r){r.setUnpainted()})},e.prototype.configLayer=function(t,r){if(r){var n=this._layerConfig;n[t]?ct(n[t],r,!0):n[t]=r,Wt(this._i,function(i,a){ct(i,n[a],!0)})}},e.prototype.delLayer=function(t){for(var r=this._i.layerStack,n=this._i.layers,i=r.length-1;i>=0;i--){var a=r[i];if(a.zl===t){var o=n[t][a.zl2];if(o.__builtin__)continue;if(r.splice(i,1),n[t][a.zl2]=void 0,!o.virtual){var s=o.dom.parentNode;s&&s.removeChild(o.dom)}}}},e.prototype.resize=function(t,r){if(this._domRoot.style){var n=this._domRoot;n.style.display="none";var i=this._opts,a=this.root;t!=null&&(i.width=t),r!=null&&(i.height=r),t=Ao(a,0,i),r=Ao(a,1,i),n.style.display="",(this._width!==t||r!==this._height)&&(n.style.width=t+"px",n.style.height=r+"px",Wt(this._i,function(o){o.resize(t,r)}),this.refresh({paintAll:!0})),this._width=t,this._height=r}else{if(t==null||r==null)return;this._width=t,this._height=r,this._ensureLayer(gn).resize(t,r)}return this},e.prototype.clearLayer=function(t){D(this._i.layers[t],function(r){r&&!r.__builtin__&&r.clear()})},e.prototype.dispose=function(){this.root.innerHTML="",this.root=this.storage=this._domRoot=this._i=null},e.prototype.getRenderedCanvas=function(t){if(t=t||{},this._singleCanvas&&!this._compositeManually)return this._i.layers[gn][0].dom;var r=new V_("image",this,t.pixelRatio||this.dpr);r.initContext(),r.clear(!1,t.backgroundColor||this._backgroundColor);var n=r.ctx;if(t.pixelRatio<=this.dpr){this.refresh();var i=r.dom.width,a=r.dom.height;Wt(this._i,function(h){h.__builtin__?n.drawImage(h.dom,0,0,i,a):h.renderToCanvas&&(n.save(),h.renderToCanvas(n),n.restore())})}else{for(var o={inHover:!1,viewWidth:this._width,viewHeight:this._height,beforeBrushParam:{}},s=this.storage.getDisplayList(!0),l=0,u=s.length;l<u;l++){var f=s[l];Tn(n,f,o)}fi(n,o)}return r.dom},e.prototype.getWidth=function(){return this._width},e.prototype.getHeight=function(){return this._height},e})();function tP(e){e.registerPainter("canvas",j2)}const eP={class:"service-status-page"},rP={class:"flex-between"},nP={class:"flex-gap-8"},iP={class:"flex-gap-8"},aP={class:"chart-wrap"},oP={class:"chart-empty"},sP={class:"table-wrap"},lP=["title","onClick"],uP={key:2},fP=["title"],hP={key:1},vP=Y_({__name:"ServiceStatusView",setup(e){Gr([$L,g2,B2,$2,tP]);const{toast:t}=Q_(),{loadError:r,run:n}=J_("延迟数据加载失败,请重试"),i=[{key:"avg10m",label:"10分钟"},{key:"avg30m",label:"30分钟"},{key:"avg1h",label:"1小时"},{key:"avg2h",label:"2小时"},{key:"avg5h",label:"5小时"},{key:"avg8h",label:"8小时"},{key:"avg12h",label:"12小时"},{key:"avg24h",label:"24小时"}],a=de([]),o=de(!0),s=de(!1),l=de(null),u=de(!1),f=de(!1);let h,v;const c=de("avg24h"),d=de("chart"),p=k=>{d.value=k,k==="chart"&&Ev(()=>{S.value&&(!y&&g.value&&(y=_p(g.value)),y==null||y.resize())})},m=de("hour"),g=de(null);let y=null;const _=de(!1),S=de(!1),b=kv(()=>a.value.filter(k=>i.some(B=>k[B.key]!==null)).map(k=>k.model)),T=["#409eff","#67c23a","#e6a23c","#f56c6c","#9067f0","#00b8a9","#f28cb1","#8d6e63","#5c7cfa","#20c997"],w=(k,B)=>{const Q=new Date(k);if(Number.isNaN(Q.getTime()))return"-";const $=et=>String(et).padStart(2,"0");return B==="day"?`${$(Q.getMonth()+1)}-${$(Q.getDate())}`:`${$(Q.getHours())}:00`},M=(k,B)=>{const Q=new Date(k);if(Number.isNaN(Q.getTime()))return"-";const $=X=>String(X).padStart(2,"0"),et=`${Q.getFullYear()}-${$(Q.getMonth()+1)}-${$(Q.getDate())}`;return B==="day"?et:`${et} ${$(Q.getHours())}:00`},C=(k,B,Q)=>{const $=k.map(Y=>B.get(Y)).find(Y=>Y.length>0)??[],et=$.map(Y=>w(Y.bucketStart,Q)),X=$.map(Y=>M(Y.bucketStart,Q));return{tooltip:{trigger:"axis",axisPointer:{type:"line"},formatter:Y=>{const Ft=Y;if(Ft.length===0)return"";const Dt=Ft[0].dataIndex,Ie=[`<b>${X[Dt]}</b>`];for(const kt of Ft)Ie.push(`${kt.marker??""}${kt.seriesName}:${kt.value===null?"-":I(kt.value)}`);return Ie.join("<br/>")}},legend:{top:0,type:"scroll"},grid:{left:56,right:24,top:40,bottom:28},xAxis:{type:"category",data:et,boundaryGap:!0,axisLabel:{fontSize:11}},yAxis:{type:"value",name:"延迟",axisLabel:{formatter:"{value}ms"},splitLine:{lineStyle:{opacity:.3}}},series:k.map((Y,Ft)=>{const Dt=B.get(Y),Ie=new Map(Dt.map(kt=>[kt.bucketStart,kt]));return{name:Y,type:"line",data:$.map(kt=>{var zt;return((zt=Ie.get(kt.bucketStart))==null?void 0:zt.avgLatencyMs)??null}),connectNulls:!1,smooth:!0,symbolSize:4,showSymbol:Dt.length<=40,itemStyle:{color:T[Ft%T.length]},lineStyle:{width:2}}})}},x=()=>n(async()=>{const k=b.value;if(k.length===0){S.value=!1,y==null||y.clear();return}_.value=!0;try{const B=await Promise.all(k.map(async et=>{try{const X=await Za.get(`/api/latency/trend?model=${encodeURIComponent(et)}&granularity=${m.value}`);return[et,X.buckets??[]]}catch{return[et,[]]}})),Q=new Map(B),$=k.filter(et=>(Q.get(et)??[]).length>0);S.value=$.length>0,y&&y.clear(),$.length>0&&(await Ev(),!y&&g.value&&(y=_p(g.value)),y==null||y.setOption(C($,Q,m.value)))}finally{_.value=!1}}),A=()=>y==null?void 0:y.resize(),I=k=>k===null?"-":k<1e3?`${String(k)}ms`:`${(k/1e3).toFixed(1)}s`,L=[103,194,58],P=[230,162,60],R=[245,108,108],E=(k,B)=>{if(k===null)return{};const Q=a.value.map(zt=>zt[B]).filter(zt=>zt!==null);if(Q.length<=1)return{backgroundColor:"rgba(103, 194, 58, 0.25)"};Q.sort((zt,Ai)=>zt-Ai);const $=Q[0],et=Q[Math.floor(Q.length/2)],X=Q[Q.length-1];let Y;X===$?Y=0:k<=et?Y=et===$?0:.5*((k-$)/(et-$)):Y=et===X?1:.5+.5*((k-et)/(X-et));const[Ft,Dt]=Y<=.5?[L,P]:[P,R],Ie=Y<=.5?Y*2:(Y-.5)*2,kt=Ft.map((zt,Ai)=>Math.round(zt+(Dt[Ai]-zt)*Ie));return{backgroundColor:`rgba(${kt[0]}, ${kt[1]}, ${kt[2]}, 0.25)`}},F=k=>{if(k===null)return"-";const B=new Date(k);if(Number.isNaN(B.getTime()))return"-";const Q=$=>String($).padStart(2,"0");return`${B.getFullYear()}-${Q(B.getMonth()+1)}-${Q(B.getDate())} ${Q(B.getHours())}:${Q(B.getMinutes())}:${Q(B.getSeconds())}`},G=(k,B,Q)=>{const $=k[Q],et=B[Q];return $===null&&et===null?0:$===null?1:et===null?-1:$-et},U=kv(()=>[...a.value].sort((k,B)=>G(k,B,c.value))),tt=()=>{},Z=()=>n(async()=>{const k=await Za.get("/api/latency/history");a.value=k.models??[],s.value=k.running,l.value=k.lastRunAt,o.value=!1,d.value==="chart"&&x()}),at=()=>Z(),q=()=>{f.value?h=window.setInterval(()=>void Z(),5e3):h!==void 0&&(window.clearInterval(h),h=void 0)},z=async()=>{u.value=!0;try{await Za.post("/api/latency/run")}catch(k){t(k.message,"error"),u.value=!1;return}v=window.setInterval(async()=>{try{const k=await Za.get("/api/latency/history");a.value=k.models??[],s.value=k.running,l.value=k.lastRunAt,k.running||(window.clearInterval(v),v=void 0,u.value=!1)}catch{}},2e3)},lt=async k=>{await j_(k)?t("已复制到剪贴板","success"):t("复制失败","error")};return X_(()=>{Z(),window.addEventListener("resize",A)}),$_(()=>{h!==void 0&&window.clearInterval(h),v!==void 0&&window.clearInterval(v),window.removeEventListener("resize",A),y==null||y.dispose(),y=null}),(k,B)=>{const Q=ce("el-button"),$=ce("el-alert"),et=ce("el-tag"),X=ce("el-radio-button"),Y=ce("el-radio-group"),Ft=ce("el-checkbox"),Dt=ce("el-option"),Ie=ce("el-select"),kt=ce("el-button-group"),zt=ce("el-table-column"),Ai=ce("el-table"),W_=ce("el-card"),Iv=Z_("loading");return qt(),_r("div",eP,[Pv(r)?(qt(),Yr($,{key:0,title:Pv(r),type:"error","show-icon":"",closable:!1,class:"mb-16"},{default:At(()=>[Gt(Q,{size:"small",onClick:at},{default:At(()=>[...B[5]||(B[5]=[Pe("重试",-1)])]),_:1})]),_:1},8,["title"])):Sl("",!0),Gt(W_,{shadow:"never",class:"main-card"},{header:At(()=>[Ee("div",rP,[Ee("div",nP,[B[7]||(B[7]=Ee("span",{class:"fw-600"},"服务状态",-1)),s.value?(qt(),Yr(et,{key:0,type:"warning",size:"small"},{default:At(()=>[...B[6]||(B[6]=[Pe("测试进行中",-1)])]),_:1})):l.value?(qt(),Yr(et,{key:1,type:"info",size:"small"},{default:At(()=>[Pe(" 上次测试 "+Qa(F(l.value)),1)]),_:1})):Sl("",!0)]),Ee("div",iP,[d.value==="chart"?(qt(),Yr(Y,{key:0,modelValue:m.value,"onUpdate:modelValue":B[0]||(B[0]=dt=>m.value=dt),onChange:x},{default:At(()=>[Gt(X,{value:"hour"},{default:At(()=>[...B[8]||(B[8]=[Pe("按小时",-1)])]),_:1}),Gt(X,{value:"day"},{default:At(()=>[...B[9]||(B[9]=[Pe("按天",-1)])]),_:1})]),_:1},8,["modelValue"])):(qt(),_r(Ka,{key:1},[Gt(Ft,{modelValue:f.value,"onUpdate:modelValue":B[1]||(B[1]=dt=>f.value=dt),onChange:q},{default:At(()=>[...B[10]||(B[10]=[Pe(" 自动刷新(5s) ",-1)])]),_:1},8,["modelValue"]),Gt(Ie,{modelValue:c.value,"onUpdate:modelValue":B[2]||(B[2]=dt=>c.value=dt),style:{width:"140px"},onChange:tt},{default:At(()=>[(qt(),_r(Ka,null,Rv(i,dt=>Gt(Dt,{key:dt.key,label:`按${dt.label}排行`,value:dt.key},null,8,["label","value"])),64))]),_:1},8,["modelValue"])],64)),Gt(kt,{class:"view-switch"},{default:At(()=>[Gt(Q,{type:d.value==="chart"?"primary":"default",onClick:B[3]||(B[3]=dt=>p("chart"))},{default:At(()=>[...B[11]||(B[11]=[Pe(" 图表 ",-1)])]),_:1},8,["type"]),Gt(Q,{type:d.value==="table"?"primary":"default",onClick:B[4]||(B[4]=dt=>p("table"))},{default:At(()=>[...B[12]||(B[12]=[Pe(" 表格 ",-1)])]),_:1},8,["type"])]),_:1}),Gt(Q,{loading:u.value,onClick:z},{default:At(()=>[...B[13]||(B[13]=[Pe(" 延迟测试 ",-1)])]),_:1},8,["loading"])])])]),default:At(()=>[qa(Ee("div",aP,[qa(Ee("div",oP," 暂无趋势数据,点击「延迟测试」开始 ",512),[[bl,!S.value]]),qa(Ee("div",{ref_key:"chartEl",ref:g,class:"chart-dom"},null,512),[[bl,S.value],[Iv,_.value]])],512),[[bl,d.value==="chart"]]),d.value==="table"?(qt(),_r(Ka,{key:0},[B[16]||(B[16]=Ee("div",{class:"muted-sm hint"}," 表格为各模型对上游的探测延迟(明确指令 + max_tokens: 1,有少量 token 消耗);列值 = 对应时间窗口内成功记录的平均延迟,10 分钟内无记录显示 「-」 ",-1)),Ee("div",sP,[qa((qt(),Yr(Ai,{data:U.value,border:"",stripe:"",height:"100%","empty-text":"暂无延迟数据,点击「延迟测试」开始"},{default:At(()=>[Gt(zt,{type:"index",label:"顺序",width:"60",align:"center","class-name":"nowrap-cell"}),Gt(zt,{prop:"model",label:"模型","min-width":"220"},{default:At(({row:dt})=>[Ee("span",{class:"copy-text model-name",title:dt.model,onClick:_l=>lt(dt.model)},Qa(dt.model),9,lP)]),_:1}),(qt(),_r(Ka,null,Rv(i,dt=>Gt(zt,{key:dt.key,label:dt.label,width:"82",align:"center","class-name":"nowrap-cell"},{default:At(({row:_l})=>[Ee("span",{class:"latency-cell",style:q_(E(_l[dt.key],dt.key))},Qa(I(_l[dt.key])),5)]),_:2},1032,["label"])),64)),Gt(zt,{label:"最近结果",width:"92",align:"center","class-name":"nowrap-cell"},{default:At(({row:dt})=>[dt.lastOk===!0?(qt(),Yr(et,{key:0,type:"success",size:"small"},{default:At(()=>[...B[14]||(B[14]=[Pe("正常",-1)])]),_:1})):dt.lastOk===!1?(qt(),Yr(et,{key:1,type:"danger",size:"small"},{default:At(()=>[...B[15]||(B[15]=[Pe("失败",-1)])]),_:1})):(qt(),_r("span",uP,"-"))]),_:1}),Gt(zt,{label:"失败原因","min-width":"160"},{default:At(({row:dt})=>[dt.lastOk===!1?(qt(),_r("span",{key:0,class:"error-text",title:dt.lastError||"未知错误"},Qa(dt.lastError||"未知错误"),9,fP)):(qt(),_r("span",hP,"-"))]),_:1})]),_:1},8,["data"])),[[Iv,o.value]])])],64)):Sl("",!0)]),_:1})])}}}),mP=K_(vP,[["__scopeId","data-v-8dcb74ec"]]);export{mP as default};
|